hackertours/layouts/_partials/menu.html
Vincent Mahnke d3fc831bc5
Some checks failed
/ build (pull_request) Has been cancelled
/ accessibility (pull_request) Has been cancelled
feat: Applies 40c3 style to website
2026-11-07 10:40:22 +01:00

16 lines
837 B
HTML

{{- /* Nav row: the main menu, and the language switch on the right.
On small screens the theme's mobilemenu.js hides .main-menu and .header__region (it fails if
either is missing) and the mobile sheet shows both instead. */ -}}
<div class="nav-bar mx--xs layout__navigation">
<div class="nav-bar__row">
<nav class="main-menu" aria-label="{{ i18n "menu_title" }}">
<ul class="flex-inline mx--0">
{{ $currentPage := . -}}
{{ range site.Menus.main -}}
<li><a href="{{ .URL }}"{{ if or ($currentPage.IsMenuCurrent "main" .) ($currentPage.HasMenuCurrent "main" .) }} aria-current="page"{{ end }}>{{ .Pre }}<span>{{ or (i18n .Identifier) .Name | safeHTML }}</span>{{ .Post }}</a></li>
{{ end -}}
</ul>
</nav>
<div class="region header__region">{{ if hugo.IsMultilingual }}{{ partial "language-selector.html" . }}{{ end }}</div>
</div>
</div>