Fix scrollbar on exploit-db

Fix for the scrollbar not appearing on exploit-db.

目前為 2021-01-03 提交的版本,檢視 最新版本

  1. // ==UserScript==
  2. // @name Fix scrollbar on exploit-db
  3. // @version 1
  4. // @grant none
  5. // @namespace StephenP
  6. // @description Fix for the scrollbar not appearing on exploit-db.
  7. // @author StephenP
  8. // @match https://www.exploit-db.com/*
  9. // @match https://www.exploit-db.com/
  10. // ==/UserScript==
  11. (function (){
  12. const config = { attributes: true, childList: false, subtree: false };
  13. const callback = function(mutationsList, observer) {
  14. for(const mutation of mutationsList) {
  15. setTimeout(function(){document.documentElement.classList.remove("perfect-scrollbar-on");},50);//direct execution would crash Greasemonkey, IDK why
  16. }
  17. };
  18. const observer = new MutationObserver(callback);
  19. observer.observe(document.documentElement, config);
  20. })();