@duplicati/ngclient 0.0.177 → 0.0.179
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/dest-icons/dincloud.png +0 -0
- package/assets/dest-icons/dreamhost.png +0 -0
- package/assets/dest-icons/dunkel.png +0 -0
- package/assets/dest-icons/duplicati.png +0 -0
- package/assets/dest-icons/hosteurope.png +0 -0
- package/assets/dest-icons/ibmcos.png +0 -0
- package/assets/dest-icons/impossiblecloud.png +0 -0
- package/assets/dest-icons/infomaniak.png +0 -0
- package/assets/dest-icons/polisystems.png +0 -0
- package/assets/dest-icons/rabata.png +0 -0
- package/assets/dest-icons/sakuracloud.png +0 -0
- package/assets/dest-icons/scaleway.png +0 -0
- package/assets/dest-icons/seagatelyve.png +0 -0
- package/assets/dest-icons/storadera.png +0 -0
- package/assets/dest-icons/wasabi.png +0 -0
- package/assets/sh.woff2 +0 -0
- package/chunk-2HZ7VZ3D.js +1 -0
- package/{chunk-AJMSZFGR.js → chunk-2LAZMIL4.js} +1 -1
- package/{chunk-M7SLT3MF.js → chunk-2U23BDRP.js} +1 -1
- package/chunk-3CCAGUTG.js +1 -0
- package/{chunk-MIUFEQ3S.js → chunk-4F7BBMQ2.js} +1 -1
- package/{chunk-WNOXOC4X.js → chunk-4JVBYGOM.js} +1 -1
- package/{chunk-PW55LN2T.js → chunk-55RRXYNB.js} +1 -1
- package/{chunk-Y4IW22ZU.js → chunk-6AX4L2U5.js} +1 -1
- package/chunk-6GJYSOXJ.js +1 -0
- package/{chunk-JTZ2JEV4.js → chunk-6WVN2KRC.js} +1 -1
- package/{chunk-6CYY2QG6.js → chunk-7XLQX4B6.js} +1 -1
- package/{chunk-G4FG3YUE.js → chunk-C6LHWLWL.js} +1 -1
- package/chunk-CM6KCZ6Q.js +1 -0
- package/{chunk-JTQDY6AH.js → chunk-D47P7LFF.js} +1 -1
- package/{chunk-WHLIHNEE.js → chunk-DNNNVTJK.js} +1 -1
- package/chunk-DV67LYLW.js +2 -0
- package/{chunk-YQSTMC2K.js → chunk-FEBDZE5A.js} +1 -1
- package/{chunk-NEQW3H7F.js → chunk-FHO4PDLK.js} +1 -1
- package/{chunk-PNECF7JS.js → chunk-HC6NRM4H.js} +1 -1
- package/chunk-HDM6ELAR.js +1 -0
- package/chunk-HEV3WHAH.js +1 -0
- package/{chunk-VSLN6R7K.js → chunk-HGZYRAXZ.js} +1 -1
- package/chunk-HPU4SX5Z.js +1 -0
- package/chunk-I77LGXJN.js +2 -0
- package/{chunk-76LEHUPM.js → chunk-IE7RK4YW.js} +1 -1
- package/chunk-IQI7X3JY.js +2 -0
- package/chunk-JKDYRSAH.js +1 -0
- package/{chunk-N4ADMNNU.js → chunk-JRFX5D6S.js} +1 -1
- package/chunk-JRMY6F6W.js +1 -0
- package/chunk-JSYVSJJU.js +1 -0
- package/{chunk-UT542KNO.js → chunk-L37SKX3M.js} +1 -1
- package/chunk-LVPZTSKG.js +1 -0
- package/{chunk-5HQJVUNE.js → chunk-MVPMVVRC.js} +1 -1
- package/chunk-PNYEL323.js +1 -0
- package/{chunk-AO4ZIHUL.js → chunk-QNZTEY37.js} +1 -1
- package/chunk-RIVMPP47.js +1 -0
- package/chunk-SYMBRSKN.js +7 -0
- package/{chunk-WLXOWWZB.js → chunk-T7XH5JIZ.js} +1 -1
- package/chunk-TOB4ESNO.js +1 -0
- package/{chunk-5MXXIFJM.js → chunk-U5GRFEV3.js} +1 -1
- package/chunk-UTLK72CH.js +1 -0
- package/{chunk-U4T4BSPF.js → chunk-VYIUFXYO.js} +1 -1
- package/chunk-WGXHTY3T.js +1 -0
- package/{chunk-PJLZ7V22.js → chunk-WPT4ETG3.js} +1 -1
- package/chunk-XECFWVLT.js +1 -0
- package/index.html +42 -1
- package/main-CMSRKMLS.js +1 -0
- package/package.json +1 -1
- package/assets/favicon.ico +0 -0
- package/chunk-27UON6YV.js +0 -2
- package/chunk-4IUPBI2K.js +0 -1
- package/chunk-5UXRNNTT.js +0 -1
- package/chunk-6O5DBV6Y.js +0 -1
- package/chunk-7IQ5FSGI.js +0 -1
- package/chunk-EBKB4YCL.js +0 -1
- package/chunk-F3RWB4I6.js +0 -1
- package/chunk-H6UYYWCU.js +0 -1
- package/chunk-J5LEAYPL.js +0 -1
- package/chunk-KR56GPXG.js +0 -2
- package/chunk-PCLJOXMF.js +0 -1
- package/chunk-PUOOECEB.js +0 -1
- package/chunk-QZJ7QZZ4.js +0 -1
- package/chunk-R6XDJFPE.js +0 -1
- package/chunk-SS7TCWY5.js +0 -1
- package/chunk-TXPM764C.js +0 -1
- package/chunk-WS7QWRRY.js +0 -1
- package/chunk-WWIKIIGV.js +0 -7
- package/chunk-WWIXPGSZ.js +0 -1
- package/chunk-XRXXVFJ4.js +0 -1
- package/chunk-XZZDJCRM.js +0 -1
- package/main-OOXK65IC.js +0 -1
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/assets/sh.woff2
CHANGED
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{g as he}from"./chunk-MVPMVVRC.js";import{a as Ne,b as pe,c as Ie,d as me,e as De}from"./chunk-SYMBRSKN.js";import"./chunk-I77LGXJN.js";import"./chunk-T5LLH46J.js";import{b as Oe,c as Ce}from"./chunk-DV67LYLW.js";import{j as Re}from"./chunk-3CCAGUTG.js";import"./chunk-GMNCWLGX.js";import"./chunk-B5LH4P4E.js";import"./chunk-TJYZBTTS.js";import"./chunk-6Q6SSTBK.js";import"./chunk-U63HBLGG.js";import"./chunk-LVPZTSKG.js";import"./chunk-AGPZBYW6.js";import{a as I}from"./chunk-WILUKPQ3.js";import"./chunk-RIVMPP47.js";import"./chunk-FBWFZMGL.js";import"./chunk-PNYEL323.js";import"./chunk-NEV6JB5M.js";import"./chunk-QWNOPLJC.js";import{B as de,H as ue,K as Fe,c as oe,e as ae,f as se,g as re,i as _e,j as le,s as ce,u as Te,w as Ee,y as Se,z as ge}from"./chunk-RYXU2QDS.js";import"./chunk-BKANUILG.js";import{b as ne,d as ie}from"./chunk-GO4NSDR6.js";import"./chunk-56FBKSBN.js";import"./chunk-FIBRO5I3.js";import"./chunk-RMOTUTEQ.js";import"./chunk-QF5K4MHH.js";import{$ as T,Ab as r,Bb as d,Fb as K,Gb as j,Ib as C,Mc as A,Pa as l,Pb as S,Qb as g,Rb as p,Sb as P,Sc as te,Tb as $,Ub as Q,Vb as u,W as R,Xb as _,aa as E,cb as H,cc as q,da as X,dc as Y,jc as L,la as N,oc as h,pc as f,qc as M,rc as y,sb as F,sc as x,tb as O,tc as w,wc as Z,xc as ee,yb as D,zb as s}from"./chunk-XYHHESIX.js";import"./chunk-7CGTOI24.js";var fe=["formRef"],Me=()=>({maxWidth:"700px",width:"100%"});function Ae(o,n){if(o&1){let e=C();s(0,"button",31),u("click",function(){T(e);let t=_();return E(t.testDestination(0,!0))}),p(1,4),r()}if(o&2){let e=_();D("disabled",e.testSignal()=="testing")}}function Pe(o,n){if(o&1){let e=C();s(0,"button",32),u("click",function(){T(e);let t=_();return E(t.openTargetUrlDialog())}),S(1,5),d(2,"sh-icon"),g(),r()}}function $e(o,n){if(o&1){let e=C();s(0,"button",32),u("click",function(){T(e);let t=_(2);return E(t.copyTargetUrl())}),S(1,7),d(2,"sh-icon"),g(),r()}}function Le(o,n){if(o&1){let e=C();s(0,"sh-menu")(1,"button",20)(2,"sh-icon"),L(3,"dots-three-vertical"),r()(),K(4,33),s(5,"button",32),u("click",function(){T(e);let t=_();return E(t.openTargetUrlDialog())}),S(6,6),d(7,"sh-icon"),g(),r(),F(8,$e,3,0,"button",20),j(),r()}if(o&2){_();let e=w(0);l(8),O(e?8:-1)}}function ye(o,n){o&1&&(s(0,"sh-alert"),S(1,8),d(2,"sh-icon",34),g(),r())}function xe(o,n){o&1&&(s(0,"sh-alert",21),S(1,9),d(2,"sh-icon",34),g(),r())}function we(o,n){if(o&1&&(s(0,"sh-alert",22),S(1,10),d(2,"sh-icon",34),g(),r()),o&2){let e=_();l(2),P(e.testErrorMessage()),$(1)}}function Ge(o,n){if(o&1&&(s(0,"sh-alert",23),S(1,11),d(2,"sh-icon",34),g(),r()),o&2){let e=_();l(2),P(e.testErrorMessage()),$(1)}}function be(o,n){if(o&1){let e=C();s(0,"app-destination-list-item",24)(1,"button",27),u("click",function(){T(e);let t=_();return E(t.removeDestination())}),p(2,12),r()()}if(o&2){_();let e=w(15);D("destination",e)}}function Ue(o,n){if(o&1){let e=C();s(0,"app-destination-list",35),u("setDestination",function(t){T(e);let a=_();return E(a.setDestination(t))}),r()}}function ke(o,n){if(o&1){let e=C();s(0,"app-single-destination",36),M("targetUrlChange",function(t){T(e);let a=_();return f(a.targetUrlModel,t)||(a.targetUrlModel=t),E(t)}),r()}if(o&2){let e=_();h("targetUrl",e.targetUrlModel)}}function ve(o,n){o&1&&(S(0,3,1),d(1,"sh-icon",29),g())}function We(o,n){o&1&&(S(0,3,2),d(1,"sh-icon"),g())}function Ve(o,n){if(o&1){let e=C();s(0,"sh-dialog",37),M("isOpenChange",function(t){T(e);let a=_();return f(a.targetUrlDialogOpen,t)||(a.targetUrlDialogOpen=t),E(t)}),s(1,"header",38)(2,"div",39)(3,"h2"),p(4,13),r(),s(5,"sh-alert",22),p(6,14),r()()(),s(7,"div",40)(8,"sh-form-field")(9,"textarea",41),M("ngModelChange",function(t){T(e);let a=_();return f(a.targetUrlCtrl,t)||(a.targetUrlCtrl=t),E(t)}),r()()(),s(10,"footer",42)(11,"button",27),u("click",function(){T(e);let t=_();return E(t.closeTargetUrlDialog(!1))}),L(12,"Cancel"),r(),s(13,"button",43),u("click",function(){T(e);let t=_();return E(t.closeTargetUrlDialog(!0))}),S(14,15),d(15,"sh-icon"),g(),r()()()}if(o&2){let e=_();h("isOpen",e.targetUrlDialogOpen),D("options",ee(3,Me)),l(9),h("ngModel",e.targetUrlCtrl)}}var G=class o{#i=R(ie);#o=R(ne);#t=R(ge);#a=R(Ne);injector=R(X);#e=R(he);#s=R(Ie);formRef=te.required("formRef");targetUrlModel=this.#e.destinationTargetUrl;targetUrlCtrl=N(null);targetUrlInitial=N(null);targetUrlDialogOpen=N(!1);toggleNewDestination=N(!0);testSignal=this.#e.testSignal;testErrorMessage=this.#e.testErrorMessage;destinationTypeOptionsInFocus=N(["file","ssh","s3","gcs","googledrive","azure"]);destinationTypeOptions=this.#s.destinationTypeOptions;destinationTypeOptionsFocused=A(()=>{let n=this.destinationTypeOptionsInFocus(),e=this.destinationTypeOptions();return n.map(i=>e.find(t=>t.key===i))});selectedDestinationType=A(()=>{let n=this.#e.destinationTargetUrl();return n?Oe(n):null});selectedDestinationTypeOption=A(()=>{let n=this.selectedDestinationType();return n?{key:n.customKey??n.key,customKey:n.customKey??null,displayName:n.displayName,description:n.description,icon:n.icon}:null});copyTargetUrl(){navigator.clipboard.writeText(this.#e.destinationTargetUrl()??"")}openTargetUrlDialog(){let n=this.#e.destinationTargetUrl();this.targetUrlCtrl.set(n),this.targetUrlInitial.set(n),this.targetUrlDialogOpen.set(!0)}closeTargetUrlDialog(n=!1){this.targetUrlDialogOpen.set(!1);let e=this.targetUrlCtrl(),i=this.targetUrlInitial();!n||e===i||!e||this.#e.updateTargetUrl(e)}testDestination(n,e,i){let t=this.#e.destinationTargetUrl();t&&(this.#e.setTestState("testing"),this.#a.testDestination(t,this.#e.backupId(),n,!0,e).subscribe({next:a=>{if(a.action==="success"){this.#e.setTestState("success"),a.containsBackup===!1?(this.#e.setTestState("warning",$localize`The remote destination does not contain any backups. Please check if the destination details are correct.`),e||this.#t.open(I,{data:{title:$localize`Folder contains no backup`,message:$localize`The remote destination does not contain any backups. Please check if the destination details are correct.`,confirmText:$localize`OK`,cancelText:void 0}})):a.anyFilesFound===!1&&(this.#e.setTestState("warning",$localize`The remote destination is empty. Please check if the destination details are correct.`),e||this.#t.open(I,{data:{title:$localize`Folder is empty`,message:$localize`The remote destination is empty. Please check if the destination details are correct.`,confirmText:$localize`OK`,cancelText:void 0}})),i?.();return}if(this.#e.setTestState("error",a.errorMessage??$localize`An error occurred while testing the destination.`),a.action==="generic-error"){i?.();return}let m=t.includes("?");a.action==="trust-cert"&&this.#e.updateTargetUrl(t+`${m?"&":"?"}accept-specified-ssl-hash=${a.certData}`),a.action==="approve-host-key"&&this.#e.updateTargetUrl(t+`${m?"&":"?"}ssh-fingerprint=${a.reportedHostKey}`),a.testAgain?this.testDestination(a.destinationIndex,e):i?.()}}))}setDestination(n){let e=Ce(n??"");if(e){if(e.mapper.default){let i=e.mapper.default("");this.#e.updateTargetUrl(i);return}this.#e.updateTargetUrl(`${n}://`)}}removeDestination(){this.#e.updateTargetUrl(null)}goBack(){this.#i.navigate(["general"],{relativeTo:this.#o.parent})}next(){let n=this.testSignal();if(n===""){this.#t.open(I,{data:{title:$localize`Test destination`,message:$localize`You have not tested the destination yet. Do you want to test it now?`,confirmText:$localize`Test now`,cancelText:$localize`Skip test and continue`},closed:e=>{e?this.testDestination(0,!1,()=>{this.testSignal()==="success"?this.#n():this.#t.open(I,{data:{title:$localize`Test did not succeed`,message:this.testErrorMessage()??$localize`Failed to test the destination.`,confirmText:$localize`OK`,cancelText:void 0}})}):this.#n()}});return}if(n!=="success"){this.#t.open(I,{data:{title:$localize`Test destination`,message:$localize`The destination has not been tested successfully. Are you sure you want to continue?`,confirmText:$localize`Yes, continue`,cancelText:$localize`Cancel`},closed:e=>{e&&this.#n()}});return}this.#n()}#n(){this.#i.navigate(["encryption"],{relativeTo:this.#o.parent})}static \u0275fac=function(e){return new(e||o)};static \u0275cmp=H({type:o,selectors:[["app-restore-destination"]],viewQuery:function(e,i){e&1&&q(i.formRef,fe,5),e&2&&Y()},features:[Z([Re])],decls:28,vars:11,consts:()=>{let n;n=$localize`Backup destination`;let e;e=$localize`${"\uFFFD#22\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#22\uFFFD"}:CLOSE_TAG_SH_ICON: Go back `;let i;i=$localize`${"\uFFFD*25:1\uFFFD"}:START_BLOCK_IF:${"\uFFFD#1:1\uFFFD"}:START_TAG_SH_ICON:spinner${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*25:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*26:2\uFFFD"}:START_BLOCK_ELSE:${"\uFFFD#1:2\uFFFD"}:START_TAG_SH_ICON_1:arrow-right${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*26:2\uFFFD"}:CLOSE_BLOCK_ELSE: Continue `,i=Q(i);let t;t=$localize` Test destination `;let a;a=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:link${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Set target URL `;let m;m=$localize`${"\uFFFD#7\uFFFD"}:START_TAG_SH_ICON:link${"\uFFFD/#7\uFFFD"}:CLOSE_TAG_SH_ICON: Edit target URL `;let b;b=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:copy${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Copy URL to clipboard `;let U;U=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:spinner${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Testing connection... `;let k;k=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:check${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Connection tested successfully. `;let v;v=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:warning${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: ${"\uFFFD0\uFFFD"}:INTERPOLATION: `;let W;W=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:warning${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: ${"\uFFFD0\uFFFD"}:INTERPOLATION: `;let V;V=$localize`Change`;let B;B=$localize`Edit target URL`;let z;z=$localize`Be careful, this will overwrite everything you have in your destination.`;let J;return J=$localize` Override target URL ${"\uFFFD#15\uFFFD"}:START_TAG_SH_ICON:swap${"\uFFFD/#15\uFFFD"}:CLOSE_TAG_SH_ICON:`,[["formRef",""],n,e,i,t,a,m,b,U,k,v,W,V,B,z,J,[3,"submit"],[1,"title-30"],[1,"actions"],["shButton","","type","button",1,"small",3,"disabled"],["shButton","","type","button",1,"small"],[1,"success"],[1,"warn"],[1,"error"],[1,"current-destination",3,"destination"],[3,"targetUrl"],[1,"form-actions"],["shButton","","type","button",3,"click"],["shButton","","type","submit",1,"raised","primary",3,"disabled"],[1,"loader"],[3,"isOpen","options"],["shButton","","type","button",1,"small",3,"click","disabled"],["shButton","","type","button",1,"small",3,"click"],["menu",""],["icon",""],[3,"setDestination"],[3,"targetUrlChange","targetUrl"],[3,"isOpenChange","isOpen","options"],["header",""],[1,"target-dialog-header"],["content",""],["id","targetUrl","autocomplete","off",3,"ngModelChange","ngModel"],["footer",""],["shButton","","type","submit",1,"raised","primary",3,"click"]]},template:function(e,i){if(e&1){let t=C();y(0),s(1,"form",16,0),u("submit",function(){return T(t),E(i.next())}),s(3,"header")(4,"h3",17)(5,"span"),p(6,1),r(),s(7,"div",18),F(8,Ae,2,1,"button",19),F(9,Pe,3,0,"button",20)(10,Le,9,1,"sh-menu"),r()(),F(11,ye,3,0,"sh-alert")(12,xe,3,0,"sh-alert",21)(13,we,3,1,"sh-alert",22)(14,Ge,3,1,"sh-alert",23),y(15),F(16,be,3,1,"app-destination-list-item",24),r(),F(17,Ue,1,0,"app-destination-list"),F(18,ke,1,1,"app-single-destination",25),s(19,"div",26)(20,"button",27),u("click",function(){return T(t),E(i.goBack())}),S(21,2),d(22,"sh-icon"),g(),r(),s(23,"button",28),S(24,3),F(25,ve,2,0,"sh-icon",29)(26,We,2,0,"sh-icon"),g(),r()()(),F(27,Ve,16,4,"sh-dialog",30)}if(e&2){let t=x(!!i.targetUrlModel());l(8),O(t?8:-1),l(),O(t?10:9),l(2),O(i.testSignal()=="testing"?11:i.testSignal()=="success"?12:i.testSignal()=="warning"?13:i.testSignal()=="error"?14:-1),l(4);let a=x(i.selectedDestinationTypeOption());l(),O(a?16:-1),l(),O(t?-1:17),l(),O(t?18:-1),l(5),D("disabled",i.testSignal()=="testing"||!t),l(2),O(i.testSignal()=="testing"?25:26),l(2),O(i.targetUrlDialogOpen()?27:-1)}},dependencies:[De,me,pe,ce,le,oe,ae,se,_e,re,de,ue,Fe,Te,Se,Ee],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:40rem}header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%], header[_ngcontent-%COMP%] sh-alert[_ngcontent-%COMP%]{width:100%}header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;gap:.5rem}header[_ngcontent-%COMP%] p[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{cursor:pointer;text-decoration:underline}header[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}pre[_ngcontent-%COMP%]{white-space:pre-wrap}.field-row[_ngcontent-%COMP%]{display:grid;align-items:flex-end;grid-template-columns:1fr 2.5rem;gap:.5rem}.field-row.single-field[_ngcontent-%COMP%]{display:block}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}.clickable[_ngcontent-%COMP%]{cursor:pointer;color:var(--primary-8)}.most-common-destinations[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem}.most-common-destinations[_ngcontent-%COMP%] .tile[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;padding:1rem;border:1px solid var(--base-4);border-radius:var(--shape-3);box-shadow:var(--box-shadow-10);background-color:var(--base-2);cursor:pointer}.most-common-destinations[_ngcontent-%COMP%] .tile[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-10);margin:0}[prefix].link[_ngcontent-%COMP%]{cursor:pointer;text-decoration:underline;color:var(--primary-8)}textarea[_ngcontent-%COMP%] ~ grammarly-extension[_ngcontent-%COMP%]{display:none}.target-dialog-header[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;justify-content:space-between;gap:.5rem}"],changeDetection:0})};export{G as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as Xe}from"./chunk-XRXXVFJ4.js";import{a as ee}from"./chunk-D7TCA6E7.js";import"./chunk-6CYY2QG6.js";import"./chunk-AJXTVI3H.js";import"./chunk-LF24JF3M.js";import{a as Ke}from"./chunk-AO4ZIHUL.js";import"./chunk-SS7TCWY5.js";import"./chunk-6Q6SSTBK.js";import{a as Z}from"./chunk-U63HBLGG.js";import"./chunk-4IUPBI2K.js";import"./chunk-AGPZBYW6.js";import"./chunk-WILUKPQ3.js";import"./chunk-NEV6JB5M.js";import"./chunk-CGKL2MHM.js";import"./chunk-QWNOPLJC.js";import"./chunk-5UXRNNTT.js";import{b as Je,c as ce}from"./chunk-FBWFZMGL.js";import{B as se,E as Be,G as be,L as Fe,U as ke,V as Ue,u as H}from"./chunk-RYXU2QDS.js";import{b as de}from"./chunk-BKANUILG.js";import{b as ye,e as xe}from"./chunk-GO4NSDR6.js";import"./chunk-56FBKSBN.js";import"./chunk-FIBRO5I3.js";import{la as V,oa as re}from"./chunk-RMOTUTEQ.js";import"./chunk-QF5K4MHH.js";import{$ as D,Ab as i,Bb as s,Cc as u,Dc as L,Ec as S,Fb as G,Fc as h,Gb as P,Ib as U,Mc as ve,Pa as a,Pb as N,Qb as m,Rb as l,Rc as le,Sb as d,Tb as c,Ub as R,Vb as I,W as x,Xb as C,aa as M,cb as X,gc as $,jc as E,kc as K,la as A,lc as f,mc as Ie,nc as $e,p as J,rc as fe,sb as g,sc as he,tb as T,tc as w,ub as B,wb as b,xb as k,yb as z,zb as o}from"./chunk-XYHHESIX.js";import{a as _e}from"./chunk-7CGTOI24.js";function Ve(n,t){n&1&&s(0,"sh-progress-bar",32)}function He(n,t){n&1&&s(0,"div",35)}function je(n,t){n&1&&s(0,"div",35)}function We(n,t){n&1&&s(0,"div",36)}function qe(n,t){n&1&&s(0,"div",37)}function Qe(n,t){if(n&1&&(o(0,"details",46)(1,"summary"),N(2,15),s(3,"sh-icon"),o(4,"div",47),s(5,"sh-icon",40),i(),m(),i(),o(6,"div",48)(7,"p"),l(8,16),u(9,"date"),i(),o(10,"p"),l(11,17),u(12,"date"),i(),o(13,"p"),l(14,18),u(15,"durationFormat"),i(),o(16,"p"),l(17,19),i(),s(18,"sh-divider"),o(19,"p"),l(20,20),i(),o(21,"p"),l(22,21),i()()(),o(23,"details",46)(24,"summary"),N(25,22),s(26,"sh-icon"),o(27,"div",47),s(28,"sh-icon",40),i(),m(),i(),o(29,"div",48)(30,"p"),l(31,23),u(32,"date"),i(),o(33,"p"),l(34,24),u(35,"date"),i(),o(36,"p"),l(37,25),u(38,"durationFormat"),i(),s(39,"sh-divider"),o(40,"p"),l(41,26),u(42,"bytes"),i(),o(43,"p"),l(44,27),u(45,"bytes"),i(),o(46,"p"),l(47,28),u(48,"bytes"),i(),s(49,"sh-divider"),o(50,"p"),l(51,29),i(),o(52,"p"),l(53,30),i()()()),n&2){let e=C(2).$implicit;a(9),d(S(9,17,e.data==null||e.data.TestResults==null?null:e.data.TestResults.BeginTime,"medium")),c(8),a(3),d(S(12,20,e.data==null||e.data.TestResults==null?null:e.data.TestResults.EndTime,"medium")),c(11),a(3),d(L(15,23,e.data==null||e.data.TestResults==null?null:e.data.TestResults.Duration)),c(14),a(2),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.VerificationsActualLength),c(17),a(3),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.WarningsActualLength),c(20),a(2),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.ErrorsActualLength),c(22),a(10),d(S(32,25,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.BeginTime,"medium")),c(31),a(3),d(S(35,28,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.EndTime,"medium")),c(34),a(3),d(L(38,31,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.Duration)),c(37),a(4),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DeletedFileCount)(h(42,33,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DeletedFileSize,!0,!0)),c(41),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DownloadedFileCount)(h(45,37,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DownloadedFileSize,!0,!0)),c(44),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.UploadedFileCount)(h(48,41,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.UploadedFileSize,!0,!0)),c(47),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.WarningsActualLength),c(51),a(2),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.ErrorsActualLength),c(53)}}function Ye(n,t){if(n&1&&(o(0,"code"),E(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),K(L(2,1,e))}}function Ze(n,t){if(n&1&&(o(0,"details",46)(1,"summary"),N(2,31),s(3,"sh-icon"),o(4,"div",47),s(5,"sh-icon",40),i(),m(),i(),o(6,"div",48),b(7,Ye,3,3,"code",null,B),i()()),n&2){let e=C(2).$implicit;a(5),d(e.data.VerificationsActualLength),c(2),a(2),k(e.data.Verifications)}}function en(n,t){if(n&1&&(o(0,"code"),E(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),K(L(2,1,e))}}function nn(n,t){n&1&&(o(0,"p"),E(1,"No errors"),i())}function tn(n,t){if(n&1&&(o(0,"code"),E(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),K(L(2,1,e))}}function on(n,t){if(n&1&&(o(0,"section",41)(1,"sh-toggle-card",42),G(2,43),o(3,"h3"),l(4,0),i(),P(),G(5,44),o(6,"p"),l(7,1),u(8,"date"),i(),o(9,"p"),l(10,2),u(11,"date"),i(),o(12,"p"),l(13,3),u(14,"durationFormat"),i(),P(),i(),o(15,"sh-toggle-card",42),G(16,43),o(17,"h3"),l(18,4),i(),P(),G(19,44),o(20,"p"),l(21,5),u(22,"bytes"),i(),o(23,"p"),l(24,6),u(25,"bytes"),i(),o(26,"p"),l(27,7),u(28,"bytes"),i(),o(29,"p"),l(30,8),u(31,"bytes"),i(),o(32,"p"),l(33,9),i(),o(34,"p"),l(35,10),i(),o(36,"p"),l(37,11),i(),P(),i(),o(38,"div",45),s(39,"sh-divider"),g(40,Qe,54,45),g(41,Ze,9,1,"details",46),o(42,"details",46)(43,"summary"),N(44,12),s(45,"sh-icon"),o(46,"div",47),s(47,"sh-icon",40),i(),m(),i(),o(48,"div",48),b(49,en,3,3,"code",null,B),i()(),o(51,"details",46)(52,"summary"),N(53,13),s(54,"sh-icon"),o(55,"div",47),s(56,"sh-icon",40),i(),m(),i(),o(57,"div",48),g(58,nn,2,0,"p"),b(59,tn,3,3,"code",null,B),i()(),s(61,"sh-divider"),o(62,"details")(63,"summary"),N(64,14),s(65,"sh-icon"),o(66,"div",47),s(67,"sh-icon",40),i(),m(),i(),o(68,"code")(69,"button",49),E(70,"Copy"),i(),E(71),u(72,"json"),i()()()()),n&2){let e=C().$implicit;a(),z("disallowToggle",!0),a(7),d(S(8,22,e.data==null?null:e.data.BeginTime,"medium")),c(7),a(3),d(S(11,25,e.data==null?null:e.data.EndTime,"medium")),c(10),a(3),d(L(14,28,e.data==null?null:e.data.Duration)),c(13),a(),z("disallowToggle",!0),a(7),d(e.data==null?null:e.data.ExaminedFiles)(h(22,30,e.data==null?null:e.data.SizeOfExaminedFiles,!0,!0)),c(21),a(3),d(e.data==null?null:e.data.OpenedFiles)(h(25,34,e.data==null?null:e.data.SizeOfOpenedFiles,!0,!0)),c(24),a(3),d(e.data==null?null:e.data.AddedFiles)(h(28,38,e.data==null?null:e.data.SizeOfAddedFiles,!0,!0)),c(27),a(3),d(e.data==null?null:e.data.ModifiedFiles)(h(31,42,e.data==null?null:e.data.SizeOfModifiedFiles,!0,!0)),c(30),a(2),d(e.data==null?null:e.data.DeletedFiles),c(33),a(2),d(e.data==null?null:e.data.TooLargeFiles),c(35),a(2),d(e.data==null?null:e.data.FilesWithError),c(37),a(3),T(e.data!=null&&e.data.TestResults?40:-1),a(),T((e.data==null?null:e.data.MainOperation)==="Test"?41:-1),a(6),d(e.data==null?null:e.data.WarningsActualLength),c(44),a(2),k(e.data==null?null:e.data.Warnings),a(7),d(e.data==null?null:e.data.ErrorsActualLength),c(53),a(2),T((e.data==null||e.data.Errors==null?null:e.data.Errors.length)===0?58:-1),a(),k(e.data==null?null:e.data.Errors),a(12),f(" ",L(72,46,e.data)," ")}}function an(n,t){if(n&1){let e=U();o(0,"article",33)(1,"header",34),I("click",function(){let r=D(e).$implicit,p=C();return M(p.toggleOpenEntry(r.id))}),g(2,He,1,0,"div",35)(3,je,1,0,"div",35)(4,We,1,0,"div",36)(5,qe,1,0,"div",37),o(6,"h3"),E(7),u(8,"date"),i(),o(9,"p"),E(10),i(),s(11,"div",38),o(12,"div",39)(13,"sh-icon",40),E(14,"caret-down"),i()()(),g(15,on,73,48,"section",41),i()}if(n&2){let e=t.$implicit,_=C(),r=(e.data==null?null:e.data.ParsedResult)||"Unknown";a(2),T(r=="Fatal"?2:r=="Error"?3:r=="Warning"?4:5),a(5),K(S(8,7,e.timestamp,"medium")),a(3),Ie(" ",e.data==null?null:e.data.MainOperation," ",_.getLocalizedSummary(e)," "),a(3),$("open",e.id===_.openEntry()),a(2),T(e.id===_.openEntry()?15:-1)}}var ue=class n{#e=x(de);#n=new Z;#t=new ee;backupId=le.required();openEntry=A(null);pagination=A({offset:0,pagesize:100});resource=ce({params:()=>_e({id:this.backupId()},this.pagination()),stream:({params:t})=>this.#e.getApiV1BackupByIdLog({id:t.id,pagesize:100}).pipe(J(e=>e.map(_=>({id:_.ID,operationId:_.OperationID,timestamp:_.Timestamp*1e3,type:_.Type,data:JSON.parse(_.Message),exception:JSON.stringify(_.Exception)==="{}"?null:_.Exception}))))});getLocalizedSummary(t){let e=t.data?.ErrorsActualLength??0,_=t.data?.WarningsActualLength??0,r=[];if(t.data?.MainOperation=="Backup"){if(t.data?.Duration){let p=this.#t.transform(t.data?.Duration,!0);p.startsWith("0h ")&&(p=p.slice(3)),p.startsWith("0m ")&&(p=p.slice(3)),r.push($localize`took ${p}`)}t.data?.BackendStatistics?.BytesUploaded&&r.push($localize`uploaded ${this.#n.transform(t.data?.BackendStatistics?.BytesUploaded)}`),t.data?.BackendStatistics?.KnownFileSize&&r.push($localize`backup size ${this.#n.transform(t.data?.BackendStatistics?.KnownFileSize)}`)}return e!==0&&r.push($localize`:@@errorCount:${e} error${e===1?"":"s"}`),_!==0&&r.push($localize`:@@warningCount:${_} warning${_===1?"":"s"}`),r.length===0?"":`(${r.join(", ")})`}toggleOpenEntry(t){if(this.openEntry()===t){this.openEntry.set(null);return}this.openEntry.set(t)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=X({type:n,selectors:[["app-general-log"]],inputs:{backupId:[1,"backupId"]},decls:3,vars:1,consts:()=>{let t;t=$localize`Time`;let e;e=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let _;_=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let r;r=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let p;p=$localize`Source files`;let v;v=$localize` Evaluated: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let y;y=$localize`Opened: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let j;j=$localize`Added: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let W;W=$localize` Modified: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let q;q=$localize`Deleted: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Q;Q=$localize`Too large: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Y;Y=$localize`Files with error: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let O;O=$localize`${"\uFFFD#45\uFFFD"}:START_TAG_SH_ICON:warning-circle${"[\uFFFD/#45\uFFFD|\uFFFD/#47\uFFFD]"}:CLOSE_TAG_SH_ICON: Warnings ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#46\uFFFD"}:START_TAG_DIV:${"\uFFFD#47\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#45\uFFFD|\uFFFD/#47\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#46\uFFFD"}:CLOSE_TAG_DIV:`,O=R(O);let ne;ne=$localize`${"\uFFFD#54\uFFFD"}:START_TAG_SH_ICON:warning${"[\uFFFD/#54\uFFFD|\uFFFD/#56\uFFFD]"}:CLOSE_TAG_SH_ICON: Errors ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#55\uFFFD"}:START_TAG_DIV:${"\uFFFD#56\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#54\uFFFD|\uFFFD/#56\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#55\uFFFD"}:CLOSE_TAG_DIV:`,ne=R(ne);let te;te=$localize`${"\uFFFD#65\uFFFD"}:START_TAG_SH_ICON:notepad${"[\uFFFD/#65\uFFFD|\uFFFD/#67\uFFFD]"}:CLOSE_TAG_SH_ICON: Complete log ${"\uFFFD#66\uFFFD"}:START_TAG_DIV:${"\uFFFD#67\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#65\uFFFD|\uFFFD/#67\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#66\uFFFD"}:CLOSE_TAG_DIV:`,te=R(te);let ie;ie=$localize`${"\uFFFD#3\uFFFD"}:START_TAG_SH_ICON:circle-half-tilt${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON: Test phase ${"\uFFFD#4\uFFFD"}:START_TAG_DIV:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_DIV:`,ie=R(ie);let Ce;Ce=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let ge;ge=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Te;Te=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Oe;Oe=$localize`Verifications: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Le;Le=$localize`Warnings: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Ne;Ne=$localize`Errors: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let oe;oe=$localize`${"\uFFFD#26\uFFFD"}:START_TAG_SH_ICON:file-archive${"[\uFFFD/#26\uFFFD|\uFFFD/#28\uFFFD]"}:CLOSE_TAG_SH_ICON: Compact phase ${"\uFFFD#27\uFFFD"}:START_TAG_DIV:${"\uFFFD#28\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#26\uFFFD|\uFFFD/#28\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#27\uFFFD"}:CLOSE_TAG_DIV:`,oe=R(oe);let me;me=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Se;Se=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Ge;Ge=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Pe;Pe=$localize` Deleted files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let Ae;Ae=$localize` Downloaded files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let Re;Re=$localize` Uploaded files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let De;De=$localize`Warnings: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Me;Me=$localize`Errors: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let ae;return ae=$localize`${"\uFFFD#3\uFFFD"}:START_TAG_SH_ICON:warning-circle${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON: Verifications ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#4\uFFFD"}:START_TAG_DIV:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_DIV:`,ae=R(ae),[t,e,_,r,p,v,y,j,W,q,Q,Y,O,ne,te,ie,Ce,ge,Te,Oe,Le,Ne,oe,me,Se,Ge,Pe,Ae,Re,De,Me,ae,[1,"indeterminate","primary"],[1,"log-entry"],[3,"click"],[1,"status","error"],[1,"status","warn"],[1,"status"],[1,"spacer"],[1,"action"],[1,"toggle-indicator"],[1,"log-content"],[3,"disallowToggle"],["title",""],["content",""],[1,"extra-info"],["name","details"],[1,"actions"],[1,"content"],["shButton","",1,"small"]]},template:function(e,_){e&1&&(g(0,Ve,1,0,"sh-progress-bar",32),b(1,an,16,10,"article",33,B)),e&2&&(T(_.resource.isLoading()?0:-1),a(),k(_.resource.value()))},dependencies:[Ue,be,Fe,se,H,Z,V,ee,re],styles:["[_nghost-%COMP%]{display:block}.log-entry[_ngcontent-%COMP%]{display:flex;flex-direction:column;cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;padding:1rem;border-bottom:1px solid var(--base-4);background-color:var(--base-1);cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]:hover{background-color:var(--base-2)}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-30);margin:0}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.toggle-indicator[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:1.25rem;transition:transform 125ms linear}.toggle-indicator.open[_ngcontent-%COMP%]{transform:rotate(180deg)}details[_ngcontent-%COMP%]{display:flex;flex-direction:column}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]{cursor:pointer;display:flex;align-items:center;gap:.5rem;padding:.75rem;border-radius:var(--shape-2);background-color:var(--base-2)}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]:focus{outline:none}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]:hover{background-color:var(--base-3)}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]::marker{font-size:0}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;flex:1 0;gap:.5rem;-webkit-user-select:none;user-select:none}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:2rem;transition:transform 125ms linear}details[open][_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{transform:rotate(180deg)}details[_ngcontent-%COMP%] .content[_ngcontent-%COMP%]{padding:.75rem 1rem 0;display:flex;flex-direction:column;gap:.75rem}details[_ngcontent-%COMP%] .content[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0}details[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{margin-top:.75rem;position:relative}details[_ngcontent-%COMP%] code[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{position:absolute;top:.75rem;right:.75rem}.extra-info[_ngcontent-%COMP%]{grid-column:1/-1;display:flex;flex-direction:column;gap:1rem}.extra-info[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;margin-bottom:.75rem}.extra-info[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{white-space:pre-wrap;padding:1rem;display:block;border-radius:var(--shape-2);background-color:var(--base-2)}.log-content[_ngcontent-%COMP%]{padding:1rem;display:grid;grid-template-columns:1fr 1fr;gap:1rem}.status[_ngcontent-%COMP%]{display:block;width:1rem;height:1rem;background-color:var(--success-8);border-radius:50%}.status.error[_ngcontent-%COMP%]{background-color:var(--error-8)}.status.warn[_ngcontent-%COMP%]{background-color:var(--warn-8)}"],changeDetection:0})};function _n(n,t){n&1&&s(0,"sh-progress-bar",1)}function ln(n,t){n&1&&(N(0,0,1),s(1,"sh-icon"),m())}function rn(n,t){n&1&&(N(0,0,2),s(1,"sh-icon"),m())}function sn(n,t){if(n&1){let e=U();o(0,"section",6)(1,"button",7),I("click",function(){D(e);let r=C(),p=r.$implicit,v=r.$index,y=C();return M(y.copyToClipboard(p.data,v))}),N(2,0),g(3,ln,2,0)(4,rn,2,0),m(),i(),o(5,"code"),E(6),u(7,"json"),i()()}if(n&2){let e=C(),_=e.$implicit,r=e.$index,p=C();a(),$("success",p.copiedFromIndex()===r),a(2),T(p.copiedFromIndex()===r?3:4),a(3),K(L(7,4,_.data))}}function Fn(n,t){if(n&1){let e=U();o(0,"article",2)(1,"header",3),I("click",function(){let r=D(e).$implicit,p=C();return M(p.toggleOpenEntry(r.id))}),o(2,"h3"),E(3),u(4,"date"),i(),o(5,"div",4)(6,"sh-icon",5),E(7,"caret-down"),i()()(),g(8,sn,8,6,"section",6),i()}if(n&2){let e=t.$implicit,_=C();a(3),$e("",S(4,6,e.timestamp,"medium"),": ",e.operation," ",e.path),a(3),$("open",e.id===_.openEntry()),a(2),T(e.id===_.openEntry()?8:-1)}}var pe=class n{#e=x(de);backupId=le.required();openEntry=A(null);pagination=A({offset:0,pagesize:100});copiedFromIndex=A(null);resource=ce({params:()=>_e({id:this.backupId()},this.pagination()),stream:({params:t})=>this.#e.getApiV1BackupByIdRemotelog({id:t.id,pagesize:100}).pipe(J(e=>e.map((_,r)=>({id:_.ID,operationId:_.OperationID,timestamp:_.Timestamp*1e3,operation:_.Operation,path:_.Path,data:typeof _.Data=="string"?JSON.parse(_.Data):null}))))});toggleOpenEntry(t){if(this.openEntry()===t){this.openEntry.set(null);return}this.openEntry.set(t)}copyToClipboard(t,e){let _=JSON.stringify(t,null,2);navigator.clipboard.writeText(_),this.copiedFromIndex.set(e),setTimeout(()=>{this.copiedFromIndex.set(null)},3e3)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=X({type:n,selectors:[["app-remote-log"]],inputs:{backupId:[1,"backupId"]},decls:3,vars:1,consts:()=>{let t;return t=$localize`${"\uFFFD*3:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:check${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Copied ${"\uFFFD/*3:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*4:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:copy${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Copy to clipboard ${"\uFFFD/*4:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,t=R(t),[t,[1,"indeterminate","primary"],[1,"log-entry"],[3,"click"],[1,"actions"],[1,"toggle-indicator"],[1,"log-content"],["shButton","",1,"small",3,"click"]]},template:function(e,_){e&1&&(g(0,_n,1,0,"sh-progress-bar",1),b(1,Fn,9,9,"article",2,B)),e&2&&(T(_.resource.isLoading()?0:-1),a(),k(_.resource.value()))},dependencies:[Fe,H,re,V],styles:["[_nghost-%COMP%]{display:block}.log-entry[_ngcontent-%COMP%]{display:flex;flex-direction:column}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.5rem;padding:1rem;border-bottom:1px solid var(--base-4);background-color:var(--base-1);cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]:hover{background-color:var(--base-2)}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-30);margin:0;-webkit-user-select:none;user-select:none}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.toggle-indicator[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:1.25rem;transition:transform 125ms linear}.toggle-indicator.open[_ngcontent-%COMP%]{transform:rotate(180deg)}.log-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem;position:relative}.log-content[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{position:absolute;top:2rem;right:2rem;background:transparent}code[_ngcontent-%COMP%]{white-space:pre-wrap;padding:1rem;display:block;border-radius:var(--shape-2);background-color:var(--base-2)}"],changeDetection:0})};function dn(n,t){if(n&1&&(E(0," - "),G(1),l(2,6),P(),E(3),u(4,"durationFormat")),n&2){C(2);let e=w(6);a(3),f(" ",L(4,1,e.Backup.Metadata==null?null:e.Backup.Metadata.LastBackupDuration)," ")}}function cn(n,t){n&1&&(G(0),l(1,7),P())}function un(n,t){if(n&1&&(E(0),u(1,"bytes")),n&2){C(2);let e=w(6);f(" ",L(1,1,e.Backup.Metadata==null?null:e.Backup.Metadata.SourceFilesSize)," ")}}function pn(n,t){n&1&&(G(0),l(1,8),P())}function En(n,t){if(n&1&&(E(0),u(1,"bytes")),n&2){C(2);let e=w(6);f(" ",L(1,1,e.Backup.Metadata==null?null:e.Backup.Metadata.TargetFilesSize)," ")}}function Cn(n,t){n&1&&(G(0),l(1,9),P())}function gn(n,t){if(n&1&&(o(0,"sh-chip",19),l(1,10),i()),n&2){C(2);let e=w(6);a(),d(e.Backup.Metadata==null?null:e.Backup.Metadata.BackupListCount),c(1)}}function Tn(n,t){n&1&&(o(0,"sh-chip",20),l(1,11),i())}function On(n,t){if(n&1&&(o(0,"div",14)(1,"div",18)(2,"h3"),E(3),o(4,"sh-icon"),E(5,"database"),i()(),o(6,"p")(7,"span"),l(8,3),i(),E(9),u(10,"date"),g(11,dn,5,3)(12,cn,2,0,"ng-container"),i(),o(13,"p")(14,"span"),l(15,4),i(),g(16,un,2,3)(17,pn,2,0,"ng-container"),i(),o(18,"p")(19,"span"),l(20,5),i(),g(21,En,2,3)(22,Cn,2,0,"ng-container"),i()(),g(23,gn,2,1,"sh-chip",19)(24,Tn,2,0,"sh-chip",20),i()),n&2){let e=C(),_=w(6);a(3),f(" ",_.Backup.Name??e.MISSING_BACKUP_NAME," "),a(6),f(" ",S(10,6,_.Backup.Metadata==null?null:_.Backup.Metadata.LastBackupDate,"short")," "),a(2),T(_.Backup.Metadata!=null&&_.Backup.Metadata.LastBackupDuration?11:12),a(5),T(_.Backup.Metadata!=null&&_.Backup.Metadata.SourceFilesSize?16:17),a(5),T(_.Backup.Metadata!=null&&_.Backup.Metadata.TargetFilesSize?21:22),a(2),T(_.Backup.Metadata!=null&&_.Backup.Metadata.BackupListCount?23:24)}}function Ln(n,t){if(n&1&&s(0,"app-general-log",17),n&2){let e=C();z("backupId",e.backupId())}}function Nn(n,t){if(n&1&&s(0,"app-remote-log",17),n&2){let e=C();z("backupId",e.backupId())}}var Ee=class n{#e=x(ye);#n=x(Ke);MISSING_BACKUP_NAME=$localize`Backup name missing`;activeTab=A("general");backupId=Je(this.#e.params.pipe(J(t=>t.id)));backup=ve(()=>{let t=this.backupId();return t?this.#n.getBackupById(t):null});static \u0275fac=function(e){return new(e||n)};static \u0275cmp=X({type:n,selectors:[["app-log"]],decls:15,vars:8,consts:()=>{let t;t=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON: Back `;let e;e=$localize`General`;let _;_=$localize` Destination `;let r;r=$localize`Last successful backup:`;let p;p=$localize`Source:`;let v;v=$localize`Destination:`;let y;y=$localize`took`;let j;j=$localize`N/A`;let W;W=$localize`N/A`;let q;q=$localize`N/A`;let Q;Q=$localize`${"\uFFFD0\uFFFD"}:INTERPOLATION: Version`;let Y;return Y=$localize`No version yet`,[t,e,_,r,p,v,y,j,W,q,Q,Y,[1,"back"],["type","button","shButton","","routerLink","/",1,"small"],[1,"backup"],[1,"primary"],["tab","",3,"click"],[3,"backupId"],[1,"text"],[1,"simple","success"],[1,"simple"]]},template:function(e,_){if(e&1){let r=U();s(0,"app-status-bar"),o(1,"section")(2,"div",12)(3,"button",13),N(4,0),s(5,"sh-icon"),m(),i()(),fe(6),g(7,On,25,9,"div",14),o(8,"sh-tabs",15)(9,"button",16),I("click",function(){return D(r),M(_.activeTab.set("general"))}),l(10,1),i(),o(11,"button",16),I("click",function(){return D(r),M(_.activeTab.set("destination"))}),l(12,2),i()(),g(13,Ln,1,1,"app-general-log",17),g(14,Nn,1,1,"app-remote-log",17),i()}if(e&2){a(6);let r=he(_.backup());a(),T(r?7:-1),a(2),$("active",_.activeTab()==="general"),a(2),$("active",_.activeTab()==="destination"),a(2),T(_.activeTab()==="general"?13:-1),a(),T(_.activeTab()==="destination"?14:-1)}},dependencies:[ke,ue,pe,xe,Xe,H,se,Be,Z,ee,V],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem 1.5rem;gap:1rem}sh-tabs[_ngcontent-%COMP%]{margin-bottom:1rem}.backup[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:2rem;gap:1rem;border:1px solid var(--base-4);border-radius:var(--shape-3);box-shadow:var(--box-shadow-10)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;width:100%;max-width:40%}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] h3[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{color:var(--base-8)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] p[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{color:var(--base-12)}"],changeDetection:0})};export{Ee as default};
|
|
1
|
+
import{a as Xe}from"./chunk-HEV3WHAH.js";import{a as ee}from"./chunk-D7TCA6E7.js";import"./chunk-7XLQX4B6.js";import"./chunk-AJXTVI3H.js";import"./chunk-LF24JF3M.js";import{a as Ke}from"./chunk-QNZTEY37.js";import"./chunk-6Q6SSTBK.js";import{a as Z}from"./chunk-U63HBLGG.js";import"./chunk-LVPZTSKG.js";import"./chunk-AGPZBYW6.js";import"./chunk-WILUKPQ3.js";import"./chunk-CGKL2MHM.js";import"./chunk-RIVMPP47.js";import{b as Je,c as ce}from"./chunk-FBWFZMGL.js";import"./chunk-PNYEL323.js";import"./chunk-NEV6JB5M.js";import"./chunk-QWNOPLJC.js";import{B as se,E as Be,G as be,L as Fe,U as ke,V as Ue,u as H}from"./chunk-RYXU2QDS.js";import{b as de}from"./chunk-BKANUILG.js";import{b as ye,e as xe}from"./chunk-GO4NSDR6.js";import"./chunk-56FBKSBN.js";import"./chunk-FIBRO5I3.js";import{la as V,oa as re}from"./chunk-RMOTUTEQ.js";import"./chunk-QF5K4MHH.js";import{$ as D,Ab as i,Bb as s,Cc as u,Dc as L,Ec as S,Fb as G,Fc as h,Gb as P,Ib as U,Mc as ve,Pa as a,Pb as N,Qb as m,Rb as l,Rc as le,Sb as d,Tb as c,Ub as R,Vb as I,W as x,Xb as C,aa as M,cb as X,gc as $,jc as E,kc as K,la as A,lc as f,mc as Ie,nc as $e,p as J,rc as fe,sb as g,sc as he,tb as T,tc as w,ub as B,wb as b,xb as k,yb as z,zb as o}from"./chunk-XYHHESIX.js";import{a as _e}from"./chunk-7CGTOI24.js";function Ve(n,t){n&1&&s(0,"sh-progress-bar",32)}function He(n,t){n&1&&s(0,"div",35)}function je(n,t){n&1&&s(0,"div",35)}function We(n,t){n&1&&s(0,"div",36)}function qe(n,t){n&1&&s(0,"div",37)}function Qe(n,t){if(n&1&&(o(0,"details",46)(1,"summary"),N(2,15),s(3,"sh-icon"),o(4,"div",47),s(5,"sh-icon",40),i(),m(),i(),o(6,"div",48)(7,"p"),l(8,16),u(9,"date"),i(),o(10,"p"),l(11,17),u(12,"date"),i(),o(13,"p"),l(14,18),u(15,"durationFormat"),i(),o(16,"p"),l(17,19),i(),s(18,"sh-divider"),o(19,"p"),l(20,20),i(),o(21,"p"),l(22,21),i()()(),o(23,"details",46)(24,"summary"),N(25,22),s(26,"sh-icon"),o(27,"div",47),s(28,"sh-icon",40),i(),m(),i(),o(29,"div",48)(30,"p"),l(31,23),u(32,"date"),i(),o(33,"p"),l(34,24),u(35,"date"),i(),o(36,"p"),l(37,25),u(38,"durationFormat"),i(),s(39,"sh-divider"),o(40,"p"),l(41,26),u(42,"bytes"),i(),o(43,"p"),l(44,27),u(45,"bytes"),i(),o(46,"p"),l(47,28),u(48,"bytes"),i(),s(49,"sh-divider"),o(50,"p"),l(51,29),i(),o(52,"p"),l(53,30),i()()()),n&2){let e=C(2).$implicit;a(9),d(S(9,17,e.data==null||e.data.TestResults==null?null:e.data.TestResults.BeginTime,"medium")),c(8),a(3),d(S(12,20,e.data==null||e.data.TestResults==null?null:e.data.TestResults.EndTime,"medium")),c(11),a(3),d(L(15,23,e.data==null||e.data.TestResults==null?null:e.data.TestResults.Duration)),c(14),a(2),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.VerificationsActualLength),c(17),a(3),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.WarningsActualLength),c(20),a(2),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.ErrorsActualLength),c(22),a(10),d(S(32,25,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.BeginTime,"medium")),c(31),a(3),d(S(35,28,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.EndTime,"medium")),c(34),a(3),d(L(38,31,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.Duration)),c(37),a(4),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DeletedFileCount)(h(42,33,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DeletedFileSize,!0,!0)),c(41),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DownloadedFileCount)(h(45,37,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DownloadedFileSize,!0,!0)),c(44),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.UploadedFileCount)(h(48,41,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.UploadedFileSize,!0,!0)),c(47),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.WarningsActualLength),c(51),a(2),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.ErrorsActualLength),c(53)}}function Ye(n,t){if(n&1&&(o(0,"code"),E(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),K(L(2,1,e))}}function Ze(n,t){if(n&1&&(o(0,"details",46)(1,"summary"),N(2,31),s(3,"sh-icon"),o(4,"div",47),s(5,"sh-icon",40),i(),m(),i(),o(6,"div",48),b(7,Ye,3,3,"code",null,B),i()()),n&2){let e=C(2).$implicit;a(5),d(e.data.VerificationsActualLength),c(2),a(2),k(e.data.Verifications)}}function en(n,t){if(n&1&&(o(0,"code"),E(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),K(L(2,1,e))}}function nn(n,t){n&1&&(o(0,"p"),E(1,"No errors"),i())}function tn(n,t){if(n&1&&(o(0,"code"),E(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),K(L(2,1,e))}}function on(n,t){if(n&1&&(o(0,"section",41)(1,"sh-toggle-card",42),G(2,43),o(3,"h3"),l(4,0),i(),P(),G(5,44),o(6,"p"),l(7,1),u(8,"date"),i(),o(9,"p"),l(10,2),u(11,"date"),i(),o(12,"p"),l(13,3),u(14,"durationFormat"),i(),P(),i(),o(15,"sh-toggle-card",42),G(16,43),o(17,"h3"),l(18,4),i(),P(),G(19,44),o(20,"p"),l(21,5),u(22,"bytes"),i(),o(23,"p"),l(24,6),u(25,"bytes"),i(),o(26,"p"),l(27,7),u(28,"bytes"),i(),o(29,"p"),l(30,8),u(31,"bytes"),i(),o(32,"p"),l(33,9),i(),o(34,"p"),l(35,10),i(),o(36,"p"),l(37,11),i(),P(),i(),o(38,"div",45),s(39,"sh-divider"),g(40,Qe,54,45),g(41,Ze,9,1,"details",46),o(42,"details",46)(43,"summary"),N(44,12),s(45,"sh-icon"),o(46,"div",47),s(47,"sh-icon",40),i(),m(),i(),o(48,"div",48),b(49,en,3,3,"code",null,B),i()(),o(51,"details",46)(52,"summary"),N(53,13),s(54,"sh-icon"),o(55,"div",47),s(56,"sh-icon",40),i(),m(),i(),o(57,"div",48),g(58,nn,2,0,"p"),b(59,tn,3,3,"code",null,B),i()(),s(61,"sh-divider"),o(62,"details")(63,"summary"),N(64,14),s(65,"sh-icon"),o(66,"div",47),s(67,"sh-icon",40),i(),m(),i(),o(68,"code")(69,"button",49),E(70,"Copy"),i(),E(71),u(72,"json"),i()()()()),n&2){let e=C().$implicit;a(),z("disallowToggle",!0),a(7),d(S(8,22,e.data==null?null:e.data.BeginTime,"medium")),c(7),a(3),d(S(11,25,e.data==null?null:e.data.EndTime,"medium")),c(10),a(3),d(L(14,28,e.data==null?null:e.data.Duration)),c(13),a(),z("disallowToggle",!0),a(7),d(e.data==null?null:e.data.ExaminedFiles)(h(22,30,e.data==null?null:e.data.SizeOfExaminedFiles,!0,!0)),c(21),a(3),d(e.data==null?null:e.data.OpenedFiles)(h(25,34,e.data==null?null:e.data.SizeOfOpenedFiles,!0,!0)),c(24),a(3),d(e.data==null?null:e.data.AddedFiles)(h(28,38,e.data==null?null:e.data.SizeOfAddedFiles,!0,!0)),c(27),a(3),d(e.data==null?null:e.data.ModifiedFiles)(h(31,42,e.data==null?null:e.data.SizeOfModifiedFiles,!0,!0)),c(30),a(2),d(e.data==null?null:e.data.DeletedFiles),c(33),a(2),d(e.data==null?null:e.data.TooLargeFiles),c(35),a(2),d(e.data==null?null:e.data.FilesWithError),c(37),a(3),T(e.data!=null&&e.data.TestResults?40:-1),a(),T((e.data==null?null:e.data.MainOperation)==="Test"?41:-1),a(6),d(e.data==null?null:e.data.WarningsActualLength),c(44),a(2),k(e.data==null?null:e.data.Warnings),a(7),d(e.data==null?null:e.data.ErrorsActualLength),c(53),a(2),T((e.data==null||e.data.Errors==null?null:e.data.Errors.length)===0?58:-1),a(),k(e.data==null?null:e.data.Errors),a(12),f(" ",L(72,46,e.data)," ")}}function an(n,t){if(n&1){let e=U();o(0,"article",33)(1,"header",34),I("click",function(){let r=D(e).$implicit,p=C();return M(p.toggleOpenEntry(r.id))}),g(2,He,1,0,"div",35)(3,je,1,0,"div",35)(4,We,1,0,"div",36)(5,qe,1,0,"div",37),o(6,"h3"),E(7),u(8,"date"),i(),o(9,"p"),E(10),i(),s(11,"div",38),o(12,"div",39)(13,"sh-icon",40),E(14,"caret-down"),i()()(),g(15,on,73,48,"section",41),i()}if(n&2){let e=t.$implicit,_=C(),r=(e.data==null?null:e.data.ParsedResult)||"Unknown";a(2),T(r=="Fatal"?2:r=="Error"?3:r=="Warning"?4:5),a(5),K(S(8,7,e.timestamp,"medium")),a(3),Ie(" ",e.data==null?null:e.data.MainOperation," ",_.getLocalizedSummary(e)," "),a(3),$("open",e.id===_.openEntry()),a(2),T(e.id===_.openEntry()?15:-1)}}var ue=class n{#e=x(de);#n=new Z;#t=new ee;backupId=le.required();openEntry=A(null);pagination=A({offset:0,pagesize:100});resource=ce({params:()=>_e({id:this.backupId()},this.pagination()),stream:({params:t})=>this.#e.getApiV1BackupByIdLog({id:t.id,pagesize:100}).pipe(J(e=>e.map(_=>({id:_.ID,operationId:_.OperationID,timestamp:_.Timestamp*1e3,type:_.Type,data:JSON.parse(_.Message),exception:JSON.stringify(_.Exception)==="{}"?null:_.Exception}))))});getLocalizedSummary(t){let e=t.data?.ErrorsActualLength??0,_=t.data?.WarningsActualLength??0,r=[];if(t.data?.MainOperation=="Backup"){if(t.data?.Duration){let p=this.#t.transform(t.data?.Duration,!0);p.startsWith("0h ")&&(p=p.slice(3)),p.startsWith("0m ")&&(p=p.slice(3)),r.push($localize`took ${p}`)}t.data?.BackendStatistics?.BytesUploaded&&r.push($localize`uploaded ${this.#n.transform(t.data?.BackendStatistics?.BytesUploaded)}`),t.data?.BackendStatistics?.KnownFileSize&&r.push($localize`backup size ${this.#n.transform(t.data?.BackendStatistics?.KnownFileSize)}`)}return e!==0&&r.push($localize`:@@errorCount:${e} error${e===1?"":"s"}`),_!==0&&r.push($localize`:@@warningCount:${_} warning${_===1?"":"s"}`),r.length===0?"":`(${r.join(", ")})`}toggleOpenEntry(t){if(this.openEntry()===t){this.openEntry.set(null);return}this.openEntry.set(t)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=X({type:n,selectors:[["app-general-log"]],inputs:{backupId:[1,"backupId"]},decls:3,vars:1,consts:()=>{let t;t=$localize`Time`;let e;e=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let _;_=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let r;r=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let p;p=$localize`Source files`;let v;v=$localize` Evaluated: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let y;y=$localize`Opened: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let j;j=$localize`Added: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let W;W=$localize` Modified: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let q;q=$localize`Deleted: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Q;Q=$localize`Too large: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Y;Y=$localize`Files with error: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let O;O=$localize`${"\uFFFD#45\uFFFD"}:START_TAG_SH_ICON:warning-circle${"[\uFFFD/#45\uFFFD|\uFFFD/#47\uFFFD]"}:CLOSE_TAG_SH_ICON: Warnings ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#46\uFFFD"}:START_TAG_DIV:${"\uFFFD#47\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#45\uFFFD|\uFFFD/#47\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#46\uFFFD"}:CLOSE_TAG_DIV:`,O=R(O);let ne;ne=$localize`${"\uFFFD#54\uFFFD"}:START_TAG_SH_ICON:warning${"[\uFFFD/#54\uFFFD|\uFFFD/#56\uFFFD]"}:CLOSE_TAG_SH_ICON: Errors ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#55\uFFFD"}:START_TAG_DIV:${"\uFFFD#56\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#54\uFFFD|\uFFFD/#56\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#55\uFFFD"}:CLOSE_TAG_DIV:`,ne=R(ne);let te;te=$localize`${"\uFFFD#65\uFFFD"}:START_TAG_SH_ICON:notepad${"[\uFFFD/#65\uFFFD|\uFFFD/#67\uFFFD]"}:CLOSE_TAG_SH_ICON: Complete log ${"\uFFFD#66\uFFFD"}:START_TAG_DIV:${"\uFFFD#67\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#65\uFFFD|\uFFFD/#67\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#66\uFFFD"}:CLOSE_TAG_DIV:`,te=R(te);let ie;ie=$localize`${"\uFFFD#3\uFFFD"}:START_TAG_SH_ICON:circle-half-tilt${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON: Test phase ${"\uFFFD#4\uFFFD"}:START_TAG_DIV:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_DIV:`,ie=R(ie);let Ce;Ce=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let ge;ge=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Te;Te=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Oe;Oe=$localize`Verifications: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Le;Le=$localize`Warnings: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Ne;Ne=$localize`Errors: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let oe;oe=$localize`${"\uFFFD#26\uFFFD"}:START_TAG_SH_ICON:file-archive${"[\uFFFD/#26\uFFFD|\uFFFD/#28\uFFFD]"}:CLOSE_TAG_SH_ICON: Compact phase ${"\uFFFD#27\uFFFD"}:START_TAG_DIV:${"\uFFFD#28\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#26\uFFFD|\uFFFD/#28\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#27\uFFFD"}:CLOSE_TAG_DIV:`,oe=R(oe);let me;me=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Se;Se=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Ge;Ge=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Pe;Pe=$localize` Deleted files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let Ae;Ae=$localize` Downloaded files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let Re;Re=$localize` Uploaded files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let De;De=$localize`Warnings: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Me;Me=$localize`Errors: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let ae;return ae=$localize`${"\uFFFD#3\uFFFD"}:START_TAG_SH_ICON:warning-circle${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON: Verifications ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#4\uFFFD"}:START_TAG_DIV:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_DIV:`,ae=R(ae),[t,e,_,r,p,v,y,j,W,q,Q,Y,O,ne,te,ie,Ce,ge,Te,Oe,Le,Ne,oe,me,Se,Ge,Pe,Ae,Re,De,Me,ae,[1,"indeterminate","primary"],[1,"log-entry"],[3,"click"],[1,"status","error"],[1,"status","warn"],[1,"status"],[1,"spacer"],[1,"action"],[1,"toggle-indicator"],[1,"log-content"],[3,"disallowToggle"],["title",""],["content",""],[1,"extra-info"],["name","details"],[1,"actions"],[1,"content"],["shButton","",1,"small"]]},template:function(e,_){e&1&&(g(0,Ve,1,0,"sh-progress-bar",32),b(1,an,16,10,"article",33,B)),e&2&&(T(_.resource.isLoading()?0:-1),a(),k(_.resource.value()))},dependencies:[Ue,be,Fe,se,H,Z,V,ee,re],styles:["[_nghost-%COMP%]{display:block}.log-entry[_ngcontent-%COMP%]{display:flex;flex-direction:column;cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;padding:1rem;border-bottom:1px solid var(--base-4);background-color:var(--base-1);cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]:hover{background-color:var(--base-2)}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-30);margin:0}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.toggle-indicator[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:1.25rem;transition:transform 125ms linear}.toggle-indicator.open[_ngcontent-%COMP%]{transform:rotate(180deg)}details[_ngcontent-%COMP%]{display:flex;flex-direction:column}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]{cursor:pointer;display:flex;align-items:center;gap:.5rem;padding:.75rem;border-radius:var(--shape-2);background-color:var(--base-2)}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]:focus{outline:none}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]:hover{background-color:var(--base-3)}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]::marker{font-size:0}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;flex:1 0;gap:.5rem;-webkit-user-select:none;user-select:none}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:2rem;transition:transform 125ms linear}details[open][_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{transform:rotate(180deg)}details[_ngcontent-%COMP%] .content[_ngcontent-%COMP%]{padding:.75rem 1rem 0;display:flex;flex-direction:column;gap:.75rem}details[_ngcontent-%COMP%] .content[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0}details[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{margin-top:.75rem;position:relative}details[_ngcontent-%COMP%] code[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{position:absolute;top:.75rem;right:.75rem}.extra-info[_ngcontent-%COMP%]{grid-column:1/-1;display:flex;flex-direction:column;gap:1rem}.extra-info[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;margin-bottom:.75rem}.extra-info[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{white-space:pre-wrap;padding:1rem;display:block;border-radius:var(--shape-2);background-color:var(--base-2)}.log-content[_ngcontent-%COMP%]{padding:1rem;display:grid;grid-template-columns:1fr 1fr;gap:1rem}.status[_ngcontent-%COMP%]{display:block;width:1rem;height:1rem;background-color:var(--success-8);border-radius:50%}.status.error[_ngcontent-%COMP%]{background-color:var(--error-8)}.status.warn[_ngcontent-%COMP%]{background-color:var(--warn-8)}"],changeDetection:0})};function _n(n,t){n&1&&s(0,"sh-progress-bar",1)}function ln(n,t){n&1&&(N(0,0,1),s(1,"sh-icon"),m())}function rn(n,t){n&1&&(N(0,0,2),s(1,"sh-icon"),m())}function sn(n,t){if(n&1){let e=U();o(0,"section",6)(1,"button",7),I("click",function(){D(e);let r=C(),p=r.$implicit,v=r.$index,y=C();return M(y.copyToClipboard(p.data,v))}),N(2,0),g(3,ln,2,0)(4,rn,2,0),m(),i(),o(5,"code"),E(6),u(7,"json"),i()()}if(n&2){let e=C(),_=e.$implicit,r=e.$index,p=C();a(),$("success",p.copiedFromIndex()===r),a(2),T(p.copiedFromIndex()===r?3:4),a(3),K(L(7,4,_.data))}}function Fn(n,t){if(n&1){let e=U();o(0,"article",2)(1,"header",3),I("click",function(){let r=D(e).$implicit,p=C();return M(p.toggleOpenEntry(r.id))}),o(2,"h3"),E(3),u(4,"date"),i(),o(5,"div",4)(6,"sh-icon",5),E(7,"caret-down"),i()()(),g(8,sn,8,6,"section",6),i()}if(n&2){let e=t.$implicit,_=C();a(3),$e("",S(4,6,e.timestamp,"medium"),": ",e.operation," ",e.path),a(3),$("open",e.id===_.openEntry()),a(2),T(e.id===_.openEntry()?8:-1)}}var pe=class n{#e=x(de);backupId=le.required();openEntry=A(null);pagination=A({offset:0,pagesize:100});copiedFromIndex=A(null);resource=ce({params:()=>_e({id:this.backupId()},this.pagination()),stream:({params:t})=>this.#e.getApiV1BackupByIdRemotelog({id:t.id,pagesize:100}).pipe(J(e=>e.map((_,r)=>({id:_.ID,operationId:_.OperationID,timestamp:_.Timestamp*1e3,operation:_.Operation,path:_.Path,data:typeof _.Data=="string"?JSON.parse(_.Data):null}))))});toggleOpenEntry(t){if(this.openEntry()===t){this.openEntry.set(null);return}this.openEntry.set(t)}copyToClipboard(t,e){let _=JSON.stringify(t,null,2);navigator.clipboard.writeText(_),this.copiedFromIndex.set(e),setTimeout(()=>{this.copiedFromIndex.set(null)},3e3)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=X({type:n,selectors:[["app-remote-log"]],inputs:{backupId:[1,"backupId"]},decls:3,vars:1,consts:()=>{let t;return t=$localize`${"\uFFFD*3:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:check${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Copied ${"\uFFFD/*3:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*4:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:copy${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Copy to clipboard ${"\uFFFD/*4:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,t=R(t),[t,[1,"indeterminate","primary"],[1,"log-entry"],[3,"click"],[1,"actions"],[1,"toggle-indicator"],[1,"log-content"],["shButton","",1,"small",3,"click"]]},template:function(e,_){e&1&&(g(0,_n,1,0,"sh-progress-bar",1),b(1,Fn,9,9,"article",2,B)),e&2&&(T(_.resource.isLoading()?0:-1),a(),k(_.resource.value()))},dependencies:[Fe,H,re,V],styles:["[_nghost-%COMP%]{display:block}.log-entry[_ngcontent-%COMP%]{display:flex;flex-direction:column}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.5rem;padding:1rem;border-bottom:1px solid var(--base-4);background-color:var(--base-1);cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]:hover{background-color:var(--base-2)}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-30);margin:0;-webkit-user-select:none;user-select:none}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.toggle-indicator[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:1.25rem;transition:transform 125ms linear}.toggle-indicator.open[_ngcontent-%COMP%]{transform:rotate(180deg)}.log-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem;position:relative}.log-content[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{position:absolute;top:2rem;right:2rem;background:transparent}code[_ngcontent-%COMP%]{white-space:pre-wrap;padding:1rem;display:block;border-radius:var(--shape-2);background-color:var(--base-2)}"],changeDetection:0})};function dn(n,t){if(n&1&&(E(0," - "),G(1),l(2,6),P(),E(3),u(4,"durationFormat")),n&2){C(2);let e=w(6);a(3),f(" ",L(4,1,e.Backup.Metadata==null?null:e.Backup.Metadata.LastBackupDuration)," ")}}function cn(n,t){n&1&&(G(0),l(1,7),P())}function un(n,t){if(n&1&&(E(0),u(1,"bytes")),n&2){C(2);let e=w(6);f(" ",L(1,1,e.Backup.Metadata==null?null:e.Backup.Metadata.SourceFilesSize)," ")}}function pn(n,t){n&1&&(G(0),l(1,8),P())}function En(n,t){if(n&1&&(E(0),u(1,"bytes")),n&2){C(2);let e=w(6);f(" ",L(1,1,e.Backup.Metadata==null?null:e.Backup.Metadata.TargetFilesSize)," ")}}function Cn(n,t){n&1&&(G(0),l(1,9),P())}function gn(n,t){if(n&1&&(o(0,"sh-chip",19),l(1,10),i()),n&2){C(2);let e=w(6);a(),d(e.Backup.Metadata==null?null:e.Backup.Metadata.BackupListCount),c(1)}}function Tn(n,t){n&1&&(o(0,"sh-chip",20),l(1,11),i())}function On(n,t){if(n&1&&(o(0,"div",14)(1,"div",18)(2,"h3"),E(3),o(4,"sh-icon"),E(5,"database"),i()(),o(6,"p")(7,"span"),l(8,3),i(),E(9),u(10,"date"),g(11,dn,5,3)(12,cn,2,0,"ng-container"),i(),o(13,"p")(14,"span"),l(15,4),i(),g(16,un,2,3)(17,pn,2,0,"ng-container"),i(),o(18,"p")(19,"span"),l(20,5),i(),g(21,En,2,3)(22,Cn,2,0,"ng-container"),i()(),g(23,gn,2,1,"sh-chip",19)(24,Tn,2,0,"sh-chip",20),i()),n&2){let e=C(),_=w(6);a(3),f(" ",_.Backup.Name??e.MISSING_BACKUP_NAME," "),a(6),f(" ",S(10,6,_.Backup.Metadata==null?null:_.Backup.Metadata.LastBackupDate,"short")," "),a(2),T(_.Backup.Metadata!=null&&_.Backup.Metadata.LastBackupDuration?11:12),a(5),T(_.Backup.Metadata!=null&&_.Backup.Metadata.SourceFilesSize?16:17),a(5),T(_.Backup.Metadata!=null&&_.Backup.Metadata.TargetFilesSize?21:22),a(2),T(_.Backup.Metadata!=null&&_.Backup.Metadata.BackupListCount?23:24)}}function Ln(n,t){if(n&1&&s(0,"app-general-log",17),n&2){let e=C();z("backupId",e.backupId())}}function Nn(n,t){if(n&1&&s(0,"app-remote-log",17),n&2){let e=C();z("backupId",e.backupId())}}var Ee=class n{#e=x(ye);#n=x(Ke);MISSING_BACKUP_NAME=$localize`Backup name missing`;activeTab=A("general");backupId=Je(this.#e.params.pipe(J(t=>t.id)));backup=ve(()=>{let t=this.backupId();return t?this.#n.getBackupById(t):null});static \u0275fac=function(e){return new(e||n)};static \u0275cmp=X({type:n,selectors:[["app-log"]],decls:15,vars:8,consts:()=>{let t;t=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON: Back `;let e;e=$localize`General`;let _;_=$localize` Destination `;let r;r=$localize`Last successful backup:`;let p;p=$localize`Source:`;let v;v=$localize`Destination:`;let y;y=$localize`took`;let j;j=$localize`N/A`;let W;W=$localize`N/A`;let q;q=$localize`N/A`;let Q;Q=$localize`${"\uFFFD0\uFFFD"}:INTERPOLATION: Version`;let Y;return Y=$localize`No version yet`,[t,e,_,r,p,v,y,j,W,q,Q,Y,[1,"back"],["type","button","shButton","","routerLink","/",1,"small"],[1,"backup"],[1,"primary"],["tab","",3,"click"],[3,"backupId"],[1,"text"],[1,"simple","success"],[1,"simple"]]},template:function(e,_){if(e&1){let r=U();s(0,"app-status-bar"),o(1,"section")(2,"div",12)(3,"button",13),N(4,0),s(5,"sh-icon"),m(),i()(),fe(6),g(7,On,25,9,"div",14),o(8,"sh-tabs",15)(9,"button",16),I("click",function(){return D(r),M(_.activeTab.set("general"))}),l(10,1),i(),o(11,"button",16),I("click",function(){return D(r),M(_.activeTab.set("destination"))}),l(12,2),i()(),g(13,Ln,1,1,"app-general-log",17),g(14,Nn,1,1,"app-remote-log",17),i()}if(e&2){a(6);let r=he(_.backup());a(),T(r?7:-1),a(2),$("active",_.activeTab()==="general"),a(2),$("active",_.activeTab()==="destination"),a(2),T(_.activeTab()==="general"?13:-1),a(),T(_.activeTab()==="destination"?14:-1)}},dependencies:[ke,ue,pe,xe,Xe,H,se,Be,Z,ee,V],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem 1.5rem;gap:1rem}sh-tabs[_ngcontent-%COMP%]{margin-bottom:1rem}.backup[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:2rem;gap:1rem;border:1px solid var(--base-4);border-radius:var(--shape-3);box-shadow:var(--box-shadow-10)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;width:100%;max-width:40%}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] h3[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{color:var(--base-8)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] p[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{color:var(--base-12)}"],changeDetection:0})};export{Ee as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as $e,b as He}from"./chunk-VSLN6R7K.js";import{a as we}from"./chunk-OWEK4OHZ.js";import{a as V}from"./chunk-Y4IW22ZU.js";import"./chunk-6CYY2QG6.js";import{a as Ge}from"./chunk-AO4ZIHUL.js";import"./chunk-SS7TCWY5.js";import"./chunk-6Q6SSTBK.js";import"./chunk-U63HBLGG.js";import"./chunk-AGPZBYW6.js";import"./chunk-WILUKPQ3.js";import{a as Re}from"./chunk-NEV6JB5M.js";import{a as ye}from"./chunk-6KSFCVWH.js";import"./chunk-CGKL2MHM.js";import{b as Ce,d as ve}from"./chunk-QWNOPLJC.js";import{a as be}from"./chunk-5UXRNNTT.js";import"./chunk-FBWFZMGL.js";import{B as R,G as Pe,H as Ie,J as Le,Q as Me,Y as De,c as Te,d as me,e as he,i as Ee,r as Ae,s as Fe,t as Oe,u as D,w as B,x as Ne,z as fe}from"./chunk-RYXU2QDS.js";import{b as Y}from"./chunk-BKANUILG.js";import{c as pe,e as Se,f as ge}from"./chunk-GO4NSDR6.js";import"./chunk-56FBKSBN.js";import"./chunk-FIBRO5I3.js";import"./chunk-RMOTUTEQ.js";import"./chunk-QF5K4MHH.js";import{$ as m,Ab as o,Bb as _,E as W,Fb as ie,Gb as oe,Ib as E,Mc as U,Pa as r,Pb as g,Qb as C,Qc as ue,Rb as f,Sc as de,Ub as G,Uc as Q,Vb as T,W as S,Xb as c,aa as h,cb as M,cc as ae,dc as se,gc as k,ic as L,jc as u,kc as q,la as F,lc as b,na as j,oc as y,pc as $,qc as H,rc as re,sb as d,sc as le,tb as p,tc as w,ub as ee,uc as _e,wb as te,xb as ne,xc as ce,yb as O,zb as a}from"./chunk-XYHHESIX.js";import{a as X,b as z}from"./chunk-7CGTOI24.js";var Be=["scroller"];function Ye(i,n){i&1&&(a(0,"sh-icon"),u(1,"bell-ringing"),o())}function Ve(i,n){i&1&&(a(0,"sh-icon"),u(1,"bell"),o())}function Je(i,n){if(i&1&&_(0,"app-notification",8),i&2){c(2);let e=w(6);O("index",0)("notification",e.content)}}function Xe(i,n){if(i&1&&(a(0,"div",11),u(1),o()),i&2){c(3);let e=w(6);r(),b(" ",e.content.content," ")}}function ze(i,n){if(i&1&&(a(0,"sh-alert")(1,"div",10),u(2),o(),d(3,Xe,2,1,"div",11),o()),i&2){c(2);let e=w(6);L(e.content.type||"error"),r(2),q(e.content.title),r(),p(e.content.content?3:-1)}}function We(i,n){if(i&1&&(a(0,"div",6),d(1,Je,1,2,"app-notification",8)(2,ze,4,4,"sh-alert",9),o()),i&2){c();let e=w(6);r(),p(e.type==="notification"?1:2)}}function je(i,n){if(i&1){let e=E();a(0,"div",7)(1,"div",12)(2,"h6",13),g(3,2),a(4,"button",5),T("click",function(){m(e);let s=c();return h(s.toggleNotifications())}),_(5,"sh-icon"),o(),C(),o(),a(6,"div",14,0)(8,"div",15),_(9,"app-notifications"),o()()()()}}function qe(i,n){if(i&1&&(a(0,"div",20),u(1),o()),i&2){let e=c().$implicit;r(),b(" ",e.content," ")}}function Qe(i,n){if(i&1){let e=E();a(0,"sh-alert",18,1),T("click",function(){let s=m(e).$implicit,l=c(2);return h(l.deleteAlertByIndex(s.id))}),a(2,"div",19),u(3),o(),d(4,qe,2,1,"div",20),o()}if(i&2){let e=n.$implicit;L(e.type),O("id",e.id),r(3),q(e.title),r(),p(e.content?4:-1)}}function Ke(i,n){i&1&&(a(0,"p",17),f(1,4),o())}function Ze(i,n){if(i&1){let e=E();a(0,"div",7)(1,"div",12)(2,"h6",13),g(3,3),a(4,"button",5),T("click",function(){m(e);let s=c();return h(s.toggleAlerts())}),_(5,"sh-icon"),o(),C(),o(),a(6,"div",14,0)(8,"div",15),te(9,Qe,5,5,"sh-alert",16,ee,!1,Ke,2,0,"p",17),o()()()()}if(i&2){let e=c();r(9),ne(e.alertHistory())}}var xe=new Ae,x=class i{#e=S(Ne);#t=S(V);isSubmitting=F(!1);messageSent=F(!1);form=xe.group({message:xe.control("",[me.required])});notifications=this.#t.notifications;shownMessage=F(null);shownMessageInterval=null;alertHistory=this.#e.alertHistory;alertHistoryIsOpen=this.#e.alertHistoryIsOpen;alertHistoryIsHidden=this.#e.alertHistoryIsHidden;numberOfOpenAlerts=U(()=>this.alertHistory().filter(n=>n.isOpen).length);scroller=de("scroller");isAlertsOpen=Q(!1);isNotificationsOpen=Q(!1);previousHistoryCount=F(null);previousNotificationsCount=F(null);constructor(){j(()=>{let n=this.alertHistory(),e=this.notifications();if(e.length===0){this.shownMessage.set(null);return}e.length&&this.previousHistoryCount()!==n.length&&!this.isNotificationsOpen()?(this.shownMessage.set({content:e[0],countDown:3,type:"notification"}),this.previousHistoryCount.set(n.length),this.shownMessageInterval=setInterval(()=>{let t=this.shownMessage();if(t?.countDown===0){this.shownMessage.set(null),this.shownMessageInterval=null;return}t!==null&&this.shownMessage.update(s=>z(X({},s),{countDown:s.countDown-1}))},1e3)):n.length&&this.previousHistoryCount()!==n.length&&!this.isAlertsOpen()&&(this.shownMessage.set({content:n[0],countDown:3,type:"alert"}),this.previousHistoryCount.set(n.length),this.shownMessageInterval=setInterval(()=>{let t=this.shownMessage();if(t?.countDown===0){this.shownMessage.set(null),this.shownMessageInterval=null;return}t!==null&&this.shownMessage.update(s=>z(X({},s),{countDown:s.countDown-1}))},1e3))}),j(()=>{this.alertHistoryIsOpen(),this.scrollToBottom()})}resetPreviewMessage(){this.shownMessage.set(null),this.shownMessageInterval=null}toggleAlerts(){this.isAlertsOpen()?this.isAlertsOpen.set(!1):(this.isAlertsOpen.set(!0),this.isNotificationsOpen.set(!1),this.resetPreviewMessage())}toggleNotifications(){this.isNotificationsOpen.set(!this.isNotificationsOpen()),this.isAlertsOpen()&&this.isAlertsOpen.set(!1)}deleteAlertByIndex(n){this.#e.removeAlert(n)}scrollToBottom(){this.scroller()&&this.scroller()?.nativeElement&&this.scroller().nativeElement.scrollTo(0,this.scroller().nativeElement.scrollHeight)}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=M({type:i,selectors:[["app-service-hub"]],viewQuery:function(e,t){e&1&&ae(t.scroller,Be,5),e&2&&se()},inputs:{isAlertsOpen:[1,"isAlertsOpen"],isNotificationsOpen:[1,"isNotificationsOpen"]},outputs:{isAlertsOpen:"isAlertsOpenChange",isNotificationsOpen:"isNotificationsOpenChange"},decls:10,vars:9,consts:()=>{let n;n=$localize` Notifications ${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:x-circle${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_BUTTON:`;let e;e=$localize` Alerts ${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:x-circle${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_BUTTON:`;let t;return t=$localize`No alerts yet`,[["scroller",""],["alerts",""],n,e,t,["shButton","",3,"click"],[1,"preview-alert-wrap"],[1,"alert-stream-modal"],[3,"index","notification"],[3,"class"],["ship-alert-title",""],["ship-alert-content",""],[1,"alert-stream-modal-content"],[1,"paragraph-20"],[1,"alert-stream-modal-list-scroller"],[1,"alert-stream-modal-list"],[3,"class","id"],[1,"no-alerts"],[3,"click","id"],["title",""],["content",""]]},template:function(e,t){if(e&1){let s=E();a(0,"button",5),T("click",function(){return m(s),h(t.toggleAlerts())}),a(1,"sh-icon"),u(2,"info"),o()(),a(3,"button",5),T("click",function(){return m(s),h(t.toggleNotifications())}),d(4,Ye,2,0,"sh-icon")(5,Ve,2,0,"sh-icon"),o(),re(6),d(7,We,3,1,"div",6),d(8,je,10,0,"div",7),d(9,Ze,12,1,"div",7)}if(e&2){L(t.alertHistory().length?"error":""),r(3),L(t.notifications().length?"error":""),r(),p(t.notifications().length?4:5),r(2);let s=le(t.shownMessage());r(),p(s?7:-1),r(),p(t.isNotificationsOpen()?8:-1),r(),p(t.isAlertsOpen()?9:-1)}},dependencies:[Oe,B,D,R,He,$e],styles:["[_nghost-%COMP%]{display:flex;position:fixed;gap:.5rem;bottom:1.5rem;right:1.5rem;z-index:5000}@media only screen and (max-width:768px){[_nghost-%COMP%]{bottom:1rem;right:1rem}}[_nghost-%COMP%] h6[_ngcontent-%COMP%]{margin:0}.preview-alert-wrap[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column;min-width:15.625rem}.helpdesk-modal[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column}@media only screen and (max-width:768px){.helpdesk-modal[_ngcontent-%COMP%]{bottom:2.6875rem}}.helpdesk-modal-content[_ngcontent-%COMP%]{position:relative;display:flex;flex-direction:column;gap:1rem;min-width:20rem;border:1px solid var(--base-4);background-color:var(--base-1);border-radius:var(--shape-2)}.helpdesk-modal-content[_ngcontent-%COMP%] .message-sent[_ngcontent-%COMP%]{padding:0 1rem 1rem;text-wrap:pretty}.helpdesk-modal-content[_ngcontent-%COMP%] h6[_ngcontent-%COMP%]{padding:1rem;border-bottom:1px solid var(--base-4);display:flex;align-items:center;justify-content:space-between}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%]{padding:0 1rem 1rem;display:flex;flex-direction:column;align-items:flex-end;gap:1rem}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{width:100%;text-wrap:pretty}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%] mat-form-field[_ngcontent-%COMP%]{width:100%}.alert-stream-modal[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column}@media only screen and (max-width:768px){.alert-stream-modal[_ngcontent-%COMP%]{bottom:2.6875rem}}.alert-stream-modal-list-scroller[_ngcontent-%COMP%]{overflow-y:auto;max-height:18.75rem}.alert-stream-modal-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem;padding:1rem;border-radius:var(--shape-2)}.alert-stream-modal-content[_ngcontent-%COMP%]{position:relative;display:flex;flex-direction:column;min-width:20rem;border:1px solid var(--base-4);background-color:var(--base-1);border-radius:var(--shape-2)}.alert-stream-modal-content[_ngcontent-%COMP%] h6[_ngcontent-%COMP%]{padding:1rem;border-bottom:1px solid var(--base-4);display:flex;align-items:center;justify-content:space-between}.no-alerts[_ngcontent-%COMP%]{padding:1rem;display:flex;flex-direction:column;gap:1rem;text-align:center}"],changeDetection:0})};function et(i,n){i&1&&(a(0,"sh-icon",14),u(1,"check"),o())}function tt(i,n){i&1&&(a(0,"sh-icon",15),u(1,"prohibit"),o())}function nt(i,n){if(i&1){let e=E();a(0,"button",20),T("click",function(){m(e);let s=c();return h(s.updatePassphrase())}),f(1,5),o()}if(i&2){let e=c();k("loader",e.isUpdating())}}function it(i,n){if(i&1){let e=E();a(0,"button",21),T("click",function(){m(e);let s=c();return h(s.updatePassphrase())}),f(1,6),o()}if(i&2){let e=c();k("loader",e.isUpdating()),O("disabled",!0)}}var J=class i{#e=S(Y);closed=ue();isUpdating=F(!1);passphrase=F("");repeatPassphrase=F("");updatePassphrase(){this.passphrase()===this.repeatPassphrase()&&(this.isUpdating.set(!0),this.#e.patchApiV1Serversettings({requestBody:{"server-passphrase":this.passphrase()}}).pipe(W(()=>this.isUpdating.set(!1))).subscribe({next:()=>this.closed.emit()}))}cancel(){this.isUpdating.set(!0),this.#e.patchApiV1Serversettings({requestBody:{"has-asked-for-password-change":"True"}}).pipe(W(()=>this.isUpdating.set(!1))).subscribe({next:()=>this.closed.emit()})}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=M({type:i,selectors:[["app-change-passphrase-alert-dialog"]],outputs:{closed:"closed"},decls:23,vars:7,consts:()=>{let n;n=$localize`Enter new password`;let e;e=$localize`Repeat password`;let t;t=$localize`Password have to be filled and have to match`;let s;s=$localize`Change passphrase`;let l;l=$localize` Duplicati needs to be secured with a passphrase and a random passphrase has been generated for you. ${"[\uFFFD#6\uFFFD\uFFFD/#6\uFFFD|\uFFFD#7\uFFFD\uFFFD/#7\uFFFD]"}:LINE_BREAK:${"[\uFFFD#6\uFFFD\uFFFD/#6\uFFFD|\uFFFD#7\uFFFD\uFFFD/#7\uFFFD]"}:LINE_BREAK: If you open Duplicati from the tray icon, you do not need a passphrase, but if you plan to open it from another location you need to set a passphrase you know. Do you want to set a passphrase now? `,l=G(l);let P;P=$localize`Passphrase`;let I;I=$localize`Repeat passphrase`;let v;v=$localize`Not now thanks`;let A;A=$localize` Yes, update passphrase now `;let Z;return Z=$localize` Yes, update passphrase now `,[s,l,P,I,v,A,Z,["header",""],["content",""],["type","warning"],["for","password"],["type","password","name","password","autocomplete","disabled","placeholder",n,"tabindex","1",3,"ngModelChange","ngModel"],["for","repeatPassword"],["type","password","name","repeatPassword","autocomplete","disabled","placeholder",e,"tabindex","2",3,"ngModelChange","disabled","ngModel"],["suffix","",1,"sh-success"],["suffix",""],["footer",""],["shButton","",3,"click"],["shButton","",1,"raised","primary",3,"loader"],["shButton","","shTooltip",t,1,"raised","primary",3,"loader","disabled"],["shButton","",1,"raised","primary",3,"click"],["shButton","","shTooltip",t,1,"raised","primary",3,"click","disabled"]]},template:function(e,t){e&1&&(a(0,"header",7)(1,"h3"),f(2,0),o()(),a(3,"div",8)(4,"sh-alert",9),g(5,1),_(6,"br")(7,"br"),C(),o(),a(8,"sh-form-field")(9,"label",10),f(10,2),o(),a(11,"input",11),H("ngModelChange",function(l){return $(t.passphrase,l)||(t.passphrase=l),l}),o()(),a(12,"sh-form-field")(13,"label",12),f(14,3),o(),a(15,"input",13),H("ngModelChange",function(l){return $(t.repeatPassphrase,l)||(t.repeatPassphrase=l),l}),o(),d(16,et,2,0,"sh-icon",14)(17,tt,2,0,"sh-icon",15),o()(),a(18,"footer",16)(19,"button",17),T("click",function(){return t.cancel()}),f(20,4),o(),d(21,nt,2,2,"button",18)(22,it,2,3,"button",19),o()),e&2&&(r(11),y("ngModel",t.passphrase),r(4),O("disabled",t.passphrase().length===0),y("ngModel",t.repeatPassphrase),r(),p(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?16:17),r(3),k("loader",t.isUpdating()),r(2),p(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?21:22))},dependencies:[Fe,Te,he,Ee,B,Ie,D,De,R],styles:["[_nghost-%COMP%]{display:block;--dialog-p: 1.5rem}[content][_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}"],changeDetection:0})};var ot=()=>({exact:!0});function at(i,n){i&1&&(a(0,"sh-icon",26),u(1,"x-bold"),o())}function st(i,n){i&1&&(a(0,"sh-icon",27),u(1,"list-bold"),o())}function rt(i,n){if(i&1){let e=E();ie(0,9),a(1,"button",25),T("click",function(){m(e);let s=c();return h(s.toggleNav())}),d(2,at,2,0,"sh-icon",26)(3,st,2,0,"sh-icon",27),o(),oe()}if(i&2){let e=c();r(2),p(e.isNavOpen()?2:3)}}function lt(i,n){i&1&&(a(0,"sh-icon"),u(1,"sun"),o())}function _t(i,n){i&1&&(a(0,"sh-icon"),u(1,"moon"),o())}function ct(i,n){if(i&1){let e=E();a(0,"button",28),T("click",function(){m(e);let s=c();return h(s.logout())}),g(1,7),_(2,"sh-icon"),C(),o()}}var K=class i{#e=S(we);#t=S(Y);#i=S(Ge);#o=S(Ce);#a=S(fe);#s=S(V);#r=S(ve);#l=S(be);#n=S(Re);relayIsEnabled=this.#o.relayIsEnabled;isDarkMode=this.#e.isDarkMode;isNavOpen=this.#e.isNavOpen;isMobile=this.#e.isMobile;sidenavType=this.#e.sidenavType;machineName=U(()=>{let n=this.#l.serverSettings();if(n&&n["--machine-name"])return n["--machine-name"];if(n&&n["machine-name"])return n["machine-name"];let e=this.#n.allOptions().find(t=>t.name==="machine-name");return e&&e.defaultValue?e.defaultValue:this.#n.systemInfo()?.MachineName??"Unknown"});ngOnInit(){return this.#s.init(),this.#i.getBackups(!0),this.#t.getApiV1Serversettings().subscribe({next:n=>{let e=n["autogenerated-passphrase"]==="True",t=n["has-asked-for-password-change"]==="True";e&&!t&&this.#a.open(J,{maxWidth:"500px"})}})}toggleNav(){this.#e.toggleNav()}toggleBodyClass(){this.#e.toggleBodyClass()}changeDefaultClientTo(n){this.#_(n),window.location.replace(`/${n}`)}logout(){this.#r.logout()}#_(n){var e=new Date;e.setTime(e.getTime()+2160*60*60*1e3),document.cookie="default-client="+n+"; expires="+e.toUTCString()+"; path=/"}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=M({type:i,selectors:[["app-layout"]],decls:42,vars:12,consts:()=>{let n;n=$localize`${"\uFFFD#11\uFFFD"}:START_TAG_SH_ICON:house${"\uFFFD/#11\uFFFD"}:CLOSE_TAG_SH_ICON: Home `;let e;e=$localize`${"\uFFFD#14\uFFFD"}:START_TAG_SH_ICON:database${"\uFFFD/#14\uFFFD"}:CLOSE_TAG_SH_ICON: Add backup `;let t;t=$localize`${"\uFFFD#17\uFFFD"}:START_TAG_SH_ICON:clock-counter-clockwise${"\uFFFD/#17\uFFFD"}:CLOSE_TAG_SH_ICON: Restore `;let s;s=$localize`${"\uFFFD#20\uFFFD"}:START_TAG_SH_ICON:gear${"\uFFFD/#20\uFFFD"}:CLOSE_TAG_SH_ICON: Settings `;let l;l=$localize`${"\uFFFD#30\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#30\uFFFD"}:CLOSE_TAG_SH_ICON: About Duplicati `;let P;P=$localize`${"\uFFFD#33\uFFFD"}:START_TAG_SH_ICON:files${"[\uFFFD/#33\uFFFD|\uFFFD/#34\uFFFD]"}:CLOSE_TAG_SH_ICON: Documentation ${"\uFFFD#34\uFFFD"}:START_TAG_SH_ICON_1:arrow-square-out${"[\uFFFD/#33\uFFFD|\uFFFD/#34\uFFFD]"}:CLOSE_TAG_SH_ICON:`,P=G(P);let I;I=$localize`${"\uFFFD#37\uFFFD"}:START_TAG_SH_ICON:chats-circle${"[\uFFFD/#37\uFFFD|\uFFFD/#38\uFFFD]"}:CLOSE_TAG_SH_ICON: Visit forum ${"\uFFFD#38\uFFFD"}:START_TAG_SH_ICON_1:arrow-square-out${"[\uFFFD/#37\uFFFD|\uFFFD/#38\uFFFD]"}:CLOSE_TAG_SH_ICON:`,I=G(I);let v;return v=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:sign-out${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Log out `,[n,e,t,s,l,P,I,v,[3,"isOpenChange","isOpen","disableDrag"],["sidenav-closed-topbar",""],["sidenav",""],["shButton","",1,"icon","small",3,"click"],[1,"base-1","primary"],["action","","routerLink","/","routerLinkActive","active",3,"routerLinkActiveOptions"],["action","","routerLink","/add-backup","routerLinkActive","active"],["action","","routerLink","/restore","routerLinkActive","active"],["action","","routerLink","/settings","routerLinkActive","active"],[1,"spacer"],[1,"base-1l","primary"],["action","",1,"machine-name",3,"title"],["action","","routerLink","/about","routerLinkActive","active"],["href","https://docs.duplicati.com","target","_blank","action",""],["suffix",""],["href","https://forum.duplicati.com","target","_blank","action",""],["action",""],["shButton","",1,"small","toggle-sidebar",3,"click"],[1,"cross"],[1,"burger"],["action","",3,"click"]]},template:function(e,t){e&1&&(a(0,"sh-sidenav",8),H("isOpenChange",function(l){return $(t.isNavOpen,l)||(t.isNavOpen=l),l}),d(1,rt,4,1,"ng-container",9),a(2,"div",10)(3,"header"),_(4,"app-logo"),a(5,"button",11),T("click",function(){return t.toggleBodyClass()}),d(6,lt,2,0,"sh-icon")(7,_t,2,0,"sh-icon"),o()(),a(8,"sh-list",12)(9,"button",13),g(10,0),_(11,"sh-icon"),C(),o(),a(12,"button",14),g(13,1),_(14,"sh-icon"),C(),o(),a(15,"button",15),g(16,2),_(17,"sh-icon"),C(),o(),a(18,"button",16),g(19,3),_(20,"sh-icon"),C(),o()(),_(21,"div",17),a(22,"sh-list",18)(23,"div",19)(24,"sh-icon"),u(25,"desktop"),o(),u(26),o(),_(27,"sh-divider"),a(28,"button",20),g(29,4),_(30,"sh-icon"),C(),o(),a(31,"a",21),g(32,5),_(33,"sh-icon")(34,"sh-icon",22),C(),o(),a(35,"a",23),g(36,6),_(37,"sh-icon")(38,"sh-icon",22),C(),o(),d(39,ct,3,0,"button",24),o()(),_(40,"router-outlet")(41,"app-service-hub"),o()),e&2&&(L(t.sidenavType()),y("isOpen",t.isNavOpen),O("disableDrag",!0),r(),p(t.isMobile()?1:-1),r(5),p(t.isDarkMode()?6:7),r(3),O("routerLinkActiveOptions",ce(11,ot)),r(14),O("title",_e(t.machineName())),r(3),b(" ",t.machineName()," "),r(13),p(t.relayIsEnabled()?-1:39))},dependencies:[pe,Se,ge,Me,D,Le,R,Pe,x,ye],styles:["[_nghost-%COMP%]{height:100vh;width:100%;overflow:hidden}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:1.25rem;gap:.75rem}.toggle-sidebar[_ngcontent-%COMP%]{position:relative;display:flex;align-items:center;justify-content:center}.toggle-sidebar[_ngcontent-%COMP%] .cross[_ngcontent-%COMP%], .toggle-sidebar[_ngcontent-%COMP%] .burger[_ngcontent-%COMP%]{opacity:1;transition:opacity 124ms linear;margin:0}.toggle-sidebar[_ngcontent-%COMP%] .cross.hidden[_ngcontent-%COMP%], .toggle-sidebar[_ngcontent-%COMP%] .burger.hidden[_ngcontent-%COMP%]{opacity:0}.toggle-sidebar[_ngcontent-%COMP%] .burger[_ngcontent-%COMP%]{position:absolute;inset:auto}h3[title][_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between}div[sidenav][_ngcontent-%COMP%]{display:flex;flex-direction:column;height:100vh}.machine-name[_ngcontent-%COMP%]{margin:0;cursor:default}"],changeDetection:0})};export{K as default};
|
|
1
|
+
import{a as $e,b as He}from"./chunk-HGZYRAXZ.js";import{a as we}from"./chunk-OWEK4OHZ.js";import{a as V}from"./chunk-6AX4L2U5.js";import"./chunk-7XLQX4B6.js";import{a as Ge}from"./chunk-QNZTEY37.js";import"./chunk-6Q6SSTBK.js";import"./chunk-U63HBLGG.js";import"./chunk-AGPZBYW6.js";import"./chunk-WILUKPQ3.js";import{a as ye}from"./chunk-6KSFCVWH.js";import"./chunk-CGKL2MHM.js";import{a as be}from"./chunk-RIVMPP47.js";import"./chunk-FBWFZMGL.js";import"./chunk-PNYEL323.js";import{a as Re}from"./chunk-NEV6JB5M.js";import{b as Ce,d as ve}from"./chunk-QWNOPLJC.js";import{B as R,G as Pe,H as Ie,J as Le,Q as Me,Y as De,c as Te,d as me,e as he,i as Ee,r as Ae,s as Fe,t as Oe,u as D,w as B,x as Ne,z as fe}from"./chunk-RYXU2QDS.js";import{b as Y}from"./chunk-BKANUILG.js";import{c as pe,e as Se,f as ge}from"./chunk-GO4NSDR6.js";import"./chunk-56FBKSBN.js";import"./chunk-FIBRO5I3.js";import"./chunk-RMOTUTEQ.js";import"./chunk-QF5K4MHH.js";import{$ as m,Ab as o,Bb as _,E as W,Fb as ie,Gb as oe,Ib as E,Mc as U,Pa as r,Pb as g,Qb as C,Qc as ue,Rb as f,Sc as de,Ub as G,Uc as Q,Vb as T,W as S,Xb as c,aa as h,cb as M,cc as ae,dc as se,gc as k,ic as L,jc as u,kc as q,la as F,lc as b,na as j,oc as y,pc as $,qc as H,rc as re,sb as d,sc as le,tb as p,tc as w,ub as ee,uc as _e,wb as te,xb as ne,xc as ce,yb as O,zb as a}from"./chunk-XYHHESIX.js";import{a as X,b as z}from"./chunk-7CGTOI24.js";var Be=["scroller"];function Ye(i,n){i&1&&(a(0,"sh-icon"),u(1,"bell-ringing"),o())}function Ve(i,n){i&1&&(a(0,"sh-icon"),u(1,"bell"),o())}function Je(i,n){if(i&1&&_(0,"app-notification",8),i&2){c(2);let e=w(6);O("index",0)("notification",e.content)}}function Xe(i,n){if(i&1&&(a(0,"div",11),u(1),o()),i&2){c(3);let e=w(6);r(),b(" ",e.content.content," ")}}function ze(i,n){if(i&1&&(a(0,"sh-alert")(1,"div",10),u(2),o(),d(3,Xe,2,1,"div",11),o()),i&2){c(2);let e=w(6);L(e.content.type||"error"),r(2),q(e.content.title),r(),p(e.content.content?3:-1)}}function We(i,n){if(i&1&&(a(0,"div",6),d(1,Je,1,2,"app-notification",8)(2,ze,4,4,"sh-alert",9),o()),i&2){c();let e=w(6);r(),p(e.type==="notification"?1:2)}}function je(i,n){if(i&1){let e=E();a(0,"div",7)(1,"div",12)(2,"h6",13),g(3,2),a(4,"button",5),T("click",function(){m(e);let s=c();return h(s.toggleNotifications())}),_(5,"sh-icon"),o(),C(),o(),a(6,"div",14,0)(8,"div",15),_(9,"app-notifications"),o()()()()}}function qe(i,n){if(i&1&&(a(0,"div",20),u(1),o()),i&2){let e=c().$implicit;r(),b(" ",e.content," ")}}function Qe(i,n){if(i&1){let e=E();a(0,"sh-alert",18,1),T("click",function(){let s=m(e).$implicit,l=c(2);return h(l.deleteAlertByIndex(s.id))}),a(2,"div",19),u(3),o(),d(4,qe,2,1,"div",20),o()}if(i&2){let e=n.$implicit;L(e.type),O("id",e.id),r(3),q(e.title),r(),p(e.content?4:-1)}}function Ke(i,n){i&1&&(a(0,"p",17),f(1,4),o())}function Ze(i,n){if(i&1){let e=E();a(0,"div",7)(1,"div",12)(2,"h6",13),g(3,3),a(4,"button",5),T("click",function(){m(e);let s=c();return h(s.toggleAlerts())}),_(5,"sh-icon"),o(),C(),o(),a(6,"div",14,0)(8,"div",15),te(9,Qe,5,5,"sh-alert",16,ee,!1,Ke,2,0,"p",17),o()()()()}if(i&2){let e=c();r(9),ne(e.alertHistory())}}var xe=new Ae,x=class i{#e=S(Ne);#t=S(V);isSubmitting=F(!1);messageSent=F(!1);form=xe.group({message:xe.control("",[me.required])});notifications=this.#t.notifications;shownMessage=F(null);shownMessageInterval=null;alertHistory=this.#e.alertHistory;alertHistoryIsOpen=this.#e.alertHistoryIsOpen;alertHistoryIsHidden=this.#e.alertHistoryIsHidden;numberOfOpenAlerts=U(()=>this.alertHistory().filter(n=>n.isOpen).length);scroller=de("scroller");isAlertsOpen=Q(!1);isNotificationsOpen=Q(!1);previousHistoryCount=F(null);previousNotificationsCount=F(null);constructor(){j(()=>{let n=this.alertHistory(),e=this.notifications();if(e.length===0){this.shownMessage.set(null);return}e.length&&this.previousHistoryCount()!==n.length&&!this.isNotificationsOpen()?(this.shownMessage.set({content:e[0],countDown:3,type:"notification"}),this.previousHistoryCount.set(n.length),this.shownMessageInterval=setInterval(()=>{let t=this.shownMessage();if(t?.countDown===0){this.shownMessage.set(null),this.shownMessageInterval=null;return}t!==null&&this.shownMessage.update(s=>z(X({},s),{countDown:s.countDown-1}))},1e3)):n.length&&this.previousHistoryCount()!==n.length&&!this.isAlertsOpen()&&(this.shownMessage.set({content:n[0],countDown:3,type:"alert"}),this.previousHistoryCount.set(n.length),this.shownMessageInterval=setInterval(()=>{let t=this.shownMessage();if(t?.countDown===0){this.shownMessage.set(null),this.shownMessageInterval=null;return}t!==null&&this.shownMessage.update(s=>z(X({},s),{countDown:s.countDown-1}))},1e3))}),j(()=>{this.alertHistoryIsOpen(),this.scrollToBottom()})}resetPreviewMessage(){this.shownMessage.set(null),this.shownMessageInterval=null}toggleAlerts(){this.isAlertsOpen()?this.isAlertsOpen.set(!1):(this.isAlertsOpen.set(!0),this.isNotificationsOpen.set(!1),this.resetPreviewMessage())}toggleNotifications(){this.isNotificationsOpen.set(!this.isNotificationsOpen()),this.isAlertsOpen()&&this.isAlertsOpen.set(!1)}deleteAlertByIndex(n){this.#e.removeAlert(n)}scrollToBottom(){this.scroller()&&this.scroller()?.nativeElement&&this.scroller().nativeElement.scrollTo(0,this.scroller().nativeElement.scrollHeight)}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=M({type:i,selectors:[["app-service-hub"]],viewQuery:function(e,t){e&1&&ae(t.scroller,Be,5),e&2&&se()},inputs:{isAlertsOpen:[1,"isAlertsOpen"],isNotificationsOpen:[1,"isNotificationsOpen"]},outputs:{isAlertsOpen:"isAlertsOpenChange",isNotificationsOpen:"isNotificationsOpenChange"},decls:10,vars:9,consts:()=>{let n;n=$localize` Notifications ${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:x-circle${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_BUTTON:`;let e;e=$localize` Alerts ${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:x-circle${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_BUTTON:`;let t;return t=$localize`No alerts yet`,[["scroller",""],["alerts",""],n,e,t,["shButton","",3,"click"],[1,"preview-alert-wrap"],[1,"alert-stream-modal"],[3,"index","notification"],[3,"class"],["ship-alert-title",""],["ship-alert-content",""],[1,"alert-stream-modal-content"],[1,"paragraph-20"],[1,"alert-stream-modal-list-scroller"],[1,"alert-stream-modal-list"],[3,"class","id"],[1,"no-alerts"],[3,"click","id"],["title",""],["content",""]]},template:function(e,t){if(e&1){let s=E();a(0,"button",5),T("click",function(){return m(s),h(t.toggleAlerts())}),a(1,"sh-icon"),u(2,"info"),o()(),a(3,"button",5),T("click",function(){return m(s),h(t.toggleNotifications())}),d(4,Ye,2,0,"sh-icon")(5,Ve,2,0,"sh-icon"),o(),re(6),d(7,We,3,1,"div",6),d(8,je,10,0,"div",7),d(9,Ze,12,1,"div",7)}if(e&2){L(t.alertHistory().length?"error":""),r(3),L(t.notifications().length?"error":""),r(),p(t.notifications().length?4:5),r(2);let s=le(t.shownMessage());r(),p(s?7:-1),r(),p(t.isNotificationsOpen()?8:-1),r(),p(t.isAlertsOpen()?9:-1)}},dependencies:[Oe,B,D,R,He,$e],styles:["[_nghost-%COMP%]{display:flex;position:fixed;gap:.5rem;bottom:1.5rem;right:1.5rem;z-index:5000}@media only screen and (max-width:768px){[_nghost-%COMP%]{bottom:1rem;right:1rem}}[_nghost-%COMP%] h6[_ngcontent-%COMP%]{margin:0}.preview-alert-wrap[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column;min-width:15.625rem}.helpdesk-modal[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column}@media only screen and (max-width:768px){.helpdesk-modal[_ngcontent-%COMP%]{bottom:2.6875rem}}.helpdesk-modal-content[_ngcontent-%COMP%]{position:relative;display:flex;flex-direction:column;gap:1rem;min-width:20rem;border:1px solid var(--base-4);background-color:var(--base-1);border-radius:var(--shape-2)}.helpdesk-modal-content[_ngcontent-%COMP%] .message-sent[_ngcontent-%COMP%]{padding:0 1rem 1rem;text-wrap:pretty}.helpdesk-modal-content[_ngcontent-%COMP%] h6[_ngcontent-%COMP%]{padding:1rem;border-bottom:1px solid var(--base-4);display:flex;align-items:center;justify-content:space-between}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%]{padding:0 1rem 1rem;display:flex;flex-direction:column;align-items:flex-end;gap:1rem}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{width:100%;text-wrap:pretty}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%] mat-form-field[_ngcontent-%COMP%]{width:100%}.alert-stream-modal[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column}@media only screen and (max-width:768px){.alert-stream-modal[_ngcontent-%COMP%]{bottom:2.6875rem}}.alert-stream-modal-list-scroller[_ngcontent-%COMP%]{overflow-y:auto;max-height:18.75rem}.alert-stream-modal-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem;padding:1rem;border-radius:var(--shape-2)}.alert-stream-modal-content[_ngcontent-%COMP%]{position:relative;display:flex;flex-direction:column;min-width:20rem;border:1px solid var(--base-4);background-color:var(--base-1);border-radius:var(--shape-2)}.alert-stream-modal-content[_ngcontent-%COMP%] h6[_ngcontent-%COMP%]{padding:1rem;border-bottom:1px solid var(--base-4);display:flex;align-items:center;justify-content:space-between}.no-alerts[_ngcontent-%COMP%]{padding:1rem;display:flex;flex-direction:column;gap:1rem;text-align:center}"],changeDetection:0})};function et(i,n){i&1&&(a(0,"sh-icon",14),u(1,"check"),o())}function tt(i,n){i&1&&(a(0,"sh-icon",15),u(1,"prohibit"),o())}function nt(i,n){if(i&1){let e=E();a(0,"button",20),T("click",function(){m(e);let s=c();return h(s.updatePassphrase())}),f(1,5),o()}if(i&2){let e=c();k("loader",e.isUpdating())}}function it(i,n){if(i&1){let e=E();a(0,"button",21),T("click",function(){m(e);let s=c();return h(s.updatePassphrase())}),f(1,6),o()}if(i&2){let e=c();k("loader",e.isUpdating()),O("disabled",!0)}}var J=class i{#e=S(Y);closed=ue();isUpdating=F(!1);passphrase=F("");repeatPassphrase=F("");updatePassphrase(){this.passphrase()===this.repeatPassphrase()&&(this.isUpdating.set(!0),this.#e.patchApiV1Serversettings({requestBody:{"server-passphrase":this.passphrase()}}).pipe(W(()=>this.isUpdating.set(!1))).subscribe({next:()=>this.closed.emit()}))}cancel(){this.isUpdating.set(!0),this.#e.patchApiV1Serversettings({requestBody:{"has-asked-for-password-change":"True"}}).pipe(W(()=>this.isUpdating.set(!1))).subscribe({next:()=>this.closed.emit()})}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=M({type:i,selectors:[["app-change-passphrase-alert-dialog"]],outputs:{closed:"closed"},decls:23,vars:7,consts:()=>{let n;n=$localize`Enter new password`;let e;e=$localize`Repeat password`;let t;t=$localize`Password have to be filled and have to match`;let s;s=$localize`Change passphrase`;let l;l=$localize` Duplicati needs to be secured with a passphrase and a random passphrase has been generated for you. ${"[\uFFFD#6\uFFFD\uFFFD/#6\uFFFD|\uFFFD#7\uFFFD\uFFFD/#7\uFFFD]"}:LINE_BREAK:${"[\uFFFD#6\uFFFD\uFFFD/#6\uFFFD|\uFFFD#7\uFFFD\uFFFD/#7\uFFFD]"}:LINE_BREAK: If you open Duplicati from the tray icon, you do not need a passphrase, but if you plan to open it from another location you need to set a passphrase you know. Do you want to set a passphrase now? `,l=G(l);let P;P=$localize`Passphrase`;let I;I=$localize`Repeat passphrase`;let v;v=$localize`Not now thanks`;let A;A=$localize` Yes, update passphrase now `;let Z;return Z=$localize` Yes, update passphrase now `,[s,l,P,I,v,A,Z,["header",""],["content",""],["type","warning"],["for","password"],["type","password","name","password","autocomplete","disabled","placeholder",n,"tabindex","1",3,"ngModelChange","ngModel"],["for","repeatPassword"],["type","password","name","repeatPassword","autocomplete","disabled","placeholder",e,"tabindex","2",3,"ngModelChange","disabled","ngModel"],["suffix","",1,"sh-success"],["suffix",""],["footer",""],["shButton","",3,"click"],["shButton","",1,"raised","primary",3,"loader"],["shButton","","shTooltip",t,1,"raised","primary",3,"loader","disabled"],["shButton","",1,"raised","primary",3,"click"],["shButton","","shTooltip",t,1,"raised","primary",3,"click","disabled"]]},template:function(e,t){e&1&&(a(0,"header",7)(1,"h3"),f(2,0),o()(),a(3,"div",8)(4,"sh-alert",9),g(5,1),_(6,"br")(7,"br"),C(),o(),a(8,"sh-form-field")(9,"label",10),f(10,2),o(),a(11,"input",11),H("ngModelChange",function(l){return $(t.passphrase,l)||(t.passphrase=l),l}),o()(),a(12,"sh-form-field")(13,"label",12),f(14,3),o(),a(15,"input",13),H("ngModelChange",function(l){return $(t.repeatPassphrase,l)||(t.repeatPassphrase=l),l}),o(),d(16,et,2,0,"sh-icon",14)(17,tt,2,0,"sh-icon",15),o()(),a(18,"footer",16)(19,"button",17),T("click",function(){return t.cancel()}),f(20,4),o(),d(21,nt,2,2,"button",18)(22,it,2,3,"button",19),o()),e&2&&(r(11),y("ngModel",t.passphrase),r(4),O("disabled",t.passphrase().length===0),y("ngModel",t.repeatPassphrase),r(),p(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?16:17),r(3),k("loader",t.isUpdating()),r(2),p(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?21:22))},dependencies:[Fe,Te,he,Ee,B,Ie,D,De,R],styles:["[_nghost-%COMP%]{display:block;--dialog-p: 1.5rem}[content][_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}"],changeDetection:0})};var ot=()=>({exact:!0});function at(i,n){i&1&&(a(0,"sh-icon",26),u(1,"x-bold"),o())}function st(i,n){i&1&&(a(0,"sh-icon",27),u(1,"list-bold"),o())}function rt(i,n){if(i&1){let e=E();ie(0,9),a(1,"button",25),T("click",function(){m(e);let s=c();return h(s.toggleNav())}),d(2,at,2,0,"sh-icon",26)(3,st,2,0,"sh-icon",27),o(),oe()}if(i&2){let e=c();r(2),p(e.isNavOpen()?2:3)}}function lt(i,n){i&1&&(a(0,"sh-icon"),u(1,"sun"),o())}function _t(i,n){i&1&&(a(0,"sh-icon"),u(1,"moon"),o())}function ct(i,n){if(i&1){let e=E();a(0,"button",28),T("click",function(){m(e);let s=c();return h(s.logout())}),g(1,7),_(2,"sh-icon"),C(),o()}}var K=class i{#e=S(we);#t=S(Y);#i=S(Ge);#o=S(Ce);#a=S(fe);#s=S(V);#r=S(ve);#l=S(be);#n=S(Re);relayIsEnabled=this.#o.relayIsEnabled;isDarkMode=this.#e.isDarkMode;isNavOpen=this.#e.isNavOpen;isMobile=this.#e.isMobile;sidenavType=this.#e.sidenavType;machineName=U(()=>{let n=this.#l.serverSettings();if(n&&n["--machine-name"])return n["--machine-name"];if(n&&n["machine-name"])return n["machine-name"];let e=this.#n.allOptions().find(t=>t.name==="machine-name");return e&&e.defaultValue?e.defaultValue:this.#n.systemInfo()?.MachineName??"Unknown"});ngOnInit(){return this.#s.init(),this.#i.getBackups(!0),this.#t.getApiV1Serversettings().subscribe({next:n=>{let e=n["autogenerated-passphrase"]==="True",t=n["has-asked-for-password-change"]==="True";e&&!t&&this.#a.open(J,{maxWidth:"500px"})}})}toggleNav(){this.#e.toggleNav()}toggleBodyClass(){this.#e.toggleBodyClass()}changeDefaultClientTo(n){this.#_(n),window.location.replace(`/${n}`)}logout(){this.#r.logout()}#_(n){var e=new Date;e.setTime(e.getTime()+2160*60*60*1e3),document.cookie="default-client="+n+"; expires="+e.toUTCString()+"; path=/"}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=M({type:i,selectors:[["app-layout"]],decls:42,vars:12,consts:()=>{let n;n=$localize`${"\uFFFD#11\uFFFD"}:START_TAG_SH_ICON:house${"\uFFFD/#11\uFFFD"}:CLOSE_TAG_SH_ICON: Home `;let e;e=$localize`${"\uFFFD#14\uFFFD"}:START_TAG_SH_ICON:database${"\uFFFD/#14\uFFFD"}:CLOSE_TAG_SH_ICON: Add backup `;let t;t=$localize`${"\uFFFD#17\uFFFD"}:START_TAG_SH_ICON:clock-counter-clockwise${"\uFFFD/#17\uFFFD"}:CLOSE_TAG_SH_ICON: Restore `;let s;s=$localize`${"\uFFFD#20\uFFFD"}:START_TAG_SH_ICON:gear${"\uFFFD/#20\uFFFD"}:CLOSE_TAG_SH_ICON: Settings `;let l;l=$localize`${"\uFFFD#30\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#30\uFFFD"}:CLOSE_TAG_SH_ICON: About Duplicati `;let P;P=$localize`${"\uFFFD#33\uFFFD"}:START_TAG_SH_ICON:files${"[\uFFFD/#33\uFFFD|\uFFFD/#34\uFFFD]"}:CLOSE_TAG_SH_ICON: Documentation ${"\uFFFD#34\uFFFD"}:START_TAG_SH_ICON_1:arrow-square-out${"[\uFFFD/#33\uFFFD|\uFFFD/#34\uFFFD]"}:CLOSE_TAG_SH_ICON:`,P=G(P);let I;I=$localize`${"\uFFFD#37\uFFFD"}:START_TAG_SH_ICON:chats-circle${"[\uFFFD/#37\uFFFD|\uFFFD/#38\uFFFD]"}:CLOSE_TAG_SH_ICON: Visit forum ${"\uFFFD#38\uFFFD"}:START_TAG_SH_ICON_1:arrow-square-out${"[\uFFFD/#37\uFFFD|\uFFFD/#38\uFFFD]"}:CLOSE_TAG_SH_ICON:`,I=G(I);let v;return v=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:sign-out${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Log out `,[n,e,t,s,l,P,I,v,[3,"isOpenChange","isOpen","disableDrag"],["sidenav-closed-topbar",""],["sidenav",""],["shButton","",1,"icon","small",3,"click"],[1,"base-1","primary"],["action","","routerLink","/","routerLinkActive","active",3,"routerLinkActiveOptions"],["action","","routerLink","/add-backup","routerLinkActive","active"],["action","","routerLink","/restore","routerLinkActive","active"],["action","","routerLink","/settings","routerLinkActive","active"],[1,"spacer"],[1,"base-1l","primary"],["action","",1,"machine-name",3,"title"],["action","","routerLink","/about","routerLinkActive","active"],["href","https://docs.duplicati.com","target","_blank","action",""],["suffix",""],["href","https://forum.duplicati.com","target","_blank","action",""],["action",""],["shButton","",1,"small","toggle-sidebar",3,"click"],[1,"cross"],[1,"burger"],["action","",3,"click"]]},template:function(e,t){e&1&&(a(0,"sh-sidenav",8),H("isOpenChange",function(l){return $(t.isNavOpen,l)||(t.isNavOpen=l),l}),d(1,rt,4,1,"ng-container",9),a(2,"div",10)(3,"header"),_(4,"app-logo"),a(5,"button",11),T("click",function(){return t.toggleBodyClass()}),d(6,lt,2,0,"sh-icon")(7,_t,2,0,"sh-icon"),o()(),a(8,"sh-list",12)(9,"button",13),g(10,0),_(11,"sh-icon"),C(),o(),a(12,"button",14),g(13,1),_(14,"sh-icon"),C(),o(),a(15,"button",15),g(16,2),_(17,"sh-icon"),C(),o(),a(18,"button",16),g(19,3),_(20,"sh-icon"),C(),o()(),_(21,"div",17),a(22,"sh-list",18)(23,"div",19)(24,"sh-icon"),u(25,"desktop"),o(),u(26),o(),_(27,"sh-divider"),a(28,"button",20),g(29,4),_(30,"sh-icon"),C(),o(),a(31,"a",21),g(32,5),_(33,"sh-icon")(34,"sh-icon",22),C(),o(),a(35,"a",23),g(36,6),_(37,"sh-icon")(38,"sh-icon",22),C(),o(),d(39,ct,3,0,"button",24),o()(),_(40,"router-outlet")(41,"app-service-hub"),o()),e&2&&(L(t.sidenavType()),y("isOpen",t.isNavOpen),O("disableDrag",!0),r(),p(t.isMobile()?1:-1),r(5),p(t.isDarkMode()?6:7),r(3),O("routerLinkActiveOptions",ce(11,ot)),r(14),O("title",_e(t.machineName())),r(3),b(" ",t.machineName()," "),r(13),p(t.relayIsEnabled()?-1:39))},dependencies:[pe,Se,ge,Me,D,Le,R,Pe,x,ye],styles:["[_nghost-%COMP%]{height:100vh;width:100%;overflow:hidden}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:1.25rem;gap:.75rem}.toggle-sidebar[_ngcontent-%COMP%]{position:relative;display:flex;align-items:center;justify-content:center}.toggle-sidebar[_ngcontent-%COMP%] .cross[_ngcontent-%COMP%], .toggle-sidebar[_ngcontent-%COMP%] .burger[_ngcontent-%COMP%]{opacity:1;transition:opacity 124ms linear;margin:0}.toggle-sidebar[_ngcontent-%COMP%] .cross.hidden[_ngcontent-%COMP%], .toggle-sidebar[_ngcontent-%COMP%] .burger.hidden[_ngcontent-%COMP%]{opacity:0}.toggle-sidebar[_ngcontent-%COMP%] .burger[_ngcontent-%COMP%]{position:absolute;inset:auto}h3[title][_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between}div[sidenav][_ngcontent-%COMP%]{display:flex;flex-direction:column;height:100vh}.machine-name[_ngcontent-%COMP%]{margin:0;cursor:default}"],changeDetection:0})};export{K as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as St}from"./chunk-GMNCWLGX.js";import{b as Oe,c as gt,d as Et}from"./chunk-B5LH4P4E.js";import{a as pt,b as Ve,c as Ct}from"./chunk-TJYZBTTS.js";import{a as dt}from"./chunk-WILUKPQ3.js";import{a as ct}from"./chunk-RIVMPP47.js";import{b as le}from"./chunk-FBWFZMGL.js";import{a as Re}from"./chunk-NEV6JB5M.js";import{B as ae,F as st,H as Q,L as lt,P as se,V as rt,W as Me,Y as _t,b as Fe,c as j,d as he,e as q,f as Ne,h as et,i as ie,j as fe,k as tt,n as nt,o as it,p as Pe,q as Ae,r as De,s as oe,t as ye,u as Y,w as ot,z as at}from"./chunk-RYXU2QDS.js";import{b as ut}from"./chunk-BKANUILG.js";import{b as ne,d as z}from"./chunk-GO4NSDR6.js";import{$ as g,Ab as l,Bb as T,E as $e,Fb as b,Gb as v,Ib as $,Mc as L,Pa as r,Pb as S,Qb as m,Qc as ke,R as Ce,Rb as f,Rc as Be,Sc as Te,Ub as be,Vb as h,W as y,Xb as u,aa as E,cb as H,cc as ge,dc as Ee,gc as Se,hb as qe,jc as G,kb as Ye,kc as ve,la as p,lc as Ze,na as te,oc as R,pc as O,qc as w,rb as Qe,sb as A,tb as D,ub as Ge,wb as Ue,xb as xe,xc as me,yb as F,zb as s}from"./chunk-XYHHESIX.js";import{a as J,b as X}from"./chunk-7CGTOI24.js";var we=class o{fromString(t){if(!t)return null;let e=t.match(/(\d+)([smhDWMY])/);return e&&{value:parseInt(e[1]),unit:e[2]}}toString(t,e){return`${t}${e}`}static \u0275fac=function(e){return new(e||o)};static \u0275prov=Ce({token:o,factory:o.\u0275fac,providedIn:"root"})};function ce(o){if(Ye(o))return o();if(Array.isArray(o))return o.map(t=>ce(t));if(typeof o=="object"&&o!==null){let t={};for(let e in o)o.hasOwnProperty(e)&&(t[e]=ce(o[e]));return t}return o}function Nt(o,t){if(o&1){let e=$();s(0,"div",26)(1,"sh-form-field")(2,"label",27),f(3,7),l(),s(4,"input",28,0),w("ngModelChange",function(i){g(e);let a=u(2);return O(a.scheduleFields.nextTime.time,i)||(a.scheduleFields.nextTime.time=i),E(i)}),l(),s(6,"sh-icon",29),G(7,"clock"),l()(),s(8,"sh-datepicker-input",30)(9,"label",31),G(10,"\xA0"),l(),s(11,"input",32,1),w("ngModelChange",function(i){g(e);let a=u(2);return O(a.scheduleFields.nextTime.date,i)||(a.scheduleFields.nextTime.date=i),E(i)}),l(),s(13,"sh-icon",29),G(14,"calendar"),l()()(),s(15,"div",26)(16,"sh-form-field")(17,"label",33),f(18,8),l(),s(19,"input",34),w("ngModelChange",function(i){g(e);let a=u(2);return O(a.scheduleFields.runAgain.repeatValue,i)||(a.scheduleFields.runAgain.repeatValue=i),E(i)}),l()(),s(20,"sh-select",35)(21,"input",36),w("ngModelChange",function(i){g(e);let a=u(2);return O(a.scheduleFields.runAgain.repeatUnit,i)||(a.scheduleFields.runAgain.repeatUnit=i),E(i)}),l()()(),s(22,"sh-toggle-card",37),b(23,38),f(24,9),v(),s(25,"div",39)(26,"sh-toggle",24),S(27,10),s(28,"input",25),w("ngModelChange",function(i){g(e);let a=u(2);return O(a.scheduleFields.runAgain.allowedDays.mon,i)||(a.scheduleFields.runAgain.allowedDays.mon=i),E(i)}),l(),m(),l(),s(29,"sh-toggle",24),S(30,11),s(31,"input",25),w("ngModelChange",function(i){g(e);let a=u(2);return O(a.scheduleFields.runAgain.allowedDays.tue,i)||(a.scheduleFields.runAgain.allowedDays.tue=i),E(i)}),l(),m(),l(),s(32,"sh-toggle",24),S(33,12),s(34,"input",25),w("ngModelChange",function(i){g(e);let a=u(2);return O(a.scheduleFields.runAgain.allowedDays.wed,i)||(a.scheduleFields.runAgain.allowedDays.wed=i),E(i)}),l(),m(),l(),s(35,"sh-toggle",24),S(36,13),s(37,"input",25),w("ngModelChange",function(i){g(e);let a=u(2);return O(a.scheduleFields.runAgain.allowedDays.thu,i)||(a.scheduleFields.runAgain.allowedDays.thu=i),E(i)}),l(),m(),l(),s(38,"sh-toggle",24),S(39,14),s(40,"input",25),w("ngModelChange",function(i){g(e);let a=u(2);return O(a.scheduleFields.runAgain.allowedDays.fri,i)||(a.scheduleFields.runAgain.allowedDays.fri=i),E(i)}),l(),m(),l(),s(41,"sh-toggle",24),S(42,15),s(43,"input",25),w("ngModelChange",function(i){g(e);let a=u(2);return O(a.scheduleFields.runAgain.allowedDays.sat,i)||(a.scheduleFields.runAgain.allowedDays.sat=i),E(i)}),l(),m(),l(),s(44,"sh-toggle",24),S(45,16),s(46,"input",25),w("ngModelChange",function(i){g(e);let a=u(2);return O(a.scheduleFields.runAgain.allowedDays.sun,i)||(a.scheduleFields.runAgain.allowedDays.sun=i),E(i)}),l(),m(),l()()()}if(o&2){let e=u(2);r(4),R("ngModel",e.scheduleFields.nextTime.time),r(7),R("ngModel",e.scheduleFields.nextTime.date),r(8),R("ngModel",e.scheduleFields.runAgain.repeatValue),r(),F("options",e.unitOptions)("isClearable",!1),r(),R("ngModel",e.scheduleFields.runAgain.repeatUnit),r(),F("disallowToggle",!0),r(6),R("ngModel",e.scheduleFields.runAgain.allowedDays.mon),r(3),R("ngModel",e.scheduleFields.runAgain.allowedDays.tue),r(3),R("ngModel",e.scheduleFields.runAgain.allowedDays.wed),r(3),R("ngModel",e.scheduleFields.runAgain.allowedDays.thu),r(3),R("ngModel",e.scheduleFields.runAgain.allowedDays.fri),r(3),R("ngModel",e.scheduleFields.runAgain.allowedDays.sat),r(3),R("ngModel",e.scheduleFields.runAgain.allowedDays.sun)}}function ft(o,t){if(o&1){let e=$();s(0,"div",23)(1,"sh-toggle",24),S(2,5),s(3,"input",25),w("ngModelChange",function(i){g(e);let a=u();return O(a.scheduleFields.autoRun,i)||(a.scheduleFields.autoRun=i),E(i)}),l(),m(),l(),s(4,"p"),f(5,6),l()(),A(6,Nt,47,14)}if(o&2){let e=u();r(3),R("ngModel",e.scheduleFields.autoRun),r(3),D(e.scheduleFields.autoRun()?6:-1)}}var Pt=[{key:"s",label:$localize`Seconds`},{key:"m",label:$localize`Minutes`},{key:"h",label:$localize`Hours`},{key:"D",label:$localize`Days`},{key:"W",label:$localize`Weeks`},{key:"M",label:$localize`Months`},{key:"Y",label:$localize`Years`}],Ie=[{key:$localize`Daily 13:00`,value:"daily",data:{autoRun:!0,nextTime:{time:"13:00:00",date:new Date().toISOString().split("T")[0]},runAgain:{repeatValue:1,repeatUnit:"D",allowedDays:{mon:!0,tue:!0,wed:!0,thu:!0,fri:!0,sat:!0,sun:!0}}}},{key:$localize`Weekdays 13:00`,value:"weekdays",data:{autoRun:!0,nextTime:{time:"13:00:00",date:new Date().toISOString().split("T")[0]},runAgain:{repeatValue:1,repeatUnit:"D",allowedDays:{mon:!0,tue:!0,wed:!0,thu:!0,fri:!0,sat:!1,sun:!1}}}},{key:$localize`Weekly monday 13:00`,value:"weekly",data:{autoRun:!0,nextTime:{time:"13:00:00",date:At().toISOString().split("T")[0]},runAgain:{repeatValue:1,repeatUnit:"W",allowedDays:{mon:!0,tue:!1,wed:!1,thu:!1,fri:!1,sat:!1,sun:!1}}}},{key:$localize`Don't run automatically`,value:"disabled",data:{autoRun:!1,nextTime:{time:"13:00:00",date:new Date().toISOString().split("T")[0]},runAgain:{repeatValue:1,repeatUnit:"D",allowedDays:{mon:!0,tue:!0,wed:!0,thu:!0,fri:!0,sat:!0,sun:!0}}}},{key:$localize`Custom`,value:"custom",data:{autoRun:!0,nextTime:{time:"13:00:00",date:new Date().toISOString().split("T")[0]},runAgain:{repeatValue:1,repeatUnit:"D",allowedDays:{mon:!0,tue:!0,wed:!0,thu:!0,fri:!0,sat:!0,sun:!0}}}}];function mt(o){if(!o.autoRun)return null;let t=[o.runAgain.allowedDays.mon?"Monday":null,o.runAgain.allowedDays.tue?"Tuesday":null,o.runAgain.allowedDays.wed?"Wednesday":null,o.runAgain.allowedDays.thu?"Thursday":null,o.runAgain.allowedDays.fri?"Friday":null,o.runAgain.allowedDays.sat?"Saturday":null,o.runAgain.allowedDays.sun?"Sunday":null].filter(c=>c!==null),e=o.nextTime.time.split(":"),n=new Date(o.nextTime.date);n.setHours(parseInt(e[0])),n.setMinutes(parseInt(e[1]));let i=o.runAgain.repeatValue,a=o.runAgain.repeatUnit;return{Time:n.toISOString(),Repeat:`${i}${a}`,AllowedDays:t}}function At(){let o=new Date,t=o.getDay(),e=t===1?7:(8-t)%7;return o.setDate(o.getDate()+e),o.setHours(12,0,0,0),o}var Xe=()=>({autoRun:p(!0),nextTime:{time:p("13:00"),date:p(new Date().toISOString().split("T")[0])},runAgain:{repeatValue:p(1),repeatUnit:p("D"),allowedDays:{mon:p(!0),tue:p(!0),wed:p(!0),thu:p(!0),fri:p(!0),sat:p(!0),sun:p(!0)}}}),Ke=class o{#e=y(Z);#t=y(z);#i=y(ne);unitOptions=Pt;scheduleFields=this.#e.scheduleFields;scheduleType=this.#e.scheduleType;scheduleOptions=Ie;updateScheduleType(t){let e=Ie.find(n=>n.value===t);if(e&&e?.value!=="custom"){this.scheduleType.set(e.value);let n=e.data;this.scheduleFields.autoRun.set(n.autoRun??!1),this.scheduleFields.nextTime.time.set(n.nextTime?.time??"13:00"),this.scheduleFields.nextTime.date.set(n.nextTime?.date??new Date().toISOString().split("T")[0]),this.scheduleFields.runAgain.repeatValue.set(n.runAgain?.repeatValue??1),this.scheduleFields.runAgain.repeatUnit.set(n.runAgain?.repeatUnit??"D"),this.scheduleFields.runAgain.allowedDays.mon.set(n.runAgain?.allowedDays?.mon??!0),this.scheduleFields.runAgain.allowedDays.tue.set(n.runAgain?.allowedDays?.tue??!0),this.scheduleFields.runAgain.allowedDays.wed.set(n.runAgain?.allowedDays?.wed??!0),this.scheduleFields.runAgain.allowedDays.thu.set(n.runAgain?.allowedDays?.thu??!0),this.scheduleFields.runAgain.allowedDays.fri.set(n.runAgain?.allowedDays?.fri??!0),this.scheduleFields.runAgain.allowedDays.sat.set(n.runAgain?.allowedDays?.sat??!0),this.scheduleFields.runAgain.allowedDays.sun.set(n.runAgain?.allowedDays?.sun??!0)}else this.scheduleType.set("custom")}goBack(){this.#t.navigate(["source-data"],{relativeTo:this.#i.parent})}next(){this.#e.isNew()||this.#e.submit(!0),this.#t.navigate(["options"],{relativeTo:this.#i.parent})}static \u0275fac=function(e){return new(e||o)};static \u0275cmp=H({type:o,selectors:[["app-schedule"]],decls:12,vars:4,consts:()=>{let t;t=$localize`Select an option...`;let e;e=$localize`Schedule`;let n;n=$localize`${"\uFFFD#8\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#8\uFFFD"}:CLOSE_TAG_SH_ICON: Go back `;let i;i=$localize`${"\uFFFD#11\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#11\uFFFD"}:CLOSE_TAG_SH_ICON: Continue `;let a;a=$localize` Automatically run backups ${"\uFFFD#3\uFFFD\uFFFD/#3\uFFFD"}:TAG_INPUT:`;let c;c=$localize`If a date was missed, the job will run as soon as possible.`;let C;C=$localize`Next time`;let _;_=$localize`Run again every`;let d;d=$localize`Allowed days`;let I;I=$localize` Monday ${"\uFFFD#28\uFFFD\uFFFD/#28\uFFFD"}:TAG_INPUT:`;let U;U=$localize` Tuesday ${"\uFFFD#31\uFFFD\uFFFD/#31\uFFFD"}:TAG_INPUT:`;let B;B=$localize` Wednesday ${"\uFFFD#34\uFFFD\uFFFD/#34\uFFFD"}:TAG_INPUT:`;let V;V=$localize` Thursday ${"\uFFFD#37\uFFFD\uFFFD/#37\uFFFD"}:TAG_INPUT:`;let x;x=$localize` Friday ${"\uFFFD#40\uFFFD\uFFFD/#40\uFFFD"}:TAG_INPUT:`;let K;K=$localize` Saturday ${"\uFFFD#43\uFFFD\uFFFD/#43\uFFFD"}:TAG_INPUT:`;let W;return W=$localize` Sunday ${"\uFFFD#46\uFFFD\uFFFD/#46\uFFFD"}:TAG_INPUT:`,[["timeRef",""],["dateRef",""],e,n,i,a,c,C,_,d,I,U,B,V,x,K,W,[1,"title-30"],["label","key","value","value",3,"isClearable","options"],["type","text","placeholder",t,3,"ngModelChange","ngModel"],[1,"form-actions"],["shButton","","type","button",3,"click"],["shButton","",1,"raised","primary",3,"click"],[1,"toggle-wrap"],[1,"raised","primary"],["type","checkbox",3,"ngModelChange","ngModel"],[1,"row-inputs"],["for","time"],["type","time","id","time",3,"ngModelChange","ngModel"],["suffix",""],[1,"primary","sharp"],["for","date"],["type","text","id","date",3,"ngModelChange","ngModel"],["for","repeatValue"],["type","number","id","repeatValue",3,"ngModelChange","ngModel"],["value","key","label","label",3,"options","isClearable"],["type","text","id","repeatUnit",3,"ngModelChange","ngModel"],[3,"disallowToggle"],["title",""],[1,"days-wrap"]]},template:function(e,n){e&1&&(s(0,"h3",17),f(1,2),l(),s(2,"sh-select",18)(3,"input",19),h("ngModelChange",function(a){return n.updateScheduleType(a)}),l()(),A(4,ft,7,2),s(5,"div",20)(6,"button",21),h("click",function(){return n.goBack()}),S(7,3),T(8,"sh-icon"),m(),l(),s(9,"button",22),h("click",function(){return n.next()}),S(10,4),T(11,"sh-icon"),m(),l()()),e&2&&(r(2),F("isClearable",!1)("options",n.scheduleOptions),r(),F("ngModel",n.scheduleType()),r(),D(n.scheduleType()==="custom"?4:-1))},dependencies:[oe,j,tt,Fe,q,ie,Q,Me,Y,ae,se,rt,st],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:40rem;padding:2.5rem 2.5rem 1.5rem;display:flex;flex-direction:column;gap:1.5rem}.toggle-wrap[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.row-inputs[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.5rem}.row-inputs[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{flex:1 0}.days-wrap[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}"],changeDetection:0})};function Dt(o,t){if(o&1){let e=$();s(0,"sh-select",2)(1,"input",6),w("ngModelChange",function(i){g(e);let a=u();return O(a.internalPath,i)||(a.internalPath=i),E(i)}),h("ngModelChange",function(){g(e);let i=u();return E(i.updateFilter())}),l()()}if(o&2){let e=u();F("options",e.fileGroupOptions())("isClearable",!1)("selectMultiple",!0),r(),R("ngModel",e.internalPath)}}function yt(o,t){if(o&1&&(b(0,7),G(1),v()),o&2){let e,n=u(2);r(),ve((e=n.currentExpressionOption())==null?null:e.startsWith)}}function Mt(o,t){if(o&1&&(b(0,8),G(1),v()),o&2){let e,n=u(2);r(),ve((e=n.currentExpressionOption())==null?null:e.endsWith)}}function Rt(o,t){if(o&1){let e=$();s(0,"sh-form-field",3)(1,"input",6),w("ngModelChange",function(i){g(e);let a=u();return O(a.internalPath,i)||(a.internalPath=i),E(i)}),h("ngModelChange",function(){g(e);let i=u();return E(i.updateFilter())}),l(),A(2,yt,2,1,"ng-container",7),A(3,Mt,2,1,"ng-container",8),l()}if(o&2){let e,n,i=u();r(),R("ngModel",i.internalPath),r(),D(!((e=i.currentExpressionOption())==null||e.startsWith==null)&&e.startsWith.length?2:-1),r(),D(!((n=i.currentExpressionOption())==null||n.endsWith==null)&&n.endsWith.length?3:-1)}}var Ot=[{key:"Applications",value:"Applications"},{key:"CacheFiles",value:"Cache Files"},{key:"TemporaryFiles",value:"Temporary Files"},{key:"OperatingSystem",value:"Operating System"},{key:"SystemFiles",value:"System Files"},{key:"DefaultExcludes",value:"Standard Excludes"}],wt=[{key:"Excludes folders where name contains",value:"-FolderName"},{key:"Excludes folder",value:"-Folder"},{key:"Excludes files where name contains",value:"-FileName"},{key:"Excludes file extension",value:"-Extension"},{key:"Excludes files where name matches regex",value:"-Regex"},{key:"Includes files where name matches regex",value:"+Regex"},{key:"Exclude file groups",value:"-FileGroup"},{key:"Includes expression",value:"+Expression"},{key:"Excludes expression",value:"-Expression"},{key:"None",value:"-Unknown"}],Le=class o{path=Be.required();osType=Be();pathChange=ke();remove=ke();internalPath=p("");pathType=p("-Expression");currentExpressionOption=L(()=>{let t=this.pathType();return this.expressionOptions().find(e=>e.value===t)});fileGroupOptions=p(Ot);expressionOptions=L(()=>{let e=this.osType()==="Windows"?"\\":"/";return wt.map(n=>n.value==="-Folder"||n.value==="+Folder"?X(J({},n),{startsWith:"",endsWith:""}):n.value==="-FolderName"||n.value==="+FolderName"?X(J({},n),{startsWith:"*",endsWith:`*${e}`}):n.value==="-FileName"||n.value==="+FileName"?X(J({},n),{startsWith:"[.*",endsWith:`[^\\${e}]*]`}):n.value==="-FileGroup"||n.value==="+FileGroup"?X(J({},n),{startsWith:"{",endsWith:"}"}):n.value==="-Regex"||n.value==="+Regex"?X(J({},n),{startsWith:"[",endsWith:"]"}):n.value==="-Extension"||n.value==="+Extension"?X(J({},n),{startsWith:"*.",endsWith:""}):X(J({},n),{startsWith:"",endsWith:""}))});pathEffect=te(()=>{let t=this.path(),e=t.slice(1),n=t.startsWith("-")?"-":"+",i=this.osType()==="Windows",a=i?"\\":"/";e.startsWith("%")&&e.endsWith(a)||i&&e.slice(2).startsWith(a)&&e.endsWith(a)||e.startsWith(a)&&e.endsWith(a)?(this.pathType.set(`${n}Folder`),this.internalPath.set(e)):e.startsWith("*")&&e.endsWith(`*${a}`)?(this.pathType.set(`${n}FolderName`),this.internalPath.set(e.slice(1,-2))):e.startsWith("[.*")&&e.endsWith(`[^\\${a}]*]`)?(this.pathType.set(`${n}FileName`),this.internalPath.set(e.slice(3,-7))):e.startsWith("{")&&e.endsWith("}")?(this.pathType.set(`${n}FileGroup`),this.internalPath.set(e.slice(1,-1))):e.startsWith("[")&&e.endsWith("]")?(this.pathType.set(`${n}Regex`),this.internalPath.set(e.slice(1,-1))):e.startsWith("*.")?(this.pathType.set(`${n}Extension`),this.internalPath.set(e.slice(2))):(this.pathType.set(`${n}Expression`),this.internalPath.set(e))});updateFilter(){let t=this.internalPath(),e=this.currentExpressionOption();t!==""&&this.pathChange.emit(`${e?.value.slice(0,1)}${e?.startsWith??""}${t}${e?.endsWith??""}`)}removeFilter(){this.remove.emit()}static \u0275fac=function(e){return new(e||o)};static \u0275cmp=H({type:o,selectors:[["app-new-filter"]],inputs:{path:[1,"path"],osType:[1,"osType"]},outputs:{pathChange:"pathChange",remove:"remove"},decls:7,vars:4,consts:()=>{let t;return t=$localize`Select an option...`,[["value","value","label","key",3,"options","isClearable"],["type","text","placeholder",t,3,"ngModelChange","ngModel"],["value","key","label","value",1,"expression-input",3,"options","isClearable","selectMultiple"],[1,"expression-input"],[1,"filter-removal",3,"click"],[1,"sh-primary"],["type","text",3,"ngModelChange","ngModel"],["prefix",""],["suffix",""]]},template:function(e,n){if(e&1&&(s(0,"sh-select",0)(1,"input",1),w("ngModelChange",function(a){return O(n.pathType,a)||(n.pathType=a),a}),h("ngModelChange",function(){return n.updateFilter()}),l()(),A(2,Dt,2,4,"sh-select",2)(3,Rt,4,3,"sh-form-field",3),s(4,"div",4),h("click",function(){return n.removeFilter()}),s(5,"sh-icon",5),G(6,"x-circle"),l()()),e&2){let i;F("options",n.expressionOptions())("isClearable",!1),r(),R("ngModel",n.pathType),r(),D(((i=n.currentExpressionOption())==null?null:i.value)=="-FileGroup"||((i=n.currentExpressionOption())==null?null:i.value)=="+FileGroup"?2:3)}},dependencies:[oe,j,q,ie,se,Q,Y],styles:["[_nghost-%COMP%]{display:grid;grid-template-columns:13.125rem 1fr 1.875rem;gap:.5rem;align-items:flex-end}.expression-input[_ngcontent-%COMP%]{--ff-suffix-bg: var(--base-2)}.filter-removal[_ngcontent-%COMP%]{cursor:pointer;display:flex;align-items:center;justify-content:center;height:2.5rem;flex:0 0}"],changeDetection:0})};var It=["formRef"],ze=()=>({standalone:!0});function Lt(o,t){if(o&1){let e=$();s(0,"sh-form-field",41)(1,"input",42),w("ngModelChange",function(i){g(e);let a=u(2);return O(a.editingPath,i)||(a.editingPath=i),E(i)}),l()(),s(2,"button",43),h("click",function(){g(e);let i=u(2);return E(i.updatePath())}),s(3,"sh-icon"),G(4,"floppy-disk"),l()(),s(5,"button",43),h("click",function(){g(e);let i=u(2);return E(i.cancelEditPath())}),s(6,"sh-icon"),G(7,"x-bold"),l()()}if(o&2){let e=u(2);r(),R("ngModel",e.editingPath),F("ngModelOptions",me(2,ze))}}function $t(o,t){if(o&1){let e=$();s(0,"sh-form-field",41),T(1,"input",44),l(),s(2,"button",43),h("click",function(){g(e);let i=u().$implicit,a=u();return E(a.editPath(i))}),s(3,"sh-icon"),G(4,"pen"),l()(),s(5,"button",43),h("click",function(){g(e);let i=u().$implicit,a=u();return E(a.removePath(i))}),s(6,"sh-icon"),G(7,"trash-simple"),l()()}if(o&2){let e=u().$implicit;Qe("readonly",!0),r(),F("ngModel",e)("ngModelOptions",me(3,ze))}}function Gt(o,t){if(o&1&&(s(0,"div",30),A(1,Lt,8,3)(2,$t,8,4),l()),o&2){let e=t.$implicit,n=u();r(),D(n.oldPath()===e?1:2)}}function Ut(o,t){if(o&1){let e=$();s(0,"app-new-filter",46),h("pathChange",function(i){let a=g(e).$index,c=u(2);return E(c.patchPathAt(i,a))})("remove",function(){let i=g(e).$index,a=u(2);return E(a.removePathAt(i))}),l()}if(o&2){let e=t.$implicit,n=u(2);F("path",e)("osType",n.osType()??"")}}function xt(o,t){if(o&1&&Ue(0,Ut,1,2,"app-new-filter",45,Ge),o&2){let e=u();xe(e.pathArray())}}function bt(o,t){if(o&1){let e=$();s(0,"div",31)(1,"app-size",47),h("ngModelChange",function(i){g(e);let a=u();return E(a.updateFilesLargerThan(i))}),l()()}if(o&2){let e=u();r(),F("ngModel",e.filesLargerThan())("ngModelOptions",me(2,ze))}}var k=new De,Tt=(o={path:"",filters:[],excludes:{hidden:!1,system:!1,temporary:!1,filesLargerThan:null}})=>k.group({path:k.control(o.path),excludes:k.group({hidden:k.control(o.excludes.hidden),system:k.control(o.excludes.system),temporary:k.control(o.excludes.temporary),filesLargerThan:k.group({size:k.control(null),unit:k.control(null)})})}),He=class o{#e=y(Z);#t=y(z);#i=y(ne);formRef=Te.required("formRef");sourceDataForm=this.#e.sourceDataForm;sourceDataFormSignal=this.#e.sourceDataFormSignal;newPathCtrl=new et("");filesLargerThan=L(()=>{let t=this.sourceDataFormSignal()?.excludes?.filesLargerThan??{};return t.size!==null&&t.unit!==null?`${t.size}${t.unit}`:null});osType=this.#e.osType;pathSignal=le(this.sourceDataForm.controls.path.valueChanges);pathArray=L(()=>this.pathSignal()?.split("\0").filter(t=>t.startsWith("-")||t.startsWith("+")||t==="___none___")??[]);nonFilterPaths=L(()=>this.pathSignal()?.split("\0").filter(t=>!t.startsWith("-")&&!t.startsWith("+")&&t!==""));oldPath=p(null);editingPath=p(null);addingNewPath=p(!1);editPath(t){this.oldPath.set(t),this.editingPath.set(t)}updateFilesLargerThan(t){let{size:e,unit:n}=Oe(t);this.sourceDataForm.controls.excludes.controls.filesLargerThan.setValue({size:e,unit:n})}updatePath(){let t=this.oldPath(),e=this.editingPath();if(!t||!e||e===t){this.oldPath.set(null),this.editingPath.set(null);return}let n=this.sourceDataForm.controls.path.value;this.sourceDataForm.controls.path.setValue(n?.replace(t,e)??""),this.oldPath.set(null),this.editingPath.set(null)}cancelEditPath(){this.oldPath.set(null),this.editingPath.set(null)}removePath(t){let n=(this.sourceDataForm.controls.path.value??"").split("\0"),i=n.indexOf(t);if(i===-1)return;n.splice(i,1);let a=n.filter(c=>c&&c!=="").join("\0");this.sourceDataForm.controls.path.setValue(a)}addFilter(t="-*"){let n=[this.sourceDataForm.controls.path.value,t].filter(i=>i&&i!=="").join("\0");this.sourceDataForm.controls.path.setValue(n)}patchPathAt(t,e){let i=this.sourceDataForm.controls.path.value.split("\0").filter(C=>!C.startsWith("-")&&!C.startsWith("+")).join("\0"),a=this.pathArray().map((C,_)=>_===e?`${t}`:`${C}`).join("\0"),c=[i,a].filter(C=>C&&C!=="").join("\0");this.sourceDataForm.controls.path.setValue(c)}removePathAt(t){let n=this.sourceDataForm.controls.path.value.split("\0").filter(c=>!c.startsWith("-")&&!c.startsWith("+")).join("\0"),i=this.pathArray().filter((c,C)=>C!==t).join("\0"),a=[n,i].filter(c=>c&&c!=="").join("\0");this.sourceDataForm.controls.path.setValue(a)}getPath(){return this.sourceDataForm.value.path??null}toggleFilesLargerThan(){this.sourceDataForm.controls.excludes.value.filesLargerThan?.size===null?this.sourceDataForm.controls.excludes.controls.filesLargerThan.setValue({size:50,unit:"MB"}):this.sourceDataForm.controls.excludes.controls.filesLargerThan.setValue({size:null,unit:null})}addNewPath(){let t=this.sourceDataForm.controls.path.value,e=this.newPathCtrl.value,n=t?.split("\0")||[];e&&!n.includes(e)&&n.push(e);let i=n.filter(a=>a&&a!=="").join("\0");this.sourceDataForm.controls.path.setValue(i),this.newPathCtrl.setValue("")}goBack(){this.#t.navigate(["destination"],{relativeTo:this.#i.parent})}next(){this.#e.isNew()||this.#e.submit(!0),this.#t.navigate(["schedule"],{relativeTo:this.#i.parent})}static \u0275fac=function(e){return new(e||o)};static \u0275cmp=H({type:o,selectors:[["app-source-data"]],viewQuery:function(e,n){e&1&&ge(n.formRef,It,5),e&2&&Ee()},decls:56,vars:12,consts:()=>{let t;t=$localize`Path`;let e;e=$localize`Add a direct path`;let n;n=$localize`Hidden files`;let i;i=$localize`System files`;let a;a=$localize`Temporary files`;let c;c=$localize`Source Data`;let C;C=$localize`Folder path`;let _;_=$localize`${"\uFFFD#12\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SH_ICON: Go back `;let d;d=$localize`${"\uFFFD#15\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#15\uFFFD"}:CLOSE_TAG_SH_ICON: Continue `;let I;I=$localize`Paths`;let U;U=$localize`Add a path directly from your machine.`;let B;B=$localize`Filters`;let V;V=$localize`Customize your filters.`;let x;x=$localize`Add filter`;let K;K=$localize`Exclude`;let W;W=$localize`Choose if there’s any files you want to exclude.`;let N;N=$localize` Files with the Hidden attribute ${"\uFFFD#46\uFFFD\uFFFD/#46\uFFFD"}:TAG_INPUT:`;let re;re=$localize` Files with the System attribute ${"\uFFFD#49\uFFFD\uFFFD/#49\uFFFD"}:TAG_INPUT:`;let _e;_e=$localize` Files with the Temporary attribute ${"\uFFFD#52\uFFFD\uFFFD/#52\uFFFD"}:TAG_INPUT:`;let ue;ue=$localize` Files larger than `;let P;return P=$localize`Edit path`,[["formRef",""],c,C,_,d,I,U,B,V,x,K,W,N,re,_e,ue,[3,"submit","formGroup"],[1,"left"],[1,"title-30"],[1,"fill",3,"multiSelect","startingPath","showFiles"],["for","path"],["type","text","id","path","tabindex","4","placeholder",t,"formControlName","path"],[1,"form-actions"],["shButton","","type","button",3,"click"],["shButton","","type","submit",1,"raised","primary"],[1,"right"],[3,"disallowToggle"],["title",""],["description",""],[1,"paths"],[1,"path"],[1,"row-inputs"],["type","text","placeholder",e,3,"formControl"],["shButton","","type","button",1,"raised","primary",3,"click"],["type","button","shButton","","action","",3,"click"],["formGroupName","excludes",3,"disallowToggle"],[1,"raised","primary"],["type","checkbox","placeholder",n,"formControlName","hidden"],["type","checkbox","placeholder",i,"formControlName","system"],["type","checkbox","placeholder",a,"formControlName","temporary"],[1,"raised","primary",3,"click"],[1,"small"],["type","text","placeholder",P,3,"ngModelChange","ngModel","ngModelOptions"],["shButton","","type","button",1,"small",3,"click"],["type","text",3,"ngModel","ngModelOptions"],[3,"path","osType"],[3,"pathChange","remove","path","osType"],[3,"ngModelChange","ngModel","ngModelOptions"]]},template:function(e,n){if(e&1){let i=$();s(0,"form",16,0),h("submit",function(){return g(i),E(n.next())}),s(2,"div",17)(3,"h3",18),f(4,1),l(),s(5,"app-file-tree",19)(6,"label",20),f(7,2),l(),T(8,"input",21),l(),s(9,"div",22)(10,"button",23),h("click",function(){return g(i),E(n.goBack())}),S(11,3),T(12,"sh-icon"),m(),l(),s(13,"button",24),S(14,4),T(15,"sh-icon"),m(),l()()(),s(16,"div",25)(17,"app-toggle-card",26),b(18,27),f(19,5),v(),s(20,"p",28),f(21,6),l(),s(22,"div",29),Ue(23,Gt,3,1,"div",30,Ge),s(25,"div",31)(26,"sh-form-field"),T(27,"input",32),l(),s(28,"button",33),h("click",function(){return g(i),E(n.addNewPath())}),s(29,"sh-icon"),G(30,"plus"),l()()()()(),s(31,"app-toggle-card",26),b(32,27),f(33,7),v(),s(34,"p",28),f(35,8),l(),s(36,"button",34),h("click",function(){return g(i),E(n.addFilter())}),f(37,9),l(),A(38,xt,2,0),l(),s(39,"app-toggle-card",35),b(40,27),f(41,10),v(),s(42,"p",28),f(43,11),l(),s(44,"sh-toggle",36),S(45,12),T(46,"input",37),m(),l(),s(47,"sh-toggle",36),S(48,13),T(49,"input",38),m(),l(),s(50,"sh-toggle",36),S(51,14),T(52,"input",39),m(),l(),s(53,"sh-toggle",40),h("click",function(){return g(i),E(n.toggleFilesLargerThan())}),f(54,15),l(),A(55,bt,2,3,"div",31),l()()()}if(e&2){let i;F("formGroup",n.sourceDataForm),r(5),F("multiSelect",!0)("startingPath",n.getPath())("showFiles",!0),r(12),F("disallowToggle",!0),r(6),xe(n.nonFilterPaths()),r(4),F("formControl",n.newPathCtrl),r(4),F("disallowToggle",!0),r(7),D((i=n.pathSignal())!=null&&i.length?38:-1),r(),F("disallowToggle",!0),r(14),Se("active",n.filesLargerThan()),r(2),D(n.filesLargerThan()?55:-1)}},dependencies:[oe,fe,j,Fe,q,Ne,ie,ye,nt,Ae,Pe,it,Q,Y,ae,Me,Le,Et,St,gt],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;width:100%;flex:1 0;overflow:hidden}form[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;flex:1 0;overflow:hidden}.right[_ngcontent-%COMP%], .left[_ngcontent-%COMP%]{flex:1 0;display:flex;flex-direction:column;gap:1.5rem}.left[_ngcontent-%COMP%]{padding:2.5rem;overflow:hidden;border-right:1px solid var(--base-4)}.right[_ngcontent-%COMP%]{padding:2.5rem 1.5rem;overflow:auto}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}sh-divider[_ngcontent-%COMP%]{margin:.75rem 0}.row-inputs[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr min-content;gap:.25rem}.paths[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;overflow:auto}.path[_ngcontent-%COMP%]{display:grid;align-items:center;grid-template-columns:1fr min-content min-content;gap:.25rem}"],changeDetection:0})};var Ft="1W:1D,4W:1W,12M:1M",Z=class o{#e=y(z);#t=y(Re);#i=y(at);#n=y(ut);#r=y(ct);#a=y(we);generalForm=ht();sourceDataForm=Tt();scheduleFields=Xe();scheduleType=p("daily");settings=p([]);optionsFields={remoteVolumeSize:p("50MB"),backupRetention:p("all"),backupRetentionTime:p(""),backupRetentionVersions:p(0),backupRetentionCustom:p("")};targetUrlModel=p(null);backupMetadata=p(null);isDraft=p(!1);backupId=p(null);backupName=L(()=>this.generalFormSignal()?.name??"");isSubmitting=p(!1);finishedLoading=p(!1);backupDefaults=p(null);applicationOptions=p(null);isNew=L(()=>this.backupId()==="new");osType=L(()=>this.#t.systemInfo()?.OSType);selectedOptions=p([]);sourceDataFormSignal=le(this.sourceDataForm.valueChanges);generalFormSignal=le(this.generalForm.valueChanges);encryptionFieldSignal=le(this.generalForm.controls.encryption.valueChanges);advancedOptions=L(()=>this.#t.systemInfo()?.Options?.map(this.#u)??[]);#o=p("");#s=p(null);#l=null;testSignal=this.#o.asReadonly();testErrorMessage=this.#s.asReadonly();#p=te(()=>{let t=this.targetUrlModel(),e=this.#o(),n=this.#l;this.#l=t,!(e==="testing"||n===null||n===t)&&(this.#o.set(""),this.#s.set(null))});setTestState(t,e){this.#o.set(t),this.#s.set(e??null)}#u(t){return{name:t.Name,type:t.Type,shortDescription:t.ShortDescription??void 0,longDescription:t.LongDescription??void 0,options:t.ValidValues}}encryptionOptions=L(()=>{let t=this.#t.systemInfo()?.EncryptionModules??[];return[pe,...t]});nonSelectedOptions=L(()=>this.advancedOptions().sort((t,e)=>t?.name&&e?.name?t?.name.localeCompare(e?.name):0).filter(t=>this.selectedOptions()?.findIndex(e=>e.name===t.name)===-1));submit(t=!1){this.isSubmitting.set(!0);let e=this.#d(),n=this.backupId();this.isDraft()&&e.Backup&&(e.Backup.Metadata=this.backupMetadata()),n==="new"||!n||this.isDraft()?this.#n.postApiV1Backups({requestBody:e}).pipe($e(()=>this.isSubmitting.set(!1))).subscribe({next:()=>{t||this.exit(!1)},error:()=>{}}):this.#n.putApiV1BackupById({id:n,requestBody:e}).pipe($e(()=>this.isSubmitting.set(!1))).subscribe({next:()=>{t||this.exit(!1)},error:()=>{}})}exit(t){if(!t){this.#_(),this.#e.navigate(["/"]);return}this.#i.open(dt,{data:{title:$localize`Confirm exit?`,message:$localize`Are you sure you want to exit?`,confirmText:$localize`Yes`,cancelText:$localize`Cancel`},closed:e=>{e&&(this.#_(),this.#e.navigate(["/"]))}})}mapSourceDataToForm(t){let e=t.Sources??"",n=t.Filters?.map(C=>`${C.Include?"":"-"}${C.Expression}`)??[],i=t.Settings?.find(C=>C.Name==="--exclude-files-attributes")?.Value?.toLowerCase()?.split(",")??[],a=t.Settings?.find(C=>C.Name==="--skip-files-larger-than")?.Value?.toUpperCase()??null,c={path:[...e,...n].join("\0"),excludes:{hidden:i.includes("hidden"),system:i.includes("system"),temporary:i.includes("temporary"),filesLargerThan:a===null?void 0:Oe(a)}};this.sourceDataForm.patchValue(c)}mapDestinationToForm(t){this.targetUrlModel.set(t.TargetURL??"")}mapGeneralToForm(t){let e=t.Name??"",n=t.Description??"",i=t.Settings?.find(d=>d.Name==="encryption-module"),a=t.Settings?.find(d=>d.Name==="passphrase")?.Value??"",c=i?.Value&&i.Value.length?i.Value:"",C=t.Settings?.find(d=>d.Name==="compression-module")?.Value??"",_={name:t.Name??"",description:t.Description??""};e&&e!==""&&(_.name=e),n&&n!==""&&(_.description=n),c&&c!==""&&(_.encryption=c),a&&a!==""&&(_.password=a,_.repeatPassword=a),C&&C!==""&&(_.compression=C),this.generalForm.patchValue(_)}mapScheduleToForm(t){if(!t){this.scheduleType.set("disabled"),this.scheduleFields.autoRun.set(!1);return}let e=this.#a.fromString(t.Repeat)??null,n=this.#c(t.Time);this.scheduleFields.autoRun.set(!0),n.date&&this.scheduleFields.nextTime.date.set(n.date),this.scheduleFields.nextTime.time.set(n.time),this.scheduleFields.runAgain.repeatUnit.set(e?.unit??"D"),this.scheduleFields.runAgain.repeatValue.set(e?.value??1),this.scheduleFields.runAgain.allowedDays.mon.set(t.AllowedDays?.includes("mon")??!1),this.scheduleFields.runAgain.allowedDays.tue.set(t.AllowedDays?.includes("tue")??!1),this.scheduleFields.runAgain.allowedDays.wed.set(t.AllowedDays?.includes("wed")??!1),this.scheduleFields.runAgain.allowedDays.thu.set(t.AllowedDays?.includes("thu")??!1),this.scheduleFields.runAgain.allowedDays.fri.set(t.AllowedDays?.includes("fri")??!1),this.scheduleFields.runAgain.allowedDays.sat.set(t.AllowedDays?.includes("sat")??!1),this.scheduleFields.runAgain.allowedDays.sun.set(t.AllowedDays?.includes("sun")??!1);let i=ce(this.scheduleFields),a=Ie.find(c=>JSON.stringify(c.data)===JSON.stringify(i));a?this.scheduleType.set(a.value):this.scheduleType.set("custom")}mapOptionsToForms(t,e=!1){let n=["--no-encryption","--exclude-files-attributes","--skip-files-larger-than","dblock-size","passphrase","keep-time","keep-versions","retention-policy"],i=(t.Settings??[]).map(_=>_);if(e){let _=this.#r.serverSettings()??{};Object.keys(_).filter(d=>d.startsWith("--")).forEach(d=>{i.find(U=>U.Name===d)||i.push({Name:d,Value:_[d],Filter:null})})}let a=i.filter(_=>!n.includes(_.Name)),c=i.filter(_=>n.includes(_.Name));this.settings.set(a??[]),a?.forEach(_=>{if(_.Name==="encryption-module"&&this.isNew())return this.generalForm.controls.encryption.setValue(_.Value??"")});var C="all";c?.forEach(_=>{if(_.Name==="dblock-size"&&this.optionsFields.remoteVolumeSize.set(_.Value??"50MB"),_.Name==="keep-time"&&(_.Value??"")!=="")return C="time",this.optionsFields.backupRetentionTime.set(_.Value??"");if(_.Name==="keep-versions"&&(_.Value??"")!=="")return C="versions",this.optionsFields.backupRetentionVersions.set(_.Value?parseInt(_.Value):null);if(_.Name==="retention-policy"&&(_.Value??"")!=="")if(_.Value===Ft)C="smart";else return C="custom",this.optionsFields.backupRetentionCustom.set(_.Value??"")}),this.optionsFields.backupRetention.set(C)}storeMetadata(t,e){this.backupMetadata.set(e?t.Metadata??null:null)}getScheduleFormValue(){let t=ce(this.scheduleFields);return mt(t)}#d(){let t=this.generalForm.value,e=this.getScheduleFormValue(),n=this.sourceDataForm.value,i=this.targetUrlModel(),a=n.path?.split("\0")??[],c=this.mapFormsToSettings(),C=Object.entries(n.excludes??{}).filter(([d,I])=>I&&d!=="filesLargerThan").map(([d])=>d),_=n.excludes?.filesLargerThan;return C.length&&c.push({Name:"--exclude-files-attributes",Value:C.join(",")}),_&&_.size!==null&&_.unit!==null&&c.push({Name:"--skip-files-larger-than",Value:`${_.size}${_.unit}`}),{Backup:{Name:t.name,Description:t.description,TargetURL:i??null,Sources:a.filter(d=>!(d.startsWith("-")||d.startsWith("+"))),Settings:c,Filters:a.filter(d=>d.startsWith("-")||d.startsWith("+")).map((d,I)=>({Order:I,Include:d.startsWith("+"),Expression:d.slice(1)}))},Schedule:e}}mapFormsToSettings(t=[]){let e=this.generalForm.value,n=["--no-encryption","--exclude-files-attributes","--skip-files-larger-than","encryption-module","passphrase","keep-time","keep-versions","retention-policy","dblock-size","compression-module"],i=[{Name:"--no-encryption",Value:"True"}];e.encryption!==""&&e.encryption!==pe.Key&&(i=[{Name:"encryption-module",Value:e.encryption??null},{Name:"passphrase",Value:e.password??null}]);let a=[{Name:"compression-module",Value:e.compression}];e.compression===""&&(a=[]);let c=[{Name:"dblock-size",Value:this.optionsFields.remoteVolumeSize()}];switch(this.optionsFields.backupRetention()){case"time":c.push({Name:"keep-time",Value:this.optionsFields.backupRetentionTime()});break;case"versions":c.push({Name:"keep-versions",Value:this.optionsFields.backupRetentionVersions()?.toString()??""});break;case"custom":c.push({Name:"retention-policy",Value:this.optionsFields.backupRetentionCustom()});break;case"smart":c.push({Name:"retention-policy",Value:Ft});break}let C=[...t,...n],_=this.settings().filter(d=>!C.includes(d.Name)).map(d=>{let I=d.Value;return typeof d.Value=="number"&&(I=d.Value.toString()),typeof d.Value=="boolean"&&(I=d.Value?"True":"False"),{Name:d.Name?.startsWith("--")?d.Name:`--${d.Name}`,Value:I}});return[...i,...a,...c,..._]}#c(t){if(!t||t?.indexOf("T")===-1)return{time:t??"13:00"};let e=new Date(t);return{time:`${(""+e.getHours()).padStart(2,"0")}:${(""+e.getMinutes()).padStart(2,"0")}`,date:e.toISOString().split("T")[0]}}setTargetUrl(t,e=!1){e&&(this.#l=null),this.targetUrlModel.set(t)}#_(){this.generalForm.reset(),this.sourceDataForm.reset(),this.scheduleFields=Xe(),this.optionsFields.remoteVolumeSize.set("50MB"),this.optionsFields.backupRetention.set("all"),this.settings.set([]),this.targetUrlModel.set(null)}static \u0275fac=function(e){return new(e||o)};static \u0275prov=Ce({token:o,factory:o.\u0275fac,providedIn:"root"})};var vt=["formRef"];function kt(o,t){o&1&&(s(0,"sh-alert",17),S(1,5),T(2,"sh-icon",26),m(),l())}function Bt(o,t){if(o&1&&G(0),o&2){let e=t.$implicit;Ze(" ",e.DisplayName," ")}}function Vt(o,t){if(o&1&&T(0,"sh-progress-bar",40),o&2){let e=u(3);Se("error",e.calculatePasswordStrength()===1)("warn",e.calculatePasswordStrength()===2)("primary",e.calculatePasswordStrength()===4)("success",e.calculatePasswordStrength()===5),F("value",e.calculatePasswordStrength()*(100/5))}}function Kt(o,t){o&1&&(s(0,"span",35),f(1,10),l())}function Wt(o,t){o&1&&(S(0,8,1),T(1,"sh-icon"),m())}function Jt(o,t){o&1&&(S(0,8,2),T(1,"sh-icon"),m())}function Xt(o,t){o&1&&(S(0,11,1),T(1,"sh-icon",42),m())}function Ht(o,t){o&1&&(S(0,11,2),T(1,"sh-icon"),m())}function zt(o,t){if(o&1){let e=$();s(0,"button",41),h("click",function(){g(e);let i=u(3);return E(i.copyPassword())}),S(1,11),A(2,Xt,2,0)(3,Ht,2,0),m(),l()}if(o&2){let e=u(3);r(2),D(e.copiedPassword()?2:3)}}function jt(o,t){o&1&&(s(0,"sh-alert",39),f(1,12),l())}function qt(o,t){if(o&1){let e=$();s(0,"div",30)(1,"sh-form-field")(2,"label",31),S(3,7),T(4,"sup"),m(),l(),T(5,"input",32),l(),A(6,Vt,1,9,"sh-progress-bar",33),s(7,"sh-form-field"),T(8,"input",34),A(9,Kt,2,0,"span",35),l(),s(10,"div",36)(11,"button",37),h("click",function(){g(e);let i=u(2);return E(i.showPassword.set(!i.showPassword()))}),S(12,8),A(13,Wt,2,0)(14,Jt,2,0),m(),l(),s(15,"button",37),h("click",function(){g(e);let i=u(2);return E(i.generatePassword())}),S(16,9),T(17,"sh-icon"),m(),l(),A(18,zt,4,1,"button",38),l(),A(19,jt,2,0,"sh-alert",39),l()}if(o&2){let e=u(2);r(5),F("type",e.showPassword()?"text":"password"),r(),D(e.generalForm.value.password?6:-1),r(2),F("type",e.showPassword()?"text":"password"),r(),D(e.generalForm.value.repeatPassword&&e.generalForm.value.repeatPassword!==e.generalForm.value.password?9:-1),r(4),D(e.showPassword()?13:14),r(5),D(e.showCopyPassword()?18:-1),r(),D(e.generalForm.value.password&&e.generalForm.value.password===e.generalForm.value.repeatPassword?19:-1)}}function Yt(o,t){if(o&1&&(s(0,"sh-select",27)(1,"label",28),f(2,6),l(),T(3,"input",29),qe(4,Bt,1,1,"ng-template"),l(),A(5,qt,20,7,"div",30)),o&2){let e=u();F("options",e.encryptionOptions())("isClearable",!1),r(5),D(e.encryptionFieldSignal()!==e.noneOptionKey?5:-1)}}function Qt(o,t){if(o&1&&(s(0,"button",24),S(1,13),T(2,"sh-icon"),m(),l()),o&2){let e=u();F("disabled",e.nameAndDescriptionValid()===!1)}}function Zt(o,t){if(o&1&&(s(0,"button",25),S(1,14),T(2,"sh-icon"),m(),l()),o&2){let e=u();F("disabled",e.generalForm.invalid||e.showCopyPassword()&&!e.copiedPassword())}}var ee=new De,ht=(o={name:"",description:"",encryption:"",password:"",repeatPassword:"",compression:""})=>ee.group({name:ee.control(o.name,[he.required]),description:ee.control(o.description),encryption:ee.control(o.encryption,[Ct()]),password:ee.control(o.password,[Ve(t=>t?.value.encryption!=="",[he.required])]),repeatPassword:ee.control(o.repeatPassword,[Ve(t=>t?.value.encryption!=="",[he.required])]),compression:ee.control(o.compression)}),pe={Key:"-",DisplayName:"None"},je=class o{#e=y(z);#t=y(ne);#i=y(pt);#n=y(Z);#r=y(Re);formRef=Te.required("formRef");generalForm=this.#n.generalForm;generalFormSignal=this.#n.generalFormSignal;encryptionFieldSignal=this.#n.encryptionFieldSignal;encryptionOptions=this.#n.encryptionOptions;isNew=this.#n.isNew;showPassword=p(!1);copiedPassword=p(!1);showCopyPassword=p(!1);noneOptionKey=pe.Key;encryptionEffect=te(()=>{this.encryptionFieldSignal()===pe.Key&&(this.copiedPassword.set(!1),this.showCopyPassword.set(!1))});nameAndDescriptionValid=L(()=>{let t=this.generalFormSignal(),e=this.generalForm.controls;return e?.name&&e.name.valid&&e?.description&&e.description.valid});calculatePasswordStrength=L(()=>{let e=this.generalFormSignal()?.password??"";return this.#i.calculatePasswordStrength(e)});ngOnInit(){this.formRef().nativeElement.focus()}exit(){this.#n.exit(!0)}async copyPassword(){let t=this.generalForm.controls.password.value;await this.#a(t??""),this.copiedPassword.set(!0)}async#a(t){try{await navigator.clipboard.writeText(t)}catch{try{let n=document.createElement("textarea");n.value=t,document.body.appendChild(n),n.select(),document.execCommand("copy"),document.body.removeChild(n)}catch(n){console.error("Failed to copy text: ",n)}}}generatePassword(){this.copiedPassword.set(!1);let t=this.#i.generate(16);this.generalForm.controls.password.setValue(t),this.generalForm.controls.repeatPassword.setValue(t),this.showCopyPassword.set(!0)}next(){this.#n.isNew()||this.#n.submit(!0),this.#e.navigate(["destination"],{relativeTo:this.#t.parent})}static \u0275fac=function(e){return new(e||o)};static \u0275cmp=H({type:o,selectors:[["app-general"]],viewQuery:function(e,n){e&1&&ge(n.formRef,vt,5),e&2&&Ee()},decls:21,vars:4,consts:()=>{let t;t=$localize`Your backup name`;let e;e=$localize`Your backup description`;let n;n=$localize`Remember to copy the password`;let i;i=$localize`General backup settings`;let a;a=$localize` Backup name ${"\uFFFD#8\uFFFD"}:START_SUPERSCRIPT:*${"\uFFFD/#8\uFFFD"}:CLOSE_SUPERSCRIPT:`;let c;c=$localize`Backup description`;let C;C=$localize`${"\uFFFD#18\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#18\uFFFD"}:CLOSE_TAG_SH_ICON: Exit `;let _;_=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:lock${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Encrypted backup `;let d;d=$localize`Encryption`;let I;I=$localize`Encryption`;let U;U=$localize`Password`;let B;B=$localize`Repeat password`;let V;V=$localize` Create a password ${"\uFFFD#4\uFFFD"}:START_SUPERSCRIPT:*${"\uFFFD/#4\uFFFD"}:CLOSE_SUPERSCRIPT:`;let x;x=$localize`${"\uFFFD*13:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:eye-slash${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Hide ${"\uFFFD/*13:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*14:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:eye${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Show ${"\uFFFD/*14:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,x=be(x);let K;K=$localize`${"\uFFFD#17\uFFFD"}:START_TAG_SH_ICON:password${"\uFFFD/#17\uFFFD"}:CLOSE_TAG_SH_ICON: Generate password `;let W;W=$localize`Passwords do not match`;let N;N=$localize`${"\uFFFD*2:1\uFFFD"}:START_BLOCK_IF:${"\uFFFD#1:1\uFFFD"}:START_TAG_SH_ICON:check${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Copied password ${"\uFFFD/*2:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*3:2\uFFFD"}:START_BLOCK_ELSE:${"\uFFFD#1:2\uFFFD"}:START_TAG_SH_ICON_1:copy${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Copy password ${"\uFFFD/*3:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,N=be(N);let re;re=$localize` Tip: Be sure to save your password. If you lose it, you will lose access to your backups. `;let _e;_e=$localize` Continue ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let ue;return ue=$localize` Continue ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`,[["formRef",""],i,a,c,C,_,I,V,x,K,W,N,re,_e,ue,["autocomplete","off",3,"submit","formGroup"],[1,"title-30"],[1,"primary"],["for","backupName"],["type","text","tabindex","1","placeholder",t,"formControlName","name"],["for","backupDescription"],["id","backupDescription","tabindex","2","placeholder",e,"formControlName","description"],[1,"form-actions"],["type","button","shButton","",3,"click"],["shButton","","type","submit",1,"raised","primary",3,"disabled"],["shButton","","type","submit","shTooltip",n,1,"raised","primary",3,"disabled"],["icon",""],["value","Key","label","DisplayName",3,"options","isClearable"],["for","encryption"],["type","text","id","encryption","tabindex","3","placeholder",d,"formControlName","encryption"],[1,"passwords"],["for","password"],["id","password","tabindex","4","autocomplete","off","placeholder",U,"formControlName","password",3,"type"],[1,"raised",3,"error","warn","primary","success","value"],["id","repeatPassword","tabindex","5","autocomplete","off","placeholder",B,"formControlName","repeatPassword",3,"type"],["error",""],[1,"password-actions"],["shButton","","type","button",1,"small",3,"click"],["shButton","","type","button",1,"small","copy"],["type","primary"],[1,"raised",3,"value"],["shButton","","type","button",1,"small","copy",3,"click"],[1,"sh-success"]]},template:function(e,n){if(e&1){let i=$();s(0,"form",15,0),h("submit",function(){return g(i),E(n.next())}),s(2,"h3",16),f(3,1),l(),A(4,kt,3,0,"sh-alert",17),s(5,"sh-form-field")(6,"label",18),S(7,2),T(8,"sup"),m(),l(),T(9,"input",19),l(),s(10,"sh-form-field")(11,"label",20),f(12,3),l(),T(13,"textarea",21),l(),A(14,Yt,6,3),s(15,"div",22)(16,"button",23),h("click",function(){return g(i),E(n.exit())}),S(17,4),T(18,"sh-icon"),m(),l(),A(19,Qt,3,1,"button",24)(20,Zt,3,1,"button",25),l()()}if(e&2){let i;F("formGroup",n.generalForm),r(4),D(!n.isNew()&&((i=n.generalFormSignal())==null?null:i.encryption)!==""?4:-1),r(10),D(n.isNew()?14:-1),r(5),D(n.encryptionFieldSignal()===n.noneOptionKey||!n.isNew()?19:20)}},dependencies:[ye,fe,j,q,Ne,Ae,Pe,Q,se,ae,Y,lt,ot,_t],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:32.5rem;padding:2.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;padding-bottom:1.5rem}sup[_ngcontent-%COMP%]{padding:0 .125rem;color:var(--error-8)}.passwords[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.password-actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;align-items:center}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}.copy[_ngcontent-%COMP%] sh-icon.sh-success[_ngcontent-%COMP%]{color:var(--success-8)}"],changeDetection:0})};export{ht as a,pe as b,je as c,Ie as d,mt as e,Xe as f,Ke as g,Tt as h,He as i,Z as j};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as le}from"./chunk-
|
|
1
|
+
import{a as le}from"./chunk-QNZTEY37.js";import"./chunk-6Q6SSTBK.js";import{a as ae}from"./chunk-U63HBLGG.js";import{a as _e}from"./chunk-WILUKPQ3.js";import"./chunk-CGKL2MHM.js";import{c as re}from"./chunk-FBWFZMGL.js";import"./chunk-PNYEL323.js";import"./chunk-NEV6JB5M.js";import"./chunk-QWNOPLJC.js";import{B as ie,D as ne,b as H,e as Q,i as Y,s as Z,u as ee,z as te}from"./chunk-RYXU2QDS.js";import{b as oe}from"./chunk-BKANUILG.js";import{d as j,e as q}from"./chunk-GO4NSDR6.js";import"./chunk-56FBKSBN.js";import"./chunk-FIBRO5I3.js";import"./chunk-RMOTUTEQ.js";import"./chunk-QF5K4MHH.js";import{$ as p,Ab as o,Cc as z,E as K,Fc as V,Ib as g,Mc as M,Pa as r,Rb as c,Rc as W,Sb as A,Tb as L,Ub as F,Vb as $,W as u,Xb as C,aa as P,cb as y,gc as x,jc as E,l as k,la as T,oc as S,p as U,pc as D,qc as h,rc as G,sb as m,sc as w,tb as f,tc as v,xc as J,yb as N,yc as X,z as I,zb as n}from"./chunk-XYHHESIX.js";import"./chunk-7CGTOI24.js";var ce=l=>["/backup",l,"export"],se=()=>["/"];function Ee(l,_){if(l&1){let t=g();n(0,"section")(1,"h4"),c(2,4),o(),n(3,"p"),c(4,5),o(),n(5,"sh-checkbox",11),E(6," Delete local database "),n(7,"input",12),h("ngModelChange",function(e){p(t);let a=C();return D(a.deleteLocalDb,e)||(a.deleteLocalDb=e),P(e)}),o()()()}if(l&2){let t=C();r(7),S("ngModel",t.deleteLocalDb)}}function ue(l,_){if(l&1){let t=g();n(0,"section")(1,"h4"),c(2,6),o(),n(3,"p"),c(4,7),z(5,"bytes"),o(),n(6,"sh-checkbox",11),E(7," Delete remote files "),n(8,"input",12),h("ngModelChange",function(e){p(t);let a=C();return D(a.deleteRemoteFiles,e)||(a.deleteRemoteFiles=e),P(e)}),o()()()}if(l&2){let t=C(),i=v(0),e=(i==null||i.Backup==null||i.Backup.Metadata==null?null:i.Backup.Metadata.TargetFilesSize)??0;r(5),A(t.fileCount())(t.fileCount())(V(5,4,e,!0,!0)),L(4),r(3),S("ngModel",t.deleteRemoteFiles)}}var B=class l{#t=u(oe);#i=u(te);#e=u(le);#n=u(j);id=W.required();backup=M(()=>this.#e.getBackupById(this.id()));noLocalDbResource=re({params:()=>({dbPath:this.backup()?.Backup?.DBPath}),stream:({params:_})=>this.#t.postApiV1FilesystemValidate({requestBody:{path:_.dbPath}}).pipe(U(()=>!0),I(()=>k(!1)))});fileCount=M(()=>parseInt(this.backup()?.Backup?.Metadata?.TargetFilesCount??"0",10));deleteLocalDb=T(!1);deleteRemoteFiles=T(!1);isDeleting=T(!1);deleteBackup(){let _=this.id(),t=this.deleteLocalDb(),i=this.deleteRemoteFiles();this.isDeleting.set(!0),this.#i.open(_e,{data:{title:$localize`Confirm delete`,message:$localize`Are you sure you want to delete this backup?`,confirmText:$localize`Delete backup`,cancelText:$localize`Cancel`},closed:e=>{e&&this.#e.deleteBackup({id:_,deleteLocalDb:t,deleteRemoteFiles:i}).pipe(K(()=>this.isDeleting.set(!1))).subscribe({next:()=>{this.#n.navigate(["/"])}})}})}static \u0275fac=function(t){return new(t||l)};static \u0275cmp=y({type:l,selectors:[["app-delete-backup"]],inputs:{id:[1,"id"]},decls:19,vars:11,consts:()=>{let _;_=$localize`Delete backup: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let t;t=$localize`Export configuration`;let i;i=$localize`If you want to use the backup later, you can export the configuration before deleting it.`;let e;e=$localize`Cancel`;let a;a=$localize`Delete local database`;let b;b=$localize` Each backup has a local database associated with it, which stores information about the remote backup on the local machine. When deleting a backup, you can also delete the local database without affecting the ability to restore the remote files. If you are using the local database for backups from the commandline, you should keep the database. `;let R;R=$localize`Delete remote files`;let d;d=$localize`{VAR_PLURAL, plural, =1 {1 file} other {{INTERPOLATION} files}}`,d=F(d,{INTERPOLATION:"\uFFFD1\uFFFD",VAR_PLURAL:"\uFFFD0\uFFFD"});let O;return O=$localize` Delete ${d}:ICU@@2159106180826349718: (${"\uFFFD2\uFFFD"}:INTERPOLATION_1:) from the remote storage? `,[_,t,i,e,a,b,R,O,["shButton","",3,"routerLink"],[1,"actions"],["shButton","",1,"raised","error",3,"click"],[1,"primary","raised"],["type","checkbox",3,"ngModelChange","ngModel"]]},template:function(t,i){if(t&1){let e=g();G(0),n(1,"h3"),c(2,0),o(),m(3,Ee,8,1,"section"),n(4,"section")(5,"h4"),c(6,1),o(),n(7,"p"),c(8,2),o(),n(9,"button",8),E(10," Export configuration "),n(11,"sh-icon"),E(12,"caret-right"),o()()(),m(13,ue,9,8,"section"),n(14,"div",9)(15,"button",8),c(16,3),o(),n(17,"button",10),$("click",function(){return p(e),P(i.deleteBackup())}),E(18,"Delete backup"),o()()}if(t&2){let e=w(i.backup()),a=i.noLocalDbResource.value();r(2),A(e==null||e.Backup==null?null:e.Backup.Name),L(2),r(),f(a?3:-1),r(6),N("routerLink",X(8,ce,i.id())),r(4),f(a?13:-1),r(2),N("routerLink",J(10,se)),r(2),x("loader",i.isDeleting())}},dependencies:[ne,ie,ee,Z,H,Q,Y,q,ae],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;padding:2.5rem;max-width:43.75rem}section[_ngcontent-%COMP%]{padding:2rem 0;display:flex;align-items:flex-start;flex-direction:column}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0}h4[_ngcontent-%COMP%]{font:var(--paragraph-20);margin-bottom:.5rem}p[_ngcontent-%COMP%]{margin-bottom:1rem}.actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;gap:.5rem;padding:2rem 0}"],changeDetection:0})};export{B as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"./chunk-
|
|
1
|
+
import{a}from"./chunk-I77LGXJN.js";import"./chunk-T5LLH46J.js";import"./chunk-DV67LYLW.js";import"./chunk-B5LH4P4E.js";import"./chunk-WILUKPQ3.js";import"./chunk-NEV6JB5M.js";import"./chunk-RYXU2QDS.js";import"./chunk-BKANUILG.js";import"./chunk-FIBRO5I3.js";import"./chunk-RMOTUTEQ.js";import"./chunk-QF5K4MHH.js";import"./chunk-XYHHESIX.js";import"./chunk-7CGTOI24.js";export{a as OptionsListComponent};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as A}from"./chunk-
|
|
1
|
+
import{a as A}from"./chunk-HEV3WHAH.js";import"./chunk-7XLQX4B6.js";import"./chunk-AJXTVI3H.js";import"./chunk-LF24JF3M.js";import"./chunk-QNZTEY37.js";import"./chunk-6Q6SSTBK.js";import"./chunk-U63HBLGG.js";import"./chunk-LVPZTSKG.js";import"./chunk-AGPZBYW6.js";import"./chunk-WILUKPQ3.js";import"./chunk-CGKL2MHM.js";import"./chunk-RIVMPP47.js";import"./chunk-FBWFZMGL.js";import"./chunk-PNYEL323.js";import"./chunk-NEV6JB5M.js";import"./chunk-QWNOPLJC.js";import{U as S}from"./chunk-RYXU2QDS.js";import"./chunk-BKANUILG.js";import{c as u,e as N,f as c}from"./chunk-GO4NSDR6.js";import"./chunk-56FBKSBN.js";import"./chunk-FIBRO5I3.js";import"./chunk-RMOTUTEQ.js";import"./chunk-QF5K4MHH.js";import{Ab as t,Bb as T,Rb as n,cb as g,zb as e}from"./chunk-XYHHESIX.js";import"./chunk-7CGTOI24.js";var l=class s{static \u0275fac=function(o){return new(o||s)};static \u0275cmp=g({type:s,selectors:[["app-about"]],decls:19,vars:0,consts:()=>{let i;i=$localize`General`;let o;o=$localize`Changelog`;let r;r=$localize`Libraries`;let C;C=$localize`System info`;let a;a=$localize`Server settings`;let E;E=$localize`Logs`;let O;return O=$localize`Crash log`,[i,o,r,C,a,E,O,[1,"content"],[1,"primary"],["tab","","routerLink","/about/general","routerLinkActive","active"],["tab","","routerLink","/about/changelog","routerLinkActive","active"],["tab","","routerLink","/about/libraries","routerLinkActive","active"],["tab","","routerLink","/about/system-info","routerLinkActive","active"],["tab","","routerLink","/about/server-settings","routerLinkActive","active"],["tab","","routerLink","/about/logs","routerLinkActive","active"],["tab","","routerLink","/about/crashlogs","routerLinkActive","active"]]},template:function(o,r){o&1&&(T(0,"app-status-bar"),e(1,"div",7)(2,"sh-tabs",8)(3,"button",9),n(4,0),t(),e(5,"button",10),n(6,1),t(),e(7,"button",11),n(8,2),t(),e(9,"button",12),n(10,3),t(),e(11,"button",13),n(12,4),t(),e(13,"button",14),n(14,5),t(),e(15,"button",15),n(16,6),t()(),e(17,"section"),T(18,"router-outlet"),t()())},dependencies:[A,S,u,N,c],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:0}.content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem 0}.content[_ngcontent-%COMP%] sh-tabs[_ngcontent-%COMP%]{margin:0 2rem 2rem}.content[_ngcontent-%COMP%] section[_ngcontent-%COMP%]{padding:0}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:2rem}"],changeDetection:0})};export{l as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as u}from"./chunk-
|
|
1
|
+
import{a as u}from"./chunk-7XLQX4B6.js";import{b as m}from"./chunk-BKANUILG.js";import{C as o,E as p,M as h,R as N,W as r,l as c,la as s,na as l,v as f,z as d}from"./chunk-XYHHESIX.js";var b=class a{#e=r(m);#o=r(u);serverState=this.#o.serverState;serverStateEffect=l(()=>{let t=this.#o.serverState();t?.LastNotificationUpdateID&&this.updateLastNotificationEventId(t?.LastNotificationUpdateID)});#s=-1;#a=s(!1);#t=s([]);#i=s([]);notifications=this.#t.asReadonly();init(){this.notifications().length===0&&this.getNotifications()}updateLastNotificationEventId(t){this.#s!==t&&(this.#s=t,this.getNotifications())}getNotifications(){this.#a.set(!0),this.#e.getApiV1Notifications().pipe(o(1),h(t=>this.#t.set(t)),p(()=>this.#a.set(!1))).subscribe()}getNofication(t){this.#e.getApiV1NotificationById({id:t}).pipe(o(1)).subscribe()}deleteNotification(t){let i=this.#t(),e=i[t];this.#i.set(i),i.splice(t,1),this.#t.set(i),this.#e.deleteApiV1NotificationById({id:e.ID}).pipe(o(1)).subscribe({error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}deleteAllNotifications(){let t=this.#t();this.#i.set(t),this.#t.set([]);let i=t.map(e=>this.#e.deleteApiV1NotificationById({id:e.ID}).pipe(d(()=>c(e))));f(i).pipe(o(1)).subscribe({next:e=>{let g=e.filter(n=>n!=null&&"ID"in n);this.#t.set(g),this.#i.set([])},error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}static \u0275fac=function(i){return new(i||a)};static \u0275prov=N({token:a,factory:a.\u0275fac,providedIn:"root"})};export{b as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{d as a,e as b,f as c,g as d}from"./chunk-3CCAGUTG.js";import"./chunk-GMNCWLGX.js";import"./chunk-B5LH4P4E.js";import"./chunk-TJYZBTTS.js";import"./chunk-6Q6SSTBK.js";import"./chunk-WILUKPQ3.js";import"./chunk-RIVMPP47.js";import"./chunk-FBWFZMGL.js";import"./chunk-PNYEL323.js";import"./chunk-NEV6JB5M.js";import"./chunk-QWNOPLJC.js";import"./chunk-RYXU2QDS.js";import"./chunk-BKANUILG.js";import"./chunk-GO4NSDR6.js";import"./chunk-56FBKSBN.js";import"./chunk-FIBRO5I3.js";import"./chunk-RMOTUTEQ.js";import"./chunk-QF5K4MHH.js";import"./chunk-XYHHESIX.js";import"./chunk-7CGTOI24.js";export{a as SCHEDULE_DEFAULT_OPTIONS,c as SCHEDULE_FIELD_DEFAULTS,d as default,b as scheduleOptionToSchedule};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as M}from"./chunk-
|
|
1
|
+
import{a as M}from"./chunk-HEV3WHAH.js";import"./chunk-7XLQX4B6.js";import"./chunk-AJXTVI3H.js";import"./chunk-LF24JF3M.js";import"./chunk-QNZTEY37.js";import"./chunk-6Q6SSTBK.js";import"./chunk-U63HBLGG.js";import"./chunk-LVPZTSKG.js";import"./chunk-AGPZBYW6.js";import"./chunk-WILUKPQ3.js";import"./chunk-CGKL2MHM.js";import"./chunk-RIVMPP47.js";import"./chunk-FBWFZMGL.js";import"./chunk-PNYEL323.js";import"./chunk-NEV6JB5M.js";import"./chunk-QWNOPLJC.js";import{B as D,C as N,u as E}from"./chunk-RYXU2QDS.js";import"./chunk-BKANUILG.js";import{e as m}from"./chunk-GO4NSDR6.js";import"./chunk-56FBKSBN.js";import"./chunk-FIBRO5I3.js";import"./chunk-RMOTUTEQ.js";import"./chunk-QF5K4MHH.js";import{Ab as n,Bb as o,Pa as c,Pb as r,Qb as l,Rb as i,cb as T,xc as d,yb as s,zb as e}from"./chunk-XYHHESIX.js";import"./chunk-7CGTOI24.js";var f=()=>["/backup/new"],O=()=>["/backup/import"],u=class p{static \u0275fac=function(t){return new(t||p)};static \u0275cmp=T({type:p,selectors:[["app-add-backup"]],decls:23,vars:4,consts:()=>{let a;a=$localize`Add a new backup`;let t;t=$localize`New backup`;let C;C=$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_SH_ICON:plus${"\uFFFD/#13\uFFFD"}:CLOSE_TAG_SH_ICON:`;let g;g=$localize`Import from file`;let P;P=$localize`Import backup configuration from a file. During import, you can adjust the settings.`;let S;return S=$localize` Import from file ${"\uFFFD#22\uFFFD"}:START_TAG_SH_ICON:upload-simple${"\uFFFD/#22\uFFFD"}:CLOSE_TAG_SH_ICON:`,[a,t,C,A,g,P,S,[1,"backup-types"],[1,"type-a"],["src","assets/images/new-backup.png"],["shButton","",1,"raised","primary",3,"routerLink"]]},template:function(t,C){t&1&&(o(0,"app-status-bar"),e(1,"section")(2,"h2"),i(3,0),n(),e(4,"div",7)(5,"sh-card",8),o(6,"img",9),e(7,"h3"),i(8,1),n(),e(9,"p"),i(10,2),n(),e(11,"button",10),r(12,3),o(13,"sh-icon"),l(),n()(),e(14,"sh-card",8),o(15,"img",9),e(16,"h3"),i(17,4),n(),e(18,"p"),i(19,5),n(),e(20,"button",10),r(21,6),o(22,"sh-icon"),l(),n()()()()),t&2&&(c(11),s("routerLink",d(2,f)),c(9),s("routerLink",d(3,O)))},dependencies:[M,D,N,E,m],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:43.75rem}sh-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;gap:1rem;padding-bottom:3rem}sh-card[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{max-width:18.75rem}sh-card[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-wrap:balance;text-align:center;width:75%}"],changeDetection:0})};export{u as default};
|