From 182f593d86951b761bb063aa31cf364f51bcefcb Mon Sep 17 00:00:00 2001 From: Alex Turchyn Date: Tue, 1 Aug 2023 00:26:37 +0300 Subject: [PATCH] fix form previous day date bug --- app/javascript/submission_form/area.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/javascript/submission_form/area.vue b/app/javascript/submission_form/area.vue index a282649c..39517b33 100644 --- a/app/javascript/submission_form/area.vue +++ b/app/javascript/submission_form/area.vue @@ -212,7 +212,7 @@ export default { }, formattedDate () { if (this.field.type === 'date' && this.modelValue) { - return new Intl.DateTimeFormat([], { year: 'numeric', month: 'long', day: 'numeric' }).format(new Date(this.modelValue)) + return new Intl.DateTimeFormat([], { year: 'numeric', month: 'long', day: 'numeric', timeZone: 'UTC' }).format(new Date(this.modelValue)) } else { return '' }