DeleteLogoutButton

Delete Logout Button on bangumi

  1. // ==UserScript==
  2. // @name DeleteLogoutButton
  3. // @namespace https://jirehlov.com
  4. // @version 0.1
  5. // @description Delete Logout Button on bangumi
  6. // @author Jirehlov
  7. // @include /^https?://(bangumi\.tv|bgm\.tv|chii\.in)/.*
  8. // @grant none
  9. // @license MIT
  10. // ==/UserScript==
  11. (function () {
  12. 'use strict';
  13. const currentDomain = window.location.origin;
  14. const links = document.getElementsByTagName('a');
  15. for (let i = 0; i < links.length; i++) {
  16. const link = links[i];
  17. if (link.textContent === '登出' && link.href.startsWith(currentDomain + '/logout/')) {
  18. const previousSibling = link.previousSibling;
  19. if (previousSibling && previousSibling.nodeType === 3 && previousSibling.textContent.trim() === '|') {
  20. previousSibling.remove();
  21. }
  22. link.remove();
  23. }
  24. }
  25. }());

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址