From 3b52fc46e469babfa48732605d635ba4611bde2e Mon Sep 17 00:00:00 2001 From: Stefan M Date: Tue, 6 Nov 2018 16:36:38 +0100 Subject: [PATCH] =?UTF-8?q?More=20customizing=20=F0=9F=A4=98=20(#33)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Use sidebar param to show or hide sidebar toggle * Make all sections optional * Make footer quicklinks customizable * Let customize the header image and link --- layouts/_default/baseof.html | 26 ++++++++++- layouts/partials/footer.html | 74 +++++++++--------------------- layouts/partials/navbar-clone.html | 16 +++++-- layouts/partials/navbar.html | 16 +++++-- 4 files changed, 70 insertions(+), 62 deletions(-) diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index 022ceaa..f7762a6 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -12,20 +12,44 @@ {{ block "main" . }} + + {{ if .Site.Params.hero }} {{ partial "hero.html" . }} + {{ end }} + + {{ if .Site.Params.section1 }} {{ partial "section1.html" . }} + {{ end }} + + {{ if .Site.Params.section2 }} {{ partial "section2.html" . }} + {{ end }} + + {{ if .Site.Params.section3 }} {{ partial "section3.html" . }} + {{ end }} + + {{ if .Site.Params.section4 }} {{ partial "section4.html" . }} + {{ end }} + + {{ if .Site.Params.section5 }} {{ partial "section5.html" . }} + {{ end }} + + {{ if .Site.Params.footer }} {{ partial "footer.html" . }} + {{ end }}
+ {{ if .Site.Params.sidebar }} {{ partial "sidebar.html" . }} {{ end }} + + {{ end }} {{ partial "javascript.html" . }} - \ No newline at end of file + diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index 4b3bf5b..71b9bd6 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -1,10 +1,8 @@ -{{- $footer := .Site.Params.footer }} -{{- $logo := index $footer "logo" }} -{{- $productLinks := index $footer "product" }} -{{- $docLinks := index $footer "docs" }} -{{- $blogrollLinks:= index $footer "blogroll" }} -{{- $socialMedia := index $footer "socialmedia" }} -{{- $bulmaLogo := index $footer "bulmalogo" }} +{{- $footer := .Site.Params.footer }} +{{- $logo := index $footer "logo" }} +{{- $quickLinks := index $footer "quicklinks" }} +{{- $socialMedia := index $footer "socialmedia" }} +{{- $bulmaLogo := index $footer "bulmalogo" }}