animation.step高频率触发,是否会中断后续step动画效果?

发布于 8 年前作者 dluo3358 次浏览最后编辑 8 年前来自 issues

handleAnimation() {

let animation = wx.createAnimation({

duration: 100,

timingFunction: ‘ease’,

delay: 10

});

let action = wx.createAnimation({

duration: 100,

timingFunction: ‘ease’,

delay: 10

});

action.translate(0, -40).opacity(1).step().translate(0, 0).opacity(1).step();

animation.translate(0, -40).opacity(1).step().translate(0, 0).opacity(1).step();

this.setData({

ani: animation.export(),

act: action.export()

})

}

问题是当点击频率很快时会造成.translate(0, 0).opacity(1).step();不生效,造成样式没有回到原位

1 回复
qiugang
qiugang1 楼6 年前

麻烦提供能复现问题的代码片段https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html