diff options
author | Fredrik Jonsson <frjo@xdeb.org> | 2022-09-12 17:19:51 +0300 |
---|---|---|
committer | Fredrik Jonsson <frjo@xdeb.org> | 2022-09-12 17:19:51 +0300 |
commit | 35443bce5c4cf0a970eba3912057cd900b6e6155 (patch) | |
tree | bf29c4edad91d81e3d6d9ac8cda30b45f4ecf29a | |
parent | 4d3658251f4e860b5424f2c36f4147a8b36022f1 (diff) |
Add setting menuInHeader to allow the manin menu to be moved to the header.
-rw-r--r-- | README.md | 1 | ||||
-rw-r--r-- | layouts/_default/baseof.html | 3 |
2 files changed, 3 insertions, 1 deletions
@@ -227,6 +227,7 @@ params: mainSections: # The sections you want to have listed on the front page. - "section1" # Default to the section with most content if not set. - "section2" # Set to empty if no section should be listed. + menuInHeader: true # Move the main menu to the header, default false. microUsername: "" # Your micro.blog username. mobileMenu: true # Turn on a mobile menu on small screens, default false. piwikSiteId: # Matamo site id diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index 7c00a8b..e5210e5 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -21,10 +21,11 @@ </h1> <div class="region header__region"> {{ if site.IsMultiLingual }}{{ partial "language-selector.html" . }}{{ end -}} +{{ if $.Param "menuinheader" }}{{ partial "menu.html" . }}{{ end -}} </div> </header> -{{ partial "menu.html" . }} +{{ if not ($.Param "menuinheader") }}{{ partial "menu.html" . }}{{ end -}} {{ block "main" . }}{{ end }} |