@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.
Files changed (162) hide show
  1. package/assets/dest-icons/googleworkspace.png +0 -0
  2. package/assets/sh-bold.woff2 +0 -0
  3. package/assets/sh.woff2 +0 -0
  4. package/chunk-23UYU3M3.js +1 -0
  5. package/chunk-2FPYV4EW.js +1 -0
  6. package/chunk-2K74TI2N.js +1 -0
  7. package/{chunk-HCSB3IIB.js → chunk-2T4BMRWX.js} +1 -1
  8. package/{chunk-D6IP567E.js → chunk-3MS6SVET.js} +1 -1
  9. package/{chunk-BABBRM6A.js → chunk-3QS6DB3O.js} +1 -1
  10. package/chunk-4HB376H3.js +1 -0
  11. package/{chunk-VDSX2M4H.js → chunk-4VYR5E5I.js} +1 -1
  12. package/chunk-5MKFV3IB.js +1 -0
  13. package/chunk-5T2JCBPV.js +1 -0
  14. package/{chunk-GRVTXORM.js → chunk-6COK7FLL.js} +1 -1
  15. package/chunk-7E5J43IH.js +1 -0
  16. package/{chunk-BYUBKTO5.js → chunk-7HFTVA4J.js} +1 -1
  17. package/chunk-7JHU54QM.js +1 -0
  18. package/chunk-7MPZ3MRD.js +1 -0
  19. package/chunk-7PUXNL75.js +1 -0
  20. package/chunk-A57TBTOD.js +1 -0
  21. package/chunk-AG7H2MR5.js +1 -0
  22. package/chunk-AGMFKAHM.js +1 -0
  23. package/chunk-AI6EYFMY.js +1 -0
  24. package/chunk-AZEV3A4R.js +11 -0
  25. package/chunk-C5OYK6UC.js +2 -0
  26. package/chunk-CAJQ2FEU.js +1 -0
  27. package/{chunk-MZ5COKIP.js → chunk-CTQKCCGM.js} +1 -1
  28. package/chunk-DKPWJYG3.js +1 -0
  29. package/chunk-DRRYACBV.js +1 -0
  30. package/{chunk-SZUNW4JO.js → chunk-EG3PT3XW.js} +1 -1
  31. package/{chunk-QHBOEY2O.js → chunk-FJFREVRV.js} +1 -1
  32. package/chunk-G3FMV74P.js +1 -0
  33. package/{chunk-B62TPRVG.js → chunk-GGW26MAG.js} +1 -1
  34. package/chunk-GTZRHPRV.js +1 -0
  35. package/chunk-I2T6IA4K.js +1 -0
  36. package/chunk-I6PR2AV2.js +1 -0
  37. package/chunk-I7MAEY3S.js +1 -0
  38. package/chunk-IAZGVY3O.js +1 -0
  39. package/chunk-IPGH33MU.js +1 -0
  40. package/chunk-JJY6UOEY.js +1 -0
  41. package/chunk-JRXD2X7B.js +1 -0
  42. package/chunk-JWPG4EWG.js +1 -0
  43. package/{chunk-ZU6T3TW3.js → chunk-KLAJGS5T.js} +1 -1
  44. package/{chunk-ZWLAV6HO.js → chunk-KUGAORAS.js} +1 -1
  45. package/{chunk-7TWUW4XJ.js → chunk-KUX6NGQU.js} +1 -1
  46. package/chunk-KYTPZ3WD.js +1 -0
  47. package/chunk-L22UB6DH.js +1 -0
  48. package/{chunk-PO3L6MKW.js → chunk-LU7RSOI6.js} +1 -1
  49. package/chunk-MMF252RQ.js +1 -0
  50. package/chunk-NAMMULH4.js +1 -0
  51. package/{chunk-HUZXJWCG.js → chunk-NGKFJLI2.js} +1 -1
  52. package/chunk-NGPZXZJJ.js +1 -0
  53. package/chunk-NJBOYRXU.js +1 -0
  54. package/{chunk-TL4WOQKT.js → chunk-O3GGVB2B.js} +1 -1
  55. package/{chunk-7LTHH6OG.js → chunk-OAAXQ2BE.js} +1 -1
  56. package/chunk-OL5HI5OG.js +2 -0
  57. package/{chunk-37CUOEGJ.js → chunk-OOL5FC7N.js} +1 -1
  58. package/{chunk-EE5SIDTF.js → chunk-OVLGKJ3Z.js} +1 -1
  59. package/{chunk-NK5WD6WE.js → chunk-OWBBT5WF.js} +1 -1
  60. package/chunk-P7TJCJ64.js +3 -0
  61. package/{chunk-R5YJUVWW.js → chunk-PGISF7LM.js} +1 -1
  62. package/chunk-PVWYJV5Y.js +1 -0
  63. package/chunk-QY4Y5NJB.js +4 -0
  64. package/{chunk-5LBG6MOL.js → chunk-QY5UGQ3R.js} +1 -1
  65. package/chunk-R45TV6JI.js +1 -0
  66. package/{chunk-I3IIG2AK.js → chunk-R4E5IO3A.js} +1 -1
  67. package/chunk-RFCIV3AX.js +1 -0
  68. package/chunk-RJM43XMN.js +1 -0
  69. package/chunk-RNE4Z2E4.js +1 -0
  70. package/{chunk-6LAXPU22.js → chunk-RWDQ3L3C.js} +1 -1
  71. package/chunk-SFW3N5OL.js +1 -0
  72. package/chunk-SIMG6PGZ.js +2 -0
  73. package/chunk-SMUUHPDS.js +1 -0
  74. package/chunk-STB3WOIA.js +1 -0
  75. package/chunk-T2KOS3XX.js +1 -0
  76. package/{chunk-AIH3GSIT.js → chunk-TBQPNXMN.js} +1 -1
  77. package/{chunk-NGNWWP6M.js → chunk-UOZTEZ7B.js} +1 -1
  78. package/{chunk-VFBRHP2H.js → chunk-V63YAEPZ.js} +1 -1
  79. package/{chunk-KDSMLI73.js → chunk-VKNFRCHQ.js} +1 -1
  80. package/{chunk-7AVOHYTE.js → chunk-VLMNSWR3.js} +1 -1
  81. package/{chunk-T4IKTBRQ.js → chunk-VNF7NNO5.js} +1 -1
  82. package/{chunk-AODNZLCK.js → chunk-VPUFUCR3.js} +1 -1
  83. package/chunk-VUKQJ766.js +1 -0
  84. package/{chunk-MDXSNEQZ.js → chunk-WLAJ3YIP.js} +1 -1
  85. package/{chunk-G2FJM62F.js → chunk-XHDAWK7I.js} +1 -1
  86. package/chunk-XTFBRBQX.js +1 -0
  87. package/chunk-XZHXN75E.js +1 -0
  88. package/chunk-Y46QCSB5.js +1 -0
  89. package/chunk-Z2BNW4KI.js +1 -0
  90. package/chunk-ZFREX3ZV.js +1 -0
  91. package/chunk-ZPIR5QIQ.js +2 -0
  92. package/index.html +2 -2
  93. package/locale/messages.da.json +9 -23
  94. package/locale/messages.de.json +114 -60
  95. package/locale/messages.de_CH.json +80 -37
  96. package/locale/messages.en.json +73 -39
  97. package/locale/messages.en_GB.json +73 -39
  98. package/locale/messages.es.json +43 -10
  99. package/locale/messages.fr.json +611 -17
  100. package/locale/messages.it.json +104 -63
  101. package/locale/messages.json +73 -39
  102. package/locale/messages.pl.json +376 -12
  103. package/main-DIGDM6JP.js +1 -0
  104. package/package.json +1 -1
  105. package/ship-ui-assets/mcp/components.json +4388 -0
  106. package/styles-377DNUNK.css +1 -0
  107. package/chunk-26MRZAFB.js +0 -1
  108. package/chunk-26Z7TPJB.js +0 -4
  109. package/chunk-3K3BYB36.js +0 -1
  110. package/chunk-3QV6WLWV.js +0 -1
  111. package/chunk-4GXIF5HF.js +0 -1
  112. package/chunk-4RYK5OOO.js +0 -1
  113. package/chunk-5MHYH7GK.js +0 -2
  114. package/chunk-5QWAH3QX.js +0 -1
  115. package/chunk-5VE6P5U5.js +0 -1
  116. package/chunk-7DCQVM6E.js +0 -1
  117. package/chunk-AT64P6E5.js +0 -2
  118. package/chunk-BFTGDQ4K.js +0 -1
  119. package/chunk-BT2VIZXE.js +0 -1
  120. package/chunk-C25WT56X.js +0 -1
  121. package/chunk-C7N24TZM.js +0 -1
  122. package/chunk-CFNARBNK.js +0 -1
  123. package/chunk-COPBOHWE.js +0 -1
  124. package/chunk-DESKT7LH.js +0 -1
  125. package/chunk-EE27B3OV.js +0 -1
  126. package/chunk-F3JL4GJQ.js +0 -1
  127. package/chunk-G4IFZKMI.js +0 -1
  128. package/chunk-GJKZESBX.js +0 -1
  129. package/chunk-H4LQO7G2.js +0 -1
  130. package/chunk-HOGZ74SB.js +0 -1
  131. package/chunk-HSHF5HR7.js +0 -1
  132. package/chunk-I27PVH6D.js +0 -1
  133. package/chunk-I2RQR4CB.js +0 -1
  134. package/chunk-IGYSPFE7.js +0 -1
  135. package/chunk-JN4WCRAH.js +0 -1
  136. package/chunk-K34VOGDF.js +0 -1
  137. package/chunk-KV5UORE3.js +0 -1
  138. package/chunk-LT3AVRVP.js +0 -1
  139. package/chunk-LXSHDO5C.js +0 -11
  140. package/chunk-M7Y3VPRV.js +0 -1
  141. package/chunk-MIMGEZMT.js +0 -1
  142. package/chunk-MLNK7NFW.js +0 -2
  143. package/chunk-MMEFBZO4.js +0 -1
  144. package/chunk-NNNKIEPR.js +0 -1
  145. package/chunk-OIYIWMS7.js +0 -1
  146. package/chunk-OPLWAKSM.js +0 -3
  147. package/chunk-Q2UQ5J3C.js +0 -1
  148. package/chunk-Q74O3CWJ.js +0 -1
  149. package/chunk-S2RZQVCD.js +0 -1
  150. package/chunk-T4BXBCQI.js +0 -1
  151. package/chunk-U2E3ZQUP.js +0 -1
  152. package/chunk-UK7MV4OF.js +0 -1
  153. package/chunk-UNLX3IVU.js +0 -1
  154. package/chunk-UNMDSCAN.js +0 -1
  155. package/chunk-W3YBKYPJ.js +0 -1
  156. package/chunk-XIYAYCFU.js +0 -1
  157. package/chunk-XLMLR5EV.js +0 -1
  158. package/chunk-YHMXLWRX.js +0 -1
  159. package/chunk-YLQF5ATT.js +0 -1
  160. package/chunk-ZHGDQABC.js +0 -2
  161. package/main-HMCIC27B.js +0 -1
  162. package/styles-H32RJLOU.css +0 -1
@@ -0,0 +1 @@
1
+ import{d as a,e as b,f as c}from"./chunk-AZEV3A4R.js";import"./chunk-RWDQ3L3C.js";import"./chunk-CAJQ2FEU.js";import"./chunk-ZPIR5QIQ.js";import"./chunk-6Q6SSTBK.js";import"./chunk-O3GGVB2B.js";import"./chunk-OAAXQ2BE.js";import"./chunk-7E5J43IH.js";import"./chunk-3MS6SVET.js";import"./chunk-4VYR5E5I.js";import"./chunk-KLAJGS5T.js";import"./chunk-NGKFJLI2.js";import"./chunk-KUX6NGQU.js";import"./chunk-Y46QCSB5.js";import"./chunk-JJY6UOEY.js";import"./chunk-2K74TI2N.js";import"./chunk-G3FMV74P.js";import"./chunk-LU7RSOI6.js";import"./chunk-VLMNSWR3.js";import"./chunk-VKNFRCHQ.js";import"./chunk-QY4Y5NJB.js";import"./chunk-7CGTOI24.js";export{b as NONE_OPTION,a as createGeneralForm,c as default};
@@ -1 +1 @@
1
- import{Mc as w,Nc as x,O as d,Oc as h,W as v,da as y,fa as l,i as m,la as b,na as D,oa as f}from"./chunk-26Z7TPJB.js";import{a as g,b as p}from"./chunk-7CGTOI24.js";function N(o,e){let s=e?.injector??v(y),n=new m(1),i=D(()=>{let t;try{t=o()}catch(u){f(()=>n.error(u));return}f(()=>n.next(t))},{injector:s,manualCleanup:!0});return s.get(l).onDestroy(()=>{i.destroy(),n.complete()}),n.asObservable()}function E(o,e){let n=!e?.manualCleanup?e?.injector?.get(l)??v(l):null,i=j(e?.equal),t;e?.requireSync?t=b({kind:0},{equal:i}):t=b({kind:1,value:e?.initialValue},{equal:i});let u,a=o.subscribe({next:r=>t.set({kind:1,value:r}),error:r=>{t.set({kind:2,error:r}),u?.()},complete:()=>{u?.()}});if(e?.requireSync&&t().kind===0)throw new d(601,!1);return u=n?.onDestroy(a.unsubscribe.bind(a)),w(()=>{let r=t();switch(r.kind){case 1:return r.value;case 2:throw r.error;case 0:throw new d(601,!1)}},{equal:e?.equal})}function j(o=Object.is){return(e,s)=>e.kind===1&&s.kind===1&&o(e.value,s.value)}function U(o){return x(p(g({},o),{loader:void 0,stream:e=>{let s,n=()=>s?.unsubscribe();e.abortSignal.addEventListener("abort",n);let i=b({value:void 0}),t,u=new Promise(c=>t=c);function a(c){i.set(c),t?.(i),t=void 0}let r=o.stream??o.loader;if(r===void 0)throw new d(990,!1);return s=r(e).subscribe({next:c=>a({value:c}),error:c=>{a({error:h(c)}),e.abortSignal.removeEventListener("abort",n)},complete:()=>{t&&a({error:new d(991,!1)}),e.abortSignal.removeEventListener("abort",n)}}),u}}))}export{N as a,E as b,U as c};
1
+ import{Pc as w,Qc as x,R as d,Rc as h,Z as v,ga as y,i as m,ia as l,oa as b,qa as D,ra as f}from"./chunk-QY4Y5NJB.js";import{a as g,b as p}from"./chunk-7CGTOI24.js";function N(o,e){let s=e?.injector??v(y),n=new m(1),i=D(()=>{let t;try{t=o()}catch(u){f(()=>n.error(u));return}f(()=>n.next(t))},{injector:s,manualCleanup:!0});return s.get(l).onDestroy(()=>{i.destroy(),n.complete()}),n.asObservable()}function E(o,e){let n=!e?.manualCleanup?e?.injector?.get(l)??v(l):null,i=j(e?.equal),t;e?.requireSync?t=b({kind:0},{equal:i}):t=b({kind:1,value:e?.initialValue},{equal:i});let u,a=o.subscribe({next:r=>t.set({kind:1,value:r}),error:r=>{t.set({kind:2,error:r}),u?.()},complete:()=>{u?.()}});if(e?.requireSync&&t().kind===0)throw new d(601,!1);return u=n?.onDestroy(a.unsubscribe.bind(a)),w(()=>{let r=t();switch(r.kind){case 1:return r.value;case 2:throw r.error;case 0:throw new d(601,!1)}},{equal:e?.equal})}function j(o=Object.is){return(e,s)=>e.kind===1&&s.kind===1&&o(e.value,s.value)}function U(o){return x(p(g({},o),{loader:void 0,stream:e=>{let s,n=()=>s?.unsubscribe();e.abortSignal.addEventListener("abort",n);let i=b({value:void 0}),t,u=new Promise(c=>t=c);function a(c){i.set(c),t?.(i),t=void 0}let r=o.stream??o.loader;if(r===void 0)throw new d(990,!1);return s=r(e).subscribe({next:c=>a({value:c}),error:c=>{a({error:h(c)}),e.abortSignal.removeEventListener("abort",n)},complete:()=>{t&&a({error:new d(991,!1)}),e.abortSignal.removeEventListener("abort",n)}}),u}}))}export{N as a,E as b,U as c};
@@ -0,0 +1 @@
1
+ import{a as Ge}from"./chunk-7MPZ3MRD.js";import{a as Le}from"./chunk-CTQKCCGM.js";import{b as xe}from"./chunk-23UYU3M3.js";import{a as ye}from"./chunk-GGW26MAG.js";import{a as $e}from"./chunk-FJFREVRV.js";import{a as K}from"./chunk-EG3PT3XW.js";import{a as ke}from"./chunk-O3GGVB2B.js";import{a as Be}from"./chunk-3MS6SVET.js";import{b as be}from"./chunk-KLAJGS5T.js";import{a as ve}from"./chunk-NGKFJLI2.js";import{c as Fe}from"./chunk-KUX6NGQU.js";import{B as h,H as Pe,K as Re,L as Ae,O as Ie,P as he,Y as V,c as Ee,e as Oe,i as fe,k as Ne,s as De,v as I,z as Me}from"./chunk-Y46QCSB5.js";import{d as H}from"./chunk-JJY6UOEY.js";import{e as Ce}from"./chunk-2K74TI2N.js";import{fa as me}from"./chunk-VLMNSWR3.js";import{Ac as X,Bb as D,Cb as s,Db as l,E as ie,Eb as u,Fc as Y,Gc as Se,Hc as de,Ib as ae,Jb as se,Jc as pe,Lb as N,Pc as A,Sa as _,Sb as C,Tb as F,Tc as ge,Ub as M,Vb as le,Wb as _e,Xb as b,Yb as c,Z as m,_b as T,ca as O,da as f,fb as P,hc as re,ic as ce,jc as G,kb as oe,mc as d,nc as U,oa as E,oc as w,pc as Te,qa as $,rc as y,sc as x,tc as B,vb as p,wb as g,zc as ue}from"./chunk-QY4Y5NJB.js";function Je(i,t){i&1&&(s(0,"sh-icon",2),d(1,"x-bold"),l())}function Xe(i,t){i&1&&(s(0,"sh-icon",3),d(1,"list-bold"),l())}function Ye(i,t){if(i&1){let n=N();s(0,"button",1),c("click",function(){O(n);let o=T();return f(o.toggleNav())}),p(1,Je,2,0,"sh-icon",2)(2,Xe,2,0,"sh-icon",3),l()}if(i&2){let n=T();_(),g(n.isNavOpen()?1:2)}}var z=class i{#e=m(Le);isNavOpen=this.#e.isNavOpen;isMobile=this.#e.isMobile;toggleNav(){this.#e.toggleNav()}static \u0275fac=function(n){return new(n||i)};static \u0275cmp=P({type:i,selectors:[["app-mobile-menu-toggle"]],decls:1,vars:1,consts:[["shButton","",1,"small","toggle-sidebar","ghost"],["shButton","",1,"small","toggle-sidebar","ghost",3,"click"],[1,"cross"],[1,"burger"]],template:function(n,e){n&1&&p(0,Ye,3,1,"button",0),n&2&&g(e.isMobile()?0:-1)},dependencies:[h,I],styles:["[_nghost-%COMP%]{display:contents}.toggle-sidebar[_ngcontent-%COMP%]{position:relative;display:flex;align-items:center;justify-content:center}.toggle-sidebar[_ngcontent-%COMP%] .cross[_ngcontent-%COMP%], .toggle-sidebar[_ngcontent-%COMP%] .burger[_ngcontent-%COMP%]{opacity:1;transition:opacity 124ms linear;margin:0}.toggle-sidebar[_ngcontent-%COMP%] .cross.hidden[_ngcontent-%COMP%], .toggle-sidebar[_ngcontent-%COMP%] .burger.hidden[_ngcontent-%COMP%]{opacity:0}"],changeDetection:0})};var Ue=()=>["/connect/logon"];function Ke(i,t){i&1&&(C(0,0,1),u(1,"div",9),F())}function We(i,t){i&1&&(C(0,0,2),u(1,"div",10),F())}function je(i,t){if(i&1){let n=N();s(0,"div",8),c("click",function(){O(n);let o=T();return f(o.resetAndRetry())}),C(1,0),p(2,Ke,2,0)(3,We,2,0),F(),l()}if(i&2){let n=T();_(2),g(n.resetting()?2:3)}}function Ze(i,t){i&1&&(s(0,"div",6),C(1,1),u(2,"div",11),F(),l()),i&2&&D("routerLink",X(1,Ue))}function qe(i,t){i&1&&(s(0,"div",6),C(1,2),u(2,"div",10),F(),l()),i&2&&D("routerLink",X(1,Ue))}function Qe(i,t){if(i&1){let n=N();s(0,"div",7),C(1,3),s(2,"sh-icon",12),c("click",function(){O(n);let o=T();return f(o.cancel())}),l(),s(3,"div",13),c("click",function(){O(n);let o=T();return f(o.claim())}),l(),u(4,"div",14),F(),l()}}function et(i,t){if(i&1){let n=N();s(0,"div",8),c("click",function(){O(n);let o=T();return f(o.openConsole())}),C(1,4),u(2,"div",15),F(),l()}}var k=class i{#e=m(ke);state=this.#e.state;resetting=E(!1);stateEffect=$(()=>{let t=this.#e.state(),n=this.resetting();t==="registered"&&n&&(this.resetting.set(!1),this.#e.beginRemoteRegistration())});ngOnInit(){this.#e.refreshRemoteControlStatus()}claim(){let t=this.#e.claimUrl();t&&window.open(t,"_blank")}cancel(){this.#e.cancelRemoteRegistration()}resetAndRetry(){this.resetting.set(!0),this.#e.cancelRemoteRegistration()}openConsole(){this.#e.openConsole()}static \u0275fac=function(n){return new(n||i)};static \u0275cmp=P({type:i,selectors:[["app-remote-connectivity-status"]],decls:5,vars:1,consts:()=>{let t;t=$localize`${"\uFFFD*2:1\uFFFD"}:START_BLOCK_IF: Resetting ${"\uFFFD#1:1\uFFFD"}:START_TAG_DIV:${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_DIV:${"\uFFFD/*2:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*3:2\uFFFD"}:START_BLOCK_ELSE: Click to connect ${"\uFFFD#1:2\uFFFD"}:START_TAG_DIV_1:${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_DIV:${"\uFFFD/*3:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,t=b(t);let n;n=$localize` Connecting ${"\uFFFD#2\uFFFD"}:START_TAG_DIV:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_DIV:`;let e;e=$localize` Click to register ${"\uFFFD#2\uFFFD"}:START_TAG_DIV:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_DIV:`;let o;o=$localize`Cancel registration`;let a;a=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:x-circle${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD#3\uFFFD"}:START_TAG_DIV:Click to claim${"[\uFFFD/#3\uFFFD|\uFFFD/#4\uFFFD]"}:CLOSE_TAG_DIV:${"\uFFFD#4\uFFFD"}:START_TAG_DIV_1:${"[\uFFFD/#3\uFFFD|\uFFFD/#4\uFFFD]"}:CLOSE_TAG_DIV:`,a=b(a);let S;return S=$localize` Connected ${"\uFFFD#2\uFFFD"}:START_TAG_DIV:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_DIV:`,[t,n,e,a,S,[1,"connectivity-status"],[1,"connectivity-status",3,"routerLink"],[1,"connectivity-status","claim"],[1,"connectivity-status",3,"click"],[1,"status","blinking"],[1,"status"],[1,"status","warning","blinking"],["shTooltip",o,3,"click"],[1,"claim",3,"click"],[1,"status","success","blinking"],[1,"status","success"]]},template:function(n,e){if(n&1&&p(0,je,4,1,"div",5)(1,Ze,3,2,"div",6)(2,qe,3,2,"div",6)(3,Qe,5,0,"div",7)(4,et,3,0,"div",5),n&2){let o=e.state()==="unknown"||e.state()==="inactive"||e.state()==="registeringfaulted",a=e.state()==="registeringfaulted",S=e.state()==="registering",r=e.state()==="registered",R=e.state()==="connected"||e.state()==="disabled"||e.state()==="connecting";g(a?0:S?1:o?2:r?3:R?4:-1)}},dependencies:[Ce,I,V],styles:["[_nghost-%COMP%]{display:flex;align-items:center;padding:0 .75rem}@media only screen and (max-width:768px){[_nghost-%COMP%]{padding:0}}.hide-text[_nghost-%COMP%]{font-size:0}.in-menu[_nghost-%COMP%]{padding:.75rem;border-bottom:1px solid var(--base-4)}.connectivity-status[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;cursor:pointer}.connectivity-status[_ngcontent-%COMP%]:hover{color:var(--primary-8)}.connectivity-status.claim[_ngcontent-%COMP%]{display:flex;gap:.5rem;cursor:pointer}.connectivity-status.claim[_ngcontent-%COMP%]:hover{color:inherit}.connectivity-status.claim[_ngcontent-%COMP%] .claim[_ngcontent-%COMP%]:hover{color:var(--primary-8)}.connectivity-status.claim[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]:hover{color:var(--error-8)}.status[_ngcontent-%COMP%]{width:.625rem;height:.625rem;border-radius:50%;background-color:var(--base-4)}.status.success[_ngcontent-%COMP%]{background-color:var(--success-8)}.status.warning[_ngcontent-%COMP%]{background-color:var(--warn-8)}.status.blinking[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_blinking 1s infinite}@keyframes _ngcontent-%COMP%_blinking{0%{opacity:.2}50%{opacity:1}to{opacity:.2}}"],changeDetection:0})};var we={Byte:"B",KByte:"KB",MByte:"MB",GByte:"GB",TByte:"TB",PByte:"PB"},tt=["mbps","gbps"],Ve=8,Q=1024,J=Q*1024,ee=J*1024,te=ee*1024,He=te*1024,nt={B:1,KB:Q,MB:J,GB:ee,TB:te,PB:He},it=1e3,q=it*1e3,Z=q*1e3,ot=[{threshold:He,unitPrefix:"PByte"},{threshold:te,unitPrefix:"TByte"},{threshold:ee,unitPrefix:"GByte"},{threshold:J,unitPrefix:"MByte"},{threshold:Q,unitPrefix:"KByte"},{threshold:1,unitPrefix:"Byte"}],L=class i{#e=m(H);closed=ge();isSubmitting=E(!1);sizeOptions=E([...tt]);maxUpload=E(0);maxDownload=E(0);maxUploadUnit=E("mbps");maxDownloadUnit=E("mbps");ngOnInit(){this.init()}convertToBitsPerSecondUnits(t,n){let o=t*(nt[n.toUpperCase()]||J)*Ve;return o===0?{value:0,unit:"mbps"}:o>=Z?{value:parseFloat((o/Z).toFixed(2)),unit:"gbps"}:{value:parseFloat((o/q).toFixed(2)),unit:"mbps"}}convertFromBitsPerSecondUnits(t,n){let e=0;switch(n){case"gbps":e=t*Z;break;case"mbps":e=t*q;break}let o=e/Ve;if(o===0)return{valueForApi:0,unitPrefixForApi:"Byte"};for(let{threshold:a,unitPrefix:S}of ot)if(o>=a)return{valueForApi:Math.round(o/a),unitPrefixForApi:S};return{valueForApi:Math.round(o),unitPrefixForApi:"Byte"}}init(){this.#e.getApiV1Serversettings().subscribe({next:t=>{let n=t?.["max-upload-speed"],e=t?.["max-download-speed"];if(n&&n!==""){let o=n.match(/^(\d+(?:\.\d+)?)([A-Za-z]+)$/);if(o){let a=parseFloat(o[1]),S=o[2],r=this.convertToBitsPerSecondUnits(a,S);this.maxUpload.set(r.value),this.maxUploadUnit.set(r.unit)}else console.warn("Unexpected max-upload-speed format from API:",n),this.resetUpload()}else this.resetUpload();if(e&&e!==""){let o=e.match(/^(\d+(?:\.\d+)?)([A-Za-z]+)$/);if(o){let a=parseFloat(o[1]),S=o[2],r=this.convertToBitsPerSecondUnits(a,S);this.maxDownload.set(r.value),this.maxDownloadUnit.set(r.unit)}else console.warn("Unexpected max-download-speed format from API:",e),this.resetDownload()}else this.resetDownload()},error:t=>{console.error("Failed to get server settings:",t),this.resetDownload(),this.resetUpload()}})}resetDownload(){this.maxDownload.set(0),this.maxDownloadUnit.set("mbps")}resetUpload(){this.maxUpload.set(0),this.maxUploadUnit.set("mbps")}blockDecimalKeys(t){if([".",","].includes(t.key))return t.preventDefault()}cleanupInputAfterPasting(t){t.preventDefault();let n=t.clipboardData?.getData("text/plain");if(!n)return;let e=n.replaceAll(/[\.,]/g,"");t.target.value=e}submit(){this.isSubmitting.set(!0);let t="",n="",e=this.maxUpload()??0,o=this.maxUploadUnit(),a=this.maxDownload()??0,S=this.maxDownloadUnit();if(e>0){let{valueForApi:r,unitPrefixForApi:R}=this.convertFromBitsPerSecondUnits(e,o),v=we[R];v?t=`${r}${v}`:console.error(`Invalid unit prefix for API submission (upload): ${R}. Defaulting to empty string.`)}if(a){let{valueForApi:r,unitPrefixForApi:R}=this.convertFromBitsPerSecondUnits(a,S),v=we[R];v?n=`${r}${v}`:console.error(`Invalid unit prefix for API submission (download): ${R}. Defaulting to empty string.`)}this.#e.patchApiV1Serversettings({requestBody:{"max-upload-speed":t,"max-download-speed":n}}).pipe(ie(()=>this.isSubmitting.set(!1))).subscribe({next:()=>{this.closed.emit(!0)},error:r=>{console.error("Failed to submit throttle settings:",r)}})}static \u0275fac=function(n){return new(n||i)};static \u0275cmp=P({type:i,selectors:[["app-throttle-settings-dialog"]],outputs:{closed:"closed"},decls:26,vars:10,consts:()=>{let t;t=$localize`Throttle network speed`;let n;n=$localize`We will round bits to the nearest byte value.`;let e;e=$localize`Max upload speed`;let o;o=$localize`Max download speed`;let a;a=$localize`Cancel`;let S;return S=$localize` Update settings `,[t,n,e,o,a,S,["content",""],[1,"column"],[1,"field-row"],["type","number",3,"paste","keydown","ngModelChange","ngModel"],[3,"isClearable","options"],["type","text",3,"ngModelChange","ngModel"],["footer",""],["shButton","",3,"click"],["shButton","",1,"raised","primary",3,"click"]]},template:function(n,e){n&1&&(s(0,"header")(1,"h3"),M(2,0),l(),s(3,"p"),M(4,1),l()(),s(5,"div",6)(6,"div",7)(7,"div",8)(8,"label"),M(9,2),l(),s(10,"sh-form-field")(11,"input",9),c("paste",function(a){return e.cleanupInputAfterPasting(a)})("keydown",function(a){return e.blockDecimalKeys(a)}),B("ngModelChange",function(a){return x(e.maxUpload,a)||(e.maxUpload=a),a}),l()(),s(12,"sh-select",10)(13,"input",11),B("ngModelChange",function(a){return x(e.maxUploadUnit,a)||(e.maxUploadUnit=a),a}),l()()(),s(14,"div",8)(15,"label"),M(16,3),l(),s(17,"sh-form-field")(18,"input",9),c("paste",function(a){return e.cleanupInputAfterPasting(a)})("keydown",function(a){return e.blockDecimalKeys(a)}),B("ngModelChange",function(a){return x(e.maxDownload,a)||(e.maxDownload=a),a}),l()(),s(19,"sh-select",10)(20,"input",11),B("ngModelChange",function(a){return x(e.maxDownloadUnit,a)||(e.maxDownloadUnit=a),a}),l()()()()(),s(21,"footer",12)(22,"button",13),c("click",function(){return e.closed.emit(!1)}),M(23,4),l(),s(24,"button",14),c("click",function(){return e.submit()}),M(25,5),l()()),n&2&&(_(11),y("ngModel",e.maxUpload),_(),D("isClearable",!1)("options",e.sizeOptions()),_(),y("ngModel",e.maxUploadUnit),_(5),y("ngModel",e.maxDownload),_(),D("isClearable",!1)("options",e.sizeOptions()),_(),y("ngModel",e.maxDownloadUnit),_(4),G("loading",e.isSubmitting()))},dependencies:[De,Ee,Ne,Oe,fe,Pe,he,h],styles:['[_nghost-%COMP%]{display:block}h3[_ngcontent-%COMP%]{font:var(--title-30)}header[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:flex-start;padding:1rem;gap:.5rem;margin-bottom:1rem}.column[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.field-row[_ngcontent-%COMP%]{display:grid;grid-template-areas:"label label" "input select";grid-template-columns:1fr auto;align-items:center;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{grid-area:label}.field-row[_ngcontent-%COMP%] sh-form-field[_ngcontent-%COMP%]{grid-area:input}.field-row[_ngcontent-%COMP%] sh-select[_ngcontent-%COMP%]{grid-area:select}'],changeDetection:0})};function at(i,t){i&1&&(s(0,"sh-icon"),d(1,"check"),l())}function st(i,t){i&1&&(s(0,"sh-icon"),d(1,"copy"),l())}function lt(i,t){if(i&1){let n=N();s(0,"div",22)(1,"button",23),c("click",function(o){O(n);let a=T(3);return f(a.copyToClipboard(o,a.tooltipText()))}),p(2,at,2,0,"sh-icon")(3,st,2,0,"sh-icon"),d(4," Copy "),l(),s(5,"p",24),d(6),l()()}if(i&2){let n=T(3);_(),D("color",n.copied()?"success":null),_(),g(n.copied()===!0?2:3),_(4),U(n.tooltipText())}}function _t(i,t){if(i&1&&(s(0,"div",21),d(1),l(),oe(2,lt,7,3,"ng-template",null,0,pe)),i&2){let n=re(3),e=T(2);D("shTooltip",n),_(),w(" ",e.statusData().fileStatusText," ")}}function rt(i,t){if(i&1&&(s(0,"div"),d(1),l(),p(2,_t,4,2),u(3,"sh-progress-bar",20)),i&2){let n,e=T();_(),Te("",e.statusData().actionText," - ",e.statusData().statusText),_(),g((n=e.statusData())!=null&&n.BackendFileSize?2:-1),_(),D("value",e.statusData().progress*100)}}function ct(i,t){if(i&1&&(s(0,"div",9),C(1,2),u(2,"sh-icon"),Y(3,"relativeTime"),Y(4,"date"),F(),l()),i&2){let n,e=T();_(4),le((n=e.nextBackup().backup)==null||n.Backup==null?null:n.Backup.Name)(Se(3,3,e.nextBackup().time))(de(4,5,e.nextBackup().time,"shortTime")),_e(1)}}function Tt(i,t){i&1&&(s(0,"div",9),M(1,3),l())}function ut(i,t){i&1&&(s(0,"div",10),C(1,4),u(2,"sh-spinner"),F(),l()),i&2&&(_(2),ce("--spinner-size","12px")("--spinner-thickness","2px"))}function St(i,t){i&1&&u(0,"app-remote-connectivity-status")}function dt(i,t){if(i&1){let n=N();s(0,"button",13),c("click",function(){O(n);let o=T(2);return f(o.abort())}),C(1,5),u(2,"sh-icon"),F(),l()}}function pt(i,t){if(i&1){let n=N();s(0,"button",13),c("click",function(){O(n);let o=T(2);return f(o.stop())}),C(1,6),u(2,"sh-icon"),F(),l()}}function gt(i,t){if(i&1&&p(0,dt,3,0,"button",25)(1,pt,3,0,"button",25),i&2){let n=T();g(n.isStopping()?0:1)}}function mt(i,t){i&1&&(C(0,1,1),u(1,"sh-icon"),F())}function Ct(i,t){i&1&&(C(0,1,2),u(1,"sh-icon"),F())}function Ft(i,t){i&1&&u(0,"app-remote-connectivity-status",16)}function Et(i,t){i&1&&u(0,"app-remote-connectivity-status",18)}function Ot(i,t){if(i&1){let n=N();s(0,"button",19),c("click",function(){O(n);let o=T();return f(o.isStopping()?o.abort():o.stop())}),s(1,"sh-icon"),d(2),l(),d(3),l()}if(i&2){let n=T();_(2),U(n.isStopping()?"skull":"stop"),_(),w(" ",n.isStopping()?"Abort":"Stop"," ")}}var ze=new Date,ne=class i{#e=m(H);#t=m(xe);#n=m(Me);#s=m(ye);#i=m(Fe);#l=m(ve);#o=m(be);#_=m(Be);#r=m(K);minsAgo=ze.setMinutes(ze.getMinutes()-1);statusData=this.#t.statusData;serverState=this.#t.serverState;clientIsRunning=this.#t.clientIsRunning;isResuming=this.#t.isResuming;runningTask=A(()=>this.#o.serverState()?.ActiveTask?.Item1);isStopping=A(()=>this.runningTask()==this.#a());#a=E(-1);pgState=A(()=>this.#o.serverState());isUsingRelay=this.#i.relayIsEnabled;hideConsoleConnectionStatus=this.#_.isConsoleConnectionStatusHidden;tooltipText=A(()=>{let t=this.statusData();return t?.CurrentFilename?`${t.CurrentFilename}`:""});nextBackup=A(()=>{let t=this.#s.backups();return{backup:this.serverState()?.ProposedSchedule?.[0]?.backup,time:this.serverState()?.ProposedSchedule?.[0]?.Item2}});tooltipTrigger=E(!0);tooltipTriggerEffect=$(()=>{this.tooltipText(),this.tooltipTrigger.update(t=>!t),this.copiedTimeout&&(clearTimeout(this.copiedTimeout),this.copiedTimeout=void 0,this.copied.set(!1))});openThrottleSettingsDialog(){this.#n.open(L,{maxWidth:"550px",width:"100%"})}openPauseDialog(){this.#n.open(Ge,{maxWidth:"550px",width:"100%"})}copied=E(!1);copiedTimeout;copyToClipboard(t,n){t.stopPropagation(),navigator.clipboard.writeText(n),this.copied.set(!0),this.copiedTimeout=setTimeout(()=>{this.copied.set(!1)},2e3)}pauseResume(){if(this.clientIsRunning()){this.openPauseDialog();return}this.#t.pauseResume().subscribe()}stop(){let t=this.runningTask();t&&(this.#a.set(t),this.#e.postApiV1TaskByTaskidStop({taskid:t}).subscribe())}abort(){let t=this.runningTask();t&&this.#e.postApiV1TaskByTaskidAbort({taskid:t}).subscribe()}ngAfterViewInit(){let t=this.#i.relayIsEnabled()||!this.#l.hasWebSocket()?"longpoll":"websocket";this.#t.setConnectionMethod(t)}static \u0275fac=function(n){return new(n||i)};static \u0275cmp=P({type:i,selectors:[["app-status-bar"]],features:[ue([K])],decls:35,vars:11,consts:()=>{let t;t=$localize`${"\uFFFD*13:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:pause${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Pause ${"\uFFFD/*13:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*14:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:play${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Resume ${"\uFFFD/*14:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,t=b(t);let n;n=$localize` ${"\uFFFD0\uFFFD"}:INTERPOLATION: - ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:clock${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: ${"\uFFFD1\uFFFD"}:INTERPOLATION_1: at ${"\uFFFD2\uFFFD"}:INTERPOLATION_2: `;let e;e=$localize`No scheduled tasks`;let o;o=$localize` Loading ${"\uFFFD#2\uFFFD"}:START_TAG_SH_SPINNER:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_SPINNER:`;let a;a=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:skull${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Abort `;let S;return S=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:stop${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Stop `,[["fileStatusTooltip",""],t,n,e,o,a,S,[1,"current-backup"],[1,"current-backup-progress"],[1,"label"],[1,"label","label-loading"],[1,"current-backup-actions"],[1,"desktop-actions"],["shButton","",3,"click"],[1,"mobile-actions"],["shButton","",1,"small","menu-mobile-toggle"],[1,"hide-text"],["menu",""],[1,"in-menu"],[3,"click"],[1,"raised","primary",3,"value"],[1,"file-status-text",3,"shTooltip"],[1,"tooltip-status-content"],["shButton","","size","small",3,"click","color"],[1,"tooltip-file-status-text"],["shButton",""]]},template:function(n,e){if(n&1&&(s(0,"div",7),u(1,"app-mobile-menu-toggle"),s(2,"div",8),p(3,rt,4,4)(4,ct,5,8,"div",9)(5,Tt,2,0,"div",9)(6,ut,3,4,"div",10),l(),s(7,"div",11)(8,"div",12),p(9,St,1,0,"app-remote-connectivity-status"),p(10,gt,2,1),s(11,"button",13),c("click",function(){return e.pauseResume()}),C(12,1),p(13,mt,2,0)(14,Ct,2,0),F(),l(),s(15,"button",13),c("click",function(){return e.openThrottleSettingsDialog()}),s(16,"sh-icon"),d(17,"speedometer"),l()()(),s(18,"div",14)(19,"sh-menu")(20,"button",15),p(21,Ft,1,0,"app-remote-connectivity-status",16),s(22,"sh-icon"),d(23,"dots-three-vertical-bold"),l()(),ae(24,17),p(25,Et,1,0,"app-remote-connectivity-status",18),p(26,Ot,4,2,"button"),s(27,"button",19),c("click",function(){return e.pauseResume()}),s(28,"sh-icon"),d(29),l(),d(30),l(),s(31,"button",19),c("click",function(){return e.openThrottleSettingsDialog()}),s(32,"sh-icon"),d(33,"speedometer"),l(),d(34," Throttle Settings "),l(),se(),l()()()()),n&2){let o;_(3),g((o=e.serverState())!=null&&o.ActiveTask&&(!((o=e.statusData())==null||o.task==null)&&o.task.Status)&&((o=e.statusData())==null||o.task==null?null:o.task.Status)!=="Completed"?3:e.nextBackup().backup||e.nextBackup().time?4:(o=e.serverState())!=null&&o.ActiveTask?6:5),_(6),g(!e.isUsingRelay()&&!e.hideConsoleConnectionStatus()?9:-1),_(),g(e.runningTask()?10:-1),_(),G("loading",e.isResuming()),_(2),g(e.clientIsRunning()?13:14),_(8),g(!e.isUsingRelay()&&!e.hideConsoleConnectionStatus()?21:-1),_(4),g(!e.isUsingRelay()&&!e.hideConsoleConnectionStatus()?25:-1),_(),g(e.runningTask()?26:-1),_(3),U(e.clientIsRunning()?"pause":"play"),_(),w(" ",e.clientIsRunning()?"Pause":"Resume"," ")}},dependencies:[k,I,h,Ie,Ae,V,Re,z,$e,me],styles:["[_nghost-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:1rem;min-height:3.875rem;border-bottom:1px solid var(--base-4);position:sticky;top:0;z-index:2000;background:var(--base-1)}[_nghost-%COMP%]:has(sh-progress-bar){padding:1rem 1rem 1.5rem}.file-status-text[_ngcontent-%COMP%]{color:var(--base-8)}.file-status-text[_ngcontent-%COMP%]:empty{display:none}.tooltip-file-status-text[_ngcontent-%COMP%]{overflow-wrap:break-word;word-break:break-word;display:inline-block;margin-bottom:.25rem}.tooltip-status-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.current-backup[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:100%;gap:.5rem}.current-backup-progress[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:0;min-width:18.75rem;flex:1 0}.current-backup-progress[_ngcontent-%COMP%] sh-progress-bar[_ngcontent-%COMP%]{position:absolute;bottom:0;left:0;right:0;width:100%;max-width:initial}.current-backup-progress[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem}.current-backup-actions[_ngcontent-%COMP%], .current-backup-actions[_ngcontent-%COMP%] .desktop-actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}@media only screen and (max-width:768px){.current-backup-actions[_ngcontent-%COMP%] .desktop-actions[_ngcontent-%COMP%]{display:none}}.current-backup-actions[_ngcontent-%COMP%] .mobile-actions[_ngcontent-%COMP%]{display:none}@media only screen and (max-width:768px){.current-backup-actions[_ngcontent-%COMP%] .mobile-actions[_ngcontent-%COMP%]{display:flex}}.current-backup-actions[_ngcontent-%COMP%] .menu-mobile-toggle[_ngcontent-%COMP%]{position:relative}.current-backup-actions[_ngcontent-%COMP%] .menu-mobile-toggle[_ngcontent-%COMP%] app-remote-connectivity-status[_ngcontent-%COMP%]{position:absolute;top:-.25rem;right:-.25rem}.label-loading[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:.25rem}.menu-status-item[_ngcontent-%COMP%]{padding:.5rem 1rem;display:flex;flex-direction:column;gap:.25rem;border-bottom:1px solid var(--base-4);margin-bottom:.25rem}.menu-status-item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem;font-size:.875rem}"],changeDetection:0})};export{ne as a};
@@ -0,0 +1 @@
1
+ import{a as A}from"./chunk-5MKFV3IB.js";import"./chunk-7MPZ3MRD.js";import"./chunk-CTQKCCGM.js";import"./chunk-23UYU3M3.js";import"./chunk-GGW26MAG.js";import"./chunk-FJFREVRV.js";import"./chunk-OWBBT5WF.js";import"./chunk-6Q6SSTBK.js";import"./chunk-EG3PT3XW.js";import"./chunk-O3GGVB2B.js";import"./chunk-OAAXQ2BE.js";import"./chunk-7E5J43IH.js";import"./chunk-QY5UGQ3R.js";import"./chunk-3MS6SVET.js";import"./chunk-4VYR5E5I.js";import"./chunk-KLAJGS5T.js";import"./chunk-NGKFJLI2.js";import"./chunk-KUX6NGQU.js";import{U as S}from"./chunk-Y46QCSB5.js";import"./chunk-JJY6UOEY.js";import{c as u,e as N,f as c}from"./chunk-2K74TI2N.js";import"./chunk-G3FMV74P.js";import"./chunk-LU7RSOI6.js";import"./chunk-VLMNSWR3.js";import"./chunk-VKNFRCHQ.js";import{Cb as e,Db as t,Eb as T,Ub as n,fb as g}from"./chunk-QY4Y5NJB.js";import"./chunk-7CGTOI24.js";var l=class s{static \u0275fac=function(o){return new(o||s)};static \u0275cmp=g({type:s,selectors:[["app-about"]],decls:19,vars:0,consts:()=>{let i;i=$localize`General`;let o;o=$localize`Changelog`;let r;r=$localize`Libraries`;let C;C=$localize`System info`;let a;a=$localize`Server settings`;let E;E=$localize`Logs`;let O;return O=$localize`Crash log`,[i,o,r,C,a,E,O,[1,"content"],[1,"primary"],["tab","","routerLink","/about/general","routerLinkActive","active"],["tab","","routerLink","/about/changelog","routerLinkActive","active"],["tab","","routerLink","/about/libraries","routerLinkActive","active"],["tab","","routerLink","/about/system-info","routerLinkActive","active"],["tab","","routerLink","/about/server-settings","routerLinkActive","active"],["tab","","routerLink","/about/logs","routerLinkActive","active"],["tab","","routerLink","/about/crashlogs","routerLinkActive","active"]]},template:function(o,r){o&1&&(T(0,"app-status-bar"),e(1,"div",7)(2,"sh-tabs",8)(3,"button",9),n(4,0),t(),e(5,"button",10),n(6,1),t(),e(7,"button",11),n(8,2),t(),e(9,"button",12),n(10,3),t(),e(11,"button",13),n(12,4),t(),e(13,"button",14),n(14,5),t(),e(15,"button",15),n(16,6),t()(),e(17,"section"),T(18,"router-outlet"),t()())},dependencies:[A,S,u,N,c],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:0}.content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem 0}.content[_ngcontent-%COMP%] sh-tabs[_ngcontent-%COMP%]{margin:0 2rem 2rem}.content[_ngcontent-%COMP%] section[_ngcontent-%COMP%]{padding:0}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:2rem}"],changeDetection:0})};export{l as default};
@@ -1 +1 @@
1
- import{b as u}from"./chunk-BFTGDQ4K.js";import{c as m}from"./chunk-CFNARBNK.js";import{C as o,E as p,M as h,R as N,W as r,l as c,la as s,na as l,v as f,z as d}from"./chunk-26Z7TPJB.js";var b=class a{#e=r(m);#o=r(u);serverState=this.#o.serverState;serverStateEffect=l(()=>{let t=this.#o.serverState();t?.LastNotificationUpdateID&&this.updateLastNotificationEventId(t?.LastNotificationUpdateID)});#s=-1;#a=s(!1);#t=s([]);#i=s([]);notifications=this.#t.asReadonly();init(){this.notifications().length===0&&this.getNotifications()}updateLastNotificationEventId(t){this.#s!==t&&(this.#s=t,this.getNotifications())}getNotifications(){this.#a.set(!0),this.#e.getApiV1Notifications().pipe(o(1),h(t=>this.#t.set(t)),p(()=>this.#a.set(!1))).subscribe()}getNofication(t){this.#e.getApiV1NotificationById({id:t}).pipe(o(1)).subscribe()}deleteNotification(t){let i=this.#t(),e=i[t];this.#i.set(i),i.splice(t,1),this.#t.set(i),this.#e.deleteApiV1NotificationById({id:e.ID}).pipe(o(1)).subscribe({error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}deleteAllNotifications(){let t=this.#t();this.#i.set(t),this.#t.set([]);let i=t.map(e=>this.#e.deleteApiV1NotificationById({id:e.ID}).pipe(d(()=>c(e))));f(i).pipe(o(1)).subscribe({next:e=>{let g=e.filter(n=>n!=null&&"ID"in n);this.#t.set(g),this.#i.set([])},error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}static \u0275fac=function(i){return new(i||a)};static \u0275prov=N({token:a,factory:a.\u0275fac,providedIn:"root"})};export{b as a};
1
+ import{b as u}from"./chunk-23UYU3M3.js";import{d as m}from"./chunk-JJY6UOEY.js";import{C as o,E as p,M as h,U as N,Z as r,l as c,oa as s,qa as l,v as f,z as d}from"./chunk-QY4Y5NJB.js";var b=class a{#e=r(m);#o=r(u);serverState=this.#o.serverState;serverStateEffect=l(()=>{let t=this.#o.serverState();t?.LastNotificationUpdateID&&this.updateLastNotificationEventId(t?.LastNotificationUpdateID)});#s=-1;#a=s(!1);#t=s([]);#i=s([]);notifications=this.#t.asReadonly();init(){this.notifications().length===0&&this.getNotifications()}updateLastNotificationEventId(t){this.#s!==t&&(this.#s=t,this.getNotifications())}getNotifications(){this.#a.set(!0),this.#e.getApiV1Notifications().pipe(o(1),h(t=>this.#t.set(t)),p(()=>this.#a.set(!1))).subscribe()}getNofication(t){this.#e.getApiV1NotificationById({id:t}).pipe(o(1)).subscribe()}deleteNotification(t){let i=this.#t(),e=i[t];this.#i.set(i),i.splice(t,1),this.#t.set(i),this.#e.deleteApiV1NotificationById({id:e.ID}).pipe(o(1)).subscribe({error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}deleteAllNotifications(){let t=this.#t();this.#i.set(t),this.#t.set([]);let i=t.map(e=>this.#e.deleteApiV1NotificationById({id:e.ID}).pipe(d(()=>c(e))));f(i).pipe(o(1)).subscribe({next:e=>{let g=e.filter(n=>n!=null&&"ID"in n);this.#t.set(g),this.#i.set([])},error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}static \u0275fac=function(i){return new(i||a)};static \u0275prov=N({token:a,factory:a.\u0275fac,providedIn:"root"})};export{b as a};
@@ -0,0 +1 @@
1
+ import{B as v}from"./chunk-Y46QCSB5.js";import{Cb as i,Db as o,Lb as C,Pc as D,Sa as n,Tc as T,Uc as h,Yb as g,_b as l,ca as u,da as _,fb as x,mc as r,nc as m,vb as s,wb as d}from"./chunk-QY4Y5NJB.js";import{a as f}from"./chunk-7CGTOI24.js";function y(e,a){if(e&1&&(i(0,"p"),r(1),o()),e&2){let t=l();n(),m(t._data().message)}}function S(e,a){if(e&1){let t=C();i(0,"button",5),g("click",function(){u(t);let p=l();return _(p.close("cancel"))}),r(1),o()}if(e&2){let t=l();n(),m(t._data().cancelText)}}function k(e,a){if(e&1){let t=C();i(0,"button",6),g("click",function(){u(t);let p=l();return _(p.close("confirm"))}),r(1),o()}if(e&2){let t=l();n(),m(t._data().confirmText)}}var w={title:$localize`Are you sure?`,confirmText:void 0,cancelText:$localize`Cancel`},b=class e{data=h();_data=D(()=>f(f({},w),this.data()));closed=T();close(a="confirm"){this.closed.emit(a==="confirm")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=x({type:e,selectors:[["app-confirm-dialog"]],inputs:{data:[1,"data"]},outputs:{closed:"closed"},decls:8,vars:4,consts:[["header",""],["content",""],["footer",""],["shButton","",1,""],["shButton","",1,"raised","primary"],["shButton","",1,"",3,"click"],["shButton","",1,"raised","primary",3,"click"]],template:function(t,c){t&1&&(i(0,"header",0)(1,"h3"),r(2),o()(),i(3,"div",1),s(4,y,2,1,"p"),o(),i(5,"footer",2),s(6,S,2,1,"button",3),s(7,k,2,1,"button",4),o()),t&2&&(n(2),m(c._data().title),n(2),d(c._data().message?4:-1),n(2),d(c._data().cancelText?6:-1),n(),d(c._data().confirmText?7:-1))},dependencies:[v],styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})};export{b as a};
@@ -1,4 +1,4 @@
1
- import{b as be}from"./chunk-VDSX2M4H.js";import{c as xe}from"./chunk-CFNARBNK.js";import{c as fe}from"./chunk-5VE6P5U5.js";import"./chunk-PO3L6MKW.js";import"./chunk-7AVOHYTE.js";import"./chunk-KDSMLI73.js";import{Cb as he,Db as pe,Eb as ue,Jb as ge,La as ae,Pa as oe,Rb as ke,U as le,W as v,cb as ce,p as ie,wc as de}from"./chunk-26Z7TPJB.js";import{a as b,b as T}from"./chunk-7CGTOI24.js";function j(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var R=j();function Te(n){R=n}var P={exec:()=>null};function p(n,e=""){let r=typeof n=="string"?n:n.source,s={replace:(t,l)=>{let i=typeof l=="string"?l:l.source;return i=i.replace(x.caret,"$1"),r=r.replace(t,i),s},getRegex:()=>new RegExp(r,e)};return s}var Ne=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),x={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:n=>new RegExp(`^( {0,3}${n})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:n=>new RegExp(`^ {0,${Math.min(3,n-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:n=>new RegExp(`^ {0,${Math.min(3,n-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:n=>new RegExp(`^ {0,${Math.min(3,n-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:n=>new RegExp(`^ {0,${Math.min(3,n-1)}}#`),htmlBeginRegex:n=>new RegExp(`^ {0,${Math.min(3,n-1)}}<(?:[a-z].*>|!--)`,"i")},Oe=/^(?:[ \t]*(?:\n|$))+/,Ze=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,De=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,E=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,Ge=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,Q=/(?:[*+-]|\d{1,9}[.)])/,ze=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,Ae=p(ze).replace(/bull/g,Q).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),He=p(ze).replace(/bull/g,Q).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),F=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,je=/^[^\n]+/,U=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,Qe=p(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",U).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),Fe=p(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,Q).getRegex(),q="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",X=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,Ue=p("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",X).replace("tag",q).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),_e=p(F).replace("hr",E).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",q).getRegex(),Xe=p(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",_e).getRegex(),W={blockquote:Xe,code:Ze,def:Qe,fences:De,heading:Ge,hr:E,html:Ue,lheading:Ae,list:Fe,newline:Oe,paragraph:_e,table:P,text:je},me=p("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",E).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",q).getRegex(),We=T(b({},W),{lheading:He,table:me,paragraph:p(F).replace("hr",E).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",me).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",q).getRegex()}),Ve=T(b({},W),{html:p(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",X).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:P,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:p(F).replace("hr",E).replace("heading",` *#{1,6} *[^
1
+ import{b as be}from"./chunk-4VYR5E5I.js";import{d as xe}from"./chunk-JJY6UOEY.js";import{c as fe}from"./chunk-G3FMV74P.js";import"./chunk-LU7RSOI6.js";import"./chunk-VLMNSWR3.js";import"./chunk-VKNFRCHQ.js";import{Fb as he,Gb as pe,Hb as ue,Mb as ge,Oa as ae,Sa as oe,Ub as ke,X as le,Z as v,fb as ce,p as ie,zc as de}from"./chunk-QY4Y5NJB.js";import{a as b,b as T}from"./chunk-7CGTOI24.js";function j(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var R=j();function Te(n){R=n}var P={exec:()=>null};function p(n,e=""){let r=typeof n=="string"?n:n.source,s={replace:(t,l)=>{let i=typeof l=="string"?l:l.source;return i=i.replace(x.caret,"$1"),r=r.replace(t,i),s},getRegex:()=>new RegExp(r,e)};return s}var Ne=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),x={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:n=>new RegExp(`^( {0,3}${n})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:n=>new RegExp(`^ {0,${Math.min(3,n-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:n=>new RegExp(`^ {0,${Math.min(3,n-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:n=>new RegExp(`^ {0,${Math.min(3,n-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:n=>new RegExp(`^ {0,${Math.min(3,n-1)}}#`),htmlBeginRegex:n=>new RegExp(`^ {0,${Math.min(3,n-1)}}<(?:[a-z].*>|!--)`,"i")},Oe=/^(?:[ \t]*(?:\n|$))+/,Ze=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,De=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,E=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,Ge=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,Q=/(?:[*+-]|\d{1,9}[.)])/,ze=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,Ae=p(ze).replace(/bull/g,Q).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),He=p(ze).replace(/bull/g,Q).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),F=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,je=/^[^\n]+/,U=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,Qe=p(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",U).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),Fe=p(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,Q).getRegex(),q="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",X=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,Ue=p("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",X).replace("tag",q).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),_e=p(F).replace("hr",E).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",q).getRegex(),Xe=p(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",_e).getRegex(),W={blockquote:Xe,code:Ze,def:Qe,fences:De,heading:Ge,hr:E,html:Ue,lheading:Ae,list:Fe,newline:Oe,paragraph:_e,table:P,text:je},me=p("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",E).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",q).getRegex(),We=T(b({},W),{lheading:He,table:me,paragraph:p(F).replace("hr",E).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",me).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",q).getRegex()}),Ve=T(b({},W),{html:p(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",X).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:P,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:p(F).replace("hr",E).replace("heading",` *#{1,6} *[^
2
2
  ]`).replace("lheading",Ae).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()}),Je=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,Ke=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,Ce=/^( {2,}|\\)\n(?!\s*$)/,Ye=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,N=/[\p{P}\p{S}]/u,V=/[\s\p{P}\p{S}]/u,Pe=/[^\s\p{P}\p{S}]/u,et=p(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,V).getRegex(),Ee=/(?!~)[\p{P}\p{S}]/u,tt=/(?!~)[\s\p{P}\p{S}]/u,rt=/(?:[^\s\p{P}\p{S}]|~)/u,nt=p(/link|precode-code|html/,"g").replace("link",/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",Ne?"(?<!`)()":"(^^|[^`])").replace("code",/(?<b>`+)[^`]+\k<b>(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),ve=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,st=p(ve,"u").replace(/punct/g,N).getRegex(),it=p(ve,"u").replace(/punct/g,Ee).getRegex(),Ie="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",lt=p(Ie,"gu").replace(/notPunctSpace/g,Pe).replace(/punctSpace/g,V).replace(/punct/g,N).getRegex(),at=p(Ie,"gu").replace(/notPunctSpace/g,rt).replace(/punctSpace/g,tt).replace(/punct/g,Ee).getRegex(),ot=p("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,Pe).replace(/punctSpace/g,V).replace(/punct/g,N).getRegex(),ct=p(/\\(punct)/,"gu").replace(/punct/g,N).getRegex(),ht=p(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[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])?)+(?![-_])/).getRegex(),pt=p(X).replace("(?:-->|$)","-->").getRegex(),ut=p("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",pt).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),L=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/,gt=p(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",L).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Le=p(/^!?\[(label)\]\[(ref)\]/).replace("label",L).replace("ref",U).getRegex(),Be=p(/^!?\[(ref)\](?:\[\])?/).replace("ref",U).getRegex(),kt=p("reflink|nolink(?!\\()","g").replace("reflink",Le).replace("nolink",Be).getRegex(),we=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,J={_backpedal:P,anyPunctuation:ct,autolink:ht,blockSkip:nt,br:Ce,code:Ke,del:P,emStrongLDelim:st,emStrongRDelimAst:lt,emStrongRDelimUnd:ot,escape:Je,link:gt,nolink:Be,punctuation:et,reflink:Le,reflinkSearch:kt,tag:ut,text:Ye,url:P},dt=T(b({},J),{link:p(/^!?\[(label)\]\((.*?)\)/).replace("label",L).getRegex(),reflink:p(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",L).getRegex()}),D=T(b({},J),{emStrongRDelimAst:at,emStrongLDelim:it,url:p(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol",we).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:p(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol",we).getRegex()}),ft=T(b({},D),{br:p(Ce).replace("{2,}","*").getRegex(),text:p(D.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()}),I={normal:W,gfm:We,pedantic:Ve},A={normal:J,gfm:D,breaks:ft,pedantic:dt},xt={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},ye=n=>xt[n];function S(n,e){if(e){if(x.escapeTest.test(n))return n.replace(x.escapeReplace,ye)}else if(x.escapeTestNoEncode.test(n))return n.replace(x.escapeReplaceNoEncode,ye);return n}function Se(n){try{n=encodeURI(n).replace(x.percentDecode,"%")}catch{return null}return n}function $e(n,e){let r=n.replace(x.findPipe,(l,i,o)=>{let a=!1,h=i;for(;--h>=0&&o[h]==="\\";)a=!a;return a?"|":" |"}),s=r.split(x.splitPipe),t=0;if(s[0].trim()||s.shift(),s.length>0&&!s.at(-1)?.trim()&&s.pop(),e)if(s.length>e)s.splice(e);else for(;s.length<e;)s.push("");for(;t<s.length;t++)s[t]=s[t].trim().replace(x.slashPipe,"|");return s}function _(n,e,r){let s=n.length;if(s===0)return"";let t=0;for(;t<s;){let l=n.charAt(s-t-1);if(l===e&&!r)t++;else if(l!==e&&r)t++;else break}return n.slice(0,s-t)}function bt(n,e){if(n.indexOf(e[1])===-1)return-1;let r=0;for(let s=0;s<n.length;s++)if(n[s]==="\\")s++;else if(n[s]===e[0])r++;else if(n[s]===e[1]&&(r--,r<0))return s;return r>0?-2:-1}function Re(n,e,r,s,t){let l=e.href,i=e.title||null,o=n[1].replace(t.other.outputLinkReplace,"$1");s.state.inLink=!0;let a={type:n[0].charAt(0)==="!"?"image":"link",raw:r,href:l,title:i,text:o,tokens:s.inlineTokens(o)};return s.state.inLink=!1,a}function mt(n,e,r){let s=n.match(r.other.indentCodeCompensation);if(s===null)return e;let t=s[1];return e.split(`
3
3
  `).map(l=>{let i=l.match(r.other.beginningSpace);if(i===null)return l;let[o]=i;return o.length>=t.length?l.slice(t.length):l}).join(`
4
4
  `)}var B=class{options;rules;lexer;constructor(n){this.options=n||R}space(n){let e=this.rules.block.newline.exec(n);if(e&&e[0].length>0)return{type:"space",raw:e[0]}}code(n){let e=this.rules.block.code.exec(n);if(e){let r=e[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?r:_(r,`
@@ -0,0 +1 @@
1
+ import{a as Y}from"./chunk-3QS6DB3O.js";import{a as W}from"./chunk-QY5UGQ3R.js";import{e as U}from"./chunk-KUX6NGQU.js";import{B as j,D as B,H as Q,b as $,c as A,d as v,e as k,f as x,j as J,p as X,q as V,r as q,t as z,v as H,w as K}from"./chunk-Y46QCSB5.js";import"./chunk-JJY6UOEY.js";import{d as R}from"./chunk-2K74TI2N.js";import"./chunk-G3FMV74P.js";import"./chunk-LU7RSOI6.js";import"./chunk-VLMNSWR3.js";import"./chunk-VKNFRCHQ.js";import{Bb as h,Cb as o,Db as i,E as S,Eb as r,Lb as M,Sa as l,Sb as g,Tb as d,Ub as O,Vc as y,Yb as C,Z as p,ca as F,da as f,fb as L,fc as P,gc as w,jc as b,mc as G,nc as D,oa as a,qa as T,vb as I,wb as E}from"./chunk-QY4Y5NJB.js";import"./chunk-7CGTOI24.js";var Z=["passwordInput"];function ee(m,t){m&1&&(o(0,"sh-alert",6),O(1,4),i())}var _=new q,N=class m{#e=p(R);#n=p(U);rememberMe=W("rememberMe",!1,!0);failedLogin=a(!1);successLogin=a(!1);isLoading=a(!1);loginForm=_.group({user:_.control(""),pass:_.control("",v.required),rememberMe:_.control(this.rememberMe())});showPassword=a(!1);passwordInput=y("passwordInput");passwordEffect=T(()=>{this.failedLogin()&&queueMicrotask(()=>this.passwordInput()?.nativeElement?.focus())});ngOnInit(){this.loginForm.controls.rememberMe.valueChanges.subscribe(t=>this.rememberMe.set(t??!1)),queueMicrotask(()=>this.passwordInput()?.nativeElement?.focus())}submit(){let t=this.loginForm.value.pass,n=this.loginForm.value.user;this.rememberMe.set(this.loginForm.value.rememberMe??!1),!n&&t&&(this.isLoading.set(!0),this.#n.login(t,this.rememberMe()).pipe(S(()=>{this.isLoading.set(!1),this.failedLogin.set(!0)})).subscribe({next:()=>{this.successLogin.set(!0),this.#e.navigate(["/"])}}))}static \u0275fac=function(n){return new(n||m)};static \u0275cmp=L({type:m,selectors:[["app-login"]],viewQuery:function(n,e){n&1&&P(e.passwordInput,Z,5),n&2&&w()},decls:24,vars:6,consts:()=>{let t;t=$localize`Enter your password`;let n;n=$localize` Password ${"\uFFFD#10\uFFFD"}:START_LINK:${"\uFFFD#11\uFFFD"}:START_TAG_SH_ICON:question${"\uFFFD/#11\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#10\uFFFD"}:CLOSE_LINK:`;let e;e=$localize` Login ${"\uFFFD#18\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#18\uFFFD"}:CLOSE_TAG_SH_ICON:`;let s;s=$localize` Keep me logged in ${"\uFFFD#21\uFFFD\uFFFD/#21\uFFFD"}:TAG_INPUT:`;let c;return c=$localize` Remember to enter a password, if you can't remember the password open the duplicati client on the machine in question and make sure you open it through the tray icon then go into settings to change the password. `,[["passwordInput",""],n,e,s,c,[3,"submit","formGroup"],["type","warning"],[1,"logo-login"],[1,"inner"],[1,"login-row"],["type","text","hidden","","autocomplete","off","name","username","formControlName","user"],["for","password"],["href","https://docs.duplicati.com/detailed-descriptions/duplicati-access-password","target","_blank","rel","noopener noreferrer"],["name","password","autocomplete","current-password","placeholder",t,"tabindex","1","formControlName","pass",3,"type"],["suffix","",3,"click"],["shButton","","type","submit",1,"raised","primary","login-button"],[1,"raised","primary"],["type","checkbox","id","rememberMe","tabindex","2","formControlName","rememberMe"],[1,"login-row","checkbox"],["for","rememberMe",1,"remember-me"]]},template:function(n,e){if(n&1){let s=M();o(0,"form",5),C("submit",function(){return F(s),f(e.submit())}),I(1,ee,2,0,"sh-alert",6),o(2,"div",7),r(3,"app-logo"),i(),o(4,"div",8)(5,"div",9),r(6,"input",10),o(7,"sh-form-field")(8,"label",11),g(9,1),o(10,"a",12),r(11,"sh-icon"),i(),d(),i(),r(12,"input",13,0),o(14,"sh-icon",14),C("click",function(){return F(s),f(e.showPassword.set(!e.showPassword()))}),G(15),i()(),o(16,"button",15),g(17,2),r(18,"sh-icon"),d(),i()(),o(19,"sh-checkbox",16),g(20,3),r(21,"input",17),d(),i(),o(22,"div",18),r(23,"label",19),i()()()}n&2&&(h("formGroup",e.loginForm),l(),E(e.failedLogin()&&!e.successLogin()?1:-1),l(11),h("type",e.showPassword()?"text":"password"),l(3),D(e.showPassword()?"eye":"eye-slash"),l(),b("loading",e.isLoading()))},dependencies:[z,J,A,$,k,x,V,X,Y,Q,H,j,K,B],styles:["[_nghost-%COMP%]{display:block}form[_ngcontent-%COMP%]{width:100vw;min-height:100vh;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.75rem}form[_ngcontent-%COMP%] .inner[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;gap:1rem}form[_ngcontent-%COMP%] .inner[_ngcontent-%COMP%] .checkbox[_ngcontent-%COMP%]{align-self:flex-start}sh-alert[_ngcontent-%COMP%]{max-width:20rem;margin:0 auto}h3[_ngcontent-%COMP%]{font:var(--title-30)}.login-row[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.5rem}.logo-login[_ngcontent-%COMP%]{top:0;left:0;padding:1.25rem;position:fixed}.login-button[_ngcontent-%COMP%]{padding-left:1.5rem;padding-right:1.5rem}"],changeDetection:0})};export{N as default};
@@ -0,0 +1 @@
1
+ import{B as G,D as L,M as D,s as I,w as h}from"./chunk-Y46QCSB5.js";import{d as b}from"./chunk-JJY6UOEY.js";import{Ab as g,Cb as n,Db as o,E as d,Lb as N,Sa as r,Tc as R,Ub as s,Yb as u,Z as T,_b as E,ca as O,da as C,fb as P,jc as p,mc as f,oa as l,oc as M,xb as A,zb as m}from"./chunk-QY4Y5NJB.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("loading",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};
@@ -0,0 +1 @@
1
+ import{a}from"./chunk-SIMG6PGZ.js";import"./chunk-GTZRHPRV.js";import"./chunk-Y46QCSB5.js";import"./chunk-JJY6UOEY.js";import"./chunk-LU7RSOI6.js";import"./chunk-VLMNSWR3.js";import"./chunk-VKNFRCHQ.js";import"./chunk-QY4Y5NJB.js";import"./chunk-7CGTOI24.js";export{a as default};
@@ -0,0 +1 @@
1
+ import{a as Xe}from"./chunk-5MKFV3IB.js";import"./chunk-7MPZ3MRD.js";import"./chunk-CTQKCCGM.js";import{a as ee}from"./chunk-WLAJ3YIP.js";import"./chunk-23UYU3M3.js";import{a as Ke}from"./chunk-GGW26MAG.js";import"./chunk-FJFREVRV.js";import"./chunk-OWBBT5WF.js";import"./chunk-6Q6SSTBK.js";import{a as Z}from"./chunk-EG3PT3XW.js";import"./chunk-O3GGVB2B.js";import"./chunk-OAAXQ2BE.js";import"./chunk-7E5J43IH.js";import"./chunk-QY5UGQ3R.js";import"./chunk-3MS6SVET.js";import{b as Je,c as ce}from"./chunk-4VYR5E5I.js";import"./chunk-KLAJGS5T.js";import"./chunk-NGKFJLI2.js";import"./chunk-KUX6NGQU.js";import{B as se,E as Be,G as be,L as Fe,U as ke,V as Ue,v as H}from"./chunk-Y46QCSB5.js";import{d as de}from"./chunk-JJY6UOEY.js";import{b as ye,e as xe}from"./chunk-2K74TI2N.js";import"./chunk-G3FMV74P.js";import"./chunk-LU7RSOI6.js";import{fa as V,ia as re}from"./chunk-VLMNSWR3.js";import"./chunk-VKNFRCHQ.js";import{Ab as U,Bb as I,Cb as _,Db as i,Eb as s,Fc as u,Gc as L,Hc as S,Ib as P,Ic as v,Jb as A,Lb as K,Pc as ve,Sa as a,Sb as N,Tb as m,Ub as l,Uc as le,Vb as d,Wb as c,Xb as R,Yb as $,Z as B,_b as E,ca as D,da as M,fb as w,jc as f,mc as C,nc as J,oa as G,oc as h,p as X,pc as Ie,qc as $e,uc as fe,vb as g,vc as he,wb as T,wc as z,xb as b,zb as k}from"./chunk-QY4Y5NJB.js";import{a as _e}from"./chunk-7CGTOI24.js";function Ve(n,t){n&1&&s(0,"sh-progress-bar",32)}function He(n,t){n&1&&s(0,"div",35)}function We(n,t){n&1&&s(0,"div",35)}function je(n,t){n&1&&s(0,"div",36)}function qe(n,t){n&1&&s(0,"div",37)}function Qe(n,t){if(n&1&&(_(0,"details",46)(1,"summary"),N(2,15),s(3,"sh-icon"),_(4,"div",48),s(5,"sh-icon",40),i(),m(),i(),_(6,"div",49)(7,"p"),l(8,16),u(9,"date"),i(),_(10,"p"),l(11,17),u(12,"date"),i(),_(13,"p"),l(14,18),u(15,"durationFormat"),i(),_(16,"p"),l(17,19),i(),s(18,"sh-divider"),_(19,"p"),l(20,20),i(),_(21,"p"),l(22,21),i()()(),_(23,"details",46)(24,"summary"),N(25,22),s(26,"sh-icon"),_(27,"div",48),s(28,"sh-icon",40),i(),m(),i(),_(29,"div",49)(30,"p"),l(31,23),u(32,"date"),i(),_(33,"p"),l(34,24),u(35,"date"),i(),_(36,"p"),l(37,25),u(38,"durationFormat"),i(),s(39,"sh-divider"),_(40,"p"),l(41,26),u(42,"bytes"),i(),_(43,"p"),l(44,27),u(45,"bytes"),i(),_(46,"p"),l(47,28),u(48,"bytes"),i(),s(49,"sh-divider"),_(50,"p"),l(51,29),i(),_(52,"p"),l(53,30),i()()()),n&2){let e=E(2).$implicit;a(9),d(S(9,17,e.data==null||e.data.TestResults==null?null:e.data.TestResults.BeginTime,"medium")),c(8),a(3),d(S(12,20,e.data==null||e.data.TestResults==null?null:e.data.TestResults.EndTime,"medium")),c(11),a(3),d(L(15,23,e.data==null||e.data.TestResults==null?null:e.data.TestResults.Duration)),c(14),a(2),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.VerificationsActualLength),c(17),a(3),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.WarningsActualLength),c(20),a(2),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.ErrorsActualLength),c(22),a(10),d(S(32,25,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.BeginTime,"medium")),c(31),a(3),d(S(35,28,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.EndTime,"medium")),c(34),a(3),d(L(38,31,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.Duration)),c(37),a(4),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DeletedFileCount)(v(42,33,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DeletedFileSize,!0,!0)),c(41),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DownloadedFileCount)(v(45,37,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DownloadedFileSize,!0,!0)),c(44),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.UploadedFileCount)(v(48,41,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.UploadedFileSize,!0,!0)),c(47),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.WarningsActualLength),c(51),a(2),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.ErrorsActualLength),c(53)}}function Ye(n,t){if(n&1&&(_(0,"code"),C(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),J(L(2,1,e))}}function Ze(n,t){if(n&1&&(_(0,"details",46)(1,"summary"),N(2,31),s(3,"sh-icon"),_(4,"div",48),s(5,"sh-icon",40),i(),m(),i(),_(6,"div",49),k(7,Ye,3,3,"code",null,b),i()()),n&2){let e=E(2).$implicit;a(5),d(e.data.VerificationsActualLength),c(2),a(2),U(e.data.Verifications)}}function en(n,t){if(n&1&&(_(0,"code"),C(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),J(L(2,1,e))}}function nn(n,t){n&1&&(_(0,"p"),C(1,"No errors"),i())}function tn(n,t){if(n&1&&(_(0,"code"),C(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),J(L(2,1,e))}}function on(n,t){if(n&1&&(_(0,"section",41)(1,"sh-toggle-card",42),P(2,43),_(3,"h3"),l(4,0),i(),A(),P(5,44),_(6,"p"),l(7,1),u(8,"date"),i(),_(9,"p"),l(10,2),u(11,"date"),i(),_(12,"p"),l(13,3),u(14,"durationFormat"),i(),A(),i(),_(15,"sh-toggle-card",42),P(16,43),_(17,"h3"),l(18,4),i(),A(),P(19,44),_(20,"p"),l(21,5),u(22,"bytes"),i(),_(23,"p"),l(24,6),u(25,"bytes"),i(),_(26,"p"),l(27,7),u(28,"bytes"),i(),_(29,"p"),l(30,8),u(31,"bytes"),i(),_(32,"p"),l(33,9),i(),_(34,"p"),l(35,10),i(),_(36,"p"),l(37,11),i(),A(),i(),_(38,"div",45),s(39,"sh-divider"),g(40,Qe,54,45),g(41,Ze,9,1,"details",46),_(42,"details",47)(43,"summary"),N(44,12),s(45,"sh-icon"),_(46,"div",48),s(47,"sh-icon",40),i(),m(),i(),_(48,"div",49),k(49,en,3,3,"code",null,b),i()(),_(51,"details",47)(52,"summary"),N(53,13),s(54,"sh-icon"),_(55,"div",48),s(56,"sh-icon",40),i(),m(),i(),_(57,"div",49),g(58,nn,2,0,"p"),k(59,tn,3,3,"code",null,b),i()(),s(61,"sh-divider"),_(62,"details")(63,"summary"),N(64,14),s(65,"sh-icon"),_(66,"div",48),s(67,"sh-icon",40),i(),m(),i(),_(68,"code")(69,"button",50),C(70,"Copy"),i(),C(71),u(72,"json"),i()()()()),n&2){let e=E().$implicit,o=E();a(),I("disableToggle",!0),a(7),d(S(8,24,e.data==null?null:e.data.BeginTime,"medium")),c(7),a(3),d(S(11,27,e.data==null?null:e.data.EndTime,"medium")),c(10),a(3),d(L(14,30,e.data==null?null:e.data.Duration)),c(13),a(),I("disableToggle",!0),a(7),d(e.data==null?null:e.data.ExaminedFiles)(v(22,32,e.data==null?null:e.data.SizeOfExaminedFiles,!0,!0)),c(21),a(3),d(e.data==null?null:e.data.OpenedFiles)(v(25,36,e.data==null?null:e.data.SizeOfOpenedFiles,!0,!0)),c(24),a(3),d(e.data==null?null:e.data.AddedFiles)(v(28,40,e.data==null?null:e.data.SizeOfAddedFiles,!0,!0)),c(27),a(3),d(e.data==null?null:e.data.ModifiedFiles)(v(31,44,e.data==null?null:e.data.SizeOfModifiedFiles,!0,!0)),c(30),a(2),d(e.data==null?null:e.data.DeletedFiles),c(33),a(2),d(e.data==null?null:e.data.TooLargeFiles),c(35),a(2),d(e.data==null?null:e.data.FilesWithError),c(37),a(3),T(e.data!=null&&e.data.TestResults?40:-1),a(),T((e.data==null?null:e.data.MainOperation)==="Test"?41:-1),a(),I("open",e.id===o.openEntry()&&o.openSection()==="warnings"),a(5),d(e.data==null?null:e.data.WarningsActualLength),c(44),a(2),U(e.data==null?null:e.data.Warnings),a(2),I("open",e.id===o.openEntry()&&o.openSection()==="errors"),a(5),d(e.data==null?null:e.data.ErrorsActualLength),c(53),a(2),T((e.data==null||e.data.Errors==null?null:e.data.Errors.length)===0?58:-1),a(),U(e.data==null?null:e.data.Errors),a(12),h(" ",L(72,48,e.data)," ")}}function an(n,t){if(n&1){let e=K();_(0,"article",33)(1,"header",34),$("click",function(){let r=D(e).$implicit,p=E();return M(p.toggleOpenEntry(r))}),g(2,He,1,0,"div",35)(3,We,1,0,"div",35)(4,je,1,0,"div",36)(5,qe,1,0,"div",37),_(6,"h3"),C(7),u(8,"date"),i(),_(9,"p"),C(10),i(),s(11,"div",38),_(12,"div",39)(13,"sh-icon",40),C(14,"caret-down"),i()()(),g(15,on,73,50,"section",41),i()}if(n&2){let e=t.$implicit,o=E(),r=(e.data==null?null:e.data.ParsedResult)||"Unknown";a(2),T(r=="Fatal"?2:r=="Error"?3:r=="Warning"?4:5),a(5),J(S(8,7,e.timestamp,"medium")),a(3),Ie(" ",e.data==null?null:e.data.MainOperation," ",o.getLocalizedSummary(e)," "),a(3),f("open",e.id===o.openEntry()),a(2),T(e.id===o.openEntry()?15:-1)}}var ue=class n{#e=B(de);#n=new Z;#t=new ee;backupId=le.required();openEntry=G(null);openSection=G(null);pagination=G({offset:0,pagesize:100});resource=ce({params:()=>_e({id:this.backupId()},this.pagination()),stream:({params:t})=>this.#e.getApiV1BackupByIdLog({id:t.id,pagesize:100}).pipe(X(e=>e.map(o=>({id:o.ID,operationId:o.OperationID,timestamp:o.Timestamp*1e3,type:o.Type,data:JSON.parse(o.Message),exception:JSON.stringify(o.Exception)==="{}"?null:o.Exception}))))});getLocalizedSummary(t){let e=t.data?.ErrorsActualLength??0,o=t.data?.WarningsActualLength??0,r=[];if(t.data?.MainOperation=="Backup"){if(t.data?.Duration){let p=this.#t.transform(t.data?.Duration,!0);p.startsWith("0h ")&&(p=p.slice(3)),p.startsWith("0m ")&&(p=p.slice(3)),r.push($localize`took ${p}`)}t.data?.BackendStatistics?.BytesUploaded&&r.push($localize`uploaded ${this.#n.transform(t.data?.BackendStatistics?.BytesUploaded)}`),t.data?.BackendStatistics?.KnownFileSize&&r.push($localize`backup size ${this.#n.transform(t.data?.BackendStatistics?.KnownFileSize)}`)}return e!==0&&r.push($localize`:@@errorCount:${e} error${e===1?"":"s"}`),o!==0&&r.push($localize`:@@warningCount:${o} warning${o===1?"":"s"}`),r.length===0?"":`(${r.join(", ")})`}toggleOpenEntry(t){let e=t.id;if(this.openEntry()===e){this.openEntry.set(null),this.openSection.set(null);return}let o=t.data?.ErrorsActualLength??0,r=t.data?.WarningsActualLength??0;o>0?this.openSection.set("errors"):r>0?this.openSection.set("warnings"):this.openSection.set(null),this.openEntry.set(e)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=w({type:n,selectors:[["app-general-log"]],inputs:{backupId:[1,"backupId"]},decls:3,vars:1,consts:()=>{let t;t=$localize`Time`;let e;e=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let o;o=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let r;r=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let p;p=$localize`Source files`;let y;y=$localize` Evaluated: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let x;x=$localize`Opened: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let W;W=$localize`Added: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let j;j=$localize` Modified: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let q;q=$localize`Deleted: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Q;Q=$localize`Too large: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Y;Y=$localize`Files with error: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let O;O=$localize`${"\uFFFD#45\uFFFD"}:START_TAG_SH_ICON:warning-circle${"[\uFFFD/#45\uFFFD|\uFFFD/#47\uFFFD]"}:CLOSE_TAG_SH_ICON: Warnings ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#46\uFFFD"}:START_TAG_DIV:${"\uFFFD#47\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#45\uFFFD|\uFFFD/#47\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#46\uFFFD"}:CLOSE_TAG_DIV:`,O=R(O);let ne;ne=$localize`${"\uFFFD#54\uFFFD"}:START_TAG_SH_ICON:warning${"[\uFFFD/#54\uFFFD|\uFFFD/#56\uFFFD]"}:CLOSE_TAG_SH_ICON: Errors ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#55\uFFFD"}:START_TAG_DIV:${"\uFFFD#56\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#54\uFFFD|\uFFFD/#56\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#55\uFFFD"}:CLOSE_TAG_DIV:`,ne=R(ne);let te;te=$localize`${"\uFFFD#65\uFFFD"}:START_TAG_SH_ICON:notepad${"[\uFFFD/#65\uFFFD|\uFFFD/#67\uFFFD]"}:CLOSE_TAG_SH_ICON: Complete log ${"\uFFFD#66\uFFFD"}:START_TAG_DIV:${"\uFFFD#67\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#65\uFFFD|\uFFFD/#67\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#66\uFFFD"}:CLOSE_TAG_DIV:`,te=R(te);let ie;ie=$localize`${"\uFFFD#3\uFFFD"}:START_TAG_SH_ICON:circle-half-tilt${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON: Test phase ${"\uFFFD#4\uFFFD"}:START_TAG_DIV:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_DIV:`,ie=R(ie);let Ce;Ce=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let ge;ge=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Te;Te=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Oe;Oe=$localize`Verifications: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Le;Le=$localize`Warnings: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Ne;Ne=$localize`Errors: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let oe;oe=$localize`${"\uFFFD#26\uFFFD"}:START_TAG_SH_ICON:file-archive${"[\uFFFD/#26\uFFFD|\uFFFD/#28\uFFFD]"}:CLOSE_TAG_SH_ICON: Compact phase ${"\uFFFD#27\uFFFD"}:START_TAG_DIV:${"\uFFFD#28\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#26\uFFFD|\uFFFD/#28\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#27\uFFFD"}:CLOSE_TAG_DIV:`,oe=R(oe);let me;me=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Se;Se=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Ge;Ge=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Pe;Pe=$localize` Deleted files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let Ae;Ae=$localize` Downloaded files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let Re;Re=$localize` Uploaded files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let De;De=$localize`Warnings: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Me;Me=$localize`Errors: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let ae;return ae=$localize`${"\uFFFD#3\uFFFD"}:START_TAG_SH_ICON:warning-circle${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON: Verifications ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#4\uFFFD"}:START_TAG_DIV:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_DIV:`,ae=R(ae),[t,e,o,r,p,y,x,W,j,q,Q,Y,O,ne,te,ie,Ce,ge,Te,Oe,Le,Ne,oe,me,Se,Ge,Pe,Ae,Re,De,Me,ae,[1,"indeterminate","primary"],[1,"log-entry"],[3,"click"],[1,"status","error"],[1,"status","warn"],[1,"status"],[1,"spacer"],[1,"action"],[1,"toggle-indicator"],[1,"log-content"],[3,"disableToggle"],["title",""],["content",""],[1,"extra-info"],["name","details"],["name","details",3,"open"],[1,"actions"],[1,"content"],["shButton","",1,"small"]]},template:function(e,o){e&1&&(g(0,Ve,1,0,"sh-progress-bar",32),k(1,an,16,10,"article",33,b)),e&2&&(T(o.resource.isLoading()?0:-1),a(),U(o.resource.value()))},dependencies:[Ue,be,Fe,se,H,Z,V,ee,re],styles:["[_nghost-%COMP%]{display:block}.log-entry[_ngcontent-%COMP%]{display:flex;flex-direction:column;cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;padding:1rem;border-bottom:1px solid var(--base-4);background-color:var(--base-1);cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]:hover{background-color:var(--base-2)}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-30);margin:0}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.toggle-indicator[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:1.25rem;transition:transform 125ms linear}.toggle-indicator.open[_ngcontent-%COMP%]{transform:rotate(180deg)}details[_ngcontent-%COMP%]{display:flex;flex-direction:column}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]{cursor:pointer;display:flex;align-items:center;gap:.5rem;padding:.75rem;border-radius:var(--shape-2);background-color:var(--base-2)}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]:focus{outline:none}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]:hover{background-color:var(--base-3)}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]::marker{font-size:0}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;flex:1 0;gap:.5rem;-webkit-user-select:none;user-select:none}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:2rem;transition:transform 125ms linear}details[open][_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{transform:rotate(180deg)}details[_ngcontent-%COMP%] .content[_ngcontent-%COMP%]{padding:.75rem 1rem 0;display:flex;flex-direction:column;gap:.75rem}details[_ngcontent-%COMP%] .content[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0}details[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{margin-top:.75rem;position:relative}details[_ngcontent-%COMP%] code[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{position:absolute;top:.75rem;right:.75rem}.extra-info[_ngcontent-%COMP%]{grid-column:1/-1;display:flex;flex-direction:column;gap:1rem}.extra-info[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;margin-bottom:.75rem}.extra-info[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{white-space:pre-wrap;padding:1rem;display:block;border-radius:var(--shape-2);background-color:var(--base-2)}.log-content[_ngcontent-%COMP%]{padding:1rem;display:grid;grid-template-columns:1fr 1fr;gap:1rem}.status[_ngcontent-%COMP%]{display:block;width:1rem;height:1rem;background-color:var(--success-8);border-radius:50%}.status.error[_ngcontent-%COMP%]{background-color:var(--error-8)}.status.warn[_ngcontent-%COMP%]{background-color:var(--warn-8)}"],changeDetection:0})};function _n(n,t){n&1&&s(0,"sh-progress-bar",1)}function ln(n,t){n&1&&(N(0,0,1),s(1,"sh-icon"),m())}function rn(n,t){n&1&&(N(0,0,2),s(1,"sh-icon"),m())}function sn(n,t){if(n&1){let e=K();_(0,"section",6)(1,"button",7),$("click",function(){D(e);let r=E(),p=r.$implicit,y=r.$index,x=E();return M(x.copyToClipboard(p.data,y))}),N(2,0),g(3,ln,2,0)(4,rn,2,0),m(),i(),_(5,"code"),C(6),u(7,"json"),i()()}if(n&2){let e=E(),o=e.$implicit,r=e.$index,p=E();a(),f("success",p.copiedFromIndex()===r),a(2),T(p.copiedFromIndex()===r?3:4),a(3),J(L(7,4,o.data))}}function Fn(n,t){if(n&1){let e=K();_(0,"article",2)(1,"header",3),$("click",function(){let r=D(e).$implicit,p=E();return M(p.toggleOpenEntry(r.id))}),_(2,"h3"),C(3),u(4,"date"),i(),_(5,"div",4)(6,"sh-icon",5),C(7,"caret-down"),i()()(),g(8,sn,8,6,"section",6),i()}if(n&2){let e=t.$implicit,o=E();a(3),$e("",S(4,6,e.timestamp,"medium"),": ",e.operation," ",e.path),a(3),f("open",e.id===o.openEntry()),a(2),T(e.id===o.openEntry()?8:-1)}}var pe=class n{#e=B(de);backupId=le.required();openEntry=G(null);pagination=G({offset:0,pagesize:100});copiedFromIndex=G(null);resource=ce({params:()=>_e({id:this.backupId()},this.pagination()),stream:({params:t})=>this.#e.getApiV1BackupByIdRemotelog({id:t.id,pagesize:100}).pipe(X(e=>e.map((o,r)=>({id:o.ID,operationId:o.OperationID,timestamp:o.Timestamp*1e3,operation:o.Operation,path:o.Path,data:typeof o.Data=="string"?JSON.parse(o.Data):null}))))});toggleOpenEntry(t){if(this.openEntry()===t){this.openEntry.set(null);return}this.openEntry.set(t)}copyToClipboard(t,e){let o=JSON.stringify(t,null,2);navigator.clipboard.writeText(o),this.copiedFromIndex.set(e),setTimeout(()=>{this.copiedFromIndex.set(null)},3e3)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=w({type:n,selectors:[["app-remote-log"]],inputs:{backupId:[1,"backupId"]},decls:3,vars:1,consts:()=>{let t;return t=$localize`${"\uFFFD*3:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:check${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Copied ${"\uFFFD/*3:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*4:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:copy${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Copy to clipboard ${"\uFFFD/*4:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,t=R(t),[t,[1,"indeterminate","primary"],[1,"log-entry"],[3,"click"],[1,"actions"],[1,"toggle-indicator"],[1,"log-content"],["shButton","",1,"small",3,"click"]]},template:function(e,o){e&1&&(g(0,_n,1,0,"sh-progress-bar",1),k(1,Fn,9,9,"article",2,b)),e&2&&(T(o.resource.isLoading()?0:-1),a(),U(o.resource.value()))},dependencies:[Fe,H,re,V],styles:["[_nghost-%COMP%]{display:block}.log-entry[_ngcontent-%COMP%]{display:flex;flex-direction:column}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.5rem;padding:1rem;border-bottom:1px solid var(--base-4);background-color:var(--base-1);cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]:hover{background-color:var(--base-2)}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-30);margin:0;-webkit-user-select:none;user-select:none}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.toggle-indicator[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:1.25rem;transition:transform 125ms linear}.toggle-indicator.open[_ngcontent-%COMP%]{transform:rotate(180deg)}.log-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem;position:relative}.log-content[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{position:absolute;top:2rem;right:2rem;background:transparent}code[_ngcontent-%COMP%]{white-space:pre-wrap;padding:1rem;display:block;border-radius:var(--shape-2);background-color:var(--base-2)}"],changeDetection:0})};function dn(n,t){if(n&1&&(C(0," - "),P(1),l(2,6),A(),C(3),u(4,"durationFormat")),n&2){E(2);let e=z(6);a(3),h(" ",L(4,1,e.Backup.Metadata==null?null:e.Backup.Metadata.LastBackupDuration)," ")}}function cn(n,t){n&1&&(P(0),l(1,7),A())}function un(n,t){if(n&1&&(C(0),u(1,"bytes")),n&2){E(2);let e=z(6);h(" ",L(1,1,e.Backup.Metadata==null?null:e.Backup.Metadata.SourceFilesSize)," ")}}function pn(n,t){n&1&&(P(0),l(1,8),A())}function En(n,t){if(n&1&&(C(0),u(1,"bytes")),n&2){E(2);let e=z(6);h(" ",L(1,1,e.Backup.Metadata==null?null:e.Backup.Metadata.TargetFilesSize)," ")}}function Cn(n,t){n&1&&(P(0),l(1,9),A())}function gn(n,t){if(n&1&&(_(0,"sh-chip",19),l(1,10),i()),n&2){E(2);let e=z(6);a(),d(e.Backup.Metadata==null?null:e.Backup.Metadata.BackupListCount),c(1)}}function Tn(n,t){n&1&&(_(0,"sh-chip",20),l(1,11),i())}function On(n,t){if(n&1&&(_(0,"div",14)(1,"div",18)(2,"h3"),C(3),_(4,"sh-icon"),C(5,"database"),i()(),_(6,"p")(7,"span"),l(8,3),i(),C(9),u(10,"date"),g(11,dn,5,3)(12,cn,2,0,"ng-container"),i(),_(13,"p")(14,"span"),l(15,4),i(),g(16,un,2,3)(17,pn,2,0,"ng-container"),i(),_(18,"p")(19,"span"),l(20,5),i(),g(21,En,2,3)(22,Cn,2,0,"ng-container"),i()(),g(23,gn,2,1,"sh-chip",19)(24,Tn,2,0,"sh-chip",20),i()),n&2){let e=E(),o=z(6);a(3),h(" ",o.Backup.Name??e.MISSING_BACKUP_NAME," "),a(6),h(" ",S(10,6,o.Backup.Metadata==null?null:o.Backup.Metadata.LastBackupDate,"short")," "),a(2),T(o.Backup.Metadata!=null&&o.Backup.Metadata.LastBackupDuration?11:12),a(5),T(o.Backup.Metadata!=null&&o.Backup.Metadata.SourceFilesSize?16:17),a(5),T(o.Backup.Metadata!=null&&o.Backup.Metadata.TargetFilesSize?21:22),a(2),T(o.Backup.Metadata!=null&&o.Backup.Metadata.BackupListCount?23:24)}}function Ln(n,t){if(n&1&&s(0,"app-general-log",17),n&2){let e=E();I("backupId",e.backupId())}}function Nn(n,t){if(n&1&&s(0,"app-remote-log",17),n&2){let e=E();I("backupId",e.backupId())}}var Ee=class n{#e=B(ye);#n=B(Ke);MISSING_BACKUP_NAME=$localize`Backup name missing`;activeTab=G("general");backupId=Je(this.#e.params.pipe(X(t=>t.id)));backup=ve(()=>{let t=this.backupId();return t?this.#n.getBackupById(t):null});static \u0275fac=function(e){return new(e||n)};static \u0275cmp=w({type:n,selectors:[["app-log"]],decls:15,vars:8,consts:()=>{let t;t=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON: Back `;let e;e=$localize`General`;let o;o=$localize` Destination `;let r;r=$localize`Last successful backup:`;let p;p=$localize`Source:`;let y;y=$localize`Destination:`;let x;x=$localize`took`;let W;W=$localize`N/A`;let j;j=$localize`N/A`;let q;q=$localize`N/A`;let Q;Q=$localize`${"\uFFFD0\uFFFD"}:INTERPOLATION: Version`;let Y;return Y=$localize`No version yet`,[t,e,o,r,p,y,x,W,j,q,Q,Y,[1,"back"],["type","button","shButton","","routerLink","/",1,"small"],[1,"backup"],[1,"primary"],["tab","",3,"click"],[3,"backupId"],[1,"text"],[1,"simple","success"],[1,"simple"]]},template:function(e,o){if(e&1){let r=K();s(0,"app-status-bar"),_(1,"section")(2,"div",12)(3,"button",13),N(4,0),s(5,"sh-icon"),m(),i()(),fe(6),g(7,On,25,9,"div",14),_(8,"sh-tabs",15)(9,"button",16),$("click",function(){return D(r),M(o.activeTab.set("general"))}),l(10,1),i(),_(11,"button",16),$("click",function(){return D(r),M(o.activeTab.set("destination"))}),l(12,2),i()(),g(13,Ln,1,1,"app-general-log",17),g(14,Nn,1,1,"app-remote-log",17),i()}if(e&2){a(6);let r=he(o.backup());a(),T(r?7:-1),a(2),f("active",o.activeTab()==="general"),a(2),f("active",o.activeTab()==="destination"),a(2),T(o.activeTab()==="general"?13:-1),a(),T(o.activeTab()==="destination"?14:-1)}},dependencies:[ke,ue,pe,xe,Xe,H,se,Be,Z,ee,V],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem 1.5rem;gap:1rem}sh-tabs[_ngcontent-%COMP%]{margin-bottom:1rem}.backup[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:2rem;gap:1rem;border:1px solid var(--base-4);border-radius:var(--shape-3);box-shadow:var(--box-shadow-10)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;width:100%;max-width:40%}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] h3[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{color:var(--base-8)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] p[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{color:var(--base-12)}"],changeDetection:0})};export{Ee as default};
@@ -0,0 +1 @@
1
+ import{a as St}from"./chunk-5MKFV3IB.js";import"./chunk-7MPZ3MRD.js";import"./chunk-CTQKCCGM.js";import{a as Ct,b as pt,c as mt,l as k,q as Tt}from"./chunk-AZEV3A4R.js";import"./chunk-RWDQ3L3C.js";import"./chunk-CAJQ2FEU.js";import{b as dt,c as ut,d as gt}from"./chunk-ZPIR5QIQ.js";import"./chunk-23UYU3M3.js";import{a as ct}from"./chunk-GGW26MAG.js";import"./chunk-FJFREVRV.js";import"./chunk-OWBBT5WF.js";import"./chunk-6Q6SSTBK.js";import"./chunk-EG3PT3XW.js";import"./chunk-O3GGVB2B.js";import"./chunk-OAAXQ2BE.js";import{a as R}from"./chunk-7E5J43IH.js";import"./chunk-QY5UGQ3R.js";import"./chunk-3MS6SVET.js";import"./chunk-4VYR5E5I.js";import"./chunk-KLAJGS5T.js";import"./chunk-NGKFJLI2.js";import"./chunk-KUX6NGQU.js";import{B as st,C as at,G as lt,H as rt,L as _t,c as Z,e as tt,i as et,s as nt,v as it,z as ot}from"./chunk-Y46QCSB5.js";import"./chunk-JJY6UOEY.js";import"./chunk-2K74TI2N.js";import"./chunk-G3FMV74P.js";import"./chunk-LU7RSOI6.js";import"./chunk-VLMNSWR3.js";import"./chunk-VKNFRCHQ.js";import{Ab as X,Bb as E,Cb as a,Db as _,Eb as x,Lb as T,Pc as y,Sa as c,Sb as B,Tb as P,Ub as d,Vb as K,Vc as Y,Wb as W,Xb as j,Yb as m,Z as O,_b as r,ca as u,da as g,fb as V,fc as Q,gc as q,jc as H,mc as D,nc as A,oa as f,qa as G,rc as M,sc as N,tc as $,vb as C,wb as p,xb as z,zb as J}from"./chunk-QY4Y5NJB.js";import"./chunk-7CGTOI24.js";function Dt(n,e){n&1&&(a(0,"div",13),x(1,"sh-progress-bar",14),a(2,"div",15)(3,"h3"),d(4,2),_()()())}function ft(n,e){n&1&&(a(0,"sh-divider"),d(1,5),_())}function Et(n,e){if(n&1&&(a(0,"p",20),D(1),_()),n&2){let t=r().$implicit;c(),A(t.Description)}}function Ft(n,e){if(n&1&&(a(0,"p",20),D(1),_()),n&2){let t=r().$implicit,o=r(3);c(),A(o.getSimplePath(t.BaseUrl))}}function It(n,e){if(n&1){let t=T();a(0,"button",25),m("click",function(i){u(t);let s=r().$implicit,l=r(3);return g(l.updateBackupsSync(s,i))}),D(1," Update backups "),_()}if(n&2){let t=r(4);E("disabled",t.isSaving())}}function Nt(n,e){if(n&1){let t=T();a(0,"app-destination-list-item",18),m("click",function(){let i=u(t).$implicit,s=r(3);return g(s.selectDestination(i))}),a(1,"h3",19),D(2),_(),C(3,Et,2,1,"p",20)(4,Ft,2,1,"p",20),a(5,"div",21),C(6,It,2,1,"button",22),a(7,"button",23),m("click",function(i){let s=u(t).$implicit,l=r(3);return g(l.deleteDestination(s.ID,i))}),a(8,"sh-icon"),D(9,"trash"),_()(),a(10,"button",24),B(11,6),x(12,"sh-icon"),P(),_()()()}if(n&2){let t=e.$implicit,o=r(3);E("targetUrl",t.BaseUrl),c(2),A(t.Name||t.BaseUrl),c(),p(t.Description?3:4),c(3),p(o.isOutOfSync(t)?6:-1)}}function ht(n,e){if(n&1){let t=T();a(0,"sh-card",16),m("click",function(){u(t);let i=r(2);return g(i.selectDestination("new"))}),a(1,"sh-icon"),D(2,"plus-circle"),_(),a(3,"div",15)(4,"h3"),d(5,3),_(),a(6,"p"),d(7,4),_()()(),C(8,ft,2,0,"sh-divider"),J(9,Nt,13,4,"app-destination-list-item",17,z)}if(n&2){let t=r(2);c(8),p(t.destinations().length>0?8:-1),c(),X(t.destinations())}}function Ot(n,e){if(n&1&&(a(0,"h2"),d(1,1),_(),C(2,Dt,5,0,"div",13)(3,ht,11,1)),n&2){let t=r();c(2),p(t.isLoading()?2:3)}}function xt(n,e){n&1&&d(0,10,1)}function Bt(n,e){n&1&&d(0,10,2)}function Pt(n,e){n&1&&d(0,10,3)}function At(n,e){if(n&1){let t=T();a(0,"button",37),m("click",function(){u(t);let i=r(2);return g(i.testDestination())}),B(1,10),C(2,xt,1,0)(3,Bt,1,0)(4,Pt,1,0),P(),_()}if(n&2){let t,o=r(2);E("disabled",o.testSignal()=="testing"),c(2),p(o.testSignal()=="testing"?2:((t=o.testResponse())==null?null:t.action)==="success"?3:4)}}function Mt(n,e){if(n&1){let t=T();a(0,"div",32)(1,"sh-form-field")(2,"label"),d(3,11),_(),a(4,"input",38),$("ngModelChange",function(i){u(t);let s=r(2);return N(s.editName,i)||(s.editName=i),g(i)}),_()()()}if(n&2){let t=r(2);c(4),M("ngModel",t.editName)}}function $t(n,e){if(n&1){let t=T();a(0,"app-test-url",39,0),$("targetUrlChange",function(i){u(t);let s=r(2);return N(s.editBaseUrl,i)||(s.editBaseUrl=i),g(i)})("testSignalChange",function(i){u(t);let s=r(2);return N(s.testSignal,i)||(s.testSignal=i),g(i)}),_()}if(n&2){let t=r(2);M("targetUrl",t.editBaseUrl)("testSignal",t.testSignal),E("connectionStringId",t.selectedDestinationId())("backupId",null)("sourcePrefix",null)("suppressErrorDialogs",!0)("askToCreate",!0)("testExpectation","any")("moduleType","Backend")}}function yt(n,e){if(n&1){let t=T();a(0,"app-destination-list-item",40)(1,"button",41),m("click",function(){u(t);let i=r(2);return g(i.removeDestination())}),d(2,12),_()(),a(3,"app-single-destination",42),$("targetUrlChange",function(i){u(t);let s=r(2);return N(s.editBaseUrl,i)||(s.editBaseUrl=i),g(i)}),_()}if(n&2){let t=r(2);E("targetUrl",t.editBaseUrl()),c(3),M("targetUrl",t.editBaseUrl)}}function Rt(n,e){if(n&1){let t=T();a(0,"app-destination-list",43),m("setDestination",function(i){u(t);let s=r(2);return g(s.setDestination(i))}),_()}}function kt(n,e){n&1&&d(0,9,1)}function Lt(n,e){n&1&&d(0,9,2)}function bt(n,e){n&1&&d(0,9,3)}function wt(n,e){n&1&&d(0,9,4)}function vt(n,e){if(n&1){let t=T();a(0,"header",26)(1,"button",23),m("click",function(){u(t);let i=r();return g(i.cancelEdit())}),a(2,"sh-icon"),D(3,"arrow-left"),_()()(),a(4,"div",27)(5,"sh-card",28)(6,"header",29)(7,"h3"),d(8,7),_(),a(9,"div",30),C(10,At,5,2,"button",31),_()(),C(11,Mt,5,1,"div",32),C(12,$t,2,9,"app-test-url",33),C(13,yt,4,2)(14,Rt,1,0,"app-destination-list"),_(),a(15,"div",34)(16,"button",35),m("click",function(){u(t);let i=r();return g(i.cancelEdit())}),d(17,8),_(),a(18,"button",36),m("click",function(){let i;u(t);let s=r();return g(((i=s.testResponse())==null?null:i.action)==="success"||((i=s.testResponse())==null?null:i.action)==="missing-folder"||!s.isUrlChanged()?s.save():s.testDestination())}),B(19,9),C(20,kt,1,0)(21,Lt,1,0)(22,bt,1,0)(23,wt,1,0),P(),_()()()}if(n&2){let t,o,i,s,l=r();c(8),K(l.selectedDestination()==="new"?"New Destination":"Edit Destination"),W(8),c(2),p(l.editBaseUrl()?10:-1),c(),p(l.selectedDestination()!=="new"?11:-1),c(),p(l.editBaseUrl()?12:-1),c(),p(l.editBaseUrl()?13:14),c(5),H("primary",((t=l.testResponse())==null?null:t.action)==="success"||!l.isUrlChanged())("warn",l.isUrlChanged()&&l.testSignal()===null||l.testSignal()==="testing"||((o=l.testResponse())==null?null:o.action)==="missing-folder")("error",l.testResponse()&&((i=l.testResponse())==null?null:i.action)!=="success"&&((i=l.testResponse())==null?null:i.action)!=="missing-folder"),E("disabled",!l.editBaseUrl()||l.isSaving()||l.testSignal()==="testing"),c(2),p(l.isSaving()?20:l.testSignal()==="testing"?21:((s=l.testResponse())==null?null:s.action)==="success"||((s=l.testResponse())==null?null:s.action)==="missing-folder"||!l.isUrlChanged()?22:23)}}var L=class n{#t=O(Ct);#e=O(ct);#n=O(ot);getSimplePath=dt;backups=this.#e.backups;constructor(){this.#e.getBackups()}isSaving=this.#t.isSaving;destinations=this.#t.destinations;isLoading=this.#t.resourceDestinations.isLoading;testUrl=Y(k);selectedDestination=f(null);selectedDestinationId=y(()=>this.selectedDestination()!=="new"?this.selectedDestination().ID:null);editName=f(null);editDescription=f(null);editBaseUrl=f(null);initialBaseUrl=f(null);isUrlChanged=y(()=>{let e=this.editBaseUrl(),t=this.initialBaseUrl();return this.selectedDestination()==="new"?!0:e!==t});testSignal=f(null);testResponse=y(()=>{let e=this.testSignal();return e&&typeof e!="string"?e:null});getOutOfSyncBackupIds(e){if(!e.Backups)return[];let t=new Map(this.backups().map(o=>[o.Backup?.ID,o.Backup]));return e.Backups.filter(o=>{let i=t.get(o.ID);return i&&i.TargetURL!==e.BaseUrl}).map(o=>o.ID).filter(o=>!!o)}isOutOfSync(e){return this.getOutOfSyncBackupIds(e).length>0}#i=G(()=>{this.editBaseUrl(),this.testSignal.set(null)});selectDestination(e){this.selectedDestination.set(e),this.testSignal.set(null),e==="new"?(this.editName.set(null),this.editDescription.set(null),this.editBaseUrl.set(null),this.initialBaseUrl.set(null)):(this.editName.set(e.Name),this.editDescription.set(e.Description),this.editBaseUrl.set(e.BaseUrl),this.initialBaseUrl.set(e.BaseUrl),this.#t.getById(e.ID).subscribe(t=>{t.Data&&(this.editName.set(t.Data.Name),this.editDescription.set(t.Data.Description),this.editBaseUrl.set(t.Data.BaseUrl??null),this.initialBaseUrl.set(t.Data.BaseUrl??null))}))}cancelEdit(){this.selectedDestination.set(null)}setDestination(e){let t=gt(e??"");if(t){if(t.mapper.default){let o=t.mapper.default("");this.editBaseUrl.set(o);return}this.editBaseUrl.set(`${e}://`)}}removeDestination(){this.editBaseUrl.set(null)}async testDestination(){(await this.testUrl()?.testDestination(!1))?.action==="missing-folder"&&this.promptCreateFolder()}promptCreateFolder(){this.#n.open(R,{data:{title:$localize`Folder missing`,message:$localize`The specified folder does not exist. Would you like to create it now?`,confirmText:$localize`Create Folder`,cancelText:$localize`Dismiss`},closed:e=>{e&&this.testUrl()?.createFolder()}})}save(){let e=this.selectedDestination();e&&this.performSave(e)}performSave(e){let t=this.editName(),o=this.editDescription(),i=this.editBaseUrl();if(e==="new"){let I=ut(i??"")?.displayName??"Destination",h=this.destinations().filter(F=>F.Name?.startsWith(I)).length;t=`${I} #${h+1}`,o=null}let s={Name:t,Description:o,BaseUrl:i};this.#t.save(e,s).subscribe(()=>{this.selectedDestination.set(null),this.#t.reload(),this.#e.getBackups(!0)})}updateBackupsSync(e,t){t.stopPropagation();let o=this.getOutOfSyncBackupIds(e);this.#n.open(R,{data:{title:$localize`Update backups`,message:$localize`Are you sure you want to update ${o.length} backup(s) to use the current connection string?`,confirmText:$localize`Update`,cancelText:$localize`Cancel`},closed:i=>{i&&this.#t.updateBackups(e.ID,o).subscribe(()=>{this.#t.reload(),this.#e.getBackups(!0)})}})}deleteDestination(e,t){t.stopPropagation(),this.#n.open(R,{data:{title:$localize`Delete destination`,message:$localize`Are you sure you want to delete this destination?`,confirmText:$localize`Delete`,confirmVariant:"error",cancelText:$localize`Cancel`},closed:o=>{o&&this.#t.delete(e).subscribe(()=>{this.#t.reload()})}})}static \u0275fac=function(t){return new(t||n)};static \u0275cmp=V({type:n,selectors:[["app-destinations"]],viewQuery:function(t,o){t&1&&Q(o.testUrl,k,5),t&2&&q()},decls:4,vars:1,consts:()=>{let e;e=$localize`Destinations`;let t;t=$localize`Loading destinations...`;let o;o=$localize`Add new destination`;let i;i=$localize`Configure a new storage location.`;let s;s=$localize`Or manage your saved destinations`;let l;l=$localize` Manage ${"\uFFFD#12\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SH_ICON:`;let I;I=$localize`${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let h;h=$localize`Cancel`;let F;F=$localize`${"\uFFFD*20:1\uFFFD"}:START_BLOCK_IF: Saving... ${"\uFFFD/*20:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*21:2\uFFFD"}:START_BLOCK_ELSE_IF: Testing... ${"[\uFFFD/*21:2\uFFFD|\uFFFD/*22:3\uFFFD]"}:CLOSE_BLOCK_ELSE_IF:${"\uFFFD*22:3\uFFFD"}:START_BLOCK_ELSE_IF_1: Save Destination ${"[\uFFFD/*21:2\uFFFD|\uFFFD/*22:3\uFFFD]"}:CLOSE_BLOCK_ELSE_IF:${"\uFFFD*23:4\uFFFD"}:START_BLOCK_ELSE: Test & Save ${"\uFFFD/*23:4\uFFFD"}:CLOSE_BLOCK_ELSE:`,F=j(F);let b;b=$localize`${"\uFFFD*2:1\uFFFD"}:START_BLOCK_IF: Testing... ${"\uFFFD/*2:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*3:2\uFFFD"}:START_BLOCK_ELSE_IF: Retry test ${"\uFFFD/*3:2\uFFFD"}:CLOSE_BLOCK_ELSE_IF:${"\uFFFD*4:3\uFFFD"}:START_BLOCK_ELSE: Test destination ${"\uFFFD/*4:3\uFFFD"}:CLOSE_BLOCK_ELSE:`;let w;w=$localize`Name`;let v;v=$localize`Name`;let U;return U=$localize`Change`,[["testUrl",""],e,t,o,i,s,l,I,h,F,b,v,U,[1,"loading-list"],[1,"indeterminate","primary"],[1,"text"],[1,"type-a","actionable","add-new",3,"click"],["variant","type-a",1,"actionable",3,"targetUrl"],["variant","type-a",1,"actionable",3,"click","targetUrl"],["displayName",""],["description",""],[1,"manage-actions"],["shButton","","type","button",1,"small","raised","primary",3,"disabled"],["shButton","","iconOnly","","variant","ghost","type","button",3,"click"],["shButton","","type","button",1,"manage-btn"],["shButton","","type","button",1,"small","raised","primary",3,"click","disabled"],[1,"edit-header"],[1,"edit-form"],[1,"config-section","type-c"],[1,"dest-config-header"],[1,"actions"],["shButton","","type","button","variant","ghost",1,"small",3,"disabled"],[1,"form-row"],[3,"targetUrl","testSignal","connectionStringId","backupId","sourcePrefix","suppressErrorDialogs","askToCreate","testExpectation","moduleType"],[1,"form-footer"],["shButton","","type","button",3,"click"],["shButton","","type","button",1,"raised",3,"click","disabled"],["shButton","","type","button","variant","ghost",1,"small",3,"click","disabled"],["placeholder",w,3,"ngModelChange","ngModel"],[3,"targetUrlChange","testSignalChange","targetUrl","testSignal","connectionStringId","backupId","sourcePrefix","suppressErrorDialogs","askToCreate","testExpectation","moduleType"],[1,"selected-backend",3,"targetUrl"],["shButton","","type","button","variant","ghost",3,"click"],[3,"targetUrlChange","targetUrl"],[3,"setDestination"]]},template:function(t,o){t&1&&(x(0,"app-status-bar"),a(1,"section"),C(2,Ot,4,1)(3,vt,24,13),_()),t&2&&(c(2),p(o.selectedDestination()===null?2:3))},dependencies:[pt,mt,Tt,St,_t,st,it,at,rt,lt,k,nt,Z,tt,et],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{max-width:43.75rem;margin:0 auto;padding:2rem 1rem;display:flex;flex-direction:column;gap:1rem}h2[_ngcontent-%COMP%]{font:var(--title-30);text-align:center;padding:2rem}h3[_ngcontent-%COMP%]{font:var(--paragraph-10)}.actionable[_ngcontent-%COMP%]{cursor:pointer}.actionable[_ngcontent-%COMP%]:after{transition:inset .1s linear}.actionable[_ngcontent-%COMP%]:hover{--card-shp: 0}.custom-info[_ngcontent-%COMP%]{flex:1}.custom-info[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--body-10);color:var(--base-7);margin:.25rem 0 0}.manage-actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;align-items:center}@media(max-width:600px){.manage-actions[_ngcontent-%COMP%] .manage-btn[_ngcontent-%COMP%]{display:none}}.add-new[_ngcontent-%COMP%]{display:flex;align-items:center;gap:1.5rem;padding:1.5rem;background:var(--base-1);color:var(--primary-8)}.add-new[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{font-size:2.5rem;opacity:.8}.edit-header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:1rem;margin-bottom:.5rem}.edit-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.edit-form[_ngcontent-%COMP%] .form-row[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr;gap:1rem;margin-bottom:1.5rem}@media(max-width:600px){.edit-form[_ngcontent-%COMP%] .form-row[_ngcontent-%COMP%]{grid-template-columns:1fr}}.edit-form[_ngcontent-%COMP%] .config-section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;padding:1.5rem}.edit-form[_ngcontent-%COMP%] .config-section[_ngcontent-%COMP%] .dest-config-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center}.edit-form[_ngcontent-%COMP%] .form-footer[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;gap:1rem;margin-top:1rem;padding-top:1.5rem;border-top:1px solid var(--base-3)}.selected-backend[_ngcontent-%COMP%]{margin-bottom:.5rem}.loading-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem;align-items:center;padding:4rem}.loading-list[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{text-align:center}"],changeDetection:0})};export{L as default};
@@ -0,0 +1 @@
1
+ import{a as F}from"./chunk-6COK7FLL.js";import{a as te}from"./chunk-7E5J43IH.js";import{e as ee}from"./chunk-KUX6NGQU.js";import{B as Q,L as Y,w as K,x as W,z as q}from"./chunk-Y46QCSB5.js";import{a as H,d as Z}from"./chunk-JJY6UOEY.js";import{b as U,d as j}from"./chunk-2K74TI2N.js";import{Ab as k,Bb as m,Cb as a,Db as c,Eb as S,Ib as y,Jb as D,Lb as f,Pa as x,Pc as h,Sa as r,Sb as G,Tb as V,Ub as _,Uc as A,Yb as u,Z as d,_b as s,ca as p,da as I,fb as E,lc as z,mc as P,nc as L,oa as v,oc as J,uc as X,vb as N,vc as B,wb as T,wc as g,zb as b}from"./chunk-QY4Y5NJB.js";function ae(n,t){if(n&1&&(a(0,"div",11),P(1),c()),n&2){s();let e=g(0);r(),J(" ",e.Message," ")}}function re(n,t){if(n&1&&(a(0,"div"),G(1,1),S(2,"a",15),V(),c()),n&2){let e=s();r(2),m("href",e.downloadLink(),x)}}function le(n,t){if(n&1){let e=f();a(0,"button",14),u("click",function(){p(e);let i=s(),l=g(0);return I(i.doRepair(l.BackupID))}),_(1,2),c()}}function ce(n,t){if(n&1){let e=f();a(0,"button",14),u("click",function(){p(e);let i=s(),l=g(0);return I(i.doDownloadBugreport(l))}),_(1,3),c()}}function _e(n,t){if(n&1&&S(0,"sh-progress-bar",17),n&2){let e,o=s(2);m("value",(e=o.serverState())==null?null:e.UpdateDownloadProgress)}}function se(n,t){if(n&1){let e=f();a(0,"div",11),y(1),_(2,4),D(),a(3,"a",16),P(4),c(),N(5,_e,1,1,"sh-progress-bar",17),a(6,"button",14),u("click",function(){p(e);let i=s();return I(i.doShowUpdate())}),_(7,5),c()()}if(n&2){let e,o,i=s(),l=g(0);r(3),m("href",(e=i.serverState())==null?null:e.UpdateDownloadLink,x),r(),L(l.Message),r(),T(((o=i.serverState())==null?null:o.UpdaterState)==="Downloading"?5:-1)}}function de(n,t){if(n&1){let e=f();a(0,"button",14),u("click",function(){p(e);let i=s(),l=g(0);return I(i.doShowLog(l.BackupID))}),_(1,6),c()}}function Ne(n,t){if(n&1){let e=f();a(0,"button",14),u("click",function(){p(e);let i=s();return I(i.doShowLink("https://docs.duplicati.com/detailed-descriptions/the-server-database"))}),_(1,7),c()}}function Te(n,t){if(n&1){let e=f();a(0,"button",14),u("click",function(){p(e);let i=s();return I(i.doShowLink("https://docs.duplicati.com/detailed-descriptions/the-server-database"))}),_(1,8),c()}}var Ce={Error:"error",Warning:"warn",Information:"primary"},M=class n{#e=d(j);#a=d(U);#r=d(q);#t=d(W);#i=d(F);#n=d(Z);#l=d(ee);#o=v(null);serverState=this.#i.serverState;index=A.required();notification=A.required();downloadLink=h(()=>this.#o()||this.notification().DownloadLink||"");deleteNotificationByIndex(){this.#i.deleteNotification(this.index())}deleteAllNotifications(){this.#i.deleteAllNotifications()}getAlertType(t){return t&&Ce[t]||"primary"}doShowLog(t){this.#n.getApiV1BackupByIdIsactive({id:t}).subscribe({next:e=>{this.#e.navigate(["/backup/"+t+"/log"])},error:e=>{if(e.status===404){let o={title:$localize`Error`,message:$localize`The backup is missing, has it been deleted?`,confirmText:$localize`OK`,cancelText:null};parseInt(t)+""!=t&&(o={title:$localize`Error`,message:$localize`The backup was temporary and does not exist anymore, so the log data is lost`,confirmText:$localize`OK`,cancelText:null}),this.#r.open(te,{maxWidth:"550px",width:"100%",data:o})}else this.#t.error($localize`Failed to find backup: `+e.message)}})}doRepair(t){this.#n.postApiV1BackupByIdRepair({id:t}).subscribe({next:()=>{this.#t.success($localize`Backup repaired`),this.#e.navigate(["./"],{onSameUrlNavigation:"reload",relativeTo:this.#a})},error:e=>{this.#t.error($localize`Failed to repair backup: `+e.message)}})}doShowUpdate(){this.#e.navigate(["/about/changelog"])}doShowLink(t){window.open(t,"_blank")}doDownloadBugreport(t){let e=t.Action.slice(19);this.#n.postApiV1AuthIssuetokenByOperation({operation:"bugreport"}).subscribe({next:o=>{if(!o.Token){this.#t.error("Failed to get bug report URL: No token generated");return}let i=H.BASE||"",l=this.#l.xsrfQueryParam(),O=`${location.origin}${i}/api/v1/bugreport/${e}?token=${o.Token}${l?`&${l}`:""}`;t.DownloadLink=O,this.#o.set(O),this.triggerDownload(O)},error:o=>{this.#t.error(`Failed to get bug report URL: ${o.message}`)}})}triggerDownload(t){let e=document.createElement("a");e.href=t,e.download="",e.style.display="none",document.body.appendChild(e);try{e.click()}catch{}document.body.removeChild(e)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=E({type:n,selectors:[["app-notification"]],inputs:{index:[1,"index"],notification:[1,"notification"]},decls:16,vars:12,consts:()=>{let t;t=$localize`Dismiss`;let e;e=$localize` If the backup file was not downloaded automatically, ${"\uFFFD#2\uFFFD"}:START_LINK:right click and choose "Save as …"${"\uFFFD/#2\uFFFD"}:CLOSE_LINK:`;let o;o=$localize`Repair`;let i;i=$localize`Download`;let l;l=$localize`New update found:`;let O;O=$localize`Show Update`;let w;w=$localize`Show Log`;let $;$=$localize` Show Help `;let R;return R=$localize` Show Help `,[t,e,o,i,l,O,w,$,R,["ship-alert-title",""],["ship-alert-content","",1,"content"],[1,"message"],[1,"actions"],["shButton","",1,"small","outlined"],["shButton","",1,"small","outlined",3,"click"],["target","_blank",3,"href"],[3,"href"],[3,"value"]]},template:function(e,o){if(e&1){let i=f();X(0),a(1,"sh-alert")(2,"div",9),P(3),c(),a(4,"div",10),N(5,ae,2,1,"div",11),N(6,re,3,1,"div"),a(7,"div",12),N(8,le,2,0,"button",13),N(9,ce,2,0,"button",13),N(10,se,8,3,"div",11),N(11,de,2,0,"button",13),N(12,Ne,2,0,"button",13),N(13,Te,2,0,"button",13),a(14,"button",14),u("click",function(){return p(i),I(o.deleteNotificationByIndex())}),_(15,0),c()()()()}if(e&2){let i=B(o.notification());r(),z(o.getAlertType(i.Type)),r(2),L(i.Title),r(2),T(i.Action!=="update:new"&&i.Action!=="update:manual"?5:-1),r(),T(o.downloadLink()?6:-1),r(2),T(i.Message!=null&&i.Message.includes("please run repair")?8:-1),r(),T(i.Action!=null&&i.Action.startsWith("bug-report:created:")&&!o.downloadLink()?9:-1),r(),T(i.Action==="update:new"?10:-1),r(),T(i.Action==="backup:show-log"?11:-1),r(),T(i.Action==="config:issue:unencrypted-database"?12:-1),r(),T(i.Action==="config:issue:windows-folder-used"?13:-1)}},dependencies:[Y,Q,K],styles:["[_nghost-%COMP%]{display:block}.content[_ngcontent-%COMP%]{margin-top:.5rem;display:flex;flex-direction:column;gap:.5rem}.message[_ngcontent-%COMP%]{max-height:12.5rem;overflow:auto}"],changeDetection:0})};var pe=(n,t)=>t.ID;function Ie(n,t){if(n&1&&S(0,"app-notification",1),n&2){let e=t.$implicit,o=t.$index;m("index",o)("notification",e)}}function fe(n,t){n&1&&(a(0,"div",2)(1,"p"),_(2,0),c()())}var ie=class n{#e=d(F);notificationFilterPredicate=A();notifications=h(()=>{let t=this.notificationFilterPredicate()?.predicate,e=this.#e.notifications();return typeof t!="function"?e:e.filter(t)});static \u0275fac=function(e){return new(e||n)};static \u0275cmp=E({type:n,selectors:[["app-notifications"]],inputs:{notificationFilterPredicate:[1,"notificationFilterPredicate"]},decls:3,vars:1,consts:()=>{let t;return t=$localize`No more notifications`,[t,[3,"index","notification"],[1,"notification-list"]]},template:function(e,o){e&1&&b(0,Ie,1,2,"app-notification",1,pe,!1,fe,3,0,"div",2),e&2&&k(o.notifications())},dependencies:[M],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.actions[_ngcontent-%COMP%]{display:flex;gap:.25rem;justify-content:flex-end}.notification-list[_ngcontent-%COMP%]{padding:1rem;display:flex;flex-direction:column;gap:1rem;text-align:center}"],changeDetection:0})};export{M as a,ie as b};
@@ -0,0 +1 @@
1
+ import{a as Ie,c as we,d as v}from"./chunk-RWDQ3L3C.js";import{a as fe}from"./chunk-GGW26MAG.js";import"./chunk-6Q6SSTBK.js";import"./chunk-QY5UGQ3R.js";import{b as Re}from"./chunk-4VYR5E5I.js";import"./chunk-KLAJGS5T.js";import"./chunk-NGKFJLI2.js";import"./chunk-KUX6NGQU.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,v as Ce,w as Ee}from"./chunk-Y46QCSB5.js";import{a as b,d as he}from"./chunk-JJY6UOEY.js";import{b as ie,d as re,e as se}from"./chunk-2K74TI2N.js";import"./chunk-G3FMV74P.js";import{a as te,d as ne}from"./chunk-LU7RSOI6.js";import"./chunk-VLMNSWR3.js";import"./chunk-VKNFRCHQ.js";import{Ac as oe,Bb as P,Cb as a,Db as r,E as M,Eb as _,K as W,Lb as L,Pc as A,Sa as s,Sb as c,Tb as p,Ub as S,Vb as X,Wb as G,Xb as B,Yb as m,Z as C,_b as u,ca as D,da as x,fb as Y,jc as h,mc as $,nc as Z,oa as E,pc as ee,qa as y,vb as F,wb as d}from"./chunk-QY4Y5NJB.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};