This commit is contained in:
parent
6e613d7b15
commit
5992869fd3
93 changed files with 9485 additions and 1277 deletions
24
themes/archie/layouts/partials/head.html
Normal file
24
themes/archie/layouts/partials/head.html
Normal file
|
@ -0,0 +1,24 @@
|
|||
{{- define "feathericon" -}}
|
||||
{{- $featherURL := "https://unpkg.com/feather-icons@4.29.2/dist/feather-sprite.svg" -}}
|
||||
{{ if not (.UseCDN | default false) -}}
|
||||
{{- $featherURL = (resources.Get "svg/feather-sprite.svg" | fingerprint).RelPermalink -}}
|
||||
{{- end -}}
|
||||
<svg class="feather">
|
||||
<use href="{{ printf "%s#%s" $featherURL .Icon }}" />
|
||||
</svg>
|
||||
{{- end -}}
|
||||
|
||||
<header>
|
||||
<div class="main">
|
||||
<a href="{{ absLangURL "/" }}">{{ .Site.Title }}</a>
|
||||
</div>
|
||||
<nav>
|
||||
{{ range .Site.Menus.main }}
|
||||
<a href="{{ .URL }}">{{ .Name }}</a>
|
||||
{{ end }}
|
||||
{{ if eq .Site.Params.mode "toggle" -}}
|
||||
| <span id="dark-mode-toggle" onclick="toggleTheme()">{{template "feathericon" (dict "UseCDN" .Site.Params.useCDN "Icon" "sun") }}</span>
|
||||
<script src="{{ absURL "js/themetoggle.js" }}"></script>
|
||||
{{ end }}
|
||||
</nav>
|
||||
</header>
|
Loading…
Add table
Add a link
Reference in a new issue