Support menu items from frontmatter and config (see gohugoio/hugo/#4995)

This commit is contained in:
Tamara Cook 2023-01-21 12:25:45 +01:00
parent 315a00623c
commit c53f4f12bc
No known key found for this signature in database
GPG Key ID: 8A117123223D268A

View File

@ -13,7 +13,7 @@
<ul class="{{ cond (eq $.Site.Language.LanguageDirection "rtl") "pr0 ml3" "pl0 mr3" }}"> <ul class="{{ cond (eq $.Site.Language.LanguageDirection "rtl") "pr0 ml3" "pl0 mr3" }}">
{{ range .Site.Menus.main }} {{ range .Site.Menus.main }}
<li class="list f5 f4-ns fw4 dib {{ cond (eq $.Site.Language.LanguageDirection "rtl") "pl3" "pr3" }}"> <li class="list f5 f4-ns fw4 dib {{ cond (eq $.Site.Language.LanguageDirection "rtl") "pl3" "pr3" }}">
<a class="hover-white no-underline white-90" href="{{ .URL }}" title="{{ i18n "pageTitle" . }}"> <a class="hover-white no-underline white-90" href="{{ with .Page }}{{ .RelPermalink }}{{ else }}{{ .URL | relLangURL }}{{ end }}" title="{{ i18n "pageTitle" . }}">
{{ .Name }} {{ .Name }}
</a> </a>
</li> </li>