Skip to content

Commit 3458c49

Browse files
committed
Replace page action with action
1 parent 7bbee9d commit 3458c49

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

extension/chrome/manifest.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@
2222
"devtools-remote": {
2323
"description": "Remote DevTools"
2424
},
25-
"_execute_page_action": {
25+
"_execute_action": {
2626
"suggested_key": {
27-
"default": "Ctrl+Shift+E"
27+
"default": "Ctrl+Shift+F"
2828
}
2929
}
3030
},

extension/src/background/index.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,10 @@ chrome.commands.onCommand.addListener((shortcut) => {
1212
openDevToolsWindow(shortcut as DevToolsPosition);
1313
});
1414

15-
// Create the context menu when installed
15+
// Disable the action by default and create the context menu when installed
1616
chrome.runtime.onInstalled.addListener(() => {
17+
chrome.action.disable();
18+
1719
syncOptions().get((option) => {
1820
if (option.showContextMenus) createMenu();
1921
});

extension/src/background/store/apiMiddleware.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -605,8 +605,8 @@ function onConnect<S, A extends Action<string>>(port: chrome.runtime.Port) {
605605
if (msg === 'heartbeat') return;
606606
if (msg.name === 'INIT_INSTANCE') {
607607
if (typeof id === 'number') {
608-
chrome.pageAction.show(id);
609-
chrome.pageAction.setIcon({ tabId: id, path: 'img/logo/38x38.png' });
608+
chrome.action.enable(id);
609+
chrome.action.setIcon({ tabId: id, path: 'img/logo/38x38.png' });
610610
}
611611
if (isMonitored) port.postMessage({ type: 'START' });
612612

0 commit comments

Comments
 (0)