hugo-battheme/layouts/_default/nav.html

23 lines
654 B
HTML
Raw Normal View History

2022-05-27 15:11:36 +00:00
{{ define "main" }}
<section id="main">
<header>
<h1 id="title" class="colorswitch">
<a href="../" class="colorswitch uplink">{{ .Title }}</a>
</h1>
</header>
<div>
<article id="content" class="colorswitch">
{{ .Content }}
<p>
<nav>
{{ $currentPage := . }}
{{ range .Site.Menus.nav }}
<a class="hamburger-nav-item{{if or ($currentPage.IsMenuCurrent "nav" .) ($currentPage.HasMenuCurrent "nav" .) }} active{{end}} colorswitch" href="{{ .URL }}" title="{{ .Title }}">{{ .Name }} {{ .Title }}</a>
{{ end }}
</nav>
</p>
</article>
</div>
</section>
{{ end }}