Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // FIX HEAD
- var min = false;
- $(document).scroll(function() {
- if($(document).scrollTop()>40&&!min)
- {
- $("#fix").toggleClass("line-head__wrap line-head__wrap--fixed");
- min = true;
- }
- if($(document).scrollTop()<=40&&min)
- {
- $("#fix").toggleClass("line-head__wrap line-head__wrap--fixed");
- min = false;
- }
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement