Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/zwbetz-gh/papercss-hugo-theme.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormeredrica <stuff@meredrica.org>2020-01-02 12:43:05 +0300
committerzwbetz-gh <37317628+zwbetz-gh@users.noreply.github.com>2020-01-02 12:43:05 +0300
commitf5f63abfb72ca4447c82d9c602554da83f2acda2 (patch)
treea447aef63257e70b028c9bcfed5f767ca0f79dd0
parent505f3020a1d4549a02f53b2e5af7aaf86b057511 (diff)
allow content to be added to index and list pages (#3)
-rw-r--r--layouts/_default/list.html3
-rw-r--r--layouts/index.html5
2 files changed, 5 insertions, 3 deletions
diff --git a/layouts/_default/list.html b/layouts/_default/list.html
index 2f70abf..dab975e 100644
--- a/layouts/_default/list.html
+++ b/layouts/_default/list.html
@@ -1,6 +1,7 @@
{{ define "main" }}
<h1>{{ .Title }}</h1>
+{{ .Content }}
{{ $pages := .Pages }}
{{ range $pages.ByPublishDate.Reverse }}
<h2 class="post-list {{ if ne .Params.show_summary false }}summary{{ end }}">
@@ -12,4 +13,4 @@
{{ .Summary }}
{{ end }}
{{ end }}
-{{ end }} \ No newline at end of file
+{{ end }}
diff --git a/layouts/index.html b/layouts/index.html
index 777587f..75987b9 100644
--- a/layouts/index.html
+++ b/layouts/index.html
@@ -1,6 +1,7 @@
{{ define "main" }}
<h1>{{ .Title }}</h1>
+{{ .Content }}
{{ $pages := where site.RegularPages "Type" "in" site.Params.mainSections }}
{{ range $pages.ByPublishDate.Reverse }}
<h2 class="post-list {{ if ne .Params.show_summary false }}summary{{ end }}">
@@ -11,5 +12,5 @@
{{ if ne .Params.show_summary false }}
{{ .Summary }}
{{ end }}
-{{ end }}
-{{ end }} \ No newline at end of file
+{{ end }}
+{{ end }}