Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <div class="stickyWrap">
- <div id="header">content</div>
- <div id="nav">content</div>
- </div>
- #header{
- -webkit-transition: all 0.3s linear 0s;
- -moz-transition: all 0.3s linear 0s;
- -o-transition: all 0.3s linear 0s;
- transition: all 0.3s linear 0s;
- -webkit-backface-visibility: hidden; /* Chrome, Safari, Opera */
- backface-visibility: hidden;
- padding: 20px 0;
- }
- .stickyWrap.sticky {
- position: fixed;
- top: 0;
- width: 100%;
- z-index: 99;
- }
- .stickyWrap.sticky #header {
- padding: 5px 0;
- -webkit-transition: all 0.2s ease-in-out 0s;
- -moz-transition: all 0.2s ease-in-out 0s;
- -o-transition: all 0.2s ease-in-out 0s;
- transition: all 0.2s ease-in-out 0s;
- -webkit-backface-visibility: hidden; /* Chrome, Safari, Opera */
- backface-visibility: hidden;
- }
- .myAnimatingClass{
- transform: translate3d(0,0,0);
- }
Add Comment
Please, Sign In to add comment