import{e as s,o as a,G as t}from"./vendor.9cc7b6f2.js";const n={class:"markdown-body"},l=[t('
Tag 标签
介绍
用于标记和分类的标签。
安装
\nimport { createApp } from 'vue';\n\nimport { Tag } from '@nutui/nutui';\n\nimport { Tag } from '@nutui/nutui-taro';\n\nconst app = createApp();\napp.use(Tag);\n\n
代码实例
基础用法
<nut-tag type="primary">标签</nut-tag>\n <nut-tag type="success">标签</nut-tag>\n <nut-tag type="danger">标签</nut-tag>\n <nut-tag type="warning">标签</nut-tag>\n
空心样式
<nut-tag plain>标签</nut-tag>\n
圆角样式
<nut-tag round type="primary">标签</nut-tag>\n
标记样式
<nut-tag mark type="primary">标签</nut-tag>\n
可关闭标签
<nut-tag v-if="show" closeable @close="close" type="primary">标签</nut-tag>\n
自定义颜色
<nut-tag color="#FA685D">标签</nut-tag>\n <nut-tag color="#E9E9E9" text-color="#999999">标签</nut-tag>\n <nut-tag color="#FA2400" plain>标签</nut-tag>\n
Prop
| 字段 | 说明 | 类型 | 默认值 |
|---|
| type | 标签类型,可选值为primary success danger warning | String | default |
| color | 标签颜色 | String | - |
| text-color | 文本颜色,优先级高于color属性 | String | white |
| plain | 是否为空心样式 | Boolean | false |
| round | 是否为圆角样式 | Boolean | false |
| mark | 是否为标记样式 | Boolean | false |
| closeable | 是否为可关闭标签 | Boolean | false |
Slots
Event
',24)],p={setup:(t,{expose:p})=>(p({frontmatter:{}}),(t,p)=>(a(),s("div",n,l)))};export{p as default};