From df14e32b46f9c0ae168253397823123d006bfd8a Mon Sep 17 00:00:00 2001 From: Marvin Steadfast Date: Thu, 2 Apr 2020 10:46:25 +0200 Subject: [PATCH] webmention form only on posts and using more if and where content type clauses --- config.yml | 2 -- layouts/index.rss.xml | 2 +- themes/xsfx/layouts/_default/single.html | 2 ++ themes/xsfx/layouts/index.html | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/config.yml b/config.yml index 5923ee6..de659bc 100644 --- a/config.yml +++ b/config.yml @@ -6,8 +6,6 @@ author: name: "Marvin Preuss" params: AuthorName: "Marvin Preuss" - mainSections: - - "posts" locallinks: - search - impressum diff --git a/layouts/index.rss.xml b/layouts/index.rss.xml index ea5fd95..398f95b 100644 --- a/layouts/index.rss.xml +++ b/layouts/index.rss.xml @@ -25,7 +25,7 @@ {{ with .OutputFormats.Get "RSS" }} {{ printf "" .Permalink .MediaType | safeHTML }} {{ end }} - {{ range $pages }} + {{ range (where .Site.RegularPages "Type" "eq" "posts") }} {{ .Title }} {{ .Permalink }} diff --git a/themes/xsfx/layouts/_default/single.html b/themes/xsfx/layouts/_default/single.html index 5b22258..c534aec 100644 --- a/themes/xsfx/layouts/_default/single.html +++ b/themes/xsfx/layouts/_default/single.html @@ -2,7 +2,9 @@
{{ partial "article.html" . }} + {{ if eq .Type "posts" }} {{ partial "mentions.html" . }} + {{ end }}
{{ end }} diff --git a/themes/xsfx/layouts/index.html b/themes/xsfx/layouts/index.html index 6e90701..b28505d 100644 --- a/themes/xsfx/layouts/index.html +++ b/themes/xsfx/layouts/index.html @@ -1,6 +1,6 @@ {{ define "main" }}
- {{ $paginator := .Paginate (where .Site.RegularPages "Type" "in" .Site.Params.mainSections) }} + {{ $paginator := .Paginate (where .Site.RegularPages "Type" "eq" "posts") }} {{ range $paginator.Pages }}
{{ partial "article.html" . }}