Last modified: 4/Oct/2024
Tag
Tags are compact elements that represent an attribute.
#Usage
import { Tag } from '@kinsta/stratus'
const MyComponent = () => (
<Tag theme="emerald">Beta</Tag>
)
#Props
#icon
"AnalyticsAlt" | "AnalyticsCircleAlt" | "AnalyticsCircleSolidAlt" | "AnalyticsCircleSolid" | "AnalyticsCircle" | "AnalyticsSmall" | "AnalyticsSquareAlt" | "AnalyticsSquareSolidAlt" | ... 530 more ... | { ...; }
Displays and Icon on either the left or right
#size
TagSize
The size of the tag
#theme
TagTheme
Determines the color scheme
#Migration guide
'emerald' - positive 'galaxy' - neutral 'graphite' - neutral 'lava' - negative 'waldo' - negative 'mercury' - neutral 'midnight' - neutral 'plum' - secondary 'ruby' - neutral 'silver' - neutral 'sky' - neutral 'sunflower' - warning 'sunset' - warning 'turquoise' - neutral 'unicorn' - secondary 'live' - positive
#Types
TagTheme
: strings that identify the colour of the tagTagProps
: props of theTag
component processed by stratusTagInterface
:TagProps
extended byHTMLAttributes<HTMLSpanElement>
Read more about types here