From 0630bcc4d0bc644503e777fe05b2f485219c2931 Mon Sep 17 00:00:00 2001 From: Micressor <micressor@secure.mailbox.org> Date: Fri, 7 Dec 2018 14:53:36 +0100 Subject: [PATCH] Add section.html template So we can see articles in sections like * $BaseURL/news * $BaseURL/hiring May be we can add a News navigation link --- themes/briar/layouts/_default/section.html | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 themes/briar/layouts/_default/section.html diff --git a/themes/briar/layouts/_default/section.html b/themes/briar/layouts/_default/section.html new file mode 100644 index 0000000..ce70db8 --- /dev/null +++ b/themes/briar/layouts/_default/section.html @@ -0,0 +1,18 @@ +{{ define "main" }} + <div id="container"> + <div id="content"> + <h1>{{ with .Title }} {{ . }} {{ else }} {{ .Site.Title }} {{ end }}</h1> + {{ range first 10 .Pages.ByDate.Reverse }} + <h3 itemprop="headline" class="blog-post-title"> + <a href="{{.Permalink}}">{{.Title}}</a> + </h3> +<p class="blog-post-meta">{{.Date.Format "2006-01-02"}} + {{ if (isset .Params "author") }} + by {{ markdownify .Params.author }} + {{ end }} + </p> + {{ end }} + {{ .Content }} + </div> <!-- content --> + </div> <!-- container --> +{{ end }} -- GitLab