@duplicati/ngclient 0.0.157 → 0.0.158
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/s3compat.png +0 -0
- package/assets/sh.woff2 +0 -0
- package/{chunk-UXOJBG6Z.js → chunk-2IE65QDC.js} +1 -1
- package/{chunk-FPVRHFKW.js → chunk-363K6H7I.js} +1 -1
- package/{chunk-2GCNISUZ.js → chunk-3AGOCPNZ.js} +1 -1
- package/chunk-6XXAHUOH.js +1 -0
- package/{chunk-YZNZ5RQI.js → chunk-BGKZFATT.js} +1 -1
- package/{chunk-VOLZIA33.js → chunk-BTJVI7MG.js} +1 -1
- package/chunk-CFN5U5PK.js +1 -0
- package/{chunk-F7PHZYZX.js → chunk-CUL5FHDH.js} +1 -1
- package/chunk-FMEVVC6D.js +7 -0
- package/chunk-HWCUMKYF.js +1 -0
- package/{chunk-OX4HQVUD.js → chunk-J2Y5AVUU.js} +1 -1
- package/chunk-JH4DRDIH.js +1 -0
- package/{chunk-DILTD4XG.js → chunk-JRDR23NB.js} +1 -1
- package/chunk-KSEFQ2XA.js +1 -0
- package/chunk-L3RU4D2N.js +1 -0
- package/{chunk-IB6ESS57.js → chunk-LANFQDZE.js} +1 -1
- package/{chunk-DBQGZZI2.js → chunk-M6SIMFCD.js} +1 -1
- package/chunk-MSX2SJC7.js +1 -0
- package/{chunk-BSMAYTZR.js → chunk-NC73IOHK.js} +1 -1
- package/chunk-O4WI3VDE.js +1 -0
- package/{chunk-YC5FPDJH.js → chunk-RADP6NAN.js} +1 -1
- package/{chunk-GYDGMSUA.js → chunk-U4U2GCS5.js} +1 -1
- package/chunk-X3XJ26NZ.js +2 -0
- package/{chunk-UDF726AD.js → chunk-XH5CTH3O.js} +1 -1
- package/{chunk-ZGC3K2EK.js → chunk-XHITDSWR.js} +1 -1
- package/{chunk-USX4C3JC.js → chunk-Y75ZS4Q2.js} +1 -1
- package/{chunk-LTQOZB7Q.js → chunk-YHOYPGPD.js} +1 -1
- package/{chunk-Q3BXXS7G.js → chunk-ZKX6JJ6S.js} +1 -1
- package/{chunk-CAJEHCFP.js → chunk-ZWO4SECL.js} +1 -1
- package/index.html +1 -1
- package/{main-UHBWCAT4.js → main-ATSCYMRN.js} +1 -1
- package/package.json +1 -1
- package/chunk-2AVDJBM7.js +0 -1
- package/chunk-3N6V4QBS.js +0 -1
- package/chunk-4NLJRM5D.js +0 -1
- package/chunk-6NY5MUS6.js +0 -1
- package/chunk-E7Y6L3W6.js +0 -1
- package/chunk-NRUGLQRY.js +0 -1
- package/chunk-P4SN4J3W.js +0 -1
- package/chunk-SJ3V6DON.js +0 -2
- package/chunk-TWMGET5I.js +0 -7
- package/chunk-VVVEOA35.js +0 -1
|
Binary file
|
package/assets/sh.woff2
CHANGED
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as v}from"./chunk-TPBZNCDW.js";import{h as C}from"./chunk-
|
|
1
|
+
import{a as v}from"./chunk-TPBZNCDW.js";import{h as C}from"./chunk-KSEFQ2XA.js";import"./chunk-VUKS2SJL.js";import"./chunk-3NFAL4U4.js";import"./chunk-4VY6SMSL.js";import{b as h}from"./chunk-Z27IQRKV.js";import"./chunk-RDCD2W2C.js";import{a as G}from"./chunk-TJIZJNCK.js";import"./chunk-ZSZLXWN6.js";import"./chunk-72HORZFV.js";import"./chunk-6Q6SSTBK.js";import"./chunk-MTQKK2WN.js";import"./chunk-LN26XMBJ.js";import"./chunk-XVWOVBC4.js";import"./chunk-WXF4HUYT.js";import{b as N,c as O,e as B,f as b}from"./chunk-ABYM5HWA.js";import"./chunk-Z35OG2DV.js";import{K as M,L as $,Q as I}from"./chunk-QF4DQYEP.js";import{h as L}from"./chunk-PD73DDOS.js";import"./chunk-I2LW33GO.js";import"./chunk-5ZSBXGHQ.js";import"./chunk-FPPZ4BUR.js";import"./chunk-JYWOYPSQ.js";import{$b as D,Ac as E,Cb as d,Db as s,Dc as _,Eb as u,F as f,Fb as r,Rc as k,Sa as n,Tb as c,Ub as p,_ as l,cb as R,nc as A,pc as P,xb as T,yb as g}from"./chunk-QONLYWYC.js";import"./chunk-EUDKD2JW.js";var y=(a,e)=>[a,e,"general"],U=(a,e)=>[a,e,"destination"],K=(a,e)=>[a,e,"source-data"],w=(a,e)=>[a,e,"schedule"],H=(a,e)=>[a,e,"options"];function J(a,e){if(a&1&&(s(0,"p"),A(1),u()),a&2){let t=D();n(),P("Editing: ",t.backupName())}}function X(a,e){a&1&&r(0,"sh-progress-bar",7)}function x(a,e){a&1&&(s(0,"section"),r(1,"router-outlet"),u())}var m=class a{#t=l(N);#e=l(C);#a=l(G);#i=l(L);isDraft=this.#e.isDraft;isNew=this.#e.isNew;backupId=this.#e.backupId;backupName=this.#e.backupName;finishedLoading=this.#e.finishedLoading;#o=h(this.#t.params);#n=h(this.#t.url);paramsChanged=k(()=>{let e=this.#o()?.id,t=!!this.#n()?.find(i=>i.path==="backup-draft");this.#e.backupId.set(e),e!=="new"?this.getBackup(e,t):this.getDefaults()});getDefaults(){this.#i.getApiV1Backupdefaults().pipe(f(1)).subscribe({next:e=>{let t=e.Backup;t.Settings=[...t.Settings],this.#e.mapGeneralToForm(t),this.#e.mapDestinationToForm(t),this.#e.mapSourceDataToForm(t),this.#e.mapScheduleToForm(e.Schedule),this.#e.mapOptionsToForms(t),this.#e.applicationOptions.set(e.ApplicationOptions),this.#e.backupDefaults.set(e),this.#e.finishedLoading.set(!0)}})}getBackup(e,t=!1){let i=o=>{this.#e.mapScheduleToForm(o.Schedule??null),o.Backup&&(this.#e.mapGeneralToForm(o.Backup),this.#e.mapDestinationToForm(o.Backup),this.#e.mapSourceDataToForm(o.Backup),this.#e.mapOptionsToForms(o.Backup),this.#e.storeMetadata(o.Backup,t)),this.#e.finishedLoading.set(!0)};if(t){this.isDraft.set(t);let o=this.#a.draftBackups().find(F=>F.id===e);if(!o){alert("Backup not found");return}i(o.data)}else this.#i.getApiV1BackupById({id:e}).subscribe({next:i})}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=R({type:a,selectors:[["app-backup"]],features:[E([C])],decls:21,vars:22,consts:()=>{let e;e=$localize`${"\uFFFD#6\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#6\uFFFD"}:CLOSE_TAG_SH_RADIO: General `;let t;t=$localize`${"\uFFFD#9\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SH_RADIO: Destination `;let i;i=$localize`${"\uFFFD#12\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SH_RADIO: Source Data `;let o;o=$localize`${"\uFFFD#15\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#15\uFFFD"}:CLOSE_TAG_SH_RADIO: Schedule `;let F;return F=$localize`${"\uFFFD#18\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#18\uFFFD"}:CLOSE_TAG_SH_RADIO: Options `,[e,t,i,o,F,[1,"primary"],["step","","routerLinkActive","active",3,"routerLink"],[1,"indeterminate","primary"]]},template:function(t,i){t&1&&(r(0,"app-status-bar"),s(1,"header"),T(2,J,2,1,"p"),s(3,"sh-stepper",5)(4,"div",6),c(5,0),r(6,"sh-radio"),p(),u(),s(7,"div",6),c(8,1),r(9,"sh-radio"),p(),u(),s(10,"div",6),c(11,2),r(12,"sh-radio"),p(),u(),s(13,"div",6),c(14,3),r(15,"sh-radio"),p(),u(),s(16,"div",6),c(17,4),r(18,"sh-radio"),p(),u()()(),T(19,X,1,0,"sh-progress-bar",7)(20,x,2,0,"section")),t&2&&(n(2),g(i.isNew()?-1:2),n(2),d("routerLink",_(7,y,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),d("routerLink",_(10,U,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),d("routerLink",_(13,K,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),d("routerLink",_(16,w,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),d("routerLink",_(19,H,i.isDraft()?"/backup-draft":"/backup",i.backupId())),n(3),g(i.finishedLoading()?20:19))},dependencies:[O,B,b,v,$,I,M],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;height:100%}header[_ngcontent-%COMP%]{padding:1rem 1.5rem;border-bottom:1px solid var(--base-4)}header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin-bottom:.5rem}header[_ngcontent-%COMP%] sh-stepper[_ngcontent-%COMP%]{width:100%}section[_ngcontent-%COMP%]{width:100%;display:flex;justify-content:center;flex:1 0;overflow-x:hidden;overflow-y:auto;-webkit-overflow-scrolling:auto}"],changeDetection:0})};export{m as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as Ke}from"./chunk-TPBZNCDW.js";import{a as Xe}from"./chunk-3NFAL4U4.js";import{b as Je,c as ce}from"./chunk-Z27IQRKV.js";import"./chunk-RDCD2W2C.js";import{a as Ue}from"./chunk-TJIZJNCK.js";import"./chunk-ZSZLXWN6.js";import"./chunk-72HORZFV.js";import"./chunk-6Q6SSTBK.js";import"./chunk-MTQKK2WN.js";import{a as Z}from"./chunk-LN26XMBJ.js";import"./chunk-XVWOVBC4.js";import"./chunk-WXF4HUYT.js";import{b as ye,e as xe}from"./chunk-ABYM5HWA.js";import"./chunk-Z35OG2DV.js";import{B as se,E as Be,F as be,K as Fe,T as ke,u as H}from"./chunk-QF4DQYEP.js";import{h as de}from"./chunk-PD73DDOS.js";import"./chunk-I2LW33GO.js";import{la as V,oa as re}from"./chunk-5ZSBXGHQ.js";import"./chunk-FPPZ4BUR.js";import{a as ee}from"./chunk-UCS5RU7N.js";import"./chunk-JYWOYPSQ.js";import{$b as C,Ab as b,Bb as k,Cb as z,Db as o,Eb as i,Fb as s,Fc as u,Gc as m,Hc as S,Ic as h,Jb as G,Kb as P,Mb as U,Qc as ve,Sa as a,Tb as L,Ub as N,Vb as l,Wb as d,Wc as le,Xb as c,Yb as R,Zb as I,_ as x,cb as X,ea as D,fa as M,kc as $,nc as E,oc as K,pa as A,pc as f,qc as Ie,r as J,rc as $e,vc as fe,wc as he,xb as g,xc as w,yb as T,zb as B}from"./chunk-QONLYWYC.js";import{a as _e}from"./chunk-EUDKD2JW.js";function Ve(n,t){n&1&&s(0,"sh-progress-bar",32)}function He(n,t){n&1&&s(0,"div",35)}function je(n,t){n&1&&s(0,"div",35)}function We(n,t){n&1&&s(0,"div",36)}function qe(n,t){n&1&&s(0,"div",37)}function Qe(n,t){if(n&1&&(o(0,"details",46)(1,"summary"),L(2,15),s(3,"sh-icon"),o(4,"div",47),s(5,"sh-icon",40),i(),N(),i(),o(6,"div",48)(7,"p"),l(8,16),u(9,"date"),i(),o(10,"p"),l(11,17),u(12,"date"),i(),o(13,"p"),l(14,18),u(15,"durationFormat"),i(),o(16,"p"),l(17,19),i(),s(18,"sh-divider"),o(19,"p"),l(20,20),i(),o(21,"p"),l(22,21),i()()(),o(23,"details",46)(24,"summary"),L(25,22),s(26,"sh-icon"),o(27,"div",47),s(28,"sh-icon",40),i(),N(),i(),o(29,"div",48)(30,"p"),l(31,23),u(32,"date"),i(),o(33,"p"),l(34,24),u(35,"date"),i(),o(36,"p"),l(37,25),u(38,"durationFormat"),i(),s(39,"sh-divider"),o(40,"p"),l(41,26),u(42,"bytes"),i(),o(43,"p"),l(44,27),u(45,"bytes"),i(),o(46,"p"),l(47,28),u(48,"bytes"),i(),s(49,"sh-divider"),o(50,"p"),l(51,29),i(),o(52,"p"),l(53,30),i()()()),n&2){let e=C(2).$implicit;a(9),d(S(9,17,e.data==null||e.data.TestResults==null?null:e.data.TestResults.BeginTime,"medium")),c(8),a(3),d(S(12,20,e.data==null||e.data.TestResults==null?null:e.data.TestResults.EndTime,"medium")),c(11),a(3),d(m(15,23,e.data==null||e.data.TestResults==null?null:e.data.TestResults.Duration)),c(14),a(2),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.VerificationsActualLength),c(17),a(3),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.WarningsActualLength),c(20),a(2),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.ErrorsActualLength),c(22),a(10),d(S(32,25,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.BeginTime,"medium")),c(31),a(3),d(S(35,28,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.EndTime,"medium")),c(34),a(3),d(m(38,31,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.Duration)),c(37),a(4),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DeletedFileCount)(h(42,33,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DeletedFileSize,!0,!0)),c(41),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DownloadedFileCount)(h(45,37,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DownloadedFileSize,!0,!0)),c(44),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.UploadedFileCount)(h(48,41,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.UploadedFileSize,!0,!0)),c(47),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.WarningsActualLength),c(51),a(2),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.ErrorsActualLength),c(53)}}function Ye(n,t){if(n&1&&(o(0,"code"),E(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),K(m(2,1,e))}}function Ze(n,t){if(n&1&&(o(0,"details",46)(1,"summary"),L(2,31),s(3,"sh-icon"),o(4,"div",47),s(5,"sh-icon",40),i(),N(),i(),o(6,"div",48),b(7,Ye,3,3,"code",null,B),i()()),n&2){let e=C(2).$implicit;a(5),d(e.data.VerificationsActualLength),c(2),a(2),k(e.data.Verifications)}}function en(n,t){if(n&1&&(o(0,"code"),E(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),K(m(2,1,e))}}function nn(n,t){n&1&&(o(0,"p"),E(1,"No errors"),i())}function tn(n,t){if(n&1&&(o(0,"code"),E(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),K(m(2,1,e))}}function on(n,t){if(n&1&&(o(0,"section",41)(1,"app-toggle-card",42),G(2,43),o(3,"h3"),l(4,0),i(),P(),G(5,44),o(6,"p"),l(7,1),u(8,"date"),i(),o(9,"p"),l(10,2),u(11,"date"),i(),o(12,"p"),l(13,3),u(14,"durationFormat"),i(),P(),i(),o(15,"app-toggle-card",42),G(16,43),o(17,"h3"),l(18,4),i(),P(),G(19,44),o(20,"p"),l(21,5),u(22,"bytes"),i(),o(23,"p"),l(24,6),u(25,"bytes"),i(),o(26,"p"),l(27,7),u(28,"bytes"),i(),o(29,"p"),l(30,8),u(31,"bytes"),i(),o(32,"p"),l(33,9),i(),o(34,"p"),l(35,10),i(),o(36,"p"),l(37,11),i(),P(),i(),o(38,"div",45),s(39,"sh-divider"),g(40,Qe,54,45),g(41,Ze,9,1,"details",46),o(42,"details",46)(43,"summary"),L(44,12),s(45,"sh-icon"),o(46,"div",47),s(47,"sh-icon",40),i(),N(),i(),o(48,"div",48),b(49,en,3,3,"code",null,B),i()(),o(51,"details",46)(52,"summary"),L(53,13),s(54,"sh-icon"),o(55,"div",47),s(56,"sh-icon",40),i(),N(),i(),o(57,"div",48),g(58,nn,2,0,"p"),b(59,tn,3,3,"code",null,B),i()(),s(61,"sh-divider"),o(62,"details")(63,"summary"),L(64,14),s(65,"sh-icon"),o(66,"div",47),s(67,"sh-icon",40),i(),N(),i(),o(68,"code")(69,"button",49),E(70,"Copy"),i(),E(71),u(72,"json"),i()()()()),n&2){let e=C().$implicit;a(),z("disallowToggle",!0),a(7),d(S(8,22,e.data==null?null:e.data.BeginTime,"medium")),c(7),a(3),d(S(11,25,e.data==null?null:e.data.EndTime,"medium")),c(10),a(3),d(m(14,28,e.data==null?null:e.data.Duration)),c(13),a(),z("disallowToggle",!0),a(7),d(e.data==null?null:e.data.ExaminedFiles)(h(22,30,e.data==null?null:e.data.SizeOfExaminedFiles,!0,!0)),c(21),a(3),d(e.data==null?null:e.data.OpenedFiles)(h(25,34,e.data==null?null:e.data.SizeOfOpenedFiles,!0,!0)),c(24),a(3),d(e.data==null?null:e.data.AddedFiles)(h(28,38,e.data==null?null:e.data.SizeOfAddedFiles,!0,!0)),c(27),a(3),d(e.data==null?null:e.data.ModifiedFiles)(h(31,42,e.data==null?null:e.data.SizeOfModifiedFiles,!0,!0)),c(30),a(2),d(e.data==null?null:e.data.DeletedFiles),c(33),a(2),d(e.data==null?null:e.data.TooLargeFiles),c(35),a(2),d(e.data==null?null:e.data.FilesWithError),c(37),a(3),T(e.data!=null&&e.data.TestResults?40:-1),a(),T((e.data==null?null:e.data.MainOperation)==="Test"?41:-1),a(6),d(e.data==null?null:e.data.WarningsActualLength),c(44),a(2),k(e.data==null?null:e.data.Warnings),a(7),d(e.data==null?null:e.data.ErrorsActualLength),c(53),a(2),T((e.data==null||e.data.Errors==null?null:e.data.Errors.length)===0?58:-1),a(),k(e.data==null?null:e.data.Errors),a(12),f(" ",m(72,46,e.data)," ")}}function an(n,t){if(n&1){let e=U();o(0,"article",33)(1,"header",34),I("click",function(){let r=D(e).$implicit,p=C();return M(p.toggleOpenEntry(r.id))}),g(2,He,1,0,"div",35)(3,je,1,0,"div",35)(4,We,1,0,"div",36)(5,qe,1,0,"div",37),o(6,"h3"),E(7),u(8,"date"),i(),o(9,"p"),E(10),i(),s(11,"div",38),o(12,"div",39)(13,"sh-icon",40),E(14,"caret-down"),i()()(),g(15,on,73,48,"section",41),i()}if(n&2){let e=t.$implicit,_=C(),r=(e.data==null?null:e.data.ParsedResult)||"Unknown";a(2),T(r=="Fatal"?2:r=="Error"?3:r=="Warning"?4:5),a(5),K(S(8,7,e.timestamp,"medium")),a(3),Ie(" ",e.data==null?null:e.data.MainOperation," ",_.getLocalizedSummary(e)," "),a(3),$("open",e.id===_.openEntry()),a(2),T(e.id===_.openEntry()?15:-1)}}var ue=class n{#e=x(de);#n=new Z;#t=new ee;backupId=le.required();openEntry=A(null);pagination=A({offset:0,pagesize:100});resource=ce({params:()=>_e({id:this.backupId()},this.pagination()),stream:({params:t})=>this.#e.getApiV1BackupByIdLog({id:t.id,pagesize:100}).pipe(J(e=>e.map(_=>({id:_.ID,operationId:_.OperationID,timestamp:_.Timestamp*1e3,type:_.Type,data:JSON.parse(_.Message),exception:JSON.stringify(_.Exception)==="{}"?null:_.Exception}))))});getLocalizedSummary(t){let e=t.data?.ErrorsActualLength??0,_=t.data?.WarningsActualLength??0,r=[];if(t.data?.MainOperation=="Backup"){if(t.data?.Duration){let p=this.#t.transform(t.data?.Duration,!0);p.startsWith("0h ")&&(p=p.slice(3)),p.startsWith("0m ")&&(p=p.slice(3)),r.push($localize`took ${p}`)}t.data?.BackendStatistics?.BytesUploaded&&r.push($localize`uploaded ${this.#n.transform(t.data?.BackendStatistics?.BytesUploaded)}`),t.data?.BackendStatistics?.KnownFileSize&&r.push($localize`backup size ${this.#n.transform(t.data?.BackendStatistics?.KnownFileSize)}`)}return e!==0&&r.push($localize`:@@errorCount:${e} error${e===1?"":"s"}`),_!==0&&r.push($localize`:@@warningCount:${_} warning${_===1?"":"s"}`),r.length===0?"":`(${r.join(", ")})`}toggleOpenEntry(t){if(this.openEntry()===t){this.openEntry.set(null);return}this.openEntry.set(t)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=X({type:n,selectors:[["app-general-log"]],inputs:{backupId:[1,"backupId"]},decls:3,vars:1,consts:()=>{let t;t=$localize`Time`;let e;e=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let _;_=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let r;r=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let p;p=$localize`Source files`;let v;v=$localize` Evaluated: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let y;y=$localize`Opened: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let j;j=$localize`Added: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let W;W=$localize` Modified: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let q;q=$localize`Deleted: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Q;Q=$localize`Too large: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Y;Y=$localize`Files with error: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let O;O=$localize`${"\uFFFD#45\uFFFD"}:START_TAG_SH_ICON:warning-circle${"[\uFFFD/#45\uFFFD|\uFFFD/#47\uFFFD]"}:CLOSE_TAG_SH_ICON: Warnings ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#46\uFFFD"}:START_TAG_DIV:${"\uFFFD#47\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#45\uFFFD|\uFFFD/#47\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#46\uFFFD"}:CLOSE_TAG_DIV:`,O=R(O);let ne;ne=$localize`${"\uFFFD#54\uFFFD"}:START_TAG_SH_ICON:warning${"[\uFFFD/#54\uFFFD|\uFFFD/#56\uFFFD]"}:CLOSE_TAG_SH_ICON: Errors ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#55\uFFFD"}:START_TAG_DIV:${"\uFFFD#56\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#54\uFFFD|\uFFFD/#56\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#55\uFFFD"}:CLOSE_TAG_DIV:`,ne=R(ne);let te;te=$localize`${"\uFFFD#65\uFFFD"}:START_TAG_SH_ICON:notepad${"[\uFFFD/#65\uFFFD|\uFFFD/#67\uFFFD]"}:CLOSE_TAG_SH_ICON: Complete log ${"\uFFFD#66\uFFFD"}:START_TAG_DIV:${"\uFFFD#67\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#65\uFFFD|\uFFFD/#67\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#66\uFFFD"}:CLOSE_TAG_DIV:`,te=R(te);let ie;ie=$localize`${"\uFFFD#3\uFFFD"}:START_TAG_SH_ICON:circle-half-tilt${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON: Test phase ${"\uFFFD#4\uFFFD"}:START_TAG_DIV:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_DIV:`,ie=R(ie);let Ce;Ce=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let ge;ge=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Te;Te=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Oe;Oe=$localize`Verifications: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let me;me=$localize`Warnings: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Le;Le=$localize`Errors: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let oe;oe=$localize`${"\uFFFD#26\uFFFD"}:START_TAG_SH_ICON:file-archive${"[\uFFFD/#26\uFFFD|\uFFFD/#28\uFFFD]"}:CLOSE_TAG_SH_ICON: Compact phase ${"\uFFFD#27\uFFFD"}:START_TAG_DIV:${"\uFFFD#28\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#26\uFFFD|\uFFFD/#28\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#27\uFFFD"}:CLOSE_TAG_DIV:`,oe=R(oe);let Ne;Ne=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Se;Se=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Ge;Ge=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Pe;Pe=$localize` Deleted files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let Ae;Ae=$localize` Downloaded files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let Re;Re=$localize` Uploaded files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let De;De=$localize`Warnings: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Me;Me=$localize`Errors: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let ae;return ae=$localize`${"\uFFFD#3\uFFFD"}:START_TAG_SH_ICON:warning-circle${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON: Verifications ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#4\uFFFD"}:START_TAG_DIV:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_DIV:`,ae=R(ae),[t,e,_,r,p,v,y,j,W,q,Q,Y,O,ne,te,ie,Ce,ge,Te,Oe,me,Le,oe,Ne,Se,Ge,Pe,Ae,Re,De,Me,ae,[1,"indeterminate","primary"],[1,"log-entry"],[3,"click"],[1,"status","error"],[1,"status","warn"],[1,"status"],[1,"spacer"],[1,"action"],[1,"toggle-indicator"],[1,"log-content"],[3,"disallowToggle"],["title",""],["content",""],[1,"extra-info"],["name","details"],[1,"actions"],[1,"content"],["shButton","",1,"small"]]},template:function(e,_){e&1&&(g(0,Ve,1,0,"sh-progress-bar",32),b(1,an,16,10,"article",33,B)),e&2&&(T(_.resource.isLoading()?0:-1),a(),k(_.resource.value()))},dependencies:[Xe,be,Fe,se,H,Z,V,ee,re],styles:["[_nghost-%COMP%]{display:block}.log-entry[_ngcontent-%COMP%]{display:flex;flex-direction:column;cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;padding:1rem;border-bottom:1px solid var(--base-4);background-color:var(--base-1);cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]:hover{background-color:var(--base-2)}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-30);margin:0}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.toggle-indicator[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:1.25rem;transition:transform 125ms linear}.toggle-indicator.open[_ngcontent-%COMP%]{transform:rotate(180deg)}details[_ngcontent-%COMP%]{display:flex;flex-direction:column}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]{cursor:pointer;display:flex;align-items:center;gap:.5rem;padding:.75rem;border-radius:var(--shape-2);background-color:var(--base-2)}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]:focus{outline:none}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]:hover{background-color:var(--base-3)}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]::marker{font-size:0}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;flex:1 0;gap:.5rem;-webkit-user-select:none;user-select:none}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:2rem;transition:transform 125ms linear}details[open][_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{transform:rotate(180deg)}details[_ngcontent-%COMP%] .content[_ngcontent-%COMP%]{padding:.75rem 1rem 0;display:flex;flex-direction:column;gap:.75rem}details[_ngcontent-%COMP%] .content[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0}details[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{margin-top:.75rem;position:relative}details[_ngcontent-%COMP%] code[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{position:absolute;top:.75rem;right:.75rem}.extra-info[_ngcontent-%COMP%]{grid-column:1/-1;display:flex;flex-direction:column;gap:1rem}.extra-info[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;margin-bottom:.75rem}.extra-info[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{white-space:pre-wrap;padding:1rem;display:block;border-radius:var(--shape-2);background-color:var(--base-2)}.log-content[_ngcontent-%COMP%]{padding:1rem;display:grid;grid-template-columns:1fr 1fr;gap:1rem}.status[_ngcontent-%COMP%]{display:block;width:1rem;height:1rem;background-color:var(--success-8);border-radius:50%}.status.error[_ngcontent-%COMP%]{background-color:var(--error-8)}.status.warn[_ngcontent-%COMP%]{background-color:var(--warn-8)}"],changeDetection:0})};function _n(n,t){n&1&&s(0,"sh-progress-bar",1)}function ln(n,t){n&1&&(L(0,0,1),s(1,"sh-icon"),N())}function rn(n,t){n&1&&(L(0,0,2),s(1,"sh-icon"),N())}function sn(n,t){if(n&1){let e=U();o(0,"section",6)(1,"button",7),I("click",function(){D(e);let r=C(),p=r.$implicit,v=r.$index,y=C();return M(y.copyToClipboard(p.data,v))}),L(2,0),g(3,ln,2,0)(4,rn,2,0),N(),i(),o(5,"code"),E(6),u(7,"json"),i()()}if(n&2){let e=C(),_=e.$implicit,r=e.$index,p=C();a(),$("success",p.copiedFromIndex()===r),a(2),T(p.copiedFromIndex()===r?3:4),a(3),K(m(7,4,_.data))}}function Fn(n,t){if(n&1){let e=U();o(0,"article",2)(1,"header",3),I("click",function(){let r=D(e).$implicit,p=C();return M(p.toggleOpenEntry(r.id))}),o(2,"h3"),E(3),u(4,"date"),i(),o(5,"div",4)(6,"sh-icon",5),E(7,"caret-down"),i()()(),g(8,sn,8,6,"section",6),i()}if(n&2){let e=t.$implicit,_=C();a(3),$e("",S(4,6,e.timestamp,"medium"),": ",e.operation," ",e.path),a(3),$("open",e.id===_.openEntry()),a(2),T(e.id===_.openEntry()?8:-1)}}var pe=class n{#e=x(de);backupId=le.required();openEntry=A(null);pagination=A({offset:0,pagesize:100});copiedFromIndex=A(null);resource=ce({params:()=>_e({id:this.backupId()},this.pagination()),stream:({params:t})=>this.#e.getApiV1BackupByIdRemotelog({id:t.id,pagesize:100}).pipe(J(e=>e.map((_,r)=>({id:_.ID,operationId:_.OperationID,timestamp:_.Timestamp*1e3,operation:_.Operation,path:_.Path,data:typeof _.Data=="string"?JSON.parse(_.Data):null}))))});toggleOpenEntry(t){if(this.openEntry()===t){this.openEntry.set(null);return}this.openEntry.set(t)}copyToClipboard(t,e){let _=JSON.stringify(t,null,2);navigator.clipboard.writeText(_),this.copiedFromIndex.set(e),setTimeout(()=>{this.copiedFromIndex.set(null)},3e3)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=X({type:n,selectors:[["app-remote-log"]],inputs:{backupId:[1,"backupId"]},decls:3,vars:1,consts:()=>{let t;return t=$localize`${"\uFFFD*3: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: Copied ${"\uFFFD/*3:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*4: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: Copy to clipboard ${"\uFFFD/*4:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,t=R(t),[t,[1,"indeterminate","primary"],[1,"log-entry"],[3,"click"],[1,"actions"],[1,"toggle-indicator"],[1,"log-content"],["shButton","",1,"small",3,"click"]]},template:function(e,_){e&1&&(g(0,_n,1,0,"sh-progress-bar",1),b(1,Fn,9,9,"article",2,B)),e&2&&(T(_.resource.isLoading()?0:-1),a(),k(_.resource.value()))},dependencies:[Fe,H,re,V],styles:["[_nghost-%COMP%]{display:block}.log-entry[_ngcontent-%COMP%]{display:flex;flex-direction:column}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.5rem;padding:1rem;border-bottom:1px solid var(--base-4);background-color:var(--base-1);cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]:hover{background-color:var(--base-2)}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-30);margin:0;-webkit-user-select:none;user-select:none}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.toggle-indicator[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:1.25rem;transition:transform 125ms linear}.toggle-indicator.open[_ngcontent-%COMP%]{transform:rotate(180deg)}.log-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem;position:relative}.log-content[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{position:absolute;top:2rem;right:2rem;background:transparent}code[_ngcontent-%COMP%]{white-space:pre-wrap;padding:1rem;display:block;border-radius:var(--shape-2);background-color:var(--base-2)}"],changeDetection:0})};function dn(n,t){if(n&1&&(E(0," - "),G(1),l(2,6),P(),E(3),u(4,"durationFormat")),n&2){C(2);let e=w(6);a(3),f(" ",m(4,1,e.Backup.Metadata==null?null:e.Backup.Metadata.LastBackupDuration)," ")}}function cn(n,t){n&1&&(G(0),l(1,7),P())}function un(n,t){if(n&1&&(E(0),u(1,"bytes")),n&2){C(2);let e=w(6);f(" ",m(1,1,e.Backup.Metadata==null?null:e.Backup.Metadata.SourceFilesSize)," ")}}function pn(n,t){n&1&&(G(0),l(1,8),P())}function En(n,t){if(n&1&&(E(0),u(1,"bytes")),n&2){C(2);let e=w(6);f(" ",m(1,1,e.Backup.Metadata==null?null:e.Backup.Metadata.TargetFilesSize)," ")}}function Cn(n,t){n&1&&(G(0),l(1,9),P())}function gn(n,t){if(n&1&&(o(0,"sh-chip",19),l(1,10),i()),n&2){C(2);let e=w(6);a(),d(e.Backup.Metadata==null?null:e.Backup.Metadata.BackupListCount),c(1)}}function Tn(n,t){n&1&&(o(0,"sh-chip",20),l(1,11),i())}function On(n,t){if(n&1&&(o(0,"div",14)(1,"div",18)(2,"h3"),E(3),o(4,"sh-icon"),E(5,"database"),i()(),o(6,"p")(7,"span"),l(8,3),i(),E(9),u(10,"date"),g(11,dn,5,3)(12,cn,2,0,"ng-container"),i(),o(13,"p")(14,"span"),l(15,4),i(),g(16,un,2,3)(17,pn,2,0,"ng-container"),i(),o(18,"p")(19,"span"),l(20,5),i(),g(21,En,2,3)(22,Cn,2,0,"ng-container"),i()(),g(23,gn,2,1,"sh-chip",19)(24,Tn,2,0,"sh-chip",20),i()),n&2){let e=C(),_=w(6);a(3),f(" ",_.Backup.Name??e.MISSING_BACKUP_NAME," "),a(6),f(" ",S(10,6,_.Backup.Metadata==null?null:_.Backup.Metadata.LastBackupDate,"short")," "),a(2),T(_.Backup.Metadata!=null&&_.Backup.Metadata.LastBackupDuration?11:12),a(5),T(_.Backup.Metadata!=null&&_.Backup.Metadata.SourceFilesSize?16:17),a(5),T(_.Backup.Metadata!=null&&_.Backup.Metadata.TargetFilesSize?21:22),a(2),T(_.Backup.Metadata!=null&&_.Backup.Metadata.BackupListCount?23:24)}}function mn(n,t){if(n&1&&s(0,"app-general-log",17),n&2){let e=C();z("backupId",e.backupId())}}function Ln(n,t){if(n&1&&s(0,"app-remote-log",17),n&2){let e=C();z("backupId",e.backupId())}}var Ee=class n{#e=x(ye);#n=x(Ue);MISSING_BACKUP_NAME=$localize`Backup name missing`;activeTab=A("general");backupId=Je(this.#e.params.pipe(J(t=>t.id)));backup=ve(()=>{let t=this.backupId();return t?this.#n.getBackupById(t):null});static \u0275fac=function(e){return new(e||n)};static \u0275cmp=X({type:n,selectors:[["app-log"]],decls:15,vars:8,consts:()=>{let t;t=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON: Back `;let e;e=$localize`General`;let _;_=$localize` Destination `;let r;r=$localize`Last successful backup:`;let p;p=$localize`Source:`;let v;v=$localize`Destination:`;let y;y=$localize`took`;let j;j=$localize`N/A`;let W;W=$localize`N/A`;let q;q=$localize`N/A`;let Q;Q=$localize`${"\uFFFD0\uFFFD"}:INTERPOLATION: Version`;let Y;return Y=$localize`No version yet`,[t,e,_,r,p,v,y,j,W,q,Q,Y,[1,"back"],["type","button","shButton","","routerLink","/",1,"small"],[1,"backup"],[1,"primary"],["tab","",3,"click"],[3,"backupId"],[1,"text"],[1,"simple","success"],[1,"simple"]]},template:function(e,_){if(e&1){let r=U();s(0,"app-status-bar"),o(1,"section")(2,"div",12)(3,"button",13),L(4,0),s(5,"sh-icon"),N(),i()(),fe(6),g(7,On,25,9,"div",14),o(8,"sh-tabs",15)(9,"button",16),I("click",function(){return D(r),M(_.activeTab.set("general"))}),l(10,1),i(),o(11,"button",16),I("click",function(){return D(r),M(_.activeTab.set("destination"))}),l(12,2),i()(),g(13,mn,1,1,"app-general-log",17),g(14,Ln,1,1,"app-remote-log",17),i()}if(e&2){a(6);let r=he(_.backup());a(),T(r?7:-1),a(2),$("active",_.activeTab()==="general"),a(2),$("active",_.activeTab()==="destination"),a(2),T(_.activeTab()==="general"?13:-1),a(),T(_.activeTab()==="destination"?14:-1)}},dependencies:[ke,ue,pe,xe,Ke,H,se,Be,Z,ee,V],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem 1.5rem;gap:1rem}sh-tabs[_ngcontent-%COMP%]{margin-bottom:1rem}.backup[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:2rem;gap:1rem;border:1px solid var(--base-4);border-radius:var(--shape-3);box-shadow:var(--box-shadow-10)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;width:100%;max-width:40%}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] h3[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{color:var(--base-8)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] p[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{color:var(--base-12)}"],changeDetection:0})};export{Ee as default};
|
|
1
|
+
import{a as Je}from"./chunk-TPBZNCDW.js";import{a as Xe}from"./chunk-3NFAL4U4.js";import{b as Ke,c as ce}from"./chunk-Z27IQRKV.js";import"./chunk-RDCD2W2C.js";import{a as Ue}from"./chunk-TJIZJNCK.js";import"./chunk-ZSZLXWN6.js";import"./chunk-72HORZFV.js";import"./chunk-6Q6SSTBK.js";import"./chunk-MTQKK2WN.js";import{a as Z}from"./chunk-LN26XMBJ.js";import"./chunk-XVWOVBC4.js";import"./chunk-WXF4HUYT.js";import{b as ye,e as xe}from"./chunk-ABYM5HWA.js";import"./chunk-Z35OG2DV.js";import{B as se,E as Be,F as be,K as Fe,T as ke,u as H}from"./chunk-QF4DQYEP.js";import{h as de}from"./chunk-PD73DDOS.js";import"./chunk-I2LW33GO.js";import{la as V,oa as re}from"./chunk-5ZSBXGHQ.js";import"./chunk-FPPZ4BUR.js";import{a as ee}from"./chunk-UCS5RU7N.js";import"./chunk-JYWOYPSQ.js";import{$b as C,Ab as b,Bb as k,Cb as z,Db as o,Eb as i,Fb as s,Fc as u,Gc as m,Hc as S,Ic as h,Jb as G,Kb as P,Mb as U,Qc as ve,Sa as a,Tb as L,Ub as N,Vb as l,Wb as d,Wc as le,Xb as c,Yb as R,Zb as I,_ as x,cb as X,ea as D,fa as M,kc as $,nc as E,oc as K,pa as A,pc as f,qc as Ie,r as J,rc as $e,vc as fe,wc as he,xb as g,xc as w,yb as T,zb as B}from"./chunk-QONLYWYC.js";import{a as _e}from"./chunk-EUDKD2JW.js";function Ve(n,t){n&1&&s(0,"sh-progress-bar",32)}function He(n,t){n&1&&s(0,"div",35)}function je(n,t){n&1&&s(0,"div",35)}function We(n,t){n&1&&s(0,"div",36)}function qe(n,t){n&1&&s(0,"div",37)}function Qe(n,t){if(n&1&&(o(0,"details",46)(1,"summary"),L(2,15),s(3,"sh-icon"),o(4,"div",47),s(5,"sh-icon",40),i(),N(),i(),o(6,"div",48)(7,"p"),l(8,16),u(9,"date"),i(),o(10,"p"),l(11,17),u(12,"date"),i(),o(13,"p"),l(14,18),u(15,"durationFormat"),i(),o(16,"p"),l(17,19),i(),s(18,"sh-divider"),o(19,"p"),l(20,20),i(),o(21,"p"),l(22,21),i()()(),o(23,"details",46)(24,"summary"),L(25,22),s(26,"sh-icon"),o(27,"div",47),s(28,"sh-icon",40),i(),N(),i(),o(29,"div",48)(30,"p"),l(31,23),u(32,"date"),i(),o(33,"p"),l(34,24),u(35,"date"),i(),o(36,"p"),l(37,25),u(38,"durationFormat"),i(),s(39,"sh-divider"),o(40,"p"),l(41,26),u(42,"bytes"),i(),o(43,"p"),l(44,27),u(45,"bytes"),i(),o(46,"p"),l(47,28),u(48,"bytes"),i(),s(49,"sh-divider"),o(50,"p"),l(51,29),i(),o(52,"p"),l(53,30),i()()()),n&2){let e=C(2).$implicit;a(9),d(S(9,17,e.data==null||e.data.TestResults==null?null:e.data.TestResults.BeginTime,"medium")),c(8),a(3),d(S(12,20,e.data==null||e.data.TestResults==null?null:e.data.TestResults.EndTime,"medium")),c(11),a(3),d(m(15,23,e.data==null||e.data.TestResults==null?null:e.data.TestResults.Duration)),c(14),a(2),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.VerificationsActualLength),c(17),a(3),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.WarningsActualLength),c(20),a(2),d(e.data==null||e.data.TestResults==null?null:e.data.TestResults.ErrorsActualLength),c(22),a(10),d(S(32,25,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.BeginTime,"medium")),c(31),a(3),d(S(35,28,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.EndTime,"medium")),c(34),a(3),d(m(38,31,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.Duration)),c(37),a(4),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DeletedFileCount)(h(42,33,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DeletedFileSize,!0,!0)),c(41),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DownloadedFileCount)(h(45,37,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.DownloadedFileSize,!0,!0)),c(44),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.UploadedFileCount)(h(48,41,e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.UploadedFileSize,!0,!0)),c(47),a(3),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.WarningsActualLength),c(51),a(2),d(e.data==null||e.data.CompactResults==null?null:e.data.CompactResults.ErrorsActualLength),c(53)}}function Ye(n,t){if(n&1&&(o(0,"code"),E(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),K(m(2,1,e))}}function Ze(n,t){if(n&1&&(o(0,"details",46)(1,"summary"),L(2,31),s(3,"sh-icon"),o(4,"div",47),s(5,"sh-icon",40),i(),N(),i(),o(6,"div",48),b(7,Ye,3,3,"code",null,B),i()()),n&2){let e=C(2).$implicit;a(5),d(e.data.VerificationsActualLength),c(2),a(2),k(e.data.Verifications)}}function en(n,t){if(n&1&&(o(0,"code"),E(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),K(m(2,1,e))}}function nn(n,t){n&1&&(o(0,"p"),E(1,"No errors"),i())}function tn(n,t){if(n&1&&(o(0,"code"),E(1),u(2,"json"),i()),n&2){let e=t.$implicit;a(),K(m(2,1,e))}}function on(n,t){if(n&1&&(o(0,"section",41)(1,"app-toggle-card",42),G(2,43),o(3,"h3"),l(4,0),i(),P(),G(5,44),o(6,"p"),l(7,1),u(8,"date"),i(),o(9,"p"),l(10,2),u(11,"date"),i(),o(12,"p"),l(13,3),u(14,"durationFormat"),i(),P(),i(),o(15,"app-toggle-card",42),G(16,43),o(17,"h3"),l(18,4),i(),P(),G(19,44),o(20,"p"),l(21,5),u(22,"bytes"),i(),o(23,"p"),l(24,6),u(25,"bytes"),i(),o(26,"p"),l(27,7),u(28,"bytes"),i(),o(29,"p"),l(30,8),u(31,"bytes"),i(),o(32,"p"),l(33,9),i(),o(34,"p"),l(35,10),i(),o(36,"p"),l(37,11),i(),P(),i(),o(38,"div",45),s(39,"sh-divider"),g(40,Qe,54,45),g(41,Ze,9,1,"details",46),o(42,"details",46)(43,"summary"),L(44,12),s(45,"sh-icon"),o(46,"div",47),s(47,"sh-icon",40),i(),N(),i(),o(48,"div",48),b(49,en,3,3,"code",null,B),i()(),o(51,"details",46)(52,"summary"),L(53,13),s(54,"sh-icon"),o(55,"div",47),s(56,"sh-icon",40),i(),N(),i(),o(57,"div",48),g(58,nn,2,0,"p"),b(59,tn,3,3,"code",null,B),i()(),s(61,"sh-divider"),o(62,"details")(63,"summary"),L(64,14),s(65,"sh-icon"),o(66,"div",47),s(67,"sh-icon",40),i(),N(),i(),o(68,"code")(69,"button",49),E(70,"Copy"),i(),E(71),u(72,"json"),i()()()()),n&2){let e=C().$implicit;a(),z("disallowToggle",!0),a(7),d(S(8,22,e.data==null?null:e.data.BeginTime,"medium")),c(7),a(3),d(S(11,25,e.data==null?null:e.data.EndTime,"medium")),c(10),a(3),d(m(14,28,e.data==null?null:e.data.Duration)),c(13),a(),z("disallowToggle",!0),a(7),d(e.data==null?null:e.data.ExaminedFiles)(h(22,30,e.data==null?null:e.data.SizeOfExaminedFiles,!0,!0)),c(21),a(3),d(e.data==null?null:e.data.OpenedFiles)(h(25,34,e.data==null?null:e.data.SizeOfOpenedFiles,!0,!0)),c(24),a(3),d(e.data==null?null:e.data.AddedFiles)(h(28,38,e.data==null?null:e.data.SizeOfAddedFiles,!0,!0)),c(27),a(3),d(e.data==null?null:e.data.ModifiedFiles)(h(31,42,e.data==null?null:e.data.SizeOfModifiedFiles,!0,!0)),c(30),a(2),d(e.data==null?null:e.data.DeletedFiles),c(33),a(2),d(e.data==null?null:e.data.TooLargeFiles),c(35),a(2),d(e.data==null?null:e.data.FilesWithError),c(37),a(3),T(e.data!=null&&e.data.TestResults?40:-1),a(),T((e.data==null?null:e.data.MainOperation)==="Test"?41:-1),a(6),d(e.data==null?null:e.data.WarningsActualLength),c(44),a(2),k(e.data==null?null:e.data.Warnings),a(7),d(e.data==null?null:e.data.ErrorsActualLength),c(53),a(2),T((e.data==null||e.data.Errors==null?null:e.data.Errors.length)===0?58:-1),a(),k(e.data==null?null:e.data.Errors),a(12),f(" ",m(72,46,e.data)," ")}}function an(n,t){if(n&1){let e=U();o(0,"article",33)(1,"header",34),I("click",function(){let r=D(e).$implicit,p=C();return M(p.toggleOpenEntry(r.id))}),g(2,He,1,0,"div",35)(3,je,1,0,"div",35)(4,We,1,0,"div",36)(5,qe,1,0,"div",37),o(6,"h3"),E(7),u(8,"date"),i(),o(9,"p"),E(10),i(),s(11,"div",38),o(12,"div",39)(13,"sh-icon",40),E(14,"caret-down"),i()()(),g(15,on,73,48,"section",41),i()}if(n&2){let e=t.$implicit,_=C(),r=(e.data==null?null:e.data.ParsedResult)||"Unknown";a(2),T(r=="Fatal"?2:r=="Error"?3:r=="Warning"?4:5),a(5),K(S(8,7,e.timestamp,"medium")),a(3),Ie(" ",e.data==null?null:e.data.MainOperation," ",_.getLocalizedSummary(e)," "),a(3),$("open",e.id===_.openEntry()),a(2),T(e.id===_.openEntry()?15:-1)}}var ue=class n{#e=x(de);#n=new Z;#t=new ee;backupId=le.required();openEntry=A(null);pagination=A({offset:0,pagesize:100});resource=ce({params:()=>_e({id:this.backupId()},this.pagination()),stream:({params:t})=>this.#e.getApiV1BackupByIdLog({id:t.id,pagesize:100}).pipe(J(e=>e.map(_=>({id:_.ID,operationId:_.OperationID,timestamp:_.Timestamp*1e3,type:_.Type,data:JSON.parse(_.Message),exception:JSON.stringify(_.Exception)==="{}"?null:_.Exception}))))});getLocalizedSummary(t){let e=t.data?.ErrorsActualLength??0,_=t.data?.WarningsActualLength??0,r=[];if(t.data?.MainOperation=="Backup"){if(t.data?.Duration){let p=this.#t.transform(t.data?.Duration,!0);p.startsWith("0h ")&&(p=p.slice(3)),p.startsWith("0m ")&&(p=p.slice(3)),r.push($localize`took ${p}`)}t.data?.BackendStatistics?.BytesUploaded&&r.push($localize`uploaded ${this.#n.transform(t.data?.BackendStatistics?.BytesUploaded)}`),t.data?.BackendStatistics?.KnownFileSize&&r.push($localize`backup size ${this.#n.transform(t.data?.BackendStatistics?.KnownFileSize)}`)}return e!==0&&r.push($localize`:@@errorCount:${e} error${e===1?"":"s"}`),_!==0&&r.push($localize`:@@warningCount:${_} warning${_===1?"":"s"}`),r.length===0?"":`(${r.join(", ")})`}toggleOpenEntry(t){if(this.openEntry()===t){this.openEntry.set(null);return}this.openEntry.set(t)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=X({type:n,selectors:[["app-general-log"]],inputs:{backupId:[1,"backupId"]},decls:3,vars:1,consts:()=>{let t;t=$localize`Time`;let e;e=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let _;_=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let r;r=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let p;p=$localize`Source files`;let v;v=$localize` Evaluated: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let y;y=$localize`Opened: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let j;j=$localize`Added: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:)`;let W;W=$localize` Modified: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let q;q=$localize`Deleted: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Q;Q=$localize`Too large: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Y;Y=$localize`Files with error: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let O;O=$localize`${"\uFFFD#45\uFFFD"}:START_TAG_SH_ICON:warning-circle${"[\uFFFD/#45\uFFFD|\uFFFD/#47\uFFFD]"}:CLOSE_TAG_SH_ICON: Warnings ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#46\uFFFD"}:START_TAG_DIV:${"\uFFFD#47\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#45\uFFFD|\uFFFD/#47\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#46\uFFFD"}:CLOSE_TAG_DIV:`,O=R(O);let ne;ne=$localize`${"\uFFFD#54\uFFFD"}:START_TAG_SH_ICON:warning${"[\uFFFD/#54\uFFFD|\uFFFD/#56\uFFFD]"}:CLOSE_TAG_SH_ICON: Errors ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#55\uFFFD"}:START_TAG_DIV:${"\uFFFD#56\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#54\uFFFD|\uFFFD/#56\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#55\uFFFD"}:CLOSE_TAG_DIV:`,ne=R(ne);let te;te=$localize`${"\uFFFD#65\uFFFD"}:START_TAG_SH_ICON:notepad${"[\uFFFD/#65\uFFFD|\uFFFD/#67\uFFFD]"}:CLOSE_TAG_SH_ICON: Complete log ${"\uFFFD#66\uFFFD"}:START_TAG_DIV:${"\uFFFD#67\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#65\uFFFD|\uFFFD/#67\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#66\uFFFD"}:CLOSE_TAG_DIV:`,te=R(te);let ie;ie=$localize`${"\uFFFD#3\uFFFD"}:START_TAG_SH_ICON:circle-half-tilt${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON: Test phase ${"\uFFFD#4\uFFFD"}:START_TAG_DIV:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_DIV:`,ie=R(ie);let Ce;Ce=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let ge;ge=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Te;Te=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Oe;Oe=$localize`Verifications: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let me;me=$localize`Warnings: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Le;Le=$localize`Errors: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let oe;oe=$localize`${"\uFFFD#26\uFFFD"}:START_TAG_SH_ICON:file-archive${"[\uFFFD/#26\uFFFD|\uFFFD/#28\uFFFD]"}:CLOSE_TAG_SH_ICON: Compact phase ${"\uFFFD#27\uFFFD"}:START_TAG_DIV:${"\uFFFD#28\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#26\uFFFD|\uFFFD/#28\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#27\uFFFD"}:CLOSE_TAG_DIV:`,oe=R(oe);let Ne;Ne=$localize`Start: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Se;Se=$localize`End: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Ge;Ge=$localize`Duration: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Pe;Pe=$localize` Deleted files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let Ae;Ae=$localize` Downloaded files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let Re;Re=$localize` Uploaded files: ${"\uFFFD0\uFFFD"}:INTERPOLATION: (${"\uFFFD1\uFFFD"}:INTERPOLATION_1:) `;let De;De=$localize`Warnings: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Me;Me=$localize`Errors: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let ae;return ae=$localize`${"\uFFFD#3\uFFFD"}:START_TAG_SH_ICON:warning-circle${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON: Verifications ${"\uFFFD0\uFFFD"}:INTERPOLATION: ${"\uFFFD#4\uFFFD"}:START_TAG_DIV:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON_1:caret-down${"[\uFFFD/#3\uFFFD|\uFFFD/#5\uFFFD]"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_DIV:`,ae=R(ae),[t,e,_,r,p,v,y,j,W,q,Q,Y,O,ne,te,ie,Ce,ge,Te,Oe,me,Le,oe,Ne,Se,Ge,Pe,Ae,Re,De,Me,ae,[1,"indeterminate","primary"],[1,"log-entry"],[3,"click"],[1,"status","error"],[1,"status","warn"],[1,"status"],[1,"spacer"],[1,"action"],[1,"toggle-indicator"],[1,"log-content"],[3,"disallowToggle"],["title",""],["content",""],[1,"extra-info"],["name","details"],[1,"actions"],[1,"content"],["shButton","",1,"small"]]},template:function(e,_){e&1&&(g(0,Ve,1,0,"sh-progress-bar",32),b(1,an,16,10,"article",33,B)),e&2&&(T(_.resource.isLoading()?0:-1),a(),k(_.resource.value()))},dependencies:[Xe,be,Fe,se,H,Z,V,ee,re],styles:["[_nghost-%COMP%]{display:block}.log-entry[_ngcontent-%COMP%]{display:flex;flex-direction:column;cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;padding:1rem;border-bottom:1px solid var(--base-4);background-color:var(--base-1);cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]:hover{background-color:var(--base-2)}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-30);margin:0}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.toggle-indicator[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:1.25rem;transition:transform 125ms linear}.toggle-indicator.open[_ngcontent-%COMP%]{transform:rotate(180deg)}details[_ngcontent-%COMP%]{display:flex;flex-direction:column}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]{cursor:pointer;display:flex;align-items:center;gap:.5rem;padding:.75rem;border-radius:var(--shape-2);background-color:var(--base-2)}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]:focus{outline:none}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]:hover{background-color:var(--base-3)}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%]::marker{font-size:0}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;justify-content:flex-end;flex:1 0;gap:.5rem;-webkit-user-select:none;user-select:none}details[_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:2rem;transition:transform 125ms linear}details[open][_ngcontent-%COMP%] summary[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{transform:rotate(180deg)}details[_ngcontent-%COMP%] .content[_ngcontent-%COMP%]{padding:.75rem 1rem 0;display:flex;flex-direction:column;gap:.75rem}details[_ngcontent-%COMP%] .content[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0}details[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{margin-top:.75rem;position:relative}details[_ngcontent-%COMP%] code[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{position:absolute;top:.75rem;right:.75rem}.extra-info[_ngcontent-%COMP%]{grid-column:1/-1;display:flex;flex-direction:column;gap:1rem}.extra-info[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;margin-bottom:.75rem}.extra-info[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{white-space:pre-wrap;padding:1rem;display:block;border-radius:var(--shape-2);background-color:var(--base-2)}.log-content[_ngcontent-%COMP%]{padding:1rem;display:grid;grid-template-columns:1fr 1fr;gap:1rem}.status[_ngcontent-%COMP%]{display:block;width:1rem;height:1rem;background-color:var(--success-8);border-radius:50%}.status.error[_ngcontent-%COMP%]{background-color:var(--error-8)}.status.warn[_ngcontent-%COMP%]{background-color:var(--warn-8)}"],changeDetection:0})};function _n(n,t){n&1&&s(0,"sh-progress-bar",1)}function ln(n,t){n&1&&(L(0,0,1),s(1,"sh-icon"),N())}function rn(n,t){n&1&&(L(0,0,2),s(1,"sh-icon"),N())}function sn(n,t){if(n&1){let e=U();o(0,"section",6)(1,"button",7),I("click",function(){D(e);let r=C(),p=r.$implicit,v=r.$index,y=C();return M(y.copyToClipboard(p.data,v))}),L(2,0),g(3,ln,2,0)(4,rn,2,0),N(),i(),o(5,"code"),E(6),u(7,"json"),i()()}if(n&2){let e=C(),_=e.$implicit,r=e.$index,p=C();a(),$("success",p.copiedFromIndex()===r),a(2),T(p.copiedFromIndex()===r?3:4),a(3),K(m(7,4,_.data))}}function Fn(n,t){if(n&1){let e=U();o(0,"article",2)(1,"header",3),I("click",function(){let r=D(e).$implicit,p=C();return M(p.toggleOpenEntry(r.id))}),o(2,"h3"),E(3),u(4,"date"),i(),o(5,"div",4)(6,"sh-icon",5),E(7,"caret-down"),i()()(),g(8,sn,8,6,"section",6),i()}if(n&2){let e=t.$implicit,_=C();a(3),$e("",S(4,6,e.timestamp,"medium"),": ",e.operation," ",e.path),a(3),$("open",e.id===_.openEntry()),a(2),T(e.id===_.openEntry()?8:-1)}}var pe=class n{#e=x(de);backupId=le.required();openEntry=A(null);pagination=A({offset:0,pagesize:100});copiedFromIndex=A(null);resource=ce({params:()=>_e({id:this.backupId()},this.pagination()),stream:({params:t})=>this.#e.getApiV1BackupByIdRemotelog({id:t.id,pagesize:100}).pipe(J(e=>e.map((_,r)=>({id:_.ID,operationId:_.OperationID,timestamp:_.Timestamp*1e3,operation:_.Operation,path:_.Path,data:typeof _.Data=="string"?JSON.parse(_.Data):null}))))});toggleOpenEntry(t){if(this.openEntry()===t){this.openEntry.set(null);return}this.openEntry.set(t)}copyToClipboard(t,e){let _=JSON.stringify(t,null,2);navigator.clipboard.writeText(_),this.copiedFromIndex.set(e),setTimeout(()=>{this.copiedFromIndex.set(null)},3e3)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=X({type:n,selectors:[["app-remote-log"]],inputs:{backupId:[1,"backupId"]},decls:3,vars:1,consts:()=>{let t;return t=$localize`${"\uFFFD*3: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: Copied ${"\uFFFD/*3:1\uFFFD"}:CLOSE_BLOCK_IF:${"\uFFFD*4: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: Copy to clipboard ${"\uFFFD/*4:2\uFFFD"}:CLOSE_BLOCK_ELSE:`,t=R(t),[t,[1,"indeterminate","primary"],[1,"log-entry"],[3,"click"],[1,"actions"],[1,"toggle-indicator"],[1,"log-content"],["shButton","",1,"small",3,"click"]]},template:function(e,_){e&1&&(g(0,_n,1,0,"sh-progress-bar",1),b(1,Fn,9,9,"article",2,B)),e&2&&(T(_.resource.isLoading()?0:-1),a(),k(_.resource.value()))},dependencies:[Fe,H,re,V],styles:["[_nghost-%COMP%]{display:block}.log-entry[_ngcontent-%COMP%]{display:flex;flex-direction:column}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.5rem;padding:1rem;border-bottom:1px solid var(--base-4);background-color:var(--base-1);cursor:pointer}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%]:hover{background-color:var(--base-2)}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-30);margin:0;-webkit-user-select:none;user-select:none}.log-entry[_ngcontent-%COMP%] header[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.toggle-indicator[_ngcontent-%COMP%]{display:inline-flex;align-items:center;justify-content:center;height:1.25rem;transition:transform 125ms linear}.toggle-indicator.open[_ngcontent-%COMP%]{transform:rotate(180deg)}.log-content[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem;position:relative}.log-content[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{position:absolute;top:2rem;right:2rem;background:transparent}code[_ngcontent-%COMP%]{white-space:pre-wrap;padding:1rem;display:block;border-radius:var(--shape-2);background-color:var(--base-2)}"],changeDetection:0})};function dn(n,t){if(n&1&&(E(0," - "),G(1),l(2,6),P(),E(3),u(4,"durationFormat")),n&2){C(2);let e=w(6);a(3),f(" ",m(4,1,e.Backup.Metadata==null?null:e.Backup.Metadata.LastBackupDuration)," ")}}function cn(n,t){n&1&&(G(0),l(1,7),P())}function un(n,t){if(n&1&&(E(0),u(1,"bytes")),n&2){C(2);let e=w(6);f(" ",m(1,1,e.Backup.Metadata==null?null:e.Backup.Metadata.SourceFilesSize)," ")}}function pn(n,t){n&1&&(G(0),l(1,8),P())}function En(n,t){if(n&1&&(E(0),u(1,"bytes")),n&2){C(2);let e=w(6);f(" ",m(1,1,e.Backup.Metadata==null?null:e.Backup.Metadata.TargetFilesSize)," ")}}function Cn(n,t){n&1&&(G(0),l(1,9),P())}function gn(n,t){if(n&1&&(o(0,"sh-chip",19),l(1,10),i()),n&2){C(2);let e=w(6);a(),d(e.Backup.Metadata==null?null:e.Backup.Metadata.BackupListCount),c(1)}}function Tn(n,t){n&1&&(o(0,"sh-chip",20),l(1,11),i())}function On(n,t){if(n&1&&(o(0,"div",14)(1,"div",18)(2,"h3"),E(3),o(4,"sh-icon"),E(5,"database"),i()(),o(6,"p")(7,"span"),l(8,3),i(),E(9),u(10,"date"),g(11,dn,5,3)(12,cn,2,0,"ng-container"),i(),o(13,"p")(14,"span"),l(15,4),i(),g(16,un,2,3)(17,pn,2,0,"ng-container"),i(),o(18,"p")(19,"span"),l(20,5),i(),g(21,En,2,3)(22,Cn,2,0,"ng-container"),i()(),g(23,gn,2,1,"sh-chip",19)(24,Tn,2,0,"sh-chip",20),i()),n&2){let e=C(),_=w(6);a(3),f(" ",_.Backup.Name??e.MISSING_BACKUP_NAME," "),a(6),f(" ",S(10,6,_.Backup.Metadata==null?null:_.Backup.Metadata.LastBackupDate,"short")," "),a(2),T(_.Backup.Metadata!=null&&_.Backup.Metadata.LastBackupDuration?11:12),a(5),T(_.Backup.Metadata!=null&&_.Backup.Metadata.SourceFilesSize?16:17),a(5),T(_.Backup.Metadata!=null&&_.Backup.Metadata.TargetFilesSize?21:22),a(2),T(_.Backup.Metadata!=null&&_.Backup.Metadata.BackupListCount?23:24)}}function mn(n,t){if(n&1&&s(0,"app-general-log",17),n&2){let e=C();z("backupId",e.backupId())}}function Ln(n,t){if(n&1&&s(0,"app-remote-log",17),n&2){let e=C();z("backupId",e.backupId())}}var Ee=class n{#e=x(ye);#n=x(Ue);MISSING_BACKUP_NAME=$localize`Backup name missing`;activeTab=A("general");backupId=Ke(this.#e.params.pipe(J(t=>t.id)));backup=ve(()=>{let t=this.backupId();return t?this.#n.getBackupById(t):null});static \u0275fac=function(e){return new(e||n)};static \u0275cmp=X({type:n,selectors:[["app-log"]],decls:15,vars:8,consts:()=>{let t;t=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON: Back `;let e;e=$localize`General`;let _;_=$localize` Destination `;let r;r=$localize`Last successful backup:`;let p;p=$localize`Source:`;let v;v=$localize`Destination:`;let y;y=$localize`took`;let j;j=$localize`N/A`;let W;W=$localize`N/A`;let q;q=$localize`N/A`;let Q;Q=$localize`${"\uFFFD0\uFFFD"}:INTERPOLATION: Version`;let Y;return Y=$localize`No version yet`,[t,e,_,r,p,v,y,j,W,q,Q,Y,[1,"back"],["type","button","shButton","","routerLink","/",1,"small"],[1,"backup"],[1,"primary"],["tab","",3,"click"],[3,"backupId"],[1,"text"],[1,"simple","success"],[1,"simple"]]},template:function(e,_){if(e&1){let r=U();s(0,"app-status-bar"),o(1,"section")(2,"div",12)(3,"button",13),L(4,0),s(5,"sh-icon"),N(),i()(),fe(6),g(7,On,25,9,"div",14),o(8,"sh-tabs",15)(9,"button",16),I("click",function(){return D(r),M(_.activeTab.set("general"))}),l(10,1),i(),o(11,"button",16),I("click",function(){return D(r),M(_.activeTab.set("destination"))}),l(12,2),i()(),g(13,mn,1,1,"app-general-log",17),g(14,Ln,1,1,"app-remote-log",17),i()}if(e&2){a(6);let r=he(_.backup());a(),T(r?7:-1),a(2),$("active",_.activeTab()==="general"),a(2),$("active",_.activeTab()==="destination"),a(2),T(_.activeTab()==="general"?13:-1),a(),T(_.activeTab()==="destination"?14:-1)}},dependencies:[ke,ue,pe,xe,Je,H,se,Be,Z,ee,V],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;padding:1rem 1.5rem;gap:1rem}sh-tabs[_ngcontent-%COMP%]{margin-bottom:1rem}.backup[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:2rem;gap:1rem;border:1px solid var(--base-4);border-radius:var(--shape-3);box-shadow:var(--box-shadow-10)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;width:100%;max-width:40%}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] h3[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{color:var(--base-8)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{font:var(--paragraph-30);color:var(--base-8)}.backup[_ngcontent-%COMP%] .text[_ngcontent-%COMP%] p[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{color:var(--base-12)}"],changeDetection:0})};export{Ee as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{g as C}from"./chunk-
|
|
1
|
+
import{g as C}from"./chunk-M6SIMFCD.js";import"./chunk-JRDR23NB.js";import"./chunk-ZBVBVQO7.js";import"./chunk-X3XJ26NZ.js";import{a as w}from"./chunk-TPBZNCDW.js";import{h as k}from"./chunk-KSEFQ2XA.js";import"./chunk-VUKS2SJL.js";import"./chunk-3NFAL4U4.js";import"./chunk-4VY6SMSL.js";import{b as u}from"./chunk-Z27IQRKV.js";import"./chunk-RDCD2W2C.js";import"./chunk-TJIZJNCK.js";import"./chunk-ZSZLXWN6.js";import"./chunk-72HORZFV.js";import"./chunk-6Q6SSTBK.js";import"./chunk-MTQKK2WN.js";import"./chunk-LN26XMBJ.js";import"./chunk-XVWOVBC4.js";import"./chunk-WXF4HUYT.js";import{a as A,b as $,c as M,d as I,e as G,f as W}from"./chunk-ABYM5HWA.js";import"./chunk-Z35OG2DV.js";import{L as v,Q as y}from"./chunk-QF4DQYEP.js";import"./chunk-PD73DDOS.js";import"./chunk-I2LW33GO.js";import"./chunk-5ZSBXGHQ.js";import"./chunk-FPPZ4BUR.js";import"./chunk-JYWOYPSQ.js";import{$b as O,Ac as N,Bc as R,Cb as _,Cc as p,Db as i,Eb as n,Fb as s,Rc as L,Sa as r,Tb as F,Ub as l,_ as c,cb as P,kc as D,pa as f,xb as E,yb as g}from"./chunk-QONLYWYC.js";import"./chunk-EUDKD2JW.js";var b=()=>["/restore-from-files/destination"],x=()=>["/restore-from-files/encryption"],H=()=>["/restore-from-files/select-files"],J=()=>["/restore-from-files/options"],X=t=>["/restore",t,"select-files"],z=t=>["/restore",t,"options"];function B(t,o){t&1&&(i(0,"div",7),F(1,0),s(2,"sh-radio"),l(),n(),i(3,"div",7),F(4,1),s(5,"sh-radio"),l(),n(),i(6,"div",7),F(7,2),s(8,"sh-radio"),l(),n(),i(9,"div",7),F(10,3),s(11,"sh-radio"),l(),n()),t&2&&(_("routerLink",R(4,b)),r(3),_("routerLink",R(5,x)),r(3),_("routerLink",R(6,H)),r(3),_("routerLink",R(7,J)))}function U(t,o){if(t&1&&(i(0,"div",7),F(1,4),s(2,"sh-radio"),l(),n(),i(3,"div",7),F(4,5),s(5,"sh-radio"),l(),n()),t&2){let e=O(2);_("routerLink",p(2,X,e.backupId())),r(3),_("routerLink",p(4,z,e.backupId()))}}function j(t,o){if(t&1&&(i(0,"sh-stepper",6),E(1,B,12,8)(2,U,6,6),n()),t&2){let e=O();r(),g(e.isFileRestore()?1:2)}}var h=class t{#e=c($);#o=c(I);#t=c(C);#i=u(this.#e.params);#n=u(this.#e.url);#s=u(this.#e.children[0].url);backupId=this.#t.backupId;isFileRestore=this.#t.isFileRestore;isProgressPage=f(!1);paramsChanged=L(()=>{let o=this.#s(),e=this.#i()?.id,a=!!this.#n()?.find(S=>S.path==="restore-from-files"),T=!!o?.find(S=>S.path==="progress");this.isProgressPage.set(T),this.#t.init(e,a)});ngOnInit(){this.#o.events.subscribe(o=>{if(o instanceof A){let e=o.urlAfterRedirects;this.isProgressPage.set(e.includes("progress"))}})}static \u0275fac=function(e){return new(e||t)};static \u0275cmp=P({type:t,selectors:[["app-restore-flow"]],hostVars:2,hostBindings:function(e,a){e&2&&D("full-width",a.isProgressPage())},features:[N([C,k])],decls:4,vars:1,consts:()=>{let o;o=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_RADIO: Destination `;let e;e=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_RADIO: Encryption `;let a;a=$localize`${"\uFFFD#8\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#8\uFFFD"}:CLOSE_TAG_SH_RADIO: Select files `;let T;T=$localize`${"\uFFFD#11\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#11\uFFFD"}:CLOSE_TAG_SH_RADIO: Options `;let S;S=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_RADIO: Select files `;let m;return m=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_RADIO:${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_RADIO: Options `,[o,e,a,T,S,m,[1,"primary"],["step","","routerLinkActive","active",3,"routerLink"]]},template:function(e,a){e&1&&(s(0,"app-status-bar"),E(1,j,3,1,"sh-stepper",6),i(2,"section"),s(3,"router-outlet"),n()),e&2&&(r(),g(a.isProgressPage()?-1:1))},dependencies:[y,v,w,M,G,W],styles:["[_nghost-%COMP%]{display:block}.full-width[_nghost-%COMP%] section[_ngcontent-%COMP%]{max-width:62.5rem}sh-stepper[_ngcontent-%COMP%]{max-width:31.25rem;margin:2.5rem auto}section[_ngcontent-%COMP%]{max-width:31.25rem;margin:0 auto 2.5rem}"],changeDetection:0})};export{h as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as K}from"./chunk-TJIZJNCK.js";import"./chunk-ZSZLXWN6.js";import{a as z}from"./chunk-72HORZFV.js";import"./chunk-6Q6SSTBK.js";import"./chunk-MTQKK2WN.js";import"./chunk-XVWOVBC4.js";import"./chunk-WXF4HUYT.js";import{d as O,e as M}from"./chunk-ABYM5HWA.js";import"./chunk-Z35OG2DV.js";import{B as U,G as x,H as V,V as j,b as E,c as A,e as R,f as b,j as y,o as B,q as $,r as v,t as G,u as k,x as L,z as w}from"./chunk-QF4DQYEP.js";import{h as J}from"./chunk-PD73DDOS.js";import"./chunk-5ZSBXGHQ.js";import"./chunk-FPPZ4BUR.js";import{Bc as N,Cb as p,Db as a,Eb as n,Fb as u,H as g,Sa as l,Tb as D,Ub as h,Vb as _,Yb as I,Zb as d,_ as s,cb as f,kc as P,pa as c,xb as C,yb as S}from"./chunk-QONLYWYC.js";import"./chunk-EUDKD2JW.js";var X=()=>["/"];function H(m,o){m&1&&(a(0,"sh-form-field")(1,"label",14),_(2,3),n(),u(3,"input",15),n())}var F=new v,T=class m{#t=s(L);#o=s(w);#n=s(J);#i=s(K);#e=s(O);isImporting=c(!1);isSecureFile=c(!1);isValid=c(!1);importForm=F.group({config:F.control(""),cmdline:F.control(!1),import_metadata:F.control(!1),direct:F.control(!1),passphrase:F.control("")});selectedFile=c([]);onFileDropped(o){let e=o[0];if(e){let t=new FileReader;this.isSecureFile.set(e.type!=="application/json"),t.onload=this.#r.bind(this),t.readAsArrayBuffer(e)}}#r(o){let e=o.target?.result;this.isSecureFile.set(this.#a(e)!=="json"),this.importForm.patchValue({config:this.#s(e)}),this.isValid.set(this.importForm.value.config!=="")}#a(o){let e=new Uint8Array(o);if(e.length>=5&&e[0]===65&&e[1]===69&&e[2]===83&&e[4]===0)return"aes";try{let t=new TextDecoder().decode(o),i=JSON.parse(t);if(typeof i=="object"&&i!==null)return"json"}catch{}return"unknown"}#s(o){let e=new Uint8Array(o),t=e.byteLength,i="";for(let r=0;r<t;r++)i+=String.fromCharCode(e[r]);return btoa(i)}submit(){this.isImporting.set(!0);let o=this.importForm.value.direct??!1;this.#n.postApiV1BackupsImport({requestBody:this.importForm.value}).pipe(g(()=>this.isImporting.set(!1))).subscribe({next:e=>{if(o){this.#t.success("Backup imported successfully."),this.#e.navigate(["/"]);return}let t=this.#i.addDraftBackup(e.data);this.#e.navigate(["/backup-draft",t])},error:e=>{let t=e.message||$localize`Unknown error`;this.#o.open(z,{data:{title:$localize`Failed to import backup`,message:t,confirmText:$localize`OK`,cancelText:void 0}})}})}static \u0275fac=function(e){return new(e||m)};static \u0275cmp=f({type:m,selectors:[["app-import"]],decls:19,vars:8,consts:()=>{let o;o=$localize` Import backup configuration ${"\uFFFD#3\uFFFD"}:START_TAG_DIV:${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"[\uFFFD#5\uFFFD|\uFFFD#7\uFFFD]"}:START_TAG_SH_ICON:arrow-left${"[\uFFFD/#5\uFFFD|\uFFFD/#7\uFFFD]"}:CLOSE_TAG_SH_ICON: Back ${"[\uFFFD/#4\uFFFD|\uFFFD/#6\uFFFD]"}:CLOSE_TAG_BUTTON:${"\uFFFD#6\uFFFD"}:START_TAG_BUTTON_1:${"[\uFFFD#5\uFFFD|\uFFFD#7\uFFFD]"}:START_TAG_SH_ICON:download-simple${"[\uFFFD/#5\uFFFD|\uFFFD/#7\uFFFD]"}:CLOSE_TAG_SH_ICON: Import ${"[\uFFFD/#4\uFFFD|\uFFFD/#6\uFFFD]"}:CLOSE_TAG_BUTTON:${"\uFFFD/#3\uFFFD"}:CLOSE_TAG_DIV:`,o=I(o);let e;e=$localize`Import Metadata`;let t;t=$localize`Save now`;let i;return i=$localize`Passphrase`,[o,e,t,i,[1,"actions"],["shButton","","type","button",1,"outlined",3,"routerLink"],["shButton","","type","submit",1,"raised","primary",3,"click","disabled"],["autocomplete","off",3,"formGroup"],["accept",".json,.aes",3,"filesChange","files"],[1,"primary","raised"],["for","importMetadata"],["type","checkbox","formControlName","import_metadata"],["for","direct"],["type","checkbox","formControlName","direct"],["for","passphrase"],["type","password","formControlName","passphrase"]]},template:function(e,t){e&1&&(a(0,"header")(1,"h3"),D(2,0),a(3,"div",4)(4,"button",5),u(5,"sh-icon"),n(),a(6,"button",6),d("click",function(){return t.submit()}),u(7,"sh-icon"),n()(),h(),n()(),a(8,"form",7)(9,"sh-file-upload",8),d("filesChange",function(r){return t.onFileDropped(r)}),n(),C(10,H,4,0,"sh-form-field"),a(11,"sh-toggle",9)(12,"label",10),_(13,1),n(),u(14,"input",11),n(),a(15,"sh-toggle",9)(16,"label",12),_(17,2),n(),u(18,"input",13),n()()),e&2&&(l(4),p("routerLink",N(7,X)),l(2),P("loader",t.isImporting()),p("disabled",t.isImporting()||!t.isValid()),l(2),p("formGroup",t.importForm),l(),p("files",t.selectedFile()),l(),S(t.isSecureFile()?10:-1))},dependencies:[G,y,A,E,R,b,B,$,M,x,k,U,j,V],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:2rem;padding:3rem}h3[_ngcontent-%COMP%]{font:var(--title-30);display:flex;align-items:center;justify-content:space-between}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;max-width:31.25rem}sh-file-upload[_ngcontent-%COMP%]{width:100%}"],changeDetection:0})};export{T as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a,b}from"./chunk-
|
|
1
|
+
import{a,b}from"./chunk-M6SIMFCD.js";import"./chunk-JRDR23NB.js";import"./chunk-ZBVBVQO7.js";import"./chunk-X3XJ26NZ.js";import"./chunk-VUKS2SJL.js";import"./chunk-3NFAL4U4.js";import"./chunk-Z27IQRKV.js";import"./chunk-ZSZLXWN6.js";import"./chunk-72HORZFV.js";import"./chunk-MTQKK2WN.js";import"./chunk-LN26XMBJ.js";import"./chunk-WXF4HUYT.js";import"./chunk-ABYM5HWA.js";import"./chunk-Z35OG2DV.js";import"./chunk-QF4DQYEP.js";import"./chunk-PD73DDOS.js";import"./chunk-5ZSBXGHQ.js";import"./chunk-FPPZ4BUR.js";import"./chunk-QONLYWYC.js";import"./chunk-EUDKD2JW.js";export{a as createRestoreOptionsForm,b as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as a,e as b}from"./chunk-
|
|
1
|
+
import{d as a,e as b}from"./chunk-KSEFQ2XA.js";import"./chunk-VUKS2SJL.js";import"./chunk-3NFAL4U4.js";import"./chunk-4VY6SMSL.js";import"./chunk-Z27IQRKV.js";import"./chunk-72HORZFV.js";import"./chunk-6Q6SSTBK.js";import"./chunk-MTQKK2WN.js";import"./chunk-ABYM5HWA.js";import"./chunk-Z35OG2DV.js";import"./chunk-QF4DQYEP.js";import"./chunk-PD73DDOS.js";import"./chunk-5ZSBXGHQ.js";import"./chunk-FPPZ4BUR.js";import"./chunk-QONLYWYC.js";import"./chunk-EUDKD2JW.js";export{a as SCHEDULE_FIELD_DEFAULTS,b as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-EUDKD2JW.js";var o=[{path:"",redirectTo:"general",pathMatch:"full"},{path:"general",loadComponent:()=>import("./chunk-RADP6NAN.js")},{path:"destination",loadComponent:()=>import("./chunk-O4WI3VDE.js")},{path:"source-data",loadComponent:()=>import("./chunk-Y75ZS4Q2.js")},{path:"schedule",loadComponent:()=>import("./chunk-BTJVI7MG.js")},{path:"options",loadComponent:()=>import("./chunk-XH5CTH3O.js")}];export{o as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as
|
|
1
|
+
import{a as _e}from"./chunk-TPBZNCDW.js";import{a as le,b as m}from"./chunk-Z27IQRKV.js";import"./chunk-RDCD2W2C.js";import{a as se}from"./chunk-TJIZJNCK.js";import"./chunk-ZSZLXWN6.js";import{a as b}from"./chunk-72HORZFV.js";import"./chunk-6Q6SSTBK.js";import"./chunk-MTQKK2WN.js";import"./chunk-LN26XMBJ.js";import"./chunk-XVWOVBC4.js";import"./chunk-WXF4HUYT.js";import{b as q,e as j}from"./chunk-ABYM5HWA.js";import"./chunk-Z35OG2DV.js";import{B as ae,G as ie,X as ne,c as Q,e as Y,i as Z,s as x,u as ee,z as te}from"./chunk-QF4DQYEP.js";import{h as oe}from"./chunk-PD73DDOS.js";import"./chunk-I2LW33GO.js";import"./chunk-5ZSBXGHQ.js";import"./chunk-FPPZ4BUR.js";import"./chunk-JYWOYPSQ.js";import{Cb as d,D as G,Db as n,Eb as i,F as g,Fb as c,G as L,H as p,Qc as E,Rc as P,Sa as _,Tb as u,Ub as h,Vb as A,Wb as H,Xb as J,Zb as T,_ as C,cb as V,kc as F,mc as K,nc as D,pa as s,r as y,sc as X,tc as z,uc as W,xb as w,yb as U}from"./chunk-QONLYWYC.js";import"./chunk-EUDKD2JW.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=C(q);#s=C(se);#e=C(oe);#a=C(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()}).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: Restore (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),F("loader",e.isRepairing()),d("disabled",!e.isValidatedPath()||e.pathHasChanged()),_(3),F("loader",e.isDeleting()),d("disabled",!e.isValidatedPath()||e.pathHasChanged()),_(3),F("loader",e.isRestoring()),d("disabled",e.pathHasChanged()),_(3),F("loader",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,7 @@
|
|
|
1
|
+
import{a as ot}from"./chunk-ZBVBVQO7.js";import{a as K,b as Ze,c as Ye,e as et}from"./chunk-X3XJ26NZ.js";import{h as it}from"./chunk-KSEFQ2XA.js";import{a as tt,d as nt}from"./chunk-VUKS2SJL.js";import{a as Qe}from"./chunk-VRV52R6I.js";import{a as R}from"./chunk-72HORZFV.js";import{a as z}from"./chunk-MTQKK2WN.js";import{B as ue,G as Ke,J as Ue,K as Je,O as Xe,U as He,V as je,X as qe,a as Re,c as de,e as ce,i as pe,k as ke,s as me,t as Be,u as Ce,z as ze}from"./chunk-QF4DQYEP.js";import{h as We}from"./chunk-PD73DDOS.js";import{ea as Ge}from"./chunk-5ZSBXGHQ.js";import{$b as s,Ab as X,Ac as Le,Bb as H,Bc as Pe,Cb as m,Cc as se,Db as _,Eb as d,Ec as _e,Fb as ie,Jb as oe,Jc as q,Kb as j,Lb as ae,Mb as x,Qc as P,Rc as W,Sa as l,Tb as Ne,Ub as xe,V as te,Vb as De,Wc as Q,Xc as $e,Zb as N,Zc as be,_ as V,ac as we,bc as Oe,cb as ne,ea as T,f as ee,fa as S,gc as Ae,hb as G,hc as Me,ic as B,ja as ye,kc as re,nc as p,pa as b,pc as A,qc as le,sc as Ve,tc as Fe,uc as ve,vc as L,wc as O,xb as g,xc as c,yb as f,zb as J}from"./chunk-QONLYWYC.js";import{a as M,b as Y}from"./chunk-EUDKD2JW.js";var at=class n{#t=V(We);#e=V(ze);#n=V(z);testDestination(t,e,i,o){return this.#n.hasV2TestOperations()?this.testDestinationv2(t,e,i,o):this.testDestinationv1(t,e,i,o)}testDestinationv2(t,e,i,o){return new ee(a=>{this.#t.postApiV2DestinationTest({requestBody:{DestinationUrl:t,AutoCreate:!1,Options:null}}).subscribe({next:r=>{if(r.Success){this.emitSuccessV2(a,t,e,r);return}this.handleGenericError(a,t,e,r.Error??"Unknown error",o)},error:r=>{let C=r?.error?.body;if(C?.Data?.FolderExists===!1||C?.StatusCode==="missing-folder"){i?this.handleMissingFolder(a,t,e):this.handleGenericError(a,t,e,$localize`The remote destination folder does not exist.`,o);return}if(C?.Data?.HostCertificate){this.handleMissingCertificate(a,t,e,C.Data?.HostCertificate);return}if(C?.Data?.ReportedHostKey){this.handleIncorrectKey(a,t,e,C.Data.ReportedHostKey,C.Data.AcceptedHostKey??null);return}this.handleGenericError(a,t,e,r?.message??"Unknown error",o)}})})}testDestinationv1(t,e,i,o){return new ee(a=>{this.#t.postApiV1RemoteoperationTest({requestBody:{path:t}}).subscribe({next:r=>{a.next({action:"success",targetUrl:t,testAgain:!1,destinationIndex:e}),a.complete()},error:r=>{this.handleDestinationErrorv1(r.message,t,e,i,o).subscribe(C=>{a.next(C)})}})})}handleMissingFolder(t,e,i){this.#e.open(R,{data:{title:$localize`Create folder`,message:$localize`The remote destination folder does not exist, do you want to create it?`,confirmText:$localize`Create folder`,cancelText:$localize`Cancel`},closed:o=>{if(!o){this.reportNoAction(t,e,i,$localize`The remote folder does not exist.`);return}this.#n.hasV2TestOperations()?this.#t.postApiV2DestinationTest({requestBody:{DestinationUrl:e,AutoCreate:!0,Options:null}}).subscribe({next:a=>{if(a.Success){this.emitSuccessV2(t,e,i,a);return}else this.handleFolderCreateFailure(t,e,i,a.Error??$localize`Unknown error`)},error:a=>{this.handleFolderCreateFailure(t,e,i,a.message??$localize`Unknown error`)}}):this.#t.postApiV1RemoteoperationCreate({requestBody:{path:e}}).subscribe({next:()=>{this.handleFolderCreated(t,e,i)},error:a=>{this.handleFolderCreateFailure(t,e,i,a.message??$localize`Unknown error`)}})}})}handleFolderCreateFailure(t,e,i,o){this.#e.open(R,{data:{title:$localize`Error creating folder`,message:$localize`The remote destination folder could not be created. ${o}`,confirmText:$localize`OK`,cancelText:null},closed:()=>{t.next({action:"generic-error",targetUrl:e,testAgain:!1,destinationIndex:i}),t.complete()}})}emitSuccessV2(t,e,i,o){t.next({action:"success",targetUrl:e,testAgain:!1,destinationIndex:i,anyFilesFound:!o.Data?.FolderIsEmpty,containsBackup:o.Data?.FolderContainsBackupFiles??void 0,containsEncryptedBackupFiles:o.Data?.FolderContainsEncryptedBackupFiles??void 0}),t.complete()}handleFolderCreated(t,e,i){this.#e.open(R,{data:{title:$localize`Folder created`,message:$localize`The remote destination folder was created successfully.`,confirmText:$localize`OK`,cancelText:null},closed:()=>{t.next({action:"test-again",targetUrl:e,testAgain:!0,destinationIndex:i}),t.complete()}})}reportNoAction(t,e,i,o){t.next({action:"generic-error",targetUrl:e,errorMessage:o,testAgain:!1,destinationIndex:i}),t.complete()}handleMissingCertificate(t,e,i,o){this.#e.open(R,{maxWidth:"500px",data:{title:$localize`Trust the certificate`,message:$localize`The server is using a certificate that is not trusted.
|
|
2
|
+
If this is a self-signed certificate, you can choose to trust this certificate.
|
|
3
|
+
The server reported the certificate hash: ${o}`,confirmText:$localize`Trust the certificate`,cancelText:$localize`Cancel`},closed:a=>{if(!a){this.reportNoAction(t,e,i,$localize`The server certificate is not trusted.`);return}t.next({action:"trust-cert",targetUrl:e,testAgain:!0,certData:o,destinationIndex:i}),t.complete()}})}handleIncorrectKey(t,e,i,o,a){a?this.#e.open(R,{maxWidth:"500px",data:{title:$localize`The host key has changed`,message:$localize`The host key has changed, please check with the server administrator if this is correct,
|
|
4
|
+
otherwise you could be the victim of a MAN-IN-THE-MIDDLE attack.
|
|
5
|
+
Do you want to REPLACE your CURRENT host key ${a}
|
|
6
|
+
with the REPORTED host key: ${o}?`,confirmText:$localize`Approve`,cancelText:$localize`Cancel`},closed:r=>{if(!r){this.reportNoAction(t,e,i,$localize`The host key was not approved.`);return}t.next({action:"approve-host-key",targetUrl:e,testAgain:!0,reportedHostKey:o,destinationIndex:i}),t.complete()}}):this.#e.open(R,{maxWidth:"500px",data:{title:$localize`Approve host key?`,message:$localize`No certificate was specified, please verify that the reported host key is correct: ${o}`,confirmText:$localize`Approve`,cancelText:$localize`Cancel`},closed:r=>{if(!r){this.reportNoAction(t,e,i,$localize`The host key was not approved.`);return}t.next({action:"approve-host-key",targetUrl:e,testAgain:!0,reportedHostKey:o,destinationIndex:i}),t.complete()}})}handleGenericError(t,e,i,o,a){function r(){t.next({action:"generic-error",targetUrl:e,testAgain:!1,destinationIndex:i,errorMessage:o}),t.complete()}if(a){r();return}this.#e.open(R,{maxWidth:"500px",data:{title:$localize`Test connection failed`,message:o,cancelText:$localize`OK`},closed:C=>r()})}handleDestinationErrorv1(t,e,i,o,a){return new ee(r=>{if(t==="missing-folder"){o?this.handleMissingFolder(r,e,i):this.handleGenericError(r,e,i,$localize`The remote destination folder does not exist.`,a);return}if(t.startsWith("incorrect-cert:")){let C=t.split("incorrect-cert:")[1];this.handleMissingCertificate(r,e,i,C);return}if(t.startsWith("incorrect-host-key:")){let C=t.split('incorrect-host-key:"')[1].split('",')[0],E=t.split('accepted-host-key:"')[1].split('",')[0];this.handleIncorrectKey(r,e,i,C,E);return}this.handleGenericError(r,e,i,t,a)})}static \u0275fac=function(e){return new(e||n)};static \u0275prov=te({token:n,factory:n.\u0275fac,providedIn:"root"})};var ge=class n{#t=V(z);supportedDestinationTypes=P(()=>this.#t.backendModules().map(t=>{if(!t?.Key)return null;let e=K(t.Key);return e.isDefaultEntry===!0?Y(M({},e),{displayName:t.DisplayName||e.displayName||t.Key,description:t.Description||e.description||""}):e}).filter(t=>t!==null));destinationTypeOptions=P(()=>this.supportedDestinationTypes().map(t=>({key:t.customKey??t.key,customKey:t.customKey??null,displayName:t.displayName,description:t.description,icon:t.icon,searchTerms:[t.displayName,t.description,t.key,t.searchTerms??"",t.customKey??""].join(" "),sortOrder:t.sortOrder??0})));backendModules=P(()=>this.#t.backendModules()??[]);static \u0275fac=function(e){return new(e||n)};static \u0275prov=te({token:n,factory:n.\u0275fac,providedIn:"root"})};var _t=["fileInput"],dt=[[["label"]]],ct=["label"],fe=class n{customId=Q();content=b("");readonly=b(!1);placeholder=Q("Drop a file here or use the browse button");fileInputRef=$e("fileInput");onFileSelected(t){let e=t.target;e.files&&e.files.length>0&&this.readFile(e.files[0])}onFileDrop(t){t.preventDefault(),t.dataTransfer?.files&&t.dataTransfer.files.length>0&&this.readFile(t.dataTransfer.files[0])}onDragOver(t){t.preventDefault()}readFile(t){let e=new FileReader;e.onload=()=>{this.content.set(e.result)},e.readAsText(t)}triggerBrowse(){return this.fileInputRef()?.nativeElement.click(),!1}onChange=()=>{};onTouched=()=>{};onChangeEffect=W(()=>{this.onChange(this.content())});writeValue(t){this.content.set(t)}registerOnChange(t){this.onChange=t}registerOnTouched(t){this.onTouched=t}setDisabledState(t){this.readonly.set(t)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=ne({type:n,selectors:[["app-file-drop-textarea"]],viewQuery:function(e,i){e&1&&Ae(i.fileInputRef,_t,5),e&2&&Me()},inputs:{customId:[1,"customId"],placeholder:[1,"placeholder"]},features:[Le([{provide:Re,useExisting:n,multi:!0}])],ngContentSelectors:ct,decls:9,vars:3,consts:[["fileInput",""],[1,"browse-btn"],["shButton","","type","button",1,"small","outlined",3,"click"],[1,"textarea-container","textarea-wrap",3,"drop","dragover"],["rows","10",3,"ngModelChange","placeholder","ngModel","disabled"],["type","file",1,"hidden",3,"change"]],template:function(e,i){if(e&1){let o=x();we(dt),Oe(0,0,["ngProjectAs","label",5,["label"]]),_(1,"div",1)(2,"button",2),N("click",function(){return T(o),S(i.triggerBrowse())}),_(3,"sh-icon"),p(4,"upload"),d()()(),_(5,"div",3),N("drop",function(r){return T(o),S(i.onFileDrop(r))})("dragover",function(r){return T(o),S(i.onDragOver(r))}),_(6,"textarea",4),ve("ngModelChange",function(r){return T(o),Fe(i.content,r)||(i.content=r),S(r)}),d()(),_(7,"input",5,0),N("change",function(r){return T(o),S(i.onFileSelected(r))}),d()}e&2&&(l(6),m("placeholder",i.placeholder()),Ve("ngModel",i.content),m("disabled",i.readonly()))},dependencies:[me,de,ce,pe,Ce,ue],styles:['[_nghost-%COMP%]{display:grid;grid-template-areas:"label browsebtn" "input input";grid-template-columns:8fr 1fr;gap:.5rem;align-items:flex-end}[_nghost-%COMP%] .browse-btn[_ngcontent-%COMP%]{grid-area:browsebtn}[_nghost-%COMP%] .label[_ngcontent-%COMP%]{grid-area:label;grid-column:1/-1}[_nghost-%COMP%] .textarea-wrap[_ngcontent-%COMP%]{grid-area:input;width:100%;border:none;font:var(--code-20)}[_nghost-%COMP%] .textarea-wrap[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{width:100%;color:var(--base-8);background-color:var(--base-1);border:1px solid var(--base-4);border-radius:var(--shape-3);padding:.5rem;resize:vertical;box-shadow:var(--box-shadow-10)}[_nghost-%COMP%] .textarea-wrap[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%] .dark[_ngcontent-%COMP%]{background-color:var(--base-2)}[_nghost-%COMP%] .hidden[_ngcontent-%COMP%]{display:none}'],changeDetection:0})};var pt=(n,t,e,i)=>({index:n,fieldGroup:"custom",formView:t,destinationType:e,oauthField:i}),Ie=n=>({$implicit:n}),mt=(n,t,e,i)=>({index:n,fieldGroup:"dynamic",formView:t,destinationType:e,oauthField:i}),Ct=()=>({updateOn:"blur"}),ut=(n,t,e,i)=>({index:n,formView:t,fieldGroup:"advanced",destinationType:e,oauthField:i});function gt(n,t){n&1&&ae(0)}function ft(n,t){if(n&1&&G(0,gt,1,0,"ng-container",13),n&2){let e=t.$implicit,i=t.$index;s();let o=B(15);s();let a=c(0),r=c(1);m("ngTemplateOutlet",o)("ngTemplateOutletContext",se(7,Ie,_e(2,pt,i,e,a,r.oauthField)))}}function Tt(n,t){n&1&&ae(0)}function St(n,t){if(n&1&&G(0,Tt,1,0,"ng-container",13),n&2){let e=t.$implicit,i=t.$index;s();let o=B(15);s();let a=c(0),r=c(1);m("ngTemplateOutlet",o)("ngTemplateOutletContext",se(7,Ie,_e(2,mt,i,e,a,r.oauthField)))}}function ht(n,t){if(n&1){let e=x();_(0,"button",14),N("click",function(){T(e);let o=s(2);return S(o.showTextArea.set(!1))}),Ne(1,6),ie(2,"sh-icon"),xe(),d()}}function Nt(n,t){if(n&1){let e=x();_(0,"button",21,1),N("click",function(){let o=T(e).$implicit,a=s(3);return S(a.addAdvancedOption(o))}),p(2),d()}if(n&2){let e=t.$implicit;l(2),A(" ",e.name," ")}}function xt(n,t){if(n&1){let e=x();_(0,"div",11)(1,"sh-menu",15)(2,"button",16),Ne(3,7),ie(4,"sh-icon"),xe(),d(),oe(5,17),X(6,Nt,3,1,"button",18,J),j(),d(),_(8,"sh-menu")(9,"button",19)(10,"sh-icon"),p(11,"dots-three-vertical"),d()(),oe(12,17),_(13,"button",20),N("click",function(){T(e);let o=s(2);return S(o.showTextArea.set(!0))}),_(14,"sh-icon"),p(15,"link"),d(),p(16," Edit contents as text "),d(),j(),d()()}if(n&2){s();let e=c(9);l(),m("searchable",!0),l(),m("disabled",e.length===0),l(4),H(e)}}function Et(n,t){if(n&1){let e=x();_(0,"textarea",22),N("ngModelChange",function(o){T(e);let a=s(2);return S(a.updateSettingsFromText(o))}),d()}if(n&2){let e=s(2);m("ngModel",e.settingsAsText())("ngModelOptions",Pe(2,Ct))}}function It(n,t){n&1&&ae(0)}function yt(n,t){if(n&1&&G(0,It,1,0,"ng-container",13),n&2){let e=t.$implicit,i=t.$index;s(2);let o=B(15),a=s(),r=c(0),C=c(1),E=a.getFormView("advanced",e)??a.getDefaultFormView(e);m("ngTemplateOutlet",o)("ngTemplateOutletContext",se(7,Ie,_e(2,ut,i,E,r,C.oauthField)))}}function Dt(n,t){if(n&1&&X(0,yt,1,9,"ng-container",null,J),n&2){let e=s(2);H(e.advancedFormFieldNames())}}function wt(n,t){n&1&&(_(0,"sup",31),p(1,"*"),d())}function Ot(n,t){if(n&1&&(_(0,"sh-icon",32),p(1,"question"),d()),n&2){let e=s(2).$implicit;m("shTooltip",e.formView.longDescription)}}function At(n,t){if(n&1){let e=x();_(0,"app-file-tree",24)(1,"label",30),g(2,wt,2,0,"sup",31),p(3),g(4,Ot,2,1,"sh-icon",32),d(),_(5,"input",33),N("ngModelChange",function(o){T(e);let a=s().$implicit,r=s(2);return S(r.updateFieldValue(a.fieldGroup,a.formView.name,o))}),d()()}if(n&2){let e=s().$implicit,i=c(1),o=c(2),a=c(3),r=c(4),C=c(5);m("startingPath",a)("accepts",e.formView.accepts)("showFiles",!0)("hideShortcuts",!0)("showHiddenNodes",!0)("selectFiles",!0),l(),m("for",C),l(),f(e.formView.isMandatory&&r?2:-1),l(),A(" ",i," "),l(),f(e.formView.longDescription?4:-1),l(),m("id",C)("ngModel",o)}}function Mt(n,t){n&1&&(_(0,"sup",34),p(1,"*"),d())}function Vt(n,t){if(n&1&&(_(0,"sh-icon",32),p(1,"question"),d()),n&2){let e=s(2).$implicit;m("shTooltip",e.formView.longDescription)}}function Ft(n,t){if(n&1){let e=x();_(0,"app-file-tree",25)(1,"label",30),g(2,Mt,2,0,"sup",34),p(3),g(4,Vt,2,1,"sh-icon",32),d(),_(5,"input",33),N("ngModelChange",function(o){T(e);let a=s().$implicit,r=s(2);return S(r.updateFieldValue(a.fieldGroup,a.formView.name,o))}),d()()}if(n&2){let e=s().$implicit,i=c(1),o=c(2),a=c(3),r=c(4),C=c(5);m("hideShortcuts",!0)("enableCreateFolder",!0)("startingPath",a),l(),m("for",C),l(),f(e.formView.isMandatory&&r?2:-1),l(),A(" ",i," "),l(),f(e.formView.longDescription?4:-1),l(),m("id",C)("ngModel",o)}}function vt(n,t){n&1&&(_(0,"sup",35),p(1,"*"),d())}function Lt(n,t){if(n&1&&(_(0,"sh-icon",32),p(1,"question"),d()),n&2){let e=s(2).$implicit;m("shTooltip",e.formView.longDescription)}}function Pt(n,t){n&1&&(_(0,"sh-icon",36),p(1," warning "),d())}function $t(n,t){n&1&&(_(0,"sh-icon",37),p(1,"x-circle"),d())}function bt(n,t){n&1&&(_(0,"sh-icon",38),p(1,"warning"),d())}function Gt(n,t){if(n&1&&(_(0,"sh-icon",42),p(1," link "),d()),n&2){s();let e=c(9),i=c(10);re("error",e&&i==="error")("warn",e&&i==="warning"),m("shTooltip",e)}}function Rt(n,t){n&1&&(_(0,"sh-icon",41),p(1,"envelope"),d())}function kt(n,t){n&1&&(_(0,"sh-icon",41),p(1,"hard-drives"),d())}function Bt(n,t){n&1&&(_(0,"sh-icon",41),p(1,"jar"),d())}function zt(n,t){n&1&&(_(0,"sh-icon",41),p(1,"textbox"),d())}function Kt(n,t){if(n&1){let e=x();_(0,"sh-form-field")(1,"label",30),g(2,vt,2,0,"sup",35),p(3),g(4,Lt,2,1,"sh-icon",32),g(5,Pt,2,0,"sh-icon",36),g(6,$t,2,0,"sh-icon",37),g(7,bt,2,0,"sh-icon",38),d(),_(8,"input",39),N("keydown",function(o){T(e);let a=s().$implicit,r=s(2);return S(r.onKeyDown(a.fieldGroup,a.formView.name,a.formView.type,o))})("ngModelChange",function(o){T(e);let a=s().$implicit,r=s(2);return S(r.updateFieldValue(a.fieldGroup,a.formView.name,o))}),d(),L(9)(10),g(11,Gt,2,5,"sh-icon",40)(12,Rt,2,0,"sh-icon",41)(13,kt,2,0,"sh-icon",41)(14,Bt,2,0,"sh-icon",41)(15,zt,2,0,"sh-icon",41),d()}if(n&2){let e=s().$implicit,i=c(1),o=c(2),a=c(3),r=c(4),C=c(5),E=s(2);l(),m("for",C),l(),f(e.formView.isMandatory&&r?2:-1),l(),A(" ",i," "),l(),f(e.formView.longDescription?4:-1),l(),f(r&&e.formView.type==="Path"?5:-1),l(),f(e.formView.type=="Hostname"&&!r&&!E.isValidHostname(a)?6:-1),l(),f(e.formView.type=="Bucketname"&&!r&&!E.isValidBucketname(a)?7:-1),l(),m("type",e.formView.type==="Email"?"email":"text")("id",C)("ngModel",o);let F=a,w=E.hasLeadingSlash(F??"");l(),O(w&&(e.formView.doubleSlash==null?null:e.formView.doubleSlash.message)),l(),O(e.formView.doubleSlash==null?null:e.formView.doubleSlash.type),l(),f(e.formView.type==="Path"?11:e.formView.type==="Email"?12:e.formView.type==="Hostname"?13:e.formView.type==="Bucketname"?14:15)}}function Ut(n,t){n&1&&(_(0,"sup",43),p(1,"*"),d())}function Jt(n,t){if(n&1&&(_(0,"sh-icon",32),p(1,"question"),d()),n&2){let e=s(2).$implicit;m("shTooltip",e.formView.longDescription)}}function Xt(n,t){if(n&1){let e=x();_(0,"span",47),N("click",function(){T(e);let o=s(2).$implicit,a=s(2);return S(a.oauthStartTokenCreation(o.destinationType,o.fieldGroup,o.formView.name,o.formView.oauthVersion))}),p(1," AuthID "),d()}}function Ht(n,t){n&1&&(_(0,"sh-icon",41),p(1,"password"),d())}function jt(n,t){if(n&1){let e=x();_(0,"sh-icon",48),N("click",function(){T(e);let o=s(2).$implicit;return S(o.formView.showPassword=!o.formView.showPassword)}),p(1," eye "),d()}}function qt(n,t){if(n&1){let e=x();_(0,"sh-icon",48),N("click",function(){T(e);let o=s(2).$implicit;return S(o.formView.showPassword=!o.formView.showPassword)}),p(1," eye-slash "),d()}}function Wt(n,t){if(n&1){let e=x();_(0,"sh-form-field")(1,"label",30),g(2,Ut,2,0,"sup",43),p(3),g(4,Jt,2,1,"sh-icon",32),d(),_(5,"input",44),N("ngModelChange",function(o){T(e);let a=s().$implicit,r=s(2);return S(r.updateFieldValue(a.fieldGroup,a.formView.name,o))}),d(),g(6,Xt,2,0,"span",45)(7,Ht,2,0,"sh-icon",41),g(8,jt,2,0,"sh-icon",46)(9,qt,2,0,"sh-icon",46),d()}if(n&2){let e=s().$implicit,i=c(1),o=c(2),a=c(4),r=c(5);l(),m("for",r),l(),f(e.formView.isMandatory&&a?2:-1),l(),A(" ",i," "),l(),f(e.formView.longDescription?4:-1),l(),m("type",e.formView.showPassword?"text":"password")("id",r)("ngModel",o),l(),f(e.oauthField===e.formView.name?6:7),l(2),f(e.formView.showPassword?8:9)}}function Qt(n,t){n&1&&(_(0,"sup",50),p(1,"*"),d())}function Zt(n,t){if(n&1&&(_(0,"sh-icon",32),p(1,"question"),d()),n&2){let e=s(3).$implicit;m("shTooltip",e.formView.longDescription)}}function Yt(n,t){if(n&1&&p(0),n&2){let e=t.$implicit;le(" ",e.key," ",e.value&&e.value!=e.key?"("+e.value+")":""," ")}}function en(n,t){if(n&1){let e=x();_(0,"sh-select",49)(1,"label",30),g(2,Qt,2,0,"sup",50),p(3),g(4,Zt,2,1,"sh-icon",32),d(),_(5,"input",33),N("ngModelChange",function(o){T(e);let a=s(2).$implicit,r=s(2);return S(r.updateFieldValue(a.fieldGroup,a.formView.name,o))}),d()(),G(6,Yt,1,2,"ng-template",null,2,q)}if(n&2){let e=B(7);s();let i=c(0),o=s().$implicit,a=c(1),r=c(2),C=c(4),E=c(5);m("options",i)("isClearable",!1)("optionTemplate",e),l(),m("for",E),l(),f(o.formView.isMandatory&&C?2:-1),l(),A(" ",a," "),l(),f(o.formView.longDescription?4:-1),l(),m("id",E)("ngModel",r)}}function tn(n,t){if(n&1&&(L(0),g(1,en,8,9)),n&2){let e=s().$implicit,i=O(s(2).mapOptions(e.formView));l(),f(i?1:-1)}}function nn(n,t){n&1&&(_(0,"sup",53),p(1,"*"),d())}function on(n,t){if(n&1&&(_(0,"sh-icon",32),p(1,"question"),d()),n&2){let e=s(3).$implicit;m("shTooltip",e.formView.longDescription)}}function an(n,t){if(n&1&&p(0),n&2){let e=t.$implicit;le(" ",e.key," ",e.value&&e.value!=e.key?"("+e.value+")":""," ")}}function rn(n,t){if(n&1){let e=x();_(0,"sh-select",52)(1,"label",30),g(2,nn,2,0,"sup",53),p(3),g(4,on,2,1,"sh-icon",32),d(),_(5,"input",33),N("ngModelChange",function(o){T(e);let a=s(2).$implicit,r=s(2);return S(r.updateFieldValue(a.fieldGroup,a.formView.name,o))}),d()(),G(6,an,1,2,"ng-template",null,3,q)}if(n&2){let e=B(7);s();let i=c(0),o=s().$implicit,a=c(1),r=c(2),C=c(4),E=c(5);m("options",i)("asFreeText",!0)("inlineSearch",!0)("optionTemplate",e),l(),m("for",E),l(),f(o.formView.isMandatory&&C?2:-1),l(),A(" ",a," "),l(),f(o.formView.longDescription?4:-1),l(),m("id",E)("ngModel",r)}}function ln(n,t){n&1&&ie(0,"sh-progress-bar",51)}function sn(n,t){if(n&1&&(L(0),g(1,rn,8,10)(2,ln,1,0,"sh-progress-bar",51)),n&2){let e=s().$implicit,i=c(2),o=O(s(2).mapOptionsWithFreeText(e.formView,i));l(),f(o?1:2)}}function _n(n,t){n&1&&(_(0,"sup",55),p(1,"*"),d())}function dn(n,t){if(n&1&&(_(0,"sh-icon",32),p(1,"question"),d()),n&2){let e=s(2).$implicit;m("shTooltip",e.formView.longDescription)}}function cn(n,t){if(n&1){let e=x();_(0,"app-size",54),N("ngModelChange",function(o){T(e);let a=s().$implicit,r=s(2);return S(r.updateFieldValue(a.fieldGroup,a.formView.name,o))}),_(1,"label",30),g(2,_n,2,0,"sup",55),p(3),g(4,dn,2,1,"sh-icon",32),d()()}if(n&2){let e=s().$implicit,i=c(1),o=c(2),a=c(4),r=c(5);m("inputType",e.Name)("ngModel",o)("customId",r),l(),m("for",r),l(),f(e.formView.isMandatory&&a?2:-1),l(),A(" ",i," "),l(),f(e.formView.longDescription?4:-1)}}function pn(n,t){n&1&&(_(0,"sup",56),p(1,"*"),d())}function mn(n,t){if(n&1&&(_(0,"sh-icon",32),p(1,"question"),d()),n&2){let e=s(2).$implicit;m("shTooltip",e.formView.longDescription)}}function Cn(n,t){if(n&1){let e=x();_(0,"sh-form-field")(1,"label",30),g(2,pn,2,0,"sup",56),p(3),g(4,mn,2,1,"sh-icon",32),d(),_(5,"input",57),N("ngModelChange",function(o){T(e);let a=s().$implicit,r=s(2);return S(r.updateFieldValue(a.fieldGroup,a.formView.name,o))}),d(),_(6,"sh-icon",41),p(7,"numpad"),d()()}if(n&2){let e=s().$implicit,i=c(1),o=c(2),a=c(4),r=c(5);l(),m("for",r),l(),f(e.formView.isMandatory&&a?2:-1),l(),A(" ",i," "),l(),f(e.formView.longDescription?4:-1),l(),m("id",r)("ngModel",o)}}function un(n,t){if(n&1&&(_(0,"sh-icon",32),p(1,"question"),d()),n&2){let e=s(2).$implicit;m("shTooltip",e.formView.longDescription)}}function gn(n,t){if(n&1){let e=x();_(0,"sh-toggle",58),N("click",function(){T(e);let o=s().$implicit,a=c(2),r=s(2);return S(r.updateFieldValue(o.fieldGroup,o.formView.name,r.isTrue(a)?"false":"true"))}),_(1,"label",30),p(2),g(3,un,2,1,"sh-icon",32),d()()}if(n&2){let e=s().$implicit,i=c(1),o=c(2),a=c(5),r=s(2);re("active",r.isTrue(o)),l(),m("for",a),l(),A(" ",i," "),l(),f(e.formView.longDescription?3:-1)}}function fn(n,t){n&1&&(_(0,"sup",60),p(1,"*"),d())}function Tn(n,t){if(n&1&&(_(0,"sh-icon",32),p(1,"question"),d()),n&2){let e=s(3).$implicit;m("shTooltip",e.formView.longDescription)}}function Sn(n,t){if(n&1&&p(0),n&2){let e=t.$implicit;le(" ",e.key," ",e.value&&e.value!=e.key?"("+e.value+")":""," ")}}function hn(n,t){if(n&1){let e=x();_(0,"sh-select",59)(1,"label",30),g(2,fn,2,0,"sup",60),p(3),g(4,Tn,2,1,"sh-icon",32),d(),_(5,"input",61),N("ngModelChange",function(o){T(e);let a=s(2).$implicit,r=s(2);return S(r.updateFieldValue(a.fieldGroup,a.formView.name,o))}),d()(),G(6,Sn,1,2,"ng-template",null,4,q)}if(n&2){let e=B(7);s();let i=c(0),o=s().$implicit,a=c(1),r=c(2),C=c(4),E=c(5);m("options",i)("selectMultiple",!0)("optionTemplate",e),l(),m("for",E),l(),f(o.formView.isMandatory&&C?2:-1),l(),A(" ",a," "),l(),f(o.formView.longDescription?4:-1),l(),m("ngModel",r)}}function Nn(n,t){if(n&1&&(L(0),g(1,hn,8,8)),n&2){let e=s().$implicit,i=O(s(2).mapOptions(e.formView));l(),f(i?1:-1)}}function xn(n,t){n&1&&(_(0,"sup",62),p(1,"*"),d())}function En(n,t){if(n&1&&(_(0,"sh-icon",32),p(1,"question"),d()),n&2){let e=s(2).$implicit;m("shTooltip",e.formView.longDescription)}}function In(n,t){if(n&1){let e=x();_(0,"app-timespan",54),N("ngModelChange",function(o){T(e);let a=s().$implicit,r=s(2);return S(r.updateFieldValue(a.fieldGroup,a.formView.name,o))}),_(1,"label",30),g(2,xn,2,0,"sup",62),p(3),g(4,En,2,1,"sh-icon",32),d()()}if(n&2){let e=s().$implicit,i=c(1),o=c(2),a=c(4),r=c(5);m("inputType",e.formView.name)("ngModel",o)("customId",r),l(),m("for",r),l(),f(e.formView.isMandatory&&a?2:-1),l(),A(" ",i," "),l(),f(e.formView.longDescription?4:-1)}}function yn(n,t){n&1&&(_(0,"sup",64),p(1,"*"),d())}function Dn(n,t){if(n&1&&(_(0,"sh-icon",32),p(1,"question"),d()),n&2){let e=s(2).$implicit;m("shTooltip",e.formView.longDescription)}}function wn(n,t){if(n&1){let e=x();_(0,"app-file-drop-textarea",63),N("ngModelChange",function(o){T(e);let a=s().$implicit,r=s(2);return S(r.updateFieldValue(a.fieldGroup,a.formView.name,o))}),_(1,"label"),g(2,yn,2,0,"sup",64),p(3),g(4,Dn,2,1,"sh-icon",32),d()()}if(n&2){let e=s().$implicit,i=c(2),o=c(4),a=c(5);m("ngModel",i)("customId",a)("placeholder",e.formView.longDescription),l(2),f(e.formView.isMandatory&&o?2:-1),l(),A(" ",e.formView.shortDescription??e.formView.name," "),l(),f(e.formView.longDescription?4:-1)}}function On(n,t){if(n&1){let e=x();_(0,"button",65),N("click",function(){T(e);let o=s().$implicit,a=s(2);return S(a.removeAdvancedOption(o.formView.name))}),_(1,"sh-icon"),p(2,"x-circle"),d()()}}function An(n,t){if(n&1&&(_(0,"div",23),L(1)(2)(3)(4)(5),g(6,At,6,12,"app-file-tree",24)(7,Ft,6,9,"app-file-tree",25)(8,Kt,16,13,"sh-form-field")(9,Wt,10,9,"sh-form-field")(10,tn,2,2)(11,sn,3,2)(12,cn,5,7,"app-size",26)(13,Cn,8,6,"sh-form-field")(14,gn,4,5,"sh-toggle",27)(15,Nn,2,2)(16,In,5,7,"app-timespan",26)(17,wn,5,6,"app-file-drop-textarea",28),g(18,On,3,0,"button",29),d()),n&2){let e=t.$implicit;s();let i=c(0),o=s();re("single-field",e.fieldGroup!=="advanced"),l(),O(e.formView.shortDescription??e.formView.name),l(),O(o.getFieldGroup(i,e.fieldGroup)[e.formView.name]),l();let a=O(o.getFieldValue(e.fieldGroup,e.formView.name));l(),O((a??"").toString().trim()===""),l(),O("destination-"+e.fieldGroup+"-"+e.index+"-"+(e.asHttpOptions?"http":"other")),l(),f(e.formView.type==="FileTree"?6:e.formView.type==="FolderTree"?7:e.formView.type==="String"||e.formView.type==="Path"||e.formView.type==="Email"||e.formView.type==="Hostname"||e.formView.type==="Bucketname"?8:e.formView.type==="Password"?9:e.formView.type==="Enumeration"?10:e.formView.type==="NonValidatedSelectableString"?11:e.formView.type==="Size"?12:e.formView.type==="Integer"?13:e.formView.type==="Boolean"?14:e.formView.type==="Flags"?15:e.formView.type==="Timespan"||e.formView.type==="DateTime"?16:e.formView.type==="FreeText"?17:-1),l(12),f(e.fieldGroup==="advanced"?18:-1)}}function Mn(n,t){if(n&1&&(L(0),X(1,ft,1,9,"ng-container",null,J),X(3,St,1,9,"ng-container",null,J),_(5,"sh-toggle-card",8),oe(6,9)(7),De(8,5),j(),L(9),g(10,ht,3,0,"button",10)(11,xt,17,2,"div",11),j(),g(12,Et,1,3,"textarea",12)(13,Dt,2,0),d(),G(14,An,19,9,"ng-template",null,0,q)),n&2){let e=s(),i=c(1);O(e.destinationForm()),l(),H(i.custom),l(2),H(i.dynamic),l(2),m("disallowToggle",!0),l(4),O(e.nonSelectedAdvancedFormViews()),l(),f(e.showTextArea()?10:11),l(2),f(e.showTextArea()?12:13)}}var rt=class n{#t=V(it);#e=V(z);#n=V(Qe);#a=V(ge);injector=V(ye);targetUrl=be.required();useBackupState=Q(!1);#i=null;destinationType=P(()=>{let t=this.targetUrl();if(!t)return null;let e=K(t.split("://")[0]);return this.#i=e?.customKey??e?.key,this.#i});destinationForm=b({custom:{},dynamic:{},advanced:{}});advancedFormFieldNames=P(()=>Object.keys(this.destinationForm().advanced));destinationFormConfig=b(null);showTextArea=b(!1);nonSelectedAdvancedFormViews=P(()=>{let t=this.destinationFormConfig();if(!t)return[];let e=this.advancedFormFieldNames();return t.advanced.filter(i=>e.findIndex(o=>o===i.name)===-1)});destinationTypeEffect=W(()=>{let t=this.destinationType()??"",e=K(t),i=e?.key,o=this.#a.backendModules().find(I=>I.Key===i)??{Key:t,DisplayName:t,Description:K(t).description,Options:[]};if(!o||!o.Options||!t)return;let a=e&&e.oauthField?e.oauthField:null,r=e&&e.customFields?e.customFields:{},C=e&&e.dynamicFields?e.dynamicFields:[],E=e&&e.advancedFields?e.advancedFields:[],F=e&&e.ignoredAdvancedFields?e.ignoredAdvancedFields:[],w={destinationType:t,oauthField:a,custom:[],dynamic:[],advanced:[]};r&&Object.entries(r).forEach(([I,u],y)=>{let D=u.order??y;w.custom.push(M({order:900+D},u))});for(let I=0;I<o.Options.length;I++){let u=o.Options[I];if(u.Deprecated)continue;let y=C.find(D=>D===u.Name||u.Aliases?.includes(D.name)||D.name===u.Name);if(y){let D=u.Aliases?.indexOf(y.name)??-1,$=u.Aliases&&D>-1?u.Aliases[D]:u.Name,h=y&&typeof y!="string",Te=h?y?.defaultValue??u.DefaultValue:u.DefaultValue,Se=h&&y?.order!==void 0?y.order:I,U={name:$,type:u.Type,shortDescription:u.ShortDescription??void 0,longDescription:u.LongDescription??void 0,options:u.ValidValues,order:900+Se},he=h?M(M({},U),y):U;w.dynamic.push(he)}else{let D=u.Name;if(F.find(Z=>Z===D))continue;let h=E.find(Z=>Z===D||Z.name===D),Te=h&&typeof h!="string",Se=Te&&h?.order!==void 0?h.order:I,U={name:D,type:u.Type,shortDescription:u.ShortDescription??void 0,longDescription:u.LongDescription??void 0,options:u.ValidValues,defaultValue:u.DefaultValue,order:900+Se},he=Te?M(M({},U),h):U;w.advanced.push(he)}}w.custom.sort((I,u)=>I.order-u.order),w.dynamic.sort((I,u)=>I.order-u.order),w.advanced.sort((I,u)=>I.order-u.order),this.destinationFormConfig.set(w);let k=this.targetUrl();if(!k)return;let v=Ye(k);v&&this.destinationForm.set({custom:v.custom,dynamic:v.dynamic,advanced:v.advanced})});destinationFormEffect=W(()=>{let t=this.#i,e=this.destinationForm();if(!e||!t)return;let i=Ze({destinationType:t,custom:e.custom,dynamic:e.dynamic,advanced:e.advanced});i&&this.targetUrl.set(i)});getFieldValue(t,e){let o=this.destinationForm()[t][e];return o||null}getFormView(t,e){let o=this.destinationFormConfig()?.[t].find(a=>a.name===e);return o||null}getDefaultFormView(t){return{name:t,type:"String",shortDescription:t,longDescription:$localize`This is an undocumented option.`}}getFieldGroup(t,e){return t[e]}hasLeadingSlash(t){return t?.startsWith("/")??!1}addAdvancedOption(t){let e=this.destinationForm();e.advanced[t.name]=t.defaultValue,this.destinationForm.set(M({},e))}isValidBucketname(t){if(!t)return!1;let e=t.length;return!(e<3||e>63||!/^[a-z0-9.-]+$/.test(t)||!/^[a-z0-9]/.test(t)||!/[a-z0-9]$/.test(t)||/^\d{1,3}(\.\d{1,3}){3}$/.test(t)||/(\.\.)|(\.-)|(-\.)/.test(t))}isValidHostname(t){if(!t||t.length>253)return!1;let e=t.split(".");for(let i of e)if(!i||i.length>63||!/^[a-zA-Z0-9]([-a-zA-Z0-9]*[a-zA-Z0-9])?$/.test(i))return!1;return!0}isTrue(t){if(typeof t=="boolean")return t;if(typeof t=="string"){let e=t.toLowerCase();return e==="true"||e==="1"||e==="yes"||e==="on"}return!1}onKeyDown(t,e,i,o){if(i==="Hostname"||i==="Bucketname"){if(["Backspace","Delete","ArrowLeft","ArrowRight","Tab","Home","End"].includes(o.key))return;if(o.key=="/"||o.key=="\\"||o.key==":"){o.preventDefault();return}}}updateFieldValue(t,e,i){let o=this.destinationForm();o[t][e]=i,this.destinationForm.set(M({},o))}removeAdvancedOption(t){let e=this.destinationForm();delete e.advanced[t],this.destinationForm.set(M({},e))}mapOptions(t){let e=t.loadOptions;if(e)return e(this.injector)();let i=t.options;return i?i.map(o=>({key:o,value:o})):null}mapOptionsWithFreeText(t,e){let i=this.mapOptions(t);return i?(e&&e.length>0&&(i.find(a=>a.value===e)||i.push({key:e,value:e})),i):null}#o=b(!1);oauthStartTokenCreation(t,e,i,o){this.#o.set(!0);let a=(o??1)==2?this.#e.defaultOAuthUrlV2():this.#e.defaultOAuthUrl(),r=this.#n.serverSettings()?.["--oauth-url"];if(r&&r.length>0&&(a=r),this.useBackupState()){let u=this.#t.mapFormsToSettings().find(y=>y.Name==="--oauth-url")?.Value;u&&u.length>0&&(a=u)}let C=this.destinationForm().advanced["oauth-url"];C&&C.length>0&&(a=C);let E=`${a}?type=${t}`,F=450,w=600,k=screen.width/2-F/2,v=screen.height/2-w/2,I=window.open(E,"_blank","height="+w+",width="+F+",menubar=0,status=0,titlebar=0,toolbar=0,left="+k+",top="+v);return window.addEventListener("message",u=>{let y=u.data.startsWith("authid:"),D=y?u.data.replace("authid:",""):null;y&&(this.destinationForm.update($=>($[e][i]=D,$)),this.#o.set(!1),I?.close())}),!1}settingsAsText=P(()=>{let t=this.destinationForm().advanced;return Object.entries(t).map(([e,i])=>{let o=e??"",a="";return typeof i=="boolean"?a=this.isTrue(i)?"True":"False":(typeof i=="number"||i!=null)&&(a=i.toString()),`${o}=${a}`}).join(`
|
|
7
|
+
`)});updateSettingsFromText(t){if(typeof t!="string")return;let e=et(t);this.destinationForm.update(i=>Y(M({},i),{advanced:e}))}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=ne({type:n,selectors:[["app-single-destination"]],inputs:{targetUrl:[1,"targetUrl"],useBackupState:[1,"useBackupState"]},outputs:{targetUrl:"targetUrlChange"},decls:3,vars:3,consts:()=>{let t;t=$localize`Advanced options`;let e;e=$localize` Show editor ${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:link${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON:`;let i;i=$localize` Add advanced option ${"\uFFFD#4\uFFFD"}:START_TAG_SH_ICON:plus${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_SH_ICON:`;let o;o=$localize`This field is mandatory`;let a;a=$localize`This field is mandatory`;let r;r=$localize`This field is mandatory`;let C;C=$localize`An empty path means storing data in the initial or root folder, which is not recommended`;let E;E=$localize`Hostname is invalid`;let F;F=$localize`Bucket name is invalid`;let w;w=$localize`This field is mandatory`;let k;k=$localize`This field is mandatory`;let v;v=$localize`This field is mandatory`;let I;I=$localize`This field is mandatory`;let u;u=$localize`This field is mandatory`;let y;y=$localize`This field is mandatory`;let D;D=$localize`This field is mandatory`;let $;return $=$localize`This field is mandatory`,[["fieldTemplate",""],["option",""],["enumOptionTemplate",""],["nonValidatedOptionTemplate",""],["optionTemplate",""],t,e,i,[1,"advanced-options",3,"disallowToggle"],["title",""],["shButton","","type","button",1,"outlined","small"],[1,"actions"],["wrap","off","placeholder","Paste advanced options here, one per line.",1,"raw-text-area",3,"ngModel","ngModelOptions"],[4,"ngTemplateOutlet","ngTemplateOutletContext"],["shButton","","type","button",1,"outlined","small",3,"click"],[3,"searchable"],["shButton","","type","button",1,"outlined","small",3,"disabled"],["menu",""],["type","button"],["shButton","","type","button",1,"small"],["shButton","","type","button",1,"small",3,"click"],["type","button",3,"click"],["wrap","off","placeholder","Paste advanced options here, one per line.",1,"raw-text-area",3,"ngModelChange","ngModel","ngModelOptions"],[1,"field-row"],[3,"startingPath","accepts","showFiles","hideShortcuts","showHiddenNodes","selectFiles"],[3,"hideShortcuts","enableCreateFolder","startingPath"],[3,"inputType","ngModel","customId"],[1,"primary","raised",3,"active"],[3,"ngModel","customId","placeholder"],["shButton","","type","button",1,"outlined"],[3,"for"],["shTooltip",o],[1,"primary",3,"shTooltip"],["type","text",3,"ngModelChange","id","ngModel"],["shTooltip",a],["shTooltip",r],["shTooltip",C,1,"warn"],["shTooltip",E,1,"error"],["shTooltip",F,1,"warn"],[3,"keydown","ngModelChange","type","id","ngModel"],["prefix","",3,"error","warn","shTooltip"],["prefix",""],["prefix","",3,"shTooltip"],["shTooltip",w],["autocomplete","off",3,"ngModelChange","type","id","ngModel"],["prefix","",1,"link"],["suffix","",1,"clickable"],["prefix","",1,"link",3,"click"],["suffix","",1,"clickable",3,"click"],["label","key","value","value",3,"options","isClearable","optionTemplate"],["shTooltip",k],[1,"indeterminate","primary"],["label","key","value","value",3,"options","asFreeText","inlineSearch","optionTemplate"],["shTooltip",v],[3,"ngModelChange","inputType","ngModel","customId"],["shTooltip",I],["shTooltip",u],["type","number",3,"ngModelChange","id","ngModel"],[1,"primary","raised",3,"click"],["key","key","value","value",1,"primary","raised",3,"options","selectMultiple","optionTemplate"],["shTooltip",y],["type","text","id","text",3,"ngModelChange","ngModel"],["shTooltip",D],[3,"ngModelChange","ngModel","customId","placeholder"],["shTooltip",$],["shButton","","type","button",1,"outlined",3,"click"]]},template:function(e,i){if(e&1&&(L(0)(1),g(2,Mn,16,5)),e&2){let o=O(i.destinationType());l();let a=O(i.destinationFormConfig());l(),f(o&&a?2:-1)}},dependencies:[Be,de,ke,ce,me,pe,Ge,tt,nt,ot,fe,Ke,ue,Ce,He,Ue,Xe,qe,je,Je],styles:["[_nghost-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.advanced-options[_ngcontent-%COMP%]{position:relative;z-index:1}textarea[_ngcontent-%COMP%] ~ grammarly-extension[_ngcontent-%COMP%]{display:none}sh-select[_ngcontent-%COMP%]{--miw: p2r(120)}[prefix].link[_ngcontent-%COMP%]{cursor:pointer;text-decoration:underline;color:var(--primary-8)}.clickable[_ngcontent-%COMP%]{cursor:pointer;color:var(--primary-8)}label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.25rem}label[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{font-size:1rem}.field-row[_ngcontent-%COMP%]{display:grid;align-items:flex-end;grid-template-columns:1fr 2.5rem;gap:.5rem}.field-row.single-field[_ngcontent-%COMP%]{display:block}.actions[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.raw-text-area[_ngcontent-%COMP%]{min-height:12rem;white-space:pre}"],changeDetection:0})};export{at as a,ge as b,rt as c};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as ye,b as $e}from"./chunk-3LVCVLMO.js";import{a as we}from"./chunk-EE5UMXWP.js";import{a as He}from"./chunk-VRV52R6I.js";import"./chunk-Z27IQRKV.js";import{a as J}from"./chunk-7FCBU2UO.js";import"./chunk-RDCD2W2C.js";import{a as ve}from"./chunk-TJIZJNCK.js";import"./chunk-ZSZLXWN6.js";import"./chunk-72HORZFV.js";import"./chunk-6Q6SSTBK.js";import{a as Re}from"./chunk-MTQKK2WN.js";import"./chunk-LN26XMBJ.js";import{a as be}from"./chunk-GXGIGJ4W.js";import"./chunk-XVWOVBC4.js";import{b as Ce,d as Ge}from"./chunk-WXF4HUYT.js";import{c as pe,e as Se,f as ge}from"./chunk-ABYM5HWA.js";import"./chunk-Z35OG2DV.js";import{B as Y,F as Pe,G as Ie,I as Le,P as De,X as Me,c as Te,d as me,e as he,i as Fe,r as Ee,s as Ae,t as Oe,u as M,w as B,x as Ne,z as fe}from"./chunk-QF4DQYEP.js";import{h as V}from"./chunk-PD73DDOS.js";import"./chunk-5ZSBXGHQ.js";import"./chunk-FPPZ4BUR.js";import{$b as c,Ab as te,Bb as ne,Bc as ce,Cb as O,Db as a,Eb as o,Fb as _,H as j,Jb as ie,Kb as oe,Mb as E,Qc as U,Rc as Q,Sa as r,Tb as g,Ub as C,Vb as f,Vc as ue,Xc as de,Yb as v,Zb as T,Zc as K,_ as S,cb as D,ea as m,fa as h,gc as ae,hc as se,kc as k,mc as L,nc as u,oc as q,pa as A,pc as b,sc as y,tc as $,uc as H,vc as re,wc as le,xb as d,xc as w,yb as p,yc as _e,zb as ee}from"./chunk-QONLYWYC.js";import{a as z,b as W}from"./chunk-EUDKD2JW.js";var Be=["scroller"];function Ye(i,n){i&1&&(a(0,"sh-icon"),u(1,"bell-ringing"),o())}function Ve(i,n){i&1&&(a(0,"sh-icon"),u(1,"bell"),o())}function Je(i,n){if(i&1&&_(0,"app-notification",8),i&2){c(2);let e=w(6);O("index",0)("notification",e.content)}}function Xe(i,n){if(i&1&&(a(0,"div",11),u(1),o()),i&2){c(3);let e=w(6);r(),b(" ",e.content.content," ")}}function ze(i,n){if(i&1&&(a(0,"sh-alert")(1,"div",10),u(2),o(),d(3,Xe,2,1,"div",11),o()),i&2){c(2);let e=w(6);L(e.content.type||"error"),r(2),q(e.content.title),r(),p(e.content.content?3:-1)}}function We(i,n){if(i&1&&(a(0,"div",6),d(1,Je,1,2,"app-notification",8)(2,ze,4,4,"sh-alert",9),o()),i&2){c();let e=w(6);r(),p(e.type==="notification"?1:2)}}function je(i,n){if(i&1){let e=E();a(0,"div",7)(1,"div",12)(2,"h6",13),g(3,2),a(4,"button",5),T("click",function(){m(e);let s=c();return h(s.toggleNotifications())}),_(5,"sh-icon"),o(),C(),o(),a(6,"div",14,0)(8,"div",15),_(9,"app-notifications"),o()()()()}}function qe(i,n){if(i&1&&(a(0,"div",20),u(1),o()),i&2){let e=c().$implicit;r(),b(" ",e.content," ")}}function Qe(i,n){if(i&1){let e=E();a(0,"sh-alert",18,1),T("click",function(){let s=m(e).$implicit,l=c(2);return h(l.deleteAlertByIndex(s.id))}),a(2,"div",19),u(3),o(),d(4,qe,2,1,"div",20),o()}if(i&2){let e=n.$implicit;L(e.type),O("id",e.id),r(3),q(e.title),r(),p(e.content?4:-1)}}function Ke(i,n){i&1&&(a(0,"p",17),f(1,4),o())}function Ze(i,n){if(i&1){let e=E();a(0,"div",7)(1,"div",12)(2,"h6",13),g(3,3),a(4,"button",5),T("click",function(){m(e);let s=c();return h(s.toggleAlerts())}),_(5,"sh-icon"),o(),C(),o(),a(6,"div",14,0)(8,"div",15),te(9,Qe,5,5,"sh-alert",16,ee,!1,Ke,2,0,"p",17),o()()()()}if(i&2){let e=c();r(9),ne(e.alertHistory())}}var xe=new Ee,x=class i{#e=S(Ne);#t=S(J);isSubmitting=A(!1);messageSent=A(!1);form=xe.group({message:xe.control("",[me.required])});notifications=this.#t.notifications;shownMessage=A(null);shownMessageInterval=null;alertHistory=this.#e.alertHistory;alertHistoryIsOpen=this.#e.alertHistoryIsOpen;alertHistoryIsHidden=this.#e.alertHistoryIsHidden;numberOfOpenAlerts=U(()=>this.alertHistory().filter(n=>n.isOpen).length);scroller=de("scroller");isAlertsOpen=K(!1);isNotificationsOpen=K(!1);previousHistoryCount=A(null);previousNotificationsCount=A(null);constructor(){Q(()=>{let n=this.alertHistory(),e=this.notifications();if(e.length===0){this.shownMessage.set(null);return}e.length&&this.previousHistoryCount()!==n.length&&!this.isNotificationsOpen()?(this.shownMessage.set({content:e[0],countDown:3,type:"notification"}),this.previousHistoryCount.set(n.length),this.shownMessageInterval=setInterval(()=>{let t=this.shownMessage();if(t?.countDown===0){this.shownMessage.set(null),this.shownMessageInterval=null;return}t!==null&&this.shownMessage.update(s=>W(z({},s),{countDown:s.countDown-1}))},1e3)):n.length&&this.previousHistoryCount()!==n.length&&!this.isAlertsOpen()&&(this.shownMessage.set({content:n[0],countDown:3,type:"alert"}),this.previousHistoryCount.set(n.length),this.shownMessageInterval=setInterval(()=>{let t=this.shownMessage();if(t?.countDown===0){this.shownMessage.set(null),this.shownMessageInterval=null;return}t!==null&&this.shownMessage.update(s=>W(z({},s),{countDown:s.countDown-1}))},1e3))}),Q(()=>{this.alertHistoryIsOpen(),this.scrollToBottom()})}resetPreviewMessage(){this.shownMessage.set(null),this.shownMessageInterval=null}toggleAlerts(){this.isAlertsOpen()?this.isAlertsOpen.set(!1):(this.isAlertsOpen.set(!0),this.isNotificationsOpen.set(!1),this.resetPreviewMessage())}toggleNotifications(){this.isNotificationsOpen.set(!this.isNotificationsOpen()),this.isAlertsOpen()&&this.isAlertsOpen.set(!1)}deleteAlertByIndex(n){this.#e.removeAlert(n)}scrollToBottom(){this.scroller()&&this.scroller()?.nativeElement&&this.scroller().nativeElement.scrollTo(0,this.scroller().nativeElement.scrollHeight)}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=D({type:i,selectors:[["app-service-hub"]],viewQuery:function(e,t){e&1&&ae(t.scroller,Be,5),e&2&&se()},inputs:{isAlertsOpen:[1,"isAlertsOpen"],isNotificationsOpen:[1,"isNotificationsOpen"]},outputs:{isAlertsOpen:"isAlertsOpenChange",isNotificationsOpen:"isNotificationsOpenChange"},decls:10,vars:9,consts:()=>{let n;n=$localize` Notifications ${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:x-circle${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_BUTTON:`;let e;e=$localize` Alerts ${"\uFFFD#4\uFFFD"}:START_TAG_BUTTON:${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:x-circle${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON:${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_BUTTON:`;let t;return t=$localize`No alerts yet`,[["scroller",""],["alerts",""],n,e,t,["shButton","",3,"click"],[1,"preview-alert-wrap"],[1,"alert-stream-modal"],[3,"index","notification"],[3,"class"],["ship-alert-title",""],["ship-alert-content",""],[1,"alert-stream-modal-content"],[1,"paragraph-20"],[1,"alert-stream-modal-list-scroller"],[1,"alert-stream-modal-list"],[3,"class","id"],[1,"no-alerts"],[3,"click","id"],["title",""],["content",""]]},template:function(e,t){if(e&1){let s=E();a(0,"button",5),T("click",function(){return m(s),h(t.toggleAlerts())}),a(1,"sh-icon"),u(2,"info"),o()(),a(3,"button",5),T("click",function(){return m(s),h(t.toggleNotifications())}),d(4,Ye,2,0,"sh-icon")(5,Ve,2,0,"sh-icon"),o(),re(6),d(7,We,3,1,"div",6),d(8,je,10,0,"div",7),d(9,Ze,12,1,"div",7)}if(e&2){L(t.alertHistory().length?"error":""),r(3),L(t.notifications().length?"error":""),r(),p(t.notifications().length?4:5),r(2);let s=le(t.shownMessage());r(),p(s?7:-1),r(),p(t.isNotificationsOpen()?8:-1),r(),p(t.isAlertsOpen()?9:-1)}},dependencies:[Oe,B,M,Y,$e,ye],styles:["[_nghost-%COMP%]{display:flex;position:fixed;gap:.5rem;bottom:1.5rem;right:1.5rem;z-index:5000}@media only screen and (max-width: 768px){[_nghost-%COMP%]{bottom:1rem;right:1rem}}[_nghost-%COMP%] h6[_ngcontent-%COMP%]{margin:0}.preview-alert-wrap[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column;min-width:15.625rem}.helpdesk-modal[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column}@media only screen and (max-width: 768px){.helpdesk-modal[_ngcontent-%COMP%]{bottom:2.6875rem}}.helpdesk-modal-content[_ngcontent-%COMP%]{position:relative;display:flex;flex-direction:column;gap:1rem;min-width:20rem;border:1px solid var(--base-4);background-color:var(--base-1);border-radius:var(--shape-2)}.helpdesk-modal-content[_ngcontent-%COMP%] .message-sent[_ngcontent-%COMP%]{padding:0 1rem 1rem;text-wrap:pretty}.helpdesk-modal-content[_ngcontent-%COMP%] h6[_ngcontent-%COMP%]{padding:1rem;border-bottom:1px solid var(--base-4);display:flex;align-items:center;justify-content:space-between}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%]{padding:0 1rem 1rem;display:flex;flex-direction:column;align-items:flex-end;gap:1rem}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{width:100%;text-wrap:pretty}.helpdesk-modal-content[_ngcontent-%COMP%] form[_ngcontent-%COMP%] mat-form-field[_ngcontent-%COMP%]{width:100%}.alert-stream-modal[_ngcontent-%COMP%]{position:absolute;bottom:2.6875rem;right:0;display:flex;flex-direction:column}@media only screen and (max-width: 768px){.alert-stream-modal[_ngcontent-%COMP%]{bottom:2.6875rem}}.alert-stream-modal-list-scroller[_ngcontent-%COMP%]{overflow-y:auto;max-height:18.75rem}.alert-stream-modal-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem;padding:1rem;border-radius:var(--shape-2)}.alert-stream-modal-content[_ngcontent-%COMP%]{position:relative;display:flex;flex-direction:column;min-width:20rem;border:1px solid var(--base-4);background-color:var(--base-1);border-radius:var(--shape-2)}.alert-stream-modal-content[_ngcontent-%COMP%] h6[_ngcontent-%COMP%]{padding:1rem;border-bottom:1px solid var(--base-4);display:flex;align-items:center;justify-content:space-between}.no-alerts[_ngcontent-%COMP%]{padding:1rem;display:flex;flex-direction:column;gap:1rem;text-align:center}"],changeDetection:0})};function et(i,n){i&1&&(a(0,"sh-icon",14),u(1,"check"),o())}function tt(i,n){i&1&&(a(0,"sh-icon",15),u(1,"prohibit"),o())}function nt(i,n){if(i&1){let e=E();a(0,"button",20),T("click",function(){m(e);let s=c();return h(s.updatePassphrase())}),f(1,5),o()}if(i&2){let e=c();k("loader",e.isUpdating())}}function it(i,n){if(i&1){let e=E();a(0,"button",21),T("click",function(){m(e);let s=c();return h(s.updatePassphrase())}),f(1,6),o()}if(i&2){let e=c();k("loader",e.isUpdating()),O("disabled",!0)}}var X=class i{#e=S(V);closed=ue();isUpdating=A(!1);passphrase=A("");repeatPassphrase=A("");updatePassphrase(){this.passphrase()===this.repeatPassphrase()&&(this.isUpdating.set(!0),this.#e.patchApiV1Serversettings({requestBody:{"server-passphrase":this.passphrase()}}).pipe(j(()=>this.isUpdating.set(!1))).subscribe({next:()=>this.closed.emit()}))}cancel(){this.isUpdating.set(!0),this.#e.patchApiV1Serversettings({requestBody:{"has-asked-for-password-change":"True"}}).pipe(j(()=>this.isUpdating.set(!1))).subscribe({next:()=>this.closed.emit()})}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=D({type:i,selectors:[["app-change-passphrase-alert-dialog"]],outputs:{closed:"closed"},decls:23,vars:7,consts:()=>{let n;n=$localize`Enter new password`;let e;e=$localize`Repeat password`;let t;t=$localize`Password have to be filled and have to match`;let s;s=$localize`Change passphrase`;let l;l=$localize` Duplicati needs to be secured with a passphrase and a random passphrase has been generated for you. ${"[\uFFFD#6\uFFFD\uFFFD/#6\uFFFD|\uFFFD#7\uFFFD\uFFFD/#7\uFFFD]"}:LINE_BREAK:${"[\uFFFD#6\uFFFD\uFFFD/#6\uFFFD|\uFFFD#7\uFFFD\uFFFD/#7\uFFFD]"}:LINE_BREAK: If you open Duplicati from the tray icon, you do not need a passphrase, but if you plan to open it from another location you need to set a passphrase you know. Do you want to set a passphrase now? `,l=v(l);let P;P=$localize`Passphrase`;let I;I=$localize`Repeat passphrase`;let R;R=$localize`Not now thanks`;let G;G=$localize` Yes, update passphrase now `;let F;return F=$localize` Yes, update passphrase now `,[s,l,P,I,R,G,F,["header",""],["content",""],["type","warning"],["for","password"],["type","password","name","password","autocomplete","disabled","placeholder",n,"tabindex","1",3,"ngModelChange","ngModel"],["for","repeatPassword"],["type","password","name","repeatPassword","autocomplete","disabled","placeholder",e,"tabindex","2",3,"ngModelChange","disabled","ngModel"],["suffix","",1,"sh-success"],["suffix",""],["footer",""],["shButton","",3,"click"],["shButton","",1,"raised","primary",3,"loader"],["shButton","","shTooltip",t,1,"raised","primary",3,"loader","disabled"],["shButton","",1,"raised","primary",3,"click"],["shButton","","shTooltip",t,1,"raised","primary",3,"click","disabled"]]},template:function(e,t){e&1&&(a(0,"header",7)(1,"h3"),f(2,0),o()(),a(3,"div",8)(4,"sh-alert",9),g(5,1),_(6,"br")(7,"br"),C(),o(),a(8,"sh-form-field")(9,"label",10),f(10,2),o(),a(11,"input",11),H("ngModelChange",function(l){return $(t.passphrase,l)||(t.passphrase=l),l}),o()(),a(12,"sh-form-field")(13,"label",12),f(14,3),o(),a(15,"input",13),H("ngModelChange",function(l){return $(t.repeatPassphrase,l)||(t.repeatPassphrase=l),l}),o(),d(16,et,2,0,"sh-icon",14)(17,tt,2,0,"sh-icon",15),o()(),a(18,"footer",16)(19,"button",17),T("click",function(){return t.cancel()}),f(20,4),o(),d(21,nt,2,2,"button",18)(22,it,2,3,"button",19),o()),e&2&&(r(11),y("ngModel",t.passphrase),r(4),O("disabled",t.passphrase().length===0),y("ngModel",t.repeatPassphrase),r(),p(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?16:17),r(3),k("loader",t.isUpdating()),r(2),p(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?21:22))},dependencies:[Ae,Te,he,Fe,B,Ie,M,Me],styles:["[_nghost-%COMP%]{display:block;--dialog-p: 1.5rem}[content][_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}"],changeDetection:0})};var ot=()=>({exact:!0});function at(i,n){i&1&&(a(0,"sh-icon",26),u(1,"x-bold"),o())}function st(i,n){i&1&&(a(0,"sh-icon",27),u(1,"list-bold"),o())}function rt(i,n){if(i&1){let e=E();ie(0,10),a(1,"button",25),T("click",function(){m(e);let s=c();return h(s.toggleNav())}),d(2,at,2,0,"sh-icon",26)(3,st,2,0,"sh-icon",27),o(),oe()}if(i&2){let e=c();r(2),p(e.isNavOpen()?2:3)}}function lt(i,n){i&1&&(a(0,"sh-icon"),u(1,"sun"),o())}function _t(i,n){i&1&&(a(0,"sh-icon"),u(1,"moon"),o())}function ct(i,n){if(i&1){let e=E();a(0,"button",28),T("click",function(){m(e);let s=c();return h(s.changeDefaultClientTo("ngax"))}),g(1,7),_(2,"sh-icon"),C(),o(),a(3,"button",28),T("click",function(){m(e);let s=c();return h(s.logout())}),g(4,8),_(5,"sh-icon"),C(),o()}}var Z=class i{#e=S(we);#t=S(V);#i=S(ve);#o=S(Ce);#a=S(fe);#s=S(J);#r=S(Ge);#l=S(He);#n=S(Re);relayIsEnabled=this.#o.relayIsEnabled;isDarkMode=this.#e.isDarkMode;isNavOpen=this.#e.isNavOpen;isMobile=this.#e.isMobile;sidenavType=this.#e.sidenavType;machineName=U(()=>{let n=this.#l.serverSettings();if(n&&n["--machine-name"])return n["--machine-name"];if(n&&n["machine-name"])return n["machine-name"];let e=this.#n.allOptions().find(t=>t.name==="machine-name");return e&&e.defaultValue?e.defaultValue:this.#n.systemInfo()?.MachineName??"Unknown"});ngOnInit(){return this.#s.init(),this.#i.getBackups(!0),this.#t.getApiV1Serversettings().subscribe({next:n=>{let e=n["autogenerated-passphrase"]==="True",t=n["has-asked-for-password-change"]==="True";e&&!t&&this.#a.open(X,{maxWidth:"500px"})}})}toggleNav(){this.#e.toggleNav()}toggleBodyClass(){this.#e.toggleBodyClass()}changeDefaultClientTo(n){this.#_(n),window.location.replace(`/${n}`)}logout(){this.#r.logout()}#_(n){var e=new Date;e.setTime(e.getTime()+2160*60*60*1e3),document.cookie="default-client="+n+"; expires="+e.toUTCString()+"; path=/"}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=D({type:i,selectors:[["app-layout"]],decls:43,vars:12,consts:()=>{let n;n=$localize`${"\uFFFD#11\uFFFD"}:START_TAG_SH_ICON:house${"\uFFFD/#11\uFFFD"}:CLOSE_TAG_SH_ICON: Home `;let e;e=$localize`${"\uFFFD#14\uFFFD"}:START_TAG_SH_ICON:database${"\uFFFD/#14\uFFFD"}:CLOSE_TAG_SH_ICON: Add backup `;let t;t=$localize`${"\uFFFD#17\uFFFD"}:START_TAG_SH_ICON:clock-counter-clockwise${"\uFFFD/#17\uFFFD"}:CLOSE_TAG_SH_ICON: Restore `;let s;s=$localize`${"\uFFFD#20\uFFFD"}:START_TAG_SH_ICON:gear${"\uFFFD/#20\uFFFD"}:CLOSE_TAG_SH_ICON: Settings `;let l;l=$localize`${"\uFFFD#32\uFFFD"}:START_TAG_SH_ICON:info${"\uFFFD/#32\uFFFD"}:CLOSE_TAG_SH_ICON: About Duplicati `;let P;P=$localize`${"\uFFFD#35\uFFFD"}:START_TAG_SH_ICON:files${"[\uFFFD/#35\uFFFD|\uFFFD/#36\uFFFD]"}:CLOSE_TAG_SH_ICON: Documentation ${"\uFFFD#36\uFFFD"}:START_TAG_SH_ICON_1:arrow-square-out${"[\uFFFD/#35\uFFFD|\uFFFD/#36\uFFFD]"}:CLOSE_TAG_SH_ICON:`,P=v(P);let I;I=$localize`${"\uFFFD#39\uFFFD"}:START_TAG_SH_ICON:chats-circle${"[\uFFFD/#39\uFFFD|\uFFFD/#40\uFFFD]"}:CLOSE_TAG_SH_ICON: Visit forum ${"\uFFFD#40\uFFFD"}:START_TAG_SH_ICON_1:arrow-square-out${"[\uFFFD/#39\uFFFD|\uFFFD/#40\uFFFD]"}:CLOSE_TAG_SH_ICON:`,I=v(I);let R;R=$localize`${"\uFFFD#2\uFFFD"}:START_TAG_SH_ICON:skip-back${"\uFFFD/#2\uFFFD"}:CLOSE_TAG_SH_ICON: Use old UI `;let G;return G=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:sign-out${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON: Log out `,[n,e,t,s,l,P,I,R,G,[3,"isOpenChange","isOpen","disableDrag"],["sidenav-closed-topbar",""],["sidenav",""],["shButton","",1,"icon","small",3,"click"],[1,"base-1","primary"],["action","","routerLink","/","routerLinkActive","active",3,"routerLinkActiveOptions"],["action","","routerLink","/add-backup","routerLinkActive","active"],["action","","routerLink","/restore","routerLinkActive","active"],["action","","routerLink","/settings","routerLinkActive","active"],["action","",1,"machine-name",3,"title"],[1,"spacer"],[1,"base-1l","primary"],["action","","routerLink","/about","routerLinkActive","active"],["href","https://docs.duplicati.com","target","_blank","action",""],["suffix",""],["href","https://forum.duplicati.com","target","_blank","action",""],["shButton","",1,"small","toggle-sidebar",3,"click"],[1,"cross"],[1,"burger"],["action","",3,"click"]]},template:function(e,t){e&1&&(a(0,"sh-sidenav",9),H("isOpenChange",function(l){return $(t.isNavOpen,l)||(t.isNavOpen=l),l}),d(1,rt,4,1,"ng-container",10),a(2,"div",11)(3,"header"),_(4,"app-logo"),a(5,"button",12),T("click",function(){return t.toggleBodyClass()}),d(6,lt,2,0,"sh-icon")(7,_t,2,0,"sh-icon"),o()(),a(8,"sh-list",13)(9,"button",14),g(10,0),_(11,"sh-icon"),C(),o(),a(12,"button",15),g(13,1),_(14,"sh-icon"),C(),o(),a(15,"button",16),g(16,2),_(17,"sh-icon"),C(),o(),a(18,"button",17),g(19,3),_(20,"sh-icon"),C(),o(),_(21,"sh-divider"),a(22,"div",18)(23,"sh-icon"),u(24,"desktop"),o(),u(25),o()(),_(26,"div",19),a(27,"sh-list",20),d(28,ct,6,0),_(29,"sh-divider"),a(30,"button",21),g(31,4),_(32,"sh-icon"),C(),o(),a(33,"a",22),g(34,5),_(35,"sh-icon")(36,"sh-icon",23),C(),o(),a(37,"a",24),g(38,6),_(39,"sh-icon")(40,"sh-icon",23),C(),o()()(),_(41,"router-outlet")(42,"app-service-hub"),o()),e&2&&(L(t.sidenavType()),y("isOpen",t.isNavOpen),O("disableDrag",!0),r(),p(t.isMobile()?1:-1),r(5),p(t.isDarkMode()?6:7),r(3),O("routerLinkActiveOptions",ce(11,ot)),r(13),O("title",_e(t.machineName())),r(3),b(" ",t.machineName()," "),r(3),p(t.relayIsEnabled()?-1:28))},dependencies:[pe,Se,ge,De,M,Le,Y,Pe,x,be],styles:["[_nghost-%COMP%]{height:100vh;width:100%;overflow:hidden}header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;padding:1.25rem;gap:.75rem}.toggle-sidebar[_ngcontent-%COMP%]{position:relative;display:flex;align-items:center;justify-content:center}.toggle-sidebar[_ngcontent-%COMP%] .cross[_ngcontent-%COMP%], .toggle-sidebar[_ngcontent-%COMP%] .burger[_ngcontent-%COMP%]{opacity:1;transition:opacity 124ms linear;margin:0}.toggle-sidebar[_ngcontent-%COMP%] .cross.hidden[_ngcontent-%COMP%], .toggle-sidebar[_ngcontent-%COMP%] .burger.hidden[_ngcontent-%COMP%]{opacity:0}.toggle-sidebar[_ngcontent-%COMP%] .burger[_ngcontent-%COMP%]{position:absolute;inset:auto}h3[title][_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between}div[sidenav][_ngcontent-%COMP%]{display:flex;flex-direction:column;height:100vh}.machine-name[_ngcontent-%COMP%]{margin:0;cursor:default}"],changeDetection:0})};export{Z as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as z}from"./chunk-TPBZNCDW.js";import"./chunk-RDCD2W2C.js";import{a as X}from"./chunk-TJIZJNCK.js";import"./chunk-ZSZLXWN6.js";import"./chunk-72HORZFV.js";import"./chunk-6Q6SSTBK.js";import"./chunk-MTQKK2WN.js";import"./chunk-LN26XMBJ.js";import"./chunk-XVWOVBC4.js";import"./chunk-WXF4HUYT.js";import{e as E}from"./chunk-ABYM5HWA.js";import"./chunk-Z35OG2DV.js";import{B as g,C,F as
|
|
1
|
+
import{a as z}from"./chunk-TPBZNCDW.js";import"./chunk-RDCD2W2C.js";import{a as X}from"./chunk-TJIZJNCK.js";import"./chunk-ZSZLXWN6.js";import"./chunk-72HORZFV.js";import"./chunk-6Q6SSTBK.js";import"./chunk-MTQKK2WN.js";import"./chunk-LN26XMBJ.js";import"./chunk-XVWOVBC4.js";import"./chunk-WXF4HUYT.js";import{e as E}from"./chunk-ABYM5HWA.js";import"./chunk-Z35OG2DV.js";import{B as g,C,F as v,K as w,u as S}from"./chunk-QF4DQYEP.js";import{h as J}from"./chunk-PD73DDOS.js";import"./chunk-I2LW33GO.js";import"./chunk-5ZSBXGHQ.js";import"./chunk-FPPZ4BUR.js";import"./chunk-JYWOYPSQ.js";import{$b as m,Ab as x,Bb as I,Bc as u,Cb as p,Cc as G,Db as e,Eb as i,Fb as a,Jb as L,Kb as $,Sa as s,Tb as b,Ub as D,Vb as c,Wb as y,Xb as A,_ as d,cb as O,ib as N,nc as r,qc as B,sb as h,tb as P,xb as M,yb as F,zb as k}from"./chunk-QONLYWYC.js";import"./chunk-EUDKD2JW.js";var j=()=>[C,g,S,E],W=()=>["/restore-from-files"],H=()=>["/restore/from-config"],q=n=>["/restore",n];function V(n,o){if(n&1&&(e(0,"sh-card",5),a(1,"img",10),e(2,"div",7)(3,"h3"),c(4,1),i(),e(5,"p"),r(6),i()(),e(7,"button",8),b(8,2),a(9,"sh-icon"),D(),i()()),n&2){let t=o.$implicit;p("routerLink",G(4,q,t.Backup.ID)),s(4),y(t.Backup.Name??"Backup name missing"),A(4),s(2),B(" ",(t.Backup.Metadata==null?null:t.Backup.Metadata.SourceSizeString)??"-"," / ",(t.Backup.Metadata==null?null:t.Backup.Metadata.BackupListCount)??"-"," ")}}function K(n,o){if(n&1&&x(0,V,10,6,"sh-card",5,k),n&2){let t=m(2);I(t.backups())}}function Q(n,o){n&1&&(L(0),c(1,3),$())}function U(n,o){if(n&1&&M(0,K,2,0)(1,Q,2,0,"ng-container"),n&2){let t=m();F(t.backups().length?0:1)}}function Y(n,o){n&1&&(e(0,"div",11),a(1,"sh-progress-bar",12),e(2,"div",7)(3,"h3"),c(4,4),i()()())}var T=class n{#e=d(X);#t=d(J);backups=this.#e.backups;backupsLoading=this.#e.backupsLoading;ngOnInit(){this.#e.getBackups(!0)}restoreNow(o){this.#t.postApiV1BackupByIdRestore({id:o.Backup?.ID,requestBody:{}})}static \u0275fac=function(t){return new(t||n)};static \u0275cmp=O({type:n,selectors:[["app-restore"]],decls:32,vars:5,consts:()=>{let o;o=$localize`Where do you want to restore from?`;let t;t=$localize`${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let _;_=$localize` Restore ${"\uFFFD#9\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#9\uFFFD"}:CLOSE_TAG_SH_ICON:`;let R;R=$localize`No backups founds`;let f;return f=$localize`Loading backups...`,[o,t,_,R,f,[1,"type-a","actionable",3,"routerLink"],["src","assets/images/backup.png","alt","","width","48px"],[1,"text"],["shButton",""],["src","assets/images/restore.png","alt","","width","48px"],["src","assets/images/folder.png","alt","","width","48px"],[1,"loading-list"],[1,"indeterminate","primary"]]},template:function(t,_){t&1&&(a(0,"app-status-bar"),e(1,"section")(2,"h2"),c(3,0),i(),e(4,"sh-card",5),a(5,"img",6),e(6,"div",7)(7,"h3"),r(8,"Direct restore from backup files"),i(),e(9,"p"),r(10,"Point to your backup files and restore from there."),i()(),e(11,"button",8),r(12," Start "),e(13,"sh-icon"),r(14,"play-circle"),i()()(),e(15,"sh-card",5),a(16,"img",9),e(17,"div",7)(18,"h3"),r(19,"Restore from configuration"),i(),e(20,"p"),r(21,"Load destination from an exported job"),i()(),e(22,"button",8),r(23," Start "),e(24,"sh-icon"),r(25,"play-circle"),i()()(),e(26,"sh-divider"),r(27,"Or existing"),i(),N(28,U,2,1)(29,Y,5,0),h(30,28,j,null,29),i()),t&2&&(s(4),p("routerLink",u(3,W)),s(11),p("routerLink",u(4,H)),s(15),P(!_.backupsLoading()))},dependencies:[z,C,g,v,S,w,E],styles:["[_nghost-%COMP%]{display:block}h2[_ngcontent-%COMP%]{font:var(--title-30);text-align:center;padding:2rem}section[_ngcontent-%COMP%]{max-width:43.75rem;margin:0 auto;padding:2rem 1rem;display:flex;flex-direction:column;gap:1rem}sh-divider[_ngcontent-%COMP%]{color:var(--base-8)}sh-card[_ngcontent-%COMP%]{display:flex;align-items:center;gap:1rem;--card-padding: 2rem}sh-card[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{flex:1 0;display:flex;flex-direction:column;gap:.25rem}.actionable[_ngcontent-%COMP%]{cursor:pointer}.actionable[_ngcontent-%COMP%]:after{transition:inset .1s linear}.actionable[_ngcontent-%COMP%]:hover{--card-shp: 0}"],changeDetection:0})};export{T as default};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as pt}from"./chunk-TPBZNCDW.js";import{a as Ct}from"./chunk-YJPY33RI.js";import{a as gt}from"./chunk-EE5UMXWP.js";import{a as k}from"./chunk-VRV52R6I.js";import"./chunk-Z27IQRKV.js";import"./chunk-RDCD2W2C.js";import"./chunk-TJIZJNCK.js";import"./chunk-ZSZLXWN6.js";import{a as ct}from"./chunk-72HORZFV.js";import"./chunk-6Q6SSTBK.js";import{a as ne}from"./chunk-MTQKK2WN.js";import"./chunk-LN26XMBJ.js";import"./chunk-XVWOVBC4.js";import{a as nt}from"./chunk-WXF4HUYT.js";import"./chunk-ABYM5HWA.js";import"./chunk-Z35OG2DV.js";import{B as D,E as st,F as at,G as te,K as rt,L as lt,M as _t,O as dt,V as Tt,X as St,c as j,e as K,i as Q,m as it,s as Y,t as Z,u as F,w as ee,z as ot}from"./chunk-QF4DQYEP.js";import{h as x}from"./chunk-PD73DDOS.js";import"./chunk-I2LW33GO.js";import"./chunk-5ZSBXGHQ.js";import"./chunk-FPPZ4BUR.js";import"./chunk-JYWOYPSQ.js";import{$b as S,B as $,Bc as q,Cb as h,Db as i,Eb as o,Fb as I,H as R,Mb as P,Pa as He,Qc as A,Rc as b,Sa as l,Tb as z,Ub as B,V as We,Vb as r,Wb as ae,Xb as re,Xc as tt,Yb as Qe,Zb as c,_ as N,a as Ue,b as ze,c as Be,cb as w,ea as u,fa as m,gc as Ye,hb as se,hc as Ze,ib as qe,kc as M,n as L,nc as O,oc as W,pa as T,pc as H,sb as je,sc as G,tb as Ke,tc as y,uc as v,xb as p,yb as C,yc as et}from"./chunk-QONLYWYC.js";import"./chunk-EUDKD2JW.js";var Et=["formRef"],Nt=()=>[import("./chunk-NC73IOHK.js").then(s=>s.OptionsListComponent)];function ft(s,e){s&1&&(i(0,"sh-alert",3),r(1,1),o())}function ht(s,e){if(s&1){let t=P();i(0,"app-options-list",5),v("optionsChange",function(a){u(t);let _=S();return y(_.settings,a)||(_.settings=a),m(a)}),o()}if(s&2){let t=S();G("options",t.settings),h("hasFreeTextSettings",!0)}}var X=class s{#e=N(k);#t=N(x);formRef=tt.required("formRef");settings=T([]);isSubmitting=T(!1);isLoadingOptions=T(!0);saved=T(!1);lastRecievedServerSettings=T({});serverSettingsEffect=b(()=>{let e=this.#e.serverSettings();if(e===void 0)return;this.lastRecievedServerSettings.set(e),this.isLoadingOptions.set(!0);let t=Object.entries(e);t.forEach(([n,a],_)=>{if(n.startsWith("--")){let E=n.substring(2);this.settings.update(g=>(g.some(f=>f.Name===E)||g.push({Name:E,Value:a}),g))}_===t.length-1&&this.isLoadingOptions.set(!1)})});submit(){this.isSubmitting.set(!0);let e=this.settings(),t=this.lastRecievedServerSettings(),n=e.map(g=>g.Name),_=Object.keys(t).filter(g=>g.startsWith("--")).filter(g=>!n.includes(g.replace("--",""))),E=e.reduce((g,f)=>{let V=f.Name?.startsWith("--")?f.Name:`--${f.Name}`;return g[V]=f.Value,g},{});_.forEach(g=>{E[g]=null}),this.#t.patchApiV1Serversettings({requestBody:E}).pipe(R(()=>this.isSubmitting.set(!1))).subscribe({next:()=>{this.#e.refreshServerSettings(),this.saved.set(!0),setTimeout(()=>{this.saved.set(!1)},3e3)}})}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=w({type:s,selectors:[["app-advanced-options-settings"]],viewQuery:function(t,n){t&1&&Ye(n.formRef,Et,5),t&2&&Ze()},decls:8,vars:4,consts:()=>{let e;e=$localize`${"\uFFFD#4\uFFFD"}:START_TAG_SH_ICON:floppy-disk${"\uFFFD/#4\uFFFD"}:CLOSE_TAG_SH_ICON: Save settings `;let t;return t=$localize`Settings saved`,[e,t,[1,"actions"],[1,"success"],["shButton","","type","button",1,"raised","primary",3,"click"],[3,"optionsChange","options","hasFreeTextSettings"]]},template:function(t,n){t&1&&(i(0,"div",2),p(1,ft,2,0,"sh-alert",3),i(2,"button",4),c("click",function(){return n.submit()}),z(3,0),I(4,"sh-icon"),B(),o()(),qe(5,ht,1,2),je(6,5,Nt)),t&2&&(l(),C(n.saved()?1:-1),l(),M("loader",n.isSubmitting()),l(4),Ke(!n.isLoadingOptions()))},dependencies:[Z,D,F,ee],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})};var J=class s{#e=N(ot);#t=N(x);#o=N(ne);repeatRegisterTimer=null;state=T("unknown");claimUrl=T(null);registerUrl=T("");status=A(()=>{let e=this.state();return e==="enabled"?"Remote control is enabled but not connected":e==="connected"?"Remote control is connected":e==="registering"?"Registering machine...":e==="registeringfaulted"?"Registration failed":e==="registered"?"Registered, waiting for accept":e==="disabled"?"Remote control is configured but not enabled":e==="unknown"?"...loading...":"Remote control is not set up"});sysInfoEffect=b(()=>{let e=this.#o.systemInfo();e&&this.registerUrl.set(e.RemoteControlRegistrationUrl??"")});#n(e){e.RegistrationUrl&&this.claimUrl.set(e.RegistrationUrl),e.IsConnected?this.state.set("connected"):e.IsEnabled?this.state.set("enabled"):e.CanEnable?this.state.set("disabled"):e.IsRegisteringFaulted?this.state.set("registeringfaulted"):e.IsRegistering?e.RegistrationUrl!=null&&e.RegistrationUrl.trim().length>0?this.state.set("registered"):this.state.set("registering"):this.state.set("inactive");let t=this.state();this.repeatRegisterTimer!==null&&(clearTimeout(this.repeatRegisterTimer),this.repeatRegisterTimer=null),t==="registering"&&(this.repeatRegisterTimer=setTimeout(()=>{this.#t.postApiV1RemotecontrolRegister({requestBody:{RegistrationUrl:""}}).subscribe({next:n=>this.#n(n),error:n=>this.#i(n)})},5e3)),(t==="enabled"||t==="registered")&&(this.repeatRegisterTimer=setTimeout(()=>{this.#t.getApiV1RemotecontrolStatus().subscribe({next:n=>this.#n(n),error:n=>this.#i(n)})},5e3)),e.IsRegistering&&e.CanEnable&&this.#t.deleteApiV1RemotecontrolRegister().subscribe({next:n=>this.#n(n)})}#i(e){this.#t.getApiV1RemotecontrolStatus().subscribe({next:t=>this.#n(t)})}refreshRemoteControlStatus(){this.#t.getApiV1RemotecontrolStatus().subscribe({next:e=>this.#n(e),error:e=>this.#i(e)})}beginRemoteRegistration(){this.state.set("registering"),this.#t.postApiV1RemotecontrolRegister({requestBody:{RegistrationUrl:this.registerUrl()}}).subscribe({next:e=>this.#n(e),error:e=>this.#i(e)})}cancelRemoteRegistration(){this.#t.deleteApiV1RemotecontrolRegister().subscribe({next:e=>this.#n(e),error:e=>this.#i(e)})}enableRemoteControl(){this.#t.postApiV1RemotecontrolEnable().subscribe({next:e=>this.#n(e),error:e=>this.#i(e)})}disableRemoteControl(){this.#t.postApiV1RemotecontrolDisable().subscribe({next:e=>this.#n(e),error:e=>this.#i(e)})}deleteRemoteControl(){let e=this;this.#e.open(ct,{data:{title:$localize`Confirm delete`,message:$localize`Are you sure you want to delete the remote control registration?`,confirmText:$localize`Delete registration`,cancelText:$localize`Cancel`},closed:t=>{t&&e.#t.deleteApiV1RemotecontrolRegistration().subscribe({next:n=>e.#n(n),error:n=>e.#i(n)})}})}static \u0275fac=function(t){return new(t||s)};static \u0275prov=We({token:s,factory:s.\u0275fac,providedIn:"root"})};function Pt(s,e){if(s&1){let t=P();i(0,"sh-form-field",11)(1,"input",12),v("ngModelChange",function(a){u(t);let _=S(2);return y(_.registerUrl,a)||(_.registerUrl=a),m(a)}),o()(),i(2,"button",13),c("click",function(){u(t);let a=S(2);return m(a.register())}),r(3,0),o()}if(s&2){let t=S(2);l(),G("ngModel",t.registerUrl)}}function Ot(s,e){if(s&1&&(i(0,"div",8)(1,"label"),r(2,1),o(),i(3,"a",14),O(4),o()()),s&2){let t=S(2);l(3),h("href",et(t.claimUrl()),He),l(),W(t.claimUrl())}}function Rt(s,e){s&1&&(i(0,"div",8)(1,"label"),r(2,2),o()())}function It(s,e){if(s&1){let t=P();i(0,"button",13),c("click",function(){u(t);let a=S(2);return m(a.cancel())}),r(1,3),o()}}function Gt(s,e){if(s&1){let t=P();i(0,"button",13),c("click",function(){u(t);let a=S(2);return m(a.disable())}),r(1,4),o()}}function yt(s,e){if(s&1){let t=P();i(0,"button",13),c("click",function(){u(t);let a=S(2);return m(a.enable())}),r(1,5),o(),i(2,"button",15),c("click",function(){u(t);let a=S(2);return m(a.delete())}),r(3,6),o()}}function vt(s,e){s&1&&(i(0,"sh-icon"),O(1,"check"),o())}function At(s,e){s&1&&(i(0,"sh-icon"),O(1,"copy"),o())}function bt(s,e){if(s&1){let t=P();i(0,"sh-chip",16),c("click",function(){u(t);let a=S(2);return m(a.copyReportingUrl())}),O(1," Reporting configured by server "),p(2,vt,2,0,"sh-icon")(3,At,2,0,"sh-icon"),o()}if(s&2){let t=S(2);l(2),C(t.copiedReportingUrl()===!0?2:3)}}function Lt(s,e){if(s&1&&(i(0,"div",7),p(1,Pt,4,1),p(2,Ot,5,3,"div",8),p(3,Rt,3,0,"div",8),p(4,It,2,0,"button",9),p(5,Gt,2,0,"button",9),p(6,yt,4,0),p(7,bt,4,1,"sh-chip",10),o()),s&2){let t=S();l(),C(t.state()==="inactive"?1:-1),l(),C(t.state()==="registered"?2:-1),l(),C(t.state()==="registering"?3:-1),l(),C(t.state()==="registering"||t.state()==="registeringfaulted"||t.state()==="registered"?4:-1),l(),C(t.state()==="connected"||t.state()==="enabled"?5:-1),l(),C(t.state()==="disabled"?6:-1),l(),C(t.additionalReportingUrl()!==""?7:-1)}}var ie=class s{#e=N(J);#t=N(k);state=this.#e.state;claimUrl=this.#e.claimUrl;registerUrl=this.#e.registerUrl;additionalReportingUrl=A(()=>{let e=this.#t.serverSettings();return e&&e["additional-report-url"]||""});copiedReportingUrl=T(!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 e=this.additionalReportingUrl();e&&(this.copiedReportingUrl.set(!0),setTimeout(()=>this.copiedReportingUrl.set(!1),2e3),navigator.clipboard.writeText(e))}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=w({type:s,selectors:[["app-remote-control"]],decls:1,vars:1,consts:()=>{let e;e=$localize`Register for remote control`;let t;t=$localize`Machine is now registered, open this link to add it to your account:`;let n;n=$localize`Registering, please wait...`;let a;a=$localize`Cancel registration`;let _;_=$localize`Disable remote control`;let E;E=$localize`Enable remote control`;let g;return g=$localize`Delete remote control setup`,[e,t,n,a,_,E,g,[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(t,n){t&1&&p(0,Lt,8,7,"div",7),t&2&&C(n.state()!=="unknown"?0:-1)},dependencies:[Y,j,K,Q,te,D,st,F],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 mt(...s){let e=T(...s);return Object.defineProperty(e,"value",{get:e.asReadonly(),set:e.set.bind(e)})}var _e=()=>({standalone:!0});function $t(s,e){s&1&&(i(0,"sh-icon",69),O(1,"check"),o())}function wt(s,e){s&1&&(i(0,"sh-icon",70),O(1,"prohibit"),o())}function Ft(s,e){if(s&1){let t=P();i(0,"button",74),c("click",function(){u(t);let a=S(2);return m(a.updatePassphrase())}),r(1,34),o()}if(s&2){let t=S(2);M("loader",t.isUpdating())}}function Dt(s,e){if(s&1){let t=P();i(0,"button",75),c("click",function(){u(t);let a=S(2);return m(a.updatePassphrase())}),r(1,35),o()}if(s&2){let t=S(2);M("loader",t.isUpdating()),h("disabled",!0)}}function xt(s,e){if(s&1){let t=P();i(0,"sh-form-field")(1,"label",65),r(2,31),o(),i(3,"input",66),v("ngModelChange",function(a){u(t);let _=S();return y(_.passphrase,a)||(_.passphrase=a),m(a)}),o()(),i(4,"sh-form-field")(5,"label",67),r(6,32),o(),i(7,"input",68),v("ngModelChange",function(a){u(t);let _=S();return y(_.repeatPassphrase,a)||(_.repeatPassphrase=a),m(a)}),o(),p(8,$t,2,0,"sh-icon",69)(9,wt,2,0,"sh-icon",70),o(),i(10,"div",48)(11,"button",71),c("click",function(){u(t);let a=S();return m(a.cancelPasswordChange())}),r(12,33),o(),p(13,Ft,2,2,"button",72)(14,Dt,2,3,"button",73),o()}if(s&2){let t=S();l(3),G("ngModel",t.passphrase),l(4),h("disabled",t.passphrase().length===0),G("ngModel",t.repeatPassphrase),l(),C(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?8:9),l(3),M("loader",t.isUpdating()),l(2),C(t.passphrase().length!==0&&t.passphrase()===t.repeatPassphrase()?13:14)}}function kt(s,e){s&1&&(i(0,"sh-icon",76),O(1,"check"),o())}function Jt(s,e){if(s&1){let t=P();i(0,"div",48)(1,"button",71),c("click",function(){u(t);let a=S();return m(a.openPassphraseForm())}),r(2,36),o(),p(3,kt,2,0,"sh-icon",76),o()}if(s&2){let t=S();l(3),C(t.passwordUpdated()?3:-1)}}function Xt(s,e){if(s&1){let t=P();i(0,"sh-form-field")(1,"label",77),r(2,37),o(),i(3,"textarea",78),v("ngModelChange",function(a){u(t);let _=S();return y(_.allowedHostnames,a)||(_.allowedHostnames=a),m(a)}),o()(),i(4,"sh-alert",79),r(5,38),o(),i(6,"button",74),c("click",function(){u(t);let a=S();return m(a.updateAllowedHostnames())}),r(7,39),o()}if(s&2){let t=S();l(3),G("ngModel",t.allowedHostnames),l(3),M("loader",t.updatingAllowedHosts())}}function Vt(s,e){if(s&1&&O(0),s&2){let t,n=S();H(" ",(t=n.sysinfo())==null?null:t.ServerVersion," ")}}function Ut(s,e){s&1&&I(0,"sh-progress-bar",53)}function zt(s,e){if(s&1&&O(0),s&2){let t=e.$implicit;H(" ",t.label," ")}}function Bt(s,e){if(s&1&&O(0),s&2){let t=e.$implicit;H(" ",t.label," ")}}function Wt(s,e,t){let n=mt(s),a=n[Ue];t?.equal&&(a.equal=t.equal);let _;return n.set=E=>{clearTimeout(_),_=setTimeout(()=>ze(a,E),e)},n.update=E=>{clearTimeout(_),_=setTimeout(()=>Be(a,E),e)},n}var Ht=[{value:"none",label:$localize`None`},{value:"s",label:$localize`Seconds`},{value:"m",label:$localize`Minutes`},{value:"h",label:$localize`Hours`}],qt=[{value:"none",label:$localize`System default (information)`},{value:"information",label:$localize`Usage statistics, warnings, errors, and crashes`},{value:"warning",label:$localize`Warnings, errors and crashes`},{value:"error",label:$localize`Errors and crashes`},{value:"crash",label:$localize`Crashes only`},{value:"none",label:$localize`None / disabled`}],de=class s{#e=N(gt);#t=N(ne);#o=N(x);#n=N(k);#i=N(J);#s=N(nt);#a=this.#s.getItem("locale")??"en-US";sysinfo=this.#t.systemInfo;isDarkMode=this.#e.isDarkMode;editAs=T("list");previousLang=this.#a;langCtrl=T(this.#a);usageStatistics=T("");updatingUsageStatistics=T(!1);remoteControlStatus=this.#i.status;updatingChannel=T(!1);updateChannel=T("");setNewChannel(e){let t=this.updateChannel();this.updateChannel.set(e),this.#o.patchApiV1Serversettings({requestBody:{"update-channel":e}}).pipe(R(()=>this.updatingChannel.set(!1)),$(()=>(this.updateChannel.set(t),L(null)))).subscribe()}allowRemoteAccess=T(!1);allowedHostnames=T("");loadedAllowedHostnames=T("");updatingRemoteAccess=T(!1);updatingAllowedHosts=T(!1);updateRemoteAccess(){let e=this.allowRemoteAccess(),t=!e;this.allowRemoteAccess.set(t),this.#o.patchApiV1Serversettings({requestBody:{"server-listen-interface":t?"any":"loopback"}}).pipe(R(()=>this.updatingRemoteAccess.set(!1)),$(()=>(this.allowRemoteAccess.set(e),L(null)))).subscribe()}updateAllowedHostnames(){let e=this.loadedAllowedHostnames(),t=this.allowedHostnames();this.updatingAllowedHosts.set(!0),this.#o.patchApiV1Serversettings({requestBody:{"server-listen-interface":"any","allowed-hostnames":t}}).pipe(R(()=>this.updatingAllowedHosts.set(!1)),$(()=>(this.allowedHostnames.set(e),L(null)))).subscribe()}updatingDisableTrayIconLogin=T(!1);disableTrayIconLogin=T(!1);saveDisableTrayIconLogin(){let e=this.disableTrayIconLogin(),t=!e;this.updatingDisableTrayIconLogin.set(!0),this.disableTrayIconLogin.set(t),this.#o.patchApiV1Serversettings({requestBody:{"disable-tray-icon-login":t?"True":"False"}}).pipe(R(()=>this.updatingDisableTrayIconLogin.set(!1)),$(()=>(this.disableTrayIconLogin.set(e),L(null)))).subscribe()}showPassphraseForm=T(!1);isUpdating=T(!1);passphrase=T("");repeatPassphrase=T("");passwordUpdated=T(!1);updatePassphrase(){this.passphrase()===this.repeatPassphrase()&&(this.isUpdating.set(!0),this.#o.patchApiV1Serversettings({requestBody:{"server-passphrase":this.passphrase()}}).pipe(R(()=>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=T(Ct);usageStatisticsOptions=T(qt);timeTypeOptions=T(Ht);timeType=T("none");timeValue=Wt(0,300);timeRange=A(()=>this.timeType()==="h"?[0,24]:[0,60]);timeValueEffect=b(()=>{let e=this.timeValue(),t=this.#n.serverSettings();!t||t["startup-delay"]===""&&this.timeType()==="none"||this.updateStartupDelay()});updateLocale(e){!e||e===""||e===this.previousLang||(this.#s.setItem("locale",e),window.location.reload())}updateStartupDelay(){let e=this.timeValue(),t=this.timeType(),n="";t!=="none"&&e!==0&&(n=`${e}${t}`),this.#o.patchApiV1Serversettings({requestBody:{"startup-delay":n}}).subscribe()}updateTimeType(e){this.timeType()==="none"&&this.timeValue.set(0),this.timeType.set(e)}updateUsageStatistics(e){let t=this.usageStatistics();!e||e===""||e===t||(this.usageStatistics.set(e),this.updatingUsageStatistics.set(!0),this.#o.patchApiV1Serversettings({requestBody:{"usage-reporter-level":this.usageStatistics()==="none"?"":this.usageStatistics()}}).pipe(R(()=>this.updatingUsageStatistics.set(!1)),$(()=>(this.usageStatistics.set(t),L(null)))).subscribe())}serverSettingsEffect=b(()=>{let e=this.#n.serverSettings();if(e===void 0)return;let t=e["startup-delay"],n=t.slice(-1),a=t.slice(0,-1),_=["s","m","h"];this.disableTrayIconLogin.set(e["disable-tray-icon-login"]!=="False"),this.updateChannel.set(e["update-channel"]),this.allowRemoteAccess.set(e["server-listen-interface"]==="any"),this.allowedHostnames.set(e["allowed-hostnames"]),this.loadedAllowedHostnames.set(e["allowed-hostnames"]),this.usageStatistics.set(e["usage-reporter-level"]===""?"none":e["usage-reporter-level"]),this.timeType.set(t==""?"none":_.includes(n)?n:"none"),this.timeValue.set(t==""?0:parseInt(a))});setDarkMode(){this.#e.setDarkMode()}setLightMode(){this.#e.setLightMode()}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=w({type:s,selectors:[["app-settings"]],decls:132,vars:46,consts:()=>{let e;e=$localize`Settings`;let t;t=$localize`Configure your backup settings.`;let n;n=$localize`Remote access control`;let a;a=$localize`Color theme`;let _;_=$localize`Customize your application theme`;let E;E=$localize`Passwords`;let g;g=$localize`Change server passphrase`;let f;f=$localize`Language`;let V;V=$localize`Select a language for the platform`;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 ge;ge=$localize`Prevent tray icon automatic log-in`;let pe;pe=$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 Ce;Ce=$localize`Prevent tray icon automatic log-in`;let ue;ue=$localize`Update channel`;let me;me=$localize` Default (${"\uFFFD0\uFFFD"}:INTERPOLATION:) `;let Ee;Ee=$localize`Same as the base install version: ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let Ne;Ne=$localize`Stable`;let fe;fe=$localize`Official stable release.`;let he;he=$localize`Beta`;let Me;Me=$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 Oe;Oe=$localize`Early previews of new features. Not for use with important data.`;let Re;Re=$localize`Canary`;let Ie;Ie=$localize`Builds for developers and testers only. Not for use with important data.`;let Ge;Ge=$localize`Pause after startup or hibernation`;let ye;ye=$localize` Duplicati will run when started, but will remain in paused state for the duration. Duplicati will occupy minimal system resources and no backups will be run. `;let ve;ve=$localize`Usage statistics`;let U;U=$localize` Usage reports help us improve the user experience and evaluate impact of new features. We use them to generate ${"\uFFFD#119\uFFFD"}:START_LINK:public usage statistics.${"\uFFFD/#119\uFFFD"}:CLOSE_LINK:${"[\uFFFD#120\uFFFD\uFFFD/#120\uFFFD|\uFFFD#121\uFFFD\uFFFD/#121\uFFFD]"}:LINE_BREAK:${"[\uFFFD#120\uFFFD\uFFFD/#120\uFFFD|\uFFFD#121\uFFFD\uFFFD/#121\uFFFD]"}:LINE_BREAK: 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. `,U=Qe(U);let Ae;Ae=$localize`Advanced options`;let be;be=$localize`Enter new password`;let Le;Le=$localize`Repeat password`;let oe;oe=$localize`Password have to be filled and have to match`;let $e;$e=$localize`Passphrase`;let we;we=$localize`Repeat passphrase`;let Fe;Fe=$localize`Cancel`;let De;De=$localize` Update passphrase `;let xe;xe=$localize` Update passphrase `;let ke;ke=$localize`Change password`;let Je;Je=$localize`Allowed hostnames`;let Xe;Xe=$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 Ve;return Ve=$localize` Update allowed hostnames `,[e,t,n,a,_,E,g,f,V,Te,Se,ce,ge,pe,Ce,ue,me,Ee,Ne,fe,he,Me,Pe,Oe,Re,Ie,Ge,ye,ve,U,Ae,$e,we,Fe,De,xe,ke,Je,Xe,Ve,[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","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"],["href","#"],["label","label","value","value",3,"options","isLoading"],[1,"advanced-settings"],["for","password"],["type","password","name","password","autocomplete","disabled","placeholder",be,"tabindex","1",3,"ngModelChange","ngModel"],["for","repeatPassword"],["type","password","name","repeatPassword","autocomplete","disabled","placeholder",Le,"tabindex","2",3,"ngModelChange","disabled","ngModel"],["suffix","",1,"sh-success"],["suffix",""],["shButton","",3,"click"],["shButton","",1,"raised","primary",3,"loader"],["shButton","","shTooltip",oe,1,"raised","primary",3,"loader","disabled"],["shButton","",1,"raised","primary",3,"click"],["shButton","","shTooltip",oe,1,"raised","primary",3,"click","disabled"],[1,"sh-success"],["for","allowedHostnames"],["type","text","id","allowedHostnames",3,"ngModelChange","ngModel"],["type","primary"]]},template:function(t,n){if(t&1&&(I(0,"app-status-bar"),i(1,"div",40)(2,"header")(3,"div",41)(4,"h2"),r(5,0),o(),i(6,"p"),r(7,1),o()()(),i(8,"section")(9,"div",42)(10,"h3"),r(11,2),o(),i(12,"p"),O(13),o()(),i(14,"div",43),I(15,"app-remote-control"),o()(),i(16,"section")(17,"div",42)(18,"h3"),r(19,3),o(),i(20,"p"),r(21,4),o()(),i(22,"div",43)(23,"div",44)(24,"img",45),c("click",function(){return n.setLightMode()}),o(),i(25,"img",46),c("click",function(){return n.setDarkMode()}),o()()()(),i(26,"section")(27,"div",42)(28,"h3"),r(29,5),o(),i(30,"p"),r(31,6),o()(),i(32,"div",47),p(33,xt,15,7)(34,Jt,4,1,"div",48),o()(),i(35,"section")(36,"div",42)(37,"h3"),r(38,7),o(),i(39,"p"),r(40,8),o()(),i(41,"div",43)(42,"sh-select",49)(43,"input",50),c("ngModelChange",function(_){return n.updateLocale(_)}),o()()()(),i(44,"section")(45,"div",42)(46,"h3"),r(47,9),o(),i(48,"p"),r(49,10),o()(),i(50,"div",51)(51,"sh-toggle",52),c("click",function(){return n.updateRemoteAccess()}),i(52,"label"),r(53,11),o()(),p(54,Xt,8,3),o()(),i(55,"section")(56,"div",42)(57,"h3"),r(58,12),o(),i(59,"p"),r(60,13),o()(),i(61,"div",43)(62,"sh-toggle",52),c("click",function(){return n.saveDisableTrayIconLogin()}),i(63,"label"),r(64,14),o()()()(),i(65,"section")(66,"div",42)(67,"h3"),r(68,15),o(),i(69,"p"),p(70,Vt,1,1),o(),p(71,Ut,1,0,"sh-progress-bar",53),o(),i(72,"div",54)(73,"div",55),c("click",function(){return n.setNewChannel("")}),i(74,"sh-radio",56),r(75,16),o(),i(76,"p"),r(77,17),o()(),i(78,"div",55),c("click",function(){return n.setNewChannel("stable")}),i(79,"sh-radio",56),r(80,18),o(),i(81,"p"),r(82,19),o()(),i(83,"div",55),c("click",function(){return n.setNewChannel("beta")}),i(84,"sh-radio",56),r(85,20),o(),i(86,"p"),r(87,21),o()(),i(88,"div",55),c("click",function(){return n.setNewChannel("experimental")}),i(89,"sh-radio",56),r(90,22),o(),i(91,"p"),r(92,23),o()(),i(93,"div",55),c("click",function(){return n.setNewChannel("canary")}),i(94,"sh-radio",56),r(95,24),o(),i(96,"p"),r(97,25),o()()()()(),I(98,"sh-divider"),i(99,"div",40)(100,"section")(101,"div",42)(102,"h3"),r(103,26),o(),i(104,"p"),r(105,27),o()(),i(106,"div",43)(107,"div",57)(108,"sh-range-slider",58)(109,"input",59),v("ngModelChange",function(_){return y(n.timeValue,_)||(n.timeValue=_),_}),o()(),i(110,"sh-select",60)(111,"input",61),c("ngModelChange",function(_){return n.updateTimeType(_)}),o(),se(112,zt,1,1,"ng-template"),o()()()(),i(113,"section")(114,"div",42)(115,"h3"),r(116,28),o(),i(117,"p"),z(118,29),I(119,"a",62)(120,"br")(121,"br"),B(),o()(),i(122,"div",43)(123,"sh-select",63)(124,"input",50),c("ngModelChange",function(_){return n.updateUsageStatistics(_)}),o(),se(125,Bt,1,1,"ng-template"),o()()()(),i(126,"div",40)(127,"section")(128,"div",64)(129,"h3"),r(130,30),o(),I(131,"app-advanced-options-settings"),o()()()),t&2){let a,_,E;l(13),W(n.remoteControlStatus()),l(11),M("active",!n.isDarkMode()),l(),M("active",n.isDarkMode()),l(8),C(n.showPassphraseForm()?33:34),l(9),h("options",n.languageOptions())("isClearable",!1)("inlineSearch",!0),l(),h("ngModel",n.langCtrl())("ngModelOptions",q(43,_e)),l(8),M("active",n.allowRemoteAccess()),l(3),C(n.allowRemoteAccess()?54:-1),l(8),M("active",n.disableTrayIconLogin()),l(8),C(n.updateChannel()!==""&&((a=n.sysinfo())!=null&&a.ServerVersion)?70:-1),l(),C(n.updatingChannel()?71:-1),l(3),M("active",n.updateChannel()===""),l(),ae((_=n.sysinfo())==null?null:_.DefaultUpdateChannel),re(75),l(2),ae((E=n.sysinfo())==null?null:E.ServerVersionType),re(77),l(2),M("active",n.updateChannel()==="stable"),l(5),M("active",n.updateChannel()==="beta"),l(5),M("active",n.updateChannel()==="experimental"),l(5),M("active",n.updateChannel()==="canary"),l(14),h("unit",n.timeType()==="none"?"s":n.timeType()),l(),h("min",n.timeRange()[0])("max",n.timeRange()[1])("disabled",n.timeType()==="none"),G("ngModel",n.timeValue),h("ngModelOptions",q(44,_e)),l(),h("options",n.timeTypeOptions())("isClearable",!1),l(),h("ngModel",n.timeType()),l(12),h("options",n.usageStatisticsOptions())("isLoading",n.updatingUsageStatistics()),l(),h("ngModel",n.usageStatistics())("ngModelOptions",q(45,_e))}},dependencies:[Y,j,it,K,Q,Z,pt,ie,X,D,lt,_t,rt,Tt,St,te,F,at,ee,dt],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)}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}"],changeDetection:0})};export{Wt as debounceSignal,de as default};
|