Badge
A number or status mark on buttons and icons.
Basic Usage
Displays the amount of new messages.
Max Value
You can customize the max value.
Customizations
Displays text content other than numbers.
Red Dot
Use a red dot to mark content that needs to be noticed.
Offset 2.7.0
API
Attributes
Name | Description | Type | Default |
---|---|---|---|
value | display value. | string / number | '' |
max | maximum value, shows {max}+ when exceeded. Only works if value is a number. | number | 99 |
is-dot | if a little dot is displayed. | boolean | false |
hidden | hidden badge. | boolean | false |
type | badge type. | enum | danger |
show-zero 2.6.0 | Whether to show badge when value is zero. | boolean | true |
color 2.6.3 | background color of the dot | string | |
offset 2.7.0 | offset of badge | [ number , number ] | — |
badge-style 2.7.1 | custom style of badge | object | — |
badge-class 2.7.1 | custom class of badge | string | — |
Slots
Name | Description |
---|---|
default | customize default content |