add a primary menu item that shows along side mobile menu button

This commit is contained in:
Ray Elliott 2020-02-21 15:39:45 +00:00
parent b7f14b8109
commit 72a92503e8
2 changed files with 13 additions and 0 deletions

View File

@ -108,4 +108,12 @@
} }
} }
} }
.primary-menu-item {
display: none;
@media only screen and (max-width: 768px) {
display: block;
margin-left: auto;
}
}
} }

View File

@ -4,6 +4,11 @@
{{ .Site.Title }} {{ .Site.Title }}
</a> </a>
{{ if or .Site.Menus.main .Site.IsMultiLingual }} {{ if or .Site.Menus.main .Site.IsMultiLingual }}
<span class="primary-menu-item">
{{ with index $.Site.Menus.main 0 }}
<a class="navigation-link" href="{{ .URL | absLangURL }}">{{ .Name }}</a>
{{ end }}
</span>
<input type="checkbox" id="menu-toggle" /> <input type="checkbox" id="menu-toggle" />
<label class="menu-button float-right" for="menu-toggle">{{ partial "svg/hamburger.svg" }}</label> <label class="menu-button float-right" for="menu-toggle">{{ partial "svg/hamburger.svg" }}</label>
<ul class="navigation-list"> <ul class="navigation-list">