From 5ee2f2a18b16bdda277c7c3a3326c118c933289d Mon Sep 17 00:00:00 2001 From: Gabriele Musco Date: Wed, 9 Jun 2021 20:54:12 +0200 Subject: [PATCH] added option to hide article summary --- README.md | 1 + layouts/partials/article_card.html | 10 ++++++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 3b6d17b..bb83703 100644 --- a/README.md +++ b/README.md @@ -47,6 +47,7 @@ summaryLength = 70 # number of words for article summaries showRss = true # show the link for the RSS feed; default true imageInArticlePreview = false # show images in article preview; default false + articleSummary = true # show a summary in article preview; default true navtype = "standard" # changes the style of the pagination, available styles are: "standard", "circles" fontFamily = "JetBrains Mono" # changes the font, default "JetBrains Mono" diff --git a/layouts/partials/article_card.html b/layouts/partials/article_card.html index d058a14..b4570a6 100644 --- a/layouts/partials/article_card.html +++ b/layouts/partials/article_card.html @@ -19,10 +19,12 @@ {{ end }} {{end}} -
-

{{ .Summary }}

-

Continue reading 

-
+ {{ if (site.Params.articleSummary | default true) }} +
+

{{ .Summary }}

+

Continue reading 

+
+ {{ end }}