Scrolller.com Adblocker

Blocks Ads and the Get Premium Popup

当前为 2023-09-19 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name Scrolller.com Adblocker
  3. // @name:de Scrolller.com Adblocker
  4. // @version 1.0.1
  5. // @description Blocks Ads and the Get Premium Popup
  6. // @description:de Blockiert Werbungen und das Get Premium Popup
  7. // @icon https://scrolller.com/assets/favicon-16x16.png
  8. // @author TalkLounge (https://github.com/TalkLounge)
  9. // @namespace https://github.com/TalkLounge/scrolller.com-adblocker
  10. // @license MIT
  11. // @match https://scrolller.com/*
  12. // @grant none
  13. // @run-at document-start
  14. // ==/UserScript==
  15.  
  16. (function () {
  17. 'use strict';
  18.  
  19. const s = document.createElement("style");
  20. s.innerHTML = `.popup {
  21. display: none;
  22. }`;
  23. document.head.append(s);
  24.  
  25.  
  26. const old_window_top_fetch = window.top.fetch;
  27.  
  28. window.top.fetch = function (...args) {
  29. if (args[1].body.indexOf("AffiliateQuery") != -1) {
  30. return;
  31. }
  32.  
  33. return old_window_top_fetch.apply(null, args);
  34. };
  35. })();