Added theme selector to the posts navbar.
This commit is contained in:
parent
2ccdb57c26
commit
45361fc63e
5 changed files with 6 additions and 13 deletions
|
@ -18,11 +18,6 @@
|
||||||
|
|
||||||
<div class="container-fluid bg-dimmed wrapper">
|
<div class="container-fluid bg-dimmed wrapper">
|
||||||
|
|
||||||
<!-- INITIALIZE DARK THEME -->
|
|
||||||
{{ if site.Params.darkTheme.enable }}
|
|
||||||
{{ partial "helpers/darkmode.html" }}
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
<!----- ADD NAVBAR --------------->
|
<!----- ADD NAVBAR --------------->
|
||||||
{{ block "navbar" . }} {{ end }}
|
{{ block "navbar" . }} {{ end }}
|
||||||
|
|
||||||
|
|
|
@ -34,11 +34,6 @@
|
||||||
</head>
|
</head>
|
||||||
<body data-spy="scroll" data-target="#top-navbar" data-offset="100">
|
<body data-spy="scroll" data-target="#top-navbar" data-offset="100">
|
||||||
|
|
||||||
<!-- INITIALIZE DARK THEME -->
|
|
||||||
{{ if site.Params.darkTheme.enable }}
|
|
||||||
{{ partial "helpers/darkmode.html" }}
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
<!--- NAVBAR ------------------------->
|
<!--- NAVBAR ------------------------->
|
||||||
{{- partial "navigators/navbar.html" . -}}
|
{{- partial "navigators/navbar.html" . -}}
|
||||||
|
|
||||||
|
|
|
@ -1,3 +0,0 @@
|
||||||
<!-- This is a 'hack' for initializing the color scheme selection. See /js/darkmode.js -->
|
|
||||||
<div id="themeInitialization" style="display: none;"
|
|
||||||
default-theme=" {{ site.Params.darkTheme.default }} "></div>
|
|
|
@ -47,6 +47,9 @@
|
||||||
{{ if .IsTranslated }}
|
{{ if .IsTranslated }}
|
||||||
{{ partial "navigators/lang-selector-2.html" . }}
|
{{ partial "navigators/lang-selector-2.html" . }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
{{ if site.Params.darkTheme.enable }}
|
||||||
|
{{ partial "navigators/theme-selector.html" . }}
|
||||||
|
{{ end }}
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,4 +1,7 @@
|
||||||
<li class="nav-item dropdown">
|
<li class="nav-item dropdown">
|
||||||
|
<!-- This is a 'hack' for initializing the color scheme selection. See /js/darkmode.js -->
|
||||||
|
<div id="themeInitialization" style="display: none;"
|
||||||
|
default-theme=" {{ site.Params.darkTheme.default }} "></div>
|
||||||
<a class="nav-link dropdown-toggle" href="#" id="themeSelector" role="button"
|
<a class="nav-link dropdown-toggle" href="#" id="themeSelector" role="button"
|
||||||
data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Theme</a>
|
data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">Theme</a>
|
||||||
<div class="dropdown-menu" aria-labelledby="themeSelector">
|
<div class="dropdown-menu" aria-labelledby="themeSelector">
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue