diff --git a/admin-spa/src/components/ui/dialog.tsx b/admin-spa/src/components/ui/dialog.tsx index 7d47744..3e3dc51 100644 --- a/admin-spa/src/components/ui/dialog.tsx +++ b/admin-spa/src/components/ui/dialog.tsx @@ -19,7 +19,7 @@ const DialogOverlay = React.forwardRef< - + updateSetting('country', v)} + options={countries.map((country: { code: string; name: string }) => ({ + value: country.code, + label: country.name, + searchText: country.name, + }))} + placeholder="Select country..." + /> @@ -293,18 +292,16 @@ export default function StoreDetailsPage() { description="How prices are displayed in your store" > - + updateSetting('currency', v)} + options={currencies.map((currency: { code: string; name: string; symbol: string }) => ({ + value: currency.code, + label: `${currency.name} (${currency.symbol})`, + searchText: `${currency.code} ${currency.name} ${currency.symbol}`, + }))} + placeholder="Select currency..." + /> @@ -377,22 +374,18 @@ export default function StoreDetailsPage() { description="Timezone and measurement units" > - + updateSetting('timezone', v)} + options={Object.entries(timezones).flatMap(([continent, tzList]: [string, any]) => + tzList.map((tz: { value: string; label: string; offset: string }) => ({ + value: tz.value, + label: `${tz.label} (${tz.offset})`, + searchText: `${continent} ${tz.label} ${tz.offset}`, + })) + )} + placeholder="Select timezone..." + />