【发布时间】:2015-02-02 19:50:22
【问题描述】:
我正在尝试使用 Jquery 2.1.1 为 translate3d 设置动画。在 10 秒内。然后,当动画完成时,我希望它提醒我。但问题是它没有动画。它只是立即更改为新的 css。
有没有什么英雄可以帮我解决这个问题?
我现在使用的代码:
$( ".circle" ).animate({ textIndent: 100 }, {
duration : 10000,
step : function() {
$(this).css("transform","translate3d(0px, 320px, 0px)");
},
complete : function() {
alert("completed the animation");
}
},'linear');
【问题讨论】:
-
您是否尝试过使用像这个人写的那样的辅助函数? cameronspear.com/blog/animating-translate3d-with-jquery
标签: jquery css animation transform