Every line of 'auto scrolling jquery' code snippets is scanned for vulnerabilities by our powerful machine learning engine that combs millions of open source libraries, ensuring your JavaScript code is secure.
208 function smoothScrolling() { 209 //Special case for chat 210 if ($(".active").attr('id') === "chat") { 211 smoothScrollBottom(); 212 } 213 }
48 allowScrolling() { 49 if (this.locked === true) { 50 lockingCounter = lockingCounter - 1; 51 this.locked = false; 52 } 53 54 if (lockingCounter === 0 && originalBodyOverflow !== null) { 55 const body = document.getElementsByTagName('body')[0]; 56 body.style.overflow = originalBodyOverflow || ''; 57 originalBodyOverflow = null; 58 } 59 }
36 function scroll_to(delta) { 37 38 if (delta < 0 ) { 39 40 delta = -scrollinc; 41 } else { 42 43 delta = scrollinc; 44 } 45 46 delta = delta * deltaKoef; 47 48 var listWidth = scroller.find('.dslca-section-scroller-content').width(); 49 var contentWidth = scroller.width(); 50 51 if ( listWidth <= contentWidth ) return false; 52 53 var scrollMax = listWidth - contentWidth + 10; 54 55 delta = parseInt(scrollInner.style.left || 0) - delta; 56 delta = delta >= 0 ? 0 : delta; 57 delta = delta <= -scrollMax ? -scrollMax : delta; 58 59 scrollInner.style.left = delta + 'px'; 60 }
59 function scrolling(i) { 60 if (this.pageYOffset >= i * Math.floor(this.pageYOffset/OFFSET)*OFFSET) { 61 $scope.yLoc = i * Math.ceil(this.pageYOffset/OFFSET)*OFFSET; 62 } 63 else { 64 scrolling(i + 1); 65 } 66 }
65 function shouldAutoScroll(o) { 66 return (o.scrollTop == (o.scrollHeight - o.clientHeight)); 67 }
37 preventScrolling () { 38 if (this.locked === true) { 39 return 40 } 41 lockingCounter = lockingCounter + 1 42 this.locked = true 43 44 // only lock the first time the component is mounted. 45 if (lockingCounter === 1) { 46 const body = document.getElementsByTagName('body')[0] 47 originalBodyOverflow = body.style.overflow 48 body.style.overflow = 'hidden' 49 } 50 }
234 export function scroll(data: ScrollData, iframe: HTMLIFrameElement): void { 235 let target = getNode(data.target); 236 if (target) { target.scrollTo(data.x, data.y); } 237 }
37 function doScroll() { 38 var scroll = $(window).scrollTop(); 39 var windowHeight = $(window).height(); 40 var documentHeight = $(document).height(); 41 42 var heightLessScroll = (documentHeight - windowHeight) - scroll; 43 44 if (heightLessScroll <= MINIMUM_HEIGHT_FOR_TO_LOAD) { 45 // $('.show-more').trigger('click'); 46 } 47 }
3 function scroll () { 4 if (window.location.hash === '') return 5 const anchor = $j('a[href="' + window.location.hash + '"]') 6 if (anchor) $j(window).scrollTop(anchor.offset().top) 7 }
34 var scrolling = function scrolling() { 35 var currentScroll = view.scrollTop; 36 for (var i = headings.length - 1; i >= 0; i--) { 37 var currentHeader = headings[i]; 38 var headingPosition = currentHeader.offsetTop - view.offsetTop; 39 var offset = headingPosition - currentScroll; 40 var currentHeight = currentHeader.offsetHeight; 41 var differentHeaders = currentlyFixed != currentHeader; 42 // Effect 43 if (!notApplyEffect && Math.abs(offset) < currentHeight && 44 differentHeaders) { 45 var toMove = Math.abs(offset) - currentHeight; 46 var inEffect = toMove <= 0; 47 var translateTop = 'translateY(' + toMove + 'px)'; 48 var transform = inEffect ? translateTop : null; 49 fixedContainer.style.transform = transform; 50 } 51 52 // Switching Header 53 if (offset <= 0) { 54 if (differentHeaders) { 55 if (!notApplyEffect) 56 fixedContainer.style.transform = 'translateY(0)'; 57 currentlyFixed = currentHeader; 58 fixedContainer.textContent = currentHeader.textContent; 59 if (currentHeader.id == 'group-favorites') { 60 fixedContainer.innerHTML = currentHeader.innerHTML; 61 } 62 } 63 return; 64 } 65 } 66 currentlyFixed = null; 67 if (!notApplyEffect) 68 fixedContainer.style.transform = 'translateY(-100%)'; 69 };