fix(mobile/menu): Shows when scroll top

This commit is contained in:
sovanna 2020-01-21 12:24:57 +01:00
parent 72ce996c37
commit a27c7370d6

View File

@ -218,6 +218,10 @@
var navbarSupportedContent = $('#navbarSupportedContent'); var navbarSupportedContent = $('#navbarSupportedContent');
mywindow.scroll(function () { mywindow.scroll(function () {
newscroll = mywindow.scrollTop(); newscroll = mywindow.scrollTop();
if (newscroll < 30) {
$('.container-header').stop().fadeIn();
return;
}
if (!navbarSupportedContent.hasClass('show')) { if (!navbarSupportedContent.hasClass('show')) {
if (newscroll > (mypos + 0) && !up) { if (newscroll > (mypos + 0) && !up) {
$('.container-header').stop().fadeOut(); $('.container-header').stop().fadeOut();