function customSlickSlider(opts){const config={dom:{sliderArrow:".slick-arrow",slider:".slick-slider",sliderContainer:"slider-container",sliderTrack:".slick-track",slides:".slick-slide"},cls:{active:".slick-active",cloned:".slick-cloned",current:".slick-current",disabled:".slick-disabled",next:["next","right"],prev:["prev","left"]}},c=$.extend(config,opts),$sliders=document.querySelectorAll(c.dom.slider);function init(){$sliders?.length>0&&$sliders.forEach($slider=>{setSlideVisibility($slider),addEvents($slider)})}function addEvents(el){const $sliderParent=getParents(el)?.find($parent=>$parent.classList.contains(c.dom.sliderContainer));if(!$sliderParent)return;[...Array.from($sliderParent?.querySelectorAll(c.dom.sliderArrow))].forEach($button=>{$button.addEventListener("click",e=>{const $currentSlider=getParents(e.target)?.find($parent2=>$parent2.classList.contains(c.dom.sliderContainer))?.querySelector(c.dom.slider);$currentSlider&&setSlideVisibility($currentSlider)})})}function setSlideVisibility(el){const targets=el.querySelectorAll(c.dom.slides),options={root:null,rootMargin:"0px",threshold:.9};function callback(entries,observer2){entries.forEach(entry=>{const slide=entry.target;if(entry.isIntersecting){setAttributes(slide,{"aria-hidden":"false",tabindex:"0"});const focusableElements=slide.querySelectorAll("a, button, input, select");focusableElements.length>0&&focusableElements.forEach(focusableEl=>setAttributes(focusableEl,{"aria-hidden":"false",tabindex:"0"})),observer2.disconnect()}else{setAttributes(slide,{"aria-hidden":"true",tabindex:"-1"});const focusableElements=slide.querySelectorAll("a, button, input, select");focusableElements.length>0&&focusableElements.forEach(focusableEl=>{setAttributes(focusableEl,{"aria-hidden":"true",tabindex:"-1"})}),observer2.disconnect()}})}let observer=new IntersectionObserver(callback,options);[...targets].forEach(target=>observer.observe(target))}return init()}customSlickSlider();
//# sourceMappingURL=/cdn/shop/t/14/assets/slick-custom.js.map?v=124467254043905770051742784887
