aboutsummaryrefslogtreecommitdiff
path: root/static/js/theme.js
diff options
context:
space:
mode:
authorJieiku2023-07-19 13:32:33 -0700
committerJieiku2023-07-19 13:32:33 -0700
commitcd71559564732e4f2b4752560ff1b6de6f737a79 (patch)
treef3fb6331389806a8c384c2d3459a125df61c34e0 /static/js/theme.js
parent65f135a6a2f7be105bfe9ce95796b2314627b20d (diff)
downloadabridge-cd71559564732e4f2b4752560ff1b6de6f737a79.tar.gz
abridge-cd71559564732e4f2b4752560ff1b6de6f737a79.tar.bz2
abridge-cd71559564732e4f2b4752560ff1b6de6f737a79.zip
nojs configurable default switcher theme
Diffstat (limited to 'static/js/theme.js')
-rw-r--r--static/js/theme.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/static/js/theme.js b/static/js/theme.js
index 5f6f0f6..ec10638 100644
--- a/static/js/theme.js
+++ b/static/js/theme.js
@@ -1,4 +1,4 @@
// enforce local storage setting but also fallback to user-agent preferences
-if (localStorage.getItem('theme') === 'light' || (!localStorage.getItem('theme') && !window.matchMedia("(prefers-color-scheme: dark)").matches)) {
- document.documentElement.classList.add('light');
+if (localStorage.getItem('theme') === 'switch' || (!localStorage.getItem('theme') && !window.matchMedia("(prefers-color-scheme: dark)").matches)) {
+ document.documentElement.classList.add('switch');
}