Greasy Fork 还支持 简体中文。

Discord Server Scrollbar

Discord scrollbar, it is jank but it works.

  1. // ==UserScript==
  2. // @name Discord Server Scrollbar
  3. // @license GNU GPLv3
  4. // @namespace https://sea-salt-child.tumblr.com/
  5. // ^ Contact me there in case this implodes or something
  6. // @version 0.2
  7. // @description Discord scrollbar, it is jank but it works.
  8. // @author Nihil
  9. // @match https://discord.com/*
  10. // @icon https://i.imgur.com/wJ7cfJC.png
  11. // @grant none
  12. // @name:pt-BR Scrollbar para Discord
  13. // @description:pt-BR Scrollbar meio eh, mas funciona pra quem não tem mouse.
  14. // ==/UserScript==
  15.  
  16. function all(){
  17. var barra = document.getElementsByClassName("scroller-3X7KbA none-2-_0dP scrollerBase-_bVAAt")[0];
  18. var observer = new MutationObserver(function(mutations) {
  19. mutations.forEach(function(mutation) {
  20. console.log('mutation.type = ' + mutation.type);
  21. if (mutation.type === 'attributes') {
  22. document.getElementsByClassName("scroller-3X7KbA none-2-_0dP scrollerBase-_bVAAt")[0].setAttribute('class', 'scroller-1ox3I2 thin-31rlnD scrollerBase-_bVAAt fade-1R6FHN');
  23. }
  24. });
  25. });
  26.  
  27. document.getElementsByClassName("scroller-3X7KbA none-2-_0dP scrollerBase-_bVAAt")[0].setAttribute('class', 'scroller-1ox3I2 thin-31rlnD scrollerBase-_bVAAt fade-1R6FHN');
  28.  
  29. observer.observe(barra, {
  30. attributes: true
  31.  
  32. });
  33. }
  34. setTimeout (all, 2000);