Skip to content

Badge

Badges bring the user's attention to something.

Usage

Badges will use the "default" variant by default, but you can use the available variants with the variant prop.

Edit live code

Variations

Variant mapping

You can map additional variant names to the default badge variants for badges using variants property. Provide the name of the new variant you want to support, and the name of the existing variant you wish to map it to.

Properties

NameValuesDefault

variant

defaultsuccesserrorwarninginfo

default

...

JSX.IntrinsicElements["span"]

Tokens

Theme tokens
TokenDefault Value
badge.variants