This commit is contained in:
lmm214
2022-10-12 19:52:06 +08:00
parent 289510c052
commit 453863d16e
6 changed files with 17 additions and 41 deletions
-18
View File
@@ -1,18 +0,0 @@
chrome.contextMenus.create({
title: "记下 “%s”",
contexts: ['selection'],
onclick: function(info, tab){
//设定打开页面的一些初始值
console.log(info);
chrome.storage.sync.set({open_action: "save_text",open_content:info.selectionText}, function() {
chrome.windows.create({
url: chrome.extension.getURL("html/popup.html"),
left: 50,
top: 50,
width: 550,
height: 300,
type: "popup"
});
});
}
});