Make use of proper relURL everywhere so site works in sub directory. Fix for setting custom height in figure shortcode.
This commit is contained in:
parent
aca6312503
commit
73cc0bfc89
1 changed files with 21 additions and 12 deletions
|
|
@ -1,11 +1,12 @@
|
|||
{{ $home := relURL "/" }}
|
||||
{{ $currentSection := .Section }}
|
||||
{{ $currentID := .UniqueID }}
|
||||
<nav class="main-menu layout__navigation" role="navigation">
|
||||
<h2 class="visually-hidden">{{ i18n "menu_title" }}</h2>
|
||||
<ul class="navbar">
|
||||
<li><a class="{{ if .IsHome }}active{{ end }}" href="/">{{ i18n "menu_home" }}</a></li>
|
||||
<li><a class="{{ if .IsHome }}active{{ end }}" href="{{ $home }}">{{ i18n "menu_home" }}</a></li>
|
||||
{{ range where .Site.Pages "Section" "" -}}
|
||||
{{ if ne .RelPermalink "/" -}}
|
||||
{{ if ne .RelPermalink (string $home) -}}
|
||||
<li><a class="{{ if eq $currentID .UniqueID }}active{{ end }}" href="{{ .RelPermalink }}">{{ .Title }}</a></li>
|
||||
{{ end -}}
|
||||
{{ end -}}
|
||||
|
|
|
|||
Loading…
Reference in a new issue