summaryrefslogtreecommitdiff
path: root/popup/popup.js
diff options
context:
space:
mode:
Diffstat (limited to 'popup/popup.js')
-rw-r--r--popup/popup.js11
1 files changed, 11 insertions, 0 deletions
diff --git a/popup/popup.js b/popup/popup.js
index 82fc942..8feac4d 100644
--- a/popup/popup.js
+++ b/popup/popup.js
@@ -20,6 +20,7 @@ new (class ExtensionPopup {
skipForceThemingList = [];
reloadButton = document.getElementById("reload");
modeIndicator = document.getElementById("mode-indicator");
+ whatsNewButton = document.getElementById("whats-new");
constructor() {
if (logging) console.log("Initializing ExtensionPopup");
@@ -54,6 +55,9 @@ new (class ExtensionPopup {
this.handleWhitelistModeChange.bind(this)
);
+ // Add event listener for the "What's New" button
+ this.whatsNewButton.addEventListener("click", this.openWhatsNew.bind(this));
+
// Add event listener for the data viewer button
document.getElementById("view-data")?.addEventListener("click", () => {
browser.tabs.create({
@@ -546,4 +550,11 @@ new (class ExtensionPopup {
this.siteToggleLabel.textContent = "Skip Forcing for this Site";
}
}
+
+ // Open the What's New page
+ openWhatsNew() {
+ browser.tabs.create({
+ url: "https://addons.mozilla.org/en-US/firefox/addon/zen-internet/versions/",
+ });
+ }
})();