From 45271b5298d4a5dd91df97a1d3f3c726bd9398bc Mon Sep 17 00:00:00 2001 From: Jordi Bares Date: Sun, 31 Mar 2019 22:48:17 +0100 Subject: Add footer functionality --- .DS_Store | Bin 0 -> 8196 bytes assets/book.scss | 14 +++++++++++++- exampleSite/config.yml | 8 +++++++- layouts/.DS_Store | Bin 0 -> 6148 bytes layouts/docs/baseof.html | 1 + layouts/partials/.DS_Store | Bin 0 -> 6148 bytes layouts/partials/docs/footer.html | 15 +++++++++++++++ layouts/partials/docs/html-head.html | 19 +++++++++++++++++++ static/custom.css | 5 +++++ 9 files changed, 60 insertions(+), 2 deletions(-) create mode 100644 .DS_Store create mode 100644 layouts/.DS_Store create mode 100644 layouts/partials/.DS_Store create mode 100644 layouts/partials/docs/footer.html create mode 100644 static/custom.css diff --git a/.DS_Store b/.DS_Store new file mode 100644 index 0000000..0a66c9f Binary files /dev/null and b/.DS_Store differ diff --git a/assets/book.scss b/assets/book.scss index 13cdbd8..c2689b9 100644 --- a/assets/book.scss +++ b/assets/book.scss @@ -145,6 +145,18 @@ ul.pagination { } } +.book-footer { + display: flex; + margin-top: $padding-16; + font-size: $font-size-14; + align-items: baseline; + + img { + width: $font-size-14; + vertical-align: bottom; + } +} + .book-posts { min-width: $body-min-width; max-width: $sm-breakpoint; @@ -205,4 +217,4 @@ aside nav, .book-toc nav { padding: $padding-16 * 2 $padding-16; } -} +} \ No newline at end of file diff --git a/exampleSite/config.yml b/exampleSite/config.yml index d450485..3e36c8c 100644 --- a/exampleSite/config.yml +++ b/exampleSite/config.yml @@ -46,4 +46,10 @@ params: # Configure the date format used on the pages # - In git information # - In blog posts - BookDateFormat: "Jan 2, 2006" \ No newline at end of file + BookDateFormat: "Jan 2, 2006" + + # (Optional, default false) Show or hide site footer + BookShowFooter: false + + # Copyright notice for footer + Copyright: ["© 2019 Alex Shpak"] diff --git a/layouts/.DS_Store b/layouts/.DS_Store new file mode 100644 index 0000000..c1f243e Binary files /dev/null and b/layouts/.DS_Store differ diff --git a/layouts/docs/baseof.html b/layouts/docs/baseof.html index 9ea09fa..57c4bec 100644 --- a/layouts/docs/baseof.html +++ b/layouts/docs/baseof.html @@ -19,6 +19,7 @@ {{ partial "docs/mobile-header" . }} {{ template "main" . }} {{ partial "docs/git-footer" . }} + {{ partial "docs/footer" . }} {{ template "toc" . }} diff --git a/layouts/partials/.DS_Store b/layouts/partials/.DS_Store new file mode 100644 index 0000000..b1bc858 Binary files /dev/null and b/layouts/partials/.DS_Store differ diff --git a/layouts/partials/docs/footer.html b/layouts/partials/docs/footer.html new file mode 100644 index 0000000..bc4a406 --- /dev/null +++ b/layouts/partials/docs/footer.html @@ -0,0 +1,15 @@ + +{{ if .Site.Params.BookShowFooter }} + +{{ end }} \ No newline at end of file diff --git a/layouts/partials/docs/html-head.html b/layouts/partials/docs/html-head.html index 5d6f1c1..7b412f7 100644 --- a/layouts/partials/docs/html-head.html +++ b/layouts/partials/docs/html-head.html @@ -2,11 +2,30 @@ {{- template "title" . }} | {{ .Site.Title -}} + + + + + + {{ $styles := resources.Get "book.scss" | resources.ToCSS | resources.Minify | resources.Fingerprint }} + + + + + + + + +{{ if .RSSLink }} + + +{{ end }} + {{ "