Created
May 16, 2017 14:59
-
-
Save VasylKyryliuk/4a1b311bb112e77b72da16ec4fcba8f9 to your computer and use it in GitHub Desktop.
Появление фиксированного меню после ..px
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function fixedHeader() { | |
var | |
boss = $(window), | |
y = boss.scrollTop(); | |
if (y > (218)) { | |
$('.header-fixed-wrapper').fadeIn(200); | |
} else { | |
$('.header-fixed-wrapper').fadeOut(100); | |
} | |
} | |
$(window).on('scroll', function() { | |
fixedHeader(); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment