@duplicati/ngclient 0.0.144 → 0.0.145
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/{chunk-X3IA226Q.js → chunk-2F6NVETW.js} +1 -1
- package/{chunk-VC72SWC4.js → chunk-2QJC4PGQ.js} +1 -1
- package/{chunk-PT7UQJD4.js → chunk-2UCO57JQ.js} +1 -1
- package/chunk-2UGURIOT.js +1 -0
- package/{chunk-4YL5DZVH.js → chunk-43JMN2ZY.js} +1 -1
- package/{chunk-LZUM5XKC.js → chunk-4TDUWDRL.js} +1 -1
- package/{chunk-SCOG2I64.js → chunk-62QANGOE.js} +1 -1
- package/{chunk-XNVRJH42.js → chunk-6LTGTS6B.js} +1 -1
- package/{chunk-73RDJP55.js → chunk-6OPAGPKF.js} +1 -1
- package/{chunk-LEXA637O.js → chunk-7B43LCPI.js} +1 -1
- package/{chunk-KOVQRACM.js → chunk-7EBTJOD7.js} +1 -1
- package/{chunk-6GC5VKTI.js → chunk-7IQY6U5W.js} +1 -1
- package/chunk-A6VGO6B5.js +1 -0
- package/{chunk-GHFYBZHQ.js → chunk-AJTK6HBC.js} +1 -1
- package/chunk-B2D4QGDJ.js +1 -0
- package/chunk-BPJCKQYP.js +1 -0
- package/{chunk-UACX27D3.js → chunk-DDWLL7XA.js} +1 -1
- package/{chunk-GUH5TMOS.js → chunk-DELLEGXW.js} +1 -1
- package/{chunk-IHNX6WZQ.js → chunk-DFMGS3IN.js} +1 -1
- package/chunk-DFMPWF6R.js +1 -0
- package/chunk-DKTUN7FF.js +1 -0
- package/{chunk-KGJAK6OP.js → chunk-DLMKZACT.js} +1 -1
- package/{chunk-FFY3NRCC.js → chunk-DNDTLTUM.js} +1 -1
- package/{chunk-3UN32GIC.js → chunk-DVDTYV66.js} +1 -1
- package/{chunk-IGOZJJE3.js → chunk-E66CBA5F.js} +1 -1
- package/{chunk-JA7OQSO3.js → chunk-EBIM5FBM.js} +1 -1
- package/{chunk-GO22DJ44.js → chunk-ESUPNSKH.js} +1 -1
- package/{chunk-OTMW34HV.js → chunk-FCRM5DER.js} +1 -1
- package/chunk-FDCY62KM.js +1 -0
- package/chunk-FFEDQIYN.js +1 -0
- package/{chunk-XQ4CAUD4.js → chunk-FUOS2UGQ.js} +1 -1
- package/{chunk-BIETD4DI.js → chunk-FZHTJSDJ.js} +1 -1
- package/{chunk-BXRW2LGW.js → chunk-GB3UMYUD.js} +1 -1
- package/chunk-H7K35UUX.js +1 -0
- package/chunk-HI4XLHO3.js +1 -0
- package/{chunk-QDFCX6XE.js → chunk-HNWRQABR.js} +3 -3
- package/{chunk-J2MHNGNQ.js → chunk-IFW3O4YJ.js} +1 -1
- package/{chunk-CTEFMU6N.js → chunk-J3ONM4TQ.js} +1 -1
- package/{chunk-CDRDYQEV.js → chunk-KDYD6LMI.js} +1 -1
- package/{chunk-GCZWFRPZ.js → chunk-KGKIF5H4.js} +1 -1
- package/chunk-KLW6HEOS.js +1 -0
- package/{chunk-K3ZQ67VT.js → chunk-L6CWVBZ6.js} +1 -1
- package/chunk-LVP2TPMO.js +1 -0
- package/{chunk-5PSLWJTF.js → chunk-M6WWZKV7.js} +1 -1
- package/chunk-MAQO5X5Q.js +1 -0
- package/{chunk-GDBU3Z7P.js → chunk-MSLKIHQQ.js} +1 -1
- package/{chunk-UT6XGEMV.js → chunk-MVNLSG6Z.js} +1 -1
- package/{chunk-USU2EHJV.js → chunk-N5SC4SKW.js} +1 -1
- package/{chunk-QY6E755W.js → chunk-N6ABN43N.js} +1 -1
- package/{chunk-WWFNG47J.js → chunk-NJEX2N4Q.js} +1 -1
- package/{chunk-JIHMT35A.js → chunk-NJZSEKTD.js} +1 -1
- package/{chunk-J3BBLPAD.js → chunk-NOPMCS2Z.js} +1 -1
- package/{chunk-ACH476VA.js → chunk-NQ27E6KP.js} +1 -1
- package/{chunk-QGFC5ZUR.js → chunk-O64ZZGQZ.js} +1 -1
- package/{chunk-CZLLEVMJ.js → chunk-OMMUXRXE.js} +1 -1
- package/{chunk-AO4O42CM.js → chunk-OWDKOVPL.js} +1 -1
- package/{chunk-TJOWPBPB.js → chunk-PN3U7MRX.js} +1 -1
- package/{chunk-CFNP4FBG.js → chunk-POMLWQHO.js} +1 -1
- package/{chunk-BGUKMOKY.js → chunk-QDFDQHU3.js} +1 -1
- package/{chunk-7AMBMWZP.js → chunk-QHC3CY43.js} +1 -1
- package/{chunk-ARXKB7WH.js → chunk-QITXA3NT.js} +1 -1
- package/chunk-QYI4IMJE.js +8 -0
- package/{chunk-J5PSMGKZ.js → chunk-R5RIFWZO.js} +1 -1
- package/chunk-RPU4AJBK.js +1 -0
- package/chunk-RUFE3SMI.js +1 -0
- package/{chunk-WJPLJKPQ.js → chunk-RUXCS4ZK.js} +1 -1
- package/{chunk-7X7K5IXS.js → chunk-SFSB73YO.js} +1 -1
- package/{chunk-B5FUQFEQ.js → chunk-TDKBGGNK.js} +1 -1
- package/{chunk-6XBSQDXR.js → chunk-TIWH4NKT.js} +1 -1
- package/{chunk-XHUUCB2W.js → chunk-TKO3OH2C.js} +1 -1
- package/chunk-U5C62E46.js +1 -0
- package/chunk-UIIHBXLB.js +1 -0
- package/{chunk-OXOOR7I4.js → chunk-UIJYCGKA.js} +1 -1
- package/{chunk-ETCRT3EV.js → chunk-UKQFDBNO.js} +1 -1
- package/{chunk-CWBEE627.js → chunk-UP5EOICU.js} +1 -1
- package/{chunk-6WWCFRZ5.js → chunk-VHE3K2F5.js} +1 -1
- package/{chunk-66BSPEOQ.js → chunk-VTSUHAP5.js} +1 -1
- package/chunk-W6DRPPZU.js +1 -0
- package/{chunk-UW4GBMEP.js → chunk-WS76KLII.js} +1 -1
- package/{chunk-T4TFHAZT.js → chunk-XJZ5GM36.js} +1 -1
- package/{chunk-ZGAC2JKG.js → chunk-Z3EPZZGY.js} +1 -1
- package/{chunk-FVE45QKX.js → chunk-ZNWZFRFW.js} +1 -1
- package/index.html +2 -2
- package/{main-SUSCPR3H.js → main-Z5T5HH5Q.js} +1 -1
- package/package.json +1 -1
- package/styles-LRXGHWCZ.css +1 -0
- package/chunk-2CTSAUUN.js +0 -1
- package/chunk-2NU5Y4V7.js +0 -1
- package/chunk-2RB5RKNM.js +0 -1
- package/chunk-74NKDA4G.js +0 -1
- package/chunk-7WD3AN66.js +0 -1
- package/chunk-AB2L3URR.js +0 -1
- package/chunk-B7NRTB6T.js +0 -1
- package/chunk-C2L3SQU3.js +0 -1
- package/chunk-ERKYRXHP.js +0 -8
- package/chunk-HKZX6OB5.js +0 -1
- package/chunk-L2EO4M4B.js +0 -1
- package/chunk-ODVCGM2O.js +0 -1
- package/chunk-QFU6VJXV.js +0 -1
- package/chunk-QNOIURSX.js +0 -1
- package/chunk-UGLRUY6T.js +0 -1
- package/chunk-UUODEERG.js +0 -1
- package/chunk-WHKW5IYF.js +0 -1
- package/chunk-WRNQOX5R.js +0 -1
- package/chunk-ZVIRETHC.js +0 -1
- package/styles-EZGVWHZF.css +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as le}from"./chunk-
|
|
1
|
+
import{a as le}from"./chunk-L6CWVBZ6.js";import{a as se,b as ae}from"./chunk-OMMUXRXE.js";import{h as ie}from"./chunk-MSLKIHQQ.js";import"./chunk-N6ABN43N.js";import"./chunk-DDWLL7XA.js";import"./chunk-2QJC4PGQ.js";import"./chunk-O64ZZGQZ.js";import"./chunk-DELLEGXW.js";import"./chunk-RHW5QVAY.js";import"./chunk-VTSUHAP5.js";import{c as Z,e as J,i as ee,k as ne,s as te,t as oe}from"./chunk-N5SC4SKW.js";import{b as V,d as H}from"./chunk-LVP2TPMO.js";import"./chunk-43JMN2ZY.js";import{a as q,g as Y,l as Q,t as j}from"./chunk-H7K35UUX.js";import"./chunk-NOPMCS2Z.js";import"./chunk-RUXCS4ZK.js";import"./chunk-FPPZ4BUR.js";import{Ab as t,Bb as i,Cb as g,Jb as F,Oc as I,Qb as S,Ra as c,Rb as O,Sb as r,Vc as W,Wb as M,Yb as p,_ as C,bb as x,ea as P,ec as G,fa as f,fc as K,ic as U,oa as v,qc as u,rc as d,sc as m,ub as h,vb as N,zb as T,zc as X}from"./chunk-HNWRQABR.js";import"./chunk-EUDKD2JW.js";var _e=["formRef"],re=()=>["--skip-files-larger-than","dblock-size","encryption-module","no-encryption","--no-encryption","compression-module","--exclude-files-attributes","keep-time","keep-versions","retention-policy"];function ce(s,l){s&1&&(S(0,1,1),g(1,"sh-icon",20),O())}function pe(s,l){s&1&&(t(0,"p",21),r(1,6),i())}function ue(s,l){s&1&&(t(0,"p"),r(1,7),i())}function de(s,l){if(s&1){let n=F();t(0,"p"),r(1,8),i(),t(2,"app-timespan",18),m("ngModelChange",function(a){P(n);let o=p();return d(o.optionsFields.backupRetentionTime,a)||(o.optionsFields.backupRetentionTime=a),f(a)}),t(3,"label",30),r(4,9),i()()}if(s&2){let n=p();c(2),T("customId","backupRetentionTime"),u("ngModel",n.optionsFields.backupRetentionTime)}}function me(s,l){if(s&1){let n=F();t(0,"p"),r(1,10),i(),t(2,"sh-form-field")(3,"label",31),r(4,11),i(),t(5,"input",32),m("ngModelChange",function(a){P(n);let o=p();return d(o.optionsFields.backupRetentionVersions,a)||(o.optionsFields.backupRetentionVersions=a),f(a)}),i()()}if(s&2){let n=p();c(5),u("ngModel",n.optionsFields.backupRetentionVersions)}}function Se(s,l){s&1&&(t(0,"p"),r(1,12),i())}function Oe(s,l){if(s&1){let n=F();t(0,"p"),r(1,13),i(),t(2,"sh-form-field")(3,"p"),r(4,14),i(),t(5,"label",33),r(6,15),i(),t(7,"input",34),m("ngModelChange",function(a){P(n);let o=p();return d(o.optionsFields.backupRetentionCustom,a)||(o.optionsFields.backupRetentionCustom=a),f(a)}),i()()}if(s&2){let n=p();c(7),u("ngModel",n.optionsFields.backupRetentionCustom)}}var Te=["Bytes","KB","MB","GB","TB","PB"],ge=[{value:"all",name:$localize`Keep all backups`},{value:"time",name:$localize`Delete backups that are older than`},{value:"versions",name:$localize`Keep a specific number of backups`},{value:"smart",name:$localize`Smart backup retention`},{value:"custom",name:$localize`Custom backup retention`}],Ce=1024*1024*1024*2,Pe=1024*1024*5,E=class s{#e=C(ie);#n=C(H);#t=C(V);formRef=W.required("formRef");selectedOptions=this.#e.selectedOptions;nonSelectedOptions=this.#e.nonSelectedOptions;isSubmitting=this.#e.isSubmitting;settings=this.#e.settings;optionsFields=this.#e.optionsFields;applicationOptions=this.#e.applicationOptions;retentionOptions=v(ge);sizeSplit=I(()=>{let n=this.optionsFields.remoteVolumeSize().match(/^(\d+)(bytes|kb|mb|gb|tb|pb|b)$/i);return{value:n?parseInt(n[1],10):0,unit:n?n[2].toUpperCase():"MB"}});exceededVolumeSize=I(()=>{let l=this.sizeSplit().value,n=this.sizeSplit().unit;if(l==null||n===null||n===void 0)return!1;let e=l*Math.pow(1024,Te.indexOf(n));return e>Ce||e<Pe});goBack(){this.#n.navigate(["schedule"],{relativeTo:this.#t.parent})}submit(){this.#e.submit()}static \u0275fac=function(n){return new(n||s)};static \u0275cmp=x({type:s,selectors:[["app-advanced-options-settings"]],viewQuery:function(n,e){n&1&&G(e.formRef,_e,5),n&2&&K()},decls:30,vars:16,consts:()=>{let l;l=$localize`Options`;let n;n=$localize` Remote volume size ${"\uFFFD*7:1\uFFFD"}:START_BLOCK_IF:${"\uFFFD#1:1\uFFFD"}:START_TAG_SH_ICON:warning${"\uFFFD/#1:1\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*7:1\uFFFD"}:CLOSE_BLOCK_IF:`;let e;e=$localize` The backups will be split up into multiple files called volumes. Here you can set the maximum size of the individual volume files. ${"\uFFFD#11\uFFFD"}:START_LINK: Read more ${"\uFFFD#12\uFFFD"}:START_TAG_SH_ICON:arrow-square-out${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#11\uFFFD"}:CLOSE_LINK:`;let a;a=$localize`Backup retention`;let o;o=$localize`${"\uFFFD#26\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#26\uFFFD"}:CLOSE_TAG_SH_ICON: Go back `;let b;b=$localize`${"\uFFFD#29\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#29\uFFFD"}:CLOSE_TAG_SH_ICON: Submit `;let A;A=$localize` The chosen size is outside the recommended range. This may cause performance issues, excessively large temporary files or other problems. `;let R;R=$localize`Nothing will be deleted. The backup size will grow with each change.`;let y;y=$localize`If at least one newer backup is found, all backups older than this date are deleted.`;let $;$=$localize`Time to keep versions`;let k;k=$localize`Once there are more backups than the specified number, the oldest backups are deleted.`;let w;w=$localize`Number of versions`;let D;D=$localize` Over time backups will be deleted automatically. There will remain one backup for each of the last 7 days, each of the last 4 weeks, each of the last 12 months. There will always be at least one remaining backup. `;let B;B=$localize` Enter a retention strategy manually. Placeholders are D/W/Y for days/weeks/years and U for unlimited. The syntax is: 7D:1D,4W:1W,36M:1M. This example keeps one backup for each of the next 7 days, one for each of the next 4 weeks, and one for each of the next 36 months. This can also be written as 1W:1D,1M:1W,3Y:1M. `;let L;L=$localize`Once there are more backups than the specified number, the oldest backups are deleted.`;let z;return z=$localize`Retention expression`,[l,n,e,a,o,b,A,R,y,$,k,w,D,B,L,z,[1,"title-30"],[1,"remote-volume-wrap"],[3,"ngModelChange","customId","ngModel"],["for","size"],[1,"warning"],[1,"warn"],["href","https://forum.duplicati.com/t/choosing-sizes-in-duplicati/17683","target","_blank",1,"sh-primary"],["suffix",""],["value","value","label","name",3,"options","inlineSearch","isClearable"],["type","text",3,"ngModelChange","ngModel"],[3,"optionsChange","options","applicationOptions","hasFreeTextSettings","hiddenOptions"],[1,"form-actions"],["shButton","","type","button",3,"click"],["shButton","",1,"raised","primary",3,"click"],["for","backupRetentionTime"],["for","backupRetentionVersions"],["type","number","id","backupRetentionVersions",3,"ngModelChange","ngModel"],["for","backupRetentionCustom"],["type","text","id","backupRetentionCustom",3,"ngModelChange","ngModel"]]},template:function(n,e){n&1&&(t(0,"section")(1,"h3",16),r(2,0),i(),t(3,"div",17)(4,"app-size",18),m("ngModelChange",function(o){return d(e.optionsFields.remoteVolumeSize,o)||(e.optionsFields.remoteVolumeSize=o),o}),t(5,"label",19),S(6,1),h(7,ce,2,0,"sh-icon",20),O(),i()(),h(8,pe,2,0,"p",21),t(9,"p"),S(10,2),t(11,"a",22),g(12,"sh-icon",23),i(),O(),i()(),t(13,"sh-select",24)(14,"label",19),r(15,3),i(),t(16,"input",25),m("ngModelChange",function(o){return d(e.optionsFields.backupRetention,o)||(e.optionsFields.backupRetention=o),o}),i()(),h(17,ue,2,0,"p")(18,de,5,2)(19,me,6,1)(20,Se,2,0,"p")(21,Oe,8,1),t(22,"app-options-list",26),m("optionsChange",function(o){return d(e.settings,o)||(e.settings=o),o}),i(),t(23,"div",27)(24,"button",28),M("click",function(){return e.goBack()}),S(25,4),g(26,"sh-icon"),O(),i(),t(27,"button",29),M("click",function(){return e.submit()}),S(28,5),g(29,"sh-icon"),O(),i()()()),n&2&&(c(4),T("customId","size"),u("ngModel",e.optionsFields.remoteVolumeSize),c(3),N(e.exceededVolumeSize()?7:-1),c(),N(e.exceededVolumeSize()?8:-1),c(5),T("options",e.retentionOptions())("inlineSearch",!0)("isClearable",!1),c(3),u("ngModel",e.optionsFields.backupRetention),c(),N(e.optionsFields.backupRetention()==="all"?17:e.optionsFields.backupRetention()==="time"?18:e.optionsFields.backupRetention()==="versions"?19:e.optionsFields.backupRetention()==="smart"?20:e.optionsFields.backupRetention()==="custom"?21:-1),c(5),u("options",e.settings),T("applicationOptions",e.applicationOptions())("hasFreeTextSettings",!0)("hiddenOptions",X(15,re)),c(5),U("loader",e.isSubmitting()))},dependencies:[te,Z,ne,J,ee,oe,le,Y,q,j,se,ae,Q],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:32.5rem;padding:2.5rem}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;padding-bottom:1.5rem}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}.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}.advanced-option[_ngcontent-%COMP%]{display:grid;gap:.5rem;grid-template-columns:1fr 1fr 2.5rem;align-items:flex-end}sh-select[_ngcontent-%COMP%]{--miw: p2r(120)}"],changeDetection:0})};export{E as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as G}from"./chunk-
|
|
1
|
+
import{a as G}from"./chunk-NJEX2N4Q.js";import{h as T}from"./chunk-MSLKIHQQ.js";import"./chunk-N6ABN43N.js";import"./chunk-DDWLL7XA.js";import"./chunk-2QJC4PGQ.js";import{b as m}from"./chunk-O64ZZGQZ.js";import"./chunk-6LTGTS6B.js";import{a as L}from"./chunk-DVDTYV66.js";import"./chunk-UIJYCGKA.js";import"./chunk-DELLEGXW.js";import"./chunk-RHW5QVAY.js";import"./chunk-VTSUHAP5.js";import"./chunk-UP5EOICU.js";import"./chunk-N5SC4SKW.js";import"./chunk-Z3EPZZGY.js";import"./chunk-UKQFDBNO.js";import{b as E,c as B,e as b,f as M}from"./chunk-LVP2TPMO.js";import"./chunk-43JMN2ZY.js";import{p as $,q as N,v as I}from"./chunk-H7K35UUX.js";import{h as v}from"./chunk-NOPMCS2Z.js";import"./chunk-TDKBGGNK.js";import"./chunk-RUXCS4ZK.js";import"./chunk-FPPZ4BUR.js";import"./chunk-6OPAGPKF.js";import{Ab as s,Bb as u,Bc as _,Cb as r,F as f,Pc as O,Qb as c,Ra as n,Rb as p,Yb as R,_ as l,bb as D,lc as A,nc as k,ub as h,vb as g,yc as P,zb as d}from"./chunk-HNWRQABR.js";import"./chunk-EUDKD2JW.js";var y=(a,e)=>[a,e,"general"],U=(a,e)=>[a,e,"destination"],K=(a,e)=>[a,e,"source-data"],w=(a,e)=>[a,e,"schedule"],H=(a,e)=>[a,e,"options"];function X(a,e){if(a&1&&(s(0,"p"),A(1),u()),a&2){let t=R();n(),k("Editing: ",t.backupName())}}function x(a,e){a&1&&r(0,"sh-progress-bar",7)}function z(a,e){a&1&&(s(0,"section"),r(1,"router-outlet"),u())}var C=class a{#t=l(E);#e=l(T);#a=l(L);#i=l(v);isDraft=this.#e.isDraft;isNew=this.#e.isNew;backupId=this.#e.backupId;backupName=this.#e.backupName;finishedLoading=this.#e.finishedLoading;#o=m(this.#t.params);#n=m(this.#t.url);paramsChanged=O(()=>{let e=this.#o()?.id,t=!!this.#n()?.find(i=>i.path==="backup-draft");this.#e.backupId.set(e),e!=="new"?this.getBackup(e,t):this.getDefaults()});getDefaults(){this.#i.getApiV1Backupdefaults().pipe(f(1)).subscribe({next:e=>{let t=e.Backup;t.Settings=[...t.Settings],this.#e.mapGeneralToForm(t),this.#e.mapDestinationToForm(t),this.#e.mapSourceDataToForm(t),this.#e.mapScheduleToForm(e.Schedule),this.#e.mapOptionsToForms(t),this.#e.applicationOptions.set(e.ApplicationOptions),this.#e.backupDefaults.set(e),this.#e.finishedLoading.set(!0)}})}getBackup(e,t=!1){let i=o=>{this.#e.mapScheduleToForm(o.Schedule??null),o.Backup&&(this.#e.mapGeneralToForm(o.Backup),this.#e.mapDestinationToForm(o.Backup),this.#e.mapSourceDataToForm(o.Backup),this.#e.mapOptionsToForms(o.Backup),this.#e.storeMetadata(o.Backup,t)),this.#e.finishedLoading.set(!0)};if(t){this.isDraft.set(t);let o=this.#a.draftBackups().find(F=>F.id===e);if(!o){alert("Backup not found");return}i(o.data)}else this.#i.getApiV1BackupById({id:e}).subscribe({next:i})}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=D({type:a,selectors:[["app-backup"]],features:[P([T])],decls:21,vars:22,consts:()=>{let e;e=$localize`${"\uFFFD#6\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#6\uFFFD"}:CLOSE_TAG_SH_RADIO: General `;let t;t=$localize`${"\uFFFD#9\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SH_RADIO: Destination `;let i;i=$localize`${"\uFFFD#12\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SH_RADIO: Source Data `;let o;o=$localize`${"\uFFFD#15\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#15\uFFFD"}:CLOSE_TAG_SH_RADIO: Schedule `;let F;return F=$localize`${"\uFFFD#18\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#18\uFFFD"}:CLOSE_TAG_SH_RADIO: Options `,[e,t,i,o,F,[1,"primary"],["step","","routerLinkActive","active",3,"routerLink"],[1,"indeterminate","primary"]]},template:function(t,i){t&1&&(r(0,"app-status-bar"),s(1,"header"),h(2,X,2,1,"p"),s(3,"sh-stepper",5)(4,"div",6),c(5,0),r(6,"sh-radio"),p(),u(),s(7,"div",6),c(8,1),r(9,"sh-radio"),p(),u(),s(10,"div",6),c(11,2),r(12,"sh-radio"),p(),u(),s(13,"div",6),c(14,3),r(15,"sh-radio"),p(),u(),s(16,"div",6),c(17,4),r(18,"sh-radio"),p(),u()()(),h(19,x,1,0,"sh-progress-bar",7)(20,z,2,0,"section")),t&2&&(n(2),g(i.isNew()?-1:2),n(2),d("routerLink",_(7,y,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),d("routerLink",_(10,U,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),d("routerLink",_(13,K,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),d("routerLink",_(16,w,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),d("routerLink",_(19,H,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),g(i.finishedLoading()?20:19))},dependencies:[B,b,M,G,N,I,$],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;height:100%}header[_ngcontent-%COMP%]{padding:1rem 1.5rem;border-bottom:1px solid var(--base-4)}header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin-bottom:.5rem}header[_ngcontent-%COMP%] sh-stepper[_ngcontent-%COMP%]{width:100%}section[_ngcontent-%COMP%]{width:100%;display:flex;justify-content:center;flex:1 0;overflow-x:hidden;overflow-y:auto;-webkit-overflow-scrolling:auto}"],changeDetection:0})};export{C as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as g}from"./chunk-
|
|
1
|
+
import{b as g}from"./chunk-O64ZZGQZ.js";import{h as o}from"./chunk-NOPMCS2Z.js";import{Oc as n,V as r,_ as i,oa as s}from"./chunk-HNWRQABR.js";var v=class e{#e=i(o);#r=g(this.#e.getApiV1Serversettings());#t=s(void 0);serverSettings=n(()=>this.#t()||this.#r());refreshServerSettings(){this.#e.getApiV1Serversettings().subscribe({next:t=>{this.#t.set(t)}})}static \u0275fac=function(a){return new(a||e)};static \u0275prov=r({token:e,factory:e.\u0275fac,providedIn:"root"})};export{v as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a,b,c}from"./chunk-MSLKIHQQ.js";import"./chunk-N6ABN43N.js";import"./chunk-DDWLL7XA.js";import"./chunk-2QJC4PGQ.js";import"./chunk-O64ZZGQZ.js";import"./chunk-DELLEGXW.js";import"./chunk-RHW5QVAY.js";import"./chunk-VTSUHAP5.js";import"./chunk-N5SC4SKW.js";import"./chunk-LVP2TPMO.js";import"./chunk-43JMN2ZY.js";import"./chunk-H7K35UUX.js";import"./chunk-NOPMCS2Z.js";import"./chunk-RUXCS4ZK.js";import"./chunk-FPPZ4BUR.js";import"./chunk-HNWRQABR.js";import"./chunk-EUDKD2JW.js";export{b as NONE_OPTION,a as createGeneralForm,c as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as Re,b as $e}from"./chunk-FFY3NRCC.js";import{a as ve}from"./chunk-JA7OQSO3.js";import{a as k}from"./chunk-BGUKMOKY.js";import"./chunk-XNVRJH42.js";import{a as Ee}from"./chunk-3UN32GIC.js";import"./chunk-OXOOR7I4.js";import"./chunk-GUH5TMOS.js";import"./chunk-RHW5QVAY.js";import"./chunk-66BSPEOQ.js";import"./chunk-CWBEE627.js";import{a as Le}from"./chunk-7AMBMWZP.js";import{c as fe,d as Oe,e as Pe,i as De,r as Ne,s as Me,t as Ie}from"./chunk-USU2EHJV.js";import"./chunk-ZGAC2JKG.js";import{b as pe,d as Te}from"./chunk-ETCRT3EV.js";import{c as ce,e as ue,f as de}from"./chunk-L2EO4M4B.js";import"./chunk-4YL5DZVH.js";import{C as Ce,a as I,b as G,c as Se,e as ge,g as w,k as he,l as Fe,n as me,u as Ae}from"./chunk-WRNQOX5R.js";import{h as x}from"./chunk-J3BBLPAD.js";import"./chunk-WJPLJKPQ.js";import"./chunk-FPPZ4BUR.js";import{Ab as s,Bb as i,Cb as l,H as V,Jb as E,Oc as re,Pc as Q,Qb as u,Ra as r,Rb as d,Sb as O,Tc as le,Vb as $,Vc as _e,Wb as g,Xc as K,Yb as c,_ as F,bb as M,ea as m,ec as ne,fa as A,fc as oe,ic as H,kc as v,lc as h,mc as X,nc as z,oa as T,qc as W,rc as q,sc as j,tc as ie,ub as p,uc as se,vb as S,vc as b,wb as Z,xb as ee,yb as te,zb as P,zc as ae}from"./chunk-QDFCX6XE.js";import{a as B,b as Y}from"./chunk-EUDKD2JW.js";var Ge=["scroller"];function we(n,o){n&1&&(s(0,"sh-icon"),h(1,"bell-ringing"),i())}function xe(n,o){n&1&&(s(0,"sh-icon"),h(1,"bell"),i())}function ke(n,o){if(n&1&&l(0,"app-notification",8),n&2){c(2);let e=b(6);P("index",0)("notification",e.content)}}function Ue(n,o){if(n&1&&(s(0,"div",11),h(1),i()),n&2){c(3);let e=b(6);r(),z(" ",e.content.content," ")}}function Be(n,o){if(n&1&&(s(0,"sh-alert")(1,"div",10),h(2),i(),p(3,Ue,2,1,"div",11),i()),n&2){c(2);let e=b(6);v(e.content.type||"error"),r(2),X(e.content.title),r(),S(e.content.content?3:-1)}}function Ye(n,o){if(n&1&&(s(0,"div",6),p(1,ke,1,2,"app-notification",8)(2,Be,4,4,"sh-alert",9),i()),n&2){c();let e=b(6);r(),S(e.type==="notification"?1:2)}}function Ve(n,o){if(n&1){let e=E();s(0,"div",7)(1,"div",12)(2,"h6",13),u(3,2),s(4,"button",5),g("click",function(){m(e);let a=c();return A(a.toggleNotifications())}),l(5,"sh-icon"),i(),d(),i(),s(6,"div",14,0)(8,"div",15),l(9,"app-notifications"),i()()()()}}function Xe(n,o){if(n&1&&(s(0,"div",20),h(1),i()),n&2){let e=c().$implicit;r(),z(" ",e.content," ")}}function ze(n,o){if(n&1){let e=E();s(0,"sh-alert",18,1),g("click",function(){let a=m(e).$implicit,_=c(2);return A(_.deleteAlertByIndex(a.id))}),s(2,"div",19),h(3),i(),p(4,Xe,2,1,"div",20),i()}if(n&2){let e=o.$implicit;v(e.type),P("id",e.id),r(3),X(e.title),r(),S(e.content?4:-1)}}function We(n,o){n&1&&(s(0,"p",17),O(1,4),i())}function qe(n,o){if(n&1){let e=E();s(0,"div",7)(1,"div",12)(2,"h6",13),u(3,3),s(4,"button",5),g("click",function(){m(e);let a=c();return A(a.toggleAlerts())}),l(5,"sh-icon"),i(),d(),i(),s(6,"div",14,0)(8,"div",15),ee(9,ze,5,5,"sh-alert",16,Z,!1,We,2,0,"p",17),i()()()()}if(n&2){let e=c();r(9),te(e.alertHistory())}}var be=new Ne,y=class n{#e=F(Se);#t=F(k);isSubmitting=T(!1);messageSent=T(!1);form=be.group({message:be.control("",[Oe.required])});notifications=this.#t.notifications;shownMessage=T(null);shownMessageInterval=null;alertHistory=this.#e.alertHistory;alertHistoryIsOpen=this.#e.alertHistoryIsOpen;alertHistoryIsHidden=this.#e.alertHistoryIsHidden;numberOfOpenAlerts=re(()=>this.alertHistory().filter(o=>o.isOpen).length);scroller=_e("scroller");isAlertsOpen=K(!1);isNotificationsOpen=K(!1);previousHistoryCount=T(null);previousNotificationsCount=T(null);constructor(){Q(()=>{let o=this.alertHistory(),e=this.notifications();if(e.length===0){this.shownMessage.set(null);return}e.length&&this.previousHistoryCount()!==o.length&&!this.isNotificationsOpen()?(this.shownMessage.set({content:e[0],countDown:3,type:"notification"}),this.previousHistoryCount.set(o.length),this.shownMessageInterval=setInterval(()=>{let t=this.shownMessage();if(t?.countDown===0){this.shownMessage.set(null),this.shownMessageInterval=null;return}t!==null&&this.shownMessage.update(a=>Y(B({},a),{countDown:a.countDown-1}))},1e3)):o.length&&this.previousHistoryCount()!==o.length&&!this.isAlertsOpen()&&(this.shownMessage.set({content:o[0],countDown:3,type:"alert"}),this.previousHistoryCount.set(o.length),this.shownMessageInterval=setInterval(()=>{let t=this.shownMessage();if(t?.countDown===0){this.shownMessage.set(null),this.shownMessageInterval=null;return}t!==null&&this.shownMessage.update(a=>Y(B({},a),{countDown:a.countDown-1}))},1e3))}),Q(()=>{this.alertHistoryIsOpen(),this.scrollToBottom()})}resetPreviewMessage(){this.shownMessage.set(null),this.shownMessageInterval=null}toggleAlerts(){this.isAlertsOpen()?this.isAlertsOpen.set(!1):(this.isAlertsOpen.set(!0),this.isNotificationsOpen.set(!1),this.resetPreviewMessage())}toggleNotifications(){this.isNotificationsOpen.set(!this.isNotificationsOpen()),this.isAlertsOpen()&&this.isAlertsOpen.set(!1)}deleteAlertByIndex(o){this.#e.removeAlert(o)}scrollToBottom(){this.scroller()&&this.scroller()?.nativeElement&&this.scroller().nativeElement.scrollTo(0,this.scroller().nativeElement.scrollHeight)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=M({type:n,selectors:[["app-service-hub"]],viewQuery:function(e,t){e&1&&ne(t.scroller,Ge,5),e&2&&oe()},inputs:{isAlertsOpen:[1,"isAlertsOpen"],isNotificationsOpen:[1,"isNotificationsOpen"]},outputs:{isAlertsOpen:"isAlertsOpenChange",isNotificationsOpen:"isNotificationsOpenChange"},decls:10,vars:9,consts:()=>{let o;o=$localize` Notifications ${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:x-circle${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_BUTTON:`;let e;e=$localize` Alerts ${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:x-circle${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_BUTTON:`;let t;return t=$localize`No alerts yet`,[["scroller",""],["alerts",""],o,e,t,["shButton","",3,"click"],[1,"preview-alert-wrap"],[1,"alert-stream-modal"],[3,"index","notification"],[3,"class"],["ship-alert-title",""],["ship-alert-content",""],[1,"alert-stream-modal-content"],[1,"paragraph-20"],[1,"alert-stream-modal-list-scroller"],[1,"alert-stream-modal-list"],[3,"class","id"],[1,"no-alerts"],[3,"click","id"],["title",""],["content",""]]},template:function(e,t){if(e&1){let a=E();s(0,"button",5),g("click",function(){return m(a),A(t.toggleAlerts())}),s(1,"sh-icon"),h(2,"info"),i()(),s(3,"button",5),g("click",function(){return m(a),A(t.toggleNotifications())}),p(4,we,2,0,"sh-icon")(5,xe,2,0,"sh-icon"),i(),ie(6),p(7,Ye,3,1,"div",6),p(8,Ve,10,0,"div",7),p(9,qe,12,1,"div",7)}if(e&2){v(t.alertHistory().length?"error":""),r(3),v(t.notifications().length?"error":""),r(),S(t.notifications().length?4:5),r(2);let a=se(t.shownMessage());r(),S(a?7:-1),r(),S(t.isNotificationsOpen()?8:-1),r(),S(t.isAlertsOpen()?9:-1)}},dependencies:[Ie,G,I,w,$e,Re],styles:["[_nghost-%COMP%]{display:flex;position:fixed;gap:.5rem;bottom:1.5rem;right:1.5rem;z-index:5000}@media only screen and (max-width: 768px){[_nghost-%COMP%]{bottom:1rem;right:1rem}}[_nghost-%COMP%] h6[_ngcontent-%COMP%]{margin:0}.preview-alert-wrap[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column;min-width:15.625rem}.helpdesk-modal[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column}@media only screen and (max-width: 768px){.helpdesk-modal[_ngcontent-%COMP%]{bottom:2.6875rem}}.helpdesk-modal-content[_ngcontent-%COMP%]{position:relative;display:flex;flex-direction:column;gap:1rem;min-width:20rem;border:1px solid var(--base-4);background-color:var(--base-1);border-radius:var(--shape-2)}.helpdesk-modal-content[_ngcontent-%COMP%] .message-sent[_ngcontent-%COMP%]{padding:0 1rem 1rem;text-wrap:pretty}.helpdesk-modal-content[_ngcontent-%COMP%] h6[_ngcontent-%COMP%]{padding:1rem;border-bottom:1px solid var(--base-4);display:flex;align-items:center;justify-content:space-between}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%]{padding:0 1rem 1rem;display:flex;flex-direction:column;align-items:flex-end;gap:1rem}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{width:100%;text-wrap:pretty}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%] mat-form-field[_ngcontent-%COMP%]{width:100%}.alert-stream-modal[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column}@media only screen and (max-width: 768px){.alert-stream-modal[_ngcontent-%COMP%]{bottom:2.6875rem}}.alert-stream-modal-list-scroller[_ngcontent-%COMP%]{overflow-y:auto;max-height:18.75rem}.alert-stream-modal-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem;padding:1rem;border-radius:var(--shape-2)}.alert-stream-modal-content[_ngcontent-%COMP%]{position:relative;display:flex;flex-direction:column;min-width:20rem;border:1px solid var(--base-4);background-color:var(--base-1);border-radius:var(--shape-2)}.alert-stream-modal-content[_ngcontent-%COMP%] h6[_ngcontent-%COMP%]{padding:1rem;border-bottom:1px solid var(--base-4);display:flex;align-items:center;justify-content:space-between}.no-alerts[_ngcontent-%COMP%]{padding:1rem;display:flex;flex-direction:column;gap:1rem;text-align:center}"],changeDetection:0})};function je(n,o){n&1&&(s(0,"sh-icon",14),h(1,"check"),i())}function Qe(n,o){n&1&&(s(0,"sh-icon",15),h(1,"prohibit"),i())}function Ke(n,o){if(n&1){let e=E();s(0,"button",20),g("click",function(){m(e);let a=c();return A(a.updatePassphrase())}),O(1,5),i()}if(n&2){let e=c();H("loader",e.isUpdating())}}function Je(n,o){if(n&1){let e=E();s(0,"button",21),g("click",function(){m(e);let a=c();return A(a.updatePassphrase())}),O(1,6),i()}if(n&2){let e=c();H("loader",e.isUpdating()),P("disabled",!0)}}var U=class n{#e=F(x);closed=le();isUpdating=T(!1);passphrase=T("");repeatPassphrase=T("");updatePassphrase(){this.passphrase()===this.repeatPassphrase()&&(this.isUpdating.set(!0),this.#e.patchApiV1Serversettings({requestBody:{"server-passphrase":this.passphrase()}}).pipe(V(()=>this.isUpdating.set(!1))).subscribe({next:()=>this.closed.emit()}))}cancel(){this.isUpdating.set(!0),this.#e.patchApiV1Serversettings({requestBody:{"has-asked-for-password-change":"True"}}).pipe(V(()=>this.isUpdating.set(!1))).subscribe({next:()=>this.closed.emit()})}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=M({type:n,selectors:[["app-change-passphrase-alert-dialog"]],outputs:{closed:"closed"},decls:23,vars:7,consts:()=>{let o;o=$localize`Enter new password`;let e;e=$localize`Repeat password`;let t;t=$localize`Password have to be filled and have to match`;let a;a=$localize`Change passphrase`;let _;_=$localize` Duplicati needs to be secured with a passphrase and a random passphrase has been generated for you. ${"[\uFFFD#6\uFFFD\uFFFD/#6\uFFFD|\uFFFD#7\uFFFD\uFFFD/#7\uFFFD]"}:LINE_BREAK:${"[\uFFFD#6\uFFFD\uFFFD/#6\uFFFD|\uFFFD#7\uFFFD\uFFFD/#7\uFFFD]"}:LINE_BREAK: If you open Duplicati from the tray icon, you do not need a passphrase, but if you plan to open it from another location you need to set a passphrase you know. Do you want to set a passphrase now? `,_=$(_);let D;D=$localize`Passphrase`;let N;N=$localize`Repeat passphrase`;let L;L=$localize`Not now thanks`;let R;R=$localize` Yes, update passphrase now `;let C;return C=$localize` Yes, update passphrase now `,[a,_,D,N,L,R,C,["header",""],["content",""],["type","warning"],["for","password"],["type","password","name","password","autocomplete","disabled","placeholder",o,"tabindex","1",3,"ngModelChange","ngModel"],["for","repeatPassword"],["type","password","name","repeatPassword","autocomplete","disabled","placeholder",e,"tabindex","2",3,"ngModelChange","disabled","ngModel"],["suffix","",1,"sh-success"],["suffix",""],["footer",""],["shButton","",3,"click"],["shButton","",1,"raised","primary",3,"loader"],["shButton","","shTooltip",t,1,"raised","primary",3,"loader","disabled"],["shButton","",1,"raised","primary",3,"click"],["shButton","","shTooltip",t,1,"raised","primary",3,"click","disabled"]]},template:function(e,t){e&1&&(s(0,"header",7)(1,"h3"),O(2,0),i()(),s(3,"div",8)(4,"sh-alert",9),u(5,1),l(6,"br")(7,"br"),d(),i(),s(8,"sh-form-field")(9,"label",10),O(10,2),i(),s(11,"input",11),j("ngModelChange",function(_){return q(t.passphrase,_)||(t.passphrase=_),_}),i()(),s(12,"sh-form-field")(13,"label",12),O(14,3),i(),s(15,"input",13),j("ngModelChange",function(_){return q(t.repeatPassphrase,_)||(t.repeatPassphrase=_),_}),i(),p(16,je,2,0,"sh-icon",14)(17,Qe,2,0,"sh-icon",15),i()(),s(18,"footer",16)(19,"button",17),g("click",function(){return t.cancel()}),O(20,4),i(),p(21,Ke,2,2,"button",18)(22,Je,2,3,"button",19),i()),e&2&&(r(11),W("ngModel",t.passphrase),r(4),P("disabled",t.passphrase().length===0),W("ngModel",t.repeatPassphrase),r(),S(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?16:17),r(3),H("loader",t.isUpdating()),r(2),S(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?21:22))},dependencies:[Me,fe,Pe,De,G,Fe,I,Ce],styles:["[_nghost-%COMP%]{display:block;--dialog-p: 1.5rem}[content][_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}"],changeDetection:0})};var Ze=()=>({exact:!0});function et(n,o){n&1&&(s(0,"sh-icon"),h(1,"sun"),i())}function tt(n,o){n&1&&(s(0,"sh-icon"),h(1,"moon"),i())}function nt(n,o){if(n&1){let e=E();s(0,"button",22),g("click",function(){m(e);let a=c();return A(a.changeDefaultClientTo("ngax"))}),u(1,7),l(2,"sh-icon"),d(),i(),s(3,"button",22),g("click",function(){m(e);let a=c();return A(a.logout())}),u(4,8),l(5,"sh-icon"),d(),i()}}var J=class n{#e=F(ve);#t=F(x);#n=F(Ee);#o=F(pe);#i=F(ge);#s=F(k);#a=F(Te);relayIsEnabled=this.#o.relayIsEnabled;isDarkMode=this.#e.isDarkMode;ngOnInit(){return this.#s.init(),this.#n.getBackups(!0),this.#t.getApiV1Serversettings().subscribe({next:o=>{let e=o["autogenerated-passphrase"]==="True",t=o["has-asked-for-password-change"]==="True";e&&!t&&this.#i.open(U,{maxWidth:"500px"})}})}toggleBodyClass(){this.#e.toggleBodyClass()}changeDefaultClientTo(o){this.#r(o),window.location.replace(`/${o}`)}logout(){this.#a.logout()}#r(o){var e=new Date;e.setTime(e.getTime()+90*24*60*60*1e3),document.cookie="default-client="+o+"; expires="+e.toUTCString()+"; path=/"}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=M({type:n,selectors:[["app-layout"]],decls:37,vars:4,consts:()=>{let o;o=$localize`${"\uFFFD#10\uFFFD"}:START_TAG_SH_ICON:house${"\uFFFD/#10\uFFFD"}:CLOSE_TAG_SH_ICON: Home `;let e;e=$localize`${"\uFFFD#13\uFFFD"}:START_TAG_SH_ICON:database${"\uFFFD/#13\uFFFD"}:CLOSE_TAG_SH_ICON: Add backup `;let t;t=$localize`${"\uFFFD#16\uFFFD"}:START_TAG_SH_ICON:clock-counter-clockwise${"\uFFFD/#16\uFFFD"}:CLOSE_TAG_SH_ICON: Restore `;let a;a=$localize`${"\uFFFD#19\uFFFD"}:START_TAG_SH_ICON:gear${"\uFFFD/#19\uFFFD"}:CLOSE_TAG_SH_ICON: Settings `;let _;_=$localize`${"\uFFFD#26\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#26\uFFFD"}:CLOSE_TAG_SH_ICON: About Duplicati `;let D;D=$localize`${"\uFFFD#29\uFFFD"}:START_TAG_SH_ICON:files${"[\uFFFD/#29\uFFFD|\uFFFD/#30\uFFFD]"}:CLOSE_TAG_SH_ICON: Documentation ${"\uFFFD#30\uFFFD"}:START_TAG_SH_ICON_1:arrow-square-out${"[\uFFFD/#29\uFFFD|\uFFFD/#30\uFFFD]"}:CLOSE_TAG_SH_ICON:`,D=$(D);let N;N=$localize`${"\uFFFD#33\uFFFD"}:START_TAG_SH_ICON:chats-circle${"[\uFFFD/#33\uFFFD|\uFFFD/#34\uFFFD]"}:CLOSE_TAG_SH_ICON: Visit forum ${"\uFFFD#34\uFFFD"}:START_TAG_SH_ICON_1:arrow-square-out${"[\uFFFD/#33\uFFFD|\uFFFD/#34\uFFFD]"}:CLOSE_TAG_SH_ICON:`,N=$(N);let L;L=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:skip-back${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Use old UI `;let R;return R=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:sign-out${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON: Log out `,[o,e,t,a,_,D,N,L,R,["sidenav",""],["shButton","",1,"icon","small",3,"click"],[1,"base-1","primary"],["action","","routerLink","/","routerLinkActive","active",3,"routerLinkActiveOptions"],["action","","routerLink","/add-backup","routerLinkActive","active"],["action","","routerLink","/restore","routerLinkActive","active"],["action","","routerLink","/settings","routerLinkActive","active"],[1,"spacer"],[1,"base-1l","primary"],["action","","routerLink","/about","routerLinkActive","active"],["href","https://docs.duplicati.com","target","_blank","action",""],["suffix",""],["href","https://forum.duplicati.com","target","_blank","action",""],["action","",3,"click"]]},template:function(e,t){e&1&&(s(0,"sh-sidenav")(1,"div",9)(2,"header"),l(3,"app-logo"),s(4,"button",10),g("click",function(){return t.toggleBodyClass()}),p(5,et,2,0,"sh-icon")(6,tt,2,0,"sh-icon"),i()(),s(7,"sh-list",11)(8,"button",12),u(9,0),l(10,"sh-icon"),d(),i(),s(11,"button",13),u(12,1),l(13,"sh-icon"),d(),i(),s(14,"button",14),u(15,2),l(16,"sh-icon"),d(),i(),s(17,"button",15),u(18,3),l(19,"sh-icon"),d(),i()(),l(20,"div",16),s(21,"sh-list",17),p(22,nt,6,0),l(23,"sh-divider"),s(24,"button",18),u(25,4),l(26,"sh-icon"),d(),i(),s(27,"a",19),u(28,5),l(29,"sh-icon")(30,"sh-icon",20),d(),i(),s(31,"a",21),u(32,6),l(33,"sh-icon")(34,"sh-icon",20),d(),i()()(),l(35,"router-outlet")(36,"app-service-hub"),i()),e&2&&(r(5),S(t.isDarkMode()?5:6),r(3),P("routerLinkActiveOptions",ae(3,Ze)),r(14),S(t.relayIsEnabled()?-1:22))},dependencies:[ce,ue,de,Ae,I,me,w,he,y,Le],styles:["[_nghost-%COMP%]{height:100vh;width:100%;overflow:hidden}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:1.25rem;gap:.75rem}h3[title][_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between}div[sidenav][_ngcontent-%COMP%]{display:flex;flex-direction:column;height:100vh}"],changeDetection:0})};export{J as default};
|
|
1
|
+
import{a as Re,b as $e}from"./chunk-DNDTLTUM.js";import{a as ve}from"./chunk-EBIM5FBM.js";import{a as k}from"./chunk-QDFDQHU3.js";import"./chunk-6LTGTS6B.js";import{a as Ee}from"./chunk-DVDTYV66.js";import"./chunk-UIJYCGKA.js";import"./chunk-DELLEGXW.js";import"./chunk-RHW5QVAY.js";import"./chunk-VTSUHAP5.js";import"./chunk-UP5EOICU.js";import{a as Le}from"./chunk-QHC3CY43.js";import{c as fe,d as Oe,e as Pe,i as De,r as Ne,s as Me,t as Ie}from"./chunk-N5SC4SKW.js";import"./chunk-Z3EPZZGY.js";import{b as pe,d as Te}from"./chunk-UKQFDBNO.js";import{c as ce,e as ue,f as de}from"./chunk-LVP2TPMO.js";import"./chunk-43JMN2ZY.js";import{C as Ce,a as I,b as G,c as Se,e as ge,g as w,k as he,l as Fe,n as me,u as Ae}from"./chunk-H7K35UUX.js";import{h as x}from"./chunk-NOPMCS2Z.js";import"./chunk-RUXCS4ZK.js";import"./chunk-FPPZ4BUR.js";import{Ab as s,Bb as i,Cb as l,H as V,Jb as E,Oc as re,Pc as Q,Qb as u,Ra as r,Rb as d,Sb as O,Tc as le,Vb as $,Vc as _e,Wb as g,Xc as K,Yb as c,_ as F,bb as M,ea as m,ec as ne,fa as A,fc as oe,ic as H,kc as v,lc as h,mc as X,nc as z,oa as T,qc as W,rc as q,sc as j,tc as ie,ub as p,uc as se,vb as S,vc as b,wb as Z,xb as ee,yb as te,zb as P,zc as ae}from"./chunk-HNWRQABR.js";import{a as B,b as Y}from"./chunk-EUDKD2JW.js";var Ge=["scroller"];function we(n,o){n&1&&(s(0,"sh-icon"),h(1,"bell-ringing"),i())}function xe(n,o){n&1&&(s(0,"sh-icon"),h(1,"bell"),i())}function ke(n,o){if(n&1&&l(0,"app-notification",8),n&2){c(2);let e=b(6);P("index",0)("notification",e.content)}}function Ue(n,o){if(n&1&&(s(0,"div",11),h(1),i()),n&2){c(3);let e=b(6);r(),z(" ",e.content.content," ")}}function Be(n,o){if(n&1&&(s(0,"sh-alert")(1,"div",10),h(2),i(),p(3,Ue,2,1,"div",11),i()),n&2){c(2);let e=b(6);v(e.content.type||"error"),r(2),X(e.content.title),r(),S(e.content.content?3:-1)}}function Ye(n,o){if(n&1&&(s(0,"div",6),p(1,ke,1,2,"app-notification",8)(2,Be,4,4,"sh-alert",9),i()),n&2){c();let e=b(6);r(),S(e.type==="notification"?1:2)}}function Ve(n,o){if(n&1){let e=E();s(0,"div",7)(1,"div",12)(2,"h6",13),u(3,2),s(4,"button",5),g("click",function(){m(e);let a=c();return A(a.toggleNotifications())}),l(5,"sh-icon"),i(),d(),i(),s(6,"div",14,0)(8,"div",15),l(9,"app-notifications"),i()()()()}}function Xe(n,o){if(n&1&&(s(0,"div",20),h(1),i()),n&2){let e=c().$implicit;r(),z(" ",e.content," ")}}function ze(n,o){if(n&1){let e=E();s(0,"sh-alert",18,1),g("click",function(){let a=m(e).$implicit,_=c(2);return A(_.deleteAlertByIndex(a.id))}),s(2,"div",19),h(3),i(),p(4,Xe,2,1,"div",20),i()}if(n&2){let e=o.$implicit;v(e.type),P("id",e.id),r(3),X(e.title),r(),S(e.content?4:-1)}}function We(n,o){n&1&&(s(0,"p",17),O(1,4),i())}function qe(n,o){if(n&1){let e=E();s(0,"div",7)(1,"div",12)(2,"h6",13),u(3,3),s(4,"button",5),g("click",function(){m(e);let a=c();return A(a.toggleAlerts())}),l(5,"sh-icon"),i(),d(),i(),s(6,"div",14,0)(8,"div",15),ee(9,ze,5,5,"sh-alert",16,Z,!1,We,2,0,"p",17),i()()()()}if(n&2){let e=c();r(9),te(e.alertHistory())}}var be=new Ne,y=class n{#e=F(Se);#t=F(k);isSubmitting=T(!1);messageSent=T(!1);form=be.group({message:be.control("",[Oe.required])});notifications=this.#t.notifications;shownMessage=T(null);shownMessageInterval=null;alertHistory=this.#e.alertHistory;alertHistoryIsOpen=this.#e.alertHistoryIsOpen;alertHistoryIsHidden=this.#e.alertHistoryIsHidden;numberOfOpenAlerts=re(()=>this.alertHistory().filter(o=>o.isOpen).length);scroller=_e("scroller");isAlertsOpen=K(!1);isNotificationsOpen=K(!1);previousHistoryCount=T(null);previousNotificationsCount=T(null);constructor(){Q(()=>{let o=this.alertHistory(),e=this.notifications();if(e.length===0){this.shownMessage.set(null);return}e.length&&this.previousHistoryCount()!==o.length&&!this.isNotificationsOpen()?(this.shownMessage.set({content:e[0],countDown:3,type:"notification"}),this.previousHistoryCount.set(o.length),this.shownMessageInterval=setInterval(()=>{let t=this.shownMessage();if(t?.countDown===0){this.shownMessage.set(null),this.shownMessageInterval=null;return}t!==null&&this.shownMessage.update(a=>Y(B({},a),{countDown:a.countDown-1}))},1e3)):o.length&&this.previousHistoryCount()!==o.length&&!this.isAlertsOpen()&&(this.shownMessage.set({content:o[0],countDown:3,type:"alert"}),this.previousHistoryCount.set(o.length),this.shownMessageInterval=setInterval(()=>{let t=this.shownMessage();if(t?.countDown===0){this.shownMessage.set(null),this.shownMessageInterval=null;return}t!==null&&this.shownMessage.update(a=>Y(B({},a),{countDown:a.countDown-1}))},1e3))}),Q(()=>{this.alertHistoryIsOpen(),this.scrollToBottom()})}resetPreviewMessage(){this.shownMessage.set(null),this.shownMessageInterval=null}toggleAlerts(){this.isAlertsOpen()?this.isAlertsOpen.set(!1):(this.isAlertsOpen.set(!0),this.isNotificationsOpen.set(!1),this.resetPreviewMessage())}toggleNotifications(){this.isNotificationsOpen.set(!this.isNotificationsOpen()),this.isAlertsOpen()&&this.isAlertsOpen.set(!1)}deleteAlertByIndex(o){this.#e.removeAlert(o)}scrollToBottom(){this.scroller()&&this.scroller()?.nativeElement&&this.scroller().nativeElement.scrollTo(0,this.scroller().nativeElement.scrollHeight)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=M({type:n,selectors:[["app-service-hub"]],viewQuery:function(e,t){e&1&&ne(t.scroller,Ge,5),e&2&&oe()},inputs:{isAlertsOpen:[1,"isAlertsOpen"],isNotificationsOpen:[1,"isNotificationsOpen"]},outputs:{isAlertsOpen:"isAlertsOpenChange",isNotificationsOpen:"isNotificationsOpenChange"},decls:10,vars:9,consts:()=>{let o;o=$localize` Notifications ${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:x-circle${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_BUTTON:`;let e;e=$localize` Alerts ${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:x-circle${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_BUTTON:`;let t;return t=$localize`No alerts yet`,[["scroller",""],["alerts",""],o,e,t,["shButton","",3,"click"],[1,"preview-alert-wrap"],[1,"alert-stream-modal"],[3,"index","notification"],[3,"class"],["ship-alert-title",""],["ship-alert-content",""],[1,"alert-stream-modal-content"],[1,"paragraph-20"],[1,"alert-stream-modal-list-scroller"],[1,"alert-stream-modal-list"],[3,"class","id"],[1,"no-alerts"],[3,"click","id"],["title",""],["content",""]]},template:function(e,t){if(e&1){let a=E();s(0,"button",5),g("click",function(){return m(a),A(t.toggleAlerts())}),s(1,"sh-icon"),h(2,"info"),i()(),s(3,"button",5),g("click",function(){return m(a),A(t.toggleNotifications())}),p(4,we,2,0,"sh-icon")(5,xe,2,0,"sh-icon"),i(),ie(6),p(7,Ye,3,1,"div",6),p(8,Ve,10,0,"div",7),p(9,qe,12,1,"div",7)}if(e&2){v(t.alertHistory().length?"error":""),r(3),v(t.notifications().length?"error":""),r(),S(t.notifications().length?4:5),r(2);let a=se(t.shownMessage());r(),S(a?7:-1),r(),S(t.isNotificationsOpen()?8:-1),r(),S(t.isAlertsOpen()?9:-1)}},dependencies:[Ie,G,I,w,$e,Re],styles:["[_nghost-%COMP%]{display:flex;position:fixed;gap:.5rem;bottom:1.5rem;right:1.5rem;z-index:5000}@media only screen and (max-width: 768px){[_nghost-%COMP%]{bottom:1rem;right:1rem}}[_nghost-%COMP%] h6[_ngcontent-%COMP%]{margin:0}.preview-alert-wrap[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column;min-width:15.625rem}.helpdesk-modal[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column}@media only screen and (max-width: 768px){.helpdesk-modal[_ngcontent-%COMP%]{bottom:2.6875rem}}.helpdesk-modal-content[_ngcontent-%COMP%]{position:relative;display:flex;flex-direction:column;gap:1rem;min-width:20rem;border:1px solid var(--base-4);background-color:var(--base-1);border-radius:var(--shape-2)}.helpdesk-modal-content[_ngcontent-%COMP%] .message-sent[_ngcontent-%COMP%]{padding:0 1rem 1rem;text-wrap:pretty}.helpdesk-modal-content[_ngcontent-%COMP%] h6[_ngcontent-%COMP%]{padding:1rem;border-bottom:1px solid var(--base-4);display:flex;align-items:center;justify-content:space-between}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%]{padding:0 1rem 1rem;display:flex;flex-direction:column;align-items:flex-end;gap:1rem}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{width:100%;text-wrap:pretty}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%] mat-form-field[_ngcontent-%COMP%]{width:100%}.alert-stream-modal[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column}@media only screen and (max-width: 768px){.alert-stream-modal[_ngcontent-%COMP%]{bottom:2.6875rem}}.alert-stream-modal-list-scroller[_ngcontent-%COMP%]{overflow-y:auto;max-height:18.75rem}.alert-stream-modal-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem;padding:1rem;border-radius:var(--shape-2)}.alert-stream-modal-content[_ngcontent-%COMP%]{position:relative;display:flex;flex-direction:column;min-width:20rem;border:1px solid var(--base-4);background-color:var(--base-1);border-radius:var(--shape-2)}.alert-stream-modal-content[_ngcontent-%COMP%] h6[_ngcontent-%COMP%]{padding:1rem;border-bottom:1px solid var(--base-4);display:flex;align-items:center;justify-content:space-between}.no-alerts[_ngcontent-%COMP%]{padding:1rem;display:flex;flex-direction:column;gap:1rem;text-align:center}"],changeDetection:0})};function je(n,o){n&1&&(s(0,"sh-icon",14),h(1,"check"),i())}function Qe(n,o){n&1&&(s(0,"sh-icon",15),h(1,"prohibit"),i())}function Ke(n,o){if(n&1){let e=E();s(0,"button",20),g("click",function(){m(e);let a=c();return A(a.updatePassphrase())}),O(1,5),i()}if(n&2){let e=c();H("loader",e.isUpdating())}}function Je(n,o){if(n&1){let e=E();s(0,"button",21),g("click",function(){m(e);let a=c();return A(a.updatePassphrase())}),O(1,6),i()}if(n&2){let e=c();H("loader",e.isUpdating()),P("disabled",!0)}}var U=class n{#e=F(x);closed=le();isUpdating=T(!1);passphrase=T("");repeatPassphrase=T("");updatePassphrase(){this.passphrase()===this.repeatPassphrase()&&(this.isUpdating.set(!0),this.#e.patchApiV1Serversettings({requestBody:{"server-passphrase":this.passphrase()}}).pipe(V(()=>this.isUpdating.set(!1))).subscribe({next:()=>this.closed.emit()}))}cancel(){this.isUpdating.set(!0),this.#e.patchApiV1Serversettings({requestBody:{"has-asked-for-password-change":"True"}}).pipe(V(()=>this.isUpdating.set(!1))).subscribe({next:()=>this.closed.emit()})}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=M({type:n,selectors:[["app-change-passphrase-alert-dialog"]],outputs:{closed:"closed"},decls:23,vars:7,consts:()=>{let o;o=$localize`Enter new password`;let e;e=$localize`Repeat password`;let t;t=$localize`Password have to be filled and have to match`;let a;a=$localize`Change passphrase`;let _;_=$localize` Duplicati needs to be secured with a passphrase and a random passphrase has been generated for you. ${"[\uFFFD#6\uFFFD\uFFFD/#6\uFFFD|\uFFFD#7\uFFFD\uFFFD/#7\uFFFD]"}:LINE_BREAK:${"[\uFFFD#6\uFFFD\uFFFD/#6\uFFFD|\uFFFD#7\uFFFD\uFFFD/#7\uFFFD]"}:LINE_BREAK: If you open Duplicati from the tray icon, you do not need a passphrase, but if you plan to open it from another location you need to set a passphrase you know. Do you want to set a passphrase now? `,_=$(_);let D;D=$localize`Passphrase`;let N;N=$localize`Repeat passphrase`;let L;L=$localize`Not now thanks`;let R;R=$localize` Yes, update passphrase now `;let C;return C=$localize` Yes, update passphrase now `,[a,_,D,N,L,R,C,["header",""],["content",""],["type","warning"],["for","password"],["type","password","name","password","autocomplete","disabled","placeholder",o,"tabindex","1",3,"ngModelChange","ngModel"],["for","repeatPassword"],["type","password","name","repeatPassword","autocomplete","disabled","placeholder",e,"tabindex","2",3,"ngModelChange","disabled","ngModel"],["suffix","",1,"sh-success"],["suffix",""],["footer",""],["shButton","",3,"click"],["shButton","",1,"raised","primary",3,"loader"],["shButton","","shTooltip",t,1,"raised","primary",3,"loader","disabled"],["shButton","",1,"raised","primary",3,"click"],["shButton","","shTooltip",t,1,"raised","primary",3,"click","disabled"]]},template:function(e,t){e&1&&(s(0,"header",7)(1,"h3"),O(2,0),i()(),s(3,"div",8)(4,"sh-alert",9),u(5,1),l(6,"br")(7,"br"),d(),i(),s(8,"sh-form-field")(9,"label",10),O(10,2),i(),s(11,"input",11),j("ngModelChange",function(_){return q(t.passphrase,_)||(t.passphrase=_),_}),i()(),s(12,"sh-form-field")(13,"label",12),O(14,3),i(),s(15,"input",13),j("ngModelChange",function(_){return q(t.repeatPassphrase,_)||(t.repeatPassphrase=_),_}),i(),p(16,je,2,0,"sh-icon",14)(17,Qe,2,0,"sh-icon",15),i()(),s(18,"footer",16)(19,"button",17),g("click",function(){return t.cancel()}),O(20,4),i(),p(21,Ke,2,2,"button",18)(22,Je,2,3,"button",19),i()),e&2&&(r(11),W("ngModel",t.passphrase),r(4),P("disabled",t.passphrase().length===0),W("ngModel",t.repeatPassphrase),r(),S(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?16:17),r(3),H("loader",t.isUpdating()),r(2),S(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?21:22))},dependencies:[Me,fe,Pe,De,G,Fe,I,Ce],styles:["[_nghost-%COMP%]{display:block;--dialog-p: 1.5rem}[content][_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}"],changeDetection:0})};var Ze=()=>({exact:!0});function et(n,o){n&1&&(s(0,"sh-icon"),h(1,"sun"),i())}function tt(n,o){n&1&&(s(0,"sh-icon"),h(1,"moon"),i())}function nt(n,o){if(n&1){let e=E();s(0,"button",22),g("click",function(){m(e);let a=c();return A(a.changeDefaultClientTo("ngax"))}),u(1,7),l(2,"sh-icon"),d(),i(),s(3,"button",22),g("click",function(){m(e);let a=c();return A(a.logout())}),u(4,8),l(5,"sh-icon"),d(),i()}}var J=class n{#e=F(ve);#t=F(x);#n=F(Ee);#o=F(pe);#i=F(ge);#s=F(k);#a=F(Te);relayIsEnabled=this.#o.relayIsEnabled;isDarkMode=this.#e.isDarkMode;ngOnInit(){return this.#s.init(),this.#n.getBackups(!0),this.#t.getApiV1Serversettings().subscribe({next:o=>{let e=o["autogenerated-passphrase"]==="True",t=o["has-asked-for-password-change"]==="True";e&&!t&&this.#i.open(U,{maxWidth:"500px"})}})}toggleBodyClass(){this.#e.toggleBodyClass()}changeDefaultClientTo(o){this.#r(o),window.location.replace(`/${o}`)}logout(){this.#a.logout()}#r(o){var e=new Date;e.setTime(e.getTime()+90*24*60*60*1e3),document.cookie="default-client="+o+"; expires="+e.toUTCString()+"; path=/"}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=M({type:n,selectors:[["app-layout"]],decls:37,vars:4,consts:()=>{let o;o=$localize`${"\uFFFD#10\uFFFD"}:START_TAG_SH_ICON:house${"\uFFFD/#10\uFFFD"}:CLOSE_TAG_SH_ICON: Home `;let e;e=$localize`${"\uFFFD#13\uFFFD"}:START_TAG_SH_ICON:database${"\uFFFD/#13\uFFFD"}:CLOSE_TAG_SH_ICON: Add backup `;let t;t=$localize`${"\uFFFD#16\uFFFD"}:START_TAG_SH_ICON:clock-counter-clockwise${"\uFFFD/#16\uFFFD"}:CLOSE_TAG_SH_ICON: Restore `;let a;a=$localize`${"\uFFFD#19\uFFFD"}:START_TAG_SH_ICON:gear${"\uFFFD/#19\uFFFD"}:CLOSE_TAG_SH_ICON: Settings `;let _;_=$localize`${"\uFFFD#26\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#26\uFFFD"}:CLOSE_TAG_SH_ICON: About Duplicati `;let D;D=$localize`${"\uFFFD#29\uFFFD"}:START_TAG_SH_ICON:files${"[\uFFFD/#29\uFFFD|\uFFFD/#30\uFFFD]"}:CLOSE_TAG_SH_ICON: Documentation ${"\uFFFD#30\uFFFD"}:START_TAG_SH_ICON_1:arrow-square-out${"[\uFFFD/#29\uFFFD|\uFFFD/#30\uFFFD]"}:CLOSE_TAG_SH_ICON:`,D=$(D);let N;N=$localize`${"\uFFFD#33\uFFFD"}:START_TAG_SH_ICON:chats-circle${"[\uFFFD/#33\uFFFD|\uFFFD/#34\uFFFD]"}:CLOSE_TAG_SH_ICON: Visit forum ${"\uFFFD#34\uFFFD"}:START_TAG_SH_ICON_1:arrow-square-out${"[\uFFFD/#33\uFFFD|\uFFFD/#34\uFFFD]"}:CLOSE_TAG_SH_ICON:`,N=$(N);let L;L=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:skip-back${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Use old UI `;let R;return R=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:sign-out${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON: Log out `,[o,e,t,a,_,D,N,L,R,["sidenav",""],["shButton","",1,"icon","small",3,"click"],[1,"base-1","primary"],["action","","routerLink","/","routerLinkActive","active",3,"routerLinkActiveOptions"],["action","","routerLink","/add-backup","routerLinkActive","active"],["action","","routerLink","/restore","routerLinkActive","active"],["action","","routerLink","/settings","routerLinkActive","active"],[1,"spacer"],[1,"base-1l","primary"],["action","","routerLink","/about","routerLinkActive","active"],["href","https://docs.duplicati.com","target","_blank","action",""],["suffix",""],["href","https://forum.duplicati.com","target","_blank","action",""],["action","",3,"click"]]},template:function(e,t){e&1&&(s(0,"sh-sidenav")(1,"div",9)(2,"header"),l(3,"app-logo"),s(4,"button",10),g("click",function(){return t.toggleBodyClass()}),p(5,et,2,0,"sh-icon")(6,tt,2,0,"sh-icon"),i()(),s(7,"sh-list",11)(8,"button",12),u(9,0),l(10,"sh-icon"),d(),i(),s(11,"button",13),u(12,1),l(13,"sh-icon"),d(),i(),s(14,"button",14),u(15,2),l(16,"sh-icon"),d(),i(),s(17,"button",15),u(18,3),l(19,"sh-icon"),d(),i()(),l(20,"div",16),s(21,"sh-list",17),p(22,nt,6,0),l(23,"sh-divider"),s(24,"button",18),u(25,4),l(26,"sh-icon"),d(),i(),s(27,"a",19),u(28,5),l(29,"sh-icon")(30,"sh-icon",20),d(),i(),s(31,"a",21),u(32,6),l(33,"sh-icon")(34,"sh-icon",20),d(),i()()(),l(35,"router-outlet")(36,"app-service-hub"),i()),e&2&&(r(5),S(t.isDarkMode()?5:6),r(3),P("routerLinkActiveOptions",ae(3,Ze)),r(14),S(t.relayIsEnabled()?-1:22))},dependencies:[ce,ue,de,Ae,I,me,w,he,y,Le],styles:["[_nghost-%COMP%]{height:100vh;width:100%;overflow:hidden}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:1.25rem;gap:.75rem}h3[title][_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between}div[sidenav][_ngcontent-%COMP%]{display:flex;flex-direction:column;height:100vh}"],changeDetection:0})};export{J as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-EUDKD2JW.js";var o=[{path:"",loadComponent:()=>import("./chunk-2F6NVETW.js"),children:[{path:"",redirectTo:"stored",pathMatch:"full"},{path:"stored",loadComponent:()=>import("./chunk-POMLWQHO.js")},{path:"live",loadComponent:()=>import("./chunk-RUFE3SMI.js")}]}],t=o;export{t as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{f as a,g as b}from"./chunk-MSLKIHQQ.js";import"./chunk-N6ABN43N.js";import"./chunk-DDWLL7XA.js";import"./chunk-2QJC4PGQ.js";import"./chunk-O64ZZGQZ.js";import"./chunk-DELLEGXW.js";import"./chunk-RHW5QVAY.js";import"./chunk-VTSUHAP5.js";import"./chunk-N5SC4SKW.js";import"./chunk-LVP2TPMO.js";import"./chunk-43JMN2ZY.js";import"./chunk-H7K35UUX.js";import"./chunk-NOPMCS2Z.js";import"./chunk-RUXCS4ZK.js";import"./chunk-FPPZ4BUR.js";import"./chunk-HNWRQABR.js";import"./chunk-EUDKD2JW.js";export{a as createSourceDataForm,b as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as _}from"./chunk-
|
|
1
|
+
import{a as _}from"./chunk-H7K35UUX.js";import{Ab as o,Bb as n,Ra as r,Uc as h,Wb as m,Xc as u,Zb as f,_b as a,bb as g,ic as C,lc as c,ub as d,vb as p}from"./chunk-HNWRQABR.js";var v=[[["","title",""]],[["","description",""]],[["","action",""]],"*"],M=["[title]","[description]","[action]","*"];function P(e,s){e&1&&c(0,"Title")}function T(e,s){e&1&&(o(0,"sh-icon"),c(1,"caret-down"),n())}var l=class e{isActive=u(!1);disallowToggle=h(!1);ngOnInit(){this.disallowToggle()&&this.isActive.set(!0)}toggle(){this.isActive.set(!this.isActive())}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=g({type:e,selectors:[["app-toggle-card"]],hostVars:2,hostBindings:function(t,i){t&2&&C("active",i.isActive())},inputs:{isActive:[1,"isActive"],disallowToggle:[1,"disallowToggle"]},outputs:{isActive:"isActiveChange"},ngContentSelectors:M,decls:11,vars:1,consts:[[1,"title"],[3,"click"],[1,"actions"],[1,"content"]],template:function(t,i){t&1&&(f(v),o(0,"header")(1,"div",0)(2,"h3",1),m("click",function(){return i.disallowToggle()||i.toggle()}),a(3,0,null,P,1,0),d(5,T,2,0,"sh-icon"),n(),a(6,1),n(),o(7,"div",2),a(8,2),n()(),o(9,"div",3),a(10,3),n()),t&2&&(r(5),p(i.disallowToggle()?-1:5))},dependencies:[_],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;border-radius:var(--shape-3);background-color:var(--base-2)}.active[_nghost-%COMP%] .content[_ngcontent-%COMP%]{max-height:1000px;transition:max-height 1s linear;padding:0 1rem 1rem}.active[_nghost-%COMP%] sh-icon[_ngcontent-%COMP%]{transform:rotate(180deg)}[_nghost-%COMP%] h3[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;font:var(--paragraph-10);cursor:pointer;-webkit-user-select:none;user-select:none}[_nghost-%COMP%] sh-icon[_ngcontent-%COMP%]{transform:rotate(0);transform-origin:center;transition:transform .2s ease}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:1rem}header[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem;flex:1 0}header[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]:empty{display:none}.content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem;padding:0 1rem;overflow:hidden;max-height:0;transition:max-height .25s linear,padding .25s linear}.content[_ngcontent-%COMP%]:empty{display:none}"],changeDetection:0})};export{l as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{Db as o,Eb as i,Jb as C,Oc as D,Ra as n,Tc as E,Uc as T,Xb as g,Yb as l,bb as x,ea as _,fa as u,lc as r,mc as m,ub as d,vb as s}from"./chunk-
|
|
1
|
+
import{Db as o,Eb as i,Jb as C,Oc as D,Ra as n,Tc as E,Uc as T,Xb as g,Yb as l,bb as x,ea as _,fa as u,lc as r,mc as m,ub as d,vb as s}from"./chunk-HNWRQABR.js";import{a as p}from"./chunk-EUDKD2JW.js";function v(e,a){if(e&1&&(o(0,"p"),r(1),i()),e&2){let t=l();n(),m(t._data().message)}}function b(e,a){if(e&1){let t=C();o(0,"button",5),g("click",function(){_(t);let f=l();return u(f.close("cancel"))}),r(1),i()}if(e&2){let t=l();n(),m(t._data().cancelText)}}function y(e,a){if(e&1){let t=C();o(0,"button",6),g("click",function(){_(t);let f=l();return u(f.close("confirm"))}),r(1),i()}if(e&2){let t=l();n(),m(t._data().confirmText)}}var k={title:$localize`Are you sure?`,confirmText:void 0,cancelText:$localize`Cancel`},h=class e{data=T();_data=D(()=>p(p({},k),this.data()));closed=E();close(a="confirm"){this.closed.emit(a==="confirm")}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=x({type:e,selectors:[["app-confirm-dialog"]],inputs:{data:[1,"data"]},outputs:{closed:"closed"},decls:8,vars:4,consts:[["header",""],["content",""],["footer",""],["shButton","",1,""],["shButton","",1,"raised","primary"],["shButton","",1,"",3,"click"],["shButton","",1,"raised","primary",3,"click"]],template:function(t,c){t&1&&(o(0,"header",0)(1,"h3"),r(2),i()(),o(3,"div",1),d(4,v,2,1,"p"),i(),o(5,"footer",2),d(6,b,2,1,"button",3),d(7,y,2,1,"button",4),i()),t&2&&(n(2),m(c._data().title),n(2),s(c._data().message?4:-1),n(2),s(c._data().cancelText?6:-1),n(),s(c._data().confirmText?7:-1))},styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})};export{h as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as m}from"./chunk-
|
|
1
|
+
import{a as m}from"./chunk-6OPAGPKF.js";import{_ as p,eb as a}from"./chunk-HNWRQABR.js";var u=class e{#t=p(m);transform(t,n=!1,...f){if(!t)return"";let r=t.split(".")[0],s=parseInt(r.split(":")[0])??0,i=parseInt(r.split(":")[1])??0,o=parseInt(r.split(":")[2])??0;return n?`${s}h ${i}m ${o}s`:this.#t.duration({hours:s,minutes:i,seconds:o}).humanize()}static \u0275fac=function(n){return new(n||e)};static \u0275pipe=a({name:"durationFormat",type:e,pure:!0})};export{u as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a}from"./chunk-L6CWVBZ6.js";import"./chunk-OMMUXRXE.js";import"./chunk-N6ABN43N.js";import"./chunk-DELLEGXW.js";import"./chunk-VTSUHAP5.js";import"./chunk-N5SC4SKW.js";import"./chunk-H7K35UUX.js";import"./chunk-NOPMCS2Z.js";import"./chunk-RUXCS4ZK.js";import"./chunk-FPPZ4BUR.js";import"./chunk-HNWRQABR.js";import"./chunk-EUDKD2JW.js";export{a as OptionsListComponent};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a}from"./chunk-DFMGS3IN.js";import"./chunk-6OPAGPKF.js";import"./chunk-HNWRQABR.js";import"./chunk-EUDKD2JW.js";export{a as DurationFormatPipe};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as re}from"./chunk-
|
|
1
|
+
import{c as re}from"./chunk-O64ZZGQZ.js";import{a as ne}from"./chunk-DVDTYV66.js";import"./chunk-UIJYCGKA.js";import{a as ie}from"./chunk-DELLEGXW.js";import"./chunk-RHW5QVAY.js";import"./chunk-VTSUHAP5.js";import{a as te}from"./chunk-UP5EOICU.js";import{b as oe,e as ae,i as le,s as _e}from"./chunk-N5SC4SKW.js";import"./chunk-Z3EPZZGY.js";import"./chunk-UKQFDBNO.js";import{d as q,e as H}from"./chunk-LVP2TPMO.js";import"./chunk-43JMN2ZY.js";import{a as J,e as Q,g as Y,i as Z}from"./chunk-H7K35UUX.js";import{h as ee}from"./chunk-NOPMCS2Z.js";import"./chunk-RUXCS4ZK.js";import"./chunk-FPPZ4BUR.js";import{Ab as i,Ac as z,B as y,Bb as o,Dc as V,Gc as W,H as O,Jb as P,Oc as L,Ra as r,Sb as c,Tb as D,Ub as h,Uc as j,Vb as $,Wb as x,Yb as E,_ as d,bb as F,ea as C,fa as g,ic as I,lc as u,n as U,oa as m,qc as M,r as K,rc as S,sc as B,tc as w,ub as f,uc as v,vb as T,vc as G,zb as A,zc as X}from"./chunk-HNWRQABR.js";import"./chunk-EUDKD2JW.js";var ce=l=>["/backup",l,"export"],se=()=>["/"];function ue(l,_){if(l&1){let t=P();i(0,"section")(1,"h4"),c(2,4),o(),i(3,"p"),c(4,5),o(),i(5,"sh-checkbox",11),u(6," Delete local database "),i(7,"input",12),B("ngModelChange",function(e){C(t);let a=E();return S(a.deleteLocalDb,e)||(a.deleteLocalDb=e),g(e)}),o()()()}if(l&2){let t=E();r(7),M("ngModel",t.deleteLocalDb)}}function de(l,_){if(l&1){let t=P();i(0,"section")(1,"h4"),c(2,6),o(),i(3,"p"),c(4,7),V(5,"bytes"),o(),i(6,"sh-checkbox",11),u(7," Delete remote files "),i(8,"input",12),B("ngModelChange",function(e){C(t);let a=E();return S(a.deleteRemoteFiles,e)||(a.deleteRemoteFiles=e),g(e)}),o()()()}if(l&2){let t=E(),n=G(0),e=(n==null||n.Backup==null||n.Backup.Metadata==null?null:n.Backup.Metadata.TargetFilesSize)??0;r(5),D(t.fileCount())(t.fileCount())(W(5,4,e,!0,!0)),h(4),r(3),M("ngModel",t.deleteRemoteFiles)}}var b=class l{#t=d(ee);#n=d(Q);#e=d(ne);#i=d(q);id=j.required();backup=L(()=>this.#e.getBackupById(this.id()));noLocalDbResource=re({params:()=>({dbPath:this.backup()?.Backup?.DBPath}),stream:({params:_})=>this.#t.postApiV1FilesystemValidate({requestBody:{path:_.dbPath}}).pipe(K(()=>!0),y(()=>U(!1)))});fileCount=L(()=>parseInt(this.backup()?.Backup?.Metadata?.TargetFilesCount??"0",10));deleteLocalDb=m(!1);deleteRemoteFiles=m(!1);isDeleting=m(!1);deleteBackup(){let _=this.id(),t=this.deleteLocalDb(),n=this.deleteRemoteFiles();this.isDeleting.set(!0),this.#n.open(ie,{data:{title:$localize`Confirm delete`,message:$localize`Are you sure you want to delete this backup?`,confirmText:$localize`Delete backup`,cancelText:$localize`Cancel`},closed:e=>{e&&this.#e.deleteBackup({id:_,deleteLocalDb:t,deleteRemoteFiles:n}).pipe(O(()=>this.isDeleting.set(!1))).subscribe({next:()=>{this.#i.navigate(["/"])}})}})}static \u0275fac=function(t){return new(t||l)};static \u0275cmp=F({type:l,selectors:[["app-delete-backup"]],inputs:{id:[1,"id"]},decls:19,vars:11,consts:()=>{let _;_=$localize`Delete backup: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let t;t=$localize`Export configuration`;let n;n=$localize`If you want to use the backup later, you can export the configuration before deleting it.`;let e;e=$localize`Cancel`;let a;a=$localize`Delete local database`;let N;N=$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 k;k=$localize`Delete remote files`;let p;p=$localize`{VAR_PLURAL, plural, =1 {1 file} other {{INTERPOLATION} files}}`,p=$(p,{INTERPOLATION:"\uFFFD1\uFFFD",VAR_PLURAL:"\uFFFD0\uFFFD"});let R;return R=$localize` Delete ${p}:ICU@@2159106180826349718: (${"\uFFFD2\uFFFD"}:INTERPOLATION_1:) from the remote storage? `,[_,t,n,e,a,N,k,R,["shButton","",3,"routerLink"],[1,"actions"],["shButton","",1,"raised","error",3,"click"],[1,"primary","raised"],["type","checkbox",3,"ngModelChange","ngModel"]]},template:function(t,n){if(t&1){let e=P();w(0),i(1,"h3"),c(2,0),o(),f(3,ue,8,1,"section"),i(4,"section")(5,"h4"),c(6,1),o(),i(7,"p"),c(8,2),o(),i(9,"button",8),u(10," Export configuration "),i(11,"sh-icon"),u(12,"caret-right"),o()()(),f(13,de,9,8,"section"),i(14,"div",9)(15,"button",8),c(16,3),o(),i(17,"button",10),x("click",function(){return C(e),g(n.deleteBackup())}),u(18,"Delete backup"),o()()}if(t&2){let e=v(n.backup()),a=n.noLocalDbResource.value();r(2),D(e==null||e.Backup==null?null:e.Backup.Name),h(2),r(),T(a?3:-1),r(6),A("routerLink",z(8,ce,n.id())),r(4),T(a?13:-1),r(2),A("routerLink",X(10,se)),r(2),I("loader",n.isDeleting())}},dependencies:[Z,Y,J,_e,oe,ae,le,H,te],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;padding:2.5rem;max-width:43.75rem}section[_ngcontent-%COMP%]{padding:2rem 0;display:flex;align-items:flex-start;flex-direction:column}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0}h4[_ngcontent-%COMP%]{font:var(--paragraph-20);margin-bottom:.5rem}p[_ngcontent-%COMP%]{margin-bottom:1rem}.actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;gap:.5rem;padding:2rem 0}"],changeDetection:0})};export{b as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as M}from"./chunk-
|
|
1
|
+
import{a as M}from"./chunk-QDFDQHU3.js";import{a as Z}from"./chunk-DELLEGXW.js";import{b as H,d as K}from"./chunk-LVP2TPMO.js";import{b as j,c as W,e as q,g as Y,p as J}from"./chunk-H7K35UUX.js";import{h as Q}from"./chunk-NOPMCS2Z.js";import{Ab as a,Bb as l,Cb as O,Gb as D,Hb as R,Jb as f,Oa as E,Oc as h,Qb as V,Ra as r,Rb as z,Sb as s,Uc as S,Wb as u,Yb as _,_ as p,bb as A,ea as C,fa as I,kc as G,lc as F,mc as P,nc as X,oa as v,tc as B,ub as d,uc as U,vb as N,vc as m,xb as y,yb as L,zb as g}from"./chunk-HNWRQABR.js";function ne(n,t){if(n&1&&F(0),n&2){_();let e=m(0);X(" ",e.Message," ")}}function oe(n,t){if(n&1&&(a(0,"div"),V(1,1),O(2,"a",15),z(),l()),n&2){let e=_();r(2),g("href",e.downloadLink(),E)}}function ae(n,t){if(n&1){let e=f();a(0,"button",14),u("click",function(){C(e);let i=_(),c=m(0);return I(i.doRepair(c.BackupID))}),s(1,2),l()}}function re(n,t){if(n&1){let e=f();a(0,"button",14),u("click",function(){C(e);let i=_(),c=m(0);return I(i.doDownloadBugreport(c))}),s(1,3),l()}}function le(n,t){if(n&1&&O(0,"sh-progress-bar",17),n&2){let e,o=_(2);g("value",(e=o.serverState())==null?null:e.UpdateDownloadProgress)}}function ce(n,t){if(n&1){let e=f();a(0,"div",13),D(1),s(2,4),R(),a(3,"a",16),F(4),l(),d(5,le,1,1,"sh-progress-bar",17),a(6,"button",14),u("click",function(){C(e);let i=_();return I(i.doShowUpdate())}),s(7,5),l()()}if(n&2){let e,o,i=_(),c=m(0);r(3),g("href",(e=i.serverState())==null?null:e.UpdateDownloadLink,E),r(),P(c.Message),r(),N(((o=i.serverState())==null?null:o.UpdaterState)==="Downloading"?5:-1)}}function se(n,t){if(n&1){let e=f();a(0,"button",14),u("click",function(){C(e);let i=_(),c=m(0);return I(i.doShowLog(c.BackupID))}),s(1,6),l()}}function _e(n,t){if(n&1){let e=f();a(0,"button",14),u("click",function(){C(e);let i=_();return I(i.doShowLink("https://docs.duplicati.com/detailed-descriptions/the-server-database"))}),s(1,7),l()}}function de(n,t){if(n&1){let e=f();a(0,"button",14),u("click",function(){C(e);let i=_();return I(i.doShowLink("https://docs.duplicati.com/detailed-descriptions/the-server-database"))}),s(1,8),l()}}var Ne={Error:"error",Warning:"warn",Information:"primary"},x=class n{#e=p(K);#a=p(H);#r=p(q);#t=p(W);#i=p(M);#n=p(Q);#o=v(null);serverState=this.#i.serverState;index=S.required();notification=S.required();downloadLink=h(()=>this.#o()||this.notification().DownloadLink||"");deleteNotificationByIndex(){this.#i.deleteNotification(this.index())}deleteAllNotifications(){this.#i.deleteAllNotifications()}getAlertType(t){return t&&Ne[t]||"primary"}doShowLog(t){this.#n.getApiV1BackupByIdIsactive({id:t}).subscribe({next:e=>{this.#e.navigate(["/backup/"+t+"/log"])},error:e=>{if(e.status===404){let o={title:$localize`Error`,message:$localize`The backup is missing, has it been deleted?`,confirmText:$localize`OK`,cancelText:null};parseInt(t)+""!=t&&(o={title:$localize`Error`,message:$localize`The backup was temporary and does not exist anymore, so the log data is lost`,confirmText:$localize`OK`,cancelText:null}),this.#r.open(Z,{maxWidth:"550px",width:"100%",data:o})}else this.#t.error($localize`Failed to find backup: `+e.message)}})}doRepair(t){this.#n.postApiV1BackupByIdRepair({id:t}).subscribe({next:()=>{this.#t.success($localize`Backup repaired`),this.#e.navigate(["./"],{onSameUrlNavigation:"reload",relativeTo:this.#a})},error:e=>{this.#t.error($localize`Failed to repair backup: `+e.message)}})}doShowUpdate(){this.#e.navigate(["/about/changelog"])}doShowLink(t){window.open(t,"_blank")}doDownloadBugreport(t){let e=t.Action.slice(19);this.#n.postApiV1AuthIssuetokenByOperation({operation:"bugreport"}).subscribe({next:o=>{if(!o.Token){this.#t.error("Failed to get bug report URL: No token generated");return}let i=`${location.origin}/api/v1/bugreport/${e}?token=${o.Token}`;t.DownloadLink=i,this.#o.set(i),this.triggerDownload(i)},error:o=>{this.#t.error(`Failed to get bug report URL: ${o.message}`)}})}triggerDownload(t){let e=document.createElement("a");e.href=t,e.download="",e.style.display="none",document.body.appendChild(e);try{e.click()}catch{}document.body.removeChild(e)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=A({type:n,selectors:[["app-notification"]],inputs:{index:[1,"index"],notification:[1,"notification"]},decls:16,vars:12,consts:()=>{let t;t=$localize`Dismiss`;let e;e=$localize` If the backup file was not downloaded automatically, ${"\uFFFD#2\uFFFD"}:START_LINK:right click and choose "Save as …"${"\uFFFD/#2\uFFFD"}:CLOSE_LINK:`;let o;o=$localize`Repair`;let i;i=$localize`Download`;let c;c=$localize`New update found:`;let w;w=$localize`Show Update`;let $;$=$localize`Show Log`;let b;b=$localize` Show Help `;let k;return k=$localize` Show Help `,[t,e,o,i,c,w,$,b,k,["ship-alert-title",""],["ship-alert-content","",1,"content"],[1,"actions"],["shButton","",1,"small","outlined"],[1,"message"],["shButton","",1,"small","outlined",3,"click"],["target","_blank",3,"href"],[3,"href"],[3,"value"]]},template:function(e,o){if(e&1){let i=f();B(0),a(1,"sh-alert")(2,"div",9),F(3),l(),a(4,"div",10),d(5,ne,1,1),d(6,oe,3,1,"div"),a(7,"div",11),d(8,ae,2,0,"button",12),d(9,re,2,0,"button",12),d(10,ce,8,3,"div",13),d(11,se,2,0,"button",12),d(12,_e,2,0,"button",12),d(13,de,2,0,"button",12),a(14,"button",14),u("click",function(){return C(i),I(o.deleteNotificationByIndex())}),s(15,0),l()()()()}if(e&2){let i=U(o.notification());r(),G(o.getAlertType(i.Type)),r(2),P(i.Title),r(2),N(i.Action!=="update:new"&&i.Action!=="update:manual"?5:-1),r(),N(o.downloadLink()?6:-1),r(2),N(i.Message!=null&&i.Message.includes("please run repair")?8:-1),r(),N(i.Action!=null&&i.Action.startsWith("bug-report:created:")&&!o.downloadLink()?9:-1),r(),N(i.Action==="update:new"?10:-1),r(),N(i.Action==="backup:show-log"?11:-1),r(),N(i.Action==="config:issue:unencrypted-database"?12:-1),r(),N(i.Action==="config:issue:windows-folder-used"?13:-1)}},dependencies:[J,Y,j],styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})};var pe=(n,t)=>t.ID;function Te(n,t){if(n&1&&O(0,"app-notification",1),n&2){let e=t.$implicit,o=t.$index;g("index",o)("notification",e)}}function Ce(n,t){n&1&&(a(0,"div",2)(1,"p"),s(2,0),l()())}var ee=class n{#e=p(M);notificationFilterPredicate=S();notifications=h(()=>{let t=this.notificationFilterPredicate()?.predicate,e=this.#e.notifications();return typeof t!="function"?e:e.filter(t)});static \u0275fac=function(e){return new(e||n)};static \u0275cmp=A({type:n,selectors:[["app-notifications"]],inputs:{notificationFilterPredicate:[1,"notificationFilterPredicate"]},decls:3,vars:1,consts:()=>{let t;return t=$localize`No more notifications`,[t,[3,"index","notification"],[1,"notification-list"]]},template:function(e,o){e&1&&y(0,Te,1,2,"app-notification",1,pe,!1,Ce,3,0,"div",2),e&2&&L(o.notifications())},dependencies:[x],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.actions[_ngcontent-%COMP%]{display:flex;gap:.25rem;justify-content:flex-end}.notification-list[_ngcontent-%COMP%]{padding:1rem;display:flex;flex-direction:column;gap:1rem;text-align:center}"],changeDetection:0})};export{x as a,ee as b};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as B}from"./chunk-
|
|
1
|
+
import{a as B}from"./chunk-UIJYCGKA.js";import{a as m}from"./chunk-RHW5QVAY.js";import{a as k}from"./chunk-VTSUHAP5.js";import{a as r}from"./chunk-Z3EPZZGY.js";import{h as b}from"./chunk-NOPMCS2Z.js";import{F as i,H as u,Oc as p,Pc as d,R as c,V as o,_ as s,oa as a}from"./chunk-HNWRQABR.js";var y="backupListOrderBy",v="backupListShowActualTimes",D=[{value:"id",label:$localize`Backup ID`},{value:"name",label:$localize`Backup name`},{value:"lastrun",label:$localize`Last run time`},{value:"nextrun",label:$localize`Next run time`},{value:"schedule",label:$localize`Is scheduled`},{value:"backend",label:$localize`Destination type`},{value:"sourcesize",label:$localize`Source size`},{value:"destinationsize",label:$localize`Destination size`},{value:"duration",label:$localize`Duration`},{value:"-id",label:$localize`Backup ID (descending)`},{value:"-name",label:$localize`Backup name (descending)`},{value:"-lastrun",label:$localize`Last run time (descending)`},{value:"-nextrun",label:$localize`Next run time (descending)`},{value:"-schedule",label:$localize`Is scheduled (descending)`},{value:"-backend",label:$localize`Destination type (descending)`},{value:"-sourcesize",label:$localize`Source size (descending)`},{value:"-destinationsize",label:$localize`Destination size (descending)`},{value:"-duration",label:$localize`Duration (descending)`}],g=class l{#s=s(b);#o=s(k);#e=s(B);#u=null;#t=a([]);#a=a([]);#l=a(!1);#n=a(null);#p=a(null);#c=r(v,"relative");#i=r(y,"id");orderByOptions=a(D);orderBy=this.#i.asReadonly();backups=this.#a.asReadonly();timeType=this.#c.asReadonly();backupsLoading=this.#l.asReadonly();startingBackup=this.#n.asReadonly();deletingBackup=this.#p.asReadonly();draftBackups=this.#t.asReadonly();#r=p(()=>this.#o.hasBackupListSubscribeOption()&&this.#e.getConnectionMethod()==="websocket");#d=d(()=>{let e=this.#e.backupListState();e&&this.#a.set(e)});addDraftBackup(e){let t=m();return this.#t.set([...this.#t(),{id:t,data:e}]),t}setOrderBy(e){this.#i.set(e),this.#e.isConnectionMethodSet()&&(this.#r()?this.#e.subscribe("backuplist",e):this.getBackups(!0))}setTimeType(e){this.#c.set(e)}removeDraftBackupById(e){this.#t.set(this.#t().filter(t=>t.id!==e))}getBackupById(e){return this.#a().find(t=>t.Backup?.ID===e)??null}getBackups(e=!1){if(!this.#e.isConnectionMethodSet())return;if(this.#r()){this.#e.subscribe("backuplist",this.#i());return}let t=this.#u,n=Date.now(),h=t&&n-t<15*60*1e3;t&&n-t<100||!e&&h&&this.#a().length||(this.#u=n,this.#l.set(!0),this.#s.getApiV1Backups({orderBy:this.#i()}).pipe(i(1),c(f=>this.#a.set(f)),u(()=>this.#l.set(!1))).subscribe())}startBackup(e){this.#n.set(e),this.#s.postApiV1BackupByIdStart({id:e}).pipe(i(1),c(()=>this.getBackups(!0)),u(()=>this.#n.set(null))).subscribe()}deleteBackup(e){return this.#s.deleteApiV1BackupById(e).pipe(i(1))}static \u0275fac=function(t){return new(t||l)};static \u0275prov=o({token:l,factory:l.\u0275fac,providedIn:"root"})};export{g as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as y}from"./chunk-
|
|
1
|
+
import{b as y}from"./chunk-O64ZZGQZ.js";import{a as w}from"./chunk-UIJYCGKA.js";import{a as b}from"./chunk-VTSUHAP5.js";import"./chunk-UKQFDBNO.js";import"./chunk-LVP2TPMO.js";import"./chunk-43JMN2ZY.js";import{a as I,g as U,p as $}from"./chunk-H7K35UUX.js";import{h as x}from"./chunk-NOPMCS2Z.js";import"./chunk-RUXCS4ZK.js";import"./chunk-FPPZ4BUR.js";import{Ab as a,Bb as r,Cb as d,H as g,Jb as f,Oa as M,Oc as k,Qb as O,Ra as l,Rb as P,Sb as F,Tb as E,Ub as h,Wb as T,Yb as p,_,bb as D,ea as m,fa as C,ic as L,lc as u,mc as R,oa as S,r as v,ub as s,vb as c,zb as G}from"./chunk-HNWRQABR.js";import"./chunk-EUDKD2JW.js";function V(n,o){n&1&&d(0,"sh-progress-bar",3)}function B(n,o){if(n&1&&(a(0,"a",7),O(1,2),d(2,"sh-icon"),P(),r()),n&2){let e,t,i=p(2);G("href",(e=i.serverState())==null?null:e.UpdateDownloadLink,M),l(2),E((t=i.serverState())==null?null:t.UpdatedVersion),h(1)}}function X(n,o){if(n&1){let e=f();a(0,"button",6),T("click",function(){m(e);let i=p();return C(i.checkForUpdates())}),u(1,"Check for updates"),r(),s(2,B,3,2,"a",7)}if(n&2){let e,t=p();L("loader",t.checkingForUpdates()),l(2),c((e=t.serverState())!=null&&e.UpdateDownloadLink?2:-1)}}function z(n,o){if(n&1){let e=f();a(0,"button",6),T("click",function(){m(e);let i=p();return C(i.checkForUpdates())}),u(1,"Checking for updates \u2026"),r()}}function H(n,o){n&1&&d(0,"sh-progress-bar",3)}var N=class n{#e=_(x);#t=_(w);#n=_(b);isLoading=S(!0);checkingForUpdates=S(!1);serverState=this.#t.serverState;duplicatiVersion=k(()=>this.#n.systemInfo()?.ServerVersionName??"Unknown");generalInfo=y(this.#e.getApiV1Acknowledgements().pipe(v(o=>o.Acknowledgements),g(()=>this.isLoading.set(!1))));checkForUpdates(){this.checkingForUpdates.set(!0),this.#e.postApiV1UpdatesCheck().pipe(g(()=>this.checkingForUpdates.set(!1))).subscribe()}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=D({type:n,selectors:[["app-general"]],decls:12,vars:5,consts:()=>{let o;o=$localize`General`;let e;e=$localize`You're running Duplicati with - ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let t;return t=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:download${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Download update - ${"\uFFFD0\uFFFD"}:INTERPOLATION: `,[o,e,t,[1,"indeterminate","primary"],[1,"actions"],["shButton",""],["shButton","",3,"click"],["shButton","","target","_blank",1,"primary","raised",3,"href"]]},template:function(e,t){if(e&1&&(s(0,V,1,0,"sh-progress-bar",3),a(1,"section")(2,"h3"),F(3,0),r(),a(4,"p"),F(5,1),r(),a(6,"div",4),s(7,X,3,3)(8,z,2,0,"button",5),s(9,H,1,0,"sh-progress-bar",3),r(),a(10,"div"),u(11),r()()),e&2){let i,A;c(t.isLoading()?0:-1),l(5),E(t.duplicatiVersion()),h(5),l(2),c(((i=t.serverState())==null?null:i.UpdaterState)==="Waiting"?7:((i=t.serverState())==null?null:i.UpdaterState)==="Checking"?8:-1),l(2),c(((A=t.serverState())==null?null:A.UpdaterState)==="Downloading"?9:-1),l(2),R(t.generalInfo())}},dependencies:[$,U,I],styles:["[_nghost-%COMP%]{display:block;position:relative}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0 0 1.25rem}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}section[_ngcontent-%COMP%] div[_ngcontent-%COMP%]{white-space:pre-wrap}sh-progress-bar[_ngcontent-%COMP%]{position:absolute;top:0;left:0;right:0}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}"],changeDetection:0})};export{N as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as o}from"./chunk-
|
|
1
|
+
import{a as o}from"./chunk-Z3EPZZGY.js";import{Pc as i,V as t,oa as s}from"./chunk-HNWRQABR.js";var a=class e{#e=o("darkTheme",null,!0);#s=s(window?.innerWidth<=768);#t=s(!1);isDarkMode=this.#e.asReadonly();isMobile=this.#s.asReadonly();isNavOpen=this.#t.asReadonly();constructor(){window.matchMedia("(prefers-color-scheme:dark)").matches&&this.#e()===null&&this.setDarkMode(),i(()=>{this.#e()?document.body.classList.add("dark"):document.body.classList.remove("dark")})}ngOnInit(){window.addEventListener("resize",this.#i)}toggleNav(){this.#t.set(!this.isNavOpen())}toggleBodyClass(){this.#e.set(!this.isDarkMode())}setDarkMode(){this.#e.set(!0)}setLightMode(){this.#e.set(!1)}#i(){this.#s.set(window.innerWidth<=768)}ngOnDestroy(){window.removeEventListener("resize",this.#i)}static \u0275fac=function(n){return new(n||e)};static \u0275prov=t({token:e,factory:e.\u0275fac,providedIn:"root"})};export{a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as d}from"./chunk-
|
|
1
|
+
import{h as d}from"./chunk-NOPMCS2Z.js";import{H as r,Oc as s,Pc as g,V as n,_ as o,oa as l}from"./chunk-HNWRQABR.js";var u=[{value:"Disabled",label:$localize`Disabled`},{value:"Verbose",label:$localize`Verbose`},{value:"ExplicitOnly",label:$localize`Explicit only`},{value:"Profiling",label:$localize`Profiling`},{value:"Retry",label:$localize`Retry`},{value:"Information",label:$localize`Information`},{value:"DryRun",label:$localize`Dry run`},{value:"Warning",label:$localize`Warning`},{value:"Error",label:$localize`Error`}],v=class a{#l=o(d);#e=l([]);LOG_LEVELS=u;logLevel=l("Disabled");logLevelByLabel=s(()=>u.find(e=>e.value===this.logLevel())?.label);whenFilter=l(null);backupIdFilter=l(null);id=l(0);logs=s(()=>this.whenFilter()&&this.backupIdFilter()?this.#e().filter(e=>e.BackupID===this.backupIdFilter()&&new Date(e.When).getTime()>=this.whenFilter()&&e.BackupID===this.backupIdFilter()):this.#e());timerInterval;logsLoading=l(!1);isPolling=l(!1);pagination=l({offset:0,pagesize:100});logLevelEffect=g(()=>{this.logLevel()==="Disabled"?this.timerInterval=void 0:this.isPolling()?(this.#e.set([]),this.id.set(0),queueMicrotask(()=>this.loadLogs()),this.timerInterval&&clearInterval(this.timerInterval),this.timerInterval=setInterval(()=>{this.loadLogs()},3e3)):(this.timerInterval&&clearInterval(this.timerInterval),this.timerInterval=void 0)});setWhenFilter(e){this.whenFilter.set(e)}setBackupIdFilter(e){this.backupIdFilter.set(e)}loadLogs(){this.logsLoading.set(!0),this.#l.getApiV1LogdataPoll({id:this.id(),level:this.logLevel(),pagesize:this.pagination().pagesize}).pipe(r(()=>this.logsLoading.set(!1))).subscribe({next:e=>{let t=e.reverse(),i=this.#t(t);i>0&&this.id.set(i),this.#e.set([...t,...this.#e()])}})}updateLogLevel(e){this.logLevel.set(e)}#t(e){return e.reduce((t,i)=>Math.max(t,i.ID),0)}destroy(){this.logLevel.set("Disabled"),this.timerInterval&&clearInterval(this.timerInterval)}static \u0275fac=function(t){return new(t||a)};static \u0275prov=n({token:a,factory:a.\u0275fac,providedIn:"root"})};export{v as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as z}from"./chunk-
|
|
1
|
+
import{a as z}from"./chunk-QHC3CY43.js";import{b as A,c as G,d as T,e as R,f as V,j as q,o as $,q as B,r as Q,t as j}from"./chunk-N5SC4SKW.js";import{a as k}from"./chunk-Z3EPZZGY.js";import{d as D}from"./chunk-UKQFDBNO.js";import{d as x}from"./chunk-LVP2TPMO.js";import"./chunk-43JMN2ZY.js";import{a as E,b as O,g as P,i as I,l as F}from"./chunk-H7K35UUX.js";import"./chunk-NOPMCS2Z.js";import"./chunk-RUXCS4ZK.js";import"./chunk-FPPZ4BUR.js";import{Ab as t,Bb as o,Cb as s,H as u,Jb as _,Pc as S,Ra as c,Vc as N,Wb as w,_ as p,bb as h,ea as g,ec as v,fa as f,fc as L,ic as y,lc as r,oa as m,ub as b,vb as C,zb as M}from"./chunk-HNWRQABR.js";import"./chunk-EUDKD2JW.js";var H=["passwordInput"];function K(a,e){a&1&&(t(0,"sh-alert",2),r(1," Remember to enter a password, if you can't remember the password open the duplicati client on the machine in question and make sure you open it through the tray icon then go into settings to change the password. "),o())}var l=new Q,d=class a{#e=p(x);#t=p(D);rememberMe=k("rememberMe",!1,!0);failedLogin=m(!1);successLogin=m(!1);isLoading=m(!1);loginForm=l.group({user:l.control(""),pass:l.control("",T.required),rememberMe:l.control(this.rememberMe())});passwordInput=N("passwordInput");passwordEffect=S(()=>{this.failedLogin()&&queueMicrotask(()=>this.passwordInput()?.nativeElement?.focus())});ngOnInit(){this.loginForm.controls.rememberMe.valueChanges.subscribe(e=>this.rememberMe.set(e??!1)),queueMicrotask(()=>this.passwordInput()?.nativeElement?.focus())}submit(){let e=this.loginForm.value.pass,n=this.loginForm.value.user;this.rememberMe.set(this.loginForm.value.rememberMe??!1),!n&&e&&(this.isLoading.set(!0),this.#t.login(e,this.rememberMe()).pipe(u(()=>{this.isLoading.set(!1),this.failedLogin.set(!0)})).subscribe({next:()=>{this.successLogin.set(!0),this.#e.navigate(["/"])}}))}static \u0275fac=function(n){return new(n||a)};static \u0275cmp=h({type:a,selectors:[["app-login"]],viewQuery:function(n,i){n&1&&v(i.passwordInput,H,5),n&2&&L()},decls:24,vars:4,consts:()=>{let e;return e=$localize`Enter your password`,[["passwordInput",""],[3,"submit","formGroup"],["type","warning"],[1,"logo-login"],[1,"inner"],[1,"login-row"],["type","text","hidden","","autocomplete","off","name","username","formControlName","user"],["for","password"],["href","https://docs.duplicati.com/detailed-descriptions/duplicati-access-password","target","_blank","rel","noopener noreferrer"],["type","password","name","password","autocomplete","current-password","placeholder",e,"tabindex","1","formControlName","pass"],["shButton","","type","submit",1,"raised","primary"],[1,"raised","primary"],["type","checkbox","id","rememberMe","tabindex","2","formControlName","rememberMe"],[1,"login-row","checkbox"],["for","rememberMe",1,"remember-me"]]},template:function(n,i){if(n&1){let X=_();t(0,"form",1),w("submit",function(){return g(X),f(i.submit())}),b(1,K,2,0,"sh-alert",2),t(2,"div",3),s(3,"app-logo"),o(),t(4,"div",4)(5,"div",5),s(6,"input",6),t(7,"sh-form-field")(8,"label",7),r(9," Password "),t(10,"a",8)(11,"sh-icon"),r(12,"question"),o()()(),s(13,"input",9,0),o(),t(15,"button",10),r(16," Login "),t(17,"sh-icon"),r(18,"arrow-right"),o()()(),t(19,"sh-checkbox",11),r(20," Keep me logged in "),s(21,"input",12),o(),t(22,"div",13),s(23,"label",14),o()()()}n&2&&(M("formGroup",i.loginForm),c(),C(i.failedLogin()&&!i.successLogin()?1:-1),c(14),y("loader",i.isLoading()))},dependencies:[j,q,G,A,R,V,$,B,z,F,E,P,O,I],styles:["[_nghost-%COMP%]{display:block}form[_ngcontent-%COMP%]{width:100vw;min-height:100vh;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.75rem}form[_ngcontent-%COMP%] .inner[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;gap:1rem}form[_ngcontent-%COMP%] .inner[_ngcontent-%COMP%] .checkbox[_ngcontent-%COMP%]{align-self:flex-start}sh-alert[_ngcontent-%COMP%]{max-width:20rem;margin:0 auto}h3[_ngcontent-%COMP%]{font:var(--title-30)}.login-row[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.5rem}.logo-login[_ngcontent-%COMP%]{top:0;left:0;padding:1.25rem;position:fixed}"],changeDetection:0})};export{d as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{g as ht}from"./chunk-PN3U7MRX.js";import{a as pt,b as Ot,c as Ct,d as mt,e as Rt}from"./chunk-QYI4IMJE.js";import"./chunk-7IQY6U5W.js";import"./chunk-L6CWVBZ6.js";import"./chunk-OMMUXRXE.js";import{a as Dt}from"./chunk-KDYD6LMI.js";import{h as Et}from"./chunk-MSLKIHQQ.js";import"./chunk-N6ABN43N.js";import"./chunk-DDWLL7XA.js";import"./chunk-2QJC4PGQ.js";import"./chunk-O64ZZGQZ.js";import"./chunk-UIJYCGKA.js";import{a as m}from"./chunk-DELLEGXW.js";import"./chunk-RHW5QVAY.js";import"./chunk-VTSUHAP5.js";import"./chunk-UP5EOICU.js";import{c as _t,e as ct,f as ut,g as Tt,i as gt,j as St,s as dt}from"./chunk-N5SC4SKW.js";import"./chunk-UKQFDBNO.js";import{b as nt,d as it}from"./chunk-LVP2TPMO.js";import"./chunk-43JMN2ZY.js";import{a as ot,b as at,d as st,e as rt,l as Ft,o as lt}from"./chunk-H7K35UUX.js";import"./chunk-NOPMCS2Z.js";import"./chunk-RUXCS4ZK.js";import"./chunk-FPPZ4BUR.js";import{Ab as s,Bb as r,Cb as g,Gb as w,Hb as b,Jb as p,Oc as v,Qb as u,Ra as F,Rb as T,Sb as N,Tb as f,Ub as $,Vb as B,Vc as et,Wb as d,Yb as l,_ as O,bb as j,ea as _,ec as Q,fa as c,fc as q,ia as K,ic as Y,lc as I,mc as k,nc as J,oa as C,qc as A,rc as M,sc as y,ub as D,vb as E,wb as P,xb as x,yb as L,yc as Z,zb as h,zc as tt}from"./chunk-HNWRQABR.js";import"./chunk-EUDKD2JW.js";var It=["formRef"],Nt=()=>({maxWidth:"700px",width:"100%"});function ft(i,n){if(i&1){let t=p();u(0,2,1),s(1,"button",30),d("click",function(){_(t);let e=l();return c(e.testDestination(0,!0))}),r(),T()}if(i&2){let t=l();F(),Y("loader",t.testSignal()=="testing"),h("disabled",t.testSignal()=="testing")}}function $t(i,n){if(i&1){let t=p();u(0,2,2),s(1,"button",20),d("click",function(){_(t);let e=l();return c(e.copyTargetUrl())}),g(2,"sh-icon"),r(),T()}}function At(i,n){i&1&&(s(0,"sh-alert"),u(1,5),g(2,"sh-icon",31),T(),r())}function Mt(i,n){i&1&&(s(0,"sh-alert",21),u(1,6),g(2,"sh-icon",31),T(),r())}function yt(i,n){if(i&1&&(s(0,"sh-alert",22),u(1,7),g(2,"sh-icon",31),T(),r()),i&2){let t=l();F(2),f(t.testErrorMessage()),$(1)}}function Pt(i,n){if(i&1&&(s(0,"sh-alert",23),u(1,8),g(2,"sh-icon",31),T(),r()),i&2){let t=l();F(2),f(t.testErrorMessage()),$(1)}}function xt(i,n){if(i&1){let t=p();s(0,"p",32),d("click",function(){_(t);let e=l();return c(e.removeDestination())}),u(1,9),g(2,"strong")(3,"br")(4,"span",33),T(),r()}if(i&2){let t,o=l();F(4),f((t=o.selectedDestinationType())==null?null:t.displayName),$(1)}}function Lt(i,n){if(i&1){let t=p();s(0,"div",39),d("click",function(){let e=_(t).$implicit,a=l(2);return c(a.setDestination(e.key))}),s(1,"h3"),I(2),r(),s(3,"p"),I(4),r()()}if(i&2){let t=n.$implicit;F(2),k(t.displayName),F(2),k(t.description)}}function wt(i,n){if(i&1){let t=p();s(0,"button",40,1),d("click",function(){let e=_(t).$implicit,a=l(2);return c(a.setDestination(e.key))}),I(2),r()}if(i&2){let t=n.$implicit;F(2),J(" ",t.displayName," ")}}function bt(i,n){if(i&1&&(s(0,"div",34),x(1,Lt,5,2,"div",35,P),r(),s(3,"sh-menu",36)(4,"button",37),N(5,10),r(),w(6,19),x(7,wt,3,1,"button",38,P),b(),r()),i&2){let t=l();F(),L(t.destinationTypeOptionsFocused()),F(2),h("searchable",!0),F(4),L(t.destinationTypeOptions())}}function Bt(i,n){if(i&1){let t=p();s(0,"app-single-destination",41),y("targetUrlChange",function(e){_(t);let a=l();return M(a.targetUrlModel,e)||(a.targetUrlModel=e),c(e)}),r()}if(i&2){let t=l();A("targetUrl",t.targetUrlModel)}}function kt(i,n){i&1&&(u(0,4,1),g(1,"sh-icon",28),T())}function vt(i,n){i&1&&(u(0,4,2),g(1,"sh-icon"),T())}function Gt(i,n){if(i&1){let t=p();s(0,"sh-dialog",42),y("isOpenChange",function(e){_(t);let a=l();return M(a.targetUrlDialogOpen,e)||(a.targetUrlDialogOpen=e),c(e)}),s(1,"header",43)(2,"h2"),N(3,11),r(),s(4,"sh-alert",22),N(5,12),r()(),s(6,"div",44)(7,"sh-form-field")(8,"textarea",45),y("ngModelChange",function(e){_(t);let a=l();return M(a.targetUrlCtrl,e)||(a.targetUrlCtrl=e),c(e)}),r()()(),s(9,"footer",46)(10,"button",26),d("click",function(){_(t);let e=l();return c(e.closeTargetUrlDialog(!1))}),I(11,"Cancel"),r(),s(12,"button",47),d("click",function(){_(t);let e=l();return c(e.closeTargetUrlDialog(!0))}),u(13,13),g(14,"sh-icon"),T(),r()()()}if(i&2){let t=l();A("isOpen",t.targetUrlDialogOpen),h("options",tt(3,Nt)),F(8),A("ngModel",t.targetUrlCtrl)}}var G=class i{#i=O(it);#o=O(nt);#e=O(rt);#a=O(pt);injector=O(K);#t=O(ht);#s=O(Ot);formRef=et.required("formRef");targetUrlModel=this.#t.destinationTargetUrl;targetUrlCtrl=C(null);targetUrlInitial=C(null);targetUrlDialogOpen=C(!1);toggleNewDestination=C(!0);testSignal=this.#t.testSignal;testErrorMessage=this.#t.testErrorMessage;destinationTypeOptionsInFocus=C(["file","ssh","s3","gcs","googledrive","azure"]);destinationTypeOptions=this.#s.destinationTypeOptions;destinationTypeOptionsFocused=v(()=>{let n=this.destinationTypeOptionsInFocus(),t=this.destinationTypeOptions();return n.map(o=>t.find(e=>e.key===o))});selectedDestinationType=v(()=>{let n=this.#t.destinationTargetUrl();if(!n)return null;let t=n.split("://")[0];return Dt(t)});copyTargetUrl(){navigator.clipboard.writeText(this.#t.destinationTargetUrl()??"")}openTargetUrlDialog(){let n=this.#t.destinationTargetUrl();this.targetUrlCtrl.set(n),this.targetUrlInitial.set(n),this.targetUrlDialogOpen.set(!0)}closeTargetUrlDialog(n=!1){this.targetUrlDialogOpen.set(!1);let t=this.targetUrlCtrl(),o=this.targetUrlInitial();!n||t===o||!t||this.#t.updateTargetUrl(t)}testDestination(n,t,o){let e=this.#t.destinationTargetUrl();e&&(this.#t.setTestState("testing"),this.#a.testDestination(e,n,!0,t).subscribe({next:a=>{if(a.action==="success"){this.#t.setTestState("success"),a.containsBackup===!1?(this.#t.setTestState("warning",$localize`The remote destination does not contain any backups. Please check if the destination details are correct.`),t||this.#e.open(m,{data:{title:$localize`Folder contains no backup`,message:$localize`The remote destination does not contain any backups. Please check if the destination details are correct.`,confirmText:$localize`OK`,cancelText:void 0}})):a.anyFilesFound===!1&&(this.#t.setTestState("warning",$localize`The remote destination is empty. Please check if the destination details are correct.`),t||this.#e.open(m,{data:{title:$localize`Folder is empty`,message:$localize`The remote destination is empty. Please check if the destination details are correct.`,confirmText:$localize`OK`,cancelText:void 0}})),o?.();return}if(this.#t.setTestState("error",a.errorMessage??$localize`An error occurred while testing the destination.`),a.action==="generic-error"){o?.();return}let R=e.includes("?");a.action==="trust-cert"&&this.#t.updateTargetUrl(e+`${R?"&":"?"}accept-specified-ssl-hash=${a.certData}`),a.action==="approve-host-key"&&this.#t.updateTargetUrl(e+`${R?"&":"?"}ssh-fingerprint=${a.reportedHostKey}`),a.testAgain?this.testDestination(a.destinationIndex,t):o?.()}}))}setDestination(n){this.#t.updateTargetUrl(`${n}://`)}removeDestination(){this.#t.updateTargetUrl(null)}goBack(){this.#i.navigate(["general"],{relativeTo:this.#o.parent})}next(){let n=this.testSignal();if(n===""){this.#e.open(m,{data:{title:$localize`Test destination`,message:$localize`You have not tested the destination yet. Do you want to test it now?`,confirmText:$localize`Test now`,cancelText:$localize`Skip test and continue`},closed:t=>{t?this.testDestination(0,!1,()=>{this.testSignal()==="success"?this.#n():this.#e.open(m,{data:{title:$localize`Test did not succeed`,message:this.testErrorMessage()??$localize`Failed to test the destination.`,confirmText:$localize`OK`,cancelText:void 0}})}):this.#n()}});return}if(n!=="success"){this.#e.open(m,{data:{title:$localize`Test destination`,message:$localize`The destination has not been tested successfully. Are you sure you want to continue?`,confirmText:$localize`Yes, continue`,cancelText:$localize`Cancel`},closed:t=>{t&&this.#n()}});return}this.#n()}#n(){this.#i.navigate(["encryption"],{relativeTo:this.#o.parent})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=j({type:i,selectors:[["app-restore-destination"]],viewQuery:function(t,o){t&1&&Q(o.formRef,It,5),t&2&&q()},features:[Z([Et,{provide:mt,useClass:Ct}])],decls:30,vars:9,consts:()=>{let n;n=$localize` Backup destination ${"\uFFFD#5\uFFFD"}:START_TAG_DIV:${"[\uFFFD*6:1\uFFFD|\uFFFD*13:2\uFFFD]"}:START_BLOCK_IF:${"\uFFFD#1:1\uFFFD"}:START_TAG_BUTTON: Test destination ${"[\uFFFD/#1:1\uFFFD|\uFFFD/#8\uFFFD|\uFFFD/#11\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_BUTTON:${"[\uFFFD/*6:1\uFFFD|\uFFFD/*13:2\uFFFD]"}:CLOSE_BLOCK_IF:${"\uFFFD#7\uFFFD"}:START_TAG_SH_MENU:${"\uFFFD#8\uFFFD"}:START_TAG_BUTTON_1:${"[\uFFFD#9\uFFFD|\uFFFD#12\uFFFD|\uFFFD#2:2\uFFFD]"}:START_TAG_SH_ICON:dots-three-vertical${"[\uFFFD/#9\uFFFD|\uFFFD/#12\uFFFD|\uFFFD/#2:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"[\uFFFD/#1:1\uFFFD|\uFFFD/#8\uFFFD|\uFFFD/#11\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_BUTTON:${"\uFFFD#10\uFFFD"}:START_TAG_NG_CONTAINER:${"\uFFFD#11\uFFFD"}:START_TAG_BUTTON_2:${"[\uFFFD#9\uFFFD|\uFFFD#12\uFFFD|\uFFFD#2:2\uFFFD]"}:START_TAG_SH_ICON:link${"[\uFFFD/#9\uFFFD|\uFFFD/#12\uFFFD|\uFFFD/#2:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Edit target URL ${"[\uFFFD/#1:1\uFFFD|\uFFFD/#8\uFFFD|\uFFFD/#11\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_BUTTON:${"[\uFFFD*6:1\uFFFD|\uFFFD*13:2\uFFFD]"}:START_BLOCK_IF:${"\uFFFD#1:2\uFFFD"}:START_TAG_BUTTON_3:${"[\uFFFD#9\uFFFD|\uFFFD#12\uFFFD|\uFFFD#2:2\uFFFD]"}:START_TAG_SH_ICON:copy${"[\uFFFD/#9\uFFFD|\uFFFD/#12\uFFFD|\uFFFD/#2:2\uFFFD]"}:CLOSE_TAG_SH_ICON: Copy url to clipboard ${"[\uFFFD/#1:1\uFFFD|\uFFFD/#8\uFFFD|\uFFFD/#11\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_BUTTON:${"[\uFFFD/*6:1\uFFFD|\uFFFD/*13:2\uFFFD]"}:CLOSE_BLOCK_IF:${"\uFFFD/#10\uFFFD"}:CLOSE_TAG_NG_CONTAINER:${"\uFFFD/#7\uFFFD"}:CLOSE_TAG_SH_MENU:${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_DIV:`,n=B(n);let t;t=$localize`${"\uFFFD#24\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#24\uFFFD"}:CLOSE_TAG_SH_ICON: Go back `;let o;o=$localize`${"\uFFFD*27:1\uFFFD"}:START_BLOCK_IF:${"\uFFFD#1:1\uFFFD"}:START_TAG_SH_ICON:spinner${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*27:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*28:2\uFFFD"}:START_BLOCK_ELSE:${"\uFFFD#1:2\uFFFD"}:START_TAG_SH_ICON_1:arrow-right${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*28:2\uFFFD"}:CLOSE_BLOCK_ELSE: Continue `,o=B(o);let e;e=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:spinner${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Testing connection... `;let a;a=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:check${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Connection tested successfully. `;let R;R=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:warning${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: ${"\uFFFD0\uFFFD"}:INTERPOLATION: `;let U;U=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:warning${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: ${"\uFFFD0\uFFFD"}:INTERPOLATION: `;let V;V=$localize` Current destination type ${"\uFFFD#2\uFFFD"}:START_TAG_STRONG:${"\uFFFD0\uFFFD"}:INTERPOLATION:.${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_STRONG:${"\uFFFD#3\uFFFD\uFFFD/#3\uFFFD"}:LINE_BREAK: Want to select another? ${"\uFFFD#4\uFFFD"}:START_TAG_SPAN:Click here${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_SPAN:`;let W;W=$localize`All destinations`;let z;z=$localize`Edit target URL`;let H;H=$localize`Be careful, this will overwrite everything you have in your destination.`;let X;return X=$localize` Override target URL ${"\uFFFD#14\uFFFD"}:START_TAG_SH_ICON:swap${"\uFFFD/#14\uFFFD"}:CLOSE_TAG_SH_ICON:`,[["formRef",""],["option",""],n,t,o,e,a,R,U,V,W,z,H,X,[3,"submit"],[1,"title-30"],[1,"actions"],["shButton","","type","button",1,"small",3,"disabled","loader"],["shButton","","type","button",1,"small"],["menu",""],["shButton","","type","button",1,"small",3,"click"],[1,"success"],[1,"warn"],[1,"error"],[3,"targetUrl"],[1,"form-actions"],["shButton","","type","button",3,"click"],["shButton","","type","submit",1,"raised","primary",3,"disabled"],[1,"loader"],[3,"isOpen","options"],["shButton","","type","button",1,"small",3,"click","disabled"],["icon",""],[3,"click"],[1,"sh-primary"],[1,"most-common-destinations"],[1,"tile"],[3,"searchable"],["shButton","","type","button",1,"outlined"],["type","button"],[1,"tile",3,"click"],["type","button",3,"click"],[3,"targetUrlChange","targetUrl"],[3,"isOpenChange","isOpen","options"],["header",""],["content",""],["id","targetUrl","autocomplete","off",3,"ngModelChange","ngModel"],["footer",""],["shButton","","type","submit",1,"raised","primary",3,"click"]]},template:function(t,o){if(t&1){let e=p();s(0,"form",14,0),d("submit",function(){return _(e),c(o.next())}),s(2,"header")(3,"h3",15),u(4,2),s(5,"div",16),D(6,ft,2,3,"button",17),s(7,"sh-menu")(8,"button",18),g(9,"sh-icon"),r(),w(10,19),s(11,"button",20),d("click",function(){return _(e),c(o.openTargetUrlDialog())}),g(12,"sh-icon"),r(),D(13,$t,3,0,"button",18),b(),r()(),T(),r(),D(14,At,3,0,"sh-alert")(15,Mt,3,0,"sh-alert",21)(16,yt,3,1,"sh-alert",22)(17,Pt,3,1,"sh-alert",23),D(18,xt,5,1,"p"),r(),D(19,bt,9,1),D(20,Bt,1,1,"app-single-destination",24),s(21,"div",25)(22,"button",26),d("click",function(){return _(e),c(o.goBack())}),u(23,3),g(24,"sh-icon"),T(),r(),s(25,"button",27),u(26,4),D(27,kt,2,0,"sh-icon",28)(28,vt,2,0,"sh-icon"),T(),r()()(),D(29,Gt,15,4,"sh-dialog",29)}if(t&2){let e=!!o.targetUrlModel();F(6),E(e?6:-1),F(7),E(e?13:-1),F(),E(o.testSignal()=="testing"?14:o.testSignal()=="success"?15:o.testSignal()=="warning"?16:o.testSignal()=="error"?17:-1),F(4),E(e?18:-1),F(),E(e?-1:19),F(),E(e?20:-1),F(5),h("disabled",o.testSignal()=="testing"||!e),F(2),E(o.testSignal()=="testing"?27:28),F(2),E(o.targetUrlDialogOpen()?29:-1)}},dependencies:[Rt,dt,St,_t,ct,ut,gt,Tt,Ft,lt,ot,st,at],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:32.5rem;padding:2.5rem}header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%], header[_ngcontent-%COMP%] sh-alert[_ngcontent-%COMP%]{width:100%}header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;gap:.5rem}header[_ngcontent-%COMP%] p[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{cursor:pointer;text-decoration:underline}header[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}pre[_ngcontent-%COMP%]{white-space:pre-wrap}.field-row[_ngcontent-%COMP%]{display:grid;align-items:flex-end;grid-template-columns:1fr 2.5rem;gap:.5rem}.field-row.single-field[_ngcontent-%COMP%]{display:block}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}.clickable[_ngcontent-%COMP%]{cursor:pointer;color:var(--primary-8)}.most-common-destinations[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem}.most-common-destinations[_ngcontent-%COMP%] .tile[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;padding:1rem;border:1px solid var(--base-4);border-radius:var(--shape-3);box-shadow:var(--box-shadow-10);background-color:var(--base-2);cursor:pointer}.most-common-destinations[_ngcontent-%COMP%] .tile[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-10);margin:0}[prefix].link[_ngcontent-%COMP%]{cursor:pointer;text-decoration:underline;color:var(--primary-8)}textarea[_ngcontent-%COMP%] ~ grammarly-extension[_ngcontent-%COMP%]{display:none}"],changeDetection:0})};export{G as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as xt,b as Lt,c as Rt,d as Ut,e as wt}from"./chunk-QYI4IMJE.js";import"./chunk-7IQY6U5W.js";import"./chunk-OMMUXRXE.js";import{a as Pt}from"./chunk-KDYD6LMI.js";import{h as Bt}from"./chunk-MSLKIHQQ.js";import"./chunk-N6ABN43N.js";import"./chunk-DDWLL7XA.js";import"./chunk-2QJC4PGQ.js";import"./chunk-O64ZZGQZ.js";import{a as $}from"./chunk-DELLEGXW.js";import"./chunk-RHW5QVAY.js";import"./chunk-VTSUHAP5.js";import{c as b,e as v,f as At,g as $t,i as k,j as Mt,r as yt,s as G}from"./chunk-N5SC4SKW.js";import{b as St,d as Ct}from"./chunk-LVP2TPMO.js";import"./chunk-43JMN2ZY.js";import{a as U,b as ht,d as It,e as Nt,g as ft,h as Ot,l as w,o as Et}from"./chunk-H7K35UUX.js";import"./chunk-NOPMCS2Z.js";import"./chunk-RUXCS4ZK.js";import"./chunk-FPPZ4BUR.js";import{Ab as s,Bb as F,Cb as c,Gb as Ft,Hb as rt,Jb as g,Oa as it,Oc as L,Qb as u,Ra as r,Rb as _,Sb as B,Tb as z,Tc as gt,Ub as H,Uc as pt,Vb as X,Vc as mt,Wb as D,Yb as l,Zb as lt,_ as C,_b as ct,bb as f,ea as d,ec as ut,fa as T,fc as _t,ia as nt,ic as dt,lc as x,mc as W,oa as I,qc as O,rc as E,sc as A,tc as j,ub as m,uc as q,vb as S,vc as R,wb as ot,wc as Q,xb as at,yb as st,yc as Tt,zb as h,zc as Dt}from"./chunk-HNWRQABR.js";import"./chunk-EUDKD2JW.js";var kt=["*"],M=class o{destination=pt.required();static \u0275fac=function(t){return new(t||o)};static \u0275cmp=f({type:o,selectors:[["app-destination-list-item"]],inputs:{destination:[1,"destination"]},ngContentSelectors:kt,decls:9,vars:6,consts:[[1,"type-b"],[1,"icon"],[3,"src","alt"],[1,"name"],[1,"description"],[1,"actions"]],template:function(t,n){if(t&1&&(lt(),s(0,"sh-card",0)(1,"div",1),c(2,"img",2),F(),s(3,"div",3),x(4),F(),s(5,"div",4),x(6),F(),s(7,"div",5),ct(8),F()()),t&2){let i=n.destination();r(2),h("src",Q(i.icon),it)("alt",Q(i.displayName)),r(2),W(i.displayName),r(2),W(i.description)}},dependencies:[Ot],styles:['[_nghost-%COMP%]{display:block}sh-card[_ngcontent-%COMP%]{display:grid;align-items:center;grid-template-columns:3rem 1fr auto;grid-template-areas:"icon name actions" "icon description actions";gap:.25rem 1rem}sh-card[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{grid-area:icon;display:flex;align-items:center;justify-content:center;width:3rem;height:3rem;border-radius:var(--shape-2)}sh-card[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{object-fit:contain;width:100%;border-radius:var(--shape-2);overflow:hidden}sh-card[_ngcontent-%COMP%] .name[_ngcontent-%COMP%]{grid-area:name;font:var(--paragraph-10)}sh-card[_ngcontent-%COMP%] .description[_ngcontent-%COMP%]{grid-area:description;color:var(--base-8)}sh-card[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{grid-area:actions;display:flex;align-items:center;gap:.5rem}'],changeDetection:0})};function Kt(o,e){if(o&1){let t=g();s(0,"app-destination-list-item",3)(1,"button",4),D("click",function(){let i=d(t).$implicit,a=l();return T(a.setDestination.emit(i.key))}),u(2,0),c(3,"sh-icon"),_(),F()()}if(o&2){let t=e.$implicit;h("destination",t)}}var K=class o{#i=C(Lt);setDestination=gt();destinationSearchTerm=I("");destinationTypeOptionsInFocus=I(["file","ssh","s3","gcs","googledrive","azure"]);destinationTypeOptions=this.#i.destinationTypeOptions;destinationTypeOptionsFocused=L(()=>{let e=new Set(this.destinationTypeOptionsInFocus()),t=this.destinationTypeOptions(),n=this.destinationSearchTerm().toLowerCase(),i=[...t].sort((a,N)=>{let y=e.has(a.key),P=e.has(N.key);return y&&!P?-1:!y&&P?1:0});return n?i.filter(a=>a.displayName.toLowerCase().includes(n)):i});static \u0275fac=function(t){return new(t||o)};static \u0275cmp=f({type:o,selectors:[["app-destination-list"]],outputs:{setDestination:"setDestination"},decls:5,vars:1,consts:()=>{let e;e=$localize`Search for destination...`;let t;return t=$localize` Choose ${"\uFFFD#3\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#3\uFFFD"}:CLOSE_TAG_SH_ICON:`,[t,["type","text","placeholder",e,3,"ngModelChange","ngModel"],[1,"list"],[3,"destination"],["shButton","","type","button",3,"click"]]},template:function(t,n){t&1&&(s(0,"sh-form-field")(1,"input",1),A("ngModelChange",function(a){return E(n.destinationSearchTerm,a)||(n.destinationSearchTerm=a),a}),F()(),s(2,"div",2),at(3,Kt,4,1,"app-destination-list-item",3,ot),F()),t&2&&(r(),O("ngModel",n.destinationSearchTerm),r(2),st(n.destinationTypeOptionsFocused()))},dependencies:[M,G,b,v,k,w,ft,U],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:1rem;height:100%;overflow:hidden}.list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem;height:100%;overflow:auto;padding-bottom:1rem;border-bottom:.0625rem solid var(--base-4)}"],changeDetection:0})};var Vt=["formRef"],zt=()=>({maxWidth:"700px",width:"100%"});function Ht(o,e){if(o&1){let t=g();u(0,1,1),s(1,"button",28),D("click",function(){d(t);let i=l();return T(i.testDestination(0,!0))}),F(),_()}if(o&2){let t=l();r(),dt("loader",t.testSignal()=="testing"),h("disabled",t.testSignal()=="testing")}}function Xt(o,e){if(o&1){let t=g();u(0,1,2),s(1,"button",29),D("click",function(){d(t);let i=l();return T(i.openTargetUrlDialog())}),c(2,"sh-icon"),F(),_()}}function Wt(o,e){if(o&1){let t=g();u(0,1,4),s(1,"button",29),D("click",function(){d(t);let i=l(2);return T(i.copyTargetUrl())}),c(2,"sh-icon"),F(),_()}}function jt(o,e){if(o&1){let t=g();u(0,1,3),s(1,"sh-menu")(2,"button",17),c(3,"sh-icon"),F(),Ft(4,30),s(5,"button",29),D("click",function(){d(t);let i=l();return T(i.openTargetUrlDialog())}),c(6,"sh-icon"),F(),m(7,Wt,3,0,"button",17),rt(),F(),_()}if(o&2){l();let t=R(0);r(7),S(t?7:-1)}}function qt(o,e){o&1&&(s(0,"sh-alert"),u(1,4),c(2,"sh-icon",31),_(),F())}function Qt(o,e){o&1&&(s(0,"sh-alert",18),u(1,5),c(2,"sh-icon",31),_(),F())}function Yt(o,e){if(o&1&&(s(0,"sh-alert",19),u(1,6),c(2,"sh-icon",31),_(),F()),o&2){let t=l();r(2),z(t.testErrorMessage()),H(1)}}function Jt(o,e){if(o&1&&(s(0,"sh-alert",20),u(1,7),c(2,"sh-icon",31),_(),F()),o&2){let t=l();r(2),z(t.testErrorMessage()),H(1)}}function Zt(o,e){if(o&1){let t=g();s(0,"app-destination-list-item",21)(1,"button",24),D("click",function(){d(t);let i=l();return T(i.removeDestination())}),B(2,8),F()()}if(o&2){l();let t=R(14);h("destination",t)}}function te(o,e){if(o&1){let t=g();s(0,"app-destination-list",32),D("setDestination",function(i){d(t);let a=l();return T(a.setDestination(i))}),F()}}function ee(o,e){if(o&1){let t=g();s(0,"app-single-destination",33),A("targetUrlChange",function(i){d(t);let a=l();return E(a.targetUrlModel,i)||(a.targetUrlModel=i),T(i)}),F()}if(o&2){let t=l();O("targetUrl",t.targetUrlModel)}}function ne(o,e){o&1&&(u(0,3,1),c(1,"sh-icon",26),_())}function ie(o,e){o&1&&(u(0,3,2),c(1,"sh-icon"),_())}function oe(o,e){o&1&&(s(0,"h2"),B(1,11),F())}function ae(o,e){o&1&&(s(0,"h2"),B(1,12),F())}function se(o,e){if(o&1){let t=g();s(0,"sh-dialog",34),A("isOpenChange",function(i){d(t);let a=l();return E(a.targetUrlDialogOpen,i)||(a.targetUrlDialogOpen=i),T(i)}),s(1,"header",35),m(2,oe,2,0,"h2")(3,ae,2,0,"h2"),s(4,"sh-alert",19),B(5,9),F()(),s(6,"div",36)(7,"sh-form-field")(8,"textarea",37),A("ngModelChange",function(i){d(t);let a=l();return E(a.targetUrlCtrl,i)||(a.targetUrlCtrl=i),T(i)}),F()()(),s(9,"footer",38)(10,"button",24),D("click",function(){d(t);let i=l();return T(i.closeTargetUrlDialog(!1))}),x(11,"Cancel"),F(),s(12,"button",39),D("click",function(){d(t);let i=l();return T(i.closeTargetUrlDialog(!0))}),u(13,10),c(14,"sh-icon"),_(),F()()()}if(o&2){let t=l(),n=R(0);O("isOpen",t.targetUrlDialogOpen),h("options",Dt(4,zt)),r(2),S(n?3:2),r(6),O("ngModel",t.targetUrlCtrl)}}var V=new yt,we=(o={destinations:[]})=>V.group({destinations:V.array(o.destinations)}),be=({key:o,customGroup:e,dynamicGroup:t,advancedGroup:n})=>V.group({destinationType:V.control(o),custom:e,dynamic:t,advanced:n}),Y=class o{#i=C(Ct);#o=C(St);#t=C(Bt);#e=C(Nt);#a=C(xt);injector=C(nt);formRef=mt.required("formRef");targetUrlModel=this.#t.targetUrlModel;targetUrlCtrl=I(null);targetUrlInitial=I(null);targetUrlDialogOpen=I(!1);toggleNewDestination=I(!0);testSignal=this.#t.testSignal;testErrorMessage=this.#t.testErrorMessage;selectedDestinationType=L(()=>{let e=this.targetUrlModel();if(!e)return null;let t=e.split("://")[0];return Pt(t)??null});selectedDestinationTypeOption=L(()=>{let e=this.selectedDestinationType();return e?{key:e.customKey??e.key,customKey:e.customKey??null,displayName:e.displayName,description:e.description,icon:e.icon}:null});copyTargetUrl(){navigator.clipboard.writeText(this.targetUrlModel()??"")}openTargetUrlDialog(){let e=this.targetUrlModel();this.targetUrlCtrl.set(e),this.targetUrlInitial.set(e),this.targetUrlDialogOpen.set(!0)}closeTargetUrlDialog(e=!1){this.targetUrlDialogOpen.set(!1);let t=this.targetUrlCtrl(),n=this.targetUrlInitial();!e||t===n||!t||this.#t.setTargetUrl(t)}testDestination(e,t,n){let i=this.targetUrlModel();i&&(this.#t.setTestState("testing"),this.#a.testDestination(i,e,!0,!0).subscribe({next:a=>{if(a.action==="success"){this.#t.setTestState("success"),this.#t.isNew()&&(a.containsBackup===!0?(this.#t.setTestState("warning",$localize`The remote destination already contains a backup. Please use a different folder for each backup.`),t||this.#e.open($,{data:{title:$localize`Folder contains backup`,message:$localize`The remote destination already contains a backup. You must use a different folder for each backup.`,confirmText:$localize`OK`,cancelText:void 0}})):a.anyFilesFound===!0&&(this.#t.setTestState("warning",$localize`The remote destination contains unknown files.`),t||this.#e.open($,{data:{title:$localize`Folder is not empty`,message:$localize`The remote destination is not empty. It is recommended to use an empty folder for the backup.`,confirmText:$localize`OK`,cancelText:void 0}}))),n?.();return}if(this.#t.setTestState("error",a.errorMessage??$localize`An error occurred while testing the destination.`),a.action==="generic-error"){n?.();return}let N=i.includes("?");a.action==="trust-cert"&&this.#t.setTargetUrl(i+`${N?"&":"?"}accept-specified-ssl-hash=${a.certData}`),a.action==="approve-host-key"&&this.#t.setTargetUrl(i+`${N?"&":"?"}ssh-fingerprint=${a.reportedHostKey}`),a.testAgain?this.testDestination(a.destinationIndex,t):n?.()}}))}setDestination(e){this.#t.setTargetUrl(`${e}://`,!0)}removeDestination(){this.#t.setTargetUrl(null,!0)}goBack(){this.#i.navigate(["general"],{relativeTo:this.#o.parent})}next(){let e=this.#t.isNew(),t=this.testSignal();if(!e){this.#n();return}if(t===""){this.#e.open($,{data:{title:$localize`Test destination`,message:$localize`You have not tested the destination yet. Do you want to test it now?`,confirmText:$localize`Test now`,cancelText:$localize`Skip test and continue`},closed:n=>{n?this.testDestination(0,!1,()=>{this.testSignal()==="success"?this.#n():this.#e.open($,{data:{title:$localize`Test did not succeed`,message:this.testErrorMessage()??$localize`Failed to test the destination.`,confirmText:$localize`OK`,cancelText:void 0}})}):this.#n()}});return}if(t!=="success"){this.#e.open($,{data:{title:$localize`Test destination`,message:$localize`The destination has not been tested successfully. Are you sure you want to continue?`,confirmText:$localize`Yes, continue`,cancelText:$localize`Cancel`},closed:n=>{n&&this.#n()}});return}this.#n()}#n(){this.#t.isNew()||this.#t.submit(!0),this.#i.navigate(["source-data"],{relativeTo:this.#o.parent})}static \u0275fac=function(t){return new(t||o)};static \u0275cmp=f({type:o,selectors:[["app-destination"]],viewQuery:function(t,n){t&1&&ut(n.formRef,Vt,5),t&2&&_t()},features:[Tt([{provide:Ut,useClass:Rt}])],decls:27,vars:11,consts:()=>{let e;e=$localize` Backup destination ${"\uFFFD#6\uFFFD"}:START_TAG_DIV:${"[\uFFFD*7:1\uFFFD|\uFFFD*7:4\uFFFD]"}:START_BLOCK_IF:${"\uFFFD#1:1\uFFFD"}:START_TAG_BUTTON: Test destination ${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD|\uFFFD/#2:3\uFFFD|\uFFFD/#5:3\uFFFD|\uFFFD/#1:4\uFFFD]"}:CLOSE_TAG_BUTTON:${"[\uFFFD/*7:1\uFFFD|\uFFFD/*8:2\uFFFD|\uFFFD/*7:4\uFFFD]"}:CLOSE_BLOCK_IF:${"\uFFFD*8:2\uFFFD"}:START_BLOCK_IF_1:${"[\uFFFD#1:2\uFFFD|\uFFFD#5:3\uFFFD]"}:START_TAG_BUTTON_1:${"[\uFFFD#2:2\uFFFD|\uFFFD#3:3\uFFFD|\uFFFD#6:3\uFFFD|\uFFFD#2:4\uFFFD]"}:START_TAG_SH_ICON:link${"[\uFFFD/#2:2\uFFFD|\uFFFD/#3:3\uFFFD|\uFFFD/#6:3\uFFFD|\uFFFD/#2:4\uFFFD]"}:CLOSE_TAG_SH_ICON: Set target URL ${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD|\uFFFD/#2:3\uFFFD|\uFFFD/#5:3\uFFFD|\uFFFD/#1:4\uFFFD]"}:CLOSE_TAG_BUTTON:${"[\uFFFD/*7:1\uFFFD|\uFFFD/*8:2\uFFFD|\uFFFD/*7:4\uFFFD]"}:CLOSE_BLOCK_IF:${"\uFFFD*9:3\uFFFD"}:START_BLOCK_ELSE:${"\uFFFD#1:3\uFFFD"}:START_TAG_SH_MENU:${"\uFFFD#2:3\uFFFD"}:START_TAG_BUTTON_2:${"[\uFFFD#2:2\uFFFD|\uFFFD#3:3\uFFFD|\uFFFD#6:3\uFFFD|\uFFFD#2:4\uFFFD]"}:START_TAG_SH_ICON:dots-three-vertical${"[\uFFFD/#2:2\uFFFD|\uFFFD/#3:3\uFFFD|\uFFFD/#6:3\uFFFD|\uFFFD/#2:4\uFFFD]"}:CLOSE_TAG_SH_ICON:${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD|\uFFFD/#2:3\uFFFD|\uFFFD/#5:3\uFFFD|\uFFFD/#1:4\uFFFD]"}:CLOSE_TAG_BUTTON:${"\uFFFD#4:3\uFFFD"}:START_TAG_NG_CONTAINER:${"[\uFFFD#1:2\uFFFD|\uFFFD#5:3\uFFFD]"}:START_TAG_BUTTON_1:${"[\uFFFD#2:2\uFFFD|\uFFFD#3:3\uFFFD|\uFFFD#6:3\uFFFD|\uFFFD#2:4\uFFFD]"}:START_TAG_SH_ICON:link${"[\uFFFD/#2:2\uFFFD|\uFFFD/#3:3\uFFFD|\uFFFD/#6:3\uFFFD|\uFFFD/#2:4\uFFFD]"}:CLOSE_TAG_SH_ICON: Edit target URL ${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD|\uFFFD/#2:3\uFFFD|\uFFFD/#5:3\uFFFD|\uFFFD/#1:4\uFFFD]"}:CLOSE_TAG_BUTTON:${"[\uFFFD*7:1\uFFFD|\uFFFD*7:4\uFFFD]"}:START_BLOCK_IF:${"\uFFFD#1:4\uFFFD"}:START_TAG_BUTTON_3:${"[\uFFFD#2:2\uFFFD|\uFFFD#3:3\uFFFD|\uFFFD#6:3\uFFFD|\uFFFD#2:4\uFFFD]"}:START_TAG_SH_ICON:copy${"[\uFFFD/#2:2\uFFFD|\uFFFD/#3:3\uFFFD|\uFFFD/#6:3\uFFFD|\uFFFD/#2:4\uFFFD]"}:CLOSE_TAG_SH_ICON: Copy url to clipboard ${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD|\uFFFD/#2:3\uFFFD|\uFFFD/#5:3\uFFFD|\uFFFD/#1:4\uFFFD]"}:CLOSE_TAG_BUTTON:${"[\uFFFD/*7:1\uFFFD|\uFFFD/*8:2\uFFFD|\uFFFD/*7:4\uFFFD]"}:CLOSE_BLOCK_IF:${"\uFFFD/#4:3\uFFFD"}:CLOSE_TAG_NG_CONTAINER:${"\uFFFD/#1:3\uFFFD"}:CLOSE_TAG_SH_MENU:${"\uFFFD/*9:3\uFFFD"}:CLOSE_BLOCK_ELSE:${"\uFFFD/#6\uFFFD"}:CLOSE_TAG_DIV:`,e=X(e);let t;t=$localize`${"\uFFFD#21\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#21\uFFFD"}:CLOSE_TAG_SH_ICON: Go back `;let n;n=$localize`${"\uFFFD*24:1\uFFFD"}:START_BLOCK_IF:${"\uFFFD#1:1\uFFFD"}:START_TAG_SH_ICON:spinner${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*24:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*25:2\uFFFD"}:START_BLOCK_ELSE:${"\uFFFD#1:2\uFFFD"}:START_TAG_SH_ICON_1:arrow-right${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*25:2\uFFFD"}:CLOSE_BLOCK_ELSE: Continue `,n=X(n);let i;i=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:spinner${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Testing connection... `;let a;a=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:check${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Connection tested successfully. `;let N;N=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:warning${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: ${"\uFFFD0\uFFFD"}:INTERPOLATION: `;let y;y=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:warning${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: ${"\uFFFD0\uFFFD"}:INTERPOLATION: `;let P;P=$localize`Change`;let J;J=$localize`Be careful, this will overwrite everything you have in your destination.`;let Z;Z=$localize` Override target URL ${"\uFFFD#14\uFFFD"}:START_TAG_SH_ICON:swap${"\uFFFD/#14\uFFFD"}:CLOSE_TAG_SH_ICON:`;let tt;tt=$localize`Set target URL`;let et;return et=$localize`Edit target URL`,[["formRef",""],e,t,n,i,a,N,y,P,J,Z,tt,et,[3,"submit"],[1,"title-30"],[1,"actions"],["shButton","","type","button",1,"small",3,"loader","disabled"],["shButton","","type","button",1,"small"],[1,"success"],[1,"warn"],[1,"error"],[1,"current-destination",3,"destination"],[3,"targetUrl"],[1,"form-actions"],["shButton","","type","button",3,"click"],["shButton","","type","submit",1,"raised","primary",3,"disabled"],[1,"loader"],[3,"isOpen","options"],["shButton","","type","button",1,"small",3,"click","disabled"],["shButton","","type","button",1,"small",3,"click"],["menu",""],["icon",""],[3,"setDestination"],[3,"targetUrlChange","targetUrl"],[3,"isOpenChange","isOpen","options"],["header",""],["content",""],["id","targetUrl","autocomplete","off",3,"ngModelChange","ngModel"],["footer",""],["shButton","","type","submit",1,"raised","primary",3,"click"]]},template:function(t,n){if(t&1){let i=g();j(0),s(1,"form",13,0),D("submit",function(){return d(i),T(n.next())}),s(3,"header")(4,"h3",14),u(5,1),s(6,"div",15),m(7,Ht,2,3,"button",16),m(8,Xt,3,0,"button",17)(9,jt,8,1,"sh-menu"),F(),_(),F(),m(10,qt,3,0,"sh-alert")(11,Qt,3,0,"sh-alert",18)(12,Yt,3,1,"sh-alert",19)(13,Jt,3,1,"sh-alert",20),j(14),m(15,Zt,3,1,"app-destination-list-item",21),F(),m(16,te,1,0,"app-destination-list"),m(17,ee,1,1,"app-single-destination",22),s(18,"div",23)(19,"button",24),D("click",function(){return d(i),T(n.goBack())}),u(20,2),c(21,"sh-icon"),_(),F(),s(22,"button",25),u(23,3),m(24,ne,2,0,"sh-icon",26)(25,ie,2,0,"sh-icon"),_(),F()()(),m(26,se,15,5,"sh-dialog",27)}if(t&2){let i=q(!!n.targetUrlModel());r(7),S(i?7:-1),r(),S(i?9:8),r(2),S(n.testSignal()=="testing"?10:n.testSignal()=="success"?11:n.testSignal()=="warning"?12:n.testSignal()=="error"?13:-1),r(4);let a=q(n.selectedDestinationTypeOption());r(),S(a?15:-1),r(),S(i?-1:16),r(),S(i?17:-1),r(5),h("disabled",n.testSignal()=="testing"||!i),r(2),S(n.testSignal()=="testing"?24:25),r(2),S(n.targetUrlDialogOpen()?26:-1)}},dependencies:[wt,K,M,G,Mt,b,v,At,k,$t,w,Et,U,It,ht],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:40rem;padding:2.5rem 2.5rem 0}header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%], header[_ngcontent-%COMP%] sh-alert[_ngcontent-%COMP%]{width:100%}header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;gap:.5rem}header[_ngcontent-%COMP%] p[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{cursor:pointer;text-decoration:underline}header[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;height:100%;overflow:hidden;padding:0 0 2.5rem}.current-destination[_ngcontent-%COMP%]{margin:1rem 0 0}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}.most-common-destinations[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem}.most-common-destinations[_ngcontent-%COMP%] .tile[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;padding:1rem;border:1px solid var(--base-4);border-radius:var(--shape-3);box-shadow:var(--box-shadow-10);background-color:var(--base-2);cursor:pointer}.most-common-destinations[_ngcontent-%COMP%] .tile[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-10);margin:0}"],changeDetection:0})};export{we as createDestinationForm,be as createDestinationFormGroup,Y as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as v}from"./chunk-
|
|
1
|
+
import{a as v}from"./chunk-DVDTYV66.js";import"./chunk-UIJYCGKA.js";import"./chunk-RHW5QVAY.js";import"./chunk-VTSUHAP5.js";import{b as k,c as G,e as L,f as w,j as U,o as x,q as j,r as K,t as X}from"./chunk-N5SC4SKW.js";import"./chunk-Z3EPZZGY.js";import"./chunk-UKQFDBNO.js";import{d as A,e as O}from"./chunk-LVP2TPMO.js";import"./chunk-43JMN2ZY.js";import{A as E,a as y,c as N,g as b,l as B,m as R}from"./chunk-H7K35UUX.js";import{h as $}from"./chunk-NOPMCS2Z.js";import"./chunk-RUXCS4ZK.js";import"./chunk-FPPZ4BUR.js";import{Ab as a,Bb as n,Cb as l,H as g,Qb as C,Ra as s,Rb as h,Sb as _,Vb as I,Wb as d,_ as F,bb as T,ic as P,oa as m,ub as S,vb as D,zb as c,zc as M}from"./chunk-HNWRQABR.js";import"./chunk-EUDKD2JW.js";var V=()=>["/"];function z(p,o){p&1&&(a(0,"sh-form-field")(1,"label",14),_(2,3),n(),l(3,"input",15),n())}var u=new K,f=class p{#e=F(N);#o=F($);#n=F(v);#t=F(A);isImporting=m(!1);isSecureFile=m(!1);importForm=u.group({config:u.control(""),cmdline:u.control(!1),import_metadata:u.control(!1),direct:u.control(!1),passphrase:u.control("")});selectedFile=m([]);onFileDropped(o){let e=o[0];if(e){let t=new FileReader;this.isSecureFile.set(e.type!=="application/json"),t.onload=this.#i.bind(this),t.readAsArrayBuffer(e)}}#i(o){let e=o.target?.result;this.isSecureFile.set(this.#r(e)!=="json"),this.importForm.patchValue({config:this.#a(e)})}#r(o){let e=new Uint8Array(o);if(e.length>=5&&e[0]===65&&e[1]===69&&e[2]===83&&e[4]===0)return"aes";try{let t=new TextDecoder().decode(o),i=JSON.parse(t);if(typeof i=="object"&&i!==null)return"json"}catch{}return"unknown"}#a(o){let e=new Uint8Array(o),t=e.byteLength,i="";for(let r=0;r<t;r++)i+=String.fromCharCode(e[r]);return btoa(i)}submit(){this.isImporting.set(!0);let o=this.importForm.value.direct??!1;this.#o.postApiV1BackupsImport({requestBody:this.importForm.value}).pipe(g(()=>this.isImporting.set(!1))).subscribe({next:e=>{if(o){this.#e.success("Backup imported successfully."),this.#t.navigate(["/"]);return}let t=this.#n.addDraftBackup(e.data);this.#t.navigate(["/backup-draft",t])},error:e=>{this.#e.error(e.message)}})}static \u0275fac=function(e){return new(e||p)};static \u0275cmp=T({type:p,selectors:[["app-import"]],decls:19,vars:8,consts:()=>{let o;o=$localize` Import backup configuration ${"\uFFFD#3\uFFFD"}:START_TAG_DIV:${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"[\uFFFD#5\uFFFD|\uFFFD#7\uFFFD]"}:START_TAG_SH_ICON:arrow-left${"[\uFFFD/#5\uFFFD|\uFFFD/#7\uFFFD]"}:CLOSE_TAG_SH_ICON: Back ${"[\uFFFD/#4\uFFFD|\uFFFD/#6\uFFFD]"}:CLOSE_TAG_BUTTON:${"\uFFFD#6\uFFFD"}:START_TAG_BUTTON_1:${"[\uFFFD#5\uFFFD|\uFFFD#7\uFFFD]"}:START_TAG_SH_ICON:download-simple${"[\uFFFD/#5\uFFFD|\uFFFD/#7\uFFFD]"}:CLOSE_TAG_SH_ICON: Import ${"[\uFFFD/#4\uFFFD|\uFFFD/#6\uFFFD]"}:CLOSE_TAG_BUTTON:${"\uFFFD/#3\uFFFD"}:CLOSE_TAG_DIV:`,o=I(o);let e;e=$localize`Import Metadata`;let t;t=$localize`Save now`;let i;return i=$localize`Passphrase`,[o,e,t,i,[1,"actions"],["shButton","","type","button",1,"outlined",3,"routerLink"],["shButton","","type","submit",1,"raised","primary",3,"click","disabled"],["autocomplete","off",3,"formGroup"],["accept",".json,.aes",3,"filesChange","files"],[1,"primary","raised"],["for","importMetadata"],["type","checkbox","formControlName","import_metadata"],["for","direct"],["type","checkbox","formControlName","direct"],["for","passphrase"],["type","password","formControlName","passphrase"]]},template:function(e,t){e&1&&(a(0,"header")(1,"h3"),C(2,0),a(3,"div",4)(4,"button",5),l(5,"sh-icon"),n(),a(6,"button",6),d("click",function(){return t.submit()}),l(7,"sh-icon"),n()(),h(),n()(),a(8,"form",7)(9,"sh-file-upload",8),d("filesChange",function(r){return t.onFileDropped(r)}),n(),S(10,z,4,0,"sh-form-field"),a(11,"sh-toggle",9)(12,"label",10),_(13,1),n(),l(14,"input",11),n(),a(15,"sh-toggle",9)(16,"label",12),_(17,2),n(),l(18,"input",13),n()()),e&2&&(s(4),c("routerLink",M(7,V)),s(2),P("loader",t.isImporting()),c("disabled",t.isImporting()),s(2),c("formGroup",t.importForm),s(),c("files",t.selectedFile()),s(),D(t.isSecureFile()?10:-1))},dependencies:[X,U,G,k,L,w,x,j,O,B,y,b,E,R],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:2rem;padding:3rem}h3[_ngcontent-%COMP%]{font:var(--title-30);display:flex;align-items:center;justify-content:space-between}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;max-width:31.25rem}sh-file-upload[_ngcontent-%COMP%]{width:100%}"],changeDetection:0})};export{f as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as E}from"./chunk-
|
|
1
|
+
import{a as E}from"./chunk-NJEX2N4Q.js";import"./chunk-6LTGTS6B.js";import"./chunk-DVDTYV66.js";import"./chunk-UIJYCGKA.js";import"./chunk-DELLEGXW.js";import"./chunk-RHW5QVAY.js";import"./chunk-VTSUHAP5.js";import"./chunk-UP5EOICU.js";import"./chunk-N5SC4SKW.js";import"./chunk-Z3EPZZGY.js";import"./chunk-UKQFDBNO.js";import{e as S}from"./chunk-LVP2TPMO.js";import"./chunk-43JMN2ZY.js";import{a as T,g as M,h as f}from"./chunk-H7K35UUX.js";import"./chunk-NOPMCS2Z.js";import"./chunk-TDKBGGNK.js";import"./chunk-RUXCS4ZK.js";import"./chunk-FPPZ4BUR.js";import"./chunk-6OPAGPKF.js";import{Ab as e,Bb as n,Cb as _,Qb as l,Ra as s,Rb as d,Sb as i,bb as P,zb as r,zc as u}from"./chunk-HNWRQABR.js";import"./chunk-EUDKD2JW.js";var F=()=>["/backup/new"],N=()=>["/backup/import"],C=class p{static \u0275fac=function(t){return new(t||p)};static \u0275cmp=P({type:p,selectors:[["app-add-backup"]],decls:23,vars:4,consts:()=>{let a;a=$localize`Add a new backup`;let t;t=$localize`New backup`;let c;c=$localize`Configure a new backup. Choose your destination, source data and schedule.`;let A;A=$localize` Add a new backup ${"\uFFFD#13\uFFFD"}:START_TAG_SH_ICON:plus${"\uFFFD/#13\uFFFD"}:CLOSE_TAG_SH_ICON:`;let g;g=$localize`Import from file`;let m;m=$localize`Import backup configuration from a file. During import, you can adjust the settings.`;let D;return D=$localize` Import from file ${"\uFFFD#22\uFFFD"}:START_TAG_SH_ICON:upload-simple${"\uFFFD/#22\uFFFD"}:CLOSE_TAG_SH_ICON:`,[a,t,c,A,g,m,D,[1,"backup-types"],[1,"type-a"],["src","assets/images/new-backup.png"],["shButton","",1,"raised","primary",3,"routerLink"]]},template:function(t,c){t&1&&(_(0,"app-status-bar"),e(1,"section")(2,"h2"),i(3,0),n(),e(4,"div",7)(5,"sh-card",8),_(6,"img",9),e(7,"h3"),i(8,1),n(),e(9,"p"),i(10,2),n(),e(11,"button",10),l(12,3),_(13,"sh-icon"),d(),n()(),e(14,"sh-card",8),_(15,"img",9),e(16,"h3"),i(17,4),n(),e(18,"p"),i(19,5),n(),e(20,"button",10),l(21,6),_(22,"sh-icon"),d(),n()()()()),t&2&&(s(11),r("routerLink",u(2,F)),s(9),r("routerLink",u(3,N)))},dependencies:[E,M,f,T,S],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;align-items:center;flex-direction:column;gap:2rem;padding:2rem 0}div.backup-types[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem;max-width:43.75rem}sh-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;gap:1rem;padding-bottom:3rem}sh-card[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{max-width:18.75rem}sh-card[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-wrap:balance;text-align:center;width:75%}"],changeDetection:0})};export{C as default};
|