2021-03-05 19:35:05 +01:00
|
|
|
{{- $currentPage := . }}
|
|
|
|
<header>
|
|
|
|
{{- range .Site.Menus.name }}
|
|
|
|
{{- if $currentPage.IsMenuCurrent "name" . }}
|
|
|
|
<h1> <a href="{{ .URL }}" class="active">{{ .Name }}</a> </h1>
|
|
|
|
{{- else }}
|
|
|
|
<h1> <a href="{{ .URL }}">{{ .Name }}</a> </h1>
|
2021-03-02 11:02:13 +01:00
|
|
|
{{- end }}
|
2021-03-05 19:35:05 +01:00
|
|
|
{{- end }}
|
2021-03-02 11:02:13 +01:00
|
|
|
<nav>
|
|
|
|
{{- range .Site.Menus.main }}
|
2021-03-05 19:35:05 +01:00
|
|
|
{{- if or ($currentPage.IsMenuCurrent "main" .) ($currentPage.HasMenuCurrent "main" .) -}}
|
|
|
|
<a href="{{ .URL }}" class="active">{{ .Name }}</a>
|
|
|
|
{{- else }}
|
2021-03-02 11:02:13 +01:00
|
|
|
<a href="{{ .URL }}">{{ .Name }}</a>
|
2021-03-05 19:35:05 +01:00
|
|
|
{{- end}}
|
2021-03-02 11:02:13 +01:00
|
|
|
{{- end }}
|
|
|
|
</nav>
|
|
|
|
</header>
|