1class CartDrawer extends DrawerComponent{constructor(){super(),window.FoxKitSections=FoxTheme.utils.getSectionId(this),this.onCartRefreshListener=this.onCartRefresh.bind(this),this.getSectionToRenderListener=this.getSectionToRender.bind(this)}get requiresBodyAppended(){return!1}get sectionId(){return this.getAttribute("data-section-id")}connectedCallback(){super.connectedCallback(),document.addEventListener("cart:grouped-sections",this.getSectionToRenderListener),document.addEventListener("cart:refresh",this.onCartRefreshListener)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("cart:grouped-sections",this.getSectionToRenderListener),document.removeEventListener("cart:refresh",this.onCartRefreshListener)}getSectionToRender(event){event.detail.sections.push(FoxTheme.utils.getSectionId(this))}show(focusElement=null,animate=!0){super.show(focusElement,animate),this.open&&!Shopify.designMode&&FoxTheme.a11y.trapFocus(this,this.focusElement)}async onCartRefresh(event){try{const[htmlResponse,cartResponse]=await Promise.all([fetch(`${FoxTheme.routes.root_url}?section_id=${this.sectionId}`),fetch(`${FoxTheme.routes.cart_url}.js`)]);if(!htmlResponse.ok||!cartResponse.ok)throw new Error("Failed to fetch cart data");const[responseText,cartData]=await Promise.all([htmlResponse.text(),cartResponse.json()]),sectionToRender=new DOMParser().parseFromString(responseText,"text/html").getElementById(`CartDrawer-${this.sectionId}`);if(!sectionToRender){console.warn("Cart drawer section not found in response");return}cartData.sections={},cartData.sections[this.sectionId]=sectionToRender.innerHTML,FoxTheme.pubsub.publish(FoxTheme.pubsub.PUB_SUB_EVENTS.cartUpdate,{cart:cartData}),event.detail&&event.detail.open===!0&&this.show()}catch(error){console.error("Error refreshing cart:",error)}}}customElements.define("cart-drawer",CartDrawer);class CartAddonModal extends ModalComponent{constructor(){super()}get focusElement(){return this.querySelector("input, textarea, select")||this.querySelector("button")}}customElements.define("cart-addon-modal",CartAddonModal);class CartItems extends HTMLElement{constructor(){super(),this.addEventListener("change",event=>{const target=event.target;target&&target.closest("quantity-input")&&FoxTheme.utils.debounce(this.onChange(event),300)}),this.cartUpdateUnsubscriber=FoxTheme.pubsub.subscribe(FoxTheme.pubsub.PUB_SUB_EVENTS.cartUpdate,this.onCartUpdate.bind(this)),this.cartItemProducts=this.querySelectorAll(".cart-item__product"),this.cartItemQuantitys=this.querySelectorAll(".cart-item__quantity");const loadTemplateContent=(elements,parentSelector)=>{elements.forEach(element=>{const template=element.querySelector("template"),templateContent=template&&document.importNode(template.content,!0),parent=element.querySelector(parentSelector);if(parent&&template&&!parent.querySelector(".template-content")){const contentWrapper=document.createElement("div");contentWrapper.classList.add("template-content"),contentWrapper.appendChild(templateContent),parent.appendChild(contentWrapper)}})},removeTemplateContent=(elements,parentSelector)=>{elements.forEach(element=>{const parent=element.querySelector(parentSelector),templateContent=parent?.querySelector(".template-content");templateContent&&parent.removeChild(templateContent)})},handleTabletMatch=()=>{loadTemplateContent(this.cartItemProducts,".cart-item__product--info"),removeTemplateContent(this.cartItemQuantitys,".cart-item__quantity-wrapper")},handleTabletUnmatch=()=>{removeTemplateContent(this.cartItemProducts,".cart-item__product--info"),loadTemplateContent(this.cartItemQuantitys,".cart-item__quantity-wrapper")},mqlTablet=window.matchMedia(FoxTheme.config.mediaQueryTablet);FoxTheme.config.mqlTablet=mqlTablet.matches,FoxTheme.config.mqlTablet?handleTabletMatch():handleTabletUnmatch(),mqlTablet.onchange=event=>{event.matches?handleTabletMatch():(FoxTheme.config.mqlTablet=!1,handleTabletUnmatch())},window.FoxKitSections=FoxTheme.utils.getSectionId(this)}cartUpdateUnsubscriber=void 0;disconnectedCallback(){this.cartUpdateUnsubscriber&&this.cartUpdateUnsubscriber()}onChange(event){this.updateQuantity(event.target.dataset.index,event.target.value,document.activeElement.getAttribute("name"),event.target)}onCartError(errors,target){if(target){this.hideLoader(target.getAttribute("data-index")),this.setValidity(target,errors);return}else window.location.href=FoxTheme.routes.cart_url;alert(errors)}setValidity(target,message){target.setCustomValidity(message),target.reportValidity(),target.value=target.defaultValue,target.select()}onCartUpdate(event){if(event.cart.errors){this.onCartError(event.cart.errors,event.target);return}if(typeof event.cart.sections>"u")return;const sectionId=FoxTheme.utils.getSectionId(this),sectionToRender=new DOMParser().parseFromString(event.cart.sections[sectionId],"text/html"),cartDrawer=document.querySelector(`#CartDrawer-${sectionId}`),cartDrawerBody=document.querySelector(`#CartDrawerBody-${sectionId}`),cartDrawerFooter=document.querySelector(`#CartDrawerFooter-${sectionId}`),cartDrawerEmpty=document.querySelector(`#CartDrawerEmpty-${sectionId}`);if(cartDrawer){const cartDrawerBodyUpdate=sectionToRender.querySelector(`#CartDrawerBody-${sectionId}`),cartDrawerFooterUpdate=sectionToRender.querySelector(`#CartDrawerFooter-${sectionId}`),cartDrawerEmptyUpdate=sectionToRender.querySelector(`#CartDrawerEmpty-${sectionId}`);cartDrawerBodyUpdate&&(cartDrawerBody.innerHTML=cartDrawerBodyUpdate.innerHTML),cartDrawerFooterUpdate&&(cartDrawerFooter.innerHTML=cartDrawerFooterUpdate.innerHTML),cartDrawerEmptyUpdate&&(cartDrawerEmpty.innerHTML=cartDrawerEmptyUpdate.innerHTML),event.cart.item_count>0?(cartDrawerBody.classList.remove("hidden"),cartDrawerFooter.classList.remove("hidden"),cartDrawerEmpty.classList.add("hidden")):(cartDrawerBody.classList.add("hidden"),cartDrawerFooter.classList.add("hidden"),cartDrawerEmpty.classList.remove("hidden"))}const mainCart=document.querySelector(`#MainCart-${sectionId}`);if(mainCart){const updatedElement=sectionToRender.querySelector(`#MainCart-${sectionId}`);updatedElement?(mainCart.innerHTML=updatedElement.innerHTML,event.cart.item_count>0?mainCart.closest(".cart").classList.remove("is-empty"):mainCart.closest(".cart").classList.add("is-empty")):(mainCart.closest(".cart").classList.add("is-empty"),mainCart.remove())}const lineItem=document.getElementById(`CartItem-${event.line}`)||document.getElementById(`CartDrawer-Item-${event.line}`);lineItem&&lineItem.querySelector(`[name="${event.name}"]`)?FoxTheme.a11y.trapFocus(mainCart||cartDrawer,lineItem.querySelector(`[name="${event.name}"]`)):event.cart.item_count===0?cartDrawer?FoxTheme.a11y.trapFocus(cartDrawer,cartDrawer.querySelector("a")):FoxTheme.a11y.trapFocus(document.querySelector(".cart__empty"),document.querySelector("a")):cartDrawer?FoxTheme.a11y.trapFocus(cartDrawer,cartDrawer.querySelector(".cart-item__title")):FoxTheme.a11y.trapFocus(mainCart,mainCart.querySelector(".cart-item__title")),document.dispatchEvent(new CustomEvent("cart:updated",{detail:{cart:event.cart}}))}updateQuantity(line,quantity,name,target){this.showLoader(line);let sectionsToBundle=[];document.documentElement.dispatchEvent(new CustomEvent("cart:grouped-sections",{bubbles:!0,detail:{sections:sectionsToBundle}}));const body=JSON.stringify({line,quantity,sections:sectionsToBundle});
1fetch(`${FoxTheme.routes.cart_change_url}`,{...FoxTheme.utils.fetchConfig(),body}).then(response=>response.json()).then(parsedState=>{FoxTheme.pubsub.publish(FoxTheme.pubsub.PUB_SUB_EVENTS.cartUpdate,{cart:parsedState,target,line,name})}).catch(error=>{console.log(error)})}showLoader(line){const sectionId=FoxTheme.utils.getSectionId(this),loaders=document.querySelectorAll(`#Loader-${sectionId}-${line}`);loaders&&loaders.forEach(loader=>{loader.classList.add("btn--loading")})}hideLoader(line){const sectionId=FoxTheme.utils.getSectionId(this),loaders=document.querySelectorAll(`#Loader-${sectionId}-${line}`);loaders&&loaders.forEach(loader=>{loader.classList.remove("btn--loading")})}}customElements.define("cart-items",CartItems);class CartRemoveItem extends HTMLAnchorElement{constructor(){super(),this.addEventListener("click",event=>{event.preventDefault(),this.closest("cart-items").updateQuantity(this.dataset.index,0)})}}customElements.define("cart-remove-item",CartRemoveItem,{extends:"a"});class CartNote extends HTMLElement{constructor(){super(),this.addEventListener("change",FoxTheme.utils.debounce(this.onChange.bind(this),300)),this.button&&this.cartNoteDetailsSummary&&this.button.addEventListener("click",()=>{this.cartNoteDetailsSummary.close()})}get cartNoteDetailsSummary(){return this.closest('[is="accordion-details"]')}get button(){return this.querySelector('[type="button"]')}onChange(event){const body=JSON.stringify({note:event.target.value});fetch(`${FoxTheme.routes.cart_update_url}`,{...FoxTheme.utils.fetchConfig(),body})}}customElements.define("cart-note",CartNote);class CartDiscount extends HTMLFormElement{constructor(){super(),this.addEventListener("submit",this.handleFormSubmit.bind(this))}get submitEl(){return this._submitEl=this._submitEl||this.querySelector('[type="submit"]')}get messageEl(){return this._messageEl=this._messageEl||this.querySelector(".form__message")}get couponEl(){return this._couponEl=this._couponEl||this.querySelector('input[name="discount"]')}get cartAddonDrawer(){return this.closest(".cart-addons-drawer")}get cartDiscountsEl(){return document.querySelector(".cart__discounts")}getDiscounts(){const discounts=[];if(this.cartDiscountsEl){const items=this.cartDiscountsEl.querySelectorAll(".discount");items&&items.forEach(item=>{discounts.push(item.dataset.discountCode)})}return discounts}handleFormSubmit(event){if(event.preventDefault(),this.submitEl.getAttribute("aria-disabled")==="true")return;this.displayFormErrors();const newDiscountCode=this.couponEl.value,discounts=this.getDiscounts();if(discounts.includes(newDiscountCode)){this.displayFormErrors(FoxTheme.cartStrings.duplicateDiscountError);return}discounts.push(newDiscountCode);let sectionsToBundle=[];document.documentElement.dispatchEvent(new CustomEvent("cart:grouped-sections",{bubbles:!0,detail:{sections:sectionsToBundle}}));const config=FoxTheme.utils.fetchConfig("javascript");config.headers["X-Requested-With"]="XMLHttpRequest",delete config.headers["Content-Type"];const formData=new FormData;formData.append("sections",sectionsToBundle),formData.append("sections_url",window.location.pathname),formData.append("discount",discounts.join(",")),config.body=formData,this.submitEl.setAttribute("aria-disabled","true"),this.submitEl.classList.add("btn--loading"),fetch(FoxTheme.routes.cart_update_url,config).then(response=>response.json()).then(async parsedState=>{if(parsedState.discount_codes.find(discount=>discount.code===newDiscountCode&&discount.applicable===!1)){this.couponEl.value="",this.displayFormErrors(FoxTheme.cartStrings.applyDiscountError);return}this.cartAddonDrawer&&this.cartAddonDrawer.hide();const cartJson=await(await fetch(`${FoxTheme.routes.cart_url}`,{...FoxTheme.utils.fetchConfig()})).json();cartJson.sections=parsedState.sections,this.updateCartState(cartJson)}).catch(e=>{console.error(e)}).finally(()=>{this.submitEl.removeAttribute("aria-disabled"),this.submitEl.classList.remove("btn--loading")})}updateCartState=cartJson=>{FoxTheme.pubsub.publish(FoxTheme.pubsub.PUB_SUB_EVENTS.cartUpdate,{cart:cartJson})};displayFormErrors=(errorMessage=!1)=>{this.messageEl?(this.messageEl.classList.toggle("!hidden",!errorMessage),errorMessage!==!1&&(this.messageEl.innerText=errorMessage)):errorMessage!==!1&&alert(errorMessage)}}customElements.define("cart-discount",CartDiscount,{extends:"form"});class CartDiscountRemove extends HTMLButtonElement{constructor(){super(),this.selectors={list:".cart__discounts",item:".discount"},this.clickHandler=this.handleClick.bind(this)}connectedCallback(){this.listEl=this.closest(this.selectors.list),this.addEventListener("click",this.clickHandler)}disconnectedCallback(){this.removeEventListener("click",this.clickHandler)}handleClick(event){if(event.preventDefault(),this.getAttribute("aria-disabled")==="true")return;this.setAttribute("aria-disabled","true"),this.classList.add("btn--loading"),this.discounts=[];const thisItem=this.closest("li"),items=this.listEl.querySelectorAll(this.selectors.item);
1items&&items.forEach(item=>{item!=thisItem&&this.discounts.push(item.dataset.discountCode)}),this.updateCartDiscounts()}updateCartDiscounts(){let sectionsToBundle=[];document.documentElement.dispatchEvent(new CustomEvent("cart:grouped-sections",{bubbles:!0,detail:{sections:sectionsToBundle}}));const config=FoxTheme.utils.fetchConfig("javascript");config.headers["X-Requested-With"]="XMLHttpRequest",delete config.headers["Content-Type"];const formData=new FormData;formData.append("sections",sectionsToBundle),formData.append("sections_url",window.location.pathname),formData.append("discount",this.discounts.join(",")),config.body=formData,fetch(FoxTheme.routes.cart_update_url,config).then(response=>response.json()).then(async parsedState=>{const cartJson=await(await fetch(`${FoxTheme.routes.cart_url}`,{...FoxTheme.utils.fetchConfig()})).json();cartJson.sections=parsedState.sections,this.updateCartState(cartJson)}).catch(e=>{console.error(e)})}updateCartState=cartJson=>{FoxTheme.pubsub.publish(FoxTheme.pubsub.PUB_SUB_EVENTS.cartUpdate,{cart:cartJson})}}customElements.define("cart-discount-remove",CartDiscountRemove,{extends:"button"});class CalculateShipping extends CartAddonModal{constructor(){super(),this.countryProvince=this.querySelector("country-province"),this.isCountrySetup=!1}static get observedAttributes(){return[...super.observedAttributes,"data-show"]}show(){super.show(),this.setAttribute("data-show",!0)}hide(){super.hide(),this.setAttribute("data-show",!1)}attributeChangedCallback(name,oldValue,newValue){if(super.attributeChangedCallback(name,oldValue,newValue),name==="data-show"&&newValue==="true"&&!this.isCountrySetup&&this.countryProvince){const template=this.countryProvince.querySelector("template"),templateContent=document.importNode(template.content,!0);this.countryProvince.countryElement.appendChild(templateContent),this.countryProvince.init(),this.isCountrySetup=!0}}}customElements.define("calculate-shipping",CalculateShipping);class CountryProvinceForm extends HTMLElement{constructor(){super(),this.provinceElement=this.querySelector('[name="address[province]"]'),this.countryElement=this.querySelector('[name="address[country]"]'),this.template=this.dataset.template,this.countryElement.addEventListener("change",this.handleCountryChange.bind(this)),this.template&&this.template==="cart"&&this.init()}init(){this.getAttribute("country")!==""?(this.countryElement.selectedIndex=Math.max(0,Array.from(this.countryElement.options).findIndex(option=>option.textContent===this.dataset.country)),this.countryElement.dispatchEvent(new Event("change"))):this.handleCountryChange()}handleCountryChange(){const option=this.countryElement.options[this.countryElement.selectedIndex],provinces=JSON.parse(option.dataset.provinces);this.provinceElement.closest(".form-field").hidden=provinces.length===0,provinces.length!==0&&(this.provinceElement.innerHTML="",provinces.forEach(data=>{const selected=data[1]===this.dataset.province;this.provinceElement.options.add(new Option(data[1],data[0],selected,selected))}))}}customElements.define("country-province",CountryProvinceForm);class ShippingCalculator extends HTMLFormElement{constructor(){super(),this.submitButton=this.querySelector('[type="submit"]'),this.resultsElement=this.lastElementChild,this.submitButton.addEventListener("click",this.handleFormSubmit.bind(this))}handleFormSubmit(event){event.preventDefault();const zip=this.querySelector('[name="address[zip]"]').value,country=this.querySelector('[name="address[country]"]').value,province=this.querySelector('[name="address[province]"]').value;this.submitButton.classList.add("btn--loading");const body=JSON.stringify({shipping_address:{zip,country,province}});let sectionUrl=`${FoxTheme.routes.cart_url}/shipping_rates.json`;sectionUrl=sectionUrl.replace("//","/"),fetch(sectionUrl,{...FoxTheme.utils.fetchConfig("javascript"),body}).then(response=>response.json()).then(parsedState=>{parsedState.shipping_rates?this.formatShippingRates(parsedState.shipping_rates):this.formatError(parsedState)}).catch(e=>{console.error(e)}).finally(()=>{this.resultsElement.hidden=!1,this.submitButton.classList.remove("btn--loading")})}formatError(errors){const shippingRatesList=Object.keys(errors).map(errorKe
1y=>`<li>${errors[errorKey]}</li>`);this.resultsElement.innerHTML=` 2 <div class="alert alert--error blocks-radius grid gap-2"> 3 <p class="font-body-bolder m-0">${FoxTheme.shippingCalculatorStrings.error}</p> 4 <ul class="list-disc grid gap-1 text-sm" role="list">${shippingRatesList.join("")}</ul> 5 </div> 6 `}formatShippingRates(shippingRates){const shippingRatesList=shippingRates.map(({presentment_name,currency,price})=>`<li>${presentment_name}: ${currency} ${price}</li>`);this.resultsElement.innerHTML=` 7 <div class="alert blocks-radius alert--${shippingRates.length===0?"error":"success"} grid gap-2 leading-tight"> 8 <p class="font-body-bolder m-0">${shippingRates.length===0?FoxTheme.shippingCalculatorStrings.notFound:shippingRates.length===1?FoxTheme.shippingCalculatorStrings.oneResult:FoxTheme.shippingCalculatorStrings.multipleResults}</p> 9 ${shippingRatesList===""?"":`<ul class="list-disc grid gap-1 text-sm" role="list">${shippingRatesList.join("")}</ul>`} 10 </div> 11 `}}customElements.define("shipping-calculator",ShippingCalculator,{extends:"form"});class CartDrawerProductsRecommendation extends HTMLElement{constructor(){super(),this.carousel=!1,this.isLoading=!1,this.classes={grid:"f-grid",swiper:"swiper",swiperWrapper:"swiper-wrapper",loading:"is-loading"},navigator.userAgent.includes("Safari")&&!navigator.userAgent.includes("Chrome")?this.init():FoxTheme.Motion.inView(this,this.init.bind(this),{margin:"600px 0px 600px 0px"})}disconnectedCallback(){this.destroyCarousel(),window.matchMedia(FoxTheme.config.mediaQueryMobile).removeEventListener("change",this.handleCarousel.bind(this))}init(){this.isLoading||!this.dataset.url||(this.isLoading=!0,this.classList.add(this.classes.loading),fetch(this.dataset.url).then(response=>{if(!response.ok)throw new Error("Network response was not ok");return response.text()}).then(responseText=>{const sectionInnerHTML=new DOMParser().parseFromString(responseText,"text/html").querySelector(".shopify-section");if(!sectionInnerHTML)return;const recommendations=sectionInnerHTML.querySelector("cart-drawer-products-recommendation");recommendations?.innerHTML.trim().length?(this.innerHTML=recommendations.innerHTML,window.matchMedia(FoxTheme.config.mediaQueryMobile).addEventListener("change",this.handleCarousel.bind(this)),this.handleCarousel(),this.dispatchEvent(new CustomEvent("recommendations:loaded"))):this.closest(".shopify-section")?.remove()}).catch(error=>{console.error("Error loading recommendations:",error),this.classList.add("has-error")}).finally(()=>{this.isLoading=!1,this.classList.remove(this.classes.loading)}))}initCarousel(){if(!this.wrapper?.innerHTML.trim().length){this.classList.add("hidden");return}if(typeof this.carousel!="object")try{this.container.classList.add(this.classes.swiper),this.wrapper.classList.remove(this.classes.grid),this.wrapper.classList.add(this.classes.swiperWrapper);let options={slidesPerView:this.columns,spaceBetween:8,loop:!1,navigation:{nextEl:this.sliderNext,prevEl:this.sliderPrev}};const paginationEl=this.querySelector(".swiper-pagination");paginationEl&&(options={...options,pagination:{el:paginationEl,clickable:!0,type:"fraction"}}),this.carousel=new FoxTheme.Carousel(this.slideContainer,options),this.carousel&&(this.carousel.init(),this.calcNavButtonsPosition())}catch(error){console.error("Error initializing carousel:",error),this.destroyCarousel()}}handleCarousel(){const containerEl=this.container;this.columns=containerEl.dataset.columns,this.enableSliderMobile=containerEl.dataset.enableSliderMobile==="true",FoxTheme.config.mqlMobile?this.enableSliderMobile?this.initCarousel():this.destroyCarousel():this.initCarousel()}destroyCarousel(){if(!this.wrapper?.innerHTML.trim().length){this.classList.add("hidden");return}this.container?.classList.remove(this.classes.swiper),this.wrapper?.classList.remove(this.classes.swiperWrapper),this.wrapper?.classList.add(this.classes.grid),typeof this.sliderInstance=="object"&&(this.carousel.slider.destroy(),this.carousel=!1)}calcNavButtonsPosition(){if(!this.dataset.calcButtonPosition==="true")return;const firstMedia=this.querySelector(".product-card__image-wrapper");firstMedia&&firstMedia.clientHeight>0&&this.style.setProperty("--swiper-navigation-top-offset",parseInt(firstMedia.clientHeight)/2+"px")}get slideContainer(){return this.querySelector(".swiper")}get sliderPagination(){return this.querySelector(".swiper-pagination")}get sliderNext(){return this.querySelector(".swiper-button-next")}get sliderPrev(){return this.querySelector(".swiper-button-prev")}get container(){return this.querySelector(".cart-drawer-products-recommendation__container")}get wrapper(){return this.querySelector(".cart-drawer-products-recommendation__wrapper")}}customElements.define("cart-drawer-products-recommendation",CartDrawerProductsRecommendation);class MainCart extends HTMLElement{constructor(){super(),document.addEventListener("cart:grouped-sections",this.get
11SectionToRender.bind(this))}getSectionToRender(event){event.detail.sections.push(FoxTheme.utils.getSectionId(this))}}customElements.define("main-cart",MainCart);class FreeShippingGoal extends HTMLElement{constructor(){super(),this.selectors={leftToSpend:"[data-left-to-spend]"},this.goal=Number(this.dataset.minimumAmount)*Number(window.Shopify.currency.rate||1)||0,this.progress=this.querySelector("progress-bar"),this.money_format=window.FoxTheme.settings.moneyFormat}connectedCallback(){this.updateShippingGloal(Number(this.dataset.cartTotal)),document.addEventListener("cart:updated",event=>{this.updateShippingGloal(event.detail.cart.items_subtotal_price)})}updateShippingGloal(amount){if(amount>0?this.classList.remove("hidden"):this.classList.add("hidden"),this.cartTotal=amount/100,this.goalLeft=this.goal-this.cartTotal,this.goalDone=this.goalLeft<=0,this.percent=this.cartTotal*100/this.goal,this.percent>=100&&(this.percent=100),this.cartTotal>=this.goal)this.progress.style.setProperty("--percent",`${this.percent}%`),this.classList.add("free-shipping-goal--done"),this.progress.dataset.value=this.cartTotal,this.progress.dataset.max=this.goal;else{let spend=(this.goal-this.cartTotal)*100;this.querySelector(this.selectors.leftToSpend).innerHTML=FoxTheme.Currency.formatMoney(spend,this.money_format),this.classList.remove("free-shipping-goal--done"),this.progress.style.setProperty("--percent",`${this.percent}%`),this.progress.dataset.value=this.cartTotal,this.progress.dataset.max=this.goal}}}customElements.define("free-shipping-goal",FreeShippingGoal),window.FoxKitAddToCart=async payload=>{if(!payload?.properties?.["_FoxKit offer"])return;const cartJson=await(await fetch(`${FoxTheme.routes.cart_url}`,{...FoxTheme.utils.fetchConfig()})).json();cartJson.sections=payload.sections,FoxTheme.pubsub.publish(FoxTheme.pubsub.PUB_SUB_EVENTS.cartUpdate,{cart:cartJson}),document.dispatchEvent(new CustomEvent("product-ajax:added",{detail:{product:payload}}))}; 12//# sourceMappingURL=/cdn/shop/t/5/assets/cart.js.map?v=53996066448371499641766571057
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.