#187, Use .Permalink for lang switch, align icons

This commit is contained in:
Alex Shpak 2020-04-03 17:42:48 +02:00
parent 6e146b1bf1
commit 1eeabcad67

View File

@ -9,7 +9,7 @@
<div class="book-languages" tabindex="0" aria-haspopup="true">
<ul>
<li class="flex">
<li class="flex align-center">
<img src="{{ "svg/translate.svg" | relURL }}" class="book-icon" alt="Languages" />
{{ $.Site.Language.LanguageName }}
</li>
@ -18,12 +18,11 @@
<ul class="book-languages-list">
{{ range .Site.Languages }}{{ with index $translations .Lang }}
<li class="{{ if (eq $.Site.Language .Language) }}active{{ end }}">
<a href="{{ .RelPermalink }}" class="flex">
<a href="{{ .Permalink }}" class="flex align-center">
<img src="{{ "svg/translate.svg" | relURL }}" class="book-icon" alt="Languages" />
{{ .Language.LanguageName }}
</a>
</li>
{{ end }}{{ end }}
</ul>
</div>