1 2 3 4 5 //videoScroll// 6 window.addEventListener('load', videoScroll); 7 window.addEventListener('scroll', videoScroll); 8 9 function videoScroll() { 10 11 if ( document.querySelectorAll('video[autoplay]').length > 0) { 12 var windowHeight = window.innerHeight, 13 videoEl = document.querySelectorAll('video[autoplay]'); 14 15 for (var i = 0; i < videoEl.length; i++) { 16 17 var thisVideoEl = videoEl[i], 18 videoHeight = thisVideoEl.clientHeight, 19 videoClientRect = thisVideoEl.getBoundingClientRect().top; 20 21 if ( videoClientRect <= ( (windowHeight) - (videoHeight*.5) ) && videoClientRect >= ( 0 - ( videoHeight*.5 ) ) ) { 22 thisVideoEl.play(); 23 } else { 24 thisVideoEl.pause(); 25 } 26 } 27 } 28 } 29 //videoScroll// 30 31 32 33 34 35 36 37 const swiper = new Swiper('.swiper', { 38 slidesPerView: 'auto', 39 speed: 7000, 40 autoplay: { 41 delay: 0, 42 disableOnInteraction: false 43 }, 44 loop: true, 45 freeMode: { 46 enabled: true, 47 sticky: false, 48 } 49 }) 50 51 52 53 54 55
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.