Reputation: 35
i want to add some easing but it's not working :/
$(window).scroll(function() {
if ($(this).scrollTop() < 300)
{
$(".userbar").animate({top:"0px"}, {duration: 100}, {easing: easeInOutQuint});
}
else
{
$(".userbar").animate({top:"-70px"}, {duration: 100}, {easing: easeInOutQuint});
}
});
How is it possible?
Upvotes: 0
Views: 76
Reputation: 2383
working fiddle here, your curly brackets were off as well as the quoting.
$(".userbar").animate({left:"0px"},{duration: 100,easing: 'easeInOutQuint'});
Upvotes: 2