Phone input
CoreA phone field with a country picker, formatting as you type, and E.164 output.
pnpm dlx shadcn@latest add https://wui.alann.works/r/phone-input.jsonAPI Reference
| Prop | Type | Default |
|---|---|---|
label* | string | required |
hideLabel | boolean | — |
value | string | — |
defaultValue | string | — |
onValueChange | (value: string, details: PhoneInputDetails) => void | — |
country | string | — |
defaultCountry | string | — |
onCountryChange | (iso: string) => void | — |
countries | string[] | — |
preferredCountries | string[] | — |
description | string | — |
error | string | — |
validate | boolean | — |
disabled | boolean | — |
required | boolean | — |
name | string | — |
id | string | — |
className | string | — |
onBlur | (event: ReactFocusEvent<HTMLInputElement>) => void | — |