Created
September 7, 2018 14:42
-
-
Save fiximportant/86af3d62ce4b82900e1df4153b62e403 to your computer and use it in GitHub Desktop.
Smoth Scroll Anchors
This file contains 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
//SMOTH SCROLL MENU | |
$('.sp-megamenu-parent > li > a').click(function(){ | |
$('html, body').animate({ | |
scrollTop: $( $.attr(this, 'href') ).offset().top - 59 /* Minus 59 pixels */ | |
}, 500); | |
return false; | |
}); | |
//END |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment