PageSourceSearch

https://www.seahamhighschool.com/_site/js/min/functions.min.js?cache=260715

js seahamhighschool.com collected 2026-10-01 15:32:55 UTC 8,131 bytes, 1 lines download raw bytes

1"use strict";function inView(){var t=document.querySelectorAll("[data-inview]");if("IntersectionObserver"in window){var a=new IntersectionObserver(function(t,e){for(var n=0;n<t.length;n++)if(t[n].isIntersecting){var i=t[n].target;viewed(i),a.unobserve(i)}},{threshold:0});console.log("inViewObserver",a);for(var e=0;e<t.length;e++)a.observe(t[e])}else{for(var n=[],i=0;i<t.length;i++){for(var o=t[i],l=0,r=o.dataset.inview;o;)l+=o.offsetTop-o.scrollTop+o.clientTop,o=o.offsetParent;l<intScrollPosition+document.documentElement.clientHeight+0*t[i].clientHeight?viewed(t[i]):n.push([l+0*t[i].clientHeight,t[i],r])}document.addEventListener("scroll",function(){for(var t=intScrollPosition+document.documentElement.clientHeight,e=0;e<n.length;e++)n[e][0]<t&&(viewed(n[e][1]),n.splice(e,1))})}}function viewed(t){var e=t.getAttribute("data-inview"),n=t.getAttribute("data-owlview");if(""!==e?document.querySelector(e).classList.add("inview"):t.classList.add("inview"),void 0!==n&&(console.log("element",t),loadOwlImages($(t))),t.hasAttribute("data-callback")){var i=t.getAttribute("data-callback");window[i]()}}function lazyLoad(){var t=document.querySelectorAll("[data-lazy]");if("IntersectionObserver"in window)for(var a=new IntersectionObserver(function(t,e){for(var n=0;n<t.length;n++)if(t[n].isIntersecting){var i=t[n].target;writeImg(i,i.getAttribute("data-lazy")),a.unobserve(i)}},{rootMargin:"0px 0px 0px 0px"}),e=0;e<t.length;e++)a.observe(t[e]);else{for(var n=[],i=0;i<t.length;i++){var o=t[i],l=o.getAttribute("data-lazy").replace(/\s/g,"%20"),r=o.getBoundingClientRect().top+document.documentElement.scrollTop;r<intScrollPosition+document.documentElement.clientHeight-0?writeImg(t[i],t[i].getAttribute("data-lazy")):n.push([r-0,t[i],l])}document.addEventListener("scroll",function(){for(var t=intScrollPosition+document.documentElement.clientHeight,e=0;e<n.length;e++)n[e][0]<t&&(writeImg(n[e][1],n[e][2]),n.splice(e,1))})}}function writeImg(n,t){n.classList.add("lazy--prep");var i=n.querySelector(".lazy__load__img");null==i&&((i=document.createElement("div")).className="lazy__load__img",n.appendChild(i));var a=t||n.getAttribute("data-img"),o=new Image;o.src=a,n.hasAttribute("data-alt")?o.alt=n.getAttribute("data-alt"):o.alt="",o.onload=function(){if(n.hasAttribute("data-bg"))i.style.backgroundImage="url("+a+")";else if(i.appendChild(o),"false"!==n.getAttribute("data-fill")){var t=o.naturalWidth,e=o.naturalHeight;resizeImg(o,t,e)}
1setTimeout(function(){n.classList.add("lazy--loaded")},300)},o.onerror=function(){if(console.log("error on element "+n+" - thumbnail loaded"),n.hasAttribute("data-bg"))i.style.backgroundImage="url("+strFallbackPath+")";else if(!o.src.includes(strFallbackPath)&&(o.src=strFallbackPath,i.appendChild(o),"false"!==n.getAttribute("data-fill"))){const t=o.naturalWidth,e=o.naturalHeight;resizeImg(o,t,e)}setTimeout((function(){n.classList.add("lazy--loaded")}),300)}}function resizeImg(t,e,n){var i=t.parentElement,a=e/n,o=i.offsetWidth,l=i.offsetHeight;parseInt(o/a)<l?(t.width=parseInt(l*a),t.height=parseInt(l)):(t.width=parseInt(o),t.height=parseInt(o/a))}function findSlide(t,e){if($(t).find("[data-img]").length){var n=$(t).find("[data-img]")[0];n.classList.contains("lazy--loaded")||writeImg(n)}}function loadCycle(t,e,n,i){if("string"==typeof t)t=$(t);e&&(t.on("cycle-initialized",function(t,e){findSlide(e.slides[0])}),t.on("cycle-before",function(t,e,n,i,a){findSlide(i)})),n&&t.on("cycle-before",function(t,e,n,i,a){var o=$(i),l=$(n);o.addClass("animate--in").siblings().removeClass("animate--out"),l.removeClass("animate--in").addClass("animate--out"),setTimeout(function(){l.removeClass("animate--out")},1e3)}),t.cycle(i)}function loadOwlCarousel(e,t,n){if("string"==typeof e)e=$(e);e.owlCarousel(n),t&&e.on("translated.owl.carousel",function(t){loadOwlImages(e)})}function loadOwlImages(t){t.find(".active").each(function(){findSlide($(this))})}function itemGrouping(t,e,n,i){for(var a=$(t),o=0;o<a.length;o+=e)a.slice(o,o+e).wrapAll(n).stop();i&&i()}function popup(t){return window.open(t,"popup","width=550, height=550, toolbar=0"),!1}function parallax(){for(var t=document.querySelectorAll("[data-parallax]"),e=new IntersectionObserver(function(t,e){for(var n=0;n<t.length;n++)for(var i=t[n].target,a=0;a<arrParallaxView.length;a++){var o=arrParallaxView[a];i==o[0]&&(o[2]=t[n].isIntersecting)}},{rootMargin:"50px 0px 50px 0px"}),n=0;n<t.length;n++){for(var i=t[n],a=document.querySelectorAll(i.getAttribute("data-watch"))[0],o=!1,l=0;l<arrParallaxView.length;l++){if(arrParallaxView[l][0]==a){o=l;break}}!1===o?(arrParallaxView.push([a,[i],!1]),e.observe(a)):arrParallaxView[o][1].push(i)}}function parallaxScroll(t){for(var e=0;e<arrParallaxView.length;e++){var n=arrParallaxView[e];if(1==n[2])for(var i=0;i<n[1].length;i++){var a=n[1][i],o=a.getAttribute("data-multiplier")||.1,l=a.getBoundingClientRect().top+t+a.offsetHeight/2,r=void 0;switch(a.getAttribute("data-parallax")){case"centre":r=(t-(l-intWinHeight/2))*o;break;case"centreFixed":0<(r=(t-(l-intWinHeight/2))*o)&&(r=0);break;case"centreInvert":r=(l-intWinHeight/2-t)*o;break;case"centreInvertFixed":(r=(l-intWinHeight/2-t)*o)<0&&(r=0);break;case"top":r=t*o;break;case"topInvert":r=-t*o;break;case"bottom":r=(t+intWinHeight-intDocHeight)*o;break;case"bottomInvert":r=-(t+intWinHeight-intDocHeight)*o}a.style.transform="translate3D(0,"+r+"px, 0)"}}}function stickyMenu(t,e,n,i){var a=document.getElementsByClassName(e)[0],o=a.offsetHeight;(a.offsetTop+o)*n<t?mason.classList.add(i):mason.classList.remove(i)}function scrollHandle(){5<=Math.abs(prevScrollPosition-intScrollPosition)&&(prevScrollPosition<intScrollPosition?mason.classList.remove("mason--scrollingup"):mason.classList.add("mason--scrollingup")),prevScrollPosition=intScrollPosition,"IntersectionObserver"in window&&parallaxScroll(intScrollPosition),"function"==typeof customScroll&&customScroll(intScrollPosition)}function runCustomAccordion(t,e,n,i){var a=$(t);if(a.length<1)return!1;a.unbind("click"),a.on("click",e,function(){var t=$(this),e=t.parent("li");e.siblings().removeClass("active").find(n).slideUp(i),e.hasClass("active")?(e.removeClass("active"),t.next(n).stop().slideUp(i)):(e.addClass("active"),t.next(n).stop().slideDown(i))})}var mason=document.getElementsByClassName("mason")[0],$window=$(window),blnAdmin=mason.classList.contains("mason--admin"),blnHome=mason.classList.contains("mason--home"),blnInner=mason.classList.contains("mason--inner"),blnForm=!!$(".content__form, .content__block__form").length,objFit="objectFit"in document.documentElement.style,strFallbackPath="/_site/images/design/thumbnail.jpg";console.log("objFitFallback",objFit);var intScrollPosition=0,prevScrollPosition=0,blnTicking=!1,intWinHeight=0,intDocHeight=0,arrParallaxView=[];document.addEventListener("DOMContentLoaded",function(){lazyLoad(),inView(),scripts(),intScrollPosition=window.pageYOffset,intWinHeight=window.innerHeight,intDocHeight=document.documentElement.scrollHeight,"IntersectionObserver"in window&&parallax()}),window.onload=function(){scrollHandle(intScrollPosition),mason.classList.add("mason--loaded")},window.addEventListener("resize",function(){if(!objFit)for(var t=document.querySelectorAll('.lazy--loaded:not([data-fill="false"])'),e=0;e<t.length;e++){var n=t[e];if(n.classList.contains("lazy--loaded")){var i=n.querySelector("img"),a=i.naturalWi
1dth,o=i.naturalHeight;resizeImg(n.querySelector("img"),a,o)}}}),$('[data-popupsource="true"]').each(function(){$(this).e4eDialog({title:"Select Source",width:400,height:450,buttons:[{id:"select",label:"Select",fn:"selectItem()",className:"primary"},"cancel"]})}),document.onscroll=function(){blnTicking||(intScrollPosition=window.pageYOffset,window.requestAnimationFrame(function(){scrollHandle(intScrollPosition),stickyMenu(intScrollPosition,"hero",.5,"mason--prep"),stickyMenu(intScrollPosition,"hero",1,"mason--sticky"),blnTicking=!1}),blnTicking=!0)},window.onresize=function(){intWinHeight=window.innerHeight,intDocHeight=document.body.scrollHeight,scrollHandle(intScrollPosition)},runCustomAccordion(".menu__list",".menu__list__item__button",".menu__list__item__sub",400);

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.