In mobile version firefox everything works perfect.In chrome have bug with fixed positioning.When i scroll the header must change absolute to fixed and height 65 to 35 pixels.But its flickering. Im novice in web development.And its my first static web site. Im using jquery plugin skrollr.
Heres my jquery code
$(window).scroll(function(){
if ($(this).scrollTop() > 20) {
$('.menu ').addClass("sticky");
}
else {
$('.menu').removeClass("sticky");
}
});
and my CSS code
.menu {
position absolute;
background: white;
height: 65px;
}
.menu.sticky {
position:fixed;
height: 37px;
max-width: 480px;
padding: 0;
background: white;
}
Please help already week cant solve this problem.