mirror of
https://github.com/youzan/vant.git
synced 2025-10-21 11:17:41 +00:00
feat(CheckboxGroup): add direction prop
This commit is contained in:
@@ -9,6 +9,7 @@ export default createComponent({
|
||||
props: {
|
||||
max: [Number, String],
|
||||
disabled: Boolean,
|
||||
direction: String,
|
||||
iconSize: [Number, String],
|
||||
checkedColor: String,
|
||||
value: {
|
||||
@@ -42,6 +43,6 @@ export default createComponent({
|
||||
},
|
||||
|
||||
render() {
|
||||
return <div class={bem()}>{this.slots()}</div>;
|
||||
return <div class={bem([this.direction])}>{this.slots()}</div>;
|
||||
},
|
||||
});
|
||||
|
8
src/checkbox-group/index.less
Normal file
8
src/checkbox-group/index.less
Normal file
@@ -0,0 +1,8 @@
|
||||
@import '../style/var';
|
||||
|
||||
.van-checkbox-group {
|
||||
&--horizontal {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user