diff --git a/assets/css/custom.css b/assets/css/custom.css index c6131fc..98cdfa1 100644 --- a/assets/css/custom.css +++ b/assets/css/custom.css @@ -1,4 +1,9 @@ -body { +dark-mode-toggle { + --dark-mode-toggle-dark-icon: url("/wp-content/moon.png"); + --dark-mode-toggle-dark-icon: url("/wp-content/moon.png"); +} + +body.light { background: #fffcf5; } @@ -26,21 +31,22 @@ a[rel*="external"]::after { nav a { padding: 2px; } -nav a.active { +.light nav a.active { background-color: inherit; color: #000; } -a { +.light a { color: #422eff; border-bottom: 1px solid #00ff9c; } -a:hover { +.light a:hover { color: #000; background-color: #00ff9c; } .muted, .help-block { opacity: 0.70; } +.light .hack .muted, .hack .help-block { color: #0e0e0e; diff --git a/config.toml b/config.toml index f508446..b843966 100644 --- a/config.toml +++ b/config.toml @@ -27,7 +27,7 @@ footnoteReturnLinkContents = "↩" # Provides a nicer footnote return link has_cookies = true # Optional, set true to disable cookie disclaimer disable_csp = false # Optional, set true to disable content security policy images = [ - "https://source.unsplash.com/collection/983219/2000x1322" + "https://rohanverma.net/wp-content/uploads/me.jpg" ] # Suggested, controls default Open Graph images [params.layout.menu.main] diff --git a/content/wp-content/moon.png b/content/wp-content/moon.png new file mode 100644 index 0000000..9c30223 Binary files /dev/null and b/content/wp-content/moon.png differ diff --git a/content/wp-content/sun.png b/content/wp-content/sun.png new file mode 100644 index 0000000..c44a435 Binary files /dev/null and b/content/wp-content/sun.png differ diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index 0339bde..c335ac9 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -57,6 +57,7 @@ {{ $hackcss_mode := .Site.Params.hackcss.mode | default "hack" }} {{ $hackcss_palette := .Site.Params.hackcss.palette | default "dark" }}
+ {{ partial "body/darkmode.html" . }}