PageSourceSearch

https://www.energytcm.cz/5526.206d398df3401f83.js

js energytcm.cz collected 2026-10-07 20:06:28 UTC 88,940 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunkenergy_tcm=self.webpackChunkenergy_tcm||[]).push([[5526],{53448:(H,M,r)=>{r.d(M,{C$:()=>T,G_:()=>c,oH:()=>n,vK:()=>u});const n="[Base Products] get all products",c="[Base Products] get all products suckness";class u{constructor(v){this.payload=v,this.type=n}}class T{constructor(v){this.payload=v,this.type=c}}},68112:(H,M,r)=>{r.d(M,{GP:()=>T,HP:()=>u,a7:()=>n});const n="[Base Products] set filter";class u{constructor(v){this.payload=v,this.type=n}}class T{constructor(){this.type="[Base Products] reset filter"}}},97832:(H,M,r)=>{r.d(M,{A:()=>S});var n=r(60177),c=r(89417),u=r(41635),T=r(76965),h=r(53448),v=r(68112),x=r(46742);const N={product:null,products:null,filter:new x.l};function I(g=N,z){switch(z.type){case h.G_:return{...g,products:z.payload.products,product:null};case v.a7:return{...g,filter:z.payload.filter};default:return g}}var b=r(14421),G=r(15539),_=r(57421),D=r(49090),R=r(95006),U=r(83921),y=r(54438),C=r(12906);let B=(()=>{class g extends C.d{constructor(){super(...arguments),this.PRODUCTS_URL="products"}getProducts(j,A=new x.l){const X={page:j,...A.getFilter()},ot=this.buildUrl(this.PRODUCTS_URL,X,!0);return this.get(ot)}static#t=this.\u0275fac=(()=>{let j;return function(X){return(j||(j=y.xGo(g)))(X||g)}})();static#e=this.\u0275prov=y.jDH({token:g,factory:g.\u0275fac})}return g})();var l=r(29262);let f=(()=>{class g{constructor(j,A,X,ot,pt){this.actions=j,this.productsService=A,this.store=X,this.toastService=ot,this.loaderService=pt}static#t=this.\u0275fac=function(A){return new(A||g)(y.KVO(u.En),y.KVO(B),y.KVO(T.il),y.KVO(l.FS),y.KVO(l.wA))};static#e=this.\u0275prov=y.jDH({token:g,factory:g.\u0275fac})}return g})();var d=r(76613);let F=(()=>{class g extends f{constructor(){super(...arguments),this.getProducts=(0,u.EH)(()=>this.actions.pipe((0,u.gp)(h.oH),(0,G.M)(()=>this.loaderService.show()),(0,_.E)(this.store),(0,D.n)(([j,A])=>this.productsService.getProducts(j.payload.page,A.baseProducts.filter).pipe((0,R.T)(X=>new h.C$({products:X,append:j.payload.append})),(0,U.W)(X=>(0,b.of)(new d.Rn(X))))))),this.getProductsSuccess=(0,u.EH)(()=>this.actions.pipe((0,u.gp)(h.G_),(0,G.M)(()=>this.loaderService.hide())),{dispatch:!1})}static#t=this.\u0275fac=(()=>{let j;return function(X){return(j||(j=y.xGo(g)))(X||g)}})();static#e=this.\u0275prov=y.jDH({token:g,factory:g.\u0275fac})}return g})(),S=(()=>{class g{static#t=this.\u0275fac=function(A){return new(A||g)};static#e=this.\u0275mod=y.$C({type:g});static#i=this.\u0275inj=y.G2t({providers:[B],imports:[n.MD,c.X1,T.md.forFeature("baseProducts",I),u.Vm.forFeature([F]),l.ni]})}return g})()},17877:(H,M,r)=>{r.d(M,{Z:()=>B});
1var n=r(54438),c=r(76965),u=r(45286),T=r(7605),h=r(63020),v=r(58728),x=r(53448),N=r(68112),I=r(46742),b=r(59788),G=r(83891);function _(l,f){1&l&&n.nrm(0,"mcrai-option",1),2&l&&n.Y8G("value",null)}function D(l,f){if(1&l){const d=n.RV6();n.j41(0,"mcrai-option",3),n.bIt("selection",function(S){n.eBV(d);const g=n.XpG();return n.Njj(g.onSelection(S))}),n.EFF(1),n.k0s()}if(2&l){const d=f.$implicit;n.Y8G("value",d.id),n.R7$(),n.E5c(" ",null==d.variants[0]||null==d.variants[0].subvariants[0]?null:d.variants[0].subvariants[0].code," - ",null==d.brand?null:d.brand.name," - ",null==d.info[0]?null:d.info[0].name," ")}}function R(l,f){1&l&&n.nrm(0,"mcrai-option",1),2&l&&n.Y8G("value",null)}function U(l,f){if(1&l&&n.EFF(0),2&l){const d=n.XpG().$implicit;n.SpI(" - ",null==d||null==d.names[0]?null:d.names[0].name," ")}}function y(l,f){if(1&l){const d=n.RV6();n.j41(0,"mcrai-option",3),n.bIt("selection",function(S){n.eBV(d);const g=n.XpG(2);return n.Njj(g.onSubvariantSelection(S,g._control.value))}),n.EFF(1),n.DNE(2,U,1,1),n.k0s()}if(2&l){const d=f.$implicit;n.Y8G("value",d.id),n.R7$(),n.SpI(" ",null==d?null:d.code," "),n.R7$(),n.vxM(2,d.names.length?2:-1)}}function C(l,f){if(1&l&&(n.j41(0,"mcrai-select",2),n.DNE(1,R,1,1,"mcrai-option",1),n.Z7z(2,y,3,3,"mcrai-option",1,n.fX1),n.k0s()),2&l){const d=n.XpG();n.Mz_("placeholder","Subvarianta ",d.required?" *":"",""),n.Y8G("control",d.subvariantControl),n.R7$(),n.vxM(1,d.nullable?1:-1),n.R7$(),n.Dyx(d.getProductSubvariants(d._control.value))}}let B=(()=>{class l{get control(){return this._control}set control(d){this._control=d}get products(){return this.productsContainer?this.productsContainer.items:[]}get paginator(){return this.productsContainer?this.productsContainer.paginator:null}constructor(d){this.store=d,this.destroy=new u.B7,this.multiple=void 0,this.nullable=!0,this.required=!1,this.selection=new n.bkB,this.subvariantSelection=new n.bkB}ngOnInit(){this.resetFilter(),this.getProducts(),this.selectProducts(),this.subvariantControl&&this._control.valueChanges.pipe((0,T.Q)(this.destroy),(0,h.B)(100)).subscribe(()=>this.subvariantControl.reset())}ngOnDestroy(){this.destroy.next(),this.destroy.complete()}selectProducts(){this.store.pipe((0,c.Lt)(d=>d.baseProducts.products),(0,T.Q)(this.destroy),(0,v.p)(d=>!!d)).subscribe(d=>this.productsContainer=d)}getProducts(d=1){this.store.dispatch(new x.vK({page:d,append:!1}))}resetFilter(){this.store.dispatch(new N.GP)}onQueryChange(d){this.store.dispatch(new N.HP({filter:new I.l(d)})),this.getProducts()}onPageChange(d){this.getProducts(d)}getProductSubvariants(d){let F=[];const S=this.products.find(g=>g.id===d);return S&&(F=S.variants.flatMap(g=>g.subvariants)),F}onSelection(d){this.selection.emit(d.value?this.products.find(F=>F.id===d.value):null)}onSubvariantSelection(d,F){const S=this.getProductSubvariants(F);this.subvariantSelection.emit(d.value?S.find(g=>g.id===d.value):null)}static#t=this.\u0275fac=function(F){return new(F||l)(n.rXU(c.il))};static#e=this.\u0275cmp=n.VBU({type:l,selectors:[["aegisx-select-product"]],inputs:{control:"control",subvariantControl:"subvariantControl",multiple:"multiple",nullable:"nullable",required:"required"},outputs:{selection:"selection",subvariantSelection:"subvariantSelection"},decls:5,vars:8,consts:[[3,"pageChange","queryChange","placeholder","control","paginator","multiple"],[3,"value"],[3,"placeholder","control"],[3,"selection","value"]],template:function(F,S){1&F&&(n.j41(0,"mcrai-select",0),n.bIt("pageChange",function(z){return S.onPageChange(z)})("queryChange",function(z){return S.onQueryChange(z)}),n.DNE(1,_,1,1,"mcrai-option",1),n.Z7z(2,D,2,4,"mcrai-option",1,n.fX1),n.k0s(),n.DNE(4,C,4,4,"mcrai-select",2)),2&F&&(n.FCK("placeholder","Produkt",S.multiple?"y":"","",S.required?" *":"",""),n.Y8G("control",S.control)("paginator",S.paginator)("multiple",S.multiple),n.R7$(),n.vxM(1,S.nullable?1:-1),n.R7$(),n.Dyx(S.products),n.R7$(2),n.vxM(4,S._control.valid&&S.subvariantControl&&S.getProductSubvariants(S._control.value)?4:-1))},dependencies:[b.w,G.P],styles:["[_nghost-%COMP%]{display:block;width:100%}"]})}return l})()},46742:(H,M,r)=>{r.d(M,{l:()=>n});
1class n{constructor(u){this.q=u}getFilter(){const u={};return this.q&&(u.q=this.q),u}}},3654:(H,M,r)=>{r.d(M,{m:()=>u});var n=r(54438),c=r(345);let u=(()=>{class T{constructor(v,x){this.elementRef=v,this.sanitizer=x}ngOnChanges(v){"safeHtml"in v&&(this.elementRef.nativeElement.innerHTML=this.sanitizer.sanitize(n.WPN.NONE,this.safeHtml))}static#t=this.\u0275fac=function(x){return new(x||T)(n.rXU(n.aKT),n.rXU(c.up))};static#e=this.\u0275dir=n.FsC({type:T,selectors:[["","safeHtml",""]],inputs:{safeHtml:"safeHtml"},features:[n.OA$]})}return T})()},75526:(H,M,r)=>{r.r(M),r.d(M,{SetsModule:()=>Ro});var n=r(60177),c=r(89417),u=r(29262),T=r(63040),h=r(76965),v=r(45286),x=r(57421),N=r(19493),I=r(1173);const b="[Sets] GET sets",G="[Sets] GET sets success",_="[Sets] GET sets error";class D{constructor(a){this.payload=a,this.type=b}}class R{constructor(a){this.payload=a,this.type=G}}class U{constructor(a){this.payload=a,this.type=_}}const y="[Sets] DELETE sets",C="[Sets] DELETE sets success",B="[Sets] DELETE sets error";class l{constructor(a){this.payload=a,this.type=y}}class f{constructor(a){this.payload=a,this.type=C}}class d{constructor(a){this.payload=a,this.type=B}}const F="[Sets] set filter",S="[Sets] reset filter";class g{constructor(a){this.payload=a,this.type=F}}class z{constructor(){this.type=S}}const j={sets:null,filter:null},A="aegisxSets";function X(i=j,a){switch(a.type){case G:return{...i,sets:a.payload};case F:return{...i,filter:a.payload.filter};case S:return{...i,filter:null};default:return i}}const ot=(0,h.UX)(A),pt=(0,h.Mz)(ot,i=>i.sets),ht=(0,h.Mz)(ot,i=>i.filter),Ct="[Sets] POST set",Ft="[Sets] POST set success",Tt="[Sets] POST set error";class Ee{constructor(a){this.payload=a,this.type=Ct}}class ye{constructor(a){this.payload=a,this.type=Ft}}class Ce{constructor(a){this.payload=a,this.type=Tt}}var t=r(54438),w=r(63649),Q=r(33579),et=r(33555),Y=r(23509),J=r(90113),K=r(36001),nt=r(31992),rt=r(46346),at=r(94300),ct=r(54444),it=r(97519),bt=r(28520),Mt=r(75483),dt=r(37282);let Fe=(()=>{class i{constructor(e,s){this.store=e,this.modalService=s,this.form=new c.J3({language:new c.hs("CZ",c.k0.required),name:new c.hs(null,c.k0.required),url:new c.hs(null),description:new c.hs(null),discount:new c.hs(0,c.k0.min(0)),discount_percent:new c.hs(0,c.k0.min(0)),images:new c.hs([])})}ngOnInit(){}close(){this.modalService.close()}createSet(){this.store.dispatch(new Ee(this.form.value))}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(h.il),t.rXU(u.mO))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-create-set-modal"]],decls:39,vars:12,consts:[["collapsable",""],["type","text","placeholder","Sleva",3,"control"],["type","text","placeholder","Sleva procenta",3,"control"],[3,"control","nullable","required"],["type","text","placeholder","N\xe1zev *",3,"control"],["type","text","placeholder","URL",3,"control"],[3,"control"],["collapsable","",3,"collapsed"],["type","file",3,"control","multiple"],["mcrai-button","negative",3,"click"],["mcrai-button","positive",3,"click","disabled"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-modal")(1,"mcrai-modal-header")(2,"h2"),t.EFF(3,"Vytvo\u0159it set"),t.k0s()(),t.j41(4,"mcrai-modal-content")(5,"mcrai-row")(6,"mcrai-col")(7,"mcrai-panel",0)(8,"mcrai-panel-header")(9,"h2"),t.EFF(10,"Z\xe1kladn\xed informace"),t.k0s()(),t.j41(11,"mcrai-panel-content"),t.nrm(12,"mcrai-input",1)(13,"mcrai-input",2),t.k0s()()()(),t.j41(14,"mcrai-row")(15,"mcrai-col")(16,"mcrai-panel",0)(17,"mcrai-panel-header")(18,"h2"),t.EFF(19,"Prvn\xed jazykov\xe1 mutace"),t.k0s()(),t.j41(20,"mcrai-panel-content"),t.nrm(21,"aegisx-select-language",3)(22,"mcrai-input",4)(23,"mcrai-input",5)(24,"br")(25,"aegisx-smd-editor",6),t.k0s()()()(),t.j41(26,"mcrai-row")(27,"mcrai-col")(28,"mcrai-panel",7)(29,"mcrai-panel-header")(30,"h2"),t.EFF(31,"Obr\xe1zky"),t.k0s()(),t.j41(32,"mcrai-panel-content"),t.nrm(33,"mcrai-input",8),t.k0s()()()()(),t.j41(34,"mcrai-modal-actions")(35,"button",9),t.bIt("click",function(){return o.close()}),t.EFF(36,"Zav\u0159\xedt "),t.k0s(),t.j41(37,"button",10),t.bIt("click",function(){return o.createSet()}),t.EFF(38,"Vytvo\u0159it"),t.k0s()()()),2&s&&(t.R7$(12),t.Y8G("control",o.form.controls.discount),t.R7$(),t.Y8G("control",o.form.controls.discount_percent),t.R7$(8),t.Y8G("control",o.form.controls.language)("nullable",!1)("required",!0),t.R7$(),t.Y8G("control",o.form.controls.name),t.R7$(),t.Y8G("control",o.form.controls.url),t.R7$(2),t.Y8G("control",o.form.controls.description),t.R7$(3),t.Y8G("collapsed",!0),t.R7$(5),t.Y8G("control",o.form.controls.images)("multiple",!0),t.R7$(4),t.Y8G("disabled",o.form.pristine||o.form.invali
1d))},dependencies:[w.Q,Q.o,et.g,Y.g,J.l,K.B,nt.h,rt.l,at.J,ct.f,it.N,bt.e,Mt.Q,dt.N]})}return i})();var ft=r(7605),$=r(95006),_t=r(58728),Te=r(91165),be=r(59863);const It="[Sets] mass patch sets",kt="[Sets] mass patch sets success";class Me{constructor(a){this.payload=a,this.type=It}}class Ie{constructor(a){this.payload=a,this.type=kt}}var gt=r(11815),xt=r(57005);let ke=(()=>{class i{get count(){return this.data.sets&&this.data.sets.length?this.data.sets.length:Math.min(this.data.paginator.count,5e3)}constructor(e,s,o){this.store=e,this.modalService=s,this.data=o,this.SELECTED_CATS_ID="mass-edit-template-cats",this.destroy=new v.B7,this.form=new c.J3({category:new c.hs,keep_categories:new c.hs(!0)}),this.formTemplate=new c.J3({templates:new c.hs}),this.template_cats=[]}ngOnInit(){this.store.pipe((0,h.Lt)(Te.lX),(0,ft.Q)(this.destroy),(0,$.T)(e=>e[this.SELECTED_CATS_ID]),(0,_t.p)(e=>!!e)).subscribe(e=>this.template_cats=e.categories)}ngOnDestroy(){this.destroy.next(),this.destroy.complete()}patch(){const e=this.form.value;if(e.category&&(e.categories=e.category,delete e.category),this.store.dispatch(new Me({body:e,filter:this.data.filter,sets:this.data.sets})),this.data.sets)for(;this.data.sets.length;)this.data.sets.pop();this.store.dispatch(new be.n({id:this.SELECTED_CATS_ID,categories:[]})),this.close()}close(){this.modalService.close()}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(h.il),t.rXU(u.mO),t.rXU(u._P))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-mass-edit-sets-modal"]],decls:15,vars:9,consts:[[3,"formGroup"],[3,"control","multiple","specials","selected","selectedCatsId"],["type","checkbox",3,"control","value"],["mcrai-button","",3,"click"],["mcrai-button","positive",3,"click"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-modal")(1,"mcrai-modal-header")(2,"h1"),t.EFF(3,"Hromadn\xe9 \xfapravy"),t.k0s()(),t.j41(4,"mcrai-modal-content")(5,"form",0),t.nrm(6,"aegisx-select-category",1)(7,"br"),t.j41(8,"mcrai-input",2),t.EFF(9," Zachovat kategorie "),t.k0s()()(),t.j41(10,"mcrai-modal-actions")(11,"button",3),t.bIt("click",function(){return o.close()}),t.EFF(12," Zav\u0159\xedt "),t.k0s(),t.j41(13,"button",4),t.bIt("click",function(){return o.patch()}),t.EFF(14),t.k0s()()()),2&s&&(t.R7$(5),t.Y8G("formGroup",o.form),t.R7$(),t.Y8G("control",o.form.controls.category)("multiple",!0)("specials",!0)("selected",o.template_cats)("selectedCatsId",o.SELECTED_CATS_ID),t.R7$(2),t.Y8G("control",o.form.controls.keep_categories)("value",!0),t.R7$(6),t.SpI(" Upravit ",o.count," set\u016f "))},dependencies:[w.Q,c.qT,c.cb,c.j4,nt.h,rt.l,at.J,ct.f,gt.u,xt.O]})}return i})();var W=r(65382),Dt=r(77617),Rt=r(70014),Ot=r(52699),q=r(92721),xe=r(48390),St=r(18391),jt=r(4379),Pt=r(26588);function De(i,a){if(1&i){const e=t.RV6();t.j41(0,"mcrai-col",1)(1,"button",2),t.bIt("click",function(){t.eBV(e);const o=t.XpG().$implicit,p=t.XpG(2);return t.Njj(p.toggleRequired(o))}),t.j41(2,"mcrai-icon"),t.EFF(3,"select"),t.k0s()()()}}function Re(i,a){if(1&i&&(t.j41(0,"mcrai-row")(1,"mcrai-col")(2,"mcrai-panel")(3,"mcrai-panel-content")(4,"mcrai-row")(5,"mcrai-col",0),t.EFF(6),t.k0s(),t.j41(7,"mcrai-col",1),t.EFF(8),t.k0s(),t.DNE(9,De,4,0,"mcrai-col",1),t.k0s()()()()()),2&i){const e=a.$implicit,s=t.XpG(2);t.R7$(2),t.AVh("mcrai-panel--highlight",s.isSelectedRequired(e)),t.R7$(4),t.E5c(" ",e.product.variants[0].subvariants[0].code," - ",e.product.info[0].name," - ",e.product.brand.name," "),t.R7$(2),t.SpI("",e.count_required,"ks"),t.R7$(),t.vxM(9,s.toolbarService.isSelectable()?9:-1)}}function Oe(i,a){if(1&i&&(t.j41(0,"h3"),t.EFF(1,"Povinn\xe9 polo\u017eky"),t.k0s(),t.Z7z(2,Re,10,7,"mcrai-row",null,t.fX1),t.nrm(4,"br")),2&i){const e=t.XpG();t.R7$(2),t.Dyx(e.required)}}function je(i,a){if(1&i){const e=t.RV6();t.j41(0,"mcrai-col",1)(1,"button",2),t.bIt("click",function(){t.eBV(e);const o=t.XpG().$implicit,p=t.XpG(2);return t.Njj(p.toggleFree(o))}),t.j41(2,"mcrai-icon"),t.EFF(3,"select"),t.k0s()()()}}function Pe(i,a){if(1&i&&(t.j41(0,"mcrai-row")(1,"mcrai-col")(2,"mcrai-panel")(3,"mcrai-panel-content")(4,"mcrai-row")(5,"mcrai-col",0),t.EFF(6),t.k0s(),t.j41(7,"mcrai-col",1),t.EFF(8),t.k0s(),t.DNE(9,je,4,0,"mcrai-col",1),t.k0s()()()()()),2&i){const e=a.$implicit,s=t.XpG(2);t.R7$(2),t.AVh("mcrai-panel--highlight",s.isSelectedFree(e)),t.R7$(4),t.E5c(" ",e.product.variants[0].subvariants[0].code," - ",e.product.info[0].name," - ",e.product.brand.name," "),t.R7$(2),t.SpI("",e.count_required,"ks"),t.R7$(),t.vxM(9,s.toolbarService.isSelectable()?9:-1)}}function Ge(i,a){if(1&i&&(t.j41(0,"h3"),t.EFF(1,"Polo\u017eky zdarma"),t.k0s(),t.Z7z(2,Pe,10,7,"mcrai-row",null,t.fX1)),2&i){const e=t.XpG();t.R7$(2),t.Dyx(e.free)}}function we(i,a){1&i&&(t.j41(0,"p"),t.EFF(1,"V setu nejsou \u017e\xe1dn\xe9 polo\u017eky."),t.k0s())}let Gt=(()=>{class i{constructor(e){this.toolbarService=e,this.selectedRequired=[],this.selectedFree=[],this.selectedRequiredChange=new t.bkB,this.selectedFreeChange=new t.bkB}ngOnInit(){}toggleRequired(e){this.selectedRequiredChange.emit((0,St.L)(this.selectedRequired,e))}toggleFree(e){this.selectedFreeChange.emit((0,St.L)(this.selectedFree,e))}isSelectedRequired(e){return!!this.selectedRequired.find(s=>s.id===e.id)}isSelectedFree(e){return!!this.selectedFree.find(s=>
1s.id===e.id)}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(W.h))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-set-items"]],inputs:{required:"required",free:"free",selectedRequired:"selectedRequired",selectedFree:"selectedFree"},outputs:{selectedRequiredChange:"selectedRequiredChange",selectedFreeChange:"selectedFreeChange"},decls:3,vars:3,consts:[["vertical-center","","flex-4",""],["vertical-center","","horizontal-right",""],["mcrai-icon-button","",3,"click"]],template:function(s,o){1&s&&t.DNE(0,Oe,5,0)(1,Ge,4,0)(2,we,2,0,"p"),2&s&&(t.vxM(0,null!=o.required&&o.required.length?0:-1),t.R7$(),t.vxM(1,null!=o.free&&o.free.length?1:-1),t.R7$(),t.vxM(2,null!=o.free&&o.free.length||null!=o.required&&o.required.length?-1:2))},dependencies:[jt.x,Pt.R,Q.o,et.g,Y.g,K.B]})}return i})(),$e=(()=>{class i{constructor(e,s){this.set=e,this.modalService=s}ngOnInit(){}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(u._P),t.rXU(u.mO))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-set-items-modal"]],decls:9,vars:2,consts:[[3,"required","free"],["mcrai-button","",3,"click"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-modal")(1,"mcrai-modal-header")(2,"h2"),t.EFF(3,"Polo\u017eky setu"),t.k0s()(),t.j41(4,"mcrai-modal-content"),t.nrm(5,"aegisx-set-items",0),t.k0s(),t.j41(6,"mcrai-modal-actions")(7,"button",1),t.bIt("click",function(){return o.modalService.close()}),t.EFF(8,"Zav\u0159\xedt"),t.k0s()()()),2&s&&(t.R7$(5),t.Y8G("required",null==o.set?null:o.set.required)("free",null==o.set?null:o.set.free))},dependencies:[w.Q,nt.h,rt.l,at.J,ct.f,Gt]})}return i})();var wt=r(7165),Ue=r(64204),Be=r(95466),Ae=r(7306),Ve=r(7622),Xe=r(57382),Le=r(65208),He=r(21336),Ne=r(30127),ze=r(49451),$t=r(18227);let Ut=(()=>{class i{transform(e){return e?e+"%":""}static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275pipe=t.EJ8({name:"percent",type:i,pure:!0})}return i})();const Bt=()=>["name","discount","discount_percent","actions"],Ye=i=>["/aegisx","sets",i];function Ke(i,a){1&i&&(t.j41(0,"mcrai-th"),t.EFF(1,"N\xe1zev"),t.k0s())}function Je(i,a){if(1&i&&(t.j41(0,"mcrai-td"),t.EFF(1),t.k0s()),2&i){const e=a.$implicit;t.R7$(),t.JRh(null==e.info[0]?null:e.info[0].name)}}function We(i,a){1&i&&(t.j41(0,"mcrai-th"),t.EFF(1,"Sleva"),t.k0s())}function Ze(i,a){if(1&i&&(t.j41(0,"mcrai-td"),t.EFF(1),t.nI1(2,"currency"),t.k0s()),2&i){const e=a.$implicit;t.R7$(),t.JRh(t.brH(2,1,e.discount,2,2))}}function Qe(i,a){1&i&&(t.j41(0,"mcrai-th"),t.EFF(1,"Sleva procenta"),t.k0s())}function qe(i,a){if(1&i&&(t.j41(0,"mcrai-td"),t.EFF(1),t.nI1(2,"percent"),t.k0s()),2&i){const e=a.$implicit;t.R7$(),t.JRh(t.bMT(2,1,e.discount_percent))}}function ti(i,a){1&i&&t.nrm(0,"mcrai-th",11)}function ei(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",16),t.bIt("click",function(){t.eBV(e);const o=t.XpG().$implicit,p=t.XpG();return t.Njj(p.toggleSet(o))}),t.j41(1,"mcrai-icon",15),t.EFF(2,"select"),t.k0s()()}}function ii(i,a){if(1&i){const e=t.RV6();t.j41(0,"mcrai-td",11)(1,"button",12),t.bIt("click",function(){const o=t.eBV(e).$implicit,p=t.XpG();return t.Njj(p.openSetItemsModal(o))}),t.EFF(2,"polo\u017eky setu"),t.k0s(),t.DNE(3,ei,3,0,"button",13),t.j41(4,"a",14)(5,"mcrai-icon",15),t.EFF(6,"view"),t.k0s()()()}if(2&i){const e=a.$implicit,s=t.XpG();t.R7$(3),t.vxM(3,s.toolbarService.isSelectable()?3:-1),t.R7$(),t.Y8G("mcraiLink",t.eq3(2,Ye,e.id))}}function si(i,a){1&i&&t.nrm(0,"mcrai-tr")}function oi(i,a){if(1&i&&t.nrm(0,"mcrai-tr"),2&i){const e=a.$implicit,s=t.XpG();t.AVh("mcrai-tr--highlight",s.isSelected(e))}}let ni=(()=>{class i{constructor(e,s){this.modalService=e,this.toolbarService=s,this.selectedSets=[],this.selectedChange=new t.bkB}ngOnInit(){}openSetItemsModal(e){this.modalService.open($e,new u.MK("1024px","500px",e))}toggleSet(e){this.selectedChange.emit((0,St.L)(this.selectedSets,e))}isSelected(e){return!!this.selectedSets.find(s=>s.id===e.id)}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(u.mO),t.rXU(W.h))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-set-list"]],inputs:{sets:"sets",selectedSets:"selectedSets"},outputs:{selectedChange:"selectedChange"},decls:15,vars:5,consts:[[3,"items"],["mcraiColumnDef","name"],[4,"mcraiHeaderCellDef"],[4,"mcraiCellDef"],["mcraiColumnDef","discount"],["mcraiColumnDef","discount_percent"],["mcraiColumnDef","actions"],["align-right","",4,"mcraiHeaderCellDef"],["align-right","",4,"mcraiCellDef"],[4,"mcraiHeaderRowDef"],[3,"mcrai-tr--highlight",4,"mcraiRowDef","mcraiRowDefColumns"],["align-right",""],["mcrai-button","neutral",2,"margin-right","auto",3,"click"],["mcrai-icon-button",""],["mcrai-icon-button","",3,"mcraiLink"],["color","primary"],["mcrai-icon-button","",3,"click"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-table",0),t.qex(1,1),t.DNE(2,Ke,2,0,"mcrai-th",2)(3,Je,2,1,"mcrai-td",3),t.bVm(),t.qex(4,4),t.DNE(5,We,2,0,"mcrai-th",2)(6,Ze,3,5,"mcrai-td",3),t.bVm(),t.qex(7,5),t.DNE(8,Qe,2,0,"mcrai-th",2)(9,qe,3,3,"mcrai-td",3),t.bVm(),t.qex(10,6),t.DNE(11,ti,1,0,"mcrai-th",7)(12,ii,7,4,"mcrai-td",8),t.bVm(),t.DNE(13,si,1,0,"mcrai-tr",9)(14,oi,1,2,"mcrai-tr",10),t.k0s()),2&s&&(t.Y8G("items",null==o.sets?null:o.sets.items),t.R7$(13),t.Y8G("mcraiHeaderRowDef",t.lJ4(3,Bt)),t.R7$(),t.Y8G("mcraiRowDefColumns",t.lJ4(4,Bt)))},dependencies:[wt.g,w.Q,jt.x,Pt.R,Ue.n,Be.q,Ae.B,Ve.K,Xe.D,Le.Q,He.V,Ne.e,ze.O,$t.o,Ut]}
1)}return i})();var ri=r(63020),At=r(17877),ai=r(40040);let ci=(()=>{class i{constructor(){this.destroy=new v.B7,this.valueChanges=new t.bkB,this.form=new c.J3({q:new c.hs,brands:new c.hs,categories:new c.hs([]),products:new c.hs([]),no_subcategories:new c.hs,no_categories:new c.hs})}ngOnInit(){this.form.valueChanges.pipe((0,ft.Q)(this.destroy),(0,ri.B)(100)).subscribe(e=>this.valueChanges.emit(e))}ngOnChanges(e){e.hasOwnProperty("filter")&&(this.filter?this.form.patchValue(this.filter):this.form.reset())}ngOnDestroy(){this.destroy.next(),this.destroy.complete()}static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-set-filter-form"]],inputs:{filter:"filter"},outputs:{valueChanges:"valueChanges"},features:[t.OA$],decls:19,vars:12,consts:[["type","text","placeholder","Fulltext",3,"control"],[3,"control","multiple"],[3,"control","multiple","specials"],["vertical-bottom",""],["type","checkbox",3,"control","value"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-row")(1,"mcrai-col"),t.nrm(2,"mcrai-input",0),t.k0s(),t.j41(3,"mcrai-col"),t.nrm(4,"shared-select-brand",1),t.k0s()(),t.j41(5,"mcrai-row")(6,"mcrai-col")(7,"mcrai-row")(8,"mcrai-col"),t.nrm(9,"aegisx-select-category",2),t.k0s(),t.j41(10,"mcrai-col",3)(11,"mcrai-input",4),t.EFF(12,"Nevyhled\xe1vat v podkategori\xedch"),t.k0s()(),t.j41(13,"mcrai-col",3)(14,"mcrai-input",4),t.EFF(15,"Neza\u0159azen\xe9 sety"),t.k0s()()(),t.j41(16,"mcrai-row")(17,"mcrai-col"),t.nrm(18,"aegisx-select-product",1),t.k0s()()()()),2&s&&(t.R7$(2),t.Y8G("control",o.form.controls.q),t.R7$(2),t.Y8G("control",o.form.controls.brands)("multiple",!0),t.R7$(5),t.Y8G("control",o.form.controls.categories)("multiple",!0)("specials",!0),t.R7$(2),t.Y8G("control",o.form.controls.no_subcategories)("value",!0),t.R7$(3),t.Y8G("control",o.form.controls.no_categories)("value",!0),t.R7$(4),t.Y8G("control",o.form.controls.products)("multiple",!0))},dependencies:[Q.o,et.g,it.N,gt.u,At.Z,xt.O,ai.h],styles:[".additional-fields[_ngcontent-%COMP%]{display:flex;margin-right:auto}.additional-field[_ngcontent-%COMP%]{display:flex;align-items:center}.additional-field__input[_ngcontent-%COMP%]{flex:1;margin-right:1.5rem}.additional-field__button[_ngcontent-%COMP%]{flex:0 0 auto}"]})}return i})(),li=(()=>{class i{constructor(e){this.store=e,this.basicFilter={}}ngOnInit(){}ngOnChanges(e){e.hasOwnProperty("filter")&&e.filter.firstChange&&this.filter&&(this.basicFilter=this.filter)}setFilter(){this.store.dispatch(new g({filter:{...this.basicFilter}}))}resetFilter(){this.store.dispatch(new z)}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(h.il))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-set-filter"]],inputs:{filter:"filter"},features:[t.OA$],decls:13,vars:2,consts:[["color","secondary","collapsable","",3,"collapsed"],[3,"valueChanges","filter"],["mcrai-button","neutral",3,"click"],["mcrai-button","positive",3,"click"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-panel",0)(1,"mcrai-panel-header")(2,"h2"),t.EFF(3,"Filtrace"),t.k0s()(),t.j41(4,"mcrai-panel-content")(5,"mcrai-row")(6,"mcrai-col")(7,"aegisx-set-filter-form",1),t.bIt("valueChanges",function(P){return o.basicFilter=P}),t.k0s()()()(),t.j41(8,"mcrai-panel-actions")(9,"button",2),t.bIt("click",function(){return o.resetFilter()}),t.EFF(10," Resetovat filtr "),t.k0s(),t.j41(11,"button",3),t.bIt("click",function(){return o.setFilter()}),t.EFF(12," Filtrovat produkty "),t.k0s()()()),2&s&&(t.Y8G("collapsed",!1),t.R7$(7),t.Y8G("filter",o.filter))},dependencies:[w.Q,Q.o,et.g,Y.g,J.l,q.h,K.B,ci],styles:["h3[_ngcontent-%COMP%]{margin-bottom:1rem}"]})}return i})();function ui(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",8),t.bIt("click",function(){t.eBV(e);const o=t.XpG(2);return t.Njj(o.selectAll())}),t.EFF(1," Ozna\u010dit viditeln\xe9 "),t.k0s(),t.j41(2,"button",9),t.bIt("click",function(){t.eBV(e);const o=t.XpG(2);return t.Njj(o.deselectAll())}),t.EFF(3," Zru\u0161it v\xfdb\u011br "),t.k0s()}if(2&i){const e=t.XpG(2);t.R7$(2),t.Y8G("disabled",!e.areAnySetsSelected())}}function di(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",10),t.bIt("click",function(){t.eBV(e);const o=t.XpG(2);return t.Njj(o.showMassPatchModal())}),t.EFF(1,"Hromadn\xe9 za\u0159azen\xed"),t.k0s()}}function mi(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",10),t.bIt("click",function(){t.eBV(e);const o=t.XpG(2);return t.Njj(o.openCreateSetModal())}),t.EFF(1,"Vytvo\u0159it set"),t.k0s()}}function pi(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",11),t.bIt("click",function(){t.eBV(e);const o=t.XpG(2);return t.Njj(o.deleteSets())}),t.EFF(1,"Smazat vybran\xe9"),t.k0s()}if(2&i){const e=t.XpG(2);t.Y8G("disabled",!e.selectedSets.length)}}function hi(i,a){if(1&i){const e=t.RV6();t.j41(0,"mcrai-paginator",5),t.nI1(1,"async"),t.bIt("page",function(o){t.eBV(e);const p=t.XpG();return t.Njj(p.fetchSets({page:o}))}),t.k0s(),t.DNE(2,ui,4,1)(3,di,2,0,"button",6)(4,mi,2,0,"button",6)(5,pi,2,1,"button",7)}if(2&i){let e;const s=t.XpG();t.Y8G("paginator",null==(e=t.bMT(1,5,s.sets))?null:e.paginator),t.R7$(2),t.vxM(2,
1s.toolbarService.isSelectable()?2:-1),t.R7$(),t.vxM(3,s.toolbarService.isEditMode()?3:-1),t.R7$(),t.vxM(4,s.toolbarService.isDeleteMode()?-1:4),t.R7$(),t.vxM(5,s.toolbarService.isDeleteMode()?5:-1)}}function fi(i,a){1&i&&t.eu8(0)}function _i(i,a){1&i&&t.eu8(0)}let gi=(()=>{class i{constructor(e,s,o){this.store=e,this.modalService=s,this.toolbarService=o,this.destroy=new v.B7,this.selectedSets=[]}ngOnInit(){this.toolbarService.setToolbarModes([I.H.View,I.H.Edit,I.H.Delete]),this.sets=this.store.pipe((0,h.Lt)(pt)),this.filter=this.store.pipe((0,h.Lt)(ht)),this.fetchSets()}ngOnDestroy(){this.destroy.next(),this.destroy.complete()}fetchSets(e={page:1}){this.store.dispatch(new D({query:e}))}openCreateSetModal(){this.modalService.open(Fe,new u.MK("1200px","800px"))}showMassPatchModal(){this.store.pipe((0,h.Lt)(ht),(0,x.E)(this.sets),(0,N.s)(1)).subscribe(([e,s])=>{const o=new u.m_("800px","600px",{sets:this.selectedSets,filter:e,paginator:s.paginator});this.modalService.open(ke,o)})}deleteSets(){this.store.dispatch(new l({ids:this.selectedSets.map(e=>e.id)}))}selectAll(){this.sets.pipe((0,N.s)(1)).subscribe(e=>{this.selectedSets=e?e.items:[]})}deselectAll(){this.selectedSets=[]}areAnySetsSelected(){return Array.isArray(this.selectedSets)&&this.selectedSets.length>0}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(h.il),t.rXU(u.mO),t.rXU(W.h))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-sets"]],decls:20,vars:9,consts:[["setActions",""],[3,"filter"],[3,"selectedChange","sets","selectedSets"],["top",""],[4,"ngTemplateOutlet"],[1,"pull-left",3,"page","paginator"],["mcrai-button","positive"],["mcrai-button","negative",3,"disabled"],["mcrai-button","neutral",3,"click"],["mcrai-button","neutral",3,"click","disabled"],["mcrai-button","positive",3,"click"],["mcrai-button","negative",3,"click","disabled"]],template:function(s,o){if(1&s){const p=t.RV6();t.nrm(0,"aegisx-header"),t.j41(1,"mcrai-container")(2,"mcrai-panel")(3,"mcrai-panel-header")(4,"h1"),t.EFF(5,"Sety"),t.k0s()(),t.j41(6,"mcrai-panel-content")(7,"mcrai-row")(8,"mcrai-col"),t.nrm(9,"aegisx-set-filter",1),t.nI1(10,"async"),t.k0s()(),t.j41(11,"aegisx-set-list",2),t.nI1(12,"async"),t.bIt("selectedChange",function(ut){return t.eBV(p),t.Njj(o.selectedSets=ut)}),t.k0s()(),t.DNE(13,hi,6,7,"ng-template",null,0,t.C5r),t.j41(15,"mcrai-panel-actions",3),t.DNE(16,fi,1,0,"ng-container",4),t.k0s(),t.j41(17,"mcrai-panel-actions"),t.DNE(18,_i,1,0,"ng-container",4),t.k0s()()(),t.nrm(19,"aegisx-toolbar")}if(2&s){const p=t.sdS(14);t.R7$(9),t.Y8G("filter",t.bMT(10,5,o.filter)),t.R7$(2),t.Y8G("sets",t.bMT(12,7,o.sets))("selectedSets",o.selectedSets),t.R7$(5),t.Y8G("ngTemplateOutlet",p),t.R7$(2),t.Y8G("ngTemplateOutlet",p)}},dependencies:[n.T3,Dt.I,Rt.I,w.Q,Q.o,et.g,Ot.H,Y.g,J.l,q.h,K.B,xe.h,ni,li,n.Jj]})}return i})();const Vt="[Sets] GET set",vt="[Sets] GET set success",Xt="[Sets] GET set error";class Si{constructor(a){this.payload=a,this.type=Vt}}class Z{constructor(a){this.payload=a,this.type=vt}}class vi{constructor(a){this.payload=a,this.type=Xt}}const Et=(0,r(70746).p)(),yi=Et.getInitialState(),Lt="aegisxSet";function Ci(i=yi,a){return a.type===vt?Et.upsertOne(a.payload.item,i):i}const mt=(0,h.UX)(Lt),{selectIds:Fi,selectEntities:Ti,selectAll:bi,selectTotal:Mi}=Et.getSelectors(),Ii=((0,h.Mz)(mt,Fi),(0,h.Mz)(mt,Ti)),Ht=((0,h.Mz)(mt,bi),(0,h.Mz)(mt,Mi),"[Sets] POST set item"),Nt="[Sets] POST set item success",zt="[Sets] POST set item error";class ki{constructor(a){this.payload=a,this.type=Ht}}class xi{constructor(a){this.payload=a,this.type=Nt}}class Di{constructor(a){this.payload=a,this.type=zt}}var Ri=r(59788),Oi=r(83891);let ji=(()=>{class i{constructor(e,s,o){this.data=e,this.store=s,this.modalService=o,this.form=new c.J3({type:new c.hs(null,c.k0.required),product:new c.hs(null,c.k0.required),count:new c.hs(1,[c.k0.required,
1c.k0.min(1)])})}ngOnInit(){}postSetItem(){this.store.dispatch(new ki({type:this.form.value.type,id:this.data,body:{product:this.form.value.product,count_required:this.form.value.count,count_free:this.form.value.count}}))}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(u._P),t.rXU(h.il),t.rXU(u.mO))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-add-set-item-modal"]],decls:17,vars:3,consts:[["placeholder","Typ polo\u017eky",3,"control"],["value","required"],["value","free"],[3,"control"],["type","text","placeholder","Po\u010det kus\u016f","errors","Po\u010det kus\u016f produktu. Minim\xe1ln\u011b jeden kus.",3,"control"],["mcrai-button","",3,"click"],["mcrai-button","positive",3,"click"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-modal")(1,"mcrai-modal-header")(2,"h2"),t.EFF(3,"P\u0159idat polo\u017eku"),t.k0s()(),t.j41(4,"mcrai-modal-content")(5,"mcrai-select",0)(6,"mcrai-option",1),t.EFF(7,"Povinn\xe1 polo\u017eka"),t.k0s(),t.j41(8,"mcrai-option",2),t.EFF(9,"Polo\u017eka zdarma"),t.k0s()(),t.nrm(10,"aegisx-select-product",3)(11,"mcrai-input",4),t.k0s(),t.j41(12,"mcrai-modal-actions")(13,"button",5),t.bIt("click",function(){return o.modalService.close()}),t.EFF(14,"Zav\u0159\xedt"),t.k0s(),t.j41(15,"button",6),t.bIt("click",function(){return o.postSetItem()}),t.EFF(16,"P\u0159idat"),t.k0s()()()),2&s&&(t.R7$(5),t.Y8G("control",o.form.controls.type),t.R7$(5),t.Y8G("control",o.form.controls.product),t.R7$(),t.Y8G("control",o.form.controls.count))},dependencies:[w.Q,nt.h,rt.l,at.J,ct.f,it.N,Ri.w,Oi.P,At.Z]})}return i})();
1const Yt="[Sets] DELETE set items",Kt="[Sets] DELETE set items success",Jt="[Sets] DELETE set items error";class Wt{constructor(a){this.payload=a,this.type=Yt}}class Pi{constructor(a){this.payload=a,this.type=Kt}}class Gi{constructor(a){this.payload=a,this.type=Jt}}var Zt=r(7887),Qt=r(71845);const qt="[Sets] PATCH set",te="[Sets] PATCH set success";class ee{constructor(a){this.payload=a,this.type=qt}}class wi{constructor(a){this.payload=a,this.type=te}}var ie=r(41819),se=r(62523),oe=r(39103),ne=r(52570),$i=r(99138);function Ui(i,a){if(1&i&&(t.j41(0,"mcrai-dl")(1,"mcrai-dt"),t.EFF(2,"Sleva"),t.k0s(),t.j41(3,"mcrai-dd"),t.EFF(4),t.nI1(5,"currency"),t.nI1(6,"notSet"),t.k0s(),t.j41(7,"mcrai-dt"),t.EFF(8,"Sleva procenta"),t.k0s(),t.j41(9,"mcrai-dd"),t.EFF(10),t.nI1(11,"percent"),t.nI1(12,"notSet"),t.k0s(),t.j41(13,"mcrai-dt"),t.EFF(14,"Flag akce"),t.k0s(),t.j41(15,"mcrai-dd"),t.EFF(16),t.nI1(17,"booleanToString"),t.k0s(),t.j41(18,"mcrai-dt"),t.EFF(19,"Flag doporu\u010dujeme"),t.k0s(),t.j41(20,"mcrai-dd"),t.EFF(21),t.nI1(22,"booleanToString"),t.k0s(),t.j41(23,"mcrai-dt"),t.EFF(24,"Flag tip"),t.k0s(),t.j41(25,"mcrai-dd"),t.EFF(26),t.nI1(27,"booleanToString"),t.k0s()()),2&i){const e=t.XpG(2);t.R7$(4),t.JRh(t.bMT(6,9,t.brH(5,5,null==e.set?null:e.set.discount,2,2))),t.R7$(6),t.JRh(t.bMT(12,13,t.bMT(11,11,null==e.set?null:e.set.discount_percent))),t.R7$(6),t.JRh(t.bMT(17,15,null==e.set?null:e.set.flag_action)),t.R7$(5),t.JRh(t.bMT(22,17,null==e.set?null:e.set.flag_recommended)),t.R7$(5),t.JRh(t.bMT(27,19,null==e.set?null:e.set.flag_tip))}}function Bi(i,a){if(1&i&&(t.j41(0,"form",1),t.nrm(1,"mcrai-input",2)(2,"mcrai-input",3),t.j41(3,"mcrai-input",4),t.EFF(4,"Flag akce "),t.k0s(),t.j41(5,"mcrai-input",4),t.EFF(6,"Flag doporu\u010dujeme "),t.k0s(),t.j41(7,"mcrai-input",4),t.EFF(8,"Flag tip "),t.k0s()()),2&i){const e=t.XpG(2);t.Y8G("formGroup",e.form),t.R7$(),t.Y8G("control",e.controls.discount),t.R7$(),t.Y8G("control",e.controls.discount_percent),t.R7$(),t.Y8G("control",e.controls.flag_action)("value",!0)("checked",e.controls.flag_action.value),t.R7$(2),t.Y8G("control",e.controls.flag_recommended)("value",!0)("checked",e.controls.flag_recommended.value),t.R7$(2),t.Y8G("control",e.controls.flag_tip)("value",!0)("checked",e.controls.flag_tip.value)}}function Ai(i,a){if(1&i&&(t.j41(0,"mcrai-panel-content"),t.DNE(1,Ui,28,21,"mcrai-dl")(2,Bi,9,12,"form",1),t.k0s()),2&i){const e=t.XpG();t.R7$(),t.vxM(1,e.toolbarService.isEditMode()?-1:1),t.R7$(),t.vxM(2,e.toolbarService.isEditMode()?2:-1)}}function Vi(i,a){if(1&i){const e=t.RV6();t.j41(0,"mcrai-panel-actions")(1,"button",5),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.patch())}),t.EFF(2,"Ulo\u017eit zm\u011bny "),t.k0s()()}if(2&i){const e=t.XpG();t.R7$(),t.Y8G("disabled",e.isPatchButtonDisabled())}}let Xi=(()=>{class i{get controls(){return this.form.controls}constructor(e,s,o){this.store=e,this.builder=s,this.toolbarService=o,this.buildForm()}ngOnInit(){}ngOnChanges(e){e.hasOwnProperty("set")&&e.set.currentValue&&this.form.patchValue(e.set.currentValue)}buildForm(){this.form=this.builder.group({discount:[0,c.k0.min(0)],discount_percent:[0,c.k0.min(0)],flag_action:[null],flag_recommended:[null],flag_tip:[null]})}isPatchButtonDisabled(){return this.form.invalid||this.form.pristine}patch(){this.isPatchButtonDisabled()||this.store.dispatch(new ee({id:this.set.id,body:this.form.value}))}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(h.il),t.rXU(c.ze),t.rXU(W.h))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-set-detail"]],inputs:{set:"set"},features:[t.OA$],decls:6,vars:2,consts:[["color","secondary"],[3,"formGroup"],["type","text","placeholder","Sleva",3,"control"],["type","text","placeholder","Sleva procenta",3,"control"],["type","checkbox",3,"control","value","checked"],["mcrai-button","positive",3,"click","disabled"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-panel",0)(1,"mcrai-panel-header")(2,"h2"),t.EFF(3,"Z\xe1kladn\xed informace"),t.k0s()(),t.DNE(4,Ai,3,2,"mcrai-panel-content")(5,Vi,3,1,"mcrai-panel-actions"),t.k0s()),2&s&&(t.R7$(4),t.vxM(4,o.set?4:-1),t.R7$(),t.vxM(5,o.toolbarService.isEditMode()?5:-1))},dependencies:[w.Q,c.qT,c.cb,c.j4,Y.g,J.l,q.h,K.B,it.N,gt.u,ie.p,se.L,oe.Z,$t.o,ne.s,$i.Z,Ut]})}return i})();const re="[Sets] ADD set info",ae="[Sets] ADD set info success";class Li{constructor(a){this.payload=a,this.type=re}}class Hi{constructor(a){this.payload=a,this.type=ae}}let Ni=(()=>{class i{constructor(e,s,o){this.store=e,this.modalService=s,this.data=o,this.form=new c.J3({language:new c.hs("CZ",c.k0.required),name:new c.hs(null,c.k0.required),url:new c.hs(null),description:new c.hs(null)})}ngOnInit(){}close(){this.modalService.close()}
1isAddButtonDisabled(){return this.form.invalid||this.form.pristine}add(){this.isAddButtonDisabled()||this.store.dispatch(new Li({id:this.data.set.id,body:this.form.value}))}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(h.il),t.rXU(u.mO),t.rXU(u._P))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["mcrai-add-set-info-modal"]],decls:15,vars:7,consts:[[3,"control","nullable","required"],["type","text","placeholder","N\xe1zev *",3,"control"],["type","text","placeholder","URL",3,"control"],[3,"control"],["mcrai-button","negative",3,"click"],["mcrai-button","positive",3,"click","disabled"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-modal")(1,"mcrai-modal-header")(2,"h1"),t.EFF(3,"Nov\xe1 jazykov\xe1 mutace"),t.k0s()(),t.j41(4,"mcrai-modal-content"),t.nrm(5,"aegisx-select-language",0)(6,"mcrai-input",1)(7,"mcrai-input",2)(8,"br")(9,"aegisx-smd-editor",3),t.k0s(),t.j41(10,"mcrai-modal-actions")(11,"button",4),t.bIt("click",function(){return o.close()}),t.EFF(12,"Zav\u0159\xedt "),t.k0s(),t.j41(13,"button",5),t.bIt("click",function(){return o.add()}),t.EFF(14,"Ulo\u017eit "),t.k0s()()()),2&s&&(t.R7$(5),t.Y8G("control",o.form.controls.language)("nullable",!1)("required",!0),t.R7$(),t.Y8G("control",o.form.controls.name),t.R7$(),t.Y8G("control",o.form.controls.url),t.R7$(2),t.Y8G("control",o.form.controls.description),t.R7$(4),t.Y8G("disabled",o.isAddButtonDisabled()))},dependencies:[w.Q,nt.h,rt.l,at.J,ct.f,it.N,Mt.Q,dt.N]})}return i})();const ce="[Sets] PATCH set info",le="[Sets] PATCH set info success";class ue{constructor(a,e=!1){this.payload=a,this.no_get=e,this.type=ce}}class zi{constructor(a,e=!1){this.payload=a,this.no_get=e,this.type=le}}var Yi=r(57864),de=r(44010),Ki=r(6985),Ji=r(3654);function Wi(i,a){if(1&i&&t.nrm(0,"div",0),2&i){const e=t.XpG();t.Y8G("safeHtml",e.info.description)}}function Zi(i,a){if(1&i&&t.nrm(0,"aegisx-smd-editor",1),2&i){const e=t.XpG();t.Y8G("control",e.form.controls.description)}}function Qi(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",4),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.patch())}),t.EFF(1,"Ulo\u017eit "),t.k0s()}if(2&i){const e=t.XpG();t.Y8G("disabled",e.isPatchbuttonDisabled())}}let me=(()=>{class i{get info(){return this.data.info}constructor(e,s,o,p){this.modalService=e,this.store=s,this.toolbarService=o,this.data=p,this.form=new c.J3({language:new c.hs(null,c.k0.required),description:new c.hs(null)}),this.form.patchValue(p.info)}ngOnInit(){}close(){this.modalService.close()}isPatchbuttonDisabled(){return this.form.invalid||this.form.pristine}patch(){this.isPatchbuttonDisabled()||this.store.dispatch(new ue({id:this.data.set.id,bodies:[this.form.value]}))}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(u.mO),t.rXU(h.il),t.rXU(W.h),t.rXU(u._P))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["mcrai-text-modal"]],decls:11,vars:3,consts:[[1,"set__text",3,"safeHtml"],[3,"control"],["mcrai-button","negative",3,"click"],["mcrai-button","positive",3,"disabled"],["mcrai-button","positive",3,"click","disabled"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-panel")(1,"mcrai-panel-header")(2,"h1"),t.EFF(3,"N\xe1hled textu"),t.k0s()(),t.j41(4,"mcrai-panel-content"),t.DNE(5,Wi,1,1,"div",0)(6,Zi,1,1,"aegisx-smd-editor",1),t.k0s(),t.j41(7,"mcrai-panel-actions")(8,"button",2),t.bIt("click",function(){return o.close()}),t.EFF(9,"Zav\u0159\xedt "),t.k0s(),t.DNE(10,Qi,2,1,"button",3),t.k0s()()),2&s&&(t.R7$(5),t.vxM(5,o.toolbarService.isEditMode()?-1:5),t.R7$(),t.vxM(6,o.toolbarService.isEditMode()?6:-1),t.R7$(4),t.vxM(10,o.toolbarService.isEditMode()?10:-1))},dependencies:[w.Q,Ki.m,Y.g,J.l,q.h,K.B,dt.N,Ji.m],styles:["mcrai-panel-content[_ngcontent-%COMP%]{overflow:auto}.set__text[_ngcontent-%COMP%]     h1{font-size:34px;font-weight:300;text-transform:uppercase;margin:10px 0}.set__text[_ngcontent-%COMP%]     h2{font-size:24px;font-weight:300;color:#a1135e;margin:10px 0}.set__text[_ngcontent-%COMP%]     h3{font-size:20px;font-weight:300;margin:10px 0}.set__text[_ngcontent-%COMP%]     p{font-weight:400;color:#000!important}.set__text[_ngcontent-%COMP%]     ul, .set__text[_ngcontent-%COMP%]     ol{padding-left:20px;color:#000!important}.set__text[_ngcontent-%COMP%]     b, .set__text[_ngcontent-%COMP%]     strong{font-weight:700}.set__text[_ngcontent-%COMP%]     table{border-collapse:collapse}.set__text[_ngcontent-%COMP%]     td, .set__text[_ngcontent-%COMP%]     th{padding:2px 5px;border:1px solid #D2D0E7}.set__text[_ngcontent-%COMP%]     img{margin:0;max-width:100%!important;height:auto}.set__text[_ngcontent-%COMP%]     img.margin-rd-12{margin:0 12px 12px 0}.set__text[_ngcontent-%COMP%]     img.margin-ld-12{margin:0 0 12px 12px}th[_ngcontent-%COMP%], td[_ngcontent-%COMP%]{border:1px solid grey}.mcrai-col[_ngcontent-%COMP%]{word-break:break-all}"]})}return i})();var qi=r(87173);let ts=(()=>{class i{get baseUrl(){return this.linkService.getProductsAbsoluteUrl()}constructor(e,s){this.modalService=e,this.linkService=s}ngOnInit(){}showTextModal(e){const s=new u.m_("800px","600px",{set:this.set,info:e});this.modalService.open(me,s)}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(u.mO),t.rXU(qi._))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-set-info-view"]],inputs:{info:"info",set:"set"},decls:14,vars:8,consts:[["target","_blank",3,"mcraiLink"],["mcrai-button","neutral",3,"click"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-dl")(1,"mcrai-dt"),t.EFF(2,"N\xe1zev"),t.k0s(),t.j41(3,"mcrai-dd"),t.EFF(4),t.nI1(5,"notSet"),t.k0s(),t.j41(6,"mcrai-dt"),t.EFF(7,"URL"),t.k0s(),t.j41(8,"mcrai-dd")(9,"a",0),t.EFF(10),t.nI1(11,"notSet"),t.k0s()()(),t.j41(12,"button",1),t.bIt("click",function(){return o.showTextModal(o.info)}),t.EFF(13,"Zobrazit text"),t.k0s()),2&s&&(t.R7$(4),t.JRh(t.bMT(5,4,o.info.name)),t.R7$(5),t.Y8G("mcraiLink",o.set),t.R7$(),t.Lme("",o.baseUrl,"",t.bMT(11,6,o.info.url),""))},dependencies:[wt.g,w.Q,ie.p,se.L,oe.Z,ne.s]})}return i})();var es=r(52070);let is=(()=>{class i{get controls(){return this.form.controls}constructor(e){this.modalService=e,this.ERRORS={name:{required:"Produkt mus\xed m\xedt n\xe1zev"},url:{required:"Produkt mus\xed m\xedt url"}},this.formGroupEmitter=new t.bkB}ngOnInit(){this.createForm()}createForm(){this.form=new c.J3({language:new c.hs(this.info.language,c.k0.required),name:new c.hs(this.info.name,c.k0.required),url:new c.hs(this.info.url),description:new c.hs(this.info.description)}),this.form.valueChanges.subscribe(()=>this.onFormValueChange())}showTextModal(e){const s=new u.m_("800px","600px",{set:this.set,info:e});this.modalService.open(me,s)}onFormValueChange(){this.formGroupEmitter.emit({language:this.info.language,form:this.form})}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(u.mO))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-set-info-form"]],inputs:{info:"info",set:"set"},outputs:{formGroupEmitter:"formGroupEmitter"},decls:7,vars:6,consts:[[3,"formGroup"],["type","text","placeholder","N\xe1zev *",3,"control","errors"],["type","product",3,"control","errors"],[3,"control"]],template:function(s,o){1&s&&(t.j41(0,"form",0),t.nrm(1,"mcrai-input",1)(2,"aegisx-url-input",2),t.k0s(),t.j41(3,"div"),t.nrm(4,"br"),t.EFF(5," Popis "),t.nrm(6,"aegisx-smd-editor",3),t.k0s()),2&s&&(t.Y8G("formGroup",o.form),t.R7$(),t.Y8G("control",o.controls.name)("errors",o.ERRORS.name),t.R7$(),t.Y8G("control",o.controls.url)("errors",o.ERRORS.url),t.R7$(4),t.Y8G("control",o.controls.description))},dependencies:[c.qT,c.cb,c.j4,es.$,it.N,dt.N]})}return i})();function ss(i,a){if(1&i&&(t.j41(0,"h3"),t.EFF(1),t.k0s()),2&i){const e=t.XpG().$implicit;t.R7$(),t.JRh(e.language)}}function os(i,a){if(1&i&&t.nrm(0,"aegisx-set-info-view",2),2&i){const e=t.XpG().$implicit,s=t.XpG(3);t.Y8G("info",e)("set",s.set)}}function ns(i,a){if(1&i){const e=t.RV6();t.j41(0,"aegisx-set-info-form",3),t.bIt("formGroupEmitter",function(o){t.eBV(e);const p=t.XpG(4);return t.Njj(p.pickupPatchedProductInfo(o.language,o.form))}),t.k0s()}if(2&i){const e=t.XpG().$implicit,s=t.XpG(3);t.Y8G("info",e)("set",s.set)}}function rs(i,a){if(1&i&&(t.j41(0,"mcrai-tab"),t.DNE(1,ss,2,1,"ng-template",1)(2,os,1,2,"aegisx-set-info-view",2)(3,ns,1,2,"aegisx-set-info-form",2),t.k0s()),2&i){const e=t.XpG(3);t.R7$(2),t.vxM(2,e.toolbarService.isEditMode()?-1:2),t.R7$(),t.vxM(3,e.toolbarService.isEditMode()?3:-1)}}function as(i,a){if(1&i&&(t.j41(0,"mcrai-horizontal-tabs"),t.Z7z(1,rs,4,2,"mcrai-tab",null,t.fX1),t.k0s()),2&i){const e=t.XpG(2);t.R7$(),t.Dyx(e.set.info)}}function cs(i,a){if(1&i&&(t.j41(0,"mcrai-panel-content"),t.DNE(1,as,3,0,"mcrai-horizontal-tabs"),t.k0s()),2&i){const e=t.XpG();t.R7$(),t.vxM(1,e.set.info.length?1:-1)}}function ls(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",6),t.bIt("click",function(){t.eBV(e);const o=t.XpG(2);return t.Njj(o.showAddSetInfoModal())}),t.EFF(1,"P\u0159idat jazykovou mutaci "),t.k0s()}}function us(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",7),t.bIt("click",function(){t.eBV(e);const o=t.XpG(2);return t.Njj(o.patch())}
1),t.EFF(1,"Ulo\u017eit zm\u011bny "),t.k0s()}if(2&i){const e=t.XpG(2);t.Y8G("disabled",e.isPatchButtonDisabled())}}function ds(i,a){if(1&i&&(t.j41(0,"mcrai-panel-actions"),t.DNE(1,ls,2,0,"button",4)(2,us,2,1,"button",5),t.k0s()),2&i){const e=t.XpG();t.R7$(),t.vxM(1,e.toolbarService.isDeleteMode()?-1:1),t.R7$(),t.vxM(2,e.toolbarService.isEditMode()?2:-1)}}let ms=(()=>{class i{constructor(e,s,o,p){this.store=e,this.builder=s,this.modalService=o,this.toolbarService=p,this.patchedSetInfo=new c.J3({})}ngOnInit(){}ngOnChanges(e){if(e.hasOwnProperty("set")&&e.set.currentValue){this.patchedSetInfo=new c.J3({});const s=e.set.currentValue;for(const o of s.info)this.patchedSetInfo.addControl(o.language,new c.J3({language:new c.hs(o.language,c.k0.required),name:new c.hs(o.name,c.k0.required),url:new c.hs(o.url),description:new c.hs(o.description)}))}}showAddSetInfoModal(){const e=new u.m_("800px","600px",{set:this.set});this.modalService.open(Ni,e)}isPatchButtonDisabled(){return this.patchedSetInfo.invalid||!this.patchedSetInfo.dirty}patch(){this.isPatchButtonDisabled()||this.store.dispatch(new ue({id:this.set.id,bodies:this.patchedSetInfo.value},!0))}pickupPatchedProductInfo(e,s){this.patchedSetInfo.markAsDirty(),this.patchedSetInfo.setControl(e,s)}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(h.il),t.rXU(c.ze),t.rXU(u.mO),t.rXU(W.h))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-set-info"]],inputs:{set:"set"},features:[t.OA$],decls:6,vars:2,consts:[["color","secondary"],["mcraiTabLabel",""],[3,"info","set"],[3,"formGroupEmitter","info","set"],["mcrai-button","positive"],["mcrai-button","positive",3,"disabled"],["mcrai-button","positive",3,"click"],["mcrai-button","positive",3,"click","disabled"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-panel",0)(1,"mcrai-panel-header")(2,"h2"),t.EFF(3,"Jazykov\xe9 mutace"),t.k0s()(),t.DNE(4,cs,2,1,"mcrai-panel-content")(5,ds,3,2,"mcrai-panel-actions"),t.k0s()),2&s&&(t.R7$(4),t.vxM(4,o.set?4:-1),t.R7$(),t.vxM(5,o.toolbarService.isDeleteMode()?-1:5))},dependencies:[w.Q,Y.g,J.l,q.h,K.B,Yi.y,de.qv,de.p$,ts,is],styles:[".mcrai-tabs[_ngcontent-%COMP%]{background-color:#fff!important}"]})}return i})();var yt=r(80070),ps=r(51279);const hs=i=>["/aegisx","categories",i];function fs(i,a){if(1&i&&(t.j41(0,"mcrai-row")(1,"mcrai-col")(2,"mcrai-panel")(3,"mcrai-panel-header")(4,"mcrai-row")(5,"mcrai-col",2),t.EFF(6),t.k0s(),t.j41(7,"mcrai-col")(8,"a",3),t.EFF(9,"Detail"),t.k0s()()()()()()()),2&i){const e=a.$implicit,s=t.XpG(3);t.R7$(6),t.Lme(" ",s.breadcrumbsToString(e)," ",null==e.info[0]?null:e.info[0].name," "),t.R7$(2),t.Y8G("routerLink",t.eq3(3,hs,e.id))}}function _s(i,a){1&i&&t.EFF(0," -- \u017d\xe1dn\xe9 kategorie -- ")}function gs(i,a){if(1&i&&(t.Z7z(0,fs,10,5,"mcrai-row",null,t.fX1),t.DNE(2,_s,1,0)),2&i){const e=t.XpG(2);t.Dyx(null==e.set?null:e.set.categories),t.R7$(2),t.vxM(2,null!=e.set&&null!=e.set.categories&&e.set.categories.length?-1:2)}}function Ss(i,a){if(1&i){const e=t.RV6();t.j41(0,"aegisx-category-tree2",4),t.bIt("onSelectCategories",function(o){t.eBV(e);const p=t.XpG(2);return t.Njj(p.pickupCategories(o))}),t.k0s()}if(2&i){const e=t.XpG(2);t.Y8G("multiple",!0)("selected",e.set.categories)}}function vs(i,a){if(1&i&&(t.j41(0,"mcrai-panel-content"),t.DNE(1,gs,3,1)(2,Ss,1,2,"aegisx-category-tree2",1),t.k0s()),2&i){const e=t.XpG();t.R7$(),t.vxM(1,e.toolbarService.isViewMode()?1:-1),t.R7$(),t.vxM(2,e.toolbarService.isViewMode()?-1:2)}}function Es(i,a){if(1&i){const e=t.RV6();t.j41(0,"mcrai-panel-actions")(1,"button",5),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.patch())}),t.EFF(2,"Ulo\u017eit zm\u011bny"),t.k0s()()}if(2&i){const e=t.XpG();t.R7$(),t.Y8G("disabled",e.isPatchButtonDisabled())}}let ys=(()=>{class i{constructor(e,s){this.store=e,this.toolbarService=s,this.form=new c.J3({categories:new c.hs([])})}ngOnInit(){}breadcrumbsToString(e){const s=[];return e.breadcrumbs.forEach(o=>{o.id&&o.info[0]&&s.push(o.info[0].name)}),s.length?s.join(" > ")+" > ":""}pickupCategories(e){this.form.patchValue({categories:(0,yt._)(e)}),this.form.controls.categories.markAsDirty(),this.form.controls.categories.markAsTouched()}
1isPatchButtonDisabled(){return this.form.invalid||this.form.pristine}patch(){this.isPatchButtonDisabled()||this.store.dispatch(new ee({id:this.set.id,body:this.form.value}))}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(h.il),t.rXU(W.h))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-set-categories"]],inputs:{set:"set"},decls:6,vars:3,consts:[["color","secondary","collapsable","",3,"collapsed"],[3,"multiple","selected"],[1,"name"],["target","_blank","mcrai-button","neutral",1,"pull-right",3,"routerLink"],[3,"onSelectCategories","multiple","selected"],["mcrai-button","neutral",3,"click","disabled"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-panel",0)(1,"mcrai-panel-header")(2,"h2"),t.EFF(3,"Kategorie"),t.k0s()(),t.DNE(4,vs,3,2,"mcrai-panel-content")(5,Es,3,1,"mcrai-panel-actions"),t.k0s()),2&s&&(t.Y8G("collapsed",!0),t.R7$(4),t.vxM(4,o.set?4:-1),t.R7$(),t.vxM(5,o.toolbarService.isViewMode()?-1:5))},dependencies:[T.Wk,w.Q,Q.o,et.g,Y.g,J.l,q.h,K.B,ps.e],styles:[".mcrai-row[_ngcontent-%COMP%]{width:100%}.name[_ngcontent-%COMP%]{display:flex;align-items:center}"]})}return i})();const pe="[Sets] ADD set images",he="[Sets] ADD set images success";class Cs{constructor(a){this.payload=a,this.type=pe}}class Fs{constructor(a){this.payload=a,this.type=he}}let Ts=(()=>{class i{constructor(e,s,o){this.store=e,this.modalService=s,this.data=o,this.form=new c.J3({images:new c.hs([],c.k0.required)})}ngOnInit(){}close(){this.modalService.close()}isAddButtonDisabled(){return this.form.invalid||this.form.pristine}add(){this.isAddButtonDisabled()||this.store.dispatch(new Cs({id:this.data.set.id,images:this.form.value.images}))}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(h.il),t.rXU(u.mO),t.rXU(u._P))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["mcrai-upload-images-modal"]],decls:11,vars:3,consts:[["type","file",3,"control","multiple"],["mcrai-button","negative",3,"click"],["mcrai-button","positive",3,"click","disabled"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-modal")(1,"mcrai-modal-header")(2,"h1"),t.EFF(3,"Nahr\xe1t obr\xe1zky"),t.k0s()(),t.j41(4,"mcrai-modal-content"),t.nrm(5,"mcrai-input",0),t.k0s(),t.j41(6,"mcrai-modal-actions")(7,"button",1),t.bIt("click",function(){return o.close()}),t.EFF(8,"Zav\u0159\xedt "),t.k0s(),t.j41(9,"button",2),t.bIt("click",function(){return o.add()}),t.EFF(10,"Nahr\xe1t obr\xe1zky "),t.k0s()()()),2&s&&(t.R7$(5),t.Y8G("control",o.form.controls.images)("multiple",!0),t.R7$(4),t.Y8G("disabled",o.isAddButtonDisabled()))},dependencies:[w.Q,nt.h,rt.l,at.J,ct.f,bt.e]})}return i})();var bs=r(20832);
1const fe="[Sets] DELETE set images",_e="[Sets] DELETE set images success";class Ms{constructor(a){this.payload=a,this.type=fe}}class Is{constructor(a){this.payload=a,this.type=_e}}const ge="[Sets] PATCH set images",Se="[Sets] PATCH set images success";class ks{constructor(a){this.payload=a,this.type=ge}}class xs{constructor(a){this.payload=a,this.type=Se}}const Ds=i=>[i,"sort_index"];function Rs(i,a){if(1&i&&t.nrm(0,"mcrai-input",7),2&i){const e=t.XpG().$implicit,s=t.XpG();t.Y8G("control",s.form.get(t.eq3(1,Ds,e.id)))}}function Os(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",9),t.bIt("click",function(){t.eBV(e);const o=t.XpG().$implicit,p=t.XpG();return t.Njj(p.toggleImage(o))}),t.EFF(1,"Vybrat "),t.k0s()}}function js(i,a){if(1&i&&(t.j41(0,"div",5),t.nrm(1,"mcrai-media",6),t.DNE(2,Rs,1,3,"mcrai-input",7)(3,Os,2,0,"button",8),t.k0s()),2&i){const e=a.$implicit,s=t.XpG();t.AVh("set__image--selected",s.isSelected(e)),t.R7$(),t.Y8G("data",e.thumbnail)("mcraiImageDetail",e.original),t.R7$(),t.vxM(2,s.toolbarService.isEditMode()?2:-1),t.R7$(),t.vxM(3,s.toolbarService.isDeleteMode()?3:-1)}}function Ps(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",10),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.showUploadImagesModal())}),t.EFF(1,"Nahr\xe1t obr\xe1zky "),t.k0s()}}function Gs(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",11),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.patch())}),t.EFF(1,"Ulo\u017eit obr\xe1zky "),t.k0s()}if(2&i){const e=t.XpG();t.Y8G("disabled",e.isPatchButtonDisabled())}}function ws(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",12),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.delete())}),t.EFF(1,"Smazat vybran\xe9 "),t.k0s()}if(2&i){const e=t.XpG();t.Y8G("disabled",e.isDeleteButtonDisabled())}}let $s=(()=>{class i{constructor(e,s,o){this.store=e,this.modalService=s,this.toolbarService=o,this.selectedImages=[],this.form=new c.J3({})}ngOnInit(){}ngOnChanges(e){if(e.hasOwnProperty("set")&&e.set.currentValue){const s=e.set.currentValue;this.form=new c.J3({});for(const o of s.images)this.form.setControl(o.id,new c.J3({id:new c.hs(o.id,c.k0.required),sort_index:new c.hs(o.sort_index)}))}}showUploadImagesModal(){const e=new u.m_("800px","600px",{set:this.set});this.modalService.open(Ts,e)}isSelected(e){return!!this.selectedImages.find(s=>s.id===e.id)}toggleImage(e){this.selectedImages=(0,bs.g)(this.selectedImages,e)}unselectAll(){this.selectedImages=[]}isDeleteButtonDisabled(){return!this.selectedImages.length}delete(){this.isDeleteButtonDisabled()||(this.store.dispatch(new Ms({id:this.set.id,items:this.selectedImages})),this.unselectAll())}isPatchButtonDisabled(){return this.form.invalid||this.form.pristine}patch(){if(!this.isPatchButtonDisabled()){const e=[];for(const s of Object.values(this.form.controls))s.touched&&s.dirty&&e.push(s.value);this.store.dispatch(new ks({id:this.set.id,bodies:e}))}}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(h.il),t.rXU(u.mO),t.rXU(W.h))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-set-images"]],inputs:{set:"set"},features:[t.OA$],decls:12,vars:4,consts:[["color","secondary","collapsable","",3,"collapsed"],[1,"set__image",3,"set__image--selected"],["mcrai-button","positive"],["mcrai-button","positive",3,"disabled"],["mcrai-button","negative",3,"disabled"],[1,"set__image"],["type","image","width","200","height","200",3,"data","mcraiImageDetail"],["type","text","placeholder","Po\u0159ad\xed",3,"control"],["mcrai-button","neutral"],["mcrai-button","neutral",3,"click"],["mcrai-button","positive",3,"click"],["mcrai-button","positive",3,"click","disabled"],["mcrai-button","negative",3,"click","disabled"]],template:function(s,o){1&s&&(t.j41(0,"mcrai-panel",0)(1,"mcrai-panel-header")(2,"h2"),t.EFF(3,"Obr\xe1zky"),t.k0s()(),t.j41(4,"mcrai-panel-content")(5,"mcrai-row"),t.Z7z(6,js,4,6,"div",1,t.fX1),t.k0s()(),t.j41(8,"mcrai-panel-actions"),t.DNE(9,Ps,2,0,"button",2)(10,Gs,2,1,"button",3)(11,ws,2,1,"button",4),t.k0s()()),2&s&&(t.Y8G("collapsed",!1),t.R7$(6),t.Dyx(null==o.set?null:o.set.images),t.R7$(3),t.vxM(9,o.toolbarService.isDeleteMode()?-1:9),t.R7$(),t.vxM(10,o.toolbarService.isEditMode()?10:-1),t.R7$(),t.vxM(11,o.toolbarService.isDeleteMode()?11:-1))},dependencies:[w.Q,Q.o,Y.g,J.l,q.h,K.B,it.N,Zt.h,Qt.U],styles:[".set__image[_ngcontent-%COMP%]{margin:5px;padding:5px;border:1px solid #d6e0ee;transition:opacity .2s cubic-bezier(.35,0,.25,1);
1display:block;position:relative}.set__image--selected[_ngcontent-%COMP%]{opacity:.35;background:gray}.set__image[_ngcontent-%COMP%]   button[_ngcontent-%COMP%]{position:absolute;inset:0;margin:auto}"]})}return i})();function Us(i,a){if(1&i&&(t.nrm(0,"mcrai-media",1),t.nI1(1,"async"),t.nI1(2,"async")),2&i){let e,s;const o=t.XpG();t.Y8G("data",null==(e=t.bMT(1,2,o.set).images[0])?null:e.thumbnail)("mcraiImageDetail",null==(s=t.bMT(2,4,o.set).images[0])?null:s.original)}}function Bs(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",7),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.openAddSetItemModule())}),t.EFF(1,"P\u0159idat polo\u017eku"),t.k0s()}}function As(i,a){if(1&i){const e=t.RV6();t.j41(0,"button",8),t.bIt("click",function(){t.eBV(e);const o=t.XpG();return t.Njj(o.deleteSetItems())}),t.EFF(1,"Smazat vybran\xe9"),t.k0s()}if(2&i){const e=t.XpG();t.Y8G("disabled",0==e.selectedFreeItems.length&&0==e.selectedRequiredItems.length)}}const Vs=[{path:"",component:gi,canActivate:[]},{path:":id",component:(()=>{class i{constructor(e,s,o,p,P){this.activatedRoute=e,this.store=s,this.modalService=o,this.toolbarService=p,this.location=P,this.destroy=new v.B7,this.selectedFreeItems=[],this.selectedRequiredItems=[]}ngOnInit(){this.toolbarService.setToolbarModes([I.H.View,I.H.Edit,I.H.Delete]),this.activatedRoute.params.pipe((0,ft.Q)(this.destroy),(0,$.T)(e=>e.id),(0,_t.p)(e=>!!e)).subscribe(e=>{this.id=e,this.fetchSet(e)}),this.set=this.store.pipe((0,h.Lt)(Ii),(0,$.T)(e=>e[this.id]),(0,_t.p)(e=>!!e))}ngOnDestroy(){this.destroy.next(),this.destroy.complete()}fetchSet(e){this.store.dispatch(new Si({id:e}))}openAddSetItemModule(){this.modalService.open(ji,new u.MK("800px","600px",this.id))}deleteSetItems(){this.selectedFreeItems.length>0&&this.store.dispatch(new Wt({type:"free",id:this.id,ids:this.selectedFreeItems.map(e=>e.id)})),this.selectedRequiredItems.length>0&&this.store.dispatch(new Wt({type:"required",id:this.id,ids:this.selectedRequiredItems.map(e=>e.id)}))}static#t=this.\u0275fac=function(s){return new(s||i)(t.rXU(T.nX),t.rXU(h.il),t.rXU(u.mO),t.rXU(W.h),t.rXU(n.aZ))};static#e=this.\u0275cmp=t.VBU({type:i,selectors:[["aegisx-set"]],decls:45,vars:29,consts:[["mcrai-button","neutral",3,"click"],["type","image","width","40","height","40",1,"header--image",3,"data","mcraiImageDetail"],[3,"set"],["color","secondary","collapsable","",3,"collapsed"],[3,"selectedRequiredChange","selectedFreeChange","selectedFree","selectedRequired","required","free"],["mcrai-button","positive"],["mcrai-button","negative",3,"disabled"],["mcrai-button","positive",3,"click"],["mcrai-button","negative",3,"click","disabled"]],template:function(s,o){if(1&s&&(t.nrm(0,"aegisx-header"),t.j41(1,"mcrai-container")(2,"mcrai-row")(3,"mcrai-col")(4,"button",0),t.bIt("click",function(){return o.location.back()}),t.EFF(5,"Zp\xe1tky"),t.k0s()()(),t.j41(6,"mcrai-row")(7,"mcrai-col")(8,"mcrai-panel")(9,"mcrai-panel-header"),t.DNE(10,Us,3,6,"mcrai-media",1),t.nI1(11,"async"),t.j41(12,"h1"),t.EFF(13),t.nI1(14,"async"),t.k0s()(),t.j41(15,"mcrai-panel-content")(16,"mcrai-row")(17,"mcrai-col"),t.nrm(18,"aegisx-set-detail",2),t.nI1(19,"async"),t.k0s(),t.j41(20,"mcrai-col"),t.nrm(21,"aegisx-set-info",2),t.nI1(22,"async"),t.k0s()(),t.j41(23,"mcrai-row")(24,"mcrai-col")(25,"mcrai-panel",3)(26,"mcrai-panel-header")(27,"h2"),t.EFF(28,"Polo\u017eky setu"),t.k0s()(),t.j41(29,"mcrai-panel-content")(30,"aegisx-set-items",4),t.nI1(31,"async"),t.nI1(32,"async"),t.bIt("selectedRequiredChange",function(P){return o.selectedRequiredItems=P})("selectedFreeChange",function(P){return o.selectedFreeItems=P}),t.k0s()(),t.j41(33,"mcrai-panel-actions"),t.DNE(34,Bs,2,0,"button",5)(35,As,2,1,"button",6),t.k0s()()()(),t.j41(36,"mcrai-row")(37,"mcrai-col"),t.nrm(38,"aegisx-set-categories",2),t.nI1(39,"async"),t.k0s()(),t.j41(40,"mcrai-row")(41,"mcrai-col"),t.nrm(42,"aegisx-set-images",2),t.nI1(43,"async"),t.k0s()()()()()()(),t.nrm(44,"aegisx-toolbar")),2&s){let p,P,ut,ve;t.R7$(10),t.vxM(10,null!=(p=t.bMT(11,13,o.set))&&p.images[0]?10:-1),t.R7$(3),t.SpI("Set ",null==(P=t.bMT(14,15,o.set))||null==P.info[0]?null:P.info[0].name,""),t.R7$(5),t.Y8G("set",t.bMT(19,17,o.set)),t.R7$(3),t.Y8G("set",t.bMT(22,19,o.set)),t.R7$(4),t.Y8G("collapsed",!0),t.R7$(5),t.Y8G("selectedFree",o.selectedFreeItems)("selectedRequired",o.selectedRequiredItems)("required",null==(ut=t.bMT(31,21,o.set))?null:ut.required)("free",null==(ve=t.bMT(32,23,o.set))?null:ve.free),t.R7$(4),t.vxM(34,o.toolbarService.isDeleteMode()?-1:34),t.R7$(),t.vxM(35,o.toolbarService.isDeleteMode()?35:-1),t.R7$(3),t.Y8G("set",t.bMT(39,25,o.set)),t.R7$(4),t.Y8G("set",t.bMT(43,27,o.set))}},dependencies:[Dt.I,Rt.I,w.Q,Q.o,et.g,Ot.H,Y.g,J.l,q.h,K.B,Zt.h,Qt.U,Gt,Xi,ms,ys,$s,n.Jj],styles:[".header--image[_ngcontent-%COMP%]{margin-right:10px}"]})}return i})(),canActivate:[]}];let Xs=(()=>
1{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[T.iI.forChild(Vs),T.iI]})}return i})();var Ls=r(291),Hs=r(93578),m=r(41635),E=r(15539),k=r(49090),L=r(83921),O=r(14421),Ns=r(12906);let zs=(()=>{class i extends Ns.d{constructor(){super(...arguments),this.SETS_ROOT="sets",this.INFO="info",this.IMAGES="images"}getSets(e){const s=this.buildUrl(this.SETS_ROOT,{...e,filter:JSON.stringify(e.filter)});return this.get(s)}getSet(e){const s=this.buildUrl([this.SETS_ROOT,e]);return this.get(s)}postSet(e){const s=this.buildUrl([this.SETS_ROOT]),o=new FormData;if(e.images)for(const p of e.images)o.append("images[]",p);return delete e.images,o.append("body",JSON.stringify(e)),this.post(s,o)}patchSet(e,s){const o=this.buildUrl([this.SETS_ROOT,e]);return this.patch(o,s)}patchSets(e,s,o){const p={...e},P=this.buildUrl(this.SETS_ROOT,p);return s.set_ids=(0,yt._)(o),this.patch(P,s)}deleteSets(e){const s=this.buildUrl([this.SETS_ROOT],{ids:e});return this.del(s)}postItems(e,s,o){const p=this.buildUrl([this.SETS_ROOT,s,e]);return this.post(p,o)}deleteSetItems(e,s,o){const p=this.buildUrl([this.SETS_ROOT,s,e],{ids:o});return this.del(p)}addSetInfo(e,s){const o=this.buildUrl([this.SETS_ROOT,e,this.INFO]);return this.post(o,s)}patchSetInfo(e,s){const o=this.buildUrl([this.SETS_ROOT,e,this.INFO]);return this.patch(o,s)}addSetImages(e,s){const o=this.buildUrl([this.SETS_ROOT,e,this.IMAGES]),p=new FormData;for(const P of s)p.append("images[]",P);return this.post(o,p)}patchSetImages(e,s){const o=this.buildUrl([this.SETS_ROOT,e,this.IMAGES]);return this.patch(o,s)}deleteSetImages(e,s){const o={images:(0,yt._)(s)},p=this.buildUrl([this.SETS_ROOT,e,this.IMAGES],o);return this.del(p)}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})(),V=(()=>{class i{constructor(e,s,o,p,P,ut){this.actions=e,this.store=s,this.dataService=o,this.loaderService=p,this.toasterService=P,this.modalService=ut}static#t=this.\u0275fac=function(s){return new(s||i)(t.KVO(m.En),t.KVO(h.il),t.KVO(zs),t.KVO(u.wA),t.KVO(u.FS),t.KVO(u.mO))};static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),Ys=(()=>{class i extends V{constructor(){super(...arguments),this.getSets=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(b),(0,x.E)(this.store.pipe((0,h.Lt)(ht))),(0,E.M)(()=>this.loaderService.show()),(0,k.n)(([e,s])=>this.dataService.getSets(Object.assign({},e.payload.query,s)).pipe((0,$.T)(o=>new R(o)),(0,L.W)(o=>(0,O.of)(new U(o))))))),this.getSetsSuccess=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(G),(0,E.M)(()=>this.loaderService.hide())),{dispatch:!1}),this.getSetsError=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(_),(0,E.M)(e=>{this.loaderService.hide(),this.toasterService.makeToast(e.payload.message,u.Ck.Error)})),{dispatch:!1})}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),Ks=(()=>{class i extends V{constructor(){super(...arguments),this.filter=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(F,S),(0,k.n)(()=>(0,O.of)(new D({query:{page:1}})))))}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})();var Js=r(634);let lt=(()=>{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,Js.r,u.DJ,u.wl,u.oP]})}return i})(),Ws=(()=>{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,lt,m.Vm.forFeature([Ys,Ks]),h.md.forFeature(A,X)]})}return i})(),Zs=(()=>{class i extends V{constructor(){super(...arguments),this.postSet=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(Ct),(0,E.M)(()=>this.loaderService.show()),(0,k.n)(e=>this.dataService.postSet(e.payload).pipe((0,$.T)(s=>new ye(s)),(0,L.W)(s=>(0,O.of)(new Ce(s))))))),this.postSetSuccess=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(Ft),(0,E.M)(e=>{this.loaderService.hide(),this.toasterService.makeToast(e.payload.message,u.Ck.Success),this.modalService.close()}),(0,k.n)(e=>(0,O.of)(new R(e.payload))))),this.postSetError=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(Tt),(0,E.M)(e=>{this.loaderService.hide(),this.toasterService.makeToast(e.payload.message,u.Ck.Error)})),{dispatch:!1})}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),Qs=(()=>
1{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,lt,m.Vm.forFeature([Zs])]})}return i})();var qs=r(52759),to=r(12741),eo=r(50289);let io=(()=>{class i extends V{constructor(){super(...arguments),this.getSet=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(Vt),(0,E.M)(()=>this.loaderService.show()),(0,k.n)(e=>this.dataService.getSet(e.payload.id).pipe((0,$.T)(s=>new Z(s)),(0,L.W)(s=>(0,O.of)(new vi(s))))))),this.getSetSuccess=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(vt),(0,E.M)(()=>this.loaderService.hide())),{dispatch:!1}),this.getSetError=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(Xt),(0,E.M)(e=>{this.loaderService.hide(),this.toasterService.makeToast(e.payload.message,u.Ck.Error)})),{dispatch:!1})}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),tt=(()=>{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,lt,m.Vm.forFeature([io]),h.md.forFeature(Lt,Ci)]})}return i})(),so=(()=>{class i extends V{constructor(){super(...arguments),this.postSetItem=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(Ht),(0,E.M)(()=>this.loaderService.show()),(0,k.n)(e=>this.dataService.postItems(e.payload.type,e.payload.id,e.payload.body).pipe((0,$.T)(s=>new xi(s)),(0,L.W)(s=>(0,O.of)(new Di(s))))))),this.postSetItemSuccess=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(Nt),(0,E.M)(e=>{this.loaderService.hide(),this.toasterService.makeToast(e.payload.message,u.Ck.Success),this.modalService.close()}),(0,k.n)(e=>(0,O.of)(new Z({item:e.payload.item}))))),this.postSetItemError=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(zt),(0,E.M)(e=>{this.loaderService.hide(),this.toasterService.makeToast(e.payload.message,u.Ck.Error)})),{dispatch:!1})}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),oo=(()=>{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,lt,m.Vm.forFeature([so])]})}return i})();var no=r(97832);let ro=(()=>{class i extends V{constructor(){super(...arguments),this.deleteSets=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(y),(0,E.M)(()=>this.loaderService.show()),(0,k.n)(e=>this.dataService.deleteSets(e.payload.ids).pipe((0,$.T)(s=>new f(s)),(0,L.W)(s=>(0,O.of)(new d(s))))))),this.deleteSetsSuccess=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(C),(0,E.M)(e=>{this.loaderService.hide(),this.toasterService.makeToast(e.payload.message,u.Ck.Success)}),(0,k.n)(e=>(0,O.of)(new R(e.payload))))),this.deleteSetsError=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(B),(0,E.M)(e=>{this.loaderService.hide(),this.toasterService.makeToast(e.payload.message,u.Ck.Error)})),{dispatch:!1})}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),ao=(()=>{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,lt,m.Vm.forFeature([ro])]})}return i})();var co=r(18456);let lo=(()=>{class i extends V{constructor(){super(...arguments),this.deleteSetItems=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(Yt),(0,E.M)(()=>this.loaderService.show()),(0,co.ZZ)(e=>this.dataService.deleteSetItems(e.payload.type,e.payload.id,e.payload.ids).pipe((0,$.T)(s=>new Pi(s)),(0,L.W)(s=>(0,O.of)(new Gi(s))))))),this.deleteSetItemsSuccess=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(Kt),(0,E.M)(e=>{this.loaderService.hide(),this.toasterService.makeToast(e.payload.message,u.Ck.Success)}),(0,k.n)(e=>(0,O.of)(new Z({item:e.payload.item}))))),this.deleteSetItemsError=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(Jt),(0,E.M)(e=>{this.loaderService.hide(),this.toasterService.makeToast(e.payload.message,u.Ck.Error)})),{dispatch:!1})}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),uo=(()=>
1{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,lt,m.Vm.forFeature([lo])]})}return i})();var st=r(76613);let mo=(()=>{class i extends V{constructor(){super(...arguments),this.patchSet=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(qt),(0,E.M)(()=>this.loaderService.show()),(0,k.n)(e=>this.dataService.patchSet(e.payload.id,e.payload.body).pipe((0,$.T)(s=>new wi(s)),(0,L.W)(s=>(0,O.of)(new st.Rn(s))))))),this.patchSetSuccess=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(te),(0,E.M)(e=>this.toasterService.makeToast(e.payload.message,u.Ck.Success)),(0,k.n)(e=>[new Z({item:e.payload.item})])))}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),po=(()=>{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,tt,m.Vm.forFeature([mo])]})}return i})();var ho=r(55951),fo=r(73821);let _o=(()=>{class i extends V{constructor(){super(...arguments),this.addSetInfo=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(re),(0,E.M)(()=>this.loaderService.show()),(0,k.n)(e=>this.dataService.addSetInfo(e.payload.id,e.payload.body).pipe((0,$.T)(s=>new Hi(s)),(0,L.W)(s=>(0,O.of)(new st.Rn(s))))))),this.addSetInfoSuccess=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(ae),(0,E.M)(e=>{this.toasterService.makeToast(e.payload.message,u.Ck.Success),this.modalService.close()}),(0,k.n)(e=>[new Z({item:e.payload.item})])))}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),go=(()=>{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,tt,m.Vm.forFeature([_o])]})}return i})(),So=(()=>{class i extends V{constructor(){super(...arguments),this.patchSetInfo=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(ce),(0,E.M)(()=>this.loaderService.show()),(0,k.n)(e=>this.dataService.patchSetInfo(e.payload.id,e.payload.bodies).pipe((0,$.T)(s=>new zi(s,e.no_get)),(0,L.W)(s=>(0,O.of)(new st.Rn(s))))))),this.patchSetInfoSuccess=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(le),(0,E.M)(e=>{this.toasterService.makeToast(e.payload.message,u.Ck.Success),e.no_get&&this.loaderService.hide()}),(0,k.n)(e=>e.no_get?[]:[new Z({item:e.payload.item})])))}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),vo=(()=>{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,tt,m.Vm.forFeature([So])]})}return i})();var Eo=r(13476);let yo=(()=>{class i extends V{constructor(){super(...arguments),this.addSetImages=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(pe),(0,E.M)(()=>this.loaderService.show()),(0,k.n)(e=>this.dataService.addSetImages(e.payload.id,e.payload.images).pipe((0,$.T)(s=>new Fs(s)),(0,L.W)(s=>(0,O.of)(new st.Rn(s))))))),this.addSetImagesSuccess=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(he),(0,E.M)(e=>{this.toasterService.makeToast(e.payload.message,u.Ck.Success),this.modalService.close()}),(0,k.n)(e=>[new Z({item:e.payload.item})])))}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),Co=(()=>{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,tt,m.Vm.forFeature([yo])]})}return i})(),Fo=(()=>{class i extends V{constructor(){super(...arguments),this.patchSetImages=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(ge),(0,E.M)(()=>this.loaderService.show()),(0,k.n)(e=>this.dataService.patchSetImages(e.payload.id,e.payload.bodies).pipe((0,$.T)(s=>new xs(s)),(0,L.W)(s=>(0,O.of)(new st.Rn(s))))))),this.patchSetImagesSuccess=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(Se),(0,E.M)(e=>{this.toasterService.makeToast(e.payload.message,u.Ck.Success),this.modalService.close()}),(0,k.n)(e=>[new Z({item:e.payload.item})])))}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),To=(()=>
1{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,tt,m.Vm.forFeature([Fo])]})}return i})(),bo=(()=>{class i extends V{constructor(){super(...arguments),this.deleteSetImages=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(fe),(0,E.M)(()=>this.loaderService.show()),(0,k.n)(e=>this.dataService.deleteSetImages(e.payload.id,e.payload.items).pipe((0,$.T)(s=>new Is(s)),(0,L.W)(s=>(0,O.of)(new st.Rn(s))))))),this.deleteSetImagesSuccess=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(_e),(0,E.M)(e=>{this.toasterService.makeToast(e.payload.message,u.Ck.Success),this.modalService.close()}),(0,k.n)(e=>[new Z({item:e.payload.item})])))}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),Mo=(()=>{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,tt,m.Vm.forFeature([bo])]})}return i})();var Io=r(67524);let ko=(()=>{class i extends V{constructor(){super(...arguments),this.patchSets=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(It),(0,E.M)(()=>this.loaderService.show()),(0,k.n)(e=>this.dataService.patchSets(e.payload.filter,e.payload.body,e.payload.sets).pipe((0,$.T)(s=>new Ie(s)),(0,L.W)(s=>(0,O.of)(new st.Rn(s))))))),this.patchSetsSuccess=(0,m.EH)(()=>this.actions.pipe((0,m.gp)(kt),(0,E.M)(e=>{this.loaderService.hide(),this.toasterService.makeToast(e.payload.message,u.Ck.Success)}),(0,x.E)(this.store),(0,k.n)(()=>(0,O.of)(new D({query:{page:1}})))))}static#t=this.\u0275fac=(()=>{let e;return function(o){return(e||(e=t.xGo(i)))(o||i)}})();static#e=this.\u0275prov=t.jDH({token:i,factory:i.\u0275fac})}return i})(),xo=(()=>{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,tt,m.Vm.forFeature([ko])]})}return i})();var Do=r(96161);let Ro=(()=>{class i{static#t=this.\u0275fac=function(s){return new(s||i)};static#e=this.\u0275mod=t.$C({type:i});static#i=this.\u0275inj=t.G2t({imports:[n.MD,Xs,Hs.m,Ls.G,qs.V,to.Y,eo.G,c.X1,Ws,Qs,tt,po,ao,go,vo,xo,oo,uo,Co,To,Mo,Do._,u.LU,u.pj,u.Zg,u.xT,u.o6,u.SD,u.oP,u.B4,u.Tm,u.ni,u.hv,u.F8,no.A,ho.R,fo.c,Eo.X,Io.N]})}return i})()},80070:(H,M,r)=>{function n(c){return c?c.reduce((u,T)=>u.concat(T.id),[]):[]}r.d(M,{_:()=>n})},7165:(H,M,r)=>{r.d(M,{g:()=>I});var n=r(63040),c=r(45286),u=r(7605),T=r(58728),h=r(14085),v=r(54438),x=r(60177),N=r(87173);let I=(()=>{class b{set mcraiLink(_){this._commands=this._parseCommands(_)}set href(_){this._href=_}set target(_){this._target=_}set queryParams(_){this._queryParams=_}set skipLocationChange(_){this._skipLocationChange=_}set replaceUrl(_){this._replaceUrl=_}set queryParamsHandling(_){this._queryParamsHandling=_}set fragment(_){this._fragment=_}get urlTree(){return this._router.createUrlTree(this._commands,{relativeTo:this._route,queryParams:this._queryParams,fragment:this._fragment,queryParamsHandling:this._queryParamsHandling,preserveFragment:(0,h.he)(this._preserveFragment)})}constructor(_,D,R,U){this._router=_,this._route=D,this._locationStrategy=R,this._linkService=U,this.destroy=new c.B7,this._commands=[],_.events.pipe((0,u.Q)(this.destroy),(0,T.p)(y=>y instanceof n.wF)).subscribe(()=>this._updateTargetUrlAndHref())}ngOnChanges(){this._updateTargetUrlAndHref()}ngOnDestroy(){this.destroy.next(),this.destroy.complete()}_parseCommands(_){switch(!0){case null===_:return[];case Array.isArray(_):return _;case"string"==typeof _:return[_];case _.hasOwnProperty("leaf"):return _.info[0].is_link?_.info[0].article_url?[this._linkService.getArticleLink(_.info[0].article_url)]:(this._isAbsolute=!0,[_.info[0].url]):[this._linkService.getCategoryLink(_)];case _.hasOwnProperty("date"):return[this._linkService.getArticleLink(_)];case _.hasOwnProperty("required"):return[this._linkService.getSetLink(_)];default:return[this._linkService.getProductLink(_)]}}_onClick(_,D,R,U){if(0!==_||D||R||U||this._target&&"_self"!==this._target||this._isAbsolute)return!0;const y={skipLocationChange:(0,h.he)(this._skipLocationChange),replaceUrl:(0,h.he)(this._replaceUrl)};return this._router.navigateByUrl(this.urlTree,y),!1}_updateTargetUrlAndHref(){this._href=this._isAbsolute?this._commands[0]:this._locationStrategy.prepareExternalUrl(this._router.serializeUrl(this.urlTree))}static#t=this.\u0275fac=function(D){return new(D||b)(v.rXU(n.Ix),v.rXU(n.nX),v.rXU(x.hb),v.rXU(N._))};static#e=this.\u0275dir=v.FsC({type:b,selectors:[["a","mcraiLink",""]],hostVars:2,hostBindings:function(D,R){1&D&&v.bIt("click",function(y){return R._onClick(y.button,y.ctrlKey,y.metaKey,y.shiftKey)}),2&D&&v.BMQ("target",R._target)("href",R._href,v.B4B)},inputs:{mcraiLink:"mcraiLink",href:"href",target:"target",queryParams:"queryParams",skipLocationChange:"skipLocationChange",replaceUrl:"replaceUrl",queryParamsHandling:"queryParamsHandling",fragment:"fragment"},features:[v.OA$]})}return b})()},18227:(H,M,r)=>{r.d(M,{o:()=>v});var n=r(76965),c=r(58728),u=r(19493),T=r(79341),h=r(54438);let v=(()=>{class x{constructor(I){this.store=I,this.store.pipe((0,n.Lt)(T.If),(0,c.p)(b=>!!b),(0,u.s)(1)).subscribe(b=>{this.priceType=b.show_prices,this.currency=b.active_currency})}transform(I,b=null,G=null,_=""){const U={style:"currency",currency:_||this.currency.code,minimumFractionDigits:b=null!==b?b:this.currency.decimal_places,maximumFractionDigits:G=null!==G?G:this.currency.decimal_places};Array.isArray(I)&&(I=I[this.priceType]);const y=Math.pow(10,G);
1return I=Math.round(I*y)/y,`${Number(I).toLocaleString("cs-CZ",U)}`}static#t=this.\u0275fac=function(b){return new(b||x)(h.rXU(n.il,16))};static#e=this.\u0275pipe=h.EJ8({name:"currency",type:x,pure:!0})}return x})()},52570:(H,M,r)=>{r.d(M,{s:()=>c});var n=r(54438);let c=(()=>{class u{static#t=this.LET={ZERO:1,EMPTY_STR:2,FALSE:4,NAN:8};transform(h,v=0){return v&u.LET.ZERO&&0===h||v&u.LET.EMPTY_STR&&""===h||v&u.LET.FALSE&&!1===h||v&u.LET.NAN&&isNaN(h)?h:h||"-"}static#e=this.\u0275fac=function(v){return new(v||u)};static#i=this.\u0275pipe=n.EJ8({name:"notSet",type:u,pure:!0})}return u})()},28520:(H,M,r)=>{r.d(M,{e:()=>y});var n=r(54438),c=r(49969),u=r(89417),T=r(45286),h=r(14421),v=r(45817),x=r(7605),N=r(63649),I=r(73955);let b=(()=>{class C{constructor(){this.UNITS=["B","KB","MB","GB","TB"]}transform(l){let f=0,d=l;for(;d>=1024;)d/=1024,f++;return d.toFixed(d>=10||f<1?0:1)+" "+this.UNITS[f]}static#t=this.\u0275fac=function(f){return new(f||C)};static#e=this.\u0275pipe=n.EJ8({name:"fileSize",type:C,pure:!0})}return C})();const G=["type","file"];function _(C,B){if(1&C&&(n.j41(0,"div",4),n.EFF(1),n.k0s()),2&C){const l=n.XpG();n.R7$(),n.SpI(" ",l.getFirstError()," ")}}function D(C,B){if(1&C){const l=n.RV6();n.j41(0,"li",6)(1,"div",7)(2,"p",8),n.EFF(3),n.k0s(),n.j41(4,"p",9),n.EFF(5),n.nI1(6,"fileSize"),n.k0s()(),n.j41(7,"div",10)(8,"button",11),n.bIt("click",function(){const d=n.eBV(l).$implicit,F=n.XpG(2);return n.Njj(F.removeStaged(d.name))}),n.EFF(9),n.nI1(10,"translate"),n.k0s()()()}if(2&C){const l=B.$implicit;n.R7$(3),n.JRh(null==l?null:l.name),n.R7$(2),n.JRh(n.bMT(6,3,null==l?null:l.size)),n.R7$(4),n.JRh(n.bMT(10,5,"common.remove_from_queue"))}}function R(C,B){if(1&C&&(n.j41(0,"ul",5),n.Z7z(1,D,11,7,"li",6,n.fX1),n.k0s()),2&C){const l=n.XpG();n.R7$(),n.Dyx(l.stagedFiles)}}let y=(()=>{class C{static#t=this.count=0;get control(){return this._control}set control(l){this._control=l}constructor(){this.destroy=new T.B7,this.MAX_FILE_SIZE=Math.pow(2,25),this.filesChange=new n.bkB,this.stagedFiles=[],this.isDraggingOver=!1,this.id=++C.count}ngOnInit(){}ngOnChanges(l){l.hasOwnProperty("control")&&l.control.currentValue&&(this.control.hasAsyncValidator(this.columnValidator)||this.control.addAsyncValidators([this.columnValidator]),this.control.hasValidator(this.sizeValidator)||this.control.addValidators([this.sizeValidator.bind(this)]),this.destroy.next(),this.control.valueChanges.pipe((0,x.Q)(this.destroy)).subscribe(f=>{this.stagedFiles=f?Array.isArray(f)?f:[f]:[]}))}ngOnDestroy(){this.destroy.next(),this.destroy.complete()}queueFiles(l){this.control instanceof u.hs?(l.length>0?this.control.setValue(this.isMultiple()?l:l[0]):this.control.reset(),this.control.markAsTouched(),this.control.markAsDirty()):console.warn(`Could not set controls value. ${this.control} provided as control`)}columnValidator(l){const f=l.value;if(!f||"text/csv"!==f.type)return(0,h.of)(null);const d=new FileReader,F=v.c.create(S=>{d.onloadend=()=>{const j=function U(C){const B=new Map;for(let l=0;l<C.length;l++){const f=C[l];if(B.get(f))return!0;B.set(f,1)}return!1}(d.result.split(/\r?\n/)[0].replace(/"/g,"").split(/;/g))?{duplicates:`Soubor '${f.name}' obsahuje duplicitn\xed sloupce`}:null;S.next(j),S.complete()},d.onerror=g=>S.error(g)});return d.readAsText(f),F}sizeValidator(l){let f=l.value;if(!f)return null;Array.isArray(f)||(f=[f]);for(let d=0;d<f.length;d++)if(f[d].size>this.MAX_FILE_SIZE)return{size:`Soubor '${f[d].name}' p\u0159ekra\u010duje maxim\xe1ln\xed velikost souboru`};return null}sanitazeFiles(l){return l instanceof FileList&&(l=Array.from(l)),l=this.filterOutDuplicities(l),this.filterOutCountExceedingFiles(l)}filterOutDuplicities(l){const f=new Set;return l.filter(d=>!f.has(d.name)&&(f.add(d.name),!0))}filterOutCountExceedingFiles(l){return!this.isMultiple()&&l.length>1?[l[0]]:l}onDragover(l){l.preventDefault(),l.stopPropagation()}onDragEnter(l){l.preventDefault(),l.stopPropagation(),this.isDraggingOver=!0}onDragLeave(l){l.preventDefault(),l.stopPropagation(),this.isDraggingOver=!1}onDrop(l){l.preventDefault(),l.stopPropagation(),this.isDraggingOver=!1;const f=this.sanitazeFiles(l.dataTransfer.files);this.queueFiles(f)}onChange(l){const f=this.sanitazeFiles(l.target.files);this.queueFiles(f)}isMultiple(){return typeof this.multiple<"u"}removeStaged(l){const f=this.stagedFiles.filter(d=>d.name!==l);this.queueFiles(f)}getMaxFileSize(){let l=this.MAX_FILE_SIZE,f=-1;do{l/=1024,f++}while(l>1024);return Math.max(l,.1).toFixed(1)+[" kB"," MB"," GB"," TB","PB","EB","ZB","YB"][f]}hasErrors(){return this.control.dirty&&this.control.invalid}getFirstError(){const l=Object.keys(this.control.errors);return this.errors&&this.errors.hasOwnProperty(l[0])?this.errors[l[0]]:this.control.errors[l[0]]}static#e=this.\u0275fac=function(f){return new(f||C)};static#i=this.\u0275cmp=n.VBU({type:C,selectors:[["mcrai-input","type","file"]],hostVars:4,hostBindings:function(f,d){2&f&&n.AVh("mcrai-input",!0)("mcrai-input--file",!0)},inputs:{multiple:"multiple",control:"control",errors:"errors"},outputs:{filesChange:"filesChange"},features:[n.OA$],attrs:G,decls:9,vars:15,consts:[["type","file","name","files[]","data-multiple-caption","files selected",1,"mcrai-input__file-input",3,"change","id","multiple"],["mcrai-button","",1,"mcrai-input__dropzone",3,"dragover","dragenter","dragleave","drop","for"],[1,"mcrai-input__hint",3,"innerHTML"],[1,"mcrai-input__max-file-size"],[1,"mcrai-input__error"],[1,"mcrai-input__files"],[1,"mcrai-input__file"],[1,"mcrai-input__file-info"],[1,"mcrai-input__file-name"],[1,"mcrai-input__file-size"],[1,"mcrai-input__actions"],["mcrai-button","negative",3,"click"]],template:function(f,d){1&f&&(n.j41(0,"input",0),n.bIt("change",function(S){return d.onChange(S)}),n.k0s(),n.j41(1,"label",1),n.bIt("dragover",function(S){return d.onDragover(S)})("dragenter",function(S){return d.onDragEnter(S)})("dragleave",function(S){return d.onDragLeave(S)})("drop",function(S){return d.onDrop(S)}),n.nrm(2,"p",2),n.nI1(3,"translate"),n.k0s(),n.j41(4,"div",3),n.EFF(5),n.nI1(6,"translate"),n.k0s(),n.DNE(7,_,2,1,"div",4)(8,R,3,0,"ul",5)),2&f&&(n.Y8G("id",d.id)("multiple",d.isMultiple()),n.R7$(),n.AVh("mcrai-input__dropzone--dragover",d.isDraggingOver),n.Y8G("@dropzoneSize",d.isDraggingOver||!d.stagedFiles.length)("for",d.id),n.R7$(),n.Y8G("innerHTML",n.bMT(3,11,"common.how_to_upload_files"),n.npT),n.R7$(3),n.Lme("",n.bMT(6,13,"common.max_size")," ",d.getMaxFileSize(),""),n.R7$(2),n.vxM(7,d.hasErrors()?7:-1),n.R7$(),n.vxM(8,d.stagedFiles.length>0?8:-1))},dependencies:[N.Q,I.D9,b],styles:[".mcrai-input--file{display:block}.mcrai-input__dropzone{display:flex;background-position:left top,left bottom,left top,right top;background-repeat:repeat-x,repeat-x,repeat-y,repeat-y;background-size:15px 1px,15px 1px,1px 15px,1px 15px}.mcrai-input__hint{font-style:italic;pointer-events:none;font-size:16px}.mcrai-input__file-input{width:.1px;height:.1px;opacity:0;overflow:hidden;position:absolute;z-index:-1}.mcrai-input__files{display:flex;flex-flow:row wrap;margin-top:10px}.mcrai-input__file{flex:0 0 100%;margin-bottom:2px;display:flex}.mcrai-input__file-info{flex:1}.mcrai-input__actions{flex:0 0 auto}.mcrai-input__file-size{font-size:14px}.mcrai-input__max-file-size{text-align:right;font-size:12px;margin-top:3px;font-style:italic}\n"],encapsulation:2,data:{animation:[(0,c.hZ)("dropzoneSize",[(0,c.wk)("true",(0,c.iF)({height:"200px"})),(0,c.wk)("false",(0,c.iF)({height:"80px"})),(0,c.kY)("0 => 1",(0,c.i0)("225ms cubic-bezier(0.4,0.0,1,1)")),(0,c.kY)("1 => 0",(0,c.i0)("195ms cubic-bezier(0.0,0.0,0.2,1)"))])]}})}return C})()}}]);

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.