Usage
Tags are used to categorize or label content. They can contain text, icons, and be closable.
React
TypeScript
New
Tag component for categorizing and labeling content with various styles and interactive features.
Experiment with all the properties of the Tag component in real time.
Text to display in the tag.
Color scheme of the tag.
Visual style of the tag.
Size of the tag.
Border radius of the tag.
Tags are used to categorize or label content. They can contain text, icons, and be closable.
Tag supports five variants: solid, soft, outline, dashed, and subtle.
Tags come in various colors to communicate different states or categories.
Available in four sizes: tiny, small, medium, and large.
You can add icons to tags using the icon prop.
Add the onClose prop to make a tag closable.
Prop | Default | Type |
|---|---|---|
text | undefined | string |
icon | undefined | React.ReactNode |
onClose | undefined | () => void |
variant | "soft" | "solid" | "soft" | "outlined" | "ghost" |
color | "neutral" | "neutral" | "primary" | "secondary" | "success" | "danger" | "warning" | "info" |
size | "medium" | "tiny" | "small" | "medium" | "large" |
radius | "medium" | "none" | "tiny" | "small" | "medium" | "large" | "full" |