update theme-switcher functionality
This commit is contained in:
@@ -1,6 +1,9 @@
|
||||
<!doctype html>
|
||||
<html
|
||||
itemscope
|
||||
class="{{- if not site.Params.theme_switcher -}}
|
||||
{{- site.Params.theme_default -}}
|
||||
{{- end -}}"
|
||||
lang="{{ site.LanguageCode | default `en-US` }}"
|
||||
itemtype="http://schema.org/WebPage">
|
||||
<head>
|
||||
|
||||
@@ -34,7 +34,6 @@
|
||||
</div>
|
||||
|
||||
<!-- theme switcher -->
|
||||
{{ if site.Params.theme_switcher }}
|
||||
<script>
|
||||
var darkMode = {{if eq site.Params.theme_default "dark"}}true{{else}}false{{end}};
|
||||
|
||||
@@ -60,6 +59,4 @@
|
||||
});
|
||||
});
|
||||
</script>
|
||||
{{ end }}
|
||||
|
||||
{{ end }}
|
||||
|
||||
Reference in New Issue
Block a user