@duplicati/ngclient 0.0.207 → 0.0.209
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/dest-icons/digitalocean.png +0 -0
- package/assets/dest-icons/hetzner.png +0 -0
- package/chunk-2DOT6WAE.js +1 -0
- package/{chunk-JJY6UOEY.js → chunk-2LSZ2I43.js} +1 -1
- package/chunk-2T442RZU.js +1 -0
- package/chunk-2V75WWT2.js +1 -0
- package/chunk-2XMYVT7N.js +1 -0
- package/chunk-3A4HTZ7B.js +1 -0
- package/{chunk-PGISF7LM.js → chunk-3KMV4PTJ.js} +1 -1
- package/{chunk-3MS6SVET.js → chunk-3SSB4QCJ.js} +1 -1
- package/chunk-3WOW2XM3.js +1 -0
- package/{chunk-WLAJ3YIP.js → chunk-3ZCJK7PY.js} +1 -1
- package/{chunk-VNF7NNO5.js → chunk-47PB4WN3.js} +1 -1
- package/{chunk-OL5HI5OG.js → chunk-4NENQSXM.js} +1 -1
- package/chunk-4QE3MT56.js +1 -0
- package/{chunk-OVLGKJ3Z.js → chunk-5ECY4LSP.js} +1 -1
- package/chunk-5KQZMHFN.js +1 -0
- package/{chunk-2FPYV4EW.js → chunk-64IX6ISO.js} +1 -1
- package/chunk-6HMNDYMY.js +1 -0
- package/chunk-77ALZWIA.js +1 -0
- package/{chunk-G3FMV74P.js → chunk-7FYL7MVA.js} +1 -1
- package/chunk-7J6AVYZE.js +1 -0
- package/{chunk-NJBOYRXU.js → chunk-7YLK4QIL.js} +1 -1
- package/{chunk-XHDAWK7I.js → chunk-7ZA3Q6TS.js} +1 -1
- package/chunk-AYOFR344.js +1 -0
- package/chunk-AZFGZQQK.js +1 -0
- package/{chunk-QY5UGQ3R.js → chunk-AZJ2P3YU.js} +1 -1
- package/{chunk-GGW26MAG.js → chunk-B35WNLRM.js} +1 -1
- package/{chunk-NGKFJLI2.js → chunk-BEXYTIOL.js} +1 -1
- package/{chunk-V63YAEPZ.js → chunk-BKQA64HZ.js} +1 -1
- package/chunk-BMWZYMK6.js +1 -0
- package/chunk-BQEUHLSB.js +1 -0
- package/chunk-BSYMQ4VF.js +1 -0
- package/{chunk-R4E5IO3A.js → chunk-C6RVYQ4M.js} +1 -1
- package/chunk-CJ5SZZQC.js +1 -0
- package/chunk-CNOKPOR3.js +1 -0
- package/chunk-CNUQWXBC.js +1 -0
- package/chunk-CPI5ZQUF.js +1 -0
- package/chunk-DHOED4DH.js +1 -0
- package/{chunk-XTFBRBQX.js → chunk-EL2UKEXS.js} +1 -1
- package/chunk-ERITO7WM.js +4 -0
- package/{chunk-P7TJCJ64.js → chunk-FE3ADWR5.js} +1 -1
- package/chunk-FKCZIBN3.js +1 -0
- package/chunk-G6ZV6LAU.js +1 -0
- package/chunk-G7XKFPGX.js +1 -0
- package/{chunk-3QS6DB3O.js → chunk-GROPRXXJ.js} +1 -1
- package/{chunk-O3GGVB2B.js → chunk-HA7XREWO.js} +1 -1
- package/chunk-I2HYK2BL.js +1 -0
- package/{chunk-EG3PT3XW.js → chunk-I4XRVBRQ.js} +1 -1
- package/{chunk-RWDQ3L3C.js → chunk-ITA7DTN3.js} +1 -1
- package/{chunk-7HFTVA4J.js → chunk-IZCDGVXJ.js} +1 -1
- package/{chunk-CTQKCCGM.js → chunk-JKIZ6U22.js} +1 -1
- package/chunk-JW6W3ER7.js +1 -0
- package/{chunk-VPUFUCR3.js → chunk-LGILJ5LY.js} +1 -1
- package/{chunk-NAMMULH4.js → chunk-LJBFPDG2.js} +1 -1
- package/{chunk-VUKQJ766.js → chunk-LMZN2X5M.js} +1 -1
- package/{chunk-KUX6NGQU.js → chunk-LO5YNFFR.js} +1 -1
- package/{chunk-6COK7FLL.js → chunk-MAKVVEKB.js} +1 -1
- package/chunk-NBPZDFGF.js +2 -0
- package/{chunk-LU7RSOI6.js → chunk-NBTTYKXH.js} +2 -2
- package/chunk-NDLPNBGE.js +1 -0
- package/{chunk-ZPIR5QIQ.js → chunk-NXF5BMPG.js} +1 -1
- package/chunk-O7MDPYFW.js +1 -0
- package/chunk-ODHFI4PA.js +1 -0
- package/chunk-OQ6BKP5N.js +1 -0
- package/chunk-OSAM5F7M.js +1 -0
- package/chunk-PAPOSE5G.js +1 -0
- package/{chunk-TBQPNXMN.js → chunk-Q5WLMQD4.js} +1 -1
- package/chunk-Q72Y55NB.js +1 -0
- package/chunk-QEIGUOTC.js +1 -0
- package/{chunk-AI6EYFMY.js → chunk-RC3UQLPB.js} +1 -1
- package/{chunk-7E5J43IH.js → chunk-RFB5A3B7.js} +1 -1
- package/{chunk-OOL5FC7N.js → chunk-RNTBVXBV.js} +1 -1
- package/chunk-SEFBKH36.js +1 -0
- package/{chunk-FJFREVRV.js → chunk-SLS3DCJP.js} +1 -1
- package/{chunk-OWBBT5WF.js → chunk-SUY5AQLW.js} +1 -1
- package/chunk-TYEWJKJU.js +1 -0
- package/chunk-U3SGWHNI.js +1 -0
- package/chunk-UCR4I5MD.js +1 -0
- package/chunk-UGEDZCTM.js +11 -0
- package/{chunk-KLAJGS5T.js → chunk-UUQWSINE.js} +1 -1
- package/{chunk-VKNFRCHQ.js → chunk-VAQ435AR.js} +1 -1
- package/{chunk-UOZTEZ7B.js → chunk-VTFVTC7O.js} +1 -1
- package/{chunk-7MPZ3MRD.js → chunk-W4HWOC3K.js} +1 -1
- package/chunk-WOZTK7S5.js +2 -0
- package/{chunk-SIMG6PGZ.js → chunk-WQVQC2MC.js} +1 -1
- package/{chunk-MMF252RQ.js → chunk-WZV32HLQ.js} +1 -1
- package/{chunk-OAAXQ2BE.js → chunk-X64LSE6Y.js} +1 -1
- package/chunk-XHUMSL6X.js +1 -0
- package/chunk-XQTUBHIK.js +1 -0
- package/chunk-YCLTQEU6.js +1 -0
- package/{chunk-GTZRHPRV.js → chunk-YQD4QIGG.js} +1 -1
- package/index.html +2 -2
- package/{main-DIGDM6JP.js → main-7RC24G3G.js} +1 -1
- package/package.json +1 -1
- package/ship-ui-assets/mcp/components.json +2404 -2404
- package/{styles-377DNUNK.css → styles-6WG7TD6T.css} +1 -1
- package/chunk-23UYU3M3.js +0 -1
- package/chunk-2K74TI2N.js +0 -1
- package/chunk-2T4BMRWX.js +0 -2
- package/chunk-4HB376H3.js +0 -1
- package/chunk-4VYR5E5I.js +0 -1
- package/chunk-5MKFV3IB.js +0 -1
- package/chunk-5T2JCBPV.js +0 -1
- package/chunk-7JHU54QM.js +0 -1
- package/chunk-7PUXNL75.js +0 -1
- package/chunk-A57TBTOD.js +0 -1
- package/chunk-AG7H2MR5.js +0 -1
- package/chunk-AGMFKAHM.js +0 -1
- package/chunk-AZEV3A4R.js +0 -11
- package/chunk-C5OYK6UC.js +0 -2
- package/chunk-CAJQ2FEU.js +0 -1
- package/chunk-DKPWJYG3.js +0 -1
- package/chunk-DRRYACBV.js +0 -1
- package/chunk-I2T6IA4K.js +0 -1
- package/chunk-I6PR2AV2.js +0 -1
- package/chunk-I7MAEY3S.js +0 -1
- package/chunk-IAZGVY3O.js +0 -1
- package/chunk-IPGH33MU.js +0 -1
- package/chunk-JRXD2X7B.js +0 -1
- package/chunk-JWPG4EWG.js +0 -1
- package/chunk-KUGAORAS.js +0 -1
- package/chunk-KYTPZ3WD.js +0 -1
- package/chunk-L22UB6DH.js +0 -1
- package/chunk-NGPZXZJJ.js +0 -1
- package/chunk-PVWYJV5Y.js +0 -1
- package/chunk-QY4Y5NJB.js +0 -4
- package/chunk-R45TV6JI.js +0 -1
- package/chunk-RFCIV3AX.js +0 -1
- package/chunk-RJM43XMN.js +0 -1
- package/chunk-RNE4Z2E4.js +0 -1
- package/chunk-SFW3N5OL.js +0 -1
- package/chunk-SMUUHPDS.js +0 -1
- package/chunk-STB3WOIA.js +0 -1
- package/chunk-T2KOS3XX.js +0 -1
- package/chunk-VLMNSWR3.js +0 -1
- package/chunk-XZHXN75E.js +0 -1
- package/chunk-Y46QCSB5.js +0 -1
- package/chunk-Z2BNW4KI.js +0 -1
- package/chunk-ZFREX3ZV.js +0 -1
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a}from"./chunk-SLS3DCJP.js";import"./chunk-SUY5AQLW.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";export{a as RelativeTimePipe};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as O,d as y}from"./chunk-LU7RSOI6.js";import{K as g,U as c,Y as A,l as f,m,p as R,v as D,z as k}from"./chunk-QY4Y5NJB.js";import{a as l,b as I}from"./chunk-7CGTOI24.js";var P=class{_fns;constructor(){this._fns=[]}eject(e){let p=this._fns.indexOf(e);p!==-1&&(this._fns=[...this._fns.slice(0,p),...this._fns.slice(p+1)])}use(e){this._fns=[...this._fns,e]}},t={BASE:"",CREDENTIALS:"include",ENCODE_PATH:void 0,HEADERS:void 0,PASSWORD:void 0,TOKEN:void 0,USERNAME:void 0,VERSION:"1",WITH_CREDENTIALS:!1,interceptors:{response:new P}};var d=class extends Error{url;status;statusText;body;request;constructor(e,p,r){super(r),this.name="ApiError",this.url=p.url,this.status=p.status,this.statusText=p.statusText,this.body=p.body,this.request=e}};var h=i=>typeof i=="string",v=i=>h(i)&&i!=="",T=i=>i instanceof Blob,S=i=>i instanceof FormData,L=i=>{try{return btoa(i)}catch{return Buffer.from(i).toString("base64")}},w=i=>{let e=[],p=(a,n)=>{e.push(`${encodeURIComponent(a)}=${encodeURIComponent(String(n))}`)},r=(a,n)=>{n!=null&&(n instanceof Date?p(a,n.toISOString()):Array.isArray(n)?n.forEach(o=>r(a,o)):typeof n=="object"?Object.entries(n).forEach(([o,u])=>r(`${a}[${o}]`,u)):p(a,n))};return Object.entries(i).forEach(([a,n])=>r(a,n)),e.length?`?${e.join("&")}`:""},F=(i,e)=>{let p=i.ENCODE_PATH||encodeURI,r=e.url.replace("{api-version}",i.VERSION).replace(/{(.*?)}/g,(n,o)=>e.path?.hasOwnProperty(o)?p(String(e.path[o])):n),a=i.BASE+r;return e.query?a+w(e.query):a},j=i=>{if(i.formData){let e=new FormData,p=(r,a)=>{h(a)||T(a)?e.append(r,a):e.append(r,JSON.stringify(a))};return Object.entries(i.formData).filter(([,r])=>r!=null).forEach(([r,a])=>{Array.isArray(a)?a.forEach(n=>p(r,n)):p(r,a)}),e}},V=async(i,e)=>typeof e=="function"?e(i):e,U=(i,e)=>D({token:V(e,i.TOKEN),username:V(e,i.USERNAME),password:V(e,i.PASSWORD),additionalHeaders:V(e,i.HEADERS)}).pipe(R(({token:p,username:r,password:a,additionalHeaders:n})=>{let o=Object.entries(l(l({Accept:"application/json"},n),e.headers)).filter(([,u])=>u!=null).reduce((u,[B,b])=>I(l({},u),{[B]:String(b)}),{});if(v(p)&&(o.Authorization=`Bearer ${p}`),v(r)&&v(a)){let u=L(`${r}:${a}`);o.Authorization=`Basic ${u}`}return e.body!==void 0&&(e.mediaType?o["Content-Type"]=e.mediaType:T(e.body)?o["Content-Type"]=e.body.type||"application/octet-stream":h(e.body)?o["Content-Type"]="text/plain":S(e.body)||(o["Content-Type"]="application/json")),new O(o)})),H=i=>{if(i.body)return i.mediaType?.includes("application/json")||i.mediaType?.includes("+json")?JSON.stringify(i.body):h(i.body)||T(i.body)||S(i.body)?i.body:JSON.stringify(i.body)},N=(i,e,p,r,a,n,o)=>p.request(e.method,r,{headers:o,body:a??n,withCredentials:i.WITH_CREDENTIALS,observe:"response"}),M=(i,e)=>{if(e){let p=i.headers.get(e);if(h(p))return p}},z=i=>{if(i.status!==204&&i.body!==null)return i.body},W=(i,e)=>{let r=l({400:"Bad Request",401:"Unauthorized",402:"Payment Required",403:"Forbidden",404:"Not Found",405:"Method Not Allowed",406:"Not Acceptable",407:"Proxy Authentication Required",408:"Request Timeout",409:"Conflict",410:"Gone",411:"Length Required",412:"Precondition Failed",413:"Payload Too Large",414:"URI Too Long",415:"Unsupported Media Type",416:"Range Not Satisfiable",417:"Expectation Failed",418:"Im a teapot",421:"Misdirected Request",422:"Unprocessable Content",423:"Locked",424:"Failed Dependency",425:"Too Early",426:"Upgrade Required",428:"Precondition Required",429:"Too Many Requests",431:"Request Header Fields Too Large",451:"Unavailable For Legal Reasons",500:"Internal Server Error",501:"Not Implemented",502:"Bad Gateway",503:"Service Unavailable",504:"Gateway Timeout",505:"HTTP Version Not Supported",506:"Variant Also Negotiates",507:"Insufficient Storage",508:"Loop Detected",510:"Not Extended",511:"Network Authentication Required"},i.errors)[e.status];if(r)throw new d(i,e,r);if(!e.ok){let a=e.status??"unknown",n=e.statusText??"unknown",o=(()=>{try{return JSON.stringify(e.body,null,2)}catch{return}})();throw new d(i,e,`Generic Error: status: ${a}; status text: ${n}; body: ${o}`)}},s=(i,e,p)=>{let r=F(i,p),a=j(p),n=H(p);return U(i,p).pipe(g(o=>N(i,p,e,r,n,a,o)),g(async o=>{for(let x of i.interceptors.response._fns)o=await x(o);let u=z(o),B=M(o,p.responseHeader),b=u;return p.responseTransformer&&o.ok&&(b=await p.responseTransformer(u)),{url:r,ok:o.ok,status:o.status,statusText:o.statusText,body:B??b}}),k(o=>o.status?f({url:r,ok:o.ok,status:o.status,statusText:o.statusText,body:o.error??o.statusText}):m(()=>o)),R(o=>(W(p,o),o.body)),k(o=>m(()=>o)))};var G=class i{constructor(e){this.http=e}getApiV1Commandline(){return s(t,this.http,{method:"GET",url:"/api/v1/commandline"})}static \u0275fac=function(p){return new(p||i)(A(y))};static \u0275prov=c({token:i,factory:i.\u0275fac,providedIn:"root"})},E=class i{constructor(e){this.http=e}getApiV2ConnectionStrings(){return s(t,this.http,{method:"GET",url:"/api/v2/connection-strings"})}postApiV2ConnectionStrings(e){return s(t,this.http,{method:"POST",url:"/api/v2/connection-strings",body:e.requestBody,mediaType:"application/json"})}getApiV2ConnectionStringById(e){return s(t,this.http,{method:"GET",url:"/api/v2/connection-string/{id}",path:{id:e.id}})}putApiV2ConnectionStringById(e){return s(t,this.http,{method:"PUT",url:"/api/v2/connection-string/{id}",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}deleteApiV2ConnectionStringById(e){return s(t,this.http,{method:"DELETE",url:"/api/v2/connection-string/{id}",path:{id:e.id}})}postApiV2ConnectionStringByIdUpdateBackups(e){return s(t,this.http,{method:"POST",url:"/api/v2/connection-string/{id}/update-backups",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}static \u0275fac=function(p){return new(p||i)(A(y))};static \u0275prov=c({token:i,factory:i.\u0275fac,providedIn:"root"})},C=class i{constructor(e){this.http=e}postApiV1Commandline(e){return s(t,this.http,{method:"POST",url:"/api/v1/commandline",body:e.requestBody,mediaType:"application/json"})}getApiV1Acknowledgements(){return s(t,this.http,{method:"GET",url:"/api/v1/acknowledgements"})}postApiV1AuthRefresh(e={}){return s(t,this.http,{method:"POST",url:"/api/v1/auth/refresh",body:e.requestBody,mediaType:"application/json"})}postApiV1AuthSignin(e){return s(t,this.http,{method:"POST",url:"/api/v1/auth/signin",body:e.requestBody,mediaType:"application/json"})}postApiV1AuthLogin(e){return s(t,this.http,{method:"POST",url:"/api/v1/auth/login",body:e.requestBody,mediaType:"application/json"})}postApiV1AuthIssuesignintoken(e){return s(t,this.http,{method:"POST",url:"/api/v1/auth/issuesignintoken",body:e.requestBody,mediaType:"application/json"})}postApiV1AuthRefreshLogout(e={}){return s(t,this.http,{method:"POST",url:"/api/v1/auth/refresh/logout",body:e.requestBody,mediaType:"application/json"})}postApiV1AuthIssuetokenByOperation(e){return s(t,this.http,{method:"POST",url:"/api/v1/auth/issuetoken/{operation}",path:{operation:e.operation}})}postApiV1AuthIssueForeverToken(){return s(t,this.http,{method:"POST",url:"/api/v1/auth/issue-forever-token"})}postApiV1AuthStatus(){return s(t,this.http,{method:"POST",url:"/api/v1/auth/status"})}getApiV1Backupdefaults(){return s(t,this.http,{method:"GET",url:"/api/v1/backupdefaults"})}getApiV1Backups(e={}){return s(t,this.http,{method:"GET",url:"/api/v1/backups",query:{orderBy:e.orderBy}})}postApiV1Backups(e){return s(t,this.http,{method:"POST",url:"/api/v1/backups",query:{temporary:e.temporary,existingdb:e.existingdb},body:e.requestBody,mediaType:"application/json"})}postApiV1BackupsImport(e){return s(t,this.http,{method:"POST",url:"/api/v1/backups/import",body:e.requestBody,mediaType:"application/json"})}getApiV1BugreportByReportid(e){return s(t,this.http,{method:"GET",url:"/api/v1/bugreport/{reportid}",path:{reportid:e.reportid},query:{token:e.token}})}getApiV1Changelog(e={}){return s(t,this.http,{method:"GET",url:"/api/v1/changelog",query:{"from-update":e.fromUpdate}})}getApiV1CommandlineByRunid(e){return s(t,this.http,{method:"GET",url:"/api/v1/commandline/{runid}",path:{runid:e.runid},query:{offset:e.offset,pagesize:e.pagesize}})}postApiV1CommandlineByRunidAbort(e){return s(t,this.http,{method:"POST",url:"/api/v1/commandline/{runid}/abort",path:{runid:e.runid}})}postApiV1Filesystem(e){return s(t,this.http,{method:"POST",url:"/api/v1/filesystem",query:{onlyFolders:e.onlyFolders,showHidden:e.showHidden},body:e.requestBody,mediaType:"application/json"})}postApiV1FilesystemValidate(e){return s(t,this.http,{method:"POST",url:"/api/v1/filesystem/validate",body:e.requestBody,mediaType:"application/json"})}getApiV1Licenses(){return s(t,this.http,{method:"GET",url:"/api/v1/licenses"})}getApiV1LogdataPoll(e){return s(t,this.http,{method:"GET",url:"/api/v1/logdata/poll",query:{level:e.level,id:e.id,pagesize:e.pagesize}})}getApiV1LogdataLog(e={}){return s(t,this.http,{method:"GET",url:"/api/v1/logdata/log",query:{offset:e.offset,pagesize:e.pagesize}})}getApiV1LogdataCrashlog(){return s(t,this.http,{method:"GET",url:"/api/v1/logdata/crashlog"})}getApiV1NotificationById(e){return s(t,this.http,{method:"GET",url:"/api/v1/notification/{id}",path:{id:e.id}})}deleteApiV1NotificationById(e){return s(t,this.http,{method:"DELETE",url:"/api/v1/notification/{id}",path:{id:e.id}})}getApiV1Notifications(){return s(t,this.http,{method:"GET",url:"/api/v1/notifications"})}getApiV1Progressstate(){return s(t,this.http,{method:"GET",url:"/api/v1/progressstate"})}getApiV1RemotecontrolStatus(){return s(t,this.http,{method:"GET",url:"/api/v1/remotecontrol/status"})}postApiV1RemoteoperationDbpath(e){return s(t,this.http,{method:"POST",url:"/api/v1/remoteoperation/dbpath",body:e.requestBody,mediaType:"application/json"})}postApiV1RemoteoperationTest(e){return s(t,this.http,{method:"POST",url:"/api/v1/remoteoperation/test",query:{autocreate:e.autocreate,type:e.type},body:e.requestBody,mediaType:"application/json"})}postApiV1RemoteoperationCreate(e){return s(t,this.http,{method:"POST",url:"/api/v1/remoteoperation/create",body:e.requestBody,mediaType:"application/json"})}getApiV1Serversettings(){return s(t,this.http,{method:"GET",url:"/api/v1/serversettings"})}patchApiV1Serversettings(e){return s(t,this.http,{method:"PATCH",url:"/api/v1/serversettings",body:e.requestBody,mediaType:"application/json"})}getApiV1ServersettingByKey(e){return s(t,this.http,{method:"GET",url:"/api/v1/serversetting/{key}",path:{key:e.key}})}putApiV1ServersettingByKey(e){return s(t,this.http,{method:"PUT",url:"/api/v1/serversetting/{key}",path:{key:e.key},body:e.requestBody,mediaType:"application/json"})}getApiV1Serverstate(e={}){return s(t,this.http,{method:"GET",url:"/api/v1/serverstate",query:{lastEventId:e.lastEventId,longpoll:e.longpoll,duration:e.duration}})}postApiV1ServerstatePause(e={}){return s(t,this.http,{method:"POST",url:"/api/v1/serverstate/pause",query:{duration:e.duration,pauseTransfers:e.pauseTransfers}})}postApiV1ServerstateResume(){return s(t,this.http,{method:"POST",url:"/api/v1/serverstate/resume"})}getApiV1Systeminfo(){return s(t,this.http,{method:"GET",url:"/api/v1/systeminfo"})}getApiV1SysteminfoFiltergroups(){return s(t,this.http,{method:"GET",url:"/api/v1/systeminfo/filtergroups"})}getApiV1Tasks(){return s(t,this.http,{method:"GET",url:"/api/v1/tasks"})}getApiV1TaskByTaskid(e){return s(t,this.http,{method:"GET",url:"/api/v1/task/{taskid}",path:{taskid:e.taskid}})}postApiV1TaskByTaskidStop(e){return s(t,this.http,{method:"POST",url:"/api/v1/task/{taskid}/stop",path:{taskid:e.taskid}})}postApiV1TaskByTaskidAbort(e){return s(t,this.http,{method:"POST",url:"/api/v1/task/{taskid}/abort",path:{taskid:e.taskid}})}getApiV1Uisettings(){return s(t,this.http,{method:"GET",url:"/api/v1/uisettings"})}postApiV1Uisettings(e){return s(t,this.http,{method:"POST",url:"/api/v1/uisettings",body:e.requestBody,mediaType:"application/json"})}getApiV1UisettingsByScheme(e){return s(t,this.http,{method:"GET",url:"/api/v1/uisettings/{scheme}",path:{scheme:e.scheme}})}patchApiV1UisettingsByScheme(e){return s(t,this.http,{method:"PATCH",url:"/api/v1/uisettings/{scheme}",path:{scheme:e.scheme},body:e.requestBody,mediaType:"application/json"})}postApiV1UpdatesCheck(){return s(t,this.http,{method:"POST",url:"/api/v1/updates/check"})}postApiV1WebmoduleByModulekey(e){return s(t,this.http,{method:"POST",url:"/api/v1/webmodule/{modulekey}",path:{modulekey:e.modulekey},body:e.requestBody,mediaType:"application/json"})}getApiV1BackupById(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}",path:{id:e.id}})}putApiV1BackupById(e){return s(t,this.http,{method:"PUT",url:"/api/v1/backup/{id}",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}deleteApiV1BackupById(e){return s(t,this.http,{method:"DELETE",url:"/api/v1/backup/{id}",path:{id:e.id},query:{"delete-remote-files":e.deleteRemoteFiles,"delete-local-db":e.deleteLocalDb,force:e.force}})}getApiV1BackupByIdFiles(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/files",path:{id:e.id},query:{filter:e.filter,time:e.time,"all-versions":e.allVersions,"prefix-only":e.prefixOnly,"folder-contents":e.folderContents}})}getApiV1BackupByIdLog(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/log",path:{id:e.id},query:{offset:e.offset,pagesize:e.pagesize}})}getApiV1BackupByIdRemotelog(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/remotelog",path:{id:e.id},query:{offset:e.offset,pagesize:e.pagesize}})}getApiV1BackupByIdFilesets(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/filesets",path:{id:e.id},query:{"include-metadata":e.includeMetadata,"from-remote-only":e.fromRemoteOnly}})}getApiV1BackupByIdExportArgsonly(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/export-argsonly",path:{id:e.id},query:{"export-passwords":e.exportPasswords,passphrase:e.passphrase}})}getApiV1BackupByIdExportCmdline(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/export-cmdline",path:{id:e.id},query:{"export-passwords":e.exportPasswords,passphrase:e.passphrase}})}getApiV1BackupByIdExport(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/export",path:{id:e.id},query:{"export-passwords":e.exportPasswords,passphrase:e.passphrase,token:e.token}})}getApiV1BackupByIdIsdbusedelsewhere(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/isdbusedelsewhere",path:{id:e.id}})}getApiV1BackupByIdIsactive(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/isactive",path:{id:e.id}})}postApiV1BackupByIdDeletedb(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/deletedb",path:{id:e.id}})}postApiV1BackupByIdMovedb(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/movedb",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}postApiV1BackupByIdUpdatedb(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/updatedb",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}postApiV1BackupByIdRestore(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/restore",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}postApiV1BackupByIdCreatereport(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/createreport",path:{id:e.id}})}postApiV1BackupByIdRepair(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/repair",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}postApiV1BackupByIdRepairupdate(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/repairupdate",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}postApiV1BackupByIdVacuum(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/vacuum",path:{id:e.id}})}postApiV1BackupByIdVerify(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/verify",path:{id:e.id}})}postApiV1BackupByIdCompact(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/compact",path:{id:e.id}})}postApiV1BackupByIdStart(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/start",path:{id:e.id},query:{skipQueue:e.skipQueue}})}postApiV1BackupByIdRun(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/run",path:{id:e.id},query:{skipQueue:e.skipQueue}})}postApiV1BackupByIdReportRemoteSize(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/report-remote-size",path:{id:e.id}})}postApiV1BackupByIdCopytotemp(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/copytotemp",path:{id:e.id}})}postApiV1RemotecontrolEnable(){return s(t,this.http,{method:"POST",url:"/api/v1/remotecontrol/enable"})}postApiV1RemotecontrolDisable(){return s(t,this.http,{method:"POST",url:"/api/v1/remotecontrol/disable"})}deleteApiV1RemotecontrolRegistration(){return s(t,this.http,{method:"DELETE",url:"/api/v1/remotecontrol/registration"})}postApiV1RemotecontrolRegister(e){return s(t,this.http,{method:"POST",url:"/api/v1/remotecontrol/register",body:e.requestBody,mediaType:"application/json"})}deleteApiV1RemotecontrolRegister(){return s(t,this.http,{method:"DELETE",url:"/api/v1/remotecontrol/register"})}postApiV1RemotecontrolRegisterWait(){return s(t,this.http,{method:"POST",url:"/api/v1/remotecontrol/register/wait"})}postApiV2SystemTempDiskSpace(e){return s(t,this.http,{method:"POST",url:"/api/v2/system/temp-disk-space",body:e.requestBody,mediaType:"application/json"})}postApiV2BackupListFilesets(e){return s(t,this.http,{method:"POST",url:"/api/v2/backup/list-filesets",body:e.requestBody,mediaType:"application/json"})}postApiV2BackupListFolder(e){return s(t,this.http,{method:"POST",url:"/api/v2/backup/list-folder",body:e.requestBody,mediaType:"application/json"})}postApiV2BackupListVersions(e){return s(t,this.http,{method:"POST",url:"/api/v2/backup/list-versions",body:e.requestBody,mediaType:"application/json"})}postApiV2BackupSearch(e){return s(t,this.http,{method:"POST",url:"/api/v2/backup/search",body:e.requestBody,mediaType:"application/json"})}postApiV2DestinationTest(e){return s(t,this.http,{method:"POST",url:"/api/v2/destination/test",body:e.requestBody,mediaType:"application/json"})}static \u0275fac=function(p){return new(p||i)(A(y))};static \u0275prov=c({token:i,factory:i.\u0275fac,providedIn:"root"})},q=class i{constructor(e){this.http=e}getApiV1Webmodules(){return s(t,this.http,{method:"GET",url:"/api/v1/webmodules"})}static \u0275fac=function(p){return new(p||i)(A(y))};static \u0275prov=c({token:i,factory:i.\u0275fac,providedIn:"root"})};export{t as a,G as b,E as c,C as d,q as e};
|
|
1
|
+
import{a as O,d as y}from"./chunk-NBTTYKXH.js";import{K as g,U as c,Y as A,l as f,m,p as R,v as D,z as k}from"./chunk-ERITO7WM.js";import{a as l,b as I}from"./chunk-7CGTOI24.js";var P=class{_fns;constructor(){this._fns=[]}eject(e){let p=this._fns.indexOf(e);p!==-1&&(this._fns=[...this._fns.slice(0,p),...this._fns.slice(p+1)])}use(e){this._fns=[...this._fns,e]}},t={BASE:"",CREDENTIALS:"include",ENCODE_PATH:void 0,HEADERS:void 0,PASSWORD:void 0,TOKEN:void 0,USERNAME:void 0,VERSION:"1",WITH_CREDENTIALS:!1,interceptors:{response:new P}};var d=class extends Error{url;status;statusText;body;request;constructor(e,p,r){super(r),this.name="ApiError",this.url=p.url,this.status=p.status,this.statusText=p.statusText,this.body=p.body,this.request=e}};var h=i=>typeof i=="string",v=i=>h(i)&&i!=="",T=i=>i instanceof Blob,S=i=>i instanceof FormData,L=i=>{try{return btoa(i)}catch{return Buffer.from(i).toString("base64")}},w=i=>{let e=[],p=(a,n)=>{e.push(`${encodeURIComponent(a)}=${encodeURIComponent(String(n))}`)},r=(a,n)=>{n!=null&&(n instanceof Date?p(a,n.toISOString()):Array.isArray(n)?n.forEach(o=>r(a,o)):typeof n=="object"?Object.entries(n).forEach(([o,u])=>r(`${a}[${o}]`,u)):p(a,n))};return Object.entries(i).forEach(([a,n])=>r(a,n)),e.length?`?${e.join("&")}`:""},F=(i,e)=>{let p=i.ENCODE_PATH||encodeURI,r=e.url.replace("{api-version}",i.VERSION).replace(/{(.*?)}/g,(n,o)=>e.path?.hasOwnProperty(o)?p(String(e.path[o])):n),a=i.BASE+r;return e.query?a+w(e.query):a},j=i=>{if(i.formData){let e=new FormData,p=(r,a)=>{h(a)||T(a)?e.append(r,a):e.append(r,JSON.stringify(a))};return Object.entries(i.formData).filter(([,r])=>r!=null).forEach(([r,a])=>{Array.isArray(a)?a.forEach(n=>p(r,n)):p(r,a)}),e}},V=async(i,e)=>typeof e=="function"?e(i):e,U=(i,e)=>D({token:V(e,i.TOKEN),username:V(e,i.USERNAME),password:V(e,i.PASSWORD),additionalHeaders:V(e,i.HEADERS)}).pipe(R(({token:p,username:r,password:a,additionalHeaders:n})=>{let o=Object.entries(l(l({Accept:"application/json"},n),e.headers)).filter(([,u])=>u!=null).reduce((u,[B,b])=>I(l({},u),{[B]:String(b)}),{});if(v(p)&&(o.Authorization=`Bearer ${p}`),v(r)&&v(a)){let u=L(`${r}:${a}`);o.Authorization=`Basic ${u}`}return e.body!==void 0&&(e.mediaType?o["Content-Type"]=e.mediaType:T(e.body)?o["Content-Type"]=e.body.type||"application/octet-stream":h(e.body)?o["Content-Type"]="text/plain":S(e.body)||(o["Content-Type"]="application/json")),new O(o)})),H=i=>{if(i.body)return i.mediaType?.includes("application/json")||i.mediaType?.includes("+json")?JSON.stringify(i.body):h(i.body)||T(i.body)||S(i.body)?i.body:JSON.stringify(i.body)},N=(i,e,p,r,a,n,o)=>p.request(e.method,r,{headers:o,body:a??n,withCredentials:i.WITH_CREDENTIALS,observe:"response"}),M=(i,e)=>{if(e){let p=i.headers.get(e);if(h(p))return p}},z=i=>{if(i.status!==204&&i.body!==null)return i.body},W=(i,e)=>{let r=l({400:"Bad Request",401:"Unauthorized",402:"Payment Required",403:"Forbidden",404:"Not Found",405:"Method Not Allowed",406:"Not Acceptable",407:"Proxy Authentication Required",408:"Request Timeout",409:"Conflict",410:"Gone",411:"Length Required",412:"Precondition Failed",413:"Payload Too Large",414:"URI Too Long",415:"Unsupported Media Type",416:"Range Not Satisfiable",417:"Expectation Failed",418:"Im a teapot",421:"Misdirected Request",422:"Unprocessable Content",423:"Locked",424:"Failed Dependency",425:"Too Early",426:"Upgrade Required",428:"Precondition Required",429:"Too Many Requests",431:"Request Header Fields Too Large",451:"Unavailable For Legal Reasons",500:"Internal Server Error",501:"Not Implemented",502:"Bad Gateway",503:"Service Unavailable",504:"Gateway Timeout",505:"HTTP Version Not Supported",506:"Variant Also Negotiates",507:"Insufficient Storage",508:"Loop Detected",510:"Not Extended",511:"Network Authentication Required"},i.errors)[e.status];if(r)throw new d(i,e,r);if(!e.ok){let a=e.status??"unknown",n=e.statusText??"unknown",o=(()=>{try{return JSON.stringify(e.body,null,2)}catch{return}})();throw new d(i,e,`Generic Error: status: ${a}; status text: ${n}; body: ${o}`)}},s=(i,e,p)=>{let r=F(i,p),a=j(p),n=H(p);return U(i,p).pipe(g(o=>N(i,p,e,r,n,a,o)),g(async o=>{for(let x of i.interceptors.response._fns)o=await x(o);let u=z(o),B=M(o,p.responseHeader),b=u;return p.responseTransformer&&o.ok&&(b=await p.responseTransformer(u)),{url:r,ok:o.ok,status:o.status,statusText:o.statusText,body:B??b}}),k(o=>o.status?f({url:r,ok:o.ok,status:o.status,statusText:o.statusText,body:o.error??o.statusText}):m(()=>o)),R(o=>(W(p,o),o.body)),k(o=>m(()=>o)))};var G=class i{constructor(e){this.http=e}getApiV1Commandline(){return s(t,this.http,{method:"GET",url:"/api/v1/commandline"})}static \u0275fac=function(p){return new(p||i)(A(y))};static \u0275prov=c({token:i,factory:i.\u0275fac,providedIn:"root"})},E=class i{constructor(e){this.http=e}getApiV2ConnectionStrings(){return s(t,this.http,{method:"GET",url:"/api/v2/connection-strings"})}postApiV2ConnectionStrings(e){return s(t,this.http,{method:"POST",url:"/api/v2/connection-strings",body:e.requestBody,mediaType:"application/json"})}getApiV2ConnectionStringById(e){return s(t,this.http,{method:"GET",url:"/api/v2/connection-string/{id}",path:{id:e.id}})}putApiV2ConnectionStringById(e){return s(t,this.http,{method:"PUT",url:"/api/v2/connection-string/{id}",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}deleteApiV2ConnectionStringById(e){return s(t,this.http,{method:"DELETE",url:"/api/v2/connection-string/{id}",path:{id:e.id}})}postApiV2ConnectionStringByIdUpdateBackups(e){return s(t,this.http,{method:"POST",url:"/api/v2/connection-string/{id}/update-backups",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}static \u0275fac=function(p){return new(p||i)(A(y))};static \u0275prov=c({token:i,factory:i.\u0275fac,providedIn:"root"})},C=class i{constructor(e){this.http=e}postApiV1Commandline(e){return s(t,this.http,{method:"POST",url:"/api/v1/commandline",body:e.requestBody,mediaType:"application/json"})}getApiV1Acknowledgements(){return s(t,this.http,{method:"GET",url:"/api/v1/acknowledgements"})}postApiV1AuthRefresh(e={}){return s(t,this.http,{method:"POST",url:"/api/v1/auth/refresh",body:e.requestBody,mediaType:"application/json"})}postApiV1AuthSignin(e){return s(t,this.http,{method:"POST",url:"/api/v1/auth/signin",body:e.requestBody,mediaType:"application/json"})}postApiV1AuthLogin(e){return s(t,this.http,{method:"POST",url:"/api/v1/auth/login",body:e.requestBody,mediaType:"application/json"})}postApiV1AuthIssuesignintoken(e){return s(t,this.http,{method:"POST",url:"/api/v1/auth/issuesignintoken",body:e.requestBody,mediaType:"application/json"})}postApiV1AuthRefreshLogout(e={}){return s(t,this.http,{method:"POST",url:"/api/v1/auth/refresh/logout",body:e.requestBody,mediaType:"application/json"})}postApiV1AuthIssuetokenByOperation(e){return s(t,this.http,{method:"POST",url:"/api/v1/auth/issuetoken/{operation}",path:{operation:e.operation}})}postApiV1AuthIssueForeverToken(){return s(t,this.http,{method:"POST",url:"/api/v1/auth/issue-forever-token"})}postApiV1AuthStatus(){return s(t,this.http,{method:"POST",url:"/api/v1/auth/status"})}getApiV1Backupdefaults(){return s(t,this.http,{method:"GET",url:"/api/v1/backupdefaults"})}getApiV1Backups(e={}){return s(t,this.http,{method:"GET",url:"/api/v1/backups",query:{orderBy:e.orderBy}})}postApiV1Backups(e){return s(t,this.http,{method:"POST",url:"/api/v1/backups",query:{temporary:e.temporary,existingdb:e.existingdb},body:e.requestBody,mediaType:"application/json"})}postApiV1BackupsImport(e){return s(t,this.http,{method:"POST",url:"/api/v1/backups/import",body:e.requestBody,mediaType:"application/json"})}getApiV1BugreportByReportid(e){return s(t,this.http,{method:"GET",url:"/api/v1/bugreport/{reportid}",path:{reportid:e.reportid},query:{token:e.token}})}getApiV1Changelog(e={}){return s(t,this.http,{method:"GET",url:"/api/v1/changelog",query:{"from-update":e.fromUpdate}})}getApiV1CommandlineByRunid(e){return s(t,this.http,{method:"GET",url:"/api/v1/commandline/{runid}",path:{runid:e.runid},query:{offset:e.offset,pagesize:e.pagesize}})}postApiV1CommandlineByRunidAbort(e){return s(t,this.http,{method:"POST",url:"/api/v1/commandline/{runid}/abort",path:{runid:e.runid}})}postApiV1Filesystem(e){return s(t,this.http,{method:"POST",url:"/api/v1/filesystem",query:{onlyFolders:e.onlyFolders,showHidden:e.showHidden},body:e.requestBody,mediaType:"application/json"})}postApiV1FilesystemValidate(e){return s(t,this.http,{method:"POST",url:"/api/v1/filesystem/validate",body:e.requestBody,mediaType:"application/json"})}getApiV1Licenses(){return s(t,this.http,{method:"GET",url:"/api/v1/licenses"})}getApiV1LogdataPoll(e){return s(t,this.http,{method:"GET",url:"/api/v1/logdata/poll",query:{level:e.level,id:e.id,pagesize:e.pagesize}})}getApiV1LogdataLog(e={}){return s(t,this.http,{method:"GET",url:"/api/v1/logdata/log",query:{offset:e.offset,pagesize:e.pagesize}})}getApiV1LogdataCrashlog(){return s(t,this.http,{method:"GET",url:"/api/v1/logdata/crashlog"})}getApiV1NotificationById(e){return s(t,this.http,{method:"GET",url:"/api/v1/notification/{id}",path:{id:e.id}})}deleteApiV1NotificationById(e){return s(t,this.http,{method:"DELETE",url:"/api/v1/notification/{id}",path:{id:e.id}})}getApiV1Notifications(){return s(t,this.http,{method:"GET",url:"/api/v1/notifications"})}getApiV1Progressstate(){return s(t,this.http,{method:"GET",url:"/api/v1/progressstate"})}getApiV1RemotecontrolStatus(){return s(t,this.http,{method:"GET",url:"/api/v1/remotecontrol/status"})}postApiV1RemoteoperationDbpath(e){return s(t,this.http,{method:"POST",url:"/api/v1/remoteoperation/dbpath",body:e.requestBody,mediaType:"application/json"})}postApiV1RemoteoperationTest(e){return s(t,this.http,{method:"POST",url:"/api/v1/remoteoperation/test",query:{autocreate:e.autocreate,type:e.type},body:e.requestBody,mediaType:"application/json"})}postApiV1RemoteoperationCreate(e){return s(t,this.http,{method:"POST",url:"/api/v1/remoteoperation/create",body:e.requestBody,mediaType:"application/json"})}getApiV1Serversettings(){return s(t,this.http,{method:"GET",url:"/api/v1/serversettings"})}patchApiV1Serversettings(e){return s(t,this.http,{method:"PATCH",url:"/api/v1/serversettings",body:e.requestBody,mediaType:"application/json"})}getApiV1ServersettingByKey(e){return s(t,this.http,{method:"GET",url:"/api/v1/serversetting/{key}",path:{key:e.key}})}putApiV1ServersettingByKey(e){return s(t,this.http,{method:"PUT",url:"/api/v1/serversetting/{key}",path:{key:e.key},body:e.requestBody,mediaType:"application/json"})}getApiV1Serverstate(e={}){return s(t,this.http,{method:"GET",url:"/api/v1/serverstate",query:{lastEventId:e.lastEventId,longpoll:e.longpoll,duration:e.duration}})}postApiV1ServerstatePause(e={}){return s(t,this.http,{method:"POST",url:"/api/v1/serverstate/pause",query:{duration:e.duration,pauseTransfers:e.pauseTransfers}})}postApiV1ServerstateResume(){return s(t,this.http,{method:"POST",url:"/api/v1/serverstate/resume"})}getApiV1Systeminfo(){return s(t,this.http,{method:"GET",url:"/api/v1/systeminfo"})}getApiV1SysteminfoFiltergroups(){return s(t,this.http,{method:"GET",url:"/api/v1/systeminfo/filtergroups"})}getApiV1Tasks(){return s(t,this.http,{method:"GET",url:"/api/v1/tasks"})}getApiV1TaskByTaskid(e){return s(t,this.http,{method:"GET",url:"/api/v1/task/{taskid}",path:{taskid:e.taskid}})}postApiV1TaskByTaskidStop(e){return s(t,this.http,{method:"POST",url:"/api/v1/task/{taskid}/stop",path:{taskid:e.taskid}})}postApiV1TaskByTaskidAbort(e){return s(t,this.http,{method:"POST",url:"/api/v1/task/{taskid}/abort",path:{taskid:e.taskid}})}getApiV1Uisettings(){return s(t,this.http,{method:"GET",url:"/api/v1/uisettings"})}postApiV1Uisettings(e){return s(t,this.http,{method:"POST",url:"/api/v1/uisettings",body:e.requestBody,mediaType:"application/json"})}getApiV1UisettingsByScheme(e){return s(t,this.http,{method:"GET",url:"/api/v1/uisettings/{scheme}",path:{scheme:e.scheme}})}patchApiV1UisettingsByScheme(e){return s(t,this.http,{method:"PATCH",url:"/api/v1/uisettings/{scheme}",path:{scheme:e.scheme},body:e.requestBody,mediaType:"application/json"})}postApiV1UpdatesCheck(){return s(t,this.http,{method:"POST",url:"/api/v1/updates/check"})}postApiV1WebmoduleByModulekey(e){return s(t,this.http,{method:"POST",url:"/api/v1/webmodule/{modulekey}",path:{modulekey:e.modulekey},body:e.requestBody,mediaType:"application/json"})}getApiV1BackupById(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}",path:{id:e.id}})}putApiV1BackupById(e){return s(t,this.http,{method:"PUT",url:"/api/v1/backup/{id}",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}deleteApiV1BackupById(e){return s(t,this.http,{method:"DELETE",url:"/api/v1/backup/{id}",path:{id:e.id},query:{"delete-remote-files":e.deleteRemoteFiles,"delete-local-db":e.deleteLocalDb,force:e.force}})}getApiV1BackupByIdFiles(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/files",path:{id:e.id},query:{filter:e.filter,time:e.time,"all-versions":e.allVersions,"prefix-only":e.prefixOnly,"folder-contents":e.folderContents}})}getApiV1BackupByIdLog(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/log",path:{id:e.id},query:{offset:e.offset,pagesize:e.pagesize}})}getApiV1BackupByIdRemotelog(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/remotelog",path:{id:e.id},query:{offset:e.offset,pagesize:e.pagesize}})}getApiV1BackupByIdFilesets(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/filesets",path:{id:e.id},query:{"include-metadata":e.includeMetadata,"from-remote-only":e.fromRemoteOnly}})}getApiV1BackupByIdExportArgsonly(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/export-argsonly",path:{id:e.id},query:{"export-passwords":e.exportPasswords,passphrase:e.passphrase}})}getApiV1BackupByIdExportCmdline(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/export-cmdline",path:{id:e.id},query:{"export-passwords":e.exportPasswords,passphrase:e.passphrase}})}getApiV1BackupByIdExport(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/export",path:{id:e.id},query:{"export-passwords":e.exportPasswords,passphrase:e.passphrase,token:e.token}})}getApiV1BackupByIdIsdbusedelsewhere(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/isdbusedelsewhere",path:{id:e.id}})}getApiV1BackupByIdIsactive(e){return s(t,this.http,{method:"GET",url:"/api/v1/backup/{id}/isactive",path:{id:e.id}})}postApiV1BackupByIdDeletedb(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/deletedb",path:{id:e.id}})}postApiV1BackupByIdMovedb(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/movedb",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}postApiV1BackupByIdUpdatedb(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/updatedb",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}postApiV1BackupByIdRestore(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/restore",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}postApiV1BackupByIdCreatereport(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/createreport",path:{id:e.id}})}postApiV1BackupByIdRepair(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/repair",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}postApiV1BackupByIdRepairupdate(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/repairupdate",path:{id:e.id},body:e.requestBody,mediaType:"application/json"})}postApiV1BackupByIdVacuum(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/vacuum",path:{id:e.id}})}postApiV1BackupByIdVerify(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/verify",path:{id:e.id}})}postApiV1BackupByIdCompact(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/compact",path:{id:e.id}})}postApiV1BackupByIdStart(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/start",path:{id:e.id},query:{skipQueue:e.skipQueue}})}postApiV1BackupByIdRun(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/run",path:{id:e.id},query:{skipQueue:e.skipQueue}})}postApiV1BackupByIdReportRemoteSize(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/report-remote-size",path:{id:e.id}})}postApiV1BackupByIdCopytotemp(e){return s(t,this.http,{method:"POST",url:"/api/v1/backup/{id}/copytotemp",path:{id:e.id}})}postApiV1RemotecontrolEnable(){return s(t,this.http,{method:"POST",url:"/api/v1/remotecontrol/enable"})}postApiV1RemotecontrolDisable(){return s(t,this.http,{method:"POST",url:"/api/v1/remotecontrol/disable"})}deleteApiV1RemotecontrolRegistration(){return s(t,this.http,{method:"DELETE",url:"/api/v1/remotecontrol/registration"})}postApiV1RemotecontrolRegister(e){return s(t,this.http,{method:"POST",url:"/api/v1/remotecontrol/register",body:e.requestBody,mediaType:"application/json"})}deleteApiV1RemotecontrolRegister(){return s(t,this.http,{method:"DELETE",url:"/api/v1/remotecontrol/register"})}postApiV1RemotecontrolRegisterWait(){return s(t,this.http,{method:"POST",url:"/api/v1/remotecontrol/register/wait"})}postApiV2SystemTempDiskSpace(e){return s(t,this.http,{method:"POST",url:"/api/v2/system/temp-disk-space",body:e.requestBody,mediaType:"application/json"})}postApiV2BackupListFilesets(e){return s(t,this.http,{method:"POST",url:"/api/v2/backup/list-filesets",body:e.requestBody,mediaType:"application/json"})}postApiV2BackupListFolder(e){return s(t,this.http,{method:"POST",url:"/api/v2/backup/list-folder",body:e.requestBody,mediaType:"application/json"})}postApiV2BackupListVersions(e){return s(t,this.http,{method:"POST",url:"/api/v2/backup/list-versions",body:e.requestBody,mediaType:"application/json"})}postApiV2BackupSearch(e){return s(t,this.http,{method:"POST",url:"/api/v2/backup/search",body:e.requestBody,mediaType:"application/json"})}postApiV2DestinationTest(e){return s(t,this.http,{method:"POST",url:"/api/v2/destination/test",body:e.requestBody,mediaType:"application/json"})}static \u0275fac=function(p){return new(p||i)(A(y))};static \u0275prov=c({token:i,factory:i.\u0275fac,providedIn:"root"})},q=class i{constructor(e){this.http=e}getApiV1Webmodules(){return s(t,this.http,{method:"GET",url:"/api/v1/webmodules"})}static \u0275fac=function(p){return new(p||i)(A(y))};static \u0275prov=c({token:i,factory:i.\u0275fac,providedIn:"root"})};export{t as a,G as b,E as c,C as d,q as e};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as _e}from"./chunk-JW6W3ER7.js";import"./chunk-W4HWOC3K.js";import"./chunk-JKIZ6U22.js";import"./chunk-4QE3MT56.js";import"./chunk-I2HYK2BL.js";import{a as se}from"./chunk-B35WNLRM.js";import"./chunk-SLS3DCJP.js";import"./chunk-SUY5AQLW.js";import"./chunk-6Q6SSTBK.js";import"./chunk-I4XRVBRQ.js";import"./chunk-HA7XREWO.js";import"./chunk-X64LSE6Y.js";import{a as b}from"./chunk-RFB5A3B7.js";import"./chunk-AZJ2P3YU.js";import"./chunk-3SSB4QCJ.js";import{a as le,b as m}from"./chunk-AYOFR344.js";import"./chunk-UUQWSINE.js";import"./chunk-BEXYTIOL.js";import"./chunk-LO5YNFFR.js";import{B as ae,H as ie,Y as ne,c as Q,e as Y,i as Z,s as x,v as ee,z as te}from"./chunk-YCLTQEU6.js";import{d as oe}from"./chunk-2LSZ2I43.js";import{b as q,e as j}from"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Ab as d,B as G,Bb as n,C as g,Cb as i,D as L,Db as c,E as p,Pc as E,Ra as _,Rb as u,Sb as h,Tb as A,Ub as H,Vb as J,Xb as T,Z as F,eb as V,ic as C,kc as K,lc as D,oa as s,p as y,qa as P,qc as X,rc as z,sc as W,ub as w,vb as U}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";function re(r,t){r&1&&(n(0,"sh-icon",19),D(1,"spinner"),i())}function ce(r,t){r&1&&(n(0,"sh-icon",20),D(1,"check"),i())}function de(r,t){r&1&&(n(0,"sh-icon",21),D(1,"warning"),i()),r&2&&d("shTooltip","File not found")}function ue(r,t){let a=le(r).pipe(G(t),L());return m(a,{initialValue:r()})}var N=class r{#o=F(q);#s=F(se);#e=F(oe);#a=F(te);#t=s("");backupId=m(this.#o.params.pipe(y(t=>t.id)));activeBackup=E(()=>this.#s.backups().find(t=>t.Backup?.ID===this.backupId()));backupFilePath=s("");lastValidatedPath=s("");isValidatedPath=E(()=>this.lastValidatedPath()===this.backupFilePath());pathHasChanged=E(()=>this.backupFilePath()!==this.#t());isValidatingPath=s(!1);#i=ue(this.backupFilePath,500);#n=s(!1);isWaitingForValidation=E(()=>this.#i()!=this.backupFilePath()||this.isValidatingPath());backupFilePathEffect=P(()=>{let t=this.#i(),a=this.activeBackup(),e=this.#n();t!==""&&(this.isValidatingPath.set(!0),this.#e.postApiV1FilesystemValidate({requestBody:{path:t}}).pipe(g(1),p(()=>this.isValidatingPath.set(!1))).subscribe(()=>this.lastValidatedPath.set(t)))});isRestoring=s(!1);isRepairing=s(!1);isDeleting=s(!1);isSavingDbPath=s(!1);isSavingAndRepairing=s(!1);isMovingDb=s(!1);isCreatingBugReport=s(!1);createdReport=s(!1);activeBackupEffect=P(()=>{let t=this.activeBackup();if(!t)return;let a=t.Backup?.DBPath??"";this.backupFilePath.set(a),this.#t.set(a)});repairDatabase(){this.isRepairing.set(!0),this.#e.postApiV1BackupByIdRepair({id:this.backupId()}).pipe(g(1),p(()=>this.isRepairing.set(!1))).subscribe()}deleteDatabase(t=null){this.isValidatedPath()?this.#a.open(b,{data:{title:$localize`Confirm delete?`,message:$localize`Do you really want to delete the database for ${this.activeBackup()?.Backup?.Name}?`,confirmText:$localize`Delete database`,cancelText:$localize`Cancel`},closed:a=>{a&&this.doDeleteDatabase(t)}}):this.doDeleteDatabase(t)}doDeleteDatabase(t=null){this.isDeleting.set(!0),this.#e.postApiV1BackupByIdDeletedb({id:this.backupId()}).pipe(g(1),p(()=>this.isDeleting.set(!1))).subscribe(()=>{this.lastValidatedPath.set(""),t?.()})}restoreDatabase(){this.isValidatedPath()?this.deleteDatabase(()=>{this.doRepairDatabase()}):this.doRepairDatabase()}doRepairDatabase(){this.isRestoring.set(!0),this.#e.postApiV1BackupByIdRepair({id:this.backupId(),requestBody:{refresh_lock_info:!0}}).pipe(g(1),p(()=>this.isRestoring.set(!1))).subscribe()}resetDatabasePath(){this.backupFilePath.set(this.#t())}saveDatabasePath(t=null){this.isValidatedPath()?this.#a.open(b,{data:{title:$localize`Confirm reassign?`,message:$localize`The target database path already exists and may belong to another backup. Are you sure you want to assign this backup to an existing database?`,confirmText:$localize`Assign existing database`,cancelText:$localize`Cancel`},closed:a=>{a&&this.doSaveDatabasePath(t)}}):this.doSaveDatabasePath(t)}doSaveDatabasePath(t=null){this.isSavingDbPath.set(!0);let a=this.backupFilePath();this.#e.postApiV1BackupByIdUpdatedb({id:this.backupId(),requestBody:{path:a}}).pipe(p(()=>this.isSavingDbPath.set(!1))).subscribe(()=>{this.#t.set(a),t?.()})}saveAndRepairDatabasePath(){this.saveDatabasePath(()=>(this.isSavingAndRepairing.set(!0),this.#e.postApiV1BackupByIdRepair({id:this.backupId()}).pipe(g(1),p(()=>this.isSavingAndRepairing.set(!1))).subscribe()))}moveDatabasePath(){this.isMovingDb.set(!0);let t=this.backupFilePath();this.#e.postApiV1BackupByIdMovedb({id:this.backupId(),requestBody:{path:t}}).pipe(p(()=>this.isMovingDb.set(!1))).subscribe(()=>{this.#n.update(a=>!a),this.#t.set(t)})}createErrorReport(){this.isCreatingBugReport.set(!0),this.#e.postApiV1BackupByIdCreatereport({id:this.backupId()}).pipe(p(()=>this.isCreatingBugReport.set(!1))).subscribe({next:()=>{this.createdReport.set(!0),window.setTimeout(()=>this.createdReport.set(!1),3e3)}})}static \u0275fac=function(a){return new(a||r)};static \u0275cmp=V({type:r,selectors:[["app-database"]],decls:50,vars:21,consts:()=>{let t;t=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON: Back `;let a;a=$localize`Local database for ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let e;e=$localize` Each backup has a local database associated with it, which stores information about the remote backup on the local machine. This makes it faster to perform many operations, and reduces the amount of data that needs to be downloaded for each operation. `;let o;o=$localize`Maintenance`;let S;S=$localize` If the backup and the remote storage is out of sync, Duplicati will require that you perform a repair operation to synchronize the database. If the repair is unsuccessful, you can delete the local database and re-generate. The bug report button can be used to create a copy of the database with path information removed. This should only be used if a developer requests to investigate an issue with your database. `;let f;f=$localize`${"\uFFFD#19\uFFFD"}:START_TAG_SH_ICON:wrench${"\uFFFD/#19\uFFFD"}:CLOSE_TAG_SH_ICON: Repair `;let I;I=$localize`${"\uFFFD#22\uFFFD"}:START_TAG_SH_ICON:trash${"\uFFFD/#22\uFFFD"}:CLOSE_TAG_SH_ICON: Delete `;let M;M=$localize`${"\uFFFD#25\uFFFD"}:START_TAG_SH_ICON:clock-counter-clockwise${"\uFFFD/#25\uFFFD"}:CLOSE_TAG_SH_ICON: Recreate (delete and repair) `;let R;R=$localize`${"\uFFFD#28\uFFFD"}:START_TAG_SH_ICON:file-plus${"\uFFFD/#28\uFFFD"}:CLOSE_TAG_SH_ICON: Create bug report database `;let B;B=$localize`Placement`;let O;O=$localize`${"\uFFFD#40\uFFFD"}:START_TAG_SH_ICON:backspace${"\uFFFD/#40\uFFFD"}:CLOSE_TAG_SH_ICON: Reset `;let $;$=$localize`${"\uFFFD#43\uFFFD"}:START_TAG_SH_ICON:floppy-disk${"\uFFFD/#43\uFFFD"}:CLOSE_TAG_SH_ICON: Save `;let v;v=$localize`${"\uFFFD#46\uFFFD"}:START_TAG_SH_ICON:wrench${"\uFFFD/#46\uFFFD"}:CLOSE_TAG_SH_ICON: Save & Repair `;let k;return k=$localize`${"\uFFFD#49\uFFFD"}:START_TAG_SH_ICON:flow-arrow${"\uFFFD/#49\uFFFD"}:CLOSE_TAG_SH_ICON: Move existing database `,[t,a,e,o,S,f,I,M,R,B,O,$,v,k,[1,"back"],["type","button","shButton","","routerLink","/",1,"small"],[1,"actions","maintenance"],["shButton","",3,"click","disabled"],["type","text",3,"ngModelChange","ngModel"],["prefix","",1,"primary"],["prefix",""],["prefix","",3,"shTooltip"],[1,"actions","placement"]]},template:function(a,e){if(a&1&&(c(0,"app-status-bar"),n(1,"section")(2,"div",14)(3,"button",15),u(4,0),c(5,"sh-icon"),h(),i()(),n(6,"article")(7,"h1"),A(8,1),i(),n(9,"p"),A(10,2),i()(),n(11,"article")(12,"h2"),A(13,3),i(),n(14,"p"),A(15,4),i(),n(16,"div",16)(17,"button",17),T("click",function(){return e.repairDatabase()}),u(18,5),c(19,"sh-icon"),h(),i(),n(20,"button",17),T("click",function(){return e.deleteDatabase()}),u(21,6),c(22,"sh-icon"),h(),i(),n(23,"button",17),T("click",function(){return e.restoreDatabase()}),u(24,7),c(25,"sh-icon"),h(),i(),n(26,"button",17),T("click",function(){return e.createErrorReport()}),u(27,8),c(28,"sh-icon"),h(),i()()(),n(29,"article")(30,"h2"),A(31,9),i(),n(32,"sh-form-field")(33,"input",18),W("ngModelChange",function(S){return z(e.backupFilePath,S)||(e.backupFilePath=S),S}),i(),w(34,re,2,0,"sh-icon",19)(35,ce,2,0,"sh-icon",20)(36,de,2,1,"sh-icon",21),i(),n(37,"div",22)(38,"button",17),T("click",function(){return e.resetDatabasePath()}),u(39,10),c(40,"sh-icon"),h(),i(),n(41,"button",17),T("click",function(){return e.saveDatabasePath()}),u(42,11),c(43,"sh-icon"),h(),i(),n(44,"button",17),T("click",function(){return e.saveAndRepairDatabasePath()}),u(45,12),c(46,"sh-icon"),h(),i(),n(47,"button",17),T("click",function(){return e.moveDatabasePath()}),u(48,13),c(49,"sh-icon"),h(),i()()()()),a&2){let o;_(8),H((o=e.activeBackup())==null||o.Backup==null?null:o.Backup.Name),J(8),_(9),C("loading",e.isRepairing()),d("disabled",!e.isValidatedPath()||e.pathHasChanged()),_(3),C("loading",e.isDeleting()),d("disabled",!e.isValidatedPath()||e.pathHasChanged()),_(3),C("loading",e.isRestoring()),d("disabled",e.pathHasChanged()),_(3),C("loading",e.isCreatingBugReport()),d("disabled",e.isCreatingBugReport()||!e.isValidatedPath()||e.pathHasChanged()),_(6),K(e.isValidatedPath()?"success":"error"),_(),X("ngModel",e.backupFilePath),_(),U(e.isWaitingForValidation()?34:e.isValidatedPath()?35:36),_(4),d("disabled",!e.pathHasChanged()),_(3),d("disabled",!e.pathHasChanged()||e.isWaitingForValidation()),_(3),d("disabled",!e.pathHasChanged()||e.isWaitingForValidation()),_(3),d("disabled",!e.pathHasChanged()||e.isValidatedPath()||e.isWaitingForValidation())}},dependencies:[x,Q,Y,Z,_e,ae,ie,ee,ne,j],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2rem;padding:2rem}article[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}h1[_ngcontent-%COMP%]{font:var(--title-20)}h2[_ngcontent-%COMP%]{font:var(--title-30)}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}"],changeDetection:0})};export{N as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as F}from"./chunk-MAKVVEKB.js";import{a as te}from"./chunk-RFB5A3B7.js";import{e as ee}from"./chunk-LO5YNFFR.js";import{B as Q,L as Y,w as K,x as W,z as q}from"./chunk-YCLTQEU6.js";import{a as H,d as Z}from"./chunk-2LSZ2I43.js";import{b as U,d as j}from"./chunk-BMWZYMK6.js";import{Ab as m,Bb as a,Cb as l,Db as S,Hb as y,Ib as D,Kb as u,Oa as x,Pc as h,Ra as r,Rb as G,Sb as z,Tb as _,Vc as A,Xb as p,Z as d,Zb as s,ca as I,da as f,eb as E,kc as V,lc as P,mc as L,nc as J,oa as v,tc as X,ub as N,uc as B,vb as T,vc as g,yb as b,zb as k}from"./chunk-ERITO7WM.js";function ae(i,t){if(i&1&&(a(0,"div",11),P(1),l()),i&2){s();let e=g(0);r(),J(" ",e.Message," ")}}function re(i,t){if(i&1&&(a(0,"div"),G(1,1),S(2,"a",15),z(),l()),i&2){let e=s();r(2),m("href",e.downloadLink(),x)}}function le(i,t){if(i&1){let e=u();a(0,"button",14),p("click",function(){I(e);let n=s(),c=g(0);return f(n.doRepair(c.BackupID))}),_(1,2),l()}}function ce(i,t){if(i&1){let e=u();a(0,"button",14),p("click",function(){I(e);let n=s(),c=g(0);return f(n.doDownloadBugreport(c))}),_(1,3),l()}}function _e(i,t){if(i&1&&S(0,"sh-progress-bar",17),i&2){let e,o=s(2);m("value",(e=o.serverState())==null?null:e.UpdateDownloadProgress)}}function se(i,t){if(i&1){let e=u();a(0,"div",11),y(1),_(2,4),D(),a(3,"a",16),P(4),l(),N(5,_e,1,1,"sh-progress-bar",17),a(6,"button",14),p("click",function(){I(e);let n=s();return f(n.doShowUpdate())}),_(7,5),l()()}if(i&2){let e,o,n=s(),c=g(0);r(3),m("href",(e=n.serverState())==null?null:e.UpdateDownloadLink,x),r(),L(c.Message),r(),T(((o=n.serverState())==null?null:o.UpdaterState)==="Downloading"?5:-1)}}function de(i,t){if(i&1){let e=u();a(0,"button",14),p("click",function(){I(e);let n=s(),c=g(0);return f(n.doShowLog(c.BackupID))}),_(1,6),l()}}function Ne(i,t){if(i&1){let e=u();a(0,"button",14),p("click",function(){I(e);let n=s();return f(n.doShowLink("https://docs.duplicati.com/detailed-descriptions/the-server-database"))}),_(1,7),l()}}function Te(i,t){if(i&1){let e=u();a(0,"button",14),p("click",function(){I(e);let n=s();return f(n.doShowLink("https://docs.duplicati.com/detailed-descriptions/the-server-database"))}),_(1,8),l()}}var Ce={Error:"error",Warning:"warn",Information:"primary"},M=class i{#e=d(j);#a=d(U);#r=d(q);#t=d(W);#i=d(F);#n=d(Z);#l=d(ee);#o=v(null);serverState=this.#i.serverState;index=A.required();notification=A.required();downloadLink=h(()=>this.#o()||this.notification().DownloadLink||"");deleteNotificationByIndex(){this.#i.deleteNotification(this.index())}deleteAllNotifications(){this.#i.deleteAllNotifications()}getAlertType(t){return t&&Ce[t]||"primary"}doShowLog(t){this.#n.getApiV1BackupByIdIsactive({id:t}).subscribe({next:e=>{this.#e.navigate(["/backup/"+t+"/log"])},error:e=>{if(e.status===404){let o={title:$localize`Error`,message:$localize`The backup is missing, has it been deleted?`,confirmText:$localize`OK`,cancelText:null};parseInt(t)+""!=t&&(o={title:$localize`Error`,message:$localize`The backup was temporary and does not exist anymore, so the log data is lost`,confirmText:$localize`OK`,cancelText:null}),this.#r.open(te,{maxWidth:"550px",width:"100%",data:o})}else this.#t.error($localize`Failed to find backup: `+e.message)}})}doRepair(t){this.#n.postApiV1BackupByIdRepair({id:t}).subscribe({next:()=>{this.#t.success($localize`Backup repaired`),this.#e.navigate(["./"],{onSameUrlNavigation:"reload",relativeTo:this.#a})},error:e=>{this.#t.error($localize`Failed to repair backup: `+e.message)}})}doShowUpdate(){this.#e.navigate(["/about/changelog"])}doShowLink(t){window.open(t,"_blank")}doDownloadBugreport(t){let e=t.Action.slice(19);this.#n.postApiV1AuthIssuetokenByOperation({operation:"bugreport"}).subscribe({next:o=>{if(!o.Token){this.#t.error("Failed to get bug report URL: No token generated");return}let n=H.BASE||"",c=this.#l.xsrfQueryParam(),O=`${location.origin}${n}/api/v1/bugreport/${e}?token=${o.Token}${c?`&${c}`:""}`;t.DownloadLink=O,this.#o.set(O),this.triggerDownload(O)},error:o=>{this.#t.error(`Failed to get bug report URL: ${o.message}`)}})}triggerDownload(t){let e=document.createElement("a");e.href=t,e.download="",e.style.display="none",document.body.appendChild(e);try{e.click()}catch{}document.body.removeChild(e)}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=E({type:i,selectors:[["app-notification"]],inputs:{index:[1,"index"],notification:[1,"notification"]},decls:16,vars:12,consts:()=>{let t;t=$localize`Dismiss`;let e;e=$localize` If the backup file was not downloaded automatically, ${"\uFFFD#2\uFFFD"}:START_LINK:right click and choose "Save as …"${"\uFFFD/#2\uFFFD"}:CLOSE_LINK:`;let o;o=$localize`Repair`;let n;n=$localize`Download`;let c;c=$localize`New update found:`;let O;O=$localize`Show Update`;let $;$=$localize`Show Log`;let w;w=$localize` Show Help `;let R;return R=$localize` Show Help `,[t,e,o,n,c,O,$,w,R,["ship-alert-title",""],["ship-alert-content","",1,"content"],[1,"message"],[1,"actions"],["shButton","",1,"small","outlined"],["shButton","",1,"small","outlined",3,"click"],["target","_blank",3,"href"],[3,"href"],[3,"value"]]},template:function(e,o){if(e&1&&(X(0),a(1,"sh-alert")(2,"div",9),P(3),l(),a(4,"div",10),N(5,ae,2,1,"div",11),N(6,re,3,1,"div"),a(7,"div",12),N(8,le,2,0,"button",13),N(9,ce,2,0,"button",13),N(10,se,8,3,"div",11),N(11,de,2,0,"button",13),N(12,Ne,2,0,"button",13),N(13,Te,2,0,"button",13),a(14,"button",14),p("click",function(){return o.deleteNotificationByIndex()}),_(15,0),l()()()()),e&2){let n=B(o.notification());r(),V(o.getAlertType(n.Type)),r(2),L(n.Title),r(2),T(n.Action!=="update:new"&&n.Action!=="update:manual"?5:-1),r(),T(o.downloadLink()?6:-1),r(2),T(n.Message!=null&&n.Message.includes("please run repair")?8:-1),r(),T(n.Action!=null&&n.Action.startsWith("bug-report:created:")&&!o.downloadLink()?9:-1),r(),T(n.Action==="update:new"?10:-1),r(),T(n.Action==="backup:show-log"?11:-1),r(),T(n.Action==="config:issue:unencrypted-database"?12:-1),r(),T(n.Action==="config:issue:windows-folder-used"?13:-1)}},dependencies:[Y,Q,K],styles:["[_nghost-%COMP%]{display:block}.content[_ngcontent-%COMP%]{margin-top:.5rem;display:flex;flex-direction:column;gap:.5rem}.message[_ngcontent-%COMP%]{max-height:12.5rem;overflow:auto}"],changeDetection:0})};var pe=(i,t)=>t.ID;function Ie(i,t){if(i&1&&S(0,"app-notification",1),i&2){let e=t.$implicit,o=t.$index;m("index",o)("notification",e)}}function fe(i,t){i&1&&(a(0,"div",2)(1,"p"),_(2,0),l()())}var ie=class i{#e=d(F);notificationFilterPredicate=A();notifications=h(()=>{let t=this.notificationFilterPredicate()?.predicate,e=this.#e.notifications();return typeof t!="function"?e:e.filter(t)});static \u0275fac=function(e){return new(e||i)};static \u0275cmp=E({type:i,selectors:[["app-notifications"]],inputs:{notificationFilterPredicate:[1,"notificationFilterPredicate"]},decls:3,vars:1,consts:()=>{let t;return t=$localize`No more notifications`,[t,[3,"index","notification"],[1,"notification-list"]]},template:function(e,o){e&1&&b(0,Ie,1,2,"app-notification",1,pe,!1,fe,3,0,"div",2),e&2&&k(o.notifications())},dependencies:[M],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.actions[_ngcontent-%COMP%]{display:flex;gap:.25rem;justify-content:flex-end}.notification-list[_ngcontent-%COMP%]{padding:1rem;display:flex;flex-direction:column;gap:1rem;text-align:center}"],changeDetection:0})};export{M as a,ie as b};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as tt}from"./chunk-NBPZDFGF.js";import{k as Ze,m as et}from"./chunk-UGEDZCTM.js";import{a as re}from"./chunk-Q72Y55NB.js";import{a as Ke}from"./chunk-I4XRVBRQ.js";import{a as M}from"./chunk-RFB5A3B7.js";import{b as _e}from"./chunk-AYOFR344.js";import{b as Qe}from"./chunk-UUQWSINE.js";import{a as K}from"./chunk-BEXYTIOL.js";import{B as j,H as Xe,L as Ue,M as Ye,P as He,V as je,W as qe,b as Be,c as W,e as B,f as V,i as Ve,j as z,l as ze,p as J,q as X,r as U,s as Je,t as Y,v as H,z as se}from"./chunk-YCLTQEU6.js";import{d as q}from"./chunk-2LSZ2I43.js";import{b as P,d as I}from"./chunk-BMWZYMK6.js";import{ha as ne}from"./chunk-OQ6BKP5N.js";import{Ab as S,Bb as r,C as Q,Cb as a,Db as c,E as h,Ec as le,Fc as we,Gc as We,H as Me,Hb as b,Ib as A,K as De,Kb as w,L as ee,Pc as N,Ra as d,Rb as m,Sb as T,Tb as O,U as Le,Ub as $e,Vb as be,Xb as f,Z as p,Zb as C,ca as y,da as $,eb as k,g as Re,ic as Ae,jb as ye,lc as v,m as he,nc as ve,oa as u,oc as Ge,qa as x,qc as te,rc as oe,sc as ie,ub as g,v as ae,vb as E,w as Pe,yc as xe,z as Ie,zc as ke}from"./chunk-ERITO7WM.js";function lt(n,t){n&1&&(r(0,"p"),O(1,3),a())}function _t(n,t){n&1&&(r(0,"sh-form-field")(1,"label",11),O(2,4),a(),c(3,"input",12),a())}var ot=new U,st=()=>ot.group({passphrase:ot.control("")}),ue=class n{#e=p(q);#t=p(D);#n=p(I);#i=p(P);encryptionForm=this.#t.encryptionForm;creatingTemporaryBackup=u(!1);settings=u([]);hasEncryptedBackup=N(()=>{let t=this.#t.destinationTestSignal();return t==="testing"||typeof t=="string"?!0:t?.containsEncryptedBackupFiles??!0});showEncryptionField=u(!1);next(){let t=this.#t.destinationTargetUrl();if(!t)throw new Error("No target URL");this.creatingTemporaryBackup.set(!0);let e=this.encryptionForm.value?.passphrase??null,o=[];e?o.push({Name:"--passphrase",Value:e}):o.push({Name:"--no-encryption",Value:"true"}),this.settings().forEach(i=>{let s=i.Name?.trim();s&&s!=="--"&&(s.startsWith("--")||(s=`--${s}`),o.push({Name:s,Value:i.Value??""}))}),this.#e.postApiV1Backups({requestBody:{Backup:{TargetURL:t,Settings:o}},temporary:!0}).pipe(h(()=>this.creatingTemporaryBackup.set(!1))).subscribe({next:i=>{let s=i.ID;this.#n.navigate([`/restore-draft/${s}`])},error:i=>{console.error(i)}})}back(){this.#t.isFileRestore()?this.#n.navigate(["destination"],{relativeTo:this.#i.parent}):this.#t.exit()}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=k({type:n,selectors:[["app-restore-encryption"]],decls:14,vars:5,consts:()=>{let t;t=$localize`Advanced options`;let e;e=$localize`${"\uFFFD#10\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#10\uFFFD"}:CLOSE_TAG_SH_ICON: Back `;let o;o=$localize`${"\uFFFD#13\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#13\uFFFD"}:CLOSE_TAG_SH_ICON: Continue `;let i;i=$localize`The backup does not contain encrypted files.`;let s;s=$localize`Enter backup passphrase if defined.`;let l;return l=$localize`Password`,[t,e,o,i,l,[3,"submit","formGroup"],["title",""],[3,"optionsChange","options","hasFreeTextSettings"],[1,"form-actions"],["shButton","","type","button",3,"click"],["shButton","","type","submit",1,"raised","primary"],["for","password"],["type","password","id","password","autocomplete","disabled","placeholder",s,"formControlName","passphrase"]]},template:function(e,o){e&1&&(r(0,"form",5),f("submit",function(){return o.next()}),g(1,lt,2,0,"p"),g(2,_t,4,0,"sh-form-field"),r(3,"sh-toggle-card"),b(4,6),O(5,0),A(),r(6,"app-options-list",7),ie("optionsChange",function(s){return oe(o.settings,s)||(o.settings=s),s}),a()(),r(7,"div",8)(8,"button",9),f("click",function(){return o.back()}),m(9,1),c(10,"sh-icon"),T(),a(),r(11,"button",10),m(12,2),c(13,"sh-icon"),T(),a()()()),e&2&&(S("formGroup",o.encryptionForm),d(),E(o.hasEncryptedBackup()?-1:1),d(),E(o.hasEncryptedBackup()||o.showEncryptionField()?2:-1),d(4),te("options",o.settings),S("hasFreeTextSettings",!0))},dependencies:[Y,z,W,B,V,X,J,Xe,H,j,je,tt],styles:["[_nghost-%COMP%]{display:block}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}"],changeDetection:0})};var ut=()=>({standalone:!0});function ct(n,t){n&1&&c(0,"sh-progress-bar",8)}function pt(n,t){if(n&1&&(v(0),le(1,"bytes")),n&2){let e=C().$implicit;ve(" (",we(1,1,e.FileSizes),") ")}}function dt(n,t){n&1&&(r(0,"span",16),O(1,4),a())}function mt(n,t){if(n&1&&(r(0,"div",15),v(1),le(2,"date"),g(3,pt,2,3),g(4,dt,2,0,"span",16),a()),n&2){let e=t.$implicit;d(),Ge(" ",e.Version,": ",We(2,4,e.Time,"medium")," "),d(2),E(e.FileSizes?3:-1),d(),E(e.IsFullBackup===!1?4:-1)}}function Tt(n,t){n&1&&c(0,"sh-progress-bar",8)}function Ft(n,t){if(n&1){let e=w();r(0,"app-file-tree",17),f("hasExtendedData",function(i){y(e);let s=C(2);return $(s.extendedDataType.set(i))}),r(1,"label",18),O(2,5),a(),c(3,"input",19),a()}if(n&2){let e=C(2);S("rootPaths",e.rootPaths())("initialNodes",e.initialNodes())("backupSettings",e.backupSettings())("multiSelect",!0)("showFiles",!0)("loadExtendedData",!0)}}function St(n,t){if(n&1){let e=w();r(0,"sh-select",12),f("cleared",function(){y(e);let i=C();return $(i.abortLoading())}),r(1,"input",13),ie("ngModelChange",function(i){y(e);let s=C();return oe(s.selectOption,i)||(s.selectOption=i),$(i)}),a(),ye(2,mt,5,7,"ng-template"),a(),g(3,Tt,1,0,"sh-progress-bar",8),g(4,Ft,4,6,"app-file-tree",14)}if(n&2){let e=C();S("options",e.versionOptions())("isClearable",!1),d(),te("ngModel",e.selectOption),S("ngModelOptions",ke(6,ut)),d(2),E(e.isRepairing()||e.versionOptionsLoading()||e.loadingRootPath()?3:-1),d(),E(e.showFileTree()?4:-1)}}var pe=new U,rt=()=>pe.group({filesToRestore:pe.control(""),passphrase:pe.control(null)}),de=class n{#e=p(q);#t=p(D);#n=p(Qe);#i=p(K);#o=p(I);#s=p(P);#a=p(ne);#l=null;#_=null;#r=u([]);selectFilesForm=this.#t.selectFilesForm;selectFilesFormSignal=this.#t.selectFilesFormSignal;selectOption=this.#t.selectOption;backupId=this.#t.backupId;versionOptionsLoading=this.#t.versionOptionsLoading;versionOptions=this.#t.versionOptions;isFileRestore=this.#t.isFileRestore;extendedDataType=this.#t.extendedDataType;needsDatabaseRepair=N(()=>this.#t.backup()?.Backup?.IsTemporary??!0);showFileTree=u(!1);backupSettings=u(null);rootPaths=u([]);initialNodes=u([]);loadingRootPath=u(!1);isRepairing=N(()=>this.#r().length>0);loadedVersions=u({});loadingEffect=x(()=>{if(this.versionOptionsLoading())return;let e=this.versionOptions();if(e&&e?.length>0){let o=e[0].Version;this.selectOption.set(o.toString())}});backupSettingsEffect=x(()=>{let t=this.backupId(),e=this.selectOption(),o=this.isRepairing(),i=this.loadedVersions();if(!e||!t)return;let l=this.versionOptions()?.find(Z=>Z.Version===parseInt(e))?.Time??null;if(!l)return;let _=`${t}+${l}`,R=i[_];if(this.needsDatabaseRepair()&&(!R||o))return;let L={id:t+"",time:l};this.backupSettings.set(L),this.getRootPath(L)});repairEffect=x(()=>{if(!this.needsDatabaseRepair())return;let t=this.selectOption(),e=this.versionOptions();if(t){let o=e.find(l=>l.Version===parseInt(t));if(o===void 0)return;let i=this.backupId(),s=`${i}+${o.Time}`;if(this.#_===s||(this.#_=s,this.#r().includes(s)))return;this.#r.update(l=>[...l,s]),this.#e.postApiV1BackupByIdRepairupdate({id:i,requestBody:{only_paths:!0,time:o.Time}}).pipe(ee(this.abortLoading$),h(()=>{this.#_=null})).subscribe(l=>{let _=l.ID;this.#n.waitForTaskToComplete(_).pipe(Q(1)).subscribe(()=>{this.#r.update(R=>R.filter(L=>L!==s)),this.loadedVersions.update(R=>(R[s]=!0,R))})})}});getRootPath(t){let e={id:t.id+"",time:t.time,prefixOnly:!0,folderContents:!1},o=t.id+"";this.isRepairing()||this.#l===o||(this.#l=o,this.loadingRootPath.set(!0),this.showFileTree.set(!1),this.#i.hasV2ListOperations()?this.#e.postApiV2BackupListFolder({requestBody:{BackupId:t.id,Time:t.time,Paths:null,PageSize:0,Page:0,ReturnExtended:!0}}).pipe(ee(this.abortLoading$),h(()=>{this.showFileTree.set(!0),this.loadingRootPath.set(!1),this.#l=null})).subscribe({next:i=>{let s=(i.Data??[]).find(_=>_.Metadata&&_.Metadata.ExtType&&_.Metadata.ExtType.length>0);s&&this.extendedDataType.set(s.Metadata.ExtType);let l=(i.Data??[]).map(_=>_.Path??"");l.length>0?(this.initialNodes.set([]),this.rootPaths.set(l)):(this.initialNodes.set([]),this.rootPaths.set(["/"]))}}):this.#e.getApiV1BackupByIdFiles(e).pipe(ee(this.abortLoading$),h(()=>{this.showFileTree.set(!0),this.loadingRootPath.set(!1)})).subscribe({next:i=>{let s=i.Files.map(l=>l.Path??"");s.length>0?(this.initialNodes.set([]),this.rootPaths.set(s)):(this.initialNodes.set([]),this.rootPaths.set(["/"]))}}))}abortLoading$=new Re;abortLoading(){this.showFileTree.set(!1),this.loadingRootPath.set(!1),this.abortLoading$.next(!0)}displayFn(){let t=this.versionOptions();return e=>{if(!e)return"";let o=t?.find(i=>typeof i.Version=="number"&&i.Version.toString()===e);return o?`${o.Version}: ${this.#a.transform(o.Time,"medium")}`:""}}next(){this.#o.navigate(["options"],{relativeTo:this.#s.parent})}back(){this.#t.isFileRestore()?this.#o.navigate(["encryption"],{relativeTo:this.#s.parent}):this.#t.exit()}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=k({type:n,selectors:[["app-select-files"]],features:[xe([ne])],decls:13,vars:3,consts:()=>{let t;t=$localize`Select files`;let e;e=$localize`${"\uFFFD#9\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SH_ICON: ${"\uFFFD0\uFFFD"}:INTERPOLATION: `;let o;o=$localize`${"\uFFFD#12\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SH_ICON: Continue `;let i;i=$localize`Select an option...`;let s;s=$localize`(partial)`;let l;return l=$localize`Path`,[["formRef",""],t,e,o,s,l,[3,"submit","formGroup"],[1,"title-30"],[1,"indeterminate","primary"],[1,"form-actions"],["shButton","","type","button",3,"click"],["shButton","","type","submit",1,"raised","primary"],["value","Version",3,"cleared","options","isClearable"],["type","text","placeholder",i,3,"ngModelChange","ngModel","ngModelOptions"],[3,"rootPaths","initialNodes","backupSettings","multiSelect","showFiles","loadExtendedData"],[1,"custom-option"],[1,"partial"],[3,"hasExtendedData","rootPaths","initialNodes","backupSettings","multiSelect","showFiles","loadExtendedData"],["for","path"],["type","text","id","path","formControlName","filesToRestore"]]},template:function(e,o){e&1&&(r(0,"form",6,0),f("submit",function(){return o.next()}),r(2,"h3",7),O(3,1),a(),g(4,ct,1,0,"sh-progress-bar",8)(5,St,5,7),r(6,"div",9)(7,"button",10),f("click",function(){return o.back()}),m(8,2),c(9,"sh-icon"),T(),a(),r(10,"button",11),m(11,3),c(12,"sh-icon"),T(),a()()()),e&2&&(S("formGroup",o.selectFilesForm),d(4),E(o.versionOptionsLoading()?4:5),d(5),$e(o.isFileRestore()?"Back":"Exit"),be(8))},dependencies:[Je,z,W,B,V,Ve,Y,X,J,re,j,H,He,Ue,ne,Ke],styles:["[_nghost-%COMP%]{display:block}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}.partial[_ngcontent-%COMP%]{color:var(--base-9);font-style:italic}"],changeDetection:0})};var D=class n{#e=p(I);#t=p(P);#n=p(K);#i=p(se);#o=p(q);backupId=u(null);backup=u(null);destinationTargetUrl=u(null);destinationTestSignal=u(null);selectFilesForm=rt();optionsForm=at();encryptionForm=st();optionsFormSignal=_e(this.optionsForm.valueChanges);selectFilesFormSignal=_e(this.selectFilesForm.valueChanges);selectOption=u(null);versionOptionsLoading=u(!1);versionOptions=u([]);isSubmitting=u(!1);isFileRestore=u(!1);isFullWidthPage=u(!1);extendedDataType=u(null);alternateRestorePath=u(null);alternateRestorePathSourcePrefix=u(null);init(t,e=!1){this.backupId.set(t),this.isFileRestore.set(e),this.alternateRestorePath.set(null),this.extendedDataType.set(null),e&&this.#e.navigate(["/restore-from-files/destination"]),e||this.getBackup()}updateTargetUrl(t){this.destinationTargetUrl.set(t)}setAlternateRestorePath(t,e){this.alternateRestorePath.set(t),this.alternateRestorePathSourcePrefix.set(e)}submit(){this.isSubmitting.set(!0);let t=this.backupId();this.backup()?.Backup?.IsTemporary??!1?this.#o.postApiV1BackupByIdCopytotemp({id:this.backupId()??""}).subscribe({next:o=>{this.#s(o.ID??"")},error:o=>this.showErrorDialog($localize`An error occurred while copying the backup to a temporary location: ${o.message}`)}):this.#s(t??"")}showErrorDialog(t){this.#i.open(M,{data:{title:$localize`Error occured`,message:t,confirmText:$localize`OK`,cancelText:void 0},closed:e=>{}})}#s(t){let e=this.optionsForm.value,o=this.selectFilesForm.value,i=this.selectOption(),s=this.versionOptions()?.find(l=>l.Version===(i&&parseInt(i)));this.#o.postApiV1BackupByIdRestore({id:t??"",requestBody:{paths:o.filesToRestore?.split("\0").map(l=>l.endsWith("/")||l.endsWith("\\")?`${l}*`:l)??[],passphrase:o.passphrase??null,time:s?.Time,restore_path:this.alternateRestorePath()??e.restoreFromPath,overwrite:e.handleExisting==="overwrite",permissions:e.permissions,skip_metadata:!e.includeMetadata,source_prefix:this.alternateRestorePathSourcePrefix(),connection_string_id:null}}).pipe(h(()=>this.isSubmitting.set(!1))).subscribe({next:l=>{this.#e.navigate([`./${l.ID}`,"progress"],{relativeTo:this.#t})},error:l=>{console.error("restore error",l)}})}exit(){this.#i.open(M,{data:{title:$localize`Confirm exit?`,message:$localize`Are you sure you want to exit?`,confirmText:$localize`Yes`,cancelText:$localize`Cancel`},closed:t=>{t&&(this.#a(),this.#e.navigate(["/"]))}})}getVersionOptions(){this.versionOptions()}loadFilesetsWithRetryv2(t,e=2){return this.#o.postApiV2BackupListFilesets({requestBody:{BackupId:t}}).pipe(Ie(o=>{let i=o?.error?.body?.StatusCode??o?.error?.requestBody?.StatusCode;return i==="EncryptedStorageNoPassphrase"||i==="FolderMissing"||i==="EmptyRemoteFolder"||e===0?he(()=>o):Pe(1e3).pipe(De(()=>this.loadFilesetsWithRetryv2(t,e-1)))}))}getBackup(){let t=this.backupId();this.versionOptionsLoading.set(!0),this.#n.hasV2ListOperations()?ae([this.#o.getApiV1BackupById({id:t}),this.loadFilesetsWithRetryv2(t)]).pipe(Q(1),h(()=>this.versionOptionsLoading.set(!1))).subscribe({next:([e,o])=>{if(o.Error)throw new Error(o.Error);if(!(e.Backup?.IsTemporary??!0)&&e?.Backup?.DBPathExists===!1){this.#i.open(M,{data:{title:$localize`Missing Local Database`,message:$localize`The local database for this backup is missing. Please repair or recreate the local database before restoring.`,confirmText:$localize`OK`,cancelText:void 0},closed:s=>{this.#e.navigate(["/backup",t,"database"])}});return}this.versionOptions.set((o.Data??[]).map(s=>({Version:s.Version??-1,IsFullBackup:s.IsFullBackup??void 0,Time:s.Time??"<missing>",FileCount:s.FileCount??void 0,FileSizes:s.FileSizes??void 0}))),this.backup.set(e)},error:e=>{let o=e?.error?.body?.StatusCode??e?.error?.requestBody?.StatusCode,i=o==="EncryptedStorageNoPassphrase",s=o==="FolderMissing",l=o==="EmptyRemoteFolder",_=$localize`An error occurred while loading the backup filesets: ${e.message}`;i&&(_=$localize`The remote storage is encrypted. Please enter the passphrase to access the backup.`),s&&(_=$localize`The backup storage folder was not found.`),l&&(_=$localize`The backup storage folder does not contain any filesets.`),this.#i.open(M,{data:{title:$localize`Failed to load backup filesets`,message:_,confirmText:$localize`OK`,cancelText:void 0},closed:R=>{this.#e.navigate([i?"/restore-from-files/encryption":"/restore-from-files/destination"])}})}}):ae([this.#o.getApiV1BackupById({id:t}),this.#o.getApiV1BackupByIdFilesets({id:t}).pipe(Me(3))]).pipe(Q(1),h(()=>this.versionOptionsLoading.set(!1))).subscribe({next:([e,o])=>{this.versionOptions.set(o.map(i=>({Version:i.Version??-1,IsFullBackup:(i.IsFullBackup??1)==1,Time:i.Time??"<missing>",FileCount:i.FileCount??void 0,FileSizes:i.FileSizes??void 0}))),this.backup.set(e)}})}#a(){this.selectFilesForm.reset(),this.optionsForm.reset()}static \u0275fac=function(e){return new(e||n)};static \u0275prov=Le({token:n,factory:n.\u0275fac,providedIn:"root"})};function gt(n,t){if(n&1){let e=w();r(0,"sh-radio",27),m(1,6),c(2,"input",31),T(),a(),r(3,"sh-radio",27),m(4,7),r(5,"input",32),f("click",function(){y(e);let i=C(2);return $(i.chooseCustomRemoteDestination())}),a(),T(),a()}}function Et(n,t){if(n&1){let e=w();r(0,"sh-radio",27),m(1,8),c(2,"input",31),T(),a(),r(3,"sh-radio",27),m(4,9),r(5,"input",32),f("click",function(){y(e);let i=C(2);return $(i.chooseCustomRemoteDestination())}),a(),T(),a()}}function Ot(n,t){if(n&1&&(r(0,"app-file-tree",29)(1,"label",33),v(2,"Path"),a(),c(3,"input",34),a()),n&2){let e,o=C(2);S("disabled",((e=o.optionsFormSignal())==null?null:e.restoreFrom)!=="pickLocation")("enableCreateFolder",!0)}}function Ct(n,t){if(n&1&&(r(0,"app-file-tree",30)(1,"label",33),v(2,"Path"),a(),c(3,"input",34),a()),n&2){let e=C(2);S("customRemoteMode",e.extendedDataType())("backupId",e.backupId())("sourcePrefix",e.remoteCustomSourcePrefix())("destinationUrl",e.customDestinationUrl())}}function Nt(n,t){if(n&1&&(g(0,gt,6,0)(1,Et,6,0),r(2,"sh-radio",27),m(3,5),c(4,"input",28),T(),a(),g(5,Ot,4,2,"app-file-tree",29),g(6,Ct,4,4,"app-file-tree",30)),n&2){let e,o=C();E(o.extendedDataType()==="o365"?0:o.extendedDataType()==="gsuite"?1:-1),d(5),E(((e=o.optionsFormSignal())==null?null:e.restoreFrom)==="pickLocation"?5:-1),d(),E(o.showCustomRemoteRestoreTree()?6:-1)}}function ft(n,t){if(n&1&&(r(0,"sh-radio",27),m(1,10),c(2,"input",35),T(),a(),r(3,"sh-radio",27),m(4,11),c(5,"input",28),T(),a(),r(6,"app-file-tree",29)(7,"label",33),v(8,"Path"),a(),c(9,"input",34),a()),n&2){let e,o=C();d(6),S("disabled",((e=o.optionsFormSignal())==null?null:e.restoreFrom)!=="pickLocation")("enableCreateFolder",!0)}}function Rt(n,t){n&1&&(r(0,"app-toggle-card",22),b(1,23),O(2,12),A(),r(3,"sh-toggle",27),m(4,13),c(5,"input",36),T(),a()()),n&2&&S("disableToggle",!0)}function ht(n,t){n&1&&(r(0,"app-toggle-card",22),b(1,23),O(2,14),A(),r(3,"sh-radio",27),m(4,15),c(5,"input",37),T(),a(),r(6,"sh-radio",27),m(7,16),c(8,"input",38),T(),a()(),r(9,"app-toggle-card"),b(10,23),O(11,17),A(),r(12,"sh-toggle",39),m(13,18),c(14,"input",40),T(),a(),r(15,"sh-toggle",39),m(16,19),c(17,"input",41),T(),a()()),n&2&&S("disableToggle",!0)}var G=new U,at=()=>G.group({restoreFrom:G.control("original"),restoreFromPath:G.control(""),handleExisting:G.control("saveTimestamp"),permissions:G.control(!1),includeMetadata:G.control(!0),customRemoteIgnoreExisting:G.control(!1)}),me=class n{#e=p(D);#t=p(I);#n=p(P);#i=p(K);#o=p(se);optionsForm=this.#e.optionsForm;optionsFormSignal=this.#e.optionsFormSignal;isSubmitting=this.#e.isSubmitting;extendedData=this.#e.extendedDataType;remoteCustomTargetUrl=u(null);backupId=N(()=>this.#e.backup()?.Backup?.ID??null);extendedDataType=N(()=>{let t=this.#e.extendedDataType();return t==="o365"?"o365":t==="gsuite"?"gsuite":null});remoteCustomSourceEntry=N(()=>this.#e.backup()?.Backup?.Sources?.filter(t=>t.startsWith("@")&&(t.includes("|office365://")||t.includes("|googleworkspace://")))[0]??null);remoteCustomSourceUrl=N(()=>this.remoteCustomSourceEntry()?.split("|")[1]??null);remoteCustomSourcePrefix=N(()=>this.remoteCustomSourceEntry()?.split("|")[0]??null);customDestinationUrl=N(()=>{let t=this.optionsFormSignal()?.restoreFrom,e=this.extendedDataType()!==null;return t==="same-custom"&&e?this.remoteCustomSourceUrl():t==="other-custom"&&e?this.remoteCustomTargetUrl():null});showCustomRemoteRestoreTree=N(()=>!!(this.optionsFormSignal()?.restoreFrom==="same-custom"&&this.customDestinationUrl()&&this.backupId()||this.optionsFormSignal()?.restoreFrom==="other-custom"&&this.customDestinationUrl()));isCustomRemoteRestore=N(()=>{let t=this.optionsFormSignal()?.restoreFrom;return t==="same-custom"||t==="other-custom"});chooseCustomRemoteDestination(){let t=this.extendedDataType()==="o365"?"office365://":"googleworkspace://";return this.#o.open(et,{maxWidth:"700px",maxHeight:"80vh",width:"100%",closeOnOutsideClick:!1,data:{targetUrlModel:this.remoteCustomTargetUrl()||this.remoteCustomSourceUrl()||t,moduleType:"RestoreDestinationProvider",askToCreate:!0,expectedResult:"any",suppressErrorDialogs:!0,backupId:this.backupId(),sourcePrefix:this.remoteCustomSourcePrefix()}}).closed.subscribe(o=>{o&&(this.remoteCustomTargetUrl.set(o),this.optionsForm.controls.restoreFrom.setValue("other-custom"))}),!1}#s=x(()=>{let t=this.optionsFormSignal()?.restoreFrom;this.extendedDataType()!=null&&(t==="original"||t===void 0)&&(this.optionsForm.controls.restoreFrom.setValue("pickLocation"),this.optionsForm.controls.handleExisting.setValue("overwrite")),this.extendedDataType()==null&&(t==="same-custom"||t==="other-custom")&&(this.optionsForm.controls.restoreFrom.setValue("original"),this.optionsForm.controls.handleExisting.setValue("saveTimestamp"))});goBack(){this.#t.navigate(["select-files"],{relativeTo:this.#n.parent})}submit(){let t=this.#e.selectFilesFormSignal()?.filesToRestore??[];if(t.length>0&&this.optionsFormSignal()?.restoreFrom=="original"&&(t[0].includes("/")?"/":"\\")!==this.#i.systemInfo()?.DirectorySeparator){this.#o.open(M,{data:{title:$localize`Confirm target folder`,message:$localize`This backup was created on another operating system. Restoring files without specifying a destination folder can cause files to be restored in unexpected places. Are you sure you want to continue without choosing a destination folder?`,confirmText:$localize`Yes`,cancelText:$localize`Cancel`},closed:i=>{i&&this.#e.submit()}});return}if(this.optionsFormSignal()?.restoreFrom==="same-custom"||this.optionsFormSignal()?.restoreFrom==="other-custom"){let o=this.optionsFormSignal()?.restoreFromPath;if(o&&o.startsWith("/")&&(o=o.substring(1)),!o||o.trim()===""){this.#o.open(M,{data:{title:$localize`No path specified`,message:this.extendedDataType()==="gsuite"?$localize`Please choose a path to restore to in the Google Workspace account.`:$localize`Please choose a path to restore to in the Office 365 tenant.`,confirmText:$localize`OK`,cancelText:void 0}});return}let i=this.optionsFormSignal()?.customRemoteIgnoreExisting,s=this.customDestinationUrl()?.substring(this.customDestinationUrl().indexOf("?")),l=this.extendedDataType()==="gsuite"?`@googleworkspace://${encodeURIComponent(o)}${s}&google-ignore-existing=${i?"true":"false"}`:`@office365://${encodeURIComponent(o)}${s}&office365-ignore-existing=${i?"true":"false"}`;this.#e.setAlternateRestorePath(l,this.remoteCustomSourcePrefix()),this.optionsForm.controls.includeMetadata.setValue(!0),this.optionsForm.controls.permissions.setValue(!0)}else this.#e.setAlternateRestorePath(null,null);this.#e.submit()}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=k({type:n,selectors:[["app-advanced-options-settings"]],decls:18,vars:6,consts:()=>{let t;t=$localize`Restore options`;let e;e=$localize`Where do you want to restore files to?`;let o;o=$localize`${"\uFFFD#14\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#14\uFFFD"}:CLOSE_TAG_SH_ICON: Go back `;let i;i=$localize`${"\uFFFD#17\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#17\uFFFD"}:CLOSE_TAG_SH_ICON: Submit `;let s;s=$localize` Local file system ${"\uFFFD#4\uFFFD\uFFFD/#4\uFFFD"}:TAG_INPUT:`;let l;l=$localize` Same Office 365 Tenant ${"\uFFFD#2\uFFFD\uFFFD/#2\uFFFD"}:TAG_INPUT:`;let _;_=$localize` Different Office 365 Tenant ${"\uFFFD#5\uFFFD\uFFFD/#5\uFFFD"}:TAG_INPUT:`;let R;R=$localize` Same Google Workspace Account ${"\uFFFD#2\uFFFD\uFFFD/#2\uFFFD"}:TAG_INPUT:`;let L;L=$localize` Different Google Workspace Account ${"\uFFFD#5\uFFFD\uFFFD/#5\uFFFD"}:TAG_INPUT:`;let Z;Z=$localize` Original location ${"\uFFFD#2\uFFFD\uFFFD/#2\uFFFD"}:TAG_INPUT:`;let Te;Te=$localize` Pick location ${"\uFFFD#5\uFFFD\uFFFD/#5\uFFFD"}:TAG_INPUT:`;let Fe;Fe=$localize`Restore settings`;let Se;Se=$localize` Ignore existing resources in the destination ${"\uFFFD#5\uFFFD\uFFFD/#5\uFFFD"}:TAG_INPUT:`;let ge;ge=$localize`How do you want to handle existing files?`;let Ee;Ee=$localize` Overwrite ${"\uFFFD#5\uFFFD\uFFFD/#5\uFFFD"}:TAG_INPUT:`;let Oe;Oe=$localize` Save different versions with timestamp in file name ${"\uFFFD#8\uFFFD\uFFFD/#8\uFFFD"}:TAG_INPUT:`;let Ce;Ce=$localize`Metadata settings`;let Ne;Ne=$localize` Restore file metadata ${"\uFFFD#14\uFFFD\uFFFD/#14\uFFFD"}:TAG_INPUT:`;let fe;return fe=$localize` Restore read/write permissions ${"\uFFFD#17\uFFFD\uFFFD/#17\uFFFD"}:TAG_INPUT:`,[["formRef",""],t,e,o,i,s,l,_,R,L,Z,Te,Fe,Se,ge,Ee,Oe,Ce,Ne,fe,[3,"submit","formGroup"],[1,"title-30"],[3,"disableToggle"],["title",""],[1,"form-actions"],["shButton","","type","button",3,"click"],["shButton","","type","submit",1,"raised","primary"],[1,"raised","primary"],["type","radio","name","restoreFrom","value","pickLocation","formControlName","restoreFrom"],[3,"disabled","enableCreateFolder"],[3,"customRemoteMode","backupId","sourcePrefix","destinationUrl"],["type","radio","name","restoreFrom","value","same-custom","formControlName","restoreFrom"],["type","radio","name","restoreFrom","value","other-custom","formControlName","restoreFrom",3,"click"],["for","path"],["type","text","id","path","formControlName","restoreFromPath"],["type","radio","name","restoreFrom","value","original","formControlName","restoreFrom"],["type","checkbox","formControlName","customRemoteIgnoreExisting"],["type","radio","name","handleExisting","value","overwrite","formControlName","handleExisting"],["type","radio","name","handleExisting","value","saveTimestamp","formControlName","handleExisting"],[1,"primary","raised"],["type","checkbox","formControlName","includeMetadata"],["type","checkbox","formControlName","permissions"]]},template:function(e,o){e&1&&(r(0,"form",20,0),f("submit",function(){return o.submit()}),r(2,"h3",21),O(3,1),a(),r(4,"app-toggle-card",22),b(5,23),O(6,2),A(),g(7,Nt,7,3)(8,ft,10,2),a(),g(9,Rt,6,1,"app-toggle-card",22)(10,ht,18,1),r(11,"div",24)(12,"button",25),f("click",function(){return o.goBack()}),m(13,3),c(14,"sh-icon"),T(),a(),r(15,"button",26),m(16,4),c(17,"sh-icon"),T(),a()()()),e&2&&(S("formGroup",o.optionsForm),d(4),S("disableToggle",!0),d(3),E(o.extendedDataType()!==null?7:8),d(2),E(o.isCustomRemoteRestore()?9:10),d(6),Ae("loading",o.isSubmitting()))},dependencies:[Y,z,W,Be,ze,B,V,X,J,Ze,re,qe,Ye,j,H],styles:["[_nghost-%COMP%]{display:block}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between}"],changeDetection:0})};export{at as a,me as b,st as c,ue as d,rt as e,de as f,D as g};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{$ as ha,A as I,Aa as Ka,B as J,Ba as La,C as K,Ca as Ma,D as L,Da as Na,E as M,Ea as Oa,F as N,Fa as Pa,G as O,Ga as Qa,H as P,Ha as Ra,I as Q,Ia as Sa,J as R,Ja as Ta,K as S,L as T,M as U,N as V,O as W,P as X,Q as Y,R as Z,S as _,T as $,U as aa,V as ba,W as ca,X as da,Y as ea,Z as fa,_ as ga,a as i,aa as ia,b as j,ba as ja,c as k,ca as ka,d as l,da as la,e as m,ea as ma,f as n,fa as na,g as o,ga as oa,h as p,ha as pa,i as q,ia as qa,j as r,ja as ra,k as s,ka as sa,l as t,la as ta,m as u,ma as ua,n as v,na as va,o as w,oa as wa,p as x,pa as xa,q as y,qa as ya,r as z,ra as za,s as A,sa as Aa,t as B,ta as Da,u as C,ua as Ea,v as D,va as Fa,w as E,wa as Ga,x as F,xa as Ha,y as G,ya as Ia,z as H,za as Ja}from"./chunk-OQ6BKP5N.js";import{a as c,b as d,c as e,d as f,e as g,f as h,g as Ba,h as Ca}from"./chunk-VAQ435AR.js";import{Ba as b,ha as a}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";export{k as APP_BASE_HREF,ja as AsyncPipe,h as BrowserPlatformLocation,ya as CommonModule,wa as CurrencyPipe,oa as DATE_PIPE_DEFAULT_OPTIONS,na as DATE_PIPE_DEFAULT_TIMEZONE,a as DOCUMENT,pa as DatePipe,ua as DecimalPipe,s as FormStyle,u as FormatWidth,p as HashLocationStrategy,qa as I18nPluralPipe,ra as I18nSelectPipe,b as IMAGE_CONFIG,Ma as IMAGE_LOADER,sa as JsonPipe,ta as KeyValuePipe,g as LOCATION_INITIALIZED,o as Location,j as LocationStrategy,ka as LowerCasePipe,Y as NgClass,Z as NgComponentOutlet,$ as NgFor,$ as NgForOf,_ as NgForOfContext,aa as NgIf,ba as NgIfContext,X as NgLocaleLocalization,W as NgLocalization,Ta as NgOptimizedImage,fa as NgPlural,ga as NgPluralCase,ha as NgStyle,ca as NgSwitch,da as NgSwitchCase,ea as NgSwitchDefault,ia as NgTemplateOutlet,m as NoTrailingSlashPathLocationStrategy,q as NumberFormatStyle,v as NumberSymbol,Sa as PRECONNECT_CHECK_BLOCKLIST,l as PathLocationStrategy,va as PercentPipe,f as PlatformLocation,Aa as PlatformNavigation,r as Plural,xa as SlicePipe,la as TitleCasePipe,n as TrailingSlashPathLocationStrategy,t as TranslationWidth,ma as UpperCasePipe,Ja as VERSION,Ka as ViewportScroller,w as WeekDay,Ca as XhrFactory,T as formatCurrency,S as formatDate,V as formatNumber,U as formatPercent,Q as getCurrencySymbol,L as getLocaleCurrencyCode,K as getLocaleCurrencyName,J as getLocaleCurrencySymbol,E as getLocaleDateFormat,G as getLocaleDateTimeFormat,z as getLocaleDayNames,y as getLocaleDayPeriods,P as getLocaleDirection,B as getLocaleEraNames,N as getLocaleExtraDayPeriodRules,O as getLocaleExtraDayPeriods,C as getLocaleFirstDayOfWeek,x as getLocaleId,A as getLocaleMonthNames,I as getLocaleNumberFormat,H as getLocaleNumberSymbol,M as getLocalePluralCase,F as getLocaleTimeFormat,D as getLocaleWeekEndRange,R as getNumberOfCurrencyDigits,Ha as isPlatformBrowser,Ia as isPlatformServer,Na as provideCloudflareLoader,Oa as provideCloudinaryLoader,Pa as provideImageKitLoader,Qa as provideImgixLoader,Ra as provideNetlifyLoader,Ea as registerLocaleData,e as \u0275DomAdapter,Da as \u0275NavigationAdapterForLocation,La as \u0275NullViewportScroller,Fa as \u0275PLATFORM_BROWSER_ID,Ga as \u0275PLATFORM_SERVER_ID,za as \u0275PRECOMMIT_HANDLER_SUPPORTED,c as \u0275getDOM,i as \u0275normalizeQueryParams,Ba as \u0275parseCookieValue,d as \u0275setRootDomAdapter};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{b as j}from"./chunk-
|
|
1
|
+
import{b as j}from"./chunk-AYOFR344.js";import{B as X,v as U,y as W}from"./chunk-YCLTQEU6.js";import{d as z}from"./chunk-2LSZ2I43.js";import"./chunk-NBTTYKXH.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Ab as m,Bb as o,Cb as r,Db as u,Kb as C,Oa as R,Ra as a,Rb as A,Sb as y,Tb as w,Xb as S,Z as b,Zb as f,ca as p,da as _,eb as v,lc as s,mc as I,nc as h,oa as g,oc as B,p as E,qa as F,qc as $,rc as k,sc as G,ub as M,vb as N,wb as P,wc as V,yb as D,zb as x,zc as J}from"./chunk-ERITO7WM.js";import{a as T,b as O}from"./chunk-7CGTOI24.js";var q=()=>({maxWidth:"700px",width:"100%"});function H(l,t){if(l&1&&(o(0,"a",9)(1,"sh-icon"),s(2,"link"),r()()),l&2){let e=f().$implicit;m("href",V(e.Url),R)}}function K(l,t){if(l&1){let e=C();o(0,"div",2)(1,"h4"),s(2),M(3,H,3,2,"a",9),r(),o(4,"p"),s(5),u(6,"br"),o(7,"i"),s(8),r()(),o(9,"div",10)(10,"button",11),S("click",function(){let n=p(e).$implicit,c=f();return _(c.openLicense(n))}),A(11,1),u(12,"sh-icon"),y(),r()()()}if(l&2){let e=t.$implicit;a(2),B(" ",e.Title," - ",e.data==null?null:e.data.license," "),a(),N(e.Url?3:-1),a(2),h(" ",e.data==null?null:e.data.description," "),a(3),I(e.data==null?null:e.data.notes)}}var L=class l{#e=b(z);licenses=j(this.#e.getApiV1Licenses().pipe(E(t=>t.map(e=>O(T({},e),{data:e.Jsondata?JSON.parse(e.Jsondata):null})))));dialogIsOpen=g(!1);dialogLicense=g(null);#t=F(()=>{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
2
|
`),i="";for(let n=0;n<e.length;n++)i+=`<li>${e[n]}</li>`;return i}static \u0275fac=function(e){return new(e||l)};static \u0275cmp=v({type:l,selectors:[["app-libraries"]],decls:14,vars:5,consts:()=>{let t;t=$localize`Libraries`;let e;return e=$localize` Details ${"\uFFFD#12\uFFFD"}:START_TAG_SH_ICON:arrow-square-in${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SH_ICON:`,[t,e,[1,"license"],[3,"isOpenChange","isOpen","options"],["header",""],["content",""],[1,"license-dialog"],["footer",""],["shButton","","type","button",3,"click"],[3,"href"],[1,"actions"],["shButton","",3,"click"]]},template:function(e,i){if(e&1){let n=C();o(0,"h3"),w(1,0),r(),D(2,K,13,5,"div",2,P),o(4,"sh-dialog",3),G("isOpenChange",function(d){return p(n),k(i.dialogIsOpen,d)||(i.dialogIsOpen=d),_(d)}),o(5,"header",4)(6,"h3"),s(7),r()(),o(8,"div",5)(9,"div",6),s(10),r()(),o(11,"footer",7)(12,"button",8),S("click",function(){return p(n),i.dialogLicense.set(null),_(i.dialogIsOpen.set(!1))}),s(13,"Close"),r()()()}if(e&2){let n,c;a(2),x(i.licenses()),a(2),$("isOpen",i.dialogIsOpen),m("options",J(4,q)),a(3),I((n=i.dialogLicense())==null?null:n.Title);let d=((c=i.dialogLicense())==null?null:c.License)??"";a(3),h(" ",d," ")}},dependencies:[U,X,W],styles:["[_nghost-%COMP%]{display:block;padding:0 2.5rem}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-4);display:flex;flex-direction:column;align-items:flex-start;gap:.5rem}.license[_ngcontent-%COMP%]:first-of-type{border-top:1px solid var(--base-4)}.license[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;gap:.25rem;align-items:center}.license-dialog[_ngcontent-%COMP%]{background-color:var(--base-1);color:var(--base-12);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-4)}"],changeDetection:0})};export{L as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as d}from"./chunk-
|
|
1
|
+
import{b as d}from"./chunk-AYOFR344.js";import{a as u,b as E}from"./chunk-UUQWSINE.js";import{d as p}from"./chunk-2LSZ2I43.js";import{Pc as o,U as v,Z as s,oa as h,qa as l,z as g}from"./chunk-ERITO7WM.js";import{a as i}from"./chunk-7CGTOI24.js";var A="shown-welcome-page-v1",_="hide-console-connection-status",f="disable-console-control",C="disable-tray-icon-login",S="server-listen-interface",O="allowed-hostnames",b="server-passphrase",R="update-channel",T="startup-delay",D="usage-reporter-level",N="power-mode-provider",m=class n{#t=s(p);#r=s(u);#s=s(E);#n=d(this.#t.getApiV1Serversettings());#e=h(void 0);serverSettings=o(()=>this.#e()||this.#n());#o=l(()=>{let e=this.#r.serverSettings();e&&this.#e.set(e)});constructor(){this.#r.subscribe("serversettings")}isConsoleConnectionStatusHidden=o(()=>{let e=this.serverSettings();return e?e[_]==="True":!1});refreshServerSettings(){this.#s.getConnectionMethod()!=="websocket"&&this.#t.getApiV1Serversettings().subscribe({next:e=>{this.#e.set(e)}})}#i(e,t){var r=i({},e);for(let[a,c]of Object.entries(t))c===null?delete r[a]:r[a]=c;return r}patchServerSettings(e){let t=i({},this.serverSettings());return this.#e.set(this.#i(this.serverSettings()??{},e)),this.#t.patchApiV1Serversettings({requestBody:e}).pipe(g(r=>{throw this.#e.set(t),r}))}patchServerSetting(e,t){let r={};return r[e]=t,this.patchServerSettings(r)}setShownWelcomePage(){return this.patchServerSetting(A,"true")}setHideConsoleConnectionStatus(e){return this.patchServerSetting(_,e?"True":"False")}setDisableTrayIconLogin(e){return this.patchServerSetting(C,e?"True":"False")}setDisableConsoleControl(e){return this.patchServerSetting(f,e?"True":"False")}setRemoteAccessInterface(e){return this.patchServerSetting(S,e)}setRemoteAccessAllowedHostnames(e){var t={[O]:e};return this.serverSettings()?.[S]==="loopback"&&(t[S]="any"),this.patchServerSettings(t)}setRemoteAccessPassword(e){return this.patchServerSetting(b,e)}setUpdateChannel(e){return this.patchServerSetting(R,e)}setStartupDelay(e){return this.patchServerSetting(T,e)}setUsageReporterLevel(e){return this.patchServerSetting(D,e)}setPowerModeProvider(e){return this.patchServerSetting(N,e)}static \u0275fac=function(t){return new(t||n)};static \u0275prov=v({token:n,factory:n.\u0275fac,providedIn:"root"})};export{m as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as le}from"./chunk-B35WNLRM.js";import"./chunk-6Q6SSTBK.js";import{a as ae}from"./chunk-I4XRVBRQ.js";import{a as _e}from"./chunk-RFB5A3B7.js";import"./chunk-AZJ2P3YU.js";import{c as re}from"./chunk-AYOFR344.js";import"./chunk-UUQWSINE.js";import"./chunk-BEXYTIOL.js";import"./chunk-LO5YNFFR.js";import{B as ne,D as ie,b as H,e as Q,i as Y,s as Z,v as ee,z as te}from"./chunk-YCLTQEU6.js";import{d as oe}from"./chunk-2LSZ2I43.js";import{d as j,e as q}from"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Ab as f,Ac as X,Bb as i,Cb as o,E as K,Ec as z,Hc as V,Kb as N,Pc as M,Ra as r,Tb as c,Ub as A,Vb as L,Vc as W,Wb as F,Xb as $,Z as u,Zb as C,ca as P,da as T,eb as y,ic as x,l as k,lc as E,oa as p,p as U,qc as S,rc as D,sc as h,tc as G,ub as g,uc as w,vb as m,vc as v,z as I,zc as J}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";var ce=l=>["/backup",l,"export"],se=()=>["/"];function Ee(l,_){if(l&1){let e=N();i(0,"section")(1,"h4"),c(2,4),o(),i(3,"p"),c(4,5),o(),i(5,"sh-checkbox",11),E(6," Delete local database "),i(7,"input",12),h("ngModelChange",function(t){P(e);let a=C();return D(a.deleteLocalDb,t)||(a.deleteLocalDb=t),T(t)}),o()()()}if(l&2){let e=C();r(7),S("ngModel",e.deleteLocalDb)}}function ue(l,_){if(l&1){let e=N();i(0,"section")(1,"h4"),c(2,6),o(),i(3,"p"),c(4,7),z(5,"bytes"),o(),i(6,"sh-checkbox",11),E(7," Delete remote files "),i(8,"input",12),h("ngModelChange",function(t){P(e);let a=C();return D(a.deleteRemoteFiles,t)||(a.deleteRemoteFiles=t),T(t)}),o()()()}if(l&2){let e=C(),n=v(0),t=(n==null||n.Backup==null||n.Backup.Metadata==null?null:n.Backup.Metadata.TargetFilesSize)??0;r(5),A(e.fileCount())(e.fileCount())(V(5,4,t,!0,!0)),L(4),r(3),S("ngModel",e.deleteRemoteFiles)}}var B=class l{#t=u(oe);#n=u(te);#e=u(le);#i=u(j);id=W.required();backup=M(()=>this.#e.getBackupById(this.id()));noLocalDbResource=re({params:()=>({dbPath:this.backup()?.Backup?.DBPath}),stream:({params:_})=>this.#t.postApiV1FilesystemValidate({requestBody:{path:_.dbPath}}).pipe(U(()=>!0),I(()=>k(!1)))});fileCount=M(()=>parseInt(this.backup()?.Backup?.Metadata?.TargetFilesCount??"0",10));deleteLocalDb=p(!1);deleteRemoteFiles=p(!1);isDeleting=p(!1);deleteBackup(){let _=this.id(),e=this.deleteLocalDb(),n=this.deleteRemoteFiles();this.isDeleting.set(!0),this.#n.open(_e,{data:{title:$localize`Confirm delete`,message:$localize`Are you sure you want to delete this backup?`,confirmText:$localize`Delete backup`,cancelText:$localize`Cancel`},closed:t=>{t&&this.#e.deleteBackup({id:_,deleteLocalDb:e,deleteRemoteFiles:n}).pipe(K(()=>this.isDeleting.set(!1))).subscribe({next:()=>{this.#i.navigate(["/"])}})}})}static \u0275fac=function(e){return new(e||l)};static \u0275cmp=y({type:l,selectors:[["app-delete-backup"]],inputs:{id:[1,"id"]},decls:19,vars:11,consts:()=>{let _;_=$localize`Delete backup: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let e;e=$localize`Export configuration`;let n;n=$localize`If you want to use the backup later, you can export the configuration before deleting it.`;let t;t=$localize`Cancel`;let a;a=$localize`Delete local database`;let b;b=$localize` Each backup has a local database associated with it, which stores information about the remote backup on the local machine. When deleting a backup, you can also delete the local database without affecting the ability to restore the remote files. If you are using the local database for backups from the commandline, you should keep the database. `;let R;R=$localize`Delete remote files`;let d;d=$localize`{VAR_PLURAL, plural, =1 {1 file} other {{INTERPOLATION} files}}`,d=F(d,{INTERPOLATION:"\uFFFD1\uFFFD",VAR_PLURAL:"\uFFFD0\uFFFD"});let O;return O=$localize` Delete ${d}:ICU@@2159106180826349718: (${"\uFFFD2\uFFFD"}:INTERPOLATION_1:) from the remote storage? `,[_,e,n,t,a,b,R,O,["shButton","",3,"routerLink"],[1,"actions"],["shButton","",1,"raised","error",3,"click"],[1,"primary","raised"],["type","checkbox",3,"ngModelChange","ngModel"]]},template:function(e,n){if(e&1&&(G(0),i(1,"h3"),c(2,0),o(),g(3,Ee,8,1,"section"),i(4,"section")(5,"h4"),c(6,1),o(),i(7,"p"),c(8,2),o(),i(9,"button",8),E(10," Export configuration "),i(11,"sh-icon"),E(12,"caret-right"),o()()(),g(13,ue,9,8,"section"),i(14,"div",9)(15,"button",8),c(16,3),o(),i(17,"button",10),$("click",function(){return n.deleteBackup()}),E(18,"Delete backup"),o()()),e&2){let t=w(n.backup()),a=n.noLocalDbResource.value();r(2),A(t==null||t.Backup==null?null:t.Backup.Name),L(2),r(),m(a?3:-1),r(6),f("routerLink",X(8,ce,n.id())),r(4),m(a?13:-1),r(2),f("routerLink",J(10,se)),r(2),x("loading",n.isDeleting())}},dependencies:[ie,ne,ee,Z,H,Q,Y,q,ae],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;padding:2.5rem;max-width:43.75rem}section[_ngcontent-%COMP%]{padding:2rem 0;display:flex;align-items:flex-start;flex-direction:column}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0}h4[_ngcontent-%COMP%]{font:var(--paragraph-20);margin-bottom:.5rem}p[_ngcontent-%COMP%]{margin-bottom:1rem}.actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;gap:.5rem;padding:2rem 0}"],changeDetection:0})};export{B as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as u}from"./chunk-
|
|
1
|
+
import{a as u}from"./chunk-SUY5AQLW.js";import{Z as p,hb as m}from"./chunk-ERITO7WM.js";var c=class s{#n=p(u);transform(r,t=!1,...d){if(!r)return"";let n=/^\s*(?:(\d+)\.)?(\d{1,2}):(\d{2}):(\d{2})(?:\.\d+)?\s*$/.exec(r);if(!n)return"";let e=parseInt(n[1]??"0",10),i=parseInt(n[2],10),o=parseInt(n[3],10),a=parseInt(n[4],10);return t?`${e?`${e}d `:""}${i}h ${o}m ${a}s`:this.#n.duration({days:e,hours:i,minutes:o,seconds:a}).humanize()}static \u0275fac=function(t){return new(t||s)};static \u0275pipe=m({name:"durationFormat",type:s,pure:!0})};export{c as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as _}from"./chunk-
|
|
1
|
+
import{a as _}from"./chunk-3SSB4QCJ.js";import"./chunk-AYOFR344.js";import"./chunk-UUQWSINE.js";import"./chunk-BEXYTIOL.js";import"./chunk-LO5YNFFR.js";import"./chunk-YCLTQEU6.js";import"./chunk-2LSZ2I43.js";import"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import{ka as l}from"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Eb as n,Ec as g,Fb as i,Fc as d,Ra as a,Tb as p,Z as s,eb as S,lc as c,mc as m}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";var o=class r{#e=s(_);serverSettings=this.#e.serverSettings;static \u0275fac=function(e){return new(e||r)};static \u0275cmp=S({type:r,selectors:[["app-server-settings"]],decls:6,vars:3,consts:()=>{let t;return t=$localize`System settings`,[t]},template:function(e,E){e&1&&(n(0,"h3"),p(1,0),i(),n(2,"code")(3,"pre"),c(4),g(5,"json"),i()()),e&2&&(a(4),m(d(5,1,E.serverSettings())))},dependencies:[l],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;padding:0 2.5rem}h3[_ngcontent-%COMP%]{font:var(--title-30)}code[_ngcontent-%COMP%]{background:color-mix(in srgb,var(--base-8),#000 70%);color:#fff;padding:1rem 1.5rem;border-radius:var(--shape-3);overflow:auto;white-space:pre}"],changeDetection:0})};export{o as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as At}from"./chunk-5MKFV3IB.js";import"./chunk-7MPZ3MRD.js";import{a as $t}from"./chunk-CTQKCCGM.js";import{a as yt}from"./chunk-VPUFUCR3.js";import"./chunk-23UYU3M3.js";import"./chunk-GGW26MAG.js";import"./chunk-FJFREVRV.js";import"./chunk-OWBBT5WF.js";import"./chunk-6Q6SSTBK.js";import"./chunk-EG3PT3XW.js";import{a as ee}from"./chunk-O3GGVB2B.js";import"./chunk-OAAXQ2BE.js";import{a as ae}from"./chunk-7E5J43IH.js";import"./chunk-QY5UGQ3R.js";import{a as x}from"./chunk-3MS6SVET.js";import"./chunk-4VYR5E5I.js";import"./chunk-KLAJGS5T.js";import{a as Ft}from"./chunk-NGKFJLI2.js";import{a as Et,c as ut}from"./chunk-KUX6NGQU.js";import{B as D,E as mt,G as ft,H as Z,L as It,M as Pt,N as Mt,P as Ot,W as ht,Y as Rt,c as W,e as q,i as j,m as pt,s as K,t as Q,v as w,w as Y,z as Nt}from"./chunk-Y46QCSB5.js";import{d as Gt}from"./chunk-JJY6UOEY.js";import"./chunk-2K74TI2N.js";import"./chunk-G3FMV74P.js";import"./chunk-LU7RSOI6.js";import"./chunk-VLMNSWR3.js";import"./chunk-VKNFRCHQ.js";import{Ac as J,Bb as N,Cb as s,Db as o,E as F,Eb as m,Lb as P,Pa as _t,Pc as v,Sa as l,Sb as O,Tb as h,Ub as _,Vb as V,Vc as gt,Wb as U,Xb as B,Yb as d,Z as R,_b as S,a as st,b as at,c as lt,ca as E,da as u,fb as b,fc as ct,gc as dt,jc as I,kb as oe,lb as rt,mc as $,nc as H,oa as c,oc as se,qa as k,rc as A,sb as Tt,sc as y,tb as St,tc as L,vb as C,wb as g,xc as Ct}from"./chunk-QY4Y5NJB.js";import"./chunk-7CGTOI24.js";var Dt=["formRef"],xt=()=>[import("./chunk-JWPG4EWG.js").then(n=>n.OptionsListComponent)];function kt(n,t){n&1&&(s(0,"sh-alert",3),_(1,1),o())}function Jt(n,t){if(n&1){let e=P();s(0,"app-options-list",5),L("optionsChange",function(a){E(e);let T=S();return y(T.settings,a)||(T.settings=a),u(a)}),o()}if(n&2){let e=S();A("options",e.settings),N("hasFreeTextSettings",!0)}}var X=class n{#e=R(x);#n=R(Gt);formRef=gt.required("formRef");settings=c([]);isSubmitting=c(!1);isLoadingOptions=c(!0);saved=c(!1);lastRecievedServerSettings=c({});serverSettingsEffect=k(()=>{let t=this.#e.serverSettings();if(t===void 0)return;this.lastRecievedServerSettings.set(t),this.isLoadingOptions.set(!0);let e=Object.entries(t);e.forEach(([i,a],T)=>{if(i.startsWith("--")){let f=i.substring(2);this.settings.update(p=>(p.some(M=>M.Name===f||M.Name===i)||p.push({Name:i,Value:a}),p))}T===e.length-1&&this.isLoadingOptions.set(!1)})});submit(){this.isSubmitting.set(!0);let t=this.settings(),e=this.lastRecievedServerSettings(),i=t.map(p=>p.Name?.startsWith("--")?p.Name:`--${p.Name}`),T=Object.keys(e).filter(p=>p.startsWith("--")).filter(p=>!i.includes(p)),f=t.reduce((p,M)=>{let G=M.Name?.startsWith("--")?M.Name:`--${M.Name}`;return p[G]=M.Value,p},{});T.forEach(p=>{f[p]=null}),this.#n.patchApiV1Serversettings({requestBody:f}).pipe(F(()=>this.isSubmitting.set(!1))).subscribe({next:()=>{this.#e.refreshServerSettings(),this.saved.set(!0),setTimeout(()=>{this.saved.set(!1)},3e3)}})}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=b({type:n,selectors:[["app-advanced-options-settings"]],viewQuery:function(e,i){e&1&&ct(i.formRef,Dt,5),e&2&&dt()},decls:8,vars:4,consts:()=>{let t;t=$localize`${"\uFFFD#4\uFFFD"}:START_TAG_SH_ICON:floppy-disk${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_SH_ICON: Save settings `;let e;return e=$localize`Settings saved`,[t,e,[1,"actions"],[1,"success"],["shButton","","type","button",1,"raised","primary",3,"click"],[3,"optionsChange","options","hasFreeTextSettings"]]},template:function(e,i){e&1&&(s(0,"div",2),C(1,kt,2,0,"sh-alert",3),s(2,"button",4),d("click",function(){return i.submit()}),O(3,0),m(4,"sh-icon"),h(),o()(),rt(5,Jt,1,2),Tt(6,5,xt)),e&2&&(l(),g(i.saved()?1:-1),l(),I("loading",i.isSubmitting()),l(4),St(!i.isLoadingOptions()))},dependencies:[Q,D,w,Y],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:40.625rem;justify-self:flex-end}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;justify-content:flex-end;margin-bottom:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-wrap[_ngcontent-%COMP%]{display:grid;grid-template-columns:2fr 2.5rem;gap:.5rem;align-items:flex-end}.remote-volume-wrap[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.remote-volume-wrap[_ngcontent-%COMP%] p.warning[_ngcontent-%COMP%]{color:#7d7d00}.row-inputs[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.5rem}.row-inputs[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{flex:1 0}.advanced-option[_ngcontent-%COMP%]{display:grid;gap:.5rem;grid-template-columns:1fr 1fr 2.5rem;align-items:flex-end}"],changeDetection:0})};function zt(n,t){if(n&1){let e=P();s(0,"sh-form-field",12)(1,"input",13),L("ngModelChange",function(a){E(e);let T=S(2);return y(T.registerUrl,a)||(T.registerUrl=a),u(a)}),o()(),s(2,"button",14),d("click",function(){E(e);let a=S(2);return u(a.register())}),_(3,0),o()}if(n&2){let e=S(2);l(),A("ngModel",e.registerUrl)}}function Vt(n,t){if(n&1&&(s(0,"div",9)(1,"label"),_(2,1),o(),s(3,"a",15),$(4),o()()),n&2){let e=S(2);l(3),N("href",Ct(e.claimUrl()),_t),l(),H(e.claimUrl())}}function Ut(n,t){n&1&&(s(0,"div",9)(1,"label"),_(2,2),o()())}function Bt(n,t){if(n&1){let e=P();s(0,"button",14),d("click",function(){E(e);let a=S(2);return u(a.cancel())}),_(1,3),o()}}function Ht(n,t){if(n&1){let e=P();s(0,"button",14),d("click",function(){E(e);let a=S(2);return u(a.disable())}),_(1,4),o()}}function Wt(n,t){if(n&1){let e=P();s(0,"button",14),d("click",function(){E(e);let a=S(2);return u(a.enable())}),_(1,5),o(),s(2,"button",16),d("click",function(){E(e);let a=S(2);return u(a.delete())}),_(3,6),o()}}function qt(n,t){n&1&&(O(0,7,1),m(1,"sh-icon"),h())}function jt(n,t){n&1&&(O(0,7,2),m(1,"sh-icon"),h())}function Kt(n,t){if(n&1){let e=P();s(0,"sh-chip",17),d("click",function(){E(e);let a=S(2);return u(a.copyReportingUrl())}),O(1,7),C(2,qt,2,0,"sh-icon")(3,jt,2,0,"sh-icon"),h(),o()}if(n&2){let e=S(2);l(2),g(e.copiedReportingUrl()===!0?2:3)}}function Qt(n,t){if(n&1&&(s(0,"div",8),C(1,zt,4,1),C(2,Vt,5,3,"div",9),C(3,Ut,3,0,"div",9),C(4,Bt,2,0,"button",10),C(5,Ht,2,0,"button",10),C(6,Wt,4,0),C(7,Kt,4,1,"sh-chip",11),o()),n&2){let e=S();l(),g(e.state()==="inactive"?1:-1),l(),g(e.state()==="registered"?2:-1),l(),g(e.state()==="registering"?3:-1),l(),g(e.state()==="registering"||e.state()==="registeringfaulted"||e.state()==="registered"?4:-1),l(),g(e.state()==="connected"||e.state()==="connecting"?5:-1),l(),g(e.state()==="disabled"?6:-1),l(),g(e.additionalReportingUrl()!==""?7:-1)}}var te=class n{#e=R(ee);#n=R(x);state=this.#e.state;claimUrl=this.#e.claimUrl;registerUrl=this.#e.registerUrl;additionalReportingUrl=v(()=>{let t=this.#n.serverSettings();return this.#e.state()==="inactive"?"":t&&t["additional-report-url"]||""});copiedReportingUrl=c(!1);ngOnInit(){this.#e.refreshRemoteControlStatus()}cancel(){this.#e.cancelRemoteRegistration()}register(){this.#e.beginRemoteRegistration()}disable(){this.#e.disableRemoteControl()}enable(){this.#e.enableRemoteControl()}delete(){this.#e.deleteRemoteControl()}copyReportingUrl(){let t=this.additionalReportingUrl();t&&(this.copiedReportingUrl.set(!0),setTimeout(()=>this.copiedReportingUrl.set(!1),2e3),navigator.clipboard.writeText(t))}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=b({type:n,selectors:[["app-remote-control"]],decls:1,vars:1,consts:()=>{let t;t=$localize`Register on console`;let e;e=$localize`Machine is now registered, open this link to add it to your account:`;let i;i=$localize`Registering, please wait...`;let a;a=$localize`Cancel registration`;let T;T=$localize`Disable console connection`;let f;f=$localize`Enable console connection`;let p;p=$localize` Delete console connection setup `;let M;return M=$localize` Reporting configured by server ${"\uFFFD*2:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:check${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*2:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*3:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:copy${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*3:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,M=B(M),[t,e,i,a,T,f,p,M,[1,"field-row"],[1,"field-col"],["type","button","shButton","",1,"raised"],[1,"reporting-url","primary","simple"],["label","Registration URL","for","remoteControlRegisterUrl"],["type","text","sh-input","","id","remoteControlRegisterUrl","name","remoteControlRegisterUrl",3,"ngModelChange","ngModel"],["type","button","shButton","",1,"raised",3,"click"],["target","_blank",3,"href"],["type","button","shButton","",1,"raised","error",3,"click"],[1,"reporting-url","primary","simple",3,"click"]]},template:function(e,i){e&1&&C(0,Qt,8,7,"div",8),e&2&&g(i.state()!=="unknown"?0:-1)},dependencies:[K,W,q,j,Z,D,mt,w],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] button[_ngcontent-%COMP%]{white-space:nowrap}.field-row[_ngcontent-%COMP%]{display:flex;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] sh-form-field[_ngcontent-%COMP%], .field-row[_ngcontent-%COMP%] sh-select[_ngcontent-%COMP%]{flex:1 0}.reporting-url[_ngcontent-%COMP%]{cursor:pointer;-webkit-user-select:none;user-select:none;margin-top:.25rem}"],changeDetection:0})};function bt(...n){let t=c(...n);return Object.defineProperty(t,"value",{get:t.asReadonly(),set:t.set.bind(t)})}var ne=()=>({standalone:!0});function Yt(n,t){if(n&1&&(s(0,"label"),O(1,35),m(2,"sh-icon",85),h(),o()),n&2){let e=S(3);l(2),N("shTooltip",e.remoteControlTooltip())}}function Zt(n,t){if(n&1&&(s(0,"label"),O(1,36),m(2,"sh-icon",85),h(),o()),n&2){let e=S(3);l(2),N("shTooltip",e.remoteControlTooltip())}}function en(n,t){if(n&1&&(s(0,"label"),O(1,37),m(2,"sh-icon",85),h(),o()),n&2){let e=S(3);l(2),N("shTooltip",e.connectionStatusIndicatorTooltip())}}function tn(n,t){if(n&1&&(s(0,"label"),O(1,38),m(2,"sh-icon",85),h(),o()),n&2){let e=S(3);l(2),N("shTooltip",e.connectionStatusIndicatorTooltip())}}function nn(n,t){if(n&1){let e=P();s(0,"section")(1,"div",61)(2,"h3"),_(3,33),o(),s(4,"p"),_(5,34),o()(),s(6,"div",84)(7,"sh-toggle",73),d("click",function(){E(e);let a=S(2);return u(a.toggleConsoleControl())}),C(8,Yt,3,1,"label")(9,Zt,3,1,"label"),o(),s(10,"sh-toggle",73),d("click",function(){E(e);let a=S(2);return u(a.saveHideConsoleConnectionStatus())}),C(11,en,3,1,"label")(12,tn,3,1,"label"),o()()()}if(n&2){let e=S(2);l(7),I("active",!e.consoleControlDisabled()),l(),g(e.consoleControlDisabled()?8:9),l(2),I("active",!e.hideConsoleConnectionStatus()),l(),g(e.hideConsoleConnectionStatus()?11:12)}}function on(n,t){n&1&&(s(0,"label"),_(1,41),o())}function sn(n,t){n&1&&(s(0,"label"),_(1,42),o())}function an(n,t){if(n&1){let e=P();s(0,"section")(1,"div",61)(2,"h3"),_(3,39),o(),s(4,"p"),_(5,40),o()(),s(6,"div",62)(7,"sh-toggle",73),d("click",function(){E(e);let a=S(2);return u(a.saveHideConsoleConnectionStatus())}),C(8,on,2,0,"label")(9,sn,2,0,"label"),o()()()}if(n&2){let e=S(2);l(7),I("active",!e.hideConsoleConnectionStatus()),l(),g(e.hideConsoleConnectionStatus()?8:9)}}function ln(n,t){if(n&1&&(s(0,"section")(1,"div",61)(2,"h3"),_(3,32),o(),s(4,"p"),$(5),o()(),s(6,"div",62),m(7,"app-remote-control"),o()(),C(8,nn,13,6,"section")(9,an,10,3,"section")),n&2){let e=S();l(5),H(e.remoteControlStatus()),l(3),g(e.remoteControlState()!="inactive"?8:9)}}function _n(n,t){n&1&&(s(0,"sh-icon",90),$(1,"check"),o())}function rn(n,t){n&1&&(s(0,"sh-icon",91),$(1,"prohibit"),o())}function Tn(n,t){if(n&1){let e=P();s(0,"button",95),d("click",function(){E(e);let a=S(2);return u(a.updatePassphrase())}),_(1,46),o()}if(n&2){let e=S(2);I("loading",e.isUpdating())}}function Sn(n,t){if(n&1){let e=P();s(0,"button",96),d("click",function(){E(e);let a=S(2);return u(a.updatePassphrase())}),_(1,47),o()}if(n&2){let e=S(2);I("loading",e.isUpdating()),N("disabled",!0)}}function cn(n,t){if(n&1){let e=P();s(0,"sh-form-field")(1,"label",86),_(2,43),o(),s(3,"input",87),L("ngModelChange",function(a){E(e);let T=S();return y(T.passphrase,a)||(T.passphrase=a),u(a)}),o()(),s(4,"sh-form-field")(5,"label",88),_(6,44),o(),s(7,"input",89),L("ngModelChange",function(a){E(e);let T=S();return y(T.repeatPassphrase,a)||(T.repeatPassphrase=a),u(a)}),o(),C(8,_n,2,0,"sh-icon",90)(9,rn,2,0,"sh-icon",91),o(),s(10,"div",67)(11,"button",92),d("click",function(){E(e);let a=S();return u(a.cancelPasswordChange())}),_(12,45),o(),C(13,Tn,2,2,"button",93)(14,Sn,2,3,"button",94),o()}if(n&2){let e=S();l(3),A("ngModel",e.passphrase),l(4),N("disabled",e.passphrase().length===0),A("ngModel",e.repeatPassphrase),l(),g(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?8:9),l(3),I("loading",e.isUpdating()),l(2),g(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?13:14)}}function dn(n,t){n&1&&(s(0,"sh-icon",97),$(1,"check"),o())}function Cn(n,t){if(n&1){let e=P();s(0,"div",67)(1,"button",92),d("click",function(){E(e);let a=S();return u(a.openPassphraseForm())}),_(2,48),o(),C(3,dn,2,0,"sh-icon",97),o()}if(n&2){let e=S();l(3),g(e.passwordUpdated()?3:-1)}}function gn(n,t){n&1&&(O(0,11,1),m(1,"span"),h())}function En(n,t){n&1&&(O(0,11,2),m(1,"span"),h())}function un(n,t){if(n&1){let e=P();s(0,"sh-form-field")(1,"label",98),_(2,49),o(),s(3,"textarea",99),L("ngModelChange",function(a){E(e);let T=S();return y(T.allowedHostnames,a)||(T.allowedHostnames=a),u(a)}),o()(),s(4,"sh-alert",100),_(5,50),o(),s(6,"button",95),d("click",function(){E(e);let a=S();return u(a.updateAllowedHostnames())}),_(7,51),o()}if(n&2){let e=S();l(3),A("ngModel",e.allowedHostnames),l(3),I("loading",e.updatingAllowedHosts())}}function pn(n,t){if(n&1){let e=P();s(0,"section")(1,"div",61)(2,"h3"),_(3,52),o(),s(4,"p"),_(5,53),o()(),s(6,"div",62)(7,"sh-select",101)(8,"input",69),d("ngModelChange",function(a){E(e);let T=S();return u(T.updatePowerMode(a))}),o()()()()}if(n&2){let e=S();l(7),N("options",e.powerModeOptions())("isClearable",!1),l(),N("ngModel",e.powerModeCtrl())("ngModelOptions",J(4,ne))}}function Nn(n,t){if(n&1&&(s(0,"p"),_(1,54),o()),n&2){let e,i=S();l(),V((e=i.sysinfo())==null?null:e.ServerVersionName),U(1)}}function mn(n,t){n&1&&m(0,"sh-progress-bar",74)}function fn(n,t){if(n&1&&$(0),n&2){let e=t.$implicit;se(" ",e.label," ")}}function In(n,t){if(n&1&&$(0),n&2){let e=t.$implicit;se(" ",e.label," ")}}function Pn(n,t){if(n&1){let e=P();s(0,"section")(1,"div",61)(2,"h3"),_(3,55),o(),s(4,"p")(5,"span"),_(6,56),o(),s(7,"a",102),_(8,57),o(),m(9,"br")(10,"br"),s(11,"span"),_(12,58),o()()(),s(13,"div",62)(14,"sh-select",103)(15,"input",69),d("ngModelChange",function(a){E(e);let T=S();return u(T.updateUsageStatistics(a))}),o(),oe(16,In,1,1,"ng-template"),o()()()}if(n&2){let e=S();l(14),N("options",e.usageStatisticsOptions())("isLoading",e.updatingUsageStatistics()),l(),N("ngModel",e.usageStatistics())("ngModelOptions",J(4,ne))}}function Mn(n,t,e){let i=bt(n),a=i[st];e?.equal&&(a.equal=e.equal);let T;return i.set=f=>{clearTimeout(T),T=setTimeout(()=>at(a,f),t)},i.update=f=>{clearTimeout(T),T=setTimeout(()=>lt(a,f),t)},i}var On=[{value:"none",label:$localize`None`},{value:"s",label:$localize`Seconds`},{value:"m",label:$localize`Minutes`},{value:"h",label:$localize`Hours`}],wt=[{value:"none",label:$localize`System default ($value)`},{value:"information",label:$localize`Usage statistics, warnings, errors, and crashes`},{value:"warning",label:$localize`Warnings, errors and crashes`},{value:"error",label:$localize`Errors and crashes`},{value:"crash",label:$localize`Crashes only`},{value:"disabled",label:$localize`None / disabled`}],le=class n{#e=R(Nt);#n=R($t);#i=R(Ft);#t=R(x);#s=R(ee);#T=R(ut);#a=R(Et);#l=this.#a.getItem("locale")??"en-US";sysinfo=this.#i.systemInfo;isDarkMode=this.#n.isDarkMode;editAs=c("list");previousLang=this.#l;langCtrl=c(this.#l);powerModeCtrl=c("");usageStatistics=c("");updatingUsageStatistics=c(!1);remoteControlStatus=this.#s.status;remoteControlState=this.#s.state;updatingChannel=c(!1);updateChannel=c("");isUsingRelay=this.#T.relayIsEnabled;defaultClient=c(this.#S());usageStatisticsDisabled=v(()=>(this.#i.systemInfo()?.DefaultUsageReportLevel??"").toLowerCase()==="disabled");#c=k(()=>{let t=this.#i.systemInfo()?.DefaultUsageReportLevel??"",e=wt;e[0].label=$localize`System default (${t})`,this.usageStatisticsOptions.set(e)});remoteControlTooltip=c($localize`Disabling console control will disable remote access to this machine from the console, but will keep the
|
|
1
|
+
import{a as At}from"./chunk-JW6W3ER7.js";import"./chunk-W4HWOC3K.js";import{a as $t}from"./chunk-JKIZ6U22.js";import"./chunk-4QE3MT56.js";import{a as yt}from"./chunk-LGILJ5LY.js";import"./chunk-I2HYK2BL.js";import"./chunk-B35WNLRM.js";import"./chunk-SLS3DCJP.js";import"./chunk-SUY5AQLW.js";import"./chunk-6Q6SSTBK.js";import"./chunk-I4XRVBRQ.js";import{a as ee}from"./chunk-HA7XREWO.js";import"./chunk-X64LSE6Y.js";import{a as ae}from"./chunk-RFB5A3B7.js";import"./chunk-AZJ2P3YU.js";import{a as x}from"./chunk-3SSB4QCJ.js";import"./chunk-AYOFR344.js";import"./chunk-UUQWSINE.js";import{a as Ft}from"./chunk-BEXYTIOL.js";import{a as Et,c as ut}from"./chunk-LO5YNFFR.js";import{B as D,E as mt,G as ft,H as Z,L as It,M as Pt,N as Mt,P as Ot,W as ht,Y as Rt,c as W,e as q,i as j,m as pt,s as K,t as Q,v as w,w as Y,z as Nt}from"./chunk-YCLTQEU6.js";import{d as Gt}from"./chunk-2LSZ2I43.js";import"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Ab as N,Bb as s,Cb as o,Db as m,E as F,Kb as P,Oa as _t,Pc as v,Ra as l,Rb as O,Sb as h,Tb as _,Ub as V,Vb as U,Wb as B,Wc as gt,Xb as d,Z as R,Zb as S,a as st,b as at,c as lt,ca as E,da as u,eb as b,ec as ct,fc as dt,ic as I,jb as oe,kb as rt,lc as $,mc as H,nc as se,oa as c,qa as k,qc as A,rb as Tt,rc as y,sb as St,sc as L,ub as C,vb as g,wc as Ct,zc as J}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";var Dt=["formRef"],xt=()=>[import("./chunk-PAPOSE5G.js").then(n=>n.OptionsListComponent)];function kt(n,t){n&1&&(s(0,"sh-alert",3),_(1,1),o())}function Jt(n,t){if(n&1){let e=P();s(0,"app-options-list",5),L("optionsChange",function(a){E(e);let T=S();return y(T.settings,a)||(T.settings=a),u(a)}),o()}if(n&2){let e=S();A("options",e.settings),N("hasFreeTextSettings",!0)}}var X=class n{#e=R(x);#n=R(Gt);formRef=gt.required("formRef");settings=c([]);isSubmitting=c(!1);isLoadingOptions=c(!0);saved=c(!1);lastRecievedServerSettings=c({});serverSettingsEffect=k(()=>{let t=this.#e.serverSettings();if(t===void 0)return;this.lastRecievedServerSettings.set(t),this.isLoadingOptions.set(!0);let e=Object.entries(t);e.forEach(([i,a],T)=>{if(i.startsWith("--")){let f=i.substring(2);this.settings.update(p=>(p.some(M=>M.Name===f||M.Name===i)||p.push({Name:i,Value:a}),p))}T===e.length-1&&this.isLoadingOptions.set(!1)})});submit(){this.isSubmitting.set(!0);let t=this.settings(),e=this.lastRecievedServerSettings(),i=t.map(p=>p.Name?.startsWith("--")?p.Name:`--${p.Name}`),T=Object.keys(e).filter(p=>p.startsWith("--")).filter(p=>!i.includes(p)),f=t.reduce((p,M)=>{let G=M.Name?.startsWith("--")?M.Name:`--${M.Name}`;return p[G]=M.Value,p},{});T.forEach(p=>{f[p]=null}),this.#n.patchApiV1Serversettings({requestBody:f}).pipe(F(()=>this.isSubmitting.set(!1))).subscribe({next:()=>{this.#e.refreshServerSettings(),this.saved.set(!0),setTimeout(()=>{this.saved.set(!1)},3e3)}})}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=b({type:n,selectors:[["app-advanced-options-settings"]],viewQuery:function(e,i){e&1&&ct(i.formRef,Dt,5),e&2&&dt()},decls:8,vars:4,consts:()=>{let t;t=$localize`${"\uFFFD#4\uFFFD"}:START_TAG_SH_ICON:floppy-disk${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_SH_ICON: Save settings `;let e;return e=$localize`Settings saved`,[t,e,[1,"actions"],[1,"success"],["shButton","","type","button",1,"raised","primary",3,"click"],[3,"optionsChange","options","hasFreeTextSettings"]]},template:function(e,i){e&1&&(s(0,"div",2),C(1,kt,2,0,"sh-alert",3),s(2,"button",4),d("click",function(){return i.submit()}),O(3,0),m(4,"sh-icon"),h(),o()(),rt(5,Jt,1,2),Tt(6,5,xt)),e&2&&(l(),g(i.saved()?1:-1),l(),I("loading",i.isSubmitting()),l(4),St(!i.isLoadingOptions()))},dependencies:[Q,D,w,Y],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:40.625rem;justify-self:flex-end}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem;justify-content:flex-end;margin-bottom:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.form-wrap[_ngcontent-%COMP%]{display:grid;grid-template-columns:2fr 2.5rem;gap:.5rem;align-items:flex-end}.remote-volume-wrap[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.remote-volume-wrap[_ngcontent-%COMP%] p.warning[_ngcontent-%COMP%]{color:#7d7d00}.row-inputs[_ngcontent-%COMP%]{display:flex;align-items:flex-end;gap:.5rem}.row-inputs[_ngcontent-%COMP%] > *[_ngcontent-%COMP%]{flex:1 0}.advanced-option[_ngcontent-%COMP%]{display:grid;gap:.5rem;grid-template-columns:1fr 1fr 2.5rem;align-items:flex-end}"],changeDetection:0})};function zt(n,t){if(n&1){let e=P();s(0,"sh-form-field",12)(1,"input",13),L("ngModelChange",function(a){E(e);let T=S(2);return y(T.registerUrl,a)||(T.registerUrl=a),u(a)}),o()(),s(2,"button",14),d("click",function(){E(e);let a=S(2);return u(a.register())}),_(3,0),o()}if(n&2){let e=S(2);l(),A("ngModel",e.registerUrl)}}function Vt(n,t){if(n&1&&(s(0,"div",9)(1,"label"),_(2,1),o(),s(3,"a",15),$(4),o()()),n&2){let e=S(2);l(3),N("href",Ct(e.claimUrl()),_t),l(),H(e.claimUrl())}}function Ut(n,t){n&1&&(s(0,"div",9)(1,"label"),_(2,2),o()())}function Bt(n,t){if(n&1){let e=P();s(0,"button",14),d("click",function(){E(e);let a=S(2);return u(a.cancel())}),_(1,3),o()}}function Ht(n,t){if(n&1){let e=P();s(0,"button",14),d("click",function(){E(e);let a=S(2);return u(a.disable())}),_(1,4),o()}}function Wt(n,t){if(n&1){let e=P();s(0,"button",14),d("click",function(){E(e);let a=S(2);return u(a.enable())}),_(1,5),o(),s(2,"button",16),d("click",function(){E(e);let a=S(2);return u(a.delete())}),_(3,6),o()}}function qt(n,t){n&1&&(O(0,7,1),m(1,"sh-icon"),h())}function jt(n,t){n&1&&(O(0,7,2),m(1,"sh-icon"),h())}function Kt(n,t){if(n&1){let e=P();s(0,"sh-chip",17),d("click",function(){E(e);let a=S(2);return u(a.copyReportingUrl())}),O(1,7),C(2,qt,2,0,"sh-icon")(3,jt,2,0,"sh-icon"),h(),o()}if(n&2){let e=S(2);l(2),g(e.copiedReportingUrl()===!0?2:3)}}function Qt(n,t){if(n&1&&(s(0,"div",8),C(1,zt,4,1),C(2,Vt,5,3,"div",9),C(3,Ut,3,0,"div",9),C(4,Bt,2,0,"button",10),C(5,Ht,2,0,"button",10),C(6,Wt,4,0),C(7,Kt,4,1,"sh-chip",11),o()),n&2){let e=S();l(),g(e.state()==="inactive"?1:-1),l(),g(e.state()==="registered"?2:-1),l(),g(e.state()==="registering"?3:-1),l(),g(e.state()==="registering"||e.state()==="registeringfaulted"||e.state()==="registered"?4:-1),l(),g(e.state()==="connected"||e.state()==="connecting"?5:-1),l(),g(e.state()==="disabled"?6:-1),l(),g(e.additionalReportingUrl()!==""?7:-1)}}var te=class n{#e=R(ee);#n=R(x);state=this.#e.state;claimUrl=this.#e.claimUrl;registerUrl=this.#e.registerUrl;additionalReportingUrl=v(()=>{let t=this.#n.serverSettings();return this.#e.state()==="inactive"?"":t&&t["additional-report-url"]||""});copiedReportingUrl=c(!1);ngOnInit(){this.#e.refreshRemoteControlStatus()}cancel(){this.#e.cancelRemoteRegistration()}register(){this.#e.beginRemoteRegistration()}disable(){this.#e.disableRemoteControl()}enable(){this.#e.enableRemoteControl()}delete(){this.#e.deleteRemoteControl()}copyReportingUrl(){let t=this.additionalReportingUrl();t&&(this.copiedReportingUrl.set(!0),setTimeout(()=>this.copiedReportingUrl.set(!1),2e3),navigator.clipboard.writeText(t))}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=b({type:n,selectors:[["app-remote-control"]],decls:1,vars:1,consts:()=>{let t;t=$localize`Register on console`;let e;e=$localize`Machine is now registered, open this link to add it to your account:`;let i;i=$localize`Registering, please wait...`;let a;a=$localize`Cancel registration`;let T;T=$localize`Disable console connection`;let f;f=$localize`Enable console connection`;let p;p=$localize` Delete console connection setup `;let M;return M=$localize` Reporting configured by server ${"\uFFFD*2:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:check${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*2:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*3:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SH_ICON:copy${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/*3:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,M=B(M),[t,e,i,a,T,f,p,M,[1,"field-row"],[1,"field-col"],["type","button","shButton","",1,"raised"],[1,"reporting-url","primary","simple"],["label","Registration URL","for","remoteControlRegisterUrl"],["type","text","sh-input","","id","remoteControlRegisterUrl","name","remoteControlRegisterUrl",3,"ngModelChange","ngModel"],["type","button","shButton","",1,"raised",3,"click"],["target","_blank",3,"href"],["type","button","shButton","",1,"raised","error",3,"click"],[1,"reporting-url","primary","simple",3,"click"]]},template:function(e,i){e&1&&C(0,Qt,8,7,"div",8),e&2&&g(i.state()!=="unknown"?0:-1)},dependencies:[K,W,q,j,Z,D,mt,w],styles:["[_nghost-%COMP%]{display:block}[_nghost-%COMP%] button[_ngcontent-%COMP%]{white-space:nowrap}.field-row[_ngcontent-%COMP%]{display:flex;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] sh-form-field[_ngcontent-%COMP%], .field-row[_ngcontent-%COMP%] sh-select[_ngcontent-%COMP%]{flex:1 0}.reporting-url[_ngcontent-%COMP%]{cursor:pointer;-webkit-user-select:none;user-select:none;margin-top:.25rem}"],changeDetection:0})};function bt(...n){let t=c(...n);return Object.defineProperty(t,"value",{get:t.asReadonly(),set:t.set.bind(t)})}var ne=()=>({standalone:!0});function Yt(n,t){if(n&1&&(s(0,"label"),O(1,35),m(2,"sh-icon",85),h(),o()),n&2){let e=S(3);l(2),N("shTooltip",e.remoteControlTooltip())}}function Zt(n,t){if(n&1&&(s(0,"label"),O(1,36),m(2,"sh-icon",85),h(),o()),n&2){let e=S(3);l(2),N("shTooltip",e.remoteControlTooltip())}}function en(n,t){if(n&1&&(s(0,"label"),O(1,37),m(2,"sh-icon",85),h(),o()),n&2){let e=S(3);l(2),N("shTooltip",e.connectionStatusIndicatorTooltip())}}function tn(n,t){if(n&1&&(s(0,"label"),O(1,38),m(2,"sh-icon",85),h(),o()),n&2){let e=S(3);l(2),N("shTooltip",e.connectionStatusIndicatorTooltip())}}function nn(n,t){if(n&1){let e=P();s(0,"section")(1,"div",61)(2,"h3"),_(3,33),o(),s(4,"p"),_(5,34),o()(),s(6,"div",84)(7,"sh-toggle",73),d("click",function(){E(e);let a=S(2);return u(a.toggleConsoleControl())}),C(8,Yt,3,1,"label")(9,Zt,3,1,"label"),o(),s(10,"sh-toggle",73),d("click",function(){E(e);let a=S(2);return u(a.saveHideConsoleConnectionStatus())}),C(11,en,3,1,"label")(12,tn,3,1,"label"),o()()()}if(n&2){let e=S(2);l(7),I("active",!e.consoleControlDisabled()),l(),g(e.consoleControlDisabled()?8:9),l(2),I("active",!e.hideConsoleConnectionStatus()),l(),g(e.hideConsoleConnectionStatus()?11:12)}}function on(n,t){n&1&&(s(0,"label"),_(1,41),o())}function sn(n,t){n&1&&(s(0,"label"),_(1,42),o())}function an(n,t){if(n&1){let e=P();s(0,"section")(1,"div",61)(2,"h3"),_(3,39),o(),s(4,"p"),_(5,40),o()(),s(6,"div",62)(7,"sh-toggle",73),d("click",function(){E(e);let a=S(2);return u(a.saveHideConsoleConnectionStatus())}),C(8,on,2,0,"label")(9,sn,2,0,"label"),o()()()}if(n&2){let e=S(2);l(7),I("active",!e.hideConsoleConnectionStatus()),l(),g(e.hideConsoleConnectionStatus()?8:9)}}function ln(n,t){if(n&1&&(s(0,"section")(1,"div",61)(2,"h3"),_(3,32),o(),s(4,"p"),$(5),o()(),s(6,"div",62),m(7,"app-remote-control"),o()(),C(8,nn,13,6,"section")(9,an,10,3,"section")),n&2){let e=S();l(5),H(e.remoteControlStatus()),l(3),g(e.remoteControlState()!="inactive"?8:9)}}function _n(n,t){n&1&&(s(0,"sh-icon",90),$(1,"check"),o())}function rn(n,t){n&1&&(s(0,"sh-icon",91),$(1,"prohibit"),o())}function Tn(n,t){if(n&1){let e=P();s(0,"button",95),d("click",function(){E(e);let a=S(2);return u(a.updatePassphrase())}),_(1,46),o()}if(n&2){let e=S(2);I("loading",e.isUpdating())}}function Sn(n,t){if(n&1){let e=P();s(0,"button",96),d("click",function(){E(e);let a=S(2);return u(a.updatePassphrase())}),_(1,47),o()}if(n&2){let e=S(2);I("loading",e.isUpdating()),N("disabled",!0)}}function cn(n,t){if(n&1){let e=P();s(0,"sh-form-field")(1,"label",86),_(2,43),o(),s(3,"input",87),L("ngModelChange",function(a){E(e);let T=S();return y(T.passphrase,a)||(T.passphrase=a),u(a)}),o()(),s(4,"sh-form-field")(5,"label",88),_(6,44),o(),s(7,"input",89),L("ngModelChange",function(a){E(e);let T=S();return y(T.repeatPassphrase,a)||(T.repeatPassphrase=a),u(a)}),o(),C(8,_n,2,0,"sh-icon",90)(9,rn,2,0,"sh-icon",91),o(),s(10,"div",67)(11,"button",92),d("click",function(){E(e);let a=S();return u(a.cancelPasswordChange())}),_(12,45),o(),C(13,Tn,2,2,"button",93)(14,Sn,2,3,"button",94),o()}if(n&2){let e=S();l(3),A("ngModel",e.passphrase),l(4),N("disabled",e.passphrase().length===0),A("ngModel",e.repeatPassphrase),l(),g(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?8:9),l(3),I("loading",e.isUpdating()),l(2),g(e.passphrase().length!==0&&e.passphrase()===e.repeatPassphrase()?13:14)}}function dn(n,t){n&1&&(s(0,"sh-icon",97),$(1,"check"),o())}function Cn(n,t){if(n&1){let e=P();s(0,"div",67)(1,"button",92),d("click",function(){E(e);let a=S();return u(a.openPassphraseForm())}),_(2,48),o(),C(3,dn,2,0,"sh-icon",97),o()}if(n&2){let e=S();l(3),g(e.passwordUpdated()?3:-1)}}function gn(n,t){n&1&&(O(0,11,1),m(1,"span"),h())}function En(n,t){n&1&&(O(0,11,2),m(1,"span"),h())}function un(n,t){if(n&1){let e=P();s(0,"sh-form-field")(1,"label",98),_(2,49),o(),s(3,"textarea",99),L("ngModelChange",function(a){E(e);let T=S();return y(T.allowedHostnames,a)||(T.allowedHostnames=a),u(a)}),o()(),s(4,"sh-alert",100),_(5,50),o(),s(6,"button",95),d("click",function(){E(e);let a=S();return u(a.updateAllowedHostnames())}),_(7,51),o()}if(n&2){let e=S();l(3),A("ngModel",e.allowedHostnames),l(3),I("loading",e.updatingAllowedHosts())}}function pn(n,t){if(n&1){let e=P();s(0,"section")(1,"div",61)(2,"h3"),_(3,52),o(),s(4,"p"),_(5,53),o()(),s(6,"div",62)(7,"sh-select",101)(8,"input",69),d("ngModelChange",function(a){E(e);let T=S();return u(T.updatePowerMode(a))}),o()()()()}if(n&2){let e=S();l(7),N("options",e.powerModeOptions())("isClearable",!1),l(),N("ngModel",e.powerModeCtrl())("ngModelOptions",J(4,ne))}}function Nn(n,t){if(n&1&&(s(0,"p"),_(1,54),o()),n&2){let e,i=S();l(),V((e=i.sysinfo())==null?null:e.ServerVersionName),U(1)}}function mn(n,t){n&1&&m(0,"sh-progress-bar",74)}function fn(n,t){if(n&1&&$(0),n&2){let e=t.$implicit;se(" ",e.label," ")}}function In(n,t){if(n&1&&$(0),n&2){let e=t.$implicit;se(" ",e.label," ")}}function Pn(n,t){if(n&1){let e=P();s(0,"section")(1,"div",61)(2,"h3"),_(3,55),o(),s(4,"p")(5,"span"),_(6,56),o(),s(7,"a",102),_(8,57),o(),m(9,"br")(10,"br"),s(11,"span"),_(12,58),o()()(),s(13,"div",62)(14,"sh-select",103)(15,"input",69),d("ngModelChange",function(a){E(e);let T=S();return u(T.updateUsageStatistics(a))}),o(),oe(16,In,1,1,"ng-template"),o()()()}if(n&2){let e=S();l(14),N("options",e.usageStatisticsOptions())("isLoading",e.updatingUsageStatistics()),l(),N("ngModel",e.usageStatistics())("ngModelOptions",J(4,ne))}}function Mn(n,t,e){let i=bt(n),a=i[st];e?.equal&&(a.equal=e.equal);let T;return i.set=f=>{clearTimeout(T),T=setTimeout(()=>at(a,f),t)},i.update=f=>{clearTimeout(T),T=setTimeout(()=>lt(a,f),t)},i}var On=[{value:"none",label:$localize`None`},{value:"s",label:$localize`Seconds`},{value:"m",label:$localize`Minutes`},{value:"h",label:$localize`Hours`}],wt=[{value:"none",label:$localize`System default ($value)`},{value:"information",label:$localize`Usage statistics, warnings, errors, and crashes`},{value:"warning",label:$localize`Warnings, errors and crashes`},{value:"error",label:$localize`Errors and crashes`},{value:"crash",label:$localize`Crashes only`},{value:"disabled",label:$localize`None / disabled`}],le=class n{#e=R(Nt);#n=R($t);#i=R(Ft);#t=R(x);#s=R(ee);#T=R(ut);#a=R(Et);#l=this.#a.getItem("locale")??"en-US";sysinfo=this.#i.systemInfo;isDarkMode=this.#n.isDarkMode;editAs=c("list");previousLang=this.#l;langCtrl=c(this.#l);powerModeCtrl=c("");usageStatistics=c("");updatingUsageStatistics=c(!1);remoteControlStatus=this.#s.status;remoteControlState=this.#s.state;updatingChannel=c(!1);updateChannel=c("");isUsingRelay=this.#T.relayIsEnabled;defaultClient=c(this.#S());usageStatisticsDisabled=v(()=>(this.#i.systemInfo()?.DefaultUsageReportLevel??"").toLowerCase()==="disabled");#c=k(()=>{let t=this.#i.systemInfo()?.DefaultUsageReportLevel??"",e=wt;e[0].label=$localize`System default (${t})`,this.usageStatisticsOptions.set(e)});remoteControlTooltip=c($localize`Disabling console control will disable remote access to this machine from the console, but will keep the
|
|
2
2
|
registration intact and allow pushing settings from the console.`);connectionStatusIndicatorTooltip=c($localize`Hides the connection status indicator in the status bar. Useful if you are not using the remote console.`);setNewChannel(t){let e=this.updateChannel();this.updateChannel.set(t),this.#t.setUpdateChannel(t).pipe(F(()=>this.updatingChannel.set(!1))).subscribe()}allowRemoteAccess=c(!1);allowedHostnames=c("");loadedAllowedHostnames=c("");updatingRemoteAccess=c(!1);updatingAllowedHosts=c(!1);updatingConsoleControl=c(!1);consoleControlDisabled=c(!1);hideConsoleConnectionStatus=this.#t.isConsoleConnectionStatusHidden;updateRemoteAccess(){let e=!this.allowRemoteAccess();this.allowRemoteAccess.set(e),this.#t.setRemoteAccessInterface(e?"any":"loopback").pipe(F(()=>this.updatingRemoteAccess.set(!1))).subscribe()}updateAllowedHostnames(){let t=this.allowedHostnames();this.updatingAllowedHosts.set(!0),this.#t.setRemoteAccessAllowedHostnames(t).pipe(F(()=>this.updatingAllowedHosts.set(!1))).subscribe()}toggleConsoleControl(){let e=!this.consoleControlDisabled();this.updatingConsoleControl.set(!0),this.#t.setDisableConsoleControl(e).pipe(F(()=>this.updatingConsoleControl.set(!1))).subscribe()}updatingDisableTrayIconLogin=c(!1);disableTrayIconLogin=c(!1);saveDisableTrayIconLogin(){let e=!this.disableTrayIconLogin();this.updatingDisableTrayIconLogin.set(!0),this.#t.setDisableTrayIconLogin(e).pipe(F(()=>this.updatingDisableTrayIconLogin.set(!1))).subscribe()}updatingHideConsoleConnectionStatus=c(!1);saveHideConsoleConnectionStatus(){let e=!this.hideConsoleConnectionStatus();this.updatingHideConsoleConnectionStatus.set(!0),this.#t.setHideConsoleConnectionStatus(e).pipe(F(()=>this.updatingHideConsoleConnectionStatus.set(!1))).subscribe()}showPassphraseForm=c(!1);isUpdating=c(!1);passphrase=c("");repeatPassphrase=c("");passwordUpdated=c(!1);updatePassphrase(){this.passphrase()===this.repeatPassphrase()&&(this.isUpdating.set(!0),this.#t.setRemoteAccessPassword(this.passphrase()).pipe(F(()=>this.isUpdating.set(!1))).subscribe({next:()=>{this.showPassphraseForm.set(!1),this.passwordUpdated.set(!0),setTimeout(()=>{this.passwordUpdated.set(!1)},3e3)}}))}openPassphraseForm(){this.showPassphraseForm.set(!0)}cancelPasswordChange(){this.showPassphraseForm.set(!1)}languageOptions=c(yt);powerModeOptions=v(()=>{let t=this.#i.systemInfo();return!t?.PowerModeProviders||t.PowerModeProviders.filter(e=>e!==""&&e!=="None").length==0?[]:t.PowerModeProviders.map(e=>({value:e==""?"default":e,label:e===""?$localize`Default`:e}))});usageStatisticsOptions=c(wt);timeTypeOptions=c(On);timeType=c("none");timeValue=Mn(0,300);timeRange=v(()=>this.timeType()==="h"?[1,24]:[1,60]);updateLocale(t){!t||t===""||t===this.previousLang||(this.#a.setItem("locale",t),window.location.reload())}updateTimeValue(t){this.timeValue.set(t),this.#_()}updateTimeType(t){this.timeType()==="none"&&this.timeValue.set(1),this.timeType.set(t),this.#_()}#o;#_(){this.#o&&clearTimeout(this.#o),this.#o=setTimeout(()=>{let t=this.timeValue(),e=this.timeType(),i=e==="none"||t===0?"":`${t}${e}`;i!==this.#t.serverSettings()?.["startup-delay"]&&this.#t.setStartupDelay(i).subscribe()},1e3)}updateUsageStatistics(t){let e=this.usageStatistics();!t||t===""||t===e||(this.usageStatistics.set(t),this.updatingUsageStatistics.set(!0),this.#t.setUsageReporterLevel(t).subscribe())}updatePowerMode(t){this.powerModeCtrl()!==t&&(t==="default"&&(t=""),this.#t.setPowerModeProvider(t).subscribe())}serverSettingsEffect=k(()=>{let t=this.#t.serverSettings();if(t===void 0)return;let e=t["startup-delay"],i=e.slice(-1),a=e.slice(0,-1),T=["s","m","h"];this.disableTrayIconLogin.set(t["disable-tray-icon-login"]!=="False"),this.updateChannel.set(t["update-channel"]),this.allowRemoteAccess.set(t["server-listen-interface"]==="any"),this.allowedHostnames.set(t["allowed-hostnames"]),this.loadedAllowedHostnames.set(t["allowed-hostnames"]),this.consoleControlDisabled.set(t["disable-console-control"]==="True"),this.usageStatistics.set(t["usage-reporter-level"]===""?"none":t["usage-reporter-level"]),this.timeType.set(e==""?"none":T.includes(i)?i:"none"),this.timeValue.set(e==""?0:parseInt(a));let f=t["power-mode-provider"]===""||t["power-mode-provider"]==null?"default":t["power-mode-provider"];this.powerModeCtrl.set(f)});setDarkMode(){this.#n.setDarkMode()}setLightMode(){this.#n.setLightMode()}changeDefaultClientTo(t){this.defaultClient()!==t&&(t==="ngax"?this.#e.open(ae,{data:{title:$localize`Use legacy UI by default`,message:$localize`Are you sure you want to use the legacy user interface by default? This is not recommended unless you have a specific reason.`,confirmText:$localize`Use legacy UI by default`,cancelText:$localize`Cancel`},closed:e=>{e&&(window.location.href="/ngax",this.#r(t))}}):this.#r(t))}openLegacyUI(){this.#e.open(ae,{data:{title:$localize`Open legacy UI`,message:$localize`Are you sure you want to open the legacy user interface? This is not recommended unless you have a specific reason.`,confirmText:$localize`Open legacy UI`,cancelText:$localize`Cancel`},closed:t=>{t&&window.open("/ngax","_blank")}})}#r(t){var e=new Date;e.setTime(e.getTime()+2160*60*60*1e3),document.cookie="default-client="+t+"; expires="+e.toUTCString()+"; path=/",this.defaultClient.set(t)}#S(){let t=document.cookie.split(";");for(let e=0;e<t.length;e++){let i=t[e].trim();if(i.startsWith("default-client="))return i.substring(15)}return"ngclient"}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=b({type:n,selectors:[["app-settings"]],decls:128,vars:44,consts:()=>{let t;t=$localize`Settings`;let e;e=$localize`Configure your backup settings.`;let i;i=$localize`Color theme`;let a;a=$localize`Customize your application theme`;let T;T=$localize`Passwords`;let f;f=$localize`Change server passphrase`;let p;p=$localize`Language`;let M;M=$localize`Select a language for the platform`;let G;G=$localize`Use legacy interface`;let _e;_e=$localize`Use the old user interface, not recommended unless you have a specific reason.`;let re;re=$localize`${"\uFFFD#46\uFFFD"}:START_TAG_SH_ICON:arrow-square-right${"\uFFFD/#46\uFFFD"}:CLOSE_TAG_SH_ICON: Open legacy UI `;let z;z=$localize`${"\uFFFD#49\uFFFD"}:START_TAG_SH_ICON:swap${"\uFFFD/#49\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD*50:1\uFFFD"}:START_BLOCK_IF:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SPAN:Set current UI as default${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SPAN:${"\uFFFD/*50:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*51:2\uFFFD"}:START_BLOCK_ELSE:${"[\uFFFD#1:1\uFFFD|\uFFFD#1:2\uFFFD]"}:START_TAG_SPAN:Set legacy UI as default${"[\uFFFD/#1:1\uFFFD|\uFFFD/#1:2\uFFFD]"}:CLOSE_TAG_SPAN:${"\uFFFD/*51:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,z=B(z);let Te;Te=$localize`Allow remote access (requires restart)`;let Se;Se=$localize` By allowing remote access, the server listens to requests from any machine on your network. If you enable this option, make sure you are always using the computer on a secure firewall protected network. `;let ce;ce=$localize`Allow remote access`;let de;de=$localize`Prevent tray icon automatic log-in`;let Ce;Ce=$localize` By default, the tray icon will open the user interface with a token that unlocks the user interface. This ensures that you can access the user interface from the tray icon, while requiring others to enter a password. If you prefer having to type in the password, even when accessing the user interface from the tray icon, enable this option. `;let ge;ge=$localize`Prevent tray icon automatic log-in`;let Ee;Ee=$localize`Update channel`;let ue;ue=$localize` Default (${"\uFFFD0\uFFFD"}:INTERPOLATION:) `;let pe;pe=$localize`Same as the base install version: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Ne;Ne=$localize`Stable`;let me;me=$localize`Official stable release.`;let fe;fe=$localize`Beta`;let Ie;Ie=$localize` Try out the new features that we are working on. Test a backup and restore before using this in production environments. `;let Pe;Pe=$localize` Experimental `;let Me;Me=$localize`Early previews of new features. Not for use with important data.`;let Oe;Oe=$localize`Canary`;let he;he=$localize`Builds for developers and testers only. Not for use with important data.`;let Re;Re=$localize`Pause after startup or hibernation`;let Ge;Ge=$localize` Duplicati will run when started, but will remain in paused state for the duration. Duplicati will occupy minimal system resources and no backups will be run. `;let Fe;Fe=$localize`Advanced options`;let $e;$e=$localize`Connect to console`;let Ae;Ae=$localize`Configure console control`;let ye;ye=$localize` You can control various settings for the remote console connection. If you are not using the console, you can also hide the connection status indicator. `;let Le;Le=$localize` Remote control disabled ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let ve;ve=$localize` Remote control enabled ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let be;be=$localize` Console connection status is hidden ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let we;we=$localize` Console connection status is visible ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let De;De=$localize`Toggle console connection status`;let xe;xe=$localize`Toggle the visibility of the console connection status indicator.`;let ke;ke=$localize`Console connection status is hidden`;let Je;Je=$localize`Console connection status is visible`;let Xe;Xe=$localize`Enter new password`;let ze;ze=$localize`Repeat password`;let ie;ie=$localize`Password have to be filled and have to match`;let Ve;Ve=$localize`Passphrase`;let Ue;Ue=$localize`Repeat passphrase`;let Be;Be=$localize`Cancel`;let He;He=$localize` Update passphrase `;let We;We=$localize` Update passphrase `;let qe;qe=$localize`Change password`;let je;je=$localize`Allowed hostnames`;let Ke;Ke=$localize` To prevent various DNS based attacks, Duplicati limits the allowed hostnames to the ones listed here. Direct IP access and localhost is always allowed. Multiple hostnames can be supplied with a semicolon separator. If any of the allowed hostnames is an asterisk (*), all hostnames are allowed and this feature is disabled. If the field is empty, only IP address and localhost access is allowed. `;let Qe;Qe=$localize` Update allowed hostnames `;let Ye;Ye=$localize`Power mode provider`;let Ze;Ze=$localize` The power mode provider monitors the system for when it enters a low power state and pauses Duplicati. When the system resumes, Duplicati will resume as well. Choosing the None option disables detection of low power states and Duplicati will run all the time. `;let et;et=$localize`Installed version: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let tt;tt=$localize`Usage statistics`;let nt;nt=$localize` Usage reports help us improve the user experience and evaluate impact of new features. We use them to generate `;let it;it=$localize`public usage statistics.`;let ot;return ot=$localize` All usage reports are sent anonymously and do not contain any personal information. They contain information about hardware and operating system, the type of backend, backup duration, overall size of source data and similar data. They do not contain paths, filenames, usernames, passwords or similar sensitive information. `,[t,e,i,a,T,f,p,M,G,_e,re,z,Te,Se,ce,de,Ce,ge,Ee,ue,pe,Ne,me,fe,Ie,Pe,Me,Oe,he,Re,Ge,Fe,$e,Ae,ye,Le,ve,be,we,De,xe,ke,Je,Ve,Ue,Be,He,We,qe,je,Ke,Qe,Ye,Ze,et,tt,nt,it,ot,[1,"content"],[1,"title"],[1,"left"],[1,"right"],[1,"themes"],["src","assets/images/light-theme.png","alt","light theme",3,"click"],["src","assets/images/dark-theme.png","alt","dark theme",3,"click"],[1,"right","passphrase-form"],[1,"actions"],["value","value","label","label",3,"options","isClearable","inlineSearch"],["type","text",3,"ngModelChange","ngModel","ngModelOptions"],[1,"right","buttons"],["shButton","",1,"primary",3,"click"],[1,"right","remote-access-form"],[1,"primary","raised",3,"click"],[1,"indeterminate","primary"],[1,"right","radios"],[1,"radio-option",3,"click"],[1,"primary","raised"],[1,"field-row"],[1,"raised","primary",3,"unit"],["type","range",3,"ngModelChange","min","max","disabled","ngModel","ngModelOptions"],["label","label","value","value",3,"options","isClearable"],["type","text",3,"ngModelChange","ngModel"],[1,"advanced-settings"],[1,"right","multiple"],["suffix","",3,"shTooltip"],["for","password"],["type","password","name","password","autocomplete","disabled","placeholder",Xe,"tabindex","1",3,"ngModelChange","ngModel"],["for","repeatPassword"],["type","password","name","repeatPassword","autocomplete","disabled","placeholder",ze,"tabindex","2",3,"ngModelChange","disabled","ngModel"],["suffix","",1,"sh-success"],["suffix",""],["shButton","",3,"click"],["shButton","",1,"raised","primary",3,"loading"],["shButton","","shTooltip",ie,1,"raised","primary",3,"loading","disabled"],["shButton","",1,"raised","primary",3,"click"],["shButton","","shTooltip",ie,1,"raised","primary",3,"click","disabled"],[1,"sh-success"],["for","allowedHostnames"],["type","text","id","allowedHostnames",3,"ngModelChange","ngModel"],["type","primary"],["value","value","label","label",3,"options","isClearable"],["href","https://usage-reporter.duplicati.com/","target","_blank"],["label","label","value","value",3,"options","isLoading"]]},template:function(e,i){if(e&1&&(m(0,"app-status-bar"),s(1,"div",59)(2,"header")(3,"div",60)(4,"h2"),_(5,0),o(),s(6,"p"),_(7,1),o()()(),C(8,ln,10,2),s(9,"section")(10,"div",61)(11,"h3"),_(12,2),o(),s(13,"p"),_(14,3),o()(),s(15,"div",62)(16,"div",63)(17,"img",64),d("click",function(){return i.setLightMode()}),o(),s(18,"img",65),d("click",function(){return i.setDarkMode()}),o()()()(),s(19,"section")(20,"div",61)(21,"h3"),_(22,4),o(),s(23,"p"),_(24,5),o()(),s(25,"div",66),C(26,cn,15,7)(27,Cn,4,1,"div",67),o()(),s(28,"section")(29,"div",61)(30,"h3"),_(31,6),o(),s(32,"p"),_(33,7),o()(),s(34,"div",62)(35,"sh-select",68)(36,"input",69),d("ngModelChange",function(T){return i.updateLocale(T)}),o()()()(),s(37,"section")(38,"div",61)(39,"h3"),_(40,8),o(),s(41,"p"),_(42,9),o()(),s(43,"div",70)(44,"button",71),d("click",function(){return i.openLegacyUI()}),O(45,10),m(46,"sh-icon"),h(),o(),s(47,"button",71),d("click",function(){return i.changeDefaultClientTo(i.defaultClient()==="ngclient"?"ngax":"ngclient")}),O(48,11),m(49,"sh-icon"),C(50,gn,2,0,"span")(51,En,2,0,"span"),h(),o()()(),s(52,"section")(53,"div",61)(54,"h3"),_(55,12),o(),s(56,"p"),_(57,13),o()(),s(58,"div",72)(59,"sh-toggle",73),d("click",function(){return i.updateRemoteAccess()}),s(60,"label"),_(61,14),o()(),C(62,un,8,3),o()(),s(63,"section")(64,"div",61)(65,"h3"),_(66,15),o(),s(67,"p"),_(68,16),o()(),s(69,"div",62)(70,"sh-toggle",73),d("click",function(){return i.saveDisableTrayIconLogin()}),s(71,"label"),_(72,17),o()()()(),C(73,pn,9,5,"section"),s(74,"section")(75,"div",61)(76,"h3"),_(77,18),o(),C(78,Nn,2,1,"p"),C(79,mn,1,0,"sh-progress-bar",74),o(),s(80,"div",75)(81,"div",76),d("click",function(){return i.setNewChannel("")}),s(82,"sh-radio",77),_(83,19),o(),s(84,"p"),_(85,20),o()(),s(86,"div",76),d("click",function(){return i.setNewChannel("stable")}),s(87,"sh-radio",77),_(88,21),o(),s(89,"p"),_(90,22),o()(),s(91,"div",76),d("click",function(){return i.setNewChannel("beta")}),s(92,"sh-radio",77),_(93,23),o(),s(94,"p"),_(95,24),o()(),s(96,"div",76),d("click",function(){return i.setNewChannel("experimental")}),s(97,"sh-radio",77),_(98,25),o(),s(99,"p"),_(100,26),o()(),s(101,"div",76),d("click",function(){return i.setNewChannel("canary")}),s(102,"sh-radio",77),_(103,27),o(),s(104,"p"),_(105,28),o()()()(),s(106,"section")(107,"div",61)(108,"h3"),_(109,29),o(),s(110,"p"),_(111,30),o()(),s(112,"div",62)(113,"div",78)(114,"sh-range-slider",79)(115,"input",80),L("ngModelChange",function(T){return y(i.timeValue,T)||(i.timeValue=T),T}),d("ngModelChange",function(T){return i.updateTimeValue(T)}),o()(),s(116,"sh-select",81)(117,"input",82),d("ngModelChange",function(T){return i.updateTimeType(T)}),o(),oe(118,fn,1,1,"ng-template"),o()()()(),C(119,Pn,17,5,"section"),o(),m(120,"sh-divider"),s(121,"div",59)(122,"section")(123,"div",83)(124,"h3"),_(125,31),o(),m(126,"app-advanced-options-settings"),o()()(),m(127,"sh-divider")),e&2){let a,T,f;l(8),g(i.isUsingRelay()?-1:8),l(9),I("active",!i.isDarkMode()),l(),I("active",i.isDarkMode()),l(8),g(i.showPassphraseForm()?26:27),l(9),N("options",i.languageOptions())("isClearable",!1)("inlineSearch",!0),l(),N("ngModel",i.langCtrl())("ngModelOptions",J(42,ne)),l(14),g(i.defaultClient()==="ngax"?50:51),l(9),I("active",i.allowRemoteAccess()),l(3),g(i.allowRemoteAccess()?62:-1),l(8),I("active",i.disableTrayIconLogin()),l(3),g(i.powerModeOptions().length>0?73:-1),l(5),g((a=i.sysinfo())!=null&&a.ServerVersion?78:-1),l(),g(i.updatingChannel()?79:-1),l(3),I("active",i.updateChannel()===""),l(),V((T=i.sysinfo())==null?null:T.DefaultUpdateChannel),U(83),l(2),V((f=i.sysinfo())==null?null:f.ServerVersionType),U(85),l(2),I("active",i.updateChannel()==="stable"),l(5),I("active",i.updateChannel()==="beta"),l(5),I("active",i.updateChannel()==="experimental"),l(5),I("active",i.updateChannel()==="canary"),l(12),N("unit",i.timeType()==="none"?"s":i.timeType()),l(),N("min",i.timeRange()[0])("max",i.timeRange()[1])("disabled",i.timeType()==="none"),A("ngModel",i.timeValue),N("ngModelOptions",J(43,ne)),l(),N("options",i.timeTypeOptions())("isClearable",!1),l(),N("ngModel",i.timeType()),l(2),g(i.usageStatisticsDisabled()?-1:119)}},dependencies:[K,W,pt,q,j,Q,At,te,X,D,Pt,Mt,It,ht,Rt,Z,w,ft,Y,Ot],styles:["[_nghost-%COMP%]{display:block}.content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:0 2rem 2rem}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:2rem 0;background:var(--base-1);border-bottom:1px solid var(--base-4)}header[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}section[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem;padding:2rem 0;border-top:1px solid var(--base-4)}@media only screen and (max-width:768px){section[_ngcontent-%COMP%]{grid-template-columns:1fr}}section[_ngcontent-%COMP%]:first-of-type{border-top:0}section[_ngcontent-%COMP%] .left[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem;align-items:flex-start}section[_ngcontent-%COMP%] .left[_ngcontent-%COMP%] sh-button-group[_ngcontent-%COMP%]{margin-top:.25rem}section[_ngcontent-%COMP%] .left[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-wrap:balance;width:50%}.passphrase-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:flex-start;gap:1rem}.passphrase-form[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.remote-access-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.themes[_ngcontent-%COMP%]{display:flex;gap:.5rem}.themes[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{max-width:15rem;border-radius:var(--shape-3);cursor:pointer}.themes[_ngcontent-%COMP%] img.active[_ngcontent-%COMP%]{border:2px solid var(--primary-8)}.radios[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.radio-option[_ngcontent-%COMP%]{cursor:pointer}.radio-option[_ngcontent-%COMP%] sh-radio[_ngcontent-%COMP%]{color:var(--base-8);margin-bottom:.25rem}.radio-option[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-wrap:balance;color:var(--base-9)}.field-col[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.field-row[_ngcontent-%COMP%]{display:flex;gap:.5rem;width:100%}.field-row[_ngcontent-%COMP%] sh-form-field[_ngcontent-%COMP%], .field-row[_ngcontent-%COMP%] sh-select[_ngcontent-%COMP%]{flex:1 0}.advanced-settings[_ngcontent-%COMP%]{grid-column:1/-1;display:grid;grid-template-columns:auto 1fr;gap:1rem}.right.buttons[_ngcontent-%COMP%]{display:flex;flex-direction:row;gap:1rem}.right.multiple[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}"],changeDetection:0})};export{Mn as debounceSignal,le as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{b as q}from"./chunk-I2HYK2BL.js";import{a as j}from"./chunk-B35WNLRM.js";import{a as Q}from"./chunk-SLS3DCJP.js";import{a as H}from"./chunk-I4XRVBRQ.js";import{B as V,L as z,O as J,Y as X,v as U}from"./chunk-YCLTQEU6.js";import{ha as K}from"./chunk-OQ6BKP5N.js";import{Ab as d,Bb as a,Cb as s,Db as g,Ec as F,Fc as $,Gc as G,Ic as L,Kb as N,Pc as _,Ra as o,Rb as T,Sb as P,Tb as b,Ub as R,Vb as v,Vc as w,Xb as B,Z as C,Zb as r,ca as x,da as h,eb as O,gc as M,hc as D,ic as I,jb as k,lc as l,mc as A,nc as m,oa as S,qa as E,ub as p,vb as c,yc as y}from"./chunk-ERITO7WM.js";function Y(e,i){if(e&1&&l(0),e&2){let t=r(3);m(" ",t.statusData().actionText," - ")}}function Z(e,i){e&1&&(a(0,"sh-icon"),l(1,"check"),s())}function tt(e,i){e&1&&(a(0,"sh-icon"),l(1,"copy"),s())}function et(e,i){if(e&1){let t=N();a(0,"div",9)(1,"button",10),B("click",function(u){x(t);let f=r(4);return h(f.copyToClipboard(u,f.tooltipText()))}),p(2,Z,2,0,"sh-icon")(3,tt,2,0,"sh-icon"),l(4," Copy "),s(),a(5,"p",11),l(6),s()()}if(e&2){let t=r(4);o(),d("color",t.copied()?"success":null),o(),c(t.copied()===!0?2:3),o(4),A(t.tooltipText())}}function it(e,i){if(e&1&&(a(0,"div",8),l(1),s(),k(2,et,7,3,"ng-template",null,0,L)),e&2){let t=M(3),n=r(3);d("shTooltip",t),o(),m(" ",n.statusData().fileStatusText," ")}}function nt(e,i){if(e&1&&(a(0,"div"),p(1,Y,1,1),l(2),s(),p(3,it,4,2),g(4,"sh-progress-bar",7)),e&2){let t,n=r(2);o(),c(n.backupId()===null?1:-1),o(),m(" ",n.statusData().statusText," "),o(),c((t=n.statusData())!=null&&t.BackendFileSize?3:-1),o(),d("value",n.statusData().progress*100)}}function ot(e,i){if(e&1&&(a(0,"div",5),T(1,1),g(2,"sh-icon"),F(3,"relativeTime"),F(4,"date"),P(),s()),e&2){let t,n=r(2);o(4),R((t=n.nextBackup().backup)==null||t.Backup==null?null:t.Backup.Name)($(3,3,n.nextBackup().time))(G(4,5,n.nextBackup().time,"shortTime")),v(1)}}function at(e,i){e&1&&(a(0,"div",5),b(1,2),s())}function st(e,i){e&1&&(a(0,"div",6),T(1,3),g(2,"sh-spinner"),P(),s()),e&2&&(o(2),D("--spinner-size","12px")("--spinner-thickness","2px"))}function rt(e,i){if(e&1&&(a(0,"div",4),p(1,nt,5,4)(2,ot,5,8,"div",5)(3,at,2,0,"div",5)(4,st,3,4,"div",6),s()),e&2){let t,n=r();o(),c(n.isActive()?1:!n.backupId()&&(n.nextBackup().backup||n.nextBackup().time)?2:!n.backupId()&&!((t=n.serverState())!=null&&t.ActiveTask)?3:n.backupId()?-1:4)}}var W=class e{backupId=w(null);#t=C(q);#e=C(j);statusData=this.#t.statusData;serverState=this.#t.serverState;isActive=_(()=>this.#t.runningBackupId()!==null);isTargetRunningTask=_(()=>{let i=this.backupId();return i?String(this.#t.runningBackupId())===String(i):!0});isVisible=_(()=>this.backupId()?this.isActive()?this.isTargetRunningTask():!1:!0);nextBackup=_(()=>{let i=this.#e.backups();return{backup:this.serverState()?.ProposedSchedule?.[0]?.backup,time:this.serverState()?.ProposedSchedule?.[0]?.Item2}});tooltipText=_(()=>{let i=this.statusData();return i?.CurrentFilename?`${i.CurrentFilename}`:""});copied=S(!1);copiedTimeout;copyToClipboard(i,t){i.stopPropagation(),navigator.clipboard.writeText(t),this.copied.set(!0),this.copiedTimeout=setTimeout(()=>{this.copied.set(!1)},2e3)}tooltipTrigger=S(!0);tooltipTriggerEffect=E(()=>{this.tooltipText(),this.tooltipTrigger.update(i=>!i),this.copiedTimeout&&(clearTimeout(this.copiedTimeout),this.copiedTimeout=void 0,this.copied.set(!1))});static \u0275fac=function(t){return new(t||e)};static \u0275cmp=O({type:e,selectors:[["app-backup-progress"]],hostVars:2,hostBindings:function(t,n){t&2&&I("is-visible",n.isVisible())},inputs:{backupId:[1,"backupId"]},features:[y([H])],decls:1,vars:1,consts:()=>{let i;i=$localize` ${"\uFFFD0\uFFFD"}:INTERPOLATION: - ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:clock${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: ${"\uFFFD1\uFFFD"}:INTERPOLATION_1: at ${"\uFFFD2\uFFFD"}:INTERPOLATION_2: `;let t;t=$localize`No scheduled tasks`;let n;return n=$localize` Loading ${"\uFFFD#2\uFFFD"}:START_TAG_SH_SPINNER:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_SPINNER:`,[["fileStatusTooltip",""],i,t,n,[1,"progress-section"],[1,"label"],[1,"label","label-loading"],[1,"raised","primary",3,"value"],[1,"file-status-text",3,"shTooltip"],[1,"tooltip-status-content"],["shButton","","size","small",3,"click","color"],[1,"tooltip-file-status-text"]]},template:function(t,n){t&1&&p(0,rt,5,1,"div",4),t&2&&c(n.isVisible()?0:-1)},dependencies:[U,V,J,z,X,Q,K],styles:["[_nghost-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:100%;gap:.5rem}[_nghost-%COMP%]:not(.is-visible){display:none}.file-status-text[_ngcontent-%COMP%]{color:var(--base-8)}.file-status-text[_ngcontent-%COMP%]:empty{display:none}.tooltip-file-status-text[_ngcontent-%COMP%]{overflow-wrap:break-word;word-break:break-word;display:inline-block;margin-bottom:.25rem}.tooltip-status-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.25rem}.progress-section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:0;min-width:18.75rem;flex:1 0}.progress-section[_ngcontent-%COMP%] sh-progress-bar[_ngcontent-%COMP%]{margin-top:.25rem}app-status-bar[_nghost-%COMP%] sh-progress-bar[_ngcontent-%COMP%], app-status-bar [_nghost-%COMP%] sh-progress-bar[_ngcontent-%COMP%]{position:absolute;bottom:0;left:0;right:0;width:100%;max-width:initial;margin-top:0}.label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem}.label-loading[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:.25rem}"],changeDetection:0})};export{W as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{e as M}from"./chunk-
|
|
1
|
+
import{e as M}from"./chunk-LO5YNFFR.js";import{B as P}from"./chunk-YCLTQEU6.js";import"./chunk-2LSZ2I43.js";import{e as E}from"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{$b as m,Bb as i,Cb as a,Eb as r,Fb as l,Gb as c,Ra as C,Tb as d,Z as u,_b as h,eb as g,lc as T,ub as f,vb as O}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";var L=["*",[["","footer",""]]],v=["*","[footer]"],s=class t{static \u0275fac=function(e){return new(e||t)};static \u0275cmp=g({type:t,selectors:[["app-custom-card"]],ngContentSelectors:v,decls:11,vars:0,consts:[[1,"card"],["src","/assets/noise/auth-noise.svg",1,"noise"],[1,"header-title"],["src","/assets/duplicati/duplicati.svg","alt",""],[1,"bg"]],template:function(e,o){e&1&&(h(L),r(0,"div",0),c(1,"img",1),r(2,"header")(3,"div",2),c(4,"img",3),T(5," Duplicati "),l()(),r(6,"main"),m(7),r(8,"footer"),m(9,1),l()()(),c(10,"div",4))},styles:['[_nghost-%COMP%]{height:100vh;width:100vw;display:flex;align-items:center;justify-content:center;background-color:var(--base-2)}body.dark [_nghost-%COMP%] .card[_ngcontent-%COMP%]:before{background:radial-gradient(rgba(var(--primary-rgb-900),1),#0000 60%)}.card[_ngcontent-%COMP%]{max-width:30rem;width:100%;position:relative;z-index:100;background-color:var(--base-1);border-radius:var(--shape-5);box-shadow:var(--box-shadow-40);border:1px solid var(--base-3);overflow:hidden}.card[_ngcontent-%COMP%]:before{content:"";position:absolute;height:30rem;transform:translateY(-17.8125rem);left:0;right:0;z-index:-2;background:radial-gradient(rgb(from var(--primary-1) r g b/1),#0000 60%)}.card[_ngcontent-%COMP%] img.noise[_ngcontent-%COMP%]{position:absolute;height:30rem;width:100%;transform:translateY(-17.8125rem);left:0;right:0;z-index:-1;-webkit-mask-image:radial-gradient(#000,#0000 60%);mask-image:radial-gradient(#000,#0000 60%)}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;padding:2rem 2rem 0;gap:.75rem;position:relative;z-index:10}.header-title[_ngcontent-%COMP%]{font:var(--title-30);display:flex;align-items:center;gap:.625rem}.header-title[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{height:1.75rem;filter:drop-shadow(0 2px 3px rgba(0,0,0,.3))}main[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;padding:2rem;gap:2.5rem;position:relative;z-index:10}main[_ngcontent-%COMP%] footer[_ngcontent-%COMP%]{font:var(--paragraph-40);color:var(--base-9);text-align:center;text-wrap:balance}.bg[_ngcontent-%COMP%]{position:fixed;inset:0;width:100vw;height:100vh;background-image:url(/assets/backgrounds/base-bg.svg);background-size:cover;background-position:center;background-repeat:no-repeat}body.dark[_ngcontent-%COMP%] .bg[_ngcontent-%COMP%]{opacity:1}footer[_ngcontent-%COMP%]:empty{display:none}'],changeDetection:0})};function N(t,n){t&1&&(i(0,"h3"),d(1,0),a())}function y(t,n){t&1&&(i(0,"h3"),d(1,1),a(),i(2,"button",3),d(3,2),a())}var p=class t{#e=u(M);isLoggingOut=this.#e.isLoggingOut;ngOnInit(){this.#e.logout()}static \u0275fac=function(e){return new(e||t)};static \u0275cmp=g({type:t,selectors:[["app-logout"]],decls:3,vars:1,consts:()=>{let n;n=$localize`Logging out...`;let e;e=$localize`You have successfully logged out your being redirected to login page.`;let o;return o=$localize`Go to login page`,[n,e,o,["shButton","","routerLink","/",1,"raised","primary"]]},template:function(e,o){e&1&&(i(0,"app-custom-card"),f(1,N,2,0,"h3")(2,y,4,0),a()),e&2&&(C(),O(o.isLoggingOut()?1:2))},dependencies:[s,P,E],styles:["[_nghost-%COMP%]{display:block}"],changeDetection:0})};export{p as default};
|