Advertisement
Guest User

DLP Ignore++ v2_1

a guest
Dec 19th, 2019
43
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // ==UserScript==
  2. // @name         DLP Ignore++
  3. // @version      0.2
  4. // @description  Ignore harder than ever before
  5. // @author       BTT
  6. // @match        https://forums.darklordpotter.net/*
  7. // @grant        none
  8. // @require      https://d3js.org/d3.v4.min.js
  9. // ==/UserScript==
  10.  
  11. function ignoreUser(t){
  12.     if (t.attr("data-author") === "user1" || t.attr("data-author") === "Arthellion"){
  13.         t.style("display", "none");
  14.     }
  15. }
  16.  
  17. (function() {
  18.     'use strict';
  19.  
  20.     d3.selectAll(".message").each(function(d){ ignoreUser(d3.select(this)); });
  21.     d3.selectAll(".discussionListItem").each(function(d){ ignoreUser(d3.select(this)); });
  22.     var blockedIDs = ['bleh','blah'];
  23.     d3.selectAll(".PreviewTooltip").each(function(d){
  24.         var t = d3.select(this);
  25.         var threadnum = t.attr("href");
  26.         threadnum = threadnum.substring(threadnum.indexOf(".") + 1);
  27.         threadnum = threadnum.substring(0, threadnum.indexOf("/"));
  28.         if (blockedIDs.includes(threadnum)){
  29.             d3.select(this.parentNode.parentNode.parentNode.parentNode).style("display", "none");
  30.         }
  31.     });
  32. })();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement