@duplicati/ngclient 0.0.228 → 0.0.229
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/sh.woff2 +0 -0
- package/{chunk-CDRHCSvU.js → chunk-0sb5_LpD.js} +1 -1
- package/chunk-2OH1SKyQ.js +1 -0
- package/chunk-A5DpxPOI.js +1 -0
- package/{chunk-BffC_BAn.js → chunk-B-fklW6A.js} +2 -2
- package/{chunk-D0t-kgLy.js → chunk-B12Syddi.js} +1 -1
- package/chunk-B2fqvpov.js +2 -0
- package/{chunk-ZVDEaGd0.js → chunk-B3yuN2OH.js} +1 -1
- package/{chunk-BAbAUjHY.js → chunk-B6vxBiK4.js} +1 -1
- package/{chunk-5zEiKCqR.js → chunk-B9zNFJSv.js} +1 -1
- package/{chunk-CdZVal1F.js → chunk-BAZ5npJw.js} +1 -1
- package/{chunk-Cz4OqhOZ.js → chunk-BDXLL1lt.js} +1 -1
- package/chunk-BFH9sFEg.js +1 -0
- package/{chunk-DddAUzMY.js → chunk-BIeNnIyg.js} +1 -1
- package/{chunk-ClHWI9-i.js → chunk-BJ6LKfIL.js} +1 -1
- package/{chunk-G-I5c1Dk.js → chunk-BYHopERA.js} +1 -1
- package/{chunk-BKLJMYh2.js → chunk-BZYVgHEz.js} +1 -1
- package/chunk-BZqhgAZ-.js +2 -0
- package/{chunk-DNJQ-AbV.js → chunk-Bc4gFy5W.js} +1 -1
- package/{chunk-CeFh90sX.js → chunk-BcpsSgKo.js} +1 -1
- package/{chunk-BNf0YAwH.js → chunk-Bf1diO1u.js} +1 -1
- package/{chunk-N7vpDAsp.js → chunk-BjkwnDTL.js} +1 -1
- package/{chunk-B6nCQM-G.js → chunk-BoCnrrB4.js} +1 -1
- package/{chunk-BxxX98wy.js → chunk-BtzP4vdU.js} +1 -1
- package/{chunk-CnAb3OKU.js → chunk-Byb051F6.js} +1 -1
- package/{chunk-C08PrcBX.js → chunk-C11i_gv7.js} +1 -1
- package/{chunk-DuO9_dH0.js → chunk-C1t4wbdG.js} +1 -1
- package/{chunk-Bzp0ULy_.js → chunk-C2bnZ62D.js} +1 -1
- package/{chunk-Do6_xsGi.js → chunk-C9EdrQe6.js} +3 -3
- package/chunk-CA-ER0DL.js +2 -0
- package/{chunk-CxPG-KgI.js → chunk-CBdr-6_u.js} +2 -2
- package/{chunk-ClfSJEUJ.js → chunk-CByrJpDb.js} +1 -1
- package/chunk-CI78bAye.js +2 -0
- package/chunk-CMmgPgiU.js +2 -0
- package/{chunk-CMs999gl.js → chunk-COgNe44h.js} +1 -1
- package/{chunk-CtLFpDTP.js → chunk-CQ8rm_d9.js} +1 -1
- package/{chunk-B7PRtY7v.js → chunk-CRU3lYvk.js} +1 -1
- package/{chunk-BUF3tczf.js → chunk-CUxq_s_t.js} +8 -8
- package/chunk-CXEImxhE.js +1 -0
- package/chunk-C_JveZJH.js +1 -0
- package/{chunk-DtQIjLqL.js → chunk-CdKfNiwm.js} +1 -1
- package/{chunk-PA5BGFyW.js → chunk-CfoJuTJX.js} +1 -1
- package/chunk-CgYrHQGO.js +1 -0
- package/{chunk-wycXedbJ.js → chunk-Cs0rlpWi.js} +1 -1
- package/{chunk-DNSvQk_3.js → chunk-CwB_t7g-.js} +1 -1
- package/chunk-D0u1cyeL.js +1 -0
- package/chunk-D1wHRltX.js +2 -0
- package/{chunk-M5tldLvJ.js → chunk-D28lTX0k.js} +1 -1
- package/{chunk--rqB0ojD.js → chunk-D2XTQURr.js} +1 -1
- package/{chunk-bx0aDvCZ.js → chunk-D48AStVy.js} +1 -1
- package/chunk-D4UZC_u0.js +1 -0
- package/{chunk-DnD9XTM4.js → chunk-DC8QqmzV.js} +1 -1
- package/{chunk-ChwFViRh.js → chunk-DDVdXEVe.js} +1 -1
- package/{chunk-r4LfAQnM.js → chunk-DDo7wKQT.js} +1 -1
- package/{chunk-DWwNINBJ.js → chunk-DJbAxHpK.js} +1 -1
- package/{chunk-C-G3pKB4.js → chunk-DMJycFPC.js} +1 -1
- package/chunk-DP9SoPGV.js +1 -0
- package/{chunk-BjNuU0J_.js → chunk-DQW8lSiz.js} +1 -1
- package/{chunk-Dt8gZPT-.js → chunk-DQwpGI_E.js} +1 -1
- package/chunk-DV2SIgNN.js +2 -0
- package/{chunk-g_QJ3SVt.js → chunk-DVgkAgur.js} +1 -1
- package/{chunk-BeAI10wv.js → chunk-DVlpMN2Q.js} +1 -1
- package/{chunk-BYoKu9PJ.js → chunk-D_A6A07f.js} +1 -1
- package/chunk-D_JCqKo8.js +1 -0
- package/{chunk-IEVZ0UN6.js → chunk-DaIpTiYw.js} +1 -1
- package/{chunk-CJRbWZfg.js → chunk-DiZeSQXj.js} +1 -1
- package/{chunk-BOII3Fdm.js → chunk-Drc5kcUX.js} +1 -1
- package/{chunk-BthLY9tf.js → chunk-GVxWY6X-.js} +1 -1
- package/{chunk-DofVJ9gn.js → chunk-JA7rUsYF.js} +1 -1
- package/{chunk-SWsliUUy.js → chunk-M21GJPzH.js} +3 -3
- package/{chunk-CUxvfCTH.js → chunk-MvQwR7nW.js} +1 -1
- package/{chunk-Cc1_FUvV.js → chunk-ObToq7vh.js} +1 -1
- package/chunk-RKTSBnYB.js +1 -0
- package/{chunk-BaWD8G-f.js → chunk-SKxVK_pD.js} +1 -1
- package/{chunk-C4pJCbq-.js → chunk-SycscfJp.js} +1 -1
- package/{chunk-Cw8vFX0e.js → chunk-bgWe6t7y.js} +1 -1
- package/{chunk-XMwSOila.js → chunk-cLFxUFjv.js} +1 -1
- package/{chunk-ySdaWJYB.js → chunk-dScOwyAU.js} +1 -1
- package/{chunk-BqjWEFHw.js → chunk-w_Hs_Uxi.js} +1 -1
- package/chunk-wyer8fjS.js +1 -0
- package/index.html +1 -1
- package/locale/messages.en.json +23 -3
- package/locale/messages.json +23 -3
- package/{main-TZVLLK67.js → main-PXGZLKMN.js} +14 -14
- package/package.json +1 -1
- package/ship-ui-assets/mcp/components.json +258 -86
- package/chunk-B-ryE8KW.js +0 -2
- package/chunk-B6ugJDDx.js +0 -1
- package/chunk-B88MJ6Up.js +0 -1
- package/chunk-BCT9ajP9.js +0 -1
- package/chunk-BMGXb3gX.js +0 -1
- package/chunk-BPpheyQK.js +0 -2
- package/chunk-BS8yAz3P.js +0 -2
- package/chunk-BlIcwFlf.js +0 -1
- package/chunk-BuyCr2eD.js +0 -1
- package/chunk-CM11IMzh.js +0 -1
- package/chunk-CU-RYihf.js +0 -2
- package/chunk-CuU6b3lp.js +0 -2
- package/chunk-D-epCTmE.js +0 -1
- package/chunk-QlYDF-EM.js +0 -1
- package/chunk-SgcWXTYZ.js +0 -2
- package/chunk-birClroL.js +0 -2
- package/chunk-ya_5JcKA.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import {e as ee}from'./chunk-
|
|
1
|
+
import {e as ee}from'./chunk-D_JCqKo8.js';import'./chunk-w_Hs_Uxi.js';import'./chunk-D1wHRltX.js';import'./chunk-CBdr-6_u.js';import'./chunk-BZqhgAZ-.js';import'./chunk-B9zNFJSv.js';import'./chunk-COgNe44h.js';import'./chunk-BAZ5npJw.js';import {T,m,d as dw,v,f as N,_ as _t,j as mg,Q as Qi,X as XT,H as Hl,O as Og,P as Pg,o as oT,D as DE,I as Qg,z as gg,a3 as QC,i as iT}from'./main-PXGZLKMN.js';import {f}from'./chunk-DJbAxHpK.js';import'./chunk-MvQwR7nW.js';import'./chunk-SycscfJp.js';import'./chunk-DQW8lSiz.js';import'./chunk-CMmgPgiU.js';import'./chunk-C9EdrQe6.js';import'./chunk-Drc5kcUX.js';import'./chunk-B-fklW6A.js';import'./chunk-D28lTX0k.js';var B=()=>["/backup/new"],G=()=>["/backup/import"],K=()=>["/backup/import-destination"];function U(r,s){r&1&&(Qi(0,"sh-card",11),mg(1,"img",15),Qi(2,"h3"),XT(3,7),Hl(),Qi(4,"p"),XT(5,8),Hl(),Qi(6,"button",13),Og(7,9),mg(8,"sh-icon"),Pg(),Hl()()),r&2&&(DE(6),gg("routerLink",QC(1,K)));}var p=class r{hasRestoreControlFilesOperation=T(m).hasRestoreControlFilesOperation;static \u0275fac=function(i){return new(i||r)};static \u0275cmp=dw({type:r,selectors:[["app-add-backup"]],decls:24,vars:7,consts:()=>{let s;s=$localize`Add a new backup`;let i;i=$localize`New backup`;let C;C=$localize`Configure a new backup. Choose your destination, source data and schedule.`;let m;m=$localize` Add a new backup ${"\uFFFD#13\uFFFD"}:START_TAG_SH_ICON:plus${"\uFFFD/#13\uFFFD"}:CLOSE_TAG_SH_ICON:`;let A;A=$localize`Import from file`;let S;S=$localize`Import backup configuration from a file. During import, you can adjust the settings.`;let P;P=$localize` Import from file ${"\uFFFD#22\uFFFD"}:START_TAG_SH_ICON:upload-simple${"\uFFFD/#22\uFFFD"}:CLOSE_TAG_SH_ICON:`;let T;T=$localize`Import from destination`;let g;g=$localize`Import one or more backup configurations from a remote destination.`;let E;return E=$localize` Import from destination ${"\uFFFD#8\uFFFD"}:START_TAG_SH_ICON:download-simple${"\uFFFD/#8\uFFFD"}:CLOSE_TAG_SH_ICON:`,[s,i,C,m,A,S,P,T,g,E,[1,"backup-types"],[1,"type-a"],["src","assets/images/new-backup.png"],["shButton","",1,"raised","primary",3,"routerLink"],["src","assets/images/backup-from-config.png"],["src","assets/images/backup-from-remote.png"]]},template:function(i,C){i&1&&(mg(0,"app-status-bar"),Qi(1,"section")(2,"h2"),XT(3,0),Hl(),Qi(4,"div",10)(5,"sh-card",11),mg(6,"img",12),Qi(7,"h3"),XT(8,1),Hl(),Qi(9,"p"),XT(10,2),Hl(),Qi(11,"button",13),Og(12,3),mg(13,"sh-icon"),Pg(),Hl()(),Qi(14,"sh-card",11),mg(15,"img",14),Qi(16,"h3"),XT(17,4),Hl(),Qi(18,"p"),XT(19,5),Hl(),Qi(20,"button",13),Og(21,6),mg(22,"sh-icon"),Pg(),Hl()(),oT(23,U,9,2,"sh-card",11),Hl()()),i&2&&(DE(4),Qg("three-column",C.hasRestoreControlFilesOperation()),DE(7),gg("routerLink",QC(5,B)),DE(9),gg("routerLink",QC(6,G)),DE(3),iT(C.hasRestoreControlFilesOperation()?23:-1));},dependencies:[ee,v,f,N,_t],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;align-items:center;flex-direction:column;gap:2rem;padding:2rem 0}div.backup-types[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem;max-width:43.75rem;padding:0 2rem}div.backup-types.three-column[_ngcontent-%COMP%]{grid-template-columns:1fr 1fr 1fr;max-width:65.625rem}@media only screen and (max-width:768px){div.backup-types[_ngcontent-%COMP%]{grid-template-columns:1fr}}sh-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;gap:1rem;padding-bottom:3rem}sh-card[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{max-width:18.75rem}sh-card[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-wrap:balance;text-align:center;width:75%}"]})};export{p as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import {OptionsListComponent as Oe}from'./chunk-
|
|
1
|
+
import {OptionsListComponent as Oe}from'./chunk-Bf1diO1u.js';import {I}from'./chunk-DV2SIgNN.js';import {L}from'./chunk-D28lTX0k.js';import {T,ab as C,e as ee$1,aw as W,U as Ue,N as Nt,C as Bu,d as dw,f as N,v,Q as Qi,F as Fg,o as oT,aP as Ul,X as XT,aQ as Wl,s as sm,H as Hl,O as Og,j as mg,P as Pg,z as gg,D as DE,i as iT,w as im,a6 as be,at as h,aZ as ee$2,l as HC,p as DD,y as TD}from'./main-PXGZLKMN.js';import {F as Fe}from'./chunk-C9EdrQe6.js';import {j as jn,G as Gn,T as Tn,Z as Ze,R as Rn,P as Pn,g as gn,h as hn}from'./chunk-Drc5kcUX.js';import'./chunk-B6vxBiK4.js';import'./chunk-B2fqvpov.js';import'./chunk-D48AStVy.js';import'./chunk-CQ8rm_d9.js';import'./chunk-CBdr-6_u.js';import'./chunk-BZqhgAZ-.js';import'./chunk-0sb5_LpD.js';import'./chunk-COgNe44h.js';import'./chunk-BAZ5npJw.js';import'./chunk-DQW8lSiz.js';import'./chunk-CMmgPgiU.js';import'./chunk-B-fklW6A.js';var d=class r{#t=T(be);destinationTargetUrl=Ue(null);destinationTestSignal=Ue(null);encryptionForm=Z();temporaryBackupId=Ue(null);updateTargetUrl(e){this.destinationTargetUrl.set(e);}showErrorDialog(e){this.#t.open(h,{data:{title:$localize`Error occured`,message:e,confirmText:$localize`OK`,cancelText:void 0},closed:n=>{}});}static \u0275fac=function(n){return new(n||r)};static \u0275prov=ee$2({token:r,factory:r.\u0275fac,providedIn:"root"})};function ne(r,e){r&1&&(Qi(0,"p"),XT(1,3),Hl());}function oe(r,e){r&1&&(Qi(0,"sh-form-field")(1,"label",11),XT(2,4),Hl(),mg(3,"input",12),DD(),Hl()),r&2&&(DE(3),TD());}var ee=new jn,Z=()=>ee.group({passphrase:ee.control("")}),f=class r{#t=T(C);#e=T(d);#n=T(ee$1);#o=T(W);encryptionForm=this.#e.encryptionForm;creatingTemporaryBackup=Ue(false);settings=Ue([]);hasEncryptedBackup=Nt(()=>{let e=this.#e.destinationTestSignal();return e==="testing"||typeof e=="string"?true:e?.containsEncryptedBackupFiles??true});passphraseSignal=L(this.encryptionForm.controls.passphrase.valueChanges);showEncryptionField=Ue(false);isValidConfig=Nt(()=>{if(!this.#e.destinationTargetUrl())return false;let n=this.#e.destinationTestSignal();return !(typeof n!="string"&&(n?.containsEncryptedBackupFiles??false)&&!this.passphraseSignal())});next(){let e=this.#e.destinationTargetUrl();if(!e)throw new Error("No target URL");this.creatingTemporaryBackup.set(true);let n=this.encryptionForm.value?.passphrase??null,t=[];n?t.push({Name:"--passphrase",Value:n}):t.push({Name:"--no-encryption",Value:"true"}),this.settings().forEach(i=>{let o=i.Name?.trim();o&&o!=="--"&&(o.startsWith("--")||(o=`--${o}`),t.push({Name:o,Value:i.Value??""}));}),this.#t.postApiV1Backups({requestBody:{Backup:{TargetURL:e,Settings:t}},temporary:true}).pipe(Bu(()=>this.creatingTemporaryBackup.set(false))).subscribe({next:i=>{let o=i.ID;this.#e.temporaryBackupId.set(o),this.#n.navigate(["../select-config"],{relativeTo:this.#o});},error:i=>{console.error(i);}});}back(){this.#n.navigate(["../destination"],{relativeTo:this.#o});}static \u0275fac=function(n){return new(n||r)};static \u0275cmp=dw({type:r,selectors:[["app-import-destination-encryption"]],decls:14,vars:6,consts:()=>{let e;e=$localize`Advanced options`;let n;n=$localize`${"\uFFFD#10\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#10\uFFFD"}:CLOSE_TAG_SH_ICON: Back `;let t;t=$localize`${"\uFFFD#13\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#13\uFFFD"}:CLOSE_TAG_SH_ICON: Continue `;let i;i=$localize`The backup does not contain encrypted files.`;let o;o=$localize`Enter backup passphrase if defined.`;let P;return P=$localize`Password`,[e,n,t,i,P,[3,"submit","formGroup"],["title",""],[3,"optionsChange","options","hasFreeTextSettings"],[1,"form-actions"],["shButton","","type","button",3,"click"],["shButton","","type","submit",1,"raised","primary",3,"disabled"],["for","password"],["type","password","id","password","autocomplete","disabled","placeholder",o,"formControlName","passphrase"]]},template:function(n,t){n&1&&(Qi(0,"form",5),Fg("submit",function(){return t.next()}),oT(1,ne,2,0,"p"),oT(2,oe,4,0,"sh-form-field"),Qi(3,"sh-toggle-card"),Ul(4,6),XT(5,0),Wl(),Qi(6,"app-options-list",7),sm("optionsChange",function(o){return HC(t.settings,o)||(t.settings=o),o}),Hl()(),Qi(7,"div",8)(8,"button",9),Fg("click",function(){return t.back()}),Og(9,1),mg(10,"sh-icon"),Pg(),Hl(),Qi(11,"button",10),Og(12,2),mg(13,"sh-icon"),Pg(),Hl()()()),n&2&&(gg("formGroup",t.encryptionForm),DE(),iT(t.hasEncryptedBackup()?-1:1),DE(),iT(t.hasEncryptedBackup()||t.showEncryptionField()?2:-1),DE(4),im("options",t.settings),gg("hasFreeTextSettings",true),DE(5),gg("disabled",!t.isValidConfig()));},dependencies:[Gn,Tn,Ze,Rn,Pn,gn,hn,Fe,N,v,I,Oe],styles:["[_nghost-%COMP%]{display:block}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}"]})};var chunkGEQXBNCM=/*#__PURE__*/Object.freeze({__proto__:null,createEncryptionForm:Z,default:f});export{chunkGEQXBNCM as c,d};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {J}from'./chunk-birClroL.js';import {e as ee}from'./chunk-BMGXb3gX.js';import'./chunk-BqjWEFHw.js';import {O as O$1}from'./chunk-BS8yAz3P.js';import {N as Nt$1}from'./chunk-CxPG-KgI.js';import'./chunk-B-ryE8KW.js';import {m}from'./chunk-5zEiKCqR.js';import {c}from'./chunk-CMs999gl.js';import {D}from'./chunk-CdZVal1F.js';import {bi as H,bj as ft,bk as po,T,a6 as be,m as m$1,g,bl as h,U as Ue,N as Nt,G as Ga,C as Bu,bm as It,at as h$1,d as dw,v,f as N,u as ue,j as mg,Q as Qi,X as XT,H as Hl,o as oT,F as Fg,p as DD,O as Og,P as Pg,s as sm,bf as ig,D as DE,i as iT,I as Qg,z as gg,a3 as QC,y as TD,au as Lg,av as eC,w as im,t as tC,l as HC,ab as C$1,B as y1,b1 as sg,b2 as tT,b3 as nT,$ as $g,K as lC,ae as Jr,b as g1,af as m1,b7 as le,L as oC,R as Bl,Y as iC,W as $l,q as PC,an as jg,V as yg,aB as rm,ag as zg,h as bC,n as nC,E as nm,k as gT,S as Sd,x as xd,ar as Wp,a9 as UC,aa as Gl}from'./main-TZVLLK67.js';import {C}from'./chunk-CUxvfCTH.js';import {O}from'./chunk-C4pJCbq-.js';import {d}from'./chunk-BjNuU0J_.js';import'./chunk-CU-RYihf.js';import {F as Fe}from'./chunk-Do6_xsGi.js';import {B as Bn$1,Z as Ze,o as on$1,R as Rn$1,J as Jt,G as Gn$1}from'./chunk-BOII3Fdm.js';import {a as at}from'./chunk-BffC_BAn.js';import'./chunk-M5tldLvJ.js';var sn=[[["label"]],[["input","type","range"]]],an=["label","input[type=range]"],en=(()=>{class i{constructor(){this.hasInput=Ue(false),this.#n=T(Jr),this.#i=null,this.#e=null,this.#t=0,this.unit=g1(""),this.value=m1(this.#t),this.inputState=Ue({min:0,max:100,step:1}),this.color=g1(null),this.variant=g1(null),this.size=g1(null),this.sharp=g1(void 0),this.alwaysShow=g1(void 0),this.hostClasses=le("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(),s=this.value()??e;if(isNaN(s))return 0;let l=n-e;if(l===0)return 0;let E=(s-e)/l*100;return Math.max(0,Math.min(100,E))}),this.trackFilledPercentage=Nt(()=>this.valuePercentage()),this.thumbPositionPercentage=Nt(()=>this.valuePercentage()),this.syncModelToInputEffect=Ga(()=>{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.#o(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:s,max:l}=this.inputState();this.value.set(Math.max(s,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 s=e.currentTarget.getBoundingClientRect(),l=e.clientX-s.left,E=s.width,{min:g,max:m,step:f}=this.inputState(),W=m-g;if(E>0&&W!==0&&f>0){let J=(l/E*W+g-g)/f,z=g+Math.round(J)*f,Q=this.#s(f);z=parseFloat(z.toFixed(Q));let Y=Math.max(g,Math.min(m,z));this.value.set(Y);}}#o(e=false){if(!this.#e)return;let n=parseFloat(this.#e.min??"0")??0,s=parseFloat(this.#e.max??"100")??100,l=this.#e.step,E=1;if(l&&l.toLowerCase()!=="any"){let m=parseFloat(l);!isNaN(m)&&m>0&&(E=m);}this.inputState.set({min:n,max:s,step:E});let g=parseFloat(this.#e.value??String(n))??n;if(e&&this.value()!==this.#t){let m=this.value(),f=Math.max(n,Math.min(s,m));g!==f&&(this.#e.value=String(f)),m!==f&&this.value.set(f);}else {let m=Math.max(n,Math.min(s,g));this.value()!==m&&this.value.set(m);}}#r(){if(!this.#e||typeof MutationObserver>"u")return;let e=["min","max","step","value","readonly","disabled"];this.#i=new MutationObserver(n=>{let s=false;for(let l of n)if(l.type==="attributes"&&e.includes(l.attributeName??"")){s=true;break}s&&this.#o(false);}),this.#i.observe(this.#e,{attributes:true,attributeFilter:e});}#s(e){if(isNaN(e)||Math.floor(e)===e)return 0;let s=e.toString().split(".")[1];return s?s.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=dw({type:i,selectors:[["sh-range-slider"]],hostVars:6,hostBindings:function(n,s){n&2&&(bC(s.hostClasses()),Qg("sh-range-slider",true)("has-input",s.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:an,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,s){n&1&&(oC(sn),Bl(0,"div",0),iC(1),$l(),Bl(2,"div",1)(3,"div",2),PC(4),$l(),Bl(5,"div",3),jg("click",function(E){return s.trackEvent(E)}),iC(6,1),Bl(7,"div",4),yg(8,"div",5),$l(),Bl(9,"div",6)(10,"div",7)(11,"div",8),PC(12),$l()()()(),Bl(13,"div",9),PC(14),$l()()),n&2&&(DE(4),rm("",s.inputState().min,"",s.unit()),DE(4),zg("width",s.trackFilledPercentage(),"%"),DE(),zg("left",s.thumbPositionPercentage(),"%"),DE(3),rm("",s.value(),"",s.unit()),DE(2),rm("",s.inputState().max,"",s.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 rn=["formRef"],ln=()=>[import('./chunk-BNf0YAwH.js').then(i=>i.OptionsListComponent)];function _n(i,t){i&1&&(Qi(0,"sh-alert",3),XT(1,1),Hl());}function cn(i,t){if(i&1){let e=gT();Qi(0,"app-options-list",5),sm("optionsChange",function(s){Sd(e);let l=nC();return HC(l.settings,s)||(l.settings=s),xd(s)}),Hl();}if(i&2){let e=nC();im("options",e.settings),gg("hasFreeTextSettings",true);}}var K=class i{#n=T(O);#i=T(C$1);formRef=y1.required("formRef");settings=Ue([]);isSubmitting=Ue(false);isLoadingOptions=Ue(true);saved=Ue(false);lastRecievedServerSettings=Ue({});serverSettingsEffect=Ga(()=>{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,s],l)=>{if(n.startsWith("--")){let E=n.substring(2);this.settings.update(g=>(g.some(m=>m.Name===E||m.Name===n)||g.push({Name:n,Value:s}),g));}l===e.length-1&&this.isLoadingOptions.set(false);});});submit(){this.isSubmitting.set(true);let t=this.settings(),e=this.lastRecievedServerSettings(),n=t.map(g=>g.Name?.startsWith("--")?g.Name:`--${g.Name}`),l=Object.keys(e).filter(g=>g.startsWith("--")).filter(g=>!n.includes(g)),E=t.reduce((g,m)=>{let f=m.Name?.startsWith("--")?m.Name:`--${m.Name}`;return g[f]=m.Value,g},{});l.forEach(g=>{E[g]=null;}),this.#i.patchApiV1Serversettings({requestBody:E}).pipe(Bu(()=>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=dw({type:i,selectors:[["app-advanced-options-settings"]],viewQuery:function(e,n){e&1&&$g(n.formRef,rn,5),e&2&&lC();},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&&(Qi(0,"div",2),oT(1,_n,2,0,"sh-alert",3),Qi(2,"button",4),Fg("click",function(){return n.submit()}),Og(3,0),mg(4,"sh-icon"),Pg(),Hl()(),sg(5,cn,1,2),tT(6,5,ln)),e&2&&(DE(),iT(n.saved()?1:-1),DE(),Qg("loading",n.isSubmitting()),DE(4),nT(!n.isLoadingOptions()));},dependencies:[Gn$1,v,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 Tn(i,t){if(i&1){let e=gT();Qi(0,"sh-form-field",12)(1,"input",13),sm("ngModelChange",function(s){Sd(e);let l=nC(2);return HC(l.registerUrl,s)||(l.registerUrl=s),xd(s)}),Hl(),DD(),Hl(),Qi(2,"button",14),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.register())}),XT(3,0),Hl();}if(i&2){let e=nC(2);DE(),im("ngModel",e.registerUrl),TD();}}function Sn(i,t){if(i&1&&(Qi(0,"div",9)(1,"label"),XT(2,1),Hl(),Qi(3,"a",15),PC(4),Hl()()),i&2){let e=nC(2);DE(3),gg("href",UC(e.claimUrl()),Wp),DE(),nm(e.claimUrl());}}function un(i,t){i&1&&(Qi(0,"div",9)(1,"label"),XT(2,2),Hl()());}function gn(i,t){if(i&1){let e=gT();Qi(0,"button",14),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.cancel())}),XT(1,3),Hl();}}function pn(i,t){if(i&1){let e=gT();Qi(0,"button",14),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.disable())}),XT(1,4),Hl();}}function Cn(i,t){if(i&1){let e=gT();Qi(0,"button",14),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.enable())}),XT(1,5),Hl(),Qi(2,"button",16),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.delete())}),XT(3,6),Hl();}}function mn(i,t){i&1&&(Og(0,7,1),mg(1,"sh-icon"),Pg());}function En(i,t){i&1&&(Og(0,7,2),mg(1,"sh-icon"),Pg());}function Nn(i,t){if(i&1){let e=gT();Qi(0,"sh-chip",17),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.copyReportingUrl())}),Og(1,7),oT(2,mn,2,0,"sh-icon")(3,En,2,0,"sh-icon"),Pg(),Hl();}if(i&2){let e=nC(2);DE(2),iT(e.copiedReportingUrl()===true?2:3);}}function hn(i,t){if(i&1&&(Qi(0,"div",8),oT(1,Tn,4,1),oT(2,Sn,5,3,"div",9),oT(3,un,3,0,"div",9),oT(4,gn,2,0,"button",10),oT(5,pn,2,0,"button",10),oT(6,Cn,4,0),oT(7,Nn,4,1,"sh-chip",11),Hl()),i&2){let e=nC();DE(),iT(e.state()==="inactive"?1:-1),DE(),iT(e.state()==="registered"?2:-1),DE(),iT(e.state()==="registering"?3:-1),DE(),iT(e.state()==="registering"||e.state()==="registeringfaulted"||e.state()==="registered"?4:-1),DE(),iT(e.state()==="connected"||e.state()==="connecting"?5:-1),DE(),iT(e.state()==="disabled"?6:-1),DE(),iT(e.additionalReportingUrl()!==""&&e.state()!=="registered"?7:-1);}}var Te=class i{#n=T(C);#i=T(O);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=Ue(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=dw({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 s;s=$localize`Cancel registration`;let l;l=$localize`Disable console connection`;let E;E=$localize`Enable console connection`;let g;g=$localize` Delete console connection setup `;let m;return m=$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:`,m=tC(m),[t,e,n,s,l,E,g,m,[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&&oT(0,hn,8,7,"div",8),e&2&&iT(n.state()!=="unknown"?0:-1);},dependencies:[Bn$1,Ze,Rn$1,Jt,Fe,v,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}"]})};function nn(...i){let t=Ue(...i);return Object.defineProperty(t,"value",{get:t.asReadonly(),set:t.set.bind(t)})}var Se=()=>({standalone:true});function fn(i,t){i&1&&(Qi(0,"sh-chip",90),XT(1,33),Hl());}function In(i,t){if(i&1&&(Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,32),Hl(),Qi(4,"p"),PC(5),Hl()(),Qi(6,"div",68),oT(7,fn,2,0,"sh-chip",90),Hl()()),i&2){let e=nC();DE(5),nm(e.remoteControlStatus()),DE(2),iT(e.additionalReportingUrl()!==""&&e.remoteControlState()!=="registered"?7:-1);}}function Mn(i,t){if(i&1&&(Qi(0,"label"),Og(1,37),mg(2,"sh-icon",92),Pg(),Hl()),i&2){let e=nC(3);DE(2),gg("shTooltip",e.remoteControlTooltip());}}function Pn(i,t){if(i&1&&(Qi(0,"label"),Og(1,38),mg(2,"sh-icon",92),Pg(),Hl()),i&2){let e=nC(3);DE(2),gg("shTooltip",e.remoteControlTooltip());}}function On(i,t){if(i&1&&(Qi(0,"label"),Og(1,39),mg(2,"sh-icon",92),Pg(),Hl()),i&2){let e=nC(3);DE(2),gg("shTooltip",e.connectionStatusIndicatorTooltip());}}function bn(i,t){if(i&1&&(Qi(0,"label"),Og(1,40),mg(2,"sh-icon",92),Pg(),Hl()),i&2){let e=nC(3);DE(2),gg("shTooltip",e.connectionStatusIndicatorTooltip());}}function vn(i,t){if(i&1){let e=gT();Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,35),Hl(),Qi(4,"p"),XT(5,36),Hl()(),Qi(6,"div",91)(7,"sh-toggle",79),Fg("checkedChange",function(s){Sd(e);let l=nC(2);return xd(l.toggleConsoleControl(s))}),oT(8,Mn,3,1,"label")(9,Pn,3,1,"label"),Hl(),Qi(10,"sh-toggle",79),Fg("checkedChange",function(s){Sd(e);let l=nC(2);return xd(l.saveHideConsoleConnectionStatus(s))}),oT(11,On,3,1,"label")(12,bn,3,1,"label"),Hl()()();}if(i&2){let e=nC(2);DE(7),gg("checked",!e.consoleControlDisabled()),DE(),iT(e.consoleControlDisabled()?8:9),DE(2),gg("checked",!e.hideConsoleConnectionStatus()),DE(),iT(e.hideConsoleConnectionStatus()?11:12);}}function Rn(i,t){i&1&&(Qi(0,"label"),XT(1,43),Hl());}function Gn(i,t){i&1&&(Qi(0,"label"),XT(1,44),Hl());}function yn(i,t){if(i&1){let e=gT();Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,41),Hl(),Qi(4,"p"),XT(5,42),Hl()(),Qi(6,"div",68)(7,"sh-toggle",79),Fg("checkedChange",function(s){Sd(e);let l=nC(2);return xd(l.saveHideConsoleConnectionStatus(s))}),oT(8,Rn,2,0,"label")(9,Gn,2,0,"label"),Hl()()();}if(i&2){let e=nC(2);DE(7),gg("checked",!e.hideConsoleConnectionStatus()),DE(),iT(e.hideConsoleConnectionStatus()?8:9);}}function Fn(i,t){if(i&1&&(Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,34),Hl(),Qi(4,"p"),PC(5),Hl()(),Qi(6,"div",68),mg(7,"app-remote-control"),Hl()(),oT(8,vn,13,4,"section")(9,yn,10,2,"section")),i&2){let e=nC();DE(5),nm(e.remoteControlStatus()),DE(3),iT(e.remoteControlState()!="inactive"?8:9);}}function $n(i,t){i&1&&(Qi(0,"sh-icon",97),PC(1,"check"),Hl());}function An(i,t){i&1&&(Qi(0,"sh-icon",98),PC(1,"prohibit"),Hl());}function Ln(i,t){if(i&1){let e=gT();Qi(0,"button",102),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.updatePassphrase())}),XT(1,48),Hl();}if(i&2){let e=nC(2);Qg("loading",e.isUpdating());}}function wn(i,t){if(i&1){let e=gT();Qi(0,"button",103),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.updatePassphrase())}),XT(1,49),Hl();}if(i&2){let e=nC(2);Qg("loading",e.isUpdating()),gg("disabled",true);}}function Dn(i,t){if(i&1){let e=gT();Qi(0,"sh-form-field")(1,"label",93),XT(2,45),Hl(),Qi(3,"input",94),sm("ngModelChange",function(s){Sd(e);let l=nC();return HC(l.passphrase,s)||(l.passphrase=s),xd(s)}),Hl(),DD(),Hl(),Qi(4,"sh-form-field")(5,"label",95),XT(6,46),Hl(),Qi(7,"input",96),sm("ngModelChange",function(s){Sd(e);let l=nC();return HC(l.repeatPassphrase,s)||(l.repeatPassphrase=s),xd(s)}),Hl(),DD(),oT(8,$n,2,0,"sh-icon",97)(9,An,2,0,"sh-icon",98),Hl(),Qi(10,"div",73)(11,"button",99),Fg("click",function(){Sd(e);let s=nC();return xd(s.cancelPasswordChange())}),XT(12,47),Hl(),oT(13,Ln,2,2,"button",100)(14,wn,2,3,"button",101),Hl();}if(i&2){let e=nC();DE(3),im("ngModel",e.passphrase),TD(),DE(4),gg("disabled",e.passphrase().length===0),im("ngModel",e.repeatPassphrase),TD(),DE(),iT(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?8:9),DE(3),Qg("loading",e.isUpdating()),DE(2),iT(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?13:14);}}function xn(i,t){i&1&&(Qi(0,"sh-icon",104),PC(1,"check"),Hl());}function kn(i,t){if(i&1){let e=gT();Qi(0,"div",73)(1,"button",99),Fg("click",function(){Sd(e);let s=nC();return xd(s.openPassphraseForm())}),XT(2,50),Hl(),oT(3,xn,2,0,"sh-icon",104),Hl();}if(i&2){let e=nC();DE(3),iT(e.passwordUpdated()?3:-1);}}function Xn(i,t){i&1&&(Og(0,11,1),mg(1,"span"),Pg());}function Jn(i,t){i&1&&(Og(0,11,2),mg(1,"span"),Pg());}function zn(i,t){if(i&1){let e=gT();Qi(0,"sh-form-field")(1,"label",105),XT(2,51),Hl(),Qi(3,"textarea",106),sm("ngModelChange",function(s){Sd(e);let l=nC();return HC(l.allowedHostnames,s)||(l.allowedHostnames=s),xd(s)}),Hl(),DD(),Hl(),Qi(4,"sh-alert",107),XT(5,52),Hl(),Qi(6,"button",102),Fg("click",function(){Sd(e);let s=nC();return xd(s.updateAllowedHostnames())}),XT(7,53),Hl();}if(i&2){let e=nC();DE(3),im("ngModel",e.allowedHostnames),TD(),DE(3),Qg("loading",e.updatingAllowedHosts());}}function Vn(i,t){if(i&1){let e=gT();Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,54),Hl(),Qi(4,"p"),XT(5,55),Hl()(),Qi(6,"div",68)(7,"sh-select",108)(8,"input",75),Fg("ngModelChange",function(s){Sd(e);let l=nC();return xd(l.updatePowerMode(s))}),Hl(),DD(),Hl()()();}if(i&2){let e=nC();DE(7),gg("options",e.powerModeOptions())("isClearable",false),DE(),gg("ngModel",e.powerModeCtrl())("ngModelOptions",QC(4,Se)),TD();}}function Un(i,t){if(i&1&&(Qi(0,"p"),XT(1,56),Hl()),i&2){let e=nC();DE(),Lg(e.sysinfo()?.ServerVersionName),eC(1);}}function Bn(i,t){i&1&&mg(0,"sh-progress-bar",80);}function Hn(i,t){if(i&1&&PC(0),i&2){let e=t.$implicit;Gl(" ",e.label," ");}}function Wn(i,t){if(i&1&&PC(0),i&2){let e=t.$implicit;Gl(" ",e.label," ");}}function jn(i,t){if(i&1){let e=gT();Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,57),Hl(),Qi(4,"p")(5,"span"),XT(6,58),Hl(),Qi(7,"a",109),XT(8,59),Hl(),mg(9,"br")(10,"br"),Qi(11,"span"),XT(12,60),Hl()()(),Qi(13,"div",68)(14,"sh-select",110)(15,"input",75),Fg("ngModelChange",function(s){Sd(e);let l=nC();return xd(l.updateUsageStatistics(s))}),Hl(),DD(),ig(16,Wn,1,1,"ng-template"),Hl()()();}if(i&2){let e=nC();DE(14),gg("options",e.usageStatisticsOptions())("isLoading",e.updatingUsageStatistics()),DE(),gg("ngModel",e.usageStatistics())("ngModelOptions",QC(4,Se)),TD();}}function qn(i,t){i&1&&(Qi(0,"label"),XT(1,63),Hl());}function Kn(i,t){i&1&&(Qi(0,"label"),XT(1,64),Hl());}function Qn(i,t){if(i&1){let e=gT();Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,61),Hl(),Qi(4,"p"),XT(5,62),Hl()(),Qi(6,"div",91)(7,"p"),PC(8,"Backup process isolation"),Hl(),Qi(9,"sh-toggle",79),Fg("checkedChange",function(s){Sd(e);let l=nC();return xd(l.saveControllerIpcState(s))}),oT(10,qn,2,0,"label")(11,Kn,2,0,"label"),Hl()()();}if(i&2){let e=nC();DE(9),gg("checked",e.isControllerIpcEnabled()),DE(),iT(e.isControllerIpcEnabled()?10:11);}}function Yn(i,t,e){let n=nn(i),s=n[H];e?.equal&&(s.equal=e.equal);let l;return n.set=E=>{clearTimeout(l),l=setTimeout(()=>ft(s,E),t);},n.update=E=>{clearTimeout(l),l=setTimeout(()=>po(s,E),t);},n}var Zn=[{value:"none",label:$localize`None`},{value:"s",label:$localize`Seconds`},{value:"m",label:$localize`Minutes`},{value:"h",label:$localize`Hours`}],on=[{value:"none",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:"disabled",label:$localize`None / disabled`}],fe=class i{#n=T(be);#i=T(m);#e=T(m$1);#t=T(O);#o=T(C);#r=T(g);#s=T(h);#a=this.#s.getItem("locale")??"en-US";sysinfo=this.#e.systemInfo;isDarkMode=this.#i.isDarkMode;editAs=Ue("list");previousLang=this.#a;langCtrl=Ue(this.#a);powerModeCtrl=Ue("");usageStatistics=Ue("");updatingUsageStatistics=Ue(false);remoteControlStatus=this.#o.statusMessage;remoteControlState=this.#o.state;updatingChannel=Ue(false);updateChannel=Ue("");isUsingRelay=this.#r.relayIsEnabled;defaultClient=Ue(this.#d());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=Ga(()=>{let t=this.#e.systemInfo()?.DefaultUsageReportLevel??"",e=on;e[0].label=$localize`System default (${t})`,this.usageStatisticsOptions.set(e);});remoteControlTooltip=Ue($localize`Disabling console control will disable remote access to this machine from the console, but will keep the
|
|
3
|
-
registration intact and allow pushing settings from the console.`);connectionStatusIndicatorTooltip=Ue($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(Bu(()=>this.updatingChannel.set(false))).subscribe();}allowRemoteAccess=Ue(false);allowedHostnames=Ue("");loadedAllowedHostnames=Ue("");updatingRemoteAccess=Ue(false);updatingAllowedHosts=Ue(false);updatingConsoleControl=Ue(false);consoleControlDisabled=Ue(false);hideConsoleConnectionStatus=this.#t.isConsoleConnectionStatusHidden;isControllerIpcEnabled=this.#t.isControllerIpcEnabled;updateRemoteAccess(t){this.allowRemoteAccess.set(t),this.#t.setRemoteAccessInterface(t?"any":"loopback").pipe(Bu(()=>this.updatingRemoteAccess.set(false))).subscribe();}updateAllowedHostnames(){let t=this.allowedHostnames();this.updatingAllowedHosts.set(true),this.#t.setRemoteAccessAllowedHostnames(t).pipe(Bu(()=>this.updatingAllowedHosts.set(false))).subscribe();}toggleConsoleControl(t){this.consoleControlDisabled.set(!t),this.#t.setDisableConsoleControl(!t).pipe(Bu(()=>this.updatingConsoleControl.set(false))).subscribe();}updatingDisableTrayIconLogin=Ue(false);disableTrayIconLogin=Ue(false);saveDisableTrayIconLogin(t){let e=t;this.updatingDisableTrayIconLogin.set(true),this.#t.setDisableTrayIconLogin(e).pipe(Bu(()=>this.updatingDisableTrayIconLogin.set(false))).subscribe();}updatingHideConsoleConnectionStatus=Ue(false);saveHideConsoleConnectionStatus(t){this.updatingHideConsoleConnectionStatus.set(true),this.#t.setHideConsoleConnectionStatus(!t).pipe(Bu(()=>this.updatingHideConsoleConnectionStatus.set(false))).subscribe();}updatingControllerIpcState=Ue(false);saveControllerIpcState(t){this.updatingControllerIpcState.set(true),this.#t.setControllerIpcState(!!t).pipe(Bu(()=>this.updatingControllerIpcState.set(false))).subscribe();}showPassphraseForm=Ue(false);isUpdating=Ue(false);passphrase=Ue("");repeatPassphrase=Ue("");passwordUpdated=Ue(false);updatePassphrase(){this.passphrase()===this.repeatPassphrase()&&(this.isUpdating.set(true),this.#t.setRemoteAccessPassword(this.passphrase()).pipe(Bu(()=>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=Ue(It);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=Ue(on);timeTypeOptions=Ue(Zn);timeType=Ue("none");timeValue=Yn(0,300);timeRange=Nt(()=>this.timeType()==="h"?[1,24]:[1,60]);updateLocale(t){!t||t===""||t===this.previousLang||(this.#s.setItem("locale",t),window.location.reload());}updateTimeValue(t){this.timeValue.set(t),this.#_();}updateTimeType(t){this.timeType()==="none"&&this.timeValue.set(1),this.timeType.set(t),this.#_();}#l;#_(){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||t===""||t===e||(this.usageStatistics.set(t),this.updatingUsageStatistics.set(true),this.#t.setUsageReporterLevel(t).subscribe());}updatePowerMode(t){this.powerModeCtrl()!==t&&(t==="default"&&(t=""),this.#t.setPowerModeProvider(t).subscribe());}serverSettingsEffect=Ga(()=>{let t=this.#t.serverSettings();if(t===void 0)return;let e=t["startup-delay"],n=e.slice(-1),s=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(t["usage-reporter-level"]===""?"none":t["usage-reporter-level"]),this.timeType.set(e==""?"none":l.includes(n)?n:"none"),this.timeValue.set(e==""?0:parseInt(s));let E=t["power-mode-provider"]===""||t["power-mode-provider"]==null?"default":t["power-mode-provider"];this.powerModeCtrl.set(E);});setDarkMode(){this.#i.setDarkMode();}setLightMode(){this.#i.setLightMode();}changeDefaultClientTo(t){this.defaultClient()!==t&&(t==="ngax"?this.#n.open(h$1,{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.#c(t));}}):this.#c(t));}openLegacyUI(){this.#n.open(h$1,{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");}});}#c(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);}#d(){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=dw({type:i,selectors:[["app-settings"]],decls:130,vars:38,consts:()=>{let t;t=$localize`Settings`;let e;e=$localize`Configure your backup settings.`;let n;n=$localize`Color theme`;let s;s=$localize`Customize your application theme`;let l;l=$localize`Passwords`;let E;E=$localize`Change server passphrase`;let g;g=$localize`Language`;let m;m=$localize`Select a language for the platform`;let f;f=$localize`Use legacy interface`;let W;W=$localize`Use the old user interface, not recommended unless you have a specific reason.`;let ue;ue=$localize`${"\uFFFD#47\uFFFD"}:START_TAG_SH_ICON:arrow-square-right${"\uFFFD/#47\uFFFD"}:CLOSE_TAG_SH_ICON: Open legacy UI `;let J;J=$localize`${"\uFFFD#50\uFFFD"}:START_TAG_SH_ICON:swap${"\uFFFD/#50\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD*51: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/*51:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*52: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/*52:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,J=tC(J);let z;z=$localize`Allow remote access (requires restart)`;let Q;Q=$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 Y;Y=$localize`Allow remote access`;let Ie;Ie=$localize`Prevent tray icon automatic log-in`;let Me;Me=$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 Pe;Pe=$localize`Prevent tray icon automatic log-in`;let Oe;Oe=$localize`Update channel`;let be;be=$localize` Default (${"\uFFFD0\uFFFD"}:INTERPOLATION:) `;let ve;ve=$localize`Same as the base install version: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Re;Re=$localize`Stable`;let Ge;Ge=$localize`Official stable release.`;let ye;ye=$localize`Beta`;let Fe;Fe=$localize` Try out the new features that we are working on. Test a backup and restore before using this in production environments. `;let $e;$e=$localize`Experimental`;let Ae;Ae=$localize`Early previews of new features. Not for use with important data.`;let Le;Le=$localize`Canary`;let we;we=$localize`Builds for developers and testers only. Not for use with important data.`;let De;De=$localize`Pause after startup or hibernation`;let xe;xe=$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 ke;ke=$localize`Advanced options`;let Xe;Xe=$localize`Console connection status`;let Je;Je=$localize`Reporting configured by server`;let ze;ze=$localize`Connect to console`;let Ve;Ve=$localize`Configure console control`;let Ue;Ue=$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 Be;Be=$localize` Remote control disabled ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let He;He=$localize` Remote control enabled ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let We;We=$localize` Console connection status is hidden ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let je;je=$localize` Console connection status is visible ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let qe;qe=$localize`Toggle console connection status`;let Ke;Ke=$localize`Toggle the visibility of the console connection status indicator.`;let Qe;Qe=$localize`Console connection status is hidden`;let Ye;Ye=$localize`Console connection status is visible`;let Ze;Ze=$localize`Enter new password`;let et;et=$localize`Repeat password`;let ge;ge=$localize`Password have to be filled and have to match`;let tt;tt=$localize`Passphrase`;let nt;nt=$localize`Repeat passphrase`;let it;it=$localize`Cancel`;let ot;ot=$localize` Update passphrase `;let st;st=$localize` Update passphrase `;let at;at=$localize`Change password`;let rt;rt=$localize`Allowed hostnames`;let lt;lt=$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 _t;_t=$localize` Update allowed hostnames `;let ct;ct=$localize`Power mode provider`;let dt;dt=$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 Tt;Tt=$localize`Installed version: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let St;St=$localize`Usage statistics`;let ut;ut=$localize` Usage reports help us improve the user experience and evaluate impact of new features. We use them to generate `;let gt;gt=$localize`public usage statistics.`;let pt;pt=$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 Ct;Ct=$localize`Experimental options`;let mt;mt=$localize`Toggle experimental options.`;let Et;Et=$localize`Operations run in an isolated process`;let Nt;return Nt=$localize`Operations run inside the server process`,[t,e,n,s,l,E,g,m,f,W,ue,J,z,Q,Y,Ie,Me,Pe,Oe,be,ve,Re,Ge,ye,Fe,$e,Ae,Le,we,De,xe,ke,Xe,Je,ze,Ve,Ue,Be,He,We,je,qe,Ke,Qe,Ye,tt,nt,it,ot,st,at,rt,lt,_t,ct,dt,Tt,St,ut,gt,pt,Ct,mt,Et,Nt,[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","buttons"],["shButton","",1,"primary",3,"click"],[1,"right","remote-access-form"],[1,"primary","raised",3,"checkedChange","checked"],[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"],[1,"right","multiple"],["suffix","",3,"shTooltip"],["for","password"],["type","password","name","password","autocomplete","new-password","placeholder",Ze,"tabindex","1",3,"ngModelChange","ngModel"],["for","repeatPassword"],["type","password","name","repeatPassword","autocomplete","new-password","placeholder",et,"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&&(mg(0,"app-status-bar"),Qi(1,"div",65)(2,"header")(3,"div",66)(4,"h2"),XT(5,0),Hl(),Qi(6,"p"),XT(7,1),Hl()()(),oT(8,In,8,2,"section")(9,Fn,10,2),Qi(10,"section")(11,"div",67)(12,"h3"),XT(13,2),Hl(),Qi(14,"p"),XT(15,3),Hl()(),Qi(16,"div",68)(17,"div",69)(18,"img",70),Fg("click",function(){return n.setLightMode()}),Hl(),Qi(19,"img",71),Fg("click",function(){return n.setDarkMode()}),Hl()()()(),Qi(20,"section")(21,"div",67)(22,"h3"),XT(23,4),Hl(),Qi(24,"p"),XT(25,5),Hl()(),Qi(26,"div",72),oT(27,Dn,15,7)(28,kn,4,1,"div",73),Hl()(),Qi(29,"section")(30,"div",67)(31,"h3"),XT(32,6),Hl(),Qi(33,"p"),XT(34,7),Hl()(),Qi(35,"div",68)(36,"sh-select",74)(37,"input",75),Fg("ngModelChange",function(l){return n.updateLocale(l)}),Hl(),DD(),Hl()()(),Qi(38,"section")(39,"div",67)(40,"h3"),XT(41,8),Hl(),Qi(42,"p"),XT(43,9),Hl()(),Qi(44,"div",76)(45,"button",77),Fg("click",function(){return n.openLegacyUI()}),Og(46,10),mg(47,"sh-icon"),Pg(),Hl(),Qi(48,"button",77),Fg("click",function(){return n.changeDefaultClientTo(n.defaultClient()==="ngclient"?"ngax":"ngclient")}),Og(49,11),mg(50,"sh-icon"),oT(51,Xn,2,0,"span")(52,Jn,2,0,"span"),Pg(),Hl()()(),Qi(53,"section")(54,"div",67)(55,"h3"),XT(56,12),Hl(),Qi(57,"p"),XT(58,13),Hl()(),Qi(59,"div",78)(60,"sh-toggle",79),Fg("checkedChange",function(l){return n.updateRemoteAccess(l)}),Qi(61,"label"),XT(62,14),Hl()(),oT(63,zn,8,3),Hl()(),Qi(64,"section")(65,"div",67)(66,"h3"),XT(67,15),Hl(),Qi(68,"p"),XT(69,16),Hl()(),Qi(70,"div",68)(71,"sh-toggle",79),Fg("checkedChange",function(l){return n.saveDisableTrayIconLogin(l)}),Qi(72,"label"),XT(73,17),Hl()()()(),oT(74,Vn,9,5,"section"),Qi(75,"section")(76,"div",67)(77,"h3"),XT(78,18),Hl(),oT(79,Un,2,1,"p"),oT(80,Bn,1,0,"sh-progress-bar",80),Hl(),Qi(81,"div",81)(82,"div",82),Fg("click",function(){return n.setNewChannel("")}),Qi(83,"sh-radio",83),XT(84,19),Hl(),Qi(85,"p"),XT(86,20),Hl()(),Qi(87,"div",82),Fg("click",function(){return n.setNewChannel("stable")}),Qi(88,"sh-radio",83),XT(89,21),Hl(),Qi(90,"p"),XT(91,22),Hl()(),Qi(92,"div",82),Fg("click",function(){return n.setNewChannel("beta")}),Qi(93,"sh-radio",83),XT(94,23),Hl(),Qi(95,"p"),XT(96,24),Hl()(),Qi(97,"div",82),Fg("click",function(){return n.setNewChannel("experimental")}),Qi(98,"sh-radio",83),XT(99,25),Hl(),Qi(100,"p"),XT(101,26),Hl()(),Qi(102,"div",82),Fg("click",function(){return n.setNewChannel("canary")}),Qi(103,"sh-radio",83),XT(104,27),Hl(),Qi(105,"p"),XT(106,28),Hl()()()(),Qi(107,"section")(108,"div",67)(109,"h3"),XT(110,29),Hl(),Qi(111,"p"),XT(112,30),Hl()(),Qi(113,"div",68)(114,"div",84)(115,"sh-range-slider",85)(116,"input",86),sm("ngModelChange",function(l){return HC(n.timeValue,l)||(n.timeValue=l),l}),Fg("ngModelChange",function(l){return n.updateTimeValue(l)}),Hl(),DD(),Hl(),Qi(117,"sh-select",87)(118,"input",88),Fg("ngModelChange",function(l){return n.updateTimeType(l)}),Hl(),DD(),ig(119,Hn,1,1,"ng-template"),Hl()()()(),oT(120,jn,17,5,"section"),oT(121,Qn,12,2,"section"),Hl(),mg(122,"sh-divider"),Qi(123,"div",65)(124,"section")(125,"div",89)(126,"h3"),XT(127,31),Hl(),mg(128,"app-advanced-options-settings"),Hl()()(),mg(129,"sh-divider")),e&2&&(DE(8),iT(n.isUsingRelay()?8:9),DE(10),Qg("active",!n.isDarkMode()),DE(),Qg("active",n.isDarkMode()),DE(8),iT(n.showPassphraseForm()?27:28),DE(9),gg("options",n.languageOptions())("isClearable",false)("inlineSearch",true),DE(),gg("ngModel",n.langCtrl())("ngModelOptions",QC(36,Se)),TD(),DE(14),iT(n.defaultClient()==="ngax"?51:52),DE(9),gg("checked",n.allowRemoteAccess()),DE(3),iT(n.allowRemoteAccess()?63:-1),DE(8),gg("checked",n.disableTrayIconLogin()),DE(3),iT(n.powerModeOptions().length>0?74:-1),DE(5),iT(n.sysinfo()?.ServerVersion?79:-1),DE(),iT(n.updatingChannel()?80:-1),DE(3),gg("checked",n.updateChannel()===""),DE(),Lg(n.sysinfo()?.DefaultUpdateChannel),eC(84),DE(2),Lg(n.sysinfo()?.ServerVersionType),eC(86),DE(2),gg("checked",n.updateChannel()==="stable"),DE(5),gg("checked",n.updateChannel()==="beta"),DE(5),gg("checked",n.updateChannel()==="experimental"),DE(5),gg("checked",n.updateChannel()==="canary"),DE(12),gg("unit",n.timeType()==="none"?"s":n.timeType()),DE(),gg("min",n.timeRange()[0])("max",n.timeRange()[1])("disabled",n.timeType()==="none"),im("ngModel",n.timeValue),gg("ngModelOptions",QC(37,Se)),TD(),DE(),gg("options",n.timeTypeOptions())("isClearable",false),DE(),gg("ngModel",n.timeType()),TD(),DE(2),iT(n.usageStatisticsDisabled()?-1:120),DE(),iT(n.hasIpcController()?121:-1));},dependencies:[Bn$1,Ze,on$1,Rn$1,Jt,Gn$1,ee,Te,K,v,O$1,en,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}"]})};
|
|
1
|
+
import {J}from'./chunk-B2fqvpov.js';import {e as ee}from'./chunk-D_JCqKo8.js';import'./chunk-w_Hs_Uxi.js';import {O as O$1}from'./chunk-D1wHRltX.js';import {N as Nt$1}from'./chunk-CBdr-6_u.js';import'./chunk-BZqhgAZ-.js';import {m}from'./chunk-B9zNFJSv.js';import {c}from'./chunk-COgNe44h.js';import {D}from'./chunk-BAZ5npJw.js';import {bi as bs,bj as H,bk as ft,bl as po,T,a6 as be,m as m$1,g,bm as h,U as Ue,N as Nt,G as Ga,C as Bu,bn as It,at as h$1,d as dw,v,f as N,u as ue,j as mg,Q as Qi,X as XT,H as Hl,o as oT,F as Fg,p as DD,O as Og,P as Pg,s as sm,bf as ig,D as DE,i as iT,I as Qg,z as gg,a3 as QC,y as TD,au as Lg,av as eC,w as im,t as tC,l as HC,ab as C$1,B as y1,b2 as sg,b3 as tT,b4 as nT,$ as $g,K as lC,ae as Jr,b as g1,af as m1,b8 as ce,L as oC,R as Bl,Y as iC,W as $l,q as PC,an as jg,V as yg,aB as rm,ag as zg,h as bC,n as nC,E as nm,k as gT,S as Sd,x as xd,ar as Wp,a9 as UC,aa as Gl}from'./main-PXGZLKMN.js';import {C}from'./chunk-MvQwR7nW.js';import {O}from'./chunk-SycscfJp.js';import {d}from'./chunk-DQW8lSiz.js';import'./chunk-CMmgPgiU.js';import {F as Fe}from'./chunk-C9EdrQe6.js';import {B as Bn$1,Z as Ze,o as on$1,R as Rn$1,J as Jt,G as Gn$1}from'./chunk-Drc5kcUX.js';import {a as at}from'./chunk-B-fklW6A.js';import'./chunk-D28lTX0k.js';var sn=[[["label"]],[["input","type","range"]]],an=["label","input[type=range]"],tn=(()=>{class i{constructor(){this.hasInput=Ue(false),this.#n=T(Jr),this.#i=null,this.#e=null,this.#t=0,this.unit=g1(""),this.value=m1(this.#t),this.inputState=Ue({min:0,max:100,step:1}),this.color=g1(null),this.variant=g1(null),this.size=g1(null),this.sharp=g1(void 0),this.alwaysShow=g1(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(),s=this.value()??e;if(isNaN(s))return 0;let l=n-e;if(l===0)return 0;let E=(s-e)/l*100;return Math.max(0,Math.min(100,E))}),this.trackFilledPercentage=Nt(()=>this.valuePercentage()),this.thumbPositionPercentage=Nt(()=>this.valuePercentage()),this.syncModelToInputEffect=Ga(()=>{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.#o(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:s,max:l}=this.inputState();this.value.set(Math.max(s,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 s=e.currentTarget.getBoundingClientRect(),l=e.clientX-s.left,E=s.width,{min:S,max:m,step:f}=this.inputState(),W=m-S;if(E>0&&W!==0&&f>0){let J=(l/E*W+S-S)/f,z=S+Math.round(J)*f,Q=this.#s(f);z=parseFloat(z.toFixed(Q));let Y=Math.max(S,Math.min(m,z));this.value.set(Y);}}#o(e=false){if(!this.#e)return;let n=parseFloat(this.#e.min??"0")??0,s=parseFloat(this.#e.max??"100")??100,l=this.#e.step,E=1;if(l&&l.toLowerCase()!=="any"){let m=parseFloat(l);!isNaN(m)&&m>0&&(E=m);}this.inputState.set({min:n,max:s,step:E});let S=parseFloat(this.#e.value??String(n))??n;if(e&&this.value()!==this.#t){let m=this.value(),f=Math.max(n,Math.min(s,m));S!==f&&(this.#e.value=String(f)),m!==f&&this.value.set(f);}else {let m=Math.max(n,Math.min(s,S));this.value()!==m&&this.value.set(m);}}#r(){if(!this.#e||typeof MutationObserver>"u")return;let e=["min","max","step","value","readonly","disabled"];this.#i=new MutationObserver(n=>{let s=false;for(let l of n)if(l.type==="attributes"&&e.includes(l.attributeName??"")){s=true;break}s&&this.#o(false);}),this.#i.observe(this.#e,{attributes:true,attributeFilter:e});}#s(e){if(isNaN(e)||Math.floor(e)===e)return 0;let s=e.toString().split(".")[1];return s?s.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=dw({type:i,selectors:[["sh-range-slider"]],hostVars:6,hostBindings:function(n,s){n&2&&(bC(s.hostClasses()),Qg("sh-range-slider",true)("has-input",s.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:an,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,s){n&1&&(oC(sn),Bl(0,"div",0),iC(1),$l(),Bl(2,"div",1)(3,"div",2),PC(4),$l(),Bl(5,"div",3),jg("click",function(E){return s.trackEvent(E)}),iC(6,1),Bl(7,"div",4),yg(8,"div",5),$l(),Bl(9,"div",6)(10,"div",7)(11,"div",8),PC(12),$l()()()(),Bl(13,"div",9),PC(14),$l()()),n&2&&(DE(4),rm("",s.inputState().min,"",s.unit()),DE(4),zg("width",s.trackFilledPercentage(),"%"),DE(),zg("left",s.thumbPositionPercentage(),"%"),DE(3),rm("",s.value(),"",s.unit()),DE(2),rm("",s.inputState().max,"",s.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 rn=["formRef"],ln=()=>[import('./chunk-Bf1diO1u.js').then(i=>i.OptionsListComponent)];function _n(i,t){i&1&&(Qi(0,"sh-alert",3),XT(1,1),Hl());}function cn(i,t){if(i&1){let e=gT();Qi(0,"app-options-list",5),sm("optionsChange",function(s){Sd(e);let l=nC();return HC(l.settings,s)||(l.settings=s),xd(s)}),Hl();}if(i&2){let e=nC();im("options",e.settings),gg("hasFreeTextSettings",true);}}var K=class i{#n=T(O);#i=T(C$1);formRef=y1.required("formRef");settings=Ue([]);isSubmitting=Ue(false);isLoadingOptions=Ue(true);saved=Ue(false);lastRecievedServerSettings=Ue({});serverSettingsEffect=Ga(()=>{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,s],l)=>{if(n.startsWith("--")){let E=n.substring(2);this.settings.update(S=>(S.some(m=>m.Name===E||m.Name===n)||S.push({Name:n,Value:s}),S));}l===e.length-1&&this.isLoadingOptions.set(false);});});submit(){this.isSubmitting.set(true);let t=this.settings(),e=this.lastRecievedServerSettings(),n=t.map(S=>S.Name?.startsWith("--")?S.Name:`--${S.Name}`),l=Object.keys(e).filter(S=>S.startsWith("--")).filter(S=>!n.includes(S)),E=t.reduce((S,m)=>{let f=m.Name?.startsWith("--")?m.Name:`--${m.Name}`;return S[f]=m.Value,S},{});l.forEach(S=>{E[S]=null;}),this.#i.patchApiV1Serversettings({requestBody:E}).pipe(Bu(()=>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=dw({type:i,selectors:[["app-advanced-options-settings"]],viewQuery:function(e,n){e&1&&$g(n.formRef,rn,5),e&2&&lC();},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&&(Qi(0,"div",2),oT(1,_n,2,0,"sh-alert",3),Qi(2,"button",4),Fg("click",function(){return n.submit()}),Og(3,0),mg(4,"sh-icon"),Pg(),Hl()(),sg(5,cn,1,2),tT(6,5,ln)),e&2&&(DE(),iT(n.saved()?1:-1),DE(),Qg("loading",n.isSubmitting()),DE(4),nT(!n.isLoadingOptions()));},dependencies:[Gn$1,v,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 Tn(i,t){if(i&1){let e=gT();Qi(0,"sh-form-field",12)(1,"input",13),sm("ngModelChange",function(s){Sd(e);let l=nC(2);return HC(l.registerUrl,s)||(l.registerUrl=s),xd(s)}),Hl(),DD(),Hl(),Qi(2,"button",14),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.register())}),XT(3,0),Hl();}if(i&2){let e=nC(2);DE(),im("ngModel",e.registerUrl),TD();}}function Sn(i,t){if(i&1&&(Qi(0,"div",9)(1,"label"),XT(2,1),Hl(),Qi(3,"a",15),PC(4),Hl()()),i&2){let e=nC(2);DE(3),gg("href",UC(e.claimUrl()),Wp),DE(),nm(e.claimUrl());}}function un(i,t){i&1&&(Qi(0,"div",9)(1,"label"),XT(2,2),Hl()());}function gn(i,t){if(i&1){let e=gT();Qi(0,"button",14),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.cancel())}),XT(1,3),Hl();}}function pn(i,t){if(i&1){let e=gT();Qi(0,"button",14),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.disable())}),XT(1,4),Hl();}}function Cn(i,t){if(i&1){let e=gT();Qi(0,"button",14),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.enable())}),XT(1,5),Hl(),Qi(2,"button",16),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.delete())}),XT(3,6),Hl();}}function mn(i,t){i&1&&(Og(0,7,1),mg(1,"sh-icon"),Pg());}function En(i,t){i&1&&(Og(0,7,2),mg(1,"sh-icon"),Pg());}function Nn(i,t){if(i&1){let e=gT();Qi(0,"sh-chip",17),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.copyReportingUrl())}),Og(1,7),oT(2,mn,2,0,"sh-icon")(3,En,2,0,"sh-icon"),Pg(),Hl();}if(i&2){let e=nC(2);DE(2),iT(e.copiedReportingUrl()===true?2:3);}}function hn(i,t){if(i&1&&(Qi(0,"div",8),oT(1,Tn,4,1),oT(2,Sn,5,3,"div",9),oT(3,un,3,0,"div",9),oT(4,gn,2,0,"button",10),oT(5,pn,2,0,"button",10),oT(6,Cn,4,0),oT(7,Nn,4,1,"sh-chip",11),Hl()),i&2){let e=nC();DE(),iT(e.state()==="inactive"?1:-1),DE(),iT(e.state()==="registered"?2:-1),DE(),iT(e.state()==="registering"?3:-1),DE(),iT(e.state()==="registering"||e.state()==="registeringfaulted"||e.state()==="registered"?4:-1),DE(),iT(e.state()==="connected"||e.state()==="connecting"?5:-1),DE(),iT(e.state()==="disabled"?6:-1),DE(),iT(e.additionalReportingUrl()!==""&&e.state()!=="registered"?7:-1);}}var Te=class i{#n=T(C);#i=T(O);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=Ue(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=dw({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 s;s=$localize`Cancel registration`;let l;l=$localize`Disable console connection`;let E;E=$localize`Enable console connection`;let S;S=$localize` Delete console connection setup `;let m;return m=$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:`,m=tC(m),[t,e,n,s,l,E,S,m,[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&&oT(0,hn,8,7,"div",8),e&2&&iT(n.state()!=="unknown"?0:-1);},dependencies:[Bn$1,Ze,Rn$1,Jt,Fe,v,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 Se=()=>({standalone:true});function fn(i,t){i&1&&(Qi(0,"sh-chip",90),XT(1,33),Hl());}function In(i,t){if(i&1&&(Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,32),Hl(),Qi(4,"p"),PC(5),Hl()(),Qi(6,"div",68),oT(7,fn,2,0,"sh-chip",90),Hl()()),i&2){let e=nC();DE(5),nm(e.remoteControlStatus()),DE(2),iT(e.additionalReportingUrl()!==""&&e.remoteControlState()!=="registered"?7:-1);}}function Mn(i,t){if(i&1&&(Qi(0,"label"),Og(1,37),mg(2,"sh-icon",92),Pg(),Hl()),i&2){let e=nC(3);DE(2),gg("shTooltip",e.remoteControlTooltip());}}function Pn(i,t){if(i&1&&(Qi(0,"label"),Og(1,38),mg(2,"sh-icon",92),Pg(),Hl()),i&2){let e=nC(3);DE(2),gg("shTooltip",e.remoteControlTooltip());}}function On(i,t){if(i&1&&(Qi(0,"label"),Og(1,39),mg(2,"sh-icon",92),Pg(),Hl()),i&2){let e=nC(3);DE(2),gg("shTooltip",e.connectionStatusIndicatorTooltip());}}function bn(i,t){if(i&1&&(Qi(0,"label"),Og(1,40),mg(2,"sh-icon",92),Pg(),Hl()),i&2){let e=nC(3);DE(2),gg("shTooltip",e.connectionStatusIndicatorTooltip());}}function vn(i,t){if(i&1){let e=gT();Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,35),Hl(),Qi(4,"p"),XT(5,36),Hl()(),Qi(6,"div",91)(7,"sh-toggle",79),Fg("checkedChange",function(s){Sd(e);let l=nC(2);return xd(l.toggleConsoleControl(s))}),oT(8,Mn,3,1,"label")(9,Pn,3,1,"label"),Hl(),Qi(10,"sh-toggle",79),Fg("checkedChange",function(s){Sd(e);let l=nC(2);return xd(l.saveHideConsoleConnectionStatus(s))}),oT(11,On,3,1,"label")(12,bn,3,1,"label"),Hl()()();}if(i&2){let e=nC(2);DE(7),gg("checked",!e.consoleControlDisabled()),DE(),iT(e.consoleControlDisabled()?8:9),DE(2),gg("checked",!e.hideConsoleConnectionStatus()),DE(),iT(e.hideConsoleConnectionStatus()?11:12);}}function Rn(i,t){i&1&&(Qi(0,"label"),XT(1,43),Hl());}function Gn(i,t){i&1&&(Qi(0,"label"),XT(1,44),Hl());}function yn(i,t){if(i&1){let e=gT();Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,41),Hl(),Qi(4,"p"),XT(5,42),Hl()(),Qi(6,"div",68)(7,"sh-toggle",79),Fg("checkedChange",function(s){Sd(e);let l=nC(2);return xd(l.saveHideConsoleConnectionStatus(s))}),oT(8,Rn,2,0,"label")(9,Gn,2,0,"label"),Hl()()();}if(i&2){let e=nC(2);DE(7),gg("checked",!e.hideConsoleConnectionStatus()),DE(),iT(e.hideConsoleConnectionStatus()?8:9);}}function Fn(i,t){if(i&1&&(Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,34),Hl(),Qi(4,"p"),PC(5),Hl()(),Qi(6,"div",68),mg(7,"app-remote-control"),Hl()(),oT(8,vn,13,4,"section")(9,yn,10,2,"section")),i&2){let e=nC();DE(5),nm(e.remoteControlStatus()),DE(3),iT(e.remoteControlState()!="inactive"?8:9);}}function $n(i,t){i&1&&(Qi(0,"sh-icon",97),PC(1,"check"),Hl());}function An(i,t){i&1&&(Qi(0,"sh-icon",98),PC(1,"prohibit"),Hl());}function Ln(i,t){if(i&1){let e=gT();Qi(0,"button",102),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.updatePassphrase())}),XT(1,48),Hl();}if(i&2){let e=nC(2);Qg("loading",e.isUpdating());}}function wn(i,t){if(i&1){let e=gT();Qi(0,"button",103),Fg("click",function(){Sd(e);let s=nC(2);return xd(s.updatePassphrase())}),XT(1,49),Hl();}if(i&2){let e=nC(2);Qg("loading",e.isUpdating()),gg("disabled",true);}}function Dn(i,t){if(i&1){let e=gT();Qi(0,"sh-form-field")(1,"label",93),XT(2,45),Hl(),Qi(3,"input",94),sm("ngModelChange",function(s){Sd(e);let l=nC();return HC(l.passphrase,s)||(l.passphrase=s),xd(s)}),Hl(),DD(),Hl(),Qi(4,"sh-form-field")(5,"label",95),XT(6,46),Hl(),Qi(7,"input",96),sm("ngModelChange",function(s){Sd(e);let l=nC();return HC(l.repeatPassphrase,s)||(l.repeatPassphrase=s),xd(s)}),Hl(),DD(),oT(8,$n,2,0,"sh-icon",97)(9,An,2,0,"sh-icon",98),Hl(),Qi(10,"div",73)(11,"button",99),Fg("click",function(){Sd(e);let s=nC();return xd(s.cancelPasswordChange())}),XT(12,47),Hl(),oT(13,Ln,2,2,"button",100)(14,wn,2,3,"button",101),Hl();}if(i&2){let e=nC();DE(3),im("ngModel",e.passphrase),TD(),DE(4),gg("disabled",e.passphrase().length===0),im("ngModel",e.repeatPassphrase),TD(),DE(),iT(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?8:9),DE(3),Qg("loading",e.isUpdating()),DE(2),iT(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?13:14);}}function xn(i,t){i&1&&(Qi(0,"sh-icon",104),PC(1,"check"),Hl());}function kn(i,t){if(i&1){let e=gT();Qi(0,"div",73)(1,"button",99),Fg("click",function(){Sd(e);let s=nC();return xd(s.openPassphraseForm())}),XT(2,50),Hl(),oT(3,xn,2,0,"sh-icon",104),Hl();}if(i&2){let e=nC();DE(3),iT(e.passwordUpdated()?3:-1);}}function Xn(i,t){i&1&&(Og(0,11,1),mg(1,"span"),Pg());}function Jn(i,t){i&1&&(Og(0,11,2),mg(1,"span"),Pg());}function zn(i,t){if(i&1){let e=gT();Qi(0,"sh-form-field")(1,"label",105),XT(2,51),Hl(),Qi(3,"textarea",106),sm("ngModelChange",function(s){Sd(e);let l=nC();return HC(l.allowedHostnames,s)||(l.allowedHostnames=s),xd(s)}),Hl(),DD(),Hl(),Qi(4,"sh-alert",107),XT(5,52),Hl(),Qi(6,"button",102),Fg("click",function(){Sd(e);let s=nC();return xd(s.updateAllowedHostnames())}),XT(7,53),Hl();}if(i&2){let e=nC();DE(3),im("ngModel",e.allowedHostnames),TD(),DE(3),Qg("loading",e.updatingAllowedHosts());}}function Vn(i,t){if(i&1){let e=gT();Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,54),Hl(),Qi(4,"p"),XT(5,55),Hl()(),Qi(6,"div",68)(7,"sh-select",108)(8,"input",75),Fg("ngModelChange",function(s){Sd(e);let l=nC();return xd(l.updatePowerMode(s))}),Hl(),DD(),Hl()()();}if(i&2){let e=nC();DE(7),gg("options",e.powerModeOptions())("isClearable",false),DE(),gg("ngModel",e.powerModeCtrl())("ngModelOptions",QC(4,Se)),TD();}}function Un(i,t){if(i&1&&(Qi(0,"p"),XT(1,56),Hl()),i&2){let e=nC();DE(),Lg(e.sysinfo()?.ServerVersionName),eC(1);}}function Bn(i,t){i&1&&mg(0,"sh-progress-bar",80);}function Hn(i,t){if(i&1&&PC(0),i&2){let e=t.$implicit;Gl(" ",e.label," ");}}function Wn(i,t){if(i&1&&PC(0),i&2){let e=t.$implicit;Gl(" ",e.label," ");}}function jn(i,t){if(i&1){let e=gT();Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,57),Hl(),Qi(4,"p")(5,"span"),XT(6,58),Hl(),Qi(7,"a",109),XT(8,59),Hl(),mg(9,"br")(10,"br"),Qi(11,"span"),XT(12,60),Hl()()(),Qi(13,"div",68)(14,"sh-select",110)(15,"input",75),Fg("ngModelChange",function(s){Sd(e);let l=nC();return xd(l.updateUsageStatistics(s))}),Hl(),DD(),ig(16,Wn,1,1,"ng-template"),Hl()()();}if(i&2){let e=nC();DE(14),gg("options",e.usageStatisticsOptions())("isLoading",e.updatingUsageStatistics()),DE(),gg("ngModel",e.usageStatistics())("ngModelOptions",QC(4,Se)),TD();}}function qn(i,t){i&1&&(Qi(0,"label"),XT(1,63),Hl());}function Kn(i,t){i&1&&(Qi(0,"label"),XT(1,64),Hl());}function Qn(i,t){if(i&1){let e=gT();Qi(0,"section")(1,"div",67)(2,"h3"),XT(3,61),Hl(),Qi(4,"p"),XT(5,62),Hl()(),Qi(6,"div",91)(7,"p"),PC(8,"Backup process isolation"),Hl(),Qi(9,"sh-toggle",79),Fg("checkedChange",function(s){Sd(e);let l=nC();return xd(l.saveControllerIpcState(s))}),oT(10,qn,2,0,"label")(11,Kn,2,0,"label"),Hl()()();}if(i&2){let e=nC();DE(9),gg("checked",e.isControllerIpcEnabled()),DE(),iT(e.isControllerIpcEnabled()?10:11);}}function Yn(i,t,e){let[n]=bs(i,e?.equal),s=n,l=n[H],E;return s.set=S=>{clearTimeout(E),E=setTimeout(()=>{ft(l,S);},t);},s.update=S=>{clearTimeout(E),E=setTimeout(()=>{po(l,S);},t);},s}var Zn=[{value:"none",label:$localize`None`},{value:"s",label:$localize`Seconds`},{value:"m",label:$localize`Minutes`},{value:"h",label:$localize`Hours`}],on=[{value:"none",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:"disabled",label:$localize`None / disabled`}],fe=class i{#n=T(be);#i=T(m);#e=T(m$1);#t=T(O);#o=T(C);#r=T(g);#s=T(h);#a=this.#s.getItem("locale")??"en-US";sysinfo=this.#e.systemInfo;isDarkMode=this.#i.isDarkMode;editAs=Ue("list");previousLang=this.#a;langCtrl=Ue(this.#a);powerModeCtrl=Ue("");usageStatistics=Ue("");updatingUsageStatistics=Ue(false);remoteControlStatus=this.#o.statusMessage;remoteControlState=this.#o.state;updatingChannel=Ue(false);updateChannel=Ue("");isUsingRelay=this.#r.relayIsEnabled;defaultClient=Ue(this.#d());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=Ga(()=>{let t=this.#e.systemInfo()?.DefaultUsageReportLevel??"",e=on;e[0].label=$localize`System default (${t})`,this.usageStatisticsOptions.set(e);});remoteControlTooltip=Ue($localize`Disabling console control will disable remote access to this machine from the console, but will keep the
|
|
3
|
+
registration intact and allow pushing settings from the console.`);connectionStatusIndicatorTooltip=Ue($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(Bu(()=>this.updatingChannel.set(false))).subscribe();}allowRemoteAccess=Ue(false);allowedHostnames=Ue("");loadedAllowedHostnames=Ue("");updatingRemoteAccess=Ue(false);updatingAllowedHosts=Ue(false);updatingConsoleControl=Ue(false);consoleControlDisabled=Ue(false);hideConsoleConnectionStatus=this.#t.isConsoleConnectionStatusHidden;isControllerIpcEnabled=this.#t.isControllerIpcEnabled;updateRemoteAccess(t){this.allowRemoteAccess.set(t),this.#t.setRemoteAccessInterface(t?"any":"loopback").pipe(Bu(()=>this.updatingRemoteAccess.set(false))).subscribe();}updateAllowedHostnames(){let t=this.allowedHostnames();this.updatingAllowedHosts.set(true),this.#t.setRemoteAccessAllowedHostnames(t).pipe(Bu(()=>this.updatingAllowedHosts.set(false))).subscribe();}toggleConsoleControl(t){this.consoleControlDisabled.set(!t),this.#t.setDisableConsoleControl(!t).pipe(Bu(()=>this.updatingConsoleControl.set(false))).subscribe();}updatingDisableTrayIconLogin=Ue(false);disableTrayIconLogin=Ue(false);saveDisableTrayIconLogin(t){let e=t;this.updatingDisableTrayIconLogin.set(true),this.#t.setDisableTrayIconLogin(e).pipe(Bu(()=>this.updatingDisableTrayIconLogin.set(false))).subscribe();}updatingHideConsoleConnectionStatus=Ue(false);saveHideConsoleConnectionStatus(t){this.updatingHideConsoleConnectionStatus.set(true),this.#t.setHideConsoleConnectionStatus(!t).pipe(Bu(()=>this.updatingHideConsoleConnectionStatus.set(false))).subscribe();}updatingControllerIpcState=Ue(false);saveControllerIpcState(t){this.updatingControllerIpcState.set(true),this.#t.setControllerIpcState(!!t).pipe(Bu(()=>this.updatingControllerIpcState.set(false))).subscribe();}showPassphraseForm=Ue(false);isUpdating=Ue(false);passphrase=Ue("");repeatPassphrase=Ue("");passwordUpdated=Ue(false);updatePassphrase(){this.passphrase()===this.repeatPassphrase()&&(this.isUpdating.set(true),this.#t.setRemoteAccessPassword(this.passphrase()).pipe(Bu(()=>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=Ue(It);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=Ue(on);timeTypeOptions=Ue(Zn);timeType=Ue("none");timeValue=Yn(0,300);timeRange=Nt(()=>this.timeType()==="h"?[1,24]:[1,60]);updateLocale(t){!t||t===""||t===this.previousLang||(this.#s.setItem("locale",t),window.location.reload());}updateTimeValue(t){this.timeValue.set(t),this.#_();}updateTimeType(t){this.timeType()==="none"&&this.timeValue.set(1),this.timeType.set(t),this.#_();}#l;#_(){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||t===""||t===e||(this.usageStatistics.set(t),this.updatingUsageStatistics.set(true),this.#t.setUsageReporterLevel(t).subscribe());}updatePowerMode(t){this.powerModeCtrl()!==t&&(t==="default"&&(t=""),this.#t.setPowerModeProvider(t).subscribe());}serverSettingsEffect=Ga(()=>{let t=this.#t.serverSettings();if(t===void 0)return;let e=t["startup-delay"],n=e.slice(-1),s=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(t["usage-reporter-level"]===""?"none":t["usage-reporter-level"]),this.timeType.set(e==""?"none":l.includes(n)?n:"none"),this.timeValue.set(e==""?0:parseInt(s));let E=t["power-mode-provider"]===""||t["power-mode-provider"]==null?"default":t["power-mode-provider"];this.powerModeCtrl.set(E);});setDarkMode(){this.#i.setDarkMode();}setLightMode(){this.#i.setLightMode();}changeDefaultClientTo(t){this.defaultClient()!==t&&(t==="ngax"?this.#n.open(h$1,{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.#c(t));}}):this.#c(t));}openLegacyUI(){this.#n.open(h$1,{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");}});}#c(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);}#d(){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=dw({type:i,selectors:[["app-settings"]],decls:130,vars:38,consts:()=>{let t;t=$localize`Settings`;let e;e=$localize`Configure your backup settings.`;let n;n=$localize`Color theme`;let s;s=$localize`Customize your application theme`;let l;l=$localize`Passwords`;let E;E=$localize`Change server passphrase`;let S;S=$localize`Language`;let m;m=$localize`Select a language for the platform`;let f;f=$localize`Use legacy interface`;let W;W=$localize`Use the old user interface, not recommended unless you have a specific reason.`;let ue;ue=$localize`${"\uFFFD#47\uFFFD"}:START_TAG_SH_ICON:arrow-square-right${"\uFFFD/#47\uFFFD"}:CLOSE_TAG_SH_ICON: Open legacy UI `;let J;J=$localize`${"\uFFFD#50\uFFFD"}:START_TAG_SH_ICON:swap${"\uFFFD/#50\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD*51: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/*51:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*52: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/*52:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,J=tC(J);let z;z=$localize`Allow remote access (requires restart)`;let Q;Q=$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 Y;Y=$localize`Allow remote access`;let Ie;Ie=$localize`Prevent tray icon automatic log-in`;let Me;Me=$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 Pe;Pe=$localize`Prevent tray icon automatic log-in`;let Oe;Oe=$localize`Update channel`;let be;be=$localize` Default (${"\uFFFD0\uFFFD"}:INTERPOLATION:) `;let ve;ve=$localize`Same as the base install version: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Re;Re=$localize`Stable`;let Ge;Ge=$localize`Official stable release.`;let ye;ye=$localize`Beta`;let Fe;Fe=$localize` Try out the new features that we are working on. Test a backup and restore before using this in production environments. `;let $e;$e=$localize`Experimental`;let Ae;Ae=$localize`Early previews of new features. Not for use with important data.`;let Le;Le=$localize`Canary`;let we;we=$localize`Builds for developers and testers only. Not for use with important data.`;let De;De=$localize`Pause after startup or hibernation`;let xe;xe=$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 ke;ke=$localize`Advanced options`;let Xe;Xe=$localize`Console connection status`;let Je;Je=$localize`Reporting configured by server`;let ze;ze=$localize`Connect to console`;let Ve;Ve=$localize`Configure console control`;let Ue;Ue=$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 Be;Be=$localize` Remote control disabled ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let He;He=$localize` Remote control enabled ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let We;We=$localize` Console connection status is hidden ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let je;je=$localize` Console connection status is visible ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let qe;qe=$localize`Toggle console connection status`;let Ke;Ke=$localize`Toggle the visibility of the console connection status indicator.`;let Qe;Qe=$localize`Console connection status is hidden`;let Ye;Ye=$localize`Console connection status is visible`;let Ze;Ze=$localize`Enter new password`;let et;et=$localize`Repeat password`;let ge;ge=$localize`Password have to be filled and have to match`;let tt;tt=$localize`Passphrase`;let nt;nt=$localize`Repeat passphrase`;let it;it=$localize`Cancel`;let ot;ot=$localize` Update passphrase `;let st;st=$localize` Update passphrase `;let at;at=$localize`Change password`;let rt;rt=$localize`Allowed hostnames`;let lt;lt=$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 _t;_t=$localize` Update allowed hostnames `;let ct;ct=$localize`Power mode provider`;let dt;dt=$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 Tt;Tt=$localize`Installed version: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let St;St=$localize`Usage statistics`;let ut;ut=$localize` Usage reports help us improve the user experience and evaluate impact of new features. We use them to generate `;let gt;gt=$localize`public usage statistics.`;let pt;pt=$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 Ct;Ct=$localize`Experimental options`;let mt;mt=$localize`Toggle experimental options.`;let Et;Et=$localize`Operations run in an isolated process`;let Nt;return Nt=$localize`Operations run inside the server process`,[t,e,n,s,l,E,S,m,f,W,ue,J,z,Q,Y,Ie,Me,Pe,Oe,be,ve,Re,Ge,ye,Fe,$e,Ae,Le,we,De,xe,ke,Xe,Je,ze,Ve,Ue,Be,He,We,je,qe,Ke,Qe,Ye,tt,nt,it,ot,st,at,rt,lt,_t,ct,dt,Tt,St,ut,gt,pt,Ct,mt,Et,Nt,[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","buttons"],["shButton","",1,"primary",3,"click"],[1,"right","remote-access-form"],[1,"primary","raised",3,"checkedChange","checked"],[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"],[1,"right","multiple"],["suffix","",3,"shTooltip"],["for","password"],["type","password","name","password","autocomplete","new-password","placeholder",Ze,"tabindex","1",3,"ngModelChange","ngModel"],["for","repeatPassword"],["type","password","name","repeatPassword","autocomplete","new-password","placeholder",et,"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&&(mg(0,"app-status-bar"),Qi(1,"div",65)(2,"header")(3,"div",66)(4,"h2"),XT(5,0),Hl(),Qi(6,"p"),XT(7,1),Hl()()(),oT(8,In,8,2,"section")(9,Fn,10,2),Qi(10,"section")(11,"div",67)(12,"h3"),XT(13,2),Hl(),Qi(14,"p"),XT(15,3),Hl()(),Qi(16,"div",68)(17,"div",69)(18,"img",70),Fg("click",function(){return n.setLightMode()}),Hl(),Qi(19,"img",71),Fg("click",function(){return n.setDarkMode()}),Hl()()()(),Qi(20,"section")(21,"div",67)(22,"h3"),XT(23,4),Hl(),Qi(24,"p"),XT(25,5),Hl()(),Qi(26,"div",72),oT(27,Dn,15,7)(28,kn,4,1,"div",73),Hl()(),Qi(29,"section")(30,"div",67)(31,"h3"),XT(32,6),Hl(),Qi(33,"p"),XT(34,7),Hl()(),Qi(35,"div",68)(36,"sh-select",74)(37,"input",75),Fg("ngModelChange",function(l){return n.updateLocale(l)}),Hl(),DD(),Hl()()(),Qi(38,"section")(39,"div",67)(40,"h3"),XT(41,8),Hl(),Qi(42,"p"),XT(43,9),Hl()(),Qi(44,"div",76)(45,"button",77),Fg("click",function(){return n.openLegacyUI()}),Og(46,10),mg(47,"sh-icon"),Pg(),Hl(),Qi(48,"button",77),Fg("click",function(){return n.changeDefaultClientTo(n.defaultClient()==="ngclient"?"ngax":"ngclient")}),Og(49,11),mg(50,"sh-icon"),oT(51,Xn,2,0,"span")(52,Jn,2,0,"span"),Pg(),Hl()()(),Qi(53,"section")(54,"div",67)(55,"h3"),XT(56,12),Hl(),Qi(57,"p"),XT(58,13),Hl()(),Qi(59,"div",78)(60,"sh-toggle",79),Fg("checkedChange",function(l){return n.updateRemoteAccess(l)}),Qi(61,"label"),XT(62,14),Hl()(),oT(63,zn,8,3),Hl()(),Qi(64,"section")(65,"div",67)(66,"h3"),XT(67,15),Hl(),Qi(68,"p"),XT(69,16),Hl()(),Qi(70,"div",68)(71,"sh-toggle",79),Fg("checkedChange",function(l){return n.saveDisableTrayIconLogin(l)}),Qi(72,"label"),XT(73,17),Hl()()()(),oT(74,Vn,9,5,"section"),Qi(75,"section")(76,"div",67)(77,"h3"),XT(78,18),Hl(),oT(79,Un,2,1,"p"),oT(80,Bn,1,0,"sh-progress-bar",80),Hl(),Qi(81,"div",81)(82,"div",82),Fg("click",function(){return n.setNewChannel("")}),Qi(83,"sh-radio",83),XT(84,19),Hl(),Qi(85,"p"),XT(86,20),Hl()(),Qi(87,"div",82),Fg("click",function(){return n.setNewChannel("stable")}),Qi(88,"sh-radio",83),XT(89,21),Hl(),Qi(90,"p"),XT(91,22),Hl()(),Qi(92,"div",82),Fg("click",function(){return n.setNewChannel("beta")}),Qi(93,"sh-radio",83),XT(94,23),Hl(),Qi(95,"p"),XT(96,24),Hl()(),Qi(97,"div",82),Fg("click",function(){return n.setNewChannel("experimental")}),Qi(98,"sh-radio",83),XT(99,25),Hl(),Qi(100,"p"),XT(101,26),Hl()(),Qi(102,"div",82),Fg("click",function(){return n.setNewChannel("canary")}),Qi(103,"sh-radio",83),XT(104,27),Hl(),Qi(105,"p"),XT(106,28),Hl()()()(),Qi(107,"section")(108,"div",67)(109,"h3"),XT(110,29),Hl(),Qi(111,"p"),XT(112,30),Hl()(),Qi(113,"div",68)(114,"div",84)(115,"sh-range-slider",85)(116,"input",86),sm("ngModelChange",function(l){return HC(n.timeValue,l)||(n.timeValue=l),l}),Fg("ngModelChange",function(l){return n.updateTimeValue(l)}),Hl(),DD(),Hl(),Qi(117,"sh-select",87)(118,"input",88),Fg("ngModelChange",function(l){return n.updateTimeType(l)}),Hl(),DD(),ig(119,Hn,1,1,"ng-template"),Hl()()()(),oT(120,jn,17,5,"section"),oT(121,Qn,12,2,"section"),Hl(),mg(122,"sh-divider"),Qi(123,"div",65)(124,"section")(125,"div",89)(126,"h3"),XT(127,31),Hl(),mg(128,"app-advanced-options-settings"),Hl()()(),mg(129,"sh-divider")),e&2&&(DE(8),iT(n.isUsingRelay()?8:9),DE(10),Qg("active",!n.isDarkMode()),DE(),Qg("active",n.isDarkMode()),DE(8),iT(n.showPassphraseForm()?27:28),DE(9),gg("options",n.languageOptions())("isClearable",false)("inlineSearch",true),DE(),gg("ngModel",n.langCtrl())("ngModelOptions",QC(36,Se)),TD(),DE(14),iT(n.defaultClient()==="ngax"?51:52),DE(9),gg("checked",n.allowRemoteAccess()),DE(3),iT(n.allowRemoteAccess()?63:-1),DE(8),gg("checked",n.disableTrayIconLogin()),DE(3),iT(n.powerModeOptions().length>0?74:-1),DE(5),iT(n.sysinfo()?.ServerVersion?79:-1),DE(),iT(n.updatingChannel()?80:-1),DE(3),gg("checked",n.updateChannel()===""),DE(),Lg(n.sysinfo()?.DefaultUpdateChannel),eC(84),DE(2),Lg(n.sysinfo()?.ServerVersionType),eC(86),DE(2),gg("checked",n.updateChannel()==="stable"),DE(5),gg("checked",n.updateChannel()==="beta"),DE(5),gg("checked",n.updateChannel()==="experimental"),DE(5),gg("checked",n.updateChannel()==="canary"),DE(12),gg("unit",n.timeType()==="none"?"s":n.timeType()),DE(),gg("min",n.timeRange()[0])("max",n.timeRange()[1])("disabled",n.timeType()==="none"),im("ngModel",n.timeValue),gg("ngModelOptions",QC(37,Se)),TD(),DE(),gg("options",n.timeTypeOptions())("isClearable",false),DE(),gg("ngModel",n.timeType()),TD(),DE(2),iT(n.usageStatisticsDisabled()?-1:120),DE(),iT(n.hasIpcController()?121:-1));},dependencies:[Bn$1,Ze,on$1,Rn$1,Jt,Gn$1,ee,Te,K,v,O$1,tn,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{Yn as debounceSignal,fe as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {O}from'./chunk-
|
|
1
|
+
import {O}from'./chunk-SycscfJp.js';import {br as x,T,a6 as be,ab as C$1,m,a as T$1,bg as Q,U as Ue,N as Nt,G as Ga,at as h,aZ as ee}from'./main-PXGZLKMN.js';var S=new x("WindowToken",{providedIn:"root",factory:()=>typeof window<"u"?window:{}});var C=class l{#c=T(S);#g=T(be);#t=T(C$1);#o=T(m);#l=T(T$1);#n=T(Q);#u=T(O);constructor(){this.#l.subscribe("remotecontrol");}repeatRegisterTimer=null;#s=null;#r=0;#h=5;#m=2e3;pendingRefresh=false;state=Ue("unknown");claimUrl=Ue(null);registerUrl=Ue("");customRegisterUrl=Ue("");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=Ga(()=>{let e=this.#o.systemInfo();e&&this.registerUrl.set(e.RemoteControlRegistrationUrl??"");});remoteEffect=Ga(()=>{let e=this.#l.remoteControlState();e&&this.#e(e);});pendingRefreshEffect=Ga(()=>{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});#f(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.#r=0,this.#f(e),this.#a())return;let i=this.state();this.repeatRegisterTimer!==null&&(clearTimeout(this.repeatRegisterTimer),this.repeatRegisterTimer=null),i==="registering"&&(this.repeatRegisterTimer=setTimeout(()=>{this.#t.postApiV1RemotecontrolRegisterWait().subscribe({next:t=>this.#e(t),error:t=>this.#i(t)});},5e3)),(i==="connecting"||i==="registered")&&(this.repeatRegisterTimer=setTimeout(()=>{this.#t.getApiV1RemotecontrolStatus().subscribe({next:t=>this.#e(t),error:t=>this.#i(t)});},5e3)),e.IsRegistering&&e.CanEnable&&this.#t.deleteApiV1RemotecontrolRegister().subscribe({next:t=>this.#e(t)});}#i(e){if(this.#s!==null&&(clearTimeout(this.#s),this.#s=null),this.#r>=this.#h){this.state.set("registeringfaulted"),this.#r=0;return}let i=this.#m*Math.pow(2,this.#r);this.#r++,this.#s=setTimeout(()=>{this.#s=null,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}this.#t.getApiV1RemotecontrolStatus().subscribe({next:e=>this.#e(e),error:e=>this.#i(e)});}}beginRemoteRegistration(e=false){this.state.set("registering"),this.#t.postApiV1RemotecontrolRegister({requestBody:{RegistrationUrl:e?this.customRegisterUrl():this.registerUrl()}}).subscribe({next:i=>this.#e(i),error:i=>this.#i(i)});}cancelRemoteRegistration(){this.#t.deleteApiV1RemotecontrolRegister().subscribe({next:e=>this.#e(e),error:e=>this.#i(e)});}enableRemoteControl(){this.#t.postApiV1RemotecontrolEnable().subscribe({next:e=>this.#e(e),error:e=>this.#i(e)});}disableRemoteControl(){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&&e.#t.deleteApiV1RemotecontrolRegistration().subscribe({next:t=>e.#e(t),error:t=>e.#i(t)});}});}openConsole(e="/app/machines",i){let t=this.#u.serverSettings(),y=this.#o.systemInfo(),r="https://app.duplicati.com",c=y?.RemoteControlDashboardUrl??"";if(c.length>0&&(r=c),t&&t["remote-control-dashboard-url"]&&(r=t["remote-control-dashboard-url"]),r=new URL(r).origin+e,i){let v=new URLSearchParams(i);r+=`?${v.toString()}`;}this.#c.open(r,"_blank");}static \u0275fac=function(i){return new(i||l)};static \u0275prov=ee({token:l,factory:l.\u0275fac,providedIn:"root"})};
|
|
2
2
|
export{C,S};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import {C}from'./chunk-
|
|
1
|
+
import {C}from'./chunk-MvQwR7nW.js';import {O}from'./chunk-SycscfJp.js';import {T as T$1,e as ee,U as Ue,G as Ga,d as dw,v,a0 as de,f as N,Q as Qi,F as Fg,X as XT,H as Hl,a1 as cT,s as sm,q as PC,j as mg,D as DE,a2 as lT,w as im,z as gg,I as Qg,a3 as QC,a4 as aT,l as HC,E as nm}from'./main-PXGZLKMN.js';import {U}from'./chunk-CMmgPgiU.js';import {a as at}from'./chunk-B-fklW6A.js';import'./chunk-D28lTX0k.js';var D=()=>({maxWidth:"520px",width:"100%"});function z(r,i){if(r&1&&(Qi(0,"div",11)(1,"sh-icon",26),PC(2,"check-circle"),Hl(),Qi(3,"span"),PC(4),Hl()()),r&2){let o=i.$implicit;DE(4),nm(o);}}function J(r,i){if(r&1&&(Qi(0,"div",11)(1,"sh-icon",26),PC(2,"check-circle"),Hl(),Qi(3,"span"),PC(4),Hl()()),r&2){let o=i.$implicit;DE(4),nm(o);}}var T=class r{#n=T$1(O);#e=T$1(ee);#t=T$1(C);hoveringConnect=Ue(false);skipDialogOpen=Ue(false);hasConnectionLink=Ue(false);primaryBenefits=[$localize`Zero-configuration cloud storage`,$localize`Centralized backup reporting and monitoring`,$localize`Remote management from the dashboard`,$localize`Notifcations if backups stop running`];secondaryBenefits=[$localize`Get notified if your backups stop working`,$localize`Access AI powered troubleshooting`,$localize`View all backups from one place`];#i=Ga(()=>{let i=this.#t.state();i=="unknown"||i=="inactive"||this.setWelcomeShown();});setWelcomeShown(){this.#n.setShownWelcomePage().subscribe(()=>{this.#e.navigate([""]);});}openSkipDialog(){this.skipDialogOpen.set(true);}connect(){let i=this.hasConnectionLink()?"/welcome/connect/link":"/welcome/connect/logon";this.#e.navigate([i]);}static \u0275fac=function(o){return new(o||r)};static \u0275cmp=dw({type:r,selectors:[["app-select"]],decls:36,vars:7,consts:()=>{let i;i=$localize`Proceed without connecting to console`;let o;o=$localize`Connect to console`;let n;n=$localize`Consolidate all your backup reports in one place.`;let l;l=$localize`I have a connection link`;let c;c=$localize`Are you sure?`;let O;O=$localize`Cancel`;let b;return b=$localize`Proceed without connecting`,[i,o,n,l,c,O,b,[1,"left"],[1,"actionables"],[1,"without-connecting",3,"click"],[1,"benefits"],[1,"benefit"],["shButton","",1,"connect","outlined","primary",3,"mouseenter","mouseleave","click"],[1,"action"],[1,"connection-link-label"],[1,"primary","raised","connection-link-check",3,"checkedChange","checked"],[3,"shTooltip"],[1,"right"],["src","assets/images/console.avif","alt",""],[3,"isOpenChange","isOpen","options"],["header",""],["content",""],[1,"dialog-benefits-header"],[1,"dialog-benefits"],["footer",""],["type","button","shButton","",1,"outlined",3,"click"],[1,"primary"]]},template:function(o,n){o&1&&(Qi(0,"section",7)(1,"div",8)(2,"div",9),Fg("click",function(){return n.openSkipDialog()}),XT(3,0),Hl(),Qi(4,"div",10),cT(5,z,5,1,"div",11,aT),Hl(),Qi(7,"button",12),Fg("mouseenter",function(){return n.hoveringConnect.set(true)})("mouseleave",function(){return n.hoveringConnect.set(false)})("click",function(){return n.connect()}),Qi(8,"div",13)(9,"h2"),XT(10,1),Hl(),Qi(11,"p"),XT(12,2),Hl()()(),Qi(13,"div",14)(14,"sh-checkbox",15),sm("checkedChange",function(c){return HC(n.hasConnectionLink,c)||(n.hasConnectionLink=c),c}),Hl(),Qi(15,"span"),XT(16,3),Hl(),Qi(17,"sh-icon",16),PC(18," information "),Hl()()()(),Qi(19,"section",17),mg(20,"img",18),Hl(),Qi(21,"sh-dialog",19),sm("isOpenChange",function(c){return HC(n.skipDialogOpen,c)||(n.skipDialogOpen=c),c}),Qi(22,"header",20)(23,"h3"),XT(24,4),Hl()(),Qi(25,"div",21)(26,"h4",22),PC(27," You can use Duplicati without a Console connection, but connecting to the Console will expand the capabilities of Duplicati. "),Hl(),Qi(28,"div",23),cT(29,J,5,1,"div",11,aT),Hl()(),Qi(31,"footer",24)(32,"button",25),Fg("click",function(){return n.skipDialogOpen.set(false)}),XT(33,5),Hl(),Qi(34,"button",25),Fg("click",function(){return n.setWelcomeShown()}),XT(35,6),Hl()()()),o&2&&(DE(5),lT(n.primaryBenefits),DE(9),im("checked",n.hasConnectionLink),DE(3),gg("shTooltip","Connection links are used for Enterprise and large-scale installations"),DE(2),Qg("hovering",n.hoveringConnect()),DE(2),im("isOpen",n.skipDialogOpen),gg("options",QC(6,D)),DE(8),lT(n.secondaryBenefits));},dependencies:[v,U,de,N,at],styles:["[_nghost-%COMP%]{display:grid;grid-template-columns:1fr 2fr;grid-template-rows:1fr;height:100vh;overflow:hidden;padding:2rem}@media only screen and (max-width:768px){[_nghost-%COMP%]{display:flex;flex-direction:column-reverse;height:auto;padding:4rem 1rem;gap:2rem}}.left[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:flex-end;justify-content:center}@media only screen and (max-width:768px){.left[_ngcontent-%COMP%]{align-items:flex-start}}.left[_ngcontent-%COMP%] .actionables[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;flex-direction:column;gap:1rem}@media only screen and (max-width:768px){.left[_ngcontent-%COMP%] .actionables[_ngcontent-%COMP%]{width:100%}}.left[_ngcontent-%COMP%] .actionables[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{width:100%}.left[_ngcontent-%COMP%] .actionables[_ngcontent-%COMP%] sh-divider[_ngcontent-%COMP%]{width:100%}.left[_ngcontent-%COMP%] .actionables[_ngcontent-%COMP%] .benefits[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.75rem;padding:1.5rem 0}.left[_ngcontent-%COMP%] .actionables[_ngcontent-%COMP%] .benefits[_ngcontent-%COMP%] .benefit[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.75rem;color:var(--base-11)}.left[_ngcontent-%COMP%] .actionables[_ngcontent-%COMP%] .benefits[_ngcontent-%COMP%] .benefit[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{font-size:1.25rem;flex-shrink:0}.left[_ngcontent-%COMP%] .actionables[_ngcontent-%COMP%] .benefits[_ngcontent-%COMP%] .benefit[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:.875rem}.right[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;padding:2rem 2rem 2rem 0}.right.hovering[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{border-color:var(--primary-8)}.right[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{max-width:90%;max-height:90%;object-fit:contain;border:1px solid var(--base-3);border-radius:var(--shape-2);box-shadow:var(--box-shadow-20);transition:border-color .2s ease-in-out}.connect[_ngcontent-%COMP%]{height:auto;padding:2rem}.without-connecting[_ngcontent-%COMP%]{text-decoration:underline;cursor:pointer;margin:0}.without-connecting[_ngcontent-%COMP%]:hover{color:var(--primary-8)}.dialog-benefits-header[_ngcontent-%COMP%]{margin-bottom:1rem}.dialog-benefits[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;margin-bottom:2rem}.dialog-benefits[_ngcontent-%COMP%] .benefit[_ngcontent-%COMP%]{display:flex;flex-direction:row;align-items:center;gap:.5rem;color:var(--base-11)}.dialog-benefits[_ngcontent-%COMP%] .benefit[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{font-size:1.25rem;flex-shrink:0}.dialog-benefits[_ngcontent-%COMP%] .benefit[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:.875rem}.connection-link-label[_ngcontent-%COMP%]{display:flex;flex-direction:row;gap:.5rem}"]})};export{T as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var o=[{path:"",loadComponent:()=>import('./chunk-CByrJpDb.js'),children:[{path:"",redirectTo:"stored",pathMatch:"full"},{path:"stored",loadComponent:()=>import('./chunk-DC8QqmzV.js')},{path:"live",loadComponent:()=>import('./chunk-BYHopERA.js')}]}],t=o;export{t as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import {d}from'./chunk-DofVJ9gn.js';import'./chunk-BNf0YAwH.js';import'./chunk-BAbAUjHY.js';import'./chunk-BPpheyQK.js';import {J}from'./chunk-birClroL.js';import'./chunk-bx0aDvCZ.js';import {O as Oe$1,F as Fe$1}from'./chunk-CtLFpDTP.js';import'./chunk-CxPG-KgI.js';import'./chunk-B-ryE8KW.js';import'./chunk-CDRHCSvU.js';import'./chunk-CMs999gl.js';import {D}from'./chunk-CdZVal1F.js';import {T,ab as C,e as ee,ah as fe,a5 as g,U as Ue,N as Nt,ai as m,aj as l,C as Bu,d as dw,v,f as N,aH as m$1,be as m$2,Q as Qi,X as XT,H as Hl,o as oT,F as Fg,j as mg,O as Og,P as Pg,D as DE,i as iT,z as gg,k as gT,a1 as cT,s as sm,S as Sd,n as nC,l as HC,x as xd,a2 as lT,w as im,p as DD,q as PC,y as TD,I as Qg,aa as Gl,ar as Wp,aM as tb,au as Lg,aR as rb,av as eC,aN as ob}from'./main-TZVLLK67.js';import {f}from'./chunk-DWwNINBJ.js';import {d as d$1}from'./chunk-BjNuU0J_.js';import {U}from'./chunk-CU-RYihf.js';import {F as Fe$2}from'./chunk-Do6_xsGi.js';import {B as Bn,Z as Ze,R as Rn,J as Jt}from'./chunk-BOII3Fdm.js';import {a as at}from'./chunk-BffC_BAn.js';import'./chunk-M5tldLvJ.js';var Oe=(n,t)=>t.BackupId;function Fe(n,t){n&1&&(Qi(0,"div",14),mg(1,"sh-progress-bar",20),Qi(2,"p"),XT(3,3),Hl()());}function Pe(n,t){n&1&&(Qi(0,"div",15)(1,"p"),XT(2,4),Hl()());}function Me(n,t){if(n&1){let e=gT();Qi(0,"sh-icon",33),Fg("click",function(){Sd(e);let o=nC(3);return xd(o.searchTerm.set(""))}),PC(1,"x-circle"),Hl();}}function he(n,t){if(n&1){let e=gT();Qi(0,"div",27)(1,"sh-form-field")(2,"input",28),sm("ngModelChange",function(o){Sd(e);let c=nC(2);return HC(c.searchTerm,o)||(c.searchTerm=o),xd(o)}),Hl(),DD(),Qi(3,"sh-icon",29),PC(4,"magnifying-glass"),Hl(),oT(5,Me,2,0,"sh-icon",30),Hl()(),Qi(6,"div",31)(7,"button",32),Fg("click",function(){Sd(e);let o=nC(2);return xd(o.selectAll())}),XT(8,6),Hl(),Qi(9,"button",32),Fg("click",function(){Sd(e);let o=nC(2);return xd(o.selectNone())}),XT(10,7),Hl()();}if(n&2){let e=nC(2);DE(2),im("ngModel",e.searchTerm),TD(),DE(3),iT(e.searchTerm()?5:-1),DE(2),gg("disabled",e.allSelected()),DE(2),gg("disabled",e.noneSelected());}}function Le(n,t){if(n&1&&(Qi(0,"div"),XT(1,8),tb(2,"bytes"),Hl()),n&2){let e=nC().$implicit;DE(2),Lg(rb(2,1,e.Metadata?.SourceFilesSize)),eC(1);}}function ye(n,t){if(n&1&&(Qi(0,"div"),XT(1,9),tb(2,"bytes"),Hl()),n&2){let e=nC().$implicit;DE(2),Lg(rb(2,1,e.Metadata?.TargetFilesSize)),eC(1);}}function Ae(n,t){if(n&1&&(Qi(0,"div"),XT(1,10),tb(2,"relativeTime"),Hl()),n&2){let e=nC().$implicit;DE(2),Lg(ob(2,1,e.Metadata?.LastBackupFinished,false)),eC(1);}}function Re(n,t){if(n&1){let e=gT();Qi(0,"sh-card",34),Fg("click",function(){let o=Sd(e).$implicit,c=nC(2);return xd(c.toggleSelected(o.BackupId))}),Qi(1,"sh-checkbox",35),sm("checkedChange",function(o){let c=Sd(e).$implicit;return HC(c.Selected,o)||(c.Selected=o),xd(o)}),Qi(2,"h3"),PC(3),Qi(4,"sh-chip",36),mg(5,"img",37),PC(6),Hl()()(),Qi(7,"div",38),oT(8,Le,3,3,"div"),oT(9,ye,3,3,"div"),oT(10,Ae,3,4,"div"),Hl()();}if(n&2){let e=t.$implicit,i=nC(2);Qg("unmatched",e.Match===false),DE(),im("checked",e.Selected),DE(2),Gl(" ",e.Name," "),DE(2),gg("src",i.getBackendIcon(e.TargetURLDisplay),Wp),DE(),Gl(" ",i.getBackendType(e.TargetURLDisplay)," "),DE(2),iT(e.Metadata?.SourceFilesSize?8:-1),DE(),iT(e.Metadata?.TargetFilesSize?9:-1),DE(),iT(e.Metadata?.LastBackupFinished?10:-1);}}function Ge(n,t){if(n&1){let e=gT();Qi(0,"sh-toggle",26),sm("checkedChange",function(o){Sd(e);let c=nC(2);return HC(c.saveNow,o)||(c.saveNow=o),xd(o)}),Og(1,11),mg(2,"sh-icon",39),Pg(),Hl();}if(n&2){let e=nC(2);gg("color","primary"),im("checked",e.saveNow),DE(2),gg("shTooltip","Save backups without editing the configuration");}}function De(n,t){n&1&&(Qi(0,"sh-toggle",25),Og(1,12),mg(2,"sh-icon",39),Pg(),Hl()),n&2&&(gg("color","primary")("checked",true)("disabled",true),DE(2),gg("shTooltip","Save now can only be disabled when importing a single backup"));}function ke(n,t){if(n&1){let e=gT();oT(0,he,11,4),Qi(1,"div",21),cT(2,Re,11,9,"sh-card",22,Oe),Hl(),Qi(4,"div",23),oT(5,Ge,3,3,"sh-toggle",24)(6,De,3,4,"sh-toggle",25),Qi(7,"sh-toggle",26),sm("checkedChange",function(o){Sd(e);let c=nC();return HC(c.importMetadata,o)||(c.importMetadata=o),xd(o)}),XT(8,5),Hl()();}if(n&2){let e=nC();iT(e.configs().length>1?0:-1),DE(2),lT(e.configsSorted()),DE(3),iT(e.selectedItems().length<=1?5:6),DE(2),gg("color","primary"),im("checked",e.importMetadata);}}function $e(n,t){n&1&&XT(0,2,1);}function be(n,t){n&1&&XT(0,2,2);}var w=class n{#t=T(d);#n=T(C);#e=T(ee);#i=T(fe);#o=T(g);getBackendType=Oe$1;getBackendIcon=Fe$1;isLoading=Ue(true);isImporting=Ue(false);configs=Ue([]);saveNow=Ue(false);importMetadata=Ue(false);searchTerm=Ue("");allSelected=Nt(()=>this.selectedItems().length===this.configs().length);noneSelected=Nt(()=>this.selectedItems().length===0);configsSorted=Nt(()=>{let t=this.searchTerm().toLowerCase();return this.configs().map(e=>m(l({},e),{Match:t?e.Name?.toLowerCase().includes(t):null})).sort((e,i)=>(e.Name??"").localeCompare(i.Name??"")).sort((e,i)=>e.Match===i.Match?0:e.Match?-1:1)});ngOnInit(){let t=this.#t.temporaryBackupId();if(!t){this.#e.navigate(["/backup/import-destination/destination"]);return}this.#n.postApiV1BackupByIdRestoreTaskConfig({id:t}).pipe(Bu(()=>this.isLoading.set(false))).subscribe({next:e=>{let i=e.sort((o,c)=>(o.Name??"").localeCompare(c.Name??"")).map(o=>m(l({},o),{Selected:e.length===1}));this.configs.set(i);},error:e=>{this.#t.showErrorDialog(e.message||"Failed to fetch configurations");}});}toggleSelected(t){this.configs.update(e=>e.map(i=>i.BackupId===t?m(l({},i),{Selected:!i.Selected}):i));}selectAll(){this.configs.update(t=>t.map(e=>m(l({},e),{Selected:true})));}selectNone(){this.configs.update(t=>t.map(e=>m(l({},e),{Selected:false})));}selectedItems=Nt(()=>this.configs().filter(t=>t.Selected));import(){let t=this.selectedItems();if(t.length===0)return;let e=this.importMetadata(),i=this.saveNow()||t.length!==1;this.isImporting.set(true);let o=c=>{if(c>=t.length){this.isImporting.set(false),this.#i.success($localize`Successfully imported ${t.length} backup(s)`),this.#e.navigate(["/"]);return}let N=t[c];this.#n.postApiV1BackupByIdImportfromtemp({requestBody:{BackupId:N.BackupId,ImportMetadata:e,Direct:i}}).subscribe({next:u=>{if(i)this.configs.update(I=>I.filter(G=>G.BackupId!==N.BackupId)),o(c+1);else {this.isImporting.set(false);let I=this.#o.addDraftBackup(u.data);this.#e.navigate(["/backup-draft",I]);}},error:u=>{this.isImporting.set(false),this.#t.showErrorDialog(`Failed to import ${N.Name}: ${u.message}`);}});};o(0);}back(){this.#e.navigate(["/backup/import-destination/encryption"]);}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=dw({type:n,selectors:[["app-import-destination-select-config"]],decls:14,vars:4,consts:()=>{let t;t=$localize`Select configurations to import`;let e;e=$localize`Back`;let i;i=$localize`${"\uFFFD*12:1\uFFFD"}:START_BLOCK_IF: Importing... ${"\uFFFD/*12:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*13:2\uFFFD"}:START_BLOCK_ELSE: Import selected ${"\uFFFD/*13:2\uFFFD"}:CLOSE_BLOCK_ELSE:`;let o;o=$localize`Fetching backup configurations from destination...`;let c;c=$localize`No backup configurations found at this destination.`;let N;N=$localize`Import metadata`;let u;u=$localize`Search for destination...`;let I;I=$localize`Select all`;let G;G=$localize`Select none`;let K;K=$localize` Source size: ${"\uFFFD0\uFFFD"}:INTERPOLATION: `;let U;U=$localize` Target size: ${"\uFFFD0\uFFFD"}:INTERPOLATION: `;let J;J=$localize` Last backup: ${"\uFFFD0\uFFFD"}:INTERPOLATION: `;let X;X=$localize` Save now ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let z;return z=$localize` Save now ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON: info ${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`,[t,e,i,o,c,N,I,G,K,U,J,X,z,[1,"content-wrapper"],[1,"loading-state"],[1,"empty-state"],[1,"actions"],["shButton","",3,"click","disabled"],[1,"spacer"],["shButton","",1,"primary","raised",3,"click","disabled"],[1,"primary","indeterminate"],[1,"config-list"],[1,"type-a","actionable","full-width",3,"unmatched"],[1,"options"],[3,"color","checked"],[3,"color","checked","disabled"],[3,"checkedChange","color","checked"],[1,"search-area"],["type","text","placeholder",u,3,"ngModelChange","ngModel"],["prefix",""],["suffix","",1,"clear-search"],[1,"list-actions"],["shButton","",1,"small",3,"click","disabled"],["suffix","",1,"clear-search",3,"click"],[1,"type-a","actionable","full-width",3,"click"],[1,"primary","raised",3,"checkedChange","checked"],[1,"small","provider"],["alt","",1,"provider-icon",3,"src"],[1,"metadata"],[1,"small",3,"shTooltip"]]},template:function(e,i){e&1&&(Qi(0,"div",13)(1,"h2"),XT(2,0),Hl(),oT(3,Fe,4,0,"div",14)(4,Pe,3,0,"div",15)(5,ke,9,4),Qi(6,"div",16)(7,"button",17),Fg("click",function(){return i.back()}),XT(8,1),Hl(),mg(9,"div",18),Qi(10,"button",19),Fg("click",function(){return i.import()}),Og(11,2),oT(12,$e,1,0)(13,be,1,0),Pg(),Hl()()()),e&2&&(DE(3),iT(i.isLoading()?3:i.configs().length===0?4:5),DE(4),gg("disabled",i.isImporting()),DE(3),gg("disabled",i.isImporting()||i.selectedItems().length===0||i.isLoading()),DE(2),iT(i.isImporting()?12:13));},dependencies:[v,f,J,U,Bn,Ze,Rn,Jt,d$1,at,N,D,Fe$2,m$1,m$2],styles:["[_nghost-%COMP%]{display:block;padding:2rem;max-width:50rem;margin:0 auto}.loading-state[_ngcontent-%COMP%], .empty-state[_ngcontent-%COMP%]{text-align:center;padding:4rem 2rem}.loading-state[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .empty-state[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin-top:1rem;color:var(--color-on-surface-variant)}h2[_ngcontent-%COMP%]{margin-bottom:2rem}.search-area[_ngcontent-%COMP%]{display:flex;flex-direction:row;gap:1rem;margin-bottom:2rem}.list-actions[_ngcontent-%COMP%]{display:flex;flex-direction:row;gap:.5rem;margin-bottom:.5rem;justify-content:flex-end}.clear-search[_ngcontent-%COMP%]{opacity:.6;cursor:pointer}.config-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem;margin-bottom:2rem}.config-list[_ngcontent-%COMP%] sh-card[_ngcontent-%COMP%]{padding:1rem;cursor:pointer;display:flex;flex-direction:column;gap:.5rem}.config-list[_ngcontent-%COMP%] sh-card.unmatched[_ngcontent-%COMP%]{opacity:.4}.config-list[_ngcontent-%COMP%] sh-card[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;flex-direction:row;align-items:center;gap:.5rem;flex-grow:1}.config-list[_ngcontent-%COMP%] sh-card[_ngcontent-%COMP%] .provider[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.config-list[_ngcontent-%COMP%] sh-card[_ngcontent-%COMP%] .metadata[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;margin-left:1.75rem}.provider-icon[_ngcontent-%COMP%]{width:1.25rem;height:1.25rem}.options[_ngcontent-%COMP%]{margin-bottom:2rem;display:flex;flex-direction:column;gap:1rem}.actions[_ngcontent-%COMP%]{display:flex;align-items:center;margin-top:2rem}.actions[_ngcontent-%COMP%] .spacer[_ngcontent-%COMP%]{flex:1}"]})};export{w as default};
|
|
1
|
+
import {d}from'./chunk-JA7rUsYF.js';import'./chunk-Bf1diO1u.js';import'./chunk-B6vxBiK4.js';import'./chunk-DV2SIgNN.js';import {J}from'./chunk-B2fqvpov.js';import'./chunk-D48AStVy.js';import {O as Oe$1,F as Fe$1}from'./chunk-CQ8rm_d9.js';import'./chunk-CBdr-6_u.js';import'./chunk-BZqhgAZ-.js';import'./chunk-0sb5_LpD.js';import'./chunk-COgNe44h.js';import {D}from'./chunk-BAZ5npJw.js';import {T,ab as C,e as ee,ah as fe,a5 as g,U as Ue,N as Nt,ai as m,aj as l,C as Bu,d as dw,v,f as N,aH as m$1,b1 as m$2,Q as Qi,X as XT,H as Hl,o as oT,F as Fg,j as mg,O as Og,P as Pg,D as DE,i as iT,z as gg,k as gT,a1 as cT,s as sm,S as Sd,n as nC,l as HC,x as xd,a2 as lT,w as im,p as DD,q as PC,y as TD,I as Qg,aa as Gl,ar as Wp,aM as tb,au as Lg,aR as rb,av as eC,aN as ob}from'./main-PXGZLKMN.js';import {f}from'./chunk-DJbAxHpK.js';import {d as d$1}from'./chunk-DQW8lSiz.js';import {U}from'./chunk-CMmgPgiU.js';import {F as Fe$2}from'./chunk-C9EdrQe6.js';import {B as Bn,Z as Ze,R as Rn,J as Jt}from'./chunk-Drc5kcUX.js';import {a as at}from'./chunk-B-fklW6A.js';import'./chunk-D28lTX0k.js';var Oe=(n,t)=>t.BackupId;function Fe(n,t){n&1&&(Qi(0,"div",14),mg(1,"sh-progress-bar",20),Qi(2,"p"),XT(3,3),Hl()());}function Pe(n,t){n&1&&(Qi(0,"div",15)(1,"p"),XT(2,4),Hl()());}function Me(n,t){if(n&1){let e=gT();Qi(0,"sh-icon",33),Fg("click",function(){Sd(e);let o=nC(3);return xd(o.searchTerm.set(""))}),PC(1,"x-circle"),Hl();}}function he(n,t){if(n&1){let e=gT();Qi(0,"div",27)(1,"sh-form-field")(2,"input",28),sm("ngModelChange",function(o){Sd(e);let c=nC(2);return HC(c.searchTerm,o)||(c.searchTerm=o),xd(o)}),Hl(),DD(),Qi(3,"sh-icon",29),PC(4,"magnifying-glass"),Hl(),oT(5,Me,2,0,"sh-icon",30),Hl()(),Qi(6,"div",31)(7,"button",32),Fg("click",function(){Sd(e);let o=nC(2);return xd(o.selectAll())}),XT(8,6),Hl(),Qi(9,"button",32),Fg("click",function(){Sd(e);let o=nC(2);return xd(o.selectNone())}),XT(10,7),Hl()();}if(n&2){let e=nC(2);DE(2),im("ngModel",e.searchTerm),TD(),DE(3),iT(e.searchTerm()?5:-1),DE(2),gg("disabled",e.allSelected()),DE(2),gg("disabled",e.noneSelected());}}function Le(n,t){if(n&1&&(Qi(0,"div"),XT(1,8),tb(2,"bytes"),Hl()),n&2){let e=nC().$implicit;DE(2),Lg(rb(2,1,e.Metadata?.SourceFilesSize)),eC(1);}}function ye(n,t){if(n&1&&(Qi(0,"div"),XT(1,9),tb(2,"bytes"),Hl()),n&2){let e=nC().$implicit;DE(2),Lg(rb(2,1,e.Metadata?.TargetFilesSize)),eC(1);}}function Ae(n,t){if(n&1&&(Qi(0,"div"),XT(1,10),tb(2,"relativeTime"),Hl()),n&2){let e=nC().$implicit;DE(2),Lg(ob(2,1,e.Metadata?.LastBackupFinished,false)),eC(1);}}function Re(n,t){if(n&1){let e=gT();Qi(0,"sh-card",34),Fg("click",function(){let o=Sd(e).$implicit,c=nC(2);return xd(c.toggleSelected(o.BackupId))}),Qi(1,"sh-checkbox",35),sm("checkedChange",function(o){let c=Sd(e).$implicit;return HC(c.Selected,o)||(c.Selected=o),xd(o)}),Qi(2,"h3"),PC(3),Qi(4,"sh-chip",36),mg(5,"img",37),PC(6),Hl()()(),Qi(7,"div",38),oT(8,Le,3,3,"div"),oT(9,ye,3,3,"div"),oT(10,Ae,3,4,"div"),Hl()();}if(n&2){let e=t.$implicit,i=nC(2);Qg("unmatched",e.Match===false),DE(),im("checked",e.Selected),DE(2),Gl(" ",e.Name," "),DE(2),gg("src",i.getBackendIcon(e.TargetURLDisplay),Wp),DE(),Gl(" ",i.getBackendType(e.TargetURLDisplay)," "),DE(2),iT(e.Metadata?.SourceFilesSize?8:-1),DE(),iT(e.Metadata?.TargetFilesSize?9:-1),DE(),iT(e.Metadata?.LastBackupFinished?10:-1);}}function Ge(n,t){if(n&1){let e=gT();Qi(0,"sh-toggle",26),sm("checkedChange",function(o){Sd(e);let c=nC(2);return HC(c.saveNow,o)||(c.saveNow=o),xd(o)}),Og(1,11),mg(2,"sh-icon",39),Pg(),Hl();}if(n&2){let e=nC(2);gg("color","primary"),im("checked",e.saveNow),DE(2),gg("shTooltip","Save backups without editing the configuration");}}function De(n,t){n&1&&(Qi(0,"sh-toggle",25),Og(1,12),mg(2,"sh-icon",39),Pg(),Hl()),n&2&&(gg("color","primary")("checked",true)("disabled",true),DE(2),gg("shTooltip","Save now can only be disabled when importing a single backup"));}function ke(n,t){if(n&1){let e=gT();oT(0,he,11,4),Qi(1,"div",21),cT(2,Re,11,9,"sh-card",22,Oe),Hl(),Qi(4,"div",23),oT(5,Ge,3,3,"sh-toggle",24)(6,De,3,4,"sh-toggle",25),Qi(7,"sh-toggle",26),sm("checkedChange",function(o){Sd(e);let c=nC();return HC(c.importMetadata,o)||(c.importMetadata=o),xd(o)}),XT(8,5),Hl()();}if(n&2){let e=nC();iT(e.configs().length>1?0:-1),DE(2),lT(e.configsSorted()),DE(3),iT(e.selectedItems().length<=1?5:6),DE(2),gg("color","primary"),im("checked",e.importMetadata);}}function $e(n,t){n&1&&XT(0,2,1);}function be(n,t){n&1&&XT(0,2,2);}var w=class n{#t=T(d);#n=T(C);#e=T(ee);#i=T(fe);#o=T(g);getBackendType=Oe$1;getBackendIcon=Fe$1;isLoading=Ue(true);isImporting=Ue(false);configs=Ue([]);saveNow=Ue(false);importMetadata=Ue(false);searchTerm=Ue("");allSelected=Nt(()=>this.selectedItems().length===this.configs().length);noneSelected=Nt(()=>this.selectedItems().length===0);configsSorted=Nt(()=>{let t=this.searchTerm().toLowerCase();return this.configs().map(e=>m(l({},e),{Match:t?e.Name?.toLowerCase().includes(t):null})).sort((e,i)=>(e.Name??"").localeCompare(i.Name??"")).sort((e,i)=>e.Match===i.Match?0:e.Match?-1:1)});ngOnInit(){let t=this.#t.temporaryBackupId();if(!t){this.#e.navigate(["/backup/import-destination/destination"]);return}this.#n.postApiV1BackupByIdRestoreTaskConfig({id:t}).pipe(Bu(()=>this.isLoading.set(false))).subscribe({next:e=>{let i=e.sort((o,c)=>(o.Name??"").localeCompare(c.Name??"")).map(o=>m(l({},o),{Selected:e.length===1}));this.configs.set(i);},error:e=>{this.#t.showErrorDialog(e.message||"Failed to fetch configurations");}});}toggleSelected(t){this.configs.update(e=>e.map(i=>i.BackupId===t?m(l({},i),{Selected:!i.Selected}):i));}selectAll(){this.configs.update(t=>t.map(e=>m(l({},e),{Selected:true})));}selectNone(){this.configs.update(t=>t.map(e=>m(l({},e),{Selected:false})));}selectedItems=Nt(()=>this.configs().filter(t=>t.Selected));import(){let t=this.selectedItems();if(t.length===0)return;let e=this.importMetadata(),i=this.saveNow()||t.length!==1;this.isImporting.set(true);let o=c=>{if(c>=t.length){this.isImporting.set(false),this.#i.success($localize`Successfully imported ${t.length} backup(s)`),this.#e.navigate(["/"]);return}let N=t[c];this.#n.postApiV1BackupByIdImportfromtemp({requestBody:{BackupId:N.BackupId,ImportMetadata:e,Direct:i}}).subscribe({next:u=>{if(i)this.configs.update(I=>I.filter(G=>G.BackupId!==N.BackupId)),o(c+1);else {this.isImporting.set(false);let I=this.#o.addDraftBackup(u.data);this.#e.navigate(["/backup-draft",I]);}},error:u=>{this.isImporting.set(false),this.#t.showErrorDialog(`Failed to import ${N.Name}: ${u.message}`);}});};o(0);}back(){this.#e.navigate(["/backup/import-destination/encryption"]);}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=dw({type:n,selectors:[["app-import-destination-select-config"]],decls:14,vars:4,consts:()=>{let t;t=$localize`Select configurations to import`;let e;e=$localize`Back`;let i;i=$localize`${"\uFFFD*12:1\uFFFD"}:START_BLOCK_IF: Importing... ${"\uFFFD/*12:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*13:2\uFFFD"}:START_BLOCK_ELSE: Import selected ${"\uFFFD/*13:2\uFFFD"}:CLOSE_BLOCK_ELSE:`;let o;o=$localize`Fetching backup configurations from destination...`;let c;c=$localize`No backup configurations found at this destination.`;let N;N=$localize`Import metadata`;let u;u=$localize`Search for destination...`;let I;I=$localize`Select all`;let G;G=$localize`Select none`;let K;K=$localize` Source size: ${"\uFFFD0\uFFFD"}:INTERPOLATION: `;let U;U=$localize` Target size: ${"\uFFFD0\uFFFD"}:INTERPOLATION: `;let J;J=$localize` Last backup: ${"\uFFFD0\uFFFD"}:INTERPOLATION: `;let X;X=$localize` Save now ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let z;return z=$localize` Save now ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON: info ${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`,[t,e,i,o,c,N,I,G,K,U,J,X,z,[1,"content-wrapper"],[1,"loading-state"],[1,"empty-state"],[1,"actions"],["shButton","",3,"click","disabled"],[1,"spacer"],["shButton","",1,"primary","raised",3,"click","disabled"],[1,"primary","indeterminate"],[1,"config-list"],[1,"type-a","actionable","full-width",3,"unmatched"],[1,"options"],[3,"color","checked"],[3,"color","checked","disabled"],[3,"checkedChange","color","checked"],[1,"search-area"],["type","text","placeholder",u,3,"ngModelChange","ngModel"],["prefix",""],["suffix","",1,"clear-search"],[1,"list-actions"],["shButton","",1,"small",3,"click","disabled"],["suffix","",1,"clear-search",3,"click"],[1,"type-a","actionable","full-width",3,"click"],[1,"primary","raised",3,"checkedChange","checked"],[1,"small","provider"],["alt","",1,"provider-icon",3,"src"],[1,"metadata"],[1,"small",3,"shTooltip"]]},template:function(e,i){e&1&&(Qi(0,"div",13)(1,"h2"),XT(2,0),Hl(),oT(3,Fe,4,0,"div",14)(4,Pe,3,0,"div",15)(5,ke,9,4),Qi(6,"div",16)(7,"button",17),Fg("click",function(){return i.back()}),XT(8,1),Hl(),mg(9,"div",18),Qi(10,"button",19),Fg("click",function(){return i.import()}),Og(11,2),oT(12,$e,1,0)(13,be,1,0),Pg(),Hl()()()),e&2&&(DE(3),iT(i.isLoading()?3:i.configs().length===0?4:5),DE(4),gg("disabled",i.isImporting()),DE(3),gg("disabled",i.isImporting()||i.selectedItems().length===0||i.isLoading()),DE(2),iT(i.isImporting()?12:13));},dependencies:[v,f,J,U,Bn,Ze,Rn,Jt,d$1,at,N,D,Fe$2,m$1,m$2],styles:["[_nghost-%COMP%]{display:block;padding:2rem;max-width:50rem;margin:0 auto}.loading-state[_ngcontent-%COMP%], .empty-state[_ngcontent-%COMP%]{text-align:center;padding:4rem 2rem}.loading-state[_ngcontent-%COMP%] p[_ngcontent-%COMP%], .empty-state[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin-top:1rem;color:var(--color-on-surface-variant)}h2[_ngcontent-%COMP%]{margin-bottom:2rem}.search-area[_ngcontent-%COMP%]{display:flex;flex-direction:row;gap:1rem;margin-bottom:2rem}.list-actions[_ngcontent-%COMP%]{display:flex;flex-direction:row;gap:.5rem;margin-bottom:.5rem;justify-content:flex-end}.clear-search[_ngcontent-%COMP%]{opacity:.6;cursor:pointer}.config-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem;margin-bottom:2rem}.config-list[_ngcontent-%COMP%] sh-card[_ngcontent-%COMP%]{padding:1rem;cursor:pointer;display:flex;flex-direction:column;gap:.5rem}.config-list[_ngcontent-%COMP%] sh-card.unmatched[_ngcontent-%COMP%]{opacity:.4}.config-list[_ngcontent-%COMP%] sh-card[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;flex-direction:row;align-items:center;gap:.5rem;flex-grow:1}.config-list[_ngcontent-%COMP%] sh-card[_ngcontent-%COMP%] .provider[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.config-list[_ngcontent-%COMP%] sh-card[_ngcontent-%COMP%] .metadata[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;margin-left:1.75rem}.provider-icon[_ngcontent-%COMP%]{width:1.25rem;height:1.25rem}.options[_ngcontent-%COMP%]{margin-bottom:2rem;display:flex;flex-direction:column;gap:1rem}.actions[_ngcontent-%COMP%]{display:flex;align-items:center;margin-top:2rem}.actions[_ngcontent-%COMP%] .spacer[_ngcontent-%COMP%]{flex:1}"]})};export{w as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import {L}from'./chunk-
|
|
1
|
+
import {L}from'./chunk-D28lTX0k.js';import {T as T$1,ab as C$1,a as T$2,bg as Q,m as m$1,U as Ue,N as Nt,G as Ga,aj as l,a$ as Vs,aZ as ee}from'./main-PXGZLKMN.js';var _="shown-welcome-page-v1",m="hide-console-connection-status",A="use-out-of-process-controller",R="disable-console-control",b="disable-tray-icon-login",c="server-listen-interface",T="allowed-hostnames",D="server-passphrase",N="update-channel",w="startup-delay",y="usage-reporter-level",P="power-mode-provider",I="autogenerated-passphrase",C="has-asked-for-password-change",O=class o{#s=T$1(C$1);#r=T$1(T$2);#n=T$1(Q);#i=T$1(m$1);#o=L(this.#s.getApiV1Serversettings());#e=Ue(void 0);#t(e,t){if(!t)return false;let s=t[e];if((s??"").trim().length==0)return false;let r=s.trim().toLowerCase();return r==="true"||r==="1"||r==="yes"||r==="on"}serverSettings=Nt(()=>this.#e()||this.#o());askForInitialPasswordConfig=Nt(()=>{let e=(this.#i.systemInfo()?.StartedBy??"").trim().toLowerCase();if(e==="tray icon"||e=="trayicon")return false;let t=this.#e(),s=this.#t(I,t),r=this.#t(C,t);return s&&!r});showWelcomePage=Nt(()=>{let e=this.#e();if(!e)return false;let t=this.#t(C,e),s=this.#t(_,e);return !(t||s)});#c=Ga(()=>{let e=this.#r.serverSettings();e&&this.#e.set(e);});constructor(){this.#r.subscribe("serversettings");}isConsoleConnectionStatusHidden=Nt(()=>this.#t(m,this.serverSettings()));isControllerIpcEnabled=Nt(()=>this.#t(A,this.serverSettings()));refreshServerSettings(){this.#n.getConnectionMethod()!=="websocket"&&this.#s.getApiV1Serversettings().subscribe({next:e=>{this.#e.set(e);}});}#a(e,t){var s=l({},e);for(let[r,S]of Object.entries(t))S===null?delete s[r]:s[r]=S;return s}patchServerSettings(e){let t=l({},this.serverSettings());return this.#e.set(this.#a(this.serverSettings()??{},e)),this.#s.patchApiV1Serversettings({requestBody:e}).pipe(Vs(s=>{throw this.#e.set(t),s}))}patchServerSetting(e,t){let s={};return s[e]=t,this.patchServerSettings(s)}setShownWelcomePage(){return this.patchServerSetting(_,"true")}setHideConsoleConnectionStatus(e){return this.patchServerSetting(m,e?"True":"False")}setControllerIpcState(e){return this.patchServerSetting(A,e?"True":"False")}setDisableTrayIconLogin(e){return this.patchServerSetting(b,e?"True":"False")}setDisableConsoleControl(e){return this.patchServerSetting(R,e?"True":"False")}setRemoteAccessInterface(e){return this.patchServerSetting(c,e)}setRemoteAccessAllowedHostnames(e){var t={[T]:e};return this.serverSettings()?.[c]==="loopback"&&(t[c]="any"),this.patchServerSettings(t)}setRemoteAccessPassword(e){return this.patchServerSetting(D,e)}setUpdateChannel(e){return this.patchServerSetting(N,e)}setStartupDelay(e){return this.patchServerSetting(w,e)}setUsageReporterLevel(e){return this.patchServerSetting(y,e)}setPowerModeProvider(e){return this.patchServerSetting(P,e)}static \u0275fac=function(t){return new(t||o)};static \u0275prov=ee({token:o,factory:o.\u0275fac,providedIn:"root"})};export{O};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import {T,ab as C,a6 as be,a5 as g,e as ee,b as g1,N as Nt,U as Ue,at as h,C as Bu,d as dw,v,f as N,_ as _t,aH as m,ak as cm,Q as Qi,X as XT,H as Hl,o as oT,q as PC,F as Fg,al as BC,D as DE,au as Lg,av as eC,i as iT,z as gg,a_ as ZC,a3 as QC,I as Qg,t as tC,k as gT,s as sm,S as Sd,n as nC,l as HC,x as xd,p as DD,w as im,y as TD,aM as tb,ao as $C,aS as ib,aG as pt,a$ as Vs,b0 as ty}from'./main-
|
|
1
|
+
import {T,ab as C,a6 as be,a5 as g,e as ee,b as g1,N as Nt,U as Ue,at as h,C as Bu,d as dw,v,f as N,_ as _t,aH as m,ak as cm,Q as Qi,X as XT,H as Hl,o as oT,q as PC,F as Fg,al as BC,D as DE,au as Lg,av as eC,i as iT,z as gg,a_ as ZC,a3 as QC,I as Qg,t as tC,k as gT,s as sm,S as Sd,n as nC,l as HC,x as xd,p as DD,w as im,y as TD,aM as tb,ao as $C,aS as ib,aG as pt,a$ as Vs,b0 as ty}from'./main-PXGZLKMN.js';import {$}from'./chunk-D28lTX0k.js';import {U}from'./chunk-CMmgPgiU.js';import {B as Bn,y as yt,R as Rn,J as Jt}from'./chunk-Drc5kcUX.js';var Ee=l=>["/backup",l,"export"],ue=()=>["/"];function Ce(l,_){if(l&1){let e=gT();Qi(0,"section")(1,"h4"),XT(2,4),Hl(),Qi(3,"p"),XT(4,5),Hl(),Qi(5,"sh-checkbox",11),PC(6," Delete local database "),Qi(7,"input",12),sm("ngModelChange",function(t){Sd(e);let a=nC();return HC(a.deleteLocalDb,t)||(a.deleteLocalDb=t),xd(t)}),Hl(),DD(),Hl()();}if(l&2){let e=nC();DE(7),im("ngModel",e.deleteLocalDb),TD();}}function de(l,_){if(l&1){let e=gT();Qi(0,"section")(1,"h4"),XT(2,6),Hl(),Qi(3,"p"),XT(4,7),tb(5,"bytes"),Hl(),Qi(6,"sh-checkbox",11),PC(7," Delete remote files "),Qi(8,"input",12),sm("ngModelChange",function(t){Sd(e);let a=nC();return HC(a.deleteRemoteFiles,t)||(a.deleteRemoteFiles=t),xd(t)}),Hl(),DD(),Hl()();}if(l&2){let e=nC(),t=$C(0)?.Backup?.Metadata?.TargetFilesSize??0;DE(5),Lg(e.fileCount())(e.fileCount())(ib(5,4,t,true,true)),eC(4),DE(3),im("ngModel",e.deleteRemoteFiles),TD();}}var R=class l{#t=T(C);#n=T(be);#e=T(g);#o=T(ee);id=g1.required();backup=Nt(()=>this.#e.getBackupById(this.id()));noLocalDbResource=$({params:()=>({dbPath:this.backup()?.Backup?.DBPath}),stream:({params:_})=>this.#t.postApiV1FilesystemValidate({requestBody:{path:_.dbPath}}).pipe(pt(()=>true),Vs(()=>ty(false)))});fileCount=Nt(()=>parseInt(this.backup()?.Backup?.Metadata?.TargetFilesCount??"0",10));deleteLocalDb=Ue(false);deleteRemoteFiles=Ue(false);isDeleting=Ue(false);deleteBackup(){let _=this.id(),e=this.deleteLocalDb(),i=this.deleteRemoteFiles();this.isDeleting.set(true),this.#n.open(h,{data:{title:$localize`Confirm delete`,message:$localize`Are you sure you want to delete this backup?`,confirmText:$localize`Delete backup`,cancelText:$localize`Cancel`},closed:t=>{t&&this.#e.deleteBackup({id:_,deleteLocalDb:e,deleteRemoteFiles:i}).pipe(Bu(()=>this.isDeleting.set(false))).subscribe({next:()=>{this.#o.navigate(["/"]);}});}});}static \u0275fac=function(e){return new(e||l)};static \u0275cmp=dw({type:l,selectors:[["app-delete-backup"]],inputs:{id:[1,"id"]},decls:19,vars:11,consts:()=>{let _;_=$localize`Delete backup: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let e;e=$localize`Export configuration`;let i;i=$localize`If you want to use the backup later, you can export the configuration before deleting it.`;let t;t=$localize`Cancel`;let a;a=$localize`Delete local database`;let O;O=$localize` Each backup has a local database associated with it, which stores information about the remote backup on the local machine. When deleting a backup, you can also delete the local database without affecting the ability to restore the remote files. If you are using the local database for backups from the commandline, you should keep the database. `;let y;y=$localize`Delete remote files`;let d;d=$localize`{VAR_PLURAL, plural, =1 {1 file} other {{INTERPOLATION} files}}`,d=tC(d,{INTERPOLATION:"\uFFFD1\uFFFD",VAR_PLURAL:"\uFFFD0\uFFFD"});let k;return k=$localize` Delete ${d}:ICU@@2159106180826349718: (${"\uFFFD2\uFFFD"}:INTERPOLATION_1:) from the remote storage? `,[_,e,i,t,a,O,y,k,["shButton","",3,"routerLink"],[1,"actions"],["shButton","",1,"raised","error",3,"click"],[1,"primary","raised"],["type","checkbox",3,"ngModelChange","ngModel"]]},template:function(e,i){if(e&1&&(cm(0),Qi(1,"h3"),XT(2,0),Hl(),oT(3,Ce,8,1,"section"),Qi(4,"section")(5,"h4"),XT(6,1),Hl(),Qi(7,"p"),XT(8,2),Hl(),Qi(9,"button",8),PC(10," Export configuration "),Qi(11,"sh-icon"),PC(12,"caret-right"),Hl()()(),oT(13,de,9,8,"section"),Qi(14,"div",9)(15,"button",8),XT(16,3),Hl(),Qi(17,"button",10),Fg("click",function(){return i.deleteBackup()}),PC(18,"Delete backup"),Hl()()),e&2){let t=BC(i.backup()),a=i.noLocalDbResource.value();DE(2),Lg(t?.Backup?.Name),eC(2),DE(),iT(a?3:-1),DE(6),gg("routerLink",ZC(8,Ee,i.id())),DE(4),iT(a?13:-1),DE(2),gg("routerLink",QC(10,ue)),DE(2),Qg("loading",i.isDeleting());}},dependencies:[U,v,N,Bn,yt,Rn,Jt,_t,m],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;padding:2.5rem;max-width:43.75rem}section[_ngcontent-%COMP%]{padding:2rem 0;display:flex;align-items:flex-start;flex-direction:column}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0}h4[_ngcontent-%COMP%]{font:var(--paragraph-20);margin-bottom:.5rem}p[_ngcontent-%COMP%]{margin-bottom:1rem}.actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;gap:.5rem;padding:2rem 0}"]})};export{R as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import {e as ee$1}from'./chunk-
|
|
1
|
+
import {e as ee$1}from'./chunk-D_JCqKo8.js';import'./chunk-w_Hs_Uxi.js';import'./chunk-D1wHRltX.js';import'./chunk-CBdr-6_u.js';import'./chunk-BZqhgAZ-.js';import'./chunk-B9zNFJSv.js';import {c}from'./chunk-COgNe44h.js';import'./chunk-BAZ5npJw.js';import {T,a5 as g,ab as C,d as dw,v,f as N,_ as _t,j as mg,Q as Qi,X as XT,H as Hl,b2 as sg,b3 as tT,o as oT,F as Fg,O as Og,P as Pg,D as DE,b4 as nT,i as iT,z as gg,a3 as QC,q as PC,n as nC,a1 as cT,ap as sT,a2 as lT,a_ as ZC,au as Lg,av as eC,aB as rm}from'./main-PXGZLKMN.js';import {f}from'./chunk-DJbAxHpK.js';import'./chunk-MvQwR7nW.js';import'./chunk-SycscfJp.js';import {d}from'./chunk-DQW8lSiz.js';import'./chunk-CMmgPgiU.js';import'./chunk-C9EdrQe6.js';import'./chunk-Drc5kcUX.js';import'./chunk-B-fklW6A.js';import'./chunk-D28lTX0k.js';var V=()=>[f,v,N,_t],K=()=>["/restore-from-files"],Q=()=>["/restore/from-config"],U=n=>["/restore",n];function Y(n,i){if(n&1&&(Qi(0,"sh-card",10),Fg("keydown.enter",function(r){return r.target.click()})("keydown.space",function(r){return r.target.click()}),mg(1,"img",16),Qi(2,"div",12)(3,"h3"),XT(4,7),Hl(),Qi(5,"p"),PC(6),Hl()(),Qi(7,"button",13),Og(8,8),mg(9,"sh-icon"),Pg(),Hl()()),n&2){let e=i.$implicit;gg("routerLink",ZC(4,U,e.Backup.ID)),DE(4),Lg(e.Backup.Name??"Backup name missing"),eC(4),DE(2),rm(" ",e.Backup.Metadata?.SourceSizeString??"-"," / ",e.Backup.Metadata?.BackupListCount??"-"," ");}}function Z(n,i){if(n&1&&cT(0,Y,10,6,"sh-card",15,sT),n&2){let e=nC(2);lT(e.backups());}}function ee(n,i){if(n&1&&oT(0,Z,2,0),n&2){let e=nC();iT(e.backups().length?0:-1);}}function ne(n,i){n&1&&(Qi(0,"div",17),mg(1,"sh-progress-bar",18),Qi(2,"div",12)(3,"h3"),XT(4,9),Hl()()());}function te(n,i){n&1&&(Qi(0,"sh-divider"),PC(1,"Or without a local configuration"),Hl());}var M=class n{#e=T(g);#n=T(C);backups=this.#e.backups;backupsLoading=this.#e.backupsLoading;ngOnInit(){this.#e.getBackups(true);}restoreNow(i){this.#n.postApiV1BackupByIdRestore({id:i.Backup?.ID,requestBody:{}});}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=dw({type:n,selectors:[["app-restore"]],decls:29,vars:6,consts:()=>{let i;i=$localize`Where do you want to restore from?`;let e;e=$localize`Direct restore from backup files`;let r;r=$localize`Point to your backup files and restore from there.`;let E;E=$localize` Start ${"\uFFFD#18\uFFFD"}:START_TAG_SH_ICON:play-circle${"\uFFFD/#18\uFFFD"}:CLOSE_TAG_SH_ICON:`;let _;_=$localize`Restore from configuration`;let h;h=$localize`Load destination from an exported job`;let I;I=$localize` Start ${"\uFFFD#28\uFFFD"}:START_TAG_SH_ICON:play-circle${"\uFFFD/#28\uFFFD"}:CLOSE_TAG_SH_ICON:`;let y;y=$localize`${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let $;$=$localize` Restore ${"\uFFFD#9\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SH_ICON:`;let k;return k=$localize`Loading backups...`,[i,e,r,E,_,h,I,y,$,k,[1,"type-a","actionable",3,"keydown.enter","keydown.space","routerLink"],["src","assets/images/backup.png","alt","","width","48px"],[1,"text"],["shButton","","tabindex","-1"],["src","assets/images/restore.png","alt","","width","48px"],[1,"type-a","actionable",3,"routerLink"],["src","assets/images/folder.png","alt","","width","48px"],[1,"loading-list"],[1,"indeterminate","primary"]]},template:function(e,r){e&1&&(mg(0,"app-status-bar"),Qi(1,"section")(2,"h2"),XT(3,0),Hl(),sg(4,ee,1,1)(5,ne,5,0),tT(6,4,V,null,5),oT(8,te,2,0,"sh-divider"),Qi(9,"sh-card",10),Fg("keydown.enter",function(_){return _.target.click()})("keydown.space",function(_){return _.target.click()}),mg(10,"img",11),Qi(11,"div",12)(12,"h3"),XT(13,1),Hl(),Qi(14,"p"),XT(15,2),Hl()(),Qi(16,"button",13),Og(17,3),mg(18,"sh-icon"),Pg(),Hl()(),Qi(19,"sh-card",10),Fg("keydown.enter",function(_){return _.target.click()})("keydown.space",function(_){return _.target.click()}),mg(20,"img",14),Qi(21,"div",12)(22,"h3"),XT(23,4),Hl(),Qi(24,"p"),XT(25,5),Hl()(),Qi(26,"button",13),Og(27,6),mg(28,"sh-icon"),Pg(),Hl()()()),e&2&&(DE(6),nT(!r.backupsLoading()),DE(2),iT(r.backups().length?8:-1),DE(),gg("routerLink",QC(4,K)),DE(10),gg("routerLink",QC(5,Q)));},dependencies:[ee$1,f,v,c,N,d,_t],styles:["[_nghost-%COMP%]{display:block}h2[_ngcontent-%COMP%]{font:var(--title-30);text-align:center;padding:2rem}section[_ngcontent-%COMP%]{max-width:43.75rem;margin:0 auto;padding:2rem 1rem;display:flex;flex-direction:column;gap:1rem}sh-divider[_ngcontent-%COMP%]{color:var(--base-8)}sh-card[_ngcontent-%COMP%]{display:flex;align-items:center;gap:1rem;--card-padding: 2rem}sh-card[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{flex:1 0;display:flex;flex-direction:column;gap:.25rem}.actionable[_ngcontent-%COMP%]{cursor:pointer}.actionable[_ngcontent-%COMP%]:after{transition:inset .1s linear}.actionable[_ngcontent-%COMP%]:hover{--card-shp: 0}"]})};export{M as default};
|