browser.action.onClicked.addListener((tab) => { // Inject the CSS for the hover highlight browser.scripting.insertCSS({ target: { tabId: tab.id }, files: ["content.css"] }); // Inject the JavaScript for the element picker browser.scripting.executeScript({ target: { tabId: tab.id }, files: ["content.js"] }); });