feat(Button): add icon-prefix prop (#5666)

This commit is contained in:
chenjiahan
2020-02-28 15:40:46 +08:00
parent 09b57901f5
commit 130e1ac7a6
9 changed files with 16 additions and 11 deletions
+1 -1
View File
@@ -116,12 +116,12 @@ Vue.use(GridItem);
|------|------|------|------|
| text | Text | *string* | - |
| icon | Icon name or URL | *string* | - |
| icon-prefix `v2.5.3` | Icon className prefix | *string* | `van-icon` |
| dot `v2.2.1` | Whether to show red dot | *boolean* | `false` |
| info `v2.2.1` | Content of the badge | *number \| string* | - |
| url | Link URL | *string* | - |
| to | Target route of the link, same as to of vue-router | *string \| object* | - |
| replace | If true, the navigation will not leave a history record | *boolean* | `false` |
| icon-prefix `v2.5.3` | Icon className prefix | *string* | `van-icon` |
### GridItem Events
+1 -1
View File
@@ -134,12 +134,12 @@ Vue.use(GridItem);
|------|------|------|------|
| text | 文字 | *string* | - |
| icon | [图标名称](#/zh-CN/icon)或图片链接 | *string* | - |
| icon-prefix `v2.5.3` | 图标类名前缀,同 Icon 组件的 [class-prefix 属性](#/zh-CN/icon#props) | *string* | `van-icon` |
| dot `v2.2.1` | 是否显示图标右上角小红点 | *boolean* | `false` |
| info `v2.2.1` | 图标右上角徽标的内容 | *number \| string* | - |
| url | 点击后跳转的链接地址 | *string* | - |
| to | 点击后跳转的目标路由对象,同 vue-router 的 [to 属性](https://router.vuejs.org/zh/api/#to) | *string \| object* | - |
| replace | 是否在跳转时替换当前页面历史 | *boolean* | `false` |
| icon-prefix `v2.5.3` | 图标类名前缀 | *string* | `van-icon` |
### GridItem Events