Founding price: $35, then $99 after 23:59 UTC on 4 November, then $99
Get ProTwo linked selects: choosing a country loads its regions and resets the region, a missing region list turns the field into free text, and a late response for a previous country is ignored. Use this when one choice decides the options of the next.
This item has no props to tune. Use the lens above to change theme, density, direction and more.
One field's options depend on another's value (country and state, brand and model, category and subcategory), possibly loaded from a server.
Do not use it when: When the full tree is small and static, use a single grouped select, or a cascader if the user needs to see it as one path.
This item is part of tealmac UI Pro
The source for this item installs with a Pro licence key. Log in with your key to see the install command, or read the Pro setup page.
| Prop | Type | Description |
|---|---|---|
loadRegions | (countryCode) => Promise<string[]> | The regions of a country. [] means it has none. |
countries | { code, name }[] | The first select. Defaults to three sample countries. |
onChange | ({ country, region }) => void | Called on every change; the region is "" right after the country changes. |
aria-busy while loading.The pattern ships with a Testing Library test (dependent-country-region-select.test.tsx) that covers: its main behaviour, the keyboard path and the error or empty states.