aboutsummaryrefslogtreecommitdiff
path: root/dst/scripts
diff options
context:
space:
mode:
authoradam <56338480+adastx@users.noreply.github.com>2022-08-30 18:41:42 +0200
committeradam <56338480+adastx@users.noreply.github.com>2022-08-30 18:41:42 +0200
commit28fbb2a85e15525292a3651f6f9d23d786de6f37 (patch)
treee836e35d8dead6ea7897ee445c68597e923c79a0 /dst/scripts
parentbdf9e3ea5034022d3c4ac9e588e5e6a07d2588ae (diff)
Removed generated html from repo
Diffstat (limited to 'dst/scripts')
-rw-r--r--dst/scripts/darktheme.js27
1 files changed, 0 insertions, 27 deletions
diff --git a/dst/scripts/darktheme.js b/dst/scripts/darktheme.js
deleted file mode 100644
index b44db9a..0000000
--- a/dst/scripts/darktheme.js
+++ /dev/null
@@ -1,27 +0,0 @@
-const themeButton = document.getElementById('darkmodetoggle');
-const theme = localStorage.getItem("theme");
-var isDark = false;
-
-if (theme) {
- setTheme(theme === "dark");
-} else if (window.matchMedia
- && window.matchMedia("(prefers-color-scheme: dark)").matches) {
- setTheme(true);
-}
-
-function setTheme(dark) {
- if (dark) {
- document.body.classList.add("dark-mode");
- themeButton.className = "fa fa-sun-o";
- localStorage.setItem("theme", "dark");
- } else {
- document.body.classList.remove("dark-mode");
- themeButton.className = "fa fa-moon-o";
- localStorage.setItem("theme", "light");
- }
- isDark = dark;
-}
-
-function switchTheme() {
- setTheme(!isDark);
-}