Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <script type="text/javascript" >
- $('.bs-sequence li').addClass('bb-anim-clear');
- $(window).scroll(function() {
- if (scrollResult('.bs-sequence')) { // переместил блок сюда
- showAnim('.bs-sequence li:nth-child(1)', 0);
- showAnim('.bs-sequence li:nth-child(2)', 500);
- showAnim('.bs-sequence li:nth-child(3)', 1000);
- }
- });
- function scrollResult(varCont) {
- var windowHeight = $(window).scrollTop() + $(window).height();
- var blockOffset = varCont.offset().top + varCont.height();
- return windowHeight >= blockOffset;
- }
- function showAnim(varBlock, varDelay) {
- setInterval(function(){
- $(varBlock).addClass('bb-anim-slide-up');
- }, varDelay);
- }
- </script>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement