1const HotspotSliderTXT={"To jest pierwszy produkt":"To jest pierwszy produkt","To jest ostatni produkt":"To jest ostatni produkt","Poprzedni produkt":"Poprzedni produkt","NastÄpny produkt":"NastÄpny produkt","Idź do produktu":"Idź do produktu"};class HotspotSlider{constructor({selector:t="",options:e={},hotspotName:s="",callbackBefore:i=t=>{},callbackAfter:o=t=>{}}={}){this.hotspotName=s,this.selector=t,this.options=e,this.slider=null,this.txt={...HotspotSliderTXT},this.settings={loop:!1,slidesPerView:1.4,spaceBetween:app_shop?.vars?.customSliderConfig?.hotspots?.gap??16,centeredSlides:!0,centeredSlidesBounds:!0,watchSlidesProgress:!0,autoHeight:!1,navigation:{nextEl:`#${this.hotspotName} .swiper-button-next`,prevEl:`#${this.hotspotName} .swiper-button-prev`},pagination:!1,breakpoints:{550:{slidesPerView:1.8,centeredSlides:!0,centeredSlidesBounds:!0,autoHeight:!0},757:{slidesPerView:3,centeredSlides:!1,centeredSlidesBounds:!1,autoHeight:!0,loop:!0},979:{slidesPerView:4,centeredSlides:!1,centeredSlidesBounds:!1,autoHeight:!0,loop:!0},1100:{slidesPerView:5,centeredSlides:!1,centeredSlidesBounds:!1,autoHeight:!0,loop:!0}},...e},this.accessibilityOptions={firstSlideMessage:this.txt["To jest pierwszy produkt"],lastSlideMessage:this.txt["To jest ostatni produkt"],prevSlideMessage:this.txt["Poprzedni produkt"],nextSlideMessage:this.txt["NastÄpny produkt"],paginationBulletMessage:`${this.txt["Idź do produktu"]} {{index}}`},this.callbackBefore=i,this.callbackAfter=o}
1async init(){const{Slider:t,SliderThumbnails:e}=await appModules.load("Slider");if(!t||!e)return void app_shop.vars.utils.debug("HotspotSlider","(async) init","Pobierane moduÅy [Slider, SliderThumbnails] nie istniejÄ
");const s=document.querySelector(this.selector);if(!s)return void app_shop.vars.utils.debug("HotspotSlider","(async) init",`Wskazany element hotspota nie istnieje. Wybrany selektor: ${this.selector}`,s);this.slider=new t,"function"==typeof this.callbackBefore&&this.callbackBefore(this.slider);if(!await this.slider.init({options:this.settings}))return void app_shop.vars.utils.debug("HotspotSlider","(async) init","Nie udaÅo siÄ zainicjalizowaÄ slidera.",this.slider);await this.slider.enableA11y(this.accessibilityOptions),this.attachListeners(s);await this.slider.setupSlider({element:s,customName:this.hotspotName})?(this.disableArrowsTabIndex(),this.setArrowsHeight(s,this.slider.slider),this.setHotspotClass(s),"function"==typeof this.callbackAfter&&this.callbackAfter(this.slider)):app_shop.vars.utils.debug("HotspotSlider","(async) init","Nie udaÅo siÄ zainstalowaÄ slidera na stronie.",this.slider)}getElementSizes(t){const e=window.getComputedStyle(t),s=parseFloat(e.marginTop)||0,i=parseFloat(e.marginBottom)||0;return{marginTop:s,marginBottom:i,paddingTop:parseFloat(e.paddingTop)||0,paddingBottom:parseFloat(e.paddingBottom)||0,computedHeight:t.offsetHeight+s+i}}setHotspotClass(t){const e=t.closest(".hotspot");e&&e.classList.add("--initialized")}setArrowsHeight(t,e){const s=t?.closest(".hotspot");if(!s||s?.classList?.contains("--slider_gallery"))return;if(!Array.isArray(e.visibleSlides))return;const i=s.querySelector(".hotspot__name"),o=i?this.getElementSizes(i).computedHeight:0,r=t.closest(".hotspot__wrapper"),{marginTop:a=0,paddingTop:d=0}=r?this.getElementSizes(r):{},l=a+d,n=e.visibleSlides.map((t=>{const e=t.querySelector(".product__icon"),s=this.getElementSizes(e).computedHeight||e.height;return Number.isNaN(s)?0:s})),p=Math.max(...n);0!==p&&s?.style.setProperty("--arrows-height",`calc(${l}px + ${o}px + ((${p}px - var(--swiper-navigation-size, 40px)) / 2))`)}attachListeners(t){this.slider.watchEvent("resize",(e=>{this.setArrowsHeight(t,e)})),this.slider.watchEvent("fromEdge toEdge afterInit lock unlock",(()=>{this.disableArrowsTabIndex()})),this.slider.watchEvent("breakpoint",(async t=>{t.initialized&&await this.reset(!1,!0)}))}disableArrowsTabIndex(){this.settings.loop||this.settings.rewind||(this.slider?.slider?.navigation?.prevEl?.setAttribute?.("tabindex",-1),this.slider?.slider?.navigation?.nextEl?.setAttribute?.("tabindex",-1))}async reset(t=!0,e=!1){this.slider&&this.slider.slider.destroy(t,e),await this.init()}destroy(){this.slider&&this.slider.slider.destroy(!0,!0)}}class HotspotSetSliderPlugin extends GetHotspots{async initSlider(t){const e=`#${this.hotspotElement?.id||"hotspotSlider"}`,s=this.productsMinHeight;app_shop.vars.hotspotSliders=app_shop.vars.hotspotSliders??{},app_shop.vars.hotspotSliders[e]=new HotspotSlider({selector:`#${this.hotspotElement?.id||""} .hotspot .swiper`,hotspotName:this.hotspotElement?.id||"custom",options:t??{},callbackAfter:t=>{s&&app_shop.fn?.setHeight({selectors:[`#${this.hotspotElement?.id} .product__prices`,`#${this.hotspotElement?.id} .product__name`,`#${this.hotspotElement?.id} .product__opinion`],container:`#${this.hotspotElement?.id} .products`})}}),await app_shop.vars.hotspotSliders[e].init(),app_shop.fn.projectorTabs&&app_shop.fn.projectorTabs.init()}async init(t){const[e,s,i]=t;this.hotspotData=e,this.hotspotTemplate=s,this.hotspotElement=i,this.sliderGalleryOptions={loop:!0,navigation:{nextEl:`#${this.hotspotElement?.id||"custom"} .hotspot__arrow.--next`,prevEl:`#${this.hotspotElement?.id||"custom"} .hotspot__arrow.--prev`},slidesPerView:1.4,slidesPerGroup:1,centeredSlides:!0,centeredSlidesBounds:!0,breakpoints:{550:{slidesPerView:2},757:{slidesPerView:3,centeredSlides:!1,centeredSlidesBounds:!1},979:{slidesPerView:4,centeredSlides:!1,centeredSlidesBounds:!1},1200:{slidesPerView:6,centeredSlides:!1,centeredSlidesBounds:!1}}};const o=i.querySelector(".--slider");if(!o||"function"!=typeof HotspotSlider||this.hotspotData.products.length<1)return!1;o&&i.querySelector(".hotspot")?.classList?.add?.("--slider_fashion"),i?.removeChild(o);const r=document.querySelector(`#${this.hotspotElement?.id} .hotspot.--slider_gallery`)?this.sliderGalleryOptions:{};return await this.initSlider(r),!0}}app_shop.vars.hotspotCallbacksAfterAppend.slider=async(...t)=>{const e=new HotspotSetSliderPlugin;await e.init(t)};
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.