feat: Nouveau design
This commit is contained in:
@ -1,31 +1,23 @@
|
||||
<div class="container-header">
|
||||
<div class="container grid-xl">
|
||||
<header class="navbar navbar-main">
|
||||
<section class="navbar-section">
|
||||
<header class="header">
|
||||
{{ $headless := .Site.GetPage "/" }}
|
||||
{{ $image := $headless.Resources.GetMatch "*" }}
|
||||
{{ $resized := $image.Fill "1400x600 Top"}}
|
||||
<img class="hero" src="{{ $resized.RelPermalink }}" alt="{{ .Title }}" />
|
||||
<nav class="nav">
|
||||
<ol>
|
||||
<li class="logo">
|
||||
<a href="/" class="">
|
||||
<img src="logo.png" alt="Blason de Crémeaux" height="80" />
|
||||
<img src="/icons/logo.jpg" alt="Blason de Crémeaux" />
|
||||
</a>
|
||||
</section>
|
||||
<section class="navbar-center">
|
||||
{{ range .Site.Menus.main }}
|
||||
<a href="{{ .URL }}" class="m-2 btn btn-primary {{ .Identifier }} {{ .Pre }}">{{ .Name }}</a>
|
||||
{{ end }}
|
||||
</section>
|
||||
</header>
|
||||
</div>
|
||||
{{ $currentPage := . }}
|
||||
{{ range .Site.Menus.main }}
|
||||
{{if or ($currentPage.IsMenuCurrent "main" .) ($currentPage.HasMenuCurrent "main" .) }}
|
||||
{{ if .HasChildren }}
|
||||
<header class="navbar navbar-submenu">
|
||||
<section class="navbar-center btn-group btn-group-block">
|
||||
{{ $color := .Pre }}
|
||||
{{ range .Children }}
|
||||
<a class="btn {{if $currentPage.IsMenuCurrent "main" .}}btn-primary{{else}}btn-link{{end}} {{$color}}" href="{{ .URL }}">{{ .Name }}</a>
|
||||
<li>
|
||||
{{ range .Site.Menus.main }}
|
||||
<li class="link">
|
||||
<a href="{{ .URL }}" class="m-2 btn btn-primary {{ .Pre }}">
|
||||
<img src="/icons/{{ .Identifier }}.jpg" alt="{{ .Name }}" />
|
||||
<span>{{ .Name }}</span>
|
||||
</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
</section>
|
||||
</header>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</div>
|
||||
</ol>
|
||||
</nav>
|
||||
</header>
|
||||
|
Reference in New Issue
Block a user