1const{Core,Utils,onBlazeLoad}=Global,{$hide,$replaceContent,$toggleDisplay}=Utils,ACTIVE_CLASSNAME="blaze-active";function _activeToggle(state){const action=state?"add":"remove";return el=>{el.classList[action](ACTIVE_CLASSNAME)}}customElements.define("slideshow-inline-blaze",class extends Core{elements={$:["blaze","slides-wrapper",["nav"]]};propTypes={gap:String,"slides-per-view":Number,"slides-per-view-mobile":Number,"slide-by-row":Boolean,"swipe-on-desktop":Boolean,"track-active":Boolean,inert:Boolean};render(){this.prop("inert")||onBlazeLoad(this._initBlaze.bind(this))}destroy(){this.slider&&this.slider.destroy()}replaceSlides(slides){this.$("slides-wrapper").replaceChildren(...slides),this.reset()}reset(){this.slider||(this.removeAttribute("inert"),this._initBlaze()),this.slider.totalSlides=this.slider.slides.length,this.slider.refresh(),this._toggleNavigation()}_initBlaze(){window.BlazeSlider&&(this.slider=new window.BlazeSlider(this.$("blaze"),{all:{slideGap:this.prop("gap"),loop:!1,slidesToShow:this.prop("slides-per-view"),slidesToScroll:this.prop("slide-by-row")?this.prop("slides-per-view"):1,draggable:this.prop("swipe-on-desktop")},"(max-width: 992px)":{slidesToShow:this.prop("slides-per-view-mobile"),slidesToScroll:1,draggable:!0}}),this.prop("track-active")&&this._handleActiveSlides(),this._toggleNavigation())}_handleActiveSlides(){this.$slides=Array.from(this.slider.slides),this._setInitialActiveSlides(),this.slider.onSlide(this._updateActiveSlides.bind(this))}_setInitialActiveSlides(){const[start,end]=this.slider.states[0].page;this.activeSlides=this._findSlidesInRange(start,end),this._toggleActiveSlides(!0)}_toggleActiveSlides(state){this.activeSlides.map(_activeToggle(state))}_findSlidesInRange(start,end){return this.$slides.filter((_,i)=>start<=i&&end>=i)}_updateActiveSlides(_,start,end){this._toggleActiveSlides(!1),this.activeSlides=this._findSlidesInRange(start,end),this._toggleActiveSlides(!0)}_toggleNavigation(){this.$("nav")?.map(item=>$toggleDisplay(item,this.hasOffset))}get hasOffset(){return this.slider.totalSlides>this.prop("slides-per-view")}}); 2//# sourceMappingURL=/cdn/shop/t/17/assets/slideshow-inline-blaze.js.map?v=62851275585444898601757441298
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.