diff --git a/data/options/index.html b/data/options/index.html index 502ff2a..a8adaed 100644 --- a/data/options/index.html +++ b/data/options/index.html @@ -26,6 +26,9 @@
diff --git a/data/options/index.js b/data/options/index.js index b07e1cf..c5aae6e 100644 --- a/data/options/index.js +++ b/data/options/index.js @@ -8,6 +8,7 @@ function prepare(str) { function save() { chrome.storage.local.set({ + faqs: document.getElementById('faqs').checked, blacklist: prepare(document.getElementById('blacklist').value), whitelist: prepare(document.getElementById('whitelist').value), mode: document.getElementById('mode-blacklist').checked ? 'blacklist' : 'whitelist' @@ -22,10 +23,12 @@ function save() { function restore() { chrome.storage.local.get({ + faqs: true, mode: 'blacklist', whitelist: [], blacklist: [] }, prefs => { + document.getElementById('faqs').checked = prefs.faqs; document.getElementById('mode-blacklist').checked = prefs.mode === 'blacklist'; document.getElementById('mode-whitelist').checked = prefs.mode === 'whitelist'; document.getElementById('blacklist').value = prefs.blacklist.join(', ');