PageSourceSearch

https://ohpolly.ae/cdn/shop/t/153/assets/product-media.js?v=156731803638416195341788940088

js ohpolly.ae collected 2026-10-06 04:20:58 UTC 3,351 bytes, 2 lines download raw bytes

1const KeenSlider=window.KeenSlider,{setInitialised,addWheelControls,useArrows}=window.BAO.Carousel.plugins;class ProductMedia extends window.BAO.CustomElement(){connectedCallback(){super.connectedCallback(),this.carousel=this.setupCarousel()}setupListeners(){super.setupListeners(),this.handleArrowClick=this.handleArrowClick.bind(this),this.els.previous?.exists&&this.listeners.add(this.els.previous.element,"click",this.handleArrowClick),this.els.next?.exists&&this.listeners.add(this.els.next.element,"click",this.handleArrowClick),this.els.video?.exists&&(this.handleVideoTrigger=this.handleVideoTrigger.bind(this),this.listeners.add(this.els.video.element,"click",this.handleVideoTrigger))}setupCarousel(){return this.onSlideChanged=this.onSlideChanged.bind(this),new KeenSlider(this.els.slides.element,{selector:this.els.slide.selector,defaultAnimation:{duration:1500},loop:!0,mode:"snap",slides:{perView:"auto",spacing:1},slideChanged:this.onSlideChanged},[setInitialised(),addWheelControls("horizontal"),useArrows({next:this.els?.next?.element,previous:this.els?.previous?.element})])}onSlideChanged(instance){const details=instance.track.details;if(this.els.index?.exists&&(this.els.index.element.innerText=details.rel+1),this.els.video?.exists){const currentSlide=instance.slides[details.rel];this.els.video.element.setAttribute("aria-hidden",currentSlide.dataset.mediaType==="video")}this.gtmTrackGalleryProgress(details)}handleArrowClick(){sessionStorage.setItem("BAO-media-gallery-arrow-click","true")}handleVideoTrigger(){this.carousel.moveToIdx(parseInt(this.els.video.element.dataset.slideIndex))}gtmTrackGalleryProgress(details){if(details.progress===0)return;const isArrowClick=sessionStorage.getItem("BAO-media-gallery-arrow-click"),eventType=isArrowClick?"arrow click":"drag",targetContext="pdp-gallery",eventProgress=this.calculateProgress(details);this.trackGalleryConversionAttribution(eventProgress),window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"carousel_engagement",event_type:eventType,event_progress:eventProgress,target_context:targetContext,target_contextSize:details.slides.length}),isArrowClick&&sessionStorage.removeItem("BAO-media-gallery-arrow-click")}calculateProgress(details){const relativeSlide=details.rel,size=details.slides.length,slidesPerView=this.getSlidesPerView(details),fullSlidesPerView=Math.floor(slidesPerView);let percentageProgress=(relativeSlide+fullSlidesPerView)/size*100;return percentageProgress=percentageProgress>100?100:percentageProgress,Math.round(percentageProgress/10)*10}getSlidesPerView(details){return details.slides.filter(slide=>slide.portion>0).length||1}trackGalleryConversionAttribution(percentageProgress){const currentValue=sessionStorage.getItem("BAO-add-to-cart-event-context"),prefix="pdp-gallery-percentage-progress";if(currentValue===`${prefix}-76-100`)return;let interactionProgress=`${prefix}-0-25`;percentageProgress>75?interactionProgress=`${prefix}-76-100`:percentageProgress>50?interactionProgress=`${prefix}-51-75`:percentageProgress>25&&(interactionProgress=`${prefix}-26-50`),sessionStorage.setItem("BAO-add-to-cart-event-context",interactionProgress)}}customElements.get("product-media")||customElements.define("product-media",ProductMedia);
2//# sourceMappingURL=/cdn/shop/t/153/assets/product-media.js.map?v=156731803638416195341788940088

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.