commit de960997bc835f75c328af55f3a3c402cf39121d parent 94d8927676510493336a745a2861145889663dcd Author: Florian <26717601+florianbieser@users.noreply.github.com> Date: Wed, 18 Jan 2023 16:51:20 +0100 option to write the reading time in the same language as the site Diffstat:
| M | README.md | | | 2 | ++ |
| M | layouts/_default/single.html | | | 2 | +- |
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/README.md b/README.md @@ -230,6 +230,8 @@ paginate = 5 olderPosts = "Older posts" missingContentMessage = "Page not found..." missingBackButtonLabel = "Back to home page" + minuteReadingTime = "min read" + words = "words" [languages.en.params.logo] logoText = "Terminal" diff --git a/layouts/_default/single.html b/layouts/_default/single.html @@ -16,7 +16,7 @@ <span class="post-author">{{ . }}</span> {{ end }} {{ if and (.Param "readingTime") (eq (.Param "readingTime") true) }} - <span class="post-reading-time">:: {{ .ReadingTime }} min read ({{ .WordCount }} words)</span> + <span class="post-reading-time">:: {{ .ReadingTime }} {{ $.Site.Params.minuteReadingTime | default "min read" }} ({{ .WordCount }} {{ $.Site.Params.words | default "words" }})</span> {{ end }} </div>