fix(Popup): legacy removeNode

This commit is contained in:
chenjiahan 2020-08-07 07:17:19 +08:00
parent 5d2cd516ed
commit 34ff811102
2 changed files with 0 additions and 14 deletions

View File

@ -3,7 +3,6 @@ import { context } from './context';
// Utils
import { on, off, preventDefault } from '../../utils/dom/event';
import { removeNode } from '../../utils/dom/node';
import { getScroller } from '../../utils/dom/scroll';
// Mixins
@ -85,15 +84,9 @@ export function PopupMixin(options = {}) {
},
beforeDestroy() {
this.removeLock();
if (this.opened) {
this.removeLock();
}
if (this.getContainer) {
removeNode(this.$refs.root);
}
},
/* istanbul ignore next */

View File

@ -1,7 +0,0 @@
export function removeNode(el: Node) {
const parent = el.parentNode;
if (parent) {
parent.removeChild(el);
}
}