您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Greasy Fork is available in English.
识别任意BT网站的磁力链接,双击即可快速复制[hahacium(GitHub)]
当前为
// ==UserScript== // @name Bt磁力复制 // @namespace http://tampermonkey.net/ // @version 0.1 // @description 识别任意BT网站的磁力链接,双击即可快速复制[hahacium(GitHub)] // @author hahacium(GitHub) // @grant none // @include *.bturl.pw/* // @include *.btrabbit.xyz/* // @include *.bteat.com/* // @include *btdiggs.org/* // ==/UserScript== (function() { 'use strict'; var cli=document.getElementsByTagName("a"); for(var i=0;i<cli.length;i++){ var urlRgx=/^magnet:\?xt=urn:btih:.*$/; if(urlRgx.test(cli[i].getAttribute("href"))) { var ok=cli[i].getAttribute("href"); document.ondblclick=function(){ var input = document.createElement('input'); document.body.appendChild(input); input.setAttribute('value', ok); input.select(); if (document.execCommand("copy")) { document.execCommand("copy"); } input.style.cssText="display: none;"; var div = document.createElement('div'); document.body.appendChild(div); div.style.cssText="width:0px;height:40px;color:#fff;background-color:#12709e;font-size:17px;text-align:center;transition:width .2s,height .2s,transform .2s;border-radius:5px;position:fixed;top:20%;right:0;display:flex;justify-content:center;align-items:center;"; div.innerHTML='<span style="height:60%;overflow:hidden">复制成功</span>'; setTimeout( function(){ div.style.cssText+="width: 120px;"; }, 10 ); setTimeout( function(){ div.style.cssText+="width: 0px;"; }, 1000 ); } break; } } })();