【发布时间】:2012-01-25 09:20:05
【问题描述】:
环顾四周,找不到答案。我需要在这段代码中添加动画的持续时间:
$('a:has(.image-active)').hover(function() {
$('.image-active', this).stop().animate({"opacity": 1});
},function() {
$('.image-active', this).stop().animate({"opacity": 0});
});
但是,我不知道在哪里放置持续时间。刚才它淡入 1 淡出到 0,这一定是 jQuery 的默认值。
【问题讨论】:
标签: javascript jquery performance duration