@duplicati/ngclient 0.0.235 → 0.0.236
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-xD8qjoz4.js → chunk-0pQRcAhF.js} +1 -1
- package/{chunk-BEUeHgR9.js → chunk-1DRz_1dv.js} +1 -1
- package/{chunk-C185qUb-.js → chunk-2QKZNH3T.js} +1 -1
- package/{chunk-DWCofCiP.js → chunk-3iAIXnG6.js} +9 -9
- package/{chunk-fDWfSg6Y.js → chunk-5q0UK__c.js} +1 -1
- package/{chunk-6-sszNfh.js → chunk-644SEuYO.js} +1 -1
- package/{chunk-B_I_9Y7k.js → chunk-6oGy_iFC.js} +1 -1
- package/{chunk-CFgDqLU0.js → chunk-8A93BNds.js} +1 -1
- package/{chunk-D6y9RCQD.js → chunk-9Pc-waxi.js} +1 -1
- package/{chunk-iU19kwHx.js → chunk-B20GDhu-.js} +1 -1
- package/{chunk-C1py21yb.js → chunk-B5S2d_Pm.js} +1 -1
- package/{chunk-CsVpmA6t.js → chunk-BFsdrFDX.js} +1 -1
- package/{chunk-CSrYlKTK.js → chunk-BG8y51P2.js} +1 -1
- package/{chunk-BjqgOGb9.js → chunk-BIZHZ66x.js} +1 -1
- package/{chunk-7T5O8Syb.js → chunk-BM5sEnUl.js} +1 -1
- package/{chunk-DB0aGcRM.js → chunk-BO1Nqy2x.js} +1 -1
- package/{chunk-D04TnMUn.js → chunk-BSB0qCYy.js} +1 -1
- package/{chunk-DkVHfoYw.js → chunk-BSCOyYHH.js} +1 -1
- package/{chunk-NiMN4Rl6.js → chunk-BWDCVcaP.js} +1 -1
- package/{chunk-Btvi2S15.js → chunk-BZPh4AYw.js} +1 -1
- package/chunk-Bc_wPl6H.js +1 -0
- package/{chunk-Dbq-qyNL.js → chunk-Bdg6GNH8.js} +1 -1
- package/{chunk-DBkkb6OR.js → chunk-Be4WXTyA.js} +1 -1
- package/{chunk-iGzJokt-.js → chunk-Bfg1Kjif.js} +1 -1
- package/{chunk-CGnjVnmu.js → chunk-BmOgPfpY.js} +1 -1
- package/{chunk-CxbeRJcJ.js → chunk-BpG_gjhd.js} +1 -1
- package/{chunk-CdzKkYEw.js → chunk-BszFCrvn.js} +1 -1
- package/{chunk-D5V6OY_2.js → chunk-Bx7WLGmZ.js} +1 -1
- package/{chunk-DneBfCBh.js → chunk-BxBZMjtQ.js} +1 -1
- package/{chunk-Cj_yOpND.js → chunk-BxLcE6zQ.js} +1 -1
- package/{chunk-29_4gGIi.js → chunk-Bz49u_nH.js} +1 -1
- package/{chunk-DA7rrIf8.js → chunk-BzRnxKOJ.js} +1 -1
- package/{chunk-D6IQFx6m.js → chunk-C0w3mWOI.js} +1 -1
- package/{chunk-BWvawawS.js → chunk-C1PIQTOq.js} +1 -1
- package/{chunk-BGuvkLC9.js → chunk-C8Zr0vl3.js} +1 -1
- package/{chunk-BDJqKfxm.js → chunk-C9fglVxt.js} +1 -1
- package/{chunk-B891gwjc.js → chunk-CBaqwuDY.js} +1 -1
- package/{chunk-xI8Kkqgy.js → chunk-CC4z1keD.js} +1 -1
- package/{chunk-Dv_fBX0w.js → chunk-CH0tv6BB.js} +1 -1
- package/{chunk-_OzpLe0L.js → chunk-CMLjueVV.js} +1 -1
- package/{chunk-C1-31fA7.js → chunk-CNwmuSlJ.js} +1 -1
- package/{chunk-DFLxy15J.js → chunk-COhlvPYj.js} +1 -1
- package/{chunk-D38QrkIM.js → chunk-CRhQXQUC.js} +1 -1
- package/{chunk-DSeMtMg3.js → chunk-CSPT2xlQ.js} +1 -1
- package/{chunk-D7UddV5F.js → chunk-CUlaXyK0.js} +1 -1
- package/{chunk-CnZx831x.js → chunk-CUo9Jt8-.js} +1 -1
- package/chunk-CWCU9i20.js +1 -0
- package/{chunk-CQVPqpMp.js → chunk-CYA8bL3v.js} +1 -1
- package/{chunk-3YzyUT-a.js → chunk-CZu3210D.js} +1 -1
- package/{chunk-DuRr4rDS.js → chunk-CaQaYVo7.js} +1 -1
- package/{chunk-gId840Er.js → chunk-CgrVW_eL.js} +1 -1
- package/{chunk-DYV1Pbu1.js → chunk-Ci645E9t.js} +1 -1
- package/{chunk-DKRWta24.js → chunk-CpY-WOcD.js} +2 -2
- package/{chunk-C4Uv1C-T.js → chunk-CqNJ2t71.js} +1 -1
- package/chunk-D0owcdvy.js +1 -0
- package/{chunk-C0KXp4hd.js → chunk-D39Om4Mk.js} +1 -1
- package/{chunk-ClFp7JLZ.js → chunk-D72BQ7G7.js} +1 -1
- package/{chunk-C0XQD9NK.js → chunk-DCP61JTN.js} +1 -1
- package/{chunk-CKUlUN3q.js → chunk-DF2Ac802.js} +1 -1
- package/{chunk-m8vMm7S6.js → chunk-DLYD6dRM.js} +1 -1
- package/{chunk-Cm7JSdTO.js → chunk-DM-zhIVI.js} +1 -1
- package/{chunk-D2P9ER0I.js → chunk-DOUmqK2E.js} +1 -1
- package/{chunk-B61kkU_h.js → chunk-DQ3vKQCE.js} +1 -1
- package/{chunk-CzoH_Agx.js → chunk-DR-utttZ.js} +1 -1
- package/{chunk-ayE11Iz-.js → chunk-DWyjU7VC.js} +1 -1
- package/{chunk-Bgd5lu61.js → chunk-DgUP0uNQ.js} +1 -1
- package/{chunk-BEzhTDp8.js → chunk-Dgq3OqWW.js} +1 -1
- package/{chunk-IqMUABbN.js → chunk-Djpe9Lo0.js} +1 -1
- package/{chunk-OQ_HQ9EL.js → chunk-DkT-0-DS.js} +1 -1
- package/{chunk-D9jPw9Ov.js → chunk-Dn7TWCfq.js} +1 -1
- package/{chunk-Css7wqTG.js → chunk-DxIS2uYj.js} +1 -1
- package/{chunk-DXLQftDm.js → chunk-DyDoCZiX.js} +1 -1
- package/chunk-DzP0W6ua.js +1 -0
- package/{chunk-DmCJ7w-M.js → chunk-Ied7KwvV.js} +1 -1
- package/{chunk-BJOhC2d8.js → chunk-Mj9aFt3b.js} +1 -1
- package/{chunk-DaXXLSfy.js → chunk-OEmUbdHQ.js} +1 -1
- package/{chunk-zOY5leQB.js → chunk-OpdQrdKp.js} +1 -1
- package/{chunk-CLlZiOaO.js → chunk-VrjhL6gl.js} +1 -1
- package/{chunk-CzsiJ0k-.js → chunk-Z-8b6Hyr.js} +1 -1
- package/{chunk-W1dL7dqQ.js → chunk-bJwp1ogZ.js} +2 -2
- package/{chunk-Kq2ZFJSk.js → chunk-hTxREuXu.js} +1 -1
- package/{chunk-BWSg9cLt.js → chunk-mVyxhVwu.js} +1 -1
- package/{chunk-BOKNwzSl.js → chunk-oBjabFaf.js} +1 -1
- package/{chunk-Bq_vr6Q3.js → chunk-qUlwoHQn.js} +1 -1
- package/{chunk-Brfc2m61.js → chunk-vtWJkNZ_.js} +1 -1
- package/{chunk-DHkdQ4u3.js → chunk-zcgLq6FT.js} +1 -1
- package/index.html +1 -1
- package/{main-2ZYVV4C4.js → main-X6MUEPX4.js} +2 -2
- package/package.json +1 -1
- package/chunk-BSCc2xDv.js +0 -1
- package/chunk-D4g_OF7M.js +0 -1
- package/chunk-DE8p9-HP.js +0 -1
- package/chunk-NAAMYA7J.js +0 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {w}from'./chunk-DKRWta24.js';import'./chunk-CSrYlKTK.js';import'./chunk-iU19kwHx.js';import {u as un,_ as _n,C as Ct,a as mn,K as Ke}from'./chunk-DWCofCiP.js';import'./chunk-6-sszNfh.js';import'./chunk-Kq2ZFJSk.js';import'./chunk-zOY5leQB.js';import'./chunk-29_4gGIi.js';import'./chunk-BEUeHgR9.js';import'./chunk-CGnjVnmu.js';import'./chunk-BJOhC2d8.js';import {G,A}from'./chunk-fDWfSg6Y.js';import {v as ve$1}from'./chunk-DuRr4rDS.js';import'./chunk-C1py21yb.js';import'./chunk-D38QrkIM.js';import'./chunk-3YzyUT-a.js';import'./chunk-CKUlUN3q.js';import {T,e as ee,ax as W,a6 as be,by as ve,B as w1,G as Ge,N as Nt,au as h,g as gw,v,a as N,a0 as de,u as ue,i as ET,al as dm,Z as Zi,w as Hg,o as oC,W as Wl,l as lT,n as lm,P as Pd,p as qC,L as Ld,F as Fg,d as Ig,j as jg,am as GC,b as bE,c as uT,y as cm,z as vg,s as sC,aF as JC,O as qg,R as hC,h as aC,H as HC,aR as zl,aS as Ql,ap as zC,t as bD,a3 as XC,M as MD}from'./main-2ZYVV4C4.js';import'./chunk-CFgDqLU0.js';import'./chunk-BGuvkLC9.js';import {F as Fe}from'./chunk-DBkkb6OR.js';import {B as Bn,T as Tn,Z as Ze,R as Rn,P as Pn,J as Jt,a as Zt}from'./chunk-iGzJokt-.js';import'./chunk-DneBfCBh.js';import'./chunk-Bq_vr6Q3.js';import'./chunk-D9jPw9Ov.js';import'./chunk-CnZx831x.js';import'./chunk-Cm7JSdTO.js';var Oe=["formRef"],Re=["testUrl"],Ne=()=>({maxWidth:"700px",width:"100%"});function De(o,i){if(o&1){let e=ET();Zi(0,"button",24),Hg("click",function(){Pd(e);let t=aC();return Ld(t.openTargetUrlDialog())}),Fg(1,5),Ig(2,"sh-icon"),jg(),Wl();}}function Ie(o,i){if(o&1){let e=ET();Zi(0,"button",24),Hg("click",function(){Pd(e);let t=aC(2);return Ld(t.copyTargetUrl())}),Fg(1,7),Ig(2,"sh-icon"),jg(),Wl();}}function fe(o,i){if(o&1){let e=ET();Zi(0,"sh-menu")(1,"button",15)(2,"sh-icon"),HC(3,"dots-three-vertical"),Wl()(),zl(4,25),Zi(5,"button",24),Hg("click",function(){Pd(e);let t=aC();return Ld(t.openTargetUrlDialog())}),Fg(6,6),Ig(7,"sh-icon"),jg(),Wl(),lT(8,Ie,3,0,"button",15),Ql(),Wl();}if(o&2){aC();let e=zC(0);bE(8),uT(e?8:-1);}}function he(o,i){if(o&1){let e=ET();Zi(0,"app-destination-list-item",17)(1,"button",20),Hg("click",function(){Pd(e);let t=aC();return Ld(t.removeDestination())}),oC(2,8),Wl()();}if(o&2){aC();let e=zC(12);vg("destination",e);}}function ye(o,i){if(o&1){let e=ET();Zi(0,"app-destination-list",26),Hg("setDestination",function(t){Pd(e);let s=aC();return Ld(s.setDestination(t))}),Wl();}}function Me(o,i){if(o&1){let e=ET();Zi(0,"app-single-destination",27),lm("targetUrlChange",function(t){Pd(e);let s=aC();return qC(s.targetUrlModel,t)||(s.targetUrlModel=t),Ld(t)}),Wl();}if(o&2){let e=aC();cm("targetUrl",e.targetUrlModel);}}function Pe(o,i){o&1&&(Fg(0,4,1),Ig(1,"sh-icon",22),jg());}function Ae(o,i){o&1&&(Fg(0,4,2),Ig(1,"sh-icon"),jg());}function Le(o,i){if(o&1){let e=ET();Zi(0,"sh-dialog",28),lm("isOpenChange",function(t){Pd(e);let s=aC();return qC(s.targetUrlDialogOpen,t)||(s.targetUrlDialogOpen=t),Ld(t)}),Zi(1,"header",29)(2,"div",30)(3,"h2"),oC(4,9),Wl(),Zi(5,"sh-alert",31),oC(6,10),Wl()()(),Zi(7,"div",32)(8,"sh-form-field")(9,"textarea",33),lm("ngModelChange",function(t){Pd(e);let s=aC();return qC(s.targetUrlCtrl,t)||(s.targetUrlCtrl=t),Ld(t)}),Wl(),bD(),Wl()(),Zi(10,"footer",34)(11,"button",20),Hg("click",function(){Pd(e);let t=aC();return Ld(t.closeTargetUrlDialog(false))}),HC(12,"Cancel"),Wl(),Zi(13,"button",35),Hg("click",function(){Pd(e);let t=aC();return Ld(t.closeTargetUrlDialog(true))}),Fg(14,11),Ig(15,"sh-icon"),jg(),Wl()()();}if(o&2){let e=aC();cm("isOpen",e.targetUrlDialogOpen),vg("options",XC(3,Ne)),bE(9),cm("ngModel",e.targetUrlCtrl),MD();}}var x=class o{#i=T(ee);#o=T(W);#n=T(be);injector=T(ve);#e=T(w);formRef=w1.required("formRef");testUrlComponent=w1.required("testUrl");testSignal=this.#e.destinationTestSignal;targetUrlModel=this.#e.destinationTargetUrl;targetUrlCtrl=Ge(null);targetUrlInitial=Ge(null);targetUrlDialogOpen=Ge(false);toggleNewDestination=Ge(true);selectedDestinationType=Nt(()=>{let i=this.#e.destinationTargetUrl();return i?G(i):null});selectedDestinationTypeOption=Nt(()=>{let i=this.selectedDestinationType();return i?{key:i.customKey??i.key,customKey:i.customKey??null,displayName:i.displayName,description:i.description,sourceDescription:i.sourceDescription??null,icon:i.icon}:null});copyTargetUrl(){navigator.clipboard.writeText(this.#e.destinationTargetUrl()??"");}openTargetUrlDialog(){let i=this.#e.destinationTargetUrl();this.targetUrlCtrl.set(i),this.targetUrlInitial.set(i),this.targetUrlDialogOpen.set(true);}closeTargetUrlDialog(i=false){this.targetUrlDialogOpen.set(false);let e=this.targetUrlCtrl(),n=this.targetUrlInitial();!i||e===n||!e||this.#e.updateTargetUrl(e);}setDestination(i){let e=A(i??"");if(e){if(e.mapper.default){let n=e.mapper.default("");this.#e.updateTargetUrl(n);return}this.#e.updateTargetUrl(`${i}://`);}}removeDestination(){this.#e.updateTargetUrl(null);}goBack(){this.#i.navigate(["general"],{relativeTo:this.#o.parent});}next(){let i=this.testSignal();if(i===null){this.#n.open(h,{data:{title:$localize`Test destination`,message:$localize`You have not tested the destination yet. Do you want to test it now?`,confirmText:$localize`Test now`,cancelText:$localize`Skip test and continue`},closed:n=>{n?this.testUrlComponent()?.testDestination(false)?.then(t=>{t.action==="success"&&t.containsBackup?this.#t():this.#n.open(h,{data:{title:$localize`Test did not succeed`,message:t.errorMessage??$localize`Failed to test the destination.`,confirmText:$localize`OK`,cancelText:void 0}});}):this.#t();}});return}let e=typeof i=="string"?null:i;if(e?.action!=="success"||!e.containsBackup){this.#n.open(h,{data:{title:$localize`Test destination`,message:$localize`The destination has not been tested successfully. Are you sure you want to continue?`,confirmText:$localize`Edit destination`,cancelText:$localize`Yes, continue`},closed:n=>{n||this.#t();}});return}this.#t();}#t(){this.#i.navigate(["encryption"],{relativeTo:this.#o.parent});}static \u0275fac=function(e){return new(e||o)};static \u0275cmp=gw({type:o,selectors:[["app-restore-destination"]],viewQuery:function(e,n){e&1&&qg(n.formRef,Oe,5)(n.testUrlComponent,Re,5),e&2&&hC(2);},features:[JC([Ke])],decls:25,vars:18,consts:()=>{let i;i=$localize`Backup destination`;let e;e=$localize`${"\uFFFD#19\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#19\uFFFD"}:CLOSE_TAG_SH_ICON: Go back `;let n;n=$localize`${"\uFFFD*22:1\uFFFD"}:START_BLOCK_IF:${"\uFFFD#1:1\uFFFD"}:START_TAG_SH_ICON:spinner${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*22:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*23:2\uFFFD"}:START_BLOCK_ELSE:${"\uFFFD#1:2\uFFFD"}:START_TAG_SH_ICON_1:arrow-right${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*23:2\uFFFD"}:CLOSE_BLOCK_ELSE: Continue `,n=sC(n);let t;t=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:link${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Set target URL `;let s;s=$localize`${"\uFFFD#7\uFFFD"}:START_TAG_SH_ICON:link${"\uFFFD/#7\uFFFD"}:CLOSE_TAG_SH_ICON: Edit target URL `;let g;g=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:copy${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Copy URL to clipboard `;let U;U=$localize`Change`;let b;b=$localize`Edit target URL`;let G;G=$localize`Be careful, this will overwrite everything you have in your destination.`;let k;return k=$localize` Override target URL ${"\uFFFD#15\uFFFD"}:START_TAG_SH_ICON:swap${"\uFFFD/#15\uFFFD"}:CLOSE_TAG_SH_ICON:`,[["formRef",""],["testUrl",""],i,e,n,t,s,g,U,b,G,k,[3,"submit"],[1,"title-30"],[1,"actions"],["shButton","","type","button",1,"small"],[3,"targetUrlChange","testSignalChange","targetUrl","testSignal","backupId","sourcePrefix","suppressErrorDialogs","askToCreate","testExpectation","readOnlyTest","moduleType"],[1,"current-destination",3,"destination"],[3,"targetUrl"],[1,"form-actions"],["shButton","","type","button",3,"click"],["shButton","","type","submit",1,"raised","primary",3,"disabled"],[1,"loader"],[3,"isOpen","options"],["shButton","","type","button",1,"small",3,"click"],["menu",""],[3,"setDestination"],[3,"targetUrlChange","targetUrl"],[3,"isOpenChange","isOpen","options"],["header",""],[1,"target-dialog-header"],[1,"warn"],["content",""],["id","targetUrl","autocomplete","off",3,"ngModelChange","ngModel"],["footer",""],["shButton","","type","submit",1,"raised","primary",3,"click"]]},template:function(e,n){if(e&1){let t=ET();dm(0),Zi(1,"form",12,0),Hg("submit",function(){return n.next()}),Zi(3,"header")(4,"h3",13)(5,"span"),oC(6,2),Wl(),Zi(7,"div",14),lT(8,De,3,0,"button",15)(9,fe,9,1,"sh-menu"),Wl()(),Zi(10,"app-test-url",16,1),lm("targetUrlChange",function(g){return Pd(t),qC(n.targetUrlModel,g)||(n.targetUrlModel=g),Ld(g)})("testSignalChange",function(g){return Pd(t),qC(n.testSignal,g)||(n.testSignal=g),Ld(g)}),Wl(),dm(12),lT(13,he,3,1,"app-destination-list-item",17),Wl(),lT(14,ye,1,0,"app-destination-list"),lT(15,Me,1,1,"app-single-destination",18),Zi(16,"div",19)(17,"button",20),Hg("click",function(){return n.goBack()}),Fg(18,3),Ig(19,"sh-icon"),jg(),Wl(),Zi(20,"button",21),Fg(21,4),lT(22,Pe,2,0,"sh-icon",22)(23,Ae,2,0,"sh-icon"),jg(),Wl()()(),lT(24,Le,16,4,"sh-dialog",23);}if(e&2){let t=GC(!!n.targetUrlModel());bE(8),uT(t?9:8),bE(2),cm("targetUrl",n.targetUrlModel)("testSignal",n.testSignal),vg("backupId",null)("sourcePrefix",null)("suppressErrorDialogs",false)("askToCreate",false)("testExpectation","containsBackup")("readOnlyTest",true)("moduleType","Backend"),bE(2);let s=GC(n.selectedDestinationTypeOption());bE(),uT(s?13:-1),bE(),uT(t?-1:14),bE(),uT(t?15:-1),bE(5),vg("disabled",n.testSignal()=="testing"||!t),bE(2),uT(n.testSignal()=="testing"?22:23),bE(2),uT(n.targetUrlDialogOpen()?24:-1);}},dependencies:[un,_n,Ct,Bn,Tn,Ze,Rn,Pn,Jt,Zt,v,Fe,ve$1,N,de,ue,mn],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:40rem}header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%], header[_ngcontent-%COMP%] sh-alert[_ngcontent-%COMP%]{width:100%}header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;gap:.5rem}header[_ngcontent-%COMP%] p[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{cursor:pointer;text-decoration:underline}header[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}pre[_ngcontent-%COMP%]{white-space:pre-wrap}.field-row[_ngcontent-%COMP%]{display:grid;align-items:flex-end;grid-template-columns:1fr 2.5rem;gap:.5rem}.field-row.single-field[_ngcontent-%COMP%]{display:block}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}.clickable[_ngcontent-%COMP%]{cursor:pointer;color:var(--primary-8)}.most-common-destinations[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem}.most-common-destinations[_ngcontent-%COMP%] .tile[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;padding:1rem;border:1px solid var(--base-4);border-radius:var(--shape-3);box-shadow:var(--box-shadow-10);background-color:var(--base-2);cursor:pointer}.most-common-destinations[_ngcontent-%COMP%] .tile[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-10);margin:0}[prefix].link[_ngcontent-%COMP%]{cursor:pointer;text-decoration:underline;color:var(--primary-8)}textarea[_ngcontent-%COMP%] ~ grammarly-extension[_ngcontent-%COMP%]{display:none}.target-dialog-header[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;justify-content:space-between;gap:.5rem}"]})};
|
|
1
|
+
import {w}from'./chunk-CpY-WOcD.js';import'./chunk-BG8y51P2.js';import'./chunk-B20GDhu-.js';import {u as un,_ as _n,C as Ct,a as mn,K as Ke}from'./chunk-3iAIXnG6.js';import'./chunk-644SEuYO.js';import'./chunk-hTxREuXu.js';import'./chunk-OpdQrdKp.js';import'./chunk-Bz49u_nH.js';import'./chunk-1DRz_1dv.js';import'./chunk-BmOgPfpY.js';import'./chunk-Mj9aFt3b.js';import {G,A}from'./chunk-5q0UK__c.js';import {v as ve$1}from'./chunk-CaQaYVo7.js';import'./chunk-B5S2d_Pm.js';import'./chunk-CRhQXQUC.js';import'./chunk-CZu3210D.js';import'./chunk-DF2Ac802.js';import {T,e as ee,ax as W,a6 as be,by as ve,B as w1,G as Ge,N as Nt,au as h,g as gw,v,a as N,a0 as de,u as ue,i as ET,al as dm,Z as Zi,w as Hg,o as oC,W as Wl,l as lT,n as lm,P as Pd,p as qC,L as Ld,F as Fg,d as Ig,j as jg,am as GC,b as bE,c as uT,y as cm,z as vg,s as sC,aF as JC,O as qg,R as hC,h as aC,H as HC,aR as zl,aS as Ql,ap as zC,t as bD,a3 as XC,M as MD}from'./main-X6MUEPX4.js';import'./chunk-8A93BNds.js';import'./chunk-C8Zr0vl3.js';import {F as Fe}from'./chunk-Be4WXTyA.js';import {B as Bn,T as Tn,Z as Ze,R as Rn,P as Pn,J as Jt,a as Zt}from'./chunk-Bfg1Kjif.js';import'./chunk-BxBZMjtQ.js';import'./chunk-qUlwoHQn.js';import'./chunk-Dn7TWCfq.js';import'./chunk-CUo9Jt8-.js';import'./chunk-DM-zhIVI.js';var Oe=["formRef"],Re=["testUrl"],Ne=()=>({maxWidth:"700px",width:"100%"});function De(o,i){if(o&1){let e=ET();Zi(0,"button",24),Hg("click",function(){Pd(e);let t=aC();return Ld(t.openTargetUrlDialog())}),Fg(1,5),Ig(2,"sh-icon"),jg(),Wl();}}function Ie(o,i){if(o&1){let e=ET();Zi(0,"button",24),Hg("click",function(){Pd(e);let t=aC(2);return Ld(t.copyTargetUrl())}),Fg(1,7),Ig(2,"sh-icon"),jg(),Wl();}}function fe(o,i){if(o&1){let e=ET();Zi(0,"sh-menu")(1,"button",15)(2,"sh-icon"),HC(3,"dots-three-vertical"),Wl()(),zl(4,25),Zi(5,"button",24),Hg("click",function(){Pd(e);let t=aC();return Ld(t.openTargetUrlDialog())}),Fg(6,6),Ig(7,"sh-icon"),jg(),Wl(),lT(8,Ie,3,0,"button",15),Ql(),Wl();}if(o&2){aC();let e=zC(0);bE(8),uT(e?8:-1);}}function he(o,i){if(o&1){let e=ET();Zi(0,"app-destination-list-item",17)(1,"button",20),Hg("click",function(){Pd(e);let t=aC();return Ld(t.removeDestination())}),oC(2,8),Wl()();}if(o&2){aC();let e=zC(12);vg("destination",e);}}function ye(o,i){if(o&1){let e=ET();Zi(0,"app-destination-list",26),Hg("setDestination",function(t){Pd(e);let s=aC();return Ld(s.setDestination(t))}),Wl();}}function Me(o,i){if(o&1){let e=ET();Zi(0,"app-single-destination",27),lm("targetUrlChange",function(t){Pd(e);let s=aC();return qC(s.targetUrlModel,t)||(s.targetUrlModel=t),Ld(t)}),Wl();}if(o&2){let e=aC();cm("targetUrl",e.targetUrlModel);}}function Pe(o,i){o&1&&(Fg(0,4,1),Ig(1,"sh-icon",22),jg());}function Ae(o,i){o&1&&(Fg(0,4,2),Ig(1,"sh-icon"),jg());}function Le(o,i){if(o&1){let e=ET();Zi(0,"sh-dialog",28),lm("isOpenChange",function(t){Pd(e);let s=aC();return qC(s.targetUrlDialogOpen,t)||(s.targetUrlDialogOpen=t),Ld(t)}),Zi(1,"header",29)(2,"div",30)(3,"h2"),oC(4,9),Wl(),Zi(5,"sh-alert",31),oC(6,10),Wl()()(),Zi(7,"div",32)(8,"sh-form-field")(9,"textarea",33),lm("ngModelChange",function(t){Pd(e);let s=aC();return qC(s.targetUrlCtrl,t)||(s.targetUrlCtrl=t),Ld(t)}),Wl(),bD(),Wl()(),Zi(10,"footer",34)(11,"button",20),Hg("click",function(){Pd(e);let t=aC();return Ld(t.closeTargetUrlDialog(false))}),HC(12,"Cancel"),Wl(),Zi(13,"button",35),Hg("click",function(){Pd(e);let t=aC();return Ld(t.closeTargetUrlDialog(true))}),Fg(14,11),Ig(15,"sh-icon"),jg(),Wl()()();}if(o&2){let e=aC();cm("isOpen",e.targetUrlDialogOpen),vg("options",XC(3,Ne)),bE(9),cm("ngModel",e.targetUrlCtrl),MD();}}var x=class o{#i=T(ee);#o=T(W);#n=T(be);injector=T(ve);#e=T(w);formRef=w1.required("formRef");testUrlComponent=w1.required("testUrl");testSignal=this.#e.destinationTestSignal;targetUrlModel=this.#e.destinationTargetUrl;targetUrlCtrl=Ge(null);targetUrlInitial=Ge(null);targetUrlDialogOpen=Ge(false);toggleNewDestination=Ge(true);selectedDestinationType=Nt(()=>{let i=this.#e.destinationTargetUrl();return i?G(i):null});selectedDestinationTypeOption=Nt(()=>{let i=this.selectedDestinationType();return i?{key:i.customKey??i.key,customKey:i.customKey??null,displayName:i.displayName,description:i.description,sourceDescription:i.sourceDescription??null,icon:i.icon}:null});copyTargetUrl(){navigator.clipboard.writeText(this.#e.destinationTargetUrl()??"");}openTargetUrlDialog(){let i=this.#e.destinationTargetUrl();this.targetUrlCtrl.set(i),this.targetUrlInitial.set(i),this.targetUrlDialogOpen.set(true);}closeTargetUrlDialog(i=false){this.targetUrlDialogOpen.set(false);let e=this.targetUrlCtrl(),n=this.targetUrlInitial();!i||e===n||!e||this.#e.updateTargetUrl(e);}setDestination(i){let e=A(i??"");if(e){if(e.mapper.default){let n=e.mapper.default("");this.#e.updateTargetUrl(n);return}this.#e.updateTargetUrl(`${i}://`);}}removeDestination(){this.#e.updateTargetUrl(null);}goBack(){this.#i.navigate(["general"],{relativeTo:this.#o.parent});}next(){let i=this.testSignal();if(i===null){this.#n.open(h,{data:{title:$localize`Test destination`,message:$localize`You have not tested the destination yet. Do you want to test it now?`,confirmText:$localize`Test now`,cancelText:$localize`Skip test and continue`},closed:n=>{n?this.testUrlComponent()?.testDestination(false)?.then(t=>{t.action==="success"&&t.containsBackup?this.#t():this.#n.open(h,{data:{title:$localize`Test did not succeed`,message:t.errorMessage??$localize`Failed to test the destination.`,confirmText:$localize`OK`,cancelText:void 0}});}):this.#t();}});return}let e=typeof i=="string"?null:i;if(e?.action!=="success"||!e.containsBackup){this.#n.open(h,{data:{title:$localize`Test destination`,message:$localize`The destination has not been tested successfully. Are you sure you want to continue?`,confirmText:$localize`Edit destination`,cancelText:$localize`Yes, continue`},closed:n=>{n||this.#t();}});return}this.#t();}#t(){this.#i.navigate(["encryption"],{relativeTo:this.#o.parent});}static \u0275fac=function(e){return new(e||o)};static \u0275cmp=gw({type:o,selectors:[["app-restore-destination"]],viewQuery:function(e,n){e&1&&qg(n.formRef,Oe,5)(n.testUrlComponent,Re,5),e&2&&hC(2);},features:[JC([Ke])],decls:25,vars:18,consts:()=>{let i;i=$localize`Backup destination`;let e;e=$localize`${"\uFFFD#19\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#19\uFFFD"}:CLOSE_TAG_SH_ICON: Go back `;let n;n=$localize`${"\uFFFD*22:1\uFFFD"}:START_BLOCK_IF:${"\uFFFD#1:1\uFFFD"}:START_TAG_SH_ICON:spinner${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*22:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*23:2\uFFFD"}:START_BLOCK_ELSE:${"\uFFFD#1:2\uFFFD"}:START_TAG_SH_ICON_1:arrow-right${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*23:2\uFFFD"}:CLOSE_BLOCK_ELSE: Continue `,n=sC(n);let t;t=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:link${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Set target URL `;let s;s=$localize`${"\uFFFD#7\uFFFD"}:START_TAG_SH_ICON:link${"\uFFFD/#7\uFFFD"}:CLOSE_TAG_SH_ICON: Edit target URL `;let g;g=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:copy${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Copy URL to clipboard `;let U;U=$localize`Change`;let b;b=$localize`Edit target URL`;let G;G=$localize`Be careful, this will overwrite everything you have in your destination.`;let k;return k=$localize` Override target URL ${"\uFFFD#15\uFFFD"}:START_TAG_SH_ICON:swap${"\uFFFD/#15\uFFFD"}:CLOSE_TAG_SH_ICON:`,[["formRef",""],["testUrl",""],i,e,n,t,s,g,U,b,G,k,[3,"submit"],[1,"title-30"],[1,"actions"],["shButton","","type","button",1,"small"],[3,"targetUrlChange","testSignalChange","targetUrl","testSignal","backupId","sourcePrefix","suppressErrorDialogs","askToCreate","testExpectation","readOnlyTest","moduleType"],[1,"current-destination",3,"destination"],[3,"targetUrl"],[1,"form-actions"],["shButton","","type","button",3,"click"],["shButton","","type","submit",1,"raised","primary",3,"disabled"],[1,"loader"],[3,"isOpen","options"],["shButton","","type","button",1,"small",3,"click"],["menu",""],[3,"setDestination"],[3,"targetUrlChange","targetUrl"],[3,"isOpenChange","isOpen","options"],["header",""],[1,"target-dialog-header"],[1,"warn"],["content",""],["id","targetUrl","autocomplete","off",3,"ngModelChange","ngModel"],["footer",""],["shButton","","type","submit",1,"raised","primary",3,"click"]]},template:function(e,n){if(e&1){let t=ET();dm(0),Zi(1,"form",12,0),Hg("submit",function(){return n.next()}),Zi(3,"header")(4,"h3",13)(5,"span"),oC(6,2),Wl(),Zi(7,"div",14),lT(8,De,3,0,"button",15)(9,fe,9,1,"sh-menu"),Wl()(),Zi(10,"app-test-url",16,1),lm("targetUrlChange",function(g){return Pd(t),qC(n.targetUrlModel,g)||(n.targetUrlModel=g),Ld(g)})("testSignalChange",function(g){return Pd(t),qC(n.testSignal,g)||(n.testSignal=g),Ld(g)}),Wl(),dm(12),lT(13,he,3,1,"app-destination-list-item",17),Wl(),lT(14,ye,1,0,"app-destination-list"),lT(15,Me,1,1,"app-single-destination",18),Zi(16,"div",19)(17,"button",20),Hg("click",function(){return n.goBack()}),Fg(18,3),Ig(19,"sh-icon"),jg(),Wl(),Zi(20,"button",21),Fg(21,4),lT(22,Pe,2,0,"sh-icon",22)(23,Ae,2,0,"sh-icon"),jg(),Wl()()(),lT(24,Le,16,4,"sh-dialog",23);}if(e&2){let t=GC(!!n.targetUrlModel());bE(8),uT(t?9:8),bE(2),cm("targetUrl",n.targetUrlModel)("testSignal",n.testSignal),vg("backupId",null)("sourcePrefix",null)("suppressErrorDialogs",false)("askToCreate",false)("testExpectation","containsBackup")("readOnlyTest",true)("moduleType","Backend"),bE(2);let s=GC(n.selectedDestinationTypeOption());bE(),uT(s?13:-1),bE(),uT(t?-1:14),bE(),uT(t?15:-1),bE(5),vg("disabled",n.testSignal()=="testing"||!t),bE(2),uT(n.testSignal()=="testing"?22:23),bE(2),uT(n.targetUrlDialogOpen()?24:-1);}},dependencies:[un,_n,Ct,Bn,Tn,Ze,Rn,Pn,Jt,Zt,v,Fe,ve$1,N,de,ue,mn],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:40rem}header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%], header[_ngcontent-%COMP%] sh-alert[_ngcontent-%COMP%]{width:100%}header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;gap:.5rem}header[_ngcontent-%COMP%] p[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{cursor:pointer;text-decoration:underline}header[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}pre[_ngcontent-%COMP%]{white-space:pre-wrap}.field-row[_ngcontent-%COMP%]{display:grid;align-items:flex-end;grid-template-columns:1fr 2.5rem;gap:.5rem}.field-row.single-field[_ngcontent-%COMP%]{display:block}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}.clickable[_ngcontent-%COMP%]{cursor:pointer;color:var(--primary-8)}.most-common-destinations[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem}.most-common-destinations[_ngcontent-%COMP%] .tile[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;padding:1rem;border:1px solid var(--base-4);border-radius:var(--shape-3);box-shadow:var(--box-shadow-10);background-color:var(--base-2);cursor:pointer}.most-common-destinations[_ngcontent-%COMP%] .tile[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-10);margin:0}[prefix].link[_ngcontent-%COMP%]{cursor:pointer;text-decoration:underline;color:var(--primary-8)}textarea[_ngcontent-%COMP%] ~ grammarly-extension[_ngcontent-%COMP%]{display:none}.target-dialog-header[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;justify-content:space-between;gap:.5rem}"]})};
|
|
2
2
|
export{x as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {T,bn as N,E as E1,ag as D1,Q as Qa,bd as ce,g as gw,a as N$1,S as lC,Z as Zi,w as Hg,Y as uC,l as lT,W as Wl,aE as yg,b as bE,c as uT,x as xC,K as Kg,H as HC}from'./main-
|
|
1
|
+
import {T,bn as N,E as E1,ag as D1,Q as Qa,bd as ce,g as gw,a as N$1,S as lC,Z as Zi,w as Hg,Y as uC,l as lT,W as Wl,aE as yg,b as bE,c as uT,x as xC,K as Kg,H as HC}from'./main-X6MUEPX4.js';var k=[[["","title",""]],"*"],M=["[title]","*"];function j(t,S){t&1&&HC(0,"Title");}function E(t,S){t&1&&(Zi(0,"sh-icon",1),HC(1,"caret-down"),Wl());}var I=(()=>{class t{constructor(){this.#e=T(N),this.disableToggle=E1(false),this.isActive=D1(false),this.#t=Qa(()=>{this.disableToggle()&&this.isActive.set(true);}),this.color=E1(null),this.variant=E1(null),this.hostClasses=ce("card",{color:this.color,variant:this.variant});}#e;#t;toggle(){this.isActive.set(!this.isActive());}handleKeyDown(o){this.#e.matches(o,"toggle-card.toggle")&&(o.preventDefault(),this.toggle());}static{this.\u0275fac=function(i){return new(i||t)};}static{this.\u0275cmp=gw({type:t,selectors:[["sh-toggle-card"]],hostVars:4,hostBindings:function(i,e){i&2&&(xC(e.hostClasses()),Kg("active",e.isActive()));},inputs:{disableToggle:[1,"disableToggle"],isActive:[1,"isActive"],color:[1,"color"],variant:[1,"variant"]},outputs:{isActive:"isActiveChange"},ngContentSelectors:M,decls:7,vars:4,consts:[["role","button",3,"click","keydown"],[1,"toggle-icon"],[1,"collapsable"],[1,"content"]],template:function(i,e){i&1&&(lC(k),Zi(0,"h3",0),Hg("click",function(){return e.disableToggle()?null:e.toggle()})("keydown",function(D){return e.disableToggle()?null:e.handleKeyDown(D)}),uC(1,0,null,j,1,0),lT(3,E,2,0,"sh-icon",1),Wl(),Zi(4,"div",2)(5,"div",3),uC(6,1),Wl()()),i&2&&(yg("tabindex",e.disableToggle()?null:"0")("aria-expanded",e.disableToggle()?null:e.isActive()?"true":"false")("aria-disabled",e.disableToggle()?"true":null),bE(3),uT(e.disableToggle()?-1:3));},dependencies:[N$1],styles:[`sh-toggle-card{display:flex;flex-direction:column;border-radius:var(--shape-3);background-color:var(--base-2)}sh-toggle-card.type-a{background-color:transparent;border:var(--border-10)}sh-toggle-card.active .collapsable{grid-template-rows:1fr}sh-toggle-card.active .content{padding:0 1rem 1rem}sh-toggle-card.active .content:empty{padding:0 1rem}sh-toggle-card.active sh-icon.toggle-icon{transform:rotate(180deg)}sh-toggle-card h3{display:flex;align-items:center;justify-content:space-between;font:var(--paragraph-10);padding:1rem;cursor:pointer;-webkit-user-select:none;user-select:none}sh-toggle-card sh-icon.toggle-icon{cursor:pointer;transform:rotate(0);transform-origin:center;transition:transform .2s ease}sh-toggle-card .collapsable{display:grid;grid-template-rows:0fr;transition:grid-template-rows .5s linear;overflow:hidden}sh-toggle-card .content{display:flex;flex-direction:column;gap:1rem;padding:0 1rem;min-height:0;overflow:hidden}
|
|
2
2
|
`],encapsulation:2});}}return t})();export{I};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {c}from'./chunk-
|
|
1
|
+
import {c}from'./chunk-9Pc-waxi.js';import {ShipTable as ot}from'./chunk-BSCOyYHH.js';import {c as c$1}from'./chunk-Mj9aFt3b.js';import {T,E as E1,Q as Qa,G as Ge,g as gw,a as N,v as v$1,aL as ci,l as lT,c as uT,K as Kg,Z as Zi,o as oC,W as Wl,d as Ig,a1 as pT,h as aC,ah as Yg,z as vg,b as bE,a2 as hT,i as ET,w as Hg,P as Pd,L as Ld,H as HC,aO as sb,J as im,aP as lb,aa as Yl,aq as dT}from'./main-X6MUEPX4.js';import'./chunk-DF2Ac802.js';import'./chunk-C8Zr0vl3.js';var B=(t,n)=>n.ID;function J(t,n){t&1&&(Zi(0,"div",4),oC(1,0),Wl());}function U(t,n){if(t&1&&(Zi(0,"li"),HC(1),Wl()),t&2){let e=n.$implicit;bE(),im(e);}}function X(t,n){if(t&1&&(Zi(0,"strong"),HC(1,"# Exception"),Wl(),Zi(2,"ol",15),pT(3,U,2,1,"li",null,dT),Wl()),t&2){let e=aC(3).$implicit,a=aC(2);bE(3),hT(a.breakIntoLines(e.Exception));}}function j(t,n){if(t&1&&(Zi(0,"li"),HC(1),Wl()),t&2){let e=n.$implicit;bE(),im(e);}}function z(t,n){if(t&1&&(Zi(0,"strong"),HC(1,"# Message"),Wl(),Zi(2,"ol",15),pT(3,j,2,1,"li",null,dT),Wl()),t&2){let e=aC(3).$implicit,a=aC(2);bE(3),hT(a.breakIntoLines(e.Message));}}function W(t,n){if(t&1&&(Zi(0,"code"),lT(1,X,5,0),lT(2,z,5,0),Wl()),t&2){let e=aC(2).$implicit;bE(),uT(e.Exception?1:-1),bE(),uT(e.Message?2:-1);}}function H(t,n){if(t&1&&(Zi(0,"tr")(1,"td",12)(2,"sh-list",13)(3,"div",14),HC(4),Wl(),Zi(5,"div",14),HC(6),Wl(),Zi(7,"div",14),HC(8),Wl(),Zi(9,"div",14),HC(10),Wl(),Zi(11,"div",14),HC(12),Wl()(),lT(13,W,3,2,"code"),Wl()()),t&2){let e=aC().$implicit;bE(4),Yl("ID: ",e.ID),bE(2),Yl("Type: ",e.Type),bE(2),Yl("Tag: ",e.Tag),bE(2),Yl("TaskID: ",e.TaskID),bE(2),Yl("MessageID: ",e.MessageID),bE(),uT(e.Exception||e.Message?13:-1);}}function q(t,n){if(t&1){let e=ET();Zi(0,"tr",10),Hg("click",function(){let u=Pd(e).$implicit,g=aC(2);return Ld(g.toggleRow(u.ID))}),Zi(1,"td"),HC(2),sb(3,"date"),Wl(),Zi(4,"td"),HC(5),Wl(),Zi(6,"td",8)(7,"button",11)(8,"sh-icon"),HC(9,"caret-down"),Wl()()()(),lT(10,H,14,6,"tr");}if(t&2){let e=n.$implicit,a=aC(2);bE(2),im(lb(3,5,e.When,"medium")),bE(3),im(a.subStringMessage(e.Message)),bE(2),Kg("rotated-icon",e.ID===a.openRowId()),bE(3),uT(e.ID===a.openRowId()?10:-1);}}function K(t,n){if(t&1&&(Zi(0,"sh-table",6)(1,"tr",7)(2,"th"),oC(3,1),Wl(),Zi(4,"th"),oC(5,2),Wl(),Ig(6,"th",8),Wl(),pT(7,q,11,8,null,null,B),Zi(9,"div",9),oC(10,3),Wl()()),t&2){let e=aC();Yg("grid-template-columns","auto 1fr auto"),Kg("type-b",true),vg("data",e.logs())("loading",e.logsLoading()),bE(7),hT(e.logs());}}var v=class t{#e=T(c);whenFilter=E1();backupIdFilter=E1();polling=E1();logLevel=this.#e.logLevel;logLevelByLabel=this.#e.logLevelByLabel;logs=this.#e.logs;logsLoading=this.#e.logsLoading;pollingEffect=Qa(()=>{let n=this.polling()??false;this.#e.isPolling.set(n);});openRowId=Ge(null);whenEffect=Qa(()=>{let n=this.whenFilter()??null;this.#e.setWhenFilter(n),this.#e.logLevel.set(n?"Verbose":"Disabled");});backupIdEffect=Qa(()=>{let n=this.backupIdFilter()??null;this.#e.setBackupIdFilter(n),this.#e.logLevel.set(n?"Verbose":"Disabled");});toggleRow(n){n!=null&&this.openRowId.set(n===this.openRowId()?null:n);}breakIntoLines(n){return n?n.split(`
|
|
2
2
|
`):[]}subStringMessage(n){return n?n.substring(0,80)+"...":""}ngOnDestroy(){this.#e.destroy();}static \u0275fac=function(e){return new(e||t)};static \u0275cmp=gw({type:t,selectors:[["app-logs-live"]],hostVars:2,hostBindings:function(e,a){e&2&&Kg("is-disabled",a.logLevel()==="Disabled");},inputs:{whenFilter:[1,"whenFilter"],backupIdFilter:[1,"backupIdFilter"],polling:[1,"polling"]},decls:2,vars:1,consts:()=>{let n;n=$localize`Live logs are disabled`;let e;e=$localize`When`;let a;a=$localize`Message`;let u;return u=$localize`No data available`,[n,e,a,u,[1,"live-view-disabled"],[3,"type-b","data","loading","grid-template-columns"],[3,"data","loading"],["thead",""],[1,"sticky-end"],["table-no-rows",""],[3,"click"],["shButton","","type","button",1,"outlined","small"],[1,"expanded-cell"],[1,"primary"],["item",""],[1,"line-numbers-ol"]]},template:function(e,a){e&1&&lT(0,J,2,0,"div",4)(1,K,11,6,"sh-table",5),e&2&&uT(a.logLevel()==="Disabled"?0:1);},dependencies:[ot,N,c$1,v$1,ci],styles:["[_nghost-%COMP%]{display:block}.is-disabled[_nghost-%COMP%]{padding:0 2rem}.live-view-disabled[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;min-height:18.75rem;width:100%;background-color:var(--base-2);border:1px solid var(--base-3);border-radius:var(--shape-2);font:var(--paragraph-20)}.expanded-cell[_ngcontent-%COMP%]{height:auto;grid-column:1/-1;white-space:pre-wrap;display:flex;flex-direction:column;background:var(--base-2)}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0 0 1.25rem}sh-table[_ngcontent-%COMP%]{--table-columns: auto auto 1fr auto}sh-table[_ngcontent-%COMP%] td.id[_ngcontent-%COMP%]{justify-content:center}sh-table[_ngcontent-%COMP%] td[_ngcontent-%COMP%]:has(code){padding:1rem .75rem;overflow:hidden}sh-table[_ngcontent-%COMP%] td[_ngcontent-%COMP%]:has(code) code[_ngcontent-%COMP%]{background:color-mix(in srgb,var(--base-8),#000 70%);color:#fff;padding:1.5rem;border-radius:var(--shape-2);overflow:auto;white-space:pre;max-width:100%;width:100%}sh-table[_ngcontent-%COMP%] td[_ngcontent-%COMP%]:has(code) code[_ngcontent-%COMP%] ul[_ngcontent-%COMP%]{margin:0}code[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{display:inline-block;margin-bottom:.25rem}code[_ngcontent-%COMP%] ol.line-numbers-ol[_ngcontent-%COMP%] + strong[_ngcontent-%COMP%]{margin-top:1.25rem}"]})};export{v as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import {ShipTable as ot}from'./chunk-
|
|
1
|
+
import {ShipTable as ot}from'./chunk-BSCOyYHH.js';import'./chunk-DF2Ac802.js';import {T,ab as J,a6 as be,a5 as m,e as ee,E as E1,N as Nt,G as Ge,Q as Qa,aj as m$1,ak as l,b5 as Ae$1,b6 as zu,C as Zu,au as h,g as gw,v,_ as _t,aJ as m$2,b3 as m$3,Z as Zi,o as oC,W as Wl,l as lT,w as Hg,b as bE,av as Vg,aw as iC,c as uT,z as vg,a3 as XC,K as Kg,s as sC,ad as sy,d as Ig,i as ET,n as lm,P as Pd,h as aC,p as qC,L as Ld,a1 as pT,y as cm,a2 as hT,H as HC,aO as sb,t as bD,J as im,aP as lb,aT as cb,M as MD}from'./main-X6MUEPX4.js';import {d}from'./chunk-C8Zr0vl3.js';import {F as Fe}from'./chunk-Be4WXTyA.js';import {B as Bn,Z as Ze,R as Rn,J as Jt}from'./chunk-Bfg1Kjif.js';import {$}from'./chunk-DM-zhIVI.js';var Te=()=>["/"],Pe=(s,i)=>i.Version;function Oe(s,i){s&1&&(Zi(0,"div",11),Ig(1,"sh-progress-bar",17),Zi(2,"p"),oC(3,3),Wl()());}function Re(s,i){s&1&&(Zi(0,"div",12)(1,"p"),oC(2,4),Wl()());}function Ae(s,i){if(s&1){let e=ET();Zi(0,"tr")(1,"td"),HC(2),Wl(),Zi(3,"td"),HC(4),sb(5,"relativeTime"),Wl(),Zi(6,"td"),HC(7),sb(8,"relativeTime"),Wl(),Zi(9,"td"),HC(10),sb(11,"bytes"),Wl(),Zi(12,"td"),HC(13),Wl(),Zi(14,"td")(15,"sh-form-field")(16,"input",24),Hg("ngModelChange",function(_){let E=Pd(e).$implicit,m=aC(2);return Ld(m.updateLabel(E.Version,_))}),Wl(),bD(),Wl()()();}if(s&2){let e=i.$implicit,n=aC(2);bE(2),im(e.Version),bE(2),im(lb(5,7,e.Time,true)),bE(3),im(lb(8,10,e.Time,false)),bE(3),im(cb(11,13,e.FileSizes)),bE(3),im(e.FileCount),bE(3),vg("ngModel",e.EditedLabel)("disabled",n.isSaving()),MD();}}function Ie(s,i){if(s&1){let e=ET();Zi(0,"sh-table",18),lm("sortByColumnChange",function(_){Pd(e);let E=aC();return qC(E.sortByColumn,_)||(E.sortByColumn=_),Ld(_)}),Zi(1,"tr",19)(2,"th",20),oC(3,5),Wl(),Zi(4,"th",20),oC(5,6),Wl(),Zi(6,"th",20),oC(7,7),Wl(),Zi(8,"th",21),oC(9,8),Wl(),Zi(10,"th",22),oC(11,9),Wl(),Zi(12,"th",23),oC(13,10),Wl()(),pT(14,Ae,17,15,"tr",null,Pe),Wl();}if(s&2){let e=aC();vg("data",e.versions())("loading",e.isLoading()),cm("sortByColumn",e.sortByColumn),bE(14),hT(e.versions());}}var B=class s{#e=T(J);#i=T(be);#n=T(m);#t=T(ee);id=E1.required();backup=Nt(()=>{this.#n.backups();return this.#n.getBackupById(this.id())});versionsResource=$({params:()=>({id:this.id()}),stream:({params:i})=>sy(()=>this.#e.postApiV2BackupListFilesets({body:{BackupId:i.id}}))});isLoading=Nt(()=>this.versionsResource.isLoading());isSaving=Ge(false);versions=Ge([]);constructor(){Qa(()=>{let i=this.versionsResource.value();if(i){let e=(i.Data??[]).slice().sort((n,_)=>n.Time<_.Time?1:n.Time>_.Time?-1:0);this.versions.set(e.map(n=>m$1(l({},n),{EditedLabel:n.Label??""})));}});}changedItems=Nt(()=>this.versions().filter(i=>(i.Label??"")!==i.EditedLabel.trim()));sortByColumn=Ge("version");updateLabel(i,e){this.versions.update(n=>n.map(_=>_.Version===i?m$1(l({},_),{EditedLabel:e}):_));}saveLabels(){let i=this.changedItems();i.length!==0&&(this.isSaving.set(true),Ae$1(i).pipe(zu(e=>this.#e.postApiV2BackupSetVersionLabel({body:{BackupId:this.id(),Version:e.Version,Label:e.EditedLabel.trim()===""?null:e.EditedLabel.trim()}})),Zu(()=>this.isSaving.set(false))).subscribe({complete:()=>{this.#t.navigate(["/"]);},error:e=>{this.#i.open(h,{data:{title:$localize`Failed to set version labels`,message:e.message??$localize`Unknown error`,confirmText:$localize`OK`,cancelText:void 0}});}}));}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=gw({type:s,selectors:[["app-version-labels"]],inputs:{id:[1,"id"]},decls:10,vars:10,consts:()=>{let i;i=$localize`Set version labels for ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let e;e=$localize`Cancel`;let n;n=$localize`{VAR_PLURAL, plural, =1 {1 label} other {{INTERPOLATION} labels}}`,n=sC(n,{INTERPOLATION:"\uFFFD1\uFFFD",VAR_PLURAL:"\uFFFD0\uFFFD"});let _;_=$localize` Save ${n}:ICU@@198601359091253570: `;let E;E=$localize`Fetching versions from destination...`;let m;m=$localize`No versions found for this backup.`;let b;b=$localize`Version`;let V;V=$localize`Timestamp`;let h;h=$localize`When`;let y;y=$localize`Size`;let $;$=$localize`Files`;let v;v=$localize`Label`;let G;return G=$localize`Add label...`,[i,e,_,E,m,b,V,h,y,$,v,[1,"loading-state"],[1,"empty-state"],[1,"type-b",3,"data","loading","sortByColumn"],[1,"actions"],["shButton","",3,"routerLink","disabled"],["shButton","",1,"raised","primary",3,"click","disabled"],[1,"primary","indeterminate"],[1,"type-b",3,"sortByColumnChange","data","loading","sortByColumn"],["thead",""],["size","min-content","shSort","version"],["size","min-content","shSort","size"],["size","min-content","shSort","files"],["size","1fr","shSort","label"],["type","text","placeholder",G,1,"label",3,"ngModelChange","ngModel","disabled"]]},template:function(e,n){e&1&&(Zi(0,"h3"),oC(1,0),Wl(),lT(2,Oe,4,0,"div",11)(3,Re,3,0,"div",12)(4,Ie,16,3,"sh-table",13),Zi(5,"div",14)(6,"button",15),oC(7,1),Wl(),Zi(8,"button",16),Hg("click",function(){return n.saveLabels()}),oC(9,2),Wl()()),e&2&&(bE(),Vg(n.backup()?.Backup?.Name),iC(1),bE(),uT(n.isLoading()?2:n.versions().length===0?3:4),bE(4),vg("routerLink",XC(9,Te))("disabled",n.isSaving()),bE(2),Kg("loading",n.isSaving()),vg("disabled",n.isSaving()||n.changedItems().length===0||n.isLoading()),bE(),Vg(n.changedItems().length)(n.changedItems().length),iC(9));},dependencies:[Bn,Ze,Rn,Jt,v,d,ot,_t,Fe,m$2,m$3],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;padding:2.5rem}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0}sh-table[_ngcontent-%COMP%]{padding:2rem 0}.label[_ngcontent-%COMP%]{width:100%}.loading-state[_ngcontent-%COMP%], .empty-state[_ngcontent-%COMP%]{padding:2rem 0;display:flex;flex-direction:column;gap:1rem}.actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;gap:.5rem;padding-top:2rem}"]})};export{B as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {t as te}from'./chunk-DmCJ7w-M.js';import'./chunk-C1-31fA7.js';import {O}from'./chunk-iU19kwHx.js';import {m}from'./chunk-C185qUb-.js';import {r}from'./chunk-BEUeHgR9.js';import {J}from'./chunk-CGnjVnmu.js';import'./chunk-DuRr4rDS.js';import {N as Nt$1}from'./chunk-C1py21yb.js';import {c}from'./chunk-3YzyUT-a.js';import {D}from'./chunk-CKUlUN3q.js';import {c1 as Ms,c2 as j,c3 as ft,c4 as go,T,a6 as be,f,I,c5 as f$1,G as Ge,N as Nt,Q as Qa,C as Zu,c6 as wt,au as h,g as gw,v as v$1,a as N,u as ue,d as Ig,Z as Zi,o as oC,W as Wl,l as lT,w as Hg,t as bD,F as Fg,j as jg,n as lm,b4 as cg,b as bE,c as uT,K as Kg,z as vg,a3 as XC,M as MD,av as Vg,aw as iC,y as cm,s as sC,p as qC,ab as J$1,B as w1,ad as sy,b7 as lg,b8 as sT,b9 as aT,O as qg,R as hC,af as eo,E as E1,ag as D1,bd as ce,S as lC,U as ql,Y as uC,X as Gl,H as HC,ao as Bg,V as Eg,aD as sm,ah as Yg,x as xC,h as aC,J as im,i as ET,P as Pd,L as Ld,as as Yp,a9 as QC,aa as Yl}from'./main-2ZYVV4C4.js';import {d}from'./chunk-BGuvkLC9.js';import {F as Fe}from'./chunk-DBkkb6OR.js';import {B as Bn$1,Z as Ze,o as on,R as Rn$1,J as Jt,G as Gn$1}from'./chunk-iGzJokt-.js';import {a as at}from'./chunk-DneBfCBh.js';import {v}from'./chunk-Bq_vr6Q3.js';import {R}from'./chunk-D9jPw9Ov.js';import'./chunk-CnZx831x.js';import'./chunk-Cm7JSdTO.js';var gn=[[["label"]],[["input","type","range"]]],Cn=["label","input[type=range]"],dn=(()=>{class i{constructor(){this.hasInput=Ge(false),this.#n=T(eo),this.#i=null,this.#e=null,this.#t=0,this.unit=E1(""),this.value=D1(this.#t),this.inputState=Ge({min:0,max:100,step:1}),this.color=E1(null),this.variant=E1(null),this.size=E1(null),this.sharp=E1(void 0),this.alwaysShow=E1(void 0),this.hostClasses=ce("rangeSlider",{color:this.color,variant:this.variant,size:this.size,sharp:this.sharp,alwaysShow:this.alwaysShow}),this.valuePercentage=Nt(()=>{let{min:e,max:n}=this.inputState(),a=this.value()??e;if(isNaN(a))return 0;let l=n-e;if(l===0)return 0;let m=(a-e)/l*100;return Math.max(0,Math.min(100,m))}),this.trackFilledPercentage=Nt(()=>this.valuePercentage()),this.thumbPositionPercentage=Nt(()=>this.valuePercentage()),this.syncModelToInputEffect=Qa(()=>{let e=this.value();if(this.#e){let n=parseFloat(this.#e.value);(isNaN(n)||String(n)!==String(e))&&(this.#e.value=String(e));}});}#n;#i;#e;#t;ngAfterViewInit(){this.#e=this.#n.nativeElement.querySelector('input[type="range"]'),this.#e?(this.hasInput.set(true),this.#a(this.#e),this.#e.oninput=()=>{this.setNewInputValue(this.#e.value);},this.#e.addEventListener("inputValueChanged",e=>{this.setNewInputValue(e.detail.value);}),queueMicrotask(()=>this.#s(true)),this.#r()):console.error('ShipRangeSlider: No <input type="range"> element found projected inside.');}setNewInputValue(e){let n=parseFloat(e??"0");if(!isNaN(n)){let{min:a,max:l}=this.inputState();this.value.set(Math.max(a,Math.min(l,n)));}}trackEvent(e){if(!this.#e||this.#e.readOnly||this.#e.disabled){e.preventDefault(),e.stopPropagation();return}if(e.target===this.#e||e.target?.closest(".thumb, .min-indicator, .max-indicator"))return;let a=e.currentTarget.getBoundingClientRect(),l=e.clientX-a.left,m=a.width,{min:u,max:E,step:f}=this.inputState(),W=E-u;if(m>0&&W!==0&&f>0){let Q=(l/m*W+u-u)/f,J=u+Math.round(Q)*f,V=this.#o(f);J=parseFloat(J.toFixed(V));let Y=Math.max(u,Math.min(E,J));this.value.set(Y);}}#s(e=false){if(!this.#e)return;let n=parseFloat(this.#e.min??"0")??0,a=parseFloat(this.#e.max??"100")??100,l=this.#e.step,m=1;if(l&&l.toLowerCase()!=="any"){let E=parseFloat(l);!isNaN(E)&&E>0&&(m=E);}this.inputState.set({min:n,max:a,step:m});let u=parseFloat(this.#e.value??String(n))??n;if(e&&this.value()!==this.#t){let E=this.value(),f=Math.max(n,Math.min(a,E));u!==f&&(this.#e.value=String(f)),E!==f&&this.value.set(f);}else {let E=Math.max(n,Math.min(a,u));this.value()!==E&&this.value.set(E);}}#r(){if(!this.#e||typeof MutationObserver>"u")return;let e=["min","max","step","value","readonly","disabled"];this.#i=new MutationObserver(n=>{let a=false;for(let l of n)if(l.type==="attributes"&&e.includes(l.attributeName??"")){a=true;break}a&&this.#s(false);}),this.#i.observe(this.#e,{attributes:true,attributeFilter:e});}#o(e){if(isNaN(e)||Math.floor(e)===e)return 0;let a=e.toString().split(".")[1];return a?a.length:0}#a(e){Object.defineProperty(e,"value",{configurable:true,get(){return Object.getOwnPropertyDescriptor(Object.getPrototypeOf(e),"value").get.call(this)},set(n){Object.getOwnPropertyDescriptor(Object.getPrototypeOf(e),"value").set.call(this,n);let l=new CustomEvent("inputValueChanged",{bubbles:true,cancelable:true,detail:{value:n}});return this.dispatchEvent(l),n}});}ngOnDestroy(){this.#i&&this.#i.disconnect(),this.#e&&(this.#e.oninput=null);}static{this.\u0275fac=function(n){return new(n||i)};}static{this.\u0275cmp=gw({type:i,selectors:[["sh-range-slider"]],hostVars:6,hostBindings:function(n,a){n&2&&(xC(a.hostClasses()),Kg("sh-range-slider",true)("has-input",a.hasInput()));},inputs:{unit:[1,"unit"],value:[1,"value"],color:[1,"color"],variant:[1,"variant"],size:[1,"size"],sharp:[1,"sharp"],alwaysShow:[1,"alwaysShow"]},outputs:{value:"valueChange"},ngContentSelectors:Cn,decls:15,vars:10,consts:[[1,"label"],[1,"input-wrap"],[1,"min-indicator"],[1,"track-wrap",3,"click"],[1,"track"],[1,"track-filled"],[1,"thumb-wrap"],[1,"thumb"],[1,"value-indicator"],[1,"max-indicator"]],template:function(n,a){n&1&&(lC(gn),ql(0,"div",0),uC(1),Gl(),ql(2,"div",1)(3,"div",2),HC(4),Gl(),ql(5,"div",3),Bg("click",function(m){return a.trackEvent(m)}),uC(6,1),ql(7,"div",4),Eg(8,"div",5),Gl(),ql(9,"div",6)(10,"div",7)(11,"div",8),HC(12),Gl()()()(),ql(13,"div",9),HC(14),Gl()()),n&2&&(bE(4),sm("",a.inputState().min,"",a.unit()),bE(4),Yg("width",a.trackFilledPercentage(),"%"),bE(),Yg("left",a.thumbPositionPercentage(),"%"),bE(3),sm("",a.value(),"",a.unit()),bE(2),sm("",a.inputState().max,"",a.unit()));},styles:[`sh-range-slider{--rs-h: 2.5rem;--rs-f: var(--paragraph-30);--rs-unit-g: .75rem;--rs-unit-c: var(--base-8);--rst: var(--base-3);--rst-bc: var(--base-1);--rst-bg: var(--base-4);--rst-h: .5rem;--rst-s: calc(var(--shape-2) / 2);--rs-thumb-c: var(--base-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--base-4);--rs-thumb-arrow: var(--rs-thumb-value-bg);--rs-thumb-value-c: var(--base-8);--rs-thumb-si: 1rem;--rs-thumb-w: var(--rs-thumb-si);--rs-thumb-s: calc(var(--rs-thumb-w) / 2);display:flex;flex-direction:column;width:100%;font:var(--rs-f)}sh-range-slider.sharp{--rst-s: .125rem;--rs-thumb-s: .125rem;--rs-thumb-bc: transparent !important}sh-range-slider .label{display:flex;align-items:center;gap:.5rem;padding-bottom:.25rem}sh-range-slider .label>label{display:flex;align-items:center;gap:.25rem}sh-range-slider .label sh-icon{color:var(--grey-500);font-size:1rem}sh-range-slider .label:empty{display:none}sh-range-slider[readonly]:not([readonly=false]),sh-range-slider:has(input[type=range][readonly]:not([readonly=false])),sh-range-slider[disabled]:not([disabled=false]),sh-range-slider:has(input[type=range][disabled]:not([disabled=false])){opacity:.4;pointer-events:none;-webkit-user-select:none;user-select:none;cursor:initial}sh-range-slider:has(input[type=range][readonly]) .thumb .value-indicator,sh-range-slider.always-show .thumb .value-indicator{opacity:1}sh-range-slider input[type=range]{appearance:none;width:100%;height:100%;position:absolute;inset:0;opacity:0;margin:0;z-index:1000}sh-range-slider .input-wrap{display:flex;align-items:center;justify-content:center;width:100%;min-height:var(--rs-h);position:relative;gap:var(--rs-unit-g)}sh-range-slider .thumb-wrap{position:absolute;top:0}sh-range-slider .thumb{position:relative;margin-top:calc(-1 * var(--rs-thumb-si) / 4);width:var(--rs-thumb-w);height:var(--rs-thumb-si);border-radius:var(--rs-thumb-s);background-color:var(--rs-thumb-c);border:1px solid var(--rs-thumb-bc);box-shadow:var(--box-shadow-20);transform:translate(-50%)}sh-range-slider .track-wrap{position:relative;width:100%;height:var(--rst-h)}sh-range-slider .track{position:relative;width:100%;height:var(--rst-h);border-radius:var(--rst-s);background-color:var(--rst);border:1px solid var(--rst-bc);overflow:hidden}sh-range-slider .track-filled{position:absolute;top:0;left:0;bottom:0;background:var(--rst-bg);width:0}sh-range-slider .min-indicator,sh-range-slider .max-indicator{white-space:nowrap;color:var(--rs-unit-c)}sh-range-slider input[type=range]:hover~.thumb-wrap .value-indicator,sh-range-slider input[type=range]:focus~.thumb-wrap .value-indicator{opacity:1}sh-range-slider .value-indicator{position:absolute;top:-1.875rem;height:1.5rem;min-width:1.5rem;border-radius:var(--shape-2);left:50%;margin:auto;transform:translate(-50%);padding:.25rem .5rem;background:var(--rs-thumb-value-bg);color:var(--rs-thumb-value-c);white-space:nowrap;opacity:0;transition:opacity 125ms linear;-webkit-user-select:none;user-select:none;pointer-events:none}sh-range-slider .value-indicator:after{content:"";border-top:.3125rem solid var(--rs-thumb-arrow);border-left:.3125rem solid transparent;border-right:.3125rem solid transparent;position:absolute;top:calc(100% - 1px);left:50%;margin-left:-.3125rem}sh-range-slider.primary{--rst-bg: var(--primary-8);--rs-thumb-arrow: var(--primary-8);--rs-thumb-value-bg: var(--primary-8);--rs-thumb-value-c: #fff}sh-range-slider.accent{--rst-bg: var(--accent-8);--rs-thumb-arrow: var(--accent-8);--rs-thumb-value-bg: var(--accent-8);--rs-thumb-value-c: #fff}sh-range-slider.warn{--rst-bg: var(--warn-8);--rs-thumb-arrow: var(--warn-8);--rs-thumb-value-bg: var(--warn-8);--rs-thumb-value-c: #fff}sh-range-slider.error{--rst-bg: var(--error-8);--rs-thumb-arrow: var(--error-8);--rs-thumb-value-bg: var(--error-8);--rs-thumb-value-c: #fff}sh-range-slider.success{--rst-bg: var(--success-8);--rs-thumb-arrow: var(--success-8);--rs-thumb-value-bg: var(--success-8);--rs-thumb-value-c: #fff}sh-range-slider.simple{--rst-h: 1rem;--rst-s: var(--shape-2)}sh-range-slider.simple .thumb{width:1px;height:var(--rst-h);margin-top:0;border-radius:0;border:none;box-shadow:none}sh-range-slider.simple.primary{--rst-bg: var(--primary-8);--rst: var(--primary-2);--rs-thumb-c: var(--primary-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--primary-8);--rs-thumb-value-c: var(--primary-2)}sh-range-slider.simple.accent{--rst-bg: var(--accent-8);--rst: var(--accent-2);--rs-thumb-c: var(--accent-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--accent-8);--rs-thumb-value-c: var(--accent-2)}sh-range-slider.simple.warn{--rst-bg: var(--warn-8);--rst: var(--warn-2);--rs-thumb-c: var(--warn-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--warn-8);--rs-thumb-value-c: var(--warn-2)}sh-range-slider.simple.error{--rst-bg: var(--error-8);--rst: var(--error-2);--rs-thumb-c: var(--error-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--error-8);--rs-thumb-value-c: var(--error-2)}sh-range-slider.simple.success{--rst-bg: var(--success-8);--rst: var(--success-2);--rs-thumb-c: var(--success-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--success-8);--rs-thumb-value-c: var(--success-2)}sh-range-slider.outlined{--rst: var(--base-1);--rst-bc: var(--base-4);--rs-thumb-c: var(--base-6);--rs-thumb-bc: var(--base-1);--rs-thumb-arrow: var(--base-4)}sh-range-slider.outlined.primary,sh-range-slider.outlined.accent,sh-range-slider.outlined.warn,sh-range-slider.outlined.error,sh-range-slider.outlined.success{--rst: var(--base-2)}sh-range-slider.outlined.primary{--rst-bg: var(--primary-4);--rst-bc: var(--primary-8);--rs-thumb-c: var(--primary-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--primary-4);--rs-thumb-value-c: var(--primary-8);--rs-thumb-arrow: var(--primary-4)}sh-range-slider.outlined.accent{--rs-thumb-c: var(--accent-4);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--accent-4);--rs-thumb-value-c: var(--accent-8);--rs-thumb-arrow: var(--accent-4)}sh-range-slider.outlined.warn{--rs-thumb-c: var(--warn-4);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--warn-4);--rs-thumb-value-c: var(--warn-8);--rs-thumb-arrow: var(--warn-4)}sh-range-slider.outlined.error{--rs-thumb-c: var(--error-4);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--error-4);--rs-thumb-value-c: var(--error-8);--rs-thumb-arrow: var(--error-4)}sh-range-slider.outlined.success{--rs-thumb-c: var(--success-4);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--success-4);--rs-thumb-value-c: var(--success-8);--rs-thumb-arrow: var(--success-4)}sh-range-slider.flat{--rs-thumb-c: #fff;--rs-thumb-bc: var(--base-4)}sh-range-slider.flat.primary,sh-range-slider.flat.accent,sh-range-slider.flat.warn,sh-range-slider.flat.error,sh-range-slider.flat.success{--rst: var(--base-3);--rs-thumb-c: #fff;--rs-thumb-bc: var(--base-4);--rs-thumb-value-bg: var(--base-8);--rs-thumb-value-c: #fff}sh-range-slider.flat.primary{--rst-bg: var(--primary-8);--rs-thumb-value-bg: var(--primary-8)}sh-range-slider.flat.accent{--rst-bg: var(--accent-8);--rs-thumb-value-bg: var(--accent-8)}sh-range-slider.flat.warn{--rst-bg: var(--warn-8);--rs-thumb-value-bg: var(--warn-8)}sh-range-slider.flat.error{--rst-bg: var(--error-8);--rs-thumb-value-bg: var(--error-8)}sh-range-slider.flat.success{--rst-bg: var(--success-8);--rs-thumb-value-bg: var(--success-8)}sh-range-slider.raised{--rst-bg: var(--base-g2);--rs-thumb-c: #fff;--rs-thumb-bc: var(--base-4)}sh-range-slider.raised.primary,sh-range-slider.raised.accent,sh-range-slider.raised.warn,sh-range-slider.raised.error,sh-range-slider.raised.success{--rst: var(--base-3);--rs-thumb-c: #fff;--rs-thumb-bc: var(--base-4);--rs-thumb-value-bg: var(--base-g6);--rs-thumb-value-c: #fff}sh-range-slider.raised.primary{--rst-bg: var(--primary-g2);--rs-thumb-arrow: var(--primary-8);--rs-thumb-value-bg: var(--primary-g3)}sh-range-slider.raised.accent{--rst-bg: var(--accent-g2);--rs-thumb-arrow: var(--accent-8);--rs-thumb-value-bg: var(--accent-8)}sh-range-slider.raised.warn{--rst-bg: var(--warn-g2);--rs-thumb-arrow: var(--warn-8);--rs-thumb-value-bg: var(--warn-8)}sh-range-slider.raised.error{--rst-bg: var(--error-g2);--rs-thumb-arrow: var(--error-8);--rs-thumb-value-bg: var(--error-8)}sh-range-slider.raised.success{--rst-bg: var(--success-g2);--rs-thumb-arrow: var(--success-8);--rs-thumb-value-bg: var(--success-8)}
|
|
2
|
-
`],encapsulation:2});}}return i})();var pn=["formRef"],En=()=>[import('./chunk-CSrYlKTK.js').then(i=>i.OptionsListComponent)];function mn(i,t){i&1&&(Zi(0,"sh-alert",3),oC(1,1),Wl());}function Nn(i,t){if(i&1){let e=ET();Zi(0,"app-options-list",5),lm("optionsChange",function(a){Pd(e);let l=aC();return qC(l.settings,a)||(l.settings=a),Ld(a)}),Wl();}if(i&2){let e=aC();cm("options",e.settings),vg("hasFreeTextSettings",true);}}var K=class i{#n=T(R);#i=T(J$1);formRef=w1.required("formRef");settings=Ge([]);isSubmitting=Ge(false);isLoadingOptions=Ge(true);saved=Ge(false);lastRecievedServerSettings=Ge({});serverSettingsEffect=Qa(()=>{let t=this.#n.serverSettings();if(t===void 0)return;this.lastRecievedServerSettings.set(t),this.isLoadingOptions.set(true);let e=Object.entries(t);e.forEach(([n,a],l)=>{if(n.startsWith("--")){let m=n.substring(2);this.settings.update(u=>(u.some(E=>E.Name===m||E.Name===n)||u.push({Name:n,Value:a}),u));}l===e.length-1&&this.isLoadingOptions.set(false);});});submit(){this.isSubmitting.set(true);let t=this.settings(),e=this.lastRecievedServerSettings(),n=t.map(u=>u.Name?.startsWith("--")?u.Name:`--${u.Name}`),l=Object.keys(e).filter(u=>u.startsWith("--")).filter(u=>!n.includes(u)),m=t.reduce((u,E)=>{let f=E.Name?.startsWith("--")?E.Name:`--${E.Name}`;return u[f]=E.Value,u},{});l.forEach(u=>{m[u]=null;}),sy(()=>this.#i.patchApiV1Serversettings({body:m})).pipe(Zu(()=>this.isSubmitting.set(false))).subscribe({next:()=>{this.#n.refreshServerSettings(),this.saved.set(true),setTimeout(()=>{this.saved.set(false);},3e3);}});}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=gw({type:i,selectors:[["app-advanced-options-settings"]],viewQuery:function(e,n){e&1&&qg(n.formRef,pn,5),e&2&&hC();},decls:8,vars:4,consts:()=>{let t;t=$localize`${"\uFFFD#4\uFFFD"}:START_TAG_SH_ICON:floppy-disk${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_SH_ICON: Save settings `;let e;return e=$localize`Settings saved`,[t,e,[1,"actions"],[1,"success"],["shButton","","type","button",1,"raised","primary",3,"click"],[3,"optionsChange","options","hasFreeTextSettings"]]},template:function(e,n){e&1&&(Zi(0,"div",2),lT(1,mn,2,0,"sh-alert",3),Zi(2,"button",4),Hg("click",function(){return n.submit()}),Fg(3,0),Ig(4,"sh-icon"),jg(),Wl()(),lg(5,Nn,1,2),sT(6,5,En)),e&2&&(bE(),uT(n.saved()?1:-1),bE(),Kg("loading",n.isSubmitting()),bE(4),aT(!n.isLoadingOptions()));},dependencies:[Gn$1,v$1,N,ue],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:40.625rem;justify-self:flex-end}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;justify-content:flex-end;margin-bottom:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-wrap[_ngcontent-%COMP%]{display:grid;grid-template-columns:2fr 2.5rem;gap:.5rem;align-items:flex-end}.remote-volume-wrap[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.remote-volume-wrap[_ngcontent-%COMP%] p.warning[_ngcontent-%COMP%]{color:#7d7d00}.row-inputs[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.5rem}.row-inputs[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{flex:1 0}.advanced-option[_ngcontent-%COMP%]{display:grid;gap:.5rem;grid-template-columns:1fr 1fr 2.5rem;align-items:flex-end}"]})};function fn(i,t){if(i&1){let e=ET();Zi(0,"sh-form-field",12)(1,"input",13),lm("ngModelChange",function(a){Pd(e);let l=aC(2);return qC(l.registerUrl,a)||(l.registerUrl=a),Ld(a)}),Wl(),bD(),Wl(),Zi(2,"button",14),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.register())}),oC(3,0),Wl();}if(i&2){let e=aC(2);bE(),cm("ngModel",e.registerUrl),MD();}}function In(i,t){if(i&1&&(Zi(0,"div",9)(1,"label"),oC(2,1),Wl(),Zi(3,"a",15),HC(4),Wl()()),i&2){let e=aC(2);bE(3),vg("href",QC(e.claimUrl()),Yp),bE(),im(e.claimUrl());}}function Mn(i,t){i&1&&(Zi(0,"div",9)(1,"label"),oC(2,2),Wl()());}function Pn(i,t){if(i&1){let e=ET();Zi(0,"button",14),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.cancel())}),oC(1,3),Wl();}}function On(i,t){if(i&1){let e=ET();Zi(0,"button",14),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.disable())}),oC(1,4),Wl();}}function bn(i,t){if(i&1){let e=ET();Zi(0,"button",14),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.enable())}),oC(1,5),Wl(),Zi(2,"button",16),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.delete())}),oC(3,6),Wl();}}function Rn(i,t){i&1&&(Fg(0,7,1),Ig(1,"sh-icon"),jg());}function Gn(i,t){i&1&&(Fg(0,7,2),Ig(1,"sh-icon"),jg());}function vn(i,t){if(i&1){let e=ET();Zi(0,"sh-chip",17),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.copyReportingUrl())}),Fg(1,7),lT(2,Rn,2,0,"sh-icon")(3,Gn,2,0,"sh-icon"),jg(),Wl();}if(i&2){let e=aC(2);bE(2),uT(e.copiedReportingUrl()===true?2:3);}}function yn(i,t){if(i&1&&(Zi(0,"div",8),lT(1,fn,4,1),lT(2,In,5,3,"div",9),lT(3,Mn,3,0,"div",9),lT(4,Pn,2,0,"button",10),lT(5,On,2,0,"button",10),lT(6,bn,4,0),lT(7,vn,4,1,"sh-chip",11),Wl()),i&2){let e=aC();bE(),uT(e.state()==="inactive"?1:-1),bE(),uT(e.state()==="registered"?2:-1),bE(),uT(e.state()==="registering"?3:-1),bE(),uT(e.state()==="registering"||e.state()==="registeringfaulted"||e.state()==="registered"?4:-1),bE(),uT(e.state()==="connected"||e.state()==="connecting"?5:-1),bE(),uT(e.state()==="disabled"?6:-1),bE(),uT(e.additionalReportingUrl()!==""&&e.state()!=="registered"?7:-1);}}var Se=class i{#n=T(v);#i=T(R);state=this.#n.state;claimUrl=this.#n.claimUrl;registerUrl=this.#n.registerUrl;additionalReportingUrl=Nt(()=>{let t=this.#i.serverSettings();return t&&t["additional-report-url"]||""});copiedReportingUrl=Ge(false);ngOnInit(){this.#n.refreshRemoteControlStatus();}cancel(){this.#n.cancelRemoteRegistration();}register(){this.#n.beginRemoteRegistration();}disable(){this.#n.disableRemoteControl();}enable(){this.#n.enableRemoteControl();}delete(){this.#n.deleteRemoteControl();}copyReportingUrl(){let t=this.additionalReportingUrl();t&&(this.copiedReportingUrl.set(true),setTimeout(()=>this.copiedReportingUrl.set(false),2e3),navigator.clipboard.writeText(t));}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=gw({type:i,selectors:[["app-remote-control"]],decls:1,vars:1,consts:()=>{let t;t=$localize`Register on console`;let e;e=$localize`Machine is now registered, open this link to add it to your account:`;let n;n=$localize`Registering, please wait...`;let a;a=$localize`Cancel registration`;let l;l=$localize`Disable console connection`;let m;m=$localize`Enable console connection`;let u;u=$localize` Delete console connection setup `;let E;return E=$localize` Reporting configured by server ${"\uFFFD*2:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:check${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*2:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*3:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:copy${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*3:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,E=sC(E),[t,e,n,a,l,m,u,E,[1,"field-row"],[1,"field-col"],["type","button","shButton","",1,"raised"],[1,"reporting-url","primary","simple"],["label","Registration URL","for","remoteControlRegisterUrl"],["type","text","sh-input","","id","remoteControlRegisterUrl","name","remoteControlRegisterUrl",3,"ngModelChange","ngModel"],["type","button","shButton","",1,"raised",3,"click"],["target","_blank",3,"href"],["type","button","shButton","",1,"raised","error",3,"click"],[1,"reporting-url","primary","simple",3,"click"]]},template:function(e,n){e&1&&lT(0,yn,8,7,"div",8),e&2&&uT(n.state()!=="unknown"?0:-1);},dependencies:[Bn$1,Ze,Rn$1,Jt,Fe,v$1,D,N],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] button[_ngcontent-%COMP%]{white-space:nowrap}.field-row[_ngcontent-%COMP%]{display:flex;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] 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}"]})};var fe=[{value:"default",label:$localize`System default ($value)`},{value:"information",label:$localize`Usage statistics, warnings, errors, and crashes`},{value:"warning",label:$localize`Warnings, errors and crashes`},{value:"error",label:$localize`Errors and crashes`},{value:"crash",label:$localize`Crashes only`},{value:"none",label:$localize`None / disabled`}],Fn=new Set(["information","warning","error","crash","none"]),Tn=i=>{let t=(i??"").trim().toLowerCase();return t==="disabled"?"none":Fn.has(t)?t:"default"},un=i=>i==="default"?"":i;var Te=()=>({standalone:true});function $n(i,t){i&1&&(Zi(0,"sh-chip",97),oC(1,35),Wl());}function An(i,t){if(i&1&&(Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,34),Wl(),Zi(4,"p"),HC(5),Wl()(),Zi(6,"div",74),lT(7,$n,2,0,"sh-chip",97),Wl()()),i&2){let e=aC();bE(5),im(e.remoteControlStatus()),bE(2),uT(e.additionalReportingUrl()!==""&&e.remoteControlState()!=="registered"?7:-1);}}function Ln(i,t){if(i&1&&(Zi(0,"label"),Fg(1,39),Ig(2,"sh-icon",98),jg(),Wl()),i&2){let e=aC(3);bE(2),vg("shTooltip",e.remoteControlTooltip());}}function wn(i,t){if(i&1&&(Zi(0,"label"),Fg(1,40),Ig(2,"sh-icon",98),jg(),Wl()),i&2){let e=aC(3);bE(2),vg("shTooltip",e.remoteControlTooltip());}}function Dn(i,t){if(i&1&&(Zi(0,"label"),Fg(1,41),Ig(2,"sh-icon",98),jg(),Wl()),i&2){let e=aC(3);bE(2),vg("shTooltip",e.connectionStatusIndicatorTooltip());}}function xn(i,t){if(i&1&&(Zi(0,"label"),Fg(1,42),Ig(2,"sh-icon",98),jg(),Wl()),i&2){let e=aC(3);bE(2),vg("shTooltip",e.connectionStatusIndicatorTooltip());}}function kn(i,t){if(i&1){let e=ET();Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,37),Wl(),Zi(4,"p"),oC(5,38),Wl()(),Zi(6,"div",82)(7,"sh-toggle",83),Hg("checkedChange",function(a){Pd(e);let l=aC(2);return Ld(l.toggleConsoleControl(a))}),lT(8,Ln,3,1,"label")(9,wn,3,1,"label"),Wl(),Zi(10,"sh-toggle",83),Hg("checkedChange",function(a){Pd(e);let l=aC(2);return Ld(l.saveHideConsoleConnectionStatus(a))}),lT(11,Dn,3,1,"label")(12,xn,3,1,"label"),Wl()()();}if(i&2){let e=aC(2);bE(7),vg("checked",!e.consoleControlDisabled()),bE(),uT(e.consoleControlDisabled()?8:9),bE(2),vg("checked",!e.hideConsoleConnectionStatus()),bE(),uT(e.hideConsoleConnectionStatus()?11:12);}}function Xn(i,t){i&1&&(Zi(0,"label"),oC(1,45),Wl());}function Jn(i,t){i&1&&(Zi(0,"label"),oC(1,46),Wl());}function Vn(i,t){if(i&1){let e=ET();Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,43),Wl(),Zi(4,"p"),oC(5,44),Wl()(),Zi(6,"div",74)(7,"sh-toggle",83),Hg("checkedChange",function(a){Pd(e);let l=aC(2);return Ld(l.saveHideConsoleConnectionStatus(a))}),lT(8,Xn,2,0,"label")(9,Jn,2,0,"label"),Wl()()();}if(i&2){let e=aC(2);bE(7),vg("checked",!e.hideConsoleConnectionStatus()),bE(),uT(e.hideConsoleConnectionStatus()?8:9);}}function zn(i,t){if(i&1&&(Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,36),Wl(),Zi(4,"p"),HC(5),Wl()(),Zi(6,"div",74),Ig(7,"app-remote-control"),Wl()(),lT(8,kn,13,4,"section")(9,Vn,10,2,"section")),i&2){let e=aC();bE(5),im(e.remoteControlStatus()),bE(3),uT(e.remoteControlState()!="inactive"?8:9);}}function Un(i,t){i&1&&(Zi(0,"sh-icon",103),HC(1,"check"),Wl());}function Bn(i,t){i&1&&(Zi(0,"sh-icon",104),HC(1,"prohibit"),Wl());}function Hn(i,t){if(i&1){let e=ET();Zi(0,"button",108),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.updatePassphrase())}),oC(1,50),Wl();}if(i&2){let e=aC(2);Kg("loading",e.isUpdating());}}function Wn(i,t){if(i&1){let e=ET();Zi(0,"button",109),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.updatePassphrase())}),oC(1,51),Wl();}if(i&2){let e=aC(2);Kg("loading",e.isUpdating()),vg("disabled",true);}}function jn(i,t){if(i&1){let e=ET();Zi(0,"sh-form-field")(1,"label",99),oC(2,47),Wl(),Zi(3,"input",100),lm("ngModelChange",function(a){Pd(e);let l=aC();return qC(l.passphrase,a)||(l.passphrase=a),Ld(a)}),Wl(),bD(),Wl(),Zi(4,"sh-form-field")(5,"label",101),oC(6,48),Wl(),Zi(7,"input",102),lm("ngModelChange",function(a){Pd(e);let l=aC();return qC(l.repeatPassphrase,a)||(l.repeatPassphrase=a),Ld(a)}),Wl(),bD(),lT(8,Un,2,0,"sh-icon",103)(9,Bn,2,0,"sh-icon",104),Wl(),Zi(10,"div",79)(11,"button",105),Hg("click",function(){Pd(e);let a=aC();return Ld(a.cancelPasswordChange())}),oC(12,49),Wl(),lT(13,Hn,2,2,"button",106)(14,Wn,2,3,"button",107),Wl();}if(i&2){let e=aC();bE(3),cm("ngModel",e.passphrase),MD(),bE(4),vg("disabled",e.passphrase().length===0),cm("ngModel",e.repeatPassphrase),MD(),bE(),uT(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?8:9),bE(3),Kg("loading",e.isUpdating()),bE(2),uT(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?13:14);}}function qn(i,t){i&1&&(Zi(0,"sh-icon",110),HC(1,"check"),Wl());}function Kn(i,t){if(i&1){let e=ET();Zi(0,"div",79)(1,"button",105),Hg("click",function(){Pd(e);let a=aC();return Ld(a.openPassphraseForm())}),oC(2,52),Wl(),lT(3,qn,2,0,"sh-icon",110),Wl();}if(i&2){let e=aC();bE(3),uT(e.passwordUpdated()?3:-1);}}function Qn(i,t){i&1&&(Zi(0,"label"),oC(1,53),Wl());}function Yn(i,t){i&1&&(Zi(0,"label"),oC(1,54),Wl());}function Zn(i,t){i&1&&(Zi(0,"label"),oC(1,55),Wl());}function ei(i,t){i&1&&(Zi(0,"label"),oC(1,56),Wl());}function ti(i,t){i&1&&(Fg(0,13,1),Ig(1,"span"),jg());}function ni(i,t){i&1&&(Fg(0,13,2),Ig(1,"span"),jg());}function ii(i,t){if(i&1){let e=ET();Zi(0,"sh-form-field")(1,"label",111),oC(2,57),Wl(),Zi(3,"textarea",112),lm("ngModelChange",function(a){Pd(e);let l=aC();return qC(l.allowedHostnames,a)||(l.allowedHostnames=a),Ld(a)}),Wl(),bD(),Wl(),Zi(4,"sh-alert",113),oC(5,58),Wl(),Zi(6,"button",108),Hg("click",function(){Pd(e);let a=aC();return Ld(a.updateAllowedHostnames())}),oC(7,59),Wl();}if(i&2){let e=aC();bE(3),cm("ngModel",e.allowedHostnames),MD(),bE(3),Kg("loading",e.updatingAllowedHosts());}}function oi(i,t){if(i&1){let e=ET();Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,60),Wl(),Zi(4,"p"),oC(5,61),Wl()(),Zi(6,"div",74)(7,"sh-select",114)(8,"input",81),Hg("ngModelChange",function(a){Pd(e);let l=aC();return Ld(l.updatePowerMode(a))}),Wl(),bD(),Wl()()();}if(i&2){let e=aC();bE(7),vg("options",e.powerModeOptions())("isClearable",false),bE(),vg("ngModel",e.powerModeCtrl())("ngModelOptions",XC(4,Te)),MD();}}function si(i,t){if(i&1&&(Zi(0,"p"),oC(1,62),Wl()),i&2){let e=aC();bE(),Vg(e.sysinfo()?.ServerVersionName),iC(1);}}function ai(i,t){i&1&&Ig(0,"sh-progress-bar",87);}function ri(i,t){if(i&1&&HC(0),i&2){let e=t.$implicit;Yl(" ",e.label," ");}}function li(i,t){if(i&1&&HC(0),i&2){let e=t.$implicit;Yl(" ",e.label," ");}}function _i(i,t){if(i&1){let e=ET();Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,63),Wl(),Zi(4,"p")(5,"span"),oC(6,64),Wl(),Zi(7,"a",115),oC(8,65),Wl(),Ig(9,"br")(10,"br"),Zi(11,"span"),oC(12,66),Wl()()(),Zi(13,"div",74)(14,"sh-select",116)(15,"input",81),Hg("ngModelChange",function(a){Pd(e);let l=aC();return Ld(l.updateUsageStatistics(a))}),Wl(),bD(),cg(16,li,1,1,"ng-template"),Wl()()();}if(i&2){let e=aC();bE(14),vg("options",e.usageStatisticsOptions())("isLoading",e.updatingUsageStatistics()),bE(),vg("ngModel",e.usageStatistics())("ngModelOptions",XC(4,Te)),MD();}}function ci(i,t){i&1&&(Zi(0,"label"),oC(1,69),Wl());}function di(i,t){i&1&&(Zi(0,"label"),oC(1,70),Wl());}function Si(i,t){if(i&1){let e=ET();Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,67),Wl(),Zi(4,"p"),oC(5,68),Wl()(),Zi(6,"div",82)(7,"p"),HC(8,"Backup process isolation"),Wl(),Zi(9,"sh-toggle",83),Hg("checkedChange",function(a){Pd(e);let l=aC();return Ld(l.saveControllerIpcState(a))}),lT(10,ci,2,0,"label")(11,di,2,0,"label"),Wl()()();}if(i&2){let e=aC();bE(9),vg("checked",e.isControllerIpcEnabled()),bE(),uT(e.isControllerIpcEnabled()?10:11);}}function Ti(i,t,e){let[n]=Ms(i,e?.equal),a=n,l=n[j],m;return a.set=u=>{clearTimeout(m),m=setTimeout(()=>{ft(l,u);},t);},a.update=u=>{clearTimeout(m),m=setTimeout(()=>{go(l,u);},t);},a}var ui=[{value:"none",label:$localize`None`},{value:"s",label:$localize`Seconds`},{value:"m",label:$localize`Minutes`},{value:"h",label:$localize`Hours`}],Ie=class i{#n=T(be);#i=T(m);#e=T(f);#t=T(R);#s=T(v);#r=T(I);#o=T(r);#a=T(f$1);#_=this.#a.getItem("locale")??"en-US";sysinfo=this.#e.systemInfo;isDarkMode=this.#i.isDarkMode;editAs=Ge("list");previousLang=this.#_;langCtrl=Ge(this.#_);powerModeCtrl=Ge("");usageStatistics=Ge("default");updatingUsageStatistics=Ge(false);remoteControlStatus=this.#s.statusMessage;remoteControlState=this.#s.state;updatingChannel=Ge(false);updateChannel=Ge("");isUsingRelay=this.#r.relayIsEnabled;defaultClient=Ge(this.#S());hasIpcController=this.#e.hasIpcController;usageStatisticsDisabled=Nt(()=>(this.#e.systemInfo()?.DefaultUsageReportLevel??"").toLowerCase()==="disabled");additionalReportingUrl=Nt(()=>{let t=this.#t.serverSettings();return t&&t["additional-report-url"]||""});#T=Qa(()=>{let t=this.#e.systemInfo()?.DefaultUsageReportLevel??"",e=fe;e[0].label=$localize`System default (${t})`,this.usageStatisticsOptions.set(e);});remoteControlTooltip=Ge($localize`Disabling console control will disable remote access to this machine from the console, but will keep the
|
|
1
|
+
import {t as te}from'./chunk-Ied7KwvV.js';import'./chunk-CNwmuSlJ.js';import {O}from'./chunk-B20GDhu-.js';import {m}from'./chunk-2QKZNH3T.js';import {r}from'./chunk-1DRz_1dv.js';import {J}from'./chunk-BmOgPfpY.js';import'./chunk-CaQaYVo7.js';import {N as Nt$1}from'./chunk-B5S2d_Pm.js';import {c}from'./chunk-CZu3210D.js';import {D}from'./chunk-DF2Ac802.js';import {c1 as Ms,c2 as j,c3 as ft,c4 as go,T,a6 as be,f,I,c5 as f$1,G as Ge,N as Nt,Q as Qa,C as Zu,c6 as wt,au as h,g as gw,v as v$1,a as N,u as ue,d as Ig,Z as Zi,o as oC,W as Wl,l as lT,w as Hg,t as bD,F as Fg,j as jg,n as lm,b4 as cg,b as bE,c as uT,K as Kg,z as vg,a3 as XC,M as MD,av as Vg,aw as iC,y as cm,s as sC,p as qC,ab as J$1,B as w1,ad as sy,b7 as lg,b8 as sT,b9 as aT,O as qg,R as hC,af as eo,E as E1,ag as D1,bd as ce,S as lC,U as ql,Y as uC,X as Gl,H as HC,ao as Bg,V as Eg,aD as sm,ah as Yg,x as xC,h as aC,J as im,i as ET,P as Pd,L as Ld,as as Yp,a9 as QC,aa as Yl}from'./main-X6MUEPX4.js';import {d}from'./chunk-C8Zr0vl3.js';import {F as Fe}from'./chunk-Be4WXTyA.js';import {B as Bn$1,Z as Ze,o as on,R as Rn$1,J as Jt,G as Gn$1}from'./chunk-Bfg1Kjif.js';import {a as at}from'./chunk-BxBZMjtQ.js';import {v}from'./chunk-qUlwoHQn.js';import {R}from'./chunk-Dn7TWCfq.js';import'./chunk-CUo9Jt8-.js';import'./chunk-DM-zhIVI.js';var gn=[[["label"]],[["input","type","range"]]],Cn=["label","input[type=range]"],dn=(()=>{class i{constructor(){this.hasInput=Ge(false),this.#n=T(eo),this.#i=null,this.#e=null,this.#t=0,this.unit=E1(""),this.value=D1(this.#t),this.inputState=Ge({min:0,max:100,step:1}),this.color=E1(null),this.variant=E1(null),this.size=E1(null),this.sharp=E1(void 0),this.alwaysShow=E1(void 0),this.hostClasses=ce("rangeSlider",{color:this.color,variant:this.variant,size:this.size,sharp:this.sharp,alwaysShow:this.alwaysShow}),this.valuePercentage=Nt(()=>{let{min:e,max:n}=this.inputState(),a=this.value()??e;if(isNaN(a))return 0;let l=n-e;if(l===0)return 0;let m=(a-e)/l*100;return Math.max(0,Math.min(100,m))}),this.trackFilledPercentage=Nt(()=>this.valuePercentage()),this.thumbPositionPercentage=Nt(()=>this.valuePercentage()),this.syncModelToInputEffect=Qa(()=>{let e=this.value();if(this.#e){let n=parseFloat(this.#e.value);(isNaN(n)||String(n)!==String(e))&&(this.#e.value=String(e));}});}#n;#i;#e;#t;ngAfterViewInit(){this.#e=this.#n.nativeElement.querySelector('input[type="range"]'),this.#e?(this.hasInput.set(true),this.#a(this.#e),this.#e.oninput=()=>{this.setNewInputValue(this.#e.value);},this.#e.addEventListener("inputValueChanged",e=>{this.setNewInputValue(e.detail.value);}),queueMicrotask(()=>this.#s(true)),this.#r()):console.error('ShipRangeSlider: No <input type="range"> element found projected inside.');}setNewInputValue(e){let n=parseFloat(e??"0");if(!isNaN(n)){let{min:a,max:l}=this.inputState();this.value.set(Math.max(a,Math.min(l,n)));}}trackEvent(e){if(!this.#e||this.#e.readOnly||this.#e.disabled){e.preventDefault(),e.stopPropagation();return}if(e.target===this.#e||e.target?.closest(".thumb, .min-indicator, .max-indicator"))return;let a=e.currentTarget.getBoundingClientRect(),l=e.clientX-a.left,m=a.width,{min:u,max:E,step:f}=this.inputState(),W=E-u;if(m>0&&W!==0&&f>0){let Q=(l/m*W+u-u)/f,J=u+Math.round(Q)*f,V=this.#o(f);J=parseFloat(J.toFixed(V));let Y=Math.max(u,Math.min(E,J));this.value.set(Y);}}#s(e=false){if(!this.#e)return;let n=parseFloat(this.#e.min??"0")??0,a=parseFloat(this.#e.max??"100")??100,l=this.#e.step,m=1;if(l&&l.toLowerCase()!=="any"){let E=parseFloat(l);!isNaN(E)&&E>0&&(m=E);}this.inputState.set({min:n,max:a,step:m});let u=parseFloat(this.#e.value??String(n))??n;if(e&&this.value()!==this.#t){let E=this.value(),f=Math.max(n,Math.min(a,E));u!==f&&(this.#e.value=String(f)),E!==f&&this.value.set(f);}else {let E=Math.max(n,Math.min(a,u));this.value()!==E&&this.value.set(E);}}#r(){if(!this.#e||typeof MutationObserver>"u")return;let e=["min","max","step","value","readonly","disabled"];this.#i=new MutationObserver(n=>{let a=false;for(let l of n)if(l.type==="attributes"&&e.includes(l.attributeName??"")){a=true;break}a&&this.#s(false);}),this.#i.observe(this.#e,{attributes:true,attributeFilter:e});}#o(e){if(isNaN(e)||Math.floor(e)===e)return 0;let a=e.toString().split(".")[1];return a?a.length:0}#a(e){Object.defineProperty(e,"value",{configurable:true,get(){return Object.getOwnPropertyDescriptor(Object.getPrototypeOf(e),"value").get.call(this)},set(n){Object.getOwnPropertyDescriptor(Object.getPrototypeOf(e),"value").set.call(this,n);let l=new CustomEvent("inputValueChanged",{bubbles:true,cancelable:true,detail:{value:n}});return this.dispatchEvent(l),n}});}ngOnDestroy(){this.#i&&this.#i.disconnect(),this.#e&&(this.#e.oninput=null);}static{this.\u0275fac=function(n){return new(n||i)};}static{this.\u0275cmp=gw({type:i,selectors:[["sh-range-slider"]],hostVars:6,hostBindings:function(n,a){n&2&&(xC(a.hostClasses()),Kg("sh-range-slider",true)("has-input",a.hasInput()));},inputs:{unit:[1,"unit"],value:[1,"value"],color:[1,"color"],variant:[1,"variant"],size:[1,"size"],sharp:[1,"sharp"],alwaysShow:[1,"alwaysShow"]},outputs:{value:"valueChange"},ngContentSelectors:Cn,decls:15,vars:10,consts:[[1,"label"],[1,"input-wrap"],[1,"min-indicator"],[1,"track-wrap",3,"click"],[1,"track"],[1,"track-filled"],[1,"thumb-wrap"],[1,"thumb"],[1,"value-indicator"],[1,"max-indicator"]],template:function(n,a){n&1&&(lC(gn),ql(0,"div",0),uC(1),Gl(),ql(2,"div",1)(3,"div",2),HC(4),Gl(),ql(5,"div",3),Bg("click",function(m){return a.trackEvent(m)}),uC(6,1),ql(7,"div",4),Eg(8,"div",5),Gl(),ql(9,"div",6)(10,"div",7)(11,"div",8),HC(12),Gl()()()(),ql(13,"div",9),HC(14),Gl()()),n&2&&(bE(4),sm("",a.inputState().min,"",a.unit()),bE(4),Yg("width",a.trackFilledPercentage(),"%"),bE(),Yg("left",a.thumbPositionPercentage(),"%"),bE(3),sm("",a.value(),"",a.unit()),bE(2),sm("",a.inputState().max,"",a.unit()));},styles:[`sh-range-slider{--rs-h: 2.5rem;--rs-f: var(--paragraph-30);--rs-unit-g: .75rem;--rs-unit-c: var(--base-8);--rst: var(--base-3);--rst-bc: var(--base-1);--rst-bg: var(--base-4);--rst-h: .5rem;--rst-s: calc(var(--shape-2) / 2);--rs-thumb-c: var(--base-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--base-4);--rs-thumb-arrow: var(--rs-thumb-value-bg);--rs-thumb-value-c: var(--base-8);--rs-thumb-si: 1rem;--rs-thumb-w: var(--rs-thumb-si);--rs-thumb-s: calc(var(--rs-thumb-w) / 2);display:flex;flex-direction:column;width:100%;font:var(--rs-f)}sh-range-slider.sharp{--rst-s: .125rem;--rs-thumb-s: .125rem;--rs-thumb-bc: transparent !important}sh-range-slider .label{display:flex;align-items:center;gap:.5rem;padding-bottom:.25rem}sh-range-slider .label>label{display:flex;align-items:center;gap:.25rem}sh-range-slider .label sh-icon{color:var(--grey-500);font-size:1rem}sh-range-slider .label:empty{display:none}sh-range-slider[readonly]:not([readonly=false]),sh-range-slider:has(input[type=range][readonly]:not([readonly=false])),sh-range-slider[disabled]:not([disabled=false]),sh-range-slider:has(input[type=range][disabled]:not([disabled=false])){opacity:.4;pointer-events:none;-webkit-user-select:none;user-select:none;cursor:initial}sh-range-slider:has(input[type=range][readonly]) .thumb .value-indicator,sh-range-slider.always-show .thumb .value-indicator{opacity:1}sh-range-slider input[type=range]{appearance:none;width:100%;height:100%;position:absolute;inset:0;opacity:0;margin:0;z-index:1000}sh-range-slider .input-wrap{display:flex;align-items:center;justify-content:center;width:100%;min-height:var(--rs-h);position:relative;gap:var(--rs-unit-g)}sh-range-slider .thumb-wrap{position:absolute;top:0}sh-range-slider .thumb{position:relative;margin-top:calc(-1 * var(--rs-thumb-si) / 4);width:var(--rs-thumb-w);height:var(--rs-thumb-si);border-radius:var(--rs-thumb-s);background-color:var(--rs-thumb-c);border:1px solid var(--rs-thumb-bc);box-shadow:var(--box-shadow-20);transform:translate(-50%)}sh-range-slider .track-wrap{position:relative;width:100%;height:var(--rst-h)}sh-range-slider .track{position:relative;width:100%;height:var(--rst-h);border-radius:var(--rst-s);background-color:var(--rst);border:1px solid var(--rst-bc);overflow:hidden}sh-range-slider .track-filled{position:absolute;top:0;left:0;bottom:0;background:var(--rst-bg);width:0}sh-range-slider .min-indicator,sh-range-slider .max-indicator{white-space:nowrap;color:var(--rs-unit-c)}sh-range-slider input[type=range]:hover~.thumb-wrap .value-indicator,sh-range-slider input[type=range]:focus~.thumb-wrap .value-indicator{opacity:1}sh-range-slider .value-indicator{position:absolute;top:-1.875rem;height:1.5rem;min-width:1.5rem;border-radius:var(--shape-2);left:50%;margin:auto;transform:translate(-50%);padding:.25rem .5rem;background:var(--rs-thumb-value-bg);color:var(--rs-thumb-value-c);white-space:nowrap;opacity:0;transition:opacity 125ms linear;-webkit-user-select:none;user-select:none;pointer-events:none}sh-range-slider .value-indicator:after{content:"";border-top:.3125rem solid var(--rs-thumb-arrow);border-left:.3125rem solid transparent;border-right:.3125rem solid transparent;position:absolute;top:calc(100% - 1px);left:50%;margin-left:-.3125rem}sh-range-slider.primary{--rst-bg: var(--primary-8);--rs-thumb-arrow: var(--primary-8);--rs-thumb-value-bg: var(--primary-8);--rs-thumb-value-c: #fff}sh-range-slider.accent{--rst-bg: var(--accent-8);--rs-thumb-arrow: var(--accent-8);--rs-thumb-value-bg: var(--accent-8);--rs-thumb-value-c: #fff}sh-range-slider.warn{--rst-bg: var(--warn-8);--rs-thumb-arrow: var(--warn-8);--rs-thumb-value-bg: var(--warn-8);--rs-thumb-value-c: #fff}sh-range-slider.error{--rst-bg: var(--error-8);--rs-thumb-arrow: var(--error-8);--rs-thumb-value-bg: var(--error-8);--rs-thumb-value-c: #fff}sh-range-slider.success{--rst-bg: var(--success-8);--rs-thumb-arrow: var(--success-8);--rs-thumb-value-bg: var(--success-8);--rs-thumb-value-c: #fff}sh-range-slider.simple{--rst-h: 1rem;--rst-s: var(--shape-2)}sh-range-slider.simple .thumb{width:1px;height:var(--rst-h);margin-top:0;border-radius:0;border:none;box-shadow:none}sh-range-slider.simple.primary{--rst-bg: var(--primary-8);--rst: var(--primary-2);--rs-thumb-c: var(--primary-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--primary-8);--rs-thumb-value-c: var(--primary-2)}sh-range-slider.simple.accent{--rst-bg: var(--accent-8);--rst: var(--accent-2);--rs-thumb-c: var(--accent-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--accent-8);--rs-thumb-value-c: var(--accent-2)}sh-range-slider.simple.warn{--rst-bg: var(--warn-8);--rst: var(--warn-2);--rs-thumb-c: var(--warn-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--warn-8);--rs-thumb-value-c: var(--warn-2)}sh-range-slider.simple.error{--rst-bg: var(--error-8);--rst: var(--error-2);--rs-thumb-c: var(--error-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--error-8);--rs-thumb-value-c: var(--error-2)}sh-range-slider.simple.success{--rst-bg: var(--success-8);--rst: var(--success-2);--rs-thumb-c: var(--success-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--success-8);--rs-thumb-value-c: var(--success-2)}sh-range-slider.outlined{--rst: var(--base-1);--rst-bc: var(--base-4);--rs-thumb-c: var(--base-6);--rs-thumb-bc: var(--base-1);--rs-thumb-arrow: var(--base-4)}sh-range-slider.outlined.primary,sh-range-slider.outlined.accent,sh-range-slider.outlined.warn,sh-range-slider.outlined.error,sh-range-slider.outlined.success{--rst: var(--base-2)}sh-range-slider.outlined.primary{--rst-bg: var(--primary-4);--rst-bc: var(--primary-8);--rs-thumb-c: var(--primary-8);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--primary-4);--rs-thumb-value-c: var(--primary-8);--rs-thumb-arrow: var(--primary-4)}sh-range-slider.outlined.accent{--rs-thumb-c: var(--accent-4);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--accent-4);--rs-thumb-value-c: var(--accent-8);--rs-thumb-arrow: var(--accent-4)}sh-range-slider.outlined.warn{--rs-thumb-c: var(--warn-4);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--warn-4);--rs-thumb-value-c: var(--warn-8);--rs-thumb-arrow: var(--warn-4)}sh-range-slider.outlined.error{--rs-thumb-c: var(--error-4);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--error-4);--rs-thumb-value-c: var(--error-8);--rs-thumb-arrow: var(--error-4)}sh-range-slider.outlined.success{--rs-thumb-c: var(--success-4);--rs-thumb-bc: var(--base-1);--rs-thumb-value-bg: var(--success-4);--rs-thumb-value-c: var(--success-8);--rs-thumb-arrow: var(--success-4)}sh-range-slider.flat{--rs-thumb-c: #fff;--rs-thumb-bc: var(--base-4)}sh-range-slider.flat.primary,sh-range-slider.flat.accent,sh-range-slider.flat.warn,sh-range-slider.flat.error,sh-range-slider.flat.success{--rst: var(--base-3);--rs-thumb-c: #fff;--rs-thumb-bc: var(--base-4);--rs-thumb-value-bg: var(--base-8);--rs-thumb-value-c: #fff}sh-range-slider.flat.primary{--rst-bg: var(--primary-8);--rs-thumb-value-bg: var(--primary-8)}sh-range-slider.flat.accent{--rst-bg: var(--accent-8);--rs-thumb-value-bg: var(--accent-8)}sh-range-slider.flat.warn{--rst-bg: var(--warn-8);--rs-thumb-value-bg: var(--warn-8)}sh-range-slider.flat.error{--rst-bg: var(--error-8);--rs-thumb-value-bg: var(--error-8)}sh-range-slider.flat.success{--rst-bg: var(--success-8);--rs-thumb-value-bg: var(--success-8)}sh-range-slider.raised{--rst-bg: var(--base-g2);--rs-thumb-c: #fff;--rs-thumb-bc: var(--base-4)}sh-range-slider.raised.primary,sh-range-slider.raised.accent,sh-range-slider.raised.warn,sh-range-slider.raised.error,sh-range-slider.raised.success{--rst: var(--base-3);--rs-thumb-c: #fff;--rs-thumb-bc: var(--base-4);--rs-thumb-value-bg: var(--base-g6);--rs-thumb-value-c: #fff}sh-range-slider.raised.primary{--rst-bg: var(--primary-g2);--rs-thumb-arrow: var(--primary-8);--rs-thumb-value-bg: var(--primary-g3)}sh-range-slider.raised.accent{--rst-bg: var(--accent-g2);--rs-thumb-arrow: var(--accent-8);--rs-thumb-value-bg: var(--accent-8)}sh-range-slider.raised.warn{--rst-bg: var(--warn-g2);--rs-thumb-arrow: var(--warn-8);--rs-thumb-value-bg: var(--warn-8)}sh-range-slider.raised.error{--rst-bg: var(--error-g2);--rs-thumb-arrow: var(--error-8);--rs-thumb-value-bg: var(--error-8)}sh-range-slider.raised.success{--rst-bg: var(--success-g2);--rs-thumb-arrow: var(--success-8);--rs-thumb-value-bg: var(--success-8)}
|
|
2
|
+
`],encapsulation:2});}}return i})();var pn=["formRef"],En=()=>[import('./chunk-BG8y51P2.js').then(i=>i.OptionsListComponent)];function mn(i,t){i&1&&(Zi(0,"sh-alert",3),oC(1,1),Wl());}function Nn(i,t){if(i&1){let e=ET();Zi(0,"app-options-list",5),lm("optionsChange",function(a){Pd(e);let l=aC();return qC(l.settings,a)||(l.settings=a),Ld(a)}),Wl();}if(i&2){let e=aC();cm("options",e.settings),vg("hasFreeTextSettings",true);}}var K=class i{#n=T(R);#i=T(J$1);formRef=w1.required("formRef");settings=Ge([]);isSubmitting=Ge(false);isLoadingOptions=Ge(true);saved=Ge(false);lastRecievedServerSettings=Ge({});serverSettingsEffect=Qa(()=>{let t=this.#n.serverSettings();if(t===void 0)return;this.lastRecievedServerSettings.set(t),this.isLoadingOptions.set(true);let e=Object.entries(t);e.forEach(([n,a],l)=>{if(n.startsWith("--")){let m=n.substring(2);this.settings.update(u=>(u.some(E=>E.Name===m||E.Name===n)||u.push({Name:n,Value:a}),u));}l===e.length-1&&this.isLoadingOptions.set(false);});});submit(){this.isSubmitting.set(true);let t=this.settings(),e=this.lastRecievedServerSettings(),n=t.map(u=>u.Name?.startsWith("--")?u.Name:`--${u.Name}`),l=Object.keys(e).filter(u=>u.startsWith("--")).filter(u=>!n.includes(u)),m=t.reduce((u,E)=>{let f=E.Name?.startsWith("--")?E.Name:`--${E.Name}`;return u[f]=E.Value,u},{});l.forEach(u=>{m[u]=null;}),sy(()=>this.#i.patchApiV1Serversettings({body:m})).pipe(Zu(()=>this.isSubmitting.set(false))).subscribe({next:()=>{this.#n.refreshServerSettings(),this.saved.set(true),setTimeout(()=>{this.saved.set(false);},3e3);}});}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=gw({type:i,selectors:[["app-advanced-options-settings"]],viewQuery:function(e,n){e&1&&qg(n.formRef,pn,5),e&2&&hC();},decls:8,vars:4,consts:()=>{let t;t=$localize`${"\uFFFD#4\uFFFD"}:START_TAG_SH_ICON:floppy-disk${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_SH_ICON: Save settings `;let e;return e=$localize`Settings saved`,[t,e,[1,"actions"],[1,"success"],["shButton","","type","button",1,"raised","primary",3,"click"],[3,"optionsChange","options","hasFreeTextSettings"]]},template:function(e,n){e&1&&(Zi(0,"div",2),lT(1,mn,2,0,"sh-alert",3),Zi(2,"button",4),Hg("click",function(){return n.submit()}),Fg(3,0),Ig(4,"sh-icon"),jg(),Wl()(),lg(5,Nn,1,2),sT(6,5,En)),e&2&&(bE(),uT(n.saved()?1:-1),bE(),Kg("loading",n.isSubmitting()),bE(4),aT(!n.isLoadingOptions()));},dependencies:[Gn$1,v$1,N,ue],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:40.625rem;justify-self:flex-end}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;justify-content:flex-end;margin-bottom:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-wrap[_ngcontent-%COMP%]{display:grid;grid-template-columns:2fr 2.5rem;gap:.5rem;align-items:flex-end}.remote-volume-wrap[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.remote-volume-wrap[_ngcontent-%COMP%] p.warning[_ngcontent-%COMP%]{color:#7d7d00}.row-inputs[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.5rem}.row-inputs[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{flex:1 0}.advanced-option[_ngcontent-%COMP%]{display:grid;gap:.5rem;grid-template-columns:1fr 1fr 2.5rem;align-items:flex-end}"]})};function fn(i,t){if(i&1){let e=ET();Zi(0,"sh-form-field",12)(1,"input",13),lm("ngModelChange",function(a){Pd(e);let l=aC(2);return qC(l.registerUrl,a)||(l.registerUrl=a),Ld(a)}),Wl(),bD(),Wl(),Zi(2,"button",14),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.register())}),oC(3,0),Wl();}if(i&2){let e=aC(2);bE(),cm("ngModel",e.registerUrl),MD();}}function In(i,t){if(i&1&&(Zi(0,"div",9)(1,"label"),oC(2,1),Wl(),Zi(3,"a",15),HC(4),Wl()()),i&2){let e=aC(2);bE(3),vg("href",QC(e.claimUrl()),Yp),bE(),im(e.claimUrl());}}function Mn(i,t){i&1&&(Zi(0,"div",9)(1,"label"),oC(2,2),Wl()());}function Pn(i,t){if(i&1){let e=ET();Zi(0,"button",14),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.cancel())}),oC(1,3),Wl();}}function On(i,t){if(i&1){let e=ET();Zi(0,"button",14),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.disable())}),oC(1,4),Wl();}}function bn(i,t){if(i&1){let e=ET();Zi(0,"button",14),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.enable())}),oC(1,5),Wl(),Zi(2,"button",16),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.delete())}),oC(3,6),Wl();}}function Rn(i,t){i&1&&(Fg(0,7,1),Ig(1,"sh-icon"),jg());}function Gn(i,t){i&1&&(Fg(0,7,2),Ig(1,"sh-icon"),jg());}function vn(i,t){if(i&1){let e=ET();Zi(0,"sh-chip",17),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.copyReportingUrl())}),Fg(1,7),lT(2,Rn,2,0,"sh-icon")(3,Gn,2,0,"sh-icon"),jg(),Wl();}if(i&2){let e=aC(2);bE(2),uT(e.copiedReportingUrl()===true?2:3);}}function yn(i,t){if(i&1&&(Zi(0,"div",8),lT(1,fn,4,1),lT(2,In,5,3,"div",9),lT(3,Mn,3,0,"div",9),lT(4,Pn,2,0,"button",10),lT(5,On,2,0,"button",10),lT(6,bn,4,0),lT(7,vn,4,1,"sh-chip",11),Wl()),i&2){let e=aC();bE(),uT(e.state()==="inactive"?1:-1),bE(),uT(e.state()==="registered"?2:-1),bE(),uT(e.state()==="registering"?3:-1),bE(),uT(e.state()==="registering"||e.state()==="registeringfaulted"||e.state()==="registered"?4:-1),bE(),uT(e.state()==="connected"||e.state()==="connecting"?5:-1),bE(),uT(e.state()==="disabled"?6:-1),bE(),uT(e.additionalReportingUrl()!==""&&e.state()!=="registered"?7:-1);}}var Se=class i{#n=T(v);#i=T(R);state=this.#n.state;claimUrl=this.#n.claimUrl;registerUrl=this.#n.registerUrl;additionalReportingUrl=Nt(()=>{let t=this.#i.serverSettings();return t&&t["additional-report-url"]||""});copiedReportingUrl=Ge(false);ngOnInit(){this.#n.refreshRemoteControlStatus();}cancel(){this.#n.cancelRemoteRegistration();}register(){this.#n.beginRemoteRegistration();}disable(){this.#n.disableRemoteControl();}enable(){this.#n.enableRemoteControl();}delete(){this.#n.deleteRemoteControl();}copyReportingUrl(){let t=this.additionalReportingUrl();t&&(this.copiedReportingUrl.set(true),setTimeout(()=>this.copiedReportingUrl.set(false),2e3),navigator.clipboard.writeText(t));}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=gw({type:i,selectors:[["app-remote-control"]],decls:1,vars:1,consts:()=>{let t;t=$localize`Register on console`;let e;e=$localize`Machine is now registered, open this link to add it to your account:`;let n;n=$localize`Registering, please wait...`;let a;a=$localize`Cancel registration`;let l;l=$localize`Disable console connection`;let m;m=$localize`Enable console connection`;let u;u=$localize` Delete console connection setup `;let E;return E=$localize` Reporting configured by server ${"\uFFFD*2:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:check${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*2:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*3:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:copy${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*3:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,E=sC(E),[t,e,n,a,l,m,u,E,[1,"field-row"],[1,"field-col"],["type","button","shButton","",1,"raised"],[1,"reporting-url","primary","simple"],["label","Registration URL","for","remoteControlRegisterUrl"],["type","text","sh-input","","id","remoteControlRegisterUrl","name","remoteControlRegisterUrl",3,"ngModelChange","ngModel"],["type","button","shButton","",1,"raised",3,"click"],["target","_blank",3,"href"],["type","button","shButton","",1,"raised","error",3,"click"],[1,"reporting-url","primary","simple",3,"click"]]},template:function(e,n){e&1&&lT(0,yn,8,7,"div",8),e&2&&uT(n.state()!=="unknown"?0:-1);},dependencies:[Bn$1,Ze,Rn$1,Jt,Fe,v$1,D,N],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] button[_ngcontent-%COMP%]{white-space:nowrap}.field-row[_ngcontent-%COMP%]{display:flex;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] 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}"]})};var fe=[{value:"default",label:$localize`System default ($value)`},{value:"information",label:$localize`Usage statistics, warnings, errors, and crashes`},{value:"warning",label:$localize`Warnings, errors and crashes`},{value:"error",label:$localize`Errors and crashes`},{value:"crash",label:$localize`Crashes only`},{value:"none",label:$localize`None / disabled`}],Fn=new Set(["information","warning","error","crash","none"]),Tn=i=>{let t=(i??"").trim().toLowerCase();return t==="disabled"?"none":Fn.has(t)?t:"default"},un=i=>i==="default"?"":i;var Te=()=>({standalone:true});function $n(i,t){i&1&&(Zi(0,"sh-chip",97),oC(1,35),Wl());}function An(i,t){if(i&1&&(Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,34),Wl(),Zi(4,"p"),HC(5),Wl()(),Zi(6,"div",74),lT(7,$n,2,0,"sh-chip",97),Wl()()),i&2){let e=aC();bE(5),im(e.remoteControlStatus()),bE(2),uT(e.additionalReportingUrl()!==""&&e.remoteControlState()!=="registered"?7:-1);}}function Ln(i,t){if(i&1&&(Zi(0,"label"),Fg(1,39),Ig(2,"sh-icon",98),jg(),Wl()),i&2){let e=aC(3);bE(2),vg("shTooltip",e.remoteControlTooltip());}}function wn(i,t){if(i&1&&(Zi(0,"label"),Fg(1,40),Ig(2,"sh-icon",98),jg(),Wl()),i&2){let e=aC(3);bE(2),vg("shTooltip",e.remoteControlTooltip());}}function Dn(i,t){if(i&1&&(Zi(0,"label"),Fg(1,41),Ig(2,"sh-icon",98),jg(),Wl()),i&2){let e=aC(3);bE(2),vg("shTooltip",e.connectionStatusIndicatorTooltip());}}function xn(i,t){if(i&1&&(Zi(0,"label"),Fg(1,42),Ig(2,"sh-icon",98),jg(),Wl()),i&2){let e=aC(3);bE(2),vg("shTooltip",e.connectionStatusIndicatorTooltip());}}function kn(i,t){if(i&1){let e=ET();Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,37),Wl(),Zi(4,"p"),oC(5,38),Wl()(),Zi(6,"div",82)(7,"sh-toggle",83),Hg("checkedChange",function(a){Pd(e);let l=aC(2);return Ld(l.toggleConsoleControl(a))}),lT(8,Ln,3,1,"label")(9,wn,3,1,"label"),Wl(),Zi(10,"sh-toggle",83),Hg("checkedChange",function(a){Pd(e);let l=aC(2);return Ld(l.saveHideConsoleConnectionStatus(a))}),lT(11,Dn,3,1,"label")(12,xn,3,1,"label"),Wl()()();}if(i&2){let e=aC(2);bE(7),vg("checked",!e.consoleControlDisabled()),bE(),uT(e.consoleControlDisabled()?8:9),bE(2),vg("checked",!e.hideConsoleConnectionStatus()),bE(),uT(e.hideConsoleConnectionStatus()?11:12);}}function Xn(i,t){i&1&&(Zi(0,"label"),oC(1,45),Wl());}function Jn(i,t){i&1&&(Zi(0,"label"),oC(1,46),Wl());}function Vn(i,t){if(i&1){let e=ET();Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,43),Wl(),Zi(4,"p"),oC(5,44),Wl()(),Zi(6,"div",74)(7,"sh-toggle",83),Hg("checkedChange",function(a){Pd(e);let l=aC(2);return Ld(l.saveHideConsoleConnectionStatus(a))}),lT(8,Xn,2,0,"label")(9,Jn,2,0,"label"),Wl()()();}if(i&2){let e=aC(2);bE(7),vg("checked",!e.hideConsoleConnectionStatus()),bE(),uT(e.hideConsoleConnectionStatus()?8:9);}}function zn(i,t){if(i&1&&(Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,36),Wl(),Zi(4,"p"),HC(5),Wl()(),Zi(6,"div",74),Ig(7,"app-remote-control"),Wl()(),lT(8,kn,13,4,"section")(9,Vn,10,2,"section")),i&2){let e=aC();bE(5),im(e.remoteControlStatus()),bE(3),uT(e.remoteControlState()!="inactive"?8:9);}}function Un(i,t){i&1&&(Zi(0,"sh-icon",103),HC(1,"check"),Wl());}function Bn(i,t){i&1&&(Zi(0,"sh-icon",104),HC(1,"prohibit"),Wl());}function Hn(i,t){if(i&1){let e=ET();Zi(0,"button",108),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.updatePassphrase())}),oC(1,50),Wl();}if(i&2){let e=aC(2);Kg("loading",e.isUpdating());}}function Wn(i,t){if(i&1){let e=ET();Zi(0,"button",109),Hg("click",function(){Pd(e);let a=aC(2);return Ld(a.updatePassphrase())}),oC(1,51),Wl();}if(i&2){let e=aC(2);Kg("loading",e.isUpdating()),vg("disabled",true);}}function jn(i,t){if(i&1){let e=ET();Zi(0,"sh-form-field")(1,"label",99),oC(2,47),Wl(),Zi(3,"input",100),lm("ngModelChange",function(a){Pd(e);let l=aC();return qC(l.passphrase,a)||(l.passphrase=a),Ld(a)}),Wl(),bD(),Wl(),Zi(4,"sh-form-field")(5,"label",101),oC(6,48),Wl(),Zi(7,"input",102),lm("ngModelChange",function(a){Pd(e);let l=aC();return qC(l.repeatPassphrase,a)||(l.repeatPassphrase=a),Ld(a)}),Wl(),bD(),lT(8,Un,2,0,"sh-icon",103)(9,Bn,2,0,"sh-icon",104),Wl(),Zi(10,"div",79)(11,"button",105),Hg("click",function(){Pd(e);let a=aC();return Ld(a.cancelPasswordChange())}),oC(12,49),Wl(),lT(13,Hn,2,2,"button",106)(14,Wn,2,3,"button",107),Wl();}if(i&2){let e=aC();bE(3),cm("ngModel",e.passphrase),MD(),bE(4),vg("disabled",e.passphrase().length===0),cm("ngModel",e.repeatPassphrase),MD(),bE(),uT(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?8:9),bE(3),Kg("loading",e.isUpdating()),bE(2),uT(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?13:14);}}function qn(i,t){i&1&&(Zi(0,"sh-icon",110),HC(1,"check"),Wl());}function Kn(i,t){if(i&1){let e=ET();Zi(0,"div",79)(1,"button",105),Hg("click",function(){Pd(e);let a=aC();return Ld(a.openPassphraseForm())}),oC(2,52),Wl(),lT(3,qn,2,0,"sh-icon",110),Wl();}if(i&2){let e=aC();bE(3),uT(e.passwordUpdated()?3:-1);}}function Qn(i,t){i&1&&(Zi(0,"label"),oC(1,53),Wl());}function Yn(i,t){i&1&&(Zi(0,"label"),oC(1,54),Wl());}function Zn(i,t){i&1&&(Zi(0,"label"),oC(1,55),Wl());}function ei(i,t){i&1&&(Zi(0,"label"),oC(1,56),Wl());}function ti(i,t){i&1&&(Fg(0,13,1),Ig(1,"span"),jg());}function ni(i,t){i&1&&(Fg(0,13,2),Ig(1,"span"),jg());}function ii(i,t){if(i&1){let e=ET();Zi(0,"sh-form-field")(1,"label",111),oC(2,57),Wl(),Zi(3,"textarea",112),lm("ngModelChange",function(a){Pd(e);let l=aC();return qC(l.allowedHostnames,a)||(l.allowedHostnames=a),Ld(a)}),Wl(),bD(),Wl(),Zi(4,"sh-alert",113),oC(5,58),Wl(),Zi(6,"button",108),Hg("click",function(){Pd(e);let a=aC();return Ld(a.updateAllowedHostnames())}),oC(7,59),Wl();}if(i&2){let e=aC();bE(3),cm("ngModel",e.allowedHostnames),MD(),bE(3),Kg("loading",e.updatingAllowedHosts());}}function oi(i,t){if(i&1){let e=ET();Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,60),Wl(),Zi(4,"p"),oC(5,61),Wl()(),Zi(6,"div",74)(7,"sh-select",114)(8,"input",81),Hg("ngModelChange",function(a){Pd(e);let l=aC();return Ld(l.updatePowerMode(a))}),Wl(),bD(),Wl()()();}if(i&2){let e=aC();bE(7),vg("options",e.powerModeOptions())("isClearable",false),bE(),vg("ngModel",e.powerModeCtrl())("ngModelOptions",XC(4,Te)),MD();}}function si(i,t){if(i&1&&(Zi(0,"p"),oC(1,62),Wl()),i&2){let e=aC();bE(),Vg(e.sysinfo()?.ServerVersionName),iC(1);}}function ai(i,t){i&1&&Ig(0,"sh-progress-bar",87);}function ri(i,t){if(i&1&&HC(0),i&2){let e=t.$implicit;Yl(" ",e.label," ");}}function li(i,t){if(i&1&&HC(0),i&2){let e=t.$implicit;Yl(" ",e.label," ");}}function _i(i,t){if(i&1){let e=ET();Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,63),Wl(),Zi(4,"p")(5,"span"),oC(6,64),Wl(),Zi(7,"a",115),oC(8,65),Wl(),Ig(9,"br")(10,"br"),Zi(11,"span"),oC(12,66),Wl()()(),Zi(13,"div",74)(14,"sh-select",116)(15,"input",81),Hg("ngModelChange",function(a){Pd(e);let l=aC();return Ld(l.updateUsageStatistics(a))}),Wl(),bD(),cg(16,li,1,1,"ng-template"),Wl()()();}if(i&2){let e=aC();bE(14),vg("options",e.usageStatisticsOptions())("isLoading",e.updatingUsageStatistics()),bE(),vg("ngModel",e.usageStatistics())("ngModelOptions",XC(4,Te)),MD();}}function ci(i,t){i&1&&(Zi(0,"label"),oC(1,69),Wl());}function di(i,t){i&1&&(Zi(0,"label"),oC(1,70),Wl());}function Si(i,t){if(i&1){let e=ET();Zi(0,"section")(1,"div",73)(2,"h3"),oC(3,67),Wl(),Zi(4,"p"),oC(5,68),Wl()(),Zi(6,"div",82)(7,"p"),HC(8,"Backup process isolation"),Wl(),Zi(9,"sh-toggle",83),Hg("checkedChange",function(a){Pd(e);let l=aC();return Ld(l.saveControllerIpcState(a))}),lT(10,ci,2,0,"label")(11,di,2,0,"label"),Wl()()();}if(i&2){let e=aC();bE(9),vg("checked",e.isControllerIpcEnabled()),bE(),uT(e.isControllerIpcEnabled()?10:11);}}function Ti(i,t,e){let[n]=Ms(i,e?.equal),a=n,l=n[j],m;return a.set=u=>{clearTimeout(m),m=setTimeout(()=>{ft(l,u);},t);},a.update=u=>{clearTimeout(m),m=setTimeout(()=>{go(l,u);},t);},a}var ui=[{value:"none",label:$localize`None`},{value:"s",label:$localize`Seconds`},{value:"m",label:$localize`Minutes`},{value:"h",label:$localize`Hours`}],Ie=class i{#n=T(be);#i=T(m);#e=T(f);#t=T(R);#s=T(v);#r=T(I);#o=T(r);#a=T(f$1);#_=this.#a.getItem("locale")??"en-US";sysinfo=this.#e.systemInfo;isDarkMode=this.#i.isDarkMode;editAs=Ge("list");previousLang=this.#_;langCtrl=Ge(this.#_);powerModeCtrl=Ge("");usageStatistics=Ge("default");updatingUsageStatistics=Ge(false);remoteControlStatus=this.#s.statusMessage;remoteControlState=this.#s.state;updatingChannel=Ge(false);updateChannel=Ge("");isUsingRelay=this.#r.relayIsEnabled;defaultClient=Ge(this.#S());hasIpcController=this.#e.hasIpcController;usageStatisticsDisabled=Nt(()=>(this.#e.systemInfo()?.DefaultUsageReportLevel??"").toLowerCase()==="disabled");additionalReportingUrl=Nt(()=>{let t=this.#t.serverSettings();return t&&t["additional-report-url"]||""});#T=Qa(()=>{let t=this.#e.systemInfo()?.DefaultUsageReportLevel??"",e=fe;e[0].label=$localize`System default (${t})`,this.usageStatisticsOptions.set(e);});remoteControlTooltip=Ge($localize`Disabling console control will disable remote access to this machine from the console, but will keep the
|
|
3
3
|
registration intact and allow pushing settings from the console.`);connectionStatusIndicatorTooltip=Ge($localize`Hides the connection status indicator in the status bar. Useful if you are not using the remote console.`);setNewChannel(t){this.updateChannel();this.updateChannel.set(t),this.#t.setUpdateChannel(t).pipe(Zu(()=>this.updatingChannel.set(false))).subscribe();}allowRemoteAccess=Ge(false);allowedHostnames=Ge("");loadedAllowedHostnames=Ge("");updatingRemoteAccess=Ge(false);updatingAllowedHosts=Ge(false);updatingConsoleControl=Ge(false);consoleControlDisabled=Ge(false);hideConsoleConnectionStatus=this.#t.isConsoleConnectionStatusHidden;isControllerIpcEnabled=this.#t.isControllerIpcEnabled;fileTreeFoldersFirst=this.#o.foldersFirst;fileTreeCaseSensitiveSort=this.#o.caseSensitiveSort;setFileTreeFoldersFirst(t){this.#o.setFoldersFirst(t);}setFileTreeCaseSensitiveSort(t){this.#o.setCaseSensitiveSort(t);}updateRemoteAccess(t){this.allowRemoteAccess.set(t),this.#t.setRemoteAccessInterface(t?"any":"loopback").pipe(Zu(()=>this.updatingRemoteAccess.set(false))).subscribe();}updateAllowedHostnames(){let t=this.allowedHostnames();this.updatingAllowedHosts.set(true),this.#t.setRemoteAccessAllowedHostnames(t).pipe(Zu(()=>this.updatingAllowedHosts.set(false))).subscribe();}toggleConsoleControl(t){this.consoleControlDisabled.set(!t),this.#t.setDisableConsoleControl(!t).pipe(Zu(()=>this.updatingConsoleControl.set(false))).subscribe();}updatingDisableTrayIconLogin=Ge(false);disableTrayIconLogin=Ge(false);saveDisableTrayIconLogin(t){let e=t;this.updatingDisableTrayIconLogin.set(true),this.#t.setDisableTrayIconLogin(e).pipe(Zu(()=>this.updatingDisableTrayIconLogin.set(false))).subscribe();}updatingHideConsoleConnectionStatus=Ge(false);saveHideConsoleConnectionStatus(t){this.updatingHideConsoleConnectionStatus.set(true),this.#t.setHideConsoleConnectionStatus(!t).pipe(Zu(()=>this.updatingHideConsoleConnectionStatus.set(false))).subscribe();}updatingControllerIpcState=Ge(false);saveControllerIpcState(t){this.updatingControllerIpcState.set(true),this.#t.setControllerIpcState(!!t).pipe(Zu(()=>this.updatingControllerIpcState.set(false))).subscribe();}showPassphraseForm=Ge(false);isUpdating=Ge(false);passphrase=Ge("");repeatPassphrase=Ge("");passwordUpdated=Ge(false);updatePassphrase(){this.passphrase()===this.repeatPassphrase()&&(this.isUpdating.set(true),this.#t.setRemoteAccessPassword(this.passphrase()).pipe(Zu(()=>this.isUpdating.set(false))).subscribe({next:()=>{this.showPassphraseForm.set(false),this.passwordUpdated.set(true),setTimeout(()=>{this.passwordUpdated.set(false);},3e3);}}));}openPassphraseForm(){this.showPassphraseForm.set(true);}cancelPasswordChange(){this.showPassphraseForm.set(false);}languageOptions=Ge([...wt].sort((t,e)=>t.label.localeCompare(e.label)));powerModeOptions=Nt(()=>{let t=this.#e.systemInfo();return !t?.PowerModeProviders||t.PowerModeProviders.filter(e=>e!==""&&e!=="None").length==0?[]:t.PowerModeProviders.map(e=>({value:e==""?"default":e,label:e===""?$localize`Default`:e}))});usageStatisticsOptions=Ge(fe);timeTypeOptions=Ge(ui);timeType=Ge("none");timeValue=Ti(0,300);timeRange=Nt(()=>this.timeType()==="h"?[1,24]:[1,60]);updateLocale(t){!t||t===""||t===this.previousLang||(this.#a.setItem("locale",t),window.location.reload());}updateTimeValue(t){this.timeValue.set(t),this.#c();}updateTimeType(t){this.timeType()==="none"&&this.timeValue.set(1),this.timeType.set(t),this.#c();}#l;#c(){this.#l&&clearTimeout(this.#l),this.#l=setTimeout(()=>{let t=this.timeValue(),e=this.timeType(),n=e==="none"||t===0?"":`${t}${e}`;n!==this.#t.serverSettings()?.["startup-delay"]&&this.#t.setStartupDelay(n).subscribe();},1e3);}updateUsageStatistics(t){let e=this.usageStatistics();t!==e&&(this.usageStatistics.set(t),this.updatingUsageStatistics.set(true),this.#t.setUsageReporterLevel(un(t)).subscribe());}updatePowerMode(t){this.powerModeCtrl()!==t&&(t==="default"&&(t=""),this.#t.setPowerModeProvider(t).subscribe());}serverSettingsEffect=Qa(()=>{let t=this.#t.serverSettings();if(t===void 0)return;let e=t["startup-delay"],n=e.slice(-1),a=e.slice(0,-1),l=["s","m","h"];this.disableTrayIconLogin.set(t["disable-tray-icon-login"]!=="False"),this.updateChannel.set(t["update-channel"]),this.allowRemoteAccess.set(t["server-listen-interface"]==="any"),this.allowedHostnames.set(t["allowed-hostnames"]),this.loadedAllowedHostnames.set(t["allowed-hostnames"]),this.consoleControlDisabled.set(t["disable-console-control"]==="True"),this.usageStatistics.set(Tn(t["usage-reporter-level"])),this.timeType.set(e==""?"none":l.includes(n)?n:"none"),this.timeValue.set(e==""?0:parseInt(a));let m=t["power-mode-provider"]===""||t["power-mode-provider"]==null?"default":t["power-mode-provider"];this.powerModeCtrl.set(m);});setDarkMode(){this.#i.setDarkMode();}setLightMode(){this.#i.setLightMode();}changeDefaultClientTo(t){this.defaultClient()!==t&&(t==="ngax"?this.#n.open(h,{data:{title:$localize`Use legacy UI by default`,message:$localize`Are you sure you want to use the legacy user interface by default? This is not recommended unless you have a specific reason.`,confirmText:$localize`Use legacy UI by default`,cancelText:$localize`Cancel`},closed:e=>{e&&(window.location.href="/ngax",this.#d(t));}}):this.#d(t));}openLegacyUI(){this.#n.open(h,{data:{title:$localize`Open legacy UI`,message:$localize`Are you sure you want to open the legacy user interface? This is not recommended unless you have a specific reason.`,confirmText:$localize`Open legacy UI`,cancelText:$localize`Cancel`},closed:t=>{t&&window.open("/ngax","_blank");}});}#d(t){var e=new Date;e.setTime(e.getTime()+2160*60*60*1e3),document.cookie="default-client="+t+"; expires="+e.toUTCString()+"; path=/",this.defaultClient.set(t);}#S(){let t=document.cookie.split(";");for(let e=0;e<t.length;e++){let n=t[e].trim();if(n.startsWith("default-client="))return n.substring(15)}return "ngclient"}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=gw({type:i,selectors:[["app-settings"]],decls:143,vars:42,consts:()=>{let t;t=$localize`Settings`;let e;e=$localize`Configure your backup settings.`;let n;n=$localize`Color theme`;let a;a=$localize`Customize your application theme`;let l;l=$localize`Passwords`;let m;m=$localize`Change server passphrase`;let u;u=$localize`Language`;let E;E=$localize`Select a language for the platform`;let f;f=$localize`File tree sorting`;let W;W=$localize`Configure how files and folders are sorted in the file tree.`;let ue;ue=$localize`Use legacy interface`;let Q;Q=$localize`Use the old user interface, not recommended unless you have a specific reason.`;let J;J=$localize`${"\uFFFD#60\uFFFD"}:START_TAG_SH_ICON:arrow-square-right${"\uFFFD/#60\uFFFD"}:CLOSE_TAG_SH_ICON: Open legacy UI `;let V;V=$localize`${"\uFFFD#63\uFFFD"}:START_TAG_SH_ICON:swap${"\uFFFD/#63\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD*64:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SPAN:Set current UI as default${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SPAN:${"\uFFFD/*64:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*65:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SPAN:Set legacy UI as default${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SPAN:${"\uFFFD/*65:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,V=sC(V);let Y;Y=$localize`Allow remote access (requires restart)`;let Me;Me=$localize` By allowing remote access, the server listens to requests from any machine on your network. If you enable this option, make sure you are always using the computer on a secure firewall protected network. `;let Pe;Pe=$localize`Allow remote access`;let Oe;Oe=$localize`Prevent tray icon automatic log-in`;let be;be=$localize` By default, the tray icon will open the user interface with a token that unlocks the user interface. This ensures that you can access the user interface from the tray icon, while requiring others to enter a password. If you prefer having to type in the password, even when accessing the user interface from the tray icon, enable this option. `;let Re;Re=$localize`Prevent tray icon automatic log-in`;let Ge;Ge=$localize`Update channel`;let ve;ve=$localize` Default (${"\uFFFD0\uFFFD"}:INTERPOLATION:) `;let ye;ye=$localize`Same as the base install version: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Fe;Fe=$localize`Stable`;let $e;$e=$localize`Official stable release.`;let Ae;Ae=$localize`Beta`;let Le;Le=$localize` Try out the new features that we are working on. Test a backup and restore before using this in production environments. `;let we;we=$localize`Experimental`;let De;De=$localize`Early previews of new features. Not for use with important data.`;let xe;xe=$localize`Canary`;let ke;ke=$localize`Builds for developers and testers only. Not for use with important data.`;let Xe;Xe=$localize`Pause after startup or hibernation`;let Je;Je=$localize` Duplicati will run when started, but will remain in paused state for the duration. Duplicati will occupy minimal system resources and no backups will be run. `;let Ve;Ve=$localize`Advanced options`;let ze;ze=$localize`Console connection status`;let Ue;Ue=$localize`Reporting configured by server`;let Be;Be=$localize`Connect to console`;let He;He=$localize`Configure console control`;let We;We=$localize` You can control various settings for the remote console connection. If you are not using the console, you can also hide the connection status indicator. `;let je;je=$localize` Remote control disabled ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let qe;qe=$localize` Remote control enabled ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let Ke;Ke=$localize` Console connection status is hidden ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let Qe;Qe=$localize` Console connection status is visible ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let Ye;Ye=$localize`Toggle console connection status`;let Ze;Ze=$localize`Toggle the visibility of the console connection status indicator.`;let et;et=$localize`Console connection status is hidden`;let tt;tt=$localize`Console connection status is visible`;let nt;nt=$localize`Enter new password`;let it;it=$localize`Repeat password`;let ge;ge=$localize`Password have to be filled and have to match`;let ot;ot=$localize`Passphrase`;let st;st=$localize`Repeat passphrase`;let at;at=$localize`Cancel`;let rt;rt=$localize` Update passphrase `;let lt;lt=$localize` Update passphrase `;let _t;_t=$localize`Change password`;let ct;ct=$localize`Folders are shown before files`;let dt;dt=$localize`Files and folders are mixed together`;let St;St=$localize`Sorting is case sensitive`;let Tt;Tt=$localize`Sorting is case insensitive`;let ut;ut=$localize`Allowed hostnames`;let gt;gt=$localize` To prevent various DNS based attacks, Duplicati limits the allowed hostnames to the ones listed here. Direct IP access and localhost is always allowed. Multiple hostnames can be supplied with a semicolon separator. If any of the allowed hostnames is an asterisk (*), all hostnames are allowed and this feature is disabled. If the field is empty, only IP address and localhost access is allowed. `;let Ct;Ct=$localize` Update allowed hostnames `;let pt;pt=$localize`Power mode provider`;let Et;Et=$localize` The power mode provider monitors the system for when it enters a low power state and pauses Duplicati. When the system resumes, Duplicati will resume as well. Choosing the None option disables detection of low power states and Duplicati will run all the time. `;let mt;mt=$localize`Installed version: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Nt;Nt=$localize`Usage statistics`;let ht;ht=$localize` Usage reports help us improve the user experience and evaluate impact of new features. We use them to generate `;let ft;ft=$localize`public usage statistics.`;let It;It=$localize` All usage reports are sent anonymously and do not contain any personal information. They contain information about hardware and operating system, the type of backend, backup duration, overall size of source data and similar data. They do not contain paths, filenames, usernames, passwords or similar sensitive information. `;let Mt;Mt=$localize`Experimental options`;let Pt;Pt=$localize`Toggle experimental options.`;let Ot;Ot=$localize`Operations run in an isolated process`;let bt;return bt=$localize`Operations run inside the server process`,[t,e,n,a,l,m,u,E,f,W,ue,Q,J,V,Y,Me,Pe,Oe,be,Re,Ge,ve,ye,Fe,$e,Ae,Le,we,De,xe,ke,Xe,Je,Ve,ze,Ue,Be,He,We,je,qe,Ke,Qe,Ye,Ze,et,tt,ot,st,at,rt,lt,_t,ct,dt,St,Tt,ut,gt,Ct,pt,Et,mt,Nt,ht,ft,It,Mt,Pt,Ot,bt,[1,"content"],[1,"title"],[1,"left"],[1,"right"],[1,"themes"],["src","assets/images/light-theme.png","alt","light theme",3,"click"],["src","assets/images/dark-theme.png","alt","dark theme",3,"click"],[1,"right","passphrase-form"],[1,"actions"],["value","value","label","label",3,"options","isClearable","inlineSearch"],["type","text",3,"ngModelChange","ngModel","ngModelOptions"],[1,"right","multiple"],[1,"primary","raised",3,"checkedChange","checked"],[1,"right","buttons"],["shButton","",1,"primary",3,"click"],[1,"right","remote-access-form"],[1,"indeterminate","primary"],[1,"right","radios"],[1,"radio-option",3,"click"],[1,"primary","raised",3,"checked"],[1,"field-row"],[1,"raised","primary",3,"unit"],["type","range",3,"ngModelChange","min","max","disabled","ngModel","ngModelOptions"],["label","label","value","value",3,"options","isClearable"],["type","text",3,"ngModelChange","ngModel"],[1,"advanced-settings"],[1,"reporting-url","primary","simple"],["suffix","",3,"shTooltip"],["for","password"],["type","password","name","password","autocomplete","new-password","placeholder",nt,"tabindex","1",3,"ngModelChange","ngModel"],["for","repeatPassword"],["type","password","name","repeatPassword","autocomplete","new-password","placeholder",it,"tabindex","2",3,"ngModelChange","disabled","ngModel"],["suffix","",1,"sh-success"],["suffix",""],["shButton","",3,"click"],["shButton","",1,"raised","primary",3,"loading"],["shButton","","shTooltip",ge,1,"raised","primary",3,"loading","disabled"],["shButton","",1,"raised","primary",3,"click"],["shButton","","shTooltip",ge,1,"raised","primary",3,"click","disabled"],[1,"sh-success"],["for","allowedHostnames"],["type","text","id","allowedHostnames",3,"ngModelChange","ngModel"],["type","primary"],["value","value","label","label",3,"options","isClearable"],["href","https://usage-reporter.duplicati.com/","target","_blank"],["label","label","value","value",3,"options","isLoading"]]},template:function(e,n){e&1&&(Ig(0,"app-status-bar"),Zi(1,"div",71)(2,"header")(3,"div",72)(4,"h2"),oC(5,0),Wl(),Zi(6,"p"),oC(7,1),Wl()()(),lT(8,An,8,2,"section")(9,zn,10,2),Zi(10,"section")(11,"div",73)(12,"h3"),oC(13,2),Wl(),Zi(14,"p"),oC(15,3),Wl()(),Zi(16,"div",74)(17,"div",75)(18,"img",76),Hg("click",function(){return n.setLightMode()}),Wl(),Zi(19,"img",77),Hg("click",function(){return n.setDarkMode()}),Wl()()()(),Zi(20,"section")(21,"div",73)(22,"h3"),oC(23,4),Wl(),Zi(24,"p"),oC(25,5),Wl()(),Zi(26,"div",78),lT(27,jn,15,7)(28,Kn,4,1,"div",79),Wl()(),Zi(29,"section")(30,"div",73)(31,"h3"),oC(32,6),Wl(),Zi(33,"p"),oC(34,7),Wl()(),Zi(35,"div",74)(36,"sh-select",80)(37,"input",81),Hg("ngModelChange",function(l){return n.updateLocale(l)}),Wl(),bD(),Wl()()(),Zi(38,"section")(39,"div",73)(40,"h3"),oC(41,8),Wl(),Zi(42,"p"),oC(43,9),Wl()(),Zi(44,"div",82)(45,"sh-toggle",83),Hg("checkedChange",function(l){return n.setFileTreeFoldersFirst(l)}),lT(46,Qn,2,0,"label")(47,Yn,2,0,"label"),Wl(),Zi(48,"sh-toggle",83),Hg("checkedChange",function(l){return n.setFileTreeCaseSensitiveSort(l)}),lT(49,Zn,2,0,"label")(50,ei,2,0,"label"),Wl()()(),Zi(51,"section")(52,"div",73)(53,"h3"),oC(54,10),Wl(),Zi(55,"p"),oC(56,11),Wl()(),Zi(57,"div",84)(58,"button",85),Hg("click",function(){return n.openLegacyUI()}),Fg(59,12),Ig(60,"sh-icon"),jg(),Wl(),Zi(61,"button",85),Hg("click",function(){return n.changeDefaultClientTo(n.defaultClient()==="ngclient"?"ngax":"ngclient")}),Fg(62,13),Ig(63,"sh-icon"),lT(64,ti,2,0,"span")(65,ni,2,0,"span"),jg(),Wl()()(),Zi(66,"section")(67,"div",73)(68,"h3"),oC(69,14),Wl(),Zi(70,"p"),oC(71,15),Wl()(),Zi(72,"div",86)(73,"sh-toggle",83),Hg("checkedChange",function(l){return n.updateRemoteAccess(l)}),Zi(74,"label"),oC(75,16),Wl()(),lT(76,ii,8,3),Wl()(),Zi(77,"section")(78,"div",73)(79,"h3"),oC(80,17),Wl(),Zi(81,"p"),oC(82,18),Wl()(),Zi(83,"div",74)(84,"sh-toggle",83),Hg("checkedChange",function(l){return n.saveDisableTrayIconLogin(l)}),Zi(85,"label"),oC(86,19),Wl()()()(),lT(87,oi,9,5,"section"),Zi(88,"section")(89,"div",73)(90,"h3"),oC(91,20),Wl(),lT(92,si,2,1,"p"),lT(93,ai,1,0,"sh-progress-bar",87),Wl(),Zi(94,"div",88)(95,"div",89),Hg("click",function(){return n.setNewChannel("")}),Zi(96,"sh-radio",90),oC(97,21),Wl(),Zi(98,"p"),oC(99,22),Wl()(),Zi(100,"div",89),Hg("click",function(){return n.setNewChannel("stable")}),Zi(101,"sh-radio",90),oC(102,23),Wl(),Zi(103,"p"),oC(104,24),Wl()(),Zi(105,"div",89),Hg("click",function(){return n.setNewChannel("beta")}),Zi(106,"sh-radio",90),oC(107,25),Wl(),Zi(108,"p"),oC(109,26),Wl()(),Zi(110,"div",89),Hg("click",function(){return n.setNewChannel("experimental")}),Zi(111,"sh-radio",90),oC(112,27),Wl(),Zi(113,"p"),oC(114,28),Wl()(),Zi(115,"div",89),Hg("click",function(){return n.setNewChannel("canary")}),Zi(116,"sh-radio",90),oC(117,29),Wl(),Zi(118,"p"),oC(119,30),Wl()()()(),Zi(120,"section")(121,"div",73)(122,"h3"),oC(123,31),Wl(),Zi(124,"p"),oC(125,32),Wl()(),Zi(126,"div",74)(127,"div",91)(128,"sh-range-slider",92)(129,"input",93),lm("ngModelChange",function(l){return qC(n.timeValue,l)||(n.timeValue=l),l}),Hg("ngModelChange",function(l){return n.updateTimeValue(l)}),Wl(),bD(),Wl(),Zi(130,"sh-select",94)(131,"input",95),Hg("ngModelChange",function(l){return n.updateTimeType(l)}),Wl(),bD(),cg(132,ri,1,1,"ng-template"),Wl()()()(),lT(133,_i,17,5,"section"),lT(134,Si,12,2,"section"),Wl(),Ig(135,"sh-divider"),Zi(136,"div",71)(137,"section")(138,"div",96)(139,"h3"),oC(140,33),Wl(),Ig(141,"app-advanced-options-settings"),Wl()()(),Ig(142,"sh-divider")),e&2&&(bE(8),uT(n.isUsingRelay()?8:9),bE(10),Kg("active",!n.isDarkMode()),bE(),Kg("active",n.isDarkMode()),bE(8),uT(n.showPassphraseForm()?27:28),bE(9),vg("options",n.languageOptions())("isClearable",false)("inlineSearch",true),bE(),vg("ngModel",n.langCtrl())("ngModelOptions",XC(40,Te)),MD(),bE(8),vg("checked",n.fileTreeFoldersFirst()),bE(),uT(n.fileTreeFoldersFirst()?46:47),bE(2),vg("checked",n.fileTreeCaseSensitiveSort()),bE(),uT(n.fileTreeCaseSensitiveSort()?49:50),bE(15),uT(n.defaultClient()==="ngax"?64:65),bE(9),vg("checked",n.allowRemoteAccess()),bE(3),uT(n.allowRemoteAccess()?76:-1),bE(8),vg("checked",n.disableTrayIconLogin()),bE(3),uT(n.powerModeOptions().length>0?87:-1),bE(5),uT(n.sysinfo()?.ServerVersion?92:-1),bE(),uT(n.updatingChannel()?93:-1),bE(3),vg("checked",n.updateChannel()===""),bE(),Vg(n.sysinfo()?.DefaultUpdateChannel),iC(97),bE(2),Vg(n.sysinfo()?.ServerVersionType),iC(99),bE(2),vg("checked",n.updateChannel()==="stable"),bE(5),vg("checked",n.updateChannel()==="beta"),bE(5),vg("checked",n.updateChannel()==="experimental"),bE(5),vg("checked",n.updateChannel()==="canary"),bE(12),vg("unit",n.timeType()==="none"?"s":n.timeType()),bE(),vg("min",n.timeRange()[0])("max",n.timeRange()[1])("disabled",n.timeType()==="none"),cm("ngModel",n.timeValue),vg("ngModelOptions",XC(41,Te)),MD(),bE(),vg("options",n.timeTypeOptions())("isClearable",false),bE(),vg("ngModel",n.timeType()),MD(),bE(2),uT(n.usageStatisticsDisabled()?-1:133),bE(),uT(n.hasIpcController()?134:-1));},dependencies:[Bn$1,Ze,on,Rn$1,Jt,Gn$1,te,Se,K,v$1,O,dn,d,J,at,Fe,N,c,ue,Nt$1,D],styles:["[_nghost-%COMP%]{display:block}.content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:0 2rem 2rem}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:2rem 0;background:var(--base-1);border-bottom:1px solid var(--base-4)}header[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}section[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem;padding:2rem 0;border-top:1px solid var(--base-4)}@media only screen and (max-width:768px){section[_ngcontent-%COMP%]{grid-template-columns:1fr}}section[_ngcontent-%COMP%]:first-of-type{border-top:0}section[_ngcontent-%COMP%] .left[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem;align-items:flex-start}section[_ngcontent-%COMP%] .left[_ngcontent-%COMP%] sh-button-group[_ngcontent-%COMP%]{margin-top:.25rem}section[_ngcontent-%COMP%] .left[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-wrap:balance;width:50%}.passphrase-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:flex-start;gap:1rem}.passphrase-form[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.remote-access-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.themes[_ngcontent-%COMP%]{display:flex;gap:.5rem}.themes[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{max-width:15rem;border-radius:var(--shape-3);cursor:pointer}.themes[_ngcontent-%COMP%] img.active[_ngcontent-%COMP%]{border:2px solid var(--primary-8)}.radios[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.radio-option[_ngcontent-%COMP%]{cursor:pointer}.radio-option[_ngcontent-%COMP%] sh-radio[_ngcontent-%COMP%]{color:var(--base-8);margin-bottom:.25rem}.radio-option[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-wrap:balance;color:var(--base-9)}.field-col[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.field-row[_ngcontent-%COMP%]{display:flex;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] sh-form-field[_ngcontent-%COMP%], .field-row[_ngcontent-%COMP%] sh-select[_ngcontent-%COMP%]{flex:1 0}.advanced-settings[_ngcontent-%COMP%]{grid-column:1/-1;display:grid;grid-template-columns:auto 1fr;gap:1rem}.right.buttons[_ngcontent-%COMP%]{display:flex;flex-direction:row;gap:1rem}.right.multiple[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}"]})};
|
|
4
4
|
export{Ti as debounceSignal,Ie as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import {v as ve}from'./chunk-
|
|
1
|
+
import {v as ve}from'./chunk-CaQaYVo7.js';import {N as Nt$1}from'./chunk-B5S2d_Pm.js';import {F as Fe}from'./chunk-Be4WXTyA.js';import {B as Bn,Z as Ze,e as en,R as Rn,J as Jt,D}from'./chunk-Bfg1Kjif.js';import {E as E1,G as Ge,N as Nt,Q as Qa,g as gw,S as lC,Z as Zi,Y as uC,W as Wl,n as lm,p as qC,t as bD,b4 as cg,b as bE,aE as yg,z as vg,y as cm,M as MD,ah as Yg,aF as JC,v,o as oC,aR as zl,a1 as pT,aS as Ql,av as Vg,aw as iC,a2 as hT,aq as dT,i as ET,w as Hg,P as Pd,h as aC,L as Ld,H as HC,aD as sm}from'./main-X6MUEPX4.js';var ne=[[["label"]],[["","prefix",""]],[["","suffix",""]]],ie=["label","[prefix]","[suffix]"],oe=["ngProjectAs","label",5,["label"]];function ae(i,e){if(i&1&&HC(0),i&2){let t=e.$implicit,n=aC();sm("",t.label,"",n.hasPerSecond()?"/s":"");}}var se=["throttle-upload","throttle-download"],re=[{value:"B",label:"Bytes"},{value:"KB",label:"KB"},{value:"MB",label:"MB"},{value:"GB",label:"GB"},{value:"TB",label:"TB"},{value:"PB",label:"PB"}],le=i=>{if(!i||typeof i!="string"||i.length===0)return {size:0,unit:"MB"};let e=i.match(/^(\d+)(bytes|kb|mb|gb|tb|pb|b|kib|mib|gib|tib|pib)$/i);return e&&(e[2].toUpperCase()==="B"||e[2].toUpperCase()==="BYTES")?{size:1,unit:"KB"}:{size:e?parseInt(e[1],10):0,unit:e?e[2].toUpperCase():"MB"}},q=class i{customId=E1();inputType=E1();timespan=Ge(0);unit=Ge("MB");sizeOptions=Ge(re);readonly=Ge(false);hasPerSecond=Nt(()=>{let e=this.inputType();return e&&se.includes(e)});onChange=()=>{};onTouched=()=>{};onChangeEffect=Qa(()=>{this.onChange(this.getValue());});writeValue(e){if(e){let t=le(e);t?queueMicrotask(()=>{this.timespan.set(t.size),this.unit.set(t.unit);}):(this.timespan.set(0),this.unit.set("MB"));}else this.timespan.set(0),this.unit.set("MB");}registerOnChange(e){this.onChange=e;}registerOnTouched(e){this.onTouched=e;}setDisabledState(e){this.readonly.set(e);}getValue(){return `${this.timespan()}${this.unit()}`}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=gw({type:i,selectors:[["app-size"]],inputs:{customId:[1,"customId"],inputType:[1,"inputType"]},features:[JC([{provide:D,useExisting:i,multi:true}])],ngContentSelectors:ie,decls:9,vars:10,consts:[[1,"label"],["type","number",3,"ngModelChange","id","ngModel","disabled"],["value","value","label","label",3,"options","readonly","isClearable"],["type","text",3,"ngModelChange","ngModel"]],template:function(t,n){t&1&&(lC(ne),Zi(0,"div",0),uC(1,0,oe),Wl(),Zi(2,"sh-form-field")(3,"input",1),lm("ngModelChange",function(o){return qC(n.timespan,o)||(n.timespan=o),o}),Wl(),bD(),uC(4,1),uC(5,2),Wl(),Zi(6,"sh-select",2)(7,"input",3),lm("ngModelChange",function(o){return qC(n.unit,o)||(n.unit=o),o}),Wl(),bD(),cg(8,ae,1,2,"ng-template"),Wl()),t&2&&(bE(2),yg("readonly",n.readonly()||void 0),bE(),vg("id",n.customId()),cm("ngModel",n.timespan),vg("disabled",n.readonly()),MD(),bE(3),Yg("--miw",0),vg("options",n.sizeOptions())("readonly",n.readonly())("isClearable",false),bE(),cm("ngModel",n.unit),MD());},dependencies:[Nt$1,Fe,Bn,Ze,en,Rn,Jt],styles:['[_nghost-%COMP%]{display:grid;grid-template-areas:"label label" "input unit";grid-template-columns:3fr 1fr;gap:.5rem;align-items:flex-end}[_nghost-%COMP%] .label[_ngcontent-%COMP%]{grid-area:label;grid-column:1/-1}[_nghost-%COMP%] sh-form-field[_ngcontent-%COMP%]{grid-area:input}[_nghost-%COMP%] sh-select[_ngcontent-%COMP%]{grid-area:unit}']})};var pe=[[["label"]],[["","prefix",""]],[["","suffix",""]]],ue=["label","[prefix]","[suffix]"],de=["ngProjectAs","label",5,["label"]];function me(i,e){if(i&1){let t=ET();Zi(0,"button",7),Hg("click",function(){let l=Pd(t).$implicit,o=aC();return Ld(o.updateUnit(l.value))}),oC(1,1),Wl();}if(i&2){let t=e.$implicit;bE(),Vg(t.label),iC(1);}}var ce=[{value:"s",label:$localize`Seconds`},{value:"m",label:$localize`Minutes`},{value:"h",label:$localize`Hours`}],ge=[{value:"Y",label:$localize`Years`},{value:"M",label:$localize`Months`},{value:"W",label:$localize`Weeks`},{value:"D",label:$localize`Days`}],_e=["retry-delay","web-timeout","read-write-timeout","run-script-timeout","list-timeout","short-timeout","long-database-query-threshold"],Z=class i{customId=E1();inputType=E1();timespan=Ge(0);#e="D";unit=Ge(this.#e);unitLabel=Nt(()=>{let e=this.timeOptions(),t=e.findIndex(n=>n.value===this.unit());return e[t]?.label??this.unit()});isShortTime=Nt(()=>{let e=this.inputType();return e&&_e.includes(e.replace("--",""))});timeOptions=Nt(()=>this.isShortTime()?ce:ge);readonly=Ge(false);onChange=()=>{};onTouched=()=>{};onChangeEffect=Qa(()=>{this.onChange(this.getValue());});inputTypeEffect=Qa(()=>{this.timeOptions();let t=this.isShortTime()?"s":"D";this.#e=t,this.unit.set(t);});updateUnit(e){this.unit.set(e);}writeValue(e){let t=this.isShortTime();if(e){let n=t?/(\d+)([smh])/i:/^(\d+)([YMWD])$/i,l=e.match(n);l?(this.timespan.set(parseInt(l[1],10)),this.unit.set(l[2])):(this.timespan.set(0),this.unit.set(this.#e));}else this.timespan.set(0),this.unit.set(this.#e);}registerOnChange(e){this.onChange=e;}registerOnTouched(e){this.onTouched=e;}setDisabledState(e){this.readonly.set(e);}getValue(){return `${this.timespan()}${this.unit()}`}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=gw({type:i,selectors:[["app-timespan"]],inputs:{customId:[1,"customId"],inputType:[1,"inputType"]},features:[JC([{provide:D,useExisting:i,multi:true}])],ngContentSelectors:ue,decls:11,vars:6,consts:()=>{let e;e=$localize`${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let t;return t=$localize`${"\uFFFD0\uFFFD"}:INTERPOLATION:`,[e,t,["type","number",3,"ngModelChange","id","ngModel","disabled"],[3,"openIndicator"],["shButton","","type","button",1,"trigger"],["menu",""],["shButton","","type","button",1,"small"],["shButton","","type","button",1,"small",3,"click"]]},template:function(t,n){t&1&&(lC(pe),uC(0,0,de),Zi(1,"sh-form-field")(2,"input",2),lm("ngModelChange",function(o){return qC(n.timespan,o)||(n.timespan=o),o}),Wl(),bD(),uC(3,1),uC(4,2),Wl(),Zi(5,"sh-menu",3)(6,"button",4),oC(7,0),Wl(),zl(8,5),pT(9,me,2,1,"button",6,dT),Ql(),Wl()),t&2&&(bE(),yg("readonly",n.readonly()||void 0),bE(),vg("id",n.customId()),cm("ngModel",n.timespan),vg("disabled",n.readonly()),MD(),bE(3),vg("openIndicator",true),bE(2),Vg(n.unitLabel()),iC(7),bE(2),hT(n.timeOptions()));},dependencies:[ve,Fe,Bn,Ze,en,Rn,Jt,v],styles:['[_nghost-%COMP%]{display:grid;grid-template-areas:"label label" "input unit";grid-template-columns:3fr 1fr;gap:.5rem;align-items:flex-end}[_nghost-%COMP%] .label[_ngcontent-%COMP%]{grid-area:label;grid-column:1/-1}[_nghost-%COMP%] sh-form-field[_ngcontent-%COMP%]{grid-area:input}[_nghost-%COMP%] sh-menu[_ngcontent-%COMP%]{grid-area:unit}[_nghost-%COMP%] sh-menu[_ngcontent-%COMP%] button.trigger[_ngcontent-%COMP%]{width:100%}']})};export{Z,le as l,q};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {m}from'./chunk-
|
|
1
|
+
import {m}from'./chunk-BM5sEnUl.js';import {O}from'./chunk-B20GDhu-.js';import {T,ab as J,a6 as be,e as ee,ax as W,G as Ge,au as h,ad as sy,C as Zu,g as gw,u as ue,v,a as N,aL as ci,aJ as m$1,Z as Zi,o as oC,W as Wl,w as Hg,aO as sb,l as lT,F as Fg,d as Ig,j as jg,b as bE,z as vg,av as Vg,aP as lb,aw as iC,c as uT,K as Kg,s as sC,a1 as pT,h as aC,a2 as hT,i as ET,P as Pd,L as Ld,H as HC,aD as sm,aa as Yl,aT as cb,J as im}from'./main-X6MUEPX4.js';import {U}from'./chunk-CUo9Jt8-.js';var oe=(o,n)=>n.Version;function te(o,n){if(o&1&&(HC(0),sb(1,"bytes")),o&2){let i=aC().$implicit;Yl(" (",cb(1,1,i.FileSizes),") ");}}function re(o,n){if(o&1&&(Zi(0,"span",17),HC(1),Wl()),o&2){let i=aC().$implicit;bE(),im(i.Label);}}function se(o,n){if(o&1){let i=ET();Zi(0,"sh-checkbox",10),Hg("checkedChange",function(r){let S=Pd(i).$implicit,C=aC(2);return Ld(C.toggleVersion(S.Version,r))}),Zi(1,"span",16),HC(2),sb(3,"date"),lT(4,te,2,3),lT(5,re,2,1,"span",17),Wl()();}if(o&2){let i=n.$implicit,e=aC(2);vg("checked",e.isVersionSelected(i.Version)),bE(2),sm(" ",i.Version,": ",lb(3,5,i.Time,"medium")," "),bE(2),uT(i.FileSizes?4:-1),bE(),uT(i.Label?5:-1);}}function _e(o,n){if(o&1&&(Zi(0,"div",11),pT(1,se,6,8,"sh-checkbox",15,oe),Wl()),o&2){let i=aC();bE(),hT(i.versions());}}var R=class o{#e=T(m);#o=T(J);#i=T(be);#n=T(ee);#t=T(W);versions=this.#e.versions;versionScope=this.#e.versionScope;specificVersions=this.#e.specificVersions;selectedVersion=this.#e.selectedVersion;selectedVersionItem=this.#e.selectedVersionItem;selectedPathsArray=this.#e.selectedPathsArray;isPurging=Ge(false);isVersionSelected(n){return this.specificVersions().includes(n)}toggleVersion(n,i){this.specificVersions.update(e=>i?[...e,n]:e.filter(r=>r!==n));}goBack(){this.#n.navigate(["../select-files"],{relativeTo:this.#t});}purgeFiles(){let n=this.selectedPathsArray();if(n.length===0)return;let i=this.versionScope(),e=i==="all"?null:i==="current"?[parseInt(this.selectedVersion())]:this.specificVersions();if(e!==null&&e.length===0)return;let r=n.length,S=i==="all"?$localize`all versions`:i==="current"?$localize`version ${this.selectedVersion()}`:$localize`version(s) ${e.join(", ")}`;this.#i.open(h,{data:{title:$localize`Confirm removal`,message:$localize`Are you sure you want to remove ${r} file(s) from ${S}? This cannot be undone.`,confirmText:$localize`Remove files`,cancelText:$localize`Cancel`},closed:C=>{C&&(this.isPurging.set(true),sy(()=>this.#o.postApiV2BackupPurgeFiles({body:{BackupId:this.#e.backupId(),Filters:n.map(l=>l.endsWith("/")||l.endsWith("\\")?`${l}*`:l),Versions:e}})).pipe(Zu(()=>this.isPurging.set(false))).subscribe({next:()=>{this.#n.navigate(["/"]);},error:l=>{this.#i.open(h,{data:{title:$localize`Failed to remove files`,message:l.message??$localize`Unknown error`,confirmText:$localize`OK`,cancelText:void 0}});}}));}});}static \u0275fac=function(i){return new(i||o)};static \u0275cmp=gw({type:o,selectors:[["app-purge-version-scope"]],decls:20,vars:14,consts:()=>{let n;n=$localize` When removing files from a backup, Duplicati will add a new backup version without the removed files, and then remove the existing one. After this, a compaction will remove any data that is no longer needed. This process cannot be reverted.
|
|
2
2
|
`;let i;i=$localize`Choose which versions to remove the selected files from:`;let e;e=$localize` All versions `;let r;r=$localize` Active version (${"\uFFFD0\uFFFD"}:INTERPOLATION:) `;let S;S=$localize` Specific versions `;let C;C=$localize`${"\uFFFD#17\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#17\uFFFD"}:CLOSE_TAG_SH_ICON: Go back `;let l;l=$localize`{VAR_PLURAL, plural, =1 {1 file} other {{INTERPOLATION} files}}`,l=sC(l,{INTERPOLATION:"\uFFFD1\uFFFD",VAR_PLURAL:"\uFFFD0\uFFFD"});let I;return I=$localize` Remove ${l}:ICU@@2159106180826349718: `,[n,i,e,r,S,C,I,["color","primary"],[1,"version-scope"],[1,"radios"],[1,"primary","raised",3,"checkedChange","checked"],[1,"versions-list"],[1,"form-actions"],["shButton","","type","button",3,"click","disabled"],["shButton","",1,"raised","error",3,"click","disabled"],[1,"primary","raised",3,"checked"],[1,"version"],[1,"label"]]},template:function(i,e){i&1&&(Zi(0,"sh-alert",7),oC(1,0),Wl(),Zi(2,"div",8)(3,"p"),oC(4,1),Wl(),Zi(5,"div",9)(6,"sh-radio",10),Hg("checkedChange",function(){return e.versionScope.set("all")}),oC(7,2),Wl(),Zi(8,"sh-radio",10),Hg("checkedChange",function(){return e.versionScope.set("current")}),oC(9,3),sb(10,"date"),Wl(),Zi(11,"sh-radio",10),Hg("checkedChange",function(){return e.versionScope.set("specific")}),oC(12,4),Wl()(),lT(13,_e,3,0,"div",11),Wl(),Zi(14,"div",12)(15,"button",13),Hg("click",function(){return e.goBack()}),Fg(16,5),Ig(17,"sh-icon"),jg(),Wl(),Zi(18,"button",14),Hg("click",function(){return e.purgeFiles()}),oC(19,6),Wl()()),i&2&&(bE(6),vg("checked",e.versionScope()==="all"),bE(2),vg("checked",e.versionScope()==="current"),bE(2),Vg(lb(10,11,e.selectedVersionItem()?.Time,"medium")),iC(9),bE(),vg("checked",e.versionScope()==="specific"),bE(2),uT(e.versionScope()==="specific"?13:-1),bE(2),vg("disabled",e.isPurging()),bE(3),Kg("loading",e.isPurging()),vg("disabled",e.isPurging()||e.selectedPathsArray().length===0||e.versionScope()==="specific"&&e.specificVersions().length===0),bE(),Vg(e.selectedPathsArray().length)(e.selectedPathsArray().length),iC(19));},dependencies:[ue,v,U,N,O,ci,m$1],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;flex:1 0;min-height:25rem;overflow:hidden;gap:1rem;padding-top:2rem;padding-bottom:1.5rem}sh-alert[_ngcontent-%COMP%]{max-width:31.25rem;flex-shrink:0}.version-scope[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem;min-height:0}.version-scope[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0;flex-shrink:0}.version-scope[_ngcontent-%COMP%] .radios[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:flex-start;gap:.5rem;flex-shrink:0}.versions-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;flex:0 1 auto;min-height:0;max-height:25rem;overflow:auto;padding:.5rem 1rem;border:1px solid var(--base-4);border-radius:var(--shape-3);background:var(--base-1)}.versions-list[_ngcontent-%COMP%] .version[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.versions-list[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{color:var(--base-9)}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between;margin-top:auto;padding-top:1rem;flex-shrink:0}"]})};export{R as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {J as J$1}from'./chunk-
|
|
1
|
+
import {J as J$1}from'./chunk-BmOgPfpY.js';import {T,ai as fe$1,a6 as be,ab as J,a5 as m,e as ee,G as Ge,ad as sy,C as Zu,au as h,g as gw,_ as _t,a as N,v,Z as Zi,F as Fg,d as Ig,W as Wl,w as Hg,j as jg,l as lT,o as oC,t as bD,b as bE,z as vg,a3 as XC,K as Kg,c as uT,M as MD,s as sC,af as eo,B as w1,E as E1,ag as D1,N as Nt,Q as Qa,S as lC,Y as uC,H as HC,x as xC,aE as yg,O as qg,R as hC,h as aC,J as im,aa as Yl}from'./main-X6MUEPX4.js';import {F as Fe$1}from'./chunk-Be4WXTyA.js';import {j as jn,G as Gn,T as Tn,Z as Ze,y as yt,R as Rn,P as Pn,g as gn,h as hn}from'./chunk-Bfg1Kjif.js';var me=["input"],fe=[[["label"]]],Fe=["label"],_e=["ngProjectAs","label",5,["label"]];function ge(n,o){if(n&1&&(Zi(0,"div",3),HC(1),Wl()),n&2){let e=aC();bE(),im(e.files()[0].name);}}function he(n,o){if(n&1&&(Zi(0,"div",3),HC(1),Wl()),n&2){let e=aC();bE(),Yl("",e.files().length," files selected");}}function Te(n,o){if(n&1&&(Zi(0,"div",4),HC(1),Wl()),n&2){let e=aC();bE(),im(e.filesOver()?e.overlayText():e.placeholder());}}var ue=(()=>{class n{constructor(){this._el=T(eo),this.inputRef=w1.required("input"),this.filesOver=Ge(false),this.multiple=E1(),this.accept=E1(null),this.placeholder=D1("Click or drag files here"),this.overlayText=E1("Drop files here"),this.files=D1([]),this.fileUploadClasses=Nt(()=>this._el.nativeElement.classList.toString()),this.inputEffect=Qa(()=>{let e=this.inputRef().nativeElement;e&&(e.placeholder&&this.placeholder.set(e.placeholder),e.addEventListener("dragover",t=>{t.preventDefault(),this.filesOver.set(true);}),e.addEventListener("dragleave",t=>{t.preventDefault(),this.filesOver.set(false);}),e.addEventListener("drop",t=>{t.preventDefault(),this.filesOver.set(false);let i=t.dataTransfer?.files;i&&i.length>0&&(this.handleFileUpload(Array.from(i)),e.files=i);}),e.addEventListener("change",t=>{t.preventDefault(),this.handleFileUpload(Array.from(t.target.files));}));});}handleFileUpload(e){this.multiple()?this.files.update(t=>[...t,...e]):this.files.set(e);}static{this.\u0275fac=function(t){return new(t||n)};}static{this.\u0275cmp=gw({type:n,selectors:[["sh-file-upload"]],viewQuery:function(t,i){t&1&&qg(i.inputRef,me,5),t&2&&hC();},inputs:{multiple:[1,"multiple"],accept:[1,"accept"],placeholder:[1,"placeholder"],overlayText:[1,"overlayText"],files:[1,"files"]},outputs:{placeholder:"placeholderChange",files:"filesChange"},ngContentSelectors:Fe,decls:12,vars:7,consts:[["inputWrap",""],["input",""],["ngProjectAs","input",5,["input"],1,"input"],[1,"files-text"],[1,"placeholder"],["type","file"],[1,"bg-overlay"],["suffix",""]],template:function(t,i){t&1&&(lC(fe),Zi(0,"sh-form-field"),uC(1,0,_e),Zi(2,"div",2,0),lT(4,ge,2,1,"div",3)(5,he,2,1,"div",3)(6,Te,2,1,"div",4),Ig(7,"input",5,1)(9,"div",6),Wl(),Zi(10,"sh-icon",7),HC(11,"upload-simple"),Wl()()),t&2&&(xC(i.fileUploadClasses()),bE(4),uT(i.files().length===1?4:i.files().length>1?5:6),bE(3),yg("multiple",i.multiple())("accept",i.accept()),bE(2),Kg("files-over",i.filesOver()));},dependencies:[Fe$1,N],styles:[`sh-file-upload{--fu-bg-active: rgba(0, 0, 0, .1);display:flex;flex-direction:column;gap:.75rem;position:relative;width:100%}sh-file-upload sh-list{border-radius:var(--shape-3);background-color:var(--base-2)}sh-file-upload .files-text,sh-file-upload .placeholder{color:var(--base-8);font:var(--paragraph-30B)}sh-file-upload input{position:absolute;opacity:0;inset:0;cursor:pointer;z-index:100}sh-file-upload .bg-overlay{opacity:0;position:absolute;inset:.0625rem;background-color:var(--fu-bg-active);transition:opacity 125ms linear;z-index:0;border-radius:var(--ff-s)}sh-file-upload .bg-overlay.files-over{opacity:1}
|
|
2
2
|
`],encapsulation:2});}}return n})();var Ce=()=>["/"];function ve(n,o){n&1&&(Zi(0,"sh-form-field")(1,"label",14),oC(2,3),Wl(),Ig(3,"input",15),bD(),Wl()),n&2&&(bE(3),MD());}var d=new jn,M=class n{#t=T(fe$1);#i=T(be);#o=T(J);#n=T(m);#e=T(ee);isImporting=Ge(false);isSecureFile=Ge(false);isValid=Ge(false);importForm=d.group({config:d.control(""),cmdline:d.control(false),import_metadata:d.control(false),direct:d.control(false),passphrase:d.control("")});selectedFile=Ge([]);onFileDropped(o){let e=o[0];if(e){let t=new FileReader;this.isSecureFile.set(e.type!=="application/json"),t.onload=this.#a.bind(this),t.readAsArrayBuffer(e);}}#a(o){let e=o.target?.result;this.isSecureFile.set(this.#r(e)!=="json"),this.importForm.patchValue({config:this.#l(e)}),this.isValid.set(this.importForm.value.config!=="");}#r(o){let e=new Uint8Array(o);if(e.length>=5&&e[0]===65&&e[1]===69&&e[2]===83&&e[4]===0)return "aes";try{let t=new TextDecoder().decode(o),i=JSON.parse(t);if(typeof i=="object"&&i!==null)return "json"}catch{}return "unknown"}#l(o){let e=new Uint8Array(o),t=e.byteLength,i="";for(let s=0;s<t;s++)i+=String.fromCharCode(e[s]);return btoa(i)}submit(){this.isImporting.set(true);let o=this.importForm.value.direct??false;sy(()=>this.#o.postApiV1BackupsImport({body:this.importForm.value})).pipe(Zu(()=>this.isImporting.set(false))).subscribe({next:e=>{if(o){this.#t.success("Backup imported successfully."),this.#e.navigate(["/"]);return}let t=this.#n.addDraftBackup(e.data);this.#e.navigate(["/backup-draft",t]);},error:e=>{let t=e.message||$localize`Unknown error`;this.#i.open(h,{data:{title:$localize`Failed to import backup`,message:t,confirmText:$localize`OK`,cancelText:void 0}});}});}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=gw({type:n,selectors:[["app-import"]],decls:19,vars:8,consts:()=>{let o;o=$localize` Import backup configuration ${"\uFFFD#3\uFFFD"}:START_TAG_DIV:${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"[\uFFFD#5\uFFFD|\uFFFD#7\uFFFD]"}:START_TAG_SH_ICON:arrow-left${"[\uFFFD/#5\uFFFD|\uFFFD/#7\uFFFD]"}:CLOSE_TAG_SH_ICON: Back ${"[\uFFFD/#4\uFFFD|\uFFFD/#6\uFFFD]"}:CLOSE_TAG_BUTTON:${"\uFFFD#6\uFFFD"}:START_TAG_BUTTON_1:${"[\uFFFD#5\uFFFD|\uFFFD#7\uFFFD]"}:START_TAG_SH_ICON:download-simple${"[\uFFFD/#5\uFFFD|\uFFFD/#7\uFFFD]"}:CLOSE_TAG_SH_ICON: Import ${"[\uFFFD/#4\uFFFD|\uFFFD/#6\uFFFD]"}:CLOSE_TAG_BUTTON:${"\uFFFD/#3\uFFFD"}:CLOSE_TAG_DIV:`,o=sC(o);let e;e=$localize`Import Metadata`;let t;t=$localize`Save now`;let i;return i=$localize`Passphrase`,[o,e,t,i,[1,"actions"],["shButton","","type","button",1,"outlined",3,"routerLink"],["shButton","","type","submit",1,"raised","primary",3,"click","disabled"],["autocomplete","off",3,"formGroup"],["accept",".json,.aes",3,"filesChange","files"],[1,"primary","raised"],["for","importMetadata"],["type","checkbox","formControlName","import_metadata"],["for","direct"],["type","checkbox","formControlName","direct"],["for","passphrase"],["type","password","autocomplete","disabled","formControlName","passphrase"]]},template:function(e,t){e&1&&(Zi(0,"header")(1,"h3"),Fg(2,0),Zi(3,"div",4)(4,"button",5),Ig(5,"sh-icon"),Wl(),Zi(6,"button",6),Hg("click",function(){return t.submit()}),Ig(7,"sh-icon"),Wl()(),jg(),Wl()(),Zi(8,"form",7)(9,"sh-file-upload",8),Hg("filesChange",function(s){return t.onFileDropped(s)}),Wl(),lT(10,ve,4,0,"sh-form-field"),Zi(11,"sh-toggle",9)(12,"label",10),oC(13,1),Wl(),Ig(14,"input",11),bD(),Wl(),Zi(15,"sh-toggle",9)(16,"label",12),oC(17,2),Wl(),Ig(18,"input",13),bD(),Wl()()),e&2&&(bE(4),vg("routerLink",XC(7,Ce)),bE(2),Kg("loading",t.isImporting()),vg("disabled",t.isImporting()||!t.isValid()),bE(2),vg("formGroup",t.importForm),bE(),vg("files",t.selectedFile()),bE(),uT(t.isSecureFile()?10:-1),bE(4),MD(),bE(4),MD());},dependencies:[Gn,Tn,Ze,yt,Rn,Pn,gn,hn,_t,Fe$1,N,v,J$1,ue],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:2rem;padding:3rem}h3[_ngcontent-%COMP%]{font:var(--title-30);display:flex;align-items:center;justify-content:space-between}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;max-width:31.25rem}sh-file-upload[_ngcontent-%COMP%]{width:100%}"]})};export{M as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {R}from'./chunk-
|
|
1
|
+
import {R}from'./chunk-Dn7TWCfq.js';import {br as x,T,a6 as be,ab as J,f,k,bk as B,I,G as Ge,N as Nt,Q as Qa,ad as sy,au as h,a_ as ee}from'./main-X6MUEPX4.js';var C=new x("WindowToken",{providedIn:"root",factory:()=>typeof window<"u"?window:{}});var v=class a{#c=T(C);#g=T(be);#t=T(J);#o=T(f);#l=T(k);#n=T(B);#u=T(R);#m=T(I);constructor(){this.#l.subscribe("remotecontrol");}repeatRegisterTimer=null;#r=null;#s=0;#f=5;#h=2e3;pendingRefresh=false;state=Ge("unknown");claimUrl=Ge(null);registerUrl=Ge("");customRegisterUrl=Ge("");statusMessage=Nt(()=>{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=Qa(()=>{let e=this.#o.systemInfo();e&&this.registerUrl.set(e.RemoteControlRegistrationUrl??"");});remoteEffect=Qa(()=>{let e=this.#l.remoteControlState();e&&this.#e(e);});relayEffect=Qa(()=>{this.#m.relayIsEnabled()&&this.state.set("connected");});pendingRefreshEffect=Qa(()=>{this.#n.isConnectionMethodSet()&&this.pendingRefresh&&(this.pendingRefresh=false,this.refreshRemoteControlStatus());});#a=Nt(()=>{let e=this.#n.getConnectionMethod()==="websocket",i=this.#o.hasWsRemoteControl();return e&&i});#d(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");}#e(e){if(this.#s=0,this.#d(e),this.#a())return;let i=this.state();this.repeatRegisterTimer!==null&&(clearTimeout(this.repeatRegisterTimer),this.repeatRegisterTimer=null),i==="registering"&&(this.repeatRegisterTimer=setTimeout(()=>{sy(()=>this.#t.postApiV1RemotecontrolRegisterWait()).subscribe({next:t=>this.#e(t),error:t=>this.#i(t)});},5e3)),(i==="connecting"||i==="registered")&&(this.repeatRegisterTimer=setTimeout(()=>{sy(()=>this.#t.getApiV1RemotecontrolStatus()).subscribe({next:t=>this.#e(t),error:t=>this.#i(t)});},5e3)),e.IsRegistering&&e.CanEnable&&sy(()=>this.#t.deleteApiV1RemotecontrolRegister()).subscribe({next:t=>this.#e(t)});}#i(e){if(this.#r!==null&&(clearTimeout(this.#r),this.#r=null),this.#s>=this.#f){this.state.set("registeringfaulted"),this.#s=0;return}let i=this.#h*Math.pow(2,this.#s);this.#s++,this.#r=setTimeout(()=>{this.#r=null,sy(()=>this.#t.getApiV1RemotecontrolStatus()).subscribe({next:t=>this.#e(t),error:t=>this.#i(t)});},i);}refreshRemoteControlStatus(){if(!this.#a()){if(!this.#n.isConnectionMethodSet()){this.pendingRefresh=true;return}sy(()=>this.#t.getApiV1RemotecontrolStatus()).subscribe({next:e=>this.#e(e),error:e=>this.#i(e)});}}beginRemoteRegistration(e=false){this.state.set("registering"),sy(()=>this.#t.postApiV1RemotecontrolRegister({body:{RegistrationUrl:e?this.customRegisterUrl():this.registerUrl()}})).subscribe({next:i=>this.#e(i),error:i=>this.#i(i)});}cancelRemoteRegistration(){sy(()=>this.#t.deleteApiV1RemotecontrolRegister()).subscribe({next:e=>this.#e(e),error:e=>this.#i(e)});}enableRemoteControl(){sy(()=>this.#t.postApiV1RemotecontrolEnable()).subscribe({next:e=>this.#e(e),error:e=>this.#i(e)});}disableRemoteControl(){sy(()=>this.#t.postApiV1RemotecontrolDisable()).subscribe({next:e=>this.#e(e),error:e=>this.#i(e)});}deleteRemoteControl(){let e=this;this.#g.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&&sy(()=>e.#t.deleteApiV1RemotecontrolRegistration()).subscribe({next:t=>e.#e(t),error:t=>e.#i(t)});}});}openConsole(e="/app/machines",i){let t=this.#u.serverSettings(),w=this.#o.systemInfo(),o="https://app.duplicati.com",g=w?.RemoteControlDashboardUrl??"";if(g.length>0&&(o=g),t&&t["remote-control-dashboard-url"]&&(o=t["remote-control-dashboard-url"]),o=new URL(o).origin+e,i){let T=new URLSearchParams(i);o+=`?${T.toString()}`;}this.#c.open(o,"_blank");}static \u0275fac=function(i){return new(i||a)};static \u0275prov=ee({token:a,factory:a.\u0275fac,providedIn:"root"})};
|
|
2
2
|
export{C,v};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {bc as ue,E as E1,bd as ce,T,q as qe,Q as Qa,g as gw,be as sg,S as lC,Y as uC,x as xC}from'./main-
|
|
1
|
+
import {bc as ue,E as E1,bd as ce,T,q as qe,Q as Qa,g as gw,be as sg,S as lC,Y as uC,x as xC}from'./main-X6MUEPX4.js';var m=["*"],w=(()=>{class i extends ue{constructor(){super("[value], [step], [routerLinkActive], button, a","active",{hostRole:"tablist",itemRole:"tab"}),this.color=E1(null),this.hostClasses=ce("stepper",{color:this.color});let s=T(qe);if(Qa(()=>{this.items().forEach(e=>{if(!e.querySelector(".sh-radio")){let t=document.createElement("div");t.className="sh-radio";let r=document.createElement("div");r.className="radio sh-sheet",t.append(r),e.prepend(t);}});}),Qa(()=>{this.items(),this.updateProgress();}),typeof MutationObserver<"u"){let e=new MutationObserver(()=>{this.updateProgress();});e.observe(this.hostElement,{attributes:true,subtree:true,attributeFilter:["class"]}),s.onDestroy(()=>{e.disconnect();});}}updateProgress(){let s=Array.from(this.hostElement.querySelectorAll("[value], [step], [routerLinkActive], button, a")),e=s.findIndex(f=>f.classList.contains(this.activeClass));e===-1&&(e=0);let t=s.length,r=0;t>1&&(r=e/(t-1)*100),this.hostElement.style.setProperty("--stepper-progress",`${r}%`);}static{this.\u0275fac=function(e){return new(e||i)};}static{this.\u0275cmp=gw({type:i,selectors:[["sh-stepper"]],hostVars:2,hostBindings:function(e,t){e&2&&xC(t.hostClasses());},inputs:{color:[1,"color"]},features:[sg],ngContentSelectors:m,decls:1,vars:0,template:function(e,t){e&1&&(lC(),uC(0));},styles:[`.sh-radio,sh-radio{--radiod-c: var(--base-8);--radiod-o: 0;--radio-bc: var(--base-4);display:flex;align-items:center;gap:.5rem;cursor:pointer;-webkit-user-select:none;user-select:none;position:relative}.sh-radio:focus-visible>.radio,.sh-radio:has(input:focus-visible)>.radio,sh-radio:focus-visible>.radio,sh-radio:has(input:focus-visible)>.radio{outline:2px solid var(--primary-8);outline-offset:2px}.sh-radio>input,sh-radio>input{appearance:none;position:absolute;inset:0;cursor:pointer}.sh-radio>input:focus,.sh-radio>input:focus-visible,sh-radio>input:focus,sh-radio>input:focus-visible{outline:none}.sh-radio:has(>input:not(.internal-input))>input.internal-input,sh-radio:has(>input:not(.internal-input))>input.internal-input{display:none}.sh-radio:has(input[disabled]),.sh-radio[disabled]:not([disabled=false]),sh-radio:has(input[disabled]),sh-radio[disabled]:not([disabled=false]){opacity:.5;pointer-events:none;-webkit-user-select:none;user-select:none;cursor:initial}.sh-radio:has(input:checked),.sh-radio.active,sh-radio:has(input:checked),sh-radio.active{--radiod-o: 1}.sh-radio .radio,sh-radio .radio{display:flex;align-items:center;justify-content:center;width:1.25rem;height:1.25rem;cursor:pointer;position:relative;border-radius:50%}.sh-radio .radio:after,sh-radio .radio:after{content:"";position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);border-radius:50%;width:.375rem;height:.375rem;background-color:var(--radiod-c);opacity:var(--radiod-o);transition:opacity 125ms linear}.sh-radio.primary,sh-radio.primary{--radiod-c: var(--primary-8)}.sh-radio.accent,sh-radio.accent{--radiod-c: var(--accent-8)}.sh-radio.warn,sh-radio.warn{--radiod-c: var(--warn-8)}.sh-radio.error,sh-radio.error{--radiod-c: var(--error-8)}.sh-radio.success,sh-radio.success{--radiod-c: var(--success-8)}.sh-radio.flat,.sh-radio.raised,sh-radio.flat,sh-radio.raised{--radiod-c: #fff}.sh-radio.raised:not(:has(input:checked)):not(.active) .radio,.sh-radio.flat:not(:has(input:checked)):not(.active) .radio,sh-radio.raised:not(:has(input:checked)):not(.active) .radio,sh-radio.flat:not(:has(input:checked)):not(.active) .radio{background:transparent;border:var(--border-10);border-color:var(--radio-bc)}sh-stepper{--step-track-bg: var(--base-3);--step-c: var(--base-6);--step-radio-cbg: var(--base-1);--step-radio-c: var(--base-g2);--step-active-c: var(--base-8);display:flex;flex-wrap:nowrap;width:100%;position:relative}sh-stepper.primary{--step-c: var(--primary-6);--step-radio-cbg: var(--primary-1);--step-radio-c: var(--primary-g2);--step-active-c: var(--primary-8)}sh-stepper.accent{--step-c: var(--accent-6);--step-radio-cbg: var(--accent-1);--step-radio-c: var(--accent-g2);--step-active-c: var(--accent-8)}sh-stepper.warn{--step-c: var(--warn-6);--step-radio-cbg: var(--warn-1);--step-radio-c: var(--warn-g2);--step-active-c: var(--warn-8)}sh-stepper.error{--step-c: var(--error-6);--step-radio-cbg: var(--error-1);--step-radio-c: var(--error-g2);--step-active-c: var(--error-8)}sh-stepper.success{--step-c: var(--success-6);--step-radio-cbg: var(--success-1);--step-radio-c: var(--success-g2);--step-active-c: var(--success-8)}sh-stepper button{background:transparent;border:0;padding:0}sh-stepper button,sh-stepper [routerLinkActive],sh-stepper [step],sh-stepper [value]{flex:2 0;display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:.5rem;position:relative;color:var(--base-8);cursor:pointer;-webkit-user-select:none;user-select:none;outline:none;z-index:1}sh-stepper button:focus-visible .sh-radio,sh-stepper [routerLinkActive]:focus-visible .sh-radio,sh-stepper [step]:focus-visible .sh-radio,sh-stepper [value]:focus-visible .sh-radio{outline:2px solid var(--primary-8);outline-offset:2px;border-radius:50%}sh-stepper button:first-child,sh-stepper [routerLinkActive]:first-child,sh-stepper [step]:first-child,sh-stepper [value]:first-child{align-items:flex-start;flex:1 0}sh-stepper button:last-child,sh-stepper [routerLinkActive]:last-child,sh-stepper [step]:last-child,sh-stepper [value]:last-child{align-items:flex-end;flex:1 0;text-align:end}sh-stepper button:not(.active) .sh-radio,sh-stepper [routerLinkActive]:not(.active) .sh-radio,sh-stepper [step]:not(.active) .sh-radio,sh-stepper [value]:not(.active) .sh-radio{z-index:10}sh-stepper button:has(~button.active) .sh-radio,sh-stepper button:has(~[step].active) .sh-radio,sh-stepper button:has(~[routerLinkActive].active) .sh-radio,sh-stepper button:has(~[value].active) .sh-radio,sh-stepper [routerLinkActive]:has(~button.active) .sh-radio,sh-stepper [routerLinkActive]:has(~[step].active) .sh-radio,sh-stepper [routerLinkActive]:has(~[routerLinkActive].active) .sh-radio,sh-stepper [routerLinkActive]:has(~[value].active) .sh-radio,sh-stepper [step]:has(~button.active) .sh-radio,sh-stepper [step]:has(~[step].active) .sh-radio,sh-stepper [step]:has(~[routerLinkActive].active) .sh-radio,sh-stepper [step]:has(~[value].active) .sh-radio,sh-stepper [value]:has(~button.active) .sh-radio,sh-stepper [value]:has(~[step].active) .sh-radio,sh-stepper [value]:has(~[routerLinkActive].active) .sh-radio,sh-stepper [value]:has(~[value].active) .sh-radio{--radiod-o: 1}sh-stepper button:has(~button.active) .sh-radio .radio,sh-stepper button:has(~[step].active) .sh-radio .radio,sh-stepper button:has(~[routerLinkActive].active) .sh-radio .radio,sh-stepper button:has(~[value].active) .sh-radio .radio,sh-stepper [routerLinkActive]:has(~button.active) .sh-radio .radio,sh-stepper [routerLinkActive]:has(~[step].active) .sh-radio .radio,sh-stepper [routerLinkActive]:has(~[routerLinkActive].active) .sh-radio .radio,sh-stepper [routerLinkActive]:has(~[value].active) .sh-radio .radio,sh-stepper [step]:has(~button.active) .sh-radio .radio,sh-stepper [step]:has(~[step].active) .sh-radio .radio,sh-stepper [step]:has(~[routerLinkActive].active) .sh-radio .radio,sh-stepper [step]:has(~[value].active) .sh-radio .radio,sh-stepper [value]:has(~button.active) .sh-radio .radio,sh-stepper [value]:has(~[step].active) .sh-radio .radio,sh-stepper [value]:has(~[routerLinkActive].active) .sh-radio .radio,sh-stepper [value]:has(~[value].active) .sh-radio .radio{border-width:0;background:var(--step-radio-c)}sh-stepper button .sh-radio .radio,sh-stepper [routerLinkActive] .sh-radio .radio,sh-stepper [step] .sh-radio .radio,sh-stepper [value] .sh-radio .radio{--radiod-c: var(--step-radio-cbg);width:1rem;height:1rem}sh-stepper button.active,sh-stepper [routerLinkActive].active,sh-stepper [step].active,sh-stepper [value].active{color:var(--step-active-c);outline:none}sh-stepper button.active .sh-radio,sh-stepper [routerLinkActive].active .sh-radio,sh-stepper [step].active .sh-radio,sh-stepper [value].active .sh-radio{z-index:0;--radiod-o: 1}sh-stepper button.active .sh-radio .radio,sh-stepper [routerLinkActive].active .sh-radio .radio,sh-stepper [step].active .sh-radio .radio,sh-stepper [value].active .sh-radio .radio{border-width:0;background:var(--step-radio-c)}sh-stepper:before{content:"";position:absolute;top:.375rem;left:0;z-index:0;right:0;height:.25rem;background-color:var(--step-track-bg)}sh-stepper:after{content:"";position:absolute;top:.375rem;left:0;z-index:0;width:var(--stepper-progress, 0%);height:.25rem;background-color:var(--step-active-c);transition:width .15s ease-out}
|
|
2
2
|
`],encapsulation:2});}}return i})();export{w};
|