您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
This removes foes' comments quoted in posts by other members at the KvRaudio forum.
// ==UserScript== // @name KvRaudio.com hide foes' quotes // @namespace https://www.kvraudio.com/forum/ // @description This removes foes' comments quoted in posts by other members at the KvRaudio forum. // @include https://www.kvraudio.com/forum/viewtopic.php* // @include https://www.kvraudio.com/forum/search.php* // @version 0.666 // @grant none // ==/UserScript== // ============= foes list =========================================== let foes = [ "*", '*', '*', "*", "*" ] ; // =================================================================== // Edit the above, replace asterisks with user names on your foes list (note: case sensitive!) // e.g. [ "*", '*', '*', "*", "*" ] -> [ "muted guy", "Right Bastard", "sOmetr0ll", "*", "*" ] // Add more if necessary. // find all quotes let allQuotes, thisQuote, quotee; allQuotes = document.getElementsByTagName('cite'); // check for foes' quotes for (let i = allQuotes.length-1; i>=0; i--) { // reverse order to prevent script from crashing on nested quotes thisQuote = allQuotes[i]; // find quote author quotee = thisQuote.firstChild.innerHTML; if (typeof(quotee) != "string") { // old forum style quotee = thisQuote.innerHTML.slice(0, -7); } // if author is a foe, ditch the quote if (foes.indexOf(quotee) != -1) { thisQuote.parentNode.innerHTML = "  <b>"+quotee+"</b> wrote something but is on your ignore list."; } }