feat(RadioGroup): add direction prop

This commit is contained in:
陈嘉涵
2020-02-10 19:02:30 +08:00
parent 3ad9950c2f
commit 4dd41b23de
8 changed files with 85 additions and 13 deletions
+10
View File
@@ -33,6 +33,15 @@ export default {
};
```
### Horizontal
```html
<van-radio-group v-model="radio" direction="horizontal">
<van-radio name="1">Radio 1</van-radio>
<van-radio name="2">Radio 2</van-radio>
</van-radio-group>
```
### Disabled
```html
@@ -150,6 +159,7 @@ export default {
|------|------|------|------|
| v-model (v-model) | Name of checked radio | *any* | - |
| disabled | Disable all radios | *boolean* | `false` |
| direction `v2.5.0` | Direction, can be set to `horizontal` | *string* | `vertical` |
| icon-size `v2.2.3` | Icon size of all radios | *number \| string* | `20px` |
| checked-color `v2.2.3` | Checked color of all radios | *string* | `#1989fa` | - |