mirror of
https://gitee.com/vant-contrib/vant-weapp.git
synced 2025-04-06 03:58:05 +08:00
修复 Toptips 在控制台的报错 (#114)
This commit is contained in:
parent
b9bfac3d5b
commit
3b9b75c9a7
@ -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);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user