mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-24 02:16:12 +08:00
feat(Grid): column-num can be string
This commit is contained in:
parent
4d1db0fa0f
commit
1af1f4ac4f
@ -102,13 +102,13 @@ Vue.use(GridItem);
|
|||||||
|
|
||||||
| Attribute | Description | Type | Default |
|
| Attribute | Description | Type | Default |
|
||||||
|------|------|------|------|
|
|------|------|------|------|
|
||||||
| column-num `v2.0.4` | Column Num | *number* | `4` |
|
| column-num `v2.0.4` | Column Num | *number \| string* | `4` |
|
||||||
|
| icon-size `v2.2.6` | Icon size | *number \| string* | `28px` |
|
||||||
| gutter | Gutter | *number \| string* | `0` |
|
| gutter | Gutter | *number \| string* | `0` |
|
||||||
| border | Whether to show border | *boolean* | `true` |
|
| border | Whether to show border | *boolean* | `true` |
|
||||||
| center | Whether to center content | *boolean* | `true` |
|
| center | Whether to center content | *boolean* | `true` |
|
||||||
| square | Whether to be square shape | *boolean* | `false` |
|
| square | Whether to be square shape | *boolean* | `false` |
|
||||||
| clickable | Whether to show click feedback when clicked | *boolean* | `false` |
|
| clickable | Whether to show click feedback when clicked | *boolean* | `false` |
|
||||||
| icon-size `v2.2.6` | Icon size | *number \| string* | `28px` |
|
|
||||||
|
|
||||||
### GridItem Props
|
### GridItem Props
|
||||||
|
|
||||||
|
@ -120,13 +120,13 @@ Vue.use(GridItem);
|
|||||||
|
|
||||||
| 参数 | 说明 | 类型 | 默认值 |
|
| 参数 | 说明 | 类型 | 默认值 |
|
||||||
|------|------|------|------|
|
|------|------|------|------|
|
||||||
| column-num `v2.0.4` | 列数 | *number* | `4` |
|
| column-num `v2.0.4` | 列数 | *number \| string* | `4` |
|
||||||
|
| icon-size `v2.2.6` | 图标大小,默认单位为`px` | *number \| string* | `28px` |
|
||||||
| gutter | 格子之间的间距,默认单位为`px` | *number \| string* | `0` |
|
| gutter | 格子之间的间距,默认单位为`px` | *number \| string* | `0` |
|
||||||
| border | 是否显示边框 | *boolean* | `true` |
|
| border | 是否显示边框 | *boolean* | `true` |
|
||||||
| center | 是否将格子内容居中显示 | *boolean* | `true` |
|
| center | 是否将格子内容居中显示 | *boolean* | `true` |
|
||||||
| square | 是否将格子固定为正方形 | *boolean* | `false` |
|
| square | 是否将格子固定为正方形 | *boolean* | `false` |
|
||||||
| clickable | 是否开启格子点击反馈 | *boolean* | `false` |
|
| clickable | 是否开启格子点击反馈 | *boolean* | `false` |
|
||||||
| icon-size `v2.2.6` | 图标大小,默认单位为`px` | *number \| string* | `28px` |
|
|
||||||
|
|
||||||
### GridItem Props
|
### GridItem Props
|
||||||
|
|
||||||
|
@ -13,7 +13,7 @@ export default createComponent({
|
|||||||
iconSize: [Number, String],
|
iconSize: [Number, String],
|
||||||
clickable: Boolean,
|
clickable: Boolean,
|
||||||
columnNum: {
|
columnNum: {
|
||||||
type: Number,
|
type: [Number, String],
|
||||||
default: 4,
|
default: 4,
|
||||||
},
|
},
|
||||||
center: {
|
center: {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user