@qredence/fleet 0.7.4 → 0.9.0

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 (227) hide show
  1. package/CHANGELOG.md +48 -0
  2. package/README.md +5 -4
  3. package/bin/fleet-prime.mjs +33 -6
  4. package/bin/prime-runtime.mjs +79 -0
  5. package/dist/runtime-manifest.json +32 -0
  6. package/dist/web/client/assets/DialogTitle-BlVq-tcv.js +1 -0
  7. package/dist/web/client/assets/FloatingPortal-D8-EPDs2.js +1 -0
  8. package/dist/web/client/assets/activity-BPIKUzOU.js +1 -0
  9. package/dist/web/client/assets/agents-CGjUBYX7.js +2 -0
  10. package/dist/web/client/assets/agents-page-CTuFJL9H.js +1 -0
  11. package/dist/web/client/assets/alert-CzWGeumf.js +1 -0
  12. package/dist/web/client/assets/alert-dialog-D-e1Pr4q.js +1 -0
  13. package/dist/web/client/assets/arrow-up-right-CG9RNk4p.js +1 -0
  14. package/dist/web/client/assets/artifacts-panel-6JEdy6jU.js +1 -0
  15. package/dist/web/client/assets/badge-CzQFgmVK.js +1 -0
  16. package/dist/web/client/assets/button-CWYjn8Zk.js +1 -0
  17. package/dist/web/client/assets/{card-Hngi3HGC.js → card-Dj1SnGUU.js} +1 -1
  18. package/dist/web/client/assets/chat-command-palette-Bxr5EkO6.js +1 -0
  19. package/dist/web/client/assets/chat-hpzV6IA6.js +57 -0
  20. package/dist/web/client/assets/chat-queries-CfZiupub.js +3 -0
  21. package/dist/web/client/assets/clock-3-BwWCSCm_.js +1 -0
  22. package/dist/web/client/assets/code-block-pKKmFZ5w.js +3 -0
  23. package/dist/web/client/assets/collapsible-Bk6zCsRX.js +1 -0
  24. package/dist/web/client/assets/{command-CmtCIDdH.js → command-xo-NK4xO.js} +1 -1
  25. package/dist/web/client/assets/connectors-CFxLqG2x.js +2 -0
  26. package/dist/web/client/assets/connectors-page-DQJdoAnl.js +1 -0
  27. package/dist/web/client/assets/create-project-dialog-Db-WhUmP.js +1 -0
  28. package/dist/web/client/assets/createBaseUIEventDetails-DIxvaz-Y.js +1 -0
  29. package/dist/web/client/assets/dialog-CK8dym6z.js +1 -0
  30. package/dist/web/client/assets/eye-iNSvs0UA.js +1 -0
  31. package/dist/web/client/assets/file-code-corner-BkDULqko.js +1 -0
  32. package/dist/web/client/assets/{fork-picker-dialog-DfGlB17w.js → fork-picker-dialog-DSaFeUii.js} +1 -1
  33. package/dist/web/client/assets/globals-DJhWyayo.css +2 -0
  34. package/dist/web/client/assets/index-C9FHZDGw.js +13 -0
  35. package/dist/web/client/assets/input-CBoTMPC_.js +1 -0
  36. package/dist/web/client/assets/{input-group-EPMGh55u.js → input-group-BFubAtz9.js} +1 -1
  37. package/dist/web/client/assets/{ipython-tool-CMhnRVrC.js → ipython-tool-bieUhw9K.js} +1 -1
  38. package/dist/web/client/assets/markdown-CvBfbPCn.js +2 -0
  39. package/dist/web/client/assets/markdown-code-rFOkzN5N.js +4 -0
  40. package/dist/web/client/assets/mcp-connections-section-DEo6Kemv.js +2 -0
  41. package/dist/web/client/assets/message-queue-Btjt9wK2.js +1 -0
  42. package/dist/web/client/assets/{model-selector-list-BiU_7ivt.js → model-selector-list-CbDAT0Rw.js} +1 -1
  43. package/dist/web/client/assets/mutation-Da9zdeWr.js +1 -0
  44. package/dist/web/client/assets/notify-BIL0-CGy.js +1 -0
  45. package/dist/web/client/assets/open-panel-action-message-SdA1VU42.js +1 -0
  46. package/dist/web/client/assets/openui-renderer-DG-iML7M.js +291 -0
  47. package/dist/web/client/assets/pencil-Cbgq3ybX.js +1 -0
  48. package/dist/web/client/assets/plus-DUP2JPVG.js +1 -0
  49. package/dist/web/client/assets/product-page-header-Ck6I13CE.js +1 -0
  50. package/dist/web/client/assets/{prompt-input-Dy-DSPqF.js → prompt-input-CoV1gTUQ.js} +1 -1
  51. package/dist/web/client/assets/{prompt-suggestions-CrpAiKeB.js → prompt-suggestions-CAY5JI-C.js} +1 -1
  52. package/dist/web/client/assets/provider-catalog-CLEDlH_v.js +1 -0
  53. package/dist/web/client/assets/provider-label-BItazQ6H.js +1 -0
  54. package/dist/web/client/assets/reasoning-line-DGdPUMwT.js +1 -0
  55. package/dist/web/client/assets/rehype-katex-DITkIpVl.js +259 -0
  56. package/dist/web/client/assets/{repl-panel-DN5kZAcB.js → repl-panel-5xgkDXO5.js} +1 -1
  57. package/dist/web/client/assets/{resources-panel-DD6iWOF3.js → resources-panel-aJCKt9eF.js} +1 -1
  58. package/dist/web/client/assets/right-panel-context-CjX-HkDO.js +1 -0
  59. package/dist/web/client/assets/right-panel-registry-BAJ6TuEY.js +2 -0
  60. package/dist/web/client/assets/rotate-ccw-DLkfsmG9.js +1 -0
  61. package/dist/web/client/assets/routes-ja_liP8Z.js +14 -0
  62. package/dist/web/client/assets/select-DYh951qi.js +1 -0
  63. package/dist/web/client/assets/session-activity-panel-DwaXiSrS.js +1 -0
  64. package/dist/web/client/assets/{session-insights-panel-D0v_DKcb.js → session-insights-panel-BXEmuJKf.js} +1 -1
  65. package/dist/web/client/assets/session-reasoning-panel-CjJJK_bq.js +1 -0
  66. package/dist/web/client/assets/session-tool-renderer-DEABxZG3.js +166 -0
  67. package/dist/web/client/assets/{session-tree-panel-BBwP_EK2.js → session-tree-panel-5QgMvXoX.js} +1 -1
  68. package/dist/web/client/assets/settings-dialog-DiikSLhF.js +1 -0
  69. package/dist/web/client/assets/shield-check-7HDd-2Fn.js +1 -0
  70. package/dist/web/client/assets/{skeleton-DNAr5ULI.js → skeleton-B_Lq2XFl.js} +1 -1
  71. package/dist/web/client/assets/{skeleton-loaders-B28mF4tJ.js → skeleton-loaders-DWc1eDL3.js} +1 -1
  72. package/dist/web/client/assets/sparkles-CASAe1AI.js +1 -0
  73. package/dist/web/client/assets/{spinner-CSBXk3Lo.js → spinner-B5TaKP7k.js} +1 -1
  74. package/dist/web/client/assets/{subagent-chat-panel-DhvBO4dQ.js → subagent-chat-panel-R2RoX1Yt.js} +1 -1
  75. package/dist/web/client/assets/subagent-transcript-DVZhMo7a.js +1 -0
  76. package/dist/web/client/assets/{subagents-panel-DRo8Xs6j.js → subagents-panel-CMMRUP8F.js} +1 -1
  77. package/dist/web/client/assets/surfaces-BUjUJTyD.js +1 -0
  78. package/dist/web/client/assets/switch-BrxDfsX6.js +1 -0
  79. package/dist/web/client/assets/toast-BNWkgZ0u.js +1 -0
  80. package/dist/web/client/assets/tool-output-normalizer-DDU09Zc6.js +4 -0
  81. package/dist/web/client/assets/tool-part-normalizer-CF6bmJ0s.js +4 -0
  82. package/dist/web/client/assets/tool-result-7qREIVv_.js +5 -0
  83. package/dist/web/client/assets/tool-timeline-CGhwMeNl.js +2 -0
  84. package/dist/web/client/assets/trace-IsV5RRvM.js +1 -0
  85. package/dist/web/client/assets/trash-sm2UyOxe.js +1 -0
  86. package/dist/web/client/assets/types-gIgIxnnG.js +1 -0
  87. package/dist/web/client/assets/ui-preferences-B-PNDkyY.js +1 -0
  88. package/dist/web/client/assets/use-hover-capable-CLq8BADD.js +1 -0
  89. package/dist/web/client/assets/useBaseUiId-lKfDDIcw.js +1 -0
  90. package/dist/web/client/assets/useButton-CvcmqA2s.js +1 -0
  91. package/dist/web/client/assets/useNavigate-CVhM7pag.js +1 -0
  92. package/dist/web/client/assets/useRender-CzJUrRlB.js +1 -0
  93. package/dist/web/client/assets/useScrollLock-BcsteNzT.js +1 -0
  94. package/dist/web/client/assets/{utils-CFDGLzf6.js → utils-oBThwhjm.js} +1 -1
  95. package/dist/web/client/assets/with-selector-B_VDO56x.js +1 -0
  96. package/dist/web/client/assets/{workspace-panel-DdZutYnd.js → workspace-panel-Da5I4p_t.js} +1 -1
  97. package/dist/web/client/assets/workspace-path-nav-D-77sJ_A.js +2 -0
  98. package/dist/web/client/assets/wrench-BXX_Ah2s.js +1 -0
  99. package/dist/web/client/bundle-budget.json +6 -6
  100. package/dist/web/server/_tanstack-start-manifest_v-B6ne-00G-OFX7UD4K.js +119 -0
  101. package/dist/web/server/agents-BwzqhPjK-ANFHE5AG.js +22 -0
  102. package/dist/web/server/agents-page-DEqPV-eG-BR5MR74O.js +215 -0
  103. package/dist/web/server/{artifacts-panel-COSC8o7j-GKW2HH2G.js → artifacts-panel-DLO8OfXb-B2ZWCDFP.js} +35 -29
  104. package/dist/web/server/{chat-command-palette-CuOWdzkk-PKZQ5EZP.js → chat-command-palette-CaDQAMAu-KDH7BTDS.js} +22 -15
  105. package/dist/web/server/chunk-2ETDIMNM.js +40 -0
  106. package/dist/web/server/{chunk-2VKVSL6Y.js → chunk-35RIM6VP.js} +128 -127
  107. package/dist/web/server/chunk-5IE54MRG.js +207 -0
  108. package/dist/web/server/{chunk-VUBITQ5X.js → chunk-5MOXRFX6.js} +180 -7
  109. package/dist/web/server/{chunk-6GTTTYSE.js → chunk-6AFVCERK.js} +72 -79
  110. package/dist/web/server/chunk-6GYLXDX3.js +588 -0
  111. package/dist/web/server/chunk-7DQQMT5V.js +8993 -0
  112. package/dist/web/server/chunk-APOS34PW.js +8965 -0
  113. package/dist/web/server/{chunk-BUKOEXE7.js → chunk-AXN2OBPF.js} +2 -4
  114. package/dist/web/server/{chunk-WCKKN5BR.js → chunk-B5FKCW75.js} +357 -910
  115. package/dist/web/server/chunk-BD7YKYWL.js +1007 -0
  116. package/dist/web/server/{chunk-36CAMOVG.js → chunk-BZ2EAUZZ.js} +10 -12
  117. package/dist/web/server/chunk-CE7U5QB2.js +42 -0
  118. package/dist/web/server/chunk-FNV3WZXL.js +125 -0
  119. package/dist/web/server/{chunk-GLSR4ZI2.js → chunk-FSQWWR2M.js} +698 -832
  120. package/dist/web/server/chunk-FT7HNDR5.js +143 -0
  121. package/dist/web/server/chunk-GNXIDE26.js +44 -0
  122. package/dist/web/server/{chunk-ORCOCCER.js → chunk-HAFELESQ.js} +5 -7
  123. package/dist/web/server/{chunk-LLO4MNGE.js → chunk-HUHUPGHT.js} +53 -45
  124. package/dist/web/server/{chunk-QSM3BRMA.js → chunk-KBMRRJQN.js} +256 -157
  125. package/dist/web/server/chunk-KDCSEISZ.js +6890 -0
  126. package/dist/web/server/chunk-KSGGSGOA.js +50 -0
  127. package/dist/web/server/chunk-PQVTLG3E.js +270 -0
  128. package/dist/web/server/{chunk-YU6RHHK6.js → chunk-Q4ECIATK.js} +65 -53
  129. package/dist/web/server/{chunk-IN2ATSEG.js → chunk-R4BS3KYI.js} +2 -4
  130. package/dist/web/server/chunk-RX2ZJARF.js +73 -0
  131. package/dist/web/server/{chunk-AKSDWYJY.js → chunk-SYS5FDNA.js} +5 -5
  132. package/dist/web/server/chunk-TOJA3X5N.js +421 -0
  133. package/dist/web/server/chunk-TQ2RECTH.js +193 -0
  134. package/dist/web/server/{chunk-KHHXJZK7.js → chunk-TTNONWZZ.js} +16001 -14668
  135. package/dist/web/server/chunk-TXZDDJCT.js +5115 -0
  136. package/dist/web/server/{chunk-XA7EOCHM.js → chunk-UDUG3MYZ.js} +2 -2
  137. package/dist/web/server/{chunk-EBC7QORX.js → chunk-V2GCVTDP.js} +5056 -12556
  138. package/dist/web/server/{chunk-TMQ3MT3D.js → chunk-VDEUVEWL.js} +2255 -1
  139. package/dist/web/server/chunk-VM3U6PUU.js +769 -0
  140. package/dist/web/server/connectors-C0xm91Ss-DJVBGD73.js +22 -0
  141. package/dist/web/server/connectors-page-B6tJNZ6c-R5K4NSAT.js +66 -0
  142. package/dist/web/server/{create-project-dialog-0-arQpsX-ZELQKHS5.js → create-project-dialog-PFPHHWIV-GH7JR5IK.js} +27 -18
  143. package/dist/web/server/{dist-7G2NZPF4.js → dist-GQUZLXN5.js} +2 -2
  144. package/dist/web/server/{dist-E5637ZAY.js → dist-MN5NWCX6.js} +1 -1
  145. package/dist/web/server/{fork-picker-dialog-fj9p33Mq-I5SA3GLJ.js → fork-picker-dialog-DFpKOdAw-JPLJSYYU.js} +7 -12
  146. package/dist/web/server/{markdown-CShfYRVO-RBTK7TRB.js → markdown-Cc8V9dOF-JTNTJKQU.js} +7 -5
  147. package/dist/web/server/{markdown-code-BDV_2b2T-6JYA5FWZ.js → markdown-code-gaRnbgNM-V5LIRYCD.js} +46 -8
  148. package/dist/web/server/{message-queue-BBC843IU-GY4ZIMM4.js → message-queue-nQ2_kU82-KKSLYR4S.js} +7 -16
  149. package/dist/web/server/{model-selector-list-DE6aLNXt-LJZMCYOI.js → model-selector-list-By_G7_Hr-GXT27BZO.js} +12 -16
  150. package/dist/web/server/{openui-renderer-C3aqSKuS-PWLWJFYO.js → openui-renderer-B9D8-Av--LFZP4U5V.js} +20 -15
  151. package/dist/web/server/{prompt-suggestions-CpTK_fHV-UKJDTLVM.js → prompt-suggestions-B67Uy5Rk-5SMTSIFQ.js} +5 -4
  152. package/dist/web/server/{rehype-katex-IDPYWU6M.js → rehype-katex-CYHGKI6Q.js} +490 -843
  153. package/dist/web/server/{repl-panel-1kSS1UGd-U64BPA7X.js → repl-panel-1kSS1UGd-POXRYDDJ.js} +2 -3
  154. package/dist/web/server/{resources-panel-DWb0eGKa-K4EM3H7Y.js → resources-panel-CTzOOKPz-5G6RS2D6.js} +18 -12
  155. package/dist/web/server/router-CnBux_Ld-YTVBMJFL.js +23 -0
  156. package/dist/web/server/routes-BUGzvQoO-WW43X7W2.js +124 -0
  157. package/dist/web/server/server.js +3 -3
  158. package/dist/web/server/session-activity-panel-f0d3fCm7-I6L5IKFQ.js +181 -0
  159. package/dist/web/server/{session-insights-panel-CfMX2NRu-6HWZTTAC.js → session-insights-panel-BiVObm_6-AP4FITT7.js} +2 -12
  160. package/dist/web/server/session-reasoning-panel-QIt_xjP0-FKJWMNHO.js +70 -0
  161. package/dist/web/server/session-tool-renderer-Cg_ZPHxS-BNQKNJNZ.js +34 -0
  162. package/dist/web/server/{session-tree-panel-HNl6R9VZ-4JUF34M7.js → session-tree-panel-B--el8O5-NZOZJM5L.js} +18 -13
  163. package/dist/web/server/{settings-dialog-DGZBA5Z_-6HYFMPNZ.js → settings-dialog-D_eJN2ia-W47Y474K.js} +104 -795
  164. package/dist/web/server/{subagent-chat-panel-DuB4hqUk-LDCAJOCL.js → subagent-chat-panel-C9nWP21E-D5C2TTYD.js} +22 -17
  165. package/dist/web/server/{subagents-panel-wAvx3-Rs-L6UTDFUX.js → subagents-panel-fAKvBNRG-O7QHXNE2.js} +26 -22
  166. package/dist/web/server/{workspace-panel-CPzJZwgv-YS7PTI5C.js → workspace-panel-CZMNMU63-SYOSM3B7.js} +23 -17
  167. package/package.json +2 -2
  168. package/dist/web/client/assets/DialogTitle-D-zqaHvF.js +0 -1
  169. package/dist/web/client/assets/FloatingPortal-73ZRZeD9.js +0 -1
  170. package/dist/web/client/assets/action-swap-BcFwS6is.js +0 -1
  171. package/dist/web/client/assets/alert-dialog-DtXvVhsF.js +0 -1
  172. package/dist/web/client/assets/artifacts-panel-Bseg97yQ.js +0 -1
  173. package/dist/web/client/assets/badge-C--lf3bb.js +0 -57
  174. package/dist/web/client/assets/button-BJZe4vNJ.js +0 -1
  175. package/dist/web/client/assets/chat-command-palette-D_rm1r9d.js +0 -1
  176. package/dist/web/client/assets/chevron-up-CqeJYyZO.js +0 -1
  177. package/dist/web/client/assets/collapsible-DauSnbYp.js +0 -1
  178. package/dist/web/client/assets/create-project-dialog-m-9aoobN.js +0 -1
  179. package/dist/web/client/assets/createBaseUIEventDetails-DklXWq23.js +0 -1
  180. package/dist/web/client/assets/dialog-Ddouieuu.js +0 -1
  181. package/dist/web/client/assets/eye-Cs0lNChA.js +0 -1
  182. package/dist/web/client/assets/globals-C961mr-b.css +0 -2
  183. package/dist/web/client/assets/index-Bz5W4EOn.js +0 -13
  184. package/dist/web/client/assets/input-Def1xOZz.js +0 -1
  185. package/dist/web/client/assets/markdown-Big27m-v.js +0 -2
  186. package/dist/web/client/assets/markdown-code-7L4RiS50.js +0 -3
  187. package/dist/web/client/assets/message-queue-Bg2MiJHM.js +0 -1
  188. package/dist/web/client/assets/mutation-DOi2Qgfa.js +0 -1
  189. package/dist/web/client/assets/notify-DhtmUPfE.js +0 -1
  190. package/dist/web/client/assets/openui-renderer-MIB3JKYa.js +0 -291
  191. package/dist/web/client/assets/provider-label-B_vy60P0.js +0 -1
  192. package/dist/web/client/assets/rehype-katex-A4PtQgTX.js +0 -259
  193. package/dist/web/client/assets/right-panel-context-DHKWoetk.js +0 -1
  194. package/dist/web/client/assets/right-panel-registry-hKJN__3l.js +0 -2
  195. package/dist/web/client/assets/routes-C3h32Lj_.js +0 -16
  196. package/dist/web/client/assets/select-Buvv1tIo.js +0 -1
  197. package/dist/web/client/assets/session-reasoning-panel-DmEbXOrR.js +0 -1
  198. package/dist/web/client/assets/session-tool-renderer-Daol5fJw.js +0 -169
  199. package/dist/web/client/assets/settings-dialog-DYbx3xuq.js +0 -2
  200. package/dist/web/client/assets/sparkles-D_ANe-HY.js +0 -1
  201. package/dist/web/client/assets/subagent-transcript-Bx-rHni-.js +0 -1
  202. package/dist/web/client/assets/surfaces-B8xTOFeK.js +0 -1
  203. package/dist/web/client/assets/switch-CDfAwEvs.js +0 -1
  204. package/dist/web/client/assets/terminal-Ceucj7us.js +0 -1
  205. package/dist/web/client/assets/toast-9zXN-yVk.js +0 -1
  206. package/dist/web/client/assets/tool-part-normalizer-NbPs9kd1.js +0 -4
  207. package/dist/web/client/assets/tool-result-BccnO34D.js +0 -4
  208. package/dist/web/client/assets/tool-timeline-DlBZyd4j.js +0 -1
  209. package/dist/web/client/assets/types-D5hZ8IyV.js +0 -1
  210. package/dist/web/client/assets/ui-preferences-1YaENqef.js +0 -1
  211. package/dist/web/client/assets/use-hover-capable-MwFjBLZQ.js +0 -1
  212. package/dist/web/client/assets/workspace-path-nav-BRwuLsFl.js +0 -2
  213. package/dist/web/client/assets/wrench-BYnD147U.js +0 -1
  214. package/dist/web/server/_tanstack-start-manifest_v-YlngJGUa-YTWBGR7L.js +0 -93
  215. package/dist/web/server/chunk-2PAW6K4Q.js +0 -56
  216. package/dist/web/server/chunk-CHSKEU3V.js +0 -166
  217. package/dist/web/server/chunk-FB3UHLLN.js +0 -49
  218. package/dist/web/server/chunk-GLH2GWMG.js +0 -2182
  219. package/dist/web/server/chunk-OXEAXEWD.js +0 -13
  220. package/dist/web/server/chunk-SIJVVYQT.js +0 -234
  221. package/dist/web/server/chunk-UQV2NU63.js +0 -163
  222. package/dist/web/server/chunk-ZUZPJNLY.js +0 -25217
  223. package/dist/web/server/router-DZYr-9uT-AEXHEFXF.js +0 -31
  224. package/dist/web/server/routes-vYxWRhis-AAZ73SNP.js +0 -120
  225. package/dist/web/server/session-reasoning-panel-XXU2yIOW-XXCKHISS.js +0 -192
  226. package/dist/web/server/session-tool-renderer-Dtt74Mts-7YYNSWRV.js +0 -29
  227. package/dist/web/server/tool-timeline-BKWsrZHK-3LGCOTPH.js +0 -12
package/CHANGELOG.md CHANGED
@@ -1,5 +1,53 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.9.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 3643a31: Read provider credentials and auth status from `auth.json` instead of the SDK
8
+
9
+ Fleet now resolves provider credentials itself rather than through the stock
10
+ runtime's `AuthStorage` and `ModelRegistry`. Model discovery reads the stored key
11
+ from `auth.json` and falls back to the provider's environment variable in the
12
+ same order the runtime used. The provider list derives its "configured" state
13
+ from the credential file, so a key Fleet wrote a moment ago is visible
14
+ immediately instead of only after the runtime reloads its in-memory view.
15
+
16
+ This removes the SDK from the credential path. Resource discovery (skills,
17
+ prompts, themes, extensions) still uses the runtime's loader.
18
+ - 8b81e09: Run on Prime Agent's native runtime. Fleet now talks to the Prime Agent daemon directly instead of through the legacy TypeScript SDK, and reports a clear error when the installed daemon is not a compatible version. Fleet requires the Rust daemon: a TypeScript daemon that advertises the same protocol and schema revision is refused, because Fleet no longer carries a second adapter path for it.
19
+
20
+ Recover chat sessions automatically when an invalid stream event interrupts the browser stream. Replayed text and tool events now resume after a malformed reasoning frame, missing runtime reasoning indexes are normalized before they reach the browser, and steering mid-recovery no longer drops the replayed answer.
21
+
22
+ Improve Fleet's navigation for sessions, agents, and connectors, and retire legacy runtime recap and error surfaces. Keep the selected chat model across page reloads.
23
+ - 3eea057: Read MCP connections from the Prime Agent daemon, and stop calling the bundled SDK at runtime for provider and model metadata.
24
+
25
+ The MCP list now reflects whether a credential actually works, not merely whether one exists. Servers whose stored token had expired were previously shown as connected; those tokens are common, since OAuth refresh expires silently, so the pane could report a working integration that had not been usable for weeks. Fleet also now shows every server the runtime knows about, and marks which ones accept a pasted token.
26
+
27
+ Provider and thinking-level metadata come from Fleet's own catalog instead of the SDK's bundled model list, so the settings pane depends on the providers Fleet supports rather than on what that particular SDK build shipped.
28
+ - 2d0fb18: Edit Prime Agent settings and provider credentials from Fleet instead of being told to go to the terminal.
29
+
30
+ Settings and provider credentials are written to the files Prime Agent reads, using a locked atomic write that never leaves a half-written file and keeps credential files owner-only. Settings that Fleet does not model survive a save, grouped settings such as retry merge field by field, and a file Fleet cannot parse is left untouched rather than replaced. Saving a resource setting reloads the runtime; changing model routing takes effect on the next session.
31
+
32
+ Providers that only had a stored credential, with no entry in the engine catalog, were missing from Settings entirely and could not be reviewed or removed. They now appear, while MCP connections stay out of the provider list.
33
+
34
+ ## 0.8.0
35
+
36
+ ### Minor Changes
37
+
38
+ - ad6e714: Align conversation activity and code blocks with shadcn patterns, and show available runtime reasoning in conversation traces.
39
+ - ad6e714: Organize agent activity into compact traces and a session Activity tab, with clearer tool output and subagent messages.
40
+ - ef95640: Fleet now provisions the pinned Prime Agent Rust runtime on first launch, verifies the downloaded platform archive and executable checksums, and launches the web UI against that Rust daemon by default.
41
+
42
+ ### Patch Changes
43
+
44
+ - 848b7ca: Map Prime Agent daemon socket frames onto the `ChatStreamEvent` contract in the web server, and read RLM child session headers read-only instead of opening them through the SDK session manager.
45
+ - 2c58710: Web server: add a daemon client for the Prime Agent Rust v0.10.1 daemon (protocol types, socket client, runtime wiring in prime-bridge).
46
+ - d2a7bb9: Route Fleet's remaining Prime Agent v0.9.8 SDK config and transcript access through one temporary legacy bridge, read session transcripts without ever rewriting them, and drop Fleet's duplicate IPython kernel prewarm (the runtime provisions its own kernel). `GET /api/health` no longer reports `kernel`.
47
+ - ad6e714: Redact credentials in activity traces, preserve assistant child reports, improve tool and artifact activity, and handle runtime startup and downloads safely.
48
+ - ad6e714: Handle runtime startup failures and stalled downloads, redact authorization and URL credentials in activity traces, and correct transcript content, artifact placement, downloads, and accessible tool controls.
49
+ - 8487dc6: Remove unreachable web UI code: unused exports, dead helpers, and the unused assistant-ui shadcn registry entry. No behavior change.
50
+
3
51
  ## 0.7.4
4
52
 
5
53
  ### Patch Changes
package/README.md CHANGED
@@ -2,10 +2,11 @@
2
2
 
3
3
  Fleet Prime Agent is Qredence's persistent local workspace for coding and
4
4
  research with AI: a multi-project web chat built on the upstream
5
- [Prime Agent](https://github.com/PrimeIntellect-ai/prime-agent) engine. The
6
- engine is installed as a checksum-pinned dependency and never modified; Fleet
7
- adds the web interface, workspace navigation, streaming tool cards, and
8
- managed IPython kernels.
5
+ [Prime Agent](https://github.com/PrimeIntellect-ai/prime-agent) engine. Fleet
6
+ provisions the pinned Prime Agent Rust runtime on first launch after verifying
7
+ the upstream archive and executable SHA-256 checksums; it never modifies the
8
+ engine. Fleet adds the web interface, workspace navigation, streaming tool
9
+ cards, and managed REPL integration.
9
10
 
10
11
  ## Install
11
12
 
@@ -2,11 +2,21 @@
2
2
 
3
3
  import { spawn } from "node:child_process";
4
4
  import { existsSync } from "node:fs";
5
- import { dirname, resolve } from "node:path";
5
+ import { readFile } from "node:fs/promises";
6
+ import { resolve } from "node:path";
6
7
  import { fileURLToPath } from "node:url";
8
+ import { ensurePrimeRuntime } from "./prime-runtime.mjs";
7
9
 
8
- const packageRoot = resolve(dirname(fileURLToPath(import.meta.resolve("prime-agent"))), "..");
10
+ const packagedManifestPath = fileURLToPath(new URL("../dist/runtime-manifest.json", import.meta.url));
11
+ const sourceManifestPath = fileURLToPath(new URL("../../../PRIME_AGENT_RUNTIME.json", import.meta.url));
12
+ const runtimeManifestPath = existsSync(packagedManifestPath) ? packagedManifestPath : sourceManifestPath;
9
13
  const launcher = fileURLToPath(new URL("../dist/web/launcher.mjs", import.meta.url));
14
+ const isAgentCommand = process.argv[2] === "agent";
15
+ const nativeBinary =
16
+ isAgentCommand || existsSync(launcher)
17
+ ? process.env.FLEET_PRIME_AGENT_BIN ||
18
+ (await ensurePrimeRuntime({ manifest: JSON.parse(await readFile(runtimeManifestPath, "utf8")) }))
19
+ : undefined;
10
20
  const sourceRoot = resolve(fileURLToPath(new URL("../../..", import.meta.url)));
11
21
  const sourceWebApp = resolve(sourceRoot, "web", "app");
12
22
  const viteCli = resolve(sourceRoot, "web", "app", "node_modules", "vite", "bin", "vite.js");
@@ -21,7 +31,11 @@ const workspaceRoot = process.cwd();
21
31
  function run(entrypoint, args, cwd) {
22
32
  const child = spawn(process.execPath, [entrypoint, ...args], {
23
33
  cwd,
24
- env: { ...process.env, PRIME_AGENT_WORKSPACE_ROOT: workspaceRoot },
34
+ env: {
35
+ ...process.env,
36
+ PRIME_AGENT_WORKSPACE_ROOT: workspaceRoot,
37
+ ...(nativeBinary ? { FLEET_PRIME_AGENT_BIN: nativeBinary } : {}),
38
+ },
25
39
  stdio: "inherit",
26
40
  });
27
41
  const forwardSignal = (signal) => {
@@ -36,10 +50,23 @@ function run(entrypoint, args, cwd) {
36
50
  }
37
51
 
38
52
  if (process.argv[2] === "agent") {
39
- const cli = resolve(packageRoot, "dist", "bundle", "cli.js");
40
- run(cli, process.argv.slice(3));
53
+ const args = process.argv.slice(3);
54
+ const child = spawn(nativeBinary, args, { cwd: workspaceRoot, env: process.env, stdio: "inherit" });
55
+ child.on("error", (error) => {
56
+ console.error(
57
+ error.code === "ENOENT"
58
+ ? `Prime Agent binary not found: ${nativeBinary}`
59
+ : `Could not start Prime Agent binary ${nativeBinary}: ${error.code ?? error.message}`,
60
+ );
61
+ process.exitCode = 1;
62
+ });
63
+ for (const signal of ["SIGINT", "SIGTERM"]) process.once(signal, () => child.kill(signal));
64
+ child.on("exit", (code, signal) => {
65
+ if (signal) process.kill(process.pid, signal);
66
+ else process.exitCode = code ?? 1;
67
+ });
41
68
  } else if (existsSync(launcher)) {
42
- run(launcher, process.argv.slice(2));
69
+ run(launcher, process.argv.slice(2), workspaceRoot);
43
70
  } else if (existsSync(viteCli)) {
44
71
  console.warn("Fleet Prime production bundle is not built; starting the source web server.");
45
72
  run(viteCli, ["dev", ...process.argv.slice(2)], sourceWebApp);
@@ -0,0 +1,79 @@
1
+ import { spawnSync } from "node:child_process";
2
+ import { createHash } from "node:crypto";
3
+ import { chmod, mkdir, mkdtemp, open, rename, rm, writeFile } from "node:fs/promises";
4
+ import { arch, homedir, platform } from "node:os";
5
+ import { dirname, join } from "node:path";
6
+
7
+ export function runtimeTarget(os = platform(), cpu = arch()) {
8
+ const target = `${os}-${cpu}`;
9
+ if (!["darwin-arm64", "darwin-x64", "linux-arm64", "linux-x64"].includes(target)) {
10
+ throw new Error(
11
+ `Fleet's Rust Prime Agent runtime does not support ${target}; supported targets: darwin-arm64, darwin-x64, linux-arm64, linux-x64.`,
12
+ );
13
+ }
14
+ return target;
15
+ }
16
+
17
+ export async function ensurePrimeRuntime({
18
+ manifest,
19
+ installRoot,
20
+ home = homedir(),
21
+ fetch: fetchImpl = fetch,
22
+ target = runtimeTarget(),
23
+ }) {
24
+ const runtime = manifest.rust;
25
+ const asset = runtime?.platforms?.[target];
26
+ if (!asset) throw new Error(`Fleet has no pinned Prime Agent runtime for ${target}`);
27
+ const destination = installRoot ?? join(home, ".prime", "fleet", "runtimes", runtime.version, target);
28
+ const executable = join(destination, "prime-agent");
29
+ if (await matchesDigest(executable, asset.executableSha256)) return executable;
30
+
31
+ await mkdir(dirname(destination), { recursive: true, mode: 0o700 });
32
+ const staging = await mkdtemp(join(dirname(destination), ".fleet-prime-runtime-"));
33
+ try {
34
+ const archivePath = join(staging, asset.archive);
35
+ // The release URL comes from Fleet's shipped runtime pin, never session or provider input.
36
+ const response = await fetchImpl(`${runtime.baseUrl}/${asset.archive}`, {
37
+ signal: AbortSignal.timeout(120_000),
38
+ });
39
+ if (!response.ok)
40
+ throw new Error(
41
+ `Could not download Prime Agent ${runtime.version} (${response.status}). Check your network and retry.`,
42
+ );
43
+ const archive = Buffer.from(await response.arrayBuffer());
44
+ if (digest(archive) !== asset.sha256)
45
+ throw new Error(`Prime Agent ${runtime.version} archive checksum mismatch; refusing to install it.`);
46
+ // Only checksum-verified release bytes reach this private staging file.
47
+ await writeFile(archivePath, archive, { mode: 0o600 });
48
+ const unpacked = join(staging, "unpacked");
49
+ await mkdir(unpacked);
50
+ const result = spawnSync("tar", ["-xzf", archivePath, "-C", unpacked], { encoding: "utf8" });
51
+ if (result.status !== 0)
52
+ throw new Error(`Could not extract Prime Agent runtime: ${result.stderr || "tar failed"}`);
53
+ if (!(await matchesDigest(join(unpacked, "prime-agent"), asset.executableSha256))) {
54
+ throw new Error("Extracted Prime Agent executable checksum mismatch; refusing to install it.");
55
+ }
56
+ await chmod(join(unpacked, "prime-agent"), 0o755);
57
+ await mkdir(destination, { recursive: true, mode: 0o700 });
58
+ await rename(join(unpacked, "prime-agent"), executable);
59
+ return executable;
60
+ } finally {
61
+ await rm(staging, { recursive: true, force: true });
62
+ }
63
+ }
64
+
65
+ async function matchesDigest(path, expected) {
66
+ let file;
67
+ try {
68
+ file = await open(path, "r");
69
+ return (await file.stat()).isFile() && digest(await file.readFile()) === expected;
70
+ } catch {
71
+ return false;
72
+ } finally {
73
+ await file?.close();
74
+ }
75
+ }
76
+
77
+ function digest(value) {
78
+ return createHash("sha256").update(value).digest("hex");
79
+ }
@@ -0,0 +1,32 @@
1
+ {
2
+ "package": "prime-agent",
3
+ "version": "0.9.8",
4
+ "tarball": "https://pub-728493de92a943e2a9b2d17b4719f318.r2.dev/releases/v0.9.8/prime-agent-0.9.8.tgz",
5
+ "sha256": "d7b72785119efc28bfbca8ec4a7f47a1fcdcf47fcd8cebdb60bffaa79e3e1274",
6
+ "rust": {
7
+ "version": "0.10.1",
8
+ "baseUrl": "https://pub-728493de92a943e2a9b2d17b4719f318.r2.dev/releases/v0.10.1",
9
+ "platforms": {
10
+ "darwin-arm64": {
11
+ "archive": "prime-agent-0.10.1-darwin-arm64.tar.gz",
12
+ "sha256": "2b47bd9cefa0b531151aaeb7295073ba0a16cf694177c18b4f9f74a54b24e279",
13
+ "executableSha256": "d96a650b2eb526141ac6e2e68d3d1fad694b8ba3988f0b312572e461bc167e32"
14
+ },
15
+ "darwin-x64": {
16
+ "archive": "prime-agent-0.10.1-darwin-x64.tar.gz",
17
+ "sha256": "9e2812084acead5a2c44209ffac350f762da67a27f4abcc5b417b7a6ef436632",
18
+ "executableSha256": "7b5d5d0770d6c0d7800ada77b74219b4505109026e1bd0de3eb4df73bb6cb4ae"
19
+ },
20
+ "linux-arm64": {
21
+ "archive": "prime-agent-0.10.1-linux-arm64.tar.gz",
22
+ "sha256": "5af68c10a088538fd4990fd18778d8c7fe28c0491083dc069c5177f733770e91",
23
+ "executableSha256": "2853e37410c249f337e44f91cb8a792d76ff1f0b05401f18f09515f1d22a0075"
24
+ },
25
+ "linux-x64": {
26
+ "archive": "prime-agent-0.10.1-linux-x64.tar.gz",
27
+ "sha256": "21ec219183f4134dd23dce9572102e69456066fe374846525561c776d4d1945c",
28
+ "executableSha256": "1fbb506f54a8e9af1f0d123e521d13a765bce34883707c69656f06d5951b314c"
29
+ }
30
+ }
31
+ }
32
+ }
@@ -0,0 +1 @@
1
+ import{r as e}from"./rolldown-runtime-hePW80VL.js";import{t}from"./react-Cvdyeg_0.js";import{t as n}from"./jsx-runtime-NZYk81nU.js";import{F as r,M as i,a,j as o,t as s}from"./useButton-CvcmqA2s.js";import{r as c,s as l,t as u,v as d,x as f}from"./createBaseUIEventDetails-DIxvaz-Y.js";import{G as p,K as m,d as h,t as g,tt as _}from"./FloatingPortal-D8-EPDs2.js";import{E as v,R as y,S as b,T as x,_ as S,b as C,f as w,g as T,m as E,n as D,p as O,s as k,t as A,v as j,w as M,x as N,y as ee,z as P}from"./useScrollLock-BcsteNzT.js";import{t as F}from"./useBaseUiId-lKfDDIcw.js";function I(e,t,n=!1){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:new M({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:n,onOpenChange:void 0}),floatingId:t,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:r,inactiveTriggerProps:r,popupProps:r}}var L=e=>e.triggerIdProp??e.activeTriggerId,R=e=>e.openProp??e.open,z=e=>(e.popupElement?.id??e.floatingId)||void 0;function B(e,t){return t!==void 0&&R(e)&&L(e)===t}function te(e,t){return B(e,t)?!0:t!==void 0&&R(e)&&L(e)==null&&e.triggerCount===1}var V={open:R,mounted:e=>e.mounted,transitionStatus:e=>e.transitionStatus,floatingRootContext:e=>e.floatingRootContext,triggerCount:e=>e.triggerCount,preventUnmountingOnClose:e=>e.preventUnmountingOnClose,payload:e=>e.payload,activeTriggerId:L,activeTriggerElement:e=>e.mounted?e.activeTriggerElement:null,popupId:z,isTriggerActive:(e,t)=>t!==void 0&&L(e)===t,isOpenedByTrigger:(e,t)=>B(e,t),isMountedByTrigger:(e,t)=>t!==void 0&&L(e)===t&&e.mounted,triggerProps:(e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps,triggerPopupId:(e,t)=>te(e,t)?z(e):void 0,popupProps:e=>e.popupProps,popupElement:e=>e.popupElement,positionerElement:e=>e.positionerElement},H=e(t(),1),U=H.createContext(void 0);function W(e){let t=H.useContext(U);if(!e&&t===void 0)throw Error(o(27));return t}var G=H.forwardRef(function(e,t){let{render:n,className:r,style:i,forceRender:o=!1,...s}=e,c=W(),l=c.useState(`open`),u=c.useState(`nested`),d=c.useState(`mounted`),f={open:l,transitionStatus:c.useState(`transitionStatus`)};return a(`div`,e,{state:f,ref:[c.context.backdropRef,t],stateAttributesMapping:P,props:[{role:`presentation`,hidden:!d,style:{userSelect:`none`,WebkitUserSelect:`none`}},s],enabled:o||!u})}),K=H.forwardRef(function(e,t){let{render:n,className:r,style:i,disabled:o=!1,nativeButton:l=!0,...d}=e,f=W(),p=f.useState(`open`),{getButtonProps:m,buttonRef:h}=s({disabled:o,native:l}),g={disabled:o};function _(e){p&&f.setOpen(!1,u(c,e.nativeEvent))}return a(`button`,e,{state:g,ref:[t,h],props:[{onClick:_},d,m]})}),q=H.forwardRef(function(e,t){let{render:n,className:r,style:i,id:o,...s}=e,c=W(),l=F(o);return c.useSyncedValueWithCleanup(`descriptionElementId`,l),a(`p`,e,{ref:t,props:[{id:l},s]})}),J=H.createContext(void 0);function Y(){let e=H.useContext(J);if(e===void 0)throw Error(o(26));return e}var X=`--nested-dialogs`,Z=`data-nested-dialog-open`,ne={...y,...f,nestedDialogOpen(e){return e?{[Z]:``}:null}},Q=n(),re=H.forwardRef(function(e,t){let{render:n,className:r,style:i,finalFocus:o,initialFocus:s,...c}=e,l=W(),u=l.useState(`descriptionElementId`),f=l.useState(`disablePointerDismissal`),p=l.useState(`floatingRootContext`),m=l.useState(`popupProps`),h=l.useState(`modal`),g=l.useState(`mounted`),_=l.useState(`nested`),y=l.useState(`nestedOpenDialogCount`),b=l.useState(`open`),x=l.useState(`openMethod`),S=l.useState(`titleElementId`),C=l.useState(`transitionStatus`),w=l.useState(`role`),E=p.useState(`floatingId`);Y(),d({open:b,ref:l.context.popupRef,onComplete(){b&&l.context.onOpenChangeComplete?.(!0)}});let D=s===void 0?T(l.context.popupRef):s,A=y>0,j=l.useStateSetter(`popupElement`),M=a(`div`,e,{state:{open:b,nested:_,transitionStatus:C,nestedDialogOpen:A},props:[m,{id:E,"aria-labelledby":S,"aria-describedby":u,role:w,...O,hidden:!g,onKeyDown(e){k.has(e.key)&&e.stopPropagation()},style:{[X]:y}},c],ref:[t,l.context.popupRef,j],stateAttributesMapping:ne});return(0,Q.jsx)(v,{context:p,openInteractionType:x,disabled:!g,closeOnFocusOut:!f,initialFocus:D,returnFocus:o,modal:h!==!1,restoreFocus:`popup`,children:M})}),ie=H.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e,i=W(),a=i.useState(`mounted`),o=i.useState(`modal`),s=i.useState(`open`);return a||n?(0,Q.jsx)(J.Provider,{value:n,children:(0,Q.jsxs)(g,{ref:t,...r,children:[a&&o===!0&&(0,Q.jsx)(D,{ref:i.context.internalBackdropRef,inert:h(!s)}),e.children]})}):null});function ae({store:e,parentContext:t,isDrawer:n}){let r=e.useState(`open`),a=e.useState(`disablePointerDismissal`),o=e.useState(`modal`),s=e.useState(`popupElement`),c=e.useState(`floatingRootContext`),[l,u]=H.useState(0),[d,f]=H.useState(0),h=l===0,g=x(c,{outsidePressEvent(){return e.context.internalBackdropRef.current||e.context.backdropRef.current?`intentional`:{mouse:o===`trap-focus`?`sloppy`:`intentional`,touch:`sloppy`}},outsidePress(t){if(!e.context.outsidePressEnabledRef.current||`button`in t&&t.button!==0)return!1;if(`touches`in t){if(t.type===`touchend`){if(t.changedTouches.length!==1||t.touches.length!==0)return!1}else if(t.touches.length!==1)return!1}let n=m(t);if(h&&!a){if(o){let t=e.context.internalBackdropRef.current,r=e.context.backdropRef.current;return t||r?t===n||r===n||p(n,s)&&!n?.hasAttribute(`data-base-ui-portal`):!0}return!0}return!1},escapeKey:h});return A(r&&o===!0,s),e.useContextCallback(`onNestedDialogOpen`,(e,t)=>{u(e),f(t)}),i(()=>(t?.onNestedDialogOpen&&(r?t.onNestedDialogOpen(l+1,d+ +!!n):t.onNestedDialogOpen(0,0)),()=>{t?.onNestedDialogOpen&&r&&t.onNestedDialogOpen(0,0)}),[n,r,l,d,t]),C(e,{activeTriggerProps:g.reference,inactiveTriggerProps:g.trigger,popupProps:g.floating,nestedOpenDialogCount:l,nestedOpenDrawerCount:d}),null}var oe={...V,modal:e=>e.modal,nested:e=>e.nested,nestedOpenDialogCount:e=>e.nestedOpenDialogCount,nestedOpenDrawerCount:e=>e.nestedOpenDrawerCount,disablePointerDismissal:e=>e.disablePointerDismissal,openMethod:e=>e.openMethod,descriptionElementId:e=>e.descriptionElementId,titleElementId:e=>e.titleElementId,viewportElement:e=>e.viewportElement,role:e=>e.role},$=class extends _{constructor(e,t,n){let r=new w,i=se(e,r,t,n);super(i,ce(r),oe)}setOpen=(e,t)=>{t.preventUnmountOnClose=()=>{this.set(`preventUnmountingOnClose`,!0)},!e&&t.trigger==null&&this.state.activeTriggerId!=null&&(t.trigger=this.state.activeTriggerElement??void 0),this.context.onOpenChange?.(e,t),!t.isCanceled&&(this.state.floatingRootContext.dispatchOpenChange(e,t),this.update(S(this.state,e,t.trigger)))}};function se(e,t,n,r=!1){return{...I(t,n,r),modal:!0,disablePointerDismissal:!1,viewportElement:null,descriptionElementId:void 0,titleElementId:void 0,openMethod:null,nested:!1,nestedOpenDialogCount:0,nestedOpenDrawerCount:0,role:`dialog`,...e}}function ce(e){return{popupRef:H.createRef(),backdropRef:H.createRef(),internalBackdropRef:H.createRef(),outsidePressEnabledRef:{current:!0},triggerElements:e,onOpenChange:void 0,onOpenChangeComplete:void 0}}function le(e,t){let{children:n,open:r,defaultOpen:i=!1,onOpenChange:a,onOpenChangeComplete:o,disablePointerDismissal:s=!1,modal:c=!0,actionsRef:d,handle:f,triggerId:p,defaultTriggerId:m=null}=t,h=e===`drawer`,g=e===`alert-dialog`,_=g?!0:c,v=g||s,y=g?`alertdialog`:`dialog`,x=W(!0),S={modal:_,disablePointerDismissal:v,nested:x!=null,role:y},C=N((e,t)=>new $({open:i,openProp:r,activeTriggerId:m,triggerIdProp:p,...S},e,t),!0);C.useControlledProp(`openProp`,r),C.useControlledProp(`triggerIdProp`,p),C.useSyncedValues(S),C.useContextCallback(`onOpenChange`,a),C.useContextCallback(`onOpenChangeComplete`,o);let w=C.useState(`open`),T=C.useState(`mounted`),D=C.useState(`payload`);b(C,w),j(C);let{forceUnmount:O}=ee(w,C);H.useImperativeHandle(d,()=>({unmount:O,close:()=>C.setOpen(!1,u(l))}),[O,C]);let k=w||T;return(0,Q.jsxs)(U.Provider,{value:C,children:[f&&(0,Q.jsx)(E,{handle:f,store:C}),k&&(0,Q.jsx)(ae,{store:C,parentContext:x?.context,isDrawer:h}),typeof n==`function`?n({payload:D}):n]})}var ue=H.forwardRef(function(e,t){let{render:n,className:r,style:i,id:o,...s}=e,c=W(),l=F(o);return c.useSyncedValueWithCleanup(`titleElementId`,l),a(`h2`,e,{ref:t,props:[{id:l},s]})});export{q as a,I as c,re as i,V as l,le as n,K as o,ie as r,G as s,ue as t};
@@ -0,0 +1 @@
1
+ import{r as e}from"./rolldown-runtime-hePW80VL.js";import{t}from"./react-Cvdyeg_0.js";import{t as n}from"./react-dom-B7th3XGm.js";import{t as r}from"./jsx-runtime-NZYk81nU.js";import{n as i,t as a}from"./with-selector-B_VDO56x.js";import{A as o,F as s,I as c,M as l,N as u,O as d,S as ee,a as f,b as p,l as m,p as h,w as g,y as _}from"./useButton-CvcmqA2s.js";import{D as v,E as y,_ as b,t as te}from"./createBaseUIEventDetails-DIxvaz-Y.js";var x=i(),S=e(a(),1),C=e(t(),1),w=[],T=void 0;function ne(){return T}function re(e){w.push(e)}function E(e){let t=(t,n)=>{let r=u(ae).current,i;try{T=r;for(let e of w)e.before(r);i=e(t,n);for(let e of w)e.after(r);r.didInitialize=!0}finally{T=void 0}return i};return t.displayName=e.displayName||e.name,t}function ie(e){return C.forwardRef(E(e))}function ae(){return{didInitialize:!1}}var oe=o(19)?ce:le;function D(e,t,n,r,i){return oe(e,t,n,r,i)}function se(e,t,n,r,i){let a=C.useCallback(()=>t(e.getSnapshot(),n,r,i),[e,t,n,r,i]);return(0,x.useSyncExternalStore)(e.subscribe,a,a)}re({before(e){e.syncIndex=0,e.didInitialize||(e.syncTick=1,e.syncHooks=[],e.didChangeStore=!0,e.getSnapshot=()=>{let t=!1;for(let n=0;n<e.syncHooks.length;n+=1){let r=e.syncHooks[n],i=r.selector(r.store.state,r.a1,r.a2,r.a3);Object.is(r.value,i)||(t=!0,r.value=i)}return t&&(e.syncTick+=1),e.syncTick})},after(e){e.syncHooks.length>0&&(e.didChangeStore&&(e.didChangeStore=!1,e.subscribe=t=>{let n=new Set;for(let t of e.syncHooks)n.add(t.store);let r=[];for(let e of n)r.push(e.subscribe(t));return()=>{for(let e of r)e()}}),(0,x.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getSnapshot))}});function ce(e,t,n,r,i){let a=ne();if(!a)return se(e,t,n,r,i);let o=a.syncIndex;a.syncIndex+=1;let s;return a.didInitialize?(s=a.syncHooks[o],(s.store!==e||s.selector!==t||!Object.is(s.a1,n)||!Object.is(s.a2,r)||!Object.is(s.a3,i))&&(s.store!==e&&(a.didChangeStore=!0),s.store=e,s.selector=t,s.a1=n,s.a2=r,s.a3=i,s.value=t(e.getSnapshot(),n,r,i))):(s={store:e,selector:t,a1:n,a2:r,a3:i,value:t(e.getSnapshot(),n,r,i)},a.syncHooks.push(s)),s.value}function le(e,t,n,r,i){return(0,S.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,e=>t(e,n,r,i))}var ue=class{static create(e){return new this(e)}constructor(e){this.state=e,this.listeners=new Set,this.updateTick=0}subscribe=e=>(this.listeners.add(e),()=>{this.listeners.delete(e)});getSnapshot=()=>this.state;setState(e){if(this.state===e)return;this.state=e,this.updateTick+=1;let t=this.updateTick;for(let n of this.listeners){if(t!==this.updateTick)return;n(e)}}update(e){for(let t in e)if(!Object.is(this.state[t],e[t])){this.setState({...this.state,...e});return}}set(e,t){Object.is(this.state[e],t)||this.setState({...this.state,[e]:t})}notifyAll(){let e={...this.state};this.setState(e)}use(e,t,n,r){return D(this,e,t,n,r)}},de=class extends ue{constructor(e,t={},n){super(e),this.context=t,this.selectors=n}useSyncedValue(e,t){C.useDebugValue(e);let n=this;l(()=>{n.state[e]!==t&&n.set(e,t)},[n,e,t])}useSyncedValueWithCleanup(e,t){let n=this;l(()=>(n.state[e]!==t&&n.set(e,t),()=>{n.set(e,void 0)}),[n,e,t])}useSyncedValues(e){let t=this,n=Object.values(e);l(()=>{t.update(e)},[t,...n])}useControlledProp(e,t){C.useDebugValue(e);let n=this,r=t!==void 0;l(()=>{r&&!Object.is(n.state[e],t)&&n.setState({...n.state,[e]:t})},[n,e,t,r])}select(e,t,n,r){let i=this.selectors[e];return i(this.state,t,n,r)}useState(e,t,n,r){return C.useDebugValue(e),D(this,this.selectors[e],t,n,r)}useContextCallback(e,t){C.useDebugValue(e);let n=d(t??c);this.context[e]=n}useStateSetter(e){let t=C.useRef(void 0);return t.current===void 0&&(t.current=t=>{this.set(e,t)}),t.current}observe(e,t){let n;n=typeof e==`function`?e:this.selectors[e];let r=n(this.state);return t(r,r,this),this.subscribe(e=>{let i=n(e);if(!Object.is(r,i)){let e=r;r=i,t(i,e,this)}})}},O=e(n(),1);function fe(...e){return()=>{for(let t=0;t<e.length;t+=1){let n=e[t];n&&n()}}}var k=r();function A(e){return e?.ownerDocument||document}var j=0,M=class e{static create(){return new e}currentId=j;start(e,t){this.clear(),this.currentId=setTimeout(()=>{this.currentId=j,t()},e)}isStarted(){return this.currentId!==j}clear=()=>{this.currentId!==j&&(clearTimeout(this.currentId),this.currentId=j)};disposeEffect=()=>this.clear};function pe(){let e=u(M.create).current;return v(e.disposeEffect),e}function me(){return typeof navigator>`u`?{userAgent:``,platform:``,maxTouchPoints:0}:{userAgent:navigator.userAgent,platform:navigator.platform??``,maxTouchPoints:navigator.maxTouchPoints??0}}var{userAgent:he,platform:ge,maxTouchPoints:_e}=me(),N=he.toLowerCase(),P=ge.toLowerCase(),F=/^i(os$|p)/.test(P)||P===`macintel`&&_e>1,ve=`android`,ye=P===ve||N.includes(ve),be=!F&&P.startsWith(`mac`);P.startsWith(`win`),!ye&&/^(linux|chrome os)/.test(P);var xe=be||F,I=typeof CSS<`u`&&!!CSS.supports?.(`-webkit-backdrop-filter:none`);!I&&N.includes(`firefox`),!I&&N.includes(`chrom`);var Se=xe,Ce=/jsdom|happydom/.test(N);function L(e){let t=e.activeElement;for(;t?.shadowRoot?.activeElement!=null;)t=t.shadowRoot.activeElement;return t}function R(e,t){if(!e||!t)return!1;let n=t.getRootNode?.();if(e.contains(t))return!0;if(n&&g(n)){let n=t;for(;n;){if(e===n)return!0;n=n.parentNode||n.host}}return!1}function we(e){return`composedPath`in e?e.composedPath()[0]??e.target:e.target}var Te=`data-base-ui-focusable`,Ee=`input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])`,De=`ArrowLeft`,Oe=`ArrowRight`,ke=`ArrowUp`,Ae=`ArrowDown`,je=`data-popup-open`,Me=`data-pressed`,z=`data-trigger-disabled`;function Ne(e,t){if(!_(e))return!1;let n=e;if(t.hasElement(n))return!n.hasAttribute(z);for(let[,e]of t.entries())if(R(e,n))return!e.hasAttribute(z);return!1}function Pe(e,t){if(t==null)return!1;if(`composedPath`in e)return e.composedPath().includes(t);let n=e;return n.target!=null&&t.contains(n.target)}function Fe(e){return e.matches(`html,body`)}function B(e){return p(e)&&e.matches(`input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])`)}function Ie(e){return e?.closest(`button,a[href],[role="button"],select,[tabindex]:not([tabindex="-1"]),${Ee}`)!=null}function Le(e){return e?e.getAttribute(`role`)===`combobox`&&B(e):!1}function Re(e){if(!e||Ce)return!0;try{return e.matches(`:focus-visible`)}catch{return!0}}function ze(e){return e?e.hasAttribute(`data-base-ui-focusable`)?e:e.querySelector(`[data-base-ui-focusable]`)||e:null}function Be(e,t){return t<0||t>=e.length}function Ve(e,t){return V(e.current,{disabledIndices:t})}function He(e,t){return V(e.current,{decrement:!0,startingIndex:e.current.length,disabledIndices:t})}function V(e,{startingIndex:t=-1,decrement:n=!1,disabledIndices:r,amount:i=1}={}){let a=t;do a+=n?-i:i;while(a>=0&&a<=e.length-1&&H(e,a,r));return a}function H(e,t,n){if(typeof n==`function`?n(t):n?.includes(t)??!1)return!0;let r=e[t];return r?!U(r)||r.matches(`:disabled`)?!0:!n&&(r.hasAttribute(`disabled`)||r.getAttribute(`aria-disabled`)===`true`):!1}function Ue(e){return e.visibility===`hidden`||e.visibility===`collapse`}function U(e,t=e?m(e):null){return!e||!e.isConnected||!t||Ue(t)?!1:typeof e.checkVisibility==`function`?e.checkVisibility():t.display!==`none`&&t.display!==`contents`}var We=`a[href],button,input,select,textarea,summary,details,iframe,object,embed,[tabindex],[contenteditable]:not([contenteditable="false"]),audio[controls],video[controls]`;function Ge(e){let t=e.assignedSlot;if(t)return t;if(e.parentElement)return e.parentElement;let n=e.getRootNode();return g(n)?n.host:null}function W(e){for(let t of Array.from(e.children))if(h(t)===`summary`)return t;return null}function Ke(e,t){let n=W(t);return!!n&&(e===n||R(n,e))}function G(e){let t=e?h(e):``;return e!=null&&e.matches(We)&&(t!==`summary`||e.parentElement!=null&&h(e.parentElement)===`details`&&W(e.parentElement)===e)&&(t!==`details`||W(e)==null)&&(t!==`input`||e.type!==`hidden`)}function K(e){if(!G(e)||!e.isConnected||e.matches(`:disabled`))return!1;for(let t=e;t;t=Ge(t)){let n=t!==e,r=h(t)===`slot`;if(t.hasAttribute(`inert`)||n&&h(t)===`details`&&!t.open&&!Ke(e,t)||t.hasAttribute(`hidden`)||!r&&!qe(t,n))return!1}return!0}function qe(e,t){let n=m(e);return t?n.display!==`none`:U(e,n)}function q(e){let t=e.tabIndex;if(t<0){let t=h(e);if(t===`details`||t===`audio`||t===`video`||p(e)&&e.isContentEditable)return 0}return t}function J(e){if(h(e)!==`input`)return null;let t=e;return t.type===`radio`&&t.name!==``?t:null}function Je(e,t){let n=J(e);if(!n)return!0;let r=t.find(e=>{let t=J(e);return t?.name===n.name&&t.form===n.form&&t.checked});return r?r===n:t.find(e=>{let t=J(e);return t?.name===n.name&&t.form===n.form})===n}function Y(e){if(p(e)&&h(e)===`slot`){let t=e.assignedElements({flatten:!0});if(t.length>0)return t}return p(e)&&e.shadowRoot?Array.from(e.shadowRoot.children):Array.from(e.children)}function Ye(e,t){Y(e).forEach(e=>{G(e)&&t.push(e),Ye(e,t)})}function Xe(e,t,n){Y(e).forEach(e=>{p(e)&&e.matches(t)&&n.push(e),Xe(e,t,n)})}function Ze(e){return K(e)&&q(e)>=0}function Qe(e){let t=[];return Ye(e,t),t.filter(K)}function X(e){let t=Qe(e);return t.filter(e=>q(e)>=0&&Je(e,t))}function $e(e,t){let n=X(e),r=n.length;if(r===0)return;let i=L(A(e)),a=n.indexOf(i);return n[a===-1?t===1?0:r-1:a+t]}function et(e){return $e(A(e).body,1)||e}function tt(e){return $e(A(e).body,-1)||e}function nt(e,t){if(!e)return null;let n=X(A(e).body),r=n.length;if(r===0)return null;let i=n.indexOf(e);return i===-1?null:n[(i+t+r)%r]}function rt(e){return nt(e,1)}function it(e){return nt(e,-1)}function Z(e,t){let n=t||e.currentTarget,r=e.relatedTarget;return!r||!R(n,r)}function at(e){X(e).forEach(e=>{e.dataset.tabindex=e.getAttribute(`tabindex`)||``,e.setAttribute(`tabindex`,`-1`)})}function ot(e){let t=[];Xe(e,`[data-tabindex]`,t),t.forEach(e=>{let t=e.dataset.tabindex;delete e.dataset.tabindex,t?e.setAttribute(`tabindex`,t):e.removeAttribute(`tabindex`)})}var st={clipPath:`inset(50%)`,overflow:`hidden`,whiteSpace:`nowrap`,border:0,padding:0,width:1,height:1,margin:-1},ct={...st,position:`fixed`,top:0,left:0},lt={...st,position:`absolute`},Q=C.forwardRef(function(e,t){let[n,r]=C.useState();l(()=>{Se&&I&&r(`button`)},[]);let i={tabIndex:0,role:n};return(0,k.jsx)(`span`,{...e,ref:t,style:ct,"aria-hidden":!n||void 0,...i,"data-base-ui-focus-guard":``})});function ut(e){return o(19)?e:e?`true`:void 0}var dt={style:{transition:`none`}},ft=`data-base-ui-click-trigger`,pt=`data-base-ui-swipe-ignore`,mt=`data-swipe-ignore`,ht=`[${pt}]`,gt=`[${mt}]`,_t={fallbackAxisSide:`none`},vt={fallbackAxisSide:`end`},yt={clipPath:`inset(50%)`,position:`fixed`,top:0,left:0};function bt(e){return`data-base-ui-${e}`}var xt=C.createContext(null),$=()=>C.useContext(xt),St=bt(`portal`);function Ct(e={}){let{ref:t,container:n,componentProps:r=s,elementProps:i}=e,a=b(),o=$()?.portalNode,[c,u]=C.useState(null),[p,m]=C.useState(null),h=d(e=>{e!==null&&m(e)}),g=C.useRef(null);l(()=>{if(n===null){g.current&&(g.current=null,m(null),u(null));return}let e=(n&&(ee(n)?n:n.current))??o??document.body;if(e==null){g.current&&(g.current=null,m(null),u(null));return}g.current!==e&&(g.current=e,m(null),u(e))},[n,o]);let _=f(`div`,r,{ref:[t,h],props:[{id:a,[St]:``},i]}),v=c&&_?O.createPortal(_,c):null;return{node:p,nodeId:C.isValidElement(_)?_.props.id:void 0,subtree:v}}var wt=C.forwardRef(function(e,t){let{render:n,className:r,style:i,children:a,container:o,portalOwnerRole:s,...c}=e,{node:u,nodeId:d,subtree:ee}=Ct({container:o,ref:t,componentProps:e,elementProps:c}),f=C.useRef(null),p=C.useRef(null),m=C.useRef(null),h=C.useRef(null),[g,_]=C.useState(null),v=C.useRef(!1),b=g?.modal,x=g?.open,S=!!g&&!g.modal&&g.open&&!!u;C.useEffect(()=>{if(!u||b)return;function e(e){u&&e.relatedTarget&&Z(e)&&(e.type===`focusin`?v.current&&=(ot(u),!1):(at(u),v.current=!0))}return fe(y(u,`focusin`,e,!0),y(u,`focusout`,e,!0))},[u,b]),l(()=>{!u||x!==!0||!v.current||(ot(u),v.current=!1)},[x,u]);let w=C.useMemo(()=>({beforeOutsideRef:f,afterOutsideRef:p,beforeInsideRef:m,afterInsideRef:h,portalNode:u,setFocusManagerState:_}),[u]);return(0,k.jsxs)(C.Fragment,{children:[ee,(0,k.jsxs)(xt.Provider,{value:w,children:[S&&u&&(0,k.jsx)(Q,{"data-type":`outside`,ref:f,onFocus:e=>{Z(e,u)?m.current?.focus():tt(g?g.domReference:null)?.focus()}}),S&&u&&(0,k.jsx)(`span`,{role:s,"aria-owns":d,style:yt}),u&&O.createPortal(a,u),S&&u&&(0,k.jsx)(Q,{"data-type":`outside`,ref:p,onFocus:e=>{Z(e,u)?h.current?.focus():(et(g?g.domReference:null)?.focus(),g?.closeOnFocusOut&&g?.onOpenChange(!1,te(`focus-out`,e.nativeEvent)))}})]})]})});export{A as $,Pe as A,De as B,V as C,Be as D,U as E,B as F,R as G,ke as H,Re as I,I as J,we as K,je as L,Fe as M,Ne as N,H as O,Le as P,pe as Q,Me as R,X as S,Ve as T,Te as U,Oe as V,L as W,F as X,ye as Y,M as Z,tt as _,ht as a,Z as b,_t as c,ut as d,fe as et,Q as f,et as g,Qe as h,bt as i,Ie as j,ze as k,gt as l,lt as m,Ct as n,E as nt,ft as o,ct as p,Ce as q,$ as r,ie as rt,dt as s,wt as t,de as tt,vt as u,rt as v,He as w,Ze as x,it as y,Ae as z};
@@ -0,0 +1 @@
1
+ import{t as e}from"./createLucideIcon-CQY2ECfR.js";var t={name:`activity`,size:24,node:[[`path`,{d:`M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2`,key:`169zse`}]]};t.node;var n=e(t);export{n as t};
@@ -0,0 +1,2 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/agents-page-CTuFJL9H.js","assets/rolldown-runtime-hePW80VL.js","assets/react-Cvdyeg_0.js","assets/mutation-Da9zdeWr.js","assets/jsx-runtime-NZYk81nU.js","assets/with-selector-B_VDO56x.js","assets/chat-queries-CfZiupub.js","assets/chat-hpzV6IA6.js","assets/card-Dj1SnGUU.js","assets/utils-oBThwhjm.js","assets/createLucideIcon-CQY2ECfR.js","assets/activity-BPIKUzOU.js","assets/arrow-up-right-CG9RNk4p.js","assets/bot-DETalD3q.js","assets/clock-3-BwWCSCm_.js","assets/loader-circle-BmKYM_C4.js","assets/button-CWYjn8Zk.js","assets/useButton-CvcmqA2s.js","assets/dist-BogNzeK9.js","assets/clsx-DB0hHKMi.js","assets/product-page-header-Ck6I13CE.js","assets/alert-CzWGeumf.js","assets/badge-CzQFgmVK.js","assets/useRender-CzJUrRlB.js"])))=>i.map(i=>d[i]);
2
+ import{r as e}from"./rolldown-runtime-hePW80VL.js";import{t}from"./react-Cvdyeg_0.js";import{t as n}from"./jsx-runtime-NZYk81nU.js";import{t as r}from"./preload-helper-BLdHbfdN.js";var i=e(t()),a=n(),o=(0,i.lazy)(()=>r(async()=>{let{AgentsPage:e}=await import(`./agents-page-CTuFJL9H.js`);return{AgentsPage:e}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23])).then(({AgentsPage:e})=>({default:e})));function s(){return(0,a.jsx)(`main`,{className:`min-h-svh bg-background p-8`,children:(0,a.jsx)(`p`,{className:`mx-auto max-w-5xl text-sm text-muted-foreground`,children:`Loading agents…`})})}var c=()=>(0,a.jsx)(i.Suspense,{fallback:(0,a.jsx)(s,{}),children:(0,a.jsx)(o,{})});export{c as component};
@@ -0,0 +1 @@
1
+ import{r as e}from"./rolldown-runtime-hePW80VL.js";import{t}from"./react-Cvdyeg_0.js";import{O as n}from"./mutation-Da9zdeWr.js";import{t as r}from"./jsx-runtime-NZYk81nU.js";import{O as i,o as a,v as o}from"./chat-queries-CfZiupub.js";import{a as s,i as c,n as l,r as u,t as d}from"./card-Dj1SnGUU.js";import{t as f}from"./createLucideIcon-CQY2ECfR.js";import{t as p}from"./activity-BPIKUzOU.js";import{t as m}from"./arrow-up-right-CG9RNk4p.js";import{t as h}from"./bot-DETalD3q.js";import{t as g}from"./clock-3-BwWCSCm_.js";import{t as _}from"./loader-circle-BmKYM_C4.js";import{t as v}from"./button-CWYjn8Zk.js";import{t as y}from"./product-page-header-Ck6I13CE.js";import{n as b,r as x,t as S}from"./alert-CzWGeumf.js";import{t as C}from"./badge-CzQFgmVK.js";var w={name:`calendar-clock`,size:24,node:[[`path`,{d:`M16 14v2.2l1.6 1`,key:`fo4ql5`}],[`path`,{d:`M16 2v3`,key:`otl347`}],[`path`,{d:`M21 7.338V5a2 2 0 00-2-2H5a2 2 0 00-2 2v14a2 2 0 002 2h2.338`,key:`7hb8p4`}],[`path`,{d:`M3 9h5.859`,key:`numkqi`}],[`path`,{d:`M8 2v3`,key:`1ioesn`}],[`circle`,{cx:`16`,cy:`16`,r:`6`,key:`qoo3c4`}]]};w.node;var T=f(w),E=e(t(),1),D=r();function O(){let[e,t]=(0,E.useState)(20),r=a(),f=i({queryKey:[`chat`,`sessions`,`all`],queryFn:()=>o.listSessions()}),w=new Map((r.data?.projects??[]).map(e=>[e.projectId,e.name])),O=[...f.data??[]].sort((e,t)=>Date.parse(t.updatedAt)-Date.parse(e.updatedAt)),j=O.slice(0,e);return(0,D.jsxs)(`main`,{className:`min-h-svh bg-background`,children:[(0,D.jsx)(y,{active:`agents`}),(0,D.jsxs)(`div`,{className:`mx-auto flex w-full max-w-5xl flex-col gap-8 px-5 py-10 sm:px-8`,children:[(0,D.jsxs)(`div`,{className:`max-w-2xl`,children:[(0,D.jsx)(`div`,{className:`mb-3 flex size-10 items-center justify-center rounded-xl bg-primary/10 text-primary`,children:(0,D.jsx)(h,{className:`size-5`})}),(0,D.jsx)(`h1`,{className:`text-2xl font-semibold tracking-tight`,children:`Agents`}),(0,D.jsx)(`p`,{className:`mt-2 text-sm leading-6 text-muted-foreground`,children:`Review conversations and schedules.`})]}),(0,D.jsxs)(`section`,{"aria-labelledby":`schedule-heading`,className:`space-y-3`,children:[(0,D.jsxs)(`div`,{children:[(0,D.jsx)(`h2`,{id:`schedule-heading`,className:`text-base font-medium`,children:`Heartbeat and cron`}),(0,D.jsx)(`p`,{className:`mt-1 text-sm text-muted-foreground`,children:`Not supported in Fleet.`})]}),(0,D.jsxs)(`div`,{className:`grid gap-3 sm:grid-cols-2`,children:[(0,D.jsx)(k,{icon:(0,D.jsx)(p,{className:`size-4`}),title:`Heartbeat`}),(0,D.jsx)(k,{icon:(0,D.jsx)(T,{className:`size-4`}),title:`Cron`})]})]}),(0,D.jsxs)(`section`,{"aria-labelledby":`saved-sessions-heading`,className:`space-y-3`,children:[(0,D.jsxs)(`div`,{className:`flex items-end justify-between gap-3`,children:[(0,D.jsxs)(`div`,{children:[(0,D.jsx)(`h2`,{id:`saved-sessions-heading`,className:`text-base font-medium`,children:`Recent sessions`}),(0,D.jsx)(`p`,{className:`mt-1 text-sm text-muted-foreground`,children:`Recent conversations.`})]}),(0,D.jsx)(v,{asChild:!0,variant:`outline`,size:`compact`,children:(0,D.jsxs)(n,{to:`/`,children:[`Open sessions `,(0,D.jsx)(m,{"data-icon":`inline-end`})]})})]}),f.isLoading?(0,D.jsxs)(`div`,{className:`flex items-center gap-2 py-5 text-sm text-muted-foreground`,children:[(0,D.jsx)(_,{className:`size-4 animate-spin`}),` Loading saved sessions…`]}):f.isError?(0,D.jsxs)(S,{variant:`destructive`,children:[(0,D.jsx)(x,{children:`Could not load saved sessions`}),(0,D.jsx)(b,{children:f.error.message})]}):O.length===0?(0,D.jsx)(d,{children:(0,D.jsx)(l,{className:`py-6 text-sm text-muted-foreground`,children:`No saved sessions yet.`})}):(0,D.jsx)(`div`,{className:`grid gap-3 md:grid-cols-2`,children:j.map(e=>{let t=e.title||e.firstMessage||`Untitled session`;return(0,D.jsxs)(d,{size:`sm`,className:`min-w-0 overflow-hidden`,children:[(0,D.jsx)(c,{className:`min-w-0`,children:(0,D.jsxs)(`div`,{className:`flex min-w-0 items-start justify-between gap-3`,children:[(0,D.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,D.jsx)(s,{className:`min-w-0 truncate`,title:t,children:t}),(0,D.jsxs)(u,{className:`mt-1 truncate`,children:[e.projectId?w.get(e.projectId)??`Project`:`Unassigned project`,`· `,e.messageCount,` `,e.messageCount===1?`message`:`messages`]})]}),(0,D.jsx)(C,{variant:`outline`,className:`capitalize`,children:e.status})]})}),(0,D.jsxs)(l,{className:`flex items-center gap-1.5 text-xs text-muted-foreground`,children:[(0,D.jsx)(g,{className:`size-3.5`}),`Updated `,A(e.updatedAt)]})]},e.sessionId)})}),!f.isLoading&&!f.isError&&O.length>20?(0,D.jsx)(`div`,{className:`flex justify-center`,children:(0,D.jsx)(v,{type:`button`,variant:`ghost`,size:`compact`,onClick:()=>t(e=>e>=O.length?20:e+20),children:e>=O.length?`Show fewer sessions`:`Show more sessions`})}):null]})]})]})}function k({icon:e,title:t}){return(0,D.jsxs)(d,{size:`sm`,className:`opacity-80`,children:[(0,D.jsx)(c,{children:(0,D.jsxs)(s,{className:`flex items-center gap-2`,children:[e,t]})}),(0,D.jsx)(l,{children:(0,D.jsx)(C,{variant:`outline`,children:`Unavailable`})})]})}function A(e){let t=new Date(e);return Number.isNaN(t.getTime())?`an unknown time`:t.toLocaleString()}export{O as AgentsPage};
@@ -0,0 +1 @@
1
+ import{t as e}from"./jsx-runtime-NZYk81nU.js";import{t}from"./utils-oBThwhjm.js";import{t as n}from"./dist-BogNzeK9.js";var r=e(),i=n(`group/alert relative grid w-full gap-0.5 rounded-lg border px-2.5 py-2 text-left text-sm has-[>svg]:grid-cols-[auto_1fr] has-[>svg]:gap-x-2 *:[svg]:row-span-2 *:[svg]:translate-y-0.5 *:[svg]:text-current *:[svg:not([class*='size-'])]:size-4`,{variants:{variant:{default:`bg-card text-card-foreground`,destructive:`bg-card text-destructive *:data-[slot=alert-description]:text-destructive/90 *:[svg]:text-current`}},defaultVariants:{variant:`default`}});function a({className:e,variant:n,...a}){return(0,r.jsx)(`div`,{"data-slot":`alert`,role:`alert`,className:t(i({variant:n}),e),...a})}function o({className:e,...n}){return(0,r.jsx)(`div`,{"data-slot":`alert-title`,className:t(`font-medium group-has-[>svg]/alert:col-start-2 [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground`,e),...n})}function s({className:e,...n}){return(0,r.jsx)(`div`,{"data-slot":`alert-description`,className:t(`text-sm text-balance text-muted-foreground md:text-pretty [&_a]:underline [&_a]:underline-offset-3 [&_a]:hover:text-foreground [&_p:not(:last-child)]:mb-4`,e),...n})}export{s as n,o as r,a as t};
@@ -0,0 +1 @@
1
+ import{t as e}from"./jsx-runtime-NZYk81nU.js";import{t}from"./utils-oBThwhjm.js";import{a as n,i as r,n as i,o as a,r as o,s,t as c}from"./DialogTitle-BlVq-tcv.js";import{t as l}from"./button-CWYjn8Zk.js";import{c as u,s as d,t as f}from"./surfaces-BUjUJTyD.js";function p(e){return i(`alert-dialog`,e)}var m=e(),h=4;function g({...e}){return(0,m.jsx)(p,{"data-slot":`alert-dialog`,...e})}function _({...e}){return(0,m.jsx)(o,{"data-slot":`alert-dialog-portal`,...e})}function v({className:e,...n}){return(0,m.jsx)(s,{"data-slot":`alert-dialog-backdrop`,className:t(`fixed inset-0 isolate z-[60] bg-black/10 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0`,e),...n})}function y({className:e,children:n,...i}){let a=u(),o=Math.min(a+h,8);return(0,m.jsxs)(_,{children:[(0,m.jsx)(v,{}),(0,m.jsx)(r,{"data-slot":`alert-dialog-content`,className:t(`fixed top-1/2 left-1/2 z-[60] grid w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl p-6 text-sm text-popover-foreground outline-none sm:max-w-md data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95`,d(o),e),...i,children:(0,m.jsx)(f,{value:o,children:n})})]})}function b({className:e,...n}){return(0,m.jsx)(c,{"data-slot":`alert-dialog-title`,className:t(`font-heading text-base leading-none font-medium`,e),...n})}function x({className:e,...r}){return(0,m.jsx)(n,{"data-slot":`alert-dialog-description`,className:t(`text-sm text-pretty text-muted-foreground`,e),...r})}function S({className:e,...n}){return(0,m.jsx)(`div`,{"data-slot":`alert-dialog-footer`,className:t(`flex flex-col-reverse gap-2 sm:flex-row sm:justify-end`,e),...n})}function C({...e}){return(0,m.jsx)(a,{"data-slot":`alert-dialog-cancel`,render:(0,m.jsx)(l,{variant:`outline`}),...e})}function w({...e}){return(0,m.jsx)(a,{"data-slot":`alert-dialog-action`,render:(0,m.jsx)(l,{variant:`destructive`}),...e})}export{x as a,y as i,w as n,S as o,C as r,b as s,g as t};
@@ -0,0 +1 @@
1
+ import{t as e}from"./createLucideIcon-CQY2ECfR.js";var t={name:`arrow-up-right`,size:24,node:[[`path`,{d:`M7 7h10v10`,key:`1tivn9`}],[`path`,{d:`M7 17 17 7`,key:`1vkiza`}]]};t.node;var n=e(t);export{n as t};
@@ -0,0 +1 @@
1
+ import{r as e}from"./rolldown-runtime-hePW80VL.js";import{t}from"./react-Cvdyeg_0.js";import{t as n}from"./jsx-runtime-NZYk81nU.js";import{t as r}from"./createLucideIcon-CQY2ECfR.js";import{a as i,i as a,n as o,t as s}from"./tool-result-7qREIVv_.js";import{i as c}from"./open-panel-action-message-SdA1VU42.js";import{t as l}from"./chevron-right-BPCB1mOg.js";import{t as u}from"./package-BkC-HSi-.js";import{t as d}from"./button-CWYjn8Zk.js";import{n as f}from"./prime-agent-artifacts-C-g1VPiW.js";import{GenerativeTextRenderer as p,t as m}from"./openui-renderer-DG-iML7M.js";import{n as h,r as g,t as _}from"./collapsible-Bk6zCsRX.js";var v={name:`layout-template`,size:24,node:[[`rect`,{width:`18`,height:`7`,x:`3`,y:`3`,rx:`1`,key:`f1a2em`}],[`rect`,{width:`9`,height:`7`,x:`3`,y:`14`,rx:`1`,key:`jqznyg`}],[`rect`,{width:`5`,height:`7`,x:`16`,y:`14`,rx:`1`,key:`q5h2i8`}]]};v.node;var y=r(v),b=e(t(),1),x=n(),S=[];function C(e){if(typeof e==`string`)return e;if(e==null)return``;try{return JSON.stringify(e,null,2)}catch{return String(e)}}function w(e){return e===`running`?`running`:e===`error`?`error`:e===`cancelled`?`cancelled`:`success`}function T(e){return e===`running`?`streaming`:e===`error`?`error`:e===`cancelled`?`cancelled`:`complete`}function E(e){let t=typeof e==`object`&&e?e:void 0;if(!t)return e===void 0?[]:[{label:`result`,text:C(e)}];let n=[];for(let e of[`stdout`,`stderr`,`result`,`error`])t[e]!==void 0&&t[e]!==``&&n.push({label:e,text:C(t[e])});let r=t.details??t.output??t.result;if(n.length===0&&r!==e&&n.push(...E(r)),n.length===0&&Array.isArray(t.content)){let e=t.content.flatMap(e=>typeof e==`string`?[e]:typeof e==`object`&&e&&`text`in e&&typeof e.text==`string`?[e.text]:[]).join(``);e&&n.push({label:t.isError===!0?`error`:`stdout`,text:e})}return n.length>0?n:[{label:`result`,text:C(e)}]}function D(e){let t=typeof e.input==`object`&&e.input!==null?e.input:void 0,n=t?.command??t?.code??t?.script;if(!(typeof n!=`string`||!n))return e.kind===`bash`?{code:n,language:`bash`,label:`Bash`}:e.kind===`ipython`?{code:n,language:/^\s*%%bash(?:\s|$)/im.test(n)?`bash`:`python`,label:`IPython`}:e.kind===`diff`?{code:n,language:`text`,label:`Text`}:{code:n,language:`json`,label:`JSON`}}function O(e){if(e.kind!==`openui-html`)return;let t=typeof e.output==`object`&&e.output!==null?e.output:void 0;if(typeof t?.title==`string`&&typeof t.document==`string`)return{title:t.title,document:t.document}}function k({artifact:e,selected:t}){let n=(0,b.useRef)(null);(0,b.useEffect)(()=>{t&&requestAnimationFrame(()=>{n.current?.focus({preventScroll:!0}),n.current?.scrollIntoView({block:`nearest`})})},[t]);let r=O(e);return(0,x.jsxs)(`article`,{ref:n,"data-artifact-id":e.id,tabIndex:-1,className:`min-w-0 rounded-md border border-border/60 bg-background p-2.5 outline-none focus-visible:ring-2 focus-visible:ring-ring`,children:[(0,x.jsxs)(`div`,{className:`mb-2 flex min-w-0 items-center gap-2`,children:[(0,x.jsx)(y,{className:`size-3.5 shrink-0 text-foreground/45`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-xs font-medium`,title:e.title,children:e.title||`OpenUI artifact`}),(0,x.jsx)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:e.status})]}),r?(0,x.jsx)(m,{artifact:r}):(0,x.jsxs)(`div`,{role:`alert`,className:`space-y-2 text-xs text-destructive`,children:[(0,x.jsx)(`p`,{children:`OpenUI artifact data is unavailable.`}),(0,x.jsx)(`pre`,{className:`max-h-48 overflow-auto whitespace-pre-wrap break-words rounded bg-foreground/5 p-2 text-foreground/70`,children:C(e.output)})]})]})}function A({artifact:e,selected:t}){let n=(0,b.useRef)(null),r=t||e.status===`running`,[c,l]=(0,b.useState)(r);(0,b.useEffect)(()=>{t&&(l(!0),requestAnimationFrame(()=>{n.current?.focus({preventScroll:!0}),n.current?.scrollIntoView({block:`nearest`})}))},[t]);let u=D(e),d=E(e.output),p=e.kind===`diff`||e.kind===`refinement`?f(e):void 0;return(0,x.jsxs)(`article`,{ref:n,"data-artifact-id":e.id,tabIndex:-1,className:`rounded-md border border-border/60 bg-background px-2.5 py-2 outline-none focus-visible:ring-2 focus-visible:ring-ring`,children:[p?(0,x.jsxs)(x.Fragment,{children:[(0,x.jsx)(i,{file:p.file,lines:p.lines,status:T(e.status),defaultOpen:r,copyText:p.copyText,maxHeight:240}),d.map(e=>(0,x.jsx)(o,{label:e.label,language:`text`,children:e.text},e.label))]}):null,p?null:(0,x.jsx)(s,{tool:e.kind,title:e.title,status:w(e.status),open:c,onOpenChange:l,defaultOpen:r,kind:e.kind===`bash`||e.kind===`ipython`?`terminal`:`custom`,children:(0,x.jsxs)(`div`,{className:`space-y-3`,children:[u?(0,x.jsx)(a,{code:u.code,language:u.language,languageLabel:u.label,showStatus:!1,showLineNumbers:!1,wrap:!0}):null,d.map(e=>(0,x.jsx)(o,{label:e.label,language:`text`,children:e.text},e.label))]})})]})}function j({block:e,expanded:t,isStreaming:n,onOpenUIAction:r,onToggle:i}){return(0,x.jsxs)(_,{open:t,onOpenChange:i,children:[(0,x.jsxs)(g,{render:(0,x.jsx)(d,{variant:`ghost`,size:`compact`,className:`group w-full justify-start gap-1.5 text-left text-label font-normal text-foreground/65 transition-none hover:bg-foreground/5 hover:text-foreground/80`}),children:[(0,x.jsx)(l,{className:`size-3 shrink-0 text-foreground/35 transition-transform group-data-panel-open:rotate-90`}),(0,x.jsx)(y,{className:`size-3.5 shrink-0 text-foreground/35`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate`,title:e.component,children:e.component}),(0,x.jsxs)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:[`#`,e.ordinal]})]}),(0,x.jsx)(h,{children:(0,x.jsx)(`div`,{className:`mb-1 mt-0.5 flex min-w-0 flex-col overflow-hidden rounded-md border border-border/60 bg-background px-2.5 py-2`,children:(0,x.jsx)(c,{resetKeys:[e.content],children:(0,x.jsx)(p,{content:e.content,isStreaming:n,messageId:e.blockId,onOpenUIAction:r})})})})]})}function M({openUIBlocks:e=[],onOpenUIAction:t,status:n,artifactRuns:r=S,selectedArtifactId:i}){let a=e,[o,s]=(0,b.useState)(null),c=n===`streaming`?a.at(-1)?.blockId:void 0,l=(0,b.useMemo)(()=>r.flatMap(e=>e.artifacts).filter(e=>e.kind!==`recap`),[r]),d=(0,b.useMemo)(()=>l.filter(e=>e.kind===`openui-html`),[l]),f=(0,b.useMemo)(()=>l.filter(e=>e.kind!==`openui-html`&&e.kind!==`ipython`),[l]);return(0,x.jsxs)(`div`,{className:`flex h-full min-h-0 flex-col gap-2 overflow-hidden`,children:[d.length>0?(0,x.jsxs)(`div`,{className:`min-h-0 flex-1 overflow-y-auto`,children:[(0,x.jsxs)(`div`,{className:`mb-2 flex min-w-0 items-center gap-2 rounded-sm bg-foreground/5 px-2 py-1.5`,children:[(0,x.jsx)(y,{className:`size-3.5 shrink-0 text-foreground/45`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-label font-medium text-foreground/70`,children:`OpenUI artifacts`}),(0,x.jsx)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:d.length})]}),(0,x.jsx)(`div`,{className:`space-y-1`,children:d.map(e=>(0,x.jsx)(k,{artifact:e,selected:e.id===i},e.id))})]}):null,f.length>0?(0,x.jsxs)(`div`,{className:`min-h-0 flex-1 overflow-y-auto`,children:[(0,x.jsxs)(`div`,{className:`mb-2 flex min-w-0 items-center gap-2 rounded-sm bg-foreground/5 px-2 py-1.5`,children:[(0,x.jsx)(u,{className:`size-3.5 shrink-0 text-foreground/45`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-label font-medium text-foreground/70`,children:`Technical artifacts`}),(0,x.jsx)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:f.length})]}),(0,x.jsx)(`div`,{className:`space-y-1`,children:f.map(e=>(0,x.jsx)(A,{artifact:e,selected:e.id===i},e.id))})]}):null,(0,x.jsxs)(`div`,{className:`flex min-h-0 flex-col`,children:[(0,x.jsxs)(`div`,{className:`mb-2 flex min-w-0 items-center gap-2 rounded-sm bg-foreground/5 px-2 py-1.5`,children:[(0,x.jsx)(y,{className:`size-3.5 shrink-0 text-foreground/45`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-label font-medium text-foreground/70`,children:`Generative UI`}),(0,x.jsx)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:a.length>0?`${a.length}`:`none yet`})]}),a.length===0?(0,x.jsx)(`p`,{className:`px-2 pb-1 text-caption leading-4 text-foreground/40`,children:`OpenUI interfaces the agent generates in this session appear here, and can be re-opened without scrolling the conversation.`}):(0,x.jsx)(`div`,{className:`flex min-h-0 flex-col gap-0.5 overflow-y-auto`,children:a.map(e=>(0,x.jsx)(j,{block:e,expanded:e.blockId===o,isStreaming:e.blockId===c,onOpenUIAction:t,onToggle:()=>s(t=>t===e.blockId?null:e.blockId)},e.blockId))})]})]})}export{M as ArtifactsPanelContent};
@@ -0,0 +1 @@
1
+ import{t as e}from"./utils-oBThwhjm.js";import{o as t}from"./useButton-CvcmqA2s.js";import{t as n}from"./dist-BogNzeK9.js";import{t as r}from"./useRender-CzJUrRlB.js";var i=n(`group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-4xl border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-colors focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!`,{variants:{variant:{default:`bg-primary text-primary-foreground [a]:hover:bg-primary/80`,secondary:`bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80`,destructive:`bg-destructive/10 text-destructive focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:focus-visible:ring-destructive/40 [a]:hover:bg-destructive/20`,outline:`border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground`,ghost:`hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50`,link:`text-primary underline-offset-4 hover:underline`}},defaultVariants:{variant:`default`}});function a({className:n,variant:a=`default`,render:o,...s}){return r({defaultTagName:`span`,props:t({className:e(i({variant:a}),n)},s),render:o,state:{slot:`badge`,variant:a}})}export{a as t};
@@ -0,0 +1 @@
1
+ import{r as e}from"./rolldown-runtime-hePW80VL.js";import{t}from"./react-Cvdyeg_0.js";import{t as n}from"./jsx-runtime-NZYk81nU.js";import{t as r}from"./utils-oBThwhjm.js";import{a as i,t as a}from"./useButton-CvcmqA2s.js";import{t as o}from"./dist-BogNzeK9.js";var s=e(t(),1),c=s.forwardRef(function(e,t){let{render:n,className:r,disabled:o=!1,focusableWhenDisabled:s=!1,nativeButton:c=!0,style:l,...u}=e,{getButtonProps:d,buttonRef:f}=a({disabled:o,focusableWhenDisabled:s,native:c});return i(`button`,e,{state:{disabled:o},ref:[t,f],props:[u,d]})}),l=n(),u=o([`group relative isolate inline-flex items-center justify-center outline-none cursor-pointer`,`transition-colors duration-80`,`disabled:opacity-50 disabled:pointer-events-none`,`focus-visible:ring-1 focus-visible:ring-[color:var(--focus-ring,#6B97FF)]`],{variants:{variant:{default:`text-background`,primary:`text-background`,secondary:`text-foreground`,tertiary:`text-foreground`,outline:`text-foreground`,ghost:`text-muted-foreground hover:text-foreground`,destructive:`text-destructive`,link:`text-primary underline-offset-4 hover:underline`},size:{default:`h-9 px-4 text-[13px] gap-1.5 [&_svg:not([class*='size-'])]:size-4`,compact:`h-7 px-3 text-[12px] gap-1 [&_svg:not([class*='size-'])]:size-3.5`,icon:`h-9 w-9 p-0 [&_svg]:h-4 [&_svg]:w-4`,"icon-compact":`h-7 w-7 p-0 [&_svg]:h-3.5 [&_svg]:w-3.5`},iconLeft:{true:``},iconRight:{true:``}},compoundVariants:[{size:`compact`,iconLeft:!0,className:`pl-2`},{size:`default`,iconLeft:!0,className:`pl-3`},{size:`compact`,iconRight:!0,className:`pr-2`},{size:`default`,iconRight:!0,className:`pr-3`}],defaultVariants:{variant:`primary`,size:`default`}}),d={xs:`compact`,sm:`compact`,md:`default`,lg:`default`,"icon-xs":`icon-compact`,"icon-sm":`icon-compact`,"icon-lg":`icon`},f={default:`[--btn-bg:var(--foreground)] group-hover:[--btn-bg:color-mix(in_oklab,var(--foreground)_90%,var(--background))] group-active:[--btn-bg:color-mix(in_oklab,var(--foreground)_80%,var(--background))] bg-[var(--btn-bg)] shadow-[0_0_0_1px_var(--btn-bg)] group-active:shadow-[0_0_0_0px_var(--btn-bg)]`,primary:`[--btn-bg:var(--foreground)] group-hover:[--btn-bg:color-mix(in_oklab,var(--foreground)_90%,var(--background))] group-active:[--btn-bg:color-mix(in_oklab,var(--foreground)_80%,var(--background))] bg-[var(--btn-bg)] shadow-[0_0_0_1px_var(--btn-bg)] group-active:shadow-[0_0_0_0px_var(--btn-bg)]`,secondary:`[--btn-bg:var(--accent)] group-hover:[--btn-bg:color-mix(in_oklab,var(--accent)_80%,var(--background))] group-active:[--btn-bg:var(--accent)] bg-[var(--btn-bg)] shadow-[0_0_0_1px_var(--btn-bg)] group-active:shadow-[0_0_0_0px_var(--btn-bg)]`,tertiary:`bg-transparent shadow-[0_0_0_1px_var(--border),inset_0_0_0_0px_var(--border)] group-hover:bg-hover group-active:bg-active group-active:shadow-[0_0_0_0px_var(--border),inset_0_0_0_1px_var(--border)]`,outline:`bg-transparent shadow-[0_0_0_1px_var(--border),inset_0_0_0_0px_var(--border)] group-hover:bg-hover group-active:bg-active group-active:shadow-[0_0_0_0px_var(--border),inset_0_0_0_1px_var(--border)]`,ghost:`bg-transparent shadow-[0_0_0_1px_transparent] group-hover:bg-hover group-hover:shadow-[0_0_0_1px_var(--hover)] group-active:bg-active group-active:shadow-[0_0_0_0px_var(--active)]`,destructive:`[--btn-bg:var(--destructive-light,#450A0A)] group-hover:[--btn-bg:color-mix(in_oklab,var(--destructive-light,#450A0A)_80%,var(--background))] group-active:[--btn-bg:var(--destructive-light,#450A0A)] bg-[var(--btn-bg)] shadow-[0_0_0_1px_var(--border)]`,link:`bg-transparent shadow-none`},p={default:`[--btn-bg:color-mix(in_oklab,var(--foreground)_80%,var(--background))] bg-[var(--btn-bg)] shadow-[0_0_0_1px_var(--btn-bg)] group-active:shadow-[0_0_0_0px_var(--btn-bg)]`,primary:`[--btn-bg:color-mix(in_oklab,var(--foreground)_80%,var(--background))] bg-[var(--btn-bg)] shadow-[0_0_0_1px_var(--btn-bg)] group-active:shadow-[0_0_0_0px_var(--btn-bg)]`,secondary:`[--btn-bg:var(--accent)] bg-[var(--btn-bg)] shadow-[0_0_0_1px_var(--btn-bg)] group-active:shadow-[0_0_0_0px_var(--btn-bg)]`,tertiary:`bg-active shadow-[0_0_0_1px_var(--border),inset_0_0_0_0px_var(--border)] group-active:shadow-[0_0_0_0px_var(--border),inset_0_0_0_1px_var(--border)]`,outline:`bg-active shadow-[0_0_0_1px_var(--border),inset_0_0_0_0px_var(--border)] group-active:shadow-[0_0_0_0px_var(--border),inset_0_0_0_1px_var(--border)]`,ghost:`bg-active shadow-[0_0_0_1px_var(--active)] group-active:shadow-[0_0_0_0px_var(--active)]`,destructive:`bg-active shadow-[0_0_0_1px_var(--border)]`,link:`bg-transparent shadow-none`},m=(0,s.forwardRef)(({className:e,variant:t,size:n,asChild:i=!1,loading:a=!1,leadingIcon:o,trailingIcon:m,active:h=!1,disabled:g,children:_,style:v,...y},b)=>{let x=i&&(0,s.isValidElement)(_)?_:null,S=x?x.props.children:_,C=n?d[n]??n:`default`,w=C===`icon`||C===`icon-compact`,T=C===`compact`||C===`icon-compact`,E=T?14:16,D=T?`h-7 w-7`:`h-9 w-9`,O=h?p[t??`primary`]:f[t??`primary`],k=(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(`span`,{"aria-hidden":!0,className:r(`absolute inset-px rounded-[inherit] transition-[box-shadow,background-color] [transition-duration:180ms,80ms] [transition-timing-function:cubic-bezier(0.23,1,0.32,1),ease] group-active:[transition-duration:80ms,80ms]`,O)}),(0,l.jsx)(`span`,{className:`relative inline-flex min-w-0 items-center justify-center gap-[inherit]`,children:a?(0,l.jsxs)(l.Fragment,{children:[(0,l.jsxs)(`span`,{className:`flex min-w-0 items-center justify-center gap-[inherit] opacity-0`,children:[o&&!w&&(0,l.jsx)(o,{size:E,strokeWidth:2}),S,m&&!w&&(0,l.jsx)(m,{size:E,strokeWidth:2})]}),(0,l.jsx)(`span`,{className:`absolute inset-0 flex items-center justify-center`,children:(0,l.jsx)(`svg`,{className:D,viewBox:`0 0 24 24`,fill:`none`,children:(0,l.jsx)(`path`,{d:`M 12 12 C 14 8.5 19 8.5 19 12 C 19 15.5 14 15.5 12 12 C 10 8.5 5 8.5 5 12 C 5 15.5 10 15.5 12 12 Z`,stroke:`currentColor`,strokeWidth:`1.125`,strokeLinecap:`round`,pathLength:`100`,style:{strokeDasharray:`15 85`,animation:`spinner-move 2s linear infinite, spinner-dash 4s ease-in-out infinite`}})})})]}):w?(0,l.jsx)(`span`,{className:`[&_svg]:stroke-[1.5] [&_svg]:transition-[stroke-width] [&_svg]:duration-80 group-hover:[&_svg]:stroke-[2]`,children:S}):(0,l.jsxs)(l.Fragment,{children:[o&&(0,l.jsx)(o,{size:E,strokeWidth:1.5,className:`transition-[stroke-width] duration-80 group-hover:stroke-[2]`}),(0,l.jsx)(`span`,{className:`inline-flex items-center gap-[inherit] min-w-0 [text-box:trim-both_cap_alphabetic] [&_svg]:shrink-0`,children:S}),m&&(0,l.jsx)(m,{size:E,strokeWidth:1.5,className:`transition-[stroke-width] duration-80 group-hover:stroke-[2]`})]})})]}),A=r(u({variant:t,size:C,iconLeft:!w&&!!o,iconRight:!w&&!!m}),`rounded-lg`,e);if(x){let e=x.props,t={...y};for(let n of Object.keys(y)){if(!/^on[A-Z]/.test(n))continue;let r=y[n],i=e[n];typeof r==`function`&&typeof i==`function`&&(t[n]=e=>{i(e),e.defaultPrevented||r(e)})}return(0,s.cloneElement)(x,{...t,ref:b,"data-slot":`button`,className:r(A,e.className),style:{...v,...e.style}},k)}return(0,l.jsx)(c,{ref:b,"data-slot":`button`,className:A,disabled:g||a,style:v,...y,children:k})});m.displayName=`Button`;export{m as t};
@@ -1 +1 @@
1
- import{t as e}from"./jsx-runtime-NZYk81nU.js";import{t}from"./utils-CFDGLzf6.js";var n=e();function r({className:e,size:r=`default`,...i}){return(0,n.jsx)(`div`,{"data-slot":`card`,"data-size":r,className:t(`group/card flex flex-col gap-4 overflow-hidden rounded-xl bg-card py-4 text-sm text-card-foreground ring-1 ring-foreground/10 has-[>img:first-child]:pt-0 data-[size=sm]:gap-3 data-[size=sm]:py-3 *:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl`,e),...i})}function i({className:e,...r}){return(0,n.jsx)(`div`,{"data-slot":`card-header`,className:t(`group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-xl px-4 group-data-[size=sm]/card:px-3 has-data-[slot=card-description]:grid-rows-[auto_auto] [.border-b]:pb-4 group-data-[size=sm]/card:[.border-b]:pb-3`,e),...r})}function a({className:e,...r}){return(0,n.jsx)(`div`,{"data-slot":`card-title`,className:t(`font-heading text-base leading-snug font-medium group-data-[size=sm]/card:text-sm`,e),...r})}function o({className:e,...r}){return(0,n.jsx)(`div`,{"data-slot":`card-description`,className:t(`text-sm text-muted-foreground`,e),...r})}function s({className:e,...r}){return(0,n.jsx)(`div`,{"data-slot":`card-content`,className:t(`px-4 group-data-[size=sm]/card:px-3`,e),...r})}export{a,i,s as n,o as r,r as t};
1
+ import{t as e}from"./jsx-runtime-NZYk81nU.js";import{t}from"./utils-oBThwhjm.js";var n=e();function r({className:e,size:r=`default`,...i}){return(0,n.jsx)(`div`,{"data-slot":`card`,"data-size":r,className:t(`group/card flex flex-col gap-4 overflow-hidden rounded-xl bg-card py-4 text-sm text-card-foreground ring-1 ring-foreground/10 has-[>img:first-child]:pt-0 data-[size=sm]:gap-3 data-[size=sm]:py-3 *:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl`,e),...i})}function i({className:e,...r}){return(0,n.jsx)(`div`,{"data-slot":`card-header`,className:t(`group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-xl px-4 group-data-[size=sm]/card:px-3 has-data-[slot=card-description]:grid-rows-[auto_auto] [.border-b]:pb-4 group-data-[size=sm]/card:[.border-b]:pb-3`,e),...r})}function a({className:e,...r}){return(0,n.jsx)(`div`,{"data-slot":`card-title`,className:t(`font-heading text-base leading-snug font-medium group-data-[size=sm]/card:text-sm`,e),...r})}function o({className:e,...r}){return(0,n.jsx)(`div`,{"data-slot":`card-description`,className:t(`text-sm text-muted-foreground`,e),...r})}function s({className:e,...r}){return(0,n.jsx)(`div`,{"data-slot":`card-content`,className:t(`px-4 group-data-[size=sm]/card:px-3`,e),...r})}export{a,i,s as n,o as r,r as t};
@@ -0,0 +1 @@
1
+ import{r as e}from"./rolldown-runtime-hePW80VL.js";import{t}from"./react-Cvdyeg_0.js";import{t as n}from"./jsx-runtime-NZYk81nU.js";import{t as r}from"./createLucideIcon-CQY2ECfR.js";import{i,n as a,r as o,t as s}from"./sun-C7zg8Oas.js";import{t as c}from"./right-panel-registry-BAJ6TuEY.js";import{t as l}from"./plus-DUP2JPVG.js";import{t as u}from"./square-BbTF3gLc.js";import{a as d,c as f,i as p,n as m,o as h,r as g,s as _}from"./command-xo-NK4xO.js";var v={name:`rotate-ccw-clock`,size:24,node:[[`path`,{d:`M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8`,key:`1357e3`}],[`path`,{d:`M3 3v5h5`,key:`1xhq8a`}],[`path`,{d:`M12 7v5l4 2`,key:`1fdv2h`}]],aliases:[`history`]};v.node;var y=r(v),b=e(t(),1),x=n();function S({open:e,onOpenChange:t,onNewSession:n,onStop:r,onResumeSession:v,onSetRightPanel:S,onThemeChange:C,sessions:w,isStreaming:T,themePreference:E}){let[D,O]=(0,b.useState)(``),[k,A]=(0,b.useState)(e);e!==k&&(A(e),e&&O(``));let j=e=>{e(),t(!1)};return(0,x.jsxs)(m,{open:e,onOpenChange:t,children:[(0,x.jsx)(d,{placeholder:`Type a command or search…`,value:D,onValueChange:O}),(0,x.jsxs)(_,{children:[(0,x.jsx)(g,{children:`No commands found.`}),(0,x.jsxs)(p,{heading:`Actions`,children:[(0,x.jsxs)(h,{onSelect:()=>j(n),keywords:[`new`,`session`,`chat`],children:[(0,x.jsx)(l,{className:`mr-2 size-4`}),(0,x.jsx)(`span`,{children:`New session`})]}),T&&(0,x.jsxs)(h,{onSelect:()=>j(r),keywords:[`stop`,`abort`,`cancel`],children:[(0,x.jsx)(u,{className:`mr-2 size-4`}),(0,x.jsx)(`span`,{children:`Stop generation`})]})]}),(0,x.jsx)(f,{}),(0,x.jsx)(p,{heading:`Panels`,children:c.map(e=>{let t=e.icon;return(0,x.jsxs)(h,{onSelect:()=>j(()=>S(e.id)),keywords:e.commandKeywords,children:[(0,x.jsx)(t,{}),(0,x.jsx)(`span`,{children:e.commandLabel})]},e.id)})}),w.length>0&&(0,x.jsxs)(x.Fragment,{children:[(0,x.jsx)(f,{}),(0,x.jsx)(p,{heading:`Sessions`,children:w.map(e=>{let t=e.title;return(0,x.jsxs)(h,{onSelect:()=>j(()=>v(e)),keywords:[`session`,t],children:[(0,x.jsx)(y,{className:`mr-2 size-4`}),(0,x.jsx)(`span`,{className:`truncate`,children:t})]},e.sessionId)})})]}),(0,x.jsx)(f,{}),(0,x.jsxs)(p,{heading:`Theme`,children:[(0,x.jsxs)(h,{onSelect:()=>j(()=>C(`light`)),keywords:[`theme`,`light`],children:[(0,x.jsx)(s,{className:`mr-2 size-4`}),(0,x.jsx)(`span`,{children:`Light`}),E===`light`&&(0,x.jsx)(i,{className:`ml-auto size-3 opacity-50`})]}),(0,x.jsxs)(h,{onSelect:()=>j(()=>C(`dark`)),keywords:[`theme`,`dark`],children:[(0,x.jsx)(a,{className:`mr-2 size-4`}),(0,x.jsx)(`span`,{children:`Dark`}),E===`dark`&&(0,x.jsx)(i,{className:`ml-auto size-3 opacity-50`})]}),(0,x.jsxs)(h,{onSelect:()=>j(()=>C(`system`)),keywords:[`theme`,`system`],children:[(0,x.jsx)(o,{className:`mr-2 size-4`}),(0,x.jsx)(`span`,{children:`System`}),E===`system`&&(0,x.jsx)(i,{className:`ml-auto size-3 opacity-50`})]})]})]})]})}export{S as ChatCommandPalette};