1import{j as D,k as U}from"./chunk-5VBVN4XO.js";import"./chunk-UYODVI7O.js";import"./chunk-MOXDLQT4.js";import"./chunk-VLJ55T5Q.js";import{a as $}from"./chunk-ZACTTJ4S.js";import{c as z,e as B}from"./chunk-EKU7OH35.js";import"./chunk-V2PPMFND.js";import{$a as C,Cb as P,Db as v,Fb as O,Ha as I,Ib as w,Lb as T,Mb as A,Nb as a,Ob as r,Pb as y,Tb as W,Vb as b,Wb as c,ba as d,db as i,fc as l,gc as s,jd as S,kd as E,ma as g,md as F,na as h,pb as M,uc as _,vb as u,vc as m,wc as k}from"./chunk-5SAOKRHL.js";import{g as f}from"./chunk-NZN5XTIE.js";function R(e,o){let t;return o.itemId+((t=o.variantId)!==null&&t!==void 0?t:"")}function j(e,o){e&1&&(a(0,"p"),l(1),_(2,"translate"),r()),e&2&&(i(),s(m(2,1,"account.loading")))}function H(e,o){e&1&&(a(0,"p",2),l(1),_(2,"translate"),r()),e&2&&(i(),s(m(2,1,"account.wishlist.empty")))}function L(e,o){if(e&1&&y(0,"img",7),e&2){let t=c().$implicit,n=c(2);v("src",n.imageUrl(t.imageResourceId),C)}}function N(e,o){e&1&&y(0,"span",8)}function q(e,o){e&1&&(a(0,"span",10),l(1),_(2,"translate"),r()),e&2&&(i(),s(m(2,1,"account.wishlist.unavailable")))}function G(e,o){if(e&1&&(a(0,"span",11),l(1),_(2,"currency"),r()),e&2){let t=c().$implicit;i(),s(k(2,1,t.price,t.currency||"EUR"))}}function J(e,o){if(e&1){let t=W();a(0,"li",5)(1,"a",6),b("click",function(p){let x=g(t).$implicit,V=c(2);return h(V.open(x,p))}),u(2,L,1,1,"img",7)(3,N,1,0,"span",8),a(4,"span",9)(5,"strong"),l(6),r(),u(7,q,3,3,"span",10)(8,G,3,4,"span",11),r()(),a(9,"button",12),_(10,"translate"),b("click",function(){let p=g(t).$implicit,x=c(2);return h(x.remove(p))}),l(11,"\xD7"),r()()}if(e&2){let t=o.$implicit,n=c(2);O("is-gone",!t.available),i(),v("href",n.productHref(t),C),i(),w(t.imageResourceId?2:3),i(4),s(t.name),i(),w(t.available?t.price!==null?8:-1:7),i(2),P("aria-label",m(10,7,"account.wishlist.remove"))}}function K(e,o){if(e&1&&(a(0,"ul",3),T(1,J,12,9,"li",4,R),r()),e&2){let t=c();i(),A(t.store.entries())}}var ct=(()=>{class e{constructor(){this.store=d(U),this.nav=d(D),this.platformId=d(I)}ngOnInit(){return f(this,null,function*(){F(this.platformId)&&(yield this.store.load())})}productHref(t){return this.nav.href(`/product/${t.itemId}`)}open(t,n){n.preventDefault(),this.nav.go(`/product/${t.itemId}`)}imageUrl(t){return`${$.apiUrl}/api/app/resources/${t}/file`}remove(t){return f(this,null,function*(){yield this.store.toggle(t.itemId,t.variantId)})}static{this.\u0275fac=function(n){return new(n||e)}}static{this.\u0275cmp=M({type:e,selectors:[["wr-account-wishlist"]],decls:7,vars:4,consts:[[1,"wr-acw"],[1,"wr-acw__title"],[1,"wr-acw__empty"],[1,"wr-acw__list"],[1,"wr-acw__item",3,"is-gone"],[1,"wr-acw__item"],[1,"wr-acw__link",3,"click","href"],["alt","","loading","lazy",1,"wr-acw__thumb",3,"src"],["aria-hidden","true",1,"wr-acw__thumb","wr-acw__thumb--empty"],[1,"wr-acw__text"],[1,"wr-acw__gone"],[1,"wr-acw__price"],["type","button",1,"wr-acw__remove",3,"click"]],template:function(n,p){n&1&&(a(0,"section",0)(1,"h2",1),l(2),_(3,"translate"),r(),u(4,j,3,3,"p")(5,H,3,3,"p",2)(6,K,3,0,"ul",3),r()),n&2&&(i(2),s(m(3,2,"account.wishlist.title")),i(2),w(p.store.busy()&&p.store.entries().length===0?4:p.store.entries().length===0?5:6))},dependencies:[E,S,B,z],styles:[".wr-acw[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:14px;max-width:620px}.wr-acw__title[_ngcontent-%COMP%]{font-size:18px;margin:0;font-family:var(--wr-font-heading, inherit)}.wr-acw__empty[_ngcontent-%COMP%]{opacity:.7;margin:0;font-size:14px}.wr-acw__list[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:10px}.wr-acw__item[_ngcontent-%COMP%]{display:flex;align-items:center;gap:10px;border:1px solid color-mix(in srgb,currentColor 14%,transparent);border-radius:12px;padding:10px 12px}.wr-acw__item.is-gone[_ngcontent-%COMP%]{opacity:.55}.wr-acw__link[_ngcontent-%COMP%]{display:flex;align-items:center;gap:12px;flex:1 1 auto;min-width:0;color:inherit;text-decoration:none}.wr-acw__thumb[_ngcontent-%COMP%]{width:52px;height:52px;border-radius:9px;object-fit:cover;flex:0 0 auto}.wr-acw__thumb--empty[_ngcontent-%COMP%]{background:color-mix(in srgb,currentColor 8%,transparent);display:block}.wr-acw__text[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:3px;min-width:0;font-size:14px}.wr-acw__price[_ngcontent-%COMP%]{font-weight:700}.wr-acw__gone[_ngcontent-%COMP%]{font-size:12px;opacity:.8}.wr-acw__remove[_ngcontent-%COMP%]{background:none;border:0;color:inherit;opacity:.5;cursor:pointer;font-size:22px;line-height:1;padding:4px 8px;font-family:inherit}.wr-acw__remove[_ngcontent-%COMP%]:hover{opacity:1}"],changeDetection:0})}}return e})();export{ct as AccountWishlistComponent};
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.