Form Field
Campo modulo
Un'unità di input completa con etichetta visibile, un controllo, un aiuto facoltativo, lo stato di validazione e un messaggio di errore collegato.
Un esempio vero
Un campo per l'ID fiscale tiene la sua etichetta visibile. Spiega il formato prima di digitare e porta a un errore chiaro dopo la validazione.
Parti principali
- 01Etichetta persistente
- 02Input control
- 03Hint or format
- 04Validation message
Usalo quando
Fornisci a ogni valore un campo completo con un nome accessibile e un posto coerente per aiuto ed errori.
Non usarlo quando
Non usare testo segnaposto come unica etichetta. Non mostrare un errore solo tramite il colore.
Nome usato nel codice
label + input + aria-describedby + error message Prima di spedire
Give each field a label that code can read. Link hints and errors, and keep entered values. Check autofill, keyboard order, validation timing, submit states, failure recovery, zoom, and languages.
Outcome: Complete the task with Campo modulo (Form Field). User context: Un campo per l'ID fiscale tiene la sua etichetta visibile. Spiega il formato prima di digitare e porta a un errore chiaro dopo la validazione. Recommended pattern: Campo modulo (Form Field). Why it fits: Fornisci a ogni valore un campo completo con un nome accessibile e un posto coerente per aiuto ed errori. Do not use it when: Non usare testo segnaposto come unica etichetta. Non mostrare un errore solo tramite il colore. Product requirements: Define the default, loading, empty, error, success, and recovery states. Keep user input. Give clear feedback after every action. Accessibility and resilience: Use semantic HTML, full keyboard access, and visible focus. Make the layout work when zoomed and support reduced motion. Follow the project’s current rules. Do not add a new UI library unless the project already uses it. Acceptance criteria: The main task works with keyboard only and at 320px width. Focus and status changes are announced. Check loading, failure, retry, cancel, and reduced-motion paths. Evidence and limits (evidence boundary): È ufficiale per quella fonte. Altre piattaforme o team potrebbero usare il termine in modo diverso. Unknowns to confirm: Product wording, data source, analytics events, supported devices and languages, and platform limits.
Controlla questa richiesta
Review how Campo modulo (Form Field) is used now. Definition: Un'unità di input completa con etichetta visibile, un controllo, un aiuto facoltativo, lo stato di validazione e un messaggio di errore collegato. Release checks: Give each field a label that code can read. Link hints and errors, and keep entered values. Check autofill, keyboard order, validation timing, submit states, failure recovery, zoom, and languages. Before changing code, list the evidence, gaps, severity, and the smallest safe fix.