【工具】-屏蔽烦你的id插件

版主: huangchong

头像
supermassive(泥橙)楼主
职业作家
职业作家
帖子互动: 6
帖子: 591
注册时间: 2022年 7月 31日 16:58

【工具】-屏蔽烦你的id插件

帖子 supermassive(泥橙)楼主 »

(Huangchong 编辑)https://www.tampermonkey.net/

从春卷老师的脚本改的,桌面端使用方法:
  • 安装tampermonkey(Firefox/Chrome/Edge, etc.)
  • tampermonkey打开dashboard
  • 点+号,新建脚本,copy&paste(覆盖掉TM自己生成的脚本模板)
已知问题:
  • 在proflat主题下无效
如果发现bug想要俺修,请确认是最新的脚本.

如何汇报问题
  • 1. 确保所有的code全部copy & paste进了油猴
  • 2. 你是用的什么浏览器
  • 3. 你用的什么主题(控制面板->偏好设置->我的论坛风格)
  • 4. 最好有浏览器截图,可以把书签地址栏隐藏,只需要在某个主题下的截图

手机端 update:
  • 10/17/22, 修复版面上失效的问题
  • 7/9/23, 修复无法添加部分含有空格id的问题
  • 2/20/25, 添加了屏蔽部分版面的功能; 添加F2开关
  • 2/23/25, 修复checkbox无法立即生效的bug

代码: 全选

// ==UserScript==
// @name         NewMitbbs-bot-blocker
// @namespace    http://tampermonkey.net/
// @version      0.2.3
// @description  Manages and blocks bot generated content. Shamelessly modified from chunjuan's script at https://greasyfork.org/en/scripts/29195-mitbbs-bot-blocker/code, which was inspired by Smalltalk80's original GM script, http://userscripts-mirror.org/scripts/review/78633
// @author       Sagittarius A*
// @match        http://newmitbbs.com/*
// @match        https://newmitbbs.com/*
// @grant        GM_addStyle
// @run-at       document-idle
// ==/UserScript==

(function () {
  'use strict';

  var storageKey = 'new.mitbbs.blocklist';

  function getBlocklist() {
    var blockList = localStorage.getItem(storageKey);
    if (blockList === null) {
      setBlocklist([]);
      blockList = localStorage.getItem(storageKey);
    }

    try {
      blockList = JSON.parse(blockList);
    } catch (error) {
      blockList = [];
      setBlocklist(blockList);
    }

    blockList = Array.isArray(blockList) ? blockList : [];
    return blockList;
  }

  function setBlocklist(idNameList) {
    // remove duplicate items
    // todo: babel output for this one doesn't really work, have to revert back to old fashion way
    // idNameList = [...new Set(idNameList)]
    var uniqueidNameList = idNameList.filter(function (elem, index, self) {
      return index === self.indexOf(elem);
    });
    uniqueidNameList = uniqueidNameList.sort(function (a, b) {
      // defer from localeCompare for better browser support
      if (a.toLowerCase() < b.toLowerCase()) return -1;
      if (a.toLowerCase() > b.toLowerCase()) return 1;
      return 0;
    });
    localStorage.setItem(storageKey, JSON.stringify(uniqueidNameList));
    document.getElementById('blockListInput').value = uniqueidNameList;
  }

  function getBlockFlag() {
    var blockFlag = localStorage.getItem(storageKey + '.flag');
    if (blockFlag === null) {
      setBlockFlag(0);
      blockFlag = localStorage.getItem(storageKey + '.flag');
    }
    //  js, just being js
    return parseInt(blockFlag);
  }

  function setBlockFlag(flag) {
    localStorage.setItem(storageKey + '.flag', flag);
  }

  function updateBoardVisibility() {
      var pathname = window.location.pathname;
      if(pathname != "/" && pathname != "/index.php"){
          console.log("1: not at main page, not supposed to happen something is wrong");
          return;
      }
      // update list of board
      var boardMap = new Map(JSON.parse(localStorage.getItem(storageKey + ".boardMap")));
      if(boardMap == null)
          boardMap = new Map();

      Array.from(document.getElementsByClassName("forumtitle")).forEach((v, i, a) => {
          //boardMap.set(v.text, [v.getAttribute("href"), "1"])
          if(!boardMap.has(v.text)) // a new board
              boardMap.set(v.text, [v.getAttribute("href"), "1"]) // 1st elem of arr is href of board, 2nd elem of arr is board switch flag, "1" allow, "0" disabled
      });

      localStorage.setItem(storageKey + ".boardMap", JSON.stringify(Array.from(boardMap.entries())));
      var boardCheckList = document.getElementById('checkboxes').getElementsByTagName("ul")[0]
      boardCheckList.innerHTML = '';
      boardMap.forEach((v, k) => {
          var li = document.createElement("li");
          var inputNode = document.createElement("input");
          inputNode.type = "checkbox";
          inputNode.checked = v[1] == "1" ? true : false;
          inputNode.addEventListener('change', function(){
              if(this.checked){
                  boardMap.set(k, [v[0], "1"]);
                  localStorage.setItem(storageKey + ".boardMap", JSON.stringify(Array.from(boardMap.entries())));
              }else{
                  boardMap.set(k, [v[0], "0"]);
                  localStorage.setItem(storageKey + ".boardMap", JSON.stringify(Array.from(boardMap.entries())));
              }
          });
          li.appendChild(inputNode);
          li.appendChild(document.createTextNode(k));
          boardCheckList.appendChild(li);
      });

      // block boards
      boardMap = new Map(JSON.parse(localStorage.getItem(storageKey + ".boardMap")));
      if(boardMap == null) {
          boardMap = new Map();
      }
      var setOfBlockedBoardUrls = new Set();
      boardMap.forEach((v, k) => {
          if(v[1] == "0"){
              setOfBlockedBoardUrls.add(v[0]);
          }

      });


      Array.from(document.getElementsByClassName("topiclist forums")).forEach(it => { // forum sections
          Array.from(it.getElementsByClassName("row")).forEach(iit => { // forums under each section
              if(setOfBlockedBoardUrls.has(iit.getElementsByClassName("forumtitle")[0].getAttribute("href")))
                  iit.style.display = "none";
              else
                  iit.style.display = "";
          });
      });
  }


  function updatePostVisibility() {
    var blockList = getBlocklist();
    var flag = getBlockFlag();
    // if list is not empty
    var counter = 0;
    if (blockList) {
      var taolunDiv = document.querySelector('div.forumbg:not(.announcement)');
      if (taolunDiv == null)
        taolunDiv = document.querySelector('div.sn-cat-header:not(.announcement)');
      // yeah yeah yeah magic number, whatever
      // this will miss the first one though, nice try langfang coder
      var userIDtdNodeList = taolunDiv.querySelectorAll('li.row');
      // console.log(userIDtdNodeList.length);
      userIDtdNodeList.forEach(function (td) {
        // damn, now i miss jquery/zepto
        var id;
        if (td.querySelector('div.topic-poster') != null) {
          id = td.querySelector('div.topic-poster').querySelector('span.username').textContent;
          // console.log("debug 3");
        } else if (td.querySelector('div.responsive-show:not([style*="display:none"]') != null) {
          id = td.querySelector('div.responsive-show:not([style*="display:none"]').querySelector('span.username').textContent;
          // console.log("debug 2");
        } else {
          console.log("couldn't find td");
        }
        //  reset all reply to visible. This is a hack-ish method to fix content not being displayed after userID has been removed from blocklist.
        //  TODO: maybe in the near future, we should keep a local copy of blocklist so that we can compare the changes and show/hide content intelligently, maybe
        td.style.display = '';
        //  yeah, nested if statements
        // console.log("op's id is " + id);
        if (blockList.indexOf(id) > -1) {
          if (flag) {
            td.style.display = 'none';
            // console.log(id + "'s post has been set as invisible");
            counter += 1;
          } else {
            td.style.display = '';
          }
        }
      });
      counter = flag ? counter : 0;
      document.getElementById('blockCounter').innerHTML = counter;
    }
  }

  function updateReplyVisibility() {
    // console.log("changeReplyVisibility called")
    //  now we on individual post page
    var blockList = getBlocklist();
    var flag = getBlockFlag();
    var counter = 0;
    var sideBarBG = document.querySelectorAll('div.post.has-profile');
    sideBarBG.forEach(function (reply) {
      // var post = reply.parentElement.parentElement.parentElement.parentElement.parentElement;
      var userID = reply.querySelector('span.username').textContent;
      //  another magic number!
      var userMenu = reply.querySelector('strong');
      var hasButton = userMenu.querySelector('span.button') !== null;
      if (!hasButton) {
        var blockButton = document.createElement('span');
        blockButton.setAttribute('class', 'button');
        blockButton.innerHTML = '&nbsp;&nbsp;<button class="addToBlock" title="' + userID + '">屏蔽!</button>';
        userMenu.appendChild(blockButton);
      }
      if (!flag) userMenu.querySelector('span.button').style.display = 'none';
      else userMenu.querySelector('span.button').style.display = '';
      //  reset all reply to visible. This is a hack-ish method to fix content not being displayed after userID has been removed from blocklist.
      //  TODO: maybe in the near future, we should keep a local copy of blocklist so that we can compare the changes and show/hide content intelligently, maybe
      reply.style.display = '';
      if (blockList.indexOf(userID) > -1) {
        if (flag) {
          reply.style.display = 'none';
          counter += 1;
        } else {
          reply.style.display = '';
        }
      }
      counter = flag ? counter : 0;
      document.getElementById('blockCounter').innerHTML = counter;
    });

    var allBlockButton = document.querySelectorAll('.addToBlock');
    Array.from(allBlockButton).forEach(function (button) {
      var userID = button.getAttribute('title');
      button.addEventListener('click', function () {
        var yesBlock = confirm('Block ' + userID + ' ?');
        if (yesBlock) {
          blockList.push(userID);
          setBlocklist(blockList);
          document.getElementById('blockListInput').value = getBlocklist().join();
          // updateGlobalVisibility();
          // copy & paste from above code to refresh the page with newly added id
          sideBarBG.forEach(function (reply) {
            // var post = reply.parentElement.parentElement.parentElement.parentElement.parentElement;
            var userID = reply.querySelector('span.username').textContent;
            //  another magic number!
            var userMenu = reply.querySelector('strong');
            var hasButton = userMenu.querySelector('span.button') !== null;
            if (!hasButton) {
              var blockButton = document.createElement('span');
              blockButton.setAttribute('class', 'button');
              blockButton.innerHTML = '&nbsp;&nbsp;<button class="addToBlock" title="' + userID + '">屏蔽!</button>';
              userMenu.appendChild(blockButton);
            }
            if (!flag) userMenu.querySelector('span.button').style.display = 'none';
            else userMenu.querySelector('span.button').style.display = '';
            //  reset all reply to visible. This is a hack-ish method to fix content not being displayed after userID has been removed from blocklist.
            //  TODO: maybe in the near future, we should keep a local copy of blocklist so that we can compare the changes and show/hide content intelligently, maybe
            reply.style.display = '';
            if (blockList.indexOf(userID) > -1) {
              if (flag) {
                reply.style.display = 'none';
                counter += 1;
              } else {
                reply.style.display = '';
              }
            }
            counter = flag ? counter : 0;
            document.getElementById('blockCounter').innerHTML = counter;
          });
        }
      });
    });
  }

  // callback of block switch checkbox. state of checkbox should be read from localStorage by getBlockFlag() to determine state of switch
  function updateGlobalVisibility() {
    //if(getBlockFlag() === 0) return; //
    switch(locationGuesser()) {
      case 0:
        updateBoardVisibility();
        break;
      case 1:
        updatePostVisibility();
        break;
      case 2:
        updateReplyVisibility();
        break;
      default:
        break;
    }
  }

  function locationGuesser() {
    var pageType = void 0;
    var pathname = window.location.pathname;
    if(pathname === "/" || pathname === "/index.php"){
      pageType = 0; // at main page
    } else if(pathname === "/viewforum.php") {
      pageType = 1; // inside a board
    } else if(pathname === "/viewtopic.php") {
      pageType = 2; // inside a post
    } else {
      pageType = -1; // placeholder
    }
    return pageType;
  }

  // callback for when clicking "block" checkbox
  function toggleBlockSwitch() {
     setBlockFlag(document.getElementById('isBlocking').checked ? 1 : 0);
     updateGlobalVisibility();
  }

  // callback for when clicking 黑名单 button
  function toggleBlockListVisibility() {
    var notVisible = document.getElementById('blockListPop').style.display === 'none';
    if (notVisible) {
      // show block list pop up
      document.getElementById('blockListInput').value = getBlocklist().join();
      document.getElementById('blockListPop').style.display = '';
    } else {
      // close block list pop up
      document.getElementById('blockListPop').style.display = 'none';
      // update blocklist when closing the pop up
      updateBlockList();
      //var pathname = window.location.pathname;
      //if(pathname === "/" || pathname === "/index.php")
      //    blockBoards();
      updateGlobalVisibility();
    }
  }

  function updateBlockList() {
    // update ids list
    var newBlockList = document.getElementById('blockListInput').value;
    ////  remove line break, space, trailing comma
    //newBlockList = newBlockList.replace(/(\r\n|\n|\r)/gm, '').replace(/\s/g, '').replace(/,+$/, '');
    //  remove line break, trailing comma
    newBlockList = newBlockList.replace(/(\r\n|\n|\r)/gm, '').replace(/,+$/, '');

    newBlockList = newBlockList.split(',');
    setBlocklist(newBlockList);

    // update board list
    // WIP

    // re-filter existing content
    updateGlobalVisibility();
  }

  function hideBlockList() {
    document.getElementById('blockListPop').style.display = 'none';
  }

  function prepPage() {
      getBlocklist();
      document.getElementById('isBlocking').checked = (getBlockFlag() === 1 ? true : false);
      updateGlobalVisibility();
  }

  function pageOnLoad() {
    //  build blocker control gui
    var blockerDiv = document.createElement('div');
    blockerDiv.innerHTML = '<button id="showBlocklist" class="button">黑名单</button><input type="checkbox" id="isBlocking" /><span id="blockCounter" title="Currently Blocked"></span>';
    blockerDiv.style.cssText = 'position:fixed; bottom:2em; right:0.5em; width:9em; padding:0.5em; border-radius:0.25em; background-color:#D7EAF9; box-shadow:2px 2px 4px 0px rgba(0,0,0,0.5); text-align:center; cursor:pointer;';
    document.body.appendChild(blockerDiv);

    document.getElementById('showBlocklist').addEventListener('click', toggleBlockListVisibility);
    document.getElementById('blockCounter').style.cssText = 'padding:0 4px; font-weight:bold';
    document.getElementById('isBlocking').addEventListener('change', toggleBlockSwitch);

    //  block list
    var blockListDiv = document.createElement('div');
    blockListDiv.setAttribute('id', 'blockListPop');
    blockListDiv.innerHTML = '<div id="checkboxes", style="overflow-y:auto;"><label style="color:blue">版面列表</label><ul style="text-align:left;margin:0;padding:10;color:blue"></ul></div><br/><span>修改ID,用逗号分隔,大小写敏感!</span>' + '<br/>' + '<textarea rows="10" cols="40" id="blockListInput" style="background-color:orange;color:black;font-size:10pt;"></textarea>';
    blockListDiv.style.cssText = 'position:fixed; bottom:5.3em; right:0.5em; padding:0.5em; border-radius:0.25em; background-color:#D7EAF9; box-shadow:2px 2px 4px 0px rgba(0,0,0,0.5); text-align:center; display:none';
    document.body.appendChild(blockListDiv);

    prepPage();
  }

  function ready(fn) {
    if (document.readyState !== 'loading') {
      fn();
    } else {
      document.addEventListener('DOMContentLoaded', fn);
    }
  }

  ready(pageOnLoad);

  // hotkey (F2) to toggle switch
  document.addEventListener('keydown', function(event) {
      event.stopImmediatePropagation();
      if(event.code === "F2"){
          // toggle checkbox
          document.getElementById('isBlocking').checked = !document.getElementById('isBlocking').checked;
          setBlockFlag(document.getElementById('isBlocking').checked ? 1 : 0);
          updateGlobalVisibility()
      }
  }, true);

})();
x5 图片 x1 图片
上次由 supermassive 在 2025年 2月 23日 16:13 修改。
雅利安正牌婆罗门大厨
头像
F150
论坛元老
论坛元老
2023-24年度优秀版主
F150 的博客
帖子互动: 1008
帖子: 22098
注册时间: 2022年 7月 26日 10:47

Re: [bug警告]-屏蔽烦你的id插件

帖子 F150 »

站长还不来删帖封号?稍微一改就可以炸版了

勿谓言之不预也
头像
supermassive(泥橙)楼主
职业作家
职业作家
帖子互动: 6
帖子: 591
注册时间: 2022年 7月 31日 16:58

Re: [bug警告]-屏蔽烦你的id插件

帖子 supermassive(泥橙)楼主 »

F150 写了: 2022年 8月 9日 14:55 站长还不来删帖封号?稍微一改就可以炸版了

勿谓言之不预也
脑子是个好东西,建议长一个
雅利安正牌婆罗门大厨
头像
huangchong(净坛使者)
论坛元老
论坛元老
2023-24年度优秀版主
帖子互动: 3202
帖子: 53777
注册时间: 2022年 7月 22日 01:22

Re: [bug警告]-屏蔽烦你的id插件

帖子 huangchong(净坛使者) »

supermassive 写了: 2022年 8月 9日 14:11 从春卷老师的脚本改的,使用方法:
  • tampermonkey打开dashboard
  • 点+号,新建脚本,copy&paste
alpha版,只有部分功能且bug多多,专门针对某些不能屏蔽的版主

代码: 全选


    

    // ==UserScript==
    // @name         NewMitbbs-bot-blocker
    // @namespace    http://tampermonkey.net/
    // @version      0.1
    // @description  Manages and blocks bot generated content. Shamelessly modified from chunjuan's script at https://greasyfork.org/en/scripts/29195-mitbbs-bot-blocker/code, which was inspired by Smalltalk80's original GM script, http://userscripts-mirror.org/scripts/review/78633
    // @author       Sagittarius A*
    // @match        http://newmitbbs.com/*
    // @match        https://newmitbbs.com/*
    // @grant        GM_addStyle
    // @run-at       document-idle
    // ==/UserScript==
    // debugger;
    (function() {
      'use strict';

      var storageKey = 'new.mitbbs.blocklist';
      var pageType = locationGuesser();

      function locationGuesser() {
        var pageType = void 0;
        var url = window.location.href;
        if (url.indexOf('viewtopic') > -1) {
          pageType = 1;
        } else if (url.indexOf('viewforum') > -1) {
          pageType = -1;
        } else {
          pageType = 0;
        }

        return pageType;
      }

      function getBlocklist() {
        var blockList = localStorage.getItem(storageKey);
        console.log("inside getBlocklist: " + blockList);
        if (blockList === null) {
          setBlocklist([]);
          blockList = localStorage.getItem(storageKey);
        }

        try {
          blockList = JSON.parse(blockList);
        } catch (error) {
          blockList = [];
          setBlocklist(blockList);
        }

        blockList = Array.isArray(blockList) ? blockList : [];
        return blockList;
      }

      function setBlocklist(idNameList) {
        // remove duplicate items
        // todo: babel output for this one doesn't really work, have to revert back to old fashion way
        // idNameList = [...new Set(idNameList)]
        var uniqueidNameList = idNameList.filter(function (elem, index, self) {
          return index === self.indexOf(elem);
        });
        uniqueidNameList = uniqueidNameList.sort(function (a, b) {
          // defer from localeCompare for better browser support
          if (a.toLowerCase() < b.toLowerCase()) return -1;
          if (a.toLowerCase() > b.toLowerCase()) return 1;
          return 0;
        });
        localStorage.setItem(storageKey, JSON.stringify(uniqueidNameList));
        document.getElementById('blockListInput').value = uniqueidNameList;
      }

      function getBlockFlag() {
        var blockFlag = localStorage.getItem(storageKey + '.flag');
        if (blockFlag === null) {
          setBlockFlag(0);
          blockFlag = localStorage.getItem(storageKey + '.flag');
        }
        //  js, just being js
        return parseInt(blockFlag);
      }

      function setBlockFlag(flag) {
        localStorage.setItem(storageKey + '.flag', flag);
      }

      function changePostVisibility() {
        var blockList = getBlocklist();
        console.log("blockList:" + blockList)
        var flag = getBlockFlag();
        console.log("getBlockFlag: " + flag);
        // if list is not empty
        var counter = 0;
        if (blockList) {
          var taolunDiv = document.querySelector('div.forumbg:not(.announcement)');
          // yeah yeah yeah magic number, whatever
          // this will miss the first one though, nice try langfang coder
          var userIDtdNodeList = taolunDiv.querySelectorAll('li.row');
          console.log(userIDtdNodeList);
          userIDtdNodeList.forEach(function (td) {
            // damn, now i miss jquery/zepto
            var id = td.querySelector('div.topic-poster').querySelector('span.username').textContent;
            console.log(id);
            //  reset all reply to visible. This is a hack-ish method to fix content not being displayed after userID has been removed from blocklist.
            //  TODO: maybe in the near future, we should keep a local copy of blocklist so that we can compare the changes and show/hide content intelligently, maybe
            td.style.display = '';
            console.log(blockList);
            //  yeah, nested if statements
            if (blockList.indexOf(id) > -1) {
              if (flag) {
                console.log(td);
                td.style.display = 'none';
                counter += 1;
              } else {
                td.style.display = '';
              }
            }
          });
          counter = flag ? counter : 0;
          document.getElementById('blockCounter').innerHTML = counter;
        }
      }

      function changeReplyVisibility() {
        //  now we on individual post page
        var blockList = getBlocklist();
        var flag = getBlockFlag();
        var counter = 0;
        var sideBarBG = document.querySelectorAll('div.post.has-profile');
        sideBarBG.forEach(function (reply) {
          // var post = reply.parentElement.parentElement.parentElement.parentElement.parentElement;
          // //  another magic number!
          // var userMenu = post.querySelector('td.jiahui-4 td[width="83%"]');
          var userID = reply.querySelector('span.username').textContent;
          // var hasButton = userMenu.lastChild.innerHTML !== undefined;
          // if (!hasButton) {
          //   var blockButton = document.createElement('span');
          //   blockButton.setAttribute('class', 'buttonHolder');
          //   blockButton.innerHTML = '&nbsp;&nbsp;<button class="addToBlock" title="' + userID + '">屏蔽!</button>';
          //   userMenu.appendChild(blockButton);
          // }
          //  reset all reply to visible. This is a hack-ish method to fix content not being displayed after userID has been removed from blocklist.
          //  TODO: maybe in the near future, we should keep a local copy of blocklist so that we can compare the changes and show/hide content intelligently, maybe
          reply.style.display = '';

          if (blockList.indexOf(userID) > -1) {
            console.log("tag 1:" + userID);
            if (flag) {
              reply.style.display = 'none';
              counter += 1;
            } else {
              reply.style.display = '';
            }
          }
          counter = flag ? counter : 0;
          document.getElementById('blockCounter').innerHTML = counter;
        });

        var allBlockButton = document.querySelectorAll('.addToBlock');
        Array.from(allBlockButton).forEach(function (button) {
          var userID = button .getAttribute('title');
          button.addEventListener('click', function () {
            var yesBlock = confirm('Block ' + userID + ' ?');
            if (yesBlock) {
              blockList.push(userID);
              setBlocklist(blockList);
              document.getElementById('blockListInput').value = getBlocklist().join();
              toggleBlockedContent();
            }
          });
        });
      }

      function toggleBlockedContent() {
        document.getElementById('isBlocking').checked ? setBlockFlag(1) : setBlockFlag(0);
        switch (pageType) {
          case 1:
            changeReplyVisibility();
            break;
          case -1:
            changePostVisibility();
            break;
        }
      }

      function changeBlockListVisibility() {
        var notVisible = document.getElementById('blockListPop').style.display === 'none';
        if (notVisible) {
          document.getElementById('blockListInput').value = getBlocklist().join();
          document.getElementById('blockListPop').style.display = '';
        } else {
          updateBlockList();
          document.getElementById('blockListPop').style.display = 'none';
        }
      }

      function updateBlockList() {
        var newBlockList = document.getElementById('blockListInput').value;
        //  remove line break, space, trailing comma
        newBlockList = newBlockList.replace(/(\r\n|\n|\r)/gm, '').replace(/\s/g, '').replace(/,+$/, '');
        newBlockList = newBlockList.split(',');
        setBlocklist(newBlockList);

        // re-filter existing content
        toggleBlockedContent();
      }

      function hideBlockList() {
        document.getElementById('blockListPop').style.display = 'none';
      }

      function prepPage() {
        var flag = getBlockFlag();
        getBlocklist();
        if (flag) {
          document.getElementById('isBlocking').checked = true;
          toggleBlockedContent();
        }
      }

      function pageOnLoad() {
        //  build blocker control gui
        var blockerDiv = document.createElement('div');
        blockerDiv.innerHTML = '<button id="showBlocklist" class="button">黑名单</button><input type="checkbox" id="isBlocking" /><span id="blockCounter" title="Currently Blocked"></span>';
        blockerDiv.style.cssText = 'position:fixed; bottom:2em; right:0.5em; width:9em; padding:0.5em; border-radius:0.25em; background-color:#D7EAF9; box-shadow:2px 2px 4px 0px rgba(0,0,0,0.5); text-align:center; cursor:pointer;';
        document.body.appendChild(blockerDiv);

        document.getElementById('showBlocklist').addEventListener('click', changeBlockListVisibility);
        document.getElementById('blockCounter').style.cssText = 'padding:0 4px; font-weight:bold';
        document.getElementById('isBlocking').addEventListener('change', toggleBlockedContent);

        //  block list
        var blockListDiv = document.createElement('div');
        blockListDiv.setAttribute('id', 'blockListPop');
        blockListDiv.innerHTML = '<span>修改ID,用逗号分隔,大小写敏感!</span>' + '<br/>' + '<textarea rows="10" cols="40" id="blockListInput"></textarea>' + '<br/>' + '<button id="updateBlockList">Update</button><span style="width:2em"></span><button id="closePop">Close</button>';
        blockListDiv.style.cssText = 'position:fixed; bottom:5.3em; right:0.5em; padding:0.5em; border-radius:0.25em; background-color:#D7EAF9; box-shadow:2px 2px 4px 0px rgba(0,0,0,0.5); text-align:center; display:none';
        document.body.appendChild(blockListDiv);
        document.getElementById('updateBlockList').addEventListener('click', updateBlockList);
        document.getElementById('closePop').addEventListener('click', hideBlockList);

        prepPage();
      }

      function ready(fn) {
        if (document.readyState !== 'loading') {
          fn();
        } else {
          document.addEventListener('DOMContentLoaded', fn);
        }
      }

      ready(pageOnLoad);
      })();


这个bbs可以贴code 光这就比老邢的破系统强不知道哪里去了
头像
supermassive(泥橙)楼主
职业作家
职业作家
帖子互动: 6
帖子: 591
注册时间: 2022年 7月 31日 16:58

Re: [bug警告]-屏蔽烦你的id插件

帖子 supermassive(泥橙)楼主 »

huangchong 写了: 2022年 8月 9日 15:33 这个bbs可以贴code 光这就比老邢的破系统强不知道哪里去了
俺做的那个插件有个版本可以在老站写markdown,事实上也能嵌入code

但是并没卵用,没人用
雅利安正牌婆罗门大厨
头像
zeami(狼VP狈¿为奸)
论坛精英
论坛精英
2023年度十大优秀网友
帖子互动: 661
帖子: 6125
注册时间: 2022年 7月 25日 15:51

Re: [bug警告]-屏蔽烦你的id插件

帖子 zeami(狼VP狈¿为奸) »

supermassive 写了: 2022年 8月 9日 15:36 俺做的那个插件有个版本可以在老站写markdown,事实上也能嵌入code

但是并没卵用,没人用
老站强迫加空行。。
⚪︎ 辟邪剑法七折大酬宾~~
头像
supermassive(泥橙)楼主
职业作家
职业作家
帖子互动: 6
帖子: 591
注册时间: 2022年 7月 31日 16:58

Re: [bug警告]-屏蔽烦你的id插件

帖子 supermassive(泥橙)楼主 »

zeami 写了: 2022年 8月 9日 15:40 老站强迫加空行。。
阿米哥俺买的便宜火板今天寄到了
雅利安正牌婆罗门大厨
头像
zeami(狼VP狈¿为奸)
论坛精英
论坛精英
2023年度十大优秀网友
帖子互动: 661
帖子: 6125
注册时间: 2022年 7月 25日 15:51

Re: [bug警告]-屏蔽烦你的id插件

帖子 zeami(狼VP狈¿为奸) »

supermassive 写了: 2022年 8月 9日 15:42 阿米哥俺买的便宜火板今天寄到了
五个小时各种姿势装vpn,结果小国旗取消了。。
⚪︎ 辟邪剑法七折大酬宾~~
头像
supermassive(泥橙)楼主
职业作家
职业作家
帖子互动: 6
帖子: 591
注册时间: 2022年 7月 31日 16:58

Re: [bug警告]-屏蔽烦你的id插件

帖子 supermassive(泥橙)楼主 »

zeami 写了: 2022年 8月 9日 15:44 五个小时各种姿势装vpn,结果小国旗取消了。。
挺好,大家都别麻烦了

windscribe不错,免费的,俺有50GB/mo的账号
雅利安正牌婆罗门大厨
头像
zeami(狼VP狈¿为奸)
论坛精英
论坛精英
2023年度十大优秀网友
帖子互动: 661
帖子: 6125
注册时间: 2022年 7月 25日 15:51

Re: [bug警告]-屏蔽烦你的id插件

帖子 zeami(狼VP狈¿为奸) »

supermassive 写了: 2022年 8月 9日 15:46 挺好,大家都别麻烦了

windscribe不错,免费的,俺有50GB/mo的账号
现在不敢不麻烦了啊,不定哪天重新上线小旗。。
⚪︎ 辟邪剑法七折大酬宾~~
头像
huangchong(净坛使者)
论坛元老
论坛元老
2023-24年度优秀版主
帖子互动: 3202
帖子: 53777
注册时间: 2022年 7月 22日 01:22

Re: [bug警告]-屏蔽烦你的id插件

帖子 huangchong(净坛使者) »

supermassive 写了: 2022年 8月 9日 15:42 阿米哥俺买的便宜火板今天寄到了
什么火板? fireHD? 多少钱 多大?慢吗?
头像
supermassive(泥橙)楼主
职业作家
职业作家
帖子互动: 6
帖子: 591
注册时间: 2022年 7月 31日 16:58

Re: [bug警告]-屏蔽烦你的id插件

帖子 supermassive(泥橙)楼主 »

huangchong 写了: 2022年 8月 9日 16:16 什么火板? fireHD? 多少钱 多大?慢吗?
https://www.amazon.com/Fire-HD-10-tablet/dp/B08BX7FV5L

标准的2021版,MT8183 4x A73 +4x A55 3GB RAM,应该比snapdragon 835差一点点不多

呵呵你想要吗,俺可以给你原价分一台,我买了好几个
雅利安正牌婆罗门大厨
头像
huangchong(净坛使者)
论坛元老
论坛元老
2023-24年度优秀版主
帖子互动: 3202
帖子: 53777
注册时间: 2022年 7月 22日 01:22

Re: [bug警告]-屏蔽烦你的id插件

帖子 huangchong(净坛使者) »

supermassive 写了: 2022年 8月 9日 16:21 https://www.amazon.com/Fire-HD-10-tablet/dp/B08BX7FV5L

标准的2021版,MT8183 4x A73 +4x A55 3GB RAM,应该比snapdragon 835差一点点不多

呵呵你想要吗,俺可以给你原价分一台,我买了好几个
我有个老版本的 特别慢 不过其实看书还凑合
这东西好处是又便宜 又轻 又大 我给它装了个弹性布条的拉手 晚上 走路的时候看书特别合适

新的就不要了 我现在家里两个平板 两个笔记本 两个台式机 选择困难 非常严重
头像
supermassive(泥橙)楼主
职业作家
职业作家
帖子互动: 6
帖子: 591
注册时间: 2022年 7月 31日 16:58

Re: [bug警告]-屏蔽烦你的id插件

帖子 supermassive(泥橙)楼主 »

huangchong 写了: 2022年 8月 9日 16:32 我有个老版本的 特别慢 不过其实看书还凑合
这东西好处是又便宜 又轻 又大 我给它装了个弹性布条的拉手 晚上 走路的时候看书特别合适

新的就不要了 我现在家里两个平板 两个笔记本 两个台式机 选择困难 非常严重
玩过老版的,好像是4个a55(记错了,2x a72, 2x a53),性能差一些,记得当时电池特别好

后来就一直用tab s7,直到前几天trade in了

前天打折看到$55,没忍住跳了
雅利安正牌婆罗门大厨
头像
huangchong(净坛使者)
论坛元老
论坛元老
2023-24年度优秀版主
帖子互动: 3202
帖子: 53777
注册时间: 2022年 7月 22日 01:22

Re: [bug警告]-屏蔽烦你的id插件

帖子 huangchong(净坛使者) »

supermassive 写了: 2022年 8月 9日 16:36 玩过老版的,好像是4个a55(记错了,2x a72, 2x a53),性能差一些,记得当时电池特别好

后来就一直用tab s7,直到前几天trade in了

前天打折看到$55,没忍住跳了
是的 电池超长也是个特点
头像
zeami(狼VP狈¿为奸)
论坛精英
论坛精英
2023年度十大优秀网友
帖子互动: 661
帖子: 6125
注册时间: 2022年 7月 25日 15:51

Re: [bug警告]-屏蔽烦你的id插件

帖子 zeami(狼VP狈¿为奸) »

huangchong 写了: 2022年 8月 9日 16:32 我有个老版本的 特别慢 不过其实看书还凑合
这东西好处是又便宜 又轻 又大 我给它装了个弹性布条的拉手 晚上 走路的时候看书特别合适

新的就不要了 我现在家里两个平板 两个笔记本 两个台式机 选择困难 非常严重
晕,购物狂啊。我在工地曾经有过三个台式机一个手提,这就是设备巅峰时期了还不是自己买的
⚪︎ 辟邪剑法七折大酬宾~~
头像
huangchong(净坛使者)
论坛元老
论坛元老
2023-24年度优秀版主
帖子互动: 3202
帖子: 53777
注册时间: 2022年 7月 22日 01:22

Re: [bug警告]-屏蔽烦你的id插件

帖子 huangchong(净坛使者) »

zeami 写了: 2022年 8月 9日 16:59 晕,购物狂啊。我在工地曾经有过三个台式机一个手提,这就是设备巅峰时期了还不是自己买的
比不上超重
fhnan
论坛支柱
论坛支柱
2024年度优秀版主
帖子互动: 488
帖子: 11314
注册时间: 2022年 7月 29日 00:50

Re: [bug警告]-屏蔽烦你的id插件

帖子 fhnan »

zeami 写了: 2022年 8月 9日 15:44 五个小时各种姿势装vpn,结果小国旗取消了。。
才注意到 小国旗取消了。
怕人告站主侵犯隐私?
买买提纪检委书记 sex版版主
头像
huangchong(净坛使者)
论坛元老
论坛元老
2023-24年度优秀版主
帖子互动: 3202
帖子: 53777
注册时间: 2022年 7月 22日 01:22

Re: [bug警告]-屏蔽烦你的id插件

帖子 huangchong(净坛使者) »

fhnan 写了: 2022年 8月 9日 17:20 才注意到 小国旗取消了。
怕人告站主侵犯隐私?
系统版说 vpn来的没效果 还有点系统负担
头像
supermassive(泥橙)楼主
职业作家
职业作家
帖子互动: 6
帖子: 591
注册时间: 2022年 7月 31日 16:58

Re: [bug警告]-屏蔽烦你的id插件

帖子 supermassive(泥橙)楼主 »

huangchong 写了: 2022年 8月 9日 17:27 系统版说 vpn来的没效果 还有点系统负担
给网友看还是有效果的

比如俺前几天一直在印度
雅利安正牌婆罗门大厨
回复

回到 “肚皮舞运动(Joke)”