From 892af4b96106670f5c2744c39665036401c68796 Mon Sep 17 00:00:00 2001 From: Harald Kraemer Date: Sat, 24 Jul 2021 12:39:31 +0200 Subject: Fix relative date for resolved issues and non-UTC browser timezone. (#197) * Remove Storehouse from the README examples (#195) Their status page is no longer present, as they seem to be changing their web strategy * Fix relative date for resolved issues and non-UTC browser timezone. The missing in the layout causes a weird glitch if the users browser is in a non-UTC timezone. For open incidents, the time is rendered as "23-07-2021 12:17:40 UTC", and then the javascript library correctly translates from UTC into the users browser time, resulting in say "30m ago". For a resolved incident, the timezone of the date was stripped due to the missing in the format string, resulting in "23-07-2021 12:17:40". If the user has a browser is in the timezone CEST (UTC+2), this causes the relative time to jump from "30 minutes ago" for an open incident to "2 hours ago" for a closed incident, because now the time without time zone is not interpreted as UTC anymore. Co-authored-by: Justin Clift <82353280+jc-dgit@users.noreply.github.com> Co-authored-by: Harald Kraemer --- layouts/issues/small.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'layouts/issues') diff --git a/layouts/issues/small.html b/layouts/issues/small.html index 531b47b..115d5d0 100644 --- a/layouts/issues/small.html +++ b/layouts/issues/small.html @@ -23,7 +23,7 @@ {{ else if .Params.Resolved }} - + {{ if .Site.Params.dateFormat }} {{ .Date.Format .Site.Params.dateFormat }} {{ else }} -- cgit v1.2.3-70-g09d2