1if(typeof SliderVertical!="function"){class SliderVertical2 extends HTMLElement{constructor(){super()}init(){this.items=this.querySelectorAll("[data-js-item]"),this.prlxItems=this.querySelectorAll("[data-scroll-speed]"),this.slider=this.querySelector("[data-js-element]"),this.bgImage=this.querySelector("[data-js-background-image]"),this.bgImage&&(this.bgImageFigure=this.bgImage.querySelector("figure")),this.calculateHeight(),window.addEventListener("resize",debounce(()=>{this.scrollParallax(),this.bgImage&&this.scrollBackground(),this.calculateHeight()},300)),this.prlxItems.length>0&&(this._raf=!0,this.scrollParallax(),this.calculateHeight(),window.addEventListener("scroll",()=>{this._raf&&(this._raf=!1,requestAnimationFrame(this.scrollParallax.bind(this)),this.bgImage&&requestAnimationFrame(this.scrollBackground.bind(this)))},{passive:!0}))}scrollBackground(){Math.abs(this.bgImage.getBoundingClientRect().y)<window.innerHeight&&(this.bgImageFigure.style.transform=`translateY(${this.bgImage.getBoundingClientRect().y/-2}px)`)}scrollParallax(){const windowHeight=document.documentElement.clientHeight,windowWidth=document.documentElement.clientWidth;this.prlxItems.forEach(elm=>{let elementY=elm.getBoundingClientRect().y,scrollFactor=Number(elm.dataset.scrollSpeed);if(windowWidth>768&&windowWidth>windowHeight&&elementY<windowHeight*2&&elementY>(elm.offsetHeight+windowHeight)*-1){const prlx=(elm.parentElement.getBoundingClientRect().y-(windowHeight-elm.parentElement.offsetHeight)/2)*scrollFactor/2;Math.abs(prlx)<windowHeight&&(elm.style.transform=`translateY(${prlx}px)`)}}),this._raf=!0}calculateHeight(){let height=0;this.items.forEach(elm=>{elm.offsetHeight+elm.offsetTop>height&&(height=elm.offsetHeight+elm.offsetTop)}),this.slider.style.height=`${height}px`}}typeof customElements.get("slider-vertical")>"u"&&customElements.define("slider-vertical",SliderVertical2)} 2//# sourceMappingURL=/cdn/shop/t/1064/assets/section-slider-vertical.js.map?v=19057134119640358161780088958
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.