Skip to content

    Badges 组件

    Badge 适合在标题旁、列表项后、文案段落中标记状态。

    基础用法

    推荐已上线实验中高优先级
    Markdown
    <Badge type="tip" text="推荐" />
    <Badge type="success" text="已上线" />
    <Badge type="caution" text="实验中" />
    <Badge type="danger" text="高优先级" />

    轮廓和自定义色

    Outline自定义色小号

    Props

    参数类型默认值说明示例
    typenote | tip | info | warning | caution | danger | successnote徽标类型。type="success"
    textstring''文本,不传时可使用默认插槽。text="已上线"
    iconstring''图标(Iconify 名称)。icon="mdi:check-circle-outline"
    colorstring''自定义主色。color="#00a7b7"
    outlinebooleanfalse是否轮廓样式。:outline="true"
    sizesm | mdmd徽标尺寸。size="sm"

    最后更新于: