@alwith/module-chat 0.6.34 → 0.6.35

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 (490) hide show
  1. package/dist/activity-host.d.ts +2 -0
  2. package/dist/activity-host.js +1 -1
  3. package/dist/agent/client.d.ts +2 -0
  4. package/dist/agent/client.js +1 -1
  5. package/dist/agent/custom-model-effort.js +1 -1
  6. package/dist/agent/fork-title.js +1 -1
  7. package/dist/agent/image-request.js +1 -1
  8. package/dist/agent/image-tools.d.ts +3 -1
  9. package/dist/agent/image-tools.js +1 -1
  10. package/dist/agent/input-config.js +1 -1
  11. package/dist/agent/input-modes/chat.js +1 -1
  12. package/dist/agent/input-modes/execution-meta.js +1 -1
  13. package/dist/agent/input-modes/image-context.js +1 -1
  14. package/dist/agent/input-modes/image.js +1 -1
  15. package/dist/agent/input-modes/index.js +1 -1
  16. package/dist/agent/project-path.js +1 -1
  17. package/dist/agent/request-error.js +1 -1
  18. package/dist/agent/session-list-refresh.js +1 -1
  19. package/dist/app-reference.js +1 -1
  20. package/dist/application-tools.js +1 -1
  21. package/dist/approval/choice-elicitation-form.js +1 -1
  22. package/dist/approval/choice-schema.js +1 -1
  23. package/dist/approval/permission-options.js +1 -1
  24. package/dist/approval/permission-view.js +1 -1
  25. package/dist/approval/schema-elicitation-form.js +1 -1
  26. package/dist/approval/url-elicitation-card.js +1 -1
  27. package/dist/{chunk-0a3tr9ws.js → chunk-0sb0c014.js} +2 -2
  28. package/dist/{chunk-ks22p0wq.js → chunk-0xztk729.js} +2 -2
  29. package/dist/chunk-18gcnf2a.js +2 -0
  30. package/dist/{chunk-p216frcj.js → chunk-1a46v4cy.js} +2 -2
  31. package/dist/chunk-1b3frq9c.js +3 -0
  32. package/dist/{chunk-nhz4egjh.js → chunk-1vwece23.js} +6 -6
  33. package/dist/{chunk-wvm6ppb3.js → chunk-20dc4fm0.js} +2 -2
  34. package/dist/{chunk-45yrj0e1.js → chunk-22nybrkv.js} +5 -5
  35. package/dist/{chunk-vab1ysnz.js → chunk-23kvszfc.js} +2 -2
  36. package/dist/chunk-2nq204hz.js +2 -0
  37. package/dist/{chunk-dcvmc9hn.js → chunk-2nv5ebq1.js} +2 -2
  38. package/dist/chunk-33fxyn5r.js +2 -0
  39. package/dist/chunk-359pf448.js +2 -0
  40. package/dist/{chunk-n8b9yg4q.js → chunk-3knw8e0x.js} +2 -2
  41. package/dist/{chunk-2eceheqt.js → chunk-3kytka7m.js} +3 -3
  42. package/dist/{chunk-mq0npf36.js → chunk-3sq2k9ca.js} +2 -2
  43. package/dist/{chunk-vgea7ggq.js → chunk-3t3n8nfy.js} +2 -2
  44. package/dist/{chunk-9n8cds8p.js → chunk-3tvq6xr2.js} +2 -2
  45. package/dist/{chunk-gktjkghg.js → chunk-482segb0.js} +2 -2
  46. package/dist/{chunk-19jh646d.js → chunk-4chmr87g.js} +2 -2
  47. package/dist/chunk-4g2412p5.js +2 -0
  48. package/dist/chunk-4ma6bmcm.js +2 -0
  49. package/dist/{chunk-103z8myv.js → chunk-54jfqcd1.js} +2 -2
  50. package/dist/chunk-5mxh7h57.js +2 -0
  51. package/dist/{chunk-tjt1s9qs.js → chunk-5qaa4atv.js} +2 -2
  52. package/dist/{chunk-qwjz3jsz.js → chunk-5zf3px9y.js} +2 -2
  53. package/dist/chunk-60yk0ye9.js +2 -0
  54. package/dist/chunk-63kwbtgs.js +2 -0
  55. package/dist/{chunk-sgmh6sa8.js → chunk-67fn9pq0.js} +2 -2
  56. package/dist/{chunk-84p483n0.js → chunk-6br4568a.js} +2 -2
  57. package/dist/{chunk-4jza4wwy.js → chunk-6c7q2rz8.js} +2 -2
  58. package/dist/{chunk-7m8hw6gh.js → chunk-6ea6q6dj.js} +2 -2
  59. package/dist/{chunk-88ysxbdh.js → chunk-6v0r7m92.js} +2 -2
  60. package/dist/{chunk-kbzsn9xw.js → chunk-6xap6hvz.js} +2 -2
  61. package/dist/{chunk-re4vc51w.js → chunk-7naym98x.js} +2 -2
  62. package/dist/{chunk-r5q65gf3.js → chunk-7nfv27hz.js} +2 -2
  63. package/dist/{chunk-masqfje4.js → chunk-7tgfj1zb.js} +2 -2
  64. package/dist/{chunk-gfkx1z04.js → chunk-7ywnza68.js} +2 -2
  65. package/dist/{chunk-r8sq654w.js → chunk-8be6eq9r.js} +2 -2
  66. package/dist/chunk-8eyw37rv.js +2 -0
  67. package/dist/{chunk-eqa6cd7b.js → chunk-8pb726d6.js} +2 -2
  68. package/dist/{chunk-zv3bm3np.js → chunk-8x7a5n2w.js} +2 -2
  69. package/dist/{chunk-x2x9g6vk.js → chunk-8yetzgqb.js} +2 -2
  70. package/dist/{chunk-tj0530fn.js → chunk-8zkn8x2j.js} +2 -2
  71. package/dist/chunk-95f0wens.js +2 -0
  72. package/dist/{chunk-g1de763m.js → chunk-9ghxym50.js} +2 -2
  73. package/dist/{chunk-n8fe2njr.js → chunk-9hts7x5n.js} +2 -2
  74. package/dist/{chunk-8sa6xn88.js → chunk-9hwqfjc1.js} +2 -2
  75. package/dist/{chunk-zqpcrtde.js → chunk-9ns2xh84.js} +2 -2
  76. package/dist/{chunk-y8p2dmw3.js → chunk-9nz4c647.js} +2 -2
  77. package/dist/{chunk-tz1gzwas.js → chunk-a2tkhes5.js} +2 -2
  78. package/dist/{chunk-zy6qme7n.js → chunk-a4ebhcsy.js} +2 -2
  79. package/dist/{chunk-mhhtcbh9.js → chunk-aeccrrg1.js} +2 -2
  80. package/dist/{chunk-arr0hypp.js → chunk-aemtk0r5.js} +2 -2
  81. package/dist/{chunk-r7g85s0a.js → chunk-afnnrn6z.js} +2 -2
  82. package/dist/chunk-aj0z9a5r.js +2 -0
  83. package/dist/{chunk-x49qjrbk.js → chunk-aj6yxm6d.js} +2 -2
  84. package/dist/{chunk-rt9dn0b3.js → chunk-aq3hemsb.js} +3 -3
  85. package/dist/{chunk-zk395v8p.js → chunk-b0zzq2ky.js} +2 -2
  86. package/dist/{chunk-f6cexkjm.js → chunk-b3mja7d9.js} +3 -3
  87. package/dist/{chunk-8w08gd0y.js → chunk-b6kn9ack.js} +3 -3
  88. package/dist/{chunk-mfkrs2at.js → chunk-b8tx1n1a.js} +2 -2
  89. package/dist/chunk-bdea3k6b.js +2 -0
  90. package/dist/{chunk-52wrk1mh.js → chunk-bm457bsd.js} +2 -2
  91. package/dist/{chunk-bhajnmtf.js → chunk-bt42z99s.js} +2 -2
  92. package/dist/{chunk-2016dacx.js → chunk-by7k0ypx.js} +2 -2
  93. package/dist/{chunk-wpacvdsv.js → chunk-bysgsnph.js} +2 -2
  94. package/dist/{chunk-bq31dzpj.js → chunk-c0czkyzh.js} +2 -2
  95. package/dist/chunk-c70a2esc.js +2 -0
  96. package/dist/{chunk-xqqk85kd.js → chunk-ccner90h.js} +2 -2
  97. package/dist/{chunk-e84mhse2.js → chunk-cgpnhrm5.js} +3 -3
  98. package/dist/{chunk-kj3a1k2q.js → chunk-chjt1pct.js} +2 -2
  99. package/dist/{chunk-pr7xj1fn.js → chunk-ck70ewc8.js} +2 -2
  100. package/dist/{chunk-fpsn6fmf.js → chunk-ckft9abb.js} +2 -2
  101. package/dist/{chunk-6nbqbjnb.js → chunk-d0zazfrq.js} +3 -3
  102. package/dist/{chunk-q78ng7mn.js → chunk-d607659a.js} +2 -2
  103. package/dist/{chunk-zyn0ys4m.js → chunk-d84xx4bh.js} +2 -2
  104. package/dist/{chunk-vys8kfkp.js → chunk-db8hae9d.js} +2 -2
  105. package/dist/chunk-ddaz4j9s.js +2 -0
  106. package/dist/{chunk-r0dg1bjd.js → chunk-dhx1sd4s.js} +2 -2
  107. package/dist/{chunk-at25g15n.js → chunk-dzncwejn.js} +2 -2
  108. package/dist/chunk-e99t3sk5.js +2 -0
  109. package/dist/{chunk-ske5z0gp.js → chunk-ebkz1sy2.js} +2 -2
  110. package/dist/chunk-eevfr0tx.js +2 -0
  111. package/dist/{chunk-89gyxwmd.js → chunk-enkrqfqq.js} +2 -2
  112. package/dist/{chunk-z8b3nz7t.js → chunk-epqqzh99.js} +2 -2
  113. package/dist/{chunk-prwzyc7q.js → chunk-epqyjwrh.js} +2 -2
  114. package/dist/{chunk-0bc7gfq4.js → chunk-evgfpd16.js} +2 -2
  115. package/dist/chunk-eyw05qyj.js +4 -0
  116. package/dist/{chunk-15m908ph.js → chunk-f2h074g0.js} +2 -2
  117. package/dist/{chunk-zg0tv3sj.js → chunk-fggwwmzc.js} +3 -3
  118. package/dist/{chunk-a18avvt2.js → chunk-fqchnswc.js} +2 -2
  119. package/dist/{chunk-sbyp6k8w.js → chunk-fvmnj6bg.js} +2 -2
  120. package/dist/chunk-fxzh4f7c.js +4 -0
  121. package/dist/chunk-fzfwftqs.js +2 -0
  122. package/dist/{chunk-qd9s7wmj.js → chunk-g9v0jr0f.js} +3 -3
  123. package/dist/{chunk-28nsjq3w.js → chunk-ged1nyhk.js} +5 -5
  124. package/dist/chunk-gk7nn747.js +2 -0
  125. package/dist/chunk-gmns080g.js +2 -0
  126. package/dist/chunk-gw4zbw0m.js +2 -0
  127. package/dist/{chunk-cef598jy.js → chunk-gy446wcz.js} +2 -2
  128. package/dist/chunk-h71pkpwg.js +2 -0
  129. package/dist/{chunk-bsb08p49.js → chunk-ha1s3jbc.js} +3 -3
  130. package/dist/{chunk-k3fwyr6s.js → chunk-hfjttc7r.js} +2 -2
  131. package/dist/{chunk-vedvkp9e.js → chunk-hqc5c3nz.js} +3 -3
  132. package/dist/{chunk-5x2aqmhm.js → chunk-hwhyyaen.js} +2 -2
  133. package/dist/{chunk-z6tw9cf9.js → chunk-j1t1fnew.js} +2 -2
  134. package/dist/chunk-j2bp0zbe.js +2 -0
  135. package/dist/{chunk-y0rnvmrw.js → chunk-jne0bc79.js} +2 -2
  136. package/dist/chunk-jtws1jg5.js +2 -0
  137. package/dist/{chunk-1md5vq9g.js → chunk-jygp7479.js} +2 -2
  138. package/dist/{chunk-b9v0vew6.js → chunk-jz7mckdp.js} +2 -2
  139. package/dist/{chunk-8hm3nkrk.js → chunk-k014w2jg.js} +2 -2
  140. package/dist/{chunk-m6sdmcpj.js → chunk-k0h18sme.js} +2 -2
  141. package/dist/{chunk-vb9mn75j.js → chunk-k1w3acq7.js} +2 -2
  142. package/dist/{chunk-as2j0yp0.js → chunk-k5065dzv.js} +2 -2
  143. package/dist/chunk-k97dpdcj.js +2 -0
  144. package/dist/{chunk-v4tznge3.js → chunk-kgx0jj22.js} +3 -3
  145. package/dist/chunk-khd2r3jh.js +2 -0
  146. package/dist/{chunk-1gb1vwvy.js → chunk-kk9dbwd1.js} +2 -2
  147. package/dist/chunk-kvgn4b2n.js +2 -0
  148. package/dist/{chunk-w83nb5a8.js → chunk-mg9a4t04.js} +2 -2
  149. package/dist/{chunk-6h10jana.js → chunk-mgve4dcw.js} +2 -2
  150. package/dist/{chunk-dhn9f10w.js → chunk-mgwkmr8g.js} +2 -2
  151. package/dist/{chunk-qk1yqepm.js → chunk-mhrn3e8j.js} +2 -2
  152. package/dist/{chunk-fwn521m5.js → chunk-mkawbqx5.js} +2 -2
  153. package/dist/chunk-mp5f940y.js +1 -0
  154. package/dist/chunk-mybye5t2.js +2 -0
  155. package/dist/{chunk-9x70f7zv.js → chunk-n4rep234.js} +2 -2
  156. package/dist/{chunk-k5kzw2px.js → chunk-nebke41s.js} +3 -3
  157. package/dist/{chunk-5h49mv0e.js → chunk-newkrtrj.js} +2 -2
  158. package/dist/{chunk-9jth6sk7.js → chunk-nfnejf16.js} +2 -2
  159. package/dist/{chunk-zyyn9t8n.js → chunk-njw6x85v.js} +3 -3
  160. package/dist/{chunk-1d29gnb2.js → chunk-npt6at4f.js} +2 -2
  161. package/dist/chunk-nrfyvzmk.js +2 -0
  162. package/dist/{chunk-86tpa1nn.js → chunk-nvadhyne.js} +2 -2
  163. package/dist/{chunk-rd51rvde.js → chunk-p2bn8ypc.js} +2 -2
  164. package/dist/chunk-pnx0f495.js +2 -0
  165. package/dist/{chunk-7p0d3rz7.js → chunk-ppcwcrdz.js} +2 -2
  166. package/dist/chunk-prr551k0.js +2 -0
  167. package/dist/chunk-pvm6d77q.js +2 -0
  168. package/dist/{chunk-0b50jg23.js → chunk-pxbww0j1.js} +2 -2
  169. package/dist/{chunk-g947bnqx.js → chunk-pz5d0vgv.js} +2 -2
  170. package/dist/chunk-q2ykvjrz.js +2 -0
  171. package/dist/chunk-q8c4k6qh.js +2 -0
  172. package/dist/{chunk-vnd6smsp.js → chunk-q8y2a23c.js} +2 -2
  173. package/dist/{chunk-11kkxd6v.js → chunk-qbmgsd3h.js} +2 -2
  174. package/dist/{chunk-965sngjd.js → chunk-qbpy0aqe.js} +2 -2
  175. package/dist/chunk-qgrd5xre.js +2 -0
  176. package/dist/{chunk-r8gnmyb1.js → chunk-qkddvxjr.js} +2 -2
  177. package/dist/chunk-qv61ef2y.js +2 -0
  178. package/dist/{chunk-9t672hzm.js → chunk-qvdfrmpb.js} +2 -2
  179. package/dist/chunk-qvzxzzw8.js +2 -0
  180. package/dist/{chunk-b6sb3akb.js → chunk-r2b234a7.js} +2 -2
  181. package/dist/{chunk-0t4fcgge.js → chunk-ra52dqfb.js} +2 -2
  182. package/dist/{chunk-68afy8mk.js → chunk-rb6mjycp.js} +2 -2
  183. package/dist/{chunk-dqjhmzjy.js → chunk-rbs3079t.js} +2 -2
  184. package/dist/chunk-rcynxrkk.js +4 -0
  185. package/dist/{chunk-75xtk0a3.js → chunk-rms7wj04.js} +2 -2
  186. package/dist/{chunk-pr6qwqpj.js → chunk-rntrfb49.js} +2 -2
  187. package/dist/{chunk-h4xx90s4.js → chunk-rxj5619b.js} +2 -2
  188. package/dist/{chunk-72xm1tz1.js → chunk-ry5phnnk.js} +2 -2
  189. package/dist/{chunk-z0q7ghbg.js → chunk-s11mgwyh.js} +2 -2
  190. package/dist/{chunk-4wm5emgf.js → chunk-s170cg6j.js} +2 -2
  191. package/dist/{chunk-8gas4q2s.js → chunk-s1w3j9p9.js} +2 -2
  192. package/dist/{chunk-2dnzdsrv.js → chunk-sfd0pp49.js} +3 -3
  193. package/dist/chunk-shzj5zf0.js +2 -0
  194. package/dist/chunk-sk9rm826.js +2 -0
  195. package/dist/chunk-svxnx1c7.js +2 -0
  196. package/dist/chunk-symaxskd.js +2 -0
  197. package/dist/chunk-t3rv7vat.js +2 -0
  198. package/dist/{chunk-yq4wz4n8.js → chunk-t6ddgvkm.js} +2 -2
  199. package/dist/{chunk-g7dxg38a.js → chunk-th5vv83g.js} +2 -2
  200. package/dist/{chunk-dxwbgg69.js → chunk-tj4b0s68.js} +2 -2
  201. package/dist/chunk-veef1avy.js +2 -0
  202. package/dist/chunk-vgxvtmja.js +2 -0
  203. package/dist/{chunk-ad53zbdb.js → chunk-vjfxm73q.js} +2 -2
  204. package/dist/chunk-vnxa4qe2.js +2 -0
  205. package/dist/{chunk-9y0fxq8e.js → chunk-vq060dnz.js} +2 -2
  206. package/dist/{chunk-ckbqdg1s.js → chunk-vyvsm4v9.js} +2 -2
  207. package/dist/{chunk-8w5bt0nc.js → chunk-w1yrsbw1.js} +2 -2
  208. package/dist/{chunk-64apxzn7.js → chunk-w2p1g8rp.js} +2 -2
  209. package/dist/{chunk-rr5ek064.js → chunk-w4537026.js} +2 -2
  210. package/dist/chunk-wexhc7rb.js +2 -0
  211. package/dist/{chunk-nef7y6mg.js → chunk-wf0ytnh9.js} +2 -2
  212. package/dist/{chunk-xqb4thy8.js → chunk-wf4z9w5x.js} +2 -2
  213. package/dist/{chunk-j4ejwthn.js → chunk-whax282d.js} +2 -2
  214. package/dist/{chunk-x6spt0mc.js → chunk-wrxj79ct.js} +2 -2
  215. package/dist/{chunk-mt01qph9.js → chunk-xanfp0nh.js} +2 -2
  216. package/dist/{chunk-jaghs2z5.js → chunk-xjf2zkrg.js} +2 -2
  217. package/dist/{chunk-dwxmgsg8.js → chunk-xqrhfxct.js} +2 -2
  218. package/dist/{chunk-ksq9a3pf.js → chunk-xxwevgqr.js} +2 -2
  219. package/dist/{chunk-x2wcwpw3.js → chunk-y5qzgfsd.js} +2 -2
  220. package/dist/chunk-y72y3j24.js +2 -0
  221. package/dist/{chunk-81xwn9e5.js → chunk-y8aeahf2.js} +3 -3
  222. package/dist/chunk-ygake3bx.js +2 -0
  223. package/dist/{chunk-zb0m2cqy.js → chunk-ymdhz3x0.js} +2 -2
  224. package/dist/{chunk-erdrx47j.js → chunk-ytkcpeq2.js} +2 -2
  225. package/dist/{chunk-69tgmjdb.js → chunk-z27pxeqg.js} +2 -2
  226. package/dist/{chunk-mrwawq46.js → chunk-z53fd30n.js} +2 -2
  227. package/dist/{chunk-54j6xftt.js → chunk-zjzzqtaj.js} +2 -2
  228. package/dist/{chunk-mmrwaa9h.js → chunk-zpetyx45.js} +2 -2
  229. package/dist/chunk-zpm0t5ye.js +2 -0
  230. package/dist/chunk-ztrkk6sp.js +2 -0
  231. package/dist/client.js +1 -1
  232. package/dist/codex/activity-group.js +1 -1
  233. package/dist/codex/artifact-links.js +1 -1
  234. package/dist/codex/assistant-message.js +1 -1
  235. package/dist/codex/async-question-card.js +1 -1
  236. package/dist/codex/disclosure-state.js +1 -1
  237. package/dist/codex/edited-files-card.js +1 -1
  238. package/dist/codex/image-view-activity.js +1 -1
  239. package/dist/codex/markdown-renderer.js +1 -1
  240. package/dist/codex/navigation-audio.js +1 -1
  241. package/dist/codex/navigation-preview.js +1 -1
  242. package/dist/codex/navigation-rail.js +1 -1
  243. package/dist/codex/patch-view.js +1 -1
  244. package/dist/codex/plan.js +1 -1
  245. package/dist/codex/timeline-virtualizer.js +1 -1
  246. package/dist/codex/turn-activity.js +1 -1
  247. package/dist/codex/user-message.js +1 -1
  248. package/dist/codex/virtualized-turn-list.js +1 -1
  249. package/dist/collections/collection-emoji.js +1 -1
  250. package/dist/collections/collection-menu.js +1 -1
  251. package/dist/collections/collection-panel.js +1 -1
  252. package/dist/collections/collections.js +1 -1
  253. package/dist/collections/host.js +1 -1
  254. package/dist/collections/locales.js +1 -1
  255. package/dist/collections/model.js +1 -1
  256. package/dist/collections/store.js +1 -1
  257. package/dist/composer/completion-filter.js +1 -1
  258. package/dist/composer/completion-menu.js +1 -1
  259. package/dist/composer/completion-trigger.js +1 -1
  260. package/dist/composer/effort-slider.js +1 -1
  261. package/dist/composer/inline-document.js +1 -1
  262. package/dist/composer/inline-dom.js +1 -1
  263. package/dist/composer/menu-radio.js +1 -1
  264. package/dist/composer/model-select.js +1 -1
  265. package/dist/composer/permission-mode-select.js +1 -1
  266. package/dist/composer/prompt-input-attachments.js +1 -1
  267. package/dist/composer/prompt-input-clipboard.js +1 -1
  268. package/dist/composer/prompt-input-context.d.ts +9 -0
  269. package/dist/composer/prompt-input-context.js +1 -1
  270. package/dist/composer/prompt-input-inline.js +1 -1
  271. package/dist/composer/prompt-input-textarea.js +1 -1
  272. package/dist/composer/prompt-input.js +1 -1
  273. package/dist/conversation/action-card.js +1 -1
  274. package/dist/conversation/composer/app-mentions.js +1 -1
  275. package/dist/conversation/composer/apps-menu.js +1 -1
  276. package/dist/conversation/composer/composer-menu.js +1 -1
  277. package/dist/conversation/composer/composer.js +1 -1
  278. package/dist/conversation/composer/config-options.js +1 -1
  279. package/dist/conversation/composer/context.js +1 -1
  280. package/dist/conversation/composer/drafts.js +1 -1
  281. package/dist/conversation/composer/file-items.js +1 -1
  282. package/dist/conversation/composer/long-text.js +1 -1
  283. package/dist/conversation/composer/mention-chips.js +1 -1
  284. package/dist/conversation/composer/mention-uri.js +1 -1
  285. package/dist/conversation/composer/model-menu.js +1 -1
  286. package/dist/conversation/composer/pasted-text-attachment.js +1 -1
  287. package/dist/conversation/composer/permission-mode-menu.js +1 -1
  288. package/dist/conversation/composer/prediction.js +1 -1
  289. package/dist/conversation/composer/prompt-history.js +1 -1
  290. package/dist/conversation/composer/slash-command-button.js +1 -1
  291. package/dist/conversation/composer/submit-button.js +1 -1
  292. package/dist/conversation/composer/usage-meter.js +1 -1
  293. package/dist/conversation/connection-notice.js +1 -1
  294. package/dist/conversation/context.js +1 -1
  295. package/dist/conversation/conversation-body.js +1 -1
  296. package/dist/conversation/conversation-search.js +1 -1
  297. package/dist/conversation/conversation-view.js +1 -1
  298. package/dist/conversation/conversation.js +1 -1
  299. package/dist/conversation/diff-modal.js +1 -1
  300. package/dist/conversation/draft-project-picker.js +1 -1
  301. package/dist/conversation/session-actions.js +1 -1
  302. package/dist/conversation/subagent-sessions.js +1 -1
  303. package/dist/conversation/subagent-tasks.js +1 -1
  304. package/dist/desktop/desktop-composer.d.ts +2 -1
  305. package/dist/desktop/desktop-composer.js +1 -1
  306. package/dist/desktop/desktop.js +1 -1
  307. package/dist/desktop/draft-model-select.js +1 -1
  308. package/dist/desktop/load-image.js +1 -1
  309. package/dist/desktop/model-catalog.js +1 -1
  310. package/dist/desktop/model-recovery.js +1 -1
  311. package/dist/desktop/model-settings-action.js +1 -1
  312. package/dist/desktop/native-file-drop.d.ts +3 -1
  313. package/dist/desktop/native-file-drop.js +1 -1
  314. package/dist/generated/commands.d.ts +1 -0
  315. package/dist/generated/commands.js +1 -1
  316. package/dist/generated-image-storage.d.ts +11 -0
  317. package/dist/generated-image-storage.js +1 -0
  318. package/dist/image-lightbox.js +1 -1
  319. package/dist/image-preview-dialog.js +1 -1
  320. package/dist/image.d.ts +5 -1
  321. package/dist/image.js +1 -1
  322. package/dist/lib/app-reference.js +1 -1
  323. package/dist/lib/application-metadata.js +1 -1
  324. package/dist/lib/chat-path.js +1 -1
  325. package/dist/lib/code-highlighter.js +1 -1
  326. package/dist/lib/file-url.js +1 -1
  327. package/dist/lib/fuzzy.js +1 -1
  328. package/dist/lib/group-blocks.js +1 -1
  329. package/dist/lib/image-encode.js +1 -1
  330. package/dist/lib/limits.js +1 -1
  331. package/dist/lib/markdown-parser.js +1 -1
  332. package/dist/lib/markdown-rules.js +1 -1
  333. package/dist/lib/model-name.js +1 -1
  334. package/dist/lib/pointer-centered-zoom.js +1 -1
  335. package/dist/lib/prepare-prompt-files.d.ts +2 -2
  336. package/dist/lib/prepare-prompt-files.js +1 -1
  337. package/dist/lib/reference-presentation.js +1 -1
  338. package/dist/lib/stream-style.js +1 -1
  339. package/dist/lib/streaming-markdown.js +1 -1
  340. package/dist/lib/tool-artifacts.js +1 -1
  341. package/dist/locales.js +1 -1
  342. package/dist/mermaid/diagram.js +1 -1
  343. package/dist/mermaid/export.js +1 -1
  344. package/dist/mermaid/index.js +1 -1
  345. package/dist/mermaid/preview.js +1 -1
  346. package/dist/oauth/claude-login.js +1 -1
  347. package/dist/oauth.js +1 -1
  348. package/dist/plugins/catalog-header.js +1 -1
  349. package/dist/plugins/catalog-skeleton.js +1 -1
  350. package/dist/plugins/host.js +1 -1
  351. package/dist/plugins/locales.js +1 -1
  352. package/dist/plugins/new-chat-directory.js +1 -1
  353. package/dist/plugins/pane.js +1 -1
  354. package/dist/plugins/panel-item.js +1 -1
  355. package/dist/plugins/plugin-detail-page.js +1 -1
  356. package/dist/plugins/plugin-icon.js +1 -1
  357. package/dist/plugins/plugin-icons.js +1 -1
  358. package/dist/plugins/plugins-page.js +1 -1
  359. package/dist/plugins/plugins.js +1 -1
  360. package/dist/plugins/read-skill-document.js +1 -1
  361. package/dist/plugins/skill-document.js +1 -1
  362. package/dist/plugins/skills-tab.js +1 -1
  363. package/dist/plugins/store.js +1 -1
  364. package/dist/plugins/toolbox-layout.js +1 -1
  365. package/dist/reference-projection.js +1 -1
  366. package/dist/search/chat-search.js +1 -1
  367. package/dist/search/codex-source-matches.js +1 -1
  368. package/dist/search/dom-matches.js +1 -1
  369. package/dist/search/find-bar.js +1 -1
  370. package/dist/search/literal-matches.js +1 -1
  371. package/dist/session-list/account-menu.js +1 -1
  372. package/dist/session-list/activity-list.js +1 -1
  373. package/dist/session-list/archived-sessions.js +1 -1
  374. package/dist/session-list/help-menu.js +1 -1
  375. package/dist/session-list/highlight.js +1 -1
  376. package/dist/session-list/host.js +1 -1
  377. package/dist/session-list/hover-info-card.js +1 -1
  378. package/dist/session-list/locales.js +1 -1
  379. package/dist/session-list/navigation-controls.js +1 -1
  380. package/dist/session-list/navigation-header.js +1 -1
  381. package/dist/session-list/navigation-store.js +1 -1
  382. package/dist/session-list/navigation-tabs.js +1 -1
  383. package/dist/session-list/navigation.js +1 -1
  384. package/dist/session-list/platform.js +1 -1
  385. package/dist/session-list/row-stop-button.js +1 -1
  386. package/dist/session-list/session-groups.js +1 -1
  387. package/dist/session-list/session-info-card.js +1 -1
  388. package/dist/session-list/session-list.js +1 -1
  389. package/dist/session-list/session-row.js +1 -1
  390. package/dist/session-list/session-state-dot.js +1 -1
  391. package/dist/session-list/session-state-menu.js +1 -1
  392. package/dist/session-list/shortcut-hint.js +1 -1
  393. package/dist/session-list/shortcut.js +1 -1
  394. package/dist/session-list/sidebar-overlay.js +1 -1
  395. package/dist/session-list/trailing-swap.js +1 -1
  396. package/dist/session-list/use-activity-notification.js +1 -1
  397. package/dist/session-list/use-activity-preview.js +1 -1
  398. package/dist/session-list/use-cmd-held.js +1 -1
  399. package/dist/session-list/use-project-sessions.js +1 -1
  400. package/dist/session-list/virtual-session-rows.js +1 -1
  401. package/dist/session-timeline/activity-group.js +1 -1
  402. package/dist/session-timeline/activity-projection.js +1 -1
  403. package/dist/session-timeline/assistant-content.js +1 -1
  404. package/dist/session-timeline/assistant-image-references.js +1 -1
  405. package/dist/session-timeline/assistant-turn.js +1 -1
  406. package/dist/session-timeline/async-questions.js +1 -1
  407. package/dist/session-timeline/edited-files-card.js +1 -1
  408. package/dist/session-timeline/history-timeline.js +1 -1
  409. package/dist/session-timeline/host.js +1 -1
  410. package/dist/session-timeline/image-generation-progress.js +1 -1
  411. package/dist/session-timeline/navigation-rail.js +1 -1
  412. package/dist/session-timeline/plan.js +1 -1
  413. package/dist/session-timeline/question-reply.js +1 -1
  414. package/dist/session-timeline/resource-content.js +1 -1
  415. package/dist/session-timeline/session-timeline.js +1 -1
  416. package/dist/session-timeline/timeline-registry.js +1 -1
  417. package/dist/session-timeline/turn-activity.js +1 -1
  418. package/dist/session-timeline/turn-error.js +1 -1
  419. package/dist/session-timeline/turn-retry.js +1 -1
  420. package/dist/session-timeline/turn-time.js +1 -1
  421. package/dist/session-timeline/turns.js +1 -1
  422. package/dist/session-timeline/use-timeline-scroll.js +1 -1
  423. package/dist/session-timeline/user-message.js +1 -1
  424. package/dist/settings/codex-account-card.js +1 -1
  425. package/dist/settings/login-card.js +1 -1
  426. package/dist/settings/model-alias-settings.js +1 -1
  427. package/dist/settings/model-aliases.js +1 -1
  428. package/dist/settings/provider-logos.js +1 -1
  429. package/dist/settings/provider-section.js +1 -1
  430. package/dist/settings/providers-port.js +1 -1
  431. package/dist/settings/providers.js +1 -1
  432. package/dist/settings/settings-bridge.js +1 -1
  433. package/dist/settings/settings.js +1 -1
  434. package/native/win32-x64/alwith_native_chat.dll +0 -0
  435. package/native/win32-x64/artifact.json +1 -1
  436. package/package.json +3 -3
  437. package/dist/chunk-0kaa9dja.js +0 -2
  438. package/dist/chunk-0myfs71s.js +0 -2
  439. package/dist/chunk-19jwgexv.js +0 -4
  440. package/dist/chunk-1p3ekdt4.js +0 -2
  441. package/dist/chunk-1xgm6fpr.js +0 -2
  442. package/dist/chunk-2rjg9fs9.js +0 -2
  443. package/dist/chunk-2s0jckfr.js +0 -2
  444. package/dist/chunk-3272z6sv.js +0 -2
  445. package/dist/chunk-38eckxjk.js +0 -2
  446. package/dist/chunk-56jqg70p.js +0 -2
  447. package/dist/chunk-5rzy2287.js +0 -2
  448. package/dist/chunk-6cedp3k2.js +0 -2
  449. package/dist/chunk-6eg26dz5.js +0 -4
  450. package/dist/chunk-7hhc8y2n.js +0 -2
  451. package/dist/chunk-7xsrqwvt.js +0 -2
  452. package/dist/chunk-9s8ht9xe.js +0 -2
  453. package/dist/chunk-b5g055qp.js +0 -2
  454. package/dist/chunk-bqbyjazm.js +0 -2
  455. package/dist/chunk-cmfcnze3.js +0 -4
  456. package/dist/chunk-d4jkh19p.js +0 -2
  457. package/dist/chunk-dn8xcv31.js +0 -2
  458. package/dist/chunk-dwv3z2sk.js +0 -2
  459. package/dist/chunk-e4ws15tg.js +0 -2
  460. package/dist/chunk-e8bazy7m.js +0 -2
  461. package/dist/chunk-eaxevj9t.js +0 -2
  462. package/dist/chunk-f0hb6t2w.js +0 -2
  463. package/dist/chunk-f67e77e6.js +0 -2
  464. package/dist/chunk-fcy6mh2e.js +0 -2
  465. package/dist/chunk-gs0b02g2.js +0 -2
  466. package/dist/chunk-hs98zk6m.js +0 -2
  467. package/dist/chunk-jf7em132.js +0 -1
  468. package/dist/chunk-k2xs8svj.js +0 -2
  469. package/dist/chunk-kv3hsfyk.js +0 -2
  470. package/dist/chunk-kyqf7cqh.js +0 -2
  471. package/dist/chunk-m4ds8kjc.js +0 -2
  472. package/dist/chunk-m6yg0dc9.js +0 -2
  473. package/dist/chunk-n88j8hsd.js +0 -2
  474. package/dist/chunk-nvsws1yg.js +0 -2
  475. package/dist/chunk-p02bdewy.js +0 -2
  476. package/dist/chunk-pae2hjvq.js +0 -2
  477. package/dist/chunk-ptdx40ae.js +0 -2
  478. package/dist/chunk-q61xz251.js +0 -2
  479. package/dist/chunk-rkqptd9w.js +0 -2
  480. package/dist/chunk-t1qj0vqe.js +0 -2
  481. package/dist/chunk-t2ej667n.js +0 -2
  482. package/dist/chunk-tab23kkx.js +0 -2
  483. package/dist/chunk-w1ga47ww.js +0 -2
  484. package/dist/chunk-w2bgfpdh.js +0 -2
  485. package/dist/chunk-wj9s8331.js +0 -2
  486. package/dist/chunk-wjgrrfq9.js +0 -2
  487. package/dist/chunk-ygaqqwmb.js +0 -2
  488. package/dist/chunk-yvzkb5p5.js +0 -2
  489. package/dist/chunk-z6x70w62.js +0 -2
  490. package/dist/chunk-zea1chz7.js +0 -3
@@ -1,2 +1,2 @@
1
- import{t}from"./chunk-e4ws15tg.js";import{codexTurnError as R}from"@nyssance/codex-acp-v2/client";import{AlertCircleIcon as C}from"lucide-react";import{useEffect as k,useRef as i,useState as s}from"react";import{Button as I}from"@nyssance/shadcn/vega/components/ui/button";import{jsx as n,jsxs as m}from"react/jsx-runtime";function No({children:u}){return m("div",{className:"codex-error-message",role:"alert",children:[n(C,{"aria-hidden":"true"}),n("div",{className:"min-w-0 flex-1",children:u})]})}function Ao({error:u,retry:e}){let{t:f,turnErrorAction:T}=t(),c=R(u),[l]=s(()=>e?.delaySeconds==null?null:Date.now()+e.delaySeconds*1000),[p,v]=s(e?.delaySeconds??null),[h,y]=s(!1),[x,g]=s(null),o=i(!1),w=i(!1),E=i(e?.run);E.current=e?.run;let S=i((N)=>{let a=E.current;if(o.current||a===void 0)return;o.current=!0,y(!0),g(null),a(N).catch((r)=>{w.current=!0,o.current=!1,v(null),y(!1),g(r instanceof Error?r.message:String(r))})}),b=T?.(c),d=b===void 0&&e!==void 0&&c.retryable;return k(()=>{if(!d||l===null)return;let a=setInterval(()=>{if(w.current||o.current)return;let r=Math.max(0,Math.ceil((l-Date.now())/1000));if(v(r),r===0)S.current("automatic")},1000);return()=>clearInterval(a)},[l,d]),m(No,{children:[m("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[n("div",{className:"min-w-0 flex-1 whitespace-pre-wrap",children:c.message}),b,d&&n(I,{variant:"outline",size:"sm",disabled:h,onClick:()=>S.current("manual"),children:p===null?f("timeline.retry"):f("timeline.retryCountdown",{seconds:p})})]}),x!==null&&n("div",{className:"text-muted-foreground mt-2 text-sm",children:x})]})}
2
- export{No,Ao};
1
+ import{t}from"./chunk-aj0z9a5r.js";import{codexTurnError as R}from"@nyssance/codex-acp-v2/client";import{AlertCircleIcon as C}from"lucide-react";import{useEffect as k,useRef as i,useState as s}from"react";import{Button as I}from"@nyssance/shadcn/vega/components/ui/button";import{jsx as n,jsxs as m}from"react/jsx-runtime";function Ho({children:u}){return m("div",{className:"codex-error-message",role:"alert",children:[n(C,{"aria-hidden":"true"}),n("div",{className:"min-w-0 flex-1",children:u})]})}function Uo({error:u,retry:e}){let{t:f,turnErrorAction:T}=t(),c=R(u),[l]=s(()=>e?.delaySeconds==null?null:Date.now()+e.delaySeconds*1000),[p,v]=s(e?.delaySeconds??null),[h,y]=s(!1),[x,g]=s(null),o=i(!1),w=i(!1),E=i(e?.run);E.current=e?.run;let S=i((N)=>{let a=E.current;if(o.current||a===void 0)return;o.current=!0,y(!0),g(null),a(N).catch((r)=>{w.current=!0,o.current=!1,v(null),y(!1),g(r instanceof Error?r.message:String(r))})}),b=T?.(c),d=b===void 0&&e!==void 0&&c.retryable;return k(()=>{if(!d||l===null)return;let a=setInterval(()=>{if(w.current||o.current)return;let r=Math.max(0,Math.ceil((l-Date.now())/1000));if(v(r),r===0)S.current("automatic")},1000);return()=>clearInterval(a)},[l,d]),m(Ho,{children:[m("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[n("div",{className:"min-w-0 flex-1 whitespace-pre-wrap",children:c.message}),b,d&&n(I,{variant:"outline",size:"sm",disabled:h,onClick:()=>S.current("manual"),children:p===null?f("timeline.retry"):f("timeline.retryCountdown",{seconds:p})})]}),x!==null&&n("div",{className:"text-muted-foreground mt-2 text-sm",children:x})]})}
2
+ export{Ho,Uo};
@@ -1,2 +1,2 @@
1
- var ks=(t)=>{let e=t.startsWith("/")&&t!=="/"?t.replace(/\/+$/,""):t,r=/^\/(?:private\/)?(var|tmp|etc)(\/.*)?$/.exec(e);if(!r)return[e];let s=`${r[1]}${r[2]??""}`;return[`/private/${s}`,`/${s}`]};
2
- export{ks};
1
+ var Ts=(t)=>{let e=t.startsWith("/")&&t!=="/"?t.replace(/\/+$/,""):t,r=/^\/(?:private\/)?(var|tmp|etc)(\/.*)?$/.exec(e);if(!r)return[e];let s=`${r[1]}${r[2]??""}`;return[`/private/${s}`,`/${s}`]};
2
+ export{Ts};
@@ -1,2 +1,2 @@
1
- import{C}from"./chunk-wjgrrfq9.js";var xo="application/x-alwith-app-references+json";function m(n){let r=[],t=n.apps.map((e,o)=>({app:e,order:o,offset:Math.max(0,Math.min(n.text.length,e.offset??0))})).sort((e,o)=>e.offset-o.offset||e.order-o.order),i=0;for(let{app:e,offset:o}of t)r.push(...n.text.slice(i,o).split(""),e),i=o;return r.push(...n.text.slice(i).split("")),r}function S(n){let r="",t=[],i=new Set;for(let e of n)if(typeof e==="string")r+=e;else if(!i.has(e.id))i.add(e.id),t.push({...e,offset:r.length});return{text:r,apps:t}}function jn(n,r){return n.slice(0,r).filter((t)=>typeof t==="string").length}function bo(n,r){let t=0;for(let i=0;i<n.length;i++){if(typeof n[i]!=="string")continue;if(t===r)return i;t++}return n.length}function Tt(n){let r=n.getData(xo);if(!r)return null;let t;try{t=JSON.parse(r)}catch{return null}if(typeof t!=="object"||t===null||!("version"in t)||t.version!==1||!("text"in t)||typeof t.text!=="string"||!("apps"in t)||!Array.isArray(t.apps))return null;let i=[];for(let e of t.apps){if(typeof e!=="object"||e===null||typeof e.id!=="string"||C(`app://${e.id}`)!==e.id||typeof e.name!=="string"||!e.name.trim()||!Number.isInteger(e.offset)||e.offset<0||e.offset>t.text.length)return null;if(e.iconUrl!=null&&typeof e.iconUrl!=="string"||e.iconUrlDark!=null&&typeof e.iconUrlDark!=="string")return null;i.push({id:e.id,name:e.name,offset:e.offset,...e.iconUrl?{iconUrl:e.iconUrl}:{},...e.iconUrlDark?{iconUrlDark:e.iconUrlDark}:{}})}return S(m({text:t.text,apps:i}))}
2
- export{xo,m,S,jn,bo,Tt};
1
+ import{w}from"./chunk-4g2412p5.js";var _o="application/x-alwith-app-references+json";function m(n){let r=[],t=n.apps.map((e,o)=>({app:e,order:o,offset:Math.max(0,Math.min(n.text.length,e.offset??0))})).sort((e,o)=>e.offset-o.offset||e.order-o.order),i=0;for(let{app:e,offset:o}of t)r.push(...n.text.slice(i,o).split(""),e),i=o;return r.push(...n.text.slice(i).split("")),r}function _(n){let r="",t=[],i=new Set;for(let e of n)if(typeof e==="string")r+=e;else if(!i.has(e.id))i.add(e.id),t.push({...e,offset:r.length});return{text:r,apps:t}}function Zn(n,r){return n.slice(0,r).filter((t)=>typeof t==="string").length}function Io(n,r){let t=0;for(let i=0;i<n.length;i++){if(typeof n[i]!=="string")continue;if(t===r)return i;t++}return n.length}function Rt(n){let r=n.getData(_o);if(!r)return null;let t;try{t=JSON.parse(r)}catch{return null}if(typeof t!=="object"||t===null||!("version"in t)||t.version!==1||!("text"in t)||typeof t.text!=="string"||!("apps"in t)||!Array.isArray(t.apps))return null;let i=[];for(let e of t.apps){if(typeof e!=="object"||e===null||typeof e.id!=="string"||w(`app://${e.id}`)!==e.id||typeof e.name!=="string"||!e.name.trim()||!Number.isInteger(e.offset)||e.offset<0||e.offset>t.text.length)return null;if(e.iconUrl!=null&&typeof e.iconUrl!=="string"||e.iconUrlDark!=null&&typeof e.iconUrlDark!=="string")return null;i.push({id:e.id,name:e.name,offset:e.offset,...e.iconUrl?{iconUrl:e.iconUrl}:{},...e.iconUrlDark?{iconUrlDark:e.iconUrlDark}:{}})}return _(m({text:t.text,apps:i}))}
2
+ export{_o,m,_,Zn,Io,Rt};
@@ -1,2 +1,2 @@
1
- import{cn as i}from"cn";import{jsx as t,jsxs as s}from"react/jsx-runtime";var ft="group/trailing";function Je({children:n,className:e}){return t("span",{className:i("flex w-5 shrink-0 items-center justify-center whitespace-nowrap",e),children:n})}function ht({content:n,actions:e,className:r}){if(n==null&&e==null)return null;return s("span",{className:i("group/swap relative flex min-h-5 min-w-5 shrink-0 items-center justify-end",r),children:[n!=null&&t("span",{className:i("flex items-center justify-end",e!=null&&"group-focus-within/trailing:hidden group-hover/trailing:hidden group-has-[[data-popup-open]]/swap:hidden"),children:n}),e!=null&&t("span",{className:"absolute inset-y-0 end-0 hidden w-max items-center justify-end gap-0.5 group-focus-within/trailing:flex group-hover/trailing:flex has-[[data-popup-open]]:flex",onClick:(a)=>a.stopPropagation(),onKeyDown:(a)=>a.stopPropagation(),children:e})]})}
2
- export{ft,Je,ht};
1
+ import{cn as i}from"cn";import{jsx as t,jsxs as s}from"react/jsx-runtime";var xt="group/trailing";function Ye({children:n,className:e}){return t("span",{className:i("flex w-5 shrink-0 items-center justify-center whitespace-nowrap",e),children:n})}function bt({content:n,actions:e,className:r}){if(n==null&&e==null)return null;return s("span",{className:i("group/swap relative flex min-h-5 min-w-5 shrink-0 items-center justify-end",r),children:[n!=null&&t("span",{className:i("flex items-center justify-end",e!=null&&"group-focus-within/trailing:hidden group-hover/trailing:hidden group-has-[[data-popup-open]]/swap:hidden"),children:n}),e!=null&&t("span",{className:"absolute inset-y-0 end-0 hidden w-max items-center justify-end gap-0.5 group-focus-within/trailing:flex group-hover/trailing:flex has-[[data-popup-open]]:flex",onClick:(a)=>a.stopPropagation(),onKeyDown:(a)=>a.stopPropagation(),children:e})]})}
2
+ export{xt,Ye,bt};
@@ -0,0 +1,2 @@
1
+ import{Fe,p}from"./chunk-vgxvtmja.js";import{O}from"./chunk-kv1v7kgn.js";import{G}from"./chunk-rxj5619b.js";import{E}from"./chunk-q8y2a23c.js";import{xt,Ye,bt}from"./chunk-8zkn8x2j.js";import{PreviewCard as C}from"@base-ui/react/preview-card";import{cn as u}from"cn";import{LockIcon as D}from"lucide-react";import{createContext as T,useContext as L,useLayoutEffect as M,useState as I}from"react";import"@alwith/module-chat/session-list.css";import{jsx as e,jsxs as d,Fragment as K}from"react/jsx-runtime";function N(o){if(o.as==="ul"){let{as:i,className:s,...a}=o;return e("ul",{className:u("flex w-full min-w-0 flex-col gap-0.5",s),...a})}let{as:t,className:n,...r}=o;return e("div",{className:u("flex w-full min-w-0 flex-col gap-0.5",n),...r})}function v({className:o,...t}){return e("span",{"data-slot":"navigation-leading",className:u("flex size-6 shrink-0 items-center justify-center [&_.lucide]:size-3.5",o),...t})}function f({active:o,className:t,...n}){return e("button",{type:"button","data-active":o?"":void 0,"aria-current":o?"page":void 0,className:u("group/navigation-row focus-visible:outline-ring flex h-[var(--navigation-row-height,30px)] w-full items-center gap-1 overflow-hidden rounded-[10px] ps-1 pe-1.5 text-start text-sm outline-hidden [corner-shape:superellipse(1.5)] focus-visible:outline-2 focus-visible:outline-offset-[-2px] disabled:pointer-events-none disabled:opacity-50 [&_svg]:size-4 [&_svg]:shrink-0 [&>span:last-child]:truncate",t),...n})}function ae({open:o,onOpenChange:t,tooltip:n,leading:r,label:i,count:s,countLabel:a,active:l=!1,actions:b,headerChildren:g,wrapHeader:c,onHeaderClick:P,children:y}){let R=()=>{P?.(),t(!o)},x=u(xt,"relative flex h-[var(--navigation-row-height,30px)] w-full items-center gap-1 rounded-[10px] ps-1 pe-1.5 text-start [corner-shape:superellipse(1.5)]"),S=d(K,{children:[r!=null&&e(v,{children:r}),g??e(O,{className:"flex-1 text-sm opacity-70",children:i}),e("span",{className:"relative z-10 ms-auto",children:e(bt,{content:s!==void 0?e(Ye,{className:u("text-muted-foreground justify-end text-xs opacity-70",a&&"w-auto"),children:e("span",{dir:"ltr",children:a??s})}):void 0,actions:b})})]}),k=g==null?d("div",{"data-active":l?"":void 0,title:n,className:u(x,p),onClick:R,onKeyDown:(m)=>{if(m.target!==m.currentTarget)return;if(m.key!=="Enter"&&m.key!==" ")return;m.preventDefault(),R()},children:[e("button",{type:"button","aria-expanded":o,"aria-label":typeof i==="string"?i:n,className:"focus-visible:outline-ring absolute inset-0 rounded-[10px] outline-hidden [corner-shape:superellipse(1.5)] focus-visible:outline-2 focus-visible:outline-offset-[-2px]"}),S]}):e("div",{"data-active":l?"":void 0,className:x,children:S});return d("div",{className:"text-[#1a1c1f] dark:text-white",children:[c===void 0?k:c(k),o&&e(N,{className:"mt-0.5",children:y})]})}var _=T(()=>{}),z=T(()=>{});function cn(){return L(z)}function Le(){return L(_)}function De({active:o=!1,state:t,interruption:n=null,leased:r=!1,media:i,title:s,hoverCard:a,onHoverCardOpenChange:l,subtitle:b,preview:g,listeningPorts:c,onOpenPort:P,accessory:y,meta:R,hint:x,actions:S,className:k,...m}){let H=d("div",{"data-slot":"navigation-session-item","data-active":o,className:u(xt,Fe,"group/navigation-row focus-visible:outline-ring flex h-[var(--navigation-row-height,30px)] w-full items-center gap-1 overflow-hidden rounded-[10px] ps-1 pe-1.5 text-start text-sm outline-hidden [corner-shape:superellipse(1.5)] focus-visible:outline-2 focus-visible:outline-offset-[-2px]",(g||c!=null&&c.length>0)&&"h-auto min-h-[var(--navigation-row-height,30px)] py-2.5",k),...m,children:[e(v,{children:t!=null?e(G,{state:t,title:n??void 0}):i}),d("span",{className:"flex min-w-0 flex-1 flex-col",children:[e(O,{className:u("leading-none",t==="done"&&"font-semibold"),children:s}),b!=null&&e(O,{className:"text-muted-foreground text-xs",children:b}),g&&e("span",{className:"text-muted-foreground mt-1.5 line-clamp-2 text-xs leading-[18px] [overflow-wrap:anywhere] break-words",children:g}),c!=null&&c.length>0&&e("span",{className:"text-muted-foreground mt-1.5 flex flex-wrap items-center gap-2 font-mono text-xs",children:c.map((w)=>P?d("button",{type:"button",className:"underline",onPointerDown:(h)=>h.stopPropagation(),onKeyDown:(h)=>h.stopPropagation(),onClick:(h)=>{h.stopPropagation(),P(w)},children:[":",w]},w):d("span",{children:[":",w]},w))})]}),d("span",{className:"relative ms-auto flex shrink-0 items-center gap-1",children:[r&&e(D,{className:"text-muted-foreground size-3"}),e(bt,{content:y!=null?e(Ye,{children:y}):R??e(Ye,{}),actions:S}),x!=null&&e("span",{className:"pointer-events-none absolute end-1 top-1/2 flex h-5 min-w-5 -translate-y-1/2 items-center justify-center",children:x})]})]});if(a==null)return H;return e(q,{row:H,onOpenChange:l,children:a})}function q({row:o,children:t,onOpenChange:n}){let[r,i]=I(!1),[s,a]=I(!1),l=r||s;return M(()=>(n?.(l),()=>n?.(!1)),[l,n]),e(_.Provider,{value:a,children:e(z.Provider,{value:()=>{i(!1),a(!1)},children:e(j,{open:l,onOpenChange:i,trigger:o,children:t})})})}function j({open:o,onOpenChange:t,trigger:n,children:r,side:i="inline-end",sideOffset:s=2,align:a="start",alignOffset:l}){return E(o),d(C.Root,{open:o,onOpenChange:t,children:[e(C.Trigger,{render:n,delay:700,closeDelay:100}),e(C.Portal,{children:e(C.Positioner,{side:i,sideOffset:s,align:a,alignOffset:l,className:"isolate z-50",children:e(C.Popup,{"data-slot":"codex-hover-card",className:"bg-popover text-popover-foreground ring-foreground/10 m-px flex w-80 max-w-[calc(100vw-1rem)] flex-col overflow-hidden rounded-md text-sm shadow-md ring-1 outline-hidden select-none",children:e("div",{className:"flex w-full min-w-0 flex-col px-0 py-1 break-words whitespace-normal",children:r})})})})]})}
2
+ export{N,v,f,ae,cn,Le,De};
@@ -1,2 +1,2 @@
1
- import{d,i}from"./chunk-6cedp3k2.js";import{k}from"./chunk-qk1yqepm.js";import{U}from"./chunk-mq0npf36.js";import{ke}from"./chunk-yvzkb5p5.js";import{Q,Se,_e}from"./chunk-n8b9yg4q.js";import{ExternalLinkIcon as M,PlusIcon as W}from"lucide-react";import{useEffect as _,useState as y}from"react";import{Badge as L}from"@nyssance/shadcn/vega/components/ui/badge";import{Button as f}from"@nyssance/shadcn/vega/components/ui/button";import{Dialog as q,DialogContent as F,DialogDescription as G,DialogHeader as J,DialogTitle as K}from"@nyssance/shadcn/vega/components/ui/dialog";import{Spinner as S}from"@nyssance/shadcn/vega/components/ui/spinner";import{Switch as X}from"@nyssance/shadcn/vega/components/ui/switch";import{jsx as e,jsxs as s,Fragment as O}from"react/jsx-runtime";function qt({entry:o,onBack:p}){let u=d(),{t:l}=u,P=i((a)=>a.readPlugin),C=i((a)=>a.installed.find(({plugin:g})=>g.id===o.plugin.id)),v=i((a)=>a.busyIds[o.plugin.id]),T=i((a)=>a.install),H=i((a)=>a.uninstall),V=i((a)=>a.setPluginEnabled),[n,B]=y(null),[D,I]=y(null),[j,R]=y(0),[c,z]=y(null);_(()=>{let a=!0;return I(null),B(null),P(o).then((g)=>{if(a)B(g)},(g)=>{if(a)I(g instanceof Error?g.message:String(g))}),()=>{a=!1}},[o,P,j]);let m=n?.summary??o.plugin,r=C?.plugin??m,t=m.interface,h=t?.displayName??m.name,b=r.availability!=="AVAILABLE"||r.installPolicy==="NOT_AVAILABLE",E=t?.longDescription??n?.description??t?.shortDescription,A=[...u.assetUrl?t?.screenshots.map((a)=>u.assetUrl(a))??[]:[],...t?.screenshotUrls??[]];return s("div",{className:"toolbox-surface flex min-h-0 flex-1 flex-col overflow-hidden",children:[e(_e,{children:s("header",{className:"flex min-w-0 flex-col gap-4",children:[s("nav",{"aria-label":l("plugins.detail.root"),className:"flex min-w-0 items-center gap-2 text-[13px]",children:[e(f,{variant:"link",size:"sm",className:"text-muted-foreground hover:text-foreground px-2 hover:no-underline",onClick:p,children:l("plugins.detail.root")}),e("span",{"aria-hidden":"true",className:"text-muted-foreground/50 text-sm",children:"/"}),e("span",{"aria-current":"page",className:"truncate",children:h})]}),s("div",{className:"flex min-h-9 flex-wrap items-center justify-between gap-4",children:[s("div",{className:"flex min-w-0 items-center gap-3",children:[e(U,{name:m.name,className:"size-9 shrink-0 rounded-lg"}),e("h1",{className:"min-w-0 text-2xl leading-8 font-semibold break-words",children:h})]}),e("div",{className:"flex shrink-0 items-center gap-3",children:C?s(O,{children:[r.source.type==="remote"?null:e(X,{checked:r.enabled,disabled:!!v||b,"aria-label":l(r.enabled?"plugins.card.disable":"plugins.card.enable",{pluginName:h}),onCheckedChange:(a)=>void V(r,a)}),e(f,{variant:"outline",size:"sm",disabled:!!v,onClick:()=>void H(r),children:v?e(S,{}):l("plugins.detail.uninstall")})]}):e(f,{size:"icon-sm",variant:"ghost",className:"text-foreground shrink-0","aria-label":l(b?"plugins.detail.unavailable":"plugins.detail.install"),title:l(b?"plugins.detail.unavailable":"plugins.detail.install"),disabled:!!v||b,onClick:()=>void T({...o,plugin:m}).catch(()=>{}),children:v?e(S,{"aria-hidden":"true"}):e(W,{className:"size-5",strokeWidth:2,"aria-hidden":"true"})})})]})]})}),e(k,{className:"pe-0",viewportClassName:"pe-0",children:s("div",{className:`${Q} pt-2`,children:[t?.shortDescription&&e("p",{className:"text-muted-foreground text-sm leading-6",children:t.shortDescription}),m.keywords.length>0&&e("div",{className:"mt-3 flex flex-wrap gap-2",children:[...new Set(m.keywords)].map((a)=>e(L,{variant:"secondary",className:"text-xs font-normal",children:a},a))}),s("div",{className:"mt-6 flex items-stretch overflow-x-auto border-y py-4",children:[t?.developerName&&e(x,{label:l("plugins.detail.developer"),children:t.developerName}),t?.category&&e(x,{label:l("plugins.detail.category"),children:t.category}),(r.localVersion??r.version)&&e(x,{label:l("plugins.detail.version"),children:r.localVersion??r.version}),e(x,{label:l("plugins.headings.marketplace"),children:o.marketplace.interface?.displayName??o.marketplace.name}),t?.websiteUrl&&e(x,{label:l("plugins.detail.website"),children:e(w,{url:t.websiteUrl,label:l("plugins.detail.website")})})]}),!n&&!D&&s("div",{role:"status",className:"text-muted-foreground mt-8 flex items-center gap-2 text-sm",children:[e(S,{}),l("plugins.detail.loading")]}),D&&s("div",{role:"alert",className:"mt-8 space-y-2",children:[s("p",{className:"text-destructive text-sm",children:[l("plugins.detail.errorTitle"),": ",D]}),e(f,{variant:"outline",size:"sm",className:"h-9",onClick:()=>R((a)=>a+1),children:l("plugins.loadError.retry")})]}),E&&e("p",{className:"mt-8 text-sm leading-6 whitespace-pre-wrap",children:E}),A.length>0&&e("div",{className:"mt-6 flex gap-3 overflow-x-auto",children:[...new Set(A)].map((a)=>e("img",{src:a,alt:h,loading:"lazy",className:"max-h-72 max-w-full rounded-xl border object-contain"},a))}),t&&t.capabilities.length>0&&e(N,{label:l("plugins.detail.capabilities"),count:t.capabilities.length,children:t.capabilities.map((a)=>e(L,{variant:"secondary",className:"me-2",children:a},a))}),n&&n.mcpServers.length>0&&e(N,{label:l("plugins.detail.mcpServers"),count:n.mcpServers.length,children:n.mcpServers.map((a)=>s("div",{className:"flex items-center gap-3 py-1",children:[e(U,{name:m.name,className:"size-6 rounded-md"}),e("span",{className:"text-sm font-medium",children:a})]},a))}),n&&n.skills.length>0&&e(N,{label:l("plugins.detail.skills"),count:n.skills.length,children:n.skills.map((a)=>s(f,{variant:"ghost",className:"h-auto w-full justify-start gap-3 rounded-xl px-3 py-3 text-start whitespace-normal",onClick:()=>z(a),children:[e(U,{name:a.name,className:"size-8"}),s("span",{className:"min-w-0 flex-1",children:[e("span",{className:"block text-sm font-medium",children:a.interface?.displayName??a.name}),e("span",{className:"text-muted-foreground mt-1 block truncate text-[13px] leading-5 font-normal",children:a.interface?.shortDescription??a.shortDescription??a.description})]})]},a.path??a.name))}),n&&n.apps.length>0&&e(N,{label:l("plugins.detail.apps"),count:n.apps.length,children:n.apps.map((a)=>s("div",{className:"rounded-xl px-3 py-3",children:[e("div",{className:"text-sm font-medium",children:a.name}),a.description&&e("p",{className:"text-muted-foreground mt-1 text-[13px] leading-5",children:a.description}),a.installUrl&&e(w,{url:a.installUrl,label:l("plugins.installModal.connect")})]},a.id))}),n&&n.hooks.length>0&&e(N,{label:l("plugins.detail.hooks"),count:n.hooks.length,children:n.hooks.map((a)=>e("p",{className:"text-sm",children:a.eventName},a.key))}),(t?.privacyPolicyUrl||t?.termsOfServiceUrl)&&s("div",{className:"mt-10 flex flex-wrap gap-4 border-t pt-4",children:[t.privacyPolicyUrl&&e(w,{url:t.privacyPolicyUrl,label:l("plugins.detail.privacyPolicy")}),t.termsOfServiceUrl&&e(w,{url:t.termsOfServiceUrl,label:l("plugins.detail.termsOfService")})]})]})}),e(q,{open:c!==null,onOpenChange:(a)=>{if(!a)z(null)},children:e(F,{className:Se,children:c&&s(O,{children:[e("div",{className:"shrink-0 pr-8",children:e(U,{name:c.name,className:"size-10"})}),s("div",{className:"min-h-0 space-y-6 overflow-y-auto overscroll-contain",children:[s(J,{className:"gap-3",children:[e(K,{className:"text-2xl leading-8 font-semibold break-words",children:c.interface?.displayName??c.name}),e(G,{className:"text-sm leading-6 break-words whitespace-pre-wrap",children:c.description})]}),e(ke,{path:c.path,description:c.description},c.path??c.name)]})]})})})]})}function x({label:o,children:p}){return s("div",{className:"flex min-w-28 shrink-0 flex-col items-center justify-between gap-1.5 border-e px-6 first:ps-2 last:border-e-0",children:[e("span",{className:"text-muted-foreground text-xs",children:o}),e("span",{className:"flex items-center text-sm font-normal",children:p})]})}function N({label:o,count:p,children:u}){return s("section",{className:"mt-8",children:[s("h2",{className:"text-base font-medium",children:[o," ",e("span",{className:"text-muted-foreground font-normal",children:p})]}),e("div",{className:"mt-3 flex flex-col gap-2",children:u})]})}function w({url:o,label:p}){let{openLink:u}=d();if(!/^https?:\/\//i.test(o))return null;return s(f,{variant:"link",className:"text-muted-foreground h-auto p-0 text-xs",title:o,onClick:()=>u(o),children:[p,e(M,{className:"size-3.5"})]})}
2
- export{qt};
1
+ import{d,i}from"./chunk-qvzxzzw8.js";import{S}from"./chunk-mhrn3e8j.js";import{U}from"./chunk-3sq2k9ca.js";import{Ie}from"./chunk-gmns080g.js";import{Q,Pe,Te}from"./chunk-3knw8e0x.js";import{ExternalLinkIcon as M,PlusIcon as W}from"lucide-react";import{useEffect as _,useState as k}from"react";import{Badge as L}from"@nyssance/shadcn/vega/components/ui/badge";import{Button as f}from"@nyssance/shadcn/vega/components/ui/button";import{Dialog as q,DialogContent as F,DialogDescription as G,DialogHeader as J,DialogTitle as K}from"@nyssance/shadcn/vega/components/ui/dialog";import{Spinner as D}from"@nyssance/shadcn/vega/components/ui/spinner";import{Switch as X}from"@nyssance/shadcn/vega/components/ui/switch";import{jsx as e,jsxs as s,Fragment as O}from"react/jsx-runtime";function Jt({entry:o,onBack:p}){let u=d(),{t:l}=u,P=i((a)=>a.readPlugin),C=i((a)=>a.installed.find(({plugin:g})=>g.id===o.plugin.id)),v=i((a)=>a.busyIds[o.plugin.id]),T=i((a)=>a.install),H=i((a)=>a.uninstall),V=i((a)=>a.setPluginEnabled),[n,B]=k(null),[w,I]=k(null),[j,R]=k(0),[c,z]=k(null);_(()=>{let a=!0;return I(null),B(null),P(o).then((g)=>{if(a)B(g)},(g)=>{if(a)I(g instanceof Error?g.message:String(g))}),()=>{a=!1}},[o,P,j]);let m=n?.summary??o.plugin,r=C?.plugin??m,t=m.interface,h=t?.displayName??m.name,b=r.availability!=="AVAILABLE"||r.installPolicy==="NOT_AVAILABLE",E=t?.longDescription??n?.description??t?.shortDescription,A=[...u.assetUrl?t?.screenshots.map((a)=>u.assetUrl(a))??[]:[],...t?.screenshotUrls??[]];return s("div",{className:"toolbox-surface flex min-h-0 flex-1 flex-col overflow-hidden",children:[e(Te,{children:s("header",{className:"flex min-w-0 flex-col gap-4",children:[s("nav",{"aria-label":l("plugins.detail.root"),className:"flex min-w-0 items-center gap-2 text-[13px]",children:[e(f,{variant:"link",size:"sm",className:"text-muted-foreground hover:text-foreground px-2 hover:no-underline",onClick:p,children:l("plugins.detail.root")}),e("span",{"aria-hidden":"true",className:"text-muted-foreground/50 text-sm",children:"/"}),e("span",{"aria-current":"page",className:"truncate",children:h})]}),s("div",{className:"flex min-h-9 flex-wrap items-center justify-between gap-4",children:[s("div",{className:"flex min-w-0 items-center gap-3",children:[e(U,{name:m.name,className:"size-9 shrink-0 rounded-lg"}),e("h1",{className:"min-w-0 text-2xl leading-8 font-semibold break-words",children:h})]}),e("div",{className:"flex shrink-0 items-center gap-3",children:C?s(O,{children:[r.source.type==="remote"?null:e(X,{checked:r.enabled,disabled:!!v||b,"aria-label":l(r.enabled?"plugins.card.disable":"plugins.card.enable",{pluginName:h}),onCheckedChange:(a)=>void V(r,a)}),e(f,{variant:"outline",size:"sm",disabled:!!v,onClick:()=>void H(r),children:v?e(D,{}):l("plugins.detail.uninstall")})]}):e(f,{size:"icon-sm",variant:"ghost",className:"text-foreground shrink-0","aria-label":l(b?"plugins.detail.unavailable":"plugins.detail.install"),title:l(b?"plugins.detail.unavailable":"plugins.detail.install"),disabled:!!v||b,onClick:()=>void T({...o,plugin:m}).catch(()=>{}),children:v?e(D,{"aria-hidden":"true"}):e(W,{className:"size-5",strokeWidth:2,"aria-hidden":"true"})})})]})]})}),e(S,{className:"pe-0",viewportClassName:"pe-0",children:s("div",{className:`${Q} pt-2`,children:[t?.shortDescription&&e("p",{className:"text-muted-foreground text-sm leading-6",children:t.shortDescription}),m.keywords.length>0&&e("div",{className:"mt-3 flex flex-wrap gap-2",children:[...new Set(m.keywords)].map((a)=>e(L,{variant:"secondary",className:"text-xs font-normal",children:a},a))}),s("div",{className:"mt-6 flex items-stretch overflow-x-auto border-y py-4",children:[t?.developerName&&e(x,{label:l("plugins.detail.developer"),children:t.developerName}),t?.category&&e(x,{label:l("plugins.detail.category"),children:t.category}),(r.localVersion??r.version)&&e(x,{label:l("plugins.detail.version"),children:r.localVersion??r.version}),e(x,{label:l("plugins.headings.marketplace"),children:o.marketplace.interface?.displayName??o.marketplace.name}),t?.websiteUrl&&e(x,{label:l("plugins.detail.website"),children:e(y,{url:t.websiteUrl,label:l("plugins.detail.website")})})]}),!n&&!w&&s("div",{role:"status",className:"text-muted-foreground mt-8 flex items-center gap-2 text-sm",children:[e(D,{}),l("plugins.detail.loading")]}),w&&s("div",{role:"alert",className:"mt-8 space-y-2",children:[s("p",{className:"text-destructive text-sm",children:[l("plugins.detail.errorTitle"),": ",w]}),e(f,{variant:"outline",size:"sm",className:"h-9",onClick:()=>R((a)=>a+1),children:l("plugins.loadError.retry")})]}),E&&e("p",{className:"mt-8 text-sm leading-6 whitespace-pre-wrap",children:E}),A.length>0&&e("div",{className:"mt-6 flex gap-3 overflow-x-auto",children:[...new Set(A)].map((a)=>e("img",{src:a,alt:h,loading:"lazy",className:"max-h-72 max-w-full rounded-xl border object-contain"},a))}),t&&t.capabilities.length>0&&e(N,{label:l("plugins.detail.capabilities"),count:t.capabilities.length,children:t.capabilities.map((a)=>e(L,{variant:"secondary",className:"me-2",children:a},a))}),n&&n.mcpServers.length>0&&e(N,{label:l("plugins.detail.mcpServers"),count:n.mcpServers.length,children:n.mcpServers.map((a)=>s("div",{className:"flex items-center gap-3 py-1",children:[e(U,{name:m.name,className:"size-6 rounded-md"}),e("span",{className:"text-sm font-medium",children:a})]},a))}),n&&n.skills.length>0&&e(N,{label:l("plugins.detail.skills"),count:n.skills.length,children:n.skills.map((a)=>s(f,{variant:"ghost",className:"h-auto w-full justify-start gap-3 rounded-xl px-3 py-3 text-start whitespace-normal",onClick:()=>z(a),children:[e(U,{name:a.name,className:"size-8"}),s("span",{className:"min-w-0 flex-1",children:[e("span",{className:"block text-sm font-medium",children:a.interface?.displayName??a.name}),e("span",{className:"text-muted-foreground mt-1 block truncate text-[13px] leading-5 font-normal",children:a.interface?.shortDescription??a.shortDescription??a.description})]})]},a.path??a.name))}),n&&n.apps.length>0&&e(N,{label:l("plugins.detail.apps"),count:n.apps.length,children:n.apps.map((a)=>s("div",{className:"rounded-xl px-3 py-3",children:[e("div",{className:"text-sm font-medium",children:a.name}),a.description&&e("p",{className:"text-muted-foreground mt-1 text-[13px] leading-5",children:a.description}),a.installUrl&&e(y,{url:a.installUrl,label:l("plugins.installModal.connect")})]},a.id))}),n&&n.hooks.length>0&&e(N,{label:l("plugins.detail.hooks"),count:n.hooks.length,children:n.hooks.map((a)=>e("p",{className:"text-sm",children:a.eventName},a.key))}),(t?.privacyPolicyUrl||t?.termsOfServiceUrl)&&s("div",{className:"mt-10 flex flex-wrap gap-4 border-t pt-4",children:[t.privacyPolicyUrl&&e(y,{url:t.privacyPolicyUrl,label:l("plugins.detail.privacyPolicy")}),t.termsOfServiceUrl&&e(y,{url:t.termsOfServiceUrl,label:l("plugins.detail.termsOfService")})]})]})}),e(q,{open:c!==null,onOpenChange:(a)=>{if(!a)z(null)},children:e(F,{className:Pe,children:c&&s(O,{children:[e("div",{className:"shrink-0 pr-8",children:e(U,{name:c.name,className:"size-10"})}),s("div",{className:"min-h-0 space-y-6 overflow-y-auto overscroll-contain",children:[s(J,{className:"gap-3",children:[e(K,{className:"text-2xl leading-8 font-semibold break-words",children:c.interface?.displayName??c.name}),e(G,{className:"text-sm leading-6 break-words whitespace-pre-wrap",children:c.description})]}),e(Ie,{path:c.path,description:c.description},c.path??c.name)]})]})})})]})}function x({label:o,children:p}){return s("div",{className:"flex min-w-28 shrink-0 flex-col items-center justify-between gap-1.5 border-e px-6 first:ps-2 last:border-e-0",children:[e("span",{className:"text-muted-foreground text-xs",children:o}),e("span",{className:"flex items-center text-sm font-normal",children:p})]})}function N({label:o,count:p,children:u}){return s("section",{className:"mt-8",children:[s("h2",{className:"text-base font-medium",children:[o," ",e("span",{className:"text-muted-foreground font-normal",children:p})]}),e("div",{className:"mt-3 flex flex-col gap-2",children:u})]})}function y({url:o,label:p}){let{openLink:u}=d();if(!/^https?:\/\//i.test(o))return null;return s(f,{variant:"link",className:"text-muted-foreground h-auto p-0 text-xs",title:o,onClick:()=>u(o),children:[p,e(M,{className:"size-3.5"})]})}
2
+ export{Jt};
@@ -1,2 +1,2 @@
1
- import{fromMcpServer as u}from"@agentclientprotocol/sdk/experimental/mcp-server";import{Server as g}from"@modelcontextprotocol/server";function Fn(e){let{parse:o,execute:t,...s}=e;return{...s,execute:(n,i)=>t(o(n),i)}}var po="alwith";function m(e){if(e.length>128)throw Error("Too many application tools");let o=new Map;for(let t of e){if(!/^[a-zA-Z][a-zA-Z0-9_]{0,49}$/.test(t.name)||o.has(t.name))throw Error(`Invalid or duplicate application tool: ${t.name}`);if(!t.description.trim()||t.inputSchema.type!=="object")throw Error(`Invalid application tool definition: ${t.name}`);o.set(t.name,{...t,inputSchema:structuredClone(t.inputSchema)})}return o}var p=(e)=>({content:[{type:"text",text:e instanceof Error?e.message:String(e)}],isError:!0});class mo{servers=new Map;session;identity;constructor(e,o){this.session=e,this.identity=o}declare(e,o){let t={agent:e,tools:m(o),sessionId:null};return t.mcp=u(()=>this.server(t)),t.registration=e.registerMcpServer({name:po,handler:t.mcp.handler}),this.servers.set(t.registration.serverId,t),t.registration.declaration}bind(e,o){let t=this.servers.get(e);if(!t)throw Error(`Application tool server is not registered: ${e}`);for(let[s,n]of this.servers)if(n.sessionId===o)this.dispose(s);t.sessionId=o}drop(e){for(let[o,t]of this.servers)if(t.sessionId===e)this.dispose(o)}clear(){for(let e of this.servers.keys())this.dispose(e)}dispose(e){let o=this.servers.get(e);if(!o)return;this.servers.delete(e),o.registration.dispose().then(()=>o.mcp.close())}server(e){let o=new g({name:po,version:"1.0.0"},{capabilities:{tools:{}}});return o.setRequestHandler("tools/list",()=>({tools:[...e.tools.values()].map((t)=>({name:t.name,...t.title===void 0?{}:{title:t.title},description:t.description,inputSchema:structuredClone(t.inputSchema),...t.annotations===void 0?{}:{annotations:t.annotations}}))})),o.setRequestHandler("tools/call",async(t,s)=>{let n=e.tools.get(t.params.name);if(!n)return p(Error(`Application tool is not registered: ${t.params.name}`));let i=e.sessionId,l=i===null?void 0:this.session(i);if(i===null||!l?.attached||l.readOnly)return p(Error("Application tool session is not attached"));let{toolCallId:c,turnId:d}=this.identity(t.params._meta??{}),a=s.mcpReq.signal;try{let r=await n.execute(t.params.arguments??{},{sessionId:i,toolCallId:c,turnId:d,signal:a,agent:e.agent});return a.throwIfAborted(),r}catch(r){if(a.aborted)throw r;return p(r)}}),o}}
2
- export{Fn,po,mo};
1
+ import{fromMcpServer as u}from"@agentclientprotocol/sdk/experimental/mcp-server";import{Server as g}from"@modelcontextprotocol/server";function Gn(e){let{parse:o,execute:t,...s}=e;return{...s,execute:(n,i)=>t(o(n),i)}}var vo="alwith";function m(e){if(e.length>128)throw Error("Too many application tools");let o=new Map;for(let t of e){if(!/^[a-zA-Z][a-zA-Z0-9_]{0,49}$/.test(t.name)||o.has(t.name))throw Error(`Invalid or duplicate application tool: ${t.name}`);if(!t.description.trim()||t.inputSchema.type!=="object")throw Error(`Invalid application tool definition: ${t.name}`);o.set(t.name,{...t,inputSchema:structuredClone(t.inputSchema)})}return o}var p=(e)=>({content:[{type:"text",text:e instanceof Error?e.message:String(e)}],isError:!0});class yo{servers=new Map;session;identity;constructor(e,o){this.session=e,this.identity=o}declare(e,o){let t={agent:e,tools:m(o),sessionId:null};return t.mcp=u(()=>this.server(t)),t.registration=e.registerMcpServer({name:vo,handler:t.mcp.handler}),this.servers.set(t.registration.serverId,t),t.registration.declaration}bind(e,o){let t=this.servers.get(e);if(!t)throw Error(`Application tool server is not registered: ${e}`);for(let[s,n]of this.servers)if(n.sessionId===o)this.dispose(s);t.sessionId=o}drop(e){for(let[o,t]of this.servers)if(t.sessionId===e)this.dispose(o)}clear(){for(let e of this.servers.keys())this.dispose(e)}dispose(e){let o=this.servers.get(e);if(!o)return;this.servers.delete(e),o.registration.dispose().then(()=>o.mcp.close())}server(e){let o=new g({name:vo,version:"1.0.0"},{capabilities:{tools:{}}});return o.setRequestHandler("tools/list",()=>({tools:[...e.tools.values()].map((t)=>({name:t.name,...t.title===void 0?{}:{title:t.title},description:t.description,inputSchema:structuredClone(t.inputSchema),...t.annotations===void 0?{}:{annotations:t.annotations}}))})),o.setRequestHandler("tools/call",async(t,s)=>{let n=e.tools.get(t.params.name);if(!n)return p(Error(`Application tool is not registered: ${t.params.name}`));let i=e.sessionId,l=i===null?void 0:this.session(i);if(i===null||!l?.attached||l.readOnly)return p(Error("Application tool session is not attached"));let{toolCallId:c,turnId:d}=this.identity(t.params._meta??{}),a=s.mcpReq.signal;try{let r=await n.execute(t.params.arguments??{},{sessionId:i,toolCallId:c,turnId:d,signal:a,agent:e.agent});return a.throwIfAborted(),r}catch(r){if(a.aborted)throw r;return p(r)}}),o}}
2
+ export{Gn,vo,yo};
@@ -1,2 +1,2 @@
1
- import{G}from"./chunk-h4xx90s4.js";import{Button as u}from"@nyssance/shadcn/vega/components/ui/button";import{DropdownMenu as d,DropdownMenuContent as m,DropdownMenuGroup as w,DropdownMenuItem as i,DropdownMenuLabel as S,DropdownMenuTrigger as c}from"@nyssance/shadcn/vega/components/ui/dropdown-menu";import{jsx as e,jsxs as a}from"react/jsx-runtime";var M=["requires_action","running","done","idle"];function Os({sessions:l,onSelect:p,t:n}){return e("div",{className:"flex shrink-0 items-center gap-0.5",role:"group","aria-label":n("sessionList.states.title"),children:M.map((o)=>{let s=l.filter((t)=>t.state===o),r=n(`sessionList.states.${o}`);return a(d,{children:[a(c,{render:e(u,{variant:"ghost",size:"xs"}),"aria-label":`${r}: ${s.length}`,children:[e(G,{state:o,pulse:!1}),e("span",{className:"tabular-nums",children:s.length})]}),e(m,{"aria-label":r,className:"w-72 max-w-[calc(100vw-1rem)]",children:a(w,{children:[e(S,{children:r}),s.length===0?e(i,{disabled:!0,children:n("sessionList.states.empty")}):s.map((t)=>a(i,{onClick:()=>p(t),children:[e(G,{state:t.state,pulse:!1}),e("span",{className:"min-w-0 flex-1 truncate",children:t.title||n("sessionList.untitled")})]},t.sessionId))]})})]},o)})})}
2
- export{Os};
1
+ import{G}from"./chunk-rxj5619b.js";import{Button as u}from"@nyssance/shadcn/vega/components/ui/button";import{DropdownMenu as d,DropdownMenuContent as m,DropdownMenuGroup as w,DropdownMenuItem as i,DropdownMenuLabel as S,DropdownMenuTrigger as c}from"@nyssance/shadcn/vega/components/ui/dropdown-menu";import{jsx as e,jsxs as a}from"react/jsx-runtime";var M=["requires_action","running","done","idle"];function zs({sessions:l,onSelect:p,t:n}){return e("div",{className:"flex shrink-0 items-center gap-0.5",role:"group","aria-label":n("sessionList.states.title"),children:M.map((o)=>{let s=l.filter((t)=>t.state===o),r=n(`sessionList.states.${o}`);return a(d,{children:[a(c,{render:e(u,{variant:"ghost",size:"xs"}),"aria-label":`${r}: ${s.length}`,children:[e(G,{state:o,pulse:!1}),e("span",{className:"tabular-nums",children:s.length})]}),e(m,{"aria-label":r,className:"w-72 max-w-[calc(100vw-1rem)]",children:a(w,{children:[e(S,{children:r}),s.length===0?e(i,{disabled:!0,children:n("sessionList.states.empty")}):s.map((t)=>a(i,{onClick:()=>p(t),children:[e(G,{state:t.state,pulse:!1}),e("span",{className:"min-w-0 flex-1 truncate",children:t.title||n("sessionList.untitled")})]},t.sessionId))]})})]},o)})})}
2
+ export{zs};
@@ -1,2 +1,2 @@
1
- import{a,o}from"./chunk-0b50jg23.js";import{QUICK_CHATS_GROUP as m,sessionGroup as l}from"@nyssance/codex-acp-v2/client";import{useEffect as S,useMemo as L}from"react";function Hs(i){let t=a(),e=o((s)=>s.projectContext),c=i===null?m:e?l(e,{cwd:t.projectPath(i)}).id:null,u=o((s)=>s.sessionList),d=o((s)=>s.connection),r=o((s)=>s.sessionListLoaded),n=o((s)=>s.sessionListError),f=()=>t.listSessions({reset:!0}).catch(()=>{return});return S(()=>{if(d==="ready"&&!r&&n===null)t.listSessions().catch(()=>{return})},[t,d,r,n]),{result:L(()=>{if(r&&e)return{status:"ready",sessionRows:u.filter((s)=>l(e,{...s,cwd:t.projectPath(s.cwd)}).id===c).toSorted((s,p)=>(p.updatedAt??"").localeCompare(s.updatedAt??""))};if(n!==null)return{status:"failed",error:n};return{status:"loading"}},[t,u,r,n,c,e]),retry:f}}
2
- export{Hs};
1
+ import{a,o}from"./chunk-pxbww0j1.js";import{QUICK_CHATS_GROUP as m,sessionGroup as l}from"@nyssance/codex-acp-v2/client";import{useEffect as S,useMemo as L}from"react";function Vs(i){let t=a(),e=o((s)=>s.projectContext),c=i===null?m:e?l(e,{cwd:t.projectPath(i)}).id:null,u=o((s)=>s.sessionList),d=o((s)=>s.connection),r=o((s)=>s.sessionListLoaded),n=o((s)=>s.sessionListError),f=()=>t.listSessions({reset:!0}).catch(()=>{return});return S(()=>{if(d==="ready"&&!r&&n===null)t.listSessions().catch(()=>{return})},[t,d,r,n]),{result:L(()=>{if(r&&e)return{status:"ready",sessionRows:u.filter((s)=>l(e,{...s,cwd:t.projectPath(s.cwd)}).id===c).toSorted((s,p)=>(p.updatedAt??"").localeCompare(s.updatedAt??""))};if(n!==null)return{status:"failed",error:n};return{status:"loading"}},[t,u,r,n,c,e]),retry:f}}
2
+ export{Vs};
@@ -1,2 +1,2 @@
1
- import{jr}from"./chunk-9x70f7zv.js";import{useCallback as xe,useEffect as P,useLayoutEffect as ye,useMemo as X,useRef as I,useState as E}from"react";import"@alwith/module-chat/navigation-rail.css";import{jsx as T,jsxs as Ne,Fragment as ke}from"react/jsx-runtime";var Se=4,ge=10;function we(h,x){let v=new Map(x.flatMap((c)=>c.itemIds.map((S)=>[S,c.key]))),p=Array(h.length),C;for(let c=h.length-1;c>=0;c--)C=v.get(h[c])??C,p[c]=C;let A=Math.max(-1,...x.map((c)=>c.key))+1,B=new Set,n=[];for(let[c,S]of h.entries()){let w=v.get(S),m=n.at(-1);if(!m||w!==void 0&&w!==m.key||w===void 0&&m.itemIds.length>=64&&p[c]!==m.key){let y=w!==void 0&&!B.has(w)?w:A++;m={key:y,startIndex:c,itemIds:[]},n.push(m),B.add(y)}m.itemIds.push(S)}return n}function fe(h,x){if(h.size!==x.size)return!1;for(let v of h)if(!x.has(v))return!1;return!0}function Gr({audio:h,beforeReveal:x,ensureItemMounted:v,items:p,onPreviewItem:C,renderPreview:A,onRevealError:B,scrollRoot:n,targetTopMarginPx:c=16}){let[S,w]=E(()=>{let e=p.at(-1);return new Set(e===void 0?[]:[e.id])}),[m,y]=E(null),[_,O]=E(null),[Z,R]=E(!1),[j,pe]=E(()=>new Set),[ve,be]=E(!0),[Ie,F]=E(null),{installUnlock:ee,preload:te,playSequence:ne}=h,K=I(null),M=I(null),U=I(!1),H=I(null),L=I(0),G=I(null),k=I(null),V=I(new Set),z=X(()=>p.map((e)=>e.id).join("\x00"),[p]),J=I(p);J.current=p;let ie=I(j),re=I(S),se=I({itemIdsKey:z,scrollRoot:n});if(se.current.scrollRoot!==n)L.current+=1,se.current={itemIdsKey:z,scrollRoot:n};let g=X(()=>v===void 0?p.filter((e)=>j.has(e.id)):p,[v,p,j]),ae=X(()=>g.map((e)=>({inputTokens:e.inputTokens,outputTokens:e.outputTokens})),[g]),D=I({ids:"",groups:[]}),oe=g.map((e)=>e.id).join("\x00");if(D.current.ids!==oe)D.current={ids:oe,groups:we(g.map((e)=>e.id),D.current.groups)};P(()=>ee(),[ee]),P(()=>()=>{if(L.current+=1,G.current?.cancel(),k.current!==null)clearTimeout(k.current)},[]),P(()=>{y(null),R(!1),O(null),M.current=null,U.current=!1,H.current=null,F(null),V.current.clear()},[n]),P(()=>{te()},[te]),P(()=>{if(n===null)return;let e=new Set,t=new Map,i=new Set(J.current.map((s)=>s.id)),r=()=>{let s=new Set(t.values()),d=J.current.filter((f)=>s.has(f.id)).map((f)=>f.id),o=d.findIndex((f)=>e.has(f));if(o===-1)return;let b=o;for(let f=o+1;f<d.length;f++)if(e.has(d[f]))b=f;let N=new Set(d.slice(o,b+1));if(fe(re.current,N))return;re.current=N,w(N)},a=new IntersectionObserver((s)=>{for(let d of s){let o=t.get(d.target);if(d.isIntersecting)e.add(o);else e.delete(o)}r()},{root:n,rootMargin:`-${c}px 0px 0px 0px`}),u=()=>{let s=new Set,d=new Set;for(let o of n.querySelectorAll("[data-content-search-unit-key]")){let b=o.dataset.contentSearchUnitKey;if(b===void 0||!i.has(b)||s.has(b))continue;s.add(b);let N=o.closest("[data-turn-key]"),f=N===null||d.has(N)?o:N;if(d.add(f),t.has(f))continue;t.set(f,b),a.observe(f)}for(let o of t.keys()){if(d.has(o))continue;a.unobserve(o),e.delete(t.get(o)),t.delete(o)}if(r(),fe(ie.current,s))return;ie.current=s,pe(s)};u();let l=new MutationObserver((s)=>{if(s.some((o)=>[...o.addedNodes,...o.removedNodes].some((b)=>b instanceof Element&&(b.matches("[data-turn-key], [data-content-search-unit-key]")||b.querySelector("[data-turn-key], [data-content-search-unit-key]")!==null))))u()});return l.observe(n,{childList:!0,subtree:!0}),()=>{l.disconnect(),a.disconnect()}},[z,n,c]);let Y=g.find((e)=>S.has(e.id))?.id??g.at(-1)?.id;ye(()=>{let e=K.current;if(e===null||M.current!==null||Y===void 0)return;let t=e.querySelector(`[data-timeline-user-message-navigation-item-id="${CSS.escape(Y)}"]`);if(t===null)return;let i=e.getBoundingClientRect(),r=t.getBoundingClientRect();if(r.top<i.top)e.scrollTop+=r.top-i.top;else if(r.bottom>i.bottom)e.scrollTop+=r.bottom-i.bottom+1},[Y,z]),P(()=>{let e=n?.querySelector("[data-timeline-user-message-navigation-content]");if(!n||!e)return;let t=()=>{let r=n.getBoundingClientRect(),a=e.getBoundingClientRect();if(r.width===0||a.width===0)return;let u=n.offsetWidth>0?r.width/n.offsetWidth:1;be((a.left-r.left)/u>=48)},i=new ResizeObserver(t);return i.observe(n),i.observe(e),t(),()=>i.disconnect()},[n]);let he=xe(async(e,t="smooth")=>{if(n===null)throw Error("Thread user-message navigation scroll root is missing");let i=L.current+1;L.current=i,x();let r=()=>n.querySelector(`[data-content-search-unit-key="${CSS.escape(e.id)}"]`),a=r(),u=a!==null&&n.clientHeight>0&&a.closest("[data-turn-key]")!==null&&Math.abs(a.getBoundingClientRect().top-n.getBoundingClientRect().top)>n.clientHeight*2;if((a===null||u)&&v!==void 0){if(t==="instant"&&e.isLoaded===!1)return;a=await v(e,()=>L.current===i)??r(),t="instant"}if(L.current!==i)return;if(a===null)return;let l=window.matchMedia?.("(prefers-reduced-motion: reduce)").matches;a.scrollIntoView({behavior:l?"instant":t,block:"start"});let s=a.querySelector("[data-user-message-bubble], [data-composer-attachment-pill]");if(G.current?.cancel(),G.current=null,s===null)return;let d=getComputedStyle(s).backgroundColor,o=`color-mix(in srgb, var(--foreground) 14%, ${d})`;G.current=s.animate?.([{backgroundColor:o},{backgroundColor:o,offset:0.35},{backgroundColor:d}],{duration:l?0:1000,easing:"cubic-bezier(0.23, 1, 0.32, 1)"})??null},[x,v,n]);if(g.length<Se||!ve)return null;let Q=()=>{if(k.current!==null)clearTimeout(k.current);k.current=null},ue=(e,t=!1)=>{if(Q(),C===void 0||e.isLoaded!==!1||V.current.has(e.turnKey))return;let i=()=>{k.current=null,V.current.add(e.turnKey),C(e).catch(()=>V.current.delete(e.turnKey))};if(t)i();else k.current=setTimeout(i,150)},q=m===null?null:g.find((e)=>e.id===m.item.id)??g.find((e)=>e.nativeTurnId!==void 0&&e.nativeTurnId===m.item.nativeTurnId)??m.item,le=(e,t="smooth")=>{he(e,t).catch((i)=>{if(B)B(i);else throw i})},de=g.findIndex((e)=>e.id===(_??Ie)),ce=K.current,Te=m===null||!ce?.contains(m.button)?0:Me(ce,m.button),me=(e)=>{let t=e?.closest("[data-timeline-user-message-navigation-item-id]"),i=K.current;if(t===void 0||t===null||!i.contains(t))return null;let r=t.dataset.timelineUserMessageNavigationItemId,a=g.findIndex((u)=>u.id===r);return{button:t,item:g[a],index:a}},W=(e)=>{let t=M.current;if(t?.pointerId!==e.pointerId)return;if(M.current=null,O(null),t.captureTarget.hasPointerCapture(e.pointerId))t.captureTarget.releasePointerCapture(e.pointerId)};return T("nav",{"aria-label":"User messages",className:"timeline-user-message-navigation absolute start-4 top-1/2 z-20 -translate-y-1/2",children:T(jr,{open:Z,onOpenChange:R,side:"inline-end",sideOffset:0,align:"center",alignOffset:Te,trigger:T("div",{ref:K,"data-timeline-user-message-navigation-rail-list":!0,"data-scrubbing":_===null?void 0:"",className:"timeline-user-message-navigation-rail-list",onPointerEnter:()=>{H.current=null},onPointerDown:(e)=>{if(e.button!==0)return;Q();let t=me(e.target instanceof Element?e.target:null);if(t===null)return;U.current=!1,M.current={pointerId:e.pointerId,itemId:t.item.id,itemIndex:t.index,captureTarget:t.button},t.button.setPointerCapture(e.pointerId),O(t.item.id),y(t),R(!0)},onPointerMove:(e)=>{let t=M.current;if(t===null){let l=me(e.target instanceof Element?e.target:null);if(l!==null){F(l.item.id);let s=H.current;if(s!==null&&s!==l.index)ne(s,l.index,ae);H.current=l.index,y((d)=>d?.item.id===l.item.id?d:l),ue(l.item)}return}if(t.pointerId!==e.pointerId)return;if((e.buttons&1)===0){W(e);return}let i=e.currentTarget.getBoundingClientRect(),r=Math.max(0,Math.min(g.length-1,Math.floor((e.clientY-i.top+e.currentTarget.scrollTop)/ge))),u={button:e.currentTarget.querySelectorAll("[data-timeline-user-message-navigation-item-id]")[r],item:g[r],index:r};if(u.item.id===t.itemId)return;ne(t.itemIndex,u.index,ae),H.current=u.index,M.current={...t,itemId:u.item.id,itemIndex:u.index},U.current=!0,O(u.item.id),y(u),le(u.item,"instant")},onPointerUp:W,onPointerCancel:W,onLostPointerCapture:W,onPointerLeave:()=>{if(Q(),F(null),H.current=null,M.current===null&&!Z)y(null)},children:T("div",{className:"flex flex-col",children:D.current.groups.map((e)=>T("div",{className:"flex w-9 shrink-0 flex-col [content-visibility:auto]",style:{height:e.itemIds.length*ge},children:g.slice(e.startIndex,e.startIndex+e.itemIds.length).map((t,i)=>{let r=e.startIndex+i,a=Math.abs(r-de),u=de===-1||a>3?void 0:[1,0.7,0.4,0.2][a];return T("button",{type:"button","data-timeline-user-message-navigation-item-id":t.id,"data-scrub-target":_===t.id?"":void 0,"aria-current":S.has(t.id)?"true":void 0,"aria-label":`Jump to user message ${r+1}`,className:"timeline-user-message-navigation-row",onClick:(l)=>{if(U.current){U.current=!1;return}let s={button:l.currentTarget,item:t,index:r};y(s),R(!0),le(t)},onFocus:(l)=>{ue(t,!0),y({button:l.currentTarget,item:t,index:r}),R(!0)},children:T("span",{className:"flex h-0.5 w-[30px] items-center",children:T("span",{className:"timeline-user-message-navigation-marker",style:u===void 0?void 0:{"--marker-progress":u}})})},t.id)})},e.key))})}),children:q!==null&&T("div",{className:"bg-popover/95 text-popover-foreground ring-border w-80 max-w-[calc(100vw-1rem)] overflow-hidden rounded-xl p-2 text-sm leading-5 shadow-xl ring-[0.5px] backdrop-blur-sm",children:A?A(q):Ne(ke,{children:[T("div",{className:"min-w-0 truncate font-medium",children:q.label}),q.response.length>0&&T("div",{className:"text-muted-foreground mt-1 line-clamp-3",children:q.response})]})})})})}function Me(h,x){let v=h.getBoundingClientRect(),p=x.getBoundingClientRect();return p.top+p.height/2-(v.top+v.height/2)}
2
- export{Gr};
1
+ import{Rr}from"./chunk-n4rep234.js";import{useCallback as xe,useEffect as P,useLayoutEffect as ye,useMemo as X,useRef as I,useState as E}from"react";import"@alwith/module-chat/navigation-rail.css";import{jsx as T,jsxs as Ne,Fragment as ke}from"react/jsx-runtime";var Se=4,ge=10;function we(h,x){let v=new Map(x.flatMap((c)=>c.itemIds.map((S)=>[S,c.key]))),p=Array(h.length),C;for(let c=h.length-1;c>=0;c--)C=v.get(h[c])??C,p[c]=C;let A=Math.max(-1,...x.map((c)=>c.key))+1,B=new Set,n=[];for(let[c,S]of h.entries()){let w=v.get(S),m=n.at(-1);if(!m||w!==void 0&&w!==m.key||w===void 0&&m.itemIds.length>=64&&p[c]!==m.key){let y=w!==void 0&&!B.has(w)?w:A++;m={key:y,startIndex:c,itemIds:[]},n.push(m),B.add(y)}m.itemIds.push(S)}return n}function fe(h,x){if(h.size!==x.size)return!1;for(let v of h)if(!x.has(v))return!1;return!0}function Mr({audio:h,beforeReveal:x,ensureItemMounted:v,items:p,onPreviewItem:C,renderPreview:A,onRevealError:B,scrollRoot:n,targetTopMarginPx:c=16}){let[S,w]=E(()=>{let e=p.at(-1);return new Set(e===void 0?[]:[e.id])}),[m,y]=E(null),[_,O]=E(null),[Z,R]=E(!1),[j,pe]=E(()=>new Set),[ve,be]=E(!0),[Ie,F]=E(null),{installUnlock:ee,preload:te,playSequence:ne}=h,K=I(null),M=I(null),U=I(!1),H=I(null),L=I(0),G=I(null),k=I(null),V=I(new Set),z=X(()=>p.map((e)=>e.id).join("\x00"),[p]),J=I(p);J.current=p;let ie=I(j),re=I(S),se=I({itemIdsKey:z,scrollRoot:n});if(se.current.scrollRoot!==n)L.current+=1,se.current={itemIdsKey:z,scrollRoot:n};let g=X(()=>v===void 0?p.filter((e)=>j.has(e.id)):p,[v,p,j]),ae=X(()=>g.map((e)=>({inputTokens:e.inputTokens,outputTokens:e.outputTokens})),[g]),D=I({ids:"",groups:[]}),oe=g.map((e)=>e.id).join("\x00");if(D.current.ids!==oe)D.current={ids:oe,groups:we(g.map((e)=>e.id),D.current.groups)};P(()=>ee(),[ee]),P(()=>()=>{if(L.current+=1,G.current?.cancel(),k.current!==null)clearTimeout(k.current)},[]),P(()=>{y(null),R(!1),O(null),M.current=null,U.current=!1,H.current=null,F(null),V.current.clear()},[n]),P(()=>{te()},[te]),P(()=>{if(n===null)return;let e=new Set,t=new Map,i=new Set(J.current.map((s)=>s.id)),r=()=>{let s=new Set(t.values()),d=J.current.filter((f)=>s.has(f.id)).map((f)=>f.id),o=d.findIndex((f)=>e.has(f));if(o===-1)return;let b=o;for(let f=o+1;f<d.length;f++)if(e.has(d[f]))b=f;let N=new Set(d.slice(o,b+1));if(fe(re.current,N))return;re.current=N,w(N)},a=new IntersectionObserver((s)=>{for(let d of s){let o=t.get(d.target);if(d.isIntersecting)e.add(o);else e.delete(o)}r()},{root:n,rootMargin:`-${c}px 0px 0px 0px`}),u=()=>{let s=new Set,d=new Set;for(let o of n.querySelectorAll("[data-content-search-unit-key]")){let b=o.dataset.contentSearchUnitKey;if(b===void 0||!i.has(b)||s.has(b))continue;s.add(b);let N=o.closest("[data-turn-key]"),f=N===null||d.has(N)?o:N;if(d.add(f),t.has(f))continue;t.set(f,b),a.observe(f)}for(let o of t.keys()){if(d.has(o))continue;a.unobserve(o),e.delete(t.get(o)),t.delete(o)}if(r(),fe(ie.current,s))return;ie.current=s,pe(s)};u();let l=new MutationObserver((s)=>{if(s.some((o)=>[...o.addedNodes,...o.removedNodes].some((b)=>b instanceof Element&&(b.matches("[data-turn-key], [data-content-search-unit-key]")||b.querySelector("[data-turn-key], [data-content-search-unit-key]")!==null))))u()});return l.observe(n,{childList:!0,subtree:!0}),()=>{l.disconnect(),a.disconnect()}},[z,n,c]);let Y=g.find((e)=>S.has(e.id))?.id??g.at(-1)?.id;ye(()=>{let e=K.current;if(e===null||M.current!==null||Y===void 0)return;let t=e.querySelector(`[data-timeline-user-message-navigation-item-id="${CSS.escape(Y)}"]`);if(t===null)return;let i=e.getBoundingClientRect(),r=t.getBoundingClientRect();if(r.top<i.top)e.scrollTop+=r.top-i.top;else if(r.bottom>i.bottom)e.scrollTop+=r.bottom-i.bottom+1},[Y,z]),P(()=>{let e=n?.querySelector("[data-timeline-user-message-navigation-content]");if(!n||!e)return;let t=()=>{let r=n.getBoundingClientRect(),a=e.getBoundingClientRect();if(r.width===0||a.width===0)return;let u=n.offsetWidth>0?r.width/n.offsetWidth:1;be((a.left-r.left)/u>=48)},i=new ResizeObserver(t);return i.observe(n),i.observe(e),t(),()=>i.disconnect()},[n]);let he=xe(async(e,t="smooth")=>{if(n===null)throw Error("Thread user-message navigation scroll root is missing");let i=L.current+1;L.current=i,x();let r=()=>n.querySelector(`[data-content-search-unit-key="${CSS.escape(e.id)}"]`),a=r(),u=a!==null&&n.clientHeight>0&&a.closest("[data-turn-key]")!==null&&Math.abs(a.getBoundingClientRect().top-n.getBoundingClientRect().top)>n.clientHeight*2;if((a===null||u)&&v!==void 0){if(t==="instant"&&e.isLoaded===!1)return;a=await v(e,()=>L.current===i)??r(),t="instant"}if(L.current!==i)return;if(a===null)return;let l=window.matchMedia?.("(prefers-reduced-motion: reduce)").matches;a.scrollIntoView({behavior:l?"instant":t,block:"start"});let s=a.querySelector("[data-user-message-bubble], [data-composer-attachment-pill]");if(G.current?.cancel(),G.current=null,s===null)return;let d=getComputedStyle(s).backgroundColor,o=`color-mix(in srgb, var(--foreground) 14%, ${d})`;G.current=s.animate?.([{backgroundColor:o},{backgroundColor:o,offset:0.35},{backgroundColor:d}],{duration:l?0:1000,easing:"cubic-bezier(0.23, 1, 0.32, 1)"})??null},[x,v,n]);if(g.length<Se||!ve)return null;let Q=()=>{if(k.current!==null)clearTimeout(k.current);k.current=null},ue=(e,t=!1)=>{if(Q(),C===void 0||e.isLoaded!==!1||V.current.has(e.turnKey))return;let i=()=>{k.current=null,V.current.add(e.turnKey),C(e).catch(()=>V.current.delete(e.turnKey))};if(t)i();else k.current=setTimeout(i,150)},q=m===null?null:g.find((e)=>e.id===m.item.id)??g.find((e)=>e.nativeTurnId!==void 0&&e.nativeTurnId===m.item.nativeTurnId)??m.item,le=(e,t="smooth")=>{he(e,t).catch((i)=>{if(B)B(i);else throw i})},de=g.findIndex((e)=>e.id===(_??Ie)),ce=K.current,Te=m===null||!ce?.contains(m.button)?0:Me(ce,m.button),me=(e)=>{let t=e?.closest("[data-timeline-user-message-navigation-item-id]"),i=K.current;if(t===void 0||t===null||!i.contains(t))return null;let r=t.dataset.timelineUserMessageNavigationItemId,a=g.findIndex((u)=>u.id===r);return{button:t,item:g[a],index:a}},W=(e)=>{let t=M.current;if(t?.pointerId!==e.pointerId)return;if(M.current=null,O(null),t.captureTarget.hasPointerCapture(e.pointerId))t.captureTarget.releasePointerCapture(e.pointerId)};return T("nav",{"aria-label":"User messages",className:"timeline-user-message-navigation absolute start-4 top-1/2 z-20 -translate-y-1/2",children:T(Rr,{open:Z,onOpenChange:R,side:"inline-end",sideOffset:0,align:"center",alignOffset:Te,trigger:T("div",{ref:K,"data-timeline-user-message-navigation-rail-list":!0,"data-scrubbing":_===null?void 0:"",className:"timeline-user-message-navigation-rail-list",onPointerEnter:()=>{H.current=null},onPointerDown:(e)=>{if(e.button!==0)return;Q();let t=me(e.target instanceof Element?e.target:null);if(t===null)return;U.current=!1,M.current={pointerId:e.pointerId,itemId:t.item.id,itemIndex:t.index,captureTarget:t.button},t.button.setPointerCapture(e.pointerId),O(t.item.id),y(t),R(!0)},onPointerMove:(e)=>{let t=M.current;if(t===null){let l=me(e.target instanceof Element?e.target:null);if(l!==null){F(l.item.id);let s=H.current;if(s!==null&&s!==l.index)ne(s,l.index,ae);H.current=l.index,y((d)=>d?.item.id===l.item.id?d:l),ue(l.item)}return}if(t.pointerId!==e.pointerId)return;if((e.buttons&1)===0){W(e);return}let i=e.currentTarget.getBoundingClientRect(),r=Math.max(0,Math.min(g.length-1,Math.floor((e.clientY-i.top+e.currentTarget.scrollTop)/ge))),u={button:e.currentTarget.querySelectorAll("[data-timeline-user-message-navigation-item-id]")[r],item:g[r],index:r};if(u.item.id===t.itemId)return;ne(t.itemIndex,u.index,ae),H.current=u.index,M.current={...t,itemId:u.item.id,itemIndex:u.index},U.current=!0,O(u.item.id),y(u),le(u.item,"instant")},onPointerUp:W,onPointerCancel:W,onLostPointerCapture:W,onPointerLeave:()=>{if(Q(),F(null),H.current=null,M.current===null&&!Z)y(null)},children:T("div",{className:"flex flex-col",children:D.current.groups.map((e)=>T("div",{className:"flex w-9 shrink-0 flex-col [content-visibility:auto]",style:{height:e.itemIds.length*ge},children:g.slice(e.startIndex,e.startIndex+e.itemIds.length).map((t,i)=>{let r=e.startIndex+i,a=Math.abs(r-de),u=de===-1||a>3?void 0:[1,0.7,0.4,0.2][a];return T("button",{type:"button","data-timeline-user-message-navigation-item-id":t.id,"data-scrub-target":_===t.id?"":void 0,"aria-current":S.has(t.id)?"true":void 0,"aria-label":`Jump to user message ${r+1}`,className:"timeline-user-message-navigation-row",onClick:(l)=>{if(U.current){U.current=!1;return}let s={button:l.currentTarget,item:t,index:r};y(s),R(!0),le(t)},onFocus:(l)=>{ue(t,!0),y({button:l.currentTarget,item:t,index:r}),R(!0)},children:T("span",{className:"flex h-0.5 w-[30px] items-center",children:T("span",{className:"timeline-user-message-navigation-marker",style:u===void 0?void 0:{"--marker-progress":u}})})},t.id)})},e.key))})}),children:q!==null&&T("div",{className:"bg-popover/95 text-popover-foreground ring-border w-80 max-w-[calc(100vw-1rem)] overflow-hidden rounded-xl p-2 text-sm leading-5 shadow-xl ring-[0.5px] backdrop-blur-sm",children:A?A(q):Ne(ke,{children:[T("div",{className:"min-w-0 truncate font-medium",children:q.label}),q.response.length>0&&T("div",{className:"text-muted-foreground mt-1 line-clamp-3",children:q.response})]})})})})}function Me(h,x){let v=h.getBoundingClientRect(),p=x.getBoundingClientRect();return p.top+p.height/2-(v.top+v.height/2)}
2
+ export{Mr};
@@ -1,2 +1,2 @@
1
- import{jsx as r,jsxs as e}from"react/jsx-runtime";function $t({title:t,badge:a,children:i}){return e("header",{className:"flex min-h-9 shrink-0 flex-wrap items-center justify-between gap-3",children:[e("div",{className:"flex min-h-9 items-center gap-2",children:[r("h1",{className:"text-2xl leading-9 font-semibold tracking-tight",children:t}),a]}),i]})}
2
- export{$t};
1
+ import{jsx as r,jsxs as e}from"react/jsx-runtime";function Wt({title:t,badge:a,children:i}){return e("header",{className:"flex min-h-9 shrink-0 flex-wrap items-center justify-between gap-3",children:[e("div",{className:"flex min-h-9 items-center gap-2",children:[r("h1",{className:"text-2xl leading-9 font-semibold tracking-tight",children:t}),a]}),i]})}
2
+ export{Wt};
@@ -1,2 +1,2 @@
1
- import{g}from"./chunk-f67e77e6.js";import{e}from"./chunk-kyqf7cqh.js";import{xt}from"./chunk-hs98zk6m.js";import{FileText as l,RotateCcw as x,X as d}from"lucide-react";import{Button as r}from"@nyssance/shadcn/vega/components/ui/button";import{jsx as t,jsxs as i}from"react/jsx-runtime";function Ri({data:s,sessionId:m}){let{host:a}=e(),{t:o}=a,p=g(),{text:c,status:n}=s.pastedText;return i("div",{className:"bg-muted flex max-w-64 min-w-0 items-center gap-1 rounded-lg px-2 py-1",children:[i(r,{type:"button",variant:"ghost",disabled:n!=="ready",onClick:()=>a.openLink(s.url),className:"h-auto min-w-0 flex-1 shrink gap-2 overflow-hidden px-0 py-1",children:[t(l,{className:"size-4 shrink-0"}),i("span",{className:"min-w-0 flex-1 text-start",children:[t("span",{className:"block truncate text-xs",children:s.filename}),t("span",{className:"text-muted-foreground block text-xs",children:n==="ready"?o("composer.pastedTextCharacters",{count:c.length}):o(n==="pending"?"composer.pastedTextPending":"composer.pastedTextError")})]})]}),n==="error"&&a.writeTextAttachment&&t(r,{type:"button",variant:"ghost",size:"icon-xs","aria-label":o("composer.pastedTextRetry"),onClick:()=>xt(m,s,a.writeTextAttachment),children:t(x,{className:"size-3"})}),t(r,{type:"button",variant:"ghost",size:"icon-xs","aria-label":o("composer.pastedTextRemove"),onClick:()=>p.remove(s.id),children:t(d,{className:"size-3"})})]})}
2
- export{Ri};
1
+ import{g}from"./chunk-q8c4k6qh.js";import{e}from"./chunk-qgrd5xre.js";import{kt}from"./chunk-c70a2esc.js";import{FileText as l,RotateCcw as x,X as d}from"lucide-react";import{Button as r}from"@nyssance/shadcn/vega/components/ui/button";import{jsx as t,jsxs as i}from"react/jsx-runtime";function Hi({data:s,sessionId:m}){let{host:a}=e(),{t:o}=a,p=g(),{text:c,status:n}=s.pastedText;return i("div",{className:"bg-muted flex max-w-64 min-w-0 items-center gap-1 rounded-lg px-2 py-1",children:[i(r,{type:"button",variant:"ghost",disabled:n!=="ready",onClick:()=>a.openLink(s.url),className:"h-auto min-w-0 flex-1 shrink gap-2 overflow-hidden px-0 py-1",children:[t(l,{className:"size-4 shrink-0"}),i("span",{className:"min-w-0 flex-1 text-start",children:[t("span",{className:"block truncate text-xs",children:s.filename}),t("span",{className:"text-muted-foreground block text-xs",children:n==="ready"?o("composer.pastedTextCharacters",{count:c.length}):o(n==="pending"?"composer.pastedTextPending":"composer.pastedTextError")})]})]}),n==="error"&&a.writeTextAttachment&&t(r,{type:"button",variant:"ghost",size:"icon-xs","aria-label":o("composer.pastedTextRetry"),onClick:()=>kt(m,s,a.writeTextAttachment),children:t(x,{className:"size-3"})}),t(r,{type:"button",variant:"ghost",size:"icon-xs","aria-label":o("composer.pastedTextRemove"),onClick:()=>p.remove(s.id),children:t(d,{className:"size-3"})})]})}
2
+ export{Hi};
@@ -1,2 +1,2 @@
1
- import{a,o}from"./chunk-0b50jg23.js";import{latestAssistantReply as v}from"@nyssance/codex-acp-v2/client";import{useEffect as S,useState as g}from"react";function Jt(e,r){let s=a(),c=o((t)=>t.connection),i=o((t)=>Boolean(t.sessions[e]?.attached)&&!t.sessions[e]?.restoring),u=o((t)=>v(t.sessions[e]?.items)),f=o((t)=>Boolean(t.runStates[e]?.reusableDraft)),[p,y]=g();return S(()=>{if(c!=="ready"||f||i)return;let t=!1,l,n=0,m=async()=>{try{let d=await s.activityReply(e);if(n=0,!t)y(d??void 0)}catch{n++}finally{if(!t&&(r==="running"||n>0&&n<3))l=setTimeout(()=>void m(),5000)}};return m(),()=>{t=!0,clearTimeout(l)}},[s,e,c,f,i,r]),i?u:p??u}
2
- export{Jt};
1
+ import{a,o}from"./chunk-pxbww0j1.js";import{latestAssistantReply as v}from"@nyssance/codex-acp-v2/client";import{useEffect as S,useState as g}from"react";function tn(e,r){let s=a(),c=o((t)=>t.connection),i=o((t)=>Boolean(t.sessions[e]?.attached)&&!t.sessions[e]?.restoring),u=o((t)=>v(t.sessions[e]?.items)),f=o((t)=>Boolean(t.runStates[e]?.reusableDraft)),[p,y]=g();return S(()=>{if(c!=="ready"||f||i)return;let t=!1,l,n=0,m=async()=>{try{let d=await s.activityReply(e);if(n=0,!t)y(d??void 0)}catch{n++}finally{if(!t&&(r==="running"||n>0&&n<3))l=setTimeout(()=>void m(),5000)}};return m(),()=>{t=!0,clearTimeout(l)}},[s,e,c,f,i,r]),i?u:p??u}
2
+ export{tn};
@@ -1,2 +1,2 @@
1
- import{Ne}from"./chunk-wj9s8331.js";import{useEffect as s,useState as w}from"react";function ni(){let[i,e]=w(!1);return s(()=>{let t=Ne()?"Meta":"Control",o=(n)=>{if(n.key===t)e(!0)},r=(n)=>{if(n.key===t)e(!1)},d=()=>e(!1);return window.addEventListener("keydown",o),window.addEventListener("keyup",r),window.addEventListener("blur",d),()=>{window.removeEventListener("keydown",o),window.removeEventListener("keyup",r),window.removeEventListener("blur",d)}},[]),i}
2
- export{ni};
1
+ import{Re}from"./chunk-e99t3sk5.js";import{useEffect as s,useState as w}from"react";function ai(){let[i,e]=w(!1);return s(()=>{let t=Re()?"Meta":"Control",o=(n)=>{if(n.key===t)e(!0)},r=(n)=>{if(n.key===t)e(!1)},d=()=>e(!1);return window.addEventListener("keydown",o),window.addEventListener("keyup",r),window.addEventListener("blur",d),()=>{window.removeEventListener("keydown",o),window.removeEventListener("keyup",r),window.removeEventListener("blur",d)}},[]),i}
2
+ export{ai};
@@ -1,4 +1,4 @@
1
- function bt(e,t){if(e!==null&&e!=="generate"&&e!=="edit")throw Error("Invalid image intent");return{"alwith.imageIntent":e===null?"The current message uses ordinary chat input. For image generation or editing, use the native image generation tool, never the application generate_image tool. Do not apply application image-model settings or earlier application image-workflow instructions. Image generation is not implied by the input mode; follow the user's request.":[e==="edit"?"The current message requests an image edit. Use the application generate_image tool and the supplied source and reference attachments. Follow the specific editing instructions in the user message.":"The user selected image input for the current message. Treat descriptions as requests to generate or edit images using the application generate_image tool. Use attached images as references when relevant. Answer questions about previous results normally; do not generate another image unless requested.","Use only the application's selected image model for this image conversation. Do not substitute a native image generation tool.",t].filter(Boolean).join(`
1
+ function St(e,t){if(e!==null&&e!=="generate"&&e!=="edit")throw Error("Invalid image intent");return{"alwith.imageIntent":e===null?"The current message uses ordinary chat input. For image generation or editing, use the native image generation tool, never the application generate_image tool. Do not apply application image-model settings or earlier application image-workflow instructions. Image generation is not implied by the input mode; follow the user's request.":[e==="edit"?"The current message requests an image edit. Use the application generate_image tool and the supplied source and reference attachments. Follow the specific editing instructions in the user message.":"The user selected image input for the current message. Treat descriptions as requests to generate or edit images using the application generate_image tool. Use attached images as references when relevant. Answer questions about previous results normally; do not generate another image unless requested.","Use only the application's selected image model for this image conversation. Do not substitute a native image generation tool.",t].filter(Boolean).join(`
2
2
 
3
3
  `)}}
4
- export{bt};
4
+ export{St};
@@ -0,0 +1,2 @@
1
+ import{Ps}from"./chunk-gk7nn747.js";import{createContext as s,useContext as o,useSyncExternalStore as m}from"react";import{jsx as l}from"react/jsx-runtime";var u=s(null),c=s(null),Qo=s(null);function de(){return o(Qo)}function qe({host:e,client:i,children:r}){return l(Ps,{host:e,children:l(u,{value:e,children:l(c,{value:i,children:r})})})}function t(){let e=o(u);if(e===null)throw Error("Timeline host is missing");return e}function We(){let e=o(c);if(e===null)throw Error("Timeline client is missing");return e}function k(e,i){return m((r)=>e.subscribe(r),()=>i(e.getState()),()=>i(e.getState()))}function n(e){let i=We();return k(i.store,e)}function Jo(){return o(u)!==null}function ue(e,i){if(e.reportError)e.reportError(i);else console.error(i)}
2
+ export{Qo,de,qe,t,We,k,n,Jo,ue};
@@ -1,4 +1,4 @@
1
- function Yi(e,t){if(t===0)return null;let r=t-1;while(r>=0){let n=e[r];if(n===" "||n==="\t"||n===`
1
+ function nr(e,t){if(t===0)return null;let r=t-1;while(r>=0){let n=e[r];if(n===" "||n==="\t"||n===`
2
2
  `)return null;if(n==="@"||n==="/"){let i=r===0?"":e[r-1],a=r===0||i===`
3
3
  `||i===" "||i==="\t",s=a||/[\p{Script=Han}\p{Script=Hiragana}\p{Script=Katakana}\p{Script=Hangul},。!?:;((]/u.test(i??"");if(n==="/"?s&&!/[/\\]/.test(e.slice(r+1,t)):a)return{kind:n==="/"?"slash":"at",start:r,end:t,query:e.slice(r+1,t)}}r-=1}return null}
4
- export{Yi};
4
+ export{nr};
@@ -1,3 +1,3 @@
1
- import{Ii,yt}from"./chunk-81xwn9e5.js";import{t,w}from"./chunk-e4ws15tg.js";import{createStore as d}from"@alwith/api/client";import{Dialog as f,DialogContent as p,DialogDescription as m,DialogHeader as u,DialogTitle as h}from"@nyssance/shadcn/vega/components/ui/dialog";import{jsx as i,jsxs as l}from"react/jsx-runtime";var c=d({request:null});function un(e){c.setState({request:{path:e.path,patch:Ci(e.patch,e.path)}})}function Ci(e,a){let n=e.split(/^(?=diff --git )/m).filter((o)=>o.length>0);if(n.length<=1)return e;return n.find((o)=>{let r=o.split(`
2
- `,1)[0]??"";return r.endsWith(` b/${a}`)||r.endsWith(` ${a}`)||r.includes(`/${a} `)})??e}function pn(){let{t:e,theme:a}=t(),n=w(c,(o)=>o.request),s=n===null?null:Ii(n.patch);return i(f,{open:n!==null,onOpenChange:(o)=>!o&&c.setState({request:null}),children:l(p,{className:"flex h-[calc(100vh-2.5rem)] max-h-[900px] flex-col gap-3 sm:max-w-[min(1400px,calc(100vw-2.5rem))]",children:[l(u,{children:[i(h,{className:"truncate pe-8 font-mono text-sm font-normal",children:n?.path}),s!==null&&l(m,{children:[l("span",{className:"codex-diff-additions",children:["+",s.additions]})," ",l("span",{className:"codex-diff-deletions",children:["-",s.deletions]})," ",i("span",{children:e("conversation.changedLines")})]})]}),i("div",{className:"min-h-0 min-w-0 flex-1 overflow-hidden rounded-lg border [&>.codex-patch-view]:h-full","data-stream-style":"codexUI",children:n!==null&&i(yt,{patch:n.patch,theme:a})})]})})}
3
- export{un,Ci,pn};
1
+ import{Ei,wt}from"./chunk-y8aeahf2.js";import{t,k}from"./chunk-aj0z9a5r.js";import{createStore as d}from"@alwith/api/client";import{Dialog as f,DialogContent as p,DialogDescription as m,DialogHeader as u,DialogTitle as h}from"@nyssance/shadcn/vega/components/ui/dialog";import{jsx as i,jsxs as l}from"react/jsx-runtime";var c=d({request:null});function mn(e){c.setState({request:{path:e.path,patch:Ii(e.patch,e.path)}})}function Ii(e,a){let n=e.split(/^(?=diff --git )/m).filter((o)=>o.length>0);if(n.length<=1)return e;return n.find((o)=>{let r=o.split(`
2
+ `,1)[0]??"";return r.endsWith(` b/${a}`)||r.endsWith(` ${a}`)||r.includes(`/${a} `)})??e}function gn(){let{t:e,theme:a}=t(),n=k(c,(o)=>o.request),s=n===null?null:Ei(n.patch);return i(f,{open:n!==null,onOpenChange:(o)=>!o&&c.setState({request:null}),children:l(p,{className:"flex h-[calc(100vh-2.5rem)] max-h-[900px] flex-col gap-3 sm:max-w-[min(1400px,calc(100vw-2.5rem))]",children:[l(u,{children:[i(h,{className:"truncate pe-8 font-mono text-sm font-normal",children:n?.path}),s!==null&&l(m,{children:[l("span",{className:"codex-diff-additions",children:["+",s.additions]})," ",l("span",{className:"codex-diff-deletions",children:["-",s.deletions]})," ",i("span",{children:e("conversation.changedLines")})]})]}),i("div",{className:"min-h-0 min-w-0 flex-1 overflow-hidden rounded-lg border [&>.codex-patch-view]:h-full","data-stream-style":"codexUI",children:n!==null&&i(wt,{patch:n.patch,theme:a})})]})})}
3
+ export{mn,Ii,gn};
@@ -1,2 +1,2 @@
1
- var l=/(?::\d+(?::\d+)?(?:[-–]\d+(?::\d+)?)?|#L\d+(?:C\d+)?(?:-L\d+(?:C\d+)?)?)$/;function s(t){return t.startsWith("/")||/^[A-Za-z]:[\\/]/.test(t)||t.startsWith(String.raw`\\`)}function Go(t,o){let e=/^[^/\\:]+:\d+(?::\d+)?(?:[-–]\d+(?::\d+)?)?$/.test(t);if(/^[a-z][a-z\d+.-]*:/i.test(t)&&!e||s(t))return t;if(t.startsWith("www."))return`https://${t}`;if(o===null)throw Error("The conversation's directory is unavailable");return`${encodeURI(o.replace(/[\\/]$/,"")).replaceAll(/[?#]/g,encodeURIComponent)}/${t}`}function Bt(t,o){let e=Go(t,o),n;if(/^file:/i.test(e)){let r=new URL(e);if(n=decodeURIComponent(r.pathname),/^\/[A-Za-z]:\//.test(n))n=n.slice(1);if(r.hostname&&r.hostname!=="localhost")n=`//${r.hostname}${n}`}else if(s(e))try{n=decodeURI(e)}catch(r){if(!(r instanceof URIError))throw r;n=e}else return null;return n.replace(l,"")}function Xr(t,o){let e=(i)=>i.replaceAll("\\","/").replace(/\/+$/,""),n=e(t),r=e(o);return r===n||r.startsWith(`${n}/`)}function Yr(t,o){if(/^file:/i.test(t)){let e=new URL(t),n=decodeURIComponent(e.pathname);if(/^\/[A-Za-z]:\//.test(n))n=n.slice(1);if(e.hostname&&e.hostname!=="localhost")n=`//${e.hostname}${n}`;return n}if(s(t))return t;if(o===null)throw Error("The conversation's directory is unavailable");return`${o.replace(/[\\/]$/,"")}/${t}`}
2
- export{Go,Bt,Xr,Yr};
1
+ var l=/(?::\d+(?::\d+)?(?:[-–]\d+(?::\d+)?)?|#L\d+(?:C\d+)?(?:-L\d+(?:C\d+)?)?)$/;function s(t){return t.startsWith("/")||/^[A-Za-z]:[\\/]/.test(t)||t.startsWith(String.raw`\\`)}function Vo(t,o){let e=/^[^/\\:]+:\d+(?::\d+)?(?:[-–]\d+(?::\d+)?)?$/.test(t);if(/^[a-z][a-z\d+.-]*:/i.test(t)&&!e||s(t))return t;if(t.startsWith("www."))return`https://${t}`;if(o===null)throw Error("The conversation's directory is unavailable");return`${encodeURI(o.replace(/[\\/]$/,"")).replaceAll(/[?#]/g,encodeURIComponent)}/${t}`}function Vt(t,o){let e=Vo(t,o),n;if(/^file:/i.test(e)){let r=new URL(e);if(n=decodeURIComponent(r.pathname),/^\/[A-Za-z]:\//.test(n))n=n.slice(1);if(r.hostname&&r.hostname!=="localhost")n=`//${r.hostname}${n}`}else if(s(e))try{n=decodeURI(e)}catch(r){if(!(r instanceof URIError))throw r;n=e}else return null;return n.replace(l,"")}function Qr(t,o){let e=(i)=>i.replaceAll("\\","/").replace(/\/+$/,""),n=e(t),r=e(o);return r===n||r.startsWith(`${n}/`)}function Jr(t,o){if(/^file:/i.test(t)){let e=new URL(t),n=decodeURIComponent(e.pathname);if(/^\/[A-Za-z]:\//.test(n))n=n.slice(1);if(e.hostname&&e.hostname!=="localhost")n=`//${e.hostname}${n}`;return n}if(s(t))return t;if(o===null)throw Error("The conversation's directory is unavailable");return`${o.replace(/[\\/]$/,"")}/${t}`}
2
+ export{Vo,Vt,Qr,Jr};
@@ -1,3 +1,3 @@
1
- var sl=["full","compact","codexUI"];function Rr(t){return t==="compact"||t==="codexUI"}var Ha=["read","edit","delete","move","search","execute","think","fetch","switch_mode","other"];function c(t){let o=t.split(/[/\\]/).at(-1)??"";return o===""?t:o}function oe(t){let o=Ha.includes(t.kind)?t.kind:"other",i=t.rawInput,e=(a)=>{let r=i[a];return typeof r==="string"&&r.length>0?r:void 0},n=t.locations?.[0]?.path??e("file_path")??e("notebook_path"),s=n!==void 0?c(n):e("command")?.split(`
2
- `)[0]??e("pattern")??e("url")??e("query")??e("description");return{category:o,...s===void 0?{}:{target:s},...n===void 0?{}:{filePath:n}}}function al(t,o){if(o)return"dot-permission";switch(t){case"completed":return"dot-success";case"failed":return"dot-error";case"in_progress":return"dot-in-progress";case"pending":return"dot-pending";case"interrupted":return"dot-interrupted";default:return console.warn("[acp] unknown tool call status:",t),"dot-pending"}}
3
- export{sl,Rr,Ha,oe,al};
1
+ var gl=["full","compact","codexUI"];function Wr(t){return t==="compact"||t==="codexUI"}var Ka=["read","edit","delete","move","search","execute","think","fetch","switch_mode","other"];function c(t){let o=t.split(/[/\\]/).at(-1)??"";return o===""?t:o}function ie(t){let o=Ka.includes(t.kind)?t.kind:"other",i=t.rawInput,e=(a)=>{let r=i[a];return typeof r==="string"&&r.length>0?r:void 0},n=t.locations?.[0]?.path??e("file_path")??e("notebook_path"),s=n!==void 0?c(n):e("command")?.split(`
2
+ `)[0]??e("pattern")??e("url")??e("query")??e("description");return{category:o,...s===void 0?{}:{target:s},...n===void 0?{}:{filePath:n}}}function fl(t,o){if(o)return"dot-permission";switch(t){case"completed":return"dot-success";case"failed":return"dot-error";case"in_progress":return"dot-in-progress";case"pending":return"dot-pending";case"interrupted":return"dot-interrupted";default:return console.warn("[acp] unknown tool call status:",t),"dot-pending"}}
3
+ export{gl,Wr,Ka,ie,fl};
@@ -1,4 +1,4 @@
1
- import{rt}from"./chunk-a18avvt2.js";import{Yi}from"./chunk-x49qjrbk.js";import{l}from"./chunk-6283nzqs.js";import{he}from"./chunk-f67e77e6.js";import{autoUpdate as ot}from"@floating-ui/dom";import{cn as st}from"cn";import{BookOpenIcon as it,FileIcon as at,SquareSlashIcon as lt,StoreIcon as ut}from"lucide-react";import{useCallback as ct,useEffect as y,useLayoutEffect as X,useMemo as Y,useRef as Z,useState as g}from"react";import{createPortal as mt}from"react-dom";import{Button as _}from"@nyssance/shadcn/vega/components/ui/button";import{jsx as d,jsxs as T,Fragment as pt}from"react/jsx-runtime";function Xi({handleRef:a,anchorRef:f,commands:q,renderSlashMenu:k,searchFiles:u,onMention:R,onSearchError:j,fileSearchDebounceMs:M=0,bashMode:Q=!1,forcedOpen:i=!1,onForcedOpenChange:c,emptyLabel:F,fileStatusLabels:L,morePlugins:N}){let D=he(),s=D.textInput.value,[z,P]=g(0),[O,S]=g(!1),[x,B]=g(null),[E,h]=g(0),U=Z(null);y(()=>{let t=a.current?.getTextarea();if(!t)return;let e=()=>P(t.selectionStart??0),n=()=>{if(document.activeElement===t)e()};return t.addEventListener("keyup",e),t.addEventListener("click",e),t.addEventListener("input",e),t.addEventListener("select",e),t.addEventListener("focus",e),document.addEventListener("selectionchange",n),()=>{t.removeEventListener("keyup",e),t.removeEventListener("click",e),t.removeEventListener("input",e),t.removeEventListener("select",e),t.removeEventListener("focus",e),document.removeEventListener("selectionchange",n)}},[a]);let V=Y(()=>Q&&s.startsWith("!")?null:Yi(s,z),[s,z,Q]),o=V?.kind==="at"&&!u?null:V,H=`${o?.kind??"forced"}:${o?.query??""}:${i}`,[tt,et]=g(H);if(tt!==H)et(H),h(0);let I=Z(null);y(()=>{if(!i){I.current=null;return}if(I.current===null)I.current=s;else if(s!==I.current)c?.(!1)},[i,s,c]);let b=o?.kind==="at"?o.query:null;y(()=>{if(b===null||!u){B(null);return}let t=!0,e=()=>{u(b).then((r)=>{if(t)B({query:b,search:u,items:r})},(r)=>{if(t)B({query:b,search:u,items:[]}),j(r)})},n=M>0?window.setTimeout(e,M):null;if(n===null)e();return()=>{if(t=!1,n!==null)window.clearTimeout(n)}},[b,u,M,j]);let v=Y(()=>{if(o?.kind==="at")return x?.query===o.query&&x.search===u?x.items:[];if(k&&(o?.kind==="slash"||i))return[];if(o)return rt(q,o.query);if(i)return rt(q,"");return[]},[o,i,q,x,u,k]),m=o?o.kind==="slash":i;y(()=>{let t=a.current?.getTextarea();if(!t)return;let e=()=>S(!0),n=()=>{if(S(!1),i)c?.(!1)};return S(document.activeElement===t),t.addEventListener("focus",e),t.addEventListener("blur",n),()=>{t.removeEventListener("focus",e),t.removeEventListener("blur",n)}},[a,i,c]),y(()=>{if(i)a.current?.getTextarea()?.focus()},[i,a]);let p=O&&(o!==null?o.kind==="slash"||v.length>0||!!L:i);y(()=>{if(!p)return;U.current?.querySelector(`[data-idx="${E}"]`)?.scrollIntoView({block:"nearest"})},[E,p]);function A(t){let e=a.current?.getTextarea();if(!e)return;let n,r;if(o){let K=o.kind==="slash"?`${t.payload.startsWith("$")?t.payload:`/${t.payload}`} `:`@${t.label} `;if(n=s.slice(0,o.start)+K+s.slice(o.end),o.kind==="at")R?.(t.payload);r=o.start+K.length}else if(i)n=`${s.length===0||s.endsWith(`
1
+ import{at}from"./chunk-fqchnswc.js";import{nr}from"./chunk-aj6yxm6d.js";import{l}from"./chunk-6283nzqs.js";import{ye}from"./chunk-q8c4k6qh.js";import{autoUpdate as ot}from"@floating-ui/dom";import{cn as rt}from"cn";import{BookOpenIcon as st,FileIcon as it,SquareSlashIcon as lt,StoreIcon as ut}from"lucide-react";import{useCallback as ct,useEffect as y,useLayoutEffect as X,useMemo as Y,useRef as Z,useState as g}from"react";import{createPortal as mt}from"react-dom";import{Button as _}from"@nyssance/shadcn/vega/components/ui/button";import{jsx as d,jsxs as T,Fragment as pt}from"react/jsx-runtime";function tr({handleRef:a,anchorRef:f,commands:q,renderSlashMenu:k,searchFiles:u,onMention:R,onSearchError:j,fileSearchDebounceMs:M=0,bashMode:Q=!1,forcedOpen:i=!1,onForcedOpenChange:c,emptyLabel:F,fileStatusLabels:L,morePlugins:N}){let D=ye(),s=D.textInput.value,[z,P]=g(0),[O,S]=g(!1),[x,B]=g(null),[E,h]=g(0),U=Z(null);y(()=>{let t=a.current?.getTextarea();if(!t)return;let e=()=>P(t.selectionStart??0),n=()=>{if(document.activeElement===t)e()};return t.addEventListener("keyup",e),t.addEventListener("click",e),t.addEventListener("input",e),t.addEventListener("select",e),t.addEventListener("focus",e),document.addEventListener("selectionchange",n),()=>{t.removeEventListener("keyup",e),t.removeEventListener("click",e),t.removeEventListener("input",e),t.removeEventListener("select",e),t.removeEventListener("focus",e),document.removeEventListener("selectionchange",n)}},[a]);let V=Y(()=>Q&&s.startsWith("!")?null:nr(s,z),[s,z,Q]),o=V?.kind==="at"&&!u?null:V,H=`${o?.kind??"forced"}:${o?.query??""}:${i}`,[tt,et]=g(H);if(tt!==H)et(H),h(0);let I=Z(null);y(()=>{if(!i){I.current=null;return}if(I.current===null)I.current=s;else if(s!==I.current)c?.(!1)},[i,s,c]);let b=o?.kind==="at"?o.query:null;y(()=>{if(b===null||!u){B(null);return}let t=!0,e=()=>{u(b).then((r)=>{if(t)B({query:b,search:u,items:r})},(r)=>{if(t)B({query:b,search:u,items:[]}),j(r)})},n=M>0?window.setTimeout(e,M):null;if(n===null)e();return()=>{if(t=!1,n!==null)window.clearTimeout(n)}},[b,u,M,j]);let v=Y(()=>{if(o?.kind==="at")return x?.query===o.query&&x.search===u?x.items:[];if(k&&(o?.kind==="slash"||i))return[];if(o)return at(q,o.query);if(i)return at(q,"");return[]},[o,i,q,x,u,k]),m=o?o.kind==="slash":i;y(()=>{let t=a.current?.getTextarea();if(!t)return;let e=()=>S(!0),n=()=>{if(S(!1),i)c?.(!1)};return S(document.activeElement===t),t.addEventListener("focus",e),t.addEventListener("blur",n),()=>{t.removeEventListener("focus",e),t.removeEventListener("blur",n)}},[a,i,c]),y(()=>{if(i)a.current?.getTextarea()?.focus()},[i,a]);let p=O&&(o!==null?o.kind==="slash"||v.length>0||!!L:i);y(()=>{if(!p)return;U.current?.querySelector(`[data-idx="${E}"]`)?.scrollIntoView({block:"nearest"})},[E,p]);function A(t){let e=a.current?.getTextarea();if(!e)return;let n,r;if(o){let K=o.kind==="slash"?`${t.payload.startsWith("$")?t.payload:`/${t.payload}`} `:`@${t.label} `;if(n=s.slice(0,o.start)+K+s.slice(o.end),o.kind==="at")R?.(t.payload);r=o.start+K.length}else if(i)n=`${s.length===0||s.endsWith(`
2
2
  `)?s:`${s}
3
- `}${t.payload.startsWith("$")?t.payload:`/${t.payload}`} `,r=n.length,c?.(!1);else return;D.textInput.setInput(n),requestAnimationFrame(()=>{e.focus(),e.setSelectionRange(r,r)})}y(()=>{let t=a.current?.getTextarea();if(!t)return;let e=(n)=>{if(!p||m&&k)return;if(a.current?.isComposing()||n.isComposing||n.keyCode===229)return;if(n.key==="ArrowDown")n.preventDefault(),n.stopPropagation(),h((r)=>v.length===0?0:Math.min(v.length-1,r+1));else if(n.key==="ArrowUp")n.preventDefault(),n.stopPropagation(),h((r)=>Math.max(0,r-1));else if(n.key==="Enter"&&!n.shiftKey&&!n.altKey||n.key==="Tab"){n.preventDefault(),n.stopPropagation();let r=v[E];if(r)A(r)}else if(n.key==="Escape")if(n.preventDefault(),n.stopPropagation(),o)P(Math.max(0,o.start-1)),t.setSelectionRange(o.start,o.start);else c?.(!1)};return t.addEventListener("keydown",e,!0),()=>t.removeEventListener("keydown",e,!0)});let[w,G]=g(null),[W,nt]=g(null),C=ct(()=>{let t=f?.current;if(!t)return;let e=t.getBoundingClientRect();G({left:e.left,width:e.width,bottom:window.innerHeight-e.top+8})},[f]);if(X(()=>{if(!p){G(null);return}C()},[p,C]),X(()=>{let t=f?.current;if(!p||!t||!W)return;return ot(t,W,C,{animationFrame:!0})},[p,W,f,C]),p&&m&&k)return k({query:o?.query??"",close:()=>{if(o)P(o.start),a.current?.getTextarea()?.setSelectionRange(o.start,o.start);else c?.(!1)},selectCommand:(t)=>A({key:t,label:t,payload:t}),replaceQuery:(t)=>{let e=a.current?.getTextarea();if(!e)return;let n=o?.start??e.selectionStart,r=o?.end??e.selectionEnd;D.textInput.setInput(s.slice(0,n)+s.slice(r)),c?.(!1),requestAnimationFrame(()=>{if(a.current?.getTextarea()!==e)return;e.focus(),e.setSelectionRange(n,n),t()})}});if(!p||f&&!w)return null;let J=d("div",{ref:nt,className:f?"fixed z-50":l.position,style:f&&w?{left:w.left,width:w.width,bottom:w.bottom}:void 0,children:T("div",{ref:U,role:"listbox",onMouseDown:(t)=>t.preventDefault(),className:l.surface,children:[T("div",{className:l.list,children:[v.length===0&&m&&d("div",{role:"option","aria-disabled":"true","aria-selected":"false",className:"text-muted-foreground px-2 py-3 text-xs",children:F}),v.length===0&&!m&&L&&d("div",{role:"option","aria-disabled":"true","aria-selected":"false",className:"text-muted-foreground px-2 py-3 text-xs",children:x?.query===b&&x.search===u?L.empty:L.loading}),v.map((t,e)=>{let n=m?t.payload.startsWith("$")?it:lt:at;return T(_,{type:"button",variant:"ghost",role:"option","aria-selected":e===E,"data-idx":e,onMouseDown:(r)=>{r.preventDefault(),A(t)},onMouseEnter:()=>h(e),className:st(m?l.row:"flex h-auto w-full items-center justify-start gap-2.5 rounded-md px-2.5 py-2 text-start",e===E&&l.selected),children:[d(n,{className:m?l.icon:"text-muted-foreground size-4 shrink-0"}),d("span",{className:m?l.label:"text-foreground shrink-0 text-sm font-medium",children:t.label}),t.description&&d("span",{"data-slot":"description",className:l.description,children:t.description})]},t.key)})]}),m&&N&&d(pt,{children:T(_,{type:"button",variant:"ghost",onMouseDown:(t)=>{t.preventDefault(),c?.(!1),N.open()},className:l.row,children:[d(ut,{className:l.icon}),d("span",{className:l.label,children:N.label})]})})]})});return f?mt(J,document.body):J}
4
- export{Xi};
3
+ `}${t.payload.startsWith("$")?t.payload:`/${t.payload}`} `,r=n.length,c?.(!1);else return;D.textInput.setInput(n),requestAnimationFrame(()=>{e.focus(),e.setSelectionRange(r,r)})}y(()=>{let t=a.current?.getTextarea();if(!t)return;let e=(n)=>{if(!p||m&&k)return;if(a.current?.isComposing()||n.isComposing||n.keyCode===229)return;if(n.key==="ArrowDown")n.preventDefault(),n.stopPropagation(),h((r)=>v.length===0?0:Math.min(v.length-1,r+1));else if(n.key==="ArrowUp")n.preventDefault(),n.stopPropagation(),h((r)=>Math.max(0,r-1));else if(n.key==="Enter"&&!n.shiftKey&&!n.altKey||n.key==="Tab"){n.preventDefault(),n.stopPropagation();let r=v[E];if(r)A(r)}else if(n.key==="Escape")if(n.preventDefault(),n.stopPropagation(),o)P(Math.max(0,o.start-1)),t.setSelectionRange(o.start,o.start);else c?.(!1)};return t.addEventListener("keydown",e,!0),()=>t.removeEventListener("keydown",e,!0)});let[w,G]=g(null),[W,nt]=g(null),C=ct(()=>{let t=f?.current;if(!t)return;let e=t.getBoundingClientRect();G({left:e.left,width:e.width,bottom:window.innerHeight-e.top+8})},[f]);if(X(()=>{if(!p){G(null);return}C()},[p,C]),X(()=>{let t=f?.current;if(!p||!t||!W)return;return ot(t,W,C,{animationFrame:!0})},[p,W,f,C]),p&&m&&k)return k({query:o?.query??"",close:()=>{if(o)P(o.start),a.current?.getTextarea()?.setSelectionRange(o.start,o.start);else c?.(!1)},selectCommand:(t)=>A({key:t,label:t,payload:t}),replaceQuery:(t)=>{let e=a.current?.getTextarea();if(!e)return;let n=o?.start??e.selectionStart,r=o?.end??e.selectionEnd;D.textInput.setInput(s.slice(0,n)+s.slice(r)),c?.(!1),requestAnimationFrame(()=>{if(a.current?.getTextarea()!==e)return;e.focus(),e.setSelectionRange(n,n),t()})}});if(!p||f&&!w)return null;let J=d("div",{ref:nt,className:f?"fixed z-50":l.position,style:f&&w?{left:w.left,width:w.width,bottom:w.bottom}:void 0,children:T("div",{ref:U,role:"listbox",onMouseDown:(t)=>t.preventDefault(),className:l.surface,children:[T("div",{className:l.list,children:[v.length===0&&m&&d("div",{role:"option","aria-disabled":"true","aria-selected":"false",className:"text-muted-foreground px-2 py-3 text-xs",children:F}),v.length===0&&!m&&L&&d("div",{role:"option","aria-disabled":"true","aria-selected":"false",className:"text-muted-foreground px-2 py-3 text-xs",children:x?.query===b&&x.search===u?L.empty:L.loading}),v.map((t,e)=>{let n=m?t.payload.startsWith("$")?st:lt:it;return T(_,{type:"button",variant:"ghost",role:"option","aria-selected":e===E,"data-idx":e,onMouseDown:(r)=>{r.preventDefault(),A(t)},onMouseEnter:()=>h(e),className:rt(m?l.row:"flex h-auto w-full items-center justify-start gap-2.5 rounded-md px-2.5 py-2 text-start",e===E&&l.selected),children:[d(n,{className:m?l.icon:"text-muted-foreground size-4 shrink-0"}),d("span",{className:m?l.label:"text-foreground shrink-0 text-sm font-medium",children:t.label}),t.description&&d("span",{"data-slot":"description",className:l.description,children:t.description})]},t.key)})]}),m&&N&&d(pt,{children:T(_,{type:"button",variant:"ghost",onMouseDown:(t)=>{t.preventDefault(),c?.(!1),N.open()},className:l.row,children:[d(ut,{className:l.icon}),d("span",{className:l.label,children:N.label})]})})]})});return f?mt(J,document.body):J}
4
+ export{tr};
@@ -1,2 +1,2 @@
1
- import{N}from"./chunk-d4jkh19p.js";import{EmojiPicker as t}from"frimousse";import{BoxIcon as u}from"lucide-react";import{useState as d}from"react";import{Button as g}from"@nyssance/shadcn/vega/components/ui/button";import{Popover as x,PopoverContent as f,PopoverTrigger as b}from"@nyssance/shadcn/vega/components/ui/popover";import{jsx as o,jsxs as n}from"react/jsx-runtime";function gt({emoji:s,onChange:l}){let[m,r]=d(!1),{t:a,i18n:c,emojibaseUrl:p}=N();return n(x,{open:m,onOpenChange:r,children:[o(b,{onClick:(e)=>e.stopPropagation(),onPointerDown:(e)=>e.stopPropagation(),render:o(g,{variant:"ghost",size:"icon-xs",className:"relative z-10","aria-label":a("collection.emoji"),children:s||o(u,{className:"size-3.5"})})}),o(f,{align:"start",className:"w-auto p-0",children:n(t.Root,{emojibaseUrl:p,locale:c.language==="zh-CN"?"zh":"en",className:"bg-popover flex h-80 w-72 flex-col",onEmojiSelect:({emoji:e})=>{l(e),r(!1)},children:[o(t.Search,{"aria-label":a("collection.emoji"),className:"focus-visible:border-ring mx-2 mt-2 flex h-8 rounded-md border bg-transparent px-2 text-sm outline-none"}),n(t.Viewport,{className:"relative flex-1 outline-none",children:[o(t.Loading,{className:"text-muted-foreground absolute inset-0 flex items-center justify-center text-xs",children:"…"}),o(t.Empty,{className:"text-muted-foreground absolute inset-0 flex items-center justify-center text-xs"}),o(t.List,{className:"pb-1.5 select-none",components:{CategoryHeader:({category:e,...i})=>o("div",{className:"bg-popover text-muted-foreground px-3 pt-3 pb-1.5 text-xs",...i,children:e.label}),Row:({children:e,...i})=>o("div",{className:"scroll-my-1.5 px-1.5",...i,children:e}),Emoji:({emoji:e,...i})=>o("button",{type:"button",className:"data-[active]:bg-accent flex size-8 items-center justify-center rounded-md text-lg",...i,children:e.emoji})}})]})]})})]})}
2
- export{gt};
1
+ import{A}from"./chunk-nrfyvzmk.js";import{EmojiPicker as t}from"frimousse";import{BoxIcon as u}from"lucide-react";import{useState as d}from"react";import{Button as g}from"@nyssance/shadcn/vega/components/ui/button";import{Popover as x,PopoverContent as f,PopoverTrigger as b}from"@nyssance/shadcn/vega/components/ui/popover";import{jsx as o,jsxs as n}from"react/jsx-runtime";function yt({emoji:s,onChange:l}){let[m,r]=d(!1),{t:a,i18n:c,emojibaseUrl:p}=A();return n(x,{open:m,onOpenChange:r,children:[o(b,{onClick:(e)=>e.stopPropagation(),onPointerDown:(e)=>e.stopPropagation(),render:o(g,{variant:"ghost",size:"icon-xs",className:"relative z-10","aria-label":a("collection.emoji"),children:s||o(u,{className:"size-3.5"})})}),o(f,{align:"start",className:"w-auto p-0",children:n(t.Root,{emojibaseUrl:p,locale:c.language==="zh-CN"?"zh":"en",className:"bg-popover flex h-80 w-72 flex-col",onEmojiSelect:({emoji:e})=>{l(e),r(!1)},children:[o(t.Search,{"aria-label":a("collection.emoji"),className:"focus-visible:border-ring mx-2 mt-2 flex h-8 rounded-md border bg-transparent px-2 text-sm outline-none"}),n(t.Viewport,{className:"relative flex-1 outline-none",children:[o(t.Loading,{className:"text-muted-foreground absolute inset-0 flex items-center justify-center text-xs",children:"…"}),o(t.Empty,{className:"text-muted-foreground absolute inset-0 flex items-center justify-center text-xs"}),o(t.List,{className:"pb-1.5 select-none",components:{CategoryHeader:({category:e,...i})=>o("div",{className:"bg-popover text-muted-foreground px-3 pt-3 pb-1.5 text-xs",...i,children:e.label}),Row:({children:e,...i})=>o("div",{className:"scroll-my-1.5 px-1.5",...i,children:e}),Emoji:({emoji:e,...i})=>o("button",{type:"button",className:"data-[active]:bg-accent flex size-8 items-center justify-center rounded-md text-lg",...i,children:e.emoji})}})]})]})})]})}
2
+ export{yt};
@@ -0,0 +1,2 @@
1
+ import{u,go}from"./chunk-pz5d0vgv.js";import{Vn}from"./chunk-th5vv83g.js";import{useEffect as p,useRef as P,useState as m}from"react";var Li="providers:changed",Di="providers:managed-revoked",i=(e)=>e;function yn(){return{read:()=>i(u.providersRead()),save:(e,r,t)=>i(u.providersSave({providerId:r,input:t,expectedRevision:e})),saveCustom:(e,r)=>i(u.providersSaveCustom({input:r,expectedRevision:e})),removeCustom:(e,r)=>i(u.providersRemoveCustom({providerId:r,expectedRevision:e})),test:(e)=>u.providersTest({providerId:e}),apply:()=>i(u.providersApply()),onChanged:(e)=>go[Li].listen((r)=>e(r.payload))}}function ya(){return{bind:(e)=>u.providersAccountBind({account:e}),refresh:(e,r)=>i(u.providersRefreshManaged({generation:e,accessToken:r})),clear:async()=>{await u.providersClearManaged()},onRevoked:(e)=>go[Di].listen((r)=>e(r.payload.sessionIds))}}async function xn(e){try{return await e.apply()}catch(r){if(!Vn(r))throw r;return e.read()}}function bn(e,r=console.error){let[t,d]=m(null),a=P(r);return a.current=r,p(()=>{let n=!0,v=e.onChanged((o)=>{if(n)d((s)=>s&&s.revision>o.revision?s:o)});return v.then(()=>e.read()).then((o)=>{if(n)d((s)=>s&&s.revision>=o.revision?s:o)}).catch((o)=>{if(n)a.current(o)}),()=>{n=!1,v.then((o)=>o())}},[e]),t}
2
+ export{Li,Di,yn,ya,xn,bn};
@@ -1,2 +1,2 @@
1
- function Ss(o){let a=!1,n=!1,r=!1,e,f=()=>{if(n=!0,r||e!==void 0)return;e=setTimeout(()=>{e=void 0,l()},300)},l=async()=>{n=!1,r=!0;try{await o.listSessions({reset:!0})}catch{}finally{if(r=!1,!a&&n)f()}},d=o.store.subscribe((i,u)=>{if(i.runStates===u.runStates)return;if([...new Set([...Object.keys(i.runStates),...Object.keys(u.runStates)])].some((c)=>{let t=u.runStates[c],s=i.runStates[c];return t?.state!==s?.state||t?.reusableDraft!==s?.reusableDraft||t?.cwd!==s?.cwd||t?.title!==s?.title}))f()});return l(),()=>{a=!0,d(),clearTimeout(e)}}
2
- export{Ss};
1
+ function Ms(o){let a=!1,n=!1,r=!1,e,f=()=>{if(n=!0,r||e!==void 0)return;e=setTimeout(()=>{e=void 0,l()},300)},l=async()=>{n=!1,r=!0;try{await o.listSessions({reset:!0})}catch{}finally{if(r=!1,!a&&n)f()}},d=o.store.subscribe((i,u)=>{if(i.runStates===u.runStates)return;if([...new Set([...Object.keys(i.runStates),...Object.keys(u.runStates)])].some((c)=>{let t=u.runStates[c],s=i.runStates[c];return t?.state!==s?.state||t?.reusableDraft!==s?.reusableDraft||t?.cwd!==s?.cwd||t?.title!==s?.title}))f()});return l(),()=>{a=!0,d(),clearTimeout(e)}}
2
+ export{Ms};
@@ -1,2 +1,2 @@
1
- import{useId as o}from"react";import{jsx as l,jsxs as e}from"react/jsx-runtime";function Wi(t){return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"Claude"}),l("path",{fill:"#D97757",fillRule:"nonzero",d:"M4.709 15.955l4.72-2.647.08-.23-.08-.128H9.2l-.79-.048-2.698-.073-2.339-.097-2.266-.122-.571-.121L0 11.784l.055-.352.48-.321.686.06 1.52.103 2.278.158 1.652.097 2.449.255h.389l.055-.157-.134-.098-.103-.097-2.358-1.596-2.552-1.688-1.336-.972-.724-.491-.364-.462-.158-1.008.656-.722.881.06.225.061.893.686 1.908 1.476 2.491 1.833.365.304.145-.103.019-.073-.164-.274-1.355-2.446-1.446-2.49-.644-1.032-.17-.619a2.97 2.97 0 01-.104-.729L6.283.134 6.696 0l.996.134.42.364.62 1.414 1.002 2.229 1.555 3.03.456.898.243.832.091.255h.158V9.01l.128-1.706.237-2.095.23-2.695.08-.76.376-.91.747-.492.584.28.48.685-.067.444-.286 1.851-.559 2.903-.364 1.942h.212l.243-.242.985-1.306 1.652-2.064.73-.82.85-.904.547-.431h1.033l.76 1.129-.34 1.166-1.064 1.347-.881 1.142-1.264 1.7-.79 1.36.073.11.188-.02 2.856-.606 1.543-.28 1.841-.315.833.388.091.395-.328.807-1.969.486-2.309.462-3.439.813-.042.03.049.061 1.549.146.662.036h1.622l3.02.225.79.522.474.638-.079.485-1.215.62-1.64-.389-3.829-.91-1.312-.329h-.182v.11l1.093 1.068 2.006 1.81 2.509 2.33.127.578-.322.455-.34-.049-2.205-1.657-.851-.747-1.926-1.62h-.128v.17l.444.649 2.345 3.521.122 1.08-.17.353-.608.213-.668-.122-1.374-1.925-1.415-2.167-1.143-1.943-.14.08-.674 7.254-.316.37-.729.28-.607-.461-.322-.747.322-1.476.389-1.924.315-1.53.286-1.9.17-.632-.012-.042-.14.018-1.434 1.967-2.18 2.945-1.726 1.845-.414.164-.717-.37.067-.662.401-.589 2.388-3.036 1.44-1.882.93-1.086-.006-.158h-.055L4.132 18.56l-1.13.146-.487-.456.061-.746.231-.243 1.908-1.312-.006.006z"})]})}function Un(t){return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"DeepSeek"}),l("path",{fill:"#4D6BFE",d:"M23.748 4.482c-.254-.124-.364.113-.512.234-.051.039-.094.09-.137.136-.372.397-.806.657-1.373.626-.829-.046-1.537.214-2.163.848-.133-.782-.575-1.248-1.247-1.548-.352-.156-.708-.311-.955-.65-.172-.241-.219-.51-.305-.774-.055-.16-.11-.323-.293-.35-.2-.031-.278.136-.356.276-.313.572-.434 1.202-.422 1.84.027 1.436.633 2.58 1.838 3.393.137.093.172.187.129.323-.082.28-.18.552-.266.833-.055.179-.137.217-.329.14a5.526 5.526 0 01-1.736-1.18c-.857-.828-1.631-1.742-2.597-2.458a11.365 11.365 0 00-.689-.471c-.985-.957.13-1.743.388-1.836.27-.098.093-.432-.779-.428-.872.004-1.67.295-2.687.684a3.055 3.055 0 01-.465.137 9.597 9.597 0 00-2.883-.102c-1.885.21-3.39 1.102-4.497 2.623C.082 8.606-.231 10.684.152 12.85c.403 2.284 1.569 4.175 3.36 5.653 1.858 1.533 3.997 2.284 6.438 2.14 1.482-.085 3.133-.284 4.994-1.86.47.234.962.327 1.78.397.63.059 1.236-.03 1.705-.128.735-.156.684-.837.419-.961-2.155-1.004-1.682-.595-2.113-.926 1.096-1.296 2.746-2.642 3.392-7.003.05-.347.007-.565 0-.845-.004-.17.035-.237.23-.256a4.173 4.173 0 001.545-.475c1.396-.763 1.96-2.015 2.093-3.517.02-.23-.004-.467-.247-.588zM11.581 18c-2.089-1.642-3.102-2.183-3.52-2.16-.392.024-.321.471-.235.763.09.288.207.486.371.739.114.167.192.416-.113.603-.673.416-1.842-.14-1.897-.167-1.361-.802-2.5-1.86-3.301-3.307-.774-1.393-1.224-2.887-1.298-4.482-.02-.386.093-.522.477-.592a4.696 4.696 0 011.529-.039c2.132.312 3.946 1.265 5.468 2.774.868.86 1.525 1.887 2.202 2.891.72 1.066 1.494 2.082 2.48 2.914.348.292.625.514.891.677-.802.09-2.14.11-3.054-.614zm1-6.44a.306.306 0 01.415-.287.302.302 0 01.2.288.306.306 0 01-.31.307.303.303 0 01-.304-.308zm3.11 1.596c-.2.081-.399.151-.59.16a1.245 1.245 0 01-.798-.254c-.274-.23-.47-.358-.552-.758a1.73 1.73 0 01.016-.588c.07-.327-.008-.537-.239-.727-.187-.156-.426-.199-.688-.199a.559.559 0 01-.254-.078c-.11-.054-.2-.19-.114-.358.028-.054.16-.186.192-.21.356-.202.767-.136 1.146.016.352.144.618.408 1.001.782.391.451.462.576.685.914.176.265.336.537.445.848.067.195-.019.354-.25.452z"})]})}function Bn(t){return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",fill:"currentColor",fillRule:"evenodd",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"Grok"}),l("path",{d:"M9.27 15.29l7.978-5.897c.391-.29.95-.177 1.137.272.98 2.369.542 5.215-1.41 7.169-1.951 1.954-4.667 2.382-7.149 1.406l-2.711 1.257c3.889 2.661 8.611 2.003 11.562-.953 2.341-2.344 3.066-5.539 2.388-8.42l.006.007c-.983-4.232.242-5.924 2.75-9.383.06-.082.12-.164.179-.248l-3.301 3.305v-.01L9.267 15.292M7.623 16.723c-2.792-2.67-2.31-6.801.071-9.184 1.761-1.763 4.647-2.483 7.166-1.425l2.705-1.25a7.808 7.808 0 00-1.829-1A8.975 8.975 0 005.984 5.83c-2.533 2.536-3.33 6.436-1.962 9.764 1.022 2.487-.653 4.246-2.34 6.022-.599.63-1.199 1.259-1.682 1.925l7.62-6.815"})]})}var c="M12.604 1.34c.393.69.784 1.382 1.174 2.075a.18.18 0 00.157.091h5.552c.174 0 .322.11.446.327l1.454 2.57c.19.337.24.478.024.837-.26.43-.513.864-.76 1.3l-.367.658c-.106.196-.223.28-.04.512l2.652 4.637c.172.301.111.494-.043.77-.437.785-.882 1.564-1.335 2.34-.159.272-.352.375-.68.37-.777-.016-1.552-.01-2.327.016a.099.099 0 00-.081.05 575.097 575.097 0 01-2.705 4.74c-.169.293-.38.363-.725.364-.997.003-2.002.004-3.017.002a.537.537 0 01-.465-.271l-1.335-2.323a.09.09 0 00-.083-.049H4.982c-.285.03-.553-.001-.805-.092l-1.603-2.77a.543.543 0 01-.002-.54l1.207-2.12a.198.198 0 000-.197 550.951 550.951 0 01-1.875-3.272l-.79-1.395c-.16-.31-.173-.496.095-.965.465-.813.927-1.625 1.387-2.436.132-.234.304-.334.584-.335a338.3 338.3 0 012.589-.001.124.124 0 00.107-.063l2.806-4.895a.488.488 0 01.422-.246c.524-.001 1.053 0 1.583-.006L11.704 1c.341-.003.724.032.9.34zm-3.432.403a.06.06 0 00-.052.03L6.254 6.788a.157.157 0 01-.135.078H3.253c-.056 0-.07.025-.041.074l5.81 10.156c.025.042.013.062-.034.063l-2.795.015a.218.218 0 00-.2.116l-1.32 2.31c-.044.078-.021.118.068.118l5.716.008c.046 0 .08.02.104.061l1.403 2.454c.046.081.092.082.139 0l5.006-8.76.783-1.382a.055.055 0 01.096 0l1.424 2.53a.122.122 0 00.107.062l2.763-.02a.04.04 0 00.035-.02.041.041 0 000-.04l-2.9-5.086a.108.108 0 010-.113l.293-.507 1.12-1.977c.024-.041.012-.062-.035-.062H9.2c-.059 0-.073-.026-.043-.077l1.434-2.505a.107.107 0 000-.114L9.225 1.774a.06.06 0 00-.053-.031zm6.29 8.02c.046 0 .058.02.034.06l-.832 1.465-2.613 4.585a.056.056 0 01-.05.029.058.058 0 01-.05-.029L8.498 9.841c-.02-.034-.01-.052.028-.054l.216-.012 6.722-.012z";function Gn(t){let a=o().replaceAll(":","");return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"Qwen"}),l("path",{d:c,fill:`url(#${a})`,fillRule:"nonzero"}),l("defs",{children:e("linearGradient",{id:a,x1:"0%",x2:"100%",y1:"0%",y2:"0%",children:[l("stop",{offset:"0%",stopColor:"#6336E7",stopOpacity:".84"}),l("stop",{offset:"100%",stopColor:"#6F69F7",stopOpacity:".84"})]})})]})}function Zi(t){return l("svg",{viewBox:"-3 -3 30 30",fill:"currentColor",...t,children:l("path",{d:"M1.5 1.5h21v21h-7v-7h-7v-7h-7zM1.5 15.5h7v7h-7z"})})}function Qi(t){return l("svg",{fill:"currentColor",fillRule:"evenodd",height:"1em",viewBox:"0 0 24 24",width:"1em",...t,children:l("path",{d:"M21.55 10.004a5.416 5.416 0 00-.478-4.501c-1.217-2.09-3.662-3.166-6.05-2.66A5.59 5.59 0 0010.831 1C8.39.995 6.224 2.546 5.473 4.838A5.553 5.553 0 001.76 7.496a5.487 5.487 0 00.691 6.5 5.416 5.416 0 00.477 4.502c1.217 2.09 3.662 3.165 6.05 2.66A5.586 5.586 0 0013.168 23c2.443.006 4.61-1.546 5.361-3.84a5.553 5.553 0 003.715-2.66 5.488 5.488 0 00-.693-6.497v.001zm-8.381 11.558a4.199 4.199 0 01-2.675-.954c.034-.018.093-.05.132-.074l4.44-2.53a.71.71 0 00.364-.623v-6.176l1.877 1.069c.02.01.033.029.036.05v5.115c-.003 2.274-1.87 4.118-4.174 4.123zM4.192 17.78a4.059 4.059 0 01-.498-2.763c.032.02.09.055.131.078l4.44 2.53c.225.13.504.13.73 0l5.42-3.088v2.138a.068.068 0 01-.027.057L9.9 19.288c-1.999 1.136-4.552.46-5.707-1.51h-.001zM3.023 8.216A4.15 4.15 0 015.198 6.41l-.002.151v5.06a.711.711 0 00.364.624l5.42 3.087-1.876 1.07a.067.067 0 01-.063.005l-4.489-2.559c-1.995-1.14-2.679-3.658-1.53-5.63h.001zm15.417 3.54l-5.42-3.088L14.896 7.6a.067.067 0 01.063-.006l4.489 2.557c1.998 1.14 2.683 3.662 1.529 5.633a4.163 4.163 0 01-2.174 1.807V12.38a.71.71 0 00-.363-.623zm1.867-2.773a6.04 6.04 0 00-.132-.078l-4.44-2.53a.731.731 0 00-.729 0l-5.42 3.088V7.325a.068.068 0 01.027-.057L14.1 4.713c2-1.137 4.555-.46 5.707 1.513.487.833.664 1.809.499 2.757h.001zm-11.741 3.81l-1.877-1.068a.065.065 0 01-.036-.051V6.559c.001-2.277 1.873-4.122 4.181-4.12.976 0 1.92.338 2.671.954-.034.018-.092.05-.131.073l-4.44 2.53a.71.71 0 00-.365.623l-.003 6.173v.002zm1.02-2.168L12 9.25l2.414 1.375v2.75L12 14.75l-2.415-1.375v-2.75z"})})}function Ge(t){let a=o();return e("svg",{height:"1em",viewBox:"0 0 24 24",width:"1em",...t,children:[l("defs",{children:e("linearGradient",{id:a,x1:"0%",x2:"100.182%",y1:"50.057%",y2:"50.057%",children:[l("stop",{offset:"0%",stopColor:"#E2167E"}),l("stop",{offset:"100%",stopColor:"#FE603C"})]})}),l("path",{d:"M16.278 2c1.156 0 2.093.927 2.093 2.07v12.501a.74.74 0 00.744.709.74.74 0 00.743-.709V9.099a2.06 2.06 0 012.071-2.049A2.06 2.06 0 0124 9.1v6.561a.649.649 0 01-.652.645.649.649 0 01-.653-.645V9.1a.762.762 0 00-.766-.758.762.762 0 00-.766.758v7.472a2.037 2.037 0 01-2.048 2.026 2.037 2.037 0 01-2.048-2.026v-12.5a.785.785 0 00-.788-.753.785.785 0 00-.789.752l-.001 15.904A2.037 2.037 0 0113.441 22a2.037 2.037 0 01-2.048-2.026V18.04c0-.356.292-.645.652-.645.36 0 .652.289.652.645v1.934c0 .263.142.506.372.638.23.131.514.131.744 0a.734.734 0 00.372-.638V4.07c0-1.143.937-2.07 2.093-2.07zm-5.674 0c1.156 0 2.093.927 2.093 2.07v11.523a.648.648 0 01-.652.645.648.648 0 01-.652-.645V4.07a.785.785 0 00-.789-.78.785.785 0 00-.789.78v14.013a2.06 2.06 0 01-2.07 2.048 2.06 2.06 0 01-2.071-2.048V9.1a.762.762 0 00-.766-.758.762.762 0 00-.766.758v3.8a2.06 2.06 0 01-2.071 2.049A2.06 2.06 0 010 12.9v-1.378c0-.357.292-.646.652-.646.36 0 .653.29.653.646V12.9c0 .418.343.757.766.757s.766-.339.766-.757V9.099a2.06 2.06 0 012.07-2.048 2.06 2.06 0 012.071 2.048v8.984c0 .419.343.758.767.758.423 0 .766-.339.766-.758V4.07c0-1.143.937-2.07 2.093-2.07z",fill:`url(#${a})`,fillRule:"nonzero"})]})}function Ji(t){return e("svg",{height:"1em",viewBox:"0 0 24 24",width:"1em",...t,children:[l("path",{d:"M19.44 10.153l-2.936 11.586a.215.215 0 00.214.261h5.87a.215.215 0 00.214-.261l-2.95-11.586a.214.214 0 00-.412 0zM3.28 12.778l-2.275 8.96A.214.214 0 001.22 22h4.532a.212.212 0 00.214-.165.214.214 0 000-.097l-2.276-8.96a.214.214 0 00-.41 0z",fill:"#00E5E5"}),l("path",{d:"M7.29 5.359L3.148 21.738a.215.215 0 00.203.261h8.29a.214.214 0 00.215-.261L7.7 5.358a.214.214 0 00-.41 0z",fill:"#006EFF"}),l("path",{d:"M14.44.15a.214.214 0 00-.41 0L8.366 21.739a.214.214 0 00.214.261H19.9a.216.216 0 00.171-.078.214.214 0 00.044-.183L14.439.15z",fill:"#006EFF"}),l("path",{d:"M10.278 7.741L6.685 21.736a.214.214 0 00.214.264h7.17a.215.215 0 00.214-.264L10.688 7.741a.214.214 0 00-.41 0z",fill:"#00E5E5"})]})}function _t(t){return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"Doubao"}),l("path",{d:"M5.31 15.756c.172-3.75 1.883-5.999 2.549-6.739-3.26 2.058-5.425 5.658-6.358 8.308v1.12C1.501 21.513 4.226 24 7.59 24a6.59 6.59 0 002.2-.375c.353-.12.7-.248 1.039-.378.913-.899 1.65-1.91 2.243-2.992-4.877 2.431-7.974.072-7.763-4.5l.002.001z",fill:"#1E37FC"}),l("path",{d:"M22.57 10.283c-1.212-.901-4.109-2.404-7.397-2.8.295 3.792.093 8.766-2.1 12.773a12.782 12.782 0 01-2.244 2.992c3.764-1.448 6.746-3.457 8.596-5.219 2.82-2.683 3.353-5.178 3.361-6.66a2.737 2.737 0 00-.216-1.084v-.002z",fill:"#37E1BE"}),l("path",{d:"M14.303 1.867C12.955.7 11.248 0 9.39 0 7.532 0 5.883.677 4.545 1.807 2.791 3.29 1.627 5.557 1.5 8.125v9.201c.932-2.65 3.097-6.25 6.357-8.307.5-.318 1.025-.595 1.569-.829 1.883-.801 3.878-.932 5.746-.706-.222-2.83-.718-5.002-.87-5.617h.001z",fill:"#A569FF"}),l("path",{d:"M17.305 4.961a199.47 199.47 0 01-1.08-1.094c-.202-.213-.398-.419-.586-.622l-1.333-1.378c.151.615.648 2.786.869 5.617 3.288.395 6.185 1.898 7.396 2.8-1.306-1.275-3.475-3.487-5.266-5.323z",fill:"#1E37FC"})]})}function zn(t){return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"Kimi"}),l("rect",{width:"24",height:"24",rx:"5",fill:"#000"}),l("path",{d:"M21.846 0a1.923 1.923 0 110 3.846H20.15a.226.226 0 01-.227-.226V1.923C19.923.861 20.784 0 21.846 0z",fill:"#1783FF"}),l("path",{d:"M11.065 11.199l7.257-7.2c.137-.136.06-.41-.116-.41H14.3a.164.164 0 00-.117.051l-7.82 7.756c-.122.12-.302.013-.302-.179V3.82c0-.127-.083-.23-.185-.23H3.186c-.103 0-.186.103-.186.23V19.77c0 .128.083.23.186.23h2.69c.103 0 .186-.102.186-.23v-3.25c0-.069.025-.135.069-.178l2.424-2.406a.158.158 0 01.205-.023l6.484 4.772a7.677 7.677 0 003.453 1.283c.108.012.2-.095.2-.23v-3.06c0-.117-.07-.212-.164-.227a5.028 5.028 0 01-2.027-.807l-5.613-4.064c-.117-.078-.132-.279-.028-.381z",fill:"#fff"})]})}function Vn(t){let a=o();return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"Zhipu"}),l("defs",{children:e("linearGradient",{id:a,x1:"-18.756%",x2:"70.894%",y1:"49.371%",y2:"90.944%",children:[l("stop",{offset:"0%",stopColor:"#504AF4"}),l("stop",{offset:"100%",stopColor:"#3485FF"})]})}),l("path",{d:"M9.917 2c4.906 0 10.178 3.947 8.93 10.58-.014.07-.037.14-.057.21l-.003-.277c-.083-3-1.534-8.934-8.87-8.934-3.393 0-8.137 3.054-7.93 8.158-.04 4.778 3.555 8.4 7.95 8.332l.073-.001c1.2-.033 2.763-.429 3.1-1.657.063-.031.26.534.268.598.048.256.112.369.192.34.981-.348 2.286-1.222 1.952-2.38-.176-.61-1.775-.147-1.921-.347.418-.979 2.234-.926 3.153-.716.443.102.657.38 1.012.442.29.052.981-.2.96.242-1.5 3.042-4.893 5.41-8.808 5.41C3.654 22 0 16.574 0 11.737 0 5.947 4.959 2 9.917 2zM9.9 5.3c.484 0 1.125.225 1.38.585 3.669.145 4.313 2.686 4.694 5.444.255 1.838.315 2.3.182 1.387l.083.59c.068.448.554.737.982.516.144-.075.254-.231.328-.47a.2.2 0 01.258-.13l.625.22a.2.2 0 01.124.238 2.172 2.172 0 01-.51.92c-.878.917-2.757.664-3.08-.62-.14-.554-.055-.626-.345-1.242-.292-.621-1.238-.709-1.69-.295-.345.315-.407.805-.406 1.282L12.6 15.9a.9.9 0 01-.9.9h-1.4a.9.9 0 01-.9-.9v-.65a1.15 1.15 0 10-2.3 0v.65a.9.9 0 01-.9.9H4.8a.9.9 0 01-.9-.9l.035-3.239c.012-1.884.356-3.658 2.47-4.134.2-.045.252.13.29.342.025.154.043.252.053.294.701 3.058 1.75 4.299 3.144 3.722l.66-.331.254-.13c.158-.082.25-.131.276-.15.012-.01-.165-.206-.407-.464l-1.012-1.067a8.925 8.925 0 01-.199-.216c-.047-.034-.116.068-.208.306-.074.157-.251.252-.272.326-.013.058.108.298.362.72.164.288.22.508-.31.343-1.04-.8-1.518-2.273-1.684-3.725-.004-.035-.162-1.913-.162-1.913a1.2 1.2 0 011.113-1.281L9.9 5.3zm12.994 8.68c.037.697-.403.704-1.213.591l-1.783-.276c-.265-.053-.385-.099-.313-.147.47-.315 3.268-.93 3.31-.168zm-.915-.083l-.926.042c-.85.077-1.452.24.338.336l.103.003c.815.012 1.264-.359.485-.381zm1.667-3.601h.01c.79.398.067 1.03-.65 1.393-.14.07-.491.176-1.052.315-.241.04-.457.092-.333.16l.01.005c1.952.958-3.123 1.534-2.495 1.285l.38-.148c.68-.266 1.614-.682 1.666-1.337.038-.48 1.253-.442 1.493-.968.048-.106 0-.236-.144-.389-.05-.047-.094-.094-.107-.148-.073-.305.7-.431 1.222-.168zm-2.568-.474c-.135 1.198-2.479 4.192-1.949 2.863l.017-.042c.298-.717.376-2.221 1.337-3.221.25-.26.636.035.595.4zm-7.976-.253c.02-.694 1.002-.968 1.346-.347.01-1.274-1.941-.768-1.346.347z",fill:`url(#${a})`,fillRule:"evenodd"})]})}
2
- export{Wi,Un,Bn,Gn,Zi,Qi,Ge,Ji,_t,zn,Vn};
1
+ import{useId as o}from"react";import{jsx as l,jsxs as e}from"react/jsx-runtime";function Ji(t){return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"Claude"}),l("path",{fill:"#D97757",fillRule:"nonzero",d:"M4.709 15.955l4.72-2.647.08-.23-.08-.128H9.2l-.79-.048-2.698-.073-2.339-.097-2.266-.122-.571-.121L0 11.784l.055-.352.48-.321.686.06 1.52.103 2.278.158 1.652.097 2.449.255h.389l.055-.157-.134-.098-.103-.097-2.358-1.596-2.552-1.688-1.336-.972-.724-.491-.364-.462-.158-1.008.656-.722.881.06.225.061.893.686 1.908 1.476 2.491 1.833.365.304.145-.103.019-.073-.164-.274-1.355-2.446-1.446-2.49-.644-1.032-.17-.619a2.97 2.97 0 01-.104-.729L6.283.134 6.696 0l.996.134.42.364.62 1.414 1.002 2.229 1.555 3.03.456.898.243.832.091.255h.158V9.01l.128-1.706.237-2.095.23-2.695.08-.76.376-.91.747-.492.584.28.48.685-.067.444-.286 1.851-.559 2.903-.364 1.942h.212l.243-.242.985-1.306 1.652-2.064.73-.82.85-.904.547-.431h1.033l.76 1.129-.34 1.166-1.064 1.347-.881 1.142-1.264 1.7-.79 1.36.073.11.188-.02 2.856-.606 1.543-.28 1.841-.315.833.388.091.395-.328.807-1.969.486-2.309.462-3.439.813-.042.03.049.061 1.549.146.662.036h1.622l3.02.225.79.522.474.638-.079.485-1.215.62-1.64-.389-3.829-.91-1.312-.329h-.182v.11l1.093 1.068 2.006 1.81 2.509 2.33.127.578-.322.455-.34-.049-2.205-1.657-.851-.747-1.926-1.62h-.128v.17l.444.649 2.345 3.521.122 1.08-.17.353-.608.213-.668-.122-1.374-1.925-1.415-2.167-1.143-1.943-.14.08-.674 7.254-.316.37-.729.28-.607-.461-.322-.747.322-1.476.389-1.924.315-1.53.286-1.9.17-.632-.012-.042-.14.018-1.434 1.967-2.18 2.945-1.726 1.845-.414.164-.717-.37.067-.662.401-.589 2.388-3.036 1.44-1.882.93-1.086-.006-.158h-.055L4.132 18.56l-1.13.146-.487-.456.061-.746.231-.243 1.908-1.312-.006.006z"})]})}function $n(t){return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"DeepSeek"}),l("path",{fill:"#4D6BFE",d:"M23.748 4.482c-.254-.124-.364.113-.512.234-.051.039-.094.09-.137.136-.372.397-.806.657-1.373.626-.829-.046-1.537.214-2.163.848-.133-.782-.575-1.248-1.247-1.548-.352-.156-.708-.311-.955-.65-.172-.241-.219-.51-.305-.774-.055-.16-.11-.323-.293-.35-.2-.031-.278.136-.356.276-.313.572-.434 1.202-.422 1.84.027 1.436.633 2.58 1.838 3.393.137.093.172.187.129.323-.082.28-.18.552-.266.833-.055.179-.137.217-.329.14a5.526 5.526 0 01-1.736-1.18c-.857-.828-1.631-1.742-2.597-2.458a11.365 11.365 0 00-.689-.471c-.985-.957.13-1.743.388-1.836.27-.098.093-.432-.779-.428-.872.004-1.67.295-2.687.684a3.055 3.055 0 01-.465.137 9.597 9.597 0 00-2.883-.102c-1.885.21-3.39 1.102-4.497 2.623C.082 8.606-.231 10.684.152 12.85c.403 2.284 1.569 4.175 3.36 5.653 1.858 1.533 3.997 2.284 6.438 2.14 1.482-.085 3.133-.284 4.994-1.86.47.234.962.327 1.78.397.63.059 1.236-.03 1.705-.128.735-.156.684-.837.419-.961-2.155-1.004-1.682-.595-2.113-.926 1.096-1.296 2.746-2.642 3.392-7.003.05-.347.007-.565 0-.845-.004-.17.035-.237.23-.256a4.173 4.173 0 001.545-.475c1.396-.763 1.96-2.015 2.093-3.517.02-.23-.004-.467-.247-.588zM11.581 18c-2.089-1.642-3.102-2.183-3.52-2.16-.392.024-.321.471-.235.763.09.288.207.486.371.739.114.167.192.416-.113.603-.673.416-1.842-.14-1.897-.167-1.361-.802-2.5-1.86-3.301-3.307-.774-1.393-1.224-2.887-1.298-4.482-.02-.386.093-.522.477-.592a4.696 4.696 0 011.529-.039c2.132.312 3.946 1.265 5.468 2.774.868.86 1.525 1.887 2.202 2.891.72 1.066 1.494 2.082 2.48 2.914.348.292.625.514.891.677-.802.09-2.14.11-3.054-.614zm1-6.44a.306.306 0 01.415-.287.302.302 0 01.2.288.306.306 0 01-.31.307.303.303 0 01-.304-.308zm3.11 1.596c-.2.081-.399.151-.59.16a1.245 1.245 0 01-.798-.254c-.274-.23-.47-.358-.552-.758a1.73 1.73 0 01.016-.588c.07-.327-.008-.537-.239-.727-.187-.156-.426-.199-.688-.199a.559.559 0 01-.254-.078c-.11-.054-.2-.19-.114-.358.028-.054.16-.186.192-.21.356-.202.767-.136 1.146.016.352.144.618.408 1.001.782.391.451.462.576.685.914.176.265.336.537.445.848.067.195-.019.354-.25.452z"})]})}function jn(t){return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",fill:"currentColor",fillRule:"evenodd",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"Grok"}),l("path",{d:"M9.27 15.29l7.978-5.897c.391-.29.95-.177 1.137.272.98 2.369.542 5.215-1.41 7.169-1.951 1.954-4.667 2.382-7.149 1.406l-2.711 1.257c3.889 2.661 8.611 2.003 11.562-.953 2.341-2.344 3.066-5.539 2.388-8.42l.006.007c-.983-4.232.242-5.924 2.75-9.383.06-.082.12-.164.179-.248l-3.301 3.305v-.01L9.267 15.292M7.623 16.723c-2.792-2.67-2.31-6.801.071-9.184 1.761-1.763 4.647-2.483 7.166-1.425l2.705-1.25a7.808 7.808 0 00-1.829-1A8.975 8.975 0 005.984 5.83c-2.533 2.536-3.33 6.436-1.962 9.764 1.022 2.487-.653 4.246-2.34 6.022-.599.63-1.199 1.259-1.682 1.925l7.62-6.815"})]})}var c="M12.604 1.34c.393.69.784 1.382 1.174 2.075a.18.18 0 00.157.091h5.552c.174 0 .322.11.446.327l1.454 2.57c.19.337.24.478.024.837-.26.43-.513.864-.76 1.3l-.367.658c-.106.196-.223.28-.04.512l2.652 4.637c.172.301.111.494-.043.77-.437.785-.882 1.564-1.335 2.34-.159.272-.352.375-.68.37-.777-.016-1.552-.01-2.327.016a.099.099 0 00-.081.05 575.097 575.097 0 01-2.705 4.74c-.169.293-.38.363-.725.364-.997.003-2.002.004-3.017.002a.537.537 0 01-.465-.271l-1.335-2.323a.09.09 0 00-.083-.049H4.982c-.285.03-.553-.001-.805-.092l-1.603-2.77a.543.543 0 01-.002-.54l1.207-2.12a.198.198 0 000-.197 550.951 550.951 0 01-1.875-3.272l-.79-1.395c-.16-.31-.173-.496.095-.965.465-.813.927-1.625 1.387-2.436.132-.234.304-.334.584-.335a338.3 338.3 0 012.589-.001.124.124 0 00.107-.063l2.806-4.895a.488.488 0 01.422-.246c.524-.001 1.053 0 1.583-.006L11.704 1c.341-.003.724.032.9.34zm-3.432.403a.06.06 0 00-.052.03L6.254 6.788a.157.157 0 01-.135.078H3.253c-.056 0-.07.025-.041.074l5.81 10.156c.025.042.013.062-.034.063l-2.795.015a.218.218 0 00-.2.116l-1.32 2.31c-.044.078-.021.118.068.118l5.716.008c.046 0 .08.02.104.061l1.403 2.454c.046.081.092.082.139 0l5.006-8.76.783-1.382a.055.055 0 01.096 0l1.424 2.53a.122.122 0 00.107.062l2.763-.02a.04.04 0 00.035-.02.041.041 0 000-.04l-2.9-5.086a.108.108 0 010-.113l.293-.507 1.12-1.977c.024-.041.012-.062-.035-.062H9.2c-.059 0-.073-.026-.043-.077l1.434-2.505a.107.107 0 000-.114L9.225 1.774a.06.06 0 00-.053-.031zm6.29 8.02c.046 0 .058.02.034.06l-.832 1.465-2.613 4.585a.056.056 0 01-.05.029.058.058 0 01-.05-.029L8.498 9.841c-.02-.034-.01-.052.028-.054l.216-.012 6.722-.012z";function Kn(t){let a=o().replaceAll(":","");return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"Qwen"}),l("path",{d:c,fill:`url(#${a})`,fillRule:"nonzero"}),l("defs",{children:e("linearGradient",{id:a,x1:"0%",x2:"100%",y1:"0%",y2:"0%",children:[l("stop",{offset:"0%",stopColor:"#6336E7",stopOpacity:".84"}),l("stop",{offset:"100%",stopColor:"#6F69F7",stopOpacity:".84"})]})})]})}function Xi(t){return l("svg",{viewBox:"-3 -3 30 30",fill:"currentColor",...t,children:l("path",{d:"M1.5 1.5h21v21h-7v-7h-7v-7h-7zM1.5 15.5h7v7h-7z"})})}function Yi(t){return l("svg",{fill:"currentColor",fillRule:"evenodd",height:"1em",viewBox:"0 0 24 24",width:"1em",...t,children:l("path",{d:"M21.55 10.004a5.416 5.416 0 00-.478-4.501c-1.217-2.09-3.662-3.166-6.05-2.66A5.59 5.59 0 0010.831 1C8.39.995 6.224 2.546 5.473 4.838A5.553 5.553 0 001.76 7.496a5.487 5.487 0 00.691 6.5 5.416 5.416 0 00.477 4.502c1.217 2.09 3.662 3.165 6.05 2.66A5.586 5.586 0 0013.168 23c2.443.006 4.61-1.546 5.361-3.84a5.553 5.553 0 003.715-2.66 5.488 5.488 0 00-.693-6.497v.001zm-8.381 11.558a4.199 4.199 0 01-2.675-.954c.034-.018.093-.05.132-.074l4.44-2.53a.71.71 0 00.364-.623v-6.176l1.877 1.069c.02.01.033.029.036.05v5.115c-.003 2.274-1.87 4.118-4.174 4.123zM4.192 17.78a4.059 4.059 0 01-.498-2.763c.032.02.09.055.131.078l4.44 2.53c.225.13.504.13.73 0l5.42-3.088v2.138a.068.068 0 01-.027.057L9.9 19.288c-1.999 1.136-4.552.46-5.707-1.51h-.001zM3.023 8.216A4.15 4.15 0 015.198 6.41l-.002.151v5.06a.711.711 0 00.364.624l5.42 3.087-1.876 1.07a.067.067 0 01-.063.005l-4.489-2.559c-1.995-1.14-2.679-3.658-1.53-5.63h.001zm15.417 3.54l-5.42-3.088L14.896 7.6a.067.067 0 01.063-.006l4.489 2.557c1.998 1.14 2.683 3.662 1.529 5.633a4.163 4.163 0 01-2.174 1.807V12.38a.71.71 0 00-.363-.623zm1.867-2.773a6.04 6.04 0 00-.132-.078l-4.44-2.53a.731.731 0 00-.729 0l-5.42 3.088V7.325a.068.068 0 01.027-.057L14.1 4.713c2-1.137 4.555-.46 5.707 1.513.487.833.664 1.809.499 2.757h.001zm-11.741 3.81l-1.877-1.068a.065.065 0 01-.036-.051V6.559c.001-2.277 1.873-4.122 4.181-4.12.976 0 1.92.338 2.671.954-.034.018-.092.05-.131.073l-4.44 2.53a.71.71 0 00-.365.623l-.003 6.173v.002zm1.02-2.168L12 9.25l2.414 1.375v2.75L12 14.75l-2.415-1.375v-2.75z"})})}function $e(t){let a=o();return e("svg",{height:"1em",viewBox:"0 0 24 24",width:"1em",...t,children:[l("defs",{children:e("linearGradient",{id:a,x1:"0%",x2:"100.182%",y1:"50.057%",y2:"50.057%",children:[l("stop",{offset:"0%",stopColor:"#E2167E"}),l("stop",{offset:"100%",stopColor:"#FE603C"})]})}),l("path",{d:"M16.278 2c1.156 0 2.093.927 2.093 2.07v12.501a.74.74 0 00.744.709.74.74 0 00.743-.709V9.099a2.06 2.06 0 012.071-2.049A2.06 2.06 0 0124 9.1v6.561a.649.649 0 01-.652.645.649.649 0 01-.653-.645V9.1a.762.762 0 00-.766-.758.762.762 0 00-.766.758v7.472a2.037 2.037 0 01-2.048 2.026 2.037 2.037 0 01-2.048-2.026v-12.5a.785.785 0 00-.788-.753.785.785 0 00-.789.752l-.001 15.904A2.037 2.037 0 0113.441 22a2.037 2.037 0 01-2.048-2.026V18.04c0-.356.292-.645.652-.645.36 0 .652.289.652.645v1.934c0 .263.142.506.372.638.23.131.514.131.744 0a.734.734 0 00.372-.638V4.07c0-1.143.937-2.07 2.093-2.07zm-5.674 0c1.156 0 2.093.927 2.093 2.07v11.523a.648.648 0 01-.652.645.648.648 0 01-.652-.645V4.07a.785.785 0 00-.789-.78.785.785 0 00-.789.78v14.013a2.06 2.06 0 01-2.07 2.048 2.06 2.06 0 01-2.071-2.048V9.1a.762.762 0 00-.766-.758.762.762 0 00-.766.758v3.8a2.06 2.06 0 01-2.071 2.049A2.06 2.06 0 010 12.9v-1.378c0-.357.292-.646.652-.646.36 0 .653.29.653.646V12.9c0 .418.343.757.766.757s.766-.339.766-.757V9.099a2.06 2.06 0 012.07-2.048 2.06 2.06 0 012.071 2.048v8.984c0 .419.343.758.767.758.423 0 .766-.339.766-.758V4.07c0-1.143.937-2.07 2.093-2.07z",fill:`url(#${a})`,fillRule:"nonzero"})]})}function er(t){return e("svg",{height:"1em",viewBox:"0 0 24 24",width:"1em",...t,children:[l("path",{d:"M19.44 10.153l-2.936 11.586a.215.215 0 00.214.261h5.87a.215.215 0 00.214-.261l-2.95-11.586a.214.214 0 00-.412 0zM3.28 12.778l-2.275 8.96A.214.214 0 001.22 22h4.532a.212.212 0 00.214-.165.214.214 0 000-.097l-2.276-8.96a.214.214 0 00-.41 0z",fill:"#00E5E5"}),l("path",{d:"M7.29 5.359L3.148 21.738a.215.215 0 00.203.261h8.29a.214.214 0 00.215-.261L7.7 5.358a.214.214 0 00-.41 0z",fill:"#006EFF"}),l("path",{d:"M14.44.15a.214.214 0 00-.41 0L8.366 21.739a.214.214 0 00.214.261H19.9a.216.216 0 00.171-.078.214.214 0 00.044-.183L14.439.15z",fill:"#006EFF"}),l("path",{d:"M10.278 7.741L6.685 21.736a.214.214 0 00.214.264h7.17a.215.215 0 00.214-.264L10.688 7.741a.214.214 0 00-.41 0z",fill:"#00E5E5"})]})}function Mt(t){return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"Doubao"}),l("path",{d:"M5.31 15.756c.172-3.75 1.883-5.999 2.549-6.739-3.26 2.058-5.425 5.658-6.358 8.308v1.12C1.501 21.513 4.226 24 7.59 24a6.59 6.59 0 002.2-.375c.353-.12.7-.248 1.039-.378.913-.899 1.65-1.91 2.243-2.992-4.877 2.431-7.974.072-7.763-4.5l.002.001z",fill:"#1E37FC"}),l("path",{d:"M22.57 10.283c-1.212-.901-4.109-2.404-7.397-2.8.295 3.792.093 8.766-2.1 12.773a12.782 12.782 0 01-2.244 2.992c3.764-1.448 6.746-3.457 8.596-5.219 2.82-2.683 3.353-5.178 3.361-6.66a2.737 2.737 0 00-.216-1.084v-.002z",fill:"#37E1BE"}),l("path",{d:"M14.303 1.867C12.955.7 11.248 0 9.39 0 7.532 0 5.883.677 4.545 1.807 2.791 3.29 1.627 5.557 1.5 8.125v9.201c.932-2.65 3.097-6.25 6.357-8.307.5-.318 1.025-.595 1.569-.829 1.883-.801 3.878-.932 5.746-.706-.222-2.83-.718-5.002-.87-5.617h.001z",fill:"#A569FF"}),l("path",{d:"M17.305 4.961a199.47 199.47 0 01-1.08-1.094c-.202-.213-.398-.419-.586-.622l-1.333-1.378c.151.615.648 2.786.869 5.617 3.288.395 6.185 1.898 7.396 2.8-1.306-1.275-3.475-3.487-5.266-5.323z",fill:"#1E37FC"})]})}function qn(t){return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"Kimi"}),l("rect",{width:"24",height:"24",rx:"5",fill:"#000"}),l("path",{d:"M21.846 0a1.923 1.923 0 110 3.846H20.15a.226.226 0 01-.227-.226V1.923C19.923.861 20.784 0 21.846 0z",fill:"#1783FF"}),l("path",{d:"M11.065 11.199l7.257-7.2c.137-.136.06-.41-.116-.41H14.3a.164.164 0 00-.117.051l-7.82 7.756c-.122.12-.302.013-.302-.179V3.82c0-.127-.083-.23-.185-.23H3.186c-.103 0-.186.103-.186.23V19.77c0 .128.083.23.186.23h2.69c.103 0 .186-.102.186-.23v-3.25c0-.069.025-.135.069-.178l2.424-2.406a.158.158 0 01.205-.023l6.484 4.772a7.677 7.677 0 003.453 1.283c.108.012.2-.095.2-.23v-3.06c0-.117-.07-.212-.164-.227a5.028 5.028 0 01-2.027-.807l-5.613-4.064c-.117-.078-.132-.279-.028-.381z",fill:"#fff"})]})}function Wn(t){let a=o();return e("svg",{viewBox:"0 0 24 24",width:"1em",height:"1em",xmlns:"http://www.w3.org/2000/svg",...t,children:[l("title",{children:"Zhipu"}),l("defs",{children:e("linearGradient",{id:a,x1:"-18.756%",x2:"70.894%",y1:"49.371%",y2:"90.944%",children:[l("stop",{offset:"0%",stopColor:"#504AF4"}),l("stop",{offset:"100%",stopColor:"#3485FF"})]})}),l("path",{d:"M9.917 2c4.906 0 10.178 3.947 8.93 10.58-.014.07-.037.14-.057.21l-.003-.277c-.083-3-1.534-8.934-8.87-8.934-3.393 0-8.137 3.054-7.93 8.158-.04 4.778 3.555 8.4 7.95 8.332l.073-.001c1.2-.033 2.763-.429 3.1-1.657.063-.031.26.534.268.598.048.256.112.369.192.34.981-.348 2.286-1.222 1.952-2.38-.176-.61-1.775-.147-1.921-.347.418-.979 2.234-.926 3.153-.716.443.102.657.38 1.012.442.29.052.981-.2.96.242-1.5 3.042-4.893 5.41-8.808 5.41C3.654 22 0 16.574 0 11.737 0 5.947 4.959 2 9.917 2zM9.9 5.3c.484 0 1.125.225 1.38.585 3.669.145 4.313 2.686 4.694 5.444.255 1.838.315 2.3.182 1.387l.083.59c.068.448.554.737.982.516.144-.075.254-.231.328-.47a.2.2 0 01.258-.13l.625.22a.2.2 0 01.124.238 2.172 2.172 0 01-.51.92c-.878.917-2.757.664-3.08-.62-.14-.554-.055-.626-.345-1.242-.292-.621-1.238-.709-1.69-.295-.345.315-.407.805-.406 1.282L12.6 15.9a.9.9 0 01-.9.9h-1.4a.9.9 0 01-.9-.9v-.65a1.15 1.15 0 10-2.3 0v.65a.9.9 0 01-.9.9H4.8a.9.9 0 01-.9-.9l.035-3.239c.012-1.884.356-3.658 2.47-4.134.2-.045.252.13.29.342.025.154.043.252.053.294.701 3.058 1.75 4.299 3.144 3.722l.66-.331.254-.13c.158-.082.25-.131.276-.15.012-.01-.165-.206-.407-.464l-1.012-1.067a8.925 8.925 0 01-.199-.216c-.047-.034-.116.068-.208.306-.074.157-.251.252-.272.326-.013.058.108.298.362.72.164.288.22.508-.31.343-1.04-.8-1.518-2.273-1.684-3.725-.004-.035-.162-1.913-.162-1.913a1.2 1.2 0 011.113-1.281L9.9 5.3zm12.994 8.68c.037.697-.403.704-1.213.591l-1.783-.276c-.265-.053-.385-.099-.313-.147.47-.315 3.268-.93 3.31-.168zm-.915-.083l-.926.042c-.85.077-1.452.24.338.336l.103.003c.815.012 1.264-.359.485-.381zm1.667-3.601h.01c.79.398.067 1.03-.65 1.393-.14.07-.491.176-1.052.315-.241.04-.457.092-.333.16l.01.005c1.952.958-3.123 1.534-2.495 1.285l.38-.148c.68-.266 1.614-.682 1.666-1.337.038-.48 1.253-.442 1.493-.968.048-.106 0-.236-.144-.389-.05-.047-.094-.094-.107-.148-.073-.305.7-.431 1.222-.168zm-2.568-.474c-.135 1.198-2.479 4.192-1.949 2.863l.017-.042c.298-.717.376-2.221 1.337-3.221.25-.26.636.035.595.4zm-7.976-.253c.02-.694 1.002-.968 1.346-.347.01-1.274-1.941-.768-1.346.347z",fill:`url(#${a})`,fillRule:"evenodd"})]})}
2
+ export{Ji,$n,jn,Kn,Xi,Yi,$e,er,Mt,qn,Wn};
@@ -1,4 +1,4 @@
1
- var r=new Map,p=new Map,c=new Map;function Di(e,t){if(p.has(e))throw Error("An attachment writer is already registered for this session");return p.set(e,t),()=>{if(p.get(e)===t)p.delete(e)}}function X(e,t){let o=r.get(e);if(!o)return;let n=t(o.attachments);r.set(e,{...o,attachments:n}),p.get(e)?.(n)}function bn(e,t){c.set(e,t),t.finally(()=>{if(c.get(e)===t)c.delete(e)})}async function ga(e){for(;;){let n=r.get(e)?.attachments.flatMap((i)=>{let m=c.get(i.id);return m?[m]:[]})??[];if(!n.length)break;await Promise.all(n)}let t=r.get(e);if(!t)return null;let o=await Promise.all(t.attachments.map(async(n)=>{if(!n.url.startsWith("blob:"))return n;let i=await fetch(n.url);if(!i.ok)throw Error("Cannot read draft image");let m=await i.blob(),f=await new Promise((l,g)=>{let s=new FileReader;s.onload=()=>l(s.result),s.onerror=()=>g(s.error),s.readAsDataURL(m)});return{...n,url:f}}));return{...t,...t.apps?{apps:t.apps.map((n)=>({...n}))}:{},text:t.text,mentions:[...t.mentions],attachments:o,modelId:t.modelId}}function fa(e,t){if(t===null)r.delete(e);else r.set(e,t)}var a=new Map;function Cn(e,t){if(a.has(e))throw Error("A composer is already registered for this session");return a.set(e,t),()=>{if(a.get(e)===t)a.delete(e)}}function ha(e,t){if(typeof t!=="string"||!t.trim())throw Error("The draft is empty");let o=a.get(e);if(!o)throw Error("The session's composer is not open; open the session first");let n=r.get(e);if(n&&(n.text.length||n.attachments.length||n.mentions.length||n.apps?.length))throw Error("The composer already has a draft; send or clear it first");o(t),r.set(e,{text:t,attachments:[],mentions:[],modelId:n?.modelId??null})}function va(e,t){if(typeof t!=="string"||!t.trim())throw Error("The context is empty");let o=a.get(e);if(!o)throw Error("The session's composer is not open; open the session first");let n=r.get(e),i=n?.text?`${n.text}
1
+ var r=new Map,p=new Map,c=new Map;function Bi(e,t){if(p.has(e))throw Error("An attachment writer is already registered for this session");return p.set(e,t),()=>{if(p.get(e)===t)p.delete(e)}}function X(e,t){let o=r.get(e);if(!o)return;let n=t(o.attachments);r.set(e,{...o,attachments:n}),p.get(e)?.(n)}function _n(e,t){c.set(e,t),t.finally(()=>{if(c.get(e)===t)c.delete(e)})}async function xa(e){for(;;){let n=r.get(e)?.attachments.flatMap((i)=>{let m=c.get(i.id);return m?[m]:[]})??[];if(!n.length)break;await Promise.all(n)}let t=r.get(e);if(!t)return null;let o=await Promise.all(t.attachments.map(async(n)=>{if(!n.url.startsWith("blob:"))return n;let i=await fetch(n.url);if(!i.ok)throw Error("Cannot read draft image");let m=await i.blob(),f=await new Promise((l,g)=>{let s=new FileReader;s.onload=()=>l(s.result),s.onerror=()=>g(s.error),s.readAsDataURL(m)});return{...n,url:f}}));return{...t,...t.apps?{apps:t.apps.map((n)=>({...n}))}:{},text:t.text,mentions:[...t.mentions],attachments:o,modelId:t.modelId}}function ba(e,t){if(t===null)r.delete(e);else r.set(e,t)}var a=new Map;function In(e,t){if(a.has(e))throw Error("A composer is already registered for this session");return a.set(e,t),()=>{if(a.get(e)===t)a.delete(e)}}function Ca(e,t){if(typeof t!=="string"||!t.trim())throw Error("The draft is empty");let o=a.get(e);if(!o)throw Error("The session's composer is not open; open the session first");let n=r.get(e);if(n&&(n.text.length||n.attachments.length||n.mentions.length||n.apps?.length))throw Error("The composer already has a draft; send or clear it first");o(t),r.set(e,{text:t,attachments:[],mentions:[],modelId:n?.modelId??null})}function wa(e,t){if(typeof t!=="string"||!t.trim())throw Error("The context is empty");let o=a.get(e);if(!o)throw Error("The session's composer is not open; open the session first");let n=r.get(e),i=n?.text?`${n.text}
2
2
 
3
3
  ${t}`:t;o(i,"append"),r.set(e,n?{...n,text:i}:{text:i,attachments:[],mentions:[],modelId:null})}
4
- export{r,Di,X,bn,ga,fa,Cn,ha,va};
4
+ export{r,Bi,X,_n,xa,ba,In,Ca,wa};
@@ -1,2 +1,2 @@
1
- import{cn as v}from"cn";import{ChevronDownIcon as h,ChevronUpIcon as g,XIcon as b}from"lucide-react";import{useEffect as z,useImperativeHandle as B,useRef as N}from"react";import{Button as i}from"@nyssance/shadcn/vega/components/ui/button";import{Input as E}from"@nyssance/shadcn/vega/components/ui/input";import{jsx as t,jsxs as k}from"react/jsx-runtime";function yr({ref:f,value:r,onChange:p,onFind:o,onClose:s,placeholder:d,autoFocusOpen:a=!0,prevTitle:l,nextTitle:c,className:m}){let n=N(null);B(f,()=>{if(n.current===null)throw Error("FindBar input is not mounted");return n.current},[]),z(()=>{if(!a)return;let e=n.current;if(e===null)throw Error("FindBar input is not mounted");e.focus({preventScroll:!0}),e.select()},[a]);let u=!r;return k("div",{className:v("border-border flex h-9 shrink-0 items-center gap-1 border-b px-2",m),children:[t(E,{ref:n,value:r,onChange:(e)=>p(e.target.value),placeholder:d,className:"h-7 text-xs",onKeyDown:(e)=>{if(e.key==="Escape"){e.preventDefault(),s();return}if(e.key==="Enter"){if(e.preventDefault(),r)o(e.shiftKey)}}}),t(i,{size:"icon",variant:"ghost",className:"size-6",disabled:u,onClick:()=>o(!0),title:l?`${l} (⇧↵)`:"⇧↵",children:t(g,{className:"size-3.5"})}),t(i,{size:"icon",variant:"ghost",className:"size-6",disabled:u,onClick:()=>o(!1),title:c?`${c} (↵)`:"↵",children:t(h,{className:"size-3.5"})}),t(i,{size:"icon",variant:"ghost",className:"size-6",onClick:s,title:"Esc",children:t(b,{className:"size-3.5"})})]})}
2
- export{yr};
1
+ import{cn as v}from"cn";import{ChevronDownIcon as h,ChevronUpIcon as g,XIcon as b}from"lucide-react";import{useEffect as z,useImperativeHandle as B,useRef as N}from"react";import{Button as i}from"@nyssance/shadcn/vega/components/ui/button";import{Input as E}from"@nyssance/shadcn/vega/components/ui/input";import{jsx as t,jsxs as k}from"react/jsx-runtime";function br({ref:f,value:r,onChange:p,onFind:o,onClose:s,placeholder:d,autoFocusOpen:a=!0,prevTitle:l,nextTitle:c,className:m}){let n=N(null);B(f,()=>{if(n.current===null)throw Error("FindBar input is not mounted");return n.current},[]),z(()=>{if(!a)return;let e=n.current;if(e===null)throw Error("FindBar input is not mounted");e.focus({preventScroll:!0}),e.select()},[a]);let u=!r;return k("div",{className:v("border-border flex h-9 shrink-0 items-center gap-1 border-b px-2",m),children:[t(E,{ref:n,value:r,onChange:(e)=>p(e.target.value),placeholder:d,className:"h-7 text-xs",onKeyDown:(e)=>{if(e.key==="Escape"){e.preventDefault(),s();return}if(e.key==="Enter"){if(e.preventDefault(),r)o(e.shiftKey)}}}),t(i,{size:"icon",variant:"ghost",className:"size-6",disabled:u,onClick:()=>o(!0),title:l?`${l} (⇧↵)`:"⇧↵",children:t(g,{className:"size-3.5"})}),t(i,{size:"icon",variant:"ghost",className:"size-6",disabled:u,onClick:()=>o(!1),title:c?`${c} (↵)`:"↵",children:t(h,{className:"size-3.5"})}),t(i,{size:"icon",variant:"ghost",className:"size-6",onClick:s,title:"Esc",children:t(b,{className:"size-3.5"})})]})}
2
+ export{br};
@@ -1,2 +1,2 @@
1
- import{useCallback as S,useLayoutEffect as C,useRef as I,useState as h}from"react";import{jsx as b}from"react/jsx-runtime";var y=30,i=32,g=6;function eo({sessionRows:t,viewport:r,renderRow:u}){let o=I(null),[c,m]=h({start:0,end:g}),[d,R]=h(()=>new Set),[E,M]=h(null),v=S((e,n)=>{R((a)=>{if(a.has(e)===n)return a;let l=new Set(a);if(n)l.add(e);else l.delete(e);return l})},[]),f=S(()=>{if(o.current===null||r===null)return;let e=r.getBoundingClientRect().top+r.clientTop-o.current.getBoundingClientRect().top,n=Math.max(0,Math.min(t.length,Math.floor(e/i)-g)),a=Math.max(n,Math.min(t.length,Math.ceil((e+r.clientHeight)/i)+g));m((l)=>l.start===n&&l.end===a?l:{start:n,end:a})},[t.length,r]);C(()=>f()),C(()=>{if(r===null)return;let e,n=()=>{if(e!==void 0)return;e=requestAnimationFrame(()=>{e=void 0,f()})},a=new ResizeObserver(n);if(a.observe(r),r.firstElementChild)a.observe(r.firstElementChild);return r.addEventListener("scroll",n,{passive:!0}),()=>{if(a.disconnect(),r.removeEventListener("scroll",n),e!==void 0)cancelAnimationFrame(e)}},[f,r]);let s=new Set;for(let e=c.start;e<Math.min(c.end,t.length);e++)s.add(e);if(t.length>0)s.add(0),s.add(t.length-1);if(t.forEach((e,n)=>{if(d.has(e.sessionId))s.add(n);if(E===e.sessionId)for(let a=Math.max(0,n-1);a<=Math.min(t.length-1,n+1);a++)s.add(a)}),t.length===0)return null;return b("div",{ref:o,"data-slot":"virtual-session-rows","data-count":t.length,className:"relative w-full",style:{height:t.length*i-(i-y)},children:[...s].toSorted((e,n)=>e-n).map((e)=>{let n=t[e];return b(T,{sessionRow:n,index:e,retainCard:v,onFocus:M,renderRow:u},n.sessionId)})})}function T({sessionRow:t,index:r,retainCard:u,onFocus:o,renderRow:c}){let m=S((d)=>u(t.sessionId,d),[u,t.sessionId]);return b("div",{"data-slot":"virtual-session-row",className:"absolute inset-x-0",style:{top:r*i,height:y},onFocusCapture:()=>o(t.sessionId),onBlurCapture:(d)=>{if(!d.currentTarget.contains(d.relatedTarget))o(null)},children:c(t,m)})}
2
- export{eo};
1
+ import{useCallback as S,useLayoutEffect as C,useRef as I,useState as h}from"react";import{jsx as b}from"react/jsx-runtime";var y=30,i=32,g=6;function ro({sessionRows:t,viewport:r,renderRow:u}){let o=I(null),[c,m]=h({start:0,end:g}),[d,R]=h(()=>new Set),[E,M]=h(null),v=S((e,n)=>{R((a)=>{if(a.has(e)===n)return a;let l=new Set(a);if(n)l.add(e);else l.delete(e);return l})},[]),f=S(()=>{if(o.current===null||r===null)return;let e=r.getBoundingClientRect().top+r.clientTop-o.current.getBoundingClientRect().top,n=Math.max(0,Math.min(t.length,Math.floor(e/i)-g)),a=Math.max(n,Math.min(t.length,Math.ceil((e+r.clientHeight)/i)+g));m((l)=>l.start===n&&l.end===a?l:{start:n,end:a})},[t.length,r]);C(()=>f()),C(()=>{if(r===null)return;let e,n=()=>{if(e!==void 0)return;e=requestAnimationFrame(()=>{e=void 0,f()})},a=new ResizeObserver(n);if(a.observe(r),r.firstElementChild)a.observe(r.firstElementChild);return r.addEventListener("scroll",n,{passive:!0}),()=>{if(a.disconnect(),r.removeEventListener("scroll",n),e!==void 0)cancelAnimationFrame(e)}},[f,r]);let s=new Set;for(let e=c.start;e<Math.min(c.end,t.length);e++)s.add(e);if(t.length>0)s.add(0),s.add(t.length-1);if(t.forEach((e,n)=>{if(d.has(e.sessionId))s.add(n);if(E===e.sessionId)for(let a=Math.max(0,n-1);a<=Math.min(t.length-1,n+1);a++)s.add(a)}),t.length===0)return null;return b("div",{ref:o,"data-slot":"virtual-session-rows","data-count":t.length,className:"relative w-full",style:{height:t.length*i-(i-y)},children:[...s].toSorted((e,n)=>e-n).map((e)=>{let n=t[e];return b(T,{sessionRow:n,index:e,retainCard:v,onFocus:M,renderRow:u},n.sessionId)})})}function T({sessionRow:t,index:r,retainCard:u,onFocus:o,renderRow:c}){let m=S((d)=>u(t.sessionId,d),[u,t.sessionId]);return b("div",{"data-slot":"virtual-session-row",className:"absolute inset-x-0",style:{top:r*i,height:y},onFocusCapture:()=>o(t.sessionId),onBlurCapture:(d)=>{if(!d.currentTarget.contains(d.relatedTarget))o(null)},children:c(t,m)})}
2
+ export{ro};
@@ -0,0 +1,2 @@
1
+ import{Y}from"./chunk-h71pkpwg.js";import{r,X,_n}from"./chunk-by7k0ypx.js";var Ui=5000;function ot(t){return"pastedText"in t}function kt(t,e,p){let n=(a,o)=>{for(let[i,x]of r){if(!x.attachments.some((s)=>s.id===e.id))continue;X(i,(s)=>s.map((d)=>d.id===e.id?{...e,url:o===void 0?"":Y(o),pastedText:{text:e.pastedText.text,status:a}}:d))}};if(!r.get(t)?.attachments.some((a)=>a.id===e.id))return;n("pending"),_n(e.id,p("pasted-text.txt",e.pastedText.text).then((a)=>n("ready",a)).catch(()=>n("error")))}function Sn(t,e,p,n){if(t.defaultPrevented||t.currentTarget.disabled)return;if([...t.clipboardData.items].some((i)=>i.kind==="file"&&i.type.startsWith("image/")))return;let a=t.clipboardData.getData("text/plain");if(a.length<Ui)return;t.preventDefault(),t.stopPropagation();let o={id:crypto.randomUUID(),type:"file",mediaType:"text/plain",filename:p,url:"",pastedText:{text:a,status:"pending"}};X(e,(i)=>[...i,o]),kt(e,o,n)}
2
+ export{Ui,ot,kt,Sn};
@@ -1,2 +1,2 @@
1
- import{A}from"./chunk-vnd6smsp.js";import{s,h}from"./chunk-0b50jg23.js";import{v,f}from"./chunk-m4ds8kjc.js";import{GlobeIcon as G,LogOutIcon as R}from"lucide-react";import{useRef as k,useState as c}from"react";import{Avatar as T,AvatarFallback as B,AvatarImage as E}from"@nyssance/shadcn/vega/components/ui/avatar";import{DropdownMenu as H,DropdownMenuContent as U,DropdownMenuGroup as d,DropdownMenuItem as F,DropdownMenuLabel as j,DropdownMenuRadioGroup as z,DropdownMenuRadioItem as V,DropdownMenuSeparator as l,DropdownMenuSub as W,DropdownMenuSubContent as _,DropdownMenuSubTrigger as q,DropdownMenuTrigger as J}from"@nyssance/shadcn/vega/components/ui/dropdown-menu";import{jsx as o,jsxs as n}from"react/jsx-runtime";function Ns(e){return o(d,{...e})}function As(e){return o(l,{...e})}function ti({className:e,...r}){return o(F,{className:["h-[var(--navigation-row-height,30px)] py-0 [&_svg]:text-muted-foreground",e].filter(Boolean).join(" "),...r})}function Es({languages:e,value:r,onChange:i}){let a=s();return n(W,{children:[n(q,{className:"h-[var(--navigation-row-height,30px)] py-0",children:[o(G,{className:"text-muted-foreground"}),a.t("sessionList.language")]}),o(_,{children:o(z,{value:r,onValueChange:(t)=>void h(a,Promise.resolve(i(t))),children:e.map((t)=>o(V,{value:t.code,children:t.label},t.code))})})]})}function Rs({user:e,children:r,onSignOut:i,busy:a=!1}){let t=s(),{t:C}=t,[g,L]=c(!1),[S,m]=c(!1),M=k(null),[w,O]=c({width:0,offset:0}),P=(x)=>{if(x){let p=M.current,u=p?.closest("[data-sidebar-footer-row]");if(!p||!u)throw Error("AccountMenu must sit in a [data-sidebar-footer-row] row");let y=u.getBoundingClientRect(),N=p.getBoundingClientRect(),I=getComputedStyle(u).direction==="rtl";O({width:u.clientWidth,offset:I?y.right-N.right:N.left-y.left})}L(x)};A(g);let b=a||S,D=n(T,{className:"size-[18px] after:border-0",children:[o(E,{src:e.avatar??void 0,alt:""}),o(B,{className:"bg-primary text-primary-foreground text-xs",children:[...e.name].slice(0,2).join("").toLocaleUpperCase()})]});return n(H,{open:g,onOpenChange:P,children:[n(J,{ref:M,render:o(f,{disabled:b,className:"text-muted-foreground hover:bg-foreground/8 data-popup-open:bg-foreground/5 font-normal"}),children:[o(v,{children:D}),o("span",{className:"min-w-0 truncate",children:e.name})]}),n(U,{side:"top",align:"start",alignOffset:-w.offset,sideOffset:8,style:{width:w.width},children:[n(d,{children:[n(j,{className:"text-popover-foreground flex items-center gap-2 px-2 py-2 text-sm font-medium",children:[o(v,{children:D}),n("span",{className:"min-w-0 flex-1",children:[o("span",{className:"block truncate",children:e.name}),o("span",{className:"text-muted-foreground mt-0.5 block truncate text-xs font-normal",children:e.email})]})]}),o(l,{})]}),r,r!=null&&o(l,{}),o(d,{children:n(ti,{disabled:b,onClick:()=>{m(!0),h(t,i()).finally(()=>m(!1))},children:[o(R,{}),C("sessionList.signOut")]})})]})]})}
2
- export{Ns,As,ti,Es,Rs};
1
+ import{E}from"./chunk-q8y2a23c.js";import{s,h}from"./chunk-pxbww0j1.js";import{v,f}from"./chunk-95f0wens.js";import{GlobeIcon as I,LogOutIcon as G}from"lucide-react";import{useRef as R,useState as c}from"react";import{Avatar as k,AvatarFallback as T,AvatarImage as B}from"@nyssance/shadcn/vega/components/ui/avatar";import{DropdownMenu as H,DropdownMenuContent as U,DropdownMenuGroup as d,DropdownMenuItem as F,DropdownMenuLabel as j,DropdownMenuRadioGroup as z,DropdownMenuRadioItem as V,DropdownMenuSeparator as l,DropdownMenuSub as W,DropdownMenuSubContent as _,DropdownMenuSubTrigger as q,DropdownMenuTrigger as J}from"@nyssance/shadcn/vega/components/ui/dropdown-menu";import{jsx as o,jsxs as n}from"react/jsx-runtime";function Ds(e){return o(d,{...e})}function Fs(e){return o(l,{...e})}function si({className:e,...r}){return o(F,{className:["h-[var(--navigation-row-height,30px)] py-0 [&_svg]:text-muted-foreground",e].filter(Boolean).join(" "),...r})}function Os({languages:e,value:r,onChange:i}){let a=s();return n(W,{children:[n(q,{className:"h-[var(--navigation-row-height,30px)] py-0",children:[o(I,{className:"text-muted-foreground"}),a.t("sessionList.language")]}),o(_,{children:o(z,{value:r,onValueChange:(t)=>void h(a,Promise.resolve(i(t))),children:e.map((t)=>o(V,{value:t.code,children:t.label},t.code))})})]})}function Hs({user:e,children:r,onSignOut:i,busy:a=!1}){let t=s(),{t:N}=t,[g,C]=c(!1),[L,m]=c(!1),M=R(null),[w,S]=c({width:0,offset:0}),O=(x)=>{if(x){let p=M.current,u=p?.closest("[data-sidebar-footer-row]");if(!p||!u)throw Error("AccountMenu must sit in a [data-sidebar-footer-row] row");let y=u.getBoundingClientRect(),A=p.getBoundingClientRect(),P=getComputedStyle(u).direction==="rtl";S({width:u.clientWidth,offset:P?y.right-A.right:A.left-y.left})}C(x)};E(g);let b=a||L,D=n(k,{className:"size-[18px] after:border-0",children:[o(B,{src:e.avatar??void 0,alt:""}),o(T,{className:"bg-primary text-primary-foreground text-xs",children:[...e.name].slice(0,2).join("").toLocaleUpperCase()})]});return n(H,{open:g,onOpenChange:O,children:[n(J,{ref:M,render:o(f,{disabled:b,className:"text-muted-foreground hover:bg-foreground/8 data-popup-open:bg-foreground/5 font-normal"}),children:[o(v,{children:D}),o("span",{className:"min-w-0 truncate",children:e.name})]}),n(U,{side:"top",align:"start",alignOffset:-w.offset,sideOffset:8,style:{width:w.width},children:[n(d,{children:[n(j,{className:"text-popover-foreground flex items-center gap-2 px-2 py-2 text-sm font-medium",children:[o(v,{children:D}),n("span",{className:"min-w-0 flex-1",children:[o("span",{className:"block truncate",children:e.name}),o("span",{className:"text-muted-foreground mt-0.5 block truncate text-xs font-normal",children:e.email})]})]}),o(l,{})]}),r,r!=null&&o(l,{}),o(d,{children:n(si,{disabled:b,onClick:()=>{m(!0),h(t,i()).finally(()=>m(!1))},children:[o(G,{}),N("sessionList.signOut")]})})]})]})}
2
+ export{Ds,Fs,si,Os,Hs};