From f2b9e3349549e1346ba46af48a8e13193f8564fb Mon Sep 17 00:00:00 2001 From: Jimmy Cai Date: Fri, 23 Jul 2021 09:49:04 +0000 Subject: [PATCH] feat: add i18n support to reading time string --- i18n/en.yaml | 5 +++++ layouts/partials/article/components/details.html | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/i18n/en.yaml b/i18n/en.yaml index 21b1310..e279278 100644 --- a/i18n/en.yaml +++ b/i18n/en.yaml @@ -29,6 +29,11 @@ article: lastUpdatedOn: other: Last updated on + readingTime: + one: "{{ .Count }} min read" + ### Seems that there's no need to add 's' even if it's plural in English + other: "{{ .Count }} min read" + notFound: title: other: Not Found diff --git a/layouts/partials/article/components/details.html b/layouts/partials/article/components/details.html index 487b765..aff4337 100644 --- a/layouts/partials/article/components/details.html +++ b/layouts/partials/article/components/details.html @@ -35,7 +35,7 @@
{{ partial "helper/icon" "clock" }}
{{ end }}