- commit
- a5b8ff4690fa559667116fd44d47f63e6908cf22
- parent
- 6cf01e07e35afbe3f4657c6bac7fc173c4110ccd
- Author
- Tobias Bengfort <tobias.bengfort@posteo.de>
- Date
- 2025-10-04 20:55
only close popup on toplevel navigation
Diffstat
| M | src/popup.js | 6 | +++++- |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/popup.js b/src/popup.js
@@ -153,7 +153,11 @@ const loadContext = async function() {
153 153 updateInherit('*');
154 154 };
155 155
156 -1 browser.webNavigation.onBeforeNavigate.addListener(window.close);
-1 156 browser.webNavigation.onBeforeNavigate.addListener(details => {
-1 157 if (details.parentFrameId === -1) {
-1 158 window.close();
-1 159 }
-1 160 });
157 161
158 162 document.querySelector('[name="settings"]').addEventListener('click', () => {
159 163 browser.runtime.openOptionsPage();