1if(typeof InfoTabs!="function"){class InfoTabs2 extends HTMLElement{constructor(){super(),this.tabs=this.querySelectorAll(".js-info-tab"),this.panels=this.querySelectorAll(".js-info-panel"),this.togglers=this.querySelector(".info-tabs_togglers"),this.index=0,this.timeout=null,this._timeoutInterval=parseInt(this.dataset.tabsAutoplayTimer*1e3),this.mobileNav=document.querySelectorAll(`#info-tabs-navigation-${this.dataset.id} .css-slider-dot`),this.mobileNavPrev=document.querySelector(`#info-tabs-navigation-${this.dataset.id} .css-slider-prev`),this.mobileNavNext=document.querySelector(`#info-tabs-navigation-${this.dataset.id} .css-slider-next`),this.zIndex=99,window.innerWidth<768&&(this.dataset.tabsAutoplay="false"),this.dataset.tabsAutoplay=="true"&&this.tabs.length>1&&(this.autoplay(this._timeoutInterval,!0),this.togglers.addEventListener("mouseover",()=>{this.timeout>0&&(this._timeoutRemaining=this._timeoutInterval-(new Date().getTime()-this._timeoutStart),clearTimeout(this.timeout),this.timeout=0)}),this.togglers.addEventListener("mouseleave",()=>{this.autoplay(this._timeoutRemaining,!0),this._timeoutInterval=this._timeoutRemaining})),this.index=0,this.SCROLL_EVENT=debounce(()=>{if(!this._blockScroll){const scrollItems=this.tabs.entries(),scrollArray=Array.from(scrollItems,elm=>elm[1].offsetLeft-this.togglers.scrollLeft+elm[1].offsetWidth),scrollIndex=scrollArray.reduce((bestIdx,current,idx)=>current<=window.innerWidth&&(bestIdx===-1||Math.abs(scrollArray[bestIdx]-window.innerWidth)>Math.abs(current-window.innerWidth))?idx:bestIdx,-1);scrollIndex!=this.index&&(this.index=scrollIndex,this.clickTab(this.tabs[this.index]))}},10),this.togglers.addEventListener("scroll",this.SCROLL_EVENT,{passive:!0}
1),this.tabs.forEach(tab=>{tab.addEventListener("click",e=>{e.currentTarget.classList.contains("active")||(this.clickTab(e.currentTarget),window.innerWidth<768&&this.togglers.scrollTo({left:e.currentTarget.offsetLeft-40,behavior:"smooth"}))})}),this.mobileNavPrev.addEventListener("click",()=>{this.index-1>=0&&(this.index--,this.clickTab(this.tabs[this.index]),this.togglers.scrollTo({left:this.tabs[this.index].offsetLeft-40,behavior:"smooth"}))}),this.mobileNavNext.addEventListener("click",()=>{this.index+1<this.tabs.length&&(this.index++,this.clickTab(this.tabs[this.index]),this.togglers.scrollTo({left:this.tabs[this.index].offsetLeft-40,behavior:"smooth"}))})}clickTab(tab){const panelID=tab.getAttribute("rel"),panel=document.getElementById(`panel-${panelID}`);this.reset(),this.index=parseInt(tab.dataset.index),tab.classList.add("active"),this.slideDown(tab.querySelector(".info-tabs__tab-caption"),200),panel&&(panel.classList.add("active"),panel.style.zIndex=++this.zIndex,panel.style.opacity=1),this.mobileNav.forEach((elm,index)=>{index==this.index?elm.classList.add("active"):elm.classList.remove("active")}),this.mobileNavNext.classList.remove("disabled"),this.mobileNavPrev.classList.remove("disabled"),this.index==0?this.mobileNavPrev.classList.add("disabled"):this.index+1==this.tabs.length&&this.mobileNavNext.classList.add("disabled"),this._blockScroll=!0,setTimeout(()=>{this._blockScroll=!1},500)}autoplay(delay,reset=!1){reset&&(this._timeoutStart=new Date().getTime()),this.timeout=setTimeout(()=>{this.index+1>=this.tabs.length?this.index=0:this.index++,this.tabs[this.index].click(),this._timeoutInterval=parseInt(this.dataset.tabsAutoplayTimer*1e3),this.autoplay(this._timeoutInterval,!0)},delay)}reset(){clearTimeout(this.timeout),this._timeoutInterval=parseInt(this.dataset.tabsAutoplayTimer*1e3),this._timeoutRemaining=this._timeoutInterval,this.querySelectorAll(".active").forEach(elm=>{elm.querySelector(".info-tabs__tab-caption")&&this.slideUp(elm.querySelector(".info-tabs__tab-caption"),200),elm.classList.remove("active")})}slideUp(target,duration){window.innerWidth>=768&&(target.style.transitionProperty="height, margin, padding",target.style.transitionDuration=duration+"ms",target.style.boxSizing="border-box",target.style.height=target.offsetHeight+"px",target.offsetHeight,target.style.overflow="hidden",target.style.height=0,target.style.paddingTop=0,target.style.paddingBottom=0,target.style.marginTop=0,target.style.marginBottom=0,setTimeout(()=>{target.style.display="none",target.style.removeProperty("height"),target.style.removeProperty("padding-top"),target.style.removeProperty("padding-bottom"),target.style.removeProperty("margin-top"),target.style.removeProperty("margin-bottom"),target.style.removeProperty("overflow"),target.style.removeProperty("transition-duration"),target.style.removeProperty("transition-property")},duration))}slideDown(target,duration){if(window.innerWidth>=768){target.style.removeProperty("display");var display=window.getComputedStyle(target).display;display==="none"&&(display="block"),target.style.display=display;var height=target.offsetHeight;target.style.overflow="hidden",target.style.height=0,target.style.paddingTop=0,target.style.paddingBottom=0,target.style.marginTop=0,target.style.marginBottom=0,target.offsetHeight,target.style.boxSizing="border-box",target.style.transitionProperty="height, margin, padding",target.style.transitionDuration=duration+"ms",target.style.height=height+"px",target.style.removeProperty("padding-top"),target.style.removeProperty("padding-bottom"),target.style.removeProperty("margin-top"),target.style.removeProperty("margin-bottom"),setTimeout(()=>{target.style.removeProperty("height"),target.style.removeProperty("overflow"),target.style.removeProperty("transition-duration"),target.style.removeProperty("transition-property")},duration)}}}typeof customElements.get("info-tabs")>"u"&&customElements.define("info-tabs",InfoTabs2)} 2//# sourceMappingURL=/cdn/shop/t/7/assets/section-info-tabs.js.map?v=183170073410936828151748455022
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.