修复:popup的zIndex转换为number (#24)

This commit is contained in:
张敏 2017-04-28 15:27:03 +08:00 committed by GitHub
parent 4bae492458
commit 58bd17f142
2 changed files with 3 additions and 4 deletions

View File

@ -66,15 +66,14 @@ export default {
/**
* 显示popup
*/
open(options) {
open() {
if (this.opened) return;
this.opening = true;
this.$emit('input', true);
const props = merge({}, this, options);
const zIndex = props.zIndex;
const zIndex = this.zIndex;
// 如果属性中传入了`zIndex`,则覆盖`popupContext`中对应的`zIndex`
if (zIndex) {

View File

@ -25,7 +25,7 @@ const PopupContext = {
},
plusKeyByOne(key) {
const oldVal = context[key];
const oldVal = +context[key];
context[key] = oldVal + 1;
return oldVal;