@duplicati/ngclient 0.0.211 → 0.0.213

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.
Files changed (134) hide show
  1. package/assets/sh.woff2 +0 -0
  2. package/{chunk-SUY5AQLW.js → chunk-22PELS6R.js} +1 -1
  3. package/{chunk-U3SGWHNI.js → chunk-2NLWVJNK.js} +1 -1
  4. package/{chunk-RFB5A3B7.js → chunk-35APLYI4.js} +1 -1
  5. package/{chunk-6FBNKISB.js → chunk-3IZWJV72.js} +1 -1
  6. package/chunk-3PUCEFO5.js +1 -0
  7. package/{chunk-LGILJ5LY.js → chunk-3XCT4PYH.js} +1 -1
  8. package/{chunk-DV7RWC4G.js → chunk-5FQ5SDPZ.js} +1 -1
  9. package/{chunk-ITA7DTN3.js → chunk-5L2OOKRZ.js} +1 -1
  10. package/chunk-5REJ6F23.js +1 -0
  11. package/chunk-7FDLOZXV.js +1 -0
  12. package/{chunk-SLS3DCJP.js → chunk-ADB5QRUO.js} +1 -1
  13. package/{chunk-C6RVYQ4M.js → chunk-AMSFSVKQ.js} +1 -1
  14. package/{chunk-IZCDGVXJ.js → chunk-APAWDC4O.js} +1 -1
  15. package/{chunk-I7HI454U.js → chunk-AZRNX5LU.js} +1 -1
  16. package/{chunk-OQ6BKP5N.js → chunk-BDQJFOCO.js} +1 -1
  17. package/{chunk-JTO22TJU.js → chunk-BLPTBPXV.js} +1 -1
  18. package/chunk-BME6TJIR.js +1 -0
  19. package/{chunk-NBTTYKXH.js → chunk-BRL4YYWO.js} +1 -1
  20. package/chunk-C5OIC3DB.js +1 -0
  21. package/chunk-CFJXIOSV.js +1 -0
  22. package/{chunk-ZY64T3CX.js → chunk-CQYKOCGO.js} +1 -1
  23. package/chunk-CW43F6WE.js +1 -0
  24. package/{chunk-WOZTK7S5.js → chunk-CYY7RVDE.js} +1 -1
  25. package/chunk-DFVPFPMV.js +11 -0
  26. package/{chunk-3KMV4PTJ.js → chunk-DTIGWCAE.js} +1 -1
  27. package/{chunk-LIDIFLHF.js → chunk-EGTYGTQI.js} +1 -1
  28. package/{chunk-X64LSE6Y.js → chunk-EQNDYV43.js} +1 -1
  29. package/chunk-EU6N52DH.js +1 -0
  30. package/{chunk-YIM56S4M.js → chunk-FMDSOHVR.js} +1 -1
  31. package/{chunk-VAQ435AR.js → chunk-FSHBOASN.js} +1 -1
  32. package/{chunk-VTFVTC7O.js → chunk-GE3DHZ5E.js} +1 -1
  33. package/chunk-GO22QPW4.js +1 -0
  34. package/{chunk-YQD4QIGG.js → chunk-HHDCI6IF.js} +1 -1
  35. package/chunk-I625OICV.js +1 -0
  36. package/chunk-IWDA6CMP.js +1 -0
  37. package/{chunk-Z772CHAB.js → chunk-J5TWEZOP.js} +1 -1
  38. package/chunk-J5VU6VA4.js +1 -0
  39. package/{chunk-BKQA64HZ.js → chunk-J6WVOYQ6.js} +1 -1
  40. package/chunk-JLSU6WKG.js +1 -0
  41. package/{chunk-KAZ3YMHR.js → chunk-JMLM4A3C.js} +1 -1
  42. package/{chunk-3ZCJK7PY.js → chunk-KHFOQETZ.js} +1 -1
  43. package/{chunk-BMWZYMK6.js → chunk-KHZ5AXGT.js} +1 -1
  44. package/chunk-KMGGFCBZ.js +1 -0
  45. package/chunk-L2QOWZDR.js +1 -0
  46. package/chunk-LOFKRPRH.js +1 -0
  47. package/{chunk-SA6PEMWL.js → chunk-LQKECNBH.js} +1 -1
  48. package/{chunk-HUJGWHH6.js → chunk-LU7TIW3P.js} +1 -1
  49. package/chunk-M5RTYP7N.js +2 -0
  50. package/{chunk-I4XRVBRQ.js → chunk-MRSBKQQM.js} +1 -1
  51. package/{chunk-MNK3XRJD.js → chunk-NBKLLQQO.js} +1 -1
  52. package/chunk-NCXKMSRH.js +1 -0
  53. package/{chunk-NXF5BMPG.js → chunk-OBF6ZSYT.js} +1 -1
  54. package/chunk-OO32MPRQ.js +1 -0
  55. package/{chunk-36J3WTHV.js → chunk-OZEGNE5W.js} +1 -1
  56. package/chunk-PBYZZEYM.js +1 -0
  57. package/{chunk-2LSZ2I43.js → chunk-QAQMMCTH.js} +1 -1
  58. package/{chunk-GROPRXXJ.js → chunk-QQLV7J6T.js} +1 -1
  59. package/{chunk-DGPSGSEP.js → chunk-QRLREAIK.js} +1 -1
  60. package/chunk-QUXPHHDZ.js +1 -0
  61. package/chunk-R5OX4JTJ.js +1 -0
  62. package/{chunk-BEXYTIOL.js → chunk-R6TFME5I.js} +1 -1
  63. package/{chunk-KQZRDX7C.js → chunk-S3FBC24H.js} +1 -1
  64. package/chunk-SGLY2D7Y.js +1 -0
  65. package/chunk-T2X5J6MQ.js +1 -0
  66. package/chunk-TGZAL6DJ.js +1 -0
  67. package/chunk-TJNL6F5S.js +1 -0
  68. package/{chunk-PSRISEFO.js → chunk-TPHRU6NP.js} +1 -1
  69. package/{chunk-NBPZDFGF.js → chunk-TZEOQBIX.js} +2 -2
  70. package/{chunk-GCFBX62M.js → chunk-U34FLIYL.js} +1 -1
  71. package/chunk-UE37PPYX.js +1 -0
  72. package/chunk-UH2E7MMT.js +4 -0
  73. package/chunk-V7UJAXBT.js +2 -0
  74. package/chunk-VCIINZCU.js +1 -0
  75. package/{chunk-3DFXRSFL.js → chunk-VDHWNNO7.js} +1 -1
  76. package/{chunk-3A4HTZ7B.js → chunk-VGBTP4QP.js} +1 -1
  77. package/{chunk-YIKPWYEP.js → chunk-VI7MBIGT.js} +1 -1
  78. package/{chunk-64W3VKAP.js → chunk-WALKMFYR.js} +1 -1
  79. package/{chunk-7HXPIZN6.js → chunk-WIE7KXIC.js} +1 -1
  80. package/{chunk-CCUGG5E4.js → chunk-XAYG4QT7.js} +1 -1
  81. package/{chunk-WBTDGQME.js → chunk-XCVBN7EK.js} +1 -1
  82. package/chunk-XZNYCTQB.js +1 -0
  83. package/chunk-Y3BYCXUX.js +1 -0
  84. package/{chunk-LJBFPDG2.js → chunk-YGHS3INE.js} +1 -1
  85. package/chunk-YHVGLFWL.js +1 -0
  86. package/{chunk-UY2WEUKC.js → chunk-YMUS7QSB.js} +1 -1
  87. package/chunk-YPWKWP5H.js +1 -0
  88. package/chunk-Z7CZCI7E.js +1 -0
  89. package/chunk-ZJOUYWI2.js +1 -0
  90. package/{chunk-COT66FJB.js → chunk-ZK3S23CJ.js} +1 -1
  91. package/{chunk-AYOFR344.js → chunk-ZXQSQRKN.js} +1 -1
  92. package/index.html +2 -2
  93. package/{main-4RMOPKNF.js → main-ZP6YWLCN.js} +1 -1
  94. package/package.json +1 -1
  95. package/ship-ui-assets/mcp/components.json +118 -47
  96. package/styles-43GHZ572.css +1 -0
  97. package/chunk-2DOT6WAE.js +0 -1
  98. package/chunk-2TGB7FK7.js +0 -1
  99. package/chunk-5MOLXRIQ.js +0 -1
  100. package/chunk-5N2VOOTZ.js +0 -11
  101. package/chunk-7FYL7MVA.js +0 -1
  102. package/chunk-A7BE7GAK.js +0 -1
  103. package/chunk-ANLSBAWJ.js +0 -1
  104. package/chunk-AXBVBB2B.js +0 -1
  105. package/chunk-BKEVAAWN.js +0 -1
  106. package/chunk-CJ5SZZQC.js +0 -1
  107. package/chunk-CVTB53TL.js +0 -1
  108. package/chunk-EGJL4XXZ.js +0 -1
  109. package/chunk-ERITO7WM.js +0 -4
  110. package/chunk-FCVVFGU2.js +0 -1
  111. package/chunk-FXZ3K2FU.js +0 -1
  112. package/chunk-G6ZV6LAU.js +0 -1
  113. package/chunk-GSDHTV3P.js +0 -1
  114. package/chunk-HDJL2F2F.js +0 -1
  115. package/chunk-IHB6NRMQ.js +0 -1
  116. package/chunk-IV3M3Q6B.js +0 -1
  117. package/chunk-KEHA3UWS.js +0 -1
  118. package/chunk-MI32HHLT.js +0 -1
  119. package/chunk-N35VE3MO.js +0 -1
  120. package/chunk-NDLPNBGE.js +0 -1
  121. package/chunk-NQIZGFSO.js +0 -1
  122. package/chunk-PAPOSE5G.js +0 -1
  123. package/chunk-Q72Y55NB.js +0 -1
  124. package/chunk-SP3KG7FO.js +0 -1
  125. package/chunk-SSUCTZ3H.js +0 -1
  126. package/chunk-UCR4I5MD.js +0 -1
  127. package/chunk-W4HWOC3K.js +0 -1
  128. package/chunk-WQVQC2MC.js +0 -2
  129. package/chunk-WSFAOFM3.js +0 -1
  130. package/chunk-XE42CXGY.js +0 -1
  131. package/chunk-XRSDTFDU.js +0 -2
  132. package/chunk-YCLTQEU6.js +0 -1
  133. package/chunk-ZVWTSTR6.js +0 -1
  134. package/styles-6WG7TD6T.css +0 -1
@@ -0,0 +1 @@
1
+ import{a as F}from"./chunk-XCVBN7EK.js";import{a as _}from"./chunk-MRSBKQQM.js";import{a as C}from"./chunk-35APLYI4.js";import{b as B}from"./chunk-XZNYCTQB.js";import{a as R}from"./chunk-R6TFME5I.js";import{z}from"./chunk-NCXKMSRH.js";import{d as $}from"./chunk-QAQMMCTH.js";import{F as f,L as S,Rc as c,V as P,_ as a,l as h,pa as g,q as k,ra as d}from"./chunk-UH2E7MMT.js";import{a as n,b as r}from"./chunk-7CGTOI24.js";var m={Starting_Operation:$localize`Starting operation …`,Backup_Begin:$localize`Starting backup …`,Backup_PreBackupVerify:$localize`Verifying backend data …`,Backup_PostBackupTest:$localize`Verifying remote data …`,Backup_PreviousBackupFinalize:$localize`Completing previous backup …`,Backup_ProcessingFiles:$localize`Processing files to backup …`,Backup_Finalize:$localize`Completing backup …`,Backup_WaitForUpload:$localize`Waiting for upload to finish …`,Backup_Delete:$localize`Deleting unwanted files …`,Backup_Compact:$localize`Compacting remote data …`,Backup_VerificationUpload:$localize`Uploading verification file …`,Backup_PostBackupVerify:$localize`Verifying backend data …`,Backup_Lock:$localize`Locking remote data …`,Backup_Complete:$localize`Backup complete!`,Backup_RemoteSynchronization:$localize`Synchronizing secondary destination(s) …`,Restore_Begin:$localize`Starting restore …`,Restore_RecreateDatabase:$localize`Rebuilding local database …`,Restore_PreRestoreVerify:$localize`Verifying remote data …`,Restore_CreateFileList:$localize`Building list of files to restore …`,Restore_CreateTargetFolders:$localize`Creating target folders …`,Restore_ScanForExistingFiles:$localize`Scanning existing files …`,Restore_ScanForLocalBlocks:$localize`Scanning for local blocks …`,Restore_PatchWithLocalBlocks:$localize`Patching files with local blocks …`,Restore_Download:$localize`Downloading files …`,Restore_PatchWithRemoteFiles:$localize`Patching files with remote data …`,Restore_VerifyRestoredFiles:$localize`Verifying restored files …`,Restore_Finaluze:$localize`Finalizing restore …`,Restore_Complete:$localize`Restore complete!`,Recreate_Begin:$localize`Starting database recreate …`,Recreate_Delete:$localize`Deleting old database …`,Recreate_Create:$localize`Creating new database …`,Recreate_Download:$localize`Downloading files …`,Recreate_Process:$localize`Processing files …`,Recreate_Complete:$localize`Database recreate complete!`,Verify_Begin:$localize`Starting verification …`,Verify_Download:$localize`Downloading files …`,Verify_Process:$localize`Processing files …`,Verify_Complete:$localize`Verification complete!`,BugReport_Begin:$localize`Starting bug report …`,BugReport_Gathering:$localize`Gathering information …`,BugReport_Complete:$localize`Bug report complete!`,List_Begin:$localize`Starting list …`,List_Download:$localize`Downloading files …`,List_Process:$localize`Processing files …`,List_Complete:$localize`List complete!`,Delete_Begin:$localize`Starting delete …`,Delete_Download:$localize`Downloading files …`,Delete_Process:$localize`Processing files …`,Delete_Complete:$localize`Delete complete!`,Compact_Begin:$localize`Starting compact …`,Compact_Download:$localize`Downloading files …`,Compact_Process:$localize`Processing files …`,Compact_Complete:$localize`Compact complete!`,Restore_DownloadingRemoteFiles:$localize`Downloading files …`,Restore_PostRestoreVerify:$localize`Verifying restored files …`,Recreate_Running:$localize`Recreating database …`,Vacuum_Running:$localize`Vacuuming database …`,Repair_Running:$localize`Repairing database …`,Verify_Running:$localize`Verifying files …`,BugReport_Running:$localize`Creating bug report …`,Delete_Listing:$localize`Listing remote files …`,Delete_Deleting:$localize`Deleting remote files …`,PurgeFiles_Begin:$localize`Listing remote files for purge …`,PurgeFiles_Process:$localize`Purging files …`,PurgeFiles_Compact:$localize`Compacting remote data …`,PurgeFiles_Complete:$localize`Purging files complete!`,ReadLockInfo_Running:$localize`Reading lock info …`,Error:$localize`Error!`};var b=class p{#i=a(_);#t=a($);#o=a(F);#e=a(B);#c=a(z);#g=a(R);#l=g(!1);#s=g(null);statusData=this.#s.asReadonly();lastState=null;serverState=c(()=>{let e=this.#e.serverState();return e?(e.ProposedSchedule=e.ProposedSchedule?.map(i=>r(n({},i),{backup:i.Item1?this.#o.getBackupById(i.Item1):null}))??null,this.lastState=e,e):this.lastState});hasProgressOnWebsocket=c(()=>this.#g.hasProgressSubscribeOption()&&this.#e.getConnectionMethod()==="websocket");clientIsRunning=c(()=>this.serverState()?.ProgramState==="Running");runningBackupId=c(()=>{let e=this.statusData();return!!(this.serverState()?.ActiveTask&&e?.task?.Status&&e?.task?.Status!=="Completed")?e?.BackupID??null:null});isResuming=g(!1);isFetching=this.#l.asReadonly();connectionStatus=this.#e.connectionStatus;pollingInterval;#m=d(()=>{let e=this.#e.serverState();e?.ActiveTask||this.#o.getBackups(!0),this.hasProgressOnWebsocket()&&(this.#e.subscribe("progress"),this.#e.subscribe("taskqueue")),e?.ActiveTask&&this.pollingInterval===void 0?this.startPollingProgress():e?.ActiveTask||this.stopPollingProgress()});#h=d(()=>{let e=this.#e.progressState(),i=this.#e.taskQueueState();if(e){let t=i?.find(o=>o.ID===e.TaskID)??null;this.#r(r(n({},e),{task:t}))}});setConnectionMethod(e){this.#e.setConnectionMethod(e)}startPollingProgress(){this.hasProgressOnWebsocket()?this.#e.subscribe("progress"):this.pollingInterval=setInterval(()=>{this.#n()},1e3)}stopPollingProgress(){clearInterval(this.pollingInterval)}fetchProgressState(){this.#n()}pauseResume(){return this.isResuming.set(!0),this.#t.postApiV1ServerstateResume().pipe(f(()=>this.isResuming.set(!1)))}resumeDialogCheck(e){if(!this.clientIsRunning()){this.#c.open(C,{data:{title:$localize`Server paused`,message:$localize`Server is currently paused. Do you want to resume now?`,confirmText:$localize`Resume`,cancelText:$localize`No, I'll resume later`},closed:i=>{i&&this.pauseResume().subscribe({next:()=>{e()}})}});return}e()}#n(){this.#l.set(!0),this.#t.getApiV1Progressstate().pipe(S(e=>{let i=e.TaskID??null;return i===null?h(e):this.#t.getApiV1TaskByTaskid({taskid:i}).pipe(k(t=>r(n({},e),{task:t??null})))}),f(()=>this.#l.set(!1))).subscribe({next:e=>{this.#r(e),this.serverState()?.ActiveTask==null&&this.stopPollingProgress()},error:e=>{e.status===404&&this.stopPollingProgress()}})}#r(e){let i=e.TaskID??null,t=e.BackupID??null;i!==null&&t!==null&&(e.backup=this.#o.getBackupById(t)),this.#s.set(r(n({},e),{progress:this.#p(e),statusText:this.#d(e),fileStatusText:this.#u(e),fileCountProgressText:this.#f(e),actionText:e.backup?.Backup?.Name??$localize`Running task`}))}#p(e){let i=-1;if(e.task&&e)if(e.Phase==="Backup_ProcessingFiles"||e.Phase==="Restore_DownloadingRemoteFiles")if(e.StillCounting)i=0;else{let t=e.CurrentFilecomplete?0:e.CurrentFileoffset,o=e.TotalFileCount-e.ProcessedFileCount,l=e.TotalFileSize-e.ProcessedFileSize-t;i=(e.ProcessedFileSize+t)/e.TotalFileSize,e.ProcessedFileCount===0?i=0:i>=.9&&(i=.9)}else e.Phase==="Backup_Finalize"||e.Phase==="Backup_WaitForUpload"?i=.9:e.Phase==="Backup_Delete"||e.Phase==="Backup_Compact"?i=.95:e.Phase==="Backup_VerificationUpload"||e.Phase==="Backup_PostBackupVerify"?i=.98:e.Phase==="Backup_Complete"?i=1:e.Phase==="Backup_RemoteSynchronization"?i=e.OverallProgress>0?e.OverallProgress:0:e.OverallProgress>0&&(i=e.OverallProgress);return i}#a(e){let i=(e.ActiveTransfers??[]).map(o=>o.BackendSpeed).reduce((o,l)=>(o??0)+(l??0),0)??-1,t=i<=0?e.BackendSpeed:i;return(t??-1)<0?"":` at ${this.#i.transform(t)}/s`}#u(e){let i=(["Backup_WaitForUpload","Backup_ProcessingFiles"].includes(e.Phase)?e?.BackendFileProgress:e.CurrentFileoffset)??0,t=(["Backup_WaitForUpload","Backup_ProcessingFiles"].includes(e.Phase)?e?.BackendFileSize:e.CurrentFilesize)??0;if(!e.CurrentFilename)return"";let o=e.CurrentFilename.length>42?"..."+e.CurrentFilename.slice(-42):e.CurrentFilename,l=(i/t*100).toFixed(1);return $localize`${o} | File processed: ${this.#i.transform(i)}/${this.#i.transform(t)} - ${l}%`}#f(e){return $localize`Files processed ${e.ProcessedFileCount}/${e.TotalFileCount}`}#d(e){let i="Running \u2026";if(e.task&&e){if(i=e.Phase?m[e.Phase]??e.Phase:"Running \u2026",e.TotalFileCount===0)return i;if(e.Phase==="Backup_ProcessingFiles"||e.Phase==="Restore_DownloadingRemoteFiles")if(e.StillCounting)i=`Counting (${e.TotalFileCount} files found, ${this.#i.transform(e.TotalFileSize)})`;else{let t=e.CurrentFilecomplete?0:e.CurrentFileoffset,o=e.TotalFileCount-e.ProcessedFileCount,l=e.TotalFileSize-e.ProcessedFileSize-t,u=e.Phase==="Restore_DownloadingRemoteFiles"?"Restoring: ":"",s=this.#a(e);e.Phase==="Backup_ProcessingFiles"&&o===0?i=`Completing upload ${s}`:e.BackendIsBlocking??!1?i=`Waiting for transfers ${s}`:i=`${u}${o} files (${this.#i.transform(l)}) to go ${s}`}else if(e.Phase==="Backup_WaitForUpload"){let t=this.#a(e);t!==""&&(i=`Waiting for upload to finish ${t}`)}else if(e.Phase==="Backup_RemoteSynchronization"){let t=e.RemoteSyncDestinationCount??0,o=e.RemoteSyncDestinationIndex??0,l=t>1?` (${o}/${t})`:"";if(e.TotalFileCount>0){let u=e.TotalFileCount-e.ProcessedFileCount,s=e.TotalFileSize-e.ProcessedFileSize,D=this.#a(e);i=`Synchronizing secondary destination${l}: ${u} files (${this.#i.transform(s)}) to go ${D}`}else l&&(i=`${m[e.Phase]}`.replace("\u2026",`${l} \u2026`))}}return i}static \u0275fac=function(i){return new(i||p)};static \u0275prov=P({token:p,factory:p.\u0275fac,providedIn:"root"})};export{m as a,b};
@@ -0,0 +1 @@
1
+ import{c as a,d as b}from"./chunk-BLPTBPXV.js";import"./chunk-TZEOQBIX.js";import"./chunk-DFVPFPMV.js";import"./chunk-5L2OOKRZ.js";import"./chunk-OO32MPRQ.js";import"./chunk-OBF6ZSYT.js";import"./chunk-6Q6SSTBK.js";import"./chunk-MRSBKQQM.js";import"./chunk-7FDLOZXV.js";import"./chunk-EQNDYV43.js";import"./chunk-35APLYI4.js";import"./chunk-YMUS7QSB.js";import"./chunk-ZXQSQRKN.js";import"./chunk-XZNYCTQB.js";import"./chunk-R6TFME5I.js";import"./chunk-AZRNX5LU.js";import"./chunk-NCXKMSRH.js";import"./chunk-QAQMMCTH.js";import"./chunk-KHZ5AXGT.js";import"./chunk-L2QOWZDR.js";import"./chunk-BRL4YYWO.js";import"./chunk-BDQJFOCO.js";import"./chunk-FSHBOASN.js";import"./chunk-UH2E7MMT.js";import"./chunk-7CGTOI24.js";export{a as createEncryptionForm,b as default};
@@ -1 +1 @@
1
- import{b as u}from"./chunk-GSDHTV3P.js";import{d as m}from"./chunk-2LSZ2I43.js";import{C as o,E as p,M as h,U as N,Z as r,l as c,oa as s,qa as l,v as f,z as d}from"./chunk-ERITO7WM.js";var b=class a{#e=r(m);#o=r(u);serverState=this.#o.serverState;serverStateEffect=l(()=>{let t=this.#o.serverState();t?.LastNotificationUpdateID&&this.updateLastNotificationEventId(t?.LastNotificationUpdateID)});#s=-1;#a=s(!1);#t=s([]);#i=s([]);notifications=this.#t.asReadonly();init(){this.notifications().length===0&&this.getNotifications()}updateLastNotificationEventId(t){this.#s!==t&&(this.#s=t,this.getNotifications())}getNotifications(){this.#a.set(!0),this.#e.getApiV1Notifications().pipe(o(1),h(t=>this.#t.set(t)),p(()=>this.#a.set(!1))).subscribe()}getNofication(t){this.#e.getApiV1NotificationById({id:t}).pipe(o(1)).subscribe()}deleteNotification(t){let i=this.#t(),e=i[t];this.#i.set(i),i.splice(t,1),this.#t.set(i),this.#e.deleteApiV1NotificationById({id:e.ID}).pipe(o(1)).subscribe({error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}deleteAllNotifications(){let t=this.#t();this.#i.set(t),this.#t.set([]);let i=t.map(e=>this.#e.deleteApiV1NotificationById({id:e.ID}).pipe(d(()=>c(e))));f(i).pipe(o(1)).subscribe({next:e=>{let g=e.filter(n=>n!=null&&"ID"in n);this.#t.set(g),this.#i.set([])},error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}static \u0275fac=function(i){return new(i||a)};static \u0275prov=N({token:a,factory:a.\u0275fac,providedIn:"root"})};export{b as a};
1
+ import{b as u}from"./chunk-I625OICV.js";import{d as m}from"./chunk-QAQMMCTH.js";import{A as d,D as o,F as p,N as h,V as N,_ as r,l as c,pa as s,ra as l,w as f}from"./chunk-UH2E7MMT.js";var b=class a{#e=r(m);#o=r(u);serverState=this.#o.serverState;serverStateEffect=l(()=>{let t=this.#o.serverState();t?.LastNotificationUpdateID&&this.updateLastNotificationEventId(t?.LastNotificationUpdateID)});#s=-1;#a=s(!1);#t=s([]);#i=s([]);notifications=this.#t.asReadonly();init(){this.notifications().length===0&&this.getNotifications()}updateLastNotificationEventId(t){this.#s!==t&&(this.#s=t,this.getNotifications())}getNotifications(){this.#a.set(!0),this.#e.getApiV1Notifications().pipe(o(1),h(t=>this.#t.set(t)),p(()=>this.#a.set(!1))).subscribe()}getNofication(t){this.#e.getApiV1NotificationById({id:t}).pipe(o(1)).subscribe()}deleteNotification(t){let i=this.#t(),e=i[t];this.#i.set(i),i.splice(t,1),this.#t.set(i),this.#e.deleteApiV1NotificationById({id:e.ID}).pipe(o(1)).subscribe({error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}deleteAllNotifications(){let t=this.#t();this.#i.set(t),this.#t.set([]);let i=t.map(e=>this.#e.deleteApiV1NotificationById({id:e.ID}).pipe(d(()=>c(e))));f(i).pipe(o(1)).subscribe({next:e=>{let g=e.filter(n=>n!=null&&"ID"in n);this.#t.set(g),this.#i.set([])},error:()=>{this.#t.set(this.#i()),this.#i.set([])}})}static \u0275fac=function(i){return new(i||a)};static \u0275prov=N({token:a,factory:a.\u0275fac,providedIn:"root"})};export{b as a};
@@ -0,0 +1 @@
1
+ import"./chunk-7CGTOI24.js";var o=[{path:"",redirectTo:"general",pathMatch:"full"},{path:"general",loadComponent:()=>import("./chunk-C5OIC3DB.js")},{path:"destination",loadComponent:()=>import("./chunk-KMGGFCBZ.js")},{path:"source-data",loadComponent:()=>import("./chunk-ZJOUYWI2.js")},{path:"schedule",loadComponent:()=>import("./chunk-JLSU6WKG.js")},{path:"options",loadComponent:()=>import("./chunk-TPHRU6NP.js")}];export{o as default};
@@ -1,2 +1,2 @@
1
- import{d as P}from"./chunk-2LSZ2I43.js";import"./chunk-NBTTYKXH.js";import"./chunk-VAQ435AR.js";import{E as p,Eb as o,Fb as i,Pc as x,Ra as s,U as h,Z as r,Zb as L,eb as u,hc as E,lc as a,mc as M,oa as c,ub as f,vb as C,wb as _,yb as v,zb as b}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";var l=class e{#e=r(P);isLoaded=c(!1);crashLog=c(null);load(){this.isLoaded()||this.#e.getApiV1LogdataCrashlog().pipe(p(()=>this.isLoaded.set(!0))).subscribe({next:t=>{this.crashLog.set(t.Logdata??null)}})}static \u0275fac=function(n){return new(n||e)};static \u0275prov=h({token:e,factory:e.\u0275fac,providedIn:"root"})};function O(e,t){e&1&&(o(0,"div",0),a(1,"Loading ..."),i())}function S(e,t){e&1&&(o(0,"div",0),a(1,"No crash log found"),i())}function w(e,t){if(e&1&&(o(0,"li"),a(1),i()),e&2){let n=t.$implicit;s(),M(n)}}function D(e,t){if(e&1&&(o(0,"div",2)(1,"code")(2,"ol",3),v(3,w,2,1,"li",null,_),i()()()),e&2){let n=L();E("grid-column","1 / -1")("height","auto"),s(3),b(n.breakIntoLines(n.crashLog()))}}var g=class e{#e=r(l);logsLoading=x(()=>!this.#e.isLoaded());crashLog=this.#e.crashLog;ngOnInit(){this.#e.load()}breakIntoLines(t){return t?t.split(`
1
+ import{d as P}from"./chunk-QAQMMCTH.js";import"./chunk-BRL4YYWO.js";import"./chunk-FSHBOASN.js";import{$b as L,Ab as v,Bb as b,F as p,Gb as o,Hb as i,Rc as x,Sa as s,V as h,_ as r,gb as u,jc as E,nc as a,oc as M,pa as c,wb as f,xb as C,yb as _}from"./chunk-UH2E7MMT.js";import"./chunk-7CGTOI24.js";var l=class e{#e=r(P);isLoaded=c(!1);crashLog=c(null);load(){this.isLoaded()||this.#e.getApiV1LogdataCrashlog().pipe(p(()=>this.isLoaded.set(!0))).subscribe({next:t=>{this.crashLog.set(t.Logdata??null)}})}static \u0275fac=function(n){return new(n||e)};static \u0275prov=h({token:e,factory:e.\u0275fac,providedIn:"root"})};function O(e,t){e&1&&(o(0,"div",0),a(1,"Loading ..."),i())}function S(e,t){e&1&&(o(0,"div",0),a(1,"No crash log found"),i())}function w(e,t){if(e&1&&(o(0,"li"),a(1),i()),e&2){let n=t.$implicit;s(),M(n)}}function D(e,t){if(e&1&&(o(0,"div",2)(1,"code")(2,"ol",3),v(3,w,2,1,"li",null,_),i()()()),e&2){let n=L();E("grid-column","1 / -1")("height","auto"),s(3),b(n.breakIntoLines(n.crashLog()))}}var g=class e{#e=r(l);logsLoading=x(()=>!this.#e.isLoaded());crashLog=this.#e.crashLog;ngOnInit(){this.#e.load()}breakIntoLines(t){return t?t.split(`
2
2
  `):[]}static \u0275fac=function(n){return new(n||e)};static \u0275cmp=u({type:e,selectors:[["app-crashlogs"]],decls:5,vars:1,consts:[[1,"loading"],[2,"white-space","pre-wrap",3,"grid-column","height"],[2,"white-space","pre-wrap"],[1,"line-numbers-ol"]],template:function(n,d){if(n&1&&(o(0,"h3"),a(1,"Crash log"),i(),f(2,O,2,0,"div",0)(3,S,2,0,"div",0)(4,D,5,4,"div",1)),n&2){let m;s(2),C(d.logsLoading()?2:d.crashLog()==null||((m=d.crashLog())==null?null:m.length)===0?3:4)}},styles:["[_nghost-%COMP%]{display:block;padding:0 2.5rem}h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0 0 1.25rem}sh-table[_ngcontent-%COMP%]{--table-columns: auto auto 1fr auto}sh-table[_ngcontent-%COMP%] td.id[_ngcontent-%COMP%]{justify-content:center}sh-table[_ngcontent-%COMP%] td[_ngcontent-%COMP%]:has(code){padding:1rem .75rem;overflow:hidden}sh-table[_ngcontent-%COMP%] td[_ngcontent-%COMP%]:has(code) code[_ngcontent-%COMP%]{background:color-mix(in srgb,var(--base-8),#000 70%);color:#fff;padding:2.5rem 2.5rem 2.5rem 1.5rem;border-radius:var(--shape-3);overflow:auto;white-space:pre}"],changeDetection:0})};export{g as default};
@@ -0,0 +1 @@
1
+ import{g as a,h as b,i as c,j as d}from"./chunk-DFVPFPMV.js";import"./chunk-5L2OOKRZ.js";import"./chunk-OO32MPRQ.js";import"./chunk-OBF6ZSYT.js";import"./chunk-6Q6SSTBK.js";import"./chunk-7FDLOZXV.js";import"./chunk-EQNDYV43.js";import"./chunk-35APLYI4.js";import"./chunk-YMUS7QSB.js";import"./chunk-ZXQSQRKN.js";import"./chunk-XZNYCTQB.js";import"./chunk-R6TFME5I.js";import"./chunk-AZRNX5LU.js";import"./chunk-NCXKMSRH.js";import"./chunk-QAQMMCTH.js";import"./chunk-KHZ5AXGT.js";import"./chunk-L2QOWZDR.js";import"./chunk-BRL4YYWO.js";import"./chunk-BDQJFOCO.js";import"./chunk-FSHBOASN.js";import"./chunk-UH2E7MMT.js";import"./chunk-7CGTOI24.js";export{a as SCHEDULE_DEFAULT_OPTIONS,c as SCHEDULE_FIELD_DEFAULTS,d as default,b as scheduleOptionToSchedule};
@@ -1 +1 @@
1
- import{a as _e}from"./chunk-COT66FJB.js";import"./chunk-W4HWOC3K.js";import"./chunk-YIM56S4M.js";import"./chunk-MNK3XRJD.js";import"./chunk-GSDHTV3P.js";import{a as se}from"./chunk-WBTDGQME.js";import"./chunk-SLS3DCJP.js";import"./chunk-SUY5AQLW.js";import"./chunk-6Q6SSTBK.js";import"./chunk-I4XRVBRQ.js";import"./chunk-MI32HHLT.js";import"./chunk-X64LSE6Y.js";import{a as b}from"./chunk-RFB5A3B7.js";import"./chunk-HUJGWHH6.js";import"./chunk-UY2WEUKC.js";import{a as le,b as m}from"./chunk-AYOFR344.js";import"./chunk-HDJL2F2F.js";import"./chunk-BEXYTIOL.js";import"./chunk-I7HI454U.js";import{B as ae,H as ie,Y as ne,c as Q,e as Y,i as Z,s as x,v as ee,z as te}from"./chunk-YCLTQEU6.js";import{d as oe}from"./chunk-2LSZ2I43.js";import{b as q,e as j}from"./chunk-BMWZYMK6.js";import"./chunk-7FYL7MVA.js";import"./chunk-NBTTYKXH.js";import"./chunk-OQ6BKP5N.js";import"./chunk-VAQ435AR.js";import{Ab as d,B as G,Bb as n,C as g,Cb as i,D as L,Db as c,E as p,Pc as E,Ra as _,Rb as u,Sb as h,Tb as A,Ub as H,Vb as J,Xb as T,Z as F,eb as V,ic as C,kc as K,lc as D,oa as s,p as y,qa as P,qc as X,rc as z,sc as W,ub as w,vb as U}from"./chunk-ERITO7WM.js";import"./chunk-7CGTOI24.js";function re(r,t){r&1&&(n(0,"sh-icon",19),D(1,"spinner"),i())}function ce(r,t){r&1&&(n(0,"sh-icon",20),D(1,"check"),i())}function de(r,t){r&1&&(n(0,"sh-icon",21),D(1,"warning"),i()),r&2&&d("shTooltip","File not found")}function ue(r,t){let a=le(r).pipe(G(t),L());return m(a,{initialValue:r()})}var N=class r{#o=F(q);#s=F(se);#e=F(oe);#a=F(te);#t=s("");backupId=m(this.#o.params.pipe(y(t=>t.id)));activeBackup=E(()=>this.#s.backups().find(t=>t.Backup?.ID===this.backupId()));backupFilePath=s("");lastValidatedPath=s("");isValidatedPath=E(()=>this.lastValidatedPath()===this.backupFilePath());pathHasChanged=E(()=>this.backupFilePath()!==this.#t());isValidatingPath=s(!1);#i=ue(this.backupFilePath,500);#n=s(!1);isWaitingForValidation=E(()=>this.#i()!=this.backupFilePath()||this.isValidatingPath());backupFilePathEffect=P(()=>{let t=this.#i(),a=this.activeBackup(),e=this.#n();t!==""&&(this.isValidatingPath.set(!0),this.#e.postApiV1FilesystemValidate({requestBody:{path:t}}).pipe(g(1),p(()=>this.isValidatingPath.set(!1))).subscribe(()=>this.lastValidatedPath.set(t)))});isRestoring=s(!1);isRepairing=s(!1);isDeleting=s(!1);isSavingDbPath=s(!1);isSavingAndRepairing=s(!1);isMovingDb=s(!1);isCreatingBugReport=s(!1);createdReport=s(!1);activeBackupEffect=P(()=>{let t=this.activeBackup();if(!t)return;let a=t.Backup?.DBPath??"";this.backupFilePath.set(a),this.#t.set(a)});repairDatabase(){this.isRepairing.set(!0),this.#e.postApiV1BackupByIdRepair({id:this.backupId()}).pipe(g(1),p(()=>this.isRepairing.set(!1))).subscribe()}deleteDatabase(t=null){this.isValidatedPath()?this.#a.open(b,{data:{title:$localize`Confirm delete?`,message:$localize`Do you really want to delete the database for ${this.activeBackup()?.Backup?.Name}?`,confirmText:$localize`Delete database`,cancelText:$localize`Cancel`},closed:a=>{a&&this.doDeleteDatabase(t)}}):this.doDeleteDatabase(t)}doDeleteDatabase(t=null){this.isDeleting.set(!0),this.#e.postApiV1BackupByIdDeletedb({id:this.backupId()}).pipe(g(1),p(()=>this.isDeleting.set(!1))).subscribe(()=>{this.lastValidatedPath.set(""),t?.()})}restoreDatabase(){this.isValidatedPath()?this.deleteDatabase(()=>{this.doRepairDatabase()}):this.doRepairDatabase()}doRepairDatabase(){this.isRestoring.set(!0),this.#e.postApiV1BackupByIdRepair({id:this.backupId(),requestBody:{refresh_lock_info:!0}}).pipe(g(1),p(()=>this.isRestoring.set(!1))).subscribe()}resetDatabasePath(){this.backupFilePath.set(this.#t())}saveDatabasePath(t=null){this.isValidatedPath()?this.#a.open(b,{data:{title:$localize`Confirm reassign?`,message:$localize`The target database path already exists and may belong to another backup. Are you sure you want to assign this backup to an existing database?`,confirmText:$localize`Assign existing database`,cancelText:$localize`Cancel`},closed:a=>{a&&this.doSaveDatabasePath(t)}}):this.doSaveDatabasePath(t)}doSaveDatabasePath(t=null){this.isSavingDbPath.set(!0);let a=this.backupFilePath();this.#e.postApiV1BackupByIdUpdatedb({id:this.backupId(),requestBody:{path:a}}).pipe(p(()=>this.isSavingDbPath.set(!1))).subscribe(()=>{this.#t.set(a),t?.()})}saveAndRepairDatabasePath(){this.saveDatabasePath(()=>(this.isSavingAndRepairing.set(!0),this.#e.postApiV1BackupByIdRepair({id:this.backupId()}).pipe(g(1),p(()=>this.isSavingAndRepairing.set(!1))).subscribe()))}moveDatabasePath(){this.isMovingDb.set(!0);let t=this.backupFilePath();this.#e.postApiV1BackupByIdMovedb({id:this.backupId(),requestBody:{path:t}}).pipe(p(()=>this.isMovingDb.set(!1))).subscribe(()=>{this.#n.update(a=>!a),this.#t.set(t)})}createErrorReport(){this.isCreatingBugReport.set(!0),this.#e.postApiV1BackupByIdCreatereport({id:this.backupId()}).pipe(p(()=>this.isCreatingBugReport.set(!1))).subscribe({next:()=>{this.createdReport.set(!0),window.setTimeout(()=>this.createdReport.set(!1),3e3)}})}static \u0275fac=function(a){return new(a||r)};static \u0275cmp=V({type:r,selectors:[["app-database"]],decls:50,vars:21,consts:()=>{let t;t=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON: Back `;let a;a=$localize`Local database for ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let e;e=$localize` Each backup has a local database associated with it, which stores information about the remote backup on the local machine. This makes it faster to perform many operations, and reduces the amount of data that needs to be downloaded for each operation. `;let o;o=$localize`Maintenance`;let S;S=$localize` If the backup and the remote storage is out of sync, Duplicati will require that you perform a repair operation to synchronize the database. If the repair is unsuccessful, you can delete the local database and re-generate. The bug report button can be used to create a copy of the database with path information removed. This should only be used if a developer requests to investigate an issue with your database. `;let f;f=$localize`${"\uFFFD#19\uFFFD"}:START_TAG_SH_ICON:wrench${"\uFFFD/#19\uFFFD"}:CLOSE_TAG_SH_ICON: Repair `;let I;I=$localize`${"\uFFFD#22\uFFFD"}:START_TAG_SH_ICON:trash${"\uFFFD/#22\uFFFD"}:CLOSE_TAG_SH_ICON: Delete `;let M;M=$localize`${"\uFFFD#25\uFFFD"}:START_TAG_SH_ICON:clock-counter-clockwise${"\uFFFD/#25\uFFFD"}:CLOSE_TAG_SH_ICON: Recreate (delete and repair) `;let R;R=$localize`${"\uFFFD#28\uFFFD"}:START_TAG_SH_ICON:file-plus${"\uFFFD/#28\uFFFD"}:CLOSE_TAG_SH_ICON: Create bug report database `;let B;B=$localize`Placement`;let O;O=$localize`${"\uFFFD#40\uFFFD"}:START_TAG_SH_ICON:backspace${"\uFFFD/#40\uFFFD"}:CLOSE_TAG_SH_ICON: Reset `;let $;$=$localize`${"\uFFFD#43\uFFFD"}:START_TAG_SH_ICON:floppy-disk${"\uFFFD/#43\uFFFD"}:CLOSE_TAG_SH_ICON: Save `;let v;v=$localize`${"\uFFFD#46\uFFFD"}:START_TAG_SH_ICON:wrench${"\uFFFD/#46\uFFFD"}:CLOSE_TAG_SH_ICON: Save & Repair `;let k;return k=$localize`${"\uFFFD#49\uFFFD"}:START_TAG_SH_ICON:flow-arrow${"\uFFFD/#49\uFFFD"}:CLOSE_TAG_SH_ICON: Move existing database `,[t,a,e,o,S,f,I,M,R,B,O,$,v,k,[1,"back"],["type","button","shButton","","routerLink","/",1,"small"],[1,"actions","maintenance"],["shButton","",3,"click","disabled"],["type","text",3,"ngModelChange","ngModel"],["prefix","",1,"primary"],["prefix",""],["prefix","",3,"shTooltip"],[1,"actions","placement"]]},template:function(a,e){if(a&1&&(c(0,"app-status-bar"),n(1,"section")(2,"div",14)(3,"button",15),u(4,0),c(5,"sh-icon"),h(),i()(),n(6,"article")(7,"h1"),A(8,1),i(),n(9,"p"),A(10,2),i()(),n(11,"article")(12,"h2"),A(13,3),i(),n(14,"p"),A(15,4),i(),n(16,"div",16)(17,"button",17),T("click",function(){return e.repairDatabase()}),u(18,5),c(19,"sh-icon"),h(),i(),n(20,"button",17),T("click",function(){return e.deleteDatabase()}),u(21,6),c(22,"sh-icon"),h(),i(),n(23,"button",17),T("click",function(){return e.restoreDatabase()}),u(24,7),c(25,"sh-icon"),h(),i(),n(26,"button",17),T("click",function(){return e.createErrorReport()}),u(27,8),c(28,"sh-icon"),h(),i()()(),n(29,"article")(30,"h2"),A(31,9),i(),n(32,"sh-form-field")(33,"input",18),W("ngModelChange",function(S){return z(e.backupFilePath,S)||(e.backupFilePath=S),S}),i(),w(34,re,2,0,"sh-icon",19)(35,ce,2,0,"sh-icon",20)(36,de,2,1,"sh-icon",21),i(),n(37,"div",22)(38,"button",17),T("click",function(){return e.resetDatabasePath()}),u(39,10),c(40,"sh-icon"),h(),i(),n(41,"button",17),T("click",function(){return e.saveDatabasePath()}),u(42,11),c(43,"sh-icon"),h(),i(),n(44,"button",17),T("click",function(){return e.saveAndRepairDatabasePath()}),u(45,12),c(46,"sh-icon"),h(),i(),n(47,"button",17),T("click",function(){return e.moveDatabasePath()}),u(48,13),c(49,"sh-icon"),h(),i()()()()),a&2){let o;_(8),H((o=e.activeBackup())==null||o.Backup==null?null:o.Backup.Name),J(8),_(9),C("loading",e.isRepairing()),d("disabled",!e.isValidatedPath()||e.pathHasChanged()),_(3),C("loading",e.isDeleting()),d("disabled",!e.isValidatedPath()||e.pathHasChanged()),_(3),C("loading",e.isRestoring()),d("disabled",e.pathHasChanged()),_(3),C("loading",e.isCreatingBugReport()),d("disabled",e.isCreatingBugReport()||!e.isValidatedPath()||e.pathHasChanged()),_(6),K(e.isValidatedPath()?"success":"error"),_(),X("ngModel",e.backupFilePath),_(),U(e.isWaitingForValidation()?34:e.isValidatedPath()?35:36),_(4),d("disabled",!e.pathHasChanged()),_(3),d("disabled",!e.pathHasChanged()||e.isWaitingForValidation()),_(3),d("disabled",!e.pathHasChanged()||e.isWaitingForValidation()),_(3),d("disabled",!e.pathHasChanged()||e.isValidatedPath()||e.isWaitingForValidation())}},dependencies:[x,Q,Y,Z,_e,ae,ie,ee,ne,j],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2rem;padding:2rem}article[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}h1[_ngcontent-%COMP%]{font:var(--title-20)}h2[_ngcontent-%COMP%]{font:var(--title-30)}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}"],changeDetection:0})};export{N as default};
1
+ import{a as _e}from"./chunk-ZK3S23CJ.js";import"./chunk-GO22QPW4.js";import"./chunk-FMDSOHVR.js";import"./chunk-NBKLLQQO.js";import"./chunk-I625OICV.js";import{a as se}from"./chunk-XCVBN7EK.js";import"./chunk-ADB5QRUO.js";import"./chunk-22PELS6R.js";import"./chunk-6Q6SSTBK.js";import"./chunk-MRSBKQQM.js";import"./chunk-7FDLOZXV.js";import"./chunk-EQNDYV43.js";import{a as b}from"./chunk-35APLYI4.js";import"./chunk-LU7TIW3P.js";import"./chunk-YMUS7QSB.js";import{a as le,b as m}from"./chunk-ZXQSQRKN.js";import"./chunk-XZNYCTQB.js";import"./chunk-R6TFME5I.js";import"./chunk-AZRNX5LU.js";import{B as ae,H as ie,Y as ne,c as Q,e as Y,i as Z,s as x,v as ee,z as te}from"./chunk-NCXKMSRH.js";import{d as oe}from"./chunk-QAQMMCTH.js";import{b as q,e as j}from"./chunk-KHZ5AXGT.js";import"./chunk-L2QOWZDR.js";import"./chunk-BRL4YYWO.js";import"./chunk-BDQJFOCO.js";import"./chunk-FSHBOASN.js";import{C as G,Cb as d,D as g,Db as n,E as L,Eb as i,F as p,Fb as c,Rc as E,Sa as _,Tb as u,Ub as h,Vb as A,Wb as H,Xb as J,Zb as T,_ as F,gb as V,kc as C,mc as K,nc as D,pa as s,q as y,ra as P,sc as X,tc as z,uc as W,wb as w,xb as U}from"./chunk-UH2E7MMT.js";import"./chunk-7CGTOI24.js";function re(r,t){r&1&&(n(0,"sh-icon",19),D(1,"spinner"),i())}function ce(r,t){r&1&&(n(0,"sh-icon",20),D(1,"check"),i())}function de(r,t){r&1&&(n(0,"sh-icon",21),D(1,"warning"),i()),r&2&&d("shTooltip","File not found")}function ue(r,t){let a=le(r).pipe(G(t),L());return m(a,{initialValue:r()})}var N=class r{#o=F(q);#s=F(se);#e=F(oe);#a=F(te);#t=s("");backupId=m(this.#o.params.pipe(y(t=>t.id)));activeBackup=E(()=>this.#s.backups().find(t=>t.Backup?.ID===this.backupId()));backupFilePath=s("");lastValidatedPath=s("");isValidatedPath=E(()=>this.lastValidatedPath()===this.backupFilePath());pathHasChanged=E(()=>this.backupFilePath()!==this.#t());isValidatingPath=s(!1);#i=ue(this.backupFilePath,500);#n=s(!1);isWaitingForValidation=E(()=>this.#i()!=this.backupFilePath()||this.isValidatingPath());backupFilePathEffect=P(()=>{let t=this.#i(),a=this.activeBackup(),e=this.#n();t!==""&&(this.isValidatingPath.set(!0),this.#e.postApiV1FilesystemValidate({requestBody:{path:t}}).pipe(g(1),p(()=>this.isValidatingPath.set(!1))).subscribe(()=>this.lastValidatedPath.set(t)))});isRestoring=s(!1);isRepairing=s(!1);isDeleting=s(!1);isSavingDbPath=s(!1);isSavingAndRepairing=s(!1);isMovingDb=s(!1);isCreatingBugReport=s(!1);createdReport=s(!1);activeBackupEffect=P(()=>{let t=this.activeBackup();if(!t)return;let a=t.Backup?.DBPath??"";this.backupFilePath.set(a),this.#t.set(a)});repairDatabase(){this.isRepairing.set(!0),this.#e.postApiV1BackupByIdRepair({id:this.backupId()}).pipe(g(1),p(()=>this.isRepairing.set(!1))).subscribe()}deleteDatabase(t=null){this.isValidatedPath()?this.#a.open(b,{data:{title:$localize`Confirm delete?`,message:$localize`Do you really want to delete the database for ${this.activeBackup()?.Backup?.Name}?`,confirmText:$localize`Delete database`,cancelText:$localize`Cancel`},closed:a=>{a&&this.doDeleteDatabase(t)}}):this.doDeleteDatabase(t)}doDeleteDatabase(t=null){this.isDeleting.set(!0),this.#e.postApiV1BackupByIdDeletedb({id:this.backupId()}).pipe(g(1),p(()=>this.isDeleting.set(!1))).subscribe(()=>{this.lastValidatedPath.set(""),t?.()})}restoreDatabase(){this.isValidatedPath()?this.deleteDatabase(()=>{this.doRepairDatabase()}):this.doRepairDatabase()}doRepairDatabase(){this.isRestoring.set(!0),this.#e.postApiV1BackupByIdRepair({id:this.backupId(),requestBody:{refresh_lock_info:!0}}).pipe(g(1),p(()=>this.isRestoring.set(!1))).subscribe()}resetDatabasePath(){this.backupFilePath.set(this.#t())}saveDatabasePath(t=null){this.isValidatedPath()?this.#a.open(b,{data:{title:$localize`Confirm reassign?`,message:$localize`The target database path already exists and may belong to another backup. Are you sure you want to assign this backup to an existing database?`,confirmText:$localize`Assign existing database`,cancelText:$localize`Cancel`},closed:a=>{a&&this.doSaveDatabasePath(t)}}):this.doSaveDatabasePath(t)}doSaveDatabasePath(t=null){this.isSavingDbPath.set(!0);let a=this.backupFilePath();this.#e.postApiV1BackupByIdUpdatedb({id:this.backupId(),requestBody:{path:a}}).pipe(p(()=>this.isSavingDbPath.set(!1))).subscribe(()=>{this.#t.set(a),t?.()})}saveAndRepairDatabasePath(){this.saveDatabasePath(()=>(this.isSavingAndRepairing.set(!0),this.#e.postApiV1BackupByIdRepair({id:this.backupId()}).pipe(g(1),p(()=>this.isSavingAndRepairing.set(!1))).subscribe()))}moveDatabasePath(){this.isMovingDb.set(!0);let t=this.backupFilePath();this.#e.postApiV1BackupByIdMovedb({id:this.backupId(),requestBody:{path:t}}).pipe(p(()=>this.isMovingDb.set(!1))).subscribe(()=>{this.#n.update(a=>!a),this.#t.set(t)})}createErrorReport(){this.isCreatingBugReport.set(!0),this.#e.postApiV1BackupByIdCreatereport({id:this.backupId()}).pipe(p(()=>this.isCreatingBugReport.set(!1))).subscribe({next:()=>{this.createdReport.set(!0),window.setTimeout(()=>this.createdReport.set(!1),3e3)}})}static \u0275fac=function(a){return new(a||r)};static \u0275cmp=V({type:r,selectors:[["app-database"]],decls:50,vars:21,consts:()=>{let t;t=$localize`${"\uFFFD#5\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#5\uFFFD"}:CLOSE_TAG_SH_ICON: Back `;let a;a=$localize`Local database for ${"\uFFFD0\uFFFD"}:INTERPOLATION:`;let e;e=$localize` Each backup has a local database associated with it, which stores information about the remote backup on the local machine. This makes it faster to perform many operations, and reduces the amount of data that needs to be downloaded for each operation. `;let o;o=$localize`Maintenance`;let S;S=$localize` If the backup and the remote storage is out of sync, Duplicati will require that you perform a repair operation to synchronize the database. If the repair is unsuccessful, you can delete the local database and re-generate. The bug report button can be used to create a copy of the database with path information removed. This should only be used if a developer requests to investigate an issue with your database. `;let f;f=$localize`${"\uFFFD#19\uFFFD"}:START_TAG_SH_ICON:wrench${"\uFFFD/#19\uFFFD"}:CLOSE_TAG_SH_ICON: Repair `;let I;I=$localize`${"\uFFFD#22\uFFFD"}:START_TAG_SH_ICON:trash${"\uFFFD/#22\uFFFD"}:CLOSE_TAG_SH_ICON: Delete `;let M;M=$localize`${"\uFFFD#25\uFFFD"}:START_TAG_SH_ICON:clock-counter-clockwise${"\uFFFD/#25\uFFFD"}:CLOSE_TAG_SH_ICON: Recreate (delete and repair) `;let R;R=$localize`${"\uFFFD#28\uFFFD"}:START_TAG_SH_ICON:file-plus${"\uFFFD/#28\uFFFD"}:CLOSE_TAG_SH_ICON: Create bug report database `;let B;B=$localize`Placement`;let O;O=$localize`${"\uFFFD#40\uFFFD"}:START_TAG_SH_ICON:backspace${"\uFFFD/#40\uFFFD"}:CLOSE_TAG_SH_ICON: Reset `;let $;$=$localize`${"\uFFFD#43\uFFFD"}:START_TAG_SH_ICON:floppy-disk${"\uFFFD/#43\uFFFD"}:CLOSE_TAG_SH_ICON: Save `;let v;v=$localize`${"\uFFFD#46\uFFFD"}:START_TAG_SH_ICON:wrench${"\uFFFD/#46\uFFFD"}:CLOSE_TAG_SH_ICON: Save & Repair `;let k;return k=$localize`${"\uFFFD#49\uFFFD"}:START_TAG_SH_ICON:flow-arrow${"\uFFFD/#49\uFFFD"}:CLOSE_TAG_SH_ICON: Move existing database `,[t,a,e,o,S,f,I,M,R,B,O,$,v,k,[1,"back"],["type","button","shButton","","routerLink","/",1,"small"],[1,"actions","maintenance"],["shButton","",3,"click","disabled"],["type","text",3,"ngModelChange","ngModel"],["prefix","",1,"primary"],["prefix",""],["prefix","",3,"shTooltip"],[1,"actions","placement"]]},template:function(a,e){if(a&1&&(c(0,"app-status-bar"),n(1,"section")(2,"div",14)(3,"button",15),u(4,0),c(5,"sh-icon"),h(),i()(),n(6,"article")(7,"h1"),A(8,1),i(),n(9,"p"),A(10,2),i()(),n(11,"article")(12,"h2"),A(13,3),i(),n(14,"p"),A(15,4),i(),n(16,"div",16)(17,"button",17),T("click",function(){return e.repairDatabase()}),u(18,5),c(19,"sh-icon"),h(),i(),n(20,"button",17),T("click",function(){return e.deleteDatabase()}),u(21,6),c(22,"sh-icon"),h(),i(),n(23,"button",17),T("click",function(){return e.restoreDatabase()}),u(24,7),c(25,"sh-icon"),h(),i(),n(26,"button",17),T("click",function(){return e.createErrorReport()}),u(27,8),c(28,"sh-icon"),h(),i()()(),n(29,"article")(30,"h2"),A(31,9),i(),n(32,"sh-form-field")(33,"input",18),W("ngModelChange",function(S){return z(e.backupFilePath,S)||(e.backupFilePath=S),S}),i(),w(34,re,2,0,"sh-icon",19)(35,ce,2,0,"sh-icon",20)(36,de,2,1,"sh-icon",21),i(),n(37,"div",22)(38,"button",17),T("click",function(){return e.resetDatabasePath()}),u(39,10),c(40,"sh-icon"),h(),i(),n(41,"button",17),T("click",function(){return e.saveDatabasePath()}),u(42,11),c(43,"sh-icon"),h(),i(),n(44,"button",17),T("click",function(){return e.saveAndRepairDatabasePath()}),u(45,12),c(46,"sh-icon"),h(),i(),n(47,"button",17),T("click",function(){return e.moveDatabasePath()}),u(48,13),c(49,"sh-icon"),h(),i()()()()),a&2){let o;_(8),H((o=e.activeBackup())==null||o.Backup==null?null:o.Backup.Name),J(8),_(9),C("loading",e.isRepairing()),d("disabled",!e.isValidatedPath()||e.pathHasChanged()),_(3),C("loading",e.isDeleting()),d("disabled",!e.isValidatedPath()||e.pathHasChanged()),_(3),C("loading",e.isRestoring()),d("disabled",e.pathHasChanged()),_(3),C("loading",e.isCreatingBugReport()),d("disabled",e.isCreatingBugReport()||!e.isValidatedPath()||e.pathHasChanged()),_(6),K(e.isValidatedPath()?"success":"error"),_(),X("ngModel",e.backupFilePath),_(),U(e.isWaitingForValidation()?34:e.isValidatedPath()?35:36),_(4),d("disabled",!e.pathHasChanged()),_(3),d("disabled",!e.pathHasChanged()||e.isWaitingForValidation()),_(3),d("disabled",!e.pathHasChanged()||e.isWaitingForValidation()),_(3),d("disabled",!e.pathHasChanged()||e.isValidatedPath()||e.isWaitingForValidation())}},dependencies:[x,Q,Y,Z,_e,ae,ie,ee,ne,j],styles:["[_nghost-%COMP%]{display:block}section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2rem;padding:2rem}article[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}h1[_ngcontent-%COMP%]{font:var(--title-20)}h2[_ngcontent-%COMP%]{font:var(--title-30)}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}"],changeDetection:0})};export{N as default};
@@ -1 +1 @@
1
- import{a as u}from"./chunk-SUY5AQLW.js";import{Z as p,hb as m}from"./chunk-ERITO7WM.js";var c=class s{#n=p(u);transform(r,t=!1,...d){if(!r)return"";let n=/^\s*(?:(\d+)\.)?(\d{1,2}):(\d{2}):(\d{2})(?:\.\d+)?\s*$/.exec(r);if(!n)return"";let e=parseInt(n[1]??"0",10),i=parseInt(n[2],10),o=parseInt(n[3],10),a=parseInt(n[4],10);return t?`${e?`${e}d `:""}${i}h ${o}m ${a}s`:this.#n.duration({days:e,hours:i,minutes:o,seconds:a}).humanize()}static \u0275fac=function(t){return new(t||s)};static \u0275pipe=m({name:"durationFormat",type:s,pure:!0})};export{c as a};
1
+ import{a as u}from"./chunk-22PELS6R.js";import{_ as p,jb as m}from"./chunk-UH2E7MMT.js";var c=class s{#n=p(u);transform(r,t=!1,...d){if(!r)return"";let n=/^\s*(?:(\d+)\.)?(\d{1,2}):(\d{2}):(\d{2})(?:\.\d+)?\s*$/.exec(r);if(!n)return"";let e=parseInt(n[1]??"0",10),i=parseInt(n[2],10),o=parseInt(n[3],10),a=parseInt(n[4],10);return t?`${e?`${e}d `:""}${i}h ${o}m ${a}s`:this.#n.duration({days:e,hours:i,minutes:o,seconds:a}).humanize()}static \u0275fac=function(t){return new(t||s)};static \u0275pipe=m({name:"durationFormat",type:s,pure:!0})};export{c as a};
@@ -1 +1 @@
1
- import{b as Qr}from"./chunk-7FYL7MVA.js";import{b as Wr,g as rt}from"./chunk-OQ6BKP5N.js";import{$a as Dr,A as Ee,C as ue,Db as jr,E as Cr,F as Q,G as Ut,J as Sr,Jc as qr,K as x,L as Ye,M as j,Oc as y,Pa as Tr,Pc as Xe,Qc as Hr,R as w,S as wr,Tc as Br,U as R,Vc as Vr,W as br,X as M,Xb as kr,Y as K,Z as h,Za as jt,_ as Ir,_a as $,_c as et,aa as H,ac as $r,ba as U,bb as Nr,bc as zr,cc as Fr,cd as tt,d as pr,db as Je,e as gr,eb as _r,f as vr,fd as Gr,g as re,ga as Ar,gb as Te,h as _,ia as Pt,j as O,ja as Er,k as b,ka as ne,l as g,lb as Or,m as mr,n as _t,na as Ze,nb as Ur,o as yr,oa as C,p as A,pb as Pr,q as Ot,qb as Lr,r as k,ra as Me,s as Ie,sa as Lt,t as Rr,ta as Mr,tb as xr,u as Ke,ua as xt,x as W,z as Ae}from"./chunk-ERITO7WM.js";import{a as l,b as N}from"./chunk-7CGTOI24.js";var f="primary",He=Symbol("RouteTitle"),qt=class{params;constructor(n){this.params=n||{}}has(n){return Object.prototype.hasOwnProperty.call(this.params,n)}get(n){if(this.has(n)){let e=this.params[n];return Array.isArray(e)?e[0]:e}return null}getAll(n){if(this.has(n)){let e=this.params[n];return Array.isArray(e)?e:[e]}return[]}get keys(){return Object.keys(this.params)}};function oe(t){return new qt(t)}function kt(t,n,e){for(let r=0;r<t.length;r++){let i=t[r],o=n[r];if(i[0]===":")e[i.substring(1)]=o;else if(i!==o.path)return!1}return!0}function tn(t,n,e){let r=e.path.split("/"),i=r.indexOf("**");if(i===-1){if(r.length>t.length||e.pathMatch==="full"&&(n.hasChildren()||r.length<t.length))return null;let c={},u=t.slice(0,r.length);return kt(r,u,c)?{consumed:u,posParams:c}:null}if(i!==r.lastIndexOf("**"))return null;let o=r.slice(0,i),s=r.slice(i+1);if(o.length+s.length>t.length||e.pathMatch==="full"&&n.hasChildren()&&e.path!=="**")return null;let a={};return!kt(o,t.slice(0,o.length),a)||!kt(s,t.slice(t.length-s.length),a)?null:{consumed:t,posParams:a}}function ct(t){return new Promise((n,e)=>{t.pipe(Q()).subscribe({next:r=>n(r),error:r=>e(r)})})}function Qn(t,n){if(t.length!==n.length)return!1;for(let e=0;e<t.length;++e)if(!z(t[e],n[e]))return!1;return!0}function z(t,n){let e=t?Ht(t):void 0,r=n?Ht(n):void 0;if(!e||!r||e.length!=r.length)return!1;let i;for(let o=0;o<e.length;o++)if(i=e[o],!rn(t[i],n[i]))return!1;return!0}function Ht(t){return[...Object.keys(t),...Object.getOwnPropertySymbols(t)]}function rn(t,n){if(Array.isArray(t)&&Array.isArray(n)){if(t.length!==n.length)return!1;let e=[...t].sort(),r=[...n].sort();return e.every((i,o)=>r[o]===i)}else return t===n}function Kn(t){return t.length>0?t[t.length-1]:null}function ce(t){return _t(t)?t:Ur(t)?b(Promise.resolve(t)):g(t)}function nn(t){return _t(t)?ct(t):Promise.resolve(t)}var Yn={exact:an,subset:sn},on={exact:Zn,subset:Jn,ignored:()=>!0},nr={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},Pe={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"};function ir(t,n,e){let r=t instanceof E?t:n.parseUrl(t);return Xe(()=>Bt(n.lastSuccessfulNavigation()?.finalUrl??new E,r,l(l({},Pe),e)))}function Bt(t,n,e){return Yn[e.paths](t.root,n.root,e.matrixParams)&&on[e.queryParams](t.queryParams,n.queryParams)&&!(e.fragment==="exact"&&t.fragment!==n.fragment)}function Zn(t,n){return z(t,n)}function an(t,n,e){if(!ie(t.segments,n.segments)||!ot(t.segments,n.segments,e)||t.numberOfChildren!==n.numberOfChildren)return!1;for(let r in n.children)if(!t.children[r]||!an(t.children[r],n.children[r],e))return!1;return!0}function Jn(t,n){return Object.keys(n).length<=Object.keys(t).length&&Object.keys(n).every(e=>rn(t[e],n[e]))}function sn(t,n,e){return cn(t,n,n.segments,e)}function cn(t,n,e,r){if(t.segments.length>e.length){let i=t.segments.slice(0,e.length);return!(!ie(i,e)||n.hasChildren()||!ot(i,e,r))}else if(t.segments.length===e.length){if(!ie(t.segments,e)||!ot(t.segments,e,r))return!1;for(let i in n.children)if(!t.children[i]||!sn(t.children[i],n.children[i],r))return!1;return!0}else{let i=e.slice(0,t.segments.length),o=e.slice(t.segments.length);return!ie(t.segments,i)||!ot(t.segments,i,r)||!t.children[f]?!1:cn(t.children[f],n,o,r)}}function ot(t,n,e){return n.every((r,i)=>on[e](t[i].parameters,r.parameters))}var E=class{root;queryParams;fragment;_queryParamMap;constructor(n=new v([],{}),e={},r=null){this.root=n,this.queryParams=e,this.fragment=r}get queryParamMap(){return this._queryParamMap??=oe(this.queryParams),this._queryParamMap}toString(){return ti.serialize(this)}},v=class{segments;children;parent=null;constructor(n,e){this.segments=n,this.children=e,Object.values(e).forEach(r=>r.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return at(this)}},Y=class{path;parameters;_parameterMap;constructor(n,e){this.path=n,this.parameters=e}get parameterMap(){return this._parameterMap??=oe(this.parameters),this._parameterMap}toString(){return ln(this)}};function Xn(t,n){return ie(t,n)&&t.every((e,r)=>z(e.parameters,n[r].parameters))}function ie(t,n){return t.length!==n.length?!1:t.every((e,r)=>e.path===n[r].path)}function ei(t,n){let e=[];return Object.entries(t.children).forEach(([r,i])=>{r===f&&(e=e.concat(n(i,r)))}),Object.entries(t.children).forEach(([r,i])=>{r!==f&&(e=e.concat(n(i,r)))}),e}var ye=(()=>{class t{static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:()=>new Z,providedIn:"root"})}return t})(),Z=class{parse(n){let e=new Gt(n);return new E(e.parseRootSegment(),e.parseQueryParams(),e.parseFragment())}serialize(n){let e=`/${De(n.root,!0)}`,r=ii(n.queryParams),i=typeof n.fragment=="string"?`#${ri(n.fragment)}`:"";return`${e}${r}${i}`}},ti=new Z;function at(t){return t.segments.map(n=>ln(n)).join("/")}function De(t,n){if(!t.hasChildren())return at(t);if(n){let e=t.children[f]?De(t.children[f],!1):"",r=[];return Object.entries(t.children).forEach(([i,o])=>{i!==f&&r.push(`${i}:${De(o,!1)}`)}),r.length>0?`${e}(${r.join("//")})`:e}else{let e=ei(t,(r,i)=>i===f?[De(t.children[f],!1)]:[`${i}:${De(r,!1)}`]);return Object.keys(t.children).length===1&&t.children[f]!=null?`${at(t)}/${e[0]}`:`${at(t)}/(${e.join("//")})`}}function un(t){return encodeURIComponent(t).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function nt(t){return un(t).replace(/%3B/gi,";")}function ri(t){return encodeURI(t)}function Vt(t){return un(t).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function st(t){return decodeURIComponent(t)}function Kr(t){return st(t.replace(/\+/g,"%20"))}function ln(t){return`${Vt(t.path)}${ni(t.parameters)}`}function ni(t){return Object.entries(t).map(([n,e])=>`;${Vt(n)}=${Vt(e)}`).join("")}function ii(t){let n=Object.entries(t).map(([e,r])=>Array.isArray(r)?r.map(i=>`${nt(e)}=${nt(i)}`).join("&"):`${nt(e)}=${nt(r)}`).filter(e=>e);return n.length?`?${n.join("&")}`:""}var oi=/^[^\/()?;#]+/;function $t(t){let n=t.match(oi);return n?n[0]:""}var ai=/^[^\/()?;=#]+/;function si(t){let n=t.match(ai);return n?n[0]:""}var ci=/^[^=?&#]+/;function ui(t){let n=t.match(ci);return n?n[0]:""}var li=/^[^&#]+/;function di(t){let n=t.match(li);return n?n[0]:""}var Gt=class{url;remaining;constructor(n){this.url=n,this.remaining=n}parseRootSegment(){return this.consumeOptional("/"),this.remaining===""||this.peekStartsWith("?")||this.peekStartsWith("#")?new v([],{}):new v([],this.parseChildren())}parseQueryParams(){let n={};if(this.consumeOptional("?"))do this.parseQueryParam(n);while(this.consumeOptional("&"));return n}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(n=0){if(n>50)throw new w(4010,!1);if(this.remaining==="")return{};this.consumeOptional("/");let e=[];for(this.peekStartsWith("(")||e.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),e.push(this.parseSegment());let r={};this.peekStartsWith("/(")&&(this.capture("/"),r=this.parseParens(!0,n));let i={};return this.peekStartsWith("(")&&(i=this.parseParens(!1,n)),(e.length>0||Object.keys(r).length>0)&&(i[f]=new v(e,r)),i}parseSegment(){let n=$t(this.remaining);if(n===""&&this.peekStartsWith(";"))throw new w(4009,!1);return this.capture(n),new Y(st(n),this.parseMatrixParams())}parseMatrixParams(){let n={};for(;this.consumeOptional(";");)this.parseParam(n);return n}parseParam(n){let e=si(this.remaining);if(!e)return;this.capture(e);let r="";if(this.consumeOptional("=")){let i=$t(this.remaining);i&&(r=i,this.capture(r))}n[st(e)]=st(r)}parseQueryParam(n){let e=ui(this.remaining);if(!e)return;this.capture(e);let r="";if(this.consumeOptional("=")){let s=di(this.remaining);s&&(r=s,this.capture(r))}let i=Kr(e),o=Kr(r);if(n.hasOwnProperty(i)){let s=n[i];Array.isArray(s)||(s=[s],n[i]=s),s.push(o)}else n[i]=o}parseParens(n,e){let r={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){let i=$t(this.remaining),o=this.remaining[i.length];if(o!=="/"&&o!==")"&&o!==";")throw new w(4010,!1);let s;i.indexOf(":")>-1?(s=i.slice(0,i.indexOf(":")),this.capture(s),this.capture(":")):n&&(s=f);let a=this.parseChildren(e+1);r[s??f]=Object.keys(a).length===1&&a[f]?a[f]:new v([],a),this.consumeOptional("//")}return r}peekStartsWith(n){return this.remaining.startsWith(n)}consumeOptional(n){return this.peekStartsWith(n)?(this.remaining=this.remaining.substring(n.length),!0):!1}capture(n){if(!this.consumeOptional(n))throw new w(4011,!1)}};function dn(t){return t.segments.length>0?new v([],{[f]:t}):t}function hn(t){let n={};for(let[r,i]of Object.entries(t.children)){let o=hn(i);if(r===f&&o.segments.length===0&&o.hasChildren())for(let[s,a]of Object.entries(o.children))n[s]=a;else(o.segments.length>0||o.hasChildren())&&(n[r]=o)}let e=new v(t.segments,n);return hi(e)}function hi(t){if(t.numberOfChildren===1&&t.children[f]){let n=t.children[f];return new v(t.segments.concat(n.segments),n.children)}return t}function J(t){return t instanceof E}function fn(t,n,e=null,r=null,i=new Z){let o=pn(t);return gn(o,n,e,r,i)}function pn(t){let n;function e(o){let s={};for(let c of o.children){let u=e(c);s[c.outlet]=u}let a=new v(o.url,s);return o===t&&(n=a),a}let r=e(t.root),i=dn(r);return n??i}function gn(t,n,e,r,i){let o=t;for(;o.parent;)o=o.parent;if(n.length===0)return zt(o,o,o,e,r,i);let s=fi(n);if(s.toRoot())return zt(o,o,new v([],{}),e,r,i);let a=pi(s,o,t),c=a.processChildren?_e(a.segmentGroup,a.index,s.commands):mn(a.segmentGroup,a.index,s.commands);return zt(o,a.segmentGroup,c,e,r,i)}function ut(t){return typeof t=="object"&&t!=null&&!t.outlets&&!t.segmentPath}function Le(t){return typeof t=="object"&&t!=null&&t.outlets}function Yr(t,n,e){t||="\u0275";let r=new E;return r.queryParams={[t]:n},e.parse(e.serialize(r)).queryParams[t]}function zt(t,n,e,r,i,o){let s={};for(let[u,d]of Object.entries(r??{}))s[u]=Array.isArray(d)?d.map(p=>Yr(u,p,o)):Yr(u,d,o);let a;t===n?a=e:a=vn(t,n,e);let c=dn(hn(a));return new E(c,s,i)}function vn(t,n,e){let r={};return Object.entries(t.children).forEach(([i,o])=>{o===n?r[i]=e:r[i]=vn(o,n,e)}),new v(t.segments,r)}var lt=class{isAbsolute;numberOfDoubleDots;commands;constructor(n,e,r){if(this.isAbsolute=n,this.numberOfDoubleDots=e,this.commands=r,n&&r.length>0&&ut(r[0]))throw new w(4003,!1);let i=r.find(Le);if(i&&i!==Kn(r))throw new w(4004,!1)}toRoot(){return this.isAbsolute&&this.commands.length===1&&this.commands[0]=="/"}};function fi(t){if(typeof t[0]=="string"&&t.length===1&&t[0]==="/")return new lt(!0,0,t);let n=0,e=!1,r=t.reduce((i,o,s)=>{if(typeof o=="object"&&o!=null){if(o.outlets){let a={};return Object.entries(o.outlets).forEach(([c,u])=>{a[c]=typeof u=="string"?u.split("/"):u}),[...i,{outlets:a}]}if(o.segmentPath)return[...i,o.segmentPath]}return typeof o!="string"?[...i,o]:s===0?(o.split("/").forEach((a,c)=>{c==0&&a==="."||(c==0&&a===""?e=!0:a===".."?n++:a!=""&&i.push(a))}),i):[...i,o]},[]);return new lt(e,n,r)}var de=class{segmentGroup;processChildren;index;constructor(n,e,r){this.segmentGroup=n,this.processChildren=e,this.index=r}};function pi(t,n,e){if(t.isAbsolute)return new de(n,!0,0);if(!e)return new de(n,!1,NaN);if(e.parent===null)return new de(e,!0,0);let r=ut(t.commands[0])?0:1,i=e.segments.length-1+r;return gi(e,i,t.numberOfDoubleDots)}function gi(t,n,e){let r=t,i=n,o=e;for(;o>i;){if(o-=i,r=r.parent,!r)throw new w(4005,!1);i=r.segments.length}return new de(r,!1,i-o)}function vi(t){return Le(t[0])?t[0].outlets:{[f]:t}}function mn(t,n,e){if(t??=new v([],{}),t.segments.length===0&&t.hasChildren())return _e(t,n,e);let r=mi(t,n,e),i=e.slice(r.commandIndex);if(r.match&&r.pathIndex<t.segments.length){let o=new v(t.segments.slice(0,r.pathIndex),{});return o.children[f]=new v(t.segments.slice(r.pathIndex),t.children),_e(o,0,i)}else return r.match&&i.length===0?new v(t.segments,{}):r.match&&!t.hasChildren()?Wt(t,n,e):r.match?_e(t,0,i):Wt(t,n,e)}function _e(t,n,e){if(e.length===0)return new v(t.segments,{});{let r=vi(e),i={};if(Object.keys(r).some(o=>o!==f)&&t.children[f]&&t.numberOfChildren===1&&t.children[f].segments.length===0){let o=_e(t.children[f],n,e);return new v(t.segments,o.children)}return Object.entries(r).forEach(([o,s])=>{typeof s=="string"&&(s=[s]),s!==null&&(i[o]=mn(t.children[o],n,s))}),Object.entries(t.children).forEach(([o,s])=>{r[o]===void 0&&(i[o]=s)}),new v(t.segments,i)}}function mi(t,n,e){let r=0,i=n,o={match:!1,pathIndex:0,commandIndex:0};for(;i<t.segments.length;){if(r>=e.length)return o;let s=t.segments[i],a=e[r];if(Le(a))break;let c=`${a}`,u=r<e.length-1?e[r+1]:null;if(i>0&&c===void 0)break;if(c&&u&&typeof u=="object"&&u.outlets===void 0){if(!Jr(c,u,s))return o;r+=2}else{if(!Jr(c,{},s))return o;r++}i++}return{match:!0,pathIndex:i,commandIndex:r}}function Wt(t,n,e){let r=t.segments.slice(0,n),i=0;for(;i<e.length;){let o=e[i];if(Le(o)){let c=yi(o.outlets);return new v(r,c)}if(i===0&&ut(e[0])){let c=t.segments[n];r.push(new Y(c.path,Zr(e[0]))),i++;continue}let s=Le(o)?o.outlets[f]:`${o}`,a=i<e.length-1?e[i+1]:null;s&&a&&ut(a)?(r.push(new Y(s,Zr(a))),i+=2):(r.push(new Y(s,{})),i++)}return new v(r,{})}function yi(t){let n={};return Object.entries(t).forEach(([e,r])=>{typeof r=="string"&&(r=[r]),r!==null&&(n[e]=Wt(new v([],{}),0,r))}),n}function Zr(t){let n={};return Object.entries(t).forEach(([e,r])=>n[e]=`${r}`),n}function Jr(t,n,e){return t==e.path&&z(n,e.parameters)}var Oe="imperative",S=(function(t){return t[t.NavigationStart=0]="NavigationStart",t[t.NavigationEnd=1]="NavigationEnd",t[t.NavigationCancel=2]="NavigationCancel",t[t.NavigationError=3]="NavigationError",t[t.RoutesRecognized=4]="RoutesRecognized",t[t.ResolveStart=5]="ResolveStart",t[t.ResolveEnd=6]="ResolveEnd",t[t.GuardsCheckStart=7]="GuardsCheckStart",t[t.GuardsCheckEnd=8]="GuardsCheckEnd",t[t.RouteConfigLoadStart=9]="RouteConfigLoadStart",t[t.RouteConfigLoadEnd=10]="RouteConfigLoadEnd",t[t.ChildActivationStart=11]="ChildActivationStart",t[t.ChildActivationEnd=12]="ChildActivationEnd",t[t.ActivationStart=13]="ActivationStart",t[t.ActivationEnd=14]="ActivationEnd",t[t.Scroll=15]="Scroll",t[t.NavigationSkipped=16]="NavigationSkipped",t})(S||{}),D=class{id;url;constructor(n,e){this.id=n,this.url=e}},ae=class extends D{type=S.NavigationStart;navigationTrigger;restoredState;constructor(n,e,r="imperative",i=null){super(n,e),this.navigationTrigger=r,this.restoredState=i}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}},L=class extends D{urlAfterRedirects;type=S.NavigationEnd;constructor(n,e,r){super(n,e),this.urlAfterRedirects=r}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}},I=(function(t){return t[t.Redirect=0]="Redirect",t[t.SupersededByNewNavigation=1]="SupersededByNewNavigation",t[t.NoDataFromResolver=2]="NoDataFromResolver",t[t.GuardRejected=3]="GuardRejected",t[t.Aborted=4]="Aborted",t})(I||{}),xe=(function(t){return t[t.IgnoredSameUrlNavigation=0]="IgnoredSameUrlNavigation",t[t.IgnoredByUrlHandlingStrategy=1]="IgnoredByUrlHandlingStrategy",t})(xe||{}),P=class extends D{reason;code;type=S.NavigationCancel;constructor(n,e,r,i){super(n,e),this.reason=r,this.code=i}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}};function yn(t){return t instanceof P&&(t.code===I.Redirect||t.code===I.SupersededByNewNavigation)}var V=class extends D{reason;code;type=S.NavigationSkipped;constructor(n,e,r,i){super(n,e),this.reason=r,this.code=i}},se=class extends D{error;target;type=S.NavigationError;constructor(n,e,r,i){super(n,e),this.error=r,this.target=i}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}},je=class extends D{urlAfterRedirects;state;type=S.RoutesRecognized;constructor(n,e,r,i){super(n,e),this.urlAfterRedirects=r,this.state=i}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},dt=class extends D{urlAfterRedirects;state;type=S.GuardsCheckStart;constructor(n,e,r,i){super(n,e),this.urlAfterRedirects=r,this.state=i}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},ht=class extends D{urlAfterRedirects;state;shouldActivate;type=S.GuardsCheckEnd;constructor(n,e,r,i,o){super(n,e),this.urlAfterRedirects=r,this.state=i,this.shouldActivate=o}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}},ft=class extends D{urlAfterRedirects;state;type=S.ResolveStart;constructor(n,e,r,i){super(n,e),this.urlAfterRedirects=r,this.state=i}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},pt=class extends D{urlAfterRedirects;state;type=S.ResolveEnd;constructor(n,e,r,i){super(n,e),this.urlAfterRedirects=r,this.state=i}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},gt=class{route;type=S.RouteConfigLoadStart;constructor(n){this.route=n}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}},vt=class{route;type=S.RouteConfigLoadEnd;constructor(n){this.route=n}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}},mt=class{snapshot;type=S.ChildActivationStart;constructor(n){this.snapshot=n}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},yt=class{snapshot;type=S.ChildActivationEnd;constructor(n){this.snapshot=n}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Rt=class{snapshot;type=S.ActivationStart;constructor(n){this.snapshot=n}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Ct=class{snapshot;type=S.ActivationEnd;constructor(n){this.snapshot=n}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}};var fe=class{},ke=class{},pe=class{url;navigationBehaviorOptions;constructor(n,e){this.url=n,this.navigationBehaviorOptions=e}};function Ri(t){return!(t instanceof fe)&&!(t instanceof pe)&&!(t instanceof ke)}var St=class{rootInjector;outlet=null;route=null;children;attachRef=null;get injector(){return this.route?.snapshot._environmentInjector??this.rootInjector}constructor(n){this.rootInjector=n,this.children=new Re(this.rootInjector)}},Re=(()=>{class t{rootInjector;contexts=new Map;constructor(e){this.rootInjector=e}onChildOutletCreated(e,r){let i=this.getOrCreateContext(e);i.outlet=r,this.contexts.set(e,i)}onChildOutletDestroyed(e){let r=this.getContext(e);r&&(r.outlet=null,r.attachRef=null)}onOutletDeactivated(){let e=this.contexts;return this.contexts=new Map,e}onOutletReAttached(e){this.contexts=e}getOrCreateContext(e){let r=this.getContext(e);return r||(r=new St(this.rootInjector),this.contexts.set(e,r)),r}getContext(e){return this.contexts.get(e)||null}static \u0275fac=function(r){return new(r||t)(K(H))};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),wt=class{_root;constructor(n){this._root=n}get root(){return this._root.value}parent(n){let e=this.pathFromRoot(n);return e.length>1?e[e.length-2]:null}children(n){let e=Qt(n,this._root);return e?e.children.map(r=>r.value):[]}firstChild(n){let e=Qt(n,this._root);return e&&e.children.length>0?e.children[0].value:null}siblings(n){let e=Kt(n,this._root);return e.length<2?[]:e[e.length-2].children.map(i=>i.value).filter(i=>i!==n)}pathFromRoot(n){return Kt(n,this._root).map(e=>e.value)}};function Qt(t,n){if(t===n.value)return n;for(let e of n.children){let r=Qt(t,e);if(r)return r}return null}function Kt(t,n){if(t===n.value)return[n];for(let e of n.children){let r=Kt(t,e);if(r.length)return r.unshift(n),r}return[]}var T=class{value;children;constructor(n,e){this.value=n,this.children=e}toString(){return`TreeNode(${this.value})`}};function le(t){let n={};return t&&t.children.forEach(e=>n[e.value.outlet]=e),n}var $e=class extends wt{snapshot;constructor(n,e){super(n),this.snapshot=e,ar(this,n)}toString(){return this.snapshot.toString()}};function Rn(t,n){let e=Ci(t,n),r=new _([new Y("",{})]),i=new _({}),o=new _({}),s=new _({}),a=new _(""),c=new G(r,i,s,a,o,f,t,e.root);return c.snapshot=e.root,new $e(new T(c,[]),e)}function Ci(t,n){let e={},r={},i={},s=new ge([],e,i,"",r,f,t,null,{},n);return new ze("",new T(s,[]))}var G=class{urlSubject;paramsSubject;queryParamsSubject;fragmentSubject;dataSubject;outlet;component;snapshot;_futureSnapshot;_routerState;_paramMap;_queryParamMap;title;url;params;queryParams;fragment;data;constructor(n,e,r,i,o,s,a,c){this.urlSubject=n,this.paramsSubject=e,this.queryParamsSubject=r,this.fragmentSubject=i,this.dataSubject=o,this.outlet=s,this.component=a,this._futureSnapshot=c,this.title=this.dataSubject?.pipe(A(u=>u[He]))??g(void 0),this.url=n,this.params=e,this.queryParams=r,this.fragment=i,this.data=o}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=this.params.pipe(A(n=>oe(n))),this._paramMap}get queryParamMap(){return this._queryParamMap??=this.queryParams.pipe(A(n=>oe(n))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}};function or(t,n,e="emptyOnly"){let r,{routeConfig:i}=t;return n!==null&&(e==="always"||i?.path===""||!n.component&&!n.routeConfig?.loadComponent)?r={params:l(l({},n.params),t.params),data:l(l({},n.data),t.data),resolve:l(l(l(l({},t.data),n.data),i?.data),t._resolvedData)}:r={params:l({},t.params),data:l({},t.data),resolve:l(l({},t.data),t._resolvedData??{})},i&&Sn(i)&&(r.resolve[He]=i.title),r}var ge=class{url;params;queryParams;fragment;data;outlet;component;routeConfig;_resolve;_resolvedData;_routerState;_paramMap;_queryParamMap;_environmentInjector;get title(){return this.data?.[He]}constructor(n,e,r,i,o,s,a,c,u,d){this.url=n,this.params=e,this.queryParams=r,this.fragment=i,this.data=o,this.outlet=s,this.component=a,this.routeConfig=c,this._resolve=u,this._environmentInjector=d}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=oe(this.params),this._paramMap}get queryParamMap(){return this._queryParamMap??=oe(this.queryParams),this._queryParamMap}toString(){let n=this.url.map(r=>r.toString()).join("/"),e=this.routeConfig?this.routeConfig.path:"";return`Route(url:'${n}', path:'${e}')`}},ze=class extends wt{url;constructor(n,e){super(e),this.url=n,ar(this,e)}toString(){return Cn(this._root)}};function ar(t,n){n.value._routerState=t,n.children.forEach(e=>ar(t,e))}function Cn(t){let n=t.children.length>0?` { ${t.children.map(Cn).join(", ")} } `:"";return`${t.value}${n}`}function Ft(t){if(t.snapshot){let n=t.snapshot,e=t._futureSnapshot;t.snapshot=e,z(n.queryParams,e.queryParams)||t.queryParamsSubject.next(e.queryParams),n.fragment!==e.fragment&&t.fragmentSubject.next(e.fragment),z(n.params,e.params)||t.paramsSubject.next(e.params),Qn(n.url,e.url)||t.urlSubject.next(e.url),z(n.data,e.data)||t.dataSubject.next(e.data)}else t.snapshot=t._futureSnapshot,t.dataSubject.next(t._futureSnapshot.data)}function Yt(t,n){let e=z(t.params,n.params)&&Xn(t.url,n.url),r=!t.parent!=!n.parent;return e&&!r&&(!t.parent||Yt(t.parent,n.parent))}function Sn(t){return typeof t.title=="string"||t.title===null}var wn=new M(""),sr=(()=>{class t{activated=null;get activatedComponentRef(){return this.activated}_activatedRoute=null;name=f;activateEvents=new ne;deactivateEvents=new ne;attachEvents=new ne;detachEvents=new ne;routerOutletData=Vr();parentContexts=h(Re);location=h(Dr);changeDetector=h(et);inputBinder=h(Be,{optional:!0});supportsBindingToComponentInputs=!0;ngOnChanges(e){if(e.name){let{firstChange:r,previousValue:i}=e.name;if(r)return;this.isTrackedInParentContexts(i)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(i)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name),this.inputBinder?.unsubscribeFromRouteData(this)}isTrackedInParentContexts(e){return this.parentContexts.getContext(e)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;let e=this.parentContexts.getContext(this.name);e?.route&&(e.attachRef?this.attach(e.attachRef,e.route):this.activateWith(e.route,e.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new w(4012,!1);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new w(4012,!1);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new w(4012,!1);this.location.detach();let e=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(e.instance),e}attach(e,r){this.activated=e,this._activatedRoute=r,this.location.insert(e.hostView),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.attachEvents.emit(e.instance)}deactivate(){if(this.activated){let e=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(e)}}activateWith(e,r){if(this.isActivated)throw new w(4013,!1);this._activatedRoute=e;let i=this.location,s=e.snapshot.component,a=this.parentContexts.getOrCreateContext(this.name).children,c=new Zt(e,a,i.injector,this.routerOutletData);this.activated=i.createComponent(s,{index:i.length,injector:c,environmentInjector:r}),this.changeDetector.markForCheck(),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.activateEvents.emit(this.activated.instance)}static \u0275fac=function(r){return new(r||t)};static \u0275dir=Te({type:t,selectors:[["router-outlet"]],inputs:{name:"name",routerOutletData:[1,"routerOutletData"]},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],features:[Me]})}return t})(),Zt=class{route;childContexts;parent;outletData;constructor(n,e,r,i){this.route=n,this.childContexts=e,this.parent=r,this.outletData=i}get(n,e){return n===G?this.route:n===Re?this.childContexts:n===wn?this.outletData:this.parent.get(n,e)}},Be=new M(""),cr=(()=>{class t{outletDataSubscriptions=new Map;bindActivatedRouteToOutletComponent(e){this.unsubscribeFromRouteData(e),this.subscribeToRouteData(e)}unsubscribeFromRouteData(e){this.outletDataSubscriptions.get(e)?.unsubscribe(),this.outletDataSubscriptions.delete(e)}subscribeToRouteData(e){let{activatedRoute:r}=e,i=Ot([r.queryParams,r.params,r.data]).pipe(x(([o,s,a],c)=>(a=l(l(l({},o),s),a),c===0?g(a):Promise.resolve(a)))).subscribe(o=>{if(!e.isActivated||!e.activatedComponentRef||e.activatedRoute!==r||r.component===null){this.unsubscribeFromRouteData(e);return}let s=Gr(r.component);if(!s){this.unsubscribeFromRouteData(e);return}for(let{templateName:a}of s.inputs)e.activatedComponentRef.setInput(a,o[a])});this.outletDataSubscriptions.set(e,i)}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac})}return t})(),ur=(()=>{class t{static \u0275fac=function(r){return new(r||t)};static \u0275cmp=_r({type:t,selectors:[["ng-component"]],exportAs:["emptyRouterOutlet"],decls:1,vars:0,template:function(r,i){r&1&&jr(0,"router-outlet")},dependencies:[sr],encapsulation:2})}return t})();function lr(t){let n=t.children&&t.children.map(lr),e=n?N(l({},t),{children:n}):l({},t);return!e.component&&!e.loadComponent&&(n||e.loadChildren)&&e.outlet&&e.outlet!==f&&(e.component=ur),e}function Si(t,n,e){let r=Fe(t,n._root,e?e._root:void 0);return new $e(r,n)}function Fe(t,n,e){if(e&&t.shouldReuseRoute(n.value,e.value.snapshot)){let r=e.value;r._futureSnapshot=n.value;let i=wi(t,n,e);return new T(r,i)}else{if(t.shouldAttach(n.value)){let o=t.retrieve(n.value);if(o!==null){let s=o.route;return s.value._futureSnapshot=n.value,s.children=n.children.map(a=>Fe(t,a)),s}}let r=bi(n.value),i=n.children.map(o=>Fe(t,o));return new T(r,i)}}function wi(t,n,e){return n.children.map(r=>{for(let i of e.children)if(t.shouldReuseRoute(r.value,i.value.snapshot))return Fe(t,r,i);return Fe(t,r)})}function bi(t){return new G(new _(t.url),new _(t.params),new _(t.queryParams),new _(t.fragment),new _(t.data),t.outlet,t.component,t)}var ve=class{redirectTo;navigationBehaviorOptions;constructor(n,e){this.redirectTo=n,this.navigationBehaviorOptions=e}},bn="ngNavigationCancelingError";function bt(t,n){let{redirectTo:e,navigationBehaviorOptions:r}=J(n)?{redirectTo:n,navigationBehaviorOptions:void 0}:n,i=In(!1,I.Redirect);return i.url=e,i.navigationBehaviorOptions=r,i}function In(t,n){let e=new Error(`NavigationCancelingError: ${t||""}`);return e[bn]=!0,e.cancellationCode=n,e}function Ii(t){return An(t)&&J(t.url)}function An(t){return!!t&&t[bn]}var Jt=class{routeReuseStrategy;futureState;currState;forwardEvent;inputBindingEnabled;constructor(n,e,r,i,o){this.routeReuseStrategy=n,this.futureState=e,this.currState=r,this.forwardEvent=i,this.inputBindingEnabled=o}activate(n){let e=this.futureState._root,r=this.currState?this.currState._root:null;this.deactivateChildRoutes(e,r,n),Ft(this.futureState.root),this.activateChildRoutes(e,r,n)}deactivateChildRoutes(n,e,r){let i=le(e);n.children.forEach(o=>{let s=o.value.outlet;this.deactivateRoutes(o,i[s],r),delete i[s]}),Object.values(i).forEach(o=>{this.deactivateRouteAndItsChildren(o,r)})}deactivateRoutes(n,e,r){let i=n.value,o=e?e.value:null;if(i===o)if(i.component){let s=r.getContext(i.outlet);s&&this.deactivateChildRoutes(n,e,s.children)}else this.deactivateChildRoutes(n,e,r);else o&&this.deactivateRouteAndItsChildren(e,r)}deactivateRouteAndItsChildren(n,e){n.value.component&&this.routeReuseStrategy.shouldDetach(n.value.snapshot)?this.detachAndStoreRouteSubtree(n,e):this.deactivateRouteAndOutlet(n,e)}detachAndStoreRouteSubtree(n,e){let r=e.getContext(n.value.outlet),i=r&&n.value.component?r.children:e,o=le(n);for(let s of Object.values(o))this.deactivateRouteAndItsChildren(s,i);if(r&&r.outlet){let s=r.outlet.detach(),a=r.children.onOutletDeactivated();this.routeReuseStrategy.store(n.value.snapshot,{componentRef:s,route:n,contexts:a})}}deactivateRouteAndOutlet(n,e){let r=e.getContext(n.value.outlet),i=r&&n.value.component?r.children:e,o=le(n);for(let s of Object.values(o))this.deactivateRouteAndItsChildren(s,i);r&&(r.outlet&&(r.outlet.deactivate(),r.children.onOutletDeactivated()),r.attachRef=null,r.route=null)}activateChildRoutes(n,e,r){let i=le(e);n.children.forEach(o=>{this.activateRoutes(o,i[o.value.outlet],r),this.forwardEvent(new Ct(o.value.snapshot))}),n.children.length&&this.forwardEvent(new yt(n.value.snapshot))}activateRoutes(n,e,r){let i=n.value,o=e?e.value:null;if(Ft(i),i===o)if(i.component){let s=r.getOrCreateContext(i.outlet);this.activateChildRoutes(n,e,s.children)}else this.activateChildRoutes(n,e,r);else if(i.component){let s=r.getOrCreateContext(i.outlet);if(this.routeReuseStrategy.shouldAttach(i.snapshot)){let a=this.routeReuseStrategy.retrieve(i.snapshot);this.routeReuseStrategy.store(i.snapshot,null),s.children.onOutletReAttached(a.contexts),s.attachRef=a.componentRef,s.route=a.route.value,s.outlet&&s.outlet.attach(a.componentRef,a.route.value),Ft(a.route.value),this.activateChildRoutes(n,null,s.children)}else s.attachRef=null,s.route=i,s.outlet&&s.outlet.activateWith(i,s.injector),this.activateChildRoutes(n,null,s.children)}else this.activateChildRoutes(n,null,r)}},It=class{path;route;constructor(n){this.path=n,this.route=this.path[this.path.length-1]}},he=class{component;route;constructor(n,e){this.component=n,this.route=e}};function Ai(t,n,e){let r=t._root,i=n?n._root:null;return Ne(r,i,e,[r.value])}function Ei(t){let n=t.routeConfig?t.routeConfig.canActivateChild:null;return!n||n.length===0?null:{node:t,guards:n}}function Ce(t,n){let e=Symbol(),r=n.get(t,e);return r===e?typeof t=="function"&&!br(t)?t:n.get(t):r}function Ne(t,n,e,r,i={canDeactivateChecks:[],canActivateChecks:[]}){let o=le(n);return t.children.forEach(s=>{Mi(s,o[s.value.outlet],e,r.concat([s.value]),i),delete o[s.value.outlet]}),Object.entries(o).forEach(([s,a])=>Ue(a,e.getContext(s),i)),i}function Mi(t,n,e,r,i={canDeactivateChecks:[],canActivateChecks:[]}){let o=t.value,s=n?n.value:null,a=e?e.getContext(t.value.outlet):null;if(s&&o.routeConfig===s.routeConfig){let c=Ti(s,o,o.routeConfig.runGuardsAndResolvers);c?i.canActivateChecks.push(new It(r)):(o.data=s.data,o._resolvedData=s._resolvedData),o.component?Ne(t,n,a?a.children:null,r,i):Ne(t,n,e,r,i),c&&a&&a.outlet&&a.outlet.isActivated&&i.canDeactivateChecks.push(new he(a.outlet.component,s))}else s&&Ue(n,a,i),i.canActivateChecks.push(new It(r)),o.component?Ne(t,null,a?a.children:null,r,i):Ne(t,null,e,r,i);return i}function Ti(t,n,e){if(typeof e=="function")return U(n._environmentInjector,()=>e(t,n));switch(e){case"pathParamsChange":return!ie(t.url,n.url);case"pathParamsOrQueryParamsChange":return!ie(t.url,n.url)||!z(t.queryParams,n.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!Yt(t,n)||!z(t.queryParams,n.queryParams);default:return!Yt(t,n)}}function Ue(t,n,e){let r=le(t),i=t.value;Object.entries(r).forEach(([o,s])=>{i.component?n?Ue(s,n.children.getContext(o),e):Ue(s,null,e):Ue(s,n,e)}),i.component?n&&n.outlet&&n.outlet.isActivated?e.canDeactivateChecks.push(new he(n.outlet.component,i)):e.canDeactivateChecks.push(new he(null,i)):e.canDeactivateChecks.push(new he(null,i))}function Ve(t){return typeof t=="function"}function Di(t){return typeof t=="boolean"}function Ni(t){return t&&Ve(t.canLoad)}function _i(t){return t&&Ve(t.canActivate)}function Oi(t){return t&&Ve(t.canActivateChild)}function Ui(t){return t&&Ve(t.canDeactivate)}function Pi(t){return t&&Ve(t.canMatch)}function En(t){return t instanceof yr||t?.name==="EmptyError"}var it=Symbol("INITIAL_VALUE");function me(){return x(t=>Ot(t.map(n=>n.pipe(ue(1),Sr(it)))).pipe(A(n=>{for(let e of n)if(e!==!0){if(e===it)return it;if(e===!1||Li(e))return e}return!0}),W(n=>n!==it),ue(1)))}function Li(t){return J(t)||t instanceof ve}function Mn(t){return t.aborted?g(void 0).pipe(ue(1)):new vr(n=>{let e=()=>{n.next(),n.complete()};return t.addEventListener("abort",e),()=>t.removeEventListener("abort",e)})}function Tn(t){return Ye(Mn(t))}function xi(t){return k(n=>{let{targetSnapshot:e,currentSnapshot:r,guards:{canActivateChecks:i,canDeactivateChecks:o}}=n;return o.length===0&&i.length===0?g(N(l({},n),{guardsResult:!0})):ji(o,e,r).pipe(k(s=>s&&Di(s)?ki(e,i,t):g(s)),A(s=>N(l({},n),{guardsResult:s})))})}function ji(t,n,e){return b(t).pipe(k(r=>Hi(r.component,r.route,e,n)),Q(r=>r!==!0,!0))}function ki(t,n,e){return b(n).pipe(Ee(r=>Rr(zi(r.route.parent,e),$i(r.route,e),qi(t,r.path),Fi(t,r.route))),Q(r=>r!==!0,!0))}function $i(t,n){return t!==null&&n&&n(new Rt(t)),g(!0)}function zi(t,n){return t!==null&&n&&n(new mt(t)),g(!0)}function Fi(t,n){let e=n.routeConfig?n.routeConfig.canActivate:null;if(!e||e.length===0)return g(!0);let r=e.map(i=>Ke(()=>{let o=n._environmentInjector,s=Ce(i,o),a=_i(s)?s.canActivate(n,t):U(o,()=>s(n,t));return ce(a).pipe(Q())}));return g(r).pipe(me())}function qi(t,n){let e=n[n.length-1],i=n.slice(0,n.length-1).reverse().map(o=>Ei(o)).filter(o=>o!==null).map(o=>Ke(()=>{let s=o.guards.map(a=>{let c=o.node._environmentInjector,u=Ce(a,c),d=Oi(u)?u.canActivateChild(e,t):U(c,()=>u(e,t));return ce(d).pipe(Q())});return g(s).pipe(me())}));return g(i).pipe(me())}function Hi(t,n,e,r){let i=n&&n.routeConfig?n.routeConfig.canDeactivate:null;if(!i||i.length===0)return g(!0);let o=i.map(s=>{let a=n._environmentInjector,c=Ce(s,a),u=Ui(c)?c.canDeactivate(t,n,e,r):U(a,()=>c(t,n,e,r));return ce(u).pipe(Q())});return g(o).pipe(me())}function Bi(t,n,e,r,i){let o=n.canLoad;if(o===void 0||o.length===0)return g(!0);let s=o.map(a=>{let c=Ce(a,t),u=Ni(c)?c.canLoad(n,e):U(t,()=>c(n,e)),d=ce(u);return i?d.pipe(Tn(i)):d});return g(s).pipe(me(),Dn(r))}function Dn(t){return gr(j(n=>{if(typeof n!="boolean")throw bt(t,n)}),A(n=>n===!0))}function Vi(t,n,e,r,i,o){let s=n.canMatch;if(!s||s.length===0)return g(!0);let a=s.map(c=>{let u=Ce(c,t),d=Pi(u)?u.canMatch(n,e,i):U(t,()=>u(n,e,i));return ce(d).pipe(Tn(o))});return g(a).pipe(me(),Dn(r))}var B=class t extends Error{segmentGroup;constructor(n){super(),this.segmentGroup=n||null,Object.setPrototypeOf(this,t.prototype)}},qe=class t extends Error{urlTree;constructor(n){super(),this.urlTree=n,Object.setPrototypeOf(this,t.prototype)}};function Gi(t){throw new w(4e3,!1)}function Wi(t){throw In(!1,I.GuardRejected)}var Xt=class{urlSerializer;urlTree;constructor(n,e){this.urlSerializer=n,this.urlTree=e}async lineralizeSegments(n,e){let r=[],i=e.root;for(;;){if(r=r.concat(i.segments),i.numberOfChildren===0)return r;if(i.numberOfChildren>1||!i.children[f])throw Gi(`${n.redirectTo}`);i=i.children[f]}}async applyRedirectCommands(n,e,r,i,o){let s=await Qi(e,i,o);if(s instanceof E)throw new qe(s);let a=this.applyRedirectCreateUrlTree(s,this.urlSerializer.parse(s),n,r);if(s[0]==="/")throw new qe(a);return a}applyRedirectCreateUrlTree(n,e,r,i){let o=this.createSegmentGroup(n,e.root,r,i);return new E(o,this.createQueryParams(e.queryParams,this.urlTree.queryParams),e.fragment)}createQueryParams(n,e){let r={};return Object.entries(n).forEach(([i,o])=>{if(typeof o=="string"&&o[0]===":"){let a=o.substring(1);r[i]=e[a]}else r[i]=o}),r}createSegmentGroup(n,e,r,i){let o=this.createSegments(n,e.segments,r,i),s={};return Object.entries(e.children).forEach(([a,c])=>{s[a]=this.createSegmentGroup(n,c,r,i)}),new v(o,s)}createSegments(n,e,r,i){return e.map(o=>o.path[0]===":"?this.findPosParam(n,o,i):this.findOrReturn(o,r))}findPosParam(n,e,r){let i=r[e.path.substring(1)];if(!i)throw new w(4001,!1);return i}findOrReturn(n,e){let r=0;for(let i of e){if(i.path===n.path)return e.splice(r),i;r++}return n}};function Qi(t,n,e){if(typeof t=="string")return Promise.resolve(t);let r=t;return ct(ce(U(e,()=>r(n))))}function Ki(t,n){return t.providers&&!t._injector&&(t._injector=Je(t.providers,n,`Route: ${t.path}`)),t._injector??n}function F(t){return t.outlet||f}function Yi(t,n){let e=t.filter(r=>F(r)===n);return e.push(...t.filter(r=>F(r)!==n)),e}var er={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function Nn(t){return{routeConfig:t.routeConfig,url:t.url,params:t.params,queryParams:t.queryParams,fragment:t.fragment,data:t.data,outlet:t.outlet,title:t.title,paramMap:t.paramMap,queryParamMap:t.queryParamMap}}function Zi(t,n,e,r,i,o,s){let a=_n(t,n,e);if(!a.matched)return g(a);let c=Nn(o(a));return r=Ki(n,r),Vi(r,n,e,i,c,s).pipe(A(u=>u===!0?a:l({},er)))}function _n(t,n,e){if(n.path==="")return n.pathMatch==="full"&&(t.hasChildren()||e.length>0)?l({},er):{matched:!0,consumedSegments:[],remainingSegments:e,parameters:{},positionalParamSegments:{}};let i=(n.matcher||tn)(e,t,n);if(!i)return l({},er);let o={};Object.entries(i.posParams??{}).forEach(([a,c])=>{o[a]=c.path});let s=i.consumed.length>0?l(l({},o),i.consumed[i.consumed.length-1].parameters):o;return{matched:!0,consumedSegments:i.consumed,remainingSegments:e.slice(i.consumed.length),parameters:s,positionalParamSegments:i.posParams??{}}}function Xr(t,n,e,r){return e.length>0&&eo(t,e,r)?{segmentGroup:new v(n,Xi(r,new v(e,t.children))),slicedSegments:[]}:e.length===0&&to(t,e,r)?{segmentGroup:new v(t.segments,Ji(t,e,r,t.children)),slicedSegments:e}:{segmentGroup:new v(t.segments,t.children),slicedSegments:e}}function Ji(t,n,e,r){let i={};for(let o of e)if(Et(t,n,o)&&!r[F(o)]){let s=new v([],{});i[F(o)]=s}return l(l({},r),i)}function Xi(t,n){let e={};e[f]=n;for(let r of t)if(r.path===""&&F(r)!==f){let i=new v([],{});e[F(r)]=i}return e}function eo(t,n,e){return e.some(r=>Et(t,n,r)&&F(r)!==f)}function to(t,n,e){return e.some(r=>Et(t,n,r))}function Et(t,n,e){return(t.hasChildren()||n.length>0)&&e.pathMatch==="full"?!1:e.path===""}function ro(t,n,e){return n.length===0&&!t.children[e]}var tr=class{};async function no(t,n,e,r,i,o,s="emptyOnly",a){return new rr(t,n,e,r,i,s,o,a).recognize()}var io=31,rr=class{injector;configLoader;rootComponentType;config;urlTree;paramsInheritanceStrategy;urlSerializer;abortSignal;applyRedirects;absoluteRedirectCount=0;allowRedirects=!0;constructor(n,e,r,i,o,s,a,c){this.injector=n,this.configLoader=e,this.rootComponentType=r,this.config=i,this.urlTree=o,this.paramsInheritanceStrategy=s,this.urlSerializer=a,this.abortSignal=c,this.applyRedirects=new Xt(this.urlSerializer,this.urlTree)}noMatchError(n){return new w(4002,`'${n.segmentGroup}'`)}async recognize(){let n=Xr(this.urlTree.root,[],[],this.config).segmentGroup,{children:e,rootSnapshot:r}=await this.match(n),i=new T(r,e),o=new ze("",i),s=fn(r,[],this.urlTree.queryParams,this.urlTree.fragment);return s.queryParams=this.urlTree.queryParams,o.url=this.urlSerializer.serialize(s),{state:o,tree:s}}async match(n){let e=new ge([],Object.freeze({}),Object.freeze(l({},this.urlTree.queryParams)),this.urlTree.fragment,Object.freeze({}),f,this.rootComponentType,null,{},this.injector);try{return{children:await this.processSegmentGroup(this.injector,this.config,n,f,e),rootSnapshot:e}}catch(r){if(r instanceof qe)return this.urlTree=r.urlTree,this.match(r.urlTree.root);throw r instanceof B?this.noMatchError(r):r}}async processSegmentGroup(n,e,r,i,o){if(r.segments.length===0&&r.hasChildren())return this.processChildren(n,e,r,o);let s=await this.processSegment(n,e,r,r.segments,i,!0,o);return s instanceof T?[s]:[]}async processChildren(n,e,r,i){let o=[];for(let c of Object.keys(r.children))c==="primary"?o.unshift(c):o.push(c);let s=[];for(let c of o){let u=r.children[c],d=Yi(e,c),p=await this.processSegmentGroup(n,d,u,c,i);s.push(...p)}let a=On(s);return oo(a),a}async processSegment(n,e,r,i,o,s,a){for(let c of e)try{return await this.processSegmentAgainstRoute(c._injector??n,e,c,r,i,o,s,a)}catch(u){if(u instanceof B||En(u))continue;throw u}if(ro(r,i,o))return new tr;throw new B(r)}async processSegmentAgainstRoute(n,e,r,i,o,s,a,c){if(F(r)!==s&&(s===f||!Et(i,o,r)))throw new B(i);if(r.redirectTo===void 0)return this.matchSegmentAgainstRoute(n,i,r,o,s,c);if(this.allowRedirects&&a)return this.expandSegmentAgainstRouteUsingRedirect(n,i,e,r,o,s,c);throw new B(i)}async expandSegmentAgainstRouteUsingRedirect(n,e,r,i,o,s,a){let{matched:c,parameters:u,consumedSegments:d,positionalParamSegments:p,remainingSegments:m}=_n(e,i,o);if(!c)throw new B(e);typeof i.redirectTo=="string"&&i.redirectTo[0]==="/"&&(this.absoluteRedirectCount++,this.absoluteRedirectCount>io&&(this.allowRedirects=!1));let ee=this.createSnapshot(n,i,o,u,a);if(this.abortSignal.aborted)throw new Error(this.abortSignal.reason);let q=await this.applyRedirects.applyRedirectCommands(d,i.redirectTo,p,Nn(ee),n),te=await this.applyRedirects.lineralizeSegments(i,q);return this.processSegment(n,r,e,te.concat(m),s,!1,a)}createSnapshot(n,e,r,i,o){let s=new ge(r,i,Object.freeze(l({},this.urlTree.queryParams)),this.urlTree.fragment,so(e),F(e),e.component??e._loadedComponent??null,e,co(e),n),a=or(s,o,this.paramsInheritanceStrategy);return s.params=Object.freeze(a.params),s.data=Object.freeze(a.data),s}async matchSegmentAgainstRoute(n,e,r,i,o,s){if(this.abortSignal.aborted)throw new Error(this.abortSignal.reason);let a=Qe=>this.createSnapshot(n,r,Qe.consumedSegments,Qe.parameters,s),c=await ct(Zi(e,r,i,n,this.urlSerializer,a,this.abortSignal));if(r.path==="**"&&(e.children={}),!c?.matched)throw new B(e);n=r._injector??n;let{routes:u}=await this.getChildConfig(n,r,i),d=r._loadedInjector??n,{parameters:p,consumedSegments:m,remainingSegments:ee}=c,q=this.createSnapshot(n,r,m,p,s),{segmentGroup:te,slicedSegments:we}=Xr(e,m,ee,u);if(we.length===0&&te.hasChildren()){let Qe=await this.processChildren(d,u,te,q);return new T(q,Qe)}if(u.length===0&&we.length===0)return new T(q,[]);let Nt=F(r)===o,be=await this.processSegment(d,u,te,we,Nt?f:o,!0,q);return new T(q,be instanceof T?[be]:[])}async getChildConfig(n,e,r){if(e.children)return{routes:e.children,injector:n};if(e.loadChildren){if(e._loadedRoutes!==void 0){let o=e._loadedNgModuleFactory;return o&&!e._loadedInjector&&(e._loadedInjector=o.create(n).injector),{routes:e._loadedRoutes,injector:e._loadedInjector}}if(this.abortSignal.aborted)throw new Error(this.abortSignal.reason);if(await ct(Bi(n,e,r,this.urlSerializer,this.abortSignal))){let o=await this.configLoader.loadChildren(n,e);return e._loadedRoutes=o.routes,e._loadedInjector=o.injector,e._loadedNgModuleFactory=o.factory,o}throw Wi(e)}return{routes:[],injector:n}}};function oo(t){t.sort((n,e)=>n.value.outlet===f?-1:e.value.outlet===f?1:n.value.outlet.localeCompare(e.value.outlet))}function ao(t){let n=t.value.routeConfig;return n&&n.path===""}function On(t){let n=[],e=new Set;for(let r of t){if(!ao(r)){n.push(r);continue}let i=n.find(o=>r.value.routeConfig===o.value.routeConfig);i!==void 0?(i.children.push(...r.children),e.add(i)):n.push(r)}for(let r of e){let i=On(r.children);n.push(new T(r.value,i))}return n.filter(r=>!e.has(r))}function so(t){return t.data||{}}function co(t){return t.resolve||{}}function uo(t,n,e,r,i,o,s){return k(async a=>{let{state:c,tree:u}=await no(t,n,e,r,a.extractedUrl,i,o,s);return N(l({},a),{targetSnapshot:c,urlAfterRedirects:u})})}function lo(t){return k(n=>{let{targetSnapshot:e,guards:{canActivateChecks:r}}=n;if(!r.length)return g(n);let i=new Set(r.map(a=>a.route)),o=new Set;for(let a of i)if(!o.has(a))for(let c of Un(a))o.add(c);let s=0;return b(o).pipe(Ee(a=>i.has(a)?ho(a,e,t):(a.data=or(a,a.parent,t).resolve,g(void 0))),j(()=>s++),Ut(1),k(a=>s===o.size?g(n):O))})}function Un(t){let n=t.children.map(e=>Un(e)).flat();return[t,...n]}function ho(t,n,e){let r=t.routeConfig,i=t._resolve;return r?.title!==void 0&&!Sn(r)&&(i[He]=r.title),Ke(()=>(t.data=or(t,t.parent,e).resolve,fo(i,t,n).pipe(A(o=>(t._resolvedData=o,t.data=l(l({},t.data),o),null)))))}function fo(t,n,e){let r=Ht(t);if(r.length===0)return g({});let i={};return b(r).pipe(k(o=>po(t[o],n,e).pipe(Q(),j(s=>{if(s instanceof ve)throw bt(new Z,s);i[o]=s}))),Ut(1),A(()=>i),Ae(o=>En(o)?O:mr(o)))}function po(t,n,e){let r=n._environmentInjector,i=Ce(t,r),o=i.resolve?i.resolve(n,e):U(r,()=>i(n,e));return ce(o)}function en(t){return x(n=>{let e=t(n);return e?b(e).pipe(A(()=>n)):g(n)})}var dr=(()=>{class t{buildTitle(e){let r,i=e.root;for(;i!==void 0;)r=this.getResolvedTitleForRoute(i)??r,i=i.children.find(o=>o.outlet===f);return r}getResolvedTitleForRoute(e){return e.data[He]}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:()=>h(Pn),providedIn:"root"})}return t})(),Pn=(()=>{class t extends dr{title;constructor(e){super(),this.title=e}updateTitle(e){let r=this.buildTitle(e);r!==void 0&&this.title.setTitle(r)}static \u0275fac=function(r){return new(r||t)(K(Qr))};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Se=new M("",{factory:()=>({})}),Ge=new M(""),hr=(()=>{class t{componentLoaders=new WeakMap;childrenLoaders=new WeakMap;onLoadStartListener;onLoadEndListener;compiler=h(qr);async loadComponent(e,r){if(this.componentLoaders.get(r))return this.componentLoaders.get(r);if(r._loadedComponent)return Promise.resolve(r._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(r);let i=(async()=>{try{let o=await nn(U(e,()=>r.loadComponent())),s=await jn(xn(o));return this.onLoadEndListener&&this.onLoadEndListener(r),r._loadedComponent=s,s}finally{this.componentLoaders.delete(r)}})();return this.componentLoaders.set(r,i),i}loadChildren(e,r){if(this.childrenLoaders.get(r))return this.childrenLoaders.get(r);if(r._loadedRoutes)return Promise.resolve({routes:r._loadedRoutes,injector:r._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(r);let i=(async()=>{try{let o=await Ln(r,this.compiler,e,this.onLoadEndListener);return r._loadedRoutes=o.routes,r._loadedInjector=o.injector,r._loadedNgModuleFactory=o.factory,o}finally{this.childrenLoaders.delete(r)}})();return this.childrenLoaders.set(r,i),i}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();async function Ln(t,n,e,r){let i=await nn(U(e,()=>t.loadChildren())),o=await jn(xn(i)),s;o instanceof Nr||Array.isArray(o)?s=o:s=await n.compileModuleAsync(o),r&&r(t);let a,c,u=!1,d;return Array.isArray(s)?(c=s,u=!0):(a=s.create(e).injector,d=s,c=a.get(Ge,[],{optional:!0,self:!0}).flat()),{routes:c.map(lr),injector:a,factory:d}}function go(t){return t&&typeof t=="object"&&"default"in t}function xn(t){return go(t)?t.default:t}async function jn(t){return t}var Mt=(()=>{class t{static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:()=>h(vo),providedIn:"root"})}return t})(),vo=(()=>{class t{shouldProcessUrl(e){return!0}extract(e){return e}merge(e,r){return e}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),kn=new M("");var mo=()=>{},$n=new M(""),zn=(()=>{class t{currentNavigation=C(null,{equal:()=>!1});currentTransition=null;lastSuccessfulNavigation=C(null);events=new re;transitionAbortWithErrorSubject=new re;configLoader=h(hr);environmentInjector=h(H);destroyRef=h(Pt);urlSerializer=h(ye);rootContexts=h(Re);location=h(rt);inputBindingEnabled=h(Be,{optional:!0})!==null;titleStrategy=h(dr);options=h(Se,{optional:!0})||{};paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly";urlHandlingStrategy=h(Mt);createViewTransition=h(kn,{optional:!0});navigationErrorHandler=h($n,{optional:!0});navigationId=0;get hasRequestedNavigation(){return this.navigationId!==0}transitions;afterPreactivation=()=>g(void 0);rootComponentType=null;destroyed=!1;constructor(){let e=i=>this.events.next(new gt(i)),r=i=>this.events.next(new vt(i));this.configLoader.onLoadEndListener=r,this.configLoader.onLoadStartListener=e,this.destroyRef.onDestroy(()=>{this.destroyed=!0})}complete(){this.transitions?.complete()}handleNavigationRequest(e){let r=++this.navigationId;y(()=>{this.transitions?.next(N(l({},e),{extractedUrl:this.urlHandlingStrategy.extract(e.rawUrl),targetSnapshot:null,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null,id:r,routesRecognizeHandler:{},beforeActivateHandler:{}}))})}setupNavigations(e){return this.transitions=new _(null),this.transitions.pipe(W(r=>r!==null),x(r=>{let i=!1,o=new AbortController,s=()=>!i&&this.currentTransition?.id===r.id;return g(r).pipe(x(a=>{if(this.navigationId>r.id)return this.cancelNavigationTransition(r,"",I.SupersededByNewNavigation),O;this.currentTransition=r;let c=this.lastSuccessfulNavigation();this.currentNavigation.set({id:a.id,initialUrl:a.rawUrl,extractedUrl:a.extractedUrl,targetBrowserUrl:typeof a.extras.browserUrl=="string"?this.urlSerializer.parse(a.extras.browserUrl):a.extras.browserUrl,trigger:a.source,extras:a.extras,previousNavigation:c?N(l({},c),{previousNavigation:null}):null,abort:()=>o.abort(),routesRecognizeHandler:a.routesRecognizeHandler,beforeActivateHandler:a.beforeActivateHandler});let u=!e.navigated||this.isUpdatingInternalState()||this.isUpdatedBrowserUrl(),d=a.extras.onSameUrlNavigation??e.onSameUrlNavigation;if(!u&&d!=="reload")return this.events.next(new V(a.id,this.urlSerializer.serialize(a.rawUrl),"",xe.IgnoredSameUrlNavigation)),a.resolve(!1),O;if(this.urlHandlingStrategy.shouldProcessUrl(a.rawUrl))return g(a).pipe(x(p=>(this.events.next(new ae(p.id,this.urlSerializer.serialize(p.extractedUrl),p.source,p.restoredState)),p.id!==this.navigationId?O:Promise.resolve(p))),uo(this.environmentInjector,this.configLoader,this.rootComponentType,e.config,this.urlSerializer,this.paramsInheritanceStrategy,o.signal),j(p=>{r.targetSnapshot=p.targetSnapshot,r.urlAfterRedirects=p.urlAfterRedirects,this.currentNavigation.update(m=>(m.finalUrl=p.urlAfterRedirects,m)),this.events.next(new ke)}),x(p=>b(r.routesRecognizeHandler.deferredHandle??g(void 0)).pipe(A(()=>p))),j(()=>{let p=new je(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot);this.events.next(p)}));if(u&&this.urlHandlingStrategy.shouldProcessUrl(a.currentRawUrl)){let{id:p,extractedUrl:m,source:ee,restoredState:q,extras:te}=a,we=new ae(p,this.urlSerializer.serialize(m),ee,q);this.events.next(we);let Nt=Rn(this.rootComponentType,this.environmentInjector).snapshot;return this.currentTransition=r=N(l({},a),{targetSnapshot:Nt,urlAfterRedirects:m,extras:N(l({},te),{skipLocationChange:!1,replaceUrl:!1})}),this.currentNavigation.update(be=>(be.finalUrl=m,be)),g(r)}else return this.events.next(new V(a.id,this.urlSerializer.serialize(a.extractedUrl),"",xe.IgnoredByUrlHandlingStrategy)),a.resolve(!1),O}),A(a=>{let c=new dt(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot);return this.events.next(c),this.currentTransition=r=N(l({},a),{guards:Ai(a.targetSnapshot,a.currentSnapshot,this.rootContexts)}),r}),xi(a=>this.events.next(a)),x(a=>{if(r.guardsResult=a.guardsResult,a.guardsResult&&typeof a.guardsResult!="boolean")throw bt(this.urlSerializer,a.guardsResult);let c=new ht(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot,!!a.guardsResult);if(this.events.next(c),!s())return O;if(!a.guardsResult)return this.cancelNavigationTransition(a,"",I.GuardRejected),O;if(a.guards.canActivateChecks.length===0)return g(a);let u=new ft(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot);if(this.events.next(u),!s())return O;let d=!1;return g(a).pipe(lo(this.paramsInheritanceStrategy),j({next:()=>{d=!0;let p=new pt(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot);this.events.next(p)},complete:()=>{d||this.cancelNavigationTransition(a,"",I.NoDataFromResolver)}}))}),en(a=>{let c=d=>{let p=[];if(d.routeConfig?._loadedComponent)d.component=d.routeConfig?._loadedComponent;else if(d.routeConfig?.loadComponent){let m=d._environmentInjector;p.push(this.configLoader.loadComponent(m,d.routeConfig).then(ee=>{d.component=ee}))}for(let m of d.children)p.push(...c(m));return p},u=c(a.targetSnapshot.root);return u.length===0?g(a):b(Promise.all(u).then(()=>a))}),en(()=>this.afterPreactivation()),x(()=>{let{currentSnapshot:a,targetSnapshot:c}=r,u=this.createViewTransition?.(this.environmentInjector,a.root,c.root);return u?b(u).pipe(A(()=>r)):g(r)}),ue(1),x(a=>{let c=Si(e.routeReuseStrategy,a.targetSnapshot,a.currentRouterState);this.currentTransition=r=a=N(l({},a),{targetRouterState:c}),this.currentNavigation.update(d=>(d.targetRouterState=c,d)),this.events.next(new fe);let u=r.beforeActivateHandler.deferredHandle;return u?b(u.then(()=>a)):g(a)}),j(a=>{new Jt(e.routeReuseStrategy,r.targetRouterState,r.currentRouterState,c=>this.events.next(c),this.inputBindingEnabled).activate(this.rootContexts),s()&&(i=!0,this.currentNavigation.update(c=>(c.abort=mo,c)),this.lastSuccessfulNavigation.set(y(this.currentNavigation)),this.events.next(new L(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects))),this.titleStrategy?.updateTitle(a.targetRouterState.snapshot),a.resolve(!0))}),Ye(Mn(o.signal).pipe(W(()=>!i&&!r.targetRouterState),j(()=>{this.cancelNavigationTransition(r,o.signal.reason+"",I.Aborted)}))),j({complete:()=>{i=!0}}),Ye(this.transitionAbortWithErrorSubject.pipe(j(a=>{throw a}))),Cr(()=>{o.abort(),i||this.cancelNavigationTransition(r,"",I.SupersededByNewNavigation),this.currentTransition?.id===r.id&&(this.currentNavigation.set(null),this.currentTransition=null)}),Ae(a=>{if(i=!0,this.destroyed)return r.resolve(!1),O;if(An(a))this.events.next(new P(r.id,this.urlSerializer.serialize(r.extractedUrl),a.message,a.cancellationCode)),Ii(a)?this.events.next(new pe(a.url,a.navigationBehaviorOptions)):r.resolve(!1);else{let c=new se(r.id,this.urlSerializer.serialize(r.extractedUrl),a,r.targetSnapshot??void 0);try{let u=U(this.environmentInjector,()=>this.navigationErrorHandler?.(c));if(u instanceof ve){let{message:d,cancellationCode:p}=bt(this.urlSerializer,u);this.events.next(new P(r.id,this.urlSerializer.serialize(r.extractedUrl),d,p)),this.events.next(new pe(u.redirectTo,u.navigationBehaviorOptions))}else throw this.events.next(c),a}catch(u){this.options.resolveNavigationPromiseOnError?r.resolve(!1):r.reject(u)}}return O}))}))}cancelNavigationTransition(e,r,i){let o=new P(e.id,this.urlSerializer.serialize(e.extractedUrl),r,i);this.events.next(o),e.resolve(!1)}isUpdatingInternalState(){return this.currentTransition?.extractedUrl.toString()!==this.currentTransition?.currentUrlTree.toString()}isUpdatedBrowserUrl(){let e=this.urlHandlingStrategy.extract(this.urlSerializer.parse(this.location.path(!0))),r=y(this.currentNavigation),i=r?.targetBrowserUrl??r?.extractedUrl;return e.toString()!==i?.toString()&&!r?.extras.skipLocationChange}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function yo(t){return t!==Oe}var Fn=new M("");var qn=(()=>{class t{static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:()=>h(Ro),providedIn:"root"})}return t})(),At=class{shouldDetach(n){return!1}store(n,e){}shouldAttach(n){return!1}retrieve(n){return null}shouldReuseRoute(n,e){return n.routeConfig===e.routeConfig}shouldDestroyInjector(n){return!0}},Ro=(()=>{class t extends At{static \u0275fac=(()=>{let e;return function(i){return(e||(e=Lt(t)))(i||t)}})();static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Tt=(()=>{class t{urlSerializer=h(ye);options=h(Se,{optional:!0})||{};canceledNavigationResolution=this.options.canceledNavigationResolution||"replace";location=h(rt);urlHandlingStrategy=h(Mt);urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred";currentUrlTree=new E;getCurrentUrlTree(){return this.currentUrlTree}rawUrlTree=this.currentUrlTree;getRawUrlTree(){return this.rawUrlTree}createBrowserPath({finalUrl:e,initialUrl:r,targetBrowserUrl:i}){let o=e!==void 0?this.urlHandlingStrategy.merge(e,r):r,s=i??o;return s instanceof E?this.urlSerializer.serialize(s):s}commitTransition({targetRouterState:e,finalUrl:r,initialUrl:i}){r&&e?(this.currentUrlTree=r,this.rawUrlTree=this.urlHandlingStrategy.merge(r,i),this.routerState=e):this.rawUrlTree=i}routerState=Rn(null,h(H));getRouterState(){return this.routerState}_stateMemento=this.createStateMemento();get stateMemento(){return this._stateMemento}updateStateMemento(){this._stateMemento=this.createStateMemento()}createStateMemento(){return{rawUrlTree:this.rawUrlTree,currentUrlTree:this.currentUrlTree,routerState:this.routerState}}restoredState(){return this.location.getState()}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:()=>h(Co),providedIn:"root"})}return t})(),Co=(()=>{class t extends Tt{currentPageId=0;lastSuccessfulId=-1;get browserPageId(){return this.canceledNavigationResolution!=="computed"?this.currentPageId:this.restoredState()?.\u0275routerPageId??this.currentPageId}registerNonRouterCurrentEntryChangeListener(e){return this.location.subscribe(r=>{r.type==="popstate"&&setTimeout(()=>{e(r.url,r.state,"popstate",{replaceUrl:!0})})})}handleRouterEvent(e,r){e instanceof ae?this.updateStateMemento():e instanceof V?this.commitTransition(r):e instanceof je?this.urlUpdateStrategy==="eager"&&(r.extras.skipLocationChange||this.setBrowserUrl(this.createBrowserPath(r),r)):e instanceof fe?(this.commitTransition(r),this.urlUpdateStrategy==="deferred"&&!r.extras.skipLocationChange&&this.setBrowserUrl(this.createBrowserPath(r),r)):e instanceof P&&!yn(e)?this.restoreHistory(r):e instanceof se?this.restoreHistory(r,!0):e instanceof L&&(this.lastSuccessfulId=e.id,this.currentPageId=this.browserPageId)}setBrowserUrl(e,{extras:r,id:i}){let{replaceUrl:o,state:s}=r;if(this.location.isCurrentPathEqualTo(e)||o){let a=this.browserPageId,c=l(l({},s),this.generateNgRouterState(i,a));this.location.replaceState(e,"",c)}else{let a=l(l({},s),this.generateNgRouterState(i,this.browserPageId+1));this.location.go(e,"",a)}}restoreHistory(e,r=!1){if(this.canceledNavigationResolution==="computed"){let i=this.browserPageId,o=this.currentPageId-i;o!==0?this.location.historyGo(o):this.getCurrentUrlTree()===e.finalUrl&&o===0&&(this.resetInternalState(e),this.resetUrlToCurrentUrlTree())}else this.canceledNavigationResolution==="replace"&&(r&&this.resetInternalState(e),this.resetUrlToCurrentUrlTree())}resetInternalState({finalUrl:e}){this.routerState=this.stateMemento.routerState,this.currentUrlTree=this.stateMemento.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,e??this.rawUrlTree)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.getRawUrlTree()),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(e,r){return this.canceledNavigationResolution==="computed"?{navigationId:e,\u0275routerPageId:r}:{navigationId:e}}static \u0275fac=(()=>{let e;return function(i){return(e||(e=Lt(t)))(i||t)}})();static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function fr(t,n){t.events.pipe(W(e=>e instanceof L||e instanceof P||e instanceof se||e instanceof V),A(e=>e instanceof L||e instanceof V?0:(e instanceof P?e.code===I.Redirect||e.code===I.SupersededByNewNavigation:!1)?2:1),W(e=>e!==2),ue(1)).subscribe(()=>{n()})}var X=(()=>{class t{get currentUrlTree(){return this.stateManager.getCurrentUrlTree()}get rawUrlTree(){return this.stateManager.getRawUrlTree()}disposed=!1;nonRouterCurrentEntryChangeSubscription;console=h(Or);stateManager=h(Tt);options=h(Se,{optional:!0})||{};pendingTasks=h(Er);urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred";navigationTransitions=h(zn);urlSerializer=h(ye);location=h(rt);urlHandlingStrategy=h(Mt);injector=h(H);_events=new re;get events(){return this._events}get routerState(){return this.stateManager.getRouterState()}navigated=!1;routeReuseStrategy=h(qn);injectorCleanup=h(Fn,{optional:!0});onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore";config=h(Ge,{optional:!0})?.flat()??[];componentInputBindingEnabled=!!h(Be,{optional:!0});currentNavigation=this.navigationTransitions.currentNavigation.asReadonly();constructor(){this.resetConfig(this.config),this.navigationTransitions.setupNavigations(this).subscribe({error:e=>{}}),this.subscribeToNavigationEvents()}eventsSubscription=new pr;subscribeToNavigationEvents(){let e=this.navigationTransitions.events.subscribe(r=>{try{let i=this.navigationTransitions.currentTransition,o=y(this.navigationTransitions.currentNavigation);if(i!==null&&o!==null){if(this.stateManager.handleRouterEvent(r,o),r instanceof P&&r.code!==I.Redirect&&r.code!==I.SupersededByNewNavigation)this.navigated=!0;else if(r instanceof L)this.navigated=!0,this.injectorCleanup?.(this.routeReuseStrategy,this.routerState,this.config);else if(r instanceof pe){let s=r.navigationBehaviorOptions,a=this.urlHandlingStrategy.merge(r.url,i.currentRawUrl),c=l({scroll:i.extras.scroll,browserUrl:i.extras.browserUrl,info:i.extras.info,skipLocationChange:i.extras.skipLocationChange,replaceUrl:i.extras.replaceUrl||this.urlUpdateStrategy==="eager"||yo(i.source)},s);this.scheduleNavigation(a,Oe,null,c,{resolve:i.resolve,reject:i.reject,promise:i.promise})}}Ri(r)&&this._events.next(r)}catch(i){this.navigationTransitions.transitionAbortWithErrorSubject.next(i)}});this.eventsSubscription.add(e)}resetRootComponentType(e){this.routerState.root.component=e,this.navigationTransitions.rootComponentType=e}initialNavigation(){this.setUpLocationChangeListener(),this.navigationTransitions.hasRequestedNavigation||this.navigateToSyncWithBrowser(this.location.path(!0),Oe,this.stateManager.restoredState(),{replaceUrl:!0})}setUpLocationChangeListener(){this.nonRouterCurrentEntryChangeSubscription??=this.stateManager.registerNonRouterCurrentEntryChangeListener((e,r,i,o)=>{this.navigateToSyncWithBrowser(e,i,r,o)})}navigateToSyncWithBrowser(e,r,i,o){let s=i?.navigationId?i:null;if(i){let c=l({},i);delete c.navigationId,delete c.\u0275routerPageId,Object.keys(c).length!==0&&(o.state=c)}let a=this.parseUrl(e);this.scheduleNavigation(a,r,s,o).catch(c=>{this.disposed||this.injector.get(Ze)(c)})}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return y(this.navigationTransitions.currentNavigation)}get lastSuccessfulNavigation(){return this.navigationTransitions.lastSuccessfulNavigation}resetConfig(e){this.config=e.map(lr),this.navigated=!1}ngOnDestroy(){this.dispose()}dispose(){this._events.unsubscribe(),this.navigationTransitions.complete(),this.nonRouterCurrentEntryChangeSubscription?.unsubscribe(),this.nonRouterCurrentEntryChangeSubscription=void 0,this.disposed=!0,this.eventsSubscription.unsubscribe()}createUrlTree(e,r={}){let{relativeTo:i,queryParams:o,fragment:s,queryParamsHandling:a,preserveFragment:c}=r,u=c?this.currentUrlTree.fragment:s,d=null;switch(a??this.options.defaultQueryParamsHandling){case"merge":d=l(l({},this.currentUrlTree.queryParams),o);break;case"preserve":d=this.currentUrlTree.queryParams;break;default:d=o||null}d!==null&&(d=this.removeEmptyProps(d));let p;try{let m=i?i.snapshot:this.routerState.snapshot.root;p=pn(m)}catch{(typeof e[0]!="string"||e[0][0]!=="/")&&(e=[]),p=this.currentUrlTree.root}return gn(p,e,d,u??null,this.urlSerializer)}navigateByUrl(e,r={skipLocationChange:!1}){let i=J(e)?e:this.parseUrl(e),o=this.urlHandlingStrategy.merge(i,this.rawUrlTree);return this.scheduleNavigation(o,Oe,null,r)}navigate(e,r={skipLocationChange:!1}){return So(e),this.navigateByUrl(this.createUrlTree(e,r),r)}serializeUrl(e){return this.urlSerializer.serialize(e)}parseUrl(e){try{return this.urlSerializer.parse(e)}catch{return this.console.warn(wr(4018,!1)),this.urlSerializer.parse("/")}}isActive(e,r){let i;if(r===!0?i=l({},nr):r===!1?i=l({},Pe):i=l(l({},Pe),r),J(e))return Bt(this.currentUrlTree,e,i);let o=this.parseUrl(e);return Bt(this.currentUrlTree,o,i)}removeEmptyProps(e){return Object.entries(e).reduce((r,[i,o])=>(o!=null&&(r[i]=o),r),{})}scheduleNavigation(e,r,i,o,s){if(this.disposed)return Promise.resolve(!1);let a,c,u;s?(a=s.resolve,c=s.reject,u=s.promise):u=new Promise((p,m)=>{a=p,c=m});let d=this.pendingTasks.add();return fr(this,()=>{queueMicrotask(()=>this.pendingTasks.remove(d))}),this.navigationTransitions.handleNavigationRequest({source:r,restoredState:i,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:e,extras:o,resolve:a,reject:c,promise:u,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),u.catch(Promise.reject.bind(Promise))}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function So(t){for(let n=0;n<t.length;n++)if(t[n]==null)throw new w(4008,!1)}var bo=(()=>{class t{router=h(X);stateManager=h(Tt);fragment=C("");queryParams=C({});path=C("");serializer=h(ye);constructor(){this.updateState(),this.router.events?.subscribe(e=>{e instanceof L&&this.updateState()})}updateState(){let{fragment:e,root:r,queryParams:i}=this.stateManager.getCurrentUrlTree();this.fragment.set(e),this.queryParams.set(i),this.path.set(this.serializer.serialize(new E(r)))}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Dt=(()=>{class t{router;route;tabIndexAttribute;renderer;el;locationStrategy;hrefAttributeValue=h(new Br("href"),{optional:!0});reactiveHref=Hr(()=>this.isAnchorElement?this.computeHref(this._urlTree()):this.hrefAttributeValue);get href(){return y(this.reactiveHref)}set href(e){this.reactiveHref.set(e)}set target(e){this._target.set(e)}get target(){return y(this._target)}_target=C(void 0);set queryParams(e){this._queryParams.set(e)}get queryParams(){return y(this._queryParams)}_queryParams=C(void 0,{equal:()=>!1});set fragment(e){this._fragment.set(e)}get fragment(){return y(this._fragment)}_fragment=C(void 0);set queryParamsHandling(e){this._queryParamsHandling.set(e)}get queryParamsHandling(){return y(this._queryParamsHandling)}_queryParamsHandling=C(void 0);set state(e){this._state.set(e)}get state(){return y(this._state)}_state=C(void 0,{equal:()=>!1});set info(e){this._info.set(e)}get info(){return y(this._info)}_info=C(void 0,{equal:()=>!1});set relativeTo(e){this._relativeTo.set(e)}get relativeTo(){return y(this._relativeTo)}_relativeTo=C(void 0);set preserveFragment(e){this._preserveFragment.set(e)}get preserveFragment(){return y(this._preserveFragment)}_preserveFragment=C(!1);set skipLocationChange(e){this._skipLocationChange.set(e)}get skipLocationChange(){return y(this._skipLocationChange)}_skipLocationChange=C(!1);set replaceUrl(e){this._replaceUrl.set(e)}get replaceUrl(){return y(this._replaceUrl)}_replaceUrl=C(!1);isAnchorElement;onChanges=new re;applicationErrorHandler=h(Ze);options=h(Se,{optional:!0});reactiveRouterState=h(bo);constructor(e,r,i,o,s,a){this.router=e,this.route=r,this.tabIndexAttribute=i,this.renderer=o,this.el=s,this.locationStrategy=a;let c=s.nativeElement.tagName?.toLowerCase();this.isAnchorElement=c==="a"||c==="area"||!!(typeof customElements=="object"&&customElements.get(c)?.observedAttributes?.includes?.("href"))}setTabIndexIfNotOnNativeEl(e){this.tabIndexAttribute!=null||this.isAnchorElement||this.applyAttributeValue("tabindex",e)}ngOnChanges(e){this.onChanges.next(this)}routerLinkInput=C(null);set routerLink(e){e==null?(this.routerLinkInput.set(null),this.setTabIndexIfNotOnNativeEl(null)):(J(e)?this.routerLinkInput.set(e):this.routerLinkInput.set(Array.isArray(e)?e:[e]),this.setTabIndexIfNotOnNativeEl("0"))}onClick(e,r,i,o,s){let a=this._urlTree();if(a===null||this.isAnchorElement&&(e!==0||r||i||o||s||typeof this.target=="string"&&this.target!="_self"))return!0;let c={skipLocationChange:this.skipLocationChange,replaceUrl:this.replaceUrl,state:this.state,info:this.info};return this.router.navigateByUrl(a,c)?.catch(u=>{this.applicationErrorHandler(u)}),!this.isAnchorElement}ngOnDestroy(){}applyAttributeValue(e,r){let i=this.renderer,o=this.el.nativeElement;r!==null?i.setAttribute(o,e,r):i.removeAttribute(o,e)}_urlTree=Xe(()=>{this.reactiveRouterState.path(),this._preserveFragment()&&this.reactiveRouterState.fragment();let e=i=>i==="preserve"||i==="merge";(e(this._queryParamsHandling())||e(this.options?.defaultQueryParamsHandling))&&this.reactiveRouterState.queryParams();let r=this.routerLinkInput();return r===null||!this.router.createUrlTree?null:J(r)?r:this.router.createUrlTree(r,{relativeTo:this._relativeTo()!==void 0?this._relativeTo():this.route,queryParams:this._queryParams(),fragment:this._fragment(),queryParamsHandling:this._queryParamsHandling(),preserveFragment:this._preserveFragment()})},{equal:(e,r)=>this.computeHref(e)===this.computeHref(r)});get urlTree(){return y(this._urlTree)}computeHref(e){return e!==null&&this.locationStrategy?this.locationStrategy?.prepareExternalUrl(this.router.serializeUrl(e))??"":null}static \u0275fac=function(r){return new(r||t)($(X),$(G),Mr("tabindex"),$(jt),$(xt),$(Wr))};static \u0275dir=Te({type:t,selectors:[["","routerLink",""]],hostVars:2,hostBindings:function(r,i){r&1&&kr("click",function(s){return i.onClick(s.button,s.ctrlKey,s.shiftKey,s.altKey,s.metaKey)}),r&2&&xr("href",i.reactiveHref(),Tr)("target",i._target())},inputs:{target:"target",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",state:"state",info:"info",relativeTo:"relativeTo",preserveFragment:[2,"preserveFragment","preserveFragment",tt],skipLocationChange:[2,"skipLocationChange","skipLocationChange",tt],replaceUrl:[2,"replaceUrl","replaceUrl",tt],routerLink:"routerLink"},features:[Me]})}return t})(),Io=(()=>{class t{router;element;renderer;cdr;links;classes=[];routerEventsSubscription;linkInputChangesSubscription;_isActive=!1;get isActive(){return this._isActive}routerLinkActiveOptions={exact:!1};ariaCurrentWhenActive;isActiveChange=new ne;link=h(Dt,{optional:!0});constructor(e,r,i,o){this.router=e,this.element=r,this.renderer=i,this.cdr=o,this.routerEventsSubscription=e.events.subscribe(s=>{s instanceof L&&this.update()})}ngAfterContentInit(){g(this.links.changes,g(null)).pipe(Ie()).subscribe(e=>{this.update(),this.subscribeToEachLinkOnChanges()})}subscribeToEachLinkOnChanges(){this.linkInputChangesSubscription?.unsubscribe();let e=[...this.links.toArray(),this.link].filter(r=>!!r).map(r=>r.onChanges);this.linkInputChangesSubscription=b(e).pipe(Ie()).subscribe(r=>{this._isActive!==this.isLinkActive(this.router)(r)&&this.update()})}set routerLinkActive(e){let r=Array.isArray(e)?e:e.split(" ");this.classes=r.filter(i=>!!i)}ngOnChanges(e){this.update()}ngOnDestroy(){this.routerEventsSubscription.unsubscribe(),this.linkInputChangesSubscription?.unsubscribe()}update(){!this.links||!this.router.navigated||queueMicrotask(()=>{let e=this.hasActiveLinks();this.classes.forEach(r=>{e?this.renderer.addClass(this.element.nativeElement,r):this.renderer.removeClass(this.element.nativeElement,r)}),e&&this.ariaCurrentWhenActive!==void 0?this.renderer.setAttribute(this.element.nativeElement,"aria-current",this.ariaCurrentWhenActive.toString()):this.renderer.removeAttribute(this.element.nativeElement,"aria-current"),this._isActive!==e&&(this._isActive=e,this.cdr.markForCheck(),this.isActiveChange.emit(e))})}isLinkActive(e){let r=Ao(this.routerLinkActiveOptions)?this.routerLinkActiveOptions:this.routerLinkActiveOptions.exact??!1?l({},nr):l({},Pe);return i=>{let o=i.urlTree;return o?y(ir(o,e,r)):!1}}hasActiveLinks(){let e=this.isLinkActive(this.router);return this.link&&e(this.link)||this.links.some(e)}static \u0275fac=function(r){return new(r||t)($(X),$(xt),$(jt),$(et))};static \u0275dir=Te({type:t,selectors:[["","routerLinkActive",""]],contentQueries:function(r,i,o){if(r&1&&$r(o,Dt,5),r&2){let s;zr(s=Fr())&&(i.links=s)}},inputs:{routerLinkActiveOptions:"routerLinkActiveOptions",ariaCurrentWhenActive:"ariaCurrentWhenActive",routerLinkActive:"routerLinkActive"},outputs:{isActiveChange:"isActiveChange"},exportAs:["routerLinkActive"],features:[Me]})}return t})();function Ao(t){let n=t;return!!(n.paths||n.matrixParams||n.queryParams||n.fragment)}var We=class{},Eo=(()=>{class t{preload(e,r){return r().pipe(Ae(()=>g(null)))}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var Hn=(()=>{class t{router;injector;preloadingStrategy;loader;subscription;constructor(e,r,i,o){this.router=e,this.injector=r,this.preloadingStrategy=i,this.loader=o}setUpPreloading(){this.subscription=this.router.events.pipe(W(e=>e instanceof L),Ee(()=>this.preload())).subscribe(()=>{})}preload(){return this.processRoutes(this.injector,this.router.config)}ngOnDestroy(){this.subscription?.unsubscribe()}processRoutes(e,r){let i=[];for(let o of r){o.providers&&!o._injector&&(o._injector=Je(o.providers,e,""));let s=o._injector??e;o._loadedNgModuleFactory&&!o._loadedInjector&&(o._loadedInjector=o._loadedNgModuleFactory.create(s).injector);let a=o._loadedInjector??s;(o.loadChildren&&!o._loadedRoutes&&o.canLoad===void 0||o.loadComponent&&!o._loadedComponent)&&i.push(this.preloadConfig(s,o)),(o.children||o._loadedRoutes)&&i.push(this.processRoutes(a,o.children??o._loadedRoutes))}return b(i).pipe(Ie())}preloadConfig(e,r){return this.preloadingStrategy.preload(r,()=>{if(e.destroyed)return g(null);let i;r.loadChildren&&r.canLoad===void 0?i=b(this.loader.loadChildren(e,r)):i=g(null);let o=i.pipe(k(s=>s===null?g(void 0):(r._loadedRoutes=s.routes,r._loadedInjector=s.injector,r._loadedNgModuleFactory=s.factory,this.processRoutes(s.injector??e,s.routes))));if(r.loadComponent&&!r._loadedComponent){let s=this.loader.loadComponent(e,r);return b([o,s]).pipe(Ie())}else return o})}static \u0275fac=function(r){return new(r||t)(K(X),K(H),K(We),K(hr))};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Mo=new M("");function To(t,...n){return Ir([{provide:Ge,multi:!0,useValue:t},[],{provide:G,useFactory:Do},{provide:Pr,multi:!0,useFactory:No},n.map(e=>e.\u0275providers)])}function Do(){return h(X).routerState.root}function Bn(t,n){return{\u0275kind:t,\u0275providers:n}}function No(){let t=h(Ar);return n=>{let e=t.get(Lr);if(n!==e.components[0])return;let r=t.get(X),i=t.get(_o);t.get(Oo)===1&&r.initialNavigation(),t.get(Vn,null,{optional:!0})?.setUpPreloading(),t.get(Mo,null,{optional:!0})?.init(),r.resetRootComponentType(e.componentTypes[0]),i.closed||(i.next(),i.complete(),i.unsubscribe())}}var _o=new M("",{factory:()=>new re}),Oo=new M("",{factory:()=>1});var Vn=new M("");function Uo(t){return Bn(0,[{provide:Vn,useExisting:Hn},{provide:We,useExisting:t}])}function Po(){return Bn(8,[cr,{provide:Be,useExisting:cr}])}export{L as a,G as b,sr as c,X as d,Dt as e,Io as f,Eo as g,To as h,Uo as i,Po as j};
1
+ import{b as Qr}from"./chunk-L2QOWZDR.js";import{b as Wr,g as rt}from"./chunk-BDQJFOCO.js";import{$ as Ir,$a as $,A as Ae,B as Ee,D as ue,F as Cr,Fb as jr,G as Q,H as Ut,K as Sr,L as x,Lc as qr,M as Ye,N as j,Qa as Tr,Qc as y,Rc as Xe,S as w,Sc as Hr,T as wr,V as R,Vc as Br,X as br,Xc as Vr,Y as M,Z as K,Zb as kr,_ as h,_a as jt,ad as et,ba as H,bb as Dr,ca as U,cc as $r,d as pr,db as Nr,dc as zr,e as gr,ec as Fr,ed as tt,f as vr,fb as Je,g as re,gb as _r,h as _,ha as Ar,hd as Gr,ib as Te,j as O,ja as Pt,k as b,ka as Er,l as g,la as ne,m as mr,n as _t,nb as Or,o as yr,oa as Ze,pa as C,pb as Ur,q as A,r as Ot,rb as Pr,s as k,sa as Me,sb as Lr,t as Ie,ta as Lt,u as Rr,ua as Mr,v as Ke,va as xt,vb as xr,y as W}from"./chunk-UH2E7MMT.js";import{a as l,b as N}from"./chunk-7CGTOI24.js";var f="primary",He=Symbol("RouteTitle"),qt=class{params;constructor(n){this.params=n||{}}has(n){return Object.prototype.hasOwnProperty.call(this.params,n)}get(n){if(this.has(n)){let e=this.params[n];return Array.isArray(e)?e[0]:e}return null}getAll(n){if(this.has(n)){let e=this.params[n];return Array.isArray(e)?e:[e]}return[]}get keys(){return Object.keys(this.params)}};function oe(t){return new qt(t)}function kt(t,n,e){for(let r=0;r<t.length;r++){let i=t[r],o=n[r];if(i[0]===":")e[i.substring(1)]=o;else if(i!==o.path)return!1}return!0}function tn(t,n,e){let r=e.path.split("/"),i=r.indexOf("**");if(i===-1){if(r.length>t.length||e.pathMatch==="full"&&(n.hasChildren()||r.length<t.length))return null;let c={},u=t.slice(0,r.length);return kt(r,u,c)?{consumed:u,posParams:c}:null}if(i!==r.lastIndexOf("**"))return null;let o=r.slice(0,i),s=r.slice(i+1);if(o.length+s.length>t.length||e.pathMatch==="full"&&n.hasChildren()&&e.path!=="**")return null;let a={};return!kt(o,t.slice(0,o.length),a)||!kt(s,t.slice(t.length-s.length),a)?null:{consumed:t,posParams:a}}function ct(t){return new Promise((n,e)=>{t.pipe(Q()).subscribe({next:r=>n(r),error:r=>e(r)})})}function Qn(t,n){if(t.length!==n.length)return!1;for(let e=0;e<t.length;++e)if(!z(t[e],n[e]))return!1;return!0}function z(t,n){let e=t?Ht(t):void 0,r=n?Ht(n):void 0;if(!e||!r||e.length!=r.length)return!1;let i;for(let o=0;o<e.length;o++)if(i=e[o],!rn(t[i],n[i]))return!1;return!0}function Ht(t){return[...Object.keys(t),...Object.getOwnPropertySymbols(t)]}function rn(t,n){if(Array.isArray(t)&&Array.isArray(n)){if(t.length!==n.length)return!1;let e=[...t].sort(),r=[...n].sort();return e.every((i,o)=>r[o]===i)}else return t===n}function Kn(t){return t.length>0?t[t.length-1]:null}function ce(t){return _t(t)?t:Ur(t)?b(Promise.resolve(t)):g(t)}function nn(t){return _t(t)?ct(t):Promise.resolve(t)}var Yn={exact:an,subset:sn},on={exact:Zn,subset:Jn,ignored:()=>!0},nr={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},Pe={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"};function ir(t,n,e){let r=t instanceof E?t:n.parseUrl(t);return Xe(()=>Bt(n.lastSuccessfulNavigation()?.finalUrl??new E,r,l(l({},Pe),e)))}function Bt(t,n,e){return Yn[e.paths](t.root,n.root,e.matrixParams)&&on[e.queryParams](t.queryParams,n.queryParams)&&!(e.fragment==="exact"&&t.fragment!==n.fragment)}function Zn(t,n){return z(t,n)}function an(t,n,e){if(!ie(t.segments,n.segments)||!ot(t.segments,n.segments,e)||t.numberOfChildren!==n.numberOfChildren)return!1;for(let r in n.children)if(!t.children[r]||!an(t.children[r],n.children[r],e))return!1;return!0}function Jn(t,n){return Object.keys(n).length<=Object.keys(t).length&&Object.keys(n).every(e=>rn(t[e],n[e]))}function sn(t,n,e){return cn(t,n,n.segments,e)}function cn(t,n,e,r){if(t.segments.length>e.length){let i=t.segments.slice(0,e.length);return!(!ie(i,e)||n.hasChildren()||!ot(i,e,r))}else if(t.segments.length===e.length){if(!ie(t.segments,e)||!ot(t.segments,e,r))return!1;for(let i in n.children)if(!t.children[i]||!sn(t.children[i],n.children[i],r))return!1;return!0}else{let i=e.slice(0,t.segments.length),o=e.slice(t.segments.length);return!ie(t.segments,i)||!ot(t.segments,i,r)||!t.children[f]?!1:cn(t.children[f],n,o,r)}}function ot(t,n,e){return n.every((r,i)=>on[e](t[i].parameters,r.parameters))}var E=class{root;queryParams;fragment;_queryParamMap;constructor(n=new v([],{}),e={},r=null){this.root=n,this.queryParams=e,this.fragment=r}get queryParamMap(){return this._queryParamMap??=oe(this.queryParams),this._queryParamMap}toString(){return ti.serialize(this)}},v=class{segments;children;parent=null;constructor(n,e){this.segments=n,this.children=e,Object.values(e).forEach(r=>r.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return at(this)}},Y=class{path;parameters;_parameterMap;constructor(n,e){this.path=n,this.parameters=e}get parameterMap(){return this._parameterMap??=oe(this.parameters),this._parameterMap}toString(){return ln(this)}};function Xn(t,n){return ie(t,n)&&t.every((e,r)=>z(e.parameters,n[r].parameters))}function ie(t,n){return t.length!==n.length?!1:t.every((e,r)=>e.path===n[r].path)}function ei(t,n){let e=[];return Object.entries(t.children).forEach(([r,i])=>{r===f&&(e=e.concat(n(i,r)))}),Object.entries(t.children).forEach(([r,i])=>{r!==f&&(e=e.concat(n(i,r)))}),e}var ye=(()=>{class t{static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:()=>new Z,providedIn:"root"})}return t})(),Z=class{parse(n){let e=new Gt(n);return new E(e.parseRootSegment(),e.parseQueryParams(),e.parseFragment())}serialize(n){let e=`/${De(n.root,!0)}`,r=ii(n.queryParams),i=typeof n.fragment=="string"?`#${ri(n.fragment)}`:"";return`${e}${r}${i}`}},ti=new Z;function at(t){return t.segments.map(n=>ln(n)).join("/")}function De(t,n){if(!t.hasChildren())return at(t);if(n){let e=t.children[f]?De(t.children[f],!1):"",r=[];return Object.entries(t.children).forEach(([i,o])=>{i!==f&&r.push(`${i}:${De(o,!1)}`)}),r.length>0?`${e}(${r.join("//")})`:e}else{let e=ei(t,(r,i)=>i===f?[De(t.children[f],!1)]:[`${i}:${De(r,!1)}`]);return Object.keys(t.children).length===1&&t.children[f]!=null?`${at(t)}/${e[0]}`:`${at(t)}/(${e.join("//")})`}}function un(t){return encodeURIComponent(t).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function nt(t){return un(t).replace(/%3B/gi,";")}function ri(t){return encodeURI(t)}function Vt(t){return un(t).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function st(t){return decodeURIComponent(t)}function Kr(t){return st(t.replace(/\+/g,"%20"))}function ln(t){return`${Vt(t.path)}${ni(t.parameters)}`}function ni(t){return Object.entries(t).map(([n,e])=>`;${Vt(n)}=${Vt(e)}`).join("")}function ii(t){let n=Object.entries(t).map(([e,r])=>Array.isArray(r)?r.map(i=>`${nt(e)}=${nt(i)}`).join("&"):`${nt(e)}=${nt(r)}`).filter(e=>e);return n.length?`?${n.join("&")}`:""}var oi=/^[^\/()?;#]+/;function $t(t){let n=t.match(oi);return n?n[0]:""}var ai=/^[^\/()?;=#]+/;function si(t){let n=t.match(ai);return n?n[0]:""}var ci=/^[^=?&#]+/;function ui(t){let n=t.match(ci);return n?n[0]:""}var li=/^[^&#]+/;function di(t){let n=t.match(li);return n?n[0]:""}var Gt=class{url;remaining;constructor(n){this.url=n,this.remaining=n}parseRootSegment(){return this.consumeOptional("/"),this.remaining===""||this.peekStartsWith("?")||this.peekStartsWith("#")?new v([],{}):new v([],this.parseChildren())}parseQueryParams(){let n={};if(this.consumeOptional("?"))do this.parseQueryParam(n);while(this.consumeOptional("&"));return n}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(n=0){if(n>50)throw new w(4010,!1);if(this.remaining==="")return{};this.consumeOptional("/");let e=[];for(this.peekStartsWith("(")||e.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),e.push(this.parseSegment());let r={};this.peekStartsWith("/(")&&(this.capture("/"),r=this.parseParens(!0,n));let i={};return this.peekStartsWith("(")&&(i=this.parseParens(!1,n)),(e.length>0||Object.keys(r).length>0)&&(i[f]=new v(e,r)),i}parseSegment(){let n=$t(this.remaining);if(n===""&&this.peekStartsWith(";"))throw new w(4009,!1);return this.capture(n),new Y(st(n),this.parseMatrixParams())}parseMatrixParams(){let n={};for(;this.consumeOptional(";");)this.parseParam(n);return n}parseParam(n){let e=si(this.remaining);if(!e)return;this.capture(e);let r="";if(this.consumeOptional("=")){let i=$t(this.remaining);i&&(r=i,this.capture(r))}n[st(e)]=st(r)}parseQueryParam(n){let e=ui(this.remaining);if(!e)return;this.capture(e);let r="";if(this.consumeOptional("=")){let s=di(this.remaining);s&&(r=s,this.capture(r))}let i=Kr(e),o=Kr(r);if(n.hasOwnProperty(i)){let s=n[i];Array.isArray(s)||(s=[s],n[i]=s),s.push(o)}else n[i]=o}parseParens(n,e){let r={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){let i=$t(this.remaining),o=this.remaining[i.length];if(o!=="/"&&o!==")"&&o!==";")throw new w(4010,!1);let s;i.indexOf(":")>-1?(s=i.slice(0,i.indexOf(":")),this.capture(s),this.capture(":")):n&&(s=f);let a=this.parseChildren(e+1);r[s??f]=Object.keys(a).length===1&&a[f]?a[f]:new v([],a),this.consumeOptional("//")}return r}peekStartsWith(n){return this.remaining.startsWith(n)}consumeOptional(n){return this.peekStartsWith(n)?(this.remaining=this.remaining.substring(n.length),!0):!1}capture(n){if(!this.consumeOptional(n))throw new w(4011,!1)}};function dn(t){return t.segments.length>0?new v([],{[f]:t}):t}function hn(t){let n={};for(let[r,i]of Object.entries(t.children)){let o=hn(i);if(r===f&&o.segments.length===0&&o.hasChildren())for(let[s,a]of Object.entries(o.children))n[s]=a;else(o.segments.length>0||o.hasChildren())&&(n[r]=o)}let e=new v(t.segments,n);return hi(e)}function hi(t){if(t.numberOfChildren===1&&t.children[f]){let n=t.children[f];return new v(t.segments.concat(n.segments),n.children)}return t}function J(t){return t instanceof E}function fn(t,n,e=null,r=null,i=new Z){let o=pn(t);return gn(o,n,e,r,i)}function pn(t){let n;function e(o){let s={};for(let c of o.children){let u=e(c);s[c.outlet]=u}let a=new v(o.url,s);return o===t&&(n=a),a}let r=e(t.root),i=dn(r);return n??i}function gn(t,n,e,r,i){let o=t;for(;o.parent;)o=o.parent;if(n.length===0)return zt(o,o,o,e,r,i);let s=fi(n);if(s.toRoot())return zt(o,o,new v([],{}),e,r,i);let a=pi(s,o,t),c=a.processChildren?_e(a.segmentGroup,a.index,s.commands):mn(a.segmentGroup,a.index,s.commands);return zt(o,a.segmentGroup,c,e,r,i)}function ut(t){return typeof t=="object"&&t!=null&&!t.outlets&&!t.segmentPath}function Le(t){return typeof t=="object"&&t!=null&&t.outlets}function Yr(t,n,e){t||="\u0275";let r=new E;return r.queryParams={[t]:n},e.parse(e.serialize(r)).queryParams[t]}function zt(t,n,e,r,i,o){let s={};for(let[u,d]of Object.entries(r??{}))s[u]=Array.isArray(d)?d.map(p=>Yr(u,p,o)):Yr(u,d,o);let a;t===n?a=e:a=vn(t,n,e);let c=dn(hn(a));return new E(c,s,i)}function vn(t,n,e){let r={};return Object.entries(t.children).forEach(([i,o])=>{o===n?r[i]=e:r[i]=vn(o,n,e)}),new v(t.segments,r)}var lt=class{isAbsolute;numberOfDoubleDots;commands;constructor(n,e,r){if(this.isAbsolute=n,this.numberOfDoubleDots=e,this.commands=r,n&&r.length>0&&ut(r[0]))throw new w(4003,!1);let i=r.find(Le);if(i&&i!==Kn(r))throw new w(4004,!1)}toRoot(){return this.isAbsolute&&this.commands.length===1&&this.commands[0]=="/"}};function fi(t){if(typeof t[0]=="string"&&t.length===1&&t[0]==="/")return new lt(!0,0,t);let n=0,e=!1,r=t.reduce((i,o,s)=>{if(typeof o=="object"&&o!=null){if(o.outlets){let a={};return Object.entries(o.outlets).forEach(([c,u])=>{a[c]=typeof u=="string"?u.split("/"):u}),[...i,{outlets:a}]}if(o.segmentPath)return[...i,o.segmentPath]}return typeof o!="string"?[...i,o]:s===0?(o.split("/").forEach((a,c)=>{c==0&&a==="."||(c==0&&a===""?e=!0:a===".."?n++:a!=""&&i.push(a))}),i):[...i,o]},[]);return new lt(e,n,r)}var de=class{segmentGroup;processChildren;index;constructor(n,e,r){this.segmentGroup=n,this.processChildren=e,this.index=r}};function pi(t,n,e){if(t.isAbsolute)return new de(n,!0,0);if(!e)return new de(n,!1,NaN);if(e.parent===null)return new de(e,!0,0);let r=ut(t.commands[0])?0:1,i=e.segments.length-1+r;return gi(e,i,t.numberOfDoubleDots)}function gi(t,n,e){let r=t,i=n,o=e;for(;o>i;){if(o-=i,r=r.parent,!r)throw new w(4005,!1);i=r.segments.length}return new de(r,!1,i-o)}function vi(t){return Le(t[0])?t[0].outlets:{[f]:t}}function mn(t,n,e){if(t??=new v([],{}),t.segments.length===0&&t.hasChildren())return _e(t,n,e);let r=mi(t,n,e),i=e.slice(r.commandIndex);if(r.match&&r.pathIndex<t.segments.length){let o=new v(t.segments.slice(0,r.pathIndex),{});return o.children[f]=new v(t.segments.slice(r.pathIndex),t.children),_e(o,0,i)}else return r.match&&i.length===0?new v(t.segments,{}):r.match&&!t.hasChildren()?Wt(t,n,e):r.match?_e(t,0,i):Wt(t,n,e)}function _e(t,n,e){if(e.length===0)return new v(t.segments,{});{let r=vi(e),i={};if(Object.keys(r).some(o=>o!==f)&&t.children[f]&&t.numberOfChildren===1&&t.children[f].segments.length===0){let o=_e(t.children[f],n,e);return new v(t.segments,o.children)}return Object.entries(r).forEach(([o,s])=>{typeof s=="string"&&(s=[s]),s!==null&&(i[o]=mn(t.children[o],n,s))}),Object.entries(t.children).forEach(([o,s])=>{r[o]===void 0&&(i[o]=s)}),new v(t.segments,i)}}function mi(t,n,e){let r=0,i=n,o={match:!1,pathIndex:0,commandIndex:0};for(;i<t.segments.length;){if(r>=e.length)return o;let s=t.segments[i],a=e[r];if(Le(a))break;let c=`${a}`,u=r<e.length-1?e[r+1]:null;if(i>0&&c===void 0)break;if(c&&u&&typeof u=="object"&&u.outlets===void 0){if(!Jr(c,u,s))return o;r+=2}else{if(!Jr(c,{},s))return o;r++}i++}return{match:!0,pathIndex:i,commandIndex:r}}function Wt(t,n,e){let r=t.segments.slice(0,n),i=0;for(;i<e.length;){let o=e[i];if(Le(o)){let c=yi(o.outlets);return new v(r,c)}if(i===0&&ut(e[0])){let c=t.segments[n];r.push(new Y(c.path,Zr(e[0]))),i++;continue}let s=Le(o)?o.outlets[f]:`${o}`,a=i<e.length-1?e[i+1]:null;s&&a&&ut(a)?(r.push(new Y(s,Zr(a))),i+=2):(r.push(new Y(s,{})),i++)}return new v(r,{})}function yi(t){let n={};return Object.entries(t).forEach(([e,r])=>{typeof r=="string"&&(r=[r]),r!==null&&(n[e]=Wt(new v([],{}),0,r))}),n}function Zr(t){let n={};return Object.entries(t).forEach(([e,r])=>n[e]=`${r}`),n}function Jr(t,n,e){return t==e.path&&z(n,e.parameters)}var Oe="imperative",S=(function(t){return t[t.NavigationStart=0]="NavigationStart",t[t.NavigationEnd=1]="NavigationEnd",t[t.NavigationCancel=2]="NavigationCancel",t[t.NavigationError=3]="NavigationError",t[t.RoutesRecognized=4]="RoutesRecognized",t[t.ResolveStart=5]="ResolveStart",t[t.ResolveEnd=6]="ResolveEnd",t[t.GuardsCheckStart=7]="GuardsCheckStart",t[t.GuardsCheckEnd=8]="GuardsCheckEnd",t[t.RouteConfigLoadStart=9]="RouteConfigLoadStart",t[t.RouteConfigLoadEnd=10]="RouteConfigLoadEnd",t[t.ChildActivationStart=11]="ChildActivationStart",t[t.ChildActivationEnd=12]="ChildActivationEnd",t[t.ActivationStart=13]="ActivationStart",t[t.ActivationEnd=14]="ActivationEnd",t[t.Scroll=15]="Scroll",t[t.NavigationSkipped=16]="NavigationSkipped",t})(S||{}),D=class{id;url;constructor(n,e){this.id=n,this.url=e}},ae=class extends D{type=S.NavigationStart;navigationTrigger;restoredState;constructor(n,e,r="imperative",i=null){super(n,e),this.navigationTrigger=r,this.restoredState=i}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}},L=class extends D{urlAfterRedirects;type=S.NavigationEnd;constructor(n,e,r){super(n,e),this.urlAfterRedirects=r}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}},I=(function(t){return t[t.Redirect=0]="Redirect",t[t.SupersededByNewNavigation=1]="SupersededByNewNavigation",t[t.NoDataFromResolver=2]="NoDataFromResolver",t[t.GuardRejected=3]="GuardRejected",t[t.Aborted=4]="Aborted",t})(I||{}),xe=(function(t){return t[t.IgnoredSameUrlNavigation=0]="IgnoredSameUrlNavigation",t[t.IgnoredByUrlHandlingStrategy=1]="IgnoredByUrlHandlingStrategy",t})(xe||{}),P=class extends D{reason;code;type=S.NavigationCancel;constructor(n,e,r,i){super(n,e),this.reason=r,this.code=i}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}};function yn(t){return t instanceof P&&(t.code===I.Redirect||t.code===I.SupersededByNewNavigation)}var V=class extends D{reason;code;type=S.NavigationSkipped;constructor(n,e,r,i){super(n,e),this.reason=r,this.code=i}},se=class extends D{error;target;type=S.NavigationError;constructor(n,e,r,i){super(n,e),this.error=r,this.target=i}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}},je=class extends D{urlAfterRedirects;state;type=S.RoutesRecognized;constructor(n,e,r,i){super(n,e),this.urlAfterRedirects=r,this.state=i}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},dt=class extends D{urlAfterRedirects;state;type=S.GuardsCheckStart;constructor(n,e,r,i){super(n,e),this.urlAfterRedirects=r,this.state=i}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},ht=class extends D{urlAfterRedirects;state;shouldActivate;type=S.GuardsCheckEnd;constructor(n,e,r,i,o){super(n,e),this.urlAfterRedirects=r,this.state=i,this.shouldActivate=o}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}},ft=class extends D{urlAfterRedirects;state;type=S.ResolveStart;constructor(n,e,r,i){super(n,e),this.urlAfterRedirects=r,this.state=i}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},pt=class extends D{urlAfterRedirects;state;type=S.ResolveEnd;constructor(n,e,r,i){super(n,e),this.urlAfterRedirects=r,this.state=i}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},gt=class{route;type=S.RouteConfigLoadStart;constructor(n){this.route=n}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}},vt=class{route;type=S.RouteConfigLoadEnd;constructor(n){this.route=n}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}},mt=class{snapshot;type=S.ChildActivationStart;constructor(n){this.snapshot=n}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},yt=class{snapshot;type=S.ChildActivationEnd;constructor(n){this.snapshot=n}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Rt=class{snapshot;type=S.ActivationStart;constructor(n){this.snapshot=n}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Ct=class{snapshot;type=S.ActivationEnd;constructor(n){this.snapshot=n}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}};var fe=class{},ke=class{},pe=class{url;navigationBehaviorOptions;constructor(n,e){this.url=n,this.navigationBehaviorOptions=e}};function Ri(t){return!(t instanceof fe)&&!(t instanceof pe)&&!(t instanceof ke)}var St=class{rootInjector;outlet=null;route=null;children;attachRef=null;get injector(){return this.route?.snapshot._environmentInjector??this.rootInjector}constructor(n){this.rootInjector=n,this.children=new Re(this.rootInjector)}},Re=(()=>{class t{rootInjector;contexts=new Map;constructor(e){this.rootInjector=e}onChildOutletCreated(e,r){let i=this.getOrCreateContext(e);i.outlet=r,this.contexts.set(e,i)}onChildOutletDestroyed(e){let r=this.getContext(e);r&&(r.outlet=null,r.attachRef=null)}onOutletDeactivated(){let e=this.contexts;return this.contexts=new Map,e}onOutletReAttached(e){this.contexts=e}getOrCreateContext(e){let r=this.getContext(e);return r||(r=new St(this.rootInjector),this.contexts.set(e,r)),r}getContext(e){return this.contexts.get(e)||null}static \u0275fac=function(r){return new(r||t)(K(H))};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),wt=class{_root;constructor(n){this._root=n}get root(){return this._root.value}parent(n){let e=this.pathFromRoot(n);return e.length>1?e[e.length-2]:null}children(n){let e=Qt(n,this._root);return e?e.children.map(r=>r.value):[]}firstChild(n){let e=Qt(n,this._root);return e&&e.children.length>0?e.children[0].value:null}siblings(n){let e=Kt(n,this._root);return e.length<2?[]:e[e.length-2].children.map(i=>i.value).filter(i=>i!==n)}pathFromRoot(n){return Kt(n,this._root).map(e=>e.value)}};function Qt(t,n){if(t===n.value)return n;for(let e of n.children){let r=Qt(t,e);if(r)return r}return null}function Kt(t,n){if(t===n.value)return[n];for(let e of n.children){let r=Kt(t,e);if(r.length)return r.unshift(n),r}return[]}var T=class{value;children;constructor(n,e){this.value=n,this.children=e}toString(){return`TreeNode(${this.value})`}};function le(t){let n={};return t&&t.children.forEach(e=>n[e.value.outlet]=e),n}var $e=class extends wt{snapshot;constructor(n,e){super(n),this.snapshot=e,ar(this,n)}toString(){return this.snapshot.toString()}};function Rn(t,n){let e=Ci(t,n),r=new _([new Y("",{})]),i=new _({}),o=new _({}),s=new _({}),a=new _(""),c=new G(r,i,s,a,o,f,t,e.root);return c.snapshot=e.root,new $e(new T(c,[]),e)}function Ci(t,n){let e={},r={},i={},s=new ge([],e,i,"",r,f,t,null,{},n);return new ze("",new T(s,[]))}var G=class{urlSubject;paramsSubject;queryParamsSubject;fragmentSubject;dataSubject;outlet;component;snapshot;_futureSnapshot;_routerState;_paramMap;_queryParamMap;title;url;params;queryParams;fragment;data;constructor(n,e,r,i,o,s,a,c){this.urlSubject=n,this.paramsSubject=e,this.queryParamsSubject=r,this.fragmentSubject=i,this.dataSubject=o,this.outlet=s,this.component=a,this._futureSnapshot=c,this.title=this.dataSubject?.pipe(A(u=>u[He]))??g(void 0),this.url=n,this.params=e,this.queryParams=r,this.fragment=i,this.data=o}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=this.params.pipe(A(n=>oe(n))),this._paramMap}get queryParamMap(){return this._queryParamMap??=this.queryParams.pipe(A(n=>oe(n))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}};function or(t,n,e="emptyOnly"){let r,{routeConfig:i}=t;return n!==null&&(e==="always"||i?.path===""||!n.component&&!n.routeConfig?.loadComponent)?r={params:l(l({},n.params),t.params),data:l(l({},n.data),t.data),resolve:l(l(l(l({},t.data),n.data),i?.data),t._resolvedData)}:r={params:l({},t.params),data:l({},t.data),resolve:l(l({},t.data),t._resolvedData??{})},i&&Sn(i)&&(r.resolve[He]=i.title),r}var ge=class{url;params;queryParams;fragment;data;outlet;component;routeConfig;_resolve;_resolvedData;_routerState;_paramMap;_queryParamMap;_environmentInjector;get title(){return this.data?.[He]}constructor(n,e,r,i,o,s,a,c,u,d){this.url=n,this.params=e,this.queryParams=r,this.fragment=i,this.data=o,this.outlet=s,this.component=a,this.routeConfig=c,this._resolve=u,this._environmentInjector=d}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=oe(this.params),this._paramMap}get queryParamMap(){return this._queryParamMap??=oe(this.queryParams),this._queryParamMap}toString(){let n=this.url.map(r=>r.toString()).join("/"),e=this.routeConfig?this.routeConfig.path:"";return`Route(url:'${n}', path:'${e}')`}},ze=class extends wt{url;constructor(n,e){super(e),this.url=n,ar(this,e)}toString(){return Cn(this._root)}};function ar(t,n){n.value._routerState=t,n.children.forEach(e=>ar(t,e))}function Cn(t){let n=t.children.length>0?` { ${t.children.map(Cn).join(", ")} } `:"";return`${t.value}${n}`}function Ft(t){if(t.snapshot){let n=t.snapshot,e=t._futureSnapshot;t.snapshot=e,z(n.queryParams,e.queryParams)||t.queryParamsSubject.next(e.queryParams),n.fragment!==e.fragment&&t.fragmentSubject.next(e.fragment),z(n.params,e.params)||t.paramsSubject.next(e.params),Qn(n.url,e.url)||t.urlSubject.next(e.url),z(n.data,e.data)||t.dataSubject.next(e.data)}else t.snapshot=t._futureSnapshot,t.dataSubject.next(t._futureSnapshot.data)}function Yt(t,n){let e=z(t.params,n.params)&&Xn(t.url,n.url),r=!t.parent!=!n.parent;return e&&!r&&(!t.parent||Yt(t.parent,n.parent))}function Sn(t){return typeof t.title=="string"||t.title===null}var wn=new M(""),sr=(()=>{class t{activated=null;get activatedComponentRef(){return this.activated}_activatedRoute=null;name=f;activateEvents=new ne;deactivateEvents=new ne;attachEvents=new ne;detachEvents=new ne;routerOutletData=Vr();parentContexts=h(Re);location=h(Dr);changeDetector=h(et);inputBinder=h(Be,{optional:!0});supportsBindingToComponentInputs=!0;ngOnChanges(e){if(e.name){let{firstChange:r,previousValue:i}=e.name;if(r)return;this.isTrackedInParentContexts(i)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(i)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name),this.inputBinder?.unsubscribeFromRouteData(this)}isTrackedInParentContexts(e){return this.parentContexts.getContext(e)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;let e=this.parentContexts.getContext(this.name);e?.route&&(e.attachRef?this.attach(e.attachRef,e.route):this.activateWith(e.route,e.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new w(4012,!1);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new w(4012,!1);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new w(4012,!1);this.location.detach();let e=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(e.instance),e}attach(e,r){this.activated=e,this._activatedRoute=r,this.location.insert(e.hostView),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.attachEvents.emit(e.instance)}deactivate(){if(this.activated){let e=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(e)}}activateWith(e,r){if(this.isActivated)throw new w(4013,!1);this._activatedRoute=e;let i=this.location,s=e.snapshot.component,a=this.parentContexts.getOrCreateContext(this.name).children,c=new Zt(e,a,i.injector,this.routerOutletData);this.activated=i.createComponent(s,{index:i.length,injector:c,environmentInjector:r}),this.changeDetector.markForCheck(),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.activateEvents.emit(this.activated.instance)}static \u0275fac=function(r){return new(r||t)};static \u0275dir=Te({type:t,selectors:[["router-outlet"]],inputs:{name:"name",routerOutletData:[1,"routerOutletData"]},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],features:[Me]})}return t})(),Zt=class{route;childContexts;parent;outletData;constructor(n,e,r,i){this.route=n,this.childContexts=e,this.parent=r,this.outletData=i}get(n,e){return n===G?this.route:n===Re?this.childContexts:n===wn?this.outletData:this.parent.get(n,e)}},Be=new M(""),cr=(()=>{class t{outletDataSubscriptions=new Map;bindActivatedRouteToOutletComponent(e){this.unsubscribeFromRouteData(e),this.subscribeToRouteData(e)}unsubscribeFromRouteData(e){this.outletDataSubscriptions.get(e)?.unsubscribe(),this.outletDataSubscriptions.delete(e)}subscribeToRouteData(e){let{activatedRoute:r}=e,i=Ot([r.queryParams,r.params,r.data]).pipe(x(([o,s,a],c)=>(a=l(l(l({},o),s),a),c===0?g(a):Promise.resolve(a)))).subscribe(o=>{if(!e.isActivated||!e.activatedComponentRef||e.activatedRoute!==r||r.component===null){this.unsubscribeFromRouteData(e);return}let s=Gr(r.component);if(!s){this.unsubscribeFromRouteData(e);return}for(let{templateName:a}of s.inputs)e.activatedComponentRef.setInput(a,o[a])});this.outletDataSubscriptions.set(e,i)}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac})}return t})(),ur=(()=>{class t{static \u0275fac=function(r){return new(r||t)};static \u0275cmp=_r({type:t,selectors:[["ng-component"]],exportAs:["emptyRouterOutlet"],decls:1,vars:0,template:function(r,i){r&1&&jr(0,"router-outlet")},dependencies:[sr],encapsulation:2})}return t})();function lr(t){let n=t.children&&t.children.map(lr),e=n?N(l({},t),{children:n}):l({},t);return!e.component&&!e.loadComponent&&(n||e.loadChildren)&&e.outlet&&e.outlet!==f&&(e.component=ur),e}function Si(t,n,e){let r=Fe(t,n._root,e?e._root:void 0);return new $e(r,n)}function Fe(t,n,e){if(e&&t.shouldReuseRoute(n.value,e.value.snapshot)){let r=e.value;r._futureSnapshot=n.value;let i=wi(t,n,e);return new T(r,i)}else{if(t.shouldAttach(n.value)){let o=t.retrieve(n.value);if(o!==null){let s=o.route;return s.value._futureSnapshot=n.value,s.children=n.children.map(a=>Fe(t,a)),s}}let r=bi(n.value),i=n.children.map(o=>Fe(t,o));return new T(r,i)}}function wi(t,n,e){return n.children.map(r=>{for(let i of e.children)if(t.shouldReuseRoute(r.value,i.value.snapshot))return Fe(t,r,i);return Fe(t,r)})}function bi(t){return new G(new _(t.url),new _(t.params),new _(t.queryParams),new _(t.fragment),new _(t.data),t.outlet,t.component,t)}var ve=class{redirectTo;navigationBehaviorOptions;constructor(n,e){this.redirectTo=n,this.navigationBehaviorOptions=e}},bn="ngNavigationCancelingError";function bt(t,n){let{redirectTo:e,navigationBehaviorOptions:r}=J(n)?{redirectTo:n,navigationBehaviorOptions:void 0}:n,i=In(!1,I.Redirect);return i.url=e,i.navigationBehaviorOptions=r,i}function In(t,n){let e=new Error(`NavigationCancelingError: ${t||""}`);return e[bn]=!0,e.cancellationCode=n,e}function Ii(t){return An(t)&&J(t.url)}function An(t){return!!t&&t[bn]}var Jt=class{routeReuseStrategy;futureState;currState;forwardEvent;inputBindingEnabled;constructor(n,e,r,i,o){this.routeReuseStrategy=n,this.futureState=e,this.currState=r,this.forwardEvent=i,this.inputBindingEnabled=o}activate(n){let e=this.futureState._root,r=this.currState?this.currState._root:null;this.deactivateChildRoutes(e,r,n),Ft(this.futureState.root),this.activateChildRoutes(e,r,n)}deactivateChildRoutes(n,e,r){let i=le(e);n.children.forEach(o=>{let s=o.value.outlet;this.deactivateRoutes(o,i[s],r),delete i[s]}),Object.values(i).forEach(o=>{this.deactivateRouteAndItsChildren(o,r)})}deactivateRoutes(n,e,r){let i=n.value,o=e?e.value:null;if(i===o)if(i.component){let s=r.getContext(i.outlet);s&&this.deactivateChildRoutes(n,e,s.children)}else this.deactivateChildRoutes(n,e,r);else o&&this.deactivateRouteAndItsChildren(e,r)}deactivateRouteAndItsChildren(n,e){n.value.component&&this.routeReuseStrategy.shouldDetach(n.value.snapshot)?this.detachAndStoreRouteSubtree(n,e):this.deactivateRouteAndOutlet(n,e)}detachAndStoreRouteSubtree(n,e){let r=e.getContext(n.value.outlet),i=r&&n.value.component?r.children:e,o=le(n);for(let s of Object.values(o))this.deactivateRouteAndItsChildren(s,i);if(r&&r.outlet){let s=r.outlet.detach(),a=r.children.onOutletDeactivated();this.routeReuseStrategy.store(n.value.snapshot,{componentRef:s,route:n,contexts:a})}}deactivateRouteAndOutlet(n,e){let r=e.getContext(n.value.outlet),i=r&&n.value.component?r.children:e,o=le(n);for(let s of Object.values(o))this.deactivateRouteAndItsChildren(s,i);r&&(r.outlet&&(r.outlet.deactivate(),r.children.onOutletDeactivated()),r.attachRef=null,r.route=null)}activateChildRoutes(n,e,r){let i=le(e);n.children.forEach(o=>{this.activateRoutes(o,i[o.value.outlet],r),this.forwardEvent(new Ct(o.value.snapshot))}),n.children.length&&this.forwardEvent(new yt(n.value.snapshot))}activateRoutes(n,e,r){let i=n.value,o=e?e.value:null;if(Ft(i),i===o)if(i.component){let s=r.getOrCreateContext(i.outlet);this.activateChildRoutes(n,e,s.children)}else this.activateChildRoutes(n,e,r);else if(i.component){let s=r.getOrCreateContext(i.outlet);if(this.routeReuseStrategy.shouldAttach(i.snapshot)){let a=this.routeReuseStrategy.retrieve(i.snapshot);this.routeReuseStrategy.store(i.snapshot,null),s.children.onOutletReAttached(a.contexts),s.attachRef=a.componentRef,s.route=a.route.value,s.outlet&&s.outlet.attach(a.componentRef,a.route.value),Ft(a.route.value),this.activateChildRoutes(n,null,s.children)}else s.attachRef=null,s.route=i,s.outlet&&s.outlet.activateWith(i,s.injector),this.activateChildRoutes(n,null,s.children)}else this.activateChildRoutes(n,null,r)}},It=class{path;route;constructor(n){this.path=n,this.route=this.path[this.path.length-1]}},he=class{component;route;constructor(n,e){this.component=n,this.route=e}};function Ai(t,n,e){let r=t._root,i=n?n._root:null;return Ne(r,i,e,[r.value])}function Ei(t){let n=t.routeConfig?t.routeConfig.canActivateChild:null;return!n||n.length===0?null:{node:t,guards:n}}function Ce(t,n){let e=Symbol(),r=n.get(t,e);return r===e?typeof t=="function"&&!br(t)?t:n.get(t):r}function Ne(t,n,e,r,i={canDeactivateChecks:[],canActivateChecks:[]}){let o=le(n);return t.children.forEach(s=>{Mi(s,o[s.value.outlet],e,r.concat([s.value]),i),delete o[s.value.outlet]}),Object.entries(o).forEach(([s,a])=>Ue(a,e.getContext(s),i)),i}function Mi(t,n,e,r,i={canDeactivateChecks:[],canActivateChecks:[]}){let o=t.value,s=n?n.value:null,a=e?e.getContext(t.value.outlet):null;if(s&&o.routeConfig===s.routeConfig){let c=Ti(s,o,o.routeConfig.runGuardsAndResolvers);c?i.canActivateChecks.push(new It(r)):(o.data=s.data,o._resolvedData=s._resolvedData),o.component?Ne(t,n,a?a.children:null,r,i):Ne(t,n,e,r,i),c&&a&&a.outlet&&a.outlet.isActivated&&i.canDeactivateChecks.push(new he(a.outlet.component,s))}else s&&Ue(n,a,i),i.canActivateChecks.push(new It(r)),o.component?Ne(t,null,a?a.children:null,r,i):Ne(t,null,e,r,i);return i}function Ti(t,n,e){if(typeof e=="function")return U(n._environmentInjector,()=>e(t,n));switch(e){case"pathParamsChange":return!ie(t.url,n.url);case"pathParamsOrQueryParamsChange":return!ie(t.url,n.url)||!z(t.queryParams,n.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!Yt(t,n)||!z(t.queryParams,n.queryParams);default:return!Yt(t,n)}}function Ue(t,n,e){let r=le(t),i=t.value;Object.entries(r).forEach(([o,s])=>{i.component?n?Ue(s,n.children.getContext(o),e):Ue(s,null,e):Ue(s,n,e)}),i.component?n&&n.outlet&&n.outlet.isActivated?e.canDeactivateChecks.push(new he(n.outlet.component,i)):e.canDeactivateChecks.push(new he(null,i)):e.canDeactivateChecks.push(new he(null,i))}function Ve(t){return typeof t=="function"}function Di(t){return typeof t=="boolean"}function Ni(t){return t&&Ve(t.canLoad)}function _i(t){return t&&Ve(t.canActivate)}function Oi(t){return t&&Ve(t.canActivateChild)}function Ui(t){return t&&Ve(t.canDeactivate)}function Pi(t){return t&&Ve(t.canMatch)}function En(t){return t instanceof yr||t?.name==="EmptyError"}var it=Symbol("INITIAL_VALUE");function me(){return x(t=>Ot(t.map(n=>n.pipe(ue(1),Sr(it)))).pipe(A(n=>{for(let e of n)if(e!==!0){if(e===it)return it;if(e===!1||Li(e))return e}return!0}),W(n=>n!==it),ue(1)))}function Li(t){return J(t)||t instanceof ve}function Mn(t){return t.aborted?g(void 0).pipe(ue(1)):new vr(n=>{let e=()=>{n.next(),n.complete()};return t.addEventListener("abort",e),()=>t.removeEventListener("abort",e)})}function Tn(t){return Ye(Mn(t))}function xi(t){return k(n=>{let{targetSnapshot:e,currentSnapshot:r,guards:{canActivateChecks:i,canDeactivateChecks:o}}=n;return o.length===0&&i.length===0?g(N(l({},n),{guardsResult:!0})):ji(o,e,r).pipe(k(s=>s&&Di(s)?ki(e,i,t):g(s)),A(s=>N(l({},n),{guardsResult:s})))})}function ji(t,n,e){return b(t).pipe(k(r=>Hi(r.component,r.route,e,n)),Q(r=>r!==!0,!0))}function ki(t,n,e){return b(n).pipe(Ee(r=>Rr(zi(r.route.parent,e),$i(r.route,e),qi(t,r.path),Fi(t,r.route))),Q(r=>r!==!0,!0))}function $i(t,n){return t!==null&&n&&n(new Rt(t)),g(!0)}function zi(t,n){return t!==null&&n&&n(new mt(t)),g(!0)}function Fi(t,n){let e=n.routeConfig?n.routeConfig.canActivate:null;if(!e||e.length===0)return g(!0);let r=e.map(i=>Ke(()=>{let o=n._environmentInjector,s=Ce(i,o),a=_i(s)?s.canActivate(n,t):U(o,()=>s(n,t));return ce(a).pipe(Q())}));return g(r).pipe(me())}function qi(t,n){let e=n[n.length-1],i=n.slice(0,n.length-1).reverse().map(o=>Ei(o)).filter(o=>o!==null).map(o=>Ke(()=>{let s=o.guards.map(a=>{let c=o.node._environmentInjector,u=Ce(a,c),d=Oi(u)?u.canActivateChild(e,t):U(c,()=>u(e,t));return ce(d).pipe(Q())});return g(s).pipe(me())}));return g(i).pipe(me())}function Hi(t,n,e,r){let i=n&&n.routeConfig?n.routeConfig.canDeactivate:null;if(!i||i.length===0)return g(!0);let o=i.map(s=>{let a=n._environmentInjector,c=Ce(s,a),u=Ui(c)?c.canDeactivate(t,n,e,r):U(a,()=>c(t,n,e,r));return ce(u).pipe(Q())});return g(o).pipe(me())}function Bi(t,n,e,r,i){let o=n.canLoad;if(o===void 0||o.length===0)return g(!0);let s=o.map(a=>{let c=Ce(a,t),u=Ni(c)?c.canLoad(n,e):U(t,()=>c(n,e)),d=ce(u);return i?d.pipe(Tn(i)):d});return g(s).pipe(me(),Dn(r))}function Dn(t){return gr(j(n=>{if(typeof n!="boolean")throw bt(t,n)}),A(n=>n===!0))}function Vi(t,n,e,r,i,o){let s=n.canMatch;if(!s||s.length===0)return g(!0);let a=s.map(c=>{let u=Ce(c,t),d=Pi(u)?u.canMatch(n,e,i):U(t,()=>u(n,e,i));return ce(d).pipe(Tn(o))});return g(a).pipe(me(),Dn(r))}var B=class t extends Error{segmentGroup;constructor(n){super(),this.segmentGroup=n||null,Object.setPrototypeOf(this,t.prototype)}},qe=class t extends Error{urlTree;constructor(n){super(),this.urlTree=n,Object.setPrototypeOf(this,t.prototype)}};function Gi(t){throw new w(4e3,!1)}function Wi(t){throw In(!1,I.GuardRejected)}var Xt=class{urlSerializer;urlTree;constructor(n,e){this.urlSerializer=n,this.urlTree=e}async lineralizeSegments(n,e){let r=[],i=e.root;for(;;){if(r=r.concat(i.segments),i.numberOfChildren===0)return r;if(i.numberOfChildren>1||!i.children[f])throw Gi(`${n.redirectTo}`);i=i.children[f]}}async applyRedirectCommands(n,e,r,i,o){let s=await Qi(e,i,o);if(s instanceof E)throw new qe(s);let a=this.applyRedirectCreateUrlTree(s,this.urlSerializer.parse(s),n,r);if(s[0]==="/")throw new qe(a);return a}applyRedirectCreateUrlTree(n,e,r,i){let o=this.createSegmentGroup(n,e.root,r,i);return new E(o,this.createQueryParams(e.queryParams,this.urlTree.queryParams),e.fragment)}createQueryParams(n,e){let r={};return Object.entries(n).forEach(([i,o])=>{if(typeof o=="string"&&o[0]===":"){let a=o.substring(1);r[i]=e[a]}else r[i]=o}),r}createSegmentGroup(n,e,r,i){let o=this.createSegments(n,e.segments,r,i),s={};return Object.entries(e.children).forEach(([a,c])=>{s[a]=this.createSegmentGroup(n,c,r,i)}),new v(o,s)}createSegments(n,e,r,i){return e.map(o=>o.path[0]===":"?this.findPosParam(n,o,i):this.findOrReturn(o,r))}findPosParam(n,e,r){let i=r[e.path.substring(1)];if(!i)throw new w(4001,!1);return i}findOrReturn(n,e){let r=0;for(let i of e){if(i.path===n.path)return e.splice(r),i;r++}return n}};function Qi(t,n,e){if(typeof t=="string")return Promise.resolve(t);let r=t;return ct(ce(U(e,()=>r(n))))}function Ki(t,n){return t.providers&&!t._injector&&(t._injector=Je(t.providers,n,`Route: ${t.path}`)),t._injector??n}function F(t){return t.outlet||f}function Yi(t,n){let e=t.filter(r=>F(r)===n);return e.push(...t.filter(r=>F(r)!==n)),e}var er={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function Nn(t){return{routeConfig:t.routeConfig,url:t.url,params:t.params,queryParams:t.queryParams,fragment:t.fragment,data:t.data,outlet:t.outlet,title:t.title,paramMap:t.paramMap,queryParamMap:t.queryParamMap}}function Zi(t,n,e,r,i,o,s){let a=_n(t,n,e);if(!a.matched)return g(a);let c=Nn(o(a));return r=Ki(n,r),Vi(r,n,e,i,c,s).pipe(A(u=>u===!0?a:l({},er)))}function _n(t,n,e){if(n.path==="")return n.pathMatch==="full"&&(t.hasChildren()||e.length>0)?l({},er):{matched:!0,consumedSegments:[],remainingSegments:e,parameters:{},positionalParamSegments:{}};let i=(n.matcher||tn)(e,t,n);if(!i)return l({},er);let o={};Object.entries(i.posParams??{}).forEach(([a,c])=>{o[a]=c.path});let s=i.consumed.length>0?l(l({},o),i.consumed[i.consumed.length-1].parameters):o;return{matched:!0,consumedSegments:i.consumed,remainingSegments:e.slice(i.consumed.length),parameters:s,positionalParamSegments:i.posParams??{}}}function Xr(t,n,e,r){return e.length>0&&eo(t,e,r)?{segmentGroup:new v(n,Xi(r,new v(e,t.children))),slicedSegments:[]}:e.length===0&&to(t,e,r)?{segmentGroup:new v(t.segments,Ji(t,e,r,t.children)),slicedSegments:e}:{segmentGroup:new v(t.segments,t.children),slicedSegments:e}}function Ji(t,n,e,r){let i={};for(let o of e)if(Et(t,n,o)&&!r[F(o)]){let s=new v([],{});i[F(o)]=s}return l(l({},r),i)}function Xi(t,n){let e={};e[f]=n;for(let r of t)if(r.path===""&&F(r)!==f){let i=new v([],{});e[F(r)]=i}return e}function eo(t,n,e){return e.some(r=>Et(t,n,r)&&F(r)!==f)}function to(t,n,e){return e.some(r=>Et(t,n,r))}function Et(t,n,e){return(t.hasChildren()||n.length>0)&&e.pathMatch==="full"?!1:e.path===""}function ro(t,n,e){return n.length===0&&!t.children[e]}var tr=class{};async function no(t,n,e,r,i,o,s="emptyOnly",a){return new rr(t,n,e,r,i,s,o,a).recognize()}var io=31,rr=class{injector;configLoader;rootComponentType;config;urlTree;paramsInheritanceStrategy;urlSerializer;abortSignal;applyRedirects;absoluteRedirectCount=0;allowRedirects=!0;constructor(n,e,r,i,o,s,a,c){this.injector=n,this.configLoader=e,this.rootComponentType=r,this.config=i,this.urlTree=o,this.paramsInheritanceStrategy=s,this.urlSerializer=a,this.abortSignal=c,this.applyRedirects=new Xt(this.urlSerializer,this.urlTree)}noMatchError(n){return new w(4002,`'${n.segmentGroup}'`)}async recognize(){let n=Xr(this.urlTree.root,[],[],this.config).segmentGroup,{children:e,rootSnapshot:r}=await this.match(n),i=new T(r,e),o=new ze("",i),s=fn(r,[],this.urlTree.queryParams,this.urlTree.fragment);return s.queryParams=this.urlTree.queryParams,o.url=this.urlSerializer.serialize(s),{state:o,tree:s}}async match(n){let e=new ge([],Object.freeze({}),Object.freeze(l({},this.urlTree.queryParams)),this.urlTree.fragment,Object.freeze({}),f,this.rootComponentType,null,{},this.injector);try{return{children:await this.processSegmentGroup(this.injector,this.config,n,f,e),rootSnapshot:e}}catch(r){if(r instanceof qe)return this.urlTree=r.urlTree,this.match(r.urlTree.root);throw r instanceof B?this.noMatchError(r):r}}async processSegmentGroup(n,e,r,i,o){if(r.segments.length===0&&r.hasChildren())return this.processChildren(n,e,r,o);let s=await this.processSegment(n,e,r,r.segments,i,!0,o);return s instanceof T?[s]:[]}async processChildren(n,e,r,i){let o=[];for(let c of Object.keys(r.children))c==="primary"?o.unshift(c):o.push(c);let s=[];for(let c of o){let u=r.children[c],d=Yi(e,c),p=await this.processSegmentGroup(n,d,u,c,i);s.push(...p)}let a=On(s);return oo(a),a}async processSegment(n,e,r,i,o,s,a){for(let c of e)try{return await this.processSegmentAgainstRoute(c._injector??n,e,c,r,i,o,s,a)}catch(u){if(u instanceof B||En(u))continue;throw u}if(ro(r,i,o))return new tr;throw new B(r)}async processSegmentAgainstRoute(n,e,r,i,o,s,a,c){if(F(r)!==s&&(s===f||!Et(i,o,r)))throw new B(i);if(r.redirectTo===void 0)return this.matchSegmentAgainstRoute(n,i,r,o,s,c);if(this.allowRedirects&&a)return this.expandSegmentAgainstRouteUsingRedirect(n,i,e,r,o,s,c);throw new B(i)}async expandSegmentAgainstRouteUsingRedirect(n,e,r,i,o,s,a){let{matched:c,parameters:u,consumedSegments:d,positionalParamSegments:p,remainingSegments:m}=_n(e,i,o);if(!c)throw new B(e);typeof i.redirectTo=="string"&&i.redirectTo[0]==="/"&&(this.absoluteRedirectCount++,this.absoluteRedirectCount>io&&(this.allowRedirects=!1));let ee=this.createSnapshot(n,i,o,u,a);if(this.abortSignal.aborted)throw new Error(this.abortSignal.reason);let q=await this.applyRedirects.applyRedirectCommands(d,i.redirectTo,p,Nn(ee),n),te=await this.applyRedirects.lineralizeSegments(i,q);return this.processSegment(n,r,e,te.concat(m),s,!1,a)}createSnapshot(n,e,r,i,o){let s=new ge(r,i,Object.freeze(l({},this.urlTree.queryParams)),this.urlTree.fragment,so(e),F(e),e.component??e._loadedComponent??null,e,co(e),n),a=or(s,o,this.paramsInheritanceStrategy);return s.params=Object.freeze(a.params),s.data=Object.freeze(a.data),s}async matchSegmentAgainstRoute(n,e,r,i,o,s){if(this.abortSignal.aborted)throw new Error(this.abortSignal.reason);let a=Qe=>this.createSnapshot(n,r,Qe.consumedSegments,Qe.parameters,s),c=await ct(Zi(e,r,i,n,this.urlSerializer,a,this.abortSignal));if(r.path==="**"&&(e.children={}),!c?.matched)throw new B(e);n=r._injector??n;let{routes:u}=await this.getChildConfig(n,r,i),d=r._loadedInjector??n,{parameters:p,consumedSegments:m,remainingSegments:ee}=c,q=this.createSnapshot(n,r,m,p,s),{segmentGroup:te,slicedSegments:we}=Xr(e,m,ee,u);if(we.length===0&&te.hasChildren()){let Qe=await this.processChildren(d,u,te,q);return new T(q,Qe)}if(u.length===0&&we.length===0)return new T(q,[]);let Nt=F(r)===o,be=await this.processSegment(d,u,te,we,Nt?f:o,!0,q);return new T(q,be instanceof T?[be]:[])}async getChildConfig(n,e,r){if(e.children)return{routes:e.children,injector:n};if(e.loadChildren){if(e._loadedRoutes!==void 0){let o=e._loadedNgModuleFactory;return o&&!e._loadedInjector&&(e._loadedInjector=o.create(n).injector),{routes:e._loadedRoutes,injector:e._loadedInjector}}if(this.abortSignal.aborted)throw new Error(this.abortSignal.reason);if(await ct(Bi(n,e,r,this.urlSerializer,this.abortSignal))){let o=await this.configLoader.loadChildren(n,e);return e._loadedRoutes=o.routes,e._loadedInjector=o.injector,e._loadedNgModuleFactory=o.factory,o}throw Wi(e)}return{routes:[],injector:n}}};function oo(t){t.sort((n,e)=>n.value.outlet===f?-1:e.value.outlet===f?1:n.value.outlet.localeCompare(e.value.outlet))}function ao(t){let n=t.value.routeConfig;return n&&n.path===""}function On(t){let n=[],e=new Set;for(let r of t){if(!ao(r)){n.push(r);continue}let i=n.find(o=>r.value.routeConfig===o.value.routeConfig);i!==void 0?(i.children.push(...r.children),e.add(i)):n.push(r)}for(let r of e){let i=On(r.children);n.push(new T(r.value,i))}return n.filter(r=>!e.has(r))}function so(t){return t.data||{}}function co(t){return t.resolve||{}}function uo(t,n,e,r,i,o,s){return k(async a=>{let{state:c,tree:u}=await no(t,n,e,r,a.extractedUrl,i,o,s);return N(l({},a),{targetSnapshot:c,urlAfterRedirects:u})})}function lo(t){return k(n=>{let{targetSnapshot:e,guards:{canActivateChecks:r}}=n;if(!r.length)return g(n);let i=new Set(r.map(a=>a.route)),o=new Set;for(let a of i)if(!o.has(a))for(let c of Un(a))o.add(c);let s=0;return b(o).pipe(Ee(a=>i.has(a)?ho(a,e,t):(a.data=or(a,a.parent,t).resolve,g(void 0))),j(()=>s++),Ut(1),k(a=>s===o.size?g(n):O))})}function Un(t){let n=t.children.map(e=>Un(e)).flat();return[t,...n]}function ho(t,n,e){let r=t.routeConfig,i=t._resolve;return r?.title!==void 0&&!Sn(r)&&(i[He]=r.title),Ke(()=>(t.data=or(t,t.parent,e).resolve,fo(i,t,n).pipe(A(o=>(t._resolvedData=o,t.data=l(l({},t.data),o),null)))))}function fo(t,n,e){let r=Ht(t);if(r.length===0)return g({});let i={};return b(r).pipe(k(o=>po(t[o],n,e).pipe(Q(),j(s=>{if(s instanceof ve)throw bt(new Z,s);i[o]=s}))),Ut(1),A(()=>i),Ae(o=>En(o)?O:mr(o)))}function po(t,n,e){let r=n._environmentInjector,i=Ce(t,r),o=i.resolve?i.resolve(n,e):U(r,()=>i(n,e));return ce(o)}function en(t){return x(n=>{let e=t(n);return e?b(e).pipe(A(()=>n)):g(n)})}var dr=(()=>{class t{buildTitle(e){let r,i=e.root;for(;i!==void 0;)r=this.getResolvedTitleForRoute(i)??r,i=i.children.find(o=>o.outlet===f);return r}getResolvedTitleForRoute(e){return e.data[He]}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:()=>h(Pn),providedIn:"root"})}return t})(),Pn=(()=>{class t extends dr{title;constructor(e){super(),this.title=e}updateTitle(e){let r=this.buildTitle(e);r!==void 0&&this.title.setTitle(r)}static \u0275fac=function(r){return new(r||t)(K(Qr))};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Se=new M("",{factory:()=>({})}),Ge=new M(""),hr=(()=>{class t{componentLoaders=new WeakMap;childrenLoaders=new WeakMap;onLoadStartListener;onLoadEndListener;compiler=h(qr);async loadComponent(e,r){if(this.componentLoaders.get(r))return this.componentLoaders.get(r);if(r._loadedComponent)return Promise.resolve(r._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(r);let i=(async()=>{try{let o=await nn(U(e,()=>r.loadComponent())),s=await jn(xn(o));return this.onLoadEndListener&&this.onLoadEndListener(r),r._loadedComponent=s,s}finally{this.componentLoaders.delete(r)}})();return this.componentLoaders.set(r,i),i}loadChildren(e,r){if(this.childrenLoaders.get(r))return this.childrenLoaders.get(r);if(r._loadedRoutes)return Promise.resolve({routes:r._loadedRoutes,injector:r._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(r);let i=(async()=>{try{let o=await Ln(r,this.compiler,e,this.onLoadEndListener);return r._loadedRoutes=o.routes,r._loadedInjector=o.injector,r._loadedNgModuleFactory=o.factory,o}finally{this.childrenLoaders.delete(r)}})();return this.childrenLoaders.set(r,i),i}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();async function Ln(t,n,e,r){let i=await nn(U(e,()=>t.loadChildren())),o=await jn(xn(i)),s;o instanceof Nr||Array.isArray(o)?s=o:s=await n.compileModuleAsync(o),r&&r(t);let a,c,u=!1,d;return Array.isArray(s)?(c=s,u=!0):(a=s.create(e).injector,d=s,c=a.get(Ge,[],{optional:!0,self:!0}).flat()),{routes:c.map(lr),injector:a,factory:d}}function go(t){return t&&typeof t=="object"&&"default"in t}function xn(t){return go(t)?t.default:t}async function jn(t){return t}var Mt=(()=>{class t{static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:()=>h(vo),providedIn:"root"})}return t})(),vo=(()=>{class t{shouldProcessUrl(e){return!0}extract(e){return e}merge(e,r){return e}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),kn=new M("");var mo=()=>{},$n=new M(""),zn=(()=>{class t{currentNavigation=C(null,{equal:()=>!1});currentTransition=null;lastSuccessfulNavigation=C(null);events=new re;transitionAbortWithErrorSubject=new re;configLoader=h(hr);environmentInjector=h(H);destroyRef=h(Pt);urlSerializer=h(ye);rootContexts=h(Re);location=h(rt);inputBindingEnabled=h(Be,{optional:!0})!==null;titleStrategy=h(dr);options=h(Se,{optional:!0})||{};paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly";urlHandlingStrategy=h(Mt);createViewTransition=h(kn,{optional:!0});navigationErrorHandler=h($n,{optional:!0});navigationId=0;get hasRequestedNavigation(){return this.navigationId!==0}transitions;afterPreactivation=()=>g(void 0);rootComponentType=null;destroyed=!1;constructor(){let e=i=>this.events.next(new gt(i)),r=i=>this.events.next(new vt(i));this.configLoader.onLoadEndListener=r,this.configLoader.onLoadStartListener=e,this.destroyRef.onDestroy(()=>{this.destroyed=!0})}complete(){this.transitions?.complete()}handleNavigationRequest(e){let r=++this.navigationId;y(()=>{this.transitions?.next(N(l({},e),{extractedUrl:this.urlHandlingStrategy.extract(e.rawUrl),targetSnapshot:null,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null,id:r,routesRecognizeHandler:{},beforeActivateHandler:{}}))})}setupNavigations(e){return this.transitions=new _(null),this.transitions.pipe(W(r=>r!==null),x(r=>{let i=!1,o=new AbortController,s=()=>!i&&this.currentTransition?.id===r.id;return g(r).pipe(x(a=>{if(this.navigationId>r.id)return this.cancelNavigationTransition(r,"",I.SupersededByNewNavigation),O;this.currentTransition=r;let c=this.lastSuccessfulNavigation();this.currentNavigation.set({id:a.id,initialUrl:a.rawUrl,extractedUrl:a.extractedUrl,targetBrowserUrl:typeof a.extras.browserUrl=="string"?this.urlSerializer.parse(a.extras.browserUrl):a.extras.browserUrl,trigger:a.source,extras:a.extras,previousNavigation:c?N(l({},c),{previousNavigation:null}):null,abort:()=>o.abort(),routesRecognizeHandler:a.routesRecognizeHandler,beforeActivateHandler:a.beforeActivateHandler});let u=!e.navigated||this.isUpdatingInternalState()||this.isUpdatedBrowserUrl(),d=a.extras.onSameUrlNavigation??e.onSameUrlNavigation;if(!u&&d!=="reload")return this.events.next(new V(a.id,this.urlSerializer.serialize(a.rawUrl),"",xe.IgnoredSameUrlNavigation)),a.resolve(!1),O;if(this.urlHandlingStrategy.shouldProcessUrl(a.rawUrl))return g(a).pipe(x(p=>(this.events.next(new ae(p.id,this.urlSerializer.serialize(p.extractedUrl),p.source,p.restoredState)),p.id!==this.navigationId?O:Promise.resolve(p))),uo(this.environmentInjector,this.configLoader,this.rootComponentType,e.config,this.urlSerializer,this.paramsInheritanceStrategy,o.signal),j(p=>{r.targetSnapshot=p.targetSnapshot,r.urlAfterRedirects=p.urlAfterRedirects,this.currentNavigation.update(m=>(m.finalUrl=p.urlAfterRedirects,m)),this.events.next(new ke)}),x(p=>b(r.routesRecognizeHandler.deferredHandle??g(void 0)).pipe(A(()=>p))),j(()=>{let p=new je(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot);this.events.next(p)}));if(u&&this.urlHandlingStrategy.shouldProcessUrl(a.currentRawUrl)){let{id:p,extractedUrl:m,source:ee,restoredState:q,extras:te}=a,we=new ae(p,this.urlSerializer.serialize(m),ee,q);this.events.next(we);let Nt=Rn(this.rootComponentType,this.environmentInjector).snapshot;return this.currentTransition=r=N(l({},a),{targetSnapshot:Nt,urlAfterRedirects:m,extras:N(l({},te),{skipLocationChange:!1,replaceUrl:!1})}),this.currentNavigation.update(be=>(be.finalUrl=m,be)),g(r)}else return this.events.next(new V(a.id,this.urlSerializer.serialize(a.extractedUrl),"",xe.IgnoredByUrlHandlingStrategy)),a.resolve(!1),O}),A(a=>{let c=new dt(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot);return this.events.next(c),this.currentTransition=r=N(l({},a),{guards:Ai(a.targetSnapshot,a.currentSnapshot,this.rootContexts)}),r}),xi(a=>this.events.next(a)),x(a=>{if(r.guardsResult=a.guardsResult,a.guardsResult&&typeof a.guardsResult!="boolean")throw bt(this.urlSerializer,a.guardsResult);let c=new ht(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot,!!a.guardsResult);if(this.events.next(c),!s())return O;if(!a.guardsResult)return this.cancelNavigationTransition(a,"",I.GuardRejected),O;if(a.guards.canActivateChecks.length===0)return g(a);let u=new ft(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot);if(this.events.next(u),!s())return O;let d=!1;return g(a).pipe(lo(this.paramsInheritanceStrategy),j({next:()=>{d=!0;let p=new pt(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot);this.events.next(p)},complete:()=>{d||this.cancelNavigationTransition(a,"",I.NoDataFromResolver)}}))}),en(a=>{let c=d=>{let p=[];if(d.routeConfig?._loadedComponent)d.component=d.routeConfig?._loadedComponent;else if(d.routeConfig?.loadComponent){let m=d._environmentInjector;p.push(this.configLoader.loadComponent(m,d.routeConfig).then(ee=>{d.component=ee}))}for(let m of d.children)p.push(...c(m));return p},u=c(a.targetSnapshot.root);return u.length===0?g(a):b(Promise.all(u).then(()=>a))}),en(()=>this.afterPreactivation()),x(()=>{let{currentSnapshot:a,targetSnapshot:c}=r,u=this.createViewTransition?.(this.environmentInjector,a.root,c.root);return u?b(u).pipe(A(()=>r)):g(r)}),ue(1),x(a=>{let c=Si(e.routeReuseStrategy,a.targetSnapshot,a.currentRouterState);this.currentTransition=r=a=N(l({},a),{targetRouterState:c}),this.currentNavigation.update(d=>(d.targetRouterState=c,d)),this.events.next(new fe);let u=r.beforeActivateHandler.deferredHandle;return u?b(u.then(()=>a)):g(a)}),j(a=>{new Jt(e.routeReuseStrategy,r.targetRouterState,r.currentRouterState,c=>this.events.next(c),this.inputBindingEnabled).activate(this.rootContexts),s()&&(i=!0,this.currentNavigation.update(c=>(c.abort=mo,c)),this.lastSuccessfulNavigation.set(y(this.currentNavigation)),this.events.next(new L(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects))),this.titleStrategy?.updateTitle(a.targetRouterState.snapshot),a.resolve(!0))}),Ye(Mn(o.signal).pipe(W(()=>!i&&!r.targetRouterState),j(()=>{this.cancelNavigationTransition(r,o.signal.reason+"",I.Aborted)}))),j({complete:()=>{i=!0}}),Ye(this.transitionAbortWithErrorSubject.pipe(j(a=>{throw a}))),Cr(()=>{o.abort(),i||this.cancelNavigationTransition(r,"",I.SupersededByNewNavigation),this.currentTransition?.id===r.id&&(this.currentNavigation.set(null),this.currentTransition=null)}),Ae(a=>{if(i=!0,this.destroyed)return r.resolve(!1),O;if(An(a))this.events.next(new P(r.id,this.urlSerializer.serialize(r.extractedUrl),a.message,a.cancellationCode)),Ii(a)?this.events.next(new pe(a.url,a.navigationBehaviorOptions)):r.resolve(!1);else{let c=new se(r.id,this.urlSerializer.serialize(r.extractedUrl),a,r.targetSnapshot??void 0);try{let u=U(this.environmentInjector,()=>this.navigationErrorHandler?.(c));if(u instanceof ve){let{message:d,cancellationCode:p}=bt(this.urlSerializer,u);this.events.next(new P(r.id,this.urlSerializer.serialize(r.extractedUrl),d,p)),this.events.next(new pe(u.redirectTo,u.navigationBehaviorOptions))}else throw this.events.next(c),a}catch(u){this.options.resolveNavigationPromiseOnError?r.resolve(!1):r.reject(u)}}return O}))}))}cancelNavigationTransition(e,r,i){let o=new P(e.id,this.urlSerializer.serialize(e.extractedUrl),r,i);this.events.next(o),e.resolve(!1)}isUpdatingInternalState(){return this.currentTransition?.extractedUrl.toString()!==this.currentTransition?.currentUrlTree.toString()}isUpdatedBrowserUrl(){let e=this.urlHandlingStrategy.extract(this.urlSerializer.parse(this.location.path(!0))),r=y(this.currentNavigation),i=r?.targetBrowserUrl??r?.extractedUrl;return e.toString()!==i?.toString()&&!r?.extras.skipLocationChange}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function yo(t){return t!==Oe}var Fn=new M("");var qn=(()=>{class t{static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:()=>h(Ro),providedIn:"root"})}return t})(),At=class{shouldDetach(n){return!1}store(n,e){}shouldAttach(n){return!1}retrieve(n){return null}shouldReuseRoute(n,e){return n.routeConfig===e.routeConfig}shouldDestroyInjector(n){return!0}},Ro=(()=>{class t extends At{static \u0275fac=(()=>{let e;return function(i){return(e||(e=Lt(t)))(i||t)}})();static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Tt=(()=>{class t{urlSerializer=h(ye);options=h(Se,{optional:!0})||{};canceledNavigationResolution=this.options.canceledNavigationResolution||"replace";location=h(rt);urlHandlingStrategy=h(Mt);urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred";currentUrlTree=new E;getCurrentUrlTree(){return this.currentUrlTree}rawUrlTree=this.currentUrlTree;getRawUrlTree(){return this.rawUrlTree}createBrowserPath({finalUrl:e,initialUrl:r,targetBrowserUrl:i}){let o=e!==void 0?this.urlHandlingStrategy.merge(e,r):r,s=i??o;return s instanceof E?this.urlSerializer.serialize(s):s}commitTransition({targetRouterState:e,finalUrl:r,initialUrl:i}){r&&e?(this.currentUrlTree=r,this.rawUrlTree=this.urlHandlingStrategy.merge(r,i),this.routerState=e):this.rawUrlTree=i}routerState=Rn(null,h(H));getRouterState(){return this.routerState}_stateMemento=this.createStateMemento();get stateMemento(){return this._stateMemento}updateStateMemento(){this._stateMemento=this.createStateMemento()}createStateMemento(){return{rawUrlTree:this.rawUrlTree,currentUrlTree:this.currentUrlTree,routerState:this.routerState}}restoredState(){return this.location.getState()}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:()=>h(Co),providedIn:"root"})}return t})(),Co=(()=>{class t extends Tt{currentPageId=0;lastSuccessfulId=-1;get browserPageId(){return this.canceledNavigationResolution!=="computed"?this.currentPageId:this.restoredState()?.\u0275routerPageId??this.currentPageId}registerNonRouterCurrentEntryChangeListener(e){return this.location.subscribe(r=>{r.type==="popstate"&&setTimeout(()=>{e(r.url,r.state,"popstate",{replaceUrl:!0})})})}handleRouterEvent(e,r){e instanceof ae?this.updateStateMemento():e instanceof V?this.commitTransition(r):e instanceof je?this.urlUpdateStrategy==="eager"&&(r.extras.skipLocationChange||this.setBrowserUrl(this.createBrowserPath(r),r)):e instanceof fe?(this.commitTransition(r),this.urlUpdateStrategy==="deferred"&&!r.extras.skipLocationChange&&this.setBrowserUrl(this.createBrowserPath(r),r)):e instanceof P&&!yn(e)?this.restoreHistory(r):e instanceof se?this.restoreHistory(r,!0):e instanceof L&&(this.lastSuccessfulId=e.id,this.currentPageId=this.browserPageId)}setBrowserUrl(e,{extras:r,id:i}){let{replaceUrl:o,state:s}=r;if(this.location.isCurrentPathEqualTo(e)||o){let a=this.browserPageId,c=l(l({},s),this.generateNgRouterState(i,a));this.location.replaceState(e,"",c)}else{let a=l(l({},s),this.generateNgRouterState(i,this.browserPageId+1));this.location.go(e,"",a)}}restoreHistory(e,r=!1){if(this.canceledNavigationResolution==="computed"){let i=this.browserPageId,o=this.currentPageId-i;o!==0?this.location.historyGo(o):this.getCurrentUrlTree()===e.finalUrl&&o===0&&(this.resetInternalState(e),this.resetUrlToCurrentUrlTree())}else this.canceledNavigationResolution==="replace"&&(r&&this.resetInternalState(e),this.resetUrlToCurrentUrlTree())}resetInternalState({finalUrl:e}){this.routerState=this.stateMemento.routerState,this.currentUrlTree=this.stateMemento.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,e??this.rawUrlTree)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.getRawUrlTree()),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(e,r){return this.canceledNavigationResolution==="computed"?{navigationId:e,\u0275routerPageId:r}:{navigationId:e}}static \u0275fac=(()=>{let e;return function(i){return(e||(e=Lt(t)))(i||t)}})();static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function fr(t,n){t.events.pipe(W(e=>e instanceof L||e instanceof P||e instanceof se||e instanceof V),A(e=>e instanceof L||e instanceof V?0:(e instanceof P?e.code===I.Redirect||e.code===I.SupersededByNewNavigation:!1)?2:1),W(e=>e!==2),ue(1)).subscribe(()=>{n()})}var X=(()=>{class t{get currentUrlTree(){return this.stateManager.getCurrentUrlTree()}get rawUrlTree(){return this.stateManager.getRawUrlTree()}disposed=!1;nonRouterCurrentEntryChangeSubscription;console=h(Or);stateManager=h(Tt);options=h(Se,{optional:!0})||{};pendingTasks=h(Er);urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred";navigationTransitions=h(zn);urlSerializer=h(ye);location=h(rt);urlHandlingStrategy=h(Mt);injector=h(H);_events=new re;get events(){return this._events}get routerState(){return this.stateManager.getRouterState()}navigated=!1;routeReuseStrategy=h(qn);injectorCleanup=h(Fn,{optional:!0});onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore";config=h(Ge,{optional:!0})?.flat()??[];componentInputBindingEnabled=!!h(Be,{optional:!0});currentNavigation=this.navigationTransitions.currentNavigation.asReadonly();constructor(){this.resetConfig(this.config),this.navigationTransitions.setupNavigations(this).subscribe({error:e=>{}}),this.subscribeToNavigationEvents()}eventsSubscription=new pr;subscribeToNavigationEvents(){let e=this.navigationTransitions.events.subscribe(r=>{try{let i=this.navigationTransitions.currentTransition,o=y(this.navigationTransitions.currentNavigation);if(i!==null&&o!==null){if(this.stateManager.handleRouterEvent(r,o),r instanceof P&&r.code!==I.Redirect&&r.code!==I.SupersededByNewNavigation)this.navigated=!0;else if(r instanceof L)this.navigated=!0,this.injectorCleanup?.(this.routeReuseStrategy,this.routerState,this.config);else if(r instanceof pe){let s=r.navigationBehaviorOptions,a=this.urlHandlingStrategy.merge(r.url,i.currentRawUrl),c=l({scroll:i.extras.scroll,browserUrl:i.extras.browserUrl,info:i.extras.info,skipLocationChange:i.extras.skipLocationChange,replaceUrl:i.extras.replaceUrl||this.urlUpdateStrategy==="eager"||yo(i.source)},s);this.scheduleNavigation(a,Oe,null,c,{resolve:i.resolve,reject:i.reject,promise:i.promise})}}Ri(r)&&this._events.next(r)}catch(i){this.navigationTransitions.transitionAbortWithErrorSubject.next(i)}});this.eventsSubscription.add(e)}resetRootComponentType(e){this.routerState.root.component=e,this.navigationTransitions.rootComponentType=e}initialNavigation(){this.setUpLocationChangeListener(),this.navigationTransitions.hasRequestedNavigation||this.navigateToSyncWithBrowser(this.location.path(!0),Oe,this.stateManager.restoredState(),{replaceUrl:!0})}setUpLocationChangeListener(){this.nonRouterCurrentEntryChangeSubscription??=this.stateManager.registerNonRouterCurrentEntryChangeListener((e,r,i,o)=>{this.navigateToSyncWithBrowser(e,i,r,o)})}navigateToSyncWithBrowser(e,r,i,o){let s=i?.navigationId?i:null;if(i){let c=l({},i);delete c.navigationId,delete c.\u0275routerPageId,Object.keys(c).length!==0&&(o.state=c)}let a=this.parseUrl(e);this.scheduleNavigation(a,r,s,o).catch(c=>{this.disposed||this.injector.get(Ze)(c)})}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return y(this.navigationTransitions.currentNavigation)}get lastSuccessfulNavigation(){return this.navigationTransitions.lastSuccessfulNavigation}resetConfig(e){this.config=e.map(lr),this.navigated=!1}ngOnDestroy(){this.dispose()}dispose(){this._events.unsubscribe(),this.navigationTransitions.complete(),this.nonRouterCurrentEntryChangeSubscription?.unsubscribe(),this.nonRouterCurrentEntryChangeSubscription=void 0,this.disposed=!0,this.eventsSubscription.unsubscribe()}createUrlTree(e,r={}){let{relativeTo:i,queryParams:o,fragment:s,queryParamsHandling:a,preserveFragment:c}=r,u=c?this.currentUrlTree.fragment:s,d=null;switch(a??this.options.defaultQueryParamsHandling){case"merge":d=l(l({},this.currentUrlTree.queryParams),o);break;case"preserve":d=this.currentUrlTree.queryParams;break;default:d=o||null}d!==null&&(d=this.removeEmptyProps(d));let p;try{let m=i?i.snapshot:this.routerState.snapshot.root;p=pn(m)}catch{(typeof e[0]!="string"||e[0][0]!=="/")&&(e=[]),p=this.currentUrlTree.root}return gn(p,e,d,u??null,this.urlSerializer)}navigateByUrl(e,r={skipLocationChange:!1}){let i=J(e)?e:this.parseUrl(e),o=this.urlHandlingStrategy.merge(i,this.rawUrlTree);return this.scheduleNavigation(o,Oe,null,r)}navigate(e,r={skipLocationChange:!1}){return So(e),this.navigateByUrl(this.createUrlTree(e,r),r)}serializeUrl(e){return this.urlSerializer.serialize(e)}parseUrl(e){try{return this.urlSerializer.parse(e)}catch{return this.console.warn(wr(4018,!1)),this.urlSerializer.parse("/")}}isActive(e,r){let i;if(r===!0?i=l({},nr):r===!1?i=l({},Pe):i=l(l({},Pe),r),J(e))return Bt(this.currentUrlTree,e,i);let o=this.parseUrl(e);return Bt(this.currentUrlTree,o,i)}removeEmptyProps(e){return Object.entries(e).reduce((r,[i,o])=>(o!=null&&(r[i]=o),r),{})}scheduleNavigation(e,r,i,o,s){if(this.disposed)return Promise.resolve(!1);let a,c,u;s?(a=s.resolve,c=s.reject,u=s.promise):u=new Promise((p,m)=>{a=p,c=m});let d=this.pendingTasks.add();return fr(this,()=>{queueMicrotask(()=>this.pendingTasks.remove(d))}),this.navigationTransitions.handleNavigationRequest({source:r,restoredState:i,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:e,extras:o,resolve:a,reject:c,promise:u,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),u.catch(Promise.reject.bind(Promise))}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();function So(t){for(let n=0;n<t.length;n++)if(t[n]==null)throw new w(4008,!1)}var bo=(()=>{class t{router=h(X);stateManager=h(Tt);fragment=C("");queryParams=C({});path=C("");serializer=h(ye);constructor(){this.updateState(),this.router.events?.subscribe(e=>{e instanceof L&&this.updateState()})}updateState(){let{fragment:e,root:r,queryParams:i}=this.stateManager.getCurrentUrlTree();this.fragment.set(e),this.queryParams.set(i),this.path.set(this.serializer.serialize(new E(r)))}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Dt=(()=>{class t{router;route;tabIndexAttribute;renderer;el;locationStrategy;hrefAttributeValue=h(new Br("href"),{optional:!0});reactiveHref=Hr(()=>this.isAnchorElement?this.computeHref(this._urlTree()):this.hrefAttributeValue);get href(){return y(this.reactiveHref)}set href(e){this.reactiveHref.set(e)}set target(e){this._target.set(e)}get target(){return y(this._target)}_target=C(void 0);set queryParams(e){this._queryParams.set(e)}get queryParams(){return y(this._queryParams)}_queryParams=C(void 0,{equal:()=>!1});set fragment(e){this._fragment.set(e)}get fragment(){return y(this._fragment)}_fragment=C(void 0);set queryParamsHandling(e){this._queryParamsHandling.set(e)}get queryParamsHandling(){return y(this._queryParamsHandling)}_queryParamsHandling=C(void 0);set state(e){this._state.set(e)}get state(){return y(this._state)}_state=C(void 0,{equal:()=>!1});set info(e){this._info.set(e)}get info(){return y(this._info)}_info=C(void 0,{equal:()=>!1});set relativeTo(e){this._relativeTo.set(e)}get relativeTo(){return y(this._relativeTo)}_relativeTo=C(void 0);set preserveFragment(e){this._preserveFragment.set(e)}get preserveFragment(){return y(this._preserveFragment)}_preserveFragment=C(!1);set skipLocationChange(e){this._skipLocationChange.set(e)}get skipLocationChange(){return y(this._skipLocationChange)}_skipLocationChange=C(!1);set replaceUrl(e){this._replaceUrl.set(e)}get replaceUrl(){return y(this._replaceUrl)}_replaceUrl=C(!1);isAnchorElement;onChanges=new re;applicationErrorHandler=h(Ze);options=h(Se,{optional:!0});reactiveRouterState=h(bo);constructor(e,r,i,o,s,a){this.router=e,this.route=r,this.tabIndexAttribute=i,this.renderer=o,this.el=s,this.locationStrategy=a;let c=s.nativeElement.tagName?.toLowerCase();this.isAnchorElement=c==="a"||c==="area"||!!(typeof customElements=="object"&&customElements.get(c)?.observedAttributes?.includes?.("href"))}setTabIndexIfNotOnNativeEl(e){this.tabIndexAttribute!=null||this.isAnchorElement||this.applyAttributeValue("tabindex",e)}ngOnChanges(e){this.onChanges.next(this)}routerLinkInput=C(null);set routerLink(e){e==null?(this.routerLinkInput.set(null),this.setTabIndexIfNotOnNativeEl(null)):(J(e)?this.routerLinkInput.set(e):this.routerLinkInput.set(Array.isArray(e)?e:[e]),this.setTabIndexIfNotOnNativeEl("0"))}onClick(e,r,i,o,s){let a=this._urlTree();if(a===null||this.isAnchorElement&&(e!==0||r||i||o||s||typeof this.target=="string"&&this.target!="_self"))return!0;let c={skipLocationChange:this.skipLocationChange,replaceUrl:this.replaceUrl,state:this.state,info:this.info};return this.router.navigateByUrl(a,c)?.catch(u=>{this.applicationErrorHandler(u)}),!this.isAnchorElement}ngOnDestroy(){}applyAttributeValue(e,r){let i=this.renderer,o=this.el.nativeElement;r!==null?i.setAttribute(o,e,r):i.removeAttribute(o,e)}_urlTree=Xe(()=>{this.reactiveRouterState.path(),this._preserveFragment()&&this.reactiveRouterState.fragment();let e=i=>i==="preserve"||i==="merge";(e(this._queryParamsHandling())||e(this.options?.defaultQueryParamsHandling))&&this.reactiveRouterState.queryParams();let r=this.routerLinkInput();return r===null||!this.router.createUrlTree?null:J(r)?r:this.router.createUrlTree(r,{relativeTo:this._relativeTo()!==void 0?this._relativeTo():this.route,queryParams:this._queryParams(),fragment:this._fragment(),queryParamsHandling:this._queryParamsHandling(),preserveFragment:this._preserveFragment()})},{equal:(e,r)=>this.computeHref(e)===this.computeHref(r)});get urlTree(){return y(this._urlTree)}computeHref(e){return e!==null&&this.locationStrategy?this.locationStrategy?.prepareExternalUrl(this.router.serializeUrl(e))??"":null}static \u0275fac=function(r){return new(r||t)($(X),$(G),Mr("tabindex"),$(jt),$(xt),$(Wr))};static \u0275dir=Te({type:t,selectors:[["","routerLink",""]],hostVars:2,hostBindings:function(r,i){r&1&&kr("click",function(s){return i.onClick(s.button,s.ctrlKey,s.shiftKey,s.altKey,s.metaKey)}),r&2&&xr("href",i.reactiveHref(),Tr)("target",i._target())},inputs:{target:"target",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",state:"state",info:"info",relativeTo:"relativeTo",preserveFragment:[2,"preserveFragment","preserveFragment",tt],skipLocationChange:[2,"skipLocationChange","skipLocationChange",tt],replaceUrl:[2,"replaceUrl","replaceUrl",tt],routerLink:"routerLink"},features:[Me]})}return t})(),Io=(()=>{class t{router;element;renderer;cdr;links;classes=[];routerEventsSubscription;linkInputChangesSubscription;_isActive=!1;get isActive(){return this._isActive}routerLinkActiveOptions={exact:!1};ariaCurrentWhenActive;isActiveChange=new ne;link=h(Dt,{optional:!0});constructor(e,r,i,o){this.router=e,this.element=r,this.renderer=i,this.cdr=o,this.routerEventsSubscription=e.events.subscribe(s=>{s instanceof L&&this.update()})}ngAfterContentInit(){g(this.links.changes,g(null)).pipe(Ie()).subscribe(e=>{this.update(),this.subscribeToEachLinkOnChanges()})}subscribeToEachLinkOnChanges(){this.linkInputChangesSubscription?.unsubscribe();let e=[...this.links.toArray(),this.link].filter(r=>!!r).map(r=>r.onChanges);this.linkInputChangesSubscription=b(e).pipe(Ie()).subscribe(r=>{this._isActive!==this.isLinkActive(this.router)(r)&&this.update()})}set routerLinkActive(e){let r=Array.isArray(e)?e:e.split(" ");this.classes=r.filter(i=>!!i)}ngOnChanges(e){this.update()}ngOnDestroy(){this.routerEventsSubscription.unsubscribe(),this.linkInputChangesSubscription?.unsubscribe()}update(){!this.links||!this.router.navigated||queueMicrotask(()=>{let e=this.hasActiveLinks();this.classes.forEach(r=>{e?this.renderer.addClass(this.element.nativeElement,r):this.renderer.removeClass(this.element.nativeElement,r)}),e&&this.ariaCurrentWhenActive!==void 0?this.renderer.setAttribute(this.element.nativeElement,"aria-current",this.ariaCurrentWhenActive.toString()):this.renderer.removeAttribute(this.element.nativeElement,"aria-current"),this._isActive!==e&&(this._isActive=e,this.cdr.markForCheck(),this.isActiveChange.emit(e))})}isLinkActive(e){let r=Ao(this.routerLinkActiveOptions)?this.routerLinkActiveOptions:this.routerLinkActiveOptions.exact??!1?l({},nr):l({},Pe);return i=>{let o=i.urlTree;return o?y(ir(o,e,r)):!1}}hasActiveLinks(){let e=this.isLinkActive(this.router);return this.link&&e(this.link)||this.links.some(e)}static \u0275fac=function(r){return new(r||t)($(X),$(xt),$(jt),$(et))};static \u0275dir=Te({type:t,selectors:[["","routerLinkActive",""]],contentQueries:function(r,i,o){if(r&1&&$r(o,Dt,5),r&2){let s;zr(s=Fr())&&(i.links=s)}},inputs:{routerLinkActiveOptions:"routerLinkActiveOptions",ariaCurrentWhenActive:"ariaCurrentWhenActive",routerLinkActive:"routerLinkActive"},outputs:{isActiveChange:"isActiveChange"},exportAs:["routerLinkActive"],features:[Me]})}return t})();function Ao(t){let n=t;return!!(n.paths||n.matrixParams||n.queryParams||n.fragment)}var We=class{},Eo=(()=>{class t{preload(e,r){return r().pipe(Ae(()=>g(null)))}static \u0275fac=function(r){return new(r||t)};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var Hn=(()=>{class t{router;injector;preloadingStrategy;loader;subscription;constructor(e,r,i,o){this.router=e,this.injector=r,this.preloadingStrategy=i,this.loader=o}setUpPreloading(){this.subscription=this.router.events.pipe(W(e=>e instanceof L),Ee(()=>this.preload())).subscribe(()=>{})}preload(){return this.processRoutes(this.injector,this.router.config)}ngOnDestroy(){this.subscription?.unsubscribe()}processRoutes(e,r){let i=[];for(let o of r){o.providers&&!o._injector&&(o._injector=Je(o.providers,e,""));let s=o._injector??e;o._loadedNgModuleFactory&&!o._loadedInjector&&(o._loadedInjector=o._loadedNgModuleFactory.create(s).injector);let a=o._loadedInjector??s;(o.loadChildren&&!o._loadedRoutes&&o.canLoad===void 0||o.loadComponent&&!o._loadedComponent)&&i.push(this.preloadConfig(s,o)),(o.children||o._loadedRoutes)&&i.push(this.processRoutes(a,o.children??o._loadedRoutes))}return b(i).pipe(Ie())}preloadConfig(e,r){return this.preloadingStrategy.preload(r,()=>{if(e.destroyed)return g(null);let i;r.loadChildren&&r.canLoad===void 0?i=b(this.loader.loadChildren(e,r)):i=g(null);let o=i.pipe(k(s=>s===null?g(void 0):(r._loadedRoutes=s.routes,r._loadedInjector=s.injector,r._loadedNgModuleFactory=s.factory,this.processRoutes(s.injector??e,s.routes))));if(r.loadComponent&&!r._loadedComponent){let s=this.loader.loadComponent(e,r);return b([o,s]).pipe(Ie())}else return o})}static \u0275fac=function(r){return new(r||t)(K(X),K(H),K(We),K(hr))};static \u0275prov=R({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})(),Mo=new M("");function To(t,...n){return Ir([{provide:Ge,multi:!0,useValue:t},[],{provide:G,useFactory:Do},{provide:Pr,multi:!0,useFactory:No},n.map(e=>e.\u0275providers)])}function Do(){return h(X).routerState.root}function Bn(t,n){return{\u0275kind:t,\u0275providers:n}}function No(){let t=h(Ar);return n=>{let e=t.get(Lr);if(n!==e.components[0])return;let r=t.get(X),i=t.get(_o);t.get(Oo)===1&&r.initialNavigation(),t.get(Vn,null,{optional:!0})?.setUpPreloading(),t.get(Mo,null,{optional:!0})?.init(),r.resetRootComponentType(e.componentTypes[0]),i.closed||(i.next(),i.complete(),i.unsubscribe())}}var _o=new M("",{factory:()=>new re}),Oo=new M("",{factory:()=>1});var Vn=new M("");function Uo(t){return Bn(0,[{provide:Vn,useExisting:Hn},{provide:We,useExisting:t}])}function Po(){return Bn(8,[cr,{provide:Be,useExisting:cr}])}export{L as a,G as b,sr as c,X as d,Dt as e,Io as f,Eo as g,To as h,Uo as i,Po as j};
@@ -0,0 +1 @@
1
+ import{a as yt,b as Ut,c as $t,l as Lt,p as Rt,q as vt}from"./chunk-DFVPFPMV.js";import"./chunk-5L2OOKRZ.js";import"./chunk-OO32MPRQ.js";import{b as Mt,c as Ft,d as wt}from"./chunk-OBF6ZSYT.js";import"./chunk-6Q6SSTBK.js";import"./chunk-7FDLOZXV.js";import"./chunk-EQNDYV43.js";import"./chunk-35APLYI4.js";import"./chunk-YMUS7QSB.js";import"./chunk-ZXQSQRKN.js";import"./chunk-XZNYCTQB.js";import"./chunk-R6TFME5I.js";import"./chunk-AZRNX5LU.js";import{B as ht,C as It,G as ft,H as Ot,K as Dt,L as Pt,V as xt,W as At,c as ct,e as dt,f as Ct,g as gt,i as ut,j as Tt,r as pt,s as mt,v as St,w as Nt,y as Et}from"./chunk-NCXKMSRH.js";import"./chunk-QAQMMCTH.js";import{b as _t,d as lt}from"./chunk-KHZ5AXGT.js";import"./chunk-L2QOWZDR.js";import"./chunk-BRL4YYWO.js";import"./chunk-BDQJFOCO.js";import"./chunk-FSHBOASN.js";import{$b as s,Ab as M,Bb as F,Bc as rt,Cb as E,Db as a,Eb as r,Fb as h,Jb as b,Kb as G,Mb as N,Rc as $,Sa as l,Tb as f,Ub as O,Vb as S,Zb as C,Zc as st,_ as P,da as c,ea as d,gb as et,gc as nt,ha as tt,hc as it,kc as ot,nc as g,oc as D,pa as I,ra as v,sc as w,tc as y,uc as U,vc as at,wb as T,wc as k,xb as p,xc as x,yb as A}from"./chunk-UH2E7MMT.js";import"./chunk-7CGTOI24.js";var bt=["testUrl"],Gt=()=>({maxWidth:"700px",width:"100%"});function kt(o,n){if(o&1){let t=N();a(0,"sh-card",30)(1,"div",32)(2,"h3"),S(3,4),r(),a(4,"button",33),C("click",function(){c(t);let i=s(3);return d(i.closeCustomList())}),g(5," Cancel "),a(6,"sh-icon"),g(7,"x-bold"),r()()(),a(8,"app-destination-list",34),C("setDestination",function(i){c(t);let _=s(3);return d(_.setDestination(i))}),r()()}}function Bt(o,n){if(o&1){let t=N();a(0,"div",40)(1,"sh-toggle",43),U("checkedChange",function(i){c(t);let _=s(2).$implicit;return y(_.save,i)||(_.save=i),d(i)}),a(2,"span",44),S(3,8),r()()()}if(o&2){let t=s(2).$implicit;l(),E("color","primary")("variant","raised"),w("checked",t.save)}}function Vt(o,n){if(o&1){let t=N();a(0,"sh-toggle-card",31),b(1,35),a(2,"app-destination-list-item",36)(3,"button",33),C("click",function(){c(t);let i=s().$index,_=s(2);return d(_.changeDestination(i))}),g(4,"Change"),r(),a(5,"sh-menu",37),C("click",function(i){return i.stopPropagation()}),a(6,"button",38)(7,"sh-icon"),g(8,"dots-three-vertical"),r()(),b(9,39),a(10,"button",33),C("click",function(){c(t);let i=s().$index,_=s(2);return d(_.openTargetUrlDialog(i))}),f(11,5),h(12,"sh-icon"),O(),r(),a(13,"button",33),C("click",function(){c(t);let i=s().$index,_=s(2);return d(_.copyTargetUrl(i))}),f(14,6),h(15,"sh-icon"),O(),r(),a(16,"button",33),C("click",function(){c(t);let i=s().$index,_=s(2);return d(_.removeDestination(i))}),f(17,7),h(18,"sh-icon"),O(),r(),G(),r()(),G(),T(19,Bt,4,3,"div",40),a(20,"app-test-url",41,1),C("targetUrlChange",function(i){c(t);let _=s().$index,m=s(2);return d(m.updateTargetUrl(_,i))})("testSignalChange",function(i){c(t);let _=s().$index,m=s(2);return d(m.updateTestState(_,i))}),r(),a(22,"app-single-destination",42),C("targetUrlChange",function(i){c(t);let _=s().$index,m=s(2);return d(m.updateTargetUrl(_,i))}),r()()}if(o&2){let t=s(),e=t.$implicit,i=t.$index,_=s(2);E("disableToggle",!0)("isActive",!0),l(2),E("targetUrl",e.url)("connectionStringId",e.connectionStringId),l(17),p(e.connectionStringId?-1:19),l(),E("targetUrl",e.url)("testSignal",_.testStates()[i]||null)("backupId",_.backupId())("connectionStringId",e.connectionStringId)("sourcePrefix",null)("suppressErrorDialogs",!1)("askToCreate",!0)("testExpectation",_.isNew()?"destinationEmpty":"any")("moduleType","Backend"),l(2),E("targetUrl",e.url)("useBackupState",!0)}}function Kt(o,n){if(o&1&&T(0,kt,9,0,"sh-card",30)(1,Vt,23,16,"sh-toggle-card",31),o&2){let t=n.$index,e=s(2);p(e.showCustomList()&&e.currentEditingIndex()===t?0:1)}}function Jt(o,n){if(o&1&&M(0,Kt,2,1,null,null,A),o&2){s();let t=x(0);F(t)}}function Xt(o,n){o&1&&(a(0,"div",45),h(1,"sh-progress-bar",46),a(2,"div",47)(3,"h3"),S(4,9),r()()())}function zt(o,n){o&1&&(a(0,"sh-divider"),S(1,12),r())}function Ht(o,n){if(o&1&&(a(0,"p",52),g(1),r()),o&2){let t=s().$implicit;l(),D(t.Description)}}function Wt(o,n){if(o&1&&(a(0,"p",52),g(1),r()),o&2){let t=s().$implicit,e=s(4);l(),D(e.getSimplePath(t.BaseUrl))}}function jt(o,n){if(o&1){let t=N();a(0,"app-destination-list-item",50),C("click",function(){let i=c(t).$implicit,_=s(4);return d(_.selectSavedDestination(i))})("keydown.enter",function(i){return i.target.click()})("keydown.space",function(i){return i.target.click()}),a(1,"h3",51),g(2),r(),T(3,Ht,2,1,"p",52)(4,Wt,2,1,"p",52),r()}if(o&2){let t=n.$implicit;E("targetUrl",t.BaseUrl),l(2),D(t.Name||t.BaseUrl),l(),p(t.Description?3:4)}}function Qt(o,n){if(o&1){let t=N();a(0,"sh-card",48),C("click",function(){c(t);let i=s(3);return d(i.toggleCustomList())})("keydown.enter",function(i){return i.target.click()})("keydown.space",function(i){return i.target.click()}),a(1,"sh-icon"),g(2,"plus-circle"),r(),a(3,"div",47)(4,"h3"),S(5,10),r(),a(6,"p"),S(7,11),r()()(),T(8,zt,2,0,"sh-divider"),M(9,jt,5,3,"app-destination-list-item",49,A)}if(o&2){let t=s(3);l(8),p(t.destinations().length>0?8:-1),l(),F(t.destinations())}}function qt(o,n){if(o&1&&T(0,Xt,5,0,"div",45)(1,Qt,11,1),o&2){let t=s(2);p(t.isLoadingDestinations()?0:1)}}function Yt(o,n){o&1&&(a(0,"sh-divider"),S(1,15),r())}function Zt(o,n){if(o&1&&(a(0,"p",52),g(1),r()),o&2){let t=s().$implicit;l(),D(t.Description)}}function te(o,n){if(o&1&&(a(0,"p",52),g(1),r()),o&2){let t=s().$implicit,e=s(3);l(),D(e.getSimplePath(t.BaseUrl))}}function ee(o,n){if(o&1){let t=N();a(0,"app-destination-list-item",57),C("click",function(){let i=c(t).$implicit,_=s(3);return d(_.selectSavedDestination(i))}),a(1,"h3",51),g(2),r(),T(3,Zt,2,1,"p",52)(4,te,2,1,"p",52),r()}if(o&2){let t=n.$implicit;E("targetUrl",t.BaseUrl),l(2),D(t.Name||t.BaseUrl),l(),p(t.Description?3:4)}}function ne(o,n){if(o&1){let t=N();a(0,"div",53)(1,"button",54),C("click",function(){c(t);let i=s(2);return d(i.closeCustomList())}),a(2,"sh-icon"),g(3,"arrow-left"),r(),g(4," Back "),r()(),a(5,"sh-card",55),C("click",function(){c(t);let i=s(2);return d(i.toggleCustomList())}),a(6,"sh-icon"),g(7,"plus-circle"),r(),a(8,"div",47)(9,"h3"),S(10,13),r(),a(11,"p"),S(12,14),r()()(),T(13,Yt,2,0,"sh-divider"),M(14,ee,5,3,"app-destination-list-item",56,A)}if(o&2){let t=s(2);l(13),p(t.destinations().length>0?13:-1),l(),F(t.destinations())}}function ie(o,n){if(o&1){let t=N();a(0,"div",53)(1,"button",54),C("click",function(){c(t);let i=s(3);return d(i.closeCustomList())}),a(2,"sh-icon"),g(3,"arrow-left"),r()(),a(4,"h3"),S(5,16),r()()}}function oe(o,n){if(o&1){let t=N();T(0,ie,6,0,"div",53),a(1,"app-destination-list",34),C("setDestination",function(i){c(t);let _=s(2);return d(_.setDestination(i))}),r()}if(o&2){let t=s(2),e=x(0);p(t.destinations().length>0||e.length>0?0:-1)}}function ae(o,n){if(o&1&&T(0,qt,2,1)(1,ne,16,1)(2,oe,2,1),o&2){let t=s(),e=x(1);p(!t.showCustomList()&&!e&&!t.isAddingNew()?0:t.isAddingNew()&&!t.showCustomList()?1:2)}}function re(o,n){if(o&1){let t=N();a(0,"div",25)(1,"button",58),C("click",function(){c(t);let i=s();return d(i.startAddingNew())}),a(2,"sh-icon"),g(3,"plus"),r(),g(4," Add another destination "),r()()}}function se(o,n){o&1&&(a(0,"h2"),S(1,19),r())}function _e(o,n){o&1&&(a(0,"h2"),S(1,20),r())}function le(o,n){if(o&1){let t=N();a(0,"sh-dialog",59),U("isOpenChange",function(i){c(t);let _=s();return y(_.targetUrlDialogOpen,i)||(_.targetUrlDialogOpen=i),d(i)}),a(1,"header",60)(2,"div",61),T(3,se,2,0,"h2")(4,_e,2,0,"h2"),a(5,"sh-alert",62),S(6,17),r()()(),a(7,"div",63)(8,"sh-form-field")(9,"textarea",64),U("ngModelChange",function(i){c(t);let _=s();return y(_.targetUrlCtrl,i)||(_.targetUrlCtrl=i),d(i)}),r()()(),a(10,"footer",65)(11,"button",27),C("click",function(){c(t);let i=s();return d(i.closeTargetUrlDialog(!1))}),g(12,"Cancel"),r(),a(13,"button",66),C("click",function(){c(t);let i=s();return d(i.closeTargetUrlDialog(!0))}),f(14,18),h(15,"sh-icon"),O(),r()()()}if(o&2){let t=s(),e=x(1);w("isOpen",t.targetUrlDialogOpen),E("options",rt(4,Gt)),l(3),p(e?4:3),l(6),w("ngModel",t.targetUrlCtrl)}}var L=new pt,Ae=(o={destinations:[]})=>L.group({destinations:L.array(o.destinations)}),Me=({key:o,customGroup:n,dynamicGroup:t,advancedGroup:e})=>L.group({destinationType:L.control(o),custom:n,dynamic:t,advanced:e}),B=class o{#n=P(lt);#i=P(_t);#t=P(Rt);#e=P(yt);injector=P(tt);testUrlComponents=st("testUrl");testStates=I([]);targetUrls=this.#t.targetUrls;targetUrlModel=$(()=>this.targetUrls()[0]?.url??null);targetUrlCtrl=I(null);targetUrlInitial=I(null);currentEditingIndex=I(null);targetUrlDialogOpen=I(!1);showCustomList=I(!1);isConnectionStringSaved=this.#t.isConnectionStringSaved;destinations=this.#e.destinations;isLoadingDestinations=this.#e.resourceDestinations.isLoading;isNew=this.#t.isNew;backupId=this.#t.backupId;selectedDestinationType=$(()=>{let n=this.targetUrlModel();return n?Ft(n)??null:null});isLoadingDestinationEffect=v(()=>{let n=this.isLoadingDestinations(),t=this.destinations(),e=this.targetUrls();!n&&t.length==0&&e.length==0&&this.toggleCustomList()});selectedDestinationTypeOption=$(()=>{let n=this.selectedDestinationType();return n?{key:n.customKey??n.key,customKey:n.customKey??null,displayName:n.displayName,description:n.description,icon:n.icon}:null});getConnectionString(n){let t=this.#e.destinations().find(e=>e.ID===n);return console.log("connection",t),t}getSimplePath(n){return n?Mt(n):""}copyTargetUrl(n=0){let t=this.targetUrls()[n]?.url;t&&navigator.clipboard.writeText(t)}openTargetUrlDialog(n=0){let t=this.targetUrls()[n]?.url??null;this.targetUrlCtrl.set(t),this.targetUrlInitial.set(t),this.currentEditingIndex.set(n),this.targetUrlDialogOpen.set(!0)}closeTargetUrlDialog(n=!1){this.targetUrlDialogOpen.set(!1);let t=this.targetUrlCtrl(),e=this.targetUrlInitial();if(!n||t===e||!t)return;let i=this.currentEditingIndex();if(i!==null){let _=this.targetUrls()[i]?.connectionStringId??null,m=this.targetUrls()[i]?.urlKey??null;this.#t.updateTargetUrl(i,t,_,m)}else this.#t.setTargetUrl(t);this.currentEditingIndex.set(null)}setDestination(n){let t=wt(n??"");if(!t)return;let e=t.mapper.default?t.mapper.default(this.#t.backupName()??""):`${n}://`;if(this.currentEditingIndex()!==null){this.#t.updateTargetUrl(this.currentEditingIndex(),e,null,null),this.updateTestState(this.currentEditingIndex(),null),this.currentEditingIndex.set(null),this.showCustomList.set(!1);return}this.showCustomList()?(this.#t.addTargetUrl(e,null,null),this.showCustomList.set(!1),this.isAddingNew.set(!1)):(this.#t.addTargetUrl(e,null,null),this.showCustomList.set(!1),this.isAddingNew.set(!1))}targetUrlsEffect=v(()=>{let n=this.targetUrls();this.testStates.update(t=>{if(t.length===n.length)return t;let e=[...t];if(e.length<n.length)for(let i=e.length;i<n.length;i++)e.push(null);else e.length=n.length;return e})});selectSavedDestination(n){n.BaseUrl&&n.BaseUrl&&(this.targetUrls().length===0?this.#t.setTargetUrl(n.BaseUrl,!0,n.ID,null):(this.#t.addTargetUrl(n.BaseUrl,n.ID,null),this.showCustomList.set(!1),this.isAddingNew.set(!1)))}toggleCustomList(){this.currentEditingIndex.set(null),this.showCustomList.set(!0)}isAddingNew=I(!1);startAddingNew(){this.isAddingNew.set(!0),this.destinations().length===0&&this.showCustomList.set(!0)}changeDestination(n){this.currentEditingIndex.set(n),this.showCustomList.set(!0)}closeCustomList(){this.showCustomList.set(!1),this.currentEditingIndex.set(null),this.isAddingNew.set(!1)}removeDestination(n){this.#t.removeTargetUrl(n)}updateTargetUrl(n,t){if(!t)return;let e=this.targetUrls()[n]?.connectionStringId??null,i=this.targetUrls()[n]?.urlKey??null;this.#t.updateTargetUrl(n,t,e,i),this.updateTestState(n,null)}updateTestState(n,t){this.testStates.update(e=>{let i=[...e];return i[n]=t,i})}toggleSave(n){this.#t.toggleSaveConnectionString(n)}goBack(){this.#n.navigate(["general"],{relativeTo:this.#i.parent})}async next(){if(!this.#t.isNew()){this.#o();return}let t=this.testUrlComponents(),e=this.testStates();for(let i=0;i<t.length;i++){let _=t[i],m=this.testStates()[i];if(m&&typeof m!="string"&&m.action==="success")continue;if((await _.testDestination(!1))?.action!=="success")return}this.#o()}#o(){this.#t.shouldAutoSave()&&this.#t.submit(!0),this.#n.navigate(["source-data"],{relativeTo:this.#i.parent})}static \u0275fac=function(t){return new(t||o)};static \u0275cmp=et({type:o,selectors:[["app-destination"]],viewQuery:function(t,e){t&1&&nt(e.testUrlComponents,bt,5),t&2&&it()},decls:19,vars:9,consts:()=>{let n;n=$localize`${"\uFFFD#14\uFFFD"}:START_TAG_SH_ICON:arrow-left${"\uFFFD/#14\uFFFD"}:CLOSE_TAG_SH_ICON: Go back `;let t;t=$localize`${"\uFFFD#17\uFFFD"}:START_TAG_SH_ICON:arrow-right${"\uFFFD/#17\uFFFD"}:CLOSE_TAG_SH_ICON: Continue `;let e;e=$localize`Change destination type`;let i;i=$localize`${"\uFFFD#12\uFFFD"}:START_TAG_SH_ICON:link${"\uFFFD/#12\uFFFD"}:CLOSE_TAG_SH_ICON: Edit target URL `;let _;_=$localize`${"\uFFFD#15\uFFFD"}:START_TAG_SH_ICON:copy${"\uFFFD/#15\uFFFD"}:CLOSE_TAG_SH_ICON: Copy URL to clipboard `;let m;m=$localize`${"\uFFFD#18\uFFFD"}:START_TAG_SH_ICON:trash${"\uFFFD/#18\uFFFD"}:CLOSE_TAG_SH_ICON: Remove `;let R;R=$localize`Save as connection string`;let V;V=$localize`Loading destinations...`;let K;K=$localize`Configure a new destination`;let J;J=$localize`Configure a one-off or new storage location.`;let X;X=$localize`Or select a saved destination`;let z;z=$localize`Configure a new destination`;let H;H=$localize`Configure a one-off or new storage location.`;let W;W=$localize`Or select a saved destination`;let j;j=$localize`Select storage type`;let Q;Q=$localize`Be careful, this will overwrite everything you have in your destination.`;let q;q=$localize` Override target URL ${"\uFFFD#15\uFFFD"}:START_TAG_SH_ICON:swap${"\uFFFD/#15\uFFFD"}:CLOSE_TAG_SH_ICON:`;let Y;Y=$localize`Set target URL`;let Z;return Z=$localize`Edit target URL`,[["formRef",""],["testUrl",""],n,t,e,i,_,m,R,V,K,J,X,z,H,W,j,Q,q,Y,Z,["autocomplete","off",3,"submit"],[2,"position","absolute","left","-9999px","width","1px","height","1px","overflow","hidden"],["type","text","name","fake_email","tabindex","-1"],["type","password","name","fake_password","tabindex","-1"],[1,"add-destination-container"],[1,"form-actions"],["shButton","","type","button",3,"click"],["shButton","","type","submit",1,"raised","primary",3,"disabled"],[3,"isOpen","options"],[1,"destination-card","type-c","editing"],[1,"destination-card","type-a",3,"disableToggle","isActive"],[1,"editing-header"],["shButton","","type","button",1,"small",3,"click"],[3,"setDestination"],["title",""],[3,"targetUrl","connectionStringId"],[1,"actions",3,"click"],["shButton","","type","button",1,"small","icon-only"],["menu",""],[1,"options-row",2,"margin","0 1rem 1rem 1rem"],[3,"targetUrlChange","testSignalChange","targetUrl","testSignal","backupId","connectionStringId","sourcePrefix","suppressErrorDialogs","askToCreate","testExpectation","moduleType"],[3,"targetUrlChange","targetUrl","useBackupState"],[3,"checkedChange","color","variant","checked"],["label",""],[1,"loading-list"],[1,"indeterminate","primary"],[1,"text"],["tabindex","0",1,"type-a","actionable","add-new",3,"click","keydown.enter","keydown.space"],["variant","type-a","tabindex","0",1,"actionable",3,"targetUrl"],["variant","type-a","tabindex","0",1,"actionable",3,"click","keydown.enter","keydown.space","targetUrl"],["displayName",""],["description",""],[1,"custom-list-header"],["shButton","","iconOnly","","variant","ghost","type","button",3,"click"],[1,"type-a","actionable","add-new",3,"click"],["variant","type-a",1,"actionable",3,"targetUrl"],["variant","type-a",1,"actionable",3,"click","targetUrl"],["shButton","","type","button",1,"secondary",3,"click"],[3,"isOpenChange","isOpen","options"],["header",""],[1,"target-dialog-header"],[1,"warn"],["content",""],["id","targetUrl","autocomplete","off",3,"ngModelChange","ngModel"],["footer",""],["shButton","","type","submit",1,"raised","primary",3,"click"]]},template:function(t,e){if(t&1&&(at(0)(1),a(2,"form",21,0),C("submit",function(){return e.next()}),a(4,"div",22),h(5,"input",23)(6,"input",24),r(),a(7,"header"),T(8,Jt,2,0),r(),T(9,ae,3,1),T(10,re,5,0,"div",25),a(11,"div",26)(12,"button",27),C("click",function(){return e.goBack()}),f(13,2),h(14,"sh-icon"),O(),r(),a(15,"button",28),f(16,3),h(17,"sh-icon"),O(),r()()(),T(18,le,16,5,"sh-dialog",29)),t&2){let i=k(e.targetUrls());l();let _=k(i.length>0);l(7),p(e.currentEditingIndex()!==null||!e.showCustomList()&&!e.isAddingNew()?8:-1),l(),p((!_||e.showCustomList()||e.isAddingNew())&&e.currentEditingIndex()===null?9:-1),l(),p(_&&!e.showCustomList()&&!e.isAddingNew()?10:-1),l(5),ot("loading",e.isNew()&&e.testStates().length>0&&e.testStates()[0]==="testing"),E("disabled",!_),l(3),p(e.targetUrlDialogOpen()?18:-1)}},dependencies:[vt,$t,Ut,Lt,mt,Tt,ct,dt,Ct,ut,gt,ht,Ot,Dt,St,Et,Nt,It,ft,Pt,xt,At],styles:["[_nghost-%COMP%]{display:block;width:100%;max-width:40rem;padding:2.5rem 2.5rem 0}header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%], header[_ngcontent-%COMP%] sh-alert[_ngcontent-%COMP%]{width:100%}header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;gap:.5rem}header[_ngcontent-%COMP%] p[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{cursor:pointer;text-decoration:underline}header[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;height:100%;padding:0 0 2.5rem}.current-destination[_ngcontent-%COMP%]{margin:1rem 0 0}.form-actions[_ngcontent-%COMP%]{display:flex;justify-content:space-between;padding-bottom:1.5rem}.most-common-destinations[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem}.most-common-destinations[_ngcontent-%COMP%] .tile[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;padding:1rem;border:1px solid var(--base-4);border-radius:var(--shape-3);box-shadow:var(--box-shadow-10);background-color:var(--base-2);cursor:pointer}.most-common-destinations[_ngcontent-%COMP%] .tile[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-10);margin:0}.target-dialog-header[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;justify-content:space-between;gap:.5rem}.loading-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem;align-items:center;padding:4rem}.loading-list[_ngcontent-%COMP%] .text[_ngcontent-%COMP%]{text-align:center}.add-new[_ngcontent-%COMP%]{display:flex;align-items:center;gap:1.5rem;padding:1.5rem;background:var(--base-1);color:var(--primary-8);cursor:pointer}.add-new[_ngcontent-%COMP%] sh-icon[_ngcontent-%COMP%]{font-size:2.5rem;opacity:.8}.actionable[_ngcontent-%COMP%]{cursor:pointer}.actionable[_ngcontent-%COMP%]:hover{--card-shp: 0}.custom-list-header[_ngcontent-%COMP%]{display:flex;align-items:center;gap:1rem;margin-bottom:.5rem}.save-connection-string[_ngcontent-%COMP%]{margin:1rem 0}sh-card.destination-card[_ngcontent-%COMP%]{padding:1.5rem}.destination-card[_ngcontent-%COMP%]{position:relative;overflow:visible}.destination-card[_ngcontent-%COMP%] app-destination-list-item[_ngcontent-%COMP%]{width:100%}.destination-card[_ngcontent-%COMP%] .card-header-content[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;width:100%}.destination-card[_ngcontent-%COMP%] .card-header-content[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--title-30);margin:0}.destination-card[_ngcontent-%COMP%] .card-header-content[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{position:static;transform:none}.destination-card[_ngcontent-%COMP%] .editing-header[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;margin-bottom:1rem}.destination-card[_ngcontent-%COMP%] .editing-header[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font:var(--paragraph-10);margin:0}.destination-card[_ngcontent-%COMP%] sh-toggle-card[_ngcontent-%COMP%] .header{width:100%}.actions[_ngcontent-%COMP%]{display:flex;gap:.5rem}"],changeDetection:0})};export{Ae as createDestinationForm,Me as createDestinationFormGroup,B as default};