about summary refs log tree commit diff stats
path: root/pages/popup/popup.js
diff options
context:
space:
mode:
authorSimonBrazell <simon@brazell.com.au>2019-09-29 23:04:24 +1000
committerSimonBrazell <simon@brazell.com.au>2019-10-01 23:21:26 +1000
commit68accaac583f09e2c4cabda29315218234af722d (patch)
tree60207b46e90dc5e5d646e9212074a1d25f8438af /pages/popup/popup.js
parentAdd screenshots for store (diff)
downloadlibredirect-68accaac583f09e2c4cabda29315218234af722d.zip
Add popup & options pages
Diffstat (limited to 'pages/popup/popup.js')
-rw-r--r--pages/popup/popup.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/pages/popup/popup.js b/pages/popup/popup.js
new file mode 100644
index 00000000..0dddb49c
--- /dev/null
+++ b/pages/popup/popup.js
@@ -0,0 +1,7 @@
+document.querySelector('#options').addEventListener('click', function () {
+  if (chrome.runtime.openOptionsPage) {
+    chrome.runtime.openOptionsPage();
+  } else {
+    window.open(chrome.runtime.getURL('../options/options.html'));
+  }
+});
\ No newline at end of file