@duplicati/ngclient 0.0.209 → 0.0.210
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/{chunk-4NENQSXM.js → chunk-23BFPX3M.js} +1 -1
- package/{chunk-RC3UQLPB.js → chunk-2FD4SR65.js} +1 -1
- package/{chunk-QEIGUOTC.js → chunk-3ULPLOSF.js} +1 -1
- package/chunk-562BU33Q.js +1 -0
- package/{chunk-Q5WLMQD4.js → chunk-76USHURS.js} +1 -1
- package/{chunk-5ECY4LSP.js → chunk-AQWULDGL.js} +1 -1
- package/{chunk-FE3ADWR5.js → chunk-BDC5JQVQ.js} +1 -1
- package/{chunk-4QE3MT56.js → chunk-CKVJ36E5.js} +1 -1
- package/{chunk-BSYMQ4VF.js → chunk-DJAQY2GM.js} +1 -1
- package/{chunk-7J6AVYZE.js → chunk-DJJ3VITJ.js} +1 -1
- package/chunk-DKA7IP53.js +1 -0
- package/{chunk-7YLK4QIL.js → chunk-DMMZWQEZ.js} +1 -1
- package/{chunk-AZJ2P3YU.js → chunk-DWFQAX4H.js} +1 -1
- package/{chunk-47PB4WN3.js → chunk-EVMEYZB7.js} +1 -1
- package/chunk-F3TYSZ53.js +1 -0
- package/{chunk-TYEWJKJU.js → chunk-FG4GOBKA.js} +1 -1
- package/{chunk-3SSB4QCJ.js → chunk-FKYRYVJD.js} +1 -1
- package/{chunk-CNUQWXBC.js → chunk-FZQEPDIF.js} +1 -1
- package/{chunk-JW6W3ER7.js → chunk-GVXQIOKE.js} +1 -1
- package/{chunk-3WOW2XM3.js → chunk-I2BAH6NC.js} +1 -1
- package/chunk-I6Y22V2Q.js +1 -0
- package/{chunk-6HMNDYMY.js → chunk-I7U3XXJD.js} +1 -1
- package/{chunk-64IX6ISO.js → chunk-IGEX5B3E.js} +1 -1
- package/{chunk-DHOED4DH.js → chunk-INI4AJEU.js} +1 -1
- package/{chunk-HA7XREWO.js → chunk-IUJGDYFS.js} +1 -1
- package/{chunk-JKIZ6U22.js → chunk-JFUWTLM7.js} +1 -1
- package/{chunk-WZV32HLQ.js → chunk-JIJGVYNW.js} +1 -1
- package/{chunk-CNOKPOR3.js → chunk-KNB7LCAL.js} +1 -1
- package/{chunk-ODHFI4PA.js → chunk-KXBEW3N2.js} +1 -1
- package/{chunk-2V75WWT2.js → chunk-LP2DMTA7.js} +1 -1
- package/{chunk-7ZA3Q6TS.js → chunk-LSIAE7ZL.js} +1 -1
- package/{chunk-UUQWSINE.js → chunk-LTVI3WYF.js} +1 -1
- package/{chunk-AZFGZQQK.js → chunk-M3JOG5RD.js} +1 -1
- package/{chunk-2T442RZU.js → chunk-M7QNSQM2.js} +1 -1
- package/chunk-MYHC4Y56.js +1 -0
- package/{chunk-EL2UKEXS.js → chunk-NYX7YT7G.js} +1 -1
- package/{chunk-OSAM5F7M.js → chunk-PRBKV7LX.js} +1 -1
- package/{chunk-RNTBVXBV.js → chunk-PUBEHQ4W.js} +1 -1
- package/{chunk-MAKVVEKB.js → chunk-S2F2BNOG.js} +1 -1
- package/{chunk-LMZN2X5M.js → chunk-T3YMO3FB.js} +1 -1
- package/{chunk-UGEDZCTM.js → chunk-TDEVA3XM.js} +1 -1
- package/{chunk-CPI5ZQUF.js → chunk-UQLHXE6V.js} +1 -1
- package/{chunk-5KQZMHFN.js → chunk-V43VAZTT.js} +1 -1
- package/{chunk-BQEUHLSB.js → chunk-VOJGEOOO.js} +1 -1
- package/chunk-VUABEJRL.js +1 -0
- package/{chunk-I2HYK2BL.js → chunk-XHUQYWAM.js} +1 -1
- package/{chunk-2XMYVT7N.js → chunk-YE7IXREK.js} +1 -1
- package/{chunk-B35WNLRM.js → chunk-YF6ULZXZ.js} +1 -1
- package/chunk-ZOOFKMMI.js +1 -0
- package/chunk-ZVTMKBV5.js +1 -0
- package/index.html +1 -1
- package/main-IO5OKXBW.js +1 -0
- package/package.json +1 -1
- package/chunk-77ALZWIA.js +0 -1
- package/chunk-FKCZIBN3.js +0 -1
- package/chunk-G7XKFPGX.js +0 -1
- package/chunk-LO5YNFFR.js +0 -1
- package/chunk-O7MDPYFW.js +0 -1
- package/chunk-SEFBKH36.js +0 -1
- package/chunk-XHUMSL6X.js +0 -1
- package/chunk-XQTUBHIK.js +0 -1
- package/main-7RC24G3G.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as Q}from"./chunk-
|
|
1
|
+
import{a as Q}from"./chunk-IUJGDYFS.js";import{a as H}from"./chunk-X64LSE6Y.js";import"./chunk-RFB5A3B7.js";import{a as q}from"./chunk-FKYRYVJD.js";import"./chunk-AYOFR344.js";import"./chunk-LTVI3WYF.js";import"./chunk-BEXYTIOL.js";import"./chunk-DKA7IP53.js";import{B as X,C as z,H as K,L as j,c as B,e as U,i as G,s as W,v as V,w as J}from"./chunk-YCLTQEU6.js";import"./chunk-2LSZ2I43.js";import{d as A,e as I}from"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Ab as y,Bb as r,Cb as l,Db as T,Dc as $,Kb as f,Pc as O,Ra as a,Rb as S,Sb as P,Tb as p,Vc as v,Wb as D,Xb as h,Z as E,Zb as s,ca as m,da as F,eb as b,kc as x,lc as d,oa as N,qa as M,qc as w,rc as L,sc as k,ub as c,vb as _}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";var Y=(t,n,e,i,o)=>({"loading-state":t,"ready-to-add-link":n,"is-connected":e,"failed-to-connect":i,"is-registered":o});function Z(t,n){t&1&&p(0,0,1)}function ee(t,n){t&1&&p(0,0,2)}function te(t,n){if(t&1){let e=f();r(0,"button",10),h("click",function(){m(e);let o=s(2);return F(o.cancel())}),d(1,"Cancel registration"),l()}}function ne(t,n){if(t&1&&(r(0,"div",7)(1,"p"),S(2,0),c(3,Z,1,0)(4,ee,1,0),P(),l(),T(5,"sh-progress-bar",8),c(6,te,2,0,"button",9),l()),t&2){let e=s();a(3),_(e.state()==="unknown"?3:4),a(3),_((e.registeringCounter()??0)>=5&&e.state()==="registering"?6:-1)}}function ie(t,n){if(t&1){let e=f();r(0,"sh-form-field")(1,"label",11),p(2,1),l(),r(3,"input",12),k("ngModelChange",function(o){m(e);let C=s();return L(C.customRegisterUrl,o)||(C.customRegisterUrl=o),F(o)}),l()(),r(4,"div",13)(5,"button",14),d(6,"Go back"),l(),r(7,"button",15),h("click",function(){m(e);let o=s();return F(o.registerViaCustomUrl())}),p(8,2),l()()}if(t&2){let e=s();a(3),w("ngModel",e.customRegisterUrl),a(4),y("disabled",!e.customRegisterUrlValid())}}function oe(t,n){if(t&1){let e=f();r(0,"p"),p(1,3),l(),T(2,"sh-progress-bar",8),r(3,"button",10),h("click",function(){m(e);let o=s(2);return F(o.retryWhenFaulted())}),d(4,"Cancel"),l()}}function re(t,n){if(t&1){let e=f();r(0,"p"),p(1,4),l(),r(2,"button",10),h("click",function(){m(e);let o=s(2);return F(o.retryWhenFaulted())}),d(3,"Retry"),l()}}function le(t,n){if(t&1&&c(0,oe,5,0)(1,re,4,0),t&2){let e=s();_(e.claimUrl()!==null?0:1)}}function ae(t,n){t&1&&(S(0,5,1),T(1,"p"),P())}function se(t,n){t&1&&(S(0,5,2),T(1,"p"),P())}function ce(t,n){if(t&1){let e=f();r(0,"sh-alert",16),S(1,5),c(2,ae,2,0,"p")(3,se,2,0,"p"),P(),l(),r(4,"button",10),h("click",function(){m(e);let o=s();return F(o.retryWhenFaulted())}),d(5," Retry "),r(6,"sh-icon"),d(7,"arrow-arc-left"),l()()}if(t&2){let e=s();a(2),_(e.typeParam()==="link"?2:3)}}function _e(t,n){t&1&&(r(0,"h3"),d(1,"Successfully connected"),l(),r(2,"p"),d(3,"We're going to redirect you to the home page"),l())}var R=class t{#t=E(A);#i=E(H);#e=E(Q);#n=E(q);isOldOpen=N(!1);typeParam=v.required();state=this.#e.state;claimUrl=this.#e.claimUrl;registerUrl=this.#e.registerUrl;customRegisterUrl=this.#e.customRegisterUrl;additionalReportingUrl=O(()=>{let n=this.#n.serverSettings();return this.#e.state()==="inactive"?"":n&&n["additional-report-url"]||""});copiedReportingUrl=N(!1);customRegisterUrlValid=O(()=>{let n=this.customRegisterUrl(),e=/^(?:http(s)?:\/\/)?[\w.-]+(?:\.[\w\.-]+)+[\w\-\._~:/?#[\]@!\$&'\(\)\*\+,;=.]+$/;return!(n.length===0||!e.test(n))});registeringCounter=N(null);didTry=!1;triedFinishConnection=!1;stateEffect=M(()=>{let n=this.#e.registerUrl(),e=this.state(),i=this.typeParam(),o=this.registeringCounter();e==="inactive"&&i==="logon"&&n!==""&&(this.didTry||(this.#e.beginRemoteRegistration(),this.didTry=!0)),e==="registered"&&this.claimUrl()!==null&&(this.triedFinishConnection||(this.triedFinishConnection=!0,this.#o())),e==="registering"?(o===null&&this.registeringCounter.set(0),setTimeout(()=>{this.registeringCounter.set((o??0)+1)},1e3)):this.registeringCounter.set(null),(e==="connected"||e==="disabled"||e==="connecting")&&this.#n.setShownWelcomePage().subscribe(()=>{this.#t.navigate([""])})});ngOnInit(){this.#e.refreshRemoteControlStatus()}#o(){let n=this.#e.claimUrl();this.#i.open(`${n}?closeAfterConnection=true`,"_blank")}registerViaCustomUrl(){this.#e.beginRemoteRegistration(!0)}retryWhenFaulted(){this.#e.cancelRemoteRegistration(),this.customRegisterUrl.set(""),this.didTry=!1,this.triedFinishConnection=!1,this.typeParam()==="logon"&&this.#t.navigate(["/welcome/select"])}cancel(){this.#e.cancelRemoteRegistration()}register(){this.#e.beginRemoteRegistration()}disable(){this.#e.disableRemoteControl()}enable(){this.#e.enableRemoteControl()}delete(){this.#e.deleteRemoteControl()}copyReportingUrl(){let n=this.additionalReportingUrl();n&&(this.copiedReportingUrl.set(!0),setTimeout(()=>this.copiedReportingUrl.set(!1),2e3),navigator.clipboard.writeText(n))}static \u0275fac=function(e){return new(e||t)};static \u0275cmp=b({type:t,selectors:[["app-connect"]],inputs:{typeParam:[1,"typeParam"]},decls:6,vars:13,consts:()=>{let n;n=$localize`${"\uFFFD*3:1\uFFFD"}:START_BLOCK_IF: Loading... ${"\uFFFD/*3:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*4:2\uFFFD"}:START_BLOCK_ELSE: Connecting to console ${"\uFFFD/*4:2\uFFFD"}:CLOSE_BLOCK_ELSE:`;let e;e=$localize`Paste registration URL here`;let i;i=$localize` Connect machine to console `;let o;o=$localize`We're now connecting you to the console`;let C;C=$localize`Something failed during registration we're missing claimUrl, please try again`;let u;return u=$localize` Failed to register ${"\uFFFD*2:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_PARAGRAPH: Check if the connection link are correct, alternatively it could be your internet connection or the service might be down ${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_PARAGRAPH:${"\uFFFD/*2:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*3:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_PARAGRAPH: There might be a problem with your internet connection or the service might be down, please try again later ${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_PARAGRAPH:${"\uFFFD/*3:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,u=D(u),[n,e,i,o,C,u,[1,"main-card","type-b"],[1,"loader-content"],[1,"primary","indeterminate"],["shButton",""],["shButton","",3,"click"],["for","remoteControlRegisterUrl"],["type","text","id","remoteControlRegisterUrl","name","remoteControlRegisterUrl",3,"ngModelChange","ngModel"],[1,"nav-buttons"],["type","button","shButton","","routerLink","/welcome",1,"raised"],["type","button","shButton","",1,"raised","primary",3,"click","disabled"],[1,"error"]]},template:function(e,i){if(e&1&&(r(0,"sh-card",6),c(1,ne,7,2,"div",7),c(2,ie,9,2),c(3,le,2,1),c(4,ce,8,1),c(5,_e,4,0),l()),e&2){let o=i.state()==="unknown"||i.typeParam()!=="link"&&i.state()==="inactive"||i.state()==="registering",C=i.typeParam()==="link"&&i.state()==="inactive",u=i.state()==="connected"||i.state()==="disabled"||i.state()==="connecting",g=i.state()==="registeringfaulted";x($(7,Y,o,C,u,g,i.state()==="registered")),a(),_(o?1:-1),a(),_(C?2:-1),a(),_(i.state()==="registered"?3:-1),a(),_(g?4:-1),a(),_(u?5:-1)}},dependencies:[I,W,B,U,G,K,X,j,z,J,V],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;align-items:center;justify-content:center;height:100%;min-height:100%;width:100%;flex:1 0;overflow:hidden;padding:2rem}@media only screen and (max-width:768px){[_nghost-%COMP%]{padding:1rem}}.main-card[_ngcontent-%COMP%]{width:100%;height:100%;max-width:31.25rem;max-height:min-content;display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:1rem;padding:2rem}.main-card.failed-to-connect[_ngcontent-%COMP%] sh-alert[_ngcontent-%COMP%]{width:100%}.main-card.failed-to-connect[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{width:100%}.main-card.is-registered[_ngcontent-%COMP%], .main-card.is-connected[_ngcontent-%COMP%]{align-items:center}.loader-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.5rem;width:100%}.loader-content[_ngcontent-%COMP%] sh-progress-bar[_ngcontent-%COMP%]{--pb-b: var(--base-3);border:1px solid var(--pb-b)}.field-row[_ngcontent-%COMP%]{display:flex;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] sh-form-field[_ngcontent-%COMP%], .field-row[_ngcontent-%COMP%] sh-select[_ngcontent-%COMP%]{flex:1 0}.reporting-url[_ngcontent-%COMP%]{cursor:pointer;-webkit-user-select:none;user-select:none;margin-top:.25rem}.state[_ngcontent-%COMP%]{position:fixed;top:1rem;right:1rem;margin:0;color:var(--base-7);font-size:.75rem}.old[_ngcontent-%COMP%]{display:flex;flex-direction:column;position:relative;gap:.5rem;padding:1rem;border:1px solid var(--base-4);background:var(--base-1);position:fixed;top:0;right:0;bottom:0;width:35rem;transform:translate(100%)}.old.open[_ngcontent-%COMP%]{transform:translate(0)}.old[_ngcontent-%COMP%] .toggle[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;gap:.5rem;cursor:pointer;position:absolute;background-color:var(--base-1);border:1px solid var(--base-4);border-width:.0625rem 0 .0625rem .0625rem;width:2rem;height:2.5rem;border-radius:var(--shape-2) 0 0 var(--shape-2);top:3.75rem;left:-2rem;-webkit-user-select:none;user-select:none}.old[_ngcontent-%COMP%] .toggle[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{font-size:1rem}.nav-buttons[_ngcontent-%COMP%]{display:flex;gap:.5rem;flex-direction:row}"],changeDetection:0})};export{R as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as f}from"./chunk-
|
|
1
|
+
import{a as f}from"./chunk-DKA7IP53.js";import{Z as m,a as S,b as i,oa as c}from"./chunk-ERITO7WM.js";function u(...a){let e=c(...a);return Object.defineProperty(e,"value",{get:e.asReadonly(),set:e.set.bind(e)})}function A(a,e,o=!1,s){let l=m(f);e=l.getItemParsed(a,o)??e;let n=u(e),r=n[S];s?.equal&&(r.equal=s.equal);function g(t){t==null?l.removeItem(a):l.setItemParsed(a,t,o)}return n.set=t=>{g(t),i(r,t)},n.update=t=>{let T=t(n());g(T),i(r,T)},n}export{A as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as _}from"./chunk-
|
|
1
|
+
import{a as _}from"./chunk-FKYRYVJD.js";import"./chunk-AYOFR344.js";import"./chunk-LTVI3WYF.js";import"./chunk-BEXYTIOL.js";import"./chunk-DKA7IP53.js";import"./chunk-YCLTQEU6.js";import"./chunk-2LSZ2I43.js";import"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import{ka as l}from"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Eb as n,Ec as g,Fb as i,Fc as d,Ra as a,Tb as p,Z as s,eb as S,lc as c,mc as m}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";var o=class r{#e=s(_);serverSettings=this.#e.serverSettings;static \u0275fac=function(e){return new(e||r)};static \u0275cmp=S({type:r,selectors:[["app-server-settings"]],decls:6,vars:3,consts:()=>{let t;return t=$localize`System settings`,[t]},template:function(e,E){e&1&&(n(0,"h3"),p(1,0),i(),n(2,"code")(3,"pre"),c(4),g(5,"json"),i()()),e&2&&(a(4),m(d(5,1,E.serverSettings())))},dependencies:[l],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;padding:0 2.5rem}h3[_ngcontent-%COMP%]{font:var(--title-30)}code[_ngcontent-%COMP%]{background:color-mix(in srgb,var(--base-8),#000 70%);color:#fff;padding:1rem 1.5rem;border-radius:var(--shape-3);overflow:auto;white-space:pre}"],changeDetection:0})};export{o as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-7CGTOI24.js";var o=[{path:"",redirectTo:"general",pathMatch:"full"},{path:"general",loadComponent:()=>import("./chunk-PRBKV7LX.js")},{path:"destination",loadComponent:()=>import("./chunk-KNB7LCAL.js")},{path:"source-data",loadComponent:()=>import("./chunk-I7U3XXJD.js")},{path:"schedule",loadComponent:()=>import("./chunk-ZOOFKMMI.js")},{path:"options",loadComponent:()=>import("./chunk-T3YMO3FB.js")}];export{o as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{g as C}from"./chunk-
|
|
1
|
+
import{g as C}from"./chunk-YE7IXREK.js";import"./chunk-NBPZDFGF.js";import{a as w}from"./chunk-GVXQIOKE.js";import"./chunk-W4HWOC3K.js";import"./chunk-JFUWTLM7.js";import"./chunk-CKVJ36E5.js";import{p as k}from"./chunk-TDEVA3XM.js";import"./chunk-ITA7DTN3.js";import"./chunk-Q72Y55NB.js";import"./chunk-NXF5BMPG.js";import"./chunk-XHUQYWAM.js";import"./chunk-YF6ULZXZ.js";import"./chunk-SLS3DCJP.js";import"./chunk-SUY5AQLW.js";import"./chunk-6Q6SSTBK.js";import"./chunk-I4XRVBRQ.js";import"./chunk-IUJGDYFS.js";import"./chunk-X64LSE6Y.js";import"./chunk-RFB5A3B7.js";import"./chunk-DWFQAX4H.js";import"./chunk-FKYRYVJD.js";import{b as u}from"./chunk-AYOFR344.js";import"./chunk-LTVI3WYF.js";import"./chunk-BEXYTIOL.js";import"./chunk-DKA7IP53.js";import{M as y,R as W}from"./chunk-YCLTQEU6.js";import"./chunk-2LSZ2I43.js";import{a as A,b as $,c as M,d as I,e as G,f as v}from"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Ab as _,Ac as p,Bb as o,Cb as n,Db as a,Ra as r,Rb as F,Sb as l,Z as c,Zb as O,eb as D,ic as L,oa as f,qa as P,ub as E,vb as g,yc as N,zc as R}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";var x=()=>["/restore-from-files/destination"],b=()=>["/restore-from-files/encryption"],H=()=>["/restore-from-files/select-files"],J=()=>["/restore-from-files/options"],X=t=>["/restore",t,"select-files"],z=t=>["/restore",t,"options"];function B(t,i){t&1&&(o(0,"div",7),F(1,0),a(2,"sh-radio"),l(),n(),o(3,"div",7),F(4,1),a(5,"sh-radio"),l(),n(),o(6,"div",8),F(7,2),a(8,"sh-radio"),l(),n(),o(9,"div",8),F(10,3),a(11,"sh-radio"),l(),n()),t&2&&(_("routerLink",R(4,x)),r(3),_("routerLink",R(5,b)),r(3),_("routerLink",R(6,H)),r(3),_("routerLink",R(7,J)))}function U(t,i){if(t&1&&(o(0,"div",7),F(1,4),a(2,"sh-radio"),l(),n(),o(3,"div",7),F(4,5),a(5,"sh-radio"),l(),n()),t&2){let e=O(2);_("routerLink",p(2,X,e.backupId())),r(3),_("routerLink",p(4,z,e.backupId()))}}function j(t,i){if(t&1&&(o(0,"sh-stepper",6),E(1,B,12,8)(2,U,6,6),n()),t&2){let e=O();r(),g(e.isFileRestore()?1:2)}}var h=class t{#e=c($);#i=c(I);#t=c(C);#o=u(this.#e.params);#n=u(this.#e.url);#a=u(this.#e.children[0].url);backupId=this.#t.backupId;isFileRestore=this.#t.isFileRestore;isProgressPage=f(!1);paramsChanged=P(()=>{let i=this.#a(),e=this.#o()?.id,s=!!this.#n()?.find(d=>d.path==="restore-from-files"),T=!!i?.find(d=>d.path==="progress");this.isProgressPage.set(T),this.#t.init(e,s)});ngOnInit(){this.#i.events.subscribe(i=>{if(i instanceof A){let e=i.urlAfterRedirects;this.isProgressPage.set(e.includes("progress"))}})}static \u0275fac=function(e){return new(e||t)};static \u0275cmp=D({type:t,selectors:[["app-restore-flow"]],hostVars:2,hostBindings:function(e,s){e&2&&L("full-width",s.isProgressPage())},features:[N([C,k])],decls:4,vars:1,consts:()=>{let i;i=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_RADIO: Destination `;let e;e=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_RADIO: Encryption `;let s;s=$localize`${"\uFFFD#8\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#8\uFFFD"}:CLOSE_TAG_SH_RADIO: Select files `;let T;T=$localize`${"\uFFFD#11\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#11\uFFFD"}:CLOSE_TAG_SH_RADIO: Options `;let d;d=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_RADIO: Select files `;let m;return m=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_RADIO: Options `,[i,e,s,T,d,m,[1,"primary"],["step","","routerLinkActive","active",3,"routerLink"],["step","","routerLinkActive","active",1,"inactive",3,"routerLink"]]},template:function(e,s){e&1&&(a(0,"app-status-bar"),E(1,j,3,1,"sh-stepper",6),o(2,"section"),a(3,"router-outlet"),n()),e&2&&(r(),g(s.isProgressPage()?-1:1))},dependencies:[W,y,w,M,G,v],styles:["[_nghost-%COMP%]{display:block}.full-width[_nghost-%COMP%] section[_ngcontent-%COMP%]{max-width:62.5rem}sh-stepper[_ngcontent-%COMP%]{max-width:31.25rem;margin:2.5rem 2rem;width:calc(100% - 4rem)}section[_ngcontent-%COMP%]{max-width:31.25rem;margin:0 auto 2.5rem}@media only screen and (max-width:768px){section[_ngcontent-%COMP%]{padding:0 2rem}}.inactive[_ngcontent-%COMP%]{pointer-events:none;opacity:.5}"],changeDetection:0})};export{h as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as d}from"./chunk-AYOFR344.js";import{a as u,b as E}from"./chunk-
|
|
1
|
+
import{b as d}from"./chunk-AYOFR344.js";import{a as u,b as E}from"./chunk-LTVI3WYF.js";import{d as p}from"./chunk-2LSZ2I43.js";import{Pc as o,U as v,Z as s,oa as h,qa as l,z as g}from"./chunk-ERITO7WM.js";import{a as i}from"./chunk-7CGTOI24.js";var A="shown-welcome-page-v1",_="hide-console-connection-status",f="disable-console-control",C="disable-tray-icon-login",S="server-listen-interface",O="allowed-hostnames",b="server-passphrase",R="update-channel",T="startup-delay",D="usage-reporter-level",N="power-mode-provider",m=class n{#t=s(p);#r=s(u);#s=s(E);#n=d(this.#t.getApiV1Serversettings());#e=h(void 0);serverSettings=o(()=>this.#e()||this.#n());#o=l(()=>{let e=this.#r.serverSettings();e&&this.#e.set(e)});constructor(){this.#r.subscribe("serversettings")}isConsoleConnectionStatusHidden=o(()=>{let e=this.serverSettings();return e?e[_]==="True":!1});refreshServerSettings(){this.#s.getConnectionMethod()!=="websocket"&&this.#t.getApiV1Serversettings().subscribe({next:e=>{this.#e.set(e)}})}#i(e,t){var r=i({},e);for(let[a,c]of Object.entries(t))c===null?delete r[a]:r[a]=c;return r}patchServerSettings(e){let t=i({},this.serverSettings());return this.#e.set(this.#i(this.serverSettings()??{},e)),this.#t.patchApiV1Serversettings({requestBody:e}).pipe(g(r=>{throw this.#e.set(t),r}))}patchServerSetting(e,t){let r={};return r[e]=t,this.patchServerSettings(r)}setShownWelcomePage(){return this.patchServerSetting(A,"true")}setHideConsoleConnectionStatus(e){return this.patchServerSetting(_,e?"True":"False")}setDisableTrayIconLogin(e){return this.patchServerSetting(C,e?"True":"False")}setDisableConsoleControl(e){return this.patchServerSetting(f,e?"True":"False")}setRemoteAccessInterface(e){return this.patchServerSetting(S,e)}setRemoteAccessAllowedHostnames(e){var t={[O]:e};return this.serverSettings()?.[S]==="loopback"&&(t[S]="any"),this.patchServerSettings(t)}setRemoteAccessPassword(e){return this.patchServerSetting(b,e)}setUpdateChannel(e){return this.patchServerSetting(R,e)}setStartupDelay(e){return this.patchServerSetting(T,e)}setUsageReporterLevel(e){return this.patchServerSetting(D,e)}setPowerModeProvider(e){return this.patchServerSetting(N,e)}static \u0275fac=function(t){return new(t||n)};static \u0275prov=v({token:n,factory:n.\u0275fac,providedIn:"root"})};export{m as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as M}from"./chunk-
|
|
1
|
+
import{a as M}from"./chunk-GVXQIOKE.js";import"./chunk-W4HWOC3K.js";import"./chunk-JFUWTLM7.js";import"./chunk-CKVJ36E5.js";import"./chunk-XHUQYWAM.js";import"./chunk-YF6ULZXZ.js";import"./chunk-SLS3DCJP.js";import"./chunk-SUY5AQLW.js";import"./chunk-6Q6SSTBK.js";import"./chunk-I4XRVBRQ.js";import"./chunk-IUJGDYFS.js";import"./chunk-X64LSE6Y.js";import"./chunk-RFB5A3B7.js";import"./chunk-DWFQAX4H.js";import"./chunk-FKYRYVJD.js";import"./chunk-AYOFR344.js";import"./chunk-LTVI3WYF.js";import"./chunk-BEXYTIOL.js";import"./chunk-DKA7IP53.js";import{B as D,C as N,v as E}from"./chunk-YCLTQEU6.js";import"./chunk-2LSZ2I43.js";import{e as m}from"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Ab as r,Bb as e,Cb as n,Db as o,Ra as C,Rb as s,Sb as l,Tb as i,eb as T,zc as d}from"./chunk-ERITO7WM.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 g;g=$localize` Add a new backup ${"\uFFFD#13\uFFFD"}:START_TAG_SH_ICON:plus${"\uFFFD/#13\uFFFD"}:CLOSE_TAG_SH_ICON:`;let A;A=$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,g,A,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),s(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),s(21,6),o(22,"sh-icon"),l(),n()()()()),t&2&&(C(11),r("routerLink",d(2,f)),C(9),r("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;padding:0 2rem}@media only screen and (max-width:768px){div.backup-types[_ngcontent-%COMP%]{grid-template-columns:1fr}}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};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as De}from"./chunk-W4HWOC3K.js";import{a as Oe}from"./chunk-JKIZ6U22.js";import{a as fe}from"./chunk-4QE3MT56.js";import{b as me}from"./chunk-I2HYK2BL.js";import{a as Ee}from"./chunk-HA7XREWO.js";import{a as Fe}from"./chunk-3SSB4QCJ.js";import{b as Ce}from"./chunk-UUQWSINE.js";import{a as pe}from"./chunk-BEXYTIOL.js";import{c as se}from"./chunk-LO5YNFFR.js";import{B as A,H as ue,K as Se,P as de,Y as ge,c as ae,e as le,i as _e,k as re,s as ce,v as P,z as Te}from"./chunk-YCLTQEU6.js";import{d as x}from"./chunk-2LSZ2I43.js";import{e as oe}from"./chunk-BMWZYMK6.js";import{Ab as R,Bb as a,Cb as l,Db as T,E as Q,Hb as te,Ib as ne,Kb as D,Pc as Y,Ra as r,Rb as C,Sb as m,Tb as I,Uc as ie,Wb as v,Xb as c,Z as d,Zb as S,ca as E,da as O,eb as N,ic as G,lc as F,mc as w,nc as V,oa as f,qa as ee,qc as b,rc as y,sc as B,ub as g,vb as p,zc as H}from"./chunk-ERITO7WM.js";function Pe(o,t){o&1&&(a(0,"sh-icon",2),F(1,"x-bold"),l())}function Ae(o,t){o&1&&(a(0,"sh-icon",3),F(1,"list-bold"),l())}function he(o,t){if(o&1){let n=D();a(0,"button",1),c("click",function(){E(n);let i=S();return O(i.toggleNav())}),g(1,Pe,2,0,"sh-icon",2)(2,Ae,2,0,"sh-icon",3),l()}if(o&2){let n=S();r(),p(n.isNavOpen()?1:2)}}var $=class o{#e=d(Oe);isNavOpen=this.#e.isNavOpen;isMobile=this.#e.isMobile;toggleNav(){this.#e.toggleNav()}static \u0275fac=function(n){return new(n||o)};static \u0275cmp=N({type:o,selectors:[["app-mobile-menu-toggle"]],decls:1,vars:1,consts:[["shButton","",1,"small","toggle-sidebar","ghost"],["shButton","",1,"small","toggle-sidebar","ghost",3,"click"],[1,"cross"],[1,"burger"]],template:function(n,e){n&1&&g(0,he,3,1,"button",0),n&2&&p(e.isMobile()?0:-1)},dependencies:[A,P],styles:["[_nghost-%COMP%]{display:contents}.toggle-sidebar[_ngcontent-%COMP%]{position:relative;display:flex;align-items:center;justify-content:center}.toggle-sidebar[_ngcontent-%COMP%] .cross[_ngcontent-%COMP%], .toggle-sidebar[_ngcontent-%COMP%] .burger[_ngcontent-%COMP%]{opacity:1;transition:opacity 124ms linear;margin:0}.toggle-sidebar[_ngcontent-%COMP%] .cross.hidden[_ngcontent-%COMP%], .toggle-sidebar[_ngcontent-%COMP%] .burger.hidden[_ngcontent-%COMP%]{opacity:0}"],changeDetection:0})};var Ne=()=>["/connect/logon"];function ve(o,t){o&1&&(C(0,0,1),T(1,"div",9),m())}function be(o,t){o&1&&(C(0,0,2),T(1,"div",10),m())}function ye(o,t){if(o&1){let n=D();a(0,"div",8),c("click",function(){E(n);let i=S();return O(i.resetAndRetry())}),C(1,0),g(2,ve,2,0)(3,be,2,0),m(),l()}if(o&2){let n=S();r(2),p(n.resetting()?2:3)}}function Be(o,t){o&1&&(a(0,"div",6),C(1,1),T(2,"div",11),m(),l()),o&2&&R("routerLink",H(1,Ne))}function ke(o,t){o&1&&(a(0,"div",6),C(1,2),T(2,"div",10),m(),l()),o&2&&R("routerLink",H(1,Ne))}function Le(o,t){if(o&1){let n=D();a(0,"div",7),C(1,3),a(2,"sh-icon",12),c("click",function(){E(n);let i=S();return O(i.cancel())}),l(),a(3,"div",13),c("click",function(){E(n);let i=S();return O(i.claim())}),l(),T(4,"div",14),m(),l()}}function Ge(o,t){if(o&1){let n=D();a(0,"div",8),c("click",function(){E(n);let i=S();return O(i.openConsole())}),C(1,4),T(2,"div",15),m(),l()}}var k=class o{#e=d(Ee);state=this.#e.state;resetting=f(!1);stateEffect=ee(()=>{let t=this.#e.state(),n=this.resetting();t==="registered"&&n&&(this.resetting.set(!1),this.#e.beginRemoteRegistration())});ngOnInit(){this.#e.refreshRemoteControlStatus()}claim(){let t=this.#e.claimUrl();t&&window.open(t,"_blank")}cancel(){this.#e.cancelRemoteRegistration()}resetAndRetry(){this.resetting.set(!0),this.#e.cancelRemoteRegistration()}openConsole(){this.#e.openConsole()}static \u0275fac=function(n){return new(n||o)};static \u0275cmp=N({type:o,selectors:[["app-remote-connectivity-status"]],decls:5,vars:1,consts:()=>{let t;t=$localize`${"\uFFFD*2:1\uFFFD"}:START_BLOCK_IF: Resetting ${"\uFFFD#1:1\uFFFD"}:START_TAG_DIV:${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_DIV:${"\uFFFD/*2:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*3:2\uFFFD"}:START_BLOCK_ELSE: Click to connect ${"\uFFFD#1:2\uFFFD"}:START_TAG_DIV_1:${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_DIV:${"\uFFFD/*3:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,t=v(t);let n;n=$localize` Connecting ${"\uFFFD#2\uFFFD"}:START_TAG_DIV:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_DIV:`;let e;e=$localize` Click to register ${"\uFFFD#2\uFFFD"}:START_TAG_DIV:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_DIV:`;let i;i=$localize`Cancel registration`;let s;s=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:x-circle${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD#3\uFFFD"}:START_TAG_DIV:Click to claim${"[\uFFFD/#3\uFFFD|\uFFFD/#4\uFFFD]"}:CLOSE_TAG_DIV:${"\uFFFD#4\uFFFD"}:START_TAG_DIV_1:${"[\uFFFD/#3\uFFFD|\uFFFD/#4\uFFFD]"}:CLOSE_TAG_DIV:`,s=v(s);let u;return u=$localize` Connected ${"\uFFFD#2\uFFFD"}:START_TAG_DIV:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_DIV:`,[t,n,e,s,u,[1,"connectivity-status"],[1,"connectivity-status",3,"routerLink"],[1,"connectivity-status","claim"],[1,"connectivity-status",3,"click"],[1,"status","blinking"],[1,"status"],[1,"status","warning","blinking"],["shTooltip",i,3,"click"],[1,"claim",3,"click"],[1,"status","success","blinking"],[1,"status","success"]]},template:function(n,e){if(n&1&&g(0,ye,4,1,"div",5)(1,Be,3,2,"div",6)(2,ke,3,2,"div",6)(3,Le,5,0,"div",7)(4,Ge,3,0,"div",5),n&2){let i=e.state()==="unknown"||e.state()==="inactive"||e.state()==="registeringfaulted",s=e.state()==="registeringfaulted",u=e.state()==="registering",_=e.state()==="registered",M=e.state()==="connected"||e.state()==="disabled"||e.state()==="connecting";p(s?0:u?1:i?2:_?3:M?4:-1)}},dependencies:[oe,P,ge],styles:["[_nghost-%COMP%]{display:flex;align-items:center;padding:0 .75rem}@media only screen and (max-width:768px){[_nghost-%COMP%]{padding:0}}.hide-text[_nghost-%COMP%]{font-size:0}.in-menu[_nghost-%COMP%]{padding:.75rem;border-bottom:1px solid var(--base-4)}.connectivity-status[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;cursor:pointer}.connectivity-status[_ngcontent-%COMP%]:hover{color:var(--primary-8)}.connectivity-status.claim[_ngcontent-%COMP%]{display:flex;gap:.5rem;cursor:pointer}.connectivity-status.claim[_ngcontent-%COMP%]:hover{color:inherit}.connectivity-status.claim[_ngcontent-%COMP%] .claim[_ngcontent-%COMP%]:hover{color:var(--primary-8)}.connectivity-status.claim[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]:hover{color:var(--error-8)}.status[_ngcontent-%COMP%]{width:.625rem;height:.625rem;border-radius:50%;background-color:var(--base-4)}.status.success[_ngcontent-%COMP%]{background-color:var(--success-8)}.status.warning[_ngcontent-%COMP%]{background-color:var(--warn-8)}.status.blinking[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_blinking 1s infinite}@keyframes _ngcontent-%COMP%_blinking{0%{opacity:.2}50%{opacity:1}to{opacity:.2}}"],changeDetection:0})};var Me={Byte:"B",KByte:"KB",MByte:"MB",GByte:"GB",TByte:"TB",PByte:"PB"},xe=["mbps","gbps"],Ie=8,W=1024,U=W*1024,j=U*1024,Z=j*1024,Re=Z*1024,$e={B:1,KB:W,MB:U,GB:j,TB:Z,PB:Re},Ue=1e3,K=Ue*1e3,X=K*1e3,we=[{threshold:Re,unitPrefix:"PByte"},{threshold:Z,unitPrefix:"TByte"},{threshold:j,unitPrefix:"GByte"},{threshold:U,unitPrefix:"MByte"},{threshold:W,unitPrefix:"KByte"},{threshold:1,unitPrefix:"Byte"}],L=class o{#e=d(x);closed=ie();isSubmitting=f(!1);sizeOptions=f([...xe]);maxUpload=f(0);maxDownload=f(0);maxUploadUnit=f("mbps");maxDownloadUnit=f("mbps");ngOnInit(){this.init()}convertToBitsPerSecondUnits(t,n){let i=t*($e[n.toUpperCase()]||U)*Ie;return i===0?{value:0,unit:"mbps"}:i>=X?{value:parseFloat((i/X).toFixed(2)),unit:"gbps"}:{value:parseFloat((i/K).toFixed(2)),unit:"mbps"}}convertFromBitsPerSecondUnits(t,n){let e=0;switch(n){case"gbps":e=t*X;break;case"mbps":e=t*K;break}let i=e/Ie;if(i===0)return{valueForApi:0,unitPrefixForApi:"Byte"};for(let{threshold:s,unitPrefix:u}of we)if(i>=s)return{valueForApi:Math.round(i/s),unitPrefixForApi:u};return{valueForApi:Math.round(i),unitPrefixForApi:"Byte"}}init(){this.#e.getApiV1Serversettings().subscribe({next:t=>{let n=t?.["max-upload-speed"],e=t?.["max-download-speed"];if(n&&n!==""){let i=n.match(/^(\d+(?:\.\d+)?)([A-Za-z]+)$/);if(i){let s=parseFloat(i[1]),u=i[2],_=this.convertToBitsPerSecondUnits(s,u);this.maxUpload.set(_.value),this.maxUploadUnit.set(_.unit)}else console.warn("Unexpected max-upload-speed format from API:",n),this.resetUpload()}else this.resetUpload();if(e&&e!==""){let i=e.match(/^(\d+(?:\.\d+)?)([A-Za-z]+)$/);if(i){let s=parseFloat(i[1]),u=i[2],_=this.convertToBitsPerSecondUnits(s,u);this.maxDownload.set(_.value),this.maxDownloadUnit.set(_.unit)}else console.warn("Unexpected max-download-speed format from API:",e),this.resetDownload()}else this.resetDownload()},error:t=>{console.error("Failed to get server settings:",t),this.resetDownload(),this.resetUpload()}})}resetDownload(){this.maxDownload.set(0),this.maxDownloadUnit.set("mbps")}resetUpload(){this.maxUpload.set(0),this.maxUploadUnit.set("mbps")}blockDecimalKeys(t){if([".",","].includes(t.key))return t.preventDefault()}cleanupInputAfterPasting(t){t.preventDefault();let n=t.clipboardData?.getData("text/plain");if(!n)return;let e=n.replaceAll(/[\.,]/g,"");t.target.value=e}submit(){this.isSubmitting.set(!0);let t="",n="",e=this.maxUpload()??0,i=this.maxUploadUnit(),s=this.maxDownload()??0,u=this.maxDownloadUnit();if(e>0){let{valueForApi:_,unitPrefixForApi:M}=this.convertFromBitsPerSecondUnits(e,i),h=Me[M];h?t=`${_}${h}`:console.error(`Invalid unit prefix for API submission (upload): ${M}. Defaulting to empty string.`)}if(s){let{valueForApi:_,unitPrefixForApi:M}=this.convertFromBitsPerSecondUnits(s,u),h=Me[M];h?n=`${_}${h}`:console.error(`Invalid unit prefix for API submission (download): ${M}. Defaulting to empty string.`)}this.#e.patchApiV1Serversettings({requestBody:{"max-upload-speed":t,"max-download-speed":n}}).pipe(Q(()=>this.isSubmitting.set(!1))).subscribe({next:()=>{this.closed.emit(!0)},error:_=>{console.error("Failed to submit throttle settings:",_)}})}static \u0275fac=function(n){return new(n||o)};static \u0275cmp=N({type:o,selectors:[["app-throttle-settings-dialog"]],outputs:{closed:"closed"},decls:26,vars:10,consts:()=>{let t;t=$localize`Throttle network speed`;let n;n=$localize`We will round bits to the nearest byte value.`;let e;e=$localize`Max upload speed`;let i;i=$localize`Max download speed`;let s;s=$localize`Cancel`;let u;return u=$localize` Update settings `,[t,n,e,i,s,u,["content",""],[1,"column"],[1,"field-row"],["type","number",3,"paste","keydown","ngModelChange","ngModel"],[3,"isClearable","options"],["type","text",3,"ngModelChange","ngModel"],["footer",""],["shButton","",3,"click"],["shButton","",1,"raised","primary",3,"click"]]},template:function(n,e){n&1&&(a(0,"header")(1,"h3"),I(2,0),l(),a(3,"p"),I(4,1),l()(),a(5,"div",6)(6,"div",7)(7,"div",8)(8,"label"),I(9,2),l(),a(10,"sh-form-field")(11,"input",9),c("paste",function(s){return e.cleanupInputAfterPasting(s)})("keydown",function(s){return e.blockDecimalKeys(s)}),B("ngModelChange",function(s){return y(e.maxUpload,s)||(e.maxUpload=s),s}),l()(),a(12,"sh-select",10)(13,"input",11),B("ngModelChange",function(s){return y(e.maxUploadUnit,s)||(e.maxUploadUnit=s),s}),l()()(),a(14,"div",8)(15,"label"),I(16,3),l(),a(17,"sh-form-field")(18,"input",9),c("paste",function(s){return e.cleanupInputAfterPasting(s)})("keydown",function(s){return e.blockDecimalKeys(s)}),B("ngModelChange",function(s){return y(e.maxDownload,s)||(e.maxDownload=s),s}),l()(),a(19,"sh-select",10)(20,"input",11),B("ngModelChange",function(s){return y(e.maxDownloadUnit,s)||(e.maxDownloadUnit=s),s}),l()()()()(),a(21,"footer",12)(22,"button",13),c("click",function(){return e.closed.emit(!1)}),I(23,4),l(),a(24,"button",14),c("click",function(){return e.submit()}),I(25,5),l()()),n&2&&(r(11),b("ngModel",e.maxUpload),r(),R("isClearable",!1)("options",e.sizeOptions()),r(),b("ngModel",e.maxUploadUnit),r(5),b("ngModel",e.maxDownload),r(),R("isClearable",!1)("options",e.sizeOptions()),r(),b("ngModel",e.maxDownloadUnit),r(4),G("loading",e.isSubmitting()))},dependencies:[ce,ae,re,le,_e,ue,de,A],styles:['[_nghost-%COMP%]{display:block}h3[_ngcontent-%COMP%]{font:var(--title-30)}header[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:flex-start;padding:1rem;gap:.5rem;margin-bottom:1rem}.column[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.field-row[_ngcontent-%COMP%]{display:grid;grid-template-areas:"label label" "input select";grid-template-columns:1fr auto;align-items:center;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{grid-area:label}.field-row[_ngcontent-%COMP%] sh-form-field[_ngcontent-%COMP%]{grid-area:input}.field-row[_ngcontent-%COMP%] sh-select[_ngcontent-%COMP%]{grid-area:select}'],changeDetection:0})};function Ve(o,t){o&1&&T(0,"app-remote-connectivity-status")}function He(o,t){if(o&1){let n=D();a(0,"button",7),c("click",function(){E(n);let i=S(2);return O(i.abort())}),C(1,1),T(2,"sh-icon"),m(),l()}}function Ye(o,t){if(o&1){let n=D();a(0,"button",7),c("click",function(){E(n);let i=S(2);return O(i.stop())}),C(1,2),T(2,"sh-icon"),m(),l()}}function ze(o,t){if(o&1&&g(0,He,3,0,"button",14)(1,Ye,3,0,"button",14),o&2){let n=S();p(n.isStopping()?0:1)}}function Je(o,t){o&1&&(C(0,0,1),T(1,"sh-icon"),m())}function Xe(o,t){o&1&&(C(0,0,2),T(1,"sh-icon"),m())}function Ke(o,t){o&1&&T(0,"app-remote-connectivity-status",10)}function We(o,t){o&1&&T(0,"app-remote-connectivity-status",12)}function je(o,t){if(o&1){let n=D();a(0,"button",13),c("click",function(){E(n);let i=S();return O(i.isStopping()?i.abort():i.stop())}),a(1,"sh-icon"),F(2),l(),F(3),l()}if(o&2){let n=S();r(2),w(n.isStopping()?"skull":"stop"),r(),V(" ",n.isStopping()?"Abort":"Stop"," ")}}var q=class o{#e=d(x);#t=d(me);#n=d(Te);#s=d(Ce);#i=d(se);#a=d(pe);#l=d(Fe);clientIsRunning=this.#t.clientIsRunning;isResuming=this.#t.isResuming;runningTask=Y(()=>this.#s.serverState()?.ActiveTask?.Item1);isStopping=Y(()=>this.runningTask()==this.#o());#o=f(-1);isUsingRelay=this.#i.relayIsEnabled;hideConsoleConnectionStatus=this.#l.isConsoleConnectionStatusHidden;openThrottleSettingsDialog(){this.#n.open(L,{maxWidth:"550px",width:"100%"})}openPauseDialog(){this.#n.open(De,{maxWidth:"550px",width:"100%"})}pauseResume(){if(this.clientIsRunning()){this.openPauseDialog();return}this.#t.pauseResume().subscribe()}stop(){let t=this.runningTask();t&&(this.#o.set(t),this.#e.postApiV1TaskByTaskidStop({taskid:t}).subscribe())}abort(){let t=this.runningTask();t&&this.#e.postApiV1TaskByTaskidAbort({taskid:t}).subscribe()}ngAfterViewInit(){let t=this.#i.relayIsEnabled()||!this.#a.hasWebSocket()?"longpoll":"websocket";this.#t.setConnectionMethod(t)}static \u0275fac=function(n){return new(n||o)};static \u0275cmp=N({type:o,selectors:[["app-status-bar"]],decls:31,vars:10,consts:()=>{let t;t=$localize`${"\uFFFD*9:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:pause${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Pause ${"\uFFFD/*9:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*10:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:play${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Resume ${"\uFFFD/*10:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,t=v(t);let n;n=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:skull${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Abort `;let e;return e=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:stop${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Stop `,[t,n,e,[1,"current-backup"],[1,"global-progress"],[1,"current-backup-actions"],[1,"desktop-actions"],["shButton","",3,"click"],[1,"mobile-actions"],["shButton","",1,"small","menu-mobile-toggle"],[1,"hide-text"],["menu",""],[1,"in-menu"],[3,"click"],["shButton",""]]},template:function(n,e){n&1&&(a(0,"div",3),T(1,"app-mobile-menu-toggle")(2,"app-backup-progress",4),a(3,"div",5)(4,"div",6),g(5,Ve,1,0,"app-remote-connectivity-status"),g(6,ze,2,1),a(7,"button",7),c("click",function(){return e.pauseResume()}),C(8,0),g(9,Je,2,0)(10,Xe,2,0),m(),l(),a(11,"button",7),c("click",function(){return e.openThrottleSettingsDialog()}),a(12,"sh-icon"),F(13,"speedometer"),l()()(),a(14,"div",8)(15,"sh-menu")(16,"button",9),g(17,Ke,1,0,"app-remote-connectivity-status",10),a(18,"sh-icon"),F(19,"dots-three-vertical-bold"),l()(),te(20,11),g(21,We,1,0,"app-remote-connectivity-status",12),g(22,je,4,2,"button"),a(23,"button",13),c("click",function(){return e.pauseResume()}),a(24,"sh-icon"),F(25),l(),F(26),l(),a(27,"button",13),c("click",function(){return e.openThrottleSettingsDialog()}),a(28,"sh-icon"),F(29,"speedometer"),l(),F(30," Throttle Settings "),l(),ne(),l()()()()),n&2&&(r(5),p(!e.isUsingRelay()&&!e.hideConsoleConnectionStatus()?5:-1),r(),p(e.runningTask()?6:-1),r(),G("loading",e.isResuming()),r(2),p(e.clientIsRunning()?9:10),r(8),p(!e.isUsingRelay()&&!e.hideConsoleConnectionStatus()?17:-1),r(4),p(!e.isUsingRelay()&&!e.hideConsoleConnectionStatus()?21:-1),r(),p(e.runningTask()?22:-1),r(3),w(e.clientIsRunning()?"pause":"play"),r(),V(" ",e.clientIsRunning()?"Pause":"Resume"," "))},dependencies:[k,P,A,Se,$,fe],styles:["[_nghost-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:1rem;min-height:3.875rem;border-bottom:1px solid var(--base-4);position:sticky;top:0;z-index:2000;background:var(--base-1)}[_nghost-%COMP%]:has(sh-progress-bar){padding:1rem 1rem 1.5rem}.current-backup[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:100%;gap:.5rem}.global-progress[_ngcontent-%COMP%]{flex:1 0;min-width:18.75rem}.current-backup-actions[_ngcontent-%COMP%], .current-backup-actions[_ngcontent-%COMP%] .desktop-actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}@media only screen and (max-width:768px){.current-backup-actions[_ngcontent-%COMP%] .desktop-actions[_ngcontent-%COMP%]{display:none}}.current-backup-actions[_ngcontent-%COMP%] .mobile-actions[_ngcontent-%COMP%]{display:none}@media only screen and (max-width:768px){.current-backup-actions[_ngcontent-%COMP%] .mobile-actions[_ngcontent-%COMP%]{display:flex}}.current-backup-actions[_ngcontent-%COMP%] .menu-mobile-toggle[_ngcontent-%COMP%]{position:relative}.current-backup-actions[_ngcontent-%COMP%] .menu-mobile-toggle[_ngcontent-%COMP%] app-remote-connectivity-status[_ngcontent-%COMP%]{position:absolute;top:-.25rem;right:-.25rem}.menu-status-item[_ngcontent-%COMP%]{padding:.5rem 1rem;display:flex;flex-direction:column;gap:.25rem;border-bottom:1px solid var(--base-4);margin-bottom:.25rem}.menu-status-item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem;font-size:.875rem}"],changeDetection:0})};export{q as a};
|
|
1
|
+
import{a as De}from"./chunk-W4HWOC3K.js";import{a as Oe}from"./chunk-JFUWTLM7.js";import{a as fe}from"./chunk-CKVJ36E5.js";import{b as me}from"./chunk-XHUQYWAM.js";import{a as Ee}from"./chunk-IUJGDYFS.js";import{a as Fe}from"./chunk-FKYRYVJD.js";import{b as Ce}from"./chunk-LTVI3WYF.js";import{a as pe}from"./chunk-BEXYTIOL.js";import{c as se}from"./chunk-DKA7IP53.js";import{B as A,H as ue,K as Se,P as de,Y as ge,c as ae,e as le,i as _e,k as re,s as ce,v as P,z as Te}from"./chunk-YCLTQEU6.js";import{d as x}from"./chunk-2LSZ2I43.js";import{e as oe}from"./chunk-BMWZYMK6.js";import{Ab as R,Bb as a,Cb as l,Db as T,E as Q,Hb as te,Ib as ne,Kb as D,Pc as Y,Ra as r,Rb as C,Sb as m,Tb as I,Uc as ie,Wb as v,Xb as c,Z as d,Zb as S,ca as E,da as O,eb as N,ic as G,lc as F,mc as w,nc as V,oa as f,qa as ee,qc as b,rc as y,sc as B,ub as g,vb as p,zc as H}from"./chunk-ERITO7WM.js";function Pe(o,t){o&1&&(a(0,"sh-icon",2),F(1,"x-bold"),l())}function Ae(o,t){o&1&&(a(0,"sh-icon",3),F(1,"list-bold"),l())}function he(o,t){if(o&1){let n=D();a(0,"button",1),c("click",function(){E(n);let i=S();return O(i.toggleNav())}),g(1,Pe,2,0,"sh-icon",2)(2,Ae,2,0,"sh-icon",3),l()}if(o&2){let n=S();r(),p(n.isNavOpen()?1:2)}}var $=class o{#e=d(Oe);isNavOpen=this.#e.isNavOpen;isMobile=this.#e.isMobile;toggleNav(){this.#e.toggleNav()}static \u0275fac=function(n){return new(n||o)};static \u0275cmp=N({type:o,selectors:[["app-mobile-menu-toggle"]],decls:1,vars:1,consts:[["shButton","",1,"small","toggle-sidebar","ghost"],["shButton","",1,"small","toggle-sidebar","ghost",3,"click"],[1,"cross"],[1,"burger"]],template:function(n,e){n&1&&g(0,he,3,1,"button",0),n&2&&p(e.isMobile()?0:-1)},dependencies:[A,P],styles:["[_nghost-%COMP%]{display:contents}.toggle-sidebar[_ngcontent-%COMP%]{position:relative;display:flex;align-items:center;justify-content:center}.toggle-sidebar[_ngcontent-%COMP%] .cross[_ngcontent-%COMP%], .toggle-sidebar[_ngcontent-%COMP%] .burger[_ngcontent-%COMP%]{opacity:1;transition:opacity 124ms linear;margin:0}.toggle-sidebar[_ngcontent-%COMP%] .cross.hidden[_ngcontent-%COMP%], .toggle-sidebar[_ngcontent-%COMP%] .burger.hidden[_ngcontent-%COMP%]{opacity:0}"],changeDetection:0})};var Ne=()=>["/connect/logon"];function ve(o,t){o&1&&(C(0,0,1),T(1,"div",9),m())}function be(o,t){o&1&&(C(0,0,2),T(1,"div",10),m())}function ye(o,t){if(o&1){let n=D();a(0,"div",8),c("click",function(){E(n);let i=S();return O(i.resetAndRetry())}),C(1,0),g(2,ve,2,0)(3,be,2,0),m(),l()}if(o&2){let n=S();r(2),p(n.resetting()?2:3)}}function Be(o,t){o&1&&(a(0,"div",6),C(1,1),T(2,"div",11),m(),l()),o&2&&R("routerLink",H(1,Ne))}function ke(o,t){o&1&&(a(0,"div",6),C(1,2),T(2,"div",10),m(),l()),o&2&&R("routerLink",H(1,Ne))}function Le(o,t){if(o&1){let n=D();a(0,"div",7),C(1,3),a(2,"sh-icon",12),c("click",function(){E(n);let i=S();return O(i.cancel())}),l(),a(3,"div",13),c("click",function(){E(n);let i=S();return O(i.claim())}),l(),T(4,"div",14),m(),l()}}function Ge(o,t){if(o&1){let n=D();a(0,"div",8),c("click",function(){E(n);let i=S();return O(i.openConsole())}),C(1,4),T(2,"div",15),m(),l()}}var k=class o{#e=d(Ee);state=this.#e.state;resetting=f(!1);stateEffect=ee(()=>{let t=this.#e.state(),n=this.resetting();t==="registered"&&n&&(this.resetting.set(!1),this.#e.beginRemoteRegistration())});ngOnInit(){this.#e.refreshRemoteControlStatus()}claim(){let t=this.#e.claimUrl();t&&window.open(t,"_blank")}cancel(){this.#e.cancelRemoteRegistration()}resetAndRetry(){this.resetting.set(!0),this.#e.cancelRemoteRegistration()}openConsole(){this.#e.openConsole()}static \u0275fac=function(n){return new(n||o)};static \u0275cmp=N({type:o,selectors:[["app-remote-connectivity-status"]],decls:5,vars:1,consts:()=>{let t;t=$localize`${"\uFFFD*2:1\uFFFD"}:START_BLOCK_IF: Resetting ${"\uFFFD#1:1\uFFFD"}:START_TAG_DIV:${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_DIV:${"\uFFFD/*2:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*3:2\uFFFD"}:START_BLOCK_ELSE: Click to connect ${"\uFFFD#1:2\uFFFD"}:START_TAG_DIV_1:${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_DIV:${"\uFFFD/*3:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,t=v(t);let n;n=$localize` Connecting ${"\uFFFD#2\uFFFD"}:START_TAG_DIV:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_DIV:`;let e;e=$localize` Click to register ${"\uFFFD#2\uFFFD"}:START_TAG_DIV:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_DIV:`;let i;i=$localize`Cancel registration`;let s;s=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:x-circle${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD#3\uFFFD"}:START_TAG_DIV:Click to claim${"[\uFFFD/#3\uFFFD|\uFFFD/#4\uFFFD]"}:CLOSE_TAG_DIV:${"\uFFFD#4\uFFFD"}:START_TAG_DIV_1:${"[\uFFFD/#3\uFFFD|\uFFFD/#4\uFFFD]"}:CLOSE_TAG_DIV:`,s=v(s);let u;return u=$localize` Connected ${"\uFFFD#2\uFFFD"}:START_TAG_DIV:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_DIV:`,[t,n,e,s,u,[1,"connectivity-status"],[1,"connectivity-status",3,"routerLink"],[1,"connectivity-status","claim"],[1,"connectivity-status",3,"click"],[1,"status","blinking"],[1,"status"],[1,"status","warning","blinking"],["shTooltip",i,3,"click"],[1,"claim",3,"click"],[1,"status","success","blinking"],[1,"status","success"]]},template:function(n,e){if(n&1&&g(0,ye,4,1,"div",5)(1,Be,3,2,"div",6)(2,ke,3,2,"div",6)(3,Le,5,0,"div",7)(4,Ge,3,0,"div",5),n&2){let i=e.state()==="unknown"||e.state()==="inactive"||e.state()==="registeringfaulted",s=e.state()==="registeringfaulted",u=e.state()==="registering",_=e.state()==="registered",M=e.state()==="connected"||e.state()==="disabled"||e.state()==="connecting";p(s?0:u?1:i?2:_?3:M?4:-1)}},dependencies:[oe,P,ge],styles:["[_nghost-%COMP%]{display:flex;align-items:center;padding:0 .75rem}@media only screen and (max-width:768px){[_nghost-%COMP%]{padding:0}}.hide-text[_nghost-%COMP%]{font-size:0}.in-menu[_nghost-%COMP%]{padding:.75rem;border-bottom:1px solid var(--base-4)}.connectivity-status[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;cursor:pointer}.connectivity-status[_ngcontent-%COMP%]:hover{color:var(--primary-8)}.connectivity-status.claim[_ngcontent-%COMP%]{display:flex;gap:.5rem;cursor:pointer}.connectivity-status.claim[_ngcontent-%COMP%]:hover{color:inherit}.connectivity-status.claim[_ngcontent-%COMP%] .claim[_ngcontent-%COMP%]:hover{color:var(--primary-8)}.connectivity-status.claim[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]:hover{color:var(--error-8)}.status[_ngcontent-%COMP%]{width:.625rem;height:.625rem;border-radius:50%;background-color:var(--base-4)}.status.success[_ngcontent-%COMP%]{background-color:var(--success-8)}.status.warning[_ngcontent-%COMP%]{background-color:var(--warn-8)}.status.blinking[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_blinking 1s infinite}@keyframes _ngcontent-%COMP%_blinking{0%{opacity:.2}50%{opacity:1}to{opacity:.2}}"],changeDetection:0})};var Me={Byte:"B",KByte:"KB",MByte:"MB",GByte:"GB",TByte:"TB",PByte:"PB"},xe=["mbps","gbps"],Ie=8,W=1024,U=W*1024,j=U*1024,Z=j*1024,Re=Z*1024,$e={B:1,KB:W,MB:U,GB:j,TB:Z,PB:Re},Ue=1e3,K=Ue*1e3,X=K*1e3,we=[{threshold:Re,unitPrefix:"PByte"},{threshold:Z,unitPrefix:"TByte"},{threshold:j,unitPrefix:"GByte"},{threshold:U,unitPrefix:"MByte"},{threshold:W,unitPrefix:"KByte"},{threshold:1,unitPrefix:"Byte"}],L=class o{#e=d(x);closed=ie();isSubmitting=f(!1);sizeOptions=f([...xe]);maxUpload=f(0);maxDownload=f(0);maxUploadUnit=f("mbps");maxDownloadUnit=f("mbps");ngOnInit(){this.init()}convertToBitsPerSecondUnits(t,n){let i=t*($e[n.toUpperCase()]||U)*Ie;return i===0?{value:0,unit:"mbps"}:i>=X?{value:parseFloat((i/X).toFixed(2)),unit:"gbps"}:{value:parseFloat((i/K).toFixed(2)),unit:"mbps"}}convertFromBitsPerSecondUnits(t,n){let e=0;switch(n){case"gbps":e=t*X;break;case"mbps":e=t*K;break}let i=e/Ie;if(i===0)return{valueForApi:0,unitPrefixForApi:"Byte"};for(let{threshold:s,unitPrefix:u}of we)if(i>=s)return{valueForApi:Math.round(i/s),unitPrefixForApi:u};return{valueForApi:Math.round(i),unitPrefixForApi:"Byte"}}init(){this.#e.getApiV1Serversettings().subscribe({next:t=>{let n=t?.["max-upload-speed"],e=t?.["max-download-speed"];if(n&&n!==""){let i=n.match(/^(\d+(?:\.\d+)?)([A-Za-z]+)$/);if(i){let s=parseFloat(i[1]),u=i[2],_=this.convertToBitsPerSecondUnits(s,u);this.maxUpload.set(_.value),this.maxUploadUnit.set(_.unit)}else console.warn("Unexpected max-upload-speed format from API:",n),this.resetUpload()}else this.resetUpload();if(e&&e!==""){let i=e.match(/^(\d+(?:\.\d+)?)([A-Za-z]+)$/);if(i){let s=parseFloat(i[1]),u=i[2],_=this.convertToBitsPerSecondUnits(s,u);this.maxDownload.set(_.value),this.maxDownloadUnit.set(_.unit)}else console.warn("Unexpected max-download-speed format from API:",e),this.resetDownload()}else this.resetDownload()},error:t=>{console.error("Failed to get server settings:",t),this.resetDownload(),this.resetUpload()}})}resetDownload(){this.maxDownload.set(0),this.maxDownloadUnit.set("mbps")}resetUpload(){this.maxUpload.set(0),this.maxUploadUnit.set("mbps")}blockDecimalKeys(t){if([".",","].includes(t.key))return t.preventDefault()}cleanupInputAfterPasting(t){t.preventDefault();let n=t.clipboardData?.getData("text/plain");if(!n)return;let e=n.replaceAll(/[\.,]/g,"");t.target.value=e}submit(){this.isSubmitting.set(!0);let t="",n="",e=this.maxUpload()??0,i=this.maxUploadUnit(),s=this.maxDownload()??0,u=this.maxDownloadUnit();if(e>0){let{valueForApi:_,unitPrefixForApi:M}=this.convertFromBitsPerSecondUnits(e,i),h=Me[M];h?t=`${_}${h}`:console.error(`Invalid unit prefix for API submission (upload): ${M}. Defaulting to empty string.`)}if(s){let{valueForApi:_,unitPrefixForApi:M}=this.convertFromBitsPerSecondUnits(s,u),h=Me[M];h?n=`${_}${h}`:console.error(`Invalid unit prefix for API submission (download): ${M}. Defaulting to empty string.`)}this.#e.patchApiV1Serversettings({requestBody:{"max-upload-speed":t,"max-download-speed":n}}).pipe(Q(()=>this.isSubmitting.set(!1))).subscribe({next:()=>{this.closed.emit(!0)},error:_=>{console.error("Failed to submit throttle settings:",_)}})}static \u0275fac=function(n){return new(n||o)};static \u0275cmp=N({type:o,selectors:[["app-throttle-settings-dialog"]],outputs:{closed:"closed"},decls:26,vars:10,consts:()=>{let t;t=$localize`Throttle network speed`;let n;n=$localize`We will round bits to the nearest byte value.`;let e;e=$localize`Max upload speed`;let i;i=$localize`Max download speed`;let s;s=$localize`Cancel`;let u;return u=$localize` Update settings `,[t,n,e,i,s,u,["content",""],[1,"column"],[1,"field-row"],["type","number",3,"paste","keydown","ngModelChange","ngModel"],[3,"isClearable","options"],["type","text",3,"ngModelChange","ngModel"],["footer",""],["shButton","",3,"click"],["shButton","",1,"raised","primary",3,"click"]]},template:function(n,e){n&1&&(a(0,"header")(1,"h3"),I(2,0),l(),a(3,"p"),I(4,1),l()(),a(5,"div",6)(6,"div",7)(7,"div",8)(8,"label"),I(9,2),l(),a(10,"sh-form-field")(11,"input",9),c("paste",function(s){return e.cleanupInputAfterPasting(s)})("keydown",function(s){return e.blockDecimalKeys(s)}),B("ngModelChange",function(s){return y(e.maxUpload,s)||(e.maxUpload=s),s}),l()(),a(12,"sh-select",10)(13,"input",11),B("ngModelChange",function(s){return y(e.maxUploadUnit,s)||(e.maxUploadUnit=s),s}),l()()(),a(14,"div",8)(15,"label"),I(16,3),l(),a(17,"sh-form-field")(18,"input",9),c("paste",function(s){return e.cleanupInputAfterPasting(s)})("keydown",function(s){return e.blockDecimalKeys(s)}),B("ngModelChange",function(s){return y(e.maxDownload,s)||(e.maxDownload=s),s}),l()(),a(19,"sh-select",10)(20,"input",11),B("ngModelChange",function(s){return y(e.maxDownloadUnit,s)||(e.maxDownloadUnit=s),s}),l()()()()(),a(21,"footer",12)(22,"button",13),c("click",function(){return e.closed.emit(!1)}),I(23,4),l(),a(24,"button",14),c("click",function(){return e.submit()}),I(25,5),l()()),n&2&&(r(11),b("ngModel",e.maxUpload),r(),R("isClearable",!1)("options",e.sizeOptions()),r(),b("ngModel",e.maxUploadUnit),r(5),b("ngModel",e.maxDownload),r(),R("isClearable",!1)("options",e.sizeOptions()),r(),b("ngModel",e.maxDownloadUnit),r(4),G("loading",e.isSubmitting()))},dependencies:[ce,ae,re,le,_e,ue,de,A],styles:['[_nghost-%COMP%]{display:block}h3[_ngcontent-%COMP%]{font:var(--title-30)}header[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:flex-start;padding:1rem;gap:.5rem;margin-bottom:1rem}.column[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.field-row[_ngcontent-%COMP%]{display:grid;grid-template-areas:"label label" "input select";grid-template-columns:1fr auto;align-items:center;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{grid-area:label}.field-row[_ngcontent-%COMP%] sh-form-field[_ngcontent-%COMP%]{grid-area:input}.field-row[_ngcontent-%COMP%] sh-select[_ngcontent-%COMP%]{grid-area:select}'],changeDetection:0})};function Ve(o,t){o&1&&T(0,"app-remote-connectivity-status")}function He(o,t){if(o&1){let n=D();a(0,"button",7),c("click",function(){E(n);let i=S(2);return O(i.abort())}),C(1,1),T(2,"sh-icon"),m(),l()}}function Ye(o,t){if(o&1){let n=D();a(0,"button",7),c("click",function(){E(n);let i=S(2);return O(i.stop())}),C(1,2),T(2,"sh-icon"),m(),l()}}function ze(o,t){if(o&1&&g(0,He,3,0,"button",14)(1,Ye,3,0,"button",14),o&2){let n=S();p(n.isStopping()?0:1)}}function Je(o,t){o&1&&(C(0,0,1),T(1,"sh-icon"),m())}function Xe(o,t){o&1&&(C(0,0,2),T(1,"sh-icon"),m())}function Ke(o,t){o&1&&T(0,"app-remote-connectivity-status",10)}function We(o,t){o&1&&T(0,"app-remote-connectivity-status",12)}function je(o,t){if(o&1){let n=D();a(0,"button",13),c("click",function(){E(n);let i=S();return O(i.isStopping()?i.abort():i.stop())}),a(1,"sh-icon"),F(2),l(),F(3),l()}if(o&2){let n=S();r(2),w(n.isStopping()?"skull":"stop"),r(),V(" ",n.isStopping()?"Abort":"Stop"," ")}}var q=class o{#e=d(x);#t=d(me);#n=d(Te);#s=d(Ce);#i=d(se);#a=d(pe);#l=d(Fe);clientIsRunning=this.#t.clientIsRunning;isResuming=this.#t.isResuming;runningTask=Y(()=>this.#s.serverState()?.ActiveTask?.Item1);isStopping=Y(()=>this.runningTask()==this.#o());#o=f(-1);isUsingRelay=this.#i.relayIsEnabled;hideConsoleConnectionStatus=this.#l.isConsoleConnectionStatusHidden;openThrottleSettingsDialog(){this.#n.open(L,{maxWidth:"550px",width:"100%"})}openPauseDialog(){this.#n.open(De,{maxWidth:"550px",width:"100%"})}pauseResume(){if(this.clientIsRunning()){this.openPauseDialog();return}this.#t.pauseResume().subscribe()}stop(){let t=this.runningTask();t&&(this.#o.set(t),this.#e.postApiV1TaskByTaskidStop({taskid:t}).subscribe())}abort(){let t=this.runningTask();t&&this.#e.postApiV1TaskByTaskidAbort({taskid:t}).subscribe()}ngAfterViewInit(){let t=this.#i.relayIsEnabled()||!this.#a.hasWebSocket()?"longpoll":"websocket";this.#t.setConnectionMethod(t)}static \u0275fac=function(n){return new(n||o)};static \u0275cmp=N({type:o,selectors:[["app-status-bar"]],decls:31,vars:10,consts:()=>{let t;t=$localize`${"\uFFFD*9:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:pause${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Pause ${"\uFFFD/*9:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*10:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:play${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Resume ${"\uFFFD/*10:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,t=v(t);let n;n=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:skull${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Abort `;let e;return e=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:stop${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Stop `,[t,n,e,[1,"current-backup"],[1,"global-progress"],[1,"current-backup-actions"],[1,"desktop-actions"],["shButton","",3,"click"],[1,"mobile-actions"],["shButton","",1,"small","menu-mobile-toggle"],[1,"hide-text"],["menu",""],[1,"in-menu"],[3,"click"],["shButton",""]]},template:function(n,e){n&1&&(a(0,"div",3),T(1,"app-mobile-menu-toggle")(2,"app-backup-progress",4),a(3,"div",5)(4,"div",6),g(5,Ve,1,0,"app-remote-connectivity-status"),g(6,ze,2,1),a(7,"button",7),c("click",function(){return e.pauseResume()}),C(8,0),g(9,Je,2,0)(10,Xe,2,0),m(),l(),a(11,"button",7),c("click",function(){return e.openThrottleSettingsDialog()}),a(12,"sh-icon"),F(13,"speedometer"),l()()(),a(14,"div",8)(15,"sh-menu")(16,"button",9),g(17,Ke,1,0,"app-remote-connectivity-status",10),a(18,"sh-icon"),F(19,"dots-three-vertical-bold"),l()(),te(20,11),g(21,We,1,0,"app-remote-connectivity-status",12),g(22,je,4,2,"button"),a(23,"button",13),c("click",function(){return e.pauseResume()}),a(24,"sh-icon"),F(25),l(),F(26),l(),a(27,"button",13),c("click",function(){return e.openThrottleSettingsDialog()}),a(28,"sh-icon"),F(29,"speedometer"),l(),F(30," Throttle Settings "),l(),ne(),l()()()()),n&2&&(r(5),p(!e.isUsingRelay()&&!e.hideConsoleConnectionStatus()?5:-1),r(),p(e.runningTask()?6:-1),r(),G("loading",e.isResuming()),r(2),p(e.clientIsRunning()?9:10),r(8),p(!e.isUsingRelay()&&!e.hideConsoleConnectionStatus()?17:-1),r(4),p(!e.isUsingRelay()&&!e.hideConsoleConnectionStatus()?21:-1),r(),p(e.runningTask()?22:-1),r(3),w(e.clientIsRunning()?"pause":"play"),r(),V(" ",e.clientIsRunning()?"Pause":"Resume"," "))},dependencies:[k,P,A,Se,$,fe],styles:["[_nghost-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:1rem;min-height:3.875rem;border-bottom:1px solid var(--base-4);position:sticky;top:0;z-index:2000;background:var(--base-1)}[_nghost-%COMP%]:has(sh-progress-bar){padding:1rem 1rem 1.5rem}.current-backup[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:100%;gap:.5rem}.global-progress[_ngcontent-%COMP%]{flex:1 0;min-width:18.75rem}.current-backup-actions[_ngcontent-%COMP%], .current-backup-actions[_ngcontent-%COMP%] .desktop-actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}@media only screen and (max-width:768px){.current-backup-actions[_ngcontent-%COMP%] .desktop-actions[_ngcontent-%COMP%]{display:none}}.current-backup-actions[_ngcontent-%COMP%] .mobile-actions[_ngcontent-%COMP%]{display:none}@media only screen and (max-width:768px){.current-backup-actions[_ngcontent-%COMP%] .mobile-actions[_ngcontent-%COMP%]{display:flex}}.current-backup-actions[_ngcontent-%COMP%] .menu-mobile-toggle[_ngcontent-%COMP%]{position:relative}.current-backup-actions[_ngcontent-%COMP%] .menu-mobile-toggle[_ngcontent-%COMP%] app-remote-connectivity-status[_ngcontent-%COMP%]{position:absolute;top:-.25rem;right:-.25rem}.menu-status-item[_ngcontent-%COMP%]{padding:.5rem 1rem;display:flex;flex-direction:column;gap:.25rem;border-bottom:1px solid var(--base-4);margin-bottom:.25rem}.menu-status-item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem;font-size:.875rem}"],changeDetection:0})};export{q as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as le}from"./chunk-
|
|
1
|
+
import{a as le}from"./chunk-YF6ULZXZ.js";import"./chunk-6Q6SSTBK.js";import{a as ae}from"./chunk-I4XRVBRQ.js";import{a as _e}from"./chunk-RFB5A3B7.js";import"./chunk-DWFQAX4H.js";import{c as re}from"./chunk-AYOFR344.js";import"./chunk-LTVI3WYF.js";import"./chunk-BEXYTIOL.js";import"./chunk-DKA7IP53.js";import{B as ne,D as ie,b as H,e as Q,i as Y,s as Z,v as ee,z as te}from"./chunk-YCLTQEU6.js";import{d as oe}from"./chunk-2LSZ2I43.js";import{d as j,e as q}from"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Ab as f,Ac as X,Bb as i,Cb as o,E as K,Ec as z,Hc as V,Kb as N,Pc as M,Ra as r,Tb as c,Ub as A,Vb as L,Vc as W,Wb as F,Xb as $,Z as u,Zb as C,ca as P,da as T,eb as y,ic as x,l as k,lc as E,oa as p,p as U,qc as S,rc as D,sc as h,tc as G,ub as g,uc as w,vb as m,vc as v,z as I,zc as J}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";var ce=l=>["/backup",l,"export"],se=()=>["/"];function Ee(l,_){if(l&1){let e=N();i(0,"section")(1,"h4"),c(2,4),o(),i(3,"p"),c(4,5),o(),i(5,"sh-checkbox",11),E(6," Delete local database "),i(7,"input",12),h("ngModelChange",function(t){P(e);let a=C();return D(a.deleteLocalDb,t)||(a.deleteLocalDb=t),T(t)}),o()()()}if(l&2){let e=C();r(7),S("ngModel",e.deleteLocalDb)}}function ue(l,_){if(l&1){let e=N();i(0,"section")(1,"h4"),c(2,6),o(),i(3,"p"),c(4,7),z(5,"bytes"),o(),i(6,"sh-checkbox",11),E(7," Delete remote files "),i(8,"input",12),h("ngModelChange",function(t){P(e);let a=C();return D(a.deleteRemoteFiles,t)||(a.deleteRemoteFiles=t),T(t)}),o()()()}if(l&2){let e=C(),n=v(0),t=(n==null||n.Backup==null||n.Backup.Metadata==null?null:n.Backup.Metadata.TargetFilesSize)??0;r(5),A(e.fileCount())(e.fileCount())(V(5,4,t,!0,!0)),L(4),r(3),S("ngModel",e.deleteRemoteFiles)}}var B=class l{#t=u(oe);#n=u(te);#e=u(le);#i=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=p(!1);deleteRemoteFiles=p(!1);isDeleting=p(!1);deleteBackup(){let _=this.id(),e=this.deleteLocalDb(),n=this.deleteRemoteFiles();this.isDeleting.set(!0),this.#n.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:t=>{t&&this.#e.deleteBackup({id:_,deleteLocalDb:e,deleteRemoteFiles:n}).pipe(K(()=>this.isDeleting.set(!1))).subscribe({next:()=>{this.#i.navigate(["/"])}})}})}static \u0275fac=function(e){return new(e||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 e;e=$localize`Export configuration`;let n;n=$localize`If you want to use the backup later, you can export the configuration before deleting it.`;let t;t=$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? `,[_,e,n,t,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(e,n){if(e&1&&(G(0),i(1,"h3"),c(2,0),o(),g(3,Ee,8,1,"section"),i(4,"section")(5,"h4"),c(6,1),o(),i(7,"p"),c(8,2),o(),i(9,"button",8),E(10," Export configuration "),i(11,"sh-icon"),E(12,"caret-right"),o()()(),g(13,ue,9,8,"section"),i(14,"div",9)(15,"button",8),c(16,3),o(),i(17,"button",10),$("click",function(){return n.deleteBackup()}),E(18,"Delete backup"),o()()),e&2){let t=w(n.backup()),a=n.noLocalDbResource.value();r(2),A(t==null||t.Backup==null?null:t.Backup.Name),L(2),r(),m(a?3:-1),r(6),f("routerLink",X(8,ce,n.id())),r(4),m(a?13:-1),r(2),f("routerLink",J(10,se)),r(2),x("loading",n.isDeleting())}},dependencies:[ie,ne,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};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-7CGTOI24.js";var o=[{path:"",redirectTo:"select-files",pathMatch:"full"},{path:"destination",loadComponent:()=>import("./chunk-NYX7YT7G.js")},{path:"encryption",loadComponent:()=>import("./chunk-562BU33Q.js")},{path:"select-files",loadComponent:()=>import("./chunk-3ULPLOSF.js")},{path:"options",loadComponent:()=>import("./chunk-VUABEJRL.js")},{path:":taskid/progress",loadComponent:()=>import("./chunk-PUBEHQ4W.js")}],t=o;export{t as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{n as a,o as b}from"./chunk-
|
|
1
|
+
import{n as a,o as b}from"./chunk-TDEVA3XM.js";import"./chunk-ITA7DTN3.js";import"./chunk-Q72Y55NB.js";import"./chunk-NXF5BMPG.js";import"./chunk-6Q6SSTBK.js";import"./chunk-IUJGDYFS.js";import"./chunk-X64LSE6Y.js";import"./chunk-RFB5A3B7.js";import"./chunk-FKYRYVJD.js";import"./chunk-AYOFR344.js";import"./chunk-LTVI3WYF.js";import"./chunk-BEXYTIOL.js";import"./chunk-DKA7IP53.js";import"./chunk-YCLTQEU6.js";import"./chunk-2LSZ2I43.js";import"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";export{a as createSourceDataForm,b as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as fe}from"./chunk-WQVQC2MC.js";import"./chunk-YQD4QIGG.js";import{a as Ce}from"./chunk-W4HWOC3K.js";import{a as pe,b as z}from"./chunk-I2HYK2BL.js";import"./chunk-B35WNLRM.js";import{a as ue}from"./chunk-SLS3DCJP.js";import"./chunk-SUY5AQLW.js";import"./chunk-6Q6SSTBK.js";import{a as me}from"./chunk-I4XRVBRQ.js";import"./chunk-RFB5A3B7.js";import"./chunk-AZJ2P3YU.js";import{b as ge}from"./chunk-UUQWSINE.js";import"./chunk-BEXYTIOL.js";import"./chunk-LO5YNFFR.js";import{B as se,C as le,J as ce,L as de,v as oe,z as re}from"./chunk-YCLTQEU6.js";import{d as _e}from"./chunk-2LSZ2I43.js";import"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import{T as ee,U as te,ha as ne,ma as ie,qa as ae}from"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Ab as p,Bb as e,Cb as t,Db as I,Ec as _,Fc as C,Gc as E,Hb as Y,Ib as Z,Kb as B,Pc as L,Ra as r,Tb as S,U as X,Xb as h,Z as x,Zb as g,ca as y,da as b,ea as V,eb as H,fa as j,ic as G,jb as P,lc as o,mc as m,nc as u,oa as N,oc as $,qa as W,ub as D,vb as F,wb as q,yb as K,zb as Q}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";var U=class s{#e=x(z);#n=x(ge);#i=N([]);recentFiles=this.#i.asReadonly();#r=5;#s=N(null);etaData=this.#s.asReadonly();#a=null;#t=null;#o=null;recentFileEffect=W(()=>{let i=this.#e.statusData();i&&i.CurrentFilename&&i.CurrentFilesize!==void 0&&this.#l(i.CurrentFilename,i.CurrentFilesize)});#l(i,n){let a=new Date;this.#i.update(l=>l.length>0&&l[0].filename===i?l:[{filename:i,filesize:n,timestamp:a},...l].slice(0,this.#r))}activateView(){this.#a=new Date;let i=this.#e.statusData();i&&i.ProcessedFileCount!==void 0&&i.ProcessedFileSize!==void 0&&(this.#t={files:i.ProcessedFileCount,bytes:i.ProcessedFileSize}),this.#o=setInterval(()=>{this.#c()},1e3)}deactivateView(){this.#a=null,this.#t=null,this.#o&&(clearInterval(this.#o),this.#o=null)}#c(){if(!this.#a||!this.#t)return;let i=this.#e.statusData();if(!i)return;let n=new Date,a=(n.getTime()-this.#a.getTime())/1e3;if(a<5)return;let l=i.ProcessedFileCount||0,d=i.ProcessedFileSize||0,c=l-this.#t.files,k=d-this.#t.bytes,M=c/a,O=k/a,A=(i.TotalFileCount||0)-l,f=(i.TotalFileSize||0)-d,T=null,v=null;M>0&&(T=A/M),O>0&&(v=f/O);let R=null,w="bytes";if(T!==null&&v!==null){let Se=Math.max(T,v);R=new Date(n.getTime()+Se*1e3),w=T>v?"files":"bytes"}else T!==null?(R=new Date(n.getTime()+T*1e3),w="files"):v!==null&&(R=new Date(n.getTime()+v*1e3),w="bytes");this.#s.set({startTime:this.#a,filesProcessedAtStart:this.#t.files,bytesProcessedAtStart:this.#t.bytes,currentFilesPerSecond:M,currentBytesPerSecond:O,estimatedCompletion:R,metric:w})}static \u0275fac=function(n){return new(n||s)};static \u0275prov=X({token:s,factory:s.\u0275fac,providedIn:"root"})};function xe(s,i){if(s&1&&(e(0,"div",42)(1,"span",20),o(2,"Processing"),t(),e(3,"sh-list",43)(4,"div",44)(5,"sh-icon"),o(6,"file"),t(),e(7,"div",45)(8,"span",46),o(9),t(),e(10,"span",47),o(11),_(12,"bytes"),t()()()()()),s&2){let n,a,l,d=g(2);r(8),p("title",(n=d.statusData())==null?null:n.CurrentFilename),r(),u(" ",(a=d.statusData())==null?null:a.CurrentFilename," "),r(2),m(C(12,3,(l=d.statusData())==null?null:l.CurrentFilesize))}}function Me(s,i){if(s&1&&(e(0,"div",35)(1,"span",46),o(2),t(),e(3,"span",47),o(4),_(5,"bytes"),t()()),s&2){let n=i.$implicit;r(),p("title",n.filename),r(),m(n.filename),r(2),m(C(5,3,n.filesize))}}function Oe(s,i){s&1&&(e(0,"div",36),S(1,2),t())}function Te(s,i){if(s&1&&(e(0,"sh-list")(1,"div",48)(2,"span",20),o(3,"ETA"),t(),e(4,"span",21),o(5),_(6,"date"),e(7,"span",49),o(8),_(9,"relativeTime"),t()()(),e(10,"div",50)(11,"span",20),o(12,"Files/s"),t(),e(13,"span",21),o(14),_(15,"number"),t()(),e(16,"div",50)(17,"span",20),o(18,"Upload Speed"),t(),e(19,"span",21),o(20),_(21,"bytes"),t()()()),s&2){let n,a,l,d,c=g(2);r(5),u(" ",E(6,4,(n=c.etaData())==null?null:n.estimatedCompletion,"mediumTime")," "),r(3),u("(",C(9,7,(a=c.etaData())==null?null:a.estimatedCompletion),")"),r(6),m(E(15,9,(l=c.etaData())==null?null:l.currentFilesPerSecond,"1.1-1")),r(6),u("",C(21,12,(d=c.etaData())==null?null:d.currentBytesPerSecond),"/s")}}function ve(s,i){if(s&1&&(e(0,"div",53)(1,"div",54)(2,"span",55),o(3),t(),e(4,"span",56),o(5),_(6,"bytes"),t()(),I(7,"sh-progress-bar",57),t()),s&2){let n=i.$implicit;r(2),p("title",n.BackendPath),r(),m(n.BackendPath),r(2),u("",C(6,4,n.BackendSpeed),"/s"),r(2),p("value",(n.BackendFileProgress||0)/(n.BackendFileSize||1)*100)}}function he(s,i){if(s&1&&(e(0,"div",51)(1,"sh-list"),P(2,ve,8,6,"div",52),t()()),s&2){let n,a=g(2);r(2),p("ngForOf",(n=a.statusData())==null?null:n.ActiveTransfers)}}function Ee(s,i){if(s&1){let n=B();e(0,"sh-card")(1,"div",13)(2,"div",14)(3,"sh-icon",15),o(4,"clock"),t(),e(5,"h2"),o(6),t()()(),e(7,"div",26)(8,"div",27)(9,"span",28),o(10),_(11,"number"),t()(),I(12,"sh-progress-bar",29),e(13,"sh-list")(14,"div",30)(15,"span",20),o(16,"Files"),t(),e(17,"span",21),o(18),t()(),e(19,"div",30)(20,"span",20),o(21,"Size"),t(),e(22,"span",21),o(23),_(24,"bytes"),_(25,"bytes"),t()()()()(),e(26,"sh-card")(27,"div",13)(28,"div",14)(29,"sh-icon",15),o(30,"file"),t(),e(31,"h3"),o(32,"Activity"),t()()(),e(33,"div",31),P(34,xe,13,5,"div",32),e(35,"div",33)(36,"span",20),S(37,1),t(),e(38,"sh-list",34),K(39,Me,6,5,"div",35,q),D(41,Oe,2,0,"div",36),t()()()(),e(42,"sh-card")(43,"div",13)(44,"div",14)(45,"sh-icon",15),o(46,"gauge"),t(),e(47,"h3"),o(48,"Performance"),t()(),e(49,"div",37),o(50),_(51,"bytes"),t()(),e(52,"div",38),P(53,Te,22,14,"sh-list",25),e(54,"div",39)(55,"button",40),h("click",function(){y(n);let l=g();return b(l.toggleTransfers())}),o(56),t(),P(57,he,3,1,"div",41),t()()()}if(s&2){let n,a,l,d,c=g();r(6),m(c.statusText()),r(4),u("",E(11,13,c.progress(),"1.0-0"),"%"),r(2),p("value",c.progress()),r(6),$("",(n=c.statusData())==null?null:n.ProcessedFileCount," / ",(n=c.statusData())==null?null:n.TotalFileCount),r(5),$(" ",C(24,16,(a=c.statusData())==null?null:a.ProcessedFileSize)," / ",C(25,18,(a=c.statusData())==null?null:a.TotalFileSize)," "),r(11),p("ngIf",(l=c.statusData())==null?null:l.CurrentFilename),r(5),Q(c.recentFiles()),r(2),F(c.recentFiles().length===0?41:-1),r(9),u("",C(51,20,(d=c.statusData())==null?null:d.BackendSpeed),"/s"),r(3),p("ngIf",c.etaData()),r(3),u(" ",c.transfersExpanded()?"Hide Details":"Show Details"," "),r(),p("ngIf",c.transfersExpanded())}}function ye(s,i){if(s&1&&(e(0,"sh-card",75)(1,"div",13)(2,"div",14)(3,"sh-icon",15),o(4,"calendar"),t(),e(5,"h3"),S(6,7),t()()(),e(7,"div",76)(8,"div",77)(9,"span",78),o(10),t(),e(11,"div",79)(12,"span",80),o(13),_(14,"date"),t(),e(15,"span",81),o(16),_(17,"relativeTime"),t()()(),e(18,"sh-icon",82),o(19,"caret-right"),t()()()),s&2){let n,a=g(2);r(10),m((n=a.nextBackup().backup)==null?null:n.Name),r(3),m(E(14,3,a.nextBackup().time,"medium")),r(3),u("(",C(17,6,a.nextBackup().time),")")}}function be(s,i){s&1&&(e(0,"span",74),S(1,8),t())}function Ne(s,i){if(s&1){let n=B();e(0,"sh-card",58)(1,"div",59)(2,"div",60)(3,"div",61),V(),e(4,"svg",62),I(5,"circle",63),t(),j(),e(6,"sh-icon",64),S(7,3),t()()(),e(8,"div",65)(9,"h2"),S(10,4),t(),e(11,"p",66),S(12,5),t()(),e(13,"div",67)(14,"button",68),h("click",function(){y(n);let l=g();return b(l.pauseResume())}),e(15,"sh-icon"),o(16),t(),o(17),t()()()(),P(18,ye,20,8,"sh-card",69),e(19,"sh-card",70)(20,"div",71)(21,"span",20),S(22,6),t(),e(23,"div",72)(24,"span",73),o(25),t(),D(26,be,2,0,"span",74),t()()()}if(s&2){let n,a=g();r(14),p("variant",a.clientIsRunning()?"primary":"secondary"),r(2),m(a.clientIsRunning()?"pause":"play"),r(),u(" ",a.clientIsRunning()?"Pause Execution":"Resume Execution"," "),r(),p("ngIf",a.nextBackup()),r(6),G("running",a.clientIsRunning()),r(),m((n=a.serverState())==null?null:n.ProgramState),r(),F(a.clientIsRunning()?-1:26)}}function Ie(s,i){if(s&1&&(e(0,"div",35)(1,"span",46),o(2),t(),e(3,"span",47),o(4),_(5,"bytes"),t()()),s&2){let n=i.$implicit;r(),p("title",n.filename),r(),m(n.filename),r(2),m(C(5,3,n.filesize))}}function ke(s,i){if(s&1&&(e(0,"sh-card",83)(1,"div",13)(2,"div",14)(3,"sh-icon",15),o(4,"clock-counter-clockwise"),t(),e(5,"h3"),S(6,9),t()()(),e(7,"sh-list"),P(8,Ie,6,5,"div",84),t()()),s&2){let n=g();r(8),p("ngForOf",n.recentFiles())}}function Ae(s,i){if(s&1&&(e(0,"div",19)(1,"span",20),o(2,"Next Task:"),t(),e(3,"div",21)(4,"div"),o(5),t(),e(6,"div",49),o(7),_(8,"date"),_(9,"relativeTime"),t()()()),s&2){let n,a=g();r(5),m((n=a.nextBackup().backup)==null?null:n.Name),r(2),$(" ",E(8,3,a.nextBackup().time,"medium")," (",C(9,6,a.nextBackup().time),") ")}}function Re(s,i){if(s&1){let n=B();Y(0),e(1,"button",85),h("click",function(){y(n);let l=g();return b(l.stop())}),e(2,"sh-icon"),o(3,"stop"),t(),o(4," Stop "),t(),e(5,"button",85),h("click",function(){y(n);let l=g();return b(l.abort())}),e(6,"sh-icon"),o(7,"x-circle"),t(),o(8," Abort "),t(),Z()}}var J=class s{#e=x(z);#n=x(U);#i=x(_e);#r=x(re);statusData=this.#e.statusData;serverState=this.#e.serverState;recentFiles=this.#n.recentFiles;etaData=this.#n.etaData;transfersExpanded=N(!1);clientIsRunning=this.#e.clientIsRunning;statusText=L(()=>{let i=this.statusData()?.Phase;return i?pe[i]||i:""});progress=L(()=>{let i=this.statusData();return i?(i.OverallProgress||0)*100:0});nextBackup=L(()=>({backup:this.serverState()?.ProposedSchedule?.[0]?.backup,time:this.serverState()?.ProposedSchedule?.[0]?.Item2}));ngOnInit(){this.#n.activateView()}ngOnDestroy(){this.#n.deactivateView()}toggleTransfers(){this.transfersExpanded.update(i=>!i)}isTaskRunning(){return!!this.statusData()?.TaskID}taskStartTime(){return this.etaData()?.startTime}currentBackupId(){return this.statusData()?.BackupID}pauseResume(){if(this.clientIsRunning()){this.#r.open(Ce,{maxWidth:"550px",width:"100%"});return}this.#e.pauseResume().subscribe()}stop(){let i=this.statusData()?.TaskID;i&&this.#i.postApiV1TaskByTaskidStop({taskid:i}).subscribe()}abort(){let i=this.statusData()?.TaskID;i&&this.#i.postApiV1TaskByTaskidAbort({taskid:i}).subscribe()}static \u0275fac=function(n){return new(n||s)};static \u0275cmp=H({type:s,selectors:[["app-status"]],decls:29,vars:13,consts:()=>{let i;i=$localize`Live Logs`;let n;n=$localize`Recently Processed`;let a;a=$localize`No recent files`;let l;l=$localize`check-bold`;let d;d=$localize`System Ready`;let c;c=$localize`Waiting for the next scheduled backup task.`;let k;k=$localize`Server State`;let M;M=$localize`Next Scheduled Task`;let O;O=$localize`Backups are currently paused`;let A;return A=$localize`Recent Activity`,[i,n,a,l,d,c,k,M,O,A,[1,"status-page"],["class","activity-card",4,"ngIf"],[1,"logs-card"],[1,"card-header"],[1,"header-titl-group"],[1,"header-icon"],[1,"logs-content"],[3,"asSimpleList","polling","whenFilter","backupIdFilter"],[1,"server-status-section"],[1,"status-row"],[1,"label"],[1,"value"],["class","status-row",4,"ngIf"],[1,"actions"],["shButton","",3,"click"],[4,"ngIf"],[1,"progress-content"],[1,"percentage-display"],[1,"percentage-value"],[3,"value"],["item","",1,"stat-item"],[1,"files-content"],["class","current-file-section",4,"ngIf"],[1,"recent-files-section"],[1,"recent-files-list"],["item","",1,"file-item"],["item","",1,"empty-state"],[1,"aggregate-speed"],[1,"performance-content"],[1,"transfers-section"],["shButton","","size","small","variant","ghost",1,"toggle-btn",3,"click"],["class","transfer-details",4,"ngIf"],[1,"current-file-section"],[1,"current-file-list"],["item","",1,"file-item","current"],[1,"file-details"],[1,"filename",3,"title"],[1,"filesize"],["item","",1,"eta-item"],[1,"sub-text"],["item","",1,"metric-item"],[1,"transfer-details"],["class","transfer-item","item","",4,"ngFor","ngForOf"],["item","",1,"transfer-item"],[1,"transfer-header"],[1,"path",3,"title"],[1,"speed"],[1,"mini-progress",3,"value"],[1,"idle-hero-card"],[1,"idle-content"],[1,"status-visual"],[1,"complete-status"],[1,"border-svg"],["cx","50","cy","50","r","45",1,"border-circle"],[1,"status-icon"],[1,"status-info"],[1,"status-description"],[1,"idle-actions"],["shButton","",3,"click","variant"],["class","next-task-hero",4,"ngIf"],[1,"server-state-card"],[1,"state-content"],[1,"state-line"],[1,"status-badge"],[1,"warning-text"],[1,"next-task-hero"],[1,"next-task-content"],[1,"task-main"],[1,"task-name"],[1,"task-time-group"],[1,"task-time"],[1,"task-relative"],[1,"chevron"],[1,"activity-card"],["class","file-item","item","",4,"ngFor","ngForOf"],["shButton","","color","warn",3,"click"]]},template:function(n,a){if(n&1&&(e(0,"div",10),D(1,Ee,58,22)(2,Ne,27,8),P(3,ke,9,1,"sh-card",11),e(4,"sh-card",12)(5,"div",13)(6,"div",14)(7,"sh-icon",15),o(8,"list"),t(),e(9,"h3"),S(10,0),t()()(),e(11,"div",16),I(12,"app-logs-live",17),t()(),e(13,"sh-card")(14,"div",18)(15,"h3"),o(16,"Server Status"),t(),e(17,"div",19)(18,"span",20),o(19,"State:"),t(),e(20,"span",21),o(21),t()(),P(22,Ae,10,8,"div",22),e(23,"div",23)(24,"button",24),h("click",function(){return a.pauseResume()}),e(25,"sh-icon"),o(26),t(),o(27),t(),P(28,Re,9,0,"ng-container",25),t()()()()),n&2){let l,d;G("idle",!a.isTaskRunning()),r(),F(a.isTaskRunning()?1:2),r(2),p("ngIf",!a.isTaskRunning()&&a.recentFiles().length>0),r(9),p("asSimpleList",!0)("polling",a.isTaskRunning())("whenFilter",(l=a.taskStartTime())==null?null:l.getTime())("backupIdFilter",a.currentBackupId()),r(9),m((d=a.serverState())==null?null:d.ProgramState),r(),p("ngIf",a.nextBackup()),r(4),m(a.clientIsRunning()?"pause":"play_arrow"),r(),u(" ",a.clientIsRunning()?"Pause":"Resume"," "),r(),p("ngIf",a.isTaskRunning())}},dependencies:[ae,ee,te,le,de,se,oe,fe,ce,ie,ne,me,ue],styles:["[_nghost-%COMP%]{display:block;padding:24px;max-width:1400px;margin:0 auto}.status-page[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr;gap:24px}@media(min-width:768px){.status-page[_ngcontent-%COMP%]{grid-template-columns:repeat(2,1fr)}}@media(min-width:1200px){.status-page[_ngcontent-%COMP%]{grid-template-columns:repeat(3,1fr)}}@media(min-width:1200px){.status-page[_ngcontent-%COMP%] .logs-card[_ngcontent-%COMP%], .status-page.idle[_ngcontent-%COMP%] .idle-hero-card[_ngcontent-%COMP%]{grid-column:span 2}.status-page.idle[_ngcontent-%COMP%] .next-task-hero[_ngcontent-%COMP%], .status-page.idle[_ngcontent-%COMP%] .server-state-card[_ngcontent-%COMP%]{grid-column:3}.status-page.idle[_ngcontent-%COMP%] .activity-card[_ngcontent-%COMP%], .status-page.idle[_ngcontent-%COMP%] .logs-card[_ngcontent-%COMP%]{grid-column:1/-1}}sh-card[_ngcontent-%COMP%]{height:100%;display:flex;flex-direction:column;--sh-card-padding: 24px}.card-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;margin-bottom:20px}.card-header[_ngcontent-%COMP%] .header-titl-group[_ngcontent-%COMP%]{display:flex;align-items:center;gap:12px}.card-header[_ngcontent-%COMP%] .header-titl-group[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{color:var(--primary-color);font-size:24px}.card-header[_ngcontent-%COMP%] .header-titl-group[_ngcontent-%COMP%] h2[_ngcontent-%COMP%], .card-header[_ngcontent-%COMP%] .header-titl-group[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{margin:0;font-size:1.1rem;font-weight:600;color:var(--text-primary)}.progress-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:20px}.progress-content[_ngcontent-%COMP%] .percentage-display[_ngcontent-%COMP%]{text-align:center}.progress-content[_ngcontent-%COMP%] .percentage-display[_ngcontent-%COMP%] .percentage-value[_ngcontent-%COMP%]{font-size:3rem;font-weight:800;color:var(--primary-color);line-height:1}.progress-content[_ngcontent-%COMP%] sh-progress-bar[_ngcontent-%COMP%]{height:8px;border-radius:4px;--sh-progress-bar-track-color: var(--bg-secondary)}.progress-content[_ngcontent-%COMP%] .stat-item[_ngcontent-%COMP%]{display:flex;justify-content:space-between;width:100%}.progress-content[_ngcontent-%COMP%] .stat-item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{color:var(--text-secondary);font-size:.9rem}.progress-content[_ngcontent-%COMP%] .stat-item[_ngcontent-%COMP%] .value[_ngcontent-%COMP%]{font-weight:600}.files-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:16px}.files-content[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;color:var(--text-secondary);font-weight:600;margin-bottom:4px;display:block;padding-left:12px}.files-content[_ngcontent-%COMP%] .file-item[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:100%}.files-content[_ngcontent-%COMP%] .file-item.current[_ngcontent-%COMP%]{gap:12px;justify-content:flex-start}.files-content[_ngcontent-%COMP%] .file-item.current[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{color:var(--primary-color)}.files-content[_ngcontent-%COMP%] .file-item.current[_ngcontent-%COMP%] .file-details[_ngcontent-%COMP%]{display:flex;flex-direction:column;overflow:hidden}.files-content[_ngcontent-%COMP%] .file-item[_ngcontent-%COMP%] .filename[_ngcontent-%COMP%]{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-right:12px;font-size:.9rem;font-weight:500;flex:1}.files-content[_ngcontent-%COMP%] .file-item[_ngcontent-%COMP%] .filesize[_ngcontent-%COMP%]{color:var(--text-secondary);font-size:.85rem;font-variant-numeric:tabular-nums;white-space:nowrap}.files-content[_ngcontent-%COMP%] .empty-state[_ngcontent-%COMP%]{color:var(--text-secondary);font-style:italic;text-align:center;width:100%}.performance-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:16px}.performance-content[_ngcontent-%COMP%] .aggregate-speed[_ngcontent-%COMP%]{font-size:1.2rem;font-weight:700;color:var(--text-primary);font-variant-numeric:tabular-nums}.performance-content[_ngcontent-%COMP%] .eta-item[_ngcontent-%COMP%], .performance-content[_ngcontent-%COMP%] .metric-item[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:100%}.performance-content[_ngcontent-%COMP%] .eta-item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%], .performance-content[_ngcontent-%COMP%] .metric-item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{color:var(--text-secondary);font-size:.9rem}.performance-content[_ngcontent-%COMP%] .eta-item[_ngcontent-%COMP%] .value[_ngcontent-%COMP%], .performance-content[_ngcontent-%COMP%] .metric-item[_ngcontent-%COMP%] .value[_ngcontent-%COMP%]{font-weight:600;font-variant-numeric:tabular-nums}.performance-content[_ngcontent-%COMP%] .eta-item[_ngcontent-%COMP%] .value[_ngcontent-%COMP%] .sub-text[_ngcontent-%COMP%], .performance-content[_ngcontent-%COMP%] .metric-item[_ngcontent-%COMP%] .value[_ngcontent-%COMP%] .sub-text[_ngcontent-%COMP%]{color:var(--text-secondary);font-weight:400;font-size:.85rem;margin-left:4px}.performance-content[_ngcontent-%COMP%] .transfers-section[_ngcontent-%COMP%] .toggle-btn[_ngcontent-%COMP%]{width:100%;margin-bottom:12px}.performance-content[_ngcontent-%COMP%] .transfers-section[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%]{display:flex;flex-direction:column;width:100%;gap:4px}.performance-content[_ngcontent-%COMP%] .transfers-section[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%] .transfer-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;font-size:.85rem}.performance-content[_ngcontent-%COMP%] .transfers-section[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%] .transfer-header[_ngcontent-%COMP%] .path[_ngcontent-%COMP%]{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-right:12px}.performance-content[_ngcontent-%COMP%] .transfers-section[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%] .transfer-header[_ngcontent-%COMP%] .speed[_ngcontent-%COMP%]{color:var(--text-secondary);font-variant-numeric:tabular-nums}.performance-content[_ngcontent-%COMP%] .transfers-section[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%] .mini-progress[_ngcontent-%COMP%]{height:4px}.logs-content[_ngcontent-%COMP%] app-logs-live[_ngcontent-%COMP%]{height:350px;display:block}.status-badge[_ngcontent-%COMP%]{padding:4px 12px;border-radius:12px;background:var(--bg-secondary);color:var(--text-secondary);font-size:.8rem;font-weight:500;text-transform:uppercase}.status-badge.running[_ngcontent-%COMP%]{background:rgba(var(--primary-rgb),.1);color:var(--primary-color)}.actions-grid[_ngcontent-%COMP%]{margin-top:auto;display:grid;grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:12px}.actions-grid[_ngcontent-%COMP%] .action-btn[_ngcontent-%COMP%]{width:100%;justify-content:center}.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:32px 0;gap:32px}@media(min-width:768px){.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%]{flex-direction:row;text-align:left;justify-content:space-around;padding:48px 0}}.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%] .status-visual[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center}.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%] .status-info[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{font-size:2rem;font-weight:700;margin-bottom:8px;color:var(--text-primary)}.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%] .status-info[_ngcontent-%COMP%] .status-description[_ngcontent-%COMP%]{color:var(--text-secondary);font-size:1.1rem;max-width:300px}.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%] .idle-actions[_ngcontent-%COMP%]{display:flex;align-items:center}.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%] .idle-actions[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{padding-left:32px;padding-right:32px}.complete-status[_ngcontent-%COMP%]{position:relative;width:120px;height:120px;display:flex;justify-content:center;align-items:center;color:var(--primary-color)}.complete-status[_ngcontent-%COMP%] .status-icon[_ngcontent-%COMP%]{font-size:48px;opacity:0;animation:_ngcontent-%COMP%_reveal-icon .2s linear forwards;animation-delay:1s}.border-svg[_ngcontent-%COMP%]{position:absolute;top:0;left:0;width:100%;height:100%}.border-circle[_ngcontent-%COMP%]{fill:none;stroke:var(--primary-color);stroke-width:5px;stroke-dasharray:282.74;stroke-dashoffset:282.74;animation:_ngcontent-%COMP%_draw-border 1.2s linear forwards}@keyframes _ngcontent-%COMP%_draw-border{to{stroke-dashoffset:0}}@keyframes _ngcontent-%COMP%_reveal-icon{to{opacity:1}}.next-task-hero[_ngcontent-%COMP%] .next-task-content[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;padding:12px 0}.next-task-hero[_ngcontent-%COMP%] .next-task-content[_ngcontent-%COMP%] .task-main[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:4px}.next-task-hero[_ngcontent-%COMP%] .next-task-content[_ngcontent-%COMP%] .task-main[_ngcontent-%COMP%] .task-name[_ngcontent-%COMP%]{font-size:1.2rem;font-weight:700;color:var(--primary-color)}.next-task-hero[_ngcontent-%COMP%] .next-task-content[_ngcontent-%COMP%] .task-main[_ngcontent-%COMP%] .task-time-group[_ngcontent-%COMP%]{display:flex;flex-direction:column;color:var(--text-secondary);font-size:.95rem}.next-task-hero[_ngcontent-%COMP%] .next-task-content[_ngcontent-%COMP%] .chevron[_ngcontent-%COMP%]{color:var(--text-secondary);opacity:.5}.server-state-card[_ngcontent-%COMP%] .state-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:12px}.server-state-card[_ngcontent-%COMP%] .state-content[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;color:var(--text-secondary);font-weight:600}.server-state-card[_ngcontent-%COMP%] .state-content[_ngcontent-%COMP%] .state-line[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:8px}.server-state-card[_ngcontent-%COMP%] .state-content[_ngcontent-%COMP%] .state-line[_ngcontent-%COMP%] .warning-text[_ngcontent-%COMP%]{font-size:.85rem;color:var(--error-color);font-weight:500}"],changeDetection:0})};export{J as default};
|
|
1
|
+
import{a as fe}from"./chunk-WQVQC2MC.js";import"./chunk-YQD4QIGG.js";import{a as Ce}from"./chunk-W4HWOC3K.js";import{a as pe,b as z}from"./chunk-XHUQYWAM.js";import"./chunk-YF6ULZXZ.js";import{a as ue}from"./chunk-SLS3DCJP.js";import"./chunk-SUY5AQLW.js";import"./chunk-6Q6SSTBK.js";import{a as me}from"./chunk-I4XRVBRQ.js";import"./chunk-RFB5A3B7.js";import"./chunk-DWFQAX4H.js";import{b as ge}from"./chunk-LTVI3WYF.js";import"./chunk-BEXYTIOL.js";import"./chunk-DKA7IP53.js";import{B as se,C as le,J as ce,L as de,v as oe,z as re}from"./chunk-YCLTQEU6.js";import{d as _e}from"./chunk-2LSZ2I43.js";import"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import{T as ee,U as te,ha as ne,ma as ie,qa as ae}from"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Ab as p,Bb as e,Cb as t,Db as I,Ec as _,Fc as C,Gc as E,Hb as Y,Ib as Z,Kb as B,Pc as L,Ra as r,Tb as S,U as X,Xb as h,Z as x,Zb as g,ca as y,da as b,ea as V,eb as H,fa as j,ic as G,jb as P,lc as o,mc as m,nc as u,oa as N,oc as $,qa as W,ub as D,vb as F,wb as q,yb as K,zb as Q}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";var U=class s{#e=x(z);#n=x(ge);#i=N([]);recentFiles=this.#i.asReadonly();#r=5;#s=N(null);etaData=this.#s.asReadonly();#a=null;#t=null;#o=null;recentFileEffect=W(()=>{let i=this.#e.statusData();i&&i.CurrentFilename&&i.CurrentFilesize!==void 0&&this.#l(i.CurrentFilename,i.CurrentFilesize)});#l(i,n){let a=new Date;this.#i.update(l=>l.length>0&&l[0].filename===i?l:[{filename:i,filesize:n,timestamp:a},...l].slice(0,this.#r))}activateView(){this.#a=new Date;let i=this.#e.statusData();i&&i.ProcessedFileCount!==void 0&&i.ProcessedFileSize!==void 0&&(this.#t={files:i.ProcessedFileCount,bytes:i.ProcessedFileSize}),this.#o=setInterval(()=>{this.#c()},1e3)}deactivateView(){this.#a=null,this.#t=null,this.#o&&(clearInterval(this.#o),this.#o=null)}#c(){if(!this.#a||!this.#t)return;let i=this.#e.statusData();if(!i)return;let n=new Date,a=(n.getTime()-this.#a.getTime())/1e3;if(a<5)return;let l=i.ProcessedFileCount||0,d=i.ProcessedFileSize||0,c=l-this.#t.files,k=d-this.#t.bytes,M=c/a,O=k/a,A=(i.TotalFileCount||0)-l,f=(i.TotalFileSize||0)-d,T=null,v=null;M>0&&(T=A/M),O>0&&(v=f/O);let R=null,w="bytes";if(T!==null&&v!==null){let Se=Math.max(T,v);R=new Date(n.getTime()+Se*1e3),w=T>v?"files":"bytes"}else T!==null?(R=new Date(n.getTime()+T*1e3),w="files"):v!==null&&(R=new Date(n.getTime()+v*1e3),w="bytes");this.#s.set({startTime:this.#a,filesProcessedAtStart:this.#t.files,bytesProcessedAtStart:this.#t.bytes,currentFilesPerSecond:M,currentBytesPerSecond:O,estimatedCompletion:R,metric:w})}static \u0275fac=function(n){return new(n||s)};static \u0275prov=X({token:s,factory:s.\u0275fac,providedIn:"root"})};function xe(s,i){if(s&1&&(e(0,"div",42)(1,"span",20),o(2,"Processing"),t(),e(3,"sh-list",43)(4,"div",44)(5,"sh-icon"),o(6,"file"),t(),e(7,"div",45)(8,"span",46),o(9),t(),e(10,"span",47),o(11),_(12,"bytes"),t()()()()()),s&2){let n,a,l,d=g(2);r(8),p("title",(n=d.statusData())==null?null:n.CurrentFilename),r(),u(" ",(a=d.statusData())==null?null:a.CurrentFilename," "),r(2),m(C(12,3,(l=d.statusData())==null?null:l.CurrentFilesize))}}function Me(s,i){if(s&1&&(e(0,"div",35)(1,"span",46),o(2),t(),e(3,"span",47),o(4),_(5,"bytes"),t()()),s&2){let n=i.$implicit;r(),p("title",n.filename),r(),m(n.filename),r(2),m(C(5,3,n.filesize))}}function Oe(s,i){s&1&&(e(0,"div",36),S(1,2),t())}function Te(s,i){if(s&1&&(e(0,"sh-list")(1,"div",48)(2,"span",20),o(3,"ETA"),t(),e(4,"span",21),o(5),_(6,"date"),e(7,"span",49),o(8),_(9,"relativeTime"),t()()(),e(10,"div",50)(11,"span",20),o(12,"Files/s"),t(),e(13,"span",21),o(14),_(15,"number"),t()(),e(16,"div",50)(17,"span",20),o(18,"Upload Speed"),t(),e(19,"span",21),o(20),_(21,"bytes"),t()()()),s&2){let n,a,l,d,c=g(2);r(5),u(" ",E(6,4,(n=c.etaData())==null?null:n.estimatedCompletion,"mediumTime")," "),r(3),u("(",C(9,7,(a=c.etaData())==null?null:a.estimatedCompletion),")"),r(6),m(E(15,9,(l=c.etaData())==null?null:l.currentFilesPerSecond,"1.1-1")),r(6),u("",C(21,12,(d=c.etaData())==null?null:d.currentBytesPerSecond),"/s")}}function ve(s,i){if(s&1&&(e(0,"div",53)(1,"div",54)(2,"span",55),o(3),t(),e(4,"span",56),o(5),_(6,"bytes"),t()(),I(7,"sh-progress-bar",57),t()),s&2){let n=i.$implicit;r(2),p("title",n.BackendPath),r(),m(n.BackendPath),r(2),u("",C(6,4,n.BackendSpeed),"/s"),r(2),p("value",(n.BackendFileProgress||0)/(n.BackendFileSize||1)*100)}}function he(s,i){if(s&1&&(e(0,"div",51)(1,"sh-list"),P(2,ve,8,6,"div",52),t()()),s&2){let n,a=g(2);r(2),p("ngForOf",(n=a.statusData())==null?null:n.ActiveTransfers)}}function Ee(s,i){if(s&1){let n=B();e(0,"sh-card")(1,"div",13)(2,"div",14)(3,"sh-icon",15),o(4,"clock"),t(),e(5,"h2"),o(6),t()()(),e(7,"div",26)(8,"div",27)(9,"span",28),o(10),_(11,"number"),t()(),I(12,"sh-progress-bar",29),e(13,"sh-list")(14,"div",30)(15,"span",20),o(16,"Files"),t(),e(17,"span",21),o(18),t()(),e(19,"div",30)(20,"span",20),o(21,"Size"),t(),e(22,"span",21),o(23),_(24,"bytes"),_(25,"bytes"),t()()()()(),e(26,"sh-card")(27,"div",13)(28,"div",14)(29,"sh-icon",15),o(30,"file"),t(),e(31,"h3"),o(32,"Activity"),t()()(),e(33,"div",31),P(34,xe,13,5,"div",32),e(35,"div",33)(36,"span",20),S(37,1),t(),e(38,"sh-list",34),K(39,Me,6,5,"div",35,q),D(41,Oe,2,0,"div",36),t()()()(),e(42,"sh-card")(43,"div",13)(44,"div",14)(45,"sh-icon",15),o(46,"gauge"),t(),e(47,"h3"),o(48,"Performance"),t()(),e(49,"div",37),o(50),_(51,"bytes"),t()(),e(52,"div",38),P(53,Te,22,14,"sh-list",25),e(54,"div",39)(55,"button",40),h("click",function(){y(n);let l=g();return b(l.toggleTransfers())}),o(56),t(),P(57,he,3,1,"div",41),t()()()}if(s&2){let n,a,l,d,c=g();r(6),m(c.statusText()),r(4),u("",E(11,13,c.progress(),"1.0-0"),"%"),r(2),p("value",c.progress()),r(6),$("",(n=c.statusData())==null?null:n.ProcessedFileCount," / ",(n=c.statusData())==null?null:n.TotalFileCount),r(5),$(" ",C(24,16,(a=c.statusData())==null?null:a.ProcessedFileSize)," / ",C(25,18,(a=c.statusData())==null?null:a.TotalFileSize)," "),r(11),p("ngIf",(l=c.statusData())==null?null:l.CurrentFilename),r(5),Q(c.recentFiles()),r(2),F(c.recentFiles().length===0?41:-1),r(9),u("",C(51,20,(d=c.statusData())==null?null:d.BackendSpeed),"/s"),r(3),p("ngIf",c.etaData()),r(3),u(" ",c.transfersExpanded()?"Hide Details":"Show Details"," "),r(),p("ngIf",c.transfersExpanded())}}function ye(s,i){if(s&1&&(e(0,"sh-card",75)(1,"div",13)(2,"div",14)(3,"sh-icon",15),o(4,"calendar"),t(),e(5,"h3"),S(6,7),t()()(),e(7,"div",76)(8,"div",77)(9,"span",78),o(10),t(),e(11,"div",79)(12,"span",80),o(13),_(14,"date"),t(),e(15,"span",81),o(16),_(17,"relativeTime"),t()()(),e(18,"sh-icon",82),o(19,"caret-right"),t()()()),s&2){let n,a=g(2);r(10),m((n=a.nextBackup().backup)==null?null:n.Name),r(3),m(E(14,3,a.nextBackup().time,"medium")),r(3),u("(",C(17,6,a.nextBackup().time),")")}}function be(s,i){s&1&&(e(0,"span",74),S(1,8),t())}function Ne(s,i){if(s&1){let n=B();e(0,"sh-card",58)(1,"div",59)(2,"div",60)(3,"div",61),V(),e(4,"svg",62),I(5,"circle",63),t(),j(),e(6,"sh-icon",64),S(7,3),t()()(),e(8,"div",65)(9,"h2"),S(10,4),t(),e(11,"p",66),S(12,5),t()(),e(13,"div",67)(14,"button",68),h("click",function(){y(n);let l=g();return b(l.pauseResume())}),e(15,"sh-icon"),o(16),t(),o(17),t()()()(),P(18,ye,20,8,"sh-card",69),e(19,"sh-card",70)(20,"div",71)(21,"span",20),S(22,6),t(),e(23,"div",72)(24,"span",73),o(25),t(),D(26,be,2,0,"span",74),t()()()}if(s&2){let n,a=g();r(14),p("variant",a.clientIsRunning()?"primary":"secondary"),r(2),m(a.clientIsRunning()?"pause":"play"),r(),u(" ",a.clientIsRunning()?"Pause Execution":"Resume Execution"," "),r(),p("ngIf",a.nextBackup()),r(6),G("running",a.clientIsRunning()),r(),m((n=a.serverState())==null?null:n.ProgramState),r(),F(a.clientIsRunning()?-1:26)}}function Ie(s,i){if(s&1&&(e(0,"div",35)(1,"span",46),o(2),t(),e(3,"span",47),o(4),_(5,"bytes"),t()()),s&2){let n=i.$implicit;r(),p("title",n.filename),r(),m(n.filename),r(2),m(C(5,3,n.filesize))}}function ke(s,i){if(s&1&&(e(0,"sh-card",83)(1,"div",13)(2,"div",14)(3,"sh-icon",15),o(4,"clock-counter-clockwise"),t(),e(5,"h3"),S(6,9),t()()(),e(7,"sh-list"),P(8,Ie,6,5,"div",84),t()()),s&2){let n=g();r(8),p("ngForOf",n.recentFiles())}}function Ae(s,i){if(s&1&&(e(0,"div",19)(1,"span",20),o(2,"Next Task:"),t(),e(3,"div",21)(4,"div"),o(5),t(),e(6,"div",49),o(7),_(8,"date"),_(9,"relativeTime"),t()()()),s&2){let n,a=g();r(5),m((n=a.nextBackup().backup)==null?null:n.Name),r(2),$(" ",E(8,3,a.nextBackup().time,"medium")," (",C(9,6,a.nextBackup().time),") ")}}function Re(s,i){if(s&1){let n=B();Y(0),e(1,"button",85),h("click",function(){y(n);let l=g();return b(l.stop())}),e(2,"sh-icon"),o(3,"stop"),t(),o(4," Stop "),t(),e(5,"button",85),h("click",function(){y(n);let l=g();return b(l.abort())}),e(6,"sh-icon"),o(7,"x-circle"),t(),o(8," Abort "),t(),Z()}}var J=class s{#e=x(z);#n=x(U);#i=x(_e);#r=x(re);statusData=this.#e.statusData;serverState=this.#e.serverState;recentFiles=this.#n.recentFiles;etaData=this.#n.etaData;transfersExpanded=N(!1);clientIsRunning=this.#e.clientIsRunning;statusText=L(()=>{let i=this.statusData()?.Phase;return i?pe[i]||i:""});progress=L(()=>{let i=this.statusData();return i?(i.OverallProgress||0)*100:0});nextBackup=L(()=>({backup:this.serverState()?.ProposedSchedule?.[0]?.backup,time:this.serverState()?.ProposedSchedule?.[0]?.Item2}));ngOnInit(){this.#n.activateView()}ngOnDestroy(){this.#n.deactivateView()}toggleTransfers(){this.transfersExpanded.update(i=>!i)}isTaskRunning(){return!!this.statusData()?.TaskID}taskStartTime(){return this.etaData()?.startTime}currentBackupId(){return this.statusData()?.BackupID}pauseResume(){if(this.clientIsRunning()){this.#r.open(Ce,{maxWidth:"550px",width:"100%"});return}this.#e.pauseResume().subscribe()}stop(){let i=this.statusData()?.TaskID;i&&this.#i.postApiV1TaskByTaskidStop({taskid:i}).subscribe()}abort(){let i=this.statusData()?.TaskID;i&&this.#i.postApiV1TaskByTaskidAbort({taskid:i}).subscribe()}static \u0275fac=function(n){return new(n||s)};static \u0275cmp=H({type:s,selectors:[["app-status"]],decls:29,vars:13,consts:()=>{let i;i=$localize`Live Logs`;let n;n=$localize`Recently Processed`;let a;a=$localize`No recent files`;let l;l=$localize`check-bold`;let d;d=$localize`System Ready`;let c;c=$localize`Waiting for the next scheduled backup task.`;let k;k=$localize`Server State`;let M;M=$localize`Next Scheduled Task`;let O;O=$localize`Backups are currently paused`;let A;return A=$localize`Recent Activity`,[i,n,a,l,d,c,k,M,O,A,[1,"status-page"],["class","activity-card",4,"ngIf"],[1,"logs-card"],[1,"card-header"],[1,"header-titl-group"],[1,"header-icon"],[1,"logs-content"],[3,"asSimpleList","polling","whenFilter","backupIdFilter"],[1,"server-status-section"],[1,"status-row"],[1,"label"],[1,"value"],["class","status-row",4,"ngIf"],[1,"actions"],["shButton","",3,"click"],[4,"ngIf"],[1,"progress-content"],[1,"percentage-display"],[1,"percentage-value"],[3,"value"],["item","",1,"stat-item"],[1,"files-content"],["class","current-file-section",4,"ngIf"],[1,"recent-files-section"],[1,"recent-files-list"],["item","",1,"file-item"],["item","",1,"empty-state"],[1,"aggregate-speed"],[1,"performance-content"],[1,"transfers-section"],["shButton","","size","small","variant","ghost",1,"toggle-btn",3,"click"],["class","transfer-details",4,"ngIf"],[1,"current-file-section"],[1,"current-file-list"],["item","",1,"file-item","current"],[1,"file-details"],[1,"filename",3,"title"],[1,"filesize"],["item","",1,"eta-item"],[1,"sub-text"],["item","",1,"metric-item"],[1,"transfer-details"],["class","transfer-item","item","",4,"ngFor","ngForOf"],["item","",1,"transfer-item"],[1,"transfer-header"],[1,"path",3,"title"],[1,"speed"],[1,"mini-progress",3,"value"],[1,"idle-hero-card"],[1,"idle-content"],[1,"status-visual"],[1,"complete-status"],[1,"border-svg"],["cx","50","cy","50","r","45",1,"border-circle"],[1,"status-icon"],[1,"status-info"],[1,"status-description"],[1,"idle-actions"],["shButton","",3,"click","variant"],["class","next-task-hero",4,"ngIf"],[1,"server-state-card"],[1,"state-content"],[1,"state-line"],[1,"status-badge"],[1,"warning-text"],[1,"next-task-hero"],[1,"next-task-content"],[1,"task-main"],[1,"task-name"],[1,"task-time-group"],[1,"task-time"],[1,"task-relative"],[1,"chevron"],[1,"activity-card"],["class","file-item","item","",4,"ngFor","ngForOf"],["shButton","","color","warn",3,"click"]]},template:function(n,a){if(n&1&&(e(0,"div",10),D(1,Ee,58,22)(2,Ne,27,8),P(3,ke,9,1,"sh-card",11),e(4,"sh-card",12)(5,"div",13)(6,"div",14)(7,"sh-icon",15),o(8,"list"),t(),e(9,"h3"),S(10,0),t()()(),e(11,"div",16),I(12,"app-logs-live",17),t()(),e(13,"sh-card")(14,"div",18)(15,"h3"),o(16,"Server Status"),t(),e(17,"div",19)(18,"span",20),o(19,"State:"),t(),e(20,"span",21),o(21),t()(),P(22,Ae,10,8,"div",22),e(23,"div",23)(24,"button",24),h("click",function(){return a.pauseResume()}),e(25,"sh-icon"),o(26),t(),o(27),t(),P(28,Re,9,0,"ng-container",25),t()()()()),n&2){let l,d;G("idle",!a.isTaskRunning()),r(),F(a.isTaskRunning()?1:2),r(2),p("ngIf",!a.isTaskRunning()&&a.recentFiles().length>0),r(9),p("asSimpleList",!0)("polling",a.isTaskRunning())("whenFilter",(l=a.taskStartTime())==null?null:l.getTime())("backupIdFilter",a.currentBackupId()),r(9),m((d=a.serverState())==null?null:d.ProgramState),r(),p("ngIf",a.nextBackup()),r(4),m(a.clientIsRunning()?"pause":"play_arrow"),r(),u(" ",a.clientIsRunning()?"Pause":"Resume"," "),r(),p("ngIf",a.isTaskRunning())}},dependencies:[ae,ee,te,le,de,se,oe,fe,ce,ie,ne,me,ue],styles:["[_nghost-%COMP%]{display:block;padding:24px;max-width:1400px;margin:0 auto}.status-page[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr;gap:24px}@media(min-width:768px){.status-page[_ngcontent-%COMP%]{grid-template-columns:repeat(2,1fr)}}@media(min-width:1200px){.status-page[_ngcontent-%COMP%]{grid-template-columns:repeat(3,1fr)}}@media(min-width:1200px){.status-page[_ngcontent-%COMP%] .logs-card[_ngcontent-%COMP%], .status-page.idle[_ngcontent-%COMP%] .idle-hero-card[_ngcontent-%COMP%]{grid-column:span 2}.status-page.idle[_ngcontent-%COMP%] .next-task-hero[_ngcontent-%COMP%], .status-page.idle[_ngcontent-%COMP%] .server-state-card[_ngcontent-%COMP%]{grid-column:3}.status-page.idle[_ngcontent-%COMP%] .activity-card[_ngcontent-%COMP%], .status-page.idle[_ngcontent-%COMP%] .logs-card[_ngcontent-%COMP%]{grid-column:1/-1}}sh-card[_ngcontent-%COMP%]{height:100%;display:flex;flex-direction:column;--sh-card-padding: 24px}.card-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;margin-bottom:20px}.card-header[_ngcontent-%COMP%] .header-titl-group[_ngcontent-%COMP%]{display:flex;align-items:center;gap:12px}.card-header[_ngcontent-%COMP%] .header-titl-group[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{color:var(--primary-color);font-size:24px}.card-header[_ngcontent-%COMP%] .header-titl-group[_ngcontent-%COMP%] h2[_ngcontent-%COMP%], .card-header[_ngcontent-%COMP%] .header-titl-group[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{margin:0;font-size:1.1rem;font-weight:600;color:var(--text-primary)}.progress-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:20px}.progress-content[_ngcontent-%COMP%] .percentage-display[_ngcontent-%COMP%]{text-align:center}.progress-content[_ngcontent-%COMP%] .percentage-display[_ngcontent-%COMP%] .percentage-value[_ngcontent-%COMP%]{font-size:3rem;font-weight:800;color:var(--primary-color);line-height:1}.progress-content[_ngcontent-%COMP%] sh-progress-bar[_ngcontent-%COMP%]{height:8px;border-radius:4px;--sh-progress-bar-track-color: var(--bg-secondary)}.progress-content[_ngcontent-%COMP%] .stat-item[_ngcontent-%COMP%]{display:flex;justify-content:space-between;width:100%}.progress-content[_ngcontent-%COMP%] .stat-item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{color:var(--text-secondary);font-size:.9rem}.progress-content[_ngcontent-%COMP%] .stat-item[_ngcontent-%COMP%] .value[_ngcontent-%COMP%]{font-weight:600}.files-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:16px}.files-content[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;color:var(--text-secondary);font-weight:600;margin-bottom:4px;display:block;padding-left:12px}.files-content[_ngcontent-%COMP%] .file-item[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:100%}.files-content[_ngcontent-%COMP%] .file-item.current[_ngcontent-%COMP%]{gap:12px;justify-content:flex-start}.files-content[_ngcontent-%COMP%] .file-item.current[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{color:var(--primary-color)}.files-content[_ngcontent-%COMP%] .file-item.current[_ngcontent-%COMP%] .file-details[_ngcontent-%COMP%]{display:flex;flex-direction:column;overflow:hidden}.files-content[_ngcontent-%COMP%] .file-item[_ngcontent-%COMP%] .filename[_ngcontent-%COMP%]{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-right:12px;font-size:.9rem;font-weight:500;flex:1}.files-content[_ngcontent-%COMP%] .file-item[_ngcontent-%COMP%] .filesize[_ngcontent-%COMP%]{color:var(--text-secondary);font-size:.85rem;font-variant-numeric:tabular-nums;white-space:nowrap}.files-content[_ngcontent-%COMP%] .empty-state[_ngcontent-%COMP%]{color:var(--text-secondary);font-style:italic;text-align:center;width:100%}.performance-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:16px}.performance-content[_ngcontent-%COMP%] .aggregate-speed[_ngcontent-%COMP%]{font-size:1.2rem;font-weight:700;color:var(--text-primary);font-variant-numeric:tabular-nums}.performance-content[_ngcontent-%COMP%] .eta-item[_ngcontent-%COMP%], .performance-content[_ngcontent-%COMP%] .metric-item[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:100%}.performance-content[_ngcontent-%COMP%] .eta-item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%], .performance-content[_ngcontent-%COMP%] .metric-item[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{color:var(--text-secondary);font-size:.9rem}.performance-content[_ngcontent-%COMP%] .eta-item[_ngcontent-%COMP%] .value[_ngcontent-%COMP%], .performance-content[_ngcontent-%COMP%] .metric-item[_ngcontent-%COMP%] .value[_ngcontent-%COMP%]{font-weight:600;font-variant-numeric:tabular-nums}.performance-content[_ngcontent-%COMP%] .eta-item[_ngcontent-%COMP%] .value[_ngcontent-%COMP%] .sub-text[_ngcontent-%COMP%], .performance-content[_ngcontent-%COMP%] .metric-item[_ngcontent-%COMP%] .value[_ngcontent-%COMP%] .sub-text[_ngcontent-%COMP%]{color:var(--text-secondary);font-weight:400;font-size:.85rem;margin-left:4px}.performance-content[_ngcontent-%COMP%] .transfers-section[_ngcontent-%COMP%] .toggle-btn[_ngcontent-%COMP%]{width:100%;margin-bottom:12px}.performance-content[_ngcontent-%COMP%] .transfers-section[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%]{display:flex;flex-direction:column;width:100%;gap:4px}.performance-content[_ngcontent-%COMP%] .transfers-section[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%] .transfer-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;font-size:.85rem}.performance-content[_ngcontent-%COMP%] .transfers-section[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%] .transfer-header[_ngcontent-%COMP%] .path[_ngcontent-%COMP%]{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-right:12px}.performance-content[_ngcontent-%COMP%] .transfers-section[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%] .transfer-header[_ngcontent-%COMP%] .speed[_ngcontent-%COMP%]{color:var(--text-secondary);font-variant-numeric:tabular-nums}.performance-content[_ngcontent-%COMP%] .transfers-section[_ngcontent-%COMP%] .transfer-item[_ngcontent-%COMP%] .mini-progress[_ngcontent-%COMP%]{height:4px}.logs-content[_ngcontent-%COMP%] app-logs-live[_ngcontent-%COMP%]{height:350px;display:block}.status-badge[_ngcontent-%COMP%]{padding:4px 12px;border-radius:12px;background:var(--bg-secondary);color:var(--text-secondary);font-size:.8rem;font-weight:500;text-transform:uppercase}.status-badge.running[_ngcontent-%COMP%]{background:rgba(var(--primary-rgb),.1);color:var(--primary-color)}.actions-grid[_ngcontent-%COMP%]{margin-top:auto;display:grid;grid-template-columns:repeat(auto-fit,minmax(120px,1fr));gap:12px}.actions-grid[_ngcontent-%COMP%] .action-btn[_ngcontent-%COMP%]{width:100%;justify-content:center}.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:32px 0;gap:32px}@media(min-width:768px){.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%]{flex-direction:row;text-align:left;justify-content:space-around;padding:48px 0}}.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%] .status-visual[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center}.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%] .status-info[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{font-size:2rem;font-weight:700;margin-bottom:8px;color:var(--text-primary)}.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%] .status-info[_ngcontent-%COMP%] .status-description[_ngcontent-%COMP%]{color:var(--text-secondary);font-size:1.1rem;max-width:300px}.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%] .idle-actions[_ngcontent-%COMP%]{display:flex;align-items:center}.idle-hero-card[_ngcontent-%COMP%] .idle-content[_ngcontent-%COMP%] .idle-actions[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{padding-left:32px;padding-right:32px}.complete-status[_ngcontent-%COMP%]{position:relative;width:120px;height:120px;display:flex;justify-content:center;align-items:center;color:var(--primary-color)}.complete-status[_ngcontent-%COMP%] .status-icon[_ngcontent-%COMP%]{font-size:48px;opacity:0;animation:_ngcontent-%COMP%_reveal-icon .2s linear forwards;animation-delay:1s}.border-svg[_ngcontent-%COMP%]{position:absolute;top:0;left:0;width:100%;height:100%}.border-circle[_ngcontent-%COMP%]{fill:none;stroke:var(--primary-color);stroke-width:5px;stroke-dasharray:282.74;stroke-dashoffset:282.74;animation:_ngcontent-%COMP%_draw-border 1.2s linear forwards}@keyframes _ngcontent-%COMP%_draw-border{to{stroke-dashoffset:0}}@keyframes _ngcontent-%COMP%_reveal-icon{to{opacity:1}}.next-task-hero[_ngcontent-%COMP%] .next-task-content[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;padding:12px 0}.next-task-hero[_ngcontent-%COMP%] .next-task-content[_ngcontent-%COMP%] .task-main[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:4px}.next-task-hero[_ngcontent-%COMP%] .next-task-content[_ngcontent-%COMP%] .task-main[_ngcontent-%COMP%] .task-name[_ngcontent-%COMP%]{font-size:1.2rem;font-weight:700;color:var(--primary-color)}.next-task-hero[_ngcontent-%COMP%] .next-task-content[_ngcontent-%COMP%] .task-main[_ngcontent-%COMP%] .task-time-group[_ngcontent-%COMP%]{display:flex;flex-direction:column;color:var(--text-secondary);font-size:.95rem}.next-task-hero[_ngcontent-%COMP%] .next-task-content[_ngcontent-%COMP%] .chevron[_ngcontent-%COMP%]{color:var(--text-secondary);opacity:.5}.server-state-card[_ngcontent-%COMP%] .state-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:12px}.server-state-card[_ngcontent-%COMP%] .state-content[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{font-size:.75rem;text-transform:uppercase;color:var(--text-secondary);font-weight:600}.server-state-card[_ngcontent-%COMP%] .state-content[_ngcontent-%COMP%] .state-line[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:8px}.server-state-card[_ngcontent-%COMP%] .state-content[_ngcontent-%COMP%] .state-line[_ngcontent-%COMP%] .warning-text[_ngcontent-%COMP%]{font-size:.85rem;color:var(--error-color);font-weight:500}"],changeDetection:0})};export{J as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as v}from"./chunk-
|
|
1
|
+
import{a as v}from"./chunk-GVXQIOKE.js";import"./chunk-W4HWOC3K.js";import"./chunk-JFUWTLM7.js";import"./chunk-CKVJ36E5.js";import{p as C}from"./chunk-TDEVA3XM.js";import"./chunk-ITA7DTN3.js";import"./chunk-Q72Y55NB.js";import"./chunk-NXF5BMPG.js";import"./chunk-XHUQYWAM.js";import{a as G}from"./chunk-YF6ULZXZ.js";import"./chunk-SLS3DCJP.js";import"./chunk-SUY5AQLW.js";import"./chunk-6Q6SSTBK.js";import"./chunk-I4XRVBRQ.js";import"./chunk-IUJGDYFS.js";import"./chunk-X64LSE6Y.js";import"./chunk-RFB5A3B7.js";import"./chunk-DWFQAX4H.js";import"./chunk-FKYRYVJD.js";import{b as h}from"./chunk-AYOFR344.js";import"./chunk-LTVI3WYF.js";import"./chunk-BEXYTIOL.js";import"./chunk-DKA7IP53.js";import{L as M,M as $,R as I}from"./chunk-YCLTQEU6.js";import{d as L}from"./chunk-2LSZ2I43.js";import{b as N,c as O,e as B,f as b}from"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Ab as d,Bb as s,Bc as p,C as f,Cb as u,Db as r,Ra as n,Rb as c,Sb as _,Z as l,Zb as A,eb as D,lc as P,nc as E,qa as R,ub as T,vb as g,yc as k}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";var y=(a,e)=>[a,e,"general"],U=(a,e)=>[a,e,"destination"],K=(a,e)=>[a,e,"source-data"],w=(a,e)=>[a,e,"schedule"],H=(a,e)=>[a,e,"options"];function J(a,e){if(a&1&&(s(0,"p"),P(1),u()),a&2){let t=A();n(),E("Editing: ",t.backupName())}}function X(a,e){a&1&&r(0,"sh-progress-bar",7)}function x(a,e){a&1&&(s(0,"section"),r(1,"router-outlet"),u())}var m=class a{#t=l(N);#e=l(C);#a=l(G);#i=l(L);isDraft=this.#e.isDraft;isNew=this.#e.isNew;backupId=this.#e.backupId;backupName=this.#e.backupName;finishedLoading=this.#e.finishedLoading;#o=h(this.#t.params);#n=h(this.#t.url);paramsChanged=R(()=>{let e=this.#o()?.id,t=!!this.#n()?.find(i=>i.path==="backup-draft");this.#e.backupId.set(e),e!=="new"?this.getBackup(e,t):this.getDefaults()});getDefaults(){this.#i.getApiV1Backupdefaults().pipe(f(1)).subscribe({next:e=>{let t=e.Backup;t.Settings=[...t.Settings],this.#e.mapGeneralToForm(t),this.#e.mapDestinationToForm(t),this.#e.mapSourceDataToForm(t),this.#e.mapScheduleToForm(e.Schedule),this.#e.mapOptionsToForms(t),this.#e.applicationOptions.set(e.ApplicationOptions),this.#e.backupDefaults.set(e),this.#e.finishedLoading.set(!0)}})}getBackup(e,t=!1){let i=o=>{this.#e.mapScheduleToForm(o.Schedule??null),o.Backup&&(this.#e.mapGeneralToForm(o.Backup),this.#e.mapDestinationToForm(o.Backup),this.#e.mapSourceDataToForm(o.Backup),this.#e.mapOptionsToForms(o.Backup),this.#e.storeMetadata(o.Backup,t)),this.#e.finishedLoading.set(!0)};if(t){this.isDraft.set(t);let o=this.#a.draftBackups().find(F=>F.id===e);if(!o){alert("Backup not found");return}i(o.data)}else this.#i.getApiV1BackupById({id:e}).subscribe({next:i})}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=D({type:a,selectors:[["app-backup"]],features:[k([C])],decls:21,vars:22,consts:()=>{let e;e=$localize`${"\uFFFD#6\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#6\uFFFD"}:CLOSE_TAG_SH_RADIO: General `;let t;t=$localize`${"\uFFFD#9\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SH_RADIO: Destination `;let i;i=$localize`${"\uFFFD#12\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SH_RADIO: Source Data `;let o;o=$localize`${"\uFFFD#15\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#15\uFFFD"}:CLOSE_TAG_SH_RADIO: Schedule `;let F;return F=$localize`${"\uFFFD#18\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#18\uFFFD"}:CLOSE_TAG_SH_RADIO: Options `,[e,t,i,o,F,[1,"primary"],["step","","routerLinkActive","active",3,"routerLink"],[1,"indeterminate","primary"]]},template:function(t,i){t&1&&(r(0,"app-status-bar"),s(1,"header"),T(2,J,2,1,"p"),s(3,"sh-stepper",5)(4,"div",6),c(5,0),r(6,"sh-radio"),_(),u(),s(7,"div",6),c(8,1),r(9,"sh-radio"),_(),u(),s(10,"div",6),c(11,2),r(12,"sh-radio"),_(),u(),s(13,"div",6),c(14,3),r(15,"sh-radio"),_(),u(),s(16,"div",6),c(17,4),r(18,"sh-radio"),_(),u()()(),T(19,X,1,0,"sh-progress-bar",7)(20,x,2,0,"section")),t&2&&(n(2),g(i.isNew()?-1:2),n(2),d("routerLink",p(7,y,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),d("routerLink",p(10,U,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),d("routerLink",p(13,K,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),d("routerLink",p(16,w,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),d("routerLink",p(19,H,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),g(i.finishedLoading()?20:19))},dependencies:[O,B,b,v,$,I,M],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;height:100%}header[_ngcontent-%COMP%]{padding:1rem 1.5rem;border-bottom:1px solid var(--base-4)}header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin-bottom:.5rem}header[_ngcontent-%COMP%] sh-stepper[_ngcontent-%COMP%]{width:100%}section[_ngcontent-%COMP%]{width:100%;display:flex;justify-content:center;flex:1 0;overflow-x:hidden;overflow-y:auto;-webkit-overflow-scrolling:auto}"],changeDetection:0})};export{m as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as p}from"./chunk-X64LSE6Y.js";import{a as h}from"./chunk-RFB5A3B7.js";import{a as d}from"./chunk-
|
|
1
|
+
import{a as p}from"./chunk-X64LSE6Y.js";import{a as h}from"./chunk-RFB5A3B7.js";import{a as d}from"./chunk-FKYRYVJD.js";import{a as f}from"./chunk-BEXYTIOL.js";import{z as u}from"./chunk-YCLTQEU6.js";import{d as m}from"./chunk-2LSZ2I43.js";import{Pc as g,U as a,Z as s,oa as o,qa as c}from"./chunk-ERITO7WM.js";var R=class n{#s=s(p);#o=s(u);#e=s(m);#r=s(f);#n=s(d);repeatRegisterTimer=null;state=o("unknown");claimUrl=o(null);registerUrl=o("");customRegisterUrl=o("");status=g(()=>{let e=this.state();return e==="connecting"?$localize`Console connection is enabled but not connected`:e==="connected"?$localize`Connected to console`:e==="registering"?$localize`Registering machine...`:e==="registeringfaulted"?$localize`Registration failed`:e==="registered"?$localize`Registered, waiting for accept`:e==="disabled"?$localize`Console connection is configured but not enabled`:e==="unknown"?$localize`...loading...`:$localize`Console connection is not set up`});sysInfoEffect=c(()=>{let e=this.#r.systemInfo();e&&this.registerUrl.set(e.RemoteControlRegistrationUrl??"")});#t(e){e.RegistrationUrl&&this.claimUrl.set(e.RegistrationUrl),e.IsConnected?this.state.set("connected"):e.IsEnabled?this.state.set("connecting"):e.CanEnable?this.state.set("disabled"):e.IsRegisteringFaulted?this.state.set("registeringfaulted"):e.IsRegistering?e.RegistrationUrl!=null&&e.RegistrationUrl.trim().length>0?this.state.set("registered"):this.state.set("registering"):this.state.set("inactive");let i=this.state();this.repeatRegisterTimer!==null&&(clearTimeout(this.repeatRegisterTimer),this.repeatRegisterTimer=null),i==="registering"&&(this.repeatRegisterTimer=setTimeout(()=>{this.#e.postApiV1RemotecontrolRegisterWait().subscribe({next:t=>this.#t(t),error:t=>this.#i(t)})},5e3)),(i==="connecting"||i==="registered")&&(this.repeatRegisterTimer=setTimeout(()=>{this.#e.getApiV1RemotecontrolStatus().subscribe({next:t=>this.#t(t),error:t=>this.#i(t)})},5e3)),e.IsRegistering&&e.CanEnable&&this.#e.deleteApiV1RemotecontrolRegister().subscribe({next:t=>this.#t(t)})}#i(e){this.#e.getApiV1RemotecontrolStatus().subscribe({next:i=>{this.#t(i)}})}refreshRemoteControlStatus(){this.#e.getApiV1RemotecontrolStatus().subscribe({next:e=>this.#t(e),error:e=>this.#i(e)})}beginRemoteRegistration(e=!1){this.state.set("registering"),this.#e.postApiV1RemotecontrolRegister({requestBody:{RegistrationUrl:e?this.customRegisterUrl():this.registerUrl()}}).subscribe({next:i=>this.#t(i),error:i=>this.#i(i)})}cancelRemoteRegistration(){this.#e.deleteApiV1RemotecontrolRegister().subscribe({next:e=>this.#t(e),error:e=>this.#i(e)})}enableRemoteControl(){this.#e.postApiV1RemotecontrolEnable().subscribe({next:e=>this.#t(e),error:e=>this.#i(e)})}disableRemoteControl(){this.#e.postApiV1RemotecontrolDisable().subscribe({next:e=>this.#t(e),error:e=>this.#i(e)})}deleteRemoteControl(){let e=this;this.#o.open(h,{data:{title:$localize`Confirm delete`,message:$localize`Are you sure you want to delete the console registration?`,confirmText:$localize`Delete registration`,cancelText:$localize`Cancel`},closed:i=>{i&&e.#e.deleteApiV1RemotecontrolRegistration().subscribe({next:t=>e.#t(t),error:t=>e.#i(t)})}})}openConsole(e="/app/machines",i){let t=this.#n.serverSettings(),b=this.#r.systemInfo(),r="https://app.duplicati.com",l=b?.RemoteControlDashboardUrl??"";if(l.length>0&&(r=l),t&&t["remote-control-dashboard-url"]&&(r=t["remote-control-dashboard-url"]),r=new URL(r).origin+e,i){let S=new URLSearchParams(i);r+=`?${S.toString()}`}this.#s.open(r,"_blank")}static \u0275fac=function(i){return new(i||n)};static \u0275prov=a({token:n,factory:n.\u0275fac,providedIn:"root"})};export{R as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as c}from"./chunk-X64LSE6Y.js";import{a as l}from"./chunk-
|
|
1
|
+
import{a as c}from"./chunk-X64LSE6Y.js";import{a as l}from"./chunk-DWFQAX4H.js";import{xa as r}from"./chunk-OQ6BKP5N.js";import{Pc as n,U as o,Z as e,ha as a,oa as t,qa as s,ya as d}from"./chunk-ERITO7WM.js";var m=class i{#i=e(c);#t=e(a);#o=e(d);#e=l("darkTheme",null,!0);#s=t(this.#i.innerWidth);isMobile=n(()=>this.#s()<1024);sidenavType=t(this.isMobile()?"overlay":"");isNavOpen=t(!1);isDarkMode=this.#e.asReadonly();darkModeEffect=s(()=>{this.#e()?(this.#t.documentElement.classList.add("dark"),this.#t.documentElement.classList.remove("light")):(this.#t.documentElement.classList.remove("dark"),this.#t.documentElement.classList.add("light"))});isMobileEffect=s(()=>{this.isNavOpen.set(!this.isMobile()),this.sidenavType.set(this.isMobile()?"overlay":"")});constructor(){r(this.#o)&&this.#i?.addEventListener("resize",()=>{this.#s.set(this.#i.innerWidth)})}toggleNav(){this.isNavOpen.set(!this.isNavOpen())}toggleBodyClass(){this.#e.set(!this.isDarkMode())}setDarkMode(){this.#e.set(!0)}setLightMode(){this.#e.set(!1)}static \u0275fac=function(h){return new(h||i)};static \u0275prov=o({token:i,factory:i.\u0275fac,providedIn:"root"})};export{m as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as y}from"./chunk-AYOFR344.js";import{b as w}from"./chunk-
|
|
1
|
+
import{b as y}from"./chunk-AYOFR344.js";import{b as w}from"./chunk-LTVI3WYF.js";import{a as b}from"./chunk-BEXYTIOL.js";import"./chunk-DKA7IP53.js";import{B as U,L as $,v as k}from"./chunk-YCLTQEU6.js";import{d as x}from"./chunk-2LSZ2I43.js";import"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Ab as L,Bb as a,Cb as r,Db as d,E as g,Kb as E,Oa as O,Pc as I,Ra as l,Rb as M,Sb as R,Tb as T,Ub as f,Vb as F,Xb as N,Z as p,Zb as c,ca as m,da as C,eb as P,ic as v,lc as u,mc as D,oa as S,p as G,ub as s,vb as _}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";function V(n,o){n&1&&d(0,"sh-progress-bar",3)}function B(n,o){if(n&1&&(a(0,"a",7),M(1,2),d(2,"sh-icon"),R(),r()),n&2){let e,t,i=c(2);L("href",(e=i.serverState())==null?null:e.UpdateDownloadLink,O),l(2),f((t=i.serverState())==null?null:t.UpdatedVersion),F(1)}}function J(n,o){if(n&1){let e=E();a(0,"button",6),N("click",function(){m(e);let i=c();return C(i.checkForUpdates())}),u(1,"Check for updates"),r(),s(2,B,3,2,"a",7)}if(n&2){let e,t=c();v("loading",t.checkingForUpdates()),l(2),_((e=t.serverState())!=null&&e.UpdateDownloadLink?2:-1)}}function X(n,o){if(n&1){let e=E();a(0,"button",6),N("click",function(){m(e);let i=c();return C(i.checkForUpdates())}),u(1,"Checking for updates \u2026"),r()}}function z(n,o){n&1&&d(0,"sh-progress-bar",3)}var h=class n{#e=p(x);#t=p(w);#n=p(b);isLoading=S(!0);checkingForUpdates=S(!1);serverState=this.#t.serverState;duplicatiVersion=I(()=>this.#n.systemInfo()?.ServerVersionName??"Unknown");generalInfo=y(this.#e.getApiV1Acknowledgements().pipe(G(o=>o.Acknowledgements),g(()=>this.isLoading.set(!1))));checkForUpdates(){this.checkingForUpdates.set(!0),this.#e.postApiV1UpdatesCheck().pipe(g(()=>this.checkingForUpdates.set(!1))).subscribe()}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=P({type:n,selectors:[["app-general"]],decls:12,vars:5,consts:()=>{let o;o=$localize`General`;let e;e=$localize`You're running Duplicati with - ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let t;return t=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:download${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Download update - ${"\uFFFD0\uFFFD"}:INTERPOLATION: `,[o,e,t,[1,"indeterminate","primary"],[1,"actions"],["shButton",""],["shButton","",3,"click"],["shButton","","target","_blank",1,"primary","raised",3,"href"]]},template:function(e,t){if(e&1&&(s(0,V,1,0,"sh-progress-bar",3),a(1,"section")(2,"h3"),T(3,0),r(),a(4,"p"),T(5,1),r(),a(6,"div",4),s(7,J,3,3)(8,X,2,0,"button",5),s(9,z,1,0,"sh-progress-bar",3),r(),a(10,"div"),u(11),r()()),e&2){let i,A;_(t.isLoading()?0:-1),l(5),f(t.duplicatiVersion()),F(5),l(2),_(((i=t.serverState())==null?null:i.UpdaterState)==="Waiting"?7:((i=t.serverState())==null?null:i.UpdaterState)==="Checking"?8:-1),l(2),_(((A=t.serverState())==null?null:A.UpdaterState)==="Downloading"?9:-1),l(2),D(t.generalInfo())}},dependencies:[$,U,k],styles:["[_nghost-%COMP%]{display:block;position:relative;padding:0 2.5rem}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0 0 1.25rem}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}section[_ngcontent-%COMP%] div[_ngcontent-%COMP%]{white-space:pre-wrap}sh-progress-bar[_ngcontent-%COMP%]{position:absolute;top:0;left:0;right:0}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}"],changeDetection:0})};export{h as default};
|