Fix timezone handling for day timeline and card dates
Revert beginningOfDay() to use local timezone methods — the UTC change from #2790 caused cards created earlier the same day to show "yesterday" for users in UTC-negative timezones after their local 7 PM. Add Time.zone.name to day timeline fragment cache keys so timezone-different renders don't collide.
This commit is contained in:
@@ -7,7 +7,7 @@ export function signedDifferenceInDays(fromDate, toDate) {
|
||||
}
|
||||
|
||||
export function beginningOfDay(date) {
|
||||
return new Date(Date.UTC(date.getUTCFullYear(), date.getUTCMonth(), date.getUTCDate()))
|
||||
return new Date(date.getFullYear(), date.getMonth(), date.getDate())
|
||||
}
|
||||
|
||||
export function secondsToDate(seconds) {
|
||||
|
||||
Reference in New Issue
Block a user