commit 5682d7682a0464658f8795e287e86608d2ada9a9
parent 01478b70877edec2ab7d3684899a3bd5077e9a3d
Author: Shimmy Xu <shimmy.xu@shimmy1996.com>
Date: Sat, 30 Nov 2019 09:25:20 -0500
Adjust how menu space are inserted
Diffstat:
2 files changed, 6 insertions(+), 7 deletions(-)
diff --git a/README.org b/README.org
@@ -15,12 +15,12 @@ What is retained though is support for multilingual page contents. The result is
31 ./layouts/partials/css/style.css
1 ./layouts/partials/footer.html
0 ./layouts/partials/head_custom.html
- 17 ./layouts/partials/nav.html
+ 16 ./layouts/partials/nav.html
7 ./layouts/partials/head.html
4 ./layouts/_default/single.html
14 ./layouts/_default/list.html
11 ./layouts/_default/baseof.html
- 91 total
+ 90 total
#+END_EXAMPLE
** Customization
diff --git a/layouts/partials/nav.html b/layouts/partials/nav.html
@@ -1,12 +1,11 @@
<nav>
- <a href="{{ .Site.Home.Permalink | relURL }}"><b>{{ .Site.Title }}</b></a> |
- {{- range $i, $menu := .Site.Menus.main -}}
- {{- if (ge $i 1) -}} | {{- end -}}
- <a href="{{ $menu.URL | relURL }}">{{ $menu.Name }}</a>
+ <a href="{{ .Site.Home.Permalink | relURL }}"><b>{{ .Site.Title }}</b></a>
+ {{- range .Site.Menus.main -}}
+ | <a href="{{ .URL | relURL }}">{{ .Name }}</a>
{{- end -}}
{{- if .IsTranslated -}}
<span style="float:right;">
- [
+ [
{{- range $i, $page := .Translations -}}
{{- if (ge $i 1) }} | {{ end -}}
<a href="{{ $page.Permalink | relURL }}">{{ $page.Language.LanguageName }}</a>