Explorar el Código

new param: moveFooterToHeader

zwbetz-gh hace 4 años
padre
commit
78021345d9
Se han modificado 3 ficheros con 7 adiciones y 1 borrados
  1. 1 0
      exampleSite/config.yaml
  2. 3 1
      layouts/_default/baseof.html
  3. 3 0
      layouts/partials/header.html

+ 1 - 0
exampleSite/config.yaml

@@ -27,6 +27,7 @@ params:
   hideHeaderLinks: false
   search: true
   showThemeSwitcher: true
+  moveFooterToHeader: false
   customCss:
     - css/custom_01.css
     - css/custom_02.css

+ 3 - 1
layouts/_default/baseof.html

@@ -10,7 +10,9 @@
       <div class="main-and-footer">
         <div>
           {{ block "main" . }}{{ end }}
-          {{ partial "footer.html" . }}
+          {{ if ne .Site.Params.moveFooterToHeader true }}
+            {{ partial "footer.html" . }}
+          {{ end }}
         </div>
       </div>
     </div>

+ 3 - 0
layouts/partials/header.html

@@ -13,5 +13,8 @@
       </p>
     </div>
     {{ partial "nav.html" . }}
+    {{ if eq .Site.Params.moveFooterToHeader true }}
+      {{ partial "footer.html" . }}
+    {{ end }}
   </div>
 </header>