1class ProductForm extends HTMLElement{constructor(){super(),this.form=this.querySelector("form"),this.form.addEventListener("submit",this.onSubmitHandler.bind(this)),this.drawer=document.querySelector("cart-drawer")}onSubmitHandler(evt){evt.preventDefault();let properties={};const submitButton=this.querySelector('[type="submit"]'),lineItemPropertyInputs=document.querySelectorAll('input[type="hidden"].line-item-property-input');for(const input of lineItemPropertyInputs)properties[input.dataset.name]=input.value;submitButton.setAttribute("disabled",!0),submitButton.classList.add("loading");const body=JSON.stringify({properties,...JSON.parse(serializeForm(this.form)),sections:["cart-drawer"],sections_url:window.location.pathname});fetch(`${routes.cart_add_url}`,{...fetchConfig("javascript"),body}).then(response=>response.json()).then(parsedState=>{this.drawer.renderContents(parsedState,submitButton)}).catch(e=>{console.error(e)}).finally(()=>{submitButton.classList.remove("loading"),submitButton.removeAttribute("disabled")}),affirm.ui.refresh()}}customElements.define("product-form",ProductForm); 2//# sourceMappingURL=/cdn/shop/t/34/assets/product-form.js.map?v=107339686826221852521787855895
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.