This commit is contained in:
梁灏 2018-09-10 16:10:35 +08:00
parent 16c2b8d26e
commit 7bafe9d94c
15 changed files with 230 additions and 27 deletions

View file

@ -52,6 +52,7 @@
import {directive as clickOutside} from 'v-click-outside-x';
import TransferDom from '../../directives/transfer-dom';
import { oneOf } from '../../utils/assist';
import { transferIndex, transferIncrease } from '../../utils/transfer-queue';
import Locale from '../../mixins/locale';
const prefixCls = 'ivu-poptip';
@ -118,6 +119,7 @@
showTitle: true,
isInput: false,
disableCloseUnderTransfer: false, // transfer slot
tIndex: this.handleGetIndex()
};
},
computed: {
@ -144,6 +146,9 @@
if (this.width) {
style.width = `${this.width}px`;
}
if (this.transfer) style['z-index'] = 1060 + this.tIndex;
return style;
},
localeOkText () {
@ -172,7 +177,7 @@
const styles = {};
if (this.padding !== '') styles['padding'] = this.padding;
return styles;
}
},
},
methods: {
handleClick () {
@ -254,6 +259,13 @@
}
return $children;
},
handleGetIndex () {
transferIncrease();
return transferIndex;
},
handleIndexIncrease () {
this.tIndex = this.handleGetIndex();
}
},
mounted () {