Divier add plain prop

This commit is contained in:
梁灏 2021-01-14 16:27:52 +08:00
parent 6f22675f39
commit 2bae54e9fe
3 changed files with 17 additions and 4 deletions

View file

@ -67,7 +67,9 @@
iView is a set of UI components and widgets built on Vue.js.
iView is a set of UI components and widgets built on Vue.js.
</p>
<Divider plain>iView</Divider>
<Divider orientation="left" plain>iView</Divider>
<Divider orientation="right" plain>iView</Divider>
</div>
</Card>
</i-col>

View file

@ -37,6 +37,11 @@
return oneOf(value, ['small', 'default']);
},
default: 'default'
},
// 4.5.0
plain: {
type: Boolean,
default: false
}
},
computed: {
@ -51,7 +56,8 @@
{
[`${prefixCls}-with-text`]: this.hasSlot && this.orientation === 'center',
[`${prefixCls}-with-text-${this.orientation}`]: this.hasSlot,
[`${prefixCls}-dashed`]: !!this.dashed
[`${prefixCls}-dashed`]: !!this.dashed,
[`${prefixCls}-plain`]: this.plain
}
];
},
@ -62,4 +68,4 @@
}
}
};
</script>
</script>

View file

@ -100,4 +100,9 @@
border-style: dashed none none;
}
}
}
&-plain&-with-text, &-plain&-with-text-left, &-plain&-with-text-right {
color: @text-color;
font-weight: normal;
font-size: @font-size-base;
}
}