dealposbarcode 26.45.0 → 26.46.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- import{d as F,l as xt,o as Rt,s as Wt}from"./main-62M3JO5Z.js";import{a as Mn,c as Sn,d as gn,m as mn,o as Qt}from"./chunk-DVmYwAhe.js";import{$ as gl,B as Zi,Ct as vo,D as Sl,Dt as yi$1,E as Qi,H as _t,I as Wl,J as dl,L as Xi,Mt as zr,O as Su,Ot as yl,P as Ur,Q as gd,T as Po,V as _l,W as al,X as fe,Z as fl,_ as Hl,a as Al,at as ks,b as Kr,bt as ul,et as hd,ht as si,i as Ai$1,jt as zl,mt as rp,nt as it,ot as ll,pt as rl,q as ct,r as Ac,rt as ja,s as At,st as md,t as $,u as Cl,vt as tu,w as Ol,z as Ze}from"./chunk-CZtkF-WL.js";import{Y as sc,it as xe,ot as xs}from"./chunk-CtdBLXrI.js";import{$ as Jw,Ci as zu,Dr as ml,Dt as Q1,E,Fr as od,Ft as Rh,H as Gu,Hn as fl$1,Kn as fw,Lr as ov,Pn as eb,Qn as gw,S as Db,St as Pi$1,Ti as G,Tn as cg,Ur as q1,Ut as Tg,V as Gh,W as Hb,Wt as Th,X as Jh,Yt as U1,_r as kh,_t as Ow,ai as ue,ar as hw,bi as zh,br as kw,bt as Pb,c as Ah,di as vw,ei as ti,en as Vw,er as hd$1,f as BD,fi as wb,fr as jw,ft as O1,gi as x,gn as _h,ht as Oh,ii as ub,j as F1,m as Bh,nn as W1,or as iI,pr as k1,qt as Tw,tt as L1,u as Aw,ur as jD,vi as yw,vn as bb,vt as P1,w as Du,wi as F$1,xt as Ph,yr as ko,yt as PD,z as GD}from"./chunk-LD3k3Loy.js";var fi={name:`search`,meta:{tags:[`search`,`find`,`query`,`lookup`,`discover`]},svg:{xmlns:`http://www.w3.org/2000/svg`,width:20,height:20,viewBox:`0 0 20 20`,fill:`none`},nodes:[[`path`,{d:`M8.76953 1.25C12.9226 1.25 16.2898 4.61656 16.29 8.76953C16.29 10.576 15.6515 12.2326 14.5898 13.5293L18.5303 17.4697C18.823 17.7626 18.8231 18.2374 18.5303 18.5303C18.2374 18.8231 17.7626 18.823 17.4697 18.5303L13.5293 14.5898C12.2326 15.6515 10.576 16.29 8.76953 16.29C4.61656 16.2898 1.25 12.9226 1.25 8.76953C1.25025 4.61672 4.61672 1.25025 8.76953 1.25ZM8.76953 2.75C5.44515 2.75025 2.75025 5.44514 2.75 8.76953C2.75 12.0941 5.44499 14.7898 8.76953 14.79C12.0943 14.79 14.79 12.0943 14.79 8.76953C14.7898 5.445 12.0941 2.75 8.76953 2.75Z`,fill:`currentColor`,key:`nt0lcw`}]]};var yi=(()=>{class m extends Kr{constructor(){super(),this._icon=fi}static ɵfac=function(n){return new(n||m)};static ɵcmp=(function(){let e=(r,g)=>g[1].key||r;function n(r,g){if(r&1&&(od(),kh(0,`path`)),r&2){let t=Aw().$implicit;Ah(`d`,t[1].d)(`fill`,t[1].fill)(`fill-opacity`,t[1].fillOpacity)(`fill-rule`,t[1].fillRule)(`clip-rule`,t[1].clipRule)(`stroke`,t[1].stroke)(`stroke-width`,t[1].strokeWidth)(`stroke-opacity`,t[1].strokeOpacity)(`opacity`,t[1].opacity)}}function o(r,g){if(r&1&&(od(),kh(0,`circle`)),r&2){let t=Aw().$implicit;Ah(`cx`,t[1].cx)(`cy`,t[1].cy)(`r`,t[1].r)(`fill`,t[1].fill)(`fill-opacity`,t[1].fillOpacity)(`opacity`,t[1].opacity)}}function p(r,g){if(r&1&&(od(),kh(0,`rect`)),r&2){let t=Aw().$implicit;Ah(`x`,t[1].x)(`y`,t[1].y)(`width`,t[1].width)(`height`,t[1].height)(`rx`,t[1].rx)(`ry`,t[1].ry)(`fill`,t[1].fill)(`fill-opacity`,t[1].fillOpacity)(`opacity`,t[1].opacity)}}function d(r,g){if(r&1&&(od(),kh(0,`line`)),r&2){let t=Aw().$implicit;Ah(`x1`,t[1].x1)(`y1`,t[1].y1)(`x2`,t[1].x2)(`y2`,t[1].y2)(`stroke`,t[1].stroke)(`stroke-opacity`,t[1].strokeOpacity)(`opacity`,t[1].opacity)}}function u(r,g){if(r&1&&(od(),kh(0,`polyline`)),r&2){let t=Aw().$implicit;Ah(`points`,t[1].points)(`fill`,t[1].fill)(`fill-opacity`,t[1].fillOpacity)(`opacity`,t[1].opacity)}}function C(r,g){if(r&1&&(od(),kh(0,`polygon`)),r&2){let t=Aw().$implicit;Ah(`points`,t[1].points)(`fill`,t[1].fill)(`fill-opacity`,t[1].fillOpacity)(`opacity`,t[1].opacity)}}function y(r,g){if(r&1&&(od(),kh(0,`ellipse`)),r&2){let t=Aw().$implicit;Ah(`cx`,t[1].cx)(`cy`,t[1].cy)(`rx`,t[1].rx)(`ry`,t[1].ry)(`fill`,t[1].fill)(`fill-opacity`,t[1].fillOpacity)(`opacity`,t[1].opacity)}}function V(r,g){if(r&1&&fw(0,n,1,9,`path`)(1,o,1,6,`circle`)(2,p,1,9,`rect`)(3,d,1,7,`line`)(4,u,1,4,`polyline`)(5,C,1,4,`polygon`)(6,y,1,7,`ellipse`),r&2){let t,z=g.$implicit;hw((t=z[0])===`path`?0:t===`circle`?1:t===`rect`?2:t===`line`?3:t===`polyline`?4:t===`polygon`?5:t===`ellipse`?6:-1)}}return PD({type:m,selectors:[[`svg`,`data-p-icon`,`search`]],features:[Th],decls:2,vars:0,template:function(g,t){g&1&&yw(0,V,7,1,null,null,e),g&2&&vw(t.iconNodes())},encapsulation:2,changeDetection:1})})()}return m})();var _i=class mt extends Mn{required=k1(void 0,{transform:U1});invalid=k1(void 0,{transform:U1});disabled=k1(void 0,{transform:U1});name=k1();_disabled=ti(!1);$disabled=Hb(()=>this.disabled()||this._disabled());onModelChange=()=>{};onModelTouched=()=>{};writeDisabledState(e){this._disabled.set(e)}writeControlValue(e,n){}writeValue(e){this.writeControlValue(e,this.writeModelValue.bind(this))}registerOnChange(e){this.onModelChange=e}registerOnTouched(e){this.onModelTouched=e}setDisabledState(e){this.writeDisabledState(e),this.cd.markForCheck()}static ɵfac=(()=>{let e;return function(o){return(e||(e=ov(mt)))(o||mt)}})();static ɵdir=BD({type:mt,inputs:{required:[1,`required`],invalid:[1,`invalid`],disabled:[1,`disabled`],name:[1,`name`]},features:[Th]})};var vi=class ht extends _i{pcFluid=E(Qt,{optional:!0,host:!0,skipSelf:!0});fluid=k1(void 0,{transform:U1});variant=k1();size=k1();inputSize=k1();pattern=k1();min=k1();max=k1();step=k1();minlength=k1();maxlength=k1();$variant=Hb(()=>this.variant()||this.config.inputVariant()||void 0);$pattern=Hb(()=>{let e=this.pattern();return typeof e==`string`&&e.length>0?e:void 0});get hasFluid(){return this.fluid()??!!this.pcFluid}static ɵfac=(()=>{let e;return function(o){return(e||(e=ov(ht)))(o||ht)}})();static ɵdir=BD({type:ht,inputs:{fluid:[1,`fluid`],variant:[1,`variant`],size:[1,`size`],inputSize:[1,`inputSize`],pattern:[1,`pattern`],min:[1,`min`],max:[1,`max`],step:[1,`step`],minlength:[1,`minlength`],maxlength:[1,`maxlength`]},features:[Th]})};var bi=`
1
+ import{d as F,l as xt,o as Rt,s as Wt}from"./main-BYQAQ7ZD.js";import{a as Mn,c as Sn,d as gn,m as mn,o as Qt}from"./chunk-DVmYwAhe.js";import{$ as gl,B as Zi,Ct as vo,D as Sl,Dt as yi$1,E as Qi,H as _t,I as Wl,J as dl,L as Xi,Mt as zr,O as Su,Ot as yl,P as Ur,Q as gd,T as Po,V as _l,W as al,X as fe,Z as fl,_ as Hl,a as Al,at as ks,b as Kr,bt as ul,et as hd,ht as si,i as Ai$1,jt as zl,mt as rp,nt as it,ot as ll,pt as rl,q as ct,r as Ac,rt as ja,s as At,st as md,t as $,u as Cl,vt as tu,w as Ol,z as Ze}from"./chunk-CZtkF-WL.js";import{Y as sc,it as xe,ot as xs}from"./chunk-CtdBLXrI.js";import{$ as Jw,Ci as zu,Dr as ml,Dt as Q1,E,Fr as od,Ft as Rh,H as Gu,Hn as fl$1,Kn as fw,Lr as ov,Pn as eb,Qn as gw,S as Db,St as Pi$1,Ti as G,Tn as cg,Ur as q1,Ut as Tg,V as Gh,W as Hb,Wt as Th,X as Jh,Yt as U1,_r as kh,_t as Ow,ai as ue,ar as hw,bi as zh,br as kw,bt as Pb,c as Ah,di as vw,ei as ti,en as Vw,er as hd$1,f as BD,fi as wb,fr as jw,ft as O1,gi as x,gn as _h,ht as Oh,ii as ub,j as F1,m as Bh,nn as W1,or as iI,pr as k1,qt as Tw,tt as L1,u as Aw,ur as jD,vi as yw,vn as bb,vt as P1,w as Du,wi as F$1,xt as Ph,yr as ko,yt as PD,z as GD}from"./chunk-LD3k3Loy.js";var fi={name:`search`,meta:{tags:[`search`,`find`,`query`,`lookup`,`discover`]},svg:{xmlns:`http://www.w3.org/2000/svg`,width:20,height:20,viewBox:`0 0 20 20`,fill:`none`},nodes:[[`path`,{d:`M8.76953 1.25C12.9226 1.25 16.2898 4.61656 16.29 8.76953C16.29 10.576 15.6515 12.2326 14.5898 13.5293L18.5303 17.4697C18.823 17.7626 18.8231 18.2374 18.5303 18.5303C18.2374 18.8231 17.7626 18.823 17.4697 18.5303L13.5293 14.5898C12.2326 15.6515 10.576 16.29 8.76953 16.29C4.61656 16.2898 1.25 12.9226 1.25 8.76953C1.25025 4.61672 4.61672 1.25025 8.76953 1.25ZM8.76953 2.75C5.44515 2.75025 2.75025 5.44514 2.75 8.76953C2.75 12.0941 5.44499 14.7898 8.76953 14.79C12.0943 14.79 14.79 12.0943 14.79 8.76953C14.7898 5.445 12.0941 2.75 8.76953 2.75Z`,fill:`currentColor`,key:`nt0lcw`}]]};var yi=(()=>{class m extends Kr{constructor(){super(),this._icon=fi}static ɵfac=function(n){return new(n||m)};static ɵcmp=(function(){let e=(r,g)=>g[1].key||r;function n(r,g){if(r&1&&(od(),kh(0,`path`)),r&2){let t=Aw().$implicit;Ah(`d`,t[1].d)(`fill`,t[1].fill)(`fill-opacity`,t[1].fillOpacity)(`fill-rule`,t[1].fillRule)(`clip-rule`,t[1].clipRule)(`stroke`,t[1].stroke)(`stroke-width`,t[1].strokeWidth)(`stroke-opacity`,t[1].strokeOpacity)(`opacity`,t[1].opacity)}}function o(r,g){if(r&1&&(od(),kh(0,`circle`)),r&2){let t=Aw().$implicit;Ah(`cx`,t[1].cx)(`cy`,t[1].cy)(`r`,t[1].r)(`fill`,t[1].fill)(`fill-opacity`,t[1].fillOpacity)(`opacity`,t[1].opacity)}}function p(r,g){if(r&1&&(od(),kh(0,`rect`)),r&2){let t=Aw().$implicit;Ah(`x`,t[1].x)(`y`,t[1].y)(`width`,t[1].width)(`height`,t[1].height)(`rx`,t[1].rx)(`ry`,t[1].ry)(`fill`,t[1].fill)(`fill-opacity`,t[1].fillOpacity)(`opacity`,t[1].opacity)}}function d(r,g){if(r&1&&(od(),kh(0,`line`)),r&2){let t=Aw().$implicit;Ah(`x1`,t[1].x1)(`y1`,t[1].y1)(`x2`,t[1].x2)(`y2`,t[1].y2)(`stroke`,t[1].stroke)(`stroke-opacity`,t[1].strokeOpacity)(`opacity`,t[1].opacity)}}function u(r,g){if(r&1&&(od(),kh(0,`polyline`)),r&2){let t=Aw().$implicit;Ah(`points`,t[1].points)(`fill`,t[1].fill)(`fill-opacity`,t[1].fillOpacity)(`opacity`,t[1].opacity)}}function C(r,g){if(r&1&&(od(),kh(0,`polygon`)),r&2){let t=Aw().$implicit;Ah(`points`,t[1].points)(`fill`,t[1].fill)(`fill-opacity`,t[1].fillOpacity)(`opacity`,t[1].opacity)}}function y(r,g){if(r&1&&(od(),kh(0,`ellipse`)),r&2){let t=Aw().$implicit;Ah(`cx`,t[1].cx)(`cy`,t[1].cy)(`rx`,t[1].rx)(`ry`,t[1].ry)(`fill`,t[1].fill)(`fill-opacity`,t[1].fillOpacity)(`opacity`,t[1].opacity)}}function V(r,g){if(r&1&&fw(0,n,1,9,`path`)(1,o,1,6,`circle`)(2,p,1,9,`rect`)(3,d,1,7,`line`)(4,u,1,4,`polyline`)(5,C,1,4,`polygon`)(6,y,1,7,`ellipse`),r&2){let t,z=g.$implicit;hw((t=z[0])===`path`?0:t===`circle`?1:t===`rect`?2:t===`line`?3:t===`polyline`?4:t===`polygon`?5:t===`ellipse`?6:-1)}}return PD({type:m,selectors:[[`svg`,`data-p-icon`,`search`]],features:[Th],decls:2,vars:0,template:function(g,t){g&1&&yw(0,V,7,1,null,null,e),g&2&&vw(t.iconNodes())},encapsulation:2,changeDetection:1})})()}return m})();var _i=class mt extends Mn{required=k1(void 0,{transform:U1});invalid=k1(void 0,{transform:U1});disabled=k1(void 0,{transform:U1});name=k1();_disabled=ti(!1);$disabled=Hb(()=>this.disabled()||this._disabled());onModelChange=()=>{};onModelTouched=()=>{};writeDisabledState(e){this._disabled.set(e)}writeControlValue(e,n){}writeValue(e){this.writeControlValue(e,this.writeModelValue.bind(this))}registerOnChange(e){this.onModelChange=e}registerOnTouched(e){this.onModelTouched=e}setDisabledState(e){this.writeDisabledState(e),this.cd.markForCheck()}static ɵfac=(()=>{let e;return function(o){return(e||(e=ov(mt)))(o||mt)}})();static ɵdir=BD({type:mt,inputs:{required:[1,`required`],invalid:[1,`invalid`],disabled:[1,`disabled`],name:[1,`name`]},features:[Th]})};var vi=class ht extends _i{pcFluid=E(Qt,{optional:!0,host:!0,skipSelf:!0});fluid=k1(void 0,{transform:U1});variant=k1();size=k1();inputSize=k1();pattern=k1();min=k1();max=k1();step=k1();minlength=k1();maxlength=k1();$variant=Hb(()=>this.variant()||this.config.inputVariant()||void 0);$pattern=Hb(()=>{let e=this.pattern();return typeof e==`string`&&e.length>0?e:void 0});get hasFluid(){return this.fluid()??!!this.pcFluid}static ɵfac=(()=>{let e;return function(o){return(e||(e=ov(ht)))(o||ht)}})();static ɵdir=BD({type:ht,inputs:{fluid:[1,`fluid`],variant:[1,`variant`],size:[1,`size`],inputSize:[1,`inputSize`],pattern:[1,`pattern`],min:[1,`min`],max:[1,`max`],step:[1,`step`],minlength:[1,`minlength`],maxlength:[1,`maxlength`]},features:[Th]})};var bi=`
2
2
  .p-iconfield {
3
3
  position: relative;
4
4
  display: block;
@@ -1 +1 @@
1
- import{n as dr,t as Ac}from"./chunk-DrXyB4Sl.js";import"./chunk-DlUaBLQM.js";import"./main-62M3JO5Z.js";import{t as i}from"./chunk-CKXRHkCI.js";import{t as h}from"./chunk-CyE7pq6Z.js";import{f as gr,h as qr}from"./chunk-DVmYwAhe.js";import"./chunk-CZtkF-WL.js";import"./chunk-DAfeU1o0.js";import"./chunk-CtdBLXrI.js";import{E as E$1,Ft as Rh,Hn as fl,St as Pi,Tn as cg,bt as Pb,ei as ti,fi as wb,gn as _h,ii as ub,or as iI,qr as ql,u as Aw,yt as PD}from"./chunk-LD3k3Loy.js";var E=()=>({"min-width":`50rem`});function D(t,p){}function G(t,p){t&1&&(Pi(0,`tr`)(1,`th`),ub(2,`Name`),fl(),Pi(3,`th`),ub(4,`Desc`),fl()())}function T(t,p){if(t&1&&(Pi(0,`tr`)(1,`td`)(2,`span`),ub(3),fl()(),Pi(4,`td`)(5,`span`),ub(6),fl()()()),t&2){let e=p.$implicit;iI(3),cg(e.Name),iI(3),cg(e.Description)}}function L(t,p){if(t&1&&(Pi(0,`p-panel`)(1,`p-table`,5),_h(2,G,5,0,`ng-template`,null,2,Pb)(4,T,7,2,`ng-template`,null,3,Pb),fl()()),t&2){let e=Aw();iI(),Rh(`value`,e.groupList())(`tableStyle`,wb(2,E))}}var K=(()=>{class t{constructor(){this.setupUserService=E$1(h),this.groupList=ti([])}ngOnInit(){this.setupUserService.getGroupList().pipe(i(`Groups`),ql(e=>this.groupList.set(e.Data))).subscribe()}static{this.ɵfac=function(l){return new(l||t)}}static{this.ɵcmp=PD({type:t,selectors:[[`app-groups`]],decls:5,vars:0,consts:[[`actionButton`,``],[`content`,``],[`header`,``],[`body`,``],[`pageTitle`,`Users`],[`dataKey`,`UserID`,3,`value`,`tableStyle`]],template:function(l,M){l&1&&(Pi(0,`app-main-panel`,4),_h(1,D,0,0,`ng-template`,null,0,Pb)(3,L,6,3,`ng-template`,null,1,Pb),fl())},dependencies:[gr,qr,Ac,dr],styles:[`.p-datatable .p-datatable-thead tr th{background-color:#f6f6f6!important}`],changeDetection:1})}}return t})();export{K as GroupsComponent};
1
+ import{n as dr,t as Ac}from"./chunk-BgXzf6k9.js";import"./chunk-BJp2hZ3i.js";import"./main-BYQAQ7ZD.js";import{t as i}from"./chunk-CKXRHkCI.js";import{t as h}from"./chunk-CyE7pq6Z.js";import{f as gr,h as qr}from"./chunk-DVmYwAhe.js";import"./chunk-CZtkF-WL.js";import"./chunk-DAfeU1o0.js";import"./chunk-CtdBLXrI.js";import{E as E$1,Ft as Rh,Hn as fl,St as Pi,Tn as cg,bt as Pb,ei as ti,fi as wb,gn as _h,ii as ub,or as iI,qr as ql,u as Aw,yt as PD}from"./chunk-LD3k3Loy.js";var E=()=>({"min-width":`50rem`});function D(t,p){}function G(t,p){t&1&&(Pi(0,`tr`)(1,`th`),ub(2,`Name`),fl(),Pi(3,`th`),ub(4,`Desc`),fl()())}function T(t,p){if(t&1&&(Pi(0,`tr`)(1,`td`)(2,`span`),ub(3),fl()(),Pi(4,`td`)(5,`span`),ub(6),fl()()()),t&2){let e=p.$implicit;iI(3),cg(e.Name),iI(3),cg(e.Description)}}function L(t,p){if(t&1&&(Pi(0,`p-panel`)(1,`p-table`,5),_h(2,G,5,0,`ng-template`,null,2,Pb)(4,T,7,2,`ng-template`,null,3,Pb),fl()()),t&2){let e=Aw();iI(),Rh(`value`,e.groupList())(`tableStyle`,wb(2,E))}}var K=(()=>{class t{constructor(){this.setupUserService=E$1(h),this.groupList=ti([])}ngOnInit(){this.setupUserService.getGroupList().pipe(i(`Groups`),ql(e=>this.groupList.set(e.Data))).subscribe()}static{this.ɵfac=function(l){return new(l||t)}}static{this.ɵcmp=PD({type:t,selectors:[[`app-groups`]],decls:5,vars:0,consts:[[`actionButton`,``],[`content`,``],[`header`,``],[`body`,``],[`pageTitle`,`Users`],[`dataKey`,`UserID`,3,`value`,`tableStyle`]],template:function(l,M){l&1&&(Pi(0,`app-main-panel`,4),_h(1,D,0,0,`ng-template`,null,0,Pb)(3,L,6,3,`ng-template`,null,1,Pb),fl())},dependencies:[gr,qr,Ac,dr],styles:[`.p-datatable .p-datatable-thead tr th{background-color:#f6f6f6!important}`],changeDetection:1})}}return t})();export{K as GroupsComponent};
@@ -0,0 +1,63 @@
1
+ import{_ as W,a as In,b as Z,v as Xt$1,x as eu}from"./main-BYQAQ7ZD.js";import{t as D}from"./chunk-CUqJO8Ae.js";import{a as dj,i as bV,n as Rg,o as rd,r as Ul,s as vz,t as Hl}from"./chunk-CjR2BAfc.js";import"./chunk-BUsg5rFD.js";import"./chunk-BJp2hZ3i.js";import{t as i}from"./chunk-CKXRHkCI.js";import{c as Sn,f as gr,i as Gn,n as An,r as Ee,t as $n}from"./chunk-DVmYwAhe.js";import{$ as gl,At as ze,Dt as yi,I as Wl,J as dl,O as Su,Q as gd,X as fe,Y as el,Z as fl,et as hd,j as Tl,q as ct,r as Ac,s as At$1,w as Ol,wt as vu,y as Ji,z as Ze}from"./chunk-CZtkF-WL.js";import"./chunk-DAfeU1o0.js";import{D as Xi,F as fh,K as oh,P as dh,R as hh,S as Tl$1,X as sh,Y as sc,a as Fs,h as Ns,i as Fo,ot as xs,tt as vl,w as Us}from"./chunk-CtdBLXrI.js";import{$ as Jw,$n as hb,B as GI,Ci as zu,Dr as ml,E,Ft as Rh,Gn as fs,H as Gu,Hn as fl$1,Kn as fw,Lr as ov,Ot as QI,Pn as eb,Pr as oE,Qr as sm,S as Db,St as Pi,Ti as G,Tn as cg,V as Gh,Vn as fg,Vr as pm,W as Hb,Wt as Th,Yn as gl$1,Yt as U1,_t as Ow,ai as ue,ar as hw,br as kw,bt as Pb,c as Ah,di as vw,ei as ti$1,en as Vw,fi as wb,fr as jw,ft as O1,gi as x,gn as _h,ht as Oh,i as $e,ii as ub,j as F1,ji as M,jn as ds,kn as dg,m as Bh,mt as Ob,nn as W1,o as Ab,on as Xi$1,or as iI,pr as k1,qr as ql,qt as Tw,u as Aw,ur as jD,vi as yw,vn as bb,w as Du,wi as F,xt as Ph,yt as PD,z as GD}from"./chunk-LD3k3Loy.js";var Dt=`
2
+ .p-popover {
3
+ margin-block-start: dt('popover.gutter');
4
+ background: dt('popover.background');
5
+ color: dt('popover.color');
6
+ border: 1px solid dt('popover.border.color');
7
+ border-radius: dt('popover.border.radius');
8
+ box-shadow: dt('popover.shadow');
9
+ will-change: transform;
10
+ }
11
+
12
+ .p-popover-content {
13
+ padding: dt('popover.content.padding');
14
+ }
15
+
16
+ .p-popover-flipped {
17
+ margin-block-start: calc(dt('popover.gutter') * -1);
18
+ margin-block-end: dt('popover.gutter');
19
+ }
20
+
21
+ .p-popover:after,
22
+ .p-popover:before {
23
+ bottom: 100%;
24
+ left: calc(dt('popover.arrow.offset') + dt('popover.arrow.left', '0px'));
25
+ content: ' ';
26
+ height: 0;
27
+ width: 0;
28
+ position: absolute;
29
+ pointer-events: none;
30
+ }
31
+
32
+ .p-popover:after {
33
+ border-width: calc(dt('popover.gutter') - 2px);
34
+ margin-left: calc(-1 * (dt('popover.gutter') - 2px));
35
+ border-style: solid;
36
+ border-color: transparent;
37
+ border-bottom-color: dt('popover.background');
38
+ }
39
+
40
+ .p-popover:before {
41
+ border-width: dt('popover.gutter');
42
+ margin-left: calc(-1 * dt('popover.gutter'));
43
+ border-style: solid;
44
+ border-color: transparent;
45
+ border-bottom-color: dt('popover.border.color');
46
+ }
47
+
48
+ .p-popover-flipped:after,
49
+ .p-popover-flipped:before {
50
+ bottom: auto;
51
+ top: 100%;
52
+ }
53
+
54
+ .p-popover.p-popover-flipped:after {
55
+ border-bottom-color: transparent;
56
+ border-top-color: dt('popover.background');
57
+ }
58
+
59
+ .p-popover.p-popover-flipped:before {
60
+ border-bottom-color: transparent;
61
+ border-top-color: dt('popover.border.color');
62
+ }
63
+ `;var Ht={root:({instance:i})=>F({position:`absolute`},i.style())};var Bt={root:`p-popover p-component`,content:`p-popover-content`};var Et=class Z extends fe{name=`popover`;style=Dt;classes=Bt;inlineStyles=Ht;static ɵfac=(()=>{let e;return function(r){return(e||(e=ov(Z)))(r||Z)}})();static ɵprov=ue({token:Z,factory:Z.ɵfac})};var Nt=new x(`POPOVER_INSTANCE`);var At=class j extends ct{componentName=`Popover`;$pcPopover=E(Nt,{optional:!0,skipSelf:!0})??void 0;bindDirectiveInstance=E(Ze,{self:!0});ariaLabel=k1();ariaLabelledBy=k1();dismissable=k1(!0,{transform:U1});style=k1();styleClass=k1();appendTo=k1(`body`);autoZIndex=k1(!0,{transform:U1});ariaCloseLabel=k1();baseZIndex=k1(0,{transform:W1});focusOnShow=k1(!0,{transform:U1});motionOptions=k1(void 0);computedMotionOptions=Hb(()=>F(F({},this.ptm(`motion`)),this.motionOptions()));onShow=O1();onHide=O1();$appendTo=Hb(()=>this.appendTo()||this.config.overlayAppendTo());container;overlayVisible=ti$1(!1);render=ti$1(!1);selfClick=!1;documentClickListener;target=null;willHide;scrollHandler;documentResizeListener;contentTemplate=F1(`content`,{descendants:!1});onCloseClickCallback=this.onCloseClick.bind(this);contentTemplateContext=Hb(()=>({closeCallback:this.onCloseClickCallback}));destroyCallback;overlayEventListener;overlaySubscription;_componentStyle=E(Et);overlayService=E(Wl);onAfterViewChecked(){this.bindDirectiveInstance.setAttrs(this.ptm(`host`))}bindDocumentClickListener(){if(sc(this.platformId)&&!this.documentClickListener){let e=Tl()?`touchstart`:`click`,t=this.el?this.el.nativeElement.ownerDocument:this.document;this.documentClickListener=this.renderer.listen(t,e,r=>{if(!this.dismissable())return;let a=gd(r,this.container),h=gd(r,this.target);!this.container?.contains(a)&&this.target!==h&&!this.target?.contains(h)&&!this.selfClick&&this.hide(),this.selfClick=!1})}}unbindDocumentClickListener(){this.documentClickListener&&(this.documentClickListener(),this.documentClickListener=null,this.selfClick=!1)}toggle(e,t){this.overlayVisible()?(this.hasTargetChanged(e,t)&&(this.destroyCallback=()=>{this.show(null,t||e.currentTarget||e.target)}),this.hide()):this.show(e,t)}show(e,t){t&&e&&e.stopPropagation(),this.container&&!this.overlayVisible()&&(this.container=null),this.target=t||e.currentTarget||e.target,this.overlayVisible.set(!0),this.render.set(!0)}onOverlayClick(e){this.overlayService.add({originalEvent:e,target:this.el.nativeElement}),this.selfClick=!0}onContentClick(e){let t=e.target;this.selfClick=e.offsetX<t.clientWidth&&e.offsetY<t.clientHeight}hasTargetChanged(e,t){return this.target!=null&&this.target!==(t||e.currentTarget||e.target)}appendOverlay(){this.$appendTo()&&this.$appendTo()!==`self`&&(this.$appendTo()===`body`?fl(this.$overlayParent(this.document.body,this.container),this.container):fl(this.$overlayParent(this.$appendTo(),this.container),this.container))}restoreAppend(){this.container&&this.$appendTo()&&this.$appendTo()!==`self`&&fl(this.el.nativeElement,this.container)}setZIndex(){this.autoZIndex()&&Ac.set(`overlay`,this.container,this.baseZIndex()+this.config.zIndex.overlay)}align(){if(this.target&&this.container){dl(this.container,this.target,!1);let e=Ji(this.container),t=Ji(this.target),r=e.left,a=e.top,h=t.left,m=t.top,f=this.document.defaultView?.getComputedStyle(this.container).getPropertyValue(`border-radius`),l=0;r<h&&(l=h-r-parseFloat(f)*2),this.container.style.setProperty(this.$styleScope.resolvers.$dt(`popover.arrow.left`).name,`${l}px`),a<m&&(this.container.setAttribute(`data-p-popover-flipped`,`true`),this.$unstyled()||ze(this.container,this.pcn(`p-popover-flipped`)))}}onAnimationStart(e){this.container=e.element,this.$markInstance(this.container),this.appendOverlay(),this.align(),this.setZIndex(),this.bindDocumentClickListener(),this.bindDocumentResizeListener(),this.bindScrollListener(),this.focusOnShow()&&this.focus(),this.overlayEventListener=t=>{this.container&&this.container.contains(t.target)&&(this.selfClick=!0)},this.overlaySubscription=this.overlayService.clickObservable.subscribe(this.overlayEventListener),this.onShow.emit(null)}onAnimationEnd(){this.overlayVisible()||(this.destroyCallback&&(this.destroyCallback(),this.destroyCallback=null),this.overlaySubscription&&this.overlaySubscription.unsubscribe(),this.autoZIndex()&&Ac.clear(this.container),this.onContainerDestroy(),this.onHide.emit({}),this.render.set(!1),this.container=null)}focus(){let e=gl(this.container,`[autofocus]`);e&&setTimeout(()=>e.focus(),5)}hide(){this.overlayVisible.set(!1)}onCloseClick(e){this.hide(),e.preventDefault()}onEscapeKeydown(e){this.hide()}onWindowResize(){this.overlayVisible()&&!Ol()&&this.hide()}bindDocumentResizeListener(){if(sc(this.platformId)&&!this.documentResizeListener){let e=this.document.defaultView;this.documentResizeListener=this.renderer.listen(e,`resize`,this.onWindowResize.bind(this))}}unbindDocumentResizeListener(){this.documentResizeListener&&(this.documentResizeListener(),this.documentResizeListener=null)}bindScrollListener(){sc(this.platformId)&&(this.scrollHandler||(this.scrollHandler=new hd(this.target,()=>{this.overlayVisible()&&this.hide()})),this.scrollHandler.bindScrollListener())}unbindScrollListener(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()}onContainerDestroy(){this.cd.destroyed||(this.target=null),this.unbindDocumentClickListener(),this.unbindDocumentResizeListener(),this.unbindScrollListener()}onDestroy(){this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null),this.container&&this.autoZIndex()&&Ac.clear(this.container),this.cd.destroyed||(this.target=null),this.destroyCallback=null,this.container&&(this.restoreAppend(),this.onContainerDestroy()),this.overlaySubscription&&this.overlaySubscription.unsubscribe()}static ɵfac=(()=>{let e;return function(r){return(e||(e=ov(j)))(r||j)}})();static ɵcmp=(function(){let e=[`content`],t=[`*`];function r(m,f){m&1&&Ph(0)}function a(m,f){if(m&1&&_h(0,r,1,0,`ng-container`,3),m&2){let l=Aw(2);Rh(`ngTemplateOutlet`,l.contentTemplate())(`ngTemplateOutletContext`,l.contentTemplateContext())}}function h(m,f){if(m&1){let l=Tw();Pi(0,`div`,1),Bh(`click`,function(g){Gu(l);let D=Aw();return zu(D.onOverlayClick(g))})(`pMotionOnEnter`,function(g){Gu(l);let D=Aw();return zu(D.onAnimationStart(g))})(`pMotionOnAfterLeave`,function(){Gu(l);let g=Aw();return zu(g.onAnimationEnd())}),Pi(1,`div`,2),Bh(`click`,function(g){Gu(l);let D=Aw();return zu(D.onContentClick(g))})(`mousedown`,function(g){Gu(l);let D=Aw();return zu(D.onContentClick(g))}),kw(2),fw(3,a,1,2,`ng-container`),fl$1()()}if(m&2){let l=Aw();Jw(l.sx(`root`)),eb(l.cn(l.cx(`root`),l.styleClass())),Rh(`pBind`,l.ptm(`root`))(`pMotion`,l.overlayVisible())(`pMotionName`,l.pcn(`p-anchored-overlay`))(`pMotionAppear`,!0)(`pMotionOptions`,l.computedMotionOptions()),Ah(`aria-modal`,l.overlayVisible())(`aria-label`,l.ariaLabel())(`aria-labelledBy`,l.ariaLabelledBy()),iI(),eb(l.cx(`content`)),Rh(`pBind`,l.ptm(`content`)),iI(2),hw(l.contentTemplate()?3:-1)}}return PD({type:j,selectors:[[`p-popover`]],contentQueries:function(f,l,M){f&1&&Gh(M,l.contentTemplate,e,4),f&2&&jw()},hostBindings:function(f,l){f&1&&Bh(`keydown.escape`,function(g){return l.onEscapeKeydown(g)},oE)},inputs:{ariaLabel:[1,`ariaLabel`],ariaLabelledBy:[1,`ariaLabelledBy`],dismissable:[1,`dismissable`],style:[1,`style`],styleClass:[1,`styleClass`],appendTo:[1,`appendTo`],autoZIndex:[1,`autoZIndex`],ariaCloseLabel:[1,`ariaCloseLabel`],baseZIndex:[1,`baseZIndex`],focusOnShow:[1,`focusOnShow`],motionOptions:[1,`motionOptions`]},outputs:{onShow:`onShow`,onHide:`onHide`},features:[Db([Et,{provide:Nt,useExisting:j},{provide:At$1,useExisting:j}]),GD([Ze]),Th],ngContentSelectors:t,decls:1,vars:1,consts:[[`role`,`dialog`,3,`pBind`,`class`,`style`,`pMotion`,`pMotionName`,`pMotionAppear`,`pMotionOptions`],[`role`,`dialog`,3,`click`,`pMotionOnEnter`,`pMotionOnAfterLeave`,`pBind`,`pMotion`,`pMotionName`,`pMotionAppear`,`pMotionOptions`],[3,`click`,`mousedown`,`pBind`],[4,`ngTemplateOutlet`,`ngTemplateOutletContext`]],template:function(f,l){f&1&&(Ow(),fw(0,h,4,16,`div`,0)),f&2&&hw(l.render()?0:-1)},dependencies:[xs,yi,Ze,Su,vu],encapsulation:2})})()};var Ot=class ke{static ɵfac=function(t){return new(t||ke)};static ɵmod=jD({type:ke});static ɵinj=Du({imports:[At,yi,yi]})};var Vt=(i,u,e=0)=>{let t=10**e,r=i*t,a;switch(u){case`floor`:a=Math.floor(r);break;case`ceil`:a=Math.ceil(r);break;default:a=Math.round(r)}return a/t};var ve=(i,u=96,e=`ceil`,t=0)=>{return Vt(i*37.7952755906,e,t)};var z=(i,u=96,e=`ceil`,t=0)=>{return Vt(i*.0264583333,e,t)};var Lt=(()=>{class i{constructor(){this.form=k1(),this.onSubmit=O1()}onSubmitHandler(){this.onSubmit.emit(this.form().getRawValue())}static{this.ɵfac=function(t){return new(t||i)}}static{this.ɵcmp=PD({type:i,selectors:[[`app-dialog-form-create`]],inputs:{form:[1,`form`]},outputs:{onSubmit:`onSubmit`},decls:57,vars:7,consts:[[1,`row`,`row-gap-2`,3,`formGroup`],[1,`col-12`],[1,`form-group`],[`for`,``,1,`fs-3`,`fw-semibold`],[`formControlName`,`name`,`type`,`text`,`pInputText`,``,1,`form-control`],[1,`col-6`],[`appMaskNumber`,``,`postfix`,``,`formControlName`,`paperWidthCM`,`pInputText`,``,3,`precision`],[`appMaskNumber`,``,`postfix`,``,`formControlName`,`paperWidth`,`pInputText`,``,3,`precision`],[`appMaskNumber`,``,`postfix`,``,`formControlName`,`stickerWidthCM`,`pInputText`,``,3,`precision`],[`appMaskNumber`,``,`postfix`,``,`formControlName`,`stickerWidth`,`pInputText`,``,3,`precision`],[`appMaskNumber`,``,`postfix`,``,`formControlName`,`stickerHeightCM`,`pInputText`,``,3,`precision`],[`appMaskNumber`,``,`postfix`,``,`formControlName`,`stickerHeight`,`pInputText`,``,3,`precision`]],template:function(t,r){t&1&&(Pi(0,`div`,0)(1,`div`,1)(2,`div`,2)(3,`label`,3),ub(4,`Label Name`),fl$1(),Pi(5,`input`,4),GI(),fl$1()()(),Pi(6,`div`,5)(7,`div`,2)(8,`label`,3),ub(9,`Paper Width`),fl$1(),Pi(10,`p-inputgroup`)(11,`input`,6),GI(),fl$1(),Pi(12,`p-inputgroup-addon`)(13,`span`),ub(14,`cm`),fl$1()()()()(),Pi(15,`div`,5)(16,`div`,2),Oh(17,`label`,3),Pi(18,`p-inputgroup`)(19,`input`,7),GI(),fl$1(),Pi(20,`p-inputgroup-addon`)(21,`span`),ub(22,`px`),fl$1()()()()(),Pi(23,`div`,5)(24,`div`,2)(25,`label`,3),ub(26,`Sticker Width`),fl$1(),Pi(27,`p-inputgroup`)(28,`input`,8),GI(),fl$1(),Pi(29,`p-inputgroup-addon`)(30,`span`),ub(31,`cm`),fl$1()()()()(),Pi(32,`div`,5)(33,`div`,2),Oh(34,`label`,3),Pi(35,`p-inputgroup`)(36,`input`,9),GI(),fl$1(),Pi(37,`p-inputgroup-addon`)(38,`span`),ub(39,`px`),fl$1()()()()(),Pi(40,`div`,5)(41,`div`,2)(42,`label`,3),ub(43,`Sticker Height`),fl$1(),Pi(44,`p-inputgroup`)(45,`input`,10),GI(),fl$1(),Pi(46,`p-inputgroup-addon`)(47,`span`),ub(48,`cm`),fl$1()()()()(),Pi(49,`div`,5)(50,`div`,2),Oh(51,`label`,3),Pi(52,`p-inputgroup`)(53,`input`,11),GI(),fl$1(),Pi(54,`p-inputgroup-addon`)(55,`span`),ub(56,`px`),fl$1()()()()()()),t&2&&(Rh(`formGroup`,r.form()),iI(5),QI(),iI(6),Rh(`precision`,2),QI(),iI(8),Rh(`precision`,2),QI(),iI(9),Rh(`precision`,2),QI(),iI(8),Rh(`precision`,2),QI(),iI(9),Rh(`precision`,2),QI(),iI(8),Rh(`precision`,2),QI())},dependencies:[fh,Fo,oh,sh,vl,Tl$1,$n,Gn,Sn,Ul],encapsulation:2,changeDetection:1})}}return i})();var Ft=(()=>{class i{constructor(){this.form=k1(),this.onSubmit=O1()}onSubmitHandler(){this.onSubmit.emit(this.form().getRawValue())}static{this.ɵfac=function(t){return new(t||i)}}static{this.ɵcmp=PD({type:i,selectors:[[`app-dialog-form-edit`]],inputs:{form:[1,`form`]},outputs:{onSubmit:`onSubmit`},decls:57,vars:7,consts:[[1,`row`,`row-gap-2`,3,`formGroup`],[1,`col-12`],[1,`form-group`],[`for`,``,1,`fs-3`,`fw-semibold`],[`formControlName`,`name`,`type`,`text`,`pInputText`,``,1,`form-control`],[1,`col-6`],[`appMaskNumber`,``,`postfix`,``,`formControlName`,`paperWidthCM`,`pInputText`,``,3,`precision`],[`appMaskNumber`,``,`postfix`,``,`formControlName`,`paperWidth`,`pInputText`,``,3,`precision`],[`appMaskNumber`,``,`postfix`,``,`formControlName`,`stickerWidthCM`,`pInputText`,``,3,`precision`],[`appMaskNumber`,``,`postfix`,``,`formControlName`,`stickerWidth`,`pInputText`,``,3,`precision`],[`appMaskNumber`,``,`postfix`,``,`formControlName`,`stickerHeightCM`,`pInputText`,``,3,`precision`],[`appMaskNumber`,``,`postfix`,``,`formControlName`,`stickerHeight`,`pInputText`,``,3,`precision`]],template:function(t,r){t&1&&(Pi(0,`div`,0)(1,`div`,1)(2,`div`,2)(3,`label`,3),ub(4,`Label Name`),fl$1(),Pi(5,`input`,4),GI(),fl$1()()(),Pi(6,`div`,5)(7,`div`,2)(8,`label`,3),ub(9,`Paper Width`),fl$1(),Pi(10,`p-inputgroup`)(11,`input`,6),GI(),fl$1(),Pi(12,`p-inputgroup-addon`)(13,`span`),ub(14,`cm`),fl$1()()()()(),Pi(15,`div`,5)(16,`div`,2),Oh(17,`label`,3),Pi(18,`p-inputgroup`)(19,`input`,7),GI(),fl$1(),Pi(20,`p-inputgroup-addon`)(21,`span`),ub(22,`px`),fl$1()()()()(),Pi(23,`div`,5)(24,`div`,2)(25,`label`,3),ub(26,`Sticker Width`),fl$1(),Pi(27,`p-inputgroup`)(28,`input`,8),GI(),fl$1(),Pi(29,`p-inputgroup-addon`)(30,`span`),ub(31,`cm`),fl$1()()()()(),Pi(32,`div`,5)(33,`div`,2),Oh(34,`label`,3),Pi(35,`p-inputgroup`)(36,`input`,9),GI(),fl$1(),Pi(37,`p-inputgroup-addon`)(38,`span`),ub(39,`px`),fl$1()()()()(),Pi(40,`div`,5)(41,`div`,2)(42,`label`,3),ub(43,`Sticker Height`),fl$1(),Pi(44,`p-inputgroup`)(45,`input`,10),GI(),fl$1(),Pi(46,`p-inputgroup-addon`)(47,`span`),ub(48,`cm`),fl$1()()()()(),Pi(49,`div`,5)(50,`div`,2),Oh(51,`label`,3),Pi(52,`p-inputgroup`)(53,`input`,11),GI(),fl$1(),Pi(54,`p-inputgroup-addon`)(55,`span`),ub(56,`px`),fl$1()()()()()()),t&2&&(Rh(`formGroup`,r.form()),iI(5),QI(),iI(6),Rh(`precision`,2),QI(),iI(8),Rh(`precision`,2),QI(),iI(9),Rh(`precision`,2),QI(),iI(8),Rh(`precision`,2),QI(),iI(9),Rh(`precision`,2),QI(),iI(8),Rh(`precision`,2),QI())},dependencies:[fh,Fo,oh,sh,vl,Tl$1,Sn,$n,Gn,Ul],encapsulation:2,changeDetection:1})}}return i})();var jt=()=>({width:`35rem`});var $t=i=>({"border border-primary":i});var qt=()=>({class:`py-1`});var Zt=i=>({root:i});var zt=(i,u)=>u.ID;function Gt(i,u){if(i&1){let e=Tw();Pi(0,`div`,8)(1,`p-button`,9),Bh(`click`,function(){Gu(e);let r=Aw();return zu(r.openCreate())}),fl$1()()}if(i&2){let e=Aw();iI(),Rh(`disabled`,!e.isUserAdmin)}}function Ut(i,u){if(i&1){let e=Tw();Pi(0,`input`,22),Bh(`change`,function(){Gu(e);let r=Aw(2).$implicit,a=Aw(2);return zu(a.onSelectionChange(r.ID))}),fl$1()}if(i&2){let e=Aw(2).$implicit,t=Aw(2);Rh(`value`,e.ID)(`checked`,t.selectedTemplateId()===e.ID)}}function Kt(i,u){if(i&1&&(Pi(0,`div`,19)(1,`div`,20)(2,`span`),ub(3),fl$1()(),Pi(4,`div`,16),fw(5,Ut,1,2,`input`,21),fl$1()()),i&2){let e=Aw().$implicit,t=Aw(2);iI(3),cg(e.ConfigObject.Name),iI(2),hw(t.selectedTemplateId()===e.ID?5:-1)}}function Jt(i,u){if(i&1&&(gl$1(0),Pi(1,`span`),ub(2),Ab(3,`number`),fl$1(),Pi(4,`span`),ub(5,`/`),fl$1(),Xi$1()),i&2){let e=Aw().$implicit;iI(2),ml(``,Ob(3,1,e.ConfigObject.PaperWidthCM),`cm`)}}function Qt(i,u){if(i&1&&(gl$1(0),Pi(1,`span`),ub(2),Ab(3,`number`),fl$1(),Pi(4,`span`),ub(5,`/`),fl$1(),Xi$1()),i&2){let e=Aw().$implicit;iI(2),ml(``,Ob(3,1,e.ConfigObject.StickerWidthCM),`cm`)}}function Xt(i,u){if(i&1&&(gl$1(0),Pi(1,`span`),ub(2),Ab(3,`number`),fl$1(),Pi(4,`span`),ub(5,`/`),fl$1(),Xi$1()),i&2){let e=Aw().$implicit;iI(2),ml(``,Ob(3,1,e.ConfigObject.StickerHeightCM),`cm`)}}function Yt(i,u){if(i&1){let e=Tw();Pi(0,`div`,23)(1,`p-button`,24),Bh(`onClick`,function(r){Gu(e);let a=Vw(3),h=Aw().$implicit,m=Aw(2);return zu(m.onMenuToggle(r,a,h.ID))}),fl$1(),Oh(2,`p-menu`,25,4),fl$1()}if(i&2){let e=Aw(3);iI(),Rh(`outlined`,!0)(`pt`,bb(5,Zt,wb(4,qt))),iI(),Rh(`model`,e.menuItems())(`popup`,!0)}}function ei(i,u){if(i&1){let e=Tw();Pi(0,`div`,12)(1,`p-card`,13),Bh(`click`,function(){let r=Gu(e).$implicit,a=Aw(2);return zu(a.onSelectionChange(r.ID))}),_h(2,Kt,6,2,`ng-template`,null,3,Pb),Pi(4,`div`,14)(5,`div`,15),ub(6,`Paper Width`),fl$1(),Pi(7,`div`,16)(8,`div`,17),_h(9,Jt,6,3,`ng-container`,18),Pi(10,`span`),ub(11),Ab(12,`number`),fl$1()()()(),Pi(13,`div`,14)(14,`div`,15),ub(15,`Sticker Width`),fl$1(),Pi(16,`div`,16)(17,`div`,17),_h(18,Qt,6,3,`ng-container`,18),Pi(19,`span`),ub(20),Ab(21,`number`),fl$1()()()(),Pi(22,`div`,14)(23,`div`,15),ub(24,`Sticker Height`),fl$1(),Pi(25,`div`,16)(26,`div`,17),_h(27,Xt,6,3,`ng-container`,18),Pi(28,`span`),ub(29),Ab(30,`number`),fl$1()()()(),_h(31,Yt,4,7,`ng-template`,null,2,Pb),fl$1()()}if(i&2){let e=u.$implicit,t=Aw(2);iI(),Rh(`ngClass`,bb(13,$t,t.selectedTemplateId()===e.ID)),iI(8),Rh(`ngIf`,e.ConfigObject.PaperWidthCM),iI(2),ml(``,Ob(12,7,e.ConfigObject.PaperWidth),`px`),iI(7),Rh(`ngIf`,e.ConfigObject.StickerWidthCM),iI(2),ml(``,Ob(21,9,e.ConfigObject.StickerWidth),`px`),iI(7),Rh(`ngIf`,e.ConfigObject.StickerHeightCM),iI(2),ml(``,Ob(30,11,e.ConfigObject.StickerHeight),`px`)}}function ti(i,u){if(i&1&&(Pi(0,`p-card`,10)(1,`div`,11),yw(2,ei,33,15,`div`,12,zt),fl$1()()),i&2){let e=Aw();iI(2),vw(e.profileTemplates())}}function ii(i,u){if(i&1){let e=Tw();Pi(0,`div`,26)(1,`p-button`,27),Bh(`onClick`,function(){Gu(e);let r=Aw();return zu(r.onNextStep())}),fl$1()()}if(i&2){let e=Aw();iI(),Rh(`disabled`,!e.hasSelectedTemplate())}}function oi(i,u){if(i&1){let e=Tw();Pi(0,`app-dialog-form-edit`,28),Bh(`onSubmit`,function(r){Gu(e);let a=Aw();return zu(a.onDialogFormEdit(r))}),fl$1()}if(i&2){let e=Aw();Rh(`form`,e.form)}}function ni(i,u){if(i&1){let e=Tw();Pi(0,`app-dialog-form-create`,28),Bh(`onSubmit`,function(r){Gu(e);let a=Aw();return zu(a.onDialogFormCreate(r))}),fl$1()}if(i&2){let e=Aw();Rh(`form`,e.form)}}function ri(i,u){if(i&1){let e=Tw();Pi(0,`p-button`,29),Bh(`onClick`,function(){Gu(e);let r=Aw();return zu(r.closeDialog())}),fl$1(),Pi(1,`p-button`,30),Bh(`onClick`,function(){Gu(e);let r=Aw();return zu(r.onSubmit())}),fl$1()}}var Wt=(()=>{class i$1{constructor(){this.templateService=E(Rg),this.appStore=E(eu),this.profileTemplates=ti$1(null),this.fb=E(dh),this.router=E(W),this.route=E(Z),this.selectedTemplateId=ti$1(null),this.profileTemplateDefault=ti$1(null),this.dialogVisible=ti$1(!1),this.dialogMode=ti$1(null),this.menuItems=ti$1([]),this.isPatching=ti$1(!1),this.isFirstRun=!0,this.hasSelectedTemplate=Hb(()=>this.selectedTemplateId()!=null)}get isUserAdmin(){return this.appStore.userRole()===`admin`}initDialogState(){this.route.queryParamMap.pipe(ql(e=>{let t=e.get(`dialog`),r=e.get(`id`);if(t===`create`){this.dialogMode.update(a=>`create`),this.dialogVisible.update(a=>!0),this.selectedTemplateId.update(a=>null),this.form.reset();return}if(t===`edit`&&r){this.dialogMode.update(a=>`edit`),this.dialogVisible.update(a=>!0),this.selectedTemplateId.update(a=>r),this.handleTemplateEdit(r);return}this.dialogVisible.update(a=>!1),this.dialogMode.update(a=>null),this.selectedTemplateId.update(a=>null)})).subscribe()}ngOnInit(){this.closeDialog(),this.initForm(),this.loadData(),this.initMenuItems(),this.initDialogState(),this.templateService.getDefaultPaperTemplate().pipe(i(`Default template loaded`),ql(e=>this.profileTemplateDefault.update(t=>e))).subscribe(),this.linkControls(this.form.controls.paperWidth,this.form.controls.paperWidthCM,e=>z(e,96,`round`,2),e=>ve(e,96,`round`,2)),this.linkControls(this.form.controls.stickerWidth,this.form.controls.stickerWidthCM,e=>z(e,96,`round`,2),e=>ve(e,96,`round`,2)),this.linkControls(this.form.controls.stickerHeight,this.form.controls.stickerHeightCM,e=>z(e,96,`round`,2),e=>ve(e,96,`round`,2))}ngAfterViewInit(){let e=localStorage.getItem(Xt$1.SelectedProfileTemplate);if(e)try{let t=JSON.parse(e);t?.ID!=null&&(this.selectedTemplateId.set(t.ID),this.appStore.updateProfileTemplate(t))}catch(t){console.warn(`Failed to parse selected profile template from localStorage`,t),localStorage.removeItem(Xt$1.SelectedProfileTemplate)}}onDialogFormEdit(e){Object.assign(this.form.value,e)}onDialogFormCreate(e){Object.assign(this.form.value,e)}initMenuItems(){this.menuItems.update(e=>[...e,{label:`Edit`,disabled:!this.isUserAdmin,command:t=>{this.openEdit(t.item.id)}},{label:`Copy`,disabled:!this.isUserAdmin,command:t=>{this.onCopyTemplate(t.item.id)}},{label:`Delete`,disabled:!this.isUserAdmin,command:t=>{this.onDeleteTemplate(t.item.id)}}])}handleTemplateEdit(e){this.templateService.getPaperTemplatesById(e).pipe(ql(({ConfigObject:{Name:t,PaperWidth:r,PaperWidthCM:a,StickerWidth:h,StickerWidthCM:m,StickerHeight:f,StickerHeightCM:l}})=>{this.isPatching.update(g=>!0);let M=(g,D)=>g||(D?z(D,96,`round`,2):g);this.form.patchValue({name:t,paperWidth:r,paperWidthCM:M(a,r),stickerWidth:h,stickerWidthCM:M(m,h),stickerHeight:f,stickerHeightCM:M(l,f)}),this.isPatching.update(g=>!1)})).subscribe()}linkControls(e,t,r,a){let h=(m,f=2)=>m.toFixed(f);e.valueChanges.pipe(sm(),$e(()=>!this.isPatching()),ql(m=>{if(m!=null){let f=r(m);t.setValue(h(f),{emitEvent:!1})}})).subscribe(),t.valueChanges.pipe(sm(),$e(()=>!this.isPatching()),ql(m=>{if(m!=null){let f=a(m);e.setValue(h(f),{emitEvent:!1})}})).subscribe()}loadData(){let e=`https://${localStorage.getItem(Xt$1.Host)}/`;pm({templates:this.templateService.getBarcodeTemplate().pipe(fs(t=>(console.error(`Failed to load templates:`,t),ds([])))),outlets:this.templateService.getListOutlet(e).pipe(fs(t=>(console.error(`Failed to load outlets:`,t),ds([])))),taxes:this.templateService.getListTax(e).pipe(fs(t=>(console.error(`Failed to load taxes:`,t),ds([]))))}).pipe(ql(({templates:t,outlets:r,taxes:a})=>{this.appStore.updateOutlets(r),this.appStore.updateTaxes(a),this.profileTemplates.set(t)}),i(`All template data loaded (even if some failed)`)).subscribe()}onMenuToggle(e,t,r){e.stopPropagation(),t.toggle(e),this.menuItems().forEach(a=>a.id=r)}initForm(){this.form=this.fb.group({paperWidthCM:void 0,name:this.fb.control(null),paperWidth:this.fb.control(null),stickerWidth:this.fb.control(null),stickerWidthCM:this.fb.control(null),stickerHeight:this.fb.control(null),stickerHeightCM:this.fb.control(null)})}onSelectionChange(e){return M(this,null,function*(){this.selectedTemplateId.update(t=>e)})}onSubmit(){if(this.form.invalid){this.form.markAllAsTouched();return}let{name:e,paperWidth:t,paperWidthCM:r,stickerWidth:a,stickerWidthCM:h,stickerHeight:m,stickerHeightCM:f}=this.form.value;if(this.route.snapshot.queryParamMap.has(`id`)){let l=this.profileTemplates().findIndex(g=>g.ID===this.route.snapshot.queryParamMap.get(`id`));if(l===-1)return;let M$1=G(F({},this.profileTemplates()[l]),{ConfigObject:G(F({},this.profileTemplates()[l].ConfigObject),{Name:e,PaperWidth:+t,PaperWidthCM:+r,StickerWidth:+a,StickerWidthCM:+h,StickerHeight:+m,StickerHeightCM:+f})});this.templateService.updatePaperTemplate(this.route.snapshot.queryParamMap.get(`id`),M$1).pipe(ql(()=>M(this,null,function*(){this.loadData(),this.closeDialog()}))).subscribe()}else{let l={ConfigObject:G(F({},this.profileTemplateDefault()),{Name:e,PaperWidth:+t,PaperWidthCM:+r,StickerWidth:+a,StickerWidthCM:+h,StickerHeight:+m,StickerHeightCM:+f})};this.templateService.savePaperTemplate(l).pipe(i(`Template saved`),ql(()=>M(this,null,function*(){this.loadData(),this.closeDialog()}))).subscribe()}}openCreate(){this.router.navigate([],{queryParams:{dialog:`create`},queryParamsHandling:`merge`})}openEdit(e){this.router.navigate([],{queryParams:{dialog:`edit`,id:e},queryParamsHandling:`merge`})}closeDialog(){this.router.navigate([],{queryParams:{},replaceUrl:!0})}onDeleteTemplate(e){this.templateService.deletePaperTemplate(e).pipe(ql(()=>{this.loadData()})).subscribe(),setTimeout(()=>{document.querySelector(`.p-menu-overlay`)?.remove()},100)}onCopyTemplate(e){this.templateService.copyPaperTemplate(e).pipe(ql(()=>{this.loadData()})).subscribe(),setTimeout(()=>{document.querySelector(`.p-menu-overlay`)?.remove()},100)}onPreviousStep(){this.appStore.updateCurrentStep(this.appStore.currentStep()-1)}onNextStep(){this.appStore.updateCurrentStep(this.appStore.currentStep()+1);let e=this.profileTemplates().find(t=>t.ID===this.selectedTemplateId());this.appStore.updateProfileTemplate(e),localStorage.setItem(Xt$1.SelectedProfileTemplate,JSON.stringify(e))}static{this.ɵfac=function(t){return new(t||i$1)}}static{this.ɵcmp=PD({type:i$1,selectors:[[`app-choose-profile-template`]],decls:12,vars:9,consts:[[`actionButton`,``],[`content`,``],[`footer`,``],[`title`,``],[`menu`,``],[`pageTitle`,`Choose Paper Template`],[`appendTo`,`body`,3,`visibleChange`,`closable`,`header`,`modal`,`visible`],[3,`form`],[1,`d-flex`,`gap-2`,`justify-content-end`,`align-items-center`],[`label`,`Add`,3,`click`,`disabled`],[1,`p-2`,`m-3`],[1,`row`,`row-gap-4`],[1,`col-12`,`col-md-6`,`col-lg-4`,`col-xl-3`],[3,`click`,`ngClass`],[1,`row`,`fs-3`],[1,`col`],[1,`col`,`d-flex`,`justify-content-end`],[1,`d-flex`,`gap-2`],[4,`ngIf`],[1,`row`],[1,`col-10`],[`type`,`radio`,`name`,`selectedCategory`,1,`p-radiobutton-box`,3,`value`,`checked`],[`type`,`radio`,`name`,`selectedCategory`,1,`p-radiobutton-box`,3,`change`,`value`,`checked`],[1,`d-flex`,`justify-content-end`,`border-top`,`py-2`],[`icon`,`fa-solid fa-ellipsis`,`severity`,`secondary`,3,`onClick`,`outlined`,`pt`],[`appendTo`,`body`,3,`model`,`popup`],[1,`d-flex`,`justify-content-end`,`gap-2`,`py-2`,`px-3`],[`label`,`Next`,`severity`,`info`,3,`onClick`,`disabled`],[3,`onSubmit`,`form`],[`label`,`Cancel`,`severity`,`secondary`,3,`onClick`],[`label`,`Save`,`severity`,`secondary`,3,`onClick`]],template:function(t,r){if(t&1){let a=Tw();Pi(0,`app-main-panel`,5),_h(1,Gt,2,1,`ng-template`,null,0,Pb)(3,ti,4,0,`ng-template`,null,1,Pb)(5,ii,2,1,`ng-template`,null,2,Pb),fl$1(),Pi(7,`p-dialog`,6),fg(`visibleChange`,function(m){return Gu(a),hb(r.dialogVisible,m)||(r.dialogVisible=m),zu(m)}),fw(8,oi,1,1,`app-dialog-form-edit`,7),fw(9,ni,1,1,`app-dialog-form-create`,7),_h(10,ri,2,0,`ng-template`,null,2,Pb),fl$1()}t&2&&(iI(7),Jw(wb(8,jt)),Rh(`closable`,!1)(`header`,r.dialogMode()==`create`?`Create New Label`:`Edit New Label`)(`modal`,!0),dg(`visible`,r.dialogVisible),iI(),hw(r.dialogMode()==`edit`?8:-1),iI(),hw(r.dialogMode()==`create`?9:-1))},dependencies:[gr,fh,D,Xi,Fs,Ns,Hl,Ee,Ot,An,In,hh,Lt,Ft,Us],styles:[`[_nghost-%COMP%]{display:block;height:100%}input[type=radio][_ngcontent-%COMP%]{appearance:none;width:18px;height:18px;border:2px solid #ced4da;border-radius:50%;outline:none;cursor:pointer;position:relative}input[type=radio][_ngcontent-%COMP%]:checked{border-color:#3b82f6}input[type=radio][_ngcontent-%COMP%]:checked:after{content:"";position:absolute;top:50%;left:50%;width:8px;height:8px;background:#3b82f6;border-radius:50%;transform:translate(-50%,-50%)}`]})}}return i$1})();function ai(i,u){i&1&&Oh(0,`app-choose-profile-template`)}function li(i,u){i&1&&Oh(0,`choose-product`)}function pi(i,u){if(i&1&&Oh(0,`app-barcode-preview`,1),i&2){let e=u.$implicit;Rh(`cartItems`,e)}}function si(i,u){i&1&&(Pi(0,`app-customize-label`),_h(1,pi,1,1,`ng-template`,null,0,Pb),fl$1())}function ci(i,u){i&1&&Oh(0,`app-print-preview`)}var Bo=(()=>{class i{constructor(){this.storeService=E(el),this.appStore=E(eu)}get cartItems(){return this.appStore.flattenedCartUnits()}static{this.ɵfac=function(t){return new(t||i)}}static{this.ɵcmp=PD({type:i,selectors:[[`app-barcode-wrapper`]],decls:4,vars:1,consts:[[`content`,``],[`previewMode`,`single`,3,`cartItems`]],template:function(t,r){if(t&1&&fw(0,ai,1,0,`app-choose-profile-template`)(1,li,1,0,`choose-product`)(2,si,3,0,`app-customize-label`)(3,ci,1,0,`app-print-preview`),t&2){let a;hw((a=r.appStore.currentStep())===1?0:a===2?1:a===3?2:a===4?3:-1)}},dependencies:[Wt,vz,dj,rd,bV],encapsulation:2,changeDetection:1})}}return i})();export{Bo as BarcodeWrapperComponent};
@@ -1,4 +1,4 @@
1
- import{a as ea,c as ra,i as _i,l as vi,n as Mt,o as ha,s as hl,t as Ai$1}from"./chunk-DlUaBLQM.js";import{l as xt,p as U,s as Wt}from"./main-62M3JO5Z.js";import{c as Sn,d as gn,g as ye,l as Ti,m as mn,p as jn,s as Ri,u as Wn}from"./chunk-DVmYwAhe.js";import{$ as gl,At as ze,Dt as yi,Et as wl,G as bl,H as _t,I as Wl,J as dl,L as Xi,Mt as zr,O as Su,Q as gd,Tt as wc,X as fe,Z as fl,_ as Hl,at as ks,b as Kr,bt as ul,c as Bl,d as Do$1,dt as qa$1,et as hd,f as El,ft as qu,g as Fs,h as Fo$1,jt as zl,kt as z,lt as nl,mt as rp,n as Aa,p as Eo$1,q as ct,r as Ac$1,s as At,st as md,t as $,ut as ol,vt as tu,w as Ol,wt as vu,z as Ze}from"./chunk-CZtkF-WL.js";import{K as oh,R as hh,U as le,Y as sc,it as xe,k as _l,o as Go$1,ot as xs}from"./chunk-CtdBLXrI.js";import{$ as Jw,$n as hb,B as GI,Ci as zu,Dr as ml,E,Er as mi,Fn as ee,Fr as od,Ft as Rh,H as Gu,Hn as fl$1,Jn as gi$1,Kn as fw,Lr as ov,Lt as Sb,Ot as QI,Pn as eb,Qn as gw,S as Db,Sr as lg,St as Pi,Ti as G,Tn as cg,Ut as Tg,V as Gh,Vn as fg,Vt as Tb,W as Hb,Wt as Th,X as Jh,Yn as gl$1,Yt as U1,_r as kh,_t as Ow,ai as ue,ar as hw,bi as zh,br as kw,bt as Pb,c as Ah,di as vw,ei as ti,en as Vw,er as hd$1,fr as jw,ft as O1,g as Br,gi as x,gn as _h,hn as _b,ht as Oh,ii as ub,it as Mb,j as F1,jr as mw,kn as dg,lt as Nb,m as Bh,nn as W1,on as Xi$1,or as iI,pr as k1,qn as gb,qt as Tw,tr as hg,tt as L1,u as Aw,ur as jD,vi as yw,vn as bb,vt as P1,w as Du,wi as F,wr as mb,xr as le$1,xt as Ph,yr as ko$1,yt as PD,z as GD}from"./chunk-LD3k3Loy.js";var $a=`
1
+ import{a as ea,c as ra,i as _i,l as vi,n as Mt,o as ha,s as hl,t as Ai$1}from"./chunk-BJp2hZ3i.js";import{l as xt,p as U,s as Wt}from"./main-BYQAQ7ZD.js";import{c as Sn,d as gn,g as ye,l as Ti,m as mn,p as jn,s as Ri,u as Wn}from"./chunk-DVmYwAhe.js";import{$ as gl,At as ze,Dt as yi,Et as wl,G as bl,H as _t,I as Wl,J as dl,L as Xi,Mt as zr,O as Su,Q as gd,Tt as wc,X as fe,Z as fl,_ as Hl,at as ks,b as Kr,bt as ul,c as Bl,d as Do$1,dt as qa$1,et as hd,f as El,ft as qu,g as Fs,h as Fo$1,jt as zl,kt as z,lt as nl,mt as rp,n as Aa,p as Eo$1,q as ct,r as Ac$1,s as At,st as md,t as $,ut as ol,vt as tu,w as Ol,wt as vu,z as Ze}from"./chunk-CZtkF-WL.js";import{K as oh,R as hh,U as le,Y as sc,it as xe,k as _l,o as Go$1,ot as xs}from"./chunk-CtdBLXrI.js";import{$ as Jw,$n as hb,B as GI,Ci as zu,Dr as ml,E,Er as mi,Fn as ee,Fr as od,Ft as Rh,H as Gu,Hn as fl$1,Jn as gi$1,Kn as fw,Lr as ov,Lt as Sb,Ot as QI,Pn as eb,Qn as gw,S as Db,Sr as lg,St as Pi,Ti as G,Tn as cg,Ut as Tg,V as Gh,Vn as fg,Vt as Tb,W as Hb,Wt as Th,X as Jh,Yn as gl$1,Yt as U1,_r as kh,_t as Ow,ai as ue,ar as hw,bi as zh,br as kw,bt as Pb,c as Ah,di as vw,ei as ti,en as Vw,er as hd$1,fr as jw,ft as O1,g as Br,gi as x,gn as _h,hn as _b,ht as Oh,ii as ub,it as Mb,j as F1,jr as mw,kn as dg,lt as Nb,m as Bh,nn as W1,on as Xi$1,or as iI,pr as k1,qn as gb,qt as Tw,tr as hg,tt as L1,u as Aw,ur as jD,vi as yw,vn as bb,vt as P1,w as Du,wi as F,wr as mb,xr as le$1,xt as Ph,yr as ko$1,yt as PD,z as GD}from"./chunk-LD3k3Loy.js";var $a=`
2
2
  .p-datatable {
3
3
  position: relative;
4
4
  display: block;
@@ -1 +1 @@
1
- import{a as dj,s as vz}from"./chunk-C4QL1jgF.js";import{b as Z$1,p as U,x as eu}from"./main-62M3JO5Z.js";import"./chunk-BUsg5rFD.js";import"./chunk-DlUaBLQM.js";import"./chunk-CKXRHkCI.js";import"./chunk-DVmYwAhe.js";import{Y as el}from"./chunk-CZtkF-WL.js";import"./chunk-DAfeU1o0.js";import{B as js,D as Xi,_ as Ps,at as xh,w as Us}from"./chunk-CtdBLXrI.js";import{Dr as ml,E,Ft as Rh,Gn as fs,Hn as fl,Kn as fw,St as Pi,Tn as cg,X as Jh,Xr as rm,ar as hw,bt as Pb,cr as it,di as vw,gn as _h,hr as kb,ht as Oh,ii as ub,jn as ds,mt as Ob,o as Ab,or as iI,pr as k1,qr as ql,u as Aw,vi as yw,yn as be,yt as PD}from"./chunk-LD3k3Loy.js";function J(t,c){if(t&1&&(Pi(0,`div`,2)(1,`span`),ub(2),fl(),Pi(3,`span`),ub(4),Ab(5,`number`),fl()(),Pi(6,`span`,2),ub(7),Ab(8,`date`),fl()),t&2){let e=Aw();Rh(`ngStyle`,e.stickerHeaderDesc1Style),iI(2),cg(e.priceLabelTemplate.CurrencySymbol),iI(2),cg(Ob(5,5,e.item().baseUnitPrice)),iI(2),Rh(`ngStyle`,e.stickerHeaderDesc2Style),iI(),ml(` sd `,kb(8,7,e.item().promotion.ExpirationDate,`dd-MM-yyyy`),` `)}}function K(t,c){if(t&1&&(Pi(0,`span`,2),ub(1),fl(),Pi(2,`span`,2),ub(3),Ab(4,`number`),fl()),t&2){let e=Aw();Jh(`font-size`,e.priceLabelTemplate.CurrencySymbolFontSize+`px`),Rh(`ngStyle`,e.stickerContentHeaderDesc1Style),iI(),ml(` `,e.priceLabelTemplate.CurrencySymbol,` `),iI(),Rh(`ngStyle`,e.stickerContentHeaderDesc2Style),iI(),ml(` `,Ob(4,6,e.item().effectiveUnitPrice),` `)}}function Q(t,c){if(t&1&&(Pi(0,`span`,2),ub(1),fl(),Pi(2,`span`,2),ub(3),Ab(4,`number`),fl()),t&2){let e=Aw();Jh(`font-size`,e.priceLabelTemplate.CurrencySymbolFontSize+`px`),Rh(`ngStyle`,e.stickerContentHeaderDesc1Style),iI(),ml(` `,e.priceLabelTemplate.CurrencySymbol,` `),iI(),Rh(`ngStyle`,e.stickerContentHeaderDesc2Style),iI(),ml(` `,Ob(4,6,e.item().effectiveUnitPrice),` `)}}function X(t,c){if(t&1&&(Pi(0,`span`,2),ub(1),fl(),Pi(2,`span`,2),ub(3),Ab(4,`number`),fl()),t&2){let e=Aw();Jh(`font-size`,e.priceLabelTemplate.CurrencySymbolFontSize+`px`),Rh(`ngStyle`,e.stickerContentHeaderDesc1Style),iI(),ml(` `,e.priceLabelTemplate.CurrencySymbol,` `),iI(),Rh(`ngStyle`,e.stickerContentHeaderDesc2Style),iI(),cg(Ob(4,6,e.item().baseUnitPrice))}}function Y(t,c){t&1&&(Pi(0,`span`),ub(1,`PROMOSI`),fl(),Pi(2,`span`),ub(3,`PROMOSI`),fl())}var q=(()=>{class t{constructor(){this.appStore=E(eu),this.item=k1(),this.printDate=/* @__PURE__ */ new Date}get priceLabelTemplate(){return this.appStore.priceLabelTemplate()||null}get stickerContainerStyles(){return{display:`flex`,flexDirection:`column`,alignItems:`center`,justifyContent:`center`,gap:`10px`,width:`100%`,height:`100%`}}get stickerStyle(){return{width:`71mm`,overflow:`hidden`,border:`1px solid #000`,display:`flex`,flexDirection:`column`}}get stickerHeaderStyle(){return{padding:`0 4px`,display:`flex`,justifyContent:`space-between`,height:this.item().promotion?`max-content`:`20px`}}get stickerHeaderDesc1Style(){return this.priceLabelTemplate?{fontWeight:`600`,fontSize:`${this.priceLabelTemplate.PromotionDateFontSize}px`,textDecoration:this.item()?`line-through`:`none`}:{}}get stickerHeaderDesc2Style(){return this.priceLabelTemplate?{fontWeight:`600`,fontSize:`${this.priceLabelTemplate.PromotionDateFontSize}px`}:{}}get stickerContentStyle(){return{padding:`0 4px`,display:`flex`,flexDirection:`column`,flex:`1 1 0`}}get stickerContentHeaderStyle(){return{display:`flex`,justifyContent:`space-between`,alignItems:`flex-start`,lineHeight:`.8`}}get stickerContentHeaderDesc1Style(){return{fontWeight:`800`}}get stickerContentHeaderDesc2Style(){return{fontSize:`${this.priceLabelTemplate.NormalFontSize}px`,margin:`0`,padding:`0`,fontWeight:`800`}}get stickerContentBodyStyle(){return{display:`flex`,flexDirection:`column`,justifyContent:`space-between`,fontWeight:`600`}}get stickerContentBodyDesc1Style(){return{textAlign:`start`,fontSize:`${this.priceLabelTemplate.ProductNameFontSize}px`}}get stickerContentBodyDesc2Style(){return{textAlign:`start`,fontSize:`${this.priceLabelTemplate.ProductCodeFontSize}px`}}get stickerFooterStyle(){return{display:`flex`,flexDirection:`column`}}get stickerFooterHeaderStyle(){return{display:`flex`,justifyContent:`end`,padding:`0 4px`}}get stickerFooterHeaderDesc1Style(){return{fontWeight:`600`,textDecoration:`none`,fontSize:`${this.priceLabelTemplate.PrintDateFontSize}px`}}get stickerFooterBodyStyle(){return{backgroundColor:`#000`,color:`#fff`,display:`flex`,justifyContent:`space-between`,alignItems:`center`,padding:`2px 6px`,fontWeight:`600`}}get stickerFooterBodyDesc1Style(){return{display:`flex`,gap:`10px`,fontSize:`${this.priceLabelTemplate.PromotionDescFontSize}px`}}get stickerFooterBodyDesc2Style(){return{fontSize:`${this.priceLabelTemplate.StoreNameFontSize}px`}}promotionDiscount(e){try{return Object.keys(e).length?e.Discount&&e.Discount>0?e.UnitPrice-e.UnitPrice*e.Discount/100:e.UnitPrice:0}catch(o){throw new Error(`error: `+(o instanceof Error?o.message:String(o)))}}static{this.ɵfac=function(o){return new(o||t)}}static{this.ɵcmp=PD({type:t,selectors:[[`app-label-preview`]],inputs:{item:[1,`item`]},decls:23,vars:23,consts:[[`id`,`sticker`,1,`sticker`,3,`ngStyle`],[`id`,`sticker-header`,3,`ngStyle`],[3,`ngStyle`]],template:function(o,n){o&1&&(Pi(0,`div`,0)(1,`div`,1),fw(2,J,9,10),fl(),Pi(3,`div`,2)(4,`div`,2),fw(5,K,5,8)(6,Q,5,8)(7,X,5,8),fl(),Pi(8,`div`,2)(9,`span`,2),ub(10),fl(),Pi(11,`span`,2),ub(12),fl()()(),Pi(13,`div`,2)(14,`div`,2)(15,`span`,2),ub(16),Ab(17,`date`),fl()(),Pi(18,`div`,2)(19,`div`,2),fw(20,Y,4,0),fl(),Pi(21,`span`,2),ub(22),fl()()()()),o&2&&(Rh(`ngStyle`,n.stickerStyle),iI(),Rh(`ngStyle`,n.stickerHeaderStyle),iI(),hw(n.item().promotion?2:-1),iI(),Rh(`ngStyle`,n.stickerContentStyle),iI(),Rh(`ngStyle`,n.stickerContentHeaderStyle),iI(),hw(n.item().promotion?5:n.item().outletPrice?6:7),iI(3),Rh(`ngStyle`,n.stickerContentBodyStyle),iI(),Rh(`ngStyle`,n.stickerContentBodyDesc1Style),iI(),cg(n.item().product.Name),iI(),Rh(`ngStyle`,n.stickerContentBodyDesc2Style),iI(),cg(n.item().product.Code),iI(),Rh(`ngStyle`,n.stickerFooterStyle),iI(),Rh(`ngStyle`,n.stickerFooterHeaderStyle),iI(),Rh(`ngStyle`,n.stickerFooterHeaderDesc1Style),iI(),cg(kb(17,20,n.printDate,`dd-MM-yyyy`)),iI(2),Rh(`ngStyle`,n.stickerFooterBodyStyle),iI(),Rh(`ngStyle`,n.stickerFooterBodyDesc1Style),iI(),hw(n.item().promotion?20:-1),iI(),Rh(`ngStyle`,n.stickerFooterBodyDesc2Style),iI(),cg(n.priceLabelTemplate.CompanyNameLabel))},dependencies:[Xi,Ps,Us,js],encapsulation:2})}}return t})();var Z=(t,c)=>c.id;function ee(t,c){t&1&&Oh(0,`choose-product`)}function te(t,c){t&1&&Oh(0,`div`,4)}function ie(t,c){if(t&1&&(Oh(0,`app-label-preview`,3),fw(1,te,1,0,`div`,4)),t&2){let e=c.$implicit,o=c.$index,n=c.$count;Rh(`item`,e),iI(),hw(o!==n-1?1:-1)}}function ne(t,c){if(t&1&&(Pi(0,`div`,2),yw(1,ie,2,2,null,null,Z),fl()),t&2){let e=c.$implicit;iI(),vw(e)}}function re(t,c){t&1&&(Pi(0,`app-customize-label`,1),_h(1,ne,3,0,`ng-template`,null,0,Pb),fl())}var Pe=(()=>{class t{constructor(){this.store=E(el),this.appStore=E(eu),this.httpService=E(xh),this.destroyRef=E(be),this.routes=E(Z$1)}get printMode(){let e=this.routes.snapshot.queryParamMap.get(`printMode`);return console.log(`printMode`,e),e}get currentStep(){return this.appStore.currentStep()}ngOnInit(){this.store.onReset(),console.log(localStorage.getItem(`Domain`))}ngAfterViewInit(){let e=this.getHostFromDomain();this.loadInitialData(e)}getHostFromDomain(){let e=localStorage.getItem(`Domain`);return e?this.hasProtocol(e)?new URL(e).hostname:e:null}hasProtocol(e){return/^(https?):\/\//.test(e)}loadInitialData(e){if(!e){console.warn(`No domain found in localStorage`);return}let o=this.httpService.post(`api/ConfigShelf/PaperConfig`,{SubDomain:e}).pipe(fs(s=>ds({error:s}))),n=this.httpService.get(`/API/V3/Tax`,void 0,`https://${e}`).pipe(fs(s=>ds({error:s})));rm([o,n]).pipe(U(this.destroyRef),it(([s,D])=>this.normalizeResponses(s,D)),ql(({paperConfig:s,taxs:D})=>this.applyDataToStore(s,D))).subscribe()}normalizeResponses(e,o){let n=s=>s&&`error`in s;return{paperConfig:n(e)?null:e,taxs:n(o)?null:o}}applyDataToStore(e,o){e&&this.store.onChangeShelfLabelConfig(e),o&&this.store.onChangeTaxs(o)}static{this.ɵfac=function(o){return new(o||t)}}static{this.ɵcmp=PD({type:t,selectors:[[`app-price-label-wrapper`]],decls:2,vars:1,consts:[[`content`,``],[`sidebarConfig`,`label`],[1,`d-flex`,`flex-column`,`gap-2`],[3,`item`],[1,`divider`]],template:function(o,n){if(o&1&&fw(0,ee,1,0,`choose-product`)(1,re,3,0,`app-customize-label`,1),o&2){let s;hw((s=n.currentStep)===1?0:s===2?1:-1)}},dependencies:[vz,dj,q],styles:[`[_nghost-%COMP%]{display:block;height:100%}.divider[_ngcontent-%COMP%]{border:1px dashed #000;width:100%}`]})}}return t})();export{Pe as PriceLabelWrapperComponent};
1
+ import{a as dj,s as vz}from"./chunk-CjR2BAfc.js";import{b as Z$1,p as U,x as eu}from"./main-BYQAQ7ZD.js";import"./chunk-BUsg5rFD.js";import"./chunk-BJp2hZ3i.js";import"./chunk-CKXRHkCI.js";import"./chunk-DVmYwAhe.js";import{Y as el}from"./chunk-CZtkF-WL.js";import"./chunk-DAfeU1o0.js";import{B as js,D as Xi,_ as Ps,at as xh,w as Us}from"./chunk-CtdBLXrI.js";import{Dr as ml,E,Ft as Rh,Gn as fs,Hn as fl,Kn as fw,St as Pi,Tn as cg,X as Jh,Xr as rm,ar as hw,bt as Pb,cr as it,di as vw,gn as _h,hr as kb,ht as Oh,ii as ub,jn as ds,mt as Ob,o as Ab,or as iI,pr as k1,qr as ql,u as Aw,vi as yw,yn as be,yt as PD}from"./chunk-LD3k3Loy.js";function J(t,c){if(t&1&&(Pi(0,`div`,2)(1,`span`),ub(2),fl(),Pi(3,`span`),ub(4),Ab(5,`number`),fl()(),Pi(6,`span`,2),ub(7),Ab(8,`date`),fl()),t&2){let e=Aw();Rh(`ngStyle`,e.stickerHeaderDesc1Style),iI(2),cg(e.priceLabelTemplate.CurrencySymbol),iI(2),cg(Ob(5,5,e.item().baseUnitPrice)),iI(2),Rh(`ngStyle`,e.stickerHeaderDesc2Style),iI(),ml(` sd `,kb(8,7,e.item().promotion.ExpirationDate,`dd-MM-yyyy`),` `)}}function K(t,c){if(t&1&&(Pi(0,`span`,2),ub(1),fl(),Pi(2,`span`,2),ub(3),Ab(4,`number`),fl()),t&2){let e=Aw();Jh(`font-size`,e.priceLabelTemplate.CurrencySymbolFontSize+`px`),Rh(`ngStyle`,e.stickerContentHeaderDesc1Style),iI(),ml(` `,e.priceLabelTemplate.CurrencySymbol,` `),iI(),Rh(`ngStyle`,e.stickerContentHeaderDesc2Style),iI(),ml(` `,Ob(4,6,e.item().effectiveUnitPrice),` `)}}function Q(t,c){if(t&1&&(Pi(0,`span`,2),ub(1),fl(),Pi(2,`span`,2),ub(3),Ab(4,`number`),fl()),t&2){let e=Aw();Jh(`font-size`,e.priceLabelTemplate.CurrencySymbolFontSize+`px`),Rh(`ngStyle`,e.stickerContentHeaderDesc1Style),iI(),ml(` `,e.priceLabelTemplate.CurrencySymbol,` `),iI(),Rh(`ngStyle`,e.stickerContentHeaderDesc2Style),iI(),ml(` `,Ob(4,6,e.item().effectiveUnitPrice),` `)}}function X(t,c){if(t&1&&(Pi(0,`span`,2),ub(1),fl(),Pi(2,`span`,2),ub(3),Ab(4,`number`),fl()),t&2){let e=Aw();Jh(`font-size`,e.priceLabelTemplate.CurrencySymbolFontSize+`px`),Rh(`ngStyle`,e.stickerContentHeaderDesc1Style),iI(),ml(` `,e.priceLabelTemplate.CurrencySymbol,` `),iI(),Rh(`ngStyle`,e.stickerContentHeaderDesc2Style),iI(),cg(Ob(4,6,e.item().baseUnitPrice))}}function Y(t,c){t&1&&(Pi(0,`span`),ub(1,`PROMOSI`),fl(),Pi(2,`span`),ub(3,`PROMOSI`),fl())}var q=(()=>{class t{constructor(){this.appStore=E(eu),this.item=k1(),this.printDate=/* @__PURE__ */ new Date}get priceLabelTemplate(){return this.appStore.priceLabelTemplate()||null}get stickerContainerStyles(){return{display:`flex`,flexDirection:`column`,alignItems:`center`,justifyContent:`center`,gap:`10px`,width:`100%`,height:`100%`}}get stickerStyle(){return{width:`71mm`,overflow:`hidden`,border:`1px solid #000`,display:`flex`,flexDirection:`column`}}get stickerHeaderStyle(){return{padding:`0 4px`,display:`flex`,justifyContent:`space-between`,height:this.item().promotion?`max-content`:`20px`}}get stickerHeaderDesc1Style(){return this.priceLabelTemplate?{fontWeight:`600`,fontSize:`${this.priceLabelTemplate.PromotionDateFontSize}px`,textDecoration:this.item()?`line-through`:`none`}:{}}get stickerHeaderDesc2Style(){return this.priceLabelTemplate?{fontWeight:`600`,fontSize:`${this.priceLabelTemplate.PromotionDateFontSize}px`}:{}}get stickerContentStyle(){return{padding:`0 4px`,display:`flex`,flexDirection:`column`,flex:`1 1 0`}}get stickerContentHeaderStyle(){return{display:`flex`,justifyContent:`space-between`,alignItems:`flex-start`,lineHeight:`.8`}}get stickerContentHeaderDesc1Style(){return{fontWeight:`800`}}get stickerContentHeaderDesc2Style(){return{fontSize:`${this.priceLabelTemplate.NormalFontSize}px`,margin:`0`,padding:`0`,fontWeight:`800`}}get stickerContentBodyStyle(){return{display:`flex`,flexDirection:`column`,justifyContent:`space-between`,fontWeight:`600`}}get stickerContentBodyDesc1Style(){return{textAlign:`start`,fontSize:`${this.priceLabelTemplate.ProductNameFontSize}px`}}get stickerContentBodyDesc2Style(){return{textAlign:`start`,fontSize:`${this.priceLabelTemplate.ProductCodeFontSize}px`}}get stickerFooterStyle(){return{display:`flex`,flexDirection:`column`}}get stickerFooterHeaderStyle(){return{display:`flex`,justifyContent:`end`,padding:`0 4px`}}get stickerFooterHeaderDesc1Style(){return{fontWeight:`600`,textDecoration:`none`,fontSize:`${this.priceLabelTemplate.PrintDateFontSize}px`}}get stickerFooterBodyStyle(){return{backgroundColor:`#000`,color:`#fff`,display:`flex`,justifyContent:`space-between`,alignItems:`center`,padding:`2px 6px`,fontWeight:`600`}}get stickerFooterBodyDesc1Style(){return{display:`flex`,gap:`10px`,fontSize:`${this.priceLabelTemplate.PromotionDescFontSize}px`}}get stickerFooterBodyDesc2Style(){return{fontSize:`${this.priceLabelTemplate.StoreNameFontSize}px`}}promotionDiscount(e){try{return Object.keys(e).length?e.Discount&&e.Discount>0?e.UnitPrice-e.UnitPrice*e.Discount/100:e.UnitPrice:0}catch(o){throw new Error(`error: `+(o instanceof Error?o.message:String(o)))}}static{this.ɵfac=function(o){return new(o||t)}}static{this.ɵcmp=PD({type:t,selectors:[[`app-label-preview`]],inputs:{item:[1,`item`]},decls:23,vars:23,consts:[[`id`,`sticker`,1,`sticker`,3,`ngStyle`],[`id`,`sticker-header`,3,`ngStyle`],[3,`ngStyle`]],template:function(o,n){o&1&&(Pi(0,`div`,0)(1,`div`,1),fw(2,J,9,10),fl(),Pi(3,`div`,2)(4,`div`,2),fw(5,K,5,8)(6,Q,5,8)(7,X,5,8),fl(),Pi(8,`div`,2)(9,`span`,2),ub(10),fl(),Pi(11,`span`,2),ub(12),fl()()(),Pi(13,`div`,2)(14,`div`,2)(15,`span`,2),ub(16),Ab(17,`date`),fl()(),Pi(18,`div`,2)(19,`div`,2),fw(20,Y,4,0),fl(),Pi(21,`span`,2),ub(22),fl()()()()),o&2&&(Rh(`ngStyle`,n.stickerStyle),iI(),Rh(`ngStyle`,n.stickerHeaderStyle),iI(),hw(n.item().promotion?2:-1),iI(),Rh(`ngStyle`,n.stickerContentStyle),iI(),Rh(`ngStyle`,n.stickerContentHeaderStyle),iI(),hw(n.item().promotion?5:n.item().outletPrice?6:7),iI(3),Rh(`ngStyle`,n.stickerContentBodyStyle),iI(),Rh(`ngStyle`,n.stickerContentBodyDesc1Style),iI(),cg(n.item().product.Name),iI(),Rh(`ngStyle`,n.stickerContentBodyDesc2Style),iI(),cg(n.item().product.Code),iI(),Rh(`ngStyle`,n.stickerFooterStyle),iI(),Rh(`ngStyle`,n.stickerFooterHeaderStyle),iI(),Rh(`ngStyle`,n.stickerFooterHeaderDesc1Style),iI(),cg(kb(17,20,n.printDate,`dd-MM-yyyy`)),iI(2),Rh(`ngStyle`,n.stickerFooterBodyStyle),iI(),Rh(`ngStyle`,n.stickerFooterBodyDesc1Style),iI(),hw(n.item().promotion?20:-1),iI(),Rh(`ngStyle`,n.stickerFooterBodyDesc2Style),iI(),cg(n.priceLabelTemplate.CompanyNameLabel))},dependencies:[Xi,Ps,Us,js],encapsulation:2})}}return t})();var Z=(t,c)=>c.id;function ee(t,c){t&1&&Oh(0,`choose-product`)}function te(t,c){t&1&&Oh(0,`div`,4)}function ie(t,c){if(t&1&&(Oh(0,`app-label-preview`,3),fw(1,te,1,0,`div`,4)),t&2){let e=c.$implicit,o=c.$index,n=c.$count;Rh(`item`,e),iI(),hw(o!==n-1?1:-1)}}function ne(t,c){if(t&1&&(Pi(0,`div`,2),yw(1,ie,2,2,null,null,Z),fl()),t&2){let e=c.$implicit;iI(),vw(e)}}function re(t,c){t&1&&(Pi(0,`app-customize-label`,1),_h(1,ne,3,0,`ng-template`,null,0,Pb),fl())}var Pe=(()=>{class t{constructor(){this.store=E(el),this.appStore=E(eu),this.httpService=E(xh),this.destroyRef=E(be),this.routes=E(Z$1)}get printMode(){let e=this.routes.snapshot.queryParamMap.get(`printMode`);return console.log(`printMode`,e),e}get currentStep(){return this.appStore.currentStep()}ngOnInit(){this.store.onReset(),console.log(localStorage.getItem(`Domain`))}ngAfterViewInit(){let e=this.getHostFromDomain();this.loadInitialData(e)}getHostFromDomain(){let e=localStorage.getItem(`Domain`);return e?this.hasProtocol(e)?new URL(e).hostname:e:null}hasProtocol(e){return/^(https?):\/\//.test(e)}loadInitialData(e){if(!e){console.warn(`No domain found in localStorage`);return}let o=this.httpService.post(`api/ConfigShelf/PaperConfig`,{SubDomain:e}).pipe(fs(s=>ds({error:s}))),n=this.httpService.get(`/API/V3/Tax`,void 0,`https://${e}`).pipe(fs(s=>ds({error:s})));rm([o,n]).pipe(U(this.destroyRef),it(([s,D])=>this.normalizeResponses(s,D)),ql(({paperConfig:s,taxs:D})=>this.applyDataToStore(s,D))).subscribe()}normalizeResponses(e,o){let n=s=>s&&`error`in s;return{paperConfig:n(e)?null:e,taxs:n(o)?null:o}}applyDataToStore(e,o){e&&this.store.onChangeShelfLabelConfig(e),o&&this.store.onChangeTaxs(o)}static{this.ɵfac=function(o){return new(o||t)}}static{this.ɵcmp=PD({type:t,selectors:[[`app-price-label-wrapper`]],decls:2,vars:1,consts:[[`content`,``],[`sidebarConfig`,`label`],[1,`d-flex`,`flex-column`,`gap-2`],[3,`item`],[1,`divider`]],template:function(o,n){if(o&1&&fw(0,ee,1,0,`choose-product`)(1,re,3,0,`app-customize-label`,1),o&2){let s;hw((s=n.currentStep)===1?0:s===2?1:-1)}},dependencies:[vz,dj,q],styles:[`[_nghost-%COMP%]{display:block;height:100%}.divider[_ngcontent-%COMP%]{border:1px dashed #000;width:100%}`]})}}return t})();export{Pe as PriceLabelWrapperComponent};
@@ -0,0 +1 @@
1
+ var e=[{path:``,children:[{path:`v2/print-mode`,loadComponent:()=>import(`./chunk-DbXSTX3L.js`).then(o=>o.PrintModeSelectorComponent)},{path:``,children:[{path:`barcode`,loadComponent:()=>import(`./chunk-Bbt-kXa8.js`).then(o=>o.BarcodeWrapperComponent)},{path:`price-label`,loadComponent:()=>import(`./chunk-C9DOB2N2.js`).then(o=>o.PriceLabelWrapperComponent)},{path:`setup`,children:[{path:`users`,loadComponent:()=>import(`./chunk-gS_FqrHj.js`).then(o=>o.UsersComponent)},{path:`groups`,loadComponent:()=>import(`./chunk-BZqeyZxL.js`).then(o=>o.GroupsComponent)},{path:`credential`,loadComponent:()=>import(`./chunk-BsK2EPXV.js`).then(o=>o.CredentialComponent)}]}]}]}];export{e as dashboardRoutes};