Add dark and light theme mode to docs, detection, and button
authorr3g_5z <june@girlboss.ceo>
Sat, 10 Dec 2022 03:49:25 +0000 (22:49 -0500)
committerr3g_5z <june@girlboss.ceo>
Sat, 10 Dec 2022 03:51:43 +0000 (22:51 -0500)
my eyes hurt

Signed-off-by: r3g_5z <june@girlboss.ceo>
docs/mkdocs.yml

index b554d3df3aacdf6b34cdf16863b4a7d125840eed..655abdd69bdf0cf530c486e117c47fc37de0ec80 100644 (file)
@@ -12,8 +12,21 @@ theme:
     - navigation.instant
     - navigation.sections
   palette:
-    primary: 'deep purple'
-    accent: 'blue grey'
+    - media: "(prefers-color-scheme: light)"
+      scheme: default
+      toggle:
+        icon: material/brightness-7
+        name: Switch to dark mode
+      primary: 'deep purple'
+      accent: 'blue grey'
+
+    - media: "(prefers-color-scheme: dark)"
+      scheme: slate
+      toggle:
+        icon: material/brightness-4
+        name: Switch to light mode
+      primary: 'deep purple'
+      accent: 'blue grey'
 
 extra_css:
   - css/extra.css