popup细节
Some checks failed
test / Run tests (push) Failing after 3s
build / Build (push) Failing after 5s

This commit is contained in:
2025-04-08 18:04:48 +08:00
parent 42975d47cf
commit d97a64c644
12 changed files with 166 additions and 126 deletions

View File

@ -9,8 +9,20 @@
// @grant GM_unregisterMenuCommand
// ==/UserScript==
const id = GM_registerMenuCommand("测试菜单", () => {
const id = GM_registerMenuCommand(
"测试菜单",
() => {
console.log(id);
GM_unregisterMenuCommand(id);
}, "h");
},
"h"
);
const id2 = GM_registerMenuCommand(
"测试菜单2",
() => {
console.log(id2);
GM_unregisterMenuCommand(id2);
},
"j"
);