From efa49ad3d27ed538b8331cbc62bbf6aef15c0245 Mon Sep 17 00:00:00 2001 From: melohagan <101575380+melohagan@users.noreply.github.com> Date: Fri, 13 Jan 2023 17:03:46 +0000 Subject: [PATCH] Undo time offset (#9140) --- packages/bbui/src/Form/Core/DatePicker.svelte | 7 ------- 1 file changed, 7 deletions(-) diff --git a/packages/bbui/src/Form/Core/DatePicker.svelte b/packages/bbui/src/Form/Core/DatePicker.svelte index 6996525a76..f5a301ca32 100644 --- a/packages/bbui/src/Form/Core/DatePicker.svelte +++ b/packages/bbui/src/Form/Core/DatePicker.svelte @@ -76,13 +76,6 @@ } // If time only set date component to 2000-01-01 if (timeOnly) { - // Classic flackpickr causing issues. - // When selecting a value for the first time for a "time only" field, - // the time is always offset by 1 hour for some reason (regardless of time - // zone) so we need to correct it. - if (!value && newValue) { - newValue = new Date(dates[0].getTime() + 60 * 60 * 1000).toISOString() - } newValue = `2000-01-01T${newValue.split("T")[1]}` }