[bugfix] Popup overlayClass type (#374)

This commit is contained in:
neverland 2017-12-04 16:42:28 +08:00 committed by GitHub
parent d78e261820
commit 03824c5b07
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 16 additions and 33 deletions

View File

@ -44,7 +44,7 @@ Use `position` prop to set popup display position
| lockOnScroll | Lock body scroll | `Boolean` | `false` | - |
| position | Position | `String` | - | `top` `bottom` `right` `left` |
| overlayClass | Custom overlay class | `String` | `` | - |
| overlayStyle | Custom overlay style | `Object` | `` | - |
| overlayStyle | Custom overlay style | `Object` | - | - |
| closeOnClickOverlay | Close popup when click overlay | `Boolean` | `true` | - |
| transition | Transition | `String` | `popup-slide` | - |
| preventScroll | Prevent background scroll | `Boolean` | `false` | - |

View File

@ -58,7 +58,7 @@ export default {
</script>
<style lang="postcss">
@import '../../../packages/vant-css/src/common/var';
@import '../../../packages/vant-css/src/common/var.css';
.side-nav {
width: 100%;

View File

@ -3,41 +3,24 @@ import context from './popup-context';
export default {
props: {
// popup 当前显示状态
value: {
type: Boolean,
default: false
},
// 是否显示遮罩层
overlay: {
type: Boolean,
default: false
},
// 点击遮罩层是否关闭 popup
closeOnClickOverlay: {
type: Boolean,
default: false
},
// whether to show popup
value: Boolean,
// whether to show overlay
overlay: Boolean,
// overlay custom style
overlayStyle: Object,
// overlay custom class name
overlayClass: String,
// whether to close popup when click overlay
closeOnClickOverlay: Boolean,
// z-index
zIndex: [String, Number],
// popup 滚动时是否禁用 body 滚动
// prevent touchmove scroll
preventScroll: Boolean,
// prevent body scroll
lockOnScroll: {
type: Boolean,
default: true
},
// 防止滚动穿透
preventScroll: {
type: Boolean,
default: false
},
// 遮罩层额外样式
overlayStyle: {
type: String,
default: ''
},
// 遮罩层额外类
overlayClass: {
type: String,
default: ''
}
},