set the side panel's trigger behavior

Add the module "user_actions.js" to the GUI scripts folder. This module will handle the user's actions, such as opening the side panel.
This commit is contained in:
buzz-lightsnack-2007 2024-04-22 16:40:24 +08:00
parent 2bd5310e40
commit 12f9562aa6
2 changed files with 9 additions and 0 deletions

View file

@ -0,0 +1,7 @@
export default class user_actions {
static init() {
chrome.sidePanel
.setPanelBehavior({ openPanelOnActionClick: true })
.catch((error) => console.error(error));
};
};

View file

@ -3,5 +3,7 @@ Shop wisely with AI!
*/
import fc from './fc.js';
import user_actions from "./GUI/user_actions.js";
fc.run();
user_actions.init();