From 7af27035d0688883e9cc3f921ea33a83c0c75912 Mon Sep 17 00:00:00 2001 From: rinsuki <428rinsuki+git@gmail.com> Date: Sat, 4 Jan 2020 20:01:48 +0900 Subject: [PATCH] make last updated date format translatable --- i18n/en.toml | 3 +++ layouts/index.html | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/i18n/en.toml b/i18n/en.toml index 0fc441bd..86cfb384 100644 --- a/i18n/en.toml +++ b/i18n/en.toml @@ -4,6 +4,9 @@ other = "Improve this page" [lastUpdated] other = "Last updated" +[lastUpdatedDateFormat] +other = "{{ .Format \"January 2, 2006\" }}" + [joinTitle] other = "Join the social media revolution" diff --git a/layouts/index.html b/layouts/index.html index a98ff5a4..b9181ca9 100644 --- a/layouts/index.html +++ b/layouts/index.html @@ -11,7 +11,7 @@ {{ .Content }}

- {{ i18n "lastUpdated" }} {{ .Lastmod.Format "January 2, 2006" }}{{ with .File }} · {{ i18n "improvePage" }}{{ end }} + {{ i18n "lastUpdated" }} {{ i18n "lastUpdatedDateFormat" .Lastmod }}{{ with .File }} · {{ i18n "improvePage" }}{{ end }} {{ if .IsTranslated }}