@duplicati/ngclient 0.0.205 → 0.0.207
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.
- package/assets/dest-icons/googleworkspace.png +0 -0
- package/assets/sh-bold.woff2 +0 -0
- package/assets/sh.woff2 +0 -0
- package/chunk-23UYU3M3.js +1 -0
- package/chunk-2FPYV4EW.js +1 -0
- package/chunk-2K74TI2N.js +1 -0
- package/{chunk-HCSB3IIB.js → chunk-2T4BMRWX.js} +1 -1
- package/{chunk-D6IP567E.js → chunk-3MS6SVET.js} +1 -1
- package/{chunk-BABBRM6A.js → chunk-3QS6DB3O.js} +1 -1
- package/chunk-4HB376H3.js +1 -0
- package/{chunk-VDSX2M4H.js → chunk-4VYR5E5I.js} +1 -1
- package/chunk-5MKFV3IB.js +1 -0
- package/chunk-5T2JCBPV.js +1 -0
- package/{chunk-GRVTXORM.js → chunk-6COK7FLL.js} +1 -1
- package/chunk-7E5J43IH.js +1 -0
- package/{chunk-BYUBKTO5.js → chunk-7HFTVA4J.js} +1 -1
- package/chunk-7JHU54QM.js +1 -0
- package/chunk-7MPZ3MRD.js +1 -0
- package/chunk-7PUXNL75.js +1 -0
- package/chunk-A57TBTOD.js +1 -0
- package/chunk-AG7H2MR5.js +1 -0
- package/chunk-AGMFKAHM.js +1 -0
- package/chunk-AI6EYFMY.js +1 -0
- package/chunk-AZEV3A4R.js +11 -0
- package/chunk-C5OYK6UC.js +2 -0
- package/chunk-CAJQ2FEU.js +1 -0
- package/{chunk-MZ5COKIP.js → chunk-CTQKCCGM.js} +1 -1
- package/chunk-DKPWJYG3.js +1 -0
- package/chunk-DRRYACBV.js +1 -0
- package/{chunk-SZUNW4JO.js → chunk-EG3PT3XW.js} +1 -1
- package/{chunk-QHBOEY2O.js → chunk-FJFREVRV.js} +1 -1
- package/chunk-G3FMV74P.js +1 -0
- package/{chunk-B62TPRVG.js → chunk-GGW26MAG.js} +1 -1
- package/chunk-GTZRHPRV.js +1 -0
- package/chunk-I2T6IA4K.js +1 -0
- package/chunk-I6PR2AV2.js +1 -0
- package/chunk-I7MAEY3S.js +1 -0
- package/chunk-IAZGVY3O.js +1 -0
- package/chunk-IPGH33MU.js +1 -0
- package/chunk-JJY6UOEY.js +1 -0
- package/chunk-JRXD2X7B.js +1 -0
- package/chunk-JWPG4EWG.js +1 -0
- package/{chunk-ZU6T3TW3.js → chunk-KLAJGS5T.js} +1 -1
- package/{chunk-ZWLAV6HO.js → chunk-KUGAORAS.js} +1 -1
- package/{chunk-7TWUW4XJ.js → chunk-KUX6NGQU.js} +1 -1
- package/chunk-KYTPZ3WD.js +1 -0
- package/chunk-L22UB6DH.js +1 -0
- package/{chunk-PO3L6MKW.js → chunk-LU7RSOI6.js} +1 -1
- package/chunk-MMF252RQ.js +1 -0
- package/chunk-NAMMULH4.js +1 -0
- package/{chunk-HUZXJWCG.js → chunk-NGKFJLI2.js} +1 -1
- package/chunk-NGPZXZJJ.js +1 -0
- package/chunk-NJBOYRXU.js +1 -0
- package/{chunk-TL4WOQKT.js → chunk-O3GGVB2B.js} +1 -1
- package/{chunk-7LTHH6OG.js → chunk-OAAXQ2BE.js} +1 -1
- package/chunk-OL5HI5OG.js +2 -0
- package/{chunk-37CUOEGJ.js → chunk-OOL5FC7N.js} +1 -1
- package/{chunk-EE5SIDTF.js → chunk-OVLGKJ3Z.js} +1 -1
- package/{chunk-NK5WD6WE.js → chunk-OWBBT5WF.js} +1 -1
- package/chunk-P7TJCJ64.js +3 -0
- package/{chunk-R5YJUVWW.js → chunk-PGISF7LM.js} +1 -1
- package/chunk-PVWYJV5Y.js +1 -0
- package/chunk-QY4Y5NJB.js +4 -0
- package/{chunk-5LBG6MOL.js → chunk-QY5UGQ3R.js} +1 -1
- package/chunk-R45TV6JI.js +1 -0
- package/{chunk-I3IIG2AK.js → chunk-R4E5IO3A.js} +1 -1
- package/chunk-RFCIV3AX.js +1 -0
- package/chunk-RJM43XMN.js +1 -0
- package/chunk-RNE4Z2E4.js +1 -0
- package/{chunk-6LAXPU22.js → chunk-RWDQ3L3C.js} +1 -1
- package/chunk-SFW3N5OL.js +1 -0
- package/chunk-SIMG6PGZ.js +2 -0
- package/chunk-SMUUHPDS.js +1 -0
- package/chunk-STB3WOIA.js +1 -0
- package/chunk-T2KOS3XX.js +1 -0
- package/{chunk-AIH3GSIT.js → chunk-TBQPNXMN.js} +1 -1
- package/{chunk-NGNWWP6M.js → chunk-UOZTEZ7B.js} +1 -1
- package/{chunk-VFBRHP2H.js → chunk-V63YAEPZ.js} +1 -1
- package/{chunk-KDSMLI73.js → chunk-VKNFRCHQ.js} +1 -1
- package/{chunk-7AVOHYTE.js → chunk-VLMNSWR3.js} +1 -1
- package/{chunk-T4IKTBRQ.js → chunk-VNF7NNO5.js} +1 -1
- package/{chunk-AODNZLCK.js → chunk-VPUFUCR3.js} +1 -1
- package/chunk-VUKQJ766.js +1 -0
- package/{chunk-MDXSNEQZ.js → chunk-WLAJ3YIP.js} +1 -1
- package/{chunk-G2FJM62F.js → chunk-XHDAWK7I.js} +1 -1
- package/chunk-XTFBRBQX.js +1 -0
- package/chunk-XZHXN75E.js +1 -0
- package/chunk-Y46QCSB5.js +1 -0
- package/chunk-Z2BNW4KI.js +1 -0
- package/chunk-ZFREX3ZV.js +1 -0
- package/chunk-ZPIR5QIQ.js +2 -0
- package/index.html +2 -2
- package/locale/messages.da.json +9 -23
- package/locale/messages.de.json +114 -60
- package/locale/messages.de_CH.json +80 -37
- package/locale/messages.en.json +73 -39
- package/locale/messages.en_GB.json +73 -39
- package/locale/messages.es.json +43 -10
- package/locale/messages.fr.json +611 -17
- package/locale/messages.it.json +104 -63
- package/locale/messages.json +73 -39
- package/locale/messages.pl.json +376 -12
- package/main-DIGDM6JP.js +1 -0
- package/package.json +1 -1
- package/ship-ui-assets/mcp/components.json +4388 -0
- package/styles-377DNUNK.css +1 -0
- package/chunk-26MRZAFB.js +0 -1
- package/chunk-26Z7TPJB.js +0 -4
- package/chunk-3K3BYB36.js +0 -1
- package/chunk-3QV6WLWV.js +0 -1
- package/chunk-4GXIF5HF.js +0 -1
- package/chunk-4RYK5OOO.js +0 -1
- package/chunk-5MHYH7GK.js +0 -2
- package/chunk-5QWAH3QX.js +0 -1
- package/chunk-5VE6P5U5.js +0 -1
- package/chunk-7DCQVM6E.js +0 -1
- package/chunk-AT64P6E5.js +0 -2
- package/chunk-BFTGDQ4K.js +0 -1
- package/chunk-BT2VIZXE.js +0 -1
- package/chunk-C25WT56X.js +0 -1
- package/chunk-C7N24TZM.js +0 -1
- package/chunk-CFNARBNK.js +0 -1
- package/chunk-COPBOHWE.js +0 -1
- package/chunk-DESKT7LH.js +0 -1
- package/chunk-EE27B3OV.js +0 -1
- package/chunk-F3JL4GJQ.js +0 -1
- package/chunk-G4IFZKMI.js +0 -1
- package/chunk-GJKZESBX.js +0 -1
- package/chunk-H4LQO7G2.js +0 -1
- package/chunk-HOGZ74SB.js +0 -1
- package/chunk-HSHF5HR7.js +0 -1
- package/chunk-I27PVH6D.js +0 -1
- package/chunk-I2RQR4CB.js +0 -1
- package/chunk-IGYSPFE7.js +0 -1
- package/chunk-JN4WCRAH.js +0 -1
- package/chunk-K34VOGDF.js +0 -1
- package/chunk-KV5UORE3.js +0 -1
- package/chunk-LT3AVRVP.js +0 -1
- package/chunk-LXSHDO5C.js +0 -11
- package/chunk-M7Y3VPRV.js +0 -1
- package/chunk-MIMGEZMT.js +0 -1
- package/chunk-MLNK7NFW.js +0 -2
- package/chunk-MMEFBZO4.js +0 -1
- package/chunk-NNNKIEPR.js +0 -1
- package/chunk-OIYIWMS7.js +0 -1
- package/chunk-OPLWAKSM.js +0 -3
- package/chunk-Q2UQ5J3C.js +0 -1
- package/chunk-Q74O3CWJ.js +0 -1
- package/chunk-S2RZQVCD.js +0 -1
- package/chunk-T4BXBCQI.js +0 -1
- package/chunk-U2E3ZQUP.js +0 -1
- package/chunk-UK7MV4OF.js +0 -1
- package/chunk-UNLX3IVU.js +0 -1
- package/chunk-UNMDSCAN.js +0 -1
- package/chunk-W3YBKYPJ.js +0 -1
- package/chunk-XIYAYCFU.js +0 -1
- package/chunk-XLMLR5EV.js +0 -1
- package/chunk-YHMXLWRX.js +0 -1
- package/chunk-YLQF5ATT.js +0 -1
- package/chunk-ZHGDQABC.js +0 -2
- package/main-HMCIC27B.js +0 -1
- package/styles-H32RJLOU.css +0 -1
package/chunk-Q74O3CWJ.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{B as G,D as L,M as D,s as I,w as h}from"./chunk-UNMDSCAN.js";import{c as b}from"./chunk-CFNARBNK.js";import{$ as O,Ab as o,E as d,Ib as N,Pa as r,Qc as R,Rb as s,Vb as u,W as T,Xb as E,aa as C,cb as P,gc as p,jc as f,la as l,lc as M,ub as A,wb as m,xb as g,zb as n}from"./chunk-26Z7TPJB.js";function U(a,i){if(a&1){let e=N();n(0,"sh-radio",10),u("click",function(){let _=O(e).$implicit,c=E();return C(c.pauseOption.set(_.value))}),f(1),o()}if(a&2){let e=i.$implicit,t=E();p("active",t.pauseOption()===e.value),r(),M(" ",e.label," ")}}var v=[{label:$localize`5 minutes`,value:"5m"},{label:$localize`10 minutes`,value:"10m"},{label:$localize`15 minutes`,value:"15m"},{label:$localize`30 minutes`,value:"30m"},{label:$localize`1 hour`,value:"1h"},{label:$localize`4 hours`,value:"4h"},{label:$localize`8 hours`,value:"8h"},{label:$localize`24 hours`,value:"24h"},{label:$localize`Until resumed`,value:void 0}],$=class a{#e=T(b);pauseOptions=l(v);closed=R();isSubmitting=l(!1);pauseTransfers=l(!1);pauseOption=l(void 0);submit(){this.isSubmitting.set(!0);let i=this.pauseTransfers()||null,e=this.pauseOption();this.#e.postApiV1ServerstatePause({duration:e,pauseTransfers:i}).pipe(d(()=>this.isSubmitting.set(!1))).subscribe({next:t=>{this.closed.emit()}})}static \u0275fac=function(e){return new(e||a)};static \u0275cmp=P({type:a,selectors:[["app-pause-dialog"]],outputs:{closed:"closed"},decls:17,vars:4,consts:()=>{let i;i=$localize`Pause settings`;let e;e=$localize` Also pause transfers `;let t;t=$localize`If you pause transfers they could time out and cause retries or failures.`;let _;_=$localize`Cancel`;let c;return c=$localize` Update settings `,[i,e,t,_,c,["header",""],["content",""],[1,"radios"],[1,"primary","raised",3,"active"],[1,"check-wrap"],[1,"primary","raised",3,"click"],["type","warning"],["footer",""],["shButton","",3,"click"],["shButton","",1,"raised","primary",3,"click"]]},template:function(e,t){e&1&&(n(0,"header",5)(1,"h3"),s(2,0),o()(),n(3,"div",6)(4,"div",7),m(5,U,2,3,"sh-radio",8,A),o(),n(7,"div",9)(8,"sh-checkbox",10),u("click",function(){return t.pauseTransfers.set(!t.pauseTransfers())}),s(9,1),o(),n(10,"sh-alert",11),s(11,2),o()()(),n(12,"footer",12)(13,"button",13),u("click",function(){return t.closed.emit()}),s(14,3),o(),n(15,"button",14),u("click",function(){return t.submit()}),s(16,4),o()()),e&2&&(r(5),g(t.pauseOptions()),r(3),p("active",t.pauseTransfers()),r(7),p("loader",t.isSubmitting()))},dependencies:[I,D,L,h,G],styles:["[_nghost-%COMP%]{--dialog-p: 1.5rem;display:block}h3[_ngcontent-%COMP%]{font:var(--title-30)}.radios[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.check-wrap[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;padding:2rem 0 0}"],changeDetection:0})};export{$ as a};
|
package/chunk-S2RZQVCD.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as z}from"./chunk-MMEFBZO4.js";import{A as X,B as H,K as V,u as J}from"./chunk-UNMDSCAN.js";import"./chunk-CFNARBNK.js";import{a as x,c as B,d as w,e as U,f as k}from"./chunk-I27PVH6D.js";import"./chunk-5VE6P5U5.js";import"./chunk-PO3L6MKW.js";import"./chunk-7AVOHYTE.js";import"./chunk-KDSMLI73.js";import{$ as F,Ab as t,Bb as _,Fb as R,Gb as M,Ib as f,Pa as C,Pb as l,Qb as s,Rb as b,Sb as v,Tb as y,Vb as a,W as g,Xb as c,aa as T,cb as $,la as p,sb as m,tb as D,yb as P,zb as i}from"./chunk-26Z7TPJB.js";import"./chunk-7CGTOI24.js";function W(u,S){if(u&1){let n=f();i(0,"sh-menu",15)(1,"button",16),b(2,2),t(),R(3,17),i(4,"button",18),a("click",function(){F(n);let e=c();return T(e.updateLogLevel("Disabled"))}),l(5,3),_(6,"sh-icon"),s(),t(),i(7,"button",18),a("click",function(){F(n);let e=c();return T(e.updateLogLevel("Verbose"))}),l(8,4),_(9,"sh-icon"),s(),t(),i(10,"button",18),a("click",function(){F(n);let e=c();return T(e.updateLogLevel("ExplicitOnly"))}),l(11,5),_(12,"sh-icon"),s(),t(),i(13,"button",18),a("click",function(){F(n);let e=c();return T(e.updateLogLevel("Profiling"))}),l(14,6),_(15,"sh-icon"),s(),t(),i(16,"button",18),a("click",function(){F(n);let e=c();return T(e.updateLogLevel("Retry"))}),l(17,7),_(18,"sh-icon"),s(),t(),i(19,"button",18),a("click",function(){F(n);let e=c();return T(e.updateLogLevel("Information"))}),l(20,8),_(21,"sh-icon"),s(),t(),i(22,"button",18),a("click",function(){F(n);let e=c();return T(e.updateLogLevel("DryRun"))}),l(23,9),_(24,"sh-icon"),s(),t(),i(25,"button",18),a("click",function(){F(n);let e=c();return T(e.updateLogLevel("Warning"))}),l(26,10),_(27,"sh-icon"),s(),t(),i(28,"button",18),a("click",function(){F(n);let e=c();return T(e.updateLogLevel("Error"))}),l(29,11),_(30,"sh-icon"),s(),t(),M(),t()}if(u&2){let n=c();P("openIndicator",!0),C(2),v(n.logLevelByLabel()),y(2)}}var O=class u{#n=g(w);#e=g(z);logLevel=this.#e.logLevel;logLevelByLabel=this.#e.logLevelByLabel;currentUrl=p(this.#n.url);constructor(){this.#n.events.subscribe(S=>{S instanceof x&&this.currentUrl.set(S.urlAfterRedirects)})}updateLogLevel(S){this.#e.isPolling.set(!0),this.#e.updateLogLevel(S)}static \u0275fac=function(n){return new(n||u)};static \u0275cmp=$({type:u,selectors:[["app-logs"]],decls:10,vars:1,consts:()=>{let S;S=$localize`${"\uFFFD#4\uFFFD"}:START_TAG_SH_ICON:archive${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_SH_ICON: Stored `;let n;n=$localize`${"\uFFFD#7\uFFFD"}:START_TAG_SH_ICON:play${"\uFFFD/#7\uFFFD"}:CLOSE_TAG_SH_ICON: Live `;let o;o=$localize`Log level: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let e;e=$localize`${"\uFFFD#6\uFFFD"}:START_TAG_SH_ICON:bell-simple-slash${"\uFFFD/#6\uFFFD"}:CLOSE_TAG_SH_ICON: Disabled `;let E;E=$localize`${"\uFFFD#9\uFFFD"}:START_TAG_SH_ICON:megaphone-simple${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SH_ICON: Verbose `;let L;L=$localize`${"\uFFFD#12\uFFFD"}:START_TAG_SH_ICON:flow-arrow${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SH_ICON: Explicit only `;let N;N=$localize`${"\uFFFD#15\uFFFD"}:START_TAG_SH_ICON:speedometer${"\uFFFD/#15\uFFFD"}:CLOSE_TAG_SH_ICON: Profiling `;let I;I=$localize`${"\uFFFD#18\uFFFD"}:START_TAG_SH_ICON:arrow-arc-left${"\uFFFD/#18\uFFFD"}:CLOSE_TAG_SH_ICON: Retry `;let d;d=$localize`${"\uFFFD#21\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#21\uFFFD"}:CLOSE_TAG_SH_ICON: Information `;let h;h=$localize`${"\uFFFD#24\uFFFD"}:START_TAG_SH_ICON:person-simple-run${"\uFFFD/#24\uFFFD"}:CLOSE_TAG_SH_ICON: Dry run `;let G;G=$localize`${"\uFFFD#27\uFFFD"}:START_TAG_SH_ICON:warning${"\uFFFD/#27\uFFFD"}:CLOSE_TAG_SH_ICON: Warning `;let A;return A=$localize`${"\uFFFD#30\uFFFD"}:START_TAG_SH_ICON:warning-octagon${"\uFFFD/#30\uFFFD"}:CLOSE_TAG_SH_ICON: Error `,[S,n,o,e,E,L,N,I,d,h,G,A,[1,"filters"],["type","button","routerLink","/about/logs/stored","routerLinkActive","active"],["type","button","routerLink","/about/logs/live","routerLinkActive","active"],[3,"openIndicator"],["shButton","","type","button"],["menu",""],["shButton","","type","button",1,"small",3,"click"]]},template:function(n,o){n&1&&(i(0,"div",12)(1,"sh-button-group")(2,"button",13),l(3,0),_(4,"sh-icon"),s(),t(),i(5,"button",14),l(6,1),_(7,"sh-icon"),s(),t()(),m(8,W,31,2,"sh-menu",15),t(),_(9,"router-outlet")),n&2&&(C(8),D(o.currentUrl().startsWith("/about/logs/live")?8:-1))},dependencies:[H,X,J,V,B,k,U],styles:["[_nghost-%COMP%]{display:block}.filters[_ngcontent-%COMP%]{display:flex;align-items:center;gap:1rem;padding:0 2rem;margin-bottom:1.25rem}"],changeDetection:0})};export{O as default};
|
package/chunk-T4BXBCQI.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as W}from"./chunk-EE27B3OV.js";import"./chunk-Q74O3CWJ.js";import"./chunk-BFTGDQ4K.js";import"./chunk-QHBOEY2O.js";import"./chunk-NK5WD6WE.js";import{a as j}from"./chunk-B62TPRVG.js";import"./chunk-6Q6SSTBK.js";import"./chunk-SZUNW4JO.js";import"./chunk-TL4WOQKT.js";import"./chunk-7LTHH6OG.js";import"./chunk-HSHF5HR7.js";import"./chunk-5LBG6MOL.js";import"./chunk-D6IP567E.js";import"./chunk-VDSX2M4H.js";import"./chunk-ZU6T3TW3.js";import"./chunk-HUZXJWCG.js";import"./chunk-7TWUW4XJ.js";import{B as m,C as N,G as w,L as z,u as O}from"./chunk-UNMDSCAN.js";import{c as H}from"./chunk-CFNARBNK.js";import{e as g}from"./chunk-I27PVH6D.js";import"./chunk-5VE6P5U5.js";import"./chunk-PO3L6MKW.js";import"./chunk-7AVOHYTE.js";import"./chunk-KDSMLI73.js";import{Ab as o,Bb as r,Pa as s,Pb as E,Qb as S,Rb as a,Sb as v,Tb as B,W as T,Xb as u,cb as A,ib as D,jc as p,mc as J,pb as G,qb as k,sb as R,tb as d,ub as y,wb as b,xb as x,xc as C,yb as l,yc as X,zb as n}from"./chunk-26Z7TPJB.js";import"./chunk-7CGTOI24.js";var q=()=>[N,m,O,g],V=()=>["/restore-from-files"],K=()=>["/restore/from-config"],Q=t=>["/restore",t];function U(t,i){if(t&1&&(n(0,"sh-card",10),r(1,"img",15),n(2,"div",12)(3,"h3"),a(4,7),o(),n(5,"p"),p(6),o()(),n(7,"button",13),E(8,8),r(9,"sh-icon"),S(),o()()),t&2){let e=i.$implicit;l("routerLink",X(4,Q,e.Backup.ID)),s(4),v(e.Backup.Name??"Backup name missing"),B(4),s(2),J(" ",(e.Backup.Metadata==null?null:e.Backup.Metadata.SourceSizeString)??"-"," / ",(e.Backup.Metadata==null?null:e.Backup.Metadata.BackupListCount)??"-"," ")}}function Y(t,i){if(t&1&&b(0,U,10,6,"sh-card",10,y),t&2){let e=u(2);x(e.backups())}}function Z(t,i){if(t&1&&R(0,Y,2,0),t&2){let e=u();d(e.backups().length?0:-1)}}function ee(t,i){t&1&&(n(0,"div",16),r(1,"sh-progress-bar",17),n(2,"div",12)(3,"h3"),a(4,9),o()()())}function te(t,i){t&1&&(n(0,"sh-divider"),p(1,"Or without a local configuration"),o())}var P=class t{#e=T(j);#t=T(H);backups=this.#e.backups;backupsLoading=this.#e.backupsLoading;ngOnInit(){this.#e.getBackups(!0)}restoreNow(i){this.#t.postApiV1BackupByIdRestore({id:i.Backup?.ID,requestBody:{}})}static \u0275fac=function(e){return new(e||t)};static \u0275cmp=A({type:t,selectors:[["app-restore"]],decls:29,vars:6,consts:()=>{let i;i=$localize`Where do you want to restore from?`;let e;e=$localize`Direct restore from backup files`;let c;c=$localize`Point to your backup files and restore from there.`;let f;f=$localize` Start ${"\uFFFD#18\uFFFD"}:START_TAG_SH_ICON:play-circle${"\uFFFD/#18\uFFFD"}:CLOSE_TAG_SH_ICON:`;let F;F=$localize`Restore from configuration`;let M;M=$localize`Load destination from an exported job`;let h;h=$localize` Start ${"\uFFFD#28\uFFFD"}:START_TAG_SH_ICON:play-circle${"\uFFFD/#28\uFFFD"}:CLOSE_TAG_SH_ICON:`;let I;I=$localize`${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let $;$=$localize` Restore ${"\uFFFD#9\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SH_ICON:`;let L;return L=$localize`Loading backups...`,[i,e,c,f,F,M,h,I,$,L,[1,"type-a","actionable",3,"routerLink"],["src","assets/images/backup.png","alt","","width","48px"],[1,"text"],["shButton",""],["src","assets/images/restore.png","alt","","width","48px"],["src","assets/images/folder.png","alt","","width","48px"],[1,"loading-list"],[1,"indeterminate","primary"]]},template:function(e,c){e&1&&(r(0,"app-status-bar"),n(1,"section")(2,"h2"),a(3,0),o(),D(4,Z,1,1)(5,ee,5,0),G(6,4,q,null,5),R(8,te,2,0,"sh-divider"),n(9,"sh-card",10),r(10,"img",11),n(11,"div",12)(12,"h3"),a(13,1),o(),n(14,"p"),a(15,2),o()(),n(16,"button",13),E(17,3),r(18,"sh-icon"),S(),o()(),n(19,"sh-card",10),r(20,"img",14),n(21,"div",12)(22,"h3"),a(23,4),o(),n(24,"p"),a(25,5),o()(),n(26,"button",13),E(27,6),r(28,"sh-icon"),S(),o()()()),e&2&&(s(6),k(!c.backupsLoading()),s(2),d(c.backups().length?8:-1),s(),l("routerLink",C(4,V)),s(10),l("routerLink",C(5,K)))},dependencies:[W,N,m,w,O,z,g],styles:["[_nghost-%COMP%]{display:block}h2[_ngcontent-%COMP%]{font:var(--title-30);text-align:center;padding:2rem}section[_ngcontent-%COMP%]{max-width:43.75rem;margin:0 auto;padding:2rem 1rem;display:flex;flex-direction:column;gap:1rem}sh-divider[_ngcontent-%COMP%]{color:var(--base-8)}sh-card[_ngcontent-%COMP%]{display:flex;align-items:center;gap:1rem;--card-padding: 2rem}sh-card[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{flex:1 0;display:flex;flex-direction:column;gap:.25rem}.actionable[_ngcontent-%COMP%]{cursor:pointer}.actionable[_ngcontent-%COMP%]:after{transition:inset .1s linear}.actionable[_ngcontent-%COMP%]:hover{--card-shp: 0}"],changeDetection:0})};export{P as default};
|
package/chunk-U2E3ZQUP.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as le}from"./chunk-B62TPRVG.js";import"./chunk-6Q6SSTBK.js";import{a as ae}from"./chunk-SZUNW4JO.js";import{a as _e}from"./chunk-HSHF5HR7.js";import"./chunk-5LBG6MOL.js";import{c as re}from"./chunk-VDSX2M4H.js";import"./chunk-ZU6T3TW3.js";import"./chunk-HUZXJWCG.js";import"./chunk-7TWUW4XJ.js";import{B as ie,D as ne,b as H,e as Q,i as Y,s as Z,u as ee,z as te}from"./chunk-UNMDSCAN.js";import{c as oe}from"./chunk-CFNARBNK.js";import{d as j,e as q}from"./chunk-I27PVH6D.js";import"./chunk-5VE6P5U5.js";import"./chunk-PO3L6MKW.js";import"./chunk-7AVOHYTE.js";import"./chunk-KDSMLI73.js";import{$ as p,Ab as o,Cc as z,E as K,Fc as V,Ib as g,Mc as M,Pa as r,Rb as c,Rc as W,Sb as A,Tb as L,Ub as F,Vb as $,W as u,Xb as C,aa as P,cb as y,gc as x,jc as E,l as k,la as T,oc as S,p as U,pc as D,qc as h,rc as G,sb as m,sc as w,tb as f,tc as v,xc as J,yb as N,yc as X,z as I,zb as n}from"./chunk-26Z7TPJB.js";import"./chunk-7CGTOI24.js";var ce=l=>["/backup",l,"export"],se=()=>["/"];function Ee(l,_){if(l&1){let t=g();n(0,"section")(1,"h4"),c(2,4),o(),n(3,"p"),c(4,5),o(),n(5,"sh-checkbox",11),E(6," Delete local database "),n(7,"input",12),h("ngModelChange",function(e){p(t);let a=C();return D(a.deleteLocalDb,e)||(a.deleteLocalDb=e),P(e)}),o()()()}if(l&2){let t=C();r(7),S("ngModel",t.deleteLocalDb)}}function ue(l,_){if(l&1){let t=g();n(0,"section")(1,"h4"),c(2,6),o(),n(3,"p"),c(4,7),z(5,"bytes"),o(),n(6,"sh-checkbox",11),E(7," Delete remote files "),n(8,"input",12),h("ngModelChange",function(e){p(t);let a=C();return D(a.deleteRemoteFiles,e)||(a.deleteRemoteFiles=e),P(e)}),o()()()}if(l&2){let t=C(),i=v(0),e=(i==null||i.Backup==null||i.Backup.Metadata==null?null:i.Backup.Metadata.TargetFilesSize)??0;r(5),A(t.fileCount())(t.fileCount())(V(5,4,e,!0,!0)),L(4),r(3),S("ngModel",t.deleteRemoteFiles)}}var B=class l{#t=u(oe);#i=u(te);#e=u(le);#n=u(j);id=W.required();backup=M(()=>this.#e.getBackupById(this.id()));noLocalDbResource=re({params:()=>({dbPath:this.backup()?.Backup?.DBPath}),stream:({params:_})=>this.#t.postApiV1FilesystemValidate({requestBody:{path:_.dbPath}}).pipe(U(()=>!0),I(()=>k(!1)))});fileCount=M(()=>parseInt(this.backup()?.Backup?.Metadata?.TargetFilesCount??"0",10));deleteLocalDb=T(!1);deleteRemoteFiles=T(!1);isDeleting=T(!1);deleteBackup(){let _=this.id(),t=this.deleteLocalDb(),i=this.deleteRemoteFiles();this.isDeleting.set(!0),this.#i.open(_e,{data:{title:$localize`Confirm delete`,message:$localize`Are you sure you want to delete this backup?`,confirmText:$localize`Delete backup`,cancelText:$localize`Cancel`},closed:e=>{e&&this.#e.deleteBackup({id:_,deleteLocalDb:t,deleteRemoteFiles:i}).pipe(K(()=>this.isDeleting.set(!1))).subscribe({next:()=>{this.#n.navigate(["/"])}})}})}static \u0275fac=function(t){return new(t||l)};static \u0275cmp=y({type:l,selectors:[["app-delete-backup"]],inputs:{id:[1,"id"]},decls:19,vars:11,consts:()=>{let _;_=$localize`Delete backup: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let t;t=$localize`Export configuration`;let i;i=$localize`If you want to use the backup later, you can export the configuration before deleting it.`;let e;e=$localize`Cancel`;let a;a=$localize`Delete local database`;let b;b=$localize` Each backup has a local database associated with it, which stores information about the remote backup on the local machine. When deleting a backup, you can also delete the local database without affecting the ability to restore the remote files. If you are using the local database for backups from the commandline, you should keep the database. `;let R;R=$localize`Delete remote files`;let d;d=$localize`{VAR_PLURAL, plural, =1 {1 file} other {{INTERPOLATION} files}}`,d=F(d,{INTERPOLATION:"\uFFFD1\uFFFD",VAR_PLURAL:"\uFFFD0\uFFFD"});let O;return O=$localize` Delete ${d}:ICU@@2159106180826349718: (${"\uFFFD2\uFFFD"}:INTERPOLATION_1:) from the remote storage? `,[_,t,i,e,a,b,R,O,["shButton","",3,"routerLink"],[1,"actions"],["shButton","",1,"raised","error",3,"click"],[1,"primary","raised"],["type","checkbox",3,"ngModelChange","ngModel"]]},template:function(t,i){if(t&1){let e=g();G(0),n(1,"h3"),c(2,0),o(),m(3,Ee,8,1,"section"),n(4,"section")(5,"h4"),c(6,1),o(),n(7,"p"),c(8,2),o(),n(9,"button",8),E(10," Export configuration "),n(11,"sh-icon"),E(12,"caret-right"),o()()(),m(13,ue,9,8,"section"),n(14,"div",9)(15,"button",8),c(16,3),o(),n(17,"button",10),$("click",function(){return p(e),P(i.deleteBackup())}),E(18,"Delete backup"),o()()}if(t&2){let e=w(i.backup()),a=i.noLocalDbResource.value();r(2),A(e==null||e.Backup==null?null:e.Backup.Name),L(2),r(),f(a?3:-1),r(6),N("routerLink",X(8,ce,i.id())),r(4),f(a?13:-1),r(2),N("routerLink",J(10,se)),r(2),x("loader",i.isDeleting())}},dependencies:[ne,ie,ee,Z,H,Q,Y,q,ae],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;padding:2.5rem;max-width:43.75rem}section[_ngcontent-%COMP%]{padding:2rem 0;display:flex;align-items:flex-start;flex-direction:column}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0}h4[_ngcontent-%COMP%]{font:var(--paragraph-20);margin-bottom:.5rem}p[_ngcontent-%COMP%]{margin-bottom:1rem}.actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;gap:.5rem;padding:2rem 0}"],changeDetection:0})};export{B as default};
|
package/chunk-UK7MV4OF.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as Ie,c as we,d as v}from"./chunk-6LAXPU22.js";import{a as fe}from"./chunk-B62TPRVG.js";import"./chunk-6Q6SSTBK.js";import"./chunk-5LBG6MOL.js";import{b as Re}from"./chunk-VDSX2M4H.js";import"./chunk-ZU6T3TW3.js";import"./chunk-HUZXJWCG.js";import"./chunk-7TWUW4XJ.js";import{A as Pe,B as Se,H as me,L as ge,W as Oe,Y as Ne,b as ae,c as le,d as g,e as _e,f as ce,j as pe,p as Fe,q as de,r as ue,t as Te,u as Ce,w as Ee}from"./chunk-UNMDSCAN.js";import{a as b,c as he}from"./chunk-CFNARBNK.js";import{b as ie,d as re,e as se}from"./chunk-I27PVH6D.js";import"./chunk-5VE6P5U5.js";import{a as te,d as ne}from"./chunk-PO3L6MKW.js";import"./chunk-7AVOHYTE.js";import"./chunk-KDSMLI73.js";import{$ as D,Ab as r,Bb as _,E as M,Ib as L,K as W,Mc as A,Pa as s,Pb as c,Qb as p,Rb as S,Sb as X,Tb as G,Ub as B,Vb as m,W as C,Xb as u,aa as x,cb as Y,gc as h,jc as $,kc as Z,la as E,mc as ee,na as y,sb as F,tb as d,xc as oe,yb as P,zb as a}from"./chunk-26Z7TPJB.js";import{a as Q}from"./chunk-7CGTOI24.js";var De=()=>["/"];function xe(n,o){n&1&&(a(0,"sh-toggle",23),c(1,5),_(2,"input",26),p(),r())}function $e(n,o){n&1&&(a(0,"span",29),S(1,9),r())}function Ae(n,o){if(n&1&&(a(0,"span",29),S(1,10),r()),n&2){let e=u(2);s(),X(e.exportForm.controls.password.errors==null?null:e.exportForm.controls.password.errors.minlength.requiredLength),G(1)}}function Me(n,o){if(n&1&&_(0,"sh-progress-bar",36),n&2){let e=u(2);h("error",e.calculatePasswordStrength()===1)("warn",e.calculatePasswordStrength()===2)("primary",e.calculatePasswordStrength()===4)("success",e.calculatePasswordStrength()===5),P("value",e.calculatePasswordStrength()*(100/5))}}function ye(n,o){n&1&&(a(0,"span",29),S(1,11),r())}function Le(n,o){n&1&&(a(0,"span",29),S(1,12),r())}function Xe(n,o){if(n&1&&(a(0,"span",29),S(1,13),r()),n&2){let e=u(2);s(),X(e.exportForm.controls.repeatPassword.errors==null?null:e.exportForm.controls.repeatPassword.errors.minlength.requiredLength),G(1)}}function Ge(n,o){n&1&&(c(0,7,1),_(1,"sh-icon"),p())}function Be(n,o){n&1&&(c(0,7,2),_(1,"sh-icon"),p())}function be(n,o){n&1&&(c(0,14,1),_(1,"sh-icon",38),p())}function ve(n,o){n&1&&(c(0,14,2),_(1,"sh-icon"),p())}function ke(n,o){if(n&1){let e=L();a(0,"button",37),m("click",function(){D(e);let i=u(2);return x(i.copyPassword())}),c(1,14),F(2,be,2,0)(3,ve,2,0),p(),r()}if(n&2){let e=u(2);s(2),d(e.copiedPassword()?2:3)}}function Ue(n,o){n&1&&(a(0,"sh-alert",35),S(1,15),r())}function Ke(n,o){if(n&1){let e=L();a(0,"div",24)(1,"sh-form-field")(2,"label",27),c(3,6),_(4,"sup"),p(),r(),_(5,"input",28),F(6,$e,2,0,"span",29)(7,Ae,2,1,"span",29),r(),F(8,Me,1,9,"sh-progress-bar",30),a(9,"sh-form-field"),_(10,"input",31),F(11,ye,2,0,"span",29)(12,Le,2,0,"span",29)(13,Xe,2,1,"span",29),r(),a(14,"div",32)(15,"button",33),m("click",function(){D(e);let i=u();return x(i.showPassword.set(!i.showPassword()))}),c(16,7),F(17,Ge,2,0)(18,Be,2,0),p(),r(),a(19,"button",33),m("click",function(){D(e);let i=u();return x(i.generatePassword())}),c(20,8),_(21,"sh-icon"),p(),r(),F(22,ke,4,1,"button",34),r(),F(23,Ue,2,0,"sh-alert",35),r()}if(n&2){let e=u();s(5),P("type",e.showPassword()?"text":"password"),s(),d(e.exportForm.controls.password.errors!=null&&e.exportForm.controls.password.errors.required?6:e.exportForm.controls.password.errors!=null&&e.exportForm.controls.password.errors.minlength?7:-1),s(2),d(e.exportForm.value.password?8:-1),s(2),P("type",e.showPassword()?"text":"password"),s(),d(e.exportForm.value.repeatPassword&&e.exportForm.value.repeatPassword!==e.exportForm.value.password?11:e.exportForm.controls.repeatPassword.errors!=null&&e.exportForm.controls.repeatPassword.errors.required?12:e.exportForm.controls.repeatPassword.errors!=null&&e.exportForm.controls.repeatPassword.errors.minlength?13:-1),s(6),d(e.showPassword()?17:18),s(5),d(e.showCopyPassword()?22:-1),s(),d(e.exportForm.value.password&&e.exportForm.value.password===e.exportForm.value.repeatPassword?23:-1)}}function Je(n,o){if(n&1&&(a(0,"div",25)(1,"code"),$(2),r()()),n&2){let e=u();s(2),Z(e.exportedCmd())}}var f=new ue,k=class n{#o=C(Ie);#t=C(he);#e=C(ie);#n=C(re);#i=C(ne);#r=C(fe);isExporting=E(!1);exportType=E("file");exportedCmd=E(null);exportForm=f.group({exportPasswords:f.control(!0),encryption:f.control(!1,[g.required,we()]),password:f.control("",[v("encryption",!0,[g.required,g.minLength(3)])]),repeatPassword:f.control("",[v("encryption",!0,[g.required,g.minLength(3)])])});exportFormSignal=Re(this.exportForm.valueChanges);encryptionFieldSignal=A(()=>(this.exportFormSignal()?.encryption??!1)&&this.exportType()==="file");activeBackup=A(()=>this.#r.backups().find(o=>o.Backup?.ID===this.#e.snapshot.params.id));showPassword=E(!1);copiedPassword=E(!1);showCopyPassword=E(!1);calculatePasswordStrength=A(()=>{let e=this.exportFormSignal()?.password??"";return this.#o.calculatePasswordStrength(e)});showPasswordEffect=y(()=>{this.showPassword()&&this.exportForm.updateValueAndValidity()});disablePasswordForCommandLine=y(()=>{this.exportType()==="cmd"&&this.exportForm.controls.encryption.setValue(!1)});submit(){this.isExporting.set(!0),this.exportType()==="file"?this.#t.postApiV1AuthIssuetokenByOperation({operation:"export"}).pipe(W(o=>{let e=R=>{let O=Object.entries(R);return O?"?"+O.filter(([N,T])=>T!=null).map(([N,T])=>`${encodeURIComponent(N)}=${encodeURIComponent(T)}`).join("&"):""},t=this.exportFormSignal()?.password?.length?this.exportFormSignal()?.password:void 0,i=b.BASE||"";return this.#i.get(`${i}/api/v1/backup/${this.#e.snapshot.params.id}/export${e({"export-passwords":this.exportFormSignal()?.exportPasswords??void 0,passphrase:t,token:o.Token})}`,{responseType:"blob",headers:new te(Q({},b.HEADERS??{}))})}),M(()=>this.isExporting.set(!1))).subscribe({next:o=>{let t=this.activeBackup()?.Backup?.Name??"Backup",i=this.exportFormSignal()?.encryption?"aes":"json";this.downloadFile(o,`${t}-duplicati-config.${i}`),this.#n.navigate(["/"])},error:o=>{}}):this.#t.getApiV1BackupByIdExportCmdline({id:this.#e.snapshot.params.id,exportPasswords:this.exportFormSignal()?.exportPasswords??void 0,passphrase:this.exportFormSignal()?.password??void 0}).pipe(M(()=>this.isExporting.set(!1))).subscribe({next:o=>{this.exportedCmd.set(o.Command??null)},error:o=>{}})}downloadFile(o,e){let t=window.URL.createObjectURL(o),i=document.createElement("a");i.href=t,i.download=e,i.click(),window.URL.revokeObjectURL(t)}async copyPassword(){let o=this.exportForm.controls.password.value;await this.#s(o??""),this.copiedPassword.set(!0)}async#s(o){try{await navigator.clipboard.writeText(o)}catch{try{let t=document.createElement("textarea");t.value=o,document.body.appendChild(t),t.select(),document.execCommand("copy"),document.body.removeChild(t)}catch(t){console.error("Failed to copy text: ",t)}}}generatePassword(){this.copiedPassword.set(!1);let o=this.#o.generate(16);this.exportForm.controls.password.setValue(o),this.exportForm.controls.repeatPassword.setValue(o),this.showCopyPassword.set(!0)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=Y({type:n,selectors:[["app-export"]],decls:26,vars:16,consts:()=>{let o;o=$localize`${"\uFFFD#6\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#6\uFFFD"}:CLOSE_TAG_SH_ICON: Back `;let e;e=$localize`${"\uFFFD#9\uFFFD"}:START_TAG_SH_ICON:export${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SH_ICON: Export `;let t;t=$localize`${"\uFFFD#16\uFFFD"}:START_TAG_SH_ICON:terminal-window${"\uFFFD/#16\uFFFD"}:CLOSE_TAG_SH_ICON: As command line `;let i;i=$localize`${"\uFFFD#19\uFFFD"}:START_TAG_SH_ICON:file${"\uFFFD/#19\uFFFD"}:CLOSE_TAG_SH_ICON: To file `;let R;R=$localize` Export passwords ${"\uFFFD#22\uFFFD\uFFFD/#22\uFFFD"}:TAG_INPUT:`;let O;O=$localize` Encrypt file ${"\uFFFD#2\uFFFD\uFFFD/#2\uFFFD"}:TAG_INPUT:`;let N;N=$localize`Password`;let T;T=$localize`Repeat password`;let U;U=$localize` Create a password ${"\uFFFD#4\uFFFD"}:START_SUPERSCRIPT:*${"\uFFFD/#4\uFFFD"}:CLOSE_SUPERSCRIPT:`;let I;I=$localize`${"\uFFFD*17:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:eye-slash${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Hide ${"\uFFFD/*17:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*18:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:eye${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Show ${"\uFFFD/*18:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,I=B(I);let K;K=$localize`${"\uFFFD#21\uFFFD"}:START_TAG_SH_ICON:password${"\uFFFD/#21\uFFFD"}:CLOSE_TAG_SH_ICON: Generate password `;let J;J=$localize`Passwords are required`;let H;H=$localize` Passwords must be at least ${"\uFFFD0\uFFFD"}:INTERPOLATION: characters long `;let z;z=$localize`Passwords do not match`;let V;V=$localize`Passwords are required`;let q;q=$localize` Passwords must be at least ${"\uFFFD0\uFFFD"}:INTERPOLATION: characters long `;let w;w=$localize`${"\uFFFD*2:1\uFFFD"}:START_BLOCK_IF:${"\uFFFD#1:1\uFFFD"}:START_TAG_SH_ICON:check${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Copied password ${"\uFFFD/*2:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*3:2\uFFFD"}:START_BLOCK_ELSE:${"\uFFFD#1:2\uFFFD"}:START_TAG_SH_ICON_1:copy${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Copy password ${"\uFFFD/*3:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,w=B(w);let j;return j=$localize` Tip: Be sure to save your password. If you lose it, you will not be able to import the configuration. `,[o,e,t,i,R,O,U,I,K,J,H,z,V,q,w,j,[1,"actions"],["shButton","",1,"outlined",3,"routerLink"],["shButton","",1,"raised","primary",3,"click","shTooltip","disabled"],["autocomplete","off",3,"formGroup"],["type","button",3,"click"],[1,"raised","primary"],["type","checkbox","formControlName","exportPasswords"],[1,"primary","raised"],[1,"passwords"],[1,"cmd-output"],["type","checkbox","formControlName","encryption"],["for","password"],["id","password","tabindex","4","autocomplete","off","placeholder",N,"formControlName","password",3,"type"],["error",""],[1,"raised",3,"error","warn","primary","success","value"],["id","repeatPassword","tabindex","5","autocomplete","off","placeholder",T,"formControlName","repeatPassword",3,"type"],[1,"password-actions"],["shButton","","type","button",1,"small",3,"click"],["shButton","","type","button",1,"small","copy"],[1,"primary"],[1,"raised",3,"value"],["shButton","","type","button",1,"small","copy",3,"click"],[1,"sh-success"]]},template:function(e,t){if(e&1&&(a(0,"header")(1,"h3"),$(2," Export backup configuration "),a(3,"div",16)(4,"button",17),c(5,0),_(6,"sh-icon"),p(),r(),a(7,"button",18),m("click",function(){return t.submit()}),c(8,1),_(9,"sh-icon"),p(),r()()(),a(10,"p"),$(11),r()(),a(12,"form",19)(13,"sh-button-group")(14,"button",20),m("click",function(){return t.exportType.set("cmd")}),c(15,2),_(16,"sh-icon"),p(),r(),a(17,"button",20),m("click",function(){return t.exportType.set("file")}),c(18,3),_(19,"sh-icon"),p(),r()(),a(20,"sh-toggle",21),c(21,4),_(22,"input",22),p(),r(),F(23,xe,3,0,"sh-toggle",23),F(24,Ke,24,8,"div",24),F(25,Je,3,1,"div",25),r()),e&2){let i;s(4),P("routerLink",oe(15,De)),s(3),h("loading",t.isExporting()),P("shTooltip",t.encryptionFieldSignal()?"Remember to copy the password":"")("disabled",t.exportForm.invalid||t.showCopyPassword()&&!t.copiedPassword()||t.encryptionFieldSignal()&&t.exportForm.value.repeatPassword!==t.exportForm.value.password),s(4),ee("#",(i=t.activeBackup())==null||i.Backup==null?null:i.Backup.ID,": ",(i=t.activeBackup())==null||i.Backup==null?null:i.Backup.Name),s(),P("formGroup",t.exportForm),s(2),h("active",t.exportType()==="cmd"),s(3),h("active",t.exportType()==="file"),s(6),d(t.exportType()==="file"?23:-1),s(),d(t.encryptionFieldSignal()?24:-1),s(),d(t.exportedCmd()?25:-1)}},dependencies:[Te,pe,le,ae,_e,ce,de,Fe,se,Pe,Oe,Ce,me,Se,Ee,ge,Ne],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:2rem;padding:3rem}h3[_ngcontent-%COMP%]{font:var(--title-30);display:flex;align-items:center;justify-content:space-between}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;max-width:31.25rem}.passwords[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.password-actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;align-items:center}.copy[_ngcontent-%COMP%] sh-icon.sh-success[_ngcontent-%COMP%]{color:var(--success-8)}.hide[_ngcontent-%COMP%]{display:none}"],changeDetection:0})};export{k as default};
|
package/chunk-UNLX3IVU.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a}from"./chunk-MDXSNEQZ.js";import"./chunk-NK5WD6WE.js";import"./chunk-26Z7TPJB.js";import"./chunk-7CGTOI24.js";export{a as DurationFormatPipe};
|
package/chunk-UNMDSCAN.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{_ as pi,fa as Pt,wa as fi}from"./chunk-7AVOHYTE.js";import{a as Ft}from"./chunk-KDSMLI73.js";import{$ as w,$c as It,Ab as g,Bb as oe,Cb as A,Db as F,Eb as ye,Gc as ui,Hb as De,Ib as z,Lc as Tt,Mc as S,O as tt,Oa as ai,Pa as p,Q as X,Qc as se,R as we,Rc as m,S as Le,Sc as J,Tc as Nt,U as le,Ua as bt,Uc as H,Va as it,Vb as E,Vc as At,W as y,Wb as Se,Xa as de,Xb as f,Ya as D,Yb as T,Z as oi,Za as li,Zb as u,Zc as hi,_ as si,a as Jt,aa as x,bc as wt,cb as O,cc as ue,da as xe,db as He,dc as ie,ea as Oe,eb as R,ec as xt,fa as he,fc as G,g as ei,gb as U,gc as N,ha as pe,hb as fe,hc as Ot,ic as Z,jc as C,k as ti,kb as Mt,kc as Ne,la as v,lb as ci,lc as K,mc as nt,na as k,oa as ce,ob as Et,oc as Ue,p as ii,pa as Be,pc as ze,qa as Ce,qc as $e,rb as ge,rc as ot,sa as I,sb as b,sc as ne,tb as M,tc as L,ub as je,v as ni,vb as di,wa as ri,wb as Ve,wc as $,xb as Te,xc as st,yb as Q,yc as rt,zb as h,zc as Vt}from"./chunk-26Z7TPJB.js";import{a as P,b as j,c as Kt}from"./chunk-7CGTOI24.js";var bi=(()=>{class i{_renderer;_elementRef;onChange=e=>{};onTouched=()=>{};constructor(e,t){this._renderer=e,this._elementRef=t}setProperty(e,t){this._renderer.setProperty(this._elementRef.nativeElement,e,t)}registerOnTouched(e){this.onTouched=e}registerOnChange(e){this.onChange=e}setDisabledState(e){this.setProperty("disabled",e)}static \u0275fac=function(t){return new(t||i)(D(de),D(I))};static \u0275dir=R({type:i})}return i})(),Je=(()=>{class i extends bi{static \u0275fac=(()=>{let e;return function(n){return(e||(e=Ce(i)))(n||i)}})();static \u0275dir=R({type:i,features:[U]})}return i})(),ve=new le(""),Xi={provide:ve,useExisting:X(()=>Qi),multi:!0},Qi=(()=>{class i extends Je{writeValue(e){this.setProperty("checked",e)}static \u0275fac=(()=>{let e;return function(n){return(e||(e=Ce(i)))(n||i)}})();static \u0275dir=R({type:i,selectors:[["input","type","checkbox","formControlName",""],["input","type","checkbox","formControl",""],["input","type","checkbox","ngModel",""]],hostBindings:function(t,n){t&1&&E("change",function(r){return n.onChange(r.target.checked)})("blur",function(){return n.onTouched()})},standalone:!1,features:[$([Xi]),U]})}return i})(),Zi={provide:ve,useExisting:X(()=>Mi),multi:!0};function Ki(){let i=Ft()?Ft().getUserAgent():"";return/android (\d+)/.test(i.toLowerCase())}var Ji=new le(""),Mi=(()=>{class i extends bi{_compositionMode;_composing=!1;constructor(e,t,n){super(e,t),this._compositionMode=n,this._compositionMode==null&&(this._compositionMode=!Ki())}writeValue(e){let t=e??"";this.setProperty("value",t)}_handleInput(e){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(e)}_compositionStart(){this._composing=!0}_compositionEnd(e){this._composing=!1,this._compositionMode&&this.onChange(e)}static \u0275fac=function(t){return new(t||i)(D(de),D(I),D(Ji,8))};static \u0275dir=R({type:i,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(t,n){t&1&&E("input",function(r){return n._handleInput(r.target.value)})("blur",function(){return n.onTouched()})("compositionstart",function(){return n._compositionStart()})("compositionend",function(r){return n._compositionEnd(r.target.value)})},standalone:!1,features:[$([Zi]),U]})}return i})();function Bt(i){return i==null||Ht(i)===0}function Ht(i){return i==null?null:Array.isArray(i)||typeof i=="string"?i.length:i instanceof Set?i.size:null}var be=new le(""),Me=new le(""),en=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,gi=class{static min(o){return tn(o)}static max(o){return nn(o)}static required(o){return on(o)}static requiredTrue(o){return sn(o)}static email(o){return rn(o)}static minLength(o){return an(o)}static maxLength(o){return ln(o)}static pattern(o){return cn(o)}static nullValidator(o){return Ei()}static compose(o){return Ni(o)}static composeAsync(o){return Ai(o)}};function tn(i){return o=>{if(o.value==null||i==null)return null;let e=parseFloat(o.value);return!isNaN(e)&&e<i?{min:{min:i,actual:o.value}}:null}}function nn(i){return o=>{if(o.value==null||i==null)return null;let e=parseFloat(o.value);return!isNaN(e)&&e>i?{max:{max:i,actual:o.value}}:null}}function on(i){return Bt(i.value)?{required:!0}:null}function sn(i){return i.value===!0?null:{required:!0}}function rn(i){return Bt(i.value)||en.test(i.value)?null:{email:!0}}function an(i){return o=>{let e=o.value?.length??Ht(o.value);return e===null||e===0?null:e<i?{minlength:{requiredLength:i,actualLength:e}}:null}}function ln(i){return o=>{let e=o.value?.length??Ht(o.value);return e!==null&&e>i?{maxlength:{requiredLength:i,actualLength:e}}:null}}function cn(i){if(!i)return Ei;let o,e;return typeof i=="string"?(e="",i.charAt(0)!=="^"&&(e+="^"),e+=i,i.charAt(i.length-1)!=="$"&&(e+="$"),o=new RegExp(e)):(e=i.toString(),o=i),t=>{if(Bt(t.value))return null;let n=t.value;return o.test(n)?null:{pattern:{requiredPattern:e,actualValue:n}}}}function Ei(i){return null}function wi(i){return i!=null}function xi(i){return ci(i)?ti(i):i}function Oi(i){let o={};return i.forEach(e=>{o=e!=null?P(P({},o),e):o}),Object.keys(o).length===0?null:o}function Vi(i,o){return o.map(e=>e(i))}function dn(i){return!i.validate}function Ti(i){return i.map(o=>dn(o)?o:e=>o.validate(e))}function Ni(i){if(!i)return null;let o=i.filter(wi);return o.length==0?null:function(e){return Oi(Vi(e,o))}}function jt(i){return i!=null?Ni(Ti(i)):null}function Ai(i){if(!i)return null;let o=i.filter(wi);return o.length==0?null:function(e){let t=Vi(e,o).map(xi);return ni(t).pipe(ii(Oi))}}function Ut(i){return i!=null?Ai(Ti(i)):null}function mi(i,o){return i===null?[o]:Array.isArray(i)?[...i,o]:[i,o]}function Ii(i){return i._rawValidators}function Fi(i){return i._rawAsyncValidators}function kt(i){return i?Array.isArray(i)?i:[i]:[]}function lt(i,o){return Array.isArray(i)?i.includes(o):i===o}function vi(i,o){let e=kt(o);return kt(i).forEach(n=>{lt(e,n)||e.push(n)}),e}function _i(i,o){return kt(o).filter(e=>!lt(i,e))}var ct=class{get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators=[];_rawAsyncValidators=[];_setValidators(o){this._rawValidators=o||[],this._composedValidatorFn=jt(this._rawValidators)}_setAsyncValidators(o){this._rawAsyncValidators=o||[],this._composedAsyncValidatorFn=Ut(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_onDestroyCallbacks=[];_registerOnDestroy(o){this._onDestroyCallbacks.push(o)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(o=>o()),this._onDestroyCallbacks=[]}reset(o=void 0){this.control&&this.control.reset(o)}hasError(o,e){return this.control?this.control.hasError(o,e):!1}getError(o,e){return this.control?this.control.getError(o,e):null}},W=class extends ct{name;get formDirective(){return null}get path(){return null}},re=class extends ct{_parent=null;name=null;valueAccessor=null},dt=class{_cd;constructor(o){this._cd=o}get isTouched(){return this._cd?.control?._touched?.(),!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return this._cd?.control?._pristine?.(),!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return this._cd?.control?._status?.(),!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return this._cd?._submitted?.(),!!this._cd?.submitted}};var Dr=(()=>{class i extends dt{constructor(e){super(e)}static \u0275fac=function(t){return new(t||i)(D(re,2))};static \u0275dir=R({type:i,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(t,n){t&2&&N("ng-untouched",n.isUntouched)("ng-touched",n.isTouched)("ng-pristine",n.isPristine)("ng-dirty",n.isDirty)("ng-valid",n.isValid)("ng-invalid",n.isInvalid)("ng-pending",n.isPending)},standalone:!1,features:[U]})}return i})(),Sr=(()=>{class i extends dt{constructor(e){super(e)}static \u0275fac=function(t){return new(t||i)(D(W,10))};static \u0275dir=R({type:i,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["","formArray",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:16,hostBindings:function(t,n){t&2&&N("ng-untouched",n.isUntouched)("ng-touched",n.isTouched)("ng-pristine",n.isPristine)("ng-dirty",n.isDirty)("ng-valid",n.isValid)("ng-invalid",n.isInvalid)("ng-pending",n.isPending)("ng-submitted",n.isSubmitted)},standalone:!1,features:[U]})}return i})();var We="VALID",at="INVALID",Ae="PENDING",Ge="DISABLED",me=class{},ut=class extends me{value;source;constructor(o,e){super(),this.value=o,this.source=e}},Ye=class extends me{pristine;source;constructor(o,e){super(),this.pristine=o,this.source=e}},Xe=class extends me{touched;source;constructor(o,e){super(),this.touched=o,this.source=e}},Ie=class extends me{status;source;constructor(o,e){super(),this.status=o,this.source=e}},ht=class extends me{source;constructor(o){super(),this.source=o}},Ze=class extends me{source;constructor(o){super(),this.source=o}};function zt(i){return(mt(i)?i.validators:i)||null}function un(i){return Array.isArray(i)?jt(i):i||null}function $t(i,o){return(mt(o)?o.asyncValidators:i)||null}function hn(i){return Array.isArray(i)?Ut(i):i||null}function mt(i){return i!=null&&!Array.isArray(i)&&typeof i=="object"}function Pi(i,o,e){let t=i.controls;if(!(o?Object.keys(t):t).length)throw new tt(1e3,"");if(!t[e])throw new tt(1001,"")}function ki(i,o,e){i._forEachChild((t,n)=>{if(e[n]===void 0)throw new tt(1002,"")})}var Fe=class{_pendingDirty=!1;_hasOwnPendingAsyncValidator=null;_pendingTouched=!1;_onCollectionChange=()=>{};_updateOn;_parent=null;_asyncValidationSubscription;_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators;_rawAsyncValidators;value;constructor(o,e){this._assignValidators(o),this._assignAsyncValidators(e)}get validator(){return this._composedValidatorFn}set validator(o){this._rawValidators=this._composedValidatorFn=o}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(o){this._rawAsyncValidators=this._composedAsyncValidatorFn=o}get parent(){return this._parent}get status(){return ce(this.statusReactive)}set status(o){ce(()=>this.statusReactive.set(o))}_status=S(()=>this.statusReactive());statusReactive=v(void 0);get valid(){return this.status===We}get invalid(){return this.status===at}get pending(){return this.status==Ae}get disabled(){return this.status===Ge}get enabled(){return this.status!==Ge}errors;get pristine(){return ce(this.pristineReactive)}set pristine(o){ce(()=>this.pristineReactive.set(o))}_pristine=S(()=>this.pristineReactive());pristineReactive=v(!0);get dirty(){return!this.pristine}get touched(){return ce(this.touchedReactive)}set touched(o){ce(()=>this.touchedReactive.set(o))}_touched=S(()=>this.touchedReactive());touchedReactive=v(!1);get untouched(){return!this.touched}_events=new ei;events=this._events.asObservable();valueChanges;statusChanges;get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(o){this._assignValidators(o)}setAsyncValidators(o){this._assignAsyncValidators(o)}addValidators(o){this.setValidators(vi(o,this._rawValidators))}addAsyncValidators(o){this.setAsyncValidators(vi(o,this._rawAsyncValidators))}removeValidators(o){this.setValidators(_i(o,this._rawValidators))}removeAsyncValidators(o){this.setAsyncValidators(_i(o,this._rawAsyncValidators))}hasValidator(o){return lt(this._rawValidators,o)}hasAsyncValidator(o){return lt(this._rawAsyncValidators,o)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(o={}){let e=this.touched===!1;this.touched=!0;let t=o.sourceControl??this;this._parent&&!o.onlySelf&&this._parent.markAsTouched(j(P({},o),{sourceControl:t})),e&&o.emitEvent!==!1&&this._events.next(new Xe(!0,t))}markAllAsDirty(o={}){this.markAsDirty({onlySelf:!0,emitEvent:o.emitEvent,sourceControl:this}),this._forEachChild(e=>e.markAllAsDirty(o))}markAllAsTouched(o={}){this.markAsTouched({onlySelf:!0,emitEvent:o.emitEvent,sourceControl:this}),this._forEachChild(e=>e.markAllAsTouched(o))}markAsUntouched(o={}){let e=this.touched===!0;this.touched=!1,this._pendingTouched=!1;let t=o.sourceControl??this;this._forEachChild(n=>{n.markAsUntouched({onlySelf:!0,emitEvent:o.emitEvent,sourceControl:t})}),this._parent&&!o.onlySelf&&this._parent._updateTouched(o,t),e&&o.emitEvent!==!1&&this._events.next(new Xe(!1,t))}markAsDirty(o={}){let e=this.pristine===!0;this.pristine=!1;let t=o.sourceControl??this;this._parent&&!o.onlySelf&&this._parent.markAsDirty(j(P({},o),{sourceControl:t})),e&&o.emitEvent!==!1&&this._events.next(new Ye(!1,t))}markAsPristine(o={}){let e=this.pristine===!1;this.pristine=!0,this._pendingDirty=!1;let t=o.sourceControl??this;this._forEachChild(n=>{n.markAsPristine({onlySelf:!0,emitEvent:o.emitEvent})}),this._parent&&!o.onlySelf&&this._parent._updatePristine(o,t),e&&o.emitEvent!==!1&&this._events.next(new Ye(!0,t))}markAsPending(o={}){this.status=Ae;let e=o.sourceControl??this;o.emitEvent!==!1&&(this._events.next(new Ie(this.status,e)),this.statusChanges.emit(this.status)),this._parent&&!o.onlySelf&&this._parent.markAsPending(j(P({},o),{sourceControl:e}))}disable(o={}){let e=this._parentMarkedDirty(o.onlySelf);this.status=Ge,this.errors=null,this._forEachChild(n=>{n.disable(j(P({},o),{onlySelf:!0}))}),this._updateValue();let t=o.sourceControl??this;o.emitEvent!==!1&&(this._events.next(new ut(this.value,t)),this._events.next(new Ie(this.status,t)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(j(P({},o),{skipPristineCheck:e}),this),this._onDisabledChange.forEach(n=>n(!0))}enable(o={}){let e=this._parentMarkedDirty(o.onlySelf);this.status=We,this._forEachChild(t=>{t.enable(j(P({},o),{onlySelf:!0}))}),this.updateValueAndValidity({onlySelf:!0,emitEvent:o.emitEvent}),this._updateAncestors(j(P({},o),{skipPristineCheck:e}),this),this._onDisabledChange.forEach(t=>t(!1))}_updateAncestors(o,e){this._parent&&!o.onlySelf&&(this._parent.updateValueAndValidity(o),o.skipPristineCheck||this._parent._updatePristine({},e),this._parent._updateTouched({},e))}setParent(o){this._parent=o}getRawValue(){return this.value}updateValueAndValidity(o={}){if(this._setInitialStatus(),this._updateValue(),this.enabled){let t=this._cancelExistingSubscription();this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===We||this.status===Ae)&&this._runAsyncValidator(t,o.emitEvent)}let e=o.sourceControl??this;o.emitEvent!==!1&&(this._events.next(new ut(this.value,e)),this._events.next(new Ie(this.status,e)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!o.onlySelf&&this._parent.updateValueAndValidity(j(P({},o),{sourceControl:e}))}_updateTreeValidity(o={emitEvent:!0}){this._forEachChild(e=>e._updateTreeValidity(o)),this.updateValueAndValidity({onlySelf:!0,emitEvent:o.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?Ge:We}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(o,e){if(this.asyncValidator){this.status=Ae,this._hasOwnPendingAsyncValidator={emitEvent:e!==!1,shouldHaveEmitted:o!==!1};let t=xi(this.asyncValidator(this));this._asyncValidationSubscription=t.subscribe(n=>{this._hasOwnPendingAsyncValidator=null,this.setErrors(n,{emitEvent:e,shouldHaveEmitted:o})})}}_cancelExistingSubscription(){if(this._asyncValidationSubscription){this._asyncValidationSubscription.unsubscribe();let o=(this._hasOwnPendingAsyncValidator?.emitEvent||this._hasOwnPendingAsyncValidator?.shouldHaveEmitted)??!1;return this._hasOwnPendingAsyncValidator=null,o}return!1}setErrors(o,e={}){this.errors=o,this._updateControlsErrors(e.emitEvent!==!1,this,e.shouldHaveEmitted)}get(o){let e=o;return e==null||(Array.isArray(e)||(e=e.split(".")),e.length===0)?null:e.reduce((t,n)=>t&&t._find(n),this)}getError(o,e){let t=e?this.get(e):this;return t&&t.errors?t.errors[o]:null}hasError(o,e){return!!this.getError(o,e)}get root(){let o=this;for(;o._parent;)o=o._parent;return o}_updateControlsErrors(o,e,t){this.status=this._calculateStatus(),o&&this.statusChanges.emit(this.status),(o||t)&&this._events.next(new Ie(this.status,e)),this._parent&&this._parent._updateControlsErrors(o,e,t)}_initObservables(){this.valueChanges=new pe,this.statusChanges=new pe}_calculateStatus(){return this._allControlsDisabled()?Ge:this.errors?at:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(Ae)?Ae:this._anyControlsHaveStatus(at)?at:We}_anyControlsHaveStatus(o){return this._anyControls(e=>e.status===o)}_anyControlsDirty(){return this._anyControls(o=>o.dirty)}_anyControlsTouched(){return this._anyControls(o=>o.touched)}_updatePristine(o,e){let t=!this._anyControlsDirty(),n=this.pristine!==t;this.pristine=t,this._parent&&!o.onlySelf&&this._parent._updatePristine(o,e),n&&this._events.next(new Ye(this.pristine,e))}_updateTouched(o={},e){this.touched=this._anyControlsTouched(),this._events.next(new Xe(this.touched,e)),this._parent&&!o.onlySelf&&this._parent._updateTouched(o,e)}_onDisabledChange=[];_registerOnCollectionChange(o){this._onCollectionChange=o}_setUpdateStrategy(o){mt(o)&&o.updateOn!=null&&(this._updateOn=o.updateOn)}_parentMarkedDirty(o){let e=this._parent&&this._parent.dirty;return!o&&!!e&&!this._parent._anyControlsDirty()}_find(o){return null}_assignValidators(o){this._rawValidators=Array.isArray(o)?o.slice():o,this._composedValidatorFn=un(this._rawValidators)}_assignAsyncValidators(o){this._rawAsyncValidators=Array.isArray(o)?o.slice():o,this._composedAsyncValidatorFn=hn(this._rawAsyncValidators)}},Pe=class extends Fe{constructor(o,e,t){super(zt(e),$t(t,e)),this.controls=o,this._initObservables(),this._setUpdateStrategy(e),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;registerControl(o,e){return this.controls[o]?this.controls[o]:(this.controls[o]=e,e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange),e)}addControl(o,e,t={}){this.registerControl(o,e),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}removeControl(o,e={}){this.controls[o]&&this.controls[o]._registerOnCollectionChange(()=>{}),delete this.controls[o],this.updateValueAndValidity({emitEvent:e.emitEvent}),this._onCollectionChange()}setControl(o,e,t={}){this.controls[o]&&this.controls[o]._registerOnCollectionChange(()=>{}),delete this.controls[o],e&&this.registerControl(o,e),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}contains(o){return this.controls.hasOwnProperty(o)&&this.controls[o].enabled}setValue(o,e={}){ki(this,!0,o),Object.keys(o).forEach(t=>{Pi(this,!0,t),this.controls[t].setValue(o[t],{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e)}patchValue(o,e={}){o!=null&&(Object.keys(o).forEach(t=>{let n=this.controls[t];n&&n.patchValue(o[t],{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e))}reset(o={},e={}){this._forEachChild((t,n)=>{t.reset(o?o[n]:null,j(P({},e),{onlySelf:!0}))}),this._updatePristine(e,this),this._updateTouched(e,this),this.updateValueAndValidity(e),e?.emitEvent!==!1&&this._events.next(new Ze(this))}getRawValue(){return this._reduceChildren({},(o,e,t)=>(o[t]=e.getRawValue(),o))}_syncPendingControls(){let o=this._reduceChildren(!1,(e,t)=>t._syncPendingControls()?!0:e);return o&&this.updateValueAndValidity({onlySelf:!0}),o}_forEachChild(o){Object.keys(this.controls).forEach(e=>{let t=this.controls[e];t&&o(t,e)})}_setUpControls(){this._forEachChild(o=>{o.setParent(this),o._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(o){for(let[e,t]of Object.entries(this.controls))if(this.contains(e)&&o(t))return!0;return!1}_reduceValue(){let o={};return this._reduceChildren(o,(e,t,n)=>((t.enabled||this.disabled)&&(e[n]=t.value),e))}_reduceChildren(o,e){let t=o;return this._forEachChild((n,s)=>{t=e(t,n,s)}),t}_allControlsDisabled(){for(let o of Object.keys(this.controls))if(this.controls[o].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(o){return this.controls.hasOwnProperty(o)?this.controls[o]:null}};var Rt=class extends Pe{};var Ee=new le("",{factory:()=>et}),et="always";function vt(i,o){return[...o.path,i]}function Ke(i,o,e=et){Wt(i,o),o.valueAccessor.writeValue(i.value),(i.disabled||e==="always")&&o.valueAccessor.setDisabledState?.(i.disabled),fn(i,o),mn(i,o),gn(i,o),pn(i,o)}function pt(i,o,e=!0){let t=()=>{};o.valueAccessor&&(o.valueAccessor.registerOnChange(t),o.valueAccessor.registerOnTouched(t)),gt(i,o),i&&(o._invokeOnDestroyCallbacks(),i._registerOnCollectionChange(()=>{}))}function ft(i,o){i.forEach(e=>{e.registerOnValidatorChange&&e.registerOnValidatorChange(o)})}function pn(i,o){if(o.valueAccessor.setDisabledState){let e=t=>{o.valueAccessor.setDisabledState(t)};i.registerOnDisabledChange(e),o._registerOnDestroy(()=>{i._unregisterOnDisabledChange(e)})}}function Wt(i,o){let e=Ii(i);o.validator!==null?i.setValidators(mi(e,o.validator)):typeof e=="function"&&i.setValidators([e]);let t=Fi(i);o.asyncValidator!==null?i.setAsyncValidators(mi(t,o.asyncValidator)):typeof t=="function"&&i.setAsyncValidators([t]);let n=()=>i.updateValueAndValidity();ft(o._rawValidators,n),ft(o._rawAsyncValidators,n)}function gt(i,o){let e=!1;if(i!==null){if(o.validator!==null){let n=Ii(i);if(Array.isArray(n)&&n.length>0){let s=n.filter(r=>r!==o.validator);s.length!==n.length&&(e=!0,i.setValidators(s))}}if(o.asyncValidator!==null){let n=Fi(i);if(Array.isArray(n)&&n.length>0){let s=n.filter(r=>r!==o.asyncValidator);s.length!==n.length&&(e=!0,i.setAsyncValidators(s))}}}let t=()=>{};return ft(o._rawValidators,t),ft(o._rawAsyncValidators,t),e}function fn(i,o){o.valueAccessor.registerOnChange(e=>{i._pendingValue=e,i._pendingChange=!0,i._pendingDirty=!0,i.updateOn==="change"&&Ri(i,o)})}function gn(i,o){o.valueAccessor.registerOnTouched(()=>{i._pendingTouched=!0,i.updateOn==="blur"&&i._pendingChange&&Ri(i,o),i.updateOn!=="submit"&&i.markAsTouched()})}function Ri(i,o){i._pendingDirty&&i.markAsDirty(),i.setValue(i._pendingValue,{emitModelToViewChange:!1}),o.viewToModelUpdate(i._pendingValue),i._pendingChange=!1}function mn(i,o){let e=(t,n)=>{o.valueAccessor.writeValue(t),n&&o.viewToModelUpdate(t)};i.registerOnChange(e),o._registerOnDestroy(()=>{i._unregisterOnChange(e)})}function Li(i,o){i==null,Wt(i,o)}function vn(i,o){return gt(i,o)}function Gt(i,o){if(!i.hasOwnProperty("model"))return!1;let e=i.model;return e.isFirstChange()?!0:!Object.is(o,e.currentValue)}function _n(i){return Object.getPrototypeOf(i.constructor)===Je}function Bi(i,o){i._syncPendingControls(),o.forEach(e=>{let t=e.control;t.updateOn==="submit"&&t._pendingChange&&(e.viewToModelUpdate(t._pendingValue),t._pendingChange=!1)})}function qt(i,o){if(!o)return null;Array.isArray(o);let e,t,n;return o.forEach(s=>{s.constructor===Mi?e=s:_n(s)?t=s:n=s}),n||t||e||null}function Cn(i,o){let e=i.indexOf(o);e>-1&&i.splice(e,1)}var yn={provide:W,useExisting:X(()=>Dn)},qe=Promise.resolve(),Dn=(()=>{class i extends W{callSetDisabledState;get submitted(){return ce(this.submittedReactive)}_submitted=S(()=>this.submittedReactive());submittedReactive=v(!1);_directives=new Set;form;ngSubmit=new pe;options;constructor(e,t,n){super(),this.callSetDisabledState=n,this.form=new Pe({},jt(e),Ut(t))}ngAfterViewInit(){this._setUpdateStrategy()}get formDirective(){return this}get control(){return this.form}get path(){return[]}get controls(){return this.form.controls}addControl(e){qe.then(()=>{let t=this._findContainer(e.path);e.control=t.registerControl(e.name,e.control),Ke(e.control,e,this.callSetDisabledState),e.control.updateValueAndValidity({emitEvent:!1}),this._directives.add(e)})}getControl(e){return this.form.get(e.path)}removeControl(e){qe.then(()=>{let t=this._findContainer(e.path);t&&t.removeControl(e.name),this._directives.delete(e)})}addFormGroup(e){qe.then(()=>{let t=this._findContainer(e.path),n=new Pe({});Li(n,e),t.registerControl(e.name,n),n.updateValueAndValidity({emitEvent:!1})})}removeFormGroup(e){qe.then(()=>{let t=this._findContainer(e.path);t&&t.removeControl(e.name)})}getFormGroup(e){return this.form.get(e.path)}updateModel(e,t){qe.then(()=>{this.form.get(e.path).setValue(t)})}setValue(e){this.control.setValue(e)}onSubmit(e){return this.submittedReactive.set(!0),Bi(this.form,this._directives),this.ngSubmit.emit(e),this.form._events.next(new ht(this.control)),e?.target?.method==="dialog"}onReset(){this.resetForm()}resetForm(e=void 0){this.form.reset(e),this.submittedReactive.set(!1)}_setUpdateStrategy(){this.options&&this.options.updateOn!=null&&(this.form._updateOn=this.options.updateOn)}_findContainer(e){return e.pop(),e.length?this.form.get(e):this.form}static \u0275fac=function(t){return new(t||i)(D(be,10),D(Me,10),D(Ee,8))};static \u0275dir=R({type:i,selectors:[["form",3,"ngNoForm","",3,"formGroup","",3,"formArray",""],["ng-form"],["","ngForm",""]],hostBindings:function(t,n){t&1&&E("submit",function(r){return n.onSubmit(r)})("reset",function(){return n.onReset()})},inputs:{options:[0,"ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[$([yn]),U]})}return i})();function Ci(i,o){let e=i.indexOf(o);e>-1&&i.splice(e,1)}function yi(i){return typeof i=="object"&&i!==null&&Object.keys(i).length===2&&"value"in i&&"disabled"in i}var Qe=class extends Fe{defaultValue=null;_onChange=[];_pendingValue;_pendingChange=!1;constructor(o=null,e,t){super(zt(e),$t(t,e)),this._applyFormState(o),this._setUpdateStrategy(e),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),mt(e)&&(e.nonNullable||e.initialValueIsDefault)&&(yi(o)?this.defaultValue=o.value:this.defaultValue=o)}setValue(o,e={}){this.value=this._pendingValue=o,this._onChange.length&&e.emitModelToViewChange!==!1&&this._onChange.forEach(t=>t(this.value,e.emitViewToModelChange!==!1)),this.updateValueAndValidity(e)}patchValue(o,e={}){this.setValue(o,e)}reset(o=this.defaultValue,e={}){this._applyFormState(o),this.markAsPristine(e),this.markAsUntouched(e),this.setValue(this.value,e),e.overwriteDefaultValue&&(this.defaultValue=this.value),this._pendingChange=!1,e?.emitEvent!==!1&&this._events.next(new Ze(this))}_updateValue(){}_anyControls(o){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(o){this._onChange.push(o)}_unregisterOnChange(o){Ci(this._onChange,o)}registerOnDisabledChange(o){this._onDisabledChange.push(o)}_unregisterOnDisabledChange(o){Ci(this._onDisabledChange,o)}_forEachChild(o){}_syncPendingControls(){return this.updateOn==="submit"&&(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),this._pendingChange)?(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),!0):!1}_applyFormState(o){yi(o)?(this.value=this._pendingValue=o.value,o.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=o}};var Sn=i=>i instanceof Qe,bn=(()=>{class i extends W{_parent;ngOnInit(){this._checkParentType(),this.formDirective.addFormGroup(this)}ngOnDestroy(){this.formDirective&&this.formDirective.removeFormGroup(this)}get control(){return this.formDirective.getFormGroup(this)}get path(){return vt(this.name==null?this.name:this.name.toString(),this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}_checkParentType(){}static \u0275fac=(()=>{let e;return function(n){return(e||(e=Ce(i)))(n||i)}})();static \u0275dir=R({type:i,standalone:!1,features:[U]})}return i})();var Mn={provide:re,useExisting:X(()=>_t)},Di=Promise.resolve(),_t=(()=>{class i extends re{_changeDetectorRef;callSetDisabledState;control=new Qe;static ngAcceptInputType_isDisabled;_registered=!1;viewModel;name="";isDisabled;model;options;update=new pe;constructor(e,t,n,s,r,a){super(),this._changeDetectorRef=r,this.callSetDisabledState=a,this._parent=e,this._setValidators(t),this._setAsyncValidators(n),this.valueAccessor=qt(this,s)}ngOnChanges(e){if(this._checkForErrors(),!this._registered||"name"in e){if(this._registered&&(this._checkName(),this.formDirective)){let t=e.name.previousValue;this.formDirective.removeControl({name:t,path:this._getPath(t)})}this._setUpControl()}"isDisabled"in e&&this._updateDisabled(e),Gt(e,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(e){this.viewModel=e,this.update.emit(e)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&this.options.updateOn!=null&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!!(this.options&&this.options.standalone)}_setUpStandalone(){Ke(this.control,this,this.callSetDisabledState),this.control.updateValueAndValidity({emitEvent:!1})}_checkForErrors(){this._checkName()}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),!this._isStandalone()&&this.name}_updateValue(e){Di.then(()=>{this.control.setValue(e,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(e){let t=e.isDisabled.currentValue,n=t!==0&&hi(t);Di.then(()=>{n&&!this.control.disabled?this.control.disable():!n&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(e){return this._parent?vt(e,this._parent):[e]}static \u0275fac=function(t){return new(t||i)(D(W,9),D(be,10),D(Me,10),D(ve,10),D(At,8),D(Ee,8))};static \u0275dir=R({type:i,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"],options:[0,"ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],standalone:!1,features:[$([Mn]),U,Be]})}return i})();var Mr=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=R({type:i,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""],standalone:!1})}return i})(),En={provide:ve,useExisting:X(()=>wn),multi:!0},wn=(()=>{class i extends Je{writeValue(e){let t=e??"";this.setProperty("value",t)}registerOnChange(e){this.onChange=t=>{e(t==""?null:parseFloat(t))}}static \u0275fac=(()=>{let e;return function(n){return(e||(e=Ce(i)))(n||i)}})();static \u0275dir=R({type:i,selectors:[["input","type","number","formControlName",""],["input","type","number","formControl",""],["input","type","number","ngModel",""]],hostBindings:function(t,n){t&1&&E("input",function(r){return n.onChange(r.target.value)})("blur",function(){return n.onTouched()})},standalone:!1,features:[$([En]),U]})}return i})(),xn={provide:ve,useExisting:X(()=>Vn),multi:!0};var On=(()=>{class i{_accessors=[];add(e,t){this._accessors.push([e,t])}remove(e){for(let t=this._accessors.length-1;t>=0;--t)if(this._accessors[t][1]===e){this._accessors.splice(t,1);return}}select(e){this._accessors.forEach(t=>{this._isSameGroup(t,e)&&t[1]!==e&&t[1].fireUncheck(e.value)})}_isSameGroup(e,t){return e[0].control?e[0]._parent===t._control._parent&&e[1].name===t.name:!1}static \u0275fac=function(t){return new(t||i)};static \u0275prov=we({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})(),Vn=(()=>{class i extends Je{_registry;_injector;_state;_control;_fn;setDisabledStateFired=!1;onChange=()=>{};name;formControlName;value;callSetDisabledState=y(Ee,{optional:!0})??et;constructor(e,t,n,s){super(e,t),this._registry=n,this._injector=s}ngOnInit(){this._control=this._injector.get(re),this._checkName(),this._registry.add(this._control,this)}ngOnDestroy(){this._registry.remove(this)}writeValue(e){this._state=e===this.value,this.setProperty("checked",this._state)}registerOnChange(e){this._fn=e,this.onChange=()=>{e(this.value),this._registry.select(this)}}setDisabledState(e){(this.setDisabledStateFired||e||this.callSetDisabledState==="whenDisabledForLegacyCode")&&this.setProperty("disabled",e),this.setDisabledStateFired=!0}fireUncheck(e){this.writeValue(e)}_checkName(){this.name&&this.formControlName&&(this.name,this.formControlName),!this.name&&this.formControlName&&(this.name=this.formControlName)}static \u0275fac=function(t){return new(t||i)(D(de),D(I),D(On),D(xe))};static \u0275dir=R({type:i,selectors:[["input","type","radio","formControlName",""],["input","type","radio","formControl",""],["input","type","radio","ngModel",""]],hostBindings:function(t,n){t&1&&E("change",function(){return n.onChange()})("blur",function(){return n.onTouched()})},inputs:{name:"name",formControlName:"formControlName",value:"value"},standalone:!1,features:[$([xn]),U]})}return i})(),Tn={provide:ve,useExisting:X(()=>Nn),multi:!0},Nn=(()=>{class i extends Je{writeValue(e){this.setProperty("value",parseFloat(e))}registerOnChange(e){this.onChange=t=>{e(t==""?null:parseFloat(t))}}static \u0275fac=(()=>{let e;return function(n){return(e||(e=Ce(i)))(n||i)}})();static \u0275dir=R({type:i,selectors:[["input","type","range","formControlName",""],["input","type","range","formControl",""],["input","type","range","ngModel",""]],hostBindings:function(t,n){t&1&&E("change",function(r){return n.onChange(r.target.value)})("input",function(r){return n.onChange(r.target.value)})("blur",function(){return n.onTouched()})},standalone:!1,features:[$([Tn]),U]})}return i})(),Lt=class extends Fe{constructor(o,e,t){super(zt(e),$t(t,e)),this.controls=o,this._initObservables(),this._setUpdateStrategy(e),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}controls;at(o){return this.controls[this._adjustIndex(o)]}push(o,e={}){Array.isArray(o)?o.forEach(t=>{this.controls.push(t),this._registerControl(t)}):(this.controls.push(o),this._registerControl(o)),this.updateValueAndValidity({emitEvent:e.emitEvent}),this._onCollectionChange()}insert(o,e,t={}){this.controls.splice(o,0,e),this._registerControl(e),this.updateValueAndValidity({emitEvent:t.emitEvent})}removeAt(o,e={}){let t=this._adjustIndex(o);t<0&&(t=0),this.controls[t]&&this.controls[t]._registerOnCollectionChange(()=>{}),this.controls.splice(t,1),this.updateValueAndValidity({emitEvent:e.emitEvent})}setControl(o,e,t={}){let n=this._adjustIndex(o);n<0&&(n=0),this.controls[n]&&this.controls[n]._registerOnCollectionChange(()=>{}),this.controls.splice(n,1),e&&(this.controls.splice(n,0,e),this._registerControl(e)),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}get length(){return this.controls.length}setValue(o,e={}){ki(this,!1,o),o.forEach((t,n)=>{Pi(this,!1,n),this.at(n).setValue(t,{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e)}patchValue(o,e={}){o!=null&&(o.forEach((t,n)=>{this.at(n)&&this.at(n).patchValue(t,{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e))}reset(o=[],e={}){this._forEachChild((t,n)=>{t.reset(o[n],j(P({},e),{onlySelf:!0}))}),this._updatePristine(e,this),this._updateTouched(e,this),this.updateValueAndValidity(e),e?.emitEvent!==!1&&this._events.next(new Ze(this))}getRawValue(){return this.controls.map(o=>o.getRawValue())}clear(o={}){this.controls.length<1||(this._forEachChild(e=>e._registerOnCollectionChange(()=>{})),this.controls.splice(0),this.updateValueAndValidity({emitEvent:o.emitEvent}))}_adjustIndex(o){return o<0?o+this.length:o}_syncPendingControls(){let o=this.controls.reduce((e,t)=>t._syncPendingControls()?!0:e,!1);return o&&this.updateValueAndValidity({onlySelf:!0}),o}_forEachChild(o){this.controls.forEach((e,t)=>{o(e,t)})}_updateValue(){this.value=this.controls.filter(o=>o.enabled||this.disabled).map(o=>o.value)}_anyControls(o){return this.controls.some(e=>e.enabled&&o(e))}_setUpControls(){this._forEachChild(o=>this._registerControl(o))}_allControlsDisabled(){for(let o of this.controls)if(o.enabled)return!1;return this.controls.length>0||this.disabled}_registerControl(o){o.setParent(this),o._registerOnCollectionChange(this._onCollectionChange)}_find(o){return this.at(o)??null}};var Hi=(()=>{class i extends W{callSetDisabledState;get submitted(){return ce(this._submittedReactive)}set submitted(e){this._submittedReactive.set(e)}_submitted=S(()=>this._submittedReactive());_submittedReactive=v(!1);_oldForm;_onCollectionChange=()=>this._updateDomValue();directives=[];constructor(e,t,n){super(),this.callSetDisabledState=n,this._setValidators(e),this._setAsyncValidators(t)}ngOnChanges(e){this.onChanges(e)}ngOnDestroy(){this.onDestroy()}onChanges(e){this._checkFormPresent(),e.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}onDestroy(){this.form&&(gt(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get path(){return[]}addControl(e){let t=this.form.get(e.path);return Ke(t,e,this.callSetDisabledState),t.updateValueAndValidity({emitEvent:!1}),this.directives.push(e),t}getControl(e){return this.form.get(e.path)}removeControl(e){pt(e.control||null,e,!1),Cn(this.directives,e)}addFormGroup(e){this._setUpFormContainer(e)}removeFormGroup(e){this._cleanUpFormContainer(e)}getFormGroup(e){return this.form.get(e.path)}getFormArray(e){return this.form.get(e.path)}addFormArray(e){this._setUpFormContainer(e)}removeFormArray(e){this._cleanUpFormContainer(e)}updateModel(e,t){this.form.get(e.path).setValue(t)}onReset(){this.resetForm()}resetForm(e=void 0,t={}){this.form.reset(e,t),this._submittedReactive.set(!1)}onSubmit(e){return this.submitted=!0,Bi(this.form,this.directives),this.ngSubmit.emit(e),this.form._events.next(new ht(this.control)),e?.target?.method==="dialog"}_updateDomValue(){this.directives.forEach(e=>{let t=e.control,n=this.form.get(e.path);t!==n&&(pt(t||null,e),Sn(n)&&(Ke(n,e,this.callSetDisabledState),e.control=n))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(e){let t=this.form.get(e.path);Li(t,e),t.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(e){if(this.form){let t=this.form.get(e.path);t&&vn(t,e)&&t.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){Wt(this.form,this),this._oldForm&>(this._oldForm,this)}_checkFormPresent(){this.form}static \u0275fac=function(t){return new(t||i)(D(be,10),D(Me,10),D(Ee,8))};static \u0275dir=R({type:i,features:[U,Be]})}return i})();var Yt=new le(""),An={provide:re,useExisting:X(()=>In)},In=(()=>{class i extends re{_ngModelWarningConfig;callSetDisabledState;viewModel;form;set isDisabled(e){}model;update=new pe;static _ngModelWarningSentOnce=!1;_ngModelWarningSent=!1;constructor(e,t,n,s,r){super(),this._ngModelWarningConfig=s,this.callSetDisabledState=r,this._setValidators(e),this._setAsyncValidators(t),this.valueAccessor=qt(this,n)}ngOnChanges(e){if(this._isControlChanged(e)){let t=e.form.previousValue;t&&pt(t,this,!1),Ke(this.form,this,this.callSetDisabledState),this.form.updateValueAndValidity({emitEvent:!1})}Gt(e,this.viewModel)&&(this.form.setValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.form&&pt(this.form,this,!1)}get path(){return[]}get control(){return this.form}viewToModelUpdate(e){this.viewModel=e,this.update.emit(e)}_isControlChanged(e){return e.hasOwnProperty("form")}static \u0275fac=function(t){return new(t||i)(D(be,10),D(Me,10),D(ve,10),D(Yt,8),D(Ee,8))};static \u0275dir=R({type:i,selectors:[["","formControl",""]],inputs:{form:[0,"formControl","form"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},exportAs:["ngForm"],standalone:!1,features:[$([An]),U,Be]})}return i})(),Fn={provide:W,useExisting:X(()=>ji)},ji=(()=>{class i extends bn{name=null;constructor(e,t,n){super(),this._parent=e,this._setValidators(t),this._setAsyncValidators(n)}_checkParentType(){zi(this._parent)}static \u0275fac=function(t){return new(t||i)(D(W,13),D(be,10),D(Me,10))};static \u0275dir=R({type:i,selectors:[["","formGroupName",""]],inputs:{name:[0,"formGroupName","name"]},standalone:!1,features:[$([Fn]),U]})}return i})(),Pn={provide:W,useExisting:X(()=>Ui)},Ui=(()=>{class i extends W{_parent;name=null;constructor(e,t,n){super(),this._parent=e,this._setValidators(t),this._setAsyncValidators(n)}ngOnInit(){zi(this._parent),this.formDirective.addFormArray(this)}ngOnDestroy(){this.formDirective?.removeFormArray(this)}get control(){return this.formDirective.getFormArray(this)}get formDirective(){return this._parent?this._parent.formDirective:null}get path(){return vt(this.name==null?this.name:this.name.toString(),this._parent)}static \u0275fac=function(t){return new(t||i)(D(W,13),D(be,10),D(Me,10))};static \u0275dir=R({type:i,selectors:[["","formArrayName",""]],inputs:{name:[0,"formArrayName","name"]},standalone:!1,features:[$([Pn]),U]})}return i})();function zi(i){return!(i instanceof ji)&&!(i instanceof Hi)&&!(i instanceof Ui)}var kn={provide:re,useExisting:X(()=>Rn)},Rn=(()=>{class i extends re{_ngModelWarningConfig;_added=!1;viewModel;control;name=null;set isDisabled(e){}model;update=new pe;static _ngModelWarningSentOnce=!1;_ngModelWarningSent=!1;constructor(e,t,n,s,r){super(),this._ngModelWarningConfig=r,this._parent=e,this._setValidators(t),this._setAsyncValidators(n),this.valueAccessor=qt(this,s)}ngOnChanges(e){this._added||this._setUpControl(),Gt(e,this.viewModel)&&(this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}viewToModelUpdate(e){this.viewModel=e,this.update.emit(e)}get path(){return vt(this.name==null?this.name:this.name.toString(),this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}_setUpControl(){this.control=this.formDirective.addControl(this),this._added=!0}static \u0275fac=function(t){return new(t||i)(D(W,13),D(be,10),D(Me,10),D(ve,10),D(Yt,8))};static \u0275dir=R({type:i,selectors:[["","formControlName",""]],inputs:{name:[0,"formControlName","name"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},standalone:!1,features:[$([kn]),U,Be]})}return i})();var Ln={provide:W,useExisting:X(()=>Bn)},Bn=(()=>{class i extends Hi{form=null;ngSubmit=new pe;get control(){return this.form}static \u0275fac=(()=>{let e;return function(n){return(e||(e=Ce(i)))(n||i)}})();static \u0275dir=R({type:i,selectors:[["","formGroup",""]],hostBindings:function(t,n){t&1&&E("submit",function(r){return n.onSubmit(r)})("reset",function(){return n.onReset()})},inputs:{form:[0,"formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],standalone:!1,features:[$([Ln]),U]})}return i})();var $i=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=He({type:i});static \u0275inj=Le({})}return i})();function Si(i){return!!i&&(i.asyncValidators!==void 0||i.validators!==void 0||i.updateOn!==void 0)}var Er=(()=>{class i{useNonNullable=!1;get nonNullable(){let e=new i;return e.useNonNullable=!0,e}group(e,t=null){let n=this._reduceControls(e),s={};return Si(t)?s=t:t!==null&&(s.validators=t.validator,s.asyncValidators=t.asyncValidator),new Pe(n,s)}record(e,t=null){let n=this._reduceControls(e);return new Rt(n,t)}control(e,t,n){let s={};return this.useNonNullable?(Si(t)?s=t:(s.validators=t,s.asyncValidators=n),new Qe(e,j(P({},s),{nonNullable:!0}))):new Qe(e,t,n)}array(e,t,n){let s=e.map(r=>this._createControl(r));return new Lt(s,t,n)}_reduceControls(e){let t={};return Object.keys(e).forEach(n=>{t[n]=this._createControl(e[n])}),t}_createControl(e){if(e instanceof Qe)return e;if(e instanceof Fe)return e;if(Array.isArray(e)){let t=e[0],n=e.length>1?e[1]:null,s=e.length>2?e[2]:null;return this.control(t,n,s)}else return this.control(e)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=we({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var wr=(()=>{class i{static withConfig(e){return{ngModule:i,providers:[{provide:Ee,useValue:e.callSetDisabledState??et}]}}static \u0275fac=function(t){return new(t||i)};static \u0275mod=He({type:i});static \u0275inj=Le({imports:[$i]})}return i})(),xr=(()=>{class i{static withConfig(e){return{ngModule:i,providers:[{provide:Yt,useValue:e.warnOnNgModelWithFormControl??"always"},{provide:Ee,useValue:e.callSetDisabledState??et}]}}static \u0275fac=function(t){return new(t||i)};static \u0275mod=He({type:i});static \u0275inj=Le({imports:[$i]})}return i})();var Y=["*"],Hn=[[["","icon",""]],[["sh-icon"]],[["","title",""]],"*",[["button"]],[["","content",""]],[["p"]]],jn=["[icon]","sh-icon","[title]","*","button","[content]","p"];function Un(i,o){i&1&&(h(0,"sh-icon",3),C(1,"info"),g())}function zn(i,o){i&1&&(h(0,"sh-icon",3),C(1,"info"),g())}function $n(i,o){i&1&&(h(0,"sh-icon",3),C(1,"warning"),g())}function Wn(i,o){i&1&&(h(0,"sh-icon",3),C(1,"warning-octagon"),g())}function Gn(i,o){i&1&&(h(0,"sh-icon",3),C(1,"check-circle"),g())}function qn(i,o){i&1&&(h(0,"sh-icon",3),C(1,"question"),g())}function Yn(i,o){if(i&1){let e=z();h(0,"sh-icon",8),E("click",function(){w(e);let n=f();return x(n.removeAlert())}),C(1,"plus"),g()}}var Xn=["dialogRef"];function Qn(i,o){if(i&1){let e=z();A(0,"div",5),Se("click",function(){w(e);let n=f(2);return x(n.isOpen.set(!1))}),F()}}function Zn(i,o){if(i&1&&(A(0,"dialog",2,0)(2,"div",3),u(3),F(),b(4,Qn,1,0,"div",4),F()),i&2){let e=f(),t=L(0);Z(t.class),G("width",t.width??"")("max-width",t.maxWidth??"")("max-height",t.maxHeight??"")("height",t.height??""),p(4),M(e.defaultOptionMerge().closeOnOutsideClick?4:-1)}}var Kn=["shButton",""];var Jn=["daysRef"];function eo(i,o){if(i&1&&C(0),i&2){let e=f();K(" - ",e.getMonthName(e.getLastVisibleMonth())," ")}}function to(i,o){if(i&1&&(h(0,"div"),C(1),g()),i&2){let e=o.$implicit;p(),Ne(e)}}function io(i,o){if(i&1){let e=z();h(0,"div",2,1),E("click",function(){let n=w(e).$implicit,s=xt(1),r=f(2);return x(r.setDate(n,s))}),C(2),g()}if(i&2){let e=o.$implicit,t=f().$implicit,n=f();Z(n.isDateSelected(e)),N("out-of-scope",!n.isCurrentMonth(e,t)),p(2),K(" ",e.getDate()," ")}}function no(i,o){if(i&1&&(h(0,"article",7),oe(1,"div",9),g()),i&2){let e=f(2);p(),Ot(e.selectedDateStylePosition())}}function oo(i,o){if(i&1&&(h(0,"div",5)(1,"nav",6),Ve(2,to,2,1,"div",null,je),g(),h(4,"div",7,0),Ve(6,io,3,5,"div",8,je),b(8,no,2,2,"article",7),g()()),i&2){let e=o.$implicit,t=f();p(2),Te(t.weekdays()),p(4),Te(t.getMonthDates(e)),p(2),M(t.asRange()?-1:8)}}var so=["triggerRef"],ro=["popoverRef"],ao=["popoverContentRef"],lo=[[["","trigger",""]],[["button"]],[["","shButton",""]],"*"],co=["[trigger]","button","[shButton]","*"];function uo(i,o){if(i&1){let e=z();A(0,"div",6,1)(2,"div",7),Se("click",function(n){w(e);let s=f();return x(s.eventClose(n))}),F(),A(3,"div",8,2),u(5,3),F()()}if(i&2){let e=f();ge("id",e.id()+"hello"),p(3),Ot(e.menuStyle()),G("position-anchor",e.id())}}var ho=[[["label"]],[["","prefix",""]],[["","textPrefix",""]],[["input"]],[["","popoverContent",""]],[["textarea"]],[["","textSuffix",""]],[["","suffix",""]],[["","error",""]],[["","hint",""]]],po=["label","[prefix]","[textPrefix]","input","[popoverContent]","textarea","[textSuffix]","[suffix]","[error]","[hint]"],Wi=()=>({closeOnButton:!1,closeOnEsc:!0}),fo=[[["label"]],[["","prefix",""]],[["","textPrefix",""]],[["input"]],[["","textSuffix",""]],[["","suffix",""]]],go=["label","[prefix]","[textPrefix]","input","[textSuffix]","[suffix]"];function mo(i,o){if(i&1&&(h(0,"div",3),C(1),g()),i&2){let e=f();p(),K(" ",e._maskedDate()," ")}}function vo(i,o){if(i&1){let e=z();h(0,"sh-datepicker",7),E("dateChange",function(n){w(e);let s=f();return x(s.onDateChange(n))}),g()}if(i&2){let e=f();Z(e.currentClass()),Q("date",e.internalDate())}}function _o(i,o){}var Co=[[["label"]],[["","boxPrefix",""]],[["","prefix",""]],[["","textPrefix",""]],[["input"]],[["textarea"]],[["","textSuffix",""]],[["","suffix",""]],[["","boxSuffix",""]],[["","error",""]],[["","hint",""]]],yo=["label","[boxPrefix]","[prefix]","[textPrefix]","input","textarea","[textSuffix]","[suffix]","[boxSuffix]","[error]","[hint]"],Do=["input"],So=[[["label"]]],bo=["label"];function Mo(i,o){if(i&1&&(h(0,"div",3),C(1),g()),i&2){let e=f();p(),Ne(e.files()[0].name)}}function Eo(i,o){if(i&1&&(h(0,"div",3),C(1),g()),i&2){let e=f();p(),K("",e.files().length," files selected")}}function wo(i,o){if(i&1&&(h(0,"div",4),C(1),g()),i&2){let e=f();p(),Ne(e.filesOver()?e.overlayText():e.placeholder())}}var xo=["inputRef"],Oo=["optionsRef"],Vo=["*",[["","menu",""]]],To=["*","[menu]"];function No(i,o){i&1&&(h(0,"sh-icon",5),C(1,"caret-down"),g())}var Ao=[[["label"]],[["input","type","range"]]],Io=["label","input[type=range]"],Fo=["optionsWrap"],Po=[[["label"]],[["","prefix",""]],[["","boxPrefix",""]],[["input"]],[["textarea"]]],ko=["label","[prefix]","[boxPrefix]","input","textarea"],Ro=()=>({closeOnButton:!1,closeOnEsc:!1}),Gi=(i,o)=>({$implicit:i,last:o}),Xt=i=>({$implicit:i});function Lo(i,o){if(i&1&&C(0),i&2){let e=f();K(" ",e.inputValue()," ")}}function Bo(i,o){i&1&&De(0)}function Ho(i,o){if(i&1&&fe(0,Bo,1,0,"ng-container",13),i&2){let e=f(3),t=e.$implicit,n=e.$index,s=e.$count;f(2);let r=L(3);Q("ngTemplateOutlet",r)("ngTemplateOutletContext",Vt(2,Gi,t,n===s-1))}}function jo(i,o){if(i&1&&C(0),i&2){let e=f(3).$implicit,t=f(2);K(" ",t.getLabel(e)," ")}}function Uo(i,o){if(i&1){let e=z();h(0,"sh-chip",12),E("click",function(n){w(e);let s=f(2).$index,r=f(2);return x(r.removeSelectedOptionByIndex(n,s))}),b(1,Ho,1,5,"ng-container")(2,jo,1,1),h(3,"sh-icon"),C(4,"x-bold"),g()()}if(i&2){let e=f(4),t=L(3);Z(e.selectClasses()),p(),M(t?1:2)}}function zo(i,o){i&1&&De(0)}function $o(i,o){if(i&1&&fe(0,zo,1,0,"ng-container",13),i&2){let e=f(4),t=e.$implicit,n=e.$index,s=e.$count;f(2);let r=L(3);Q("ngTemplateOutlet",r)("ngTemplateOutletContext",Vt(2,Gi,t,n===s-1))}}function Wo(i,o){if(i&1&&C(0),i&2){let e=f(4),t=e.$implicit,n=e.$index,s=e.$count,r=f(2);K(" ",n===s-1?r.getLabel(t):r.getLabel(t)+","," ")}}function Go(i,o){if(i&1&&b(0,$o,1,5,"ng-container")(1,Wo,1,1),i&2){f(5);let e=L(3);M(e?0:1)}}function qo(i,o){if(i&1&&b(0,Go,2,1),i&2){f(4);let e=L(6);M(e?-1:0)}}function Yo(i,o){if(i&1&&b(0,Uo,5,3,"sh-chip",11)(1,qo,1,1),i&2){f(3);let e=L(5);M(e?0:1)}}function Xo(i,o){if(i&1&&b(0,Yo,2,1),i&2){let e=o.$implicit;M(e?0:-1)}}function Qo(i,o){if(i&1&&Ve(0,Xo,1,1,null,null,je),i&2){f();let e=L(2);Te(e)}}function Zo(i,o){i&1&&De(0)}function Ko(i,o){if(i&1&&fe(0,Zo,1,0,"ng-container",14),i&2){f(2);let e=L(0);Q("ngTemplateOutlet",e)}}function Jo(i,o){if(i&1&&C(0),i&2){let e=f(2);K(" ",e.placeholderText()??""," ")}}function es(i,o){if(i&1&&b(0,Ko,1,1,"ng-container")(1,Jo,1,1),i&2){f();let e=L(0);M(e?0:1)}}function ts(i,o){i&1&&(h(0,"sh-icon",6),C(1,"caret-down"),g())}function is(i,o){i&1&&oe(0,"sh-spinner",7)}function ns(i,o){i&1&&(h(0,"sh-icon",6),C(1,"list-magnifying-glass"),g())}function os(i,o){i&1&&(h(0,"sh-icon",6),C(1,"magnifying-glass"),g())}function ss(i,o){if(i&1){let e=z();h(0,"sh-icon",15),E("click",function(n){w(e);let s=f();return x(s.clear(n))}),C(1,"x-bold"),g()}}function rs(i,o){i&1&&(h(0,"sh-icon",6),C(1,"caret-down"),g())}function as(i,o){i&1&&(h(0,"sh-icon",6),C(1,"caret-up"),g())}function ls(i,o){if(i&1&&(h(0,"p",9),C(1),g()),i&2){let e=f(3);p(),Ne(e.freeTextTitle())}}function cs(i,o){i&1&&De(0)}function ds(i,o){if(i&1&&fe(0,cs,1,0,"ng-container",13),i&2){f(2);let e=L(0);f();let t=L(1);Q("ngTemplateOutlet",t)("ngTemplateOutletContext",rt(2,Xt,e))}}function us(i,o){i&1&&De(0)}function hs(i,o){if(i&1&&fe(0,us,1,0,"ng-container",13),i&2){f(2);let e=L(0);f();let t=L(4);Q("ngTemplateOutlet",t)("ngTemplateOutletContext",rt(2,Xt,e))}}function ps(i,o){if(i&1&&C(0),i&2){f(2);let e=L(1);K(" ",e," ")}}function fs(i,o){i&1&&oe(0,"sh-divider")}function gs(i,o){if(i&1){let e=z();b(0,ls,2,1,"p",9),h(1,"li",16),E("click",function(){w(e);let n=f(2);return x(n.toggleOptionByIndex(-1))}),b(2,ds,1,4,"ng-container")(3,hs,1,4,"ng-container")(4,ps,1,1),g(),b(5,fs,1,0,"sh-divider")}if(i&2){f();let e=L(0),t=f(),n=L(1),s=L(4);M(t.freeTextTitle()?0:-1),p(),N("selected",t.isSelected(-1))("focused",t.focusedOptionIndex()===-1),Q("id",t.getLabelAsSlug(e)),ge("aria-selected",t.isSelected(-1)),p(),M(n?2:s?3:4),p(3),M(t.freeTextTitle()&&t.filteredOptions().length>0?5:-1)}}function ms(i,o){if(i&1&&(ot(0)(1),b(2,gs,6,9)),i&2){let e=f(),t=ne(e.computedFreeTextOption());p();let n=ne(e.getValue(t));p(),M(n.length>0?2:-1)}}function vs(i,o){if(i&1&&(h(0,"p",9),C(1),g()),i&2){let e=f();p(),Ne(e.optionTitle())}}function _s(i,o){if(i&1&&oe(0,"sh-checkbox"),i&2){let e=f().$index,t=f();Z(t.selectClasses()),N("active",t.isSelected(e))}}function Cs(i,o){i&1&&De(0)}function ys(i,o){if(i&1&&fe(0,Cs,1,0,"ng-container",13),i&2){let e=f().$implicit;f();let t=L(4);Q("ngTemplateOutlet",t)("ngTemplateOutletContext",rt(2,Xt,e))}}function Ds(i,o){if(i&1&&C(0),i&2){let e=f().$implicit,t=f();K(" ",t.getLabel(e)," ")}}function Ss(i,o){if(i&1){let e=z();h(0,"li",16),E("click",function(){let n=w(e).$index,s=f();return x(s.toggleOptionByIndex(n))}),b(1,_s,1,4,"sh-checkbox",17),b(2,ys,1,4,"ng-container")(3,Ds,1,1),g()}if(i&2){let e=o.$implicit,t=o.$index,n=f(),s=L(4);N("selected",n.isSelected(t))("focused",t===n.focusedOptionIndex()),Q("id",n.getLabelAsSlug(e)),ge("aria-selected",n.isSelected(t)),p(),M(n.selectMultiple()?1:-1),p(),M(s?2:3)}}var bs=["dragImageElement"],Ms=[[["","sidenav",""]],[["","sidenav-closed-topbar",""]],"*"],Es=["[sidenav]","[sidenav-closed-topbar]","*"];function ws(i,o){i&1&&ye(0,"div",1,0)}function xs(i,o){if(i&1){let e=z();A(0,"div",7),Se("drop",function(n){w(e);let s=f();return x(s.drop(n))})("dragenter",function(){w(e);let n=f();return x(n.dragEnter())})("dragleave",function(){w(e);let n=f();return x(n.dragLeave())}),F()}}function Os(i,o){if(i&1){let e=z();A(0,"div",8),Se("dragstart",function(n){w(e);let s=f();return x(s.dragStart(n))})("dragend",function(n){w(e);let s=f();return x(s.dragEnd(n))})("drag",function(n){w(e);let s=f();return x(s.drag(n))})("touchstart",function(n){w(e);let s=f();return x(s.touchStart(n))})("touchmove",function(n){w(e);let s=f();return x(s.touchMove(n))})("touchend",function(n){w(e);let s=f();return x(s.touchEnd(n))})("touchcancel",function(n){w(e);let s=f();return x(s.touchCancel(n))}),F()}}var Vs=["thead"],Ts=["tbody"],Ns=[[["","actionbar",""]],[["th"]],[["","thead",""]],"*",[["","table-no-rows",""]]],As=["[actionbar]","th","[thead]","*","[table-no-rows]"];function Is(i,o){i&1&&oe(0,"sh-progress-bar",3)}function Fs(i,o){i&1&&(h(0,"div",4),u(1,4),g())}var Ps=[[["","title",""]],"*"],ks=["[title]","*"];function Rs(i,o){i&1&&C(0,"Title")}function Ls(i,o){i&1&&(h(0,"sh-icon",1),C(1,"caret-down"),g())}var Bs=["bold","thin","light","fill","duotone"],_e=(()=>{class i{#e=y(I);#i=y(de);ngAfterContentInit(){let e=this.#e.nativeElement.textContent?.trim();if(!e)return;let t=e.split("-").at(-1);t&&Bs.includes(t)&&this.#i.addClass(this.#e.nativeElement,t)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-icon"]],ngContentSelectors:Y,decls:1,vars:0,template:function(t,n){t&1&&(T(),u(0))},encapsulation:2,changeDetection:0})}}return i})();function Re(i=null){let o=i??y(I).nativeElement;if(!o)return v("");let e=v(o.className);if(typeof MutationObserver>"u")return e.asReadonly();let t=y(he),n=new MutationObserver(s=>{for(let r of s)if(r.type==="attributes"&&r.attributeName==="class"){let a=r.target;e.set(a.className)}});return n.observe(o,{attributes:!0,attributeFilter:["class"]}),t.onDestroy(()=>n.disconnect()),e.asReadonly()}var yt=new le("Ship UI Config"),Hs=["simple","outlined","flat","raised"],Kr=(()=>{class i{constructor(){this.#e=y(yt,{optional:!0}),this.variant=v(this.#e?.alertVariant??""),this._el=y(I),this.alertService=m(null),this.id=m(null),this.currentClasses=Re(),this.activeClass=S(()=>{let e=this.variant(),t=`${this.currentClasses()} sh-sheet`;return e?Hs.find(s=>this.currentClasses().includes(s))?t:`${t} ${e}`:t})}#e;removeAlert(){this.id()&&this.alertService()&&this.alertService()?.removeAlert(this.id())}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-alert"]],hostVars:2,hostBindings:function(t,n){t&2&&Z(n.activeClass())},inputs:{alertService:[1,"alertService"],id:[1,"id"]},ngContentSelectors:jn,decls:21,vars:4,consts:[["ref",""],[1,"alert"],[1,"icon"],[1,"state-icon"],[1,"title"],[1,"close-icon"],[1,"actions"],[1,"content"],[1,"close-icon",3,"click"]],template:function(t,n){if(t&1&&(T(Hn),h(0,"div",1)(1,"div",2,0),u(3),u(4,1),g(),h(5,"div",2),b(6,Un,2,0,"sh-icon",3)(7,zn,2,0,"sh-icon",3)(8,$n,2,0,"sh-icon",3)(9,Wn,2,0,"sh-icon",3)(10,Gn,2,0,"sh-icon",3)(11,qn,2,0,"sh-icon",3),g(),h(12,"div",4),u(13,2),u(14,3),g(),b(15,Yn,2,0,"sh-icon",5),h(16,"div",6),u(17,4),g(),h(18,"div",7),u(19,5),u(20,6),g()()),t&2){let s=xt(2);p(),G("display",s.children.length?"block":"none");let r=n.currentClasses();p(5),M(r.includes("primary")?6:r.includes("accent")?7:r.includes("warn")?8:r.includes("error")?9:r.includes("success")?10:11),p(9),M(n.id()?15:-1)}},dependencies:[_e],encapsulation:2,changeDetection:0})}}return i})();function Dt(){return Date.now().toString(36)+Math.random().toString(36).substring(2)}var Jr=(()=>{class i{constructor(){this.alertHistory=v([]),this.alertHistoryIsOpen=v(!1),this.alertHistoryIsHidden=v(!0)}error(e){this.addAlert({type:"error",title:e??"An error occured"})}success(e){this.addAlert({type:"success",title:e})}question(e){this.addAlert({type:"question",title:e})}warning(e){this.addAlert({type:"warn",title:e})}info(e){this.addAlert({type:"primary",title:e})}addAlert(e){let t=Dt();this.alertHistory.update(n=>[j(P({},e),{isOpen:!0,animateIn:!0,animateOut:!1,id:t}),...n]),setTimeout(()=>{this.alertHistory.update(n=>n.map(s=>j(P({},s),{animateIn:s.id===t?!1:s.animateIn})))},40),setTimeout(()=>{this.hideAlert(t)},2500)}removeAlert(e){this.alertHistory.update(t=>t.map(n=>j(P({},n),{animateOut:n.id===e?!1:n.animateOut}))),setTimeout(()=>{this.alertHistory.update(t=>t.filter(n=>n.id!==e))},300)}hideAlert(e){this.alertHistory.update(t=>t.map(n=>j(P({},n),{isOpen:n.id===e?!1:n.isOpen})))}setHidden(e){this.alertHistoryIsHidden.set(e)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=we({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})(),js={class:"default",width:void 0,maxWidth:void 0,height:void 0,maxHeight:void 0,closeOnButton:!0,closeOnEsc:!0,closeOnOutsideClick:!0},Us=(()=>{class i{constructor(){this.#e=y(Oe),this.#i=y(yt,{optional:!0}),this.dialogRef=J("dialogRef"),this.isOpen=H(!1),this.options=m(),this.closed=se(),this.defaultOptionMerge=S(()=>P(j(P({},js),{class:this.#i?.dialogType??"default"}),this.options())),this.abortController=null,this.isOpenEffect=k(()=>{let e=this.dialogRef()?.nativeElement;e&&(this.abortController&&this.abortController.abort(),this.abortController=new AbortController,this.isOpen()?(e.showModal(),e.addEventListener("close",()=>{this.isOpen.set(!1),this.closed.emit()},{signal:this.abortController?.signal}),this.#e.addEventListener("keydown",t=>{t.key==="Escape"&&!this.defaultOptionMerge().closeOnEsc&&t.preventDefault(),t.key==="Escape"&&this.defaultOptionMerge().closeOnEsc&&this.isOpen.set(!1)},{signal:this.abortController?.signal})):(e.close(),queueMicrotask(()=>this.closed.emit())))})}#e;#i;ngOnDestroy(){this.abortController?.abort()}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-dialog"]],viewQuery:function(t,n){t&1&&ue(n.dialogRef,Xn,5),t&2&&ie()},inputs:{isOpen:[1,"isOpen"],options:[1,"options"]},outputs:{isOpen:"isOpenChange",closed:"closed"},ngContentSelectors:Y,decls:2,vars:2,consts:[["dialogRef",""],["shDialog","",3,"class","width","max-width","max-height","height"],["shDialog",""],[1,"content"],[1,"closeable-overlay"],[1,"closeable-overlay",3,"click"]],template:function(t,n){t&1&&(T(),ot(0),b(1,Zn,5,11,"dialog",1)),t&2&&(ne(n.defaultOptionMerge()),p(),M(n.isOpen()?1:-1))},encapsulation:2,changeDetection:0})}}return i})(),ea=(()=>{class i{constructor(){this.#e=y(Oe),this.#i=this.#e.querySelector("body"),this.#t=y(Et),this.compRef=null,this.insertedCompRef=null,this.closedFieldSub=null,this.compClosedSub=null}#e;#i;#t;open(e,t){let n=this.#t.injector,s=this.#n(),r=!1,ee=t||{},{data:a,closed:l}=ee,c=Kt(ee,["data","closed"]);this.compRef&&this.#o(!0),this.insertedCompRef=It(e,{environmentInjector:n}),this.compRef=It(Us,{hostElement:s,environmentInjector:n,projectableNodes:[[this.insertedCompRef.location.nativeElement]]});let d=this.insertedCompRef.instance,_=d.data,V=d.closed;if(a){if(Mt(_))this.insertedCompRef.setInput("data",a);else if(!Mt(_))throw new Error("data is not an input signal on the passed component")}V instanceof Tt&&(this.closedFieldSub=V.subscribe(ae=>{this.#o(),!r&&(r=!0,l?.(ae),(this.compRef?.instance.closed).emit(ae))})),this.#t.attachView(this.insertedCompRef.hostView),this.#t.attachView(this.compRef.hostView),this.insertedCompRef.changeDetectorRef.detectChanges(),this.compRef.changeDetectorRef.detectChanges(),this.compRef.instance.isOpen.set(!0),this.compRef.setInput("options",c),this.compClosedSub=this.compRef.instance.closed.subscribe(()=>te());let B=this;function te(ae=void 0){B.#o(),!r&&(r=!0,V&&V instanceof Tt&&V.emit(ae),l?.(ae))}return{component:this.insertedCompRef.instance,close:te,closed:this.compRef.instance.closed}}#n(){let e=this.#e.createElement("sh-dialog-ref");return e.id="sh-dialog-ref",this.#e.getElementById("sh-dialog-ref")||this.#i?.append(e),this.#e.getElementById("sh-dialog-ref")}#o(e=!1){let t=this;e||queueMicrotask(()=>n());function n(){t.insertedCompRef&&(t.#t.detachView(t.insertedCompRef.hostView),t.closedFieldSub?.unsubscribe(),t.insertedCompRef.destroy()),t.compRef&&(t.#t.detachView(t.compRef.hostView),t.compClosedSub?.unsubscribe(),t.compRef.destroy())}}ngOnDestroy(){this.#o(!0)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275prov=we({token:i,factory:i.\u0275fac,providedIn:"root"})}}return i})();var ta=(()=>{class i{constructor(){this.id="--"+Math.random().toString(36).substring(2,15)+Math.random().toString(36).substring(2,12)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-button-group"]],hostVars:2,hostBindings:function(t,n){t&2&&G("--btng-id",n.id)},ngContentSelectors:Y,decls:1,vars:0,template:function(t,n){t&1&&(T(),u(0))},encapsulation:2,changeDetection:0})}}return i})(),ia=(()=>{class i{static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["","shButton",""]],hostAttrs:[1,"sh-sheet-h"],attrs:Kn,ngContentSelectors:Y,decls:1,vars:0,template:function(t,n){t&1&&(T(),u(0))},encapsulation:2,changeDetection:0})}}return i})(),na=(()=>{class i{constructor(){this.#e=y(yt,{optional:!0}),this.class=v(this.#e?.cardType??"type-a")}#e;static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-card"]],hostVars:2,hostBindings:function(t,n){t&2&&Z(n.class())},ngContentSelectors:Y,decls:1,vars:0,template:function(t,n){t&1&&(T(),u(0))},encapsulation:2,changeDetection:0})}}return i})(),zs=(()=>{class i{constructor(){this.currentClassList=Re()}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-checkbox"]],ngContentSelectors:Y,decls:7,vars:2,consts:[[1,"box","sh-sheet"],[1,"inherit","default-indicator"],[1,"inherit","indeterminate-indicator"],[1,"label"]],template:function(t,n){t&1&&(T(),h(0,"div",0)(1,"sh-icon",1),C(2,"check-bold"),g(),h(3,"sh-icon",2),C(4,"minus-bold"),g()(),h(5,"div",3),u(6),g()),t&2&&Z(n.currentClassList())},dependencies:[_e],encapsulation:2,changeDetection:0})}}return i})(),$s=(()=>{class i{static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-chip"]],hostAttrs:[1,"sh-sheet"],ngContentSelectors:Y,decls:2,vars:0,template:function(t,n){t&1&&(T(),A(0,"div"),u(1),F())},encapsulation:2,changeDetection:0})}}return i})();var Ws=(()=>{class i{constructor(){this.#e=this.#r(new Date),this.date=H(null),this.endDate=H(null),this.asRange=m(!1),this.monthsToShow=m(1),this.disabled=m(!1),this.startOfWeek=m(1),this.weekdayLabels=m(["Su","Mo","Tu","We","Th","Fr","Sa"]),this.daysRef=J("daysRef"),this.currentDate=v(this.date()??this.#e),this.monthOffsets=S(()=>Array.from({length:this.monthsToShow()},(e,t)=>t)),this.selectedDateStylePosition=v(null),this.weekdays=S(()=>{let e=this.startOfWeek(),t=this.weekdayLabels();return t.slice(e).concat(t.slice(0,e))}),this.currentClasses=Re(),this.someEffect=k(()=>{let e=this.currentClasses();this.#n()}),this.#i=k(()=>{this.monthsToShow()>1||this.#t()})}#e;getLastVisibleMonth(){let e=this.monthsToShow()-1;return this.getOffsetDate(e)}getOffsetDate(e){let t=new Date(this.currentDate());return t.setMonth(t.getMonth()+e),t}getMonthDates(e){let t=this.getOffsetDate(e);return this.#o(t,this.startOfWeek())}#i;ngOnInit(){this.monthsToShow()!==1&&this.#t()}#t(){let e=this.date();e&&this.currentDate.set(e),this.#n()}#n(){setTimeout(()=>{let e=this.daysRef()?.nativeElement.querySelector(".sel");if(!e)return this.selectedDateStylePosition.update(t=>t?j(P({},t),{opacity:"0"}):null);this.setSelectedDateStylePosition(e)})}#o(e,t){let n=e.getUTCFullYear(),s=e.getUTCMonth(),r=new Date(Date.UTC(n,s)).getUTCDay(),a=32-new Date(Date.UTC(n,s,32)).getUTCDate(),l=[],c=r-t;c<0&&(c+=7);let d=new Date(Date.UTC(n,s,0)).getUTCDate();for(let V=c-1;V>=0;V--){let B=new Date(Date.UTC(n,s-1,d-V));l.push(B)}for(let V=1;V<=a;V++)l.push(new Date(Date.UTC(n,s,V)));let _=1;for(;l.length%7!==0;)l.push(new Date(Date.UTC(n,s+1,_++)));return l}nextMonth(){this.currentDate.update(e=>{let t=new Date(e);return t.setMonth(e.getMonth()+1),t}),this.#n()}previousMonth(){this.currentDate.update(e=>{let t=new Date(e);return t.setMonth(e.getMonth()-1),t}),this.#n()}setDate(e,t){let n=(s,r)=>{let a=r?.getUTCHours()??0,l=r?.getUTCMinutes()??0,c=r?.getUTCSeconds()??0,d=r?.getUTCMilliseconds()??0;return this.#r(new Date(Date.UTC(s.getUTCFullYear(),s.getUTCMonth(),s.getUTCDate(),a,l,c,d)))};if(!this.asRange())this.date.set(n(e,this.date())),this.endDate.set(null);else{let s=this.date(),r=this.endDate(),a=n(e,null);s?r?(this.date.set(a),this.endDate.set(null)):a<s?(this.date.set(a),this.endDate.set(null)):this.endDate.set(a):this.date.set(a)}this.asRange()||this.setSelectedDateStylePosition(t)}isDateSelected(e){let t=this.date(),n=this.endDate();if(t===null)return null;let s=_=>new Date(Date.UTC(_.getUTCFullYear(),_.getUTCMonth(),_.getUTCDate(),0,0,0,0)),r=_=>new Date(Date.UTC(_.getUTCFullYear(),_.getUTCMonth(),_.getUTCDate(),23,59,59,999)),a=s(e),l=s(t),c=n?r(n):null,d=[];if(this.asRange())if(c===null)a.getTime()===l.getTime()&&d.push("sel first last");else{if(a.getTime()===l.getTime()&&d.push("first"),a.getTime()===s(c).getTime()&&d.push("last"),a>=l&&a<=c){d.push("sel");let ee=a.getUTCDay(),ae=this.startOfWeek();ee===ae&&d.push("week-start");let St=(ae+6)%7;ee===St&&d.push("week-end")}let _=new Date(a);_.setUTCDate(a.getUTCDate()+1),new Date(a).setUTCDate(a.getUTCDate()-1);let B=a.getUTCDate()===1,te=_.getUTCMonth()!==a.getUTCMonth();B&&d.push("month-start"),te&&d.push("month-end")}else a.getTime()===l.getTime()&&d.push("sel");return d.join(" ")||null}setSelectedDateStylePosition(e){this.selectedDateStylePosition.set({transform:`translate(${e.offsetLeft}px, ${e.offsetTop}px)`,opacity:"1"})}getMonthName(e){return e.toLocaleString("default",{month:"long"})}getFullYear(e){return e.getFullYear()}isCurrentMonth(e,t){let n=this.getOffsetDate(t);return e.getMonth()===n.getMonth()}#r(e){let n=e.getTimezoneOffset()*60*1e3;return new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())+n)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-datepicker"]],viewQuery:function(t,n){t&1&&ue(n.daysRef,Jn,5),t&2&&ie()},hostVars:6,hostBindings:function(t,n){t&2&&(Z("columns-"+n.monthsToShow()),N("as-range",n.asRange())("disabled",n.disabled()))},inputs:{date:[1,"date"],endDate:[1,"endDate"],asRange:[1,"asRange"],monthsToShow:[1,"monthsToShow"],disabled:[1,"disabled"],startOfWeek:[1,"startOfWeek"],weekdayLabels:[1,"weekdayLabels"]},outputs:{date:"dateChange",endDate:"endDateChange"},decls:14,vars:3,consts:[["daysRef",""],["elementRef",""],[3,"click"],[1,"title"],[1,"months-container"],[1,"month"],[1,"weekdays"],[1,"days"],[3,"out-of-scope","class"],[1,"sel-el"]],template:function(t,n){t&1&&(h(0,"header")(1,"button",2),E("click",function(){return n.previousMonth()}),h(2,"sh-icon"),C(3,"caret-left"),g()(),h(4,"div",3),C(5),b(6,eo,1,1),C(7),g(),h(8,"button",2),E("click",function(){return n.nextMonth()}),h(9,"sh-icon"),C(10,"caret-right"),g()()(),h(11,"section",4),Ve(12,oo,9,1,"div",5,di),g()),t&2&&(p(5),K(" ",n.getMonthName(n.currentDate())," "),p(),M(n.monthsToShow()>1?6:-1),p(),K(" ",n.getFullYear(n.currentDate())," "),p(5),Te(n.monthOffsets()))},dependencies:[_e],encapsulation:2,changeDetection:0})}}return i})(),Ct=4,Gs=["scroll","auto"],qs={width:void 0,height:void 0,closeOnButton:!0,closeOnEsc:!0},Qt=(()=>{class i{constructor(){this.#e=y(Oe),this.SUPPORTS_ANCHOR=typeof CSS<"u"&&CSS.supports("position-anchor","--abc")&&CSS.supports("anchor-name","--abc"),this.asMultiLayer=m(!1),this.disableOpenByClick=m(!1),this.isOpen=H(!1),this.options=m(),this.closed=se(),this.defaultOptionMerge=S(()=>P(P({},qs),this.options())),this.triggerRef=J.required("triggerRef"),this.popoverRef=J("popoverRef"),this.popoverContentRef=J("popoverContentRef"),this.id=v("--"+Dt()),this.menuStyle=v(null),this.openAbort=null,this.openEffect=k(()=>{let e=this.isOpen();queueMicrotask(()=>{let t=this.popoverRef()?.nativeElement;if(!t){this.openAbort?.abort(),this.openAbort=null;return}e?(this.openAbort&&this.openAbort.abort(),this.openAbort=new AbortController,this.#e.addEventListener("keydown",n=>{n.key==="Escape"&&!this.defaultOptionMerge().closeOnEsc&&n.preventDefault(),n.key==="Escape"&&this.defaultOptionMerge().closeOnEsc&&this.isOpen.set(!1)},{signal:this.openAbort?.signal}),t.showPopover(),this.SUPPORTS_ANCHOR||setTimeout(()=>{this.#i(t).addEventListener("scroll",()=>this.#a(),{signal:this.openAbort?.signal}),window?.addEventListener("resize",()=>this.#a(),{signal:this.openAbort?.signal}),this.#a()})):(this.closed.emit(),this.openAbort?.abort(),this.openAbort=null)})})}#e;toggleIsOpen(e){this.disableOpenByClick()||(e.preventDefault(),e.stopPropagation(),this.isOpen.set(!this.isOpen()))}eventClose(e){this.isOpen()&&this.isOpen.set(!1)}#i(e){let t=e.parentElement;for(;t;){if(Gs.indexOf(window?.getComputedStyle(t).overflowY)>-1&&t.scrollHeight>t.clientHeight)return t;t=t.parentElement}return this.#e.documentElement}#t(e,t){let n=e.left,s=e.bottom+Ct;return{left:n,top:s}}#n(e,t){let n=e.right+Ct,s=e.top;return{left:n,top:s}}#o(e,t){let n=e.right+Ct,s=e.bottom;return{left:n,top:s}}#r(e,t){let n=e.left,s=e.bottom-e.height-t.height-Ct;return{left:n,top:s}}#a(){let e=this.triggerRef()?.nativeElement.getBoundingClientRect(),t=this.popoverContentRef()?.nativeElement.getBoundingClientRect(),n=[this.#n,this.#o],s=[this.#t,this.#r],r=this.asMultiLayer()?n:s;for(let l=0;l<r.length;l++){let c=r[l](e,t),d=c.left+(t?.width||0)>window.innerWidth,_=c.top+(t?.height||0)>window.innerHeight;if(!d&&!_){this.menuStyle.set({left:c.left+"px",top:c.top+"px"});return}}let a=r[0](e,t);this.menuStyle.set({left:a.left+"px",top:a.top+"px"})}ngOnDestroy(){this.openAbort?.abort(),this.openAbort=null}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-popover"]],viewQuery:function(t,n){t&1&&ue(n.triggerRef,so,5)(n.popoverRef,ro,5)(n.popoverContentRef,ao,5),t&2&&ie(3)},hostVars:2,hostBindings:function(t,n){t&2&&N("multi-layer",n.asMultiLayer())},inputs:{asMultiLayer:[1,"asMultiLayer"],disableOpenByClick:[1,"disableOpenByClick"],isOpen:[1,"isOpen"],options:[1,"options"]},outputs:{isOpen:"isOpenChange",closed:"closed"},ngContentSelectors:co,decls:8,vars:4,consts:[["triggerRef",""],["popoverRef",""],["popoverContentRef",""],[1,"trigger",3,"click"],[1,"trigger-wrapper"],[1,"trigger-anchor"],["popover","manual",1,"popover"],[1,"overlay",3,"click"],[1,"popover-content"]],template:function(t,n){if(t&1){let s=z();T(lo),A(0,"div",3,0),Se("click",function(a){return w(s),x(n.toggleIsOpen(a))}),A(2,"div",4),u(3),u(4,1),u(5,2),F(),ye(6,"div",5),F(),b(7,uo,6,5,"div",6)}t&2&&(ge("popovertarget",n.id()+"hello"),p(6),G("anchor-name",n.id()),p(),M(n.isOpen()?7:-1))},encapsulation:2,changeDetection:0})}}return i})(),Ys=(()=>{class i{constructor(){this.#e=y(I),this.isOpen=H(!1),this.closed=se()}#e;onClick(){this.#e.nativeElement.querySelector("input")&&this.#e.nativeElement.querySelector("input").focus(),this.#e.nativeElement.querySelector("textarea")&&this.#e.nativeElement.querySelector("textarea").focus()}close(){this.closed.emit()}ngOnInit(){let e=typeof CSS<"u"&&CSS.supports("field-sizing","content"),t=this.#e.nativeElement.querySelector("textarea");if(!e&&t!==null){let a=function(){r.style.height="auto",r.style.height=r.scrollHeight+"px"},l=function(){setTimeout(a,0)};var n=a,s=l;let r=this.#e.nativeElement.querySelector("textarea");r&&(r.addEventListener("change",a),r.addEventListener("cut",l),r.addEventListener("paste",l),r.addEventListener("drop",l),r.addEventListener("keydown",l),r.focus(),r.select(),a())}}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-form-field-popover"]],hostBindings:function(t,n){t&1&&E("click",function(){return n.onClick()})},inputs:{isOpen:[1,"isOpen"]},outputs:{isOpen:"isOpenChange",closed:"closed"},ngContentSelectors:po,decls:18,vars:3,consts:[[1,"input-wrap"],[1,"prefix"],[1,"prefix-space"],[3,"isOpenChange","closed","isOpen","options"],[1,"suffix-space"],[1,"helpers"],[1,"error-wrap"],[1,"hint"]],template:function(t,n){t&1&&(T(ho),u(0),h(1,"div",0)(2,"div",1),u(3,1),u(4,2),g(),oe(5,"div",2),h(6,"sh-popover",3),$e("isOpenChange",function(r){return ze(n.isOpen,r)||(n.isOpen=r),r}),E("closed",function(){return n.close()}),u(7,3,["trigger",""]),u(8,4),g(),u(9,5),u(10,6),oe(11,"div",4),u(12,7),g(),h(13,"div",5)(14,"div",6),u(15,8),g(),h(16,"div",7),u(17,9),g()()),t&2&&(p(6),Ue("isOpen",n.isOpen),Q("options",st(2,Wi)))},dependencies:[Qt],encapsulation:2,changeDetection:0})}}return i})();function Xs(i){let o=y(I).nativeElement,e=y(he),t=v([]),n=()=>{t.set(Array.from(o.querySelectorAll(i)))};if(n(),typeof MutationObserver>"u")return t.asReadonly();let s=new MutationObserver(r=>{r.some(l=>l.type==="childList")&&n()});return s.observe(o,{childList:!0}),e.onDestroy(()=>s.disconnect()),t.asReadonly()}var oa=(()=>{class i{constructor(){this.ngModels=Nt(_t),this.#e=y(Pt),this.#i=v(null),this.masking=m("mediumDate"),this.closed=se(),this._maskedDate=S(()=>{let e=this.internalDate(),t=this.masking();return t?e?this.#e.transform(e,t):null:e}),this.internalDate=v(null),this.isOpen=H(!1),this.currentClass=Re(),this.#t=Xs("#input-wrap input"),this.#n=k(()=>{let e=this.#t();if(!e.length)return;let t=e[0];t&&(this.#o(t),t.addEventListener("inputValueChanged",n=>{this.internalDate.set(n.detail.value?this.#r(new Date(n.detail.value)):null)}),t.addEventListener("focus",()=>{this.isOpen.set(!0),t.blur()}),this.#i.set(t),t.autocomplete="off",typeof t.value=="string"&&this.internalDate.set(t.value?this.#r(new Date(t.value)):null))})}#e;#i;#t;onDateChange(e){this.internalDate.set(e);let t=this.#i();t&&(t.value=e?e.toString():"",t.dispatchEvent(new Event("input")))}close(){this.closed.emit(this.internalDate())}#n;#o(e){return Object.defineProperty(e,"value",{configurable:!0,get(){return Object.getOwnPropertyDescriptor(HTMLInputElement.prototype,"value").get.call(this)},set(t){Object.getOwnPropertyDescriptor(HTMLInputElement.prototype,"value").set.call(this,t);let s=new CustomEvent("inputValueChanged",{bubbles:!0,cancelable:!0,detail:{value:t}});return this.dispatchEvent(s),t}}),e}#r(e){let n=e.getTimezoneOffset()*60*1e3;return new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())+n)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-datepicker-input"]],contentQueries:function(t,n,s){t&1&&wt(s,n.ngModels,_t,5),t&2&&ie()},inputs:{masking:[1,"masking"],isOpen:[1,"isOpen"]},outputs:{closed:"closed",isOpen:"isOpenChange"},features:[$([Pt])],ngContentSelectors:go,decls:15,vars:3,consts:[["defaultIndicator",""],[3,"closed","isOpenChange","isOpen"],["id","input-wrap","ngProjectAs","input",5,["input"],1,"input"],[1,"masked-value"],["suffix","",1,"default-indicator"],["popoverContent",""],[3,"date","class"],[3,"dateChange","date"]],template:function(t,n){if(t&1){let s=z();T(fo),h(0,"sh-form-field-popover",1),E("closed",function(){return w(s),x(n.close())}),$e("isOpenChange",function(a){return w(s),ze(n.isOpen,a)||(n.isOpen=a),x(a)}),u(1,0,["ngProjectAs","label",5,["label"]]),u(2,1,["ngProjectAs","[prefix]",5,["","prefix",""]]),u(3,2,["ngProjectAs","[textPrefix]",5,["","textPrefix",""]]),h(4,"div",2),b(5,mo,2,1,"div",3),u(6,3),g(),u(7,4,["ngProjectAs","[textSuffix]",5,["","textSuffix",""]]),u(8,5,["ngProjectAs","[suffix]",5,["","suffix",""]]),h(9,"sh-icon",4),C(10,"calendar"),g(),h(11,"div",5),b(12,vo,1,3,"sh-datepicker",6),g()(),fe(13,_o,0,0,"ng-template",null,0,ui)}t&2&&(Ue("isOpen",n.isOpen),p(5),M(n.masking()?5:-1),p(7),M(n.isOpen()?12:-1))},dependencies:[Ws,Ys,_e],encapsulation:2,changeDetection:0})}}return i})();var Qs=(()=>{class i{static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-divider"]],ngContentSelectors:Y,decls:1,vars:0,template:function(t,n){t&1&&(T(),u(0))},encapsulation:2,changeDetection:0})}}return i})();var Zt=(()=>{class i{#e=y(I);onClick(){this.#e.nativeElement.querySelector("input")&&this.#e.nativeElement.querySelector("input").focus(),this.#e.nativeElement.querySelector("textarea")&&this.#e.nativeElement.querySelector("textarea").focus()}constructor(){bt(()=>{let e=typeof CSS<"u"&&CSS.supports("field-sizing","content"),t=this.#e.nativeElement.querySelector("textarea");if(!e&&t!==null){let r=function(){t.style.height="auto",t.style.height=t.scrollHeight+"px"},a=function(){setTimeout(r,0)};var n=r,s=a;t.addEventListener("change",r),t.addEventListener("cut",a),t.addEventListener("paste",a),t.addEventListener("drop",a),t.addEventListener("keydown",a),t.focus(),t.select(),r()}})}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-form-field"]],hostBindings:function(t,n){t&1&&E("click",function(){return n.onClick()})},ngContentSelectors:yo,decls:17,vars:0,consts:[[1,"input-wrap"],[1,"prefix"],[1,"suffix"],[1,"helpers"],[1,"error-wrap"],[1,"hint"]],template:function(t,n){t&1&&(T(Co),u(0),A(1,"div",0)(2,"div",1),u(3,1),u(4,2),u(5,3),F(),u(6,4),u(7,5),A(8,"div",2),u(9,6),u(10,7),u(11,8),F()(),A(12,"div",3)(13,"div",4),u(14,9),F(),A(15,"div",5),u(16,10),F()())},encapsulation:2,changeDetection:0})}}return i})(),sa=(()=>{class i{constructor(){this._el=y(I),this.inputRef=J.required("input"),this.filesOver=v(!1),this.multiple=m(),this.accept=m(null),this.placeholder=H("Click or drag files here"),this.overlayText=m("Drop files here"),this.files=H([]),this.fileUploadClasses=S(()=>this._el.nativeElement.classList.toString()),this.inputEffect=k(()=>{let e=this.inputRef().nativeElement;e&&(e.placeholder&&this.placeholder.set(e.placeholder),e.addEventListener("dragover",t=>{t.preventDefault(),this.filesOver.set(!0)}),e.addEventListener("dragleave",t=>{t.preventDefault(),this.filesOver.set(!1)}),e.addEventListener("drop",t=>{t.preventDefault(),this.filesOver.set(!1);let n=t.dataTransfer?.files;n&&n.length>0&&(this.handleFileUpload(Array.from(n)),e.files=n)}),e.addEventListener("change",t=>{t.preventDefault(),this.handleFileUpload(Array.from(t.target.files))}))})}handleFileUpload(e){this.multiple()?this.files.update(t=>[...t,...e]):this.files.set(e)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-file-upload"]],viewQuery:function(t,n){t&1&&ue(n.inputRef,Do,5),t&2&&ie()},inputs:{multiple:[1,"multiple"],accept:[1,"accept"],placeholder:[1,"placeholder"],overlayText:[1,"overlayText"],files:[1,"files"]},outputs:{placeholder:"placeholderChange",files:"filesChange"},ngContentSelectors:bo,decls:12,vars:7,consts:[["inputWrap",""],["input",""],["ngProjectAs","input",5,["input"],1,"input"],[1,"files-text"],[1,"placeholder"],["type","file"],[1,"bg-overlay"],["suffix",""]],template:function(t,n){t&1&&(T(So),h(0,"sh-form-field"),u(1,0,["ngProjectAs","label",5,["label"]]),h(2,"div",2,0),b(4,Mo,2,1,"div",3)(5,Eo,2,1,"div",3)(6,wo,2,1,"div",4),oe(7,"input",5,1)(9,"div",6),g(),h(10,"sh-icon",7),C(11,"upload-simple"),g()()),t&2&&(Z(n.fileUploadClasses()),p(4),M(n.files().length===1?4:n.files().length>1?5:6),p(3),ge("multiple",n.multiple())("accept",n.accept()),p(2),N("files-over",n.filesOver()))},dependencies:[Zt,_e],encapsulation:2,changeDetection:0})}}return i})(),ra=(()=>{class i{static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-list"]],ngContentSelectors:Y,decls:1,vars:0,template:function(t,n){t&1&&(T(),u(0))},encapsulation:2,changeDetection:0})}}return i})();function Zs(i,o){let e=v(null),t=o.map(l=>l.toUpperCase()),n=y(xe),s=n.get(he);if(fi(n.get(ri))||typeof MutationObserver>"u")return e.asReadonly();if(t.find(l=>i.nativeElement.querySelector(l)))return e.set(new I(i.nativeElement.querySelector(o[0]))),e.asReadonly();let a=new MutationObserver(l=>{for(let c of l)if(c.addedNodes){for(let d of Array.from(c.addedNodes))if(d.nodeType===Node.ELEMENT_NODE&&t.includes(d.nodeName)){e.set(new I(d)),a.disconnect();return}}});return a.observe(i.nativeElement,{childList:!0,subtree:!0}),s.onDestroy(()=>a.disconnect()),e.asReadonly()}function qi(i,o){let e=y(xe),t=e.get(he),n=v([]),s=null,r=null,a=(c,d)=>{r&&r.disconnect();let _=Array.from(c.nativeElement.querySelectorAll(d.join(",")));n.set(_),typeof MutationObserver<"u"&&(r=new MutationObserver(V=>{queueMicrotask(()=>{let B=Array.from(c.nativeElement.querySelectorAll(d.join(",")));n.set(B)})}),r.observe(c.nativeElement,{childList:!0,subtree:!0})),t.onDestroy(()=>l())};s=k(()=>{let c=typeof i=="function"&&i[Jt]?i():i,d=typeof o=="function"?o():o;c&&d?.length>0?a(c,d):(n.set([]),r&&(r.disconnect(),r=null))},{injector:e});function l(){s&&s.destroy(),r&&r.disconnect()}return{signal:n.asReadonly(),destroy:l}}function Ks(i,o=["input","textarea"]){let e=i||Zs(y(I),o),t=v(void 0),n=y(xe),s=n.get(he),r=v(null);k(l=>{let c=e();if(!c)return;let d=c.nativeElement;d&&(Js(d),r.set(d),t.set(d.value??""),l(()=>{r.set(null)}))},{injector:n});let a=null;return k(()=>{let l=r();if(!l)return;a&&(a(),a=null);let c=_=>{t.set(_.detail.value)},d=_=>{t.set(_.target.value)};l.addEventListener("input",d),l.addEventListener("inputValueChanged",c),t.set(l.value),a=()=>{l.removeEventListener("input",d),l.removeEventListener("inputValueChanged",c)},s.onDestroy(()=>{a&&a()})},{injector:n}),k(()=>{let l=r();if(!l)return;let c=t();c&&(l.value=c,l.dispatchEvent(new Event("input")))},{injector:n}),t}function Js(i){return Object.defineProperty(i,"value",{configurable:!0,get(){return Object.getOwnPropertyDescriptor(Object.getPrototypeOf(i),"value").get.call(this)},set(o){Object.getOwnPropertyDescriptor(Object.getPrototypeOf(i),"value").set.call(this,o);let t=new CustomEvent("inputValueChanged",{bubbles:!0,cancelable:!0,detail:{value:o}});return this.dispatchEvent(t),o}}),i}var aa=(()=>{class i{constructor(){this.#e=y(Oe),this.#i=y(de),this.asMultiLayer=m(!1),this.openIndicator=m(!1),this.disabled=m(!1),this.customOptionElementSelectors=m(["button"]),this.keepClickedOptionActive=m(!1),this.closeOnClick=m(!0),this.isOpen=H(!1),this.closed=se(),this.searchable=m(!1),this.activeOptionIndex=v(-1),this.inputRef=J("inputRef"),this.optionsRef=J("optionsRef"),this.options=qi(this.optionsRef,this.customOptionElementSelectors),this.optionsEl=S(()=>this.options.signal().filter(e=>!e.disabled)),this.inputValue=Ks(this.inputRef),this.abortController=null,this.optionsEffect=k(()=>{if(this.abortController!==null&&(this.abortController.abort(),this.abortController=null),!this.isOpen())return;this.abortController=new AbortController,this.searchable()||this.#e.documentElement.addEventListener("keydown",this.keyDownEventListener,{signal:this.abortController.signal});let t=this.inputRef()?.nativeElement;t&&(queueMicrotask(()=>t.focus()),t.addEventListener("keydown",this.keyDownEventListener,{signal:this.abortController.signal}),this.closeOnClick()||this.optionsRef()?.nativeElement?.addEventListener("click",s=>{let r=s.target,a=this.activeElements();if(!a.length){let c=this.optionsEl();this.activeElements.set(c),a=c}let l=a.findIndex(c=>c===r);l>-1&&(this.activeOptionIndex.set(l),t.focus())}))}),this.keyDownEventListener=e=>{let t=this.activeOptionIndex();e.key==="ArrowDown"?(e.preventDefault(),this.activeOptionIndex.set(this.nextActiveIndex(t))):e.key==="ArrowUp"?(e.preventDefault(),this.activeOptionIndex.set(this.prevActiveIndex(t))):e.key==="Enter"?(e.preventDefault(),t>-1&&(this.activeElements()[t].click(),queueMicrotask(()=>this.close("active")))):e.key==="Tab"&&(e.preventDefault(),this.close("closed"))},this._lastElementList=[],this.activeElements=v([]),this.lastInputValue="",this.inputValueEffect=k(()=>{if(!this.searchable())return;let t=(this.inputValue()??"").toLowerCase();if(this.#n(),!t||t===""){let s=this.optionsEl();this.activeElements.set(s),this._lastElementList=s;for(let r=0;r<s.length;r++)this.#i.removeStyle(s[r],"order");return}if(!t||t==="")return;let n=this._lastElementList.length&&t.length>this.lastInputValue.length?this._lastElementList:this.optionsEl();this.lastInputValue=t;for(let s=0;s<n.length;s++){let r=n[s],a=r.textContent?.toLowerCase()||"",l=this.#t(a,t);r.value=l}n=n.filter(s=>s.value>0).sort((s,r)=>r.value-s.value);for(let s=0;s<n.length;s++)this.#i.setStyle(n[s],"order",s);this.activeElements.set(n),this._lastElementList=n}),this.activeOptionIndexEffect=k(()=>{let e=this.activeElements(),t=this.activeOptionIndex();for(let n=0;n<e.length;n++)e[n].classList.remove("active");t>-1&&(e[t].scrollIntoView({block:"center"}),e[t].classList.add("active"))})}#e;#i;toggleIsOpen(e){e.preventDefault(),e.stopPropagation(),!this.disabled()&&(this.isOpen.set(!this.isOpen()),this.searchable()&&this.isOpen()&&setTimeout(()=>this.inputRef()?.nativeElement.focus()))}#t(e,t){if(!t)return 0;let n=0,s=-1,r=0,a=!0;for(let l=0;l<t.length;l++){let c=t[l];if(e.length>s+1&&e[s+1]===c)n+=l===0?100:150,s++,r++;else{let d=e.indexOf(c,s+1);if(l>0&&(a=!1),d===-1)return 0;n+=100,s=d,r++}}return a&&t.length===r&&(n+=1e3),n+=r*20,n}nextActiveIndex(e){let t=this.activeElements();if(!t.length){let s=this.optionsEl();this.activeElements.set(s),t=s}if(e===-1||e===t.length-1)return 0;let n=e+1;return t[n].disabled?this.nextActiveIndex(n):n}prevActiveIndex(e){let t=this.activeElements();if(!t.length){let s=this.optionsEl();this.activeElements.set(s),t=s}if(e===0||e===-1)return t.length-1;let n=e-1;return t[n].disabled?this.prevActiveIndex(n):n}close(e="closed",t){this.inputValue.set(""),this.closeOnClick()&&((!this.keepClickedOptionActive()||e==="closed")&&this.#n(),this.isOpen.set(!1),this.closed.emit(e==="active"))}#n(){this.activeOptionIndex.set(-1);let e=this.optionsEl();for(let t=0;t<e.length;t++)e[t].classList.remove("active")}ngOnDestroy(){this.abortController&&(this.abortController.abort(),this.abortController=null)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-menu"]],viewQuery:function(t,n){t&1&&ue(n.inputRef,xo,5)(n.optionsRef,Oo,5),t&2&&ie(2)},hostVars:6,hostBindings:function(t,n){t&2&&N("disabled",n.disabled())("has-search",n.searchable())("multi-layer",n.asMultiLayer())},inputs:{asMultiLayer:[1,"asMultiLayer"],openIndicator:[1,"openIndicator"],disabled:[1,"disabled"],customOptionElementSelectors:[1,"customOptionElementSelectors"],keepClickedOptionActive:[1,"keepClickedOptionActive"],closeOnClick:[1,"closeOnClick"],isOpen:[1,"isOpen"],searchable:[1,"searchable"]},outputs:{isOpen:"isOpenChange",closed:"closed"},ngContentSelectors:To,decls:12,vars:12,consts:[["formFieldWrapper",""],["inputRef",""],["optionsRef",""],[3,"isOpenChange","closed","isOpen","disableOpenByClick","asMultiLayer","options"],["trigger","",3,"click"],[1,"open-indicator"],[1,"form-field-wrap"],[1,"small","stretch"],["type","text","placeholder","Search"],[1,"options",3,"click"]],template:function(t,n){if(t&1){let s=z();T(Vo),h(0,"sh-popover",3,0),$e("isOpenChange",function(a){return w(s),ze(n.isOpen,a)||(n.isOpen=a),x(a)}),E("closed",function(){return w(s),x(n.close("fromPopover"))}),h(2,"div",4),E("click",function(a){return w(s),x(n.toggleIsOpen(a))}),u(3),b(4,No,2,0,"sh-icon",5),g(),h(5,"div",6)(6,"sh-form-field",7),oe(7,"input",8,1),g()(),h(9,"div",9,2),E("click",function(){return w(s),x(n.close("active"))}),u(11,1),g()()}t&2&&(Ue("isOpen",n.isOpen),Q("disableOpenByClick",!0)("asMultiLayer",n.asMultiLayer())("options",st(11,Wi)),p(2),N("is-open",n.isOpen()),p(2),M(n.openIndicator()?4:-1),p(2),N("hidden",n.searchable()===!1),p(3),N("searching",n.searchable()&&n.inputValue()!==""))},dependencies:[Qt,Zt,_e],encapsulation:2,changeDetection:0})}}return i})(),er=(()=>{class i{constructor(){this.value=m(void 0)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-progress-bar"]],inputs:{value:[1,"value"]},decls:1,vars:2,consts:[[1,"progress-bar"]],template:function(t,n){t&1&&ye(0,"div",0),t&2&&G("width",n.value(),"%")},encapsulation:2,changeDetection:0})}}return i})(),la=(()=>{class i{constructor(){this.currentClassList=Re()}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-radio"]],ngContentSelectors:Y,decls:2,vars:2,consts:[[1,"radio","sh-sheet"]],template:function(t,n){t&1&&(T(),ye(0,"div",0),u(1)),t&2&&Z(n.currentClassList())},encapsulation:2,changeDetection:0})}}return i})(),ca=(()=>{class i{constructor(){this.#e=y(I),this.#i=null,this.#t=null,this.#n=0,this.unit=m(""),this.value=H(this.#n),this.inputState=v({min:0,max:100,step:1}),this.valuePercentage=S(()=>{let{min:e,max:t}=this.inputState(),n=this.value()??e;if(isNaN(n))return 0;let s=t-e;if(s===0)return 0;let r=(n-e)/s*100;return Math.max(0,Math.min(100,r))}),this.trackFilledPercentage=S(()=>this.valuePercentage()),this.thumbPositionPercentage=S(()=>this.valuePercentage()),this.syncModelToInputEffect=k(()=>{let e=this.value();if(this.#t){let t=parseFloat(this.#t.value);(isNaN(t)||String(t)!==String(e))&&(this.#t.value=String(e))}})}#e;#i;#t;#n;get hasInputElement(){return!!this.#t}ngAfterViewInit(){this.#t=this.#e.nativeElement.querySelector('input[type="range"]'),this.#t?(this.#s(this.#t),this.#t.oninput=()=>{this.setNewInputValue(this.#t.value)},this.#t.addEventListener("inputValueChanged",e=>{this.setNewInputValue(e.detail.value)}),queueMicrotask(()=>this.#o(!0)),this.#r()):console.error('ShipRangeSlider: No <input type="range"> element found projected inside.')}setNewInputValue(e){let t=parseFloat(e??"0");if(!isNaN(t)){let{min:n,max:s}=this.inputState();this.value.set(Math.max(n,Math.min(s,t)))}}trackEvent(e){if(!this.#t||this.#t.readOnly||this.#t.disabled){e.preventDefault(),e.stopPropagation();return}if(e.target===this.#t||e.target?.closest(".thumb, .min-indicator, .max-indicator"))return;let n=e.currentTarget.getBoundingClientRect(),s=e.clientX-n.left,r=n.width,{min:a,max:l,step:c}=this.inputState(),d=l-a;if(r>0&&d!==0&&c>0){let V=(s/r*d+a-a)/c,B=a+Math.round(V)*c,te=this.#a(c);B=parseFloat(B.toFixed(te));let ee=Math.max(a,Math.min(l,B));this.value.set(ee)}}#o(e=!1){if(!this.#t)return;let t=parseFloat(this.#t.min??"0")??0,n=parseFloat(this.#t.max??"100")??100,s=this.#t.step,r=1;if(s&&s.toLowerCase()!=="any"){let l=parseFloat(s);!isNaN(l)&&l>0&&(r=l)}this.inputState.set({min:t,max:n,step:r});let a=parseFloat(this.#t.value??String(t))??t;if(e&&this.value()!==this.#n){let l=this.value(),c=Math.max(t,Math.min(n,l));a!==c&&(this.#t.value=String(c)),l!==c&&this.value.set(c)}else{let l=Math.max(t,Math.min(n,a));this.value()!==l&&this.value.set(l)}}#r(){if(!this.#t||typeof MutationObserver>"u")return;let e=["min","max","step","value","readonly","disabled"];this.#i=new MutationObserver(t=>{let n=!1;for(let s of t)if(s.type==="attributes"&&e.includes(s.attributeName??"")){n=!0;break}n&&this.#o(!1)}),this.#i.observe(this.#t,{attributes:!0,attributeFilter:e})}#a(e){if(isNaN(e)||Math.floor(e)===e)return 0;let n=e.toString().split(".")[1];return n?n.length:0}#s(e){Object.defineProperty(e,"value",{configurable:!0,get(){return Object.getOwnPropertyDescriptor(Object.getPrototypeOf(e),"value").get.call(this)},set(t){Object.getOwnPropertyDescriptor(Object.getPrototypeOf(e),"value").set.call(this,t);let s=new CustomEvent("inputValueChanged",{bubbles:!0,cancelable:!0,detail:{value:t}});return this.dispatchEvent(s),t}})}ngOnDestroy(){this.#i&&this.#i.disconnect(),this.#t&&(this.#t.oninput=null)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-range-slider"]],hostVars:2,hostBindings:function(t,n){t&2&&N("has-input",n.hasInputElement)},inputs:{unit:[1,"unit"],value:[1,"value"]},outputs:{value:"valueChange"},ngContentSelectors:Io,decls:15,vars:10,consts:[[1,"label"],[1,"input-wrap"],[1,"min-indicator"],[1,"track-wrap",3,"click"],[1,"track"],[1,"track-filled"],[1,"thumb-wrap"],[1,"thumb"],[1,"value-indicator"],[1,"max-indicator"]],template:function(t,n){t&1&&(T(Ao),A(0,"div",0),u(1),F(),A(2,"div",1)(3,"div",2),C(4),F(),A(5,"div",3),Se("click",function(r){return n.trackEvent(r)}),u(6,1),A(7,"div",4),ye(8,"div",5),F(),A(9,"div",6)(10,"div",7)(11,"div",8),C(12),F()()()(),A(13,"div",9),C(14),F()()),t&2&&(p(4),nt("",n.inputState().min,"",n.unit()),p(4),G("width",n.trackFilledPercentage(),"%"),p(),G("left",n.thumbPositionPercentage(),"%"),p(3),nt("",n.value(),"",n.unit()),p(2),nt("",n.inputState().max,"",n.unit()))},encapsulation:2,changeDetection:0})}}return i})(),tr=(()=>{class i{static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-spinner"]],decls:0,vars:0,template:function(t,n){},encapsulation:2,changeDetection:0})}}return i})(),da=(()=>{class i{constructor(){this.#e=y(I),this.value=m(),this.label=m(),this.asFreeText=m(!1),this.optionTitle=m(null),this.freeTextTitle=m(null),this.freeTextPlaceholder=m("Type to create a new option"),this.validateFreeText=m(),this.placeholder=m(),this.readonly=H(!1),this.disabled=H(!1),this.lazySearch=m(!1),this.inlineSearch=m(!1),this.asText=m(!1),this.isClearable=m(!0),this.selectMultiple=m(!1),this.optionTemplate=m(null),this.selectedOptionTemplate=m(null),this.placeholderTemplate=m(null),this.freeTextOptionTemplate=m(null),this.isOpen=H(!1),this.isLoading=H(!1),this.options=H([]),this.selectedOptions=H([]),this.cleared=se(),this.onAddNewFreeTextOption=se(),this.computedFreeTextOption=S(()=>{let e=this.inputValue(),t=this.value(),n=t?{}:e;return t&&typeof n=="object"&&(n[t]=e),n}),this.#i=v(null),this.inlineTemplate=Nt(it),this.optionsWrapRef=J.required("optionsWrap"),this.inputRefInput=v(null),this.#t=typeof MutationObserver<"u"&&new MutationObserver(e=>{for(var t of e)t&&(t.target.nodeName==="INPUT"||t.target.nodeName==="TEXTAREA")&&(this.inputRefInput.set(new I(t.target)),this.#t.disconnect())}),this.inputValue=v(""),this.prevInputValue=v(null),this.focusedOptionIndex=v(-1),this._isClearable=S(()=>this.selectMultiple()||this.isClearable()),this.selectClasses=S(()=>this.#e.nativeElement.classList.toString()),this.stretch=S(()=>this.selectClasses().includes("stretch")),this.small=S(()=>this.selectClasses().includes("small")),this.placeholderText=S(()=>{let e=this.placeholder(),t=this.inputRefEl();return e||t?.placeholder||null}),this.selectedOptionValues=S(()=>{let e=this.selectedOptions(),t=this.value();return t?e.map(n=>this.#s(n,t)):e}),this.filteredOptions=S(()=>{let e=this.options()||[],t=this.label(),n=this.value(),s=this.inlineSearch(),r=this.inputValue().toLowerCase(),a=this.#c(r);if(e.length<=0)return[];if(!s||r==="")return e;let c=e.filter(d=>{let _=t?(this.#s(d,t)??"").toString().toLowerCase():(d??"").toString().toLowerCase(),V=((n?this.#s(d,n):d)??"").toString().toLowerCase(),B=a.test(_),te=a.test(V);return B||te}).map(d=>{let _=t?(this.#s(d,t)??"").toString().toLowerCase():(d??"").toString().toLowerCase(),V=((n?this.#s(d,n):d)??"").toString().toLowerCase(),B=this.#n(_,r),te=this.#n(V,r);return{item:d,score:Math.max(B,te)}});return c.sort((d,_)=>_.score-d.score),c.map(d=>d.item)}),this.#o=Dt(),this.inputRefEl=S(()=>{let e=this.inputRefInput();if(e===null)return;let t=e?e.nativeElement:null;return t?(t.autocomplete="off",t.setAttribute("role","combobox"),t.setAttribute("id",`combobox-${this.#o}`),t.setAttribute("aria-haspopup","listbox"),t.setAttribute("aria-owns","optionsWrapId"),this.#l(t),t.addEventListener("focus",()=>{this.readonly()||this.open()}),t.addEventListener("input",n=>{let s=n.target.value,r=this.inputValue();s!==r&&(this.focusedOptionIndex.set(this.asFreeText()?-1:0),this.inputValue.set(s),this.updateInputElValue())}),t.addEventListener("inputValueChanged",n=>{let s=n.detail.value,r=this.inputValue();if(s!==r){if(s===""){this.clear();return}this.setSelectedOptionsFromValue(s),this.setInputValueFromOptions(this.selectedOptions()),this.#a()}}),t):(console.warn("<sh-select> input element not found are you missing to pass an <input> or <textarea> element to select component?"),null)}),this.focusEffect=k(()=>{let e=this.inputRefEl();if(!e)return;let t=this.getLabelAsSlug(this.filteredOptions()[this.focusedOptionIndex()]);t?e.setAttribute("aria-activedescendant",t):e.removeAttribute("aria-activedescendant")}),this.openAbortController=null,this.isOpenEffect=k(()=>{if(this.isOpen()){this.openAbortController||(this.openAbortController=new AbortController);let t=this.inputRefEl(),s=this.asFreeText()?-1:0;if(!t)return;t.setAttribute("aria-expanded",this.isOpen().toString()),t.addEventListener("keydown",r=>{if((r.key==="Escape"||r.key==="Tab")&&(r.preventDefault(),this.close()),r.key==="Enter"&&(r.preventDefault(),this.toggleOptionByIndex(this.focusedOptionIndex(),void 0,!0)),r.key==="ArrowDown"){r.preventDefault();let a=this.focusedOptionIndex()+1;this.focusedOptionIndex.set(a>this.filteredOptions().length-1?s:a)}if(r.key==="ArrowUp"){r.preventDefault();let a=this.focusedOptionIndex()-1;this.focusedOptionIndex.set(a<s?this.filteredOptions().length-1:a)}},{signal:this.openAbortController?.signal})}else{let t=this.inputRefEl();if(!t)return;t.setAttribute("aria-expanded",this.isOpen().toString()),this.openAbortController&&(this.openAbortController.abort(),this.openAbortController=null)}}),this._inputValue="",this.inputValueEffect=k(()=>{let e=this.inputValue();this._inputValue=e}),this.inputRefElEffect=k(()=>{let e=this.inputRefEl();e&&e.value!==this._inputValue&&(this.disabled.set(e.disabled),this.setSelectedOptionsFromValue(e.value),this.setInputValueFromOptions(this.selectedOptions()))}),this.selectedLabels=S(()=>{let e=this.selectedOptions();return this.label()?e.map(n=>this.getLabel(n)).join(", "):e.join(", ")}),this.inputState=S(()=>(this.selectedOptions().length>0||this.asFreeText()&&this.inputValue().length>0)&&!this.isOpen()?"selected":this.isLoading()?"loading":this.isOpen()&&(this.lazySearch()||this.inlineSearch())?"open-searching":this.isOpen()?"open":this.inlineSearch()||this.lazySearch()?"searching":"closed"),this.hasSearch=S(()=>this.inlineSearch()||this.lazySearch()),this.#r=k(()=>{if(this.selectMultiple()&&this.hasSearch())return;let e=this.selectedOptions(),t=this.value(),n=e.map(s=>t?this.#s(s,t):s).join(",");this.inputValue.set(n)})}#e;#i;#t;#n(e,t){if(!t)return 0;let n=0,s=-1,r=0,a=!0;for(let l=0;l<t.length;l++){let c=t[l];if(e.length>s+1&&e[s+1]===c)n+=l===0?100:150,s++,r++;else{let d=e.indexOf(c,s+1);if(l>0&&(a=!1),d===-1)return 0;n+=100,s=d,r++}}return a&&t.length===r&&(n+=1e3),n+=r*20,n}#o;#r;ngOnInit(){this.setInitInput()}setInitInput(){let e=this.#e.nativeElement.querySelector("input");if(e){this.inputRefInput.set(new I(e));return}let t=this.#e.nativeElement.querySelector("textarea");if(t){this.inputRefInput.set(new I(t));return}typeof MutationObserver<"u"&&this.#t.observe(this.#e.nativeElement,{attributes:!0,childList:!0,subtree:!0,characterData:!0})}setSelectedOptionsFromValue(e){let t=this.options()||[],n=this.value(),s=this.selectMultiple(),r=e.toString().split(",");if(r.length===0){this.selectedOptions.set([]);return}let a=s?r:[r[0]],l=t.filter(c=>{let d=n?this.#s(c,n)?.toString():c?.toString();return d&&a.includes(d)});this.selectedOptions.set(s?l:[l[0]])}setInputValueFromOptions(e){let t=this.value();if(e.length===0){this.inputValue.set(""),this.updateInputElValue();return}let n=e.map(s=>t?this.#s(s,t):s).join(",");n!==this.inputValue()&&(this.inputValue.set(n),this.updateInputElValue())}getValue(e){let t=this.value();return t?this.#s(e,t):e}getLabel(e){let t=this.label();return t?this.#s(e,t):e}getLabelAsSlug(e){let t=this.getLabel(e);return!t||typeof t!="string"?"":t.replaceAll(" ","-")}toggleOptionByIndex(e,t,n=!1){let s=this.filteredOptions()[e];if(this.asFreeText()&&e===-1){let _=this.computedFreeTextOption(),V=this.getValue(_);if(!(this.validateFreeText()??(ee=>!0))(V))return;this.options.update(ee=>ee.findIndex(St=>this.getValue(St)===V)>-1?ee:(this.onAddNewFreeTextOption.emit(V),[_,...ee])),e=0,s=_}else if(!s){this.close();return}t&&t.stopPropagation();let r=this.selectMultiple(),a=this._isClearable(),l=this.value(),c=this.selectedOptionValues(),d=l?this.#s(s,l):s;this.prevInputValue.set(null),this.#i.set(null),this.selectedOptions.update(_=>{let V=c.indexOf(d);if(V>-1){let B=[..._.slice(0,V),..._.slice(V+1)];return a||B.length>0?B:_}else return this.focusedOptionIndex.set(e),r?[..._,s]:[s]}),r?this.inputRefEl()?.focus():this.isOpen.set(!1),this.setInputValueFromOptions(this.selectedOptions()),r&&this.hasSearch()&&(this.inputValue.set(""),this.updateInputElValue())}removeSelectedOptionByIndex(e,t){e.stopPropagation(),this.selectedOptions.update(n=>[...n.slice(0,t),...n.slice(t+1)]),this.setInputValueFromOptions(this.selectedOptions())}isSelected(e){let t=this.value(),n=this.filteredOptions()[e],s=t?this.#s(n,t):n;return this.selectedOptionValues().indexOf(s)>-1}open(){this.isOpen()||(this.isOpen.set(!0),this.hasSearch()?(this.prevInputValue.set(this.inputValue()??""),this.inputValue.set(""),this.updateInputElValue()):this.#i.set(this.selectedOptions()),this.selectMultiple()||this.#a())}#a(){let e=this.selectedOptionValues()[0],t=this.value();if(e){let n=this.filteredOptions().findIndex(s=>t?this.#s(s,t)===e:s===e);this.focusedOptionIndex.set(n)}else this.focusedOptionIndex.set(-1)}close(){this.isOpen.set(!1);let e=this.prevInputValue(),t=this.#i();if(this.asFreeText()){this.updateInputElValue();return}this.hasSearch()&&e&&(this.inputValue.set(e),this.setInputValueFromOptions(this.selectedOptions())),!this.hasSearch()&&t!==null&&this.setInputValueFromOptions(t),this.selectMultiple()&&this.setInputValueFromOptions(this.selectedOptions())}clear(e){e?.stopPropagation(),this.inputValue.set(""),this.selectedOptions.set([]),this.isOpen.set(!1),this.prevInputValue.set(null),this.cleared.emit(),this.updateInputElValue()}updateInputElValue(){let e=this.inputRefEl(),t=this.inputValue();e&&(e.value=t,e.dispatchEvent(new Event("input")))}#s(e,t){return t.split(".").reduce((n,s)=>n?.[s],e)}#l(e){Object.defineProperty(e,"value",{configurable:!0,get(){return Object.getOwnPropertyDescriptor(Object.getPrototypeOf(e),"value").get.call(this)},set(t){Object.getOwnPropertyDescriptor(Object.getPrototypeOf(e),"value").set.call(this,t);let s=new CustomEvent("inputValueChanged",{bubbles:!0,cancelable:!0,detail:{value:t}});return this.dispatchEvent(s),t}})}#c(e){let t=(e??"").toLowerCase(),n="^";for(let s of t)n+=".*"+this.#d(s);return n+=".*$",new RegExp(n,"i")}#d(e){return e.replace(/[-\/\\^$+?.()|[\]{}]/g,"\\$&")}ngOnDestroy(){this.openAbortController&&(this.openAbortController.abort(),this.openAbortController=null),typeof MutationObserver<"u"&&this.#t.disconnect()}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-select"]],contentQueries:function(t,n,s){t&1&&wt(s,n.inlineTemplate,it,5),t&2&&ie()},viewQuery:function(t,n){t&1&&ue(n.optionsWrapRef,Fo,5),t&2&&ie()},hostVars:2,hostBindings:function(t,n){t&2&&N("multiple",n.selectMultiple())},inputs:{value:[1,"value"],label:[1,"label"],asFreeText:[1,"asFreeText"],optionTitle:[1,"optionTitle"],freeTextTitle:[1,"freeTextTitle"],freeTextPlaceholder:[1,"freeTextPlaceholder"],validateFreeText:[1,"validateFreeText"],placeholder:[1,"placeholder"],readonly:[1,"readonly"],disabled:[1,"disabled"],lazySearch:[1,"lazySearch"],inlineSearch:[1,"inlineSearch"],asText:[1,"asText"],isClearable:[1,"isClearable"],selectMultiple:[1,"selectMultiple"],optionTemplate:[1,"optionTemplate"],selectedOptionTemplate:[1,"selectedOptionTemplate"],placeholderTemplate:[1,"placeholderTemplate"],freeTextOptionTemplate:[1,"freeTextOptionTemplate"],isOpen:[1,"isOpen"],isLoading:[1,"isLoading"],options:[1,"options"],selectedOptions:[1,"selectedOptions"]},outputs:{readonly:"readonlyChange",disabled:"disabledChange",isOpen:"isOpenChange",isLoading:"isLoadingChange",options:"optionsChange",selectedOptions:"selectedOptionsChange",cleared:"cleared",onAddNewFreeTextOption:"onAddNewFreeTextOption"},ngContentSelectors:ko,decls:33,vars:25,consts:[["formFieldWrapper",""],["optionsWrap",""],[3,"isOpenChange","closed","isOpen","disableOpenByClick","options"],["trigger","",3,"click"],["ngProjectAs","input",5,["input"],1,"input"],[1,"selected-value"],["suffix",""],["suffix","",1,"primary"],["id","optionsWrapId","role","listbox",1,"ship-options"],["title",""],[1,"option",3,"id","selected","focused"],[1,"small",3,"class"],[1,"small",3,"click"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],[4,"ngTemplateOutlet"],["suffix","",3,"click"],[1,"option",3,"click","id"],[3,"class","active"]],template:function(t,n){if(t&1){let s=z();T(Po),ot(0)(1)(2)(3)(4)(5)(6),h(7,"sh-popover",2,0),$e("isOpenChange",function(a){return w(s),ze(n.isOpen,a)||(n.isOpen=a),x(a)}),E("closed",function(){return w(s),x(n.close())}),h(9,"sh-form-field",3),E("click",function(){return w(s),x(n.open())}),u(10,0,["ngProjectAs","label",5,["label"]]),u(11,1,["ngProjectAs","[prefix]",5,["","prefix",""]]),u(12,2,["ngProjectAs","[boxPrefix]",5,["","boxPrefix",""]]),h(13,"div",4)(14,"div",5),b(15,Lo,1,1)(16,Qo,2,0)(17,es,2,1),u(18,3),u(19,4),g()(),b(20,ts,2,0,"sh-icon",6)(21,is,1,0,"sh-spinner",7)(22,ns,2,0,"sh-icon",6)(23,os,2,0,"sh-icon",6)(24,ss,2,0,"sh-icon",6)(25,rs,2,0,"sh-icon",6)(26,as,2,0,"sh-icon",6),g(),h(27,"div",8,1),b(29,ms,3,3),b(30,vs,2,1,"p",9),Ve(31,Ss,4,8,"li",10,je),g()()}if(t&2){ne(n.placeholderTemplate());let s=n.optionTemplate();p(),ne(n.freeTextOptionTemplate());let r=n.selectedOptionTemplate(),a=n.inlineTemplate();p();let l=ne(n.selectedOptions()),c=n.inputState();p(),ne(r||s||a),p(),ne(s||a),p();let d=ne(!n.asText()&&n.selectMultiple());p();let _=ne(n.isOpen()&&n.hasSearch()&&(d||n.inputValue().length>-1));p(),Ue("isOpen",n.isOpen),Q("disableOpenByClick",!0)("options",st(24,Ro)),p(2),N("stretch",n.stretch())("small",n.small())("readonly",n.readonly()||n.disabled()),p(4),N("show-search-text",_),p(),N("is-selected",c==="selected"),p(),M(n.asFreeText()&&n.inputValue().length>0&&!n.isOpen()?15:l.length>0?16:_?-1:17),p(5),M(c==="closed"?20:c==="loading"?21:c==="open-searching"?22:c==="searching"?23:c==="selected"&&n._isClearable()?24:c==="selected"&&!n._isClearable()?25:26),p(9),M(n.asFreeText()?29:-1),p(),M(n.optionTitle()&&n.filteredOptions().length>0?30:-1),p(),Te(n.filteredOptions())}},dependencies:[pi,Qt,Zt,_e,zs,tr,$s,Qs],encapsulation:2,changeDetection:0})}}return i})();function ir(i){let o=y(I),e=y(he),t=v(!1),n=typeof MutationObserver<"u"&&new MutationObserver(s=>{s.forEach(r=>{r.type==="attributes"&&r.attributeName==="class"&&t.set(o.nativeElement.classList.contains(i))})});return si(o.nativeElement,()=>{n&&n.observe(o.nativeElement,{attributes:!0}),t.set(o.nativeElement.classList.contains(i))}),e.onDestroy(()=>{n&&n.disconnect()}),t}var ua=(()=>{class i{constructor(){this.#e=y(Oe),this.#i=y(I),this.openWidth=280,this.openWidthTreshold=this.openWidth*.5,this.disableDrag=m(!1),this.isOpen=H(!1),this.isOverlay=ir("overlay"),this.#t=this.#i.nativeElement.parentElement,this.#n=this.#t.getBoundingClientRect&&this.#t.getBoundingClientRect(),this.dragImageElement=J.required("dragImageElement"),this.dragIsEnding=v(!1),this.dragIsOnScreen=v(!0),this.isDragging=v(!1),this.dragPositionX=v(0),this.dragActualPositionX=S(()=>{let e=this.dragPositionX(),t=280,n=100,s=.008,r=t/2,a=r-n/2,l=r+n/2;if(e>l){let c=e-l,_=(t-l)*(1-Math.exp(-s*c));return l+_}else if(e<a){let c=a-e,_=a*(1-Math.exp(-s*c));return a-_}return e}),this.draggingStyle=S(()=>!this.isOverlay()||this.disableDrag()?null:this.isDragging()?`translateX(${this.dragActualPositionX()}px)`:this.isOpen()?`translateX(${this.openWidth}px)`:"translateX(0px)"),this.draggingEffect=k(()=>{this.disableDrag()||(this.isDragging()?this.#e.body.classList.add("dragging"):this.#e.body.classList.remove("dragging"))})}#e;#i;#t;#n;drop(e){e.stopPropagation(),this.#o(e.clientX-this.#n.left)}#o(e){this.isDragging.set(!1),e>=this.openWidthTreshold?this.isOpen.set(!0):this.isOpen.set(!1)}dragEnd(e){e.clientX-this.#n.left<0&&this.#o(0),e.clientX-this.#n.left>this.openWidthTreshold&&this.#o(this.openWidthTreshold)}dragEnter(){this.dragIsOnScreen.set(!0)}dragLeave(){this.dragIsOnScreen.set(!1)}dragStart(e){e.stopPropagation(),this.#n=this.#t.getBoundingClientRect(),this.isDragging.set(!0)}drag(e){e.stopPropagation(),this.isDragging()&&(e.clientX!==0||e.clientY!==0)&&this.dragPositionX.set(e.clientX-this.#n.left)}touchStart(e){e.stopPropagation(),this.isDragging.set(!0),this.#n=this.#t.getBoundingClientRect(),this.dragPositionX.set(0)}touchMove(e){e.stopPropagation(),this.isDragging()&&this.dragPositionX.set(e.touches[0].clientX-this.#n.left)}touchEnd(e){e.stopPropagation(),this.#o(e.changedTouches[0].clientX-this.#n.left)}touchCancel(e){e.stopPropagation(),this.isDragging.set(!1)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-sidenav"]],viewQuery:function(t,n){t&1&&ue(n.dragImageElement,bs,5),t&2&&ie()},hostVars:6,hostBindings:function(t,n){t&2&&N("open",n.isOpen())("closed",!n.isOpen())("is-dragging",n.isDragging())},inputs:{disableDrag:[1,"disableDrag"],isOpen:[1,"isOpen"]},outputs:{isOpen:"isOpenChange"},ngContentSelectors:Es,decls:10,vars:5,consts:[["dragImageElement",""],[1,"drag-image"],[1,"dropping-surface"],[1,"sidenav"],[1,"main-wrap"],["draggable","true",1,"dragable"],[1,"closed-topbar"],[1,"dropping-surface",3,"drop","dragenter","dragleave"],["draggable","true",1,"dragable",3,"dragstart","dragend","drag","touchstart","touchmove","touchend","touchcancel"]],template:function(t,n){t&1&&(T(Ms),b(0,ws,2,0,"div",1),b(1,xs,1,0,"div",2),A(2,"div",3),u(3),F(),A(4,"div",4),b(5,Os,1,0,"div",5),A(6,"div",6),u(7,1),F(),A(8,"main"),u(9,2),F()()),t&2&&(M(n.isOverlay()&&!n.disableDrag()?0:-1),p(),M(n.isOverlay()&&n.isDragging()?1:-1),p(3),G("transform",!n.disableDrag()&&n.draggingStyle()),p(),M(n.isOverlay()&&!n.disableDrag()?5:-1))},encapsulation:2,changeDetection:0})}}return i})();var ha=(()=>{class i{static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-stepper"]],ngContentSelectors:Y,decls:1,vars:0,template:function(t,n){t&1&&(T(),u(0))},encapsulation:2,changeDetection:0})}}return i})();var pa=(()=>{class i{constructor(){this.#e=y(nr),this.shSort=m(),this.sortAsc=S(()=>{let e=this.#e.sortByColumn(),t=this.shSort();return!e||!t?!1:e===t}),this.sortDesc=S(()=>{let e=this.#e.sortByColumn(),t=this.shSort();return!e||!t?!1:e===`-${t}`})}#e;toggleSort(){let e=this.shSort();e&&this.#e.toggleSort(e)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275dir=R({type:i,selectors:[["","shSort",""]],hostAttrs:[1,"sortable"],hostVars:4,hostBindings:function(t,n){t&1&&E("mousedown",function(){return n.toggleSort()}),t&2&&N("sort-asc",n.sortAsc())("sort-desc",n.sortDesc())},inputs:{shSort:[1,"shSort"]}})}}return i})();var ke=1.5,nr=(()=>{class i{constructor(){this.#e=y(I),this.#i=y(yt,{optional:!0}),this.loading=m(!1),this.data=m([]),this.dataChange=se(),this.sortByColumn=H(null),this.currentClass=Re(),this.thead=J("thead"),this.tbody=J("tbody"),this.columns=qi(this.thead,["tr:first-child th"]),this.stickyHeaderHeight=S(()=>{let e=this.currentClass();return this.thead()?.nativeElement?.clientHeight??0}),this.bodyEffect=k(()=>{let e=this.tbody()?.nativeElement,t=this.thead()?.nativeElement;if(!e||!t)return;let n=this.stickyHeaderHeight();queueMicrotask(()=>{let s=t.querySelectorAll("tr.sticky").length>0,r=e.querySelectorAll("tr.sticky");if(r.length>0&&s)for(let l=0;l<r.length;l++)r[l].style.top=`${n}px`})}),this.class=v(this.#i?.tableType??"default"),this.resizing=v(!1),this.sizeTrigger=v(!0),this.#t=null,this.#n=v(!1),this.scrollXState=v(-1),this.scrollYState=v(-1),this.canScrollX=v(!1),this.canScrollY=v(!1),this.columnSizes=S(()=>{this.sizeTrigger();let e=this.columns.signal();return e.reduce((t,n,s)=>{let r=n,a=r.getAttribute("size"),l=s===e.length-1;return a?`${t} ${a}`:r.classList.contains("sticky")||r.classList.contains("sticky-end")?`${t} min-content`:l?`${t} 1fr`:`${t} 1fr`},"")}),this.e=k(()=>{let e=this.sortByColumn();if(e===null)return this.#n()||(this.#t=this.data(),this.#n.set(!0)),this.dataChange.emit(structuredClone(this.#t));let t=e.startsWith("-")?e.slice(1):e,n=e.startsWith("-"),s=this.data().sort((r,a)=>{let l=r[t],c=a[t],d=0;return typeof l=="number"&&typeof c=="number"&&(d=l-c),l instanceof Date&&c instanceof Date&&(d=l.getTime()-c.getTime()),typeof l=="string"&&typeof c=="string"&&(d=l.localeCompare(c,void 0,{sensitivity:"base"})),n?-d:d});this.dataChange.emit(s)})}#e;#i;#t;#n;updateColumnSizes(){this.sizeTrigger.set(!this.sizeTrigger())}onScroll(){this.#o()}onResize(e){this.#o()}ngAfterViewInit(){queueMicrotask(()=>this.#o())}toggleSort(e){let t=this.sortByColumn(),n=t===e?`-${e}`:t===`-${e}`?null:e;this.sortByColumn.set(n)}#o(){let e=this.#e.nativeElement,t=-1,n=-1,s=e.scrollWidth>e.clientWidth+ke;if(s){let a=e.scrollLeft<=ke;e.scrollWidth-(e.scrollLeft+e.clientWidth)<ke?t=1:a||(t=0)}this.scrollXState.set(t),this.canScrollX.set(s);let r=e.scrollHeight>e.clientHeight+ke;if(r){let a=e.scrollTop<=ke;e.scrollHeight-(e.scrollTop+e.clientHeight)<ke?n=1:a||(n=0)}this.scrollYState.set(n),this.canScrollY.set(r)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-table"]],viewQuery:function(t,n){t&1&&ue(n.thead,Vs,5)(n.tbody,Ts,5),t&2&&ie(2)},hostVars:18,hostBindings:function(t,n){t&1&&E("scroll",function(){return n.onScroll()})("resize",function(r){return n.onResize(r)},ai),t&2&&(Z(n.class()),G("grid-template-columns",n.columnSizes()),N("resizing",n.resizing())("can-scroll-x",n.canScrollX())("can-scroll-y",n.canScrollY())("scrolled-x",n.scrollXState()>=0)("scrolled-x-end",n.scrollXState()===1)("scrolled-y",n.scrollYState()>=0)("scrolled-y-end",n.scrollYState()===1))},inputs:{loading:[1,"loading"],data:[1,"data"],sortByColumn:[1,"sortByColumn"]},outputs:{dataChange:"dataChange",sortByColumn:"sortByColumnChange"},ngContentSelectors:As,decls:11,vars:2,consts:[["thead",""],["tbody",""],[1,"actionbar"],[1,"indeterminate","primary"],[1,"no-rows"]],template:function(t,n){t&1&&(T(Ns),h(0,"div",2),u(1),g(),b(2,Is,1,0,"sh-progress-bar",3),h(3,"thead",null,0),u(5,1),u(6,2),g(),h(7,"tbody",null,1),u(9,3),g(),b(10,Fs,2,0,"div",4)),t&2&&(p(2),M(n.loading()?2:-1),p(8),M(n.loading()?-1:10))},dependencies:[er],encapsulation:2,changeDetection:0})}}return i})(),fa=(()=>{class i{constructor(){this.id="--"+Math.random().toString(36).substring(2,15)+Math.random().toString(36).substring(2,12)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-tabs"]],hostVars:2,hostBindings:function(t,n){t&2&&G("--tabs-id",n.id)},ngContentSelectors:Y,decls:1,vars:0,template:function(t,n){t&1&&(T(),u(0))},encapsulation:2,changeDetection:0})}}return i})();var ga=(()=>{class i{constructor(){this.isActive=H(!1),this.disallowToggle=m(!1)}ngOnInit(){this.disallowToggle()&&this.isActive.set(!0)}toggle(){this.isActive.set(!this.isActive())}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-toggle-card"]],hostVars:2,hostBindings:function(t,n){t&2&&N("active",n.isActive())},inputs:{isActive:[1,"isActive"],disallowToggle:[1,"disallowToggle"]},outputs:{isActive:"isActiveChange"},ngContentSelectors:ks,decls:7,vars:1,consts:[[3,"click"],[1,"toggle-icon"],[1,"collapsable"],[1,"content"]],template:function(t,n){t&1&&(T(Ps),h(0,"h3",0),E("click",function(){return n.disallowToggle()||n.toggle()}),u(1,0,null,Rs,1,0),b(3,Ls,2,0,"sh-icon",1),g(),h(4,"div",2)(5,"div",3),u(6,1),g()()),t&2&&(p(3),M(n.disallowToggle()?-1:3))},dependencies:[_e],encapsulation:2,changeDetection:0})}}return i})(),ma=(()=>{class i{static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["sh-toggle"]],ngContentSelectors:Y,decls:3,vars:0,consts:[[1,"box"],[1,"knob"]],template:function(t,n){t&1&&(T(),A(0,"div",0),ye(1,"div",1),F(),u(2))},encapsulation:2,changeDetection:0})}}return i})();var va=(()=>{class i{constructor(){this.filesOver=v(!1),this.filesDropped=se()}onDragOver(e){e.preventDefault(),e.stopPropagation(),this.filesOver.set(!0)}onDragLeave(e){e.preventDefault(),e.stopPropagation(),this.filesOver.set(!1)}ondrop(e){e.preventDefault(),e.stopPropagation(),this.filesOver.set(!1);let t=e.dataTransfer?.files;t&&t.length>0&&this.filesDropped.emit(t)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275dir=R({type:i,selectors:[["","shDragDrop",""]],hostVars:2,hostBindings:function(t,n){t&1&&E("dragover",function(r){return n.onDragOver(r)})("dragleave",function(r){return n.onDragLeave(r)})("drop",function(r){return n.ondrop(r)}),t&2&&N("filesover",n.filesOver())},outputs:{filesDropped:"filesDropped"}})}}return i})();var or=(()=>{class i{constructor(){this.positionAnchorName=m.required(),this.anchorEl=m.required(),this.isOpen=m(!1),this.#e=y(I),this.#i=y(de),this.#t=null,this.SUPPORTS_ANCHOR=typeof CSS<"u"&&CSS.supports("position-anchor","--abc"),this.isBelow=v(!1),this.openEffect=k(()=>{this.isOpen()?setTimeout(()=>{this.#e.nativeElement.showPopover(),this.calculateTooltipPosition()}):this.#e.nativeElement.hidePopover()}),this.calculateTooltipPosition=()=>{if(!this.anchorEl())return;let e=this.anchorEl().nativeElement.getBoundingClientRect(),t=this.#e.nativeElement,n=t.getBoundingClientRect();if(n.width===0&&n.height===0)return;let s=e.top-n.height<0;if(this.isBelow.set(s),!this.SUPPORTS_ANCHOR){let r=t.getBoundingClientRect(),a=e.top-r.height,l=e.left+e.width/2-r.width/2;s&&(a=e.top+e.height),l+r.width>window?.innerWidth&&(l=e.right-r.width/2),l<0&&(l=-(r.width/2)),this.#i.setStyle(t,"left",`${l}px`),this.#i.setStyle(t,"top",`${a}px`),this.#i.setStyle(t,"position","fixed")}}}#e;#i;#t;ngAfterViewInit(){this.#t=new AbortController;let e={signal:this.#t.signal,capture:!0};window?.addEventListener("scroll",this.calculateTooltipPosition,e),window?.addEventListener("resize",this.calculateTooltipPosition,{signal:this.#t.signal}),setTimeout(()=>this.calculateTooltipPosition())}ngOnDestroy(){this.#t?.abort()}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275cmp=O({type:i,selectors:[["ship-tooltip-wrapper"]],hostAttrs:["role","tooltip"],hostVars:5,hostBindings:function(t,n){t&2&&(ge("popover","manual"),G("position-anchor",n.positionAnchorName()),N("below",n.isBelow()))},inputs:{positionAnchorName:[1,"positionAnchorName"],anchorEl:[1,"anchorEl"],isOpen:[1,"isOpen"]},ngContentSelectors:Y,decls:2,vars:0,consts:[[1,"tooltip-content"]],template:function(t,n){t&1&&(T(),A(0,"div",0),u(1),F())},encapsulation:2})}}return i})(),q=null,_a=(()=>{class i{constructor(){this.shTooltip=m.required(),this.#e=y(I),this.#i=y(li),this.#t=y(oi),this.#n=y(de),this.#o=null,this.DEBOUNCE_DELAY=500,this.anchorName=`--${Dt()}`,this.isOpen=v(!1)}#e;#i;#t;#n;#o;onMouseEnter(){q?.component.anchorName!==this.anchorName&&this.cleanupTooltip(),this.cancelCleanupTimer(),queueMicrotask(()=>this.showTooltip())}onMouseLeave(){this.startCleanupTimer()}ngOnDestroy(){this.cancelCleanupTimer(),this.cleanupTooltip()}startCleanupTimer(){this.cancelCleanupTimer(),this.debounceTimer=setTimeout(()=>{this.cleanupTooltip()},this.DEBOUNCE_DELAY)}cancelCleanupTimer(){this.debounceTimer&&(clearTimeout(this.debounceTimer),this.debounceTimer=null)}showTooltip(){if(q?.wrapperComponentRef||!this.shTooltip())return;let e,t=this.shTooltip();if(typeof t=="string")e=[[this.#n.createText(t)]];else if(t instanceof it)this.#o=t.createEmbeddedView({}),this.#o.detectChanges(),e=[this.#o.rootNodes];else return;q={wrapperComponentRef:this.#i.createComponent(or,{environmentInjector:this.#t,projectableNodes:e}),component:this},q.wrapperComponentRef.setInput("positionAnchorName",this.anchorName),q.wrapperComponentRef.setInput("anchorEl",this.#e),q.wrapperComponentRef?.setInput("isOpen",this.isOpen),q.wrapperComponentRef.changeDetectorRef.detectChanges(),q.wrapperComponentRef.location.nativeElement.addEventListener("mouseenter",()=>{this.cancelCleanupTimer()}),q.wrapperComponentRef.location.nativeElement.addEventListener("mouseleave",()=>{this.startCleanupTimer()}),setTimeout(()=>{this.isOpen.set(!0)})}cleanupTooltip(){q?.wrapperComponentRef&&(q.component.cancelCleanupTimer(),q.wrapperComponentRef.destroy(),q.component.isOpen.set(!1),q=null),this.#o&&(this.#o.destroy(),this.#o=null)}static{this.\u0275fac=function(t){return new(t||i)}}static{this.\u0275dir=R({type:i,selectors:[["","shTooltip",""]],hostAttrs:[1,"tooltip"],hostVars:4,hostBindings:function(t,n){t&1&&E("mouseenter",function(){return n.onMouseEnter()})("mouseleave",function(){return n.onMouseLeave()}),t&2&&(G("anchor-name",n.anchorName),N("active",n.isOpen()))},inputs:{shTooltip:[1,"shTooltip"]}})}}return i})();export{ve as a,Qi as b,Mi as c,gi as d,Dr as e,Sr as f,Dn as g,Qe as h,_t as i,Mr as j,wn as k,Vn as l,Nn as m,In as n,ji as o,Rn as p,Bn as q,Er as r,wr as s,xr as t,_e as u,yt as v,Kr as w,Jr as x,Us as y,ea as z,ta as A,ia as B,na as C,zs as D,$s as E,oa as F,Qs as G,Zt as H,sa as I,ra as J,aa as K,er as L,la as M,ca as N,tr as O,da as P,ua as Q,ha as R,pa as S,nr as T,fa as U,ga as V,ma as W,va as X,_a as Y};
|
package/chunk-W3YBKYPJ.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as ae}from"./chunk-ZHGDQABC.js";import"./chunk-MMEFBZO4.js";import{a as se}from"./chunk-Q74O3CWJ.js";import{a as Z,b as k}from"./chunk-BFTGDQ4K.js";import{a as ie}from"./chunk-QHBOEY2O.js";import"./chunk-NK5WD6WE.js";import"./chunk-B62TPRVG.js";import"./chunk-6Q6SSTBK.js";import{a as te}from"./chunk-SZUNW4JO.js";import"./chunk-HSHF5HR7.js";import"./chunk-5LBG6MOL.js";import{b as ne}from"./chunk-ZU6T3TW3.js";import"./chunk-HUZXJWCG.js";import"./chunk-7TWUW4XJ.js";import{B as Q,C as X,L as Y,u as J,z as K}from"./chunk-UNMDSCAN.js";import{c as ee}from"./chunk-CFNARBNK.js";import"./chunk-I27PVH6D.js";import"./chunk-5VE6P5U5.js";import"./chunk-PO3L6MKW.js";import{R as $,S as H,fa as U,ka as q,oa as G}from"./chunk-7AVOHYTE.js";import"./chunk-KDSMLI73.js";import{$ as B,Ab as i,Bb as T,Cc as p,Dc as u,Ec as F,Fb as j,Gb as L,Ib as W,Mc as I,Pa as r,R as A,Vb as b,W as g,Xb as _,aa as z,cb as V,hb as f,jc as a,kc as m,la as M,lc as v,mc as y,na as N,yb as d,zb as s}from"./chunk-26Z7TPJB.js";import"./chunk-7CGTOI24.js";var E=class o{#e=g(k);#i=g(ne);#n=M([]);recentFiles=this.#n.asReadonly();#r=5;#o=1e4;#l=M(null);etaData=this.#l.asReadonly();#s=null;#t=null;#a=null;constructor(){N(()=>{let e=this.#e.statusData();e&&e.CurrentFilename&&e.CurrentFilesize!==void 0&&this.#c(e.CurrentFilename,e.CurrentFilesize)},{allowSignalWrites:!0})}#c(e,n){let t=new Date;this.#n.update(l=>{let c=l.filter(C=>t.getTime()-C.timestamp.getTime()<this.#o);return c.length>0&&c[0].filename===e?c:[{filename:e,filesize:n,timestamp:t},...c].slice(0,this.#r)})}activateView(){this.#s=new Date;let e=this.#e.statusData();e&&e.ProcessedFileCount!==void 0&&e.ProcessedFileSize!==void 0&&(this.#t={files:e.ProcessedFileCount,bytes:e.ProcessedFileSize}),this.#a=setInterval(()=>{this.#d(),this.#p()},1e3)}deactivateView(){this.#s=null,this.#t=null,this.#a&&(clearInterval(this.#a),this.#a=null)}#p(){let e=new Date;this.#n.update(n=>n.filter(t=>e.getTime()-t.timestamp.getTime()<this.#o))}#d(){if(!this.#s||!this.#t)return;let e=this.#e.statusData();if(!e)return;let n=new Date,t=(n.getTime()-this.#s.getTime())/1e3;if(t<5)return;let l=e.ProcessedFileCount||0,c=e.ProcessedFileSize||0,O=l-this.#t.files,C=c-this.#t.bytes,P=O/t,x=C/t,re=(e.TotalFileCount||0)-l,oe=(e.TotalFileSize||0)-c,h=null,S=null;P>0&&(h=re/P),x>0&&(S=oe/x);let D=null,w="bytes";if(h!==null&&S!==null){let le=Math.max(h,S);D=new Date(n.getTime()+le*1e3),w=h>S?"files":"bytes"}else h!==null?(D=new Date(n.getTime()+h*1e3),w="files"):S!==null&&(D=new Date(n.getTime()+S*1e3),w="bytes");this.#l.set({startTime:this.#s,filesProcessedAtStart:this.#t.files,bytesProcessedAtStart:this.#t.bytes,currentFilesPerSecond:P,currentBytesPerSecond:x,estimatedCompletion:D,metric:w})}static \u0275fac=function(n){return new(n||o)};static \u0275prov=A({token:o,factory:o.\u0275fac,providedIn:"root"})};function pe(o,e){if(o&1&&(s(0,"div",25)(1,"div",26),a(2),i(),s(3,"div",27),a(4),p(5,"bytes"),i()()),o&2){let n,t,l=_();r(2),m((n=l.statusData())==null?null:n.CurrentFilename),r(2),m(u(5,2,(t=l.statusData())==null?null:t.CurrentFilesize))}}function de(o,e){if(o&1&&(s(0,"div",28)(1,"span",26),a(2),i(),s(3,"span",27),a(4),p(5,"bytes"),i()()),o&2){let n=e.$implicit;r(2),m(n.filename),r(2),m(u(5,2,n.filesize))}}function me(o,e){if(o&1&&(s(0,"div",29)(1,"div",30),a(2),p(3,"date"),p(4,"relativeTime"),i(),s(5,"div",31)(6,"div"),a(7),p(8,"number"),i(),s(9,"div"),a(10),p(11,"bytes"),i()()()),o&2){let n,t,l,c=_();r(2),y(" ETA: ",F(3,4,(n=c.etaData())==null?null:n.estimatedCompletion,"mediumTime")," (",u(4,7,(n=c.etaData())==null?null:n.estimatedCompletion),") "),r(5),v("",F(8,9,(t=c.etaData())==null?null:t.currentFilesPerSecond,"1.1-1")," files/s"),r(3),v("",u(11,12,(l=c.etaData())==null?null:l.currentBytesPerSecond),"/s")}}function ue(o,e){if(o&1&&(s(0,"div",34)(1,"div",35)(2,"span",36),a(3),i(),s(4,"span",37),a(5),p(6,"bytes"),i()(),T(7,"sh-progress-bar",2),i()),o&2){let n=e.$implicit;r(3),m(n.BackendPath),r(2),v("",u(6,3,n.BackendSpeed),"/s"),r(2),d("value",(n.BackendFileProgress||0)/(n.BackendFileSize||1)*100)}}function ge(o,e){if(o&1&&(s(0,"div",32),f(1,ue,8,5,"div",33),i()),o&2){let n,t=_();r(),d("ngForOf",(n=t.statusData())==null?null:n.ActiveTransfers)}}function fe(o,e){if(o&1&&(s(0,"div",21)(1,"span",5),a(2,"Next Task:"),i(),s(3,"div",6)(4,"div"),a(5),i(),s(6,"div",38),a(7),p(8,"date"),p(9,"relativeTime"),i()()()),o&2){let n,t=_();r(5),m((n=t.nextBackup().backup)==null?null:n.Name),r(2),y(" ",F(8,3,t.nextBackup().time,"medium")," (",u(9,6,t.nextBackup().time),") ")}}function _e(o,e){if(o&1){let n=W();j(0),s(1,"button",39),b("click",function(){B(n);let l=_();return z(l.stop())}),s(2,"sh-icon"),a(3,"stop"),i(),a(4," Stop "),i(),s(5,"button",39),b("click",function(){B(n);let l=_();return z(l.abort())}),s(6,"sh-icon"),a(7,"x-circle"),i(),a(8," Abort "),i(),L()}}var R=class o{#e=g(k);#i=g(E);#n=g(ee);#r=g(K);statusData=this.#e.statusData;serverState=this.#e.serverState;recentFiles=this.#i.recentFiles;etaData=this.#i.etaData;transfersExpanded=M(!1);clientIsRunning=this.#e.clientIsRunning;statusText=I(()=>{let e=this.statusData()?.Phase;return e?Z[e]||e:""});progress=I(()=>{let e=this.statusData();return e?(e.OverallProgress||0)*100:0});nextBackup=I(()=>({backup:this.serverState()?.ProposedSchedule?.[0]?.backup,time:this.serverState()?.ProposedSchedule?.[0]?.Item2}));ngOnInit(){this.#i.activateView()}ngOnDestroy(){this.#i.deactivateView()}toggleTransfers(){this.transfersExpanded.update(e=>!e)}isTaskRunning(){return!!this.statusData()?.TaskID}taskStartTime(){return this.etaData()?.startTime}currentBackupId(){return this.statusData()?.BackupID}pauseResume(){if(this.clientIsRunning()){this.#r.open(se,{maxWidth:"550px",width:"100%"});return}this.#e.pauseResume().subscribe()}stop(){let e=this.statusData()?.TaskID;e&&this.#n.postApiV1TaskByTaskidStop({taskid:e}).subscribe()}abort(){let e=this.statusData()?.TaskID;e&&this.#n.postApiV1TaskByTaskidAbort({taskid:e}).subscribe()}static \u0275fac=function(n){return new(n||o)};static \u0275cmp=V({type:o,selectors:[["app-status"]],decls:62,vars:27,consts:[[1,"status-page"],[1,"progress-section"],[3,"value"],[1,"stats-grid"],[1,"stat-item"],[1,"label"],[1,"value"],[1,"files-section"],["class","current-file",4,"ngIf"],[1,"recent-files"],["class","recent-file",4,"ngFor","ngForOf"],[1,"speed-section"],[1,"speed-header"],[1,"aggregate-speed"],["class","eta-info",4,"ngIf"],[1,"transfers-toggle"],["shButton","",3,"click"],["class","transfer-details",4,"ngIf"],[1,"logs-section"],[3,"asSimpleList","polling","whenFilter","backupIdFilter"],[1,"server-status-section"],[1,"status-row"],["class","status-row",4,"ngIf"],[1,"actions"],[4,"ngIf"],[1,"current-file"],[1,"filename"],[1,"filesize"],[1,"recent-file"],[1,"eta-info"],[1,"eta-time"],[1,"speed-metrics"],[1,"transfer-details"],["class","transfer-item",4,"ngFor","ngForOf"],[1,"transfer-item"],[1,"transfer-info"],[1,"path"],[1,"speed"],[1,"sub-text"],["shButton","","color","warn",3,"click"]],template:function(n,t){if(n&1&&(s(0,"div",0)(1,"sh-card")(2,"div",1)(3,"h2"),a(4),i(),T(5,"sh-progress-bar",2),s(6,"div",3)(7,"div",4)(8,"span",5),a(9,"Files"),i(),s(10,"span",6),a(11),i()(),s(12,"div",4)(13,"span",5),a(14,"Size"),i(),s(15,"span",6),a(16),p(17,"bytes"),p(18,"bytes"),i()()()()(),s(19,"sh-card")(20,"div",7)(21,"h3"),a(22,"Current File"),i(),f(23,pe,6,4,"div",8),s(24,"h3"),a(25,"Recent Files"),i(),s(26,"div",9),f(27,de,6,4,"div",10),i()()(),s(28,"sh-card")(29,"div",11)(30,"div",12)(31,"h3"),a(32,"Transfer Speed"),i(),s(33,"div",13),a(34),p(35,"bytes"),i()(),f(36,me,12,14,"div",14),s(37,"div",15)(38,"button",16),b("click",function(){return t.toggleTransfers()}),a(39),i()(),f(40,ge,2,1,"div",17),i()(),s(41,"sh-card")(42,"div",18)(43,"h3"),a(44,"Live Logs"),i(),T(45,"app-logs-live",19),i()(),s(46,"sh-card")(47,"div",20)(48,"h3"),a(49,"Server Status"),i(),s(50,"div",21)(51,"span",5),a(52,"State:"),i(),s(53,"span",6),a(54),i()(),f(55,fe,10,8,"div",22),s(56,"div",23)(57,"button",16),b("click",function(){return t.pauseResume()}),s(58,"sh-icon"),a(59),i(),a(60),i(),f(61,_e,9,0,"ng-container",24),i()()()()),n&2){let l,c,O,C,P,x;r(4),m(t.statusText()),r(),d("value",t.progress()),r(6),y("",(l=t.statusData())==null?null:l.ProcessedFileCount," / ",(l=t.statusData())==null?null:l.TotalFileCount),r(5),y(" ",u(17,21,(c=t.statusData())==null?null:c.ProcessedFileSize)," / ",u(18,23,(c=t.statusData())==null?null:c.TotalFileSize)," "),r(7),d("ngIf",(O=t.statusData())==null?null:O.CurrentFilename),r(4),d("ngForOf",t.recentFiles()),r(7),v("",u(35,25,(C=t.statusData())==null?null:C.BackendSpeed),"/s"),r(2),d("ngIf",t.etaData()),r(3),v(" ",t.transfersExpanded()?"Hide Details":"Show Details"," "),r(),d("ngIf",t.transfersExpanded()),r(5),d("asSimpleList",!0)("polling",t.isTaskRunning())("whenFilter",(P=t.taskStartTime())==null?null:P.getTime())("backupIdFilter",t.currentBackupId()),r(9),m((x=t.serverState())==null?null:x.ProgramState),r(),d("ngIf",t.nextBackup()),r(4),m(t.clientIsRunning()?"pause":"play_arrow"),r(),v(" ",t.clientIsRunning()?"Pause":"Resume"," "),r(),d("ngIf",t.isTaskRunning())}},dependencies:[G,$,H,X,Y,Q,J,ae,q,U,te,ie],styles:["[_nghost-%COMP%]{display:block;padding:20px;max-width:1200px;margin:0 auto}.status-page[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr;gap:20px}@media(min-width:768px){.status-page[_ngcontent-%COMP%]{grid-template-columns:repeat(2,1fr)}}@media(min-width:1024px){.status-page[_ngcontent-%COMP%]{grid-template-columns:repeat(3,1fr)}}sh-card[_ngcontent-%COMP%]{height:100%;display:flex;flex-direction:column}.progress-section[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin-top:0;margin-bottom:15px;font-size:1.2rem;color:var(--text-primary)}.progress-section[_ngcontent-%COMP%] sh-progress-bar[_ngcontent-%COMP%]{margin-bottom:15px;height:20px;--progress-bar-color: var(--primary-color)}.progress-section[_ngcontent-%COMP%] .stats-grid[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:10px}.progress-section[_ngcontent-%COMP%] .stats-grid[_ngcontent-%COMP%] .stat-item[_ngcontent-%COMP%]{display:flex;flex-direction:column}.progress-section[_ngcontent-%COMP%] .stats-grid[_ngcontent-%COMP%] .stat-item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{font-size:.8rem;color:var(--text-secondary)}.progress-section[_ngcontent-%COMP%] .stats-grid[_ngcontent-%COMP%] .stat-item[_ngcontent-%COMP%] .value[_ngcontent-%COMP%]{font-weight:500}.files-section[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{margin-top:0;margin-bottom:10px;font-size:1rem;color:var(--text-secondary)}.files-section[_ngcontent-%COMP%] .current-file[_ngcontent-%COMP%]{margin-bottom:20px;padding:10px;background:var(--bg-secondary);border-radius:4px}.files-section[_ngcontent-%COMP%] .current-file[_ngcontent-%COMP%] .filename[_ngcontent-%COMP%]{font-weight:500;word-break:break-all;margin-bottom:5px}.files-section[_ngcontent-%COMP%] .current-file[_ngcontent-%COMP%] .filesize[_ngcontent-%COMP%]{font-size:.8rem;color:var(--text-secondary)}.files-section[_ngcontent-%COMP%] .recent-files[_ngcontent-%COMP%] .recent-file[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding:5px 0;border-bottom:1px solid var(--border-color);font-size:.9rem}.files-section[_ngcontent-%COMP%] .recent-files[_ngcontent-%COMP%] .recent-file[_ngcontent-%COMP%]:last-child{border-bottom:none}.files-section[_ngcontent-%COMP%] .recent-files[_ngcontent-%COMP%] .recent-file[_ngcontent-%COMP%] .filename[_ngcontent-%COMP%]{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-right:10px}.files-section[_ngcontent-%COMP%] .recent-files[_ngcontent-%COMP%] .recent-file[_ngcontent-%COMP%] .filesize[_ngcontent-%COMP%]{color:var(--text-secondary);white-space:nowrap}.speed-section[_ngcontent-%COMP%] .speed-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;margin-bottom:15px}.speed-section[_ngcontent-%COMP%] .speed-header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{margin:0;font-size:1rem;color:var(--text-secondary)}.speed-section[_ngcontent-%COMP%] .speed-header[_ngcontent-%COMP%] .aggregate-speed[_ngcontent-%COMP%]{font-size:1.2rem;font-weight:700;color:var(--primary-color)}.speed-section[_ngcontent-%COMP%] .eta-info[_ngcontent-%COMP%]{margin-bottom:15px;padding:10px;background:var(--bg-secondary);border-radius:4px}.speed-section[_ngcontent-%COMP%] .eta-info[_ngcontent-%COMP%] .eta-time[_ngcontent-%COMP%]{font-weight:500;margin-bottom:5px}.speed-section[_ngcontent-%COMP%] .eta-info[_ngcontent-%COMP%] .speed-metrics[_ngcontent-%COMP%]{display:flex;justify-content:space-between;font-size:.8rem;color:var(--text-secondary)}.speed-section[_ngcontent-%COMP%] .transfers-toggle[_ngcontent-%COMP%]{margin-bottom:10px;text-align:right}.speed-section[_ngcontent-%COMP%] .transfer-details[_ngcontent-%COMP%]{max-height:200px;overflow-y:auto}.speed-section[_ngcontent-%COMP%] .transfer-details[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%]{margin-bottom:10px}.speed-section[_ngcontent-%COMP%] .transfer-details[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%] .transfer-info[_ngcontent-%COMP%]{display:flex;justify-content:space-between;font-size:.8rem;margin-bottom:2px}.speed-section[_ngcontent-%COMP%] .transfer-details[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%] .transfer-info[_ngcontent-%COMP%] .path[_ngcontent-%COMP%]{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-right:10px}.speed-section[_ngcontent-%COMP%] .transfer-details[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%] sh-progress-bar[_ngcontent-%COMP%]{height:4px}.logs-section[_ngcontent-%COMP%]{grid-column:1/-1}.logs-section[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{margin-top:0;margin-bottom:10px;font-size:1rem;color:var(--text-secondary)}.logs-section[_ngcontent-%COMP%] app-logs-live[_ngcontent-%COMP%]{height:300px;display:block;border:1px solid var(--border-color);border-radius:4px}.server-status-section[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{margin-top:0;margin-bottom:15px;font-size:1rem;color:var(--text-secondary)}.server-status-section[_ngcontent-%COMP%] .status-row[_ngcontent-%COMP%]{display:flex;margin-bottom:10px}.server-status-section[_ngcontent-%COMP%] .status-row[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{width:100px;color:var(--text-secondary)}.server-status-section[_ngcontent-%COMP%] .status-row[_ngcontent-%COMP%] .value[_ngcontent-%COMP%]{flex:1;font-weight:500}.server-status-section[_ngcontent-%COMP%] .status-row[_ngcontent-%COMP%] .value[_ngcontent-%COMP%] .sub-text[_ngcontent-%COMP%]{font-size:.8rem;color:var(--text-secondary)}.server-status-section[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{margin-top:20px;display:flex;gap:10px;flex-wrap:wrap}"],changeDetection:0})};export{R as default};
|
package/chunk-XIYAYCFU.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a}from"./chunk-QHBOEY2O.js";import"./chunk-NK5WD6WE.js";import"./chunk-7AVOHYTE.js";import"./chunk-KDSMLI73.js";import"./chunk-26Z7TPJB.js";import"./chunk-7CGTOI24.js";export{a as RelativeTimePipe};
|
package/chunk-XLMLR5EV.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as $}from"./chunk-EE27B3OV.js";import"./chunk-Q74O3CWJ.js";import"./chunk-BFTGDQ4K.js";import"./chunk-QHBOEY2O.js";import"./chunk-NK5WD6WE.js";import"./chunk-B62TPRVG.js";import"./chunk-6Q6SSTBK.js";import"./chunk-SZUNW4JO.js";import"./chunk-TL4WOQKT.js";import"./chunk-7LTHH6OG.js";import"./chunk-HSHF5HR7.js";import"./chunk-5LBG6MOL.js";import"./chunk-D6IP567E.js";import{b as f}from"./chunk-VDSX2M4H.js";import"./chunk-ZU6T3TW3.js";import"./chunk-HUZXJWCG.js";import"./chunk-7TWUW4XJ.js";import{B as b,u as h}from"./chunk-UNMDSCAN.js";import{c as P}from"./chunk-CFNARBNK.js";import{b as B,e as A}from"./chunk-I27PVH6D.js";import"./chunk-5VE6P5U5.js";import"./chunk-PO3L6MKW.js";import"./chunk-7AVOHYTE.js";import"./chunk-KDSMLI73.js";import{Ab as F,Bb as _,Mc as D,Pa as i,Pb as c,Qb as d,Rb as r,Ub as N,Vb as L,W as C,cb as S,jc as M,la as l,lc as O,sb as s,tb as u,ub as T,wb as p,xb as I,yb as E,yc as R,zb as a}from"./chunk-26Z7TPJB.js";import"./chunk-7CGTOI24.js";var k=e=>({state:e});function v(e,t){e&1&&r(0,2,1)}function y(e,t){e&1&&r(0,2,2)}function U(e,t){e&1&&r(0,2,3)}function G(e,t){e&1&&r(0,2,4)}function K(e,t){if(e&1&&(M(0),_(1,"br")),e&2){let o=t.$implicit;O(" ",o," ")}}var g=class e{#t=C(P);#e=C(B);#n=f(this.#e.params);#o=f(this.#e.queryParams);runId=D(()=>this.#n()?.runId);stateId=D(()=>this.#o()?.state);offset=l(0);status=l("starting");messageLog=l([]);interval=setInterval(()=>{this.#t.getApiV1CommandlineByRunid({runid:this.runId(),offset:this.offset(),pagesize:100}).subscribe(t=>{this.offset.set(t.Count),this.evalStatus(t),this.messageLog.update(o=>[...o,...t.Items])})},1e3);evalStatus(t){t.Started===!0&&t.Finished===!0&&(this.status.set("finished"),clearInterval(this.interval)),t.Started===!0&&t.Finished===!1&&this.status.set("started")}abort(){this.#t.postApiV1CommandlineByRunidAbort({runid:this.runId()}).subscribe({next:t=>{this.status.set("aborted"),clearInterval(this.interval)}})}static \u0275fac=function(o){return new(o||e)};static \u0275cmp=S({type:e,selectors:[["app-commandline-result"]],decls:18,vars:7,consts:()=>{let t;t=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON: Back `;let o;o=$localize` Running commandline task... ${"\uFFFD#8\uFFFD"}:START_TAG_BUTTON:Abort${"\uFFFD/#8\uFFFD"}:CLOSE_TAG_BUTTON:`;let n;return n=$localize`${"\uFFFD*11:1\uFFFD"}:START_BLOCK_IF: Starting... ${"[\uFFFD/*11:1\uFFFD|\uFFFD/*12:2\uFFFD|\uFFFD/*13:3\uFFFD|\uFFFD/*14:4\uFFFD]"}:CLOSE_BLOCK_IF:${"\uFFFD*12:2\uFFFD"}:START_BLOCK_IF_1: Started! ${"[\uFFFD/*11:1\uFFFD|\uFFFD/*12:2\uFFFD|\uFFFD/*13:3\uFFFD|\uFFFD/*14:4\uFFFD]"}:CLOSE_BLOCK_IF:${"\uFFFD*13:3\uFFFD"}:START_BLOCK_IF_2: Finished! ${"[\uFFFD/*11:1\uFFFD|\uFFFD/*12:2\uFFFD|\uFFFD/*13:3\uFFFD|\uFFFD/*14:4\uFFFD]"}:CLOSE_BLOCK_IF:${"\uFFFD*14:4\uFFFD"}:START_BLOCK_IF_3: Aborted! ${"[\uFFFD/*11:1\uFFFD|\uFFFD/*12:2\uFFFD|\uFFFD/*13:3\uFFFD|\uFFFD/*14:4\uFFFD]"}:CLOSE_BLOCK_IF:`,n=N(n),[t,o,n,[1,"back"],["type","button","shButton","","routerLink","../",1,"small",3,"queryParams"],["type","button","shButton","",1,"small",3,"click"],[1,"status"]]},template:function(o,n){o&1&&(_(0,"app-status-bar"),a(1,"section")(2,"div",3)(3,"button",4),c(4,0),_(5,"sh-icon"),d(),F()(),a(6,"h3"),c(7,1),a(8,"button",5),L("click",function(){return n.abort()}),F(),d(),F(),a(9,"div",6),c(10,2),s(11,v,1,0),s(12,y,1,0),s(13,U,1,0),s(14,G,1,0),d(),F(),a(15,"code"),p(16,K,2,1,null,null,T),F()()),o&2&&(i(3),E("queryParams",R(5,k,n.stateId())),i(8),u(n.status()==="starting"?11:-1),i(),u(n.status()==="started"?12:-1),i(),u(n.status()==="finished"?13:-1),i(),u(n.status()==="aborted"?14:-1),i(2),I(n.messageLog()))},dependencies:[$,h,b,A],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;width:100%;padding:2.5rem;gap:1.25rem}code[_ngcontent-%COMP%]{background:color-mix(in srgb,var(--base-8),#000 70%);color:#fff;padding:2.5rem 2.5rem 2.5rem 1.5rem;border-radius:var(--shape-3);overflow:auto;white-space:pre}"],changeDetection:0})};export{g as default};
|
package/chunk-YHMXLWRX.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a}from"./chunk-ZHGDQABC.js";import"./chunk-MMEFBZO4.js";import"./chunk-UNMDSCAN.js";import"./chunk-CFNARBNK.js";import"./chunk-PO3L6MKW.js";import"./chunk-7AVOHYTE.js";import"./chunk-KDSMLI73.js";import"./chunk-26Z7TPJB.js";import"./chunk-7CGTOI24.js";export{a as default};
|
package/chunk-YLQF5ATT.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a}from"./chunk-MLNK7NFW.js";import"./chunk-K34VOGDF.js";import"./chunk-AT64P6E5.js";import"./chunk-HSHF5HR7.js";import"./chunk-HUZXJWCG.js";import"./chunk-UNMDSCAN.js";import"./chunk-CFNARBNK.js";import"./chunk-PO3L6MKW.js";import"./chunk-7AVOHYTE.js";import"./chunk-KDSMLI73.js";import"./chunk-26Z7TPJB.js";import"./chunk-7CGTOI24.js";export{a as OptionsListComponent};
|
package/chunk-ZHGDQABC.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a as V}from"./chunk-MMEFBZO4.js";import{B as A,J as D,T as F,u as k}from"./chunk-UNMDSCAN.js";import{fa as $}from"./chunk-7AVOHYTE.js";import{$ as I,Ab as i,Bb as P,Cc as R,Ec as y,Ib as N,Pa as l,Rb as m,Rc as u,Vb as G,W as O,Xb as d,aa as h,cb as x,fc as w,gc as v,jc as s,kc as L,la as T,lc as _,na as C,sb as g,tb as p,ub as S,wb as f,xb as E,yb as M,zb as o}from"./chunk-26Z7TPJB.js";function B(n,t){n&1&&(o(0,"div",4),m(1,0),i())}function J(n,t){if(n&1&&(o(0,"li"),s(1),i()),n&2){let e=t.$implicit;l(),L(e)}}function U(n,t){if(n&1&&(o(0,"code")(1,"ol",15),f(2,J,2,1,"li",null,S),i()()),n&2){let e=d(2).$implicit,a=d(2);l(2),E(a.breakIntoLines(e.Exception))}}function X(n,t){if(n&1&&(o(0,"li"),s(1),i()),n&2){let e=t.$implicit;l(),L(e)}}function j(n,t){if(n&1&&(o(0,"code")(1,"ol",15),f(2,X,2,1,"li",null,S),i()()),n&2){let e=d(2).$implicit,a=d(2);l(2),E(a.breakIntoLines(e.Message))}}function z(n,t){if(n&1&&(o(0,"tr")(1,"td",12)(2,"sh-list",13)(3,"div",14),s(4),i(),o(5,"div",14),s(6),i(),o(7,"div",14),s(8),i(),o(9,"div",14),s(10),i(),o(11,"div",14),s(12),i()(),g(13,U,4,0,"code"),g(14,j,4,0,"code"),i()()),n&2){let e=d().$implicit;l(4),_("ID: ",e.ID),l(2),_("Type: ",e.Type),l(2),_("Tag: ",e.Tag),l(2),_("TaskID: ",e.TaskID),l(2),_("MessageID: ",e.MessageID),l(),p(e.Exception?13:-1),l(),p(e.Message?14:-1)}}function W(n,t){if(n&1){let e=N();o(0,"tr",10),G("click",function(){let r=I(e).$index,c=d(2);return h(c.toggleRow(r))}),o(1,"td"),s(2),R(3,"date"),i(),o(4,"td"),s(5),i(),o(6,"td",8)(7,"button",11)(8,"sh-icon"),s(9,"caret-down"),i()()()(),g(10,z,15,7,"tr")}if(n&2){let e=t.$implicit,a=t.$index,r=d(2);l(2),L(y(3,5,e.When,"medium")),l(3),L(r.subStringMessage(e.Message)),l(2),v("rotated-icon",a===r.openRowIndex()),l(3),p(a===r.openRowIndex()?10:-1)}}function H(n,t){if(n&1&&(o(0,"sh-table",6)(1,"tr",7)(2,"th"),m(3,1),i(),o(4,"th"),m(5,2),i(),P(6,"th",8),i(),f(7,W,11,8,null,null,S),o(9,"div",9),m(10,3),i()()),n&2){let e=d();w("grid-template-columns","auto 1fr auto"),v("type-b",e.asSimpleList()),M("data",e.logs())("loading",e.logsLoading()),l(7),E(e.logs())}}var b=class n{#e=O(V);whenFilter=u();backupIdFilter=u();asSimpleList=u();polling=u();logLevel=this.#e.logLevel;logLevelByLabel=this.#e.logLevelByLabel;logs=this.#e.logs;logsLoading=this.#e.logsLoading;pollingEffect=C(()=>{let t=this.polling()??!1;this.#e.isPolling.set(t)});openRowIndex=T(null);whenEffect=C(()=>{let t=this.whenFilter()??null;this.#e.setWhenFilter(t),this.#e.logLevel.set(t?"Verbose":"Disabled")});backupIdEffect=C(()=>{let t=this.backupIdFilter()??null;this.#e.setBackupIdFilter(t),this.#e.logLevel.set(t?"Verbose":"Disabled")});toggleRow(t){this.openRowIndex.set(t===this.openRowIndex()?null:t)}breakIntoLines(t){return t?t.split(`
|
|
2
|
-
`):[]}subStringMessage(t){return t?t.substring(0,80)+"...":""}ngOnDestroy(){this.#e.destroy()}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=x({type:n,selectors:[["app-logs-live"]],hostVars:2,hostBindings:function(e,a){e&2&&v("simple-list",a.asSimpleList())},inputs:{whenFilter:[1,"whenFilter"],backupIdFilter:[1,"backupIdFilter"],asSimpleList:[1,"asSimpleList"],polling:[1,"polling"]},decls:2,vars:1,consts:()=>{let t;t=$localize`Live logs are disabled`;let e;e=$localize`When`;let a;a=$localize`Message`;let r;return r=$localize`No data available`,[t,e,a,r,[1,"live-view-disabled"],[3,"type-b","data","loading","grid-template-columns"],[3,"data","loading"],["thead",""],[1,"sticky-end"],["table-no-rows",""],[3,"click"],["shButton","","type","button",1,"outlined","small"],[1,"expanded-cell"],[1,"primary"],["item",""],[1,"line-numbers-ol"]]},template:function(e,a){e&1&&g(0,B,2,0,"div",4)(1,H,11,6,"sh-table",5),e&2&&p(a.logLevel()==="Disabled"?0:1)},dependencies:[F,k,D,A,$],styles:["[_nghost-%COMP%]{display:block;padding:0 2rem}.simple-list[_nghost-%COMP%] sh-table[_ngcontent-%COMP%]{--table-td-bg: var(--base-2);height:100%}.live-view-disabled[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;min-height:18.75rem;width:100%;background-color:var(--base-2);border:1px solid var(--base-3);border-radius:var(--shape-2);font:var(--paragraph-20)}.expanded-cell[_ngcontent-%COMP%]{height:auto;grid-column:1/-1;white-space:pre-wrap;display:flex;flex-direction:column}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0 0 1.25rem}sh-table[_ngcontent-%COMP%]{--table-columns: auto auto 1fr auto}sh-table[_ngcontent-%COMP%] td.id[_ngcontent-%COMP%]{justify-content:center}sh-table[_ngcontent-%COMP%] td[_ngcontent-%COMP%]:has(code){padding:1rem .75rem;overflow:hidden}sh-table[_ngcontent-%COMP%] td[_ngcontent-%COMP%]:has(code) code[_ngcontent-%COMP%]{background:color-mix(in srgb,var(--base-8),#000 70%);color:#fff;padding:2.5rem 2.5rem 2.5rem 1.5rem;border-radius:var(--shape-3);overflow:auto;white-space:pre;max-width:100%}"],changeDetection:0})};export{b as a};
|
package/main-HMCIC27B.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as ke,c as Ae}from"./chunk-AODNZLCK.js";import{a as Te}from"./chunk-GRVTXORM.js";import{a as Ie}from"./chunk-MDXSNEQZ.js";import{b as k}from"./chunk-BFTGDQ4K.js";import{a as Me}from"./chunk-QHBOEY2O.js";import{b as Ee}from"./chunk-NK5WD6WE.js";import"./chunk-B62TPRVG.js";import{a as D}from"./chunk-6Q6SSTBK.js";import{a as Re}from"./chunk-SZUNW4JO.js";import"./chunk-HSHF5HR7.js";import"./chunk-5LBG6MOL.js";import"./chunk-ZU6T3TW3.js";import{a as H}from"./chunk-HUZXJWCG.js";import{a as h,b as be,c as v,d as we,e as I}from"./chunk-7TWUW4XJ.js";import{v as Ce,x as ve}from"./chunk-UNMDSCAN.js";import{a as ye,d as Se}from"./chunk-CFNARBNK.js";import{c as me,d as de,g as ue,h as he,i as fe,j as ge}from"./chunk-I27PVH6D.js";import{a as re}from"./chunk-5VE6P5U5.js";import{a as se,b as ie,c as ae,e as pe,f as le,g as ce}from"./chunk-PO3L6MKW.js";import{fa as oe,ka as ne}from"./chunk-7AVOHYTE.js";import"./chunk-KDSMLI73.js";import{Bb as Z,E as M,I as K,Ic as ee,Jc as te,K as T,M as _,R as C,U as q,W as s,cb as Y,da as z,ea as X,f as W,g as $,l as G,la as d,m as B,na as Q,p as w,y as P,z as J}from"./chunk-26Z7TPJB.js";import"./chunk-7CGTOI24.js";var A=class e{#e=s(h);#a=s(v);ngOnInit(){be(),this.#a.fetchConfig(),this.#e.clearAllNotCurrentVersion()}static \u0275fac=function(o){return new(o||e)};static \u0275cmp=Y({type:e,selectors:[["app-root"]],decls:1,vars:0,template:function(o,n){o&1&&Z(0,"router-outlet")},dependencies:[me],encapsulation:2})};var Ne={production:!0,baseUrl:"/api",machineServerUrl:"${WS_URL}",defaultTimeout:3e4};var f=new q("ENVIRONMENT");var N=class e{#e=s(Se);isLoaded=d(!1);webmodules=d(null);preload(t=!1){let o=this.#e.getApiV1Webmodules().pipe(_(n=>this.webmodules.set(n)),M(()=>this.isLoaded.set(!0)));if(t)return o;o.subscribe()}static \u0275fac=function(o){return new(o||e)};static \u0275prov=C({token:e,factory:e.\u0275fac,providedIn:"root"})};var Fe=()=>{let e=s(I);return e.token()?!0:e.checkProxyAuthed().pipe(T(t=>t?G(!0):e.refreshToken().pipe(w(()=>!0))))},We=()=>{let e=s(v),t=s(k),o=s(z),n=e.relayIsEnabled()?"longpoll":"websocket",a=[o.get(H).preload(!0),o.get(H).preloadFilterGroups(!0),o.get(N).preload(!0)];return e.configLoaded===null?P(a).pipe(w(()=>n)):e.configLoaded?.pipe(T(()=>P(a)))},$e=()=>!0,Oe={path:"connect/:typeParam",loadComponent:()=>import("./chunk-NNNKIEPR.js")},Ge=()=>{let e=s(h);return!e.getItem("locale")&&navigator.language&&e.setItem("locale",navigator.language),!0},xe=[{path:"",children:[{path:"login",canActivate:[],loadComponent:()=>import("./chunk-HOGZ74SB.js")},{path:"logout",loadComponent:()=>import("./chunk-EE5SIDTF.js")},{path:"",canActivate:[Fe],children:[{path:"",canActivate:[We,$e,Ge],children:[{path:"welcome",loadComponent:()=>import("./chunk-NGNWWP6M.js"),children:[{path:"",redirectTo:"select",pathMatch:"full"},{path:"select",loadComponent:()=>import("./chunk-AIH3GSIT.js")},Oe]},{path:"",loadComponent:()=>import("./chunk-7DCQVM6E.js"),children:[{path:"",loadComponent:()=>import("./chunk-BT2VIZXE.js")},Oe,{path:"add-backup",loadComponent:()=>import("./chunk-3QV6WLWV.js")},{path:"backup/:id/export",loadComponent:()=>import("./chunk-UK7MV4OF.js")},{path:"backup/import",loadComponent:()=>import("./chunk-G2FJM62F.js")},{path:"backup-draft/:id",loadComponent:()=>import("./chunk-M7Y3VPRV.js"),loadChildren:()=>import("./chunk-DESKT7LH.js")},{path:"backup/:id",loadComponent:()=>import("./chunk-M7Y3VPRV.js"),loadChildren:()=>import("./chunk-DESKT7LH.js")},{path:"backup/:id/log",loadComponent:()=>import("./chunk-Q2UQ5J3C.js")},{path:"backup/:id/database",loadComponent:()=>import("./chunk-IGYSPFE7.js")},{path:"backup/:id/commandline",loadComponent:()=>import("./chunk-OPLWAKSM.js")},{path:"backup/:id/commandline/:runId",loadComponent:()=>import("./chunk-XLMLR5EV.js")},{path:"backup/:id/delete",loadComponent:()=>import("./chunk-U2E3ZQUP.js")},{path:"restore",children:[{path:"",loadComponent:()=>import("./chunk-T4BXBCQI.js")},{path:"from-config",loadComponent:()=>import("./chunk-I3IIG2AK.js")}]},{path:"restore-from-files",loadComponent:()=>import("./chunk-LT3AVRVP.js"),loadChildren:()=>import("./chunk-4GXIF5HF.js")},{path:"restore-draft/:id",loadComponent:()=>import("./chunk-LT3AVRVP.js"),loadChildren:()=>import("./chunk-4GXIF5HF.js")},{path:"restore/:id",loadComponent:()=>import("./chunk-LT3AVRVP.js"),loadChildren:()=>import("./chunk-4GXIF5HF.js")},{path:"status",loadComponent:()=>import("./chunk-W3YBKYPJ.js")},{path:"settings",loadComponent:()=>import("./chunk-5MHYH7GK.js")},{path:"about",loadComponent:()=>import("./chunk-C7N24TZM.js"),children:[{path:"",redirectTo:"general",pathMatch:"full"},{path:"general",loadComponent:()=>import("./chunk-I2RQR4CB.js")},{path:"changelog",loadComponent:()=>import("./chunk-BYUBKTO5.js")},{path:"libraries",loadComponent:()=>import("./chunk-R5YJUVWW.js")},{path:"system-info",loadComponent:()=>import("./chunk-3K3BYB36.js")},{path:"server-settings",loadComponent:()=>import("./chunk-T4IKTBRQ.js")},{path:"logs",loadChildren:()=>import("./chunk-26MRZAFB.js")},{path:"crashlogs",loadComponent:()=>import("./chunk-VFBRHP2H.js")}]}]}]}]}]}];var U=null,Le=(e,t)=>{let o=s(I),n=s(de),a=s(h),p=s(f),i=a.getItem("locale"),u=s(ve),l=ke(i),r=ye.BASE||"",m=e.url===`${r}/api/v1/auth/login`,S=e.url===`${r}/api/v1/auth/logout`,g=e.url===`${r}/api/v1/auth/refresh`,b=e.url===`${r}/api/v1/progressstate`,E=e.url===`${r}/api/v1/remoteoperation/test`,Ue=e.url===`${r}/api/v1/filesystem/validate`,je=e.url.startsWith(`${r}/api/v2/`),L=o.token(),j=e,F=e.headers.has("custom-proxy-check")||L===we;if(L&&e.url.startsWith(r+p.baseUrl)&&!F){let c=e.headers.set("Authorization",`Bearer ${L}`);i&&i!=="en-US"&&(c=c.set("X-Ui-Language",l)),j=e.clone({headers:c})}return t(j).pipe(w(c=>{if(c.type===4&&c.status===200&&je){let y=c.body;if(y?.Success===!1)throw{status:200,message:y?.Error??"Unknown error",error:{Error:y?.Error??"Unknown error"},requestBody:y}}return c}),J(c=>{let y=c.error?.Error||`Error Code: ${c.status}, Message: ${c.message}`;if(!F){let R=!0;if((b&&c.status===404||E||Ue)&&(R=!1),g&&c.status===401&&(R=!1,o.logout(),n.navigate(["/logout"])),!m&&!g&&!S&&c.status===401)return R=!1,U??=o.refreshToken().pipe(K()),U.pipe(T(()=>t(e.clone({headers:e.headers.set("Authorization",`Bearer ${o.token()}`)}))),M(()=>U=null));R&&u.error(y)}return B(()=>({error:c,message:y}))}))};var O=class e{#e=s(X);showError(t){let o=this.#e.querySelector("body > .loading");if(!o)return;o.classList.add("has-error"),o.innerHTML="";let n=this.#e.createElement("div");n.classList.add("loading-title"),n.textContent="Unable to connect";let a=this.#e.createElement("div");a.classList.add("loading-error"),a.textContent=t||"Unknown error";let p=this.#e.createElement("button");p.type="button",p.classList.add("retry-button"),p.textContent="Retry",p.addEventListener("click",()=>{this.#e.defaultView?.location.reload()}),o.append(n,a,p)}static \u0275fac=function(o){return new(o||e)};static \u0275prov=C({token:e,factory:e.\u0275fac,providedIn:"root"})};var Be="1.0.0",Pe=`portal-proxy-client-${D()}`,Je=1,x=class e{#e=1e3;#a=s(f);#d=s(O);#o=d("disconnected");#u=d(this.#e);#p=d(!1);#n=d(!1);#l=d(null);#s=!1;isConnectedToMachineServer=this.#n.asReadonly();wsState=this.#o.asReadonly();#c=[];#r={};#t=null;#h=new TextDecoder("utf-8");#m=null;#g=Q(()=>{let t=this.#p(),o=this.#u(),n=this.#l();if(!n||!t||!o||o<this.#e){this.#m&&window.clearInterval(this.#m);return}this.#m=window.setInterval(()=>{this.connectToMachineServer(n)},o)});#i(t){this.#s||(this.#s=!0,this.#d.showError(t||"Unable to connect to the server."))}#f(){this.#s||(this.#s=!0)}utf8Atob(t){let o=Uint8Array.from(atob(t),a=>a.charCodeAt(0)),n=this.#h.decode(o);return n?JSON.parse(n):null}connectToMachineServer(t,o){let n=o?.reconnect??!1,a=this.wsState();(a==="disconnected"||a==="error"||n)&&(this.#t?.close(),this.#t=null),!this.#t&&(this.#s=!1,this.#t=new WebSocket(this.#a.machineServerUrl),this.#o.set("connecting"),this.#t.onopen=()=>{this.#o.set("connect"),this.#n.set(!0),this.#p.set(!1),this.#l.set(null)},this.#t.onclose=()=>{this.#o.set("disconnected"),this.#n.set(!1),this.#l.set(t),this.#p.set(!0)},this.#t.onerror=()=>{this.#o.set("error")},this.#t.onmessage=p=>{let i=JSON.parse(p.data);if(this.wsState()==="connect"){if(i.type!=="welcome"){this.disconnectFromMachineServer(`Unexpected message type, expected 'welcome' but got '${i.type}'`);return}let l={token:t,publicKey:"",clientVersion:Be,protocolVersion:Je},r=this.createResponse(i,"authportal",l);this.#o.set("welcome"),this.#t?.send(r)}else if(this.wsState()==="welcome"){if(i.type!=="authportal"){this.disconnectFromMachineServer(`Unexpected message type, expected 'authportal' but got '${i.type}'`);return}var u=JSON.parse(i.payload??"");if(u.accepted===!1){this.#i("Authentication failed"),this.disconnectFromMachineServer("Authentication failed");return}for(this.#o.set("authenticated"),this.#n.set(!0);this.#c.length>0;){let l=this.#c.pop();l&&this.#r[l.messageId]&&this.activateCommand(l)}}else if(this.wsState()==="authenticated"){if(i.type!=="command"){console.warn(`Unexpected message type, expected 'command' but got '${i.type}'`);return}let l=this.#r[i.messageId];if(l){if(i.errorMessage)this.#i(i.errorMessage),l.reject(i.errorMessage);else{let r=JSON.parse(i.payload??"");r.statusCode>=400?this.#i(r.body||`Initial request failed with status code ${r.statusCode}`):this.#f(),r.body=r?.body==null?null:this.utf8Atob(r.body),l.resolve(r)}delete this.#r[i.messageId],window.clearTimeout(l.timer)}}})}disconnectFromMachineServer(t=null){t&&console.error(t),this.#t?.close(),this.#t=null,this.#o.set("disconnected"),this.#n.set(!1)}createResponse(t,o,n){let a={from:Pe,to:t.from,type:o,messageId:t.messageId,payload:JSON.stringify(n)};return JSON.stringify(a)}sendCommand(t,o,n,a,p,i,u=5e3){return(this.wsState()==="disconnected"||this.wsState()==="error")&&this.connectToMachineServer(t),new Promise((l,r)=>{let m=D(),g={from:Pe,to:o,type:"command",messageId:m,payload:JSON.stringify({method:n,path:a,body:p,headers:i})},b={resolve:l,reject:r,timer:window.setTimeout(()=>{let E=this.#r[m];E&&(delete this.#r[m],this.#i("The request timed out before receiving a response."),E.reject("Timeout"))},u)};this.#r[m]=b,this.#n()?this.activateCommand(g):this.#c.push(g)})}activateCommand(t){this.#t?.send(JSON.stringify(t))}static \u0275fac=function(o){return new(o||e)};static \u0275prov=C({token:e,factory:e.\u0275fac,providedIn:"root"})};function Ke(e){if(typeof e!="string")return null;let o=new TextEncoder().encode(e);return window.btoa(String.fromCharCode(...o))}function He(e,t,o){let n=e.relayconfigState.config();if(n===null)return o(t);let a=Ke(t.body),p={};t.headers.keys().forEach(r=>{p[r]=t.headers.get(r)??""});let i=t.headers.get("timeout"),u=i!==null?parseInt(i):e.defaultTimeout;t.url.startsWith("/api/v1/serverstate")&&t.url.includes("longpoll=true")&&(u=1e3*99);let l=e.relayWebsocket.sendCommand(n.accessToken,n.clientId,t.method,t.url,a,p,u);return new W(r=>{l.then(m=>{let S=new se;p!=null&&Object.keys(p).forEach(b=>{S.set(b,p[b])});let g=new ie({body:m.body,status:m.statusCode,statusText:"OK",headers:S});r.next(g),r.complete()}).catch(m=>{r.error(new ae({error:m??"Unknown error",status:0,statusText:m??"Unknown error"}))})})}var De=(e,t)=>{let o={relayconfigState:s(v),defaultTimeout:s(f).defaultTimeout,relayWebsocket:s(x)},n=o.relayconfigState.config();if(o.relayconfigState.configLoaded!==null&&n===null){let a=new $;return o.relayconfigState.configLoaded.subscribe(p=>{p&&He(o,e,t).subscribe(a)}),a}return He(o,e,t)};var Ve={providers:[ee(),he(xe,ge(),fe(ue)),pe(ce(),le([De,Le])),h,{provide:f,useValue:Ne},{provide:te,useValue:Ae()},{provide:Ce,useValue:{alertVariant:"simple"}},Te,k,Ee,ne,Re,oe,Me,Ie]};re(A,Ve);
|