要素の高さをアニメーション化しています:
// Animate height of items
$j(".item .row").toggle(function(){
$j(this).animate({height:500},200);
},function(){
$j(this).animate({height:300},200);
});
イージングを追加する方法を考えていましたか?(例えば、アニメーションが最後に向かって遅くなる?)
要素の高さをアニメーション化しています:
// Animate height of items
$j(".item .row").toggle(function(){
$j(this).animate({height:500},200);
},function(){
$j(this).animate({height:300},200);
});
イージングを追加する方法を考えていましたか?(例えば、アニメーションが最後に向かって遅くなる?)
次の方法でイージングを定義します
$('selector').animate({
prop:1
},{
easing: easing, //Something like 'linear'
duration: duration,
complete: callback
});
Easing Pluginを含めることで、他のイージング効果も追加できます。
あなたの場合、それは次のようなものになります
$j(".item .row").toggle(function(){
$j(this).animate({height:500}, {
easing: 'linear',
duration: '200'
});
},function(){
$j(this).animate({height:300},{
easing: 'linear',
duration: '200'
});
});