@alwith/module-chat 0.5.10 → 0.5.11

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 (306) hide show
  1. package/dist/activity-host.js +1 -1
  2. package/dist/approval/choice-elicitation-form.js +1 -1
  3. package/dist/approval/choice-schema.js +1 -1
  4. package/dist/approval/permission-options.js +1 -1
  5. package/dist/approval/permission-view.js +1 -1
  6. package/dist/approval/schema-elicitation-form.js +1 -1
  7. package/dist/approval/url-elicitation-card.js +1 -1
  8. package/dist/{chunk-pmpeh7e8.js → chunk-0d4xsx23.js} +2 -2
  9. package/dist/{chunk-8tn17nw7.js → chunk-0gwe31zs.js} +2 -2
  10. package/dist/chunk-0kwfy29d.js +2 -0
  11. package/dist/{chunk-951wn2bd.js → chunk-0n240acr.js} +2 -2
  12. package/dist/{chunk-vdeh7n7d.js → chunk-0yvbqccv.js} +2 -2
  13. package/dist/chunk-133f0wed.js +2 -0
  14. package/dist/{chunk-et0rpfh9.js → chunk-17zegmxa.js} +1 -1
  15. package/dist/{chunk-9bjywaze.js → chunk-1drkvxzk.js} +1 -1
  16. package/dist/{chunk-gajhc4bp.js → chunk-20svvgj3.js} +2 -2
  17. package/dist/{chunk-rmv0t2ee.js → chunk-294gms5s.js} +2 -2
  18. package/dist/{chunk-ybwgmphj.js → chunk-2pha46d9.js} +1 -1
  19. package/dist/{chunk-dzx4rypz.js → chunk-30wqrz8v.js} +2 -2
  20. package/dist/chunk-31x6chk8.js +2 -0
  21. package/dist/{chunk-2879v3ps.js → chunk-377s443r.js} +2 -2
  22. package/dist/chunk-3e0mfcj6.js +2 -0
  23. package/dist/chunk-3vrtepy0.js +3 -0
  24. package/dist/chunk-443z7mve.js +2 -0
  25. package/dist/{chunk-ptws0wtt.js → chunk-460phps1.js} +2 -2
  26. package/dist/chunk-4b3s7gyc.js +3 -0
  27. package/dist/chunk-4nh3xzrm.js +2 -0
  28. package/dist/{chunk-jbz530rv.js → chunk-4svcj9c6.js} +2 -2
  29. package/dist/{chunk-5f4m4ptz.js → chunk-50qyant6.js} +3 -3
  30. package/dist/chunk-51sbmqdk.js +2 -0
  31. package/dist/chunk-5ev4qvsp.js +2 -0
  32. package/dist/chunk-5fgakrmr.js +2 -0
  33. package/dist/{chunk-k583q9wq.js → chunk-5hsmhj1g.js} +3 -3
  34. package/dist/chunk-5kpcpjrb.js +4 -0
  35. package/dist/{chunk-erzjz56d.js → chunk-5m4605a3.js} +1 -1
  36. package/dist/{chunk-xv3qen27.js → chunk-5w92bzgs.js} +2 -2
  37. package/dist/chunk-64whvkk0.js +2 -0
  38. package/dist/{chunk-nsns7rgs.js → chunk-6amcjhqh.js} +2 -2
  39. package/dist/{chunk-y0ppdmcv.js → chunk-6d7ppje3.js} +2 -2
  40. package/dist/{chunk-dnhmnmgf.js → chunk-6edz9f7j.js} +2 -2
  41. package/dist/{chunk-akcs13sj.js → chunk-6pmc9283.js} +2 -2
  42. package/dist/{chunk-bm4s6n8a.js → chunk-6ss1981q.js} +2 -2
  43. package/dist/{chunk-x66yhg5y.js → chunk-728v2as1.js} +2 -2
  44. package/dist/{chunk-kgkrtc3r.js → chunk-7a6t282a.js} +1 -1
  45. package/dist/chunk-7drq0g9b.js +2 -0
  46. package/dist/{chunk-9h86hvc3.js → chunk-7dzq2t68.js} +2 -2
  47. package/dist/{chunk-tjhwk02y.js → chunk-7h8pv9eg.js} +1 -1
  48. package/dist/{chunk-9cbpmdqf.js → chunk-7jdazbzv.js} +2 -2
  49. package/dist/{chunk-wp673je0.js → chunk-7k0wvvy0.js} +1 -1
  50. package/dist/{chunk-5nqhvv28.js → chunk-88xay4pa.js} +2 -2
  51. package/dist/{chunk-j8fybkv1.js → chunk-91x8etvh.js} +2 -2
  52. package/dist/{chunk-wzjq9j6g.js → chunk-93x6b2qa.js} +3 -3
  53. package/dist/chunk-96xwaa2t.js +2 -0
  54. package/dist/{chunk-rqnvygqy.js → chunk-9a4kjze3.js} +6 -6
  55. package/dist/chunk-9tdzg6e6.js +2 -0
  56. package/dist/{chunk-gc1m6aw5.js → chunk-a3krtv66.js} +2 -2
  57. package/dist/{chunk-vpt3vyfc.js → chunk-abwjd5yv.js} +2 -2
  58. package/dist/{chunk-tc85dd04.js → chunk-ak0k5vg6.js} +1 -1
  59. package/dist/chunk-aprxk7c2.js +2 -0
  60. package/dist/chunk-b4dsjhkq.js +2 -0
  61. package/dist/{chunk-rawfwgmw.js → chunk-b65vdzz3.js} +1 -1
  62. package/dist/chunk-bhze2sjv.js +2 -0
  63. package/dist/{chunk-vyf9wx2w.js → chunk-c0ac9k7h.js} +2 -2
  64. package/dist/{chunk-eg1d1gbc.js → chunk-cgqhz23q.js} +2 -2
  65. package/dist/{chunk-7awdgc0t.js → chunk-cjztkcsm.js} +2 -2
  66. package/dist/{chunk-1k1e55de.js → chunk-cke0v0a7.js} +1 -1
  67. package/dist/{chunk-3wg25354.js → chunk-cpk3y6ad.js} +2 -2
  68. package/dist/chunk-d84cxw1v.js +2 -0
  69. package/dist/chunk-dp8pjv6r.js +2 -0
  70. package/dist/{chunk-kathd6f3.js → chunk-e11qjnb4.js} +2 -2
  71. package/dist/chunk-e55zxnda.js +2 -0
  72. package/dist/{chunk-kjtd3wc3.js → chunk-ek06eyp4.js} +1 -1
  73. package/dist/chunk-f1zvbkak.js +2 -0
  74. package/dist/{chunk-76xfekar.js → chunk-f4h7yb7d.js} +2 -2
  75. package/dist/chunk-fe3c678p.js +2 -0
  76. package/dist/{chunk-s4tydqhr.js → chunk-g7p46jq1.js} +2 -2
  77. package/dist/{chunk-0fr24sxr.js → chunk-gj3j9zh5.js} +3 -3
  78. package/dist/{chunk-6z9r27t2.js → chunk-gzff19t3.js} +2 -2
  79. package/dist/chunk-ha5jfz6r.js +4 -0
  80. package/dist/{chunk-r828rqdv.js → chunk-hjnf5kvc.js} +2 -2
  81. package/dist/{chunk-t1yd4a57.js → chunk-hrsz92yq.js} +1 -1
  82. package/dist/{chunk-v2bbgpvw.js → chunk-hxhptw6e.js} +2 -2
  83. package/dist/{chunk-ct5wk01a.js → chunk-j2wtwb37.js} +3 -3
  84. package/dist/chunk-j2wty8a3.js +2 -0
  85. package/dist/chunk-jhk2chpp.js +2 -0
  86. package/dist/{chunk-5c4z345j.js → chunk-jn0q0b7k.js} +2 -2
  87. package/dist/{chunk-rw9bsnyp.js → chunk-k3375qqd.js} +2 -2
  88. package/dist/{chunk-bhrnw36x.js → chunk-k5c82xk9.js} +2 -2
  89. package/dist/{chunk-r55p44ys.js → chunk-kahn24np.js} +2 -2
  90. package/dist/{chunk-grncrd31.js → chunk-knsf6jm1.js} +2 -2
  91. package/dist/{chunk-vxm45kym.js → chunk-krmz8t4p.js} +2 -2
  92. package/dist/{chunk-5d94195x.js → chunk-ksv9pjc2.js} +1 -1
  93. package/dist/chunk-m28hdj8j.js +2 -0
  94. package/dist/{chunk-34a7aha4.js → chunk-m6rrt94g.js} +2 -2
  95. package/dist/chunk-m8djwdd5.js +2 -0
  96. package/dist/{chunk-d8rf7rff.js → chunk-m99k3e5h.js} +2 -2
  97. package/dist/{chunk-anshr0mw.js → chunk-magaaqab.js} +1 -1
  98. package/dist/{chunk-f4e289mj.js → chunk-mgtkmbmd.js} +2 -2
  99. package/dist/{chunk-0sdhavk8.js → chunk-mt965yn0.js} +2 -2
  100. package/dist/{chunk-xjtqdp82.js → chunk-ncekagm6.js} +1 -1
  101. package/dist/{chunk-vvk1knxf.js → chunk-nkypxxjk.js} +1 -1
  102. package/dist/chunk-p1ydsj54.js +2 -0
  103. package/dist/{chunk-9w0w5by0.js → chunk-p8nx34zm.js} +2 -2
  104. package/dist/chunk-p8qgqtkc.js +2 -0
  105. package/dist/chunk-q905xt4v.js +2 -0
  106. package/dist/{chunk-wqrn3428.js → chunk-qah4fs3d.js} +1 -1
  107. package/dist/{chunk-b616t3fp.js → chunk-qj63fv6w.js} +2 -2
  108. package/dist/{chunk-4t6bd8j7.js → chunk-qnk5jk1b.js} +2 -2
  109. package/dist/chunk-qpc4ca5y.js +2 -0
  110. package/dist/chunk-qw0jp3wm.js +2 -0
  111. package/dist/{chunk-zbnjrtye.js → chunk-r79zqx0t.js} +5 -5
  112. package/dist/{chunk-94r5frad.js → chunk-rnykpmn2.js} +2 -2
  113. package/dist/{chunk-r67bkrmr.js → chunk-rnzphmk6.js} +2 -2
  114. package/dist/{chunk-zse2yz8e.js → chunk-rszktjdw.js} +3 -3
  115. package/dist/{chunk-46gb51y9.js → chunk-ryz4c13z.js} +2 -2
  116. package/dist/{chunk-13y1xqbb.js → chunk-sex6d2c2.js} +2 -2
  117. package/dist/{chunk-83dkw1mh.js → chunk-sr5rcdza.js} +2 -2
  118. package/dist/{chunk-btjqewxj.js → chunk-svt0t387.js} +2 -2
  119. package/dist/{chunk-12swy4za.js → chunk-syffw61b.js} +4 -4
  120. package/dist/{chunk-y8qmxd0j.js → chunk-t3ew92b3.js} +2 -2
  121. package/dist/{chunk-rg5vskrr.js → chunk-t6t6hgzx.js} +2 -2
  122. package/dist/{chunk-bq05e911.js → chunk-tjgq4882.js} +2 -2
  123. package/dist/{chunk-b81yxz7f.js → chunk-tv89wh8b.js} +2 -2
  124. package/dist/{chunk-gthvary5.js → chunk-vv1ghqq3.js} +1 -1
  125. package/dist/{chunk-2ymhbrf9.js → chunk-w43dvzqk.js} +3 -3
  126. package/dist/chunk-w6hhyjcn.js +2 -0
  127. package/dist/{chunk-fjwg3y8h.js → chunk-w8qmh6he.js} +2 -2
  128. package/dist/{chunk-7q07tm0w.js → chunk-wb3zpzk3.js} +1 -1
  129. package/dist/chunk-xh8wth6z.js +2 -0
  130. package/dist/{chunk-64hrczd9.js → chunk-xxkdv1zf.js} +1 -1
  131. package/dist/chunk-y3qgsj79.js +2 -0
  132. package/dist/{chunk-gq30yqjk.js → chunk-ynw0f8h2.js} +2 -2
  133. package/dist/chunk-ysc51tpb.js +2 -0
  134. package/dist/{chunk-115a3p9z.js → chunk-zbtas7pt.js} +2 -2
  135. package/dist/{chunk-90c0tynf.js → chunk-znx2e9e7.js} +2 -2
  136. package/dist/chunk-zt8qaqbz.js +2 -0
  137. package/dist/{chunk-2pj3pcc7.js → chunk-zz734bzf.js} +2 -2
  138. package/dist/codex/activity-group.js +1 -1
  139. package/dist/codex/assistant-message.js +1 -1
  140. package/dist/codex/async-question-card.js +1 -1
  141. package/dist/codex/disclosure-state.js +1 -1
  142. package/dist/codex/edited-files-card.js +1 -1
  143. package/dist/codex/image-view-activity.js +1 -1
  144. package/dist/codex/markdown-renderer.js +1 -1
  145. package/dist/codex/navigation-audio.js +1 -1
  146. package/dist/codex/navigation-preview.js +1 -1
  147. package/dist/codex/navigation-rail.js +1 -1
  148. package/dist/codex/patch-view.js +1 -1
  149. package/dist/codex/plan.js +1 -1
  150. package/dist/codex/timeline-virtualizer.js +1 -1
  151. package/dist/codex/turn-activity.js +1 -1
  152. package/dist/codex/user-message.js +1 -1
  153. package/dist/codex/virtualized-turn-list.js +1 -1
  154. package/dist/composer/completion-filter.js +1 -1
  155. package/dist/composer/completion-menu.js +1 -1
  156. package/dist/composer/completion-trigger.js +1 -1
  157. package/dist/composer/effort-slider.js +1 -1
  158. package/dist/composer/menu-radio.js +1 -1
  159. package/dist/composer/model-select.js +1 -1
  160. package/dist/composer/permission-mode-select.js +1 -1
  161. package/dist/composer/prompt-input-attachments.js +1 -1
  162. package/dist/composer/prompt-input-clipboard.js +1 -1
  163. package/dist/composer/prompt-input-context.js +1 -1
  164. package/dist/composer/prompt-input-textarea.js +1 -1
  165. package/dist/composer/prompt-input.js +1 -1
  166. package/dist/conversation/action-card.js +1 -1
  167. package/dist/conversation/composer/composer.js +1 -1
  168. package/dist/conversation/composer/config-options.js +1 -1
  169. package/dist/conversation/composer/context.js +1 -1
  170. package/dist/conversation/composer/drafts.js +1 -1
  171. package/dist/conversation/composer/file-items.js +1 -1
  172. package/dist/conversation/composer/long-text.js +1 -1
  173. package/dist/conversation/composer/mention-chips.js +1 -1
  174. package/dist/conversation/composer/mention-uri.js +1 -1
  175. package/dist/conversation/composer/model-menu.js +1 -1
  176. package/dist/conversation/composer/pasted-text-attachment.js +1 -1
  177. package/dist/conversation/composer/permission-mode-menu.js +1 -1
  178. package/dist/conversation/composer/prediction.js +1 -1
  179. package/dist/conversation/composer/slash-command-button.js +1 -1
  180. package/dist/conversation/composer/submit-button.js +1 -1
  181. package/dist/conversation/composer/usage-meter.js +1 -1
  182. package/dist/conversation/context.js +1 -1
  183. package/dist/conversation/conversation-body.js +1 -1
  184. package/dist/conversation/conversation-view.js +1 -1
  185. package/dist/conversation/conversation.js +1 -1
  186. package/dist/conversation/diff-modal.js +1 -1
  187. package/dist/conversation/session-actions.js +1 -1
  188. package/dist/image-lightbox.js +1 -1
  189. package/dist/image-preview-dialog.js +1 -1
  190. package/dist/lib/code-highlighter.js +1 -1
  191. package/dist/lib/fuzzy.js +1 -1
  192. package/dist/lib/group-blocks.js +1 -1
  193. package/dist/lib/image-encode.js +1 -1
  194. package/dist/lib/limits.js +1 -1
  195. package/dist/lib/markdown-parser.js +1 -1
  196. package/dist/lib/markdown-parser.worker.js +43 -39
  197. package/dist/lib/markdown-rules.js +1 -1
  198. package/dist/lib/model-name.js +1 -1
  199. package/dist/lib/pointer-centered-zoom.js +1 -1
  200. package/dist/lib/prepare-prompt-files.js +1 -1
  201. package/dist/lib/stream-style.js +1 -1
  202. package/dist/lib/streaming-markdown.js +1 -1
  203. package/dist/search/chat-search.js +1 -1
  204. package/dist/search/dom-matches.js +1 -1
  205. package/dist/search/find-bar.js +1 -1
  206. package/dist/search/literal-matches.js +1 -1
  207. package/dist/session-list/archived-sessions.js +1 -1
  208. package/dist/session-list/highlight.js +1 -1
  209. package/dist/session-list/host.js +1 -1
  210. package/dist/session-list/hover-info-card.js +1 -1
  211. package/dist/session-list/navigation.js +1 -1
  212. package/dist/session-list/overflow-marquee.js +1 -1
  213. package/dist/session-list/row-stop-button.js +1 -1
  214. package/dist/session-list/session-groups.js +1 -1
  215. package/dist/session-list/session-info-card.js +1 -1
  216. package/dist/session-list/session-list.js +1 -1
  217. package/dist/session-list/session-row.js +1 -1
  218. package/dist/session-list/session-state-dot.js +1 -1
  219. package/dist/session-list/session-state-menu.js +1 -1
  220. package/dist/session-list/sidebar-overlay.js +1 -1
  221. package/dist/session-list/trailing-swap.js +1 -1
  222. package/dist/session-list/use-activity-preview.js +1 -1
  223. package/dist/session-list/use-project-sessions.js +1 -1
  224. package/dist/session-list/virtual-session-rows.js +1 -1
  225. package/dist/session-timeline/activity-group.js +1 -1
  226. package/dist/session-timeline/activity-projection.js +1 -1
  227. package/dist/session-timeline/assistant-content.js +1 -1
  228. package/dist/session-timeline/assistant-turn.js +1 -1
  229. package/dist/session-timeline/async-questions.js +1 -1
  230. package/dist/session-timeline/edited-files-card.js +1 -1
  231. package/dist/session-timeline/history-timeline.js +1 -1
  232. package/dist/session-timeline/host.js +1 -1
  233. package/dist/session-timeline/navigation-rail.js +1 -1
  234. package/dist/session-timeline/plan.js +1 -1
  235. package/dist/session-timeline/question-reply.js +1 -1
  236. package/dist/session-timeline/resource-content.js +1 -1
  237. package/dist/session-timeline/session-timeline.js +1 -1
  238. package/dist/session-timeline/timeline-registry.js +1 -1
  239. package/dist/session-timeline/turn-activity.js +1 -1
  240. package/dist/session-timeline/turn-error.js +1 -1
  241. package/dist/session-timeline/turn-retry.js +1 -1
  242. package/dist/session-timeline/turn-time.js +1 -1
  243. package/dist/session-timeline/turns.js +1 -1
  244. package/dist/session-timeline/use-timeline-scroll.js +1 -1
  245. package/dist/session-timeline/user-message.js +1 -1
  246. package/dist/ui/alert.js +1 -1
  247. package/dist/ui/badge.js +1 -1
  248. package/dist/ui/card.js +1 -1
  249. package/dist/ui/checkbox.js +1 -1
  250. package/dist/ui/dialog.js +1 -1
  251. package/dist/ui/dropdown-menu.js +1 -1
  252. package/dist/ui/empty.js +1 -1
  253. package/dist/ui/field.js +1 -1
  254. package/dist/ui/hover-card.js +1 -1
  255. package/dist/ui/input-group-textarea.js +1 -1
  256. package/dist/ui/input-group.js +1 -1
  257. package/dist/ui/kbd.js +1 -1
  258. package/dist/ui/label.js +1 -1
  259. package/dist/ui/radio-group.js +1 -1
  260. package/dist/ui/select.js +1 -1
  261. package/dist/ui/separator.js +1 -1
  262. package/dist/ui/skeleton.js +1 -1
  263. package/dist/ui/spinner.js +1 -1
  264. package/dist/ui/switch.js +1 -1
  265. package/dist/ui/textarea.js +1 -1
  266. package/dist/ui/tooltip.js +1 -1
  267. package/package.json +5 -5
  268. package/dist/chunk-1jzxmw98.js +0 -2
  269. package/dist/chunk-1wxebrbt.js +0 -2
  270. package/dist/chunk-1xg1qw4g.js +0 -4
  271. package/dist/chunk-3g8ck68k.js +0 -2
  272. package/dist/chunk-3xnbypjz.js +0 -2
  273. package/dist/chunk-4ecdn9z1.js +0 -2
  274. package/dist/chunk-60ks28ef.js +0 -2
  275. package/dist/chunk-62x983rq.js +0 -2
  276. package/dist/chunk-6f2h379x.js +0 -2
  277. package/dist/chunk-6xp64b2e.js +0 -2
  278. package/dist/chunk-78x93ef2.js +0 -2
  279. package/dist/chunk-7e1m1d9x.js +0 -2
  280. package/dist/chunk-8dtaq4eh.js +0 -2
  281. package/dist/chunk-9tgtskz4.js +0 -2
  282. package/dist/chunk-a7nqzhxj.js +0 -2
  283. package/dist/chunk-aafg3jqm.js +0 -3
  284. package/dist/chunk-b8ywzj88.js +0 -2
  285. package/dist/chunk-b9ew8dwr.js +0 -2
  286. package/dist/chunk-cc6vp2sg.js +0 -2
  287. package/dist/chunk-ckft9abb.js +0 -2
  288. package/dist/chunk-fb6vxbmc.js +0 -2
  289. package/dist/chunk-fcyzhbmn.js +0 -2
  290. package/dist/chunk-fw3emcqw.js +0 -2
  291. package/dist/chunk-h7ks1p6h.js +0 -2
  292. package/dist/chunk-j4cm74nv.js +0 -4
  293. package/dist/chunk-jegkf64h.js +0 -2
  294. package/dist/chunk-jjtgsnj0.js +0 -2
  295. package/dist/chunk-jnrcqphc.js +0 -2
  296. package/dist/chunk-jyy20tw1.js +0 -2
  297. package/dist/chunk-k7wta28t.js +0 -2
  298. package/dist/chunk-ksmcznp2.js +0 -3
  299. package/dist/chunk-m2ab6p4w.js +0 -2
  300. package/dist/chunk-n89jvr5q.js +0 -2
  301. package/dist/chunk-nvya2g1d.js +0 -2
  302. package/dist/chunk-s1z1418w.js +0 -2
  303. package/dist/chunk-sgy6b5me.js +0 -2
  304. package/dist/chunk-sk14wfkj.js +0 -2
  305. package/dist/chunk-sx4fhs54.js +0 -2
  306. package/dist/chunk-vmcxp5e2.js +0 -2
@@ -1,5 +1,5 @@
1
- import{Bt}from"./chunk-5f4m4ptz.js";import{t}from"./chunk-3g8ck68k.js";import{isDiffEntry as p}from"@nyssance/codex-acp-v2/client";import{jsx as f,jsxs as g,Fragment as h}from"react/jsx-runtime";function Nr(o,s){let e=o.split(/^(?=diff --git )/m).filter((i)=>i.length>0);if(e.length<=1)return o;return e.find((i)=>{let a=i.split(`
2
- `,1)[0]??"";return a.endsWith(` b/${s}`)||a.endsWith(` ${s}`)||a.includes(`/${s} `)})??o}function Mr(o){let s=new Map,e=null;for(let n of o.split(`
3
- `)){if(n.startsWith("diff --git ")){e=null;continue}if(n.startsWith("+++ ")){let i=n.slice(4).trim(),a=i==="/dev/null"?null:i.replace(/^b\//,"");if(a!==null)e={additions:0,deletions:0},s.set(a,e);continue}if(n.startsWith("--- ")){let i=n.slice(4).trim();if(i!=="/dev/null"&&e===null)e={additions:0,deletions:0},s.set(i.replace(/^a\//,""),e);continue}if(e===null)continue;if(n.startsWith("+"))e.additions+=1;else if(n.startsWith("-"))e.deletions+=1}return s}function u(o,s){let e=s.replaceAll("\\","/");for(let[n,i]of o)if(e===n||e.endsWith(`/${n}`))return i;return{additions:0,deletions:0}}function Rr(o){let s=new Map;for(let e of o)for(let n of e.content){if(!p(n))continue;let i=n.patch?Mr(n.patch.text):new Map;for(let a of n.changes){let r=typeof a.path==="string"?a.path:null;if(r===null)continue;let c=u(i,r),d=n.patch?Nr(n.patch.text,r):"",l=s.get(r);if(l)l.additions+=c.additions,l.deletions+=c.deletions,l.patch=l.patch?`${l.patch}
4
- ${d}`:d;else s.set(r,{path:r,patch:d,...c})}}return[...s.values()]}function Dn({items:o}){let s=t(),{openDiff:e,FileIcon:n}=s;return f(Bt,{files:Rr(o),onOpen:e===void 0?void 0:(i)=>e({path:i.path,patch:i.patch}),renderPath:n===void 0?void 0:(i)=>g(h,{children:[f(n,{path:i.path,className:"codex-edited-file-icon"}),f("span",{className:"codex-edited-file-name",children:i.path})]})})}
5
- export{Nr,Mr,Rr,Dn};
1
+ import{Ut}from"./chunk-50qyant6.js";import{t}from"./chunk-dp8pjv6r.js";import{isDiffEntry as p}from"@nyssance/codex-acp-v2/client";import{jsx as f,jsxs as g,Fragment as h}from"react/jsx-runtime";function Dr(o,s){let e=o.split(/^(?=diff --git )/m).filter((i)=>i.length>0);if(e.length<=1)return o;return e.find((i)=>{let a=i.split(`
2
+ `,1)[0]??"";return a.endsWith(` b/${s}`)||a.endsWith(` ${s}`)||a.includes(`/${s} `)})??o}function _r(o){let s=new Map,e=null;for(let n of o.split(`
3
+ `)){if(n.startsWith("diff --git ")){e=null;continue}if(n.startsWith("+++ ")){let i=n.slice(4).trim(),a=i==="/dev/null"?null:i.replace(/^b\//,"");if(a!==null)e={additions:0,deletions:0},s.set(a,e);continue}if(n.startsWith("--- ")){let i=n.slice(4).trim();if(i!=="/dev/null"&&e===null)e={additions:0,deletions:0},s.set(i.replace(/^a\//,""),e);continue}if(e===null)continue;if(n.startsWith("+"))e.additions+=1;else if(n.startsWith("-"))e.deletions+=1}return s}function u(o,s){let e=s.replaceAll("\\","/");for(let[n,i]of o)if(e===n||e.endsWith(`/${n}`))return i;return{additions:0,deletions:0}}function Hr(o){let s=new Map;for(let e of o)for(let n of e.content){if(!p(n))continue;let i=n.patch?_r(n.patch.text):new Map;for(let a of n.changes){let r=typeof a.path==="string"?a.path:null;if(r===null)continue;let c=u(i,r),d=n.patch?Dr(n.patch.text,r):"",l=s.get(r);if(l)l.additions+=c.additions,l.deletions+=c.deletions,l.patch=l.patch?`${l.patch}
4
+ ${d}`:d;else s.set(r,{path:r,patch:d,...c})}}return[...s.values()]}function uo({items:o}){let s=t(),{openDiff:e,FileIcon:n}=s;return f(Ut,{files:Hr(o),onOpen:e===void 0?void 0:(i)=>e({path:i.path,patch:i.patch}),renderPath:n===void 0?void 0:(i)=>g(h,{children:[f(n,{path:i.path,className:"codex-edited-file-icon"}),f("span",{className:"codex-edited-file-name",children:i.path})]})})}
5
+ export{Dr,_r,Hr,uo};
@@ -1,2 +1,2 @@
1
- import{jo,Ko}from"./chunk-wqrn3428.js";import{cn as l}from"cn";import{jsx as t,jsxs as a}from"react/jsx-runtime";function f({value:i,onValueChange:n,options:o,itemClassName:d}){return t(jo,{value:i,onValueChange:(e)=>n(String(e)),children:o.map((e)=>a(Ko,{value:e.value,disabled:e.disabled,title:e.title,closeOnClick:!0,className:l("gap-2",e.description?"items-start":"items-center",d),children:[e.icon,e.description?a("div",{className:"min-w-0 flex-1",children:[t("div",{className:"text-xs font-medium",children:e.label}),t("div",{className:"text-muted-foreground text-[11px] font-normal",children:e.description})]}):t("span",{className:"min-w-0 flex-1 truncate text-start",children:e.label})]},e.value))})}
2
- export{f};
1
+ import{Uo,$o}from"./chunk-qah4fs3d.js";import{cn as l}from"cn";import{jsx as t,jsxs as a}from"react/jsx-runtime";function h({value:i,onValueChange:n,options:o,itemClassName:d}){return t(Uo,{value:i,onValueChange:(e)=>n(String(e)),children:o.map((e)=>a($o,{value:e.value,disabled:e.disabled,title:e.title,closeOnClick:!0,className:l("gap-2",e.description?"items-start":"items-center",d),children:[e.icon,e.description?a("div",{className:"min-w-0 flex-1",children:[t("div",{className:"text-xs font-medium",children:e.label}),t("div",{className:"text-muted-foreground text-[11px] font-normal",children:e.description})]}):t("span",{className:"min-w-0 flex-1 truncate text-start",children:e.label})]},e.value))})}
2
+ export{h};
@@ -1,2 +1,2 @@
1
- import{nativeTurnId as a}from"@nyssance/codex-acp-v2/client";function Pn(o,i){let u=new Set,s=(e)=>{let t=e.items.map(a).find((r)=>r!==null),n=e.items.every((r)=>r.replayed);if(t===void 0||u.has(t))return{turnKey:e.key,turn:e,deferUntilReady:n};return u.add(t),{turnKey:`history:${t}`,aliases:[e.key],turn:e,deferUntilReady:n}};if(!i?.complete)return o.map(s);let d=new Map;for(let e of o){let t=e.items.map(a).find((r)=>r!==null);if(t===void 0)continue;let n=d.get(t)??[];n.push(e),d.set(t,n)}let l=new Set(i.turns.map((e)=>e.turnId)),y=new Set(i.loadedTurnIds);return[...i.turns.flatMap((e)=>{let t=d.get(e.turnId);if(t)return t.map(s);return y.has(e.turnId)?[]:[{turnKey:`history:${e.turnId}`,nativeTurnId:e.turnId,estimatedHeightPx:320,placeholder:!0}]}),...o.filter((e)=>!e.items.some((t)=>l.has(a(t)??""))).map(s)]}
2
- export{Pn};
1
+ import{nativeTurnId as a}from"@nyssance/codex-acp-v2/client";function no(o,i){let u=new Set,s=(e)=>{let t=e.items.map(a).find((r)=>r!==null),n=e.items.every((r)=>r.replayed);if(t===void 0||u.has(t))return{turnKey:e.key,turn:e,deferUntilReady:n};return u.add(t),{turnKey:`history:${t}`,aliases:[e.key],turn:e,deferUntilReady:n}};if(!i?.complete)return o.map(s);let d=new Map;for(let e of o){let t=e.items.map(a).find((r)=>r!==null);if(t===void 0)continue;let n=d.get(t)??[];n.push(e),d.set(t,n)}let l=new Set(i.turns.map((e)=>e.turnId)),y=new Set(i.loadedTurnIds);return[...i.turns.flatMap((e)=>{let t=d.get(e.turnId);if(t)return t.map(s);return y.has(e.turnId)?[]:[{turnKey:`history:${e.turnId}`,nativeTurnId:e.turnId,estimatedHeightPx:320,placeholder:!0}]}),...o.filter((e)=>!e.items.some((t)=>l.has(a(t)??""))).map(s)]}
2
+ export{no};
@@ -1,4 +1,4 @@
1
- import{sn}from"./chunk-1wxebrbt.js";import{Io,Po,ut}from"./chunk-jegkf64h.js";import{Ae,y}from"./chunk-3wg25354.js";import{cn as w}from"cn";import{forwardRef as A,useCallback as D,useEffect as M,useImperativeHandle as K,useRef as f}from"react";import{jsx as F}from"react/jsx-runtime";var L=(i)=>!i.shiftKey,R=()=>!1,Vt=A(({onChange:i,onCompositionStart:g,onCompositionEnd:v,className:x,placeholder:T,bashMode:b=!1,isSendShortcut:E=L,isNewlineShortcut:I=R,...C},H)=>{let n=Ae(),l=y(),o=f(!1),u=f(!1),r=f(null),s=D(()=>{let e=r.current;if(!e||o.current)return;e.style.height="auto",e.style.height=`${e.scrollHeight}px`},[]);M(()=>{let e=r.current;if(!e)return;let t=new ResizeObserver(()=>{requestAnimationFrame(s)});return t.observe(e),()=>t.disconnect()},[s]);let c=b&&(n?.textInput.value??"").startsWith("!"),P=(e)=>{if(o.current||e.nativeEvent.isComposing||e.nativeEvent.keyCode===229||u.current)return;if(e.key.length===1&&e.key.charCodeAt(0)<32&&e.key!==`
1
+ import{an}from"./chunk-qpc4ca5y.js";import{Ao,Lo,ct}from"./chunk-96xwaa2t.js";import{Ue,y}from"./chunk-cpk3y6ad.js";import{cn as w}from"cn";import{forwardRef as A,useCallback as D,useEffect as M,useImperativeHandle as K,useRef as f}from"react";import{jsx as F}from"react/jsx-runtime";var L=(i)=>!i.shiftKey,R=()=>!1,Yt=A(({onChange:i,onCompositionStart:g,onCompositionEnd:v,className:x,placeholder:T,bashMode:b=!1,isSendShortcut:E=L,isNewlineShortcut:I=R,...C},H)=>{let n=Ue(),l=y(),o=f(!1),u=f(!1),r=f(null),s=D(()=>{let e=r.current;if(!e||o.current)return;e.style.height="auto",e.style.height=`${e.scrollHeight}px`},[]);M(()=>{let e=r.current;if(!e)return;let t=new ResizeObserver(()=>{requestAnimationFrame(s)});return t.observe(e),()=>t.disconnect()},[s]);let c=b&&(n?.textInput.value??"").startsWith("!"),P=(e)=>{if(o.current||e.nativeEvent.isComposing||e.nativeEvent.keyCode===229||u.current)return;if(e.key.length===1&&e.key.charCodeAt(0)<32&&e.key!==`
2
2
  `&&e.key!=="\r"&&e.key!=="\t"){e.preventDefault();return}if(c&&n){let t=e.currentTarget.selectionStart===0&&e.currentTarget.selectionEnd===0;if(e.key==="Escape"||(e.key==="Backspace"||e.key==="Delete")&&t){e.preventDefault(),n.textInput.setInput(n.textInput.value.slice(1));return}}if(e.key==="Enter"){if(I(e.nativeEvent)){e.preventDefault();let t=e.currentTarget,{selectionStart:a,selectionEnd:m,value:p}=t,d=`${p.slice(0,a)}
3
- ${p.slice(m)}`;if(n)n.textInput.setInput(d);else t.value=d;let h=a+1;t.setSelectionRange(h,h),s();return}if(E(e.nativeEvent)){e.preventDefault();let t=e.currentTarget.form;if(!t)return;let a=t.querySelector('button[type="submit"]');if(!a||a.disabled)return;t.requestSubmit(a)}}if(e.key==="Backspace"&&e.currentTarget.value===""&&l.files.length>0){e.preventDefault();let t=l.files.at(-1);if(t)l.remove(t.id)}},S=(e)=>{let t=e.clipboardData?.items;if(!t)return;let{imageFiles:a,sawNonImageFile:m}=Io(t),p=Po(t);if(a.length>0)e.preventDefault(),l.add(a);else if(m&&!p)e.preventDefault()},k=n?{value:o.current&&r.current?r.current.value:c?n.textInput.value.slice(1):n.textInput.value,onChange:(e)=>{let t=o.current?e.currentTarget.value:ut(e.currentTarget);n.textInput.setInput(c?`!${t}`:t),s(),i?.(e)}}:{onChange:(e)=>{if(!o.current)ut(e.currentTarget);s(),i?.(e)}};return K(H,()=>({resetHeight:()=>{if(r.current)r.current.style.height="auto"},focus:()=>{r.current?.focus()},isComposing:()=>o.current||u.current,getTextarea:()=>r.current}),[]),F(sn,{"data-chat-input":!0,ref:r,rows:3,className:w("field-sizing-content max-h-(--chat-input-max-height) min-h-[calc(var(--chat-input-line-height)*3)] min-w-0 flex-1 overflow-x-hidden","leading-(--chat-input-line-height)","placeholder:text-chat-input-placeholder p-0 pe-2.5","bg-chat-input-bg",x),name:"message",onCompositionEnd:(e)=>{o.current=!1;let t=ut(e.currentTarget);n?.textInput.setInput(c?`!${t}`:t),s(),v?.(e),u.current=!0,requestAnimationFrame(()=>{u.current=!1})},onCompositionStart:(e)=>{u.current=!1,o.current=!0,g?.(e)},onKeyDown:P,onPaste:S,placeholder:T,...C,...k})});Vt.displayName="PromptInputTextarea";
4
- export{Vt};
3
+ ${p.slice(m)}`;if(n)n.textInput.setInput(d);else t.value=d;let h=a+1;t.setSelectionRange(h,h),s();return}if(E(e.nativeEvent)){e.preventDefault();let t=e.currentTarget.form;if(!t)return;let a=t.querySelector('button[type="submit"]');if(!a||a.disabled)return;t.requestSubmit(a)}}if(e.key==="Backspace"&&e.currentTarget.value===""&&l.files.length>0){e.preventDefault();let t=l.files.at(-1);if(t)l.remove(t.id)}},S=(e)=>{let t=e.clipboardData?.items;if(!t)return;let{imageFiles:a,sawNonImageFile:m}=Ao(t),p=Lo(t);if(a.length>0)e.preventDefault(),l.add(a);else if(m&&!p)e.preventDefault()},k=n?{value:o.current&&r.current?r.current.value:c?n.textInput.value.slice(1):n.textInput.value,onChange:(e)=>{let t=o.current?e.currentTarget.value:ct(e.currentTarget);n.textInput.setInput(c?`!${t}`:t),s(),i?.(e)}}:{onChange:(e)=>{if(!o.current)ct(e.currentTarget);s(),i?.(e)}};return K(H,()=>({resetHeight:()=>{if(r.current)r.current.style.height="auto"},focus:()=>{r.current?.focus()},isComposing:()=>o.current||u.current,getTextarea:()=>r.current}),[]),F(an,{"data-chat-input":!0,ref:r,rows:3,className:w("field-sizing-content max-h-(--chat-input-max-height) min-h-[calc(var(--chat-input-line-height)*3)] min-w-0 flex-1 overflow-x-hidden","leading-(--chat-input-line-height)","placeholder:text-chat-input-placeholder p-0 pe-2.5","bg-chat-input-bg",x),name:"message",onCompositionEnd:(e)=>{o.current=!1;let t=ct(e.currentTarget);n?.textInput.setInput(c?`!${t}`:t),s(),v?.(e),u.current=!0,requestAnimationFrame(()=>{u.current=!1})},onCompositionStart:(e)=>{u.current=!1,o.current=!0,g?.(e)},onKeyDown:P,onPaste:S,placeholder:T,...C,...k})});Yt.displayName="PromptInputTextarea";
4
+ export{Yt};
@@ -1,2 +1,2 @@
1
- import{createContext as i,useContext as r}from"react";import{jsx as e}from"react/jsx-runtime";var n=i(null);function fo({host:t,children:o}){return e(n.Provider,{value:t,children:o})}function a(){let t=r(n);if(t===null)throw Error("Activity host is missing");return t}function g(t){let{Markdown:o}=a();return e(o,{...t})}
2
- export{fo,a,g};
1
+ import{createContext as i,useContext as r}from"react";import{jsx as e}from"react/jsx-runtime";var n=i(null);function sr({host:t,children:o}){return e(n.Provider,{value:t,children:o})}function a(){let t=r(n);if(t===null)throw Error("Activity host is missing");return t}function v(t){let{Markdown:o}=a();return e(o,{...t})}
2
+ export{sr,a,v};
@@ -1,2 +1,2 @@
1
- import{$o}from"./chunk-y8qmxd0j.js";import{d,Yo,u,m}from"./chunk-et0rpfh9.js";import{cn as M}from"cn";import{XIcon as L}from"lucide-react";import{useCallback as O,useEffect as z,useMemo as j,useRef as H,useState as S}from"react";import{jsx as i,jsxs as A}from"react/jsx-runtime";function Uo({open:l,onOpenChange:P,url:h,filename:x,scale:v,onScaleChange:p,containerRef:T,containerClassName:I,dialogContentClassName:R,imageClassName:W}){let g=O((e)=>Math.min(4,Math.max(0.25,e)),[]),[Z,C]=S(1),o=g(v??Z),k=H(null),s=T??k,D=H(null),[f,N]=S({width:0,height:0}),[y,E]=S({width:0,height:0}),b=O((e)=>{let n=g(e);if(typeof p==="function"){p(n);return}C(n)},[p,g]);z(()=>{if(!l)return;if(!h)return;if(typeof v==="number")return;C(1)},[l,h,v]),z(()=>{if(!l)return;let e=s.current;if(!e)return;let n=()=>{N({width:e.clientWidth,height:e.clientHeight})};n();let t=new ResizeObserver(n);return t.observe(e),()=>{t.disconnect()}},[s,l]);let X=O(()=>{b(1)},[b]),r=j(()=>{let{width:e,height:n}=y,{width:t,height:a}=f;if(e===0||n===0)return{width:0,height:0};if(t===0||a===0)return{width:0,height:0};let c=Math.min(t/e,a/n,1),w=e*c,_=n*c;return{width:w*o,height:_*o}},[o,y,f]);if(!h)return null;return i(d,{open:l,onOpenChange:P,children:A(u,{className:M("top-1/2 left-1/2 h-[90vh] max-h-[90vh] w-[90vw]! max-w-[90vw]! -translate-x-1/2 -translate-y-1/2 gap-0 rounded-none bg-transparent p-0 ring-0 sm:w-[90vw]! sm:max-w-[90vw]!",R),showCloseButton:!1,children:[i(m,{className:"sr-only",children:x||"Image preview"}),i(Yo,{"aria-label":"Close",className:"absolute top-3 right-3 z-10 flex size-10 items-center justify-center rounded-full bg-black/55 text-white backdrop-blur-sm transition-colors hover:bg-black/75",children:i(L,{className:"size-5"})}),i("div",{ref:s,onWheel:(e)=>{if(!e.ctrlKey&&!e.metaKey)return;e.preventDefault();let n=e.deltaY>0?o-0.2:o+0.2,t=g(Number.parseFloat(n.toFixed(2)));if(t===o)return;let a=s.current,c=D.current,w=a&&c?$o({container:a,target:c,clientX:e.clientX,clientY:e.clientY,currentScale:o,nextScale:t}):null;if(b(t),a&&w)requestAnimationFrame(()=>{a.scrollTo(w)})},className:M("h-full w-full scrollbar-thin overflow-auto",I),children:i("div",{className:"grid min-h-full min-w-full place-items-center",style:{width:Math.max(f.width,r.width),height:Math.max(f.height,r.height)},children:i("div",{className:"shrink-0",children:i("img",{alt:x||"image preview",className:M("block object-contain select-none",W),decoding:"async",draggable:!1,ref:D,onDoubleClick:X,onLoad:(e)=>{let n=e.currentTarget;E({width:n.naturalWidth,height:n.naturalHeight});let t=s.current;if(t&&(t.clientWidth||t.clientHeight))N({width:t.clientWidth,height:t.clientHeight})},style:{imageRendering:"auto",width:r.width||void 0,height:r.height||void 0,maxWidth:r.width?"none":"90vw",maxHeight:r.height?"none":"90vh"},src:h})})})})]})})}
2
- export{Uo};
1
+ import{Ho}from"./chunk-t3ew92b3.js";import{d,rr,u,m}from"./chunk-17zegmxa.js";import{cn as M}from"cn";import{XIcon as L}from"lucide-react";import{useCallback as O,useEffect as z,useMemo as j,useRef as H,useState as S}from"react";import{jsx as i,jsxs as A}from"react/jsx-runtime";function Do({open:l,onOpenChange:P,url:h,filename:x,scale:v,onScaleChange:p,containerRef:T,containerClassName:I,dialogContentClassName:R,imageClassName:W}){let g=O((e)=>Math.min(4,Math.max(0.25,e)),[]),[Z,C]=S(1),o=g(v??Z),k=H(null),s=T??k,D=H(null),[f,N]=S({width:0,height:0}),[y,E]=S({width:0,height:0}),b=O((e)=>{let n=g(e);if(typeof p==="function"){p(n);return}C(n)},[p,g]);z(()=>{if(!l)return;if(!h)return;if(typeof v==="number")return;C(1)},[l,h,v]),z(()=>{if(!l)return;let e=s.current;if(!e)return;let n=()=>{N({width:e.clientWidth,height:e.clientHeight})};n();let t=new ResizeObserver(n);return t.observe(e),()=>{t.disconnect()}},[s,l]);let X=O(()=>{b(1)},[b]),r=j(()=>{let{width:e,height:n}=y,{width:t,height:a}=f;if(e===0||n===0)return{width:0,height:0};if(t===0||a===0)return{width:0,height:0};let c=Math.min(t/e,a/n,1),w=e*c,_=n*c;return{width:w*o,height:_*o}},[o,y,f]);if(!h)return null;return i(d,{open:l,onOpenChange:P,children:A(u,{className:M("top-1/2 left-1/2 h-[90vh] max-h-[90vh] w-[90vw]! max-w-[90vw]! -translate-x-1/2 -translate-y-1/2 gap-0 rounded-none bg-transparent p-0 ring-0 sm:w-[90vw]! sm:max-w-[90vw]!",R),showCloseButton:!1,children:[i(m,{className:"sr-only",children:x||"Image preview"}),i(rr,{"aria-label":"Close",className:"absolute top-3 right-3 z-10 flex size-10 items-center justify-center rounded-full bg-black/55 text-white backdrop-blur-sm transition-colors hover:bg-black/75",children:i(L,{className:"size-5"})}),i("div",{ref:s,onWheel:(e)=>{if(!e.ctrlKey&&!e.metaKey)return;e.preventDefault();let n=e.deltaY>0?o-0.2:o+0.2,t=g(Number.parseFloat(n.toFixed(2)));if(t===o)return;let a=s.current,c=D.current,w=a&&c?Ho({container:a,target:c,clientX:e.clientX,clientY:e.clientY,currentScale:o,nextScale:t}):null;if(b(t),a&&w)requestAnimationFrame(()=>{a.scrollTo(w)})},className:M("h-full w-full scrollbar-thin overflow-auto",I),children:i("div",{className:"grid min-h-full min-w-full place-items-center",style:{width:Math.max(f.width,r.width),height:Math.max(f.height,r.height)},children:i("div",{className:"shrink-0",children:i("img",{alt:x||"image preview",className:M("block object-contain select-none",W),decoding:"async",draggable:!1,ref:D,onDoubleClick:X,onLoad:(e)=>{let n=e.currentTarget;E({width:n.naturalWidth,height:n.naturalHeight});let t=s.current;if(t&&(t.clientWidth||t.clientHeight))N({width:t.clientWidth,height:t.clientHeight})},style:{imageRendering:"auto",width:r.width||void 0,height:r.height||void 0,maxWidth:r.width?"none":"90vw",maxHeight:r.height?"none":"90vh"},src:h})})})})]})})}
2
+ export{Do};
@@ -1,2 +1,2 @@
1
- import{co}from"./chunk-951wn2bd.js";import{CheckIcon as N,ChevronDownIcon as E,CopyIcon as T,FileIcon as w}from"lucide-react";import{useEffect as k,useLayoutEffect as H,useRef as I,useState as f}from"react";import{jsx as e,jsxs as p,Fragment as h}from"react/jsx-runtime";var A=20,L='a[href], area[href], button, input, select, textarea, summary, audio[controls], video[controls], iframe, [contenteditable]:not([contenteditable="false"]), [tabindex]:not([tabindex="-1"])';function y(n,o,s){if(n.toggleAttribute("inert",!o),!o){n.setAttribute("aria-hidden","true");return}if(s===null)n.removeAttribute("aria-hidden");else n.setAttribute("aria-hidden",s)}function R(n,o){let s=n.getBoundingClientRect(),a=o.getBoundingClientRect();return s.top>=a.top&&s.right<=a.right&&s.bottom<=a.bottom&&s.left>=a.left}function M({text:n,host:o}){let{t:s,Markdown:a}=o,c=I(null),[l,u]=f(!1),[d,x]=f(!1);return H(()=>{let r=c.current;if(!r)throw Error("Codex user message content is missing");let t=()=>{if(r.scrollHeight===0){u(!1);return}let b=Number.parseFloat(getComputedStyle(r).lineHeight);if(!Number.isFinite(b))throw Error("Codex user message line height is invalid");u(r.scrollHeight>A*b+1)};t();let m=new ResizeObserver(t);return m.observe(r),()=>m.disconnect()},[]),k(()=>{if(!l||d)return;let r=c.current;if(!r)throw Error("Codex user message content is missing");let t=new Map,m=typeof IntersectionObserver>"u"?null:new IntersectionObserver((i)=>{for(let g of i){let v=g.target;if(!t.has(v))continue;y(v,g.isIntersecting&&g.intersectionRatio>=1,t.get(v))}},{root:r,rootMargin:"0px",threshold:1}),b=()=>{for(let i of t.keys()){if(r.contains(i))continue;m?.unobserve(i),t.delete(i)}for(let i of r.querySelectorAll(L)){if(t.has(i)||i.hasAttribute("inert"))continue;let g=i.getAttribute("aria-hidden");t.set(i,g),y(i,m===null&&R(i,r),g),m?.observe(i)}};b();let C=new MutationObserver(b);return C.observe(r,{childList:!0,subtree:!0}),()=>{m?.disconnect(),C.disconnect();for(let[i,g]of t)y(i,!0,g)}},[l,d]),p("div",{className:"codex-user-message-content",children:[e("div",{ref:c,className:l&&!d?"codex-user-message-text codex-user-message-text-collapsed":"codex-user-message-text",children:e(a,{text:n,streaming:!1})}),l&&!d&&e("span",{className:"codex-user-message-ellipsis","aria-hidden":"true",children:"…"}),l&&p("button",{type:"button","aria-expanded":d,className:"codex-user-message-collapse-trigger",onClick:()=>{x((r)=>!r)},children:[e("span",{children:d?s("stream.codex.showLess"):s("stream.codex.showMore")}),e(E,{className:d?"codex-user-message-collapse-chevron codex-user-message-collapse-chevron-expanded":"codex-user-message-collapse-chevron","aria-hidden":"true"})]})]})}function Ot({text:n,label:o,host:s}){let[a,c]=f(!1),[l,u]=f(null),d=async()=>{c(!1),u(null);try{await(s?.copyText?s.copyText(n):navigator.clipboard.writeText(n)),c(!0),setTimeout(()=>c(!1),2000)}catch(x){u(String(x)),s?.onCopyError?.(x)}};return e("button",{type:"button",className:"codex-message-action","aria-label":o,title:l??o,onClick:()=>void d(),children:a?e(N,{className:"codex-message-action-confirmed"}):e(T,{})})}function S({image:n,openImage:o}){let[s,a]=f(!1),c=`data:${n.mimeType};base64,${n.data}`;return p(h,{children:[e("button",{type:"button",className:"codex-user-image",onClick:()=>o===void 0?a(!0):o(c),children:e("img",{src:c,alt:""})}),s&&e(co,{src:c,alt:"",onClose:()=>a(!1)})]})}function lo({message:n,text:o,textParts:s,mentions:a,images:c,messageTime:l,host:u,bubbleStyle:d}){let{t:x,openImage:r}=u;return e("div",{"data-content-search-unit-key":n.id,"data-message-id":n.id,className:"timeline-break codex-user-message scroll-mt-4",children:p("div",{className:"group/codex-user codex-user-message-group",children:[a.length>0&&e("div",{className:"codex-user-mentions",children:a.map((t)=>p("span",{className:"codex-user-mention",title:t.title,children:[e(w,{"aria-hidden":"true"}),e("span",{className:"codex-user-mention-label",children:t.label})]},t.key))}),c.length>0&&e("div",{className:"codex-user-images",children:c.map((t)=>e(S,{image:t,openImage:r},`${t.mimeType}:${t.data}`))}),o.length>0&&e(h,{children:e("div",{"data-user-message-bubble":!0,tabIndex:0,className:"codex-user-bubble",style:d,children:s?s.map((t,m)=>e("div",{className:"codex-user-text-part",children:t.question===void 0?e(M,{text:t.text,host:u}):p(h,{children:[e("div",{className:"codex-user-question-summary",title:t.question,children:t.question}),e("div",{className:"codex-user-question-answer",children:t.text})]})},m)):e(M,{text:o,host:u})})}),p("div",{className:"codex-user-actions",children:[e(Ot,{text:o,label:x("actions.copy"),host:u}),l&&e("span",{className:"codex-user-time",title:l.full,children:l.short})]})]})})}
2
- export{Ot,lo};
1
+ import{go}from"./chunk-0n240acr.js";import{CheckIcon as N,ChevronDownIcon as E,CopyIcon as T,FileIcon as w}from"lucide-react";import{useEffect as k,useLayoutEffect as H,useRef as I,useState as f}from"react";import{jsx as e,jsxs as p,Fragment as h}from"react/jsx-runtime";var A=20,L='a[href], area[href], button, input, select, textarea, summary, audio[controls], video[controls], iframe, [contenteditable]:not([contenteditable="false"]), [tabindex]:not([tabindex="-1"])';function y(n,o,s){if(n.toggleAttribute("inert",!o),!o){n.setAttribute("aria-hidden","true");return}if(s===null)n.removeAttribute("aria-hidden");else n.setAttribute("aria-hidden",s)}function R(n,o){let s=n.getBoundingClientRect(),a=o.getBoundingClientRect();return s.top>=a.top&&s.right<=a.right&&s.bottom<=a.bottom&&s.left>=a.left}function M({text:n,host:o}){let{t:s,Markdown:a}=o,c=I(null),[l,u]=f(!1),[d,x]=f(!1);return H(()=>{let r=c.current;if(!r)throw Error("Codex user message content is missing");let t=()=>{if(r.scrollHeight===0){u(!1);return}let b=Number.parseFloat(getComputedStyle(r).lineHeight);if(!Number.isFinite(b))throw Error("Codex user message line height is invalid");u(r.scrollHeight>A*b+1)};t();let m=new ResizeObserver(t);return m.observe(r),()=>m.disconnect()},[]),k(()=>{if(!l||d)return;let r=c.current;if(!r)throw Error("Codex user message content is missing");let t=new Map,m=typeof IntersectionObserver>"u"?null:new IntersectionObserver((i)=>{for(let g of i){let v=g.target;if(!t.has(v))continue;y(v,g.isIntersecting&&g.intersectionRatio>=1,t.get(v))}},{root:r,rootMargin:"0px",threshold:1}),b=()=>{for(let i of t.keys()){if(r.contains(i))continue;m?.unobserve(i),t.delete(i)}for(let i of r.querySelectorAll(L)){if(t.has(i)||i.hasAttribute("inert"))continue;let g=i.getAttribute("aria-hidden");t.set(i,g),y(i,m===null&&R(i,r),g),m?.observe(i)}};b();let C=new MutationObserver(b);return C.observe(r,{childList:!0,subtree:!0}),()=>{m?.disconnect(),C.disconnect();for(let[i,g]of t)y(i,!0,g)}},[l,d]),p("div",{className:"codex-user-message-content",children:[e("div",{ref:c,className:l&&!d?"codex-user-message-text codex-user-message-text-collapsed":"codex-user-message-text",children:e(a,{text:n,streaming:!1})}),l&&!d&&e("span",{className:"codex-user-message-ellipsis","aria-hidden":"true",children:"…"}),l&&p("button",{type:"button","aria-expanded":d,className:"codex-user-message-collapse-trigger",onClick:()=>{x((r)=>!r)},children:[e("span",{children:d?s("stream.codex.showLess"):s("stream.codex.showMore")}),e(E,{className:d?"codex-user-message-collapse-chevron codex-user-message-collapse-chevron-expanded":"codex-user-message-collapse-chevron","aria-hidden":"true"})]})]})}function $t({text:n,label:o,host:s}){let[a,c]=f(!1),[l,u]=f(null),d=async()=>{c(!1),u(null);try{await(s?.copyText?s.copyText(n):navigator.clipboard.writeText(n)),c(!0),setTimeout(()=>c(!1),2000)}catch(x){u(String(x)),s?.onCopyError?.(x)}};return e("button",{type:"button",className:"codex-message-action","aria-label":o,title:l??o,onClick:()=>void d(),children:a?e(N,{className:"codex-message-action-confirmed"}):e(T,{})})}function S({image:n,openImage:o}){let[s,a]=f(!1),c=`data:${n.mimeType};base64,${n.data}`;return p(h,{children:[e("button",{type:"button",className:"codex-user-image",onClick:()=>o===void 0?a(!0):o(c),children:e("img",{src:c,alt:""})}),s&&e(go,{src:c,alt:"",onClose:()=>a(!1)})]})}function po({message:n,text:o,textParts:s,mentions:a,images:c,messageTime:l,host:u,bubbleStyle:d}){let{t:x,openImage:r}=u;return e("div",{"data-content-search-unit-key":n.id,"data-message-id":n.id,className:"timeline-break codex-user-message scroll-mt-4",children:p("div",{className:"group/codex-user codex-user-message-group",children:[a.length>0&&e("div",{className:"codex-user-mentions",children:a.map((t)=>p("span",{className:"codex-user-mention",title:t.title,children:[e(w,{"aria-hidden":"true"}),e("span",{className:"codex-user-mention-label",children:t.label})]},t.key))}),c.length>0&&e("div",{className:"codex-user-images",children:c.map((t)=>e(S,{image:t,openImage:r},`${t.mimeType}:${t.data}`))}),o.length>0&&e(h,{children:e("div",{"data-user-message-bubble":!0,tabIndex:0,className:"codex-user-bubble",style:d,children:s?s.map((t,m)=>e("div",{className:"codex-user-text-part",children:t.question===void 0?e(M,{text:t.text,host:u}):p(h,{children:[e("div",{className:"codex-user-question-summary",title:t.question,children:t.question}),e("div",{className:"codex-user-question-answer",children:t.text})]})},m)):e(M,{text:o,host:u})})}),p("div",{className:"codex-user-actions",children:[e($t,{text:o,label:x("actions.copy"),host:u}),l&&e("span",{className:"codex-user-time",title:l.full,children:l.short})]})]})})}
2
+ export{$t,po};
@@ -1,2 +1,2 @@
1
- function a(t){if(t.path.startsWith("/")||/^[A-Za-z]:[\\/]/.test(t.path))return t.path;return`${t.root.replace(/[\\/]+$/,"")}/${t.path}`}function Ye(t,o=50){return t.slice(0,o).map((e)=>{let r=a(e);return{key:r,label:e.path,payload:r,description:e.match_type==="directory"?"/":""}})}
2
- export{Ye};
1
+ function a(t){if(t.path.startsWith("/")||/^[A-Za-z]:[\\/]/.test(t.path))return t.path;return`${t.root.replace(/[\\/]+$/,"")}/${t.path}`}function ut(t,o=50){return t.slice(0,o).map((e)=>{let r=a(e);return{key:r,label:e.path,payload:r,description:e.match_type==="directory"?"/":""}})}
2
+ export{ut};
@@ -1,7 +1,7 @@
1
- import{yo}from"./chunk-5c4z345j.js";import{zt,xo}from"./chunk-5nqhvv28.js";import{Ut}from"./chunk-dzx4rypz.js";import{decodeHTMLAttribute as C,decodeHTMLStrict as R}from"entities";import oe from"katex";import{CheckIcon as z,ChevronLeftIcon as ae,ChevronRightIcon as se,CopyIcon as ie,DownloadIcon as ce,FileIcon as de,LinkIcon as le,MailIcon as ue,XIcon as me}from"lucide-react";import"katex/dist/katex.min.css";import{createContext as ge,createElement as U,memo as B,startTransition as fe,useContext as he,useEffect as p,useLayoutEffect as D,useMemo as X,useRef as b,useState as h}from"react";import{jsx as a,jsxs as f,Fragment as te}from"react/jsx-runtime";var G=ge(null);function y(){let e=he(G);if(e===null)throw Error("Markdown host is missing");return e}var pe=80,A=/\[([^\]\n]+)\]\(([^)\n]+)$/,ke=/(^|\n)[^\S\n]*!\[[^\]\n]*(?:\](?:\([^\n]*)?)?\s*$/,we=/\uE200[^\uE201]*$/,be=4,xe=new Set("7zipx.accdb.asarpack.asciidoc.backup.backupdb.bundle.ccproj.cdrdao.code-workspace.config.debugin.deploy.design.docbook.dockerfile.dockerignore.editorconfig.eslintignore.gitattributes.gitignore.gitignore.gitkeep.gradle.graphqls.ignore.ipynb.keychain.keynote.licensee.lockfile.lockfile.markdown.markup.matlab.mkdocs.models.module.msstyle.notebook.npmignore.output.packageinfo.parquet.pickle.plistx.policy.postcssrc.prettierignore.projectfile.python.readme.review.robots.schema.search.series.settingsjson.shader.sqlite.sqlite3.storyboard.styles.system.target.terraform.update.vertex.webapp.webdoc.webpackrc.widget.workspace.xcodeproj.yarnlock".split("."));function N(e,n){let t=0;for(let r=n-1;r>=0&&e[r]==="\\";r-=1)t+=1;return t%2===1}function J(e,n,t){if(t.length!==1)return!1;return e[n-1]===t||e[n+1]===t}function Te(e,n){let t=0;for(let r=0;r<=e.length-n.length;){if(e.startsWith(n,r)&&!N(e,r)&&!J(e,r,n)){t+=1,r+=n.length;continue}r+=1}return t}function ve(e,n){for(let t=e.length-n.length;t>=0;t-=1)if(e.startsWith(n,t)&&!N(e,t)&&!J(e,t,n))return t;return-1}function Ce(e,n){let t=0;for(let r=0;r<=e.length-n.length;){if(e.startsWith(n,r)&&!N(e,r)){t+=1,r+=n.length;continue}r+=1}return t}function ye(e){return Ce(e,"```")%2===1}function V(e){let n=0;for(let t=0;t<e.length;){if(e.startsWith("```",t)){for(t+=3;t<e.length&&!e.startsWith("```",t);)t+=1;if(t<e.length)t+=3;continue}if(e[t]==="`"&&!N(e,t))n+=1;t+=1}return n%2===1}function Ne(e){return e.endsWith(`
1
+ import{Jn}from"./chunk-jn0q0b7k.js";import{Ot,to}from"./chunk-88xay4pa.js";import{Ht}from"./chunk-30wqrz8v.js";import{decodeHTMLAttribute as C,decodeHTMLStrict as R}from"entities";import oe from"katex";import{CheckIcon as z,ChevronLeftIcon as ae,ChevronRightIcon as se,CopyIcon as ie,DownloadIcon as ce,FileIcon as de,LinkIcon as le,MailIcon as ue,XIcon as me}from"lucide-react";import"katex/dist/katex.min.css";import{createContext as ge,createElement as U,memo as B,startTransition as fe,useContext as he,useEffect as p,useLayoutEffect as D,useMemo as X,useRef as b,useState as h}from"react";import{jsx as a,jsxs as f,Fragment as te}from"react/jsx-runtime";var G=ge(null);function y(){let e=he(G);if(e===null)throw Error("Markdown host is missing");return e}var pe=80,A=/\[([^\]\n]+)\]\(([^)\n]+)$/,ke=/(^|\n)[^\S\n]*!\[[^\]\n]*(?:\](?:\([^\n]*)?)?\s*$/,we=/\uE200[^\uE201]*$/,be=4,xe=new Set("7zipx.accdb.asarpack.asciidoc.backup.backupdb.bundle.ccproj.cdrdao.code-workspace.config.debugin.deploy.design.docbook.dockerfile.dockerignore.editorconfig.eslintignore.gitattributes.gitignore.gitignore.gitkeep.gradle.graphqls.ignore.ipynb.keychain.keynote.licensee.lockfile.lockfile.markdown.markup.matlab.mkdocs.models.module.msstyle.notebook.npmignore.output.packageinfo.parquet.pickle.plistx.policy.postcssrc.prettierignore.projectfile.python.readme.review.robots.schema.search.series.settingsjson.shader.sqlite.sqlite3.storyboard.styles.system.target.terraform.update.vertex.webapp.webdoc.webpackrc.widget.workspace.xcodeproj.yarnlock".split("."));function N(e,n){let t=0;for(let r=n-1;r>=0&&e[r]==="\\";r-=1)t+=1;return t%2===1}function J(e,n,t){if(t.length!==1)return!1;return e[n-1]===t||e[n+1]===t}function Te(e,n){let t=0;for(let r=0;r<=e.length-n.length;){if(e.startsWith(n,r)&&!N(e,r)&&!J(e,r,n)){t+=1,r+=n.length;continue}r+=1}return t}function ve(e,n){for(let t=e.length-n.length;t>=0;t-=1)if(e.startsWith(n,t)&&!N(e,t)&&!J(e,t,n))return t;return-1}function Ce(e,n){let t=0;for(let r=0;r<=e.length-n.length;){if(e.startsWith(n,r)&&!N(e,r)){t+=1,r+=n.length;continue}r+=1}return t}function ye(e){return Ce(e,"```")%2===1}function V(e){let n=0;for(let t=0;t<e.length;){if(e.startsWith("```",t)){for(t+=3;t<e.length&&!e.startsWith("```",t);)t+=1;if(t<e.length)t+=3;continue}if(e[t]==="`"&&!N(e,t))n+=1;t+=1}return n%2===1}function Ne(e){return e.endsWith(`
2
2
  `)?`${e}\`\`\``:`${e}
3
3
  \`\`\``}function H(e,n){if(!e.includes(n)||Te(e,n)%2===0)return e;let t=ve(e,n);if(t<0)return e;let r=e.slice(t+n.length);if(r.length===0||/^\s/.test(r)||r.includes(`
4
4
  `)||V(r))return e;return`${e}${n}`}function Me(e){return e.startsWith("/")&&!e.startsWith("//")||/^[A-Za-z]:[\\/]/.test(e)||/^\\\\[^\\]+\\[^\\]+/.test(e)||/^\/\/[^/]+\/[^/]+/.test(e)}function Z(e){let n=e.replaceAll("`","").trim(),t=n.match(/^(.*?):(\d+)(?::(\d+))?(?:[-–](\d+)(?::(\d+))?)?$/);if(t!==null){let[,o,s,i,c,d]=t;if(o===void 0||s===void 0)throw Error("Codex file location is incomplete");return{path:o,line:Number.parseInt(s,10),column:i===void 0?void 0:Number.parseInt(i,10),endLine:c===void 0?void 0:Number.parseInt(c,10),endColumn:d===void 0?void 0:Number.parseInt(d,10)}}let r=n.match(/^(.*?)#L(\d+)(?:C(\d+))?(?:-L(\d+)(?:C(\d+))?)?$/);if(r!==null){let[,o,s,i,c,d]=r;if(o===void 0||s===void 0)throw Error("Codex hash file location is incomplete");return{path:o,line:Number.parseInt(s,10),column:i===void 0?void 0:Number.parseInt(i,10),endLine:c===void 0?void 0:Number.parseInt(c,10),endColumn:d===void 0?void 0:Number.parseInt(d,10)}}return{path:n}}function Ee(e){let{path:n,line:t,column:r,endLine:o,endColumn:s}=Z(e);if(/^[a-z][a-z0-9+.-]*:\/\//i.test(n)||/^www\./i.test(n)||/^(mailto|tel):/i.test(n))return!1;if(t!==void 0||r!==void 0||o!==void 0||s!==void 0)return!0;if(!/(?:^|[\\/])[^\\/]+\.(?!\d+$)[^\\/.]+$/i.test(n))return!1;let i=/[\\/]/.test(n),c=n.split(/[\\/]/).at(-1);if(c===void 0)throw Error("Codex streaming link target has no file name");let d=c.split(".").at(-1);if(d===void 0||d.length===0)return!1;if(!i&&/[a-z]/.test(d)&&/[A-Z]/.test(d.slice(1)))return!1;if(!i){let u=d.toLowerCase();if(u.length>be&&!xe.has(u))return!1}return!0}function Le(e){let{path:n}=Z(e);if(Me(n))return!0;try{return new URL(n).protocol==="file:"}catch{return!1}}function Ie(e){let n=e.match(A);if(n===null)return e;let t=n[2];if(t===void 0)throw Error("Codex streaming link target is missing");return Ee(t)||Le(t)?e.replace(A,"$1"):`${e})`}function $e(e){let n=e.replace(we,"");if(n.length===0||n.includes("`")&&V(n))return{isCodeFenceOpen:!1,markdown:n};if(n.includes("```")&&ye(n))return{isCodeFenceOpen:!0,markdown:Ne(n)};if(n.includes("!["))n=n.replace(ke,(t,r)=>r);if(n.includes("]("))n=Ie(n);return n=H(n,"**"),n=H(n,"*"),{isCodeFenceOpen:!1,markdown:n}}function Re(e){return e?.type==="paragraph"&&"tokens"in e&&Array.isArray(e.tokens)}function _(e){return Re(e)&&e.tokens.length===1&&e.tokens[0]?.type==="image"}function Y(e){for(let n=0;n<e.length;n+=1){let t=e[n];if(t===void 0)throw Error(`Codex Markdown token is missing at index ${n}`);if("tokens"in t&&Array.isArray(t.tokens))Y(t.tokens);if(!_(t))continue;let r=[...t.tokens],o=n+1,s=o;for(;;){while(e[o]?.type==="space")o+=1;let i=e[o];if(!_(i))break;r.push(...i.tokens),o+=1,s=o}if(s===n+1)continue;t.tokens=r,t.text=r.map((i)=>i.raw).join(`
5
- `),t.raw=e.slice(n,s).map((i)=>i.raw).join(""),e.splice(n+1,s-n-1)}}function O(e){return{type:"text",raw:e,text:e}}function Pe(e){return{type:"paragraph",raw:e.raw,text:e.text,tokens:e.tokens??[e]}}function I(e){for(let n of e){if(n.type==="list")for(let t of n.items){let r=t.tokens[0];if(r?.type==="heading"){let o=r,s=o.raw.trimEnd(),i=s.match(/^#{1,6}\s+/)?.[0];if(i!==void 0)t.tokens[0]={type:"paragraph",raw:o.raw,text:s,tokens:o.tokens===void 0?[O(s)]:[O(i),...o.tokens]}}if(t.loose)t.tokens=t.tokens.map((o)=>o.type==="text"?Pe(o):o);I(t.tokens)}if("tokens"in n&&Array.isArray(n.tokens))I(n.tokens)}}function Se(e,n,t){e.preventDefault(),e.stopPropagation(),t.openLink(n)}function Fe(e){try{let n=new URL(e);return n.protocol!=="http:"&&n.protocol!=="https:"?null:`${n.origin}/favicon.ico`}catch{return null}}function Ae(e){let n=Fe(e);return n===null?[]:[n,`https://www.google.com/s2/favicons?domain=${new URL(e).origin}&sz=32`]}function He({href:e}){let n=X(()=>Ae(e),[e]),[t,r]=h(),o=n.length===0&&!/^[a-z][a-z0-9+.-]*:/i.test(e),s=e.toLowerCase().startsWith("mailto:")?ue:o?de:le;return f("span",{className:"codex-markdown-favicon",children:[t===void 0?a("span",{className:"codex-markdown-favicon-fallback",children:a(s,{"aria-hidden":!0})}):null,n.map((i)=>a("img",{alt:"",className:t===i?"codex-markdown-favicon-image-loaded":void 0,decoding:"async",draggable:!1,referrerPolicy:"no-referrer",src:i,onLoad:()=>r((c)=>c!==void 0&&n.includes(c)?c:i)},i))]})}function _e({children:e,href:n,title:t}){let r=y();if(r.preview)return a("span",{children:e});return a("a",{className:"codex-markdown-link","data-inline-mention-interactive":"",href:n,title:t,onClick:(o)=>Se(o,n,r),children:f("span",{className:"codex-markdown-link-mention","data-layout":"inline-flow","data-interactive":"","data-underline-on-hover":"",children:[a("span",{className:"codex-markdown-link-icon-container","data-markdown-copy":"exclude",children:a(He,{href:n})}),a("span",{className:"codex-markdown-link-label",children:e})]})})}function Oe({code:e,language:n}){let{theme:t,copyLabel:r,copyText:o,onCopyError:s}=y(),i=b(null),[c,d]=h(null),[u,T]=h(null),[M,k]=h(!1);if(p(()=>{let g=yo(d,T);return i.current=g,()=>{g.dispose(),i.current=null}},[]),p(()=>{let g=i.current;if(g===null)throw Error("Code highlighter is not mounted");g.update(e,n)},[e,n]),u!==null)throw u;let w=c!==null&&c.code===e&&c.language===n?c.html:null,l=async()=>{k(!1);try{await(o?o(e):navigator.clipboard.writeText(e)),k(!0),window.setTimeout(()=>k(!1),2000)}catch(g){s?.(g)}};return f("div",{className:"codex-markdown-code-block","data-markdown-copy":"code-block","data-markdown-copy-text":e,"data-theme":t==="dark"?"dark":"light",children:[f("div",{className:"codex-markdown-code-header","data-markdown-copy":"exclude",children:[a("div",{className:"codex-markdown-code-title",children:n}),a("div",{className:"codex-markdown-code-actions",children:a("button",{type:"button",className:"codex-markdown-code-copy",title:r,onClick:()=>void l(),children:M?a(z,{}):a(ie,{})})})]}),a("div",{className:"codex-markdown-code-container",dir:"ltr",children:a("code",{className:"codex-markdown-code-content hljs",...w===null?{children:e}:{dangerouslySetInnerHTML:{__html:w}}})})]})}function je({code:e,language:n}){return y().preview?a("span",{children:e}):a(We,{code:e,language:n})}function We({code:e,language:n}){let t=b(null),[r,o]=h(!1);if(p(()=>{if(r)return;let s=t.current;if(s===null)throw Error("Codex code block placeholder is not mounted");if(typeof IntersectionObserver>"u"){let c=window.setTimeout(()=>o(!0),0);return()=>window.clearTimeout(c)}let i=new IntersectionObserver((c)=>{if(!c.some((d)=>d.isIntersecting))return;o(!0),i.disconnect()},{rootMargin:"600px 0px"});return i.observe(s),()=>i.disconnect()},[r]),r)return a(Oe,{code:e,language:n});return a("div",{ref:t,className:"codex-markdown-code-block",children:a("pre",{className:"codex-markdown-code-placeholder",children:a("code",{children:e})})})}function qe(e){let n=[...document.body.querySelectorAll('[data-markdown-image-preview-trigger="true"]')],t=n.map((o)=>{let s=o.querySelector("img");if(s===null)throw Error("Codex image preview trigger has no image");return{src:s.currentSrc||s.src,alt:s.alt}}),r=n.indexOf(e);if(r===-1)throw Error("Codex image preview trigger is outside the document");return{images:t,index:r}}function Ke({preview:e,setPreview:n}){let t=e.images[e.index];if(t===void 0)throw Error(`Codex image preview index is out of range: ${e.index}`);return f("div",{className:"codex-markdown-image-preview",children:[a("img",{src:t.src,alt:t.alt}),f("div",{className:"codex-markdown-image-preview-actions",children:[a("button",{type:"button","aria-label":"Previous image",disabled:e.index===0,onClick:()=>n({...e,index:e.index-1}),children:a(ae,{})}),a("a",{href:t.src,download:!0,"aria-label":"Download image",children:a(ce,{})}),a("button",{type:"button","aria-label":"Next image",disabled:e.index===e.images.length-1,onClick:()=>n({...e,index:e.index+1}),children:a(se,{})}),a("button",{type:"button","aria-label":"Close image preview",onClick:()=>n(void 0),children:a(me,{})})]})]})}function ze(e){return y().preview?a(te,{children:e.alt}):a(Ue,{...e})}function Ue({src:e,alt:n,title:t,allowWide:r}){let o=b(null),[s,i]=h();p(()=>{let d=o.current;if(d===null)throw Error("Codex image preview dialog is not mounted");if(s===void 0){if(d.open)d.close();return}if(!d.open)d.showModal()},[s]);let c=n.length===0?"Open image preview":n;return f(te,{children:[a("button",{type:"button",className:`codex-markdown-image-trigger${r?"codex-markdown-image-trigger-wide":""}`,"aria-label":c,"data-markdown-image-preview-trigger":"true",onClick:(d)=>i(qe(d.currentTarget)),children:a("img",{className:`codex-markdown-image${r?"codex-markdown-image-wide":""}`,src:e,alt:n,title:t,loading:"lazy"})}),a("dialog",{ref:o,className:"codex-markdown-image-dialog","aria-label":c,onClose:()=>i(void 0),children:s===void 0?null:a(Ke,{preview:s,setPreview:i})})]})}function Be({value:e,display:n}){let t=b(null);return D(()=>{if(t.current===null)throw Error("Codex math root is not mounted");oe.render(e,t.current,{displayMode:n,throwOnError:!1})},[n,e]),a("span",{ref:t,className:n?"codex-markdown-math-block":"codex-markdown-inline-math"})}var De=150,v=null;function j(e,n){let t=v;if(t===null)return e;let r=t.cursor,o=r+e.length;t.cursor=o;let s=[],i=r;for(let c of t.runs){if(c.end<=r)continue;if(c.start>=o)break;let d=Math.max(r,c.start),u=Math.min(o,c.end);if(i<d)s.push(e.slice(i-r,d-r));s.push(a("span",{className:"codex-markdown-fade",children:e.slice(d-r,u-r)},`${n}:${t.generation}:${c.start}`)),i=u}if(i<o)s.push(e.slice(i-r));return s}function Q(e){let n=5381;for(let t=0;t<e.length;t+=1)n=(n*33+e.charCodeAt(t))%4294967296;return n.toString(36)}function W(e){let n=e.trim();if(n.length===0)return"";let t=n.split(`
6
- `,1)[0];if(t===void 0)throw Error("Codex Markdown token has no first line");return(t.match(/\S+/)?.[0]??t).slice(0,pe)}function Xe(e){switch(e.type){case"code":return e.raw.trimStart().match(/^(```|~~~)/)?.[1]??"";case"link":return e.href;case"image":{let n=e;return`${n.href}:${W(n.text)}`}case"html":case"space":case"br":case"hr":case"def":return e.raw;case"math":return W(e.text);default:return""}}function ee(e){return`${e.type==="math"?`math-${e.display?"block":"inline"}`:e.type}-${Q(Xe(e))}`}function m(e,n){let t=new Map;return e.map((r)=>{let o=ee(r),s=t.get(o)??0;return t.set(o,s+1),ne(r,`${n}-${o}-${s}`)})}function Ge(e,n){let t=e.task?e.tokens.filter((r)=>r.type!=="checkbox"):e.tokens;return f("li",{className:`codex-markdown-list-item${e.task?"codex-markdown-task-list-item":""}`,children:[e.task?f("div",{className:"codex-markdown-task-checkbox",children:[a("input",{type:"checkbox",className:"codex-markdown-checkbox",checked:e.checked,"data-state":e.checked?"checked":"unchecked",readOnly:!0,disabled:!0}),e.checked?a(z,{}):null]}):null,m(t,n)]},n)}function Je(e,n){let r=`codex-markdown-list ${e.items.some((s)=>s.task)?"codex-markdown-task-list":e.ordered?"codex-markdown-ordered-list":"codex-markdown-unordered-list"}`,o=m(e.items,n);return e.ordered?a("ol",{className:r,start:e.start===""?void 0:e.start,children:o},n):a("ul",{className:r,children:o},n)}function q(e,n,t){let r=t?"th":"td",o=/^\d+$/.test(e.text);return U(r,{key:n,className:`${t?"codex-markdown-table-header":"codex-markdown-table-cell"}${o?" codex-markdown-numeric-table-cell":""}`,align:e.align??void 0},...m(e.tokens,n))}function Ve(e,n){let t=new Map;return a("div",{className:"codex-markdown-table-container","data-markdown-table":!0,tabIndex:-1,children:a("div",{className:"codex-markdown-table-scroller",children:a("div",{className:"codex-markdown-table-wrapper",children:f("table",{className:"codex-markdown-table",children:[a("thead",{children:a("tr",{className:"codex-markdown-table-row",children:e.header.map((r,o)=>q(r,`${n}-header-${o}`,!0))})}),a("tbody",{className:"codex-markdown-table-body",children:e.rows.map((r)=>{let o=Q(r.map((c)=>c.text).join("\x00")),s=t.get(o)??0;t.set(o,s+1);let i=`${n}-row-${o}-${s}`;return a("tr",{className:"codex-markdown-table-row",children:r.map((c,d)=>q(c,`${i}-cell-${d}`,!1))},i)})})]})})})},n)}function K(e,n,t){let r=C(e.href);if(!Ut(r))return null;return a(ze,{src:r,alt:R(e.text),title:e.title==null?void 0:C(e.title),allowWide:t},n)}function ne(e,n){switch(e.type){case"space":case"def":case"internalMessage":return null;case"hr":return a("hr",{className:"codex-markdown-horizontal-rule"},n);case"heading":{let t=e,o={1:"h1",2:"h2",3:"h3",4:"h4",5:"h5",6:"h6"}[t.depth];if(o===void 0)throw Error(`Unsupported Codex Markdown heading depth: ${t.depth}`);return U(o,{key:n,className:`codex-markdown-heading codex-markdown-heading-${t.depth}`},...m(t.tokens,n))}case"paragraph":{let t=e,r=t.tokens.filter((i)=>i.type!=="space"&&i.type!=="br"),o=r.length>0&&r.every((i)=>i.type==="image"),s=o&&r.length>1;return a("p",{className:`codex-markdown-paragraph${o?"codex-markdown-media-paragraph codex-markdown-media-wide-block":""}${s?"codex-markdown-media-grid-paragraph":""}`,"data-markdown-image-grid":s?"true":void 0,"data-wide-markdown-block":o?"true":void 0,"data-wide-markdown-block-kind":o?"image":void 0,children:o?r.map((i,c)=>K(i,`${n}-image-${c}`,!0)):m(t.tokens,n)},n)}case"text":{let t=e;return t.tokens===void 0?j(R(t.text),n):m(t.tokens,n)}case"escape":return j(e.text,n);case"strong":return a("strong",{className:"codex-markdown-strong",children:m(e.tokens,n)},n);case"em":return a("em",{children:m(e.tokens,n)},n);case"del":return a("del",{children:m(e.tokens,n)},n);case"codespan":return a("span",{className:"codex-markdown-inline-code",dir:"ltr","data-markdown-copy":"inline-code",children:e.text},n);case"br":return a("br",{},n);case"link":{let t=e,r=m(t.tokens,n),o=C(t.href);return Ut(o)?a(_e,{href:o,title:t.title==null?void 0:C(t.title),children:r},n):a("span",{children:r},n)}case"image":return K(e,n,!1);case"code":{let t=e;return a(je,{code:t.text,language:t.lang},n)}case"blockquote":return a("blockquote",{className:"codex-markdown-blockquote",children:m(e.tokens,n)},n);case"list":return Je(e,n);case"list_item":return Ge(e,n);case"table":return Ve(e,n);case"html":{let t=e;return/^<br\s*\/?>$/i.test(t.raw.trim())?a("br",{},n):t.raw}case"math":{let t=e;return a(Be,{value:t.text,display:t.display},n)}default:throw Error(`Unsupported Codex Markdown token: ${JSON.stringify(e)}`)}}function x(e){switch(e.type){case"text":{let n=e;return n.tokens===void 0?R(n.text):n.tokens.map(x).join("")}case"escape":return e.text;case"paragraph":case"heading":case"strong":case"em":case"del":case"link":case"blockquote":case"list_item":return e.tokens.map(x).join("");case"list":return e.items.map(x).join("");case"table":{let n=e;return[n.header,...n.rows].map((t)=>t.map((r)=>r.tokens.map(x).join("")).join("")).join("")}default:return""}}function Ze({token:e,tokenKey:n,offset:t,runs:r,generation:o}){let s=v;try{return v={cursor:t,runs:r,generation:o},ne(e,n)}finally{v=s}}var Ye=B(function({result:n}){let{text:t,isStreaming:r}=n,o=X(()=>{let l=n.tokens;if(n.source.includes("!["))Y(l);I(l);let g=new Map,P=0;return l.map((E)=>{let L=ee(E),S=g.get(L)??0;g.set(L,S+1);let F=x(E),re={token:E,tokenKey:`root-${L}-${S}`,offset:P,visibleText:F};return P+=F.length,re})},[n]),s=o.map((l)=>l.visibleText).join(""),i=b({text:"",visibleText:"",runs:[],generation:0}),c=i.current,d=t.startsWith(c.text)||s.startsWith(c.visibleText),u=d?c.visibleText.length:0,T=performance.now(),M=r&&d?c.runs.filter((l)=>T-l.firstSeenAtMs<De):[],k=c.generation+(d?0:1),w={text:t,visibleText:s,runs:M.filter((l)=>l.start<s.length).map((l)=>({...l,end:Math.min(l.end,s.length)})),generation:k};if(r&&s.length>u)w.runs.push({start:u,end:s.length,firstSeenAtMs:T});return D(()=>{i.current=w}),a("div",{dir:"auto",className:"codex-markdown-content codex-markdown-root","data-streaming":r?"true":void 0,children:o.map((l)=>a(Ze,{token:l.token,tokenKey:l.tokenKey,offset:l.offset,runs:w.runs,generation:k},l.tokenKey))})}),Qe=B(function({text:n,isStreaming:t}){let r=b(null),[o,s]=h(()=>zt(n,t)),[i,c]=h(null);if(p(()=>{let d=xo((u)=>{fe(()=>s(u))},c);return r.current=d,()=>{d.dispose(),r.current=null}},[]),p(()=>{let d=r.current;if(d===null)throw Error("Markdown parser is not mounted");let u=t?$e(n).markdown:n;d.update({source:u,text:n,isStreaming:t})},[t,n]),i!==null)throw i;return o===null?a("div",{"data-markdown-pending":!0}):a(Ye,{result:o})});function vo({text:e,streaming:n,host:t}){let r=n===!0,[o,s]=h(e);return p(()=>{if(o===e)return;if(!r){s(e);return}let i=requestAnimationFrame(()=>s(e));return()=>cancelAnimationFrame(i)},[o,r,e]),a(G.Provider,{value:t,children:a(Qe,{text:r?o:e,isStreaming:r})})}
7
- export{vo};
5
+ `),t.raw=e.slice(n,s).map((i)=>i.raw).join(""),e.splice(n+1,s-n-1)}}function O(e){return{type:"text",raw:e,text:e}}function Pe(e){return{type:"paragraph",raw:e.raw,text:e.text,tokens:e.tokens??[e]}}function I(e){for(let n of e){if(n.type==="list")for(let t of n.items){let r=t.tokens[0];if(r?.type==="heading"){let o=r,s=o.raw.trimEnd(),i=s.match(/^#{1,6}\s+/)?.[0];if(i!==void 0)t.tokens[0]={type:"paragraph",raw:o.raw,text:s,tokens:o.tokens===void 0?[O(s)]:[O(i),...o.tokens]}}if(t.loose)t.tokens=t.tokens.map((o)=>o.type==="text"?Pe(o):o);I(t.tokens)}if("tokens"in n&&Array.isArray(n.tokens))I(n.tokens)}}function Se(e,n,t){e.preventDefault(),e.stopPropagation(),t.openLink(n)}function Fe(e){try{let n=new URL(e);return n.protocol!=="http:"&&n.protocol!=="https:"?null:`${n.origin}/favicon.ico`}catch{return null}}function Ae(e){let n=Fe(e);return n===null?[]:[n,`https://www.google.com/s2/favicons?domain=${new URL(e).origin}&sz=32`]}function He({href:e}){let n=X(()=>Ae(e),[e]),[t,r]=h(),o=n.length===0&&!/^[a-z][a-z0-9+.-]*:/i.test(e),s=e.toLowerCase().startsWith("mailto:")?ue:o?de:le;return f("span",{className:"codex-markdown-favicon",children:[t===void 0?a("span",{className:"codex-markdown-favicon-fallback",children:a(s,{"aria-hidden":!0})}):null,n.map((i)=>a("img",{alt:"",className:t===i?"codex-markdown-favicon-image-loaded":void 0,decoding:"async",draggable:!1,referrerPolicy:"no-referrer",src:i,onLoad:()=>r((c)=>c!==void 0&&n.includes(c)?c:i)},i))]})}function _e({children:e,href:n,title:t}){let r=y();if(r.preview)return a("span",{children:e});return a("a",{className:"codex-markdown-link","data-inline-mention-interactive":"",href:n,title:t,onClick:(o)=>Se(o,n,r),children:f("span",{className:"codex-markdown-link-mention","data-layout":"inline-flow","data-interactive":"","data-underline-on-hover":"",children:[a("span",{className:"codex-markdown-link-icon-container","data-markdown-copy":"exclude",children:a(He,{href:n})}),a("span",{className:"codex-markdown-link-label",children:e})]})})}function Oe({code:e,language:n}){let{theme:t,copyLabel:r,copyText:o,onCopyError:s}=y(),i=b(null),[c,d]=h(null),[u,T]=h(null),[M,k]=h(!1);if(p(()=>{let g=Jn(d,T);return i.current=g,()=>{g.dispose(),i.current=null}},[]),p(()=>{let g=i.current;if(g===null)throw Error("Code highlighter is not mounted");g.update(e,n)},[e,n]),u!==null)throw u;let w=c!==null&&c.code===e&&c.language===n?c.html:null,l=async()=>{k(!1);try{await(o?o(e):navigator.clipboard.writeText(e)),k(!0),window.setTimeout(()=>k(!1),2000)}catch(g){s?.(g)}};return f("div",{className:"codex-markdown-code-block","data-markdown-copy":"code-block","data-markdown-copy-text":e,"data-theme":t==="dark"?"dark":"light",children:[f("div",{className:"codex-markdown-code-header","data-markdown-copy":"exclude",children:[a("div",{className:"codex-markdown-code-title",children:n}),a("div",{className:"codex-markdown-code-actions",children:a("button",{type:"button",className:"codex-markdown-code-copy",title:r,onClick:()=>void l(),children:M?a(z,{}):a(ie,{})})})]}),a("div",{className:"codex-markdown-code-container",dir:"ltr",children:a("code",{className:"codex-markdown-code-content hljs",...w===null?{children:e}:{dangerouslySetInnerHTML:{__html:w}}})})]})}function je({code:e,language:n}){return y().preview?a("span",{children:e}):a(We,{code:e,language:n})}function We({code:e,language:n}){let t=b(null),[r,o]=h(!1);if(p(()=>{if(r)return;let s=t.current;if(s===null)throw Error("Codex code block placeholder is not mounted");if(typeof IntersectionObserver>"u"){let c=window.setTimeout(()=>o(!0),0);return()=>window.clearTimeout(c)}let i=new IntersectionObserver((c)=>{if(!c.some((d)=>d.isIntersecting))return;o(!0),i.disconnect()},{rootMargin:"600px 0px"});return i.observe(s),()=>i.disconnect()},[r]),r)return a(Oe,{code:e,language:n});return a("div",{ref:t,className:"codex-markdown-code-block",children:a("pre",{className:"codex-markdown-code-placeholder",children:a("code",{children:e})})})}function qe(e){let n=[...document.body.querySelectorAll('[data-markdown-image-preview-trigger="true"]')],t=n.map((o)=>{let s=o.querySelector("img");if(s===null)throw Error("Codex image preview trigger has no image");return{src:s.currentSrc||s.src,alt:s.alt}}),r=n.indexOf(e);if(r===-1)throw Error("Codex image preview trigger is outside the document");return{images:t,index:r}}function Ke({preview:e,setPreview:n}){let t=e.images[e.index];if(t===void 0)throw Error(`Codex image preview index is out of range: ${e.index}`);return f("div",{className:"codex-markdown-image-preview",children:[a("img",{src:t.src,alt:t.alt}),f("div",{className:"codex-markdown-image-preview-actions",children:[a("button",{type:"button","aria-label":"Previous image",disabled:e.index===0,onClick:()=>n({...e,index:e.index-1}),children:a(ae,{})}),a("a",{href:t.src,download:!0,"aria-label":"Download image",children:a(ce,{})}),a("button",{type:"button","aria-label":"Next image",disabled:e.index===e.images.length-1,onClick:()=>n({...e,index:e.index+1}),children:a(se,{})}),a("button",{type:"button","aria-label":"Close image preview",onClick:()=>n(void 0),children:a(me,{})})]})]})}function ze(e){return y().preview?a(te,{children:e.alt}):a(Ue,{...e})}function Ue({src:e,alt:n,title:t,allowWide:r}){let o=b(null),[s,i]=h();p(()=>{let d=o.current;if(d===null)throw Error("Codex image preview dialog is not mounted");if(s===void 0){if(d.open)d.close();return}if(!d.open)d.showModal()},[s]);let c=n.length===0?"Open image preview":n;return f(te,{children:[a("button",{type:"button",className:`codex-markdown-image-trigger${r?"codex-markdown-image-trigger-wide":""}`,"aria-label":c,"data-markdown-image-preview-trigger":"true",onClick:(d)=>i(qe(d.currentTarget)),children:a("img",{className:`codex-markdown-image${r?"codex-markdown-image-wide":""}`,src:e,alt:n,title:t,loading:"lazy"})}),a("dialog",{ref:o,className:"codex-markdown-image-dialog","aria-label":c,onClose:()=>i(void 0),children:s===void 0?null:a(Ke,{preview:s,setPreview:i})})]})}function Be({value:e,display:n}){let t=b(null);return D(()=>{if(t.current===null)throw Error("Codex math root is not mounted");oe.render(e,t.current,{displayMode:n,throwOnError:!1})},[n,e]),a("span",{ref:t,className:n?"codex-markdown-math-block":"codex-markdown-inline-math"})}var De=150,v=null;function j(e,n){let t=v;if(t===null)return e;let r=t.cursor,o=r+e.length;t.cursor=o;let s=[],i=r;for(let c of t.runs){if(c.end<=r)continue;if(c.start>=o)break;let d=Math.max(r,c.start),u=Math.min(o,c.end);if(i<d)s.push(e.slice(i-r,d-r));s.push(a("span",{className:"codex-markdown-fade",children:e.slice(d-r,u-r)},`${n}:${t.generation}:${c.start}`)),i=u}if(i<o)s.push(e.slice(i-r));return s}function Q(e){let n=5381;for(let t=0;t<e.length;t+=1)n=(n*33+e.charCodeAt(t))%4294967296;return n.toString(36)}function W(e){let n=e.trim();if(n.length===0)return"";let t=n.split(`
6
+ `,1)[0];if(t===void 0)throw Error("Codex Markdown token has no first line");return(t.match(/\S+/)?.[0]??t).slice(0,pe)}function Xe(e){switch(e.type){case"code":return e.raw.trimStart().match(/^(```|~~~)/)?.[1]??"";case"link":return e.href;case"image":{let n=e;return`${n.href}:${W(n.text)}`}case"html":case"space":case"br":case"hr":case"def":return e.raw;case"math":return W(e.text);default:return""}}function ee(e){return`${e.type==="math"?`math-${e.display?"block":"inline"}`:e.type}-${Q(Xe(e))}`}function m(e,n){let t=new Map;return e.map((r)=>{let o=ee(r),s=t.get(o)??0;return t.set(o,s+1),ne(r,`${n}-${o}-${s}`)})}function Ge(e,n){let t=e.task?e.tokens.filter((r)=>r.type!=="checkbox"):e.tokens;return f("li",{className:`codex-markdown-list-item${e.task?"codex-markdown-task-list-item":""}`,children:[e.task?f("div",{className:"codex-markdown-task-checkbox",children:[a("input",{type:"checkbox",className:"codex-markdown-checkbox",checked:e.checked,"data-state":e.checked?"checked":"unchecked",readOnly:!0,disabled:!0}),e.checked?a(z,{}):null]}):null,m(t,n)]},n)}function Je(e,n){let r=`codex-markdown-list ${e.items.some((s)=>s.task)?"codex-markdown-task-list":e.ordered?"codex-markdown-ordered-list":"codex-markdown-unordered-list"}`,o=m(e.items,n);return e.ordered?a("ol",{className:r,start:e.start===""?void 0:e.start,children:o},n):a("ul",{className:r,children:o},n)}function q(e,n,t){let r=t?"th":"td",o=/^\d+$/.test(e.text);return U(r,{key:n,className:`${t?"codex-markdown-table-header":"codex-markdown-table-cell"}${o?" codex-markdown-numeric-table-cell":""}`,align:e.align??void 0},...m(e.tokens,n))}function Ve(e,n){let t=new Map;return a("div",{className:"codex-markdown-table-container","data-markdown-table":!0,tabIndex:-1,children:a("div",{className:"codex-markdown-table-scroller",children:a("div",{className:"codex-markdown-table-wrapper",children:f("table",{className:"codex-markdown-table",children:[a("thead",{children:a("tr",{className:"codex-markdown-table-row",children:e.header.map((r,o)=>q(r,`${n}-header-${o}`,!0))})}),a("tbody",{className:"codex-markdown-table-body",children:e.rows.map((r)=>{let o=Q(r.map((c)=>c.text).join("\x00")),s=t.get(o)??0;t.set(o,s+1);let i=`${n}-row-${o}-${s}`;return a("tr",{className:"codex-markdown-table-row",children:r.map((c,d)=>q(c,`${i}-cell-${d}`,!1))},i)})})]})})})},n)}function K(e,n,t){let r=C(e.href);if(!Ht(r))return null;return a(ze,{src:r,alt:R(e.text),title:e.title==null?void 0:C(e.title),allowWide:t},n)}function ne(e,n){switch(e.type){case"space":case"def":case"internalMessage":return null;case"hr":return a("hr",{className:"codex-markdown-horizontal-rule"},n);case"heading":{let t=e,o={1:"h1",2:"h2",3:"h3",4:"h4",5:"h5",6:"h6"}[t.depth];if(o===void 0)throw Error(`Unsupported Codex Markdown heading depth: ${t.depth}`);return U(o,{key:n,className:`codex-markdown-heading codex-markdown-heading-${t.depth}`},...m(t.tokens,n))}case"paragraph":{let t=e,r=t.tokens.filter((i)=>i.type!=="space"&&i.type!=="br"),o=r.length>0&&r.every((i)=>i.type==="image"),s=o&&r.length>1;return a("p",{className:`codex-markdown-paragraph${o?"codex-markdown-media-paragraph codex-markdown-media-wide-block":""}${s?"codex-markdown-media-grid-paragraph":""}`,"data-markdown-image-grid":s?"true":void 0,"data-wide-markdown-block":o?"true":void 0,"data-wide-markdown-block-kind":o?"image":void 0,children:o?r.map((i,c)=>K(i,`${n}-image-${c}`,!0)):m(t.tokens,n)},n)}case"text":{let t=e;return t.tokens===void 0?j(R(t.text),n):m(t.tokens,n)}case"escape":return j(e.text,n);case"strong":return a("strong",{className:"codex-markdown-strong",children:m(e.tokens,n)},n);case"em":return a("em",{children:m(e.tokens,n)},n);case"del":return a("del",{children:m(e.tokens,n)},n);case"codespan":return a("span",{className:"codex-markdown-inline-code",dir:"ltr","data-markdown-copy":"inline-code",children:e.text},n);case"br":return a("br",{},n);case"link":{let t=e,r=m(t.tokens,n),o=C(t.href);return Ht(o)?a(_e,{href:o,title:t.title==null?void 0:C(t.title),children:r},n):a("span",{children:r},n)}case"image":return K(e,n,!1);case"code":{let t=e;return a(je,{code:t.text,language:t.lang},n)}case"blockquote":return a("blockquote",{className:"codex-markdown-blockquote",children:m(e.tokens,n)},n);case"list":return Je(e,n);case"list_item":return Ge(e,n);case"table":return Ve(e,n);case"html":{let t=e;return/^<br\s*\/?>$/i.test(t.raw.trim())?a("br",{},n):t.raw}case"math":{let t=e;return a(Be,{value:t.text,display:t.display},n)}default:throw Error(`Unsupported Codex Markdown token: ${JSON.stringify(e)}`)}}function x(e){switch(e.type){case"text":{let n=e;return n.tokens===void 0?R(n.text):n.tokens.map(x).join("")}case"escape":return e.text;case"paragraph":case"heading":case"strong":case"em":case"del":case"link":case"blockquote":case"list_item":return e.tokens.map(x).join("");case"list":return e.items.map(x).join("");case"table":{let n=e;return[n.header,...n.rows].map((t)=>t.map((r)=>r.tokens.map(x).join("")).join("")).join("")}default:return""}}function Ze({token:e,tokenKey:n,offset:t,runs:r,generation:o}){let s=v;try{return v={cursor:t,runs:r,generation:o},ne(e,n)}finally{v=s}}var Ye=B(function({result:n}){let{text:t,isStreaming:r}=n,o=X(()=>{let l=n.tokens;if(n.source.includes("!["))Y(l);I(l);let g=new Map,P=0;return l.map((E)=>{let L=ee(E),S=g.get(L)??0;g.set(L,S+1);let F=x(E),re={token:E,tokenKey:`root-${L}-${S}`,offset:P,visibleText:F};return P+=F.length,re})},[n]),s=o.map((l)=>l.visibleText).join(""),i=b({text:"",visibleText:"",runs:[],generation:0}),c=i.current,d=t.startsWith(c.text)||s.startsWith(c.visibleText),u=d?c.visibleText.length:0,T=performance.now(),M=r&&d?c.runs.filter((l)=>T-l.firstSeenAtMs<De):[],k=c.generation+(d?0:1),w={text:t,visibleText:s,runs:M.filter((l)=>l.start<s.length).map((l)=>({...l,end:Math.min(l.end,s.length)})),generation:k};if(r&&s.length>u)w.runs.push({start:u,end:s.length,firstSeenAtMs:T});return D(()=>{i.current=w}),a("div",{dir:"auto",className:"codex-markdown-content codex-markdown-root","data-streaming":r?"true":void 0,children:o.map((l)=>a(Ze,{token:l.token,tokenKey:l.tokenKey,offset:l.offset,runs:w.runs,generation:k},l.tokenKey))})}),Qe=B(function({text:n,isStreaming:t}){let r=b(null),[o,s]=h(()=>Ot(n,t)),[i,c]=h(null);if(p(()=>{let d=to((u)=>{fe(()=>s(u))},c);return r.current=d,()=>{d.dispose(),r.current=null}},[]),p(()=>{let d=r.current;if(d===null)throw Error("Markdown parser is not mounted");let u=t?$e(n).markdown:n;d.update({source:u,text:n,isStreaming:t})},[t,n]),i!==null)throw i;return o===null?a("div",{"data-markdown-pending":!0}):a(Ye,{result:o})});function jn({text:e,streaming:n,host:t}){let r=n===!0,[o,s]=h(e);return p(()=>{if(o===e)return;if(!r){s(e);return}let i=requestAnimationFrame(()=>s(e));return()=>cancelAnimationFrame(i)},[o,r,e]),a(G.Provider,{value:t,children:a(Qe,{text:r?o:e,isStreaming:r})})}
7
+ export{jn};
@@ -1,2 +1,2 @@
1
- function $o({container:i,target:f,clientX:e,clientY:n,currentScale:r,nextScale:s}){if(r<=0||s<=0)return null;let o=i.getBoundingClientRect(),t=f.getBoundingClientRect();if(t.width===0||t.height===0)return null;let h=e>=t.left&&e<=t.right&&n>=t.top&&n<=t.bottom,l=h?(e-t.left)/t.width:0.5,a=h?(n-t.top)/t.height:0.5,c=t.width/r,g=t.height/r,m=c*s,u=g*s,d=e-o.left,p=n-o.top,P=i.scrollLeft+(t.left-o.left)+t.width/2,b=i.scrollTop+(t.top-o.top)+t.height/2,C=(l-0.5)*m,x=(a-0.5)*u;return{left:Math.max(0,P+C-d),top:Math.max(0,b+x-p)}}
2
- export{$o};
1
+ function Ho({container:i,target:f,clientX:e,clientY:n,currentScale:r,nextScale:s}){if(r<=0||s<=0)return null;let o=i.getBoundingClientRect(),t=f.getBoundingClientRect();if(t.width===0||t.height===0)return null;let h=e>=t.left&&e<=t.right&&n>=t.top&&n<=t.bottom,l=h?(e-t.left)/t.width:0.5,a=h?(n-t.top)/t.height:0.5,c=t.width/r,g=t.height/r,m=c*s,u=g*s,d=e-o.left,p=n-o.top,P=i.scrollLeft+(t.left-o.left)+t.width/2,b=i.scrollTop+(t.top-o.top)+t.height/2,C=(l-0.5)*m,x=(a-0.5)*u;return{left:Math.max(0,P+C-d),top:Math.max(0,b+x-p)}}
2
+ export{Ho};
@@ -1,2 +1,2 @@
1
- function kn(t){return Object.entries(t.properties??{}).map(([n,e])=>({key:n,property:e}))}function Ct(t){let{title:n,description:e}=t;return{title:n??void 0,description:e??void 0}}function le(t){return t.type==="array"}function ct(t){return(le(t)?t.items?.oneOf??[]:t.oneOf??[]).map((e)=>{let i=e,r=i.const??i.title??"";return{value:r,label:i.title??r,...i.description?{description:i.description}:{},...i._meta?.alwith?.preview?{preview:i._meta.alwith.preview}:{}}})}
2
- export{kn,Ct,le,ct};
1
+ function mn(t){return Object.entries(t.properties??{}).map(([n,e])=>({key:n,property:e}))}function Ct(t){let{title:n,description:e}=t;return{title:n??void 0,description:e??void 0}}function ae(t){return t.type==="array"}function We(t){return(ae(t)?t.items?.oneOf??[]:t.oneOf??[]).map((e)=>{let i=e,r=i.const??i.title??"";return{value:r,label:i.title??r,...i.description?{description:i.description}:{},...i._meta?.alwith?.preview?{preview:i._meta.alwith.preview}:{}}})}
2
+ export{mn,Ct,ae,We};
@@ -1,2 +1,2 @@
1
- function oo(r,e){if(!e.running)return{kind:"idle"};if(e.blocked)return{kind:"waiting"};if(e.retrying)return{kind:"retrying"};let t=r.findLast((i)=>i.kind==="tool"&&i.active);if(t)return{kind:"tool",ownerKey:t.key};let n=r.findLast((i)=>i.kind!=="user");if(n?.active){if(n.kind==="answer")return{kind:"speaking",ownerKey:n.key};if(n.kind==="text")return{kind:"thinking",ownerKey:n.key};if(n.kind==="reasoning")return{kind:"reasoning",ownerKey:n.key};if(n.kind==="plan")return{kind:"planning",ownerKey:n.key};if(n.kind==="compaction")return{kind:"tool",ownerKey:n.key}}if(n?.kind==="answer")return{kind:"idle"};return{kind:"thinking",ownerKey:n?.key}}
2
- export{oo};
1
+ function Po(r,e){if(!e.running)return{kind:"idle"};if(e.blocked)return{kind:"waiting"};if(e.retrying)return{kind:"retrying"};let t=r.findLast((i)=>i.kind==="tool"&&i.active);if(t)return{kind:"tool",ownerKey:t.key};let n=r.findLast((i)=>i.kind!=="user");if(n?.active){if(n.kind==="answer")return{kind:"speaking",ownerKey:n.key};if(n.kind==="text")return{kind:"thinking",ownerKey:n.key};if(n.kind==="reasoning")return{kind:"reasoning",ownerKey:n.key};if(n.kind==="plan")return{kind:"planning",ownerKey:n.key};if(n.kind==="compaction")return{kind:"tool",ownerKey:n.key}}if(n?.kind==="answer")return{kind:"idle"};return{kind:"thinking",ownerKey:n?.key}}
2
+ export{Po};
@@ -1,2 +1,2 @@
1
- async function Ho(g,u){try{let a=await(await fetch(g)).blob(),s=u??a.type??"";if(!s.startsWith("image/"))return new Promise((e)=>{let t=new FileReader;t.onloadend=()=>e(t.result),t.onerror=()=>e(null),t.readAsDataURL(a)});let w=s.includes("svg"),n,r,o;if(w){let e=new Image,t=URL.createObjectURL(a);e.src=t;try{await new Promise((h,f)=>{e.onload=()=>h(),e.onerror=()=>f(Error("svg load failed"))})}finally{URL.revokeObjectURL(t)}r=e.naturalWidth||1024,o=e.naturalHeight||1024,n=e}else{let e=await createImageBitmap(a);r=e.width,o=e.height,n=e}let i=Math.min(1,2000/Math.max(r,o)),c=Math.round(r*i),l=Math.round(o*i),d=new OffscreenCanvas(c,l),m=d.getContext("2d");if(!m)throw Error("image-encode: OffscreenCanvas 2d context 不可用");if(m.drawImage(n,0,0,c,l),n instanceof ImageBitmap)n.close();let b=await d.convertToBlob({type:"image/webp",quality:0.85});return new Promise((e)=>{let t=new FileReader;t.onloadend=()=>e(t.result),t.onerror=()=>e(null),t.readAsDataURL(b)})}catch{return null}}
2
- export{Ho};
1
+ async function tr(g,u){try{let a=await(await fetch(g)).blob(),s=u??a.type??"";if(!s.startsWith("image/"))return new Promise((e)=>{let t=new FileReader;t.onloadend=()=>e(t.result),t.onerror=()=>e(null),t.readAsDataURL(a)});let w=s.includes("svg"),n,r,o;if(w){let e=new Image,t=URL.createObjectURL(a);e.src=t;try{await new Promise((h,f)=>{e.onload=()=>h(),e.onerror=()=>f(Error("svg load failed"))})}finally{URL.revokeObjectURL(t)}r=e.naturalWidth||1024,o=e.naturalHeight||1024,n=e}else{let e=await createImageBitmap(a);r=e.width,o=e.height,n=e}let i=Math.min(1,2000/Math.max(r,o)),c=Math.round(r*i),l=Math.round(o*i),d=new OffscreenCanvas(c,l),m=d.getContext("2d");if(!m)throw Error("image-encode: OffscreenCanvas 2d context 不可用");if(m.drawImage(n,0,0,c,l),n instanceof ImageBitmap)n.close();let b=await d.convertToBlob({type:"image/webp",quality:0.85});return new Promise((e)=>{let t=new FileReader;t.onloadend=()=>e(t.result),t.onerror=()=>e(null),t.readAsDataURL(b)})}catch{return null}}
2
+ export{tr};
@@ -1 +1 @@
1
- import{cn as r}from"cn";import{jsx as d}from"react/jsx-runtime";function Zo({className:a,size:t="default",...o}){return d("div",{"data-slot":"card","data-size":t,className:r("group/card bg-card text-card-foreground ring-foreground/10 flex flex-col gap-(--card-spacing) overflow-hidden rounded-xl py-(--card-spacing) text-sm shadow-xs ring-1 [--card-spacing:--spacing(6)] has-[>img:first-child]:pt-0 data-[size=sm]:[--card-spacing:--spacing(4)] *:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl",a),...o})}function Jo({className:a,...t}){return d("div",{"data-slot":"card-header",className:r("group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-xl px-(--card-spacing) has-data-[slot=card-action]:grid-cols-[1fr_auto] has-data-[slot=card-description]:grid-rows-[auto_auto] [.border-b]:pb-(--card-spacing)",a),...t})}function er({className:a,...t}){return d("div",{"data-slot":"card-title",className:r("font-heading text-base leading-normal font-medium group-data-[size=sm]/card:text-sm",a),...t})}function tr({className:a,...t}){return d("div",{"data-slot":"card-description",className:r("text-muted-foreground text-sm",a),...t})}function bi({className:a,...t}){return d("div",{"data-slot":"card-action",className:r("col-start-2 row-span-2 row-start-1 self-start justify-self-end",a),...t})}function nr({className:a,...t}){return d("div",{"data-slot":"card-content",className:r("flex flex-col gap-3 px-(--card-spacing)",a),...t})}function or({className:a,...t}){return d("div",{"data-slot":"card-footer",className:r("flex items-center rounded-b-xl px-(--card-spacing) [.border-t]:pt-(--card-spacing)",a),...t})}export{Zo,Jo,er,tr,bi,nr,or};
1
+ import{cn as r}from"cn";import{jsx as d}from"react/jsx-runtime";function Cn({className:a,size:t="default",...o}){return d("div",{"data-slot":"card","data-size":t,className:r("group/card bg-card text-card-foreground ring-foreground/10 flex flex-col gap-(--card-spacing) overflow-hidden rounded-xl py-(--card-spacing) text-sm shadow-xs ring-1 [--card-spacing:--spacing(6)] has-[>img:first-child]:pt-0 data-[size=sm]:[--card-spacing:--spacing(4)] *:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl",a),...o})}function Tn({className:a,...t}){return d("div",{"data-slot":"card-header",className:r("group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-xl px-(--card-spacing) has-data-[slot=card-action]:grid-cols-[1fr_auto] has-data-[slot=card-description]:grid-rows-[auto_auto] [.border-b]:pb-(--card-spacing)",a),...t})}function Sn({className:a,...t}){return d("div",{"data-slot":"card-title",className:r("font-heading text-base leading-normal font-medium group-data-[size=sm]/card:text-sm",a),...t})}function In({className:a,...t}){return d("div",{"data-slot":"card-description",className:r("text-muted-foreground text-sm",a),...t})}function Jr({className:a,...t}){return d("div",{"data-slot":"card-action",className:r("col-start-2 row-span-2 row-start-1 self-start justify-self-end",a),...t})}function Pn({className:a,...t}){return d("div",{"data-slot":"card-content",className:r("flex flex-col gap-3 px-(--card-spacing)",a),...t})}function Nn({className:a,...t}){return d("div",{"data-slot":"card-footer",className:r("flex items-center rounded-b-xl px-(--card-spacing) [.border-t]:pt-(--card-spacing)",a),...t})}export{Cn,Tn,Sn,In,Jr,Pn,Nn};
@@ -1,3 +1,3 @@
1
- var oi=["full","compact","codexUI"];function mo(t){return t==="compact"||t==="codexUI"}var Hr=["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 L(t){let o=Hr.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 ri(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{oi,mo,Hr,L,ri};
1
+ var mi=["full","compact","codexUI"];function co(t){return t==="compact"||t==="codexUI"}var Lr=["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 D(t){let o=Lr.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 pi(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{mi,co,Lr,D,pi};
@@ -0,0 +1,2 @@
1
+ import{zo}from"./chunk-zt8qaqbz.js";import{o}from"./chunk-dp8pjv6r.js";import{n,C}from"./chunk-ysc51tpb.js";import{R,x,ne}from"./chunk-bhze2sjv.js";import{isBooleanOption as E,isGroupedSelect as U,isSelectOption as q}from"@nyssance/codex-acp-v2/client";import{Zap as A}from"lucide-react";import{jsx as y}from"react/jsx-runtime";function gt({sessionId:p,options:f,disabled:w,onModelChange:g,onConfigChange:M,defaultGroup:I={id:"models",name:"Models"},catalog:B=(s)=>s,headerAction:G}){let{host:s,client:L}=n(),{t:r}=s,h=o((e)=>Boolean(e.configPending[p])),N=o((e)=>{let a=e.sessions[p];return a?.state==="running"||a?.state==="requires_action"}),t=x(f,"model"),l=x(f,"thought_level"),b=f.filter((e)=>e.configId!=="collaboration_mode"&&(e.category==="model_config"||e.category!=="mode"&&e!==t&&e!==l)),O=b.filter(q),d=b.filter(E);if(!t&&!l&&O.length===0&&d.length===0)return null;let c=(e,a)=>{if(a===e.currentValue)return;C(s,M?M(e.configId,a):L.setConfig(p,e.configId,a))},m=l?R(l):[],k=m.reduce((e,a)=>a.name.length>=e.length?a.name:e,""),z=t?ne(t):r("composer.model"),_=(e)=>({api_id:e.value,label:e.name}),v=B(t&&U(t.options)?t.options.map((e)=>({id:e.groupId,name:e.name,models:e.options.map(_)})):[{...I,models:t?R(t).map(_):[]}]),S=v.flatMap((e)=>e.models),u=S.find((e)=>e.api_id===t?.currentValue)??{api_id:t?.currentValue??"",label:z},i=d.find((e)=>e.configId==="fast-mode");return y(zo,{disabled:w||h||N,switching:h,value:{...u,label:u.shortLabel??u.label},compactCatalog:!0,models:S,showModelList:Boolean(t),onChange:(e)=>{if(e.api_id===t?.currentValue)return;if(g)g(e.api_id);else if(t)c(t,e.api_id)},header:{name:t?.name??r("composer.model"),action:G},modelGroups:v,t:r,effortConfig:l&&m.length>0?{name:"Effort",value:l.currentValue,levels:m,sizer:k,onChange:(e)=>c(l,e)}:void 0,selectOptions:O.map((e)=>({id:e.configId,name:e.name,value:e.currentValue,options:R(e).map((a)=>({value:a.value,label:a.name})),onChange:(a)=>c(e,a)})),booleanOptions:[{id:"fast_mode",name:r("composer.fastMode"),currentValue:i?.currentValue??!1,disabled:!i,title:!i?r("composer.fastModeUnsupported"):void 0,icon:y(A,{className:"size-4","aria-hidden":"true"})},...d.filter((e)=>e!==i).map((e)=>({id:e.configId,name:e.name,currentValue:e.currentValue}))],onBooleanChange:(e,a)=>{let V=e==="fast_mode"?i:d.find((P)=>P.configId===e);if(!V)throw Error(`Unknown boolean config: ${e}`);c(V,a)}})}
2
+ export{gt};
@@ -1,2 +1,2 @@
1
- import{CheckCircleIcon as c,CircleIcon as o,LoaderIcon as i}from"lucide-react";import{jsx as n,jsxs as e}from"react/jsx-runtime";function z({entries:s}){let d=s.filter((a)=>a.status==="completed").length,t=s.find((a)=>a.status==="in_progress");return e("div",{className:"codex-plan",children:[e("div",{className:"codex-plan-summary",children:[e("span",{children:[d,"/",s.length]}),t!==void 0&&e("span",{className:"codex-plan-active",children:["· ",t.content]})]}),n("div",{className:"codex-plan-entries",children:s.map((a)=>e("div",{className:"codex-plan-entry","data-status":a.status,children:[a.status==="completed"&&n(c,{"aria-hidden":"true"}),a.status==="in_progress"&&n(i,{className:"codex-plan-spinner","aria-hidden":"true"}),a.status==="pending"&&n(o,{"aria-hidden":"true"}),n("span",{children:a.content})]},a.content))})]})}
2
- export{z};
1
+ import{CheckCircleIcon as c,CircleIcon as o,LoaderIcon as i}from"lucide-react";import{jsx as n,jsxs as e}from"react/jsx-runtime";function W({entries:s}){let d=s.filter((a)=>a.status==="completed").length,t=s.find((a)=>a.status==="in_progress");return e("div",{className:"codex-plan",children:[e("div",{className:"codex-plan-summary",children:[e("span",{children:[d,"/",s.length]}),t!==void 0&&e("span",{className:"codex-plan-active",children:["· ",t.content]})]}),n("div",{className:"codex-plan-entries",children:s.map((a)=>e("div",{className:"codex-plan-entry","data-status":a.status,children:[a.status==="completed"&&n(c,{"aria-hidden":"true"}),a.status==="in_progress"&&n(i,{className:"codex-plan-spinner","aria-hidden":"true"}),a.status==="pending"&&n(o,{"aria-hidden":"true"}),n("span",{children:a.content})]},a.content))})]})}
2
+ export{W};
@@ -1 +1 @@
1
- import{Tooltip as i}from"@base-ui/react/tooltip";import{cn as l}from"cn";import{jsx as o,jsxs as p}from"react/jsx-runtime";function Ni({delay:t=0,...e}){return o(i.Provider,{"data-slot":"tooltip-provider",delay:t,...e})}function be({...t}){return o(i.Root,{"data-slot":"tooltip",...t})}function we({...t}){return o(i.Trigger,{"data-slot":"tooltip-trigger",...t})}function ke({className:t,side:e="top",sideOffset:a=4,align:d="center",alignOffset:r=0,children:n,...s}){return o(i.Portal,{children:o(i.Positioner,{align:d,alignOffset:r,side:e,sideOffset:a,className:"isolate z-50",children:p(i.Popup,{"data-slot":"tooltip-content",className:l("bg-foreground text-background data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=delayed-open]:animate-in data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95 z-50 inline-flex w-fit max-w-xs origin-(--transform-origin) items-center gap-1.5 rounded-md px-3 py-1.5 text-xs has-data-[slot=kbd]:pr-1.5 **:data-[slot=kbd]:relative **:data-[slot=kbd]:isolate **:data-[slot=kbd]:z-50 **:data-[slot=kbd]:rounded-sm",t),...s,children:[n,o(i.Arrow,{className:"bg-foreground fill-foreground z-50 size-2.5 translate-y-[calc(-50%-2px)] rotate-45 rounded-[2px] data-[side=bottom]:top-1 data-[side=inline-end]:top-1/2! data-[side=inline-end]:-left-1 data-[side=inline-end]:-translate-y-1/2 data-[side=inline-start]:top-1/2! data-[side=inline-start]:-right-1 data-[side=inline-start]:-translate-y-1/2 data-[side=left]:top-1/2! data-[side=left]:-right-1 data-[side=left]:-translate-y-1/2 data-[side=right]:top-1/2! data-[side=right]:-left-1 data-[side=right]:-translate-y-1/2 data-[side=top]:-bottom-2.5"})]})})})}export{Ni,be,we,ke};
1
+ import{Tooltip as i}from"@base-ui/react/tooltip";import{cn as l}from"cn";import{jsx as o,jsxs as p}from"react/jsx-runtime";function bi({delay:t=0,...e}){return o(i.Provider,{"data-slot":"tooltip-provider",delay:t,...e})}function ye({...t}){return o(i.Root,{"data-slot":"tooltip",...t})}function be({...t}){return o(i.Trigger,{"data-slot":"tooltip-trigger",...t})}function we({className:t,side:e="top",sideOffset:a=4,align:d="center",alignOffset:r=0,children:n,...s}){return o(i.Portal,{children:o(i.Positioner,{align:d,alignOffset:r,side:e,sideOffset:a,className:"isolate z-50",children:p(i.Popup,{"data-slot":"tooltip-content",className:l("bg-foreground text-background data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=delayed-open]:animate-in data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95 z-50 inline-flex w-fit max-w-xs origin-(--transform-origin) items-center gap-1.5 rounded-md px-3 py-1.5 text-xs has-data-[slot=kbd]:pr-1.5 **:data-[slot=kbd]:relative **:data-[slot=kbd]:isolate **:data-[slot=kbd]:z-50 **:data-[slot=kbd]:rounded-sm",t),...s,children:[n,o(i.Arrow,{className:"bg-foreground fill-foreground z-50 size-2.5 translate-y-[calc(-50%-2px)] rotate-45 rounded-[2px] data-[side=bottom]:top-1 data-[side=inline-end]:top-1/2! data-[side=inline-end]:-left-1 data-[side=inline-end]:-translate-y-1/2 data-[side=inline-start]:top-1/2! data-[side=inline-start]:-right-1 data-[side=inline-start]:-translate-y-1/2 data-[side=left]:top-1/2! data-[side=left]:-right-1 data-[side=left]:-translate-y-1/2 data-[side=right]:top-1/2! data-[side=right]:-left-1 data-[side=right]:-translate-y-1/2 data-[side=top]:-bottom-2.5"})]})})})}export{bi,ye,be,we};
@@ -0,0 +1,2 @@
1
+ import{p,s,tt,r,T}from"./chunk-5fgakrmr.js";import{B}from"./chunk-6ss1981q.js";import{Je}from"./chunk-j2wty8a3.js";import{Qe}from"./chunk-qnk5jk1b.js";import{Ce,je}from"./chunk-f1zvbkak.js";import{hasRename as L}from"@nyssance/codex-acp-v2/client";import{ArchiveIcon as F,ArchiveRestoreIcon as D,GitForkIcon as x,PencilIcon as A,Trash2Icon as H}from"lucide-react";import{useRef as N,useState as g}from"react";import{jsx as n,jsxs as C,Fragment as y}from"react/jsx-runtime";function It({sessionRow:e,active:f,onSelect:u,onForked:v=u,onHoverCardOpenChange:a,actions:c}){let i=p(),{t:m,i18n:S}=i,k=s(),l=r((o)=>o.runStates[e.sessionId]),h=tt(),d=()=>u(e);return n(Je,{"data-session-id":e.sessionId,role:"button",tabIndex:0,active:f,onClick:d,onKeyDown:(o)=>{if(o.key==="Enter"||o.key===" ")o.preventDefault(),d()},state:l?.state,interruption:l?.interruption??null,title:e.title??m("sessionList.untitled"),onHoverCardOpenChange:a,hoverCard:n(R,{sessionRow:e,onDelete:()=>h(e),onForked:v,actions:c}),meta:e.updatedAt!==null?n("span",{className:"text-muted-foreground shrink-0 text-xs",children:Ce(e.updatedAt,S.language)}):void 0,actions:l!=null?n(Qe,{title:m("sessionList.stop"),onStop:()=>T(i,k.stopSession(e.sessionId))}):void 0})}function R({sessionRow:e,onDelete:f,onForked:u,actions:v}){let a=p(),{t:c}=a,i=s(),m=r((t)=>L(t.agent)),S=r((t)=>t.connection==="ready"&&t.agent?.capabilities?.session?.fork!=null),[k,l]=g(!1),[h,d]=g(!1),o=N(!1);return n(je,{sessionRow:e,renaming:k,onRename:(t)=>{if(l(!1),t!==null)T(a,i.renameSession(e.sessionId,t))},actions:C(y,{children:[m&&n(B,{icon:n(A,{}),label:c("sessionList.rename"),onClick:()=>l(!0)}),v,e.archived?n(B,{icon:n(D,{}),label:c("sessionList.unarchive"),onClick:()=>void T(a,i.unarchive(e.sessionId))}):C(y,{children:[n(B,{icon:n(x,{}),label:c("sessionList.fork"),disabled:!S||h,onClick:()=>{if(o.current)return;o.current=!0,d(!0),T(a,i.fork(e.sessionId,e.cwd).then((t)=>{let I=i.state.sessionList.find((b)=>b.sessionId===t);if(!I)throw Error("Forked chat is missing from the session list");u(I)}).finally(()=>{o.current=!1,d(!1)}))}}),n(B,{icon:n(F,{}),label:c("sessionList.archive"),onClick:()=>void T(a,i.archive(e.sessionId))})]}),n(B,{variant:"destructive",icon:n(H,{}),label:c("sessionList.delete"),onClick:f})]})})}
2
+ export{It};
@@ -1 +1 @@
1
- import{cn as a}from"cn";import{Loader2Icon as r}from"lucide-react";import{jsx as e}from"react/jsx-runtime";function fe({className:o,...n}){return e(r,{"data-slot":"spinner",role:"status","aria-label":"Loading",className:a("size-4 animate-spin",o),...n})}export{fe};
1
+ import{cn as a}from"cn";import{Loader2Icon as r}from"lucide-react";import{jsx as e}from"react/jsx-runtime";function ce({className:o,...n}){return e(r,{"data-slot":"spinner",role:"status","aria-label":"Loading",className:a("size-4 animate-spin",o),...n})}export{ce};
@@ -0,0 +1,2 @@
1
+ import{o}from"./chunk-dp8pjv6r.js";import{de,Pe,it}from"./chunk-j2wtwb37.js";import{jsx as t,jsxs as d,Fragment as r}from"react/jsx-runtime";var a=[];function rt({sessionId:s}){let e=o((n)=>n.actions),c=e.some((n)=>n.sessionId===s)?e.filter((n)=>n.sessionId===s):a,i=c.filter(de),l=c.filter((n)=>!de(n));return d(r,{children:[l.length>0&&t("div",{className:"mx-auto flex w-full max-w-3xl flex-col gap-3 px-6 pb-3","data-session-actions":!0,children:l.map((n)=>t(it,{action:n},n.id))}),i[0]!==void 0&&t(Pe,{action:i[0],total:i.length},i[0].id)]})}
2
+ export{rt};
@@ -1,2 +1,2 @@
1
- import{mo}from"./chunk-2ymhbrf9.js";function so(t,o){if(mo(o))return y(t);return t.map((e)=>({kind:"block",block:e}))}function i(t){return t.type==="thinking"||t.type==="tool_use"||t.type==="subagent"||t.type==="collab"}function c(t){return t.type==="tool_use"&&t.kind!=="think"}function y(t){let o=[],e=[],r=()=>{if(e.length===0)return;o.push({kind:"codexActivityGroup",blocks:e}),e=[]};for(let n of t){if(i(n)&&c(n)){e.push(n);continue}if(r(),i(n)){o.push({kind:"codexActivityGroup",blocks:[n]});continue}o.push({kind:"block",block:n})}return r(),o}
2
- export{so};
1
+ import{co}from"./chunk-w43dvzqk.js";function lo(t,o){if(co(o))return y(t);return t.map((e)=>({kind:"block",block:e}))}function i(t){return t.type==="thinking"||t.type==="tool_use"||t.type==="subagent"||t.type==="collab"}function c(t){return t.type==="tool_use"&&t.kind!=="think"}function y(t){let o=[],e=[],r=()=>{if(e.length===0)return;o.push({kind:"codexActivityGroup",blocks:e}),e=[]};for(let n of t){if(i(n)&&c(n)){e.push(n);continue}if(r(),i(n)){o.push({kind:"codexActivityGroup",blocks:[n]});continue}o.push({kind:"block",block:n})}return r(),o}
2
+ export{lo};
@@ -0,0 +1,2 @@
1
+ import{re}from"./chunk-dp8pjv6r.js";import{createContext as v,useContext as a,useMemo as l}from"react";import{jsx as r}from"react/jsx-runtime";var i=v(null);function ht({host:o,client:e,children:t}){let s=l(()=>({host:o,client:e}),[o,e]);return r(re,{host:o,client:e,children:r(i,{value:s,children:t})})}function n(){let o=a(i);if(o===null)throw Error("Conversation host is missing");return o}function C(o,e){e.catch((t)=>{if(o.reportError)o.reportError(t);else console.error(t)})}
2
+ export{ht,n,C};
@@ -1,2 +1,2 @@
1
- import{Do,te}from"./chunk-8dtaq4eh.js";import{_o}from"./chunk-nsns7rgs.js";import{rr,rn,an}from"./chunk-tjhwk02y.js";import{Wt,jt,Re,Ae,Kt}from"./chunk-3wg25354.js";import{cn as P}from"cn";import{ArrowUpIcon as fe,Loader2Icon as ge,SquareIcon as be,XIcon as ve}from"lucide-react";import{Children as Y,useCallback as h,useEffect as F,useMemo as he,useRef as M,useState as Pe}from"react";import{flushSync as Ie}from"react-dom";import{jsx as a,jsxs as ye}from"react/jsx-runtime";function Z(u){let o=new FormData(u).get("message");return typeof o==="string"?o:""}var No=({className:u,bashMode:o=!1,attachmentPolicy:I,onCommand:d,onSubmitError:y,canSubmit:f,onSubmitAsync:g,accept:E,multiple:ee,globalDrop:C,syncHiddenInput:R,maxFiles:z,maxFileSize:H,onError:b,onSubmit:re,children:ne,...oe})=>{let s=Ae(),l=!!s,se=o&&l&&s.textInput.value.startsWith("!"),x=M(null),A=M(null),k=M(!1),[ie,D]=Pe([]),c=l?s.attachments.files:ie,B=M(c);B.current=c;let ae=h(()=>{x.current?.click()},[]),O=h((e)=>{if(!E||E.trim()==="")return!0;return E.split(",").map((t)=>t.trim()).filter(Boolean).some((t)=>{if(t.endsWith("/*")){let n=t.slice(0,-1);return e.type.startsWith(n)}return e.type===t})},[E]),W=h((e)=>{if(e.type)return e.type;let r=(e.name||"").toLowerCase();if(r.endsWith(".png"))return"image/png";if(r.endsWith(".jpg")||r.endsWith(".jpeg"))return"image/jpeg";if(r.endsWith(".webp"))return"image/webp";if(r.endsWith(".gif"))return"image/gif";if(r.endsWith(".bmp"))return"image/bmp";if(r.endsWith(".svg"))return"image/svg+xml";return""},[]),ue=h((e)=>{let r=[...e],t=r.filter((i)=>O(i));if(r.length&&t.length===0){b?.({code:"accept",message:"No files match the accepted types."});return}let n=(i)=>H?i.size<=H:!0,m=t.filter(n);if(t.length>0&&m.length===0){b?.({code:"max_file_size",message:"All files exceed the maximum size."});return}D((i)=>{let v=I?I.uniqueFiles(m,i):m,p=typeof z==="number"?Math.max(0,z-i.length):void 0,_=typeof p==="number"?v.slice(0,p):v;if(typeof p==="number"&&v.length>p)b?.({code:"max_files",message:"Too many files. Some were not added."});let Q=[];for(let T of _){let V=I?.sourcePath(T);Q.push({id:crypto.randomUUID(),type:"file",url:URL.createObjectURL(T),mediaType:W(T),filename:T.name,size:T.size,lastModified:T.lastModified,...V===void 0?{}:{sourcePath:V}})}return[...i,...Q]})},[I,W,O,z,H,b]),le=h((e)=>D((r)=>{let t=r.find((n)=>n.id===e);if(t?.url)URL.revokeObjectURL(t.url);return r.filter((n)=>n.id!==e)}),[]),pe=h(()=>D((e)=>{for(let r of e)if(r.url)URL.revokeObjectURL(r.url);return[]}),[]),G=l?s.attachments.add:ue,L=h((e)=>{let r=[...e],t=r.filter((m)=>!(m.type??"").toLowerCase().startsWith("image/"));if(t.length>0){b?.({code:"unsupported_type",message:`Only image attachments are supported. ${t.length} non-image file(s) were ignored.`});return}let n=r.reduce((m,i)=>m+i.size,0);if(n>0){let m=c.filter((i)=>(i.mediaType??"").toLowerCase().startsWith("image/")).reduce((i,v)=>i+(v.size??0),0);if(Do(m,n)){b?.({code:"max_total_size",message:`Total image size must not exceed ${te}MB.`});return}}G(r)},[c,G,b]),j=l?s.attachments.remove:le,N=l?s.attachments.clear:pe,q=l?s.attachments.openFileDialog:ae;F(()=>{if(!l)return;s.__registerFileInput(x,()=>x.current?.click())},[l,s]),F(()=>{if(R&&x.current&&c.length===0)x.current.value=""},[c,R]),F(()=>{let e=A.current;if(!e)return;if(C)return;let r=(n)=>{if(n.dataTransfer?.types?.includes("Files"))n.preventDefault()},t=(n)=>{if(n.dataTransfer?.types?.includes("Files"))n.preventDefault();if(n.dataTransfer?.files&&n.dataTransfer.files.length>0)L(n.dataTransfer.files)};return e.addEventListener("dragover",r),e.addEventListener("drop",t),()=>{e.removeEventListener("dragover",r),e.removeEventListener("drop",t)}},[L,C]),F(()=>{if(!C)return;let e=(t)=>{if(t.dataTransfer?.types?.includes("Files"))t.preventDefault()},r=(t)=>{if(t.dataTransfer?.types?.includes("Files"))t.preventDefault();if(t.dataTransfer?.files&&t.dataTransfer.files.length>0)L(t.dataTransfer.files)};return document.addEventListener("dragover",e),document.addEventListener("drop",r),()=>{document.removeEventListener("dragover",e),document.removeEventListener("drop",r)}},[L,C]),F(()=>()=>{if(!l){for(let e of B.current)if(e.url)URL.revokeObjectURL(e.url)}},[l]);let me=(e)=>{if(e.currentTarget.files)L(e.currentTarget.files);e.currentTarget.value=""},X=he(()=>({files:c.map((e)=>({...e,id:e.id})),add:L,remove:j,clear:N,openFileDialog:q,fileInputRef:x}),[c,L,j,N,q]),w=M({controller:s,files:c,canSubmit:f});w.current={controller:s,files:c,canSubmit:f};let S=M(!0);F(()=>(S.current=!0,()=>{S.current=!1}),[]);let J=async(e)=>{let r=f===void 0?!0:f();if(r!==!0)return{status:"blocked",reason:r};if(k.current)return{status:"blocked",reason:"submission_pending"};if(e===null&&g===void 0)throw Error("Awaitable submission requires onSubmitAsync");let t=A.current;if(t===null)return{status:"blocked",reason:"form_unmounted"};let n=l?s.textInput.value:Z(t),m=s?.textInput.getRevision?.(),i=c,v=()=>{if(!S.current)return;let p=w.current;if(p.files!==i)return;if(l){if(m===void 0||p.controller===null||p.controller.textInput.getRevision?.()!==m)return;if(p.controller.textInput.clearSubmitted===void 0)p.controller.textInput.clear();else p.controller.textInput.clearSubmitted()}else if(Z(t)===n)t.reset();N()};k.current=!0;try{if(d?.(n.trim()))return v(),{status:"accepted"};let p=await _o(i),_=w.current.canSubmit===void 0?!0:w.current.canSubmit();if(_!==!0)return{status:"blocked",reason:_};if(!S.current)return{status:"blocked",reason:"form_unmounted"};if(p.rejectedCount>0)b?.({code:"accept",message:"One or more images are corrupted and were removed before sending."});if(g!==void 0)await g({text:n,files:p.files});else if(e!==null)await re({text:n,files:p.files},e);return v(),{status:"accepted"}}finally{k.current=!1}},ce=(e)=>{e.preventDefault(),J(e).catch(y)},de=h((e)=>{if(!e.trim())return;if(l&&s)Ie(()=>{s.textInput.setInput(e)});A.current?.requestSubmit()},[s,l]),K=a(jt.Provider,{value:()=>J(null),children:ye(Wt.Provider,{value:de,children:[a("input",{accept:E,"aria-label":"Upload files",className:"hidden",multiple:ee,onChange:me,ref:x,title:"Upload files",type:"file"}),a("form",{className:P("w-full",u),onSubmit:ce,ref:A,"data-tour":"chat-input",...oe,children:a(rr,{className:P("codex-composer-surface overflow-y-auto has-[[data-slot=input-group-control]:focus-visible]:ring-0",se&&"border! border-[rgb(255,0,135)] has-[[data-slot=input-group-control]:focus-visible]:border-[rgb(255,0,135)] dark:border-[rgb(253,93,177)] dark:has-[[data-slot=input-group-control]:focus-visible]:border-[rgb(253,93,177)]"),children:ne})})]})});return l?a(Re.Provider,{value:X,children:K}):a(Kt.Provider,{value:X,children:K})};function Mo({className:u,...o}){return a("div",{className:P("flex w-full min-w-0 flex-row items-end gap-2",u),...o})}function Ro({className:u,...o}){return a(rn,{align:"block-end",className:P("order-first flex-wrap gap-1 p-2 pb-1.5",u),...o})}function Eo({className:u,...o}){return a(rn,{align:"block-end",className:P("mt-3.5 justify-between gap-1 p-0",u),...o})}function Ao({className:u,...o}){return a("div",{className:P("flex items-center gap-1",u),...o})}var U=({variant:u="ghost",className:o,size:I,collapsed:d=!1,...y})=>{let f=d||Y.count(y.children)<=1?"icon-xs":"xs";return a(an,{className:P("h-7 rounded-full text-xs font-medium hover:bg-transparent dark:hover:bg-transparent",(d||Y.count(y.children)<=1)&&"size-7",o),size:f,type:"button",variant:u,...y})},Lo=({className:u,variant:o="ghost",size:I="icon-xs",status:d,children:y,...f})=>{let g=a(fe,{className:"size-4"});if(d==="submitted")g=a(ge,{className:"size-4 animate-spin"});else if(d==="streaming")g=a(be,{className:"size-3 fill-current"});else if(d==="error")g=a(ve,{className:"size-4"});return a(an,{"aria-label":"Submit",className:P("bg-foreground text-background hover:bg-foreground/70 size-7 rounded-full p-0 transition-opacity disabled:opacity-50",u),size:I,type:"submit",variant:o,...f,children:y??g})};
2
- export{No,Mo,Ro,Eo,Ao,U,Lo};
1
+ import{Jo,oe}from"./chunk-0kwfy29d.js";import{er}from"./chunk-6amcjhqh.js";import{nr,on,rn}from"./chunk-7h8pv9eg.js";import{sn,ln,Be,Ue,cn}from"./chunk-cpk3y6ad.js";import{cn as P}from"cn";import{ArrowUpIcon as fe,Loader2Icon as ge,SquareIcon as be,XIcon as ve}from"lucide-react";import{Children as Y,useCallback as h,useEffect as F,useMemo as he,useRef as M,useState as Pe}from"react";import{flushSync as Ie}from"react-dom";import{jsx as a,jsxs as ye}from"react/jsx-runtime";function Z(u){let o=new FormData(u).get("message");return typeof o==="string"?o:""}var jo=({className:u,bashMode:o=!1,attachmentPolicy:I,onCommand:d,onSubmitError:y,canSubmit:f,onSubmitAsync:g,accept:E,multiple:ee,globalDrop:C,syncHiddenInput:R,maxFiles:z,maxFileSize:H,onError:b,onSubmit:te,children:re,...ne})=>{let s=Ue(),l=!!s,se=o&&l&&s.textInput.value.startsWith("!"),x=M(null),A=M(null),k=M(!1),[ie,D]=Pe([]),c=l?s.attachments.files:ie,U=M(c);U.current=c;let ae=h(()=>{x.current?.click()},[]),B=h((e)=>{if(!E||E.trim()==="")return!0;return E.split(",").map((t)=>t.trim()).filter(Boolean).some((t)=>{if(t.endsWith("/*")){let n=t.slice(0,-1);return e.type.startsWith(n)}return e.type===t})},[E]),O=h((e)=>{if(e.type)return e.type;let r=(e.name||"").toLowerCase();if(r.endsWith(".png"))return"image/png";if(r.endsWith(".jpg")||r.endsWith(".jpeg"))return"image/jpeg";if(r.endsWith(".webp"))return"image/webp";if(r.endsWith(".gif"))return"image/gif";if(r.endsWith(".bmp"))return"image/bmp";if(r.endsWith(".svg"))return"image/svg+xml";return""},[]),ue=h((e)=>{let r=[...e],t=r.filter((i)=>B(i));if(r.length&&t.length===0){b?.({code:"accept",message:"No files match the accepted types."});return}let n=(i)=>H?i.size<=H:!0,m=t.filter(n);if(t.length>0&&m.length===0){b?.({code:"max_file_size",message:"All files exceed the maximum size."});return}D((i)=>{let v=I?I.uniqueFiles(m,i):m,p=typeof z==="number"?Math.max(0,z-i.length):void 0,_=typeof p==="number"?v.slice(0,p):v;if(typeof p==="number"&&v.length>p)b?.({code:"max_files",message:"Too many files. Some were not added."});let Q=[];for(let T of _){let V=I?.sourcePath(T);Q.push({id:crypto.randomUUID(),type:"file",url:URL.createObjectURL(T),mediaType:O(T),filename:T.name,size:T.size,lastModified:T.lastModified,...V===void 0?{}:{sourcePath:V}})}return[...i,...Q]})},[I,O,B,z,H,b]),le=h((e)=>D((r)=>{let t=r.find((n)=>n.id===e);if(t?.url)URL.revokeObjectURL(t.url);return r.filter((n)=>n.id!==e)}),[]),pe=h(()=>D((e)=>{for(let r of e)if(r.url)URL.revokeObjectURL(r.url);return[]}),[]),W=l?s.attachments.add:ue,L=h((e)=>{let r=[...e],t=r.filter((m)=>!(m.type??"").toLowerCase().startsWith("image/"));if(t.length>0){b?.({code:"unsupported_type",message:`Only image attachments are supported. ${t.length} non-image file(s) were ignored.`});return}let n=r.reduce((m,i)=>m+i.size,0);if(n>0){let m=c.filter((i)=>(i.mediaType??"").toLowerCase().startsWith("image/")).reduce((i,v)=>i+(v.size??0),0);if(Jo(m,n)){b?.({code:"max_total_size",message:`Total image size must not exceed ${oe}MB.`});return}}W(r)},[c,W,b]),G=l?s.attachments.remove:le,N=l?s.attachments.clear:pe,j=l?s.attachments.openFileDialog:ae;F(()=>{if(!l)return;s.__registerFileInput(x,()=>x.current?.click())},[l,s]),F(()=>{if(R&&x.current&&c.length===0)x.current.value=""},[c,R]),F(()=>{let e=A.current;if(!e)return;if(C)return;let r=(n)=>{if(n.dataTransfer?.types?.includes("Files"))n.preventDefault()},t=(n)=>{if(n.dataTransfer?.types?.includes("Files"))n.preventDefault();if(n.dataTransfer?.files&&n.dataTransfer.files.length>0)L(n.dataTransfer.files)};return e.addEventListener("dragover",r),e.addEventListener("drop",t),()=>{e.removeEventListener("dragover",r),e.removeEventListener("drop",t)}},[L,C]),F(()=>{if(!C)return;let e=(t)=>{if(t.dataTransfer?.types?.includes("Files"))t.preventDefault()},r=(t)=>{if(t.dataTransfer?.types?.includes("Files"))t.preventDefault();if(t.dataTransfer?.files&&t.dataTransfer.files.length>0)L(t.dataTransfer.files)};return document.addEventListener("dragover",e),document.addEventListener("drop",r),()=>{document.removeEventListener("dragover",e),document.removeEventListener("drop",r)}},[L,C]),F(()=>()=>{if(!l){for(let e of U.current)if(e.url)URL.revokeObjectURL(e.url)}},[l]);let me=(e)=>{if(e.currentTarget.files)L(e.currentTarget.files);e.currentTarget.value=""},q=he(()=>({files:c.map((e)=>({...e,id:e.id})),add:L,remove:G,clear:N,openFileDialog:j,fileInputRef:x}),[c,L,G,N,j]),w=M({controller:s,files:c,canSubmit:f});w.current={controller:s,files:c,canSubmit:f};let S=M(!0);F(()=>(S.current=!0,()=>{S.current=!1}),[]);let X=async(e)=>{let r=f===void 0?!0:f();if(r!==!0)return{status:"blocked",reason:r};if(k.current)return{status:"blocked",reason:"submission_pending"};if(e===null&&g===void 0)throw Error("Awaitable submission requires onSubmitAsync");let t=A.current;if(t===null)return{status:"blocked",reason:"form_unmounted"};let n=l?s.textInput.value:Z(t),m=s?.textInput.getRevision?.(),i=c,v=()=>{if(!S.current)return;let p=w.current;if(p.files!==i)return;if(l){if(m===void 0||p.controller===null||p.controller.textInput.getRevision?.()!==m)return;if(p.controller.textInput.clearSubmitted===void 0)p.controller.textInput.clear();else p.controller.textInput.clearSubmitted()}else if(Z(t)===n)t.reset();N()};k.current=!0;try{if(d?.(n.trim()))return v(),{status:"accepted"};let p=await er(i),_=w.current.canSubmit===void 0?!0:w.current.canSubmit();if(_!==!0)return{status:"blocked",reason:_};if(!S.current)return{status:"blocked",reason:"form_unmounted"};if(p.rejectedCount>0)b?.({code:"accept",message:"One or more images are corrupted and were removed before sending."});if(g!==void 0)await g({text:n,files:p.files});else if(e!==null)await te({text:n,files:p.files},e);return v(),{status:"accepted"}}finally{k.current=!1}},ce=(e)=>{e.preventDefault(),X(e).catch(y)},de=h((e)=>{if(!e.trim())return;if(l&&s)Ie(()=>{s.textInput.setInput(e)});A.current?.requestSubmit()},[s,l]),J=a(ln.Provider,{value:()=>X(null),children:ye(sn.Provider,{value:de,children:[a("input",{accept:E,"aria-label":"Upload files",className:"hidden",multiple:ee,onChange:me,ref:x,title:"Upload files",type:"file"}),a("form",{className:P("w-full",u),onSubmit:ce,ref:A,"data-tour":"chat-input",...ne,children:a(nr,{className:P("codex-composer-surface overflow-y-auto has-[[data-slot=input-group-control]:focus-visible]:ring-0",se&&"border! border-[rgb(255,0,135)] has-[[data-slot=input-group-control]:focus-visible]:border-[rgb(255,0,135)] dark:border-[rgb(253,93,177)] dark:has-[[data-slot=input-group-control]:focus-visible]:border-[rgb(253,93,177)]"),children:re})})]})});return l?a(Be.Provider,{value:q,children:J}):a(cn.Provider,{value:q,children:J})};function Ko({className:u,...o}){return a("div",{className:P("flex w-full min-w-0 flex-row items-end gap-2",u),...o})}function Qo({className:u,...o}){return a(on,{align:"block-end",className:P("order-first flex-wrap gap-1 p-2 pb-1.5",u),...o})}function Xo({className:u,...o}){return a(on,{align:"block-end",className:P("mt-3.5 justify-between gap-1 p-0",u),...o})}function Yo({className:u,...o}){return a("div",{className:P("flex items-center gap-1",u),...o})}var K=({variant:u="ghost",className:o,size:I,collapsed:d=!1,...y})=>{let f=d||Y.count(y.children)<=1?"icon-xs":"xs";return a(rn,{className:P("h-7 rounded-full text-xs font-medium hover:bg-transparent dark:hover:bg-transparent",(d||Y.count(y.children)<=1)&&"size-7",o),size:f,type:"button",variant:u,...y})},Zo=({className:u,variant:o="ghost",size:I="icon-xs",status:d,children:y,...f})=>{let g=a(fe,{className:"size-4"});if(d==="submitted")g=a(ge,{className:"size-4 animate-spin"});else if(d==="streaming")g=a(be,{className:"size-3 fill-current"});else if(d==="error")g=a(ve,{className:"size-4"});return a(rn,{"aria-label":"Submit",className:P("bg-foreground text-background hover:bg-foreground/70 size-7 rounded-full p-0 transition-opacity disabled:opacity-50",u),size:I,type:"submit",variant:o,...f,children:y??g})};
2
+ export{jo,Ko,Qo,Xo,Yo,K,Zo};
@@ -1,2 +1,2 @@
1
- import{PreviewCard as e}from"@base-ui/react/preview-card";import{jsx as o,jsxs as d}from"react/jsx-runtime";function wo({open:r,onOpenChange:a,trigger:i,children:t,...n}){return d(e.Root,{open:r,onOpenChange:a,children:[o(e.Trigger,{render:i,delay:700,closeDelay:100}),o(e.Portal,{children:o(e.Positioner,{...n,className:"isolate z-50",children:o(e.Popup,{"data-slot":"codex-hover-card",className:"m-0 outline-hidden",children:t})})})]})}
2
- export{wo};
1
+ import{PreviewCard as e}from"@base-ui/react/preview-card";import{jsx as o,jsxs as d}from"react/jsx-runtime";function Qn({open:r,onOpenChange:a,trigger:i,children:t,...n}){return d(e.Root,{open:r,onOpenChange:a,children:[o(e.Trigger,{render:i,delay:700,closeDelay:100}),o(e.Portal,{children:o(e.Positioner,{...n,className:"isolate z-50",children:o(e.Popup,{"data-slot":"codex-hover-card",className:"m-0 outline-hidden",children:t})})})]})}
2
+ export{Qn};
@@ -0,0 +1,2 @@
1
+ import{e}from"./chunk-6kn920c5.js";import{H,O,P,F,te,N,_e,He,Oe,nn,M}from"./chunk-qah4fs3d.js";import{$e}from"./chunk-ak0k5vg6.js";import{ye,be,we}from"./chunk-wb3zpzk3.js";import{tn}from"./chunk-e11qjnb4.js";import{h}from"./chunk-rnykpmn2.js";import{cn as m}from"cn";import{ArrowUpRight as se,ChevronUp as G,Loader2Icon as U,Zap as W}from"lucide-react";import{Fragment as ie,useState as Z}from"react";import{jsx as n,jsxs as s,Fragment as p}from"react/jsx-runtime";function zo({value:c,onChange:q,models:v,modelGroups:C,compactCatalog:l,effortPresentation:R="slider",unavailableEffort:D,providerMenu:w,header:g,className:I,condensed:T,stripLabelPrefix:V,showDescription:J,showModelList:K=!0,loading:Q,switching:A,isLoading:X,effortConfig:i,booleanOptions:f,onBooleanChange:z,selectOptions:Y=[],t:u,...r}){let[E,ee]=Z(!1),[ne,ae]=Z(!1),d=f?.find((a)=>a.id==="fast_mode"),_=l?f?.filter((a)=>a!==d):f,L=(a)=>V&&a.startsWith(V)?a.slice(V.length):a;if(Q)return n("div",{className:"inline-flex min-w-0 items-center gap-1.5",children:s(e,{variant:"ghost",disabled:!0,className:m("h-7 min-w-0 shrink gap-1.5 rounded-md px-2 text-xs font-normal",I),children:[n(U,{className:"size-3 animate-spin"}),n("span",{className:"text-muted-foreground truncate",children:u("model.loadingModels")})]})});return s("div",{className:"inline-flex min-w-0 items-center gap-1.5",children:[w&&s(H,{open:E,onOpenChange:ee,children:[s(ye,{children:[n(be,{render:n(O,{render:s(e,{"data-testid":"provider-trigger",variant:"ghost",disabled:r.disabled,className:m("h-7 shrink-0 gap-1 rounded-md px-1.5","hover:bg-accent"),children:[w.icon,n(G,{className:"size-2.5 shrink-0 opacity-60"})]})})}),n(we,{children:u("model.switchProvider")})]}),s(P,{side:"top",align:"end",sideOffset:4,className:"z-100 min-w-[10rem]",children:[w.groups.map((a,t)=>s(ie,{children:[t>0&&a.length>0&&n(M,{}),n(h,{value:w.value,onValueChange:w.onChange,options:a})]},t)),w.moreAction&&s(p,{children:[n(M,{}),s(N,{onClick:w.moreAction,className:"whitespace-nowrap",children:[n("span",{className:"min-w-0 flex-1 truncate",children:u("model.moreModels")}),n(se,{className:"size-4"})]})]})]})]}),s(H,{open:ne,onOpenChange:ae,children:[s(ye,{children:[n(be,{render:n(O,{render:s(e,{"data-testid":"model-trigger","aria-busy":A,variant:"ghost",className:m("h-7 gap-1.5 rounded-md px-2 text-xs font-normal","hover:bg-accent","max-w-full min-w-0 shrink",T&&"h-7 gap-1 px-1.5 text-[11px]",I),...r,children:[c.icon,f?.some((a)=>a.id==="fast_mode"&&a.currentValue&&!a.disabled)&&n(W,{"aria-hidden":"true",className:"size-3 shrink-0 fill-current"}),n("span",{className:m("min-w-0 flex-1 truncate text-start",T&&"text-[11px]"),children:L(c.label)||u("model.selectModel")}),i&&s("span",{className:"text-muted-foreground grid shrink-0 justify-items-center",children:[n("span",{className:"invisible col-start-1 row-start-1",children:i.sizer??i.levels.reduce((a,t)=>t.name.length>a.length?t.name:a,"")}),n("span",{className:"col-start-1 row-start-1",children:i.levels.find((a)=>a.value===i.value)?.name??i.value})]}),A?n(U,{"data-testid":"model-switch-loading",className:"size-3 shrink-0 animate-spin"}):n(G,{className:m("size-3 shrink-0",T&&"size-2.5")})]})})}),n(we,{children:u("model.switchModel")})]}),s(P,{side:"top",align:"end",sideOffset:4,className:m("z-100 w-auto max-w-[min(24rem,calc(100vw-1rem))] min-w-[14rem]",l&&"flex h-[350px] w-80 min-w-0 flex-col overflow-hidden rounded-xl p-1.5"),children:[l&&s(p,{children:[s(F,{"data-model-menu-header":!0,className:"flex shrink-0 items-center justify-between gap-2 px-1 py-1",children:[i?R==="slider"?n("div",{role:"menuitem","aria-label":i.name,className:"min-w-0 [&>div]:justify-start [&>div]:gap-3 [&>div]:px-2 [&>div]:py-1.5",children:n(tn,{...i,disabled:r.disabled})}):s(_e,{children:[s(He,{disabled:r.disabled,className:"h-8 min-w-0 flex-1 gap-2 rounded-md",children:[n("span",{children:i.name}),n("span",{className:"text-muted-foreground min-w-0 truncate text-xs",children:i.levels.find((a)=>a.value===i.value)?.name??i.value})]}),n(Oe,{children:n(h,{value:i.value,onValueChange:i.onChange,options:i.levels.map((a)=>({value:a.value,label:a.name}))})})]}):D?s(N,{disabled:!0,className:"h-8 min-w-0 flex-1 gap-2",children:[n("span",{children:D.name}),n("span",{className:"text-muted-foreground truncate text-xs",children:D.label})]}):n(te,{className:"min-w-0 flex-1 truncate",children:g?.name}),d&&n(nn,{"aria-label":d.name,title:d.title??d.name,disabled:r.disabled||d.disabled,checked:d.currentValue,closeOnClick:!1,onCheckedChange:(a)=>z?.(d.id,a),className:m("hover:bg-accent focus:hover:bg-accent focus-visible:bg-accent ml-auto size-8 shrink-0 justify-center rounded-md p-0 focus:bg-transparent [&_[data-slot=dropdown-menu-checkbox-item-indicator]]:hidden",d.currentValue&&!d.disabled?"text-foreground [&_svg]:fill-current":"text-muted-foreground"),children:d.icon??n(W,{className:"size-4","aria-hidden":"true"})})]}),n(M,{className:"shrink-0"})]}),g&&!l&&s(p,{children:[s("div",{className:"flex items-center gap-2 px-2 py-2",children:[g.icon,n("span",{className:"min-w-0 flex-1 truncate text-sm font-medium",children:g.name}),g.action]}),n(M,{})]}),s(F,{"data-model-menu-list":l?"":void 0,className:l?"min-h-0 min-w-0 flex-1 overflow-x-hidden overflow-y-auto overscroll-contain":void 0,children:[K&&(X?n(N,{disabled:!0,className:"text-muted-foreground",children:u("model.loadingModels")}):v.length===0?n(N,{disabled:!0,className:"text-muted-foreground",children:u("model.noModelsAvailable")}):(()=>{let a=v.filter((o)=>!o.more),t=v.filter((o)=>o.more),j=a.length>0&&t.length>0,y=(o,b)=>({disabled:r.disabled,icon:o.icon,value:o.api_id,label:L(o.label),description:b?.noDescription?void 0:J?o.description:void 0}),k=(o)=>{let b=v.find((S)=>S.api_id===o);if(b)q(b)};if(l)return n(h,{value:c.api_id,onValueChange:k,itemClassName:"min-w-0 max-w-full font-normal whitespace-nowrap",options:v.map((o)=>y(o))});return s(p,{children:[C?C.map((o)=>{let b=o.models.filter((x)=>!x.more),S=o.models.filter((x)=>x.more),B=b.length>0&&S.length>0;return s(F,{children:[n(te,{className:"text-muted-foreground text-xs font-normal",children:o.name}),n(h,{value:c.api_id,onValueChange:k,itemClassName:"font-medium whitespace-nowrap",options:(B?b:o.models).map((x)=>y(x))}),B&&s(_e,{children:[n(He,{className:"font-medium whitespace-nowrap",children:u("model.moreModels")}),n(Oe,{children:n(h,{value:c.api_id,onValueChange:k,itemClassName:"font-medium whitespace-nowrap",options:S.map((x)=>y(x,{noDescription:!0}))})})]})]},o.id)}):n(h,{value:c.api_id,onValueChange:k,itemClassName:"font-medium whitespace-nowrap",options:(j?a:v).map((o)=>y(o))}),!C&&j&&s(_e,{children:[n(He,{className:"font-medium whitespace-nowrap",children:u("model.moreModels")}),n(Oe,{children:n(h,{value:c.api_id,onValueChange:k,itemClassName:"font-medium whitespace-nowrap",options:t.map((o)=>y(o,{noDescription:!0}))})})]})]})})()),!l&&i&&s(p,{children:[n(M,{}),R==="menu"?s(_e,{children:[s(He,{disabled:r.disabled,children:[n("span",{className:"flex-1",children:i.name}),n("span",{className:"text-muted-foreground",children:i.levels.find((a)=>a.value===i.value)?.name??i.value})]}),n(Oe,{children:n(h,{value:i.value,onValueChange:i.onChange,options:i.levels.map((a)=>({value:a.value,label:a.name}))})})]}):n(tn,{...i,disabled:r.disabled})]}),!l&&!i&&D&&s(p,{children:[n(M,{}),s(N,{disabled:!0,children:[n("span",{className:"flex-1",children:D.name}),n("span",{children:D.label})]})]}),Y.map((a)=>s(F,{children:[n(M,{}),n(te,{children:a.name}),n(h,{value:a.value,onValueChange:a.onChange,options:a.options,itemClassName:"whitespace-nowrap"})]},a.id)),_&&_.length>0&&s(p,{children:[!i&&n(M,{}),_.map((a)=>l?s(nn,{"aria-label":a.name,title:a.title,disabled:r.disabled||a.disabled,checked:a.currentValue,closeOnClick:!1,onCheckedChange:(t)=>z?.(a.id,t),className:"justify-between gap-3 py-2.5 pr-2 [&_[data-slot=dropdown-menu-checkbox-item-indicator]]:hidden",children:[s("span",{className:"flex items-center gap-2",children:[a.icon,a.name]}),n("span",{"aria-hidden":"true",className:m("flex h-[18px] w-8 shrink-0 items-center rounded-full p-0.5",a.currentValue?"bg-primary":"bg-input"),children:n("span",{className:m("bg-background size-3.5 rounded-full shadow-xs transition-transform",a.currentValue&&"translate-x-3.5")})})]},a.id):s("div",{title:a.title,className:m("flex items-center justify-between gap-3 px-2 py-2.5",a.disabled&&"opacity-50"),children:[s("span",{className:"flex items-center gap-2 text-sm font-medium",children:[a.icon,a.name]}),n($e,{"aria-label":a.name,disabled:r.disabled||a.disabled,checked:a.currentValue,onCheckedChange:(t)=>z?.(a.id,t)})]},a.id))]})]}),l&&g?.action&&s(p,{children:[n(M,{className:"shrink-0"}),n(F,{"data-model-menu-footer":!0,className:"shrink-0",children:g.action})]})]})]})]})}
2
+ export{zo};
@@ -1,2 +1,2 @@
1
- import{cn as a}from"cn";import{useRef as u,useState as E}from"react";import{jsx as l}from"react/jsx-runtime";var M=45,d=8;function _({className:i,children:p,onMouseEnter:c,onMouseLeave:f,...m}){let s=u(null),[t,r]=E(0);return l("span",{className:a("min-w-0 overflow-hidden",i),onMouseEnter:(e)=>{let n=s.current;if(!n)return;let o=n.scrollWidth-n.clientWidth;if(o>d)r(getComputedStyle(n).direction==="rtl"?o:-o);c?.(e)},onMouseLeave:(e)=>{r(0),f?.(e)},...m,children:l("span",{ref:s,className:a("block whitespace-nowrap",t===0?"truncate":"overflow-visible"),style:{transform:`translateX(${t}px)`,transition:`transform ${Math.abs(t)/M}s linear`},children:p})})}
2
- export{_};
1
+ import{cn as a}from"cn";import{useRef as u,useState as E}from"react";import{jsx as l}from"react/jsx-runtime";var M=45,d=8;function A({className:i,children:p,onMouseEnter:c,onMouseLeave:f,...m}){let s=u(null),[t,r]=E(0);return l("span",{className:a("min-w-0 overflow-hidden",i),onMouseEnter:(e)=>{let n=s.current;if(!n)return;let o=n.scrollWidth-n.clientWidth;if(o>d)r(getComputedStyle(n).direction==="rtl"?o:-o);c?.(e)},onMouseLeave:(e)=>{r(0),f?.(e)},...m,children:l("span",{ref:s,className:a("block whitespace-nowrap",t===0?"truncate":"overflow-visible"),style:{transform:`translateX(${t}px)`,transition:`transform ${Math.abs(t)/M}s linear`},children:p})})}
2
+ export{A};
@@ -1 +1 @@
1
- import{uo,Me}from"../chunk-rqnvygqy.js";import"../chunk-dnhmnmgf.js";import"../chunk-2ymhbrf9.js";import"../chunk-9w0w5by0.js";import"../chunk-ckft9abb.js";import"../chunk-fjwg3y8h.js";import"../chunk-46gb51y9.js";export{Me as CodexActivityGroup,uo as CodexWorkSection};
1
+ import{ao,Me}from"../chunk-9a4kjze3.js";import"../chunk-p8nx34zm.js";import"../chunk-51sbmqdk.js";import"../chunk-w43dvzqk.js";import"../chunk-6edz9f7j.js";import"../chunk-w8qmh6he.js";import"../chunk-ryz4c13z.js";export{Me as CodexActivityGroup,ao as CodexWorkSection};
@@ -1 +1 @@
1
- import{ni,_t,Ht}from"../chunk-wzjq9j6g.js";import"../chunk-gq30yqjk.js";import"../chunk-83dkw1mh.js";import"../chunk-951wn2bd.js";import"../chunk-rqnvygqy.js";import"../chunk-dnhmnmgf.js";import"../chunk-2ymhbrf9.js";import"../chunk-9w0w5by0.js";import"../chunk-ckft9abb.js";import"../chunk-fjwg3y8h.js";import"../chunk-5f4m4ptz.js";import"../chunk-46gb51y9.js";export{ni as CodexAssistantMessage,Ht as CodexAssistantTurn,_t as CodexMessageActions};
1
+ import{ui,Ft,Bt}from"../chunk-93x6b2qa.js";import"../chunk-9a4kjze3.js";import"../chunk-p8nx34zm.js";import"../chunk-51sbmqdk.js";import"../chunk-ynw0f8h2.js";import"../chunk-w43dvzqk.js";import"../chunk-6edz9f7j.js";import"../chunk-50qyant6.js";import"../chunk-sr5rcdza.js";import"../chunk-0n240acr.js";import"../chunk-w8qmh6he.js";import"../chunk-ryz4c13z.js";export{ui as CodexAssistantMessage,Bt as CodexAssistantTurn,Ft as CodexMessageActions};
@@ -1 +1 @@
1
- import{p,At,ro,Lt,io,Dt,ao}from"../chunk-j4cm74nv.js";import"../chunk-erzjz56d.js";import"../chunk-6kn920c5.js";import"../chunk-xjtqdp82.js";import"../chunk-kjtd3wc3.js";export{ao as AsyncQuestionCard,At as asyncQuestionId,p as asyncQuestions,ro as initialQuestionDraft,Lt as questionAnswer,Dt as questionReplies,io as questionReplyEnvelope};
1
+ import{g,Kt,wo,Qt,ko,Xt,Co}from"../chunk-5kpcpjrb.js";import"../chunk-5m4605a3.js";import"../chunk-ek06eyp4.js";import"../chunk-ncekagm6.js";import"../chunk-6kn920c5.js";export{Co as AsyncQuestionCard,Kt as asyncQuestionId,g as asyncQuestions,wo as initialQuestionDraft,Qt as questionAnswer,Xt as questionReplies,ko as questionReplyEnvelope};
@@ -1 +1 @@
1
- import{I}from"../chunk-ckft9abb.js";export{I as useCodexDisclosureState};
1
+ import{S}from"../chunk-51sbmqdk.js";export{S as useCodexDisclosureState};
@@ -1 +1 @@
1
- import{Or,go,Bt}from"../chunk-5f4m4ptz.js";import"../chunk-46gb51y9.js";export{go as CodexEditedFilesCard,Bt as EditedFilesCard,Or as fileChanges};
1
+ import{Or,mo,Ut}from"../chunk-50qyant6.js";import"../chunk-ryz4c13z.js";export{mo as CodexEditedFilesCard,Ut as EditedFilesCard,Or as fileChanges};
@@ -1 +1 @@
1
- import{ue,po}from"../chunk-9w0w5by0.js";import"../chunk-ckft9abb.js";import"../chunk-46gb51y9.js";export{po as ImageViewActivity,ue as isImageView};
1
+ import{pe,so}from"../chunk-p8nx34zm.js";import"../chunk-51sbmqdk.js";import"../chunk-ryz4c13z.js";export{so as ImageViewActivity,pe as isImageView};
@@ -1 +1 @@
1
- import{vo}from"../chunk-12swy4za.js";import"../chunk-5nqhvv28.js";import"../chunk-5c4z345j.js";import"../chunk-dzx4rypz.js";export{vo as CodexMarkdownRenderer};
1
+ import{jn}from"../chunk-syffw61b.js";import"../chunk-jn0q0b7k.js";import"../chunk-30wqrz8v.js";import"../chunk-88xay4pa.js";export{jn as CodexMarkdownRenderer};
@@ -1 +1 @@
1
- import{jn,Qr,Kn,Qn,Xr,hr,Lr,vr,Yr,Dr,_r,Zr,Jr}from"../chunk-bhrnw36x.js";export{Qr as armTimelineUserMessageNavigationAudio,Lr as automaticNavigationMidiNote,Zr as getNavigationAudioContextState,Jr as getNavigationInstrumentReady,Kn as installTimelineUserMessageNavigationAudioUnlock,Dr as itemPianoKeyIndex,hr as navigationMidiNote,_r as navigationPianoKeyIndexes,Yr as pianoKeyFrequency,vr as pianoKeyMidiNote,Xr as playTimelineUserMessageNavigationNote,Qn as playTimelineUserMessageNavigationSequence,jn as preloadTimelineUserMessageNavigationInstrument};
1
+ import{Xn,ai,Yn,Zn,si,vr,Rr,xr,li,Er,Ar,ci,di}from"../chunk-k5c82xk9.js";export{ai as armTimelineUserMessageNavigationAudio,Rr as automaticNavigationMidiNote,ci as getNavigationAudioContextState,di as getNavigationInstrumentReady,Yn as installTimelineUserMessageNavigationAudioUnlock,Er as itemPianoKeyIndex,vr as navigationMidiNote,Ar as navigationPianoKeyIndexes,li as pianoKeyFrequency,xr as pianoKeyMidiNote,si as playTimelineUserMessageNavigationNote,Zn as playTimelineUserMessageNavigationSequence,Xn as preloadTimelineUserMessageNavigationInstrument};
@@ -1 +1 @@
1
- import{wo}from"../chunk-90c0tynf.js";export{wo as NavigationPreview};
1
+ import{Qn}from"../chunk-znx2e9e7.js";export{Qn as NavigationPreview};
@@ -1 +1 @@
1
- import{ho}from"../chunk-jbz530rv.js";import"../chunk-90c0tynf.js";export{ho as TimelineUserMessageNavigationRail};
1
+ import{Kn}from"../chunk-4svcj9c6.js";import"../chunk-znx2e9e7.js";export{Kn as TimelineUserMessageNavigationRail};
@@ -1 +1 @@
1
- import{no,Ne}from"../chunk-2879v3ps.js";export{Ne as PatchView,no as patchStats};
1
+ import{An,Ne}from"../chunk-377s443r.js";export{Ne as PatchView,An as patchStats};
@@ -1 +1 @@
1
- import{z}from"../chunk-fjwg3y8h.js";export{z as CodexPlan};
1
+ import{W}from"../chunk-w8qmh6he.js";export{W as CodexPlan};
@@ -1 +1 @@
1
- import{ti,Zn,de,Et,Jn,eo,to}from"../chunk-8tn17nw7.js";export{ti as CODEX_UNKNOWN_TURN_HEIGHT,de as calculateCodexThreadVirtualRange,eo as calculateCodexTurnCenterDistanceFromBottom,to as calculateCodexTurnTargetDistanceFromBottom,Zn as createCodexThreadVirtualLayout,Jn as preserveCodexThreadDistanceFromBottom,Et as preserveCodexThreadRenderedWindow};
1
+ import{ri,_n,me,Dt,Hn,On,Fn}from"../chunk-0gwe31zs.js";export{ri as CODEX_UNKNOWN_TURN_HEIGHT,me as calculateCodexThreadVirtualRange,On as calculateCodexTurnCenterDistanceFromBottom,Fn as calculateCodexTurnTargetDistanceFromBottom,_n as createCodexThreadVirtualLayout,Hn as preserveCodexThreadDistanceFromBottom,Dt as preserveCodexThreadRenderedWindow};
@@ -1 +1 @@
1
- import{oo}from"../chunk-bq05e911.js";export{oo as selectTurnActivity};
1
+ import{Po}from"../chunk-tjgq4882.js";export{Po as selectTurnActivity};
@@ -1 +1 @@
1
- import{Ot,lo}from"../chunk-83dkw1mh.js";import"../chunk-951wn2bd.js";export{lo as CodexUserMessage,Ot as CopyAction};
1
+ import{$t,po}from"../chunk-sr5rcdza.js";import"../chunk-0n240acr.js";export{po as CodexUserMessage,$t as CopyAction};
@@ -1 +1 @@
1
- import{Wn}from"../chunk-9h86hvc3.js";import"../chunk-8tn17nw7.js";export{Wn as VirtualizedTurnList};
1
+ import{Dn}from"../chunk-7dzq2t68.js";import"../chunk-0gwe31zs.js";export{Dn as VirtualizedTurnList};
@@ -1 +1 @@
1
- import{$t,ii}from"../chunk-grncrd31.js";import"../chunk-6z9r27t2.js";export{ii as filterFiles,$t as filterSlashCommands};
1
+ import{Zt,hi}from"../chunk-knsf6jm1.js";import"../chunk-gzff19t3.js";export{hi as filterFiles,Zt as filterSlashCommands};
@@ -1 +1 @@
1
- import{To}from"../chunk-k583q9wq.js";import"../chunk-grncrd31.js";import"../chunk-6z9r27t2.js";import"../chunk-rmv0t2ee.js";import"../chunk-3wg25354.js";import"../chunk-6kn920c5.js";import"../chunk-5d94195x.js";export{To as CompletionMenu};
1
+ import{Ro}from"../chunk-5hsmhj1g.js";import"../chunk-knsf6jm1.js";import"../chunk-294gms5s.js";import"../chunk-gzff19t3.js";import"../chunk-cpk3y6ad.js";import"../chunk-ksv9pjc2.js";import"../chunk-6kn920c5.js";export{Ro as CompletionMenu};
@@ -1 +1 @@
1
- import{Oo}from"../chunk-rmv0t2ee.js";export{Oo as detectTrigger};
1
+ import{Eo}from"../chunk-294gms5s.js";export{Eo as detectTrigger};
@@ -1 +1 @@
1
- import{Gt}from"../chunk-kathd6f3.js";export{Gt as EffortSlider};
1
+ import{tn}from"../chunk-e11qjnb4.js";export{tn as EffortSlider};