Rallly is an open-source scheduling and collaboration tool designed to make organizing events and meetings easier.
TypeScript i18nextnext-authnextjspostgresqlprismareact-emailt3-stacktailwindcsstrpcturborepotypescriptzod
✨ Improved time zone selector (#2261)
Luke Vellac85f1a73b34c
diff --git a/apps/web/package.json b/apps/web/package.jsonindex 1f3d2f2e6..4519b443e 100644--- a/apps/web/package.json+++ b/apps/web/package.json@@ -14,7 +14,8 @@"test:unit": "vitest run","test:codegen": "playwright codegen http://localhost:3000","docker:start": "./scripts/docker-start.sh",- "better-auth:generate": "pnpx @better-auth/cli@latest generate --config ./src/lib/auth.ts --output ../../packages/database/prisma/models/user.prisma"+ "better-auth:generate": "pnpx @better-auth/cli@latest generate --config ./src/lib/auth.ts --output ../../packages/database/prisma/models/user.prisma",+ "tz:generate": "node scripts/generate-timezone-data.mjs"},"dependencies": {"@ai-sdk/openai": "^3.0.29",diff --git a/apps/web/public/locales/en/app.json b/apps/web/public/locales/en/app.jsonindex a547148a7..43f31d26a 100644--- a/apps/web/public/locales/en/app.json+++ b/apps/web/public/locales/en/app.json@@ -90,7 +90,6 @@"profile": "Profile","polls": "Polls","timeZoneSelect__noOption": "No option found",- "timeZoneSelect__inputPlaceholder": "Search…","poweredByRallly": "Powered by <a>{name}</a>","participants": "Participants","language": "Language",@@ -612,13 +611,9 @@"notFoundTitle": "Page not found","notFoundDescription": "Sorry, we couldn't find the page you're looking for. Here are some helpful links instead.","notifications": "Notifications",- "notificationScopeOff": "Off",- "notificationScopeMine": "Mine",- "notificationScopeAll": "All","pollNotificationsDescription": "Get notified by email when there is activity on your polls","notifyNewResponse": "New response",- "notifyNewResponseDescription": "When someone responds to a poll","notifyNewComment": "New comment",- "notifyNewCommentDescription": "When someone comments on a poll",- "notificationsDescription": "Choose which email notifications you receive"+ "notificationsDescription": "Choose which email notifications you receive",+ "timezoneInputPlaceholder": "Search timezone…"}diff --git a/apps/web/scripts/generate-timezone-data.mjs b/apps/web/scripts/generate-timezone-data.mjsnew file mode 100644index 000000000..34089be49--- /dev/null+++ b/apps/web/scripts/generate-timezone-data.mjs@@ -0,0 +1,332 @@+import { writeFileSync } from "node:fs";+import { createRequire } from "node:module";+import { dirname, resolve } from "node:path";+import { fileURLToPath } from "node:url";++const require = createRequire(import.meta.url);+const soft = require("timezone-soft");++const __dirname = dirname(fileURLToPath(import.meta.url));++// Curated list of major cities/timezones (~150)+// Covers all UTC offsets and major population centers+const curatedTimezones = [+ // UTC-12 to UTC-10+ "Pacific/Pago_Pago",+ "Pacific/Honolulu",++ // UTC-9 to UTC-8+ "America/Anchorage",+ "America/Los_Angeles",+ "America/Tijuana",+ "America/Vancouver",++ // UTC-7+ "America/Denver",+ "America/Edmonton",+ "America/Phoenix",++ // UTC-6+ "America/Chicago",+ "America/Guatemala",+ "America/Mexico_City",+ "America/Winnipeg",++ // UTC-5+ "America/Bogota",+ "America/Cancun",+ "America/Havana",+ "America/Indianapolis",+ "America/Jamaica",+ "America/Lima",+ "America/New_York",+ "America/Panama",+ "America/Toronto",++ // UTC-4+ "America/Barbados",+ "America/Caracas",+ "America/Halifax",+ "America/La_Paz",+ "America/Puerto_Rico",+ "America/Santiago",+ "America/Santo_Domingo",++ // UTC-3.5+ "America/St_Johns",++ // UTC-3+ "America/Argentina/Buenos_Aires",+ "America/Asuncion",+ "America/Montevideo",+ "America/Sao_Paulo",++ // UTC-2+ "America/Noronha",+ "Atlantic/South_Georgia",++ // UTC-1+ "Atlantic/Azores",+ "Atlantic/Cape_Verde",++ // UTC+0+ "Africa/Abidjan",+ "Africa/Accra",+ "Africa/Casablanca",+ "Africa/Monrovia",+ "Atlantic/Reykjavik",+ "Europe/Dublin",+ "Europe/Lisbon",+ "Europe/London",++ // UTC+1+ "Africa/Algiers",+ "Africa/Lagos",+ "Africa/Tunis",+ "Europe/Amsterdam",+ "Europe/Belgrade",+ "Europe/Berlin",+ "Europe/Brussels",+ "Europe/Budapest",+ "Europe/Copenhagen",+ "Europe/Madrid",+ "Europe/Oslo",+ "Europe/Paris",+ "Europe/Prague",+ "Europe/Rome",+ "Europe/Stockholm",+ "Europe/Vienna",+ "Europe/Warsaw",+ "Europe/Zurich",++ // UTC+2+ "Africa/Cairo",+ "Africa/Johannesburg",+ "Africa/Nairobi",+ "Asia/Beirut",+ "Asia/Jerusalem",+ "Europe/Athens",+ "Europe/Bucharest",+ "Europe/Helsinki",+ "Europe/Istanbul",+ "Europe/Kyiv",+ "Europe/Riga",+ "Europe/Sofia",+ "Europe/Tallinn",+ "Europe/Vilnius",++ // UTC+3+ "Africa/Addis_Ababa",+ "Asia/Baghdad",+ "Asia/Kuwait",+ "Asia/Qatar",+ "Asia/Riyadh",+ "Europe/Minsk",+ "Europe/Moscow",++ // UTC+3:30+ "Asia/Tehran",++ // UTC+4+ "Asia/Baku",+ "Asia/Dubai",+ "Asia/Tbilisi",+ "Asia/Yerevan",+ "Indian/Mauritius",++ // UTC+4:30+ "Asia/Kabul",++ // UTC+5+ "Asia/Karachi",+ "Asia/Tashkent",+ "Asia/Yekaterinburg",++ // UTC+5:30+ "Asia/Colombo",+ "Asia/Kolkata",++ // UTC+5:45+ "Asia/Kathmandu",++ // UTC+6+ "Asia/Almaty",+ "Asia/Dhaka",+ "Asia/Omsk",++ // UTC+6:30+ "Asia/Yangon",++ // UTC+7+ "Asia/Bangkok",+ "Asia/Jakarta",+ "Asia/Krasnoyarsk",+ "Asia/Ho_Chi_Minh",++ // UTC+8+ "Asia/Hong_Kong",+ "Asia/Kuala_Lumpur",+ "Asia/Macau",+ "Asia/Manila",+ "Asia/Shanghai",+ "Asia/Singapore",+ "Asia/Taipei",+ "Australia/Perth",++ // UTC+9+ "Asia/Seoul",+ "Asia/Tokyo",+ "Asia/Yakutsk",++ // UTC+9:30+ "Australia/Adelaide",+ "Australia/Darwin",++ // UTC+10+ "Australia/Brisbane",+ "Australia/Melbourne",+ "Australia/Sydney",+ "Pacific/Guam",+ "Pacific/Port_Moresby",++ // UTC+11+ "Asia/Magadan",+ "Pacific/Guadalcanal",+ "Pacific/Noumea",++ // UTC+12+ "Asia/Kamchatka",+ "Pacific/Auckland",+ "Pacific/Fiji",++ // UTC+13+ "Pacific/Apia",+ "Pacific/Tongatapu",+];++// Override display names for cities where IANA ID doesn't match common usage+const cityOverrides = {+ "America/Argentina/Buenos_Aires": "Buenos Aires",+ "America/Indianapolis": "Indianapolis",+};++function getCityFromIana(iana) {+ if (cityOverrides[iana]) return cityOverrides[iana];+ const lastSlash = iana.lastIndexOf("/");+ const raw = iana.substring(lastSlash + 1);+ return raw.replaceAll("_", " ");+}++function buildKeywords(entry) {+ const parts = [+ entry.city,+ entry.iana,+ entry.standardAbbr,+ entry.daylightAbbr,+ entry.longDescription,+ entry.standardName,+ ].filter(Boolean);++ return parts.join(" ").toLowerCase();+}++const curatedSet = new Set(curatedTimezones);++function buildEntry(iana) {+ const softData = soft(iana)[0];+ const city = getCityFromIana(iana);++ const keywords = buildKeywords({+ iana,+ city,+ standardAbbr: softData?.standard?.abbr ?? "",+ daylightAbbr: softData?.daylight?.abbr ?? "",+ standardName: softData?.standard?.name ?? "",+ });++ return {+ id: iana,+ city,+ keywords,+ curated: curatedSet.has(iana),+ };+}++// Legacy IANA aliases that exist in production databases but aren't returned+// by Intl.supportedValuesOf("timeZone"). We include them so existing DB values+// are always findable in the picker.+const legacyAliases = [+ "America/Indiana/Indianapolis",+ "America/Montreal",+ "America/Santa_Isabel",+ "Pacific/Johnston",+];++// Build entries for all IANA timezones+const allTimezones = Intl.supportedValuesOf("timeZone");++// Add legacy aliases that aren't already in the list+const allTimezoneSet = new Set(allTimezones);+for (const alias of legacyAliases) {+ if (!allTimezoneSet.has(alias)) {+ allTimezones.push(alias);+ }+}++const entries = allTimezones.map(buildEntry);++// Sort alphabetically by city (runtime will re-sort by offset)+entries.sort((a, b) => a.city.localeCompare(b.city));++// Generate TS file with unquoted keys for Biome compatibility+function entryToTs(entry) {+ const esc = (s) => s.replace(/\\/g, "\\\\").replace(/"/g, '\\"');+ return ` {+ id: "${esc(entry.id)}",+ city: "${esc(entry.city)}",+ keywords: "${esc(entry.keywords)}",+ }`;+}++const curated = entries.filter((e) => e.curated);++const curatedTs = curated.map(entryToTs).join(",\n");+const allTs = entries.map(entryToTs).join(",\n");++const output = `// This file is auto-generated by scripts/generate-timezone-data.mjs+// Do not edit manually. Run: pnpm tz:generate++export interface TimezoneEntry {+ id: string;+ city: string;+ keywords: string;+}++export const curatedTimezoneEntries: TimezoneEntry[] = [+${curatedTs},+];++export const allTimezoneEntries: TimezoneEntry[] = [+${allTs},+];+`;++const outPath = resolve(+ __dirname,+ "../src/components/time-zone-picker/timezone-data.ts",+);+writeFileSync(outPath, output, "utf-8");++// Run Biome to format the generated file+import { execSync } from "node:child_process";++try {+ execSync(`npx biome check --write ${outPath}`, {+ cwd: resolve(__dirname, ".."),+ stdio: "inherit",+ });+} catch {+ // Biome may not be available, that's ok+}++console.log(`Generated ${entries.length} timezone entries to ${outPath}`);diff --git a/apps/web/src/app/api/private/[...route]/route.ts b/apps/web/src/app/api/private/[...route]/route.tsindex 4e95e661d..766710889 100644--- a/apps/web/src/app/api/private/[...route]/route.ts+++ b/apps/web/src/app/api/private/[...route]/route.ts@@ -14,7 +14,6 @@ import { rateLimiter } from "hono-rate-limiter";import { getPollParticipants, getPollResults } from "@/features/poll/data";import { createPoll, deletePoll } from "@/features/poll/mutations";import { redis } from "@/lib/kv";-import { isSupportedTimeZone } from "@/utils/supported-time-zones";import {createPollInputSchema,createPollSuccessResponseSchema,@@ -228,16 +227,6 @@ app.post(const slots = input.slots;const timeZone = slots.timezone;- if (timeZone && !isSupportedTimeZone(timeZone)) {- return c.json(- apiError(- "INVALID_TIMEZONE",- `Invalid timezone: ${timeZone}. Please provide a valid IANA timezone.`,- ),- 400,- );- }-const duration = slots.duration;const times = Array.isArray(slots.times) ? slots.times : [slots.times];diff --git a/apps/web/src/app/api/private/schemas.ts b/apps/web/src/app/api/private/schemas.tsindex 6c57220f0..ad3ccd281 100644--- a/apps/web/src/app/api/private/schemas.ts+++ b/apps/web/src/app/api/private/schemas.ts@@ -1,5 +1,5 @@import { z } from "@hono/zod-openapi";-import { isSupportedTimeZone } from "@/utils/supported-time-zones";+import { timezoneSchema } from "@/utils/timezone-schema";export const dateSchema = z.iso.date().openapi({description: "Date in YYYY-MM-DD format",@@ -31,17 +31,11 @@ const slotsInputSchema = zdescription: "Duration in minutes for each time slot",example: 30,}),- timezone: z- .string()- .refine(isSupportedTimeZone, {- message: "Timezone must be a valid IANA timezone",- })- .optional()- .openapi({- description:- "IANA timezone. If not provided, times will be stored as UTC and no timezone will be set on the poll (indicating floating times).",- example: "Europe/London",- }),+ timezone: timezoneSchema.optional().openapi({+ description:+ "IANA timezone. If not provided, times will be stored as UTC and no timezone will be set on the poll (indicating floating times).",+ example: "Europe/London",+ }),times: z.array(z.union([diff --git a/apps/web/src/components/clock.tsx b/apps/web/src/components/clock.tsxindex 8e9a27a8b..2ae59e788 100644--- a/apps/web/src/components/clock.tsx+++ b/apps/web/src/components/clock.tsx@@ -16,9 +16,11 @@ import spacetime from "spacetime";import soft from "timezone-soft";import { TimeFormatPicker } from "@/components/time-format-picker";import { TimeZoneSelect } from "@/components/time-zone-picker/time-zone-select";+import { allTimezoneEntries } from "@/components/time-zone-picker/timezone-data";import { usePreferences } from "@/contexts/preferences";import { Trans } from "@/i18n/client";import { dayjs } from "@/lib/dayjs";+import { useTimezone } from "@/lib/timezone/client/context";import { useDayjs } from "@/utils/dayjs";export const TimePreferences = () => {@@ -74,8 +76,11 @@ export const Clock = ({ className }: { className?: string }) => {};export const TimesShownIn = () => {- const { timeZone } = useDayjs();-+ const { timezone } = useTimezone();+ const selectedEntry = React.useMemo(+ () => allTimezoneEntries.find((e) => e.id === timezone),+ [timezone],+ );return (<ClockPreferences><button@@ -86,7 +91,7 @@ export const TimesShownIn = () => {<Transi18nKey="timeShownIn"defaults="Times shown in {timeZone}"- values={{ timeZone: timeZone.replaceAll("_", " ") }}+ values={{ timeZone: selectedEntry?.city }}/></button></ClockPreferences>diff --git a/apps/web/src/components/forms/poll-options-form/poll-options-form.tsx b/apps/web/src/components/forms/poll-options-form/poll-options-form.tsxindex c6e558df5..763d25e9a 100644--- a/apps/web/src/components/forms/poll-options-form/poll-options-form.tsx+++ b/apps/web/src/components/forms/poll-options-form/poll-options-form.tsx@@ -1,7 +1,6 @@import { cn } from "@rallly/ui";import { Button } from "@rallly/ui/button";import { Card, CardDescription, CardHeader, CardTitle } from "@rallly/ui/card";-import { CommandDialog } from "@rallly/ui/command";import {Dialog,DialogContent,@@ -15,11 +14,11 @@ import { Label } from "@rallly/ui/label";import { Switch } from "@rallly/ui/switch";import { Tabs, TabsList, TabsTrigger } from "@rallly/ui/tabs";import { Tooltip, TooltipContent, TooltipTrigger } from "@rallly/ui/tooltip";-import { CalendarIcon, GlobeIcon, InfoIcon, TableIcon } from "lucide-react";+import { CalendarIcon, InfoIcon, TableIcon } from "lucide-react";import * as React from "react";import { useFormContext } from "react-hook-form";-import { TimeZoneCommand } from "@/components/time-zone-picker/time-zone-select";+import { TimeZoneSelect } from "@/components/time-zone-picker/time-zone-select";import { Trans, useTranslation } from "@/i18n/client";import { getBrowserTimeZone } from "../../../utils/date-time-utils";@@ -43,8 +42,6 @@ const PollOptionsForm = ({const { t } = useTranslation();const form = useFormContext<NewEventData>();- const [isTimeZoneCommandModalOpen, showTimeZoneCommandModal] =- React.useState(false);const { watch, setValue, getValues, formState } = form;const views = React.useMemo(() => {@@ -252,30 +249,11 @@ const PollOptionsForm = ({</Tooltip></div>{field.value ? (- <div>- <Button- disabled={disableTimeZoneChange}- onClick={() => {- showTimeZoneCommandModal(true);- }}- variant="ghost"- >- <GlobeIcon className="size-4 text-muted-foreground" />- {field.value}- </Button>- <CommandDialog- open={isTimeZoneCommandModalOpen}- onOpenChange={showTimeZoneCommandModal}- >- <TimeZoneCommand- value={field.value}- onSelect={(newValue) => {- field.onChange(newValue);- showTimeZoneCommandModal(false);- }}- />- </CommandDialog>- </div>+ <TimeZoneSelect+ disabled={disableTimeZoneChange}+ value={field.value}+ onValueChange={field.onChange}+ />) : null}</div>)}diff --git a/apps/web/src/components/time-zone-picker/time-zone-select.test.tsx b/apps/web/src/components/time-zone-picker/time-zone-select.test.tsxnew file mode 100644index 000000000..0c6496e2c--- /dev/null+++ b/apps/web/src/components/time-zone-picker/time-zone-select.test.tsx@@ -0,0 +1,108 @@+import userEvent from "@testing-library/user-event";+import { describe, expect, it } from "vitest";+import { render, screen, within } from "@/test/test-utils";++import { TimeZoneSelect } from "./time-zone-select";++describe("TimeZoneSelect", () => {+ it("should render the combobox input", () => {+ render(<TimeZoneSelect />);+ expect(screen.getByRole("combobox")).toBeInTheDocument();+ });++ it("should show selected timezone as input value", () => {+ render(<TimeZoneSelect value="America/New_York" />);+ const input = screen.getByRole("combobox");+ expect(input).toHaveValue("New York");+ });++ it("should show curated timezones when opened without typing", async () => {+ const user = userEvent.setup();+ render(<TimeZoneSelect />);++ await user.click(screen.getByRole("combobox"));++ const listbox = await screen.findByRole("listbox");+ const options = within(listbox).getAllByRole("option");++ // Should show curated list (100+ entries but not the full 400+)+ expect(options.length).toBeGreaterThan(50);+ expect(options.length).toBeLessThan(200);+ });++ it("should filter results when typing a city name", async () => {+ const user = userEvent.setup();+ render(<TimeZoneSelect />);++ const input = screen.getByRole("combobox");+ await user.type(input, "tokyo");++ const listbox = await screen.findByRole("listbox");+ const options = within(listbox).getAllByRole("option");++ expect(options.length).toBeGreaterThanOrEqual(1);+ expect(options.some((opt) => opt.textContent?.includes("Tokyo"))).toBe(+ true,+ );+ });++ it("should show non-curated timezones when searching", async () => {+ const user = userEvent.setup();+ render(<TimeZoneSelect />);++ const input = screen.getByRole("combobox");+ await user.type(input, "malta");++ const listbox = await screen.findByRole("listbox");+ const options = within(listbox).getAllByRole("option");++ expect(options.some((opt) => opt.textContent?.includes("Malta"))).toBe(+ true,+ );+ });++ it("should call onValueChange when selecting a timezone", async () => {+ const onValueChange = vi.fn();+ const user = userEvent.setup();+ render(<TimeZoneSelect onValueChange={onValueChange} />);++ const input = screen.getByRole("combobox");+ await user.type(input, "london");++ const listbox = await screen.findByRole("listbox");+ const londonOption = within(listbox)+ .getAllByRole("option")+ .find((opt) => opt.textContent?.includes("London"));++ if (!londonOption) throw new Error("London option not found");+ await user.click(londonOption);++ expect(onValueChange).toHaveBeenCalledWith("Europe/London");+ });++ it("should be case-insensitive when filtering", async () => {+ const user = userEvent.setup();+ render(<TimeZoneSelect />);++ const input = screen.getByRole("combobox");+ await user.type(input, "NEW YORK");++ const listbox = await screen.findByRole("listbox");+ const options = within(listbox).getAllByRole("option");++ expect(options.some((opt) => opt.textContent?.includes("New York"))).toBe(+ true,+ );+ });++ it("should show no options for nonsense query", async () => {+ const user = userEvent.setup();+ render(<TimeZoneSelect />);++ const input = screen.getByRole("combobox");+ await user.type(input, "xyznotaplace");++ // The combobox should indicate the list is empty via data attribute+ expect(input).toHaveAttribute("data-list-empty", "");+ });+});diff --git a/apps/web/src/components/time-zone-picker/time-zone-select.tsx b/apps/web/src/components/time-zone-picker/time-zone-select.tsxindex f84643734..33ae6e39c 100644--- a/apps/web/src/components/time-zone-picker/time-zone-select.tsx+++ b/apps/web/src/components/time-zone-picker/time-zone-select.tsx@@ -1,106 +1,104 @@-"use client";--import type { SelectProps } from "@radix-ui/react-select";import { cn } from "@rallly/ui";-import { Badge } from "@rallly/ui/badge";-import { Button } from "@rallly/ui/button";import {- Command,- CommandDialog,- CommandEmpty,- CommandGroup,- CommandInput,- CommandItem,- CommandList,-} from "@rallly/ui/command";-import { useDialog } from "@rallly/ui/dialog";-import { Icon } from "@rallly/ui/icon";-import { CheckIcon, GlobeIcon } from "lucide-react";+ Combobox,+ ComboboxContent,+ ComboboxEmpty,+ ComboboxInput,+ ComboboxItem,+ ComboboxList,+ useComboboxAnchor,+} from "@rallly/ui/combobox";+import { InputGroupAddon } from "@rallly/ui/input-group";+import dayjs from "dayjs";+import { GlobeIcon } from "lucide-react";import React from "react";-import { Trans, useTranslation } from "@/i18n/client";-import { dayjs } from "@/lib/dayjs";-import { groupedTimeZones } from "@/utils/grouped-time-zone";+import type { TimezoneEntry } from "@/components/time-zone-picker/timezone-data";+import {+ allTimezoneEntries,+ curatedTimezoneEntries,+} from "@/components/time-zone-picker/timezone-data";+import { getOffsetLabel } from "@/components/time-zone-picker/timezone-utils";+import { useTranslation } from "@/i18n/client";-interface TimeZoneCommandProps {- value?: string;- onSelect?: (value: string) => void;+function filterTimezone(entry: TimezoneEntry, query: string): boolean {+ if (!query) return true;+ return entry.keywords.includes(query.toLowerCase());}-export const TimeZoneCommand = ({ onSelect, value }: TimeZoneCommandProps) => {+export function TimeZoneSelect({+ value,+ onValueChange,+ className,+ disabled,+}: {+ value?: string;+ onValueChange?: (value: string) => void;+ className?: string;+ disabled?: boolean;+}) {const { t } = useTranslation();- return (- <Command>- <CommandInput- placeholder={t("timeZoneSelect__inputPlaceholder", {- defaultValue: "Search…",- })}- />- <CommandList className="max-h-[300px] w-(--radix-popover-trigger-width) max-w-(--radix-popover-content-available-width) overflow-y-auto">- <CommandEmpty>- <Trans- i18nKey="timeZoneSelect__noOption"- defaults="No option found"- />- </CommandEmpty>- {Object.entries(groupedTimeZones).map(([region, timeZones]) => (- <CommandGroup heading={region} key={region}>- {timeZones.map(({ timezone, city }) => {- return (- <CommandItem- key={timezone}- onSelect={() => onSelect?.(timezone)}- className="flex min-w-0 gap-x-2.5"- >- <div className="w-6 shrink-0">- {value === timezone ? (- <Icon>- <CheckIcon />- </Icon>- ) : null}- </div>- <span className="min-w-0 grow truncate">{city}</span>- <Badge>{dayjs().tz(timezone).format("z")}</Badge>- </CommandItem>- );- })}- </CommandGroup>- ))}- </CommandList>- </Command>++ const anchorRef = useComboboxAnchor();++ const [isSearching, setIsSearching] = React.useState(false);++ const selectedEntry = React.useMemo(+ () => allTimezoneEntries.find((e) => e.id === value),+ [value],);-};-export const TimeZoneSelect = React.forwardRef<- HTMLButtonElement,- SelectProps & { className?: string }->(({ value, onValueChange, className, disabled }, ref) => {- const dialog = useDialog();return (- <>- <CommandDialog {...dialog.dialogProps}>- <TimeZoneCommand- value={value}- onSelect={(newValue) => {- onValueChange?.(newValue);- dialog.dismiss();- }}- />- </CommandDialog>- <Button- ref={ref}- disabled={disabled}- className={cn("justify-start text-left", className)}- onClick={() => {- dialog.trigger();- }}- >- <Icon>- <GlobeIcon />- </Icon>- <span className="flex-1">{value}</span>- </Button>- </>+ <Combobox<TimezoneEntry>+ items={isSearching ? allTimezoneEntries : curatedTimezoneEntries}+ value={selectedEntry ?? null}+ onValueChange={(entry) => {+ if (entry) {+ onValueChange?.(entry.id);+ }+ }}+ onInputValueChange={(inputValue, { reason }) => {+ if (reason === "input-change") {+ setIsSearching(inputValue.trim().length > 0);+ } else {+ setIsSearching(false);+ }+ }}+ itemToStringLabel={(entry) => entry.city}+ filter={filterTimezone}+ autoHighlight={true}+ >+ <div ref={anchorRef} className={cn("min-w-64", className)}>+ <ComboboxInput+ disabled={disabled}+ placeholder={t("timezoneInputPlaceholder", {+ defaultValue: "Search timezone…",+ })}+ >+ <InputGroupAddon>+ <GlobeIcon />+ </InputGroupAddon>+ </ComboboxInput>+ </div>+ <ComboboxContent align="end" anchor={anchorRef.current}>+ <ComboboxEmpty>+ {t("timeZoneSelect__noOption", {+ defaultValue: "No timezone found",+ })}+ </ComboboxEmpty>+ <ComboboxList>+ {(entry) => (+ <ComboboxItem key={entry.id} value={entry} index={entry.index}>+ <span className="rounded-full bg-muted px-1.5 py-0.5 text-muted-foreground text-xs tabular-nums">+ {getOffsetLabel(entry.id)}+ </span>+ <span className="min-w-0 flex-1 truncate">{entry.city}</span>+ <span className="rounded-full px-1 py-0.5 text-center text-muted-foreground text-xs tabular-nums">+ {dayjs().tz(entry.id).format("LT")}+ </span>+ </ComboboxItem>+ )}+ </ComboboxList>+ </ComboboxContent>+ </Combobox>);-});--TimeZoneSelect.displayName = "TimeZoneSelect";+}diff --git a/apps/web/src/components/time-zone-picker/timezone-data.ts b/apps/web/src/components/time-zone-picker/timezone-data.tsnew file mode 100644index 000000000..40c52915c--- /dev/null+++ b/apps/web/src/components/time-zone-picker/timezone-data.ts@@ -0,0 +1,2836 @@+// This file is auto-generated by scripts/generate-timezone-data.mjs+// Do not edit manually. Run: pnpm tz:generate++export interface TimezoneEntry {+ id: string;+ city: string;+ keywords: string;+}++export const curatedTimezoneEntries: TimezoneEntry[] = [+ {+ id: "Africa/Abidjan",+ city: "Abidjan",+ keywords: "abidjan africa/abidjan gmt greenwich mean standard time",+ },+ {+ id: "Africa/Accra",+ city: "Accra",+ keywords: "accra africa/accra gmt greenwich mean standard time",+ },+ {+ id: "Africa/Addis_Ababa",+ city: "Addis Ababa",+ keywords: "addis ababa africa/addis_ababa eat east africa standard time",+ },+ {+ id: "Australia/Adelaide",+ city: "Adelaide",+ keywords:+ "adelaide australia/adelaide acst acdt central australia standard time",+ },+ {+ id: "Africa/Algiers",+ city: "Algiers",+ keywords: "algiers africa/algiers cet central european standard time",+ },+ {+ id: "Asia/Almaty",+ city: "Almaty",+ keywords: "almaty asia/almaty almt east kazakhstan standard time",+ },+ {+ id: "Europe/Amsterdam",+ city: "Amsterdam",+ keywords:+ "amsterdam europe/amsterdam cet cest central european standard time",+ },+ {+ id: "America/Anchorage",+ city: "Anchorage",+ keywords: "anchorage america/anchorage akst akdt alaska standard time",+ },+ {+ id: "Pacific/Apia",+ city: "Apia",+ keywords: "apia pacific/apia wst west samoa standard time",+ },+ {+ id: "America/Asuncion",+ city: "Asuncion",+ keywords: "asuncion america/asuncion pyt pyst paraguay standard time",+ },+ {+ id: "Europe/Athens",+ city: "Athens",+ keywords: "athens europe/athens eet eest eastern european standard time",+ },+ {+ id: "Pacific/Auckland",+ city: "Auckland",+ keywords: "auckland pacific/auckland nzst nzdt new zealand standard time",+ },+ {+ id: "Atlantic/Azores",+ city: "Azores",+ keywords: "azores atlantic/azores azot azost azores standard time",+ },+ {+ id: "Asia/Baghdad",+ city: "Baghdad",+ keywords: "baghdad asia/baghdad ast arabian standard time",+ },+ {+ id: "Asia/Baku",+ city: "Baku",+ keywords: "baku asia/baku azt azerbaijan standard time",+ },+ {+ id: "Asia/Bangkok",+ city: "Bangkok",+ keywords: "bangkok asia/bangkok ict indochina standard time",+ },+ {+ id: "America/Barbados",+ city: "Barbados",+ keywords: "barbados america/barbados ast atlantic standard time",+ },+ {+ id: "Asia/Beirut",+ city: "Beirut",+ keywords: "beirut asia/beirut eet eest eastern european standard time",+ },+ {+ id: "Europe/Belgrade",+ city: "Belgrade",+ keywords:+ "belgrade europe/belgrade cet cest central european standard time",+ },+ {+ id: "Europe/Berlin",+ city: "Berlin",+ keywords: "berlin europe/berlin cet cest central european standard time",+ },+ {+ id: "America/Bogota",+ city: "Bogota",+ keywords: "bogota america/bogota cot colombia standard time",+ },+ {+ id: "Australia/Brisbane",+ city: "Brisbane",+ keywords: "brisbane australia/brisbane aest brisbane standard time",+ },+ {+ id: "Europe/Brussels",+ city: "Brussels",+ keywords:+ "brussels europe/brussels cet cest central european standard time",+ },+ {+ id: "Europe/Bucharest",+ city: "Bucharest",+ keywords:+ "bucharest europe/bucharest eet eest eastern european standard time",+ },+ {+ id: "Europe/Budapest",+ city: "Budapest",+ keywords:+ "budapest europe/budapest cet cest central european standard time",+ },+ {+ id: "Africa/Cairo",+ city: "Cairo",+ keywords: "cairo africa/cairo eet eastern european standard time",+ },+ {+ id: "America/Cancun",+ city: "Cancun",+ keywords: "cancun america/cancun est eastern standard time",+ },+ {+ id: "Atlantic/Cape_Verde",+ city: "Cape Verde",+ keywords: "cape verde atlantic/cape_verde cvt cape verde standard time",+ },+ {+ id: "America/Caracas",+ city: "Caracas",+ keywords: "caracas america/caracas vet venezuela standard time",+ },+ {+ id: "Africa/Casablanca",+ city: "Casablanca",+ keywords:+ "casablanca africa/casablanca wet west morocco standard standard time",+ },+ {+ id: "America/Chicago",+ city: "Chicago",+ keywords: "chicago america/chicago cst cdt central standard time",+ },+ {+ id: "Asia/Colombo",+ city: "Colombo",+ keywords: "colombo asia/colombo ist india standard time",+ },+ {+ id: "Europe/Copenhagen",+ city: "Copenhagen",+ keywords:+ "copenhagen europe/copenhagen cet cest central european standard time",+ },+ {+ id: "Australia/Darwin",+ city: "Darwin",+ keywords: "darwin australia/darwin acst australian central standard time",+ },+ {+ id: "America/Denver",+ city: "Denver",+ keywords: "denver america/denver mst mdt mountain standard time",+ },+ {+ id: "Asia/Dhaka",+ city: "Dhaka",+ keywords: "dhaka asia/dhaka bst bangladesh standard time",+ },+ {+ id: "Asia/Dubai",+ city: "Dubai",+ keywords: "dubai asia/dubai gst gulf standard time",+ },+ {+ id: "Europe/Dublin",+ city: "Dublin",+ keywords: "dublin europe/dublin gmt ist irish standard time",+ },+ {+ id: "America/Edmonton",+ city: "Edmonton",+ keywords: "edmonton america/edmonton mst mdt mountain standard time",+ },+ {+ id: "Pacific/Fiji",+ city: "Fiji",+ keywords: "fiji pacific/fiji fjt fjt fiji standard time",+ },+ {+ id: "Pacific/Guadalcanal",+ city: "Guadalcanal",+ keywords:+ "guadalcanal pacific/guadalcanal sbt solomon islands standard time",+ },+ {+ id: "Pacific/Guam",+ city: "Guam",+ keywords: "guam pacific/guam chst chamorro standard time",+ },+ {+ id: "America/Guatemala",+ city: "Guatemala",+ keywords: "guatemala america/guatemala cst central standard time",+ },+ {+ id: "America/Halifax",+ city: "Halifax",+ keywords: "halifax america/halifax ast adt atlantic standard time",+ },+ {+ id: "America/Havana",+ city: "Havana",+ keywords: "havana america/havana hncu hecu cuba standard time",+ },+ {+ id: "Europe/Helsinki",+ city: "Helsinki",+ keywords:+ "helsinki europe/helsinki eet eest eastern european standard time",+ },+ {+ id: "Asia/Hong_Kong",+ city: "Hong Kong",+ keywords: "hong kong asia/hong_kong hkt hong kong standard time",+ },+ {+ id: "Pacific/Honolulu",+ city: "Honolulu",+ keywords: "honolulu pacific/honolulu hast hawaii-aleutian standard time",+ },+ {+ id: "America/Indianapolis",+ city: "Indianapolis",+ keywords: "indianapolis america/indianapolis est edt eastern standard time",+ },+ {+ id: "Europe/Istanbul",+ city: "Istanbul",+ keywords: "istanbul europe/istanbul trt turkey standard time",+ },+ {+ id: "Asia/Jakarta",+ city: "Jakarta",+ keywords: "jakarta asia/jakarta wib western indonesia standard time",+ },+ {+ id: "America/Jamaica",+ city: "Jamaica",+ keywords: "jamaica america/jamaica est eastern standard time",+ },+ {+ id: "Asia/Jerusalem",+ city: "Jerusalem",+ keywords: "jerusalem asia/jerusalem ist idt israel standard time",+ },+ {+ id: "Africa/Johannesburg",+ city: "Johannesburg",+ keywords:+ "johannesburg africa/johannesburg sast south africa standard time",+ },+ {+ id: "Asia/Kabul",+ city: "Kabul",+ keywords: "kabul asia/kabul aft afghanistan standard time",+ },+ {+ id: "Asia/Kamchatka",+ city: "Kamchatka",+ keywords:+ "kamchatka asia/kamchatka pett petropavlovsk-kamchatski standard time",+ },+ {+ id: "Asia/Karachi",+ city: "Karachi",+ keywords: "karachi asia/karachi pkt pakistan standard time",+ },+ {+ id: "Asia/Krasnoyarsk",+ city: "Krasnoyarsk",+ keywords: "krasnoyarsk asia/krasnoyarsk krat krasnoyarsk standard time",+ },+ {+ id: "Asia/Kuala_Lumpur",+ city: "Kuala Lumpur",+ keywords: "kuala lumpur asia/kuala_lumpur myt malaysia standard time",+ },+ {+ id: "Asia/Kuwait",+ city: "Kuwait",+ keywords: "kuwait asia/kuwait ast arabian standard time",+ },+ {+ id: "America/La_Paz",+ city: "La Paz",+ keywords: "la paz america/la_paz bot bolivia standard time",+ },+ {+ id: "Africa/Lagos",+ city: "Lagos",+ keywords: "lagos africa/lagos wat west africa standard time",+ },+ {+ id: "America/Lima",+ city: "Lima",+ keywords: "lima america/lima pet peru standard time",+ },+ {+ id: "Europe/Lisbon",+ city: "Lisbon",+ keywords: "lisbon europe/lisbon wet west western european standard time",+ },+ {+ id: "Europe/London",+ city: "London",+ keywords: "london europe/london gmt bst british standard time",+ },+ {+ id: "America/Los_Angeles",+ city: "Los Angeles",+ keywords: "los angeles america/los_angeles pst pdt pacific standard time",+ },+ {+ id: "Asia/Macau",+ city: "Macau",+ keywords: "macau asia/macau cst china standard time",+ },+ {+ id: "Europe/Madrid",+ city: "Madrid",+ keywords: "madrid europe/madrid cet cest central european standard time",+ },+ {+ id: "Asia/Magadan",+ city: "Magadan",+ keywords: "magadan asia/magadan magt magadan standard time",+ },+ {+ id: "Asia/Manila",+ city: "Manila",+ keywords: "manila asia/manila phst philippine standard time",+ },+ {+ id: "Indian/Mauritius",+ city: "Mauritius",+ keywords: "mauritius indian/mauritius mut mauritius standard time",+ },+ {+ id: "Australia/Melbourne",+ city: "Melbourne",+ keywords:+ "melbourne australia/melbourne aest aedt eastern australia standard time",+ },+ {+ id: "America/Mexico_City",+ city: "Mexico City",+ keywords:+ "mexico city america/mexico_city cst cdt central mexico standard time",+ },+ {+ id: "Europe/Minsk",+ city: "Minsk",+ keywords: "minsk europe/minsk msk moscow standard time",+ },+ {+ id: "Africa/Monrovia",+ city: "Monrovia",+ keywords: "monrovia africa/monrovia gmt greenwich mean standard time",+ },+ {+ id: "America/Montevideo",+ city: "Montevideo",+ keywords: "montevideo america/montevideo uyt uruguay standard time",+ },+ {+ id: "Europe/Moscow",+ city: "Moscow",+ keywords: "moscow europe/moscow msk moscow standard time",+ },+ {+ id: "Africa/Nairobi",+ city: "Nairobi",+ keywords: "nairobi africa/nairobi eat east africa standard time",+ },+ {+ id: "America/New_York",+ city: "New York",+ keywords: "new york america/new_york est edt eastern standard time",+ },+ {+ id: "America/Noronha",+ city: "Noronha",+ keywords: "noronha america/noronha fnt fernando de noronha standard time",+ },+ {+ id: "Pacific/Noumea",+ city: "Noumea",+ keywords: "noumea pacific/noumea nct new caledonia standard time",+ },+ {+ id: "Asia/Omsk",+ city: "Omsk",+ keywords: "omsk asia/omsk omst omsk standard time",+ },+ {+ id: "Europe/Oslo",+ city: "Oslo",+ keywords: "oslo europe/oslo cet cest central european standard time",+ },+ {+ id: "Pacific/Pago_Pago",+ city: "Pago Pago",+ keywords: "pago pago pacific/pago_pago sst samoa standard time",+ },+ {+ id: "America/Panama",+ city: "Panama",+ keywords: "panama america/panama est eastern standard time",+ },+ {+ id: "Europe/Paris",+ city: "Paris",+ keywords: "paris europe/paris cet cest central european standard time",+ },+ {+ id: "Australia/Perth",+ city: "Perth",+ keywords: "perth australia/perth awst western australia standard time",+ },+ {+ id: "America/Phoenix",+ city: "Phoenix",+ keywords: "phoenix america/phoenix mst mountain standard time",+ },+ {+ id: "Pacific/Port_Moresby",+ city: "Port Moresby",+ keywords:+ "port moresby pacific/port_moresby pgt papua new guinea standard time",+ },+ {+ id: "Europe/Prague",+ city: "Prague",+ keywords: "prague europe/prague cet cest central european standard time",+ },+ {+ id: "America/Puerto_Rico",+ city: "Puerto Rico",+ keywords: "puerto rico america/puerto_rico ast atlantic standard time",+ },+ {+ id: "Asia/Qatar",+ city: "Qatar",+ keywords: "qatar asia/qatar ast arabian standard time",+ },+ {+ id: "Atlantic/Reykjavik",+ city: "Reykjavik",+ keywords: "reykjavik atlantic/reykjavik gmt greenwich mean standard time",+ },+ {+ id: "Europe/Riga",+ city: "Riga",+ keywords: "riga europe/riga eet eest eastern european standard time",+ },+ {+ id: "Asia/Riyadh",+ city: "Riyadh",+ keywords: "riyadh asia/riyadh ast arabian standard time",+ },+ {+ id: "Europe/Rome",+ city: "Rome",+ keywords: "rome europe/rome cet cest central european standard time",+ },+ {+ id: "America/Santiago",+ city: "Santiago",+ keywords: "santiago america/santiago clt clst chile standard time",+ },+ {+ id: "America/Santo_Domingo",+ city: "Santo Domingo",+ keywords: "santo domingo america/santo_domingo ast atlantic standard time",+ },+ {+ id: "America/Sao_Paulo",+ city: "Sao Paulo",+ keywords: "sao paulo america/sao_paulo brt brasilia standard time",+ },+ {+ id: "Asia/Seoul",+ city: "Seoul",+ keywords: "seoul asia/seoul kst korean standard time",+ },+ {+ id: "Asia/Shanghai",+ city: "Shanghai",+ keywords: "shanghai asia/shanghai cst china standard time",+ },+ {+ id: "Asia/Singapore",+ city: "Singapore",+ keywords: "singapore asia/singapore sgt singapore standard time",+ },+ {+ id: "Europe/Sofia",+ city: "Sofia",+ keywords: "sofia europe/sofia eet eest eastern european standard time",+ },+ {+ id: "Atlantic/South_Georgia",+ city: "South Georgia",+ keywords:+ "south georgia atlantic/south_georgia gst south georgia standard time",+ },+ {+ id: "America/St_Johns",+ city: "St Johns",+ keywords: "st johns america/st_johns hntn hetn newfoundland standard time",+ },+ {+ id: "Europe/Stockholm",+ city: "Stockholm",+ keywords:+ "stockholm europe/stockholm cet cest central european standard time",+ },+ {+ id: "Australia/Sydney",+ city: "Sydney",+ keywords:+ "sydney australia/sydney aest aedt eastern australia standard time",+ },+ {+ id: "Asia/Taipei",+ city: "Taipei",+ keywords: "taipei asia/taipei cst taipei standard time",+ },+ {+ id: "Europe/Tallinn",+ city: "Tallinn",+ keywords: "tallinn europe/tallinn eet eest eastern european standard time",+ },+ {+ id: "Asia/Tashkent",+ city: "Tashkent",+ keywords: "tashkent asia/tashkent uzt uzbekistan standard time",+ },+ {+ id: "Asia/Tbilisi",+ city: "Tbilisi",+ keywords: "tbilisi asia/tbilisi get georgia standard time",+ },+ {+ id: "Asia/Tehran",+ city: "Tehran",+ keywords: "tehran asia/tehran irst iran standard time",+ },+ {+ id: "America/Tijuana",+ city: "Tijuana",+ keywords: "tijuana america/tijuana pst pdt pacific standard time",+ },+ {+ id: "Asia/Tokyo",+ city: "Tokyo",+ keywords: "tokyo asia/tokyo jst japan standard time",+ },+ {+ id: "Pacific/Tongatapu",+ city: "Tongatapu",+ keywords: "tongatapu pacific/tongatapu tot tonga standard time",+ },+ {+ id: "America/Toronto",+ city: "Toronto",+ keywords: "toronto america/toronto est edt eastern standard time",+ },+ {+ id: "Africa/Tunis",+ city: "Tunis",+ keywords: "tunis africa/tunis cet central european standard time",+ },+ {+ id: "America/Vancouver",+ city: "Vancouver",+ keywords: "vancouver america/vancouver pst pdt pacific standard time",+ },+ {+ id: "Europe/Vienna",+ city: "Vienna",+ keywords: "vienna europe/vienna cet cest central european standard time",+ },+ {+ id: "Europe/Vilnius",+ city: "Vilnius",+ keywords: "vilnius europe/vilnius eet eest eastern european standard time",+ },+ {+ id: "Europe/Warsaw",+ city: "Warsaw",+ keywords: "warsaw europe/warsaw cet cest central european standard time",+ },+ {+ id: "America/Winnipeg",+ city: "Winnipeg",+ keywords: "winnipeg america/winnipeg cst cdt central standard time",+ },+ {+ id: "Asia/Yakutsk",+ city: "Yakutsk",+ keywords: "yakutsk asia/yakutsk yakt yakutsk standard time",+ },+ {+ id: "Asia/Yekaterinburg",+ city: "Yekaterinburg",+ keywords:+ "yekaterinburg asia/yekaterinburg yekt yekaterinburg standard time",+ },+ {+ id: "Asia/Yerevan",+ city: "Yerevan",+ keywords: "yerevan asia/yerevan amt armenia standard time",+ },+ {+ id: "Europe/Zurich",+ city: "Zurich",+ keywords: "zurich europe/zurich cet cest central european standard time",+ },+];++export const allTimezoneEntries: TimezoneEntry[] = [+ {+ id: "Africa/Abidjan",+ city: "Abidjan",+ keywords: "abidjan africa/abidjan gmt greenwich mean standard time",+ },+ {+ id: "Africa/Accra",+ city: "Accra",+ keywords: "accra africa/accra gmt greenwich mean standard time",+ },+ {+ id: "America/Adak",+ city: "Adak",+ keywords: "adak america/adak hst hdt aleutian standard standard time",+ },+ {+ id: "Africa/Addis_Ababa",+ city: "Addis Ababa",+ keywords: "addis ababa africa/addis_ababa eat east africa standard time",+ },+ {+ id: "Australia/Adelaide",+ city: "Adelaide",+ keywords:+ "adelaide australia/adelaide acst acdt central australia standard time",+ },+ {+ id: "Asia/Aden",+ city: "Aden",+ keywords: "aden asia/aden ast arabian standard time",+ },+ {+ id: "Africa/Algiers",+ city: "Algiers",+ keywords: "algiers africa/algiers cet central european standard time",+ },+ {+ id: "Asia/Almaty",+ city: "Almaty",+ keywords: "almaty asia/almaty almt east kazakhstan standard time",+ },+ {+ id: "Asia/Amman",+ city: "Amman",+ keywords: "amman asia/amman eet eest eastern european standard time",+ },+ {+ id: "Europe/Amsterdam",+ city: "Amsterdam",+ keywords:+ "amsterdam europe/amsterdam cet cest central european standard time",+ },+ {+ id: "Asia/Anadyr",+ city: "Anadyr",+ keywords: "anadyr asia/anadyr anat anadyr standard time",+ },+ {+ id: "America/Anchorage",+ city: "Anchorage",+ keywords: "anchorage america/anchorage akst akdt alaska standard time",+ },+ {+ id: "Europe/Andorra",+ city: "Andorra",+ keywords: "andorra europe/andorra cet cest central european standard time",+ },+ {+ id: "America/Anguilla",+ city: "Anguilla",+ keywords: "anguilla america/anguilla ast atlantic standard time",+ },+ {+ id: "Indian/Antananarivo",+ city: "Antananarivo",+ keywords: "antananarivo indian/antananarivo eat east africa standard time",+ },+ {+ id: "America/Antigua",+ city: "Antigua",+ keywords: "antigua america/antigua ast atlantic standard time",+ },+ {+ id: "Pacific/Apia",+ city: "Apia",+ keywords: "apia pacific/apia wst west samoa standard time",+ },+ {+ id: "Asia/Aqtau",+ city: "Aqtau",+ keywords: "aqtau asia/aqtau almt west kazakhstan standard time",+ },+ {+ id: "Asia/Aqtobe",+ city: "Aqtobe",+ keywords: "aqtobe asia/aqtobe almt west kazakhstan standard time",+ },+ {+ id: "America/Araguaina",+ city: "Araguaina",+ keywords: "araguaina america/araguaina brt brasilia standard time",+ },+ {+ id: "America/Aruba",+ city: "Aruba",+ keywords: "aruba america/aruba ast atlantic standard time",+ },+ {+ id: "Asia/Ashgabat",+ city: "Ashgabat",+ keywords: "ashgabat asia/ashgabat tmt turkmenistan standard time",+ },+ {+ id: "Africa/Asmera",+ city: "Asmera",+ keywords: "asmera africa/asmera eat east africa standard time",+ },+ {+ id: "Europe/Astrakhan",+ city: "Astrakhan",+ keywords: "astrakhan europe/astrakhan msk moscow standard time",+ },+ {+ id: "America/Asuncion",+ city: "Asuncion",+ keywords: "asuncion america/asuncion pyt pyst paraguay standard time",+ },+ {+ id: "Europe/Athens",+ city: "Athens",+ keywords: "athens europe/athens eet eest eastern european standard time",+ },+ {+ id: "Asia/Atyrau",+ city: "Atyrau",+ keywords: "atyrau asia/atyrau almt west kazakhstan standard time",+ },+ {+ id: "Pacific/Auckland",+ city: "Auckland",+ keywords: "auckland pacific/auckland nzst nzdt new zealand standard time",+ },+ {+ id: "Atlantic/Azores",+ city: "Azores",+ keywords: "azores atlantic/azores azot azost azores standard time",+ },+ {+ id: "Asia/Baghdad",+ city: "Baghdad",+ keywords: "baghdad asia/baghdad ast arabian standard time",+ },+ {+ id: "America/Bahia",+ city: "Bahia",+ keywords: "bahia america/bahia brt brasilia standard time",+ },+ {+ id: "America/Bahia_Banderas",+ city: "Bahia Banderas",+ keywords:+ "bahia banderas america/bahia_banderas cst cdt central mexico standard time",+ },+ {+ id: "Asia/Bahrain",+ city: "Bahrain",+ keywords: "bahrain asia/bahrain ast arabian standard time",+ },+ {+ id: "Asia/Baku",+ city: "Baku",+ keywords: "baku asia/baku azt azerbaijan standard time",+ },+ {+ id: "Africa/Bamako",+ city: "Bamako",+ keywords: "bamako africa/bamako gmt greenwich mean standard time",+ },+ {+ id: "Asia/Bangkok",+ city: "Bangkok",+ keywords: "bangkok asia/bangkok ict indochina standard time",+ },+ {+ id: "Africa/Bangui",+ city: "Bangui",+ keywords: "bangui africa/bangui wat west africa standard time",+ },+ {+ id: "Africa/Banjul",+ city: "Banjul",+ keywords: "banjul africa/banjul gmt greenwich mean standard time",+ },+ {+ id: "America/Barbados",+ city: "Barbados",+ keywords: "barbados america/barbados ast atlantic standard time",+ },+ {+ id: "Asia/Barnaul",+ city: "Barnaul",+ keywords: "barnaul asia/barnaul krat krasnoyarsk standard time",+ },+ {+ id: "Asia/Beirut",+ city: "Beirut",+ keywords: "beirut asia/beirut eet eest eastern european standard time",+ },+ {+ id: "America/Belem",+ city: "Belem",+ keywords: "belem america/belem brt brasilia standard time",+ },+ {+ id: "Europe/Belgrade",+ city: "Belgrade",+ keywords:+ "belgrade europe/belgrade cet cest central european standard time",+ },+ {+ id: "America/Belize",+ city: "Belize",+ keywords: "belize america/belize cst central standard time",+ },+ {+ id: "Europe/Berlin",+ city: "Berlin",+ keywords: "berlin europe/berlin cet cest central european standard time",+ },+ {+ id: "Atlantic/Bermuda",+ city: "Bermuda",+ keywords: "bermuda atlantic/bermuda ast adt atlantic standard time",+ },+ {+ id: "America/North_Dakota/Beulah",+ city: "Beulah",+ keywords:+ "beulah america/north_dakota/beulah cst cdt central standard time",+ },+ {+ id: "Asia/Bishkek",+ city: "Bishkek",+ keywords: "bishkek asia/bishkek kgt kyrgyzstan standard time",+ },+ {+ id: "Africa/Bissau",+ city: "Bissau",+ keywords: "bissau africa/bissau gmt greenwich mean standard time",+ },+ {+ id: "America/Blanc-Sablon",+ city: "Blanc-Sablon",+ keywords: "blanc-sablon america/blanc-sablon ast atlantic standard time",+ },+ {+ id: "Africa/Blantyre",+ city: "Blantyre",+ keywords: "blantyre africa/blantyre cat central africa standard time",+ },+ {+ id: "America/Boa_Vista",+ city: "Boa Vista",+ keywords: "boa vista america/boa_vista amt amazon standard time",+ },+ {+ id: "America/Bogota",+ city: "Bogota",+ keywords: "bogota america/bogota cot colombia standard time",+ },+ {+ id: "America/Boise",+ city: "Boise",+ keywords: "boise america/boise mst mdt mountain standard time",+ },+ {+ id: "Pacific/Bougainville",+ city: "Bougainville",+ keywords:+ "bougainville pacific/bougainville pgt papua new guinea standard time",+ },+ {+ id: "Europe/Bratislava",+ city: "Bratislava",+ keywords:+ "bratislava europe/bratislava cet cest central european standard time",+ },+ {+ id: "Africa/Brazzaville",+ city: "Brazzaville",+ keywords: "brazzaville africa/brazzaville wat west africa standard time",+ },+ {+ id: "Australia/Brisbane",+ city: "Brisbane",+ keywords: "brisbane australia/brisbane aest brisbane standard time",+ },+ {+ id: "Australia/Broken_Hill",+ city: "Broken Hill",+ keywords:+ "broken hill australia/broken_hill acst acdt central australia standard time",+ },+ {+ id: "Asia/Brunei",+ city: "Brunei",+ keywords: "brunei asia/brunei bnt brunei darussalam standard time",+ },+ {+ id: "Europe/Brussels",+ city: "Brussels",+ keywords:+ "brussels europe/brussels cet cest central european standard time",+ },+ {+ id: "Europe/Bucharest",+ city: "Bucharest",+ keywords:+ "bucharest europe/bucharest eet eest eastern european standard time",+ },+ {+ id: "Europe/Budapest",+ city: "Budapest",+ keywords:+ "budapest europe/budapest cet cest central european standard time",+ },+ {+ id: "America/Buenos_Aires",+ city: "Buenos Aires",+ keywords: "buenos aires america/buenos_aires art argentina standard time",+ },+ {+ id: "Africa/Bujumbura",+ city: "Bujumbura",+ keywords: "bujumbura africa/bujumbura cat central africa standard time",+ },+ {+ id: "Europe/Busingen",+ city: "Busingen",+ keywords:+ "busingen europe/busingen cet cest central european standard time",+ },+ {+ id: "Africa/Cairo",+ city: "Cairo",+ keywords: "cairo africa/cairo eet eastern european standard time",+ },+ {+ id: "Asia/Calcutta",+ city: "Calcutta",+ keywords: "calcutta asia/calcutta ist india standard time",+ },+ {+ id: "America/Cambridge_Bay",+ city: "Cambridge Bay",+ keywords:+ "cambridge bay america/cambridge_bay mst mdt mountain standard time",+ },+ {+ id: "America/Campo_Grande",+ city: "Campo Grande",+ keywords: "campo grande america/campo_grande amt amazon standard time",+ },+ {+ id: "Atlantic/Canary",+ city: "Canary",+ keywords: "canary atlantic/canary wet west western european standard time",+ },+ {+ id: "America/Cancun",+ city: "Cancun",+ keywords: "cancun america/cancun est eastern standard time",+ },+ {+ id: "Atlantic/Cape_Verde",+ city: "Cape Verde",+ keywords: "cape verde atlantic/cape_verde cvt cape verde standard time",+ },+ {+ id: "America/Caracas",+ city: "Caracas",+ keywords: "caracas america/caracas vet venezuela standard time",+ },+ {+ id: "Africa/Casablanca",+ city: "Casablanca",+ keywords:+ "casablanca africa/casablanca wet west morocco standard standard time",+ },+ {+ id: "Antarctica/Casey",+ city: "Casey",+ keywords: "casey antarctica/casey cast cast casey standard time",+ },+ {+ id: "America/Catamarca",+ city: "Catamarca",+ keywords: "catamarca america/catamarca art argentina standard time",+ },+ {+ id: "America/Cayenne",+ city: "Cayenne",+ keywords: "cayenne america/cayenne gft french guiana standard time",+ },+ {+ id: "America/Cayman",+ city: "Cayman",+ keywords: "cayman america/cayman est eastern standard time",+ },+ {+ id: "America/North_Dakota/Center",+ city: "Center",+ keywords:+ "center america/north_dakota/center cst cdt central standard time",+ },+ {+ id: "Africa/Ceuta",+ city: "Ceuta",+ keywords: "ceuta africa/ceuta cet cest central european standard time",+ },+ {+ id: "Indian/Chagos",+ city: "Chagos",+ keywords: "chagos indian/chagos iot indian ocean standard time",+ },+ {+ id: "Pacific/Chatham",+ city: "Chatham",+ keywords: "chatham pacific/chatham chast chadt chatham standard time",+ },+ {+ id: "America/Chicago",+ city: "Chicago",+ keywords: "chicago america/chicago cst cdt central standard time",+ },+ {+ id: "America/Chihuahua",+ city: "Chihuahua",+ keywords:+ "chihuahua america/chihuahua hnpmx hepmx mexican pacific standard time",+ },+ {+ id: "Europe/Chisinau",+ city: "Chisinau",+ keywords:+ "chisinau europe/chisinau eet eest eastern european standard time",+ },+ {+ id: "Asia/Chita",+ city: "Chita",+ keywords: "chita asia/chita yakt yakutsk standard time",+ },+ {+ id: "Indian/Christmas",+ city: "Christmas",+ keywords: "christmas indian/christmas cxt christmas island standard time",+ },+ {+ id: "America/Ciudad_Juarez",+ city: "Ciudad Juarez",+ keywords: "ciudad juarez america/ciudad_juarez",+ },+ {+ id: "Indian/Cocos",+ city: "Cocos",+ keywords: "cocos indian/cocos cct cocos islands standard time",+ },+ {+ id: "Asia/Colombo",+ city: "Colombo",+ keywords: "colombo asia/colombo ist india standard time",+ },+ {+ id: "Indian/Comoro",+ city: "Comoro",+ keywords: "comoro indian/comoro eat east africa standard time",+ },+ {+ id: "Africa/Conakry",+ city: "Conakry",+ keywords: "conakry africa/conakry gmt greenwich mean standard time",+ },+ {+ id: "Europe/Copenhagen",+ city: "Copenhagen",+ keywords:+ "copenhagen europe/copenhagen cet cest central european standard time",+ },+ {+ id: "America/Coral_Harbour",+ city: "Coral Harbour",+ keywords: "coral harbour america/coral_harbour est eastern standard time",+ },+ {+ id: "America/Cordoba",+ city: "Cordoba",+ keywords: "cordoba america/cordoba art argentina standard time",+ },+ {+ id: "America/Costa_Rica",+ city: "Costa Rica",+ keywords: "costa rica america/costa_rica cst central standard time",+ },+ {+ id: "America/Coyhaique",+ city: "Coyhaique",+ keywords: "coyhaique america/coyhaique",+ },+ {+ id: "America/Creston",+ city: "Creston",+ keywords: "creston america/creston mst mountain standard time",+ },+ {+ id: "America/Cuiaba",+ city: "Cuiaba",+ keywords: "cuiaba america/cuiaba amt amazon standard time",+ },+ {+ id: "America/Curacao",+ city: "Curacao",+ keywords: "curacao america/curacao ast atlantic standard time",+ },+ {+ id: "Africa/Dakar",+ city: "Dakar",+ keywords: "dakar africa/dakar gmt greenwich mean standard time",+ },+ {+ id: "Asia/Damascus",+ city: "Damascus",+ keywords: "damascus asia/damascus eet eest eastern european standard time",+ },+ {+ id: "America/Danmarkshavn",+ city: "Danmarkshavn",+ keywords:+ "danmarkshavn america/danmarkshavn gmt greenwich mean standard time",+ },+ {+ id: "Africa/Dar_es_Salaam",+ city: "Dar es Salaam",+ keywords:+ "dar es salaam africa/dar_es_salaam eat east africa standard time",+ },+ {+ id: "Australia/Darwin",+ city: "Darwin",+ keywords: "darwin australia/darwin acst australian central standard time",+ },+ {+ id: "Antarctica/Davis",+ city: "Davis",+ keywords: "davis antarctica/davis davt davis standard time",+ },+ {+ id: "America/Dawson",+ city: "Dawson",+ keywords: "dawson america/dawson mst mountain standard time",+ },+ {+ id: "America/Dawson_Creek",+ city: "Dawson Creek",+ keywords: "dawson creek america/dawson_creek mst mountain standard time",+ },+ {+ id: "America/Denver",+ city: "Denver",+ keywords: "denver america/denver mst mdt mountain standard time",+ },+ {+ id: "America/Detroit",+ city: "Detroit",+ keywords: "detroit america/detroit est edt eastern standard time",+ },+ {+ id: "Asia/Dhaka",+ city: "Dhaka",+ keywords: "dhaka asia/dhaka bst bangladesh standard time",+ },+ {+ id: "Asia/Dili",+ city: "Dili",+ keywords: "dili asia/dili tlt east timor standard time",+ },+ {+ id: "Africa/Djibouti",+ city: "Djibouti",+ keywords: "djibouti africa/djibouti eat east africa standard time",+ },+ {+ id: "America/Dominica",+ city: "Dominica",+ keywords: "dominica america/dominica ast atlantic standard time",+ },+ {+ id: "Africa/Douala",+ city: "Douala",+ keywords: "douala africa/douala wat west africa standard time",+ },+ {+ id: "Asia/Dubai",+ city: "Dubai",+ keywords: "dubai asia/dubai gst gulf standard time",+ },+ {+ id: "Europe/Dublin",+ city: "Dublin",+ keywords: "dublin europe/dublin gmt ist irish standard time",+ },+ {+ id: "Antarctica/DumontDUrville",+ city: "DumontDUrville",+ keywords:+ "dumontdurville antarctica/dumontdurville pgt papua new guinea standard time",+ },+ {+ id: "Asia/Dushanbe",+ city: "Dushanbe",+ keywords: "dushanbe asia/dushanbe tjt tajikistan standard time",+ },+ {+ id: "Pacific/Easter",+ city: "Easter",+ keywords: "easter pacific/easter east easst easter island standard time",+ },+ {+ id: "America/Edmonton",+ city: "Edmonton",+ keywords: "edmonton america/edmonton mst mdt mountain standard time",+ },+ {+ id: "Pacific/Efate",+ city: "Efate",+ keywords: "efate pacific/efate vut vanuatu standard time",+ },+ {+ id: "America/Eirunepe",+ city: "Eirunepe",+ keywords: "eirunepe america/eirunepe act acre standard time",+ },+ {+ id: "Africa/El_Aaiun",+ city: "El Aaiun",+ keywords:+ "el aaiun africa/el_aaiun wet west morocco standard standard time",+ },+ {+ id: "America/El_Salvador",+ city: "El Salvador",+ keywords: "el salvador america/el_salvador cst central standard time",+ },+ {+ id: "Pacific/Enderbury",+ city: "Enderbury",+ keywords: "enderbury pacific/enderbury phot phoenix islands standard time",+ },+ {+ id: "Australia/Eucla",+ city: "Eucla",+ keywords:+ "eucla australia/eucla acwst australian central western standard time",+ },+ {+ id: "Atlantic/Faeroe",+ city: "Faeroe",+ keywords: "faeroe atlantic/faeroe wet west western european standard time",+ },+ {+ id: "Pacific/Fakaofo",+ city: "Fakaofo",+ keywords: "fakaofo pacific/fakaofo tkt tokelau standard time",+ },+ {+ id: "Asia/Famagusta",+ city: "Famagusta",+ keywords:+ "famagusta asia/famagusta eet eest eastern european standard time",+ },+ {+ id: "Pacific/Fiji",+ city: "Fiji",+ keywords: "fiji pacific/fiji fjt fjt fiji standard time",+ },+ {+ id: "America/Fort_Nelson",+ city: "Fort Nelson",+ keywords: "fort nelson america/fort_nelson mst mountain standard time",+ },+ {+ id: "America/Fortaleza",+ city: "Fortaleza",+ keywords: "fortaleza america/fortaleza brt brasilia standard time",+ },+ {+ id: "Africa/Freetown",+ city: "Freetown",+ keywords: "freetown africa/freetown gmt greenwich mean standard time",+ },+ {+ id: "Pacific/Funafuti",+ city: "Funafuti",+ keywords: "funafuti pacific/funafuti tvt tuvalu standard time",+ },+ {+ id: "Africa/Gaborone",+ city: "Gaborone",+ keywords: "gaborone africa/gaborone cat central africa standard time",+ },+ {+ id: "Pacific/Galapagos",+ city: "Galapagos",+ keywords: "galapagos pacific/galapagos cot colombia standard time",+ },+ {+ id: "Pacific/Gambier",+ city: "Gambier",+ keywords: "gambier pacific/gambier gamt gambier standard time",+ },+ {+ id: "Asia/Gaza",+ city: "Gaza",+ keywords: "gaza asia/gaza eet eest eastern european standard time",+ },+ {+ id: "Europe/Gibraltar",+ city: "Gibraltar",+ keywords:+ "gibraltar europe/gibraltar cet cest central european standard time",+ },+ {+ id: "America/Glace_Bay",+ city: "Glace Bay",+ keywords: "glace bay america/glace_bay ast adt atlantic standard time",+ },+ {+ id: "America/Godthab",+ city: "Godthab",+ keywords: "godthab america/godthab wgt wgst west greenland standard time",+ },+ {+ id: "America/Goose_Bay",+ city: "Goose Bay",+ keywords: "goose bay america/goose_bay ast adt atlantic standard time",+ },+ {+ id: "America/Grand_Turk",+ city: "Grand Turk",+ keywords: "grand turk america/grand_turk est edt eastern standard time",+ },+ {+ id: "America/Grenada",+ city: "Grenada",+ keywords: "grenada america/grenada ast atlantic standard time",+ },+ {+ id: "Pacific/Guadalcanal",+ city: "Guadalcanal",+ keywords:+ "guadalcanal pacific/guadalcanal sbt solomon islands standard time",+ },+ {+ id: "America/Guadeloupe",+ city: "Guadeloupe",+ keywords: "guadeloupe america/guadeloupe ast atlantic standard time",+ },+ {+ id: "Pacific/Guam",+ city: "Guam",+ keywords: "guam pacific/guam chst chamorro standard time",+ },+ {+ id: "America/Guatemala",+ city: "Guatemala",+ keywords: "guatemala america/guatemala cst central standard time",+ },+ {+ id: "America/Guayaquil",+ city: "Guayaquil",+ keywords: "guayaquil america/guayaquil ect ecuador standard time",+ },+ {+ id: "Europe/Guernsey",+ city: "Guernsey",+ keywords: "guernsey europe/guernsey gmt bst british standard time",+ },+ {+ id: "America/Guyana",+ city: "Guyana",+ keywords: "guyana america/guyana gyt guyana standard time",+ },+ {+ id: "America/Halifax",+ city: "Halifax",+ keywords: "halifax america/halifax ast adt atlantic standard time",+ },+ {+ id: "Africa/Harare",+ city: "Harare",+ keywords: "harare africa/harare cat central africa standard time",+ },+ {+ id: "America/Havana",+ city: "Havana",+ keywords: "havana america/havana hncu hecu cuba standard time",+ },+ {+ id: "Asia/Hebron",+ city: "Hebron",+ keywords: "hebron asia/hebron eet eest eastern european standard time",+ },+ {+ id: "Europe/Helsinki",+ city: "Helsinki",+ keywords:+ "helsinki europe/helsinki eet eest eastern european standard time",+ },+ {+ id: "America/Hermosillo",+ city: "Hermosillo",+ keywords:+ "hermosillo america/hermosillo hnpmx mexican pacific standard time",+ },+ {+ id: "Australia/Hobart",+ city: "Hobart",+ keywords:+ "hobart australia/hobart aest aedt eastern australia standard time",+ },+ {+ id: "Asia/Hong_Kong",+ city: "Hong Kong",+ keywords: "hong kong asia/hong_kong hkt hong kong standard time",+ },+ {+ id: "Pacific/Honolulu",+ city: "Honolulu",+ keywords: "honolulu pacific/honolulu hast hawaii-aleutian standard time",+ },+ {+ id: "Asia/Hovd",+ city: "Hovd",+ keywords: "hovd asia/hovd hovt hovd standard time",+ },+ {+ id: "America/Indianapolis",+ city: "Indianapolis",+ keywords: "indianapolis america/indianapolis est edt eastern standard time",+ },+ {+ id: "America/Indiana/Indianapolis",+ city: "Indianapolis",+ keywords:+ "indianapolis america/indiana/indianapolis est edt eastern standard time",+ },+ {+ id: "America/Inuvik",+ city: "Inuvik",+ keywords: "inuvik america/inuvik mst mdt mountain standard time",+ },+ {+ id: "America/Iqaluit",+ city: "Iqaluit",+ keywords: "iqaluit america/iqaluit est edt eastern standard time",+ },+ {+ id: "Asia/Irkutsk",+ city: "Irkutsk",+ keywords: "irkutsk asia/irkutsk irkt irkutsk standard time",+ },+ {+ id: "Europe/Isle_of_Man",+ city: "Isle of Man",+ keywords: "isle of man europe/isle_of_man gmt bst british standard time",+ },+ {+ id: "Europe/Istanbul",+ city: "Istanbul",+ keywords: "istanbul europe/istanbul trt turkey standard time",+ },+ {+ id: "Asia/Jakarta",+ city: "Jakarta",+ keywords: "jakarta asia/jakarta wib western indonesia standard time",+ },+ {+ id: "America/Jamaica",+ city: "Jamaica",+ keywords: "jamaica america/jamaica est eastern standard time",+ },+ {+ id: "Asia/Jayapura",+ city: "Jayapura",+ keywords: "jayapura asia/jayapura wit eastern indonesia standard time",+ },+ {+ id: "Europe/Jersey",+ city: "Jersey",+ keywords: "jersey europe/jersey gmt bst british standard time",+ },+ {+ id: "Asia/Jerusalem",+ city: "Jerusalem",+ keywords: "jerusalem asia/jerusalem ist idt israel standard time",+ },+ {+ id: "Africa/Johannesburg",+ city: "Johannesburg",+ keywords:+ "johannesburg africa/johannesburg sast south africa standard time",+ },+ {+ id: "Pacific/Johnston",+ city: "Johnston",+ keywords: "johnston pacific/johnston hast hawaii-aleutian standard time",+ },+ {+ id: "Africa/Juba",+ city: "Juba",+ keywords: "juba africa/juba cat central africa standard time",+ },+ {+ id: "America/Jujuy",+ city: "Jujuy",+ keywords: "jujuy america/jujuy art argentina standard time",+ },+ {+ id: "America/Juneau",+ city: "Juneau",+ keywords: "juneau america/juneau akst akdt alaska standard time",+ },+ {+ id: "Asia/Kabul",+ city: "Kabul",+ keywords: "kabul asia/kabul aft afghanistan standard time",+ },+ {+ id: "Europe/Kaliningrad",+ city: "Kaliningrad",+ keywords:+ "kaliningrad europe/kaliningrad eet eastern european standard time",+ },+ {+ id: "Asia/Kamchatka",+ city: "Kamchatka",+ keywords:+ "kamchatka asia/kamchatka pett petropavlovsk-kamchatski standard time",+ },+ {+ id: "Africa/Kampala",+ city: "Kampala",+ keywords: "kampala africa/kampala eat east africa standard time",+ },+ {+ id: "Asia/Karachi",+ city: "Karachi",+ keywords: "karachi asia/karachi pkt pakistan standard time",+ },+ {+ id: "Asia/Katmandu",+ city: "Katmandu",+ keywords: "katmandu asia/katmandu npt nepal standard time",+ },+ {+ id: "Indian/Kerguelen",+ city: "Kerguelen",+ keywords:+ "kerguelen indian/kerguelen tft french southern & antarctic standard time",+ },+ {+ id: "Asia/Khandyga",+ city: "Khandyga",+ keywords: "khandyga asia/khandyga yakt yakutsk standard time",+ },+ {+ id: "Africa/Khartoum",+ city: "Khartoum",+ keywords: "khartoum africa/khartoum cat central africa standard time",+ },+ {+ id: "Europe/Kiev",+ city: "Kiev",+ keywords: "kiev europe/kiev eet eest eastern european standard time",+ },+ {+ id: "Africa/Kigali",+ city: "Kigali",+ keywords: "kigali africa/kigali cat central africa standard time",+ },+ {+ id: "Africa/Kinshasa",+ city: "Kinshasa",+ keywords: "kinshasa africa/kinshasa wat west africa standard time",+ },+ {+ id: "Pacific/Kiritimati",+ city: "Kiritimati",+ keywords: "kiritimati pacific/kiritimati lint line islands standard time",+ },+ {+ id: "Europe/Kirov",+ city: "Kirov",+ keywords: "kirov europe/kirov msk moscow standard time",+ },+ {+ id: "America/Indiana/Knox",+ city: "Knox",+ keywords: "knox america/indiana/knox cst cdt central standard time",+ },+ {+ id: "Pacific/Kosrae",+ city: "Kosrae",+ keywords: "kosrae pacific/kosrae kost kosrae standard time",+ },+ {+ id: "America/Kralendijk",+ city: "Kralendijk",+ keywords: "kralendijk america/kralendijk ast atlantic standard time",+ },+ {+ id: "Asia/Krasnoyarsk",+ city: "Krasnoyarsk",+ keywords: "krasnoyarsk asia/krasnoyarsk krat krasnoyarsk standard time",+ },+ {+ id: "Asia/Kuala_Lumpur",+ city: "Kuala Lumpur",+ keywords: "kuala lumpur asia/kuala_lumpur myt malaysia standard time",+ },+ {+ id: "Asia/Kuching",+ city: "Kuching",+ keywords: "kuching asia/kuching myt malaysia standard time",+ },+ {+ id: "Asia/Kuwait",+ city: "Kuwait",+ keywords: "kuwait asia/kuwait ast arabian standard time",+ },+ {+ id: "Pacific/Kwajalein",+ city: "Kwajalein",+ keywords: "kwajalein pacific/kwajalein mht marshall islands standard time",+ },+ {+ id: "America/La_Paz",+ city: "La Paz",+ keywords: "la paz america/la_paz bot bolivia standard time",+ },+ {+ id: "America/Argentina/La_Rioja",+ city: "La Rioja",+ keywords: "la rioja america/argentina/la_rioja art argentina standard time",+ },+ {+ id: "Africa/Lagos",+ city: "Lagos",+ keywords: "lagos africa/lagos wat west africa standard time",+ },+ {+ id: "Africa/Libreville",+ city: "Libreville",+ keywords: "libreville africa/libreville wat west africa standard time",+ },+ {+ id: "America/Lima",+ city: "Lima",+ keywords: "lima america/lima pet peru standard time",+ },+ {+ id: "Australia/Lindeman",+ city: "Lindeman",+ keywords: "lindeman australia/lindeman aest brisbane standard time",+ },+ {+ id: "Europe/Lisbon",+ city: "Lisbon",+ keywords: "lisbon europe/lisbon wet west western european standard time",+ },+ {+ id: "Europe/Ljubljana",+ city: "Ljubljana",+ keywords:+ "ljubljana europe/ljubljana cet cest central european standard time",+ },+ {+ id: "Africa/Lome",+ city: "Lome",+ keywords: "lome africa/lome gmt greenwich mean standard time",+ },+ {+ id: "Europe/London",+ city: "London",+ keywords: "london europe/london gmt bst british standard time",+ },+ {+ id: "Arctic/Longyearbyen",+ city: "Longyearbyen",+ keywords:+ "longyearbyen arctic/longyearbyen cet cest central european standard time",+ },+ {+ id: "Australia/Lord_Howe",+ city: "Lord Howe",+ keywords: "lord howe australia/lord_howe lhst lhdt lord howe standard time",+ },+ {+ id: "America/Los_Angeles",+ city: "Los Angeles",+ keywords: "los angeles america/los_angeles pst pdt pacific standard time",+ },+ {+ id: "America/Louisville",+ city: "Louisville",+ keywords: "louisville america/louisville est edt eastern standard time",+ },+ {+ id: "America/Lower_Princes",+ city: "Lower Princes",+ keywords: "lower princes america/lower_princes ast atlantic standard time",+ },+ {+ id: "Africa/Luanda",+ city: "Luanda",+ keywords: "luanda africa/luanda wat west africa standard time",+ },+ {+ id: "Africa/Lubumbashi",+ city: "Lubumbashi",+ keywords: "lubumbashi africa/lubumbashi cat central africa standard time",+ },+ {+ id: "Africa/Lusaka",+ city: "Lusaka",+ keywords: "lusaka africa/lusaka cat central africa standard time",+ },+ {+ id: "Europe/Luxembourg",+ city: "Luxembourg",+ keywords:+ "luxembourg europe/luxembourg cet cest central european standard time",+ },+ {+ id: "Asia/Macau",+ city: "Macau",+ keywords: "macau asia/macau cst china standard time",+ },+ {+ id: "America/Maceio",+ city: "Maceio",+ keywords: "maceio america/maceio brt brasilia standard time",+ },+ {+ id: "Antarctica/Macquarie",+ city: "Macquarie",+ keywords:+ "macquarie antarctica/macquarie aest aedt eastern australia standard time",+ },+ {+ id: "Atlantic/Madeira",+ city: "Madeira",+ keywords:+ "madeira atlantic/madeira wet west western european standard time",+ },+ {+ id: "Europe/Madrid",+ city: "Madrid",+ keywords: "madrid europe/madrid cet cest central european standard time",+ },+ {+ id: "Asia/Magadan",+ city: "Magadan",+ keywords: "magadan asia/magadan magt magadan standard time",+ },+ {+ id: "Indian/Mahe",+ city: "Mahe",+ keywords: "mahe indian/mahe sct seychelles standard time",+ },+ {+ id: "Pacific/Majuro",+ city: "Majuro",+ keywords: "majuro pacific/majuro mht marshall islands standard time",+ },+ {+ id: "Asia/Makassar",+ city: "Makassar",+ keywords: "makassar asia/makassar wita central indonesia standard time",+ },+ {+ id: "Africa/Malabo",+ city: "Malabo",+ keywords: "malabo africa/malabo wat west africa standard time",+ },+ {+ id: "Indian/Maldives",+ city: "Maldives",+ keywords: "maldives indian/maldives mvt maldives standard time",+ },+ {+ id: "Europe/Malta",+ city: "Malta",+ keywords: "malta europe/malta cet cest central european standard time",+ },+ {+ id: "America/Managua",+ city: "Managua",+ keywords: "managua america/managua cst central standard time",+ },+ {+ id: "America/Manaus",+ city: "Manaus",+ keywords: "manaus america/manaus amt amazon standard time",+ },+ {+ id: "Asia/Manila",+ city: "Manila",+ keywords: "manila asia/manila phst philippine standard time",+ },+ {+ id: "Africa/Maputo",+ city: "Maputo",+ keywords: "maputo africa/maputo cat central africa standard time",+ },+ {+ id: "America/Indiana/Marengo",+ city: "Marengo",+ keywords: "marengo america/indiana/marengo est edt eastern standard time",+ },+ {+ id: "Europe/Mariehamn",+ city: "Mariehamn",+ keywords:+ "mariehamn europe/mariehamn eet eest eastern european standard time",+ },+ {+ id: "America/Marigot",+ city: "Marigot",+ keywords: "marigot america/marigot ast atlantic standard time",+ },+ {+ id: "Pacific/Marquesas",+ city: "Marquesas",+ keywords: "marquesas pacific/marquesas mart marquesas standard time",+ },+ {+ id: "America/Martinique",+ city: "Martinique",+ keywords: "martinique america/martinique ast atlantic standard time",+ },+ {+ id: "Africa/Maseru",+ city: "Maseru",+ keywords: "maseru africa/maseru sast south africa standard time",+ },+ {+ id: "America/Matamoros",+ city: "Matamoros",+ keywords: "matamoros america/matamoros cst cdt central standard time",+ },+ {+ id: "Indian/Mauritius",+ city: "Mauritius",+ keywords: "mauritius indian/mauritius mut mauritius standard time",+ },+ {+ id: "Antarctica/Mawson",+ city: "Mawson",+ keywords: "mawson antarctica/mawson mawt mawson standard time",+ },+ {+ id: "Indian/Mayotte",+ city: "Mayotte",+ keywords: "mayotte indian/mayotte eat east africa standard time",+ },+ {+ id: "America/Mazatlan",+ city: "Mazatlan",+ keywords:+ "mazatlan america/mazatlan hnpmx hepmx mexican pacific standard time",+ },+ {+ id: "Africa/Mbabane",+ city: "Mbabane",+ keywords: "mbabane africa/mbabane sast south africa standard time",+ },+ {+ id: "Antarctica/McMurdo",+ city: "McMurdo",+ keywords: "mcmurdo antarctica/mcmurdo nzst nzdt new zealand standard time",+ },+ {+ id: "Australia/Melbourne",+ city: "Melbourne",+ keywords:+ "melbourne australia/melbourne aest aedt eastern australia standard time",+ },+ {+ id: "America/Mendoza",+ city: "Mendoza",+ keywords: "mendoza america/mendoza art argentina standard time",+ },+ {+ id: "America/Menominee",+ city: "Menominee",+ keywords: "menominee america/menominee cst cdt central standard time",+ },+ {+ id: "America/Merida",+ city: "Merida",+ keywords: "merida america/merida cst cdt central mexico standard time",+ },+ {+ id: "America/Metlakatla",+ city: "Metlakatla",+ keywords: "metlakatla america/metlakatla akst akdt alaska standard time",+ },+ {+ id: "America/Mexico_City",+ city: "Mexico City",+ keywords:+ "mexico city america/mexico_city cst cdt central mexico standard time",+ },+ {+ id: "Pacific/Midway",+ city: "Midway",+ keywords: "midway pacific/midway sst samoa standard time",+ },+ {+ id: "Europe/Minsk",+ city: "Minsk",+ keywords: "minsk europe/minsk msk moscow standard time",+ },+ {+ id: "America/Miquelon",+ city: "Miquelon",+ keywords:+ "miquelon america/miquelon hnpm hepm st. pierre & miquelon standard time",+ },+ {+ id: "Africa/Mogadishu",+ city: "Mogadishu",+ keywords: "mogadishu africa/mogadishu eat east africa standard time",+ },+ {+ id: "Europe/Monaco",+ city: "Monaco",+ keywords: "monaco europe/monaco cet cest central european standard time",+ },+ {+ id: "America/Moncton",+ city: "Moncton",+ keywords: "moncton america/moncton ast adt atlantic standard time",+ },+ {+ id: "Africa/Monrovia",+ city: "Monrovia",+ keywords: "monrovia africa/monrovia gmt greenwich mean standard time",+ },+ {+ id: "America/Monterrey",+ city: "Monterrey",+ keywords:+ "monterrey america/monterrey cst cdt central mexico standard time",+ },+ {+ id: "America/Montevideo",+ city: "Montevideo",+ keywords: "montevideo america/montevideo uyt uruguay standard time",+ },+ {+ id: "America/Kentucky/Monticello",+ city: "Monticello",+ keywords:+ "monticello america/kentucky/monticello est edt eastern standard time",+ },+ {+ id: "America/Montreal",+ city: "Montreal",+ keywords: "montreal america/montreal est edt eastern standard time",+ },+ {+ id: "America/Montserrat",+ city: "Montserrat",+ keywords: "montserrat america/montserrat ast atlantic standard time",+ },+ {+ id: "Europe/Moscow",+ city: "Moscow",+ keywords: "moscow europe/moscow msk moscow standard time",+ },+ {+ id: "Asia/Muscat",+ city: "Muscat",+ keywords: "muscat asia/muscat gst gulf standard time",+ },+ {+ id: "Africa/Nairobi",+ city: "Nairobi",+ keywords: "nairobi africa/nairobi eat east africa standard time",+ },+ {+ id: "America/Nassau",+ city: "Nassau",+ keywords: "nassau america/nassau est edt eastern standard time",+ },+ {+ id: "Pacific/Nauru",+ city: "Nauru",+ keywords: "nauru pacific/nauru nrt nauru standard time",+ },+ {+ id: "Africa/Ndjamena",+ city: "Ndjamena",+ keywords: "ndjamena africa/ndjamena wat west africa standard time",+ },+ {+ id: "America/North_Dakota/New_Salem",+ city: "New Salem",+ keywords:+ "new salem america/north_dakota/new_salem cst cdt central standard time",+ },+ {+ id: "America/New_York",+ city: "New York",+ keywords: "new york america/new_york est edt eastern standard time",+ },+ {+ id: "Africa/Niamey",+ city: "Niamey",+ keywords: "niamey africa/niamey wat west africa standard time",+ },+ {+ id: "Asia/Nicosia",+ city: "Nicosia",+ keywords: "nicosia asia/nicosia eet eest eastern european standard time",+ },+ {+ id: "Pacific/Niue",+ city: "Niue",+ keywords: "niue pacific/niue nut niue standard time",+ },+ {+ id: "America/Nome",+ city: "Nome",+ keywords: "nome america/nome akst akdt alaska standard time",+ },+ {+ id: "Pacific/Norfolk",+ city: "Norfolk",+ keywords: "norfolk pacific/norfolk nft nfdt norfolk island standard time",+ },+ {+ id: "America/Noronha",+ city: "Noronha",+ keywords: "noronha america/noronha fnt fernando de noronha standard time",+ },+ {+ id: "Africa/Nouakchott",+ city: "Nouakchott",+ keywords: "nouakchott africa/nouakchott gmt greenwich mean standard time",+ },+ {+ id: "Pacific/Noumea",+ city: "Noumea",+ keywords: "noumea pacific/noumea nct new caledonia standard time",+ },+ {+ id: "Asia/Novokuznetsk",+ city: "Novokuznetsk",+ keywords: "novokuznetsk asia/novokuznetsk krat krasnoyarsk standard time",+ },+ {+ id: "Asia/Novosibirsk",+ city: "Novosibirsk",+ keywords: "novosibirsk asia/novosibirsk novt novosibirsk standard time",+ },+ {+ id: "America/Ojinaga",+ city: "Ojinaga",+ keywords: "ojinaga america/ojinaga mst mdt mountain standard time",+ },+ {+ id: "Asia/Omsk",+ city: "Omsk",+ keywords: "omsk asia/omsk omst omsk standard time",+ },+ {+ id: "Asia/Oral",+ city: "Oral",+ keywords: "oral asia/oral almt west kazakhstan standard time",+ },+ {+ id: "Europe/Oslo",+ city: "Oslo",+ keywords: "oslo europe/oslo cet cest central european standard time",+ },+ {+ id: "Africa/Ouagadougou",+ city: "Ouagadougou",+ keywords: "ouagadougou africa/ouagadougou gmt greenwich mean standard time",+ },+ {+ id: "Pacific/Pago_Pago",+ city: "Pago Pago",+ keywords: "pago pago pacific/pago_pago sst samoa standard time",+ },+ {+ id: "Pacific/Palau",+ city: "Palau",+ keywords: "palau pacific/palau pwt palau standard time",+ },+ {+ id: "Antarctica/Palmer",+ city: "Palmer",+ keywords: "palmer antarctica/palmer art argentina standard time",+ },+ {+ id: "America/Panama",+ city: "Panama",+ keywords: "panama america/panama est eastern standard time",+ },+ {+ id: "America/Paramaribo",+ city: "Paramaribo",+ keywords: "paramaribo america/paramaribo srt suriname standard time",+ },+ {+ id: "Europe/Paris",+ city: "Paris",+ keywords: "paris europe/paris cet cest central european standard time",+ },+ {+ id: "Australia/Perth",+ city: "Perth",+ keywords: "perth australia/perth awst western australia standard time",+ },+ {+ id: "America/Indiana/Petersburg",+ city: "Petersburg",+ keywords:+ "petersburg america/indiana/petersburg est edt eastern standard time",+ },+ {+ id: "Asia/Phnom_Penh",+ city: "Phnom Penh",+ keywords: "phnom penh asia/phnom_penh ict indochina standard time",+ },+ {+ id: "America/Phoenix",+ city: "Phoenix",+ keywords: "phoenix america/phoenix mst mountain standard time",+ },+ {+ id: "Pacific/Pitcairn",+ city: "Pitcairn",+ keywords: "pitcairn pacific/pitcairn pst pitcairn standard time",+ },+ {+ id: "Europe/Podgorica",+ city: "Podgorica",+ keywords:+ "podgorica europe/podgorica cet cest central european standard time",+ },+ {+ id: "Pacific/Ponape",+ city: "Ponape",+ keywords: "ponape pacific/ponape pont ponape standard time",+ },+ {+ id: "Asia/Pontianak",+ city: "Pontianak",+ keywords: "pontianak asia/pontianak wib western indonesia standard time",+ },+ {+ id: "Pacific/Port_Moresby",+ city: "Port Moresby",+ keywords:+ "port moresby pacific/port_moresby pgt papua new guinea standard time",+ },+ {+ id: "America/Port_of_Spain",+ city: "Port of Spain",+ keywords: "port of spain america/port_of_spain ast atlantic standard time",+ },+ {+ id: "America/Port-au-Prince",+ city: "Port-au-Prince",+ keywords:+ "port-au-prince america/port-au-prince est edt eastern standard time",+ },+ {+ id: "America/Porto_Velho",+ city: "Porto Velho",+ keywords: "porto velho america/porto_velho amt amazon standard time",+ },+ {+ id: "Africa/Porto-Novo",+ city: "Porto-Novo",+ keywords: "porto-novo africa/porto-novo wat west africa standard time",+ },+ {+ id: "Europe/Prague",+ city: "Prague",+ keywords: "prague europe/prague cet cest central european standard time",+ },+ {+ id: "America/Puerto_Rico",+ city: "Puerto Rico",+ keywords: "puerto rico america/puerto_rico ast atlantic standard time",+ },+ {+ id: "America/Punta_Arenas",+ city: "Punta Arenas",+ keywords: "punta arenas america/punta_arenas clt chile standard time",+ },+ {+ id: "Asia/Pyongyang",+ city: "Pyongyang",+ keywords: "pyongyang asia/pyongyang kst korean standard time",+ },+ {+ id: "Asia/Qatar",+ city: "Qatar",+ keywords: "qatar asia/qatar ast arabian standard time",+ },+ {+ id: "Asia/Qostanay",+ city: "Qostanay",+ keywords: "qostanay asia/qostanay almt east kazakhstan standard time",+ },+ {+ id: "Asia/Qyzylorda",+ city: "Qyzylorda",+ keywords: "qyzylorda asia/qyzylorda almt west kazakhstan standard time",+ },+ {+ id: "Asia/Rangoon",+ city: "Rangoon",+ keywords: "rangoon asia/rangoon mmt myanmar standard time",+ },+ {+ id: "America/Rankin_Inlet",+ city: "Rankin Inlet",+ keywords: "rankin inlet america/rankin_inlet cst cdt central standard time",+ },+ {+ id: "Pacific/Rarotonga",+ city: "Rarotonga",+ keywords: "rarotonga pacific/rarotonga ckt cook islands standard time",+ },+ {+ id: "America/Recife",+ city: "Recife",+ keywords: "recife america/recife brt brasilia standard time",+ },+ {+ id: "America/Regina",+ city: "Regina",+ keywords: "regina america/regina cst central standard time",+ },+ {+ id: "America/Resolute",+ city: "Resolute",+ keywords: "resolute america/resolute cst cdt central standard time",+ },+ {+ id: "Indian/Reunion",+ city: "Reunion",+ keywords: "reunion indian/reunion ret réunion standard time",+ },+ {+ id: "Atlantic/Reykjavik",+ city: "Reykjavik",+ keywords: "reykjavik atlantic/reykjavik gmt greenwich mean standard time",+ },+ {+ id: "Europe/Riga",+ city: "Riga",+ keywords: "riga europe/riga eet eest eastern european standard time",+ },+ {+ id: "America/Rio_Branco",+ city: "Rio Branco",+ keywords: "rio branco america/rio_branco act acre standard time",+ },+ {+ id: "America/Argentina/Rio_Gallegos",+ city: "Rio Gallegos",+ keywords:+ "rio gallegos america/argentina/rio_gallegos art argentina standard time",+ },+ {+ id: "Asia/Riyadh",+ city: "Riyadh",+ keywords: "riyadh asia/riyadh ast arabian standard time",+ },+ {+ id: "Europe/Rome",+ city: "Rome",+ keywords: "rome europe/rome cet cest central european standard time",+ },+ {+ id: "Antarctica/Rothera",+ city: "Rothera",+ keywords: "rothera antarctica/rothera art argentina standard time",+ },+ {+ id: "Asia/Saigon",+ city: "Saigon",+ keywords: "saigon asia/saigon ict indochina standard time",+ },+ {+ id: "Pacific/Saipan",+ city: "Saipan",+ keywords: "saipan pacific/saipan chst chamorro standard time",+ },+ {+ id: "Asia/Sakhalin",+ city: "Sakhalin",+ keywords: "sakhalin asia/sakhalin sakt sakhalin standard time",+ },+ {+ id: "America/Argentina/Salta",+ city: "Salta",+ keywords: "salta america/argentina/salta art argentina standard time",+ },+ {+ id: "Europe/Samara",+ city: "Samara",+ keywords: "samara europe/samara samt samara standard time",+ },+ {+ id: "Asia/Samarkand",+ city: "Samarkand",+ keywords: "samarkand asia/samarkand uzt uzbekistan standard time",+ },+ {+ id: "America/Argentina/San_Juan",+ city: "San Juan",+ keywords: "san juan america/argentina/san_juan art argentina standard time",+ },+ {+ id: "America/Argentina/San_Luis",+ city: "San Luis",+ keywords: "san luis america/argentina/san_luis art argentina standard time",+ },+ {+ id: "Europe/San_Marino",+ city: "San Marino",+ keywords:+ "san marino europe/san_marino cet cest central european standard time",+ },+ {+ id: "America/Santa_Isabel",+ city: "Santa Isabel",+ keywords: "santa isabel america/santa_isabel pst pdt pacific standard time",+ },+ {+ id: "America/Santarem",+ city: "Santarem",+ keywords: "santarem america/santarem brt brasilia standard time",+ },+ {+ id: "America/Santiago",+ city: "Santiago",+ keywords: "santiago america/santiago clt clst chile standard time",+ },+ {+ id: "America/Santo_Domingo",+ city: "Santo Domingo",+ keywords: "santo domingo america/santo_domingo ast atlantic standard time",+ },+ {+ id: "America/Sao_Paulo",+ city: "Sao Paulo",+ keywords: "sao paulo america/sao_paulo brt brasilia standard time",+ },+ {+ id: "Africa/Sao_Tome",+ city: "Sao Tome",+ keywords: "sao tome africa/sao_tome gmt greenwich mean standard time",+ },+ {+ id: "Europe/Sarajevo",+ city: "Sarajevo",+ keywords:+ "sarajevo europe/sarajevo cet cest central european standard time",+ },+ {+ id: "Europe/Saratov",+ city: "Saratov",+ keywords: "saratov europe/saratov samt samara standard time",+ },+ {+ id: "America/Scoresbysund",+ city: "Scoresbysund",+ keywords:+ "scoresbysund america/scoresbysund hneg heeg east greenland standard time",+ },+ {+ id: "Asia/Seoul",+ city: "Seoul",+ keywords: "seoul asia/seoul kst korean standard time",+ },+ {+ id: "Asia/Shanghai",+ city: "Shanghai",+ keywords: "shanghai asia/shanghai cst china standard time",+ },+ {+ id: "Europe/Simferopol",+ city: "Simferopol",+ keywords:+ "simferopol europe/simferopol eet eest eastern european standard time",+ },+ {+ id: "Asia/Singapore",+ city: "Singapore",+ keywords: "singapore asia/singapore sgt singapore standard time",+ },+ {+ id: "America/Sitka",+ city: "Sitka",+ keywords: "sitka america/sitka akst akdt alaska standard time",+ },+ {+ id: "Europe/Skopje",+ city: "Skopje",+ keywords: "skopje europe/skopje cet cest central european standard time",+ },+ {+ id: "Europe/Sofia",+ city: "Sofia",+ keywords: "sofia europe/sofia eet eest eastern european standard time",+ },+ {+ id: "Atlantic/South_Georgia",+ city: "South Georgia",+ keywords:+ "south georgia atlantic/south_georgia gst south georgia standard time",+ },+ {+ id: "Asia/Srednekolymsk",+ city: "Srednekolymsk",+ keywords:+ "srednekolymsk asia/srednekolymsk sret srednekolymsk standard time",+ },+ {+ id: "America/St_Barthelemy",+ city: "St Barthelemy",+ keywords: "st barthelemy america/st_barthelemy ast atlantic standard time",+ },+ {+ id: "Atlantic/St_Helena",+ city: "St Helena",+ keywords: "st helena atlantic/st_helena gmt greenwich mean standard time",+ },+ {+ id: "America/St_Johns",+ city: "St Johns",+ keywords: "st johns america/st_johns hntn hetn newfoundland standard time",+ },+ {+ id: "America/St_Kitts",+ city: "St Kitts",+ keywords: "st kitts america/st_kitts ast atlantic standard time",+ },+ {+ id: "America/St_Lucia",+ city: "St Lucia",+ keywords: "st lucia america/st_lucia ast atlantic standard time",+ },+ {+ id: "America/St_Thomas",+ city: "St Thomas",+ keywords: "st thomas america/st_thomas ast atlantic standard time",+ },+ {+ id: "America/St_Vincent",+ city: "St Vincent",+ keywords: "st vincent america/st_vincent ast atlantic standard time",+ },+ {+ id: "Atlantic/Stanley",+ city: "Stanley",+ keywords: "stanley atlantic/stanley fkst falkland islands standard time",+ },+ {+ id: "Europe/Stockholm",+ city: "Stockholm",+ keywords:+ "stockholm europe/stockholm cet cest central european standard time",+ },+ {+ id: "America/Swift_Current",+ city: "Swift Current",+ keywords: "swift current america/swift_current cst central standard time",+ },+ {+ id: "Australia/Sydney",+ city: "Sydney",+ keywords:+ "sydney australia/sydney aest aedt eastern australia standard time",+ },+ {+ id: "Antarctica/Syowa",+ city: "Syowa",+ keywords: "syowa antarctica/syowa ast arabian standard time",+ },+ {+ id: "Pacific/Tahiti",+ city: "Tahiti",+ keywords: "tahiti pacific/tahiti taht tahiti standard time",+ },+ {+ id: "Asia/Taipei",+ city: "Taipei",+ keywords: "taipei asia/taipei cst taipei standard time",+ },+ {+ id: "Europe/Tallinn",+ city: "Tallinn",+ keywords: "tallinn europe/tallinn eet eest eastern european standard time",+ },+ {+ id: "Pacific/Tarawa",+ city: "Tarawa",+ keywords: "tarawa pacific/tarawa gilt gilbert islands standard time",+ },+ {+ id: "Asia/Tashkent",+ city: "Tashkent",+ keywords: "tashkent asia/tashkent uzt uzbekistan standard time",+ },+ {+ id: "Asia/Tbilisi",+ city: "Tbilisi",+ keywords: "tbilisi asia/tbilisi get georgia standard time",+ },+ {+ id: "America/Tegucigalpa",+ city: "Tegucigalpa",+ keywords: "tegucigalpa america/tegucigalpa cst central standard time",+ },+ {+ id: "Asia/Tehran",+ city: "Tehran",+ keywords: "tehran asia/tehran irst iran standard time",+ },+ {+ id: "America/Indiana/Tell_City",+ city: "Tell City",+ keywords:+ "tell city america/indiana/tell_city cst cdt central standard time",+ },+ {+ id: "Asia/Thimphu",+ city: "Thimphu",+ keywords: "thimphu asia/thimphu bt bhutan standard time",+ },+ {+ id: "America/Thule",+ city: "Thule",+ keywords: "thule america/thule ast adt atlantic standard time",+ },+ {+ id: "America/Tijuana",+ city: "Tijuana",+ keywords: "tijuana america/tijuana pst pdt pacific standard time",+ },+ {+ id: "Europe/Tirane",+ city: "Tirane",+ keywords: "tirane europe/tirane cet cest central european standard time",+ },+ {+ id: "Asia/Tokyo",+ city: "Tokyo",+ keywords: "tokyo asia/tokyo jst japan standard time",+ },+ {+ id: "Asia/Tomsk",+ city: "Tomsk",+ keywords: "tomsk asia/tomsk omst omsk standard time",+ },+ {+ id: "Pacific/Tongatapu",+ city: "Tongatapu",+ keywords: "tongatapu pacific/tongatapu tot tonga standard time",+ },+ {+ id: "America/Toronto",+ city: "Toronto",+ keywords: "toronto america/toronto est edt eastern standard time",+ },+ {+ id: "America/Tortola",+ city: "Tortola",+ keywords: "tortola america/tortola ast atlantic standard time",+ },+ {+ id: "Africa/Tripoli",+ city: "Tripoli",+ keywords: "tripoli africa/tripoli eet eastern european standard time",+ },+ {+ id: "Antarctica/Troll",+ city: "Troll",+ keywords: "troll antarctica/troll gmt troll standard time",+ },+ {+ id: "Pacific/Truk",+ city: "Truk",+ keywords: "truk pacific/truk chut chuuk standard time",+ },+ {+ id: "America/Argentina/Tucuman",+ city: "Tucuman",+ keywords: "tucuman america/argentina/tucuman art argentina standard time",+ },+ {+ id: "Africa/Tunis",+ city: "Tunis",+ keywords: "tunis africa/tunis cet central european standard time",+ },+ {+ id: "Asia/Ulaanbaatar",+ city: "Ulaanbaatar",+ keywords: "ulaanbaatar asia/ulaanbaatar ulat ulaanbaatar standard time",+ },+ {+ id: "Europe/Ulyanovsk",+ city: "Ulyanovsk",+ keywords: "ulyanovsk europe/ulyanovsk msk moscow standard time",+ },+ {+ id: "Asia/Urumqi",+ city: "Urumqi",+ keywords: "urumqi asia/urumqi cst china standard time",+ },+ {+ id: "America/Argentina/Ushuaia",+ city: "Ushuaia",+ keywords: "ushuaia america/argentina/ushuaia art argentina standard time",+ },+ {+ id: "Asia/Ust-Nera",+ city: "Ust-Nera",+ keywords: "ust-nera asia/ust-nera vlat vladivostok standard time",+ },+ {+ id: "Europe/Vaduz",+ city: "Vaduz",+ keywords: "vaduz europe/vaduz cet cest central european standard time",+ },+ {+ id: "America/Vancouver",+ city: "Vancouver",+ keywords: "vancouver america/vancouver pst pdt pacific standard time",+ },+ {+ id: "Europe/Vatican",+ city: "Vatican",+ keywords: "vatican europe/vatican cet cest central european standard time",+ },+ {+ id: "America/Indiana/Vevay",+ city: "Vevay",+ keywords: "vevay america/indiana/vevay est edt eastern standard time",+ },+ {+ id: "Europe/Vienna",+ city: "Vienna",+ keywords: "vienna europe/vienna cet cest central european standard time",+ },+ {+ id: "Asia/Vientiane",+ city: "Vientiane",+ keywords: "vientiane asia/vientiane ict indochina standard time",+ },+ {+ id: "Europe/Vilnius",+ city: "Vilnius",+ keywords: "vilnius europe/vilnius eet eest eastern european standard time",+ },+ {+ id: "America/Indiana/Vincennes",+ city: "Vincennes",+ keywords:+ "vincennes america/indiana/vincennes est edt eastern standard time",+ },+ {+ id: "Asia/Vladivostok",+ city: "Vladivostok",+ keywords: "vladivostok asia/vladivostok vlat vladivostok standard time",+ },+ {+ id: "Europe/Volgograd",+ city: "Volgograd",+ keywords: "volgograd europe/volgograd msk moscow standard time",+ },+ {+ id: "Antarctica/Vostok",+ city: "Vostok",+ keywords: "vostok antarctica/vostok msk+4 vostok standard time",+ },+ {+ id: "Pacific/Wake",+ city: "Wake",+ keywords: "wake pacific/wake wakt wake island standard time",+ },+ {+ id: "Pacific/Wallis",+ city: "Wallis",+ keywords: "wallis pacific/wallis wft wallis & futuna standard time",+ },+ {+ id: "Europe/Warsaw",+ city: "Warsaw",+ keywords: "warsaw europe/warsaw cet cest central european standard time",+ },+ {+ id: "America/Whitehorse",+ city: "Whitehorse",+ keywords: "whitehorse america/whitehorse mst mountain standard time",+ },+ {+ id: "America/Indiana/Winamac",+ city: "Winamac",+ keywords: "winamac america/indiana/winamac est edt eastern standard time",+ },+ {+ id: "Africa/Windhoek",+ city: "Windhoek",+ keywords: "windhoek africa/windhoek cat central africa standard time",+ },+ {+ id: "America/Winnipeg",+ city: "Winnipeg",+ keywords: "winnipeg america/winnipeg cst cdt central standard time",+ },+ {+ id: "America/Yakutat",+ city: "Yakutat",+ keywords: "yakutat america/yakutat akst akdt alaska standard time",+ },+ {+ id: "Asia/Yakutsk",+ city: "Yakutsk",+ keywords: "yakutsk asia/yakutsk yakt yakutsk standard time",+ },+ {+ id: "Asia/Yekaterinburg",+ city: "Yekaterinburg",+ keywords:+ "yekaterinburg asia/yekaterinburg yekt yekaterinburg standard time",+ },+ {+ id: "Asia/Yerevan",+ city: "Yerevan",+ keywords: "yerevan asia/yerevan amt armenia standard time",+ },+ {+ id: "Europe/Zagreb",+ city: "Zagreb",+ keywords: "zagreb europe/zagreb cet cest central european standard time",+ },+ {+ id: "Europe/Zurich",+ city: "Zurich",+ keywords: "zurich europe/zurich cet cest central european standard time",+ },+];diff --git a/apps/web/src/components/time-zone-picker/timezone-utils.ts b/apps/web/src/components/time-zone-picker/timezone-utils.tsnew file mode 100644index 000000000..0811589f7--- /dev/null+++ b/apps/web/src/components/time-zone-picker/timezone-utils.ts@@ -0,0 +1,40 @@+import type { TimezoneEntry } from "./timezone-data";++export interface TimezoneEntryWithOffset extends TimezoneEntry {+ offsetMinutes: number;+ offsetLabel: string;+}++export function getOffsetMinutes(iana: string): number {+ const now = new Date();+ const parts = new Intl.DateTimeFormat("en-US", {+ timeZone: iana,+ timeZoneName: "shortOffset",+ }).formatToParts(now);++ const tzPart = parts.find((p) => p.type === "timeZoneName")?.value ?? "";++ // tzPart is like "GMT", "GMT+5:30", "GMT-8"+ if (tzPart === "GMT") return 0;++ const match = tzPart.match(/GMT([+-])(\d+)(?::(\d+))?/);+ if (!match) return 0;++ const sign = match[1] === "+" ? 1 : -1;+ const hours = Number.parseInt(match[2], 10);+ const minutes = Number.parseInt(match[3] ?? "0", 10);+ return sign * (hours * 60 + minutes);+}++function formatOffset(offsetMinutes: number): string {+ const sign = offsetMinutes >= 0 ? "+" : "-";+ const abs = Math.abs(offsetMinutes);+ const hours = Math.floor(abs / 60);+ const minutes = abs % 60;+ return `${sign}${String(hours).padStart(2, "0")}:${String(minutes).padStart(2, "0")}`;+}++export function getOffsetLabel(iana: string): string {+ const offsetMinutes = getOffsetMinutes(iana);+ return formatOffset(offsetMinutes);+}diff --git a/apps/web/src/test/setup.ts b/apps/web/src/test/setup.tsindex 2c009f7f1..a634e98ac 100644--- a/apps/web/src/test/setup.ts+++ b/apps/web/src/test/setup.ts@@ -1,4 +1,5 @@import "@testing-library/jest-dom/vitest";+import "@/lib/dayjs";import { vi } from "vitest";// Mock next-themes to avoid SSR issuesdiff --git a/apps/web/src/trpc/routers/user.ts b/apps/web/src/trpc/routers/user.tsindex 47f201fb6..24cf0a43c 100644--- a/apps/web/src/trpc/routers/user.ts+++ b/apps/web/src/trpc/routers/user.ts@@ -14,6 +14,7 @@ import {} from "@/lib/storage/image-upload";import { getEmailClient } from "@/utils/emails";import { createToken } from "@/utils/session";+import { timezoneSchema } from "@/utils/timezone-schema";import {createRateLimitMiddleware,privateProcedure,@@ -52,7 +53,7 @@ export const user = router({.input(z.object({locale: z.string().optional(),- timeZone: z.string().optional(),+ timeZone: timezoneSchema.optional(),weekStart: z.number().min(0).max(6).optional(),timeFormat: z.enum(["hours12", "hours24"]).optional(),}),diff --git a/apps/web/src/utils/date-time-utils.test.ts b/apps/web/src/utils/date-time-utils.test.tsindex 106e0e07b..64c518972 100644--- a/apps/web/src/utils/date-time-utils.test.ts+++ b/apps/web/src/utils/date-time-utils.test.ts@@ -1,38 +1,31 @@-import "@/lib/dayjs";+import { timezoneSchema } from "./timezone-schema";-import { supportedTimeZones } from "@/utils/supported-time-zones";--import { normalizeTimeZone } from "./date-time-utils";--describe("Normalize Time Zone", () => {- it("should return same timezone when given a geographic timezone", () => {- const browserTimeZone = normalizeTimeZone("Europe/London");-- // Assert that the browser time zone is one of the supported time zones- expect(browserTimeZone).toBe("Europe/London");+describe("timezoneSchema", () => {+ it("should accept a geographic timezone", () => {+ expect(timezoneSchema.safeParse("Europe/London").success).toBe(true);});- it("should return a supported timezone when given a fixed offset timezone", () => {- const browserTimeZone = normalizeTimeZone("Etc/GMT-1");- // Assert that the browser time zone is one of the supported time zones- expect(supportedTimeZones.includes(browserTimeZone)).toBe(true);+ it("should canonicalize a legacy alias", () => {+ const result = timezoneSchema.safeParse("America/Montreal");+ expect(result.success).toBe(true);+ if (result.success) {+ expect(result.data).toBe("America/Toronto");+ }});- it("should return a supported timezone when given GMT", () => {- const browserTimeZone = normalizeTimeZone("GMT");- // Assert that the browser time zone is one of the supported time zones- expect(supportedTimeZones.includes(browserTimeZone)).toBe(true);+ it("should reject Etc/ timezones", () => {+ expect(timezoneSchema.safeParse("Etc/GMT-1").success).toBe(false);});- it("should return a supported timezone when given UTC", () => {- const browserTimeZone = normalizeTimeZone("UTC");- // Assert that the browser time zone is one of the supported time zones- expect(supportedTimeZones.includes(browserTimeZone)).toBe(true);+ it("should reject GMT", () => {+ expect(timezoneSchema.safeParse("GMT").success).toBe(false);});- it("should return a valid timezone in the same continent when not recognized", () => {- const browserTimeZone = normalizeTimeZone("Asia/Kolkata");+ it("should reject UTC", () => {+ expect(timezoneSchema.safeParse("UTC").success).toBe(false);+ });- expect(browserTimeZone).toBe("Asia/Calcutta");+ it("should reject an invalid timezone", () => {+ expect(timezoneSchema.safeParse("Not/A_Timezone").success).toBe(false);});});diff --git a/apps/web/src/utils/date-time-utils.ts b/apps/web/src/utils/date-time-utils.tsindex 1b48600d9..58700ef4e 100644--- a/apps/web/src/utils/date-time-utils.ts+++ b/apps/web/src/utils/date-time-utils.ts@@ -1,85 +1,12 @@import { dayjs } from "@/lib/dayjs";-import { supportedTimeZones } from "@/utils/supported-time-zones";import type {DateTimeOption,TimeOption,} from "../components/forms/poll-options-form";-export function parseIanaTimezone(timezone: string): {- region: string;- city: string;-} {- const firstSlash = timezone.indexOf("/");- const region = timezone.substring(0, firstSlash);- const city = timezone.substring(firstSlash + 1).replaceAll("_", " ");-- return { region, city };-}-export function getBrowserTimeZone() {- const timeZone = dayjs.tz.guess();- return normalizeTimeZone(timeZone);-}--function getTimeZoneOffset(timeZone: string) {- try {- return dayjs().tz(timeZone).utcOffset();- } catch {- console.error({ timeZone }, "Failed to resolve timezone");- return 0;- }-}--function isFixedOffsetTimeZone(timeZone: string) {- return (- timeZone.toLowerCase().startsWith("etc") ||- timeZone.toLowerCase().startsWith("gmt") ||- timeZone.toLowerCase().startsWith("utc")- );-}--/**- * Given a timezone, this function returns a normalized timezone- * that is supported by the application. If the timezone is not- * recognized, it will return a timezone in the same continent- * with the same offset.- * @param timeZone- * @returns- */-export function normalizeTimeZone(timeZone: string) {- let tz = supportedTimeZones.find((tz) => tz === timeZone);-- if (tz) {- return tz;- }-- const timeZoneOffset = getTimeZoneOffset(timeZone);-- if (!isFixedOffsetTimeZone(timeZone)) {- // Find a timezone in the same continent with the same offset- const [continent] = timeZone.split("/");- const sameContinentTimeZones = supportedTimeZones.filter((tz) =>- tz.startsWith(continent),- );- tz = sameContinentTimeZones.find((tz) => {- return dayjs().tz(tz, true).utcOffset() === timeZoneOffset;- });- }-- if (!tz) {- tz = supportedTimeZones.find((tz) => {- return getTimeZoneOffset(tz) === timeZoneOffset;- });- }-- if (!tz) {- // In theory this shouldn't happen- tz = "America/New_York";- console.error({ timeZone }, "Unable to resolve timezone");- }-- return tz;+ return dayjs.tz.guess();}export const encodeDateOption = (option: DateTimeOption) => {diff --git a/apps/web/src/utils/dayjs.tsx b/apps/web/src/utils/dayjs.tsxindex a586407bd..06961d819 100644--- a/apps/web/src/utils/dayjs.tsx+++ b/apps/web/src/utils/dayjs.tsx@@ -24,7 +24,7 @@ import * as React from "react";import { usePreferences } from "@/contexts/preferences";import { dayjs } from "@/lib/dayjs";import { useLocale } from "@/lib/locale/client";-import { getBrowserTimeZone, normalizeTimeZone } from "@/utils/date-time-utils";+import { getBrowserTimeZone } from "@/utils/date-time-utils";import { useRequiredContext } from "../components/use-required-context";const dayjsLocales: Record<@@ -163,10 +163,7 @@ export const DayjsProvider: React.FunctionComponent<{const dayjsLocale = localeConfig.locale;const preferredTimeZone = React.useMemo(- () =>- config?.timeZone- ? normalizeTimeZone(config?.timeZone)- : getBrowserTimeZone(),+ () => config?.timeZone ?? getBrowserTimeZone(),[config?.timeZone],);diff --git a/apps/web/src/utils/grouped-time-zone.ts b/apps/web/src/utils/grouped-time-zone.tsdeleted file mode 100644index ec788a7ca..000000000--- a/apps/web/src/utils/grouped-time-zone.ts+++ /dev/null@@ -1,14 +0,0 @@-import { parseIanaTimezone } from "@/utils/date-time-utils";-import { supportedTimeZones } from "@/utils/supported-time-zones";--export const groupedTimeZones = supportedTimeZones.reduce(- (acc, tz) => {- const { region, city } = parseIanaTimezone(tz);- if (!acc[region]) {- acc[region] = [];- }- acc[region].push({ timezone: tz, city });- return acc;- },- {} as Record<string, { timezone: string; city: string }[]>,-);diff --git a/apps/web/src/utils/supported-time-zones.ts b/apps/web/src/utils/supported-time-zones.tsdeleted file mode 100644index 842b7c5c9..000000000--- a/apps/web/src/utils/supported-time-zones.ts+++ /dev/null@@ -1,436 +0,0 @@-export const supportedTimeZones = [- "Africa/Abidjan",- "Africa/Accra",- "Africa/Addis_Ababa",- "Africa/Algiers",- "Africa/Asmera",- "Africa/Bamako",- "Africa/Bangui",- "Africa/Banjul",- "Africa/Bissau",- "Africa/Blantyre",- "Africa/Brazzaville",- "Africa/Bujumbura",- "Africa/Cairo",- "Africa/Casablanca",- "Africa/Ceuta",- "Africa/Conakry",- "Africa/Dakar",- "Africa/Dar_es_Salaam",- "Africa/Djibouti",- "Africa/Douala",- "Africa/El_Aaiun",- "Africa/Freetown",- "Africa/Gaborone",- "Africa/Harare",- "Africa/Johannesburg",- "Africa/Juba",- "Africa/Kampala",- "Africa/Khartoum",- "Africa/Kigali",- "Africa/Kinshasa",- "Africa/Lagos",- "Africa/Libreville",- "Africa/Lome",- "Africa/Luanda",- "Africa/Lubumbashi",- "Africa/Lusaka",- "Africa/Malabo",- "Africa/Maputo",- "Africa/Maseru",- "Africa/Mbabane",- "Africa/Mogadishu",- "Africa/Monrovia",- "Africa/Nairobi",- "Africa/Ndjamena",- "Africa/Niamey",- "Africa/Nouakchott",- "Africa/Ouagadougou",- "Africa/Porto-Novo",- "Africa/Sao_Tome",- "Africa/Tripoli",- "Africa/Tunis",- "Africa/Windhoek",- "America/Adak",- "America/Anchorage",- "America/Anguilla",- "America/Antigua",- "America/Araguaina",- "America/Argentina/La_Rioja",- "America/Argentina/Rio_Gallegos",- "America/Argentina/Salta",- "America/Argentina/San_Juan",- "America/Argentina/San_Luis",- "America/Argentina/Tucuman",- "America/Argentina/Ushuaia",- "America/Aruba",- "America/Asuncion",- "America/Bahia",- "America/Bahia_Banderas",- "America/Barbados",- "America/Belem",- "America/Belize",- "America/Blanc-Sablon",- "America/Boa_Vista",- "America/Bogota",- "America/Boise",- "America/Buenos_Aires",- "America/Cambridge_Bay",- "America/Campo_Grande",- "America/Cancun",- "America/Caracas",- "America/Catamarca",- "America/Cayenne",- "America/Cayman",- "America/Chicago",- "America/Chihuahua",- "America/Ciudad_Juarez",- "America/Coral_Harbour",- "America/Cordoba",- "America/Costa_Rica",- "America/Creston",- "America/Cuiaba",- "America/Curacao",- "America/Danmarkshavn",- "America/Dawson",- "America/Dawson_Creek",- "America/Denver",- "America/Detroit",- "America/Dominica",- "America/Edmonton",- "America/Eirunepe",- "America/El_Salvador",- "America/Fort_Nelson",- "America/Fortaleza",- "America/Glace_Bay",- "America/Godthab",- "America/Goose_Bay",- "America/Grand_Turk",- "America/Grenada",- "America/Guadeloupe",- "America/Guatemala",- "America/Guayaquil",- "America/Guyana",- "America/Halifax",- "America/Havana",- "America/Hermosillo",- "America/Indiana/Knox",- "America/Indiana/Marengo",- "America/Indiana/Petersburg",- "America/Indiana/Tell_City",- "America/Indiana/Vevay",- "America/Indiana/Vincennes",- "America/Indiana/Winamac",- "America/Indianapolis",- "America/Inuvik",- "America/Iqaluit",- "America/Jamaica",- "America/Jujuy",- "America/Juneau",- "America/Kentucky/Monticello",- "America/Kralendijk",- "America/La_Paz",- "America/Lima",- "America/Los_Angeles",- "America/Louisville",- "America/Lower_Princes",- "America/Maceio",- "America/Managua",- "America/Manaus",- "America/Marigot",- "America/Martinique",- "America/Matamoros",- "America/Mazatlan",- "America/Mendoza",- "America/Menominee",- "America/Merida",- "America/Metlakatla",- "America/Mexico_City",- "America/Miquelon",- "America/Moncton",- "America/Monterrey",- "America/Montevideo",- "America/Montserrat",- "America/Nassau",- "America/New_York",- "America/Nipigon",- "America/Nome",- "America/Noronha",- "America/North_Dakota/Beulah",- "America/North_Dakota/Center",- "America/North_Dakota/New_Salem",- "America/Ojinaga",- "America/Panama",- "America/Pangnirtung",- "America/Paramaribo",- "America/Phoenix",- "America/Port-au-Prince",- "America/Port_of_Spain",- "America/Porto_Velho",- "America/Puerto_Rico",- "America/Punta_Arenas",- "America/Rainy_River",- "America/Rankin_Inlet",- "America/Recife",- "America/Regina",- "America/Resolute",- "America/Rio_Branco",- "America/Santa_Isabel",- "America/Santarem",- "America/Santiago",- "America/Santo_Domingo",- "America/Sao_Paulo",- "America/Scoresbysund",- "America/Sitka",- "America/St_Barthelemy",- "America/St_Johns",- "America/St_Kitts",- "America/St_Lucia",- "America/St_Thomas",- "America/St_Vincent",- "America/Swift_Current",- "America/Tegucigalpa",- "America/Thule",- "America/Thunder_Bay",- "America/Tijuana",- "America/Toronto",- "America/Tortola",- "America/Vancouver",- "America/Whitehorse",- "America/Winnipeg",- "America/Yakutat",- "America/Yellowknife",- "Antarctica/Casey",- "Antarctica/Davis",- "Antarctica/DumontDUrville",- "Antarctica/Macquarie",- "Antarctica/Mawson",- "Antarctica/McMurdo",- "Antarctica/Palmer",- "Antarctica/Rothera",- "Antarctica/Syowa",- "Antarctica/Troll",- "Antarctica/Vostok",- "Arctic/Longyearbyen",- "Asia/Aden",- "Asia/Almaty",- "Asia/Amman",- "Asia/Anadyr",- "Asia/Aqtau",- "Asia/Aqtobe",- "Asia/Ashgabat",- "Asia/Atyrau",- "Asia/Baghdad",- "Asia/Bahrain",- "Asia/Baku",- "Asia/Bangkok",- "Asia/Barnaul",- "Asia/Beirut",- "Asia/Bishkek",- "Asia/Brunei",- "Asia/Calcutta",- "Asia/Chita",- "Asia/Choibalsan",- "Asia/Colombo",- "Asia/Damascus",- "Asia/Dhaka",- "Asia/Dili",- "Asia/Dubai",- "Asia/Dushanbe",- "Asia/Famagusta",- "Asia/Gaza",- "Asia/Hebron",- "Asia/Hong_Kong",- "Asia/Hovd",- "Asia/Irkutsk",- "Asia/Jakarta",- "Asia/Jayapura",- "Asia/Jerusalem",- "Asia/Kabul",- "Asia/Kamchatka",- "Asia/Karachi",- "Asia/Katmandu",- "Asia/Khandyga",- "Asia/Krasnoyarsk",- "Asia/Kuala_Lumpur",- "Asia/Kuching",- "Asia/Kuwait",- "Asia/Macau",- "Asia/Magadan",- "Asia/Makassar",- "Asia/Manila",- "Asia/Muscat",- "Asia/Nicosia",- "Asia/Novokuznetsk",- "Asia/Novosibirsk",- "Asia/Omsk",- "Asia/Oral",- "Asia/Phnom_Penh",- "Asia/Pontianak",- "Asia/Pyongyang",- "Asia/Qatar",- "Asia/Qostanay",- "Asia/Qyzylorda",- "Asia/Rangoon",- "Asia/Riyadh",- "Asia/Saigon",- "Asia/Sakhalin",- "Asia/Samarkand",- "Asia/Seoul",- "Asia/Shanghai",- "Asia/Singapore",- "Asia/Srednekolymsk",- "Asia/Taipei",- "Asia/Tashkent",- "Asia/Tbilisi",- "Asia/Tehran",- "Asia/Thimphu",- "Asia/Tokyo",- "Asia/Tomsk",- "Asia/Ulaanbaatar",- "Asia/Urumqi",- "Asia/Ust-Nera",- "Asia/Vientiane",- "Asia/Vladivostok",- "Asia/Yakutsk",- "Asia/Yekaterinburg",- "Asia/Yerevan",- "Atlantic/Azores",- "Atlantic/Bermuda",- "Atlantic/Canary",- "Atlantic/Cape_Verde",- "Atlantic/Faeroe",- "Atlantic/Madeira",- "Atlantic/Reykjavik",- "Atlantic/South_Georgia",- "Atlantic/St_Helena",- "Atlantic/Stanley",- "Australia/Adelaide",- "Australia/Brisbane",- "Australia/Broken_Hill",- "Australia/Currie",- "Australia/Darwin",- "Australia/Eucla",- "Australia/Hobart",- "Australia/Lindeman",- "Australia/Lord_Howe",- "Australia/Melbourne",- "Australia/Perth",- "Australia/Sydney",- "Europe/Amsterdam",- "Europe/Andorra",- "Europe/Astrakhan",- "Europe/Athens",- "Europe/Belgrade",- "Europe/Berlin",- "Europe/Bratislava",- "Europe/Brussels",- "Europe/Bucharest",- "Europe/Budapest",- "Europe/Busingen",- "Europe/Chisinau",- "Europe/Copenhagen",- "Europe/Dublin",- "Europe/Gibraltar",- "Europe/Guernsey",- "Europe/Helsinki",- "Europe/Isle_of_Man",- "Europe/Istanbul",- "Europe/Jersey",- "Europe/Kaliningrad",- "Europe/Kyiv",- "Europe/Kirov",- "Europe/Lisbon",- "Europe/Ljubljana",- "Europe/London",- "Europe/Luxembourg",- "Europe/Madrid",- "Europe/Malta",- "Europe/Mariehamn",- "Europe/Minsk",- "Europe/Monaco",- "Europe/Moscow",- "Europe/Oslo",- "Europe/Paris",- "Europe/Podgorica",- "Europe/Prague",- "Europe/Riga",- "Europe/Rome",- "Europe/Samara",- "Europe/San_Marino",- "Europe/Sarajevo",- "Europe/Saratov",- "Europe/Simferopol",- "Europe/Skopje",- "Europe/Sofia",- "Europe/Stockholm",- "Europe/Tallinn",- "Europe/Tirane",- "Europe/Ulyanovsk",- "Europe/Uzhgorod",- "Europe/Vaduz",- "Europe/Vatican",- "Europe/Vienna",- "Europe/Vilnius",- "Europe/Volgograd",- "Europe/Warsaw",- "Europe/Zagreb",- "Europe/Zaporozhye",- "Europe/Zurich",- "Indian/Antananarivo",- "Indian/Chagos",- "Indian/Christmas",- "Indian/Cocos",- "Indian/Comoro",- "Indian/Kerguelen",- "Indian/Mahe",- "Indian/Maldives",- "Indian/Mauritius",- "Indian/Mayotte",- "Indian/Reunion",- "Pacific/Apia",- "Pacific/Auckland",- "Pacific/Bougainville",- "Pacific/Chatham",- "Pacific/Easter",- "Pacific/Efate",- "Pacific/Enderbury",- "Pacific/Fakaofo",- "Pacific/Fiji",- "Pacific/Funafuti",- "Pacific/Galapagos",- "Pacific/Gambier",- "Pacific/Guadalcanal",- "Pacific/Guam",- "Pacific/Honolulu",- "Pacific/Johnston",- "Pacific/Kiritimati",- "Pacific/Kosrae",- "Pacific/Kwajalein",- "Pacific/Majuro",- "Pacific/Marquesas",- "Pacific/Midway",- "Pacific/Nauru",- "Pacific/Niue",- "Pacific/Norfolk",- "Pacific/Noumea",- "Pacific/Pago_Pago",- "Pacific/Palau",- "Pacific/Pitcairn",- "Pacific/Ponape",- "Pacific/Port_Moresby",- "Pacific/Rarotonga",- "Pacific/Saipan",- "Pacific/Tahiti",- "Pacific/Tarawa",- "Pacific/Tongatapu",- "Pacific/Truk",- "Pacific/Wake",- "Pacific/Wallis",-] as const;--export function isSupportedTimeZone(timeZone: string) {- return supportedTimeZones.includes(- timeZone as (typeof supportedTimeZones)[number],- );-}diff --git a/apps/web/src/utils/timezone-schema.ts b/apps/web/src/utils/timezone-schema.tsnew file mode 100644index 000000000..53f371adf--- /dev/null+++ b/apps/web/src/utils/timezone-schema.ts@@ -0,0 +1,27 @@+import { z } from "zod";++const fixedOffsetPrefixes = ["etc/", "gmt", "utc"];++function isGeographic(timeZone: string) {+ const lower = timeZone.toLowerCase();+ return !fixedOffsetPrefixes.some((prefix) => lower.startsWith(prefix));+}++function canonicalize(timeZone: string) {+ return Intl.DateTimeFormat(undefined, { timeZone }).resolvedOptions()+ .timeZone;+}++export const timezoneSchema = z+ .string()+ .refine(+ (tz) => {+ try {+ return isGeographic(canonicalize(tz));+ } catch {+ return false;+ }+ },+ { message: "Must be a valid IANA geographic timezone" },+ )+ .transform((tz) => canonicalize(tz));diff --git a/packages/tailwind-config/shared-styles.css b/packages/tailwind-config/shared-styles.cssindex 2d083aba4..275a805f3 100644--- a/packages/tailwind-config/shared-styles.css+++ b/packages/tailwind-config/shared-styles.css@@ -9,6 +9,7 @@@source "../../packages/ui/src/**/*.{ts,tsx}";:root {+ --radius: 0.625rem;--primary: var(--primary-light, var(--color-indigo-600));--primary-foreground: var(--primary-light-foreground, var(--color-white));diff --git a/packages/ui/src/combobox.tsx b/packages/ui/src/combobox.tsxnew file mode 100644index 000000000..a247dccdd--- /dev/null+++ b/packages/ui/src/combobox.tsx@@ -0,0 +1,303 @@+"use client";++import { Combobox as ComboboxPrimitive } from "@base-ui/react";+import { CheckIcon, ChevronDownIcon, XIcon } from "lucide-react";+import * as React from "react";+import { Button } from "./button";+import {+ InputGroup,+ InputGroupAddon,+ InputGroupButton,+ InputGroupInput,+} from "./input-group";+import { cn } from "./lib/utils";++const Combobox = ComboboxPrimitive.Root;++function ComboboxValue({ ...props }: ComboboxPrimitive.Value.Props) {+ return <ComboboxPrimitive.Value data-slot="combobox-value" {...props} />;+}++function ComboboxTrigger({+ className,+ children,+ ...props+}: ComboboxPrimitive.Trigger.Props) {+ return (+ <ComboboxPrimitive.Trigger+ data-slot="combobox-trigger"+ className={cn("[&_svg:not([class*='size-'])]:size-4", className)}+ {...props}+ >+ {children}+ <ChevronDownIcon className="pointer-events-none size-4 text-muted-foreground" />+ </ComboboxPrimitive.Trigger>+ );+}++function ComboboxClear({ className, ...props }: ComboboxPrimitive.Clear.Props) {+ return (+ <ComboboxPrimitive.Clear+ data-slot="combobox-clear"+ className={cn(className)}+ {...props}+ render={+ <InputGroupButton variant="ghost" size="icon-xs">+ <XIcon className="pointer-events-none" />+ </InputGroupButton>+ }+ />+ );+}++function ComboboxInput({+ className,+ children,+ disabled = false,+ showTrigger = true,+ showClear = false,+ ...props+}: ComboboxPrimitive.Input.Props & {+ showTrigger?: boolean;+ showClear?: boolean;+}) {+ return (+ <InputGroup className={cn("w-auto", className)}>+ <ComboboxPrimitive.Input+ render={<InputGroupInput disabled={disabled} />}+ {...props}+ />+ <InputGroupAddon align="inline-end">+ {showTrigger && (+ <InputGroupButton+ size="icon-xs"+ variant="ghost"+ render={<ComboboxTrigger />}+ data-slot="input-group-button"+ className="group-has-data-[slot=combobox-clear]/input-group:hidden data-pressed:bg-transparent"+ disabled={disabled}+ />+ )}+ {showClear && <ComboboxClear disabled={disabled} />}+ </InputGroupAddon>+ {children}+ </InputGroup>+ );+}++function ComboboxContent({+ className,+ side = "bottom",+ sideOffset = 6,+ align = "start",+ alignOffset = 0,+ anchor,+ ...props+}: ComboboxPrimitive.Popup.Props &+ Pick<+ ComboboxPrimitive.Positioner.Props,+ "side" | "align" | "sideOffset" | "alignOffset" | "anchor"+ >) {+ return (+ <ComboboxPrimitive.Portal>+ <ComboboxPrimitive.Positioner+ side={side}+ sideOffset={sideOffset}+ align={align}+ alignOffset={alignOffset}+ anchor={anchor}+ className="isolate z-50"+ >+ <ComboboxPrimitive.Popup+ data-slot="combobox-content"+ data-chips={!!anchor}+ className={cn(+ "data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=inline-end]:slide-in-from-left-2 group/combobox-content relative max-h-(--available-height) w-(--anchor-width) min-w-[calc(var(--anchor-width)+--spacing(7))] max-w-(--available-width) origin-(--transform-origin) overflow-hidden rounded-lg bg-popover text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[chips=true]:min-w-(--anchor-width) data-closed:animate-out data-open:animate-in *:data-[slot=input-group]:m-1 *:data-[slot=input-group]:mb-0 *:data-[slot=input-group]:h-8 *:data-[slot=input-group]:border-input/30 *:data-[slot=input-group]:bg-input/30 *:data-[slot=input-group]:shadow-none",+ className,+ )}+ {...props}+ />+ </ComboboxPrimitive.Positioner>+ </ComboboxPrimitive.Portal>+ );+}++function ComboboxList({ className, ...props }: ComboboxPrimitive.List.Props) {+ return (+ <ComboboxPrimitive.List+ data-slot="combobox-list"+ className={cn(+ "no-scrollbar max-h-[min(calc(--spacing(72)---spacing(9)),calc(var(--available-height)---spacing(9)))] scroll-py-1 overflow-y-auto overscroll-contain p-1 data-empty:p-0",+ className,+ )}+ {...props}+ />+ );+}++function ComboboxItem({+ className,+ children,+ ...props+}: ComboboxPrimitive.Item.Props) {+ return (+ <ComboboxPrimitive.Item+ data-slot="combobox-item"+ className={cn(+ "relative flex w-full cursor-default select-none items-center gap-2 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden data-disabled:pointer-events-none data-highlighted:bg-accent data-highlighted:text-accent-foreground data-disabled:opacity-50 not-data-[variant=destructive]:data-highlighted:**:text-accent-foreground [&_svg:not([class*='size-'])]:size-4 [&_svg]:pointer-events-none [&_svg]:shrink-0",+ className,+ )}+ {...props}+ >+ {children}+ <ComboboxPrimitive.ItemIndicator+ render={+ <span className="pointer-events-none absolute right-2 flex size-4 items-center justify-center">+ <CheckIcon className="pointer-events-none" />+ </span>+ }+ />+ </ComboboxPrimitive.Item>+ );+}++function ComboboxGroup({ className, ...props }: ComboboxPrimitive.Group.Props) {+ return (+ <ComboboxPrimitive.Group+ data-slot="combobox-group"+ className={cn(className)}+ {...props}+ />+ );+}++function ComboboxLabel({+ className,+ ...props+}: ComboboxPrimitive.GroupLabel.Props) {+ return (+ <ComboboxPrimitive.GroupLabel+ data-slot="combobox-label"+ className={cn("px-2 py-1.5 text-muted-foreground text-xs", className)}+ {...props}+ />+ );+}++function ComboboxCollection({ ...props }: ComboboxPrimitive.Collection.Props) {+ return (+ <ComboboxPrimitive.Collection data-slot="combobox-collection" {...props} />+ );+}++function ComboboxEmpty({ className, ...props }: ComboboxPrimitive.Empty.Props) {+ return (+ <ComboboxPrimitive.Empty+ data-slot="combobox-empty"+ className={cn(+ "hidden w-full justify-center py-2 text-center text-muted-foreground text-sm group-data-empty/combobox-content:flex",+ className,+ )}+ {...props}+ />+ );+}++function ComboboxSeparator({+ className,+ ...props+}: ComboboxPrimitive.Separator.Props) {+ return (+ <ComboboxPrimitive.Separator+ data-slot="combobox-separator"+ className={cn("-mx-1 my-1 h-px bg-border", className)}+ {...props}+ />+ );+}++function ComboboxChips({+ className,+ ...props+}: React.ComponentPropsWithRef<typeof ComboboxPrimitive.Chips> &+ ComboboxPrimitive.Chips.Props) {+ return (+ <ComboboxPrimitive.Chips+ data-slot="combobox-chips"+ className={cn(+ "flex min-h-8 flex-wrap items-center gap-1 rounded-lg border border-input bg-transparent bg-clip-padding px-2.5 py-1 text-sm transition-colors focus-within:border-ring focus-within:ring-3 focus-within:ring-ring/50 has-aria-invalid:border-destructive has-data-[slot=combobox-chip]:px-1 has-aria-invalid:ring-3 has-aria-invalid:ring-destructive/20 dark:bg-input/30 dark:has-aria-invalid:border-destructive/50 dark:has-aria-invalid:ring-destructive/40",+ className,+ )}+ {...props}+ />+ );+}++function ComboboxChip({+ className,+ children,+ showRemove = true,+ ...props+}: ComboboxPrimitive.Chip.Props & {+ showRemove?: boolean;+}) {+ return (+ <ComboboxPrimitive.Chip+ data-slot="combobox-chip"+ className={cn(+ "flex h-[calc(--spacing(5.25))] w-fit items-center justify-center gap-1 whitespace-nowrap rounded-sm bg-muted px-1.5 font-medium text-foreground text-xs has-disabled:pointer-events-none has-disabled:cursor-not-allowed has-data-[slot=combobox-chip-remove]:pr-0 has-disabled:opacity-50",+ className,+ )}+ {...props}+ >+ {children}+ {showRemove && (+ <ComboboxPrimitive.ChipRemove+ className="-ml-1 opacity-50 hover:opacity-100"+ data-slot="combobox-chip-remove"+ render={+ <Button variant="ghost" size="icon-xs">+ <XIcon className="pointer-events-none" />+ </Button>+ }+ />+ )}+ </ComboboxPrimitive.Chip>+ );+}++function ComboboxChipsInput({+ className,+ ...props+}: ComboboxPrimitive.Input.Props) {+ return (+ <ComboboxPrimitive.Input+ data-slot="combobox-chip-input"+ className={cn("min-w-16 flex-1 outline-none", className)}+ {...props}+ />+ );+}++function useComboboxAnchor() {+ return React.useRef<HTMLDivElement | null>(null);+}++export {+ Combobox,+ ComboboxInput,+ ComboboxContent,+ ComboboxList,+ ComboboxItem,+ ComboboxGroup,+ ComboboxLabel,+ ComboboxCollection,+ ComboboxEmpty,+ ComboboxSeparator,+ ComboboxChips,+ ComboboxChip,+ ComboboxChipsInput,+ ComboboxTrigger,+ ComboboxValue,+ useComboboxAnchor,+};diff --git a/packages/ui/src/input-group.tsx b/packages/ui/src/input-group.tsxnew file mode 100644index 000000000..b6442ac7b--- /dev/null+++ b/packages/ui/src/input-group.tsx@@ -0,0 +1,161 @@+/** biome-ignore-all lint/a11y/useSemanticElements: avoid messing with shadcn defualt implementation */+/** biome-ignore-all lint/a11y/useKeyWithClickEvents: avoid messing with shadcn defualt implementation */+"use client";++import type { VariantProps } from "class-variance-authority";+import { cva } from "class-variance-authority";+import type * as React from "react";+import { Button } from "./button";+import { Input } from "./input";+import { cn } from "./lib/utils";+import { Textarea } from "./textarea";++function InputGroup({ className, ...props }: React.ComponentProps<"div">) {+ return (+ <div+ data-slot="input-group"+ role="group"+ className={cn(+ "group/input-group relative flex h-8 w-full min-w-0 items-center rounded-lg border border-input outline-none transition-colors in-data-[slot=combobox-content]:focus-within:border-inherit in-data-[slot=combobox-content]:focus-within:ring-0 has-[>[data-align=block-end]]:h-auto has-[>[data-align=block-start]]:h-auto has-[>textarea]:h-auto has-[>[data-align=block-end]]:flex-col has-[>[data-align=block-start]]:flex-col has-[[data-slot=input-group-control]:focus-visible]:border-ring has-[[data-slot][aria-invalid=true]]:border-destructive has-disabled:bg-input/50 has-disabled:opacity-50 has-[[data-slot=input-group-control]:focus-visible]:ring-3 has-[[data-slot=input-group-control]:focus-visible]:ring-ring/50 has-[[data-slot][aria-invalid=true]]:ring-3 has-[[data-slot][aria-invalid=true]]:ring-destructive/20 dark:bg-input/30 dark:has-disabled:bg-input/80 dark:has-[[data-slot][aria-invalid=true]]:ring-destructive/40 has-[>[data-align=block-end]]:[&>input]:pt-3 has-[>[data-align=inline-end]]:[&>input]:pr-1.5 has-[>[data-align=block-start]]:[&>input]:pb-3 has-[>[data-align=inline-start]]:[&>input]:pl-1.5",+ className,+ )}+ {...props}+ />+ );+}++const inputGroupAddonVariants = cva(+ "flex h-auto cursor-text select-none items-center justify-center gap-2 py-1.5 font-medium text-muted-foreground text-sm group-data-[disabled=true]/input-group:opacity-50 [&>kbd]:rounded-[calc(var(--radius)-5px)] [&>svg:not([class*='size-'])]:size-4",+ {+ variants: {+ align: {+ "inline-start":+ "order-first pl-2 has-[>button]:ml-[-0.3rem] has-[>kbd]:ml-[-0.15rem]",+ "inline-end":+ "order-last pr-2 has-[>button]:mr-[-0.3rem] has-[>kbd]:mr-[-0.15rem]",+ "block-start":+ "order-first w-full justify-start px-2.5 pt-2 group-has-[>input]/input-group:pt-2 [.border-b]:pb-2",+ "block-end":+ "order-last w-full justify-start px-2.5 pb-2 group-has-[>input]/input-group:pb-2 [.border-t]:pt-2",+ },+ },+ defaultVariants: {+ align: "inline-start",+ },+ },+);++function InputGroupAddon({+ className,+ align = "inline-start",+ ...props+}: React.ComponentProps<"div"> & VariantProps<typeof inputGroupAddonVariants>) {+ return (+ <div+ role="group"+ data-slot="input-group-addon"+ data-align={align}+ className={cn(inputGroupAddonVariants({ align }), className)}+ onClick={(e) => {+ if ((e.target as HTMLElement).closest("button")) {+ return;+ }+ e.currentTarget.parentElement?.querySelector("input")?.focus();+ }}+ {...props}+ />+ );+}++const inputGroupButtonVariants = cva(+ "flex items-center gap-2 text-sm shadow-none",+ {+ variants: {+ size: {+ xs: "h-6 gap-1 rounded-[calc(var(--radius)-3px)] px-1.5 [&>svg:not([class*='size-'])]:size-3.5",+ sm: "",+ "icon-xs":+ "size-6 rounded-[calc(var(--radius)-3px)] p-0 has-[>svg]:p-0",+ "icon-sm": "size-8 p-0 has-[>svg]:p-0",+ },+ },+ defaultVariants: {+ size: "xs",+ },+ },+);++function InputGroupButton({+ className,+ type = "button",+ variant = "ghost",+ size = "xs",+ ...props+}: Omit<React.ComponentProps<typeof Button>, "size" | "type"> &+ VariantProps<typeof inputGroupButtonVariants> & {+ type?: "button" | "submit" | "reset";+ }) {+ return (+ <Button+ type={type}+ data-size={size}+ variant={variant}+ size={size}+ className={cn(inputGroupButtonVariants({ size }), className)}+ {...props}+ />+ );+}++function InputGroupText({ className, ...props }: React.ComponentProps<"span">) {+ return (+ <span+ className={cn(+ "flex items-center gap-2 text-muted-foreground text-sm [&_svg:not([class*='size-'])]:size-4 [&_svg]:pointer-events-none",+ className,+ )}+ {...props}+ />+ );+}++function InputGroupInput({+ className,+ ...props+}: React.ComponentProps<"input">) {+ return (+ <Input+ data-slot="input-group-control"+ className={cn(+ "flex-1 rounded-none border-0 bg-transparent shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent",+ className,+ )}+ {...props}+ />+ );+}++function InputGroupTextarea({+ className,+ ...props+}: React.ComponentProps<"textarea">) {+ return (+ <Textarea+ data-slot="input-group-control"+ className={cn(+ "flex-1 resize-none rounded-none border-0 bg-transparent py-2 shadow-none ring-0 focus-visible:ring-0 disabled:bg-transparent aria-invalid:ring-0 dark:bg-transparent dark:disabled:bg-transparent",+ className,+ )}+ {...props}+ />+ );+}++export {+ InputGroup,+ InputGroupAddon,+ InputGroupButton,+ InputGroupText,+ InputGroupInput,+ InputGroupTextarea,+};