Badge
Distintivo
Un badge è un piccolo segno non cliccabile attaccato a un altro elemento. Mostra un conteggio, uno stato o un segnale breve ed è un modello di design, non uno standard web.
Un esempio vero
Una casella di posta ha tre messaggi non letti ad alta priorità. Il testo della casella di posta e il nome accessibile entrambi indicano il conteggio senza rendere il badge una fermata separata della tastiera. Una pillola filtro cliccabile è un chip, non un badge.
Parti principali
- 01elemento host
- 02Valore compatto
- 03equivalente accessibile
Usalo quando
Usa questo termine per un piccolo stato o conteggio aggiuntivo collegato a un'etichetta o icona principale.
Non usarlo quando
Non mettere testo lungo e essenziale, un'azione o il significato visibile solo dal colore all'interno di un badge.
Nome usato nel codice
label + noninteractive status indicator Prima di spedire
Before release, check the page structure, keyboard access, visible focus, contrast, and zoom. Also check loading, empty, error, success, cancel, and reduced-motion states.
Outcome: Complete the task with Distintivo (Badge). User context: Una casella di posta ha tre messaggi non letti ad alta priorità. Il testo della casella di posta e il nome accessibile entrambi indicano il conteggio senza rendere il badge una fermata separata della tastiera. Una pillola filtro cliccabile è un chip, non un badge. Recommended pattern: Distintivo (Badge). Why it fits: Usa questo termine per un piccolo stato o conteggio aggiuntivo collegato a un'etichetta o icona principale. Do not use it when: Non mettere testo lungo e essenziale, un'azione o il significato visibile solo dal colore all'interno di un badge. 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 Distintivo (Badge) is used now. Definition: Un badge è un piccolo segno non cliccabile attaccato a un altro elemento. Mostra un conteggio, uno stato o un segnale breve ed è un modello di design, non uno standard web. Release checks: Before release, check the page structure, keyboard access, visible focus, contrast, and zoom. Also check loading, empty, error, success, cancel, and reduced-motion states. Before changing code, list the evidence, gaps, severity, and the smallest safe fix.