1class VendorProducts extends HTMLElement{async connectedCallback(){this.outputContainer=this.querySelector(`#VendorProducts-${this.dataset.sectionId}`);let url=`${this.dataset.vendorUrl}&view=vendor-ajax`;url=url.replace("//","/");try{const text=await(await fetch(url)).text();this.processProducts(text)}catch(error){console.error("Error fetching vendor products:",error)}}processProducts(html){let count=0;const products=[],modals=[],element=document.createElement("div");element.innerHTML=html,element.querySelectorAll(".grid-product").forEach(el=>{const id=el.firstElementChild.dataset.productId;if(count===parseInt(this.dataset.maxProducts,10)||id===this.dataset.productId)return;const modal=element.querySelector(`.modal[data-product-id="${id}"]`);modal&&modals.push(modal),count++,products.push(el)}),this.updateOutputContainer(products,modals)}updateOutputContainer(products,modals){this.outputContainer.innerHTML="",products.length===0?this.classList.add("hide"):(this.classList.remove("hide"),this.outputContainer.append(...products),modals.length&&this.outputContainer.append(...modals))}}customElements.define("vendor-products",VendorProducts); 2//# sourceMappingURL=/cdn/shop/t/101/assets/section.more-products-vendor.js.map?v=8511688544614558571786530467
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.