Content
Badge
A small pill of words that states a status or a count, such as "Done" or "1 h 32 late"; people read it, they do not press it.
In kanso-ui as Badge
Variants and sizes
k-badge: neutral, oncontainer: "Before bed".k-badge--accent: anaccentfill for "Now" only; it spends the product colour.k-badge--accent-soft: a quietaccent-softfill: "Up next".k-badge--positive: done, or money coming in: "Done" withcheck.k-badge--caution: late, or needs attention: "1 h 32 late" withschedule.k-badge--negative: money over budget: "Over budget".k-badge--critical: errors only: "Not saved" witherror.k-badge--count: an ink pill with a number, round for one digit: 3.
States
A badge has no hover, focus or pressed state; it changes with the data. Weekly review reads "1 h 32 late" until it is marked, then "Done". Each state is a different word, so colour is never the only cue.
Do and don’t
Do
Write the state as words: "Done", "1 h 32 late", "Over budget".
Keep one badge per row, at its end.
Keep negative for money and critical for errors: money over budget is never a broken field.
Don’t
Use the accent badge for anything but now.
Use a badge as a button or a filter.
What you provide
- The words and the variant.
- Icon name, optional:
check,schedule,error. - For a count: the number, and the words that say what it counts.