@qredence/fleet 0.7.1 → 0.7.2

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 (109) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/dist/web/client/assets/{action-swap-roll-BfVrBOVd.js → action-swap-roll-Bek47h-E.js} +1 -1
  3. package/dist/web/client/assets/{alert-dialog-FCppNafx.js → alert-dialog-OoasP5iO.js} +1 -1
  4. package/dist/web/client/assets/{artifacts-panel-C69vz-oo.js → artifacts-panel-DVY0-7X0.js} +1 -1
  5. package/dist/web/client/assets/{badge-DOGhnsYk.js → badge-9wr3qUp1.js} +2 -2
  6. package/dist/web/client/assets/{button-BJyg7l5W.js → button-Bqms7ZKX.js} +1 -1
  7. package/dist/web/client/assets/{card-BScRdZNS.js → card-DPCbcrMK.js} +1 -1
  8. package/dist/web/client/assets/{chat-command-palette-wyZjTNa8.js → chat-command-palette-CXS5eTiy.js} +1 -1
  9. package/dist/web/client/assets/{citations-BhyqbxcZ.js → citations-C7USoVdz.js} +1 -1
  10. package/dist/web/client/assets/{command-Bo31U-UD.js → command-s2yLD3tA.js} +1 -1
  11. package/dist/web/client/assets/{create-project-dialog-SDyXTpl-.js → create-project-dialog-C99_Lyjg.js} +1 -1
  12. package/dist/web/client/assets/{dialog-DLIPvl1s.js → dialog-DuCD5hRq.js} +1 -1
  13. package/dist/web/client/assets/{ease-DKi-MOH5.js → ease-2gsl7ABx.js} +1 -1
  14. package/dist/web/client/assets/{fork-picker-dialog-BDleMADF.js → fork-picker-dialog--dV6TE-9.js} +1 -1
  15. package/dist/web/client/assets/globals-BXtzVIWE.css +2 -0
  16. package/dist/web/client/assets/{index-BARp0bjW.js → index-C2EkVtv5.js} +3 -3
  17. package/dist/web/client/assets/{input-Ce8yLnXY.js → input-DECT4vz2.js} +1 -1
  18. package/dist/web/client/assets/{input-group-BZLQiZOA.js → input-group-CZlz1ygA.js} +1 -1
  19. package/dist/web/client/assets/{ipython-tool-CuSGRhXl.js → ipython-tool-Bs6ESZe1.js} +1 -1
  20. package/dist/web/client/assets/{layout-constants-Bl6XCvhY.js → layout-constants-C4hoW3YP.js} +1 -1
  21. package/dist/web/client/assets/{markdown-yn-nhRzB.js → markdown-B2tpfUKu.js} +2 -2
  22. package/dist/web/client/assets/{markdown-code-DfJbKhL9.js → markdown-code-B5YUmtLX.js} +1 -1
  23. package/dist/web/client/assets/{message-queue-CiptKSb6.js → message-queue-BD2sIUTH.js} +1 -1
  24. package/dist/web/client/assets/{model-selector-list-BHQ-Q8b9.js → model-selector-list-zPZRE3JY.js} +1 -1
  25. package/dist/web/client/assets/{notify-BC0a76VJ.js → notify-mVA6z9Ly.js} +1 -1
  26. package/dist/web/client/assets/{openui-renderer-DrfHxs1t.js → openui-renderer-ByP8yQph.js} +1 -1
  27. package/dist/web/client/assets/{prompt-input-IwZOepG7.js → prompt-input-Bnl0HyL6.js} +1 -1
  28. package/dist/web/client/assets/{prompt-suggestions-BRFWFm5y.js → prompt-suggestions-DcgETXtw.js} +1 -1
  29. package/dist/web/client/assets/{provider-label-DNZOLldn.js → provider-label-COVNyoZo.js} +1 -1
  30. package/dist/web/client/assets/{repl-panel-UQN9UFG7.js → repl-panel-BoDNpJOe.js} +1 -1
  31. package/dist/web/client/assets/{resources-panel-kp_UjnpX.js → resources-panel-DD6iWOF3.js} +1 -1
  32. package/dist/web/client/assets/{right-panel-registry-CF7GLJrk.js → right-panel-registry-CIfLdAfS.js} +2 -2
  33. package/dist/web/client/assets/{routes-DCP1DP1g.js → routes-DO93P3Xm.js} +5 -5
  34. package/dist/web/client/assets/{select-COK0Kaq2.js → select-Dp15z1lf.js} +1 -1
  35. package/dist/web/client/assets/{session-reasoning-panel-DrTWp8d4.js → session-reasoning-panel-WMedZp__.js} +1 -1
  36. package/dist/web/client/assets/session-tool-renderer-BFC3-Md4.js +170 -0
  37. package/dist/web/client/assets/{session-tree-panel-deGRKAhX.js → session-tree-panel-CnHOsPzz.js} +1 -1
  38. package/dist/web/client/assets/{settings-dialog-BU1Tw0CQ.js → settings-dialog-BN138nzK.js} +1 -1
  39. package/dist/web/client/assets/{skeleton-D5Y9nBfp.js → skeleton-DNAr5ULI.js} +1 -1
  40. package/dist/web/client/assets/{skeleton-loaders-DOKGa7CW.js → skeleton-loaders-B28mF4tJ.js} +1 -1
  41. package/dist/web/client/assets/{spinner-C3sPnLdu.js → spinner-CSBXk3Lo.js} +1 -1
  42. package/dist/web/client/assets/{subagent-chat-panel-bVnkDkgs.js → subagent-chat-panel-DYKOKRPp.js} +1 -1
  43. package/dist/web/client/assets/subagent-transcript-BCUhqVvi.js +1 -0
  44. package/dist/web/client/assets/{subagent-utils-D7sXbLsS.js → subagent-utils-CM2qX9BG.js} +2 -2
  45. package/dist/web/client/assets/{subagents-panel-i5-12E1U.js → subagents-panel-CTvtU0Sh.js} +1 -1
  46. package/dist/web/client/assets/{surface-context-DWplCCcO.js → surface-context-VvasJf_6.js} +1 -1
  47. package/dist/web/client/assets/{surfaces-BULKVm-B.js → surfaces-m1vs5aMP.js} +1 -1
  48. package/dist/web/client/assets/{switch-DQETDDJT.js → switch-eqXIzePo.js} +1 -1
  49. package/dist/web/client/assets/{toast-BFeqSeaR.js → toast-DRDVljMF.js} +1 -1
  50. package/dist/web/client/assets/{tool-result-D7HtJ_yg.js → tool-result-DWUV8hEz.js} +1 -1
  51. package/dist/web/client/assets/{tool-timeline-B4ci1oJg.js → tool-timeline-4k2iSEky.js} +1 -1
  52. package/dist/web/client/assets/{use-reduced-motion-BgG7f9xw.js → use-reduced-motion-BzGFRmoG.js} +1 -1
  53. package/dist/web/client/assets/utils-CFDGLzf6.js +1 -0
  54. package/dist/web/client/assets/{workspace-panel-Clbmrdza.js → workspace-panel-BNeGABPi.js} +1 -1
  55. package/dist/web/client/assets/{workspace-path-nav-eVT0rYvv.js → workspace-path-nav-umvkE4ut.js} +2 -2
  56. package/dist/web/client/bundle-budget.json +5 -5
  57. package/dist/web/server/{_tanstack-start-manifest_v-CaT-3S-N-VAOGUHEJ.js → _tanstack-start-manifest_v-DTCFS0PG-ARV2V4FW.js} +26 -26
  58. package/dist/web/server/{artifacts-panel-BuAqeJzj-6DYYLKUW.js → artifacts-panel-Ct2R_4wM-DAPQMI57.js} +13 -13
  59. package/dist/web/server/{chat-command-palette-Ca8gXVi2-P6EOQ43G.js → chat-command-palette-ETZzg35Q-TAV74IAW.js} +8 -8
  60. package/dist/web/server/{chunk-5AYK2KDO.js → chunk-777VIBCH.js} +176 -176
  61. package/dist/web/server/{chunk-7VFULIHV.js → chunk-AAPVQJAD.js} +2 -2
  62. package/dist/web/server/{chunk-K4KN3QBT.js → chunk-BNB7T7P6.js} +2 -2
  63. package/dist/web/server/{chunk-E4YWFQX5.js → chunk-FFGFTGLQ.js} +415 -383
  64. package/dist/web/server/{chunk-GCDOYNXR.js → chunk-FL3FOWSC.js} +30 -30
  65. package/dist/web/server/{chunk-ITKXE2Q5.js → chunk-GS5F6X7H.js} +497 -234
  66. package/dist/web/server/{chunk-B7YWDA2F.js → chunk-INRE3X52.js} +2 -2
  67. package/dist/web/server/{chunk-35AFSKDX.js → chunk-JOCVZVZ3.js} +5 -5
  68. package/dist/web/server/{chunk-J4Y2Z3XM.js → chunk-JU7PCOE7.js} +4 -4
  69. package/dist/web/server/{chunk-UTV66W5H.js → chunk-KVW6XTN3.js} +14 -9
  70. package/dist/web/server/{chunk-NB3TVOGB.js → chunk-LECHJX4M.js} +483 -481
  71. package/dist/web/server/{chunk-JFAUSHBI.js → chunk-M6K66QBV.js} +6 -6
  72. package/dist/web/server/{chunk-COWE2EJ6.js → chunk-R7KUUFDW.js} +4 -4
  73. package/dist/web/server/chunk-SHNODG3C.js +18343 -0
  74. package/dist/web/server/{chunk-PXSOI3XF.js → chunk-SQXJ5TUB.js} +2 -2
  75. package/dist/web/server/{chunk-B5Y7XOIJ.js → chunk-TMQ3MT3D.js} +78 -17
  76. package/dist/web/server/{chunk-M7BTY55G.js → chunk-UWZYLMEH.js} +2 -2
  77. package/dist/web/server/{chunk-YIJ7D7G5.js → chunk-VTEYQNJE.js} +7 -7
  78. package/dist/web/server/{chunk-ABYOWAMD.js → chunk-X76RBZ37.js} +2 -2
  79. package/dist/web/server/{chunk-FPPKECLB.js → chunk-XMAAYUOT.js} +14 -14
  80. package/dist/web/server/{create-project-dialog-DCvdysey-IZUGGDAN.js → create-project-dialog-CqBmLTlA-X6HI6AYR.js} +9 -9
  81. package/dist/web/server/{dist-DVCLWOYT.js → dist-3UIQ7SZN.js} +2 -2
  82. package/dist/web/server/{dist-4A22NBTB.js → dist-ZPEDRNZ4.js} +2 -2
  83. package/dist/web/server/{fork-picker-dialog-QH00XmqX-6YLU5REF.js → fork-picker-dialog-PYNd9ozc-EA7BRLRR.js} +6 -6
  84. package/dist/web/server/{markdown-CShfYRVO-OKGCYPQK.js → markdown-CShfYRVO-22N5LNAN.js} +2 -2
  85. package/dist/web/server/{markdown-code-BDV_2b2T-VZGAECQB.js → markdown-code-BDV_2b2T-KUPHX52W.js} +2 -2
  86. package/dist/web/server/{message-queue-BzEFQR8k-2W53EW32.js → message-queue-DmSFAI5Y-XDZHJ2Z6.js} +6 -6
  87. package/dist/web/server/{model-selector-list-BjoXmw92-TEKBPB3E.js → model-selector-list-C-Y3p5UM-HTSWVVHP.js} +8 -8
  88. package/dist/web/server/{openui-renderer-CJ7Q2zZ_-FPXKZPSO.js → openui-renderer-C4B1EJxC-QDYQF5LD.js} +10 -10
  89. package/dist/web/server/{prompt-suggestions-EqAaAx6L-723M64XJ.js → prompt-suggestions-EqAaAx6L-B4KCWNZX.js} +1 -1
  90. package/dist/web/server/{repl-panel-DOyUyuQR-IMYO4FKX.js → repl-panel-DOyUyuQR-LRBDRMHW.js} +3 -3
  91. package/dist/web/server/{resources-panel-yVB4xF_K-OHFHXVU4.js → resources-panel-Bo-TmRON-O47AKGEQ.js} +7 -7
  92. package/dist/web/server/{router-UgU5vJxm-R33FGTXY.js → router-DtS2wXhd-I2SZV7YF.js} +5 -5
  93. package/dist/web/server/{routes-Cbbo-jh9-ZUPH4SJD.js → routes-DuSYlASY-U7C32ONE.js} +5 -5
  94. package/dist/web/server/server.js +3 -3
  95. package/dist/web/server/{session-reasoning-panel-C50VbaQ8-4YLMVVY6.js → session-reasoning-panel-BFcZs1pZ-KNHSU5GX.js} +7 -7
  96. package/dist/web/server/{session-tool-renderer-QcAkYD-V-6RXRKDH6.js → session-tool-renderer-TiFeeJEc-YUZPEEZ4.js} +9 -9
  97. package/dist/web/server/{session-tree-panel-CL49XSTK-4ZPK6AIV.js → session-tree-panel-CjsqVYLY-DGZBGY2E.js} +6 -6
  98. package/dist/web/server/{settings-dialog-DG9HEZeP-TWDRDGMN.js → settings-dialog-Bj5LrAE8-6BQRLUJT.js} +10 -10
  99. package/dist/web/server/{start-DEejK9Uj-FODAOTAO.js → start-cCC--AXu-BBMIT6OU.js} +1 -1
  100. package/dist/web/server/{subagent-chat-panel-Cg2CxshI-WWGFHTIF.js → subagent-chat-panel-DAS4Ne-1-TWIUXSQC.js} +12 -12
  101. package/dist/web/server/{subagents-panel-aC3Eo-MR-RNIPLCZQ.js → subagents-panel-C3CdUcqw-DFTJTPHA.js} +12 -12
  102. package/dist/web/server/{tool-timeline-C4dgQITK-CFWANSDL.js → tool-timeline-C4dgQITK-IWCLQLWG.js} +3 -3
  103. package/dist/web/server/{workspace-panel-DfdFkgHU-6HIOXRBX.js → workspace-panel-DNs0Ye2U-VFB6X5PK.js} +7 -7
  104. package/package.json +4 -4
  105. package/dist/web/client/assets/globals-DZbMyHfg.css +0 -2
  106. package/dist/web/client/assets/session-tool-renderer-Yu4G1165.js +0 -1389
  107. package/dist/web/client/assets/subagent-transcript-D_L-8PQi.js +0 -1
  108. package/dist/web/client/assets/utils-Dpy9ZFOr.js +0 -1
  109. package/dist/web/server/chunk-PHHC52CO.js +0 -38412
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.7.2
4
+
5
+ ### Patch Changes
6
+
7
+ - 6f424fd: Bump the bundled web app's TanStack Start stack together: `@tanstack/react-router` 1.170.32 → 1.170.40 and `@tanstack/react-start` 1.168.49 → 1.168.59 (pulling `@tanstack/start-client-core` 1.170.27 → 1.170.33 and `@tanstack/router-core` 1.171.27 → 1.171.33). Moving the router and Start in lockstep keeps the `server.handlers` route-option augmentation aligned for the API routes. No user-facing behavior change is expected.
8
+
3
9
  ## 0.7.1
4
10
 
5
11
  ### Patch Changes
@@ -1 +1 @@
1
- import{r as e}from"./rolldown-runtime-hePW80VL.js";import{t}from"./react-Cvdyeg_0.js";import{t as n}from"./jsx-runtime-NZYk81nU.js";import{t as r}from"./utils-Dpy9ZFOr.js";import{c as i,d as a,i as o,r as s}from"./ease-DKi-MOH5.js";import{n as c,t as l}from"./use-reduced-motion-BgG7f9xw.js";import{t as u}from"./createLucideIcon-CQY2ECfR.js";var d={name:`circle-x`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`m15 9-6 6`,key:`1uzhvr`}],[`path`,{d:`m9 9 6 6`,key:`z0biqf`}]],aliases:[`x-circle`]};d.node;var f=u(d),p={name:`copy`,size:24,node:[[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]};p.node;var m=u(p),h={name:`file-code-corner`,size:24,node:[[`path`,{d:`M4 12.15V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.706.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2h-3.35`,key:`1wthlu`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`m5 16-3 3 3 3`,key:`331omg`}],[`path`,{d:`m9 22 3-3-3-3`,key:`lsp7cz`}]],aliases:[`file-code-2`]};h.node;var g=u(h),_=n();function v({open:e,openHeight:t=`auto`,className:n,style:i,transition:o,...c}){let u=l()??!1;return(0,_.jsx)(a.div,{...c,"aria-hidden":!e,inert:!e,initial:!1,animate:u?{opacity:+!!e}:{opacity:+!!e,clipPath:e?`inset(0 0 0% 0)`:`inset(0 0 100% 0)`,y:e?0:-4},transition:o??{duration:u?0:e?.22:.14,ease:s},className:r(`overflow-hidden`,n),style:{...i,height:e?t:0,pointerEvents:e?void 0:`none`,transformOrigin:`top`}})}var y=e(t(),1),b={duration:.2,ease:`easeInOut`},x=i,S={duration:.14,ease:s},C=`blur(8px)`,w=`blur(3px)`,T=.025,E={initial:{opacity:0,y:`105%`,filter:w},animate:(e=0)=>({opacity:1,y:`0%`,filter:`blur(0px)`,transition:{...i,delay:e}}),exit:(e=0)=>({opacity:0,y:`-105%`,filter:w,transition:{duration:.16,ease:s,delay:e*.5}})},D={blur:{initial:{opacity:0,scale:.94,filter:C},animate:{opacity:1,scale:1,filter:`blur(0px)`,transition:b},exit:{opacity:0,scale:.94,filter:C,transition:b}},roll:{initial:{opacity:0,y:`90%`,filter:w},animate:{opacity:1,y:`0%`,filter:`blur(0px)`,transition:x},exit:{opacity:0,y:`-90%`,filter:w,transition:S}}};function O({value:e,children:t,animation:n=`blur`,className:i}){let s=l(),u=(0,y.useRef)(null),[d,f]=(0,y.useState)();(0,y.useLayoutEffect)(()=>{let e=u.current?.offsetWidth;e&&f(t=>t===e?t:e)});let p=typeof t==`string`?t:null,m=n===`cascade`&&p!==null&&!s,h=n===`cascade`?`roll`:n;return(0,_.jsxs)(`span`,{className:r(`relative inline-block overflow-hidden whitespace-nowrap align-bottom`,i),style:{width:d,transition:s?void 0:`width 220ms ${o}`},children:[(0,_.jsx)(`span`,{ref:u,"aria-hidden":!0,className:`invisible inline-block whitespace-nowrap`,children:t}),m?(0,_.jsx)(`span`,{className:`sr-only`,children:p}):null,(0,_.jsx)(c,{initial:!1,children:m?(0,_.jsx)(a.span,{"aria-hidden":!0,initial:`initial`,animate:`animate`,exit:`exit`,className:`absolute left-0 top-0 inline-block whitespace-pre`,children:p.split(``).map((e,t)=>(0,_.jsx)(a.span,{custom:t*T,variants:E,className:`inline-block whitespace-pre`,children:e},t))},`cascade-${e}`):(0,_.jsx)(a.span,{variants:D[h],initial:!s&&`initial`,animate:s?{opacity:1,filter:`blur(0px)`,scale:1,y:0}:`animate`,exit:s?void 0:`exit`,className:`absolute left-0 top-0 inline-block`,children:t},`${n}-${e}`)})]})}function k(e){return(0,_.jsx)(O,{...e,animation:`roll`})}export{f as a,m as i,v as n,g as r,k as t};
1
+ import{r as e}from"./rolldown-runtime-hePW80VL.js";import{t}from"./react-Cvdyeg_0.js";import{t as n}from"./jsx-runtime-NZYk81nU.js";import{t as r}from"./utils-CFDGLzf6.js";import{c as i,d as a,i as o,r as s}from"./ease-2gsl7ABx.js";import{n as c,t as l}from"./use-reduced-motion-BzGFRmoG.js";import{t as u}from"./createLucideIcon-CQY2ECfR.js";var d={name:`circle-x`,size:24,node:[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`m15 9-6 6`,key:`1uzhvr`}],[`path`,{d:`m9 9 6 6`,key:`z0biqf`}]],aliases:[`x-circle`]};d.node;var f=u(d),p={name:`copy`,size:24,node:[[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]};p.node;var m=u(p),h={name:`file-code-corner`,size:24,node:[[`path`,{d:`M4 12.15V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.706.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2h-3.35`,key:`1wthlu`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`m5 16-3 3 3 3`,key:`331omg`}],[`path`,{d:`m9 22 3-3-3-3`,key:`lsp7cz`}]],aliases:[`file-code-2`]};h.node;var g=u(h),_=n();function v({open:e,openHeight:t=`auto`,className:n,style:i,transition:o,...c}){let u=l()??!1;return(0,_.jsx)(a.div,{...c,"aria-hidden":!e,inert:!e,initial:!1,animate:u?{opacity:+!!e}:{opacity:+!!e,clipPath:e?`inset(0 0 0% 0)`:`inset(0 0 100% 0)`,y:e?0:-4},transition:o??{duration:u?0:e?.22:.14,ease:s},className:r(`overflow-hidden`,n),style:{...i,height:e?t:0,pointerEvents:e?void 0:`none`,transformOrigin:`top`}})}var y=e(t(),1),b={duration:.2,ease:`easeInOut`},x=i,S={duration:.14,ease:s},C=`blur(8px)`,w=`blur(3px)`,T=.025,E={initial:{opacity:0,y:`105%`,filter:w},animate:(e=0)=>({opacity:1,y:`0%`,filter:`blur(0px)`,transition:{...i,delay:e}}),exit:(e=0)=>({opacity:0,y:`-105%`,filter:w,transition:{duration:.16,ease:s,delay:e*.5}})},D={blur:{initial:{opacity:0,scale:.94,filter:C},animate:{opacity:1,scale:1,filter:`blur(0px)`,transition:b},exit:{opacity:0,scale:.94,filter:C,transition:b}},roll:{initial:{opacity:0,y:`90%`,filter:w},animate:{opacity:1,y:`0%`,filter:`blur(0px)`,transition:x},exit:{opacity:0,y:`-90%`,filter:w,transition:S}}};function O({value:e,children:t,animation:n=`blur`,className:i}){let s=l(),u=(0,y.useRef)(null),[d,f]=(0,y.useState)();(0,y.useLayoutEffect)(()=>{let e=u.current?.offsetWidth;e&&f(t=>t===e?t:e)});let p=typeof t==`string`?t:null,m=n===`cascade`&&p!==null&&!s,h=n===`cascade`?`roll`:n;return(0,_.jsxs)(`span`,{className:r(`relative inline-block overflow-hidden whitespace-nowrap align-bottom`,i),style:{width:d,transition:s?void 0:`width 220ms ${o}`},children:[(0,_.jsx)(`span`,{ref:u,"aria-hidden":!0,className:`invisible inline-block whitespace-nowrap`,children:t}),m?(0,_.jsx)(`span`,{className:`sr-only`,children:p}):null,(0,_.jsx)(c,{initial:!1,children:m?(0,_.jsx)(a.span,{"aria-hidden":!0,initial:`initial`,animate:`animate`,exit:`exit`,className:`absolute left-0 top-0 inline-block whitespace-pre`,children:p.split(``).map((e,t)=>(0,_.jsx)(a.span,{custom:t*T,variants:E,className:`inline-block whitespace-pre`,children:e},t))},`cascade-${e}`):(0,_.jsx)(a.span,{variants:D[h],initial:!s&&`initial`,animate:s?{opacity:1,filter:`blur(0px)`,scale:1,y:0}:`animate`,exit:s?void 0:`exit`,className:`absolute left-0 top-0 inline-block`,children:t},`${n}-${e}`)})]})}function k(e){return(0,_.jsx)(O,{...e,animation:`roll`})}export{f as a,m as i,v as n,g as r,k as t};
@@ -1 +1 @@
1
- import{t as e}from"./jsx-runtime-NZYk81nU.js";import{t}from"./button-BJyg7l5W.js";import{t as n}from"./utils-Dpy9ZFOr.js";import{S as r,a as i,b as a,i as o,l as s,n as c,r as l,s as u,t as d,x as f}from"./surface-context-DWplCCcO.js";function p(e){return i(`alert-dialog`,e)}var m=e(),h=4;function g({...e}){return(0,m.jsx)(p,{"data-slot":`alert-dialog`,...e})}function _({...e}){return(0,m.jsx)(u,{"data-slot":`alert-dialog-portal`,...e})}function v({className:e,...t}){return(0,m.jsx)(r,{"data-slot":`alert-dialog-backdrop`,className:n(`fixed inset-0 isolate z-[60] bg-black/10 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0`,e),...t})}function y({className:e,children:t,...r}){let i=c(),a=Math.min(i+h,8);return(0,m.jsxs)(_,{children:[(0,m.jsx)(v,{}),(0,m.jsx)(s,{"data-slot":`alert-dialog-content`,className:n(`fixed top-1/2 left-1/2 z-[60] grid w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl p-6 text-sm text-popover-foreground outline-none sm:max-w-md data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95`,l(a),e),...r,children:(0,m.jsx)(d,{value:a,children:t})})]})}function b({className:e,...t}){return(0,m.jsx)(o,{"data-slot":`alert-dialog-title`,className:n(`font-heading text-base leading-none font-medium`,e),...t})}function x({className:e,...t}){return(0,m.jsx)(a,{"data-slot":`alert-dialog-description`,className:n(`text-sm text-pretty text-muted-foreground`,e),...t})}function S({className:e,...t}){return(0,m.jsx)(`div`,{"data-slot":`alert-dialog-footer`,className:n(`flex flex-col-reverse gap-2 sm:flex-row sm:justify-end`,e),...t})}function C({...e}){return(0,m.jsx)(f,{"data-slot":`alert-dialog-cancel`,render:(0,m.jsx)(t,{variant:`outline`}),...e})}function w({...e}){return(0,m.jsx)(f,{"data-slot":`alert-dialog-action`,render:(0,m.jsx)(t,{variant:`destructive`}),...e})}export{x as a,y as i,w as n,S as o,C as r,b as s,g as t};
1
+ import{t as e}from"./jsx-runtime-NZYk81nU.js";import{t}from"./button-Bqms7ZKX.js";import{t as n}from"./utils-CFDGLzf6.js";import{S as r,a as i,b as a,i as o,l as s,n as c,r as l,s as u,t as d,x as f}from"./surface-context-VvasJf_6.js";function p(e){return i(`alert-dialog`,e)}var m=e(),h=4;function g({...e}){return(0,m.jsx)(p,{"data-slot":`alert-dialog`,...e})}function _({...e}){return(0,m.jsx)(u,{"data-slot":`alert-dialog-portal`,...e})}function v({className:e,...t}){return(0,m.jsx)(r,{"data-slot":`alert-dialog-backdrop`,className:n(`fixed inset-0 isolate z-[60] bg-black/10 supports-backdrop-filter:backdrop-blur-xs data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0`,e),...t})}function y({className:e,children:t,...r}){let i=c(),a=Math.min(i+h,8);return(0,m.jsxs)(_,{children:[(0,m.jsx)(v,{}),(0,m.jsx)(s,{"data-slot":`alert-dialog-content`,className:n(`fixed top-1/2 left-1/2 z-[60] grid w-full max-w-[calc(100%-2rem)] -translate-x-1/2 -translate-y-1/2 gap-4 rounded-xl p-6 text-sm text-popover-foreground outline-none sm:max-w-md data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95`,l(a),e),...r,children:(0,m.jsx)(d,{value:a,children:t})})]})}function b({className:e,...t}){return(0,m.jsx)(o,{"data-slot":`alert-dialog-title`,className:n(`font-heading text-base leading-none font-medium`,e),...t})}function x({className:e,...t}){return(0,m.jsx)(a,{"data-slot":`alert-dialog-description`,className:n(`text-sm text-pretty text-muted-foreground`,e),...t})}function S({className:e,...t}){return(0,m.jsx)(`div`,{"data-slot":`alert-dialog-footer`,className:n(`flex flex-col-reverse gap-2 sm:flex-row sm:justify-end`,e),...t})}function C({...e}){return(0,m.jsx)(f,{"data-slot":`alert-dialog-cancel`,render:(0,m.jsx)(t,{variant:`outline`}),...e})}function w({...e}){return(0,m.jsx)(f,{"data-slot":`alert-dialog-action`,render:(0,m.jsx)(t,{variant:`destructive`}),...e})}export{x as a,y as i,w as n,S as o,C as r,b as s,g as t};
@@ -1 +1 @@
1
- import{r as e}from"./rolldown-runtime-hePW80VL.js";import{t}from"./react-Cvdyeg_0.js";import{t as n}from"./jsx-runtime-NZYk81nU.js";import{t as r}from"./button-BJyg7l5W.js";import{t as i}from"./createLucideIcon-CQY2ECfR.js";import{i as a,n as o,r as s,t as c}from"./tool-result-D7HtJ_yg.js";import{t as l}from"./chevron-right-BPCB1mOg.js";import{t as u}from"./package-BkC-HSi-.js";import{r as d,t as f}from"./openui-renderer-DrfHxs1t.js";import{n as p}from"./prime-agent-artifacts-C-g1VPiW.js";import{Z as m}from"./badge-DOGhnsYk.js";import{n as h,r as g,t as _}from"./collapsible-DsbKpD_Y.js";var v={name:`layout-template`,size:24,node:[[`rect`,{width:`18`,height:`7`,x:`3`,y:`3`,rx:`1`,key:`f1a2em`}],[`rect`,{width:`9`,height:`7`,x:`3`,y:`14`,rx:`1`,key:`jqznyg`}],[`rect`,{width:`5`,height:`7`,x:`16`,y:`14`,rx:`1`,key:`q5h2i8`}]]};v.node;var y=i(v),b=e(t(),1),x=n(),S=[];function C(e){if(typeof e==`string`)return e;if(e==null)return``;try{return JSON.stringify(e,null,2)}catch{return String(e)}}function w(e){return e===`running`?`running`:e===`error`?`error`:e===`cancelled`?`cancelled`:`success`}function T(e){return e===`running`?`streaming`:e===`error`?`error`:e===`cancelled`?`cancelled`:`complete`}function E(e){let t=typeof e==`object`&&e?e:void 0;if(!t)return e===void 0?[]:[{label:`result`,text:C(e)}];let n=[];for(let e of[`stdout`,`stderr`,`result`,`error`])t[e]!==void 0&&t[e]!==``&&n.push({label:e,text:C(t[e])});let r=t.details??t.output??t.result;if(n.length===0&&r!==e&&n.push(...E(r)),n.length===0&&Array.isArray(t.content)){let e=t.content.flatMap(e=>typeof e==`string`?[e]:typeof e==`object`&&e&&`text`in e&&typeof e.text==`string`?[e.text]:[]).join(``);e&&n.push({label:t.isError===!0?`error`:`stdout`,text:e})}return n.length>0?n:[{label:`result`,text:C(e)}]}function D(e){let t=typeof e.input==`object`&&e.input!==null?e.input:void 0,n=t?.command??t?.code??t?.script;if(!(typeof n!=`string`||!n))return e.kind===`bash`?{code:n,language:`bash`,label:`Bash`}:e.kind===`ipython`?{code:n,language:/^\s*%%bash(?:\s|$)/im.test(n)?`bash`:`python`,label:`IPython`}:e.kind===`diff`?{code:n,language:`text`,label:`Text`}:{code:n,language:`json`,label:`JSON`}}function O(e){if(e.kind!==`openui-html`)return;let t=typeof e.output==`object`&&e.output!==null?e.output:void 0;if(typeof t?.title==`string`&&typeof t.document==`string`)return{title:t.title,document:t.document}}function k({artifact:e,selected:t}){let n=(0,b.useRef)(null);(0,b.useEffect)(()=>{t&&requestAnimationFrame(()=>{n.current?.focus({preventScroll:!0}),n.current?.scrollIntoView({block:`nearest`})})},[t]);let r=O(e);return(0,x.jsxs)(`article`,{ref:n,"data-artifact-id":e.id,tabIndex:-1,className:`min-w-0 rounded-md border border-border/60 bg-background p-2.5 outline-none focus-visible:ring-2 focus-visible:ring-ring`,children:[(0,x.jsxs)(`div`,{className:`mb-2 flex min-w-0 items-center gap-2`,children:[(0,x.jsx)(y,{className:`size-3.5 shrink-0 text-foreground/45`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-xs font-medium`,title:e.title,children:e.title||`OpenUI artifact`}),(0,x.jsx)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:e.status})]}),r?(0,x.jsx)(d,{artifact:r}):(0,x.jsxs)(`div`,{role:`alert`,className:`space-y-2 text-xs text-destructive`,children:[(0,x.jsx)(`p`,{children:`OpenUI artifact data is unavailable.`}),(0,x.jsx)(`pre`,{className:`max-h-48 overflow-auto whitespace-pre-wrap break-words rounded bg-foreground/5 p-2 text-foreground/70`,children:C(e.output)})]})]})}function A({artifact:e,selected:t}){let n=(0,b.useRef)(null),r=t||e.status===`running`,[i,l]=(0,b.useState)(r);(0,b.useEffect)(()=>{t&&(l(!0),requestAnimationFrame(()=>{n.current?.focus({preventScroll:!0}),n.current?.scrollIntoView({block:`nearest`})}))},[t]);let u=D(e),d=E(e.output),f=e.kind===`diff`||e.kind===`refinement`?p(e):void 0;return(0,x.jsxs)(`article`,{ref:n,"data-artifact-id":e.id,tabIndex:-1,className:`rounded-md border border-border/60 bg-background px-2.5 py-2 outline-none focus-visible:ring-2 focus-visible:ring-ring`,children:[f?(0,x.jsxs)(x.Fragment,{children:[(0,x.jsx)(s,{file:f.file,lines:f.lines,status:T(e.status),defaultOpen:r,copyText:f.copyText,maxHeight:240}),d.map(e=>(0,x.jsx)(o,{label:e.label,language:`text`,children:e.text},e.label))]}):null,f?null:(0,x.jsx)(c,{tool:e.kind,title:e.title,status:w(e.status),open:i,onOpenChange:l,defaultOpen:r,kind:e.kind===`bash`||e.kind===`ipython`?`terminal`:`custom`,children:(0,x.jsxs)(`div`,{className:`space-y-3`,children:[u?(0,x.jsx)(a,{code:u.code,language:u.language,languageLabel:u.label,showStatus:!1,showLineNumbers:!1,wrap:!0}):null,d.map(e=>(0,x.jsx)(o,{label:e.label,language:`text`,children:e.text},e.label))]})})]})}function j({block:e,expanded:t,isStreaming:n,onOpenUIAction:i,onToggle:a}){return(0,x.jsxs)(_,{open:t,onOpenChange:a,children:[(0,x.jsxs)(g,{render:(0,x.jsx)(r,{variant:`ghost`,size:`compact`,className:`group w-full justify-start gap-1.5 text-left text-label font-normal text-foreground/65 transition-none hover:bg-foreground/5 hover:text-foreground/80`}),children:[(0,x.jsx)(l,{className:`size-3 shrink-0 text-foreground/35 transition-transform group-data-panel-open:rotate-90`}),(0,x.jsx)(y,{className:`size-3.5 shrink-0 text-foreground/35`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate`,title:e.component,children:e.component}),(0,x.jsxs)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:[`#`,e.ordinal]})]}),(0,x.jsx)(h,{children:(0,x.jsx)(`div`,{className:`mb-1 mt-0.5 flex min-w-0 flex-col overflow-hidden rounded-md border border-border/60 bg-background px-2.5 py-2`,children:(0,x.jsx)(m,{resetKeys:[e.content],children:(0,x.jsx)(f,{content:e.content,isStreaming:n,messageId:e.blockId,onOpenUIAction:i})})})})]})}function M({openUIBlocks:e=[],onOpenUIAction:t,status:n,artifactRuns:r=S,selectedArtifactId:i}){let a=e,[o,s]=(0,b.useState)(null),c=n===`streaming`?a.at(-1)?.blockId:void 0,l=(0,b.useMemo)(()=>r.flatMap(e=>e.artifacts),[r]),d=(0,b.useMemo)(()=>l.filter(e=>e.kind===`openui-html`),[l]),f=(0,b.useMemo)(()=>l.filter(e=>e.kind!==`openui-html`&&e.kind!==`ipython`),[l]);return(0,x.jsxs)(`div`,{className:`flex h-full min-h-0 flex-col gap-2 overflow-hidden`,children:[d.length>0?(0,x.jsxs)(`div`,{className:`min-h-0 flex-1 overflow-y-auto`,children:[(0,x.jsxs)(`div`,{className:`mb-2 flex min-w-0 items-center gap-2 rounded-sm bg-foreground/5 px-2 py-1.5`,children:[(0,x.jsx)(y,{className:`size-3.5 shrink-0 text-foreground/45`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-label font-medium text-foreground/70`,children:`OpenUI artifacts`}),(0,x.jsx)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:d.length})]}),(0,x.jsx)(`div`,{className:`space-y-1`,children:d.map(e=>(0,x.jsx)(k,{artifact:e,selected:e.id===i},e.id))})]}):null,f.length>0?(0,x.jsxs)(`div`,{className:`min-h-0 flex-1 overflow-y-auto`,children:[(0,x.jsxs)(`div`,{className:`mb-2 flex min-w-0 items-center gap-2 rounded-sm bg-foreground/5 px-2 py-1.5`,children:[(0,x.jsx)(u,{className:`size-3.5 shrink-0 text-foreground/45`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-label font-medium text-foreground/70`,children:`Technical artifacts`}),(0,x.jsx)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:f.length})]}),(0,x.jsx)(`div`,{className:`space-y-1`,children:f.map(e=>(0,x.jsx)(A,{artifact:e,selected:e.id===i},e.id))})]}):null,(0,x.jsxs)(`div`,{className:`flex min-h-0 flex-col`,children:[(0,x.jsxs)(`div`,{className:`mb-2 flex min-w-0 items-center gap-2 rounded-sm bg-foreground/5 px-2 py-1.5`,children:[(0,x.jsx)(y,{className:`size-3.5 shrink-0 text-foreground/45`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-label font-medium text-foreground/70`,children:`Generative UI`}),(0,x.jsx)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:a.length>0?`${a.length}`:`none yet`})]}),a.length===0?(0,x.jsx)(`p`,{className:`px-2 pb-1 text-caption leading-4 text-foreground/40`,children:`OpenUI interfaces the agent generates in this session appear here, and can be re-opened without scrolling the conversation.`}):(0,x.jsx)(`div`,{className:`flex min-h-0 flex-col gap-0.5 overflow-y-auto`,children:a.map(e=>(0,x.jsx)(j,{block:e,expanded:e.blockId===o,isStreaming:e.blockId===c,onOpenUIAction:t,onToggle:()=>s(t=>t===e.blockId?null:e.blockId)},e.blockId))})]})]})}export{M as ArtifactsPanelContent};
1
+ import{r as e}from"./rolldown-runtime-hePW80VL.js";import{t}from"./react-Cvdyeg_0.js";import{t as n}from"./jsx-runtime-NZYk81nU.js";import{t as r}from"./button-Bqms7ZKX.js";import{t as i}from"./createLucideIcon-CQY2ECfR.js";import{i as a,n as o,r as s,t as c}from"./tool-result-DWUV8hEz.js";import{t as l}from"./chevron-right-BPCB1mOg.js";import{t as u}from"./package-BkC-HSi-.js";import{r as d,t as f}from"./openui-renderer-ByP8yQph.js";import{n as p}from"./prime-agent-artifacts-C-g1VPiW.js";import{Z as m}from"./badge-9wr3qUp1.js";import{n as h,r as g,t as _}from"./collapsible-DsbKpD_Y.js";var v={name:`layout-template`,size:24,node:[[`rect`,{width:`18`,height:`7`,x:`3`,y:`3`,rx:`1`,key:`f1a2em`}],[`rect`,{width:`9`,height:`7`,x:`3`,y:`14`,rx:`1`,key:`jqznyg`}],[`rect`,{width:`5`,height:`7`,x:`16`,y:`14`,rx:`1`,key:`q5h2i8`}]]};v.node;var y=i(v),b=e(t(),1),x=n(),S=[];function C(e){if(typeof e==`string`)return e;if(e==null)return``;try{return JSON.stringify(e,null,2)}catch{return String(e)}}function w(e){return e===`running`?`running`:e===`error`?`error`:e===`cancelled`?`cancelled`:`success`}function T(e){return e===`running`?`streaming`:e===`error`?`error`:e===`cancelled`?`cancelled`:`complete`}function E(e){let t=typeof e==`object`&&e?e:void 0;if(!t)return e===void 0?[]:[{label:`result`,text:C(e)}];let n=[];for(let e of[`stdout`,`stderr`,`result`,`error`])t[e]!==void 0&&t[e]!==``&&n.push({label:e,text:C(t[e])});let r=t.details??t.output??t.result;if(n.length===0&&r!==e&&n.push(...E(r)),n.length===0&&Array.isArray(t.content)){let e=t.content.flatMap(e=>typeof e==`string`?[e]:typeof e==`object`&&e&&`text`in e&&typeof e.text==`string`?[e.text]:[]).join(``);e&&n.push({label:t.isError===!0?`error`:`stdout`,text:e})}return n.length>0?n:[{label:`result`,text:C(e)}]}function D(e){let t=typeof e.input==`object`&&e.input!==null?e.input:void 0,n=t?.command??t?.code??t?.script;if(!(typeof n!=`string`||!n))return e.kind===`bash`?{code:n,language:`bash`,label:`Bash`}:e.kind===`ipython`?{code:n,language:/^\s*%%bash(?:\s|$)/im.test(n)?`bash`:`python`,label:`IPython`}:e.kind===`diff`?{code:n,language:`text`,label:`Text`}:{code:n,language:`json`,label:`JSON`}}function O(e){if(e.kind!==`openui-html`)return;let t=typeof e.output==`object`&&e.output!==null?e.output:void 0;if(typeof t?.title==`string`&&typeof t.document==`string`)return{title:t.title,document:t.document}}function k({artifact:e,selected:t}){let n=(0,b.useRef)(null);(0,b.useEffect)(()=>{t&&requestAnimationFrame(()=>{n.current?.focus({preventScroll:!0}),n.current?.scrollIntoView({block:`nearest`})})},[t]);let r=O(e);return(0,x.jsxs)(`article`,{ref:n,"data-artifact-id":e.id,tabIndex:-1,className:`min-w-0 rounded-md border border-border/60 bg-background p-2.5 outline-none focus-visible:ring-2 focus-visible:ring-ring`,children:[(0,x.jsxs)(`div`,{className:`mb-2 flex min-w-0 items-center gap-2`,children:[(0,x.jsx)(y,{className:`size-3.5 shrink-0 text-foreground/45`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-xs font-medium`,title:e.title,children:e.title||`OpenUI artifact`}),(0,x.jsx)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:e.status})]}),r?(0,x.jsx)(d,{artifact:r}):(0,x.jsxs)(`div`,{role:`alert`,className:`space-y-2 text-xs text-destructive`,children:[(0,x.jsx)(`p`,{children:`OpenUI artifact data is unavailable.`}),(0,x.jsx)(`pre`,{className:`max-h-48 overflow-auto whitespace-pre-wrap break-words rounded bg-foreground/5 p-2 text-foreground/70`,children:C(e.output)})]})]})}function A({artifact:e,selected:t}){let n=(0,b.useRef)(null),r=t||e.status===`running`,[i,l]=(0,b.useState)(r);(0,b.useEffect)(()=>{t&&(l(!0),requestAnimationFrame(()=>{n.current?.focus({preventScroll:!0}),n.current?.scrollIntoView({block:`nearest`})}))},[t]);let u=D(e),d=E(e.output),f=e.kind===`diff`||e.kind===`refinement`?p(e):void 0;return(0,x.jsxs)(`article`,{ref:n,"data-artifact-id":e.id,tabIndex:-1,className:`rounded-md border border-border/60 bg-background px-2.5 py-2 outline-none focus-visible:ring-2 focus-visible:ring-ring`,children:[f?(0,x.jsxs)(x.Fragment,{children:[(0,x.jsx)(s,{file:f.file,lines:f.lines,status:T(e.status),defaultOpen:r,copyText:f.copyText,maxHeight:240}),d.map(e=>(0,x.jsx)(o,{label:e.label,language:`text`,children:e.text},e.label))]}):null,f?null:(0,x.jsx)(c,{tool:e.kind,title:e.title,status:w(e.status),open:i,onOpenChange:l,defaultOpen:r,kind:e.kind===`bash`||e.kind===`ipython`?`terminal`:`custom`,children:(0,x.jsxs)(`div`,{className:`space-y-3`,children:[u?(0,x.jsx)(a,{code:u.code,language:u.language,languageLabel:u.label,showStatus:!1,showLineNumbers:!1,wrap:!0}):null,d.map(e=>(0,x.jsx)(o,{label:e.label,language:`text`,children:e.text},e.label))]})})]})}function j({block:e,expanded:t,isStreaming:n,onOpenUIAction:i,onToggle:a}){return(0,x.jsxs)(_,{open:t,onOpenChange:a,children:[(0,x.jsxs)(g,{render:(0,x.jsx)(r,{variant:`ghost`,size:`compact`,className:`group w-full justify-start gap-1.5 text-left text-label font-normal text-foreground/65 transition-none hover:bg-foreground/5 hover:text-foreground/80`}),children:[(0,x.jsx)(l,{className:`size-3 shrink-0 text-foreground/35 transition-transform group-data-panel-open:rotate-90`}),(0,x.jsx)(y,{className:`size-3.5 shrink-0 text-foreground/35`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate`,title:e.component,children:e.component}),(0,x.jsxs)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:[`#`,e.ordinal]})]}),(0,x.jsx)(h,{children:(0,x.jsx)(`div`,{className:`mb-1 mt-0.5 flex min-w-0 flex-col overflow-hidden rounded-md border border-border/60 bg-background px-2.5 py-2`,children:(0,x.jsx)(m,{resetKeys:[e.content],children:(0,x.jsx)(f,{content:e.content,isStreaming:n,messageId:e.blockId,onOpenUIAction:i})})})})]})}function M({openUIBlocks:e=[],onOpenUIAction:t,status:n,artifactRuns:r=S,selectedArtifactId:i}){let a=e,[o,s]=(0,b.useState)(null),c=n===`streaming`?a.at(-1)?.blockId:void 0,l=(0,b.useMemo)(()=>r.flatMap(e=>e.artifacts),[r]),d=(0,b.useMemo)(()=>l.filter(e=>e.kind===`openui-html`),[l]),f=(0,b.useMemo)(()=>l.filter(e=>e.kind!==`openui-html`&&e.kind!==`ipython`),[l]);return(0,x.jsxs)(`div`,{className:`flex h-full min-h-0 flex-col gap-2 overflow-hidden`,children:[d.length>0?(0,x.jsxs)(`div`,{className:`min-h-0 flex-1 overflow-y-auto`,children:[(0,x.jsxs)(`div`,{className:`mb-2 flex min-w-0 items-center gap-2 rounded-sm bg-foreground/5 px-2 py-1.5`,children:[(0,x.jsx)(y,{className:`size-3.5 shrink-0 text-foreground/45`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-label font-medium text-foreground/70`,children:`OpenUI artifacts`}),(0,x.jsx)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:d.length})]}),(0,x.jsx)(`div`,{className:`space-y-1`,children:d.map(e=>(0,x.jsx)(k,{artifact:e,selected:e.id===i},e.id))})]}):null,f.length>0?(0,x.jsxs)(`div`,{className:`min-h-0 flex-1 overflow-y-auto`,children:[(0,x.jsxs)(`div`,{className:`mb-2 flex min-w-0 items-center gap-2 rounded-sm bg-foreground/5 px-2 py-1.5`,children:[(0,x.jsx)(u,{className:`size-3.5 shrink-0 text-foreground/45`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-label font-medium text-foreground/70`,children:`Technical artifacts`}),(0,x.jsx)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:f.length})]}),(0,x.jsx)(`div`,{className:`space-y-1`,children:f.map(e=>(0,x.jsx)(A,{artifact:e,selected:e.id===i},e.id))})]}):null,(0,x.jsxs)(`div`,{className:`flex min-h-0 flex-col`,children:[(0,x.jsxs)(`div`,{className:`mb-2 flex min-w-0 items-center gap-2 rounded-sm bg-foreground/5 px-2 py-1.5`,children:[(0,x.jsx)(y,{className:`size-3.5 shrink-0 text-foreground/45`}),(0,x.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-label font-medium text-foreground/70`,children:`Generative UI`}),(0,x.jsx)(`span`,{className:`shrink-0 text-micro text-foreground/40`,children:a.length>0?`${a.length}`:`none yet`})]}),a.length===0?(0,x.jsx)(`p`,{className:`px-2 pb-1 text-caption leading-4 text-foreground/40`,children:`OpenUI interfaces the agent generates in this session appear here, and can be re-opened without scrolling the conversation.`}):(0,x.jsx)(`div`,{className:`flex min-h-0 flex-col gap-0.5 overflow-y-auto`,children:a.map(e=>(0,x.jsx)(j,{block:e,expanded:e.blockId===o,isStreaming:e.blockId===c,onOpenUIAction:t,onToggle:()=>s(t=>t===e.blockId?null:e.blockId)},e.blockId))})]})]})}export{M as ArtifactsPanelContent};