document.addEventListener("shopify:block:select",function(event){var sectionId="section-"+event.detail.sectionId,blockId=event.detail.blockId,section=document.getElementById(sectionId);section&§ion.classList.contains("socioh-collection-slider")&&document.getElementsByClassName("js-block-"+blockId).click()}),document.addEventListener("shopify:section:load",function(event){var sectionId="section-"+event.detail.sectionId,section=document.getElementById(sectionId);section&§ion.classList.contains("socioh-countdown-timer")&&sohCountdown.load(sectionId),section&§ion.classList.contains("socioh-sale-banner")&&updateSociohSaleBannersVisibility()});var sohCountdown={timers:{},load:function(sectionId){sohCountdown.timers[sectionId]||(sohCountdown.timers[sectionId]={sectionId}),sohCountdown.initializeTimer(sectionId)},initializeTimer:function(sectionId){var timer=sohCountdown.timers[sectionId];timer.rootElement=document.getElementById(timer.sectionId),timer.daysElement=timer.rootElement.getElementsByClassName("js-soh-countdown-days")[0],timer.hoursElement=timer.rootElement.getElementsByClassName("js-soh-countdown-hours")[0],timer.minutesElement=timer.rootElement.getElementsByClassName("js-soh-countdown-minutes")[0],timer.secondsElement=timer.rootElement.getElementsByClassName("js-soh-countdown-seconds")[0],timer.timerElement=timer.rootElement.getElementsByClassName("js-soh-countdown")[0],timer.daysPluralElement=timer.rootElement.getElementsByClassName("js-soh-countdown-days-plural")[0],timer.hoursPluralElement=timer.rootElement.getElementsByClassName("js-soh-countdown-hours-plural")[0],timer.minutesPluralElement=timer.rootElement.getElementsByClassName("js-soh-countdown-minutes-plural")[0],timer.secondsPluralElement=timer.rootElement.getElementsByClassName("js-soh-countdown-seconds-plural")[0],timer.settings=JSON.parse(timer.rootElement.getElementsByClassName("js-soh-countdown-settings")[0].innerHTML),timer.settings.timezone="-04:00",timer.settings.after_completion=="hide_section"?(timer.hideSection=!0,timer.hideTimer=!1):timer.settings.after_completion=="hide_timer"?(timer.hideTimer=!0,timer.hideSection=!1):(timer.hideTimer=!1,timer.hideSection=!1),timer.dateFuture=new Date(timer.settings.date+"T"+timer.settings.time+":00.000"+timer.settings.timezone),timer.interval&&clearInterval(timer.interval),sohCountdown.updateTime(timer),timer.interval=setInterval(function(){sohCountdown.updateTime(timer)},1e3)},updateTime:function(timer){timer.dateNow=new Date,timer.dateFuture-timer.dateNow<=0?(clearInterval(timer.interval),timer.daysElement.innerHTML="0",timer.hoursElement.innerHTML="0",timer.minutesElement.innerHTML="0",timer.secondsElement.innerHTML="0",timer.hideSection&&timer.rootElement.classList.add("soh-hide-section"),timer.hideTimer&&timer.timerElement.classList.add("soh-hide-timer")):(timer.seconds=Math.floor((timer.dateFuture-timer.dateNow)/1e3),timer.minutes=Math.floor(timer.seconds/60),timer.hours=Math.floor(timer.minutes/60),timer.days=Math.floor(timer.hours/24),timer.hours=timer.hours-timer.days*24,timer.minutes=timer.minutes-timer.days*24*60-timer.hours*60,timer.seconds=timer.seconds-timer.days*24*60*60-timer.hours*60*60-timer.minutes*60,timer.days==1?timer.daysPluralElement.classList.add("hide-plural"):timer.daysPluralElement.classList.remove("hide-plural"),timer.hours==1?timer.hoursPluralElement.classList.add("hide-plural"):timer.hoursPluralElement.classList.remove("hide-plural"),timer.minutes==1?timer.minutesPluralElement.classList.add("hide-plural"):timer.minutesPluralElement.classList.remove("hide-plural"),timer.seconds==1?timer.secondsPluralElement.classList.add("hide-plural"):timer.secondsPluralElement.classList.remove("hide-plural"),timer.daysElement.innerHTML=timer.days,timer.hoursElement.innerHTML=timer.hours,timer.minutesElement.innerHTML=timer.minutes,timer.secondsElement.innerHTML=timer.seconds)},initialize:function(){for(var timers=document.getElementsByClassName("socioh-countdown-timer"),i=0;idateEnd&&(toHide=!0)}toHide?banner.rootElement.classList.add("hide-banner"):banner.rootElement.classList.remove("hide-banner")}banners.length>0&&setTimeout(updateSociohSaleBannersVisibility,1e3)},updateSociohAnnouncementBannersVisibility=function(){for(var banners=document.getElementsByClassName("AnnouncementBar"),i=0;idateEnd&&(toShow=!1)}toShow?banner.rootElement.classList.add("show"):banner.rootElement.classList.remove("show")}banners.length>0&&setTimeout(updateSociohAnnouncementBannersVisibility,1e3)};document.addEventListener("DOMContentLoaded",function(){document.getElementById("section-announcement")&&updateSociohAnnouncementBannersVisibility()});var sohCollectionSlider={sliders:{},initialize:function(){for(var sliders=document.getElementsByClassName("socioh-collection-slider"),i=0;isohCollectionSlider.touchstartX&&sohCollectionSlider.slide(event,1)},selectTab:function(event){for(var sectionId=event.target.closest(".socioh-collection-slider").id,slider=sohCollectionSlider.sliders[sectionId],tab=event.target,tabIndex=-1,i=0;i=0;i--)if(slides[i].offsetLeftcontentLeft){contentLeft=slides[i].offsetLeft;break}activeProductSet.style.left=-1*contentLeft+"px",setTimeout(function(){sohCollectionSlider.updateArrowStatus(slider)},350)},updateArrowStatus:function(slider){var activeProductSet=slider.rootElement.getElementsByClassName("is-active")[0],contentLeft=Math.abs(activeProductSet.offsetLeft);contentLeft==0?slider.rootElement.getElementsByClassName("js-arrow-left")[0].classList.add("is-disabled"):slider.rootElement.getElementsByClassName("js-arrow-left")[0].classList.remove("is-disabled"),slider.contentContainer.offsetWidth+contentLeft>=activeProductSet.offsetWidth?slider.rootElement.getElementsByClassName("js-arrow-right")[0].classList.add("is-disabled"):slider.rootElement.getElementsByClassName("js-arrow-right")[0].classList.remove("is-disabled")}};sohCollectionSlider.initialize(); //# sourceMappingURL=/cdn/shop/t/153/assets/custom.js.map?v=117943525599920767941746656774