[new feature] DropdownMenu: add overlay prop

This commit is contained in:
陈嘉涵 2019-05-07 20:42:03 +08:00
parent d935fa5fc7
commit df7d33b03d
4 changed files with 7 additions and 0 deletions

View File

@ -65,6 +65,7 @@ export default sfc({
position="top" position="top"
duration={0.2} duration={0.2}
class={bem('content')} class={bem('content')}
overlay={this.parent.overlay}
overlayStyle={{ position: 'absolute' }} overlayStyle={{ position: 'absolute' }}
> >
{Options} {Options}

View File

@ -82,6 +82,7 @@ export default {
|------|------|------|------|------| |------|------|------|------|------|
| active-color | Active color of title and option | `String` | `#1989fa` | | active-color | Active color of title and option | `String` | `#1989fa` |
| z-index | z-index of menu item | `Number` | `10` | | z-index | z-index of menu item | `Number` | `10` |
| overlay | Whether to show overlay | `Boolean` | `true` |
### DropdownItem Props ### DropdownItem Props

View File

@ -8,6 +8,10 @@ export default sfc({
mixins: [ParentMixin('vanDropdownMenu')], mixins: [ParentMixin('vanDropdownMenu')],
props: { props: {
overlay: {
type: Boolean,
default: true
},
zIndex: { zIndex: {
type: Number, type: Number,
default: 10 default: 10

View File

@ -84,6 +84,7 @@ export default {
|------|------|------|------|------| |------|------|------|------|------|
| active-color | 菜单标题和选项的选中态颜色 | `String` | `#1989fa` | - | | active-color | 菜单标题和选项的选中态颜色 | `String` | `#1989fa` | - |
| z-index | 菜单栏 z-index 层级 | `Number` | `10` | - | | z-index | 菜单栏 z-index 层级 | `Number` | `10` | - |
| overlay | 是否显示遮罩层 | `Boolean` | `true` | - | - |
### DropdownItem Props ### DropdownItem Props