@duplicati/ngclient 0.0.50 → 0.0.52
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/spk.woff2 +0 -0
- package/{chunk-QVBSCQE5.js → chunk-357MEO73.js} +1 -1
- package/{chunk-LDPVZ7HY.js → chunk-4JABYZCU.js} +1 -1
- package/{chunk-PG6H3R6N.js → chunk-52PLNEEU.js} +1 -1
- package/chunk-62SAGIBE.js +1 -0
- package/chunk-6FOLH2A7.js +1 -0
- package/{chunk-FNBPWR4X.js → chunk-6G5MO2LW.js} +1 -1
- package/{chunk-5CNGSXWF.js → chunk-6XUGGGJW.js} +1 -1
- package/chunk-7DNBOPA2.js +1 -0
- package/{chunk-2JNOYYQN.js → chunk-7RHSTKHT.js} +1 -1
- package/{chunk-3RFC4Q5V.js → chunk-7ZY4AW73.js} +1 -1
- package/chunk-DNXP5WQT.js +1 -0
- package/{chunk-TFD4HD6F.js → chunk-E6NXFEY6.js} +1 -1
- package/chunk-EANM4F5Q.js +1 -0
- package/{chunk-WDHZG25P.js → chunk-ETMR6JG6.js} +1 -1
- package/chunk-FUENP7LQ.js +1 -0
- package/chunk-HGKCNEQ4.js +1 -0
- package/{chunk-6XZQG7L7.js → chunk-HRUCGEQL.js} +1 -1
- package/{chunk-LQL7UFPH.js → chunk-HW2X3WEE.js} +1 -1
- package/{chunk-WMC5H5UV.js → chunk-IQNE6QMR.js} +1 -1
- package/chunk-IW4H6RJH.js +1 -0
- package/chunk-JFN26EE2.js +1 -0
- package/{chunk-YK6SXMBM.js → chunk-JRLAYIPU.js} +1 -1
- package/{chunk-MWCNA7Y5.js → chunk-MRRA6ZB2.js} +1 -1
- package/{chunk-FALW4SDX.js → chunk-NZ5QQIUJ.js} +1 -1
- package/chunk-NZJCL3BX.js +1 -0
- package/chunk-PFQRJ432.js +1 -0
- package/{chunk-CKTCGJPR.js → chunk-QLEXNL6F.js} +1 -1
- package/{chunk-OJUBI3TM.js → chunk-R5ARSI2W.js} +1 -1
- package/{chunk-4765QCNT.js → chunk-TLM42G2X.js} +1 -1
- package/{chunk-YWZWJHRE.js → chunk-TOUGWZ56.js} +1 -1
- package/chunk-VBS3YNVR.js +1 -0
- package/{chunk-OYSDTWXA.js → chunk-XWIXIQIA.js} +1 -1
- package/{chunk-Z7UXXM2M.js → chunk-XWRLDJ4Y.js} +1 -1
- package/chunk-YFA44VRS.js +1 -0
- package/{chunk-DV7N4NYO.js → chunk-ZJMDOZXF.js} +1 -1
- package/{chunk-XO6YTY63.js → chunk-ZOOONPFY.js} +3 -3
- package/{chunk-MJJYBD2L.js → chunk-ZS2AJHUM.js} +1 -1
- package/index.html +2 -2
- package/{main-XHR6OEX7.js → main-G2EKF3C3.js} +1 -1
- package/package.json +1 -1
- package/styles-AIQ3E4AK.css +1 -0
- package/chunk-2UNV5KQ7.js +0 -1
- package/chunk-5FSG4VRJ.js +0 -1
- package/chunk-7PE677UQ.js +0 -1
- package/chunk-FFD5RG7J.js +0 -1
- package/chunk-FJKXE3RZ.js +0 -1
- package/chunk-IE4GYLKI.js +0 -1
- package/chunk-JRYVI7GA.js +0 -1
- package/chunk-N23IUXUM.js +0 -1
- package/chunk-TICM6BU7.js +0 -1
- package/chunk-U4SEXW7F.js +0 -1
- package/chunk-VOVR4GPX.js +0 -1
- package/chunk-WVBAR46B.js +0 -1
- package/chunk-XMM537S7.js +0 -1
- package/styles-QS7LVTVV.css +0 -1
package/assets/spk.woff2
CHANGED
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as b,b as $,d as y,e as B,h,l as v,o as G,p as L,r as U}from"./chunk-QXNJFFEM.js";import{
|
|
1
|
+
import{a as j}from"./chunk-O47LGUY4.js";import{a as b,b as $,d as y,e as B,h,l as v,o as G,p as L,r as U}from"./chunk-QXNJFFEM.js";import{b as N}from"./chunk-PSJAIBCQ.js";import{c as E,d as R}from"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import{a as K,c as w,g as X,l as x,w as V,y as z}from"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import"./chunk-X566VMXX.js";import{Ab as n,Bb as l,E as g,Lb as I,Mb as M,Nb as u,Oa as F,Qb as O,Rb as f,Va as m,X as p,bb as S,ec as A,hb as D,oc as k,qb as d,sb as C,vb as P,zb as r}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";var q=()=>["/"];function H(c,e){c&1&&(r(0,"spk-form-field")(1,"label",18),u(2,4),n(),l(3,"input",19),n())}var s=new L,T=class c{#e=p(w);#t=p(N);#o=p(j);#n=p(E);isImporting=m(!1);isSecureFile=m(!1);importForm=s.group({config:s.control(""),cmdline:s.control(!1),importMetadata:s.control(!1),direct:s.control(!1),passphrase:s.control("")});selectedFile=m(null);onFileDropped(e){let t=e.target?.files?.item(0);if(t){let i=new FileReader;this.isSecureFile.set(t.type!=="application/json"),i.onload=this.#i.bind(this),i.readAsArrayBuffer(t)}}#i(e){let o=e.target?.result;this.importForm.patchValue({config:this.#r(o)})}#r(e){let o=new Uint8Array(e),t=o.byteLength,i="";for(let a=0;a<t;a++)i+=String.fromCharCode(o[a]);return btoa(i)}submit(){this.isImporting.set(!0),this.#t.postApiV1BackupsImport({requestBody:this.importForm.value}).pipe(g(()=>this.isImporting.set(!1))).subscribe({next:e=>{let o=this.#o.addDraftBackup(e.data);this.#n.navigate(["/backup-draft",o])},error:e=>{this.#e.error(e.message)}})}static \u0275fac=function(o){return new(o||c)};static \u0275cmp=S({type:c,selectors:[["app-import"]],decls:24,vars:7,consts:()=>{let e;e=$localize` Import backup configuration ${"\uFFFD#3\uFFFD"}:START_TAG_DIV:${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"[\uFFFD#5\uFFFD|\uFFFD#7\uFFFD]"}:START_TAG_SPK_ICON:arrow-left${"[\uFFFD/#5\uFFFD|\uFFFD/#7\uFFFD]"}:CLOSE_TAG_SPK_ICON: Back ${"[\uFFFD/#4\uFFFD|\uFFFD/#6\uFFFD]"}:CLOSE_TAG_BUTTON:${"\uFFFD#6\uFFFD"}:START_TAG_BUTTON_1:${"[\uFFFD#5\uFFFD|\uFFFD#7\uFFFD]"}:START_TAG_SPK_ICON:download-simple${"[\uFFFD/#5\uFFFD|\uFFFD/#7\uFFFD]"}:CLOSE_TAG_SPK_ICON: Import ${"[\uFFFD/#4\uFFFD|\uFFFD/#6\uFFFD]"}:CLOSE_TAG_BUTTON:${"\uFFFD/#3\uFFFD"}:CLOSE_TAG_DIV:`,e=O(e);let o;o=$localize`Select a configuration file`;let t;t=$localize`Import Metadata`;let i;i=$localize`Save now`;let a;return a=$localize`Passphrase`,[e,o,t,i,a,[1,"actions"],["spk-button","","type","button",1,"outlined",3,"routerLink"],["spk-button","","type","submit",1,"raised","primary",3,"click","disabled"],["autocomplete","off",3,"formGroup"],["spkDragDrop","",3,"fileDropped"],["for","file"],["type","file","accept",".json,.aes",3,"change"],["suffix",""],[1,"primary","raised"],["for","importMetadata"],["type","checkbox","formControlName","importMetadata"],["for","direct"],["type","checkbox","formControlName","direct"],["for","passphrase"],["type","password","formControlName","passphrase"]]},template:function(o,t){o&1&&(r(0,"header")(1,"h3"),I(2,0),r(3,"div",5)(4,"button",6),l(5,"spk-icon"),n(),r(6,"button",7),f("click",function(){return t.submit()}),l(7,"spk-icon"),n()(),M(),n()(),r(8,"form",8)(9,"spk-form-field",9),f("fileDropped",function(a){return t.onFileDropped(a)}),r(10,"label",10),u(11,1),n(),r(12,"input",11),f("change",function(a){return t.onFileDropped(a)}),n(),r(13,"spk-icon",12),A(14,"upload"),n()(),D(15,H,4,0,"spk-form-field"),r(16,"spk-toggle",13)(17,"label",14),u(18,2),n(),l(19,"input",15),n(),r(20,"spk-toggle",13)(21,"label",16),u(22,3),n(),l(23,"input",17),n()()),o&2&&(F(4),d("routerLink",k(6,q)),F(2),C("loader",t.isImporting()),d("disabled",t.isImporting()),F(2),d("formGroup",t.importForm),F(7),P(t.isSecureFile()?15:-1))},dependencies:[U,h,$,b,y,B,v,G,R,z,x,K,X,V],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:2rem;padding:3rem}h3[_ngcontent-%COMP%]{font:var(--title-30);display:flex;align-items:center;justify-content:space-between}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;max-width:31.25rem}"],changeDetection:0})};export{T as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{q as g}from"./chunk-
|
|
1
|
+
import{q as g}from"./chunk-TOUGWZ56.js";import"./chunk-TLM42G2X.js";import"./chunk-NZ5QQIUJ.js";import"./chunk-DNHLTHLR.js";import{b as k}from"./chunk-TYEKJAUH.js";import"./chunk-QTTCN7A7.js";import{a as I}from"./chunk-JFN26EE2.js";import{a as N}from"./chunk-O47LGUY4.js";import"./chunk-QXNJFFEM.js";import{b as O}from"./chunk-PSJAIBCQ.js";import{a as P,b as h,d as E,e as B}from"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import{o as $,p as M,t as b}from"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import"./chunk-R6C4MOOH.js";import"./chunk-X566VMXX.js";import"./chunk-BI7LIYF6.js";import{Ab as p,B as m,Bb as n,Jc as A,Lb as d,Mb as c,Oa as r,X as F,bb as f,hb as C,nc as R,qb as u,qc as _,vb as D,zb as s}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";var K=(i,e)=>[i,e,"general"],L=(i,e)=>[i,e,"destination"],v=(i,e)=>[i,e,"source-data"],G=(i,e)=>[i,e,"schedule"],y=(i,e)=>[i,e,"options"];function U(i,e){i&1&&n(0,"spk-progress-bar",6)}function X(i,e){i&1&&(s(0,"section"),n(1,"router-outlet"),p())}var T=class i{#t=F(P);#e=F(g);#a=F(N);#i=F(O);isDraft=this.#e.isDraft;backupId=this.#e.backupId;finishedLoading=this.#e.finishedLoading;#o=k(this.#t.params);#n=k(this.#t.url);paramsChanged=A(()=>{let e=this.#o()?.id,a=!!this.#n()?.find(t=>t.path==="backup-draft");this.#e.backupId.set(e),e!=="new"?this.getBackup(e,a):this.getDefaults()});getDefaults(){this.#i.getApiV1Backupdefaults().pipe(m(1)).subscribe({next:e=>{this.#e.mapScheduleToForm(e.Schedule),this.#e.mapOptionsToForms(e.Backup),this.#e.backupDefaults.set(e),this.#e.finishedLoading.set(!0)}})}getBackup(e,a=!1){let t=o=>{this.#e.mapScheduleToForm(o.Schedule??null),o.Backup&&(this.#e.mapGeneralToForm(o.Backup),this.#e.mapDestinationToForm(o.Backup),this.#e.mapSourceDataToForm(o.Backup),this.#e.mapOptionsToForms(o.Backup)),this.#e.finishedLoading.set(!0)};if(a){this.isDraft.set(a);let o=this.#a.draftBackups().find(l=>l.id===e);if(!o){alert("Backup not found");return}t(o.data)}else this.#i.getApiV1BackupById({id:e}).subscribe({next:t})}static \u0275fac=function(a){return new(a||i)};static \u0275cmp=f({type:i,selectors:[["app-backup"]],features:[R([g])],decls:20,vars:21,consts:()=>{let e;e=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SPK_RADIO:${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SPK_RADIO: General `;let a;a=$localize`${"\uFFFD#8\uFFFD"}:START_TAG_SPK_RADIO:${"\uFFFD/#8\uFFFD"}:CLOSE_TAG_SPK_RADIO: Destination `;let t;t=$localize`${"\uFFFD#11\uFFFD"}:START_TAG_SPK_RADIO:${"\uFFFD/#11\uFFFD"}:CLOSE_TAG_SPK_RADIO: Source Data `;let o;o=$localize`${"\uFFFD#14\uFFFD"}:START_TAG_SPK_RADIO:${"\uFFFD/#14\uFFFD"}:CLOSE_TAG_SPK_RADIO: Schedule `;let l;return l=$localize`${"\uFFFD#17\uFFFD"}:START_TAG_SPK_RADIO:${"\uFFFD/#17\uFFFD"}:CLOSE_TAG_SPK_RADIO: Options `,[e,a,t,o,l,["step","","routerLinkActive","active",3,"routerLink"],[1,"indeterminate","primary"]]},template:function(a,t){a&1&&(n(0,"app-status-bar"),s(1,"header")(2,"spk-stepper")(3,"div",5),d(4,0),n(5,"spk-radio"),c(),p(),s(6,"div",5),d(7,1),n(8,"spk-radio"),c(),p(),s(9,"div",5),d(10,2),n(11,"spk-radio"),c(),p(),s(12,"div",5),d(13,3),n(14,"spk-radio"),c(),p(),s(15,"div",5),d(16,4),n(17,"spk-radio"),c(),p()()(),C(18,U,1,0,"spk-progress-bar",6)(19,X,2,0,"section")),a&2&&(r(3),u("routerLink",_(6,K,t.isDraft()?"/backup-draft":"/backup",t.backupId())),r(3),u("routerLink",_(9,L,t.isDraft()?"/backup-draft":"/backup",t.backupId())),r(3),u("routerLink",_(12,v,t.isDraft()?"/backup-draft":"/backup",t.backupId())),r(3),u("routerLink",_(15,G,t.isDraft()?"/backup-draft":"/backup",t.backupId())),r(3),u("routerLink",_(18,y,t.isDraft()?"/backup-draft":"/backup",t.backupId())),r(3),D(t.finishedLoading()?19:18))},dependencies:[h,E,B,I,M,b,$],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;height:100%}header[_ngcontent-%COMP%]{padding:1rem 1.5rem;border-bottom:1px solid var(--base-level-40)}header[_ngcontent-%COMP%] spk-stepper[_ngcontent-%COMP%]{width:100%}section[_ngcontent-%COMP%]{width:100%;display:flex;justify-content:center;flex:1 0;overflow:hidden}"],changeDetection:0})};export{T as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as K}from"./chunk-TYEKJAUH.js";import{b as X}from"./chunk-PSJAIBCQ.js";import{a as z,d as J,g as q}from"./chunk-
|
|
1
|
+
import{b as K}from"./chunk-TYEKJAUH.js";import{b as X}from"./chunk-PSJAIBCQ.js";import{a as z,d as J,g as q}from"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import"./chunk-X566VMXX.js";import{Ab as a,Bb as g,Fb as u,Jc as W,La as E,Lb as A,Mb as D,Nb as y,Oa as l,Rb as S,Sb as f,Va as m,Vb as w,X as v,bb as h,ca as d,da as _,ec as c,fc as C,gc as I,hb as k,hc as N,jc as $,kc as B,lc as V,mc as U,oc as G,p as T,qb as F,vb as x,wb as M,xb as P,yb as R,zb as i}from"./chunk-NHACGZPI.js";import{a as b,b as O}from"./chunk-C6Q5SG76.js";var j=()=>({maxWidth:"700px",width:"100%"});function H(s,t){if(s&1&&(i(0,"a",9)(1,"spk-icon"),c(2,"link"),a()()),s&2){let e=f().$implicit;w("href",e.Url,E)}}function Q(s,t){if(s&1){let e=u();i(0,"div",2)(1,"h4"),c(2),k(3,H,3,1,"a",9),a(),i(4,"p"),c(5),g(6,"br"),i(7,"i"),c(8),a()(),i(9,"div",10)(10,"button",11),S("click",function(){let o=d(e).$implicit,r=f();return _(r.openLicense(o))}),A(11,1),g(12,"spk-icon"),D(),a()()()}if(s&2){let e=t.$implicit;l(2),N(" ",e.Title," - ",e.data==null?null:e.data.license," "),l(),x(e.Url?3:-1),l(2),I(" ",e.data==null?null:e.data.description," "),l(3),C(e.data==null?null:e.data.notes)}}var L=class s{#e=v(X);licenses=K(this.#e.getApiV1Licenses().pipe(T(t=>t.map(e=>O(b({},e),{data:e.Jsondata?JSON.parse(e.Jsondata):null})))));dialogIsOpen=m(!1);dialogLicense=m(null);#t=W(()=>{this.dialogLicense()&&this.dialogIsOpen.set(!0)});openLicense(t){this.dialogLicense.set(t)}closeLicense(){this.dialogIsOpen.set(!1),this.dialogLicense.set(null)}breakIntoLines(t){let e=t.split(`
|
|
2
2
|
`),n="";for(let o=0;o<e.length;o++)n+=`<li>${e[o]}</li>`;return n}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=h({type:s,selectors:[["app-libraries"]],decls:15,vars:5,consts:()=>{let t;t=$localize`Libraries`;let e;return e=$localize` Details ${"\uFFFD#12\uFFFD"}:START_TAG_SPK_ICON:arrow-square-in${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SPK_ICON:`,[t,e,[1,"license"],[3,"isOpenChange","isOpen","options"],["header",""],["content",""],[1,"license-dialog"],["footer",""],["spk-button","","type","button",3,"click"],[3,"href"],[1,"actions"],["spk-button","",3,"click"]]},template:function(e,n){if(e&1){let o=u();i(0,"h3"),y(1,0),a(),P(2,Q,13,5,"div",2,M),i(4,"spk-dialog",3),V("isOpenChange",function(p){return d(o),B(n.dialogIsOpen,p)||(n.dialogIsOpen=p),_(p)}),i(5,"header",4)(6,"h3"),c(7),a()(),i(8,"div",5),U(9),i(10,"div",6),c(11),a()(),i(12,"footer",7)(13,"button",8),S("click",function(){return d(o),_(n.dialogLicense.set(null))}),c(14,"Close"),a()()()}if(e&2){let o,r;l(2),R(n.licenses()),l(2),$("isOpen",n.dialogIsOpen),F("options",G(4,j)),l(3),C((o=n.dialogLicense())==null?null:o.Title);let p=(r=(r=n.dialogLicense())==null?null:r.License)!==null&&r!==void 0?r:"";l(4),I(" ",p," ")}},dependencies:[z,q,J],styles:["[_nghost-%COMP%]{display:block}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0 0 1.25rem}h4[_ngcontent-%COMP%]{font:var(--paragraph-10)}a[_ngcontent-%COMP%]{text-decoration:none}.license[_ngcontent-%COMP%]{padding:1rem;border-bottom:1px solid var(--base-level-40);display:flex;flex-direction:column;align-items:flex-start;gap:.5rem}.license[_ngcontent-%COMP%]:first-of-type{border-top:1px solid var(--base-level-40)}.license[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;gap:.25rem;align-items:center}.license-dialog[_ngcontent-%COMP%]{background-color:var(--base-level-10);color:var(--base-level-70);padding:2.5rem 2.5rem 2.5rem 1.5rem;border-radius:var(--shape-3);overflow:auto;max-height:31.25rem;white-space:pre;border:1px solid var(--base-level-40)}"],changeDetection:0})};export{L as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{b as $}from"./chunk-TYEKJAUH.js";import{a as R}from"./chunk-JFN26EE2.js";import"./chunk-O47LGUY4.js";import"./chunk-QXNJFFEM.js";import{b as k}from"./chunk-PSJAIBCQ.js";import{a as A,d as N}from"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import{a as B,g as O}from"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import"./chunk-R6C4MOOH.js";import"./chunk-X566VMXX.js";import"./chunk-BI7LIYF6.js";import{Ab as a,Bb as r,Hc as M,Lb as _,Mb as c,Nb as u,Oa as i,Qb as T,Rb as I,Va as l,X as m,bb as C,ec as E,gc as L,hb as p,vb as s,wb as f,xb as S,yb as g,zb as F}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";function b(e,t){e&1&&u(0,2,1)}function P(e,t){e&1&&u(0,2,2)}function h(e,t){e&1&&u(0,2,3)}function v(e,t){e&1&&u(0,2,4)}function U(e,t){if(e&1&&(E(0),r(1,"br")),e&2){let n=t.$implicit;L(" ",n," ")}}var D=class e{#t=m(k);#e=m(A);#n=$(this.#e.params);runId=M(()=>this.#n()?.runId);offset=l(0);status=l("starting");messageLog=l([]);interval=setInterval(()=>{this.#t.getApiV1CommandlineByRunid({runid:this.runId(),offset:this.offset(),pagesize:100}).subscribe(t=>{this.offset.set(t.Count),this.evalStatus(t),this.messageLog.update(n=>[...n,...t.Items])})},1e3);evalStatus(t){t.Started===!0&&t.Finished===!0&&(this.status.set("finished"),clearInterval(this.interval)),t.Started===!0&&t.Finished===!1&&this.status.set("started")}abort(){this.#t.postApiV1CommandlineByRunidAbort({runid:this.runId()}).subscribe({next:t=>{this.status.set("aborted"),clearInterval(this.interval)}})}static \u0275fac=function(n){return new(n||e)};static \u0275cmp=C({type:e,selectors:[["app-commandline-result"]],decls:18,vars:4,consts:()=>{let t;t=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SPK_ICON:arrow-left${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SPK_ICON: Back `;let n;n=$localize` Running commandline task... ${"\uFFFD#8\uFFFD"}:START_TAG_BUTTON:Abort${"\uFFFD/#8\uFFFD"}:CLOSE_TAG_BUTTON:`;let o;return o=$localize`${"\uFFFD*11:1\uFFFD"}:START_BLOCK_IF: Starting... ${"[\uFFFD/*11:1\uFFFD|\uFFFD/*12:2\uFFFD|\uFFFD/*13:3\uFFFD|\uFFFD/*14:4\uFFFD]"}:CLOSE_BLOCK_IF:${"\uFFFD*12:2\uFFFD"}:START_BLOCK_IF_1: Started! ${"[\uFFFD/*11:1\uFFFD|\uFFFD/*12:2\uFFFD|\uFFFD/*13:3\uFFFD|\uFFFD/*14:4\uFFFD]"}:CLOSE_BLOCK_IF:${"\uFFFD*13:3\uFFFD"}:START_BLOCK_IF_2: Finished! ${"[\uFFFD/*11:1\uFFFD|\uFFFD/*12:2\uFFFD|\uFFFD/*13:3\uFFFD|\uFFFD/*14:4\uFFFD]"}:CLOSE_BLOCK_IF:${"\uFFFD*14:4\uFFFD"}:START_BLOCK_IF_3: Aborted! ${"[\uFFFD/*11:1\uFFFD|\uFFFD/*12:2\uFFFD|\uFFFD/*13:3\uFFFD|\uFFFD/*14:4\uFFFD]"}:CLOSE_BLOCK_IF:`,o=T(o),[t,n,o,[1,"back"],["type","button","spk-button","","routerLink","/",1,"small"],["type","button","spk-button","",1,"small",3,"click"],[1,"status"]]},template:function(n,o){n&1&&(r(0,"app-status-bar"),F(1,"section")(2,"div",3)(3,"button",4),_(4,0),r(5,"spk-icon"),c(),a()(),F(6,"h3"),_(7,1),F(8,"button",5),I("click",function(){return o.abort()}),a(),c(),a(),F(9,"div",6),_(10,2),p(11,b,1,0)(12,P,1,0)(13,h,1,0)(14,v,1,0),c(),a(),F(15,"code"),S(16,U,2,1,null,null,f),a()()),n&2&&(i(11),s(o.status()==="starting"?11:-1),i(),s(o.status()==="started"?12:-1),i(),s(o.status()==="finished"?13:-1),i(),s(o.status()==="aborted"?14:-1),i(2),g(o.messageLog()))},dependencies:[R,B,O,N],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;width:100%;padding:2.5rem;gap:1.25rem}code[_ngcontent-%COMP%]{background-color:var(--grey-800);color:var(--grey-100);padding:2.5rem 2.5rem 2.5rem 1.5rem;border-radius:var(--shape-3);overflow:auto;white-space:pre}"],changeDetection:0})};export{D as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as ye}from"./chunk-NZ5QQIUJ.js";import{b as ve,c as ee}from"./chunk-TYEKJAUH.js";import{a as Ie}from"./chunk-FH6MENLO.js";import{a as fe}from"./chunk-JFN26EE2.js";import"./chunk-O47LGUY4.js";import"./chunk-QXNJFFEM.js";import{b as Q}from"./chunk-PSJAIBCQ.js";import{a as Pe,d as De}from"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import{a as k,g as Y,k as Re,o as Z,v as Me}from"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import{a as $e}from"./chunk-R6C4MOOH.js";import{pa as J,sa as H}from"./chunk-X566VMXX.js";import"./chunk-BI7LIYF6.js";import{Ab as n,Bb as s,Cb as x,Db as b,Fb as j,Lb as T,Mb as A,Nb as r,Oa as i,Ob as p,Pb as F,Qb as y,Rb as R,Sb as E,Va as L,X as f,bb as I,ca as z,da as V,ec as u,fc as M,gc as q,hb as O,ic as Ne,p as $,pa as W,qb as v,sb as S,sc as d,tc as c,uc as C,vb as g,wb as N,xb as P,yb as D,zb as t}from"./chunk-NHACGZPI.js";import{a as w}from"./chunk-C6Q5SG76.js";function be(o,a){o&1&&s(0,"spk-progress-bar",31)}function Be(o,a){o&1&&s(0,"div",34)}function he(o,a){o&1&&s(0,"div",35)}function Ke(o,a){o&1&&s(0,"div",36)}function Ue(o,a){if(o&1&&u(0),o&2){let e=E().$implicit;q(" (",e.data==null?null:e.data.WarningsActualLength," warnings) ")}}function Xe(o,a){if(o&1&&(t(0,"details",45)(1,"summary"),T(2,15),s(3,"spk-icon"),t(4,"div",46),s(5,"spk-icon",39),n(),A(),n(),t(6,"div",47)(7,"p"),r(8,16),d(9,"date"),n(),t(10,"p"),r(11,17),d(12,"date"),n(),t(13,"p"),r(14,18),d(15,"durationFormat"),n(),t(16,"p"),r(17,19),n(),s(18,"spk-divider"),t(19,"p"),r(20,20),n(),t(21,"p"),r(22,21),n()()(),t(23,"details",45)(24,"summary")(25,"spk-icon"),u(26,"file-archive"),n(),u(27," Compression phase "),t(28,"div",46)(29,"spk-icon",39),u(30,"caret-down"),n()()(),t(31,"div",47)(32,"p"),r(33,22),d(34,"date"),n(),t(35,"p"),r(36,23),d(37,"date"),n(),t(38,"p"),r(39,24),d(40,"durationFormat"),n(),s(41,"spk-divider"),t(42,"p"),r(43,25),d(44,"bytes"),n(),t(45,"p"),r(46,26),d(47,"bytes"),n(),t(48,"p"),r(49,27),d(50,"bytes"),n(),s(51,"spk-divider"),t(52,"p"),r(53,28),n(),t(54,"p"),r(55,29),n()()()),o&2){let e=E(2).$implicit;i(9),p(C(9,17,e.data==null||e.data.TestResults==null?null:e.data.TestResults.BeginTime,"medium")),F(8),i(3),p(C(12,20,e.data==null||e.data.TestResults==null?null:e.data.TestResults.EndTime,"medium")),F(11),i(3),p(c(15,23,e.data==null||e.data.TestResults==null?null:e.data.TestResults.Duration)),F(14),i(2),p(e.data==null||e.data.TestResults==null?null:e.data.TestResults.VerificationsActualLength),F(17),i(3),p(e.data==null||e.data.TestResults==null?null:e.data.TestResults.WarningsActualLength),F(20),i(2),p(e.data==null||e.data.TestResults==null?null:e.data.TestResults.ErrorsActualLength),F(22),i(12),p(C(34,25,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.BeginTime,"medium")),F(33),i(3),p(C(37,28,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.EndTime,"medium")),F(36),i(3),p(c(40,31,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.Duration)),F(39),i(4),p(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DeletedFileCount)(c(44,33,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DeletedFileSize)),F(43),i(3),p(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DownloadedFileCount)(c(47,35,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DownloadedFileSize)),F(46),i(3),p(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.UploadedFileCount)(c(50,37,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.UploadedFileSize)),F(49),i(3),p(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.WarningsActualLength),F(53),i(2),p(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.ErrorsActualLength),F(55)}}function we(o,a){if(o&1&&(t(0,"code"),u(1),d(2,"json"),n()),o&2){let e=a.$implicit;i(),M(c(2,1,e))}}function ze(o,a){if(o&1&&(t(0,"details",45)(1,"summary"),T(2,30),s(3,"spk-icon"),t(4,"div",46),s(5,"spk-icon",39),n(),A(),n(),t(6,"div",47),P(7,we,3,3,"code",null,N),n()()),o&2){let e=E(2).$implicit;i(5),p(e.data.VerificationsActualLength),F(2),i(2),D(e.data.Verifications)}}function Ve(o,a){if(o&1&&(t(0,"code"),u(1),d(2,"json"),n()),o&2){let e=a.$implicit;i(),M(c(2,1,e))}}function We(o,a){o&1&&(t(0,"p"),u(1,"No errors"),n())}function je(o,a){if(o&1&&(t(0,"code"),u(1),d(2,"json"),n()),o&2){let e=a.$implicit;i(),M(c(2,1,e))}}function qe(o,a){if(o&1&&(t(0,"section",40)(1,"app-toggle-card",41),x(2,42),t(3,"h3"),r(4,0),n(),b(),x(5,43),t(6,"p"),r(7,1),d(8,"date"),n(),t(9,"p"),r(10,2),d(11,"date"),n(),t(12,"p"),r(13,3),d(14,"durationFormat"),n(),b(),n(),t(15,"app-toggle-card",41),x(16,42),t(17,"h3"),r(18,4),n(),b(),x(19,43),t(20,"p"),r(21,5),d(22,"bytes"),n(),t(23,"p"),r(24,6),d(25,"bytes"),n(),t(26,"p"),r(27,7),d(28,"bytes"),n(),t(29,"p"),r(30,8),d(31,"bytes"),n(),t(32,"p"),r(33,9),n(),t(34,"p"),r(35,10),n(),t(36,"p"),r(37,11),n(),b(),n(),t(38,"div",44),s(39,"spk-divider"),O(40,Xe,56,39)(41,ze,9,1,"details",45),t(42,"details",45)(43,"summary"),T(44,12),s(45,"spk-icon"),t(46,"div",46),s(47,"spk-icon",39),n(),A(),n(),t(48,"div",47),P(49,Ve,3,3,"code",null,N),n()(),t(51,"details",45)(52,"summary"),T(53,13),s(54,"spk-icon"),t(55,"div",46),s(56,"spk-icon",39),n(),A(),n(),t(57,"div",47),O(58,We,2,0,"p"),P(59,je,3,3,"code",null,N),n()(),s(61,"spk-divider"),t(62,"details")(63,"summary"),T(64,14),s(65,"spk-icon"),t(66,"div",46),s(67,"spk-icon",39),n(),A(),n(),t(68,"code")(69,"button",48),u(70,"Copy"),n(),u(71),d(72,"json"),n()()()()),o&2){let e=E().$implicit;i(),v("disallowToggle",!0),i(7),p(C(8,22,e.data==null?null:e.data.BeginTime,"medium")),F(7),i(3),p(C(11,25,e.data==null?null:e.data.EndTime,"medium")),F(10),i(3),p(c(14,28,e.data==null?null:e.data.Duration)),F(13),i(),v("disallowToggle",!0),i(7),p(e.data==null?null:e.data.ExaminedFiles)(c(22,30,e.data==null?null:e.data.SizeOfExaminedFiles)),F(21),i(3),p(e.data==null?null:e.data.OpenedFiles)(c(25,32,e.data==null?null:e.data.SizeOfOpenedFiles)),F(24),i(3),p(e.data==null?null:e.data.AddedFiles)(c(28,34,e.data==null?null:e.data.SizeOfAddedFiles)),F(27),i(3),p(e.data==null?null:e.data.ModifiedFiles)(c(31,36,e.data==null?null:e.data.SizeOfModifiedFiles)),F(30),i(2),p(e.data==null?null:e.data.DeletedFiles),F(33),i(2),p(e.data==null?null:e.data.TooLargeFiles),F(35),i(2),p(e.data==null?null:e.data.FilesWithError),F(37),i(3),g((e.data==null?null:e.data.MainOperation)==="Backup"?40:-1),i(),g((e.data==null?null:e.data.MainOperation)==="Test"?41:-1),i(6),p(e.data==null?null:e.data.WarningsActualLength),F(44),i(2),D(e.data==null?null:e.data.Warnings),i(7),p(e.data==null?null:e.data.ErrorsActualLength),F(53),i(2),g((e.data==null||e.data.Errors==null?null:e.data.Errors.length)===0?58:-1),i(),D(e.data==null?null:e.data.Errors),i(12),q(" ",c(72,38,e.data)," ")}}function Je(o,a){if(o&1){let e=j();t(0,"article",32)(1,"header",33),R("click",function(){let m=z(e).$implicit,G=E();return V(G.toggleOpenEntry(m.id))}),O(2,Be,1,0,"div",34)(3,he,1,0,"div",35)(4,Ke,1,0,"div",36),t(5,"h3"),u(6),d(7,"date"),n(),t(8,"p"),u(9),O(10,Ue,1,1),n(),s(11,"div",37),t(12,"div",38)(13,"spk-icon",39),u(14,"caret-down"),n()()(),O(15,qe,73,40,"section",40),n()}if(o&2){let e=a.$implicit,l=E();i(2),g(e.data!=null&&e.data.ErrorsActualLength&&(e.data==null?null:e.data.ErrorsActualLength)>0?2:e.data!=null&&e.data.WarningsActualLength&&(e.data==null?null:e.data.WarningsActualLength)>0?3:4),i(4),M(C(7,7,e.timestamp,"medium")),i(3),q(" ",e.data==null?null:e.data.MainOperation," "),i(),g(e.data!=null&&e.data.WarningsActualLength&&(e.data==null?null:e.data.WarningsActualLength)>0?10:-1),i(3),S("open",e.id===l.openEntry()),i(2),g(e.id===l.openEntry()?15:-1)}}var ne=class o{#e=f(Q);backupId=W.required();openEntry=L(null);pagination=L({offset:0,pagesize:100});resource=ee({request:()=>w({id:this.backupId()},this.pagination()),loader:({request:a})=>this.#e.getApiV1BackupByIdLog({id:a.id,pagesize:100}).pipe($(e=>e.map(l=>({id:l.ID,operationId:l.OperationID,timestamp:l.Timestamp*1e3,type:l.Type,data:JSON.parse(l.Message),exception:JSON.stringify(l.Exception)==="{}"?null:l.Exception}))))});toggleOpenEntry(a){if(this.openEntry()===a){this.openEntry.set(null);return}this.openEntry.set(a)}static \u0275fac=function(e){return new(e||o)};static \u0275cmp=I({type:o,selectors:[["app-general-log"]],inputs:{backupId:[1,"backupId"]},decls:3,vars:1,consts:()=>{let a;a=$localize`Time`;let e;e=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let l;l=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let m;m=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let G;G=$localize`Source files`;let oe;oe=$localize`Evaluated: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let ae;ae=$localize`Opened: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let le;le=$localize`Added: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let _e;_e=$localize`Modified: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let re;re=$localize`Deleted: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let se;se=$localize`Too large: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let pe;pe=$localize`Files with error: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let B;B=$localize`${"\uFFFD#45\uFFFD"}:START_TAG_SPK_ICON:warning-circle${"[\uFFFD/#45\uFFFD|\uFFFD/#47\uFFFD]"}:CLOSE_TAG_SPK_ICON: Warnings ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#46\uFFFD"}:START_TAG_DIV:${"\uFFFD#47\uFFFD"}:START_TAG_SPK_ICON_1:caret-down${"[\uFFFD/#45\uFFFD|\uFFFD/#47\uFFFD]"}:CLOSE_TAG_SPK_ICON:${"\uFFFD/#46\uFFFD"}:CLOSE_TAG_DIV:`,B=y(B);let h;h=$localize`${"\uFFFD#54\uFFFD"}:START_TAG_SPK_ICON:warning${"[\uFFFD/#54\uFFFD|\uFFFD/#56\uFFFD]"}:CLOSE_TAG_SPK_ICON: Errors ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#55\uFFFD"}:START_TAG_DIV:${"\uFFFD#56\uFFFD"}:START_TAG_SPK_ICON_1:caret-down${"[\uFFFD/#54\uFFFD|\uFFFD/#56\uFFFD]"}:CLOSE_TAG_SPK_ICON:${"\uFFFD/#55\uFFFD"}:CLOSE_TAG_DIV:`,h=y(h);let K;K=$localize`${"\uFFFD#65\uFFFD"}:START_TAG_SPK_ICON:notepad${"[\uFFFD/#65\uFFFD|\uFFFD/#67\uFFFD]"}:CLOSE_TAG_SPK_ICON: Complete log ${"\uFFFD#66\uFFFD"}:START_TAG_DIV:${"\uFFFD#67\uFFFD"}:START_TAG_SPK_ICON_1:caret-down${"[\uFFFD/#65\uFFFD|\uFFFD/#67\uFFFD]"}:CLOSE_TAG_SPK_ICON:${"\uFFFD/#66\uFFFD"}:CLOSE_TAG_DIV:`,K=y(K);let U;U=$localize`${"\uFFFD#3\uFFFD"}:START_TAG_SPK_ICON:circle-half-tilt${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SPK_ICON: Test phase ${"\uFFFD#4\uFFFD"}:START_TAG_DIV:${"\uFFFD#5\uFFFD"}:START_TAG_SPK_ICON_1:caret-down${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SPK_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_DIV:`,U=y(U);let Fe;Fe=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let de;de=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let ue;ue=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let ce;ce=$localize`Verifications: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let ge;ge=$localize`Warnings: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Ee;Ee=$localize`Errors: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let me;me=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Oe;Oe=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Ce;Ce=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Le;Le=$localize` Deleted files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let Te;Te=$localize` Downloaded files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let Ae;Ae=$localize` Uploaded files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let Ge;Ge=$localize`Warnings: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Se;Se=$localize`Errors: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let X;return X=$localize`${"\uFFFD#3\uFFFD"}:START_TAG_SPK_ICON:warning-circle${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SPK_ICON: Verifications ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#4\uFFFD"}:START_TAG_DIV:${"\uFFFD#5\uFFFD"}:START_TAG_SPK_ICON_1:caret-down${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SPK_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_DIV:`,X=y(X),[a,e,l,m,G,oe,ae,le,_e,re,se,pe,B,h,K,U,Fe,de,ue,ce,ge,Ee,me,Oe,Ce,Le,Te,Ae,Ge,Se,X,[1,"indeterminate","primary"],[1,"log-entry"],[3,"click"],[1,"status","error"],[1,"status","warn"],[1,"status"],[1,"spacer"],[1,"action"],[1,"toggle-indicator"],[1,"log-content"],[3,"disallowToggle"],["title",""],["content",""],[1,"extra-info"],["name","details"],[1,"actions"],[1,"content"],["spk-button","",1,"small"]]},template:function(e,l){e&1&&(O(0,be,1,0,"spk-progress-bar",31),P(1,Je,16,10,"article",32,N)),e&2&&(g(l.resource.isLoading()?0:-1),i(),D(l.resource.value()))},dependencies:[ye,Re,Z,Y,k,$e,J,Ie,H],styles:["[_nghost-%COMP%]{display:block}.log-entry[_ngcontent-%COMP%]{display:flex;flex-direction:column;cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;padding:1rem;border-bottom:1px solid var(--base-level-40);background-color:var(--base-level-10);cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]:hover{background-color:var(--base-level-20)}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-30);margin:0}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-level-60)}.toggle-indicator[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:1.25rem;transition:transform 125ms linear}.toggle-indicator.open[_ngcontent-%COMP%]{transform:rotate(180deg)}details[_ngcontent-%COMP%]{display:flex;flex-direction:column}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]{cursor:pointer;display:flex;align-items:center;gap:.5rem;padding:.75rem;border-radius:var(--shape-2);background-color:var(--base-level-20)}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]:focus{outline:none}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]:hover{background-color:var(--base-level-30)}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]::marker{font-size:0}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;flex:1 0;gap:.5rem;-webkit-user-select:none;user-select:none}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:2rem;transition:transform 125ms linear}details[open][_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{transform:rotate(180deg)}details[_ngcontent-%COMP%] .content[_ngcontent-%COMP%]{padding:.75rem 1rem 0;display:flex;flex-direction:column;gap:.75rem}details[_ngcontent-%COMP%] .content[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0}details[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{margin-top:.75rem;position:relative}details[_ngcontent-%COMP%] code[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{position:absolute;top:.75rem;right:.75rem}.extra-info[_ngcontent-%COMP%]{grid-column:1/-1;display:flex;flex-direction:column;gap:1rem}.extra-info[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;margin-bottom:.75rem}.extra-info[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{white-space:pre-wrap;padding:1rem;display:block;border-radius:var(--shape-2);background-color:var(--base-level-20)}.log-content[_ngcontent-%COMP%]{padding:1rem;display:grid;grid-template-columns:1fr 1fr;gap:1rem}.status[_ngcontent-%COMP%]{display:block;width:1rem;height:1rem;background-color:var(--success-500);border-radius:50%}.status.error[_ngcontent-%COMP%]{background-color:var(--warn-500)}.status.warn[_ngcontent-%COMP%]{background-color:var(--tertiary-500)}"],changeDetection:0})};function He(o,a){o&1&&s(0,"spk-progress-bar",0)}function Qe(o,a){if(o&1&&(t(0,"section",5)(1,"code"),u(2),d(3,"json"),n()()),o&2){let e=E().$implicit;i(2),M(c(3,1,e.data))}}function Ye(o,a){if(o&1){let e=j();t(0,"article",1)(1,"header",2),R("click",function(){let m=z(e).$implicit,G=E();return V(G.toggleOpenEntry(m.id))}),t(2,"h3"),u(3),d(4,"date"),n(),t(5,"div",3)(6,"spk-icon",4),u(7,"caret-down"),n()()(),O(8,Qe,4,3,"section",5),n()}if(o&2){let e=a.$implicit,l=E();i(3),Ne("",C(4,6,e.timestamp,"medium"),": ",e.operation," ",e.path,""),i(3),S("open",e.id===l.openEntry()),i(2),g(e.id===l.openEntry()?8:-1)}}var te=class o{#e=f(Q);backupId=W.required();openEntry=L(null);pagination=L({offset:0,pagesize:100});resource=ee({request:()=>w({id:this.backupId()},this.pagination()),loader:({request:a})=>this.#e.getApiV1BackupByIdRemotelog({id:a.id,pagesize:100}).pipe($(e=>(console.log(e),e.map((l,m)=>({id:l.ID,operationId:l.OperationID,timestamp:l.Timestamp*1e3,operation:l.Operation,path:l.Path,data:typeof l.Data=="string"?JSON.parse(l.Data):null})))))});toggleOpenEntry(a){if(this.openEntry()===a){this.openEntry.set(null);return}this.openEntry.set(a)}static \u0275fac=function(e){return new(e||o)};static \u0275cmp=I({type:o,selectors:[["app-remote-log"]],inputs:{backupId:[1,"backupId"]},decls:3,vars:1,consts:[[1,"indeterminate","primary"],[1,"log-entry"],[3,"click"],[1,"actions"],[1,"toggle-indicator"],[1,"log-content"]],template:function(e,l){e&1&&(O(0,He,1,0,"spk-progress-bar",0),P(1,Ye,9,9,"article",1,N)),e&2&&(g(l.resource.isLoading()?0:-1),i(),D(l.resource.value()))},dependencies:[H,Z,k,J],styles:["[_nghost-%COMP%]{display:block}.log-entry[_ngcontent-%COMP%]{display:flex;flex-direction:column}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.5rem;padding:1rem;border-bottom:1px solid var(--base-level-40);background-color:var(--base-level-10);cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]:hover{background-color:var(--base-level-20)}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-30);margin:0;-webkit-user-select:none;user-select:none}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-level-60)}.toggle-indicator[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:1.25rem;transition:transform 125ms linear}.toggle-indicator.open[_ngcontent-%COMP%]{transform:rotate(180deg)}.log-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem}code[_ngcontent-%COMP%]{white-space:pre-wrap;padding:1rem;display:block;border-radius:var(--shape-2);background-color:var(--base-level-20)}"],changeDetection:0})};function Ze(o,a){if(o&1&&s(0,"app-general-log",7),o&2){let e=E();v("backupId",e.backupId())}}function en(o,a){if(o&1&&s(0,"app-remote-log",7),o&2){let e=E();v("backupId",e.backupId())}}var ie=class o{#e=f(Pe);backupId=ve(this.#e.params.pipe($(a=>a.id)));activeTab=L("general");static \u0275fac=function(e){return new(e||o)};static \u0275cmp=I({type:o,selectors:[["app-log"]],decls:13,vars:6,consts:()=>{let a;a=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SPK_ICON:arrow-left${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SPK_ICON: Back `;let e;e=$localize`General`;let l;return l=$localize` Destination `,[a,e,l,[1,"back"],["type","button","spk-button","","routerLink","/",1,"small"],[1,"primary"],["tab","",3,"click"],[3,"backupId"]]},template:function(e,l){e&1&&(s(0,"app-status-bar"),t(1,"section")(2,"div",3)(3,"button",4),T(4,0),s(5,"spk-icon"),A(),n()(),t(6,"spk-tabs",5)(7,"button",6),R("click",function(){return l.activeTab.set("general")}),r(8,1),n(),t(9,"button",6),R("click",function(){return l.activeTab.set("destination")}),r(10,2),n()(),O(11,Ze,1,1,"app-general-log",7)(12,en,1,1,"app-remote-log",7),n()),e&2&&(i(7),S("active",l.activeTab()==="general"),i(2),S("active",l.activeTab()==="destination"),i(2),g(l.activeTab()==="general"?11:-1),i(),g(l.activeTab()==="destination"?12:-1))},dependencies:[Me,ne,te,De,fe,k,Y],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem 1.5rem}spk-tabs[_ngcontent-%COMP%]{margin-bottom:1rem}"],changeDetection:0})};export{ie as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as xe}from"./chunk-VJJVFTK5.js";import"./chunk-TYEKJAUH.js";import{a as K}from"./chunk-AAWGVWT3.js";import{a as z}from"./chunk-QTTCN7A7.js";import{a as ke}from"./chunk-OXHL644M.js";import{b as V,d as B,e as Re,g as W,h as Fe,j as he,l as Pe,m as Ie,o as ye,p as $e,q as j,r as Ge}from"./chunk-QXNJFFEM.js";import{a as Oe}from"./chunk-XCS7POXG.js";import{a as we}from"./chunk-U4SEXW7F.js";import"./chunk-O47LGUY4.js";import{b as U}from"./chunk-PSJAIBCQ.js";import{g as be,l as ve,p as Ae,q as De,r as Le}from"./chunk-FFD5RG7J.js";import"./chunk-U5DDVNLJ.js";import"./chunk-R6C4MOOH.js";import"./chunk-X566VMXX.js";import"./chunk-BI7LIYF6.js";import{Ab as o,Bb as d,Fb as M,Hc as X,Jc as Me,K as A,La as Ce,Lb as O,Mb as R,Nb as a,Oa as s,Ob as Q,Pb as Y,Qb as Ee,R as ge,Rb as p,Sb as S,Va as E,Vb as Ne,X as m,bb as D,c as me,ca as g,da as C,ec as f,fc as b,gc as L,hb as H,jc as k,kc as w,lc as x,oc as fe,p as Te,qb as c,sb as J,vb as N,wb as y,xb as $,yb as G,zb as i}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";var F=class l{#e=m(U);#i=m(z);repeatRegisterTimer=null;state=E("unknown");claimUrl=E(null);registerUrl=E("");status=X(()=>{let e=this.state();return e==="enabled"?"Remote control is enabled but not connected":e==="connected"?"Remote control is connected":e==="registering"?"Registering machine...":e==="registeringfaulted"?"Registration failed":e==="registered"?"Registered, waiting for accept":e==="disabled"?"Remote control is configured but not enabled":e==="unknown"?"...loading...":"Remote control is not set up"});sysInfoEffect=Me(()=>{let e=this.#i.systemInfo();e&&this.registerUrl.set(e.RemoteControlRegistrationUrl??"")});#t(e){e.RegistrationUrl&&this.claimUrl.set(e.RegistrationUrl),e.IsConnected?this.state.set("connected"):e.IsEnabled?this.state.set("enabled"):e.CanEnable?this.state.set("disabled"):e.IsRegisteringFaulted?this.state.set("registeringfaulted"):e.IsRegistering?e.RegistrationUrl!=null&&e.RegistrationUrl.trim().length>0?this.state.set("registered"):this.state.set("registering"):this.state.set("inactive");let t=this.state();console.log("currentState: ",t),this.repeatRegisterTimer!==null&&(clearTimeout(this.repeatRegisterTimer),this.repeatRegisterTimer=null),t==="registering"&&(this.repeatRegisterTimer=setTimeout(()=>{this.#e.postApiV1RemotecontrolRegister({requestBody:{RegistrationUrl:""}}).subscribe({next:n=>this.#t(n),error:n=>this.#n(n)})},5e3)),(t==="enabled"||t==="registered")&&(this.repeatRegisterTimer=setTimeout(()=>{this.#e.getApiV1RemotecontrolStatus().subscribe({next:n=>this.#t(n),error:n=>this.#n(n)})},5e3)),e.IsRegistering&&e.CanEnable&&this.#e.deleteApiV1RemotecontrolRegister().subscribe({next:n=>this.#t(n)})}#n(e){this.#e.getApiV1RemotecontrolStatus().subscribe({next:t=>this.#t(t)})}refreshRemoteControlStatus(){this.#e.getApiV1RemotecontrolStatus().subscribe({next:e=>this.#t(e),error:e=>this.#n(e)})}beginRemoteRegistration(){this.state.set("registering"),this.#e.postApiV1RemotecontrolRegister({requestBody:{RegistrationUrl:this.registerUrl()}}).subscribe({next:e=>this.#t(e),error:e=>this.#n(e)})}cancelRemoteRegistration(){this.#e.deleteApiV1RemotecontrolRegister().subscribe({next:e=>this.#t(e),error:e=>this.#n(e)})}enableRemoteControl(){this.#e.postApiV1RemotecontrolEnable().subscribe({next:e=>this.#t(e),error:e=>this.#n(e)})}disableRemoteControl(){this.#e.postApiV1RemotecontrolDisable().subscribe({next:e=>this.#t(e),error:e=>this.#n(e)})}deleteRemoteControl(){let e=this;confirm("Are you sure you want to delete the remote control registration?")&&e.#e.deleteApiV1RemotecontrolRegistration().subscribe({next:t=>e.#t(t),error:t=>e.#n(t)})}static \u0275fac=function(t){return new(t||l)};static \u0275prov=ge({token:l,factory:l.\u0275fac,providedIn:"root"})};function We(l,e){if(l&1){let t=M();i(0,"spk-form-field",10)(1,"input",11),x("ngModelChange",function(r){g(t);let u=S(2);return w(u.registerUrl,r)||(u.registerUrl=r),C(r)}),o()(),i(2,"button",12),p("click",function(){g(t);let r=S(2);return C(r.register())}),a(3,0),o()}if(l&2){let t=S(2);s(),k("ngModel",t.registerUrl)}}function je(l,e){if(l&1&&(i(0,"div",8)(1,"label"),a(2,1),o(),i(3,"a",13),f(4),o()()),l&2){let t=S(2);s(3),Ne("href",t.claimUrl(),Ce),s(),b(t.claimUrl())}}function Ke(l,e){l&1&&(i(0,"div",8)(1,"label"),a(2,2),o()())}function qe(l,e){if(l&1){let t=M();i(0,"button",12),p("click",function(){g(t);let r=S(2);return C(r.cancel())}),a(1,3),o()}}function He(l,e){if(l&1){let t=M();i(0,"button",12),p("click",function(){g(t);let r=S(2);return C(r.disable())}),a(1,4),o()}}function Je(l,e){if(l&1){let t=M();i(0,"button",12),p("click",function(){g(t);let r=S(2);return C(r.enable())}),a(1,5),o(),i(2,"button",14),p("click",function(){g(t);let r=S(2);return C(r.delete())}),a(3,6),o()}}function Qe(l,e){if(l&1&&(i(0,"div",7),H(1,We,4,1)(2,je,5,2,"div",8)(3,Ke,3,0,"div",8)(4,qe,2,0,"button",9)(5,He,2,0,"button",9)(6,Je,4,0),o()),l&2){let t=S();s(),N(t.state()==="inactive"?1:-1),s(),N(t.state()==="registered"?2:-1),s(),N(t.state()==="registering"?3:-1),s(),N(t.state()==="registering"||t.state()==="registeringfaulted"||t.state()==="registered"?4:-1),s(),N(t.state()==="connected"||t.state()==="enabled"?5:-1),s(),N(t.state()==="disabled"?6:-1)}}var q=class l{#e=m(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(t){return new(t||l)};static \u0275cmp=D({type:l,selectors:[["app-remote-control"]],decls:1,vars:1,consts:()=>{let e;e=$localize`Register for remote control`;let t;t=$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 u;u=$localize`Disable remote control`;let P;P=$localize`Enable remote control`;let I;return I=$localize`Delete remote control setup`,[e,t,n,r,u,P,I,[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","warn",3,"click"]]},template:function(t,n){t&1&&H(0,Qe,7,6,"div",7),t&2&&N(n.state()!=="unknown"?0:-1)},dependencies:[j,V,B,W,ve],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 Ye=()=>({standalone:!0});function Ze(l,e){if(l&1&&(i(0,"spk-option",32),f(1),o()),l&2){let t=e.$implicit;c("value",t),s(),b(t)}}function et(l,e){if(l&1){let t=M();i(0,"spk-option",51),p("click",function(){let r=g(t).$implicit,u=S();return C(u.pauseSettings.controls.timeType.setValue(r.value))}),f(1),o()}if(l&2){let t=e.$implicit;c("value",t.value),s(),L(" ",t.label," ")}}function tt(l,e){if(l&1&&(i(0,"spk-option",32),f(1),o()),l&2){let t=e.$implicit;c("value",t.value),s(),L(" ",t.label," ")}}function nt(l,e){if(l&1&&(i(0,"spk-option",32),f(1),o()),l&2){let t=e.$implicit;c("value",t.value),s(),L(" ",t.label," ")}}var h=new $e,Ue=[{value:"s",label:$localize`Seconds`},{value:"m",label:$localize`Minutes`},{value:"h",label:$localize`Hours`}],ze=[{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`}],Z=class l{#e=m(ke);#i=m(z);#t=m(U);#n=m(F);#o=m(Oe);#r=this.#o.getItem("locale")??"en-US";sysinfo=this.#i.systemInfo;isDarkMode=this.#e.isDarkMode;editAs=E("list");langCtrl=E(this.#r);remoteControlStatus=this.#n.status;settingsForm=h.group({pauseSettings:h.group({time:h.control(0),timeType:h.control("s")}),usageStatistics:h.control(""),updateChannel:h.control("")});get pauseSettings(){return this.settingsForm.controls.pauseSettings}languageOptions=X(()=>{let e=this.langCtrl();return e?K.filter(t=>t.label.toLowerCase().includes(e.toLowerCase())):K});usageStatisticsOptions=E(ze);timeTypeOptions=E(Ue);timeOptions=xe([this.pauseSettings.controls.timeType.valueChanges.pipe(A("s")),this.pauseSettings.controls.time.valueChanges.pipe(A(null))],me(Te(([e,t])=>{let n=this.#l(e);return t!==null?n.filter(r=>r.toString().includes(t.toString())):n}),A([])));#l(e){let t=e==="h"?25:61;return new Array(t).fill(0).map((n,r)=>r)}ngOnInit(){this.getServerSettings()}saveLocale(e){this.#o.setItem("locale",e),window.location.reload()}submit(){let e=`${this.pauseSettings.controls.time.value}${this.pauseSettings.controls.timeType.value}`;this.#t.patchApiV1Serversettings({requestBody:{"usage-reporter-level":this.settingsForm.controls.usageStatistics.value,"startup-delay":e==="0s"?"":e,"update-channel":this.settingsForm.controls.updateChannel.value}}).subscribe({next:t=>{console.log("res",t)},error:t=>{console.error("err",t)}})}getServerSettings(){return this.#t.getApiV1Serversettings().subscribe({next:e=>{let t=e["startup-delay"],n=t.slice(-1),r=t.slice(0,-1),u=["s","m","h"];this.settingsForm.patchValue({pauseSettings:{time:parseInt(r==""?"0":r),timeType:u.includes(n)?n:"s"},usageStatistics:e["usage-reporter-level"],updateChannel:e["update-channel"]})}})}languageDisplay(){let e=this;return()=>{let t=e.langCtrl();return t?K.find(n=>n.value===t)?.label??null:null}}typeDisplay(){let e=this;return()=>{let t=e.settingsForm.value.pauseSettings?.timeType;return t==null?null:Ue.find(n=>n.value===t)?.label??null}}usageDisplay(){let e=this;return()=>{let t=e.settingsForm.value.usageStatistics;return t==null?null:ze.find(n=>n.value===t)?.label??null}}setDarkMode(){this.#e.setDarkMode()}setLightMode(){this.#e.setLightMode()}static \u0275fac=function(t){return new(t||l)};static \u0275cmp=D({type:l,selectors:[["app-settings"]],decls:106,vars:18,consts:()=>{let e;e=$localize`Settings`;let t;t=$localize`Configure your backup settings.`;let n;n=$localize` Save changes `;let r;r=$localize`Remote access control`;let u;u=$localize`Pause after startup or hibernation`;let P;P=$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 I;I=$localize`Color theme`;let T;T=$localize`Customize your application theme`;let ee;ee=$localize`Language`;let te;te=$localize`Select a language for the platform`;let ne;ne=$localize`Update channel`;let ie;ie=$localize`Update channel selection is not implemented yet.`;let oe;oe=$localize` Default (${"\uFFFD0\uFFFD"}:INTERPOLATION:) ${"\uFFFD#65\uFFFD\uFFFD/#65\uFFFD"}:TAG_INPUT:`;let re;re=$localize`Same as the base install version: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let le;le=$localize` Stable ${"\uFFFD#71\uFFFD\uFFFD/#71\uFFFD"}:TAG_INPUT:`;let se;se=$localize`Official releases`;let ae;ae=$localize` Beta ${"\uFFFD#77\uFFFD\uFFFD/#77\uFFFD"}:TAG_INPUT:`;let _e;_e=$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 ue;ue=$localize` Experimental ${"\uFFFD#83\uFFFD\uFFFD/#83\uFFFD"}:TAG_INPUT:`;let pe;pe=$localize`Specific builds for developers only. Not for use with important data.`;let ce;ce=$localize` Canary ${"\uFFFD#89\uFFFD\uFFFD/#89\uFFFD"}:TAG_INPUT:`;let de;de=$localize`Individual builds for developers only. Not for use with important data.`;let Se;Se=$localize`Usage statistics`;let v;return v=$localize` Usage reports help us improve the user experience and evaluate impact of new features. We use them to generate ${"\uFFFD#98\uFFFD"}:START_LINK:public usage statistics.${"\uFFFD/#98\uFFFD"}:CLOSE_LINK:${"[\uFFFD#99\uFFFD\uFFFD/#99\uFFFD|\uFFFD#100\uFFFD\uFFFD/#100\uFFFD]"}:LINE_BREAK:${"[\uFFFD#99\uFFFD\uFFFD/#99\uFFFD|\uFFFD#100\uFFFD\uFFFD/#100\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=Ee(v),[e,t,n,r,u,P,I,T,ee,te,ne,ie,oe,re,le,se,ae,_e,ue,pe,ce,de,Se,v,[1,"content",3,"submit","formGroup"],[1,"title"],["type","submit","spk-button","",1,"raised","primary",3,"disabled"],[1,"left"],[1,"right"],["formGroupName","pauseSettings",1,"field-row"],[3,"hideClearButton"],["type","search","formControlName","time"],[3,"value"],[3,"displayFn","hideClearButton"],["type","text","formControlName","timeType"],[1,"themes"],["src","assets/images/light-theme.png","alt","light theme",3,"click"],["src","assets/images/dark-theme.png","alt","dark theme",3,"click"],[3,"change","displayFn","hideClearButton"],["type","search",3,"ngModelChange","ngModel","ngModelOptions"],[1,"right","radios"],[1,"radio-option",3,"click"],[1,"outlined","primary"],["type","radio","name","updateChannel","value","","formControlName","updateChannel"],["type","radio","name","updateChannel","value","stable","formControlName","updateChannel"],["type","radio","name","updateChannel","value","beta","formControlName","updateChannel"],["type","radio","name","updateChannel","value","experimental","formControlName","updateChannel"],["type","radio","name","updateChannel","value","canary","formControlName","updateChannel"],["href","#"],[3,"displayFn"],["type","text","formControlName","usageStatistics"],[3,"click","value"]]},template:function(t,n){if(t&1&&(d(0,"app-status-bar"),i(1,"form",24),p("submit",function(){return n.submit()}),i(2,"header")(3,"div",25)(4,"h2"),a(5,0),o(),i(6,"p"),a(7,1),o()(),i(8,"button",26),a(9,2),o()(),i(10,"section")(11,"div",27)(12,"h3"),a(13,3),o(),i(14,"p"),f(15),o()(),i(16,"div",28),d(17,"app-remote-control"),o()(),i(18,"section")(19,"div",27)(20,"h3"),a(21,4),o(),i(22,"p"),a(23,5),o()(),i(24,"div",28)(25,"div",29)(26,"spk-select",30),d(27,"input",31),$(28,Ze,2,2,"spk-option",32,y),o(),i(30,"spk-select",33),d(31,"input",34),$(32,et,2,2,"spk-option",32,y),o()()()(),i(34,"section")(35,"div",27)(36,"h3"),a(37,6),o(),i(38,"p"),a(39,7),o()(),i(40,"div",28)(41,"div",35)(42,"img",36),p("click",function(){return n.setLightMode()}),o(),i(43,"img",37),p("click",function(){return n.setDarkMode()}),o()()()(),i(44,"section")(45,"div",27)(46,"h3"),a(47,8),o(),i(48,"p"),a(49,9),o()(),i(50,"div",28)(51,"spk-select",38),p("change",function(u){return n.saveLocale(u)}),i(52,"input",39),x("ngModelChange",function(u){return w(n.langCtrl,u)||(n.langCtrl=u),u}),o(),$(53,tt,2,2,"spk-option",32,y),o()()(),i(55,"section")(56,"div",27)(57,"h3"),a(58,10),o(),i(59,"p"),a(60,11),o()(),i(61,"div",40)(62,"div",41),p("click",function(){return n.settingsForm.controls.updateChannel.setValue("")}),i(63,"spk-radio",42),O(64,12),d(65,"input",43),R(),o(),i(66,"p"),a(67,13),o()(),i(68,"div",41),p("click",function(){return n.settingsForm.controls.updateChannel.setValue("stable")}),i(69,"spk-radio",42),O(70,14),d(71,"input",44),R(),o(),i(72,"p"),a(73,15),o()(),i(74,"div",41),p("click",function(){return n.settingsForm.controls.updateChannel.setValue("beta")}),i(75,"spk-radio",42),O(76,16),d(77,"input",45),R(),o(),i(78,"p"),a(79,17),o()(),i(80,"div",41),p("click",function(){return n.settingsForm.controls.updateChannel.setValue("experimental")}),i(81,"spk-radio",42),O(82,18),d(83,"input",46),R(),o(),i(84,"p"),a(85,19),o()(),i(86,"div",41),p("click",function(){return n.settingsForm.controls.updateChannel.setValue("canary")}),i(87,"spk-radio",42),O(88,20),d(89,"input",47),R(),o(),i(90,"p"),a(91,21),o()()()(),i(92,"section")(93,"div",27)(94,"h3"),a(95,22),o(),i(96,"p"),O(97,23),d(98,"a",48)(99,"br")(100,"br"),R(),o()(),i(101,"div",28)(102,"spk-select",49),d(103,"input",50),$(104,nt,2,2,"spk-option",32,y),o()()()()),t&2){let r,u;s(),c("formGroup",n.settingsForm),s(7),c("disabled",n.settingsForm.untouched),s(7),b(n.remoteControlStatus()),s(11),c("hideClearButton",!0),s(2),G(n.timeOptions()),s(2),c("displayFn",n.typeDisplay())("hideClearButton",!0),s(2),G(n.timeTypeOptions()),s(10),J("active",!n.isDarkMode()),s(),J("active",n.isDarkMode()),s(8),c("displayFn",n.languageDisplay())("hideClearButton",!0),s(),k("ngModel",n.langCtrl),c("ngModelOptions",fe(17,Ye)),s(),G(n.languageOptions()),s(12),Q((r=n.sysinfo())==null?null:r.DefaultUpdateChannel),Y(64),s(2),Q((u=n.sysinfo())==null?null:u.ServerVersionType),Y(67),s(35),c("displayFn",n.usageDisplay()),s(2),G(n.usageStatisticsOptions())}},dependencies:[j,Fe,V,he,B,Re,W,Ge,Pe,ye,Ie,we,q,De,be,Ae,Le],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%}.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}"],changeDetection:0})};export{Z as default};
|
|
1
|
+
import{a as xe}from"./chunk-VJJVFTK5.js";import"./chunk-TYEKJAUH.js";import{a as K}from"./chunk-AAWGVWT3.js";import{a as z}from"./chunk-QTTCN7A7.js";import{a as ke}from"./chunk-OXHL644M.js";import{a as Oe}from"./chunk-XCS7POXG.js";import{a as we}from"./chunk-JFN26EE2.js";import"./chunk-O47LGUY4.js";import{b as V,d as B,e as Re,g as W,h as Fe,j as he,l as Pe,m as Ie,o as ye,p as $e,q as j,r as Ge}from"./chunk-QXNJFFEM.js";import{b as U}from"./chunk-PSJAIBCQ.js";import{g as be,l as ve,p as Ae,q as De,r as Le}from"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import"./chunk-R6C4MOOH.js";import"./chunk-X566VMXX.js";import"./chunk-BI7LIYF6.js";import{Ab as o,Bb as d,Fb as M,Hc as X,Jc as Me,K as A,La as Ce,Lb as O,Mb as R,Nb as a,Oa as s,Ob as Q,Pb as Y,Qb as Ee,R as ge,Rb as p,Sb as S,Va as E,Vb as Ne,X as m,bb as D,c as me,ca as g,da as C,ec as f,fc as b,gc as L,hb as H,jc as k,kc as w,lc as x,oc as fe,p as Te,qb as c,sb as J,vb as N,wb as y,xb as $,yb as G,zb as i}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";var F=class l{#e=m(U);#i=m(z);repeatRegisterTimer=null;state=E("unknown");claimUrl=E(null);registerUrl=E("");status=X(()=>{let e=this.state();return e==="enabled"?"Remote control is enabled but not connected":e==="connected"?"Remote control is connected":e==="registering"?"Registering machine...":e==="registeringfaulted"?"Registration failed":e==="registered"?"Registered, waiting for accept":e==="disabled"?"Remote control is configured but not enabled":e==="unknown"?"...loading...":"Remote control is not set up"});sysInfoEffect=Me(()=>{let e=this.#i.systemInfo();e&&this.registerUrl.set(e.RemoteControlRegistrationUrl??"")});#t(e){e.RegistrationUrl&&this.claimUrl.set(e.RegistrationUrl),e.IsConnected?this.state.set("connected"):e.IsEnabled?this.state.set("enabled"):e.CanEnable?this.state.set("disabled"):e.IsRegisteringFaulted?this.state.set("registeringfaulted"):e.IsRegistering?e.RegistrationUrl!=null&&e.RegistrationUrl.trim().length>0?this.state.set("registered"):this.state.set("registering"):this.state.set("inactive");let t=this.state();console.log("currentState: ",t),this.repeatRegisterTimer!==null&&(clearTimeout(this.repeatRegisterTimer),this.repeatRegisterTimer=null),t==="registering"&&(this.repeatRegisterTimer=setTimeout(()=>{this.#e.postApiV1RemotecontrolRegister({requestBody:{RegistrationUrl:""}}).subscribe({next:n=>this.#t(n),error:n=>this.#n(n)})},5e3)),(t==="enabled"||t==="registered")&&(this.repeatRegisterTimer=setTimeout(()=>{this.#e.getApiV1RemotecontrolStatus().subscribe({next:n=>this.#t(n),error:n=>this.#n(n)})},5e3)),e.IsRegistering&&e.CanEnable&&this.#e.deleteApiV1RemotecontrolRegister().subscribe({next:n=>this.#t(n)})}#n(e){this.#e.getApiV1RemotecontrolStatus().subscribe({next:t=>this.#t(t)})}refreshRemoteControlStatus(){this.#e.getApiV1RemotecontrolStatus().subscribe({next:e=>this.#t(e),error:e=>this.#n(e)})}beginRemoteRegistration(){this.state.set("registering"),this.#e.postApiV1RemotecontrolRegister({requestBody:{RegistrationUrl:this.registerUrl()}}).subscribe({next:e=>this.#t(e),error:e=>this.#n(e)})}cancelRemoteRegistration(){this.#e.deleteApiV1RemotecontrolRegister().subscribe({next:e=>this.#t(e),error:e=>this.#n(e)})}enableRemoteControl(){this.#e.postApiV1RemotecontrolEnable().subscribe({next:e=>this.#t(e),error:e=>this.#n(e)})}disableRemoteControl(){this.#e.postApiV1RemotecontrolDisable().subscribe({next:e=>this.#t(e),error:e=>this.#n(e)})}deleteRemoteControl(){let e=this;confirm("Are you sure you want to delete the remote control registration?")&&e.#e.deleteApiV1RemotecontrolRegistration().subscribe({next:t=>e.#t(t),error:t=>e.#n(t)})}static \u0275fac=function(t){return new(t||l)};static \u0275prov=ge({token:l,factory:l.\u0275fac,providedIn:"root"})};function We(l,e){if(l&1){let t=M();i(0,"spk-form-field",10)(1,"input",11),x("ngModelChange",function(r){g(t);let u=S(2);return w(u.registerUrl,r)||(u.registerUrl=r),C(r)}),o()(),i(2,"button",12),p("click",function(){g(t);let r=S(2);return C(r.register())}),a(3,0),o()}if(l&2){let t=S(2);s(),k("ngModel",t.registerUrl)}}function je(l,e){if(l&1&&(i(0,"div",8)(1,"label"),a(2,1),o(),i(3,"a",13),f(4),o()()),l&2){let t=S(2);s(3),Ne("href",t.claimUrl(),Ce),s(),b(t.claimUrl())}}function Ke(l,e){l&1&&(i(0,"div",8)(1,"label"),a(2,2),o()())}function qe(l,e){if(l&1){let t=M();i(0,"button",12),p("click",function(){g(t);let r=S(2);return C(r.cancel())}),a(1,3),o()}}function He(l,e){if(l&1){let t=M();i(0,"button",12),p("click",function(){g(t);let r=S(2);return C(r.disable())}),a(1,4),o()}}function Je(l,e){if(l&1){let t=M();i(0,"button",12),p("click",function(){g(t);let r=S(2);return C(r.enable())}),a(1,5),o(),i(2,"button",14),p("click",function(){g(t);let r=S(2);return C(r.delete())}),a(3,6),o()}}function Qe(l,e){if(l&1&&(i(0,"div",7),H(1,We,4,1)(2,je,5,2,"div",8)(3,Ke,3,0,"div",8)(4,qe,2,0,"button",9)(5,He,2,0,"button",9)(6,Je,4,0),o()),l&2){let t=S();s(),N(t.state()==="inactive"?1:-1),s(),N(t.state()==="registered"?2:-1),s(),N(t.state()==="registering"?3:-1),s(),N(t.state()==="registering"||t.state()==="registeringfaulted"||t.state()==="registered"?4:-1),s(),N(t.state()==="connected"||t.state()==="enabled"?5:-1),s(),N(t.state()==="disabled"?6:-1)}}var q=class l{#e=m(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(t){return new(t||l)};static \u0275cmp=D({type:l,selectors:[["app-remote-control"]],decls:1,vars:1,consts:()=>{let e;e=$localize`Register for remote control`;let t;t=$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 u;u=$localize`Disable remote control`;let P;P=$localize`Enable remote control`;let I;return I=$localize`Delete remote control setup`,[e,t,n,r,u,P,I,[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","warn",3,"click"]]},template:function(t,n){t&1&&H(0,Qe,7,6,"div",7),t&2&&N(n.state()!=="unknown"?0:-1)},dependencies:[j,V,B,W,ve],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 Ye=()=>({standalone:!0});function Ze(l,e){if(l&1&&(i(0,"spk-option",32),f(1),o()),l&2){let t=e.$implicit;c("value",t),s(),b(t)}}function et(l,e){if(l&1){let t=M();i(0,"spk-option",51),p("click",function(){let r=g(t).$implicit,u=S();return C(u.pauseSettings.controls.timeType.setValue(r.value))}),f(1),o()}if(l&2){let t=e.$implicit;c("value",t.value),s(),L(" ",t.label," ")}}function tt(l,e){if(l&1&&(i(0,"spk-option",32),f(1),o()),l&2){let t=e.$implicit;c("value",t.value),s(),L(" ",t.label," ")}}function nt(l,e){if(l&1&&(i(0,"spk-option",32),f(1),o()),l&2){let t=e.$implicit;c("value",t.value),s(),L(" ",t.label," ")}}var h=new $e,Ue=[{value:"s",label:$localize`Seconds`},{value:"m",label:$localize`Minutes`},{value:"h",label:$localize`Hours`}],ze=[{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`}],Z=class l{#e=m(ke);#i=m(z);#t=m(U);#n=m(F);#o=m(Oe);#r=this.#o.getItem("locale")??"en-US";sysinfo=this.#i.systemInfo;isDarkMode=this.#e.isDarkMode;editAs=E("list");langCtrl=E(this.#r);remoteControlStatus=this.#n.status;settingsForm=h.group({pauseSettings:h.group({time:h.control(0),timeType:h.control("s")}),usageStatistics:h.control(""),updateChannel:h.control("")});get pauseSettings(){return this.settingsForm.controls.pauseSettings}languageOptions=X(()=>{let e=this.langCtrl();return e?K.filter(t=>t.label.toLowerCase().includes(e.toLowerCase())):K});usageStatisticsOptions=E(ze);timeTypeOptions=E(Ue);timeOptions=xe([this.pauseSettings.controls.timeType.valueChanges.pipe(A("s")),this.pauseSettings.controls.time.valueChanges.pipe(A(null))],me(Te(([e,t])=>{let n=this.#l(e);return t!==null?n.filter(r=>r.toString().includes(t.toString())):n}),A([])));#l(e){let t=e==="h"?25:61;return new Array(t).fill(0).map((n,r)=>r)}ngOnInit(){this.getServerSettings()}saveLocale(e){this.#o.setItem("locale",e),window.location.reload()}submit(){let e=`${this.pauseSettings.controls.time.value}${this.pauseSettings.controls.timeType.value}`;this.#t.patchApiV1Serversettings({requestBody:{"usage-reporter-level":this.settingsForm.controls.usageStatistics.value,"startup-delay":e==="0s"?"":e,"update-channel":this.settingsForm.controls.updateChannel.value}}).subscribe({next:t=>{console.log("res",t)},error:t=>{console.error("err",t)}})}getServerSettings(){return this.#t.getApiV1Serversettings().subscribe({next:e=>{let t=e["startup-delay"],n=t.slice(-1),r=t.slice(0,-1),u=["s","m","h"];this.settingsForm.patchValue({pauseSettings:{time:parseInt(r==""?"0":r),timeType:u.includes(n)?n:"s"},usageStatistics:e["usage-reporter-level"],updateChannel:e["update-channel"]})}})}languageDisplay(){let e=this;return()=>{let t=e.langCtrl();return t?K.find(n=>n.value===t)?.label??null:null}}typeDisplay(){let e=this;return()=>{let t=e.settingsForm.value.pauseSettings?.timeType;return t==null?null:Ue.find(n=>n.value===t)?.label??null}}usageDisplay(){let e=this;return()=>{let t=e.settingsForm.value.usageStatistics;return t==null?null:ze.find(n=>n.value===t)?.label??null}}setDarkMode(){this.#e.setDarkMode()}setLightMode(){this.#e.setLightMode()}static \u0275fac=function(t){return new(t||l)};static \u0275cmp=D({type:l,selectors:[["app-settings"]],decls:106,vars:18,consts:()=>{let e;e=$localize`Settings`;let t;t=$localize`Configure your backup settings.`;let n;n=$localize` Save changes `;let r;r=$localize`Remote access control`;let u;u=$localize`Pause after startup or hibernation`;let P;P=$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 I;I=$localize`Color theme`;let T;T=$localize`Customize your application theme`;let ee;ee=$localize`Language`;let te;te=$localize`Select a language for the platform`;let ne;ne=$localize`Update channel`;let ie;ie=$localize`Update channel selection is not implemented yet.`;let oe;oe=$localize` Default (${"\uFFFD0\uFFFD"}:INTERPOLATION:) ${"\uFFFD#65\uFFFD\uFFFD/#65\uFFFD"}:TAG_INPUT:`;let re;re=$localize`Same as the base install version: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let le;le=$localize` Stable ${"\uFFFD#71\uFFFD\uFFFD/#71\uFFFD"}:TAG_INPUT:`;let se;se=$localize`Official releases`;let ae;ae=$localize` Beta ${"\uFFFD#77\uFFFD\uFFFD/#77\uFFFD"}:TAG_INPUT:`;let _e;_e=$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 ue;ue=$localize` Experimental ${"\uFFFD#83\uFFFD\uFFFD/#83\uFFFD"}:TAG_INPUT:`;let pe;pe=$localize`Specific builds for developers only. Not for use with important data.`;let ce;ce=$localize` Canary ${"\uFFFD#89\uFFFD\uFFFD/#89\uFFFD"}:TAG_INPUT:`;let de;de=$localize`Individual builds for developers only. Not for use with important data.`;let Se;Se=$localize`Usage statistics`;let v;return v=$localize` Usage reports help us improve the user experience and evaluate impact of new features. We use them to generate ${"\uFFFD#98\uFFFD"}:START_LINK:public usage statistics.${"\uFFFD/#98\uFFFD"}:CLOSE_LINK:${"[\uFFFD#99\uFFFD\uFFFD/#99\uFFFD|\uFFFD#100\uFFFD\uFFFD/#100\uFFFD]"}:LINE_BREAK:${"[\uFFFD#99\uFFFD\uFFFD/#99\uFFFD|\uFFFD#100\uFFFD\uFFFD/#100\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=Ee(v),[e,t,n,r,u,P,I,T,ee,te,ne,ie,oe,re,le,se,ae,_e,ue,pe,ce,de,Se,v,[1,"content",3,"submit","formGroup"],[1,"title"],["type","submit","spk-button","",1,"raised","primary",3,"disabled"],[1,"left"],[1,"right"],["formGroupName","pauseSettings",1,"field-row"],[3,"hideClearButton"],["type","search","formControlName","time"],[3,"value"],[3,"displayFn","hideClearButton"],["type","text","formControlName","timeType"],[1,"themes"],["src","assets/images/light-theme.png","alt","light theme",3,"click"],["src","assets/images/dark-theme.png","alt","dark theme",3,"click"],[3,"change","displayFn","hideClearButton"],["type","search",3,"ngModelChange","ngModel","ngModelOptions"],[1,"right","radios"],[1,"radio-option",3,"click"],[1,"outlined","primary"],["type","radio","name","updateChannel","value","","formControlName","updateChannel"],["type","radio","name","updateChannel","value","stable","formControlName","updateChannel"],["type","radio","name","updateChannel","value","beta","formControlName","updateChannel"],["type","radio","name","updateChannel","value","experimental","formControlName","updateChannel"],["type","radio","name","updateChannel","value","canary","formControlName","updateChannel"],["href","#"],[3,"displayFn"],["type","text","formControlName","usageStatistics"],[3,"click","value"]]},template:function(t,n){if(t&1&&(d(0,"app-status-bar"),i(1,"form",24),p("submit",function(){return n.submit()}),i(2,"header")(3,"div",25)(4,"h2"),a(5,0),o(),i(6,"p"),a(7,1),o()(),i(8,"button",26),a(9,2),o()(),i(10,"section")(11,"div",27)(12,"h3"),a(13,3),o(),i(14,"p"),f(15),o()(),i(16,"div",28),d(17,"app-remote-control"),o()(),i(18,"section")(19,"div",27)(20,"h3"),a(21,4),o(),i(22,"p"),a(23,5),o()(),i(24,"div",28)(25,"div",29)(26,"spk-select",30),d(27,"input",31),$(28,Ze,2,2,"spk-option",32,y),o(),i(30,"spk-select",33),d(31,"input",34),$(32,et,2,2,"spk-option",32,y),o()()()(),i(34,"section")(35,"div",27)(36,"h3"),a(37,6),o(),i(38,"p"),a(39,7),o()(),i(40,"div",28)(41,"div",35)(42,"img",36),p("click",function(){return n.setLightMode()}),o(),i(43,"img",37),p("click",function(){return n.setDarkMode()}),o()()()(),i(44,"section")(45,"div",27)(46,"h3"),a(47,8),o(),i(48,"p"),a(49,9),o()(),i(50,"div",28)(51,"spk-select",38),p("change",function(u){return n.saveLocale(u)}),i(52,"input",39),x("ngModelChange",function(u){return w(n.langCtrl,u)||(n.langCtrl=u),u}),o(),$(53,tt,2,2,"spk-option",32,y),o()()(),i(55,"section")(56,"div",27)(57,"h3"),a(58,10),o(),i(59,"p"),a(60,11),o()(),i(61,"div",40)(62,"div",41),p("click",function(){return n.settingsForm.controls.updateChannel.setValue("")}),i(63,"spk-radio",42),O(64,12),d(65,"input",43),R(),o(),i(66,"p"),a(67,13),o()(),i(68,"div",41),p("click",function(){return n.settingsForm.controls.updateChannel.setValue("stable")}),i(69,"spk-radio",42),O(70,14),d(71,"input",44),R(),o(),i(72,"p"),a(73,15),o()(),i(74,"div",41),p("click",function(){return n.settingsForm.controls.updateChannel.setValue("beta")}),i(75,"spk-radio",42),O(76,16),d(77,"input",45),R(),o(),i(78,"p"),a(79,17),o()(),i(80,"div",41),p("click",function(){return n.settingsForm.controls.updateChannel.setValue("experimental")}),i(81,"spk-radio",42),O(82,18),d(83,"input",46),R(),o(),i(84,"p"),a(85,19),o()(),i(86,"div",41),p("click",function(){return n.settingsForm.controls.updateChannel.setValue("canary")}),i(87,"spk-radio",42),O(88,20),d(89,"input",47),R(),o(),i(90,"p"),a(91,21),o()()()(),i(92,"section")(93,"div",27)(94,"h3"),a(95,22),o(),i(96,"p"),O(97,23),d(98,"a",48)(99,"br")(100,"br"),R(),o()(),i(101,"div",28)(102,"spk-select",49),d(103,"input",50),$(104,nt,2,2,"spk-option",32,y),o()()()()),t&2){let r,u;s(),c("formGroup",n.settingsForm),s(7),c("disabled",n.settingsForm.untouched),s(7),b(n.remoteControlStatus()),s(11),c("hideClearButton",!0),s(2),G(n.timeOptions()),s(2),c("displayFn",n.typeDisplay())("hideClearButton",!0),s(2),G(n.timeTypeOptions()),s(10),J("active",!n.isDarkMode()),s(),J("active",n.isDarkMode()),s(8),c("displayFn",n.languageDisplay())("hideClearButton",!0),s(),k("ngModel",n.langCtrl),c("ngModelOptions",fe(17,Ye)),s(),G(n.languageOptions()),s(12),Q((r=n.sysinfo())==null?null:r.DefaultUpdateChannel),Y(64),s(2),Q((u=n.sysinfo())==null?null:u.ServerVersionType),Y(67),s(35),c("displayFn",n.usageDisplay()),s(2),G(n.usageStatisticsOptions())}},dependencies:[j,Fe,V,he,B,Re,W,Ge,Pe,ye,Ie,we,q,De,be,Ae,Le],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%}.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}"],changeDetection:0})};export{Z as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{g as a,h as b,i as c}from"./chunk-
|
|
1
|
+
import{g as a,h as b,i as c}from"./chunk-TOUGWZ56.js";import"./chunk-TLM42G2X.js";import"./chunk-NZ5QQIUJ.js";import"./chunk-DNHLTHLR.js";import"./chunk-TYEKJAUH.js";import"./chunk-QTTCN7A7.js";import"./chunk-QXNJFFEM.js";import"./chunk-PSJAIBCQ.js";import"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import"./chunk-X566VMXX.js";import"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";export{b as NONE_OPTION,a as createGeneralForm,c as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as ke}from"./chunk-JFN26EE2.js";import{a as Te}from"./chunk-O47LGUY4.js";import"./chunk-QXNJFFEM.js";import{b as Se}from"./chunk-PSJAIBCQ.js";import{d as R}from"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import{a as H,g as b,h as Me,j as Ee,k as ge,n as Fe,o as Ce}from"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import"./chunk-R6C4MOOH.js";import"./chunk-X566VMXX.js";import"./chunk-BI7LIYF6.js";import{Ab as i,Bb as r,Cb as F,Db as C,Fb as pe,Lb as s,Mb as u,Nb as p,Oa as c,Ob as se,Pb as ue,Rb as P,Sb as d,X as I,bb as ie,ca as k,da as O,ec as S,gc as N,hb as g,nb as _e,ob as ae,oc as D,pc as T,qb as E,sb as A,sc as $,tc as f,uc as de,vb as m,wb as le,xb as ce,yb as re,zb as o}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";var Oe=()=>[R,b,H,Ee,ge,Fe,import("./chunk-VCPYNGOK.js").then(e=>e.DatePipe),import("./chunk-GGTAHZ6F.js").then(e=>e.DurationFormatPipe),import("./chunk-PJIG2CDP.js").then(e=>e.BytesPipe)],me=()=>["/add-backup"],Pe=()=>["/restore"],Ne=e=>["/backup",e],$e=e=>["/restore",e],fe=e=>["/backup",e,"export"],Ie=e=>["/backup",e,"database"],Ae=e=>["/backup",e,"commandline"],De=e=>["/backup",e,"log"];function Re(e,_){if(e&1&&(S(0," - "),F(1),p(2,21),C(),S(3),$(4,"durationFormat")),e&2){let t=d().$implicit;c(3),N(" ",f(4,1,t.Backup==null||t.Backup.Metadata==null?null:t.Backup.Metadata.LastBackupDuration)," ")}}function He(e,_){e&1&&(F(0),p(1,22),C())}function be(e,_){if(e&1&&(S(0),$(1,"bytes")),e&2){let t=d().$implicit;N(" ",f(1,1,t.Backup==null||t.Backup.Metadata==null?null:t.Backup.Metadata.SourceFilesSize)," ")}}function xe(e,_){e&1&&(F(0),p(1,23),C())}function Be(e,_){if(e&1&&(S(0),$(1,"bytes")),e&2){let t=d().$implicit;N(" ",f(1,1,t.Backup==null||t.Backup.Metadata==null?null:t.Backup.Metadata.TargetFilesSize)," ")}}function Le(e,_){e&1&&(F(0),p(1,24),C())}function ye(e,_){if(e&1&&(o(0,"spk-chip",37),p(1,25),i()),e&2){let t=d().$implicit;c(),se(t.Backup==null||t.Backup.Metadata==null?null:t.Backup.Metadata.BackupListCount),ue(1)}}function Ge(e,_){e&1&&(o(0,"spk-chip",38),p(1,26),i())}function he(e,_){if(e&1){let t=pe();o(0,"div",36)(1,"div",31)(2,"h3"),S(3),o(4,"spk-icon"),S(5,"database"),i()(),o(6,"p")(7,"span"),p(8,8),i(),S(9),$(10,"date"),g(11,Re,5,3)(12,He,2,0,"ng-container"),i(),o(13,"p")(14,"span"),p(15,9),i(),g(16,be,2,3)(17,xe,2,0,"ng-container"),i(),o(18,"p")(19,"span"),p(20,10),i(),g(21,Be,2,3)(22,Le,2,0,"ng-container"),i()(),g(23,ye,2,1,"spk-chip",37)(24,Ge,2,0,"spk-chip",38),o(25,"div",39)(26,"button",40),P("click",function(){let l=k(t).$implicit,M=d(3);return O(M.startBackup(l.Backup==null?null:l.Backup.ID))}),s(27,11),r(28,"spk-icon"),u(),i(),o(29,"button",41)(30,"spk-icon"),S(31,"pencil-simple"),i()(),o(32,"spk-menu",42)(33,"button",32)(34,"spk-icon"),S(35,"dots-three-vertical"),i()(),F(36,43),o(37,"h3",44),S(38,"Operations"),i(),o(39,"button",45,0),s(41,12),r(42,"spk-icon"),u(),i(),o(43,"button",45,0),s(45,13),r(46,"spk-icon"),u(),i(),o(47,"button",46,0),P("click",function(){let l=k(t).$implicit,M=d(3);return O(M.deleteBackup(l.Backup==null?null:l.Backup.ID))}),s(49,14),r(50,"spk-icon"),u(),i(),r(51,"spk-divider"),o(52,"h3",44),S(53,"Advanced"),i(),o(54,"button",45,0),s(56,15),r(57,"spk-icon"),u(),i(),o(58,"button",47,0),P("click",function(){let l=k(t).$implicit,M=d(3);return O(M.verifyFiles(l.Backup==null?null:l.Backup.ID))}),s(60,16),r(61,"spk-icon"),u(),i(),o(62,"button",47,0),P("click",function(){let l=k(t).$implicit,M=d(3);return O(M.compressBackup(l.Backup==null?null:l.Backup.ID))}),s(64,17),r(65,"spk-icon"),u(),i(),o(66,"button",45,0),s(68,18),r(69,"spk-icon"),u(),i(),r(70,"spk-divider"),o(71,"h3",44),S(72,"Reporting"),i(),o(73,"button",45,0),s(75,19),r(76,"spk-icon"),u(),i(),o(77,"button",47,0),P("click",function(){let l=k(t).$implicit,M=d(3);return O(M.createErrorReport(l.Backup==null?null:l.Backup.ID))}),s(79,20),r(80,"spk-icon"),u(),i(),C(),i()()()}if(e&2){let t,n=_.$implicit,l=d(3);c(3),N(" ",(t=n.Backup==null?null:n.Backup.Name)!==null&&t!==void 0?t:l.MISSING_BACKUP_NAME," "),c(6),N(" ",de(10,17,n.Backup==null||n.Backup.Metadata==null?null:n.Backup.Metadata.LastBackupDate,"short")," "),c(2),m(!(n.Backup==null||n.Backup.Metadata==null)&&n.Backup.Metadata.LastBackupDuration?11:12),c(5),m(!(n.Backup==null||n.Backup.Metadata==null)&&n.Backup.Metadata.SourceFilesSize?16:17),c(5),m(!(n.Backup==null||n.Backup.Metadata==null)&&n.Backup.Metadata.TargetFilesSize?21:22),c(2),m(!(n.Backup==null||n.Backup.Metadata==null)&&n.Backup.Metadata.BackupListCount?23:24),c(3),A("loader",l.startingBackup()),c(3),E("routerLink",T(20,Ne,n.Backup==null?null:n.Backup.ID)),c(3),E("right",!0),c(7),E("routerLink",T(22,$e,n.Backup==null?null:n.Backup.ID)),c(4),E("routerLink",T(24,fe,n.Backup==null?null:n.Backup.ID)),c(4),A("loader",l.deletingBackup()===(n.Backup==null?null:n.Backup.ID)),c(7),E("routerLink",T(26,Ie,n.Backup==null?null:n.Backup.ID)),c(12),E("routerLink",T(28,Ae,n.Backup==null?null:n.Backup.ID)),c(7),E("routerLink",T(30,De,n.Backup==null?null:n.Backup.ID))}}function ve(e,_){if(e&1&&ce(0,he,81,32,"div",36,le),e&2){let t=d(2);re(t.backups())}}function Xe(e,_){e&1&&(F(0),p(1,27),C())}function we(e,_){if(e&1&&g(0,ve,2,0)(1,Xe,2,0,"ng-container"),e&2){let t=d();m(t.backups().length?0:1)}}function ze(e,_){e&1&&(o(0,"div",48),r(1,"spk-progress-bar",49),o(2,"div",31)(3,"h3"),p(4,28),i()()())}var x=class e{#e=I(Te);#n=I(Se);MISSING_BACKUP_NAME=$localize`Backup name missing`;backups=this.#e.backups;backupsLoading=this.#e.backupsLoading;startingBackup=this.#e.startingBackup;deletingBackup=this.#e.deletingBackup;ngOnInit(){this.#e.getBackups(!0)}startBackup(_){this.#e.startBackup(_)}deleteBackup(_){window.confirm("Are you sure you want to delete this backup?")&&this.#e.deleteBackup(_)}verifyFiles(_){this.#n.postApiV1BackupByIdVerify({id:_}).subscribe()}compressBackup(_){this.#n.postApiV1BackupByIdCompact({id:_}).subscribe()}createErrorReport(_){this.#n.postApiV1BackupByIdCreatereport({id:_}).subscribe()}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=ie({type:e,selectors:[["app-home"]],decls:31,vars:5,consts:()=>{let _;_=$localize`Backups`;let t;t=$localize`Backups are stored in the cloud and can be restored at any time.`;let n;n=$localize` Add ${"\uFFFD#12\uFFFD"}:START_TAG_SPK_ICON:plus${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SPK_ICON:`;let l;l=$localize`Restores`;let M;M=$localize`Restores allow you to restore your data from the cloud.`;let B;B=$localize` Start ${"\uFFFD#22\uFFFD"}:START_TAG_SPK_ICON:arrow-right${"\uFFFD/#22\uFFFD"}:CLOSE_TAG_SPK_ICON:`;let L;L=$localize`My backups`;let y;y=$localize`Last successful backup:`;let G;G=$localize`Source:`;let h;h=$localize`Destination:`;let v;v=$localize`${"\uFFFD#28\uFFFD"}:START_TAG_SPK_ICON:play-circle${"\uFFFD/#28\uFFFD"}:CLOSE_TAG_SPK_ICON: Start `;let X;X=$localize`${"\uFFFD#42\uFFFD"}:START_TAG_SPK_ICON:clock-counter-clockwise${"\uFFFD/#42\uFFFD"}:CLOSE_TAG_SPK_ICON: Restore `;let w;w=$localize`${"\uFFFD#46\uFFFD"}:START_TAG_SPK_ICON:export${"\uFFFD/#46\uFFFD"}:CLOSE_TAG_SPK_ICON: Export `;let z;z=$localize`${"\uFFFD#50\uFFFD"}:START_TAG_SPK_ICON:x-circle${"\uFFFD/#50\uFFFD"}:CLOSE_TAG_SPK_ICON: Delete `;let K;K=$localize`${"\uFFFD#57\uFFFD"}:START_TAG_SPK_ICON:database${"\uFFFD/#57\uFFFD"}:CLOSE_TAG_SPK_ICON: Database `;let V;V=$localize`${"\uFFFD#61\uFFFD"}:START_TAG_SPK_ICON:check-square-offset${"\uFFFD/#61\uFFFD"}:CLOSE_TAG_SPK_ICON: Verify files `;let j;j=$localize`${"\uFFFD#65\uFFFD"}:START_TAG_SPK_ICON:file-archive${"\uFFFD/#65\uFFFD"}:CLOSE_TAG_SPK_ICON: Compress now `;let q;q=$localize`${"\uFFFD#69\uFFFD"}:START_TAG_SPK_ICON:terminal-window${"\uFFFD/#69\uFFFD"}:CLOSE_TAG_SPK_ICON: Commandline `;let U;U=$localize`${"\uFFFD#76\uFFFD"}:START_TAG_SPK_ICON:notepad${"\uFFFD/#76\uFFFD"}:CLOSE_TAG_SPK_ICON: Log `;let W;W=$localize`${"\uFFFD#80\uFFFD"}:START_TAG_SPK_ICON:file-plus${"\uFFFD/#80\uFFFD"}:CLOSE_TAG_SPK_ICON: Create error report `;let J;J=$localize`took`;let Q;Q=$localize`N/A`;let Y;Y=$localize`N/A`;let Z;Z=$localize`N/A`;let ee;ee=$localize` ${"\uFFFD0\uFFFD"}:INTERPOLATION: Version `;let ne;ne=$localize`No version yet`;let te;te=$localize`No backups founds`;let oe;return oe=$localize`Loading backups...`,[["option",""],_,t,n,l,M,B,L,y,G,h,v,X,w,z,K,V,j,q,U,W,J,Q,Y,Z,ee,ne,te,oe,[1,"type-a",3,"routerLink"],["src","assets/images/backup.png","alt","","width","48px"],[1,"text"],["type","button","spk-button",""],["src","assets/images/restore.png","alt","","width","48px"],[1,"content"],[1,"backups"],[1,"backup"],[1,"simple","success"],[1,"simple"],[1,"actions"],["spk-button","",3,"click"],["type","button","spk-button","",3,"routerLink"],[3,"right"],["menu",""],["title",""],["type","button",3,"routerLink"],[3,"click"],["type","button",3,"click"],[1,"loading-list"],[1,"indeterminate","primary"]]},template:function(t,n){t&1&&(r(0,"app-status-bar"),o(1,"section")(2,"header")(3,"spk-card",29),r(4,"img",30),o(5,"div",31)(6,"h3"),p(7,1),i(),o(8,"p"),p(9,2),i()(),o(10,"button",32),s(11,3),r(12,"spk-icon"),u(),i()(),o(13,"spk-card",29),r(14,"img",33),o(15,"div",31)(16,"h3"),p(17,4),i(),o(18,"p"),p(19,5),i()(),o(20,"button",32),s(21,6),r(22,"spk-icon"),u(),i()()(),o(23,"div",34)(24,"h2"),p(25,7),i(),o(26,"div",35),g(27,we,2,1)(28,ze,5,0),_e(29,27,Oe,null,28),i()()()),t&2&&(c(3),E("routerLink",D(3,me)),c(10),E("routerLink",D(4,Pe)),c(16),ae(!n.backupsLoading()))},dependencies:[R,ke,Me,b,H,Ce],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2rem;padding:2rem 0}header[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;padding:0 2rem;gap:1rem}spk-card[_ngcontent-%COMP%]{display:flex;align-items:center;gap:1rem}spk-card[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{flex:1 0;display:flex;flex-direction:column;gap:.25rem}.content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:0 2rem;gap:1rem}.backups[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.backup[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:2rem;gap:1rem;border:1px solid var(--base-level-40);border-radius:var(--shape-3);box-shadow:var(--shadow-1)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;width:100%;max-width:40%}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] h3[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{color:var(--base-level-60)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-level-60)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] p[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{color:var(--base-level-70)}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}"],changeDetection:0})};export{x as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as R,b as te}from"./chunk-DNHLTHLR.js";import{b as oe}from"./chunk-TYEKJAUH.js";import{a as G,b as L,c as S,d as K,e as U,h as z,l as j,o as V,p as q,r as H}from"./chunk-QXNJFFEM.js";import{
|
|
1
|
+
import{a as R,b as te}from"./chunk-DNHLTHLR.js";import{b as oe}from"./chunk-TYEKJAUH.js";import{a as ee}from"./chunk-O47LGUY4.js";import{a as G,b as L,c as S,d as K,e as U,h as z,l as j,o as V,p as q,r as H}from"./chunk-QXNJFFEM.js";import{b as v}from"./chunk-PSJAIBCQ.js";import{a as b,c as w,d as B}from"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import{a as Q,f as W,g as J,l as Y,w as Z}from"./chunk-YFA44VRS.js";import{c as h}from"./chunk-U5DDVNLJ.js";import"./chunk-X566VMXX.js";import{Ab as n,Bb as a,E,Hc as O,L as M,Lb as l,Mb as c,Nb as f,Oa as s,Rb as P,Va as g,X as _,bb as I,ec as k,hb as x,hc as y,oc as X,qb as C,sb as T,vb as D,zb as r}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";var ne=()=>["/"];function ie(d,e){d&1&&(r(0,"spk-form-field")(1,"label",17),f(2,6),n(),a(3,"input",18),n(),r(4,"spk-form-field")(5,"label",19),f(6,7),n(),a(7,"input",20),n())}var u=new q,N=class d{#o=_(v);#e=_(b);#t=_(w);#n=_(h);#i=_(ee);isExporting=g(!1);exportType=g("file");exportedCmd=g(null);exportForm=u.group({exportPasswords:u.control(!0),encryption:u.control(!1,[S.required,te()]),password:u.control("",[R(e=>e?.value.encryption,[S.required])]),repeatPassword:u.control("",[R(e=>e?.value.encryption,[S.required])])});exportFormSignal=oe(this.exportForm.valueChanges);encryptionFieldSignal=O(()=>this.exportFormSignal()?.encryption??!1);activeBackup=O(()=>this.#i.backups().find(e=>e.Backup?.ID===this.#e.snapshot.params.id));submit(){this.isExporting.set(!0),this.exportType()==="file"?this.#o.postApiV1AuthIssuetokenByOperation({operation:"export"}).pipe(M(e=>{let i=t=>{let o=Object.entries(t);return o?"?"+o.map(([F,m])=>`${F}=${m}`).join("&"):""};return this.#n.get(`/api/v1/backup/${this.#e.snapshot.params.id}/export${i({exportPasswords:this.exportFormSignal()?.exportPasswords??void 0,passphrase:this.exportFormSignal()?.password??void 0,token:e.Token})}`,{responseType:"blob"})}),E(()=>this.isExporting.set(!1))).subscribe({next:e=>{let t=this.activeBackup()?.Backup?.Name??"Backup",o=this.exportFormSignal()?.encryption?"aes":"json";this.downloadFile(e,`${t}.${o}`),this.#t.navigate(["/"])},error:e=>{console.log("err",e)}}):this.#o.getApiV1BackupByIdExportCmdline({id:this.#e.snapshot.params.id,exportPasswords:this.exportFormSignal()?.exportPasswords??void 0,passphrase:this.exportFormSignal()?.password??void 0}).pipe(E(()=>this.isExporting.set(!1))).subscribe({next:e=>{console.log("res",e),this.exportedCmd.set(e.Command??null)},error:e=>{console.log("err",e)}})}downloadFile(e,i){let t=window.URL.createObjectURL(e),o=document.createElement("a");o.href=t,o.download=i,o.click(),window.URL.revokeObjectURL(t)}static \u0275fac=function(i){return new(i||d)};static \u0275cmp=I({type:d,selectors:[["app-export"]],decls:27,vars:12,consts:()=>{let e;e=$localize`${"\uFFFD#6\uFFFD"}:START_TAG_SPK_ICON:arrow-left${"\uFFFD/#6\uFFFD"}:CLOSE_TAG_SPK_ICON: Back `;let i;i=$localize`${"\uFFFD#9\uFFFD"}:START_TAG_SPK_ICON:export${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SPK_ICON: Export `;let t;t=$localize`${"\uFFFD#16\uFFFD"}:START_TAG_SPK_ICON:terminal-window${"\uFFFD/#16\uFFFD"}:CLOSE_TAG_SPK_ICON: As command line `;let o;o=$localize`${"\uFFFD#19\uFFFD"}:START_TAG_SPK_ICON:file${"\uFFFD/#19\uFFFD"}:CLOSE_TAG_SPK_ICON: To file `;let F;F=$localize` Export passwords ${"\uFFFD#22\uFFFD\uFFFD/#22\uFFFD"}:TAG_INPUT:`;let m;m=$localize` Encrypt file ${"\uFFFD#25\uFFFD\uFFFD/#25\uFFFD"}:TAG_INPUT:`;let A;A=$localize`Password`;let $;return $=$localize`Repeat password`,[e,i,t,o,F,m,A,$,[1,"actions"],["spk-button","",1,"outlined",3,"routerLink"],["spk-button","",1,"raised","primary",3,"click"],["autocomplete","off",3,"formGroup"],["type","button",3,"click"],[1,"raised","primary"],["type","checkbox","formControlName","exportPasswords"],[1,"primary","raised"],["type","checkbox","formControlName","encryption"],["for","password"],["type","password","id","password","formControlName","password"],["for","repeatPassword"],["type","password","id","repeatPassword","formControlName","repeatPassword"]]},template:function(i,t){if(i&1&&(r(0,"header")(1,"h3"),k(2," Export backup configuration "),r(3,"div",8)(4,"button",9),l(5,0),a(6,"spk-icon"),c(),n(),r(7,"button",10),P("click",function(){return t.submit()}),l(8,1),a(9,"spk-icon"),c(),n()()(),r(10,"p"),k(11),n()(),r(12,"form",11)(13,"spk-button-group")(14,"button",12),P("click",function(){return t.exportType.set("cmd")}),l(15,2),a(16,"spk-icon"),c(),n(),r(17,"button",12),P("click",function(){return t.exportType.set("file")}),l(18,3),a(19,"spk-icon"),c(),n()(),r(20,"spk-toggle",13),l(21,4),a(22,"input",14),c(),n(),r(23,"spk-toggle",15),l(24,5),a(25,"input",16),c(),n(),x(26,ie,8,0),n()),i&2){let o;s(4),C("routerLink",X(11,ne)),s(3),T("loading",t.isExporting()),s(4),y("#",(o=t.activeBackup())==null||o.Backup==null?null:o.Backup.ID,": ",(o=t.activeBackup())==null||o.Backup==null?null:o.Backup.Name,""),s(),C("formGroup",t.exportForm),s(2),T("active",t.exportType()==="cmd"),s(3),T("active",t.exportType()==="file"),s(9),D(t.encryptionFieldSignal()?26:-1)}},dependencies:[H,z,L,G,K,U,j,V,B,W,Z,Q,Y,J],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:2rem;padding:3rem}h3[_ngcontent-%COMP%]{font:var(--title-30);display:flex;align-items:center;justify-content:space-between}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;max-width:31.25rem}"],changeDetection:0})};export{N as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{g as Xt}from"./chunk-OJUBI3TM.js";import"./chunk-VJJVFTK5.js";import{a as U,b as Wt,c as zt,q as Z}from"./chunk-YWZWJHRE.js";import{a as Ht}from"./chunk-4765QCNT.js";import{a as Kt}from"./chunk-FALW4SDX.js";import"./chunk-DNHLTHLR.js";import"./chunk-TYEKJAUH.js";import"./chunk-QTTCN7A7.js";import{a as ft,b as gt,d as Dt,e as St,f as Et,h as Ot,i as xt,k as kt,l as Nt,m as Rt,n as ht,o as yt,p as It,r as $t}from"./chunk-QXNJFFEM.js";import{b as Ct}from"./chunk-PSJAIBCQ.js";import{a as ut,c as Tt}from"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import{a as wt,b as vt,d as At,e as Pt,i as Vt,l as Mt,n as bt,q as Gt,r as Bt,w as Lt,x as Ut}from"./chunk-FFD5RG7J.js";import{c as dt}from"./chunk-U5DDVNLJ.js";import{ia as Ft}from"./chunk-X566VMXX.js";import{Ab as a,Bb as u,Cb as v,Db as A,E as tt,Eb as M,Fb as x,Hc as K,Jc as mt,Lb as N,Mb as R,Nb as b,Oa as o,Ob as q,Pb as j,Qb as H,Rb as g,Sb as s,Va as h,Vb as y,Wa as nt,X as w,Yb as T,bb as it,bc as ot,ca as C,cc as at,da as f,dc as G,ec as p,fc as V,gc as O,ha as et,hb as F,hc as Q,jc as rt,kc as lt,lc as st,nc as pt,oc as _t,pc as B,qb as c,rc as L,sb as X,vb as d,vc as ct,wb as D,xb as S,yb as E,zb as r}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";var qt=["formRef"],jt=(n,i,t,e)=>({index:n,formView:i,formGroupName:"custom",destinationType:t,oauthField:e}),z=n=>({$implicit:n}),Qt=(n,i,t,e)=>({index:n,formView:i,formGroupName:"dynamic",destinationType:t,oauthField:e}),Zt=(n,i,t,e)=>({index:n,formView:i,formGroupName:"advanced",destinationType:t,oauthField:e}),Jt=(n,i,t,e)=>({index:n,formView:i,formGroupName:"advanced",asHttpOptions:!0,destinationType:t,oauthField:e}),Yt=()=>({maxWidth:"700px",width:"100%"});function te(n,i){n&1&&(N(0,2,2),u(1,"spk-icon"),R())}function ee(n,i){n&1&&b(0,2,3)}function ne(n,i){if(n&1){let t=x();N(0,2,1),r(1,"button",18),g("click",function(){C(t);let l=s();return f(l.testDestination())}),F(2,te,2,0)(3,ee,1,0),a(),R()}if(n&2){let t=s();o(),X("success",t.successfulTest()),o(),d(t.successfulTest()?2:3)}}function ie(n,i){if(n&1){let t=x();r(0,"p",24),g("click",function(){C(t);let l=s();return f(l.removeDestinationFormGroup(l.destinationCount()-1))}),N(1,5),u(2,"span",25),R(),a()}}function oe(n,i){if(n&1){let t=x();r(0,"div",30),g("click",function(){let l=C(t).$implicit,_=s(2);return f(_.addDestinationFormGroup(l.key))}),r(1,"h3"),p(2),a(),r(3,"p"),p(4),a()()}if(n&2){let t=i.$implicit;o(2),V(t.displayName),o(2),V(t.description)}}function ae(n,i){if(n&1){let t=x();r(0,"button",31),g("click",function(){let l=C(t).$implicit,_=s(2);return f(_.addDestinationFormGroup(l.key))}),p(1),a()}if(n&2){let t=i.$implicit;o(),O(" ",t.displayName," ")}}function re(n,i){if(n&1&&(r(0,"div",26),S(1,oe,5,2,"div",27,D),a(),r(3,"spk-menu")(4,"button",28),b(5,6),a(),v(6,17),S(7,ae,2,1,"button",29,D),A(),a()),n&2){let t=s();o(),E(t.destinationTypeOptionsFocused()),o(6),E(t.destinationTypeOptionsNotFocused())}}function le(n,i){n&1&&M(0)}function se(n,i){if(n&1&&F(0,le,1,0,"ng-container",36),n&2){let t,e=i.$implicit,l=i.$index;s();let _=G(29),m=s();c("ngTemplateOutlet",_)("ngTemplateOutletContext",B(7,z,L(2,jt,l,e,(t=m.destinationFormSignal())==null||t.destinations==null||t.destinations[0]==null?null:t.destinations[0].destinationType,m.destinationFormPair().oauthField)))}}function pe(n,i){n&1&&M(0)}function _e(n,i){if(n&1&&F(0,pe,1,0,"ng-container",36),n&2){let t,e=i.$implicit,l=i.$index;s();let _=G(29),m=s();c("ngTemplateOutlet",_)("ngTemplateOutletContext",B(7,z,L(2,Qt,l,e,(t=m.destinationFormSignal())==null||t.destinations==null||t.destinations[0]==null?null:t.destinations[0].destinationType,m.destinationFormPair().oauthField)))}}function ce(n,i){if(n&1){let t=x();N(0,7,1),r(1,"button",31),g("click",function(){let l=C(t).$implicit,_=s(2);return f(_.addAdvancedFormPair(l,0))}),a(),R()}if(n&2){let t=i.$implicit;o(),q(t.name),j(0)}}function me(n,i){n&1&&M(0)}function Fe(n,i){if(n&1&&F(0,me,1,0,"ng-container",36),n&2){let t,e=i.$implicit,l=i.$index;s();let _=G(29),m=s();c("ngTemplateOutlet",_)("ngTemplateOutletContext",B(7,z,L(2,Zt,l,e,(t=m.destinationFormSignal())==null||t.destinations==null||t.destinations[0]==null?null:t.destinations[0].destinationType,m.destinationFormPair().oauthField)))}}function de(n,i){if(n&1){let t=x();N(0,8,1),r(1,"button",31),g("click",function(){let l=C(t).$implicit,_=s(2);return f(_.addHttpOption(l,0))}),a(),R()}if(n&2){let t=i.$implicit;o(),q(t.name),j(0)}}function ue(n,i){n&1&&M(0)}function Te(n,i){if(n&1&&F(0,ue,1,0,"ng-container",36),n&2){let t,e=i.$implicit,l=i.$index;s();let _=G(29),m=s();c("ngTemplateOutlet",_)("ngTemplateOutletContext",B(7,z,L(2,Jt,l,e,(t=m.destinationFormSignal())==null||t.destinations==null||t.destinations[0]==null?null:t.destinations[0].destinationType,m.destinationFormPair().oauthField)))}}function Ce(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function fe(n,i){if(n&1&&(r(0,"app-file-tree",39)(1,"label",46),p(2),F(3,Ce,3,1,"spk-tooltip",47),a(),u(4,"input",48),a()),n&2){let t,e=s().$implicit,l=s(2);c("startingPath",l.getFormFieldValue(0,e.formGroupName,e.formView.name))("accepts",e.formView.accepts)("showFiles",!0)("hideShortcuts",!0)("showHiddenNodes",!0)("selectFiles",!0),o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name)}}function ge(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function De(n,i){if(n&1&&(r(0,"app-file-tree",40)(1,"label",46),p(2),F(3,ge,3,1,"spk-tooltip",47),a(),u(4,"input",48),a()),n&2){let t,e=s().$implicit,l=s(2);c("hideShortcuts",!0)("startingPath",l.getFormFieldValue(0,e.formGroupName,e.formView.name)),o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name)}}function Se(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function Ee(n,i){n&1&&(r(0,"spk-icon",50),p(1,"link"),a())}function Oe(n,i){n&1&&(r(0,"spk-icon",50),p(1,"envelope"),a())}function xe(n,i){n&1&&(r(0,"spk-icon",50),p(1,"textbox"),a())}function ke(n,i){if(n&1&&(r(0,"spk-form-field")(1,"label",46),p(2),F(3,Se,3,1,"spk-tooltip",47),a(),u(4,"input",49),F(5,Ee,2,0,"spk-icon",50)(6,Oe,2,0,"spk-icon",50)(7,xe,2,0,"spk-icon",50),a()),n&2){let t,e=s().$implicit;o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name),c("type",e.formView.type==="Email"?"email":"text"),o(),d(e.formView.type==="Path"?5:e.formView.type==="Email"?6:7)}}function Ne(n,i){if(n&1){let t=x();r(0,"span",54),g("click",function(){C(t);let l=s(2).$implicit,_=s(2);return f(_.oauthStartTokenCreation(l.destinationType))}),p(1,"AuthID"),a()}}function Re(n,i){n&1&&(r(0,"spk-icon",50),p(1,"password"),a())}function he(n,i){if(n&1){let t=x();r(0,"spk-icon",55),g("click",function(){C(t);let l=s(2).$implicit;return f(l.formView.showPassword=!l.formView.showPassword)}),p(1," eye "),a()}}function ye(n,i){if(n&1){let t=x();r(0,"spk-icon",55),g("click",function(){C(t);let l=s(2).$implicit;return f(l.formView.showPassword=!l.formView.showPassword)}),p(1," eye-slash "),a()}}function Ie(n,i){if(n&1&&(r(0,"spk-form-field")(1,"label",46),p(2),a(),u(3,"input",51),F(4,Ne,2,0,"span",52)(5,Re,2,0,"spk-icon",50)(6,he,2,0,"spk-icon",53)(7,ye,2,0,"spk-icon",53),a()),n&2){let t,e=s().$implicit;o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name),c("type",e.formView.showPassword?"text":"password"),o(),d(e.oauthField===e.formView.name?4:5),o(2),d(e.formView.showPassword?6:7)}}function $e(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function we(n,i){if(n&1&&(r(0,"spk-option",56),p(1),a()),n&2){let t=i.$implicit;c("value",t.value),o(),Q(" ",t.key," ",t.value?"("+t.value+")":""," ")}}function ve(n,i){if(n&1&&S(0,we,2,3,"spk-option",56,D),n&2){let t=s(2).$implicit,e=s(2);E(t.formView.loadOptions(e.injector)())}}function Ae(n,i){if(n&1&&(r(0,"spk-option",56),p(1),a()),n&2){let t=i.$implicit;c("value",t),o(),V(t)}}function Pe(n,i){if(n&1&&S(0,Ae,2,2,"spk-option",56,D),n&2){let t=s(2).$implicit;E(t.formView.options)}}function Ve(n,i){if(n&1&&(r(0,"spk-select",41)(1,"label",46),p(2),F(3,$e,3,1,"spk-tooltip",47),a(),u(4,"input",48),F(5,ve,2,0)(6,Pe,2,0),a()),n&2){let t,e=s().$implicit;c("hideClearButton",!0),o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name),o(),d(e.formView.loadOptions?5:-1),o(),d(e.formView.options?6:-1)}}function Me(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function be(n,i){if(n&1&&(r(0,"spk-option",56),p(1),a()),n&2){let t=i.$implicit;c("value",t.value),o(),Q(" ",t.key," ",t.value?"("+t.value+")":""," ")}}function Ge(n,i){if(n&1&&S(0,be,2,3,"spk-option",56,D),n&2){let t=s(2).$implicit,e=s(2);E(t.formView.loadOptions(e.injector)())}}function Be(n,i){if(n&1&&(r(0,"spk-option",56),p(1),a()),n&2){let t=i.$implicit;c("value",t),o(),V(t)}}function Le(n,i){if(n&1&&S(0,Be,2,2,"spk-option",56,D),n&2){let t=s(2).$implicit;E(t.formView.options)}}function Ue(n,i){if(n&1&&(r(0,"spk-select",42)(1,"label",46),p(2),F(3,Me,3,1,"spk-tooltip",47),a(),u(4,"input",57),F(5,Ge,2,0)(6,Le,2,0),a()),n&2){let t,e=s().$implicit;c("isFreeText",!0),o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name),o(),d(e.formView.loadOptions?5:-1),o(),d(e.formView.options?6:-1)}}function He(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function Ke(n,i){if(n&1&&(r(0,"spk-option",56),p(1),a()),n&2){let t=i.$implicit;c("value",t),o(),V(t)}}function We(n,i){if(n&1&&(r(0,"div",43)(1,"label",46),p(2),F(3,He,3,1,"spk-tooltip",47),a(),r(4,"div",58)(5,"spk-form-field"),u(6,"input",59),r(7,"spk-icon",50),p(8,"resize"),a()(),r(9,"spk-select"),u(10,"label")(11,"input",60),S(12,Ke,2,2,"spk-option",56,D),a()()()),n&2){let t,e=s().$implicit,l=s(2);c("formGroupName",e.formView.name),o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(3),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(6),E(l.sizeOptions())}}function ze(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function Xe(n,i){if(n&1&&(r(0,"spk-form-field")(1,"label",46),p(2),F(3,ze,3,1,"spk-tooltip",47),a(),u(4,"input",61),r(5,"spk-icon",50),p(6,"numpad"),a()()),n&2){let t,e=s().$implicit;o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name)}}function qe(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function je(n,i){if(n&1&&(r(0,"spk-toggle",44)(1,"label",46),p(2),F(3,qe,3,1,"spk-tooltip",47),a(),u(4,"input",62),a()),n&2){let t,e=s().$implicit;o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name)}}function Qe(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function Ze(n,i){n&1&&(r(0,"spk-option",64),p(1,"None"),a()),n&2&&c("value","None")}function Je(n,i){if(n&1&&(r(0,"spk-option",56),p(1),u(2,"spk-checkbox",65),a()),n&2){let t=s().$implicit;c("value",t),o(),O(" ",t," ")}}function Ye(n,i){if(n&1&&F(0,Ze,2,1,"spk-option",64)(1,Je,3,2,"spk-option",56),n&2){let t=i.$implicit;d(t==="None"?0:1)}}function tn(n,i){if(n&1&&(r(0,"spk-select",45)(1,"label",46),p(2),F(3,Qe,3,1,"spk-tooltip",47),a(),u(4,"input",63),S(5,Ye,2,1,null,null,D),a()),n&2){let t,e=s().$implicit;c("selectMultiple",!0),o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),y("formControlName",e.formView.name),o(),E(e.formView.options)}}function en(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function nn(n,i){if(n&1&&(r(0,"spk-form-field")(1,"label",46),p(2),F(3,en,3,1,"spk-tooltip",47),a(),u(4,"input",48),a()),n&2){let t,e=s().$implicit;o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name)}}function on(n,i){if(n&1){let t=x();r(0,"button",66),g("click",function(){C(t);let l=s().$implicit,_=s(2);return f(_.removeFormView(l.formView,0))}),r(1,"spk-icon"),p(2,"x-circle"),a()()}}function an(n,i){if(n&1&&(r(0,"div",37),v(1,38),F(2,fe,5,17,"app-file-tree",39)(3,De,5,13,"app-file-tree",40)(4,ke,8,13,"spk-form-field")(5,Ie,8,13,"spk-form-field")(6,Ve,7,14,"spk-select",41)(7,Ue,7,14,"spk-select",42)(8,We,14,11,"div",43)(9,Xe,7,11,"spk-form-field")(10,je,5,11,"spk-toggle",44)(11,tn,7,8,"spk-select",45)(12,nn,5,11,"spk-form-field"),A(),F(13,on,3,0,"button",28),a()),n&2){let t=i.$implicit;X("single-field",t.formGroupName!=="advanced"),o(),c("formGroupName",t.formGroupName),o(),d(t.formView.type==="FileTree"?2:t.formView.type==="FolderTree"?3:t.formView.type==="String"||t.formView.type==="Path"||t.formView.type==="Email"?4:t.formView.type==="Password"?5:t.formView.type==="Enumeration"?6:t.formView.type==="NonValidatedSelectableString"?7:t.formView.type==="Size"?8:t.formView.type==="Integer"?9:t.formView.type==="Boolean"?10:t.formView.type==="Flags"?11:t.formView.type==="Timespan"?12:-1),o(11),d(t.formGroupName==="advanced"?13:-1)}}function rn(n,i){if(n&1&&(v(0,19)(1,32),S(2,se,1,9,"ng-container",null,D),S(4,_e,1,9,"ng-container",null,D),r(6,"app-toggle-card",33),v(7,34),N(8,7),r(9,"spk-menu")(10,"button",35),u(11,"spk-icon"),a(),v(12,17),S(13,ce,2,1,"button",29,D),A(),a(),R(),A(),S(15,Fe,1,9,"ng-container",null,D),a(),r(17,"app-toggle-card",33),v(18,34),N(19,8),r(20,"spk-menu")(21,"button",35),u(22,"spk-icon"),a(),v(23,17),S(24,de,2,1,"button",29,D),A(),a(),R(),A(),S(26,Te,1,9,"ng-container",null,D),a(),F(28,an,14,5,"ng-template",null,1,ct),A()()),n&2){let t=s();o(2),E(t.destinationFormPair().custom),o(2),E(t.destinationFormPair().dynamic),o(2),c("disallowToggle",!0),o(4),c("disabled",t.notSelectedAdvancedFormPair().length===0),o(3),E(t.notSelectedAdvancedFormPair()),o(2),E(t.selectedAdvancedFormPair()),o(2),c("disallowToggle",!0),o(4),c("disabled",t.notSelectedHttpOptions().length===0),o(3),E(t.notSelectedHttpOptions()),o(2),E(t.selectedHttpOptions())}}function ln(n,i){if(n&1){let t=x();r(0,"spk-dialog",67),st("isOpenChange",function(l){C(t);let _=s();return lt(_.targetUrlDialogOpen,l)||(_.targetUrlDialogOpen=l),f(l)}),r(1,"header",68)(2,"h2"),b(3,9),a(),r(4,"spk-alert",69),b(5,10),a()(),r(6,"div",70)(7,"spk-form-field"),u(8,"textarea",71),a()(),r(9,"footer",72)(10,"button",21),g("click",function(){C(t);let l=s();return f(l.closeTargetUrlDialog(!1))}),p(11,"Cancel"),a(),r(12,"button",73),g("click",function(){C(t);let l=s();return f(l.closeTargetUrlDialog(!0))}),N(13,11),u(14,"spk-icon"),R(),a()()()}if(n&2){let t=s();rt("isOpen",t.targetUrlDialogOpen),c("options",_t(3,Yt)),o(8),c("formControl",t.targetUrlCtrl)}}var sn=["Bytes","KB","MB","GB","TB","PB"],W=new It,vn=(n={destinations:[]})=>W.group({destinations:W.array(n.destinations)}),An=({key:n,customGroup:i,dynamicGroup:t,advancedGroup:e})=>W.group({destinationType:W.control(n),custom:i,dynamic:t,advanced:e}),J=class n{#l=w(Tt);#s=w(ut);#p=w(dt);#t=w(Z);#i=w(Ct);#e=w(Pt);#n=w(Xt);injector=w(et);formRef=nt.required("formRef");destinationForm=this.#t.destinationForm;destinationFormPair=this.#t.destinationFormPair;selectedAdvancedFormPair=this.#t.selectedAdvancedFormPair;notSelectedAdvancedFormPair=this.#t.notSelectedAdvancedFormPair;selectedHttpOptions=this.#t.selectedHttpOptions;notSelectedHttpOptions=this.#t.notSelectedHttpOptions;destinationOptions=this.#t.destinationOptions;destinationFormSignal=this.#t.destinationFormSignal;destinationCount=K(()=>this.destinationFormSignal()?.destinations?.length??0);sizeOptions=h(sn);successfulTest=h(!1);destinationTypeOptionsInFocus=h(["file","ssh","s3","gcs","googledrive","azure"]);destinationTypeOptions=h(zt.map(i=>({key:i.customKey??i.key,customKey:i.customKey??null,displayName:i.displayName,description:i.description})));destinationTypeOptionsFocused=K(()=>{let i=this.destinationTypeOptionsInFocus(),t=this.destinationTypeOptions();return i.map(e=>t.find(l=>l.key===e))});destinationTypeOptionsNotFocused=K(()=>{let i=this.destinationTypeOptionsInFocus();return this.destinationTypeOptions().filter(e=>!i.includes(e.key))});targetUrlEffect=mt(()=>{if(this.destinationFormSignal(),this.destinationForm.valid){let i=this.#t.getCurrentTargetUrl();this.#n.updateTargetUrl(i[0])}else this.#n.updateTargetUrl(null)});ngOnInit(){let i=this.#n.destinationTargetUrl();i&&this.#t.updateFieldsFromTargetUrl(i)}getFormFieldValue(i,t,e){return((this.destinationForm.controls.destinations.controls?.[i]).controls?.[t]).controls[e].value}addDestinationFormGroup(i){this.#t.addDestinationFormGroup(i)}addAdvancedFormPair(i,t){this.#t.addAdvancedFormPair(i,t)}removeFormView(i,t){this.#t.removeAdvancedFormPair(i,t)}addHttpOption(i,t){this.#t.addHttpOption(i,t)}targetUrlCtrl=new Et;targetUrlInitial=h(null);targetUrlDialogOpen=h(!1);openTargetUrlDialog(){let t=this.#t.getCurrentTargetUrl()[0];this.targetUrlCtrl.setValue(t),this.targetUrlInitial.set(t),this.targetUrlDialogOpen.set(!0)}closeTargetUrlDialog(i=!1){this.targetUrlDialogOpen.set(!1);let t=this.targetUrlCtrl.value,e=this.targetUrlInitial();!i||t===e||this.#t.updateFieldsFromTargetUrl(this.targetUrlCtrl.value)}testDestination(i=0){let e=this.#t.getCurrentTargetUrl()[i];e&&this.#i.postApiV1RemoteoperationTest({requestBody:{path:e}}).subscribe({next:()=>{this.successfulTest.set(!0),setTimeout(()=>{this.successfulTest.set(!1)},3e3)},error:l=>{let _=l.error.error.Error;if(_==="missing-folder"&&this.#e.open(U,{data:{title:$localize`Create folder`,message:$localize`The remote destination folder does not exist, do you want to create it?`},closed:m=>{m&&this.#i.postApiV1RemoteoperationCreate({requestBody:{path:e}}).subscribe()}}),_.startsWith("incorrect-cert:")){let m=_.split("incorrect-cert:")[1];this.#e.open(U,{maxWidth:"500px",data:{title:$localize`Trust the certificate`,message:$localize`The server is using a certificate that is not trusted.
|
|
1
|
+
import{g as Xt}from"./chunk-R5ARSI2W.js";import"./chunk-VJJVFTK5.js";import{a as U,b as Wt,c as zt,q as Z}from"./chunk-TOUGWZ56.js";import{a as Ht}from"./chunk-TLM42G2X.js";import{a as Kt}from"./chunk-NZ5QQIUJ.js";import"./chunk-DNHLTHLR.js";import"./chunk-TYEKJAUH.js";import"./chunk-QTTCN7A7.js";import{a as ft,b as gt,d as Dt,e as St,f as Et,h as Ot,i as xt,k as kt,l as Nt,m as Rt,n as ht,o as yt,p as It,r as $t}from"./chunk-QXNJFFEM.js";import{b as Ct}from"./chunk-PSJAIBCQ.js";import{a as ut,c as Tt}from"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import{a as wt,b as vt,d as At,e as Pt,i as Vt,l as Mt,n as bt,q as Gt,r as Bt,w as Lt,x as Ut}from"./chunk-YFA44VRS.js";import{c as dt}from"./chunk-U5DDVNLJ.js";import{ia as Ft}from"./chunk-X566VMXX.js";import{Ab as a,Bb as u,Cb as v,Db as A,E as tt,Eb as M,Fb as x,Hc as K,Jc as mt,Lb as N,Mb as R,Nb as b,Oa as o,Ob as q,Pb as j,Qb as H,Rb as g,Sb as s,Va as h,Vb as y,Wa as nt,X as w,Yb as T,bb as it,bc as ot,ca as C,cc as at,da as f,dc as G,ec as p,fc as V,gc as O,ha as et,hb as F,hc as Q,jc as rt,kc as lt,lc as st,nc as pt,oc as _t,pc as B,qb as c,rc as L,sb as X,vb as d,vc as ct,wb as D,xb as S,yb as E,zb as r}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";var qt=["formRef"],jt=(n,i,t,e)=>({index:n,formView:i,formGroupName:"custom",destinationType:t,oauthField:e}),z=n=>({$implicit:n}),Qt=(n,i,t,e)=>({index:n,formView:i,formGroupName:"dynamic",destinationType:t,oauthField:e}),Zt=(n,i,t,e)=>({index:n,formView:i,formGroupName:"advanced",destinationType:t,oauthField:e}),Jt=(n,i,t,e)=>({index:n,formView:i,formGroupName:"advanced",asHttpOptions:!0,destinationType:t,oauthField:e}),Yt=()=>({maxWidth:"700px",width:"100%"});function te(n,i){n&1&&(N(0,2,2),u(1,"spk-icon"),R())}function ee(n,i){n&1&&b(0,2,3)}function ne(n,i){if(n&1){let t=x();N(0,2,1),r(1,"button",18),g("click",function(){C(t);let l=s();return f(l.testDestination())}),F(2,te,2,0)(3,ee,1,0),a(),R()}if(n&2){let t=s();o(),X("success",t.successfulTest()),o(),d(t.successfulTest()?2:3)}}function ie(n,i){if(n&1){let t=x();r(0,"p",24),g("click",function(){C(t);let l=s();return f(l.removeDestinationFormGroup(l.destinationCount()-1))}),N(1,5),u(2,"span",25),R(),a()}}function oe(n,i){if(n&1){let t=x();r(0,"div",30),g("click",function(){let l=C(t).$implicit,_=s(2);return f(_.addDestinationFormGroup(l.key))}),r(1,"h3"),p(2),a(),r(3,"p"),p(4),a()()}if(n&2){let t=i.$implicit;o(2),V(t.displayName),o(2),V(t.description)}}function ae(n,i){if(n&1){let t=x();r(0,"button",31),g("click",function(){let l=C(t).$implicit,_=s(2);return f(_.addDestinationFormGroup(l.key))}),p(1),a()}if(n&2){let t=i.$implicit;o(),O(" ",t.displayName," ")}}function re(n,i){if(n&1&&(r(0,"div",26),S(1,oe,5,2,"div",27,D),a(),r(3,"spk-menu")(4,"button",28),b(5,6),a(),v(6,17),S(7,ae,2,1,"button",29,D),A(),a()),n&2){let t=s();o(),E(t.destinationTypeOptionsFocused()),o(6),E(t.destinationTypeOptionsNotFocused())}}function le(n,i){n&1&&M(0)}function se(n,i){if(n&1&&F(0,le,1,0,"ng-container",36),n&2){let t,e=i.$implicit,l=i.$index;s();let _=G(29),m=s();c("ngTemplateOutlet",_)("ngTemplateOutletContext",B(7,z,L(2,jt,l,e,(t=m.destinationFormSignal())==null||t.destinations==null||t.destinations[0]==null?null:t.destinations[0].destinationType,m.destinationFormPair().oauthField)))}}function pe(n,i){n&1&&M(0)}function _e(n,i){if(n&1&&F(0,pe,1,0,"ng-container",36),n&2){let t,e=i.$implicit,l=i.$index;s();let _=G(29),m=s();c("ngTemplateOutlet",_)("ngTemplateOutletContext",B(7,z,L(2,Qt,l,e,(t=m.destinationFormSignal())==null||t.destinations==null||t.destinations[0]==null?null:t.destinations[0].destinationType,m.destinationFormPair().oauthField)))}}function ce(n,i){if(n&1){let t=x();N(0,7,1),r(1,"button",31),g("click",function(){let l=C(t).$implicit,_=s(2);return f(_.addAdvancedFormPair(l,0))}),a(),R()}if(n&2){let t=i.$implicit;o(),q(t.name),j(0)}}function me(n,i){n&1&&M(0)}function Fe(n,i){if(n&1&&F(0,me,1,0,"ng-container",36),n&2){let t,e=i.$implicit,l=i.$index;s();let _=G(29),m=s();c("ngTemplateOutlet",_)("ngTemplateOutletContext",B(7,z,L(2,Zt,l,e,(t=m.destinationFormSignal())==null||t.destinations==null||t.destinations[0]==null?null:t.destinations[0].destinationType,m.destinationFormPair().oauthField)))}}function de(n,i){if(n&1){let t=x();N(0,8,1),r(1,"button",31),g("click",function(){let l=C(t).$implicit,_=s(2);return f(_.addHttpOption(l,0))}),a(),R()}if(n&2){let t=i.$implicit;o(),q(t.name),j(0)}}function ue(n,i){n&1&&M(0)}function Te(n,i){if(n&1&&F(0,ue,1,0,"ng-container",36),n&2){let t,e=i.$implicit,l=i.$index;s();let _=G(29),m=s();c("ngTemplateOutlet",_)("ngTemplateOutletContext",B(7,z,L(2,Jt,l,e,(t=m.destinationFormSignal())==null||t.destinations==null||t.destinations[0]==null?null:t.destinations[0].destinationType,m.destinationFormPair().oauthField)))}}function Ce(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function fe(n,i){if(n&1&&(r(0,"app-file-tree",39)(1,"label",46),p(2),F(3,Ce,3,1,"spk-tooltip",47),a(),u(4,"input",48),a()),n&2){let t,e=s().$implicit,l=s(2);c("startingPath",l.getFormFieldValue(0,e.formGroupName,e.formView.name))("accepts",e.formView.accepts)("showFiles",!0)("hideShortcuts",!0)("showHiddenNodes",!0)("selectFiles",!0),o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name)}}function ge(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function De(n,i){if(n&1&&(r(0,"app-file-tree",40)(1,"label",46),p(2),F(3,ge,3,1,"spk-tooltip",47),a(),u(4,"input",48),a()),n&2){let t,e=s().$implicit,l=s(2);c("hideShortcuts",!0)("startingPath",l.getFormFieldValue(0,e.formGroupName,e.formView.name)),o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name)}}function Se(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function Ee(n,i){n&1&&(r(0,"spk-icon",50),p(1,"link"),a())}function Oe(n,i){n&1&&(r(0,"spk-icon",50),p(1,"envelope"),a())}function xe(n,i){n&1&&(r(0,"spk-icon",50),p(1,"textbox"),a())}function ke(n,i){if(n&1&&(r(0,"spk-form-field")(1,"label",46),p(2),F(3,Se,3,1,"spk-tooltip",47),a(),u(4,"input",49),F(5,Ee,2,0,"spk-icon",50)(6,Oe,2,0,"spk-icon",50)(7,xe,2,0,"spk-icon",50),a()),n&2){let t,e=s().$implicit;o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name),c("type",e.formView.type==="Email"?"email":"text"),o(),d(e.formView.type==="Path"?5:e.formView.type==="Email"?6:7)}}function Ne(n,i){if(n&1){let t=x();r(0,"span",54),g("click",function(){C(t);let l=s(2).$implicit,_=s(2);return f(_.oauthStartTokenCreation(l.destinationType))}),p(1,"AuthID"),a()}}function Re(n,i){n&1&&(r(0,"spk-icon",50),p(1,"password"),a())}function he(n,i){if(n&1){let t=x();r(0,"spk-icon",55),g("click",function(){C(t);let l=s(2).$implicit;return f(l.formView.showPassword=!l.formView.showPassword)}),p(1," eye "),a()}}function ye(n,i){if(n&1){let t=x();r(0,"spk-icon",55),g("click",function(){C(t);let l=s(2).$implicit;return f(l.formView.showPassword=!l.formView.showPassword)}),p(1," eye-slash "),a()}}function Ie(n,i){if(n&1&&(r(0,"spk-form-field")(1,"label",46),p(2),a(),u(3,"input",51),F(4,Ne,2,0,"span",52)(5,Re,2,0,"spk-icon",50)(6,he,2,0,"spk-icon",53)(7,ye,2,0,"spk-icon",53),a()),n&2){let t,e=s().$implicit;o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name),c("type",e.formView.showPassword?"text":"password"),o(),d(e.oauthField===e.formView.name?4:5),o(2),d(e.formView.showPassword?6:7)}}function $e(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function we(n,i){if(n&1&&(r(0,"spk-option",56),p(1),a()),n&2){let t=i.$implicit;c("value",t.value),o(),Q(" ",t.key," ",t.value?"("+t.value+")":""," ")}}function ve(n,i){if(n&1&&S(0,we,2,3,"spk-option",56,D),n&2){let t=s(2).$implicit,e=s(2);E(t.formView.loadOptions(e.injector)())}}function Ae(n,i){if(n&1&&(r(0,"spk-option",56),p(1),a()),n&2){let t=i.$implicit;c("value",t),o(),V(t)}}function Pe(n,i){if(n&1&&S(0,Ae,2,2,"spk-option",56,D),n&2){let t=s(2).$implicit;E(t.formView.options)}}function Ve(n,i){if(n&1&&(r(0,"spk-select",41)(1,"label",46),p(2),F(3,$e,3,1,"spk-tooltip",47),a(),u(4,"input",48),F(5,ve,2,0)(6,Pe,2,0),a()),n&2){let t,e=s().$implicit;c("hideClearButton",!0),o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name),o(),d(e.formView.loadOptions?5:-1),o(),d(e.formView.options?6:-1)}}function Me(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function be(n,i){if(n&1&&(r(0,"spk-option",56),p(1),a()),n&2){let t=i.$implicit;c("value",t.value),o(),Q(" ",t.key," ",t.value?"("+t.value+")":""," ")}}function Ge(n,i){if(n&1&&S(0,be,2,3,"spk-option",56,D),n&2){let t=s(2).$implicit,e=s(2);E(t.formView.loadOptions(e.injector)())}}function Be(n,i){if(n&1&&(r(0,"spk-option",56),p(1),a()),n&2){let t=i.$implicit;c("value",t),o(),V(t)}}function Le(n,i){if(n&1&&S(0,Be,2,2,"spk-option",56,D),n&2){let t=s(2).$implicit;E(t.formView.options)}}function Ue(n,i){if(n&1&&(r(0,"spk-select",42)(1,"label",46),p(2),F(3,Me,3,1,"spk-tooltip",47),a(),u(4,"input",57),F(5,Ge,2,0)(6,Le,2,0),a()),n&2){let t,e=s().$implicit;c("isFreeText",!0),o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name),o(),d(e.formView.loadOptions?5:-1),o(),d(e.formView.options?6:-1)}}function He(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function Ke(n,i){if(n&1&&(r(0,"spk-option",56),p(1),a()),n&2){let t=i.$implicit;c("value",t),o(),V(t)}}function We(n,i){if(n&1&&(r(0,"div",43)(1,"label",46),p(2),F(3,He,3,1,"spk-tooltip",47),a(),r(4,"div",58)(5,"spk-form-field"),u(6,"input",59),r(7,"spk-icon",50),p(8,"resize"),a()(),r(9,"spk-select"),u(10,"label")(11,"input",60),S(12,Ke,2,2,"spk-option",56,D),a()()()),n&2){let t,e=s().$implicit,l=s(2);c("formGroupName",e.formView.name),o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(3),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(6),E(l.sizeOptions())}}function ze(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function Xe(n,i){if(n&1&&(r(0,"spk-form-field")(1,"label",46),p(2),F(3,ze,3,1,"spk-tooltip",47),a(),u(4,"input",61),r(5,"spk-icon",50),p(6,"numpad"),a()()),n&2){let t,e=s().$implicit;o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name)}}function qe(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function je(n,i){if(n&1&&(r(0,"spk-toggle",44)(1,"label",46),p(2),F(3,qe,3,1,"spk-tooltip",47),a(),u(4,"input",62),a()),n&2){let t,e=s().$implicit;o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name)}}function Qe(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function Ze(n,i){n&1&&(r(0,"spk-option",64),p(1,"None"),a()),n&2&&c("value","None")}function Je(n,i){if(n&1&&(r(0,"spk-option",56),p(1),u(2,"spk-checkbox",65),a()),n&2){let t=s().$implicit;c("value",t),o(),O(" ",t," ")}}function Ye(n,i){if(n&1&&F(0,Ze,2,1,"spk-option",64)(1,Je,3,2,"spk-option",56),n&2){let t=i.$implicit;d(t==="None"?0:1)}}function tn(n,i){if(n&1&&(r(0,"spk-select",45)(1,"label",46),p(2),F(3,Qe,3,1,"spk-tooltip",47),a(),u(4,"input",63),S(5,Ye,2,1,null,null,D),a()),n&2){let t,e=s().$implicit;c("selectMultiple",!0),o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),y("formControlName",e.formView.name),o(),E(e.formView.options)}}function en(n,i){if(n&1&&(r(0,"spk-tooltip",47)(1,"spk-icon"),p(2,"question"),a()()),n&2){let t=s(2).$implicit;c("message",t.formView.longDescription)}}function nn(n,i){if(n&1&&(r(0,"spk-form-field")(1,"label",46),p(2),F(3,en,3,1,"spk-tooltip",47),a(),u(4,"input",48),a()),n&2){let t,e=s().$implicit;o(),T("for","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),o(),O(" ",(t=e.formView.shortDescription)!==null&&t!==void 0?t:e.formView.name," "),o(),d(e.formView.longDescription?3:-1),o(),T("id","destination-",e.formGroupName,"-",e.index,"-",e.asHttpOptions?"http":"other",""),y("formControlName",e.formView.name)}}function on(n,i){if(n&1){let t=x();r(0,"button",66),g("click",function(){C(t);let l=s().$implicit,_=s(2);return f(_.removeFormView(l.formView,0))}),r(1,"spk-icon"),p(2,"x-circle"),a()()}}function an(n,i){if(n&1&&(r(0,"div",37),v(1,38),F(2,fe,5,17,"app-file-tree",39)(3,De,5,13,"app-file-tree",40)(4,ke,8,13,"spk-form-field")(5,Ie,8,13,"spk-form-field")(6,Ve,7,14,"spk-select",41)(7,Ue,7,14,"spk-select",42)(8,We,14,11,"div",43)(9,Xe,7,11,"spk-form-field")(10,je,5,11,"spk-toggle",44)(11,tn,7,8,"spk-select",45)(12,nn,5,11,"spk-form-field"),A(),F(13,on,3,0,"button",28),a()),n&2){let t=i.$implicit;X("single-field",t.formGroupName!=="advanced"),o(),c("formGroupName",t.formGroupName),o(),d(t.formView.type==="FileTree"?2:t.formView.type==="FolderTree"?3:t.formView.type==="String"||t.formView.type==="Path"||t.formView.type==="Email"?4:t.formView.type==="Password"?5:t.formView.type==="Enumeration"?6:t.formView.type==="NonValidatedSelectableString"?7:t.formView.type==="Size"?8:t.formView.type==="Integer"?9:t.formView.type==="Boolean"?10:t.formView.type==="Flags"?11:t.formView.type==="Timespan"?12:-1),o(11),d(t.formGroupName==="advanced"?13:-1)}}function rn(n,i){if(n&1&&(v(0,19)(1,32),S(2,se,1,9,"ng-container",null,D),S(4,_e,1,9,"ng-container",null,D),r(6,"app-toggle-card",33),v(7,34),N(8,7),r(9,"spk-menu")(10,"button",35),u(11,"spk-icon"),a(),v(12,17),S(13,ce,2,1,"button",29,D),A(),a(),R(),A(),S(15,Fe,1,9,"ng-container",null,D),a(),r(17,"app-toggle-card",33),v(18,34),N(19,8),r(20,"spk-menu")(21,"button",35),u(22,"spk-icon"),a(),v(23,17),S(24,de,2,1,"button",29,D),A(),a(),R(),A(),S(26,Te,1,9,"ng-container",null,D),a(),F(28,an,14,5,"ng-template",null,1,ct),A()()),n&2){let t=s();o(2),E(t.destinationFormPair().custom),o(2),E(t.destinationFormPair().dynamic),o(2),c("disallowToggle",!0),o(4),c("disabled",t.notSelectedAdvancedFormPair().length===0),o(3),E(t.notSelectedAdvancedFormPair()),o(2),E(t.selectedAdvancedFormPair()),o(2),c("disallowToggle",!0),o(4),c("disabled",t.notSelectedHttpOptions().length===0),o(3),E(t.notSelectedHttpOptions()),o(2),E(t.selectedHttpOptions())}}function ln(n,i){if(n&1){let t=x();r(0,"spk-dialog",67),st("isOpenChange",function(l){C(t);let _=s();return lt(_.targetUrlDialogOpen,l)||(_.targetUrlDialogOpen=l),f(l)}),r(1,"header",68)(2,"h2"),b(3,9),a(),r(4,"spk-alert",69),b(5,10),a()(),r(6,"div",70)(7,"spk-form-field"),u(8,"textarea",71),a()(),r(9,"footer",72)(10,"button",21),g("click",function(){C(t);let l=s();return f(l.closeTargetUrlDialog(!1))}),p(11,"Cancel"),a(),r(12,"button",73),g("click",function(){C(t);let l=s();return f(l.closeTargetUrlDialog(!0))}),N(13,11),u(14,"spk-icon"),R(),a()()()}if(n&2){let t=s();rt("isOpen",t.targetUrlDialogOpen),c("options",_t(3,Yt)),o(8),c("formControl",t.targetUrlCtrl)}}var sn=["Bytes","KB","MB","GB","TB","PB"],W=new It,vn=(n={destinations:[]})=>W.group({destinations:W.array(n.destinations)}),An=({key:n,customGroup:i,dynamicGroup:t,advancedGroup:e})=>W.group({destinationType:W.control(n),custom:i,dynamic:t,advanced:e}),J=class n{#l=w(Tt);#s=w(ut);#p=w(dt);#t=w(Z);#i=w(Ct);#e=w(Pt);#n=w(Xt);injector=w(et);formRef=nt.required("formRef");destinationForm=this.#t.destinationForm;destinationFormPair=this.#t.destinationFormPair;selectedAdvancedFormPair=this.#t.selectedAdvancedFormPair;notSelectedAdvancedFormPair=this.#t.notSelectedAdvancedFormPair;selectedHttpOptions=this.#t.selectedHttpOptions;notSelectedHttpOptions=this.#t.notSelectedHttpOptions;destinationOptions=this.#t.destinationOptions;destinationFormSignal=this.#t.destinationFormSignal;destinationCount=K(()=>this.destinationFormSignal()?.destinations?.length??0);sizeOptions=h(sn);successfulTest=h(!1);destinationTypeOptionsInFocus=h(["file","ssh","s3","gcs","googledrive","azure"]);destinationTypeOptions=h(zt.map(i=>({key:i.customKey??i.key,customKey:i.customKey??null,displayName:i.displayName,description:i.description})));destinationTypeOptionsFocused=K(()=>{let i=this.destinationTypeOptionsInFocus(),t=this.destinationTypeOptions();return i.map(e=>t.find(l=>l.key===e))});destinationTypeOptionsNotFocused=K(()=>{let i=this.destinationTypeOptionsInFocus();return this.destinationTypeOptions().filter(e=>!i.includes(e.key))});targetUrlEffect=mt(()=>{if(this.destinationFormSignal(),this.destinationForm.valid){let i=this.#t.getCurrentTargetUrl();this.#n.updateTargetUrl(i[0])}else this.#n.updateTargetUrl(null)});ngOnInit(){let i=this.#n.destinationTargetUrl();i&&this.#t.updateFieldsFromTargetUrl(i)}getFormFieldValue(i,t,e){return((this.destinationForm.controls.destinations.controls?.[i]).controls?.[t]).controls[e].value}addDestinationFormGroup(i){this.#t.addDestinationFormGroup(i)}addAdvancedFormPair(i,t){this.#t.addAdvancedFormPair(i,t)}removeFormView(i,t){this.#t.removeAdvancedFormPair(i,t)}addHttpOption(i,t){this.#t.addHttpOption(i,t)}targetUrlCtrl=new Et;targetUrlInitial=h(null);targetUrlDialogOpen=h(!1);openTargetUrlDialog(){let t=this.#t.getCurrentTargetUrl()[0];this.targetUrlCtrl.setValue(t),this.targetUrlInitial.set(t),this.targetUrlDialogOpen.set(!0)}closeTargetUrlDialog(i=!1){this.targetUrlDialogOpen.set(!1);let t=this.targetUrlCtrl.value,e=this.targetUrlInitial();!i||t===e||this.#t.updateFieldsFromTargetUrl(this.targetUrlCtrl.value)}testDestination(i=0){let e=this.#t.getCurrentTargetUrl()[i];e&&this.#i.postApiV1RemoteoperationTest({requestBody:{path:e}}).subscribe({next:()=>{this.successfulTest.set(!0),setTimeout(()=>{this.successfulTest.set(!1)},3e3)},error:l=>{let _=l.error.error.Error;if(_==="missing-folder"&&this.#e.open(U,{data:{title:$localize`Create folder`,message:$localize`The remote destination folder does not exist, do you want to create it?`},closed:m=>{m&&this.#i.postApiV1RemoteoperationCreate({requestBody:{path:e}}).subscribe()}}),_.startsWith("incorrect-cert:")){let m=_.split("incorrect-cert:")[1];this.#e.open(U,{maxWidth:"500px",data:{title:$localize`Trust the certificate`,message:$localize`The server is using a certificate that is not trusted.
|
|
2
2
|
If this is a self-signed certificate, you can choose to trust this certificate.
|
|
3
3
|
The server reported the certificate hash: ${m}`,confirmText:"Trust the certificate",cancelText:"Cancel"},closed:k=>{k&&this.#t.addHttpOptionByName("accept-specified-ssl-hash",m)}})}if(_.startsWith("incorrect-host-key:")){let m=_.split('incorrect-host-key:"')[1].split('",')[0],k=_.split('accepted-host-key:"')[1].split('",')[0];k?this.#e.open(U,{maxWidth:"500px",data:{title:$localize`The host key has changed`,message:$localize`The host key has changed, please check with the server administrator if this is correct,
|
|
4
4
|
otherwise you could be the victim of a MAN-IN-THE-MIDDLE attack.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{c as a,d as b}from"./chunk-R5ARSI2W.js";import"./chunk-VJJVFTK5.js";import"./chunk-TLM42G2X.js";import"./chunk-NZ5QQIUJ.js";import"./chunk-TYEKJAUH.js";import"./chunk-QTTCN7A7.js";import"./chunk-QXNJFFEM.js";import"./chunk-PSJAIBCQ.js";import"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import"./chunk-X566VMXX.js";import"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";export{a as createEncryptionForm,b as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as A}from"./chunk-TYEKJAUH.js";import{b as S}from"./chunk-PSJAIBCQ.js";import{c as M}from"./chunk-UMMURHDH.js";import{o as P}from"./chunk-
|
|
1
|
+
import{b as A}from"./chunk-TYEKJAUH.js";import{b as S}from"./chunk-PSJAIBCQ.js";import{c as M}from"./chunk-UMMURHDH.js";import{o as P}from"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import"./chunk-X566VMXX.js";import{Ab as r,Bb as _,E as p,Nb as C,Oa as m,Va as c,X as o,bb as g,ec as u,fc as E,hb as d,p as l,vb as f,zb as i}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";function G(t,e){t&1&&_(0,"spk-progress-bar",1)}var a=class t{#n=o(M);#e=o(S);isLoading=c(!0);generalInfo=A(this.#e.getApiV1Acknowledgements().pipe(l(e=>e.Acknowledgements),p(()=>this.isLoading.set(!1))));static \u0275fac=function(n){return new(n||t)};static \u0275cmp=g({type:t,selectors:[["app-general"]],decls:6,vars:2,consts:()=>{let e;return e=$localize`General`,[e,[1,"indeterminate","primary"]]},template:function(n,s){n&1&&(d(0,G,1,0,"spk-progress-bar",1),i(1,"section")(2,"h3"),C(3,0),r(),i(4,"div"),u(5),r()()),n&2&&(f(s.isLoading()?0:-1),m(5),E(s.generalInfo()))},dependencies:[P],styles:["[_nghost-%COMP%]{display:block;position:relative}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0 0 1.25rem}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}section[_ngcontent-%COMP%] div[_ngcontent-%COMP%]{white-space:pre-wrap}spk-progress-bar[_ngcontent-%COMP%]{position:absolute;top:0;left:0;right:0}"],changeDetection:0})};export{a as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as k}from"./chunk-JFN26EE2.js";import"./chunk-O47LGUY4.js";import"./chunk-QXNJFFEM.js";import"./chunk-PSJAIBCQ.js";import{d as S}from"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import{a as T,g as M,h as f}from"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import"./chunk-R6C4MOOH.js";import"./chunk-X566VMXX.js";import"./chunk-BI7LIYF6.js";import{Ab as n,Bb as _,Lb as s,Mb as l,Nb as i,Oa as c,bb as D,oc as d,qb as r,zb as e}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";var E=()=>["/backup/new"],F=()=>["/backup/import"],u=class C{static \u0275fac=function(t){return new(t||C)};static \u0275cmp=D({type:C,selectors:[["app-add-backup"]],decls:23,vars:4,consts:()=>{let a;a=$localize`Add a new backup`;let t;t=$localize`New backup`;let p;p=$localize`Configure a new backup. Choose your destination, source data and schedule.`;let A;A=$localize` Add a new backup ${"\uFFFD#13\uFFFD"}:START_TAG_SPK_ICON:plus${"\uFFFD/#13\uFFFD"}:CLOSE_TAG_SPK_ICON:`;let g;g=$localize`Import from file`;let P;P=$localize`Import backup configuration from a file. During import you can adjust the setings.`;let m;return m=$localize` Import from file ${"\uFFFD#22\uFFFD"}:START_TAG_SPK_ICON:upload-simple${"\uFFFD/#22\uFFFD"}:CLOSE_TAG_SPK_ICON:`,[a,t,p,A,g,P,m,[1,"backup-types"],[1,"type-a"],["src","assets/images/new-backup.png"],["spk-button","",1,"raised","primary",3,"routerLink"]]},template:function(t,p){t&1&&(_(0,"app-status-bar"),e(1,"section")(2,"h2"),i(3,0),n(),e(4,"div",7)(5,"spk-card",8),_(6,"img",9),e(7,"h3"),i(8,1),n(),e(9,"p"),i(10,2),n(),e(11,"button",10),s(12,3),_(13,"spk-icon"),l(),n()(),e(14,"spk-card",8),_(15,"img",9),e(16,"h3"),i(17,4),n(),e(18,"p"),i(19,5),n(),e(20,"button",10),s(21,6),_(22,"spk-icon"),l(),n()()()()),t&2&&(c(11),r("routerLink",d(2,E)),c(9),r("routerLink",d(3,F)))},dependencies:[k,M,f,T,S],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;align-items:center;flex-direction:column;gap:2rem;padding:2rem 0}div.backup-types[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem;max-width:700px}spk-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;gap:1rem;padding-bottom:3rem}spk-card[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{max-width:300px}spk-card[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-wrap:balance;text-align:center;width:75%}"],changeDetection:0})};export{u as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as a,e as b,f as c}from"./chunk-
|
|
1
|
+
import{d as a,e as b,f as c}from"./chunk-TOUGWZ56.js";import"./chunk-TLM42G2X.js";import"./chunk-NZ5QQIUJ.js";import"./chunk-DNHLTHLR.js";import"./chunk-TYEKJAUH.js";import"./chunk-QTTCN7A7.js";import"./chunk-QXNJFFEM.js";import"./chunk-PSJAIBCQ.js";import"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import"./chunk-X566VMXX.js";import"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";export{a as createDestinationForm,b as createDestinationFormGroup,c as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-C6Q5SG76.js";var t=[{path:"",redirectTo:"select-files",pathMatch:"full"},{path:"destination",loadComponent:()=>import("./chunk-7ZY4AW73.js")},{path:"encryption",loadComponent:()=>import("./chunk-DNXP5WQT.js")},{path:"select-files",loadComponent:()=>import("./chunk-VBS3YNVR.js")},{path:"options",loadComponent:()=>import("./chunk-JRLAYIPU.js")}],o=t;export{o as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-C6Q5SG76.js";var o=[{path:"",redirectTo:"general",pathMatch:"full"},{path:"general",loadComponent:()=>import("./chunk-6XUGGGJW.js")},{path:"destination",loadComponent:()=>import("./chunk-ETMR6JG6.js")},{path:"source-data",loadComponent:()=>import("./chunk-NZJCL3BX.js")},{path:"schedule",loadComponent:()=>import("./chunk-PFQRJ432.js")},{path:"options",loadComponent:()=>import("./chunk-XWRLDJ4Y.js")}];export{o as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as B}from"./chunk-PSJAIBCQ.js";import{a as D,u as U}from"./chunk-
|
|
1
|
+
import{b as B}from"./chunk-PSJAIBCQ.js";import{a as D,u as U}from"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import{pa as R}from"./chunk-X566VMXX.js";import{Ab as a,Bb as u,E as S,Fb as v,Ka as T,Nb as p,Oa as l,Rb as A,Sb as c,Va as d,X as O,bb as f,ca as M,da as L,ec as _,fc as g,hb as E,jc as $,kc as k,lc as y,qb as m,rb as P,sb as h,sc as G,uc as w,vb as b,wb as N,xb as x,yb as I,zb as o}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";function X(s,n){if(s&1&&(o(0,"tr")(1,"td",10)(2,"code"),u(3,"ol",11),a()()()),s&2){let e=c().$implicit,t=c();l(),P("grid-column","1 / -1")("height","auto"),l(2),m("innerHTML",t.breakIntoLines(e.Exception),T)}}function z(s,n){if(s&1){let e=v();o(0,"tr",7),A("click",function(){let i=M(e).$index,r=c();return L(r.toggleRow(i))}),o(1,"td"),_(2),G(3,"date"),a(),o(4,"td",8),_(5),a(),o(6,"td"),_(7),a(),o(8,"td")(9,"button",9)(10,"spk-icon"),_(11,"caret-down"),a()()()(),E(12,X,4,5,"tr")}if(s&2){let e=n.$implicit,t=n.$index,i=c();l(2),g(w(3,6,e.Timestamp,"MMM dd. hh:mm")),l(3),g(e.BackupID>=0?e.BackupID:"-"),l(2),g(e.Message),l(2),h("rotated-icon",t===i.openRowIndex()),l(3),b(t===i.openRowIndex()?12:-1)}}var F=["BackupID","Timestamp","Message","actions"],C=class s{#e=O(B);displayedColumns=d(F);logsLoading=d(!0);openRowIndex=d(null);logs=d([]);ngOnInit(){this.init()}init(){this.#e.getApiV1LogdataLog().pipe(S(()=>this.logsLoading.set(!1))).subscribe({next:n=>{console.log(n),this.logs.set(n)}})}toggleRow(n){this.openRowIndex.set(n===this.openRowIndex()?null:n)}breakIntoLines(n){let e=n.split(`
|
|
2
2
|
`),t="";for(let i=0;i<e.length;i++)t+=`<li>${e[i]}</li>`;return t}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=f({type:s,selectors:[["app-logs"]],decls:15,vars:2,consts:()=>{let n;n=$localize`Timestamp`;let e;e=$localize`Backup ID`;let t;t=$localize`Message`;let i;return i=$localize`No data available`,[n,e,t,i,[3,"dataChange","data","loading"],["table-header",""],["table-no-rows",""],[3,"click"],[1,"id"],["spk-button","","type","button",1,"outlined","small"],[2,"white-space","pre-wrap"],[1,"line-numbers-ol",3,"innerHTML"]]},template:function(e,t){e&1&&(o(0,"h3"),_(1,"Logs"),a(),o(2,"spk-table",4),y("dataChange",function(r){return k(t.logs,r)||(t.logs=r),r}),o(3,"tr",5)(4,"th"),p(5,0),a(),o(6,"th"),p(7,1),a(),o(8,"th"),p(9,2),a(),u(10,"th"),a(),x(11,z,13,9,null,null,N),o(13,"div",6),p(14,3),a()()),e&2&&(l(2),$("data",t.logs),m("loading",t.logsLoading()),l(9),I(t.logs()))},dependencies:[U,R,D],styles:["[_nghost-%COMP%]{display:block}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0 0 1.25rem}spk-table[_ngcontent-%COMP%]{--table-columns: auto auto 1fr auto}spk-table[_ngcontent-%COMP%] td.id[_ngcontent-%COMP%]{justify-content:center}spk-table[_ngcontent-%COMP%] td[_ngcontent-%COMP%]:has(code){padding:1rem .75rem;overflow:hidden}spk-table[_ngcontent-%COMP%] td[_ngcontent-%COMP%]:has(code) code[_ngcontent-%COMP%]{background-color:var(--grey-800);color:var(--grey-100);padding:2.5rem 2.5rem 2.5rem 1.5rem;border-radius:var(--shape-3);overflow:auto;white-space:pre}"],changeDetection:0})};export{C as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b,d as $,e as h,h as G,l as P,o as B,p as v,r as L}from"./chunk-QXNJFFEM.js";import{b as A}from"./chunk-PSJAIBCQ.js";import{c as I,d as y}from"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import{a as w,c as V,g as x,l as X,y as U}from"./chunk-
|
|
1
|
+
import{b,d as $,e as h,h as G,l as P,o as B,p as v,r as L}from"./chunk-QXNJFFEM.js";import{b as A}from"./chunk-PSJAIBCQ.js";import{c as I,d as y}from"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import{a as w,c as V,g as x,l as X,y as U}from"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import"./chunk-X566VMXX.js";import{Ab as r,Bb as _,E as g,L as T,Lb as C,Mb as O,Nb as f,Oa as F,Qb as N,Rb as m,Va as p,X as u,bb as R,ec as M,hb as S,oc as k,qb as c,sb as D,vb as E,zb as i}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";var j=()=>["/"];function z(l,e){l&1&&(i(0,"spk-form-field")(1,"label",11),f(2,2),r(),_(3,"input",12),r())}var a=new v,d=class l{#t=u(V);#e=u(A);#o=u(I);isRestoring=p(!1);isSecureFile=p(!1);importForm=a.group({config:a.control(""),cmdline:a.control(!1),importMetadata:a.control(!1),direct:a.control(!1),passphrase:a.control("")});selectedFile=p(null);onFileDropped(e){let t=e.target?.files?.item(0);if(t){let n=new FileReader;this.isSecureFile.set(t.type!=="application/json"),n.onload=this.#n.bind(this),n.readAsArrayBuffer(t)}}#n(e){let o=e.target?.result;this.importForm.patchValue({config:this.#r(o)})}#r(e){let o=new Uint8Array(e),t=o.byteLength,n="";for(let s=0;s<t;s++)n+=String.fromCharCode(o[s]);return btoa(n)}submit(){this.isRestoring.set(!0),this.#e.postApiV1BackupsImport({requestBody:this.importForm.value}).pipe(T(e=>this.#e.postApiV1Backups({requestBody:e.data,temporary:!0})),g(()=>this.isRestoring.set(!1))).subscribe({next:e=>{console.log("/restore-draft",e.ID),this.#o.navigate(["/restore-draft",e.ID])},error:e=>{this.#t.error(e.message)}})}static \u0275fac=function(o){return new(o||l)};static \u0275cmp=R({type:l,selectors:[["app-restore-from-config"]],decls:16,vars:7,consts:()=>{let e;e=$localize` Restore from config ${"\uFFFD#3\uFFFD"}:START_TAG_DIV:${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"[\uFFFD#5\uFFFD|\uFFFD#7\uFFFD]"}:START_TAG_SPK_ICON:arrow-left${"[\uFFFD/#5\uFFFD|\uFFFD/#7\uFFFD]"}:CLOSE_TAG_SPK_ICON: Back ${"[\uFFFD/#4\uFFFD|\uFFFD/#6\uFFFD]"}:CLOSE_TAG_BUTTON:${"\uFFFD#6\uFFFD"}:START_TAG_BUTTON_1:${"[\uFFFD#5\uFFFD|\uFFFD#7\uFFFD]"}:START_TAG_SPK_ICON:download-simple${"[\uFFFD/#5\uFFFD|\uFFFD/#7\uFFFD]"}:CLOSE_TAG_SPK_ICON: Restore ${"[\uFFFD/#4\uFFFD|\uFFFD/#6\uFFFD]"}:CLOSE_TAG_BUTTON:${"\uFFFD/#3\uFFFD"}:CLOSE_TAG_DIV:`,e=N(e);let o;o=$localize`Select a configuration file`;let t;return t=$localize`Passphrase`,[e,o,t,[1,"actions"],["spk-button","","type","button",1,"outlined",3,"routerLink"],["spk-button","","type","submit",1,"raised","primary",3,"click","disabled"],["autocomplete","off",3,"formGroup"],["spkDragDrop","",3,"fileDropped"],["for","file"],["type","file","accept",".json,.aes",3,"change"],["suffix",""],["for","passphrase"],["type","password","formControlName","passphrase"]]},template:function(o,t){o&1&&(i(0,"header")(1,"h3"),C(2,0),i(3,"div",3)(4,"button",4),_(5,"spk-icon"),r(),i(6,"button",5),m("click",function(){return t.submit()}),_(7,"spk-icon"),r()(),O(),r()(),i(8,"form",6)(9,"spk-form-field",7),m("fileDropped",function(s){return t.onFileDropped(s)}),i(10,"label",8),f(11,1),r(),i(12,"input",9),m("change",function(s){return t.onFileDropped(s)}),r(),i(13,"spk-icon",10),M(14,"upload"),r()(),S(15,z,4,0,"spk-form-field"),r()),o&2&&(F(4),c("routerLink",k(6,j)),F(2),D("loader",t.isRestoring()),c("disabled",t.isRestoring()),F(2),c("formGroup",t.importForm),F(7),E(t.isSecureFile()?15:-1))},dependencies:[L,G,b,$,h,P,B,y,U,X,w,x],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:2rem;padding:3rem}h3[_ngcontent-%COMP%]{font:var(--title-30);display:flex;align-items:center;justify-content:space-between}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;max-width:31.25rem}"],changeDetection:0})};export{d as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as M}from"./chunk-JWC6WDAE.js";import"./chunk-XCS7POXG.js";import"./chunk-PSJAIBCQ.js";import"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import{g as h}from"./chunk-
|
|
1
|
+
import{a as M}from"./chunk-JWC6WDAE.js";import"./chunk-XCS7POXG.js";import"./chunk-PSJAIBCQ.js";import"./chunk-B5F2IYXZ.js";import"./chunk-UMMURHDH.js";import{g as h}from"./chunk-YFA44VRS.js";import"./chunk-U5DDVNLJ.js";import"./chunk-X566VMXX.js";import{Ab as i,Bb as g,Nb as l,Oa as u,Tb as C,Ub as c,X as m,bb as s,ec as O,hb as _,vb as f,zb as t}from"./chunk-NHACGZPI.js";import"./chunk-C6Q5SG76.js";var v=["*",[["","footer",""]]],T=["*","[footer]"],r=class n{static \u0275fac=function(e){return new(e||n)};static \u0275cmp=s({type:n,selectors:[["app-custom-card"]],ngContentSelectors:T,decls:11,vars:0,consts:[[1,"card"],["src","/assets/noise/auth-noise.svg",1,"noise"],[1,"header-title"],["src","/assets/duplicati/duplicati.svg","alt",""],[1,"bg"]],template:function(e,a){e&1&&(C(v),t(0,"div",0),g(1,"img",1),t(2,"header")(3,"div",2),g(4,"img",3),O(5," Duplicati "),i()(),t(6,"main"),c(7),t(8,"footer"),c(9,1),i()()(),g(10,"div",4))},styles:['[_nghost-%COMP%]{height:100vh;width:100vw;display:flex;align-items:center;justify-content:center;background-color:var(--base-level-20)}body.dark [_nghost-%COMP%] .card[_ngcontent-%COMP%]:before{background:radial-gradient(rgba(var(--primary-rgb-900),1),#0000 60%)}.card[_ngcontent-%COMP%]{max-width:480px;width:100%;position:relative;z-index:100;background-color:var(--base-level-10);border-radius:var(--shape-5);box-shadow:var(--box-shadow-40);border:1px solid var(--base-level-30);overflow:hidden}.card[_ngcontent-%COMP%]:before{content:"";position:absolute;height:480px;transform:translateY(-285px);left:0;right:0;z-index:-2;background:radial-gradient(rgba(var(--primary-rgb-100),1),#0000 60%)}.card[_ngcontent-%COMP%] img.noise[_ngcontent-%COMP%]{position:absolute;height:480px;width:100%;transform:translateY(-285px);left:0;right:0;z-index:-1;mask-image:radial-gradient(#000,#0000 60%)}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;padding:2rem 2rem 0;gap:12px;position:relative;z-index:10}.header-title[_ngcontent-%COMP%]{font:var(--title-30);display:flex;align-items:center;gap:10px}.header-title[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{height:28px;filter:drop-shadow(0 2px 3px rgba(0,0,0,.3))}main[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;padding:2rem;gap:2.5rem;position:relative;z-index:10}main[_ngcontent-%COMP%] footer[_ngcontent-%COMP%]{font:var(--paragraph-40);color:var(--base-level-60R);text-align:center;text-wrap:balance}.bg[_ngcontent-%COMP%]{position:fixed;inset:0;width:100vw;height:100vh;background-image:url(/assets/backgrounds/base-bg.svg);background-size:cover;background-position:center;background-repeat:no-repeat}body.dark[_ngcontent-%COMP%] .bg[_ngcontent-%COMP%]{opacity:1}footer[_ngcontent-%COMP%]:empty{display:none}'],changeDetection:0})};function x(n,o){n&1&&(t(0,"h3"),l(1,0),i())}function y(n,o){n&1&&(t(0,"h3"),l(1,1),i(),t(2,"button",3),l(3,2),i())}var d=class n{#e=m(M);isLoggingOut=this.#e.isLoggingOut;ngOnInit(){this.#e.logout()}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=s({type:n,selectors:[["app-logout"]],decls:3,vars:1,consts:()=>{let o;o=$localize`Logging out...`;let e;e=$localize`You have successfully logged out your being redirected to login page.`;let a;return a=$localize`Go to login page`,[o,e,a,["spk-button","","routerLink","/",1,"raised","primary"]]},template:function(e,a){e&1&&(t(0,"app-custom-card"),_(1,x,2,0,"h3")(2,y,4,0),i()),e&2&&(u(),f(a.isLoggingOut()?1:2))},dependencies:[r,h],styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})};export{d as default};
|