This commit is contained in:
panr 2019-02-01 15:53:23 +01:00
parent 8402237a8d
commit ab9bb3b3fb
2 changed files with 6 additions and 4 deletions

View file

@ -8,6 +8,7 @@ paginate = 5
contentTypeName = "post"
# "light" or "dark"
defaultTheme = "dark"
showMenuItems = 2
[languages]
[languages.en]
@ -15,6 +16,7 @@ paginate = 5
subtitle = "A simple theme for Hugo"
keywords = ""
copyright = ""
menuMore = "Show more"
writtenBy = "Written by"
readMore = "Read more"
readOtherPosts = "Read other posts"

View file

@ -6,8 +6,8 @@
<li><a href="{{ .URL }}">{{ .Name }}</a></li>
{{ end }}
{{ end }}
<ul class="menu__sub-inner">
{{ if gt (len $.Site.Menus.main) $.Site.Params.showMenuItems }}
{{ if gt (len $.Site.Menus.main) $.Site.Params.showMenuItems }}
<ul class="menu__sub-inner">
<li class="menu__sub-inner-more-trigger">{{ $.Site.Params.MenuMore }} <span class="menu__sub-inner-more-trigger-icon">></span></li>
<ul class="menu__sub-inner-more hidden">
@ -17,8 +17,8 @@
{{ end }}
{{ end }}
</ul>
{{ end }}
</ul>
</ul>
{{ end }}
{{ else }}
{{ range $.Site.Menus.main }}
{{ if not .HasChildren }}