qq-docs Redirect Fix

Avoid link redirect for docs.qq.com

  1. // ==UserScript==
  2. // @name qq-docs Redirect Fix
  3. // @name:zh-CN 腾讯文档地址重定向
  4. // @description Avoid link redirect for docs.qq.com
  5. // @description:zh-CN 自动跳过网站安全性未知提示页面
  6.  
  7. // @author GallenHu
  8. // @namespace https://hgl2.com
  9. // @license MIT
  10. // @icon https://pub.idqqimg.com/pc/misc/files/20200904/2eb030216d9362bbc6c0df045857b718.png
  11.  
  12. // @grant none
  13. // @run-at document-end
  14. // @include https://docs.qq.com/scenario/link.html?url=*
  15.  
  16. // @date 03/15/2021
  17. // @modified 03/15/2021
  18. // @version 0.1.0
  19. // ==/UserScript==
  20.  
  21.  
  22. (function () {
  23. 'use strict';
  24.  
  25. let timer = null;
  26.  
  27. function checkLink() {
  28. const $linkWrapper = document.querySelector('.url-click');
  29. if ($linkWrapper) {
  30. const targetUrl = $linkWrapper.innerText;
  31. if (targetUrl) {
  32. clearInterval(timer);
  33. location.href = targetUrl.trim();
  34. }
  35. }
  36. }
  37.  
  38. timer = setInterval(checkLink, 100);
  39. })();

QingJ © 2025

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