1import{a as r}from"./wishlist.fsUynMh5.min.js";import"./global-notice.C4ZfiLeN.min.js";import"./global-events.DtO11sQs.min.js";import"./fetch.BphByVRy.min.js";const o={MOVE_TO_BAG_SELECTOR:'[data-selector="move-to-bag"]',REMOVE_FROM_WISHLIST_SELECTOR:'[data-selector="wishlist-page-card-remove"]'},e={DATA_ID:"data-id",DATA_PRODUCT_ID:"data-product-id"};class a extends HTMLElement{constructor(){super(...arguments),this.moveToBag=null,this.removeFromWishlist=null,this.handleMoveToBag=()=>{const t=this.getAttribute(e.DATA_ID);!t||!this.moveToBag||window.cartService.addToCart({id:t,quantity:1},this.moveToBag)},this.handleRemoveFromWishlist=t=>{t.preventDefault();const i=Number(this.getAttribute(e.DATA_PRODUCT_ID)),s=Number(this.getAttribute(e.DATA_ID));!i||!s||r(i,s,this.removeFromWishlist)}}connectedCallback(){this.moveToBag=this.querySelector(o.MOVE_TO_BAG_SELECTOR),this.removeFromWishlist=this.querySelector(o.REMOVE_FROM_WISHLIST_SELECTOR),this.moveToBag?.addEventListener("click",this.handleMoveToBag),this.removeFromWishlist?.addEventListener("click",this.handleRemoveFromWishlist)}disconnectedCallback(){this.moveToBag?.removeEventListener("click",this.handleMoveToBag),this.removeFromWishlist?.removeEventListener("click",this.handleRemoveFromWishlist)}}customElements.get("wishlist-page-card")||customElements.define("wishlist-page-card",a);
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.