@qredence/fleet 0.8.0 → 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 (165) hide show
  1. package/CHANGELOG.md +31 -0
  2. package/dist/web/client/assets/DialogTitle-BlVq-tcv.js +1 -0
  3. package/dist/web/client/assets/FloatingPortal-D8-EPDs2.js +1 -0
  4. package/dist/web/client/assets/activity-BPIKUzOU.js +1 -0
  5. package/dist/web/client/assets/agents-CGjUBYX7.js +2 -0
  6. package/dist/web/client/assets/agents-page-CTuFJL9H.js +1 -0
  7. package/dist/web/client/assets/alert-CzWGeumf.js +1 -0
  8. package/dist/web/client/assets/alert-dialog-D-e1Pr4q.js +1 -0
  9. package/dist/web/client/assets/artifacts-panel-6JEdy6jU.js +1 -0
  10. package/dist/web/client/assets/badge-CzQFgmVK.js +1 -0
  11. package/dist/web/client/assets/chat-command-palette-Bxr5EkO6.js +1 -0
  12. package/dist/web/client/assets/chat-hpzV6IA6.js +57 -0
  13. package/dist/web/client/assets/chat-queries-CfZiupub.js +3 -0
  14. package/dist/web/client/assets/clock-3-BwWCSCm_.js +1 -0
  15. package/dist/web/client/assets/{command-imgUMV3r.js → command-xo-NK4xO.js} +1 -1
  16. package/dist/web/client/assets/connectors-CFxLqG2x.js +2 -0
  17. package/dist/web/client/assets/connectors-page-DQJdoAnl.js +1 -0
  18. package/dist/web/client/assets/create-project-dialog-Db-WhUmP.js +1 -0
  19. package/dist/web/client/assets/dialog-CK8dym6z.js +1 -0
  20. package/dist/web/client/assets/{fork-picker-dialog-Cgi48NnT.js → fork-picker-dialog-DSaFeUii.js} +1 -1
  21. package/dist/web/client/assets/globals-DJhWyayo.css +2 -0
  22. package/dist/web/client/assets/index-C9FHZDGw.js +13 -0
  23. package/dist/web/client/assets/{input-7g8_nw-Z.js → input-CBoTMPC_.js} +1 -1
  24. package/dist/web/client/assets/{input-group-Nq03Qums.js → input-group-BFubAtz9.js} +1 -1
  25. package/dist/web/client/assets/mcp-connections-section-DEo6Kemv.js +2 -0
  26. package/dist/web/client/assets/message-queue-Btjt9wK2.js +1 -0
  27. package/dist/web/client/assets/{model-selector-list-Cp687pdm.js → model-selector-list-CbDAT0Rw.js} +1 -1
  28. package/dist/web/client/assets/mutation-Da9zdeWr.js +1 -0
  29. package/dist/web/client/assets/notify-BIL0-CGy.js +1 -0
  30. package/dist/web/client/assets/open-panel-action-message-SdA1VU42.js +1 -0
  31. package/dist/web/client/assets/openui-renderer-DG-iML7M.js +291 -0
  32. package/dist/web/client/assets/pencil-Cbgq3ybX.js +1 -0
  33. package/dist/web/client/assets/plus-DUP2JPVG.js +1 -0
  34. package/dist/web/client/assets/product-page-header-Ck6I13CE.js +1 -0
  35. package/dist/web/client/assets/provider-catalog-CLEDlH_v.js +1 -0
  36. package/dist/web/client/assets/provider-label-BItazQ6H.js +1 -0
  37. package/dist/web/client/assets/right-panel-context-CjX-HkDO.js +1 -0
  38. package/dist/web/client/assets/right-panel-registry-BAJ6TuEY.js +2 -0
  39. package/dist/web/client/assets/rotate-ccw-DLkfsmG9.js +1 -0
  40. package/dist/web/client/assets/routes-ja_liP8Z.js +14 -0
  41. package/dist/web/client/assets/select-DYh951qi.js +1 -0
  42. package/dist/web/client/assets/{session-activity-panel-Bc4-HSfb.js → session-activity-panel-DwaXiSrS.js} +1 -1
  43. package/dist/web/client/assets/{session-insights-panel-D0v_DKcb.js → session-insights-panel-BXEmuJKf.js} +1 -1
  44. package/dist/web/client/assets/{session-tool-renderer-C7mYeUOs.js → session-tool-renderer-DEABxZG3.js} +25 -25
  45. package/dist/web/client/assets/{session-tree-panel-By9m9tGB.js → session-tree-panel-5QgMvXoX.js} +1 -1
  46. package/dist/web/client/assets/settings-dialog-DiikSLhF.js +1 -0
  47. package/dist/web/client/assets/sparkles-CASAe1AI.js +1 -0
  48. package/dist/web/client/assets/{subagent-chat-panel-DsPmLZSf.js → subagent-chat-panel-R2RoX1Yt.js} +1 -1
  49. package/dist/web/client/assets/subagent-transcript-DVZhMo7a.js +1 -0
  50. package/dist/web/client/assets/{subagents-panel-gQ9BLfV3.js → subagents-panel-CMMRUP8F.js} +1 -1
  51. package/dist/web/client/assets/switch-BrxDfsX6.js +1 -0
  52. package/dist/web/client/assets/toast-BNWkgZ0u.js +1 -0
  53. package/dist/web/client/assets/{tool-output-normalizer-CADgEiI4.js → tool-output-normalizer-DDU09Zc6.js} +1 -1
  54. package/dist/web/client/assets/tool-part-normalizer-CF6bmJ0s.js +4 -0
  55. package/dist/web/client/assets/tool-result-7qREIVv_.js +5 -0
  56. package/dist/web/client/assets/tool-timeline-CGhwMeNl.js +2 -0
  57. package/dist/web/client/assets/trash-sm2UyOxe.js +1 -0
  58. package/dist/web/client/assets/types-gIgIxnnG.js +1 -0
  59. package/dist/web/client/assets/useNavigate-CVhM7pag.js +1 -0
  60. package/dist/web/client/assets/useRender-CzJUrRlB.js +1 -0
  61. package/dist/web/client/assets/useScrollLock-BcsteNzT.js +1 -0
  62. package/dist/web/client/assets/with-selector-B_VDO56x.js +1 -0
  63. package/dist/web/client/bundle-budget.json +6 -6
  64. package/dist/web/server/{_tanstack-start-manifest_v-BiNPG4xt-BZTMSM2I.js → _tanstack-start-manifest_v-B6ne-00G-OFX7UD4K.js} +44 -23
  65. package/dist/web/server/agents-BwzqhPjK-ANFHE5AG.js +22 -0
  66. package/dist/web/server/agents-page-DEqPV-eG-BR5MR74O.js +215 -0
  67. package/dist/web/server/{artifacts-panel-CqGBNU4q-UHNMC7PK.js → artifacts-panel-DLO8OfXb-B2ZWCDFP.js} +27 -17
  68. package/dist/web/server/{chat-command-palette-B94-zIEz-ES2ZB4ZF.js → chat-command-palette-CaDQAMAu-KDH7BTDS.js} +22 -13
  69. package/dist/web/server/chunk-2ETDIMNM.js +40 -0
  70. package/dist/web/server/{chunk-2VKVSL6Y.js → chunk-35RIM6VP.js} +128 -127
  71. package/dist/web/server/{chunk-SI5IQSG4.js → chunk-5IE54MRG.js} +8 -7
  72. package/dist/web/server/chunk-5MOXRFX6.js +826 -0
  73. package/dist/web/server/{chunk-FB2QLQTN.js → chunk-6AFVCERK.js} +12 -13
  74. package/dist/web/server/chunk-6GYLXDX3.js +588 -0
  75. package/dist/web/server/chunk-7DQQMT5V.js +8993 -0
  76. package/dist/web/server/chunk-APOS34PW.js +8965 -0
  77. package/dist/web/server/{chunk-YQO36OP6.js → chunk-AXN2OBPF.js} +2 -4
  78. package/dist/web/server/{chunk-E6T36NM5.js → chunk-B5FKCW75.js} +36 -353
  79. package/dist/web/server/chunk-BD7YKYWL.js +1007 -0
  80. package/dist/web/server/{chunk-BAHZXA4D.js → chunk-BZ2EAUZZ.js} +10 -12
  81. package/dist/web/server/chunk-CE7U5QB2.js +42 -0
  82. package/dist/web/server/{chunk-LTTBT3J7.js → chunk-FNV3WZXL.js} +5 -9
  83. package/dist/web/server/{chunk-2FHYWKDN.js → chunk-FSQWWR2M.js} +46 -16
  84. package/dist/web/server/chunk-FT7HNDR5.js +143 -0
  85. package/dist/web/server/chunk-GNXIDE26.js +44 -0
  86. package/dist/web/server/{chunk-EAKPTSWR.js → chunk-HAFELESQ.js} +5 -7
  87. package/dist/web/server/{chunk-K67IDUAI.js → chunk-HUHUPGHT.js} +42 -32
  88. package/dist/web/server/{chunk-WSK55TKE.js → chunk-KBMRRJQN.js} +96 -10
  89. package/dist/web/server/chunk-KDCSEISZ.js +6890 -0
  90. package/dist/web/server/chunk-KSGGSGOA.js +50 -0
  91. package/dist/web/server/chunk-OO7NBFQQ.js +15 -0
  92. package/dist/web/server/{chunk-EL2JCDAM.js → chunk-PQVTLG3E.js} +9 -9
  93. package/dist/web/server/{chunk-LQM6QR7S.js → chunk-Q4ECIATK.js} +61 -47
  94. package/dist/web/server/{chunk-CZLGB3NE.js → chunk-R4BS3KYI.js} +2 -4
  95. package/dist/web/server/chunk-RX2ZJARF.js +73 -0
  96. package/dist/web/server/chunk-TOJA3X5N.js +421 -0
  97. package/dist/web/server/chunk-TQ2RECTH.js +193 -0
  98. package/dist/web/server/{chunk-ABMGW6QH.js → chunk-TTNONWZZ.js} +15871 -15660
  99. package/dist/web/server/chunk-TXZDDJCT.js +5115 -0
  100. package/dist/web/server/{chunk-SGAQVAYL.js → chunk-UDUG3MYZ.js} +2 -2
  101. package/dist/web/server/{chunk-5GUEYYYO.js → chunk-V2GCVTDP.js} +4583 -13665
  102. package/dist/web/server/{chunk-OAYEN3JV.js → chunk-VDEUVEWL.js} +2253 -1
  103. package/dist/web/server/chunk-VM3U6PUU.js +769 -0
  104. package/dist/web/server/connectors-C0xm91Ss-DJVBGD73.js +22 -0
  105. package/dist/web/server/connectors-page-B6tJNZ6c-R5K4NSAT.js +66 -0
  106. package/dist/web/server/{create-project-dialog-CFPX6Ihl-EO4XTINS.js → create-project-dialog-PFPHHWIV-GH7JR5IK.js} +25 -14
  107. package/dist/web/server/{fork-picker-dialog-B2RBFzoZ-R6GXPSPL.js → fork-picker-dialog-DFpKOdAw-JPLJSYYU.js} +7 -10
  108. package/dist/web/server/{markdown-BvCfOB26-VDH4YOQD.js → markdown-Cc8V9dOF-JTNTJKQU.js} +5 -6
  109. package/dist/web/server/{markdown-code-SYc-BQvp-MR4FXT5C.js → markdown-code-gaRnbgNM-V5LIRYCD.js} +7 -8
  110. package/dist/web/server/{message-queue-D32rLiJo-HEBRGH5B.js → message-queue-nQ2_kU82-KKSLYR4S.js} +7 -14
  111. package/dist/web/server/{model-selector-list-DKzt_xEN-5ZPU6XDY.js → model-selector-list-By_G7_Hr-GXT27BZO.js} +12 -14
  112. package/dist/web/server/{openui-renderer-CeVtOdYl-PY37PCJI.js → openui-renderer-B9D8-Av--LFZP4U5V.js} +20 -13
  113. package/dist/web/server/{prompt-suggestions-CpTK_fHV-Q4ILLZKC.js → prompt-suggestions-B67Uy5Rk-5SMTSIFQ.js} +5 -4
  114. package/dist/web/server/{repl-panel-1kSS1UGd-DDM5ADGZ.js → repl-panel-1kSS1UGd-POXRYDDJ.js} +2 -3
  115. package/dist/web/server/{resources-panel-S4NHlpz7-NF7WYYSR.js → resources-panel-CTzOOKPz-5G6RS2D6.js} +18 -10
  116. package/dist/web/server/router-CnBux_Ld-YTVBMJFL.js +23 -0
  117. package/dist/web/server/routes-BUGzvQoO-WW43X7W2.js +124 -0
  118. package/dist/web/server/server.js +3 -3
  119. package/dist/web/server/{session-activity-panel-Bz2GrdMk-PCOXG46X.js → session-activity-panel-f0d3fCm7-I6L5IKFQ.js} +18 -10
  120. package/dist/web/server/{session-insights-panel-CfMX2NRu-6HWZTTAC.js → session-insights-panel-BiVObm_6-AP4FITT7.js} +2 -12
  121. package/dist/web/server/{session-reasoning-panel-CpiTdyQz-O3B5CDKS.js → session-reasoning-panel-QIt_xjP0-FKJWMNHO.js} +17 -9
  122. package/dist/web/server/session-tool-renderer-Cg_ZPHxS-BNQKNJNZ.js +34 -0
  123. package/dist/web/server/{session-tree-panel-CzkE0RFB-P4KWA7S2.js → session-tree-panel-B--el8O5-NZOZJM5L.js} +18 -11
  124. package/dist/web/server/{settings-dialog-BUgVNpr1-THSYIOZL.js → settings-dialog-D_eJN2ia-W47Y474K.js} +102 -790
  125. package/dist/web/server/{subagent-chat-panel-mw3kEFfK-CDYX7LST.js → subagent-chat-panel-C9nWP21E-D5C2TTYD.js} +23 -15
  126. package/dist/web/server/{subagents-panel-2ZJfYrXG-NDJKHJHD.js → subagents-panel-fAKvBNRG-O7QHXNE2.js} +24 -17
  127. package/dist/web/server/{workspace-panel-xznrPDLt-QCJRZOF3.js → workspace-panel-CZMNMU63-SYOSM3B7.js} +23 -15
  128. package/package.json +1 -1
  129. package/dist/web/client/assets/DialogTitle-RY2UDuCY.js +0 -1
  130. package/dist/web/client/assets/FloatingPortal-XC0MCNnD.js +0 -1
  131. package/dist/web/client/assets/action-swap-BWRUNKQA.js +0 -1
  132. package/dist/web/client/assets/alert-dialog-DGNvg0B1.js +0 -1
  133. package/dist/web/client/assets/artifacts-panel-BGXpKRJ7.js +0 -1
  134. package/dist/web/client/assets/badge-DM06QVqB.js +0 -57
  135. package/dist/web/client/assets/chat-command-palette-PenyaZBw.js +0 -1
  136. package/dist/web/client/assets/create-project-dialog-C00d5yCq.js +0 -1
  137. package/dist/web/client/assets/dialog-zCNOQI63.js +0 -1
  138. package/dist/web/client/assets/globals-BuMuB_ea.css +0 -2
  139. package/dist/web/client/assets/index-BqBdQGWs.js +0 -13
  140. package/dist/web/client/assets/message-queue-sSljtjYz.js +0 -1
  141. package/dist/web/client/assets/mutation-DOi2Qgfa.js +0 -1
  142. package/dist/web/client/assets/notify-Cqdu6EV8.js +0 -1
  143. package/dist/web/client/assets/openui-renderer-BdYTcn-_.js +0 -291
  144. package/dist/web/client/assets/provider-label-QrVOwKBO.js +0 -1
  145. package/dist/web/client/assets/right-panel-context-DHKWoetk.js +0 -1
  146. package/dist/web/client/assets/right-panel-registry-BaLZiKny.js +0 -2
  147. package/dist/web/client/assets/routes-BkFkhfO3.js +0 -16
  148. package/dist/web/client/assets/select-BhV4ikeN.js +0 -1
  149. package/dist/web/client/assets/settings-dialog-Dpt4Ha_m.js +0 -2
  150. package/dist/web/client/assets/sparkles-BwVa9zQJ.js +0 -1
  151. package/dist/web/client/assets/subagent-transcript-CNQ9wGk2.js +0 -1
  152. package/dist/web/client/assets/switch-C7Myu-Dt.js +0 -1
  153. package/dist/web/client/assets/toast-DlbKi6K-.js +0 -1
  154. package/dist/web/client/assets/tool-part-normalizer-CYK62WZM.js +0 -4
  155. package/dist/web/client/assets/tool-result-bjAGZ2qm.js +0 -5
  156. package/dist/web/client/assets/tool-timeline-eNqH1zj7.js +0 -2
  157. package/dist/web/client/assets/types-D5hZ8IyV.js +0 -1
  158. package/dist/web/client/assets/useRender-Bbk_fl72.js +0 -1
  159. package/dist/web/server/chunk-2PAW6K4Q.js +0 -56
  160. package/dist/web/server/chunk-7L5PCCYR.js +0 -2287
  161. package/dist/web/server/chunk-FB3UHLLN.js +0 -49
  162. package/dist/web/server/chunk-OSPDNT7S.js +0 -25404
  163. package/dist/web/server/router-DVKxZik_-254GZAJW.js +0 -30
  164. package/dist/web/server/routes-BTxAklRp-UM7ZTLLP.js +0 -140
  165. package/dist/web/server/session-tool-renderer-BZiOxtt1-T3ZGAQKX.js +0 -26
@@ -1,4 +0,0 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/openui-renderer-BdYTcn-_.js","assets/rolldown-runtime-hePW80VL.js","assets/react-Cvdyeg_0.js","assets/react-dom-B7th3XGm.js","assets/jsx-runtime-NZYk81nU.js","assets/FloatingPortal-XC0MCNnD.js","assets/useButton-CvcmqA2s.js","assets/createBaseUIEventDetails-DIxvaz-Y.js","assets/utils-oBThwhjm.js","assets/card-Dj1SnGUU.js","assets/select-BhV4ikeN.js","assets/DialogTitle-RY2UDuCY.js","assets/useBaseUiId-lKfDDIcw.js","assets/check-BTwIaCtI.js","assets/createLucideIcon-CQY2ECfR.js","assets/chevron-down-Bse1ggZM.js","assets/input-7g8_nw-Z.js","assets/useControlled-CkQSkSv1.js","assets/surfaces-BUjUJTyD.js","assets/useRender-Bbk_fl72.js","assets/markdown-CvBfbPCn.js","assets/file-code-corner-BkDULqko.js","assets/button-CWYjn8Zk.js","assets/dist-BogNzeK9.js","assets/clsx-DB0hHKMi.js","assets/preload-helper-BLdHbfdN.js","assets/chunk-D32TOXHM-BM74MRmz.js","assets/space-separated-tokens-Ciu5hotc.js","assets/lib-CJ9xR_xY.js","assets/lib-BvGd2E-G.js","assets/code-block-pKKmFZ5w.js","assets/arrow-left-Bfkw0vUM.js","assets/createLucideIcon-CR62Fawq.js","assets/arrow-up-CzxAS3J9.js","assets/blocks-BmVH6RoL.js","assets/boxes-P3I8BDys.js","assets/calendar-days-CXqvsoor.js","assets/check-check-Btqs36TD.js","assets/check-IbKELFd2.js","assets/chevron-down-D5amraNy.js","assets/chevron-left-AyR1xUDb.js","assets/chevron-right-E-3OemuN.js","assets/chevron-up-DCTJ3XA-.js","assets/circle-alert-CSVDHZOw.js","assets/copy-CLOAxiYY.js","assets/ellipsis-dxrmXw37.js","assets/globe-eVRxbI0y.js","assets/image-1Usfao59.js","assets/info-DJfctP7D.js","assets/lightbulb-BwqxgRpD.js","assets/link-DreltefI.js","assets/list-VCLXYdos.js","assets/loader-circle-BAwTuoks.js","assets/menu-ykZJO64E.js","assets/message-square-CZNlkRgV.js","assets/panel-left-D8Dtrg9O.js","assets/rotate-ccw-3h4Oynp3.js","assets/search-yqNIhSMn.js","assets/share-2-2ysz1TZP.js","assets/square-code-BL_X7jLn.js","assets/square-pen-C4QgEtsH.js","assets/square-DS8IK_lK.js","assets/trash-2-BhumKxcC.js","assets/type-H-QEoR0y.js","assets/x-CXE81yPy.js","assets/character-entities-legacy-Wut6vMuj.js","assets/badge-DM06QVqB.js","assets/dist-BJJVCio8.js","assets/switch-C7Myu-Dt.js","assets/dialog-zCNOQI63.js","assets/x-DEU6H3M-.js","assets/safe-external-url-D3PJJIcM.js","assets/openui-utils-DawGoQNp.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"./react-dom-B7th3XGm.js";import{t as r}from"./jsx-runtime-NZYk81nU.js";import{n as i,r as a,t as o}from"./utils-oBThwhjm.js";import{o as s,r as c,u as l}from"./ease-DYVhTl2n.js";import{n as u,t as d}from"./use-reduced-motion-CFEp5oKr.js";import{o as f}from"./useButton-CvcmqA2s.js";import{t as p}from"./createLucideIcon-CQY2ECfR.js";import{t as m}from"./useRender-Bbk_fl72.js";import{t as h}from"./chevron-right-BPCB1mOg.js";import{n as g,t as _}from"./file-text-cqOanUYv.js";import{t as v}from"./circle-check-DBhaebaM.js";import{n as y}from"./wrench-BXX_Ah2s.js";import{n as b,o as x,t as S}from"./tool-output-normalizer-CADgEiI4.js";import{t as C}from"./loader-circle-BmKYM_C4.js";import{t as w}from"./x-DEU6H3M-.js";import{t as T}from"./dist-BogNzeK9.js";import{t as E}from"./preload-helper-BLdHbfdN.js";import{t as D}from"./openui-utils-DawGoQNp.js";import"./tokens-DinEQBG4.js";import{i as O}from"./workspace-path-nav-D-77sJ_A.js";import{t as k}from"./reasoning-line-DGdPUMwT.js";import{t as A}from"./use-hover-capable-CLq8BADD.js";import{a as j,c as M,i as N,n as P,o as F,r as I,s as L,t as R}from"./trace-IsV5RRvM.js";var z={name:`chevron-left`,size:24,node:[[`path`,{d:`m15 18-6-6 6-6`,key:`1wnfg3`}]]};z.node;var B=p(z),V={name:`file-braces`,size:24,node:[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`M10 12a1 1 0 0 0-1 1v1a1 1 0 0 1-1 1 1 1 0 0 1 1 1v1a1 1 0 0 0 1 1`,key:`1oajmo`}],[`path`,{d:`M14 18a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1 1 1 0 0 1-1-1v-1a1 1 0 0 0-1-1`,key:`mpwhp6`}]],aliases:[`file-json`]};V.node;var ee=p(V),H={name:`file-code`,size:24,node:[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`M10 12.5 8 15l2 2.5`,key:`1tg20x`}],[`path`,{d:`m14 12.5 2 2.5-2 2.5`,key:`yinavb`}]]};H.node;var te=p(H),ne={name:`rotate-cw`,size:24,node:[[`path`,{d:`M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8`,key:`1p45f6`}],[`path`,{d:`M21 3v5h-5`,key:`1q7to0`}]]};ne.node;var re=p(ne),U=e(t(),1),W=r(),ie=(0,U.lazy)(()=>E(async()=>{let{GenerativeTextRenderer:e}=await import(`./openui-renderer-BdYTcn-_.js`);return{GenerativeTextRenderer: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,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72])).then(({GenerativeTextRenderer:e})=>({default:e})));function ae({className:e,content:t}){return(0,W.jsx)(`div`,{className:e?`${e} whitespace-pre-wrap`:`whitespace-pre-wrap`,children:t})}function oe(e){return(0,U.useMemo)(()=>D(e.content).some(e=>e.type===`openui`),[e.content])?(0,W.jsx)(U.Suspense,{fallback:(0,W.jsx)(ae,{className:e.className,content:e.content}),children:(0,W.jsx)(ie,{...e})}):(0,W.jsx)(O,{className:e.className,content:e.content,isStreaming:e.isStreaming})}function se(e){return e.status===`running`||e.status===`recovering`?`streaming`:e.status===`error`||e.status===`failed`?`error`:`ready`}function ce(e,t){let n=new Map(e.map(e=>[e.id,e])),r=new Set,i=[],a=e=>{if(r.has(e))return;r.add(e);let o=n.get(e);o&&i.push(o);for(let n of t?.nodes[e]?.childrenIds??[])a(n)};for(let e of t?.rootChildrenIds??[])a(e);for(let t of e)a(t.id);return i}function le(e){return e===`done`?(0,W.jsx)(v,{className:`size-3.5 text-success`}):e===`error`||e===`failed`?(0,W.jsx)(g,{className:`size-3.5 text-destructive`}):e===`cancelled`?(0,W.jsx)(y,{className:`size-3.5 text-muted-foreground`}):e===`recovering`?(0,W.jsx)(re,{className:`size-3.5 animate-spin text-warning`}):(0,W.jsx)(C,{className:`size-3.5 animate-spin text-primary`})}var G=(0,U.createContext)({from:`assistant`}),ue={type:`spring`,stiffness:480,damping:32,mass:.62},de={duration:.12,ease:c,delay:.04};function fe({from:e,animateIn:t=!1,children:n,className:r,initial:i,animate:a,transition:s,exit:c,style:u,...f}){let p=d()??!1,m=(0,U.useMemo)(()=>({from:e}),[e]);return(0,W.jsx)(G.Provider,{value:m,children:(0,W.jsx)(l.article,{"data-slot":`message`,"data-from":e,"aria-label":f[`aria-label`]??`${e} message`,initial:i??(t&&!p?{opacity:0,transform:`translateY(8px) scale(0.95)`}:!1),animate:a??(t&&!p?{opacity:1,transform:`translateY(0px) scale(1)`}:{opacity:1}),exit:c??(p?{opacity:0}:{opacity:0,transform:`translateY(-3px) scale(0.99)`}),transition:s??(p?{duration:.12}:ue),style:{transformOrigin:e===`user`?`100% 100%`:`0% 100%`,...u},className:o(`group/message flex w-full items-start gap-2`,e===`user`?`flex-row-reverse`:`flex-row`,r),...f,children:n})})}function pe({className:e,...t}){let{from:n}=(0,U.useContext)(G);return(0,W.jsx)(`div`,{"data-slot":`message-content`,className:o(`flex min-w-0 flex-1 flex-col gap-1.5`,n===`user`?`items-end`:`items-start`,e),...t})}function me({variant:e=`ghost`,align:t,className:n,children:r,initial:i,animate:a,exit:c,transition:u,layout:f,...p}){let m=d()??!1,{from:h}=(0,U.useContext)(G),g=t??(h===`user`?`end`:`start`);return(0,W.jsx)(l.div,{"data-slot":`message-bubble`,"data-align":g,"data-variant":e,layout:f,initial:i??!1,animate:a,exit:c??(m?{opacity:0}:{opacity:0,y:-3,scale:.99}),transition:u??(m?{duration:.12}:s),className:o(`group/bubble flex w-full flex-col`,g===`end`?`items-end`:`items-start`,n),...p,children:r})}function he({className:e,children:t,ref:n,...r}){let i=d()??!1;return(0,W.jsx)(`div`,{ref:n,"data-slot":`message-bubble-content`,className:o(`relative z-0 w-full max-w-none min-w-9 text-sm leading-6 text-foreground`,e),...r,children:(0,W.jsx)(l.div,{initial:!1,animate:{opacity:1},transition:i?{duration:.12,ease:c}:de,className:`relative`,children:t})})}var K=56,ge=88;function _e(e,t){if(e.length<=t)return e;let n=e.slice(0,t),r=n.lastIndexOf(` `);return`${n.slice(0,r>t*.65?r:t).trim()}…`}function q(e){return((e.querySelector(`[data-slot="message-bubble-content"]`)??e.querySelector(`[data-slot="message-content"]`)??e).textContent??``).replace(/\s+/g,` `).trim()}function ve(e,t){let n=q(e);if(!n)return{label:`Message`,description:void 0};if(n.length<=K){let e=t?q(t):``;return{label:n,description:e?_e(e,ge):void 0}}let r=n.slice(0,K).lastIndexOf(` `),i=r>K*.65?r:K,a=`${n.slice(0,i).trim()}…`,o=t?q(t):n.slice(i).trim();return{label:a,description:o?_e(o,ge):void 0}}function ye({navigation:e,followThreshold:t,contentRef:n,viewportRef:r,reduce:i,smooth:a,scrollToEnd:o,setFollowing:s,markProgrammaticScroll:c}){let l=(0,U.useRef)(void 0),u=(0,U.useRef)(new WeakMap),d=(0,U.useRef)(0),f=(0,U.useRef)(new Map),[p,m]=(0,U.useState)([]),[h,g]=(0,U.useState)(``),[_,v]=(0,U.useState)(!1),y=(0,U.useCallback)(()=>{if(e!==`rail`)return;let n=r.current,i=[...f.current.entries()];if(!n||i.length===0)return;let a=n.getBoundingClientRect();if(n.scrollTop<=t){let e=i[0]?.[0]??``;g(t=>t===e?t:e);return}if(n.scrollHeight-n.scrollTop-n.clientHeight<=t){let e=i.at(-1)?.[0]??``;g(t=>t===e?t:e);return}let o=a.top+a.height/2,s=i[0]?.[0]??``,c=1/0;for(let[e,t]of i){let n=t.getBoundingClientRect(),r=Math.abs(n.top+n.height/2-o);r<c&&(c=r,s=e)}g(e=>e===s?e:s)},[t,e,r]),b=(0,U.useCallback)(()=>{if(e!==`rail`)return;let t=n.current,i=r.current;if(!t||!i)return;let a=Array.from(t.querySelectorAll(`[data-slot="message"]`)),o=new Map,s=a.map((e,t)=>{let n=u.current.get(e);n||(d.current+=1,n=`message-rail-${d.current}`,u.current.set(e,n)),o.set(n,e);let r=e.dataset.from??`conversation`,i=ve(e,r===`user`?a.slice(t+1).find(e=>e.dataset.from===`assistant`):void 0);return{id:n,label:i.label,description:i.description,ariaLabel:`Go to ${r} message ${t+1} of ${a.length}`}});f.current=o,m(e=>e.length===s.length&&e.every((e,t)=>e.id===s[t]?.id&&e.label===s[t]?.label&&e.description===s[t]?.description&&e.ariaLabel===s[t]?.ariaLabel)?e:s),v(i.scrollHeight>i.clientHeight+1&&a.length>1)},[n,e,r]),x=(0,U.useCallback)(()=>{e===`rail`&&(l.current&&cancelAnimationFrame(l.current),l.current=requestAnimationFrame(()=>{b(),y()}))},[e,b,y]);return(0,U.useEffect)(()=>{if(e!==`rail`){f.current.clear(),m([]),v(!1);return}let t=n.current,i=r.current;if(!t||!i)return;x();let a=typeof MutationObserver>`u`?null:new MutationObserver(x);a?.observe(t,{childList:!0,characterData:!0,subtree:!0});let o=typeof ResizeObserver>`u`?null:new ResizeObserver(x);return o?.observe(t),o?.observe(i),()=>{a?.disconnect(),o?.disconnect()}},[n,e,x,r]),(0,U.useEffect)(()=>()=>{l.current&&cancelAnimationFrame(l.current)},[]),{activeRailId:h,railItems:p,railOverflowing:_,scheduleRailSync:x,scrollToRailItem:(0,U.useCallback)(e=>{let t=r.current,n=f.current.get(e.id);if(!t||!n)return;let l=p.at(-1)?.id===e.id;if(g(e.id),l){s(!0),o(i||!a?`auto`:`smooth`);return}s(!1),c(i||!a?`auto`:`smooth`);let u=t.getBoundingClientRect(),d=n.getBoundingClientRect(),m=t.scrollTop+d.top-u.top-(t.clientHeight-d.height)/2,h=i||!a?`auto`:`smooth`;typeof t.scrollTo==`function`?t.scrollTo({top:m,behavior:h}):t.scrollTop=m},[c,p,i,o,s,a,r])}}function be({item:e}){return(0,W.jsxs)(`div`,{"data-slot":`preview-rail-card`,className:`rounded-2xl border border-border bg-card p-4 shadow-sm`,children:[(0,W.jsx)(`p`,{"data-slot":`preview-rail-title`,className:`font-medium text-card-foreground`,children:e.label}),e.description?(0,W.jsx)(`div`,{"data-slot":`preview-rail-description`,className:`mt-1 text-sm leading-6 text-muted-foreground`,children:e.description}):null]})}function xe({items:e,label:t=`Section navigation`,orientation:n=`vertical`,activeId:r,defaultActiveId:i,onActiveChange:a,onItemSelect:f,renderPreview:p,showPreview:m=!0,previewSide:h=`after`,highlightActive:g=!1,itemSize:_=24,children:v,className:y,railClassName:b,previewContainerClassName:x,previewClassName:S}){let C=(0,U.useId)(),w=d(),T=A(),[E,D]=(0,U.useState)(i??e[0]?.id??``),[O,k]=(0,U.useState)(null),[j,M]=(0,U.useState)(null),N=r??E,P=e.some(e=>e.id===N)?N:e[0]?.id??``,F=O??j??``,I=F||(g?P:``),L=e.findIndex(e=>e.id===I),R=e.length?`repeat(${e.length}, ${_}px)`:void 0,z=n===`horizontal`,B=e=>{r===void 0&&D(e),a?.(e)};return(0,W.jsxs)(l.div,{layoutRoot:!0,onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||M(null)},className:o(`isolate relative flex w-full overflow-visible`,z?`min-h-64 flex-col items-center justify-center`:`min-h-80`,y),children:[(0,W.jsx)(`nav`,{"aria-label":t,onPointerLeave:()=>k(null),style:z?{gridTemplateColumns:R}:{gridTemplateRows:R},className:o(`relative z-10 grid shrink-0`,z?`h-12 w-fit max-w-full self-center justify-center`:`w-12 content-center`,b),children:e.map((e,t)=>{let n=e.id===P,r=e.id===I,i=L<0?1/0:Math.abs(t-L),a=r?1:i===1?.68:i===2?.44:.25,c=(0,W.jsx)(W.Fragment,{children:(0,W.jsx)(l.span,{"data-slot":`preview-rail-tick`,"aria-hidden":`true`,animate:z?{scaleY:a}:{scaleX:a},transition:w?{duration:0}:s,className:o(`block bg-current`,z?`h-12 w-0.5 origin-bottom`:`h-0.5 w-12 origin-left`,r?`text-foreground`:void 0)})}),u=o(`relative flex text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background`,z?`h-12 w-6 items-end justify-center`:`h-6 w-12 items-center`),d=z?{width:_}:{height:_},p=()=>{T&&k(e.id)},m=t=>{t.matches(`:focus-visible`)&&M(e.id)},h=()=>{B(e.id),f?.(e)};return e.href?(0,W.jsx)(`a`,{"data-slot":`preview-rail-item`,href:e.href,target:e.target,rel:e.rel??(e.target===`_blank`?`noreferrer noopener`:void 0),"aria-label":e.ariaLabel??e.label,"aria-current":n?`page`:void 0,onPointerEnter:p,onMouseEnter:p,onPointerDown:()=>M(null),onFocus:e=>m(e.currentTarget),onClick:h,style:d,className:u,children:c},e.id):(0,W.jsx)(`button`,{"data-slot":`preview-rail-item`,type:`button`,"aria-label":e.ariaLabel??e.label,"aria-current":n?`location`:void 0,onPointerEnter:p,onMouseEnter:p,onPointerDown:()=>M(null),onFocus:e=>m(e.currentTarget),onClick:h,style:d,className:u,children:c},e.id)})}),m?(0,W.jsx)(`div`,{"aria-hidden":`true`,style:z?{gridTemplateColumns:R}:{gridTemplateRows:R},className:o(`pointer-events-none absolute z-50 grid`,z?`top-1/2 left-1/2 h-5 w-fit max-w-full -translate-x-1/2 -translate-y-1/2 justify-center`:h===`before`?`inset-y-0 right-16 left-4 content-center`:`inset-y-0 right-4 left-16 content-center`,x),children:e.map(e=>(0,W.jsx)(`div`,{style:z?{width:_}:{height:_},className:o(`relative flex items-center`,z?`justify-center`:void 0),children:(0,W.jsx)(u,{mode:`wait`,initial:!1,children:e.id===F?(0,W.jsx)(l.div,{initial:w?{opacity:0}:{opacity:0,y:4,filter:`blur(6px)`},animate:w?{opacity:1}:{opacity:1,y:0,filter:`blur(0px)`},exit:w?{opacity:0}:{opacity:0,y:-2,filter:`blur(4px)`,transition:{duration:.12,ease:c}},transition:{duration:w?0:.18,ease:c},className:o(z?`absolute bottom-12 left-1/2 w-72 -translate-x-1/2`:o(`w-full max-w-sm`,h===`before`&&`ml-auto`),S),children:(0,W.jsx)(l.div,{layoutId:`preview-rail-card-${C}`,transition:w?{duration:0}:s,children:p?p(e):(0,W.jsx)(be,{item:e})})},e.id):null})},e.id))}):null,v?(0,W.jsx)(`div`,{className:`min-h-0 min-w-0 flex-1`,children:v}):null]})}function Se({followOutput:e=!0,followThreshold:t=56,smooth:n=!0,onFollowChange:r,label:i=`Conversation`,busy:a,navigation:s,navigationLabel:c=`Message navigation`,viewportClassName:l,contentClassName:u,railClassName:f,viewportRef:p,viewportProps:m,contentProps:h,className:g,children:_,...v}){let y=d()??!1,b=(0,U.useRef)(null),x=(0,U.useRef)(null),S=(0,U.useRef)(e),C=(0,U.useRef)(!1),w=(0,U.useRef)(void 0),T=(0,U.useRef)(void 0),{onScroll:E,onWheel:D,onTouchStart:O,onKeyDown:k,...A}=m??{},j=(0,U.useCallback)(e=>{b.current=e,typeof p==`function`?p(e):p&&(p.current=e)},[p]),M=(0,U.useCallback)(e=>{S.current!==e&&(S.current=e,r?.(e))},[r]),N=(0,U.useCallback)(e=>{C.current=!0,w.current&&window.clearTimeout(w.current),w.current=window.setTimeout(()=>{C.current=!1},e===`smooth`?320:0)},[]),P=(0,U.useCallback)(e=>{let t=b.current;t&&(N(e),typeof t.scrollTo==`function`?t.scrollTo({top:t.scrollHeight,behavior:e}):t.scrollTop=t.scrollHeight)},[N]),{activeRailId:F,railItems:I,railOverflowing:L,scheduleRailSync:R,scrollToRailItem:z}=ye({navigation:s,followThreshold:t,contentRef:x,viewportRef:b,reduce:y,smooth:n,scrollToEnd:P,setFollowing:M,markProgrammaticScroll:N}),B=(0,U.useEffectEvent)(R),V=(0,U.useEffectEvent)(P),ee=(0,U.useCallback)(()=>{let e=b.current;if(!e||C.current)return;let n=e.scrollHeight-e.scrollTop-e.clientHeight;M(n<=t),R()},[t,R,M]),H=(0,U.useCallback)(()=>{C.current=!1},[]);(0,U.useLayoutEffect)(()=>{if(S.current=e,e)return T.current=requestAnimationFrame(()=>V(`auto`)),()=>{T.current&&cancelAnimationFrame(T.current)}},[e]),(0,U.useEffect)(()=>{let t=x.current;if(!t||typeof ResizeObserver>`u`)return;let r=new ResizeObserver(()=>{B(),!(!e||!S.current)&&V(y||!n?`auto`:`smooth`)});return r.observe(t),()=>r.disconnect()},[e,y,n]),(0,U.useEffect)(()=>()=>{w.current&&window.clearTimeout(w.current),T.current&&cancelAnimationFrame(T.current)},[]);let te=(0,W.jsx)(`section`,{ref:j,"aria-label":i,...A,onScroll:e=>{ee(),E?.(e)},onWheel:e=>{H(),D?.(e)},onTouchStart:e=>{H(),O?.(e)},onKeyDown:e=>{[`ArrowUp`,`PageUp`,`Home`].includes(e.key)&&H(),k?.(e)},className:o(`h-full overflow-y-auto overscroll-contain outline-none [overflow-anchor:none] focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring`,s===`rail`?`[-ms-overflow-style:none] [scrollbar-width:none] [&::-webkit-scrollbar]:hidden`:`[scrollbar-gutter:stable]`,l,s===`rail`&&L&&`pr-10`),children:(0,W.jsx)(`div`,{ref:x,role:`log`,"aria-live":a?`off`:`polite`,"aria-relevant":`additions text`,"aria-busy":a,className:u,...h,children:_})});return(0,W.jsx)(`div`,{"data-slot":`message-scroller`,className:o(`min-h-0`,g),...v,children:s===`rail`?(0,W.jsx)(xe,{items:L?I:[],label:c,activeId:F,onItemSelect:z,previewSide:`before`,highlightActive:!0,itemSize:14,className:`h-full min-h-0 overflow-hidden`,previewContainerClassName:`right-8 left-3`,previewClassName:`mr-1 w-64 max-w-full [&_[data-slot=preview-rail-card]]:h-20 [&_[data-slot=preview-rail-card]]:overflow-hidden [&_[data-slot=preview-rail-card]]:p-3 [&_[data-slot=preview-rail-title]]:line-clamp-1 [&_[data-slot=preview-rail-title]]:text-xs [&_[data-slot=preview-rail-title]]:leading-4 [&_[data-slot=preview-rail-description]]:line-clamp-2 [&_[data-slot=preview-rail-description]]:text-xs [&_[data-slot=preview-rail-description]]:leading-4`,railClassName:o(`absolute inset-y-3 right-1 w-7 content-center py-1 [&_[data-slot=preview-rail-item]]:w-7 [&_[data-slot=preview-rail-item]]:justify-end [&_[data-slot=preview-rail-tick]]:h-px [&_[data-slot=preview-rail-tick]]:w-4 [&_[data-slot=preview-rail-tick]]:origin-right`,L?`pointer-events-auto opacity-100`:`pointer-events-none opacity-0`,f),children:te}):te})}function J(e){return typeof e==`object`&&!!e}function Ce(e){return J(e)&&e.type===`text`&&typeof e.text==`string`}function we(e){return J(e)&&e.type===`error`&&typeof e.message==`string`}function Te(e){return J(e)&&e.type===`payload`&&typeof e.kind==`string`&&typeof e.title==`string`}function Y(e){if(!J(e))return!1;let t=e.type;return t===`dynamic-tool`||typeof t==`string`&&t.startsWith(`tool-`)}function Ee(e){if(typeof e==`string`)return e;if(e===void 0)return``;try{return JSON.stringify(e,null,2)??``}catch{return String(e)}}function De({part:e}){let t=Ee(e.payload);return e.kind===`agent_message`?t||e.text?(0,W.jsxs)(`section`,{"data-payload-kind":e.kind,className:`w-full min-w-0 text-xs text-muted-foreground`,children:[e.text?(0,W.jsx)(`pre`,{className:`m-0 whitespace-pre-wrap break-words p-3 font-mono text-xs leading-5 text-foreground/80`,children:e.text}):null,t?(0,W.jsxs)(`details`,{children:[(0,W.jsx)(`summary`,{className:`w-fit cursor-pointer py-1 font-medium`,children:`Details`}),(0,W.jsx)(`pre`,{className:`m-0 max-h-60 overflow-auto whitespace-pre-wrap break-words border-l border-border pl-3 font-mono text-xs leading-5`,children:t})]}):null]}):null:(0,W.jsxs)(`section`,{"data-payload-kind":e.kind,className:`w-full min-w-0 overflow-hidden rounded-xl border border-border/60 bg-muted/40 text-sm`,children:[e.title===`Details`?null:(0,W.jsx)(`div`,{className:`border-b border-border/50 px-3 py-2 text-xs font-medium text-muted-foreground`,children:e.title}),e.text?(0,W.jsx)(`pre`,{className:`m-0 whitespace-pre-wrap break-words p-3 font-mono text-xs leading-5 text-foreground/80`,children:e.text}):null,t?(0,W.jsxs)(`details`,{className:`border-t border-border/50 px-3 py-2`,children:[(0,W.jsx)(`summary`,{className:`cursor-pointer text-xs font-medium text-muted-foreground`,children:`Payload`}),(0,W.jsx)(`pre`,{className:`m-0 mt-2 max-w-full whitespace-pre-wrap break-words font-mono text-xs leading-5 text-foreground/70`,children:t})]}):null]})}var Oe=[],ke=(0,U.memo)(function({title:e=`Unable to complete request`,message:t,className:n}){return(0,W.jsx)(`div`,{className:o(`flex justify-start`,n),children:(0,W.jsxs)(`div`,{className:`rounded-lg border border-destructive/30 bg-destructive/10 px-4 py-2.5 text-sm text-foreground`,children:[(0,W.jsx)(`div`,{className:`font-medium text-foreground`,children:e}),(0,W.jsx)(`div`,{className:`mt-0.5 text-muted-foreground`,children:t})]})})}),Ae=`tool-call:`,je=`unkeyed-tool:`;function Me(e,t,n){return t.toolCallId?`${Ae}${t.toolCallId}`:`${je}${e}:${t.type}:${n}`}function Ne(e,t){let{messageId:n,isLast:r,isStreaming:i,suppressQuestionTool:a,suppressTextWhenPlanWrite:o=!1,ToolRendererComponent:s,TextRendererComponent:c,toolRenderers:l,onOpenUIAction:u,onOpenUIArtifactReady:d,onOpenArtifact:f,artifactByToolCallId:p,onOpenToolArtifact:m}=t,h=[],g=[],_=o&&e.some(e=>Y(e)&&e.type===`tool-PlanWrite`),v=new Set(e.filter(e=>Y(e)&&(e.type===`tool-Task`||e.type===`tool-Agent`)&&typeof e.toolCallId==`string`).map(e=>e.toolCallId)),y=new Map,x=new Set,C=new Map,w=()=>{let e=g.splice(0).join(`
3
-
4
- `);e&&h.push((0,W.jsx)(`div`,{className:`group/assistant-text text-body [&_a]:font-medium [&_a]:underline [&_a]:underline-offset-4 [&_ol]:my-2 [&_ol]:list-decimal [&_ol]:pl-5 [&_p+p]:mt-2 [&_ul]:my-2 [&_ul]:list-disc [&_ul]:pl-5`,children:(0,W.jsx)(c,{content:e,isStreaming:i,messageId:n,onOpenUIAction:u,onOpenUIArtifactReady:d,onOpenArtifact:f,className:`leading-relaxed [&_p]:leading-relaxed`})},`${n}-text-${h.length}`))};for(let t of e){if(!Y(t)||t.type===`tool-TaskOutput`||!t.toolCallId||!t.toolCallId.includes(`:`))continue;let e=t.toolCallId.split(`:`)[0];v.has(e)&&(y.has(e)||y.set(e,[]),y.get(e).push(t),x.add(t.toolCallId))}let T=0;for(;T<e.length;){let t=e[T];if(typeof t==`object`&&t&&`type`in t&&t.type===`reasoning`&&`text`in t&&typeof t.text==`string`&&`contentIndex`in t&&typeof t.contentIndex==`number`&&`state`in t&&typeof t.state==`string`){w(),h.push((0,W.jsx)(k,{text:t.text,streaming:r&&i&&t.state===`streaming`,durationMs:`durationMs`in t&&typeof t.durationMs==`number`?t.durationMs:void 0},`${n}-reasoning-${t.contentIndex}`)),T++;continue}if(Y(t)&&t.type===`tool-TaskOutput`){T++;continue}if(Ce(t)){let e=t.text;e&&!_&&g.push(e),T++;continue}if(we(t)){w(),h.push((0,W.jsx)(ke,{title:t.title,message:t.message},`${n}-error-${t.title}-${t.message}`)),T++;continue}if(Te(t)){w(),h.push((0,W.jsx)(De,{part:t},`${n}-payload-${T}`)),T++;continue}if(Y(t)){if(a&&t.type===`tool-Question`){T++;continue}if(t.toolCallId&&x.has(t.toolCallId)){T++;continue}w();let e=typeof t.state==`string`?t.state:``,o=r&&i&&(e===`input-streaming`||e===`streaming`)?`streaming`:void 0,c=e===`input-available`||e===`pending`,u=S(t,o),d=b(t.type.replace(/^tool-/,``)),f=u?.status===`error`,g=u?.status===`cancelled`,_=`Details for ${t.type.replace(/^tool-/,``)}${t.toolCallId?` (${t.toolCallId})`:``}`,v=t.toolCallId?p?.get(t.toolCallId):void 0,E=t.toolCallId,D=(t.type===`tool-Task`||t.type===`tool-Agent`)&&E?y.get(E)??Oe:void 0,O=t.toolCallId?0:C.get(t.type)??0;t.toolCallId||C.set(t.type,O+1),h.push((0,W.jsxs)(R,{className:`my-1 flex-row items-center`,"data-testid":`assistant-tool-trace`,children:[(0,W.jsxs)(P,{defaultOpen:t.type===`tool-Question`||t.type===`tool-PlanWrite`&&!!t.input?.pendingDecision,children:[(0,W.jsx)(N,{"aria-label":_,children:(0,W.jsxs)(L,{status:f?`error`:o?`running`:c?`pending`:void 0,children:[(0,W.jsx)(F,{children:(0,W.jsx)(d,{})}),(0,W.jsx)(M,{children:t.type.replace(/^tool-/,``)}),u?.traceDescription?(0,W.jsx)(j,{className:`max-w-48 truncate`,title:u.traceDescription,children:u.traceDescription}):null,(0,W.jsx)(j,{className:u?.outputSummary.isError?`text-destructive`:void 0,children:f?`failed`:o?`running`:c?`waiting`:g?`cancelled`:u?.outputSummary.isError?`reported error`:`done`}),u?.durationLabel?(0,W.jsx)(j,{children:u.durationLabel}):null]})}),(0,W.jsx)(I,{children:(0,W.jsx)(s,{part:t,nestedTools:D,chatStatus:o,toolRenderers:l,insideTrace:!0})})]}),v&&m?(0,W.jsx)(`button`,{type:`button`,className:`shrink-0 text-micro underline`,"aria-label":`Open ${v.title} in ${v.kind===`ipython`?`REPL`:`artifacts`}`,onClick:()=>m(v.id,v.kind===`ipython`?`repl`:`artifacts`),children:`Open`}):null]},Me(n,t,O))),T++;continue}T++}return w(),h}var Pe=e(n(),1);function Fe({open:e,onClose:t,images:n,initialIndex:r=0}){let[i,a]=(0,U.useState)(r),s=n.length>1;(0,U.useEffect)(()=>{e&&a(r)},[e,r]);let c=(0,U.useCallback)(e=>{e?.stopPropagation(),a(e=>e>0?e-1:n.length-1)},[n.length]),l=(0,U.useCallback)(e=>{e?.stopPropagation(),a(e=>e<n.length-1?e+1:0)},[n.length]),u=(0,U.useEffectEvent)(e=>{switch(e.key){case`ArrowLeft`:e.preventDefault(),s&&c();break;case`ArrowRight`:e.preventDefault(),s&&l()}});(0,U.useEffect)(()=>{if(!e)return;let t=e=>u(e);return window.addEventListener(`keydown`,t,!0),()=>window.removeEventListener(`keydown`,t,!0)},[e]),(0,U.useEffect)(()=>{if(!e)return;let t=document.body.style.overflow;return document.body.style.overflow=`hidden`,()=>{document.body.style.overflow=t}},[e]);let d=(0,U.useRef)(null),f=(0,U.useEffectEvent)(e=>{d.current&&e.target===d.current&&t()});if((0,U.useEffect)(()=>{if(!e)return;let t=d.current;if(!t)return;t.open||t.showModal();let n=e=>f(e);return t.addEventListener(`click`,n),()=>{t.removeEventListener(`click`,n),t.open&&t.close()}},[e]),typeof document>`u`||!e)return null;let p=n[i]??n[0];return p?.url?(0,Pe.createPortal)((0,W.jsxs)(`dialog`,{ref:d,"aria-label":`Image viewer`,onClose:()=>t(),className:`fixed inset-0 z-50 m-0 flex h-full max-h-none w-full max-w-none items-center justify-center border-0 bg-black/90 p-0 backdrop:bg-transparent`,children:[(0,W.jsx)(`button`,{type:`button`,onClick:t,"aria-label":`Close fullscreen (Esc)`,className:`absolute top-4 right-4 z-10 inline-flex size-9 items-center justify-center rounded-full bg-black/50 text-white transition-colors hover:bg-black/70`,children:(0,W.jsx)(w,{className:`size-5`})}),s&&(0,W.jsx)(`button`,{type:`button`,onClick:c,"aria-label":`Previous image (←)`,className:`absolute top-1/2 left-4 z-10 inline-flex size-10 -translate-y-1/2 items-center justify-center rounded-full bg-black/50 text-white transition-colors hover:bg-black/70`,children:(0,W.jsx)(B,{className:`size-6`})}),(0,W.jsx)(`img`,{src:p.url,alt:p.filename??`Image preview`,className:`max-h-[85vh] max-w-[90vw] object-contain select-none`,onClick:e=>e.stopPropagation(),draggable:!1}),s&&(0,W.jsx)(`button`,{type:`button`,onClick:l,"aria-label":`Next image (→)`,className:`absolute top-1/2 right-4 z-10 inline-flex size-10 -translate-y-1/2 items-center justify-center rounded-full bg-black/50 text-white transition-colors hover:bg-black/70`,children:(0,W.jsx)(h,{className:`size-6`})}),s&&(0,W.jsxs)(`div`,{className:`absolute bottom-6 left-1/2 flex -translate-x-1/2 flex-col items-center gap-3`,children:[(0,W.jsx)(`div`,{className:`flex gap-2`,children:n.map((e,t)=>(0,W.jsx)(`button`,{type:`button`,onClick:e=>{e.stopPropagation(),a(t)},"aria-label":`Go to image ${t+1}`,className:o(`size-2 rounded-full transition-[background-color,transform] duration-150`,t===i?`scale-125 bg-white`:`bg-white/40 hover:bg-white/60`)},e.url))}),(0,W.jsxs)(`span`,{className:`text-sm tabular-nums text-white/70`,children:[i+1,` / `,n.length]})]})]}),document.body):null}function Ie(e){return e<1024?`${e} B`:e<1048576?`${(e/1024).toFixed(1)} KB`:`${(e/1048576).toFixed(1)} MB`}function Le(e,t){if(t)return`image`;let n=e.split(`.`).pop()?.toLowerCase();return[`js`,`ts`,`jsx`,`tsx`,`py`,`rb`,`go`,`rs`,`java`,`kt`,`swift`,`c`,`cpp`,`h`,`hpp`,`cs`,`php`].includes(n||``)?`code`:[`json`,`yaml`,`yml`,`xml`].includes(n||``)?`data`:`text`}function Re(e){switch(e){case`image`:return(0,W.jsx)(x,{"aria-hidden":`true`,className:`size-4 text-muted-foreground`});case`code`:return(0,W.jsx)(te,{"aria-hidden":`true`,className:`size-4 text-muted-foreground`});case`data`:return(0,W.jsx)(ee,{"aria-hidden":`true`,className:`size-4 text-muted-foreground`});default:return(0,W.jsx)(_,{"aria-hidden":`true`,className:`size-4 text-muted-foreground`})}}function ze({id:e,filename:t,size:n,isImage:r,url:i,onRemove:a,className:s,display:c=`chip`,enableImagePreview:l=!0}){let[u,d]=(0,U.useState)(!1),[f,p]=(0,U.useState)(!1),m=Le(t,r),h=c===`image-only`&&r&&!!i,g=!!(l&&r&&i),_=e=>{e?.stopPropagation(),p(!0)},v=o(`shrink-0 overflow-hidden rounded-[calc(var(--chat-input-radius)-var(--chat-context-padding)-2px)]`,g&&`cursor-pointer focus-visible:ring-2 focus-visible:ring-ring`);return(0,W.jsxs)(`div`,{className:o(`group relative rounded-[calc(var(--chat-input-radius)-var(--chat-context-padding))] bg-muted/50`,h?`flex size-10 items-center justify-center`:`flex max-w-[min(12.5rem,100%)] min-w-0 items-center gap-2 py-1 ps-1 pe-2`,s),onMouseEnter:()=>d(!0),onMouseLeave:()=>d(!1),children:[h?g?(0,W.jsx)(`button`,{type:`button`,className:o(v,`size-8 border-0 bg-transparent p-0`),onClick:_,"aria-label":`Preview ${t}`,children:(0,W.jsx)(`img`,{src:i,alt:``,className:`h-full w-full object-cover`})}):(0,W.jsx)(`div`,{className:o(v,`size-8`),children:(0,W.jsx)(`img`,{src:i,alt:t,className:`h-full w-full object-cover`})}):(0,W.jsxs)(W.Fragment,{children:[r&&i?g?(0,W.jsx)(`button`,{type:`button`,className:o(v,`w-8 self-stretch border-0 bg-transparent p-0`),onClick:_,"aria-label":`Preview ${t}`,children:(0,W.jsx)(`img`,{src:i,alt:``,className:`aspect-square h-full w-full object-cover`})}):(0,W.jsx)(`div`,{className:o(v,`w-8 self-stretch`),children:(0,W.jsx)(`img`,{src:i,alt:t,className:`aspect-square h-full w-full object-cover`})}):(0,W.jsx)(`div`,{className:`flex w-8 shrink-0 items-center justify-center self-stretch rounded-[calc(var(--chat-input-radius)-var(--chat-context-padding)-2px)] bg-muted`,children:Re(m)}),(0,W.jsxs)(`div`,{className:`flex min-w-0 flex-col`,children:[(0,W.jsx)(`span`,{className:`truncate text-sm font-medium text-foreground`,title:t,children:t}),n!==void 0&&(0,W.jsx)(`span`,{className:`text-micro text-muted-foreground`,children:Ie(n)})]})]}),a&&(0,W.jsx)(`button`,{onClick:e=>{e.stopPropagation(),a()},"aria-label":`Remove ${t}`,className:o(`relative after:absolute after:top-1/2 after:left-1/2 after:size-10 after:-translate-x-1/2 after:-translate-y-1/2`,`absolute -top-1.5 -end-1.5 z-10 flex size-6 items-center justify-center rounded-full border border-border bg-background text-muted-foreground transition-[opacity,transform] duration-150 ease-out hover:text-foreground focus-visible:opacity-100 focus-visible:ring-2 focus-visible:ring-ring enabled:active:scale-[0.96] group-hover:opacity-100 group-focus-within:opacity-100 [@media(hover:none)]:opacity-100`,u?`opacity-100`:`opacity-0`),type:`button`,children:(0,W.jsx)(w,{"aria-hidden":`true`,className:`size-3`})}),g&&i&&(0,W.jsx)(Fe,{open:f,onClose:()=>p(!1),images:[{id:e,url:i,filename:t}]})]})}var Be=48,X=(e,t=0)=>{let n=new Int32Array(e.length);for(let r=0;r<e.length;r++)n[r]=e.charCodeAt(r)-Be-t;return n},Z=e=>{let t=new Int32Array(e.length+1);for(let n=0;n<e.length;n++)t[n+1]=t[n]+e[n];return t},Q=e=>{let t=new Int32Array(e.length),n=0;for(let r=0;r<e.length;r++){let i=e.charCodeAt(r)-Be;n+=i>>>1^-(i&1),t[r]=n}return t},Ve=384,He=[],$=Z(X(`E0500002005282000000002000150000020021820000011200000003022202000300004200120000200420001200021200301200010400162000010000220021010:2192001200220012000220012000200200200400010200040000000000400200108200110100000022010313000162002000020020012020080213000228200000000082000000000120002000120020020040101020300130001001010`)),Ue=Z(X(`:11111111211111119311546544411119731869:671397415686432441111111111161114151214313433415:78311132233313187211117221449443411141111151152226611131111112212518142224214215421421542142424242516171151615616347111111111197911327451111111111111111111113134714133513411111311111111111111111111112444411111342312715245411117:3`)),We=`@containerabcdefghinlmoprstunderlineviawzccentlignnimatespectuto-colsrowsaglorightnessckdrop-sisbcontrastfiltergrayscalehue-rotateinvertopacityslurrightnessaturateepia-coniclinearpositionradialsizeockurrderttom-belrstxyespacing-xyaretoursorlnt-umnsendspantartainentrasteividerop-shadowurationcorationlay-xyasendillexontromlter-featuresstretchapr-xyayscaleidow-colsrowsue-rotatedentlinesetvert-beringsxyeshadoweiadingftnest-clamp-imageabein-lrstxyskx--b-coniclpositionrsizet-x-y-fromto-fromto-inearfromto-fromto-adialfromto-fromtofromtofromtofromtoblockhinlinew-screenesblockhinlinewbjectpacityrutlinederigin-offsetbelrstxyesrspective-originaceholderioghtng-offsettateundedw-xyz-belrstlreseslr-endspantartaturatecepiahizekewpace-taleroll-xyz-barmpbelrstxyesbelrstxyes-thumbrackadowrink-xyxyartrokeabextora-shadowpckingnsformitionlate-xyz-offsetill-changeoom`,Ge=(()=>{let e=$.length-1,t=new Int32Array(e);for(let n=e-1;n>=0;n--){let e=1,r=n+1;for(let i=$[n];i<$[n+1];i++)e+=t[r],r+=t[r];t[n]=e}let n=new Int32Array($[e]),r=0;for(let i=0;i<e;i++){let e=i+1;for(let a=$[i];a<$[i+1];a++)n[r++]=e,e+=t[e]}return n})(),Ke=X(`02000000000000900<=0?000B000F00F00ŏI0J0LNPRTVX0000]_a00000000000000000000000rst0000000zŏ00000000000…ŏ000ˆ0000ŏ0000000000—0000000000000000000000000000000000000000000000000000Ë000000000000000000000Þ000000000000000000ð0000000ø0ùúûüýþÿĀāĂ㥹Ć000000000000000000000000000000000000000000ħ0ĨĪ00000000000000000000ļĽ00000Ŭ000000`,1),qe=Z(X(`123333359346463635126536711576`)),Je=X(`93203242332583253248325D>E?F@03263243255B:032523853:0325B:8GA032542H<C=12727B:0328432553;D>E?3257D>032585:0325B:;0328B:032`),Ye=X(`012113445661666666789111:5;;;;;;;;444;;;:62999<1161=62>>?61:21@ABCD4446996:64E:::;:?::64:F114GHHIHHHHIHH1HH1HH1HHHHHH::EEJ4444::EE4444441691;644444114244444:;K6666555555555555555999666664444444444444444444444226?6:66644L9M?D:111::::6DE199`),Xe=Q(`020200202020020020020020020020200200200200200200200002020202001003040106000200200200200200200200200200200200200200200200200200200200200200200200200200200200020020020020020020002020200202002002002002002002002002002020002002020020200220200200200200200200200200200200020020020000200020002000200200200020020020002000200200200020020202002020202000200200020022000200200020020002002000200220002002000200W0Z00020020002002020002002000200g0j0002002000200200020020002002000200200020020002000200002000002002002002002000200020000200002002002002002002002020020020200200200200200200200200202020020020020020020020020002002002020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020020002002002002002002000200200200200200200200200200020202020002000200020002002002002000020200200`),Ze=(()=>{let e=new Int32Array(319).fill(-1),t=Q(`02422242:222222242224222242442222222422222244442242226224222426222422442462222422622222222626222462242622422622422424242422222222422222222242422222222222222222622442224222222222222224424442262222222222222222222226224222424242422224422422422222`),n=Q(`02222222222222222222202222222222222222222222221422222222222222222222222222222222222Y\\222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222222221422222222222222222222222222222222222222Ŀł222222222222222222`);for(let r=0;r<t.length;r++)e[t[r]]=n[r];return e})(),Qe=`container |break-after- all auto avoid avoid-page column left page right|break-before- all auto avoid avoid-page column left page right|break-inside-a uto void void-column void-page|box-decoration- clone slice|box- border content| contents flow-root hidden table table-caption table-cell table-column table-column-group table-footer-group table-header-group table-row table-row-group| not-sr-only sr-only|float- end left none right start|clear- both end left none right start|isolat e ion-auto|overflow- auto clip hidden scroll visible|overflow-x- auto clip hidden scroll visible|overflow-y- auto clip hidden scroll visible|overscroll- auto contain none|overscroll-x- auto contain none|overscroll-y- auto contain none| absolute fixed relative static sticky| collapse invisible visible|justify- around baseline between center center-safe end end-safe evenly normal start stretch|justify-items- center center-safe end end-safe normal start stretch|justify-self- auto center center-safe end end-safe start stretch|items- baseline baseline-last center center-safe end end-safe start stretch|self- auto baseline baseline-last center center-safe end end-safe start stretch|place-content- around baseline between center center-safe end end-safe evenly start stretch|place-items- baseline center center-safe end end-safe start stretch|place-self- auto center center-safe end end-safe start stretch| antialiased subpixel-antialiased| italic not-italic|normal-nums |ordinal |slashed-zero | lining-nums oldstyle-nums| proportional-nums tabular-nums| diagonal-fractions stacked-fractions| no-underline overline| capitalize lowercase normal-case uppercase|truncate |whitespace- break-spaces normal nowrap pre pre-line pre-wrap|break- all keep normal words|wrap- anywhere break-word normal|hyphens- auto manual none|mix-blend- color color-burn color-dodge darken difference exclusion hard-light hue lighten luminosity multiply normal overlay plus-darker plus-lighter saturation screen soft-light|table- auto fixed|caption- bottom top|backface- hidden visible|appearance- auto none|scheme- dark light light-dark normal only-dark only-light|field-sizing- content fixed|pointer-events- auto none|resize -none -x -y|snap- align-none center end start|snap- always normal|snap- both none x y|snap- mandatory proximity|touch- auto manipulation none|touch-pan- left right x|touch-pan- down up y|touch-pinch-zoom |select- all auto none text|forced-color-adjust- auto none| normal size| baseline bottom middle sub super text-bottom text-top top| bounce none ping pulse spin| auto square video| auto fr max min px|none | auto full px| fixed local scroll|clip- border content padding text|origin- border content padding| bottom bottom-left bottom-right center left left-bottom left-top right right-bottom right-top top top-left top-right| no-repeat repeat repeat-round repeat-space repeat-x repeat-y| auto contain cover| gradient-to-b gradient-to-bl gradient-to-br gradient-to-l gradient-to-r gradient-to-t gradient-to-tl gradient-to-tr none|blend- color color-burn color-dodge darken difference exclusion hard-light hue lighten luminosity multiply normal overlay saturation screen soft-light|to- b bl br l r t tl tr| auto dvh fit full lh lvh max min px screen svh| dashed dotted double hidden none solid| collapse separate|px |auto |full | content none strict| inline-size size|layout |paint |style | around baseline between center center-safe end end-safe evenly normal start stretch| alias all-scroll auto cell col-resize context-menu copy crosshair default e-resize ew-resize grab grabbing help move n-resize ne-resize nesw-resize no-drop none not-allowed ns-resize nw-resize nwse-resize pointer progress row-resize s-resize se-resize sw-resize text vertical-text w-resize wait zoom-in zoom-out| dashed dotted double solid wavy| auto from-font|reverse |initial | in in-out initial linear out| col col-reverse row row-reverse| nowrap wrap wrap-reverse| auto initial none| black bold extrabold extralight light medium normal semibold thin| condensed expanded extra-condensed extra-expanded normal semi-condensed semi-expanded ultra-condensed ultra-expanded|flow- col col-dense dense row row-dense| none subgrid| auto dvh dvw fit full lh lvh lvw max min px screen svh svw| block flex grid table| auto dvw fit full lvw max min px screen svw| loose none normal px relaxed snug tight|through |item | inside outside| decimal disc none| auto px| clip-border clip-content clip-fill clip-padding clip-stroke clip-view no-clip| add exclude intersect subtract| alpha luminance match|origin- border content fill padding stroke view|type- alpha luminance| circle ellipse| closest-corner closest-side farthest-corner farthest-side|at- bottom bottom-left bottom-right center left left-bottom left-top right right-bottom right-top top top-left top-right| dvh fit full lh lvh max min none px screen svh| auto dvh dvw fit full lh lvh lvw max min none px screen svh svw| dvw fit full lvw max min none px screen svw| auto dvh dvw fit full lvh lvw max min none prose px svh svw| auto dvh dvw fit full lvh lvw max min none px screen svh svw| contain cover fill none scale-down| first last none| distant dramatic midrange near none normal|inset | full none|3d | auto smooth|gutter- auto both stable| auto none thin| inner none| auto dvh dvw fit full lvh lvw max min px svh svw|base | center end justify left right start| clip ellipsis| balance nowrap pretty wrap| normal tight tighter wide wider widest| cpu gpu none| 3d flat| all colors none opacity shadow transform| discrete normal| full px| auto dvh dvw fit full lvh lvw max min px screen svh svw| auto contents scroll transform`.split(`|`).map(e=>{let t=e.split(` `),n=t.shift();for(let e=0;e<t.length;e++)t[e]=n+t[e];return t}),$e=Q(`0000000000000000000000000000000000000000000000000000000000000262242:6@200000006:240B428:4422400002046044222426220026642642462026224222824220022400000000\\00N222422242222222224062242222222422226264222422222222222222442804222422222222222222222222220<4<0204260002444020204224422`),et=Q(`ɠ222222222222222222222222222222222222222222222222222222222222˕4222226>ʶ22ʷʺʷ2ʸʷ42ʴ2ʓ22>621422ɶ222ɹɼɷɺɷɺ22ɱ42222ɨ2ɧ26622ɘɓ244ƸƵ222]d24242ǖǓƚÄȫ2263ȨȥȨ2222222ǣ222222222222222222ǂƽ2ƾƵ2222222422222ƜƑ22222222222222222222144Ŧţ22Ţş222222222222222222222ĸ2ı68ĦģĦɡŰ4Ġ«®ĝ822ĔđĔ2ē2222622`),tt=Q(`02222222222222222222222222222222222222222222222222222222222222222202022222222222EH2200IL021042222Y\\222IL0cf2e10j2222U00X202[^2y0000120|{~‚22…ˆ‡:22|22222222222G000q†OVI00000}š2›>40000ŒB00000I¨©000¬00000000000000021M®­00°“000000000000000000000–222›HGHa1º222¿2À2222ÉÌ000­°2±`),nt=new Int32Array(995),rt=new Int32Array(995),it=new Int32Array(995),at=``,ot=new Int32Array(1038);{let e=new Map,t=0,n=0;for(let r=0;r<$e.length;r++)for(let i of Qe[tt[r]]){let a=e.get(i);a===void 0&&(a=t++,e.set(i,a),ot[a*2]=at.length,ot[a*2+1]=i.length,at+=i),nt[n]=$e[r],rt[n]=et[r],it[n]=a,n++}}var st=Q(`0b2N:222@R>F@286¦2@H2D266226FB22B2>BD\\6N22222Z222D222p`),ct=Z(X(`1::24444432:442:44:44>222222:44:4421322511111311111114`)),lt=Q(`2Š4A;33N=C@H4A;33N=C@<27;83:;8393NQ:3NQʰ222ˉºŴŽ2R2=18cƴÅҜ=cĞÛC1ƈǝȈ:ħ25=11D3A@4=<1;1DEr25;11B3?<6;:371BCn9@7=<8192>2E121@9@EHE@9>2T25511<398454131<=V25511<398454131<=„ƧNž2Đå242L222290000f22500ɛ000ǘ222`),ut=X(`ij`),dt=X(`—`),ft=X(`1`),pt=i({GROUP_COUNT:Ve,customValidatorNames:He,edgeStart:$,labelStart:Ue,labelText:We,edgeTarget:Ge,nodeGroup:Ke,nodeVlist:Ze,vlistPat:qe,vlistOps:Je,vlistRef:Ye,vlistGroup:Xe,litAnchor:nt,litGroup:rt,litPool:it,poolOffsets:ot,poolText:at,adjGid:st,adjStart:ct,adjTgt:lt,patGid:ut,patTgt:dt,postfixLookupGroups:ft,orderSensitiveModifiers:`* ** after backdrop before details-content file first-letter first-line marker placeholder selection`}),mt=a(pt.mergeString,pt);pt.merge;var ht=T(`group/bubble relative flex w-fit max-w-[80%] min-w-0 flex-col gap-1 group-data-[align=end]/message:self-end data-[align=end]:self-end data-[variant=ghost]:max-w-full`,{variants:{variant:{default:`*:data-[slot=bubble-content]:bg-primary *:data-[slot=bubble-content]:text-primary-foreground [&>[data-slot=bubble-content]:is(button,a):hover]:bg-primary/80`,secondary:`*:data-[slot=bubble-content]:bg-secondary *:data-[slot=bubble-content]:text-secondary-foreground [&>[data-slot=bubble-content]:is(button,a):hover]:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)]`,muted:`*:data-[slot=bubble-content]:bg-muted [&>[data-slot=bubble-content]:is(button,a):hover]:bg-[color-mix(in_oklch,var(--muted),var(--foreground)_5%)]`,tinted:`*:data-[slot=bubble-content]:bg-[oklch(from_var(--primary)_0.93_calc(c*0.4)_h)] *:data-[slot=bubble-content]:text-foreground dark:*:data-[slot=bubble-content]:bg-[oklch(from_var(--primary)_0.3_calc(c*0.4)_h)] [&>[data-slot=bubble-content]:is(button,a):hover]:bg-[oklch(from_var(--primary)_0.88_calc(c*0.5)_h)] dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-[oklch(from_var(--primary)_0.35_calc(c*0.5)_h)]`,outline:`*:data-[slot=bubble-content]:border-border *:data-[slot=bubble-content]:bg-background [&>[data-slot=bubble-content]:is(button,a):hover]:bg-muted [&>[data-slot=bubble-content]:is(button,a):hover]:text-foreground dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-input/30`,ghost:`border-none *:data-[slot=bubble-content]:rounded-none *:data-[slot=bubble-content]:bg-transparent *:data-[slot=bubble-content]:p-0 [&>[data-slot=bubble-content]:is(button,a):hover]:bg-muted [&>[data-slot=bubble-content]:is(button,a):hover]:text-foreground dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-muted/50`,destructive:`*:data-[slot=bubble-content]:bg-destructive/10 *:data-[slot=bubble-content]:text-destructive dark:*:data-[slot=bubble-content]:bg-destructive/20 [&>[data-slot=bubble-content]:is(button,a):hover]:bg-destructive/20 dark:[&>[data-slot=bubble-content]:is(button,a):hover]:bg-destructive/30`}},defaultVariants:{variant:`default`}});function gt({variant:e=`default`,align:t=`start`,className:n,...r}){return(0,W.jsx)(`div`,{"data-slot":`bubble`,"data-variant":e,"data-align":t,className:mt(ht({variant:e}),n),...r})}function _t({className:e,render:t,...n}){return m({defaultTagName:`div`,props:f({className:mt(`w-fit max-w-full min-w-0 overflow-hidden rounded-xl border border-transparent px-3 py-2 text-sm leading-relaxed wrap-break-word group-data-[align=end]/bubble:self-end [button]:text-left [button,a]:transition-colors [button,a]:outline-none [button,a]:focus-visible:border-ring [button,a]:focus-visible:ring-3 [button,a]:focus-visible:ring-ring/50`,e)},n),render:t,state:{slot:`bubble-content`}})}T(`absolute z-10 flex w-fit shrink-0 items-center justify-center gap-1 rounded-full bg-muted px-1.5 py-0.5 text-sm ring-3 ring-card has-[button]:p-0`,{variants:{side:{top:`top-0 -translate-y-3/4`,bottom:`bottom-0 translate-y-3/4`},align:{start:`left-3`,end:`right-3`}},defaultVariants:{side:`bottom`,align:`end`}});function vt(e){return typeof e==`object`&&!!e}function yt(e){if(!vt(e))return null;let t=e.type;if(typeof t!=`string`)return null;if(t===`image`){let t=e;return t.url??t.image??null}if(t===`data-image`)return e.data?.url??null;if(t===`file`){let t=e;if(t.mimeType?.startsWith(`image/`)){if(t.url)return t.url;if(t.data)return`data:${t.mimeType};base64,${t.data}`}}return null}function bt(e){if(!vt(e)||e.type!==`file`)return null;let t=e,n=t.filename||t.name||t.fileName||`Attachment`;return t.mimeType?.startsWith(`image/`)??!1?null:{filename:n,size:t.size}}var xt=(0,U.memo)(function({message:e,className:t,enableImagePreview:n=!0}){let[r,i]=(0,U.useState)(null),a=(e.parts?.filter(Ce)??[]).map(e=>e.text).join(``),s=[],c=[];for(let t of e.parts??[]){let e=yt(t);e&&s.push(e);let n=bt(t);n&&c.push(n)}if(vt(e)&&Array.isArray(e.experimental_attachments))for(let t of e.experimental_attachments)t.contentType?.startsWith(`image/`)&&t.url&&s.push(t.url);if(!a&&s.length===0&&c.length===0)return null;let l=s.map((t,n)=>({id:`${e.id}-img-${n}`,url:t,filename:`image-${n+1}`}));return(0,W.jsxs)(`div`,{className:o(`flex flex-col items-end gap-1`,t),children:[s.length>0&&s.map((e,t)=>(0,W.jsx)(`div`,{className:o(`max-w-[200px] rounded-chat-message bg-foreground/4 p-1.5`,n&&`cursor-pointer`),onClick:n?()=>i(t):void 0,role:n?`button`:void 0,tabIndex:n?0:void 0,onKeyDown:n?e=>{(e.key===`Enter`||e.key===` `)&&(e.preventDefault(),i(t))}:void 0,children:(0,W.jsx)(`img`,{src:e,alt:`attachment`,width:184,height:120,className:`block max-h-[120px] max-w-[184px] rounded-chat-message-inner object-cover`})},e)),n&&l.length>0&&(0,W.jsx)(Fe,{open:r!==null,onClose:()=>i(null),images:l,initialIndex:r??0}),c.length>0&&(0,W.jsx)(`div`,{className:`flex flex-col items-end gap-2`,children:c.map((e,t)=>(0,W.jsx)(ze,{id:`${e.filename}-${t}`,filename:e.filename,size:e.size},`${e.filename}-${e.size}`))}),a&&(0,W.jsx)(gt,{align:`end`,variant:`muted`,className:`max-w-[85%]`,children:(0,W.jsx)(_t,{className:`rounded-chat-message px-3.5 py-1.5 whitespace-pre-wrap text-pretty`,children:a})})]})});function St(e,t,n){if(n===0)return 0;let r=0,i=n;for(;r<i;){let n=Math.floor((r+i)/2);e[n]<=t?r=n+1:i=n}return Math.max(0,Math.min(n-1,r-1))}function Ct(e,t,n,r){let i=[0];for(let[a,o]of e.entries())i.push(i[i.length-1]+(t.get(o)??n)+(a<e.length-1?r:0));return i}function wt({estimateSize:e,getItemKey:t,itemGap:n=0,items:r,overscan:i=1.5,renderItem:a,viewportRef:o}){let s=(0,U.useMemo)(()=>r.map((e,n)=>t(e,n)),[t,r]),c=r.length>=16,[l,u]=(0,U.useState)(()=>new Map),[d,f]=(0,U.useState)({height:0,scrollTop:0}),p=(0,U.useRef)(s),m=(0,U.useRef)(l),h=(0,U.useRef)(e),g=(0,U.useRef)(n),_=(0,U.useRef)([0]),v=(0,U.useRef)(0),y=(0,U.useRef)(new Map),b=(0,U.useRef)(new WeakMap),x=(0,U.useRef)(null),S=(0,U.useRef)(null),C=(0,U.useCallback)(()=>{let e=o.current;if(!e)return;let t={height:e.clientHeight,scrollTop:e.scrollTop};f(e=>e.height===t.height&&e.scrollTop===t.scrollTop?e:t)},[o]),w=(0,U.useCallback)(()=>{S.current??=window.requestAnimationFrame(()=>{S.current=null,C()})},[C]),T=(0,U.useCallback)((e,t)=>{let n=y.current.get(e);n&&n!==t&&(x.current?.unobserve(n),y.current.delete(e)),t&&(y.current.set(e,t),b.current.set(t,e),x.current?.observe(t))},[]),E=(0,U.useMemo)(()=>Ct(s,l,e,n),[e,n,s,l]);(0,U.useLayoutEffect)(()=>{C()},[r.length,C]),(0,U.useLayoutEffect)(()=>{p.current=s,m.current=l,h.current=e,g.current=n,_.current=E},[e,n,s,l,E]),(0,U.useEffect)(()=>{let e=o.current;if(!e)return;e.addEventListener(`scroll`,w,{passive:!0}),window.addEventListener(`resize`,w),C();let t;return typeof ResizeObserver<`u`&&(t=new ResizeObserver(w),t.observe(e)),()=>{e.removeEventListener(`scroll`,w),window.removeEventListener(`resize`,w),t?.disconnect(),S.current!=null&&(window.cancelAnimationFrame(S.current),S.current=null)}},[w,C,o]);let D=(0,U.useCallback)(e=>{let t=m.current,n=t;for(let r of e){let e=b.current.get(r.target),i=r.contentRect.height;!e||i<=0||t.get(e)===i||(n===t&&(n=new Map(t)),n.set(e,i))}if(n===t)return;let r=o.current,i=p.current,a=Ct(i,n,h.current,g.current);if(r&&i.length>0){let e=_.current,t=St(e,Math.max(0,r.scrollTop),i.length),n=i[t];if(n&&t>0){let r=(a[i.indexOf(n)]??0)-(e[t]??0);r!==0&&(v.current+=r)}}m.current=n,_.current=a,u(n)},[o]);if((0,U.useLayoutEffect)(()=>{if(!c||typeof ResizeObserver>`u`)return;let e=new ResizeObserver(e=>D(e));x.current=e;for(let t of y.current.values())e.observe(t);return()=>{e.disconnect(),x.current===e&&(x.current=null)}},[c,D]),(0,U.useEffect)(()=>{let e=m.current;if(e.size===0)return;let t=new Set(s),n=new Map([...e].filter(([e])=>t.has(e)));n.size!==e.size&&(m.current=n,u(n))},[s]),(0,U.useLayoutEffect)(()=>{let e=v.current,t=o.current;!t||e===0||(t.scrollTop+=e,v.current=0,C())},[l,C,o]),!c)return(0,W.jsx)(W.Fragment,{children:r.map((e,t)=>(0,W.jsx)(U.Fragment,{children:a(e,t)},s[t]))});let O=E[E.length-1]??0,k=Math.max(e,d.height*i),A=St(E,Math.max(0,d.scrollTop-k),r.length),j=Math.min(r.length-1,St(E,d.scrollTop+d.height+k,r.length)+1);return(0,W.jsx)(`div`,{"data-rendered-turn-count":j-A+1,"data-total-turn-count":r.length,"data-virtualized-transcript":`true`,style:{height:O,position:`relative`,width:`100%`},children:r.slice(A,j+1).map((e,t)=>{let n=A+t,r=s[n];return(0,W.jsx)(`div`,{ref:e=>T(r,e),"data-virtualized-turn-index":n,style:{left:0,position:`absolute`,right:0,top:E[n]},children:a(e,n)},r)})})}function Tt(e){return typeof e==`object`&&!!e}function Et(e){if(typeof e!=`string`)return e;let t=e.trim();if(!t)return e;try{let n=JSON.parse(t);return Tt(n)||Array.isArray(n)?n:e}catch{return e}}function Dt(e){if(!Tt(e)||typeof e.type!=`string`||!e.type.startsWith(`tool-`))return e;let t=Et(e.input),n=Et(e.output),r=Et(e.result),i=t!==e.input,a=n!==e.output,o=r!==e.result;if(!i&&!a&&!o)return e;let s={...e};return i&&(s.input=t),a&&(s.output=n),o&&(s.result=r),s}function Ot(e){let t=!1,n=e.map(e=>{let n=Dt(e);return n!==e&&(t=!0),n});return t?n:e}export{Ne as a,me as c,ce as d,le as f,B as h,ze as i,he as l,oe as m,wt as n,Se as o,se as p,xt as r,fe as s,Ot as t,pe as u};
@@ -1,5 +0,0 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/dist-CprW0Qol.js","assets/rolldown-runtime-hePW80VL.js","assets/preload-helper-BLdHbfdN.js","assets/space-separated-tokens-Ciu5hotc.js","assets/character-entities-legacy-Wut6vMuj.js","assets/lib-BvGd2E-G.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"./utils-oBThwhjm.js";import{c as i,s as a,u as o}from"./ease-DYVhTl2n.js";import{t as s}from"./use-reduced-motion-CFEp5oKr.js";import{t as c}from"./createLucideIcon-CQY2ECfR.js";import{t as l}from"./check-BTwIaCtI.js";import{t as u}from"./chevron-down-Bse1ggZM.js";import{t as d}from"./circle-check-DBhaebaM.js";import{n as f,t as p}from"./wrench-BXX_Ah2s.js";import{n as m,t as h}from"./file-code-corner-BkDULqko.js";import{t as g}from"./loader-circle-BmKYM_C4.js";import{t as _}from"./square-terminal-BLq2bQVF.js";import{t as v}from"./preload-helper-BLdHbfdN.js";import{a as y,i as b,n as x,o as S,r as C,t as w}from"./code-block-pKKmFZ5w.js";import{n as T,t as E}from"./action-swap-BWRUNKQA.js";var D={name:`ban`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`M4.929 4.929 19.07 19.071`,key:`196cmz`}]]};D.node;var O=c(D),k={name:`braces`,size:24,node:[[`path`,{d:`M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5c0 1.1.9 2 2 2h1`,key:`ezmyqa`}],[`path`,{d:`M16 21h1a2 2 0 0 0 2-2v-5c0-1.1.9-2 2-2a2 2 0 0 1-2-2V5a2 2 0 0 0-2-2h-1`,key:`e1hn23`}]],aliases:[`curly-braces`]};k.node;var A=c(k),j=e(t(),1),M=n(),N=`github-light-high-contrast`,P=`github-dark-high-contrast`,F=null,I=new Map,L=500;function R(e,t){if(I.size>=L){let e=I.keys().next().value;e!==void 0&&I.delete(e)}I.set(e,t)}var z=()=>v(()=>import(`./dist-CprW0Qol.js`).then(e=>e.t),__vite__mapDeps([0,1,2,3,4,5]));function B(){return F||=z().then(({createHighlighter:e})=>e({themes:[N,P],langs:[`bash`,`diff`,`json`,`python`,`tsx`,`typescript`]})),F}function V(e,t){return`${t}\u0000${e}`}function H(e,t){let n=V(e,t),r=I.get(n),[i,a]=(0,j.useState)(r?{key:n,code:e,language:t,lines:r}:null);return(0,j.useEffect)(()=>{let r=I.get(n);if(r){a({key:n,code:e,language:t,lines:r});return}let i=!1;return B().then(r=>{if(i)return;let o=r.codeToTokensWithThemes(e,{lang:t,themes:{light:N,dark:P}}).map(e=>e.map(e=>({content:e.content,offset:e.offset,light:e.variants.light?.color,dark:e.variants.dark?.color})));R(n,o),a({key:n,code:e,language:t,lines:o})}),()=>{i=!0}},[e,n,t]),i?.key===n||i?.language===t&&e.startsWith(i.code)?i.lines:null}function U({code:e,tokens:t,suffix:n,className:r}){return(0,M.jsxs)(`span`,{className:r,children:[t?t.map(e=>(0,M.jsx)(`span`,{style:{"--agent-code-light":e.light??`currentColor`,"--agent-code-dark":e.dark??e.light??`currentColor`},className:`text-[var(--agent-code-light)] dark:text-[var(--agent-code-dark)]`,children:e.content},`${e.offset}-${e.content}`)):e,n]})}function W({value:e,type:t}){return e?(0,M.jsxs)(`span`,{className:r(`font-mono text-xs tabular-nums`,t===`added`?`text-product-diff-added`:`text-product-diff-removed`),children:[t===`added`?`+`:`−`,e]}):null}function G({file:e,lines:t,status:n=`streaming`,open:c,defaultOpen:d=!0,onOpenChange:p,collapseOnComplete:_=!0,maxHeight:v=220,language:y=`typescript`,copyText:b,onCopy:x,className:S}){let C=s()??!1,w=(0,j.useId)(),E=`${w}-trigger`,D=`${w}-content`,k=(0,j.useRef)(null),A=(0,j.useRef)(n),N=(0,j.useRef)(void 0),[P,F]=(0,j.useState)(!1),[I,L]=(0,j.useState)(d),R=c??I,z=n===`streaming`,B=t.filter(e=>e.type===`added`).length,V=t.filter(e=>e.type===`removed`).length,G=!!(b||x),K=H(t.map(e=>e.content).join(`
3
- `),y),q=(0,j.useCallback)(e=>{c===void 0&&L(e),p?.(e)},[p,c]);(0,j.useEffect)(()=>{A.current!==`streaming`&&n===`streaming`&&q(!0),A.current===`streaming`&&n!==`streaming`&&_&&q(!1),A.current=n},[_,q,n]),(0,j.useEffect)(()=>()=>{N.current&&window.clearTimeout(N.current)},[]),(0,j.useLayoutEffect)(()=>{let e=k.current;if(!e||!R||!z)return;let t=requestAnimationFrame(()=>{e.scrollHeight<=e.clientHeight||(typeof e.scrollTo==`function`?e.scrollTo({top:e.scrollHeight,behavior:C?`auto`:`smooth`}):e.scrollTop=e.scrollHeight)});return()=>cancelAnimationFrame(t)});let J=(0,j.useCallback)(async()=>{x?await x():b&&await navigator.clipboard?.writeText(b),F(!0),N.current&&window.clearTimeout(N.current),N.current=window.setTimeout(()=>F(!1),1600)},[b,x]);return(0,M.jsxs)(`div`,{"data-state":n,"aria-busy":z,className:r(`w-full text-sm`,S),children:[(0,M.jsxs)(`button`,{id:E,type:`button`,"aria-expanded":R,"aria-controls":D,onClick:()=>q(!R),className:`group flex min-h-9 w-full items-center gap-2 rounded-md py-1 text-left outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background`,children:[(0,M.jsx)(h,{"aria-hidden":`true`,className:`size-4 shrink-0 text-muted-foreground`}),(0,M.jsx)(`span`,{className:`min-w-0 flex-1 truncate font-mono text-xs text-foreground/80`,children:e}),(0,M.jsxs)(`span`,{className:`flex shrink-0 items-center gap-2`,children:[(0,M.jsx)(W,{value:B,type:`added`}),(0,M.jsx)(W,{value:V,type:`removed`})]}),(0,M.jsx)(`span`,{className:`grid size-4 shrink-0 place-items-center text-muted-foreground/60`,children:z?(0,M.jsx)(g,{"aria-label":`Applying changes`,className:r(`size-3.5`,!C&&`animate-spin`)}):n===`error`?(0,M.jsx)(f,{"aria-label":`Changes failed`,className:`size-3.5`}):n===`cancelled`?(0,M.jsx)(O,{"aria-label":`Changes cancelled`,className:`size-3.5`}):(0,M.jsx)(l,{"aria-label":`Changes applied`,className:`size-3.5`})}),(0,M.jsx)(o.span,{"aria-hidden":`true`,animate:{rotate:R?180:0},transition:C?{duration:0}:i,className:`shrink-0 text-muted-foreground/45 transition-colors group-hover:text-muted-foreground`,children:(0,M.jsx)(u,{className:`size-3.5`})})]}),(0,M.jsx)(T,{id:D,role:`region`,"aria-labelledby":E,open:R,children:(0,M.jsx)(`div`,{className:`pl-6 pt-1.5`,children:(0,M.jsxs)(`div`,{className:`overflow-hidden rounded-xl bg-muted/80`,children:[(0,M.jsx)(`div`,{ref:k,"data-slot":`file-diff-viewport`,"aria-live":z?`off`:`polite`,className:`scrollbar-hide overflow-auto`,style:{maxHeight:v},children:(0,M.jsxs)(`div`,{className:`font-mono text-xs leading-5`,children:[(0,M.jsx)(`span`,{className:`sr-only`,children:`File changes`}),t.map((e,t)=>{let n=e.type??`context`;return(0,M.jsxs)(`div`,{className:r(`grid grid-cols-[2.25rem_2.25rem_1rem_minmax(0,1fr)]`,n===`added`&&`bg-success/[0.07]`,n===`removed`&&`bg-destructive/[0.07]`),children:[(0,M.jsx)(`span`,{className:`select-none pr-2 text-right tabular-nums text-muted-foreground/40`,children:e.oldLine}),(0,M.jsx)(`span`,{className:`select-none pr-2 text-right tabular-nums text-muted-foreground/40`,children:e.newLine}),(0,M.jsx)(`span`,{className:r(`select-none text-center text-muted-foreground/45`,n===`added`&&`text-product-diff-added`,n===`removed`&&`text-product-diff-removed`),children:n===`added`?`+`:n===`removed`?`−`:``}),(0,M.jsx)(U,{code:e.content,tokens:K?.[t],className:`min-w-0 whitespace-pre px-1.5`})]},e.id)})]})}),G?(0,M.jsx)(`div`,{className:`flex justify-end px-2 pb-1.5 pt-1`,children:(0,M.jsx)(o.button,{type:`button`,"aria-label":P?`Copied`:`Copy diff`,title:P?`Copied`:`Copy diff`,onClick:J,whileTap:C?void 0:{scale:.96},transition:a,className:`grid size-7 place-items-center rounded-md text-muted-foreground outline-none transition-colors hover:bg-background/70 hover:text-foreground focus-visible:ring-2 focus-visible:ring-ring`,children:P?(0,M.jsx)(l,{className:`size-3.5`}):(0,M.jsx)(m,{className:`size-3.5`})})}):null]})})})]})}var K=[];function q({code:e,language:t=`typescript`,languageLabel:n,filename:i,status:c=`complete`,showStatus:u=!0,showLineNumbers:d=!0,highlightLines:f=K,maxHeight:p=280,wrap:_=!1,copyable:v=!0,onCopy:b}){let T=s()??!1,E=(0,j.useRef)(null),D=(0,j.useRef)(void 0),[O,k]=(0,j.useState)(!1),A=c===`streaming`,N=H(e,t),P=(0,j.useMemo)(()=>new Set(f),[f]),F=0,I=e.split(`
4
- `).map(e=>{let t={content:e,offset:F};return F+=e.length+1,t}),L=n??{bash:`Bash`,diff:`Diff`,json:`JSON`,python:`Python`,text:`Text`,tsx:`TSX`,typescript:`TypeScript`}[t];(0,j.useEffect)(()=>()=>{D.current&&window.clearTimeout(D.current)},[]),(0,j.useLayoutEffect)(()=>{let e=E.current;if(!e||!A)return;let t=requestAnimationFrame(()=>{e.scrollHeight<=e.clientHeight||(typeof e.scrollTo==`function`?e.scrollTo({top:e.scrollHeight,behavior:T?`auto`:`smooth`}):e.scrollTop=e.scrollHeight)});return()=>cancelAnimationFrame(t)});let R=(0,j.useCallback)(async()=>{b?await b():await navigator.clipboard?.writeText(e),k(!0),D.current&&window.clearTimeout(D.current),D.current=window.setTimeout(()=>k(!1),1600)},[e,b]);return(0,M.jsxs)(w,{"data-state":c,"aria-busy":A,size:`sm`,className:`bg-muted/80`,children:[(0,M.jsxs)(y,{className:`h-10 gap-2.5 px-3 pt-0`,children:[(0,M.jsx)(h,{"aria-hidden":`true`,className:`size-3.5 shrink-0 text-muted-foreground/70`}),i?(0,M.jsx)(S,{className:`font-mono text-xs text-foreground/80`,children:i}):null,(0,M.jsx)(`span`,{className:`text-micro font-medium uppercase tracking-wide text-muted-foreground/55`,children:L}),u?(0,M.jsxs)(`span`,{className:r(!v&&!b&&`ml-auto`,`inline-flex shrink-0 items-center gap-1 text-micro font-medium`,A?`text-info`:`text-success`),children:[A?(0,M.jsx)(g,{className:r(`size-3`,!T&&`animate-spin`)}):(0,M.jsx)(l,{className:`size-3`}),A?`Writing`:`Ready`]}):null,v||b?(0,M.jsx)(x,{className:r(`-my-0 -me-0`,u?`ms-0`:`ms-auto`),children:(0,M.jsx)(o.button,{type:`button`,"aria-label":O?`Copied`:`Copy code`,title:O?`Copied`:`Copy code`,onClick:R,whileTap:T?void 0:{scale:.96},transition:a,className:`grid size-7 shrink-0 place-items-center rounded-full text-muted-foreground outline-none transition-colors hover:bg-background/70 hover:text-foreground focus-visible:ring-2 focus-visible:ring-ring`,children:O?(0,M.jsx)(l,{className:`size-3.5`}):(0,M.jsx)(m,{className:`size-3.5`})})}):null]}),(0,M.jsx)(C,{ref:E,role:A?`log`:void 0,"aria-live":A?`off`:void 0,className:`max-w-full overflow-auto border-t border-foreground/[0.06] px-0 py-2 font-mono text-xs leading-5 text-foreground/85 [scrollbar-color:color-mix(in_oklab,var(--muted-foreground)_35%,transparent)_transparent] [scrollbar-width:thin]`,style:{maxHeight:p},wrap:_,children:I.map((e,t)=>{let n=t+1;return(0,M.jsx)(`span`,{"data-line-number":d?n:void 0,className:r(`grid min-h-5`,d?`grid-cols-[2.75rem_minmax(0,1fr)] before:content-[attr(data-line-number)] before:select-none before:pr-3 before:text-right before:tabular-nums before:text-muted-foreground/35`:`grid-cols-1`,P.has(n)&&`bg-primary/[0.07]`),children:(0,M.jsx)(U,{code:e.content,tokens:N?.[t],suffix:t<I.length-1?`
5
- `:void 0,className:r(`pr-4`,d?`pl-1`:`pl-4`,_?`whitespace-pre-wrap break-words`:`whitespace-pre`)})},e.offset)})})]})}function J(e){return e===`running`?`Running`:e===`success`?`Completed`:e===`error`?`Failed`:`Cancelled`}function Y(e){return e===`running`?`text-primary`:e===`success`?`text-success`:e===`error`?`text-destructive`:`text-muted-foreground`}function X({kind:e}){return e===`terminal`?(0,M.jsx)(_,{className:`size-4`}):e===`request`?(0,M.jsx)(A,{className:`size-4`}):(0,M.jsx)(p,{className:`size-4`})}function Z({status:e,reduce:t}){return e===`running`?(0,M.jsx)(g,{className:r(`size-3`,!t&&`animate-spin`)}):e===`success`?(0,M.jsx)(d,{className:`size-3`}):e===`error`?(0,M.jsx)(f,{className:`size-3`}):(0,M.jsx)(O,{className:`size-3`})}function Q({label:e,onClick:t,children:n}){let r=s()??!1;return(0,M.jsx)(o.button,{type:`button`,"aria-label":e,title:e,onClick:t,whileTap:r?void 0:{scale:.96},transition:a,className:`grid size-7 place-items-center rounded-md text-muted-foreground outline-none transition-colors hover:bg-muted hover:text-foreground focus-visible:ring-2 focus-visible:ring-ring`,children:n})}function $({children:e,language:t=`bash`,label:n,error:i=!1,className:a}){return(0,M.jsxs)(w,{"data-error":i||void 0,variant:i?`destructive`:`default`,size:`sm`,className:a,children:[(0,M.jsxs)(y,{className:`py-1`,children:[n?(0,M.jsx)(S,{className:r(`text-micro uppercase tracking-[0.12em]`,i?`text-destructive`:`text-muted-foreground/60`),children:i?`Reported error`:n}):null,(0,M.jsx)(x,{children:(0,M.jsx)(b,{value:e,"aria-label":`Copy result`})})]}),(0,M.jsx)(C,{wrap:!0,className:r(`max-h-60 text-xs leading-5`,i?`text-destructive`:`text-foreground/80`),children:e})]})}function ee({tool:e,title:t,children:n,status:a=`running`,kind:c=`custom`,meta:d,open:f,defaultOpen:p=!0,onOpenChange:h,collapseOnComplete:g=!0,maxHeight:_=220,copyText:v}){let y=s()??!1,b=(0,j.useId)(),x=`${b}-trigger`,S=`${b}-content`,C=(0,j.useRef)(null),w=(0,j.useRef)(a),D=(0,j.useRef)(void 0),[O,k]=(0,j.useState)(!1),[A,N]=(0,j.useState)(p),P=f??A,F=a===`running`,I=!!v,L=J(a),R=(0,j.useCallback)(e=>{f===void 0&&N(e),h?.(e)},[h,f]);(0,j.useEffect)(()=>{w.current!==`running`&&a===`running`&&R(!0),w.current===`running`&&a!==`running`&&g&&R(!1),w.current=a},[g,R,a]),(0,j.useEffect)(()=>()=>{D.current&&window.clearTimeout(D.current)},[]),(0,j.useLayoutEffect)(()=>{let e=C.current;if(!e||!P||!F)return;let t=requestAnimationFrame(()=>{typeof e.scrollTo==`function`?e.scrollTo({top:e.scrollHeight,behavior:y?`auto`:`smooth`}):e.scrollTop=e.scrollHeight});return()=>cancelAnimationFrame(t)});let z=(0,j.useCallback)(async()=>{v&&await navigator.clipboard?.writeText(v),k(!0),D.current&&window.clearTimeout(D.current),D.current=window.setTimeout(()=>k(!1),1600)},[v]);return(0,M.jsxs)(`div`,{"data-state":a,"aria-busy":F,className:`w-full text-sm`,children:[(0,M.jsxs)(`button`,{id:x,type:`button`,"aria-expanded":P,"aria-controls":S,onClick:()=>R(!P),className:`group flex min-h-9 w-full items-center gap-2 py-1 text-left outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background`,children:[(0,M.jsx)(`span`,{"aria-hidden":`true`,className:`grid size-4 shrink-0 place-items-center text-muted-foreground`,children:(0,M.jsx)(X,{kind:c})}),(0,M.jsxs)(`span`,{className:`flex min-w-0 flex-1 items-baseline gap-2`,children:[(0,M.jsx)(`span`,{className:`min-w-0 truncate font-medium text-foreground/90`,children:t}),d?(0,M.jsx)(`span`,{className:`shrink-0 text-xs tabular-nums text-muted-foreground/60`,children:d}):null,(0,M.jsx)(`span`,{className:`hidden min-w-0 truncate font-mono text-caption text-muted-foreground/55 sm:inline`,children:e})]}),(0,M.jsxs)(`span`,{className:r(`inline-flex shrink-0 items-center gap-1 text-caption font-medium`,Y(a)),children:[(0,M.jsx)(Z,{status:a,reduce:y}),(0,M.jsx)(E,{value:a,children:L})]}),(0,M.jsx)(o.span,{"aria-hidden":`true`,animate:{rotate:P?180:0},transition:y?{duration:0}:i,className:`shrink-0 text-muted-foreground/50 transition-colors group-hover:text-muted-foreground`,children:(0,M.jsx)(u,{className:`size-3.5`})})]}),(0,M.jsx)(T,{id:S,role:`region`,"aria-labelledby":x,open:P,children:(0,M.jsx)(`div`,{className:`pl-6 pt-1.5`,children:(0,M.jsxs)(`div`,{children:[(0,M.jsx)(`div`,{ref:C,role:`log`,"aria-live":`polite`,className:`scrollbar-hide overflow-y-auto overscroll-contain`,style:{maxHeight:_},children:n}),I?(0,M.jsxs)(`div`,{className:`flex items-center gap-0.5 px-2 pb-1.5`,children:[(0,M.jsx)(Q,{label:O?`Copied`:`Copy result`,onClick:z,children:O?(0,M.jsx)(l,{className:`size-3.5`}):(0,M.jsx)(m,{className:`size-3.5`})}),(0,M.jsx)(`span`,{className:`ml-auto text-caption text-muted-foreground/55`,children:(0,M.jsx)(E,{value:a,children:L})})]}):null]})})})]})}export{G as i,$ as n,q as r,ee as t};
@@ -1,2 +0,0 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/session-tool-renderer-C7mYeUOs.js","assets/rolldown-runtime-hePW80VL.js","assets/react-Cvdyeg_0.js","assets/jsx-runtime-NZYk81nU.js","assets/utils-oBThwhjm.js","assets/ease-DYVhTl2n.js","assets/is-ref-object-h-bjS8Eq.js","assets/use-reduced-motion-CFEp5oKr.js","assets/use-presence-BPZ36pcg.js","assets/useButton-CvcmqA2s.js","assets/createLucideIcon-CQY2ECfR.js","assets/arrow-up-right-CG9RNk4p.js","assets/tool-result-bjAGZ2qm.js","assets/check-BTwIaCtI.js","assets/chevron-down-Bse1ggZM.js","assets/circle-check-DBhaebaM.js","assets/wrench-BXX_Ah2s.js","assets/file-code-corner-BkDULqko.js","assets/loader-circle-BmKYM_C4.js","assets/square-terminal-BLq2bQVF.js","assets/preload-helper-BLdHbfdN.js","assets/code-block-pKKmFZ5w.js","assets/button-CWYjn8Zk.js","assets/dist-BogNzeK9.js","assets/clsx-DB0hHKMi.js","assets/action-swap-BWRUNKQA.js","assets/useRender-Bbk_fl72.js","assets/chevron-right-BPCB1mOg.js","assets/file-text-cqOanUYv.js","assets/ipython-tool-bieUhw9K.js","assets/tool-output-normalizer-CADgEiI4.js","assets/search-Cb6fFWew.js","assets/shield-check-7HDd-2Fn.js","assets/safe-external-url-D3PJJIcM.js","assets/eye-iNSvs0UA.js","assets/git-branch-DZEh2mM2.js","assets/sparkles-BwVa9zQJ.js","assets/x-DEU6H3M-.js","assets/dist-CprW0Qol.js","assets/space-separated-tokens-Ciu5hotc.js","assets/character-entities-legacy-Wut6vMuj.js","assets/lib-BvGd2E-G.js","assets/surfaces-BUjUJTyD.js","assets/collapsible-Bk6zCsRX.js","assets/createBaseUIEventDetails-DIxvaz-Y.js","assets/react-dom-B7th3XGm.js","assets/useBaseUiId-lKfDDIcw.js","assets/useControlled-CkQSkSv1.js","assets/workspace-path-nav-D-77sJ_A.js","assets/use-hover-capable-CLq8BADD.js","assets/trace-IsV5RRvM.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"./utils-oBThwhjm.js";import{n as i,t as a}from"./tool-output-normalizer-CADgEiI4.js";import{t as o}from"./preload-helper-BLdHbfdN.js";import{a as s,c,i as l,n as u,o as d,r as f,s as p,t as m}from"./trace-IsV5RRvM.js";var h=e(t(),1),g=n(),_=(0,h.lazy)(()=>o(async()=>{let{SessionToolRenderer:e}=await import(`./session-tool-renderer-C7mYeUOs.js`).then(e=>e.n);return{SessionToolRenderer: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,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50])).then(({SessionToolRenderer:e})=>({default:e}))),v=[];function y(e){return e===`ipython`?`repl`:`artifacts`}function b(e,t){return t?{...e,artifactId:t.id,artifactTitle:t.title,artifactTarget:y(t.kind)}:e}function x(e){return typeof e==`object`&&e&&!Array.isArray(e)?e:void 0}function S(e,t){let n=e.state;return n===`output-error`||n===`error`?`error`:n===`cancelled`||n===`canceled`||n===`aborted`||n===`interrupted`?`cancelled`:n===`input-streaming`||n===`streaming`?t?`running`:`cancelled`:n===`input-available`||n===`pending`||n===`queued`?`pending`:t&&e.output===void 0&&e.result===void 0?`running`:`complete`}function C(e,t,n,r=[],i=!1){let o=e.type;if(typeof o!=`string`||!o.startsWith(`tool-`)||o===`tool-FleetReasoning`||o===`tool-Thinking`||i)return;let s=o.slice(5),c=s.toLowerCase(),l=c.includes(`edit`)||c.includes(`write`)||c.includes(`patch`)?`Edited`:c.includes(`read`)?`Read`:c.includes(`search`)||c.includes(`grep`)||c.includes(`glob`)?`Searched`:c.includes(`bash`)||c.includes(`shell`)||c.includes(`python`)||c.includes(`ipython`)?`Ran`:s,u=a(e);return{id:typeof e.toolCallId==`string`?e.toolCallId:t,verb:l,target:s,status:S(e,n),part:e,nestedTools:r,traceDescription:u?.traceDescription,durationLabel:u?.durationLabel,reportedError:u?.outputSummary.isError}}function w(e){return{id:`artifact:${e.id}`,verb:e.kind===`compaction`?`Compacted`:e.kind===`refinement`?`Refined`:e.kind===`recap`?`Recapped`:e.kind===`rlm`?`Delegated`:e.kind===`diff`?`Edited`:`Completed`,target:e.kind===`bash`?`Bash output`:e.kind===`ipython`?`IPython result`:e.kind===`diff`?`File change`:e.kind===`rlm`?`Child task`:e.kind===`recap`?`Session recap`:e.kind===`refinement`?`Refinement`:`Session activity`,status:e.status===`success`?`complete`:e.status}}function T({step:e,onOpenArtifact:t,renderToolDetails:n}){let a=i(e.part?.type.replace(/^tool-/,``)??e.target),o=e.artifactId,m=o&&e.artifactTitle?e.artifactTarget===`repl`?`Open ${e.artifactTitle} in REPL`:`Open ${e.artifactTitle} in artifacts`:void 0,v=`Details for ${e.target}${e.id?` (${e.id})`:``}`,y=e.reportedError?`reported error`:e.status===`error`?`failed`:e.status===`running`?`running`:e.status===`pending`?`waiting`:e.status===`cancelled`?`cancelled`:`done`,b=(0,g.jsxs)(p,{status:e.status===`running`?`running`:e.status===`error`?`error`:e.status===`pending`?`pending`:void 0,children:[(0,g.jsx)(d,{children:(0,g.jsx)(a,{className:r(`size-3.5`,e.status===`running`&&`animate-pulse text-primary`,e.status===`error`&&`text-destructive`)})}),(0,g.jsxs)(c,{children:[e.verb,` `,e.target]}),(0,g.jsx)(s,{className:e.reportedError?`text-destructive`:void 0,children:y}),e.traceDescription?(0,g.jsx)(s,{className:`max-w-48 truncate`,title:e.traceDescription,children:e.traceDescription}):null,e.durationLabel?(0,g.jsx)(s,{children:e.durationLabel}):null]});return(0,g.jsxs)(`div`,{className:`flex min-w-0 items-start gap-2`,children:[e.part?(0,g.jsxs)(u,{className:`min-w-0 flex-1`,children:[(0,g.jsx)(l,{"aria-label":v,children:b}),(0,g.jsx)(f,{children:n?n(e.part,e.status===`running`,e.nestedTools):(0,g.jsx)(h.Suspense,{fallback:null,children:(0,g.jsx)(_,{part:e.part,nestedTools:e.nestedTools,chatStatus:e.status===`running`?`streaming`:void 0,insideTrace:!0})})})]}):(0,g.jsx)(`div`,{className:`min-w-0 flex-1`,children:b}),m&&o&&t?(0,g.jsx)(`button`,{type:`button`,className:`shrink-0 text-micro underline`,"aria-label":m,onClick:()=>t(o,e.artifactTarget),children:`Open`}):null]})}function E({messages:e,artifacts:t=v,streaming:n,className:a,onOpenArtifact:o,renderToolDetails:_}){let y=(0,h.useMemo)(()=>{let r=new Set,i=new Map(t.flatMap(e=>e.sourceToolCallId?[[e.sourceToolCallId,e]]:[])),a=e.flatMap(e=>{let t=new Set(e.parts.flatMap(e=>{let t=x(e);return(t?.type===`tool-Task`||t?.type===`tool-Agent`)&&typeof t.toolCallId==`string`?[t.toolCallId]:[]})),a=new Map,o=new Set;for(let n of e.parts){let e=x(n),r=typeof e?.toolCallId==`string`?e.toolCallId:void 0,i=r?.indexOf(`:`)??-1;if(!r||i<=0)continue;let s=r.slice(0,i);if(!t.has(s))continue;o.add(r);let c=a.get(s)??[];c.push(e),a.set(s,c)}return e.parts.flatMap((t,s)=>{let c=x(t)??{},l=typeof c.toolCallId==`string`?c.toolCallId:void 0,u=C(c,`${e.id}:${s}`,n,l?a.get(l)??[]:[],l?o.has(l):!1);return!u||r.has(u.id)?[]:(r.add(u.id),[b(u,i.get(u.id))])})}),o=t.flatMap(e=>{if(e.sourceToolCallId&&r.has(e.sourceToolCallId))return[];let t=b(w(e),e);return r.has(t.id)?[]:(r.add(t.id),[t])});return[...a,...o]},[t,e,n]),[S,E]=(0,h.useState)(!0);if(y.length===0)return null;let D=[...y].reverse().find(e=>e.status===`running`)??y.at(-1),O=i(D?.part?.type.replace(/^tool-/,``)??D?.target??`activity`);return(0,g.jsx)(m,{className:r(`mb-2`,a),"data-testid":`tool-trace`,children:(0,g.jsxs)(u,{open:S,onOpenChange:E,children:[(0,g.jsx)(l,{"aria-label":`${y.length} tool ${y.length===1?`action`:`actions`}`,children:(0,g.jsxs)(p,{status:D?.status===`running`?`running`:D?.status===`error`?`error`:void 0,children:[(0,g.jsx)(d,{children:(0,g.jsx)(O,{className:r(`size-3.5`,D?.status===`running`&&`animate-spin`)})}),(0,g.jsx)(c,{children:n&&D?`${D.verb} ${D.target}`:`${y.length} tool ${y.length===1?`action`:`actions`}`}),(0,g.jsx)(s,{children:y.length})]})}),(0,g.jsx)(f,{children:(0,g.jsx)(m,{className:`gap-1`,children:y.map(e=>(0,g.jsx)(T,{step:e,onOpenArtifact:o,renderToolDetails:_},e.id))})})]})})}export{E as t};
@@ -1 +0,0 @@
1
- import{t as e}from"./createLucideIcon-CQY2ECfR.js";import{d as t,i as n,l as r,u as i}from"./chat-helpers-Bj7_hES7.js";import{t as a}from"./safe-storage-s25GrfpH.js";var o={name:`folder-plus`,size:24,node:[[`path`,{d:`M12 10v6`,key:`1bos4e`}],[`path`,{d:`M9 13h6`,key:`1uhe8q`}],[`path`,{d:`M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z`,key:`1kt360`}]]};o.node;var s=e(o),c={name:`folder-tree`,size:24,node:[[`path`,{d:`M20 10a1 1 0 0 0 1-1V6a1 1 0 0 0-1-1h-2.5a1 1 0 0 1-.8-.4l-.9-1.2A1 1 0 0 0 15 3h-2a1 1 0 0 0-1 1v5a1 1 0 0 0 1 1Z`,key:`hod4my`}],[`path`,{d:`M20 21a1 1 0 0 0 1-1v-3a1 1 0 0 0-1-1h-2.9a1 1 0 0 1-.88-.55l-.42-.85a1 1 0 0 0-.92-.6H13a1 1 0 0 0-1 1v5a1 1 0 0 0 1 1Z`,key:`w4yl2u`}],[`path`,{d:`M3 5a2 2 0 0 0 2 2h3`,key:`f2jnh7`}],[`path`,{d:`M3 3v13a2 2 0 0 0 2 2h3`,key:`k8epm1`}]]};c.node;var l=e(c),u=`https://docs.qredence.ai`,d=`https://x.com/zacharybydesign`,f=`https://discord.gg/ebgy7gtZHK`,p=`fleet-prime:v1:sidebar-expanded-projects`,m=[],h=`new-session:`,g=`project:`,_=`session:`;function v(e){return`${g}${e}`}function y(e){return`${_}${e}`}function b(e){return`${h}${e}`}function x(e,t){return e.startsWith(t)?e.slice(t.length):null}function S(e){return n(t({sessionId:e.sessionId,title:e.title,firstMessage:e.firstMessage}))||i(e.sessionId)}function C(e,t){let n=S(e);if(!t)return n;let i=0;for(let e of t)S(e)===n&&(i+=1);return r(n,e.sessionId,i)}function w(e,t){return`${e.projectId?t.get(e.projectId)?.name??`Unassigned`:`Unassigned`} · ${e.status===`idle`?`Ready`:e.status} · ${`${String(e.messageCount)} ${e.messageCount===1?`message`:`messages`}`}`}function T(e){let t=Date.parse(e);if(!Number.isFinite(t))return`Earlier`;let n=new Date,r=new Date(n.getFullYear(),n.getMonth(),n.getDate()).getTime(),i=Math.floor((r-new Date(t).setHours(0,0,0,0))/864e5);return i<=0?`Today`:i===1?`Yesterday`:`Earlier`}function E(e){return e.hasChildren?`${e.name}/`:e.name}function D(e,t){return e instanceof Error&&e.message.trim()?e.message:t}function O(e){let t=a(p);if(!t)return e?[v(e)]:[];try{let e=JSON.parse(t);return Array.isArray(e)?e.filter(e=>typeof e==`string`):[]}catch{return e?[v(e)]:[]}}export{y as _,h as a,s as b,d as c,b as d,E as f,C as g,w as h,p as i,D as l,O as m,u as n,g as o,v as p,m as r,_ as s,f as t,x as u,T as v,l as y};
@@ -1 +0,0 @@
1
- import{a as e}from"./useButton-CvcmqA2s.js";import{t}from"./createLucideIcon-CQY2ECfR.js";var n={name:`chevron-up`,size:24,node:[[`path`,{d:`m18 15-6-6-6 6`,key:`153udz`}]]};n.node;var r=t(n);function i(t){return e(t.defaultTagName??`div`,t,t)}export{r as n,i as t};
@@ -1,56 +0,0 @@
1
- import {
2
- cva
3
- } from "./chunk-FB3UHLLN.js";
4
-
5
- // web/app/dist/server/assets/tokens-Mmu61GUV.js
6
- var COMPACT_ACTION_BUTTON_CLASS = "h-8 shrink-0 cursor-pointer rounded-full border-border/45 bg-background/65 px-3 text-caption font-semibold text-foreground/75 shadow-sm transition-[background-color,border-color,box-shadow,opacity,transform] duration-150 hover:bg-foreground/5 enabled:active:scale-[0.96] disabled:opacity-50";
7
- var HIT_AREA_EXPAND_CLASS = "relative after:absolute after:top-1/2 after:left-1/2 after:size-10 after:-translate-x-1/2 after:-translate-y-1/2";
8
- var HIT_AREA_EXPAND_DENSE_CLASS = "relative after:absolute after:inset-x-0 after:-top-1.5 after:-bottom-1.5";
9
- var CHROME_PILL_CLASS = "relative inline-flex h-9 items-center gap-1.5 rounded-md border border-border/70 px-3 text-label font-medium whitespace-nowrap shadow-sm backdrop-blur transition-colors";
10
- var CHROME_PILL_INACTIVE_CLASS = "bg-sidebar text-foreground/55 hover:bg-background hover:text-foreground/75";
11
- var CHROME_PILL_ACTIVE_CLASS = "bg-background text-foreground/75";
12
- var CHAT_HEADER_LAYER_CLASS = "relative z-10 overflow-visible";
13
- var CHAT_COLUMN_CLASS = "mx-auto w-full max-w-chat px-[var(--density-pad-x)]";
14
- var COMPOSER_ADD_BUTTON_CLASS = "size-8 shrink-0 rounded-full border-border/70 bg-background text-foreground/80 shadow-sm hover:bg-muted hover:text-foreground";
15
- var SUGGESTION_ITEM_CLASS = "h-auto justify-start rounded-full border border-border/70 bg-background/80 px-3 py-1.5 text-pretty text-sm font-normal text-foreground/65 shadow-sm transition-colors hover:border-border hover:bg-foreground/6 hover:text-foreground";
16
- var PANEL_OVERLAY_CLASS = "min-h-0 w-[min(360px,calc(100vw-1.5rem))] overflow-hidden rounded-lg border border-border/70 bg-background/95 shadow-lg backdrop-blur";
17
- var rowSurface = cva("flex min-w-0 rounded-sm border", {
18
- variants: {
19
- tone: {
20
- default: "border-border/30 bg-background/30",
21
- muted: "border-border/20 bg-foreground/1.5",
22
- inset: "border-border/60 bg-foreground/2",
23
- dashed: "border-dashed border-border/25 bg-background/10"
24
- },
25
- padding: {
26
- sm: "p-2",
27
- md: "px-2.5 py-2",
28
- lg: "p-2.5"
29
- },
30
- interactive: {
31
- true: "transition-[border-color,background-color,box-shadow] duration-200 hover:border-border/45 hover:bg-foreground/2 hover:shadow-sm",
32
- lift: "transition-[border-color,background-color,box-shadow,transform] duration-200 hover:-translate-y-px hover:border-border/45 hover:bg-foreground/3.5 hover:shadow-sm",
33
- false: ""
34
- }
35
- },
36
- defaultVariants: {
37
- tone: "default",
38
- padding: "sm",
39
- interactive: false
40
- }
41
- });
42
-
43
- export {
44
- COMPACT_ACTION_BUTTON_CLASS,
45
- HIT_AREA_EXPAND_CLASS,
46
- HIT_AREA_EXPAND_DENSE_CLASS,
47
- CHROME_PILL_CLASS,
48
- CHROME_PILL_INACTIVE_CLASS,
49
- CHROME_PILL_ACTIVE_CLASS,
50
- CHAT_HEADER_LAYER_CLASS,
51
- CHAT_COLUMN_CLASS,
52
- COMPOSER_ADD_BUTTON_CLASS,
53
- SUGGESTION_ITEM_CLASS,
54
- PANEL_OVERLAY_CLASS,
55
- rowSurface
56
- };