您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Adds a link to full size product images uploaded by users.
// ==UserScript== // @name Trendyol.com Large User Review Images // @namespace http://tampermonkey.net/ // @version 1.2 // @description Adds a link to full size product images uploaded by users. // @author nexus99 // @match https://www.trendyol.com/* // @icon https://www.google.com/s2/favicons?sz=64&domain=trendyol.com // @grant none // @license GNU GPLv3 // ==/UserScript== (function() { 'use strict'; window.addEventListener('load', function() { const nodeList = document.querySelectorAll(".item.review-image"); console.log("Found " + nodeList.length + " items"); for (let i = 0; i < nodeList.length; i++) { const link = document.createElement("a"); link.text = "Large"; var linkURL = nodeList[i].style.backgroundImage.replace("url(\"", "").replace("\")", "").replace(/mnresize\/[^\/]*\/[^\/]*\//, ""); link.href = linkURL; link.style.position = "relative"; link.style.color = "white"; link.style.backgroundColor = "black"; nodeList[i].style.textAlign = "center"; nodeList[i].appendChild(link); } }, false); })();