From 24ef11afb9556386a48028a88837bf20dd8643b8 Mon Sep 17 00:00:00 2001 From: tanjinzhou <415800467@qq.com> Date: Tue, 9 Jun 2020 18:29:34 +0800 Subject: [PATCH] fix: update util --- components/_util/openAnimation.js | 4 ++-- components/_util/props-util.js | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/components/_util/openAnimation.js b/components/_util/openAnimation.js index 2c81887ee..29d98f0bf 100644 --- a/components/_util/openAnimation.js +++ b/components/_util/openAnimation.js @@ -1,6 +1,6 @@ import cssAnimation from './css-animation'; import raf from 'raf'; -import Vue from 'vue'; +import { nextTick } from 'vue'; function animate(node, show, done) { let height; @@ -55,7 +55,7 @@ function animate(node, show, done) { const animation = { enter(node, done) { - Vue.nextTick(() => { + nextTick(() => { animate(node, true, done); }); }, diff --git a/components/_util/props-util.js b/components/_util/props-util.js index b1d546d37..b69597779 100644 --- a/components/_util/props-util.js +++ b/components/_util/props-util.js @@ -269,7 +269,7 @@ export function getComponentName(opts) { } export function isEmptyElement(c) { - return typeof c.type === 'symbol' && c.children.trim() === ''; + return typeof c.type.toString() === 'Symbol(Text)' && c.children.trim() === ''; } export function isStringElement(c) {