From cc9f3d7cdae925c0901728d35770866914c813b3 Mon Sep 17 00:00:00 2001 From: Matt Spencer Date: Wed, 5 Jan 2022 16:36:08 +0000 Subject: [PATCH 01/11] Initial commit for blog structure Add menu item for blog posts Enable navbar rollup for responsive design Add initial card based list for blog posts Add boilerplate blog post for all-hands --- config.toml | 15 ++++++++++----- content/blog/2022/all_hands.md | 9 +++++++++ content/blog/_index.md | 4 ++++ themes/soafee/layouts/_default/list.html | 11 ++++------- themes/soafee/layouts/partials/blogcard.html | 9 +++++++++ themes/soafee/layouts/partials/header.html | 12 ++++++------ 6 files changed, 42 insertions(+), 18 deletions(-) create mode 100644 content/blog/2022/all_hands.md create mode 100644 content/blog/_index.md create mode 100644 themes/soafee/layouts/partials/blogcard.html diff --git a/config.toml b/config.toml index f084dea..751034d 100644 --- a/config.toml +++ b/config.toml @@ -32,8 +32,13 @@ googleAnalytics = "GTM-WLHTXFF" privacyEnhanced = false -#[[menu.main]] -# name = "Home" -# pre = "home" -# url = "/" -# weight = 1 +[[menu.main]] + name = "Home" + pre = "home" + url = "/" + weight = 1 +[[menu.main]] + name = "Blog" + pre = "blog" + url = "/blog" + weight = 2 diff --git a/content/blog/2022/all_hands.md b/content/blog/2022/all_hands.md new file mode 100644 index 0000000..6b7c570 --- /dev/null +++ b/content/blog/2022/all_hands.md @@ -0,0 +1,9 @@ +--- +Title: "SOAFEE Inaugural All Hands" +Description: "The SOAFEE Governing Body are pleased to announce the inaugural All Hands meeting for the SOAFEE Special Interest Group. Click through to find out more." +date: "2022-01-05" +--- + +# Title of the post +## Sub-title +I am waiting for content from Robert to fill this section \ No newline at end of file diff --git a/content/blog/_index.md b/content/blog/_index.md new file mode 100644 index 0000000..b7ef9b6 --- /dev/null +++ b/content/blog/_index.md @@ -0,0 +1,4 @@ +--- +Title: "SOAFEE Blogs" +layout: "list" +--- diff --git a/themes/soafee/layouts/_default/list.html b/themes/soafee/layouts/_default/list.html index cbade5a..022d2e0 100644 --- a/themes/soafee/layouts/_default/list.html +++ b/themes/soafee/layouts/_default/list.html @@ -1,11 +1,8 @@ {{ define "main" }} -

{{ .Title }}

+{{ .Content }} {{ range .Pages.ByPublishDate.Reverse }} -

-

{{ .Title }}

- -

{{ .Summary }}

-
-

+ +{{- partial "blogcard.html" . -}} + {{ end }} {{ end }} \ No newline at end of file diff --git a/themes/soafee/layouts/partials/blogcard.html b/themes/soafee/layouts/partials/blogcard.html new file mode 100644 index 0000000..7c92325 --- /dev/null +++ b/themes/soafee/layouts/partials/blogcard.html @@ -0,0 +1,9 @@ +
+
+
+ {{ .Title }} +
+

{{ .Description }}

+
+ +
diff --git a/themes/soafee/layouts/partials/header.html b/themes/soafee/layouts/partials/header.html index f6a926e..7daa326 100644 --- a/themes/soafee/layouts/partials/header.html +++ b/themes/soafee/layouts/partials/header.html @@ -1,14 +1,14 @@ \ No newline at end of file -- GitLab From c80dc891cfd4f389cff453dfdbbb375f7c07d940 Mon Sep 17 00:00:00 2001 From: Matt Spencer Date: Thu, 6 Jan 2022 15:48:33 +0000 Subject: [PATCH 02/11] Add padding to the blog card --- themes/soafee/layouts/partials/blogcard.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/themes/soafee/layouts/partials/blogcard.html b/themes/soafee/layouts/partials/blogcard.html index 7c92325..aa64ee6 100644 --- a/themes/soafee/layouts/partials/blogcard.html +++ b/themes/soafee/layouts/partials/blogcard.html @@ -1,4 +1,4 @@ -
+
{{ .Title }} -- GitLab From 852c66bb1a7eb5863c16e992721dfea8dd75f1fb Mon Sep 17 00:00:00 2001 From: Matt Spencer Date: Thu, 6 Jan 2022 16:33:40 +0000 Subject: [PATCH 03/11] Add navbar highlight Only works for non-nested menus at the moment. --- config.toml | 4 ++-- themes/soafee/layouts/partials/header.html | 10 +++++++--- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/config.toml b/config.toml index 751034d..1c2eb90 100644 --- a/config.toml +++ b/config.toml @@ -35,10 +35,10 @@ googleAnalytics = "GTM-WLHTXFF" [[menu.main]] name = "Home" pre = "home" - url = "/" + pageref = "/" weight = 1 [[menu.main]] name = "Blog" pre = "blog" - url = "/blog" + pageref = "/blog" weight = 2 diff --git a/themes/soafee/layouts/partials/header.html b/themes/soafee/layouts/partials/header.html index 7daa326..e7ec970 100644 --- a/themes/soafee/layouts/partials/header.html +++ b/themes/soafee/layouts/partials/header.html @@ -9,11 +9,15 @@