From 1199b92d9e2a7514c33f13ca7e79e78662116682 Mon Sep 17 00:00:00 2001 From: Toshaan Bharvani Date: Fri, 16 Dec 2022 11:07:53 +0100 Subject: [PATCH] update blog layout Signed-off-by: Toshaan Bharvani --- .../openpowerfoundation/assets/css/pages.scss | 20 +++++++++++++++++++ .../layouts/blog/list.html | 3 +++ .../layouts/blog/single.html | 16 ++++++++++----- 3 files changed, 34 insertions(+), 5 deletions(-) diff --git a/themes/openpowerfoundation/assets/css/pages.scss b/themes/openpowerfoundation/assets/css/pages.scss index 338cb04..d2c5d3a 100644 --- a/themes/openpowerfoundation/assets/css/pages.scss +++ b/themes/openpowerfoundation/assets/css/pages.scss @@ -284,3 +284,23 @@ section#steeringcomittee { padding-top: 3.75rem; padding-bottom: 1.75rem; } + +.blog-entry { + padding-top: 7.00rem; + padding-bottom: 1.75rem; + h1 { + font-size: 2rem; + font-style: bold; + text-decoration: underline; + } + h2 { + font-size: 1rem; + font-style: italic; + } + h3 { + font-size: 1rem; + } + .tags { + color: #888888; + } +} diff --git a/themes/openpowerfoundation/layouts/blog/list.html b/themes/openpowerfoundation/layouts/blog/list.html index 644bba1..730b6c4 100644 --- a/themes/openpowerfoundation/layouts/blog/list.html +++ b/themes/openpowerfoundation/layouts/blog/list.html @@ -30,6 +30,9 @@ {{ .Title }}
+ {{ if .Params.author }} + Written by {{ .Params.author }} -  + {{ end }} Published on {{ .Date.Format "Monday 2 January 2006" }}
diff --git a/themes/openpowerfoundation/layouts/blog/single.html b/themes/openpowerfoundation/layouts/blog/single.html index 73ca10b..6f45a0d 100644 --- a/themes/openpowerfoundation/layouts/blog/single.html +++ b/themes/openpowerfoundation/layouts/blog/single.html @@ -1,13 +1,17 @@ {{ partial "header.html" . }} {{ partial "navbar.html" . }} -
+
-

{{ .Title }}

+

{{ .Title }}

+ {{ if .Params.author }} +

Author : {{ .Params.author }}

+ {{ end }}

Published on {{ .Date.Format "Monday 2 January 2006" }}

+

 
@@ -15,16 +19,17 @@
 
+

{{ if .Params.tags }} {{ $tags := .Params.tags }}
-
+
{{ if not (eq (len $.Site.Taxonomies.tags) 0) }} {{ $fontUnit := "rem" }} - {{ $largestFontSize := 3.5 }} - {{ $smallestFontSize := 0.5 }} + {{ $largestFontSize := 2.25 }} + {{ $smallestFontSize := 0.25 }} {{ $fontSpread := sub $largestFontSize $smallestFontSize }} {{ $max := add (len (index $.Site.Taxonomies.tags.ByCount 0).Pages) 1 }} {{ $min := len (index $.Site.Taxonomies.tags.ByCount.Reverse 0).Pages }} @@ -45,6 +50,7 @@ {{ end }}
+
{{ end }}
{{ partial "footer.html" . }}