Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var sticky = new Waypoint.Sticky({
- element: $('.top-navigation')[0],
- offset: "-60%",
- handler: function(direction) {
- if (direction === 'down') {
- $('.top-navigation.stuck').css('top','-50px').animate(
- {
- 'top': '0px'
- }, 500);
- } else if (direction === 'up') {
- $('.top-navigation.stuck').css('top','0px').animate(
- {
- 'top': '-50px'
- }, 500);
- }
- }
- })
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement