徽章 Badge
用于在目标元素(如图标、按钮、列表项等)上显示状态或数量提示的轻量型组件。
基础用法
支持 5 种按钮类型
10+
vue
<template>
<bp-badge :count="20" :max-count="10">
<IconNotification4Line fill="#595959" />
</bp-badge>
</template>Badge 属性
| text | 自定义文本 | String | - | - |
| count | 数值 | Number | - | - |
| max-count | 最大显示数值 | Number | 99 | - |
| dot | 是否显示小圆点 | Boolean | - | - |
| status | 状态类型 | String | primary | - |
| offset | 偏移量 | Array | [-2, -6] | - |
Badge 插槽
| default | 内容 | - | - |