Skip to content

Commit

Permalink
add dark theme for nimbus.guide (#5564)
Browse files Browse the repository at this point in the history
  • Loading branch information
narimiran authored Nov 10, 2023
1 parent f388d76 commit 1bbd628
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 4 deletions.
18 changes: 14 additions & 4 deletions docs/the_nimbus_book/mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,20 @@ theme:
- navigation.top
- content.tabs.link
palette:
scheme: default
primary: orange
accent: amber
- scheme: default
primary: orange
accent: amber
toggle:
icon: material/brightness-7
name: Switch to dark mode
- scheme: slate
primary: black
accent: light blue
toggle:
icon: material/brightness-4
name: Switch to light mode
extra_css:
- stylesheets/extra.css

# Support urls previously used by mdbook
use_directory_urls: false
Expand All @@ -29,7 +40,6 @@ docs_dir: src

markdown_extensions:
- admonition
- meta
- pymdownx.details
- pymdownx.highlight:
anchor_linenums: true
Expand Down
6 changes: 6 additions & 0 deletions docs/the_nimbus_book/src/stylesheets/extra.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[data-md-color-scheme="slate"] {
--md-hue: 180;
--md-default-bg-color: hsla(var(--md-hue), 0%, 0%, 1);
--md-footer-bg-color: hsla(var(--md-hue), 0%, 0%, 1);
--md-footer-bg-color--dark: hsla(var(--md-hue), 0%, 0%, 1);
}

0 comments on commit 1bbd628

Please sign in to comment.