Merge pull request #34 from memclutter/set-abs-lang-url
Added support for i18n url in main menu
This commit is contained in:
commit
10dcb7a324
2 changed files with 2 additions and 2 deletions
|
@ -5,7 +5,7 @@
|
||||||
{{ $data := .Data }}
|
{{ $data := .Data }}
|
||||||
{{ range $key, $value := .Data.Terms.ByCount }}
|
{{ range $key, $value := .Data.Terms.ByCount }}
|
||||||
<div class="mb-5 flex justify-between">
|
<div class="mb-5 flex justify-between">
|
||||||
<a class="self-start" href="/{{ $data.Plural }}/{{ $value.Name }}">
|
<a class="self-start" href="{{ $data.Plural | absLangURL }}/{{ $value.Name }}">
|
||||||
{{ $value.Name }}
|
{{ $value.Name }}
|
||||||
</a>
|
</a>
|
||||||
<span class="">{{ $value.Count }}</span>
|
<span class="">{{ $value.Count }}</span>
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
<nav class="flex items-center
|
<nav class="flex items-center
|
||||||
whitespace-nowrap overflow-x-auto overflow-y-hidden">
|
whitespace-nowrap overflow-x-auto overflow-y-hidden">
|
||||||
{{ range .Site.Menus.main }}
|
{{ range .Site.Menus.main }}
|
||||||
<a class="ml-5" href="{{ .URL }}">{{ .Name }}</a>
|
<a class="ml-5" href="{{ .URL | absLangURL }}">{{ .Name }}</a>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
</nav>
|
</nav>
|
||||||
</header>
|
</header>
|
Loading…
Reference in a new issue