From 3b9b75c9a7e39476579cab49a4931b061accff00 Mon Sep 17 00:00:00 2001 From: Yao Date: Sun, 21 Jan 2018 13:13:26 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20Toptips=20=E5=9C=A8?= =?UTF-8?q?=E6=8E=A7=E5=88=B6=E5=8F=B0=E7=9A=84=E6=8A=A5=E9=94=99=20(#114)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/toptips/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/toptips/index.js b/packages/toptips/index.js index af5104ea..279a874f 100644 --- a/packages/toptips/index.js +++ b/packages/toptips/index.js @@ -4,7 +4,7 @@ module.exports = { // 如果已经有一个计时器在了,就清理掉先 if (zanTopTips.timer) { clearTimeout(zanTopTips.timer); - zanTopTips.timer = undefined; + zanTopTips.timer = -1; } if (typeof options === 'number') { @@ -22,7 +22,7 @@ module.exports = { let timer = setTimeout(() => { this.setData({ 'zanTopTips.show': false, - 'zanTopTips.timer': undefined + 'zanTopTips.timer': -1 }); }, options.duration);