Skip to content

Field

Associate a control with its label, instructions, and error message.

alpina-ui/ui/field

Interactive preview

Regional studio

New print job

At least three characters.

Usage notes

Put the label, help and correction next to their control. The accessible description reads the error first and includes each referenced hint only once.

When to use

Keep the label, format hint and error for one editor together across validation states.

When to avoid

Several radios or checkboxes sharing a question need a fieldset and legend.

Accessibility

Pass the supplied control attributes to the real input so its label, description and validation message are linked.

Keys
KeyAction
Tab / Shift+TabMove through any links or controls supplied inside the component, in document order.

Content

Name one value, give one concrete format example and use a corrective sentence for an error. Keep the hint separate from the label.

Use
Reference / Enter the reference shown on your letter.
Avoid
Invalid input!

Copy in four languages

German
Referenznummer14 characters
French
Numéro de référence19 characters
Italian
Numero di riferimento21 characters
Romansh
Numer da referenza18 characters
Add to your project
npx --no-install alpina add field