@futdevpro/ccap 1.1.2941 → 1.1.2944

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-DQNVM7AN.js → agent-instances.module-7CO6UHU3.js} +2 -2
  2. package/client-dist/{ca.module-O75C6NM4.js → ca.module-AWJFVKB6.js} +2 -2
  3. package/client-dist/{cc-usage-dashboard.component-T6B7E2UI.js → cc-usage-dashboard.component-GXP6RN5X.js} +2 -2
  4. package/client-dist/{cc.module-J3EAMUJD.js → cc.module-DAJE6FWU.js} +2 -2
  5. package/client-dist/{chunk-YORE53OO.js → chunk-2KAMFUG2.js} +2 -2
  6. package/client-dist/{chunk-STNBIKCT.js → chunk-2PHD2EKP.js} +2 -2
  7. package/client-dist/{chunk-JFYDUH37.js → chunk-3TF7VKLJ.js} +2 -2
  8. package/client-dist/{chunk-SB6AP4YU.js → chunk-3YNI7ZOC.js} +2 -2
  9. package/client-dist/{chunk-6ZJOH7NF.js → chunk-4ZYMYI5W.js} +2 -2
  10. package/client-dist/{chunk-AQ7GMTGO.js → chunk-55SU72FF.js} +2 -2
  11. package/client-dist/{chunk-XFC3O3CG.js → chunk-5ET7OKBY.js} +2 -2
  12. package/client-dist/{chunk-F53NZ2ZL.js → chunk-6TGIKFR5.js} +2 -2
  13. package/client-dist/{chunk-6HEIMADY.js → chunk-6YHLSAO5.js} +2 -2
  14. package/client-dist/{chunk-O3R65DXW.js → chunk-6YS7CV3D.js} +2 -2
  15. package/client-dist/{chunk-ELCLLZN6.js → chunk-72RIFC2G.js} +2 -2
  16. package/client-dist/{chunk-ME33LUDI.js → chunk-B6IC7KVI.js} +2 -2
  17. package/client-dist/{chunk-EVULZLJI.js → chunk-BQPWYB35.js} +2 -2
  18. package/client-dist/{chunk-ZDNLZMH3.js → chunk-BXCJWV46.js} +2 -2
  19. package/client-dist/{chunk-FLM2XUDT.js → chunk-C7SYYRYT.js} +2 -2
  20. package/client-dist/{chunk-2SLADLRY.js → chunk-CKI6BXRG.js} +2 -2
  21. package/client-dist/{chunk-T55CH5AA.js → chunk-CNHLKS6H.js} +2 -2
  22. package/client-dist/{chunk-MPNIHRMZ.js → chunk-D6ZRTKYW.js} +2 -2
  23. package/client-dist/{chunk-FDFKQCLH.js → chunk-DPDNCEGC.js} +2 -2
  24. package/client-dist/{chunk-IXECCSJS.js → chunk-EBM77UWL.js} +2 -2
  25. package/client-dist/{chunk-KYHDIQCX.js → chunk-EBN4RVPT.js} +2 -2
  26. package/client-dist/{chunk-3SDOBYEW.js → chunk-FDNFCOSI.js} +2 -2
  27. package/client-dist/{chunk-JBI7DZF6.js → chunk-FIFTZWSX.js} +2 -2
  28. package/client-dist/{chunk-EE62M3C3.js → chunk-FQR3AIES.js} +2 -2
  29. package/client-dist/{chunk-C5KZ5ZXA.js → chunk-GOORI72A.js} +2 -2
  30. package/client-dist/{chunk-YUCPEKTT.js → chunk-IJJURZJE.js} +2 -2
  31. package/client-dist/{chunk-PYVALWHU.js → chunk-IZZTOAKP.js} +2 -2
  32. package/client-dist/{chunk-PYVALWHU.js.map → chunk-IZZTOAKP.js.map} +1 -1
  33. package/client-dist/{chunk-GHC5GFO2.js → chunk-J2Q5JXK4.js} +2 -2
  34. package/client-dist/{chunk-25FKG2J7.js → chunk-LB4KTK4L.js} +2 -2
  35. package/client-dist/{chunk-SPGMJKQ6.js → chunk-LNVTTWEM.js} +2 -2
  36. package/client-dist/{chunk-VE3L6E54.js → chunk-LOR6NEY2.js} +2 -2
  37. package/client-dist/{chunk-4IIQKFA5.js → chunk-MG3OU6BA.js} +2 -2
  38. package/client-dist/{chunk-SLVEW3FJ.js → chunk-MKHA5B77.js} +2 -2
  39. package/client-dist/{chunk-S3LPVCEK.js → chunk-MXKN6SWW.js} +2 -2
  40. package/client-dist/{chunk-HIEUVQDI.js → chunk-N7QP46GR.js} +2 -2
  41. package/client-dist/{chunk-H6M757KS.js → chunk-OG3OHMEI.js} +2 -2
  42. package/client-dist/{chunk-BVMJ6VDQ.js → chunk-OGKOBIDG.js} +2 -2
  43. package/client-dist/{chunk-BFYLRSXS.js → chunk-OKROU2FK.js} +2 -2
  44. package/client-dist/{chunk-ISH4TFYI.js → chunk-PGG6Q644.js} +2 -2
  45. package/client-dist/{chunk-76DKMZYK.js → chunk-PYXBJB3L.js} +2 -2
  46. package/client-dist/{chunk-KUXCTBKK.js → chunk-Q6LHOV5F.js} +2 -2
  47. package/client-dist/{chunk-SAPL2K2E.js → chunk-QD3Y7QQV.js} +2 -2
  48. package/client-dist/{chunk-TVFT7AVC.js → chunk-QNTGWC2R.js} +2 -2
  49. package/client-dist/{chunk-4PVZDW7U.js → chunk-RNAZN5SR.js} +2 -2
  50. package/client-dist/{chunk-XCT53H4N.js → chunk-TKWKAUHK.js} +2 -2
  51. package/client-dist/{chunk-KUOWE3RO.js → chunk-UUVYIZLS.js} +2 -2
  52. package/client-dist/{chunk-KE3ET6OR.js → chunk-V7QPXZIU.js} +2 -2
  53. package/client-dist/{chunk-LQFJLYDU.js → chunk-VAH4APWT.js} +2 -2
  54. package/client-dist/{chunk-5L2ZD352.js → chunk-VEUZTI3M.js} +2 -2
  55. package/client-dist/{chunk-QFLT45N4.js → chunk-VVKXOUY4.js} +2 -2
  56. package/client-dist/{chunk-GWVMW7IG.js → chunk-WXUCJ5YR.js} +2 -2
  57. package/client-dist/{chunk-QR57TW7S.js → chunk-XQCAQ3IN.js} +2 -2
  58. package/client-dist/{chunk-ZXONE2EQ.js → chunk-Y352VV4S.js} +2 -2
  59. package/client-dist/{chunk-ULQMQC3R.js → chunk-YHQIHIFX.js} +2 -2
  60. package/client-dist/{chunk-L34TPSOM.js → chunk-YXFAMRML.js} +2 -2
  61. package/client-dist/{chunk-ZRXTZHMM.js → chunk-ZED36DG7.js} +2 -2
  62. package/client-dist/{consultant.module-KY52LOBE.js → consultant.module-GN65PO6I.js} +2 -2
  63. package/client-dist/{crd.module-WUXOSSGU.js → crd.module-IZBRR35X.js} +2 -2
  64. package/client-dist/{dashboard.module-UTQDXN24.js → dashboard.module-SZVJ6NVD.js} +2 -2
  65. package/client-dist/{do.module-7N5QH7EH.js → do.module-MB5RWBU3.js} +2 -2
  66. package/client-dist/{document-library.module-PP32OUKK.js → document-library.module-I5ACYMEI.js} +2 -2
  67. package/client-dist/{embedding-eval.module-J73HF4SJ.js → embedding-eval.module-T5J3FYAQ.js} +2 -2
  68. package/client-dist/{embedding-registry.module-73AL3GC5.js → embedding-registry.module-3RAM2AYM.js} +2 -2
  69. package/client-dist/{err.module-TKF4HCDX.js → err.module-77BW3SYR.js} +2 -2
  70. package/client-dist/{feedback.module-AMF7Z6CL.js → feedback.module-J6RGG5RE.js} +2 -2
  71. package/client-dist/{host-runtime-mcp.module-Y3H5KATA.js → host-runtime-mcp.module-4ZTXSBD4.js} +2 -2
  72. package/client-dist/index.html +1 -1
  73. package/client-dist/{live-dev-pipeline.module-3I425DWB.js → live-dev-pipeline.module-6SYVG4XC.js} +2 -2
  74. package/client-dist/{logs.module-DU7IJ2DE.js → logs.module-WLHOPHEM.js} +2 -2
  75. package/client-dist/{main-DBKN6KIK.js → main-HHCQAI3N.js} +3 -3
  76. package/client-dist/{master-control-remote-poc.module-QGNYMMG3.js → master-control-remote-poc.module-HVUW2NXS.js} +2 -2
  77. package/client-dist/{mobile-app.module-LSMEWADN.js → mobile-app.module-6U4R7XPL.js} +2 -2
  78. package/client-dist/{model-registry.module-T7RR46CZ.js → model-registry.module-WV2FJV4Y.js} +2 -2
  79. package/client-dist/{oc.module-SJGNF5A3.js → oc.module-A3MCEZNG.js} +2 -2
  80. package/client-dist/{orc.module-IZI6CDZM.js → orc.module-VE2VTXQF.js} +2 -2
  81. package/client-dist/{project-management.module-2FLSPZW7.js → project-management.module-UMA6AEPX.js} +2 -2
  82. package/client-dist/project-source-routed.module-E4EUTDTT.js +2 -0
  83. package/client-dist/{scheduler.module-PIEO4HFO.js → scheduler.module-QG5AETNC.js} +2 -2
  84. package/client-dist/{session.module-VLAABUIK.js → session.module-IVTURNPB.js} +2 -2
  85. package/client-dist/{set.module-6ZL4FBEL.js → set.module-YDQOZTYD.js} +2 -2
  86. package/client-dist/{setup.module-M6GV6JEI.js → setup.module-G4BE72OU.js} +2 -2
  87. package/client-dist/{terminals.module-2GVQO2KU.js → terminals.module-N36ZCT7W.js} +2 -2
  88. package/client-dist/{voice-notes-poc.module-KGPLCE5E.js → voice-notes-poc.module-XWVT3NUP.js} +2 -2
  89. package/client-dist/{wfs.module-CRKC34R4.js → wfs.module-HCT6NE7K.js} +2 -2
  90. package/package.json +1 -1
  91. package/client-dist/project-source-routed.module-WI5VP2S7.js +0 -2
  92. /package/client-dist/{agent-instances.module-DQNVM7AN.js.map → agent-instances.module-7CO6UHU3.js.map} +0 -0
  93. /package/client-dist/{ca.module-O75C6NM4.js.map → ca.module-AWJFVKB6.js.map} +0 -0
  94. /package/client-dist/{cc-usage-dashboard.component-T6B7E2UI.js.map → cc-usage-dashboard.component-GXP6RN5X.js.map} +0 -0
  95. /package/client-dist/{cc.module-J3EAMUJD.js.map → cc.module-DAJE6FWU.js.map} +0 -0
  96. /package/client-dist/{chunk-YORE53OO.js.map → chunk-2KAMFUG2.js.map} +0 -0
  97. /package/client-dist/{chunk-STNBIKCT.js.map → chunk-2PHD2EKP.js.map} +0 -0
  98. /package/client-dist/{chunk-JFYDUH37.js.map → chunk-3TF7VKLJ.js.map} +0 -0
  99. /package/client-dist/{chunk-SB6AP4YU.js.map → chunk-3YNI7ZOC.js.map} +0 -0
  100. /package/client-dist/{chunk-6ZJOH7NF.js.map → chunk-4ZYMYI5W.js.map} +0 -0
  101. /package/client-dist/{chunk-AQ7GMTGO.js.map → chunk-55SU72FF.js.map} +0 -0
  102. /package/client-dist/{chunk-XFC3O3CG.js.map → chunk-5ET7OKBY.js.map} +0 -0
  103. /package/client-dist/{chunk-F53NZ2ZL.js.map → chunk-6TGIKFR5.js.map} +0 -0
  104. /package/client-dist/{chunk-6HEIMADY.js.map → chunk-6YHLSAO5.js.map} +0 -0
  105. /package/client-dist/{chunk-O3R65DXW.js.map → chunk-6YS7CV3D.js.map} +0 -0
  106. /package/client-dist/{chunk-ELCLLZN6.js.map → chunk-72RIFC2G.js.map} +0 -0
  107. /package/client-dist/{chunk-ME33LUDI.js.map → chunk-B6IC7KVI.js.map} +0 -0
  108. /package/client-dist/{chunk-EVULZLJI.js.map → chunk-BQPWYB35.js.map} +0 -0
  109. /package/client-dist/{chunk-ZDNLZMH3.js.map → chunk-BXCJWV46.js.map} +0 -0
  110. /package/client-dist/{chunk-FLM2XUDT.js.map → chunk-C7SYYRYT.js.map} +0 -0
  111. /package/client-dist/{chunk-2SLADLRY.js.map → chunk-CKI6BXRG.js.map} +0 -0
  112. /package/client-dist/{chunk-T55CH5AA.js.map → chunk-CNHLKS6H.js.map} +0 -0
  113. /package/client-dist/{chunk-MPNIHRMZ.js.map → chunk-D6ZRTKYW.js.map} +0 -0
  114. /package/client-dist/{chunk-FDFKQCLH.js.map → chunk-DPDNCEGC.js.map} +0 -0
  115. /package/client-dist/{chunk-IXECCSJS.js.map → chunk-EBM77UWL.js.map} +0 -0
  116. /package/client-dist/{chunk-KYHDIQCX.js.map → chunk-EBN4RVPT.js.map} +0 -0
  117. /package/client-dist/{chunk-3SDOBYEW.js.map → chunk-FDNFCOSI.js.map} +0 -0
  118. /package/client-dist/{chunk-JBI7DZF6.js.map → chunk-FIFTZWSX.js.map} +0 -0
  119. /package/client-dist/{chunk-EE62M3C3.js.map → chunk-FQR3AIES.js.map} +0 -0
  120. /package/client-dist/{chunk-C5KZ5ZXA.js.map → chunk-GOORI72A.js.map} +0 -0
  121. /package/client-dist/{chunk-YUCPEKTT.js.map → chunk-IJJURZJE.js.map} +0 -0
  122. /package/client-dist/{chunk-GHC5GFO2.js.map → chunk-J2Q5JXK4.js.map} +0 -0
  123. /package/client-dist/{chunk-25FKG2J7.js.map → chunk-LB4KTK4L.js.map} +0 -0
  124. /package/client-dist/{chunk-SPGMJKQ6.js.map → chunk-LNVTTWEM.js.map} +0 -0
  125. /package/client-dist/{chunk-VE3L6E54.js.map → chunk-LOR6NEY2.js.map} +0 -0
  126. /package/client-dist/{chunk-4IIQKFA5.js.map → chunk-MG3OU6BA.js.map} +0 -0
  127. /package/client-dist/{chunk-SLVEW3FJ.js.map → chunk-MKHA5B77.js.map} +0 -0
  128. /package/client-dist/{chunk-S3LPVCEK.js.map → chunk-MXKN6SWW.js.map} +0 -0
  129. /package/client-dist/{chunk-HIEUVQDI.js.map → chunk-N7QP46GR.js.map} +0 -0
  130. /package/client-dist/{chunk-H6M757KS.js.map → chunk-OG3OHMEI.js.map} +0 -0
  131. /package/client-dist/{chunk-BVMJ6VDQ.js.map → chunk-OGKOBIDG.js.map} +0 -0
  132. /package/client-dist/{chunk-BFYLRSXS.js.map → chunk-OKROU2FK.js.map} +0 -0
  133. /package/client-dist/{chunk-ISH4TFYI.js.map → chunk-PGG6Q644.js.map} +0 -0
  134. /package/client-dist/{chunk-76DKMZYK.js.map → chunk-PYXBJB3L.js.map} +0 -0
  135. /package/client-dist/{chunk-KUXCTBKK.js.map → chunk-Q6LHOV5F.js.map} +0 -0
  136. /package/client-dist/{chunk-SAPL2K2E.js.map → chunk-QD3Y7QQV.js.map} +0 -0
  137. /package/client-dist/{chunk-TVFT7AVC.js.map → chunk-QNTGWC2R.js.map} +0 -0
  138. /package/client-dist/{chunk-4PVZDW7U.js.map → chunk-RNAZN5SR.js.map} +0 -0
  139. /package/client-dist/{chunk-XCT53H4N.js.map → chunk-TKWKAUHK.js.map} +0 -0
  140. /package/client-dist/{chunk-KUOWE3RO.js.map → chunk-UUVYIZLS.js.map} +0 -0
  141. /package/client-dist/{chunk-KE3ET6OR.js.map → chunk-V7QPXZIU.js.map} +0 -0
  142. /package/client-dist/{chunk-LQFJLYDU.js.map → chunk-VAH4APWT.js.map} +0 -0
  143. /package/client-dist/{chunk-5L2ZD352.js.map → chunk-VEUZTI3M.js.map} +0 -0
  144. /package/client-dist/{chunk-QFLT45N4.js.map → chunk-VVKXOUY4.js.map} +0 -0
  145. /package/client-dist/{chunk-GWVMW7IG.js.map → chunk-WXUCJ5YR.js.map} +0 -0
  146. /package/client-dist/{chunk-QR57TW7S.js.map → chunk-XQCAQ3IN.js.map} +0 -0
  147. /package/client-dist/{chunk-ZXONE2EQ.js.map → chunk-Y352VV4S.js.map} +0 -0
  148. /package/client-dist/{chunk-ULQMQC3R.js.map → chunk-YHQIHIFX.js.map} +0 -0
  149. /package/client-dist/{chunk-L34TPSOM.js.map → chunk-YXFAMRML.js.map} +0 -0
  150. /package/client-dist/{chunk-ZRXTZHMM.js.map → chunk-ZED36DG7.js.map} +0 -0
  151. /package/client-dist/{consultant.module-KY52LOBE.js.map → consultant.module-GN65PO6I.js.map} +0 -0
  152. /package/client-dist/{crd.module-WUXOSSGU.js.map → crd.module-IZBRR35X.js.map} +0 -0
  153. /package/client-dist/{dashboard.module-UTQDXN24.js.map → dashboard.module-SZVJ6NVD.js.map} +0 -0
  154. /package/client-dist/{do.module-7N5QH7EH.js.map → do.module-MB5RWBU3.js.map} +0 -0
  155. /package/client-dist/{document-library.module-PP32OUKK.js.map → document-library.module-I5ACYMEI.js.map} +0 -0
  156. /package/client-dist/{embedding-eval.module-J73HF4SJ.js.map → embedding-eval.module-T5J3FYAQ.js.map} +0 -0
  157. /package/client-dist/{embedding-registry.module-73AL3GC5.js.map → embedding-registry.module-3RAM2AYM.js.map} +0 -0
  158. /package/client-dist/{err.module-TKF4HCDX.js.map → err.module-77BW3SYR.js.map} +0 -0
  159. /package/client-dist/{feedback.module-AMF7Z6CL.js.map → feedback.module-J6RGG5RE.js.map} +0 -0
  160. /package/client-dist/{host-runtime-mcp.module-Y3H5KATA.js.map → host-runtime-mcp.module-4ZTXSBD4.js.map} +0 -0
  161. /package/client-dist/{live-dev-pipeline.module-3I425DWB.js.map → live-dev-pipeline.module-6SYVG4XC.js.map} +0 -0
  162. /package/client-dist/{logs.module-DU7IJ2DE.js.map → logs.module-WLHOPHEM.js.map} +0 -0
  163. /package/client-dist/{main-DBKN6KIK.js.map → main-HHCQAI3N.js.map} +0 -0
  164. /package/client-dist/{master-control-remote-poc.module-QGNYMMG3.js.map → master-control-remote-poc.module-HVUW2NXS.js.map} +0 -0
  165. /package/client-dist/{mobile-app.module-LSMEWADN.js.map → mobile-app.module-6U4R7XPL.js.map} +0 -0
  166. /package/client-dist/{model-registry.module-T7RR46CZ.js.map → model-registry.module-WV2FJV4Y.js.map} +0 -0
  167. /package/client-dist/{oc.module-SJGNF5A3.js.map → oc.module-A3MCEZNG.js.map} +0 -0
  168. /package/client-dist/{orc.module-IZI6CDZM.js.map → orc.module-VE2VTXQF.js.map} +0 -0
  169. /package/client-dist/{project-management.module-2FLSPZW7.js.map → project-management.module-UMA6AEPX.js.map} +0 -0
  170. /package/client-dist/{project-source-routed.module-WI5VP2S7.js.map → project-source-routed.module-E4EUTDTT.js.map} +0 -0
  171. /package/client-dist/{scheduler.module-PIEO4HFO.js.map → scheduler.module-QG5AETNC.js.map} +0 -0
  172. /package/client-dist/{session.module-VLAABUIK.js.map → session.module-IVTURNPB.js.map} +0 -0
  173. /package/client-dist/{set.module-6ZL4FBEL.js.map → set.module-YDQOZTYD.js.map} +0 -0
  174. /package/client-dist/{setup.module-M6GV6JEI.js.map → setup.module-G4BE72OU.js.map} +0 -0
  175. /package/client-dist/{terminals.module-2GVQO2KU.js.map → terminals.module-N36ZCT7W.js.map} +0 -0
  176. /package/client-dist/{voice-notes-poc.module-KGPLCE5E.js.map → voice-notes-poc.module-XWVT3NUP.js.map} +0 -0
  177. /package/client-dist/{wfs.module-CRKC34R4.js.map → wfs.module-HCT6NE7K.js.map} +0 -0
@@ -1,4 +1,4 @@
1
- import{a as le,b as Ae,c as Vt,d as Lt,e as Re,f as Ft}from"./chunk-EE62M3C3.js";import{a as de,b as ce,c as Rt,d as Oe}from"./chunk-6HEIMADY.js";import"./chunk-EGRHWZRV.js";import{a as Pe}from"./chunk-FDFKQCLH.js";import{a as Me}from"./chunk-L34TPSOM.js";import{a as ge}from"./chunk-Q2PKIGLB.js";import{a as wt}from"./chunk-SLVEW3FJ.js";import{a as W}from"./chunk-6ZJOH7NF.js";import{a as qe}from"./chunk-YRVQSWSZ.js";import{a as bt}from"./chunk-ISH4TFYI.js";import{a as vt,b as $e}from"./chunk-ZXONE2EQ.js";import"./chunk-2SLADLRY.js";import"./chunk-JBI7DZF6.js";import"./chunk-L44637OO.js";import"./chunk-YORE53OO.js";import"./chunk-UFBTR2BG.js";import{a as ae}from"./chunk-O3R65DXW.js";import"./chunk-ZDNLZMH3.js";import"./chunk-LQFJLYDU.js";import"./chunk-XFC3O3CG.js";import{e as Pt,f as At,g as Ot}from"./chunk-4IIQKFA5.js";import"./chunk-GHC5GFO2.js";import{a as $t}from"./chunk-7JUIBZEE.js";import{a as kt,b as It,c as Dt}from"./chunk-C7XPBJTG.js";import{a as Et,b as U,c as Ke,f as Mt}from"./chunk-MPNIHRMZ.js";import"./chunk-WPHEQXWB.js";import{a as yt,c as Tt}from"./chunk-KUXCTBKK.js";import{b as De,c as Ee}from"./chunk-STNBIKCT.js";import"./chunk-C5KZ5ZXA.js";import"./chunk-SB6AP4YU.js";import"./chunk-Q2NVIOCY.js";import{a as re}from"./chunk-XOGAYT52.js";import"./chunk-ULQMQC3R.js";import"./chunk-GWVMW7IG.js";import"./chunk-3SDOBYEW.js";import"./chunk-V3VQWJQL.js";import"./chunk-BFYLRSXS.js";import"./chunk-XCT53H4N.js";import"./chunk-ZBTWQZNB.js";import{a as Y}from"./chunk-FLAJXIYW.js";import{c as mt,f as ut,i as Ct,n as ft,o as xt,p as ht,v as gt}from"./chunk-EO4DNTT4.js";import"./chunk-HIEUVQDI.js";import{a as O}from"./chunk-5UPNU54P.js";import{j as St}from"./chunk-KE3ET6OR.js";import{p as dt}from"./chunk-PYVALWHU.js";import{$a as F,Aa as Ce,Ba as fe,C as $,Cb as Ie,D as z,E as Ye,Ea as xe,Eb as ct,Fa as d,Fb as pt,G as ie,Ga as T,Gb as se,Ha as D,Ia as J,J as u,K as C,Kb as _t,L as M,M as L,N as Ze,Pa as he,Qa as nt,Ra as ye,T as ve,Ta as Te,U as Q,Va as He,W as G,Xa as it,Z as a,_ as et,a as Be,aa as v,ab as j,b as We,bb as ot,ca as tt,da as g,db as st,fa as _e,ga as b,h as Ge,ha as we,hb as A,ia as me,ib as at,ja as V,jb as ke,k as R,la as _,mb as X,oa as N,ob as rt,pa as H,pb as lt,qa as o,ra as s,sa as S,ta as Ne,ua as k,ub as oe,va as f,wa as c,y as Je,z as Xe,za as ue}from"./chunk-TBMJSIBB.js";function an(t,r){t&1&&(o(0,"div",3),M(),o(1,"svg",5),S(2,"path",6),s(),L(),o(3,"span",7),d(4,"Plan accepted"),s()())}function rn(t,r){if(t&1){let e=k();o(0,"button",8),f("click",function(){u(e);let n=c(2);return C(n.handleAccept())}),M(),o(1,"svg",9),S(2,"path",6),s(),d(3," Accept plan "),s()}}function ln(t,r){if(t&1&&(o(0,"div",0),S(1,"div",1),o(2,"div",2),g(3,an,5,0,"div",3)(4,rn,4,0,"button",4),s()()),t&2){let e=c();a(),b("innerHTML",r,G),a(2),_(e.isAccepted_$()?3:4)}}var Ve=(()=>{class t{sanitizer=$(Ie);rawData=Q(void 0);accepted=ve();isAccepted_$=v(!1);planText_$=A(()=>{let e=this.rawData();if(!e)return"";let i=e.input;if(!i||typeof i!="object")return"";let n=i.plan;return typeof n=="string"?n:""});planHtml_$=A(()=>{let e=this.planText_$();if(!e)return null;let i=Et.toSanitizedHtml(e);return this.sanitizer.bypassSecurityTrustHtml(i)});handleAccept(){this.isAccepted_$()||(this.isAccepted_$.set(!0),this.accepted.emit())}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=z({type:t,selectors:[["app-s-agent-tool-plan-view"]],hostAttrs:[1,"block"],inputs:{rawData:[1,"rawData"]},outputs:{accepted:"accepted"},standalone:!0,features:[Te],decls:1,vars:1,consts:[[1,"px-2.5","py-2","space-y-2"],[1,"ccap-assistant-md","leading-snug","sm:leading-normal","break-words","text-neutral-200","text-xs","sm:text-sm","min-w-0","max-h-[400px]","overflow-y-auto","overflow-x-auto","pr-1",3,"innerHTML"],[1,"flex","justify-end","pt-1","border-t","border-orange-500/10"],[1,"inline-flex","items-center","gap-1.5","px-3","py-1","rounded-md","bg-green-500/10","border","border-green-500/25"],["type","button",1,"inline-flex","items-center","gap-1.5","px-3","py-1","rounded-md","bg-ccapAccent/10","border","border-ccapAccent/30","text-ccapAccent","text-[11px]","font-medium","cursor-pointer","hover:bg-ccapAccent/20","hover:border-ccapAccent/50","transition-colors"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","2","stroke-linecap","round","stroke-linejoin","round",1,"w-3.5","h-3.5","text-green-400"],["d","M3.5 8.5l3 3 6-6"],[1,"text-[11px]","text-green-400","font-medium"],["type","button",1,"inline-flex","items-center","gap-1.5","px-3","py-1","rounded-md","bg-ccapAccent/10","border","border-ccapAccent/30","text-ccapAccent","text-[11px]","font-medium","cursor-pointer","hover:bg-ccapAccent/20","hover:border-ccapAccent/50","transition-colors",3,"click"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","2","stroke-linecap","round","stroke-linejoin","round",1,"w-3.5","h-3.5"]],template:function(i,n){if(i&1&&g(0,ln,5,2,"div",0),i&2){let l;_((l=n.planHtml_$())?0:-1,l)}},dependencies:[oe],styles:[`@charset "UTF-8";.ccap-assistant-md[_ngcontent-%COMP%]{font-size:inherit;line-height:1.55;text-align:left;color:#ffffffeb}.ccap-assistant-md[_ngcontent-%COMP%] [_ngcontent-%COMP%]:first-child{margin-top:0}.ccap-assistant-md[_ngcontent-%COMP%] [_ngcontent-%COMP%]:last-child{margin-bottom:0}.ccap-assistant-md[_ngcontent-%COMP%] h1[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] h2[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] h3[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] h4[_ngcontent-%COMP%]{font-weight:600;color:#fffffff7;letter-spacing:.01em}.ccap-assistant-md[_ngcontent-%COMP%] h1[_ngcontent-%COMP%]{font-size:1.2em;margin-top:1.5rem;margin-bottom:.6rem;padding-bottom:.45rem;border-bottom:1px solid rgba(0,245,255,.28)}.ccap-assistant-md[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{font-size:1.1em;margin-top:1.35rem;margin-bottom:.55rem;padding-bottom:.35rem;border-bottom:1px solid rgba(0,245,255,.16)}.ccap-assistant-md[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font-size:1.02em;margin-top:1.15rem;margin-bottom:.45rem;color:#00f5ffe0}.ccap-assistant-md[_ngcontent-%COMP%] h4[_ngcontent-%COMP%]{font-size:.95em;margin-top:.95rem;margin-bottom:.35rem;color:#ffffffc7}.ccap-assistant-md[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:.5rem 0}.ccap-assistant-md[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{font-weight:650;color:#fffffffa}.ccap-assistant-md[_ngcontent-%COMP%] em[_ngcontent-%COMP%]{font-style:italic;color:#ffffffd9}.ccap-assistant-md[_ngcontent-%COMP%] ul[_ngcontent-%COMP%]{margin:.6rem 0;padding-left:1.5rem;list-style-type:disc}.ccap-assistant-md[_ngcontent-%COMP%] ol[_ngcontent-%COMP%]{margin:.6rem 0;padding-left:1.5rem;list-style-type:decimal}.ccap-assistant-md[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{margin:.15rem 0;line-height:1.5}.ccap-assistant-md[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] ul[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] ol[_ngcontent-%COMP%] ul[_ngcontent-%COMP%]{list-style-type:circle}.ccap-assistant-md[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] ul[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] ol[_ngcontent-%COMP%] ol[_ngcontent-%COMP%] ol[_ngcontent-%COMP%]{list-style-type:square}.ccap-assistant-md[_ngcontent-%COMP%] li[_ngcontent-%COMP%] + li[_ngcontent-%COMP%]{margin-top:.25rem}.ccap-assistant-md[_ngcontent-%COMP%] li[_ngcontent-%COMP%] > ul[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] li[_ngcontent-%COMP%] > ol[_ngcontent-%COMP%]{margin-top:.15rem;margin-bottom:.1rem}.ccap-assistant-md[_ngcontent-%COMP%] hr[_ngcontent-%COMP%]{border:0;height:1px;background:linear-gradient(90deg,transparent 0%,rgba(0,245,255,.38) 12%,rgba(0,245,255,.38) 88%,transparent 100%);margin:2.2rem 0}.ccap-assistant-md[_ngcontent-%COMP%] blockquote[_ngcontent-%COMP%]{margin:.75rem 0;padding:.45rem .85rem;border-left:3px solid rgba(0,245,255,.4);background:#00f5ff0a;border-radius:0 .25rem .25rem 0;color:#ffffffd9}.ccap-assistant-md[_ngcontent-%COMP%] blockquote[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:.2rem 0}.ccap-assistant-md[_ngcontent-%COMP%] table[_ngcontent-%COMP%]{width:100%;border-collapse:separate;border-spacing:0;margin:1rem 0;font-size:.9em;display:block;overflow-x:auto;border:1px solid rgba(0,245,255,.32);border-radius:.3rem}.ccap-assistant-md[_ngcontent-%COMP%] thead[_ngcontent-%COMP%]{position:sticky;top:0}.ccap-assistant-md[_ngcontent-%COMP%] th[_ngcontent-%COMP%]{background:#00f5ff24;font-weight:600;color:#00f5ffeb;border-bottom:1px solid rgba(0,245,255,.22);border-right:1px solid rgba(0,245,255,.12);padding:.45rem .7rem;text-align:left;vertical-align:top;white-space:nowrap}.ccap-assistant-md[_ngcontent-%COMP%] th[_ngcontent-%COMP%]:last-child{border-right:none}.ccap-assistant-md[_ngcontent-%COMP%] td[_ngcontent-%COMP%]{border-bottom:1px solid rgba(255,255,255,.16);border-right:1px solid rgba(255,255,255,.12);padding:.4rem .7rem;text-align:left;vertical-align:top}.ccap-assistant-md[_ngcontent-%COMP%] td[_ngcontent-%COMP%]:last-child{border-right:none}.ccap-assistant-md[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:last-child td[_ngcontent-%COMP%]{border-bottom:none}.ccap-assistant-md[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:nth-child(2n){background:#ffffff08}.ccap-assistant-md[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:hover{background:#00f5ff0e}.ccap-assistant-md[_ngcontent-%COMP%] pre[_ngcontent-%COMP%]{margin:.55rem 0;padding:.6rem .75rem;border-radius:.3rem;background:#00000080;border:1px solid rgba(255,255,255,.08);overflow-x:auto;font-size:.88em}.ccap-assistant-md[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-size:.9em}.ccap-assistant-md[_ngcontent-%COMP%] p[_ngcontent-%COMP%] code[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] li[_ngcontent-%COMP%] code[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] td[_ngcontent-%COMP%] code[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] th[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{padding:.1rem .28rem;border-radius:.2rem;background:#00f5ff12;color:#00f5ffeb;border:1px solid rgba(0,245,255,.12)}.ccap-assistant-md[_ngcontent-%COMP%] pre[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{background:transparent;color:inherit;border:none;padding:0;font-size:inherit}.ccap-assistant-md[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{color:#38bdf8;text-decoration:underline;text-underline-offset:2px}.ccap-assistant-md[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:hover{color:#7dd3fc}
1
+ import{a as le,b as Ae,c as Vt,d as Lt,e as Re,f as Ft}from"./chunk-FQR3AIES.js";import{a as de,b as ce,c as Rt,d as Oe}from"./chunk-6YHLSAO5.js";import"./chunk-EGRHWZRV.js";import{a as Pe}from"./chunk-DPDNCEGC.js";import{a as Me}from"./chunk-YXFAMRML.js";import{a as ge}from"./chunk-Q2PKIGLB.js";import{a as wt}from"./chunk-MKHA5B77.js";import{a as W}from"./chunk-4ZYMYI5W.js";import{a as qe}from"./chunk-YRVQSWSZ.js";import{a as bt}from"./chunk-PGG6Q644.js";import{a as vt,b as $e}from"./chunk-Y352VV4S.js";import"./chunk-CKI6BXRG.js";import"./chunk-FIFTZWSX.js";import"./chunk-L44637OO.js";import"./chunk-2KAMFUG2.js";import"./chunk-UFBTR2BG.js";import{a as ae}from"./chunk-6YS7CV3D.js";import"./chunk-BXCJWV46.js";import"./chunk-VAH4APWT.js";import"./chunk-5ET7OKBY.js";import{e as Pt,f as At,g as Ot}from"./chunk-MG3OU6BA.js";import"./chunk-J2Q5JXK4.js";import{a as $t}from"./chunk-7JUIBZEE.js";import{a as kt,b as It,c as Dt}from"./chunk-C7XPBJTG.js";import{a as Et,b as U,c as Ke,f as Mt}from"./chunk-D6ZRTKYW.js";import"./chunk-WPHEQXWB.js";import{a as yt,c as Tt}from"./chunk-Q6LHOV5F.js";import{b as De,c as Ee}from"./chunk-2PHD2EKP.js";import"./chunk-GOORI72A.js";import"./chunk-3YNI7ZOC.js";import"./chunk-Q2NVIOCY.js";import{a as re}from"./chunk-XOGAYT52.js";import"./chunk-YHQIHIFX.js";import"./chunk-WXUCJ5YR.js";import"./chunk-FDNFCOSI.js";import"./chunk-V3VQWJQL.js";import"./chunk-OKROU2FK.js";import"./chunk-TKWKAUHK.js";import"./chunk-ZBTWQZNB.js";import{a as Y}from"./chunk-FLAJXIYW.js";import{c as mt,f as ut,i as Ct,n as ft,o as xt,p as ht,v as gt}from"./chunk-EO4DNTT4.js";import"./chunk-N7QP46GR.js";import{a as O}from"./chunk-5UPNU54P.js";import{j as St}from"./chunk-V7QPXZIU.js";import{p as dt}from"./chunk-IZZTOAKP.js";import{$a as F,Aa as Ce,Ba as fe,C as $,Cb as Ie,D as z,E as Ye,Ea as xe,Eb as ct,Fa as d,Fb as pt,G as ie,Ga as T,Gb as se,Ha as D,Ia as J,J as u,K as C,Kb as _t,L as M,M as L,N as Ze,Pa as he,Qa as nt,Ra as ye,T as ve,Ta as Te,U as Q,Va as He,W as G,Xa as it,Z as a,_ as et,a as Be,aa as v,ab as j,b as We,bb as ot,ca as tt,da as g,db as st,fa as _e,ga as b,h as Ge,ha as we,hb as A,ia as me,ib as at,ja as V,jb as ke,k as R,la as _,mb as X,oa as N,ob as rt,pa as H,pb as lt,qa as o,ra as s,sa as S,ta as Ne,ua as k,ub as oe,va as f,wa as c,y as Je,z as Xe,za as ue}from"./chunk-TBMJSIBB.js";function an(t,r){t&1&&(o(0,"div",3),M(),o(1,"svg",5),S(2,"path",6),s(),L(),o(3,"span",7),d(4,"Plan accepted"),s()())}function rn(t,r){if(t&1){let e=k();o(0,"button",8),f("click",function(){u(e);let n=c(2);return C(n.handleAccept())}),M(),o(1,"svg",9),S(2,"path",6),s(),d(3," Accept plan "),s()}}function ln(t,r){if(t&1&&(o(0,"div",0),S(1,"div",1),o(2,"div",2),g(3,an,5,0,"div",3)(4,rn,4,0,"button",4),s()()),t&2){let e=c();a(),b("innerHTML",r,G),a(2),_(e.isAccepted_$()?3:4)}}var Ve=(()=>{class t{sanitizer=$(Ie);rawData=Q(void 0);accepted=ve();isAccepted_$=v(!1);planText_$=A(()=>{let e=this.rawData();if(!e)return"";let i=e.input;if(!i||typeof i!="object")return"";let n=i.plan;return typeof n=="string"?n:""});planHtml_$=A(()=>{let e=this.planText_$();if(!e)return null;let i=Et.toSanitizedHtml(e);return this.sanitizer.bypassSecurityTrustHtml(i)});handleAccept(){this.isAccepted_$()||(this.isAccepted_$.set(!0),this.accepted.emit())}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=z({type:t,selectors:[["app-s-agent-tool-plan-view"]],hostAttrs:[1,"block"],inputs:{rawData:[1,"rawData"]},outputs:{accepted:"accepted"},standalone:!0,features:[Te],decls:1,vars:1,consts:[[1,"px-2.5","py-2","space-y-2"],[1,"ccap-assistant-md","leading-snug","sm:leading-normal","break-words","text-neutral-200","text-xs","sm:text-sm","min-w-0","max-h-[400px]","overflow-y-auto","overflow-x-auto","pr-1",3,"innerHTML"],[1,"flex","justify-end","pt-1","border-t","border-orange-500/10"],[1,"inline-flex","items-center","gap-1.5","px-3","py-1","rounded-md","bg-green-500/10","border","border-green-500/25"],["type","button",1,"inline-flex","items-center","gap-1.5","px-3","py-1","rounded-md","bg-ccapAccent/10","border","border-ccapAccent/30","text-ccapAccent","text-[11px]","font-medium","cursor-pointer","hover:bg-ccapAccent/20","hover:border-ccapAccent/50","transition-colors"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","2","stroke-linecap","round","stroke-linejoin","round",1,"w-3.5","h-3.5","text-green-400"],["d","M3.5 8.5l3 3 6-6"],[1,"text-[11px]","text-green-400","font-medium"],["type","button",1,"inline-flex","items-center","gap-1.5","px-3","py-1","rounded-md","bg-ccapAccent/10","border","border-ccapAccent/30","text-ccapAccent","text-[11px]","font-medium","cursor-pointer","hover:bg-ccapAccent/20","hover:border-ccapAccent/50","transition-colors",3,"click"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","2","stroke-linecap","round","stroke-linejoin","round",1,"w-3.5","h-3.5"]],template:function(i,n){if(i&1&&g(0,ln,5,2,"div",0),i&2){let l;_((l=n.planHtml_$())?0:-1,l)}},dependencies:[oe],styles:[`@charset "UTF-8";.ccap-assistant-md[_ngcontent-%COMP%]{font-size:inherit;line-height:1.55;text-align:left;color:#ffffffeb}.ccap-assistant-md[_ngcontent-%COMP%] [_ngcontent-%COMP%]:first-child{margin-top:0}.ccap-assistant-md[_ngcontent-%COMP%] [_ngcontent-%COMP%]:last-child{margin-bottom:0}.ccap-assistant-md[_ngcontent-%COMP%] h1[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] h2[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] h3[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] h4[_ngcontent-%COMP%]{font-weight:600;color:#fffffff7;letter-spacing:.01em}.ccap-assistant-md[_ngcontent-%COMP%] h1[_ngcontent-%COMP%]{font-size:1.2em;margin-top:1.5rem;margin-bottom:.6rem;padding-bottom:.45rem;border-bottom:1px solid rgba(0,245,255,.28)}.ccap-assistant-md[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{font-size:1.1em;margin-top:1.35rem;margin-bottom:.55rem;padding-bottom:.35rem;border-bottom:1px solid rgba(0,245,255,.16)}.ccap-assistant-md[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{font-size:1.02em;margin-top:1.15rem;margin-bottom:.45rem;color:#00f5ffe0}.ccap-assistant-md[_ngcontent-%COMP%] h4[_ngcontent-%COMP%]{font-size:.95em;margin-top:.95rem;margin-bottom:.35rem;color:#ffffffc7}.ccap-assistant-md[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:.5rem 0}.ccap-assistant-md[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{font-weight:650;color:#fffffffa}.ccap-assistant-md[_ngcontent-%COMP%] em[_ngcontent-%COMP%]{font-style:italic;color:#ffffffd9}.ccap-assistant-md[_ngcontent-%COMP%] ul[_ngcontent-%COMP%]{margin:.6rem 0;padding-left:1.5rem;list-style-type:disc}.ccap-assistant-md[_ngcontent-%COMP%] ol[_ngcontent-%COMP%]{margin:.6rem 0;padding-left:1.5rem;list-style-type:decimal}.ccap-assistant-md[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{margin:.15rem 0;line-height:1.5}.ccap-assistant-md[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] ul[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] ol[_ngcontent-%COMP%] ul[_ngcontent-%COMP%]{list-style-type:circle}.ccap-assistant-md[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] ul[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] ol[_ngcontent-%COMP%] ol[_ngcontent-%COMP%] ol[_ngcontent-%COMP%]{list-style-type:square}.ccap-assistant-md[_ngcontent-%COMP%] li[_ngcontent-%COMP%] + li[_ngcontent-%COMP%]{margin-top:.25rem}.ccap-assistant-md[_ngcontent-%COMP%] li[_ngcontent-%COMP%] > ul[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] li[_ngcontent-%COMP%] > ol[_ngcontent-%COMP%]{margin-top:.15rem;margin-bottom:.1rem}.ccap-assistant-md[_ngcontent-%COMP%] hr[_ngcontent-%COMP%]{border:0;height:1px;background:linear-gradient(90deg,transparent 0%,rgba(0,245,255,.38) 12%,rgba(0,245,255,.38) 88%,transparent 100%);margin:2.2rem 0}.ccap-assistant-md[_ngcontent-%COMP%] blockquote[_ngcontent-%COMP%]{margin:.75rem 0;padding:.45rem .85rem;border-left:3px solid rgba(0,245,255,.4);background:#00f5ff0a;border-radius:0 .25rem .25rem 0;color:#ffffffd9}.ccap-assistant-md[_ngcontent-%COMP%] blockquote[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:.2rem 0}.ccap-assistant-md[_ngcontent-%COMP%] table[_ngcontent-%COMP%]{width:100%;border-collapse:separate;border-spacing:0;margin:1rem 0;font-size:.9em;display:block;overflow-x:auto;border:1px solid rgba(0,245,255,.32);border-radius:.3rem}.ccap-assistant-md[_ngcontent-%COMP%] thead[_ngcontent-%COMP%]{position:sticky;top:0}.ccap-assistant-md[_ngcontent-%COMP%] th[_ngcontent-%COMP%]{background:#00f5ff24;font-weight:600;color:#00f5ffeb;border-bottom:1px solid rgba(0,245,255,.22);border-right:1px solid rgba(0,245,255,.12);padding:.45rem .7rem;text-align:left;vertical-align:top;white-space:nowrap}.ccap-assistant-md[_ngcontent-%COMP%] th[_ngcontent-%COMP%]:last-child{border-right:none}.ccap-assistant-md[_ngcontent-%COMP%] td[_ngcontent-%COMP%]{border-bottom:1px solid rgba(255,255,255,.16);border-right:1px solid rgba(255,255,255,.12);padding:.4rem .7rem;text-align:left;vertical-align:top}.ccap-assistant-md[_ngcontent-%COMP%] td[_ngcontent-%COMP%]:last-child{border-right:none}.ccap-assistant-md[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:last-child td[_ngcontent-%COMP%]{border-bottom:none}.ccap-assistant-md[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:nth-child(2n){background:#ffffff08}.ccap-assistant-md[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:hover{background:#00f5ff0e}.ccap-assistant-md[_ngcontent-%COMP%] pre[_ngcontent-%COMP%]{margin:.55rem 0;padding:.6rem .75rem;border-radius:.3rem;background:#00000080;border:1px solid rgba(255,255,255,.08);overflow-x:auto;font-size:.88em}.ccap-assistant-md[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-size:.9em}.ccap-assistant-md[_ngcontent-%COMP%] p[_ngcontent-%COMP%] code[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] li[_ngcontent-%COMP%] code[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] td[_ngcontent-%COMP%] code[_ngcontent-%COMP%], .ccap-assistant-md[_ngcontent-%COMP%] th[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{padding:.1rem .28rem;border-radius:.2rem;background:#00f5ff12;color:#00f5ffeb;border:1px solid rgba(0,245,255,.12)}.ccap-assistant-md[_ngcontent-%COMP%] pre[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{background:transparent;color:inherit;border:none;padding:0;font-size:inherit}.ccap-assistant-md[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{color:#38bdf8;text-decoration:underline;text-underline-offset:2px}.ccap-assistant-md[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:hover{color:#7dd3fc}
2
2
  /*# sourceMappingURL=s-agent-tool-plan-view.component-PVG3EXHY.css.map */`]})}return t})();var cn=(t,r)=>r.content,pn=(t,r,e)=>({"text-neutral-500 line-through":t,"text-blue-300":r,"text-neutral-300":e});function _n(t,r){t&1&&(M(),o(0,"svg",5),S(1,"path",10),s())}function mn(t,r){t&1&&(o(0,"span",6),S(1,"span",11),s())}function un(t,r){t&1&&(o(0,"span",6),S(1,"span",12),s())}function Cn(t,r){if(t&1&&(o(0,"div",9),d(1),s()),t&2){let e=c().$implicit;a(),T(e.activeForm)}}function fn(t,r){if(t&1&&(o(0,"div",4),g(1,_n,2,0,":svg:svg",5)(2,mn,2,0,"span",6)(3,un,2,0,"span",6),o(4,"div",7)(5,"span",8),d(6),s(),g(7,Cn,2,1,"div",9),s()()),t&2){let e,i=r.$implicit;a(),_((e=i.status)==="completed"?1:e==="in_progress"?2:3),a(4),b("ngClass",it(4,pn,i.status==="completed",i.status==="in_progress",i.status!=="completed"&&i.status!=="in_progress")),a(),T(i.content),a(),_(i.status==="in_progress"&&i.activeForm?7:-1)}}function xn(t,r){if(t&1&&(o(0,"div",0)(1,"div",1)(2,"span",2),d(3,"Tasks"),s(),o(4,"span",3),d(5),s()(),N(6,fn,8,8,"div",4,cn),s()),t&2){let e=c();a(5),J("",e.completedCount_$(),"/",e.totalCount_$(),""),a(),H(e.todos_$())}}var Fe=(()=>{class t{rawData=Q(void 0);todos_$=A(()=>{let e=this.rawData();if(!e)return[];let i=e.input;if(!i||typeof i!="object")return[];let n=i.todos;return Array.isArray(n)?n.filter(l=>typeof l=="object"&&l!==null&&typeof l.content=="string"):[]});completedCount_$=A(()=>this.todos_$().filter(e=>e.status==="completed").length);totalCount_$=A(()=>this.todos_$().length);static \u0275fac=function(i){return new(i||t)};static \u0275cmp=z({type:t,selectors:[["app-s-agent-tool-todo-list"]],hostAttrs:[1,"block"],inputs:{rawData:[1,"rawData"]},standalone:!0,features:[Te],decls:1,vars:1,consts:[[1,"px-2.5","py-1.5","space-y-0.5"],[1,"flex","items-center","gap-1.5","mb-1"],[1,"text-[10px]","text-neutral-500","uppercase","tracking-wider","font-medium"],[1,"text-[10px]","text-neutral-600"],[1,"flex","items-start","gap-2","py-0.5"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","2","stroke-linecap","round","stroke-linejoin","round",1,"w-4","h-4","text-green-400","shrink-0","mt-px"],[1,"w-4","h-4","shrink-0","mt-px","flex","items-center","justify-center"],[1,"min-w-0"],[1,"text-[11px]","leading-relaxed","break-words",3,"ngClass"],[1,"text-[9px]","text-blue-400/50","mt-px"],["d","M3.5 8.5l3 3 6-6"],[1,"w-3","h-3","rounded-full","border-2","border-blue-400/40","border-t-blue-400","animate-spin"],[1,"w-3","h-3","rounded-full","border","border-neutral-600"]],template:function(i,n){i&1&&g(0,xn,8,2,"div",0),i&2&&_(n.todos_$().length?0:-1)},dependencies:[oe,X],encapsulation:2})}return t})();var P="ccap-ccSession",y=class{static saveProjectFilter(r){O.writeString(`${P}:projectFilter`,r)}static loadProjectFilter(){return O.readString(`${P}:projectFilter`)??""}static saveLastWorkspacePath(r){O.writeString(`${P}:lastWorkspacePath`,r)}static loadLastWorkspacePath(){return O.readString(`${P}:lastWorkspacePath`)??""}static saveLastLabel(r){O.writeString(`${P}:lastLabel`,r)}static loadLastLabel(){return O.readString(`${P}:lastLabel`)??""}static savePromptDraft(r,e){Oe.saveDraft(P,r,e)}static loadPromptDraft(r){return Oe.loadDraft(P,r)}static clearPromptDraft(r){Oe.clearDraft(P,r)}static savePanelOpen(r,e){O.writeBoolean(`${P}:panelOpen:${r}`,e)}static loadPanelOpen(r,e){return O.readBoolean(`${P}:panelOpen:${r}`,e)}static savePanelWidth(r,e){O.writeNumber(`${P}:panelWidth:${r}`,e)}static loadPanelWidth(r,e){return O.readNumber(`${P}:panelWidth:${r}`,e)}static saveSessionMode(r){O.writeString(`${P}:sessionMode`,r)}static loadSessionMode(){return O.readString(`${P}:sessionMode`)??"normal"}static saveSessionEffort(r){O.writeString(`${P}:sessionEffort`,r)}static loadSessionEffort(){return O.readString(`${P}:sessionEffort`)??"high"}static saveSessionModel(r){O.writeString(`${P}:sessionModel`,r)}static loadSessionModel(){return O.readString(`${P}:sessionModel`)??"sonnet"}static saveStatusHistory(r){O.writeBoolean(`${P}:statusHistory`,r)}static loadStatusHistory(){return O.readBoolean(`${P}:statusHistory`,!1)}static saveLastSessionId(r){O.writeString(`${P}:lastSessionId`,r)}static loadLastSessionId(){return O.readString(`${P}:lastSessionId`)??""}static saveLastCcapId(r){O.writeString(`${P}:lastCcapId`,r)}static loadLastCcapId(){return O.readString(`${P}:lastCcapId`)??""}static saveShowStatusUpdates(r){O.writeBoolean(`${P}:showStatusUpdates`,r)}static loadShowStatusUpdates(){return O.readBoolean(`${P}:showStatusUpdates`,!0)}static saveShowArchived(r){O.writeBoolean(`${P}:showArchived`,r)}static loadShowArchived(){return O.readBoolean(`${P}:showArchived`,!1)}};var K=(()=>{class t{ccSession_DS=$(W);isTimelinePanelOpen_$=v(y.loadPanelOpen("timeline",!1));isMetadataPanelOpen_$=v(y.loadPanelOpen("metadata",!1));isResuming_$=v(!1);isTerminating_$=v(!1);isStopping_$=v(!1);isForking_$=v(!1);isShowSessionStatus_$=v(y.loadStatusHistory());isShowAgentUpdates_$=v(y.loadShowStatusUpdates());handleToggleTimeline(){let e=!this.isTimelinePanelOpen_$();this.isTimelinePanelOpen_$.set(e),y.savePanelOpen("timeline",e)}handleToggleMetadata(){let e=!this.isMetadataPanelOpen_$();this.isMetadataPanelOpen_$.set(e),y.savePanelOpen("metadata",e)}handleToggleSessionStatus(){let e=!this.isShowSessionStatus_$();this.isShowSessionStatus_$.set(e),y.saveStatusHistory(e)}handleToggleAgentUpdates(){let e=!this.isShowAgentUpdates_$();this.isShowAgentUpdates_$.set(e),y.saveShowStatusUpdates(e)}handleResume(){return R(this,null,function*(){let e=this.ccSession_DS.selectedSession_$();if(!e||this.isResuming_$())return;let i=e.session.sessionId;if(i){this.isResuming_$.set(!0);try{yield this.ccSession_DS.resumeSession({sessionId:i})}catch{}finally{this.isResuming_$.set(!1)}}})}handleStopExecution(){return R(this,null,function*(){let e=this.ccSession_DS.selectedSession_$();if(!e||this.isStopping_$())return;let i=e.session.sessionId;if(i){this.isStopping_$.set(!0);try{yield this.ccSession_DS.stopExecution({sessionId:i})}catch{}finally{this.isStopping_$.set(!1)}}})}handleFork(){return R(this,null,function*(){let e=this.ccSession_DS.selectedSession_$();if(!e||this.isForking_$())return null;let i=e.session.sessionId;if(!i||!e.session.claudeSessionId)return null;this.isForking_$.set(!0);try{return yield this.ccSession_DS.forkSession({sessionId:i})}catch{return null}finally{this.isForking_$.set(!1)}})}handleTerminate(){return R(this,null,function*(){let e=this.ccSession_DS.selectedSession_$();if(!e||this.isTerminating_$())return;let i=e.session.sessionId;if(i){this.isTerminating_$.set(!0);try{yield this.ccSession_DS.terminateSession({sessionId:i})}catch{}finally{this.isTerminating_$.set(!1)}}})}static \u0275fac=function(i){return new(i||t)};static \u0275prov=Je({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();var bn=(t,r)=>r._id,vn=(t,r)=>r.path;function wn(t,r){if(t&1&&(o(0,"option",26),d(1),s()),t&2){let e=c().$implicit;b("value",e.localPath),a(),T(e.name)}}function yn(t,r){if(t&1&&g(0,wn,2,2,"option",26),t&2){let e=r.$implicit;_(e.localPath?0:-1)}}function Tn(t,r){t&1&&(o(0,"div",12),d(1,"Loading sessions..."),s())}function kn(t,r){t&1&&(o(0,"div",13),d(1,"Failed to load sessions"),s())}function In(t,r){if(t&1){let e=k();o(0,"app-s-session-select",27),f("selected",function(n){u(e);let l=c();return C(l.handleSelectSession(n))})("contextMenu",function(n){u(e);let l=c();return C(l.handleRowContextMenu(n))})("scheduleIndicatorClicked",function(n){u(e);let l=c();return C(l.handleScheduleIndicatorClick(n))})("coordinatorIndicatorClicked",function(n){u(e);let l=c();return C(l.handleCoordinatorIndicatorClick(n))}),s()}if(t&2){let e=c();b("rows",e.sessionRowViews_$())("activeId",e.ccSession_DS.activeSessionId_$())("hideSearch",!0)}}function $n(t,r){t&1&&(o(0,"div",12),d(1,"No sessions found"),s())}function Dn(t,r){if(t&1&&(o(0,"option",26),d(1),s()),t&2){let e=r.$implicit;b("value",e.path),a(),J("",e.label," \u2014 ",e.path,"")}}function En(t,r){if(t&1){let e=k();o(0,"select",28),f("ngModelChange",function(n){u(e);let l=c();return C(l.handlePathOptionChange(n))}),o(1,"option",29),d(2,"Select a path..."),s(),N(3,Dn,2,3,"option",26,vn),o(5,"option",30),d(6,"Custom path..."),s()()}if(t&2){let e=c();b("ngModel",e.selectedPathOption_$()),a(3),H(e.newAgentSessionWorkspace_DS.workspacePathPickerOptions_$())}}function Mn(t,r){if(t&1){let e=k();o(0,"div",33)(1,"input",34,0),f("input",function(){u(e);let n=xe(2),l=c(2);return C(l.renameValue_$.set(n.value))})("keydown.enter",function(){u(e);let n=c(2);return C(n.handleCtxRenameConfirm())})("keydown.escape",function(){u(e);let n=c(2);return C(n.handleCloseCtxMenu())}),s()()}if(t&2){let e=c(2);a(),b("value",e.renameValue_$())}}function Pn(t,r){if(t&1){let e=k();o(0,"button",35),f("click",function(){u(e);let n=c(3);return C(n.handleCtxResume())}),d(1," Resume "),s()}}function An(t,r){if(t&1){let e=k();S(0,"div",37),o(1,"button",38),f("click",function(){u(e);let n=c(3);return C(n.handleCtxTerminate())}),d(2," Terminate "),s()}}function On(t,r){if(t&1){let e=k();o(0,"button",35),f("click",function(){u(e);let n=c(2);return C(n.handleCtxRenameStart())}),d(1," Rename "),s(),o(2,"button",35),f("click",function(){u(e);let n=c(2);return C(n.handleCtxToggleArchive())}),d(3),s(),g(4,Pn,2,0,"button",36)(5,An,3,0)}if(t&2){let e=c();a(3),D(" ",e.isArchived?"Unarchive":"Archive"," "),a(),_(e.status==="completed"||e.status==="errored"?4:-1),a(),_(e.status==="running"||e.status==="starting"||e.status==="waiting-input"?5:-1)}}function Rn(t,r){if(t&1){let e=k();o(0,"div",31),f("click",function(){u(e);let n=c();return C(n.handleCloseCtxMenu())}),s(),o(1,"div",32),g(2,Mn,3,1,"div",33)(3,On,6,3),s()}if(t&2){let e=c();a(),we("left",e.ctxMenuPos_$().x,"px")("top",e.ctxMenuPos_$().y,"px"),a(),_(e.isRenaming_$()?2:3)}}var jt=(()=>{class t{ccSession_DS=$(W);newAgentSessionWorkspace_DS=$(wt);pm_DS=$(yt);peiContext_DS=$(ae);scheduledJobs_DS=$(Me);coordinator_DS=$(Pe);router=$(se);instanceChangeEffect=ke(()=>{let e=this.peiContext_DS.activeCcapId_$(),i=this.showArchived_$();e&&at(()=>{this.ccSession_DS.loadSessions({includeArchived:i||void 0})})});projectFilter_$=v("");filteredSessions_$=A(()=>{let e=this.ccSession_DS.sessions_$(),i=this.projectFilter_$();if(!i)return e;let n=t.normalizePath(i);return e.filter(l=>!!l.workspacePath&&t.normalizePath(l.workspacePath)===n)});sessionRowViews_$=A(()=>{let e=this.scheduledJobs_DS.scheduledSessionIds_$(),i=this.coordinator_DS.coordinatedSessionIds_$();return this.filteredSessions_$().map(n=>({id:n.sessionId,label:n.label||n.sessionId,status:n.status,statusColorClass:qe.resolve(n.status),workspacePath:n.workspacePath,isArchived:!!n.isArchived,lastActivityAt:n.lastActivityAt,promptCount:n.promptCount,isRunning:qe.isRunning(n.status),hasSchedule:e.has(n.sessionId),hasCoordinator:i.has(n.sessionId)}))});isCreateDialogOpen_$=v(!1);schedulePopupSessionId_$=v(null);coordinatorPopupSessionId_$=v(null);newSessionWorkspacePath_$=v("");newSessionLabel_$=v("");isCreating_$=v(!1);showArchived_$=v(!1);selectedPathOption_$=v("");sessionSelected=ve();ctxMenuSession_$=v(null);ctxMenuPos_$=v({x:0,y:0});isRenaming_$=v(!1);renameValue_$=v("");ngOnInit(){let e=y.loadProjectFilter();e&&this.projectFilter_$.set(e);let i=y.loadShowArchived();this.showArchived_$.set(i),!this.pm_DS.projectsLoadedOnce_$()&&!this.pm_DS.projectsLoading_$()&&this.pm_DS.loadProjects(),this.peiContext_DS.ensureInitialized().then(()=>{this.ccSession_DS.loadSessions({includeArchived:i||void 0})}),this.scheduledJobs_DS.loadAll(),this.coordinator_DS.loadAllCoordinatorsForManagementPage()}handleSelectSession(e){let i=this.peiContext_DS.activeCcapId_$(),n=i?["/cc-session",i,e]:["/cc-session",e];this.router.navigate(n),this.sessionSelected.emit()}handleOpenCreateDialog(){return R(this,null,function*(){if(this.isCreateDialogOpen_$.set(!0),yield this.newAgentSessionWorkspace_DS.refreshWorkspacePathPickerOptions(),!this.newSessionWorkspacePath_$()){let i=this.newAgentSessionWorkspace_DS.resolveInitialWorkspacePath({lastWorkspacePath:y.loadLastWorkspacePath()});if(i){this.newSessionWorkspacePath_$.set(i);let n=this.newAgentSessionWorkspace_DS.workspacePathPickerOptions_$().some(l=>l.path===i);this.selectedPathOption_$.set(n?i:"custom")}}let e=y.loadLastLabel();e&&this.newSessionLabel_$.set(e)})}handlePathOptionChange(e){this.selectedPathOption_$.set(e),e&&e!=="custom"&&this.newSessionWorkspacePath_$.set(e)}handleCloseCreateDialog(){this.isCreateDialogOpen_$.set(!1),this.newSessionWorkspacePath_$.set(""),this.newSessionLabel_$.set(""),this.selectedPathOption_$.set("")}handleCreateSession(){return R(this,null,function*(){let e=this.newSessionWorkspacePath_$();if(!(!e||this.isCreating_$())){this.isCreating_$.set(!0);try{y.saveLastWorkspacePath(e),y.saveLastLabel(this.newSessionLabel_$());let i=y.loadSessionMode(),n=y.loadSessionEffort(),l=yield this.ccSession_DS.createSession({workspacePath:e,label:this.newSessionLabel_$()||void 0,mode:i||void 0,reasoningEffort:n||void 0});if(this.handleCloseCreateDialog(),l){let p=this.peiContext_DS.activeCcapId_$(),m=p?["/cc-session",p,l]:["/cc-session",l];this.router.navigate(m)}}catch{this.handleCloseCreateDialog()}finally{this.isCreating_$.set(!1)}}})}handleProjectFilterChange(e){this.projectFilter_$.set(e),y.saveProjectFilter(e)}handleToggleShowArchived(){let e=!this.showArchived_$();this.showArchived_$.set(e),y.saveShowArchived(e),this.handleRefresh()}handleToggleArchive(e,i){return R(this,null,function*(){e.stopPropagation();try{yield this.ccSession_DS.setSessionArchived({sessionId:i.sessionId,isArchived:!i.isArchived}),this.handleRefresh()}catch{}})}handleRowContextMenu(e){this.isRenaming_$.set(!1);let i=this.filteredSessions_$().find(n=>n.sessionId===e.id);i&&(this.ctxMenuSession_$.set(i),this.ctxMenuPos_$.set({x:e.event.clientX,y:e.event.clientY}))}handleScheduleIndicatorClick(e){this.schedulePopupSessionId_$.set(e)}handleCloseSchedulePopup(){this.schedulePopupSessionId_$.set(null)}handleCoordinatorIndicatorClick(e){this.coordinatorPopupSessionId_$.set(e)}handleCloseCoordinatorPopup(){this.coordinatorPopupSessionId_$.set(null)}handleCloseCtxMenu(){this.ctxMenuSession_$.set(null),this.isRenaming_$.set(!1),this.renameValue_$.set("")}handleCtxRenameStart(){let e=this.ctxMenuSession_$();e&&(this.renameValue_$.set(e.label||""),this.isRenaming_$.set(!0),setTimeout(()=>{let i=document.querySelector("#ctxRenameInput");i&&(i.focus(),i.select())},0))}handleCtxRenameConfirm(){return R(this,null,function*(){let e=this.ctxMenuSession_$();if(!e)return;let i=this.renameValue_$().trim();if(i!==(e.label||""))try{yield this.ccSession_DS.updateSessionConfig({sessionId:e.sessionId,label:i})}catch{}this.handleCloseCtxMenu()})}handleCtxToggleArchive(){return R(this,null,function*(){let e=this.ctxMenuSession_$();if(e){this.handleCloseCtxMenu();try{yield this.ccSession_DS.setSessionArchived({sessionId:e.sessionId,isArchived:!e.isArchived}),this.handleRefresh()}catch{}}})}handleCtxTerminate(){return R(this,null,function*(){let e=this.ctxMenuSession_$();if(e){this.handleCloseCtxMenu();try{yield this.ccSession_DS.terminateSession({sessionId:e.sessionId}),this.handleRefresh()}catch{}}})}handleCtxResume(){return R(this,null,function*(){let e=this.ctxMenuSession_$();if(e){this.handleCloseCtxMenu();try{yield this.ccSession_DS.resumeSession({sessionId:e.sessionId}),this.handleRefresh()}catch{}}})}handleRefresh(){this.ccSession_DS.loadSessions({includeArchived:this.showArchived_$()||void 0})}static normalizePath(e){let i=e.trim().toLowerCase().replace(/\\/g,"/");for(;i.endsWith("/")&&i.length>1;)i=i.slice(0,-1);return i}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=z({type:t,selectors:[["app-ccap-cc-dashboard"]],hostAttrs:[1,"flex","flex-col","flex-1","min-h-0","overflow-hidden"],outputs:{sessionSelected:"sessionSelected"},decls:41,vars:24,consts:[["renameInput",""],[1,"p-2","border-b","border-neonDefault"],[1,"flex","items-center","justify-between","p-3","border-b","border-neonDefault"],[1,"text-sm","font-semibold","text-neutral-200"],[1,"flex","gap-1"],["title","Refresh",1,"px-2","py-1","text-xs","border","border-neonDefault","text-neutral-300","hover:bg-neutral-700","rounded","transition-colors",3,"click"],[1,"px-2","py-1","text-xs","border","border-ccapAccent","text-ccapAccent","hover:bg-ccapAccent","hover:text-white","hover:shadow-neon-glow-accent","rounded","transition-colors",3,"click"],[1,"p-2","border-b","border-neonDefault","flex","gap-2","items-center"],[1,"flex-1","bg-neutral-900","text-neutral-300","text-xs","rounded","px-2","py-1","border","border-neonDefault",3,"ngModelChange","ngModel"],["value",""],[1,"px-2","py-1","text-[10px]","border","rounded","transition-colors","whitespace-nowrap",3,"click","title"],[1,"flex-1","overflow-y-auto"],[1,"p-4","text-center","text-neutral-500","text-sm"],[1,"p-4","text-center","text-red-400","text-sm"],["kind","cc",3,"rows","activeId","hideSearch"],[3,"closed","isOpen","title","maxWidth","closeOnBackdropClick"],[1,"mb-2"],[1,"text-xs","text-neutral-400","block","mb-1"],[1,"w-full","bg-neutral-900","text-neutral-300","text-xs","rounded","px-2","py-1.5","border","border-neonDefault","focus:border-neonCyan","focus:outline-none","mb-1.5",3,"ngModel"],["type","text","placeholder","/path/to/workspace",1,"w-full","bg-neutral-900","text-neutral-200","text-sm","rounded","px-2","py-1.5","border","border-neonDefault","focus:border-neonCyan","focus:outline-none",3,"ngModelChange","ngModel"],[1,"mb-3"],["type","text","placeholder","My session",1,"w-full","bg-neutral-900","text-neutral-200","text-sm","rounded","px-2","py-1.5","border","border-neonDefault","focus:border-neonCyan","focus:outline-none",3,"ngModelChange","ngModel"],[1,"flex","justify-end","gap-2"],[1,"px-3","py-1.5","text-xs","border","border-neonDefault","text-neutral-300","hover:bg-neutral-700","rounded","transition-colors",3,"click","disabled"],[1,"px-3","py-1.5","text-xs","border","border-ccapAccent","text-ccapAccent","hover:bg-ccapAccent","hover:text-white","disabled:opacity-50","rounded","transition-colors",3,"click","disabled"],[3,"closed","sessionId","isOpen"],[3,"value"],["kind","cc",3,"selected","contextMenu","scheduleIndicatorClicked","coordinatorIndicatorClicked","rows","activeId","hideSearch"],[1,"w-full","bg-neutral-900","text-neutral-300","text-xs","rounded","px-2","py-1.5","border","border-neonDefault","focus:border-neonCyan","focus:outline-none","mb-1.5",3,"ngModelChange","ngModel"],["value","","disabled",""],["value","custom"],[1,"fixed","inset-0","z-40",3,"click"],[1,"fixed","z-50","min-w-[160px]","bg-neutral-900","border","border-neutral-700","rounded-lg","shadow-xl","py-1","text-xs"],[1,"px-2","py-1.5"],["id","ctxRenameInput","type","text",1,"w-full","bg-neutral-800","text-neutral-200","text-xs","rounded","px-2","py-1","border","border-neonDefault","focus:border-neonCyan","focus:outline-none",3,"input","keydown.enter","keydown.escape","value"],[1,"w-full","text-left","px-3","py-1.5","text-neutral-300","hover:bg-neutral-800","transition-colors",3,"click"],[1,"w-full","text-left","px-3","py-1.5","text-neutral-300","hover:bg-neutral-800","transition-colors"],[1,"border-t","border-neutral-700","my-1"],[1,"w-full","text-left","px-3","py-1.5","text-red-400","hover:bg-red-500/10","transition-colors",3,"click"]],template:function(i,n){if(i&1&&(o(0,"div",1),S(1,"app-s-instance-chip-row-with-info"),s(),o(2,"div",2)(3,"h2",3),d(4,"CC Sessions"),s(),o(5,"div",4)(6,"button",5),f("click",function(){return n.handleRefresh()}),d(7," Refresh "),s(),o(8,"button",6),f("click",function(){return n.handleOpenCreateDialog()}),d(9," + New "),s()()(),o(10,"div",7)(11,"select",8),f("ngModelChange",function(p){return n.handleProjectFilterChange(p)}),o(12,"option",9),d(13,"All projects"),s(),N(14,yn,1,1,null,null,bn),s(),o(16,"button",10),f("click",function(){return n.handleToggleShowArchived()}),d(17),s()(),o(18,"div",11),g(19,Tn,2,0,"div",12)(20,kn,2,0,"div",13)(21,In,1,3,"app-s-session-select",14)(22,$n,2,0,"div",12),s(),o(23,"app-s-modal",15),f("closed",function(){return n.isCreateDialogOpen_$.set(!1)}),o(24,"div",16)(25,"label",17),d(26,"Workspace Path *"),s(),g(27,En,7,1,"select",18),o(28,"input",19),f("ngModelChange",function(p){return n.newSessionWorkspacePath_$.set(p)}),s()(),o(29,"div",20)(30,"label",17),d(31,"Label (optional)"),s(),o(32,"input",21),f("ngModelChange",function(p){return n.newSessionLabel_$.set(p)}),s()(),o(33,"div",22)(34,"button",23),f("click",function(){return n.handleCloseCreateDialog()}),d(35," Cancel "),s(),o(36,"button",24),f("click",function(){return n.handleCreateSession()}),d(37),s()()(),o(38,"app-sch-schedule-popup",25),f("closed",function(){return n.handleCloseSchedulePopup()}),s(),o(39,"app-crd-info-popup",25),f("closed",function(){return n.handleCloseCoordinatorPopup()}),s(),g(40,Rn,4,5)),i&2){let l;a(11),b("ngModel",n.projectFilter_$()),a(3),H(n.pm_DS.projects_$()),a(2),V(n.showArchived_$()?"border-amber-500/60 text-amber-400 bg-amber-500/10 hover:bg-amber-500/20":"border-neonDefault text-neutral-500 hover:text-neutral-300 hover:bg-neutral-700"),b("title",n.showArchived_$()?"Hide archived sessions":"Show archived sessions"),a(),D(" ",n.showArchived_$()?"Archived ON":"Archived"," "),a(2),_(n.ccSession_DS.sessionsLoading_$()?19:-1),a(),_(n.ccSession_DS.sessionsLoadError_$()?20:-1),a(),_(n.sessionRowViews_$().length?21:-1),a(),_(!n.ccSession_DS.sessionsLoading_$()&&!n.sessionRowViews_$().length?22:-1),a(),b("isOpen",n.isCreateDialogOpen_$())("title","New CC Session")("maxWidth","sm")("closeOnBackdropClick",!1),a(4),_(n.newAgentSessionWorkspace_DS.workspacePathPickerOptions_$().length?27:-1),a(),b("ngModel",n.newSessionWorkspacePath_$()),a(4),b("ngModel",n.newSessionLabel_$()),a(2),b("disabled",n.isCreating_$()),a(2),b("disabled",n.isCreating_$()||!n.newSessionWorkspacePath_$()),a(),D(" ",n.isCreating_$()?"Creating...":"Create"," "),a(),b("sessionId",n.schedulePopupSessionId_$())("isOpen",n.schedulePopupSessionId_$()!==null),a(),b("sessionId",n.coordinatorPopupSessionId_$())("isOpen",n.coordinatorPopupSessionId_$()!==null),a(),_((l=n.ctxMenuSession_$())?40:-1,l)}},dependencies:[xt,ht,mt,ft,ut,Ct,Ae,Y,de,ce,Tt],encapsulation:2})}return t})();var Ue=(()=>{class t{transform(e){switch(e){case"running":return"bg-yellow-500";case"waiting-input":return"bg-green-500";case"starting":return"bg-yellow-500";case"creating":return"bg-yellow-400";case"completed":return"bg-blue-500";case"errored":return"bg-red-500";case"terminated":return"bg-red-700";case"stalled":return"bg-orange-500";default:return"bg-neutral-600"}}static \u0275fac=function(i){return new(i||t)};static \u0275pipe=ie({name:"ccSessionStatusColor",type:t,pure:!0})}return t})();function Fn(t,r){t&1&&S(0,"div",5)}function Un(t,r){if(t&1){let e=k();o(0,"button",14),f("click",function(){u(e);let n=c();return C(n.detailUi_DS.handleToggleMetadata())}),d(1," Info "),s()}if(t&2){let e=c();V(e.detailUi_DS.isMetadataPanelOpen_$()?"border-neonCyan/50 text-neonCyan bg-neonCyan/10":"border-neutral-700 text-neutral-500 hover:text-neutral-300 hover:border-neutral-600")}}function jn(t,r){t&1&&S(0,"span",18)}function zn(t,r){if(t&1&&(S(0,"span",17),F(1,"ccSessionStatusColor"),g(2,jn,1,0,"span",18)),t&2){c(2);let e=ye(1);b("ngClass",j(1,3,e.detail.session.status))("title",e.detail.session.status),a(2),_(e.detail.runtime.isLive?2:-1)}}function Bn(t,r){t&1&&(o(0,"span",16),d(1,"Loading\u2026"),s())}function Wn(t,r){if(t&1&&(o(0,"span",15),d(1),s(),g(2,zn,3,5)(3,Bn,2,0,"span",16)),t&2){c();let e=ye(1);b("title",e.title),a(),D(" ",e.title," "),a(),_(e.detail?2:-1),a(),_(e.isLoading&&!e.showActions?3:-1)}}function Nn(t,r){if(t&1){let e=k();o(0,"button",23),f("click",function(){u(e);let n=c(2);return C(n.detailUi_DS.handleStopExecution())}),d(1),s()}if(t&2){let e=c(2);b("disabled",e.detailUi_DS.isStopping_$()),a(),D(" ",e.detailUi_DS.isStopping_$()?"Stopping\u2026":"Stop"," ")}}function Hn(t,r){if(t&1){let e=k();he(0),o(1,"div",9)(2,"button",19),f("click",function(){u(e);let n=c();return C(n.detailUi_DS.handleToggleTimeline())}),d(3," Timeline "),s(),o(4,"button",20),f("click",function(){u(e);let n=c();return C(n.handleForkSession())}),d(5),s(),S(6,"span",21),g(7,Nn,2,2,"button",22),s()}if(t&2){let e=c(),n=ye(1).detail;a(2),V(e.detailUi_DS.isTimelinePanelOpen_$()?"border-neonCyan/50 text-neonCyan bg-neonCyan/10":"border-neutral-700 text-neutral-500 hover:text-neutral-300 hover:border-neutral-600"),a(2),b("disabled",e.detailUi_DS.isForking_$()||!n.session.claudeSessionId)("title",e.detailUi_DS.isForking_$()?"Fork in progress\u2026":n.session.claudeSessionId?"Fork conversation into new session":"Cannot fork: no conversation yet"),a(),D(" ",e.detailUi_DS.isForking_$()?"Forking\u2026":"Fork"," "),a(2),_(n.session.status==="running"?7:-1)}}var Ht=(()=>{class t{router=$(se);peiContext_DS=$(ae);ccSession_DS=$(W);detailUi_DS=$(K);sidebarWidth_$=v(320);isSidebarOpen_$=v(!0);isResizing_$=v(!1);ccTopBarContext_$=A(()=>{let e=this.ccSession_DS.activeSessionId_$();if(!e)return null;let i=this.ccSession_DS.selectedSessionLoading_$(),n=this.ccSession_DS.selectedSession_$(),p=this.ccSession_DS.sessions_$().find(I=>I.sessionId===e),m=n?.session.sessionId===e;return{title:(m?n.session.label||n.session.sessionId:null)??(p?p.label||p.sessionId:e),detail:m?n:null,showActions:m&&!i,isLoading:i}});ngOnInit(){let e=y.loadPanelWidth("sidebar",320);this.sidebarWidth_$.set(Math.max(200,Math.min(600,e))),this.isSidebarOpen_$.set(y.loadPanelOpen("sidebar",!0))}handleSidebarResizeStart(e){let i=e.clientX,n=this.sidebarWidth_$();this.isResizing_$.set(!0),ge.attachUntilPointerUp({startEvent:e,onMove:l=>{let p=l.clientX-i,m=Math.max(200,Math.min(600,n+p));this.sidebarWidth_$.set(m)},onEnd:()=>{this.isResizing_$.set(!1),y.savePanelWidth("sidebar",this.sidebarWidth_$())}})}handleToggleSidebar(){this.isSidebarOpen_$.update(e=>!e),y.savePanelOpen("sidebar",this.isSidebarOpen_$())}handleSessionSelectedFromDashboard(){window.innerWidth<640&&this.isSidebarOpen_$.set(!1)}handleForkSession(){return R(this,null,function*(){let e=yield this.detailUi_DS.handleFork();if(e){let i=this.peiContext_DS.activeCcapId_$(),n=i?["/cc-session",i,e]:["/cc-session",e];yield this.router.navigate(n)}})}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=z({type:t,selectors:[["app-ccap-cc-shell"]],hostAttrs:[1,"flex","min-h-0","w-full","flex-1","flex-col","overflow-hidden"],decls:19,vars:14,consts:[[1,"flex","min-h-0","w-full","flex-1","flex-col","overflow-hidden"],["sSessionToolbarLeft","",1,"flex","items-center","gap-1","min-w-0"],[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"],[1,"w-px","h-4","bg-neutral-700","shrink-0","self-center","mx-0.5"],["type","button",1,"px-2","py-1","text-xs","border","rounded","transition-colors","shrink-0",3,"class"],["sSessionToolbarCenter","",1,"flex","flex-wrap","items-center","justify-center","gap-2","min-w-0","max-w-[min(100vw-10rem,48rem)]"],["sSessionToolbarRight","",1,"flex","items-center","gap-1","min-w-0","flex-wrap","justify-end"],[1,"flex","gap-1","shrink-0","items-center","flex-wrap","justify-end"],[3,"sidebarResizeStart","isSidebarOpen","sidebarWidthPx","isResizing"],["sSessionShellSidebar","",1,"flex","flex-col","overflow-hidden","h-full"],[3,"sessionSelected"],["sSessionShellMain","",1,"flex","min-h-0","flex-1","flex-col","overflow-hidden","[&>router-outlet]:contents"],["type","button",1,"px-2","py-1","text-xs","border","rounded","transition-colors","shrink-0",3,"click"],[1,"text-sm","font-semibold","text-neutral-200","truncate","text-center","min-w-0","max-w-[min(240px,35vw)]",3,"title"],[1,"text-[10px]","text-neutral-500","shrink-0"],[1,"w-2","h-2","rounded-full","shrink-0",3,"ngClass","title"],["title","Live",1,"w-2","h-2","rounded-full","bg-green-500","animate-pulse","shrink-0"],[1,"px-2","py-1","text-xs","border","rounded","transition-colors",3,"click"],[1,"px-2","py-1","text-xs","border","border-neutral-700","text-neutral-500","hover:text-neutral-300","hover:border-neutral-600","disabled:opacity-40","rounded","transition-colors",3,"click","disabled","title"],[1,"w-px","bg-neutral-700","mx-0.5","self-stretch","min-h-[1.25rem]"],[1,"px-2","py-1","text-xs","border","border-neonRed/50","text-red-300","hover:bg-red-950/40","disabled:opacity-40","rounded","transition-colors",3,"disabled"],[1,"px-2","py-1","text-xs","border","border-neonRed/50","text-red-300","hover:bg-red-950/40","disabled:opacity-40","rounded","transition-colors",3,"click","disabled"]],template:function(i,n){if(i&1){let l=k();o(0,"div",0),he(1),o(2,"app-s-session-shell-toolbar")(3,"div",1)(4,"button",2),f("click",function(){return u(l),C(n.handleToggleSidebar())}),M(),o(5,"svg",3),S(6,"polyline",4),s(),d(7," Sessions "),s(),g(8,Fn,1,0,"div",5)(9,Un,2,2,"button",6),s(),L(),o(10,"div",7),g(11,Wn,4,4),s(),o(12,"div",8),g(13,Hn,8,6,"div",9),s()(),o(14,"app-s-resizable-session-shell-layout",10),f("sidebarResizeStart",function(m){return u(l),C(n.handleSidebarResizeStart(m))}),o(15,"div",11)(16,"app-ccap-cc-dashboard",12),f("sessionSelected",function(){return u(l),C(n.handleSessionSelectedFromDashboard())}),s()(),o(17,"div",13),S(18,"router-outlet"),s()()()}if(i&2){me("select-none",n.isResizing_$()),a();let l=nt(n.ccTopBarContext_$());a(4),me("rotate-90",n.isSidebarOpen_$())("-rotate-90",!n.isSidebarOpen_$()),a(3),_(l?8:-1),a(),_(l&&l.showActions&&l.detail?9:-1),a(2),_(l?11:-1),a(2),_(l&&l.showActions&&l.detail?13:-1),a(),b("isSidebarOpen",n.isSidebarOpen_$())("sidebarWidthPx",n.sidebarWidth_$())("isResizing",n.isResizing_$())}},dependencies:[X,pt,kt,It,jt,Ue],encapsulation:2})}return t})();var te=Ge(dt());var Se=function(t){return t.normal="normal",t.plan="plan",t}(Se||{});var pe=function(t){return t.sonnet="sonnet",t.opus="opus",t.haiku="haiku",t}(pe||{});var be=class t{static fromDisplayItem(r){let e=t.mapMessageTypeToKind(r.messageType),i=r.pairedResult?{text:r.pairedResult.text,expandableContent:r.pairedResult.expandableContent,rawData:r.pairedResult.rawData,isError:r.pairedResult.isError}:void 0,n=r.messageType==="tool"&&r.toolName==="Edit"&&!!r.expandableContent;return{listKey:r.listKey,kind:e,bodyText:r.text,toolName:r.toolName,expandableContent:r.expandableContent,pairedResult:i,rawData:r.rawData,subtype:r.subtype,isUserAligned:r.messageType==="prompt",flags:{showCopy:!0,showRawInfo:!0,useEditDiffForExpandable:n}}}static mapMessageTypeToKind(r){switch(r){case"prompt":return U.userPrompt;case"assistant":return U.assistant;case"tool":return U.tool;case"tool-result":return U.toolResult;case"error":return U.error;case"info":return U.info;case"status":return U.status;case"result":return U.result;case"run-intent":return U.runIntent;case"iteration":return U.iteration;case"thinking":return U.thinking;case"status-update":return U.statusUpdate;case"raw":return U.raw;case"tool-group":return U.toolGroup;case"sub-agent-group":return U.subAgentGroup;default:return U.info}}};var je=(()=>{class t{sanitizer;constructor(e){this.sanitizer=e}transform(e){if(!e)return this.sanitizer.bypassSecurityTrustHtml('<span class="text-neutral-500">{}</span>');try{let i=JSON.stringify(e,null,2),n=this.highlightJson(i);return this.sanitizer.bypassSecurityTrustHtml(n)}catch{return this.sanitizer.bypassSecurityTrustHtml('<span class="text-neutral-500">{}</span>')}}MULTILINE_THRESHOLD=150;highlightJson(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/("(\\u[\da-fA-F]{4}|\\[^u]|[^\\"])*"(\s*:)?|\b(true|false|null)\b|-?\d+(?:\.\d*)?(?:[eE][+-]?\d+)?)/g,n=>/^"/.test(n)?/:$/.test(n)?`<span style="color:#7dd3fc">${n}</span>`:n.length>this.MULTILINE_THRESHOLD&&n.includes("\\n")?this.formatMultilineString(n):`<span style="color:#86efac">${n}</span>`:/true|false/.test(n)?`<span style="color:#fbbf24">${n}</span>`:/null/.test(n)?`<span style="color:#a78bfa">${n}</span>`:`<span style="color:#fb923c">${n}</span>`)}formatMultilineString(e){return'<span style="color:#86efac">"</span><span style="display:block;margin:2px 0;padding:4px 8px;border-left:2px solid rgba(134,239,172,0.25);background:rgba(134,239,172,0.04);border-radius:0 4px 4px 0;color:#86efac;opacity:0.85;white-space:pre-wrap;word-break:break-word;font-size:0.9em;line-height:1.5">'+e.slice(1,-1).replace(/\\n/g,`
3
3
  `).replace(/\\t/g," ").replace(/\\r/g,"").replace(/\\"/g,'"').replace(/\\\\/g,"\\")+'</span><span style="color:#86efac">"</span>'}static \u0275fac=function(i){return new(i||t)(et(Ie,16))};static \u0275pipe=ie({name:"ccSessionJsonFormat",type:t,pure:!0})}return t})();var qn=["chatScroll"],Kn=["sessionInput"],Qn=(t,r)=>r.promptListKey,Qe=(t,r)=>r.listKey,Gn=(t,r)=>r.trackKey,Kt=t=>({$implicit:t});function Jn(t,r){if(t&1){let e=k();o(0,"div",14),f("click",function(){u(e);let n=c();return C(n.handleStickyPromptClick())}),o(1,"div",15)(2,"span",16),d(3,"YOU"),s(),o(4,"span",17),d(5),s(),M(),o(6,"svg",18),S(7,"path",19),s()()()}if(t&2){let e=c();a(5),T(e.lastPromptText_$())}}function Xn(t,r){if(t&1){let e=k();o(0,"button",34),f("click",function(){u(e);let n=c(3).$implicit,l=c();return C(l.handleOpenInfoPopup(n))}),o(1,"span",35),d(2,"i"),s()()}}function Yn(t,r){if(t&1){let e=k();o(0,"app-s-agent-tool-plan-view",36),f("accepted",function(){u(e);let n=c(4);return C(n.handlePlanAccepted())}),s()}if(t&2){let e=c(3).$implicit;b("rawData",e.rawData)}}function Zn(t,r){if(t&1&&S(0,"app-s-agent-tool-todo-list",33),t&2){let e=c(3).$implicit;b("rawData",e.rawData)}}function ei(t,r){if(t&1&&(o(0,"div",29),S(1,"span",30),F(2,"sAgentToolIcon"),o(3,"span",31),d(4),s(),g(5,Xn,3,0,"button",32),s(),g(6,Yn,1,1,"app-s-agent-tool-plan-view",33)(7,Zn,1,1,"app-s-agent-tool-todo-list",33)),t&2){let e,i=c(2).$implicit;a(),b("innerHTML",j(2,4,(e=i.toolName)!==null&&e!==void 0?e:""),G),a(3),T(i.toolName==="ExitPlanMode"?"Plan":i.toolName),a(),_(i.rawData?5:-1),a(),_(i.toolName==="ExitPlanMode"?6:7)}}function ti(t,r){if(t&1){let e=k();o(0,"app-s-agent-tool-call-card",37),f("toolRawInfoClick",function(){u(e);let n=c(2).$implicit,l=c();return C(l.handleOpenInfoPopup(n))})("pairedRawInfoClick",function(){u(e);let n=c(2).$implicit,l=c();return C(l.handleOpenPairedResultInfo(n))}),s()}if(t&2){let e,i,n,l,p=c(2).$implicit;b("toolName",(e=p.toolName)!==null&&e!==void 0?e:"")("summaryText",p.text)("toolDescription",(i=p.toolDescription)!==null&&i!==void 0?i:"")("isPathRtl",p.toolName==="Read")("showToolRawInfo",!!p.rawData||!!(p.pairedResult!=null&&p.pairedResult.rawData))("expandableContent",(n=p.expandableContent)!==null&&n!==void 0?n:"")("pairedResult",(l=p.pairedResult)!==null&&l!==void 0?l:null)}}function ni(t,r){if(t&1&&(o(0,"div",20)(1,"div",27),g(2,ei,8,6)(3,ti,1,7,"app-s-agent-tool-call-card",28),s()()),t&2){let e=c().$implicit;a(2),_(e.toolName==="TodoWrite"||e.toolName==="ExitPlanMode"?2:3)}}function ii(t,r){if(t&1){let e=k();o(0,"app-s-agent-tool-call-card",45),f("toolRawInfoClick",function(){u(e);let n=c().$implicit,l=c(3);return C(l.handleOpenInfoPopup(n))})("pairedRawInfoClick",function(){u(e);let n=c().$implicit,l=c(3);return C(l.handleOpenPairedResultInfo(n))}),s()}if(t&2){let e,i,n,l,p=c().$implicit;b("toolName",(e=p.toolName)!==null&&e!==void 0?e:"")("summaryText",p.text)("toolDescription",(i=p.toolDescription)!==null&&i!==void 0?i:"")("isPathRtl",p.toolName==="Read")("showToolRawInfo",!!p.rawData||!!(p.pairedResult!=null&&p.pairedResult.rawData))("expandableContent",(n=p.expandableContent)!==null&&n!==void 0?n:"")("pairedResult",(l=p.pairedResult)!==null&&l!==void 0?l:null)}}function oi(t,r){if(t&1&&(o(0,"div",44)(1,"span",46),d(2),s()()),t&2){let e=c().$implicit;a(2),T(e.text)}}function si(t,r){if(t&1&&g(0,ii,1,7,"app-s-agent-tool-call-card",43)(1,oi,3,1,"div",44),t&2){let e=r.$implicit;_(e.messageType==="tool"?0:-1),a(),_(e.messageType==="tool-result"?1:-1)}}function ai(t,r){if(t&1&&(o(0,"div",20)(1,"details",38)(2,"summary",39),S(3,"span",30),F(4,"sAgentToolIcon"),o(5,"span",31),d(6),s(),M(),o(7,"svg",40),S(8,"path",41),s()(),L(),o(9,"div",42),N(10,si,2,2,null,null,Qe),s()()()),t&2){let e=c().$implicit;a(3),b("innerHTML",j(4,2,e.groupToolName),G),a(3),T(e.text),a(4),H(e.groupItems)}}function ri(t,r){t&1&&(o(0,"span",58),S(1,"span",63),o(2,"span",64),d(3,"running"),s()())}function li(t,r){if(t&1){let e=k();o(0,"button",65),f("click",function(n){u(e);let l=c(2).$implicit;return c().handleOpenInfoPopup(l.groupItems[0]),C(n.stopPropagation())}),o(1,"span",66),d(2,"i"),s()()}}function di(t,r){if(t&1){let e=k();o(0,"details",67),f("click",function(n){return u(e),C(n.stopPropagation())}),o(1,"summary",68),M(),o(2,"svg",69),S(3,"path",41),s(),L(),o(4,"span",70),d(5),s()(),o(6,"div",71)(7,"pre",72),d(8),s()()()}if(t&2){let e=c(2).$implicit;a(5),T(e.groupItems[0].pairedResult.text),a(3),T(e.groupItems[0].pairedResult.expandableContent||e.groupItems[0].pairedResult.text)}}function ci(t,r){if(t&1&&Ne(0,73),t&2){let e=c().$implicit;c(3);let i=xe(2);b("ngTemplateOutlet",i)("ngTemplateOutletContext",He(2,Kt,e))}}function pi(t,r){if(t&1&&g(0,ci,1,4,"ng-container",73),t&2){let e=r.$index;_(e>0?0:-1)}}function _i(t,r){if(t&1&&(o(0,"div",21)(1,"details",47)(2,"summary",48),M(),o(3,"svg",49),S(4,"rect",50)(5,"circle",51)(6,"circle",52)(7,"path",53)(8,"path",54),s(),L(),o(9,"span",55),d(10,"Sub-agent"),s(),o(11,"span",56),d(12),s(),o(13,"span",57),d(14),s(),g(15,ri,4,0,"span",58)(16,li,3,0,"button",59),M(),o(17,"svg",60),S(18,"path",41),s()(),g(19,di,9,2,"details",61),L(),o(20,"div",62),N(21,pi,1,1,null,null,Qe),s()()()),t&2){let e,i=c().$implicit;a(12),T(i.text),a(2),T(((e=i.groupItems==null?null:i.groupItems.length)!==null&&e!==void 0?e:0)>1?i.groupItems.length-1:0),a(),_(!(i.groupItems==null||i.groupItems[0]==null)&&i.groupItems[0].pairedResult?-1:15),a(),_(!(i.groupItems==null||i.groupItems[0]==null)&&i.groupItems[0].rawData?16:-1),a(3),_(!(i.groupItems==null||i.groupItems[0]==null)&&i.groupItems[0].pairedResult?19:-1),a(2),H(i.groupItems)}}function mi(t,r){if(t&1){let e=k();o(0,"button",78),f("click",function(){u(e);let n=c(2).$implicit,l=c();return C(l.handleOpenInfoPopup(n))}),o(1,"span",79),d(2,"i"),s()()}}function ui(t,r){if(t&1&&(o(0,"div",22)(1,"div",74),S(2,"span",75),o(3,"span",76),d(4),s(),g(5,mi,3,0,"button",77),s()()),t&2){let e=c().$implicit;a(4),T(e.text),a(),_(e.rawData?5:-1)}}function Ci(t,r){t&1&&(o(0,"span",83),d(1,"Run intent: "),s())}function fi(t,r){if(t&1&&(o(0,"div",23)(1,"div",80),S(2,"span",81),o(3,"span",82),g(4,Ci,2,0,"span",83),d(5),s()()()),t&2){let e=c().$implicit;a(4),_(e.isLatestMessage?-1:4),a(),D(" ",e.text," ")}}function xi(t,r){if(t&1&&(o(0,"div",20)(1,"div",84),S(2,"span",85),o(3,"span",86),d(4),s()()()),t&2){let e=c().$implicit;a(4),T(e.text)}}function hi(t,r){if(t&1){let e=k();o(0,"button",98),f("click",function(n){u(e);let l=c(2).$implicit;return c().handleOpenInfoPopup(l),C(n.stopPropagation())}),o(1,"span",99),d(2,"i"),s()()}}function gi(t,r){if(t&1&&(o(0,"div",24)(1,"details",87)(2,"summary",88),M(),o(3,"svg",89),S(4,"circle",90)(5,"path",91)(6,"circle",92),s(),L(),o(7,"span",93),d(8,"Thinking"),s(),o(9,"span",94),d(10),s(),g(11,hi,3,0,"button",95),s(),o(12,"div",96)(13,"pre",97),d(14),s()()()()),t&2){let e=c().$implicit;a(10),T(e.text),a(),_(e.rawData?11:-1),a(3),T(e.text)}}function Si(t,r){if(t&1){let e=k();o(0,"button",104),f("click",function(){u(e);let n=c(2).$implicit,l=c();return C(l.handleOpenInfoPopup(n))}),o(1,"span",105),d(2,"i"),s()()}}function bi(t,r){if(t&1&&(o(0,"div",25)(1,"div",100),S(2,"span",101),o(3,"span",102),d(4),s(),g(5,Si,3,0,"button",103),s()()),t&2){let e=c().$implicit;a(4),T(e.text),a(),_(e.rawData?5:-1)}}function vi(t,r){if(t&1&&(o(0,"span",110),d(1),s()),t&2){let e=c(2).$implicit;a(),T(e.subtype)}}function wi(t,r){if(t&1){let e=k();o(0,"button",112),f("click",function(){u(e);let n=c(2).$implicit,l=c();return C(l.handleOpenInfoPopup(n))}),o(1,"span",113),d(2,"i"),s()()}}function yi(t,r){if(t&1&&(o(0,"div",26)(1,"div",106),M(),o(2,"svg",107),S(3,"path",108),s(),L(),o(4,"span",109),d(5),s(),g(6,vi,2,1,"span",110)(7,wi,3,0,"button",111),s()()),t&2){let e=c().$implicit;a(5),T(e.text),a(),_(e.subtype?6:-1),a(),_(e.rawData?7:-1)}}function Ti(t,r){if(t&1){let e=k();o(0,"button",121),f("click",function(){u(e);let n=c(2).$implicit,l=c();return C(l.handleOpenInfoPopup(n))}),o(1,"span",122),d(2,"i"),s()()}}function ki(t,r){if(t&1&&(S(0,"pre",120),F(1,"ccSessionJsonFormat")),t&2){let e=c(2).$implicit;b("innerHTML",j(1,1,e.rawData),G)}}function Ii(t,r){if(t&1&&(o(0,"div",24)(1,"div",114)(2,"div",115),S(3,"span",116),o(4,"span",117),d(5),s(),o(6,"span",118),d(7,"needs brief"),s(),g(8,Ti,3,0,"button",119),s(),g(9,ki,2,3,"pre",120),s()()),t&2){let e=c().$implicit;a(5),T(e.text),a(3),_(e.rawData?8:-1),a(),_(e.rawData?9:-1)}}function $i(t,r){if(t&1&&g(0,ni,4,1,"div",20)(1,ai,12,4,"div",20)(2,_i,23,5,"div",21)(3,ui,6,2,"div",22)(4,fi,6,2,"div",23)(5,xi,5,1,"div",20)(6,gi,15,3,"div",24)(7,bi,6,2,"div",25)(8,yi,8,3,"div",26)(9,Ii,10,3,"div",24),t&2){let e,i=r.$implicit;_((e=i.messageType)==="tool"?0:e==="tool-group"?1:e==="sub-agent-group"?2:e==="result"?3:e==="run-intent"?4:e==="iteration"?5:e==="thinking"?6:e==="status"?7:e==="status-update"?8:e==="raw"?9:-1)}}function Di(t,r){t&1&&(o(0,"div",6)(1,"div",123),M(),o(2,"svg",124),S(3,"path",108),s(),L(),o(4,"span",125),d(5,"Loading older messages..."),s()()())}function Ei(t,r){if(t&1){let e=k();o(0,"div",126)(1,"div",128)(2,"app-s-agent-console-message-bubble",129),f("ttsCached",function(n){u(e);let l=c(2);return C(l.handleTtsCached(n))}),s()()()}if(t&2){let e=c().$implicit;_e("data-prompt-key",e.promptListKey)("data-prompt-text",e.promptText),a(2),b("view",e.promptBubbleView)}}function Mi(t,r){if(t&1){let e=k();o(0,"div",136)(1,"div",137)(2,"app-s-agent-console-message-bubble",129),f("ttsCached",function(n){u(e);let l=c(4);return C(l.handleTtsCached(n))}),s()()()}if(t&2){let e=c().$implicit;me("justify-end",e.messageType==="prompt"),a(),V(e.messageType==="prompt"?"w-[85%]":e.messageType==="tool"||e.messageType==="tool-result"?"w-[90%] ml-4":"w-[90%]"),a(),b("view",e.bubbleView)}}function Pi(t,r){if(t&1&&Ne(0,73),t&2){let e=c().$implicit;c(3);let i=xe(2);b("ngTemplateOutlet",i)("ngTemplateOutletContext",He(2,Kt,e))}}function Ai(t,r){if(t&1&&g(0,Mi,3,5,"div",135)(1,Pi,1,4,"ng-container",73),t&2){let e=r.$implicit;_(e.bubbleView?0:1)}}function Oi(t,r){if(t&1&&(o(0,"details",127)(1,"summary",130),M(),o(2,"svg",131),S(3,"path",41),s(),L(),o(4,"span",132),d(5),s(),S(6,"div",133),s(),o(7,"div",134),N(8,Ai,2,1,null,null,Qe),s()()),t&2){let e=c().$implicit;a(5),D("",e.items.length," events"),a(3),H(e.items)}}function Ri(t,r){if(t&1&&g(0,Ei,3,3,"div",126)(1,Oi,10,1,"details",127),t&2){let e=r.$implicit;_(e.promptBubbleView?0:-1),a(),_(e.items.length?1:-1)}}function Vi(t,r){t&1&&(o(0,"div",138)(1,"div",140),S(2,"div",141),s(),o(3,"div",142),S(4,"div",143),s(),o(5,"div",140),S(6,"div",144),s(),o(7,"div",145),M(),o(8,"svg",146),S(9,"path",108),s(),L(),o(10,"span",147),d(11,"Loading chat history\u2026"),s()()())}function Li(t,r){t&1&&(o(0,"div",139)(1,"span",148),d(2,"\u{1F4AC}"),s(),o(3,"span",149),d(4,"Send a prompt to start the conversation"),s()())}function Fi(t,r){if(t&1&&g(0,Vi,12,0,"div",138)(1,Li,5,0,"div",139),t&2){let e=c();_(e.ccSession_DS.assembledMessagesLoaded_$()?1:0)}}function Ui(t,r){t&1&&(M(),o(0,"svg",153),S(1,"path",154),s(),L(),o(2,"span"),d(3,"Copied!"),s())}function ji(t,r){t&1&&(M(),o(0,"svg",155),S(1,"path",156),s(),L(),o(2,"span"),d(3,"Copy last 30 events"),s())}function zi(t,r){t&1&&(M(),o(0,"svg",153),S(1,"path",154),s(),L(),o(2,"span"),d(3,"Copied!"),s())}function Bi(t,r){t&1&&(M(),o(0,"svg",155),S(1,"rect",157)(2,"path",158),s(),L(),o(3,"span"),d(4,"Copy JSON"),s())}function Wi(t,r){if(t&1&&(o(0,"section")(1,"div",159),d(2,"Primary (message / tool call)"),s(),o(3,"pre",160),d(4),s()()),t&2){let e=c();a(4),T(e.primaryJson)}}function Ni(t,r){if(t&1&&(o(0,"div",161)(1,"div",162),d(2),s(),o(3,"pre",160),d(4),s()()),t&2){let e=r.$implicit,i=c(2);a(2),J(" Part ",e.index+1," / ",i.streamParts.length," "),a(2),T(e.json)}}function Hi(t,r){if(t&1&&(o(0,"section")(1,"div",159),d(2,"Stream mirror payloads (each chunk)"),s(),N(3,Ni,5,3,"div",161,Gn),s()),t&2){let e=c();a(3),H(e.streamParts)}}function qi(t,r){if(t&1&&(o(0,"section")(1,"div",159),d(2,"Paired tool result"),s(),o(3,"pre",160),d(4),s()()),t&2){let e=c();a(4),T(e.pairedJson)}}function Ki(t,r){if(t&1){let e=k();o(0,"div",150)(1,"button",151),f("click",function(){u(e);let n=c();return C(n.handleCopyLast30Events())}),g(2,Ui,4,0)(3,ji,4,0),s(),o(4,"button",151),f("click",function(){u(e);let n=c();return C(n.handleCopyInfoPopup())}),g(5,zi,4,0)(6,Bi,5,0),s()(),o(7,"div",152),g(8,Wi,5,1,"section")(9,Hi,5,0,"section")(10,qi,5,1,"section"),s()}if(t&2){let e=r,i=c();a(),V(i.isLast30Copied_$()?"bg-green-500/15 border border-green-500/30 text-green-300":"bg-neutral-800 border border-neutral-700 text-neutral-400 hover:text-neutral-200 hover:border-neutral-600"),a(),_(i.isLast30Copied_$()?2:3),a(2),V(i.isInfoCopied_$()?"bg-green-500/15 border border-green-500/30 text-green-300":"bg-neutral-800 border border-neutral-700 text-neutral-400 hover:text-neutral-200 hover:border-neutral-600"),a(),_(i.isInfoCopied_$()?5:6),a(3),_(e.primaryJson?8:-1),a(),_(e.showStreamBreakdown?9:-1),a(),_(e.pairedJson?10:-1)}}var Qt=(()=>{class t{sessionId=Q("");ccSession_DS=$(W);detailUi_DS=$(K);sessionQueue_DS=$(Rt);voiceInputUi_DS=$(vt);ttsCachedKeys_$=v(new Set);handleTtsCached(e){this.ttsCachedKeys_$.update(i=>new Set([...i,e]))}promptInput_$=v("");isAutoScroll_$=v(!0);isSending_$=v(!1);isExecuting_$=A(()=>this.ccSession_DS.selectedSession_$()?.session?.status==="running");selectedMode_$=v(y.loadSessionMode()||Se.normal);selectedEffort_$=v(y.loadSessionEffort()||re.high);selectedModel_$=v(y.loadSessionModel()||pe.sonnet);modeOptions=[Se.normal,Se.plan];effortOptions=[re.none,re.low,re.mid,re.high];modelOptions=[pe.sonnet,pe.opus,pe.haiku];modelName_$=A(()=>{let e=this.ccSession_DS.selectedSession_$();return e?.session?.activeModel||e?.session?.model||""});usage_$=A(()=>this.ccSession_DS.sessionUsage_$());usageText_$=A(()=>{let e=this.usage_$();if(!e.totalTokens)return"";let i=e.totalTokens>1e3?`${(e.totalTokens/1e3).toFixed(1)}k`:String(e.totalTokens),n=e.costUsd>0?` \xB7 $${e.costUsd.toFixed(4)}`:"";return`${i} tokens${n}`});chatTurns_$=A(()=>{let e=this.ccSession_DS.assembledMessages_$();if(e.length>0)return this.buildTurnsFromAssembledMessages(e);if(!this.ccSession_DS.assembledMessagesLoaded_$())return[];let i=this.ccSession_DS.consoleMessages_$(),n=this.isShowSessionStatus(),l=this.isShowAgentUpdates(),p=this.sessionId(),m=this.ttsCachedKeys_$(),w=[],x=null;for(let h of i)if(!(h.type==="status-update"&&!l))if(h.type==="prompt")x={promptText:h.text,promptListKey:h.listKey,promptBubbleView:{listKey:h.listKey,kind:U.userPrompt,bodyText:h.text,timestampIso:h.timestamp,isUserAligned:!0,flags:{showCopy:!0,showRawInfo:!1,useEditDiffForExpandable:!1},tts:h.text.trim().length>0?{messageKey:h.listKey,sessionId:p,role:"user",content:h.text,timestampIso:h.timestamp,hasTtsAudio:m.has(h.listKey)}:void 0,imageDataUrls:h.imageDataUrls},items:[]},w.push(x);else{x||(x={promptText:"",promptListKey:`__no-prompt-${w.length}`,items:[]},w.push(x));let I={listKey:h.listKey,messageType:h.type,text:h.text,isStatus:h.isStatus,expandableContent:h.expandableContent,isLatestMessage:!1,rawData:h.rawData,timestamp:h.timestamp,subtype:h.subtype,parentAgentId:h.parentAgentId};h.type==="tool"&&(I.toolName=this.extractToolNameFromMsg(h),I.toolDescription=this.extractToolDescription(h.rawData)),x.items.push(I)}if(w.length){let h=w[w.length-1];h.items.length&&(h.items[h.items.length-1].isLatestMessage=!0)}if(!n)for(let h of w){let I=-1;for(let E=h.items.length-1;E>=0;E--)if(h.items[E].isStatus){I=E;break}I>=0&&(h.items=h.items.filter((E,B)=>!E.isStatus||B===I))}for(let h of w)h.items=this.pairToolCallsWithResults(h.items);for(let h of w)h.items=this.groupSubAgentItems(h.items);for(let h of w)h.items=this.groupConsecutiveToolItems(h.items);for(let h of w)h.items=h.items.map(I=>{if(!(I.messageType==="assistant"||I.messageType==="error"||I.messageType==="tool-result"||I.messageType==="info"))return I;let B=be.fromDisplayItem(I);return I.messageType==="assistant"&&I.text.trim().length>0&&(B.tts={messageKey:I.listKey,sessionId:p,role:"assistant",content:I.text,timestampIso:I.timestamp??new Date().toISOString(),hasTtsAudio:m.has(I.listKey)}),We(Be({},I),{bubbleView:B})});return w});stickyPromptInfo_$=v(null);lastPromptText_$=A(()=>this.stickyPromptInfo_$()?.promptText??"");isShowSessionStatus=Q(!1);isShowAgentUpdates=Q(!0);isShowStickyPrompt_$=v(!1);isInfoPopupOpen_$=v(!1);infoPopupBundle_$=v(null);infoPopupTitle_$=v("");isInfoCopied_$=v(!1);isLast30Copied_$=v(!1);chatScrollRef;sessionInputRef;pendingAttachments_$=v([]);previousItemCount=0;constructor(){ke(()=>{let e=this.sessionId();if(e){let i=y.loadPromptDraft(e);this.promptInput_$.set(i),this.sessionQueue_DS.subscribeToSession({sessionId:e,baseRoute:"cc-session"})}},{allowSignalWrites:!0})}ngOnDestroy(){this.sessionQueue_DS.unsubscribe()}ngAfterViewChecked(){let e=this.ccSession_DS.assembledMessages_$(),i=this.ccSession_DS.consoleMessages_$(),n=e.length+i.length;this.isAutoScroll_$()&&n>this.previousItemCount&&this.scrollToBottom(),this.previousItemCount=n}handleSendPrompt(){return R(this,null,function*(){let e=this.promptInput_$().trim(),i=this.pendingAttachments_$();if(!e&&!i.length||this.isSending_$())return;let n=this.sessionId();if(n){this.isSending_$.set(!0),y.clearPromptDraft(n);try{yield this.ccSession_DS.sendPrompt({sessionId:n,content:e,attachments:i.length>0?i:void 0}),this.promptInput_$.set(""),this.sessionInputRef?.clearAttachments()}catch{y.savePromptDraft(n,e)}finally{this.isSending_$.set(!1)}}})}handleAttachmentsChanged(e){this.pendingAttachments_$.set(e)}handlePromptInputChange(e){this.promptInput_$.set(e);let i=this.sessionId();i&&y.savePromptDraft(i,e)}handleQuickCastAction(e){return R(this,null,function*(){let i=e.trim(),n=this.sessionId();if(!(!i||!n||this.isSending_$())){this.isSending_$.set(!0);try{yield this.ccSession_DS.sendPrompt({sessionId:n,content:i})}finally{this.isSending_$.set(!1)}}})}handleVoiceSegment(e){let i=e.text.trim();if(!i.length)return;let n=this.promptInput_$().trim(),l=n.length>0?`${n} ${i}`:i;this.handlePromptInputChange(l),this.voiceInputUi_DS.autoSendAfterVoice_$()&&e.isFinal&&this.handleSendPrompt()}handleRestartRunnerClicked(){let e=this.sessionId().trim();e&&this.ccSession_DS.restartRunner({sessionId:e})}handlePlanAccepted(){let e=this.sessionId();e&&this.ccSession_DS.sendPrompt({sessionId:e,content:"plan approved, proceed"}).catch(i=>{te.DyFM_Log.error("[CCAP] cc-console plan-accept send",i)})}handleKeydown(e){e.key==="Enter"&&!e.shiftKey&&(e.preventDefault(),this.handleSendPrompt())}handleSelectMode(e){this.selectedMode_$.set(e),y.saveSessionMode(e);let i=this.sessionId();i&&this.ccSession_DS.updateSessionConfig({sessionId:i,mode:e}).catch(n=>{te.DyFM_Log.error("[CCAP] cc-session-console config-update mode",n)})}handleSelectEffort(e){this.selectedEffort_$.set(e),y.saveSessionEffort(e);let i=this.sessionId();i&&this.ccSession_DS.updateSessionConfig({sessionId:i,reasoningEffort:e}).catch(n=>{te.DyFM_Log.error("[CCAP] cc-session-console config-update effort",n)})}handleSelectModel(e){this.selectedModel_$.set(e),y.saveSessionModel(e);let i=this.sessionId();i&&this.ccSession_DS.updateSessionConfig({sessionId:i,model:e}).catch(n=>{te.DyFM_Log.error("[CCAP] cc-session-console config-update model",n)})}handleChatScroll(){let e=this.chatScrollRef?.nativeElement;if(!e)return;this.updateStickyPrompt(e);let i=e.scrollHeight-e.scrollTop-e.clientHeight<60;this.isAutoScroll_$.set(i),e.scrollTop<40&&this.ccSession_DS.assembledMessagesHasMore_$()&&this.loadOlderMessages(e)}updateStickyPrompt(e){if(!(e.scrollTop>80)){this.isShowStickyPrompt_$.set(!1),this.stickyPromptInfo_$.set(null);return}let l=e.getBoundingClientRect().top+50,p=e.querySelectorAll("[data-prompt-key]"),m=this.isShowStickyPrompt_$(),w=l-8,x=l+24,h=null;for(let I=p.length-1;I>=0;I--){let E=p[I],B=E.getBoundingClientRect(),ne=m?x:w;if(B.bottom<ne){let Z=E.getAttribute("data-prompt-key")??"",ee=E.getAttribute("data-prompt-text")??"";Z&&ee&&(h={promptListKey:Z,promptText:ee});break}}this.stickyPromptInfo_$.set(h),this.isShowStickyPrompt_$.set(!!h)}handleStickyPromptClick(){let e=this.stickyPromptInfo_$();if(!e)return;let i=this.chatScrollRef?.nativeElement;if(!i)return;let n=i.querySelector(`[data-prompt-key="${e.promptListKey}"]`);if(!n)return;let l=i.getBoundingClientRect(),p=n.getBoundingClientRect(),m=58;i.scrollTop+=p.top-l.top-m}loadOlderMessages(e){return R(this,null,function*(){let i=this.sessionId();if(!i)return;let n=e.scrollHeight;yield this.ccSession_DS.loadOlderAssembledMessages({sessionId:i}),requestAnimationFrame(()=>{let l=e.scrollHeight;e.scrollTop=l-n,requestAnimationFrame(()=>{this.updateStickyPrompt(e)})})})}handleOpenInfoPopup(e){Ke.ccItemHasAnyRaw(e)&&(this.infoPopupTitle_$.set(e.messageType),this.infoPopupBundle_$.set(Ke.buildForCcConsoleItem(e)),this.isInfoPopupOpen_$.set(!0))}handleOpenPairedResultInfo(e){this.handleOpenInfoPopup(e)}handleCloseInfoPopup(){this.isInfoPopupOpen_$.set(!1),this.infoPopupBundle_$.set(null),this.isInfoCopied_$.set(!1),this.isLast30Copied_$.set(!1)}handleCopyInfoPopup(){let e=this.infoPopupBundle_$();e&&navigator.clipboard.writeText(e.copyJsonString).then(()=>{this.isInfoCopied_$.set(!0),setTimeout(()=>{this.isInfoCopied_$.set(!1)},2e3)}).catch(i=>{te.DyFM_Log.error("[CCAP] cc-session-console clipboard-copy",i)})}handleCopyLast30Events(){let i=this.ccSession_DS.assembledMessages_$().slice(-30),n=JSON.stringify(i,null,2);navigator.clipboard.writeText(n).then(()=>{this.isLast30Copied_$.set(!0),setTimeout(()=>{this.isLast30Copied_$.set(!1)},2e3)}).catch(l=>{te.DyFM_Log.error("[CCAP] cc-session-console clipboard-copy-last30",l)})}pairToolCallsWithResults(e){let i=new Map;for(let l=0;l<e.length;l++){let p=e[l];if(p.messageType==="tool"&&p.rawData){let m=typeof p.rawData.id=="string"?p.rawData.id:"";m&&i.set(m,l)}}if(!i.size)return e;let n=new Set;for(let l=0;l<e.length;l++){let p=e[l];if(p.messageType==="tool-result"&&p.rawData){let m=typeof p.rawData.tool_use_id=="string"?p.rawData.tool_use_id:"",w=m?i.get(m):void 0;w!==void 0&&(e[w].pairedResult={text:p.text,expandableContent:p.expandableContent,rawData:p.rawData},n.add(l))}}return n.size?e.filter((l,p)=>!n.has(p)):e}extractToolNameFromMsg(e){if(e.rawData){let n=e.rawData.name??e.rawData.tool_name??e.rawData.last_tool_name;if(typeof n=="string")return n}let i=e.text.indexOf(":");return i>0?e.text.substring(0,i).trim():e.text.trim()}extractToolDescription(e){if(!e)return;let i=e.input;if(!i||typeof i!="object")return;let n=i.description;return typeof n=="string"?n:void 0}extractToolName(e){if(e.toolName)return e.toolName;if(e.rawData){let n=e.rawData.name??e.rawData.tool_name??e.rawData.last_tool_name;if(typeof n=="string")return n}let i=e.text.indexOf(":");return i>0?e.text.substring(0,i).trim():e.text.trim()}groupSubAgentItems(e){let i=new Map;for(let m=0;m<e.length;m++){let w=e[m];if(w.messageType==="tool"&&w.toolName==="Agent"&&w.rawData){let x=typeof w.rawData.id=="string"?w.rawData.id:"";x&&i.set(x,{item:w,index:m})}}if(!i.size)return e;let n=new Map,l=new Set;for(let m=0;m<e.length;m++){let w=e[m];if(w.parentAgentId&&(l.add(m),i.has(w.parentAgentId))){let x=n.get(w.parentAgentId)??[];x.push(w),n.set(w.parentAgentId,x)}}let p=[];for(let m=0;m<e.length;m++){if(l.has(m))continue;let w=e[m];if(w.messageType==="tool"&&w.toolName==="Agent"&&w.rawData){let x=typeof w.rawData.id=="string"?w.rawData.id:"",h=n.get(x)??[],I=[w,...h],E=w.rawData?.input,B=E&&typeof E=="object"&&typeof E.subagent_type=="string"?E.subagent_type:"",ne=E&&typeof E=="object"&&typeof E.description=="string"?E.description:"",Z=B?`${B}: ${ne||"..."}`:ne||"Sub-agent",ee=this.groupConsecutiveToolItems(I);p.push({listKey:w.listKey,messageType:"sub-agent-group",text:Z,isStatus:!1,isLatestMessage:!1,groupItems:ee,groupToolName:B||"Agent"})}else p.push(w)}return p}buildTurnsFromAssembledMessages(e){let i=this.isShowAgentUpdates(),n=this.isShowSessionStatus(),l=this.sessionId(),p=this.ttsCachedKeys_$(),m=[],w=null;for(let x of e){let h=x.messageRole==="status-update"&&x.subtype==="task_progress"&&!!x.rawData?.last_tool_name;if(!(x.messageRole==="status-update"&&!i&&!h))if(x.messageRole==="user"&&x.isUserAligned===!0)w={promptText:x.bodyText,promptListKey:x.messageKey,promptBubbleView:{listKey:x.messageKey,kind:U.userPrompt,bodyText:x.bodyText,timestampIso:x.timestamp,isUserAligned:!0,rawData:x.rawData,flags:{showCopy:!0,showRawInfo:!!x.rawData,useEditDiffForExpandable:!1},tts:x.bodyText.trim().length>0?{messageKey:x.messageKey,sessionId:l,role:"user",content:x.bodyText,timestampIso:x.timestamp,hasTtsAudio:p.has(x.messageKey)}:void 0},items:[]},m.push(w);else{w||(w={promptText:"",promptListKey:`__no-prompt-${m.length}`,items:[]},m.push(w));let I=x.rawData&&typeof x.rawData.last_tool_name=="string"?x.rawData.last_tool_name:"",E=x.messageRole==="status-update"&&x.subtype==="task_progress"&&!!I,B=E?"tool":x.messageRole,ne=B==="status"||B==="status-update",Z=t.mapAssembledRoleToMessageType(B),ee={listKey:x.messageKey,messageType:Z,text:E?`${I}: ${x.bodyText}`:x.bodyText,isStatus:ne,expandableContent:x.expandableContent,isLatestMessage:!1,rawData:x.rawData,timestamp:x.timestamp,subtype:x.subtype,parentAgentId:x.parentAgentId,toolName:x.toolName||(E?I:void 0),toolDescription:Z==="tool"?this.extractToolDescription(x.rawData):void 0};x.toolResult&&(ee.pairedResult={text:x.toolResult.text,expandableContent:x.toolResult.expandableContent,rawData:x.toolResult.rawData,isError:x.toolResult.isError}),w.items.push(ee)}}if(m.length){let x=m[m.length-1];x.items.length&&(x.items[x.items.length-1].isLatestMessage=!0)}if(!n)for(let x of m){let h=-1;for(let I=x.items.length-1;I>=0;I--)if(x.items[I].isStatus){h=I;break}h>=0&&(x.items=x.items.filter((I,E)=>!I.isStatus||E===h))}for(let x of m)x.items=this.groupSubAgentItems(x.items);for(let x of m)x.items=this.groupConsecutiveToolItems(x.items);for(let x of m)x.items=x.items.map(h=>{if(!(h.messageType==="assistant"||h.messageType==="error"||h.messageType==="tool-result"||h.messageType==="info"))return h;let E=be.fromDisplayItem(h);return h.messageType==="assistant"&&h.text.trim().length>0&&(E.tts={messageKey:h.listKey,sessionId:l,role:"assistant",content:h.text,timestampIso:h.timestamp??new Date().toISOString(),hasTtsAudio:p.has(h.listKey)}),We(Be({},h),{bubbleView:E})});return m}groupConsecutiveToolItems(e){let i=[],n=[],l="",p=()=>{if(!n.length)return;let m=n.filter(w=>w.messageType==="tool").length;m>=2?i.push({listKey:n[0].listKey,messageType:"tool-group",text:`${l} \xD7 ${m}`,isStatus:!1,isLatestMessage:!1,groupItems:n,groupToolName:l}):i.push(...n),n=[],l=""};for(let m of e){if(m.messageType==="tool"){let w=this.extractToolName(m);l&&l!==w&&p(),l=w,n.push(m);continue}if(m.messageType==="tool-result"&&n.length){n.push(m);continue}p(),i.push(m)}return p(),i}static mapAssembledRoleToMessageType(e){switch(e){case"user":return"prompt";case"assistant":return"assistant";case"tool":return"tool";case"tool-result":return"tool-result";case"status":return"status";case"error":return"error";case"info":return"info";case"result":return"result";case"thinking":return"thinking";case"status-update":return"status-update";default:return"info"}}scrollToBottom(){let e=this.chatScrollRef?.nativeElement;e&&(e.scrollTop=e.scrollHeight)}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=z({type:t,selectors:[["app-ccap-cc-console"]],viewQuery:function(i,n){if(i&1&&(ue(qn,5),ue(Kn,5)),i&2){let l;Ce(l=fe())&&(n.chatScrollRef=l.first),Ce(l=fe())&&(n.sessionInputRef=l.first)}},hostAttrs:[1,"flex","flex-col","flex-1","min-h-0","overflow-hidden"],inputs:{sessionId:[1,"sessionId"],isShowSessionStatus:[1,"isShowSessionStatus"],isShowAgentUpdates:[1,"isShowAgentUpdates"]},decls:20,vars:28,consts:[["itemRenderer",""],["chatScroll",""],["sessionInput",""],[1,"sticky","top-0","z-10","px-4","py-2","bg-ccapBg/95","backdrop-blur-sm","border-b","border-neonCyan/20","shrink-0","cursor-pointer","hover:bg-ccapBg/80","transition-colors","group/sticky"],[1,"relative","flex-1","flex","flex-col","min-h-0"],[1,"flex-1","overflow-y-auto","min-h-0","px-3","py-3",3,"scroll"],[1,"flex","justify-center","py-3"],[3,"sessionId"],[3,"actionSelected"],[3,"restartRunnerClicked","sessionId","showRestartRunner"],[1,"absolute","bottom-4","right-4","z-30","pointer-events-auto"],[3,"transcriptSegmentReady","compactLayout"],["placeholder","Type a message... (Enter to send)",3,"draftTextChange","attachmentsChanged","sendRequested","queueRequested","stopRequested","modeChanged","modelChanged","effortChanged","queueEditStart","queueEditTextChange","queueEditSave","queueEditCancel","queueRemoveItem","queueSendNow","queueMoveUp","queueMoveDown","draftText","isExecuting","isSending","isStopping","enableAttachments","modeOptions","selectedMode","modelOptions","selectedModel","effortOptions","selectedEffort","usageText","textareaRows","queueItems","isQueueLocked","editingQueueItemId","editingQueueText"],["maxWidth","4xl","headerBorderClass","border-neonCyan/30",3,"closed","isOpen","title"],[1,"sticky","top-0","z-10","px-4","py-2","bg-ccapBg/95","backdrop-blur-sm","border-b","border-neonCyan/20","shrink-0","cursor-pointer","hover:bg-ccapBg/80","transition-colors","group/sticky",3,"click"],[1,"flex","items-start","gap-2"],[1,"text-[10px]","text-neonCyan/70","font-medium","mt-0.5","shrink-0"],[1,"text-xs","text-neonCyan/90","line-clamp-2","leading-relaxed","group-hover/sticky:text-neonCyan"],["viewBox","0 0 12 12","fill","none","stroke","currentColor","stroke-width","1.5","stroke-linecap","round","stroke-linejoin","round",1,"w-3","h-3","text-neonCyan/40","shrink-0","mt-0.5","group-hover/sticky:text-neonCyan/70","transition-colors"],["d","M6 9V3M3 5.5L6 3l3 2.5"],[1,"flex","justify-start","mb-1.5"],[1,"mb-2"],[1,"flex","justify-start","mb-2","group/msg"],[1,"flex","justify-start","mb-2"],[1,"flex","justify-start","mb-1.5","group/msg"],[1,"flex","justify-center","mb-1.5"],[1,"flex","justify-center","mb-1","group/msg"],[1,"bg-orange-500/5","border","border-orange-500/15","rounded-lg","max-w-[90%]","overflow-hidden"],["layout","full","density","comfortable",3,"toolName","summaryText","toolDescription","isPathRtl","showToolRawInfo","expandableContent","pairedResult"],[1,"flex","items-center","gap-1.5","px-2.5","py-1","border-b","border-orange-500/10"],[1,"text-orange-400","shrink-0","flex","items-center",3,"innerHTML"],[1,"text-[11px]","text-orange-300/90","font-medium"],[1,"ml-auto","shrink-0","w-4","h-4","rounded-full","bg-orange-500/20","border","border-orange-500/30","flex","items-center","justify-center","cursor-pointer","hover:bg-orange-500/40"],[3,"rawData"],[1,"ml-auto","shrink-0","w-4","h-4","rounded-full","bg-orange-500/20","border","border-orange-500/30","flex","items-center","justify-center","cursor-pointer","hover:bg-orange-500/40",3,"click"],[1,"text-[8px]","text-orange-300","font-bold","leading-none"],[3,"accepted","rawData"],["layout","full","density","comfortable",3,"toolRawInfoClick","pairedRawInfoClick","toolName","summaryText","toolDescription","isPathRtl","showToolRawInfo","expandableContent","pairedResult"],["open","",1,"bg-orange-500/5","border","border-orange-500/15","rounded-lg","max-w-[90%]","overflow-hidden"],[1,"flex","items-center","gap-1.5","px-2.5","py-1","cursor-pointer","select-none","hover:bg-orange-500/8","transition-colors"],["viewBox","0 0 12 12","fill","none",1,"w-3","h-3","text-orange-400/50","ml-1","transition-transform","[details[open]>&]:rotate-90"],["d","M4.5 2.5l4 3.5-4 3.5","stroke","currentColor","stroke-width","1.5","stroke-linecap","round","stroke-linejoin","round"],[1,"px-2","pb-1.5","pt-0.5","space-y-0.5"],["layout","nested","density","compact",3,"toolName","summaryText","toolDescription","isPathRtl","showToolRawInfo","expandableContent","pairedResult"],[1,"pl-5","mb-0.5"],["layout","nested","density","compact",3,"toolRawInfoClick","pairedRawInfoClick","toolName","summaryText","toolDescription","isPathRtl","showToolRawInfo","expandableContent","pairedResult"],[1,"text-[10px]","text-neutral-500","line-clamp-1"],[1,"border","border-indigo-500/20","rounded-lg","overflow-hidden","bg-indigo-500/3"],[1,"flex","items-center","gap-1.5","px-2.5","py-1.5","cursor-pointer","select-none","hover:bg-indigo-500/8","transition-colors","list-none","[&::-webkit-details-marker]:hidden","group/sah"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","1.5","stroke-linecap","round","stroke-linejoin","round",1,"w-3.5","h-3.5","text-indigo-400","shrink-0"],["x","3","y","5","width","10","height","8","rx","2"],["cx","6","cy","9","r","1"],["cx","10","cy","9","r","1"],["d","M8 2v3"],["d","M6 2h4"],[1,"text-[10px]","text-indigo-400/60","font-medium","uppercase","tracking-wider","shrink-0"],[1,"text-[11px]","text-indigo-300/90","font-medium","truncate"],[1,"text-[9px]","text-indigo-400/40","shrink-0"],["title","Sub-agent in progress \u2014 m\xE9g nincs eredm\xE9ny",1,"flex","items-center","gap-1","text-[10px]","text-amber-300/90","shrink-0"],[1,"shrink-0","w-4","h-4","rounded-full","bg-indigo-500/20","border","border-indigo-500/30","flex","items-center","justify-center","cursor-pointer","hover:bg-indigo-500/40"],["viewBox","0 0 12 12","fill","none",1,"w-3","h-3","text-indigo-400/40","ml-auto","shrink-0","transition-transform","[[open]>&]:rotate-90"],[1,"border-t","border-indigo-500/10"],[1,"px-2","pb-2","pt-1","space-y-0.5","border-t","border-indigo-500/10"],["aria-hidden","true",1,"inline-block","w-2","h-2","animate-spin","rounded-full","border","border-amber-400/60","border-t-amber-200"],[1,"uppercase","tracking-wider"],[1,"shrink-0","w-4","h-4","rounded-full","bg-indigo-500/20","border","border-indigo-500/30","flex","items-center","justify-center","cursor-pointer","hover:bg-indigo-500/40",3,"click"],[1,"text-[8px]","text-indigo-300","font-bold","leading-none"],[1,"border-t","border-indigo-500/10",3,"click"],[1,"flex","items-center","gap-1","px-2.5","py-1","bg-indigo-500/5","cursor-pointer","select-none","hover:bg-indigo-500/8","transition-colors","list-none","[&::-webkit-details-marker]:hidden"],["viewBox","0 0 12 12","fill","none",1,"w-2.5","h-2.5","text-indigo-400/40","shrink-0","transition-transform","[[open]>&]:rotate-90"],[1,"text-[10px]","text-indigo-300/40","truncate","leading-relaxed"],[1,"px-2.5","py-1.5","bg-indigo-500/5","border-t","border-indigo-500/8"],[1,"text-[10px]","text-indigo-200/40","whitespace-pre-wrap","break-words","max-h-[200px]","overflow-y-auto","overflow-x-auto","leading-relaxed"],[3,"ngTemplateOutlet","ngTemplateOutletContext"],[1,"inline-flex","items-center","gap-1.5","bg-green-500/8","border","border-green-500/20","rounded-lg","px-2.5","py-1"],[1,"w-1.5","h-1.5","rounded-full","bg-green-400","shrink-0"],[1,"text-[11px]","text-green-300/90","break-words","min-w-0"],[1,"ml-1","w-4","h-4","rounded-full","bg-green-500/20","border","border-green-500/30","flex","items-center","justify-center","cursor-pointer","hover:bg-green-500/40"],[1,"ml-1","w-4","h-4","rounded-full","bg-green-500/20","border","border-green-500/30","flex","items-center","justify-center","cursor-pointer","hover:bg-green-500/40",3,"click"],[1,"text-[8px]","text-green-300","font-bold","leading-none"],[1,"inline-flex","items-start","gap-1.5","bg-blue-500/8","border","border-blue-500/20","rounded-lg","px-2.5","py-1.5","max-w-[90%]"],[1,"w-1.5","h-1.5","rounded-full","bg-blue-400","shrink-0","mt-0.5"],[1,"text-[11px]","text-blue-300/90","leading-relaxed","min-w-0","break-words"],[1,"text-blue-400/60","font-medium"],[1,"inline-flex","items-center","gap-1.5","bg-violet-500/8","border","border-violet-500/20","rounded-lg","px-2.5","py-1"],[1,"w-1.5","h-1.5","rounded-full","bg-violet-400","shrink-0"],[1,"text-[11px]","text-violet-300/90","truncate","max-w-[80%]"],[1,"bg-sky-500/5","border","border-sky-500/15","rounded-lg","max-w-[90%]","overflow-hidden"],[1,"flex","items-center","gap-1.5","px-2.5","py-1","cursor-pointer","select-none","hover:bg-sky-500/8","transition-colors"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","1.5","stroke-linecap","round","stroke-linejoin","round",1,"w-3.5","h-3.5","text-sky-400","shrink-0"],["cx","8","cy","8","r","6"],["d","M6 6.5a2 2 0 0 1 3.5 1.5c0 1-1.5 1.5-1.5 1.5"],["cx","8","cy","12","r","0.5","fill","currentColor"],[1,"text-[11px]","text-sky-300/80","font-medium"],[1,"text-[10px]","text-sky-400/40","ml-1","truncate","min-w-0"],[1,"ml-auto","shrink-0","w-3.5","h-3.5","rounded-full","bg-sky-500/15","flex","items-center","justify-center","cursor-pointer","hover:bg-sky-500/30"],[1,"px-2.5","pb-2","pt-1"],[1,"text-[10px]","text-sky-200/60","whitespace-pre-wrap","break-words","max-h-[200px]","overflow-y-auto","overflow-x-auto","leading-relaxed"],[1,"ml-auto","shrink-0","w-3.5","h-3.5","rounded-full","bg-sky-500/15","flex","items-center","justify-center","cursor-pointer","hover:bg-sky-500/30",3,"click"],[1,"text-[7px]","text-sky-300/60","font-bold","leading-none"],[1,"inline-flex","items-center","gap-1.5","bg-neonPurple/8","border","border-neonPurple/20","rounded-full","px-3","py-0.5"],[1,"w-1","h-1","rounded-full","bg-neonPurple","animate-pulse","shrink-0"],[1,"text-[10px]","text-neonPurple/80","truncate"],[1,"shrink-0","w-3.5","h-3.5","rounded-full","bg-neonPurple/15","flex","items-center","justify-center","cursor-pointer","hover:bg-neonPurple/30"],[1,"shrink-0","w-3.5","h-3.5","rounded-full","bg-neonPurple/15","flex","items-center","justify-center","cursor-pointer","hover:bg-neonPurple/30",3,"click"],[1,"text-[7px]","text-neonPurple/60","font-bold","leading-none"],[1,"inline-flex","items-center","gap-1.5","bg-teal-500/6","border","border-teal-500/15","rounded-full","px-3","py-0.5","max-w-[85%]"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","2",1,"w-3","h-3","text-teal-400/70","shrink-0","animate-spin"],["d","M8 2a6 6 0 0 1 6 6","stroke-linecap","round"],[1,"text-[10px]","text-teal-300/70","truncate"],[1,"text-[8px]","text-teal-400/40","shrink-0"],[1,"shrink-0","w-3.5","h-3.5","rounded-full","bg-teal-500/15","flex","items-center","justify-center","cursor-pointer","hover:bg-teal-500/30"],[1,"shrink-0","w-3.5","h-3.5","rounded-full","bg-teal-500/15","flex","items-center","justify-center","cursor-pointer","hover:bg-teal-500/30",3,"click"],[1,"text-[7px]","text-teal-300/60","font-bold","leading-none"],[1,"bg-neutral-800/60","border","border-amber-500/15","rounded-lg","px-2.5","py-1.5","max-w-[85%]"],[1,"flex","items-center","gap-1.5","mb-1"],[1,"w-1.5","h-1.5","rounded-full","bg-amber-400","shrink-0"],[1,"text-[10px]","text-neutral-400","font-medium","uppercase","tracking-wider"],[1,"text-[8px]","text-amber-500/60","italic","ml-1"],[1,"ml-auto","w-4","h-4","rounded-full","bg-neutral-700/80","border","border-neutral-600/50","flex","items-center","justify-center","cursor-pointer","hover:bg-neutral-600"],[1,"text-[10px]","text-neutral-500","whitespace-pre-wrap","break-words","max-h-[120px]","overflow-y-auto","overflow-x-auto","leading-relaxed",3,"innerHTML"],[1,"ml-auto","w-4","h-4","rounded-full","bg-neutral-700/80","border","border-neutral-600/50","flex","items-center","justify-center","cursor-pointer","hover:bg-neutral-600",3,"click"],[1,"text-[8px]","text-neutral-300","font-bold","leading-none"],[1,"inline-flex","items-center","gap-2","px-3","py-1.5","rounded-full","bg-neutral-800/60","border","border-neutral-700/50"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","2",1,"w-3.5","h-3.5","text-neonCyan/70","animate-spin"],[1,"text-[11px]","text-neutral-400"],[1,"flex","justify-end","mb-3"],["open","",1,"mb-3"],[1,"max-w-[85%]","min-w-0"],[3,"ttsCached","view"],[1,"flex","items-center","gap-1.5","mb-1.5","cursor-pointer","select-none","list-none","[&::-webkit-details-marker]:hidden","group/sum"],["viewBox","0 0 12 12","fill","none",1,"w-3","h-3","text-neutral-600","shrink-0","transition-transform","[[open]>&]:rotate-90"],[1,"text-[10px]","text-neutral-600","group-hover/sum:text-neutral-400","transition-colors"],[1,"flex-1","h-px","bg-neutral-800","ml-1"],[1,"pl-1"],[1,"flex","mb-2","w-full","min-w-0",3,"justify-end"],[1,"flex","mb-2","w-full","min-w-0"],[1,"min-w-0"],["aria-label","Chat history bet\xF6lt\xE9se folyamatban",1,"flex","flex-col","gap-3","px-2","py-4"],[1,"flex","flex-col","items-center","justify-center","h-full","text-neutral-500","gap-2"],[1,"flex","justify-end"],[1,"w-[60%]","max-w-[420px]","h-12","rounded-lg","bg-neutral-800/50","animate-pulse"],[1,"flex","justify-start"],[1,"w-[75%]","max-w-[520px]","h-20","rounded-lg","bg-neutral-800/50","animate-pulse"],[1,"w-[55%]","max-w-[380px]","h-10","rounded-lg","bg-neutral-800/50","animate-pulse"],[1,"flex","items-center","justify-center","gap-2","mt-2"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","2",1,"w-3","h-3","text-neonCyan/70","animate-spin"],[1,"text-[10px]","text-neutral-500"],[1,"text-2xl"],[1,"text-xs"],[1,"flex","justify-end","gap-2","mb-2"],[1,"inline-flex","items-center","gap-1.5","px-2.5","py-1","rounded-md","text-[11px]","transition-colors","cursor-pointer",3,"click"],[1,"space-y-4","max-h-[60vh]","overflow-y-auto","p-1"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","2","stroke-linecap","round","stroke-linejoin","round",1,"w-3.5","h-3.5"],["d","M3 8.5l3 3 7-7"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","1.5","stroke-linecap","round","stroke-linejoin","round",1,"w-3.5","h-3.5"],["d","M2 4h12M2 8h12M2 12h8"],["x","5","y","5","width","9","height","9","rx","1.5"],["d","M3 11V3a1.5 1.5 0 0 1 1.5-1.5H11"],[1,"text-[9px]","text-neutral-500","uppercase","tracking-wide","mb-1"],[1,"text-xs","leading-relaxed","whitespace-pre-wrap","break-words","overflow-x-auto","font-mono","text-neutral-300"],[1,"mb-3","last:mb-0"],[1,"text-[8px]","text-neutral-600","mb-0.5"]],template:function(i,n){if(i&1){let l=k();g(0,Jn,8,1,"div",3)(1,$i,10,1,"ng-template",null,0,st),o(3,"div",4)(4,"div",5,1),f("scroll",function(){return u(l),C(n.handleChatScroll())}),g(6,Di,6,0,"div",6),N(7,Ri,2,2,null,null,Qn),g(9,Fi,2,1),s(),S(10,"app-s-session-schedule-overlay",7),o(11,"app-s-session-quickcast-overlay",8),f("actionSelected",function(m){return u(l),C(n.handleQuickCastAction(m))}),s(),S(12,"app-s-session-coordinator-overlay",7),o(13,"app-s-session-quick-settings-overlay",9),f("restartRunnerClicked",function(){return u(l),C(n.handleRestartRunnerClicked())}),s(),o(14,"div",10)(15,"app-ccap-voice-record-button",11),f("transcriptSegmentReady",function(m){return u(l),C(n.handleVoiceSegment(m))}),s()()(),o(16,"app-s-session-input",12,2),f("draftTextChange",function(m){return u(l),C(n.handlePromptInputChange(m))})("attachmentsChanged",function(m){return u(l),C(n.handleAttachmentsChanged(m))})("sendRequested",function(){return u(l),C(n.handleSendPrompt())})("queueRequested",function(){return u(l),C(n.handleSendPrompt())})("stopRequested",function(){return u(l),C(n.detailUi_DS.handleStopExecution())})("modeChanged",function(m){return u(l),C(n.handleSelectMode(m))})("modelChanged",function(m){return u(l),C(n.handleSelectModel(m))})("effortChanged",function(m){return u(l),C(n.handleSelectEffort(m))})("queueEditStart",function(m){return u(l),C(n.sessionQueue_DS.startEditing(m))})("queueEditTextChange",function(m){return u(l),C(n.sessionQueue_DS.editingText_$.set(m))})("queueEditSave",function(){return u(l),C(n.sessionQueue_DS.saveEdit())})("queueEditCancel",function(){return u(l),C(n.sessionQueue_DS.cancelEdit())})("queueRemoveItem",function(m){return u(l),C(n.sessionQueue_DS.removeItem(m))})("queueSendNow",function(m){return u(l),C(n.sessionQueue_DS.sendNow(m))})("queueMoveUp",function(m){return u(l),C(n.sessionQueue_DS.reorderItem({queueItemId:m,direction:"up"}))})("queueMoveDown",function(m){return u(l),C(n.sessionQueue_DS.reorderItem({queueItemId:m,direction:"down"}))}),s(),o(18,"app-s-modal",13),f("closed",function(){return u(l),C(n.handleCloseInfoPopup())}),g(19,Ki,11,9),s()}if(i&2){let l;_(n.isShowStickyPrompt_$()?0:-1),a(6),_(n.ccSession_DS.isLoadingOlderMessages_$()?6:-1),a(),H(n.chatTurns_$()),a(2),_(n.chatTurns_$().length?-1:9),a(),b("sessionId",n.sessionId()),a(2),b("sessionId",n.sessionId()),a(),b("sessionId",n.sessionId())("showRestartRunner",!0),a(2),b("compactLayout",!0),a(),b("draftText",n.promptInput_$())("isExecuting",n.isExecuting_$())("isSending",n.isSending_$())("isStopping",n.detailUi_DS.isStopping_$())("enableAttachments",!0)("modeOptions",n.modeOptions)("selectedMode",n.selectedMode_$())("modelOptions",n.modelOptions)("selectedModel",n.selectedModel_$())("effortOptions",n.effortOptions)("selectedEffort",n.selectedEffort_$())("usageText",n.usageText_$())("textareaRows",2)("queueItems",n.sessionQueue_DS.items_$())("isQueueLocked",n.sessionQueue_DS.isLocked_$())("editingQueueItemId",n.sessionQueue_DS.editingItemId_$())("editingQueueText",n.sessionQueue_DS.editingText_$()),a(2),b("isOpen",n.isInfoPopupOpen_$())("title","Event details \u2014 "+n.infoPopupTitle_$()),a(),_((l=n.infoPopupBundle_$())?19:-1,l)}},dependencies:[rt,Y,$e,Ve,Fe,Vt,Lt,Re,Ft,Dt,Mt,At,Pt,je],encapsulation:2})}return t})();var Gt=(()=>{class t{transform(e){switch(e){case"status-change":return"bg-purple-600";case"prompt-sent":return"bg-blue-600";case"response-chunk":return"bg-green-600";case"response-complete":return"bg-green-500";case"tool-call-start":return"bg-orange-500";case"tool-call-end":return"bg-orange-400";case"stdout-line":return"bg-neutral-600";case"stderr-line":return"bg-red-500";case"error":return"bg-red-600";case"file-operation":return"bg-cyan-600";case"shell-command":return"bg-yellow-600";case"session-init":return"bg-blue-500";case"config-mismatch":return"bg-amber-600";case"cli-args-record":return"bg-slate-500";case"usage-update":return"bg-teal-600";case"config-change":return"bg-indigo-500";case"runner-overflow":return"bg-red-700";case"interrupted-prompt":return"bg-amber-500";case"cli-chunk":return"bg-neutral-500";default:return"bg-neutral-600"}}static \u0275fac=function(i){return new(i||t)};static \u0275pipe=ie({name:"ccSessionEventTypeColor",type:t,pure:!0})}return t})();var Yi=["eventList"],Zi=(t,r)=>r.sequence;function eo(t,r){t&1&&(o(0,"span",14),d(1," CCAP "),s())}function to(t,r){t&1&&(M(),o(0,"svg",19),S(1,"path",22),s())}function no(t,r){t&1&&(M(),o(0,"svg",20),S(1,"rect",23)(2,"path",24),s())}function io(t,r){if(t&1&&(S(0,"pre",21),F(1,"ccSessionJsonFormat")),t&2){let e=c().$implicit;b("innerHTML",j(1,1,e.data),G)}}function oo(t,r){if(t&1){let e=k();o(0,"div",12),f("click",function(){let n=u(e).$implicit,l=c();return C(l.handleToggleEvent(n.sequence))}),o(1,"div",13),g(2,eo,2,0,"span",14),o(3,"span",15),F(4,"ccSessionEventTypeColor"),d(5),s(),o(6,"span",16),d(7),s(),o(8,"span",17),F(9,"sAbsoluteTime"),d(10),F(11,"sTimeAgo"),s(),o(12,"button",18),f("click",function(n){let l=u(e).$implicit,p=c();return C(p.handleCopyEvent(l,n))}),g(13,to,2,0,":svg:svg",19)(14,no,3,0,":svg:svg",20),s()(),g(15,io,2,3,"pre",21),s()}if(t&2){let e=r.$implicit,i=c();a(2),_(e.eventSource==="ccap-internal"?2:-1),a(),b("ngClass",j(4,8,e.eventType)),a(2),D(" ",e.eventType," "),a(2),D(" #",e.sequence," "),a(),b("title",j(9,10,e.timestamp)),a(2),D(" ",j(11,12,e.timestamp)," "),a(3),_(i.copiedSequence_$()===e.sequence?13:14),a(2),_(i.isExpanded(e.sequence)?15:-1)}}function so(t,r){t&1&&(o(0,"div",11),d(1,"No events yet"),s())}var Jt=(()=>{class t{ccSession_DS=$(W);detailUi_DS=$(K);globalError_CS=$(St);expandedSequences_$=v(new Set);isAutoScroll_$=v(!0);copiedSequence_$=v(null);eventListRef;previousEventCount=0;ngAfterViewChecked(){let e=this.ccSession_DS.selectedSessionEvents_$().length;this.isAutoScroll_$()&&e>this.previousEventCount&&this.scrollToBottom(),this.previousEventCount=e}handleToggleEvent(e){let i=this.expandedSequences_$(),n=new Set(i);n.has(e)?n.delete(e):n.add(e),this.expandedSequences_$.set(n)}handleToggleAutoScroll(){this.isAutoScroll_$.update(e=>!e)}isExpanded(e){return this.expandedSequences_$().has(e)}handleCopyEvent(e,i){return R(this,null,function*(){i.stopPropagation();let n=JSON.stringify(e.data,null,2);(yield this.globalError_CS.copyToClipboard(n)).ok&&(this.copiedSequence_$.set(e.sequence),setTimeout(()=>{this.copiedSequence_$.set(null)},1500))})}scrollToBottom(){let e=this.eventListRef?.nativeElement;e&&(e.scrollTop=e.scrollHeight)}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=z({type:t,selectors:[["app-ccap-cc-timeline"]],viewQuery:function(i,n){if(i&1&&ue(Yi,5),i&2){let l;Ce(l=fe())&&(n.eventListRef=l.first)}},hostAttrs:[1,"flex","flex-col","h-full","overflow-hidden"],decls:18,vars:8,consts:[["eventList",""],[1,"flex","items-center","justify-between","p-2","border-b","border-neonDefault","shrink-0"],[1,"flex","items-center","gap-1"],[1,"text-xs","text-neutral-400","font-medium"],[1,"text-xs","text-neutral-500"],[1,"text-[10px]","px-1.5","py-0.5","border","rounded","transition-colors",3,"click"],[1,"flex","items-center","gap-1","px-2","py-1.5","border-b","border-neonDefault","shrink-0"],["title","Session lifecycle status changes (running, waiting, completed...)",1,"px-2","py-0.5","text-[10px]","border","rounded","transition-colors",3,"click"],["title","Agent progress updates (task_progress, tool status...)",1,"px-2","py-0.5","text-[10px]","border","rounded","transition-colors",3,"click"],[1,"flex-1","overflow-y-auto","min-h-0"],[1,"px-2","py-1","border-b","border-neutral-700/30","cursor-pointer","hover:bg-neutral-800/30","transition-colors"],[1,"p-3","text-center","text-neutral-500","text-xs"],[1,"px-2","py-1","border-b","border-neutral-700/30","cursor-pointer","hover:bg-neutral-800/30","transition-colors",3,"click"],[1,"flex","items-center","gap-1.5"],["title","CCAP-internal event (saj\xE1t rendszer state-reconciliation / force-reset / recovery)",1,"text-[9px]","px-1","py-0.5","rounded","bg-purple-700","text-white","whitespace-nowrap","leading-none","font-semibold"],[1,"text-[9px]","px-1","py-0.5","rounded","text-white","whitespace-nowrap","leading-none",3,"ngClass"],[1,"text-[10px]","text-neutral-600","leading-none"],[1,"text-[10px]","text-neutral-400","ml-auto","leading-none",3,"title"],["title","Copy event data",1,"ml-1","p-0.5","rounded","transition-colors","text-neutral-500","hover:text-neonCyan","shrink-0",3,"click"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","2",1,"w-3","h-3","text-green-400"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","1.5",1,"w-3","h-3"],[1,"mt-1","p-2","bg-neutral-900","border","border-neutral-700/50","rounded","text-[10px]","text-neonCyan/70","overflow-x-auto","max-h-60","whitespace-pre-wrap","break-words","font-mono",3,"innerHTML"],["d","M3 8.5L6.5 12L13 4","stroke-linecap","round","stroke-linejoin","round"],["x","5","y","5","width","8","height","8","rx","1","stroke-linecap","round","stroke-linejoin","round"],["d","M3 11V3h8","stroke-linecap","round","stroke-linejoin","round"]],template:function(i,n){if(i&1){let l=k();o(0,"div",1)(1,"div",2)(2,"span",3),d(3,"Event Timeline"),s(),o(4,"span",4),d(5),s()(),o(6,"button",5),f("click",function(){return u(l),C(n.handleToggleAutoScroll())}),d(7," Auto-scroll "),s()(),o(8,"div",6)(9,"button",7),f("click",function(){return u(l),C(n.detailUi_DS.handleToggleSessionStatus())}),d(10," Session status "),s(),o(11,"button",8),f("click",function(){return u(l),C(n.detailUi_DS.handleToggleAgentUpdates())}),d(12," Agent updates "),s()(),o(13,"div",9,0),N(15,oo,16,14,"div",10,Zi),g(17,so,2,0,"div",11),s()}i&2&&(a(5),D(" (",n.ccSession_DS.selectedSessionEvents_$().length,") "),a(),V(n.isAutoScroll_$()?"border-neonCyan text-neonCyan shadow-neon-glow-cyan":"border-neonDefault text-neutral-400"),a(3),V(n.detailUi_DS.isShowSessionStatus_$()?"border-neonPurple/50 text-neonPurple bg-neonPurple/10":"border-neutral-700 text-neutral-500 hover:text-neutral-300 hover:border-neutral-600"),a(2),V(n.detailUi_DS.isShowAgentUpdates_$()?"border-teal-500/50 text-teal-400 bg-teal-500/10":"border-neutral-700 text-neutral-500 hover:text-neutral-300 hover:border-neutral-600"),a(4),H(n.ccSession_DS.selectedSessionEvents_$()),a(2),_(n.ccSession_DS.selectedSessionEvents_$().length?-1:17))},dependencies:[X,De,Ee,Gt,je],encapsulation:2})}return t})();var Xt=Ge(dt());function ro(t,r){if(t&1){let e=k();o(0,"button",41),f("click",function(){u(e);let n=c(2);return C(n.handleScheduleBadgeClick())}),M(),o(1,"svg",42),S(2,"rect",43)(3,"line",44)(4,"line",45)(5,"line",46),s()()}}function lo(t,r){if(t&1){let e=k();o(0,"button",47),f("click",function(){u(e);let n=c(2);return C(n.handleCoordinatorBadgeClick())}),M(),o(1,"svg",42),S(2,"circle",48)(3,"polygon",49),s()()}}function co(t,r){if(t&1){let e=k();o(0,"button",50),f("click",function(){u(e);let n=c(2);return C(n.detailUi_DS.handleResume())}),d(1),s()}if(t&2){let e=c(2);b("disabled",e.detailUi_DS.isResuming_$()),a(),D(" ",e.detailUi_DS.isResuming_$()?"Resuming...":"Resume"," ")}}function po(t,r){if(t&1&&(o(0,"span"),d(1),s()),t&2){let e=c(2);a(),J("",e.rateLimitScopeLabel_$()," ",e.rateLimitPercent_$(),"%")}}function _o(t,r){t&1&&(o(0,"span"),d(1,"Rate limit"),s())}function mo(t,r){if(t&1&&(he(0),o(1,"div",55)(2,"span",29),d(3,"Status"),s(),o(4,"span",56),d(5),s()(),o(6,"div",55)(7,"span",29),d(8,"Scope"),s(),o(9,"span",57),d(10),o(11,"span",58),d(12),s()()(),o(13,"div")(14,"div",59)(15,"span",29),d(16,"Utilization"),s(),o(17,"span",60),d(18),s()(),o(19,"div",61),S(20,"div",62),s()(),o(21,"div",55)(22,"span",29),d(23,"Warning threshold"),s(),o(24,"span",57),d(25),s()(),o(26,"div",55)(27,"span",29),d(28,"Resets in"),s(),o(29,"span",57),d(30),s()(),o(31,"div",55)(32,"span",29),d(33,"Overage"),s(),o(34,"span",63),d(35),s()(),o(36,"div",64)(37,"span",65),d(38),F(39,"date"),s()()),t&2){let e=c(3),i=e.rateLimitInfo_$();a(4),V(e.isRateLimitOverThreshold_$()?"text-red-400":"text-green-400"),a(),D(" ",i.status," "),a(5),D(" ",e.rateLimitScopeLabel_$()," "),a(2),D("(",i.rateLimitType,")"),a(6),D("",e.rateLimitPercent_$(),"%"),a(2),V(e.isRateLimitOverThreshold_$()?"bg-red-500":e.rateLimitPercent_$()>50?"bg-amber-500":"bg-green-500"),we("width",e.rateLimitPercent_$(),"%"),_e("data-utilization-color",e.isRateLimitOverThreshold_$()?"red":e.rateLimitPercent_$()>50?"amber":"green"),a(5),D("",e.rateLimitThresholdPercent_$(),"%"),a(5),T(e.rateLimitResetText_$()),a(4),V(i.isUsingOverage?"text-amber-400":"text-neutral-400"),a(),D(" ",i.isUsingOverage?"active":"inactive"," "),a(3),D("Last updated: ",ot(39,17,i.receivedAt,"HH:mm:ss"),"")}}function uo(t,r){t&1&&(o(0,"div",54),d(1," No rate limit data yet "),s())}function Co(t,r){if(t&1){let e=k();o(0,"div",51),f("click",function(){u(e);let n=c(2);return C(n.handleToggleRateLimit())}),s(),o(1,"div",52)(2,"div",53),d(3,"Rate Limit Info"),s(),g(4,mo,40,20)(5,uo,2,0,"div",54),s()}if(t&2){let e=c(2);a(4),_(e.rateLimitInfo_$()?4:5)}}function fo(t,r){t&1&&S(0,"span",19)}function xo(t,r){if(t&1&&(o(0,"div",20),d(1),s()),t&2){let e=c();a(),T(e.session.statusMessage)}}function ho(t,r){if(t&1&&(o(0,"div",21)(1,"div",17),d(2,"Actor"),s(),o(3,"div",35),d(4),s()()),t&2){let e=c();a(4),D(" ",e.session.actorLabel||e.session.actorId," ")}}function go(t,r){if(t&1&&(o(0,"div",21)(1,"div",17),d(2,"Process ID"),s(),o(3,"div",66),d(4),s()()),t&2){let e=c();a(4),T(e.session.processId)}}function So(t,r){if(t&1&&(o(0,"div",21)(1,"div",17),d(2,"Claude Session"),s(),o(3,"div",22),d(4),s()()),t&2){let e=c();a(4),T(e.session.claudeSessionId)}}function bo(t,r){if(t&1&&(o(0,"div",21)(1,"div",17),d(2,"Last Prompt"),s(),o(3,"div",67),d(4),s()()),t&2){let e=c();a(4),T(e.session.lastPrompt)}}function vo(t,r){if(t&1&&(o(0,"div",30)(1,"div",31),d(2,"Started"),s(),o(3,"div",68),F(4,"sAbsoluteTime"),d(5),F(6,"sTimeAgo"),s()()),t&2){let e=c();a(3),b("title",j(4,2,e.session.startedAt)),a(2),T(j(6,4,e.session.startedAt))}}function wo(t,r){if(t&1&&(o(0,"div",30)(1,"div",31),d(2,"Last Activity"),s(),o(3,"div",68),F(4,"sAbsoluteTime"),d(5),F(6,"sTimeAgo"),s()()),t&2){let e=c();a(3),b("title",j(4,2,e.session.lastActivityAt)),a(2),T(j(6,4,e.session.lastActivityAt))}}function yo(t,r){if(t&1&&(o(0,"div",30)(1,"div",31),d(2,"Completed"),s(),o(3,"div",68),F(4,"sAbsoluteTime"),d(5),F(6,"sTimeAgo"),s()()),t&2){let e=c();a(3),b("title",j(4,2,e.session.completedAt)),a(2),T(j(6,4,e.session.completedAt))}}function To(t,r){if(t&1&&(o(0,"div",30)(1,"div",31),d(2,"Model"),s(),o(3,"div",35),d(4),s()()),t&2){let e=c();a(4),T(e.session.activeModel||e.session.model)}}function ko(t,r){if(t&1&&(o(0,"div",30)(1,"div",31),d(2,"Mode"),s(),o(3,"div",35),d(4),s()()),t&2){let e=c();a(4),T(e.session.mode)}}function Io(t,r){if(t&1&&(o(0,"div",30)(1,"div",31),d(2,"Permission"),s(),o(3,"div",35),d(4),s()()),t&2){let e=c();a(4),T(e.session.permissionPolicy)}}function $o(t,r){if(t&1&&(o(0,"div",30)(1,"div",31),d(2,"Effort"),s(),o(3,"div",35),d(4),s()()),t&2){let e=c();a(4),T(e.session.reasoningEffort)}}function Do(t,r){if(t&1&&(o(0,"div",30)(1,"div",31),d(2,"Max Turns"),s(),o(3,"div",35),d(4),s()()),t&2){let e=c();a(4),T(e.session.maxTurns)}}function Eo(t,r){if(t&1){let e=k();o(0,"button",69),f("click",function(){u(e);let n=c(),l=c();return C(l.handleToggleDebugMode(n.session.sessionId,!0))}),d(1," on (--debug) "),s()}}function Mo(t,r){if(t&1){let e=k();o(0,"button",70),f("click",function(){u(e);let n=c(),l=c();return C(l.handleToggleDebugMode(n.session.sessionId,!1))}),d(1," off "),s()}}function Po(t,r){if(t&1&&(o(0,"div",30)(1,"div",31),d(2,"Cost"),s(),o(3,"div",73),d(4),s()()),t&2){let e=c(2);a(4),D("$",e.session.costUsdTotal.toFixed(4),"")}}function Ao(t,r){if(t&1&&(S(0,"hr",24),o(1,"h3",25),d(2," Usage "),s(),o(3,"div",71)(4,"div",27)(5,"div",72),d(6),s(),o(7,"div",29),d(8,"Input"),s()(),o(9,"div",27)(10,"div",72),d(11),s(),o(12,"div",29),d(13,"Output"),s()()(),g(14,Po,5,1,"div",30)),t&2){let e=c(),i=c();a(6),T(i.formatTokens(e.session.inputTokensTotal)),a(5),T(i.formatTokens(e.session.outputTokensTotal)),a(3),_(e.session.costUsdTotal?14:-1)}}function Oo(t,r){if(t&1&&(o(0,"div",30)(1,"div",31),d(2,"Runtime Status"),s(),o(3,"div",35),d(4),s()()),t&2){let e=c();a(4),T(e.runtime.runtimeStatus)}}function Ro(t,r){if(t&1&&(o(0,"div",30)(1,"div",31),d(2,"Runner"),s(),o(3,"div",34),d(4),s()()),t&2){let e=c();a(3),V(e.runtime.isTerminalRunnerConnected?"text-neonGreen":"text-amber-400"),a(),D(" ",e.runtime.isTerminalRunnerConnected?"connected":"disconnected"," ")}}function Vo(t,r){if(t&1){let e=k();o(0,"div",1)(1,"div",2)(2,"div",3)(3,"h3",4),d(4," Session Info "),s(),g(5,ro,6,0,"button",5)(6,lo,4,0,"button",6),s(),o(7,"button",7),f("click",function(){u(e);let n=c();return C(n.isArchiveConfirmOpen_$.set(!0))}),d(8),s()(),o(9,"div",8),g(10,co,2,2,"button",9),o(11,"button",10),f("click",function(){u(e);let n=c();return C(n.handleRestartRunner())}),d(12," \u21BB Restart runner "),s(),o(13,"div",11)(14,"button",12),f("click",function(){u(e);let n=c();return C(n.handleToggleRateLimit())}),M(),o(15,"svg",13),S(16,"circle",14)(17,"path",15),s(),g(18,po,2,2,"span")(19,_o,2,0,"span"),s(),g(20,Co,6,1),s()(),L(),o(21,"div",16)(22,"div",17),d(23,"Status"),s(),o(24,"div",3)(25,"span",18),F(26,"ccSessionStatusColor"),d(27),s(),g(28,fo,1,0,"span",19),s(),g(29,xo,2,1,"div",20),s(),o(30,"div",21)(31,"div",17),d(32,"Session ID"),s(),o(33,"div",22),d(34),s()(),o(35,"div",21)(36,"div",17),d(37,"Workspace"),s(),o(38,"div",23),d(39),s()(),g(40,ho,5,1,"div",21)(41,go,5,1,"div",21)(42,So,5,1,"div",21),S(43,"hr",24),o(44,"h3",25),d(45," Statistics "),s(),o(46,"div",26)(47,"div",27)(48,"div",28),d(49),s(),o(50,"div",29),d(51,"Prompts"),s()(),o(52,"div",27)(53,"div",28),d(54),s(),o(55,"div",29),d(56,"Tool Calls"),s()()(),g(57,bo,5,1,"div",21),S(58,"hr",24),o(59,"h3",25),d(60," Timestamps "),s(),g(61,vo,7,6,"div",30)(62,wo,7,6,"div",30)(63,yo,7,6,"div",30),S(64,"hr",24),o(65,"h3",25),d(66," Configuration "),s(),g(67,To,5,1,"div",30)(68,ko,5,1,"div",30)(69,Io,5,1,"div",30)(70,$o,5,1,"div",30)(71,Do,5,1,"div",30),o(72,"div",30)(73,"div",31),d(74,"Debug Mode"),s(),g(75,Eo,2,0,"button",32)(76,Mo,2,0,"button",33),s(),g(77,Ao,15,3),S(78,"hr",24),o(79,"h3",25),d(80," Runtime "),s(),o(81,"div",30)(82,"div",31),d(83,"Live"),s(),o(84,"div",34),d(85),s()(),g(86,Oo,5,1,"div",30),o(87,"div",30)(88,"div",31),d(89,"Output Buffer"),s(),o(90,"div",35),d(91),s()(),o(92,"div",30)(93,"div",31),d(94,"Runner Mode"),s(),o(95,"div",35),d(96),s()(),g(97,Ro,5,3,"div",30),s(),o(98,"app-s-modal",36),f("closed",function(){u(e);let n=c();return C(n.isArchiveConfirmOpen_$.set(!1))}),o(99,"p",37),d(100),s(),o(101,"div",38)(102,"button",39),f("click",function(){u(e);let n=c();return C(n.isArchiveConfirmOpen_$.set(!1))}),d(103," Cancel "),s(),o(104,"button",40),f("click",function(){let n=u(e),l=c();return C(l.handleConfirmToggleArchive(n.session))}),d(105),s()()()}if(t&2){let e=r,i=c();a(5),_(i.hasSchedule_$()?5:-1),a(),_(i.hasCoordinator_$()?6:-1),a(),V(e.session.isArchived?"text-amber-400 border border-amber-500/60 bg-amber-500/10 hover:bg-amber-500/20":"text-neutral-500 border border-neutral-700 hover:text-neutral-300 hover:bg-neutral-700"),b("title",e.session.isArchived?"Unarchive session":"Archive session"),a(),D(" ",e.session.isArchived?"Unarchive":"Archive"," "),a(2),_(e.session.status==="completed"||e.session.status==="errored"?10:-1),a(4),V(i.rateLimitInfo_$()?i.isRateLimitOverThreshold_$()?"border-red-500/30 text-red-400/80 hover:bg-red-500/10":"border-green-500/30 text-green-400/80 hover:bg-green-500/10":"border-neutral-700 text-neutral-500"),_e("data-rate-limit-state",i.rateLimitInfo_$()?i.isRateLimitOverThreshold_$()?"reached":"allowed":"unknown"),a(4),_(i.rateLimitInfo_$()?18:19),a(2),_(i.isRateLimitOpen_$()?20:-1),a(5),b("ngClass",j(26,47,e.session.status)),a(2),D(" ",e.session.status," "),a(),_(e.runtime.isLive?28:-1),a(),_(e.session.statusMessage?29:-1),a(5),T(e.session.sessionId),a(5),T(e.session.workspacePath),a(),_(e.session.actorId||e.session.actorLabel?40:-1),a(),_(e.session.processId?41:-1),a(),_(e.session.claudeSessionId?42:-1),a(7),T(e.session.promptCount),a(5),T(e.session.toolCallCount),a(3),_(e.session.lastPrompt?57:-1),a(4),_(e.session.startedAt?61:-1),a(),_(e.session.lastActivityAt?62:-1),a(),_(e.session.completedAt?63:-1),a(4),_(e.session.activeModel||e.session.model?67:-1),a(),_(e.session.mode?68:-1),a(),_(e.session.permissionPolicy?69:-1),a(),_(e.session.reasoningEffort?70:-1),a(),_(e.session.maxTurns?71:-1),a(4),_(e.session.isDebugMode?75:76),a(2),_(e.session.inputTokensTotal||e.session.outputTokensTotal||e.session.costUsdTotal?77:-1),a(7),V(e.runtime.isLive?"text-neonGreen":"text-neutral-500"),a(),D(" ",e.runtime.isLive?"Yes":"No"," "),a(),_(e.runtime.runtimeStatus?86:-1),a(5),D("",e.runtime.outputBufferLength," lines"),a(5),D(" ",e.runtime.isTerminalMode?"terminal":"direct"," "),a(),_(e.runtime.isTerminalMode?97:-1),a(),b("isOpen",i.isArchiveConfirmOpen_$())("title",e.session.isArchived?"Unarchive Session":"Archive Session")("maxWidth","sm")("closeOnBackdropClick",!0),a(2),D(" ",e.session.isArchived?"Are you sure you want to unarchive this session?":"Are you sure you want to archive this session?"," "),a(5),D(" ",e.session.isArchived?"Unarchive":"Archive"," ")}}var Yt=(()=>{class t{ccSession_DS=$(W);detailUi_DS=$(K);scheduledJobs_DS=$(Me);coordinator_DS=$(Pe);hasSchedule_$=A(()=>{let e=this.ccSession_DS.activeSessionId_$();return e?this.scheduledJobs_DS.scheduledSessionIds_$().has(e):!1});hasCoordinator_$=A(()=>{let e=this.ccSession_DS.activeSessionId_$();return e?this.coordinator_DS.coordinatedSessionIds_$().has(e):!1});isRateLimitOpen_$=v(!1);isArchiveConfirmOpen_$=v(!1);schedulePopupSessionId_$=v(null);coordinatorPopupSessionId_$=v(null);handleScheduleBadgeClick(){let e=this.ccSession_DS.activeSessionId_$();e&&this.schedulePopupSessionId_$.set(e)}handleCloseSchedulePopup(){this.schedulePopupSessionId_$.set(null)}handleCoordinatorBadgeClick(){let e=this.ccSession_DS.activeSessionId_$();e&&this.coordinatorPopupSessionId_$.set(e)}handleCloseCoordinatorPopup(){this.coordinatorPopupSessionId_$.set(null)}handleToggleDebugMode(e,i){if(!e)return;let n=!i;this.ccSession_DS.updateSessionConfig({sessionId:e,isDebugMode:n}).catch(l=>{Xt.DyFM_Log.error("[CCAP] cc-metadata config-update isDebugMode",l)})}rateLimitInfo_$=A(()=>this.ccSession_DS.rateLimitInfo_$());rateLimitResetText_$=A(()=>le.formatResetText(this.rateLimitInfo_$()));rateLimitPercent_$=A(()=>le.computeUtilizationPercent(this.rateLimitInfo_$()));rateLimitThresholdPercent_$=A(()=>le.computeThresholdPercent(this.rateLimitInfo_$()));rateLimitScopeLabel_$=A(()=>le.formatLimitScopeLabel(this.rateLimitInfo_$()));isRateLimitOverThreshold_$=A(()=>le.isOverThreshold(this.rateLimitInfo_$()));ngOnInit(){this.scheduledJobs_DS.jobs_$().length===0&&this.scheduledJobs_DS.loadAll(),this.coordinator_DS.globalCoordinatorsList_$().length===0&&this.coordinator_DS.loadAllCoordinatorsForManagementPage()}handleToggleRateLimit(){this.isRateLimitOpen_$.update(e=>!e)}handleConfirmToggleArchive(e){return R(this,null,function*(){this.isArchiveConfirmOpen_$.set(!1);try{yield this.ccSession_DS.setSessionArchived({sessionId:e.sessionId,isArchived:!e.isArchived})}catch{}})}handleRestartRunner(){return R(this,null,function*(){let e=this.ccSession_DS.activeSessionId_$();if(e)try{yield this.ccSession_DS.restartRunner({sessionId:e})}catch{}})}formatTokens(e){return e?e>1e3?`${(e/1e3).toFixed(1)}k`:String(e):"0"}static \u0275fac=function(i){return new(i||t)};static \u0275cmp=z({type:t,selectors:[["app-ccap-cc-metadata"]],hostAttrs:[1,"block","h-full","overflow-y-auto"],decls:3,vars:5,consts:[[3,"closed","sessionId","isOpen"],[1,"p-3"],[1,"flex","items-center","justify-between","mb-3"],[1,"flex","items-center","gap-1.5"],[1,"text-xs","font-semibold","text-neutral-400","uppercase","tracking-wider"],["type","button","title","Ehhez a session-h\xF6z tartozik schedule \u2014 kattints a r\xE9szletek\xE9rt","aria-label","Schedule attached \u2014 open popup",1,"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,"text-neonAmber/80","hover:text-neonAmber","focus:outline-none","focus:ring-1","focus:ring-neonAmber/60","rounded","p-0.5"],[1,"text-[10px]","px-1.5","py-0.5","rounded","transition-colors",3,"click","title"],[1,"flex","flex-col","gap-2","mb-4"],["type","button",1,"w-full","px-2","py-1.5","text-xs","border","border-ccapAccent","text-ccapAccent","hover:bg-ccapAccent","hover:text-white","disabled:opacity-50","rounded","transition-colors",3,"disabled"],["type","button","title","Runner kill + respawn (\xFAj CMD/termin\xE1l ablak; haszn\xE1ld ha verzi\xF3-mismatch vagy no-ACK loop van)",1,"w-full","px-2","py-1.5","text-xs","border","border-amber-500/60","text-amber-300","hover:bg-amber-500/10","disabled:opacity-50","rounded","transition-colors",3,"click"],["data-testid","cc-rate-limit-container",1,"relative","w-full","shrink-0"],["type","button","data-testid","cc-rate-limit-button","title","Rate limit info",1,"w-full","px-2","py-1.5","text-xs","border","rounded","transition-colors","flex","items-center","justify-center","gap-1.5",3,"click"],["viewBox","0 0 16 16","fill","none","stroke","currentColor","stroke-width","1.5","stroke-linecap","round","stroke-linejoin","round",1,"w-3.5","h-3.5","shrink-0"],["cx","8","cy","8","r","6"],["d","M8 5v3.5l2 1.5"],[1,"mb-4"],[1,"text-[10px]","text-neutral-500","uppercase","tracking-wider","mb-1"],[1,"text-[10px]","px-1.5","py-0.5","rounded-full","text-white",3,"ngClass"],[1,"w-1.5","h-1.5","rounded-full","bg-green-500","animate-pulse"],[1,"text-xs","text-neutral-500","mt-0.5"],[1,"mb-3"],[1,"text-xs","text-neutral-400","font-mono","break-all"],[1,"text-xs","text-neutral-400","break-all"],[1,"border-neutral-700/50","my-3"],[1,"text-xs","font-semibold","text-neutral-400","uppercase","tracking-wider","mb-3"],[1,"grid","grid-cols-2","gap-2","mb-4"],[1,"bg-neutral-800/60","border","border-neonDefault","rounded","p-2","text-center"],[1,"text-lg","font-bold","text-neutral-100"],[1,"text-[10px]","text-neutral-500"],[1,"mb-2"],[1,"text-[10px]","text-neutral-500","uppercase","tracking-wider","mb-0.5"],["type","button","title","CLI --debug flag akt\xEDv \u2014 klikk a kikapcsol\xE1shoz",1,"text-xs","px-2","py-0.5","rounded","border","border-amber-700","text-amber-400","hover:border-amber-500","hover:text-amber-300","transition-colors","duration-150"],["type","button","title","CLI --debug flag inakt\xEDv \u2014 klikk a bekapcsol\xE1shoz",1,"text-xs","px-2","py-0.5","rounded","border","border-neutral-700","text-neutral-500","hover:border-neutral-500","hover:text-neutral-300","transition-colors","duration-150"],[1,"text-xs"],[1,"text-xs","text-neutral-400"],[3,"closed","isOpen","title","maxWidth","closeOnBackdropClick"],[1,"text-sm","text-neutral-300","mb-4"],[1,"flex","justify-end","gap-2"],[1,"px-3","py-1.5","text-xs","border","border-neonDefault","text-neutral-300","hover:bg-neutral-700","rounded","transition-colors",3,"click"],[1,"px-3","py-1.5","text-xs","border","border-amber-500","text-amber-400","hover:bg-amber-500","hover:text-white","rounded","transition-colors",3,"click"],["type","button","title","Ehhez a session-h\xF6z tartozik schedule \u2014 kattints a r\xE9szletek\xE9rt","aria-label","Schedule attached \u2014 open popup",1,"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,"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"],["type","button",1,"w-full","px-2","py-1.5","text-xs","border","border-ccapAccent","text-ccapAccent","hover:bg-ccapAccent","hover:text-white","disabled:opacity-50","rounded","transition-colors",3,"click","disabled"],[1,"fixed","inset-0","z-40",3,"click"],["data-testid","cc-rate-limit-popover",1,"absolute","left-0","top-full","mt-1","z-50","w-full","min-w-[16rem]","max-w-[min(100vw-2rem,18rem)]","bg-neutral-900","border","border-neutral-700","rounded-lg","shadow-xl","p-3","space-y-2.5"],[1,"text-xs","font-semibold","text-neutral-200","mb-2"],[1,"text-[11px]","text-neutral-500","text-center","py-2"],[1,"flex","items-center","justify-between"],["data-testid","cc-rate-limit-status",1,"text-[11px]","font-medium"],[1,"text-[11px]","text-neutral-300"],[1,"text-[9px]","text-neutral-500"],[1,"flex","items-center","justify-between","mb-1"],[1,"text-[10px]","text-neutral-300","font-medium"],[1,"w-full","h-1.5","bg-neutral-800","rounded-full","overflow-hidden"],["data-testid","cc-rate-limit-utilization-bar",1,"h-full","rounded-full","transition-all"],[1,"text-[11px]"],[1,"border-t","border-neutral-800","pt-1.5","mt-1.5"],[1,"text-[9px]","text-neutral-600"],[1,"text-xs","text-neutral-400","font-mono"],[1,"text-xs","text-neutral-400","line-clamp-3"],[1,"text-xs","text-neutral-400",3,"title"],["type","button","title","CLI --debug flag akt\xEDv \u2014 klikk a kikapcsol\xE1shoz",1,"text-xs","px-2","py-0.5","rounded","border","border-amber-700","text-amber-400","hover:border-amber-500","hover:text-amber-300","transition-colors","duration-150",3,"click"],["type","button","title","CLI --debug flag inakt\xEDv \u2014 klikk a bekapcsol\xE1shoz",1,"text-xs","px-2","py-0.5","rounded","border","border-neutral-700","text-neutral-500","hover:border-neutral-500","hover:text-neutral-300","transition-colors","duration-150",3,"click"],[1,"grid","grid-cols-2","gap-2","mb-2"],[1,"text-sm","font-bold","text-neutral-100"],[1,"text-xs","text-neonGreen","font-mono"]],template:function(i,n){if(i&1&&(g(0,Vo,106,49),o(1,"app-sch-schedule-popup",0),f("closed",function(){return n.handleCloseSchedulePopup()}),s(),o(2,"app-crd-info-popup",0),f("closed",function(){return n.handleCloseCoordinatorPopup()}),s()),i&2){let l;_((l=n.ccSession_DS.selectedSession_$())?0:-1,l),a(),b("sessionId",n.schedulePopupSessionId_$())("isOpen",n.schedulePopupSessionId_$()!==null),a(),b("sessionId",n.coordinatorPopupSessionId_$())("isOpen",n.coordinatorPopupSessionId_$()!==null)}},dependencies:[X,Y,de,ce,lt,De,Ee,Ue],encapsulation:2})}return t})();function Fo(t,r){t&1&&(o(0,"div",0),d(1," Loading session... "),s())}function Uo(t,r){if(t&1){let e=k();o(0,"app-s-session-detail-three-column-layout",2),f("startResizeStart",function(n){u(e);let l=c();return C(l.handleMetadataResizeStart(n))})("endResizeStart",function(n){u(e);let l=c();return C(l.handleTimelineResizeStart(n))}),o(1,"div",3),S(2,"app-ccap-cc-metadata"),s(),o(3,"div",4),S(4,"app-ccap-cc-console",5),s(),o(5,"div",6),S(6,"app-ccap-cc-timeline"),s()()}if(t&2){let e=c();b("isStartOpen",e.detailUi_DS.isMetadataPanelOpen_$())("isEndOpen",e.detailUi_DS.isTimelinePanelOpen_$())("startWidthPx",e.metadataWidth_$())("endWidthPx",e.timelineWidth_$())("isResizing",e.isResizing_$()),a(4),b("sessionId",e.sessionId_$())("isShowSessionStatus",e.detailUi_DS.isShowSessionStatus_$())("isShowAgentUpdates",e.detailUi_DS.isShowAgentUpdates_$())}}function jo(t,r){t&1&&(o(0,"div",0),d(1," Select a session to view details "),s())}var ze=(()=>{class t extends bt{ccSession_DS=$(W);detailUi_DS=$(K);peiContext_DS=$(ae);route=$(ct);router=$(se);sessionId_$=v("");metadataWidth_$=v(256);timelineWidth_$=v(288);isResizing_$=v(!1);ngOnInit(){this.metadataWidth_$.set(Math.max(160,Math.min(500,y.loadPanelWidth("metadata",256)))),this.timelineWidth_$.set(Math.max(200,Math.min(600,y.loadPanelWidth("timeline",288)))),this.addSubscription(this.route.params.subscribe(e=>{let i=e.sessionId??"",n=e.ccapId??"";if(this.sessionId_$.set(i),i)y.saveLastSessionId(i),n&&y.saveLastCcapId(n),this.peiContext_DS.ensureInitialized().then(()=>{n&&this.peiContext_DS.activeCcapId_$()!==n&&this.peiContext_DS.selectInstance(n),this.ccSession_DS.clearLiveOutput(),this.ccSession_DS.setActiveSessionId(i),this.ccSession_DS.loadSessionDetail({sessionId:i}),this.ccSession_DS.loadSessionEvents({sessionId:i});let l=this.peiContext_DS.activeCcapId_$();l&&this.ccSession_DS.loadPersistedRateLimitState({ccapId:l}).catch(()=>{})});else{let l=y.loadLastSessionId(),p=y.loadLastCcapId();if(l){let m=p?["/cc-session",p,l]:["/cc-session",l];this.router.navigate(m,{replaceUrl:!0})}}}))}ngOnDestroy(){this.ccSession_DS.setActiveSessionId(""),super.ngOnDestroy()}handleMetadataResizeStart(e){let i=this.metadataWidth_$(),n=e.clientX;this.isResizing_$.set(!0),ge.attachUntilPointerUp({startEvent:e,onMove:l=>{let p=l.clientX-n,m=Math.max(160,Math.min(500,i+p));this.metadataWidth_$.set(m)},onEnd:()=>{this.isResizing_$.set(!1),y.savePanelWidth("metadata",this.metadataWidth_$())}})}handleTimelineResizeStart(e){let i=this.timelineWidth_$(),n=e.clientX;this.isResizing_$.set(!0),ge.attachUntilPointerUp({startEvent:e,onMove:l=>{let p=n-l.clientX,m=Math.max(200,Math.min(600,i+p));this.timelineWidth_$.set(m)},onEnd:()=>{this.isResizing_$.set(!1),y.savePanelWidth("timeline",this.timelineWidth_$())}})}static \u0275fac=(()=>{let e;return function(n){return(e||(e=Ze(t)))(n||t)}})();static \u0275cmp=z({type:t,selectors:[["app-ccap-cc-detail"]],hostAttrs:[1,"flex","flex-col","flex-1","min-h-0","overflow-hidden"],features:[tt],decls:3,vars:1,consts:[[1,"flex","items-center","justify-center","h-full","text-neutral-500","text-sm"],[3,"isStartOpen","isEndOpen","startWidthPx","endWidthPx","isResizing"],[3,"startResizeStart","endResizeStart","isStartOpen","isEndOpen","startWidthPx","endWidthPx","isResizing"],["sDetailColumnStart",""],["sDetailColumnMain",""],[3,"sessionId","isShowSessionStatus","isShowAgentUpdates"],["sDetailColumnEnd",""]],template:function(i,n){i&1&&g(0,Fo,2,0,"div",0)(1,Uo,7,8,"app-s-session-detail-three-column-layout",1)(2,jo,2,0,"div",0),i&2&&_(n.ccSession_DS.selectedSessionLoading_$()?0:n.ccSession_DS.selectedSession_$()?1:2)},dependencies:[$t,Qt,Jt,Yt],encapsulation:2})}return t})();var zo=[{path:"",component:Ht,children:[{path:"",pathMatch:"full",component:ze},{path:":ccapId/:sessionId",component:ze},{path:":sessionId",component:ze}]}],fr=(()=>{class t{static \u0275fac=function(i){return new(i||t)};static \u0275mod=Ye({type:t});static \u0275inj=Xe({imports:[oe,gt,_t.forChild(zo),Ae,Y,$e,Ve,Fe,de,Re,ce,Ot]})}return t})();export{fr as CcSession_Module};
4
- //# sourceMappingURL=cc.module-J3EAMUJD.js.map
4
+ //# sourceMappingURL=cc.module-DAJE6FWU.js.map
@@ -1,2 +1,2 @@
1
- import{I as c}from"./chunk-PYVALWHU.js";import{C as s,p as n,vb as o,xb as f,y as r}from"./chunk-TBMJSIBB.js";var b=(()=>{class i{baseUrl=`${c.api.baseUrl}/ext-session-message`;http=s(f);getMessages(t){let e=new o;return t.sinceSequence!==void 0&&(e=e.set("sinceSequence",String(t.sinceSequence))),t.beforeSequence!==void 0&&(e=e.set("beforeSequence",String(t.beforeSequence))),t.limit!==void 0&&(e=e.set("limit",String(t.limit))),t.latest&&(e=e.set("latest","1")),n(this.http.get(`${this.baseUrl}/${t.sessionId}/messages`,{params:e}))}static \u0275fac=function(e){return new(e||i)};static \u0275prov=r({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();export{b as a};
2
- //# sourceMappingURL=chunk-YORE53OO.js.map
1
+ import{I as c}from"./chunk-IZZTOAKP.js";import{C as s,p as n,vb as o,xb as f,y as r}from"./chunk-TBMJSIBB.js";var b=(()=>{class i{baseUrl=`${c.api.baseUrl}/ext-session-message`;http=s(f);getMessages(t){let e=new o;return t.sinceSequence!==void 0&&(e=e.set("sinceSequence",String(t.sinceSequence))),t.beforeSequence!==void 0&&(e=e.set("beforeSequence",String(t.beforeSequence))),t.limit!==void 0&&(e=e.set("limit",String(t.limit))),t.latest&&(e=e.set("latest","1")),n(this.http.get(`${this.baseUrl}/${t.sessionId}/messages`,{params:e}))}static \u0275fac=function(e){return new(e||i)};static \u0275prov=r({token:i,factory:i.\u0275fac,providedIn:"root"})}return i})();export{b as a};
2
+ //# sourceMappingURL=chunk-2KAMFUG2.js.map
@@ -1,3 +1,3 @@
1
- import{a as n}from"./chunk-SB6AP4YU.js";import{G as o}from"./chunk-TBMJSIBB.js";var u=(()=>{class e{transform(t){return n.formatAbsoluteForTooltip(t)}static \u0275fac=function(i){return new(i||e)};static \u0275pipe=o({name:"sAbsoluteTime",type:e,pure:!0,standalone:!0})}return e})();var d=(()=>{class e{transform(t){return n.formatCompactRelativeTime(t)}static \u0275fac=function(i){return new(i||e)};static \u0275pipe=o({name:"sTimeAgo",type:e,pure:!0,standalone:!0})}return e})();var a=class e{static normalizeForSearch(r){return typeof r!="string"||r.length===0?"":r.trim().toLowerCase().normalize("NFD").replace(new RegExp("\\p{Diacritic}","gu"),"")}static includesText(r,t){let i=e.normalizeForSearch(t);return i.length===0?!0:e.normalizeForSearch(r).includes(i)}};var s=class{static looksLikeJson(r){let t=r.trim();return t.startsWith("{")&&t.endsWith("}")||t.startsWith("[")&&t.endsWith("]")}static formatJson(r){try{let t=JSON.parse(r.trim());return JSON.stringify(t,null,2)}catch{return r}}static lineCount(r){return r.split(`
1
+ import{a as n}from"./chunk-3YNI7ZOC.js";import{G as o}from"./chunk-TBMJSIBB.js";var u=(()=>{class e{transform(t){return n.formatAbsoluteForTooltip(t)}static \u0275fac=function(i){return new(i||e)};static \u0275pipe=o({name:"sAbsoluteTime",type:e,pure:!0,standalone:!0})}return e})();var d=(()=>{class e{transform(t){return n.formatCompactRelativeTime(t)}static \u0275fac=function(i){return new(i||e)};static \u0275pipe=o({name:"sTimeAgo",type:e,pure:!0,standalone:!0})}return e})();var a=class e{static normalizeForSearch(r){return typeof r!="string"||r.length===0?"":r.trim().toLowerCase().normalize("NFD").replace(new RegExp("\\p{Diacritic}","gu"),"")}static includesText(r,t){let i=e.normalizeForSearch(t);return i.length===0?!0:e.normalizeForSearch(r).includes(i)}};var s=class{static looksLikeJson(r){let t=r.trim();return t.startsWith("{")&&t.endsWith("}")||t.startsWith("[")&&t.endsWith("]")}static formatJson(r){try{let t=JSON.parse(r.trim());return JSON.stringify(t,null,2)}catch{return r}}static lineCount(r){return r.split(`
2
2
  `).length}};export{a,u as b,d as c,s as d};
3
- //# sourceMappingURL=chunk-STNBIKCT.js.map
3
+ //# sourceMappingURL=chunk-2PHD2EKP.js.map
@@ -1,2 +1,2 @@
1
- import{I as a}from"./chunk-PYVALWHU.js";import{C as n,p as t,xb as o,y as i}from"./chunk-TBMJSIBB.js";var m=(()=>{class r{baseUrl=`${a.api.baseUrl}/setup`;http=n(o);getSetupStatus(){return t(this.http.get(`${this.baseUrl}/status`))}getVaultStatus(){return t(this.http.get(`${this.baseUrl}/vault-status`))}getVaultKeyGenerate(){return t(this.http.get(`${this.baseUrl}/vault-key/generate`))}postVaultKey(e){return t(this.http.post(`${this.baseUrl}/vault-key`,{vaultKey:e}))}postSetup(e){return t(this.http.post(this.baseUrl,e))}putSetupConfig(e){let s=`${a.api.baseUrl}/settings`;return t(this.http.put(`${s}/config`,e))}static \u0275fac=function(s){return new(s||r)};static \u0275prov=i({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();export{m as a};
2
- //# sourceMappingURL=chunk-JFYDUH37.js.map
1
+ import{I as a}from"./chunk-IZZTOAKP.js";import{C as n,p as t,xb as o,y as i}from"./chunk-TBMJSIBB.js";var m=(()=>{class r{baseUrl=`${a.api.baseUrl}/setup`;http=n(o);getSetupStatus(){return t(this.http.get(`${this.baseUrl}/status`))}getVaultStatus(){return t(this.http.get(`${this.baseUrl}/vault-status`))}getVaultKeyGenerate(){return t(this.http.get(`${this.baseUrl}/vault-key/generate`))}postVaultKey(e){return t(this.http.post(`${this.baseUrl}/vault-key`,{vaultKey:e}))}postSetup(e){return t(this.http.post(this.baseUrl,e))}putSetupConfig(e){let s=`${a.api.baseUrl}/settings`;return t(this.http.put(`${s}/config`,e))}static \u0275fac=function(s){return new(s||r)};static \u0275prov=i({token:r,factory:r.\u0275fac,providedIn:"root"})}return r})();export{m as a};
2
+ //# sourceMappingURL=chunk-3TF7VKLJ.js.map
@@ -1,2 +1,2 @@
1
- import{p as h}from"./chunk-PYVALWHU.js";import{h as S}from"./chunk-TBMJSIBB.js";var c=S(h()),f=60,d=60*60,g=60*60*24,M=7,m=class{static formatRelativeTime(t){if(t==null)return"";let n=typeof t=="string"?new Date(t):t;if(Number.isNaN(n.getTime()))return"";let a=new Date,i=a.getTime()-n.getTime(),o=Math.floor(i/c.second);if(o<0)return"";if(o<f)return"just now";let e=Math.floor(o/f);if(e<60)return e===1?"1 minute ago":`${e} minutes ago`;let s=Math.floor(o/d);if(s<24)return s===1?"1 hour ago":`${s} hours ago`;let r=Math.floor(o/g);if(r<=M)return r===1?"1 day ago":`${r} days ago`;let u={month:"short",day:"numeric",year:n.getFullYear()!==a.getFullYear()?"numeric":void 0};return n.toLocaleDateString(void 0,u)}static formatCompactRelativeTime(t){if(t==null)return"";let n=typeof t=="string"?new Date(t):t;if(Number.isNaN(n.getTime()))return"";let i=Date.now()-n.getTime();if(i<0)return"just now";let o=Math.floor(i/c.second),e=Math.floor(o/f),s=Math.floor(o/d),r=Math.floor(o/g);return o<f?"just now":e<60?`${e}m ago`:s<24?`${s}h ago`:r<30?`${r}d ago`:`${Math.floor(r/30)}mo ago`}static formatAbsoluteForTooltip(t){if(t==null)return"";let n=typeof t=="string"?new Date(t):t;if(Number.isNaN(n.getTime()))return"";let a=String(n.getFullYear()),i=String(n.getMonth()+1).padStart(2,"0"),o=String(n.getDate()).padStart(2,"0"),e=String(n.getHours()).padStart(2,"0"),s=String(n.getMinutes()).padStart(2,"0"),r=String(n.getSeconds()).padStart(2,"0");return`${a}-${i}-${o} ${e}:${s}:${r}`}};export{m as a};
2
- //# sourceMappingURL=chunk-SB6AP4YU.js.map
1
+ import{p as h}from"./chunk-IZZTOAKP.js";import{h as S}from"./chunk-TBMJSIBB.js";var c=S(h()),f=60,d=60*60,g=60*60*24,M=7,m=class{static formatRelativeTime(t){if(t==null)return"";let n=typeof t=="string"?new Date(t):t;if(Number.isNaN(n.getTime()))return"";let a=new Date,i=a.getTime()-n.getTime(),o=Math.floor(i/c.second);if(o<0)return"";if(o<f)return"just now";let e=Math.floor(o/f);if(e<60)return e===1?"1 minute ago":`${e} minutes ago`;let s=Math.floor(o/d);if(s<24)return s===1?"1 hour ago":`${s} hours ago`;let r=Math.floor(o/g);if(r<=M)return r===1?"1 day ago":`${r} days ago`;let u={month:"short",day:"numeric",year:n.getFullYear()!==a.getFullYear()?"numeric":void 0};return n.toLocaleDateString(void 0,u)}static formatCompactRelativeTime(t){if(t==null)return"";let n=typeof t=="string"?new Date(t):t;if(Number.isNaN(n.getTime()))return"";let i=Date.now()-n.getTime();if(i<0)return"just now";let o=Math.floor(i/c.second),e=Math.floor(o/f),s=Math.floor(o/d),r=Math.floor(o/g);return o<f?"just now":e<60?`${e}m ago`:s<24?`${s}h ago`:r<30?`${r}d ago`:`${Math.floor(r/30)}mo ago`}static formatAbsoluteForTooltip(t){if(t==null)return"";let n=typeof t=="string"?new Date(t):t;if(Number.isNaN(n.getTime()))return"";let a=String(n.getFullYear()),i=String(n.getMonth()+1).padStart(2,"0"),o=String(n.getDate()).padStart(2,"0"),e=String(n.getHours()).padStart(2,"0"),s=String(n.getMinutes()).padStart(2,"0"),r=String(n.getSeconds()).padStart(2,"0");return`${a}-${i}-${o} ${e}:${s}:${r}`}};export{m as a};
2
+ //# sourceMappingURL=chunk-3YNI7ZOC.js.map
@@ -1,3 +1,3 @@
1
- import{a as R,b as O}from"./chunk-JBI7DZF6.js";import{a as q}from"./chunk-YORE53OO.js";import{a as g}from"./chunk-UFBTR2BG.js";import{a as U}from"./chunk-O3R65DXW.js";import{e as P}from"./chunk-XCT53H4N.js";import{h as y,j as L}from"./chunk-KE3ET6OR.js";import{p as D}from"./chunk-PYVALWHU.js";import{C as v,R as T,a as h,aa as p,b as f,h as E,k as d,y as A}from"./chunk-TBMJSIBB.js";var S=E(D());var _=class u{static compareAsc(C,e){let s=(C.sequence??0)-(e.sequence??0);if(s!==0)return s;let n=typeof C.timestamp=="string"?C.timestamp:"",t=typeof e.timestamp=="string"?e.timestamp:"",o=n.localeCompare(t);if(o!==0)return o;let i=typeof C.messageKey=="string"?C.messageKey:"",r=typeof e.messageKey=="string"?e.messageKey:"";return i.localeCompare(r)}static sortAsc(C){return[...C].sort(u.compareAsc)}};var M=E(D());var x=(()=>{class u{parent;agentToolUseIds=new Set;activeSubAgentId="";toolUseIdToName=new Map;init(e){this.parent=e}resetTrackingState(){this.toolUseIdToName.clear(),this.agentToolUseIds.clear(),this.activeSubAgentId=""}handleSocketEvent(e,s){let n=e.event,t=e.payload;try{let o=typeof t.ccapId=="string"?t.ccapId:"";if(n!=="cc:rate-limit-update"&&n!=="ext-session-msg:message"&&n!=="ext-session-msg:update"&&o&&s.selectedCcapId&&o!==s.selectedCcapId){M.DyFM_Log.info(`CCAP_CcSession_DS | socket event dropped by instance filter | event: ${n} | eventCcapId: ${o} | selectedCcapId: ${s.selectedCcapId}`);return}switch(n){case"cc-session:status":this.handleStatusUpdate(t);break;case"cc-session:output":this.handleOutputChunk(t);break;case"cc-session:event":this.handleSessionEvent(t);break;case"cc-session:list-update":this.handleListUpdate(t);break;case"cc-session:session-update":this.handleSessionItemUpdate(t);break;case"agent-events":this.handleAgentEvent(t);break;case"ext-session-msg:message":this.handleAssembledMessage(t);break;case"ext-session-msg:update":this.handleAssembledMessageUpdate(t);break;case"cc:rate-limit-update":this.handleRateLimitBroadcast(t);break}}catch(o){let i=o instanceof Error?o.message:String(o);M.DyFM_Log.error(`CCAP_CcSession_DS | socket event error | event: ${n}`,o),s.globalErrorShowError(o instanceof Error?o:new Error(`CC Session socket event processing failed: ${n} \u2014 ${i}`),"cc-session-socket-event")}}pushConsoleMessageFromEvent(e,s,n){let t=e.data;switch(e.eventType){case"response-chunk":{this.pushResponseChunkBlocks(t);break}case"tool-call-start":{let o=t.name??t.tool_name??"unknown",i=typeof t.id=="string"?t.id:"";i&&this.toolUseIdToName.set(i,o),o==="Agent"&&i&&this.agentToolUseIds.add(i);let r=t.input,a=r?u.summarizeToolInput(r):"",l=a?`${o}: ${a}`:o,c=o==="Edit"?u.buildEditExpandableContent(r):void 0,m=o==="Agent"?"":this.activeSubAgentId;this.parent.pushConsoleMessage({type:"tool",text:l,expandableContent:c,rawData:t,parentAgentId:m||void 0});break}case"tool-call-end":{let o=t.content??t.output,i=typeof o=="string"?o:"",r=i.length>200?i.substring(0,200)+"\u2026":i;if(r){let a=i.length>200?i:void 0;this.parent.pushConsoleMessage({type:"tool-result",text:r,expandableContent:a,rawData:t,parentAgentId:this.activeSubAgentId||void 0})}break}case"response-complete":{this.activeSubAgentId="";let o=t.cost_usd,i=typeof o=="number"?` ($${o.toFixed(4)})`:"",r=typeof t.model=="string"?` \xB7 ${t.model}`:"";this.parent.pushConsoleMessage({type:"result",text:`Response complete${r}${i}`,rawData:t,expandableContent:JSON.stringify(t,null,2)}),this.accumulateUsage(t);break}case"prompt-sent":{let o=typeof t.content=="string"?t.content:"";o&&(this.parent.consoleMessages_$().some(a=>a.type==="prompt"&&a.text===o.trim())||this.parent.pushConsoleMessage({type:"prompt",text:o,rawData:t,expandableContent:JSON.stringify(t,null,2)}));break}case"status-change":{let o=typeof t.from=="string"?t.from:"",i=typeof t.to=="string"?t.to:"";if(i){let r=typeof t.statusMessage=="string"?t.statusMessage:void 0,a=o?`${o} \u2192 ${i}`:i,l=r?`${a} \u2014 ${r}`:a;this.parent.pushConsoleMessage({type:"status",text:l,isStatus:!0,rawData:t,expandableContent:JSON.stringify(t,null,2)})}break}case"config-change":{let o=t.update,i=o&&typeof o=="object"?Object.keys(o).join(", "):"unknown";this.parent.pushConsoleMessage({type:"info",text:`Config updated: ${i}`,rawData:t,expandableContent:JSON.stringify(t,null,2)});break}case"error":{let o=typeof t.message=="string"?t.message:"Unknown error";this.parent.pushConsoleMessage({type:"error",text:o,rawData:t,expandableContent:JSON.stringify(t,null,2)}),s&&n(new Error(`CC Session error: ${o}`),"cc-session-event");break}case"usage-update":{this.accumulateUsage(t);break}case"cli-chunk":{this.handleCliChunkEvent(t);break}case"runner-overflow":{let i=`Runner buffer overflow: ${typeof t.droppedCount=="number"?t.droppedCount:0} output items lost during server disconnect`;this.parent.pushConsoleMessage({type:"error",text:i,rawData:t,expandableContent:JSON.stringify(t,null,2)});break}case"interrupted-prompt":{let o=typeof t.reason=="string"?t.reason:"",i=typeof t.lastPrompt=="string"?t.lastPrompt:"",r=i.length>80?i.substring(0,80)+"\u2026":i,a=r?`Prompt interrupted (${o}): "${r}"`:`Prompt interrupted${o?" ("+o+")":""}`;this.parent.pushConsoleMessage({type:"status",text:a,isStatus:!0,rawData:t,expandableContent:JSON.stringify(t,null,2)});break}case"session-init":{let o=typeof t.model=="string"?t.model:"",i=typeof t.claudeCodeVersion=="string"?t.claudeCodeVersion:"",r=typeof t.permissionMode=="string"?t.permissionMode:"",a=[];o&&a.push(o),r&&a.push(r),i&&a.push(`v${i}`);let l=a.length>0?`CLI init: ${a.join(" \xB7 ")}`:"CLI initialized",c=JSON.stringify(t,null,2);this.parent.pushConsoleMessage({type:"info",text:l,rawData:t,expandableContent:c});break}case"config-mismatch":{let o=t.mismatches,i=Array.isArray(o)?o.map(r=>`${r.field}: requested "${r.requested}" \u2192 actual "${r.actual}"`).join(", "):"unknown mismatch";this.parent.pushConsoleMessage({type:"error",text:`Config mismatch: ${i}`,rawData:t,expandableContent:JSON.stringify(t,null,2)});break}case"cli-args-record":{let o=typeof t.model=="string"?t.model:"default",i=typeof t.reasoningEffort=="string"?t.reasoningEffort:"default",r=typeof t.mode=="string"?t.mode:"normal",a=typeof t.permissionPolicy=="string"?t.permissionPolicy:"default",l=`CLI spawn: model=${o} \xB7 effort=${i} \xB7 mode=${r} \xB7 permission=${a}`;this.parent.pushConsoleMessage({type:"info",text:l,rawData:t,expandableContent:JSON.stringify(t,null,2)});break}case"stdout-line":case"stderr-line":break;default:{let o=e.eventType;this.parent.pushConsoleMessage({type:"raw",text:o,rawData:t});break}}}handleStatusUpdate(e){let s=e.sessionId??"",n=e.status??"",t=e.statusMessage;this.parent.lastStatusUpdate_$.set({sessionId:s,status:n,statusMessage:t});let i=this.parent.sessions_$().map(a=>a.sessionId===s?f(h({},a),{status:n,statusMessage:t}):a);this.parent.sessions_$.set(i);let r=this.parent.selectedSession_$();if(r?.session.sessionId===s){let a=u.isLiveCcSessionStatus(n);this.parent.selectedSession_$.set(f(h({},r),{session:f(h({},r.session),{status:n,statusMessage:t}),runtime:f(h({},r.runtime),{isLive:a,runtimeStatus:n})}))}if(n==="errored"){let a=(t??"").trim();if(a.startsWith("Auto-recovery: terminal runner dropped silently")||a.startsWith("Exit code:"))M.DyFM_Log.warn(`CCAP_CcSession | user-task-fail diagnostic (NOT recorded to /errors) | sessionId: ${s} | statusMessage: ${a}`);else{let c=t?`CC Session error (${s}): ${t}`:`CC Session error (${s}): session entered errored state`;this.parent.showGlobalError(new Error(c),"cc-session-status")}}this.parent.evaluateSessionEventsPolling()}handleOutputChunk(e){let s=e.sessionId??"";if(s&&s!==this.parent.activeSessionId_$())return;let n=e.content??"",t=e.type??"stdout",o=this.parent.liveOutput_$(),i=n.split(`
1
+ import{a as R,b as O}from"./chunk-FIFTZWSX.js";import{a as q}from"./chunk-2KAMFUG2.js";import{a as g}from"./chunk-UFBTR2BG.js";import{a as U}from"./chunk-6YS7CV3D.js";import{e as P}from"./chunk-TKWKAUHK.js";import{h as y,j as L}from"./chunk-V7QPXZIU.js";import{p as D}from"./chunk-IZZTOAKP.js";import{C as v,R as T,a as h,aa as p,b as f,h as E,k as d,y as A}from"./chunk-TBMJSIBB.js";var S=E(D());var _=class u{static compareAsc(C,e){let s=(C.sequence??0)-(e.sequence??0);if(s!==0)return s;let n=typeof C.timestamp=="string"?C.timestamp:"",t=typeof e.timestamp=="string"?e.timestamp:"",o=n.localeCompare(t);if(o!==0)return o;let i=typeof C.messageKey=="string"?C.messageKey:"",r=typeof e.messageKey=="string"?e.messageKey:"";return i.localeCompare(r)}static sortAsc(C){return[...C].sort(u.compareAsc)}};var M=E(D());var x=(()=>{class u{parent;agentToolUseIds=new Set;activeSubAgentId="";toolUseIdToName=new Map;init(e){this.parent=e}resetTrackingState(){this.toolUseIdToName.clear(),this.agentToolUseIds.clear(),this.activeSubAgentId=""}handleSocketEvent(e,s){let n=e.event,t=e.payload;try{let o=typeof t.ccapId=="string"?t.ccapId:"";if(n!=="cc:rate-limit-update"&&n!=="ext-session-msg:message"&&n!=="ext-session-msg:update"&&o&&s.selectedCcapId&&o!==s.selectedCcapId){M.DyFM_Log.info(`CCAP_CcSession_DS | socket event dropped by instance filter | event: ${n} | eventCcapId: ${o} | selectedCcapId: ${s.selectedCcapId}`);return}switch(n){case"cc-session:status":this.handleStatusUpdate(t);break;case"cc-session:output":this.handleOutputChunk(t);break;case"cc-session:event":this.handleSessionEvent(t);break;case"cc-session:list-update":this.handleListUpdate(t);break;case"cc-session:session-update":this.handleSessionItemUpdate(t);break;case"agent-events":this.handleAgentEvent(t);break;case"ext-session-msg:message":this.handleAssembledMessage(t);break;case"ext-session-msg:update":this.handleAssembledMessageUpdate(t);break;case"cc:rate-limit-update":this.handleRateLimitBroadcast(t);break}}catch(o){let i=o instanceof Error?o.message:String(o);M.DyFM_Log.error(`CCAP_CcSession_DS | socket event error | event: ${n}`,o),s.globalErrorShowError(o instanceof Error?o:new Error(`CC Session socket event processing failed: ${n} \u2014 ${i}`),"cc-session-socket-event")}}pushConsoleMessageFromEvent(e,s,n){let t=e.data;switch(e.eventType){case"response-chunk":{this.pushResponseChunkBlocks(t);break}case"tool-call-start":{let o=t.name??t.tool_name??"unknown",i=typeof t.id=="string"?t.id:"";i&&this.toolUseIdToName.set(i,o),o==="Agent"&&i&&this.agentToolUseIds.add(i);let r=t.input,a=r?u.summarizeToolInput(r):"",l=a?`${o}: ${a}`:o,c=o==="Edit"?u.buildEditExpandableContent(r):void 0,m=o==="Agent"?"":this.activeSubAgentId;this.parent.pushConsoleMessage({type:"tool",text:l,expandableContent:c,rawData:t,parentAgentId:m||void 0});break}case"tool-call-end":{let o=t.content??t.output,i=typeof o=="string"?o:"",r=i.length>200?i.substring(0,200)+"\u2026":i;if(r){let a=i.length>200?i:void 0;this.parent.pushConsoleMessage({type:"tool-result",text:r,expandableContent:a,rawData:t,parentAgentId:this.activeSubAgentId||void 0})}break}case"response-complete":{this.activeSubAgentId="";let o=t.cost_usd,i=typeof o=="number"?` ($${o.toFixed(4)})`:"",r=typeof t.model=="string"?` \xB7 ${t.model}`:"";this.parent.pushConsoleMessage({type:"result",text:`Response complete${r}${i}`,rawData:t,expandableContent:JSON.stringify(t,null,2)}),this.accumulateUsage(t);break}case"prompt-sent":{let o=typeof t.content=="string"?t.content:"";o&&(this.parent.consoleMessages_$().some(a=>a.type==="prompt"&&a.text===o.trim())||this.parent.pushConsoleMessage({type:"prompt",text:o,rawData:t,expandableContent:JSON.stringify(t,null,2)}));break}case"status-change":{let o=typeof t.from=="string"?t.from:"",i=typeof t.to=="string"?t.to:"";if(i){let r=typeof t.statusMessage=="string"?t.statusMessage:void 0,a=o?`${o} \u2192 ${i}`:i,l=r?`${a} \u2014 ${r}`:a;this.parent.pushConsoleMessage({type:"status",text:l,isStatus:!0,rawData:t,expandableContent:JSON.stringify(t,null,2)})}break}case"config-change":{let o=t.update,i=o&&typeof o=="object"?Object.keys(o).join(", "):"unknown";this.parent.pushConsoleMessage({type:"info",text:`Config updated: ${i}`,rawData:t,expandableContent:JSON.stringify(t,null,2)});break}case"error":{let o=typeof t.message=="string"?t.message:"Unknown error";this.parent.pushConsoleMessage({type:"error",text:o,rawData:t,expandableContent:JSON.stringify(t,null,2)}),s&&n(new Error(`CC Session error: ${o}`),"cc-session-event");break}case"usage-update":{this.accumulateUsage(t);break}case"cli-chunk":{this.handleCliChunkEvent(t);break}case"runner-overflow":{let i=`Runner buffer overflow: ${typeof t.droppedCount=="number"?t.droppedCount:0} output items lost during server disconnect`;this.parent.pushConsoleMessage({type:"error",text:i,rawData:t,expandableContent:JSON.stringify(t,null,2)});break}case"interrupted-prompt":{let o=typeof t.reason=="string"?t.reason:"",i=typeof t.lastPrompt=="string"?t.lastPrompt:"",r=i.length>80?i.substring(0,80)+"\u2026":i,a=r?`Prompt interrupted (${o}): "${r}"`:`Prompt interrupted${o?" ("+o+")":""}`;this.parent.pushConsoleMessage({type:"status",text:a,isStatus:!0,rawData:t,expandableContent:JSON.stringify(t,null,2)});break}case"session-init":{let o=typeof t.model=="string"?t.model:"",i=typeof t.claudeCodeVersion=="string"?t.claudeCodeVersion:"",r=typeof t.permissionMode=="string"?t.permissionMode:"",a=[];o&&a.push(o),r&&a.push(r),i&&a.push(`v${i}`);let l=a.length>0?`CLI init: ${a.join(" \xB7 ")}`:"CLI initialized",c=JSON.stringify(t,null,2);this.parent.pushConsoleMessage({type:"info",text:l,rawData:t,expandableContent:c});break}case"config-mismatch":{let o=t.mismatches,i=Array.isArray(o)?o.map(r=>`${r.field}: requested "${r.requested}" \u2192 actual "${r.actual}"`).join(", "):"unknown mismatch";this.parent.pushConsoleMessage({type:"error",text:`Config mismatch: ${i}`,rawData:t,expandableContent:JSON.stringify(t,null,2)});break}case"cli-args-record":{let o=typeof t.model=="string"?t.model:"default",i=typeof t.reasoningEffort=="string"?t.reasoningEffort:"default",r=typeof t.mode=="string"?t.mode:"normal",a=typeof t.permissionPolicy=="string"?t.permissionPolicy:"default",l=`CLI spawn: model=${o} \xB7 effort=${i} \xB7 mode=${r} \xB7 permission=${a}`;this.parent.pushConsoleMessage({type:"info",text:l,rawData:t,expandableContent:JSON.stringify(t,null,2)});break}case"stdout-line":case"stderr-line":break;default:{let o=e.eventType;this.parent.pushConsoleMessage({type:"raw",text:o,rawData:t});break}}}handleStatusUpdate(e){let s=e.sessionId??"",n=e.status??"",t=e.statusMessage;this.parent.lastStatusUpdate_$.set({sessionId:s,status:n,statusMessage:t});let i=this.parent.sessions_$().map(a=>a.sessionId===s?f(h({},a),{status:n,statusMessage:t}):a);this.parent.sessions_$.set(i);let r=this.parent.selectedSession_$();if(r?.session.sessionId===s){let a=u.isLiveCcSessionStatus(n);this.parent.selectedSession_$.set(f(h({},r),{session:f(h({},r.session),{status:n,statusMessage:t}),runtime:f(h({},r.runtime),{isLive:a,runtimeStatus:n})}))}if(n==="errored"){let a=(t??"").trim();if(a.startsWith("Auto-recovery: terminal runner dropped silently")||a.startsWith("Exit code:"))M.DyFM_Log.warn(`CCAP_CcSession | user-task-fail diagnostic (NOT recorded to /errors) | sessionId: ${s} | statusMessage: ${a}`);else{let c=t?`CC Session error (${s}): ${t}`:`CC Session error (${s}): session entered errored state`;this.parent.showGlobalError(new Error(c),"cc-session-status")}}this.parent.evaluateSessionEventsPolling()}handleOutputChunk(e){let s=e.sessionId??"";if(s&&s!==this.parent.activeSessionId_$())return;let n=e.content??"",t=e.type??"stdout",o=this.parent.liveOutput_$(),i=n.split(`
2
2
  `),r=3e3;if(t==="stderr"){let c=new Set(this.parent.liveStderrLines_$()),m=o.length;for(let b=0;b<i.length;b++)c.add(m+b);this.parent.liveStderrLines_$.set(c)}let l=[...o,...i];if(l.length>r){let c=l.length-r,m=l.slice(c),b=this.parent.liveStderrLines_$(),I=new Set;for(let w of b){let $=w-c;$>=0&&I.add($)}this.parent.liveStderrLines_$.set(I),this.parent.liveOutput_$.set(m)}else this.parent.liveOutput_$.set(l)}handleSessionEvent(e){let s=e.sessionId??"";if(s&&s!==this.parent.activeSessionId_$())return;let n=e.event??{},t={sessionId:s,eventType:n.eventType??"",timestamp:n.timestamp??"",data:n.data??{},sequence:n.sequence??0,eventSource:typeof n.eventSource=="string"?n.eventSource:void 0};if(t.sequence<=this.parent.getLastKnownEventSequence())return;this.parent.setLastKnownEventSequence(t.sequence);let o=this.parent.selectedSessionEvents_$();this.parent.selectedSessionEvents_$.set([...o,t]),this.pushConsoleMessageFromEvent(t,!0,(i,r)=>{this.parent.showGlobalError(i,r)})}handleAgentEvent(e){let s=typeof e.phase=="string"?e.phase:void 0;if(s)switch(s){case g.runInitialization:this.parent.pushConsoleMessage({type:"status",text:"RUN initialization",isStatus:!0});break;case g.analyze:this.parent.pushConsoleMessage({type:"status",text:"Analyzing incoming message",isStatus:!0});break;case g.analyzeResult:{let n=typeof e.runIntent=="string"?e.runIntent:"";n&&this.parent.pushConsoleMessage({type:"run-intent",text:n,isStatus:!1});break}case g.assemble:this.parent.pushConsoleMessage({type:"status",text:"Refreshing Context",isStatus:!0});break;case g.executionStart:this.parent.pushConsoleMessage({type:"status",text:"Starting Agent",isStatus:!0});break;case g.llmAgenticLoop:this.parent.pushConsoleMessage({type:"status",text:"Selecting next move",isStatus:!0});break;case g.agenticLoopIteration:{let n=typeof e.action=="string"?e.action:"",t=typeof e.tool=="string"?e.tool:"",o=typeof e.intent=="string"?e.intent:"",i=[];n&&i.push(n),t&&i.push(t),o&&i.push(o);let r=i.join(" \xB7 ");r&&this.parent.pushConsoleMessage({type:"iteration",text:r,isStatus:!1});break}case g.llmToolDescription:this.parent.pushConsoleMessage({type:"status",text:"Assembling tool inputs",isStatus:!0});break;case g.llmToolErrorRetry:this.parent.pushConsoleMessage({type:"status",text:"Figuring out what's wrong",isStatus:!0});break;case g.toolErrorRetry:this.parent.pushConsoleMessage({type:"status",text:"Trying to fix inputs",isStatus:!0});break;case g.executionEnd:this.parent.pushConsoleMessage({type:"status",text:"Finishing run",isStatus:!0});break;case g.finalization:case g.llmRunFinalization:this.parent.pushConsoleMessage({type:"status",text:"Gathering what we've done",isStatus:!0});break;case g.postFinalization:this.parent.pushConsoleMessage({type:"status",text:"Memorizing stuff",isStatus:!0});break;case g.runFlowComplete:this.parent.pushConsoleMessage({type:"status",text:"Getting back to user",isStatus:!0});break}}handleRateLimitBroadcast(e){let s=e.rate_limit_info;if(!s||typeof s!="object")return;let n=s,t={status:typeof n.status=="string"?n.status:"",resetsAt:typeof n.resetsAt=="number"?n.resetsAt:0,rateLimitType:typeof n.rateLimitType=="string"?n.rateLimitType:"",utilization:typeof n.utilization=="number"?n.utilization:0,surpassedThreshold:typeof n.surpassedThreshold=="number"?n.surpassedThreshold:0,isUsingOverage:n.isUsingOverage===!0,receivedAt:new Date().toISOString()};this.parent.rateLimitInfo_$.set(t)}handleListUpdate(e){let s=e.sessions??[],o=[...this.parent.sessions_$().some(i=>i.isArchived===!0)?s:s.filter(i=>!i.isArchived)].sort((i,r)=>{let a=i.lastActivityAt?new Date(i.lastActivityAt).getTime():0;return(r.lastActivityAt?new Date(r.lastActivityAt).getTime():0)-a});this.parent.sessions_$.set(o),this.mergeActiveSessionDetail(s)}handleSessionItemUpdate(e){let s=typeof e.sessionId=="string"?e.sessionId:"";if(!s)return;let n=typeof e.update=="object"&&e.update!==null?e.update:{},o=this.parent.sessions_$().map(r=>r.sessionId!==s?r:u.applySessionFieldUpdate(r,n));this.parent.sessions_$.set(o);let i=this.parent.selectedSession_$();i?.session.sessionId===s&&this.parent.selectedSession_$.set(f(h({},i),{session:u.applySessionFieldUpdate(i.session,n)}))}static applySessionFieldUpdate(e,s){let n=h({},e);return typeof s.toolCallCountIncrement=="number"&&(n.toolCallCount=(n.toolCallCount??0)+s.toolCallCountIncrement),typeof s.promptCountIncrement=="number"&&(n.promptCount=(n.promptCount??0)+s.promptCountIncrement),typeof s.inputTokensIncrement=="number"&&(n.inputTokensTotal=(n.inputTokensTotal??0)+s.inputTokensIncrement),typeof s.outputTokensIncrement=="number"&&(n.outputTokensTotal=(n.outputTokensTotal??0)+s.outputTokensIncrement),typeof s.costUsdIncrement=="number"&&(n.costUsdTotal=(n.costUsdTotal??0)+s.costUsdIncrement),typeof s.status=="string"&&(n.status=s.status),(typeof s.statusMessage=="string"||s.statusMessage===void 0)&&(n.statusMessage=s.statusMessage),typeof s.lastActivityAt=="string"&&(n.lastActivityAt=s.lastActivityAt),typeof s.lastPrompt=="string"&&(n.lastPrompt=s.lastPrompt),typeof s.activeModel=="string"&&(n.activeModel=s.activeModel),n}mergeActiveSessionDetail(e){let s=this.parent.activeSessionId_$();if(!s)return;let n=this.parent.selectedSession_$();if(!n)return;let t=e.find(o=>o.sessionId===s);t&&this.parent.selectedSession_$.set(f(h({},n),{session:h(h({},n.session),t)}))}handleAssembledMessage(e){let s=typeof e.sessionId=="string"?e.sessionId:"",n=this.parent.activeSessionId_$();if(!s||s!==n)return;let t=e.message;if(!t||typeof t!="object"){M.DyFM_Log.warn("CCAP_CcSession_DS | handleAssembledMessage dropped: invalid message payload",{sessionId:s,payloadKeys:Object.keys(e)});return}let o=t,i=this.parent.assembledMessages_$(),r=typeof o.messageKey=="string"?o.messageKey:"";r&&i.some(a=>a.messageKey===r)||this.parent.assembledMessages_$.set(_.sortAsc([...i,o]))}handleAssembledMessageUpdate(e){let s=typeof e.sessionId=="string"?e.sessionId:"";if(!s||s!==this.parent.activeSessionId_$())return;let n=typeof e.messageKey=="string"?e.messageKey:"";if(!n)return;let t=e.update;if(!t||typeof t!="object")return;let o=t,i=this.parent.assembledMessages_$(),r=i.findIndex(c=>c.messageKey===n);if(r<0)return;let a=h({},i[r]);typeof o.bodyText=="string"&&(a.bodyText=o.bodyText),o.toolResult!==void 0&&(a.toolResult=o.toolResult),typeof o.toolStatus=="string"&&(a.toolStatus=o.toolStatus),o.headerStatusDot!==void 0&&(a.headerStatusDot=typeof o.headerStatusDot=="string"?o.headerStatusDot:void 0);let l=[...i];l[r]=a,this.parent.assembledMessages_$.set(l)}handleCliChunkEvent(e){let s=typeof e.type=="string"?e.type:"";if(s==="rate_limit_event"){let n=e.rate_limit_info;if(n&&typeof n=="object"){let t=n,o={status:typeof t.status=="string"?t.status:"",resetsAt:typeof t.resetsAt=="number"?t.resetsAt:0,rateLimitType:typeof t.rateLimitType=="string"?t.rateLimitType:"",utilization:typeof t.utilization=="number"?t.utilization:0,surpassedThreshold:typeof t.surpassedThreshold=="number"?t.surpassedThreshold:0,isUsingOverage:t.isUsingOverage===!0,receivedAt:new Date().toISOString()};this.parent.rateLimitInfo_$.set(o)}return}if(s==="system"){this.handleCliChunkSystemEvent(e);return}this.handleCliChunkToolResults(e)||this.parent.pushConsoleMessage({type:"raw",text:s||"cli-chunk",rawData:e})}handleCliChunkSystemEvent(e){let s=typeof e.subtype=="string"?e.subtype:"",n=typeof e.description=="string"?e.description:u.buildSystemEventBrief({subtype:s,data:e}),t=typeof e.tool_use_id=="string"?e.tool_use_id:"";t&&this.agentToolUseIds.has(t)&&(this.activeSubAgentId=t);let o=t&&this.agentToolUseIds.has(t)?t:this.activeSubAgentId||void 0,i=typeof e.last_tool_name=="string"?e.last_tool_name:"";if(s==="task_progress"&&i){this.parent.pushConsoleMessage({type:"tool",text:`${i}: ${n}`,isStatus:!1,rawData:e,parentAgentId:o});return}this.parent.pushConsoleMessage({type:"status-update",text:n,subtype:s,isStatus:!1,rawData:e,parentAgentId:o})}pushResponseChunkBlocks(e){let s=e.message,n=s&&typeof s=="object"?s.content:e.content;if(Array.isArray(n)){for(let t of n){if(!t||typeof t!="object")continue;let o=t,i=typeof o.type=="string"?o.type:"";if(i==="text"){let r=typeof o.text=="string"?o.text:"";r&&(this.activeSubAgentId="",this.parent.pushConsoleMessage({type:"assistant",text:r,rawData:e}))}else if(i==="tool_use")this.handleResponseChunkToolUse(o,e);else if(i==="tool_result")this.handleResponseChunkToolResult(o);else if(i==="thinking"){let r=typeof o.thinking=="string"?o.thinking:"";r&&this.parent.pushConsoleMessage({type:"thinking",text:r,rawData:o,parentAgentId:this.activeSubAgentId||void 0})}else i&&this.parent.pushConsoleMessage({type:"raw",text:i,rawData:o})}return}if(typeof n=="string"&&n){this.parent.pushConsoleMessage({type:"assistant",text:n,rawData:e});return}this.parent.pushConsoleMessage({type:"raw",text:"response-chunk",rawData:e})}handleResponseChunkToolUse(e,s){let n=typeof e.name=="string"?e.name:"unknown",t=typeof e.id=="string"?e.id:"";t&&this.toolUseIdToName.set(t,n),n==="Agent"&&t&&this.agentToolUseIds.add(t);let o=e.input,i=o?u.summarizeToolInput(o):"",r=i?`${n}: ${i}`:n,a=n==="Edit"?u.buildEditExpandableContent(o):void 0,l=n==="Agent"?"":this.activeSubAgentId;this.parent.pushConsoleMessage({type:"tool",text:r,expandableContent:a,rawData:e,parentAgentId:l||void 0})}handleResponseChunkToolResult(e){let s=typeof e.tool_use_id=="string"?e.tool_use_id:"",n=s&&this.agentToolUseIds.has(s)?s:this.activeSubAgentId||"",t=e.content??e.output,o=typeof t=="string"?t:"",i=o.length>200?o.substring(0,200)+"\u2026":o||"tool_result";this.parent.pushConsoleMessage({type:"tool-result",text:i,expandableContent:o.length>200?o:void 0,rawData:e,parentAgentId:n||void 0})}handleCliChunkToolResults(e){if((typeof e.type=="string"?e.type:"")!=="user")return!1;let n=e.message,t=n&&typeof n=="object"?n.content:null;if(!Array.isArray(t))return!1;let o=typeof e.parent_tool_use_id=="string"?e.parent_tool_use_id:"",i=!1;for(let r of t){if(!r||typeof r!="object")continue;let a=r,l=typeof a.type=="string"?a.type:"";if(l==="tool_result"){let c=typeof a.tool_use_id=="string"?a.tool_use_id:"",m=c?this.toolUseIdToName.get(c)??"":"",b=a.content,I=typeof b=="string"?b:"",w=a.is_error===!0,$=m?`${m}: `:"",k=I.length>200?I.substring(0,200)+"\u2026":I||"tool result",F=w?`${$}ERROR \u2014 ${k}`:`${$}${k}`;this.parent.pushConsoleMessage({type:"tool-result",text:F,expandableContent:I.length>200?I:void 0,rawData:f(h({},a),{parent_tool_use_id:o||void 0}),parentAgentId:o||void 0}),i=!0}else if(l==="text"&&o){let c=typeof a.text=="string"?a.text:"";if(c){let m=c.length>200?c.substring(0,200)+"\u2026":c;this.parent.pushConsoleMessage({type:"tool-result",text:m,expandableContent:c.length>200?c:void 0,rawData:{tool_use_id:o,type:"sub-agent-prompt",text:c},parentAgentId:o}),i=!0}}}return i}static isLiveCcSessionStatus(e){return e==="running"||e==="waiting-input"||e==="starting"}static buildSystemEventBrief(e){switch(e.subtype){case"init":{let s=typeof e.data.cwd=="string"?e.data.cwd:"",n=typeof e.data.model=="string"?e.data.model:"",t=["init"];return s&&t.push(s),n&&t.push(n),t.join(" \xB7 ")}case"task_updated":{let s=e.data.patch,n=s&&typeof s=="object"&&typeof s.status=="string"?s.status:"";return n?`task ${n}`:"task updated"}case"task_notification":{let s=typeof e.data.status=="string"?e.data.status:"";return s?`task ${s}`:"task notification"}default:return e.subtype||"system"}}static buildEditExpandableContent(e){if(!e||typeof e!="object")return;let s=e,n=s.old_string,t=s.new_string;if(typeof n!="string"||typeof t!="string")return;let o=500,i=n.length>o?n.substring(0,o)+"\u2026":n,r=t.length>o?t.substring(0,o)+"\u2026":t;return JSON.stringify({old:i,new:r})}static summarizeToolInput(e){if(typeof e=="string")return e.length>120?e.substring(0,120)+"\u2026":e;if(e&&typeof e=="object"){let s=e,n=s.file_path??s.path,t=s.command,o=s.pattern;if(typeof n=="string")return n;if(typeof t=="string")return t.length>120?t.substring(0,120)+"\u2026":t;if(typeof o=="string")return o}return""}accumulateUsage(e){let s=e.usage,n=typeof e.cost_usd=="number"?e.cost_usd:0,t=0,o=0;if(s&&typeof s=="object"){let r=s;t=typeof r.input_tokens=="number"?r.input_tokens:typeof r.promptTokens=="number"?r.promptTokens:0,o=typeof r.output_tokens=="number"?r.output_tokens:typeof r.completionTokens=="number"?r.completionTokens:0}let i=this.parent.sessionUsage_$();this.parent.sessionUsage_$.set({promptTokens:i.promptTokens+t,completionTokens:i.completionTokens+o,totalTokens:i.totalTokens+t+o,costUsd:i.costUsd+n})}static \u0275fac=function(s){return new(s||u)};static \u0275prov=A({token:u,factory:u.\u0275fac,providedIn:"root"})}return u})();var ne=(()=>{class u{sessions_$=p([]);sessionsLoading_$=p(!1);sessionsLoadError_$=p(null);selectedSession_$=p(null);selectedSessionLoading_$=p(!1);selectedSessionEvents_$=p([]);liveOutput_$=p([]);liveStderrLines_$=p(new Set);consoleMessages_$=p([]);assembledMessages_$=p([]);assembledMessagesHasMore_$=p(!1);isLoadingOlderMessages_$=p(!1);assembledMessagesLoaded_$=p(!1);lastStatusUpdate_$=p(null);sessionUsage_$=p({promptTokens:0,completionTokens:0,totalTokens:0,costUsd:0});rateLimitInfo_$=p(null);activeSessionId_$=p("");ccSession_AS=v(R);extSessionMsg_AS=v(q);globalError_CS=v(L);socket_CS=v(P);ngZone=v(T);peiContext_DS=v(U);socketEventHandler_CS=v(x);eventSubscription=null;reconnectSubscription=null;lastKnownEventSequence=-1;static SESSION_EVENTS_POLL_INTERVAL_MS=5*S.second;sessionEventsPollHandle=null;isSessionEventsPollInFlight=!1;constructor(){this.socketEventHandler_CS.init(this),this.eventSubscription=this.socket_CS.event$.subscribe(e=>{this.ngZone.run(()=>{this.socketEventHandler_CS.handleSocketEvent(e,{selectedCcapId:this.peiContext_DS.activeCcapId_$(),globalErrorShowError:(s,n)=>{this.globalError_CS.showError(s,n)}})})}),this.reconnectSubscription=this.socket_CS.connected$.subscribe(e=>{if(!e)return;let s=this.activeSessionId_$();s&&(this.socket_CS.emit("cc-session:subscribe",{sessionId:s}),this.loadAssembledMessages({sessionId:s}).catch(()=>{}),this.loadSessionDetail({sessionId:s}).catch(()=>{})),this.loadSessions().catch(()=>{}),this.backfillMissedEvents()})}ngOnDestroy(){this.stopSessionEventsPolling(),this.eventSubscription&&(this.eventSubscription.unsubscribe(),this.eventSubscription=null),this.reconnectSubscription&&(this.reconnectSubscription.unsubscribe(),this.reconnectSubscription=null)}showGlobalError(e,s){this.globalError_CS.showError(e,s)}getLastKnownEventSequence(){return this.lastKnownEventSequence}setLastKnownEventSequence(e){this.lastKnownEventSequence=e}evaluateSessionEventsPolling(){let e=this.activeSessionId_$(),s=this.resolveActiveSessionStatusForEventsPolling();!!(e&&this.lastKnownEventSequence>=0&&s!=null&&x.isLiveCcSessionStatus(s))?this.ensureSessionEventsPollingStarted():this.stopSessionEventsPolling()}loadSessions(e){return d(this,null,function*(){this.sessionsLoading_$.set(!0),this.sessionsLoadError_$.set(null);try{let n=[...(yield this.ccSession_AS.listSessions({status:e?.status,workspacePath:e?.workspacePath,includeArchived:e?.includeArchived})).sessions].sort((t,o)=>{let i=t.lastActivityAt?new Date(t.lastActivityAt).getTime():0;return(o.lastActivityAt?new Date(o.lastActivityAt).getTime():0)-i});this.sessions_$.set(n)}catch(s){this.sessionsLoadError_$.set(s)}finally{this.sessionsLoading_$.set(!1)}})}loadPersistedRateLimitState(e){return d(this,null,function*(){let s=e.ccapId?.trim()??"";if(s)try{let n=yield this.ccSession_AS.getRateLimitState({ccapId:s});this.mergePersistedRateLimitState(n.items)}catch(n){S.DyFM_Log.warn(`ClaudeCode_DS | loadPersistedRateLimitState failed (non-blocking) | ccapId: ${s} | ${n instanceof Error?n.message:String(n)}`)}})}mergePersistedRateLimitState(e){if(this.rateLimitInfo_$()!==null)return;let s=O.mapServerItemsToClientInfo(e);s!==null&&this.rateLimitInfo_$.set(s)}loadSessionDetail(e){return d(this,null,function*(){this.selectedSessionLoading_$.set(!0);try{let s=yield this.ccSession_AS.getSession({sessionId:e.sessionId}),n=this.activeSessionId_$();if(n&&n!==e.sessionId){S.DyFM_Log.info(`CCAP_CcSession_DS | loadSessionDetail stale response \u2014 discarded | requestedSessionId: ${e.sessionId} | currentActiveSessionId: ${n}`);return}this.selectedSession_$.set(s)}catch(s){let n=this.activeSessionId_$();if(n&&n!==e.sessionId)return;this.selectedSession_$.set(null);let t=s instanceof Error?s.message:"Failed to load session details";this.pushConsoleMessage({type:"error",text:`Load session failed: ${t}`})}finally{this.selectedSessionLoading_$.set(!1),this.evaluateSessionEventsPolling()}})}loadSessionEvents(e){return d(this,null,function*(){try{let s=yield this.ccSession_AS.getSessionEvents({sessionId:e.sessionId,eventType:e.eventType,limit:e.limit??500,latest:!0}),n=this.activeSessionId_$();if(n&&n!==e.sessionId){S.DyFM_Log.info(`CCAP_CcSession_DS | loadSessionEvents stale response \u2014 discarded | requestedSessionId: ${e.sessionId} | currentActiveSessionId: ${n}`);return}this.selectedSessionEvents_$.set(s.events),this.updateLastKnownSequence(s.events);for(let t of s.events)this.socketEventHandler_CS.pushConsoleMessageFromEvent(t,!1,(o,i)=>{this.globalError_CS.showError(o,i)});this.loadAssembledMessages({sessionId:e.sessionId}).catch(()=>{})}catch{let n=this.activeSessionId_$();if(n&&n!==e.sessionId)return;this.selectedSessionEvents_$.set([])}finally{this.evaluateSessionEventsPolling()}})}createSession(e){return d(this,null,function*(){try{let s=yield this.ccSession_AS.createSession(e),n=String(s.session.sessionId||"");return yield this.loadSessions(),n}catch(s){throw this.pushConsoleMessage({type:"error",text:`Create session failed: ${y.getErrorMessageForDisplay(s)}`}),s}})}sendPrompt(e){return d(this,null,function*(){let s=e.attachments?.filter(n=>n.isImage&&!!n.base64).map(n=>`data:${n.mimeType};base64,${n.base64}`);this.pushConsoleMessage({type:"prompt",text:e.content,imageDataUrls:s?.length?s:void 0});try{let n=yield this.ccSession_AS.sendPrompt(e);n.relayed&&(n.targetOnline?this.pushConsoleMessage({type:"info",text:`Prompt relayed to remote instance (task: ${n.taskId?.substring(0,8)}\u2026)`}):this.pushConsoleMessage({type:"error",text:`\u26A0 A t\xE1voli instance jelenleg offline \u2014 a prompt queue-ban v\xE1rakozik (task: ${n.taskId?.substring(0,8)}\u2026) \xE9s csak akkor k\xE9zbes\xEDt\u0151dik, ha a target instance online lesz. Ellen\u0151rizd, hogy mindk\xE9t instance fut, \xE9s a Settings \u2192 Cluster sharedSecret azonos.`})),this.evaluateSessionEventsPolling()}catch(n){throw this.pushConsoleMessage({type:"error",text:`Send failed: ${y.getErrorMessageForDisplay(n)}`}),this.globalError_CS.showError(n,"CC Session sendPrompt"),n}})}forkSession(e){return d(this,null,function*(){try{let s=yield this.ccSession_AS.forkSession({sessionId:e.sessionId,label:e.label}),n=String(s.session.sessionId||"");return yield this.loadSessions(),n}catch(s){throw this.pushConsoleMessage({type:"error",text:`Fork session failed: ${y.getErrorMessageForDisplay(s)}`}),s}})}resumeSession(e){return d(this,null,function*(){try{let s=yield this.ccSession_AS.resumeSession(e);s.relayed&&this.pushConsoleMessage({type:"info",text:s.targetOnline?"Resume relayed to remote instance":"Resume queued for offline remote instance"}),yield this.loadSessions()}catch(s){throw this.pushConsoleMessage({type:"error",text:`Resume failed: ${y.getErrorMessageForDisplay(s)}`}),s}})}stopExecution(e){return d(this,null,function*(){try{let s=yield this.ccSession_AS.stopExecution(e);if(s.relayed){this.pushSystemAssembledMessage({sessionId:e.sessionId,text:s.targetOnline?"Stop execution relayed to remote instance":"Stop execution queued for offline remote instance",role:"info"});return}let n=s.message||"Execution stopped";this.pushSystemAssembledMessage({sessionId:e.sessionId,text:n,role:"info"})}catch(s){throw this.pushSystemAssembledMessage({sessionId:e.sessionId,text:`Stop execution failed: ${y.getErrorMessageForDisplay(s)}`,role:"error"}),s}})}terminateSession(e){return d(this,null,function*(){try{let s=yield this.ccSession_AS.terminateSession(e);s.relayed?this.pushSystemAssembledMessage({sessionId:e.sessionId,text:s.targetOnline?"Terminate relayed to remote instance":"Terminate queued for offline remote instance",role:"info"}):this.pushSystemAssembledMessage({sessionId:e.sessionId,text:"Session terminated",role:"status"}),yield this.loadSessions()}catch(s){throw this.pushSystemAssembledMessage({sessionId:e.sessionId,text:`Terminate failed: ${y.getErrorMessageForDisplay(s)}`,role:"error"}),s}})}restartRunner(e){return d(this,null,function*(){try{let s=yield this.ccSession_AS.restartRunner(e);this.pushSystemAssembledMessage({sessionId:e.sessionId,text:`Runner restarted (new terminalId: ${s.newTerminalId.slice(0,8)}\u2026). New terminal window should open shortly.`,role:"info"})}catch(s){throw this.pushSystemAssembledMessage({sessionId:e.sessionId,text:`Runner restart failed: ${y.getErrorMessageForDisplay(s)}`,role:"error"}),s}})}setSessionArchived(e){return d(this,null,function*(){try{yield this.ccSession_AS.setSessionArchived(e),yield this.loadSessions()}catch(s){throw this.pushConsoleMessage({type:"error",text:`Archive failed: ${y.getErrorMessageForDisplay(s)}`}),s}})}updateSessionConfig(e){return d(this,null,function*(){try{yield this.ccSession_AS.updateSessionConfig(e);let s=this.selectedSession_$();if(s?.session.sessionId===e.sessionId){let n=h({},s.session);e.label!=null&&(n.label=e.label),e.mode!=null&&(n.mode=e.mode),e.permissionPolicy!=null&&(n.permissionPolicy=e.permissionPolicy),e.reasoningEffort!=null&&(n.reasoningEffort=e.reasoningEffort),e.model!=null&&(n.model=e.model),e.isDebugMode!=null&&(n.isDebugMode=e.isDebugMode),this.selectedSession_$.set(f(h({},s),{session:n}))}if(e.label!=null){let n=this.sessions_$(),t=n.findIndex(o=>o.sessionId===e.sessionId);if(t>=0){let o=[...n];o[t]=f(h({},o[t]),{label:e.label}),this.sessions_$.set(o)}}}catch(s){throw this.pushConsoleMessage({type:"error",text:`Config update failed: ${y.getErrorMessageForDisplay(s)}`}),s}})}setActiveSessionId(e){let s=this.activeSessionId_$();s!==e&&this.stopSessionEventsPolling(),s&&s!==e&&this.socket_CS.emit("cc-session:unsubscribe",{sessionId:s}),this.activeSessionId_$.set(e),e&&this.socket_CS.emit("cc-session:subscribe",{sessionId:e})}clearLiveOutput(){this.stopSessionEventsPolling(),this.liveOutput_$.set([]),this.liveStderrLines_$.set(new Set),this.consoleMessages_$.set([]),this.assembledMessages_$.set([]),this.assembledMessagesHasMore_$.set(!1),this.isLoadingOlderMessages_$.set(!1),this.assembledMessagesLoaded_$.set(!1),this.selectedSession_$.set(null),this.selectedSessionEvents_$.set([]),this.lastStatusUpdate_$.set(null),this.sessionUsage_$.set({promptTokens:0,completionTokens:0,totalTokens:0,costUsd:0}),this.lastKnownEventSequence=-1,this.socketEventHandler_CS.resetTrackingState()}pushConsoleMessage(e){let s=e.type==="assistant"||e.type==="prompt"?e.text.trim():e.text,n={listKey:e.listKey??this.allocateConsoleListKey(),type:e.type,text:s,timestamp:e.timestamp??new Date().toISOString(),isStatus:e.isStatus??!1,expandableContent:e.expandableContent,rawData:e.rawData,subtype:e.subtype,parentAgentId:e.parentAgentId,imageDataUrls:e.imageDataUrls},t=this.consoleMessages_$();this.consoleMessages_$.set([...t,n])}loadAssembledMessages(e){return d(this,null,function*(){try{let s=yield this.extSessionMsg_AS.getMessages({sessionId:e.sessionId,latest:!0}),n=this.activeSessionId_$();if(n&&n!==e.sessionId){S.DyFM_Log.info(`CCAP_CcSession_DS | loadAssembledMessages stale \u2014 discarded | requestedSessionId: ${e.sessionId} | currentActiveSessionId: ${n} | restMessageCount: ${s.messages.length}`);return}let t=this.assembledMessages_$(),o=new Set(s.messages.map(r=>r.messageKey).filter(r=>typeof r=="string"&&r.length>0)),i=t.filter(r=>!o.has(r.messageKey));this.assembledMessages_$.set(_.sortAsc([...s.messages,...i])),this.assembledMessagesHasMore_$.set(s.hasMore)}catch(s){S.DyFM_Log.error(`CCAP_CcSession_DS | loadAssembledMessages failed | sessionId: ${e.sessionId}`,s)}finally{this.assembledMessagesLoaded_$.set(!0)}})}loadOlderAssembledMessages(e){return d(this,null,function*(){if(this.isLoadingOlderMessages_$()||!this.assembledMessagesHasMore_$())return;let s=this.assembledMessages_$();if(!s.length)return;let n=s.reduce((t,o)=>(o.sequence??0)<t?o.sequence??0:t,s[0].sequence??0);this.isLoadingOlderMessages_$.set(!0);try{let t=yield this.extSessionMsg_AS.getMessages({sessionId:e.sessionId,beforeSequence:n,limit:e.limit??50});t.messages.length&&this.assembledMessages_$.set(_.sortAsc([...t.messages,...s])),this.assembledMessagesHasMore_$.set(t.hasMore)}catch(t){S.DyFM_Log.error(`CCAP_CcSession_DS | loadOlderAssembledMessages failed | sessionId: ${e.sessionId}`,t)}finally{this.isLoadingOlderMessages_$.set(!1)}})}pushSystemAssembledMessage(e){let s=this.assembledMessages_$(),n=s.length?s.reduce((o,i)=>(i.sequence??0)>o?i.sequence??0:o,0):0,t={messageKey:`sys-${Date.now()}-${Math.random().toString(36).slice(2,8)}`,sessionId:e.sessionId,sessionType:"cc",messageRole:e.role,bodyText:e.text,timestamp:new Date().toISOString(),sequence:n+1};this.assembledMessages_$.set(_.sortAsc([...s,t])),this.pushConsoleMessage({type:e.role==="error"?"error":e.role==="status"?"status":"info",text:e.text,isStatus:e.role==="status"})}allocateConsoleListKey(){return globalThis.crypto.randomUUID()}pullEventsSinceLastKnownSequence(e){return d(this,null,function*(){let s=this.activeSessionId_$();if(!(!s||this.lastKnownEventSequence<0))try{let t=(yield this.ccSession_AS.getSessionEvents({sessionId:s,sinceSequence:this.lastKnownEventSequence})).events;if(!t.length)return;this.ngZone.run(()=>{let o=this.activeSessionId_$();if(o!==s){S.DyFM_Log.info(`CCAP_CcSession_DS | pull(${e}) stale \u2014 discarded | requestedSessionId: ${s} | currentActiveSessionId: ${o} | newEventCount: ${t.length}`);return}let i=this.selectedSessionEvents_$();this.selectedSessionEvents_$.set([...i,...t]);for(let r of t)this.socketEventHandler_CS.pushConsoleMessageFromEvent(r,!0,(a,l)=>{this.globalError_CS.showError(a,l)});this.updateLastKnownSequence(t)})}catch(n){let t=e==="poll"?"session events poll failed":"backfill failed";S.DyFM_Log.warn(`CCAP_CcSession_DS | ${t}`,n)}})}backfillMissedEvents(){return d(this,null,function*(){yield this.pullEventsSinceLastKnownSequence("backfill")})}updateLastKnownSequence(e){for(let s of e)s.sequence>this.lastKnownEventSequence&&(this.lastKnownEventSequence=s.sequence)}resolveActiveSessionStatusForEventsPolling(){let e=this.activeSessionId_$();if(!e)return null;let s=this.selectedSession_$();if(s?.session.sessionId===e)return s.session.status;let n=this.lastStatusUpdate_$();return n?.sessionId===e?n.status:this.sessions_$().find(o=>o.sessionId===e)?.status??null}ensureSessionEventsPollingStarted(){this.sessionEventsPollHandle===null&&(this.sessionEventsPollHandle=setInterval(()=>{this.onSessionEventsPollTick()},u.SESSION_EVENTS_POLL_INTERVAL_MS))}stopSessionEventsPolling(){this.sessionEventsPollHandle!==null&&(clearInterval(this.sessionEventsPollHandle),this.sessionEventsPollHandle=null),this.isSessionEventsPollInFlight=!1}onSessionEventsPollTick(){return d(this,null,function*(){if(!this.isSessionEventsPollInFlight){this.isSessionEventsPollInFlight=!0;try{yield this.pullEventsSinceLastKnownSequence("poll");let e=this.activeSessionId_$();e&&(yield this.loadAssembledMessages({sessionId:e}))}finally{this.isSessionEventsPollInFlight=!1}}})}static \u0275fac=function(s){return new(s||u)};static \u0275prov=A({token:u,factory:u.\u0275fac,providedIn:"root"})}return u})();export{ne as a};
3
- //# sourceMappingURL=chunk-6ZJOH7NF.js.map
3
+ //# sourceMappingURL=chunk-4ZYMYI5W.js.map
@@ -1,2 +1,2 @@
1
- import{b as c}from"./chunk-ZRXTZHMM.js";import{I as d,p as h}from"./chunk-PYVALWHU.js";import{C as l,aa as o,h as u,k as r,y as s}from"./chunk-TBMJSIBB.js";var e=function(t){return t.idle="idle",t.downloading="downloading",t.installing="installing",t.completed="completed",t.failed="failed",t}(e||{});var p=u(h());function m(){return typeof window.Capacitor<"u"&&window.Capacitor.isNativePlatform?.()===!0}function w(){let a=window.Capacitor?.Plugins?.AppUpdater;return a||null}var y=(()=>{class t{versionCheck_CS=l(c);downloadUrl=d.api.baseUrl+"/mobile/download";phase_$=o(e.idle);lastError_$=o("");startUpdate(){return r(this,null,function*(){let n=this.phase_$();if(!(n===e.downloading||n===e.installing)){this.lastError_$.set(""),this.phase_$.set(e.downloading);try{let i=w();if(i){this.phase_$.set(e.installing),yield i.downloadAndInstall({downloadUrl:this.downloadUrl}),this.phase_$.set(e.completed);return}this.openInSystemBrowser(this.downloadUrl),this.phase_$.set(e.completed)}catch(i){let f=i instanceof Error?i.message:String(i);this.lastError_$.set(f),this.phase_$.set(e.failed),p.DyFM_Error.logSimple("CCAP_MobileAppUpdater | startUpdate failed",i)}}})}autoUpdateIfAvailable(){return r(this,null,function*(){m()&&(yield this.versionCheck_CS.checkNow(),this.versionCheck_CS.updateAvailable_$()&&(yield this.startUpdate()))})}openInSystemBrowser(n){window.open(n,"_system")}static \u0275fac=function(i){return new(i||t)};static \u0275prov=s({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();export{e as a,y as b};
2
- //# sourceMappingURL=chunk-AQ7GMTGO.js.map
1
+ import{b as c}from"./chunk-ZED36DG7.js";import{I as d,p as h}from"./chunk-IZZTOAKP.js";import{C as l,aa as o,h as u,k as r,y as s}from"./chunk-TBMJSIBB.js";var e=function(t){return t.idle="idle",t.downloading="downloading",t.installing="installing",t.completed="completed",t.failed="failed",t}(e||{});var p=u(h());function m(){return typeof window.Capacitor<"u"&&window.Capacitor.isNativePlatform?.()===!0}function w(){let a=window.Capacitor?.Plugins?.AppUpdater;return a||null}var y=(()=>{class t{versionCheck_CS=l(c);downloadUrl=d.api.baseUrl+"/mobile/download";phase_$=o(e.idle);lastError_$=o("");startUpdate(){return r(this,null,function*(){let n=this.phase_$();if(!(n===e.downloading||n===e.installing)){this.lastError_$.set(""),this.phase_$.set(e.downloading);try{let i=w();if(i){this.phase_$.set(e.installing),yield i.downloadAndInstall({downloadUrl:this.downloadUrl}),this.phase_$.set(e.completed);return}this.openInSystemBrowser(this.downloadUrl),this.phase_$.set(e.completed)}catch(i){let f=i instanceof Error?i.message:String(i);this.lastError_$.set(f),this.phase_$.set(e.failed),p.DyFM_Error.logSimple("CCAP_MobileAppUpdater | startUpdate failed",i)}}})}autoUpdateIfAvailable(){return r(this,null,function*(){m()&&(yield this.versionCheck_CS.checkNow(),this.versionCheck_CS.updateAvailable_$()&&(yield this.startUpdate()))})}openInSystemBrowser(n){window.open(n,"_system")}static \u0275fac=function(i){return new(i||t)};static \u0275prov=s({token:t,factory:t.\u0275fac,providedIn:"root"})}return t})();export{e as a,y as b};
2
+ //# sourceMappingURL=chunk-55SU72FF.js.map