From 509ef5c3d68ababee0c97f4caa931a55f9836f7f Mon Sep 17 00:00:00 2001 From: Chris Short Date: Thu, 30 Nov 2023 19:17:05 +0000 Subject: [PATCH] header tweaking --- layouts/partials/header.html | 156 +++++++++++++++++++++++++++++++++++ 1 file changed, 156 insertions(+) create mode 100644 layouts/partials/header.html diff --git a/layouts/partials/header.html b/layouts/partials/header.html new file mode 100644 index 00000000..1a5b40af --- /dev/null +++ b/layouts/partials/header.html @@ -0,0 +1,156 @@ +{{- /* theme-toggle is enabled */}} +{{- if (not .Site.Params.disableThemeToggle) }} +{{- /* theme is light */}} +{{- if (eq .Site.Params.defaultTheme "light") }} + +{{- /* theme is dark */}} +{{- else if (eq .Site.Params.defaultTheme "dark") }} + +{{- else }} +{{- /* theme is auto */}} + +{{- end }} +{{- /* theme-toggle is disabled and theme is auto */}} +{{- else if (and (ne .Site.Params.defaultTheme "light") (ne .Site.Params.defaultTheme "dark"))}} + +{{- end }} + +
+ +