summary refs log tree commit diff stats
path: root/nimdoc/rst2html
diff options
context:
space:
mode:
authorAmjad Ben Hedhili <amjadhedhili@outlook.com>2022-08-21 21:56:12 +0100
committerGitHub <noreply@github.com>2022-08-21 16:56:12 -0400
commit70a8e0d65c6ada01dac22b77873a0b6a9ea846b7 (patch)
tree72a3ca334c716555f9f24de7046b0db0d985cd03 /nimdoc/rst2html
parentd8d86e07c39be1d41f2d26eabc8cbdf87b799d8e (diff)
downloadNim-70a8e0d65c6ada01dac22b77873a0b6a9ea846b7.tar.gz
Docs auto dark mode (#20188)
* Implement auto dark mode

* Rename class

* Fix borders cutout

* Apply suggestions from code review

* Apply suggestions from code review

Co-authored-by: ringabout <43030857+ringabout@users.noreply.github.com>
Diffstat (limited to 'nimdoc/rst2html')
-rw-r--r--nimdoc/rst2html/expected/rst_examples.html13
1 files changed, 7 insertions, 6 deletions
diff --git a/nimdoc/rst2html/expected/rst_examples.html b/nimdoc/rst2html/expected/rst_examples.html
index efc8ac414..9debd16ac 100644
--- a/nimdoc/rst2html/expected/rst_examples.html
+++ b/nimdoc/rst2html/expected/rst_examples.html
@@ -27,12 +27,13 @@
       <h1 class="title">Not a Nim Manual</h1>
       <div class="row">
   <div class="three columns">
-    <div class="theme-switch-wrapper">
-      <label class="theme-switch" for="checkbox">
-        <input type="checkbox" id="checkbox" />
-        <div class="slider round"></div>
-      </label>
-      &nbsp;&nbsp;&nbsp; <em>Dark Mode</em>
+    <div class="theme-select-wrapper">
+      <label for="theme-select">Theme:&nbsp;</label>
+      <select id="theme-select" onchange="setTheme(this.value)">
+        <option value="auto">🌗 Match OS</option>
+        <option value="dark">🌑 Dark</option>
+        <option value="light">🌕 Light</option>
+      </select>
     </div>
     <div id="global-links">
       <ul class="simple">