@duplicati/ngclient 0.0.115 → 0.0.116
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-36ZCEF76.js +1 -0
- package/chunk-3KPWJPKG.js +1 -0
- package/{chunk-Z75HLGYD.js → chunk-7LOECBLM.js} +1 -1
- package/{chunk-E6YEUK4V.js → chunk-B26K7HTR.js} +1 -1
- package/chunk-BYSLHWG6.js +1 -0
- package/{chunk-GXRQHMLN.js → chunk-CRR7DNOY.js} +1 -1
- package/chunk-CVYWOUO3.js +1 -0
- package/chunk-DJYSOUD7.js +3 -0
- package/{chunk-T5U3AMRL.js → chunk-DL56XS75.js} +1 -1
- package/chunk-DMI4A75F.js +1 -0
- package/{chunk-R43XF3RF.js → chunk-ETELPN3O.js} +1 -1
- package/{chunk-JC5OEIB3.js → chunk-FPFUN6JC.js} +2 -2
- package/chunk-G3SK7TBB.js +1 -0
- package/chunk-GM4QKN65.js +1 -0
- package/{chunk-XMYCIQBS.js → chunk-GVTMU7Q2.js} +1 -1
- package/{chunk-QPMF3OND.js → chunk-GWH2WEBY.js} +1 -1
- package/chunk-GZDT4MSC.js +1 -0
- package/{chunk-NDO7MKXC.js → chunk-HTJ5CVNN.js} +1 -1
- package/{chunk-4E7QE6GD.js → chunk-JDSUBKXI.js} +1 -1
- package/chunk-JOIFJV7F.js +1 -0
- package/chunk-JUVUG5N3.js +1 -0
- package/chunk-JYXXSXNP.js +8 -0
- package/{chunk-FTPARAAG.js → chunk-M5CGJUYP.js} +1 -1
- package/chunk-MZ677J6Y.js +1 -0
- package/chunk-PH5P3W5Z.js +1 -0
- package/{chunk-PHPGQ5OC.js → chunk-RG2UOHQD.js} +1 -1
- package/chunk-RI2SWQGS.js +1 -0
- package/chunk-RNSVPE4U.js +1 -0
- package/{chunk-XER6OR26.js → chunk-S24RG6QP.js} +2 -2
- package/chunk-SFSNPREM.js +1 -0
- package/chunk-SOXAVKMK.js +1 -0
- package/chunk-T6SML6VO.js +1 -0
- package/{chunk-KQCGQDTS.js → chunk-UWRVKCWT.js} +3 -3
- package/chunk-W2YH5ADR.js +1 -0
- package/{chunk-GKYC6XK5.js → chunk-WA5HD4WO.js} +1 -1
- package/{chunk-B2RFNJKM.js → chunk-XVGPU3ZE.js} +1 -1
- package/chunk-XWHL2DXG.js +1 -0
- package/{chunk-WFR2V6TK.js → chunk-Y6ZPPRT6.js} +1 -1
- package/{chunk-PVY4CFCN.js → chunk-Y7K42OXA.js} +1 -1
- package/chunk-Z2ISC3PW.js +1 -0
- package/chunk-ZIR6PET2.js +1 -0
- package/index.html +1 -1
- package/main-7GKFJWB5.js +1 -0
- package/package.json +1 -1
- package/chunk-36NW32TN.js +0 -1
- package/chunk-3MWN54TU.js +0 -1
- package/chunk-4WQHUN4Y.js +0 -1
- package/chunk-7T6RGHZV.js +0 -1
- package/chunk-BEA3HPFS.js +0 -1
- package/chunk-BMGMPYWQ.js +0 -1
- package/chunk-CKS3VATQ.js +0 -1
- package/chunk-CW3Y4RRU.js +0 -8
- package/chunk-EBDDRAQ5.js +0 -1
- package/chunk-FAB4IY5W.js +0 -1
- package/chunk-JXQXCHPY.js +0 -3
- package/chunk-K7WOLKTB.js +0 -1
- package/chunk-KRXMGGJO.js +0 -1
- package/chunk-LRF5G4S6.js +0 -1
- package/chunk-NMMRBG2U.js +0 -1
- package/chunk-RU2M6EPT.js +0 -1
- package/chunk-RUGSDKDK.js +0 -1
- package/chunk-RZ6B5C2M.js +0 -1
- package/chunk-UBBFB6RT.js +0 -1
- package/chunk-URYEQA3U.js +0 -1
- package/chunk-XYLMZK7X.js +0 -1
- package/chunk-Y7YR7HTF.js +0 -1
- package/main-U4R24N47.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as L}from"./chunk-GM4QKN65.js";import{l as T}from"./chunk-JYXXSXNP.js";import"./chunk-PUEJXHBQ.js";import"./chunk-HTJ5CVNN.js";import"./chunk-U467ZTQ4.js";import"./chunk-3KPWJPKG.js";import"./chunk-EQWH3TBL.js";import{a as m}from"./chunk-TQHNKGRL.js";import"./chunk-F2GEUOGZ.js";import"./chunk-PH5P3W5Z.js";import"./chunk-IINSQSHJ.js";import{a as v}from"./chunk-FJVMA6GA.js";import"./chunk-BIZAKOYU.js";import"./chunk-RHW5QVAY.js";import"./chunk-HFIC4JNY.js";import"./chunk-ELMONRIG.js";import"./chunk-BJGA55H2.js";import"./chunk-XP7PWMT2.js";import{b as O,c as B,e as b,f as $}from"./chunk-C6XTRC7P.js";import"./chunk-MAVZY7BL.js";import{p as M,q as N,v as I}from"./chunk-P4ZFQZCA.js";import{h as K}from"./chunk-S5EF63OY.js";import"./chunk-JFNFY6VY.js";import"./chunk-7L2WUS2V.js";import"./chunk-DOP6RFEG.js";import{Db as p,E as C,Eb as s,Fb as r,Pb as d,Pc as E,Qb as c,Ua as n,Wb as R,Z as _,gb as D,ic as A,kc as P,lb as k,tc as h,ub as u,wc as l,zb as g}from"./chunk-L72ALLHJ.js";import"./chunk-7CGTOI24.js";var G=(i,e)=>[i,e,"general"],y=(i,e)=>[i,e,"destination"],U=(i,e)=>[i,e,"source-data"],w=(i,e)=>[i,e,"schedule"],X=(i,e)=>[i,e,"options"];function x(i,e){if(i&1&&(p(0,"p"),A(1),s()),i&2){let a=R();n(),P("Editing: ",a.backupName(),"")}}function z(i,e){i&1&&r(0,"spk-progress-bar",6)}function V(i,e){i&1&&(p(0,"section"),r(1,"router-outlet"),s())}var f=class i{#t=_(O);#e=_(T);#a=_(v);#i=_(K);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=E(()=>{let e=this.#o()?.id,a=!!this.#n()?.find(t=>t.path==="backup-draft");this.#e.backupId.set(e),e!=="new"?this.getBackup(e,a):this.getDefaults()});getDefaults(){this.#i.getApiV1Backupdefaults().pipe(C(1)).subscribe({next:e=>{let a=e.Backup;a.Settings=[...a.Settings,...e.ApplicationOptions.map(t=>({Name:t.Name,Value:t.Value}))],this.#e.mapScheduleToForm(e.Schedule),this.#e.mapOptionsToForms(a),this.#e.backupDefaults.set(e),this.#e.finishedLoading.set(!0)}})}getBackup(e,a=!1){let t=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.finishedLoading.set(!0)};if(a){this.isDraft.set(a);let o=this.#a.draftBackups().find(F=>F.id===e);if(!o){alert("Backup not found");return}t(o.data)}else this.#i.getApiV1BackupById({id:e}).subscribe({next:t})}static \u0275fac=function(a){return new(a||i)};static \u0275cmp=D({type:i,selectors:[["app-backup"]],features:[h([T])],decls:21,vars:22,consts:()=>{let e;e=$localize`${"\uFFFD#6\uFFFD"}:START_TAG_SPK_RADIO:${"\uFFFD/#6\uFFFD"}:CLOSE_TAG_SPK_RADIO: General `;let a;a=$localize`${"\uFFFD#9\uFFFD"}:START_TAG_SPK_RADIO:${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SPK_RADIO: Destination `;let t;t=$localize`${"\uFFFD#12\uFFFD"}:START_TAG_SPK_RADIO:${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SPK_RADIO: Source Data `;let o;o=$localize`${"\uFFFD#15\uFFFD"}:START_TAG_SPK_RADIO:${"\uFFFD/#15\uFFFD"}:CLOSE_TAG_SPK_RADIO: Schedule `;let F;return F=$localize`${"\uFFFD#18\uFFFD"}:START_TAG_SPK_RADIO:${"\uFFFD/#18\uFFFD"}:CLOSE_TAG_SPK_RADIO: Options `,[e,a,t,o,F,["step","","routerLinkActive","active",3,"routerLink"],[1,"indeterminate","primary"]]},template:function(a,t){a&1&&(r(0,"app-status-bar"),p(1,"header"),k(2,x,2,1,"p"),p(3,"spk-stepper")(4,"div",5),d(5,0),r(6,"spk-radio"),c(),s(),p(7,"div",5),d(8,1),r(9,"spk-radio"),c(),s(),p(10,"div",5),d(11,2),r(12,"spk-radio"),c(),s(),p(13,"div",5),d(14,3),r(15,"spk-radio"),c(),s(),p(16,"div",5),d(17,4),r(18,"spk-radio"),c(),s()()(),k(19,z,1,0,"spk-progress-bar",6)(20,V,2,0,"section")),a&2&&(n(2),g(t.isNew()?-1:2),n(2),u("routerLink",l(7,G,t.isDraft()?"/backup-draft":"/backup",t.backupId())),n(3),u("routerLink",l(10,y,t.isDraft()?"/backup-draft":"/backup",t.backupId())),n(3),u("routerLink",l(13,U,t.isDraft()?"/backup-draft":"/backup",t.backupId())),n(3),u("routerLink",l(16,w,t.isDraft()?"/backup-draft":"/backup",t.backupId())),n(3),u("routerLink",l(19,X,t.isDraft()?"/backup-draft":"/backup",t.backupId())),n(3),g(t.finishedLoading()?20:19))},dependencies:[B,b,$,L,N,I,M],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;height:100%}header[_ngcontent-%COMP%]{padding:1rem 1.5rem;border-bottom:1px solid var(--base-level-40)}header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin-bottom:.5rem}header[_ngcontent-%COMP%] spk-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{f as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as h}from"./chunk-TQHNKGRL.js";import{d as P,r as b}from"./chunk-ELMONRIG.js";import{h as f}from"./chunk-S5EF63OY.js";import{T as v,Z as F,r as D,va as k}from"./chunk-L72ALLHJ.js";import{a}from"./chunk-7CGTOI24.js";var l=class t{#t=F(f);s3Providers=h(this.getS3Config("Providers"));s3Regions=h(this.getS3Config("Regions"));s3RegionHosts=h(this.getS3Config("RegionHosts"));s3StorageClasses=h(this.getS3Config("StorageClasses"));storjSatellites=h(this.getStorjConfig("Satellites"));storjAuthenticationMethods=h(this.getStorjConfig("AuthenticationMethods"));openstackProviders=h(this.getOpenstackConfig("Providers"));openstackVersions=h(this.getOpenstackConfig("Versions"));gcsLocations=h(this.getGcsConfig("Locations"));gcsStorageClasses=h(this.getGcsConfig("StorageClasses"));getS3Config(e){return this.#t.postApiV1WebmoduleByModulekey({modulekey:"s3-getconfig",requestBody:{"s3-config":e}}).pipe(D(r=>this.#e(r)))}createS3IamUser(e,r){return this.#t.postApiV1WebmoduleByModulekey({modulekey:"s3-iamconfig",requestBody:{"s3-operation":"CanCreateUser","s3-username":e,"s3-password":r}})}createS3PolicyIAM(e){return this.#t.postApiV1WebmoduleByModulekey({modulekey:"s3-iamconfig",requestBody:{"s3-operation":"GetPolicyDoc",path:e}})}getStorjConfig(e){return this.#t.postApiV1WebmoduleByModulekey({modulekey:"storj-getconfig",requestBody:{"storj-config":e}}).pipe(D(r=>this.#e(r)))}getOpenstackConfig(e){return this.#t.postApiV1WebmoduleByModulekey({modulekey:"openstack-getconfig",requestBody:{"openstack-config":e}}).pipe(D(r=>this.#e(r)))}getGcsConfig(e){return this.#t.postApiV1WebmoduleByModulekey({modulekey:"gcs-getconfig",requestBody:{"gcs-config":e}}).pipe(D(r=>this.#e(r)))}#e(e){return(e.Result&&typeof e.Result=="object"&&Object.entries(e.Result).map(([r,n])=>({key:r,value:n})))??[]}static \u0275fac=function(r){return new(r||t)};static \u0275prov=v({token:t,factory:t.\u0275fac,providedIn:"root"})};var o=new b,S=[{key:"file",displayName:"File system",description:"Store backups on your local file system.",customFields:{path:{type:"FolderTree",name:"path",shortDescription:"File path",longDescription:"The path to store the backup",formElement:t=>o.control(t??"")}},mapper:{to:t=>{let e=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${t.custom.path}${e}`},from:(t,e,r)=>{let s=r.startsWith("file:///")?r.split("file:///")[1]:r.split("file://")[1],p=s.startsWith("%"),g=s.slice(1).startsWith(":\\")||p?s:"/"+s;return a({destinationType:t,custom:{path:g}},i(t,e))}}},{key:"ssh",displayName:"SSH",description:"Store backups in SSH.",customFields:{server:{type:"String",name:"server",shortDescription:"Server",longDescription:"The server to connect to",formElement:t=>o.control(t??"")},port:{type:"Integer",name:"port",shortDescription:"Port",longDescription:"The port to connect to",formElement:t=>o.control(t??"",[P.required,P.max(65535)])},path:{type:"Path",name:"path",shortDescription:"Folder path",longDescription:"Folder path",formElement:t=>o.control(t??"")}},dynamicFields:["auth-username"],advancedFields:[{type:"FileTree",name:"ssh-keyfile",accepts:".key,",shortDescription:"This is a path to a private key file locally on the machine",longDescription:"This is a path to a private key file locally on the machine"}],mapper:{to:t=>{let e=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]),{port:r,server:n,path:s}=t.custom;return`${t.destinationType}://${n+d(r)+u(s)+e}`},from:(t,e,r)=>a({destinationType:t,custom:{server:e.hostname,port:e.port,path:e.pathname}},i(t,e))}},{key:"s3",displayName:"S3 compatible bucket",description:"Store backups in any S3 compatible bucket.",customFields:{bucket:{type:"String",name:"bucket",shortDescription:"Bucket name",longDescription:"Bucket name",formElement:t=>o.control(t??"")},path:{type:"Path",name:"path",shortDescription:"Folder path",longDescription:"Folder path",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"s3-server-name",shortDescription:"Server",type:"NonValidatedSelectableString",loadOptions:t=>t.get(l).s3Providers},"use-ssl","auth-username","auth-password"],advancedFields:[{name:"s3-client",type:"Enumeration",options:["aws","minio"]},{name:"s3-storage-class",type:"NonValidatedSelectableString",loadOptions:t=>t.get(l).s3StorageClasses}],mapper:{to:t=>{let{bucket:e,path:r}=t.custom,n=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${e+u(r)+n}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.pathname,bucket:e.hostname}},i(t,e))}},{key:"gcs",displayName:"Google Cloud Storage",description:"Store backups in Google Cloud Storage.",oauthField:"authid",customFields:{path:{type:"Path",name:"path",shortDescription:"Bucket name",longDescription:"Bucket name",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"gcs-location",type:"NonValidatedSelectableString",loadOptions:t=>t.get(l).gcsLocations},{name:"gcs-storage-class",type:"NonValidatedSelectableString",loadOptions:t=>t.get(l).gcsStorageClasses},"authid"],mapper:{to:t=>{let e=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${t.custom.path}${e}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.hostname+e.pathname}},i(t,e))}},{key:"googledrive",displayName:"Google Drive",description:"Store backups in Google Drive.",oauthField:"authid",customFields:{path:{type:"Path",name:"path",shortDescription:"Folder path",longDescription:"Folder path",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"authid",type:"Password"}],mapper:{to:t=>{let e=t.custom.path,r=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${e}${r}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.hostname+e.pathname}},i(t,e))}},{key:"pcloud",displayName:"pCloud",description:"Store backups in pCloud.",oauthField:"authid",customFields:{server:{type:"Enumeration",name:"server",loadOptions:()=>k([{key:"pCloud Global",value:"api.pcloud.com"},{key:"pCloud Europe",value:"eapi.pcloud.com"}]),shortDescription:"Server",longDescription:"Server",formElement:t=>o.control(t??"")},path:{type:"Path",name:"path",shortDescription:"Folder path",longDescription:"Folder path",formElement:t=>o.control(t??"")}},dynamicFields:["authid"],mapper:{to:t=>{let e=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]),{server:r,path:n}=t.custom;return`${t.destinationType}://${r+u(n)+e}`},from:(t,e,r)=>{let n=e.pathname.replace(/^\//,"");return a({destinationType:t,custom:{server:e.hostname,path:n}},i(t,e))}}},{key:"azure",displayName:"Azure Blob Storage",description:"Store backups in Azure Blob Storage.",customFields:{path:{type:"String",name:"path",shortDescription:"Container name",longDescription:"Container name",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"auth-username",shortDescription:"Account name"},{name:"auth-password",shortDescription:"Access key"}],mapper:{to:t=>{let e=t.custom.path,r=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${e}${r}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.hostname+e.pathname}},i(t,e))}},{key:"onedrivev2",displayName:"OneDrive",description:"Store backups in OneDrive.",oauthField:"authid",customFields:{path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:["authid"],mapper:{to:t=>{let e=t.custom.path,r=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${e}${r}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.hostname+e.pathname}},i(t,e))}},{key:"od4b",displayName:"OneDrive Business",description:"Store backups in OneDrive Business.",customFields:{server:{type:"String",name:"server",shortDescription:"Server",longDescription:"Server",formElement:t=>o.control(t??"")},port:{type:"Integer",name:"port",shortDescription:"Port",longDescription:"Port",formElement:t=>o.control(t??"")},path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"auth-username",shortDescription:"Account name"},{name:"auth-password",shortDescription:"Access key"}],mapper:{to:t=>{let e=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]),{port:r,server:n,path:s}=t.custom;return`${t.destinationType}://${n+d(r)+u(s)+e}`},from:(t,e,r)=>a({destinationType:t,custom:{server:e.hostname,port:e.port,path:e.pathname}},i(t,e))}},{key:"mssp",displayName:"Microsoft SharePoint",description:"Store backups in Microsoft SharePoint.",customFields:{server:{type:"String",name:"server",shortDescription:"Server",longDescription:"Server",formElement:t=>o.control(t??"")},port:{type:"Integer",name:"port",shortDescription:"Port",longDescription:"Port",formElement:t=>o.control(t??"")},path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"auth-username",shortDescription:"Account name"},{name:"auth-password",shortDescription:"Access key"}],mapper:{to:t=>{let e=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]),{port:r,server:n,path:s}=t.custom;return`${t.destinationType}://${n+d(r)+u(s)+e}`},from:(t,e,r)=>a({destinationType:t,custom:{server:e.hostname,port:e.port,path:e.pathname}},i(t,e))}},{key:"sharepoint",displayName:"Microsoft SharePoint v2",description:"Store backups in Microsoft SharePoint.",oauthField:"authid",customFields:{path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:["authid"],mapper:{to:t=>{let e=t.custom.path,r=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${e}${r}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.hostname+e.pathname}},i(t,e))}},{key:"dropbox",displayName:"Dropbox",description:"Store backups in Dropbox.",oauthField:"authid",customFields:{path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:["authid"],mapper:{to:t=>{let e=t.custom.path,r=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${e}${r}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.hostname+e.pathname}},i(t,e))}},{key:"box",displayName:"Box.com",description:"Store backups in Box.com.",oauthField:"authid",customFields:{path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:["authid"],mapper:{to:t=>{let e=t.custom.path,r=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${e}${r}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.hostname+e.pathname}},i(t,e))}},{key:"jottacloud",displayName:"Jottacloud",description:"Store backups in Jottacloud.",oauthField:"authid",customFields:{path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:["authid"],mapper:{to:t=>{let e=t.custom.path,r=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${e}${r}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.hostname+e.pathname}},i(t,e))}},{key:"b2",displayName:"B2 Cloud Storage",description:"Store backups in B2 Cloud Storage.",customFields:{bucket:{type:"String",name:"bucket",shortDescription:"Bucket name",longDescription:"Bucket name",formElement:t=>o.control(t??"")},path:{type:"String",name:"path",shortDescription:"Path in the bucket",longDescription:"Path in the bucket",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"auth-username",shortDescription:"Application ID"},{name:"auth-password",shortDescription:"Application Key"}],mapper:{to:t=>{let{bucket:e,path:r}=t.custom,n=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${e+u(r)+n}`},from:(t,e,r)=>a({destinationType:t,custom:{bucket:e.hostname,path:decodeURIComponent(e.pathname)}},i(t,e))}},{key:"e2",displayName:"IDrive e2",description:"Store backups in IDrive e2.",customFields:{bucket:{type:"String",name:"bucket",shortDescription:"Bucket name",longDescription:"Bucket name",formElement:t=>o.control(t??"")},path:{type:"String",name:"path",shortDescription:"Path in the bucket",longDescription:"Path in the bucket",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"auth-username",shortDescription:"Access ID"},{name:"auth-password",shortDescription:"Access Secret"}],mapper:{to:t=>{let{bucket:e,path:r}=t.custom,n=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${e+u(r)+n}`},from:(t,e,r)=>a({destinationType:t,custom:{bucket:e.hostname,path:e.pathname}},i(t,e))}},{key:"mega",displayName:"Mega.nz",description:"Store backups in Mega.nz.",customFields:{path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"auth-username",shortDescription:"Username"},{name:"auth-password",shortDescription:"Password"}],mapper:{to:t=>{let e=t.custom.path,r=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${e}${r}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.hostname+e.pathname}},i(t,e))}},{key:"msgroup",displayName:"Microsoft Office 365 Group",description:"Store backups in Microsoft Office 365 Group.",oauthField:"authid",customFields:{groupEmail:{type:"Email",name:"groupEmail",shortDescription:"Group email",longDescription:"Group email",formElement:t=>o.control(t??"",[P.email])},path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:["authid"],mapper:{to:t=>{let e=t.custom.path,r=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]);return`${t.destinationType}://${e}${r}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.hostname+e.pathname}},i(t,e))}},{key:"cloudfiles",displayName:"Rackspace CloudFiles",description:"Store backups in Rackspace CloudFiles.",customFields:{server:{type:"String",name:"server",shortDescription:"Server",longDescription:"Server",formElement:t=>o.control(t??"")},port:{type:"Integer",name:"port",shortDescription:"Port",longDescription:"Port",formElement:t=>o.control(t??"")},path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"auth-username",shortDescription:"Username"},{name:"auth-password",shortDescription:"Password"}],mapper:{to:t=>{let e=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]),{port:r,server:n,path:s}=t.custom;return`${t.destinationType}://${n+d(r)+u(s)+e}`},from:(t,e,r)=>a({destinationType:t,custom:{server:e.hostname,port:e.port,path:e.pathname}},i(t,e))}},{key:"rclone",displayName:"Rclone",description:"Store backups in Rclone.",dynamicFields:[{name:"rclone-local-repository",shortDescription:"Local repository",defaultValue:""},{name:"rclone-remote-repository",shortDescription:"Remote repository",defaultValue:""},{name:"rclone-remote-path",shortDescription:"Path on remote repository",defaultValue:""}],mapper:{to:t=>{let e=t.dynamic["rclone-remote-repository"],r=t.dynamic["rclone-remote-path"],n=Object.entries(t.dynamic).filter(([p])=>!["rclone-remote-repository","rclone-remote-path"].includes(p)),s=c([...Object.entries(t.advanced),...n]);return`${t.destinationType}://${e}/${r+s}`},from:(t,e,r)=>{let{advanced:n,dynamic:s}=i(t,e);return a({destinationType:t,dynamic:a({"rclone-remote-repository":e.hostname,"rclone-remote-path":e.pathname},s)},n)}}},{key:"openstack",displayName:"OpenStack Object Storage",description:"Store backups in OpenStack Object Storage.",customFields:{bucket:{type:"String",name:"bucket",shortDescription:"Bucket",longDescription:"Bucket",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"openstack-authuri",shortDescription:"Auth URI",type:"Enumeration",loadOptions:t=>t.get(l).openstackProviders},{name:"openstack-version",shortDescription:"Version",type:"Enumeration",loadOptions:t=>t.get(l).openstackVersions},{name:"openstack-domain-name",shortDescription:"Domain name"},{name:"openstack-tenant-name",shortDescription:"Tenant name"},{name:"openstack-region",shortDescription:"Region"}],mapper:{to:t=>{let e=c([...Object.entries(t.advanced),...Object.entries(t.dynamic)]),{bucket:r}=t.custom;return`${t.destinationType}://${r+e}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.pathname,bucket:e.hostname}},i(t,e))}},{key:"webdav",displayName:"WebDAV",description:"Store backups in WebDAV.",customFields:{server:{type:"String",name:"server",shortDescription:"Server",longDescription:"Server",formElement:t=>o.control(t??"")},port:{type:"Integer",name:"port",shortDescription:"Port",longDescription:"Port",formElement:t=>o.control(t??"")},path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"use-ssl",shortDescription:"Use SSL"},{name:"auth-username",shortDescription:"Username"},{name:"auth-password",shortDescription:"Password"}],mapper:{to:t=>{let{port:e,server:r,path:n}=t.custom,s=t.dynamic["use-ssl"],p=c([...Object.entries(t.advanced),...Object.entries(t.dynamic).filter(([m])=>m!=="use-ssl")]);return`${t.destinationType}${s?"s":""}://${r+d(e)+u(n)+p}`},from:(t,e,r)=>a({destinationType:t,custom:{server:e.hostname,port:e.port,path:e.pathname}},i(t,e))}},{key:"aftp",displayName:"FTP",description:"Store backups in FTP.",customFields:{server:{type:"String",name:"server",shortDescription:"Server",longDescription:"Server",formElement:t=>o.control(t??"")},port:{type:"Integer",name:"port",shortDescription:"Port",longDescription:"Port",formElement:t=>o.control(t??"")},path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"auth-username",shortDescription:"Username"},{name:"auth-password",shortDescription:"Password"}],mapper:{to:t=>{let{port:e,server:r,path:n}=t.custom,s=c([...Object.entries(t.advanced),...Object.entries(t.dynamic).filter(([p])=>p!=="use-ssl")]);return`${t.destinationType}://${r+d(e)+u(n)+s}`},from:(t,e,r)=>a({destinationType:t,custom:{server:e.hostname,port:e.port,path:e.pathname}},i(t,e))}},{key:"sia",displayName:"Sia Decentrilized Cloud",description:"Store backups in Sia Decentrilized Cloud.",customFields:{server:{type:"String",name:"server",shortDescription:"Server",longDescription:"Server",formElement:t=>o.control(t??"")}},dynamicFields:["sia-targetpath","sia-password","sia-redundancy"],mapper:{to:t=>{let e=t.custom.server,r=t.dynamic["sia-targetpath"],n=c([...Object.entries(t.advanced),...Object.entries(t.dynamic).filter(([s])=>s!=="sia-targetpath")]);return`${t.destinationType}://${e+u(r)+n}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.pathname}},i(t,e))}},{key:"cos",displayName:"Tencent COS",description:"Store backups in Tencent COS.",customFields:{path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"cos-bucket",shortDescription:"Bucket",order:1},{name:"cos-region",shortDescription:"Region",order:2},{name:"cos-app-id",shortDescription:"COS App Id",order:3},{name:"cos-secret-id",shortDescription:"COS Secret Id",order:4},{name:"cos-secret-key",shortDescription:"COS Secret Key",order:5}],mapper:{to:t=>{let e=t.custom.path,r=c([...Object.entries(t.advanced),...Object.entries(t.dynamic).filter(([n])=>n!=="cos-targetpath")]);return`${t.destinationType}://${e+r}`},from:(t,e,r)=>a({destinationType:t,custom:{path:e.pathname}},i(t,e))}},{key:"tahoe",displayName:"Tahoe LAFS",description:"Store backups in Tahoe LAFS.",customFields:{server:{type:"String",name:"server",shortDescription:"Server",longDescription:"Server",formElement:t=>o.control(t??"")},port:{type:"Integer",name:"port",shortDescription:"Port",longDescription:"Port",formElement:t=>o.control(t??"")},path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:[{name:"use-ssl",shortDescription:"Use SSL"}],mapper:{to:t=>{let{port:e,server:r,path:n,username:s,password:p}=t.custom,m={"auth-username":s,"auth-password":p},g=t.dynamic["use-ssl"],y=c([...Object.entries(t.advanced),...Object.entries(t.dynamic).filter(([O])=>O!=="use-ssl"),...Object.entries(m)]);return`${t.destinationType}${g?"s":""}://${r+d(e)+u(n)+y}`},from:(t,e,r)=>a({destinationType:t,custom:{server:e.hostname,port:e.port,path:e.pathname}},i(t,e))}},{key:"cifs",displayName:"CIFS",description:"Store backups in CIFS.",customFields:{server:{type:"String",name:"server",shortDescription:"Server",longDescription:"Server",formElement:t=>o.control(t??"")},share:{type:"String",name:"share",shortDescription:"Share Name",longDescription:"Share Name",formElement:t=>o.control(t??"")},path:{type:"String",name:"path",shortDescription:"Path on server",longDescription:"Path on server",formElement:t=>o.control(t??"")}},dynamicFields:["transport","auth-username","auth-password","auth-domain"],mapper:{to:t=>{let{share:e,server:r,path:n,username:s,password:p}=t.custom,m={"auth-username":s,"auth-password":p},g=new Map([...Object.entries(m),...Object.entries(t.advanced),...Object.entries(t.dynamic)]),y=c(Array.from(g));return`${t.destinationType}://${r+u(e)+u(n)+y}`},from:(t,e,r)=>{let n=e.pathname.split("/")[1],s=e.pathname.split("/").slice(2).join("/");return a({destinationType:t,custom:{server:e.hostname,share:n,path:s}},i(t,e))}}},{key:"filen",displayName:"Filen.io",description:"Store backups in Filen.io.",customFields:{path:{type:"String",name:"path",shortDescription:"Path on Filen",longDescription:"Path on Filen",formElement:t=>o.control(t??"")}},dynamicFields:["auth-username","auth-password"],mapper:{to:t=>{let{path:e,username:r,password:n}=t.custom,s={"auth-username":r,"auth-password":n},p=new Map([...Object.entries(s),...Object.entries(t.advanced),...Object.entries(t.dynamic)]),m=c(Array.from(p));return`${t.destinationType}://${e+m}`},from:(t,e,r)=>{let n=e.hostname??"";return e.pathname&&n!==""&&e.pathname[0]!="/"&&(n+="/"),n+=e.pathname,a({destinationType:t,custom:{path:n}},i(t,e))}}},{key:"filejump",displayName:"Filejump",description:"Store backups in Filejump.",customFields:{path:{type:"String",name:"path",shortDescription:"Path on Filejump",longDescription:"Path on Filejump",formElement:t=>o.control(t??"")}},dynamicFields:[{type:"Password",name:"api-token",shortDescription:"API Token",longDescription:"Filejump API Token",formElement:t=>o.control(t??"")}],mapper:{to:t=>{let{path:e,username:r,password:n,apitoken:s}=t.custom,p=(s||"").trim()===""?{"auth-username":r,"auth-password":n}:{"api-token":s},m=new Map([...Object.entries(p),...Object.entries(t.advanced),...Object.entries(t.dynamic)]),g=c(Array.from(m));return`${t.destinationType}://${e+g}`},from:(t,e,r)=>{let n=e.hostname??"";return e.pathname&&n!==""&&e.pathname[0]!="/"&&(n+="/"),n+=e.pathname,a({destinationType:t,custom:{path:n}},i(t,e))}}},{key:"storj",customKey:"storjAccessGrant",displayName:"Storj Access Grant",description:"Store backups in Storj Access Grant.",dynamicFields:[{name:"storj-shared-access",shortDescription:"Access Grant"},{name:"storj-bucket",shortDescription:"Bucket"},{name:"storj-folder",shortDescription:"Path on server"}],mapper:{to:t=>`storj://storj.io/config?storj-auth-method=Access%20grant&storj-satellite=us1.storj.io%3A7777&storj-api-key&storj-secret&${c([...Object.entries(t.advanced),...Object.entries(t.dynamic)],!0)}`,from:(t,e,r)=>a({destinationType:t},i(t,e))}},{key:"storj",customKey:"storjApiKey",displayName:"Storj API Key",description:"Store backups in Storj API Key.",dynamicFields:[{name:"storj-satellite",shortDescription:"Satellite",type:"Enumeration",loadOptions:t=>t.get(l).storjSatellites},{name:"storj-api-key",shortDescription:"API Key"},{name:"storj-secret",shortDescription:"Secret"},{name:"storj-bucket",shortDescription:"Bucket"},{name:"storj-folder",shortDescription:"Path on server"}],mapper:{to:t=>`storj://storj.io/config?storj-auth-method=API%20key&${c([...Object.entries(t.advanced),...Object.entries(t.dynamic)],!0)}`,from:(t,e,r)=>a({destinationType:t},i(t,e))}}];function d(t){return t==null||t===""?"":":"+t.toString()}function u(t){return t==null?"":t.startsWith("/")?t:"/"+t}function i(t,e){let r={},n={},s=S.find(p=>p.key===t);return e.searchParams.forEach((p,m)=>{s?.dynamicFields?.some(y=>y===m||y?.name===m)?n[m]=decodeURIComponent(p):r[m]=decodeURIComponent(p)}),{advanced:r,dynamic:n}}function c(t,e=!1){let r=t.map(([s,p])=>`${s}=${p?encodeURIComponent(p.toString()):""}`).join("&");return r?(e?"":"?")+r:""}function x(t){let e=t.destinationType,r=S.find(n=>n.customKey===e||n.key===e);if(!r)throw new Error("Invalid destination type");return r?.mapper.to(t)??""}function K(t){let e=URL.canParse(t),r=t.split("://")[0],n=t.split("://")[1],s="http://"+n;if(n.startsWith("%")&&r==="file")return S.find(p=>p.customKey===r||p.key===r)?.mapper.from(r,new URL("http://localhost"),t);try{let p=new URL(s);return S.find(m=>m.customKey===r||m.key===r)?.mapper.from(r,p,t)}catch(p){console.error("Error while parsing target path",p)}if(!e)throw new Error("Invalid target path");return null}export{x as a,K as b,S as c};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as h}from"./chunk-FJVMA6GA.js";import"./chunk-RHW5QVAY.js";import{b as v,c as G,e as L,f as w,i as U,n as K,q as X,r as x,t as V}from"./chunk-ELMONRIG.js";import"./chunk-XP7PWMT2.js";import{d as O,e as A}from"./chunk-C6XTRC7P.js";import"./chunk-MAVZY7BL.js";import{A as
|
|
1
|
+
import{a as h}from"./chunk-FJVMA6GA.js";import"./chunk-RHW5QVAY.js";import{b as v,c as G,e as L,f as w,i as U,n as K,q as X,r as x,t as V}from"./chunk-ELMONRIG.js";import"./chunk-XP7PWMT2.js";import{d as O,e as A}from"./chunk-C6XTRC7P.js";import"./chunk-MAVZY7BL.js";import{A as y,a as b,c as R,g as N,l as E,m as $}from"./chunk-P4ZFQZCA.js";import{h as B}from"./chunk-S5EF63OY.js";import"./chunk-7L2WUS2V.js";import{Db as r,Eb as n,F as g,Fb as l,Pb as P,Qb as I,Rb as _,Ua as s,Ub as M,Vb as d,Z as F,gb as T,lb as S,ub as u,uc as k,va as m,wb as C,zb as D}from"./chunk-L72ALLHJ.js";import"./chunk-7CGTOI24.js";var z=()=>["/"];function j(c,t){c&1&&(r(0,"spk-form-field")(1,"label",14),_(2,3),n(),l(3,"input",15),n())}var p=new x,f=class c{#e=F(R);#t=F(B);#o=F(h);#n=F(O);isImporting=m(!1);isSecureFile=m(!1);importForm=p.group({config:p.control(""),cmdline:p.control(!1),importMetadata:p.control(!1),direct:p.control(!1),passphrase:p.control("")});selectedFile=m([]);onFileDropped(t){let e=t[0];if(e){let o=new FileReader;this.isSecureFile.set(e.type!=="application/json"),o.onload=this.#i.bind(this),o.readAsArrayBuffer(e)}}#i(t){let e=t.target?.result;this.importForm.patchValue({config:this.#r(e)})}#r(t){let e=new Uint8Array(t),o=e.byteLength,a="";for(let i=0;i<o;i++)a+=String.fromCharCode(e[i]);return btoa(a)}submit(){this.isImporting.set(!0),this.#t.postApiV1BackupsImport({requestBody:this.importForm.value}).pipe(g(()=>this.isImporting.set(!1))).subscribe({next:t=>{let e=this.#o.addDraftBackup(t.data);this.#n.navigate(["/backup-draft",e])},error:t=>{this.#e.error(t.message)}})}static \u0275fac=function(e){return new(e||c)};static \u0275cmp=T({type:c,selectors:[["app-import"]],decls:19,vars:8,consts:()=>{let t;t=$localize` Import backup configuration ${"\uFFFD#3\uFFFD"}:START_TAG_DIV:${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"[\uFFFD#5\uFFFD|\uFFFD#7\uFFFD]"}:START_TAG_SPK_ICON:arrow-left${"[\uFFFD/#5\uFFFD|\uFFFD/#7\uFFFD]"}:CLOSE_TAG_SPK_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_SPK_ICON:download-simple${"[\uFFFD/#5\uFFFD|\uFFFD/#7\uFFFD]"}:CLOSE_TAG_SPK_ICON: Import ${"[\uFFFD/#4\uFFFD|\uFFFD/#6\uFFFD]"}:CLOSE_TAG_BUTTON:${"\uFFFD/#3\uFFFD"}:CLOSE_TAG_DIV:`,t=M(t);let e;e=$localize`Import Metadata`;let o;o=$localize`Save now`;let a;return a=$localize`Passphrase`,[t,e,o,a,[1,"actions"],["spk-button","","type","button",1,"outlined",3,"routerLink"],["spk-button","","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","importMetadata"],["for","direct"],["type","checkbox","formControlName","direct"],["for","passphrase"],["type","password","formControlName","passphrase"]]},template:function(e,o){e&1&&(r(0,"header")(1,"h3"),P(2,0),r(3,"div",4)(4,"button",5),l(5,"spk-icon"),n(),r(6,"button",6),d("click",function(){return o.submit()}),l(7,"spk-icon"),n()(),I(),n()(),r(8,"form",7)(9,"spk-file-upload",8),d("filesChange",function(i){return o.onFileDropped(i)}),n(),S(10,j,4,0,"spk-form-field"),r(11,"spk-toggle",9)(12,"label",10),_(13,1),n(),l(14,"input",11),n(),r(15,"spk-toggle",9)(16,"label",12),_(17,2),n(),l(18,"input",13),n()()),e&2&&(s(4),u("routerLink",k(7,z)),s(2),C("loader",o.isImporting()),u("disabled",o.isImporting()),s(2),u("formGroup",o.importForm),s(),u("files",o.selectedFile()),s(),D(o.isSecureFile()?10:-1))},dependencies:[V,U,G,v,L,w,K,X,A,E,b,N,y,$],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}spk-file-upload[_ngcontent-%COMP%]{width:100%}"],changeDetection:0})};export{f as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as le,b as pe}from"./chunk-PUEJXHBQ.js";import{a as re}from"./chunk-NDO7MKXC.js";import{a as Y}from"./chunk-F2GEUOGZ.js";import{b as Z,c as ee,e as te,h as ie,j as ne,s as oe}from"./chunk-ELMONRIG.js";import{A as J,B as Q,a as K,g as U,l as W,o as X,t as j,z as H}from"./chunk-P4ZFQZCA.js";import{$b as g,Ab as V,Bb as O,Bc as A,Cb as y,Db as l,Eb as a,Fb as M,Gb as N,Hb as k,Jb as x,Oc as R,Pb as $,Qb as P,Rb as q,Ua as r,Vb as f,Wb as s,Z as B,bb as G,ea as d,fa as u,gb as z,hc as E,ic as m,jc as L,kc as F,lb as C,nc as v,oc as D,pc as b,sa as I,ub as c,va as h,zb as S}from"./chunk-L72ALLHJ.js";import{a as T,b as w}from"./chunk-7CGTOI24.js";function me(n,o){if(n&1){let e=x();l(0,"button",14),f("click",function(){d(e);let t=s();return u(t.addFreeTextSetting())}),$(1,5),M(2,"spk-icon"),P(),a()}}function _e(n,o){if(n&1){let e=x();l(0,"button",16,0),f("click",function(){let t=d(e).$implicit,p=s(2);return u(p.addSetting(t))}),m(2),a()}if(n&2){let e=o.$implicit;r(2),L(e.name)}}function ce(n,o){if(n&1&&(l(0,"h3",7),m(1),a(),O(2,_e,3,1,"button",15,V)),n&2){let e=o.$implicit;r(),L(e.displayName),r(),y(e.options)}}function de(n,o){n&1&&(l(0,"div",12),m(1,"Add a setting above to get started."),a())}function ue(n,o){if(n&1){let e=x();l(0,"div",17)(1,"label"),m(2),a(),l(3,"div",23)(4,"spk-form-field")(5,"input",24),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateFreeTextSettingName(p,t))}),a(),l(6,"spk-icon",25),m(7,"rectangle-dashed"),a()(),l(8,"spk-form-field")(9,"input",24),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a(),l(10,"spk-icon",25),m(11,"textbox"),a()()()()}if(n&2){let e=s().$implicit;r(2),F(" ",e.FormView.shortDescription," "),r(3),c("ngModel",e.Name),r(4),c("ngModel",e.Value())}}function ge(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Ce(n,o){if(n&1){let e=x();l(0,"app-file-tree",18)(1,"label",26),m(2),C(3,ge,3,1,"spk-tooltip",27),a(),l(4,"input",28),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a()()}if(n&2){let e=s(),i=e.$implicit,t=e.$index;c("startingPath",i.Value())("accepts",i.FormView.accepts)("showFiles",!0)("showHiddenNodes",!0)("selectFiles",!0),r(),g("for","destination-",i.Name,"-",t,""),r(),F(" ",i.FormView.shortDescription," "),r(),S(i.FormView.longDescription?3:-1),r(),g("id","destination-",i.Name,"-",t,""),c("ngModel",i.Value())}}function xe(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function fe(n,o){if(n&1){let e=x();l(0,"app-file-tree",19)(1,"label",26),m(2),C(3,xe,3,1,"spk-tooltip",27),a(),l(4,"input",28),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a()()}if(n&2){let e=s(),i=e.$implicit,t=e.$index;c("startingPath",i.Value()),r(),g("for","destination-",i.Name,"-",t,""),r(),F(" ",i.FormView.shortDescription," "),r(),S(i.FormView.longDescription?3:-1),r(),g("id","destination-",i.Name,"-",t,""),c("ngModel",i.Value())}}function Se(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Fe(n,o){n&1&&(l(0,"spk-icon",25),m(1,"link"),a())}function Te(n,o){n&1&&(l(0,"spk-icon",25),m(1,"textbox"),a())}function we(n,o){if(n&1){let e=x();l(0,"spk-form-field")(1,"label",26),m(2),C(3,Se,3,1,"spk-tooltip",27),a(),l(4,"input",28),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a(),C(5,Fe,2,0,"spk-icon",25)(6,Te,2,0,"spk-icon",25),a()}if(n&2){let e=s(),i=e.$implicit,t=e.$index;r(),g("for","destination-",i.Name,"-",t,""),r(),F(" ",i.FormView.shortDescription," "),r(),S(i.FormView.longDescription?3:-1),r(),g("id","destination-",i.Name,"-",t,""),c("ngModel",i.Value()),r(),S(i.FormView.type==="Path"?5:6)}}function Ve(n,o){if(n&1){let e=x();l(0,"spk-icon",31),f("click",function(){d(e);let t=s(2).$implicit;return u(t.showPassword=!t.showPassword)}),m(1," eye "),a()}}function Oe(n,o){if(n&1){let e=x();l(0,"spk-icon",31),f("click",function(){d(e);let t=s(2).$implicit;return u(t.showPassword=!t.showPassword)}),m(1," eye-slash "),a()}}function ye(n,o){if(n&1){let e=x();l(0,"spk-form-field")(1,"label",26),m(2),a(),l(3,"input",29),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a(),l(4,"spk-icon",25),m(5,"password"),a(),C(6,Ve,2,0,"spk-icon",30)(7,Oe,2,0,"spk-icon",30),a()}if(n&2){let e=s(),i=e.$implicit,t=e.$index;r(),g("for","destination-",i.Name,"-",t,""),r(),F(" ",i.FormView.shortDescription," "),r(),g("id","destination-",i.Name,"-",t,""),c("type",i.showPassword?"text":"password")("ngModel",i.Value()),r(3),S(i.showPassword?6:7)}}function ke(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Ie(n,o){if(n&1&&m(0),n&2){let e=o.$implicit;F(" ",e," ")}}function he(n,o){if(n&1){let e=x();l(0,"spk-select",32)(1,"label",26),m(2),C(3,ke,3,1,"spk-tooltip",27),a(),l(4,"input",28),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a()(),C(5,Ie,1,1,"ng-template",null,1,A)}if(n&2){let e=E(6),i=s(),t=i.$implicit,p=i.$index;c("options",t.FormView.options)("isClearable",!1)("optionTemplate",e),r(),g("for","destination-",t.Name,"-",p,""),r(),F(" ",t.FormView.shortDescription," "),r(),S(t.FormView.longDescription?3:-1),r(),g("id","destination-",t.Name,"-",p,""),c("ngModel",t.Value())}}function Me(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Ne(n,o){if(n&1){let e=x();l(0,"app-size",33),b("ngModelChange",function(t){d(e);let p=s().$implicit;return D(p.Value,t)||(p.Value=t),u(t)}),l(1,"label",26),m(2),C(3,Me,3,1,"spk-tooltip",27),a()()}if(n&2){let e,i=s(),t=i.$implicit,p=i.$index;c("inputType",t.Name),v("ngModel",t.Value),c("customId","destination-{{ item.Name }}-{{ $index }}"),r(),g("for","destination-",t.Name,"-",p,""),r(),F(" ",(e=t.FormView.shortDescription)!==null&&e!==void 0?e:t.FormView.name," "),r(),S(t.FormView.longDescription?3:-1)}}function $e(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Pe(n,o){if(n&1){let e=x();l(0,"spk-form-field")(1,"label",26),m(2),C(3,$e,3,1,"spk-tooltip",27),a(),l(4,"input",34),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a(),l(5,"spk-icon",25),m(6,"numpad"),a()()}if(n&2){let e=s(),i=e.$implicit,t=e.$index;r(),g("for","destination-",i.Name,"-",t,""),r(),F(" ",i.FormView.shortDescription," "),r(),S(i.FormView.longDescription?3:-1),r(),g("id","destination-",i.Name,"-",t,""),c("ngModel",i.Value())}}function Ee(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Le(n,o){if(n&1){let e=x();l(0,"spk-toggle",21)(1,"label",26),m(2),C(3,Ee,3,1,"spk-tooltip",27),a(),l(4,"input",35),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a()()}if(n&2){let e=s(),i=e.$implicit,t=e.$index;r(),g("for","destination-",i.Name,"-",t,""),r(),F(" ",i.FormView.shortDescription," "),r(),S(i.FormView.longDescription?3:-1),r(),g("id","destination-",i.Name,"-",t,""),c("ngModel",i.Value())}}function ve(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function De(n,o){if(n&1&&m(0),n&2){let e=o.$implicit;F(" ",e," ")}}function be(n,o){if(n&1){let e=x();l(0,"spk-select",36)(1,"label",26),m(2),C(3,ve,3,1,"spk-tooltip",27),a(),l(4,"input",37),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a()(),C(5,De,1,1,"ng-template",null,2,A)}if(n&2){let e=E(6),i=s(),t=i.$implicit,p=i.$index;c("options",t.FormView.options)("selectMultiple",!0)("optionTemplate",e),r(),g("for","destination-",t.Name,"-",p,""),r(),F(" ",t.FormView.shortDescription," "),r(),S(t.FormView.longDescription?3:-1),r(),c("ngModel",t.Value())}}function Ae(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Re(n,o){if(n&1){let e=x();l(0,"app-timespan",33),b("ngModelChange",function(t){d(e);let p=s().$implicit;return D(p.Value,t)||(p.Value=t),u(t)}),l(1,"label",26),m(2),C(3,Ae,3,1,"spk-tooltip",27),a()()}if(n&2){let e,i=s(),t=i.$implicit,p=i.$index;c("inputType",t.Name),v("ngModel",t.Value),c("customId","destination-{{ item.Name }}-{{ $index }}"),r(),g("for","destination-",t.Name,"-",p,""),r(),F(" ",(e=t.FormView.shortDescription)!==null&&e!==void 0?e:t.FormView.name," "),r(),S(t.FormView.longDescription?3:-1)}}function Be(n,o){if(n&1){let e=x();l(0,"div",13),C(1,ue,12,3,"div",17)(2,Ce,5,14,"app-file-tree",18)(3,fe,5,10,"app-file-tree",19)(4,we,7,10,"spk-form-field")(5,ye,8,10,"spk-form-field")(6,he,7,12)(7,Ne,4,8,"app-size",20)(8,Pe,7,9,"spk-form-field")(9,Le,5,9,"spk-toggle",21)(10,be,7,9)(11,Re,4,8,"app-timespan",20),l(12,"button",22),f("click",function(){let t=d(e).$implicit,p=s();return u(p.removeSetting(t))}),l(13,"spk-icon"),m(14,"x-bold"),a()()()}if(n&2){let e=o.$implicit;r(),S(e.FormView.type==="FreeText"?1:e.FormView.type==="FileTree"?2:e.FormView.type==="FolderTree"?3:e.FormView.type==="String"||e.FormView.type==="Path"||e.FormView.type==="Decimal"?4:e.FormView.type==="Password"?5:e.FormView.type==="Enumeration"?6:e.FormView.type==="Size"?7:e.FormView.type==="Integer"?8:e.FormView.type==="Boolean"?9:e.FormView.type==="Flags"?10:e.FormView.type==="Timespan"||e.FormView.type==="DateTime"?11:-1)}}var ae=class n{#e=B(Y);options=G.required();hiddenOptions=I([]);hasFreeTextSettings=I(!1);allOptionsGrouped=this.#e.allOptionsGrouped;allOptions=this.#e.allOptions;selectedSettings=R(()=>{let o=this.hiddenOptions();return this.options().map(t=>{let p=this.allOptions().find(_=>_.name===t.Name?.replace("--",""));if(p&&!o.includes(p.name)){let _=t.Value??"";p.type==="Boolean"&&(_=_&&_.toLowerCase()==="true"||!1),p.type==="Integer"&&(_=parseInt(_)||0);let se=h(_);return w(T({},t),{Value:se,FormView:p})}else if(this.hasFreeTextSettings())return w(T({},t),{Value:h(t.Value),FormView:{name:t.Name,type:"FreeText",shortDescription:"Custom settings argument",longDescription:"Custom settings argument"}});return null}).filter(t=>t!==null)});nonSelectedOptionsGrouped=R(()=>{let o=this.options().map(i=>i.Name),e=this.hiddenOptions();return this.allOptionsGrouped().map(i=>w(T({},i),{options:i.options.filter(t=>!o.includes(t.name)&&!e.includes(t.name))})).filter(i=>i.options.length>0)});addFreeTextSetting(){this.hasFreeTextSettings()&&this.options.update(o=>[...o,{Filter:null,Name:"",Value:""}])}addSetting(o){this.options.update(e=>{let i=o.defaultValue??"";return o.type==="Boolean"&&(i=i.toLowerCase()==="true"||!1),o.type==="Integer"&&(i=parseInt(i)||0),[...e,{Name:o.name,Value:i}]})}updateSettingValue(o,e){this.options.update(i=>{let t=[...i],p=t.findIndex(_=>_.Name===o.Name);return o.FormView.type==="Boolean"?(t[p].Value=e?"True":"False",t):o.FormView.type==="Integer"?(t[p].Value=e.toString(),t):(t[p].Value=e,t)})}updateFreeTextSettingName(o,e){this.options.update(i=>{let t=[...i],p=t.findIndex(_=>_.Name===o.Name);return t[p].Name=e,t})}removeSetting(o){this.options.update(e=>e.filter(i=>i.Name!==o.Name))}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=z({type:n,selectors:[["app-options-list"]],inputs:{options:[1,"options"],hiddenOptions:[1,"hiddenOptions"],hasFreeTextSettings:[1,"hasFreeTextSettings"]},outputs:{options:"optionsChange"},decls:16,vars:4,consts:()=>{let o;o=$localize`Advanced options`;let e;e=$localize` Add advanced option ${"\uFFFD#9\uFFFD"}:START_TAG_SPK_ICON:plus${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SPK_ICON:`;let i;return i=$localize` New custom option ${"\uFFFD#2\uFFFD"}:START_TAG_SPK_ICON:pen${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SPK_ICON:`,[["option",""],["enumOptionTemplate",""],["optionTemplate",""],o,e,i,[3,"disallowToggle"],["title",""],[1,"actions"],["spk-button","","type","button",1,"outlined","small"],[3,"searchable"],["menu",""],[1,"placeholder"],[1,"field-row"],["spk-button","","type","button",1,"outlined","small",3,"click"],["type","button"],["type","button",3,"click"],[1,"form-column"],[3,"startingPath","accepts","showFiles","showHiddenNodes","selectFiles"],[3,"startingPath"],[3,"inputType","ngModel","customId"],[1,"primary","raised"],["spk-button","","type","button",1,"outlined","remove-btn",3,"click"],[1,"form-row"],["type","text",3,"ngModelChange","ngModel"],["prefix",""],[3,"for"],[1,"primary",3,"message"],["type","text",3,"ngModelChange","id","ngModel"],["autocomplete","off",3,"ngModelChange","type","id","ngModel"],["suffix","",1,"clickable"],["suffix","",1,"clickable",3,"click"],[3,"options","isClearable","optionTemplate"],[3,"ngModelChange","inputType","ngModel","customId"],["type","number",3,"ngModelChange","id","ngModel"],["type","checkbox",3,"ngModelChange","id","ngModel"],[1,"primary","raised",3,"options","selectMultiple","optionTemplate"],["type","text","id","text",3,"ngModelChange","ngModel"]]},template:function(e,i){e&1&&(l(0,"spk-toggle-card",6),N(1,7)(2),q(3,3),k(),l(4,"div",8),C(5,me,3,0,"button",9),l(6,"spk-menu",10)(7,"button",9),$(8,4),M(9,"spk-icon"),P(),a(),N(10,11),O(11,ce,4,1,null,null,V),k(),a()(),k(),C(13,de,2,0,"div",12),O(14,Be,15,1,"div",13,V),a()),e&2&&(c("disallowToggle",!0),r(5),S(i.hasFreeTextSettings()?5:-1),r(),c("searchable",!0),r(5),y(i.nonSelectedOptionsGrouped()),r(2),S(i.selectedSettings().length===0?13:-1),r(),y(i.selectedSettings()))},dependencies:[oe,ee,ne,Z,te,ie,re,H,W,U,X,Q,K,j,J,le,pe],styles:["[_nghost-%COMP%]{display:block}spk-select[_ngcontent-%COMP%]{--miw: p2r(120)}spk-toggle[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:1rem}.placeholder[_ngcontent-%COMP%]{color:var(--base-level-60R);text-align:center;padding:2rem 1rem}.field-row[_ngcontent-%COMP%]{display:grid;align-items:center;grid-template-columns:1fr 2.5rem;gap:.5rem}.field-row[_ngcontent-%COMP%] .remove-btn[_ngcontent-%COMP%]{align-self:flex-end}.form-column[_ngcontent-%COMP%]{display:flex;gap:.25rem;flex-direction:column}.form-column[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem}.form-column[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:1rem}.form-row[_ngcontent-%COMP%]{display:grid;grid-template-columns:3fr 1fr;gap:.5rem;align-items:flex-end}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;justify-content:flex-end}"],changeDetection:0})};export{ae as a};
|
|
1
|
+
import{a as le,b as pe}from"./chunk-PUEJXHBQ.js";import{a as re}from"./chunk-HTJ5CVNN.js";import{a as Y}from"./chunk-F2GEUOGZ.js";import{b as Z,c as ee,e as te,h as ie,j as ne,s as oe}from"./chunk-ELMONRIG.js";import{A as J,B as Q,a as K,g as U,l as W,o as X,t as j,z as H}from"./chunk-P4ZFQZCA.js";import{$b as g,Ab as V,Bb as O,Bc as A,Cb as y,Db as l,Eb as a,Fb as M,Gb as N,Hb as k,Jb as x,Oc as R,Pb as $,Qb as P,Rb as q,Ua as r,Vb as f,Wb as s,Z as B,bb as G,ea as d,fa as u,gb as z,hc as E,ic as m,jc as L,kc as F,lb as C,nc as v,oc as D,pc as b,sa as I,ub as c,va as h,zb as S}from"./chunk-L72ALLHJ.js";import{a as T,b as w}from"./chunk-7CGTOI24.js";function me(n,o){if(n&1){let e=x();l(0,"button",14),f("click",function(){d(e);let t=s();return u(t.addFreeTextSetting())}),$(1,5),M(2,"spk-icon"),P(),a()}}function _e(n,o){if(n&1){let e=x();l(0,"button",16,0),f("click",function(){let t=d(e).$implicit,p=s(2);return u(p.addSetting(t))}),m(2),a()}if(n&2){let e=o.$implicit;r(2),L(e.name)}}function ce(n,o){if(n&1&&(l(0,"h3",7),m(1),a(),O(2,_e,3,1,"button",15,V)),n&2){let e=o.$implicit;r(),L(e.displayName),r(),y(e.options)}}function de(n,o){n&1&&(l(0,"div",12),m(1,"Add a setting above to get started."),a())}function ue(n,o){if(n&1){let e=x();l(0,"div",17)(1,"label"),m(2),a(),l(3,"div",23)(4,"spk-form-field")(5,"input",24),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateFreeTextSettingName(p,t))}),a(),l(6,"spk-icon",25),m(7,"rectangle-dashed"),a()(),l(8,"spk-form-field")(9,"input",24),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a(),l(10,"spk-icon",25),m(11,"textbox"),a()()()()}if(n&2){let e=s().$implicit;r(2),F(" ",e.FormView.shortDescription," "),r(3),c("ngModel",e.Name),r(4),c("ngModel",e.Value())}}function ge(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Ce(n,o){if(n&1){let e=x();l(0,"app-file-tree",18)(1,"label",26),m(2),C(3,ge,3,1,"spk-tooltip",27),a(),l(4,"input",28),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a()()}if(n&2){let e=s(),i=e.$implicit,t=e.$index;c("startingPath",i.Value())("accepts",i.FormView.accepts)("showFiles",!0)("showHiddenNodes",!0)("selectFiles",!0),r(),g("for","destination-",i.Name,"-",t,""),r(),F(" ",i.FormView.shortDescription," "),r(),S(i.FormView.longDescription?3:-1),r(),g("id","destination-",i.Name,"-",t,""),c("ngModel",i.Value())}}function xe(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function fe(n,o){if(n&1){let e=x();l(0,"app-file-tree",19)(1,"label",26),m(2),C(3,xe,3,1,"spk-tooltip",27),a(),l(4,"input",28),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a()()}if(n&2){let e=s(),i=e.$implicit,t=e.$index;c("startingPath",i.Value()),r(),g("for","destination-",i.Name,"-",t,""),r(),F(" ",i.FormView.shortDescription," "),r(),S(i.FormView.longDescription?3:-1),r(),g("id","destination-",i.Name,"-",t,""),c("ngModel",i.Value())}}function Se(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Fe(n,o){n&1&&(l(0,"spk-icon",25),m(1,"link"),a())}function Te(n,o){n&1&&(l(0,"spk-icon",25),m(1,"textbox"),a())}function we(n,o){if(n&1){let e=x();l(0,"spk-form-field")(1,"label",26),m(2),C(3,Se,3,1,"spk-tooltip",27),a(),l(4,"input",28),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a(),C(5,Fe,2,0,"spk-icon",25)(6,Te,2,0,"spk-icon",25),a()}if(n&2){let e=s(),i=e.$implicit,t=e.$index;r(),g("for","destination-",i.Name,"-",t,""),r(),F(" ",i.FormView.shortDescription," "),r(),S(i.FormView.longDescription?3:-1),r(),g("id","destination-",i.Name,"-",t,""),c("ngModel",i.Value()),r(),S(i.FormView.type==="Path"?5:6)}}function Ve(n,o){if(n&1){let e=x();l(0,"spk-icon",31),f("click",function(){d(e);let t=s(2).$implicit;return u(t.showPassword=!t.showPassword)}),m(1," eye "),a()}}function Oe(n,o){if(n&1){let e=x();l(0,"spk-icon",31),f("click",function(){d(e);let t=s(2).$implicit;return u(t.showPassword=!t.showPassword)}),m(1," eye-slash "),a()}}function ye(n,o){if(n&1){let e=x();l(0,"spk-form-field")(1,"label",26),m(2),a(),l(3,"input",29),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a(),l(4,"spk-icon",25),m(5,"password"),a(),C(6,Ve,2,0,"spk-icon",30)(7,Oe,2,0,"spk-icon",30),a()}if(n&2){let e=s(),i=e.$implicit,t=e.$index;r(),g("for","destination-",i.Name,"-",t,""),r(),F(" ",i.FormView.shortDescription," "),r(),g("id","destination-",i.Name,"-",t,""),c("type",i.showPassword?"text":"password")("ngModel",i.Value()),r(3),S(i.showPassword?6:7)}}function ke(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Ie(n,o){if(n&1&&m(0),n&2){let e=o.$implicit;F(" ",e," ")}}function he(n,o){if(n&1){let e=x();l(0,"spk-select",32)(1,"label",26),m(2),C(3,ke,3,1,"spk-tooltip",27),a(),l(4,"input",28),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a()(),C(5,Ie,1,1,"ng-template",null,1,A)}if(n&2){let e=E(6),i=s(),t=i.$implicit,p=i.$index;c("options",t.FormView.options)("isClearable",!1)("optionTemplate",e),r(),g("for","destination-",t.Name,"-",p,""),r(),F(" ",t.FormView.shortDescription," "),r(),S(t.FormView.longDescription?3:-1),r(),g("id","destination-",t.Name,"-",p,""),c("ngModel",t.Value())}}function Me(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Ne(n,o){if(n&1){let e=x();l(0,"app-size",33),b("ngModelChange",function(t){d(e);let p=s().$implicit;return D(p.Value,t)||(p.Value=t),u(t)}),l(1,"label",26),m(2),C(3,Me,3,1,"spk-tooltip",27),a()()}if(n&2){let e,i=s(),t=i.$implicit,p=i.$index;c("inputType",t.Name),v("ngModel",t.Value),c("customId","destination-{{ item.Name }}-{{ $index }}"),r(),g("for","destination-",t.Name,"-",p,""),r(),F(" ",(e=t.FormView.shortDescription)!==null&&e!==void 0?e:t.FormView.name," "),r(),S(t.FormView.longDescription?3:-1)}}function $e(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Pe(n,o){if(n&1){let e=x();l(0,"spk-form-field")(1,"label",26),m(2),C(3,$e,3,1,"spk-tooltip",27),a(),l(4,"input",34),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a(),l(5,"spk-icon",25),m(6,"numpad"),a()()}if(n&2){let e=s(),i=e.$implicit,t=e.$index;r(),g("for","destination-",i.Name,"-",t,""),r(),F(" ",i.FormView.shortDescription," "),r(),S(i.FormView.longDescription?3:-1),r(),g("id","destination-",i.Name,"-",t,""),c("ngModel",i.Value())}}function Ee(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Le(n,o){if(n&1){let e=x();l(0,"spk-toggle",21)(1,"label",26),m(2),C(3,Ee,3,1,"spk-tooltip",27),a(),l(4,"input",35),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a()()}if(n&2){let e=s(),i=e.$implicit,t=e.$index;r(),g("for","destination-",i.Name,"-",t,""),r(),F(" ",i.FormView.shortDescription," "),r(),S(i.FormView.longDescription?3:-1),r(),g("id","destination-",i.Name,"-",t,""),c("ngModel",i.Value())}}function ve(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function De(n,o){if(n&1&&m(0),n&2){let e=o.$implicit;F(" ",e," ")}}function be(n,o){if(n&1){let e=x();l(0,"spk-select",36)(1,"label",26),m(2),C(3,ve,3,1,"spk-tooltip",27),a(),l(4,"input",37),f("ngModelChange",function(t){d(e);let p=s().$implicit,_=s();return u(_.updateSettingValue(p,t))}),a()(),C(5,De,1,1,"ng-template",null,2,A)}if(n&2){let e=E(6),i=s(),t=i.$implicit,p=i.$index;c("options",t.FormView.options)("selectMultiple",!0)("optionTemplate",e),r(),g("for","destination-",t.Name,"-",p,""),r(),F(" ",t.FormView.shortDescription," "),r(),S(t.FormView.longDescription?3:-1),r(),c("ngModel",t.Value())}}function Ae(n,o){if(n&1&&(l(0,"spk-tooltip",27)(1,"spk-icon"),m(2,"question"),a()()),n&2){let e=s(2).$implicit;c("message",e.FormView.longDescription)}}function Re(n,o){if(n&1){let e=x();l(0,"app-timespan",33),b("ngModelChange",function(t){d(e);let p=s().$implicit;return D(p.Value,t)||(p.Value=t),u(t)}),l(1,"label",26),m(2),C(3,Ae,3,1,"spk-tooltip",27),a()()}if(n&2){let e,i=s(),t=i.$implicit,p=i.$index;c("inputType",t.Name),v("ngModel",t.Value),c("customId","destination-{{ item.Name }}-{{ $index }}"),r(),g("for","destination-",t.Name,"-",p,""),r(),F(" ",(e=t.FormView.shortDescription)!==null&&e!==void 0?e:t.FormView.name," "),r(),S(t.FormView.longDescription?3:-1)}}function Be(n,o){if(n&1){let e=x();l(0,"div",13),C(1,ue,12,3,"div",17)(2,Ce,5,14,"app-file-tree",18)(3,fe,5,10,"app-file-tree",19)(4,we,7,10,"spk-form-field")(5,ye,8,10,"spk-form-field")(6,he,7,12)(7,Ne,4,8,"app-size",20)(8,Pe,7,9,"spk-form-field")(9,Le,5,9,"spk-toggle",21)(10,be,7,9)(11,Re,4,8,"app-timespan",20),l(12,"button",22),f("click",function(){let t=d(e).$implicit,p=s();return u(p.removeSetting(t))}),l(13,"spk-icon"),m(14,"x-bold"),a()()()}if(n&2){let e=o.$implicit;r(),S(e.FormView.type==="FreeText"?1:e.FormView.type==="FileTree"?2:e.FormView.type==="FolderTree"?3:e.FormView.type==="String"||e.FormView.type==="Path"||e.FormView.type==="Decimal"?4:e.FormView.type==="Password"?5:e.FormView.type==="Enumeration"?6:e.FormView.type==="Size"?7:e.FormView.type==="Integer"?8:e.FormView.type==="Boolean"?9:e.FormView.type==="Flags"?10:e.FormView.type==="Timespan"||e.FormView.type==="DateTime"?11:-1)}}var ae=class n{#e=B(Y);options=G.required();hiddenOptions=I([]);hasFreeTextSettings=I(!1);allOptionsGrouped=this.#e.allOptionsGrouped;allOptions=this.#e.allOptions;selectedSettings=R(()=>{let o=this.hiddenOptions();return this.options().map(t=>{let p=this.allOptions().find(_=>_.name===t.Name?.replace("--",""));if(p&&!o.includes(p.name)){let _=t.Value??"";p.type==="Boolean"&&(_=_&&_.toLowerCase()==="true"||!1),p.type==="Integer"&&(_=parseInt(_)||0);let se=h(_);return w(T({},t),{Value:se,FormView:p})}else if(this.hasFreeTextSettings())return w(T({},t),{Value:h(t.Value),FormView:{name:t.Name,type:"FreeText",shortDescription:"Custom settings argument",longDescription:"Custom settings argument"}});return null}).filter(t=>t!==null)});nonSelectedOptionsGrouped=R(()=>{let o=this.options().map(i=>i.Name),e=this.hiddenOptions();return this.allOptionsGrouped().map(i=>w(T({},i),{options:i.options.filter(t=>!o.includes(t.name)&&!e.includes(t.name))})).filter(i=>i.options.length>0)});addFreeTextSetting(){this.hasFreeTextSettings()&&this.options.update(o=>[...o,{Filter:null,Name:"",Value:""}])}addSetting(o){this.options.update(e=>{let i=o.defaultValue??"";return o.type==="Boolean"&&(i=i.toLowerCase()==="true"||!1),o.type==="Integer"&&(i=parseInt(i)||0),[...e,{Name:o.name,Value:i}]})}updateSettingValue(o,e){this.options.update(i=>{let t=[...i],p=t.findIndex(_=>_.Name===o.Name);return o.FormView.type==="Boolean"?(t[p].Value=e?"True":"False",t):o.FormView.type==="Integer"?(t[p].Value=e.toString(),t):(t[p].Value=e,t)})}updateFreeTextSettingName(o,e){this.options.update(i=>{let t=[...i],p=t.findIndex(_=>_.Name===o.Name);return t[p].Name=e,t})}removeSetting(o){this.options.update(e=>e.filter(i=>i.Name!==o.Name))}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=z({type:n,selectors:[["app-options-list"]],inputs:{options:[1,"options"],hiddenOptions:[1,"hiddenOptions"],hasFreeTextSettings:[1,"hasFreeTextSettings"]},outputs:{options:"optionsChange"},decls:16,vars:4,consts:()=>{let o;o=$localize`Advanced options`;let e;e=$localize` Add advanced option ${"\uFFFD#9\uFFFD"}:START_TAG_SPK_ICON:plus${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SPK_ICON:`;let i;return i=$localize` New custom option ${"\uFFFD#2\uFFFD"}:START_TAG_SPK_ICON:pen${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SPK_ICON:`,[["option",""],["enumOptionTemplate",""],["optionTemplate",""],o,e,i,[3,"disallowToggle"],["title",""],[1,"actions"],["spk-button","","type","button",1,"outlined","small"],[3,"searchable"],["menu",""],[1,"placeholder"],[1,"field-row"],["spk-button","","type","button",1,"outlined","small",3,"click"],["type","button"],["type","button",3,"click"],[1,"form-column"],[3,"startingPath","accepts","showFiles","showHiddenNodes","selectFiles"],[3,"startingPath"],[3,"inputType","ngModel","customId"],[1,"primary","raised"],["spk-button","","type","button",1,"outlined","remove-btn",3,"click"],[1,"form-row"],["type","text",3,"ngModelChange","ngModel"],["prefix",""],[3,"for"],[1,"primary",3,"message"],["type","text",3,"ngModelChange","id","ngModel"],["autocomplete","off",3,"ngModelChange","type","id","ngModel"],["suffix","",1,"clickable"],["suffix","",1,"clickable",3,"click"],[3,"options","isClearable","optionTemplate"],[3,"ngModelChange","inputType","ngModel","customId"],["type","number",3,"ngModelChange","id","ngModel"],["type","checkbox",3,"ngModelChange","id","ngModel"],[1,"primary","raised",3,"options","selectMultiple","optionTemplate"],["type","text","id","text",3,"ngModelChange","ngModel"]]},template:function(e,i){e&1&&(l(0,"spk-toggle-card",6),N(1,7)(2),q(3,3),k(),l(4,"div",8),C(5,me,3,0,"button",9),l(6,"spk-menu",10)(7,"button",9),$(8,4),M(9,"spk-icon"),P(),a(),N(10,11),O(11,ce,4,1,null,null,V),k(),a()(),k(),C(13,de,2,0,"div",12),O(14,Be,15,1,"div",13,V),a()),e&2&&(c("disallowToggle",!0),r(5),S(i.hasFreeTextSettings()?5:-1),r(),c("searchable",!0),r(5),y(i.nonSelectedOptionsGrouped()),r(2),S(i.selectedSettings().length===0?13:-1),r(),y(i.selectedSettings()))},dependencies:[oe,ee,ne,Z,te,ie,re,H,W,U,X,Q,K,j,J,le,pe],styles:["[_nghost-%COMP%]{display:block}spk-select[_ngcontent-%COMP%]{--miw: p2r(120)}spk-toggle[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:1rem}.placeholder[_ngcontent-%COMP%]{color:var(--base-level-60R);text-align:center;padding:2rem 1rem}.field-row[_ngcontent-%COMP%]{display:grid;align-items:center;grid-template-columns:1fr 2.5rem;gap:.5rem}.field-row[_ngcontent-%COMP%] .remove-btn[_ngcontent-%COMP%]{align-self:flex-end}.form-column[_ngcontent-%COMP%]{display:flex;gap:.25rem;flex-direction:column}.form-column[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem}.form-column[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:1rem}.form-row[_ngcontent-%COMP%]{display:grid;grid-template-columns:3fr 1fr;gap:.5rem;align-items:flex-end}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;justify-content:flex-end}"],changeDetection:0})};export{ae as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as ae}from"./chunk-B26K7HTR.js";import{l as le}from"./chunk-JYXXSXNP.js";import{a as ie,b as se}from"./chunk-PUEJXHBQ.js";import"./chunk-HTJ5CVNN.js";import"./chunk-U467ZTQ4.js";import"./chunk-3KPWJPKG.js";import"./chunk-EQWH3TBL.js";import"./chunk-TQHNKGRL.js";import"./chunk-F2GEUOGZ.js";import"./chunk-BIZAKOYU.js";import"./chunk-RHW5QVAY.js";import{c as Z,e as J,h as ee,j as ne,s as te,t as oe}from"./chunk-ELMONRIG.js";import{b as V,d as q}from"./chunk-C6XTRC7P.js";import"./chunk-MAVZY7BL.js";import{a as Y,g as H,l as Q,t as j}from"./chunk-P4ZFQZCA.js";import"./chunk-S5EF63OY.js";import"./chunk-7L2WUS2V.js";import{$a as v,Db as t,Eb as i,Fb as T,Jb as M,Oc as k,Pb as S,Qb as O,Rb as r,Ua as p,Vb as I,Wb as c,Z as C,ea as P,fa as f,fc as U,gb as K,gc as X,lb as N,nc as u,oc as d,pc as m,ub as g,uc as W,va as x,wb as G,zb as F}from"./chunk-L72ALLHJ.js";import"./chunk-7CGTOI24.js";var _e=["formRef"],re=()=>["--skip-files-larger-than","dblock-size","encryption-module","no-encryption","--no-encryption","--exclude-files-attributes","keep-time","keep-versions","retention-policy"];function pe(s,a){s&1&&(S(0,1,1),T(1,"spk-icon",20),O())}function ce(s,a){s&1&&(t(0,"p",20),r(1,6),i())}function ue(s,a){s&1&&(t(0,"p"),r(1,7),i())}function de(s,a){if(s&1){let e=M();t(0,"p"),r(1,8),i(),t(2,"app-timespan",18),m("ngModelChange",function(l){P(e);let o=c();return d(o.optionsFields.backupRetentionTime,l)||(o.optionsFields.backupRetentionTime=l),f(l)}),t(3,"label",29),r(4,9),i()()}if(s&2){let e=c();p(2),g("customId","backupRetentionTime"),u("ngModel",e.optionsFields.backupRetentionTime)}}function me(s,a){if(s&1){let e=M();t(0,"p"),r(1,10),i(),t(2,"spk-form-field")(3,"label",30),r(4,11),i(),t(5,"input",31),m("ngModelChange",function(l){P(e);let o=c();return d(o.optionsFields.backupRetentionVersions,l)||(o.optionsFields.backupRetentionVersions=l),f(l)}),i()()}if(s&2){let e=c();p(5),u("ngModel",e.optionsFields.backupRetentionVersions)}}function Se(s,a){s&1&&(t(0,"p"),r(1,12),i())}function Oe(s,a){if(s&1){let e=M();t(0,"p"),r(1,13),i(),t(2,"spk-form-field")(3,"p"),r(4,14),i(),t(5,"label",32),r(6,15),i(),t(7,"input",33),m("ngModelChange",function(l){P(e);let o=c();return d(o.optionsFields.backupRetentionCustom,l)||(o.optionsFields.backupRetentionCustom=l),f(l)}),i()()}if(s&2){let e=c();p(7),u("ngModel",e.optionsFields.backupRetentionCustom)}}var ge=["Bytes","KB","MB","GB","TB","PB"],Te=[{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,h=class s{#e=C(le);#n=C(q);#t=C(V);formRef=v.required("formRef");selectedOptions=this.#e.selectedOptions;nonSelectedOptions=this.#e.nonSelectedOptions;isSubmitting=this.#e.isSubmitting;settings=this.#e.settings;optionsFields=this.#e.optionsFields;retentionOptions=x(Te);sizeSplit=k(()=>{let e=this.optionsFields.remoteVolumeSize().match(/^(\d+)(bytes|kb|mb|gb|tb|pb|b)$/i);return{value:e?parseInt(e[1],10):0,unit:e?e[2].toUpperCase():"MB"}});exceededVolumeSize=k(()=>{let a=this.sizeSplit().value,e=this.sizeSplit().unit;if(a==null||e===null||e===void 0)return!1;let n=a*Math.pow(1024,ge.indexOf(e));return n>Ce||n<Pe});goBack(){this.#n.navigate(["schedule"],{relativeTo:this.#t.parent})}submit(){this.#e.submit()}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=K({type:s,selectors:[["app-advanced-options-settings"]],viewQuery:function(e,n){e&1&&U(n.formRef,_e,5),e&2&&X()},decls:30,vars:14,consts:()=>{let a;a=$localize`Options`;let e;e=$localize` Remote volume size ${"\uFFFD*7:1\uFFFD"}:START_BLOCK_IF:${"\uFFFD#1:1\uFFFD"}:START_TAG_SPK_ICON:warning${"\uFFFD/#1:1\uFFFD"}:CLOSE_TAG_SPK_ICON:${"\uFFFD/*7:1\uFFFD"}:CLOSE_BLOCK_IF:`;let n;n=$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_SPK_ICON:arrow-square-out${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SPK_ICON:${"\uFFFD/#11\uFFFD"}:CLOSE_LINK:`;let l;l=$localize`Backup retention`;let o;o=$localize`${"\uFFFD#26\uFFFD"}:START_TAG_SPK_ICON:arrow-left${"\uFFFD/#26\uFFFD"}:CLOSE_TAG_SPK_ICON: Go back `;let E;E=$localize`${"\uFFFD#29\uFFFD"}:START_TAG_SPK_ICON:arrow-right${"\uFFFD/#29\uFFFD"}:CLOSE_TAG_SPK_ICON: Submit `;let b;b=$localize` The chosen size is outside the recommended range. This may cause performance issues, excessively large temporary files or other problems. `;let A;A=$localize`Nothing will be deleted. The backup size will grow with each change.`;let R;R=$localize`If at least one newer backup is found, all backups older than this date are deleted.`;let y;y=$localize`Time to keep versions`;let $;$=$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`,[a,e,n,l,o,E,b,A,R,y,$,w,D,B,L,z,[1,"title-30"],[1,"remote-volume-wrap"],[3,"ngModelChange","customId","ngModel"],["for","size"],[1,"warning"],["href","https://forum.duplicati.com/t/choosing-sizes-in-duplicati/17683","target","_blank",1,"spk-primary"],["suffix",""],["value","value","label","name",3,"options","inlineSearch","isClearable"],["type","text",3,"ngModelChange","ngModel"],[3,"optionsChange","options","hiddenOptions"],[1,"form-actions"],["spk-button","","type","button",3,"click"],["spk-button","",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(e,n){e&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(n.optionsFields.remoteVolumeSize,o)||(n.optionsFields.remoteVolumeSize=o),o}),t(5,"label",19),S(6,1),N(7,pe,2,0,"spk-icon",20),O(),i()(),N(8,ce,2,0,"p",20),t(9,"p"),S(10,2),t(11,"a",21),T(12,"spk-icon",22),i(),O(),i()(),t(13,"spk-select",23)(14,"label",19),r(15,3),i(),t(16,"input",24),m("ngModelChange",function(o){return d(n.optionsFields.backupRetention,o)||(n.optionsFields.backupRetention=o),o}),i()(),N(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",25),m("optionsChange",function(o){return d(n.settings,o)||(n.settings=o),o}),i(),t(23,"div",26)(24,"button",27),I("click",function(){return n.goBack()}),S(25,4),T(26,"spk-icon"),O(),i(),t(27,"button",28),I("click",function(){return n.submit()}),S(28,5),T(29,"spk-icon"),O(),i()()()),e&2&&(p(4),g("customId","size"),u("ngModel",n.optionsFields.remoteVolumeSize),p(3),F(n.exceededVolumeSize()?7:-1),p(),F(n.exceededVolumeSize()?8:-1),p(5),g("options",n.retentionOptions())("inlineSearch",!0)("isClearable",!1),p(3),u("ngModel",n.optionsFields.backupRetention),p(),F(n.optionsFields.backupRetention()==="all"?17:n.optionsFields.backupRetention()==="time"?18:n.optionsFields.backupRetention()==="versions"?19:n.optionsFields.backupRetention()==="smart"?20:n.optionsFields.backupRetention()==="custom"?21:-1),p(5),u("options",n.settings),g("hiddenOptions",W(13,re)),p(5),G("loader",n.isSubmitting()))},dependencies:[te,Z,ne,J,ee,oe,ae,H,Y,j,ie,se,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-column[_ngcontent-%COMP%]{display:flex;flex-direction:column}.form-column[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem}.form-column[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:1rem}.field-row[_ngcontent-%COMP%]{display:grid;align-items:flex-end;grid-template-columns:1fr 2.5rem;gap:.5rem}.form-row[_ngcontent-%COMP%]{display:grid;grid-template-columns:3fr 1fr;gap:.5rem;align-items:flex-end}.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 40px;align-items:flex-end}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}spk-select[_ngcontent-%COMP%]{--miw: p2r(120)}"],changeDetection:0})};export{h as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as m}from"./chunk-
|
|
1
|
+
import{a as m}from"./chunk-PH5P3W5Z.js";import{h as u}from"./chunk-S5EF63OY.js";import{B as h,E as s,F as p,P as d,Pc as N,T as l,Z as r,n as c,va as o,x as f}from"./chunk-L72ALLHJ.js";var b=class a{#e=r(u);#s=r(m);serverState=this.#s.serverState;serverStateEffect=N(()=>{let t=this.#s.serverState();t?.LastNotificationUpdateID&&this.updateLastNotificationEventId(t?.LastNotificationUpdateID)});#o=-1;#a=o(!1);#t=o([]);#i=o([]);notifications=this.#t.asReadonly();init(){this.notifications().length===0&&this.getNotifications()}updateLastNotificationEventId(t){this.#o!==t&&(this.#o=t,this.getNotifications())}getNotifications(){this.#a.set(!0),this.#e.getApiV1Notifications().pipe(s(1),d(t=>this.#t.set(t)),p(()=>this.#a.set(!1))).subscribe()}getNofication(t){this.#e.getApiV1NotificationById({id:t}).pipe(s(1)).subscribe()}deleteNotification(t){let i=this.#t(),e=i[t];this.#i.set(i),i.splice(t,1),this.#t.set(i),this.#e.deleteApiV1NotificationById({id:e.ID}).pipe(s(1)).subscribe({error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}deleteAllNotifications(){let t=this.#t();this.#i.set(t),this.#t.set([]);let i=t.map(e=>this.#e.deleteApiV1NotificationById({id:e.ID}).pipe(h(()=>c(e))));f(i).pipe(s(1)).subscribe({next:e=>{let v=e.filter(n=>n!=null&&"ID"in n);this.#t.set(v),this.#i.set([])},error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}static \u0275fac=function(i){return new(i||a)};static \u0275prov=l({token:a,factory:a.\u0275fac,providedIn:"root"})};export{b as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as Ne}from"./chunk-JDSUBKXI.js";import{a as Ie}from"./chunk-R3PVYKQS.js";import{a as w}from"./chunk-CRR7DNOY.js";import"./chunk-PH5P3W5Z.js";import"./chunk-IINSQSHJ.js";import{a as Te}from"./chunk-FJVMA6GA.js";import"./chunk-BIZAKOYU.js";import"./chunk-RHW5QVAY.js";import"./chunk-HFIC4JNY.js";import{a as De}from"./chunk-CK7BEV2X.js";import{c as Ce,d as Ee,e as Pe,h as Oe,r as fe,s as he,t as ke}from"./chunk-ELMONRIG.js";import{a as ce,c as me}from"./chunk-BJGA55H2.js";import"./chunk-XP7PWMT2.js";import{c as le,e as re,f as _e}from"./chunk-C6XTRC7P.js";import"./chunk-MAVZY7BL.js";import{B as Ae,a as I,b,c as pe,e as ue,g as y,k as Se,l as de,n as ge,u as Fe}from"./chunk-P4ZFQZCA.js";import{h as H}from"./chunk-S5EF63OY.js";import"./chunk-7L2WUS2V.js";import{$a as Z,Ab as ee,Bb as te,Cb as ne,Db as s,Eb as i,F as B,Fb as _,Jb as O,Oc as ae,Pb as p,Pc as j,Qb as u,Rb as f,Ua as l,Ub as $,Vb as S,Wb as c,Z as g,bb as X,ea as T,fa as C,fc as oe,gb as N,gc as ie,ic as d,jc as V,kc as K,lb as m,nc as z,oc as W,pc as q,ra as J,ub as D,uc as se,va as P,wb as G,yb as R,zb as F}from"./chunk-L72ALLHJ.js";import{a as U,b as Y}from"./chunk-7CGTOI24.js";var $e=["scroller"];function ve(o,n){o&1&&(s(0,"spk-icon"),d(1,"bell-ringing"),i())}function Ge(o,n){o&1&&(s(0,"spk-icon"),d(1,"bell"),i())}function be(o,n){if(o&1&&(s(0,"div",9),d(1),i()),o&2){let e,t=c(2);l(),K(" ",(e=t.shownMessage())==null?null:e.content," ")}}function ye(o,n){if(o&1&&(s(0,"div",6)(1,"spk-alert")(2,"div",8),d(3),i(),m(4,be,2,1,"div",9),i()()),o&2){let e,t,a,r=c();l(),R((e=(e=r.shownMessage())==null?null:e.type)!==null&&e!==void 0?e:"error"),l(2),V((t=r.shownMessage())==null?null:t.title),l(),F((a=r.shownMessage())!=null&&a.content?4:-1)}}function He(o,n){if(o&1){let e=O();s(0,"div",7)(1,"div",10)(2,"h6",11),p(3,2),s(4,"button",5),S("click",function(){T(e);let a=c();return C(a.toggleNotifications())}),_(5,"spk-icon"),i(),u(),i(),s(6,"div",12,0)(8,"div",13),_(9,"app-notifications"),i()()()()}}function we(o,n){if(o&1&&(s(0,"div",17),d(1),i()),o&2){let e=c().$implicit;l(),K(" ",e.content," ")}}function xe(o,n){if(o&1){let e=O();s(0,"spk-alert",15,1),S("click",function(){let a=T(e).$implicit,r=c(2);return C(r.deleteAlertByIndex(a.id))}),s(2,"div",16),d(3),i(),m(4,we,2,1,"div",17),i()}if(o&2){let e=n.$implicit;R(e.type),D("id",e.id),l(3),V(e.title),l(),F(e.content?4:-1)}}function Ue(o,n){o&1&&(s(0,"p"),f(1,4),i())}function Ye(o,n){if(o&1){let e=O();s(0,"div",7)(1,"div",10)(2,"h6",11),p(3,3),s(4,"button",5),S("click",function(){T(e);let a=c();return C(a.toggleAlerts())}),_(5,"spk-icon"),i(),u(),i(),s(6,"div",12,0)(8,"div",13),te(9,xe,5,5,"spk-alert",14,ee,!1,Ue,2,0,"p"),i()()()()}if(o&2){let e=c();l(9),ne(e.alertHistory())}}var Me=new fe,v=class o{#e=g(pe);#t=g(w);isSubmitting=P(!1);messageSent=P(!1);form=Me.group({message:Me.control("",[Ee.required])});notifications=this.#t.notifications;shownMessage=P(null);shownMessageInterval=null;alertHistory=this.#e.alertHistory;alertHistoryIsOpen=this.#e.alertHistoryIsOpen;alertHistoryIsHidden=this.#e.alertHistoryIsHidden;numberOfOpenAlerts=ae(()=>this.alertHistory().filter(n=>n.isOpen).length);scroller=Z("scroller");isAlertsOpen=X(!1);isNotificationsOpen=X(!1);previousHistoryCount=P(null);constructor(){j(()=>{let n=this.alertHistory();n.length&&this.previousHistoryCount()!==n.length&&!this.isAlertsOpen()&&(this.shownMessage.set(Y(U({},n[0]),{countDown:3})),this.previousHistoryCount.set(n.length),this.shownMessageInterval=setInterval(()=>{let e=this.shownMessage();if(e?.countDown===0){this.shownMessage.set(null),this.shownMessageInterval=null;return}e!==null&&this.shownMessage.update(t=>Y(U({},t),{countDown:t.countDown-1}))},1e3))}),j(()=>{this.alertHistoryIsOpen(),this.scrollToBottom()})}resetPreviewMessage(){this.shownMessage.set(null),this.shownMessageInterval=null}toggleAlerts(){this.isAlertsOpen()?this.isAlertsOpen.set(!1):(this.isAlertsOpen.set(!0),this.isNotificationsOpen.set(!1),this.resetPreviewMessage())}toggleNotifications(){this.isNotificationsOpen.set(!this.isNotificationsOpen()),this.isAlertsOpen()&&this.isAlertsOpen.set(!1)}deleteAlertByIndex(n){this.#e.removeAlert(n)}scrollToBottom(){this.scroller()&&this.scroller()?.nativeElement&&this.scroller().nativeElement.scrollTo(0,this.scroller().nativeElement.scrollHeight)}static \u0275fac=function(e){return new(e||o)};static \u0275cmp=N({type:o,selectors:[["app-service-hub"]],viewQuery:function(e,t){e&1&&oe(t.scroller,$e,5),e&2&&ie()},inputs:{isAlertsOpen:[1,"isAlertsOpen"],isNotificationsOpen:[1,"isNotificationsOpen"]},outputs:{isAlertsOpen:"isAlertsOpenChange",isNotificationsOpen:"isNotificationsOpenChange"},decls:9,vars:8,consts:()=>{let n;n=$localize` Notifications ${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"\uFFFD#5\uFFFD"}:START_TAG_SPK_ICON:x-circle${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SPK_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_BUTTON:`;let e;e=$localize` Alerts ${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"\uFFFD#5\uFFFD"}:START_TAG_SPK_ICON:x-circle${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SPK_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_BUTTON:`;let t;return t=$localize`No alerts yet`,[["scroller",""],["alerts",""],n,e,t,["spk-button","",3,"click"],[1,"preview-alert-wrap"],[1,"alert-stream-modal"],["sparkle-alert-title",""],["sparkle-alert-content",""],[1,"alert-stream-modal-content"],[1,"paragraph-20"],[1,"alert-stream-modal-list-scroller"],[1,"alert-stream-modal-list"],[3,"class","id"],[3,"click","id"],["title",""],["content",""]]},template:function(e,t){e&1&&(s(0,"button",5),S("click",function(){return t.toggleAlerts()}),s(1,"spk-icon"),d(2,"info"),i()(),s(3,"button",5),S("click",function(){return t.toggleNotifications()}),m(4,ve,2,0,"spk-icon")(5,Ge,2,0,"spk-icon"),i(),m(6,ye,5,4,"div",6)(7,He,10,0,"div",7)(8,Ye,12,1,"div",7)),e&2&&(R(t.alertHistory().length?"error":""),l(3),R(t.notifications().length?"error":""),l(),F(t.notifications().length?4:5),l(2),F(t.shownMessage()?6:-1),l(),F(t.isNotificationsOpen()?7:-1),l(),F(t.isAlertsOpen()?8:-1))},dependencies:[ke,b,I,y,Ne],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:250px}.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-level-40);background-color:var(--base-level-10);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-level-40);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-level-40);background-color:var(--base-level-10);border-radius:var(--shape-2)}.alert-stream-modal-content[_ngcontent-%COMP%] h6[_ngcontent-%COMP%]{padding:1rem;border-bottom:1px solid var(--base-level-40);display:flex;align-items:center;justify-content:space-between}"],changeDetection:0})};function Be(o,n){o&1&&(s(0,"spk-icon",14),d(1,"check"),i())}function Xe(o,n){o&1&&(s(0,"spk-icon",15),d(1,"prohibit"),i())}function Ve(o,n){if(o&1){let e=O();s(0,"button",20),S("click",function(){T(e);let a=c();return C(a.updatePassphrase())}),f(1,5),i()}if(o&2){let e=c();G("loader",e.isUpdating())}}function Ke(o,n){if(o&1){let e=O();s(0,"spk-tooltip",19)(1,"button",21),S("click",function(){T(e);let a=c();return C(a.updatePassphrase())}),f(2,6),i()()}if(o&2){let e=c();l(),G("loader",e.isUpdating()),D("disabled",!0)}}var x=class o{#e=g(H);closed=J();isUpdating=P(!1);passphrase=P("");repeatPassphrase=P("");updatePassphrase(){this.passphrase()===this.repeatPassphrase()&&(this.isUpdating.set(!0),this.#e.patchApiV1Serversettings({requestBody:{"server-passphrase":this.passphrase()}}).pipe(B(()=>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(B(()=>this.isUpdating.set(!1))).subscribe({next:()=>this.closed.emit()})}static \u0275fac=function(e){return new(e||o)};static \u0275cmp=N({type:o,selectors:[["app-change-passphrase-alert-dialog"]],outputs:{closed:"closed"},decls:23,vars:7,consts:()=>{let n;n=$localize`Enter new password`;let e;e=$localize`Repeat password`;let t;t=$localize`Password have to be filled and have to match`;let a;a=$localize`Change passphrase`;let r;r=$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? `,r=$(r);let h;h=$localize`Passphrase`;let k;k=$localize`Repeat passphrase`;let M;M=$localize`Not now thanks`;let L;L=$localize` Yes, update passphrase now `;let A;return A=$localize` Yes, update passphrase now `,[a,r,h,k,M,L,A,["header",""],["content",""],["type","warning"],["for","password"],["type","password","name","password","autocomplete","disabled","placeholder",n,"tabindex","1",3,"ngModelChange","ngModel"],["for","repeatPassword"],["type","password","name","repeatPassword","autocomplete","disabled","placeholder",e,"tabindex","2",3,"ngModelChange","disabled","ngModel"],["suffix","",1,"spk-success"],["suffix",""],["footer",""],["spk-button","",3,"click"],["spk-button","",1,"raised","primary",3,"loader"],["message",t,1,"primary"],["spk-button","",1,"raised","primary",3,"click"],["spk-button","",1,"raised","primary",3,"click","disabled"]]},template:function(e,t){e&1&&(s(0,"header",7)(1,"h3"),f(2,0),i()(),s(3,"div",8)(4,"spk-alert",9),p(5,1),_(6,"br")(7,"br"),u(),i(),s(8,"spk-form-field")(9,"label",10),f(10,2),i(),s(11,"input",11),q("ngModelChange",function(r){return W(t.passphrase,r)||(t.passphrase=r),r}),i()(),s(12,"spk-form-field")(13,"label",12),f(14,3),i(),s(15,"input",13),q("ngModelChange",function(r){return W(t.repeatPassphrase,r)||(t.repeatPassphrase=r),r}),i(),m(16,Be,2,0,"spk-icon",14)(17,Xe,2,0,"spk-icon",15),i()(),s(18,"footer",16)(19,"button",17),S("click",function(){return t.cancel()}),f(20,4),i(),m(21,Ve,2,2,"button",18)(22,Ke,3,3,"spk-tooltip",19),i()),e&2&&(l(11),z("ngModel",t.passphrase),l(4),D("disabled",t.passphrase().length===0),z("ngModel",t.repeatPassphrase),l(),F(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?16:17),l(3),G("loader",t.isUpdating()),l(2),F(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?21:22))},dependencies:[he,Ce,Pe,Oe,b,de,I,Ae],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 We(o,n){o&1&&(s(0,"spk-icon"),d(1,"sun"),i())}function qe(o,n){o&1&&(s(0,"spk-icon"),d(1,"moon"),i())}function je(o,n){if(o&1){let e=O();s(0,"button",21),S("click",function(){T(e);let a=c();return C(a.changeDefaultClientTo("ngax"))}),p(1,7),_(2,"spk-icon"),u(),i(),s(3,"button",21),S("click",function(){T(e);let a=c();return C(a.logout())}),p(4,8),_(5,"spk-icon"),u(),i()}}var Q=class o{#e=g(Ie);#t=g(H);#n=g(Te);#o=g(ce);#i=g(ue);#s=g(w);#a=g(me);relayIsEnabled=this.#o.relayIsEnabled;isDarkMode=this.#e.isDarkMode;ngOnInit(){return this.#s.init(),this.#n.getBackups(!0),this.#t.getApiV1Serversettings().subscribe({next:n=>{let e=n["autogenerated-passphrase"]==="True",t=n["has-asked-for-password-change"]==="True";e&&!t&&this.#i.open(x,{maxWidth:"500px"})}})}toggleBodyClass(){this.#e.toggleBodyClass()}changeDefaultClientTo(n){this.#l(n),window.location.replace(`/${n}`)}logout(){this.#a.logout()}#l(n){var e=new Date;e.setTime(e.getTime()+90*24*60*60*1e3),document.cookie="default-client="+n+"; expires="+e.toUTCString()+"; path=/"}static \u0275fac=function(e){return new(e||o)};static \u0275cmp=N({type:o,selectors:[["app-layout"]],decls:37,vars:4,consts:()=>{let n;n=$localize`${"\uFFFD#10\uFFFD"}:START_TAG_SPK_ICON:house${"\uFFFD/#10\uFFFD"}:CLOSE_TAG_SPK_ICON: Home `;let e;e=$localize`${"\uFFFD#13\uFFFD"}:START_TAG_SPK_ICON:database${"\uFFFD/#13\uFFFD"}:CLOSE_TAG_SPK_ICON: Add backup `;let t;t=$localize`${"\uFFFD#16\uFFFD"}:START_TAG_SPK_ICON:clock-counter-clockwise${"\uFFFD/#16\uFFFD"}:CLOSE_TAG_SPK_ICON: Restore `;let a;a=$localize`${"\uFFFD#19\uFFFD"}:START_TAG_SPK_ICON:gear${"\uFFFD/#19\uFFFD"}:CLOSE_TAG_SPK_ICON: Settings `;let r;r=$localize`${"\uFFFD#26\uFFFD"}:START_TAG_SPK_ICON:info${"\uFFFD/#26\uFFFD"}:CLOSE_TAG_SPK_ICON: About Duplicati `;let h;h=$localize`${"\uFFFD#29\uFFFD"}:START_TAG_SPK_ICON:files${"[\uFFFD/#29\uFFFD|\uFFFD/#30\uFFFD]"}:CLOSE_TAG_SPK_ICON: Documentation ${"\uFFFD#30\uFFFD"}:START_TAG_SPK_ICON_1:arrow-square-out${"[\uFFFD/#29\uFFFD|\uFFFD/#30\uFFFD]"}:CLOSE_TAG_SPK_ICON:`,h=$(h);let k;k=$localize`${"\uFFFD#33\uFFFD"}:START_TAG_SPK_ICON:chats-circle${"[\uFFFD/#33\uFFFD|\uFFFD/#34\uFFFD]"}:CLOSE_TAG_SPK_ICON: Visit forum ${"\uFFFD#34\uFFFD"}:START_TAG_SPK_ICON_1:arrow-square-out${"[\uFFFD/#33\uFFFD|\uFFFD/#34\uFFFD]"}:CLOSE_TAG_SPK_ICON:`,k=$(k);let M;M=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SPK_ICON:skip-back${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SPK_ICON: Revert to NGAX client `;let L;return L=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SPK_ICON:sign-out${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SPK_ICON: Log out `,[n,e,t,a,r,h,k,M,L,["sidenav",""],["spk-button","",1,"icon","small",3,"click"],[1,"base-level-20","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"],["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,"spk-sidenav")(1,"div",9)(2,"header"),_(3,"app-logo"),s(4,"button",10),S("click",function(){return t.toggleBodyClass()}),m(5,We,2,0,"spk-icon")(6,qe,2,0,"spk-icon"),i()(),s(7,"spk-list",11)(8,"button",12),p(9,0),_(10,"spk-icon"),u(),i(),s(11,"button",13),p(12,1),_(13,"spk-icon"),u(),i(),s(14,"button",14),p(15,2),_(16,"spk-icon"),u(),i(),s(17,"button",15),p(18,3),_(19,"spk-icon"),u(),i()(),_(20,"div",16),s(21,"spk-list",11),m(22,je,6,0),_(23,"spk-divider"),s(24,"button",17),p(25,4),_(26,"spk-icon"),u(),i(),s(27,"a",18),p(28,5),_(29,"spk-icon")(30,"spk-icon",19),u(),i(),s(31,"a",20),p(32,6),_(33,"spk-icon")(34,"spk-icon",19),u(),i()()(),_(35,"router-outlet")(36,"app-service-hub"),i()),e&2&&(l(5),F(t.isDarkMode()?5:6),l(3),D("routerLinkActiveOptions",se(3,ze)),l(14),F(t.relayIsEnabled()?-1:22))},dependencies:[le,re,_e,Fe,I,ge,y,Se,v,De],styles:["[_nghost-%COMP%]{height:100vh;width:100%;overflow:hidden}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:20px;gap:12px}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{Q as default};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import{a as Ee}from"./chunk-B26K7HTR.js";import{a as fe}from"./chunk-GM4QKN65.js";import{l as P}from"./chunk-JYXXSXNP.js";import"./chunk-PUEJXHBQ.js";import"./chunk-HTJ5CVNN.js";import{a as Se}from"./chunk-U467ZTQ4.js";import"./chunk-3KPWJPKG.js";import"./chunk-EQWH3TBL.js";import{a as T}from"./chunk-TQHNKGRL.js";import"./chunk-F2GEUOGZ.js";import{a as le}from"./chunk-PH5P3W5Z.js";import"./chunk-IINSQSHJ.js";import"./chunk-FJVMA6GA.js";import"./chunk-BIZAKOYU.js";import"./chunk-RHW5QVAY.js";import"./chunk-HFIC4JNY.js";import{c as se,e as me,f as de,i as pe,m as _e,n as ce,o as ue,q as Ce,r as ge,s as Me,t as Ne}from"./chunk-ELMONRIG.js";import"./chunk-BJGA55H2.js";import"./chunk-XP7PWMT2.js";import{b as q,d as Z,e as J}from"./chunk-C6XTRC7P.js";import"./chunk-MAVZY7BL.js";import{a as Q,e as Y,g as ee,k as te,l as ne,p as oe,t as ie}from"./chunk-P4ZFQZCA.js";import{g as ae,h as re}from"./chunk-S5EF63OY.js";import"./chunk-JFNFY6VY.js";import"./chunk-7L2WUS2V.js";import"./chunk-DOP6RFEG.js";import{Ab as R,Bb as y,Cb as v,Db as r,Eb as o,Fb as l,Gb as A,Hb as O,Jb as G,Pb as M,Pc as H,Qb as N,Rb as c,Sb as x,Tb as U,Ua as m,Vb as K,Wb as f,Z as _,_b as w,ea as S,fa as E,gb as $,lb as h,nc as X,oc as z,pc as V,tc as W,ub as C,uc as j,va as F,wb as b,zb as B}from"./chunk-L72ALLHJ.js";import"./chunk-7CGTOI24.js";var Fe=()=>[];function Ae(s,t){s&1&&l(0,"spk-progress-bar",12)}function Oe(s,t){if(s&1&&(r(0,"spk-form-field"),l(1,"input",32),o()),s&2){let e=t.$implicit,i=t.$index;m(),w("id","filter-",i,""),C("formControl",e)}}function Te(s,t){if(s&1){let e=G();r(0,"form",13)(1,"spk-select",14)(2,"label",15),c(3,1),o(),l(4,"input",16),o(),r(5,"spk-form-field")(6,"label",17),c(7,2),o(),l(8,"textarea",18),o(),r(9,"spk-form-field")(10,"label",19),c(11,3),o(),l(12,"textarea",20),o()(),r(13,"spk-divider"),c(14,4),o(),r(15,"form",13)(16,"spk-form-field")(17,"label",21),c(18,5),o(),l(19,"input",22),o(),r(20,"spk-form-field")(21,"label",23),c(22,6),o(),l(23,"input",24),o(),r(24,"app-toggle-card",25),A(25,26),c(26,7),O(),A(27,27),y(28,Oe,2,3,"spk-form-field",null,R),O(),o()(),r(30,"p"),M(31,8),l(32,"a",28),N(),o(),r(33,"app-options-list",29),V("optionsChange",function(a){S(e);let u=f();return z(u.settings,a)||(u.settings=a),E(a)}),o(),r(34,"div",30)(35,"button",31),K("click",function(){S(e);let a=f();return E(a.submit())}),M(36,9),l(37,"spk-icon"),N(),o()()}if(s&2){let e,i=f();C("formGroup",i.baseCmdForm),m(),C("options",(e=i.commandOptions())!==null&&e!==void 0?e:j(10,Fe))("inlineSearch",!0),m(14),C("formGroup",i.standardFields),m(9),C("disallowToggle",!0),m(4),v(i.standardFields.controls.filters.controls),m(5),X("options",i.settings),C("hasFreeTextSettings",!0),m(2),b("loader",i.isSubmitting()),m(2),x(i.baseCmdForm.value.command),U(36)}}var d=new ge,Pe=["Bytes","KB","MB","GB","TB","PB"],I=class s{#e=_(P);#t=_(re);#n=_(Z);#o=_(q);#i=_(ae);#a=_(le);#s=_(Y);#r=T(this.#o.params);commandOptions=T(this.#i.getApiV1Commandline());sizeOptions=F(Pe);isSubmitting=F(!1);optionsFields=this.#e.optionsFields;standardFields=d.group({"backup-id":d.control(""),"backup-name":d.control(""),dbpath:d.control(""),filters:d.array([])});baseCmdForm=d.group({command:d.control("backup"),targetUrl:d.control(""),arguments:d.control("")});finishedLoading=this.#e.finishedLoading;backupId=this.#e.backupId;settings=this.#e.settings;#m=H(()=>{let t=this.#r()?.id;this.#e.backupId.set(t),this.getBackup(t)});getBackup(t){this.#t.getApiV1BackupById({id:t}).subscribe({next:e=>{this.#e.mapScheduleToForm(e.Schedule??null),e.Backup&&(this.mapStandardFieldsToForm(e.Backup),this.mapBaseCmdToForm(e.Backup),this.#e.mapOptionsToForms(e.Backup)),this.#e.finishedLoading.set(!0)}})}mapStandardFieldsToForm(t){this.standardFields.patchValue({dbpath:t.DBPath,"backup-id":t.ID,"backup-name":t.Name}),t.Filters&&t.Filters.length&&t.Filters.map(e=>{this.standardFields.controls.filters.push(d.control(`${e.Include?"":"-"}${e.Expression}`))})}submit(){this.#a.resumeDialogCheck(()=>this.#l())}#l(){this.isSubmitting.set(!0);let t=this.baseCmdForm.value,e=t.targetUrl??"",i=t.arguments?.split(`
|
|
2
|
+
`).filter(n=>n.length>0)??[],a=this.standardFields.value,u=a.filters??[],g=[t.command,e,...i,`--backup-name=${a["backup-name"]}`,`--dbpath=${a.dbpath}`,`--backup-id=${a["backup-id"]}`,...u.filter(n=>n).map(n=>n.startsWith("-")?`--exclude=${n?.slice(1)}`:`--include=${n}`),...this.#e.mapFormsToSettings(["backup-id","backup-name","dbpath"]).map(n=>n.Name.startsWith("--")?`${n.Name}=${n.Value}`:`--${n.Name}=${n.Value}`),"--disable-module=console-password-input"];this.#t.postApiV1Commandline({requestBody:g}).subscribe(n=>{n.Status==="OK"&&this.#n.navigate(["backup",this.backupId(),"commandline",n.ID])})}mapBaseCmdToForm(t){let e=t.TargetURL??null;e&&this.baseCmdForm.patchValue({targetUrl:e??"",arguments:t.Sources?.join(`
|
|
3
|
+
`)??""})}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=$({type:s,selectors:[["app-commandline"]],features:[W([P])],decls:8,vars:1,consts:()=>{let t;t=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SPK_ICON:arrow-left${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SPK_ICON: Back `;let e;e=$localize`Command`;let i;i=$localize`TargetUrl`;let a;a=$localize`Commandline Arguments`;let u;u=$localize`Advanced options`;let g;g=$localize`Backup ID`;let n;n=$localize`Backup Name`;let k;k=$localize`Filters`;let D;D=$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#32\uFFFD"}:START_LINK:Read more${"\uFFFD/#32\uFFFD"}:CLOSE_LINK:`;let L;return L=$localize`${"\uFFFD#37\uFFFD"}:START_TAG_SPK_ICON:arrow-right${"\uFFFD/#37\uFFFD"}:CLOSE_TAG_SPK_ICON: Run "${"\uFFFD0\uFFFD"}:INTERPOLATION:" command now `,[t,e,i,a,u,g,n,k,D,L,[1,"back"],["type","button","spk-button","","routerLink","/",1,"small"],[1,"indeterminate","primary"],[3,"formGroup"],["placeholder","Select a command...",3,"options","inlineSearch"],["for","command"],["type","text","id","command","formControlName","command"],["for","targetUrl"],["id","targetUrl","autocomplete","off","formControlName","targetUrl"],["for","arguments"],["id","arguments","autocomplete","off","formControlName","arguments"],["for","backup-id"],["id","backup-id","formControlName","backup-id"],["for","backup-name"],["id","backup-name","formControlName","backup-name"],[3,"disallowToggle"],["title",""],["content","","formGroupName","filters"],["href","#",1,"spk-primary"],[3,"optionsChange","options","hasFreeTextSettings"],[1,"form-actions"],["spk-button","",1,"raised","primary",3,"click"],[3,"id","formControl"]]},template:function(e,i){e&1&&(l(0,"app-status-bar"),r(1,"section")(2,"div",10)(3,"button",11),M(4,0),l(5,"spk-icon"),N(),o()(),h(6,Ae,1,0,"spk-progress-bar",12)(7,Te,38,11),o()),e&2&&(m(6),B(i.finishedLoading()?7:6))},dependencies:[Me,pe,se,me,de,fe,Ee,Se,Ne,_e,ce,Ce,ue,J,ne,ee,te,ie,oe,Q],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;width:100%;max-width:40rem;padding:2.5rem;gap:1.25rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end}.form-column[_ngcontent-%COMP%]{display:flex;flex-direction:column}.form-column[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem}.form-column[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:1rem}.row-inputs[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.5rem}.row-inputs[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{flex:1 0}.field-row[_ngcontent-%COMP%]{display:grid;align-items:flex-end;grid-template-columns:1fr 2.5rem;gap:.5rem}.form-row[_ngcontent-%COMP%]{display:grid;grid-template-columns:3fr 1fr;gap:.5rem;align-items:flex-end}"],changeDetection:0})};export{I as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as a,d as b}from"./chunk-
|
|
1
|
+
import{c as a,d as b}from"./chunk-Y6ZPPRT6.js";import"./chunk-HTJ5CVNN.js";import"./chunk-U467ZTQ4.js";import"./chunk-TQHNKGRL.js";import"./chunk-F2GEUOGZ.js";import"./chunk-BIZAKOYU.js";import"./chunk-ELMONRIG.js";import"./chunk-C6XTRC7P.js";import"./chunk-MAVZY7BL.js";import"./chunk-P4ZFQZCA.js";import"./chunk-S5EF63OY.js";import"./chunk-7L2WUS2V.js";import"./chunk-L72ALLHJ.js";import"./chunk-7CGTOI24.js";export{a as createEncryptionForm,b as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{b as a,c as b,d as c}from"./chunk-JYXXSXNP.js";import"./chunk-PUEJXHBQ.js";import"./chunk-HTJ5CVNN.js";import"./chunk-U467ZTQ4.js";import"./chunk-3KPWJPKG.js";import"./chunk-EQWH3TBL.js";import"./chunk-TQHNKGRL.js";import"./chunk-F2GEUOGZ.js";import"./chunk-BIZAKOYU.js";import"./chunk-RHW5QVAY.js";import"./chunk-ELMONRIG.js";import"./chunk-C6XTRC7P.js";import"./chunk-MAVZY7BL.js";import"./chunk-P4ZFQZCA.js";import"./chunk-S5EF63OY.js";import"./chunk-7L2WUS2V.js";import"./chunk-L72ALLHJ.js";import"./chunk-7CGTOI24.js";export{a as createDestinationForm,b as createDestinationFormGroup,c as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"./chunk-
|
|
1
|
+
import{a}from"./chunk-B26K7HTR.js";import"./chunk-PUEJXHBQ.js";import"./chunk-HTJ5CVNN.js";import"./chunk-F2GEUOGZ.js";import"./chunk-ELMONRIG.js";import"./chunk-P4ZFQZCA.js";import"./chunk-S5EF63OY.js";import"./chunk-7L2WUS2V.js";import"./chunk-L72ALLHJ.js";import"./chunk-7CGTOI24.js";export{a as OptionsListComponent};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as K}from"./chunk-TQHNKGRL.js";import{a as
|
|
2
|
-
`),n="";for(let o=0;o<e.length;o++)n+=`<li>${e[o]}</li>`;return n}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=h({type:s,selectors:[["app-libraries"]],decls:15,vars:5,consts:()=>{let t;t=$localize`Libraries`;let e;return e=$localize` Details ${"\uFFFD#12\uFFFD"}:START_TAG_SPK_ICON:arrow-square-in${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SPK_ICON:`,[t,e,[1,"license"],[3,"isOpenChange","isOpen","options"],["header",""],["content",""],[1,"license-dialog"],["footer",""],["spk-button","","type","button",3,"click"],[3,"href"],[1,"actions"],["spk-button","",3,"click"]]},template:function(e,n){if(e&1){let o=u();i(0,"h3"),y(1,0),a(),R(2,Q,13,5,"div",2,P),i(4,"spk-dialog",3),V("isOpenChange",function(p){return d(o),B(n.dialogIsOpen,p)||(n.dialogIsOpen=p),_(p)}),i(5,"header",4)(6,"h3"),c(7),a()(),i(8,"div",5),U(9),i(10,"div",6),c(11),a()(),i(12,"footer",7)(13,"button",8),f("click",function(){return d(o),n.dialogLicense.set(null),_(n.dialogIsOpen.set(!1))}),c(14,"Close"),a()()()}if(e&2){let o,r;l(2),x(n.licenses()),l(2),$("isOpen",n.dialogIsOpen),F("options",G(4,j)),l(3),C((o=n.dialogLicense())==null?null:o.Title);let p=(r=(r=n.dialogLicense())==null?null:r.License)!==null&&r!==void 0?r:"";l(4),I(" ",p," ")}},dependencies:[
|
|
1
|
+
import{a as K}from"./chunk-TQHNKGRL.js";import{a as X,d as z,g as J}from"./chunk-P4ZFQZCA.js";import{h as q}from"./chunk-S5EF63OY.js";import"./chunk-7L2WUS2V.js";import{Ab as P,Bb as R,Cb as x,Db as i,Eb as a,Fb as g,Jb as u,Pb as A,Pc as W,Qb as D,Ra as E,Rb as y,Ua as l,Vb as f,Wb as S,Z as v,Zb as w,ea as d,fa as _,gb as h,ic as c,jc as C,kc as I,lb as k,lc as N,nc as $,oc as B,pc as V,qc as U,r as T,ub as F,uc as G,va as m,zb as M}from"./chunk-L72ALLHJ.js";import{a as b,b as O}from"./chunk-7CGTOI24.js";var j=()=>({maxWidth:"700px",width:"100%"});function H(s,t){if(s&1&&(i(0,"a",9)(1,"spk-icon"),c(2,"link"),a()()),s&2){let e=S().$implicit;w("href",e.Url,E)}}function Q(s,t){if(s&1){let e=u();i(0,"div",2)(1,"h4"),c(2),k(3,H,3,1,"a",9),a(),i(4,"p"),c(5),g(6,"br"),i(7,"i"),c(8),a()(),i(9,"div",10)(10,"button",11),f("click",function(){let o=d(e).$implicit,r=S();return _(r.openLicense(o))}),A(11,1),g(12,"spk-icon"),D(),a()()()}if(s&2){let e=t.$implicit;l(2),N(" ",e.Title," - ",e.data==null?null:e.data.license," "),l(),M(e.Url?3:-1),l(2),I(" ",e.data==null?null:e.data.description," "),l(3),C(e.data==null?null:e.data.notes)}}var L=class s{#e=v(q);licenses=K(this.#e.getApiV1Licenses().pipe(T(t=>t.map(e=>O(b({},e),{data:e.Jsondata?JSON.parse(e.Jsondata):null})))));dialogIsOpen=m(!1);dialogLicense=m(null);#t=W(()=>{this.dialogLicense()&&this.dialogIsOpen.set(!0)});openLicense(t){this.dialogLicense.set(t)}closeLicense(){this.dialogIsOpen.set(!1),this.dialogLicense.set(null)}breakIntoLines(t){let e=t.split(`
|
|
2
|
+
`),n="";for(let o=0;o<e.length;o++)n+=`<li>${e[o]}</li>`;return n}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=h({type:s,selectors:[["app-libraries"]],decls:15,vars:5,consts:()=>{let t;t=$localize`Libraries`;let e;return e=$localize` Details ${"\uFFFD#12\uFFFD"}:START_TAG_SPK_ICON:arrow-square-in${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SPK_ICON:`,[t,e,[1,"license"],[3,"isOpenChange","isOpen","options"],["header",""],["content",""],[1,"license-dialog"],["footer",""],["spk-button","","type","button",3,"click"],[3,"href"],[1,"actions"],["spk-button","",3,"click"]]},template:function(e,n){if(e&1){let o=u();i(0,"h3"),y(1,0),a(),R(2,Q,13,5,"div",2,P),i(4,"spk-dialog",3),V("isOpenChange",function(p){return d(o),B(n.dialogIsOpen,p)||(n.dialogIsOpen=p),_(p)}),i(5,"header",4)(6,"h3"),c(7),a()(),i(8,"div",5),U(9),i(10,"div",6),c(11),a()(),i(12,"footer",7)(13,"button",8),f("click",function(){return d(o),n.dialogLicense.set(null),_(n.dialogIsOpen.set(!1))}),c(14,"Close"),a()()()}if(e&2){let o,r;l(2),x(n.licenses()),l(2),$("isOpen",n.dialogIsOpen),F("options",G(4,j)),l(3),C((o=n.dialogLicense())==null?null:o.Title);let p=(r=(r=n.dialogLicense())==null?null:r.License)!==null&&r!==void 0?r:"";l(4),I(" ",p," ")}},dependencies:[X,J,z],styles:["[_nghost-%COMP%]{display:block}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0 0 1.25rem}h4[_ngcontent-%COMP%]{font:var(--paragraph-10)}a[_ngcontent-%COMP%]{text-decoration:none}.license[_ngcontent-%COMP%]{padding:1rem;border-bottom:1px solid var(--base-level-40);display:flex;flex-direction:column;align-items:flex-start;gap:.5rem}.license[_ngcontent-%COMP%]:first-of-type{border-top:1px solid var(--base-level-40)}.license[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;gap:.25rem;align-items:center}.license-dialog[_ngcontent-%COMP%]{background-color:var(--base-level-10);color:var(--base-level-70);padding:2.5rem 2.5rem 2.5rem 1.5rem;border-radius:var(--shape-3);overflow:auto;max-height:31.25rem;white-space:pre;border:1px solid var(--base-level-40)}"],changeDetection:0})};export{L as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-7CGTOI24.js";var o=[{path:"",redirectTo:"select-files",pathMatch:"full"},{path:"destination",loadComponent:()=>import("./chunk-UWRVKCWT.js")},{path:"encryption",loadComponent:()=>import("./chunk-DL56XS75.js")},{path:"select-files",loadComponent:()=>import("./chunk-Y7K42OXA.js")},{path:"options",loadComponent:()=>import("./chunk-M5CGJUYP.js")},{path:"progress",loadComponent:()=>import("./chunk-GWH2WEBY.js")}],t=o;export{t as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as se}from"./chunk-PH5P3W5Z.js";import{c as re,e as _e,h as pe,j as ce,s as I}from"./chunk-ELMONRIG.js";import{a as J}from"./chunk-BJGA55H2.js";import{a as Q,b as Y,e as ee,g as te,i as R,l as ne,p as ie,q as oe,s as ae,t as le}from"./chunk-P4ZFQZCA.js";import{h}from"./chunk-S5EF63OY.js";import{a as ue}from"./chunk-JFNFY6VY.js";import{pa as Z}from"./chunk-7L2WUS2V.js";import{Ab as z,Ac as j,Bb as X,Cb as H,Db as a,Eb as l,F as N,Fb as E,Jb as K,Oc as q,Pb as O,Qb as f,Rb as c,Ua as r,Ub as W,Vb as _,Wb as C,Z as S,ea as $,fa as x,gb as g,ic as u,kc as k,lb as y,lc as B,nc as A,oc as P,pc as M,ra as F,ub as m,va as p,vb as w,wb as d,yc as U,zb as v,zc as V}from"./chunk-L72ALLHJ.js";function Oe(s,n){if(s&1){let t=K();a(0,"spk-radio",10),_("click",function(){let i=$(t).$implicit,o=C();return x(o.pauseOption.set(i.value))}),u(1),l()}if(s&2){let t=n.$implicit,e=C();d("active",e.pauseOption()===t.value),r(),k(" ",t.label," ")}}var fe=[{label:$localize`5 minuts`,value:"5m"},{label:$localize`10 minuts`,value:"10m"},{label:$localize`15 minuts`,value:"15m"},{label:$localize`30 minuts`,value:"30m"},{label:$localize`1 hour`,value:"1h"},{label:$localize`4 hours`,value:"4h"},{label:$localize`8 hours`,value:"8h"},{label:$localize`24 hours`,value:"24h"},{label:$localize`Until resumed`,value:void 0}],b=class s{#e=S(h);pauseOptions=p(fe);closed=F();isSubmitting=p(!1);pauseTransfers=p(!1);pauseOption=p(void 0);submit(){this.isSubmitting.set(!0);let n=this.pauseTransfers()||null,t=this.pauseOption();this.#e.postApiV1ServerstatePause({duration:t,pauseTransfers:n}).pipe(N(()=>this.isSubmitting.set(!1))).subscribe({next:e=>{this.closed.emit()}})}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=g({type:s,selectors:[["app-pause-dialog"]],outputs:{closed:"closed"},decls:17,vars:4,consts:()=>{let n;n=$localize`Pause settings`;let t;t=$localize` Also pause transfers `;let e;e=$localize`If you pause transfers they could time out and cause retries or failures.`;let i;i=$localize`Cancel`;let o;return o=$localize` Update settings `,[n,t,e,i,o,["header",""],["content",""],[1,"radios"],[1,"primary","raised",3,"active"],[1,"check-wrap"],[1,"primary","raised",3,"click"],["type","warning"],["footer",""],["spk-button","",3,"click"],["spk-button","",1,"raised","primary",3,"click"]]},template:function(t,e){t&1&&(a(0,"header",5)(1,"h3"),c(2,0),l()(),a(3,"div",6)(4,"div",7),X(5,Oe,2,3,"spk-radio",8,z),l(),a(7,"div",9)(8,"spk-checkbox",10),_("click",function(){return e.pauseTransfers.set(!e.pauseTransfers())}),c(9,1),l(),a(10,"spk-alert",11),c(11,2),l()()(),a(12,"footer",12)(13,"button",13),_("click",function(){return e.closed.emit()}),c(14,3),l(),a(15,"button",14),_("click",function(){return e.submit()}),c(16,4),l()()),t&2&&(r(5),H(e.pauseOptions()),r(3),d("active",e.pauseTransfers()),r(7),d("loader",e.isSubmitting()))},dependencies:[I,oe,R,Y],styles:["[_nghost-%COMP%]{--dialog-p: 1.5rem;display:block}h3[_ngcontent-%COMP%]{font:var(--title-30)}.radios[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.check-wrap[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;padding:2rem 0 0}"],changeDetection:0})};var Ae=["Byte/s","KByte/s","MByte/s","GByte/s","TByte/s","PByte/s"],L={Byte:"B",KByte:"KB",MByte:"MB",GByte:"GB",TByte:"TB",PByte:"PB"},me=Object.entries(L).reduce((s,[n,t])=>(s[t]=n,s),{}),D=class s{#e=S(h);closed=F();isSubmitting=p(!1);sizeOptions=p(Ae);maxUploadActive=p(!1);maxDownloadActive=p(!1);maxUpload=p(0);maxDownload=p(0);maxUploadUnit=p("MByte/s");maxDownloadUnit=p("MByte/s");ngOnInit(){this.init()}init(){this.#e.getApiV1Serversettings().subscribe({next:n=>{let t=n?.["max-upload-speed"]?.split(/(\d+)/),e=n?.["max-download-speed"]?.split(/(\d+)/),i=t[1]??"",o=e[1]??"",T=t[2]??"MB",ge=e[2]??"MB",Ce=i===""?10:parseInt(i),Ee=o===""?10:parseInt(o);this.maxUploadUnit.set(me[T]+"/s"),this.maxDownloadUnit.set(me[ge]+"/s"),this.maxUploadActive.set(i!==""),this.maxDownloadActive.set(o!==""),this.maxUpload.set(Ce),this.maxDownload.set(Ee)}})}blockDecimalKeys(n){if([".",","].includes(n.key))return n.preventDefault()}cleanupInputAfterPasting(n){n.preventDefault();let t=n.clipboardData?.getData("text/plain");if(!t)return;let e=t.replaceAll(/[\.,]/g,"");n.target.value=e}submit(){this.isSubmitting.set(!0);let n=this.maxUploadActive()?`${this.maxUpload()}${L[this.maxUploadUnit().replace("/s","")]}`:"",t=this.maxDownloadActive()?`${this.maxDownload()}${L[this.maxDownloadUnit().replace("/s","")]}`:"";this.#e.patchApiV1Serversettings({requestBody:{"max-upload-speed":n,"max-download-speed":t}}).pipe(N(()=>this.isSubmitting.set(!1))).subscribe({next:e=>{this.closed.emit(!0)}})}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=g({type:s,selectors:[["app-throttle-settings-dialog"]],outputs:{closed:"closed"},decls:28,vars:16,consts:()=>{let n;n=$localize`Throttle network speed`;let t;t=$localize` Note that speeds are entered in bytes, and line speeds are typically reported in bits. Use a factor of 8 to convert, such that an 8 mbit/s line is equivalent to 1 MByte/s. `;let e;e=$localize`Cancel`;let i;return i=$localize` Update settings `,[n,t,e,i,["header",""],["content",""],[1,"column"],[1,"field-row"],[1,"primary","raised",3,"click"],["type","number",3,"paste","keydown","ngModelChange","ngModel","disabled"],[3,"isClearable","options"],["type","text",3,"ngModelChange","ngModel"],["footer",""],["spk-button","",3,"click"],["spk-button","",1,"raised","primary",3,"click"]]},template:function(t,e){t&1&&(a(0,"header",4)(1,"h3"),c(2,0),l()(),a(3,"div",5)(4,"div",6)(5,"div",7)(6,"label"),u(7,"Max upload speed"),l(),a(8,"spk-checkbox",8),_("click",function(){return e.maxUploadActive.set(!e.maxUploadActive())}),l(),a(9,"spk-form-field")(10,"input",9),_("paste",function(o){return e.cleanupInputAfterPasting(o)})("keydown",function(o){return e.blockDecimalKeys(o)}),M("ngModelChange",function(o){return P(e.maxUpload,o)||(e.maxUpload=o),o}),l()(),a(11,"spk-select",10)(12,"input",11),M("ngModelChange",function(o){return P(e.maxUploadUnit,o)||(e.maxUploadUnit=o),o}),l()()(),a(13,"div",7)(14,"label"),u(15,"Max download speed"),l(),a(16,"spk-checkbox",8),_("click",function(){return e.maxDownloadActive.set(!e.maxDownloadActive())}),l(),a(17,"spk-form-field")(18,"input",9),_("paste",function(o){return e.cleanupInputAfterPasting(o)})("keydown",function(o){return e.blockDecimalKeys(o)}),M("ngModelChange",function(o){return P(e.maxDownload,o)||(e.maxDownload=o),o}),l()(),a(19,"spk-select",10)(20,"input",11),M("ngModelChange",function(o){return P(e.maxDownloadUnit,o)||(e.maxDownloadUnit=o),o}),l()()(),a(21,"p"),c(22,1),l()()(),a(23,"footer",12)(24,"button",13),_("click",function(){return e.closed.emit(!1)}),c(25,2),l(),a(26,"button",14),_("click",function(){return e.submit()}),c(27,3),l()()),t&2&&(r(8),d("active",e.maxUploadActive()),r(2),A("ngModel",e.maxUpload),m("disabled",!e.maxUploadActive()),r(),m("isClearable",!1)("options",e.sizeOptions()),r(),A("ngModel",e.maxUploadUnit),r(4),d("active",e.maxDownloadActive()),r(2),A("ngModel",e.maxDownload),m("disabled",!e.maxDownloadActive()),r(),m("isClearable",!1)("options",e.sizeOptions()),r(),A("ngModel",e.maxDownloadUnit),r(6),d("loader",e.isSubmitting()))},dependencies:[I,re,ce,_e,pe,ne,R,le],styles:['[_nghost-%COMP%]{display:block}h3[_ngcontent-%COMP%]{font:var(--title-30)}.column[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.field-row[_ngcontent-%COMP%]{display:grid;grid-template-areas:"label label label" "checkbox input select";grid-template-columns:auto 1fr auto;align-items:center;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{grid-area:label}.field-row[_ngcontent-%COMP%] spk-form-field[_ngcontent-%COMP%]{grid-area:input}.field-row[_ngcontent-%COMP%] spk-select[_ngcontent-%COMP%]{grid-area:select}'],changeDetection:0})};function Pe(s,n){if(s&1&&(a(0,"div"),u(1),l(),E(2,"spk-progress-bar",9)),s&2){let t=C();r(),B("",t.statusData().actionText," - ",t.statusData().statusText,""),r(),m("value",t.statusData().progress*100)}}function Me(s,n){if(s&1&&(a(0,"div",5),u(1),a(2,"spk-icon"),u(3,"clock"),l(),u(4),U(5,"relativeTime"),U(6,"date"),l()),s&2){let t,e=C();r(),k(" ",(t=e.nextBackup().backup)==null||t.Backup==null?null:t.Backup.Name," - "),r(3),B(" ",V(5,3,e.nextBackup().time)," at ",j(6,5,e.nextBackup().time,"shortTime")," ")}}function De(s,n){s&1&&(a(0,"div",5),c(1,1),l())}function Ne(s,n){s&1&&(a(0,"div",6),O(1,2),E(2,"spk-spinner"),f(),l()),s&2&&(r(2),w("--spinner-size","12px")("--spinner-thickness","2px"))}function Fe(s,n){s&1&&(O(0,0,1),E(1,"spk-icon"),f())}function ke(s,n){s&1&&(O(0,0,2),E(1,"spk-icon"),f())}var Te=new Date,G=class s{#e=S(se);#t=S(ee);#n=S(J);minsAgo=Te.setMinutes(Te.getMinutes()-1);statusData=this.#e.statusData;serverState=this.#e.serverState;clientIsRunning=this.#e.clientIsRunning;isResuming=this.#e.isResuming;nextBackup=q(()=>({backup:this.serverState()?.ProposedSchedule?.[0]?.backup,time:this.serverState()?.ProposedSchedule?.[0]?.Item2}));openThrottleSettingsDialog(){this.#t.open(D,{maxWidth:"550px",width:"100%"})}openPauseDialog(){this.#t.open(b,{maxWidth:"550px",width:"100%"})}pauseResume(){if(this.clientIsRunning()){this.openPauseDialog();return}this.#e.pauseResume().subscribe()}ngAfterViewInit(){let n=this.#n.relayIsEnabled()?"longpoll":"websocket";this.#e.setConnectionMethod(n)}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=g({type:s,selectors:[["app-status-bar"]],decls:14,vars:4,consts:()=>{let n;n=$localize`${"\uFFFD*9:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SPK_ICON:pause${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SPK_ICON: Pause ${"\uFFFD/*9:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*10:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SPK_ICON:play${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SPK_ICON: Start ${"\uFFFD/*10:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,n=W(n);let t;t=$localize`No scheduled tasks`;let e;return e=$localize` Loading ${"\uFFFD#2\uFFFD"}:START_TAG_SPK_SPINNER:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SPK_SPINNER:`,[n,t,e,[1,"current-backup"],[1,"current-backup-progress"],[1,"label"],[1,"label","label-loading"],[1,"current-backup-actions"],["spk-button","",3,"click"],[1,"raised","primary",3,"value"]]},template:function(t,e){if(t&1&&(a(0,"div",3)(1,"div",4),y(2,Pe,3,3)(3,Me,7,8,"div",5)(4,De,2,0,"div",5)(5,Ne,3,4,"div",6),l(),a(6,"div",7)(7,"button",8),_("click",function(){return e.pauseResume()}),O(8,0),y(9,Fe,2,0)(10,ke,2,0),f(),l(),a(11,"button",8),_("click",function(){return e.openThrottleSettingsDialog()}),a(12,"spk-icon"),u(13,"speedometer"),l()()()()),t&2){let i;r(2),v((i=e.serverState())!=null&&i.ActiveTask&&(!((i=e.statusData())==null||i.task==null)&&i.task.Status)&&((i=e.statusData())==null||i.task==null?null:i.task.Status)!=="Completed"?2:e.nextBackup().backup||e.nextBackup().time?3:(i=e.serverState())!=null&&i.ActiveTask?5:4),r(5),d("loader",e.isResuming()),r(2),v(e.clientIsRunning()?9:10)}},dependencies:[ie,ue,Z,Q,te,ae],styles:["[_nghost-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:1rem;min-height:3.875rem;border-bottom:1px solid var(--base-level-40)}.current-backup[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:100%;gap:.5rem}.current-backup-progress[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem;min-width:18.75rem}.current-backup-progress[_ngcontent-%COMP%] .label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem}.current-backup-actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}.label-loading[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:.25rem}"],changeDetection:0})};export{G as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./chunk-7CGTOI24.js";var o=[{path:"",loadComponent:()=>import("./chunk-S5FFZRTF.js"),children:[{path:"",redirectTo:"stored",pathMatch:"full"},{path:"stored",loadComponent:()=>import("./chunk-
|
|
1
|
+
import"./chunk-7CGTOI24.js";var o=[{path:"",loadComponent:()=>import("./chunk-S5FFZRTF.js"),children:[{path:"",redirectTo:"stored",pathMatch:"full"},{path:"stored",loadComponent:()=>import("./chunk-S24RG6QP.js")},{path:"live",loadComponent:()=>import("./chunk-NF45E5CN.js")}]}],t=o;export{t as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{g as K}from"./chunk-
|
|
1
|
+
import{g as K}from"./chunk-Y6ZPPRT6.js";import{a as H}from"./chunk-ZGKHK6QQ.js";import"./chunk-P7IBR2UW.js";import"./chunk-HTJ5CVNN.js";import"./chunk-U467ZTQ4.js";import"./chunk-TQHNKGRL.js";import"./chunk-F2GEUOGZ.js";import{a as j}from"./chunk-JDSUBKXI.js";import"./chunk-CRR7DNOY.js";import{a as B}from"./chunk-PH5P3W5Z.js";import"./chunk-IINSQSHJ.js";import"./chunk-FJVMA6GA.js";import"./chunk-BIZAKOYU.js";import"./chunk-RHW5QVAY.js";import{a as z}from"./chunk-HFIC4JNY.js";import"./chunk-ELMONRIG.js";import"./chunk-BJGA55H2.js";import"./chunk-XP7PWMT2.js";import"./chunk-C6XTRC7P.js";import"./chunk-MAVZY7BL.js";import{a as b,h as w,p as W,s as X}from"./chunk-P4ZFQZCA.js";import"./chunk-S5EF63OY.js";import{ua as v}from"./chunk-7L2WUS2V.js";import{Db as i,Eb as s,Fb as p,Gb as m,Hb as P,Oc as M,Pb as L,Pc as I,Qb as A,Rb as _,Sb as D,Tb as x,Ua as l,Wb as u,Z as T,ga as $,gb as y,ha as G,ic as C,lb as g,lc as f,ub as O,va as h,yc as R,zb as d,zc as E}from"./chunk-L72ALLHJ.js";import"./chunk-7CGTOI24.js";function V(n,e){n&1&&(i(0,"spk-card",8),m(1,14),_(2,2),P(),i(3,"div",15),$(),i(4,"svg",16),p(5,"circle",17),s(),G(),i(6,"spk-icon"),C(7,"check-bold"),s()()())}function Z(n,e){if(n&1&&(C(0),R(1,"number"),R(2,"number")),n&2){let t,o=u(2);f(" ",E(1,2,(t=o.statusData())==null?null:t.ProcessedFileCount)," of ",E(2,4,(t=o.statusData())==null?null:t.TotalFileCount)," ")}}function q(n,e){n&1&&(m(0),_(1,6),P())}function J(n,e){if(n&1&&(C(0),R(1,"bytes"),R(2,"bytes")),n&2){let t,o=u(2);f(" ",E(1,2,(t=o.statusData())==null?null:t.ProcessedFileSize)," of ",E(2,4,(t=o.statusData())==null?null:t.TotalFileSize)," ")}}function Q(n,e){n&1&&(m(0),_(1,7),P())}function U(n,e){if(n&1&&(i(0,"spk-card",8)(1,"h3"),L(2,3),p(3,"spk-spinner",18),A(),s(),i(4,"div",19),p(5,"spk-progress-bar",20),i(6,"p")(7,"span"),_(8,4),s(),g(9,Z,3,6)(10,q,2,0,"ng-container"),s(),i(11,"p")(12,"span"),_(13,5),s(),g(14,J,3,6)(15,Q,2,0,"ng-container"),s()()()),n&2){let t,o,r,a,c=u();l(3),D((t=c.statusData())==null?null:t.statusText),x(2),l(2),O("value",(o=c.statusData())==null?null:o.OverallProgress),l(4),d((r=c.statusData())!=null&&r.ProcessedFileCount?9:10),l(5),d((a=c.statusData())!=null&&a.ProcessedFileSize?14:15)}}var F=class n{#e=T(B);#t=T(K);statusData=this.#e.statusData;backupId=this.#t.backupId;isPolling=h(!0);taskId=M(()=>this.#e.statusData()?.TaskID?.toString()??void 0);lastRestoreStarted=M(()=>{let e=this.#e.statusData()?.backup?.Backup?.Metadata?.LastRestoreStarted??null;return e?this.fixDate(e):null});completedEffect=I(()=>{this.statusData()?.task?.Status==="Completed"&&this.isPolling.set(!1)});notificationFilterPredicate=()=>{let e=this.lastRestoreStarted();return{predicate:t=>(t.BackupID===this.#t.backupId()&&e&&e.getTime()<=new Date(t.Timestamp).getTime())??!1}};ngOnInit(){this.#e.fetchProgressState(),this.#e.startPollingProgress()}fixDate(e){return new Date(`${e.slice(0,4)}-${e.slice(4,6)}-${e.slice(6,8)}T${e.slice(9,11)}:${e.slice(11,13)}:${e.slice(13,15)}Z`)}static \u0275fac=function(t){return new(t||n)};static \u0275cmp=y({type:n,selectors:[["app-restore-progress"]],decls:12,vars:6,consts:()=>{let e;e=$localize`Notifications`;let t;t=$localize`Logs`;let o;o=$localize`Restore completed`;let r;r=$localize` Restore progress: ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#3\uFFFD"}:START_TAG_SPK_SPINNER:${"\uFFFD/#3\uFFFD"}:CLOSE_TAG_SPK_SPINNER:`;let a;a=$localize`Files processed:`;let c;c=$localize`Size processed:`;let N;N=$localize`N/A`;let k;return k=$localize`N/A`,[e,t,o,r,a,c,N,k,[1,"progress","type-a"],[1,"notifications","type-a"],[1,"notification-list"],[3,"notificationFilterPredicate"],[1,"logs","type-a"],[3,"asSimpleList","polling","whenFilter","backupIdFilter"],["title",""],[1,"complete-check"],[1,"border-svg"],["cx","50","cy","50","r","45",1,"border-circle"],[1,"primary"],[1,"progress-content"],[3,"value"]]},template:function(t,o){if(t&1&&(i(0,"section"),g(1,V,8,0,"spk-card",8)(2,U,16,4,"spk-card",8),i(3,"spk-card",9)(4,"h3"),_(5,0),s(),i(6,"div",10),p(7,"app-notifications",11),s()(),i(8,"spk-card",12)(9,"h3"),_(10,1),s(),p(11,"app-logs-live",13),s()()),t&2){let r,a;l(),d(((r=o.statusData())==null||r.task==null?null:r.task.Status)==="Completed"?1:2),l(6),O("notificationFilterPredicate",o.notificationFilterPredicate()),l(4),O("asSimpleList",!0)("polling",o.isPolling())("whenFilter",(a=o.lastRestoreStarted())==null?null:a.getTime())("backupIdFilter",o.backupId())}},dependencies:[H,W,X,b,w,j,z,v],styles:['[_nghost-%COMP%]{display:block;padding:0 1.25rem}section[_ngcontent-%COMP%]{display:grid;gap:1.25rem;grid-template-columns:2fr 1fr;grid-template-areas:"progress notifications" "logs logs"}section[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{margin-bottom:1rem}section[_ngcontent-%COMP%] .progress[_ngcontent-%COMP%]{grid-area:progress}section[_ngcontent-%COMP%] .progress[_ngcontent-%COMP%]:has(.complete-check){display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1.25rem}section[_ngcontent-%COMP%] .progress[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between}section[_ngcontent-%COMP%] .progress[_ngcontent-%COMP%] spk-spinner[_ngcontent-%COMP%]{--spinner-size: 1.25rem;--spinner-thickness: .1875rem}section[_ngcontent-%COMP%] .notifications[_ngcontent-%COMP%]{grid-area:notifications}section[_ngcontent-%COMP%] .logs[_ngcontent-%COMP%]{grid-area:logs}section[_ngcontent-%COMP%] .logs[_ngcontent-%COMP%] app-logs-live[_ngcontent-%COMP%]{max-height:50rem;overflow:auto}.notification-list[_ngcontent-%COMP%]{max-height:15rem;overflow:auto}.complete-check[_ngcontent-%COMP%]{position:relative;width:100px;height:100px;display:flex;justify-content:center;align-items:center;color:var(--success-500)}.complete-check[_ngcontent-%COMP%] spk-icon[_ngcontent-%COMP%]{font-size:2.5rem;opacity:0;animation:_ngcontent-%COMP%_reveal-icon .2s linear forwards;animation-delay:1s}.border-svg[_ngcontent-%COMP%]{position:absolute;top:0;left:0;width:100%;height:100%}.border-circle[_ngcontent-%COMP%]{fill:none;stroke:var(--success-500);stroke-width:5px;stroke-dasharray:282.74;stroke-dashoffset:282.74;animation:_ngcontent-%COMP%_draw-border 1.2s linear forwards}@keyframes _ngcontent-%COMP%_draw-border{to{stroke-dashoffset:0}}@keyframes _ngcontent-%COMP%_reveal-icon{to{opacity:1}}.progress-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.progress-content[_ngcontent-%COMP%] spk-progress-bar[_ngcontent-%COMP%]{margin-bottom:.75rem}.progress-content[_ngcontent-%COMP%] p[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{margin-right:.25rem}'],changeDetection:0})};export{F as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as M}from"./chunk-GM4QKN65.js";import"./chunk-PH5P3W5Z.js";import"./chunk-IINSQSHJ.js";import"./chunk-FJVMA6GA.js";import"./chunk-BIZAKOYU.js";import"./chunk-RHW5QVAY.js";import"./chunk-HFIC4JNY.js";import"./chunk-ELMONRIG.js";import"./chunk-BJGA55H2.js";import"./chunk-XP7PWMT2.js";import{c as O,e as C,f as S}from"./chunk-C6XTRC7P.js";import"./chunk-MAVZY7BL.js";import{y as d}from"./chunk-P4ZFQZCA.js";import"./chunk-S5EF63OY.js";import"./chunk-JFNFY6VY.js";import"./chunk-7L2WUS2V.js";import"./chunk-DOP6RFEG.js";import{Db as e,Eb as t,Fb as l,Rb as n,gb as c}from"./chunk-L72ALLHJ.js";import"./chunk-7CGTOI24.js";var s=class a{static \u0275fac=function(o){return new(o||a)};static \u0275cmp=c({type:a,selectors:[["app-about"]],decls:19,vars:0,consts:()=>{let _;_=$localize`General`;let o;o=$localize`Changelog`;let r;r=$localize`Libraries`;let u;u=$localize`System info`;let T;T=$localize`Server settings`;let g;g=$localize`Logs`;let A;return A=$localize`Crash log`,[_,o,r,u,T,g,A,[1,"content"],[1,"primary"],["tab","","routerLink","/about/general","routerLinkActive","active"],["tab","","routerLink","/about/changelog","routerLinkActive","active"],["tab","","routerLink","/about/libraries","routerLinkActive","active"],["tab","","routerLink","/about/system-info","routerLinkActive","active"],["tab","","routerLink","/about/server-settings","routerLinkActive","active"],["tab","","routerLink","/about/logs","routerLinkActive","active"],["tab","","routerLink","/about/crashlogs","routerLinkActive","active"]]},template:function(o,r){o&1&&(l(0,"app-status-bar"),e(1,"div",7)(2,"spk-tabs",8)(3,"button",9),n(4,0),t(),e(5,"button",10),n(6,1),t(),e(7,"button",11),n(8,2),t(),e(9,"button",12),n(10,3),t(),e(11,"button",13),n(12,4),t(),e(13,"button",14),n(14,5),t(),e(15,"button",15),n(16,6),t()(),e(17,"section"),l(18,"router-outlet"),t()())},dependencies:[M,d,O,C,S],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:0}.content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem 2rem}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:2rem 0}"],changeDetection:0})};export{s as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as be}from"./chunk-F2GEUOGZ.js";import{s as xe}from"./chunk-ELMONRIG.js";import{A as Te,a as me,f as Ce,l as Pe,n as Ee,p as ve}from"./chunk-P4ZFQZCA.js";import{h as ge}from"./chunk-S5EF63OY.js";import{ia as fe}from"./chunk-7L2WUS2V.js";import{$a as K,B as ne,Bb as re,Bc as _e,Cb as oe,Db as h,Eb as f,F as q,Fb as le,Ib as z,Jb as B,Oc as W,Pc as A,Rb as $,Sb as ae,Tb as ce,Ua as m,Vb as R,Wb as u,Xb as de,Yb as D,Z as X,ea as N,fa as k,fc as J,gb as ie,gc as pe,hc as Y,ic as S,kc as ue,lb as M,n as ee,r as L,ra as Q,sa as v,ub as U,va as O,vb as se,vc as V,wb as T,wc as he,x as te,zb as F}from"./chunk-L72ALLHJ.js";import{a as j,b as G}from"./chunk-7CGTOI24.js";var we=["treeContainer"],ye=["formRef"],Ne=[[["label"]],[["label"]],[["input"]]],ke=["label","label","input"],Re=s=>({children:s,level:0}),Me=s=>({$implicit:s}),Ie=(s,t)=>({children:s,level:t}),We=(s,t)=>t.id;function Ae(s,t){if(s&1){let e=B();h(0,"spk-button-group")(1,"button",13),R("click",function(){N(e);let i=u();return k(i.pathDiscoveryMethod.set("browse"))}),$(2,4),f(),h(3,"button",13),R("click",function(){N(e);let i=u();return k(i.pathDiscoveryMethod.set("path"))}),$(4,5),f()()}if(s&2){let e=u();m(),T("active",e.pathDiscoveryMethod()==="browse"),m(2),T("active",e.pathDiscoveryMethod()==="path")}}function Le(s,t){s&1&&le(0,"spk-progress-bar",9)}function Be(s,t){s&1&&(h(0,"spk-icon",18),S(1,"caret-down"),f(),h(2,"spk-icon",16),S(3,"folder-open"),f())}function $e(s,t){s&1&&(h(0,"spk-icon"),S(1,"file"),f())}function De(s,t){s&1&&(h(0,"spk-icon",18),S(1,"caret-right"),f(),h(2,"spk-icon",16),S(3,"folder"),f())}function Ve(s,t){if(s&1&&M(0,Be,4,0)(1,$e,2,0,"spk-icon")(2,De,4,0),s&2){let e=u(2).$implicit;F(e.children.length?0:e.cls==="file"?1:2)}}function He(s,t){s&1&&(h(0,"spk-icon",16),S(1,"desktop-tower"),f())}function je(s,t){s&1&&z(0)}function Ge(s,t){if(s&1&&M(0,je,1,0,"ng-container",10),s&2){let e=u(2).$implicit,n=u().$implicit;u();let i=Y(7);U("ngTemplateOutlet",i)("ngTemplateOutletContext",V(5,Me,he(2,Ie,e.children,n.level+1)))}}function qe(s,t){if(s&1){let e=B();h(0,"div",14,3),R("click",function(){N(e);let i=u().$implicit,o=u(2);return k(o.toggleNode(i.id,i))}),h(2,"div",15),M(3,Ve,3,1)(4,He,2,0,"spk-icon",16),f(),h(5,"div",17),R("click",function(i){N(e);let o=u().$implicit,a=u(2);return k(a.toggleSelectedNode(i,o))}),S(6),f()(),M(7,Ge,1,7,"ng-container")}if(s&2){let e=u().$implicit,n=u().$implicit,i=u();T("accepted",e.accepted===!0)("active",e.evalState===i.TreeEvalEnum.Included)("indeterminate",e.isIndeterminate)("open",e.children.length)("usually-hidden",e.hidden)("root",n.level===0),m(2),T("file",e.cls==="file"),m(),F(e.id!=="/"?3:4),m(3),ue(" ",e.text," "),m(),F(e.children.length>0?7:-1)}}function Xe(s,t){if(s&1&&M(0,qe,8,17),s&2){let e=t.$implicit,n=u(2);F(e.hidden&&n._showHiddenNodes()||!e.hidden?0:-1)}}function Qe(s,t){if(s&1&&(h(0,"spk-list"),re(1,Xe,1,1,null,null,We),f()),s&2){let e=t.$implicit;se("padding-left",e.level*.25,"rem"),m(),oe(e.children)}}function Ke(s,t){s&1&&z(0)}function Ue(s,t){if(s&1){let e=B();h(0,"spk-toggle",19),R("click",function(){N(e);let i=u();return k(i._showHiddenNodes.set(!i._showHiddenNodes()))}),$(1,6),f()}if(s&2){let e=u();T("active",e._showHiddenNodes()),m(),ae(e.showFiles()?"files":"folders"),ce(1)}}var Oe=(o=>(o[o.ExcludedByParent=-2]="ExcludedByParent",o[o.Excluded=-1]="Excluded",o[o.None=0]="None",o[o.Included=1]="Included",o[o.IncludedByParent=2]="IncludedByParent",o))(Oe||{}),Z=class s{#e=X(ge);#t=X(be);multiSelect=v(!1);disabled=v(!1);showFiles=v(!1);selectFiles=v(!1);accepts=v(null);startingPath=v(null);rootPaths=v([]);backupSettings=v(null);pathRefreshTrigger=v(!1);showHiddenNodes=v(!1);hideShortcuts=v(!1);includes=Q();excludes=Q();_showHiddenNodes=O(!1);treeContainerRef=K("treeContainer");formRef=K("formRef");pathDiscoveryMethod=O("browse");isLoading=O(!1);currentPath=O("/");#n=O(null);treeSearchQuery=O("");treeNodes=O([]);isWindows=W(()=>this.#t.systemInfo()?.OSType==="Windows");filterGroups=this.#t.filterGroups();isByBackupSettings=W(()=>{let t=this.backupSettings();return!(t===void 0||t?.id===void 0||t?.time===void 0)});searchableTreeNodes=W(()=>{let t=this.treeSearchQuery();return t?this.treeNodes().filter(e=>e.text?.toLowerCase().includes(t.toLowerCase())):this.treeNodes()});TreeEvalEnum=Oe;treeStructure=W(()=>{let t=this.showHiddenNodes(),e=this.currentPath().split("\0").filter(r=>r!==""&&r!=="/"),n=structuredClone(e);for(let r=0;r<n.length;r++){let c=n[r].slice(1);if(c.startsWith("{")&&c.endsWith("}")){let p=c.slice(1,-1),d=this.filterGroups?.FilterGroups[p];if(d&&d.length){let b=d.map(P=>`-${P}`);n.splice(r,1,...b)}}}let i=this.searchableTreeNodes(),o=this.rootPaths(),a=this.accepts(),C=this.isWindows(),l=[];return o.length>0?l=o.map(r=>({id:r,resolvedpath:r,text:r,parentPath:"",children:[],evalState:0,isIndeterminate:!1,cls:"folder"})):l=[{id:"/",resolvedpath:"/",text:"Computer",parentPath:"",children:[],evalState:0,isIndeterminate:!1,cls:"folder"}],l.map(r=>{let g=new Map,c=r?.id;a&&(r.accepted=!0),g.set(r.id,r);let p=o.length>0?i.filter(d=>d.parentPath===r.id):i;for(let d of p){let b=o.length>0?d.id.replace(c??"",""):d.id,P=C?"\\":"/",_=b.split(P).filter(Boolean),E="",x=r;for(let H of _){if(E+=H+P,!g.has(E)){let I=d.hidden===!0&&t?0:this.#o(n,d.id,d.cls,x,C),w={id:d.id,isIndeterminate:this.isIndeterminate(n,d.id),evalState:I,parentPath:E,resolvedpath:d.id?.startsWith("%")?d.resolvedpath+P:E,hidden:d.hidden,text:d.text,cls:d.cls,children:[]};a&&(w.accepted=this.matchAccepts(a,w)),g.set(E,w),x.children.push(w)}x=g.get(E)}}return r}),l});#o(t,e,n,i,o){if(i.evalState===-1)return-2;let a=0,C=t.filter(r=>!r.startsWith("-")&&!r.startsWith("+")),l=t.filter(r=>r.startsWith("-")||r.startsWith("+"));if(C.length===0)return a;for(let r=0;r<C.length;r++){let g=C[r];if(e?.startsWith(g)){a=1;break}}if(l.length===0)return a;for(let r=0;r<l.length;r++){let g=l[r],c=g.slice(1),p=g.startsWith("-")?"exclude":"include",d=o?"\\":"/";if((o?c.slice(2):c).startsWith(d)&&c.endsWith(d)){if(n!=="folder")continue;if(e===c){a=p==="include"?1:-1;break}}if(c.startsWith("*")&&c.endsWith(`*${d}`)){if(n!=="folder")continue;let _=c.slice(1,-2);if(_==="")break;if(e?.includes(_+d)){a=p==="include"?1:-1;break}}if(c.startsWith("[.*")&&c.endsWith(`[^\\${d}]*]`)){if(n!=="file")continue;let _=c.slice(3,-7);if(new RegExp(_).test(e)){a=p==="include"?1:-1;break}}if(c.startsWith("[")&&c.endsWith("]")){let _=c.slice(1,-1),E=this.translateCSharpRegex(_);if(new RegExp(`${E}`).test(e)){a=p==="include"?1:-1;break}}if(c.startsWith("*.")){if(n!=="file"||c.replace("*.","").length===0)continue;if(this.#s(e,c,!0)){a=p==="include"?1:-1;break}}if(c==="")continue;if(c===e){a=p==="include"?1:-1;break}if(this.#s(e,c,!0)){a=p==="include"?1:-1;break}}return a}translateCSharpRegex(t){let e=t;e=e.replace(/^@/,"");let n=/\(\?<(?<name>\w+)>(?<pattern>[^)]+)\)/g;return e=e.replace(n,(i,o,a)=>`(${a})`),e=e.replace(/\\/g,"\\\\"),e}isIndeterminate(t,e){return t.some(n=>n.startsWith(e))}#s(t,e,n=!1){let i=e.replace(/\*/g,".*").replace(/\?/g,".").replace(/\[!([^\]]+)\]/g,"[^$1]");return new RegExp(`${i}${n?"$":""}`).test(t)}showHiddenNodesEffect=A(()=>this._showHiddenNodes.set(this.showHiddenNodes()));pathDiscoveryMethodEffect=A(()=>{let t=this.pathDiscoveryMethod(),e=this.#n();t==="browse"&&e&&this.currentPath.set(e.value)});matchAccepts(t,e){if(!t||e.cls==="folder"||e.id==="/")return!0;let n=t.split(",");if(n.length===0)return!0;let i="."+e.id.slice(e.id.indexOf("."));return i?n.some(o=>i.endsWith(o)):!1}currentPathEffect=A(()=>{let t=this.#n();t&&(t.value=this.currentPath(),t.dispatchEvent(new Event("input")))});inputValueChangeAbortController=null;inputRefEffect=A(()=>{let t=this.formRef()?.nativeElement?.querySelector("input");t&&(this.#a(t),this.inputValueChangeAbortController&&this.inputValueChangeAbortController.abort(),this.inputValueChangeAbortController=new AbortController,t.addEventListener("inputValueChanged",e=>{this.currentPath.set(e.detail.value)},{signal:this.inputValueChangeAbortController.signal}),this.#n.set(t),t.autocomplete="off")});ngOnInit(){let t=this.startingPath();if(t)this.currentPath.set(t),this.#p(t);else{let e=this.rootPaths();e&&e.length>0?this.#i(null,e[0]):this.#i(null,"/")}}toggleSelectedNode(t,e){if(e.id==="/"||(t.stopPropagation(),e.evalState===-2))return;if(this.selectFiles()&&e.cls==="folder"){this.toggleNode(e.id,e);return}if(this.accepts()&&!e.accepted)return;let i=this.currentPath().split("\0").filter(a=>a!==""&&a!=="/"),o=this.isChildOfSelected(e)?`-${e.id}`:e.id;this.multiSelect()?i.includes(e.id)?this.currentPath.set(i.filter(a=>a!==e.id).join("\0")):i.some(a=>a.startsWith(o))?this.currentPath.set(i.filter(a=>a!==o).join("\0")):this.currentPath.set([...i,o].join("\0")):i.includes(e.id)?this.currentPath.set(i.filter(a=>a!==e.id).join("\0")):this.currentPath.set(e.id)}isChildOfSelected(t){return this.currentPath().split("\0").filter(n=>n!==""&&n!=="/").some(n=>t.id?.startsWith(n)||`-${t.id}`.startsWith(n))}toggleNode(t,e=null){e?.cls==="folder"&&(e?.children.length?this.treeNodes.update(n=>n.filter(i=>!i.id?.startsWith(e.id)||i.id===e.id)):this.#i(e,t))}#l(){setTimeout(()=>{let e=this.treeContainerRef()?.nativeElement?.querySelector(".active");e&&e.scrollIntoView({behavior:"smooth",block:"center"})},100)}#a(t){return Object.defineProperty(t,"value",{configurable:!0,get(){return Object.getOwnPropertyDescriptor(HTMLInputElement.prototype,"value").get.call(this)},set(e){return Object.getOwnPropertyDescriptor(HTMLInputElement.prototype,"value").set.call(this,e),this.dispatchEvent(new CustomEvent("inputValueChanged",{bubbles:!0,cancelable:!0,detail:{value:e}})),e}}),t}#c(t){return this.#e.postApiV1Filesystem({showHidden:!0,requestBody:{path:t},onlyFolders:!this.showFiles()})}#d(t){let e=this.backupSettings();if(this.#t.hasV2ListOperations())return this.#e.postApiV2BackupListFolder({requestBody:{BackupId:e.id,Time:e.time,Paths:t?[t]:null,PageSize:0,Page:0}}).pipe(L(n=>n.Data??[]));{let n={id:e.id+"",prefixOnly:!1,folderContents:!0,time:e.time,filter:t?"@"+t:void 0};return this.#e.getApiV1BackupByIdFiles(n).pipe(L(i=>i.Files??[]))}}#r(t){return this.isByBackupSettings()?this.#d(t):this.#c(t)}#p(t){let e=this.isWindows(),n=t.split("\0").filter(l=>l.startsWith("-")).map(l=>l.slice(1,-1)),i=t.split("\0").filter(l=>!l.startsWith("-")).filter(Boolean),o=i.map(l=>l.split(e?"\\":"/").filter(r=>r.includes(".")?!1:r)),a=["/"];o.forEach(l=>{l.forEach((r,g)=>{let c=l.slice(0,g+1).join(e?"\\":"/"),p=c;p.indexOf(":")===-1&&!p.startsWith("%")&&(p="/"+c),a.includes(p)||a.push(p)})}),this.isLoading.set(!0);let C=a.map(l=>this.#r(l).pipe(L(r=>({status:"success",value:r,url:l})),ne(r=>ee({status:"error",value:r,url:l}))));te(C).pipe(q(()=>this.isLoading.set(!1))).subscribe({next:l=>{let r=l.filter(c=>c.status==="success"),g=l.filter(c=>c.status==="error");this.treeNodes.update(c=>{let p=r.flatMap(b=>b.value.map(P=>{let _=P.id,E=P.id.startsWith("%")&&P.id.endsWith("%")?P.resolvedpath+"/":P.id,x=_&&_.split("/").filter(Boolean).slice(0,-1).join("/"),I="/"+(_&&_.split("/").filter(Boolean).join("/")),w=i.findIndex(y=>this.multiSelect()?I.startsWith(y):I===y)>-1,Fe=i.findIndex(y=>y===_)>-1,Se=n.findIndex(y=>y===I)>-1;return G(j({},P),{cls:E.endsWith("/")||E.endsWith("\\")?"folder":"file",parentPath:x.startsWith("%")?x:"/"+x,isSelected:w&&!Se||Fe})})),d=[...new Map([...c,...p].map(b=>[b.id,b])).values()];return this.#l(),d})}})}#i(t=null,e="/"){this.isLoading.set(!0),this.#r(e).pipe(q(()=>this.isLoading.set(!1))).subscribe({next:n=>{let i=this.isByBackupSettings()?n.map(o=>{let C=o.Path.includes("\\")?"\\":"/";return{text:o.Path.split(C).filter(l=>l!=="").pop(),id:o.Path,cls:o.Path.endsWith(C)?"folder":"file",leaf:t!==null,resolvedpath:o.Path,hidden:!1}}):n;this.treeNodes.update(o=>{let a=i.map(l=>{let g=l.id.includes("\\")?"\\":"/",c=l.id.startsWith("%")&&l.id.endsWith("%")||l.id.endsWith(g)?"folder":"file";return G(j({},l),{cls:c,parentPath:e})}),C=[...new Map([...o,...a].map(l=>[l.id,l])).values()];return this.hideShortcuts()?C.filter(l=>!l.id.startsWith("%")):C})}})}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=ie({type:s,selectors:[["app-file-tree"]],viewQuery:function(e,n){e&1&&(J(n.treeContainerRef,we,5),J(n.formRef,ye,5)),e&2&&pe(2)},hostVars:2,hostBindings:function(e,n){e&2&&T("disabled",n.disabled())},inputs:{multiSelect:[1,"multiSelect"],disabled:[1,"disabled"],showFiles:[1,"showFiles"],selectFiles:[1,"selectFiles"],accepts:[1,"accepts"],startingPath:[1,"startingPath"],rootPaths:[1,"rootPaths"],backupSettings:[1,"backupSettings"],pathRefreshTrigger:[1,"pathRefreshTrigger"],showHiddenNodes:[1,"showHiddenNodes"],hideShortcuts:[1,"hideShortcuts"]},outputs:{includes:"includes",excludes:"excludes"},ngContentSelectors:ke,decls:15,vars:15,consts:()=>{let t;t=$localize` Browser path `;let e;e=$localize` Manually type path `;let n;return n=$localize` Show hidden ${"\uFFFD0\uFFFD"}:INTERPOLATION: `,[["treeContainer",""],["recursiveTree",""],["formRef",""],["treeNode",""],t,e,n,[1,"section"],[1,"browse-files"],[1,"indeterminate","primary"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],[1,"primary","raised","browse-files-toggle",3,"active"],[1,"form-field"],["type","button",3,"click"],["action","",3,"click"],[1,"icon"],[1,"spk-primary"],[1,"text",3,"click"],[1,"small"],[1,"primary","raised","browse-files-toggle",3,"click"]]},template:function(e,n){if(e&1&&(de(Ne),M(0,Ae,5,4,"spk-button-group"),h(1,"div",7),D(2,0,["ngProjectAs","label",5,["label"]]),h(3,"div",8,0),M(5,Le,1,0,"spk-progress-bar",9)(6,Qe,3,2,"ng-template",null,1,_e)(8,Ke,1,0,"ng-container",10),f(),M(9,Ue,2,3,"spk-toggle",11),f(),h(10,"div",12,2)(12,"spk-form-field"),D(13,1,["ngProjectAs","label",5,["label"]]),D(14,2,["ngProjectAs","input",5,["input"]]),f()()),e&2){let i=Y(7);F(n.multiSelect()?-1:0),m(),T("hidden",n.pathDiscoveryMethod()!=="browse"),m(2),T("visualize-accepted",n.accepts()),m(2),F(n.isLoading()?5:-1),m(3),U("ngTemplateOutlet",i)("ngTemplateOutletContext",V(13,Me,V(11,Re,n.treeStructure()))),m(),F(!n.accepts()&&!n.isByBackupSettings()?9:-1),m(),T("hidden",n.pathDiscoveryMethod()!=="path")}},dependencies:[Ce,Te,me,Pe,Ee,ve,fe,xe],styles:['[_nghost-%COMP%]{display:flex;flex-direction:column;gap:1rem}.disabled[_nghost-%COMP%]{opacity:.5;-webkit-user-select:none;user-select:none;pointer-events:none;position:relative}.disabled[_nghost-%COMP%]:before{content:"";position:absolute;inset:0;background:transparent}.fill[_nghost-%COMP%]{height:auto;overflow:hidden;flex:1 0}.fill[_nghost-%COMP%] .section[_ngcontent-%COMP%]{height:auto;overflow:hidden;flex:1 0;display:grid;grid-template-columns:1fr auto;grid-template-rows:auto 1fr;grid-template-areas:"label toggle" "tree tree"}.fill[_nghost-%COMP%] .browse-files[_ngcontent-%COMP%]{resize:none;height:initial;grid-area:tree}.fill[_nghost-%COMP%] label[_ngcontent-%COMP%]{grid-area:label}.fill[_nghost-%COMP%] spk-toggle[_ngcontent-%COMP%]{grid-area:toggle;flex-direction:row-reverse}.section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.form-field.hidden[_ngcontent-%COMP%]{display:none}.browse-files[_ngcontent-%COMP%]{display:flex;gap:.5rem;padding:.5rem 1rem;height:12.5rem;border:1px solid var(--base-level-40);border-radius:var(--shape-3);overflow:auto;resize:vertical;background:var(--base-level-10);position:relative}.browse-files[_ngcontent-%COMP%] spk-progress-bar[_ngcontent-%COMP%]{position:absolute;top:0;left:0;right:0}.browse-files.visualize-accepted[_ngcontent-%COMP%] [action][_ngcontent-%COMP%]:not(.accepted){opacity:.5}.browse-files.visualize-accepted[_ngcontent-%COMP%] [action].accepted[_ngcontent-%COMP%]{opacity:1}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%]{--list-active-bg: var(--base-level-30);gap:.125rem;padding:0;height:min-content;min-width:min-content}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action][_ngcontent-%COMP%]{padding:0;gap:0;border:1px solid transparent}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action].active[_ngcontent-%COMP%]{border-color:transparent;--list-active-bg: var(--primary-level-20)}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action].indeterminate[_ngcontent-%COMP%]{border-color:var(--primary-level-40)}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action].usually-hidden[_ngcontent-%COMP%]{opacity:.6}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action].root[_ngcontent-%COMP%]{gap:.25rem}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action].root[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]:has(spk-icon:nth-child(2)){width:3rem}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action].root[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{width:1.5rem}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action][_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{flex:1 0;height:100%;width:max-content;display:flex;align-items:center}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action][_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{width:3rem;gap:.25rem;height:1.5rem;display:flex;align-items:center;justify-content:center;cursor:pointer}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action][_ngcontent-%COMP%] .icon.file[_ngcontent-%COMP%]{width:2rem;padding:0 .25rem}.browse-files-toggle[_ngcontent-%COMP%]{color:var(--base-level-60R)}.hidden[_ngcontent-%COMP%]{display:none}'],changeDetection:0})};export{Z as a};
|
|
1
|
+
import{a as be}from"./chunk-F2GEUOGZ.js";import{s as xe}from"./chunk-ELMONRIG.js";import{A as ve,a as ge,f as me,l as Ce,n as Pe,p as Ee}from"./chunk-P4ZFQZCA.js";import{h as Te}from"./chunk-S5EF63OY.js";import{ia as fe}from"./chunk-7L2WUS2V.js";import{$a as K,B as ne,Bb as re,Bc as _e,Cb as oe,Db as h,Eb as f,F as q,Fb as le,Ib as z,Jb as B,Oc as W,Pc as A,Rb as $,Sb as ae,Tb as ce,Ua as m,Vb as R,Wb as u,Xb as de,Yb as D,Z as X,ea as N,fa as k,fc as J,gb as ie,gc as pe,hc as Y,ic as S,kc as ue,lb as M,n as ee,r as L,ra as Q,sa as v,ub as U,va as O,vb as se,vc as V,wb as T,wc as he,x as te,zb as F}from"./chunk-L72ALLHJ.js";import{a as j,b as G}from"./chunk-7CGTOI24.js";var we=["treeContainer"],ye=["formRef"],Ne=[[["label"]],[["label"]],[["input"]]],ke=["label","label","input"],Re=s=>({children:s,level:0}),Me=s=>({$implicit:s}),Ie=(s,t)=>({children:s,level:t}),We=(s,t)=>t.id;function Ae(s,t){if(s&1){let e=B();h(0,"spk-button-group")(1,"button",13),R("click",function(){N(e);let i=u();return k(i.pathDiscoveryMethod.set("browse"))}),$(2,4),f(),h(3,"button",13),R("click",function(){N(e);let i=u();return k(i.pathDiscoveryMethod.set("path"))}),$(4,5),f()()}if(s&2){let e=u();m(),T("active",e.pathDiscoveryMethod()==="browse"),m(2),T("active",e.pathDiscoveryMethod()==="path")}}function Le(s,t){s&1&&le(0,"spk-progress-bar",9)}function Be(s,t){s&1&&(h(0,"spk-icon",18),S(1,"caret-down"),f(),h(2,"spk-icon",16),S(3,"folder-open"),f())}function $e(s,t){s&1&&(h(0,"spk-icon"),S(1,"file"),f())}function De(s,t){s&1&&(h(0,"spk-icon",18),S(1,"caret-right"),f(),h(2,"spk-icon",16),S(3,"folder"),f())}function Ve(s,t){if(s&1&&M(0,Be,4,0)(1,$e,2,0,"spk-icon")(2,De,4,0),s&2){let e=u(2).$implicit;F(e.children.length?0:e.cls==="file"?1:2)}}function He(s,t){s&1&&(h(0,"spk-icon",16),S(1,"desktop-tower"),f())}function je(s,t){s&1&&z(0)}function Ge(s,t){if(s&1&&M(0,je,1,0,"ng-container",10),s&2){let e=u(2).$implicit,n=u().$implicit;u();let i=Y(7);U("ngTemplateOutlet",i)("ngTemplateOutletContext",V(5,Me,he(2,Ie,e.children,n.level+1)))}}function qe(s,t){if(s&1){let e=B();h(0,"div",14,3),R("click",function(){N(e);let i=u().$implicit,o=u(2);return k(o.toggleNode(i.id,i))}),h(2,"div",15),M(3,Ve,3,1)(4,He,2,0,"spk-icon",16),f(),h(5,"div",17),R("click",function(i){N(e);let o=u().$implicit,a=u(2);return k(a.toggleSelectedNode(i,o))}),S(6),f()(),M(7,Ge,1,7,"ng-container")}if(s&2){let e=u().$implicit,n=u().$implicit,i=u();T("accepted",e.accepted===!0)("active",e.evalState===i.TreeEvalEnum.Included)("indeterminate",e.isIndeterminate)("open",e.children.length)("usually-hidden",e.hidden)("root",n.level===0),m(2),T("file",e.cls==="file"),m(),F(e.id!=="/"?3:4),m(3),ue(" ",e.text," "),m(),F(e.children.length>0?7:-1)}}function Xe(s,t){if(s&1&&M(0,qe,8,17),s&2){let e=t.$implicit,n=u(2);F(e.hidden&&n._showHiddenNodes()||!e.hidden?0:-1)}}function Qe(s,t){if(s&1&&(h(0,"spk-list"),re(1,Xe,1,1,null,null,We),f()),s&2){let e=t.$implicit;se("padding-left",e.level*.25,"rem"),m(),oe(e.children)}}function Ke(s,t){s&1&&z(0)}function Ue(s,t){if(s&1){let e=B();h(0,"spk-toggle",19),R("click",function(){N(e);let i=u();return k(i._showHiddenNodes.set(!i._showHiddenNodes()))}),$(1,6),f()}if(s&2){let e=u();T("active",e._showHiddenNodes()),m(),ae(e.showFiles()?"files":"folders"),ce(1)}}var Oe=(o=>(o[o.ExcludedByParent=-2]="ExcludedByParent",o[o.Excluded=-1]="Excluded",o[o.None=0]="None",o[o.Included=1]="Included",o[o.IncludedByParent=2]="IncludedByParent",o))(Oe||{}),Z=class s{#e=X(Te);#t=X(be);multiSelect=v(!1);disabled=v(!1);showFiles=v(!1);selectFiles=v(!1);accepts=v(null);startingPath=v(null);rootPaths=v([]);backupSettings=v(null);pathRefreshTrigger=v(!1);showHiddenNodes=v(!1);hideShortcuts=v(!1);includes=Q();excludes=Q();_showHiddenNodes=O(!1);treeContainerRef=K("treeContainer");formRef=K("formRef");pathDiscoveryMethod=O("browse");isLoading=O(!1);currentPath=O("/");#n=O(null);treeSearchQuery=O("");treeNodes=O([]);isWindows=W(()=>this.#t.systemInfo()?.OSType==="Windows");filterGroups=this.#t.filterGroups();isByBackupSettings=W(()=>{let t=this.backupSettings();return!(t===void 0||t?.id===void 0||t?.time===void 0)});searchableTreeNodes=W(()=>{let t=this.treeSearchQuery();return t?this.treeNodes().filter(e=>e.text?.toLowerCase().includes(t.toLowerCase())):this.treeNodes()});TreeEvalEnum=Oe;treeStructure=W(()=>{let t=this.showHiddenNodes(),e=this.currentPath().split("\0").filter(r=>r!==""&&r!=="/"),n=structuredClone(e);for(let r=0;r<n.length;r++){let c=n[r].slice(1);if(c.startsWith("{")&&c.endsWith("}")){let p=c.slice(1,-1),d=this.filterGroups?.FilterGroups[p];if(d&&d.length){let b=d.map(P=>`-${P}`);n.splice(r,1,...b)}}}let i=this.searchableTreeNodes(),o=this.rootPaths(),a=this.accepts(),C=this.isWindows(),l=[];return o.length>0?l=o.map(r=>({id:r,resolvedpath:r,text:r,parentPath:"",children:[],evalState:0,isIndeterminate:!1,cls:"folder"})):l=[{id:"/",resolvedpath:"/",text:"Computer",parentPath:"",children:[],evalState:0,isIndeterminate:!1,cls:"folder"}],l.map(r=>{let g=new Map,c=r?.id;a&&(r.accepted=!0),g.set(r.id,r);let p=o.length>0?i.filter(d=>d.parentPath===r.id):i;for(let d of p){let b=o.length>0?d.id.replace(c??"",""):d.id,P=C?"\\":"/",_=b.split(P).filter(Boolean),E="",x=r;for(let H of _){if(E+=H+P,!g.has(E)){let I=d.hidden===!0&&t?0:this.#o(n,d.id,d.cls,x,C),w={id:d.id,isIndeterminate:this.isIndeterminate(n,d.id),evalState:I,parentPath:E,resolvedpath:d.id?.startsWith("%")?d.resolvedpath+P:E,hidden:d.hidden,text:d.text,cls:d.cls,children:[]};a&&(w.accepted=this.matchAccepts(a,w)),g.set(E,w),x.children.push(w)}x=g.get(E)}}return r}),l});#o(t,e,n,i,o){if(i.evalState===-1)return-2;let a=0,C=t.filter(r=>!r.startsWith("-")&&!r.startsWith("+")),l=t.filter(r=>r.startsWith("-")||r.startsWith("+"));if(C.length===0)return a;for(let r=0;r<C.length;r++){let g=C[r];if(e?.startsWith(g)){a=1;break}}if(l.length===0)return a;for(let r=0;r<l.length;r++){let g=l[r],c=g.slice(1),p=g.startsWith("-")?"exclude":"include",d=o?"\\":"/";if((o?c.slice(2):c).startsWith(d)&&c.endsWith(d)){if(n!=="folder")continue;if(e===c){a=p==="include"?1:-1;break}}if(c.startsWith("*")&&c.endsWith(`*${d}`)){if(n!=="folder")continue;let _=c.slice(1,-2);if(_==="")break;if(e?.includes(_+d)){a=p==="include"?1:-1;break}}if(c.startsWith("[.*")&&c.endsWith(`[^\\${d}]*]`)){if(n!=="file")continue;let _=c.slice(3,-7);if(new RegExp(_).test(e)){a=p==="include"?1:-1;break}}if(c.startsWith("[")&&c.endsWith("]")){let _=c.slice(1,-1),E=this.translateCSharpRegex(_);if(new RegExp(`${E}`).test(e)){a=p==="include"?1:-1;break}}if(c.startsWith("*.")){if(n!=="file"||c.replace("*.","").length===0)continue;if(this.#s(e,c,!0)){a=p==="include"?1:-1;break}}if(c==="")continue;if(c===e){a=p==="include"?1:-1;break}if(this.#s(e,c,!0)){a=p==="include"?1:-1;break}}return a}translateCSharpRegex(t){let e=t;e=e.replace(/^@/,"");let n=/\(\?<(?<name>\w+)>(?<pattern>[^)]+)\)/g;return e=e.replace(n,(i,o,a)=>`(${a})`),e=e.replace(/\\/g,"\\\\"),e}isIndeterminate(t,e){return t.some(n=>n.startsWith(e))}#s(t,e,n=!1){let i=e.replace(/\*/g,".*").replace(/\?/g,".").replace(/\[!([^\]]+)\]/g,"[^$1]");return new RegExp(`${i}${n?"$":""}`).test(t)}showHiddenNodesEffect=A(()=>this._showHiddenNodes.set(this.showHiddenNodes()));pathDiscoveryMethodEffect=A(()=>{let t=this.pathDiscoveryMethod(),e=this.#n();t==="browse"&&e&&this.currentPath.set(e.value)});matchAccepts(t,e){if(!t||e.cls==="folder"||e.id==="/")return!0;let n=t.split(",");if(n.length===0)return!0;let i="."+e.id.slice(e.id.indexOf("."));return i?n.some(o=>i.endsWith(o)):!1}currentPathEffect=A(()=>{let t=this.#n();t&&(t.value=this.currentPath(),t.dispatchEvent(new Event("input")))});inputValueChangeAbortController=null;inputRefEffect=A(()=>{let t=this.formRef()?.nativeElement?.querySelector("input");t&&(this.#a(t),this.inputValueChangeAbortController&&this.inputValueChangeAbortController.abort(),this.inputValueChangeAbortController=new AbortController,t.addEventListener("inputValueChanged",e=>{this.currentPath.set(e.detail.value)},{signal:this.inputValueChangeAbortController.signal}),this.#n.set(t),t.autocomplete="off")});ngOnInit(){let t=this.startingPath();if(t)this.currentPath.set(t),this.#p(t);else{let e=this.rootPaths();e&&e.length>0?this.#i(null,e[0]):this.#i(null,"/")}}toggleSelectedNode(t,e){if(e.id==="/"||(t.stopPropagation(),e.evalState===-2))return;if(this.selectFiles()&&e.cls==="folder"){this.toggleNode(e.id,e);return}if(this.accepts()&&!e.accepted)return;let i=this.currentPath().split("\0").filter(a=>a!==""&&a!=="/"),o=this.isChildOfSelected(e)?`-${e.id}`:e.id;this.multiSelect()?i.includes(e.id)?this.currentPath.set(i.filter(a=>a!==e.id).join("\0")):i.some(a=>a.startsWith(o))?this.currentPath.set(i.filter(a=>a!==o).join("\0")):this.currentPath.set([...i,o].join("\0")):i.includes(e.id)?this.currentPath.set(i.filter(a=>a!==e.id).join("\0")):this.currentPath.set(e.id)}isChildOfSelected(t){return this.currentPath().split("\0").filter(n=>n!==""&&n!=="/").some(n=>t.id?.startsWith(n)||`-${t.id}`.startsWith(n))}toggleNode(t,e=null){e?.cls==="folder"&&(e?.children.length?this.treeNodes.update(n=>n.filter(i=>!i.id?.startsWith(e.id)||i.id===e.id)):this.#i(e,t))}#l(){setTimeout(()=>{let e=this.treeContainerRef()?.nativeElement?.querySelector(".active");e&&e.scrollIntoView({behavior:"smooth",block:"center"})},100)}#a(t){return Object.defineProperty(t,"value",{configurable:!0,get(){return Object.getOwnPropertyDescriptor(HTMLInputElement.prototype,"value").get.call(this)},set(e){return Object.getOwnPropertyDescriptor(HTMLInputElement.prototype,"value").set.call(this,e),this.dispatchEvent(new CustomEvent("inputValueChanged",{bubbles:!0,cancelable:!0,detail:{value:e}})),e}}),t}#c(t){return this.#e.postApiV1Filesystem({showHidden:!0,requestBody:{path:t},onlyFolders:!this.showFiles()})}#d(t){let e=this.backupSettings();if(this.#t.hasV2ListOperations())return this.#e.postApiV2BackupListFolder({requestBody:{BackupId:e.id,Time:e.time,Paths:t?[t]:null,PageSize:0,Page:0}}).pipe(L(n=>n.Data??[]));{let n={id:e.id+"",prefixOnly:!1,folderContents:!0,time:e.time,filter:t?"@"+t:void 0};return this.#e.getApiV1BackupByIdFiles(n).pipe(L(i=>i.Files??[]))}}#r(t){return this.isByBackupSettings()?this.#d(t):this.#c(t)}#p(t){let e=this.isWindows(),n=t.split("\0").filter(l=>l.startsWith("-")).map(l=>l.slice(1,-1)),i=t.split("\0").filter(l=>!l.startsWith("-")).filter(Boolean),o=i.map(l=>l.split(e?"\\":"/").filter(r=>r.includes(".")?!1:r)),a=["/"];o.forEach(l=>{l.forEach((r,g)=>{let c=l.slice(0,g+1).join(e?"\\":"/"),p=c;p.indexOf(":")===-1&&!p.startsWith("%")&&(p="/"+c),a.includes(p)||a.push(p)})}),this.isLoading.set(!0);let C=a.map(l=>this.#r(l).pipe(L(r=>({status:"success",value:r,url:l})),ne(r=>ee({status:"error",value:r,url:l}))));te(C).pipe(q(()=>this.isLoading.set(!1))).subscribe({next:l=>{let r=l.filter(c=>c.status==="success"),g=l.filter(c=>c.status==="error");this.treeNodes.update(c=>{let p=r.flatMap(b=>b.value.map(P=>{let _=P.id,E=P.id.startsWith("%")&&P.id.endsWith("%")?P.resolvedpath+"/":P.id,x=_&&_.split("/").filter(Boolean).slice(0,-1).join("/"),I="/"+(_&&_.split("/").filter(Boolean).join("/")),w=i.findIndex(y=>this.multiSelect()?I.startsWith(y):I===y)>-1,Fe=i.findIndex(y=>y===_)>-1,Se=n.findIndex(y=>y===I)>-1;return G(j({},P),{cls:E.endsWith("/")||E.endsWith("\\")?"folder":"file",parentPath:x.startsWith("%")?x:"/"+x,isSelected:w&&!Se||Fe})})),d=[...new Map([...c,...p].map(b=>[b.id,b])).values()];return this.#l(),d})}})}#i(t=null,e="/"){this.isLoading.set(!0),this.#r(e).pipe(q(()=>this.isLoading.set(!1))).subscribe({next:n=>{let i=this.isByBackupSettings()?n.map(o=>{let C=o.Path.includes("\\")?"\\":"/";return{text:o.Path.split(C).filter(l=>l!=="").pop(),id:o.Path,cls:o.Path.endsWith(C)?"folder":"file",leaf:t!==null,resolvedpath:o.Path,hidden:!1}}):n;this.treeNodes.update(o=>{let a=i.map(l=>{let g=l.id.includes("\\")?"\\":"/",c=l.id.startsWith("%")&&l.id.endsWith("%")||l.id.endsWith(g)?"folder":"file";return G(j({},l),{cls:c,parentPath:e})}),C=[...new Map([...o,...a].map(l=>[l.id,l])).values()];return this.hideShortcuts()?C.filter(l=>!l.id.startsWith("%")):C})}})}static \u0275fac=function(e){return new(e||s)};static \u0275cmp=ie({type:s,selectors:[["app-file-tree"]],viewQuery:function(e,n){e&1&&(J(n.treeContainerRef,we,5),J(n.formRef,ye,5)),e&2&&pe(2)},hostVars:2,hostBindings:function(e,n){e&2&&T("disabled",n.disabled())},inputs:{multiSelect:[1,"multiSelect"],disabled:[1,"disabled"],showFiles:[1,"showFiles"],selectFiles:[1,"selectFiles"],accepts:[1,"accepts"],startingPath:[1,"startingPath"],rootPaths:[1,"rootPaths"],backupSettings:[1,"backupSettings"],pathRefreshTrigger:[1,"pathRefreshTrigger"],showHiddenNodes:[1,"showHiddenNodes"],hideShortcuts:[1,"hideShortcuts"]},outputs:{includes:"includes",excludes:"excludes"},ngContentSelectors:ke,decls:15,vars:15,consts:()=>{let t;t=$localize` Browser path `;let e;e=$localize` Manually type path `;let n;return n=$localize` Show hidden ${"\uFFFD0\uFFFD"}:INTERPOLATION: `,[["treeContainer",""],["recursiveTree",""],["formRef",""],["treeNode",""],t,e,n,[1,"section"],[1,"browse-files"],[1,"indeterminate","primary"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],[1,"primary","raised","browse-files-toggle",3,"active"],[1,"form-field"],["type","button",3,"click"],["action","",3,"click"],[1,"icon"],[1,"spk-primary"],[1,"text",3,"click"],[1,"small"],[1,"primary","raised","browse-files-toggle",3,"click"]]},template:function(e,n){if(e&1&&(de(Ne),M(0,Ae,5,4,"spk-button-group"),h(1,"div",7),D(2,0,["ngProjectAs","label",5,["label"]]),h(3,"div",8,0),M(5,Le,1,0,"spk-progress-bar",9)(6,Qe,3,2,"ng-template",null,1,_e)(8,Ke,1,0,"ng-container",10),f(),M(9,Ue,2,3,"spk-toggle",11),f(),h(10,"div",12,2)(12,"spk-form-field"),D(13,1,["ngProjectAs","label",5,["label"]]),D(14,2,["ngProjectAs","input",5,["input"]]),f()()),e&2){let i=Y(7);F(n.multiSelect()?-1:0),m(),T("hidden",n.pathDiscoveryMethod()!=="browse"),m(2),T("visualize-accepted",n.accepts()),m(2),F(n.isLoading()?5:-1),m(3),U("ngTemplateOutlet",i)("ngTemplateOutletContext",V(13,Me,V(11,Re,n.treeStructure()))),m(),F(!n.accepts()&&!n.isByBackupSettings()?9:-1),m(),T("hidden",n.pathDiscoveryMethod()!=="path")}},dependencies:[me,ve,ge,Ce,Pe,Ee,fe,xe],styles:['[_nghost-%COMP%]{display:flex;flex-direction:column;gap:1rem}.disabled[_nghost-%COMP%]{opacity:.5;-webkit-user-select:none;user-select:none;pointer-events:none;position:relative}.disabled[_nghost-%COMP%]:before{content:"";position:absolute;inset:0;background:transparent}.fill[_nghost-%COMP%]{height:auto;overflow:hidden;flex:1 0}.fill[_nghost-%COMP%] .section[_ngcontent-%COMP%]{height:auto;overflow:hidden;flex:1 0;display:grid;grid-template-columns:1fr auto;grid-template-rows:auto 1fr;grid-template-areas:"label toggle" "tree tree"}.fill[_nghost-%COMP%] .browse-files[_ngcontent-%COMP%]{resize:none;height:initial;grid-area:tree}.fill[_nghost-%COMP%] label[_ngcontent-%COMP%]{grid-area:label}.fill[_nghost-%COMP%] spk-toggle[_ngcontent-%COMP%]{grid-area:toggle;flex-direction:row-reverse}.section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.form-field.hidden[_ngcontent-%COMP%]{display:none}.browse-files[_ngcontent-%COMP%]{display:flex;gap:.5rem;padding:.5rem 1rem;height:12.5rem;border:1px solid var(--base-level-40);border-radius:var(--shape-3);overflow:auto;resize:vertical;background:var(--base-level-10);position:relative}.browse-files[_ngcontent-%COMP%] spk-progress-bar[_ngcontent-%COMP%]{position:absolute;top:0;left:0;right:0}.browse-files.visualize-accepted[_ngcontent-%COMP%] [action][_ngcontent-%COMP%]:not(.accepted){opacity:.5}.browse-files.visualize-accepted[_ngcontent-%COMP%] [action].accepted[_ngcontent-%COMP%]{opacity:1}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%]{--list-active-bg: var(--base-level-30);gap:.125rem;padding:0;height:min-content;min-width:min-content}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action][_ngcontent-%COMP%]{padding:0;gap:0;border:1px solid transparent}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action].active[_ngcontent-%COMP%]{border-color:transparent;--list-active-bg: var(--primary-level-20)}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action].indeterminate[_ngcontent-%COMP%]{border-color:var(--primary-level-40)}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action].usually-hidden[_ngcontent-%COMP%]{opacity:.6}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action].root[_ngcontent-%COMP%]{gap:.25rem}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action].root[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]:has(spk-icon:nth-child(2)){width:3rem}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action].root[_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{width:1.5rem}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action][_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{flex:1 0;height:100%;width:max-content;display:flex;align-items:center}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action][_ngcontent-%COMP%] .icon[_ngcontent-%COMP%]{width:3rem;gap:.25rem;height:1.5rem;display:flex;align-items:center;justify-content:center;cursor:pointer}.browse-files[_ngcontent-%COMP%] spk-list[_ngcontent-%COMP%] [action][_ngcontent-%COMP%] .icon.file[_ngcontent-%COMP%]{width:2rem;padding:0 .25rem}.browse-files-toggle[_ngcontent-%COMP%]{color:var(--base-level-60R)}.hidden[_ngcontent-%COMP%]{display:none}'],changeDetection:0})};export{Z as a};
|