|
@@ -10,14 +10,14 @@
|
|
|
// @version 1.0
|
|
|
// @author tianyunperfect
|
|
|
// @require https://cdnjs.cloudflare.com/ajax/libs/axios/0.18.0/axios.min.js
|
|
|
-// @require http://www.tianyunperfect.cn:3001/tianyunperfect/web-base/raw/369c684a3d4f12d24ef0e6edacde733e3a6e2d00/tmp/monkey/util.js
|
|
|
+// @require http://www.tianyunperfect.cn:3001/tianyunperfect/web-base/raw/master/tmp/monkey/util.js
|
|
|
// @description 2021/1/30 下午7:09:51
|
|
|
// ==/UserScript==
|
|
|
|
|
|
(function () {
|
|
|
'use strict';
|
|
|
GM_registerMenuCommand("!!!复制并加到memory", to_memory)
|
|
|
- GM_registerMenuCommand("!!!复制标题和 url", myCopy(`${pre_str}<a href="${location.href}">${document.title}</a>`))
|
|
|
+ GM_registerMenuCommand("!!!复制标题和 url", copyTitle)
|
|
|
|
|
|
function to_memory() {
|
|
|
let url = location.href;
|
|
@@ -46,10 +46,14 @@
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ function copyTitle() {
|
|
|
+ myCopy(`<a href="${location.href}">${document.title}</a>`)
|
|
|
+ }
|
|
|
+
|
|
|
document.onkeydown = function (ev) {
|
|
|
if (ev.key === 'c' && ev.shiftKey) {
|
|
|
ev.preventDefault() // 关闭浏览器快捷键
|
|
|
- myCopy(`${pre_str}<a href="${location.href}">${document.title}</a>`)
|
|
|
+ copyTitle()
|
|
|
}
|
|
|
|
|
|
}
|