From b84cdcf7c6046b8d0c7d9fd292866e2ebc6a13ab Mon Sep 17 00:00:00 2001 From: sameerasw Date: Thu, 27 Feb 2025 23:09:40 +0530 Subject: updated pop-up footer --- background.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'background.js') diff --git a/background.js b/background.js index 3a8a958..067bad7 100644 --- a/background.js +++ b/background.js @@ -1,4 +1,4 @@ -let logging = true; +let logging = false; async function applyCSSToTab(tab) { if (logging) console.log("applyCSSToTab called with", tab); @@ -103,9 +103,9 @@ browser.tabs.onUpdated.addListener((tabId, changeInfo, tab) => { } }); -// browser.tabs.onActivated.addListener(async (activeInfo) => { -// if (logging) console.log("onActivated called with", activeInfo); -// // Apply CSS when a tab is activated -// const tab = await browser.tabs.get(activeInfo.tabId); -// applyCSSToTab(tab); -// }); +browser.tabs.onActivated.addListener(async (activeInfo) => { + if (logging) console.log("onActivated called with", activeInfo); + // Apply CSS when a tab is activated + const tab = await browser.tabs.get(activeInfo.tabId); + applyCSSToTab(tab); +}); -- cgit v1.2.3