Input phone

Interactive documentation for the phone input component. Change props in the playground, inspect validation states, and copy the generated example.

Preview

Code

<InputPhone
  v-model="phone"
/>

Model

{
  "number": "",
  "country": "CA"
}

Sizes

Examples for supported phone input sizes.

Size L — no label

Size XL — with label

States

Common phone input states for filled, disabled, required, and error.

Empty

Filled

Disabled

Error

Invalid phone number

Props

This table matches the current InputPhoneProps interface.

PropTypeDefaultDescription
modelValuePhoneNumberModel{ number: '', country: 'CA' }Current phone value object containing full phone number and selected country.
size'l' | 'xl''l'Controls height, padding, icon size, spacing, and typography.
disabledbooleanfalseDisables the phone input and country selector interaction.
labelstringundefinedFloating label rendered above the phone input.
requiredbooleanfalseDisplays required indicator inside the floating label.
errorstringundefinedDisplays error styles and renders an error message below the input.
classstring'w-full'Additional classes applied to the root container.