popper: destroy popper instance(#13988)

pull/12547/head
王小白 2019-01-23 11:22:54 +08:00 committed by hetech
parent c154292d1b
commit 4b02ed7c51
2 changed files with 5 additions and 0 deletions

View File

@ -121,6 +121,7 @@ loadingDirective.install = Vue => {
el.mask.parentNode.removeChild(el.mask); el.mask.parentNode.removeChild(el.mask);
toggleLoading(el, { value: false, modifiers: binding.modifiers }); toggleLoading(el, { value: false, modifiers: binding.modifiers });
} }
el.instance && el.instance.$destroy();
} }
}); });
}; };

View File

@ -205,6 +205,10 @@ export default {
} }
}, },
beforeDestroy() {
this.popperVM && this.popperVM.$destroy();
},
destroyed() { destroyed() {
const reference = this.referenceElm; const reference = this.referenceElm;
off(reference, 'mouseenter', this.show); off(reference, 'mouseenter', this.show);