From 363b9276eb7300436821384affdea6cdc1229fbd Mon Sep 17 00:00:00 2001 From: Daniel Dietzler <36593685+danieldietzler@users.noreply.github.com> Date: Fri, 26 Dec 2025 21:40:07 -0600 Subject: [PATCH] fix: album card timezone (#24855) --- web/src/lib/utils/date-time.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/web/src/lib/utils/date-time.ts b/web/src/lib/utils/date-time.ts index 8a50df9cfe..53996adfa2 100644 --- a/web/src/lib/utils/date-time.ts +++ b/web/src/lib/utils/date-time.ts @@ -27,6 +27,9 @@ export const getShortDateRange = (startDate: string | Date, endDate: string | Da const endDateLocalized = endDate.toLocaleString(userLocale, { month: 'short', year: 'numeric', + // The API returns the date in UTC. If the earliest asset was taken on Jan 1st at 1am, + // we expect the album to start in January, even if the local timezone is UTC-5 for instance. + timeZone: 'UTC', }); if (startDate.getFullYear() === endDate.getFullYear()) {