mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-11-26 06:37:33 +00:00
fix(dashboard): name Etc/GMT world clocks by their real offset
An Etc/GMT zone counts westward as positive, so Etc/GMT-4 is four hours ahead of UTC. The clock's title and the zone picker printed the id's own sign, and someone who picked GMT+4 got a clock four hours behind UTC; both now read the real offset, on the desktop and the phone. Closes #3175
This commit is contained in:
@@ -10,7 +10,7 @@ import { useAddonStore } from '../../../store/addonStore'
|
||||
import { entityGradient } from '../../../utils/gradients'
|
||||
import { useCurrencyConverter } from '../../../components/Dashboard/useCurrencyConverter'
|
||||
import { useCollectionLists } from '../../../components/Dashboard/useCollectionLists'
|
||||
import { shortZone, useDashboardTimezones } from '../../../components/Dashboard/useDashboardTimezones'
|
||||
import { shortZone, useDashboardTimezones, zoneOptionLabel } from '../../../components/Dashboard/useDashboardTimezones'
|
||||
import { formatTime, splitReservationDateTime } from '../../../utils/formatters'
|
||||
import { normalizeAppearance, MOBILE_DASH_TOKENS, type MobileDashToken } from '@trek/shared'
|
||||
import { MOMENT_LABEL, upcomingKey, type UpcomingReservation } from '../../../pages/dashboard/dashboardModel'
|
||||
@@ -231,7 +231,7 @@ function MTimezonesWidget(): React.ReactElement {
|
||||
>
|
||||
<option value="" disabled>{t('dashboard.tz.searchPlaceholder')}</option>
|
||||
{allZones.filter(z => !zones.includes(z)).map(z => (
|
||||
<option key={z} value={z}>{z.replace(/_/g, ' ')}</option>
|
||||
<option key={z} value={z}>{zoneOptionLabel(z)}</option>
|
||||
))}
|
||||
</select>
|
||||
)}
|
||||
|
||||
Reference in New Issue
Block a user