You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

26 lines
562 B
JavaScript

9 months ago
const duration = 300;
const timingFun = "ease";
const width = 0;
var ani_width = function(duration,timingFunc,width){
if (undefined != duration){
this.duration = duration;
}
if (undefined != timingFun) {
this.timingFun = timingFun;
}
if (undefined != width) {
this.width = width;
}
var animation = wx.createAnimation({
duration: duration,
timingFunction: timingFunc
});
animation.width(width).step();
return animation.export();
}
module.exports = {
ani_width: ani_width
}