Tag
DesignEngineeringProduct
A compact label for a category, status or filter, optionally removable.
A Markdown brief for Claude, Cursor or v0: install, setup, props and a complete example.
For categories, statuses or active filters, as short labels.
A count or a dot that flags something new? Badge.
Color is never the only signal: the text says the status. A removable tag’s button is named "Remove" plus the tag’s label.
import { Tag } from '@idyeah/diya'Stable since 1.0.0
childrenRequiredReactNodeVisible tag text.
labelstringPlain-text name for the tag, not shown; the remove button is announced as "Remove {label}". Defaults to the text of children.
leadingReactNode'dot' shows a small dot in the tag's tone; any other node is a decorative icon. Both are hidden from screen readers.
onRemove() => voidWhen given, shows a remove button that calls it.
size"small" | "medium" | "large"Tag height and text size. Defaults to 'medium'.
Default 'medium'
toneToneColor meaning: 'neutral' plain, 'brand' a soft tint of your brand color, 'success' done, 'warning' needs care, 'error' failed, 'info' for information. Defaults to 'neutral'.
Default 'neutral'
Also takes every native <span> attribute, such as id, aria-* or data-*.