@futdevpro/ccap 1.1.2980 → 1.1.2988

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 (177) hide show
  1. package/client-dist/{agent-instances.module-WFXL2NDE.js → agent-instances.module-EZ3HLJRW.js} +2 -2
  2. package/client-dist/{ca.module-CVTI3AF7.js → ca.module-2NK5JZOQ.js} +2 -2
  3. package/client-dist/{cc-usage-dashboard.component-I2G2NBSY.js → cc-usage-dashboard.component-SLFNE2NX.js} +2 -2
  4. package/client-dist/{cc.module-EXDXYOJ4.js → cc.module-F7LHWQ3A.js} +2 -2
  5. package/client-dist/{chunk-ESPURNI3.js → chunk-2CZLQZAC.js} +2 -2
  6. package/client-dist/{chunk-N26D6SXG.js → chunk-35HAXCRL.js} +2 -2
  7. package/client-dist/{chunk-3HWZLIS3.js → chunk-4JZNUGDT.js} +2 -2
  8. package/client-dist/{chunk-SG5TSGOY.js → chunk-4ORBCWDZ.js} +2 -2
  9. package/client-dist/{chunk-Q2WNI354.js → chunk-565H5Q7X.js} +2 -2
  10. package/client-dist/{chunk-SBPFNYFT.js → chunk-5GCMRTM2.js} +2 -2
  11. package/client-dist/{chunk-WXN5C3BS.js → chunk-66YFYBOC.js} +2 -2
  12. package/client-dist/{chunk-HRSSMQBA.js → chunk-6CNO7CIR.js} +2 -2
  13. package/client-dist/{chunk-7XAV5GIW.js → chunk-6IVNYSN4.js} +2 -2
  14. package/client-dist/{chunk-ZOCMDQAW.js → chunk-6UTINZN6.js} +2 -2
  15. package/client-dist/{chunk-VSGHMHDK.js → chunk-7FDRE6FK.js} +2 -2
  16. package/client-dist/{chunk-FVNI46U2.js → chunk-ACLAVYA7.js} +2 -2
  17. package/client-dist/{chunk-4CXFWMLH.js → chunk-ALRGHRMX.js} +2 -2
  18. package/client-dist/{chunk-AQO5IW5B.js → chunk-CJXAN5QP.js} +2 -2
  19. package/client-dist/{chunk-ORFH2XGX.js → chunk-CK4L2E6A.js} +2 -2
  20. package/client-dist/{chunk-EP3IAFIL.js → chunk-CPOWA47I.js} +2 -2
  21. package/client-dist/{chunk-GH67BJ7J.js → chunk-CROOTWQ4.js} +2 -2
  22. package/client-dist/{chunk-4ANOVQQ6.js → chunk-CZK7PL4V.js} +2 -2
  23. package/client-dist/{chunk-TSGXTLGO.js → chunk-CZVHJQVK.js} +2 -2
  24. package/client-dist/{chunk-N7HJWJ2S.js → chunk-EZQXUBC4.js} +2 -2
  25. package/client-dist/{chunk-4OK5LJEU.js → chunk-HK3NW3BA.js} +2 -2
  26. package/client-dist/{chunk-VHZQSBXM.js → chunk-HKO57F7B.js} +2 -2
  27. package/client-dist/{chunk-GZRNNZID.js → chunk-I24ZZ4G3.js} +2 -2
  28. package/client-dist/{chunk-7EHVTWSO.js → chunk-I5LYGLY6.js} +2 -2
  29. package/client-dist/{chunk-CU2HMFAD.js → chunk-IMV4JDM4.js} +2 -2
  30. package/client-dist/{chunk-C75AJJFP.js → chunk-KOFPH2WQ.js} +2 -2
  31. package/client-dist/{chunk-LBMIDL4S.js → chunk-L2E2MBF2.js} +2 -2
  32. package/client-dist/{chunk-2CUMN334.js → chunk-LNDWBFCV.js} +2 -2
  33. package/client-dist/{chunk-2UXI7P2C.js → chunk-LOUIZXXC.js} +2 -2
  34. package/client-dist/{chunk-DPGBOTN3.js → chunk-LP2E4KMW.js} +2 -2
  35. package/client-dist/{chunk-2VU3GISV.js → chunk-M53FIKSO.js} +2 -2
  36. package/client-dist/{chunk-JGLBYLWW.js → chunk-MIWIPUJL.js} +2 -2
  37. package/client-dist/{chunk-OVD3GSH2.js → chunk-OJPFXL3T.js} +2 -2
  38. package/client-dist/{chunk-EPIK2P4Q.js → chunk-PUVXCR3N.js} +2 -2
  39. package/client-dist/{chunk-VEPJ3MZH.js → chunk-QM4JVUVN.js} +2 -2
  40. package/client-dist/{chunk-KB2F332Z.js → chunk-QYAK3VTE.js} +2 -2
  41. package/client-dist/{chunk-RWQ5B34I.js → chunk-RJEB2CGY.js} +2 -2
  42. package/client-dist/{chunk-AE5VAS75.js → chunk-RQSPYGNE.js} +2 -2
  43. package/client-dist/{chunk-MMFURH5P.js → chunk-RTAONMUA.js} +2 -2
  44. package/client-dist/{chunk-BGNEFOVG.js → chunk-SAWE7K3L.js} +2 -2
  45. package/client-dist/{chunk-RG67NB4W.js → chunk-SIC2VUD2.js} +2 -2
  46. package/client-dist/{chunk-WL7JJ44C.js → chunk-SMBU53NX.js} +2 -2
  47. package/client-dist/{chunk-I4M7XPFX.js → chunk-SUAZOLRE.js} +2 -2
  48. package/client-dist/{chunk-FSUMD4VQ.js → chunk-SYXQFJNU.js} +2 -2
  49. package/client-dist/{chunk-UBUKMZCP.js → chunk-TWUEQMEF.js} +2 -2
  50. package/client-dist/{chunk-RT7QOL2Q.js → chunk-VUMU4S4O.js} +2 -2
  51. package/client-dist/{chunk-AYDRWFG2.js → chunk-W4ICO22C.js} +2 -2
  52. package/client-dist/{chunk-6EPKNTJZ.js → chunk-W66474CE.js} +2 -2
  53. package/client-dist/{chunk-WDSKSHR7.js → chunk-WKXTPGKW.js} +2 -2
  54. package/client-dist/{chunk-RV3A7THL.js → chunk-X3CIXD4W.js} +2 -2
  55. package/client-dist/{chunk-4WGQS2HA.js → chunk-XC26T3JJ.js} +2 -2
  56. package/client-dist/{chunk-UHAAQJ2R.js → chunk-XDP5GOHT.js} +2 -2
  57. package/client-dist/{chunk-4PZ65LDL.js → chunk-XO6LJ5A6.js} +2 -2
  58. package/client-dist/{chunk-PGKNPYIE.js → chunk-ZI46JBHS.js} +2 -2
  59. package/client-dist/{chunk-5N64HGRY.js → chunk-ZJ3DCODZ.js} +2 -2
  60. package/client-dist/{chunk-5N64HGRY.js.map → chunk-ZJ3DCODZ.js.map} +1 -1
  61. package/client-dist/{chunk-PWAWM6DC.js → chunk-ZRLAS63L.js} +2 -2
  62. package/client-dist/{consultant.module-WHGIMF6M.js → consultant.module-ZRSJ2JPM.js} +2 -2
  63. package/client-dist/{crd.module-EH2RIMWD.js → crd.module-TDLM6M2Z.js} +2 -2
  64. package/client-dist/{dashboard.module-EROOHU4C.js → dashboard.module-VSWWQDEU.js} +2 -2
  65. package/client-dist/{do.module-PATPM2KZ.js → do.module-CCOHMJLG.js} +2 -2
  66. package/client-dist/{document-library.module-QBW7XGNT.js → document-library.module-QLZ4ZUUG.js} +2 -2
  67. package/client-dist/{embedding-eval.module-O4YXXNZE.js → embedding-eval.module-6KORAJ7D.js} +2 -2
  68. package/client-dist/{embedding-registry.module-DOWVA6RV.js → embedding-registry.module-GJJ5G2Y7.js} +2 -2
  69. package/client-dist/{err.module-AWN67SP6.js → err.module-4GLVR2GJ.js} +2 -2
  70. package/client-dist/{feedback.module-BWKJCSTU.js → feedback.module-U6CCHRVZ.js} +2 -2
  71. package/client-dist/{host-runtime-mcp.module-24MRZ77I.js → host-runtime-mcp.module-EV5GZKTL.js} +2 -2
  72. package/client-dist/index.html +1 -1
  73. package/client-dist/{live-dev-pipeline.module-T4EERACF.js → live-dev-pipeline.module-MWG23KAS.js} +2 -2
  74. package/client-dist/{logs.module-O4MVHXRP.js → logs.module-YNDMPESQ.js} +2 -2
  75. package/client-dist/{main-NP3NWD3C.js → main-OGUDQHPL.js} +3 -3
  76. package/client-dist/{master-control-remote-poc.module-M6TNRCRQ.js → master-control-remote-poc.module-37OSJYRO.js} +2 -2
  77. package/client-dist/{mobile-app.module-SW2L4EB3.js → mobile-app.module-2DXC7DFY.js} +2 -2
  78. package/client-dist/{model-registry.module-MMEFDY3Y.js → model-registry.module-Z64FRB5O.js} +2 -2
  79. package/client-dist/{oc.module-PVCITNSF.js → oc.module-6SHIJS3R.js} +2 -2
  80. package/client-dist/{orc.module-2S5XXXZI.js → orc.module-NBZZGOV3.js} +2 -2
  81. package/client-dist/{project-management.module-XD6NLN3S.js → project-management.module-TR33UVCV.js} +2 -2
  82. package/client-dist/project-source-routed.module-ZZ7SNTUN.js +2 -0
  83. package/client-dist/{scheduler.module-7YAZ6PYA.js → scheduler.module-M3LHP2DW.js} +2 -2
  84. package/client-dist/{session.module-QNFMZPFT.js → session.module-FIZ5NYKK.js} +2 -2
  85. package/client-dist/{set.module-QLYUFFRH.js → set.module-4E6WAYIQ.js} +2 -2
  86. package/client-dist/{setup.module-HSVFOBYN.js → setup.module-2AUXXLIR.js} +2 -2
  87. package/client-dist/{terminals.module-2NKJL3L6.js → terminals.module-GCGUOFVO.js} +2 -2
  88. package/client-dist/{voice-notes-poc.module-VBWYBFHH.js → voice-notes-poc.module-6LVDT3MA.js} +2 -2
  89. package/client-dist/{wfs.module-2ZF3S6F2.js → wfs.module-XQGZNMEP.js} +2 -2
  90. package/package.json +1 -1
  91. package/client-dist/project-source-routed.module-ZBU2T4Q5.js +0 -2
  92. /package/client-dist/{agent-instances.module-WFXL2NDE.js.map → agent-instances.module-EZ3HLJRW.js.map} +0 -0
  93. /package/client-dist/{ca.module-CVTI3AF7.js.map → ca.module-2NK5JZOQ.js.map} +0 -0
  94. /package/client-dist/{cc-usage-dashboard.component-I2G2NBSY.js.map → cc-usage-dashboard.component-SLFNE2NX.js.map} +0 -0
  95. /package/client-dist/{cc.module-EXDXYOJ4.js.map → cc.module-F7LHWQ3A.js.map} +0 -0
  96. /package/client-dist/{chunk-ESPURNI3.js.map → chunk-2CZLQZAC.js.map} +0 -0
  97. /package/client-dist/{chunk-N26D6SXG.js.map → chunk-35HAXCRL.js.map} +0 -0
  98. /package/client-dist/{chunk-3HWZLIS3.js.map → chunk-4JZNUGDT.js.map} +0 -0
  99. /package/client-dist/{chunk-SG5TSGOY.js.map → chunk-4ORBCWDZ.js.map} +0 -0
  100. /package/client-dist/{chunk-Q2WNI354.js.map → chunk-565H5Q7X.js.map} +0 -0
  101. /package/client-dist/{chunk-SBPFNYFT.js.map → chunk-5GCMRTM2.js.map} +0 -0
  102. /package/client-dist/{chunk-WXN5C3BS.js.map → chunk-66YFYBOC.js.map} +0 -0
  103. /package/client-dist/{chunk-HRSSMQBA.js.map → chunk-6CNO7CIR.js.map} +0 -0
  104. /package/client-dist/{chunk-7XAV5GIW.js.map → chunk-6IVNYSN4.js.map} +0 -0
  105. /package/client-dist/{chunk-ZOCMDQAW.js.map → chunk-6UTINZN6.js.map} +0 -0
  106. /package/client-dist/{chunk-VSGHMHDK.js.map → chunk-7FDRE6FK.js.map} +0 -0
  107. /package/client-dist/{chunk-FVNI46U2.js.map → chunk-ACLAVYA7.js.map} +0 -0
  108. /package/client-dist/{chunk-4CXFWMLH.js.map → chunk-ALRGHRMX.js.map} +0 -0
  109. /package/client-dist/{chunk-AQO5IW5B.js.map → chunk-CJXAN5QP.js.map} +0 -0
  110. /package/client-dist/{chunk-ORFH2XGX.js.map → chunk-CK4L2E6A.js.map} +0 -0
  111. /package/client-dist/{chunk-EP3IAFIL.js.map → chunk-CPOWA47I.js.map} +0 -0
  112. /package/client-dist/{chunk-GH67BJ7J.js.map → chunk-CROOTWQ4.js.map} +0 -0
  113. /package/client-dist/{chunk-4ANOVQQ6.js.map → chunk-CZK7PL4V.js.map} +0 -0
  114. /package/client-dist/{chunk-TSGXTLGO.js.map → chunk-CZVHJQVK.js.map} +0 -0
  115. /package/client-dist/{chunk-N7HJWJ2S.js.map → chunk-EZQXUBC4.js.map} +0 -0
  116. /package/client-dist/{chunk-4OK5LJEU.js.map → chunk-HK3NW3BA.js.map} +0 -0
  117. /package/client-dist/{chunk-VHZQSBXM.js.map → chunk-HKO57F7B.js.map} +0 -0
  118. /package/client-dist/{chunk-GZRNNZID.js.map → chunk-I24ZZ4G3.js.map} +0 -0
  119. /package/client-dist/{chunk-7EHVTWSO.js.map → chunk-I5LYGLY6.js.map} +0 -0
  120. /package/client-dist/{chunk-CU2HMFAD.js.map → chunk-IMV4JDM4.js.map} +0 -0
  121. /package/client-dist/{chunk-C75AJJFP.js.map → chunk-KOFPH2WQ.js.map} +0 -0
  122. /package/client-dist/{chunk-LBMIDL4S.js.map → chunk-L2E2MBF2.js.map} +0 -0
  123. /package/client-dist/{chunk-2CUMN334.js.map → chunk-LNDWBFCV.js.map} +0 -0
  124. /package/client-dist/{chunk-2UXI7P2C.js.map → chunk-LOUIZXXC.js.map} +0 -0
  125. /package/client-dist/{chunk-DPGBOTN3.js.map → chunk-LP2E4KMW.js.map} +0 -0
  126. /package/client-dist/{chunk-2VU3GISV.js.map → chunk-M53FIKSO.js.map} +0 -0
  127. /package/client-dist/{chunk-JGLBYLWW.js.map → chunk-MIWIPUJL.js.map} +0 -0
  128. /package/client-dist/{chunk-OVD3GSH2.js.map → chunk-OJPFXL3T.js.map} +0 -0
  129. /package/client-dist/{chunk-EPIK2P4Q.js.map → chunk-PUVXCR3N.js.map} +0 -0
  130. /package/client-dist/{chunk-VEPJ3MZH.js.map → chunk-QM4JVUVN.js.map} +0 -0
  131. /package/client-dist/{chunk-KB2F332Z.js.map → chunk-QYAK3VTE.js.map} +0 -0
  132. /package/client-dist/{chunk-RWQ5B34I.js.map → chunk-RJEB2CGY.js.map} +0 -0
  133. /package/client-dist/{chunk-AE5VAS75.js.map → chunk-RQSPYGNE.js.map} +0 -0
  134. /package/client-dist/{chunk-MMFURH5P.js.map → chunk-RTAONMUA.js.map} +0 -0
  135. /package/client-dist/{chunk-BGNEFOVG.js.map → chunk-SAWE7K3L.js.map} +0 -0
  136. /package/client-dist/{chunk-RG67NB4W.js.map → chunk-SIC2VUD2.js.map} +0 -0
  137. /package/client-dist/{chunk-WL7JJ44C.js.map → chunk-SMBU53NX.js.map} +0 -0
  138. /package/client-dist/{chunk-I4M7XPFX.js.map → chunk-SUAZOLRE.js.map} +0 -0
  139. /package/client-dist/{chunk-FSUMD4VQ.js.map → chunk-SYXQFJNU.js.map} +0 -0
  140. /package/client-dist/{chunk-UBUKMZCP.js.map → chunk-TWUEQMEF.js.map} +0 -0
  141. /package/client-dist/{chunk-RT7QOL2Q.js.map → chunk-VUMU4S4O.js.map} +0 -0
  142. /package/client-dist/{chunk-AYDRWFG2.js.map → chunk-W4ICO22C.js.map} +0 -0
  143. /package/client-dist/{chunk-6EPKNTJZ.js.map → chunk-W66474CE.js.map} +0 -0
  144. /package/client-dist/{chunk-WDSKSHR7.js.map → chunk-WKXTPGKW.js.map} +0 -0
  145. /package/client-dist/{chunk-RV3A7THL.js.map → chunk-X3CIXD4W.js.map} +0 -0
  146. /package/client-dist/{chunk-4WGQS2HA.js.map → chunk-XC26T3JJ.js.map} +0 -0
  147. /package/client-dist/{chunk-UHAAQJ2R.js.map → chunk-XDP5GOHT.js.map} +0 -0
  148. /package/client-dist/{chunk-4PZ65LDL.js.map → chunk-XO6LJ5A6.js.map} +0 -0
  149. /package/client-dist/{chunk-PGKNPYIE.js.map → chunk-ZI46JBHS.js.map} +0 -0
  150. /package/client-dist/{chunk-PWAWM6DC.js.map → chunk-ZRLAS63L.js.map} +0 -0
  151. /package/client-dist/{consultant.module-WHGIMF6M.js.map → consultant.module-ZRSJ2JPM.js.map} +0 -0
  152. /package/client-dist/{crd.module-EH2RIMWD.js.map → crd.module-TDLM6M2Z.js.map} +0 -0
  153. /package/client-dist/{dashboard.module-EROOHU4C.js.map → dashboard.module-VSWWQDEU.js.map} +0 -0
  154. /package/client-dist/{do.module-PATPM2KZ.js.map → do.module-CCOHMJLG.js.map} +0 -0
  155. /package/client-dist/{document-library.module-QBW7XGNT.js.map → document-library.module-QLZ4ZUUG.js.map} +0 -0
  156. /package/client-dist/{embedding-eval.module-O4YXXNZE.js.map → embedding-eval.module-6KORAJ7D.js.map} +0 -0
  157. /package/client-dist/{embedding-registry.module-DOWVA6RV.js.map → embedding-registry.module-GJJ5G2Y7.js.map} +0 -0
  158. /package/client-dist/{err.module-AWN67SP6.js.map → err.module-4GLVR2GJ.js.map} +0 -0
  159. /package/client-dist/{feedback.module-BWKJCSTU.js.map → feedback.module-U6CCHRVZ.js.map} +0 -0
  160. /package/client-dist/{host-runtime-mcp.module-24MRZ77I.js.map → host-runtime-mcp.module-EV5GZKTL.js.map} +0 -0
  161. /package/client-dist/{live-dev-pipeline.module-T4EERACF.js.map → live-dev-pipeline.module-MWG23KAS.js.map} +0 -0
  162. /package/client-dist/{logs.module-O4MVHXRP.js.map → logs.module-YNDMPESQ.js.map} +0 -0
  163. /package/client-dist/{main-NP3NWD3C.js.map → main-OGUDQHPL.js.map} +0 -0
  164. /package/client-dist/{master-control-remote-poc.module-M6TNRCRQ.js.map → master-control-remote-poc.module-37OSJYRO.js.map} +0 -0
  165. /package/client-dist/{mobile-app.module-SW2L4EB3.js.map → mobile-app.module-2DXC7DFY.js.map} +0 -0
  166. /package/client-dist/{model-registry.module-MMEFDY3Y.js.map → model-registry.module-Z64FRB5O.js.map} +0 -0
  167. /package/client-dist/{oc.module-PVCITNSF.js.map → oc.module-6SHIJS3R.js.map} +0 -0
  168. /package/client-dist/{orc.module-2S5XXXZI.js.map → orc.module-NBZZGOV3.js.map} +0 -0
  169. /package/client-dist/{project-management.module-XD6NLN3S.js.map → project-management.module-TR33UVCV.js.map} +0 -0
  170. /package/client-dist/{project-source-routed.module-ZBU2T4Q5.js.map → project-source-routed.module-ZZ7SNTUN.js.map} +0 -0
  171. /package/client-dist/{scheduler.module-7YAZ6PYA.js.map → scheduler.module-M3LHP2DW.js.map} +0 -0
  172. /package/client-dist/{session.module-QNFMZPFT.js.map → session.module-FIZ5NYKK.js.map} +0 -0
  173. /package/client-dist/{set.module-QLYUFFRH.js.map → set.module-4E6WAYIQ.js.map} +0 -0
  174. /package/client-dist/{setup.module-HSVFOBYN.js.map → setup.module-2AUXXLIR.js.map} +0 -0
  175. /package/client-dist/{terminals.module-2NKJL3L6.js.map → terminals.module-GCGUOFVO.js.map} +0 -0
  176. /package/client-dist/{voice-notes-poc.module-VBWYBFHH.js.map → voice-notes-poc.module-6LVDT3MA.js.map} +0 -0
  177. /package/client-dist/{wfs.module-2ZF3S6F2.js.map → wfs.module-XQGZNMEP.js.map} +0 -0
@@ -1,4 +1,4 @@
1
- import{a as K,b as J,c as X}from"./chunk-4WGQS2HA.js";import{c as U,f as H,i as N,v as O}from"./chunk-EO4DNTT4.js";import{f as Q}from"./chunk-I4M7XPFX.js";import{$a as b,C as E,D as x,Fa as m,Ha as y,J as $,K as v,L as I,T as g,Ta as A,U as p,Z as a,aa as r,ab as F,da as f,ga as w,ha as T,hb as j,ia as W,ja as D,k as o,la as h,mb as B,oa as G,pa as q,qa as c,ra as u,sa as P,ua as R,ub as V,va as S,wa as d,y as M}from"./chunk-TBMJSIBB.js";var L=class s{static normalizeNewlines(l){return l.replace(/\r\n/g,`
1
+ import{a as K,b as J,c as X}from"./chunk-XC26T3JJ.js";import{c as U,f as H,i as N,v as O}from"./chunk-EO4DNTT4.js";import{f as Q}from"./chunk-SUAZOLRE.js";import{$a as b,C as E,D as x,Fa as m,Ha as y,J as $,K as v,L as I,T as g,Ta as A,U as p,Z as a,aa as r,ab as F,da as f,ga as w,ha as T,hb as j,ia as W,ja as D,k as o,la as h,mb as B,oa as G,pa as q,qa as c,ra as u,sa as P,ua as R,ub as V,va as S,wa as d,y as M}from"./chunk-TBMJSIBB.js";var L=class s{static normalizeNewlines(l){return l.replace(/\r\n/g,`
2
2
  `).replace(/\r/g,`
3
3
  `)}static sha256HexOfNormalized(l){return o(this,null,function*(){let e=s.normalizeNewlines(l),i=new TextEncoder().encode(e),n=yield crypto.subtle.digest("SHA-256",i),_=new Uint8Array(n),C="";for(let k=0;k<_.length;k+=1)C+=_[k].toString(16).padStart(2,"0");return C})}};var Y=(()=>{class s{projects_$=r([]);projectsLoading_$=r(!1);projectsError_$=r(null);projectsLoadedOnce_$=r(!1);activeProject_$=r(null);activeProjectComputedCcapHost_$=r(!1);activeProjectLoading_$=r(!1);activeProjectError_$=r(null);userRequests_$=r([]);userRequestsLoading_$=r(!1);userRequestsError_$=r(null);discoveredProjects_$=r([]);discoveryLoading_$=r(!1);discoveryError_$=r(null);gitStatusLoading_$=r(!1);gitStatusError_$=r(null);syncLoading_$=r(!1);syncError_$=r(null);lastSyncResult_$=r(null);fileContents_$=r(null);fileContentLoading_$=r(!1);fileContentError_$=r(null);testErrorReportsClearing_$=r(!1);agentReports_$=r([]);agentReportsLoading_$=r(!1);agentReportsError_$=r(null);activeAgentReport_$=r(null);activeAgentReportLoading_$=r(!1);activeAgentReportError_$=r(null);reviewsMeta_$=r([]);reviewsMetaLoading_$=r(!1);reviewsMetaError_$=r(null);reviewResult_$=r(null);reviewsRunning_$=r(!1);reviewsRunError_$=r(null);userInputWizardSuggestLoading_$=r(!1);userInputWizardSuggestError_$=r(null);userInputWizardFinalizeLoading_$=r(!1);userInputWizardFinalizeError_$=r(null);userInputWizardLastLlmSystemPrompt_$=r(null);userInputWizardLastLlmUserMessage_$=r(null);groups_$=r([]);groupsLoading_$=r(!1);groupsError_$=r(null);activeGroup_$=r(null);groupFiles_$=r(null);groupFilesLoading_$=r(!1);groupFilesError_$=r(null);crossInstanceProjects_$=r([]);crossInstanceLoading_$=r(!1);crossInstanceError_$=r(null);currentCcapId_$=r(null);cloneLoading_$=r(!1);cloneError_$=r(null);pm_AS=E(Q);loadProjects(){return o(this,null,function*(){this.projectsLoading_$.set(!0),this.projectsError_$.set(null);try{let e=yield this.pm_AS.listProjects();this.projects_$.set(e.projects),this.projectsLoadedOnce_$.set(!0)}catch(e){this.projectsError_$.set(e)}finally{this.projectsLoading_$.set(!1)}})}loadProject(e){return o(this,null,function*(){this.activeProjectLoading_$.set(!0),this.activeProjectError_$.set(null);try{let t=yield this.pm_AS.getProject(e);this.activeProject_$.set(t.project),this.activeProjectComputedCcapHost_$.set(t.computedCcapRevisionedHost)}catch(t){this.activeProjectError_$.set(t)}finally{this.activeProjectLoading_$.set(!1)}})}createProject(e){return o(this,null,function*(){let t=yield this.pm_AS.createProject(e);return yield this.loadProjects(),t.project})}updateProject(e,t){return o(this,null,function*(){let i=yield this.pm_AS.updateProject(e,t);this.activeProject_$.set(i.project),this.activeProjectComputedCcapHost_$.set(i.computedCcapRevisionedHost),this.projects_$.update(n=>n.map(_=>_._id===e?i.project:_))})}archiveProject(e){return o(this,null,function*(){yield this.pm_AS.archiveProject(e),yield this.loadProjects(),this.activeProject_$()?._id===e&&(this.activeProject_$.set(null),this.activeProjectComputedCcapHost_$.set(!1))})}loadGroups(){return o(this,null,function*(){this.groupsLoading_$.set(!0),this.groupsError_$.set(null);try{let e=yield this.pm_AS.listGroups();this.groups_$.set(e.groups)}catch(e){this.groupsError_$.set(e)}finally{this.groupsLoading_$.set(!1)}})}createGroup(e){return o(this,null,function*(){yield this.pm_AS.createGroup(e),yield this.loadGroups()})}archiveGroup(e){return o(this,null,function*(){yield this.pm_AS.archiveGroup(e),this.activeGroup_$()?._id===e&&this.activeGroup_$.set(null),yield this.loadGroups()})}selectGroup(e){this.activeGroup_$.set(e)}loadGroupFiles(e){return o(this,null,function*(){this.groupFilesLoading_$.set(!0),this.groupFilesError_$.set(null);try{let t=yield this.pm_AS.getGroupFiles(e);this.groupFiles_$.set(t)}catch(t){this.groupFilesError_$.set(t)}finally{this.groupFilesLoading_$.set(!1)}})}loadCrossInstanceProjects(){return o(this,null,function*(){this.crossInstanceLoading_$.set(!0),this.crossInstanceError_$.set(null);try{let e=yield this.pm_AS.listAllProjectsAcrossInstances();this.crossInstanceProjects_$.set(e.projects),this.currentCcapId_$.set(e.currentCcapId)}catch(e){this.crossInstanceError_$.set(e)}finally{this.crossInstanceLoading_$.set(!1)}})}cloneProject(e){return o(this,null,function*(){this.cloneLoading_$.set(!0),this.cloneError_$.set(null);try{yield this.pm_AS.cloneProject({sourceProjectId:e.sourceProjectId,targetParentDir:e.targetParentDir,repoName:e.repoName}),yield this.loadProjects()}catch(t){this.cloneError_$.set(t)}finally{this.cloneLoading_$.set(!1)}})}cloneGroup(e){return o(this,null,function*(){this.cloneLoading_$.set(!0),this.cloneError_$.set(null);try{yield this.pm_AS.cloneGroup({sourceGroupId:e.sourceGroupId,targetParentDir:e.targetParentDir}),yield this.loadProjects(),yield this.loadGroups()}catch(t){this.cloneError_$.set(t)}finally{this.cloneLoading_$.set(!1)}})}discoverProjects(e){return o(this,null,function*(){this.discoveryLoading_$.set(!0),this.discoveryError_$.set(null),this.discoveredProjects_$.set([]);try{let t=yield this.pm_AS.discoverProjects(e);this.discoveredProjects_$.set(t.discoveredProjects)}catch(t){this.discoveryError_$.set(t)}finally{this.discoveryLoading_$.set(!1)}})}createDiscoveredProjects(e){return o(this,null,function*(){for(let t of e){let i={name:t.name,localPath:t.localPath,description:t.description,githubRepoUrl:t.githubRepoUrl,isActive:!0};yield this.pm_AS.createProject(i)}yield this.loadProjects()})}clearDiscovery(){this.discoveredProjects_$.set([]),this.discoveryError_$.set(null),this.discoveryLoading_$.set(!1)}refreshGitStatus(e){return o(this,null,function*(){this.gitStatusLoading_$.set(!0),this.gitStatusError_$.set(null);try{let t=yield this.pm_AS.refreshGitStatus(e);this.activeProject_$.set(t.project);try{let i=yield this.pm_AS.getProject(e);this.activeProjectComputedCcapHost_$.set(i.computedCcapRevisionedHost)}catch{}this.projects_$.update(i=>i.map(n=>n._id===e?t.project:n))}catch(t){this.gitStatusError_$.set(t)}finally{this.gitStatusLoading_$.set(!1)}})}syncProject(e){return o(this,null,function*(){this.syncLoading_$.set(!0),this.syncError_$.set(null),this.lastSyncResult_$.set(null);try{let t=yield this.pm_AS.syncProject(e);this.lastSyncResult_$.set(t.syncResult),this.activeProject_$.set(t.project);try{let i=yield this.pm_AS.getProject(e);this.activeProjectComputedCcapHost_$.set(i.computedCcapRevisionedHost)}catch{}this.projects_$.update(i=>i.map(n=>n._id===e?t.project:n))}catch(t){this.syncError_$.set(t)}finally{this.syncLoading_$.set(!1)}})}syncAllProjects(){return o(this,null,function*(){this.syncLoading_$.set(!0),this.syncError_$.set(null);try{yield this.pm_AS.syncAllProjects(),yield this.loadProjects()}catch(e){this.syncError_$.set(e)}finally{this.syncLoading_$.set(!1)}})}loadAllFileContents(e){return o(this,null,function*(){this.fileContentLoading_$.set(!0),this.fileContentError_$.set(null);try{let t=yield this.pm_AS.getAllFileContents(e);this.fileContents_$.set(t.files)}catch(t){this.fileContentError_$.set(t)}finally{this.fileContentLoading_$.set(!1)}})}clearTestErrorReportsAndRefresh(e){return o(this,null,function*(){this.testErrorReportsClearing_$.set(!0);try{yield this.pm_AS.clearTestErrorReports(e),yield this.loadAllFileContents(e)}finally{this.testErrorReportsClearing_$.set(!1)}})}getBugsPathResolve(e){return o(this,null,function*(){return this.pm_AS.getBugsPathResolve(e)})}appendBugsFromErrorsAndRefreshFiles(e,t){return o(this,null,function*(){let i=yield this.pm_AS.appendBugsFromErrors(e,t);return yield this.loadAllFileContents(e),i})}appendSingleBugFromErrorAndRefreshFiles(e,t,i){return o(this,null,function*(){let n=yield this.pm_AS.appendSingleBugFromError(e,t,i);return yield this.loadAllFileContents(e),n})}createManualBugAndRefresh(e,t){return o(this,null,function*(){let i=yield this.pm_AS.createManualBug(e,t);return yield this.loadAllFileContents(e),yield this.loadUserRequests(e),i})}loadUserRequests(e){return o(this,null,function*(){this.userRequestsLoading_$.set(!0),this.userRequestsError_$.set(null);try{let t=yield this.pm_AS.listUserRequests(e);this.userRequests_$.set(t.userRequests)}catch(t){this.userRequestsError_$.set(t)}finally{this.userRequestsLoading_$.set(!1)}})}createUserRequest(e,t){return o(this,null,function*(){yield this.pm_AS.createUserRequest(e,t),yield this.loadUserRequests(e)})}updateUserRequest(e,t,i){return o(this,null,function*(){let n=yield this.pm_AS.updateUserRequest(e,t,i);this.userRequests_$.update(_=>_.map(C=>C._id===t?n.userRequest:C))})}suggestUserInputFormat(e,t){return o(this,null,function*(){this.userInputWizardSuggestLoading_$.set(!0),this.userInputWizardSuggestError_$.set(null),this.userInputWizardLastLlmSystemPrompt_$.set(null),this.userInputWizardLastLlmUserMessage_$.set(null);try{let i=yield this.pm_AS.suggestUserInputFormat(e,t);return this.userInputWizardLastLlmSystemPrompt_$.set(i.llmSystemPrompt??null),this.userInputWizardLastLlmUserMessage_$.set(i.llmUserMessage??null),i}catch(i){throw this.userInputWizardSuggestError_$.set(i),i}finally{this.userInputWizardSuggestLoading_$.set(!1)}})}mutateControlFileEntryAndRefresh(e,t,i){return o(this,null,function*(){let n=i.priorRawFingerprintSha256?.trim(),_=n!=null&&n.length>0?n:yield L.sha256HexOfNormalized(i.priorRawBlock),C={mode:i.mode,priorRawBlock:i.priorRawBlock,priorRawFingerprintSha256:_,newRawBlock:i.newRawBlock,bugsFileAbsolutePath:i.bugsFileAbsolutePath},k=yield this.pm_AS.mutateControlFileEntry(e,t,C);return yield this.loadAllFileContents(e),k})}finalizeUserInputWizard(e,t){return o(this,null,function*(){this.userInputWizardFinalizeLoading_$.set(!0),this.userInputWizardFinalizeError_$.set(null);try{let i=yield this.pm_AS.finalizeUserInput(e,t);return yield this.loadUserRequests(e),yield this.loadAllFileContents(e),i}catch(i){throw this.userInputWizardFinalizeError_$.set(i),i}finally{this.userInputWizardFinalizeLoading_$.set(!1)}})}loadReviewsMeta(e){return o(this,null,function*(){this.reviewsMetaLoading_$.set(!0),this.reviewsMetaError_$.set(null);try{let t=yield this.pm_AS.getReviewsMeta(e);this.reviewsMeta_$.set(t.reviewsMeta)}catch(t){this.reviewsMetaError_$.set(t)}finally{this.reviewsMetaLoading_$.set(!1)}})}runProjectReviews(e,t){return o(this,null,function*(){this.reviewsRunning_$.set(!0),this.reviewsRunError_$.set(null),this.reviewResult_$.set(null);try{let i=yield this.pm_AS.runProjectReviews(e,t);this.reviewResult_$.set(i.reviewResult)}catch(i){this.reviewsRunError_$.set(i)}finally{this.reviewsRunning_$.set(!1)}})}loadAgentReports(e){return o(this,null,function*(){this.agentReportsLoading_$.set(!0),this.agentReportsError_$.set(null);try{let t=yield this.pm_AS.listAgentReports(e);this.agentReports_$.set(t.reports)}catch(t){this.agentReportsError_$.set(t)}finally{this.agentReportsLoading_$.set(!1)}})}loadAgentReport(e,t){return o(this,null,function*(){this.activeAgentReportLoading_$.set(!0),this.activeAgentReportError_$.set(null);try{let i=yield this.pm_AS.getAgentReportContent(e,t);this.activeAgentReport_$.set(i)}catch(i){this.activeAgentReport_$.set(null),this.activeAgentReportError_$.set(i)}finally{this.activeAgentReportLoading_$.set(!1)}})}clearActiveAgentReport(){this.activeAgentReport_$.set(null),this.activeAgentReportError_$.set(null)}static \u0275fac=function(t){return new(t||s)};static \u0275prov=M({token:s,factory:s.\u0275fac,providedIn:"root"})}return s})();function te(s,l){if(s&1&&(c(0,"span",0),m(1),u()),s&2){let e=l;w("title",e),a(),y(" ",e," ")}}var Z=(()=>{class s{workspacePath=p(void 0);pm_DS=E(Y);projectName_$=j(()=>{let e=this.workspacePath();if(!e)return null;let t=s.normalizePath(e);return t?this.pm_DS.projects_$().find(_=>!!_.localPath&&s.normalizePath(_.localPath)===t)?.name??null:null});constructor(){!this.pm_DS.projectsLoadedOnce_$()&&!this.pm_DS.projectsLoading_$()&&!this.pm_DS.projectsError_$()&&this.pm_DS.loadProjects()}static normalizePath(e){let t=e.trim().toLowerCase().replace(/\\/g,"/");for(;t.endsWith("/")&&t.length>1;)t=t.slice(0,-1);return t}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=x({type:s,selectors:[["app-s-project-badge"]],hostAttrs:[1,"ml-auto"],hostVars:2,hostBindings:function(t,i){t&2&&T("display",i.projectName_$()?"inline-flex":"none")},inputs:{workspacePath:[1,"workspacePath"]},standalone:!0,features:[A],decls:1,vars:1,consts:[[1,"text-[9px]","px-1","py-0.5","rounded","bg-sky-500/20","text-sky-300","border","border-sky-500/30","shrink-0","truncate","max-w-[140px]",3,"title"]],template:function(t,i){if(t&1&&f(0,te,2,2,"span",0),t&2){let n;h((n=i.projectName_$())?0:-1,n)}},encapsulation:2})}return s})();function ie(s,l){s&1&&P(0,"span",4)}function se(s,l){if(s&1&&P(0,"app-s-project-badge",7),s&2){let e=d();w("workspacePath",e.view().workspacePath)}}function re(s,l){s&1&&(c(0,"span",8),m(1," archived "),u())}function ne(s,l){if(s&1){let e=R();c(0,"button",13),S("click",function(i){$(e);let n=d();return v(n.handleScheduleIndicatorClick(i))}),I(),c(1,"svg",14),P(2,"rect",15)(3,"line",16)(4,"line",17)(5,"line",18),u()()}}function oe(s,l){if(s&1){let e=R();c(0,"button",19),S("click",function(i){$(e);let n=d();return v(n.handleCoordinatorIndicatorClick(i))}),I(),c(1,"svg",14),P(2,"circle",20)(3,"polygon",21),u()()}}function ae(s,l){if(s&1&&(c(0,"div",11),m(1),u()),s&2){let e=d();a(),y(" ",e.view().workspacePath," ")}}function le(s,l){if(s&1&&(c(0,"div",12)(1,"span",22),m(2),u()()),s&2){let e=d();a(2),y(" ",e.view().promptCount," prompts ")}}var ee=(()=>{class s{view=p.required();isActive=p(!1);showWorkspacePath=p(!1);showPromptCount=p(!1);selected=g();contextMenu=g();scheduleIndicatorClicked=g();coordinatorIndicatorClicked=g();handleSelect(){this.selected.emit(this.view().id)}handleContextMenu(e){e.preventDefault(),e.stopPropagation(),this.contextMenu.emit({event:e,id:this.view().id})}handleScheduleIndicatorClick(e){e.stopPropagation(),this.scheduleIndicatorClicked.emit(this.view().id)}handleCoordinatorIndicatorClick(e){e.stopPropagation(),this.coordinatorIndicatorClicked.emit(this.view().id)}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=x({type:s,selectors:[["app-s-session-list-row"]],hostAttrs:[1,"block"],inputs:{view:[1,"view"],isActive:[1,"isActive"],showWorkspacePath:[1,"showWorkspacePath"],showPromptCount:[1,"showPromptCount"]},outputs:{selected:"selected",contextMenu:"contextMenu",scheduleIndicatorClicked:"scheduleIndicatorClicked",coordinatorIndicatorClicked:"coordinatorIndicatorClicked"},standalone:!0,features:[A],decls:17,vars:20,consts:[[1,"px-2","py-1.5","border-b","cursor-pointer","transition-colors",3,"click","contextmenu"],[1,"flex","items-center","gap-1.5"],[1,"relative","w-3.5","h-3.5","shrink-0","flex","items-center","justify-center",3,"title"],[1,"w-1.5","h-1.5","rounded-full",3,"ngClass"],[1,"absolute","inset-0","rounded-full","border","border-transparent","border-t-yellow-400","animate-spin"],[1,"text-xs","text-neutral-200","font-medium","truncate","shrink-1","min-w-0"],[1,"text-[10px]","text-neutral-400","shrink-0",3,"title"],[3,"workspacePath"],[1,"text-[8px]","px-0.5","rounded","bg-amber-500/15","text-amber-500","shrink-0"],["type","button","title","Ehhez a session-h\xF6z tartozik schedule \u2014 kattints a r\xE9szletek\xE9rt","aria-label","Schedule attached \u2014 open popup",1,"shrink-0","text-neonCyan/80","hover:text-neonCyan","focus:outline-none","focus:ring-1","focus:ring-neonCyan/60","rounded","p-0.5"],["type","button","title","Ehhez a session-h\xF6z tartozik koordin\xE1tor \u2014 kattints a r\xE9szletek\xE9rt","aria-label","Coordinator attached \u2014 open popup",1,"shrink-0","text-neonAmber/80","hover:text-neonAmber","focus:outline-none","focus:ring-1","focus:ring-neonAmber/60","rounded","p-0.5"],[1,"text-[10px]","text-neutral-500","truncate","mt-0.5","ml-5"],[1,"flex","items-center","gap-2","mt-0.5","ml-5"],["type","button","title","Ehhez a session-h\xF6z tartozik schedule \u2014 kattints a r\xE9szletek\xE9rt","aria-label","Schedule attached \u2014 open popup",1,"shrink-0","text-neonCyan/80","hover:text-neonCyan","focus:outline-none","focus:ring-1","focus:ring-neonCyan/60","rounded","p-0.5",3,"click"],["viewBox","0 0 24 24","fill","none","stroke","currentColor","stroke-width","2","stroke-linecap","round","stroke-linejoin","round","aria-hidden","true",1,"w-3","h-3"],["x","3","y","4","width","18","height","18","rx","2","ry","2"],["x1","16","y1","2","x2","16","y2","6"],["x1","8","y1","2","x2","8","y2","6"],["x1","3","y1","10","x2","21","y2","10"],["type","button","title","Ehhez a session-h\xF6z tartozik koordin\xE1tor \u2014 kattints a r\xE9szletek\xE9rt","aria-label","Coordinator attached \u2014 open popup",1,"shrink-0","text-neonAmber/80","hover:text-neonAmber","focus:outline-none","focus:ring-1","focus:ring-neonAmber/60","rounded","p-0.5",3,"click"],["cx","12","cy","12","r","10"],["points","16.24 7.76 14.12 14.12 7.76 16.24 9.88 9.88 16.24 7.76"],[1,"text-[10px]","text-neutral-600"]],template:function(t,i){if(t&1&&(c(0,"div",0),S("click",function(){return i.handleSelect()})("contextmenu",function(_){return i.handleContextMenu(_)}),c(1,"div",1)(2,"span",2),P(3,"span",3),f(4,ie,1,0,"span",4),u(),c(5,"span",5),m(6),u(),c(7,"span",6),b(8,"sAbsoluteTime"),m(9),b(10,"sTimeAgo"),u(),f(11,se,1,1,"app-s-project-badge",7)(12,re,2,0,"span",8)(13,ne,6,0,"button",9)(14,oe,4,0,"button",10),u(),f(15,ae,2,1,"div",11)(16,le,3,1,"div",12),u()),t&2){let n;D(i.isActive()?"border-l-2 border-l-ccapAccent border-b-neutral-700/30 bg-neutral-800/80":"border-l-2 border-l-transparent border-b-neutral-700/30 hover:bg-neutral-800/60"),W("opacity-50",i.view().isArchived),a(2),w("title",i.view().status),a(),w("ngClass",i.view().statusColorClass),a(),h(i.view().isRunning?4:-1),a(2),y(" ",i.view().label," "),a(),w("title",F(8,16,(n=i.view().lastActivityAt)!==null&&n!==void 0?n:"")),a(2),y(" ",i.view().lastActivityAt?F(10,18,i.view().lastActivityAt):"\u2014"," "),a(2),h(i.view().workspacePath?11:-1),a(),h(i.view().isArchived?12:-1),a(),h(i.view().hasSchedule?13:-1),a(),h(i.view().hasCoordinator?14:-1),a(),h(i.showWorkspacePath()&&i.view().workspacePath?15:-1),a(),h(i.showPromptCount()&&i.view().promptCount?16:-1)}},dependencies:[B,J,X,Z],encapsulation:2})}return s})();var ce=(s,l)=>l.id;function ue(s,l){if(s&1){let e=R();c(0,"div",1)(1,"input",5),S("ngModelChange",function(i){$(e);let n=d();return v(n.searchQuery_$.set(i))}),u()()}if(s&2){let e=d();a(),w("placeholder",e.searchPlaceholder())("ngModel",e.searchQuery_$())}}function pe(s,l){if(s&1){let e=R();c(0,"app-s-session-list-row",6),S("selected",function(i){$(e);let n=d();return v(n.handleRowSelect(i))})("contextMenu",function(i){$(e);let n=d();return v(n.handleRowContextMenu(i))})("scheduleIndicatorClicked",function(i){$(e);let n=d();return v(n.handleRowScheduleIndicatorClick(i))})("coordinatorIndicatorClicked",function(i){$(e);let n=d();return v(n.handleRowCoordinatorIndicatorClick(i))}),u()}if(s&2){let e=l.$implicit,t=d();w("view",e)("isActive",e.id===t.activeId())("showWorkspacePath",t.showWorkspacePath())("showPromptCount",t.showPromptCount())}}function de(s,l){s&1&&m(0," Nincs tal\xE1lat. ")}function _e(s,l){s&1&&m(0," \xDCres lista. ")}function he(s,l){if(s&1&&(c(0,"span",4),f(1,de,1,0)(2,_e,1,0),u()),s&2){let e=d();a(),h(e.searchQuery_$().trim().length>0?1:2)}}var qe=(()=>{class s{kind=p.required();rows=p([]);activeId=p("");showWorkspacePath=p(!1);showPromptCount=p(!1);searchPlaceholder=p("Keres\xE9s...");hideSearch=p(!1);selected=g();contextMenu=g();scheduleIndicatorClicked=g();coordinatorIndicatorClicked=g();searchQuery_$=r("");filteredRows_$=j(()=>{let e=this.rows();if(this.hideSearch())return e;let t=this.searchQuery_$();return t.trim().length===0?e:e.filter(i=>K.includesText(i.label,t))});handleRowSelect(e){this.selected.emit(e)}handleRowContextMenu(e){this.contextMenu.emit(e)}handleRowScheduleIndicatorClick(e){this.scheduleIndicatorClicked.emit(e)}handleRowCoordinatorIndicatorClick(e){this.coordinatorIndicatorClicked.emit(e)}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=x({type:s,selectors:[["app-s-session-select"]],hostAttrs:[1,"block"],inputs:{kind:[1,"kind"],rows:[1,"rows"],activeId:[1,"activeId"],showWorkspacePath:[1,"showWorkspacePath"],showPromptCount:[1,"showPromptCount"],searchPlaceholder:[1,"searchPlaceholder"],hideSearch:[1,"hideSearch"]},outputs:{selected:"selected",contextMenu:"contextMenu",scheduleIndicatorClicked:"scheduleIndicatorClicked",coordinatorIndicatorClicked:"coordinatorIndicatorClicked"},standalone:!0,features:[A],decls:6,vars:2,consts:[[1,"flex","flex-col","gap-2"],[1,"px-2","pt-2"],[1,"flex","flex-col","gap-1","px-2","pb-2"],[3,"view","isActive","showWorkspacePath","showPromptCount"],[1,"text-[11px]","text-neutral-500","italic","px-1","py-2"],["type","text","data-testid","s-session-select-search",1,"w-full","px-2","py-1","text-xs","rounded","border","border-neonDefault","bg-neutral-900","text-neutral-200","placeholder-neutral-500","focus:outline-none","focus:border-ccapAccent",3,"ngModelChange","placeholder","ngModel"],[3,"selected","contextMenu","scheduleIndicatorClicked","coordinatorIndicatorClicked","view","isActive","showWorkspacePath","showPromptCount"]],template:function(t,i){t&1&&(c(0,"div",0),f(1,ue,2,2,"div",1),c(2,"div",2),G(3,pe,1,4,"app-s-session-list-row",3,ce),f(5,he,3,1,"span",4),u()()),t&2&&(a(),h(i.hideSearch()?-1:1),a(2),q(i.filteredRows_$()),a(2),h(i.filteredRows_$().length===0?5:-1))},dependencies:[V,O,U,H,N,ee],encapsulation:2})}return s})();export{Y as a,ee as b,qe as c};
4
- //# sourceMappingURL=chunk-PWAWM6DC.js.map
4
+ //# sourceMappingURL=chunk-ZRLAS63L.js.map
@@ -1,3 +1,3 @@
1
- import"./chunk-EGRHWZRV.js";import{a as Ve}from"./chunk-Q2PKIGLB.js";import{a as we}from"./chunk-JGLBYLWW.js";import{a as Ie,b as X}from"./chunk-MMFURH5P.js";import"./chunk-VEPJ3MZH.js";import{g as Re}from"./chunk-C75AJJFP.js";import"./chunk-SBPFNYFT.js";import"./chunk-7JUIBZEE.js";import{a as Pe,b as Ee,c as q}from"./chunk-C7XPBJTG.js";import{b as te,f as ke,g as Ae}from"./chunk-Q2WNI354.js";import"./chunk-WPHEQXWB.js";import{b as Me}from"./chunk-PWAWM6DC.js";import"./chunk-4WGQS2HA.js";import"./chunk-AE5VAS75.js";import"./chunk-TSGXTLGO.js";import"./chunk-Q2NVIOCY.js";import{a as De}from"./chunk-3HWZLIS3.js";import{a as ee}from"./chunk-J32YRK3S.js";import"./chunk-KB2F332Z.js";import"./chunk-RV3A7THL.js";import"./chunk-N7HJWJ2S.js";import"./chunk-V3VQWJQL.js";import"./chunk-WDSKSHR7.js";import"./chunk-FVNI46U2.js";import"./chunk-ZBTWQZNB.js";import"./chunk-FLAJXIYW.js";import{b as ve,c as N,f as W,i as B,n as z,o as j,p as H,v as Se}from"./chunk-EO4DNTT4.js";import{k as Te}from"./chunk-I4M7XPFX.js";import{a as V}from"./chunk-5UPNU54P.js";import{j as ye}from"./chunk-WXN5C3BS.js";import{I as $e}from"./chunk-5N64HGRY.js";import{Aa as he,Ba as me,C as x,D as I,E as se,Eb as xe,Fa as _,Fb as ge,Ga as k,Gb as U,J as m,K as u,Kb as be,L as le,M as de,Z as d,aa as l,ca as ce,da as M,ga as f,ha as _e,hb as b,ia as R,jb as ue,k as C,la as y,na as P,oa as S,p as v,pa as $,q as re,qa as r,ra as s,sa as w,ua as E,ub as fe,va as h,wa as c,xb as Ce,y as F,z as ae,za as pe}from"./chunk-TBMJSIBB.js";var Q="ccap-consultant",T=class{static savePanelOpen(a,e){V.writeBoolean(`${Q}:panelOpen:${a}`,e)}static loadPanelOpen(a,e){return V.readBoolean(`${Q}:panelOpen:${a}`,e)}static savePanelWidth(a,e){V.writeNumber(`${Q}:panelWidth:${a}`,e)}static loadPanelWidth(a,e){return V.readNumber(`${Q}:panelWidth:${a}`,e)}};var Oe=(()=>{class i{baseUrl=`${$e.api.baseUrl}/consultant`;http=x(Ce);listThreads(){return v(this.http.get(this.baseUrl))}getPickerOptions(){return v(this.http.get(`${this.baseUrl}/picker-options`))}createThread(e){return v(this.http.post(this.baseUrl,e))}getThread(e){return v(this.http.get(`${this.baseUrl}/${encodeURIComponent(e)}`))}patchThread(e){let t={};return e.label!=null&&(t.label=e.label),e.providerInstanceId!=null&&(t.providerInstanceId=e.providerInstanceId),e.model!=null&&(t.model=e.model),v(this.http.patch(`${this.baseUrl}/${encodeURIComponent(e.threadId)}`,t))}deleteThread(e){return v(this.http.delete(`${this.baseUrl}/${encodeURIComponent(e)}`))}postMessage(e){return v(this.http.post(`${this.baseUrl}/${encodeURIComponent(e.threadId)}/messages`,{text:e.text,allowWebSearch:e.allowWebSearch,attachments:e.attachments}))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=F({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var G=(()=>{class i{consultant_AS=x(Oe);globalError_CS=x(ye);threads_$=l([]);threadsLoading_$=l(!1);threadsError_$=l(null);selectedThread_$=l(null);selectedThreadLoading_$=l(!1);selectedThreadError_$=l(null);sending_$=l(!1);activeThreadId_$=l("");defaults_$=l({providerInstanceId:"",model:""});pickerOptions_$=l([]);pickerOptionsLoading_$=l(!1);loadPickerOptions(){return C(this,null,function*(){this.pickerOptionsLoading_$.set(!0);try{let e=yield this.consultant_AS.getPickerOptions(),t=Array.isArray(e.entries)?e.entries.map(i.parseRegistryEntry).filter(n=>n!==null):[];this.pickerOptions_$.set(t),this.defaults_$.set({providerInstanceId:typeof e.defaults?.providerInstanceId=="string"?e.defaults.providerInstanceId:"",model:typeof e.defaults?.model=="string"?e.defaults.model:""})}catch(e){this.globalError_CS.showError(e,"Consultant_DataService.loadPickerOptions")}finally{this.pickerOptionsLoading_$.set(!1)}})}loadThreads(){return C(this,null,function*(){this.threadsLoading_$.set(!0),this.threadsError_$.set(null);try{let e=yield this.consultant_AS.listThreads(),n=(Array.isArray(e.threads)?e.threads:[]).map(o=>({threadId:typeof o.threadId=="string"?o.threadId:"",label:typeof o.label=="string"?o.label:"",providerInstanceId:typeof o.providerInstanceId=="string"?o.providerInstanceId:"",model:typeof o.model=="string"?o.model:"",messageCount:typeof o.messageCount=="number"?o.messageCount:0,updatedAt:typeof o.updatedAt=="string"?o.updatedAt:""}));this.threads_$.set(n)}catch(e){this.threadsError_$.set(e),this.globalError_CS.showError(e,"Consultant_DataService.loadThreads")}finally{this.threadsLoading_$.set(!1)}})}loadThreadDetail(e){return C(this,null,function*(){this.activeThreadId_$.set(e),this.selectedThreadLoading_$.set(!0),this.selectedThreadError_$.set(null);try{let t=yield this.consultant_AS.getThread(e),n=i.parseThreadDetail(t.thread);this.selectedThread_$.set(n)}catch(t){this.selectedThreadError_$.set(t),this.globalError_CS.showError(t,"Consultant_DataService.loadThreadDetail")}finally{this.selectedThreadLoading_$.set(!1)}})}sendMessage(e){return C(this,null,function*(){this.sending_$.set(!0);try{let n=(yield this.consultant_AS.postMessage(e)).thread;if(i.isPlainRecord(n)){let o=i.parseThreadDetail(n);this.selectedThread_$.set(o)}yield this.loadThreads()}catch(t){throw this.globalError_CS.showError(t,"Consultant_DataService.sendMessage"),t}finally{this.sending_$.set(!1)}})}updateThreadConfig(e){return C(this,null,function*(){try{let t=yield this.consultant_AS.patchThread(e),n=i.parseThreadDetail(t.thread);this.selectedThread_$.set(n),yield this.loadThreads()}catch(t){throw this.globalError_CS.showError(t,"Consultant_DataService.updateThreadConfig"),t}})}createThread(e){return C(this,null,function*(){try{let n=(yield this.consultant_AS.createThread(e)).thread.threadId,o=typeof n=="string"?n:"";return yield this.loadThreads(),o}catch(t){throw this.globalError_CS.showError(t,"Consultant_DataService.createThread"),t}})}deleteThread(e){return C(this,null,function*(){try{yield this.consultant_AS.deleteThread(e),this.activeThreadId_$()===e&&(this.selectedThread_$.set(null),this.activeThreadId_$.set("")),yield this.loadThreads()}catch(t){throw this.globalError_CS.showError(t,"Consultant_DataService.deleteThread"),t}})}static parseThreadDetail(e){let t=typeof e.threadId=="string"?e.threadId:"";if(!t.length)return null;let n=e.messages,o=[];if(Array.isArray(n))for(let p of n){if(!i.isPlainRecord(p))continue;let A=typeof p.id=="string"?p.id:"",Y=p.role;if(Y!=="user"&&Y!=="assistant")continue;let L={id:A,role:Y};typeof p.rawUserText=="string"&&(L.rawUserText=p.rawUserText),typeof p.content=="string"&&(L.content=p.content);let ie=p.userParts;if(Array.isArray(ie)){let oe=[];for(let D of ie){if(!i.isPlainRecord(D))continue;let J=D.type;if(J!=="text"&&J!=="image_url")continue;let Z={type:J};typeof D.text=="string"&&(Z.text=D.text),typeof D.imageUrl=="string"&&(Z.imageUrl=D.imageUrl),oe.push(Z)}L.userParts=oe}o.push(L)}return{threadId:t,label:typeof e.label=="string"?e.label:"",providerInstanceId:typeof e.providerInstanceId=="string"?e.providerInstanceId:"",model:typeof e.model=="string"?e.model:"",messages:o,updatedAt:typeof e.updatedAt=="string"?e.updatedAt:""}}static isPlainRecord(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}static parseRegistryEntry(e){if(!i.isPlainRecord(e))return null;let t=typeof e.provider=="string"?e.provider:"",n=typeof e.modelName=="string"?e.modelName:"";if(!t.length||!n.length)return null;let o=e.capabilities,p=Array.isArray(o)?o.filter(A=>typeof A=="string"):void 0;return{id:typeof e.id=="string"?e.id:"",provider:t,modelName:n,enabled:e.enabled===!0,capabilities:p}}static \u0275fac=function(t){return new(t||i)};static \u0275prov=F({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var g=class{static collectSortedProviders(a){let e=new Set;for(let t of a){let n=t.provider.trim();n.length>0&&e.add(n)}return[...e].sort()}static collectSortedModelsForProvider(a,e){let t=e.trim();if(!t.length)return[];let n=[];for(let o of a){let p=o.modelName.trim();o.provider===t&&p.length>0&&n.push(p)}return[...new Set(n)].sort()}};var ze=(i,a)=>a.id;function je(i,a){i&1&&(r(0,"div",5),_(1,"Loading..."),s())}function He(i,a){if(i&1){let e=E();r(0,"app-s-session-list-row",9),h("selected",function(n){m(e);let o=c(2);return u(o.handleSelectThread(n))})("contextMenu",function(n){m(e);let o=c(2);return u(o.handleRowContextMenu(n))}),s()}if(i&2){let e=a.$implicit,t=c(2);f("view",e)("isActive",t.consultant_DS.activeThreadId_$()===e.id)}}function Xe(i,a){if(i&1&&S(0,He,1,2,"app-s-session-list-row",8,ze),i&2){let e=c();$(e.threadRowViews_$())}}function qe(i,a){i&1&&(r(0,"div",6),_(1,"No threads"),s())}function Qe(i,a){if(i&1&&(r(0,"option",16),_(1),s()),i&2){let e=a.$implicit,t=c(2);f("value",e),d(),k(t.providerDisplayLabelsMap_$()[e]||e)}}function Ge(i,a){if(i&1&&(r(0,"option",16),_(1),s()),i&2){let e=a.$implicit;f("value",e),d(),k(e)}}function Ke(i,a){if(i&1){let e=E();r(0,"div",10),h("click",function(){m(e);let n=c();return u(n.handleCloseCreate())}),r(1,"div",11),h("click",function(n){return m(e),u(n.stopPropagation())}),r(2,"h3",12),_(3,"New consultant thread"),s(),r(4,"div",13)(5,"label",14),_(6,"Label (optional)"),s(),r(7,"input",15),h("ngModelChange",function(n){m(e);let o=c();return u(o.newLabel_$.set(n))}),s(),r(8,"label",14),_(9,"Provider"),s(),r(10,"select",15),h("ngModelChange",function(n){m(e);let o=c();return u(o.handleProviderChange(n))}),S(11,Qe,2,2,"option",16,P),s(),r(13,"label",14),_(14,"Model"),s(),r(15,"select",15),h("ngModelChange",function(n){m(e);let o=c();return u(o.newModel_$.set(n))}),S(16,Ge,2,2,"option",16,P),s()(),r(18,"div",17)(19,"button",18),h("click",function(){m(e);let n=c();return u(n.handleCloseCreate())}),_(20," Cancel "),s(),r(21,"button",19),h("click",function(){m(e);let n=c();return u(n.handleCreateThread())}),_(22," Create "),s()()()()}if(i&2){let e=c();d(7),f("ngModel",e.newLabel_$()),d(3),f("ngModel",e.newProvider_$()),d(),$(e.providerOptions_$()),d(4),f("ngModel",e.newModel_$()),d(),$(e.modelsForNewProvider_$()),d(5),f("disabled",e.isCreating_$()||!e.newProvider_$().trim()||!e.newModel_$().trim())}}function Ye(i,a){if(i&1){let e=E();r(0,"div",20),h("click",function(){m(e);let n=c();return u(n.handleCloseCtxMenu())}),s(),r(1,"div",21)(2,"button",22),h("click",function(){m(e);let n=c();return u(n.handleCtxDelete())}),_(3," Delete "),s()()}if(i&2){let e=c();d(),_e("left",e.ctxMenuPos_$().x,"px")("top",e.ctxMenuPos_$().y,"px")}}var Le=(()=>{class i{consultant_DS=x(G);router=x(U);modelRegistry_DS=x(De);isCreateOpen_$=l(!1);newLabel_$=l("");newProvider_$=l("");newModel_$=l("");isCreating_$=l(!1);providerOptions_$=b(()=>g.collectSortedProviders(this.consultant_DS.pickerOptions_$()));modelsForNewProvider_$=b(()=>g.collectSortedModelsForProvider(this.consultant_DS.pickerOptions_$(),this.newProvider_$()));providerDisplayLabelsMap_$=b(()=>{let e=this.modelRegistry_DS.setupConfigForRegistry_$(),t=this.providerOptions_$(),n={};for(let o of t)n[o]==null&&(n[o]=ee.getProviderDisplayLabel(o,e));return n});threadProviderDisplayLabels_$=b(()=>{let e=this.modelRegistry_DS.setupConfigForRegistry_$(),t=new Set;for(let o of this.consultant_DS.threads_$()){let p=o.providerInstanceId.trim();p.length>0&&t.add(p)}for(let o of this.providerOptions_$())t.add(o);let n={};for(let o of t)n[o]=ee.getProviderDisplayLabel(o,e);return n});threadRowViews_$=b(()=>this.consultant_DS.threads_$().map(e=>({id:e.threadId,label:e.label||e.threadId,status:"",statusColorClass:"bg-neutral-600",isArchived:!1,lastActivityAt:e.updatedAt,isRunning:!1})));ctxMenuThread_$=l(null);ctxMenuPos_$=l({x:0,y:0});ngOnInit(){this.consultant_DS.loadThreads(),this.consultant_DS.loadPickerOptions(),this.modelRegistry_DS.loadSetupConfigForRegistry()}handleSelectThread(e){this.router.navigate(["/consultant",e])}handleOpenCreate(){return C(this,null,function*(){yield this.consultant_DS.loadPickerOptions();let e=this.consultant_DS.defaults_$(),t=this.providerOptions_$();if(e.providerInstanceId.length>0&&t.includes(e.providerInstanceId)){let n=g.collectSortedModelsForProvider(this.consultant_DS.pickerOptions_$(),e.providerInstanceId);e.model.length>0&&n.includes(e.model)?(this.newProvider_$.set(e.providerInstanceId),this.newModel_$.set(e.model)):(this.newProvider_$.set(e.providerInstanceId),this.newModel_$.set(n[0]??""))}else{let n=t[0]??"";this.newProvider_$.set(n);let o=g.collectSortedModelsForProvider(this.consultant_DS.pickerOptions_$(),n);this.newModel_$.set(o[0]??"")}this.newLabel_$.set(""),this.isCreateOpen_$.set(!0)})}handleCloseCreate(){this.isCreateOpen_$.set(!1)}handleProviderChange(e){this.newProvider_$.set(e);let t=g.collectSortedModelsForProvider(this.consultant_DS.pickerOptions_$(),e);this.newModel_$.set(t[0]??"")}handleCreateThread(){return C(this,null,function*(){let e=this.newProvider_$().trim(),t=this.newModel_$().trim();if(!(!e.length||!t.length)){this.isCreating_$.set(!0);try{let n=this.newLabel_$().trim(),o=yield this.consultant_DS.createThread({label:n.length>0?n:void 0,providerInstanceId:e,model:t});this.isCreateOpen_$.set(!1),o.length>0&&this.router.navigate(["/consultant",o])}finally{this.isCreating_$.set(!1)}}})}handleRowContextMenu(e){let t=this.consultant_DS.threads_$().find(n=>n.threadId===e.id);t&&(this.ctxMenuThread_$.set(t),this.ctxMenuPos_$.set({x:e.event.clientX,y:e.event.clientY}))}handleCloseCtxMenu(){this.ctxMenuThread_$.set(null)}handleCtxDelete(){return C(this,null,function*(){let e=this.ctxMenuThread_$();if(e){this.handleCloseCtxMenu();try{yield this.consultant_DS.deleteThread(e.threadId),this.router.navigate(["/consultant"])}catch{}}})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=I({type:i,selectors:[["app-ccap-consultant-dashboard"]],hostAttrs:[1,"flex","flex-col","flex-1","min-h-0","overflow-hidden"],decls:12,vars:3,consts:[[1,"flex","flex-col","flex-1","min-h-0"],[1,"shrink-0","p-2","border-b","border-neonDefault","flex","items-center","gap-2"],[1,"text-xs","font-semibold","text-neutral-300","flex-1","truncate"],["type","button",1,"px-2","py-1","text-xs","border","border-neonDefault","text-neutral-300","hover:bg-neutral-700","rounded","transition-colors",3,"click"],[1,"flex-1","overflow-y-auto"],[1,"p-3","text-xs","text-neutral-500"],[1,"p-4","text-center","text-neutral-500","text-xs"],[1,"fixed","inset-0","z-40","flex","items-center","justify-center","bg-black/60","p-4"],[3,"view","isActive"],[3,"selected","contextMenu","view","isActive"],[1,"fixed","inset-0","z-40","flex","items-center","justify-center","bg-black/60","p-4",3,"click"],[1,"w-full","max-w-md","rounded-lg","border","border-neonDefault","bg-neutral-900","p-4","shadow-xl",3,"click"],[1,"text-sm","font-semibold","text-neutral-200","mb-3"],[1,"flex","flex-col","gap-2","text-xs"],[1,"text-neutral-400"],[1,"w-full","px-2","py-1","rounded","bg-neutral-800","border","border-neutral-600","text-neutral-200",3,"ngModelChange","ngModel"],[3,"value"],[1,"flex","justify-end","gap-2","mt-4"],["type","button",1,"px-2","py-1","text-xs","border","border-neutral-600","text-neutral-400","rounded",3,"click"],["type","button",1,"px-2","py-1","text-xs","border","border-neonDefault","text-neutral-200","rounded","disabled:opacity-40",3,"click","disabled"],[1,"fixed","inset-0","z-40",3,"click"],[1,"fixed","z-50","min-w-[140px]","bg-neutral-900","border","border-neutral-700","rounded-lg","shadow-xl","py-1","text-xs"],[1,"w-full","text-left","px-3","py-1.5","text-red-400","hover:bg-red-500/10","transition-colors",3,"click"]],template:function(t,n){if(t&1&&(r(0,"div",0)(1,"div",1)(2,"span",2),_(3,"Consultant"),s(),r(4,"button",3),h("click",function(){return n.handleOpenCreate()}),_(5," + New "),s()(),r(6,"div",4),M(7,je,2,0,"div",5)(8,Xe,2,0)(9,qe,2,0,"div",6),s()(),M(10,Ke,23,4,"div",7)(11,Ye,4,4)),t&2){let o;d(7),y(n.consultant_DS.threadsLoading_$()?7:n.threadRowViews_$().length?8:9),d(3),y(n.isCreateOpen_$()?10:-1),d(),y((o=n.ctxMenuThread_$())?11:-1,o)}},dependencies:[j,H,N,z,W,B,Me],encapsulation:2})}return i})();var We=(()=>{class i{sidebarWidth_$=l(320);isSidebarOpen_$=l(!0);isResizing_$=l(!1);ngOnInit(){let e=T.loadPanelWidth("sidebar",320);this.sidebarWidth_$.set(Math.max(200,Math.min(600,e))),this.isSidebarOpen_$.set(T.loadPanelOpen("sidebar",!0))}handleSidebarResizeStart(e){let t=e.clientX,n=this.sidebarWidth_$();this.isResizing_$.set(!0),Ve.attachUntilPointerUp({startEvent:e,onMove:o=>{let p=o.clientX-t,A=Math.max(200,Math.min(600,n+p));this.sidebarWidth_$.set(A)},onEnd:()=>{this.isResizing_$.set(!1),T.savePanelWidth("sidebar",this.sidebarWidth_$())}})}handleToggleSidebar(){this.isSidebarOpen_$.update(e=>!e),T.savePanelOpen("sidebar",this.isSidebarOpen_$())}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=I({type:i,selectors:[["app-ccap-consultant-shell"]],hostAttrs:[1,"flex","min-h-0","w-full","flex-1","flex-col","overflow-hidden"],decls:14,vars:9,consts:[[1,"flex","min-h-0","w-full","flex-1","flex-col","overflow-hidden"],["sSessionToolbarLeft","",1,"flex","items-center","gap-1","min-w-0"],["type","button",1,"px-2","py-1","text-xs","border","border-neonDefault","text-neutral-300","hover:bg-neutral-700","rounded","transition-colors","flex","items-center","gap-1","shrink-0",3,"click"],["viewBox","0 0 24 24","fill","none","stroke","currentColor","stroke-width","2","stroke-linecap","round","stroke-linejoin","round",1,"w-3","h-3","shrink-0","transition-transform","duration-150"],["points","6 9 12 15 18 9"],["sSessionToolbarCenter","",1,"min-w-0"],["sSessionToolbarRight","",1,"min-w-0"],[3,"sidebarResizeStart","isSidebarOpen","sidebarWidthPx","isResizing"],["sSessionShellSidebar","",1,"flex","flex-col","overflow-hidden","h-full"],["sSessionShellMain","",1,"flex","min-h-0","flex-1","flex-col","overflow-hidden","[&>router-outlet]:contents"]],template:function(t,n){t&1&&(r(0,"div",0)(1,"app-s-session-shell-toolbar")(2,"div",1)(3,"button",2),h("click",function(){return n.handleToggleSidebar()}),le(),r(4,"svg",3),w(5,"polyline",4),s(),_(6," Consultant "),s()(),de(),w(7,"div",5)(8,"div",6),s(),r(9,"app-s-resizable-session-shell-layout",7),h("sidebarResizeStart",function(p){return n.handleSidebarResizeStart(p)}),r(10,"div",8),w(11,"app-ccap-consultant-dashboard"),s(),r(12,"div",9),w(13,"router-outlet"),s()()()),t&2&&(R("select-none",n.isResizing_$()),d(4),R("rotate-90",n.isSidebarOpen_$())("-rotate-90",!n.isSidebarOpen_$()),d(5),f("isSidebarOpen",n.isSidebarOpen_$())("sidebarWidthPx",n.sidebarWidth_$())("isResizing",n.isResizing_$()))},dependencies:[ge,Pe,Ee,Le],encapsulation:2})}return i})();var K=class i{static fromMessage(a){let e=a.role==="user",t=e?i.buildUserBodyText(a):a.content??"";return{listKey:a.id,kind:e?te.userPrompt:te.assistant,bodyText:t,isUserAligned:e,flags:{showCopy:!0,showRawInfo:!1,useEditDiffForExpandable:!1}}}static buildUserBodyText(a){let e=(a.rawUserText??"").trim();return(a.userParts?.length??0)>1?e.length>0?`${e}
1
+ import"./chunk-EGRHWZRV.js";import{a as Ve}from"./chunk-Q2PKIGLB.js";import{a as we}from"./chunk-MIWIPUJL.js";import{a as Ie,b as X}from"./chunk-RTAONMUA.js";import"./chunk-QM4JVUVN.js";import{g as Re}from"./chunk-KOFPH2WQ.js";import"./chunk-5GCMRTM2.js";import"./chunk-7JUIBZEE.js";import{a as Pe,b as Ee,c as q}from"./chunk-C7XPBJTG.js";import{b as te,f as ke,g as Ae}from"./chunk-565H5Q7X.js";import"./chunk-WPHEQXWB.js";import{b as Me}from"./chunk-ZRLAS63L.js";import"./chunk-XC26T3JJ.js";import"./chunk-RQSPYGNE.js";import"./chunk-CZVHJQVK.js";import"./chunk-Q2NVIOCY.js";import{a as De}from"./chunk-4JZNUGDT.js";import{a as ee}from"./chunk-J32YRK3S.js";import"./chunk-QYAK3VTE.js";import"./chunk-X3CIXD4W.js";import"./chunk-EZQXUBC4.js";import"./chunk-V3VQWJQL.js";import"./chunk-WKXTPGKW.js";import"./chunk-ACLAVYA7.js";import"./chunk-ZBTWQZNB.js";import"./chunk-FLAJXIYW.js";import{b as ve,c as N,f as W,i as B,n as z,o as j,p as H,v as Se}from"./chunk-EO4DNTT4.js";import{k as Te}from"./chunk-SUAZOLRE.js";import{a as V}from"./chunk-5UPNU54P.js";import{j as ye}from"./chunk-66YFYBOC.js";import{I as $e}from"./chunk-ZJ3DCODZ.js";import{Aa as he,Ba as me,C as x,D as I,E as se,Eb as xe,Fa as _,Fb as ge,Ga as k,Gb as U,J as m,K as u,Kb as be,L as le,M as de,Z as d,aa as l,ca as ce,da as M,ga as f,ha as _e,hb as b,ia as R,jb as ue,k as C,la as y,na as P,oa as S,p as v,pa as $,q as re,qa as r,ra as s,sa as w,ua as E,ub as fe,va as h,wa as c,xb as Ce,y as F,z as ae,za as pe}from"./chunk-TBMJSIBB.js";var Q="ccap-consultant",T=class{static savePanelOpen(a,e){V.writeBoolean(`${Q}:panelOpen:${a}`,e)}static loadPanelOpen(a,e){return V.readBoolean(`${Q}:panelOpen:${a}`,e)}static savePanelWidth(a,e){V.writeNumber(`${Q}:panelWidth:${a}`,e)}static loadPanelWidth(a,e){return V.readNumber(`${Q}:panelWidth:${a}`,e)}};var Oe=(()=>{class i{baseUrl=`${$e.api.baseUrl}/consultant`;http=x(Ce);listThreads(){return v(this.http.get(this.baseUrl))}getPickerOptions(){return v(this.http.get(`${this.baseUrl}/picker-options`))}createThread(e){return v(this.http.post(this.baseUrl,e))}getThread(e){return v(this.http.get(`${this.baseUrl}/${encodeURIComponent(e)}`))}patchThread(e){let t={};return e.label!=null&&(t.label=e.label),e.providerInstanceId!=null&&(t.providerInstanceId=e.providerInstanceId),e.model!=null&&(t.model=e.model),v(this.http.patch(`${this.baseUrl}/${encodeURIComponent(e.threadId)}`,t))}deleteThread(e){return v(this.http.delete(`${this.baseUrl}/${encodeURIComponent(e)}`))}postMessage(e){return v(this.http.post(`${this.baseUrl}/${encodeURIComponent(e.threadId)}/messages`,{text:e.text,allowWebSearch:e.allowWebSearch,attachments:e.attachments}))}static \u0275fac=function(t){return new(t||i)};static \u0275prov=F({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var G=(()=>{class i{consultant_AS=x(Oe);globalError_CS=x(ye);threads_$=l([]);threadsLoading_$=l(!1);threadsError_$=l(null);selectedThread_$=l(null);selectedThreadLoading_$=l(!1);selectedThreadError_$=l(null);sending_$=l(!1);activeThreadId_$=l("");defaults_$=l({providerInstanceId:"",model:""});pickerOptions_$=l([]);pickerOptionsLoading_$=l(!1);loadPickerOptions(){return C(this,null,function*(){this.pickerOptionsLoading_$.set(!0);try{let e=yield this.consultant_AS.getPickerOptions(),t=Array.isArray(e.entries)?e.entries.map(i.parseRegistryEntry).filter(n=>n!==null):[];this.pickerOptions_$.set(t),this.defaults_$.set({providerInstanceId:typeof e.defaults?.providerInstanceId=="string"?e.defaults.providerInstanceId:"",model:typeof e.defaults?.model=="string"?e.defaults.model:""})}catch(e){this.globalError_CS.showError(e,"Consultant_DataService.loadPickerOptions")}finally{this.pickerOptionsLoading_$.set(!1)}})}loadThreads(){return C(this,null,function*(){this.threadsLoading_$.set(!0),this.threadsError_$.set(null);try{let e=yield this.consultant_AS.listThreads(),n=(Array.isArray(e.threads)?e.threads:[]).map(o=>({threadId:typeof o.threadId=="string"?o.threadId:"",label:typeof o.label=="string"?o.label:"",providerInstanceId:typeof o.providerInstanceId=="string"?o.providerInstanceId:"",model:typeof o.model=="string"?o.model:"",messageCount:typeof o.messageCount=="number"?o.messageCount:0,updatedAt:typeof o.updatedAt=="string"?o.updatedAt:""}));this.threads_$.set(n)}catch(e){this.threadsError_$.set(e),this.globalError_CS.showError(e,"Consultant_DataService.loadThreads")}finally{this.threadsLoading_$.set(!1)}})}loadThreadDetail(e){return C(this,null,function*(){this.activeThreadId_$.set(e),this.selectedThreadLoading_$.set(!0),this.selectedThreadError_$.set(null);try{let t=yield this.consultant_AS.getThread(e),n=i.parseThreadDetail(t.thread);this.selectedThread_$.set(n)}catch(t){this.selectedThreadError_$.set(t),this.globalError_CS.showError(t,"Consultant_DataService.loadThreadDetail")}finally{this.selectedThreadLoading_$.set(!1)}})}sendMessage(e){return C(this,null,function*(){this.sending_$.set(!0);try{let n=(yield this.consultant_AS.postMessage(e)).thread;if(i.isPlainRecord(n)){let o=i.parseThreadDetail(n);this.selectedThread_$.set(o)}yield this.loadThreads()}catch(t){throw this.globalError_CS.showError(t,"Consultant_DataService.sendMessage"),t}finally{this.sending_$.set(!1)}})}updateThreadConfig(e){return C(this,null,function*(){try{let t=yield this.consultant_AS.patchThread(e),n=i.parseThreadDetail(t.thread);this.selectedThread_$.set(n),yield this.loadThreads()}catch(t){throw this.globalError_CS.showError(t,"Consultant_DataService.updateThreadConfig"),t}})}createThread(e){return C(this,null,function*(){try{let n=(yield this.consultant_AS.createThread(e)).thread.threadId,o=typeof n=="string"?n:"";return yield this.loadThreads(),o}catch(t){throw this.globalError_CS.showError(t,"Consultant_DataService.createThread"),t}})}deleteThread(e){return C(this,null,function*(){try{yield this.consultant_AS.deleteThread(e),this.activeThreadId_$()===e&&(this.selectedThread_$.set(null),this.activeThreadId_$.set("")),yield this.loadThreads()}catch(t){throw this.globalError_CS.showError(t,"Consultant_DataService.deleteThread"),t}})}static parseThreadDetail(e){let t=typeof e.threadId=="string"?e.threadId:"";if(!t.length)return null;let n=e.messages,o=[];if(Array.isArray(n))for(let p of n){if(!i.isPlainRecord(p))continue;let A=typeof p.id=="string"?p.id:"",Y=p.role;if(Y!=="user"&&Y!=="assistant")continue;let L={id:A,role:Y};typeof p.rawUserText=="string"&&(L.rawUserText=p.rawUserText),typeof p.content=="string"&&(L.content=p.content);let ie=p.userParts;if(Array.isArray(ie)){let oe=[];for(let D of ie){if(!i.isPlainRecord(D))continue;let J=D.type;if(J!=="text"&&J!=="image_url")continue;let Z={type:J};typeof D.text=="string"&&(Z.text=D.text),typeof D.imageUrl=="string"&&(Z.imageUrl=D.imageUrl),oe.push(Z)}L.userParts=oe}o.push(L)}return{threadId:t,label:typeof e.label=="string"?e.label:"",providerInstanceId:typeof e.providerInstanceId=="string"?e.providerInstanceId:"",model:typeof e.model=="string"?e.model:"",messages:o,updatedAt:typeof e.updatedAt=="string"?e.updatedAt:""}}static isPlainRecord(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}static parseRegistryEntry(e){if(!i.isPlainRecord(e))return null;let t=typeof e.provider=="string"?e.provider:"",n=typeof e.modelName=="string"?e.modelName:"";if(!t.length||!n.length)return null;let o=e.capabilities,p=Array.isArray(o)?o.filter(A=>typeof A=="string"):void 0;return{id:typeof e.id=="string"?e.id:"",provider:t,modelName:n,enabled:e.enabled===!0,capabilities:p}}static \u0275fac=function(t){return new(t||i)};static \u0275prov=F({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();var g=class{static collectSortedProviders(a){let e=new Set;for(let t of a){let n=t.provider.trim();n.length>0&&e.add(n)}return[...e].sort()}static collectSortedModelsForProvider(a,e){let t=e.trim();if(!t.length)return[];let n=[];for(let o of a){let p=o.modelName.trim();o.provider===t&&p.length>0&&n.push(p)}return[...new Set(n)].sort()}};var ze=(i,a)=>a.id;function je(i,a){i&1&&(r(0,"div",5),_(1,"Loading..."),s())}function He(i,a){if(i&1){let e=E();r(0,"app-s-session-list-row",9),h("selected",function(n){m(e);let o=c(2);return u(o.handleSelectThread(n))})("contextMenu",function(n){m(e);let o=c(2);return u(o.handleRowContextMenu(n))}),s()}if(i&2){let e=a.$implicit,t=c(2);f("view",e)("isActive",t.consultant_DS.activeThreadId_$()===e.id)}}function Xe(i,a){if(i&1&&S(0,He,1,2,"app-s-session-list-row",8,ze),i&2){let e=c();$(e.threadRowViews_$())}}function qe(i,a){i&1&&(r(0,"div",6),_(1,"No threads"),s())}function Qe(i,a){if(i&1&&(r(0,"option",16),_(1),s()),i&2){let e=a.$implicit,t=c(2);f("value",e),d(),k(t.providerDisplayLabelsMap_$()[e]||e)}}function Ge(i,a){if(i&1&&(r(0,"option",16),_(1),s()),i&2){let e=a.$implicit;f("value",e),d(),k(e)}}function Ke(i,a){if(i&1){let e=E();r(0,"div",10),h("click",function(){m(e);let n=c();return u(n.handleCloseCreate())}),r(1,"div",11),h("click",function(n){return m(e),u(n.stopPropagation())}),r(2,"h3",12),_(3,"New consultant thread"),s(),r(4,"div",13)(5,"label",14),_(6,"Label (optional)"),s(),r(7,"input",15),h("ngModelChange",function(n){m(e);let o=c();return u(o.newLabel_$.set(n))}),s(),r(8,"label",14),_(9,"Provider"),s(),r(10,"select",15),h("ngModelChange",function(n){m(e);let o=c();return u(o.handleProviderChange(n))}),S(11,Qe,2,2,"option",16,P),s(),r(13,"label",14),_(14,"Model"),s(),r(15,"select",15),h("ngModelChange",function(n){m(e);let o=c();return u(o.newModel_$.set(n))}),S(16,Ge,2,2,"option",16,P),s()(),r(18,"div",17)(19,"button",18),h("click",function(){m(e);let n=c();return u(n.handleCloseCreate())}),_(20," Cancel "),s(),r(21,"button",19),h("click",function(){m(e);let n=c();return u(n.handleCreateThread())}),_(22," Create "),s()()()()}if(i&2){let e=c();d(7),f("ngModel",e.newLabel_$()),d(3),f("ngModel",e.newProvider_$()),d(),$(e.providerOptions_$()),d(4),f("ngModel",e.newModel_$()),d(),$(e.modelsForNewProvider_$()),d(5),f("disabled",e.isCreating_$()||!e.newProvider_$().trim()||!e.newModel_$().trim())}}function Ye(i,a){if(i&1){let e=E();r(0,"div",20),h("click",function(){m(e);let n=c();return u(n.handleCloseCtxMenu())}),s(),r(1,"div",21)(2,"button",22),h("click",function(){m(e);let n=c();return u(n.handleCtxDelete())}),_(3," Delete "),s()()}if(i&2){let e=c();d(),_e("left",e.ctxMenuPos_$().x,"px")("top",e.ctxMenuPos_$().y,"px")}}var Le=(()=>{class i{consultant_DS=x(G);router=x(U);modelRegistry_DS=x(De);isCreateOpen_$=l(!1);newLabel_$=l("");newProvider_$=l("");newModel_$=l("");isCreating_$=l(!1);providerOptions_$=b(()=>g.collectSortedProviders(this.consultant_DS.pickerOptions_$()));modelsForNewProvider_$=b(()=>g.collectSortedModelsForProvider(this.consultant_DS.pickerOptions_$(),this.newProvider_$()));providerDisplayLabelsMap_$=b(()=>{let e=this.modelRegistry_DS.setupConfigForRegistry_$(),t=this.providerOptions_$(),n={};for(let o of t)n[o]==null&&(n[o]=ee.getProviderDisplayLabel(o,e));return n});threadProviderDisplayLabels_$=b(()=>{let e=this.modelRegistry_DS.setupConfigForRegistry_$(),t=new Set;for(let o of this.consultant_DS.threads_$()){let p=o.providerInstanceId.trim();p.length>0&&t.add(p)}for(let o of this.providerOptions_$())t.add(o);let n={};for(let o of t)n[o]=ee.getProviderDisplayLabel(o,e);return n});threadRowViews_$=b(()=>this.consultant_DS.threads_$().map(e=>({id:e.threadId,label:e.label||e.threadId,status:"",statusColorClass:"bg-neutral-600",isArchived:!1,lastActivityAt:e.updatedAt,isRunning:!1})));ctxMenuThread_$=l(null);ctxMenuPos_$=l({x:0,y:0});ngOnInit(){this.consultant_DS.loadThreads(),this.consultant_DS.loadPickerOptions(),this.modelRegistry_DS.loadSetupConfigForRegistry()}handleSelectThread(e){this.router.navigate(["/consultant",e])}handleOpenCreate(){return C(this,null,function*(){yield this.consultant_DS.loadPickerOptions();let e=this.consultant_DS.defaults_$(),t=this.providerOptions_$();if(e.providerInstanceId.length>0&&t.includes(e.providerInstanceId)){let n=g.collectSortedModelsForProvider(this.consultant_DS.pickerOptions_$(),e.providerInstanceId);e.model.length>0&&n.includes(e.model)?(this.newProvider_$.set(e.providerInstanceId),this.newModel_$.set(e.model)):(this.newProvider_$.set(e.providerInstanceId),this.newModel_$.set(n[0]??""))}else{let n=t[0]??"";this.newProvider_$.set(n);let o=g.collectSortedModelsForProvider(this.consultant_DS.pickerOptions_$(),n);this.newModel_$.set(o[0]??"")}this.newLabel_$.set(""),this.isCreateOpen_$.set(!0)})}handleCloseCreate(){this.isCreateOpen_$.set(!1)}handleProviderChange(e){this.newProvider_$.set(e);let t=g.collectSortedModelsForProvider(this.consultant_DS.pickerOptions_$(),e);this.newModel_$.set(t[0]??"")}handleCreateThread(){return C(this,null,function*(){let e=this.newProvider_$().trim(),t=this.newModel_$().trim();if(!(!e.length||!t.length)){this.isCreating_$.set(!0);try{let n=this.newLabel_$().trim(),o=yield this.consultant_DS.createThread({label:n.length>0?n:void 0,providerInstanceId:e,model:t});this.isCreateOpen_$.set(!1),o.length>0&&this.router.navigate(["/consultant",o])}finally{this.isCreating_$.set(!1)}}})}handleRowContextMenu(e){let t=this.consultant_DS.threads_$().find(n=>n.threadId===e.id);t&&(this.ctxMenuThread_$.set(t),this.ctxMenuPos_$.set({x:e.event.clientX,y:e.event.clientY}))}handleCloseCtxMenu(){this.ctxMenuThread_$.set(null)}handleCtxDelete(){return C(this,null,function*(){let e=this.ctxMenuThread_$();if(e){this.handleCloseCtxMenu();try{yield this.consultant_DS.deleteThread(e.threadId),this.router.navigate(["/consultant"])}catch{}}})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=I({type:i,selectors:[["app-ccap-consultant-dashboard"]],hostAttrs:[1,"flex","flex-col","flex-1","min-h-0","overflow-hidden"],decls:12,vars:3,consts:[[1,"flex","flex-col","flex-1","min-h-0"],[1,"shrink-0","p-2","border-b","border-neonDefault","flex","items-center","gap-2"],[1,"text-xs","font-semibold","text-neutral-300","flex-1","truncate"],["type","button",1,"px-2","py-1","text-xs","border","border-neonDefault","text-neutral-300","hover:bg-neutral-700","rounded","transition-colors",3,"click"],[1,"flex-1","overflow-y-auto"],[1,"p-3","text-xs","text-neutral-500"],[1,"p-4","text-center","text-neutral-500","text-xs"],[1,"fixed","inset-0","z-40","flex","items-center","justify-center","bg-black/60","p-4"],[3,"view","isActive"],[3,"selected","contextMenu","view","isActive"],[1,"fixed","inset-0","z-40","flex","items-center","justify-center","bg-black/60","p-4",3,"click"],[1,"w-full","max-w-md","rounded-lg","border","border-neonDefault","bg-neutral-900","p-4","shadow-xl",3,"click"],[1,"text-sm","font-semibold","text-neutral-200","mb-3"],[1,"flex","flex-col","gap-2","text-xs"],[1,"text-neutral-400"],[1,"w-full","px-2","py-1","rounded","bg-neutral-800","border","border-neutral-600","text-neutral-200",3,"ngModelChange","ngModel"],[3,"value"],[1,"flex","justify-end","gap-2","mt-4"],["type","button",1,"px-2","py-1","text-xs","border","border-neutral-600","text-neutral-400","rounded",3,"click"],["type","button",1,"px-2","py-1","text-xs","border","border-neonDefault","text-neutral-200","rounded","disabled:opacity-40",3,"click","disabled"],[1,"fixed","inset-0","z-40",3,"click"],[1,"fixed","z-50","min-w-[140px]","bg-neutral-900","border","border-neutral-700","rounded-lg","shadow-xl","py-1","text-xs"],[1,"w-full","text-left","px-3","py-1.5","text-red-400","hover:bg-red-500/10","transition-colors",3,"click"]],template:function(t,n){if(t&1&&(r(0,"div",0)(1,"div",1)(2,"span",2),_(3,"Consultant"),s(),r(4,"button",3),h("click",function(){return n.handleOpenCreate()}),_(5," + New "),s()(),r(6,"div",4),M(7,je,2,0,"div",5)(8,Xe,2,0)(9,qe,2,0,"div",6),s()(),M(10,Ke,23,4,"div",7)(11,Ye,4,4)),t&2){let o;d(7),y(n.consultant_DS.threadsLoading_$()?7:n.threadRowViews_$().length?8:9),d(3),y(n.isCreateOpen_$()?10:-1),d(),y((o=n.ctxMenuThread_$())?11:-1,o)}},dependencies:[j,H,N,z,W,B,Me],encapsulation:2})}return i})();var We=(()=>{class i{sidebarWidth_$=l(320);isSidebarOpen_$=l(!0);isResizing_$=l(!1);ngOnInit(){let e=T.loadPanelWidth("sidebar",320);this.sidebarWidth_$.set(Math.max(200,Math.min(600,e))),this.isSidebarOpen_$.set(T.loadPanelOpen("sidebar",!0))}handleSidebarResizeStart(e){let t=e.clientX,n=this.sidebarWidth_$();this.isResizing_$.set(!0),Ve.attachUntilPointerUp({startEvent:e,onMove:o=>{let p=o.clientX-t,A=Math.max(200,Math.min(600,n+p));this.sidebarWidth_$.set(A)},onEnd:()=>{this.isResizing_$.set(!1),T.savePanelWidth("sidebar",this.sidebarWidth_$())}})}handleToggleSidebar(){this.isSidebarOpen_$.update(e=>!e),T.savePanelOpen("sidebar",this.isSidebarOpen_$())}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=I({type:i,selectors:[["app-ccap-consultant-shell"]],hostAttrs:[1,"flex","min-h-0","w-full","flex-1","flex-col","overflow-hidden"],decls:14,vars:9,consts:[[1,"flex","min-h-0","w-full","flex-1","flex-col","overflow-hidden"],["sSessionToolbarLeft","",1,"flex","items-center","gap-1","min-w-0"],["type","button",1,"px-2","py-1","text-xs","border","border-neonDefault","text-neutral-300","hover:bg-neutral-700","rounded","transition-colors","flex","items-center","gap-1","shrink-0",3,"click"],["viewBox","0 0 24 24","fill","none","stroke","currentColor","stroke-width","2","stroke-linecap","round","stroke-linejoin","round",1,"w-3","h-3","shrink-0","transition-transform","duration-150"],["points","6 9 12 15 18 9"],["sSessionToolbarCenter","",1,"min-w-0"],["sSessionToolbarRight","",1,"min-w-0"],[3,"sidebarResizeStart","isSidebarOpen","sidebarWidthPx","isResizing"],["sSessionShellSidebar","",1,"flex","flex-col","overflow-hidden","h-full"],["sSessionShellMain","",1,"flex","min-h-0","flex-1","flex-col","overflow-hidden","[&>router-outlet]:contents"]],template:function(t,n){t&1&&(r(0,"div",0)(1,"app-s-session-shell-toolbar")(2,"div",1)(3,"button",2),h("click",function(){return n.handleToggleSidebar()}),le(),r(4,"svg",3),w(5,"polyline",4),s(),_(6," Consultant "),s()(),de(),w(7,"div",5)(8,"div",6),s(),r(9,"app-s-resizable-session-shell-layout",7),h("sidebarResizeStart",function(p){return n.handleSidebarResizeStart(p)}),r(10,"div",8),w(11,"app-ccap-consultant-dashboard"),s(),r(12,"div",9),w(13,"router-outlet"),s()()()),t&2&&(R("select-none",n.isResizing_$()),d(4),R("rotate-90",n.isSidebarOpen_$())("-rotate-90",!n.isSidebarOpen_$()),d(5),f("isSidebarOpen",n.isSidebarOpen_$())("sidebarWidthPx",n.sidebarWidth_$())("isResizing",n.isResizing_$()))},dependencies:[ge,Pe,Ee,Le],encapsulation:2})}return i})();var K=class i{static fromMessage(a){let e=a.role==="user",t=e?i.buildUserBodyText(a):a.content??"";return{listKey:a.id,kind:e?te.userPrompt:te.assistant,bodyText:t,isUserAligned:e,flags:{showCopy:!0,showRawInfo:!1,useEditDiffForExpandable:!1}}}static buildUserBodyText(a){let e=(a.rawUserText??"").trim();return(a.userParts?.length??0)>1?e.length>0?`${e}
2
2
  [attachments]`:"[attachments]":e.length>0?e:a.content??""}};var Ze=(i,a)=>a.listKey;function et(i,a){i&1&&(r(0,"div",0),_(1," Select a thread or create a new consultant chat. "),s())}function tt(i,a){i&1&&(r(0,"div",1),_(1,"Loading\u2026"),s())}function nt(i,a){if(i&1&&(r(0,"option",8),_(1),s()),i&2){let e=a.$implicit;f("value",e),d(),k(e)}}function it(i,a){if(i&1&&(r(0,"option",8),_(1),s()),i&2){let e=a.$implicit;f("value",e),d(),k(e)}}function ot(i,a){if(i&1&&(r(0,"div",18),w(1,"app-s-agent-console-message-bubble",19),s()),i&2){let e=a.$implicit;R("self-end",e.isUserAligned===!0)("self-start",e.isUserAligned!==!0),d(),f("view",e)}}function rt(i,a){if(i&1){let e=E();r(0,"app-s-session-chat-column-layout")(1,"div",2)(2,"div",3)(3,"div",4)(4,"span",5),_(5,"Label"),s(),r(6,"input",6),h("ngModelChange",function(n){m(e);let o=c(2);return u(o.localLabel_$.set(n))}),s()(),r(7,"div",4)(8,"span",5),_(9,"Provider"),s(),r(10,"select",7),h("ngModelChange",function(n){m(e);let o=c(2);return u(o.handleProviderChange(n))}),S(11,nt,2,2,"option",8,P),s()(),r(13,"div",4)(14,"span",5),_(15,"Model"),s(),r(16,"select",6),h("ngModelChange",function(n){m(e);let o=c(2);return u(o.localModel_$.set(n))}),S(17,it,2,2,"option",8,P),s()(),r(19,"button",9),h("click",function(){m(e);let n=c(2);return u(n.handleApplyConfig())}),_(20," Apply "),s(),r(21,"button",10),h("click",function(){m(e);let n=c(2);return u(n.handleDeleteThread())}),_(22," Delete "),s()()(),r(23,"div",11),S(24,ot,2,5,"div",12,Ze),s(),r(26,"div",13)(27,"label",14)(28,"input",15),h("ngModelChange",function(n){m(e);let o=c(2);return u(o.allowWebSearch_$.set(n))}),s(),_(29," Allow web search (Brave) "),s(),r(30,"app-s-session-input",16),h("draftTextChange",function(n){m(e);let o=c(2);return u(o.composerText_$.set(n))})("sendRequested",function(){m(e);let n=c(2);return u(n.handleSend())})("attachmentsChanged",function(n){m(e);let o=c(2);return u(o.handleAttachmentsChanged(n))}),r(31,"app-ccap-voice-record-button",17),h("transcriptSegmentReady",function(n){m(e);let o=c(2);return u(o.handleVoiceSegment(n))}),s()()()()}if(i&2){let e=c(2);d(6),f("ngModel",e.localLabel_$()),d(4),f("ngModel",e.localProvider_$()),d(),$(e.providerOptions_$()),d(5),f("ngModel",e.localModel_$()),d(),$(e.modelsForSelectedProvider_$()),d(7),$(e.consultantBubbleViews_$()),d(4),f("ngModel",e.allowWebSearch_$()),d(2),f("draftText",e.composerText_$())("isSending",e.consultant_DS.sending_$())("enableAttachments",!0)("textareaRows",3),d(),f("compactLayout",!0)}}function at(i,a){i&1&&(r(0,"div",0),_(1," Thread not loaded. "),s())}function st(i,a){if(i&1&&M(0,rt,32,9,"app-s-session-chat-column-layout")(1,at,2,0,"div",0),i&2){let e=c();y(e.consultant_DS.selectedThread_$()?0:1)}}var ne=(()=>{class i extends we{consultant_DS=x(G);route=x(xe);router=x(U);voiceInputUi_DS=x(Ie);sessionInputRef;composerText_$=l("");allowWebSearch_$=l(!1);localLabel_$=l("");localProvider_$=l("");localModel_$=l("");providerOptions_$=b(()=>g.collectSortedProviders(this.consultant_DS.pickerOptions_$()));modelsForSelectedProvider_$=b(()=>g.collectSortedModelsForProvider(this.consultant_DS.pickerOptions_$(),this.localProvider_$()));consultantBubbleViews_$=b(()=>{let e=this.consultant_DS.selectedThread_$();return e?e.messages.map(t=>K.fromMessage(t)):[]});pendingAttachments=[];constructor(){super(),this.addSubscription(this.route.paramMap.pipe(re(e=>e.get("threadId")??"")).subscribe(e=>{e.length>0?this.consultant_DS.loadThreadDetail(e):(this.consultant_DS.selectedThread_$.set(null),this.consultant_DS.activeThreadId_$.set(""))})),ue(()=>{let e=this.consultant_DS.selectedThread_$();e!=null&&(this.localLabel_$.set(e.label),this.localProvider_$.set(e.providerInstanceId),this.localModel_$.set(e.model))},{allowSignalWrites:!0}),this.consultant_DS.loadPickerOptions()}ngOnDestroy(){super.ngOnDestroy()}handleProviderChange(e){this.localProvider_$.set(e);let t=g.collectSortedModelsForProvider(this.consultant_DS.pickerOptions_$(),e),n=this.localModel_$();t.includes(n)||this.localModel_$.set(t[0]??"")}handleApplyConfig(){return C(this,null,function*(){let e=this.consultant_DS.activeThreadId_$();e.length&&(yield this.consultant_DS.updateThreadConfig({threadId:e,label:this.localLabel_$(),providerInstanceId:this.localProvider_$(),model:this.localModel_$()}))})}handleDeleteThread(){return C(this,null,function*(){let e=this.consultant_DS.activeThreadId_$();e.length&&(yield this.consultant_DS.deleteThread(e),this.router.navigate(["/consultant"]))})}handleAttachmentsChanged(e){this.pendingAttachments=e}handleVoiceSegment(e){let t=e.text.trim();if(!t.length)return;let n=this.composerText_$().trim();this.composerText_$.set(n.length>0?`${n} ${t}`:t),this.voiceInputUi_DS.autoSendAfterVoice_$()&&e.isFinal&&this.handleSend()}handleSend(){return C(this,null,function*(){let e=this.consultant_DS.activeThreadId_$();if(!e.length)return;let t=this.composerText_$().trim(),n=[...this.pendingAttachments];if(!t.length&&!n.length)return;let o=n.map(p=>({kind:p.isImage?"image":"textDocument",mimeType:p.mimeType,fileName:p.fileName,dataBase64:p.base64}));yield this.consultant_DS.sendMessage({threadId:e,text:t,allowWebSearch:this.allowWebSearch_$(),attachments:o}),this.composerText_$.set(""),this.pendingAttachments=[],this.sessionInputRef?.clearAttachments()})}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=I({type:i,selectors:[["app-ccap-consultant-detail"]],viewQuery:function(t,n){if(t&1&&pe(q,5),t&2){let o;he(o=me())&&(n.sessionInputRef=o.first)}},hostAttrs:[1,"flex","flex-col","flex-1","min-h-0","overflow-hidden"],features:[ce],decls:3,vars:1,consts:[[1,"flex","flex-1","items-center","justify-center","p-4","text-xs","text-neutral-500"],[1,"flex","flex-1","items-center","justify-center","text-xs","text-neutral-500"],["sChatColumnHeader","",1,"flex","shrink-0","flex-col","gap-2","border-b","border-neonDefault","bg-ccapSurface","p-2"],[1,"flex","flex-wrap","items-end","gap-2"],[1,"flex","flex-col","gap-0.5"],[1,"text-[10px]","text-neutral-500"],[1,"w-40","rounded","border","border-neutral-600","bg-neutral-800","px-2","py-1","text-xs","text-neutral-200",3,"ngModelChange","ngModel"],[1,"w-36","rounded","border","border-neutral-600","bg-neutral-800","px-2","py-1","text-xs","text-neutral-200",3,"ngModelChange","ngModel"],[3,"value"],["type","button",1,"rounded","border","border-neonDefault","px-2","py-1","text-xs","text-neutral-300",3,"click"],["type","button",1,"ml-auto","rounded","border","border-red-900","px-2","py-1","text-xs","text-red-300",3,"click"],["sChatColumnScroll","",1,"flex","flex-col","gap-3","p-3"],[1,"max-w-[85%]",3,"self-end","self-start"],["sChatColumnComposer","",1,"flex","flex-col"],[1,"flex","cursor-pointer","items-center","gap-2","px-2","pt-1","text-[10px]","text-neutral-400"],["type","checkbox",3,"ngModelChange","ngModel"],["acceptedFileTypes","image/png,image/jpeg,image/webp,image/gif,.txt,.md,text/plain,text/markdown","placeholder","Message\u2026",3,"draftTextChange","sendRequested","attachmentsChanged","draftText","isSending","enableAttachments","textareaRows"],["sInputTextareaAccessory","",3,"transcriptSegmentReady","compactLayout"],[1,"max-w-[85%]"],[3,"view"]],template:function(t,n){t&1&&M(0,et,2,0,"div",0)(1,tt,2,0,"div",1)(2,st,2,1),t&2&&y(n.consultant_DS.activeThreadId_$()?n.consultant_DS.selectedThreadLoading_$()?1:2:0)},dependencies:[j,H,N,ve,z,W,B,X,q,ke,Ae],encapsulation:2})}return i})();var lt=[{path:"",component:We,children:[{path:"",component:ne},{path:":threadId",component:ne}]}],xn=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=se({type:i});static \u0275inj=ae({imports:[fe,Se,be.forChild(lt),Te,X,Re]})}return i})();export{xn as Consultant_Module};
3
- //# sourceMappingURL=consultant.module-WHGIMF6M.js.map
3
+ //# sourceMappingURL=consultant.module-ZRSJ2JPM.js.map
@@ -1,2 +1,2 @@
1
- import{a as B}from"./chunk-GH67BJ7J.js";import"./chunk-FVNI46U2.js";import"./chunk-WXN5C3BS.js";import"./chunk-5N64HGRY.js";import{$a as A,C as v,D as b,E as S,Fa as i,G as E,Ha as c,Ia as w,Kb as D,Ta as $,Z as r,aa as h,ab as I,da as p,ga as _,hb as T,k as f,la as s,mb as k,oa as y,pa as F,qa as o,ra as n,ub as u,va as x,wa as m,z as g}from"./chunk-TBMJSIBB.js";var R={respond:"bg-green-500/20 text-green-400","status-update":"bg-blue-500/20 text-blue-400",stop:"bg-neutral-500/20 text-neutral-400","request-user-interaction":"bg-yellow-500/20 text-yellow-400"},M="bg-neutral-700/20 text-neutral-500",P=(()=>{class e{transform(t){return t?R[t]??M:M}static \u0275fac=function(a){return new(a||e)};static \u0275pipe=E({name:"ccapCoordinatorActionBadge",type:e,pure:!0,standalone:!0})}return e})();var K=(e,l)=>l._id;function O(e,l){e&1&&(o(0,"div",13),i(1," Loading coordinators... "),n())}function z(e,l){e&1&&(o(0,"div",14),i(1," Nincs koordin\xE1tor session. "),n())}function G(e,l){if(e&1&&i(0),e&2){let t=m(2).$implicit;c(" \xB7 WF: ",t.workflowId," ")}}function q(e,l){if(e&1&&(o(0,"div",22),i(1),p(2,G,1,1),n()),e&2){let t=m().$implicit;r(),w(" ",t.providerName,":",t.model," "),r(),s(t.workflowId?2:-1)}}function V(e,l){if(e&1&&(o(0,"span",24),A(1,"ccapCoordinatorActionBadge"),i(2),n()),e&2){let t=m().$implicit;_("ngClass",I(1,2,t.decisions[t.decisions.length-1].action)),r(2),c(" ",t.decisions[t.decisions.length-1].action," ")}}function W(e,l){if(e&1&&(o(0,"div",25),i(1),n()),e&2){let t=m().$implicit;r(),c(" ",t.decisions[t.decisions.length-1].reasoning," ")}}function H(e,l){if(e&1&&(o(0,"div",26),i(1),n()),e&2){let t=m().$implicit;r(),c(" Pause reason: ",t.pauseReason," ")}}function J(e,l){if(e&1&&(o(0,"div",16)(1,"div",17)(2,"div",18)(3,"span",19),i(4),n(),o(5,"div",20)(6,"div",21),i(7),n(),p(8,q,3,3,"div",22),n()(),o(9,"div",23)(10,"span",6),i(11),n(),p(12,V,3,4,"span",24),n()(),p(13,W,2,1,"div",25)(14,H,2,1,"div",26),n()),e&2){let t=l.$implicit,a=m(2);r(3),_("ngClass",a.getStatusBadgeClass(t.status)),r(),c(" ",t.status," "),r(3),c(" Session: ",t.sessionId," "),r(),s(t.providerName||t.model?8:-1),r(3),c(" ",t.totalStepCount," steps "),r(),s(t.decisions&&t.decisions.length>0?12:-1),r(),s(t.decisions&&t.decisions.length>0?13:-1),r(),s(t.pauseReason?14:-1)}}function Q(e,l){if(e&1&&(o(0,"div",15),y(1,J,15,8,"div",16,K),n()),e&2){let t=m();r(),F(t.filteredCoordinators_$())}}var C=(()=>{class e{coordinator_DS=v(B);statusFilter_$=h("");filteredCoordinators_$=T(()=>{let t=this.statusFilter_$(),a=this.coordinator_DS.globalCoordinatorsList_$();return t?a.filter(d=>d.status===t):a});ngOnInit(){this.loadCoordinators()}loadCoordinators(){return f(this,null,function*(){yield this.coordinator_DS.loadAllCoordinatorsForManagementPage()})}handleFilterChange(t){let a=t.target;!a||!("value"in a)||this.statusFilter_$.set(String(a.value))}getStatusBadgeClass(t){switch(t){case"active":return"bg-green-500/20 text-green-400";case"paused":return"bg-yellow-500/20 text-yellow-400";case"completed":return"bg-neutral-500/20 text-neutral-400";case"failed":return"bg-red-500/20 text-red-400";default:return"bg-neutral-700/20 text-neutral-500"}}static \u0275fac=function(a){return new(a||e)};static \u0275cmp=b({type:e,selectors:[["app-ccap-coordinator"]],standalone:!0,features:[$],decls:28,vars:4,consts:[[1,"max-w-5xl","mx-auto","p-4","gt-xs:p-6","text-neutral-100"],[1,"flex","items-center","justify-between","mb-6"],[1,"text-2xl","font-bold"],[1,"text-neutral-400","text-sm","mt-1"],[1,"px-3","py-1.5","text-xs","border","border-neutral-600","text-neutral-300","rounded","hover:bg-neutral-800","transition-colors",3,"click"],[1,"flex","items-center","gap-3","mb-4"],[1,"text-xs","text-neutral-500"],[1,"bg-neutral-800","border","border-neutral-600","rounded","px-2","py-1","text-xs","text-neutral-200","outline-none","focus:border-neonDefault",3,"change"],["value",""],["value","active"],["value","paused"],["value","completed"],["value","failed"],[1,"text-center","py-8","text-neutral-500","text-sm"],[1,"rounded-lg","border","border-neutral-700","bg-ccapSurface/50","p-8","text-center","text-neutral-500","text-sm"],[1,"space-y-2"],[1,"rounded-lg","border","border-neutral-700","bg-ccapSurface/50","p-4","hover:border-neutral-600","transition-colors"],[1,"flex","items-center","justify-between","gap-4"],[1,"flex","items-center","gap-3","min-w-0"],[1,"text-xs","px-2","py-0.5","rounded","shrink-0",3,"ngClass"],[1,"min-w-0"],[1,"text-sm","text-neutral-200","truncate"],[1,"text-xs","text-neutral-500","mt-0.5"],[1,"flex","items-center","gap-3","shrink-0"],[1,"text-xs","px-1.5","py-0.5","rounded",3,"ngClass"],[1,"text-xs","text-neutral-400","mt-2","truncate"],[1,"text-xs","text-yellow-400/80","mt-1"]],template:function(a,d){a&1&&(o(0,"div",0)(1,"div",1)(2,"div")(3,"h1",2),i(4,"Koordin\xE1tor"),n(),o(5,"p",3),i(6," Koordin\xE1tor session-\xF6k kezel\xE9se \u2014 workflow-alap\xFA agent vez\xE9rl\xE9s. "),n()(),o(7,"button",4),x("click",function(){return d.loadCoordinators()}),i(8," Refresh "),n()(),o(9,"div",5)(10,"span",6),i(11,"Filter:"),n(),o(12,"select",7),x("change",function(j){return d.handleFilterChange(j)}),o(13,"option",8),i(14,"All"),n(),o(15,"option",9),i(16,"Active"),n(),o(17,"option",10),i(18,"Paused"),n(),o(19,"option",11),i(20,"Completed"),n(),o(21,"option",12),i(22,"Failed"),n()(),o(23,"span",6),i(24),n()(),p(25,O,2,0,"div",13)(26,z,2,0,"div",14)(27,Q,3,0,"div",15),n()),a&2&&(r(24),c(" ",d.filteredCoordinators_$().length," coordinator(s) "),r(),s(d.coordinator_DS.globalCoordinatorsListLoading_$()?25:-1),r(),s(!d.coordinator_DS.globalCoordinatorsListLoading_$()&&d.filteredCoordinators_$().length===0?26:-1),r(),s(!d.coordinator_DS.globalCoordinatorsListLoading_$()&&d.filteredCoordinators_$().length>0?27:-1))},dependencies:[u,k,P],encapsulation:2})}return e})();var U=[{path:"",pathMatch:"full",component:C}],st=(()=>{class e{static \u0275fac=function(a){return new(a||e)};static \u0275mod=S({type:e});static \u0275inj=g({imports:[u,D.forChild(U),C]})}return e})();export{st as Coordinator_Module};
2
- //# sourceMappingURL=crd.module-EH2RIMWD.js.map
1
+ import{a as B}from"./chunk-CROOTWQ4.js";import"./chunk-ACLAVYA7.js";import"./chunk-66YFYBOC.js";import"./chunk-ZJ3DCODZ.js";import{$a as A,C as v,D as b,E as S,Fa as i,G as E,Ha as c,Ia as w,Kb as D,Ta as $,Z as r,aa as h,ab as I,da as p,ga as _,hb as T,k as f,la as s,mb as k,oa as y,pa as F,qa as o,ra as n,ub as u,va as x,wa as m,z as g}from"./chunk-TBMJSIBB.js";var R={respond:"bg-green-500/20 text-green-400","status-update":"bg-blue-500/20 text-blue-400",stop:"bg-neutral-500/20 text-neutral-400","request-user-interaction":"bg-yellow-500/20 text-yellow-400"},M="bg-neutral-700/20 text-neutral-500",P=(()=>{class e{transform(t){return t?R[t]??M:M}static \u0275fac=function(a){return new(a||e)};static \u0275pipe=E({name:"ccapCoordinatorActionBadge",type:e,pure:!0,standalone:!0})}return e})();var K=(e,l)=>l._id;function O(e,l){e&1&&(o(0,"div",13),i(1," Loading coordinators... "),n())}function z(e,l){e&1&&(o(0,"div",14),i(1," Nincs koordin\xE1tor session. "),n())}function G(e,l){if(e&1&&i(0),e&2){let t=m(2).$implicit;c(" \xB7 WF: ",t.workflowId," ")}}function q(e,l){if(e&1&&(o(0,"div",22),i(1),p(2,G,1,1),n()),e&2){let t=m().$implicit;r(),w(" ",t.providerName,":",t.model," "),r(),s(t.workflowId?2:-1)}}function V(e,l){if(e&1&&(o(0,"span",24),A(1,"ccapCoordinatorActionBadge"),i(2),n()),e&2){let t=m().$implicit;_("ngClass",I(1,2,t.decisions[t.decisions.length-1].action)),r(2),c(" ",t.decisions[t.decisions.length-1].action," ")}}function W(e,l){if(e&1&&(o(0,"div",25),i(1),n()),e&2){let t=m().$implicit;r(),c(" ",t.decisions[t.decisions.length-1].reasoning," ")}}function H(e,l){if(e&1&&(o(0,"div",26),i(1),n()),e&2){let t=m().$implicit;r(),c(" Pause reason: ",t.pauseReason," ")}}function J(e,l){if(e&1&&(o(0,"div",16)(1,"div",17)(2,"div",18)(3,"span",19),i(4),n(),o(5,"div",20)(6,"div",21),i(7),n(),p(8,q,3,3,"div",22),n()(),o(9,"div",23)(10,"span",6),i(11),n(),p(12,V,3,4,"span",24),n()(),p(13,W,2,1,"div",25)(14,H,2,1,"div",26),n()),e&2){let t=l.$implicit,a=m(2);r(3),_("ngClass",a.getStatusBadgeClass(t.status)),r(),c(" ",t.status," "),r(3),c(" Session: ",t.sessionId," "),r(),s(t.providerName||t.model?8:-1),r(3),c(" ",t.totalStepCount," steps "),r(),s(t.decisions&&t.decisions.length>0?12:-1),r(),s(t.decisions&&t.decisions.length>0?13:-1),r(),s(t.pauseReason?14:-1)}}function Q(e,l){if(e&1&&(o(0,"div",15),y(1,J,15,8,"div",16,K),n()),e&2){let t=m();r(),F(t.filteredCoordinators_$())}}var C=(()=>{class e{coordinator_DS=v(B);statusFilter_$=h("");filteredCoordinators_$=T(()=>{let t=this.statusFilter_$(),a=this.coordinator_DS.globalCoordinatorsList_$();return t?a.filter(d=>d.status===t):a});ngOnInit(){this.loadCoordinators()}loadCoordinators(){return f(this,null,function*(){yield this.coordinator_DS.loadAllCoordinatorsForManagementPage()})}handleFilterChange(t){let a=t.target;!a||!("value"in a)||this.statusFilter_$.set(String(a.value))}getStatusBadgeClass(t){switch(t){case"active":return"bg-green-500/20 text-green-400";case"paused":return"bg-yellow-500/20 text-yellow-400";case"completed":return"bg-neutral-500/20 text-neutral-400";case"failed":return"bg-red-500/20 text-red-400";default:return"bg-neutral-700/20 text-neutral-500"}}static \u0275fac=function(a){return new(a||e)};static \u0275cmp=b({type:e,selectors:[["app-ccap-coordinator"]],standalone:!0,features:[$],decls:28,vars:4,consts:[[1,"max-w-5xl","mx-auto","p-4","gt-xs:p-6","text-neutral-100"],[1,"flex","items-center","justify-between","mb-6"],[1,"text-2xl","font-bold"],[1,"text-neutral-400","text-sm","mt-1"],[1,"px-3","py-1.5","text-xs","border","border-neutral-600","text-neutral-300","rounded","hover:bg-neutral-800","transition-colors",3,"click"],[1,"flex","items-center","gap-3","mb-4"],[1,"text-xs","text-neutral-500"],[1,"bg-neutral-800","border","border-neutral-600","rounded","px-2","py-1","text-xs","text-neutral-200","outline-none","focus:border-neonDefault",3,"change"],["value",""],["value","active"],["value","paused"],["value","completed"],["value","failed"],[1,"text-center","py-8","text-neutral-500","text-sm"],[1,"rounded-lg","border","border-neutral-700","bg-ccapSurface/50","p-8","text-center","text-neutral-500","text-sm"],[1,"space-y-2"],[1,"rounded-lg","border","border-neutral-700","bg-ccapSurface/50","p-4","hover:border-neutral-600","transition-colors"],[1,"flex","items-center","justify-between","gap-4"],[1,"flex","items-center","gap-3","min-w-0"],[1,"text-xs","px-2","py-0.5","rounded","shrink-0",3,"ngClass"],[1,"min-w-0"],[1,"text-sm","text-neutral-200","truncate"],[1,"text-xs","text-neutral-500","mt-0.5"],[1,"flex","items-center","gap-3","shrink-0"],[1,"text-xs","px-1.5","py-0.5","rounded",3,"ngClass"],[1,"text-xs","text-neutral-400","mt-2","truncate"],[1,"text-xs","text-yellow-400/80","mt-1"]],template:function(a,d){a&1&&(o(0,"div",0)(1,"div",1)(2,"div")(3,"h1",2),i(4,"Koordin\xE1tor"),n(),o(5,"p",3),i(6," Koordin\xE1tor session-\xF6k kezel\xE9se \u2014 workflow-alap\xFA agent vez\xE9rl\xE9s. "),n()(),o(7,"button",4),x("click",function(){return d.loadCoordinators()}),i(8," Refresh "),n()(),o(9,"div",5)(10,"span",6),i(11,"Filter:"),n(),o(12,"select",7),x("change",function(j){return d.handleFilterChange(j)}),o(13,"option",8),i(14,"All"),n(),o(15,"option",9),i(16,"Active"),n(),o(17,"option",10),i(18,"Paused"),n(),o(19,"option",11),i(20,"Completed"),n(),o(21,"option",12),i(22,"Failed"),n()(),o(23,"span",6),i(24),n()(),p(25,O,2,0,"div",13)(26,z,2,0,"div",14)(27,Q,3,0,"div",15),n()),a&2&&(r(24),c(" ",d.filteredCoordinators_$().length," coordinator(s) "),r(),s(d.coordinator_DS.globalCoordinatorsListLoading_$()?25:-1),r(),s(!d.coordinator_DS.globalCoordinatorsListLoading_$()&&d.filteredCoordinators_$().length===0?26:-1),r(),s(!d.coordinator_DS.globalCoordinatorsListLoading_$()&&d.filteredCoordinators_$().length>0?27:-1))},dependencies:[u,k,P],encapsulation:2})}return e})();var U=[{path:"",pathMatch:"full",component:C}],st=(()=>{class e{static \u0275fac=function(a){return new(a||e)};static \u0275mod=S({type:e});static \u0275inj=g({imports:[u,D.forChild(U),C]})}return e})();export{st as Coordinator_Module};
2
+ //# sourceMappingURL=crd.module-TDLM6M2Z.js.map
@@ -1,2 +1,2 @@
1
- import{a as V}from"./chunk-AQO5IW5B.js";import{a as x,b as f}from"./chunk-6Y7O2W4H.js";import{d as W}from"./chunk-OVD3GSH2.js";import"./chunk-SG5TSGOY.js";import{a as O}from"./chunk-Q2NVIOCY.js";import{a as U}from"./chunk-J32YRK3S.js";import"./chunk-V3VQWJQL.js";import{k as b}from"./chunk-I4M7XPFX.js";import"./chunk-5UPNU54P.js";import"./chunk-WXN5C3BS.js";import{p as tt}from"./chunk-5N64HGRY.js";import{C as S,D as N,E as R,Fa as o,Ga as c,Ha as p,Hb as B,J as D,K as y,Kb as G,Z as l,aa as h,da as d,ga as g,h as Z,hb as k,ia as I,k as F,la as s,na as z,oa as v,pa as E,qa as i,ra as n,sa as u,ua as T,ub as j,va as $,wa as _,y as P,z as M}from"./chunk-TBMJSIBB.js";var J=Z(tt());var K=(()=>{class t{status_$=h(null);statusLoading_$=h(!1);statusLoadError_$=h(null);serverStatus_AS=S(V);loadStatus(){return F(this,null,function*(){this.statusLoading_$.set(!0),this.statusLoadError_$.set(null);try{let e=yield this.serverStatus_AS.getStatus();return this.status_$.set(e),e}catch(e){return J.DyFM_Error.logSimple("CCAP_ServerStatusDS | Failed to load status",e),this.statusLoadError_$.set(e),null}finally{this.statusLoading_$.set(!1)}})}getCachedStatus(){return this.status_$()}static \u0275fac=function(r){return new(r||t)};static \u0275prov=P({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var et=(t,a)=>a.name,nt=(t,a)=>a._id,it=(t,a)=>a.sessionId;function ot(t,a){if(t&1){let e=T();i(0,"button",6),$("click",function(){D(e);let m=_();return y(m.loadStatus())}),o(1," Friss\xEDt\xE9s "),n()}}function at(t,a){t&1&&(i(0,"div",5)(1,"p",7),o(2,"Bet\xF6lt\xE9s\u2026"),n()())}function lt(t,a){if(t&1){let e=T();i(0,"div",8),u(1,"app-ccap-error-display",9),i(2,"div",10)(3,"button",11),$("click",function(){D(e);let m=_(2);return y(m.loadStatus())}),o(4," \xDAjrapr\xF3b\xE1l\xE1s "),n()()()}if(t&2){let e=_(2);l(),g("error",e.serverStatus_DS.statusLoadError_$())}}function rt(t,a){t&1&&(i(0,"p",15),o(1,"Nincs enged\xE9lyezett messaging provider (Setup \u2192 enged\xE9lyez\xE9s)."),n())}function _t(t,a){t&1&&(i(0,"span",29),o(1," working "),n())}function st(t,a){if(t&1&&(i(0,"span",31),o(1),n()),t&2){let e=_(2).$implicit;g("title",e.error),l(),c(e.error)}}function dt(t,a){if(t&1&&(i(0,"span",30),o(1," disconnected "),n(),d(2,st,2,2,"span",31)),t&2){let e=_().$implicit;l(2),s(e.error?2:-1)}}function mt(t,a){if(t&1&&(i(0,"li",27)(1,"span",28),o(2),n(),d(3,_t,2,0,"span",29)(4,dt,3,1),n()),t&2){let e=a.$implicit,r=_(5);l(2),c(r.MESSAGING_PROVIDER_NAMES[e.name]),l(),s(e.connected?3:4)}}function ct(t,a){if(t&1&&(i(0,"ul",16),v(1,mt,5,2,"li",27,et),n()),t&2){let e=_();l(),E(e.messagingProviders)}}function ut(t,a){t&1&&(i(0,"p",15),o(1,"Nincs enged\xE9lyezett LLM provider (Setup \u2192 enged\xE9lyez\xE9s)."),n())}function pt(t,a){if(t&1&&(i(0,"li",27)(1,"span",28),o(2),n(),i(3,"span",29),o(4," enged\xE9lyezve "),n()()),t&2){let e=a.$implicit,r=_(5);l(2),c(r.llmProviderDisplayLabelsMap_$()[e])}}function Ct(t,a){if(t&1&&(i(0,"ul",16),v(1,pt,5,1,"li",27,z),n()),t&2){let e=_();l(),E(e.llmProviders)}}function xt(t,a){if(t&1&&(i(0,"p",21)(1,"span",32),o(2),n(),o(3," akt\xEDv az elm\xFAlt 24 \xF3r\xE1ban "),n()),t&2){let e=_();l(2),c(e.sessionSummary.recentActivityCount)}}function ft(t,a){if(t&1&&(i(0,"p",22),u(1,"span",33),i(2,"span",34),o(3),n(),i(4,"span",7),o(5," r\xF6gz\xEDtett hiba a legut\xF3bbi 24 \xF3r\xE1ban "),n()()),t&2){let e=_();l(),I("bg-red-500",e.lastErrorCount>0)("bg-green-500",e.lastErrorCount===0),l(),I("text-red-300",e.lastErrorCount>0)("text-green-300",e.lastErrorCount===0),l(),p(" ",e.lastErrorCount," ")}}function St(t,a){t&1&&(i(0,"p",15),o(1,"Bet\xF6lt\xE9s\u2026"),n())}function vt(t,a){t&1&&(i(0,"p",15),o(1,"Nem siker\xFClt bet\xF6lteni az instance adatokat."),n())}function Et(t,a){if(t&1&&(i(0,"div",36),u(1,"span",45),i(2,"span",38),o(3),n(),i(4,"span",15),o(5,"inactive"),n()()),t&2){let e=_(5);l(3),c(e.instanceSummary_$().inactiveCount)}}function ht(t,a){if(t&1&&(i(0,"div",36),u(1,"span",46),i(2,"span",38),o(3),n(),i(4,"span",15),o(5,"maintenance"),n()()),t&2){let e=_(5);l(3),c(e.instanceSummary_$().maintenanceCount)}}function gt(t,a){if(t&1&&(i(0,"span",40),o(1),n()),t&2){let e=_(5);l(),p("",e.instanceSummary_$().workingSessionCount," working")}}function bt(t,a){if(t&1&&(i(0,"span",41),o(1),n()),t&2){let e=_(5);l(),p("",e.instanceSummary_$().idleSessionCount," idle")}}function Dt(t,a){if(t&1&&(i(0,"span",42),o(1),n()),t&2){let e=_(5);l(),p("",e.instanceSummary_$().offlineSessionCount," offline")}}function yt(t,a){t&1&&(i(0,"span",43),o(1,"nincs session adat"),n())}function It(t,a){t&1&&(i(0,"p",15),o(1,"Nincs regisztr\xE1lt instance."),n())}function Tt(t,a){t&1&&(i(0,"span",29),o(1,"Active"),n())}function $t(t,a){t&1&&(i(0,"span",50),o(1,"Inactive"),n())}function kt(t,a){t&1&&(i(0,"span",30),o(1,"Maintenance"),n())}function wt(t,a){t&1&&u(0,"span",55)}function Ht(t,a){t&1&&u(0,"span",56)}function Lt(t,a){t&1&&u(0,"span",57)}function At(t,a){if(t&1&&(i(0,"p",60),o(1),n()),t&2){let e=_().$implicit;l(),c(e.activitySummary)}}function Ft(t,a){if(t&1&&(i(0,"div",54),d(1,wt,1,0,"span",55)(2,Ht,1,0,"span",56)(3,Lt,1,0,"span",57),i(4,"span",58),o(5),n(),i(6,"span",59),o(7),n()(),d(8,At,2,1,"p",60)),t&2){let e,r=a.$implicit,m=_(8);l(),s((e=r.presence)==="working"?1:e==="idle"?2:3),l(4),p(" ",r.sessionName||r.sessionId," "),l(2),c(m.PRESENCE_LABELS[r.presence]),l(),s(r.activitySummary?8:-1)}}function Pt(t,a){if(t&1&&(i(0,"div",52),v(1,Ft,9,4,null,null,it),n()),t&2){let e=_().$implicit;l(),E(e.sessionStatuses)}}function Mt(t,a){t&1&&(i(0,"p",53),o(1,"Nincs session adat"),n())}function Nt(t,a){if(t&1&&(i(0,"div",47)(1,"div",48)(2,"span",49),o(3),n(),d(4,Tt,2,0,"span",29)(5,$t,2,0,"span",50)(6,kt,2,0,"span",30),n(),i(7,"span",51),o(8),n(),d(9,Pt,3,0,"div",52)(10,Mt,2,0,"p",53),n()),t&2){let e,r=a.$implicit;l(3),p(" ",r.name||r.ccapId," "),l(),s((e=r.status)==="active"?4:e==="inactive"?5:e==="maintenance"?6:-1),l(3),g("title",r.ccapId),l(),p(" ",r.ccapId," "),l(),s(r.sessionStatuses&&r.sessionStatuses.length>0?9:10)}}function Rt(t,a){if(t&1&&(i(0,"div",44),v(1,Nt,11,5,"div",47,nt),n()),t&2){let e=_(5);l(),E(e.runtimeInstances_DS.ccapInstanceList_$())}}function zt(t,a){if(t&1&&(i(0,"div",35)(1,"div",36)(2,"span",19),o(3),n(),i(4,"span",21),o(5,"instance"),n()(),i(6,"div",36),u(7,"span",37),i(8,"span",38),o(9),n(),i(10,"span",15),o(11,"active"),n()(),d(12,Et,6,1,"div",36)(13,ht,6,1,"div",36),i(14,"div",39)(15,"span",21),o(16,"Sessions:"),n(),d(17,gt,2,1,"span",40)(18,bt,2,1,"span",41)(19,Dt,2,1,"span",42)(20,yt,2,0,"span",43),n()(),d(21,It,2,0,"p",15)(22,Rt,3,0,"div",44)),t&2){let e=_(4);l(3),c(e.instanceSummary_$().totalCount),l(6),c(e.instanceSummary_$().activeCount),l(3),s(e.instanceSummary_$().inactiveCount?12:-1),l(),s(e.instanceSummary_$().maintenanceCount?13:-1),l(4),s(e.instanceSummary_$().workingSessionCount?17:-1),l(),s(e.instanceSummary_$().idleSessionCount?18:-1),l(),s(e.instanceSummary_$().offlineSessionCount?19:-1),l(),s(!e.instanceSummary_$().workingSessionCount&&!e.instanceSummary_$().idleSessionCount&&!e.instanceSummary_$().offlineSessionCount?20:-1),l(),s(e.runtimeInstances_DS.ccapInstanceList_$().length===0?21:22)}}function jt(t,a){if(t&1&&(i(0,"div",12)(1,"section",13)(2,"h2",14),o(3,"Messaging provider-ek"),n(),d(4,rt,2,0,"p",15)(5,ct,3,0,"ul",16),n(),i(6,"section",13)(7,"h2",14),o(8,"LLM provider-ek"),n(),d(9,ut,2,0,"p",15)(10,Ct,3,0,"ul",16),n(),i(11,"section",13)(12,"h2",14),o(13,"Session \xF6sszes\xEDt\u0151"),n(),i(14,"div",17)(15,"p",18)(16,"span",19),o(17),n(),i(18,"span",20),o(19,"session"),n()(),d(20,xt,4,1,"p",21)(21,ft,6,9,"p",22),n()(),i(22,"section",23)(23,"h2",14),o(24,"Instance \xE1ttekint\u0151"),n(),d(25,St,2,0,"p",15)(26,vt,2,0,"p",15)(27,zt,23,9),n(),i(28,"section",13)(29,"h2",14),o(30,"Gyors linkek"),n(),i(31,"div",24)(32,"a",25),o(33," Open Sessions "),n(),i(34,"a",26),o(35," Be\xE1ll\xEDt\xE1sok "),n()()()()),t&2){let e=a,r=_(3);l(4),s(e.messagingProviders.length===0?4:5),l(5),s(e.llmProviders.length===0?9:10),l(8),c(e.sessionSummary.totalCount),l(3),s(e.sessionSummary.recentActivityCount!==void 0?20:-1),l(),s(e.lastErrorCount!==void 0&&e.lastErrorCount!==null?21:-1),l(4),s(r.runtimeInstances_DS.ccapInstanceListLoading_$()?25:r.runtimeInstances_DS.ccapInstanceListError_$()?26:27)}}function Bt(t,a){if(t&1&&d(0,jt,36,6,"div",12),t&2){let e,r=_(2);s((e=r.serverStatus_DS.status_$())?0:-1,e)}}function Gt(t,a){if(t&1&&d(0,lt,5,1,"div",8)(1,Bt,1,1),t&2){let e=_();s(e.serverStatus_DS.statusLoadError_$()?0:1)}}var Vt={"ccap-client":"CCAP Client","ccap-cli":"CCAP CLI",discord:"Discord"},Ot={[x.active]:"Active",[x.inactive]:"Inactive",[x.maintenance]:"Maintenance"},Ut={[f.working]:"Working",[f.idle]:"Idle",[f.offline]:"Offline"},Q=(()=>{class t{title="CCAP Revisioned";serverStatus_DS=S(K);runtimeInstances_DS=S(W);MESSAGING_PROVIDER_NAMES=Vt;INSTANCE_STATUS_LABELS=Ot;PRESENCE_LABELS=Ut;instanceSummary_$=k(()=>{let e=this.runtimeInstances_DS.ccapInstanceList_$(),r=e.length,m=e.filter(C=>C.status===x.active).length,X=e.filter(C=>C.status===x.inactive).length,Y=e.filter(C=>C.status===x.maintenance).length,w=0,H=0,L=0;for(let C of e)for(let A of C.sessionStatuses??[])A.presence===f.working?w++:A.presence===f.idle?H++:L++;return{totalCount:r,activeCount:m,inactiveCount:X,maintenanceCount:Y,workingSessionCount:w,idleSessionCount:H,offlineSessionCount:L}});llmProviderDisplayLabelsMap_$=k(()=>{let e=this.serverStatus_DS.status_$();if(!e)return{};let r={};for(let m of e.llmProviders)r[m]=U.getProviderDisplayLabel(m,null);return r});ngOnInit(){this.serverStatus_DS.loadStatus(),this.runtimeInstances_DS.loadCcapInstanceList()}loadStatus(){this.serverStatus_DS.loadStatus(),this.runtimeInstances_DS.loadCcapInstanceList()}static \u0275fac=function(r){return new(r||t)};static \u0275cmp=N({type:t,selectors:[["app-ccap-home"]],decls:10,vars:3,consts:[[1,"flex","flex-col","min-h-full","text-neutral-100","p-4","gt-xs:p-6"],[1,"flex","flex-col","xs:flex-row","xs:items-center","xs:justify-between","gap-4","mb-6"],[1,"text-2xl","gt-xs:text-3xl","font-bold","text-neutral-100"],[1,"text-neutral-400","text-sm","gt-xs:text-base","mt-1"],["type","button",1,"shrink-0","px-4","py-2","border","border-neonCyan","rounded-lg","text-neutral-400","text-sm","font-medium","hover:bg-neutral-800","hover:text-neutral-200","hover:shadow-neon-glow-cyan","transition-colors"],[1,"flex","items-center","justify-center","py-16"],["type","button",1,"shrink-0","px-4","py-2","border","border-neonCyan","rounded-lg","text-neutral-400","text-sm","font-medium","hover:bg-neutral-800","hover:text-neutral-200","hover:shadow-neon-glow-cyan","transition-colors",3,"click"],[1,"text-neutral-400"],[1,"rounded-lg","bg-neutral-800/60","border","border-red-500/50","p-6","max-w-2xl"],["sourceLabelOverride","St\xE1tusz bet\xF6lt\xE9s",1,"mb-4","block",3,"error"],[1,"text-center"],["type","button",1,"px-4","py-2","border","border-neonCyan","rounded-lg","text-neutral-300","text-sm","font-medium","hover:bg-neutral-700","hover:shadow-neon-glow-cyan","transition-colors",3,"click"],[1,"grid","grid-cols-1","md:grid-cols-2","lg:grid-cols-3","gap-4","mb-8"],[1,"flex","flex-col","rounded-lg","bg-neutral-800/60","border","border-neonDefault","p-4","min-h-0"],[1,"text-lg","font-semibold","text-neutral-200","mb-3","shrink-0"],[1,"text-neutral-500","text-sm"],[1,"space-y-2","min-h-0"],[1,"flex","flex-col","gap-1","min-h-0"],[1,"text-neutral-300"],[1,"text-2xl","font-bold","text-neutral-100"],[1,"ml-1"],[1,"text-neutral-400","text-sm"],[1,"text-sm","mt-1","flex","items-center","gap-1.5"],[1,"flex","flex-col","rounded-lg","bg-neutral-800/60","border","border-neonDefault","p-4","min-h-0","md:col-span-2","lg:col-span-3"],[1,"flex","flex-wrap","gap-3"],["routerLink","/session",1,"inline-flex","items-center","px-5","py-2.5","border","border-ccapAccent","rounded-lg","text-ccapAccent","text-sm","font-semibold","transition-colors","duration-200","hover:bg-ccapAccent","hover:text-white","hover:shadow-neon-glow-accent"],["routerLink","/settings",1,"inline-flex","items-center","px-5","py-2.5","border","border-neonCyan","rounded-lg","text-neutral-300","text-sm","font-semibold","transition-colors","duration-200","hover:bg-neutral-700","hover:text-white","hover:shadow-neon-glow-cyan"],[1,"flex","items-center","gap-3","flex-wrap"],[1,"text-neutral-200","font-medium"],[1,"px-2","py-0.5","text-xs","font-medium","rounded","bg-green-900/50","text-green-300","border","border-neonGreen","shrink-0"],[1,"px-2","py-0.5","text-xs","font-medium","rounded","bg-amber-900/50","text-amber-300","border","border-neonAmber","shrink-0"],[1,"text-neutral-500","text-xs","truncate","max-w-full",3,"title"],[1,"font-medium","text-neutral-300"],["aria-hidden","true",1,"inline-block","w-2","h-2","rounded-full","shrink-0"],[1,"font-medium"],[1,"flex","flex-wrap","gap-4","mb-4"],[1,"flex","items-center","gap-2"],[1,"w-2","h-2","rounded-full","bg-green-500","shrink-0"],[1,"text-neutral-300","text-sm","font-medium"],[1,"border-l","border-neutral-700","pl-4","flex","items-center","gap-2"],[1,"px-2","py-0.5","text-xs","font-medium","rounded","bg-green-900/50","text-green-300","border","border-neonGreen"],[1,"px-2","py-0.5","text-xs","font-medium","rounded","bg-amber-900/50","text-amber-300","border","border-neonAmber"],[1,"px-2","py-0.5","text-xs","font-medium","rounded","bg-neutral-700/50","text-neutral-400","border","border-neutral-600"],[1,"text-neutral-500","text-xs"],[1,"grid","grid-cols-1","md:grid-cols-2","lg:grid-cols-3","gap-3"],[1,"w-2","h-2","rounded-full","bg-neutral-500","shrink-0"],[1,"w-2","h-2","rounded-full","bg-amber-500","shrink-0"],[1,"rounded-md","border","border-neutral-700","bg-neutral-800/40","p-3","flex","flex-col","gap-2"],[1,"flex","items-center","justify-between","gap-2"],[1,"text-neutral-100","font-medium","text-sm","truncate"],[1,"px-2","py-0.5","text-xs","font-medium","rounded","bg-neutral-700/50","text-neutral-400","border","border-neutral-600","shrink-0"],[1,"text-neutral-500","text-xs","font-mono","truncate",3,"title"],[1,"flex","flex-col","gap-1.5","mt-1","pt-2","border-t","border-neutral-700/50"],[1,"text-neutral-600","text-xs","mt-1"],[1,"flex","items-center","gap-2","text-xs"],[1,"w-1.5","h-1.5","rounded-full","bg-green-500","shrink-0"],[1,"w-1.5","h-1.5","rounded-full","bg-amber-500","shrink-0"],[1,"w-1.5","h-1.5","rounded-full","bg-neutral-500","shrink-0"],[1,"text-neutral-300","truncate"],[1,"text-neutral-500","shrink-0"],[1,"text-neutral-500","text-xs","pl-3.5","-mt-1","truncate"]],template:function(r,m){r&1&&(i(0,"div",0)(1,"header",1)(2,"div")(3,"h1",2),o(4),n(),i(5,"p",3),o(6,"Agentic AI System"),n()(),d(7,ot,2,0,"button",4),n(),d(8,at,3,0,"div",5)(9,Gt,2,1),n()),r&2&&(l(4),c(m.title),l(3),s(!m.serverStatus_DS.statusLoading_$()&&!m.serverStatus_DS.statusLoadError_$()&&m.serverStatus_DS.status_$()?7:-1),l(),s(m.serverStatus_DS.statusLoading_$()?8:9))},dependencies:[B,b],encapsulation:2})}return t})();var Wt=[{path:"",pathMatch:"full",component:Q}],ue=(()=>{class t{static \u0275fac=function(r){return new(r||t)};static \u0275mod=R({type:t});static \u0275inj=M({imports:[j,G.forChild(Wt),b,O]})}return t})();export{ue as Dashboard_Module};
2
- //# sourceMappingURL=dashboard.module-EROOHU4C.js.map
1
+ import{a as V}from"./chunk-CJXAN5QP.js";import{a as x,b as f}from"./chunk-6Y7O2W4H.js";import{d as W}from"./chunk-OJPFXL3T.js";import"./chunk-4ORBCWDZ.js";import{a as O}from"./chunk-Q2NVIOCY.js";import{a as U}from"./chunk-J32YRK3S.js";import"./chunk-V3VQWJQL.js";import{k as b}from"./chunk-SUAZOLRE.js";import"./chunk-5UPNU54P.js";import"./chunk-66YFYBOC.js";import{p as tt}from"./chunk-ZJ3DCODZ.js";import{C as S,D as N,E as R,Fa as o,Ga as c,Ha as p,Hb as B,J as D,K as y,Kb as G,Z as l,aa as h,da as d,ga as g,h as Z,hb as k,ia as I,k as F,la as s,na as z,oa as v,pa as E,qa as i,ra as n,sa as u,ua as T,ub as j,va as $,wa as _,y as P,z as M}from"./chunk-TBMJSIBB.js";var J=Z(tt());var K=(()=>{class t{status_$=h(null);statusLoading_$=h(!1);statusLoadError_$=h(null);serverStatus_AS=S(V);loadStatus(){return F(this,null,function*(){this.statusLoading_$.set(!0),this.statusLoadError_$.set(null);try{let e=yield this.serverStatus_AS.getStatus();return this.status_$.set(e),e}catch(e){return J.DyFM_Error.logSimple("CCAP_ServerStatusDS | Failed to load status",e),this.statusLoadError_$.set(e),null}finally{this.statusLoading_$.set(!1)}})}getCachedStatus(){return this.status_$()}static \u0275fac=function(r){return new(r||t)};static \u0275prov=P({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var et=(t,a)=>a.name,nt=(t,a)=>a._id,it=(t,a)=>a.sessionId;function ot(t,a){if(t&1){let e=T();i(0,"button",6),$("click",function(){D(e);let m=_();return y(m.loadStatus())}),o(1," Friss\xEDt\xE9s "),n()}}function at(t,a){t&1&&(i(0,"div",5)(1,"p",7),o(2,"Bet\xF6lt\xE9s\u2026"),n()())}function lt(t,a){if(t&1){let e=T();i(0,"div",8),u(1,"app-ccap-error-display",9),i(2,"div",10)(3,"button",11),$("click",function(){D(e);let m=_(2);return y(m.loadStatus())}),o(4," \xDAjrapr\xF3b\xE1l\xE1s "),n()()()}if(t&2){let e=_(2);l(),g("error",e.serverStatus_DS.statusLoadError_$())}}function rt(t,a){t&1&&(i(0,"p",15),o(1,"Nincs enged\xE9lyezett messaging provider (Setup \u2192 enged\xE9lyez\xE9s)."),n())}function _t(t,a){t&1&&(i(0,"span",29),o(1," working "),n())}function st(t,a){if(t&1&&(i(0,"span",31),o(1),n()),t&2){let e=_(2).$implicit;g("title",e.error),l(),c(e.error)}}function dt(t,a){if(t&1&&(i(0,"span",30),o(1," disconnected "),n(),d(2,st,2,2,"span",31)),t&2){let e=_().$implicit;l(2),s(e.error?2:-1)}}function mt(t,a){if(t&1&&(i(0,"li",27)(1,"span",28),o(2),n(),d(3,_t,2,0,"span",29)(4,dt,3,1),n()),t&2){let e=a.$implicit,r=_(5);l(2),c(r.MESSAGING_PROVIDER_NAMES[e.name]),l(),s(e.connected?3:4)}}function ct(t,a){if(t&1&&(i(0,"ul",16),v(1,mt,5,2,"li",27,et),n()),t&2){let e=_();l(),E(e.messagingProviders)}}function ut(t,a){t&1&&(i(0,"p",15),o(1,"Nincs enged\xE9lyezett LLM provider (Setup \u2192 enged\xE9lyez\xE9s)."),n())}function pt(t,a){if(t&1&&(i(0,"li",27)(1,"span",28),o(2),n(),i(3,"span",29),o(4," enged\xE9lyezve "),n()()),t&2){let e=a.$implicit,r=_(5);l(2),c(r.llmProviderDisplayLabelsMap_$()[e])}}function Ct(t,a){if(t&1&&(i(0,"ul",16),v(1,pt,5,1,"li",27,z),n()),t&2){let e=_();l(),E(e.llmProviders)}}function xt(t,a){if(t&1&&(i(0,"p",21)(1,"span",32),o(2),n(),o(3," akt\xEDv az elm\xFAlt 24 \xF3r\xE1ban "),n()),t&2){let e=_();l(2),c(e.sessionSummary.recentActivityCount)}}function ft(t,a){if(t&1&&(i(0,"p",22),u(1,"span",33),i(2,"span",34),o(3),n(),i(4,"span",7),o(5," r\xF6gz\xEDtett hiba a legut\xF3bbi 24 \xF3r\xE1ban "),n()()),t&2){let e=_();l(),I("bg-red-500",e.lastErrorCount>0)("bg-green-500",e.lastErrorCount===0),l(),I("text-red-300",e.lastErrorCount>0)("text-green-300",e.lastErrorCount===0),l(),p(" ",e.lastErrorCount," ")}}function St(t,a){t&1&&(i(0,"p",15),o(1,"Bet\xF6lt\xE9s\u2026"),n())}function vt(t,a){t&1&&(i(0,"p",15),o(1,"Nem siker\xFClt bet\xF6lteni az instance adatokat."),n())}function Et(t,a){if(t&1&&(i(0,"div",36),u(1,"span",45),i(2,"span",38),o(3),n(),i(4,"span",15),o(5,"inactive"),n()()),t&2){let e=_(5);l(3),c(e.instanceSummary_$().inactiveCount)}}function ht(t,a){if(t&1&&(i(0,"div",36),u(1,"span",46),i(2,"span",38),o(3),n(),i(4,"span",15),o(5,"maintenance"),n()()),t&2){let e=_(5);l(3),c(e.instanceSummary_$().maintenanceCount)}}function gt(t,a){if(t&1&&(i(0,"span",40),o(1),n()),t&2){let e=_(5);l(),p("",e.instanceSummary_$().workingSessionCount," working")}}function bt(t,a){if(t&1&&(i(0,"span",41),o(1),n()),t&2){let e=_(5);l(),p("",e.instanceSummary_$().idleSessionCount," idle")}}function Dt(t,a){if(t&1&&(i(0,"span",42),o(1),n()),t&2){let e=_(5);l(),p("",e.instanceSummary_$().offlineSessionCount," offline")}}function yt(t,a){t&1&&(i(0,"span",43),o(1,"nincs session adat"),n())}function It(t,a){t&1&&(i(0,"p",15),o(1,"Nincs regisztr\xE1lt instance."),n())}function Tt(t,a){t&1&&(i(0,"span",29),o(1,"Active"),n())}function $t(t,a){t&1&&(i(0,"span",50),o(1,"Inactive"),n())}function kt(t,a){t&1&&(i(0,"span",30),o(1,"Maintenance"),n())}function wt(t,a){t&1&&u(0,"span",55)}function Ht(t,a){t&1&&u(0,"span",56)}function Lt(t,a){t&1&&u(0,"span",57)}function At(t,a){if(t&1&&(i(0,"p",60),o(1),n()),t&2){let e=_().$implicit;l(),c(e.activitySummary)}}function Ft(t,a){if(t&1&&(i(0,"div",54),d(1,wt,1,0,"span",55)(2,Ht,1,0,"span",56)(3,Lt,1,0,"span",57),i(4,"span",58),o(5),n(),i(6,"span",59),o(7),n()(),d(8,At,2,1,"p",60)),t&2){let e,r=a.$implicit,m=_(8);l(),s((e=r.presence)==="working"?1:e==="idle"?2:3),l(4),p(" ",r.sessionName||r.sessionId," "),l(2),c(m.PRESENCE_LABELS[r.presence]),l(),s(r.activitySummary?8:-1)}}function Pt(t,a){if(t&1&&(i(0,"div",52),v(1,Ft,9,4,null,null,it),n()),t&2){let e=_().$implicit;l(),E(e.sessionStatuses)}}function Mt(t,a){t&1&&(i(0,"p",53),o(1,"Nincs session adat"),n())}function Nt(t,a){if(t&1&&(i(0,"div",47)(1,"div",48)(2,"span",49),o(3),n(),d(4,Tt,2,0,"span",29)(5,$t,2,0,"span",50)(6,kt,2,0,"span",30),n(),i(7,"span",51),o(8),n(),d(9,Pt,3,0,"div",52)(10,Mt,2,0,"p",53),n()),t&2){let e,r=a.$implicit;l(3),p(" ",r.name||r.ccapId," "),l(),s((e=r.status)==="active"?4:e==="inactive"?5:e==="maintenance"?6:-1),l(3),g("title",r.ccapId),l(),p(" ",r.ccapId," "),l(),s(r.sessionStatuses&&r.sessionStatuses.length>0?9:10)}}function Rt(t,a){if(t&1&&(i(0,"div",44),v(1,Nt,11,5,"div",47,nt),n()),t&2){let e=_(5);l(),E(e.runtimeInstances_DS.ccapInstanceList_$())}}function zt(t,a){if(t&1&&(i(0,"div",35)(1,"div",36)(2,"span",19),o(3),n(),i(4,"span",21),o(5,"instance"),n()(),i(6,"div",36),u(7,"span",37),i(8,"span",38),o(9),n(),i(10,"span",15),o(11,"active"),n()(),d(12,Et,6,1,"div",36)(13,ht,6,1,"div",36),i(14,"div",39)(15,"span",21),o(16,"Sessions:"),n(),d(17,gt,2,1,"span",40)(18,bt,2,1,"span",41)(19,Dt,2,1,"span",42)(20,yt,2,0,"span",43),n()(),d(21,It,2,0,"p",15)(22,Rt,3,0,"div",44)),t&2){let e=_(4);l(3),c(e.instanceSummary_$().totalCount),l(6),c(e.instanceSummary_$().activeCount),l(3),s(e.instanceSummary_$().inactiveCount?12:-1),l(),s(e.instanceSummary_$().maintenanceCount?13:-1),l(4),s(e.instanceSummary_$().workingSessionCount?17:-1),l(),s(e.instanceSummary_$().idleSessionCount?18:-1),l(),s(e.instanceSummary_$().offlineSessionCount?19:-1),l(),s(!e.instanceSummary_$().workingSessionCount&&!e.instanceSummary_$().idleSessionCount&&!e.instanceSummary_$().offlineSessionCount?20:-1),l(),s(e.runtimeInstances_DS.ccapInstanceList_$().length===0?21:22)}}function jt(t,a){if(t&1&&(i(0,"div",12)(1,"section",13)(2,"h2",14),o(3,"Messaging provider-ek"),n(),d(4,rt,2,0,"p",15)(5,ct,3,0,"ul",16),n(),i(6,"section",13)(7,"h2",14),o(8,"LLM provider-ek"),n(),d(9,ut,2,0,"p",15)(10,Ct,3,0,"ul",16),n(),i(11,"section",13)(12,"h2",14),o(13,"Session \xF6sszes\xEDt\u0151"),n(),i(14,"div",17)(15,"p",18)(16,"span",19),o(17),n(),i(18,"span",20),o(19,"session"),n()(),d(20,xt,4,1,"p",21)(21,ft,6,9,"p",22),n()(),i(22,"section",23)(23,"h2",14),o(24,"Instance \xE1ttekint\u0151"),n(),d(25,St,2,0,"p",15)(26,vt,2,0,"p",15)(27,zt,23,9),n(),i(28,"section",13)(29,"h2",14),o(30,"Gyors linkek"),n(),i(31,"div",24)(32,"a",25),o(33," Open Sessions "),n(),i(34,"a",26),o(35," Be\xE1ll\xEDt\xE1sok "),n()()()()),t&2){let e=a,r=_(3);l(4),s(e.messagingProviders.length===0?4:5),l(5),s(e.llmProviders.length===0?9:10),l(8),c(e.sessionSummary.totalCount),l(3),s(e.sessionSummary.recentActivityCount!==void 0?20:-1),l(),s(e.lastErrorCount!==void 0&&e.lastErrorCount!==null?21:-1),l(4),s(r.runtimeInstances_DS.ccapInstanceListLoading_$()?25:r.runtimeInstances_DS.ccapInstanceListError_$()?26:27)}}function Bt(t,a){if(t&1&&d(0,jt,36,6,"div",12),t&2){let e,r=_(2);s((e=r.serverStatus_DS.status_$())?0:-1,e)}}function Gt(t,a){if(t&1&&d(0,lt,5,1,"div",8)(1,Bt,1,1),t&2){let e=_();s(e.serverStatus_DS.statusLoadError_$()?0:1)}}var Vt={"ccap-client":"CCAP Client","ccap-cli":"CCAP CLI",discord:"Discord"},Ot={[x.active]:"Active",[x.inactive]:"Inactive",[x.maintenance]:"Maintenance"},Ut={[f.working]:"Working",[f.idle]:"Idle",[f.offline]:"Offline"},Q=(()=>{class t{title="CCAP Revisioned";serverStatus_DS=S(K);runtimeInstances_DS=S(W);MESSAGING_PROVIDER_NAMES=Vt;INSTANCE_STATUS_LABELS=Ot;PRESENCE_LABELS=Ut;instanceSummary_$=k(()=>{let e=this.runtimeInstances_DS.ccapInstanceList_$(),r=e.length,m=e.filter(C=>C.status===x.active).length,X=e.filter(C=>C.status===x.inactive).length,Y=e.filter(C=>C.status===x.maintenance).length,w=0,H=0,L=0;for(let C of e)for(let A of C.sessionStatuses??[])A.presence===f.working?w++:A.presence===f.idle?H++:L++;return{totalCount:r,activeCount:m,inactiveCount:X,maintenanceCount:Y,workingSessionCount:w,idleSessionCount:H,offlineSessionCount:L}});llmProviderDisplayLabelsMap_$=k(()=>{let e=this.serverStatus_DS.status_$();if(!e)return{};let r={};for(let m of e.llmProviders)r[m]=U.getProviderDisplayLabel(m,null);return r});ngOnInit(){this.serverStatus_DS.loadStatus(),this.runtimeInstances_DS.loadCcapInstanceList()}loadStatus(){this.serverStatus_DS.loadStatus(),this.runtimeInstances_DS.loadCcapInstanceList()}static \u0275fac=function(r){return new(r||t)};static \u0275cmp=N({type:t,selectors:[["app-ccap-home"]],decls:10,vars:3,consts:[[1,"flex","flex-col","min-h-full","text-neutral-100","p-4","gt-xs:p-6"],[1,"flex","flex-col","xs:flex-row","xs:items-center","xs:justify-between","gap-4","mb-6"],[1,"text-2xl","gt-xs:text-3xl","font-bold","text-neutral-100"],[1,"text-neutral-400","text-sm","gt-xs:text-base","mt-1"],["type","button",1,"shrink-0","px-4","py-2","border","border-neonCyan","rounded-lg","text-neutral-400","text-sm","font-medium","hover:bg-neutral-800","hover:text-neutral-200","hover:shadow-neon-glow-cyan","transition-colors"],[1,"flex","items-center","justify-center","py-16"],["type","button",1,"shrink-0","px-4","py-2","border","border-neonCyan","rounded-lg","text-neutral-400","text-sm","font-medium","hover:bg-neutral-800","hover:text-neutral-200","hover:shadow-neon-glow-cyan","transition-colors",3,"click"],[1,"text-neutral-400"],[1,"rounded-lg","bg-neutral-800/60","border","border-red-500/50","p-6","max-w-2xl"],["sourceLabelOverride","St\xE1tusz bet\xF6lt\xE9s",1,"mb-4","block",3,"error"],[1,"text-center"],["type","button",1,"px-4","py-2","border","border-neonCyan","rounded-lg","text-neutral-300","text-sm","font-medium","hover:bg-neutral-700","hover:shadow-neon-glow-cyan","transition-colors",3,"click"],[1,"grid","grid-cols-1","md:grid-cols-2","lg:grid-cols-3","gap-4","mb-8"],[1,"flex","flex-col","rounded-lg","bg-neutral-800/60","border","border-neonDefault","p-4","min-h-0"],[1,"text-lg","font-semibold","text-neutral-200","mb-3","shrink-0"],[1,"text-neutral-500","text-sm"],[1,"space-y-2","min-h-0"],[1,"flex","flex-col","gap-1","min-h-0"],[1,"text-neutral-300"],[1,"text-2xl","font-bold","text-neutral-100"],[1,"ml-1"],[1,"text-neutral-400","text-sm"],[1,"text-sm","mt-1","flex","items-center","gap-1.5"],[1,"flex","flex-col","rounded-lg","bg-neutral-800/60","border","border-neonDefault","p-4","min-h-0","md:col-span-2","lg:col-span-3"],[1,"flex","flex-wrap","gap-3"],["routerLink","/session",1,"inline-flex","items-center","px-5","py-2.5","border","border-ccapAccent","rounded-lg","text-ccapAccent","text-sm","font-semibold","transition-colors","duration-200","hover:bg-ccapAccent","hover:text-white","hover:shadow-neon-glow-accent"],["routerLink","/settings",1,"inline-flex","items-center","px-5","py-2.5","border","border-neonCyan","rounded-lg","text-neutral-300","text-sm","font-semibold","transition-colors","duration-200","hover:bg-neutral-700","hover:text-white","hover:shadow-neon-glow-cyan"],[1,"flex","items-center","gap-3","flex-wrap"],[1,"text-neutral-200","font-medium"],[1,"px-2","py-0.5","text-xs","font-medium","rounded","bg-green-900/50","text-green-300","border","border-neonGreen","shrink-0"],[1,"px-2","py-0.5","text-xs","font-medium","rounded","bg-amber-900/50","text-amber-300","border","border-neonAmber","shrink-0"],[1,"text-neutral-500","text-xs","truncate","max-w-full",3,"title"],[1,"font-medium","text-neutral-300"],["aria-hidden","true",1,"inline-block","w-2","h-2","rounded-full","shrink-0"],[1,"font-medium"],[1,"flex","flex-wrap","gap-4","mb-4"],[1,"flex","items-center","gap-2"],[1,"w-2","h-2","rounded-full","bg-green-500","shrink-0"],[1,"text-neutral-300","text-sm","font-medium"],[1,"border-l","border-neutral-700","pl-4","flex","items-center","gap-2"],[1,"px-2","py-0.5","text-xs","font-medium","rounded","bg-green-900/50","text-green-300","border","border-neonGreen"],[1,"px-2","py-0.5","text-xs","font-medium","rounded","bg-amber-900/50","text-amber-300","border","border-neonAmber"],[1,"px-2","py-0.5","text-xs","font-medium","rounded","bg-neutral-700/50","text-neutral-400","border","border-neutral-600"],[1,"text-neutral-500","text-xs"],[1,"grid","grid-cols-1","md:grid-cols-2","lg:grid-cols-3","gap-3"],[1,"w-2","h-2","rounded-full","bg-neutral-500","shrink-0"],[1,"w-2","h-2","rounded-full","bg-amber-500","shrink-0"],[1,"rounded-md","border","border-neutral-700","bg-neutral-800/40","p-3","flex","flex-col","gap-2"],[1,"flex","items-center","justify-between","gap-2"],[1,"text-neutral-100","font-medium","text-sm","truncate"],[1,"px-2","py-0.5","text-xs","font-medium","rounded","bg-neutral-700/50","text-neutral-400","border","border-neutral-600","shrink-0"],[1,"text-neutral-500","text-xs","font-mono","truncate",3,"title"],[1,"flex","flex-col","gap-1.5","mt-1","pt-2","border-t","border-neutral-700/50"],[1,"text-neutral-600","text-xs","mt-1"],[1,"flex","items-center","gap-2","text-xs"],[1,"w-1.5","h-1.5","rounded-full","bg-green-500","shrink-0"],[1,"w-1.5","h-1.5","rounded-full","bg-amber-500","shrink-0"],[1,"w-1.5","h-1.5","rounded-full","bg-neutral-500","shrink-0"],[1,"text-neutral-300","truncate"],[1,"text-neutral-500","shrink-0"],[1,"text-neutral-500","text-xs","pl-3.5","-mt-1","truncate"]],template:function(r,m){r&1&&(i(0,"div",0)(1,"header",1)(2,"div")(3,"h1",2),o(4),n(),i(5,"p",3),o(6,"Agentic AI System"),n()(),d(7,ot,2,0,"button",4),n(),d(8,at,3,0,"div",5)(9,Gt,2,1),n()),r&2&&(l(4),c(m.title),l(3),s(!m.serverStatus_DS.statusLoading_$()&&!m.serverStatus_DS.statusLoadError_$()&&m.serverStatus_DS.status_$()?7:-1),l(),s(m.serverStatus_DS.statusLoading_$()?8:9))},dependencies:[B,b],encapsulation:2})}return t})();var Wt=[{path:"",pathMatch:"full",component:Q}],ue=(()=>{class t{static \u0275fac=function(r){return new(r||t)};static \u0275mod=R({type:t});static \u0275inj=M({imports:[j,G.forChild(Wt),b,O]})}return t})();export{ue as Dashboard_Module};
2
+ //# sourceMappingURL=dashboard.module-VSWWQDEU.js.map