jk.nipponalba.scot website https://jk.nipponalba.scot
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

27 lines
1.2 KiB

5 years ago
  1. <div class="page-top">
  2. <div class="nav">
  3. {{ $currentPage := . }}
  4. {{ range .Site.Menus.main }}
  5. <li id="{{ .Name }}"><a {{if or ($currentPage.IsMenuCurrent "main" .) ($currentPage.HasMenuCurrent "main" .) }}class="current"{{end}} href="{{ .URL }}" title="{{ .Name }}">{{ .Name }}</a></li>
  6. {{ end }}
  7. </div>
  8. <div class="selectors">
  9. <div class="theme-selector float-right"><label for="theme-switch"><i class="fa fa-adjust fa-2x light" aria-hidden="true" title="light/dark mode switch"></i></label></div>
  10. <div class="language-selector layout__language-selector float-right">
  11. <ul>
  12. {{ if .IsTranslated }}
  13. {{ range .Translations }}
  14. <li><a rel="alternate" href="{{ .RelPermalink }}" hreflang="{{ .Lang }}" lang="{{ .Lang }}">{{ .Language.LanguageName }}<i class="fa fa-language fa-2x language" aria-hidden="true" title="Language"></i></a></li>
  15. {{ end }}
  16. {{ else }}
  17. {{ range .Site.Languages }}
  18. {{ if ne $.Site.Language.Lang .Lang }}
  19. <li><a rel="alternate" href="{{ .Lang | relURL }}" hreflang="{{ .Lang }}" lang="{{ .Lang }}">{{ .LanguageName }} <i class="fa fa-language fa-2x language" aria-hidden="true" title="言語"></i></a></li>
  20. {{ end }}
  21. {{ end }}
  22. {{ end }}
  23. </ul>
  24. </div>
  25. </div>
  26. </div>