Skip to content

Fix handling of timezones in the date picker#14

Open
iosabi wants to merge 1 commit intoLouisHDev:mainfrom
iosabi:fix_date
Open

Fix handling of timezones in the date picker#14
iosabi wants to merge 1 commit intoLouisHDev:mainfrom
iosabi:fix_date

Conversation

@iosabi
Copy link

@iosabi iosabi commented Mar 30, 2025

The API returns UTC datetimes, like "2025-03-29T18:22:10.681Z" but we want the user to pick times in their local timezone like in the web UI. DateTime.now() already returns a local time, so all we have to do is convert the UTC time to local when displaying in the widget and back to UTC afterwards.

The API returns UTC datetimes, like "2025-03-29T18:22:10.681Z" but we
want the user to pick times in their local timezone like in the web UI.
`DateTime.now()` already returns a local time, so all we have to do is
convert the UTC time to local when displaying in the widget and back to
UTC afterwards.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant