@duplicati/ngclient 0.0.95 → 0.0.96

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 (90) hide show
  1. package/{chunk-ICOF6OY2.js → chunk-27RULQ7Y.js} +1 -1
  2. package/{chunk-2HS3CYRN.js → chunk-3GK4TNUH.js} +1 -1
  3. package/chunk-3WEATDBM.js +1 -0
  4. package/chunk-3WKC2CFC.js +1 -0
  5. package/{chunk-25IC7WV6.js → chunk-3XY4ZNIY.js} +1 -1
  6. package/{chunk-3HJFVNAL.js → chunk-3YOT5OAB.js} +1 -1
  7. package/chunk-4ERW7ITN.js +1 -0
  8. package/{chunk-V5GVLIPJ.js → chunk-4XPN5ZGE.js} +1 -1
  9. package/{chunk-3ZLHMSKS.js → chunk-57MYGQMW.js} +1 -1
  10. package/{chunk-M5YHW43W.js → chunk-5COOM7FC.js} +1 -1
  11. package/{chunk-ORA656R6.js → chunk-5UL3RRQI.js} +1 -1
  12. package/{chunk-AVNZ3OXK.js → chunk-6EQS5NZL.js} +1 -1
  13. package/{chunk-ZHWVTLKA.js → chunk-6LVGSIUU.js} +1 -1
  14. package/{chunk-VFLEQIHL.js → chunk-76MUKWQP.js} +1 -1
  15. package/chunk-7CGTOI24.js +1 -0
  16. package/chunk-7EPQLKGD.js +1 -0
  17. package/chunk-7JZ5LA6R.js +1 -0
  18. package/{chunk-R6R4GFBX.js → chunk-A6XFGG4U.js} +1 -1
  19. package/chunk-ASQFBDFK.js +1 -0
  20. package/chunk-C2PMOZWR.js +1 -0
  21. package/chunk-CHZ7TMI7.js +1 -0
  22. package/{chunk-LFPZBC5Y.js → chunk-CMXSHXAU.js} +1 -1
  23. package/{chunk-DUPZCVLU.js → chunk-CNWIFYHZ.js} +1 -1
  24. package/{chunk-RCP6EKCC.js → chunk-CR2UB7UZ.js} +1 -1
  25. package/{chunk-RDRLCN5M.js → chunk-F5S33WHR.js} +1 -1
  26. package/{chunk-TYO44G6M.js → chunk-FHW4WHNO.js} +1 -1
  27. package/{chunk-ETPUKEDV.js → chunk-FJKXCOAH.js} +1 -1
  28. package/{chunk-THUAAYGA.js → chunk-G3YJXHRY.js} +1 -1
  29. package/{chunk-IR7OYLKR.js → chunk-GI6WORKU.js} +1 -1
  30. package/{chunk-GEEPH37P.js → chunk-HGERKLOF.js} +1 -1
  31. package/{chunk-VS2WUXLN.js → chunk-IAVOZTCR.js} +1 -1
  32. package/{chunk-OB2RR7QV.js → chunk-IHYIT4I3.js} +1 -1
  33. package/{chunk-TLNQL27Q.js → chunk-IZOZII2D.js} +1 -1
  34. package/{chunk-KLIPTMVG.js → chunk-L3T52MCL.js} +1 -1
  35. package/{chunk-4IJQ7AAQ.js → chunk-LHSJLKCF.js} +1 -1
  36. package/{chunk-2FWU7B4D.js → chunk-LO4MUZS2.js} +1 -1
  37. package/chunk-LXEGFP53.js +1 -0
  38. package/chunk-MJI6X5KH.js +1 -0
  39. package/{chunk-YKB6KLXM.js → chunk-MJUYFS7O.js} +1 -1
  40. package/{chunk-QXYKZKGV.js → chunk-MURCWMUG.js} +1 -1
  41. package/{chunk-DTR7JZFL.js → chunk-NB32XJ7B.js} +1 -1
  42. package/{chunk-N5K6ODRA.js → chunk-NV2YMSSM.js} +1 -1
  43. package/{chunk-CK5N2PPF.js → chunk-OS4AAJLB.js} +1 -1
  44. package/{chunk-DTPZU6NP.js → chunk-PTC4N7TU.js} +1 -1
  45. package/chunk-PUSUA4U7.js +1 -0
  46. package/chunk-Q3FF4WG3.js +1 -0
  47. package/{chunk-S5JZJBJS.js → chunk-QPO2N2OR.js} +1 -1
  48. package/{chunk-WZG34QS3.js → chunk-QX5XWUM2.js} +1 -1
  49. package/chunk-RUWWC6BD.js +1 -0
  50. package/{chunk-UDBZI5KJ.js → chunk-T2KQRNAJ.js} +1 -1
  51. package/chunk-TNK2MVSP.js +1 -0
  52. package/{chunk-5RLVPRCW.js → chunk-UBZDIRFY.js} +1 -1
  53. package/{chunk-XL5J65PI.js → chunk-UT45C7WK.js} +1 -1
  54. package/{chunk-WNQBKJ3M.js → chunk-V6OHLKTK.js} +1 -1
  55. package/{chunk-RHPHTHFC.js → chunk-VFJL5JPI.js} +1 -1
  56. package/{chunk-RBRHRXAU.js → chunk-W5YK2JJZ.js} +1 -1
  57. package/{chunk-AIOUSVMR.js → chunk-WBNOGAKJ.js} +1 -1
  58. package/{chunk-SNZ7FE6B.js → chunk-WGIELPP6.js} +1 -1
  59. package/{chunk-KJ3CPTGU.js → chunk-WNWGY2FM.js} +1 -1
  60. package/{chunk-TBPNAHEA.js → chunk-WVKWOGDQ.js} +1 -1
  61. package/{chunk-Q67EYU7V.js → chunk-XC6KYSRC.js} +1 -1
  62. package/{chunk-FAZH6E7O.js → chunk-YDN2L342.js} +1 -1
  63. package/{chunk-SSKK33BY.js → chunk-YIWL3QAP.js} +1 -1
  64. package/{chunk-WYXI4BXE.js → chunk-YPQUTPBQ.js} +1 -1
  65. package/{chunk-L4B5RE7R.js → chunk-ZCB4RYTS.js} +1 -1
  66. package/chunk-ZTJALQGT.js +1 -0
  67. package/index.html +1 -1
  68. package/locale/dayjs/da.js +40 -1
  69. package/locale/dayjs/de.js +64 -1
  70. package/locale/dayjs/en-gb.js +42 -1
  71. package/locale/dayjs/en.js +12 -1
  72. package/locale/dayjs/fr.js +41 -1
  73. package/{main-ZZ5NOUMD.js → main-JSU2T7AW.js} +1 -1
  74. package/package.json +1 -1
  75. package/chunk-3TZIEZUP.js +0 -1
  76. package/chunk-APEDZMBI.js +0 -1
  77. package/chunk-C6Q5SG76.js +0 -1
  78. package/chunk-ECH6I3YN.js +0 -1
  79. package/chunk-F4AVB6VB.js +0 -1
  80. package/chunk-HWVDZXYD.js +0 -1
  81. package/chunk-IYKSYF2U.js +0 -1
  82. package/chunk-LVHYWUFN.js +0 -1
  83. package/chunk-MLJFOQOI.js +0 -1
  84. package/chunk-NU46HB6T.js +0 -1
  85. package/chunk-P5GYPUJD.js +0 -1
  86. package/chunk-QUDKB5S3.js +0 -1
  87. package/chunk-SSXZ4GVY.js +0 -1
  88. package/chunk-TX5R4CFB.js +0 -1
  89. package/chunk-UQH5ZQG7.js +0 -1
  90. package/chunk-XQXYPXR7.js +0 -1
@@ -1 +1 @@
1
- import{a as pe}from"./chunk-RDRLCN5M.js";import{b as ue,d as ce,g as Se,i as de,r as F}from"./chunk-4IJQ7AAQ.js";import{a as te}from"./chunk-TYO44G6M.js";import{a as ne,b as ie,e as oe,g as ae,i as h,l as se,o as le,p as _e,r as re}from"./chunk-ECH6I3YN.js";import{b as A}from"./chunk-KLIPTMVG.js";import{pa as ee}from"./chunk-2HS3CYRN.js";import{a as Te}from"./chunk-UQH5ZQG7.js";import{Ab as s,Bb as l,Cb as R,D as g,Gb as V,Lc as G,Mb as I,Nb as k,Ob as p,Qa as _,Rb as j,Sb as u,Tb as C,X as c,ca as x,da as z,db as E,fc as O,gb as X,hc as q,ib as L,ic as Z,jc as J,kc as f,lc as P,mc as N,oa as D,rb as m,sa as r,tb as S,vc as B,wb as v,wc as Y,xb as H,xc as Q,yb as K,zb as W}from"./chunk-DTPZU6NP.js";var y=class a{#e=c(Te);transform(n,...t){return this.#e.locale(),this.#e(n).fromNow()}static \u0275fac=function(t){return new(t||a)};static \u0275pipe=X({name:"appRelativeTime",type:a,pure:!0})};function Ae(a,n){if(a&1){let t=V();s(0,"spk-radio",10),u("click",function(){let i=x(t).$implicit,o=C();return z(o.pauseOption.set(i.value))}),O(1),l()}if(a&2){let t=n.$implicit,e=C();S("active",e.pauseOption()===t.value),_(),q(" ",t.label," ")}}var fe=[{label:$localize`5 minuts`,value:"5m"},{label:$localize`10 minuts`,value:"10m"},{label:$localize`15 minuts`,value:"15m"},{label:$localize`30 minuts`,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}],b=class a{#e=c(A);pauseOptions=r(fe);closed=D();isSubmitting=r(!1);pauseTransfers=r(!1);pauseOption=r(void 0);submit(){this.isSubmitting.set(!0);let n=this.pauseTransfers()||null,t=this.pauseOption();this.#e.postApiV1ServerstatePause({duration:t,pauseTransfers:n}).pipe(g(()=>this.isSubmitting.set(!1))).subscribe({next:e=>{this.closed.emit()}})}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=E({type:a,selectors:[["app-pause-dialog"]],outputs:{closed:"closed"},decls:17,vars:4,consts:()=>{let n;n=$localize`Pause settings`;let t;t=$localize` Also pause transfers `;let e;e=$localize`If you pause transfers they could time out and cause retries or failures.`;let i;i=$localize`Cancel`;let o;return o=$localize` Update settings `,[n,t,e,i,o,["header",""],["content",""],[1,"radios"],[1,"primary","raised",3,"active"],[1,"check-wrap"],[1,"primary","raised",3,"click"],["type","warning"],["footer",""],["spk-button","",3,"click"],["spk-button","",1,"raised","primary",3,"click"]]},template:function(t,e){t&1&&(s(0,"header",5)(1,"h3"),p(2,0),l()(),s(3,"div",6)(4,"div",7),K(5,Ae,2,3,"spk-radio",8,H),l(),s(7,"div",9)(8,"spk-checkbox",10),u("click",function(){return e.pauseTransfers.set(!e.pauseTransfers())}),p(9,1),l(),s(10,"spk-alert",11),p(11,2),l()()(),s(12,"footer",12)(13,"button",13),u("click",function(){return e.closed.emit()}),p(14,3),l(),s(15,"button",14),u("click",function(){return e.submit()}),p(16,4),l()()),t&2&&(_(5),W(e.pauseOptions()),_(3),S("active",e.pauseTransfers()),_(7),S("loader",e.isSubmitting()))},dependencies:[F,_e,h,ie],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})};var Pe=["Byte/s","KByte/s","MByte/s","GByte/s","TByte/s","PByte/s"],$={Byte:"B",KByte:"KB",MByte:"MB",GByte:"GB",TByte:"TB",PByte:"PB"},ge=Object.entries($).reduce((a,[n,t])=>(a[t]=n,a),{}),M=class a{#e=c(A);closed=D();isSubmitting=r(!1);sizeOptions=r(Pe);maxUploadActive=r(!1);maxDownloadActive=r(!1);maxUpload=r(0);maxDownload=r(0);maxUploadUnit=r("MByte/s");maxDownloadUnit=r("MByte/s");ngOnInit(){this.init()}init(){this.#e.getApiV1Serversettings().subscribe({next:n=>{let t=n?.["max-upload-speed"]?.split(/(\d+)/),e=n?.["max-download-speed"]?.split(/(\d+)/),i=t[1]??"",o=e[1]??"",d=t[2]??"MB",T=e[2]??"MB",Ce=i===""?10:parseInt(i),Oe=o===""?10:parseInt(o);this.maxUploadUnit.set(ge[d]+"/s"),this.maxDownloadUnit.set(ge[T]+"/s"),this.maxUploadActive.set(i!==""),this.maxDownloadActive.set(o!==""),this.maxUpload.set(Ce),this.maxDownload.set(Oe)}})}blockDecimalKeys(n){if([".",","].includes(n.key))return n.preventDefault()}cleanupInputAfterPasting(n){n.preventDefault();let t=n.clipboardData?.getData("text/plain");if(!t)return;let e=t.replaceAll(/[\.,]/g,"");n.target.value=e}submit(){this.isSubmitting.set(!0);let n=this.maxUploadActive()?`${this.maxUpload()}${$[this.maxUploadUnit().replace("/s","")]}`:"",t=this.maxDownloadActive()?`${this.maxDownload()}${$[this.maxDownloadUnit().replace("/s","")]}`:"";this.#e.patchApiV1Serversettings({requestBody:{"max-upload-speed":n,"max-download-speed":t}}).pipe(g(()=>this.isSubmitting.set(!1))).subscribe({next:e=>{this.closed.emit(!0)}})}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=E({type:a,selectors:[["app-throttle-settings-dialog"]],outputs:{closed:"closed"},decls:26,vars:16,consts:()=>{let n;n=$localize`Throttle network speed`;let t;t=$localize` Max upload speed `;let e;e=$localize` Max download speed `;let i;i=$localize` Note that speeds are entered in bytes, and line speeds are typically reported in bits. Use a factor of 8 to convert, such that an 8 mbit/s line is equivalent to 1 MByte/s. `;let o;o=$localize`Cancel`;let d;return d=$localize` Update settings `,[n,t,e,i,o,d,["header",""],["content",""],[1,"column"],[1,"field-row"],[1,"primary","raised",3,"click"],["type","number",3,"paste","keydown","ngModelChange","ngModel","disabled"],[3,"isClearable","options"],["type","text",3,"ngModelChange","ngModel"],["footer",""],["spk-button","",3,"click"],["spk-button","",1,"raised","primary",3,"click"]]},template:function(t,e){t&1&&(s(0,"header",6)(1,"h3"),p(2,0),l()(),s(3,"div",7)(4,"div",8)(5,"div",9)(6,"spk-checkbox",10),u("click",function(){return e.maxUploadActive.set(!e.maxUploadActive())}),p(7,1),l(),s(8,"spk-form-field")(9,"input",11),u("paste",function(o){return e.cleanupInputAfterPasting(o)})("keydown",function(o){return e.blockDecimalKeys(o)}),N("ngModelChange",function(o){return P(e.maxUpload,o)||(e.maxUpload=o),o}),l()(),s(10,"spk-select",12)(11,"input",13),N("ngModelChange",function(o){return P(e.maxUploadUnit,o)||(e.maxUploadUnit=o),o}),l()()(),s(12,"div",9)(13,"spk-checkbox",10),u("click",function(){return e.maxDownloadActive.set(!e.maxDownloadActive())}),p(14,2),l(),s(15,"spk-form-field")(16,"input",11),u("paste",function(o){return e.cleanupInputAfterPasting(o)})("keydown",function(o){return e.blockDecimalKeys(o)}),N("ngModelChange",function(o){return P(e.maxDownload,o)||(e.maxDownload=o),o}),l()(),s(17,"spk-select",12)(18,"input",13),N("ngModelChange",function(o){return P(e.maxDownloadUnit,o)||(e.maxDownloadUnit=o),o}),l()()(),s(19,"p"),p(20,3),l()()(),s(21,"footer",14)(22,"button",15),u("click",function(){return e.closed.emit(!1)}),p(23,4),l(),s(24,"button",16),u("click",function(){return e.submit()}),p(25,5),l()()),t&2&&(_(6),S("active",e.maxUploadActive()),_(3),f("ngModel",e.maxUpload),m("disabled",!e.maxUploadActive()),_(),m("isClearable",!1)("options",e.sizeOptions()),_(),f("ngModel",e.maxUploadUnit),_(2),S("active",e.maxDownloadActive()),_(3),f("ngModel",e.maxDownload),m("disabled",!e.maxDownloadActive()),_(),m("isClearable",!1)("options",e.sizeOptions()),_(),f("ngModel",e.maxDownloadUnit),_(6),S("loader",e.isSubmitting()))},dependencies:[F,ue,de,ce,Se,se,h,re],styles:["[_nghost-%COMP%]{display:block}h3[_ngcontent-%COMP%]{font:var(--title-30)}.column[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.field-row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;width:100%}"],changeDetection:0})};function Ne(a,n){if(a&1&&(s(0,"div"),O(1),l(),R(2,"spk-progress-bar",8)),a&2){let t=C();_(),Z("",t.statusData().actionText," - ",t.statusData().statusText,""),_(),m("value",t.statusData().progress*100)}}function Me(a,n){if(a&1&&(s(0,"div",5),O(1),B(2,"appRelativeTime"),B(3,"date"),l()),a&2){let t,e=C();_(),J(" ",(t=e.nextBackup().backup)==null||t.Backup==null?null:t.Backup.Name," - ",Y(2,3,e.nextBackup().time)," at ",Q(3,5,e.nextBackup().time,"shortTime")," ")}}function De(a,n){a&1&&(s(0,"div",5),p(1,1),l())}function Re(a,n){a&1&&(s(0,"div",5),p(1,2),l())}function Ie(a,n){a&1&&(I(0,0,1),R(1,"spk-icon"),k())}function ke(a,n){a&1&&(I(0,0,2),R(1,"spk-icon"),k())}var Ee=new Date,w=class a{#e=c(A);#t=c(pe);#n=c(oe);#i=c(te);minsAgo=Ee.setMinutes(Ee.getMinutes()-1);statusData=this.#t.statusData;serverState=this.#t.serverState;isRunning=G(()=>this.serverState()?.ProgramState==="Running");isResuming=r(!1);nextBackup=G(()=>({backup:this.serverState()?.ProposedSchedule?.[0]?.backup,time:this.serverState()?.ProposedSchedule?.[0]?.Item2}));openThrottleSettingsDialog(){this.#n.open(M,{maxWidth:"550px",width:"100%"})}openPauseDialog(){this.#n.open(b,{maxWidth:"550px",width:"100%"})}pauseResume(){if(this.isRunning()){this.openPauseDialog();return}this.isResuming.set(!0),this.#e.postApiV1ServerstateResume().pipe(g(()=>this.isResuming.set(!1))).subscribe()}ngAfterViewInit(){let n=this.#i.relayIsEnabled()?"longpoll":"websocket";this.#t.setConnectionMethod(n)}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=E({type:a,selectors:[["app-status-bar"]],decls:14,vars:4,consts:()=>{let n;n=$localize`${"\uFFFD*9:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SPK_ICON:pause${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SPK_ICON: Pause ${"\uFFFD/*9:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*10:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SPK_ICON:play${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SPK_ICON: Start ${"\uFFFD/*10:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,n=j(n);let t;t=$localize`No scheduled tasks`;let e;return e=$localize`Loading...`,[n,t,e,[1,"current-backup"],[1,"current-backup-progress"],[1,"label"],[1,"current-backup-actions"],["spk-button","",3,"click"],[1,"raised","primary",3,"value"]]},template:function(t,e){if(t&1&&(s(0,"div",3)(1,"div",4),L(2,Ne,3,3)(3,Me,4,8,"div",5)(4,De,2,0,"div",5)(5,Re,2,0,"div",5),l(),s(6,"div",6)(7,"button",7),u("click",function(){return e.pauseResume()}),I(8,0),L(9,Ie,2,0)(10,ke,2,0),k(),l(),s(11,"button",7),u("click",function(){return e.openThrottleSettingsDialog()}),s(12,"spk-icon"),O(13,"speedometer"),l()()()()),t&2){let i;_(2),v((i=e.serverState())!=null&&i.ActiveTask&&(!((i=e.statusData())==null||i.task==null)&&i.task.Status)&&((i=e.statusData())==null||i.task==null?null:i.task.Status)!=="Completed"?2:e.nextBackup().backup||e.nextBackup().time?3:(i=e.serverState())!=null&&i.ActiveTask?5:4),_(5),S("loader",e.isResuming()),_(2),v(e.isRunning()?9:10)}},dependencies:[le,y,ee,ne,ae],styles:["[_nghost-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:1rem;min-height:3.875rem;border-bottom:1px solid var(--base-level-40)}.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:.25rem;min-width:18.75rem}.current-backup-actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}"],changeDetection:0})};export{w as a};
1
+ import{a as pe}from"./chunk-F5S33WHR.js";import{b as ue,d as ce,g as Se,i as de,r as F}from"./chunk-LHSJLKCF.js";import{a as te}from"./chunk-FHW4WHNO.js";import{a as ne,b as ie,e as oe,g as ae,i as h,l as se,o as le,p as _e,r as re}from"./chunk-PUSUA4U7.js";import{b as A}from"./chunk-L3T52MCL.js";import{pa as ee}from"./chunk-3GK4TNUH.js";import{a as Te}from"./chunk-CHZ7TMI7.js";import{Ab as s,Bb as l,Cb as R,D as g,Gb as V,Lc as G,Mb as I,Nb as k,Ob as p,Qa as _,Rb as j,Sb as u,Tb as C,X as c,ca as x,da as z,db as E,fc as O,gb as X,hc as q,ib as L,ic as Z,jc as J,kc as f,lc as P,mc as N,oa as D,rb as m,sa as r,tb as S,vc as B,wb as v,wc as Y,xb as H,xc as Q,yb as K,zb as W}from"./chunk-PTC4N7TU.js";var y=class a{#e=c(Te);transform(n,...t){return this.#e.locale(),this.#e(n).fromNow()}static \u0275fac=function(t){return new(t||a)};static \u0275pipe=X({name:"appRelativeTime",type:a,pure:!0})};function Ae(a,n){if(a&1){let t=V();s(0,"spk-radio",10),u("click",function(){let i=x(t).$implicit,o=C();return z(o.pauseOption.set(i.value))}),O(1),l()}if(a&2){let t=n.$implicit,e=C();S("active",e.pauseOption()===t.value),_(),q(" ",t.label," ")}}var fe=[{label:$localize`5 minuts`,value:"5m"},{label:$localize`10 minuts`,value:"10m"},{label:$localize`15 minuts`,value:"15m"},{label:$localize`30 minuts`,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}],b=class a{#e=c(A);pauseOptions=r(fe);closed=D();isSubmitting=r(!1);pauseTransfers=r(!1);pauseOption=r(void 0);submit(){this.isSubmitting.set(!0);let n=this.pauseTransfers()||null,t=this.pauseOption();this.#e.postApiV1ServerstatePause({duration:t,pauseTransfers:n}).pipe(g(()=>this.isSubmitting.set(!1))).subscribe({next:e=>{this.closed.emit()}})}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=E({type:a,selectors:[["app-pause-dialog"]],outputs:{closed:"closed"},decls:17,vars:4,consts:()=>{let n;n=$localize`Pause settings`;let t;t=$localize` Also pause transfers `;let e;e=$localize`If you pause transfers they could time out and cause retries or failures.`;let i;i=$localize`Cancel`;let o;return o=$localize` Update settings `,[n,t,e,i,o,["header",""],["content",""],[1,"radios"],[1,"primary","raised",3,"active"],[1,"check-wrap"],[1,"primary","raised",3,"click"],["type","warning"],["footer",""],["spk-button","",3,"click"],["spk-button","",1,"raised","primary",3,"click"]]},template:function(t,e){t&1&&(s(0,"header",5)(1,"h3"),p(2,0),l()(),s(3,"div",6)(4,"div",7),K(5,Ae,2,3,"spk-radio",8,H),l(),s(7,"div",9)(8,"spk-checkbox",10),u("click",function(){return e.pauseTransfers.set(!e.pauseTransfers())}),p(9,1),l(),s(10,"spk-alert",11),p(11,2),l()()(),s(12,"footer",12)(13,"button",13),u("click",function(){return e.closed.emit()}),p(14,3),l(),s(15,"button",14),u("click",function(){return e.submit()}),p(16,4),l()()),t&2&&(_(5),W(e.pauseOptions()),_(3),S("active",e.pauseTransfers()),_(7),S("loader",e.isSubmitting()))},dependencies:[F,_e,h,ie],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})};var Pe=["Byte/s","KByte/s","MByte/s","GByte/s","TByte/s","PByte/s"],$={Byte:"B",KByte:"KB",MByte:"MB",GByte:"GB",TByte:"TB",PByte:"PB"},ge=Object.entries($).reduce((a,[n,t])=>(a[t]=n,a),{}),M=class a{#e=c(A);closed=D();isSubmitting=r(!1);sizeOptions=r(Pe);maxUploadActive=r(!1);maxDownloadActive=r(!1);maxUpload=r(0);maxDownload=r(0);maxUploadUnit=r("MByte/s");maxDownloadUnit=r("MByte/s");ngOnInit(){this.init()}init(){this.#e.getApiV1Serversettings().subscribe({next:n=>{let t=n?.["max-upload-speed"]?.split(/(\d+)/),e=n?.["max-download-speed"]?.split(/(\d+)/),i=t[1]??"",o=e[1]??"",d=t[2]??"MB",T=e[2]??"MB",Ce=i===""?10:parseInt(i),Oe=o===""?10:parseInt(o);this.maxUploadUnit.set(ge[d]+"/s"),this.maxDownloadUnit.set(ge[T]+"/s"),this.maxUploadActive.set(i!==""),this.maxDownloadActive.set(o!==""),this.maxUpload.set(Ce),this.maxDownload.set(Oe)}})}blockDecimalKeys(n){if([".",","].includes(n.key))return n.preventDefault()}cleanupInputAfterPasting(n){n.preventDefault();let t=n.clipboardData?.getData("text/plain");if(!t)return;let e=t.replaceAll(/[\.,]/g,"");n.target.value=e}submit(){this.isSubmitting.set(!0);let n=this.maxUploadActive()?`${this.maxUpload()}${$[this.maxUploadUnit().replace("/s","")]}`:"",t=this.maxDownloadActive()?`${this.maxDownload()}${$[this.maxDownloadUnit().replace("/s","")]}`:"";this.#e.patchApiV1Serversettings({requestBody:{"max-upload-speed":n,"max-download-speed":t}}).pipe(g(()=>this.isSubmitting.set(!1))).subscribe({next:e=>{this.closed.emit(!0)}})}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=E({type:a,selectors:[["app-throttle-settings-dialog"]],outputs:{closed:"closed"},decls:26,vars:16,consts:()=>{let n;n=$localize`Throttle network speed`;let t;t=$localize` Max upload speed `;let e;e=$localize` Max download speed `;let i;i=$localize` Note that speeds are entered in bytes, and line speeds are typically reported in bits. Use a factor of 8 to convert, such that an 8 mbit/s line is equivalent to 1 MByte/s. `;let o;o=$localize`Cancel`;let d;return d=$localize` Update settings `,[n,t,e,i,o,d,["header",""],["content",""],[1,"column"],[1,"field-row"],[1,"primary","raised",3,"click"],["type","number",3,"paste","keydown","ngModelChange","ngModel","disabled"],[3,"isClearable","options"],["type","text",3,"ngModelChange","ngModel"],["footer",""],["spk-button","",3,"click"],["spk-button","",1,"raised","primary",3,"click"]]},template:function(t,e){t&1&&(s(0,"header",6)(1,"h3"),p(2,0),l()(),s(3,"div",7)(4,"div",8)(5,"div",9)(6,"spk-checkbox",10),u("click",function(){return e.maxUploadActive.set(!e.maxUploadActive())}),p(7,1),l(),s(8,"spk-form-field")(9,"input",11),u("paste",function(o){return e.cleanupInputAfterPasting(o)})("keydown",function(o){return e.blockDecimalKeys(o)}),N("ngModelChange",function(o){return P(e.maxUpload,o)||(e.maxUpload=o),o}),l()(),s(10,"spk-select",12)(11,"input",13),N("ngModelChange",function(o){return P(e.maxUploadUnit,o)||(e.maxUploadUnit=o),o}),l()()(),s(12,"div",9)(13,"spk-checkbox",10),u("click",function(){return e.maxDownloadActive.set(!e.maxDownloadActive())}),p(14,2),l(),s(15,"spk-form-field")(16,"input",11),u("paste",function(o){return e.cleanupInputAfterPasting(o)})("keydown",function(o){return e.blockDecimalKeys(o)}),N("ngModelChange",function(o){return P(e.maxDownload,o)||(e.maxDownload=o),o}),l()(),s(17,"spk-select",12)(18,"input",13),N("ngModelChange",function(o){return P(e.maxDownloadUnit,o)||(e.maxDownloadUnit=o),o}),l()()(),s(19,"p"),p(20,3),l()()(),s(21,"footer",14)(22,"button",15),u("click",function(){return e.closed.emit(!1)}),p(23,4),l(),s(24,"button",16),u("click",function(){return e.submit()}),p(25,5),l()()),t&2&&(_(6),S("active",e.maxUploadActive()),_(3),f("ngModel",e.maxUpload),m("disabled",!e.maxUploadActive()),_(),m("isClearable",!1)("options",e.sizeOptions()),_(),f("ngModel",e.maxUploadUnit),_(2),S("active",e.maxDownloadActive()),_(3),f("ngModel",e.maxDownload),m("disabled",!e.maxDownloadActive()),_(),m("isClearable",!1)("options",e.sizeOptions()),_(),f("ngModel",e.maxDownloadUnit),_(6),S("loader",e.isSubmitting()))},dependencies:[F,ue,de,ce,Se,se,h,re],styles:["[_nghost-%COMP%]{display:block}h3[_ngcontent-%COMP%]{font:var(--title-30)}.column[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.field-row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;width:100%}"],changeDetection:0})};function Ne(a,n){if(a&1&&(s(0,"div"),O(1),l(),R(2,"spk-progress-bar",8)),a&2){let t=C();_(),Z("",t.statusData().actionText," - ",t.statusData().statusText,""),_(),m("value",t.statusData().progress*100)}}function Me(a,n){if(a&1&&(s(0,"div",5),O(1),B(2,"appRelativeTime"),B(3,"date"),l()),a&2){let t,e=C();_(),J(" ",(t=e.nextBackup().backup)==null||t.Backup==null?null:t.Backup.Name," - ",Y(2,3,e.nextBackup().time)," at ",Q(3,5,e.nextBackup().time,"shortTime")," ")}}function De(a,n){a&1&&(s(0,"div",5),p(1,1),l())}function Re(a,n){a&1&&(s(0,"div",5),p(1,2),l())}function Ie(a,n){a&1&&(I(0,0,1),R(1,"spk-icon"),k())}function ke(a,n){a&1&&(I(0,0,2),R(1,"spk-icon"),k())}var Ee=new Date,w=class a{#e=c(A);#t=c(pe);#n=c(oe);#i=c(te);minsAgo=Ee.setMinutes(Ee.getMinutes()-1);statusData=this.#t.statusData;serverState=this.#t.serverState;isRunning=G(()=>this.serverState()?.ProgramState==="Running");isResuming=r(!1);nextBackup=G(()=>({backup:this.serverState()?.ProposedSchedule?.[0]?.backup,time:this.serverState()?.ProposedSchedule?.[0]?.Item2}));openThrottleSettingsDialog(){this.#n.open(M,{maxWidth:"550px",width:"100%"})}openPauseDialog(){this.#n.open(b,{maxWidth:"550px",width:"100%"})}pauseResume(){if(this.isRunning()){this.openPauseDialog();return}this.isResuming.set(!0),this.#e.postApiV1ServerstateResume().pipe(g(()=>this.isResuming.set(!1))).subscribe()}ngAfterViewInit(){let n=this.#i.relayIsEnabled()?"longpoll":"websocket";this.#t.setConnectionMethod(n)}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=E({type:a,selectors:[["app-status-bar"]],decls:14,vars:4,consts:()=>{let n;n=$localize`${"\uFFFD*9:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SPK_ICON:pause${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SPK_ICON: Pause ${"\uFFFD/*9:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*10:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SPK_ICON:play${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SPK_ICON: Start ${"\uFFFD/*10:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,n=j(n);let t;t=$localize`No scheduled tasks`;let e;return e=$localize`Loading...`,[n,t,e,[1,"current-backup"],[1,"current-backup-progress"],[1,"label"],[1,"current-backup-actions"],["spk-button","",3,"click"],[1,"raised","primary",3,"value"]]},template:function(t,e){if(t&1&&(s(0,"div",3)(1,"div",4),L(2,Ne,3,3)(3,Me,4,8,"div",5)(4,De,2,0,"div",5)(5,Re,2,0,"div",5),l(),s(6,"div",6)(7,"button",7),u("click",function(){return e.pauseResume()}),I(8,0),L(9,Ie,2,0)(10,ke,2,0),k(),l(),s(11,"button",7),u("click",function(){return e.openThrottleSettingsDialog()}),s(12,"spk-icon"),O(13,"speedometer"),l()()()()),t&2){let i;_(2),v((i=e.serverState())!=null&&i.ActiveTask&&(!((i=e.statusData())==null||i.task==null)&&i.task.Status)&&((i=e.statusData())==null||i.task==null?null:i.task.Status)!=="Completed"?2:e.nextBackup().backup||e.nextBackup().time?3:(i=e.serverState())!=null&&i.ActiveTask?5:4),_(5),S("loader",e.isResuming()),_(2),v(e.isRunning()?9:10)}},dependencies:[le,y,ee,ne,ae],styles:["[_nghost-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:1rem;min-height:3.875rem;border-bottom:1px solid var(--base-level-40)}.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:.25rem;min-width:18.75rem}.current-backup-actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}"],changeDetection:0})};export{w as a};
@@ -0,0 +1 @@
1
+ var i=Object.defineProperty,j=Object.defineProperties;var k=Object.getOwnPropertyDescriptors;var e=Object.getOwnPropertySymbols;var g=Object.prototype.hasOwnProperty,h=Object.prototype.propertyIsEnumerable;var f=(a,b,c)=>b in a?i(a,b,{enumerable:!0,configurable:!0,writable:!0,value:c}):a[b]=c,l=(a,b)=>{for(var c in b||={})g.call(b,c)&&f(a,c,b[c]);if(e)for(var c of e(b))h.call(b,c)&&f(a,c,b[c]);return a},m=(a,b)=>j(a,k(b));var n=(a,b)=>{var c={};for(var d in a)g.call(a,d)&&b.indexOf(d)<0&&(c[d]=a[d]);if(a!=null&&e)for(var d of e(a))b.indexOf(d)<0&&h.call(a,d)&&(c[d]=a[d]);return c};export{l as a,m as b,n as c};
@@ -0,0 +1 @@
1
+ import"./chunk-7CGTOI24.js";var o=[{path:"",redirectTo:"general",pathMatch:"full"},{path:"general",loadComponent:()=>import("./chunk-C2PMOZWR.js")},{path:"destination",loadComponent:()=>import("./chunk-3WKC2CFC.js")},{path:"source-data",loadComponent:()=>import("./chunk-3WEATDBM.js")},{path:"schedule",loadComponent:()=>import("./chunk-7JZ5LA6R.js")},{path:"options",loadComponent:()=>import("./chunk-MJI6X5KH.js")}];export{o as default};
@@ -0,0 +1 @@
1
+ import{k as a,l as b}from"./chunk-5COOM7FC.js";import"./chunk-XC6KYSRC.js";import"./chunk-DNHLTHLR.js";import"./chunk-NV2YMSSM.js";import"./chunk-CR2UB7UZ.js";import"./chunk-3YOT5OAB.js";import"./chunk-CMXSHXAU.js";import"./chunk-OS4AAJLB.js";import"./chunk-LHSJLKCF.js";import"./chunk-WBNOGAKJ.js";import"./chunk-G3YJXHRY.js";import"./chunk-PUSUA4U7.js";import"./chunk-L3T52MCL.js";import"./chunk-4XPN5ZGE.js";import"./chunk-3GK4TNUH.js";import"./chunk-PTC4N7TU.js";import"./chunk-7CGTOI24.js";export{a as createScheduleForm,b as default};
@@ -1 +1 @@
1
- import{a as m}from"./chunk-XL5J65PI.js";import{b as N}from"./chunk-KLIPTMVG.js";import{C as o,D as h,Lc as u,N as d,R as l,X as r,l as c,sa as s,v as f,y as p}from"./chunk-DTPZU6NP.js";var v=class n{#e=r(N);#n=r(m);serverState=u(()=>{let t=this.#n.serverState();return t?.LastNotificationUpdateID&&this.updateLastNotificationEventId(t?.LastNotificationUpdateID),t});#o=s(-1);#s=s(!1);#t=s([]);#i=s([]);notifications=this.#t.asReadonly();init(){this.notifications().length===0&&this.getNotifications()}updateLastNotificationEventId(t){this.#o()!==t&&(this.#o.set(t),this.getNotifications())}getNotifications(){this.#s.set(!0),this.#e.getApiV1Notifications().pipe(o(1),d(t=>this.#t.set(t)),h(()=>this.#s.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(p(()=>c(e))));f(i).pipe(o(1)).subscribe({next:e=>{let b=e.filter(a=>a!=null&&"ID"in a);this.#t.set(b),this.#i.set([])},error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}static \u0275fac=function(i){return new(i||n)};static \u0275prov=l({token:n,factory:n.\u0275fac,providedIn:"root"})};export{v as a};
1
+ import{a as m}from"./chunk-UT45C7WK.js";import{b as N}from"./chunk-L3T52MCL.js";import{C as o,D as h,Lc as u,N as d,R as l,X as r,l as c,sa as s,v as f,y as p}from"./chunk-PTC4N7TU.js";var v=class n{#e=r(N);#n=r(m);serverState=u(()=>{let t=this.#n.serverState();return t?.LastNotificationUpdateID&&this.updateLastNotificationEventId(t?.LastNotificationUpdateID),t});#o=s(-1);#s=s(!1);#t=s([]);#i=s([]);notifications=this.#t.asReadonly();init(){this.notifications().length===0&&this.getNotifications()}updateLastNotificationEventId(t){this.#o()!==t&&(this.#o.set(t),this.getNotifications())}getNotifications(){this.#s.set(!0),this.#e.getApiV1Notifications().pipe(o(1),d(t=>this.#t.set(t)),h(()=>this.#s.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(p(()=>c(e))));f(i).pipe(o(1)).subscribe({next:e=>{let b=e.filter(a=>a!=null&&"ID"in a);this.#t.set(b),this.#i.set([])},error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}static \u0275fac=function(i){return new(i||n)};static \u0275prov=l({token:n,factory:n.\u0275fac,providedIn:"root"})};export{v as a};
@@ -0,0 +1 @@
1
+ import{e as a,f as b}from"./chunk-ZCB4RYTS.js";import"./chunk-XC6KYSRC.js";import"./chunk-NV2YMSSM.js";import"./chunk-3YOT5OAB.js";import"./chunk-CMXSHXAU.js";import"./chunk-F5S33WHR.js";import"./chunk-HGERKLOF.js";import"./chunk-UT45C7WK.js";import"./chunk-QX5XWUM2.js";import"./chunk-LHSJLKCF.js";import"./chunk-FHW4WHNO.js";import"./chunk-WBNOGAKJ.js";import"./chunk-G3YJXHRY.js";import"./chunk-PUSUA4U7.js";import"./chunk-L3T52MCL.js";import"./chunk-4XPN5ZGE.js";import"./chunk-3GK4TNUH.js";import"./chunk-PTC4N7TU.js";import"./chunk-7CGTOI24.js";export{a as createRestoreSelectFilesForm,b as default};
@@ -0,0 +1 @@
1
+ import{f as a,g as b,h as c}from"./chunk-5COOM7FC.js";import"./chunk-XC6KYSRC.js";import"./chunk-DNHLTHLR.js";import"./chunk-NV2YMSSM.js";import"./chunk-CR2UB7UZ.js";import"./chunk-3YOT5OAB.js";import"./chunk-CMXSHXAU.js";import"./chunk-OS4AAJLB.js";import"./chunk-LHSJLKCF.js";import"./chunk-WBNOGAKJ.js";import"./chunk-G3YJXHRY.js";import"./chunk-PUSUA4U7.js";import"./chunk-L3T52MCL.js";import"./chunk-4XPN5ZGE.js";import"./chunk-3GK4TNUH.js";import"./chunk-PTC4N7TU.js";import"./chunk-7CGTOI24.js";export{b as NONE_OPTION,a as createGeneralForm,c as default};
@@ -0,0 +1 @@
1
+ import{U as it}from"./chunk-PTC4N7TU.js";var ot=60,ut=ot*60,dt=ut*24,At=dt*7,C=1e3,w=ot*C,k=ut*C,b=dt*C,Z=At*C,W="millisecond",I="second",A="minute",E="hour",p="day",U="week",S="month",X="quarter",y="year",x="date",ct="YYYY-MM-DDTHH:mm:ssZ",rt="Invalid Date",ft=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,B=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g;var ht={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var r=["th","st","nd","rd"],e=t%100;return"["+t+(r[(e-20)%10]||r[e]||r[0])+"]"}};var nt=function(t,r,e){var n=String(t);return!n||n.length>=r?t:""+Array(r+1-n.length).join(e)+t},Et=function(t){var r=-t.utcOffset(),e=Math.abs(r),n=Math.floor(e/60),s=e%60;return(r<=0?"+":"-")+nt(n,2,"0")+":"+nt(s,2,"0")},Nt=function i(t,r){if(t.date()<r.date())return-i(r,t);var e=(r.year()-t.year())*12+(r.month()-t.month()),n=t.clone().add(e,S),s=r-n<0,a=t.clone().add(e+(s?-1:1),S);return+(-(e+(r-n)/(s?n-a:a-n))||0)},Tt=function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},Ht=function(t){var r={M:S,y,w:U,d:p,D:x,h:E,m:A,s:I,ms:W,Q:X};return r[t]||String(t||"").toLowerCase().replace(/s$/,"")},wt=function(t){return t===void 0},lt={s:nt,z:Et,m:Nt,a:Tt,p:Ht,u:wt};var P="en",F={};F[P]=ht;var mt="$isDayjsObject",st=function(t){return t instanceof Q||!!(t&&t[mt])},K=function i(t,r,e){var n;if(!t)return P;if(typeof t=="string"){var s=t.toLowerCase();F[s]&&(n=s),r&&(F[s]=r,n=s);var a=t.split("-");if(!n&&a.length>1)return i(a[0])}else{var o=t.name;F[o]=t,n=o}return!e&&n&&(P=n),n||!e&&P},m=function(t,r){if(st(t))return t.clone();var e=typeof r=="object"?r:{};return e.date=t,e.args=arguments,new Q(e)},xt=function(t,r){return m(t,{locale:r.$L,utc:r.$u,x:r.$x,$offset:r.$offset})},f=lt;f.l=K;f.i=st;f.w=xt;var kt=function(t){var r=t.date,e=t.utc;if(r===null)return new Date(NaN);if(f.u(r))return new Date;if(r instanceof Date)return new Date(r);if(typeof r=="string"&&!/Z$/i.test(r)){var n=r.match(ft);if(n){var s=n[2]-1||0,a=(n[7]||"0").substring(0,3);return e?new Date(Date.UTC(n[1],s,n[3]||1,n[4]||0,n[5]||0,n[6]||0,a)):new Date(n[1],s,n[3]||1,n[4]||0,n[5]||0,n[6]||0,a)}}return new Date(r)},Q=function(){function i(r){this.$L=K(r.locale,null,!0),this.parse(r),this.$x=this.$x||r.x||{},this[mt]=!0}var t=i.prototype;return t.parse=function(e){this.$d=kt(e),this.init()},t.init=function(){var e=this.$d;this.$y=e.getFullYear(),this.$M=e.getMonth(),this.$D=e.getDate(),this.$W=e.getDay(),this.$H=e.getHours(),this.$m=e.getMinutes(),this.$s=e.getSeconds(),this.$ms=e.getMilliseconds()},t.$utils=function(){return f},t.isValid=function(){return this.$d.toString()!==rt},t.isSame=function(e,n){var s=m(e);return this.startOf(n)<=s&&s<=this.endOf(n)},t.isAfter=function(e,n){return m(e)<this.startOf(n)},t.isBefore=function(e,n){return this.endOf(n)<m(e)},t.$g=function(e,n,s){return f.u(e)?this[n]:this.set(s,e)},t.unix=function(){return Math.floor(this.valueOf()/1e3)},t.valueOf=function(){return this.$d.getTime()},t.startOf=function(e,n){var s=this,a=f.u(n)?!0:n,o=f.p(e),u=function(O,M){var l=f.w(s.$u?Date.UTC(s.$y,M,O):new Date(s.$y,M,O),s);return a?l:l.endOf(p)},d=function(O,M){var l=[0,0,0,0],D=[23,59,59,999];return f.w(s.toDate()[O].apply(s.toDate("s"),(a?l:D).slice(M)),s)},c=this.$W,_=this.$M,h=this.$D,v="set"+(this.$u?"UTC":"");switch(o){case y:return a?u(1,0):u(31,11);case S:return a?u(1,_):u(0,_+1);case U:{var $=this.$locale().weekStart||0,T=(c<$?c+7:c)-$;return u(a?h-T:h+(6-T),_)}case p:case x:return d(v+"Hours",0);case E:return d(v+"Minutes",1);case A:return d(v+"Seconds",2);case I:return d(v+"Milliseconds",3);default:return this.clone()}},t.endOf=function(e){return this.startOf(e,!1)},t.$set=function(e,n){var s,a=f.p(e),o="set"+(this.$u?"UTC":""),u=(s={},s[p]=o+"Date",s[x]=o+"Date",s[S]=o+"Month",s[y]=o+"FullYear",s[E]=o+"Hours",s[A]=o+"Minutes",s[I]=o+"Seconds",s[W]=o+"Milliseconds",s)[a],d=a===p?this.$D+(n-this.$W):n;if(a===S||a===y){var c=this.clone().set(x,1);c.$d[u](d),c.init(),this.$d=c.set(x,Math.min(this.$D,c.daysInMonth())).$d}else u&&this.$d[u](d);return this.init(),this},t.set=function(e,n){return this.clone().$set(e,n)},t.get=function(e){return this[f.p(e)]()},t.add=function(e,n){var s=this,a;e=Number(e);var o=f.p(n),u=function(h){var v=m(s);return f.w(v.date(v.date()+Math.round(h*e)),s)};if(o===S)return this.set(S,this.$M+e);if(o===y)return this.set(y,this.$y+e);if(o===p)return u(1);if(o===U)return u(7);var d=(a={},a[A]=w,a[E]=k,a[I]=C,a)[o]||1,c=this.$d.getTime()+e*d;return f.w(c,this)},t.subtract=function(e,n){return this.add(e*-1,n)},t.format=function(e){var n=this,s=this.$locale();if(!this.isValid())return s.invalidDate||rt;var a=e||ct,o=f.z(this),u=this.$H,d=this.$m,c=this.$M,_=s.weekdays,h=s.months,v=s.meridiem,$=function(l,D,H,R){return l&&(l[D]||l(n,a))||H[D].slice(0,R)},T=function(l){return f.s(u%12||12,l,"0")},Y=v||function(M,l,D){var H=M<12?"AM":"PM";return D?H.toLowerCase():H},O=function(l){switch(l){case"YY":return String(n.$y).slice(-2);case"YYYY":return f.s(n.$y,4,"0");case"M":return c+1;case"MM":return f.s(c+1,2,"0");case"MMM":return $(s.monthsShort,c,h,3);case"MMMM":return $(h,c);case"D":return n.$D;case"DD":return f.s(n.$D,2,"0");case"d":return String(n.$W);case"dd":return $(s.weekdaysMin,n.$W,_,2);case"ddd":return $(s.weekdaysShort,n.$W,_,3);case"dddd":return _[n.$W];case"H":return String(u);case"HH":return f.s(u,2,"0");case"h":return T(1);case"hh":return T(2);case"a":return Y(u,d,!0);case"A":return Y(u,d,!1);case"m":return String(d);case"mm":return f.s(d,2,"0");case"s":return String(n.$s);case"ss":return f.s(n.$s,2,"0");case"SSS":return f.s(n.$ms,3,"0");case"Z":return o;default:break}return null};return a.replace(B,function(M,l){return l||O(M)||o.replace(":","")})},t.utcOffset=function(){return-Math.round(this.$d.getTimezoneOffset()/15)*15},t.diff=function(e,n,s){var a=this,o=f.p(n),u=m(e),d=(u.utcOffset()-this.utcOffset())*w,c=this-u,_=function(){return f.m(a,u)},h;switch(o){case y:h=_()/12;break;case S:h=_();break;case X:h=_()/3;break;case U:h=(c-d)/Z;break;case p:h=(c-d)/b;break;case E:h=c/k;break;case A:h=c/w;break;case I:h=c/C;break;default:h=c;break}return s?h:f.a(h)},t.daysInMonth=function(){return this.endOf(S).$D},t.$locale=function(){return F[this.$L]},t.locale=function(e,n){if(!e)return this.$L;var s=this.clone(),a=K(e,n,!0);return a&&(s.$L=a),s},t.clone=function(){return f.w(this.$d,this)},t.toDate=function(){return new Date(this.valueOf())},t.toJSON=function(){return this.isValid()?this.toISOString():null},t.toISOString=function(){return this.$d.toISOString()},t.toString=function(){return this.$d.toUTCString()},i}(),_t=Q.prototype;m.prototype=_t;[["$ms",W],["$s",I],["$m",A],["$H",E],["$W",p],["$M",S],["$y",y],["$D",x]].forEach(function(i){_t[i[1]]=function(t){return this.$g(t,i[0],i[1])}});m.extend=function(i,t){return i.$i||(i(t,Q,m),i.$i=!0),m};m.locale=K;m.isDayjs=st;m.unix=function(i){return m(i*1e3)};m.en=F[P];m.Ls=F;m.p={};var g=m;var tt=b*365,at=tt/12,bt=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,z={years:tt,months:at,days:b,hours:k,minutes:w,seconds:C,milliseconds:1,weeks:Z},q=function(t){return t instanceof $t},vt,N,V=function(t,r,e){return new $t(t,e,r.$l)},G=function(t){return N.p(t)+"s"},St=function(t){return t<0},j=function(t){return St(t)?Math.ceil(t):Math.floor(t)},Ft=function(t){return Math.abs(t)},J=function(t,r){return t?St(t)?{negative:!0,format:""+Ft(t)+r}:{negative:!1,format:""+t+r}:{negative:!1,format:""}},$t=function(){function i(r,e,n){var s=this;if(this.$d={},this.$l=n,r===void 0&&(this.$ms=0,this.parseFromMilliseconds()),e)return V(r*z[G(e)],this);if(typeof r=="number")return this.$ms=r,this.parseFromMilliseconds(),this;if(typeof r=="object")return Object.keys(r).forEach(function(d){s.$d[G(d)]=r[d]}),this.calMilliseconds(),this;if(typeof r=="string"){var a=r.match(bt);if(a){var o=a.slice(2),u=o.map(function(d){return d!=null?Number(d):0});return this.$d.years=u[0],this.$d.months=u[1],this.$d.weeks=u[2],this.$d.days=u[3],this.$d.hours=u[4],this.$d.minutes=u[5],this.$d.seconds=u[6],this.calMilliseconds(),this}}return this}var t=i.prototype;return t.calMilliseconds=function(){var e=this;this.$ms=Object.keys(this.$d).reduce(function(n,s){return n+(e.$d[s]||0)*z[s]},0)},t.parseFromMilliseconds=function(){var e=this.$ms;this.$d.years=j(e/tt),e%=tt,this.$d.months=j(e/at),e%=at,this.$d.days=j(e/b),e%=b,this.$d.hours=j(e/k),e%=k,this.$d.minutes=j(e/w),e%=w,this.$d.seconds=j(e/C),e%=C,this.$d.milliseconds=e},t.toISOString=function(){var e=J(this.$d.years,"Y"),n=J(this.$d.months,"M"),s=+this.$d.days||0;this.$d.weeks&&(s+=this.$d.weeks*7);var a=J(s,"D"),o=J(this.$d.hours,"H"),u=J(this.$d.minutes,"M"),d=this.$d.seconds||0;this.$d.milliseconds&&(d+=this.$d.milliseconds/1e3,d=Math.round(d*1e3)/1e3);var c=J(d,"S"),_=e.negative||n.negative||a.negative||o.negative||u.negative||c.negative,h=o.format||u.format||c.format?"T":"",v=_?"-":"",$=v+"P"+e.format+n.format+a.format+h+o.format+u.format+c.format;return $==="P"||$==="-P"?"P0D":$},t.toJSON=function(){return this.toISOString()},t.format=function(e){var n=e||"YYYY-MM-DDTHH:mm:ss",s={Y:this.$d.years,YY:N.s(this.$d.years,2,"0"),YYYY:N.s(this.$d.years,4,"0"),M:this.$d.months,MM:N.s(this.$d.months,2,"0"),D:this.$d.days,DD:N.s(this.$d.days,2,"0"),H:this.$d.hours,HH:N.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:N.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:N.s(this.$d.seconds,2,"0"),SSS:N.s(this.$d.milliseconds,3,"0")};return n.replace(B,function(a,o){return o||String(s[a])})},t.as=function(e){return this.$ms/z[G(e)]},t.get=function(e){var n=this.$ms,s=G(e);return s==="milliseconds"?n%=1e3:s==="weeks"?n=j(n/z[s]):n=this.$d[s],n||0},t.add=function(e,n,s){var a;return n?a=e*z[G(n)]:q(e)?a=e.$ms:a=V(e,this).$ms,V(this.$ms+a*(s?-1:1),this)},t.subtract=function(e,n){return this.add(e,n,!0)},t.locale=function(e){var n=this.clone();return n.$l=e,n},t.clone=function(){return V(this.$ms,this)},t.humanize=function(e){return vt().add(this.$ms,"ms").locale(this.$l).fromNow(!e)},t.valueOf=function(){return this.asMilliseconds()},t.milliseconds=function(){return this.get("milliseconds")},t.asMilliseconds=function(){return this.as("milliseconds")},t.seconds=function(){return this.get("seconds")},t.asSeconds=function(){return this.as("seconds")},t.minutes=function(){return this.get("minutes")},t.asMinutes=function(){return this.as("minutes")},t.hours=function(){return this.get("hours")},t.asHours=function(){return this.as("hours")},t.days=function(){return this.get("days")},t.asDays=function(){return this.as("days")},t.weeks=function(){return this.get("weeks")},t.asWeeks=function(){return this.as("weeks")},t.months=function(){return this.get("months")},t.asMonths=function(){return this.as("months")},t.years=function(){return this.get("years")},t.asYears=function(){return this.as("years")},i}(),Mt=function(t,r,e){return t.add(r.years()*e,"y").add(r.months()*e,"M").add(r.days()*e,"d").add(r.hours()*e,"h").add(r.minutes()*e,"m").add(r.seconds()*e,"s").add(r.milliseconds()*e,"ms")},Dt=function(i,t,r){vt=r,N=r().$utils(),r.duration=function(s,a){var o=r.locale();return V(s,{$l:o},a)},r.isDuration=q;var e=t.prototype.add,n=t.prototype.subtract;t.prototype.add=function(s,a){return q(s)?Mt(this,s,1):e.bind(this)(s,a)},t.prototype.subtract=function(s,a){return q(s)?Mt(this,s,-1):n.bind(this)(s,a)}};var pt=function(i,t,r){i=i||{};var e=t.prototype,n={future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};r.en.relativeTime=n,e.fromToBase=function(o,u,d,c,_){for(var h=d.$locale().relativeTime||n,v=i.thresholds||[{l:"s",r:44,d:I},{l:"m",r:89},{l:"mm",r:44,d:A},{l:"h",r:89},{l:"hh",r:21,d:E},{l:"d",r:35},{l:"dd",r:25,d:p},{l:"M",r:45},{l:"MM",r:10,d:S},{l:"y",r:17},{l:"yy",d:y}],$=v.length,T,Y,O,M=0;M<$;M+=1){var l=v[M];l.d&&(T=c?r(o).diff(d,l.d,!0):d.diff(o,l.d,!0));var D=(i.rounding||Math.round)(Math.abs(T));if(O=T>0,D<=l.r||!l.r){D<=1&&M>0&&(l=v[M-1]);var H=h[l.l];_&&(D=_(""+D)),typeof H=="string"?Y=H.replace("%d",D):Y=H(D,u,l.l,O);break}}if(u)return Y;var R=O?h.future:h.past;return typeof R=="function"?R(Y):R.replace("%s",Y)};function s(o,u,d,c){return e.fromToBase(o,u,d,c)}e.to=function(o,u){return s(o,u,this,!0)},e.from=function(o,u){return s(o,u,this)};var a=function(u){return u.$u?r.utc():r()};e.toNow=function(o){return this.to(a(this),o)},e.fromNow=function(o){return this.from(a(this),o)}};var yt={name:"da",weekdays:"s\xF8ndag_mandag_tirsdag_onsdag_torsdag_fredag_l\xF8rdag".split("_"),weekdaysShort:"s\xF8n._man._tirs._ons._tors._fre._l\xF8r.".split("_"),weekdaysMin:"s\xF8._ma._ti._on._to._fr._l\xF8.".split("_"),months:"januar_februar_marts_april_maj_juni_juli_august_september_oktober_november_december".split("_"),monthsShort:"jan._feb._mar._apr._maj_juni_juli_aug._sept._okt._nov._dec.".split("_"),weekStart:1,yearStart:4,ordinal:function(t){return t+"."},formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd [d.] D. MMMM YYYY [kl.] HH:mm"},relativeTime:{future:"om %s",past:"%s siden",s:"f\xE5 sekunder",m:"et minut",mm:"%d minutter",h:"en time",hh:"%d timer",d:"en dag",dd:"%d dage",M:"en m\xE5ned",MM:"%d m\xE5neder",y:"et \xE5r",yy:"%d \xE5r"}};g.locale(yt,null,!0);var Ct=yt;var jt={s:"ein paar Sekunden",m:["eine Minute","einer Minute"],mm:"%d Minuten",h:["eine Stunde","einer Stunde"],hh:"%d Stunden",d:["ein Tag","einem Tag"],dd:["%d Tage","%d Tagen"],M:["ein Monat","einem Monat"],MM:["%d Monate","%d Monaten"],y:["ein Jahr","einem Jahr"],yy:["%d Jahre","%d Jahren"]};function L(i,t,r){var e=jt[r];return Array.isArray(e)&&(e=e[t?0:1]),e.replace("%d",i)}var gt={name:"de",weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),months:"Januar_Februar_M\xE4rz_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Feb._M\xE4rz_Apr._Mai_Juni_Juli_Aug._Sept._Okt._Nov._Dez.".split("_"),ordinal:function(t){return t+"."},weekStart:1,yearStart:4,formats:{LTS:"HH:mm:ss",LT:"HH:mm",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},relativeTime:{future:"in %s",past:"vor %s",s:L,m:L,mm:L,h:L,hh:L,d:L,dd:L,M:L,MM:L,y:L,yy:L}};g.locale(gt,null,!0);var Lt=gt;var Yt={name:"fr",weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),months:"janvier_f\xE9vrier_mars_avril_mai_juin_juillet_ao\xFBt_septembre_octobre_novembre_d\xE9cembre".split("_"),monthsShort:"janv._f\xE9vr._mars_avr._mai_juin_juil._ao\xFBt_sept._oct._nov._d\xE9c.".split("_"),weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},ordinal:function(t){var r=t===1?"er":"";return""+t+r}};g.locale(Yt,null,!0);var Ot=Yt;var It={da:Ct,de:Lt,fr:Ot};var Ut=new it("Dayjs"),fr={provide:Ut,useFactory:()=>{let t=(localStorage.getItem("v1:duplicati:locale")??"en-US").split("-")[0];return g.extend(pt),g.extend(Dt),g.locale(It[t]),g}};export{Ut as a,fr as b};
@@ -1 +1 @@
1
- import{b as u}from"./chunk-KLIPTMVG.js";import{D as p,Lc as r,N as a,R as l,X as m,sa as i}from"./chunk-DTPZU6NP.js";var d=class n{#s=m(u);isLoaded=i(!1);systemInfo=i(null);filterGroups=i(null);backendModules=r(()=>this.systemInfo()?.BackendModules??[]);allOptionsGrouped=r(()=>{let e={displayName:"Default",options:this.systemInfo()?.Options?.map(this.#e)??[]},s=this.systemInfo()?.GenericModules?.map(t=>({displayName:t.DisplayName??t.Key,options:t.Options?.map(this.#e)??[]}))??[],o=this.systemInfo()?.CompressionModules?.map(t=>({displayName:t.DisplayName??t.Key,options:t.Options?.map(this.#e)??[]}))??[];return[e,...s,...o]});allOptions=r(()=>this.allOptionsGrouped().reduce((e,s)=>[...e,...s.options],[]));preload(e=!1){let s=this.#s.getApiV1Systeminfo().pipe(a(o=>{this.systemInfo.set(o)}),p(()=>this.isLoaded.set(!0)));if(e)return s;s.subscribe()}preloadFilterGroups(e=!1){let s=this.#s.getApiV1SysteminfoFiltergroups().pipe(a(o=>{this.filterGroups.set(o)}),p(()=>this.isLoaded.set(!0)));if(e)return s;s.subscribe()}#e(e){return{name:e.Name,type:e.Type,shortDescription:e.ShortDescription??void 0,longDescription:e.LongDescription??void 0,options:e.ValidValues}}static \u0275fac=function(s){return new(s||n)};static \u0275prov=l({token:n,factory:n.\u0275fac,providedIn:"root"})};export{d as a};
1
+ import{b as u}from"./chunk-L3T52MCL.js";import{D as p,Lc as r,N as a,R as l,X as m,sa as i}from"./chunk-PTC4N7TU.js";var d=class n{#s=m(u);isLoaded=i(!1);systemInfo=i(null);filterGroups=i(null);backendModules=r(()=>this.systemInfo()?.BackendModules??[]);allOptionsGrouped=r(()=>{let e={displayName:"Default",options:this.systemInfo()?.Options?.map(this.#e)??[]},s=this.systemInfo()?.GenericModules?.map(t=>({displayName:t.DisplayName??t.Key,options:t.Options?.map(this.#e)??[]}))??[],o=this.systemInfo()?.CompressionModules?.map(t=>({displayName:t.DisplayName??t.Key,options:t.Options?.map(this.#e)??[]}))??[];return[e,...s,...o]});allOptions=r(()=>this.allOptionsGrouped().reduce((e,s)=>[...e,...s.options],[]));preload(e=!1){let s=this.#s.getApiV1Systeminfo().pipe(a(o=>{this.systemInfo.set(o)}),p(()=>this.isLoaded.set(!0)));if(e)return s;s.subscribe()}preloadFilterGroups(e=!1){let s=this.#s.getApiV1SysteminfoFiltergroups().pipe(a(o=>{this.filterGroups.set(o)}),p(()=>this.isLoaded.set(!0)));if(e)return s;s.subscribe()}#e(e){return{name:e.Name,type:e.Type,shortDescription:e.ShortDescription??void 0,longDescription:e.LongDescription??void 0,options:e.ValidValues}}static \u0275fac=function(s){return new(s||n)};static \u0275prov=l({token:n,factory:n.\u0275fac,providedIn:"root"})};export{d as a};
@@ -1,3 +1,3 @@
1
- import{o as k}from"./chunk-M5YHW43W.js";import{a as Se}from"./chunk-Q67EYU7V.js";import"./chunk-DNHLTHLR.js";import{a as I}from"./chunk-N5K6ODRA.js";import{a as Ee}from"./chunk-RCP6EKCC.js";import"./chunk-3HJFVNAL.js";import"./chunk-LFPZBC5Y.js";import"./chunk-CK5N2PPF.js";import{a as fe}from"./chunk-VFLEQIHL.js";import"./chunk-RDRLCN5M.js";import"./chunk-GEEPH37P.js";import"./chunk-XL5J65PI.js";import"./chunk-WZG34QS3.js";import{b as se,d as me,e as _e,h as pe,i as de,l as ce,m as ue,n as Ce,p as Ne,q as Me,s as ge}from"./chunk-4IJQ7AAQ.js";import"./chunk-TYO44G6M.js";import{a as J,c as Q,d as Y}from"./chunk-AIOUSVMR.js";import"./chunk-THUAAYGA.js";import{a as ne,g as oe,k as ie,l as ae,o as re,r as le}from"./chunk-ECH6I3YN.js";import{a as ee,b as te}from"./chunk-KLIPTMVG.js";import"./chunk-V5GVLIPJ.js";import"./chunk-2HS3CYRN.js";import"./chunk-UQH5ZQG7.js";import{Ab as a,Bb as n,Cb as r,Db as O,Eb as P,Gb as K,Mb as g,Mc as Z,Nb as f,Ob as u,Pb as w,Qa as l,Qb as z,Sb as X,Tb as S,X as C,Xb as V,ca as E,da as A,db as R,ib as B,kc as W,lc as j,mc as H,qc as q,rb as c,rc as T,sa as F,tb as y,wb as v,xb as G,yb as x,zb as U}from"./chunk-DTPZU6NP.js";import"./chunk-C6Q5SG76.js";var Ae=()=>[],Fe=()=>["--no-encryption","--exclude-files-attributes","--skip-files-larger-than","dblock-size","no-encryption"];function Oe(m,t){m&1&&r(0,"spk-progress-bar",13)}function Pe(m,t){if(m&1&&(a(0,"spk-form-field"),r(1,"input",39),n()),m&2){let e=t.$implicit,o=t.$index;l(),V("id","filter-",o,""),c("formControl",e)}}function Te(m,t){if(m&1){let e=K();a(0,"form",14)(1,"spk-select",15)(2,"label",16),u(3,1),n(),r(4,"input",17),n(),a(5,"spk-form-field")(6,"label",18),u(7,2),n(),r(8,"textarea",19),n(),a(9,"spk-form-field")(10,"label",20),u(11,3),n(),r(12,"textarea",21),n()(),a(13,"spk-divider"),u(14,4),n(),a(15,"form",14)(16,"spk-form-field")(17,"label",22),u(18,5),n(),r(19,"input",23),n(),a(20,"spk-form-field")(21,"label",24),u(22,6),n(),r(23,"input",25),n(),a(24,"app-toggle-card",26),O(25,27),u(26,7),P(),O(27,28),x(28,Pe,2,3,"spk-form-field",null,G),P(),n()(),a(30,"form",14)(31,"div",29)(32,"div",30)(33,"spk-form-field")(34,"label",31),u(35,8),n(),r(36,"input",32),n(),a(37,"spk-select",33),r(38,"input",34),n()(),a(39,"p"),g(40,9),r(41,"a",35),f(),n()(),a(42,"app-options-list",36),H("optionsChange",function(_){E(e);let p=S();return j(p.settings,_)||(p.settings=_),A(_)}),n(),a(43,"div",37)(44,"button",38),X("click",function(){E(e);let _=S();return A(_.submit())}),g(45,10),r(46,"spk-icon"),f(),n()()()}if(m&2){let e,o=S();c("formGroup",o.baseCmdForm),l(),c("options",(e=o.commandOptions())!==null&&e!==void 0?e:T(14,Ae))("inlineSearch",!0),l(14),c("formGroup",o.standardFields),l(9),c("disallowToggle",!0),l(4),U(o.standardFields.controls.filters.controls),l(2),c("formGroup",o.optionsForm),l(7),c("options",o.sizeOptions())("inlineSearch",!0),l(5),W("options",o.settings),c("hasFreeTextSettings",!0)("hiddenOptions",T(15,Fe)),l(2),y("loader",o.isSubmitting()),l(2),w(o.baseCmdForm.value.command),z(45)}}var d=new Me,Ie=["Bytes","KB","MB","GB","TB","PB"],D=class m{#e=C(k);#t=C(te);#n=C(Q);#o=C(J);#i=C(ee);#a=I(this.#o.params);commandOptions=I(this.#i.getApiV1Commandline());sizeOptions=F(Ie);isSubmitting=F(!1);standardFields=d.group({"backup-id":d.control(""),"backup-name":d.control(""),dbpath:d.control(""),filters:d.array([])});baseCmdForm=d.group({command:d.control("backup"),targetUrl:d.control(""),arguments:d.control("")});optionsForm=this.#e.optionsForm;finishedLoading=this.#e.finishedLoading;backupId=this.#e.backupId;settings=this.#e.settings;#r=Z(()=>{let t=this.#a()?.id;this.#e.backupId.set(t),this.getBackup(t)});getBackup(t){this.#t.getApiV1BackupById({id:t}).subscribe({next:e=>{this.#e.mapScheduleToForm(e.Schedule??null),e.Backup&&(this.mapStandardFieldsToForm(e.Backup),this.mapBaseCmdToForm(e.Backup),this.#e.mapOptionsToForms(e.Backup)),this.#e.finishedLoading.set(!0)}})}mapStandardFieldsToForm(t){this.standardFields.patchValue({dbpath:t.DBPath,"backup-id":t.ID,"backup-name":t.Name}),t.Filters&&t.Filters.length&&t.Filters.map(e=>{this.standardFields.controls.filters.push(d.control(`${e.Include?"":"-"}${e.Expression}`))})}submit(){this.isSubmitting.set(!0);let t=this.baseCmdForm.value,e=this.optionsForm.value,o=t.targetUrl??"",_=t.arguments?.split(`
1
+ import{o as k}from"./chunk-5COOM7FC.js";import{a as Se}from"./chunk-XC6KYSRC.js";import"./chunk-DNHLTHLR.js";import{a as I}from"./chunk-NV2YMSSM.js";import{a as Ee}from"./chunk-CR2UB7UZ.js";import"./chunk-3YOT5OAB.js";import"./chunk-CMXSHXAU.js";import"./chunk-OS4AAJLB.js";import{a as fe}from"./chunk-76MUKWQP.js";import"./chunk-F5S33WHR.js";import"./chunk-HGERKLOF.js";import"./chunk-UT45C7WK.js";import"./chunk-QX5XWUM2.js";import{b as se,d as me,e as _e,h as pe,i as de,l as ce,m as ue,n as Ce,p as Ne,q as Me,s as ge}from"./chunk-LHSJLKCF.js";import"./chunk-FHW4WHNO.js";import{a as J,c as Q,d as Y}from"./chunk-WBNOGAKJ.js";import"./chunk-G3YJXHRY.js";import{a as ne,g as oe,k as ie,l as ae,o as re,r as le}from"./chunk-PUSUA4U7.js";import{a as ee,b as te}from"./chunk-L3T52MCL.js";import"./chunk-4XPN5ZGE.js";import"./chunk-3GK4TNUH.js";import"./chunk-CHZ7TMI7.js";import{Ab as a,Bb as n,Cb as r,Db as O,Eb as P,Gb as K,Mb as g,Mc as Z,Nb as f,Ob as u,Pb as w,Qa as l,Qb as z,Sb as X,Tb as S,X as C,Xb as V,ca as E,da as A,db as R,ib as B,kc as W,lc as j,mc as H,qc as q,rb as c,rc as T,sa as F,tb as y,wb as v,xb as G,yb as x,zb as U}from"./chunk-PTC4N7TU.js";import"./chunk-7CGTOI24.js";var Ae=()=>[],Fe=()=>["--no-encryption","--exclude-files-attributes","--skip-files-larger-than","dblock-size","no-encryption"];function Oe(m,t){m&1&&r(0,"spk-progress-bar",13)}function Pe(m,t){if(m&1&&(a(0,"spk-form-field"),r(1,"input",39),n()),m&2){let e=t.$implicit,o=t.$index;l(),V("id","filter-",o,""),c("formControl",e)}}function Te(m,t){if(m&1){let e=K();a(0,"form",14)(1,"spk-select",15)(2,"label",16),u(3,1),n(),r(4,"input",17),n(),a(5,"spk-form-field")(6,"label",18),u(7,2),n(),r(8,"textarea",19),n(),a(9,"spk-form-field")(10,"label",20),u(11,3),n(),r(12,"textarea",21),n()(),a(13,"spk-divider"),u(14,4),n(),a(15,"form",14)(16,"spk-form-field")(17,"label",22),u(18,5),n(),r(19,"input",23),n(),a(20,"spk-form-field")(21,"label",24),u(22,6),n(),r(23,"input",25),n(),a(24,"app-toggle-card",26),O(25,27),u(26,7),P(),O(27,28),x(28,Pe,2,3,"spk-form-field",null,G),P(),n()(),a(30,"form",14)(31,"div",29)(32,"div",30)(33,"spk-form-field")(34,"label",31),u(35,8),n(),r(36,"input",32),n(),a(37,"spk-select",33),r(38,"input",34),n()(),a(39,"p"),g(40,9),r(41,"a",35),f(),n()(),a(42,"app-options-list",36),H("optionsChange",function(_){E(e);let p=S();return j(p.settings,_)||(p.settings=_),A(_)}),n(),a(43,"div",37)(44,"button",38),X("click",function(){E(e);let _=S();return A(_.submit())}),g(45,10),r(46,"spk-icon"),f(),n()()()}if(m&2){let e,o=S();c("formGroup",o.baseCmdForm),l(),c("options",(e=o.commandOptions())!==null&&e!==void 0?e:T(14,Ae))("inlineSearch",!0),l(14),c("formGroup",o.standardFields),l(9),c("disallowToggle",!0),l(4),U(o.standardFields.controls.filters.controls),l(2),c("formGroup",o.optionsForm),l(7),c("options",o.sizeOptions())("inlineSearch",!0),l(5),W("options",o.settings),c("hasFreeTextSettings",!0)("hiddenOptions",T(15,Fe)),l(2),y("loader",o.isSubmitting()),l(2),w(o.baseCmdForm.value.command),z(45)}}var d=new Me,Ie=["Bytes","KB","MB","GB","TB","PB"],D=class m{#e=C(k);#t=C(te);#n=C(Q);#o=C(J);#i=C(ee);#a=I(this.#o.params);commandOptions=I(this.#i.getApiV1Commandline());sizeOptions=F(Ie);isSubmitting=F(!1);standardFields=d.group({"backup-id":d.control(""),"backup-name":d.control(""),dbpath:d.control(""),filters:d.array([])});baseCmdForm=d.group({command:d.control("backup"),targetUrl:d.control(""),arguments:d.control("")});optionsForm=this.#e.optionsForm;finishedLoading=this.#e.finishedLoading;backupId=this.#e.backupId;settings=this.#e.settings;#r=Z(()=>{let t=this.#a()?.id;this.#e.backupId.set(t),this.getBackup(t)});getBackup(t){this.#t.getApiV1BackupById({id:t}).subscribe({next:e=>{this.#e.mapScheduleToForm(e.Schedule??null),e.Backup&&(this.mapStandardFieldsToForm(e.Backup),this.mapBaseCmdToForm(e.Backup),this.#e.mapOptionsToForms(e.Backup)),this.#e.finishedLoading.set(!0)}})}mapStandardFieldsToForm(t){this.standardFields.patchValue({dbpath:t.DBPath,"backup-id":t.ID,"backup-name":t.Name}),t.Filters&&t.Filters.length&&t.Filters.map(e=>{this.standardFields.controls.filters.push(d.control(`${e.Include?"":"-"}${e.Expression}`))})}submit(){this.isSubmitting.set(!0);let t=this.baseCmdForm.value,e=this.optionsForm.value,o=t.targetUrl??"",_=t.arguments?.split(`
2
2
  `)??[],p=this.standardFields.value,N=p.filters??[],M=[t.command,o,..._,`--backup-name=${p["backup-name"]}`,`--dbpath=${p.dbpath}`,`--backup-id=${p["backup-id"]}`,...N.filter(i=>i).map(i=>i.startsWith("-")?`--exclude=${i?.slice(1)}`:`--include=${i}`),...this.#e.mapFormsToSettings(["backup-id","backup-name","dbpath"]).map(i=>i.Name.startsWith("--")?`${i.Name}=${i.Value}`:`--${i.Name}=${i.Value}`),"--disable-module=console-password-input"];this.#t.postApiV1Commandline({requestBody:M}).subscribe(i=>{i.Status==="OK"&&this.#n.navigate(["backup",this.backupId(),"commandline",i.ID])})}mapBaseCmdToForm(t){let e=t.TargetURL??null;e&&this.baseCmdForm.patchValue({targetUrl:e??"",arguments:t.Sources?.join(`
3
3
  `)??""})}static \u0275fac=function(e){return new(e||m)};static \u0275cmp=R({type:m,selectors:[["app-commandline"]],features:[q([k])],decls:8,vars:1,consts:()=>{let t;t=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SPK_ICON:arrow-left${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SPK_ICON: Back `;let e;e=$localize`Select an option...`;let o;o=$localize`Command`;let _;_=$localize`TargetUrl`;let p;p=$localize`Commandline Arguments`;let N;N=$localize`Advanced options`;let M;M=$localize`Backup ID`;let i;i=$localize`Backup Name`;let L;L=$localize`Filters`;let $;$=$localize`Remote volume size`;let h;h=$localize` The backups will be split up into multiple files called volumes. Here you can set the maximum size of the individual volume files. ${"\uFFFD#41\uFFFD"}:START_LINK:Read more${"\uFFFD/#41\uFFFD"}:CLOSE_LINK:`;let b;return b=$localize`${"\uFFFD#46\uFFFD"}:START_TAG_SPK_ICON:arrow-right${"\uFFFD/#46\uFFFD"}:CLOSE_TAG_SPK_ICON: Run "${"\uFFFD0\uFFFD"}:INTERPOLATION:" command now `,[t,o,_,p,N,M,i,L,$,h,b,[1,"back"],["type","button","spk-button","","routerLink","/",1,"small"],[1,"indeterminate","primary"],[3,"formGroup"],["placeholder","Select a command...",3,"options","inlineSearch"],["for","command"],["type","text","id","command","formControlName","command"],["for","targetUrl"],["id","targetUrl","autocomplete","off","formControlName","targetUrl"],["for","arguments"],["id","arguments","autocomplete","off","formControlName","arguments"],["for","backup-id"],["id","backup-id","formControlName","backup-id"],["for","backup-name"],["id","backup-name","formControlName","backup-name"],[3,"disallowToggle"],["title",""],["content","","formGroupName","filters"],[1,"remote-volume-wrap"],["formGroupName","remoteVolumeSize",1,"row-inputs"],["for","size"],["type","number","id","size","formControlName","size"],["placeholder",e,3,"options","inlineSearch"],["type","text","formControlName","unit"],["href","#",1,"spk-primary"],[3,"optionsChange","options","hasFreeTextSettings","hiddenOptions"],[1,"form-actions"],["spk-button","",1,"raised","primary",3,"click"],[3,"id","formControl"]]},template:function(e,o){e&1&&(r(0,"app-status-bar"),a(1,"section")(2,"div",11)(3,"button",12),g(4,0),r(5,"spk-icon"),f(),n()(),B(6,Oe,1,0,"spk-progress-bar",13)(7,Te,47,16),n()),e&2&&(l(6),v(o.finishedLoading()?7:6))},dependencies:[fe,Ee,Se,ge,pe,se,de,me,_e,ce,ue,Ne,Ce,Y,ae,oe,ie,le,re,ne],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;width:100%;max-width:40rem;padding:2.5rem;gap:1.25rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end}.form-column[_ngcontent-%COMP%]{display:flex;flex-direction:column}.form-column[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem}.form-column[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:1rem}.row-inputs[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.5rem}.row-inputs[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{flex:1 0}.remote-volume-wrap[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.field-row[_ngcontent-%COMP%]{display:grid;align-items:flex-end;grid-template-columns:1fr 2.5rem;gap:.5rem}.form-row[_ngcontent-%COMP%]{display:grid;grid-template-columns:3fr 1fr;gap:.5rem;align-items:flex-end}"],changeDetection:0})};export{D as default};
@@ -1 +1 @@
1
- import{a as le}from"./chunk-3HJFVNAL.js";import{a as Y}from"./chunk-LFPZBC5Y.js";import{a as ee,b as te,d as ie,g as ne,i as oe,r as re}from"./chunk-4IJQ7AAQ.js";import{a as U,g as X,l as j,n as H,r as Z,w as J,x as Q,y as W}from"./chunk-ECH6I3YN.js";import{Ab as a,Bb as p,Cb as P,Db as E,Eb as N,Gb as S,Lc as M,Mb as v,Nb as L,Ob as q,Qa as l,Sb as C,Tb as s,X as B,Yb as d,_a as G,ca as u,da as g,db as K,ec as D,fc as m,gc as b,hc as F,ib as x,pa as $,rb as c,sa as O,wb as f,xb as y,yb as k,yc as A,zb as h}from"./chunk-DTPZU6NP.js";import{a as w,b as I}from"./chunk-C6Q5SG76.js";function pe(n,o){if(n&1){let e=S();a(0,"button",14),C("click",function(){u(e);let i=s();return g(i.addFreeTextSetting())}),v(1,5),P(2,"spk-icon"),L(),p()}}function se(n,o){if(n&1){let e=S();a(0,"button",16,0),C("click",function(){let i=u(e).$implicit,r=s(2);return g(r.addSetting(i))}),m(2),p()}if(n&2){let e=o.$implicit;l(2),b(e.name)}}function _e(n,o){if(n&1&&(a(0,"h3",7),m(1),p(),k(2,se,3,1,"button",15,y)),n&2){let e=o.$implicit;l(),b(e.displayName),l(),h(e.options)}}function me(n,o){n&1&&(a(0,"div",12),m(1,"Add a setting above to get started."),p())}function ce(n,o){if(n&1){let e=S();a(0,"div",17)(1,"label"),m(2),p(),a(3,"div",22)(4,"spk-form-field")(5,"input",23),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateFreeTextSettingName(r,i))}),p(),a(6,"spk-icon",24),m(7,"rectangle-dashed"),p()(),a(8,"spk-form-field")(9,"input",23),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p(),a(10,"spk-icon",24),m(11,"textbox"),p()()()()}if(n&2){let e=s().$implicit;l(2),F(" ",e.FormView.shortDescription," "),l(3),c("ngModel",e.Name),l(4),c("ngModel",e.Value())}}function de(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function ue(n,o){if(n&1){let e=S();a(0,"app-file-tree",18)(1,"label",25),m(2),x(3,de,3,1,"spk-tooltip",26),p(),a(4,"input",27),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p()()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;c("startingPath",t.Value())("accepts",t.FormView.accepts)("showFiles",!0)("showHiddenNodes",!0)("selectFiles",!0),l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.Value())}}function ge(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Ce(n,o){if(n&1){let e=S();a(0,"app-file-tree",19)(1,"label",25),m(2),x(3,ge,3,1,"spk-tooltip",26),p(),a(4,"input",27),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p()()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;c("startingPath",t.Value()),l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.Value())}}function xe(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Se(n,o){n&1&&(a(0,"spk-icon",24),m(1,"link"),p())}function fe(n,o){n&1&&(a(0,"spk-icon",24),m(1,"textbox"),p())}function Fe(n,o){if(n&1){let e=S();a(0,"spk-form-field")(1,"label",25),m(2),x(3,xe,3,1,"spk-tooltip",26),p(),a(4,"input",27),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p(),x(5,Se,2,0,"spk-icon",24)(6,fe,2,0,"spk-icon",24),p()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.Value()),l(),f(t.FormView.type==="Path"?5:6)}}function Te(n,o){if(n&1){let e=S();a(0,"spk-icon",30),C("click",function(){u(e);let i=s(2).$implicit;return g(i.showPassword=!i.showPassword)}),m(1," eye "),p()}}function Oe(n,o){if(n&1){let e=S();a(0,"spk-icon",30),C("click",function(){u(e);let i=s(2).$implicit;return g(i.showPassword=!i.showPassword)}),m(1," eye-slash "),p()}}function Ve(n,o){if(n&1){let e=S();a(0,"spk-form-field")(1,"label",25),m(2),p(),a(3,"input",28),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p(),a(4,"spk-icon",24),m(5,"password"),p(),x(6,Te,2,0,"spk-icon",29)(7,Oe,2,0,"spk-icon",29),p()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),d("id","destination-",t.Name,"-",i,""),c("type",t.showPassword?"text":"password")("ngModel",t.Value()),l(3),f(t.showPassword?6:7)}}function we(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Ie(n,o){if(n&1&&m(0),n&2){let e=o.$implicit;F(" ",e," ")}}function ye(n,o){if(n&1){let e=S();a(0,"spk-select",31)(1,"label",25),m(2),x(3,we,3,1,"spk-tooltip",26),p(),a(4,"input",27),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p()(),x(5,Ie,1,1,"ng-template",null,1,A)}if(n&2){let e=D(6),t=s(),i=t.$implicit,r=t.$index;c("options",i.FormView.options)("isClearable",!1)("optionTemplate",e),l(),d("for","destination-",i.Name,"-",r,""),l(),F(" ",i.FormView.shortDescription," "),l(),f(i.FormView.longDescription?3:-1),l(),d("id","destination-",i.Name,"-",r,""),c("ngModel",i.Value())}}function ke(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function he(n,o){if(n&1){let e=S();a(0,"div",17)(1,"label",25),m(2),x(3,ke,3,1,"spk-tooltip",26),p(),a(4,"div",22)(5,"spk-form-field")(6,"input",32),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSizeSetting(r,i,"size"))}),p(),a(7,"spk-icon",24),m(8,"resize"),p()(),a(9,"spk-select",33)(10,"input",23),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSizeSetting(r,i,"unit"))}),p()()()()}if(n&2){let e=s(),t=e.$implicit,i=e.$index,r=s();l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(3),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.size()),l(3),c("options",r.sizeOptions())("isClearable",!1),l(),c("ngModel",t.unit())}}function Ne(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Me(n,o){if(n&1){let e=S();a(0,"spk-form-field")(1,"label",25),m(2),x(3,Ne,3,1,"spk-tooltip",26),p(),a(4,"input",32),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p(),a(5,"spk-icon",24),m(6,"numpad"),p()()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.Value())}}function $e(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Pe(n,o){if(n&1){let e=S();a(0,"spk-toggle",20)(1,"label",25),m(2),x(3,$e,3,1,"spk-tooltip",26),p(),a(4,"input",34),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p()()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.Value())}}function Ee(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function ve(n,o){if(n&1&&m(0),n&2){let e=o.$implicit;F(" ",e," ")}}function Le(n,o){if(n&1){let e=S();a(0,"spk-select",35)(1,"label",25),m(2),x(3,Ee,3,1,"spk-tooltip",26),p(),a(4,"input",36),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p()(),x(5,ve,1,1,"ng-template",null,2,A)}if(n&2){let e=D(6),t=s(),i=t.$implicit,r=t.$index;c("options",i.FormView.options)("selectMultiple",!0)("optionTemplate",e),l(),d("for","destination-",i.Name,"-",r,""),l(),F(" ",i.FormView.shortDescription," "),l(),f(i.FormView.longDescription?3:-1),l(),c("ngModel",i.Value())}}function De(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function be(n,o){if(n&1){let e=S();a(0,"spk-form-field")(1,"label",25),m(2),x(3,De,3,1,"spk-tooltip",26),p(),a(4,"input",27),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p()()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.Value())}}function Ae(n,o){if(n&1){let e=S();a(0,"div",13),x(1,ce,12,3,"div",17)(2,ue,5,14,"app-file-tree",18)(3,Ce,5,10,"app-file-tree",19)(4,Fe,7,10,"spk-form-field")(5,Ve,8,10,"spk-form-field")(6,ye,7,12)(7,he,11,12,"div",17)(8,Me,7,9,"spk-form-field")(9,Pe,5,9,"spk-toggle",20)(10,Le,7,9)(11,be,5,9,"spk-form-field"),a(12,"button",21),C("click",function(){let i=u(e).$implicit,r=s();return g(r.removeSetting(i))}),a(13,"spk-icon"),m(14,"x-bold"),p()()()}if(n&2){let e=o.$implicit;l(),f(e.FormView.type==="FreeText"?1:e.FormView.type==="FileTree"?2:e.FormView.type==="FolderTree"?3:e.FormView.type==="String"||e.FormView.type==="Path"||e.FormView.type==="Decimal"?4:e.FormView.type==="Password"?5:e.FormView.type==="Enumeration"?6:e.FormView.type==="Size"?7:e.FormView.type==="Integer"?8:e.FormView.type==="Boolean"?9:e.FormView.type==="Flags"?10:e.FormView.type==="Timespan"?11:-1)}}var ze=["Bytes","KB","MB","GB","TB","PB"],ae=class n{#e=B(Y);options=G.required();hiddenOptions=$([]);hasFreeTextSettings=$(!1);allOptionsGrouped=this.#e.allOptionsGrouped;allOptions=this.#e.allOptions;sizeOptions=O(ze);selectedSettings=M(()=>{let o=this.hiddenOptions();return this.options().map(t=>{let i=this.allOptions().find(r=>r.name===t.Name);if(i&&!o.includes(i.name)){if(i.type==="Size"){let T=t.Value?.replace(/[0-9]/g,""),V=t.Value?.replace(/[^0-9]/g,""),z=O(T&&T!==""?T:"MB"),R=O(V&&V!==""?parseInt(V):"");return I(w({},t),{Value:M(()=>R()+z()),unit:z,size:R,FormView:i})}let r=t.Value??"";i.type==="Boolean"&&(r=r&&r.toLowerCase()==="true"||!1),i.type==="Integer"&&(r=parseInt(r)||0);let _=O(r);return I(w({},t),{Value:_,FormView:i})}else if(this.hasFreeTextSettings())return I(w({},t),{Value:O(t.Value),FormView:{name:t.Name,type:"FreeText",shortDescription:"Custom settings argument",longDescription:"Custom settings argument"}});return null}).filter(t=>t!==null)});nonSelectedOptionsGrouped=M(()=>{let o=this.options().map(t=>t.Name),e=this.hiddenOptions();return this.allOptionsGrouped().map(t=>I(w({},t),{options:t.options.filter(i=>!o.includes(i.name)&&!e.includes(i.name))})).filter(t=>t.options.length>0)});addFreeTextSetting(){this.hasFreeTextSettings()&&this.options.update(o=>[...o,{Filter:null,Name:"",Value:""}])}addSetting(o){this.options.update(e=>{let t=o.defaultValue??"";return o.type==="Boolean"&&(t=t.toLowerCase()==="true"||!1),o.type==="Integer"&&(t=parseInt(t)||0),[...e,{Name:o.name,Value:t}]})}updateSettingValue(o,e){this.options.update(t=>{let i=[...t],r=i.findIndex(_=>_.Name===o.Name);return o.FormView.type==="Boolean"?(i[r].Value=e?"True":"False",i):o.FormView.type==="Integer"?(i[r].Value=e.toString(),i):(i[r].Value=e,i)})}updateFreeTextSettingName(o,e){this.options.update(t=>{let i=[...t],r=i.findIndex(_=>_.Name===o.Name);return i[r].Name=e,i})}updateSizeSetting(o,e,t){let i=o;this.options.update(r=>{let _=[...r],T=_.findIndex(V=>V.Name===i.Name);return t==="size"&&(_[T].Value=`${e}${i.unit()}`),t==="unit"&&(_[T].Value=`${i.size()}${e}`),_})}removeSetting(o){this.options.update(e=>e.filter(t=>t.Name!==o.Name))}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=K({type:n,selectors:[["app-options-list"]],inputs:{options:[1,"options"],hiddenOptions:[1,"hiddenOptions"],hasFreeTextSettings:[1,"hasFreeTextSettings"]},outputs:{options:"optionsChange"},decls:16,vars:4,consts:()=>{let o;o=$localize`Advanced options`;let e;e=$localize` Add advanced option ${"\uFFFD#9\uFFFD"}:START_TAG_SPK_ICON:plus${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SPK_ICON:`;let t;t=$localize` New custom option ${"\uFFFD#2\uFFFD"}:START_TAG_SPK_ICON:pen${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SPK_ICON:`;let i;return i=$localize`Select an item...`,[["option",""],["enumOptionTemplate",""],["optionTemplate",""],o,e,t,[3,"disallowToggle"],["title",""],[1,"actions"],["spk-button","","type","button",1,"outlined","small"],[3,"searchable"],["menu",""],[1,"placeholder"],[1,"field-row"],["spk-button","","type","button",1,"outlined","small",3,"click"],["type","button"],["type","button",3,"click"],[1,"form-column"],[3,"startingPath","accepts","showFiles","showHiddenNodes","selectFiles"],[3,"startingPath"],[1,"primary","raised"],["spk-button","","type","button",1,"outlined","remove-btn",3,"click"],[1,"form-row"],["type","text",3,"ngModelChange","ngModel"],["prefix",""],[3,"for"],[1,"primary",3,"message"],["type","text",3,"ngModelChange","id","ngModel"],["autocomplete","off",3,"ngModelChange","type","id","ngModel"],["suffix","",1,"clickable"],["suffix","",1,"clickable",3,"click"],[3,"options","isClearable","optionTemplate"],["type","number",3,"ngModelChange","id","ngModel"],["placeholder",i,3,"options","isClearable"],["type","checkbox",3,"ngModelChange","id","ngModel"],[1,"primary","raised",3,"options","selectMultiple","optionTemplate"],["type","text","id","text",3,"ngModelChange","ngModel"]]},template:function(e,t){e&1&&(a(0,"spk-toggle-card",6),E(1,7)(2),q(3,3),N(),a(4,"div",8),x(5,pe,3,0,"button",9),a(6,"spk-menu",10)(7,"button",9),v(8,4),P(9,"spk-icon"),L(),p(),E(10,11),k(11,_e,4,1,null,null,y),N(),p()(),N(),x(13,me,2,0,"div",12),k(14,Ae,15,1,"div",13,y),p()),e&2&&(c("disallowToggle",!0),l(5),f(t.hasFreeTextSettings()?5:-1),l(),c("searchable",!0),l(5),h(t.nonSelectedOptionsGrouped()),l(2),f(t.selectedSettings().length===0?13:-1),l(),h(t.selectedSettings()))},dependencies:[re,te,oe,ee,ie,ne,le,J,j,X,H,W,U,Z,Q],styles:["[_nghost-%COMP%]{display:block}spk-select[_ngcontent-%COMP%]{--miw: p2r(120)}spk-toggle[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:1rem}.placeholder[_ngcontent-%COMP%]{color:var(--base-level-60R);text-align:center;padding:2rem 1rem}.field-row[_ngcontent-%COMP%]{display:grid;align-items:center;grid-template-columns:1fr 2.5rem;gap:.5rem}.field-row[_ngcontent-%COMP%] .remove-btn[_ngcontent-%COMP%]{align-self:flex-end}.form-column[_ngcontent-%COMP%]{display:flex;gap:.25rem;flex-direction:column}.form-column[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem}.form-column[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:1rem}.form-row[_ngcontent-%COMP%]{display:grid;grid-template-columns:3fr 1fr;gap:.5rem;align-items:flex-end}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;justify-content:flex-end}"],changeDetection:0})};export{ae as a};
1
+ import{a as le}from"./chunk-3YOT5OAB.js";import{a as Y}from"./chunk-CMXSHXAU.js";import{a as ee,b as te,d as ie,g as ne,i as oe,r as re}from"./chunk-LHSJLKCF.js";import{a as U,g as X,l as j,n as H,r as Z,w as J,x as Q,y as W}from"./chunk-PUSUA4U7.js";import{Ab as a,Bb as p,Cb as P,Db as E,Eb as N,Gb as S,Lc as M,Mb as v,Nb as L,Ob as q,Qa as l,Sb as C,Tb as s,X as B,Yb as d,_a as G,ca as u,da as g,db as K,ec as D,fc as m,gc as b,hc as F,ib as x,pa as $,rb as c,sa as O,wb as f,xb as y,yb as k,yc as A,zb as h}from"./chunk-PTC4N7TU.js";import{a as w,b as I}from"./chunk-7CGTOI24.js";function pe(n,o){if(n&1){let e=S();a(0,"button",14),C("click",function(){u(e);let i=s();return g(i.addFreeTextSetting())}),v(1,5),P(2,"spk-icon"),L(),p()}}function se(n,o){if(n&1){let e=S();a(0,"button",16,0),C("click",function(){let i=u(e).$implicit,r=s(2);return g(r.addSetting(i))}),m(2),p()}if(n&2){let e=o.$implicit;l(2),b(e.name)}}function _e(n,o){if(n&1&&(a(0,"h3",7),m(1),p(),k(2,se,3,1,"button",15,y)),n&2){let e=o.$implicit;l(),b(e.displayName),l(),h(e.options)}}function me(n,o){n&1&&(a(0,"div",12),m(1,"Add a setting above to get started."),p())}function ce(n,o){if(n&1){let e=S();a(0,"div",17)(1,"label"),m(2),p(),a(3,"div",22)(4,"spk-form-field")(5,"input",23),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateFreeTextSettingName(r,i))}),p(),a(6,"spk-icon",24),m(7,"rectangle-dashed"),p()(),a(8,"spk-form-field")(9,"input",23),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p(),a(10,"spk-icon",24),m(11,"textbox"),p()()()()}if(n&2){let e=s().$implicit;l(2),F(" ",e.FormView.shortDescription," "),l(3),c("ngModel",e.Name),l(4),c("ngModel",e.Value())}}function de(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function ue(n,o){if(n&1){let e=S();a(0,"app-file-tree",18)(1,"label",25),m(2),x(3,de,3,1,"spk-tooltip",26),p(),a(4,"input",27),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p()()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;c("startingPath",t.Value())("accepts",t.FormView.accepts)("showFiles",!0)("showHiddenNodes",!0)("selectFiles",!0),l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.Value())}}function ge(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Ce(n,o){if(n&1){let e=S();a(0,"app-file-tree",19)(1,"label",25),m(2),x(3,ge,3,1,"spk-tooltip",26),p(),a(4,"input",27),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p()()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;c("startingPath",t.Value()),l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.Value())}}function xe(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Se(n,o){n&1&&(a(0,"spk-icon",24),m(1,"link"),p())}function fe(n,o){n&1&&(a(0,"spk-icon",24),m(1,"textbox"),p())}function Fe(n,o){if(n&1){let e=S();a(0,"spk-form-field")(1,"label",25),m(2),x(3,xe,3,1,"spk-tooltip",26),p(),a(4,"input",27),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p(),x(5,Se,2,0,"spk-icon",24)(6,fe,2,0,"spk-icon",24),p()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.Value()),l(),f(t.FormView.type==="Path"?5:6)}}function Te(n,o){if(n&1){let e=S();a(0,"spk-icon",30),C("click",function(){u(e);let i=s(2).$implicit;return g(i.showPassword=!i.showPassword)}),m(1," eye "),p()}}function Oe(n,o){if(n&1){let e=S();a(0,"spk-icon",30),C("click",function(){u(e);let i=s(2).$implicit;return g(i.showPassword=!i.showPassword)}),m(1," eye-slash "),p()}}function Ve(n,o){if(n&1){let e=S();a(0,"spk-form-field")(1,"label",25),m(2),p(),a(3,"input",28),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p(),a(4,"spk-icon",24),m(5,"password"),p(),x(6,Te,2,0,"spk-icon",29)(7,Oe,2,0,"spk-icon",29),p()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),d("id","destination-",t.Name,"-",i,""),c("type",t.showPassword?"text":"password")("ngModel",t.Value()),l(3),f(t.showPassword?6:7)}}function we(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Ie(n,o){if(n&1&&m(0),n&2){let e=o.$implicit;F(" ",e," ")}}function ye(n,o){if(n&1){let e=S();a(0,"spk-select",31)(1,"label",25),m(2),x(3,we,3,1,"spk-tooltip",26),p(),a(4,"input",27),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p()(),x(5,Ie,1,1,"ng-template",null,1,A)}if(n&2){let e=D(6),t=s(),i=t.$implicit,r=t.$index;c("options",i.FormView.options)("isClearable",!1)("optionTemplate",e),l(),d("for","destination-",i.Name,"-",r,""),l(),F(" ",i.FormView.shortDescription," "),l(),f(i.FormView.longDescription?3:-1),l(),d("id","destination-",i.Name,"-",r,""),c("ngModel",i.Value())}}function ke(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function he(n,o){if(n&1){let e=S();a(0,"div",17)(1,"label",25),m(2),x(3,ke,3,1,"spk-tooltip",26),p(),a(4,"div",22)(5,"spk-form-field")(6,"input",32),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSizeSetting(r,i,"size"))}),p(),a(7,"spk-icon",24),m(8,"resize"),p()(),a(9,"spk-select",33)(10,"input",23),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSizeSetting(r,i,"unit"))}),p()()()()}if(n&2){let e=s(),t=e.$implicit,i=e.$index,r=s();l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(3),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.size()),l(3),c("options",r.sizeOptions())("isClearable",!1),l(),c("ngModel",t.unit())}}function Ne(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Me(n,o){if(n&1){let e=S();a(0,"spk-form-field")(1,"label",25),m(2),x(3,Ne,3,1,"spk-tooltip",26),p(),a(4,"input",32),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p(),a(5,"spk-icon",24),m(6,"numpad"),p()()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.Value())}}function $e(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Pe(n,o){if(n&1){let e=S();a(0,"spk-toggle",20)(1,"label",25),m(2),x(3,$e,3,1,"spk-tooltip",26),p(),a(4,"input",34),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p()()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.Value())}}function Ee(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function ve(n,o){if(n&1&&m(0),n&2){let e=o.$implicit;F(" ",e," ")}}function Le(n,o){if(n&1){let e=S();a(0,"spk-select",35)(1,"label",25),m(2),x(3,Ee,3,1,"spk-tooltip",26),p(),a(4,"input",36),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p()(),x(5,ve,1,1,"ng-template",null,2,A)}if(n&2){let e=D(6),t=s(),i=t.$implicit,r=t.$index;c("options",i.FormView.options)("selectMultiple",!0)("optionTemplate",e),l(),d("for","destination-",i.Name,"-",r,""),l(),F(" ",i.FormView.shortDescription," "),l(),f(i.FormView.longDescription?3:-1),l(),c("ngModel",i.Value())}}function De(n,o){if(n&1&&(a(0,"spk-tooltip",26)(1,"spk-icon"),m(2,"question"),p()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function be(n,o){if(n&1){let e=S();a(0,"spk-form-field")(1,"label",25),m(2),x(3,De,3,1,"spk-tooltip",26),p(),a(4,"input",27),C("ngModelChange",function(i){u(e);let r=s().$implicit,_=s();return g(_.updateSettingValue(r,i))}),p()()}if(n&2){let e=s(),t=e.$implicit,i=e.$index;l(),d("for","destination-",t.Name,"-",i,""),l(),F(" ",t.FormView.shortDescription," "),l(),f(t.FormView.longDescription?3:-1),l(),d("id","destination-",t.Name,"-",i,""),c("ngModel",t.Value())}}function Ae(n,o){if(n&1){let e=S();a(0,"div",13),x(1,ce,12,3,"div",17)(2,ue,5,14,"app-file-tree",18)(3,Ce,5,10,"app-file-tree",19)(4,Fe,7,10,"spk-form-field")(5,Ve,8,10,"spk-form-field")(6,ye,7,12)(7,he,11,12,"div",17)(8,Me,7,9,"spk-form-field")(9,Pe,5,9,"spk-toggle",20)(10,Le,7,9)(11,be,5,9,"spk-form-field"),a(12,"button",21),C("click",function(){let i=u(e).$implicit,r=s();return g(r.removeSetting(i))}),a(13,"spk-icon"),m(14,"x-bold"),p()()()}if(n&2){let e=o.$implicit;l(),f(e.FormView.type==="FreeText"?1:e.FormView.type==="FileTree"?2:e.FormView.type==="FolderTree"?3:e.FormView.type==="String"||e.FormView.type==="Path"||e.FormView.type==="Decimal"?4:e.FormView.type==="Password"?5:e.FormView.type==="Enumeration"?6:e.FormView.type==="Size"?7:e.FormView.type==="Integer"?8:e.FormView.type==="Boolean"?9:e.FormView.type==="Flags"?10:e.FormView.type==="Timespan"?11:-1)}}var ze=["Bytes","KB","MB","GB","TB","PB"],ae=class n{#e=B(Y);options=G.required();hiddenOptions=$([]);hasFreeTextSettings=$(!1);allOptionsGrouped=this.#e.allOptionsGrouped;allOptions=this.#e.allOptions;sizeOptions=O(ze);selectedSettings=M(()=>{let o=this.hiddenOptions();return this.options().map(t=>{let i=this.allOptions().find(r=>r.name===t.Name);if(i&&!o.includes(i.name)){if(i.type==="Size"){let T=t.Value?.replace(/[0-9]/g,""),V=t.Value?.replace(/[^0-9]/g,""),z=O(T&&T!==""?T:"MB"),R=O(V&&V!==""?parseInt(V):"");return I(w({},t),{Value:M(()=>R()+z()),unit:z,size:R,FormView:i})}let r=t.Value??"";i.type==="Boolean"&&(r=r&&r.toLowerCase()==="true"||!1),i.type==="Integer"&&(r=parseInt(r)||0);let _=O(r);return I(w({},t),{Value:_,FormView:i})}else if(this.hasFreeTextSettings())return I(w({},t),{Value:O(t.Value),FormView:{name:t.Name,type:"FreeText",shortDescription:"Custom settings argument",longDescription:"Custom settings argument"}});return null}).filter(t=>t!==null)});nonSelectedOptionsGrouped=M(()=>{let o=this.options().map(t=>t.Name),e=this.hiddenOptions();return this.allOptionsGrouped().map(t=>I(w({},t),{options:t.options.filter(i=>!o.includes(i.name)&&!e.includes(i.name))})).filter(t=>t.options.length>0)});addFreeTextSetting(){this.hasFreeTextSettings()&&this.options.update(o=>[...o,{Filter:null,Name:"",Value:""}])}addSetting(o){this.options.update(e=>{let t=o.defaultValue??"";return o.type==="Boolean"&&(t=t.toLowerCase()==="true"||!1),o.type==="Integer"&&(t=parseInt(t)||0),[...e,{Name:o.name,Value:t}]})}updateSettingValue(o,e){this.options.update(t=>{let i=[...t],r=i.findIndex(_=>_.Name===o.Name);return o.FormView.type==="Boolean"?(i[r].Value=e?"True":"False",i):o.FormView.type==="Integer"?(i[r].Value=e.toString(),i):(i[r].Value=e,i)})}updateFreeTextSettingName(o,e){this.options.update(t=>{let i=[...t],r=i.findIndex(_=>_.Name===o.Name);return i[r].Name=e,i})}updateSizeSetting(o,e,t){let i=o;this.options.update(r=>{let _=[...r],T=_.findIndex(V=>V.Name===i.Name);return t==="size"&&(_[T].Value=`${e}${i.unit()}`),t==="unit"&&(_[T].Value=`${i.size()}${e}`),_})}removeSetting(o){this.options.update(e=>e.filter(t=>t.Name!==o.Name))}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=K({type:n,selectors:[["app-options-list"]],inputs:{options:[1,"options"],hiddenOptions:[1,"hiddenOptions"],hasFreeTextSettings:[1,"hasFreeTextSettings"]},outputs:{options:"optionsChange"},decls:16,vars:4,consts:()=>{let o;o=$localize`Advanced options`;let e;e=$localize` Add advanced option ${"\uFFFD#9\uFFFD"}:START_TAG_SPK_ICON:plus${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SPK_ICON:`;let t;t=$localize` New custom option ${"\uFFFD#2\uFFFD"}:START_TAG_SPK_ICON:pen${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SPK_ICON:`;let i;return i=$localize`Select an item...`,[["option",""],["enumOptionTemplate",""],["optionTemplate",""],o,e,t,[3,"disallowToggle"],["title",""],[1,"actions"],["spk-button","","type","button",1,"outlined","small"],[3,"searchable"],["menu",""],[1,"placeholder"],[1,"field-row"],["spk-button","","type","button",1,"outlined","small",3,"click"],["type","button"],["type","button",3,"click"],[1,"form-column"],[3,"startingPath","accepts","showFiles","showHiddenNodes","selectFiles"],[3,"startingPath"],[1,"primary","raised"],["spk-button","","type","button",1,"outlined","remove-btn",3,"click"],[1,"form-row"],["type","text",3,"ngModelChange","ngModel"],["prefix",""],[3,"for"],[1,"primary",3,"message"],["type","text",3,"ngModelChange","id","ngModel"],["autocomplete","off",3,"ngModelChange","type","id","ngModel"],["suffix","",1,"clickable"],["suffix","",1,"clickable",3,"click"],[3,"options","isClearable","optionTemplate"],["type","number",3,"ngModelChange","id","ngModel"],["placeholder",i,3,"options","isClearable"],["type","checkbox",3,"ngModelChange","id","ngModel"],[1,"primary","raised",3,"options","selectMultiple","optionTemplate"],["type","text","id","text",3,"ngModelChange","ngModel"]]},template:function(e,t){e&1&&(a(0,"spk-toggle-card",6),E(1,7)(2),q(3,3),N(),a(4,"div",8),x(5,pe,3,0,"button",9),a(6,"spk-menu",10)(7,"button",9),v(8,4),P(9,"spk-icon"),L(),p(),E(10,11),k(11,_e,4,1,null,null,y),N(),p()(),N(),x(13,me,2,0,"div",12),k(14,Ae,15,1,"div",13,y),p()),e&2&&(c("disallowToggle",!0),l(5),f(t.hasFreeTextSettings()?5:-1),l(),c("searchable",!0),l(5),h(t.nonSelectedOptionsGrouped()),l(2),f(t.selectedSettings().length===0?13:-1),l(),h(t.selectedSettings()))},dependencies:[re,te,oe,ee,ie,ne,le,J,j,X,H,W,U,Z,Q],styles:["[_nghost-%COMP%]{display:block}spk-select[_ngcontent-%COMP%]{--miw: p2r(120)}spk-toggle[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:1rem}.placeholder[_ngcontent-%COMP%]{color:var(--base-level-60R);text-align:center;padding:2rem 1rem}.field-row[_ngcontent-%COMP%]{display:grid;align-items:center;grid-template-columns:1fr 2.5rem;gap:.5rem}.field-row[_ngcontent-%COMP%] .remove-btn[_ngcontent-%COMP%]{align-self:flex-end}.form-column[_ngcontent-%COMP%]{display:flex;gap:.25rem;flex-direction:column}.form-column[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem}.form-column[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:1rem}.form-row[_ngcontent-%COMP%]{display:grid;grid-template-columns:3fr 1fr;gap:.5rem;align-items:flex-end}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;justify-content:flex-end}"],changeDetection:0})};export{ae as a};
@@ -1 +1 @@
1
- import{a as S}from"./chunk-GEEPH37P.js";import{a as B}from"./chunk-XL5J65PI.js";import{a as z}from"./chunk-WZG34QS3.js";import{b as m,c as h}from"./chunk-KLIPTMVG.js";import{D as u,L as f,Lc as d,Mc as P,R as k,X as o,l as p,p as g,sa as n}from"./chunk-DTPZU6NP.js";import{a as l,b as a}from"./chunk-C6Q5SG76.js";var $={Backup_Begin:$localize`Starting backup …`,Backup_PreBackupVerify:$localize`Verifying backend data …`,Backup_PostBackupTest:$localize`Verifying remote data …`,Backup_PreviousBackupFinalize:$localize`Completing previous backup …`,Backup_ProcessingFiles:$localize`Processing files to backup …`,Backup_Finalize:$localize`Completing backup …`,Backup_WaitForUpload:$localize`Waiting for upload to finish …`,Backup_Delete:$localize`Deleting unwanted files …`,Backup_Compact:$localize`Compacting remote data …`,Backup_VerificationUpload:$localize`Uploading verification file …`,Backup_PostBackupVerify:$localize`Verifying backend data …`,Backup_Complete:$localize`Backup complete!`,Restore_Begin:$localize`Starting restore …`,Restore_RecreateDatabase:$localize`Rebuilding local database …`,Restore_PreRestoreVerify:$localize`Verifying remote data …`,Restore_CreateFileList:$localize`Building list of files to restore …`,Restore_CreateTargetFolders:$localize`Creating target folders …`,Restore_ScanForExistingFiles:$localize`Scanning existing files …`,Restore_ScanForLocalBlocks:$localize`Scanning for local blocks …`,Restore_PatchWithLocalBlocks:$localize`Patching files with local blocks …`,Restore_DownloadingRemoteFiles:$localize`Downloading files …`,Restore_PostRestoreVerify:$localize`Verifying restored files …`,Restore_Complete:$localize`Restore complete!`,Recreate_Running:$localize`Recreating database …`,Vacuum_Running:$localize`Vacuuming database …`,Repair_Running:$localize`Repairing database …`,Verify_Running:$localize`Verifying files …`,BugReport_Running:$localize`Creating bug report …`,Delete_Listing:$localize`Listing remote files …`,Delete_Deleting:$localize`Deleting remote files …`,"PurgeFiles_Begin,":$localize`Listing remote files for purge …`,"PurgeFiles_Process,":$localize`Purging files …`,"PurgeFiles_Compact,":$localize`Compacting remote data …`,"PurgeFiles_Complete,":$localize`Purging files complete!`,Error:$localize`Error!`},_=class r{#i=o(S);#a=o(h);#r=o(m);#o=o(z);#e=o(B);#t=n(!1);#l=n(null);statusData=this.#l.asReadonly();serverState=d(()=>{let e=this.#e.serverState();return e?(e.ProposedSchedule=e.ProposedSchedule?.map(i=>a(l({},i),{backup:i.Item1?this.#o.getBackupById(i.Item1):null})),e):null});isFetching=this.#t.asReadonly();connectionStatus=this.#e.connectionStatus;setConnectionMethod(e){this.#e.setConnectionMethod(e)}pollingInterval;#p=P(()=>{let e=this.#e.serverState();e?.ActiveTask&&this.pollingInterval===void 0?this.pollingInterval=setInterval(()=>{this.#n()},1e3):e?.ActiveTask||this.stopPollingProgress()});stopPollingProgress(){clearInterval(this.pollingInterval)}#n(){this.#t.set(!0),this.#a.getApiV1Progressstate().pipe(f(e=>{let i=e.TaskID??null;return i===null?p(e):this.#r.getApiV1TaskByTaskid({taskid:i}).pipe(g(t=>a(l({},e),{task:t??null})))}),u(()=>this.#t.set(!1))).subscribe({next:e=>{let i=e.TaskID??null,t=e.BackupID??null;i!==null&&t!==null&&(e.backup=this.#o.getBackupById(t)),this.#l.set(a(l({},e),{progress:this.#s(e),statusText:this.#c(e),actionText:e.backup?.Backup?.Name??$localize`Running task`}))},error:e=>{e.status===404&&this.stopPollingProgress()}})}#s(e){let i=-1;if(e.task&&e)if(e.Phase==="Backup_ProcessingFiles"||e.Phase==="Restore_DownloadingRemoteFiles")if(e.StillCounting)i=0;else{let t=e.CurrentFilecomplete?0:e.CurrentFileoffset,s=e.TotalFileCount-e.ProcessedFileCount,c=e.TotalFileSize-e.ProcessedFileSize-t;i=(e.ProcessedFileSize+t)/e.TotalFileSize,e.ProcessedFileCount===0?i=0:i>=.9&&(i=.9)}else e.Phase==="Backup_Finalize"||e.Phase==="Backup_WaitForUpload"?i=.9:e.Phase==="Backup_Delete"||e.Phase==="Backup_Compact"?i=.95:e.Phase==="Backup_VerificationUpload"||e.Phase==="Backup_PostBackupVerify"?i=.98:e.Phase==="Backup_Complete"||e.Phase==="Backup_WaitForUpload"?i=1:e.OverallProgress>0&&(i=e.OverallProgress);return i}#c(e){let i="Running \u2026";if(e.task&&e&&(i=e.Phase?$[e.Phase]:"Running \u2026",e.Phase==="Backup_ProcessingFiles"||e.Phase==="Restore_DownloadingRemoteFiles"))if(e.StillCounting)i=`Counting (${e.TotalFileCount} files found, ${this.#i.transform(e.TotalFileSize)})`;else{let t=e.CurrentFilecomplete?0:e.CurrentFileoffset,s=e.TotalFileCount-e.ProcessedFileCount,c=e.TotalFileSize-e.ProcessedFileSize-t,R=e.BackendSpeed<0?"":` at ${this.#i.transform(e.BackendSpeed)}/s`;i=`${e.Phase==="Restore_DownloadingRemoteFiles"?"Restoring: ":""}${s} files (${this.#i.transform(c)}) to go ${R}`}return i}static \u0275fac=function(i){return new(i||r)};static \u0275prov=k({token:r,factory:r.\u0275fac,providedIn:"root"})};export{_ as a};
1
+ import{a as S}from"./chunk-HGERKLOF.js";import{a as B}from"./chunk-UT45C7WK.js";import{a as z}from"./chunk-QX5XWUM2.js";import{b as m,c as h}from"./chunk-L3T52MCL.js";import{D as u,L as f,Lc as d,Mc as P,R as k,X as o,l as p,p as g,sa as n}from"./chunk-PTC4N7TU.js";import{a as l,b as a}from"./chunk-7CGTOI24.js";var $={Backup_Begin:$localize`Starting backup …`,Backup_PreBackupVerify:$localize`Verifying backend data …`,Backup_PostBackupTest:$localize`Verifying remote data …`,Backup_PreviousBackupFinalize:$localize`Completing previous backup …`,Backup_ProcessingFiles:$localize`Processing files to backup …`,Backup_Finalize:$localize`Completing backup …`,Backup_WaitForUpload:$localize`Waiting for upload to finish …`,Backup_Delete:$localize`Deleting unwanted files …`,Backup_Compact:$localize`Compacting remote data …`,Backup_VerificationUpload:$localize`Uploading verification file …`,Backup_PostBackupVerify:$localize`Verifying backend data …`,Backup_Complete:$localize`Backup complete!`,Restore_Begin:$localize`Starting restore …`,Restore_RecreateDatabase:$localize`Rebuilding local database …`,Restore_PreRestoreVerify:$localize`Verifying remote data …`,Restore_CreateFileList:$localize`Building list of files to restore …`,Restore_CreateTargetFolders:$localize`Creating target folders …`,Restore_ScanForExistingFiles:$localize`Scanning existing files …`,Restore_ScanForLocalBlocks:$localize`Scanning for local blocks …`,Restore_PatchWithLocalBlocks:$localize`Patching files with local blocks …`,Restore_DownloadingRemoteFiles:$localize`Downloading files …`,Restore_PostRestoreVerify:$localize`Verifying restored files …`,Restore_Complete:$localize`Restore complete!`,Recreate_Running:$localize`Recreating database …`,Vacuum_Running:$localize`Vacuuming database …`,Repair_Running:$localize`Repairing database …`,Verify_Running:$localize`Verifying files …`,BugReport_Running:$localize`Creating bug report …`,Delete_Listing:$localize`Listing remote files …`,Delete_Deleting:$localize`Deleting remote files …`,"PurgeFiles_Begin,":$localize`Listing remote files for purge …`,"PurgeFiles_Process,":$localize`Purging files …`,"PurgeFiles_Compact,":$localize`Compacting remote data …`,"PurgeFiles_Complete,":$localize`Purging files complete!`,Error:$localize`Error!`},_=class r{#i=o(S);#a=o(h);#r=o(m);#o=o(z);#e=o(B);#t=n(!1);#l=n(null);statusData=this.#l.asReadonly();serverState=d(()=>{let e=this.#e.serverState();return e?(e.ProposedSchedule=e.ProposedSchedule?.map(i=>a(l({},i),{backup:i.Item1?this.#o.getBackupById(i.Item1):null})),e):null});isFetching=this.#t.asReadonly();connectionStatus=this.#e.connectionStatus;setConnectionMethod(e){this.#e.setConnectionMethod(e)}pollingInterval;#p=P(()=>{let e=this.#e.serverState();e?.ActiveTask&&this.pollingInterval===void 0?this.pollingInterval=setInterval(()=>{this.#n()},1e3):e?.ActiveTask||this.stopPollingProgress()});stopPollingProgress(){clearInterval(this.pollingInterval)}#n(){this.#t.set(!0),this.#a.getApiV1Progressstate().pipe(f(e=>{let i=e.TaskID??null;return i===null?p(e):this.#r.getApiV1TaskByTaskid({taskid:i}).pipe(g(t=>a(l({},e),{task:t??null})))}),u(()=>this.#t.set(!1))).subscribe({next:e=>{let i=e.TaskID??null,t=e.BackupID??null;i!==null&&t!==null&&(e.backup=this.#o.getBackupById(t)),this.#l.set(a(l({},e),{progress:this.#s(e),statusText:this.#c(e),actionText:e.backup?.Backup?.Name??$localize`Running task`}))},error:e=>{e.status===404&&this.stopPollingProgress()}})}#s(e){let i=-1;if(e.task&&e)if(e.Phase==="Backup_ProcessingFiles"||e.Phase==="Restore_DownloadingRemoteFiles")if(e.StillCounting)i=0;else{let t=e.CurrentFilecomplete?0:e.CurrentFileoffset,s=e.TotalFileCount-e.ProcessedFileCount,c=e.TotalFileSize-e.ProcessedFileSize-t;i=(e.ProcessedFileSize+t)/e.TotalFileSize,e.ProcessedFileCount===0?i=0:i>=.9&&(i=.9)}else e.Phase==="Backup_Finalize"||e.Phase==="Backup_WaitForUpload"?i=.9:e.Phase==="Backup_Delete"||e.Phase==="Backup_Compact"?i=.95:e.Phase==="Backup_VerificationUpload"||e.Phase==="Backup_PostBackupVerify"?i=.98:e.Phase==="Backup_Complete"||e.Phase==="Backup_WaitForUpload"?i=1:e.OverallProgress>0&&(i=e.OverallProgress);return i}#c(e){let i="Running \u2026";if(e.task&&e&&(i=e.Phase?$[e.Phase]:"Running \u2026",e.Phase==="Backup_ProcessingFiles"||e.Phase==="Restore_DownloadingRemoteFiles"))if(e.StillCounting)i=`Counting (${e.TotalFileCount} files found, ${this.#i.transform(e.TotalFileSize)})`;else{let t=e.CurrentFilecomplete?0:e.CurrentFileoffset,s=e.TotalFileCount-e.ProcessedFileCount,c=e.TotalFileSize-e.ProcessedFileSize-t,R=e.BackendSpeed<0?"":` at ${this.#i.transform(e.BackendSpeed)}/s`;i=`${e.Phase==="Restore_DownloadingRemoteFiles"?"Restoring: ":""}${s} files (${this.#i.transform(c)}) to go ${R}`}return i}static \u0275fac=function(i){return new(i||r)};static \u0275prov=k({token:r,factory:r.\u0275fac,providedIn:"root"})};export{_ as a};
@@ -1 +1 @@
1
- import{c as I}from"./chunk-AIOUSVMR.js";import{b as A}from"./chunk-KLIPTMVG.js";import{a as y,c as k}from"./chunk-V5GVLIPJ.js";import{C as o,D as m,N as l,R as a,X as r,d as p,i as h,l as u,p as g,sa as i,y as d}from"./chunk-DTPZU6NP.js";var c=class s{#i=i(null);#n=window.self!==window.top;#e=i(this.#n);relayIsEnabled=this.#e.asReadonly();config=this.#i.asReadonly();configLoaded=this.#n?new h:null;isLoading=i(this.#n);parentIframeListner=null;parentOrigin="*";fetchConfig(){this.#t(),this.#n&&(this.#e.set(!0),this.parentIframeListner=new AbortController,this.#s("connected"),window.addEventListener("message",e=>{if(e.data.startsWith("access:")){let t=e.data.replace("access:",""),n=JSON.parse(t);if(!n?.accessToken||!n?.clientId){this.#s("error:invalid-config"),this.#e.set(!1);return}if(typeof n.clientId!="string"){this.#s("error:invalid-config"),this.#e.set(!1);return}if(typeof n.accessToken!="string"){this.#s("error:invalid-config"),this.#e.set(!1);return}console.info("postMessage config set"),this.#i.set(n),this.configLoaded?.next(!0),this.isLoading.set(!1),this.#s("handshake-complete")}},{signal:this.parentIframeListner.signal}))}#s(e){window.parent.postMessage(e,"*")}#t(){this.parentIframeListner&&(this.parentIframeListner.abort(),this.parentIframeListner=null)}setConfig(e){this.#i.set(e)}clearConfig(){this.#i.set(null)}static \u0275fac=function(t){return new(t||s)};static \u0275prov=a({token:s,factory:s.\u0275fac,providedIn:"root"})};var f="PROXY_AUTHED_FAKE_TOKEN",b=class s{#i=r(I);#n=r(k);#e=r(A);#s=r(c);#t=i(null);#r=i(!1);token=this.#t.asReadonly();isLoggingOut=this.#r.asReadonly();login(e){return this.#e.postApiV1AuthLogin({requestBody:{Password:e,RememberMe:!0}}).pipe(o(1),l(t=>t.AccessToken&&this.#t.set(t.AccessToken)))}refreshToken(){return this.#s.relayIsEnabled()?(this.#t.set(f),new p(e=>{e.next({AccessToken:f}),e.complete()})):this.#e.postApiV1AuthRefresh().pipe(o(1),l(e=>e.AccessToken&&this.#t.set(e.AccessToken)))}checkProxyAuthed(){let e=new y({"custom-proxy-check":"true"});return this.#n.get("/api/v1/systeminfo",{headers:e}).pipe(g(()=>(this.#t.set(f),!0)),d(()=>u(!1)))}logout(){this.#r.set(!0),this.#e.postApiV1AuthRefreshLogout().pipe(o(1),m(()=>{this.#r.set(!1),this.#t.set(null),this.#i.navigate(["/login"])})).subscribe()}static \u0275fac=function(t){return new(t||s)};static \u0275prov=a({token:s,factory:s.\u0275fac,providedIn:"root"})};export{c as a,f as b,b as c};
1
+ import{c as I}from"./chunk-WBNOGAKJ.js";import{b as A}from"./chunk-L3T52MCL.js";import{a as y,c as k}from"./chunk-4XPN5ZGE.js";import{C as o,D as m,N as l,R as a,X as r,d as p,i as h,l as u,p as g,sa as i,y as d}from"./chunk-PTC4N7TU.js";var c=class s{#i=i(null);#n=window.self!==window.top;#e=i(this.#n);relayIsEnabled=this.#e.asReadonly();config=this.#i.asReadonly();configLoaded=this.#n?new h:null;isLoading=i(this.#n);parentIframeListner=null;parentOrigin="*";fetchConfig(){this.#t(),this.#n&&(this.#e.set(!0),this.parentIframeListner=new AbortController,this.#s("connected"),window.addEventListener("message",e=>{if(e.data.startsWith("access:")){let t=e.data.replace("access:",""),n=JSON.parse(t);if(!n?.accessToken||!n?.clientId){this.#s("error:invalid-config"),this.#e.set(!1);return}if(typeof n.clientId!="string"){this.#s("error:invalid-config"),this.#e.set(!1);return}if(typeof n.accessToken!="string"){this.#s("error:invalid-config"),this.#e.set(!1);return}console.info("postMessage config set"),this.#i.set(n),this.configLoaded?.next(!0),this.isLoading.set(!1),this.#s("handshake-complete")}},{signal:this.parentIframeListner.signal}))}#s(e){window.parent.postMessage(e,"*")}#t(){this.parentIframeListner&&(this.parentIframeListner.abort(),this.parentIframeListner=null)}setConfig(e){this.#i.set(e)}clearConfig(){this.#i.set(null)}static \u0275fac=function(t){return new(t||s)};static \u0275prov=a({token:s,factory:s.\u0275fac,providedIn:"root"})};var f="PROXY_AUTHED_FAKE_TOKEN",b=class s{#i=r(I);#n=r(k);#e=r(A);#s=r(c);#t=i(null);#r=i(!1);token=this.#t.asReadonly();isLoggingOut=this.#r.asReadonly();login(e){return this.#e.postApiV1AuthLogin({requestBody:{Password:e,RememberMe:!0}}).pipe(o(1),l(t=>t.AccessToken&&this.#t.set(t.AccessToken)))}refreshToken(){return this.#s.relayIsEnabled()?(this.#t.set(f),new p(e=>{e.next({AccessToken:f}),e.complete()})):this.#e.postApiV1AuthRefresh().pipe(o(1),l(e=>e.AccessToken&&this.#t.set(e.AccessToken)))}checkProxyAuthed(){let e=new y({"custom-proxy-check":"true"});return this.#n.get("/api/v1/systeminfo",{headers:e}).pipe(g(()=>(this.#t.set(f),!0)),d(()=>u(!1)))}logout(){this.#r.set(!0),this.#e.postApiV1AuthRefreshLogout().pipe(o(1),m(()=>{this.#r.set(!1),this.#t.set(null),this.#i.navigate(["/login"])})).subscribe()}static \u0275fac=function(t){return new(t||s)};static \u0275prov=a({token:s,factory:s.\u0275fac,providedIn:"root"})};export{c as a,f as b,b as c};
@@ -1 +1 @@
1
- import{o as _e}from"./chunk-M5YHW43W.js";import"./chunk-Q67EYU7V.js";import"./chunk-DNHLTHLR.js";import{a as oe}from"./chunk-N5K6ODRA.js";import"./chunk-RCP6EKCC.js";import"./chunk-3HJFVNAL.js";import{a as ce}from"./chunk-RBRHRXAU.js";import{a as J}from"./chunk-LFPZBC5Y.js";import{a as Ct}from"./chunk-UDBZI5KJ.js";import"./chunk-CK5N2PPF.js";import{a as it}from"./chunk-25IC7WV6.js";import{a as Et}from"./chunk-VFLEQIHL.js";import"./chunk-RDRLCN5M.js";import"./chunk-GEEPH37P.js";import"./chunk-XL5J65PI.js";import"./chunk-WZG34QS3.js";import{b as Y,d as ee,e as dt,g as te,h as pt,k as St,m as gt,n as Tt,p as ut,q as mt,r as ne,s as ie}from"./chunk-4IJQ7AAQ.js";import"./chunk-TYO44G6M.js";import"./chunk-AIOUSVMR.js";import"./chunk-THUAAYGA.js";import{a as j,b as K,g as Q,k as ot,l as Z,o as st,p as rt,q as at,r as lt,x as _t,y as ct}from"./chunk-ECH6I3YN.js";import{b as v}from"./chunk-KLIPTMVG.js";import"./chunk-V5GVLIPJ.js";import"./chunk-2HS3CYRN.js";import"./chunk-UQH5ZQG7.js";import{Ab as i,Bb as o,Cb as P,D as R,Gb as O,Lc as b,Mb as U,Mc as w,Nb as B,Oa as je,Ob as a,Pb as ae,Qa as l,Qb as le,R as z,Rb as Je,Sb as S,Tb as p,Wb as Ye,X as T,Xa as Ke,c as qe,ca as u,cc as et,da as m,db as $,dc as tt,fc as I,gc as H,hc as W,ib as E,kc as y,l as L,lc as G,mc as A,ob as Qe,pb as Ze,qc as nt,rb as h,rc as q,sa as c,tb as f,wb as C,y as x}from"./chunk-DTPZU6NP.js";import"./chunk-C6Q5SG76.js";var k=class s{#e=T(v);#i=oe(this.#e.getApiV1Serversettings());#t=c(void 0);serverSettings=b(()=>this.#t()||this.#i());refreshServerSettings(){this.#e.getApiV1Serversettings().subscribe({next:t=>{this.#t.set(t)}})}withRefresh(){return qe(R(()=>this.refreshServerSettings()))}static \u0275fac=function(e){return new(e||s)};static \u0275prov=z({token:s,factory:s.\u0275fac,providedIn:"root"})};var ht=["formRef"],Pt=()=>[import("./chunk-SSXZ4GVY.js").then(s=>s.OptionsListComponent)],Ot=()=>["--no-encryption","--exclude-files-attributes","--skip-files-larger-than","dblock-size","no-encryption"];function Rt(s,t){s&1&&(i(0,"spk-alert",3),a(1,1),o())}function It(s,t){if(s&1){let e=O();i(0,"app-options-list",5),A("optionsChange",function(r){u(e);let d=p();return G(d.settings,r)||(d.settings=r),m(r)}),o()}if(s&2){let e=p();y("options",e.settings),h("hasFreeTextSettings",!0)("hiddenOptions",q(3,Ot))}}var yt=["Bytes","KB","MB","GB","TB","PB"],D=class s{#e=T(_e);#i=T(k);#t=T(v);formRef=Ke.required("formRef");optionsForm=this.#e.optionsForm;settings=this.#e.settings;isSubmitting=c(!1);isLoadingOptions=c(!0);saved=c(!1);sizeOptions=c(yt);lastRecievedServerSettings=c({});serverSettingsEffect=w(()=>{let t=this.#i.serverSettings();if(t===void 0)return;this.lastRecievedServerSettings.set(t),this.isLoadingOptions.set(!0);let e=Object.entries(t);e.forEach(([n,r],d)=>{if(n.startsWith("--")){let N=n.replace("--","");this.settings.update(g=>(g.some(M=>M.Name===N)||g.push({Name:N,Value:r}),g))}d===e.length-1&&this.isLoadingOptions.set(!1)})});submit(){this.isSubmitting.set(!0);let t=this.settings(),e=this.lastRecievedServerSettings(),n=t.map(g=>g.Name),d=Object.keys(e).filter(g=>!n.includes(g.replace("--",""))),N=t.reduce((g,M)=>(g[`--${M.Name}`]=M.Value,g),{});d.forEach(g=>{N[g]=null}),this.#t.patchApiV1Serversettings({requestBody:N}).pipe(R(()=>this.isSubmitting.set(!1))).subscribe({next:()=>{this.#i.refreshServerSettings(),this.saved.set(!0),setTimeout(()=>{this.saved.set(!1)},3e3)}})}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=$({type:s,selectors:[["app-advanced-options-settings"]],viewQuery:function(e,n){e&1&&et(n.formRef,ht,5),e&2&&tt()},features:[nt([_e])],decls:8,vars:4,consts:()=>{let t;t=$localize`${"\uFFFD#4\uFFFD"}:START_TAG_SPK_ICON:floppy-disk${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_SPK_ICON: Save settings `;let e;return e=$localize`Settings saved`,[t,e,[1,"actions"],[1,"success"],["spk-button","","type","button",1,"raised","primary",3,"click"],[3,"optionsChange","options","hasFreeTextSettings","hiddenOptions"]]},template:function(e,n){e&1&&(i(0,"div",2),E(1,Rt,2,0,"spk-alert",3),i(2,"button",4),S("click",function(){return n.submit()}),U(3,0),P(4,"spk-icon"),B(),o()(),E(5,It,1,4),Qe(6,5,Pt)),e&2&&(l(),C(n.saved()?1:-1),l(),f("loader",n.isSubmitting()),l(4),Ze(!n.isLoadingOptions()))},dependencies:[ie,Q,j,K],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:40.625rem;justify-self:flex-end}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;justify-content:flex-end;margin-bottom:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-column[_ngcontent-%COMP%]{display:flex;flex-direction:column}.form-column[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem}.form-column[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:1rem}.field-row[_ngcontent-%COMP%]{display:grid;align-items:flex-end;grid-template-columns:1fr 2.5rem;gap:.5rem}.form-row[_ngcontent-%COMP%]{display:grid;grid-template-columns:3fr 1fr;gap:.5rem;align-items:flex-end}.form-wrap[_ngcontent-%COMP%]{display:grid;grid-template-columns:2fr 2.5rem;gap:.5rem;align-items:flex-end}.remote-volume-wrap[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.remote-volume-wrap[_ngcontent-%COMP%] p.warning[_ngcontent-%COMP%]{color:#7d7d00}.row-inputs[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.5rem}.row-inputs[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{flex:1 0}.advanced-option[_ngcontent-%COMP%]{display:grid;gap:.5rem;grid-template-columns:1fr 1fr 40px;align-items:flex-end}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}"],changeDetection:0})};var F=class s{#e=T(v);#i=T(J);repeatRegisterTimer=null;state=c("unknown");claimUrl=c(null);registerUrl=c("");status=b(()=>{let t=this.state();return t==="enabled"?"Remote control is enabled but not connected":t==="connected"?"Remote control is connected":t==="registering"?"Registering machine...":t==="registeringfaulted"?"Registration failed":t==="registered"?"Registered, waiting for accept":t==="disabled"?"Remote control is configured but not enabled":t==="unknown"?"...loading...":"Remote control is not set up"});sysInfoEffect=w(()=>{let t=this.#i.systemInfo();t&&this.registerUrl.set(t.RemoteControlRegistrationUrl??"")});#t(t){t.RegistrationUrl&&this.claimUrl.set(t.RegistrationUrl),t.IsConnected?this.state.set("connected"):t.IsEnabled?this.state.set("enabled"):t.CanEnable?this.state.set("disabled"):t.IsRegisteringFaulted?this.state.set("registeringfaulted"):t.IsRegistering?t.RegistrationUrl!=null&&t.RegistrationUrl.trim().length>0?this.state.set("registered"):this.state.set("registering"):this.state.set("inactive");let e=this.state();this.repeatRegisterTimer!==null&&(clearTimeout(this.repeatRegisterTimer),this.repeatRegisterTimer=null),e==="registering"&&(this.repeatRegisterTimer=setTimeout(()=>{this.#e.postApiV1RemotecontrolRegister({requestBody:{RegistrationUrl:""}}).subscribe({next:n=>this.#t(n),error:n=>this.#n(n)})},5e3)),(e==="enabled"||e==="registered")&&(this.repeatRegisterTimer=setTimeout(()=>{this.#e.getApiV1RemotecontrolStatus().subscribe({next:n=>this.#t(n),error:n=>this.#n(n)})},5e3)),t.IsRegistering&&t.CanEnable&&this.#e.deleteApiV1RemotecontrolRegister().subscribe({next:n=>this.#t(n)})}#n(t){this.#e.getApiV1RemotecontrolStatus().subscribe({next:e=>this.#t(e)})}refreshRemoteControlStatus(){this.#e.getApiV1RemotecontrolStatus().subscribe({next:t=>this.#t(t),error:t=>this.#n(t)})}beginRemoteRegistration(){this.state.set("registering"),this.#e.postApiV1RemotecontrolRegister({requestBody:{RegistrationUrl:this.registerUrl()}}).subscribe({next:t=>this.#t(t),error:t=>this.#n(t)})}cancelRemoteRegistration(){this.#e.deleteApiV1RemotecontrolRegister().subscribe({next:t=>this.#t(t),error:t=>this.#n(t)})}enableRemoteControl(){this.#e.postApiV1RemotecontrolEnable().subscribe({next:t=>this.#t(t),error:t=>this.#n(t)})}disableRemoteControl(){this.#e.postApiV1RemotecontrolDisable().subscribe({next:t=>this.#t(t),error:t=>this.#n(t)})}deleteRemoteControl(){let t=this;confirm("Are you sure you want to delete the remote control registration?")&&t.#e.deleteApiV1RemotecontrolRegistration().subscribe({next:e=>t.#t(e),error:e=>t.#n(e)})}static \u0275fac=function(e){return new(e||s)};static \u0275prov=z({token:s,factory:s.\u0275fac,providedIn:"root"})};function At(s,t){if(s&1){let e=O();i(0,"spk-form-field",10)(1,"input",11),A("ngModelChange",function(r){u(e);let d=p(2);return G(d.registerUrl,r)||(d.registerUrl=r),m(r)}),o()(),i(2,"button",12),S("click",function(){u(e);let r=p(2);return m(r.register())}),a(3,0),o()}if(s&2){let e=p(2);l(),y("ngModel",e.registerUrl)}}function vt(s,t){if(s&1&&(i(0,"div",8)(1,"label"),a(2,1),o(),i(3,"a",13),I(4),o()()),s&2){let e=p(2);l(3),Ye("href",e.claimUrl(),je),l(),H(e.claimUrl())}}function $t(s,t){s&1&&(i(0,"div",8)(1,"label"),a(2,2),o()())}function bt(s,t){if(s&1){let e=O();i(0,"button",12),S("click",function(){u(e);let r=p(2);return m(r.cancel())}),a(1,3),o()}}function wt(s,t){if(s&1){let e=O();i(0,"button",12),S("click",function(){u(e);let r=p(2);return m(r.disable())}),a(1,4),o()}}function kt(s,t){if(s&1){let e=O();i(0,"button",12),S("click",function(){u(e);let r=p(2);return m(r.enable())}),a(1,5),o(),i(2,"button",14),S("click",function(){u(e);let r=p(2);return m(r.delete())}),a(3,6),o()}}function Ft(s,t){if(s&1&&(i(0,"div",7),E(1,At,4,1)(2,vt,5,2,"div",8)(3,$t,3,0,"div",8)(4,bt,2,0,"button",9)(5,wt,2,0,"button",9)(6,kt,4,0),o()),s&2){let e=p();l(),C(e.state()==="inactive"?1:-1),l(),C(e.state()==="registered"?2:-1),l(),C(e.state()==="registering"?3:-1),l(),C(e.state()==="registering"||e.state()==="registeringfaulted"||e.state()==="registered"?4:-1),l(),C(e.state()==="connected"||e.state()==="enabled"?5:-1),l(),C(e.state()==="disabled"?6:-1)}}var re=class s{#e=T(F);state=this.#e.state;claimUrl=this.#e.claimUrl;registerUrl=this.#e.registerUrl;ngOnInit(){this.#e.refreshRemoteControlStatus()}cancel(){this.#e.cancelRemoteRegistration()}register(){this.#e.beginRemoteRegistration()}disable(){this.#e.disableRemoteControl()}enable(){this.#e.enableRemoteControl()}delete(){this.#e.deleteRemoteControl()}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=$({type:s,selectors:[["app-remote-control"]],decls:1,vars:1,consts:()=>{let t;t=$localize`Register for remote control`;let e;e=$localize`Machine is now registered, open this link to add it to your account:`;let n;n=$localize`Registering, please wait...`;let r;r=$localize`Cancel registration`;let d;d=$localize`Disable remote control`;let N;N=$localize`Enable remote control`;let g;return g=$localize`Delete remote control setup`,[t,e,n,r,d,N,g,[1,"field-row"],[1,"field-col"],["type","button","spk-button","",1,"raised"],["label","Registration URL","for","remoteControlRegisterUrl"],["type","text","spk-input","","id","remoteControlRegisterUrl","name","remoteControlRegisterUrl",3,"ngModelChange","ngModel"],["type","button","spk-button","",1,"raised",3,"click"],["target","_blank",3,"href"],["type","button","spk-button","",1,"raised","error",3,"click"]]},template:function(e,n){e&1&&E(0,Ft,7,6,"div",7),e&2&&C(n.state()!=="unknown"?0:-1)},dependencies:[ne,Y,ee,te,Z],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] button[_ngcontent-%COMP%]{white-space:nowrap}.field-row[_ngcontent-%COMP%]{display:flex;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] spk-form-field[_ngcontent-%COMP%], .field-row[_ngcontent-%COMP%] spk-select[_ngcontent-%COMP%]{flex:1 0}"],changeDetection:0})};var Lt=()=>({standalone:!0});function xt(s,t){s&1&&(i(0,"spk-icon",73),I(1,"check"),o())}function Dt(s,t){s&1&&(i(0,"spk-icon",74),I(1,"prohibit"),o())}function Xt(s,t){if(s&1){let e=O();i(0,"button",78),S("click",function(){u(e);let r=p(2);return m(r.updatePassphrase())}),a(1,35),o()}if(s&2){let e=p(2);f("loader",e.isUpdating())}}function Vt(s,t){if(s&1){let e=O();i(0,"spk-tooltip",77)(1,"button",79),S("click",function(){u(e);let r=p(2);return m(r.updatePassphrase())}),a(2,36),o()()}if(s&2){let e=p(2);l(),f("loader",e.isUpdating()),h("disabled",!0)}}function zt(s,t){if(s&1){let e=O();i(0,"spk-form-field")(1,"label",69),a(2,32),o(),i(3,"input",70),A("ngModelChange",function(r){u(e);let d=p();return G(d.passphrase,r)||(d.passphrase=r),m(r)}),o()(),i(4,"spk-form-field")(5,"label",71),a(6,33),o(),i(7,"input",72),A("ngModelChange",function(r){u(e);let d=p();return G(d.repeatPassphrase,r)||(d.repeatPassphrase=r),m(r)}),o(),E(8,xt,2,0,"spk-icon",73)(9,Dt,2,0,"spk-icon",74),o(),i(10,"div",50)(11,"button",75),S("click",function(){u(e);let r=p();return m(r.cancelPasswordChange())}),a(12,34),o(),E(13,Xt,2,2,"button",76)(14,Vt,3,3,"spk-tooltip",77),o()}if(s&2){let e=p();l(3),y("ngModel",e.passphrase),l(4),h("disabled",e.passphrase().length===0),y("ngModel",e.repeatPassphrase),l(),C(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?8:9),l(3),f("loader",e.isUpdating()),l(2),C(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?13:14)}}function Ut(s,t){s&1&&(i(0,"spk-icon",80),I(1,"check"),o())}function Bt(s,t){if(s&1){let e=O();i(0,"div",50)(1,"button",75),S("click",function(){u(e);let r=p();return m(r.openPassphraseForm())}),a(2,37),o(),E(3,Ut,2,0,"spk-icon",80),o()}if(s&2){let e=p();l(3),C(e.passwordUpdated()?3:-1)}}function Ht(s,t){if(s&1){let e=O();i(0,"spk-form-field")(1,"label",81),a(2,38),o(),i(3,"textarea",82),A("ngModelChange",function(r){u(e);let d=p();return G(d.allowedHostnames,r)||(d.allowedHostnames=r),m(r)}),o()(),i(4,"spk-alert",83),a(5,39),o(),i(6,"button",78),S("click",function(){u(e);let r=p();return m(r.updateAllowedHostnames())}),a(7,40),o()}if(s&2){let e=p();l(3),y("ngModel",e.allowedHostnames),l(3),f("loader",e.updatingAllowedHosts())}}function Wt(s,t){if(s&1&&I(0),s&2){let e,n=p();W(" ",(e=n.sysinfo())==null?null:e.ServerVersion," ")}}function qt(s,t){s&1&&P(0,"spk-progress-bar",55)}function jt(s,t){if(s&1&&I(0),s&2){let e=t.$implicit;W(" ",e.label," ")}}function Kt(s,t){if(s&1&&I(0),s&2){let e=t.$implicit;W(" ",e.label," ")}}var X=new mt,Nt=[{value:"s",label:$localize`Seconds`},{value:"m",label:$localize`Minutes`},{value:"h",label:$localize`Hours`}],Mt=[{value:"",label:$localize`System default (information)`},{value:"information",label:$localize`Usage statistics, warnings, errors, and crashes`},{value:"warning",label:$localize`Warnings, errors and crashes`},{value:"error",label:$localize`Errors and crashes`},{value:"crash",label:$localize`Crashes only`},{value:"none",label:$localize`None / disabled`}],de=class s{#e=T(Ct);#i=T(J);#t=T(v);#n=T(k);#r=T(F);#o=T(it);#s=this.#o.getItem("locale")??"en-US";sysinfo=this.#i.systemInfo;isDarkMode=this.#e.isDarkMode;editAs=c("list");previousLang=this.#s;langCtrl=c(this.#s);remoteControlStatus=this.#r.status;settingsForm=X.group({pauseSettings:X.group({time:X.control(0),timeType:X.control("s")}),usageStatistics:X.control("")});updatingChannel=c(!1);updateChannel=c("");setNewChannel(t){let e=this.updateChannel();this.updateChannel.set(t),this.#t.patchApiV1Serversettings({requestBody:{"update-channel":t}}).pipe(this.#n.withRefresh(),R(()=>this.updatingChannel.set(!1)),x(()=>(this.updateChannel.set(e),L(null)))).subscribe()}allowRemoteAccess=c(!1);allowedHostnames=c("");loadedAllowedHostnames=c("");updatingRemoteAccess=c(!1);updatingAllowedHosts=c(!1);updateRemoteAccess(){let t=this.allowRemoteAccess(),e=!t;this.allowRemoteAccess.set(e),e||this.#t.patchApiV1Serversettings({requestBody:{"server-listen-interface":e?"any":"loopback"}}).pipe(this.#n.withRefresh(),R(()=>this.updatingRemoteAccess.set(!1)),x(()=>(this.allowRemoteAccess.set(t),L(null)))).subscribe()}updateAllowedHostnames(){let t=this.loadedAllowedHostnames(),e=this.allowedHostnames();this.updatingAllowedHosts.set(!0),this.#t.patchApiV1Serversettings({requestBody:{"server-listen-interface":"any","allowed-hostnames":e}}).pipe(this.#n.withRefresh(),R(()=>this.updatingAllowedHosts.set(!1)),x(()=>(this.allowedHostnames.set(t),L(null)))).subscribe()}updatingDisableTrayIconLogin=c(!1);disableTrayIconLogin=c(!1);saveDisableTrayIconLogin(){let t=this.disableTrayIconLogin(),e=!t;this.updatingDisableTrayIconLogin.set(!0),this.disableTrayIconLogin.set(e),this.#t.patchApiV1Serversettings({requestBody:{"disable-tray-icon-login":e?"True":"False"}}).pipe(this.#n.withRefresh(),R(()=>this.updatingDisableTrayIconLogin.set(!1)),x(()=>(this.disableTrayIconLogin.set(t),L(null)))).subscribe()}showPassphraseForm=c(!1);isUpdating=c(!1);passphrase=c("");repeatPassphrase=c("");passwordUpdated=c(!1);updatePassphrase(){this.passphrase()===this.repeatPassphrase()&&(this.isUpdating.set(!0),this.#t.patchApiV1Serversettings({requestBody:{"server-passphrase":this.passphrase()}}).pipe(this.#n.withRefresh(),R(()=>this.isUpdating.set(!1))).subscribe({next:()=>{this.showPassphraseForm.set(!1),this.passwordUpdated.set(!0),setTimeout(()=>{this.passwordUpdated.set(!1)},3e3)}}))}openPassphraseForm(){this.showPassphraseForm.set(!0)}cancelPasswordChange(){this.showPassphraseForm.set(!1)}get pauseSettings(){return this.settingsForm.controls.pauseSettings}languageOptions=c(ce);usageStatisticsOptions=c(Mt);timeTypeOptions=c(Nt);timeTypeSignal=oe(this.pauseSettings.controls.timeType.valueChanges);timeRange=b(()=>this.timeTypeSignal()==="h"?[0,24]:[0,60]);updateLocale(t){let n=t[0]?.value??"";!n||n===""||n===this.previousLang||(this.#o.setItem("locale",n),window.location.reload())}submit(){let t=this.pauseSettings.value,e=`${t.time}${t.timeType}`;this.#t.patchApiV1Serversettings({requestBody:{"usage-reporter-level":this.settingsForm.controls.usageStatistics.value,"startup-delay":e==="0s"?"":e}}).pipe(this.#n.withRefresh()).subscribe()}serverSettingsEffect=w(()=>{let t=this.#n.serverSettings();if(t===void 0)return;let e=t["startup-delay"],n=e.slice(-1),r=e.slice(0,-1),d=["s","m","h"];this.disableTrayIconLogin.set(t["disable-tray-icon-login"]!=="False"),this.updateChannel.set(t["update-channel"]),this.allowRemoteAccess.set(t["server-listen-interface"]==="any"),this.allowedHostnames.set(t["allowed-hostnames"]),this.loadedAllowedHostnames.set(t["allowed-hostnames"]),console.log(t["usage-reporter-level"]),queueMicrotask(()=>{this.settingsForm.patchValue({pauseSettings:{time:parseInt(r==""?"0":r),timeType:d.includes(n)?n:"s"},usageStatistics:t["usage-reporter-level"]??""})})});languageDisplay(){let t=this;return()=>{let e=t.langCtrl();return e?ce.find(n=>n.value===e)?.label??null:null}}typeDisplay(){let t=this;return()=>{let e=t.settingsForm.value.pauseSettings?.timeType;return e==null?null:Nt.find(n=>n.value===e)?.label??null}}usageDisplay(){let t=this;return()=>{let e=t.settingsForm.value.usageStatistics;return e==null?null:Mt.find(n=>n.value===e)?.label??null}}setDarkMode(){this.#e.setDarkMode()}setLightMode(){this.#e.setLightMode()}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=$({type:s,selectors:[["app-settings"]],decls:134,vars:39,consts:()=>{let t;t=$localize`Settings`;let e;e=$localize`Configure your backup settings.`;let n;n=$localize` Save changes `;let r;r=$localize`Remote access control`;let d;d=$localize`Color theme`;let N;N=$localize`Customize your application theme`;let g;g=$localize`Passwords`;let M;M=$localize`Change server passphrase`;let pe;pe=$localize`Language`;let Se;Se=$localize`Select a language for the platform`;let ge;ge=$localize`Allow remote access (requires restart)`;let Te;Te=$localize` By allowing remote access, the server listens to requests from any machine on your network. If you enable this option, make sure you are always using the computer on a secure firewall protected network. `;let ue;ue=$localize`Allow remote access`;let me;me=$localize`Prevent tray icon automatic log-in`;let Ce;Ce=$localize` By default, the tray icon will open the user interface with a token that unlocks the user interface. This ensures that you can access the user interface from the tray icon, while requiring others to enter a password. If you prefer having to type in the password, even when accessing the user interface from the tray icon, enable this option. `;let Ee;Ee=$localize`Prevent tray icon automatic log-in`;let fe;fe=$localize`Update channel`;let Ne;Ne=$localize` Default (${"\uFFFD0\uFFFD"}:INTERPOLATION:) `;let Me;Me=$localize`Same as the base install version: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let he;he=$localize`Stable`;let Pe;Pe=$localize`Official releases`;let Oe;Oe=$localize`Beta`;let Re;Re=$localize` Try out the new features that we are working on. Currently the most stable version available. Test Restore data before using this in production environments. `;let Ie;Ie=$localize` Experimental `;let ye;ye=$localize`Specific builds for developers only. Not for use with important data.`;let Ge;Ge=$localize`Canary`;let Ae;Ae=$localize`Individual builds for developers only. Not for use with important data.`;let ve;ve=$localize`Pause after startup or hibernation`;let $e;$e=$localize` Duplicati will run when started, but will remain in paused state for the duration. Duplicati will occupy minimal system resources and no backups will be run. `;let be;be=$localize`Usage statistics`;let V;V=$localize` Usage reports help us improve the user experience and evaluate impact of new features. We use them to generate ${"\uFFFD#121\uFFFD"}:START_LINK:public usage statistics.${"\uFFFD/#121\uFFFD"}:CLOSE_LINK:${"[\uFFFD#122\uFFFD\uFFFD/#122\uFFFD|\uFFFD#123\uFFFD\uFFFD/#123\uFFFD]"}:LINE_BREAK:${"[\uFFFD#122\uFFFD\uFFFD/#122\uFFFD|\uFFFD#123\uFFFD\uFFFD/#123\uFFFD]"}:LINE_BREAK: All usage reports are sent anonymously and do not contain any personal information. They contain information about hardware and operating system, the type of backend, backup duration, overall size of source data and similar data. They do not contain paths, filenames, usernames, passwords or similar sensitive information. `,V=Je(V);let we;we=$localize`Advanced options`;let ke;ke=$localize`Enter new password`;let Fe;Fe=$localize`Repeat password`;let Le;Le=$localize`Password have to be filled and have to match`;let xe;xe=$localize`Passphrase`;let De;De=$localize`Repeat passphrase`;let Xe;Xe=$localize`Cancel`;let Ve;Ve=$localize` Update passphrase `;let ze;ze=$localize` Update passphrase `;let Ue;Ue=$localize`Change password`;let Be;Be=$localize`Allowed hostnames`;let He;He=$localize` To prevent various DNS based attacks, Duplicati limits the allowed hostnames to the ones listed here. Direct IP access and localhost is always allowed. Multiple hostnames can be supplied with a semicolon separator. If any of the allowed hostnames is an asterisk (*), all hostnames are allowed and this feature is disabled. If the field is empty, only IP address and localhost access is allowed. `;let We;return We=$localize` Update allowed hostnames `,[t,e,n,r,d,N,g,M,pe,Se,ge,Te,ue,me,Ce,Ee,fe,Ne,Me,he,Pe,Oe,Re,Ie,ye,Ge,Ae,ve,$e,be,V,we,xe,De,Xe,Ve,ze,Ue,Be,He,We,[1,"content"],[1,"title"],["type","submit","spk-button","",1,"raised","primary",3,"click","disabled"],[1,"left"],[1,"right"],[1,"themes"],["src","assets/images/light-theme.png","alt","light theme",3,"click"],["src","assets/images/dark-theme.png","alt","dark theme",3,"click"],[1,"right","passphrase-form"],[1,"actions"],["value","value","label","label",3,"selectedOptionsChange","options","isClearable","inlineSearch"],["type","text",3,"ngModel","ngModelOptions"],[1,"right","remote-access-form"],[1,"primary","raised",3,"click"],[1,"indeterminate","primary"],[1,"right","radios"],[1,"radio-option",3,"click"],[1,"primary","raised"],[1,"content",3,"submit","formGroup"],["formGroupName","pauseSettings",1,"field-row"],[1,"raised","primary",3,"unit"],["type","range","formControlName","time",3,"min","max"],["label","label","value","value",3,"options","isClearable"],["type","text","formControlName","timeType"],["href","#"],["label","label","value","value",3,"options"],["type","text","formControlName","usageStatistics"],[1,"advanced-settings"],["for","password"],["type","password","name","password","autocomplete","disabled","placeholder",ke,"tabindex","1",3,"ngModelChange","ngModel"],["for","repeatPassword"],["type","password","name","repeatPassword","autocomplete","disabled","placeholder",Fe,"tabindex","2",3,"ngModelChange","disabled","ngModel"],["suffix","",1,"spk-success"],["suffix",""],["spk-button","",3,"click"],["spk-button","",1,"raised","primary",3,"loader"],["message",Le,1,"primary"],["spk-button","",1,"raised","primary",3,"click"],["spk-button","",1,"raised","primary",3,"click","disabled"],[1,"spk-success"],["for","allowedHostnames"],["type","text","id","allowedHostnames",3,"ngModelChange","ngModel"],["type","primary"]]},template:function(e,n){if(e&1&&(P(0,"app-status-bar"),i(1,"div",41)(2,"header")(3,"div",42)(4,"h2"),a(5,0),o(),i(6,"p"),a(7,1),o()(),i(8,"button",43),S("click",function(){return n.submit()}),a(9,2),o()(),i(10,"section")(11,"div",44)(12,"h3"),a(13,3),o(),i(14,"p"),I(15),o()(),i(16,"div",45),P(17,"app-remote-control"),o()(),i(18,"section")(19,"div",44)(20,"h3"),a(21,4),o(),i(22,"p"),a(23,5),o()(),i(24,"div",45)(25,"div",46)(26,"img",47),S("click",function(){return n.setLightMode()}),o(),i(27,"img",48),S("click",function(){return n.setDarkMode()}),o()()()(),i(28,"section")(29,"div",44)(30,"h3"),a(31,6),o(),i(32,"p"),a(33,7),o()(),i(34,"div",49),E(35,zt,15,7)(36,Bt,4,1,"div",50),o()(),i(37,"section")(38,"div",44)(39,"h3"),a(40,8),o(),i(41,"p"),a(42,9),o()(),i(43,"div",45)(44,"spk-select",51),S("selectedOptionsChange",function(d){return n.updateLocale(d)}),P(45,"input",52),o()()(),i(46,"section")(47,"div",44)(48,"h3"),a(49,10),o(),i(50,"p"),a(51,11),o()(),i(52,"div",53)(53,"spk-toggle",54),S("click",function(){return n.updateRemoteAccess()}),i(54,"label"),a(55,12),o()(),E(56,Ht,8,3),o()(),i(57,"section")(58,"div",44)(59,"h3"),a(60,13),o(),i(61,"p"),a(62,14),o()(),i(63,"div",45)(64,"spk-toggle",54),S("click",function(){return n.saveDisableTrayIconLogin()}),i(65,"label"),a(66,15),o()()()(),i(67,"section")(68,"div",44)(69,"h3"),a(70,16),o(),i(71,"p"),E(72,Wt,1,1),o(),E(73,qt,1,0,"spk-progress-bar",55),o(),i(74,"div",56)(75,"div",57),S("click",function(){return n.setNewChannel("")}),i(76,"spk-radio",58),a(77,17),o(),i(78,"p"),a(79,18),o()(),i(80,"div",57),S("click",function(){return n.setNewChannel("stable")}),i(81,"spk-radio",58),a(82,19),o(),i(83,"p"),a(84,20),o()(),i(85,"div",57),S("click",function(){return n.setNewChannel("beta")}),i(86,"spk-radio",58),a(87,21),o(),i(88,"p"),a(89,22),o()(),i(90,"div",57),S("click",function(){return n.setNewChannel("experimental")}),i(91,"spk-radio",58),a(92,23),o(),i(93,"p"),a(94,24),o()(),i(95,"div",57),S("click",function(){return n.setNewChannel("canary")}),i(96,"spk-radio",58),a(97,25),o(),i(98,"p"),a(99,26),o()()()()(),P(100,"spk-divider"),i(101,"form",59),S("submit",function(){return n.submit()}),i(102,"section")(103,"div",44)(104,"h3"),a(105,27),o(),i(106,"p"),a(107,28),o()(),i(108,"div",45)(109,"div",60)(110,"spk-range-slider",61),P(111,"input",62),o(),i(112,"spk-select",63),P(113,"input",64),E(114,jt,1,1,"ng-template"),o()()()(),i(115,"section")(116,"div",44)(117,"h3"),a(118,29),o(),i(119,"p"),U(120,30),P(121,"a",65)(122,"br")(123,"br"),B(),o()(),i(124,"div",45)(125,"spk-select",66),P(126,"input",67),E(127,Kt,1,1,"ng-template"),o()()()(),i(128,"div",41)(129,"section")(130,"div",68)(131,"h3"),a(132,31),o(),P(133,"app-advanced-options-settings"),o()()()),e&2){let r,d,N,g;l(8),h("disabled",n.settingsForm.untouched),l(7),H(n.remoteControlStatus()),l(11),f("active",!n.isDarkMode()),l(),f("active",n.isDarkMode()),l(8),C(n.showPassphraseForm()?35:36),l(9),h("options",n.languageOptions())("isClearable",!1)("inlineSearch",!0),l(),h("ngModel",n.langCtrl())("ngModelOptions",q(38,Lt)),l(8),f("active",n.allowRemoteAccess()),l(3),C(n.allowRemoteAccess()?56:-1),l(8),f("active",n.disableTrayIconLogin()),l(8),C(n.updateChannel()!==""&&((r=n.sysinfo())!=null&&r.ServerVersion)?72:-1),l(),C(n.updatingChannel()?73:-1),l(3),f("active",n.updateChannel()===""),l(),ae((d=n.sysinfo())==null?null:d.DefaultUpdateChannel),le(77),l(2),ae((N=n.sysinfo())==null?null:N.ServerVersionType),le(79),l(2),f("active",n.updateChannel()==="stable"),l(5),f("active",n.updateChannel()==="beta"),l(5),f("active",n.updateChannel()==="experimental"),l(5),f("active",n.updateChannel()==="canary"),l(5),h("formGroup",n.settingsForm),l(9),h("unit",(g=n.timeTypeSignal())!==null&&g!==void 0?g:""),l(),h("min",n.timeRange()[0])("max",n.timeRange()[1]),l(),h("options",n.timeTypeOptions())("isClearable",!1),l(13),h("options",n.usageStatisticsOptions())}},dependencies:[ne,pt,Y,St,ee,dt,te,ie,gt,ut,Tt,Et,re,D,Q,rt,at,st,_t,ct,Z,j,ot,K,lt],styles:["[_nghost-%COMP%]{display:block}.content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:0 2rem 2rem}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:2rem 0;position:sticky;top:0;background:var(--base-level-10);z-index:1000;border-bottom:1px solid var(--base-level-40)}header[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}section[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem;padding:2rem 0;border-top:1px solid var(--base-level-40)}section[_ngcontent-%COMP%]:first-of-type{border-top:0}section[_ngcontent-%COMP%] .left[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem;align-items:flex-start}section[_ngcontent-%COMP%] .left[_ngcontent-%COMP%] spk-button-group[_ngcontent-%COMP%]{margin-top:.25rem}section[_ngcontent-%COMP%] .left[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-wrap:balance;width:50%}.passphrase-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:flex-start;gap:1rem}.passphrase-form[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.remote-access-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.themes[_ngcontent-%COMP%]{display:flex;gap:.5rem}.themes[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{max-width:240px;border-radius:var(--shape-3);cursor:pointer}.themes[_ngcontent-%COMP%] img.active[_ngcontent-%COMP%]{border:2px solid var(--primary-500)}.radios[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.radio-option[_ngcontent-%COMP%]{cursor:pointer}.radio-option[_ngcontent-%COMP%] spk-radio[_ngcontent-%COMP%]{color:var(--base-level-60);margin-bottom:.25rem}.radio-option[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-wrap:balance;color:var(--base-level-60R)}.field-col[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.field-row[_ngcontent-%COMP%]{display:flex;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] spk-form-field[_ngcontent-%COMP%], .field-row[_ngcontent-%COMP%] spk-select[_ngcontent-%COMP%]{flex:1 0}.advanced-settings[_ngcontent-%COMP%]{grid-column:1/-1;display:grid;grid-template-columns:auto 1fr;gap:1rem}"],changeDetection:0})};export{de as default};
1
+ import{o as _e}from"./chunk-5COOM7FC.js";import"./chunk-XC6KYSRC.js";import"./chunk-DNHLTHLR.js";import{a as oe}from"./chunk-NV2YMSSM.js";import"./chunk-CR2UB7UZ.js";import"./chunk-3YOT5OAB.js";import{a as ce}from"./chunk-W5YK2JJZ.js";import{a as J}from"./chunk-CMXSHXAU.js";import{a as Ct}from"./chunk-T2KQRNAJ.js";import"./chunk-OS4AAJLB.js";import{a as it}from"./chunk-3XY4ZNIY.js";import{a as Et}from"./chunk-76MUKWQP.js";import"./chunk-F5S33WHR.js";import"./chunk-HGERKLOF.js";import"./chunk-UT45C7WK.js";import"./chunk-QX5XWUM2.js";import{b as Y,d as ee,e as dt,g as te,h as pt,k as St,m as gt,n as Tt,p as ut,q as mt,r as ne,s as ie}from"./chunk-LHSJLKCF.js";import"./chunk-FHW4WHNO.js";import"./chunk-WBNOGAKJ.js";import"./chunk-G3YJXHRY.js";import{a as j,b as K,g as Q,k as ot,l as Z,o as st,p as rt,q as at,r as lt,x as _t,y as ct}from"./chunk-PUSUA4U7.js";import{b as v}from"./chunk-L3T52MCL.js";import"./chunk-4XPN5ZGE.js";import"./chunk-3GK4TNUH.js";import"./chunk-CHZ7TMI7.js";import{Ab as i,Bb as o,Cb as P,D as R,Gb as O,Lc as b,Mb as U,Mc as w,Nb as B,Oa as je,Ob as a,Pb as ae,Qa as l,Qb as le,R as z,Rb as Je,Sb as S,Tb as p,Wb as Ye,X as T,Xa as Ke,c as qe,ca as u,cc as et,da as m,db as $,dc as tt,fc as I,gc as H,hc as W,ib as E,kc as y,l as L,lc as G,mc as A,ob as Qe,pb as Ze,qc as nt,rb as h,rc as q,sa as c,tb as f,wb as C,y as x}from"./chunk-PTC4N7TU.js";import"./chunk-7CGTOI24.js";var k=class s{#e=T(v);#i=oe(this.#e.getApiV1Serversettings());#t=c(void 0);serverSettings=b(()=>this.#t()||this.#i());refreshServerSettings(){this.#e.getApiV1Serversettings().subscribe({next:t=>{this.#t.set(t)}})}withRefresh(){return qe(R(()=>this.refreshServerSettings()))}static \u0275fac=function(e){return new(e||s)};static \u0275prov=z({token:s,factory:s.\u0275fac,providedIn:"root"})};var ht=["formRef"],Pt=()=>[import("./chunk-Q3FF4WG3.js").then(s=>s.OptionsListComponent)],Ot=()=>["--no-encryption","--exclude-files-attributes","--skip-files-larger-than","dblock-size","no-encryption"];function Rt(s,t){s&1&&(i(0,"spk-alert",3),a(1,1),o())}function It(s,t){if(s&1){let e=O();i(0,"app-options-list",5),A("optionsChange",function(r){u(e);let d=p();return G(d.settings,r)||(d.settings=r),m(r)}),o()}if(s&2){let e=p();y("options",e.settings),h("hasFreeTextSettings",!0)("hiddenOptions",q(3,Ot))}}var yt=["Bytes","KB","MB","GB","TB","PB"],D=class s{#e=T(_e);#i=T(k);#t=T(v);formRef=Ke.required("formRef");optionsForm=this.#e.optionsForm;settings=this.#e.settings;isSubmitting=c(!1);isLoadingOptions=c(!0);saved=c(!1);sizeOptions=c(yt);lastRecievedServerSettings=c({});serverSettingsEffect=w(()=>{let t=this.#i.serverSettings();if(t===void 0)return;this.lastRecievedServerSettings.set(t),this.isLoadingOptions.set(!0);let e=Object.entries(t);e.forEach(([n,r],d)=>{if(n.startsWith("--")){let N=n.replace("--","");this.settings.update(g=>(g.some(M=>M.Name===N)||g.push({Name:N,Value:r}),g))}d===e.length-1&&this.isLoadingOptions.set(!1)})});submit(){this.isSubmitting.set(!0);let t=this.settings(),e=this.lastRecievedServerSettings(),n=t.map(g=>g.Name),d=Object.keys(e).filter(g=>!n.includes(g.replace("--",""))),N=t.reduce((g,M)=>(g[`--${M.Name}`]=M.Value,g),{});d.forEach(g=>{N[g]=null}),this.#t.patchApiV1Serversettings({requestBody:N}).pipe(R(()=>this.isSubmitting.set(!1))).subscribe({next:()=>{this.#i.refreshServerSettings(),this.saved.set(!0),setTimeout(()=>{this.saved.set(!1)},3e3)}})}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=$({type:s,selectors:[["app-advanced-options-settings"]],viewQuery:function(e,n){e&1&&et(n.formRef,ht,5),e&2&&tt()},features:[nt([_e])],decls:8,vars:4,consts:()=>{let t;t=$localize`${"\uFFFD#4\uFFFD"}:START_TAG_SPK_ICON:floppy-disk${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_SPK_ICON: Save settings `;let e;return e=$localize`Settings saved`,[t,e,[1,"actions"],[1,"success"],["spk-button","","type","button",1,"raised","primary",3,"click"],[3,"optionsChange","options","hasFreeTextSettings","hiddenOptions"]]},template:function(e,n){e&1&&(i(0,"div",2),E(1,Rt,2,0,"spk-alert",3),i(2,"button",4),S("click",function(){return n.submit()}),U(3,0),P(4,"spk-icon"),B(),o()(),E(5,It,1,4),Qe(6,5,Pt)),e&2&&(l(),C(n.saved()?1:-1),l(),f("loader",n.isSubmitting()),l(4),Ze(!n.isLoadingOptions()))},dependencies:[ie,Q,j,K],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:40.625rem;justify-self:flex-end}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;justify-content:flex-end;margin-bottom:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-column[_ngcontent-%COMP%]{display:flex;flex-direction:column}.form-column[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem}.form-column[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:1rem}.field-row[_ngcontent-%COMP%]{display:grid;align-items:flex-end;grid-template-columns:1fr 2.5rem;gap:.5rem}.form-row[_ngcontent-%COMP%]{display:grid;grid-template-columns:3fr 1fr;gap:.5rem;align-items:flex-end}.form-wrap[_ngcontent-%COMP%]{display:grid;grid-template-columns:2fr 2.5rem;gap:.5rem;align-items:flex-end}.remote-volume-wrap[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.remote-volume-wrap[_ngcontent-%COMP%] p.warning[_ngcontent-%COMP%]{color:#7d7d00}.row-inputs[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.5rem}.row-inputs[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{flex:1 0}.advanced-option[_ngcontent-%COMP%]{display:grid;gap:.5rem;grid-template-columns:1fr 1fr 40px;align-items:flex-end}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}"],changeDetection:0})};var F=class s{#e=T(v);#i=T(J);repeatRegisterTimer=null;state=c("unknown");claimUrl=c(null);registerUrl=c("");status=b(()=>{let t=this.state();return t==="enabled"?"Remote control is enabled but not connected":t==="connected"?"Remote control is connected":t==="registering"?"Registering machine...":t==="registeringfaulted"?"Registration failed":t==="registered"?"Registered, waiting for accept":t==="disabled"?"Remote control is configured but not enabled":t==="unknown"?"...loading...":"Remote control is not set up"});sysInfoEffect=w(()=>{let t=this.#i.systemInfo();t&&this.registerUrl.set(t.RemoteControlRegistrationUrl??"")});#t(t){t.RegistrationUrl&&this.claimUrl.set(t.RegistrationUrl),t.IsConnected?this.state.set("connected"):t.IsEnabled?this.state.set("enabled"):t.CanEnable?this.state.set("disabled"):t.IsRegisteringFaulted?this.state.set("registeringfaulted"):t.IsRegistering?t.RegistrationUrl!=null&&t.RegistrationUrl.trim().length>0?this.state.set("registered"):this.state.set("registering"):this.state.set("inactive");let e=this.state();this.repeatRegisterTimer!==null&&(clearTimeout(this.repeatRegisterTimer),this.repeatRegisterTimer=null),e==="registering"&&(this.repeatRegisterTimer=setTimeout(()=>{this.#e.postApiV1RemotecontrolRegister({requestBody:{RegistrationUrl:""}}).subscribe({next:n=>this.#t(n),error:n=>this.#n(n)})},5e3)),(e==="enabled"||e==="registered")&&(this.repeatRegisterTimer=setTimeout(()=>{this.#e.getApiV1RemotecontrolStatus().subscribe({next:n=>this.#t(n),error:n=>this.#n(n)})},5e3)),t.IsRegistering&&t.CanEnable&&this.#e.deleteApiV1RemotecontrolRegister().subscribe({next:n=>this.#t(n)})}#n(t){this.#e.getApiV1RemotecontrolStatus().subscribe({next:e=>this.#t(e)})}refreshRemoteControlStatus(){this.#e.getApiV1RemotecontrolStatus().subscribe({next:t=>this.#t(t),error:t=>this.#n(t)})}beginRemoteRegistration(){this.state.set("registering"),this.#e.postApiV1RemotecontrolRegister({requestBody:{RegistrationUrl:this.registerUrl()}}).subscribe({next:t=>this.#t(t),error:t=>this.#n(t)})}cancelRemoteRegistration(){this.#e.deleteApiV1RemotecontrolRegister().subscribe({next:t=>this.#t(t),error:t=>this.#n(t)})}enableRemoteControl(){this.#e.postApiV1RemotecontrolEnable().subscribe({next:t=>this.#t(t),error:t=>this.#n(t)})}disableRemoteControl(){this.#e.postApiV1RemotecontrolDisable().subscribe({next:t=>this.#t(t),error:t=>this.#n(t)})}deleteRemoteControl(){let t=this;confirm("Are you sure you want to delete the remote control registration?")&&t.#e.deleteApiV1RemotecontrolRegistration().subscribe({next:e=>t.#t(e),error:e=>t.#n(e)})}static \u0275fac=function(e){return new(e||s)};static \u0275prov=z({token:s,factory:s.\u0275fac,providedIn:"root"})};function At(s,t){if(s&1){let e=O();i(0,"spk-form-field",10)(1,"input",11),A("ngModelChange",function(r){u(e);let d=p(2);return G(d.registerUrl,r)||(d.registerUrl=r),m(r)}),o()(),i(2,"button",12),S("click",function(){u(e);let r=p(2);return m(r.register())}),a(3,0),o()}if(s&2){let e=p(2);l(),y("ngModel",e.registerUrl)}}function vt(s,t){if(s&1&&(i(0,"div",8)(1,"label"),a(2,1),o(),i(3,"a",13),I(4),o()()),s&2){let e=p(2);l(3),Ye("href",e.claimUrl(),je),l(),H(e.claimUrl())}}function $t(s,t){s&1&&(i(0,"div",8)(1,"label"),a(2,2),o()())}function bt(s,t){if(s&1){let e=O();i(0,"button",12),S("click",function(){u(e);let r=p(2);return m(r.cancel())}),a(1,3),o()}}function wt(s,t){if(s&1){let e=O();i(0,"button",12),S("click",function(){u(e);let r=p(2);return m(r.disable())}),a(1,4),o()}}function kt(s,t){if(s&1){let e=O();i(0,"button",12),S("click",function(){u(e);let r=p(2);return m(r.enable())}),a(1,5),o(),i(2,"button",14),S("click",function(){u(e);let r=p(2);return m(r.delete())}),a(3,6),o()}}function Ft(s,t){if(s&1&&(i(0,"div",7),E(1,At,4,1)(2,vt,5,2,"div",8)(3,$t,3,0,"div",8)(4,bt,2,0,"button",9)(5,wt,2,0,"button",9)(6,kt,4,0),o()),s&2){let e=p();l(),C(e.state()==="inactive"?1:-1),l(),C(e.state()==="registered"?2:-1),l(),C(e.state()==="registering"?3:-1),l(),C(e.state()==="registering"||e.state()==="registeringfaulted"||e.state()==="registered"?4:-1),l(),C(e.state()==="connected"||e.state()==="enabled"?5:-1),l(),C(e.state()==="disabled"?6:-1)}}var re=class s{#e=T(F);state=this.#e.state;claimUrl=this.#e.claimUrl;registerUrl=this.#e.registerUrl;ngOnInit(){this.#e.refreshRemoteControlStatus()}cancel(){this.#e.cancelRemoteRegistration()}register(){this.#e.beginRemoteRegistration()}disable(){this.#e.disableRemoteControl()}enable(){this.#e.enableRemoteControl()}delete(){this.#e.deleteRemoteControl()}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=$({type:s,selectors:[["app-remote-control"]],decls:1,vars:1,consts:()=>{let t;t=$localize`Register for remote control`;let e;e=$localize`Machine is now registered, open this link to add it to your account:`;let n;n=$localize`Registering, please wait...`;let r;r=$localize`Cancel registration`;let d;d=$localize`Disable remote control`;let N;N=$localize`Enable remote control`;let g;return g=$localize`Delete remote control setup`,[t,e,n,r,d,N,g,[1,"field-row"],[1,"field-col"],["type","button","spk-button","",1,"raised"],["label","Registration URL","for","remoteControlRegisterUrl"],["type","text","spk-input","","id","remoteControlRegisterUrl","name","remoteControlRegisterUrl",3,"ngModelChange","ngModel"],["type","button","spk-button","",1,"raised",3,"click"],["target","_blank",3,"href"],["type","button","spk-button","",1,"raised","error",3,"click"]]},template:function(e,n){e&1&&E(0,Ft,7,6,"div",7),e&2&&C(n.state()!=="unknown"?0:-1)},dependencies:[ne,Y,ee,te,Z],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] button[_ngcontent-%COMP%]{white-space:nowrap}.field-row[_ngcontent-%COMP%]{display:flex;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] spk-form-field[_ngcontent-%COMP%], .field-row[_ngcontent-%COMP%] spk-select[_ngcontent-%COMP%]{flex:1 0}"],changeDetection:0})};var Lt=()=>({standalone:!0});function xt(s,t){s&1&&(i(0,"spk-icon",73),I(1,"check"),o())}function Dt(s,t){s&1&&(i(0,"spk-icon",74),I(1,"prohibit"),o())}function Xt(s,t){if(s&1){let e=O();i(0,"button",78),S("click",function(){u(e);let r=p(2);return m(r.updatePassphrase())}),a(1,35),o()}if(s&2){let e=p(2);f("loader",e.isUpdating())}}function Vt(s,t){if(s&1){let e=O();i(0,"spk-tooltip",77)(1,"button",79),S("click",function(){u(e);let r=p(2);return m(r.updatePassphrase())}),a(2,36),o()()}if(s&2){let e=p(2);l(),f("loader",e.isUpdating()),h("disabled",!0)}}function zt(s,t){if(s&1){let e=O();i(0,"spk-form-field")(1,"label",69),a(2,32),o(),i(3,"input",70),A("ngModelChange",function(r){u(e);let d=p();return G(d.passphrase,r)||(d.passphrase=r),m(r)}),o()(),i(4,"spk-form-field")(5,"label",71),a(6,33),o(),i(7,"input",72),A("ngModelChange",function(r){u(e);let d=p();return G(d.repeatPassphrase,r)||(d.repeatPassphrase=r),m(r)}),o(),E(8,xt,2,0,"spk-icon",73)(9,Dt,2,0,"spk-icon",74),o(),i(10,"div",50)(11,"button",75),S("click",function(){u(e);let r=p();return m(r.cancelPasswordChange())}),a(12,34),o(),E(13,Xt,2,2,"button",76)(14,Vt,3,3,"spk-tooltip",77),o()}if(s&2){let e=p();l(3),y("ngModel",e.passphrase),l(4),h("disabled",e.passphrase().length===0),y("ngModel",e.repeatPassphrase),l(),C(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?8:9),l(3),f("loader",e.isUpdating()),l(2),C(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?13:14)}}function Ut(s,t){s&1&&(i(0,"spk-icon",80),I(1,"check"),o())}function Bt(s,t){if(s&1){let e=O();i(0,"div",50)(1,"button",75),S("click",function(){u(e);let r=p();return m(r.openPassphraseForm())}),a(2,37),o(),E(3,Ut,2,0,"spk-icon",80),o()}if(s&2){let e=p();l(3),C(e.passwordUpdated()?3:-1)}}function Ht(s,t){if(s&1){let e=O();i(0,"spk-form-field")(1,"label",81),a(2,38),o(),i(3,"textarea",82),A("ngModelChange",function(r){u(e);let d=p();return G(d.allowedHostnames,r)||(d.allowedHostnames=r),m(r)}),o()(),i(4,"spk-alert",83),a(5,39),o(),i(6,"button",78),S("click",function(){u(e);let r=p();return m(r.updateAllowedHostnames())}),a(7,40),o()}if(s&2){let e=p();l(3),y("ngModel",e.allowedHostnames),l(3),f("loader",e.updatingAllowedHosts())}}function Wt(s,t){if(s&1&&I(0),s&2){let e,n=p();W(" ",(e=n.sysinfo())==null?null:e.ServerVersion," ")}}function qt(s,t){s&1&&P(0,"spk-progress-bar",55)}function jt(s,t){if(s&1&&I(0),s&2){let e=t.$implicit;W(" ",e.label," ")}}function Kt(s,t){if(s&1&&I(0),s&2){let e=t.$implicit;W(" ",e.label," ")}}var X=new mt,Nt=[{value:"s",label:$localize`Seconds`},{value:"m",label:$localize`Minutes`},{value:"h",label:$localize`Hours`}],Mt=[{value:"",label:$localize`System default (information)`},{value:"information",label:$localize`Usage statistics, warnings, errors, and crashes`},{value:"warning",label:$localize`Warnings, errors and crashes`},{value:"error",label:$localize`Errors and crashes`},{value:"crash",label:$localize`Crashes only`},{value:"none",label:$localize`None / disabled`}],de=class s{#e=T(Ct);#i=T(J);#t=T(v);#n=T(k);#r=T(F);#o=T(it);#s=this.#o.getItem("locale")??"en-US";sysinfo=this.#i.systemInfo;isDarkMode=this.#e.isDarkMode;editAs=c("list");previousLang=this.#s;langCtrl=c(this.#s);remoteControlStatus=this.#r.status;settingsForm=X.group({pauseSettings:X.group({time:X.control(0),timeType:X.control("s")}),usageStatistics:X.control("")});updatingChannel=c(!1);updateChannel=c("");setNewChannel(t){let e=this.updateChannel();this.updateChannel.set(t),this.#t.patchApiV1Serversettings({requestBody:{"update-channel":t}}).pipe(this.#n.withRefresh(),R(()=>this.updatingChannel.set(!1)),x(()=>(this.updateChannel.set(e),L(null)))).subscribe()}allowRemoteAccess=c(!1);allowedHostnames=c("");loadedAllowedHostnames=c("");updatingRemoteAccess=c(!1);updatingAllowedHosts=c(!1);updateRemoteAccess(){let t=this.allowRemoteAccess(),e=!t;this.allowRemoteAccess.set(e),e||this.#t.patchApiV1Serversettings({requestBody:{"server-listen-interface":e?"any":"loopback"}}).pipe(this.#n.withRefresh(),R(()=>this.updatingRemoteAccess.set(!1)),x(()=>(this.allowRemoteAccess.set(t),L(null)))).subscribe()}updateAllowedHostnames(){let t=this.loadedAllowedHostnames(),e=this.allowedHostnames();this.updatingAllowedHosts.set(!0),this.#t.patchApiV1Serversettings({requestBody:{"server-listen-interface":"any","allowed-hostnames":e}}).pipe(this.#n.withRefresh(),R(()=>this.updatingAllowedHosts.set(!1)),x(()=>(this.allowedHostnames.set(t),L(null)))).subscribe()}updatingDisableTrayIconLogin=c(!1);disableTrayIconLogin=c(!1);saveDisableTrayIconLogin(){let t=this.disableTrayIconLogin(),e=!t;this.updatingDisableTrayIconLogin.set(!0),this.disableTrayIconLogin.set(e),this.#t.patchApiV1Serversettings({requestBody:{"disable-tray-icon-login":e?"True":"False"}}).pipe(this.#n.withRefresh(),R(()=>this.updatingDisableTrayIconLogin.set(!1)),x(()=>(this.disableTrayIconLogin.set(t),L(null)))).subscribe()}showPassphraseForm=c(!1);isUpdating=c(!1);passphrase=c("");repeatPassphrase=c("");passwordUpdated=c(!1);updatePassphrase(){this.passphrase()===this.repeatPassphrase()&&(this.isUpdating.set(!0),this.#t.patchApiV1Serversettings({requestBody:{"server-passphrase":this.passphrase()}}).pipe(this.#n.withRefresh(),R(()=>this.isUpdating.set(!1))).subscribe({next:()=>{this.showPassphraseForm.set(!1),this.passwordUpdated.set(!0),setTimeout(()=>{this.passwordUpdated.set(!1)},3e3)}}))}openPassphraseForm(){this.showPassphraseForm.set(!0)}cancelPasswordChange(){this.showPassphraseForm.set(!1)}get pauseSettings(){return this.settingsForm.controls.pauseSettings}languageOptions=c(ce);usageStatisticsOptions=c(Mt);timeTypeOptions=c(Nt);timeTypeSignal=oe(this.pauseSettings.controls.timeType.valueChanges);timeRange=b(()=>this.timeTypeSignal()==="h"?[0,24]:[0,60]);updateLocale(t){let n=t[0]?.value??"";!n||n===""||n===this.previousLang||(this.#o.setItem("locale",n),window.location.reload())}submit(){let t=this.pauseSettings.value,e=`${t.time}${t.timeType}`;this.#t.patchApiV1Serversettings({requestBody:{"usage-reporter-level":this.settingsForm.controls.usageStatistics.value,"startup-delay":e==="0s"?"":e}}).pipe(this.#n.withRefresh()).subscribe()}serverSettingsEffect=w(()=>{let t=this.#n.serverSettings();if(t===void 0)return;let e=t["startup-delay"],n=e.slice(-1),r=e.slice(0,-1),d=["s","m","h"];this.disableTrayIconLogin.set(t["disable-tray-icon-login"]!=="False"),this.updateChannel.set(t["update-channel"]),this.allowRemoteAccess.set(t["server-listen-interface"]==="any"),this.allowedHostnames.set(t["allowed-hostnames"]),this.loadedAllowedHostnames.set(t["allowed-hostnames"]),console.log(t["usage-reporter-level"]),queueMicrotask(()=>{this.settingsForm.patchValue({pauseSettings:{time:parseInt(r==""?"0":r),timeType:d.includes(n)?n:"s"},usageStatistics:t["usage-reporter-level"]??""})})});languageDisplay(){let t=this;return()=>{let e=t.langCtrl();return e?ce.find(n=>n.value===e)?.label??null:null}}typeDisplay(){let t=this;return()=>{let e=t.settingsForm.value.pauseSettings?.timeType;return e==null?null:Nt.find(n=>n.value===e)?.label??null}}usageDisplay(){let t=this;return()=>{let e=t.settingsForm.value.usageStatistics;return e==null?null:Mt.find(n=>n.value===e)?.label??null}}setDarkMode(){this.#e.setDarkMode()}setLightMode(){this.#e.setLightMode()}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=$({type:s,selectors:[["app-settings"]],decls:134,vars:39,consts:()=>{let t;t=$localize`Settings`;let e;e=$localize`Configure your backup settings.`;let n;n=$localize` Save changes `;let r;r=$localize`Remote access control`;let d;d=$localize`Color theme`;let N;N=$localize`Customize your application theme`;let g;g=$localize`Passwords`;let M;M=$localize`Change server passphrase`;let pe;pe=$localize`Language`;let Se;Se=$localize`Select a language for the platform`;let ge;ge=$localize`Allow remote access (requires restart)`;let Te;Te=$localize` By allowing remote access, the server listens to requests from any machine on your network. If you enable this option, make sure you are always using the computer on a secure firewall protected network. `;let ue;ue=$localize`Allow remote access`;let me;me=$localize`Prevent tray icon automatic log-in`;let Ce;Ce=$localize` By default, the tray icon will open the user interface with a token that unlocks the user interface. This ensures that you can access the user interface from the tray icon, while requiring others to enter a password. If you prefer having to type in the password, even when accessing the user interface from the tray icon, enable this option. `;let Ee;Ee=$localize`Prevent tray icon automatic log-in`;let fe;fe=$localize`Update channel`;let Ne;Ne=$localize` Default (${"\uFFFD0\uFFFD"}:INTERPOLATION:) `;let Me;Me=$localize`Same as the base install version: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let he;he=$localize`Stable`;let Pe;Pe=$localize`Official releases`;let Oe;Oe=$localize`Beta`;let Re;Re=$localize` Try out the new features that we are working on. Currently the most stable version available. Test Restore data before using this in production environments. `;let Ie;Ie=$localize` Experimental `;let ye;ye=$localize`Specific builds for developers only. Not for use with important data.`;let Ge;Ge=$localize`Canary`;let Ae;Ae=$localize`Individual builds for developers only. Not for use with important data.`;let ve;ve=$localize`Pause after startup or hibernation`;let $e;$e=$localize` Duplicati will run when started, but will remain in paused state for the duration. Duplicati will occupy minimal system resources and no backups will be run. `;let be;be=$localize`Usage statistics`;let V;V=$localize` Usage reports help us improve the user experience and evaluate impact of new features. We use them to generate ${"\uFFFD#121\uFFFD"}:START_LINK:public usage statistics.${"\uFFFD/#121\uFFFD"}:CLOSE_LINK:${"[\uFFFD#122\uFFFD\uFFFD/#122\uFFFD|\uFFFD#123\uFFFD\uFFFD/#123\uFFFD]"}:LINE_BREAK:${"[\uFFFD#122\uFFFD\uFFFD/#122\uFFFD|\uFFFD#123\uFFFD\uFFFD/#123\uFFFD]"}:LINE_BREAK: All usage reports are sent anonymously and do not contain any personal information. They contain information about hardware and operating system, the type of backend, backup duration, overall size of source data and similar data. They do not contain paths, filenames, usernames, passwords or similar sensitive information. `,V=Je(V);let we;we=$localize`Advanced options`;let ke;ke=$localize`Enter new password`;let Fe;Fe=$localize`Repeat password`;let Le;Le=$localize`Password have to be filled and have to match`;let xe;xe=$localize`Passphrase`;let De;De=$localize`Repeat passphrase`;let Xe;Xe=$localize`Cancel`;let Ve;Ve=$localize` Update passphrase `;let ze;ze=$localize` Update passphrase `;let Ue;Ue=$localize`Change password`;let Be;Be=$localize`Allowed hostnames`;let He;He=$localize` To prevent various DNS based attacks, Duplicati limits the allowed hostnames to the ones listed here. Direct IP access and localhost is always allowed. Multiple hostnames can be supplied with a semicolon separator. If any of the allowed hostnames is an asterisk (*), all hostnames are allowed and this feature is disabled. If the field is empty, only IP address and localhost access is allowed. `;let We;return We=$localize` Update allowed hostnames `,[t,e,n,r,d,N,g,M,pe,Se,ge,Te,ue,me,Ce,Ee,fe,Ne,Me,he,Pe,Oe,Re,Ie,ye,Ge,Ae,ve,$e,be,V,we,xe,De,Xe,Ve,ze,Ue,Be,He,We,[1,"content"],[1,"title"],["type","submit","spk-button","",1,"raised","primary",3,"click","disabled"],[1,"left"],[1,"right"],[1,"themes"],["src","assets/images/light-theme.png","alt","light theme",3,"click"],["src","assets/images/dark-theme.png","alt","dark theme",3,"click"],[1,"right","passphrase-form"],[1,"actions"],["value","value","label","label",3,"selectedOptionsChange","options","isClearable","inlineSearch"],["type","text",3,"ngModel","ngModelOptions"],[1,"right","remote-access-form"],[1,"primary","raised",3,"click"],[1,"indeterminate","primary"],[1,"right","radios"],[1,"radio-option",3,"click"],[1,"primary","raised"],[1,"content",3,"submit","formGroup"],["formGroupName","pauseSettings",1,"field-row"],[1,"raised","primary",3,"unit"],["type","range","formControlName","time",3,"min","max"],["label","label","value","value",3,"options","isClearable"],["type","text","formControlName","timeType"],["href","#"],["label","label","value","value",3,"options"],["type","text","formControlName","usageStatistics"],[1,"advanced-settings"],["for","password"],["type","password","name","password","autocomplete","disabled","placeholder",ke,"tabindex","1",3,"ngModelChange","ngModel"],["for","repeatPassword"],["type","password","name","repeatPassword","autocomplete","disabled","placeholder",Fe,"tabindex","2",3,"ngModelChange","disabled","ngModel"],["suffix","",1,"spk-success"],["suffix",""],["spk-button","",3,"click"],["spk-button","",1,"raised","primary",3,"loader"],["message",Le,1,"primary"],["spk-button","",1,"raised","primary",3,"click"],["spk-button","",1,"raised","primary",3,"click","disabled"],[1,"spk-success"],["for","allowedHostnames"],["type","text","id","allowedHostnames",3,"ngModelChange","ngModel"],["type","primary"]]},template:function(e,n){if(e&1&&(P(0,"app-status-bar"),i(1,"div",41)(2,"header")(3,"div",42)(4,"h2"),a(5,0),o(),i(6,"p"),a(7,1),o()(),i(8,"button",43),S("click",function(){return n.submit()}),a(9,2),o()(),i(10,"section")(11,"div",44)(12,"h3"),a(13,3),o(),i(14,"p"),I(15),o()(),i(16,"div",45),P(17,"app-remote-control"),o()(),i(18,"section")(19,"div",44)(20,"h3"),a(21,4),o(),i(22,"p"),a(23,5),o()(),i(24,"div",45)(25,"div",46)(26,"img",47),S("click",function(){return n.setLightMode()}),o(),i(27,"img",48),S("click",function(){return n.setDarkMode()}),o()()()(),i(28,"section")(29,"div",44)(30,"h3"),a(31,6),o(),i(32,"p"),a(33,7),o()(),i(34,"div",49),E(35,zt,15,7)(36,Bt,4,1,"div",50),o()(),i(37,"section")(38,"div",44)(39,"h3"),a(40,8),o(),i(41,"p"),a(42,9),o()(),i(43,"div",45)(44,"spk-select",51),S("selectedOptionsChange",function(d){return n.updateLocale(d)}),P(45,"input",52),o()()(),i(46,"section")(47,"div",44)(48,"h3"),a(49,10),o(),i(50,"p"),a(51,11),o()(),i(52,"div",53)(53,"spk-toggle",54),S("click",function(){return n.updateRemoteAccess()}),i(54,"label"),a(55,12),o()(),E(56,Ht,8,3),o()(),i(57,"section")(58,"div",44)(59,"h3"),a(60,13),o(),i(61,"p"),a(62,14),o()(),i(63,"div",45)(64,"spk-toggle",54),S("click",function(){return n.saveDisableTrayIconLogin()}),i(65,"label"),a(66,15),o()()()(),i(67,"section")(68,"div",44)(69,"h3"),a(70,16),o(),i(71,"p"),E(72,Wt,1,1),o(),E(73,qt,1,0,"spk-progress-bar",55),o(),i(74,"div",56)(75,"div",57),S("click",function(){return n.setNewChannel("")}),i(76,"spk-radio",58),a(77,17),o(),i(78,"p"),a(79,18),o()(),i(80,"div",57),S("click",function(){return n.setNewChannel("stable")}),i(81,"spk-radio",58),a(82,19),o(),i(83,"p"),a(84,20),o()(),i(85,"div",57),S("click",function(){return n.setNewChannel("beta")}),i(86,"spk-radio",58),a(87,21),o(),i(88,"p"),a(89,22),o()(),i(90,"div",57),S("click",function(){return n.setNewChannel("experimental")}),i(91,"spk-radio",58),a(92,23),o(),i(93,"p"),a(94,24),o()(),i(95,"div",57),S("click",function(){return n.setNewChannel("canary")}),i(96,"spk-radio",58),a(97,25),o(),i(98,"p"),a(99,26),o()()()()(),P(100,"spk-divider"),i(101,"form",59),S("submit",function(){return n.submit()}),i(102,"section")(103,"div",44)(104,"h3"),a(105,27),o(),i(106,"p"),a(107,28),o()(),i(108,"div",45)(109,"div",60)(110,"spk-range-slider",61),P(111,"input",62),o(),i(112,"spk-select",63),P(113,"input",64),E(114,jt,1,1,"ng-template"),o()()()(),i(115,"section")(116,"div",44)(117,"h3"),a(118,29),o(),i(119,"p"),U(120,30),P(121,"a",65)(122,"br")(123,"br"),B(),o()(),i(124,"div",45)(125,"spk-select",66),P(126,"input",67),E(127,Kt,1,1,"ng-template"),o()()()(),i(128,"div",41)(129,"section")(130,"div",68)(131,"h3"),a(132,31),o(),P(133,"app-advanced-options-settings"),o()()()),e&2){let r,d,N,g;l(8),h("disabled",n.settingsForm.untouched),l(7),H(n.remoteControlStatus()),l(11),f("active",!n.isDarkMode()),l(),f("active",n.isDarkMode()),l(8),C(n.showPassphraseForm()?35:36),l(9),h("options",n.languageOptions())("isClearable",!1)("inlineSearch",!0),l(),h("ngModel",n.langCtrl())("ngModelOptions",q(38,Lt)),l(8),f("active",n.allowRemoteAccess()),l(3),C(n.allowRemoteAccess()?56:-1),l(8),f("active",n.disableTrayIconLogin()),l(8),C(n.updateChannel()!==""&&((r=n.sysinfo())!=null&&r.ServerVersion)?72:-1),l(),C(n.updatingChannel()?73:-1),l(3),f("active",n.updateChannel()===""),l(),ae((d=n.sysinfo())==null?null:d.DefaultUpdateChannel),le(77),l(2),ae((N=n.sysinfo())==null?null:N.ServerVersionType),le(79),l(2),f("active",n.updateChannel()==="stable"),l(5),f("active",n.updateChannel()==="beta"),l(5),f("active",n.updateChannel()==="experimental"),l(5),f("active",n.updateChannel()==="canary"),l(5),h("formGroup",n.settingsForm),l(9),h("unit",(g=n.timeTypeSignal())!==null&&g!==void 0?g:""),l(),h("min",n.timeRange()[0])("max",n.timeRange()[1]),l(),h("options",n.timeTypeOptions())("isClearable",!1),l(13),h("options",n.usageStatisticsOptions())}},dependencies:[ne,pt,Y,St,ee,dt,te,ie,gt,ut,Tt,Et,re,D,Q,rt,at,st,_t,ct,Z,j,ot,K,lt],styles:["[_nghost-%COMP%]{display:block}.content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:0 2rem 2rem}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:2rem 0;position:sticky;top:0;background:var(--base-level-10);z-index:1000;border-bottom:1px solid var(--base-level-40)}header[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}section[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem;padding:2rem 0;border-top:1px solid var(--base-level-40)}section[_ngcontent-%COMP%]:first-of-type{border-top:0}section[_ngcontent-%COMP%] .left[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem;align-items:flex-start}section[_ngcontent-%COMP%] .left[_ngcontent-%COMP%] spk-button-group[_ngcontent-%COMP%]{margin-top:.25rem}section[_ngcontent-%COMP%] .left[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-wrap:balance;width:50%}.passphrase-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:flex-start;gap:1rem}.passphrase-form[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.remote-access-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.themes[_ngcontent-%COMP%]{display:flex;gap:.5rem}.themes[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{max-width:240px;border-radius:var(--shape-3);cursor:pointer}.themes[_ngcontent-%COMP%] img.active[_ngcontent-%COMP%]{border:2px solid var(--primary-500)}.radios[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.radio-option[_ngcontent-%COMP%]{cursor:pointer}.radio-option[_ngcontent-%COMP%] spk-radio[_ngcontent-%COMP%]{color:var(--base-level-60);margin-bottom:.25rem}.radio-option[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-wrap:balance;color:var(--base-level-60R)}.field-col[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.field-row[_ngcontent-%COMP%]{display:flex;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] spk-form-field[_ngcontent-%COMP%], .field-row[_ngcontent-%COMP%] spk-select[_ngcontent-%COMP%]{flex:1 0}.advanced-settings[_ngcontent-%COMP%]{grid-column:1/-1;display:grid;grid-template-columns:auto 1fr;gap:1rem}"],changeDetection:0})};export{de as default};