Skip to content

Badge

A number or status mark on buttons and icons.

Basic usage

Displays the amount of new messages.

12
3
1
2

Standalone

Used in standalone when default slot is empty.

12
12
99+

Max Value

you can customize the max value. The max value is defined by property max which is a Number. Note that it only works when value is also a Number.

99+
10+

Customizations

Displays text content other than numbers. When value is a String, it can display customized text.

new
hot

Color

We provide a variety of preset colors for the badge. And you can also set a custom color by the color property.

blue
red
green
yellow
pink

Badge API

Badge Attributes

NameDescriptionTypeDefault
valueDisplay valueString Number-
maxMaximum value, shows {max}+ when exceeded. Only works if value is a numberNumber-
is-dotIf a little dot is displayedBooleanfalse
hiddenHidden badgeBooleanfalse
typeBadge typeStringdanger
colorCustomize dot colorString-
textSet the display text of the status dotString-