当前位置: 首页 > 文档资料 > Feui 中文文档 >

Badge 徽章

优质
小牛编辑
121浏览
2023-12-01
import { Badge } from 'feui';
components: {
  [Badge.name]: Badge
}

代码演示

基础用法

<fe-badge text="1"></fe-badge>

与其他组件同用

<fe-group title='表格中使用'>
  <fe-cell title="个位数" is-link>
    <div class="badge-value" slot="value">
      <span class="vertical-middle">未读消息  </span>
      <fe-badge text="8"></fe-badge>
    </div>
  </fe-cell>
  <fe-cell title="较大数据" is-link>
    <div class="badge-value" slot="value">
      <span class="vertical-middle">新信息  </span>
      <fe-badge text="888"></fe-badge>
    </div>
  </fe-cell>
</fe-group>

API

参数 说明 类型 默认值 可选值
text 显示的文字 String - -
- - - - -