Repository navigation
Conversation
Contributor
There was a problem hiding this comment.
ℹ️ No blocking issues — one non-blocking finding below.
Approach: sound — the profile picker should draw from the platform's IANA set instead of a hand-curated 15-entry list, and this matches what the public booking templates already do.
Reviewed changes
- Timezone source —
TIMEZONESis now a module-load union ofIntl.supportedValuesOf('timeZone')and the retainedFALLBACK_TIMEZONES, deduped and sorted, with the old list kept for engines withoutsupportedValuesOfand forUTC, which CLDR omits. - Fallback entries —
Asia/Ho_Chi_MinhandAsia/Bangkokwere added to the retained list; the first is genuinely absent from CLDR (which returnsAsia/Saigon), the second is redundant but harmless. - Blast radius — the only consumer is the profile
Combobox(settings/profile/+page.svelte:257), and the SPA setsssr = false, so the module-load IIFE cannot cause hydration drift. Every selectable name is present in Go's embedded tzdata, so the backendtime.LoadLocationcheck inPatchMeaccepts the whole list.
Non-blocking
- CLDR's canonical spellings are the legacy IANA names, so the modern ones stay unsearchable. The list carries
Asia/Calcutta,Europe/Kiev,Asia/Rangoon,America/GodthabandAfrica/Asmerawhile lackingAsia/Kolkata,Europe/Kyiv,Asia/Yangon,America/NuukandAsia/Asmara, so a user searching the picker for the name they know gets "no results" — the fallback merge only patches one such case (Asia/Ho_Chi_Minh), and leaves both it andAsia/Saigonselectable. The same gap means a stored value outside the list (set via the API or a seed) renders as an empty picker, sinceComboboxresolves its display label only againstitems(prefs.tsL95); adding the current spellings to the merge, or appending the stored value in the profile page, closes both.
deepseek-v4.1-flash | 𝕏
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
The public booking templates (
internal/handler/templates/book.htmlandmanage.html) already populate their timezone pickers withIntl.supportedValuesOf('timeZone'). The admin profile page (frontend/src/routes/settings/profile/+page.svelte) still read from a hardcoded 15-itemTIMEZONESarray infrontend/src/lib/prefs.ts, which left out zones such asAsia/Ho_Chi_MinhandAsia/Bangkok.This change builds
TIMEZONESfromIntl.supportedValuesOf('timeZone')merged withFALLBACK_TIMEZONESand sorted. Merging the fallback list is required because V8/ICU omitsUTCandAsia/Ho_Chi_MinhfromIntl.supportedValuesOf('timeZone')(returningAsia/Saigoninstead).Evidence
TIMEZONESinfrontend/src/lib/prefs.tscontained 15 hardcoded entries;Asia/Ho_Chi_MinhandAsia/Bangkokwere absent from Settings -> Profile -> Timezone.Intl.supportedValuesOf('timeZone')returns 418 IANA zones in Node/V8 (UTC: false,Asia/Ho_Chi_Minh: false,Asia/Saigon: true), and mergingFALLBACK_TIMEZONESpreserves bothUTCandAsia/Ho_Chi_Minh.pnpm check(svelte-kit sync && svelte-check --tsconfig ./tsconfig.json):svelte-check found 0 errors and 0 warnings.pnpm build(vite build): completed cleanly (vite buildin 12.78s).Merge Danger
Door: two-way
Reverting
frontend/src/lib/prefs.tsrestores the previous list with no database or API changes.Blast Radius: Low
Only affects the
TIMEZONESexport consumed by the profile timezoneComboboxinfrontend/src/routes/settings/profile/+page.svelte. Backend validation already uses Gotime.LoadLocationoniana_timezone.