Upload files to "Pricer Extension"
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
const ext = typeof browser !== "undefined" ? browser : chrome;
|
||||
|
||||
document.getElementById('arm-scanner').addEventListener('click', async () => {
|
||||
try {
|
||||
const tabs = await ext.tabs.query({ active: true, currentWindow: true });
|
||||
const tab = tabs[0];
|
||||
|
||||
await ext.tabs.sendMessage(tab.id, { action: "ARM_SCANNER" });
|
||||
|
||||
window.close();
|
||||
} catch (err) {
|
||||
console.error("Error sending message:", err);
|
||||
}
|
||||
});
|
||||
Reference in New Issue
Block a user