您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Hidesforum posts that have dislikes on their ratings.
// ==UserScript== // @name Anti shitpost // @version 0.03 // @description Hidesforum posts that have dislikes on their ratings. // @match https://www.torn.com/forums.php* // @grant none // @namespace https://gf.qytechs.cn/users/1041152 // ==/UserScript== (function() { 'use strict'; // Define the main code that hides disliked posts function hideDislikedPosts() { $('li').each(function(index) { const selector = `li:nth-of-type(${index + 1}) > .thread-info-wrap > .thread.right > .rating > .dislike-icon.voted`; //console.log(`Checking element with selector ${selector}`); if ($(selector).length > 0) { //console.log(`Hiding element with selector ${selector}`); $(`li:nth-of-type(${index + 1})`).hide(); } }); } // Check for new posts every 100 seconds and run the main code if any are found setInterval(function() { if ($('li').length > 0) { hideDislikedPosts(); } }, 100); })();
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址