(Split from #25)
This is mainly a problem because Elm core does not properly support timezones or even give a way to determine the timezone of a Date value.
Specifically, in our app, we need to let the user choose moments in time, but we want the datepicker to show them dates in their user-selected timezone, which sometimes is different from the timezone of the local computer they are using.
Our investigation has led to the following thoughts about how to make datetimepicker more robust w/r to timezone handling:
- datetimepicker should provide its own data types that directly matches what the pickers can choose
(instead of giving back a Maybe Date)
- datepicker should give a record with year, month, day
- timepicker should give a record with hour, minute
- datetimepicker should give a record with year, month, day, hour, minute
- datetimepicker can provide convenience functions to turn the above data types into Date values (documented to note that they will convert using the local timezone of the user's web browser)
(Split from #25)
This is mainly a problem because Elm core does not properly support timezones or even give a way to determine the timezone of a Date value.
Specifically, in our app, we need to let the user choose moments in time, but we want the datepicker to show them dates in their user-selected timezone, which sometimes is different from the timezone of the local computer they are using.
Our investigation has led to the following thoughts about how to make datetimepicker more robust w/r to timezone handling:
(instead of giving back a
Maybe Date)