decocms 3.10.3 → 3.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (231) hide show
  1. package/dist/client/assets/{AlertCircle-DQ3zaMns.js → AlertCircle-Ctbek2zl.js} +1 -1
  2. package/dist/client/assets/{ArrowUpRight-UT01ancE.js → ArrowUpRight-CGlPrRsR.js} +1 -1
  3. package/dist/client/assets/{Check-DCJCCJt5.js → Check-D-2DMeXR.js} +1 -1
  4. package/dist/client/assets/{CheckCircle-CN8csJmd.js → CheckCircle-CPLY3iX-.js} +1 -1
  5. package/dist/client/assets/{ChevronDown-vntP1LF0.js → ChevronDown-DUb-OAcF.js} +1 -1
  6. package/dist/client/assets/{ChevronLeft-_4tt3JbP.js → ChevronLeft-IUSMXc7n.js} +1 -1
  7. package/dist/client/assets/{ChevronRight-BD7fiLv7.js → ChevronRight-C6_Bb1P7.js} +1 -1
  8. package/dist/client/assets/{ChevronUp-B9NZzlEX.js → ChevronUp-mT0kmu5O.js} +1 -1
  9. package/dist/client/assets/{Container-DlDQbtuJ.js → Container-V3OuMECL.js} +1 -1
  10. package/dist/client/assets/{DotsVertical-DDPFnnRS.js → DotsVertical-CYMPhMIv.js} +1 -1
  11. package/dist/client/assets/{Eye-ogI2y4CN.js → Eye-DLKlw-42.js} +1 -1
  12. package/dist/client/assets/{FilterLines-DpUfIC-u.js → FilterLines-B2lLGnWS.js} +1 -1
  13. package/dist/client/assets/{Globe01-C2fKyC2-.js → Globe01-BSqLqa8H.js} +1 -1
  14. package/dist/client/assets/{HardDrive-Ik-OtFON.js → HardDrive-BFG0b6vP.js} +1 -1
  15. package/dist/client/assets/{Key01-CmprkySl.js → Key01-DeIJhm73.js} +1 -1
  16. package/dist/client/assets/{LayoutLeft-BO92HMhM.js → LayoutLeft-CAachN7j.js} +1 -1
  17. package/dist/client/assets/{LinkExternal01-9W209kLr.js → LinkExternal01-C7Ulot5I.js} +1 -1
  18. package/dist/client/assets/{Monitor01-B0FKK9nk.js → Monitor01-RdLthi4L.js} +1 -1
  19. package/dist/client/assets/{Palette-OtFJ1ywH.js → Palette-D1rjO3C7.js} +1 -1
  20. package/dist/client/assets/{Play-B9TsjtCB.js → Play-CL1Mgiwf.js} +1 -1
  21. package/dist/client/assets/{Plus-BnGx63GX.js → Plus-DINfOuqC.js} +1 -1
  22. package/dist/client/assets/{RefreshCcw01-Dk9AOo-m.js → RefreshCcw01-DSZXx3HQ.js} +1 -1
  23. package/dist/client/assets/{SearchMd-CxJnyPJ2.js → SearchMd-Dt4Aj6N4.js} +1 -1
  24. package/dist/client/assets/{Settings02-PSRUEgfS.js → Settings02-COHAF-aj.js} +1 -1
  25. package/dist/client/assets/{Shield01-Do71Dyqk.js → Shield01-Ef5O0H91.js} +1 -1
  26. package/dist/client/assets/{Star01-Cu6cUuhf.js → Star01-DWr_psxV.js} +1 -1
  27. package/dist/client/assets/{Stars01-BuMp0jeZ.js → Stars01-CTAt_kJn.js} +1 -1
  28. package/dist/client/assets/{Stars02-Bo6vryYW.js → Stars02-7S-x4jsE.js} +1 -1
  29. package/dist/client/assets/{Sun-Bg1tFzcn.js → Sun-C0yimusT.js} +1 -1
  30. package/dist/client/assets/{SwitchHorizontal01-BjgMZfW7.js → SwitchHorizontal01-CdSYnpvh.js} +1 -1
  31. package/dist/client/assets/{Tool01-DRibBi0T.js → Tool01-Co9IzxOX.js} +1 -1
  32. package/dist/client/assets/{Trash01-DfuJtop_.js → Trash01-m4F91Gbm.js} +1 -1
  33. package/dist/client/assets/{Upload01-DGWS8Icx.js → Upload01-BWuva6Fs.js} +1 -1
  34. package/dist/client/assets/{User01-B1RcIkcM.js → User01-BQ6QP8OL.js} +1 -1
  35. package/dist/client/assets/{Users01-CyxI-ZiC.js → Users01-ByzlIQ3F.js} +1 -1
  36. package/dist/client/assets/{Users03-DhXF_0sH.js → Users03-mgRYViRT.js} +1 -1
  37. package/dist/client/assets/{X-COnjMnsv.js → X-D5DAti-0.js} +1 -1
  38. package/dist/client/assets/{XCircle-BvIhN4E7.js → XCircle-BjeFLJxj.js} +1 -1
  39. package/dist/client/assets/{XClose-CXacF9IM.js → XClose-s3WJPw3-.js} +1 -1
  40. package/dist/client/assets/{Zap-BM6RWRPw.js → Zap-Z3n8EP6c.js} +1 -1
  41. package/dist/client/assets/{ZapSquare-C79zBXJj.js → ZapSquare-By7Cv3Wp.js} +1 -1
  42. package/dist/client/assets/{ZoomOut-B5B07_-g.js → ZoomOut-CIHaUyEl.js} +1 -1
  43. package/dist/client/assets/{access-gate-BHd_MMZj.js → access-gate-Duof6cnb.js} +1 -1
  44. package/dist/client/assets/{accordion-BelQbjLG.js → accordion-B1qqQUiM.js} +1 -1
  45. package/dist/client/assets/add-section-modal-DkoTaNoJ.js +1 -0
  46. package/dist/client/assets/{agent-capabilities-BQdt-MuJ.js → agent-capabilities-Ckkw1MUq.js} +1 -1
  47. package/dist/client/assets/{agent-icon-DFJgaXFK.js → agent-icon-VIqap9Jf.js} +1 -1
  48. package/dist/client/assets/{agent-icons-CkZUPYja.js → agent-icons-D05ipmZ4.js} +1 -1
  49. package/dist/client/assets/{agents-list-DNyHPwF6.js → agents-list-CVx5qLnY.js} +1 -1
  50. package/dist/client/assets/{ai-providers-D3kDr_eM.js → ai-providers-BuKKX642.js} +1 -1
  51. package/dist/client/assets/{alert-kxVKcfjz.js → alert-DlT05Ylq.js} +1 -1
  52. package/dist/client/assets/{alert-dialog-BpOf9MAK.js → alert-dialog-Ci1rMRpl.js} +1 -1
  53. package/dist/client/assets/app-editor-DNNG7_rJ.js +1 -0
  54. package/dist/client/assets/{auth-catchall-0zpjCrAp.js → auth-catchall-BUCBz8XY.js} +1 -1
  55. package/dist/client/assets/{auth-split-layout-qhIpjF8b.js → auth-split-layout-CY6KnHSz.js} +1 -1
  56. package/dist/client/assets/{automation-list-row-CPxwK1jZ.js → automation-list-row-Dg6SIiTL.js} +1 -1
  57. package/dist/client/assets/{automation-runs-W1XLcZy_.js → automation-runs-BmKdgkka.js} +1 -1
  58. package/dist/client/assets/{automations-D1j8zNJi.js → automations-BcxEWxp4.js} +1 -1
  59. package/dist/client/assets/{avatar-CuZPsvd7.js → avatar-B5XGLu28.js} +1 -1
  60. package/dist/client/assets/{badge-BCXaZ3jr.js → badge-BiVWMQaC.js} +1 -1
  61. package/dist/client/assets/{brand-context-BMZ4j5vM.js → brand-context-DSuk-fkh.js} +1 -1
  62. package/dist/client/assets/{buckets-DsWGuu5e.js → buckets-DNim0Oxi.js} +1 -1
  63. package/dist/client/assets/{calendar-DfGnEJr6.js → calendar-D3ybWgKx.js} +1 -1
  64. package/dist/client/assets/{capability-load-error-DjoRzFiH.js → capability-load-error-BoG7ZxlR.js} +1 -1
  65. package/dist/client/assets/{card-DsraaOS_.js → card-Bs_ZETWd.js} +1 -1
  66. package/dist/client/assets/{chat-context-CL-ll6R6.js → chat-context-DXMK9LpM.js} +1 -1
  67. package/dist/client/assets/{checkbox-4DJ-sElS.js → checkbox-CDeLVmoz.js} +1 -1
  68. package/dist/client/assets/{cli-auth-success-BVgFFt5r.js → cli-auth-success-DUzSXn1x.js} +1 -1
  69. package/dist/client/assets/{collection-detail-DS5E30Me.js → collection-detail-B39xBZcf.js} +1 -1
  70. package/dist/client/assets/{collection-display-button-C-mBXp6g.js → collection-display-button-LYjUKJyD.js} +1 -1
  71. package/dist/client/assets/{collection-search-CljcPIbT.js → collection-search-CIGzMvXg.js} +1 -1
  72. package/dist/client/assets/{collection-table-wrapper-DO_P7QvK.js → collection-table-wrapper-CRZ7umIR.js} +1 -1
  73. package/dist/client/assets/{collection-tabs-BgZPPjBK.js → collection-tabs-Cl0Sce7d.js} +1 -1
  74. package/dist/client/assets/{collections-C8UGR0dQ.js → collections-DsvWgjkq.js} +1 -1
  75. package/dist/client/assets/{command-Cwxrfu8T.js → command-nIpjgY_C.js} +1 -1
  76. package/dist/client/assets/{connect-desktop-dialog-CAgFYUmf.js → connect-desktop-dialog-D0cwbi62.js} +1 -1
  77. package/dist/client/assets/{connection-card-Dmrkhocz.js → connection-card-Js2GKnMD.js} +1 -1
  78. package/dist/client/assets/connection-detail-Db8Rqnlx.js +1 -0
  79. package/dist/client/assets/{connection-form-helpers-BL61O5Zc.js → connection-form-helpers-Dkeln3L-.js} +1 -1
  80. package/dist/client/assets/connections-BM65SkyA.js +1 -0
  81. package/dist/client/assets/{constants-BFQrPD6r.js → constants-DeFtLUND.js} +1 -1
  82. package/dist/client/assets/{decopilot-sse-pool-DIAcxt2i.js → decopilot-sse-pool-xYuzxJCG.js} +1 -1
  83. package/dist/client/assets/{dialog-J9xRnRHX.js → dialog-BDoa-Aig.js} +1 -1
  84. package/dist/client/assets/{domain-settings-Cq5_HOtz.js → domain-settings-BHKhY4wr.js} +1 -1
  85. package/dist/client/assets/{drawer-NwIwuvOD.js → drawer-DBoqm7Ga.js} +1 -1
  86. package/dist/client/assets/{dropdown-menu-Do65ajnt.js → dropdown-menu-BuEg85yr.js} +1 -1
  87. package/dist/client/assets/{dynamic-plugin-layout-DYQZtWgt.js → dynamic-plugin-layout-DROpH4YR.js} +1 -1
  88. package/dist/client/assets/{empty-state-Dl_snts0.js → empty-state-BzUpYoP8.js} +1 -1
  89. package/dist/client/assets/{empty-state-BqVzURvi.js → empty-state-Ct_D2Lzo.js} +1 -1
  90. package/dist/client/assets/{extract-connection-data-J0nLi0pB.js → extract-connection-data-C73XSXJg.js} +1 -1
  91. package/dist/client/assets/{features-B1yvHilR.js → features-CG5whIKN.js} +1 -1
  92. package/dist/client/assets/{file-explorer-B3VjqNs-.js → file-explorer-DIE7TBnv.js} +2 -2
  93. package/dist/client/assets/{file-type-icon-DPEVE6_q.js → file-type-icon-CXEAWEt3.js} +1 -1
  94. package/dist/client/assets/{files-DFPQhmGr.js → files-Dk2BQIKH.js} +1 -1
  95. package/dist/client/assets/{form-C4TJnG5K.js → form-CEHwzUIx.js} +1 -1
  96. package/dist/client/assets/{general-B4bDWRqK.js → general-D0Ux1V9u.js} +1 -1
  97. package/dist/client/assets/{generate-id-C8OHZs1-.js → generate-id-DwXNdT-H.js} +1 -1
  98. package/dist/client/assets/{github-repo-picker-BXy4amYZ.js → github-repo-picker-CFHmzbdo.js} +1 -1
  99. package/dist/client/assets/{header-tab-button-CfRERpsl.js → header-tab-button-Be5qNrZz.js} +1 -1
  100. package/dist/client/assets/{hover-card-CzsSQjRq.js → hover-card-CZKyvEKV.js} +1 -1
  101. package/dist/client/assets/{image-field-ixadfB5p.js → image-field-dhimK8za.js} +1 -1
  102. package/dist/client/assets/{index-FjrzqkXH.js → index-3RJ1532Y.js} +1 -1
  103. package/dist/client/assets/{index-C3EQc9K0.js → index-4cje1k2I.js} +1 -1
  104. package/dist/client/assets/{index-Bx5wFMxU.js → index-5FdhmN0u.js} +1 -1
  105. package/dist/client/assets/{index-B9kRhzg7.js → index-8Av7_XG5.js} +3 -3
  106. package/dist/client/assets/{index-X8qPybJt.js → index-B3HtVn_3.js} +1 -1
  107. package/dist/client/assets/{index-bbsI4OK2.js → index-BTP7FdvD.js} +1 -1
  108. package/dist/client/assets/{index-DSVt98oz.js → index-C1oz8tZO.js} +1 -1
  109. package/dist/client/assets/{index-BQhstHsz.js → index-CX7SvFBB.js} +1 -1
  110. package/dist/client/assets/{index-CtCZ2lVU.js → index-CnvExC11.js} +1 -1
  111. package/dist/client/assets/{index-DgQteD84.js → index-D2E_r2Ga.js} +1 -1
  112. package/dist/client/assets/{index-2TKWj64n.js → index-DJjaDA78.js} +1 -1
  113. package/dist/client/assets/{index-jPAWrqoL.js → index-DhlM3QdF.js} +1 -1
  114. package/dist/client/assets/{index-CPhpCeI1.js → index-OL8Ldzfm.js} +23 -23
  115. package/dist/client/assets/{index-CjY_0Wnz.js → index-fhh9LjnW.js} +1 -1
  116. package/dist/client/assets/{index-hwNqvXOX.js → index-qEEk-G84.js} +1 -1
  117. package/dist/client/assets/{index-redirect-Cu5slcp-.js → index-redirect-Cw9_x250.js} +1 -1
  118. package/dist/client/assets/{infiniteQueryObserver-Xb1xysnw.js → infiniteQueryObserver-BPAoXqhZ.js} +1 -1
  119. package/dist/client/assets/{input-DCOoktZX.js → input-CFgdCIf-.js} +1 -1
  120. package/dist/client/assets/{integration-icon-D0rRtQFH.js → integration-icon-ByZrCdpe.js} +1 -1
  121. package/dist/client/assets/{label-dlG4_xKf.js → label-D5ze4fbW.js} +1 -1
  122. package/dist/client/assets/{layout-CqY1dIbQ.js → layout-BuMBlDfo.js} +1 -1
  123. package/dist/client/assets/{login-D5Kc2gHp.js → login-RbDPhsFB.js} +1 -1
  124. package/dist/client/assets/{members-CtWFCCAM.js → members-k2G4ARa8.js} +1 -1
  125. package/dist/client/assets/{monaco-editor-C03OGypq.js → monaco-editor-BAqhsJzm.js} +1 -1
  126. package/dist/client/assets/{monitoring-stats-row-B5_JF7d0.js → monitoring-stats-row-DSa7vGTC.js} +1 -1
  127. package/dist/client/assets/{oauth-callback-Bq0llziz.js → oauth-callback-CbbBKuCW.js} +1 -1
  128. package/dist/client/assets/{oauth-callback-ai-provider-Dqhr4g5S.js → oauth-callback-ai-provider-BRZTOWnt.js} +1 -1
  129. package/dist/client/assets/{onboarding-B8asD6BW.js → onboarding-C6E_j9z8.js} +1 -1
  130. package/dist/client/assets/{org-install-Chh9koDm.js → org-install-Dj9o_O_M.js} +1 -1
  131. package/dist/client/assets/{org-layout-_HQPGRGc.js → org-layout-UJeeaSgp.js} +1 -1
  132. package/dist/client/assets/{org-plugin-layout-CrzvtX56.js → org-plugin-layout-BKs5_fCy.js} +1 -1
  133. package/dist/client/assets/{page-seo-form-DgC67IZh.js → page-seo-form-nusKb5Sb.js} +1 -1
  134. package/dist/client/assets/page-seo-sheet-BpOn67AY.js +1 -0
  135. package/dist/client/assets/{pair-ETmN3fj_.js → pair-B10kI-gZ.js} +1 -1
  136. package/dist/client/assets/{plugin-empty-state-rsU-dNVu.js → plugin-empty-state-j4CULS57.js} +1 -1
  137. package/dist/client/assets/{plugin-header-D7vi3yKZ.js → plugin-header-DULj-Y49.js} +1 -1
  138. package/dist/client/assets/{plugin-layout-CNRc47uO.js → plugin-layout-BKWVYVIi.js} +1 -1
  139. package/dist/client/assets/{popover-Dinj8RAt.js → popover-CusBDsw3.js} +1 -1
  140. package/dist/client/assets/{post-editor-D_b2wd_z.js → post-editor-DEyWVqiE.js} +3 -3
  141. package/dist/client/assets/{primitives-DqpziEOx.js → primitives-K-Cou-34.js} +1 -1
  142. package/dist/client/assets/{profile-p9UvcTh7.js → profile-Cbty-wCE.js} +1 -1
  143. package/dist/client/assets/project-app-view-gakpd8ie.js +1 -0
  144. package/dist/client/assets/record-editor-BJCIZK6H.js +1 -0
  145. package/dist/client/assets/registry-IJiacnxJ.js +2 -0
  146. package/dist/client/assets/{registry-layout-CEjdQi8i.js → registry-layout-1N9kmpom.js} +1 -1
  147. package/dist/client/assets/{require-capability-DjstlBCS.js → require-capability-B58b3LsO.js} +1 -1
  148. package/dist/client/assets/{required-auth-layout-DQ_j0OWf.js → required-auth-layout-CLPqu2hV.js} +1 -1
  149. package/dist/client/assets/{reset-password-PhkeCWUg.js → reset-password-QvfJzQLt.js} +1 -1
  150. package/dist/client/assets/{resizable-CEMGS5N9.js → resizable-DtVYiBv-.js} +1 -1
  151. package/dist/client/assets/{roles-C9PxfSEA.js → roles-BJzMRSbv.js} +1 -1
  152. package/dist/client/assets/{save-status-BCvLZZx5.js → save-status-CcrdCZvz.js} +1 -1
  153. package/dist/client/assets/{schema-form-ETVh-DHz.js → schema-form-CLs9R9OM.js} +1 -1
  154. package/dist/client/assets/{scroll-area-DSB3avJ3.js → scroll-area-GY_MqX9m.js} +1 -1
  155. package/dist/client/assets/{search-input-Dny3m5xa.js → search-input-CaIL3--R.js} +1 -1
  156. package/dist/client/assets/{secrets-CWGMYwDs.js → secrets-CEQKXAz2.js} +1 -1
  157. package/dist/client/assets/{sections-editor-rkPkrwr9.js → sections-editor-3wx6-GfE.js} +1 -1
  158. package/dist/client/assets/{select-CVZQAcm7.js → select-Y4AHPww8.js} +1 -1
  159. package/dist/client/assets/{select-model-BLCOUHJb.js → select-model-DV1-Oh57.js} +1 -1
  160. package/dist/client/assets/{seo-editor-Dv6Vrh4r.js → seo-editor-CwuvVAjS.js} +1 -1
  161. package/dist/client/assets/{settings-layout-D33DplHx.js → settings-layout-lPzeLZ6G.js} +1 -1
  162. package/dist/client/assets/{settings-section-Bx1_7ym7.js → settings-section-rywQD1H8.js} +1 -1
  163. package/dist/client/assets/{sheet-BLkB41eQ.js → sheet-HD1tdtUP.js} +1 -1
  164. package/dist/client/assets/{shell-controls-yn92xA7D.js → shell-controls-CiR1mOgQ.js} +1 -1
  165. package/dist/client/assets/{shell-layout-v69WfJwF.js → shell-layout-D1gXYOI4.js} +1 -1
  166. package/dist/client/assets/{shell-route-loading-DqEXsH0r.js → shell-route-loading-BMvdQN97.js} +1 -1
  167. package/dist/client/assets/{sidebar-BMIDAt6t.js → sidebar-BTAYcbpn.js} +1 -1
  168. package/dist/client/assets/{skeleton-KI9W-P-f.js → skeleton-KPs8aExG.js} +1 -1
  169. package/dist/client/assets/{sortable.esm-tovEx4aa.js → sortable.esm-k9dnaUc0.js} +1 -1
  170. package/dist/client/assets/{spinner-1Hxy4oL5.js → spinner-CWHpDgnL.js} +1 -1
  171. package/dist/client/assets/{sso-D_4gD-Yv.js → sso-DCJOVjP-.js} +1 -1
  172. package/dist/client/assets/{store-DeB9eSSk.js → store-QHf4NvZa.js} +1 -1
  173. package/dist/client/assets/store-registry-O5u8x-zS.js +2 -0
  174. package/dist/client/assets/{switch-BtXimVeh.js → switch-CCjru8jV.js} +1 -1
  175. package/dist/client/assets/{tab-id-DiLpeikj.js → tab-id-Cj2zAp8p.js} +1 -1
  176. package/dist/client/assets/{table-CZLBrik6.js → table-Dpu-CGxg.js} +1 -1
  177. package/dist/client/assets/{tabs-DGoyKbi9.js → tabs-Bsb3WneA.js} +1 -1
  178. package/dist/client/assets/{task-status-nPHS0i2v.js → task-status-Bq8PHYFh.js} +1 -1
  179. package/dist/client/assets/{textarea-CaPEW-IU.js → textarea-Bw4v_xfm.js} +1 -1
  180. package/dist/client/assets/{toggle-group-kjmQGkBo.js → toggle-group-a9DpUbSj.js} +1 -1
  181. package/dist/client/assets/{toolbar-CuMC4awt.js → toolbar-BkMHRO8B.js} +1 -1
  182. package/dist/client/assets/{tools-list-CCmWgH3U.js → tools-list-CmaWZYdl.js} +1 -1
  183. package/dist/client/assets/{tooltip-Cx8u2hvs.js → tooltip-B9p8ywB_.js} +1 -1
  184. package/dist/client/assets/{types-CZnHlJyi.js → types-5S14a687.js} +1 -1
  185. package/dist/client/assets/{use-ai-providers-CmWP-lNT.js → use-ai-providers-iJF3uFpo.js} +1 -1
  186. package/dist/client/assets/{use-automations-Bi6clolz.js → use-automations-BTipFIOi.js} +1 -1
  187. package/dist/client/assets/{use-capability-B6JwqpW7.js → use-capability-CeWdChcL.js} +1 -1
  188. package/dist/client/assets/{use-collections-C1EEoGdl.js → use-collections-CMMaRmVG.js} +1 -1
  189. package/dist/client/assets/{use-connection-DkHV4tpA.js → use-connection-C2Ef-EqP.js} +1 -1
  190. package/dist/client/assets/{use-copy-BKH_ay1V.js → use-copy-DPF-R5Zs.js} +1 -1
  191. package/dist/client/assets/{use-create-virtual-mcp-UfIRObXS.js → use-create-virtual-mcp-7QQxHiI4.js} +1 -1
  192. package/dist/client/assets/{use-debounced-autosave-BTVTsOKV.js → use-debounced-autosave-Da4caii8.js} +1 -1
  193. package/dist/client/assets/{use-delete-connection-D9RSUNNZ.js → use-delete-connection-DaFBaRNm.js} +1 -1
  194. package/dist/client/assets/{use-file-configs-DC8U7Oa7.js → use-file-configs-DWgNRokn.js} +1 -1
  195. package/dist/client/assets/{use-infinite-scroll-DV-4RP03.js → use-infinite-scroll-BaBllFvG.js} +1 -1
  196. package/dist/client/assets/{use-list-state-Mwh_8jAB.js → use-list-state-d80zzrG8.js} +1 -1
  197. package/dist/client/assets/{use-mcp-prompts-CeFy4g83.js → use-mcp-prompts-1dd1yGOH.js} +1 -1
  198. package/dist/client/assets/{use-mcp-tools-BS9dyBS-.js → use-mcp-tools-C8LW1vg1.js} +1 -1
  199. package/dist/client/assets/{use-members-CtpiNo8J.js → use-members-D2U599cF.js} +1 -1
  200. package/dist/client/assets/{use-navigate-to-agent-C81Y1E7k.js → use-navigate-to-agent-C3AzTy7G.js} +1 -1
  201. package/dist/client/assets/{use-org-auth-client-DVt08ImK.js → use-org-auth-client-BQe59WMu.js} +1 -1
  202. package/dist/client/assets/{use-org-sso-B96bQNMI.js → use-org-sso-BB-vyF4c.js} +1 -1
  203. package/dist/client/assets/{use-organization-roles-DRbW9m6o.js → use-organization-roles-DItwUayG.js} +1 -1
  204. package/dist/client/assets/{use-organization-settings-BDlR4IeW.js → use-organization-settings-B6tWOwuA.js} +1 -1
  205. package/dist/client/assets/{use-registry-connections-BCrdHAv1.js → use-registry-connections-DIBKm4oO.js} +1 -1
  206. package/dist/client/assets/{use-secrets-ODuzEevV.js → use-secrets-BhZyR2Dx.js} +1 -1
  207. package/dist/client/assets/{use-status-sounds-DEheRMHk.js → use-status-sounds-Wb6qMNbl.js} +1 -1
  208. package/dist/client/assets/{use-view-mode-BoGNEuZa.js → use-view-mode-BwvjqQMY.js} +1 -1
  209. package/dist/client/assets/{use-virtual-mcp-CtYRrEgz.js → use-virtual-mcp-C_vD2kKw.js} +1 -1
  210. package/dist/client/assets/useInfiniteQuery-CQ_UxVw9.js +1 -0
  211. package/dist/client/assets/{useRouterState-BRj2kxuq.js → useRouterState-BLC1S9ll.js} +1 -1
  212. package/dist/client/assets/useSuspenseInfiniteQuery-XoWOrVYw.js +1 -0
  213. package/dist/client/assets/{user-C5EKJb7v.js → user-BHKPSALf.js} +1 -1
  214. package/dist/client/assets/{view-mode-toggle-DbMrI7Rd.js → view-mode-toggle-BabF7Sx4.js} +1 -1
  215. package/dist/client/assets/{workflow-DyKfGm6u.js → workflow-BQFoQKwV.js} +1 -1
  216. package/dist/client/assets/workflow-detail-CUEl0-_h.js +1 -0
  217. package/dist/client/index.html +1 -1
  218. package/dist/server/cli.js +1 -1
  219. package/package.json +1 -1
  220. package/dist/client/assets/add-section-modal-ClL4Powp.js +0 -1
  221. package/dist/client/assets/app-editor-D9kT95TJ.js +0 -1
  222. package/dist/client/assets/connection-detail-DWDzLFqi.js +0 -1
  223. package/dist/client/assets/connections-uscIXarN.js +0 -1
  224. package/dist/client/assets/page-seo-sheet-Dra624a7.js +0 -1
  225. package/dist/client/assets/project-app-view-uOoeNe2E.js +0 -1
  226. package/dist/client/assets/record-editor-CMLZ85jn.js +0 -1
  227. package/dist/client/assets/registry-aoqZ94q5.js +0 -2
  228. package/dist/client/assets/store-registry-s8ISYHIv.js +0 -2
  229. package/dist/client/assets/useInfiniteQuery-B2j87XPZ.js +0 -1
  230. package/dist/client/assets/useSuspenseInfiniteQuery-BbIHskrR.js +0 -1
  231. package/dist/client/assets/workflow-detail-DBpAT1yB.js +0 -1
@@ -1,4 +1,4 @@
1
- import{e as y,r as v,j as o,B as W,z as we,c as ee,q as C,F as ce,a as G,K as M,n as X,b2 as xe,o as re,a0 as ge,l as ye}from"./index-B9kRhzg7.js";import{D as je,a as ke,b as be,c as ie}from"./dropdown-menu-Do65ajnt.js";import{b as A,T as B,a as K}from"./tooltip-Cx8u2hvs.js";import{i as ve}from"./Check-DCJCCJt5.js";import{a as Se}from"./Eye-ogI2y4CN.js";import{n as Z}from"./Globe01-C2fKyC2-.js";import{e as $e,f as Te,i as Ee,b as Me}from"./ZoomOut-B5B07_-g.js";import{i as Ce}from"./LayoutLeft-BO92HMhM.js";import{n as Ne}from"./LinkExternal01-9W209kLr.js";import{S as Q}from"./skeleton-KI9W-P-f.js";import{l as Fe,F as De}from"./index-BQhstHsz.js";import{F as ze,M as Pe}from"./file-type-icon-DPEVE6_q.js";const wt=1e4,Ue=3;function J(s){return s.trim()?(s.startsWith("/")?s:`/${s}`).replace(/\/+/g,"/"):"/"}function te(s){return s.startsWith("/")?s.slice(1):s}function Y(s){return s.trim()?s.startsWith("/")?s:`/${s}`:"/"}function Oe(s){const e=Y(s);if(e==="/")return"/";const t=e.split("/").filter(Boolean);return t.pop(),t.length===0?"/":`/${t.join("/")}`}function xt(s,e){const t=e.replace(/^\/+|\/+$/g,"");return Y(t?`${s==="/"?"":s}/${t}`:s)}function gt(s,e){return e==="directory"?s:Oe(s)}function yt(s){const e=s.trim();return e?e.includes("/")||e.includes("\\")||e.includes("..")||e.includes("\0")?"Name cannot contain /, \\, or ..":e.startsWith(".")?"Name cannot start with a dot":null:"Name is required"}function _e(s){const e=te(s);return e?e.split("/").filter(Boolean).length:0}function jt(s,e,t,n=!1){return{files:[...new Set([...s,...t.files])],directories:[...new Set([...e,...t.directories??[]])],truncated:n||!!t.truncated}}function kt(s,e){return _e(s)>Ue&&!e.has(s)}function bt(s,e,t=[]){const n=te(s);if(e.includes(n)||t.includes(n))return!0;if(!n)return!1;const r=`${n}/`;return e.some(i=>i.startsWith(r))||t.some(i=>i.startsWith(r))}function vt(s){const e=te(s),t=".deco/blocks/";if(!e.startsWith(t)||!e.endsWith(".json"))return null;const n=e.slice(t.length,-5);try{return decodeURIComponent(n)}catch{return n}}function Re(s){if(!s)return"plaintext";const e=s.toLowerCase();return e.endsWith(".tsx")||e.endsWith(".ts")?"typescript":e.endsWith(".jsx")||e.endsWith(".js")||e.endsWith(".mjs")||e.endsWith(".cjs")?"javascript":e.endsWith(".json")?"json":e.endsWith(".md")||e.endsWith(".mdx")?"markdown":e.endsWith(".css")?"css":e.endsWith(".scss")?"scss":e.endsWith(".html")?"html":e.endsWith(".yaml")||e.endsWith(".yml")?"yaml":e.endsWith(".xml")||e.endsWith(".svg")?"xml":e.endsWith(".py")?"python":e.endsWith(".sql")?"sql":e.endsWith(".sh")?"shell":"plaintext"}function St(s){const e=J(s).split("/").filter(Boolean),t=["/"];let n="";for(const r of e.slice(0,-1))n+=`/${r}`,t.push(n);return t}function $t(s,e=[]){const t={children:[]},n=i=>{const d=J(i).split("/").filter(Boolean);let c=t,l="";for(const f of d){l+=`/${f}`;let u=c.children.find(m=>m.name===f);u?u.kind==="file"&&(u.kind="directory"):(u={name:f,path:l,kind:"directory",children:[]},c.children.push(u)),c=u}};for(const i of s){const d=J(i).split("/").filter(Boolean);let c=t,l="";d.forEach((f,u)=>{l+=`/${f}`;const m=u===d.length-1;let x=c.children.find(k=>k.name===f);x||(x={name:f,path:l,kind:m?"file":"directory",children:[]},c.children.push(x)),c=x})}for(const i of e)n(Y(i));const r=i=>{i.sort((a,d)=>a.kind!==d.kind?a.kind==="directory"?-1:1:a.name.localeCompare(d.name));for(const a of i)a.children.length>0&&r(a.children)};return r(t.children),t.children}function We(s,e,t=0){const n=[];for(const r of s)r.name!==".gitkeep"&&(n.push({node:r,depth:t}),r.kind==="directory"&&r.children.length>0&&e.has(r.path)&&n.push(...We(r.children,e,t+1)));return n}function Tt(s){return s.split(`
1
+ import{e as y,r as v,j as o,B as W,z as we,c as ee,q as C,F as ce,a as G,K as M,n as X,b2 as xe,o as re,a0 as ge,l as ye}from"./index-8Av7_XG5.js";import{D as je,a as ke,b as be,c as ie}from"./dropdown-menu-BuEg85yr.js";import{b as A,T as B,a as K}from"./tooltip-B9p8ywB_.js";import{i as ve}from"./Check-D-2DMeXR.js";import{a as Se}from"./Eye-DLKlw-42.js";import{n as Z}from"./Globe01-BSqLqa8H.js";import{e as $e,f as Te,i as Ee,b as Me}from"./ZoomOut-CIHaUyEl.js";import{i as Ce}from"./LayoutLeft-CAachN7j.js";import{n as Ne}from"./LinkExternal01-C7Ulot5I.js";import{S as Q}from"./skeleton-KPs8aExG.js";import{l as Fe,F as De}from"./index-CX7SvFBB.js";import{F as ze,M as Pe}from"./file-type-icon-CXEAWEt3.js";const wt=1e4,Ue=3;function J(s){return s.trim()?(s.startsWith("/")?s:`/${s}`).replace(/\/+/g,"/"):"/"}function te(s){return s.startsWith("/")?s.slice(1):s}function Y(s){return s.trim()?s.startsWith("/")?s:`/${s}`:"/"}function Oe(s){const e=Y(s);if(e==="/")return"/";const t=e.split("/").filter(Boolean);return t.pop(),t.length===0?"/":`/${t.join("/")}`}function xt(s,e){const t=e.replace(/^\/+|\/+$/g,"");return Y(t?`${s==="/"?"":s}/${t}`:s)}function gt(s,e){return e==="directory"?s:Oe(s)}function yt(s){const e=s.trim();return e?e.includes("/")||e.includes("\\")||e.includes("..")||e.includes("\0")?"Name cannot contain /, \\, or ..":e.startsWith(".")?"Name cannot start with a dot":null:"Name is required"}function _e(s){const e=te(s);return e?e.split("/").filter(Boolean).length:0}function jt(s,e,t,n=!1){return{files:[...new Set([...s,...t.files])],directories:[...new Set([...e,...t.directories??[]])],truncated:n||!!t.truncated}}function kt(s,e){return _e(s)>Ue&&!e.has(s)}function bt(s,e,t=[]){const n=te(s);if(e.includes(n)||t.includes(n))return!0;if(!n)return!1;const r=`${n}/`;return e.some(i=>i.startsWith(r))||t.some(i=>i.startsWith(r))}function vt(s){const e=te(s),t=".deco/blocks/";if(!e.startsWith(t)||!e.endsWith(".json"))return null;const n=e.slice(t.length,-5);try{return decodeURIComponent(n)}catch{return n}}function Re(s){if(!s)return"plaintext";const e=s.toLowerCase();return e.endsWith(".tsx")||e.endsWith(".ts")?"typescript":e.endsWith(".jsx")||e.endsWith(".js")||e.endsWith(".mjs")||e.endsWith(".cjs")?"javascript":e.endsWith(".json")?"json":e.endsWith(".md")||e.endsWith(".mdx")?"markdown":e.endsWith(".css")?"css":e.endsWith(".scss")?"scss":e.endsWith(".html")?"html":e.endsWith(".yaml")||e.endsWith(".yml")?"yaml":e.endsWith(".xml")||e.endsWith(".svg")?"xml":e.endsWith(".py")?"python":e.endsWith(".sql")?"sql":e.endsWith(".sh")?"shell":"plaintext"}function St(s){const e=J(s).split("/").filter(Boolean),t=["/"];let n="";for(const r of e.slice(0,-1))n+=`/${r}`,t.push(n);return t}function $t(s,e=[]){const t={children:[]},n=i=>{const d=J(i).split("/").filter(Boolean);let c=t,l="";for(const f of d){l+=`/${f}`;let u=c.children.find(m=>m.name===f);u?u.kind==="file"&&(u.kind="directory"):(u={name:f,path:l,kind:"directory",children:[]},c.children.push(u)),c=u}};for(const i of s){const d=J(i).split("/").filter(Boolean);let c=t,l="";d.forEach((f,u)=>{l+=`/${f}`;const m=u===d.length-1;let x=c.children.find(k=>k.name===f);x||(x={name:f,path:l,kind:m?"file":"directory",children:[]},c.children.push(x)),c=x})}for(const i of e)n(Y(i));const r=i=>{i.sort((a,d)=>a.kind!==d.kind?a.kind==="directory"?-1:1:a.name.localeCompare(d.name));for(const a of i)a.children.length>0&&r(a.children)};return r(t.children),t.children}function We(s,e,t=0){const n=[];for(const r of s)r.name!==".gitkeep"&&(n.push({node:r,depth:t}),r.kind==="directory"&&r.children.length>0&&e.has(r.path)&&n.push(...We(r.children,e,t+1)));return n}function Tt(s){return s.split(`
2
2
  `).map(e=>{const t=e.match(/^\d+\t(.*)/);return t?t[1]:e}).join(`
3
3
  `)}function Le(s){const e=y.c(53),{readUrl:t,editor:n,downloadName:r,trailing:i}=s,[a,d]=v.useState(!1);let c;e[0]!==t?(c=new URL(t,window.location.origin).toString(),e[0]=t,e[1]=c):c=e[1];const l=c;let f;e[2]!==l?(f=()=>{navigator.clipboard.writeText(l),d(!0),window.setTimeout(()=>d(!1),1500)},e[2]=l,e[3]=f):f=e[3];const u=f;let m;e[4]!==n?(m=n.deckDetected&&o.jsxs(A,{children:[o.jsx(B,{asChild:!0,children:o.jsx(W,{variant:n.railOpen?"secondary":"ghost",size:"icon","aria-label":n.railOpen?"Hide slide list":"Show slide list",onClick:()=>n.setRailOpen(!n.railOpen),children:o.jsx(Ce,{size:14})})}),o.jsx(K,{side:"bottom",children:n.railOpen?"Hide slide list":"Show slide list"})]}),e[4]=n,e[5]=m):m=e[5];let x;e[6]!==l?(x=()=>window.open(l,"_blank","noopener"),e[6]=l,e[7]=x):x=e[7];let k;e[8]!==l?(k=o.jsx("span",{className:"truncate",children:l}),e[8]=l,e[9]=k):k=e[9];let b;e[10]!==l||e[11]!==x||e[12]!==k?(b=o.jsx("button",{type:"button",onClick:x,className:"flex min-w-0 flex-1 items-center rounded-md px-2 py-1 text-left text-xs text-muted-foreground transition-colors hover:bg-muted hover:text-foreground",title:l,children:k}),e[10]=l,e[11]=x,e[12]=k,e[13]=b):b=e[13];let g;e[14]!==n.agentUpdated||e[15]!==n.reload?(g=n.agentUpdated&&o.jsxs(A,{children:[o.jsx(B,{asChild:!0,children:o.jsxs(W,{variant:"outline",size:"sm",className:"h-7 gap-1 text-xs",onClick:n.reload,children:[o.jsx(we,{size:12}),"Agent updated — reload"]})}),o.jsx(K,{side:"bottom",children:"The agent rewrote this deck while you were editing. Reloading discards unsaved differences."})]}),e[14]=n.agentUpdated,e[15]=n.reload,e[16]=g):g=e[16];let j;e[17]!==n.saving?(j=n.saving&&o.jsx("span",{className:"px-1 text-xs text-muted-foreground",children:"Saving…"}),e[17]=n.saving,e[18]=j):j=e[18];let S;e[19]!==n?(S=n.deckDetected&&n.writable&&o.jsxs(A,{children:[o.jsx(B,{asChild:!0,children:o.jsx(W,{variant:n.editMode?"secondary":"ghost",size:"icon","aria-label":n.editMode?"Done editing":"Edit inline",className:ee(n.editMode&&"text-primary"),onClick:()=>n.setEditMode(!n.editMode),children:o.jsx($e,{size:14})})}),o.jsx(K,{side:"bottom",children:n.editMode?"Done editing":"Edit inline (text, reorder, delete)"})]}),e[19]=n,e[20]=S):S=e[20];let E;e[21]!==l||e[22]!==r||e[23]!==n.deckDetected?(E=n.deckDetected?o.jsxs(je,{children:[o.jsx(ke,{asChild:!0,children:o.jsx(W,{variant:"ghost",size:"icon","aria-label":"Download",children:o.jsx(Z,{size:14})})}),o.jsxs(be,{align:"end",children:[o.jsxs(ie,{onClick:()=>window.open(`${l}#print`,"_blank","noopener"),children:[o.jsx(Te,{size:14}),"Export as PDF"]}),o.jsx(ie,{asChild:!0,children:o.jsxs("a",{href:l,download:r,children:[o.jsx(Ee,{size:14}),"Download HTML"]})})]})]}):o.jsxs(A,{children:[o.jsx(B,{asChild:!0,children:o.jsx(W,{variant:"ghost",size:"icon","aria-label":"Download",asChild:!0,children:o.jsx("a",{href:l,download:r,children:o.jsx(Z,{size:14})})})}),o.jsx(K,{side:"bottom",children:"Download"})]}),e[21]=l,e[22]=r,e[23]=n.deckDetected,e[24]=E):E=e[24];let D;e[25]!==a?(D=a?o.jsx(ve,{size:14}):o.jsx(Se,{size:14}),e[25]=a,e[26]=D):D=e[26];let z;e[27]!==u||e[28]!==D?(z=o.jsx(B,{asChild:!0,children:o.jsx(W,{variant:"ghost",size:"icon","aria-label":"Copy URL",onClick:u,children:D})}),e[27]=u,e[28]=D,e[29]=z):z=e[29];const V=a?"Copied":"Copy URL";let p;e[30]!==V?(p=o.jsx(K,{side:"bottom",children:V}),e[30]=V,e[31]=p):p=e[31];let P;e[32]!==z||e[33]!==p?(P=o.jsxs(A,{children:[z,p]}),e[32]=z,e[33]=p,e[34]=P):P=e[34];let N;e[35]!==l?(N=()=>window.open(l,"_blank","noopener"),e[35]=l,e[36]=N):N=e[36];let $;e[37]===Symbol.for("react.memo_cache_sentinel")?($=o.jsx(Ne,{size:14}),e[37]=$):$=e[37];let T;e[38]!==N?(T=o.jsx(B,{asChild:!0,children:o.jsx(W,{variant:"ghost",size:"icon","aria-label":"Open in new tab",onClick:N,children:$})}),e[38]=N,e[39]=T):T=e[39];let I;e[40]===Symbol.for("react.memo_cache_sentinel")?(I=o.jsx(K,{side:"bottom",children:"Open in new tab"}),e[40]=I):I=e[40];let U;e[41]!==T?(U=o.jsxs(A,{children:[T,I]}),e[41]=T,e[42]=U):U=e[42];let O;return e[43]!==E||e[44]!==P||e[45]!==U||e[46]!==m||e[47]!==b||e[48]!==g||e[49]!==j||e[50]!==S||e[51]!==i?(O=o.jsxs("div",{className:"flex h-9 shrink-0 items-center gap-1 border-b border-border/60 px-2",children:[m,b,g,j,S,E,P,U,i]}),e[43]=E,e[44]=P,e[45]=U,e[46]=m,e[47]=b,e[48]=g,e[49]=j,e[50]=S,e[51]=i,e[52]=O):O=e[52],O}function qe(s){return s.contentHash??`${s.size}-${s.updatedAt}`}function F(s,e,t,n){const r=new URLSearchParams(n).toString();return`/api/${encodeURIComponent(s)}/fs/${encodeURIComponent(e)}/${t}${r?`?${r}`:""}`}async function q(s,e){const t=await fetch(s,e);if(!t.ok){let n="";try{n=(await t.json()).error??""}catch{}throw new Error(n||`HTTP ${t.status}`)}return t}function Et(s,e){const t=y.c(11),{org:n}=C();let r;t[0]!==n.id||t[1]!==e||t[2]!==s?(r=M.orgFsList(n.id,s,e),t[0]=n.id,t[1]=e,t[2]=s,t[3]=r):r=t[3];let i;t[4]!==n.slug||t[5]!==e||t[6]!==s?(i=async()=>(await(await q(F(n.slug,s,"list",{path:e}))).json()).entries.toSorted(Ie),t[4]=n.slug,t[5]=e,t[6]=s,t[7]=i):i=t[7];let a;return t[8]!==r||t[9]!==i?(a={queryKey:r,placeholderData:xe,queryFn:i},t[8]=r,t[9]=i,t[10]=a):a=t[10],X(a)}function Ie(s,e){return s.kind!==e.kind?s.kind==="dir"?-1:1:s.path.localeCompare(e.path)}function Mt(s,e,t){const n=y.c(15),{org:r}=C();let i;n[0]!==r.id||n[1]!==e||n[2]!==s?(i=M.orgFsStat(r.id,s??"",e),n[0]=r.id,n[1]=e,n[2]=s,n[3]=i):i=n[3];const a=s!==null;let d;n[4]!==t?(d=t?.refetchIntervalWhenAbsent?f=>f.state.data?!1:t.refetchIntervalWhenAbsent??!1:void 0,n[4]=t,n[5]=d):d=n[5];let c;n[6]!==r.slug||n[7]!==e||n[8]!==s?(c=async()=>{const f=await fetch(F(r.slug,s??"","stat",{path:e}));if(f.status===404)return null;if(!f.ok)throw new Error(`HTTP ${f.status}`);return(await f.json()).entry},n[6]=r.slug,n[7]=e,n[8]=s,n[9]=c):c=n[9];let l;return n[10]!==i||n[11]!==a||n[12]!==d||n[13]!==c?(l={queryKey:i,enabled:a,refetchInterval:d,queryFn:c},n[10]=i,n[11]=a,n[12]=d,n[13]=c,n[14]=l):l=n[14],X(l)}function Ct(s){const e=y.c(9),{org:t}=C();let n;e[0]!==t.id||e[1]!==s?(n=M.orgFsUsage(t.id,s),e[0]=t.id,e[1]=s,e[2]=n):n=e[2];let r;e[3]!==t.slug||e[4]!==s?(r=async()=>await(await q(F(t.slug,s,"usage"))).json(),e[3]=t.slug,e[4]=s,e[5]=r):r=e[5];let i;return e[6]!==n||e[7]!==r?(i={queryKey:n,queryFn:r},e[6]=n,e[7]=r,e[8]=i):i=e[8],X(i)}function Nt(s){const e=y.c(8),t=60,{org:n}=C();let r;e[0]!==n.id?(r=M.orgFsRecent(n.id),e[0]=n.id,e[1]=r):r=e[1];let i;e[2]!==t||e[3]!==n.slug?(i=async()=>(await(await q(`/api/${encodeURIComponent(n.slug)}/fs/recent?limit=${t}`)).json()).entries,e[2]=t,e[3]=n.slug,e[4]=i):i=e[4];let a;return e[5]!==r||e[6]!==i?(a={queryKey:r,queryFn:i},e[5]=r,e[6]=i,e[7]=a):a=e[7],X(a)}function Ft(){const s=y.c(7),{org:e}=C();let t;s[0]!==e.id?(t=M.orgFsPublicSets(e.id),s[0]=e.id,s[1]=t):t=s[1];let n;s[2]!==e.slug?(n=async()=>(await(await q(`/api/${encodeURIComponent(e.slug)}/fs/public-sets`)).json()).sets,s[2]=e.slug,s[3]=n):n=s[3];let r;return s[4]!==t||s[5]!==n?(r={queryKey:t,staleTime:3e5,queryFn:n},s[4]=t,s[5]=n,s[6]=r):r=s[6],X(r)}function Dt(s){const e=y.c(3),{org:t}=C();let n;return e[0]!==t.slug||e[1]!==s?(n=r=>F(t.slug,s,"read",{path:r}),e[0]=t.slug,e[1]=s,e[2]=n):n=e[2],n}function zt(){const s=y.c(2),{org:e}=C();let t;return s[0]!==e.slug?(t=(n,r)=>F(e.slug,n,"read",{path:r}),s[0]=e.slug,s[1]=t):t=s[1],t}function Ae(s){const e=y.c(3),{org:t}=C();let n;return e[0]!==t||e[1]!==s?(n={mutationFn:async r=>(await(await q(F(t.slug,s,"file",{path:r.path}),{method:"PUT",headers:{"content-type":r.contentType??"text/html; charset=utf-8"},body:r.body})).json()).entry},e[0]=t,e[1]=s,e[2]=n):n=e[2],G(n)}function Pt(s){const e=y.c(26),{org:t}=C(),n=ce();let r;e[0]!==t||e[1]!==n||e[2]!==s?(r=()=>{n.invalidateQueries({queryKey:M.orgFsVolume(t.id,s)}),n.invalidateQueries({queryKey:M.orgFsRecent(t.id)})},e[0]=t,e[1]=n,e[2]=s,e[3]=r):r=e[3];const i=r;let a;e[4]!==t||e[5]!==s?(a=async g=>{for(const j of g.files){const S=g.dir?`${g.dir}/${j.name}`:j.name;await q(F(t.slug,s,"file",{path:S}),{method:"PUT",headers:{"content-type":j.type||"application/octet-stream"},body:j})}},e[4]=t,e[5]=s,e[6]=a):a=e[6];let d;e[7]!==i||e[8]!==a?(d={mutationFn:a,onSettled:i},e[7]=i,e[8]=a,e[9]=d):d=e[9];const c=G(d);let l;e[10]!==t||e[11]!==s?(l=async g=>{await q(F(t.slug,s,"dir",{path:g}),{method:"POST"})},e[10]=t,e[11]=s,e[12]=l):l=e[12];let f;e[13]!==i||e[14]!==l?(f={mutationFn:l,onSuccess:i},e[13]=i,e[14]=l,e[15]=f):f=e[15];const u=G(f);let m;e[16]!==t||e[17]!==s?(m=async g=>{await q(F(t.slug,s,"file",{path:g}),{method:"DELETE"})},e[16]=t,e[17]=s,e[18]=m):m=e[18];let x;e[19]!==i||e[20]!==m?(x={mutationFn:m,onSuccess:i},e[19]=i,e[20]=m,e[21]=x):x=e[21];const k=G(x);let b;return e[22]!==u||e[23]!==k||e[24]!==c?(b={upload:c,mkdir:u,remove:k},e[22]=u,e[23]=k,e[24]=c,e[25]=b):b=e[25],b}const H=1;function Be(s){if(typeof s!="object"||s===null||s.v!==H||s.source!=="deck-viewer")return null;const e=s;return e.type==="ready"||e.type==="state"||e.type==="op"&&typeof e.opId=="string"&&e.op?e:null}class L extends Error{constructor(e,t){super(e),this.code=t,this.name="DeckOpError"}code}function de(s){return[...s.children].filter(e=>!/^(TEMPLATE|SCRIPT|STYLE)$/.test(e.tagName))}function Ke(s){const t=new DOMParser().parseFromString(s,"text/html").querySelector("deck-viewer");return t?de(t).length:null}function He(s,e){const t=new DOMParser().parseFromString(s,"text/html"),n=t.querySelector("deck-viewer");if(!n)throw new L("no <deck-viewer> element in source","no-viewer");const r=de(n),i=e.kind==="move"?e.from:e.at,a=r[i];if(!a)throw new L(`slide index ${i} out of range (${r.length})`,"stale-index");switch(e.kind){case"remove":{if(r.length<=1)throw new L("cannot remove the last slide","bad-op");a.remove();break}case"duplicate":{const c=a.cloneNode(!0);c.removeAttribute("id");for(const l of c.querySelectorAll("[id]"))l.removeAttribute("id");a.after(c);break}case"move":{if(e.to<0||e.to>=r.length)throw new L(`move target ${e.to} out of range`,"stale-index");if(e.to!==e.from){const c=e.to<e.from?r[e.to]:r[e.to].nextSibling;n.insertBefore(a,c)}break}case"set-attr":{if(!/^[a-zA-Z][\w-]*$/.test(e.name))throw new L(`invalid attribute name: ${e.name}`,"bad-op");a.setAttribute(e.name,e.value);break}case"remove-attr":{a.removeAttribute(e.name);break}case"replace":{const l=new DOMParser().parseFromString(e.html,"text/html").body.firstElementChild;if(!l)throw new L("replace html has no root element","bad-op");a.replaceWith(t.importNode(l,!0));break}default:throw new L(`unknown op kind: ${e.kind}`,"bad-op")}return`${s.trimStart().toLowerCase().startsWith("<!doctype")?`<!DOCTYPE html>
4
4
  `:""}${t.documentElement.outerHTML}
@@ -1 +1 @@
1
- import{r as c,j as d,db as k,a6 as F,a7 as f,dd as T,af as $,bf as O,bq as I,de as U,df as W,dh as z,dc as B,bc as G,da as K,e as E,c as q}from"./index-B9kRhzg7.js";var w,b="HoverCard",[N]=$(b,[T]),R=T(),[V,S]=N(b),_=o=>{const{__scopeHoverCard:e,children:t,open:r,defaultOpen:a,onOpenChange:s,openDelay:l=700,closeDelay:u=300}=o,i=R(e),p=c.useRef(0),v=c.useRef(0),C=c.useRef(!1),h=c.useRef(!1),[m,n]=G({prop:r,defaultProp:a??!1,onChange:s,caller:b}),x=c.useCallback(()=>{clearTimeout(v.current),p.current=window.setTimeout(()=>n(!0),l)},[l,n]),L=c.useCallback(()=>{clearTimeout(p.current),!C.current&&!h.current&&(v.current=window.setTimeout(()=>n(!1),u))},[u,n]),M=c.useCallback(()=>n(!1),[n]);return c.useEffect(()=>()=>{clearTimeout(p.current),clearTimeout(v.current)},[]),d.jsx(V,{scope:e,open:m,onOpenChange:n,onOpen:x,onClose:L,onDismiss:M,hasSelectionRef:C,isPointerDownOnContentRef:h,children:d.jsx(K,{...i,children:t})})};_.displayName=b;var y="HoverCardTrigger",D=c.forwardRef((o,e)=>{const{__scopeHoverCard:t,...r}=o,a=S(y,t),s=R(t);return d.jsx(k,{asChild:!0,...s,children:d.jsx(F.a,{"data-state":a.open?"open":"closed",...r,ref:e,onPointerEnter:f(o.onPointerEnter,P(a.onOpen)),onPointerLeave:f(o.onPointerLeave,P(a.onClose)),onFocus:f(o.onFocus,a.onOpen),onBlur:f(o.onBlur,a.onClose),onTouchStart:f(o.onTouchStart,l=>l.preventDefault())})})});D.displayName=y;var H="HoverCardPortal",[J,Q]=N(H,{forceMount:void 0}),j=o=>{const{__scopeHoverCard:e,forceMount:t,children:r,container:a}=o,s=S(H,e);return d.jsx(J,{scope:e,forceMount:t,children:d.jsx(O,{present:t||s.open,children:d.jsx(B,{asChild:!0,container:a,children:r})})})};j.displayName=H;var g="HoverCardContent",A=c.forwardRef((o,e)=>{const t=Q(g,o.__scopeHoverCard),{forceMount:r=t.forceMount,...a}=o,s=S(g,o.__scopeHoverCard);return d.jsx(O,{present:r||s.open,children:d.jsx(X,{"data-state":s.open?"open":"closed",...a,onPointerEnter:f(o.onPointerEnter,P(s.onOpen)),onPointerLeave:f(o.onPointerLeave,P(s.onClose)),ref:e})})});A.displayName=g;var X=c.forwardRef((o,e)=>{const{__scopeHoverCard:t,onEscapeKeyDown:r,onPointerDownOutside:a,onFocusOutside:s,onInteractOutside:l,...u}=o,i=S(g,t),p=R(t),v=c.useRef(null),C=I(e,v),[h,m]=c.useState(!1);return c.useEffect(()=>{if(h){const n=document.body;return w=n.style.userSelect||n.style.webkitUserSelect,n.style.userSelect="none",n.style.webkitUserSelect="none",()=>{n.style.userSelect=w,n.style.webkitUserSelect=w}}},[h]),c.useEffect(()=>{if(v.current){const n=()=>{m(!1),i.isPointerDownOnContentRef.current=!1,setTimeout(()=>{document.getSelection()?.toString()!==""&&(i.hasSelectionRef.current=!0)})};return document.addEventListener("pointerup",n),()=>{document.removeEventListener("pointerup",n),i.hasSelectionRef.current=!1,i.isPointerDownOnContentRef.current=!1}}},[i.isPointerDownOnContentRef,i.hasSelectionRef]),c.useEffect(()=>{v.current&&ee(v.current).forEach(x=>x.setAttribute("tabindex","-1"))}),d.jsx(U,{asChild:!0,disableOutsidePointerEvents:!1,onInteractOutside:l,onEscapeKeyDown:r,onPointerDownOutside:a,onFocusOutside:f(s,n=>{n.preventDefault()}),onDismiss:i.onDismiss,children:d.jsx(W,{...p,...u,onPointerDown:f(u.onPointerDown,n=>{n.currentTarget.contains(n.target)&&m(!0),i.hasSelectionRef.current=!1,i.isPointerDownOnContentRef.current=!0}),ref:C,style:{...u.style,userSelect:h?"text":void 0,WebkitUserSelect:h?"text":void 0,"--radix-hover-card-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-hover-card-content-available-width":"var(--radix-popper-available-width)","--radix-hover-card-content-available-height":"var(--radix-popper-available-height)","--radix-hover-card-trigger-width":"var(--radix-popper-anchor-width)","--radix-hover-card-trigger-height":"var(--radix-popper-anchor-height)"}})})}),Y="HoverCardArrow",Z=c.forwardRef((o,e)=>{const{__scopeHoverCard:t,...r}=o,a=R(t);return d.jsx(z,{...a,...r,ref:e})});Z.displayName=Y;function P(o){return e=>e.pointerType==="touch"?void 0:o()}function ee(o){const e=[],t=document.createTreeWalker(o,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});for(;t.nextNode();)e.push(t.currentNode);return e}var te=_,oe=D,re=j,ne=A;function se(o){const e=E.c(4);let t;e[0]!==o?({...t}=o,e[0]=o,e[1]=t):t=e[1];let r;return e[2]!==t?(r=d.jsx(te,{"data-slot":"hover-card",...t}),e[2]=t,e[3]=r):r=e[3],r}function ie(o){const e=E.c(4);let t;e[0]!==o?({...t}=o,e[0]=o,e[1]=t):t=e[1];let r;return e[2]!==t?(r=d.jsx(oe,{"data-slot":"hover-card-trigger",...t}),e[2]=t,e[3]=r):r=e[3],r}function ce(o){const e=E.c(12);let t,r,a,s;e[0]!==o?({className:t,align:a,sideOffset:s,...r}=o,e[0]=o,e[1]=t,e[2]=r,e[3]=a,e[4]=s):(t=e[1],r=e[2],a=e[3],s=e[4]);const l=a===void 0?"center":a,u=s===void 0?4:s;let i;e[5]!==t?(i=q("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-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 z-50 w-64 origin-(--radix-hover-card-content-transform-origin) rounded-md border p-4 shadow-md outline-hidden",t),e[5]=t,e[6]=i):i=e[6];let p;return e[7]!==l||e[8]!==r||e[9]!==u||e[10]!==i?(p=d.jsx(re,{"data-slot":"hover-card-portal",children:d.jsx(ne,{"data-slot":"hover-card-content",align:l,sideOffset:u,className:i,...r})}),e[7]=l,e[8]=r,e[9]=u,e[10]=i,e[11]=p):p=e[11],p}export{ie as H,ce as a,se as b};
1
+ import{r as c,j as d,db as k,a6 as F,a7 as f,dd as T,af as $,bf as O,bq as I,de as U,df as W,dh as z,dc as B,bc as G,da as K,e as E,c as q}from"./index-8Av7_XG5.js";var w,b="HoverCard",[N]=$(b,[T]),R=T(),[V,S]=N(b),_=o=>{const{__scopeHoverCard:e,children:t,open:r,defaultOpen:a,onOpenChange:s,openDelay:l=700,closeDelay:u=300}=o,i=R(e),p=c.useRef(0),v=c.useRef(0),C=c.useRef(!1),h=c.useRef(!1),[m,n]=G({prop:r,defaultProp:a??!1,onChange:s,caller:b}),x=c.useCallback(()=>{clearTimeout(v.current),p.current=window.setTimeout(()=>n(!0),l)},[l,n]),L=c.useCallback(()=>{clearTimeout(p.current),!C.current&&!h.current&&(v.current=window.setTimeout(()=>n(!1),u))},[u,n]),M=c.useCallback(()=>n(!1),[n]);return c.useEffect(()=>()=>{clearTimeout(p.current),clearTimeout(v.current)},[]),d.jsx(V,{scope:e,open:m,onOpenChange:n,onOpen:x,onClose:L,onDismiss:M,hasSelectionRef:C,isPointerDownOnContentRef:h,children:d.jsx(K,{...i,children:t})})};_.displayName=b;var y="HoverCardTrigger",D=c.forwardRef((o,e)=>{const{__scopeHoverCard:t,...r}=o,a=S(y,t),s=R(t);return d.jsx(k,{asChild:!0,...s,children:d.jsx(F.a,{"data-state":a.open?"open":"closed",...r,ref:e,onPointerEnter:f(o.onPointerEnter,P(a.onOpen)),onPointerLeave:f(o.onPointerLeave,P(a.onClose)),onFocus:f(o.onFocus,a.onOpen),onBlur:f(o.onBlur,a.onClose),onTouchStart:f(o.onTouchStart,l=>l.preventDefault())})})});D.displayName=y;var H="HoverCardPortal",[J,Q]=N(H,{forceMount:void 0}),j=o=>{const{__scopeHoverCard:e,forceMount:t,children:r,container:a}=o,s=S(H,e);return d.jsx(J,{scope:e,forceMount:t,children:d.jsx(O,{present:t||s.open,children:d.jsx(B,{asChild:!0,container:a,children:r})})})};j.displayName=H;var g="HoverCardContent",A=c.forwardRef((o,e)=>{const t=Q(g,o.__scopeHoverCard),{forceMount:r=t.forceMount,...a}=o,s=S(g,o.__scopeHoverCard);return d.jsx(O,{present:r||s.open,children:d.jsx(X,{"data-state":s.open?"open":"closed",...a,onPointerEnter:f(o.onPointerEnter,P(s.onOpen)),onPointerLeave:f(o.onPointerLeave,P(s.onClose)),ref:e})})});A.displayName=g;var X=c.forwardRef((o,e)=>{const{__scopeHoverCard:t,onEscapeKeyDown:r,onPointerDownOutside:a,onFocusOutside:s,onInteractOutside:l,...u}=o,i=S(g,t),p=R(t),v=c.useRef(null),C=I(e,v),[h,m]=c.useState(!1);return c.useEffect(()=>{if(h){const n=document.body;return w=n.style.userSelect||n.style.webkitUserSelect,n.style.userSelect="none",n.style.webkitUserSelect="none",()=>{n.style.userSelect=w,n.style.webkitUserSelect=w}}},[h]),c.useEffect(()=>{if(v.current){const n=()=>{m(!1),i.isPointerDownOnContentRef.current=!1,setTimeout(()=>{document.getSelection()?.toString()!==""&&(i.hasSelectionRef.current=!0)})};return document.addEventListener("pointerup",n),()=>{document.removeEventListener("pointerup",n),i.hasSelectionRef.current=!1,i.isPointerDownOnContentRef.current=!1}}},[i.isPointerDownOnContentRef,i.hasSelectionRef]),c.useEffect(()=>{v.current&&ee(v.current).forEach(x=>x.setAttribute("tabindex","-1"))}),d.jsx(U,{asChild:!0,disableOutsidePointerEvents:!1,onInteractOutside:l,onEscapeKeyDown:r,onPointerDownOutside:a,onFocusOutside:f(s,n=>{n.preventDefault()}),onDismiss:i.onDismiss,children:d.jsx(W,{...p,...u,onPointerDown:f(u.onPointerDown,n=>{n.currentTarget.contains(n.target)&&m(!0),i.hasSelectionRef.current=!1,i.isPointerDownOnContentRef.current=!0}),ref:C,style:{...u.style,userSelect:h?"text":void 0,WebkitUserSelect:h?"text":void 0,"--radix-hover-card-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-hover-card-content-available-width":"var(--radix-popper-available-width)","--radix-hover-card-content-available-height":"var(--radix-popper-available-height)","--radix-hover-card-trigger-width":"var(--radix-popper-anchor-width)","--radix-hover-card-trigger-height":"var(--radix-popper-anchor-height)"}})})}),Y="HoverCardArrow",Z=c.forwardRef((o,e)=>{const{__scopeHoverCard:t,...r}=o,a=R(t);return d.jsx(z,{...a,...r,ref:e})});Z.displayName=Y;function P(o){return e=>e.pointerType==="touch"?void 0:o()}function ee(o){const e=[],t=document.createTreeWalker(o,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});for(;t.nextNode();)e.push(t.currentNode);return e}var te=_,oe=D,re=j,ne=A;function se(o){const e=E.c(4);let t;e[0]!==o?({...t}=o,e[0]=o,e[1]=t):t=e[1];let r;return e[2]!==t?(r=d.jsx(te,{"data-slot":"hover-card",...t}),e[2]=t,e[3]=r):r=e[3],r}function ie(o){const e=E.c(4);let t;e[0]!==o?({...t}=o,e[0]=o,e[1]=t):t=e[1];let r;return e[2]!==t?(r=d.jsx(oe,{"data-slot":"hover-card-trigger",...t}),e[2]=t,e[3]=r):r=e[3],r}function ce(o){const e=E.c(12);let t,r,a,s;e[0]!==o?({className:t,align:a,sideOffset:s,...r}=o,e[0]=o,e[1]=t,e[2]=r,e[3]=a,e[4]=s):(t=e[1],r=e[2],a=e[3],s=e[4]);const l=a===void 0?"center":a,u=s===void 0?4:s;let i;e[5]!==t?(i=q("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-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 z-50 w-64 origin-(--radix-hover-card-content-transform-origin) rounded-md border p-4 shadow-md outline-hidden",t),e[5]=t,e[6]=i):i=e[6];let p;return e[7]!==l||e[8]!==r||e[9]!==u||e[10]!==i?(p=d.jsx(re,{"data-slot":"hover-card-portal",children:d.jsx(ne,{"data-slot":"hover-card-content",align:l,sideOffset:u,className:i,...r})}),e[7]=l,e[8]=r,e[9]=u,e[10]=i,e[11]=p):p=e[11],p}export{ie as H,ce as a,se as b};
@@ -1 +1 @@
1
- import{e as w,q as be,a as Ne,K as ke,j as t,E as we,r as $,c as de,B as Y,l as Ce,M as Ie,o as Q}from"./index-B9kRhzg7.js";import{a as W}from"./Tool01-DRibBi0T.js";import{s as Se}from"./Trash01-DfuJtop_.js";import{i as fe}from"./Upload01-DGWS8Icx.js";import{I as _e}from"./input-DCOoktZX.js";import{L as Pe}from"./label-dlG4_xKf.js";import{i as Ue}from"./AlertCircle-DQ3zaMns.js";import{i as ge}from"./Check-DCJCCJt5.js";import{a as $e}from"./Eye-ogI2y4CN.js";import{i as De}from"./DotsVertical-DDPFnnRS.js";import{E as ze}from"./agent-icon-DFJgaXFK.js";import{n as Fe}from"./LinkExternal01-9W209kLr.js";import{D as Te,c as Ee,e as Le,b as Oe,a as Ae}from"./dialog-J9xRnRHX.js";import{c as ce,a as Me,D as Re,b as Be}from"./dropdown-menu-Do65ajnt.js";import{S as Ge}from"./skeleton-KI9W-P-f.js";import{T as Ve,a as Ke,b as qe,c as Je}from"./tabs-DGoyKbi9.js";import{u as Qe,c as Ye}from"./use-file-configs-DC8U7Oa7.js";import{u as We}from"./useInfiniteQuery-B2j87XPZ.js";import{S as He,u as Xe}from"./constants-BFQrPD6r.js";import{u as Ze}from"./unwrap-tool-result-BYXdCQMg.js";function et(s){if(typeof s=="string")return s;if(!s||typeof s!="object")return"";const e=s;if(Array.isArray(e.variants)){const n=e.variants,l=n.find(o=>o.rule?.__resolveType?.includes("always"));if(typeof l?.value=="string")return l.value;const i=n.find(o=>typeof o.value=="string");if(i)return i.value}return typeof e.src=="string"?e.src:typeof e.url=="string"?e.url:typeof e.value=="string"?e.value:""}function tt(s){const e=w.c(13),{org:n}=be();let l;e[0]!==n.id||e[1]!==n.slug?(l={connectionId:He,orgId:n.id,orgSlug:n.slug},e[0]=n.id,e[1]=n.slug,e[2]=l):l=e[2];const i=Xe(l);let o;e[3]!==n.id||e[4]!==s.configId?(o=ke.filePickerObjects(n.id,s.configId),e[3]=n.id,e[4]=s.configId,e[5]=o):o=e[5];const a=s.enabled!==!1&&!!s.configId;let r;e[6]!==i||e[7]!==s.configId?(r=async c=>{const{pageParam:g}=c,f=await i.callTool({name:"FILE_OBJECTS_LIST",arguments:{configId:s.configId,cursor:g??void 0}});return Ze(f)},e[6]=i,e[7]=s.configId,e[8]=r):r=e[8];let d;return e[9]!==o||e[10]!==a||e[11]!==r?(d={queryKey:o,enabled:a,staleTime:3e4,initialPageParam:null,queryFn:r,getNextPageParam:st},e[9]=o,e[10]=a,e[11]=r,e[12]=d):d=e[12],We(d)}function st(s){return s.nextCursor??void 0}function je(){const s=w.c(2),{org:e}=be();let n;return s[0]!==e?(n={mutationFn:async l=>{const i=l.file.type||"application/octet-stream",o=await fetch(`/api/${encodeURIComponent(e.slug)}/file-configs/${encodeURIComponent(l.configId)}/upload?filename=${encodeURIComponent(l.file.name)}`,{method:"POST",headers:{"Content-Type":i},body:l.file});if(!o.ok){const a=await o.text().catch(nt);let r=`${o.status} ${o.statusText}`;try{const d=JSON.parse(a);d.message&&(r=d.message)}catch{a&&(r=a.slice(0,200))}throw new Error(`Upload failed: ${r}`)}return await o.json()}},s[0]=e,s[1]=n):n=s[1],Ne(n)}function nt(){return""}const ue="file-picker:last-config-id";function it(s){const e=w.c(18),n=s.mode==="image"?"Pick an image":"Pick a file";let l;e[0]!==n?(l=t.jsx(Ee,{children:n}),e[0]=n,e[1]=l):l=e[1];let i;e[2]===Symbol.for("react.memo_cache_sentinel")?(i=t.jsx(Le,{children:"Upload a new file or pick one previously uploaded to a configured bucket."}),e[2]=i):i=e[2];let o;e[3]!==l?(o=t.jsxs(Oe,{children:[l,i]}),e[3]=l,e[4]=o):o=e[4];let a;e[5]===Symbol.for("react.memo_cache_sentinel")?(a=t.jsx(Ge,{className:"h-64 w-full"}),e[5]=a):a=e[5];let r;e[6]!==s?(r=f=>{s.onSelect(f),s.onOpenChange(!1)},e[6]=s,e[7]=r):r=e[7];let d;e[8]!==s.mode||e[9]!==r?(d=t.jsx(we,{fallback:lt,children:t.jsx($.Suspense,{fallback:a,children:t.jsx(ot,{mode:s.mode,onSelect:r})})}),e[8]=s.mode,e[9]=r,e[10]=d):d=e[10];let c;e[11]!==o||e[12]!==d?(c=t.jsxs(Ae,{className:"sm:max-w-3xl max-h-[85vh] overflow-hidden flex flex-col",children:[o,d]}),e[11]=o,e[12]=d,e[13]=c):c=e[13];let g;return e[14]!==s.onOpenChange||e[15]!==s.open||e[16]!==c?(g=t.jsx(Te,{open:s.open,onOpenChange:s.onOpenChange,children:c}),e[14]=s.onOpenChange,e[15]=s.open,e[16]=c,e[17]=g):g=e[17],g}function lt(s){const{error:e}=s;return t.jsx(rt,{error:e??new Error("Failed to load buckets")})}function rt(s){const e=w.c(3),{error:n}=s;let l;e[0]===Symbol.for("react.memo_cache_sentinel")?(l=t.jsx(Ue,{size:16}),e[0]=l):l=e[0];let i;return e[1]!==n.message?(i=t.jsxs("div",{className:"p-4 rounded-md bg-destructive/10 text-destructive flex items-center gap-2",children:[l,t.jsx("span",{className:"text-sm font-medium",children:n.message})]}),e[1]=n.message,e[2]=i):i=e[2],i}function ot(s){const e=w.c(23),{mode:n,onSelect:l}=s,i=Qe();if(i.length===0){let u;return e[0]===Symbol.for("react.memo_cache_sentinel")?(u=t.jsx(dt,{}),e[0]=u):u=e[0],u}if(i.length===1){const u=i[0];let p;return e[1]!==u||e[2]!==n||e[3]!==l?(p=t.jsx(pe,{config:u,mode:n,onSelect:l}),e[1]=u,e[2]=n,e[3]=l,e[4]=p):p=e[4],p}let o;e[5]===Symbol.for("react.memo_cache_sentinel")?(o=typeof window<"u"?window.localStorage.getItem(ue):null,e[5]=o):o=e[5];const a=o;let r;e[6]!==i?(r=i.find(u=>u.id===a)?.id??i[0].id,e[6]=i,e[7]=r):r=e[7];const d=r;let c;e[8]!==i?(c=i.map(at),e[8]=i,e[9]=c):c=e[9];let g;e[10]!==c?(g=t.jsx(Ke,{className:"self-start",children:c}),e[10]=c,e[11]=g):g=e[11];let f;if(e[12]!==i||e[13]!==n||e[14]!==l){let u;e[16]!==n||e[17]!==l?(u=p=>t.jsx(qe,{value:p.id,className:"min-h-0 flex-1 overflow-hidden",children:t.jsx(pe,{config:p,mode:n,onSelect:l})},p.id),e[16]=n,e[17]=l,e[18]=u):u=e[18],f=i.map(u),e[12]=i,e[13]=n,e[14]=l,e[15]=f}else f=e[15];let x;return e[19]!==d||e[20]!==g||e[21]!==f?(x=t.jsxs(Je,{defaultValue:d,onValueChange:ct,className:"min-h-0 flex-1 flex flex-col",children:[g,f]}),e[19]=d,e[20]=g,e[21]=f,e[22]=x):x=e[22],x}function at(s){return t.jsx(Ve,{value:s.id,children:s.name},s.id)}function ct(s){typeof window<"u"&&window.localStorage.setItem(ue,s)}function dt(){const s=w.c(3);let e,n;s[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx("div",{className:"size-12 rounded-full bg-muted flex items-center justify-center",children:t.jsx(fe,{size:20,className:"text-muted-foreground"})}),n=t.jsxs("div",{children:[t.jsx("p",{className:"font-medium text-sm",children:"No bucket configured"}),t.jsx("p",{className:"text-xs text-muted-foreground mt-1 max-w-sm",children:"Add an S3-compatible bucket in Settings before you can upload files."})]}),s[0]=e,s[1]=n):(e=s[0],n=s[1]);let l;return s[2]===Symbol.for("react.memo_cache_sentinel")?(l=t.jsxs("div",{className:"rounded-xl border border-dashed border-border/60 p-10 flex flex-col items-center justify-center text-center gap-3",children:[e,n,t.jsx(Y,{asChild:!0,size:"sm",className:"mt-2",children:t.jsx(Ie,{to:"/settings/files",children:"Configure a bucket"})})]}),s[2]=l):l=s[2],l}function pe({config:s,mode:e,onSelect:n}){const l=tt({configId:s.id}),i=je(),[o,a]=$.useState(!1),r=$.useRef(null),d=e==="image"?"image/*":void 0;async function c(m){if(!m)return;const y=Array.from(m);if(y.length===0)return;let k=null;const b=[];for(const N of y)try{const h=await i.mutateAsync({configId:s.id,file:N});k??=h.publicUrl}catch(h){b.push(`${N.name} (${h instanceof Error?h.message:"upload failed"})`)}await l.refetch(),b.length>0&&Q.error(b.length===y.length?`Upload failed: ${b.join("; ")}`:`Some files failed: ${b.join("; ")}`),k&&n(k)}function g(m){m.preventDefault(),a(!0)}function f(){a(!1)}function x(m){m.preventDefault(),a(!1),c(m.dataTransfer.files)}const p=(l.data?.pages??[]).flatMap(m=>m.items),j=p.filter(m=>e==="image"?ye(m.key):!0);return t.jsxs("div",{className:"flex flex-col gap-3 min-h-0 h-full",children:[t.jsxs("button",{type:"button",onClick:()=>r.current?.click(),onDragOver:g,onDragLeave:f,onDrop:x,className:de("rounded-xl border border-dashed border-border/60 p-6 flex flex-col items-center justify-center gap-2 text-center transition-colors",o&&"border-primary bg-primary/5",i.isPending&&"opacity-60 pointer-events-none"),children:[t.jsx(fe,{size:18,className:"text-muted-foreground"}),t.jsx("p",{className:"text-sm font-medium",children:i.isPending?"Uploading…":"Drop files here or click to upload"}),t.jsxs("p",{className:"text-xs text-muted-foreground",children:["Up to 100 MB."," ",e==="image"?"Images only (PNG, JPEG, WebP, GIF, SVG, AVIF).":"Common image, video, audio, and document types."]}),t.jsx("input",{ref:r,type:"file",accept:d,multiple:!0,className:"hidden",onChange:m=>{const y=m.target.files;m.target.value="",c(y)}})]}),l.isFetching&&!l.isFetchingNextPage?t.jsx("div",{className:"flex justify-end",children:t.jsx("span",{className:"text-xs text-muted-foreground",children:"Loading…"})}):null,t.jsxs("div",{className:"min-h-0 flex-1 overflow-y-auto pr-1",children:[j.length===0?e==="image"&&p.length>0?t.jsx(ut,{}):t.jsx(ft,{}):e==="image"?t.jsx(gt,{items:j,onSelect:n}):t.jsx(pt,{items:j,onSelect:n}),l.hasNextPage&&t.jsx("div",{className:"flex justify-center py-4",children:t.jsx(Y,{type:"button",variant:"outline",size:"sm",disabled:l.isFetchingNextPage,onClick:()=>l.fetchNextPage(),children:l.isFetchingNextPage?t.jsxs(t.Fragment,{children:[t.jsx(Ce,{size:14,className:"animate-spin"}),"Loading…"]}):"Load more"})})]})]})}function ft(){const s=w.c(1);let e;return s[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsxs("div",{className:"flex h-full min-h-40 flex-col items-center justify-center gap-2 py-8 text-center",children:[t.jsx("div",{className:"flex size-10 items-center justify-center rounded-full bg-muted",children:t.jsx(W,{size:18,className:"text-muted-foreground"})}),t.jsx("p",{className:"text-sm font-medium",children:"No files in this bucket yet"}),t.jsx("p",{className:"text-xs text-muted-foreground",children:"Drop a file above to get started."})]}),s[0]=e):e=s[0],e}function ut(){const s=w.c(1);let e;return s[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsxs("div",{className:"flex h-full min-h-40 flex-col items-center justify-center gap-2 py-8 text-center",children:[t.jsx("div",{className:"flex size-10 items-center justify-center rounded-full bg-muted",children:t.jsx(W,{size:18,className:"text-muted-foreground"})}),t.jsx("p",{className:"text-sm font-medium",children:"No images in this bucket yet"}),t.jsx("p",{className:"text-xs text-muted-foreground",children:"The bucket has other files, but none match common image formats."})]}),s[0]=e):e=s[0],e}function ye(s){return/\.(png|jpe?g|gif|webp|svg|avif|bmp)$/i.test(s)}function mt(s){const e=s.lastIndexOf(".");return e<0||e===s.length-1?"file":s.slice(e+1).toLowerCase()}function gt(s){const e=w.c(7),{items:n,onSelect:l}=s;let i;if(e[0]!==n||e[1]!==l){let a;e[3]!==l?(a=r=>t.jsx(ve,{item:r,variant:"image",onSelect:l},r.key),e[3]=l,e[4]=a):a=e[4],i=n.map(a),e[0]=n,e[1]=l,e[2]=i}else i=e[2];let o;return e[5]!==i?(o=t.jsx("div",{className:"grid grid-cols-2 sm:grid-cols-3 md:grid-cols-4 gap-3",children:i}),e[5]=i,e[6]=o):o=e[6],o}function pt(s){const e=w.c(7),{items:n,onSelect:l}=s;let i;if(e[0]!==n||e[1]!==l){let a;e[3]!==l?(a=r=>t.jsx("li",{children:t.jsx(ve,{item:r,variant:"row",onSelect:l})},r.key),e[3]=l,e[4]=a):a=e[4],i=n.map(a),e[0]=n,e[1]=l,e[2]=i}else i=e[2];let o;return e[5]!==i?(o=t.jsx("ul",{className:"divide-y divide-border/60 rounded-lg border border-border/60",children:i}),e[5]=i,e[6]=o):o=e[6],o}function ve(s){const e=w.c(58),{item:n,variant:l,onSelect:i}=s;let o;e[0]!==n.key?(o=mt(n.key),e[0]=n.key,e[1]=o):o=e[1];const a=o;if(l==="image"){let b;e[2]!==n.publicUrl||e[3]!==i?(b=()=>i(n.publicUrl),e[2]=n.publicUrl,e[3]=i,e[4]=b):b=e[4];let N;e[5]!==n.key||e[6]!==n.publicUrl?(N=t.jsx("img",{src:n.publicUrl,alt:n.key,loading:"lazy",className:"h-full w-full object-cover",onError:xt}),e[5]=n.key,e[6]=n.publicUrl,e[7]=N):N=e[7];let h;e[8]!==n.key||e[9]!==b||e[10]!==N?(h=t.jsx("button",{type:"button",onClick:b,className:"block h-full w-full transition hover:ring-2 hover:ring-primary",title:n.key,children:N}),e[8]=n.key,e[9]=b,e[10]=N,e[11]=h):h=e[11];let C;e[12]!==a?(C=t.jsx("span",{className:"pointer-events-none absolute left-1.5 top-1.5 rounded bg-background/80 px-1.5 py-0.5 text-[10px] font-medium uppercase text-foreground opacity-0 backdrop-blur-sm transition-opacity group-hover:opacity-100",children:a}),e[12]=a,e[13]=C):C=e[13];let S;e[14]!==n||e[15]!==i?(S=t.jsx("div",{className:"absolute right-1.5 top-1.5 opacity-0 transition-opacity group-hover:opacity-100",children:t.jsx(xe,{item:n,onSelect:i})}),e[14]=n,e[15]=i,e[16]=S):S=e[16];let I;e[17]!==n.key?(I=he(n.key),e[17]=n.key,e[18]=I):I=e[18];let _;e[19]!==I?(_=t.jsx("div",{className:"pointer-events-none absolute inset-x-0 bottom-0 bg-gradient-to-t from-black/70 to-transparent p-2 opacity-0 transition-opacity group-hover:opacity-100",children:t.jsx("p",{className:"truncate text-xs text-white",children:I})}),e[19]=I,e[20]=_):_=e[20];let P;return e[21]!==h||e[22]!==C||e[23]!==S||e[24]!==_?(P=t.jsxs("div",{className:"group relative aspect-square overflow-hidden rounded-lg border border-border/60 bg-muted",children:[h,C,S,_]}),e[21]=h,e[22]=C,e[23]=S,e[24]=_,e[25]=P):P=e[25],P}let r;e[26]!==n.publicUrl||e[27]!==i?(r=()=>i(n.publicUrl),e[26]=n.publicUrl,e[27]=i,e[28]=r):r=e[28];let d;e[29]!==n.key?(d=t.jsx("div",{className:"flex size-9 shrink-0 items-center justify-center rounded-md bg-muted",children:ye(n.key)?t.jsx(W,{size:16,className:"text-muted-foreground"}):t.jsx(ze,{size:16,className:"text-muted-foreground"})}),e[29]=n.key,e[30]=d):d=e[30];let c;e[31]!==n.key?(c=he(n.key),e[31]=n.key,e[32]=c):c=e[32];let g;e[33]!==c?(g=t.jsx("p",{className:"truncate text-sm font-medium",children:c}),e[33]=c,e[34]=g):g=e[34];let f;e[35]!==n.key?(f=t.jsx("p",{className:"truncate font-mono text-xs text-muted-foreground",children:n.key}),e[35]=n.key,e[36]=f):f=e[36];let x;e[37]!==g||e[38]!==f?(x=t.jsxs("div",{className:"min-w-0 flex-1",children:[g,f]}),e[37]=g,e[38]=f,e[39]=x):x=e[39];let u;e[40]!==a?(u=t.jsx("span",{className:"shrink-0 rounded bg-muted px-1.5 py-0.5 text-[10px] font-medium uppercase text-muted-foreground",children:a}),e[40]=a,e[41]=u):u=e[41];let p;e[42]!==n.size?(p=yt(n.size),e[42]=n.size,e[43]=p):p=e[43];let j;e[44]!==p?(j=t.jsx("span",{className:"shrink-0 text-xs text-muted-foreground",children:p}),e[44]=p,e[45]=j):j=e[45];let m;e[46]!==j||e[47]!==r||e[48]!==d||e[49]!==x||e[50]!==u?(m=t.jsxs("button",{type:"button",onClick:r,className:"flex min-w-0 flex-1 items-center gap-3 text-left",children:[d,x,u,j]}),e[46]=j,e[47]=r,e[48]=d,e[49]=x,e[50]=u,e[51]=m):m=e[51];let y;e[52]!==n||e[53]!==i?(y=t.jsx(xe,{item:n,onSelect:i}),e[52]=n,e[53]=i,e[54]=y):y=e[54];let k;return e[55]!==m||e[56]!==y?(k=t.jsxs("div",{className:"group flex items-center gap-3 px-3 py-2 transition hover:bg-muted/50",children:[m,y]}),e[55]=m,e[56]=y,e[57]=k):k=e[57],k}function xt(s){s.target.style.display="none"}function xe(s){const e=w.c(22),{item:n,onSelect:l}=s,[i,o]=$.useState(!1);let a;e[0]!==n.publicUrl?(a=async function(b){b.preventDefault(),b.stopPropagation();try{await navigator.clipboard.writeText(n.publicUrl),o(!0),window.setTimeout(()=>o(!1),1500)}catch{Q.error("Failed to copy URL")}},e[0]=n.publicUrl,e[1]=a):a=e[1];const r=a;let d;e[2]===Symbol.for("react.memo_cache_sentinel")?(d=t.jsx(Me,{asChild:!0,children:t.jsx(Y,{type:"button",variant:"ghost",size:"icon",className:"size-7 rounded-md bg-background/80 backdrop-blur-sm",onClick:jt,"aria-label":"Asset actions",children:t.jsx(De,{size:14})})}),e[2]=d):d=e[2];let c;e[3]!==n.publicUrl||e[4]!==l?(c=()=>l(n.publicUrl),e[3]=n.publicUrl,e[4]=l,e[5]=c):c=e[5];let g;e[6]===Symbol.for("react.memo_cache_sentinel")?(g=t.jsx(ge,{size:14}),e[6]=g):g=e[6];let f;e[7]!==c?(f=t.jsxs(ce,{onClick:c,children:[g,"Use this"]}),e[7]=c,e[8]=f):f=e[8];let x;e[9]!==i?(x=i?t.jsx(ge,{size:14}):t.jsx($e,{size:14}),e[9]=i,e[10]=x):x=e[10];const u=i?"Copied":"Copy URL";let p;e[11]!==r||e[12]!==x||e[13]!==u?(p=t.jsxs(ce,{onClick:r,children:[x,u]}),e[11]=r,e[12]=x,e[13]=u,e[14]=p):p=e[14];let j;e[15]===Symbol.for("react.memo_cache_sentinel")?(j=t.jsx(Fe,{size:14}),e[15]=j):j=e[15];let m;e[16]!==n.publicUrl?(m=t.jsx(ce,{asChild:!0,children:t.jsxs("a",{href:n.publicUrl,target:"_blank",rel:"noreferrer",onClick:ht,children:[j,"Open in new tab"]})}),e[16]=n.publicUrl,e[17]=m):m=e[17];let y;return e[18]!==m||e[19]!==f||e[20]!==p?(y=t.jsxs(Re,{children:[d,t.jsxs(Be,{align:"end",onClick:bt,children:[f,p,m]})]}),e[18]=m,e[19]=f,e[20]=p,e[21]=y):y=e[21],y}function ht(s){return s.stopPropagation()}function bt(s){return s.stopPropagation()}function jt(s){return s.stopPropagation()}function he(s){const e=s.split("/");return e[e.length-1]??s}function yt(s){return s<1024?`${s} B`:s<1024*1024?`${(s/1024).toFixed(1)} KB`:`${(s/(1024*1024)).toFixed(1)} MB`}function vt(s){try{const e=new URL(s).pathname;return decodeURIComponent(e.split("/").pop()??s)}catch{return s.split("/").pop()??s}}function Nt(s){const e=s.lastIndexOf(".");return e<0||e===s.length-1?"":s.slice(e+1).toLowerCase()}const kt=new Set(["image/png","image/jpeg","image/gif","image/webp","image/svg+xml","image/avif"]);function Kt(s){const e=w.c(79),{schema:n,value:l,onChange:i,path:o,label:a}=s,r=et(l),[d,c]=$.useState(!1),[g,f]=$.useState(!1),[x,u]=$.useState(!1),[p,j]=$.useState(!1),m=r?vt(r):"",y=m?Nt(m):"",k=Ye(),b=je();let N;e[0]!==i||e[1]!==j||e[2]!==u?(N=function(v){u(!1),j(!1),i(v)},e[0]=i,e[1]=j,e[2]=u,e[3]=N):N=e[3];const h=N;let C;e[4]!==k.data?.configs?(C=function(){const v=k.data?.configs??[];if(v.length===1)return v[0].id;if(v.length===0)return null;const D=typeof window<"u"?window.localStorage.getItem(ue):null;return v.some(te=>te.id===D)?D:null},e[4]=k.data?.configs,e[5]=C):C=e[5];const S=C;let I;e[6]!==S||e[7]!==c||e[8]!==h||e[9]!==b?(I=async function(v){if(!v)return;const D=Array.from(v).filter(wt);if(D.length===0){Q.error("Only image files are accepted here.");return}const te=S();if(!te){c(!0);return}try{const ae=await b.mutateAsync({configId:te,file:D[0]});h(ae.publicUrl),D.length>1&&Q.info(`Uploaded ${D[0].name}; extra files were ignored (single-select field).`)}catch(ae){const me=ae;Q.error(me instanceof Error?me.message:"Upload failed")}},e[6]=S,e[7]=c,e[8]=h,e[9]=b,e[10]=I):I=e[10];const _=I;let P;e[11]!==f?(P=function(v){v.preventDefault(),v.dataTransfer.types.includes("Files")&&f(!0)},e[11]=f,e[12]=P):P=e[12];const se=P;let H;e[13]!==f?(H=function(v){v.currentTarget===v.target&&f(!1)},e[13]=f,e[14]=H):H=e[14];const ne=H;let X;e[15]!==_||e[16]!==f?(X=function(v){v.preventDefault(),f(!1),_(v.dataTransfer.files)},e[15]=_,e[16]=f,e[17]=X):X=e[17];const ie=X;let z;e[18]!==a||e[19]!==o?(z=t.jsx(Pe,{htmlFor:o,className:"text-muted-foreground",children:a}),e[18]=a,e[19]=o,e[20]=z):z=e[20];let F;e[21]!==n.description?(F=n.description&&t.jsx("p",{className:"text-xs leading-normal text-muted-foreground",children:n.description}),e[21]=n.description,e[22]=F):F=e[22];let T;e[23]!==z||e[24]!==F?(T=t.jsxs("div",{className:"min-w-0 space-y-0.5",children:[z,F]}),e[23]=z,e[24]=F,e[25]=T):T=e[25];const le=g&&"border-primary ring-2 ring-primary/30",re=b.isPending&&"pointer-events-none opacity-60";let E;e[26]!==le||e[27]!==re?(E=de("group relative w-full overflow-hidden rounded-xl border border-border/60 bg-muted/30 transition",le,re),e[26]=le,e[27]=re,e[28]=E):E=e[28];let L;e[29]!==y||e[30]!==m||e[31]!==p||e[32]!==x||e[33]!==a||e[34]!==j||e[35]!==u||e[36]!==c||e[37]!==r||e[38]!==b.isPending?(L=r?t.jsxs(t.Fragment,{children:[t.jsxs("div",{className:"relative h-40 w-full bg-[image:linear-gradient(45deg,rgba(0,0,0,0.04)_25%,transparent_25%,transparent_75%,rgba(0,0,0,0.04)_75%),linear-gradient(45deg,rgba(0,0,0,0.04)_25%,transparent_25%,transparent_75%,rgba(0,0,0,0.04)_75%)] bg-[position:0_0,8px_8px] [background-size:16px_16px]",children:[!p&&t.jsx("img",{src:r,alt:a,className:de("h-full w-full object-contain transition-opacity",!x&&"opacity-0"),onLoad:()=>u(!0),onError:()=>j(!0)},r),p&&t.jsxs("div",{className:"flex h-full w-full flex-col items-center justify-center gap-1 text-muted-foreground",children:[t.jsx(W,{size:20}),t.jsx("p",{className:"text-xs",children:"Preview unavailable"})]}),!x&&!p&&t.jsx("div",{className:"absolute inset-0 animate-pulse bg-muted/60"})]}),t.jsxs("div",{className:"flex items-center gap-2 border-t border-border/60 bg-background/50 px-3 py-2",children:[t.jsx("span",{className:"min-w-0 flex-1 truncate text-xs font-medium",children:m}),y&&t.jsx("span",{className:"shrink-0 rounded bg-muted px-1.5 py-0.5 text-[10px] font-medium uppercase text-muted-foreground",children:y})]})]}):t.jsxs("button",{type:"button",onClick:()=>c(!0),className:"flex h-40 w-full flex-col items-center justify-center gap-2 text-sm text-muted-foreground hover:bg-muted/60 hover:text-foreground",children:[t.jsx(W,{size:20}),t.jsx("span",{className:"text-sm font-medium",children:b.isPending?"Uploading…":"Drop an image or click to browse"}),t.jsx("span",{className:"text-xs text-muted-foreground",children:"PNG, JPEG, WebP, GIF, SVG, AVIF — up to 100 MB"})]}),e[29]=y,e[30]=m,e[31]=p,e[32]=x,e[33]=a,e[34]=j,e[35]=u,e[36]=c,e[37]=r,e[38]=b.isPending,e[39]=L):L=e[39];let O;e[40]!==g?(O=g&&t.jsx("div",{className:"pointer-events-none absolute inset-0 flex items-center justify-center bg-primary/10 backdrop-blur-[1px]",children:t.jsx("span",{className:"rounded-md bg-background px-3 py-1.5 text-xs font-medium shadow",children:"Drop to upload"})}),e[40]=g,e[41]=O):O=e[41];let A;e[42]!==ne||e[43]!==se||e[44]!==ie||e[45]!==E||e[46]!==L||e[47]!==O?(A=t.jsxs("div",{onDragOver:se,onDragLeave:ne,onDrop:ie,className:E,children:[L,O]}),e[42]=ne,e[43]=se,e[44]=ie,e[45]=E,e[46]=L,e[47]=O,e[48]=A):A=e[48];let M;e[49]!==h?(M=U=>h(U.target.value),e[49]=h,e[50]=M):M=e[50];let R;e[51]!==o||e[52]!==r||e[53]!==M?(R=t.jsx(_e,{id:o,type:"url",value:r,onChange:M,placeholder:"https://...",className:"h-9 min-w-0 flex-1"}),e[51]=o,e[52]=r,e[53]=M,e[54]=R):R=e[54];let B;e[55]!==c?(B=()=>c(!0),e[55]=c,e[56]=B):B=e[56];let Z;e[57]===Symbol.for("react.memo_cache_sentinel")?(Z=t.jsx(fe,{size:14}),e[57]=Z):Z=e[57];const oe=r?"Replace":"Browse";let G;e[58]!==B||e[59]!==oe?(G=t.jsxs(Y,{type:"button",variant:"outline",size:"sm",onClick:B,className:"h-9 shrink-0",children:[Z,oe]}),e[58]=B,e[59]=oe,e[60]=G):G=e[60];let V;e[61]!==h||e[62]!==r?(V=r&&t.jsx(Y,{type:"button",variant:"ghost",size:"sm",onClick:()=>h(""),className:"h-9 shrink-0","aria-label":"Remove image",children:t.jsx(Se,{size:14})}),e[61]=h,e[62]=r,e[63]=V):V=e[63];let K;e[64]!==R||e[65]!==G||e[66]!==V?(K=t.jsxs("div",{className:"flex w-full min-w-0 items-center gap-2",children:[R,G,V]}),e[64]=R,e[65]=G,e[66]=V,e[67]=K):K=e[67];let q;e[68]!==h?(q=U=>h(U),e[68]=h,e[69]=q):q=e[69];let J;e[70]!==d||e[71]!==c||e[72]!==q?(J=t.jsx(it,{open:d,onOpenChange:c,mode:"image",onSelect:q}),e[70]=d,e[71]=c,e[72]=q,e[73]=J):J=e[73];let ee;return e[74]!==A||e[75]!==K||e[76]!==J||e[77]!==T?(ee=t.jsxs("div",{className:"grid w-full min-w-0 grid-cols-[minmax(0,1fr)] gap-2",children:[T,A,K,J]}),e[74]=A,e[75]=K,e[76]=J,e[77]=T,e[78]=ee):ee=e[78],ee}function wt(s){return kt.has(s.type||"")}export{it as F,Kt as I,ue as L,et as e,je as u};
1
+ import{e as w,q as be,a as Ne,K as ke,j as t,E as we,r as $,c as de,B as Y,l as Ce,M as Ie,o as Q}from"./index-8Av7_XG5.js";import{a as W}from"./Tool01-Co9IzxOX.js";import{s as Se}from"./Trash01-m4F91Gbm.js";import{i as fe}from"./Upload01-BWuva6Fs.js";import{I as _e}from"./input-CFgdCIf-.js";import{L as Pe}from"./label-D5ze4fbW.js";import{i as Ue}from"./AlertCircle-Ctbek2zl.js";import{i as ge}from"./Check-D-2DMeXR.js";import{a as $e}from"./Eye-DLKlw-42.js";import{i as De}from"./DotsVertical-CYMPhMIv.js";import{G as ze}from"./agent-icon-VIqap9Jf.js";import{n as Fe}from"./LinkExternal01-C7Ulot5I.js";import{D as Te,c as Ee,e as Le,b as Oe,a as Ae}from"./dialog-BDoa-Aig.js";import{c as ce,a as Me,D as Re,b as Ge}from"./dropdown-menu-BuEg85yr.js";import{S as Be}from"./skeleton-KPs8aExG.js";import{T as Ve,a as Ke,b as qe,c as Je}from"./tabs-Bsb3WneA.js";import{u as Qe,c as Ye}from"./use-file-configs-DWgNRokn.js";import{u as We}from"./useInfiniteQuery-CQ_UxVw9.js";import{S as He,u as Xe}from"./constants-DeFtLUND.js";import{u as Ze}from"./unwrap-tool-result-BYXdCQMg.js";function et(s){if(typeof s=="string")return s;if(!s||typeof s!="object")return"";const e=s;if(Array.isArray(e.variants)){const n=e.variants,l=n.find(o=>o.rule?.__resolveType?.includes("always"));if(typeof l?.value=="string")return l.value;const i=n.find(o=>typeof o.value=="string");if(i)return i.value}return typeof e.src=="string"?e.src:typeof e.url=="string"?e.url:typeof e.value=="string"?e.value:""}function tt(s){const e=w.c(13),{org:n}=be();let l;e[0]!==n.id||e[1]!==n.slug?(l={connectionId:He,orgId:n.id,orgSlug:n.slug},e[0]=n.id,e[1]=n.slug,e[2]=l):l=e[2];const i=Xe(l);let o;e[3]!==n.id||e[4]!==s.configId?(o=ke.filePickerObjects(n.id,s.configId),e[3]=n.id,e[4]=s.configId,e[5]=o):o=e[5];const a=s.enabled!==!1&&!!s.configId;let r;e[6]!==i||e[7]!==s.configId?(r=async c=>{const{pageParam:g}=c,f=await i.callTool({name:"FILE_OBJECTS_LIST",arguments:{configId:s.configId,cursor:g??void 0}});return Ze(f)},e[6]=i,e[7]=s.configId,e[8]=r):r=e[8];let d;return e[9]!==o||e[10]!==a||e[11]!==r?(d={queryKey:o,enabled:a,staleTime:3e4,initialPageParam:null,queryFn:r,getNextPageParam:st},e[9]=o,e[10]=a,e[11]=r,e[12]=d):d=e[12],We(d)}function st(s){return s.nextCursor??void 0}function je(){const s=w.c(2),{org:e}=be();let n;return s[0]!==e?(n={mutationFn:async l=>{const i=l.file.type||"application/octet-stream",o=await fetch(`/api/${encodeURIComponent(e.slug)}/file-configs/${encodeURIComponent(l.configId)}/upload?filename=${encodeURIComponent(l.file.name)}`,{method:"POST",headers:{"Content-Type":i},body:l.file});if(!o.ok){const a=await o.text().catch(nt);let r=`${o.status} ${o.statusText}`;try{const d=JSON.parse(a);d.message&&(r=d.message)}catch{a&&(r=a.slice(0,200))}throw new Error(`Upload failed: ${r}`)}return await o.json()}},s[0]=e,s[1]=n):n=s[1],Ne(n)}function nt(){return""}const ue="file-picker:last-config-id";function it(s){const e=w.c(18),n=s.mode==="image"?"Pick an image":"Pick a file";let l;e[0]!==n?(l=t.jsx(Ee,{children:n}),e[0]=n,e[1]=l):l=e[1];let i;e[2]===Symbol.for("react.memo_cache_sentinel")?(i=t.jsx(Le,{children:"Upload a new file or pick one previously uploaded to a configured bucket."}),e[2]=i):i=e[2];let o;e[3]!==l?(o=t.jsxs(Oe,{children:[l,i]}),e[3]=l,e[4]=o):o=e[4];let a;e[5]===Symbol.for("react.memo_cache_sentinel")?(a=t.jsx(Be,{className:"h-64 w-full"}),e[5]=a):a=e[5];let r;e[6]!==s?(r=f=>{s.onSelect(f),s.onOpenChange(!1)},e[6]=s,e[7]=r):r=e[7];let d;e[8]!==s.mode||e[9]!==r?(d=t.jsx(we,{fallback:lt,children:t.jsx($.Suspense,{fallback:a,children:t.jsx(ot,{mode:s.mode,onSelect:r})})}),e[8]=s.mode,e[9]=r,e[10]=d):d=e[10];let c;e[11]!==o||e[12]!==d?(c=t.jsxs(Ae,{className:"sm:max-w-3xl max-h-[85vh] overflow-hidden flex flex-col",children:[o,d]}),e[11]=o,e[12]=d,e[13]=c):c=e[13];let g;return e[14]!==s.onOpenChange||e[15]!==s.open||e[16]!==c?(g=t.jsx(Te,{open:s.open,onOpenChange:s.onOpenChange,children:c}),e[14]=s.onOpenChange,e[15]=s.open,e[16]=c,e[17]=g):g=e[17],g}function lt(s){const{error:e}=s;return t.jsx(rt,{error:e??new Error("Failed to load buckets")})}function rt(s){const e=w.c(3),{error:n}=s;let l;e[0]===Symbol.for("react.memo_cache_sentinel")?(l=t.jsx(Ue,{size:16}),e[0]=l):l=e[0];let i;return e[1]!==n.message?(i=t.jsxs("div",{className:"p-4 rounded-md bg-destructive/10 text-destructive flex items-center gap-2",children:[l,t.jsx("span",{className:"text-sm font-medium",children:n.message})]}),e[1]=n.message,e[2]=i):i=e[2],i}function ot(s){const e=w.c(23),{mode:n,onSelect:l}=s,i=Qe();if(i.length===0){let u;return e[0]===Symbol.for("react.memo_cache_sentinel")?(u=t.jsx(dt,{}),e[0]=u):u=e[0],u}if(i.length===1){const u=i[0];let p;return e[1]!==u||e[2]!==n||e[3]!==l?(p=t.jsx(pe,{config:u,mode:n,onSelect:l}),e[1]=u,e[2]=n,e[3]=l,e[4]=p):p=e[4],p}let o;e[5]===Symbol.for("react.memo_cache_sentinel")?(o=typeof window<"u"?window.localStorage.getItem(ue):null,e[5]=o):o=e[5];const a=o;let r;e[6]!==i?(r=i.find(u=>u.id===a)?.id??i[0].id,e[6]=i,e[7]=r):r=e[7];const d=r;let c;e[8]!==i?(c=i.map(at),e[8]=i,e[9]=c):c=e[9];let g;e[10]!==c?(g=t.jsx(Ke,{className:"self-start",children:c}),e[10]=c,e[11]=g):g=e[11];let f;if(e[12]!==i||e[13]!==n||e[14]!==l){let u;e[16]!==n||e[17]!==l?(u=p=>t.jsx(qe,{value:p.id,className:"min-h-0 flex-1 overflow-hidden",children:t.jsx(pe,{config:p,mode:n,onSelect:l})},p.id),e[16]=n,e[17]=l,e[18]=u):u=e[18],f=i.map(u),e[12]=i,e[13]=n,e[14]=l,e[15]=f}else f=e[15];let x;return e[19]!==d||e[20]!==g||e[21]!==f?(x=t.jsxs(Je,{defaultValue:d,onValueChange:ct,className:"min-h-0 flex-1 flex flex-col",children:[g,f]}),e[19]=d,e[20]=g,e[21]=f,e[22]=x):x=e[22],x}function at(s){return t.jsx(Ve,{value:s.id,children:s.name},s.id)}function ct(s){typeof window<"u"&&window.localStorage.setItem(ue,s)}function dt(){const s=w.c(3);let e,n;s[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx("div",{className:"size-12 rounded-full bg-muted flex items-center justify-center",children:t.jsx(fe,{size:20,className:"text-muted-foreground"})}),n=t.jsxs("div",{children:[t.jsx("p",{className:"font-medium text-sm",children:"No bucket configured"}),t.jsx("p",{className:"text-xs text-muted-foreground mt-1 max-w-sm",children:"Add an S3-compatible bucket in Settings before you can upload files."})]}),s[0]=e,s[1]=n):(e=s[0],n=s[1]);let l;return s[2]===Symbol.for("react.memo_cache_sentinel")?(l=t.jsxs("div",{className:"rounded-xl border border-dashed border-border/60 p-10 flex flex-col items-center justify-center text-center gap-3",children:[e,n,t.jsx(Y,{asChild:!0,size:"sm",className:"mt-2",children:t.jsx(Ie,{to:"/settings/files",children:"Configure a bucket"})})]}),s[2]=l):l=s[2],l}function pe({config:s,mode:e,onSelect:n}){const l=tt({configId:s.id}),i=je(),[o,a]=$.useState(!1),r=$.useRef(null),d=e==="image"?"image/*":void 0;async function c(m){if(!m)return;const y=Array.from(m);if(y.length===0)return;let k=null;const b=[];for(const N of y)try{const h=await i.mutateAsync({configId:s.id,file:N});k??=h.publicUrl}catch(h){b.push(`${N.name} (${h instanceof Error?h.message:"upload failed"})`)}await l.refetch(),b.length>0&&Q.error(b.length===y.length?`Upload failed: ${b.join("; ")}`:`Some files failed: ${b.join("; ")}`),k&&n(k)}function g(m){m.preventDefault(),a(!0)}function f(){a(!1)}function x(m){m.preventDefault(),a(!1),c(m.dataTransfer.files)}const p=(l.data?.pages??[]).flatMap(m=>m.items),j=p.filter(m=>e==="image"?ye(m.key):!0);return t.jsxs("div",{className:"flex flex-col gap-3 min-h-0 h-full",children:[t.jsxs("button",{type:"button",onClick:()=>r.current?.click(),onDragOver:g,onDragLeave:f,onDrop:x,className:de("rounded-xl border border-dashed border-border/60 p-6 flex flex-col items-center justify-center gap-2 text-center transition-colors",o&&"border-primary bg-primary/5",i.isPending&&"opacity-60 pointer-events-none"),children:[t.jsx(fe,{size:18,className:"text-muted-foreground"}),t.jsx("p",{className:"text-sm font-medium",children:i.isPending?"Uploading…":"Drop files here or click to upload"}),t.jsxs("p",{className:"text-xs text-muted-foreground",children:["Up to 100 MB."," ",e==="image"?"Images only (PNG, JPEG, WebP, GIF, SVG, AVIF).":"Common image, video, audio, and document types."]}),t.jsx("input",{ref:r,type:"file",accept:d,multiple:!0,className:"hidden",onChange:m=>{const y=m.target.files;m.target.value="",c(y)}})]}),l.isFetching&&!l.isFetchingNextPage?t.jsx("div",{className:"flex justify-end",children:t.jsx("span",{className:"text-xs text-muted-foreground",children:"Loading…"})}):null,t.jsxs("div",{className:"min-h-0 flex-1 overflow-y-auto pr-1",children:[j.length===0?e==="image"&&p.length>0?t.jsx(ut,{}):t.jsx(ft,{}):e==="image"?t.jsx(gt,{items:j,onSelect:n}):t.jsx(pt,{items:j,onSelect:n}),l.hasNextPage&&t.jsx("div",{className:"flex justify-center py-4",children:t.jsx(Y,{type:"button",variant:"outline",size:"sm",disabled:l.isFetchingNextPage,onClick:()=>l.fetchNextPage(),children:l.isFetchingNextPage?t.jsxs(t.Fragment,{children:[t.jsx(Ce,{size:14,className:"animate-spin"}),"Loading…"]}):"Load more"})})]})]})}function ft(){const s=w.c(1);let e;return s[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsxs("div",{className:"flex h-full min-h-40 flex-col items-center justify-center gap-2 py-8 text-center",children:[t.jsx("div",{className:"flex size-10 items-center justify-center rounded-full bg-muted",children:t.jsx(W,{size:18,className:"text-muted-foreground"})}),t.jsx("p",{className:"text-sm font-medium",children:"No files in this bucket yet"}),t.jsx("p",{className:"text-xs text-muted-foreground",children:"Drop a file above to get started."})]}),s[0]=e):e=s[0],e}function ut(){const s=w.c(1);let e;return s[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsxs("div",{className:"flex h-full min-h-40 flex-col items-center justify-center gap-2 py-8 text-center",children:[t.jsx("div",{className:"flex size-10 items-center justify-center rounded-full bg-muted",children:t.jsx(W,{size:18,className:"text-muted-foreground"})}),t.jsx("p",{className:"text-sm font-medium",children:"No images in this bucket yet"}),t.jsx("p",{className:"text-xs text-muted-foreground",children:"The bucket has other files, but none match common image formats."})]}),s[0]=e):e=s[0],e}function ye(s){return/\.(png|jpe?g|gif|webp|svg|avif|bmp)$/i.test(s)}function mt(s){const e=s.lastIndexOf(".");return e<0||e===s.length-1?"file":s.slice(e+1).toLowerCase()}function gt(s){const e=w.c(7),{items:n,onSelect:l}=s;let i;if(e[0]!==n||e[1]!==l){let a;e[3]!==l?(a=r=>t.jsx(ve,{item:r,variant:"image",onSelect:l},r.key),e[3]=l,e[4]=a):a=e[4],i=n.map(a),e[0]=n,e[1]=l,e[2]=i}else i=e[2];let o;return e[5]!==i?(o=t.jsx("div",{className:"grid grid-cols-2 sm:grid-cols-3 md:grid-cols-4 gap-3",children:i}),e[5]=i,e[6]=o):o=e[6],o}function pt(s){const e=w.c(7),{items:n,onSelect:l}=s;let i;if(e[0]!==n||e[1]!==l){let a;e[3]!==l?(a=r=>t.jsx("li",{children:t.jsx(ve,{item:r,variant:"row",onSelect:l})},r.key),e[3]=l,e[4]=a):a=e[4],i=n.map(a),e[0]=n,e[1]=l,e[2]=i}else i=e[2];let o;return e[5]!==i?(o=t.jsx("ul",{className:"divide-y divide-border/60 rounded-lg border border-border/60",children:i}),e[5]=i,e[6]=o):o=e[6],o}function ve(s){const e=w.c(58),{item:n,variant:l,onSelect:i}=s;let o;e[0]!==n.key?(o=mt(n.key),e[0]=n.key,e[1]=o):o=e[1];const a=o;if(l==="image"){let b;e[2]!==n.publicUrl||e[3]!==i?(b=()=>i(n.publicUrl),e[2]=n.publicUrl,e[3]=i,e[4]=b):b=e[4];let N;e[5]!==n.key||e[6]!==n.publicUrl?(N=t.jsx("img",{src:n.publicUrl,alt:n.key,loading:"lazy",className:"h-full w-full object-cover",onError:xt}),e[5]=n.key,e[6]=n.publicUrl,e[7]=N):N=e[7];let h;e[8]!==n.key||e[9]!==b||e[10]!==N?(h=t.jsx("button",{type:"button",onClick:b,className:"block h-full w-full transition hover:ring-2 hover:ring-primary",title:n.key,children:N}),e[8]=n.key,e[9]=b,e[10]=N,e[11]=h):h=e[11];let C;e[12]!==a?(C=t.jsx("span",{className:"pointer-events-none absolute left-1.5 top-1.5 rounded bg-background/80 px-1.5 py-0.5 text-[10px] font-medium uppercase text-foreground opacity-0 backdrop-blur-sm transition-opacity group-hover:opacity-100",children:a}),e[12]=a,e[13]=C):C=e[13];let S;e[14]!==n||e[15]!==i?(S=t.jsx("div",{className:"absolute right-1.5 top-1.5 opacity-0 transition-opacity group-hover:opacity-100",children:t.jsx(xe,{item:n,onSelect:i})}),e[14]=n,e[15]=i,e[16]=S):S=e[16];let I;e[17]!==n.key?(I=he(n.key),e[17]=n.key,e[18]=I):I=e[18];let _;e[19]!==I?(_=t.jsx("div",{className:"pointer-events-none absolute inset-x-0 bottom-0 bg-gradient-to-t from-black/70 to-transparent p-2 opacity-0 transition-opacity group-hover:opacity-100",children:t.jsx("p",{className:"truncate text-xs text-white",children:I})}),e[19]=I,e[20]=_):_=e[20];let P;return e[21]!==h||e[22]!==C||e[23]!==S||e[24]!==_?(P=t.jsxs("div",{className:"group relative aspect-square overflow-hidden rounded-lg border border-border/60 bg-muted",children:[h,C,S,_]}),e[21]=h,e[22]=C,e[23]=S,e[24]=_,e[25]=P):P=e[25],P}let r;e[26]!==n.publicUrl||e[27]!==i?(r=()=>i(n.publicUrl),e[26]=n.publicUrl,e[27]=i,e[28]=r):r=e[28];let d;e[29]!==n.key?(d=t.jsx("div",{className:"flex size-9 shrink-0 items-center justify-center rounded-md bg-muted",children:ye(n.key)?t.jsx(W,{size:16,className:"text-muted-foreground"}):t.jsx(ze,{size:16,className:"text-muted-foreground"})}),e[29]=n.key,e[30]=d):d=e[30];let c;e[31]!==n.key?(c=he(n.key),e[31]=n.key,e[32]=c):c=e[32];let g;e[33]!==c?(g=t.jsx("p",{className:"truncate text-sm font-medium",children:c}),e[33]=c,e[34]=g):g=e[34];let f;e[35]!==n.key?(f=t.jsx("p",{className:"truncate font-mono text-xs text-muted-foreground",children:n.key}),e[35]=n.key,e[36]=f):f=e[36];let x;e[37]!==g||e[38]!==f?(x=t.jsxs("div",{className:"min-w-0 flex-1",children:[g,f]}),e[37]=g,e[38]=f,e[39]=x):x=e[39];let u;e[40]!==a?(u=t.jsx("span",{className:"shrink-0 rounded bg-muted px-1.5 py-0.5 text-[10px] font-medium uppercase text-muted-foreground",children:a}),e[40]=a,e[41]=u):u=e[41];let p;e[42]!==n.size?(p=yt(n.size),e[42]=n.size,e[43]=p):p=e[43];let j;e[44]!==p?(j=t.jsx("span",{className:"shrink-0 text-xs text-muted-foreground",children:p}),e[44]=p,e[45]=j):j=e[45];let m;e[46]!==j||e[47]!==r||e[48]!==d||e[49]!==x||e[50]!==u?(m=t.jsxs("button",{type:"button",onClick:r,className:"flex min-w-0 flex-1 items-center gap-3 text-left",children:[d,x,u,j]}),e[46]=j,e[47]=r,e[48]=d,e[49]=x,e[50]=u,e[51]=m):m=e[51];let y;e[52]!==n||e[53]!==i?(y=t.jsx(xe,{item:n,onSelect:i}),e[52]=n,e[53]=i,e[54]=y):y=e[54];let k;return e[55]!==m||e[56]!==y?(k=t.jsxs("div",{className:"group flex items-center gap-3 px-3 py-2 transition hover:bg-muted/50",children:[m,y]}),e[55]=m,e[56]=y,e[57]=k):k=e[57],k}function xt(s){s.target.style.display="none"}function xe(s){const e=w.c(22),{item:n,onSelect:l}=s,[i,o]=$.useState(!1);let a;e[0]!==n.publicUrl?(a=async function(b){b.preventDefault(),b.stopPropagation();try{await navigator.clipboard.writeText(n.publicUrl),o(!0),window.setTimeout(()=>o(!1),1500)}catch{Q.error("Failed to copy URL")}},e[0]=n.publicUrl,e[1]=a):a=e[1];const r=a;let d;e[2]===Symbol.for("react.memo_cache_sentinel")?(d=t.jsx(Me,{asChild:!0,children:t.jsx(Y,{type:"button",variant:"ghost",size:"icon",className:"size-7 rounded-md bg-background/80 backdrop-blur-sm",onClick:jt,"aria-label":"Asset actions",children:t.jsx(De,{size:14})})}),e[2]=d):d=e[2];let c;e[3]!==n.publicUrl||e[4]!==l?(c=()=>l(n.publicUrl),e[3]=n.publicUrl,e[4]=l,e[5]=c):c=e[5];let g;e[6]===Symbol.for("react.memo_cache_sentinel")?(g=t.jsx(ge,{size:14}),e[6]=g):g=e[6];let f;e[7]!==c?(f=t.jsxs(ce,{onClick:c,children:[g,"Use this"]}),e[7]=c,e[8]=f):f=e[8];let x;e[9]!==i?(x=i?t.jsx(ge,{size:14}):t.jsx($e,{size:14}),e[9]=i,e[10]=x):x=e[10];const u=i?"Copied":"Copy URL";let p;e[11]!==r||e[12]!==x||e[13]!==u?(p=t.jsxs(ce,{onClick:r,children:[x,u]}),e[11]=r,e[12]=x,e[13]=u,e[14]=p):p=e[14];let j;e[15]===Symbol.for("react.memo_cache_sentinel")?(j=t.jsx(Fe,{size:14}),e[15]=j):j=e[15];let m;e[16]!==n.publicUrl?(m=t.jsx(ce,{asChild:!0,children:t.jsxs("a",{href:n.publicUrl,target:"_blank",rel:"noreferrer",onClick:ht,children:[j,"Open in new tab"]})}),e[16]=n.publicUrl,e[17]=m):m=e[17];let y;return e[18]!==m||e[19]!==f||e[20]!==p?(y=t.jsxs(Re,{children:[d,t.jsxs(Ge,{align:"end",onClick:bt,children:[f,p,m]})]}),e[18]=m,e[19]=f,e[20]=p,e[21]=y):y=e[21],y}function ht(s){return s.stopPropagation()}function bt(s){return s.stopPropagation()}function jt(s){return s.stopPropagation()}function he(s){const e=s.split("/");return e[e.length-1]??s}function yt(s){return s<1024?`${s} B`:s<1024*1024?`${(s/1024).toFixed(1)} KB`:`${(s/(1024*1024)).toFixed(1)} MB`}function vt(s){try{const e=new URL(s).pathname;return decodeURIComponent(e.split("/").pop()??s)}catch{return s.split("/").pop()??s}}function Nt(s){const e=s.lastIndexOf(".");return e<0||e===s.length-1?"":s.slice(e+1).toLowerCase()}const kt=new Set(["image/png","image/jpeg","image/gif","image/webp","image/svg+xml","image/avif"]);function Kt(s){const e=w.c(79),{schema:n,value:l,onChange:i,path:o,label:a}=s,r=et(l),[d,c]=$.useState(!1),[g,f]=$.useState(!1),[x,u]=$.useState(!1),[p,j]=$.useState(!1),m=r?vt(r):"",y=m?Nt(m):"",k=Ye(),b=je();let N;e[0]!==i||e[1]!==j||e[2]!==u?(N=function(v){u(!1),j(!1),i(v)},e[0]=i,e[1]=j,e[2]=u,e[3]=N):N=e[3];const h=N;let C;e[4]!==k.data?.configs?(C=function(){const v=k.data?.configs??[];if(v.length===1)return v[0].id;if(v.length===0)return null;const D=typeof window<"u"?window.localStorage.getItem(ue):null;return v.some(te=>te.id===D)?D:null},e[4]=k.data?.configs,e[5]=C):C=e[5];const S=C;let I;e[6]!==S||e[7]!==c||e[8]!==h||e[9]!==b?(I=async function(v){if(!v)return;const D=Array.from(v).filter(wt);if(D.length===0){Q.error("Only image files are accepted here.");return}const te=S();if(!te){c(!0);return}try{const ae=await b.mutateAsync({configId:te,file:D[0]});h(ae.publicUrl),D.length>1&&Q.info(`Uploaded ${D[0].name}; extra files were ignored (single-select field).`)}catch(ae){const me=ae;Q.error(me instanceof Error?me.message:"Upload failed")}},e[6]=S,e[7]=c,e[8]=h,e[9]=b,e[10]=I):I=e[10];const _=I;let P;e[11]!==f?(P=function(v){v.preventDefault(),v.dataTransfer.types.includes("Files")&&f(!0)},e[11]=f,e[12]=P):P=e[12];const se=P;let H;e[13]!==f?(H=function(v){v.currentTarget===v.target&&f(!1)},e[13]=f,e[14]=H):H=e[14];const ne=H;let X;e[15]!==_||e[16]!==f?(X=function(v){v.preventDefault(),f(!1),_(v.dataTransfer.files)},e[15]=_,e[16]=f,e[17]=X):X=e[17];const ie=X;let z;e[18]!==a||e[19]!==o?(z=t.jsx(Pe,{htmlFor:o,className:"text-muted-foreground",children:a}),e[18]=a,e[19]=o,e[20]=z):z=e[20];let F;e[21]!==n.description?(F=n.description&&t.jsx("p",{className:"text-xs leading-normal text-muted-foreground",children:n.description}),e[21]=n.description,e[22]=F):F=e[22];let T;e[23]!==z||e[24]!==F?(T=t.jsxs("div",{className:"min-w-0 space-y-0.5",children:[z,F]}),e[23]=z,e[24]=F,e[25]=T):T=e[25];const le=g&&"border-primary ring-2 ring-primary/30",re=b.isPending&&"pointer-events-none opacity-60";let E;e[26]!==le||e[27]!==re?(E=de("group relative w-full overflow-hidden rounded-xl border border-border/60 bg-muted/30 transition",le,re),e[26]=le,e[27]=re,e[28]=E):E=e[28];let L;e[29]!==y||e[30]!==m||e[31]!==p||e[32]!==x||e[33]!==a||e[34]!==j||e[35]!==u||e[36]!==c||e[37]!==r||e[38]!==b.isPending?(L=r?t.jsxs(t.Fragment,{children:[t.jsxs("div",{className:"relative h-40 w-full bg-[image:linear-gradient(45deg,rgba(0,0,0,0.04)_25%,transparent_25%,transparent_75%,rgba(0,0,0,0.04)_75%),linear-gradient(45deg,rgba(0,0,0,0.04)_25%,transparent_25%,transparent_75%,rgba(0,0,0,0.04)_75%)] bg-[position:0_0,8px_8px] [background-size:16px_16px]",children:[!p&&t.jsx("img",{src:r,alt:a,className:de("h-full w-full object-contain transition-opacity",!x&&"opacity-0"),onLoad:()=>u(!0),onError:()=>j(!0)},r),p&&t.jsxs("div",{className:"flex h-full w-full flex-col items-center justify-center gap-1 text-muted-foreground",children:[t.jsx(W,{size:20}),t.jsx("p",{className:"text-xs",children:"Preview unavailable"})]}),!x&&!p&&t.jsx("div",{className:"absolute inset-0 animate-pulse bg-muted/60"})]}),t.jsxs("div",{className:"flex items-center gap-2 border-t border-border/60 bg-background/50 px-3 py-2",children:[t.jsx("span",{className:"min-w-0 flex-1 truncate text-xs font-medium",children:m}),y&&t.jsx("span",{className:"shrink-0 rounded bg-muted px-1.5 py-0.5 text-[10px] font-medium uppercase text-muted-foreground",children:y})]})]}):t.jsxs("button",{type:"button",onClick:()=>c(!0),className:"flex h-40 w-full flex-col items-center justify-center gap-2 text-sm text-muted-foreground hover:bg-muted/60 hover:text-foreground",children:[t.jsx(W,{size:20}),t.jsx("span",{className:"text-sm font-medium",children:b.isPending?"Uploading…":"Drop an image or click to browse"}),t.jsx("span",{className:"text-xs text-muted-foreground",children:"PNG, JPEG, WebP, GIF, SVG, AVIF — up to 100 MB"})]}),e[29]=y,e[30]=m,e[31]=p,e[32]=x,e[33]=a,e[34]=j,e[35]=u,e[36]=c,e[37]=r,e[38]=b.isPending,e[39]=L):L=e[39];let O;e[40]!==g?(O=g&&t.jsx("div",{className:"pointer-events-none absolute inset-0 flex items-center justify-center bg-primary/10 backdrop-blur-[1px]",children:t.jsx("span",{className:"rounded-md bg-background px-3 py-1.5 text-xs font-medium shadow",children:"Drop to upload"})}),e[40]=g,e[41]=O):O=e[41];let A;e[42]!==ne||e[43]!==se||e[44]!==ie||e[45]!==E||e[46]!==L||e[47]!==O?(A=t.jsxs("div",{onDragOver:se,onDragLeave:ne,onDrop:ie,className:E,children:[L,O]}),e[42]=ne,e[43]=se,e[44]=ie,e[45]=E,e[46]=L,e[47]=O,e[48]=A):A=e[48];let M;e[49]!==h?(M=U=>h(U.target.value),e[49]=h,e[50]=M):M=e[50];let R;e[51]!==o||e[52]!==r||e[53]!==M?(R=t.jsx(_e,{id:o,type:"url",value:r,onChange:M,placeholder:"https://...",className:"h-9 min-w-0 flex-1"}),e[51]=o,e[52]=r,e[53]=M,e[54]=R):R=e[54];let G;e[55]!==c?(G=()=>c(!0),e[55]=c,e[56]=G):G=e[56];let Z;e[57]===Symbol.for("react.memo_cache_sentinel")?(Z=t.jsx(fe,{size:14}),e[57]=Z):Z=e[57];const oe=r?"Replace":"Browse";let B;e[58]!==G||e[59]!==oe?(B=t.jsxs(Y,{type:"button",variant:"outline",size:"sm",onClick:G,className:"h-9 shrink-0",children:[Z,oe]}),e[58]=G,e[59]=oe,e[60]=B):B=e[60];let V;e[61]!==h||e[62]!==r?(V=r&&t.jsx(Y,{type:"button",variant:"ghost",size:"sm",onClick:()=>h(""),className:"h-9 shrink-0","aria-label":"Remove image",children:t.jsx(Se,{size:14})}),e[61]=h,e[62]=r,e[63]=V):V=e[63];let K;e[64]!==R||e[65]!==B||e[66]!==V?(K=t.jsxs("div",{className:"flex w-full min-w-0 items-center gap-2",children:[R,B,V]}),e[64]=R,e[65]=B,e[66]=V,e[67]=K):K=e[67];let q;e[68]!==h?(q=U=>h(U),e[68]=h,e[69]=q):q=e[69];let J;e[70]!==d||e[71]!==c||e[72]!==q?(J=t.jsx(it,{open:d,onOpenChange:c,mode:"image",onSelect:q}),e[70]=d,e[71]=c,e[72]=q,e[73]=J):J=e[73];let ee;return e[74]!==A||e[75]!==K||e[76]!==J||e[77]!==T?(ee=t.jsxs("div",{className:"grid w-full min-w-0 grid-cols-[minmax(0,1fr)] gap-2",children:[T,A,K,J]}),e[74]=A,e[75]=K,e[76]=J,e[77]=T,e[78]=ee):ee=e[78],ee}function wt(s){return kt.has(s.type||"")}export{it as F,Kt as I,ue as L,et as e,je as u};
@@ -1 +1 @@
1
- import{e as k,j as o,p as T,r as N,O as D}from"./index-B9kRhzg7.js";import{u as z,S as E,a as I,b as L}from"./sidebar-BMIDAt6t.js";import{T as M,a as O,b as A,u as P}from"./tooltip-Cx8u2hvs.js";import{S as $,a as W,b as B}from"./shell-route-loading-DqEXsH0r.js";import{u as X,C as H}from"./chat-context-CL-ll6R6.js";import{T as F}from"./tab-id-DiLpeikj.js";import{i as q}from"./Monitor01-B0FKK9nk.js";import{v as G,C as K}from"./connect-desktop-dialog-CAgFYUmf.js";import{T as Y,a as b}from"./toolbar-CuMC4awt.js";import{S as U,M as J}from"./shell-controls-yn92xA7D.js";import"./LayoutLeft-BO92HMhM.js";import"./sheet-BLkB41eQ.js";import"./X-COnjMnsv.js";import"./useRouterState-BRj2kxuq.js";import"./ZoomOut-B5B07_-g.js";import"./skeleton-KI9W-P-f.js";import"./popover-Dinj8RAt.js";import"./drawer-NwIwuvOD.js";import"./SearchMd-CxJnyPJ2.js";import"./Star01-Cu6cUuhf.js";import"./Plus-BnGx63GX.js";import"./constants-BFQrPD6r.js";import"./use-virtual-mcp-CtYRrEgz.js";import"./use-collections-C1EEoGdl.js";import"./use-create-virtual-mcp-UfIRObXS.js";import"./use-navigate-to-agent-C81Y1E7k.js";import"./github-repo-picker-BXy4amYZ.js";import"./use-connection-DkHV4tpA.js";import"./dialog-J9xRnRHX.js";import"./RefreshCcw01-Dk9AOo-m.js";import"./collection-search-CljcPIbT.js";import"./checkbox-4DJ-sElS.js";import"./Check-DCJCCJt5.js";import"./agent-icon-DFJgaXFK.js";import"./AlertCircle-DQ3zaMns.js";import"./Tool01-DRibBi0T.js";import"./SwitchHorizontal01-BjgMZfW7.js";import"./XCircle-BvIhN4E7.js";import"./ArrowUpRight-UT01ancE.js";import"./ZapSquare-C79zBXJj.js";import"./Users03-DhXF_0sH.js";import"./CheckCircle-CN8csJmd.js";import"./ChevronDown-vntP1LF0.js";import"./ChevronLeft-_4tt3JbP.js";import"./ChevronRight-BD7fiLv7.js";import"./ChevronUp-B9NZzlEX.js";import"./DotsVertical-DDPFnnRS.js";import"./Container-DlDQbtuJ.js";import"./Eye-ogI2y4CN.js";import"./Globe01-C2fKyC2-.js";import"./FilterLines-DpUfIC-u.js";import"./Palette-OtFJ1ywH.js";import"./HardDrive-Ik-OtFON.js";import"./Stars02-Bo6vryYW.js";import"./Key01-CmprkySl.js";import"./LinkExternal01-9W209kLr.js";import"./Sun-Bg1tFzcn.js";import"./Play-B9TsjtCB.js";import"./Settings02-PSRUEgfS.js";import"./Shield01-Do71Dyqk.js";import"./Stars01-BuMp0jeZ.js";import"./Trash01-DfuJtop_.js";import"./Upload01-DGWS8Icx.js";import"./User01-B1RcIkcM.js";import"./Users01-CyxI-ZiC.js";import"./XClose-CXacF9IM.js";import"./Zap-BM6RWRPw.js";import"./use-mcp-tools-BS9dyBS-.js";import"./extract-connection-data-J0nLi0pB.js";import"./generate-id-C8OHZs1-.js";import"./collections-C8UGR0dQ.js";import"./shell-layout-v69WfJwF.js";import"./avatar-CuZPsvd7.js";import"./required-auth-layout-DQ_j0OWf.js";import"./use-organization-settings-BDlR4IeW.js";import"./use-org-sso-B96bQNMI.js";import"./alert-dialog-BpOf9MAK.js";import"./form-C4TJnG5K.js";import"./label-dlG4_xKf.js";import"./input-DCOoktZX.js";import"./spinner-1Hxy4oL5.js";import"./index-DgQteD84.js";import"./sortable.esm-tovEx4aa.js";import"./connection-slug-eyAPH6o3.js";import"./connection-card-Dmrkhocz.js";import"./use-registry-connections-BCrdHAv1.js";import"./useInfiniteQuery-B2j87XPZ.js";import"./infiniteQueryObserver-Xb1xysnw.js";import"./card-DsraaOS_.js";import"./integration-icon-D0rRtQFH.js";import"./collection-tabs-BgZPPjBK.js";import"./badge-BCXaZ3jr.js";import"./select-CVZQAcm7.js";import"./textarea-CaPEW-IU.js";import"./connection-form-helpers-BL61O5Zc.js";import"./use-infinite-scroll-DV-4RP03.js";import"./useSuspenseInfiniteQuery-BbIHskrR.js";import"./use-ai-providers-CmWP-lNT.js";import"./command-Cwxrfu8T.js";import"./index-X8qPybJt.js";import"./use-org-auth-client-DVt08ImK.js";import"./hover-card-CzsSQjRq.js";import"./task-status-nPHS0i2v.js";import"./format-time-Cy7tTmZp.js";import"./differenceInSeconds-NQ4PDo0z.js";import"./unwrap-tool-result-BYXdCQMg.js";import"./decopilot-sse-pool-DIAcxt2i.js";import"./create-sse-subscription-BS5983N4.js";function Q(e){const t=k.c(5),{onPointerDown:r,onDoubleClick:d}=e,{state:f,isMobile:u}=z();if(u||f==="collapsed")return null;let s,n;t[0]===Symbol.for("react.memo_cache_sentinel")?(s={left:"var(--sidebar-width)"},n=o.jsx("span",{className:"pointer-events-none absolute inset-y-0 left-1/2 w-px -translate-x-1/2 bg-transparent transition-colors duration-150 group-hover/resize:bg-border group-active/resize:bg-border"}),t[0]=s,t[1]=n):(s=t[0],n=t[1]);let i;return t[2]!==d||t[3]!==r?(i=o.jsx("div",{role:"separator","aria-orientation":"vertical","aria-label":"Resize sidebar",title:"Drag to resize, double-click to reset",onPointerDown:r,onDoubleClick:d,className:"group/resize absolute top-0 z-20 h-full w-2 -translate-x-1/2 cursor-col-resize",style:s,children:n}),t[2]=d,t[3]=r,t[4]=i):i=t[4],i}const R=240,V=400,Z="sidebar.width";function _(e){return Math.max(R,Math.min(V,e))}function ee(){const e=k.c(11),[t,r]=T(Z,te),d=N.useRef(null);let f;e[0]!==r||e[1]!==t?(f=a=>{a.preventDefault();const m=a.clientX,p=_(t),c=d.current??(typeof document<"u"?document.querySelector('[data-slot="sidebar-wrapper"]'):null),h=c?Array.from(c.querySelectorAll('[data-slot="sidebar"], [data-slot="sidebar-container"]')):[];for(const x of h)x.style.transition="none";const j=x=>{const g=_(p+(x.clientX-m));c?.style.setProperty("--sidebar-width",`${g}px`)},S=x=>{const g=_(p+(x.clientX-m));r(g);for(const v of h)v.style.transition="";window.removeEventListener("pointermove",j),window.removeEventListener("pointerup",S),document.body.style.userSelect="",document.body.style.cursor=""};document.body.style.userSelect="none",document.body.style.cursor="col-resize",window.addEventListener("pointermove",j),window.addEventListener("pointerup",S)},e[0]=r,e[1]=t,e[2]=f):f=e[2];const u=f;let s;e[3]!==r?(s=()=>{r(R)},e[3]=r,e[4]=s):s=e[4];const n=s;let i;e[5]!==t?(i=_(t),e[5]=t,e[6]=i):i=e[6];let l;return e[7]!==u||e[8]!==n||e[9]!==i?(l={width:i,wrapperRef:d,onStartResize:u,resetWidth:n},e[7]=u,e[8]=n,e[9]=i,e[10]=l):l=e[10],l}function te(e){return typeof e=="number"?_(e):R}function oe(){const e=k.c(22),t=X(),[r,d]=N.useState(!1);let f;if(e[0]!==t.capabilities||e[1]!==t.hostname||e[2]!==t.machineId||e[3]!==t.online){const j=G(t.capabilities);f=t.online?o.jsxs("div",{className:"flex flex-col gap-0.5 text-xs",children:[o.jsx("span",{className:"font-medium",children:t.hostname??t.machineId??"Desktop linked"}),o.jsx("span",{className:"text-muted-foreground",children:j.length>0?`Available: ${j.join(", ")}`:"No CLI agents detected"})]}):o.jsx("span",{className:"text-xs",children:"Desktop disconnected"}),e[0]=t.capabilities,e[1]=t.hostname,e[2]=t.machineId,e[3]=t.online,e[4]=f}else f=e[4];const u=f;let s;e[5]===Symbol.for("react.memo_cache_sentinel")?(s=()=>d(!0),e[5]=s):s=e[5];const n=t.online?"Desktop linked":"Connect your desktop";let i;e[6]===Symbol.for("react.memo_cache_sentinel")?(i=o.jsx(q,{size:16}),e[6]=i):i=e[6];let l;e[7]!==t.online?(l=t.online&&o.jsx("span",{className:"absolute top-1 right-1 size-2 rounded-full bg-success ring-2 ring-background animate-pulse"}),e[7]=t.online,e[8]=l):l=e[8];let a;e[9]!==n||e[10]!==l?(a=o.jsx(M,{asChild:!0,children:o.jsxs(Y,{onClick:s,"aria-label":n,children:[i,l]})}),e[9]=n,e[10]=l,e[11]=a):a=e[11];let m;e[12]!==u?(m=o.jsx(O,{side:"bottom",children:u}),e[12]=u,e[13]=m):m=e[13];let p;e[14]!==a||e[15]!==m?(p=o.jsxs(A,{children:[a,m]}),e[14]=a,e[15]=m,e[16]=p):p=e[16];let c;e[17]!==r?(c=o.jsx(K,{open:r,onOpenChange:d}),e[17]=r,e[18]=c):c=e[18];let h;return e[19]!==p||e[20]!==c?(h=o.jsxs(o.Fragment,{children:[p,c]}),e[19]=p,e[20]=c,e[21]=h):h=e[21],h}const ie="sidebar.open";function re(){const e=k.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=o.jsx(B,{}),e[0]=t):t=e[0],t}function no(){const e=k.c(26),t=P(),[r,d]=T(ie,!1),{width:f,wrapperRef:u,onStartResize:s,resetWidth:n}=ee();let i,l;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=o.jsx(b.LogoLink,{}),l=o.jsx(U,{}),e[0]=i,e[1]=l):(i=e[0],l=e[1]);let a,m;e[2]===Symbol.for("react.memo_cache_sentinel")?(a=o.jsxs(b.LeftColumn,{children:[i,l,o.jsx("span",{className:"hidden md:contents",children:o.jsx(b.Nav,{})}),o.jsx(b.TogglesSlot,{}),o.jsx(oe,{})]}),m=o.jsx(b.CenterSlot,{}),e[2]=a,e[3]=m):(a=e[2],m=e[3]);let p;e[4]===Symbol.for("react.memo_cache_sentinel")?(p=o.jsxs(b.Header,{children:[a,m,o.jsxs(b.RightColumn,{children:[o.jsx("div",{className:"min-w-0 flex-1 overflow-x-auto [scrollbar-width:none] flex justify-end",children:o.jsx(b.TabsSlot,{})}),o.jsx(b.RightSlot,{})]})]}),e[4]=p):p=e[4];const c=`${f}px`;let h;e[5]!==c?(h={"--sidebar-width":c,"--sidebar-width-icon":"3.5rem"},e[5]=c,e[6]=h):h=e[6];const j=h;let S;e[7]!==t||e[8]!==s||e[9]!==n?(S=!t&&o.jsxs(o.Fragment,{children:[o.jsx($,{}),o.jsx(Q,{onPointerDown:s,onDoubleClick:n})]}),e[7]=t,e[8]=s,e[9]=n,e[10]=S):S=e[10];let x;e[11]===Symbol.for("react.memo_cache_sentinel")?(x={background:"transparent",containerType:"inline-size"},e[11]=x):x=e[11];let g;e[12]===Symbol.for("react.memo_cache_sentinel")?(g=o.jsx(E,{className:"flex flex-col",style:x,children:o.jsx("div",{className:"flex flex-col h-full min-h-0",children:o.jsx("div",{className:"relative flex-1 min-h-0 flex flex-row",children:o.jsx(N.Suspense,{fallback:o.jsx(re,{}),children:o.jsx(D,{})})})})}),e[12]=g):g=e[12];let v;e[13]!==j||e[14]!==S||e[15]!==u?(v=o.jsxs(I,{ref:u,className:"flex-1 bg-sidebar relative min-h-0",style:j,children:[S,g]}),e[13]=j,e[14]=S,e[15]=u,e[16]=v):v=e[16];let y;e[17]!==t?(y=t&&o.jsx(J,{renderSidebar:se}),e[17]=t,e[18]=y):y=e[18];let w;e[19]!==v||e[20]!==y?(w=o.jsx(H,{children:o.jsxs("div",{className:"app-shell-root flex flex-col h-dvh overflow-hidden",children:[p,v,y]})}),e[19]=v,e[20]=y,e[21]=w):w=e[21];let C;return e[22]!==d||e[23]!==r||e[24]!==w?(C=o.jsx(F,{children:o.jsx(b.Provider,{children:o.jsx(L,{open:r,onOpenChange:d,children:w})})}),e[22]=d,e[23]=r,e[24]=w,e[25]=C):C=e[25],C}function se(e){const{onClose:t}=e;return o.jsx("div",{className:"flex h-full",children:o.jsx("div",{className:"w-full bg-sidebar flex flex-col overflow-y-auto group/sidebar","data-state":"expanded",children:o.jsx(W,{onClose:t})})})}export{no as default};
1
+ import{e as k,j as o,p as T,r as N,O as D}from"./index-8Av7_XG5.js";import{u as z,S as E,a as I,b as L}from"./sidebar-BTAYcbpn.js";import{T as M,a as O,b as A,u as P}from"./tooltip-B9p8ywB_.js";import{S as $,a as W,b as B}from"./shell-route-loading-BMvdQN97.js";import{u as X,C as H}from"./chat-context-DXMK9LpM.js";import{T as F}from"./tab-id-Cj2zAp8p.js";import{i as q}from"./Monitor01-RdLthi4L.js";import{v as G,C as K}from"./connect-desktop-dialog-D0cwbi62.js";import{T as Y,a as b}from"./toolbar-BkMHRO8B.js";import{S as U,M as J}from"./shell-controls-CiR1mOgQ.js";import"./LayoutLeft-CAachN7j.js";import"./sheet-HD1tdtUP.js";import"./X-D5DAti-0.js";import"./useRouterState-BLC1S9ll.js";import"./ZoomOut-CIHaUyEl.js";import"./skeleton-KPs8aExG.js";import"./popover-CusBDsw3.js";import"./drawer-DBoqm7Ga.js";import"./SearchMd-Dt4Aj6N4.js";import"./Star01-DWr_psxV.js";import"./Plus-DINfOuqC.js";import"./constants-DeFtLUND.js";import"./use-virtual-mcp-C_vD2kKw.js";import"./use-collections-CMMaRmVG.js";import"./use-create-virtual-mcp-7QQxHiI4.js";import"./use-navigate-to-agent-C3AzTy7G.js";import"./github-repo-picker-CFHmzbdo.js";import"./use-connection-C2Ef-EqP.js";import"./dialog-BDoa-Aig.js";import"./RefreshCcw01-DSZXx3HQ.js";import"./collection-search-CIGzMvXg.js";import"./checkbox-CDeLVmoz.js";import"./Check-D-2DMeXR.js";import"./agent-icon-VIqap9Jf.js";import"./AlertCircle-Ctbek2zl.js";import"./Tool01-Co9IzxOX.js";import"./SwitchHorizontal01-CdSYnpvh.js";import"./XCircle-BjeFLJxj.js";import"./ArrowUpRight-CGlPrRsR.js";import"./ZapSquare-By7Cv3Wp.js";import"./Users03-mgRYViRT.js";import"./CheckCircle-CPLY3iX-.js";import"./ChevronDown-DUb-OAcF.js";import"./ChevronLeft-IUSMXc7n.js";import"./ChevronRight-C6_Bb1P7.js";import"./ChevronUp-mT0kmu5O.js";import"./DotsVertical-CYMPhMIv.js";import"./Container-V3OuMECL.js";import"./Eye-DLKlw-42.js";import"./Globe01-BSqLqa8H.js";import"./FilterLines-B2lLGnWS.js";import"./Palette-D1rjO3C7.js";import"./HardDrive-BFG0b6vP.js";import"./Stars02-7S-x4jsE.js";import"./Key01-DeIJhm73.js";import"./LinkExternal01-C7Ulot5I.js";import"./Sun-C0yimusT.js";import"./Play-CL1Mgiwf.js";import"./Settings02-COHAF-aj.js";import"./Shield01-Ef5O0H91.js";import"./Stars01-CTAt_kJn.js";import"./Trash01-m4F91Gbm.js";import"./Upload01-BWuva6Fs.js";import"./User01-BQ6QP8OL.js";import"./Users01-ByzlIQ3F.js";import"./XClose-s3WJPw3-.js";import"./Zap-Z3n8EP6c.js";import"./use-mcp-tools-C8LW1vg1.js";import"./extract-connection-data-C73XSXJg.js";import"./generate-id-DwXNdT-H.js";import"./collections-DsvWgjkq.js";import"./shell-layout-D1gXYOI4.js";import"./avatar-B5XGLu28.js";import"./required-auth-layout-CLPqu2hV.js";import"./use-organization-settings-B6tWOwuA.js";import"./use-org-sso-BB-vyF4c.js";import"./alert-dialog-Ci1rMRpl.js";import"./form-CEHwzUIx.js";import"./label-D5ze4fbW.js";import"./input-CFgdCIf-.js";import"./spinner-CWHpDgnL.js";import"./index-D2E_r2Ga.js";import"./sortable.esm-k9dnaUc0.js";import"./connection-slug-eyAPH6o3.js";import"./connection-card-Js2GKnMD.js";import"./use-registry-connections-DIBKm4oO.js";import"./useInfiniteQuery-CQ_UxVw9.js";import"./infiniteQueryObserver-BPAoXqhZ.js";import"./card-Bs_ZETWd.js";import"./integration-icon-ByZrCdpe.js";import"./collection-tabs-Cl0Sce7d.js";import"./badge-BiVWMQaC.js";import"./select-Y4AHPww8.js";import"./textarea-Bw4v_xfm.js";import"./connection-form-helpers-Dkeln3L-.js";import"./use-infinite-scroll-BaBllFvG.js";import"./useSuspenseInfiniteQuery-XoWOrVYw.js";import"./use-ai-providers-iJF3uFpo.js";import"./command-nIpjgY_C.js";import"./index-B3HtVn_3.js";import"./use-org-auth-client-BQe59WMu.js";import"./hover-card-CZKyvEKV.js";import"./task-status-Bq8PHYFh.js";import"./format-time-Cy7tTmZp.js";import"./differenceInSeconds-NQ4PDo0z.js";import"./unwrap-tool-result-BYXdCQMg.js";import"./decopilot-sse-pool-xYuzxJCG.js";import"./create-sse-subscription-BS5983N4.js";function Q(e){const t=k.c(5),{onPointerDown:r,onDoubleClick:d}=e,{state:f,isMobile:u}=z();if(u||f==="collapsed")return null;let s,n;t[0]===Symbol.for("react.memo_cache_sentinel")?(s={left:"var(--sidebar-width)"},n=o.jsx("span",{className:"pointer-events-none absolute inset-y-0 left-1/2 w-px -translate-x-1/2 bg-transparent transition-colors duration-150 group-hover/resize:bg-border group-active/resize:bg-border"}),t[0]=s,t[1]=n):(s=t[0],n=t[1]);let i;return t[2]!==d||t[3]!==r?(i=o.jsx("div",{role:"separator","aria-orientation":"vertical","aria-label":"Resize sidebar",title:"Drag to resize, double-click to reset",onPointerDown:r,onDoubleClick:d,className:"group/resize absolute top-0 z-20 h-full w-2 -translate-x-1/2 cursor-col-resize",style:s,children:n}),t[2]=d,t[3]=r,t[4]=i):i=t[4],i}const R=240,V=400,Z="sidebar.width";function _(e){return Math.max(R,Math.min(V,e))}function ee(){const e=k.c(11),[t,r]=T(Z,te),d=N.useRef(null);let f;e[0]!==r||e[1]!==t?(f=a=>{a.preventDefault();const m=a.clientX,p=_(t),c=d.current??(typeof document<"u"?document.querySelector('[data-slot="sidebar-wrapper"]'):null),h=c?Array.from(c.querySelectorAll('[data-slot="sidebar"], [data-slot="sidebar-container"]')):[];for(const x of h)x.style.transition="none";const j=x=>{const g=_(p+(x.clientX-m));c?.style.setProperty("--sidebar-width",`${g}px`)},S=x=>{const g=_(p+(x.clientX-m));r(g);for(const v of h)v.style.transition="";window.removeEventListener("pointermove",j),window.removeEventListener("pointerup",S),document.body.style.userSelect="",document.body.style.cursor=""};document.body.style.userSelect="none",document.body.style.cursor="col-resize",window.addEventListener("pointermove",j),window.addEventListener("pointerup",S)},e[0]=r,e[1]=t,e[2]=f):f=e[2];const u=f;let s;e[3]!==r?(s=()=>{r(R)},e[3]=r,e[4]=s):s=e[4];const n=s;let i;e[5]!==t?(i=_(t),e[5]=t,e[6]=i):i=e[6];let l;return e[7]!==u||e[8]!==n||e[9]!==i?(l={width:i,wrapperRef:d,onStartResize:u,resetWidth:n},e[7]=u,e[8]=n,e[9]=i,e[10]=l):l=e[10],l}function te(e){return typeof e=="number"?_(e):R}function oe(){const e=k.c(22),t=X(),[r,d]=N.useState(!1);let f;if(e[0]!==t.capabilities||e[1]!==t.hostname||e[2]!==t.machineId||e[3]!==t.online){const j=G(t.capabilities);f=t.online?o.jsxs("div",{className:"flex flex-col gap-0.5 text-xs",children:[o.jsx("span",{className:"font-medium",children:t.hostname??t.machineId??"Desktop linked"}),o.jsx("span",{className:"text-muted-foreground",children:j.length>0?`Available: ${j.join(", ")}`:"No CLI agents detected"})]}):o.jsx("span",{className:"text-xs",children:"Desktop disconnected"}),e[0]=t.capabilities,e[1]=t.hostname,e[2]=t.machineId,e[3]=t.online,e[4]=f}else f=e[4];const u=f;let s;e[5]===Symbol.for("react.memo_cache_sentinel")?(s=()=>d(!0),e[5]=s):s=e[5];const n=t.online?"Desktop linked":"Connect your desktop";let i;e[6]===Symbol.for("react.memo_cache_sentinel")?(i=o.jsx(q,{size:16}),e[6]=i):i=e[6];let l;e[7]!==t.online?(l=t.online&&o.jsx("span",{className:"absolute top-1 right-1 size-2 rounded-full bg-success ring-2 ring-background animate-pulse"}),e[7]=t.online,e[8]=l):l=e[8];let a;e[9]!==n||e[10]!==l?(a=o.jsx(M,{asChild:!0,children:o.jsxs(Y,{onClick:s,"aria-label":n,children:[i,l]})}),e[9]=n,e[10]=l,e[11]=a):a=e[11];let m;e[12]!==u?(m=o.jsx(O,{side:"bottom",children:u}),e[12]=u,e[13]=m):m=e[13];let p;e[14]!==a||e[15]!==m?(p=o.jsxs(A,{children:[a,m]}),e[14]=a,e[15]=m,e[16]=p):p=e[16];let c;e[17]!==r?(c=o.jsx(K,{open:r,onOpenChange:d}),e[17]=r,e[18]=c):c=e[18];let h;return e[19]!==p||e[20]!==c?(h=o.jsxs(o.Fragment,{children:[p,c]}),e[19]=p,e[20]=c,e[21]=h):h=e[21],h}const ie="sidebar.open";function re(){const e=k.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=o.jsx(B,{}),e[0]=t):t=e[0],t}function no(){const e=k.c(26),t=P(),[r,d]=T(ie,!1),{width:f,wrapperRef:u,onStartResize:s,resetWidth:n}=ee();let i,l;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=o.jsx(b.LogoLink,{}),l=o.jsx(U,{}),e[0]=i,e[1]=l):(i=e[0],l=e[1]);let a,m;e[2]===Symbol.for("react.memo_cache_sentinel")?(a=o.jsxs(b.LeftColumn,{children:[i,l,o.jsx("span",{className:"hidden md:contents",children:o.jsx(b.Nav,{})}),o.jsx(b.TogglesSlot,{}),o.jsx(oe,{})]}),m=o.jsx(b.CenterSlot,{}),e[2]=a,e[3]=m):(a=e[2],m=e[3]);let p;e[4]===Symbol.for("react.memo_cache_sentinel")?(p=o.jsxs(b.Header,{children:[a,m,o.jsxs(b.RightColumn,{children:[o.jsx("div",{className:"min-w-0 flex-1 overflow-x-auto [scrollbar-width:none] flex justify-end",children:o.jsx(b.TabsSlot,{})}),o.jsx(b.RightSlot,{})]})]}),e[4]=p):p=e[4];const c=`${f}px`;let h;e[5]!==c?(h={"--sidebar-width":c,"--sidebar-width-icon":"3.5rem"},e[5]=c,e[6]=h):h=e[6];const j=h;let S;e[7]!==t||e[8]!==s||e[9]!==n?(S=!t&&o.jsxs(o.Fragment,{children:[o.jsx($,{}),o.jsx(Q,{onPointerDown:s,onDoubleClick:n})]}),e[7]=t,e[8]=s,e[9]=n,e[10]=S):S=e[10];let x;e[11]===Symbol.for("react.memo_cache_sentinel")?(x={background:"transparent",containerType:"inline-size"},e[11]=x):x=e[11];let g;e[12]===Symbol.for("react.memo_cache_sentinel")?(g=o.jsx(E,{className:"flex flex-col",style:x,children:o.jsx("div",{className:"flex flex-col h-full min-h-0",children:o.jsx("div",{className:"relative flex-1 min-h-0 flex flex-row",children:o.jsx(N.Suspense,{fallback:o.jsx(re,{}),children:o.jsx(D,{})})})})}),e[12]=g):g=e[12];let v;e[13]!==j||e[14]!==S||e[15]!==u?(v=o.jsxs(I,{ref:u,className:"flex-1 bg-sidebar relative min-h-0",style:j,children:[S,g]}),e[13]=j,e[14]=S,e[15]=u,e[16]=v):v=e[16];let y;e[17]!==t?(y=t&&o.jsx(J,{renderSidebar:se}),e[17]=t,e[18]=y):y=e[18];let w;e[19]!==v||e[20]!==y?(w=o.jsx(H,{children:o.jsxs("div",{className:"app-shell-root flex flex-col h-dvh overflow-hidden",children:[p,v,y]})}),e[19]=v,e[20]=y,e[21]=w):w=e[21];let C;return e[22]!==d||e[23]!==r||e[24]!==w?(C=o.jsx(F,{children:o.jsx(b.Provider,{children:o.jsx(L,{open:r,onOpenChange:d,children:w})})}),e[22]=d,e[23]=r,e[24]=w,e[25]=C):C=e[25],C}function se(e){const{onClose:t}=e;return o.jsx("div",{className:"flex h-full",children:o.jsx("div",{className:"w-full bg-sidebar flex flex-col overflow-y-auto group/sidebar","data-state":"expanded",children:o.jsx(W,{onClose:t})})})}export{no as default};
@@ -1,4 +1,4 @@
1
- import{dW as se,e as I,j as o,B as te,l as Yt,b1 as We,dX as Gs,r as X,q as oe,c as $,g as Qs,F as Zt,dY as Nt,dZ as es,o as Ys,v as Zs,d_ as en,d$ as tn}from"./index-B9kRhzg7.js";import{D as sn,F as nn,B as on}from"./index-CtCZ2lVU.js";import{h as De,i as rn,u as ae}from"./constants-BFQrPD6r.js";import{a as ts}from"./use-virtual-mcp-CtYRrEgz.js";import{M as Oe}from"./monaco-editor-C03OGypq.js";import{b as ln,R as zt,a as cn}from"./resizable-CEMGS5N9.js";import{B as le}from"./badge-BCXaZ3jr.js";import{b as xt,d as ht,c as Ze,a as gt,S as bt}from"./select-CVZQAcm7.js";import{S as et}from"./spinner-1Hxy4oL5.js";import{V as an}from"./view-mode-toggle-DbMrI7Rd.js";import{ag as un,o as dn,i as fn,x as ss,ah as mn,a1 as pn,r as xn,ai as ns,a7 as hn,L as os,aj as gn,ak as bn,a3 as ft,al as jn}from"./agent-icon-DFJgaXFK.js";import{i as rs}from"./Play-B9TsjtCB.js";import{b as Sn,a as yn,V as Ge}from"./layout-CqY1dIbQ.js";import{c as is,b as ls,T as cs,a as as}from"./tooltip-Cx8u2hvs.js";import{u as wn,a as vn}from"./use-connection-DkHV4tpA.js";import{u as kt,d as It,b as us}from"./use-mcp-tools-BS9dyBS-.js";import{b as Nn,c as kn,e as In,d as _n,a as Cn,D as Tn}from"./dialog-J9xRnRHX.js";import"./index-2TKWj64n.js";import{N as En,m as $n,n as On,o as Ke,P as Mn,i as Rn,R as Ln,u as zn,p as Wn,e as Wt,d as An,q as Pn,S as Dn}from"./scroll-area-DSB3avJ3.js";import{S as Fn}from"./index-jPAWrqoL.js";import{H as Vn,a as qn,b as Hn}from"./hover-card-CzsSQjRq.js";import{D as ds,a as fs,b as ms,c as Qe}from"./dropdown-menu-Do65ajnt.js";import{s as Un}from"./Plus-BnGx63GX.js";import{b as ps}from"./Tool01-DRibBi0T.js";import{i as Fe}from"./Check-DCJCCJt5.js";import{s as _t}from"./XClose-CXacF9IM.js";import{I as Ct}from"./integration-icon-D0rRtQFH.js";import{A as Kn,c as Bn,a as Xn,b as Jn}from"./accordion-BelQbjLG.js";import"./index-DgQteD84.js";import{i as xs}from"./X-COnjMnsv.js";import{u as hs,a as Gn}from"./use-collections-C1EEoGdl.js";import{E as gs}from"./empty-state-Dl_snts0.js";import{c as Qn}from"./create-sse-subscription-BS5983N4.js";import{I as At}from"./input-DCOoktZX.js";const bs=se("Box",[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]]);const js=se("Braces",[["path",{d:"M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5c0 1.1.9 2 2 2h1",key:"ezmyqa"}],["path",{d:"M16 21h1a2 2 0 0 0 2-2v-5c0-1.1.9-2 2-2a2 2 0 0 1-2-2V5a2 2 0 0 0-2-2h-1",key:"e1hn23"}]]);const tt=se("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);const st=se("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);const Yn=se("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);const Ss=se("Code",[["polyline",{points:"16 18 22 12 16 6",key:"z7tu5w"}],["polyline",{points:"8 6 2 12 8 18",key:"1eg1df"}]]);const Zn=se("Copy",[["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"}]]);const ys=se("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);const ws=se("File",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}]]);const vs=se("Hash",[["line",{x1:"4",x2:"20",y1:"9",y2:"9",key:"4lhtct"}],["line",{x1:"4",x2:"20",y1:"15",y2:"15",key:"vyu0kd"}],["line",{x1:"10",x2:"8",y1:"3",y2:"21",key:"1ggp8o"}],["line",{x1:"16",x2:"14",y1:"3",y2:"21",key:"weycgp"}]]);const eo=se("OctagonAlert",[["path",{d:"M12 16h.01",key:"1drbdi"}],["path",{d:"M12 8v4",key:"1got3b"}],["path",{d:"M15.312 2a2 2 0 0 1 1.414.586l4.688 4.688A2 2 0 0 1 22 8.688v6.624a2 2 0 0 1-.586 1.414l-4.688 4.688a2 2 0 0 1-1.414.586H8.688a2 2 0 0 1-1.414-.586l-4.688-4.688A2 2 0 0 1 2 15.312V8.688a2 2 0 0 1 .586-1.414l4.688-4.688A2 2 0 0 1 8.688 2z",key:"1fd625"}]]);const Ns=se("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);const ks=se("SquareCheckBig",[["path",{d:"M21 10.5V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h12.5",key:"1uzm8b"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);const to=se("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);const Is=se("Type",[["polyline",{points:"4 7 4 4 20 4 20 7",key:"1nosan"}],["line",{x1:"9",x2:"15",y1:"20",y2:"20",key:"swin9y"}],["line",{x1:"12",x2:"12",y1:"4",y2:"20",key:"1tx1rr"}]]);function so(t){const e=I.c(15),{onSave:n,onUndo:s,isDirty:i,isSaving:r,saveLabel:l,undoLabel:c}=t,a=l===void 0?"Save":l,u=c===void 0?"Undo":c;if(!i)return null;let d;e[0]===Symbol.for("react.memo_cache_sentinel")?(d=o.jsx(un,{size:14}),e[0]=d):d=e[0];let f;e[1]!==r||e[2]!==s||e[3]!==u?(f=o.jsxs(te,{variant:"outline",size:"sm",onClick:s,disabled:r,"aria-label":u,children:[d,u]}),e[1]=r,e[2]=s,e[3]=u,e[4]=f):f=e[4];let m;e[5]!==r?(m=r?o.jsx(Yt,{size:14,className:"animate-spin"}):o.jsx(dn,{size:14}),e[5]=r,e[6]=m):m=e[6];let p;e[7]!==r||e[8]!==n||e[9]!==a||e[10]!==m?(p=o.jsxs(te,{variant:"default",size:"sm",onClick:n,disabled:r,"aria-label":a,children:[m,a]}),e[7]=r,e[8]=n,e[9]=a,e[10]=m,e[11]=p):p=e[11];let x;return e[12]!==f||e[13]!==p?(x=o.jsxs(o.Fragment,{children:[f,p]}),e[12]=f,e[13]=p,e[14]=x):x=e[14],x}const Pt=t=>{let e;const n=new Set,s=(u,d)=>{const f=typeof u=="function"?u(e):u;if(!Object.is(f,e)){const m=e;e=d??(typeof f!="object"||f===null)?f:Object.assign({},e,f),n.forEach(p=>p(e,m))}},i=()=>e,c={setState:s,getState:i,getInitialState:()=>a,subscribe:u=>(n.add(u),()=>n.delete(u))},a=e=t(s,i,c);return c},Tt=(t=>t?Pt(t):Pt),no=t=>t;function jt(t,e=no){const n=We.useSyncExternalStore(t.subscribe,We.useCallback(()=>e(t.getState()),[t,e]),We.useCallback(()=>e(t.getInitialState()),[t,e]));return We.useDebugValue(n),n}const oo=t=>{const e=Tt(t),n=s=>jt(e,s);return Object.assign(n,e),n},ro=(t=>oo);function _s(t,e){let n;try{n=t()}catch{return}return{getItem:i=>{var r;const l=a=>a===null?null:JSON.parse(a,void 0),c=(r=n.getItem(i))!=null?r:null;return c instanceof Promise?c.then(l):l(c)},setItem:(i,r)=>n.setItem(i,JSON.stringify(r,void 0)),removeItem:i=>n.removeItem(i)}}const St=t=>e=>{try{const n=t(e);return n instanceof Promise?n:{then(s){return St(s)(n)},catch(s){return this}}}catch(n){return{then(s){return this},catch(s){return St(s)(n)}}}},io=(t,e)=>(n,s,i)=>{let r={storage:_s(()=>window.localStorage),partialize:g=>g,version:0,merge:(g,b)=>({...b,...g}),...e},l=!1,c=0;const a=new Set,u=new Set;let d=r.storage;if(!d)return t((...g)=>{console.warn(`[zustand persist middleware] Unable to update item '${r.name}', the given storage is currently unavailable.`),n(...g)},s,i);const f=()=>{const g=r.partialize({...s()});return d.setItem(r.name,{state:g,version:r.version})},m=i.setState;i.setState=(g,b)=>(m(g,b),f());const p=t((...g)=>(n(...g),f()),s,i);i.getInitialState=()=>p;let x;const h=()=>{var g,b;if(!d)return;const S=++c;l=!1,a.forEach(y=>{var j;return y((j=s())!=null?j:p)});const w=((b=r.onRehydrateStorage)==null?void 0:b.call(r,(g=s())!=null?g:p))||void 0;return St(d.getItem.bind(d))(r.name).then(y=>{if(y)if(typeof y.version=="number"&&y.version!==r.version){if(r.migrate){const j=r.migrate(y.state,y.version);return j instanceof Promise?j.then(v=>[!0,v]):[!0,j]}console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return[!1,y.state];return[!1,void 0]}).then(y=>{var j;if(S!==c)return;const[v,N]=y;if(x=r.merge(N,(j=s())!=null?j:p),n(x,!0),v)return f()}).then(()=>{S===c&&(w?.(s(),void 0),x=s(),l=!0,u.forEach(y=>y(x)))}).catch(y=>{S===c&&w?.(void 0,y)})};return i.persist={setOptions:g=>{r={...r,...g},g.storage&&(d=g.storage)},clearStorage:()=>{d?.removeItem(r.name)},getOptions:()=>r,rehydrate:()=>h(),hasHydrated:()=>l,onHydrate:g=>(a.add(g),()=>{a.delete(g)}),onFinishHydration:g=>(u.add(g),()=>{u.delete(g)})},r.skipHydration||h(),x||p},Cs=io,{useSyncExternalStoreWithSelector:lo}=Gs,co=t=>t;function ao(t,e=co,n){const s=lo(t.subscribe,t.getState,t.getInitialState,e,n);return We.useDebugValue(s),s}const Dt=t=>Symbol.iterator in t,Ft=t=>"entries"in t,Vt=(t,e)=>{const n=t instanceof Map?t:new Map(t.entries()),s=e instanceof Map?e:new Map(e.entries());if(n.size!==s.size)return!1;for(const[i,r]of n)if(!s.has(i)||!Object.is(r,s.get(i)))return!1;return!0},uo=(t,e)=>{const n=t[Symbol.iterator](),s=e[Symbol.iterator]();let i=n.next(),r=s.next();for(;!i.done&&!r.done;){if(!Object.is(i.value,r.value))return!1;i=n.next(),r=s.next()}return!!i.done&&!!r.done};function fo(t,e){return Object.is(t,e)?!0:typeof t!="object"||t===null||typeof e!="object"||e===null||Object.getPrototypeOf(t)!==Object.getPrototypeOf(e)?!1:Dt(t)&&Dt(e)?Ft(t)&&Ft(e)?Vt(t,e):uo(t,e):Vt({entries:()=>Object.entries(t)},{entries:()=>Object.entries(e)})}function Ts(t,e="Output"){if(!t)return`interface ${e} {}`;function n(r){if(!r||typeof r!="object")return"unknown";const l=r.type;if(Array.isArray(l))return l.map(c=>s(c)).join(" | ");switch(l){case"string":return r.enum?r.enum.map(c=>`"${c}"`).join(" | "):"string";case"number":case"integer":return"number";case"boolean":return"boolean";case"null":return"null";case"array":{const c=r.items;return c?`${n(c)}[]`:"unknown[]"}case"object":return i(r);default:return r.anyOf?r.anyOf.map(n).join(" | "):r.oneOf?r.oneOf.map(n).join(" | "):r.allOf?r.allOf.map(n).join(" & "):"unknown"}}function s(r){switch(r){case"string":return"string";case"number":case"integer":return"number";case"boolean":return"boolean";case"null":return"null";default:return"unknown"}}function i(r){const l=r.properties;if(!l)return"Record<string, unknown>";const c=new Set(r.required||[]);return`{
1
+ import{dW as se,e as I,j as o,B as te,l as Yt,b1 as We,dX as Gs,r as X,q as oe,c as $,g as Qs,F as Zt,dY as Nt,dZ as es,o as Ys,v as Zs,d_ as en,d$ as tn}from"./index-8Av7_XG5.js";import{D as sn,F as nn,B as on}from"./index-CnvExC11.js";import{h as De,i as rn,u as ae}from"./constants-DeFtLUND.js";import{a as ts}from"./use-virtual-mcp-C_vD2kKw.js";import{M as Oe}from"./monaco-editor-BAqhsJzm.js";import{b as ln,R as zt,a as cn}from"./resizable-DtVYiBv-.js";import{B as le}from"./badge-BiVWMQaC.js";import{b as xt,d as ht,c as Ze,a as gt,S as bt}from"./select-Y4AHPww8.js";import{S as et}from"./spinner-CWHpDgnL.js";import{V as an}from"./view-mode-toggle-BabF7Sx4.js";import{ai as un,o as dn,i as fn,z as ss,aj as mn,a3 as pn,u as xn,ak as ns,a9 as hn,N as os,al as gn,am as bn,a5 as ft,an as jn}from"./agent-icon-VIqap9Jf.js";import{i as rs}from"./Play-CL1Mgiwf.js";import{b as Sn,a as yn,V as Ge}from"./layout-BuMBlDfo.js";import{c as is,b as ls,T as cs,a as as}from"./tooltip-B9p8ywB_.js";import{u as wn,a as vn}from"./use-connection-C2Ef-EqP.js";import{u as kt,d as It,b as us}from"./use-mcp-tools-C8LW1vg1.js";import{b as Nn,c as kn,e as In,d as _n,a as Cn,D as Tn}from"./dialog-BDoa-Aig.js";import"./index-DJjaDA78.js";import{N as En,m as $n,n as On,o as Ke,P as Mn,i as Rn,R as Ln,u as zn,p as Wn,e as Wt,d as An,q as Pn,S as Dn}from"./scroll-area-GY_MqX9m.js";import{S as Fn}from"./index-DhlM3QdF.js";import{H as Vn,a as qn,b as Hn}from"./hover-card-CZKyvEKV.js";import{D as ds,a as fs,b as ms,c as Qe}from"./dropdown-menu-BuEg85yr.js";import{s as Un}from"./Plus-DINfOuqC.js";import{b as ps}from"./Tool01-Co9IzxOX.js";import{i as Fe}from"./Check-D-2DMeXR.js";import{s as _t}from"./XClose-s3WJPw3-.js";import{I as Ct}from"./integration-icon-ByZrCdpe.js";import{A as Kn,c as Bn,a as Xn,b as Jn}from"./accordion-B1qqQUiM.js";import"./index-D2E_r2Ga.js";import{i as xs}from"./X-D5DAti-0.js";import{u as hs,a as Gn}from"./use-collections-CMMaRmVG.js";import{E as gs}from"./empty-state-BzUpYoP8.js";import{c as Qn}from"./create-sse-subscription-BS5983N4.js";import{I as At}from"./input-CFgdCIf-.js";const bs=se("Box",[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]]);const js=se("Braces",[["path",{d:"M8 3H7a2 2 0 0 0-2 2v5a2 2 0 0 1-2 2 2 2 0 0 1 2 2v5c0 1.1.9 2 2 2h1",key:"ezmyqa"}],["path",{d:"M16 21h1a2 2 0 0 0 2-2v-5c0-1.1.9-2 2-2a2 2 0 0 1-2-2V5a2 2 0 0 0-2-2h-1",key:"e1hn23"}]]);const tt=se("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);const st=se("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);const Yn=se("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);const Ss=se("Code",[["polyline",{points:"16 18 22 12 16 6",key:"z7tu5w"}],["polyline",{points:"8 6 2 12 8 18",key:"1eg1df"}]]);const Zn=se("Copy",[["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"}]]);const ys=se("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);const ws=se("File",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}]]);const vs=se("Hash",[["line",{x1:"4",x2:"20",y1:"9",y2:"9",key:"4lhtct"}],["line",{x1:"4",x2:"20",y1:"15",y2:"15",key:"vyu0kd"}],["line",{x1:"10",x2:"8",y1:"3",y2:"21",key:"1ggp8o"}],["line",{x1:"16",x2:"14",y1:"3",y2:"21",key:"weycgp"}]]);const eo=se("OctagonAlert",[["path",{d:"M12 16h.01",key:"1drbdi"}],["path",{d:"M12 8v4",key:"1got3b"}],["path",{d:"M15.312 2a2 2 0 0 1 1.414.586l4.688 4.688A2 2 0 0 1 22 8.688v6.624a2 2 0 0 1-.586 1.414l-4.688 4.688a2 2 0 0 1-1.414.586H8.688a2 2 0 0 1-1.414-.586l-4.688-4.688A2 2 0 0 1 2 15.312V8.688a2 2 0 0 1 .586-1.414l4.688-4.688A2 2 0 0 1 8.688 2z",key:"1fd625"}]]);const Ns=se("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);const ks=se("SquareCheckBig",[["path",{d:"M21 10.5V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h12.5",key:"1uzm8b"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);const to=se("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);const Is=se("Type",[["polyline",{points:"4 7 4 4 20 4 20 7",key:"1nosan"}],["line",{x1:"9",x2:"15",y1:"20",y2:"20",key:"swin9y"}],["line",{x1:"12",x2:"12",y1:"4",y2:"20",key:"1tx1rr"}]]);function so(t){const e=I.c(15),{onSave:n,onUndo:s,isDirty:i,isSaving:r,saveLabel:l,undoLabel:c}=t,a=l===void 0?"Save":l,u=c===void 0?"Undo":c;if(!i)return null;let d;e[0]===Symbol.for("react.memo_cache_sentinel")?(d=o.jsx(un,{size:14}),e[0]=d):d=e[0];let f;e[1]!==r||e[2]!==s||e[3]!==u?(f=o.jsxs(te,{variant:"outline",size:"sm",onClick:s,disabled:r,"aria-label":u,children:[d,u]}),e[1]=r,e[2]=s,e[3]=u,e[4]=f):f=e[4];let m;e[5]!==r?(m=r?o.jsx(Yt,{size:14,className:"animate-spin"}):o.jsx(dn,{size:14}),e[5]=r,e[6]=m):m=e[6];let p;e[7]!==r||e[8]!==n||e[9]!==a||e[10]!==m?(p=o.jsxs(te,{variant:"default",size:"sm",onClick:n,disabled:r,"aria-label":a,children:[m,a]}),e[7]=r,e[8]=n,e[9]=a,e[10]=m,e[11]=p):p=e[11];let x;return e[12]!==f||e[13]!==p?(x=o.jsxs(o.Fragment,{children:[f,p]}),e[12]=f,e[13]=p,e[14]=x):x=e[14],x}const Pt=t=>{let e;const n=new Set,s=(u,d)=>{const f=typeof u=="function"?u(e):u;if(!Object.is(f,e)){const m=e;e=d??(typeof f!="object"||f===null)?f:Object.assign({},e,f),n.forEach(p=>p(e,m))}},i=()=>e,c={setState:s,getState:i,getInitialState:()=>a,subscribe:u=>(n.add(u),()=>n.delete(u))},a=e=t(s,i,c);return c},Tt=(t=>t?Pt(t):Pt),no=t=>t;function jt(t,e=no){const n=We.useSyncExternalStore(t.subscribe,We.useCallback(()=>e(t.getState()),[t,e]),We.useCallback(()=>e(t.getInitialState()),[t,e]));return We.useDebugValue(n),n}const oo=t=>{const e=Tt(t),n=s=>jt(e,s);return Object.assign(n,e),n},ro=(t=>oo);function _s(t,e){let n;try{n=t()}catch{return}return{getItem:i=>{var r;const l=a=>a===null?null:JSON.parse(a,void 0),c=(r=n.getItem(i))!=null?r:null;return c instanceof Promise?c.then(l):l(c)},setItem:(i,r)=>n.setItem(i,JSON.stringify(r,void 0)),removeItem:i=>n.removeItem(i)}}const St=t=>e=>{try{const n=t(e);return n instanceof Promise?n:{then(s){return St(s)(n)},catch(s){return this}}}catch(n){return{then(s){return this},catch(s){return St(s)(n)}}}},io=(t,e)=>(n,s,i)=>{let r={storage:_s(()=>window.localStorage),partialize:g=>g,version:0,merge:(g,b)=>({...b,...g}),...e},l=!1,c=0;const a=new Set,u=new Set;let d=r.storage;if(!d)return t((...g)=>{console.warn(`[zustand persist middleware] Unable to update item '${r.name}', the given storage is currently unavailable.`),n(...g)},s,i);const f=()=>{const g=r.partialize({...s()});return d.setItem(r.name,{state:g,version:r.version})},m=i.setState;i.setState=(g,b)=>(m(g,b),f());const p=t((...g)=>(n(...g),f()),s,i);i.getInitialState=()=>p;let x;const h=()=>{var g,b;if(!d)return;const S=++c;l=!1,a.forEach(y=>{var j;return y((j=s())!=null?j:p)});const w=((b=r.onRehydrateStorage)==null?void 0:b.call(r,(g=s())!=null?g:p))||void 0;return St(d.getItem.bind(d))(r.name).then(y=>{if(y)if(typeof y.version=="number"&&y.version!==r.version){if(r.migrate){const j=r.migrate(y.state,y.version);return j instanceof Promise?j.then(v=>[!0,v]):[!0,j]}console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return[!1,y.state];return[!1,void 0]}).then(y=>{var j;if(S!==c)return;const[v,N]=y;if(x=r.merge(N,(j=s())!=null?j:p),n(x,!0),v)return f()}).then(()=>{S===c&&(w?.(s(),void 0),x=s(),l=!0,u.forEach(y=>y(x)))}).catch(y=>{S===c&&w?.(void 0,y)})};return i.persist={setOptions:g=>{r={...r,...g},g.storage&&(d=g.storage)},clearStorage:()=>{d?.removeItem(r.name)},getOptions:()=>r,rehydrate:()=>h(),hasHydrated:()=>l,onHydrate:g=>(a.add(g),()=>{a.delete(g)}),onFinishHydration:g=>(u.add(g),()=>{u.delete(g)})},r.skipHydration||h(),x||p},Cs=io,{useSyncExternalStoreWithSelector:lo}=Gs,co=t=>t;function ao(t,e=co,n){const s=lo(t.subscribe,t.getState,t.getInitialState,e,n);return We.useDebugValue(s),s}const Dt=t=>Symbol.iterator in t,Ft=t=>"entries"in t,Vt=(t,e)=>{const n=t instanceof Map?t:new Map(t.entries()),s=e instanceof Map?e:new Map(e.entries());if(n.size!==s.size)return!1;for(const[i,r]of n)if(!s.has(i)||!Object.is(r,s.get(i)))return!1;return!0},uo=(t,e)=>{const n=t[Symbol.iterator](),s=e[Symbol.iterator]();let i=n.next(),r=s.next();for(;!i.done&&!r.done;){if(!Object.is(i.value,r.value))return!1;i=n.next(),r=s.next()}return!!i.done&&!!r.done};function fo(t,e){return Object.is(t,e)?!0:typeof t!="object"||t===null||typeof e!="object"||e===null||Object.getPrototypeOf(t)!==Object.getPrototypeOf(e)?!1:Dt(t)&&Dt(e)?Ft(t)&&Ft(e)?Vt(t,e):uo(t,e):Vt({entries:()=>Object.entries(t)},{entries:()=>Object.entries(e)})}function Ts(t,e="Output"){if(!t)return`interface ${e} {}`;function n(r){if(!r||typeof r!="object")return"unknown";const l=r.type;if(Array.isArray(l))return l.map(c=>s(c)).join(" | ");switch(l){case"string":return r.enum?r.enum.map(c=>`"${c}"`).join(" | "):"string";case"number":case"integer":return"number";case"boolean":return"boolean";case"null":return"null";case"array":{const c=r.items;return c?`${n(c)}[]`:"unknown[]"}case"object":return i(r);default:return r.anyOf?r.anyOf.map(n).join(" | "):r.oneOf?r.oneOf.map(n).join(" | "):r.allOf?r.allOf.map(n).join(" & "):"unknown"}}function s(r){switch(r){case"string":return"string";case"number":case"integer":return"number";case"boolean":return"boolean";case"null":return"null";default:return"unknown"}}function i(r){const l=r.properties;if(!l)return"Record<string, unknown>";const c=new Set(r.required||[]);return`{
2
2
  ${Object.entries(l).map(([u,d])=>{const f=c.has(u)?"":"?";return`${d.description?` /** ${d.description} */
3
3
  `:""} ${u}${f}: ${n(d)};`}).join(`
4
4
  `)}
@@ -1 +1 @@
1
- import{e as f,c as d,r as p,j as r}from"./index-B9kRhzg7.js";import{m as w}from"./sidebar-BMIDAt6t.js";const v=p.createContext(void 0),H=v.Provider;function N(c,e){const l=p.Children.toArray(c);for(const i of l)if(p.isValidElement(i)&&i.type===e)return i;return null}function P(c){const e=f.c(5),{children:l,className:i}=c;let s;e[0]!==i?(s=d("flex flex-col h-full w-full bg-background overflow-hidden",i),e[0]=i,e[1]=s):s=e[1];let t;return e[2]!==l||e[3]!==s?(t=r.jsx("div",{className:s,children:l}),e[2]=l,e[3]=s,e[4]=t):t=e[4],t}function C(c){const e=f.c(17),{children:l,className:i,hideSidebarTrigger:s}=c;let t;e[0]!==l?(t=N(l,j),e[0]=l,e[1]=t):t=e[1];const n=t;let a;e[2]!==l?(a=N(l,b),e[2]=l,e[3]=a):a=e[3];const o=a;let m;e[4]!==i?(m=d("shrink-0 w-full border-b border-border/50 h-11","flex items-center justify-between gap-3 pr-2 pl-2 md:pl-4",i),e[4]=i,e[5]=m):m=e[5];let x;e[6]!==s?(x=!s&&r.jsx(w,{className:"md:hidden shrink-0"}),e[6]=s,e[7]=x):x=e[7];let u;e[8]!==n||e[9]!==x?(u=r.jsxs("div",{className:"flex items-center gap-1 min-w-0 flex-1",children:[x,n]}),e[8]=n,e[9]=x,e[10]=u):u=e[10];let h;e[11]!==o?(h=r.jsx("div",{className:"flex items-center",children:o}),e[11]=o,e[12]=h):h=e[12];let g;return e[13]!==m||e[14]!==u||e[15]!==h?(g=r.jsxs("div",{className:m,children:[u,h]}),e[13]=m,e[14]=u,e[15]=h,e[16]=g):g=e[16],g}function j(c){const e=f.c(5),{children:l,className:i}=c;let s;e[0]!==i?(s=d("flex items-center gap-2 min-w-0 overflow-hidden",i),e[0]=i,e[1]=s):s=e[1];let t;return e[2]!==l||e[3]!==s?(t=r.jsx("div",{className:s,children:l}),e[2]=l,e[3]=s,e[4]=t):t=e[4],t}function b(c){const e=f.c(5),{children:l,className:i}=c;let s;e[0]!==i?(s=d("flex items-center gap-2 shrink-0 overflow-hidden",i),e[0]=i,e[1]=s):s=e[1];let t;return e[2]!==l||e[3]!==s?(t=r.jsx("div",{className:s,children:l}),e[2]=l,e[3]=s,e[4]=t):t=e[4],t}function $(c){const e=f.c(6),{children:l,className:i}=c,s=p.useContext(v);let t;e[0]!==i||e[1]!==s?(t=d("flex-1 overflow-auto",s,i),e[0]=i,e[1]=s,e[2]=t):t=e[2];let n;return e[3]!==l||e[4]!==t?(n=r.jsx("div",{className:t,children:l}),e[3]=l,e[4]=t,e[5]=n):n=e[5],n}function y(c){const e=f.c(10),{children:l,actions:i,className:s}=c;let t;e[0]!==s?(t=d("flex flex-wrap items-center justify-between gap-3",s),e[0]=s,e[1]=t):t=e[1];let n;e[2]!==l?(n=r.jsx("div",{className:"text-xl font-medium min-w-0",children:l}),e[2]=l,e[3]=n):n=e[3];let a;e[4]!==i?(a=i&&r.jsx("div",{className:"flex items-center gap-2",children:i}),e[4]=i,e[5]=a):a=e[5];let o;return e[6]!==t||e[7]!==n||e[8]!==a?(o=r.jsxs("div",{className:t,children:[n,a]}),e[6]=t,e[7]=n,e[8]=a,e[9]=o):o=e[9],o}function R(c){const e=f.c(6),{children:l,className:i,maxWidth:s}=c,t=s===void 0?"max-w-[1200px]":s;let n;e[0]!==i||e[1]!==t?(n=d("mx-auto w-full px-4 pt-8 pb-6 md:px-10 md:pt-12 md:pb-10",t,i),e[0]=i,e[1]=t,e[2]=n):n=e[2];let a;return e[3]!==l||e[4]!==n?(a=r.jsx("div",{className:n,children:l}),e[3]=l,e[4]=n,e[5]=a):a=e[5],a}const T=Object.assign(P,{Header:Object.assign(C,{Left:j,Right:b}),Content:$,Title:y,Body:R});export{T as P,H as a};
1
+ import{e as f,c as d,r as p,j as r}from"./index-8Av7_XG5.js";import{m as w}from"./sidebar-BTAYcbpn.js";const v=p.createContext(void 0),H=v.Provider;function N(c,e){const l=p.Children.toArray(c);for(const i of l)if(p.isValidElement(i)&&i.type===e)return i;return null}function P(c){const e=f.c(5),{children:l,className:i}=c;let s;e[0]!==i?(s=d("flex flex-col h-full w-full bg-background overflow-hidden",i),e[0]=i,e[1]=s):s=e[1];let t;return e[2]!==l||e[3]!==s?(t=r.jsx("div",{className:s,children:l}),e[2]=l,e[3]=s,e[4]=t):t=e[4],t}function C(c){const e=f.c(17),{children:l,className:i,hideSidebarTrigger:s}=c;let t;e[0]!==l?(t=N(l,j),e[0]=l,e[1]=t):t=e[1];const n=t;let a;e[2]!==l?(a=N(l,b),e[2]=l,e[3]=a):a=e[3];const o=a;let m;e[4]!==i?(m=d("shrink-0 w-full border-b border-border/50 h-11","flex items-center justify-between gap-3 pr-2 pl-2 md:pl-4",i),e[4]=i,e[5]=m):m=e[5];let x;e[6]!==s?(x=!s&&r.jsx(w,{className:"md:hidden shrink-0"}),e[6]=s,e[7]=x):x=e[7];let u;e[8]!==n||e[9]!==x?(u=r.jsxs("div",{className:"flex items-center gap-1 min-w-0 flex-1",children:[x,n]}),e[8]=n,e[9]=x,e[10]=u):u=e[10];let h;e[11]!==o?(h=r.jsx("div",{className:"flex items-center",children:o}),e[11]=o,e[12]=h):h=e[12];let g;return e[13]!==m||e[14]!==u||e[15]!==h?(g=r.jsxs("div",{className:m,children:[u,h]}),e[13]=m,e[14]=u,e[15]=h,e[16]=g):g=e[16],g}function j(c){const e=f.c(5),{children:l,className:i}=c;let s;e[0]!==i?(s=d("flex items-center gap-2 min-w-0 overflow-hidden",i),e[0]=i,e[1]=s):s=e[1];let t;return e[2]!==l||e[3]!==s?(t=r.jsx("div",{className:s,children:l}),e[2]=l,e[3]=s,e[4]=t):t=e[4],t}function b(c){const e=f.c(5),{children:l,className:i}=c;let s;e[0]!==i?(s=d("flex items-center gap-2 shrink-0 overflow-hidden",i),e[0]=i,e[1]=s):s=e[1];let t;return e[2]!==l||e[3]!==s?(t=r.jsx("div",{className:s,children:l}),e[2]=l,e[3]=s,e[4]=t):t=e[4],t}function $(c){const e=f.c(6),{children:l,className:i}=c,s=p.useContext(v);let t;e[0]!==i||e[1]!==s?(t=d("flex-1 overflow-auto",s,i),e[0]=i,e[1]=s,e[2]=t):t=e[2];let n;return e[3]!==l||e[4]!==t?(n=r.jsx("div",{className:t,children:l}),e[3]=l,e[4]=t,e[5]=n):n=e[5],n}function y(c){const e=f.c(10),{children:l,actions:i,className:s}=c;let t;e[0]!==s?(t=d("flex flex-wrap items-center justify-between gap-3",s),e[0]=s,e[1]=t):t=e[1];let n;e[2]!==l?(n=r.jsx("div",{className:"text-xl font-medium min-w-0",children:l}),e[2]=l,e[3]=n):n=e[3];let a;e[4]!==i?(a=i&&r.jsx("div",{className:"flex items-center gap-2",children:i}),e[4]=i,e[5]=a):a=e[5];let o;return e[6]!==t||e[7]!==n||e[8]!==a?(o=r.jsxs("div",{className:t,children:[n,a]}),e[6]=t,e[7]=n,e[8]=a,e[9]=o):o=e[9],o}function R(c){const e=f.c(6),{children:l,className:i,maxWidth:s}=c,t=s===void 0?"max-w-[1200px]":s;let n;e[0]!==i||e[1]!==t?(n=d("mx-auto w-full px-4 pt-8 pb-6 md:px-10 md:pt-12 md:pb-10",t,i),e[0]=i,e[1]=t,e[2]=n):n=e[2];let a;return e[3]!==l||e[4]!==n?(a=r.jsx("div",{className:n,children:l}),e[3]=l,e[4]=n,e[5]=a):a=e[5],a}const T=Object.assign(P,{Header:Object.assign(C,{Left:j,Right:b}),Content:$,Title:y,Body:R});export{T as P,H as a};