decocms 2.306.6 → 2.306.7

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 (256) hide show
  1. package/dist/client/assets/{AlertCircle-4Fij-rVg.js → AlertCircle-Cb7fTEMa.js} +1 -1
  2. package/dist/client/assets/{ArrowNarrowLeft-CxNzupMt.js → ArrowNarrowLeft-tcEBzg5K.js} +1 -1
  3. package/dist/client/assets/{ArrowUpRight-B9s_0HcJ.js → ArrowUpRight-Ds7CgDkL.js} +1 -1
  4. package/dist/client/assets/{Check-DC_iCN8Z.js → Check-Dgq0jjpz.js} +1 -1
  5. package/dist/client/assets/{CheckCircle-ROoANe3f.js → CheckCircle-rZ5sDOOP.js} +1 -1
  6. package/dist/client/assets/{ChevronDown-CnUhTqwX.js → ChevronDown-CH5lQohM.js} +1 -1
  7. package/dist/client/assets/{ChevronRight-X2lm_E9M.js → ChevronRight-DfFDUpKj.js} +1 -1
  8. package/dist/client/assets/{ChevronUp-CgOfWCZA.js → ChevronUp-DCsRkih0.js} +1 -1
  9. package/dist/client/assets/{Container-BrskPoE3.js → Container-zeFPXb1Q.js} +1 -1
  10. package/dist/client/assets/{DotsVertical-C2-ev8jy.js → DotsVertical-BljfGuhu.js} +1 -1
  11. package/dist/client/assets/{LinkExternal01-Bhhv-wHj.js → LinkExternal01-MvI2bZbP.js} +1 -1
  12. package/dist/client/assets/{Lock01-KbqVCyA7.js → Lock01-CidilFiJ.js} +1 -1
  13. package/dist/client/assets/{Palette-CmZGtCez.js → Palette-CURRsupy.js} +1 -1
  14. package/dist/client/assets/{Play-EPgISV5B.js → Play-DLW6aJFn.js} +1 -1
  15. package/dist/client/assets/{Plus-BYimMcAW.js → Plus-28zZOE9T.js} +1 -1
  16. package/dist/client/assets/{RefreshCcw01-DIY3NFBI.js → RefreshCcw01-CCzpYBs0.js} +1 -1
  17. package/dist/client/assets/{SearchMd-DzMVdOJP.js → SearchMd-BpRj1P2W.js} +1 -1
  18. package/dist/client/assets/{Settings02-BxmxMTOA.js → Settings02-CE5ZLw2I.js} +1 -1
  19. package/dist/client/assets/{Shield01-B9vNkAc4.js → Shield01-Dtb2_AeI.js} +1 -1
  20. package/dist/client/assets/{Star01-iULH34rV.js → Star01-ChekdAzX.js} +1 -1
  21. package/dist/client/assets/{Sun-Dc78AQrj.js → Sun-TuktgENq.js} +1 -1
  22. package/dist/client/assets/{Tool01-DVcjHQGB.js → Tool01-Cu4I31F8.js} +1 -1
  23. package/dist/client/assets/{Trash01-CaZrP0UV.js → Trash01-4Dq6ympL.js} +1 -1
  24. package/dist/client/assets/{User01-7U7nAEDg.js → User01-DKnZn118.js} +1 -1
  25. package/dist/client/assets/{Users03-CIZBy7k3.js → Users03-rbWg-6tV.js} +1 -1
  26. package/dist/client/assets/{X-QdBx5oCM.js → X-CAquUT--.js} +1 -1
  27. package/dist/client/assets/{XCircle-DokNvYvs.js → XCircle-B-00qJpY.js} +1 -1
  28. package/dist/client/assets/{XClose-BdbZPqCd.js → XClose-_Y5VAjW5.js} +1 -1
  29. package/dist/client/assets/{Zap-DH1KrJ0w.js → Zap-B8xnzkap.js} +1 -1
  30. package/dist/client/assets/{ZapSquare-CnxL4Bs1.js → ZapSquare-Cpo7Z7gP.js} +1 -1
  31. package/dist/client/assets/{accordion-81SrnINF.js → accordion-CyIKHcCT.js} +1 -1
  32. package/dist/client/assets/{agent-icon-C2zAhw3X.js → agent-icon-D9odI-qh.js} +1 -1
  33. package/dist/client/assets/{agents-list-CH2sTwpj.js → agents-list-CLJAN1rm.js} +1 -1
  34. package/dist/client/assets/ai-providers-28dSCs53.js +1 -0
  35. package/dist/client/assets/{alert-dialog-BytOwrWo.js → alert-dialog-DCT4MTMH.js} +1 -1
  36. package/dist/client/assets/{auth-catchall-BcUDEqD5.js → auth-catchall-DoKHQvfb.js} +1 -1
  37. package/dist/client/assets/{automation-list-row-etrXhG1_.js → automation-list-row-C0fNHM9j.js} +1 -1
  38. package/dist/client/assets/{automations-DFRPWAOO.js → automations-CVam3JT8.js} +1 -1
  39. package/dist/client/assets/{avatar-D0sdobqD.js → avatar-JoKAxyik.js} +1 -1
  40. package/dist/client/assets/{badge-tvsCFCHP.js → badge-BXVtVPzt.js} +1 -1
  41. package/dist/client/assets/{brand-context-Cy-kcB0m.js → brand-context-B00HyWuJ.js} +1 -1
  42. package/dist/client/assets/{card-BGZ5LqAO.js → card-CkFfla-m.js} +1 -1
  43. package/dist/client/assets/{chat-context-iq-Q-O9L.js → chat-context-C4lTxfjV.js} +1 -1
  44. package/dist/client/assets/{checkbox-IEnuEqAm.js → checkbox-Baro7Q1f.js} +1 -1
  45. package/dist/client/assets/{collection-detail-BnoKU_uS.js → collection-detail-CvBw6hsJ.js} +1 -1
  46. package/dist/client/assets/{collection-display-button-tJsvfx8o.js → collection-display-button-BSv13jEo.js} +1 -1
  47. package/dist/client/assets/{collection-search-bjPRZI3g.js → collection-search-BHyuqRiT.js} +1 -1
  48. package/dist/client/assets/{collection-search-O8QAretn.js → collection-search-jhKWbxqo.js} +1 -1
  49. package/dist/client/assets/{collection-table-wrapper-CcyIZki9.js → collection-table-wrapper-hR7H16-N.js} +1 -1
  50. package/dist/client/assets/{collection-tabs-CqINIlN4.js → collection-tabs-BPF8fjT2.js} +1 -1
  51. package/dist/client/assets/{collections-DKW_jlNs.js → collections-B60eBxX4.js} +1 -1
  52. package/dist/client/assets/{command-Cbi8R9Tg.js → command-CJRvOxZ7.js} +1 -1
  53. package/dist/client/assets/{connection-card-Aj-8CWhX.js → connection-card-ugyEg8FF.js} +1 -1
  54. package/dist/client/assets/{connection-detail-G5l6bgwi.js → connection-detail-EgRvIktM.js} +1 -1
  55. package/dist/client/assets/{connection-form-helpers-hlnQqQXV.js → connection-form-helpers-CYrNbtwl.js} +1 -1
  56. package/dist/client/assets/{connections-CrOLesap.js → connections-I35i0t7r.js} +1 -1
  57. package/dist/client/assets/{constants-Dm1wnwL3.js → constants-CMPjFkrZ.js} +1 -1
  58. package/dist/client/assets/{constants-CWAA475A.js → constants-XGFAnuHn.js} +1 -1
  59. package/dist/client/assets/{dialog-0SvGB_9G.js → dialog-sfEBwtz9.js} +1 -1
  60. package/dist/client/assets/{domain-settings-CckaLtjm.js → domain-settings-BEv8OnaD.js} +1 -1
  61. package/dist/client/assets/{drawer-CyXE-C5x.js → drawer--MluJNWl.js} +1 -1
  62. package/dist/client/assets/{dropdown-menu-BkrpBFy3.js → dropdown-menu-BpPFRti7.js} +1 -1
  63. package/dist/client/assets/{dynamic-plugin-layout-DAf8nhzs.js → dynamic-plugin-layout-JwST599m.js} +1 -1
  64. package/dist/client/assets/{empty-state-Crsog8CF.js → empty-state-Be0FdXg2.js} +1 -1
  65. package/dist/client/assets/{empty-state-CxZybw5m.js → empty-state-Vlkqr5Ha.js} +1 -1
  66. package/dist/client/assets/{extract-connection-data-CnUKkwJT.js → extract-connection-data-B9BMTKgA.js} +1 -1
  67. package/dist/client/assets/{features-Ddtjf7i2.js → features-ymCT4sQe.js} +1 -1
  68. package/dist/client/assets/{form-BMjsxf1O.js → form-DpB6tHPK.js} +1 -1
  69. package/dist/client/assets/{general-CVe1Krdt.js → general-Bi8iKo_s.js} +1 -1
  70. package/dist/client/assets/{index-BV4BlnS9.js → index-0dtUnOR1.js} +2 -2
  71. package/dist/client/assets/{index-hSAfwkZQ.js → index-B-PMmlqs.js} +1 -1
  72. package/dist/client/assets/{index-CyJ-TyKU.js → index-BAl-Vlym.js} +1 -1
  73. package/dist/client/assets/{index-WBXV3t9A.js → index-BG0omYxu.js} +1 -1
  74. package/dist/client/assets/{index-CPDZUQ3g.js → index-BWMPhdit.js} +1 -1
  75. package/dist/client/assets/{index-CEyiW6G-.js → index-B_IvwEkx.js} +1 -1
  76. package/dist/client/assets/index-BkJIlnCh.js +1 -0
  77. package/dist/client/assets/{index-CYY5hWbm.js → index-Bzh6y1DZ.js} +1 -1
  78. package/dist/client/assets/{index-AqmdpH5c.js → index-CGKwbcyW.js} +1 -1
  79. package/dist/client/assets/{index-DYUyKEVO.js → index-Cav3nFoE.js} +1 -1
  80. package/dist/client/assets/{index-tIIHK8_r.js → index-DE4jOyEe.js} +1 -1
  81. package/dist/client/assets/{index-DvCRkopi.js → index-DlEDBVDU.js} +1 -1
  82. package/dist/client/assets/{index-CZ5qFDIg.js → index-DqWmbGe9.js} +1 -1
  83. package/dist/client/assets/{index-DusASzPG.js → index-JYp8Y8Zk.js} +3 -3
  84. package/dist/client/assets/{index-B8A_ReFj.js → index-mKsCyZ2c.js} +1 -1
  85. package/dist/client/assets/{index-D85QLvNR.js → index-uTY5VsaX.js} +1 -1
  86. package/dist/client/assets/{infiniteQueryObserver-DmPvCV47.js → infiniteQueryObserver-D69C8aZS.js} +1 -1
  87. package/dist/client/assets/{input-Bs7mkNsF.js → input-Dh3J6cxA.js} +1 -1
  88. package/dist/client/assets/{integration-icon-DgJZ63kl.js → integration-icon-CDE9CENl.js} +1 -1
  89. package/dist/client/assets/{label-CB1YxmGr.js → label-BGhcnROH.js} +1 -1
  90. package/dist/client/assets/{layout-GReGu88m.js → layout-DMQieMve.js} +1 -1
  91. package/dist/client/assets/{lean-canvas-recruit-modal-BkH3ZJD2.js → lean-canvas-recruit-modal-DZfH4ZaB.js} +1 -1
  92. package/dist/client/assets/{login-JiD1cfP5.js → login-HZPNR9xd.js} +1 -1
  93. package/dist/client/assets/{members-B72381x1.js → members-DXQFXjq8.js} +1 -1
  94. package/dist/client/assets/{monaco-editor-_r7N6eV-.js → monaco-editor-BaDnBAIf.js} +1 -1
  95. package/dist/client/assets/{monitoring-stats-row-IV0nDqiB.js → monitoring-stats-row-CQqHcgiv.js} +1 -1
  96. package/dist/client/assets/{oauth-callback-CkFjLbE_.js → oauth-callback-Du4eDSpz.js} +1 -1
  97. package/dist/client/assets/{oauth-callback-ai-provider-By5VSIqz.js → oauth-callback-ai-provider-BhxrV53q.js} +1 -1
  98. package/dist/client/assets/{onboarding-CCZiORGK.js → onboarding-HMRjmRyP.js} +1 -1
  99. package/dist/client/assets/{org-layout-DF3EY572.js → org-layout-DoqHSWQn.js} +1 -1
  100. package/dist/client/assets/{org-plugin-layout-C4CnG2ku.js → org-plugin-layout-DXqded6M.js} +1 -1
  101. package/dist/client/assets/{pair-Hj9vutgK.js → pair-D1MIu7ah.js} +1 -1
  102. package/dist/client/assets/{plugin-empty-state-DtiwhoNI.js → plugin-empty-state-BSfCLmcP.js} +1 -1
  103. package/dist/client/assets/{plugin-header-CjcXnInr.js → plugin-header-2Ks_trAw.js} +1 -1
  104. package/dist/client/assets/{plugin-layout-BJ0qU511.js → plugin-layout-CdtsQwFc.js} +1 -1
  105. package/dist/client/assets/{popover-9-i1guS1.js → popover-D4Clv1Kb.js} +1 -1
  106. package/dist/client/assets/{profile-C0pKX75D.js → profile-CjGu4VCE.js} +1 -1
  107. package/dist/client/assets/{project-app-view-Btui0VFM.js → project-app-view-Cr2YOe9x.js} +1 -1
  108. package/dist/client/assets/registry-YuZMNy-0.js +2 -0
  109. package/dist/client/assets/{registry-layout-Cvjuv72f.js → registry-layout-DGUmz1QL.js} +1 -1
  110. package/dist/client/assets/{required-auth-layout-Cm0GjYeR.js → required-auth-layout-DMKD_TV3.js} +1 -1
  111. package/dist/client/assets/{reset-password-DHyMDEUg.js → reset-password-Bn__ApCp.js} +1 -1
  112. package/dist/client/assets/{roles-BRZ0jwUp.js → roles-C4lGMFwb.js} +1 -1
  113. package/dist/client/assets/{scroll-area-Dal58SLb.js → scroll-area-yWZqBKom.js} +1 -1
  114. package/dist/client/assets/{search-input-BSfMPrXv.js → search-input-UA1Jjc1m.js} +1 -1
  115. package/dist/client/assets/{select-DQy3AX-J.js → select-CG0rwGUX.js} +1 -1
  116. package/dist/client/assets/{select-model-BjvpQUyU.js → select-model-DcRnjECr.js} +1 -1
  117. package/dist/client/assets/{settings-layout-Hke-qhRP.js → settings-layout-ePFy_Zf4.js} +1 -1
  118. package/dist/client/assets/{settings-section-DJf4hau9.js → settings-section-HkZRSntL.js} +1 -1
  119. package/dist/client/assets/{shell-layout-BcsYrOTT.js → shell-layout-CtEV3YzW.js} +1 -1
  120. package/dist/client/assets/{skeleton-DLT024S3.js → skeleton-BxQRt9FI.js} +1 -1
  121. package/dist/client/assets/{sso-BuTvljxJ.js → sso-DElvxw59.js} +1 -1
  122. package/dist/client/assets/{store-Iw0YIysI.js → store-CQloMsrY.js} +1 -1
  123. package/dist/client/assets/store-registry-h--qJyio.js +2 -0
  124. package/dist/client/assets/{switch-ChOgiOZl.js → switch-DydlPJmA.js} +1 -1
  125. package/dist/client/assets/{table-B48Xy50A.js → table-Cg2S62iB.js} +1 -1
  126. package/dist/client/assets/{tabs-y647ki3a.js → tabs-BArWG_lg.js} +1 -1
  127. package/dist/client/assets/{task-status-IiU7o7it.js → task-status-Bi6NGRuA.js} +1 -1
  128. package/dist/client/assets/{textarea-CT4UCcWE.js → textarea-Dkmw6W4u.js} +1 -1
  129. package/dist/client/assets/{toggle-group-CgDVnjbj.js → toggle-group-BdQafmUc.js} +1 -1
  130. package/dist/client/assets/{tools-list-Dl1EqLq_.js → tools-list-C0MslVQp.js} +1 -1
  131. package/dist/client/assets/{tooltip-DZT-1bal.js → tooltip-XW5rFMNu.js} +1 -1
  132. package/dist/client/assets/{types-DA7k1cs0.js → types-BU1oqgjO.js} +1 -1
  133. package/dist/client/assets/{use-ai-providers-Bv-kgplO.js → use-ai-providers-ClmB64W8.js} +1 -1
  134. package/dist/client/assets/{use-collections-ASqcb463.js → use-collections-BLOTVIAP.js} +1 -1
  135. package/dist/client/assets/{use-connection-Ck4brnCx.js → use-connection-DGPnnQz6.js} +1 -1
  136. package/dist/client/assets/{use-copy-qtJD_4jj.js → use-copy-BquaY5FR.js} +1 -1
  137. package/dist/client/assets/{use-create-virtual-mcp-CTxthd0a.js → use-create-virtual-mcp-gYa1vYVG.js} +1 -1
  138. package/dist/client/assets/{use-debounced-autosave-BliXkuEQ.js → use-debounced-autosave-BFE3ZeG7.js} +1 -1
  139. package/dist/client/assets/{use-decopilot-events-tgKj5crX.js → use-decopilot-events-nw-lJk37.js} +1 -1
  140. package/dist/client/assets/{use-delete-connection-DM_4FfQI.js → use-delete-connection-MTPofM5f.js} +1 -1
  141. package/dist/client/assets/{use-infinite-scroll-De_3UNjO.js → use-infinite-scroll-KzNu752x.js} +1 -1
  142. package/dist/client/assets/{use-list-state-SVk88wog.js → use-list-state-BMUfPc5P.js} +1 -1
  143. package/dist/client/assets/{use-mcp-tools-rNZ6JWxz.js → use-mcp-tools-DkxVTDC9.js} +1 -1
  144. package/dist/client/assets/{use-members-Bk-c46d0.js → use-members-DadnCd-C.js} +1 -1
  145. package/dist/client/assets/{use-navigate-to-agent-CwcBoswU.js → use-navigate-to-agent-zDaGGVEB.js} +1 -1
  146. package/dist/client/assets/{use-org-auth-client-Hwc_S6Fw.js → use-org-auth-client-CPZNMqkZ.js} +1 -1
  147. package/dist/client/assets/{use-org-sso-Cj1DBVz0.js → use-org-sso-DMUwA_K8.js} +1 -1
  148. package/dist/client/assets/{use-organization-roles--8BRYJrg.js → use-organization-roles-CJVol15S.js} +1 -1
  149. package/dist/client/assets/{use-organization-settings-gFwljgrZ.js → use-organization-settings-CoHf1k_t.js} +1 -1
  150. package/dist/client/assets/{use-registry-connections-Dgb2TDlG.js → use-registry-connections-DWMBdekg.js} +1 -1
  151. package/dist/client/assets/{use-status-sounds-Cn3fBsPH.js → use-status-sounds-j2IA-viC.js} +1 -1
  152. package/dist/client/assets/{use-tasks-DqNLNkkM.js → use-tasks-DqkYGNHa.js} +1 -1
  153. package/dist/client/assets/{use-view-mode-D9kCRFMC.js → use-view-mode-Bc5J1h4b.js} +1 -1
  154. package/dist/client/assets/{use-virtual-mcp-BR6mzHHD.js → use-virtual-mcp-Dndzl8Kr.js} +1 -1
  155. package/dist/client/assets/useInfiniteQuery-BzvZ_TDh.js +1 -0
  156. package/dist/client/assets/useSuspenseInfiniteQuery-ZnAzp1qO.js +1 -0
  157. package/dist/client/assets/{user-BVu9y1Y7.js → user-Df7A58iD.js} +1 -1
  158. package/dist/client/assets/{view-mode-toggle-ZI-MN1pO.js → view-mode-toggle-DoidsjaP.js} +1 -1
  159. package/dist/client/assets/{workflow-D5sDlQLV.js → workflow-DgvsxaIb.js} +1 -1
  160. package/dist/client/assets/workflow-detail-Bebyclsh.js +1 -0
  161. package/dist/client/index.html +1 -1
  162. package/dist/server/cli.js +90 -38
  163. package/dist/server/node_modules/ansi-regex/index.d.ts +33 -0
  164. package/dist/server/node_modules/ansi-regex/index.js +14 -0
  165. package/dist/server/node_modules/{ansi-styles → ansi-regex}/package.json +20 -13
  166. package/dist/server/node_modules/ansi-regex/readme.md +66 -0
  167. package/dist/server/node_modules/emoji-regex/LICENSE-MIT.txt +20 -0
  168. package/dist/server/node_modules/emoji-regex/README.md +107 -0
  169. package/dist/server/node_modules/emoji-regex/index.d.ts +3 -0
  170. package/dist/server/node_modules/emoji-regex/index.js +4 -0
  171. package/dist/server/node_modules/emoji-regex/index.mjs +4 -0
  172. package/dist/server/node_modules/emoji-regex/package.json +45 -0
  173. package/dist/server/node_modules/onetime/index.d.ts +64 -0
  174. package/dist/server/node_modules/onetime/index.js +44 -0
  175. package/dist/server/node_modules/onetime/package.json +43 -0
  176. package/dist/server/node_modules/onetime/readme.md +94 -0
  177. package/dist/server/server.js +89 -37
  178. package/package.json +1 -1
  179. package/dist/client/assets/ai-providers-BxrN55-q.js +0 -1
  180. package/dist/client/assets/index-Bhv1nOmU.js +0 -1
  181. package/dist/client/assets/registry-Bhz5Jlkf.js +0 -2
  182. package/dist/client/assets/store-registry-Df9fj_hE.js +0 -2
  183. package/dist/client/assets/useInfiniteQuery-C_BkERX4.js +0 -1
  184. package/dist/client/assets/useSuspenseInfiniteQuery-DFnwwxGS.js +0 -1
  185. package/dist/client/assets/workflow-detail-BKMBH1Ij.js +0 -1
  186. package/dist/server/node_modules/ansi-styles/index.d.ts +0 -236
  187. package/dist/server/node_modules/ansi-styles/index.js +0 -223
  188. package/dist/server/node_modules/ansi-styles/readme.md +0 -173
  189. package/dist/server/node_modules/environment/index.d.ts +0 -74
  190. package/dist/server/node_modules/environment/index.js +0 -47
  191. package/dist/server/node_modules/environment/package.json +0 -74
  192. package/dist/server/node_modules/environment/readme.md +0 -94
  193. package/dist/server/node_modules/escape-string-regexp/index.d.ts +0 -18
  194. package/dist/server/node_modules/escape-string-regexp/index.js +0 -11
  195. package/dist/server/node_modules/escape-string-regexp/license +0 -9
  196. package/dist/server/node_modules/escape-string-regexp/package.json +0 -43
  197. package/dist/server/node_modules/escape-string-regexp/readme.md +0 -29
  198. package/dist/server/node_modules/get-east-asian-width/index.d.ts +0 -60
  199. package/dist/server/node_modules/get-east-asian-width/index.js +0 -30
  200. package/dist/server/node_modules/get-east-asian-width/license +0 -9
  201. package/dist/server/node_modules/get-east-asian-width/lookup-data.js +0 -18
  202. package/dist/server/node_modules/get-east-asian-width/lookup.js +0 -135
  203. package/dist/server/node_modules/get-east-asian-width/package.json +0 -71
  204. package/dist/server/node_modules/get-east-asian-width/readme.md +0 -65
  205. package/dist/server/node_modules/get-east-asian-width/utilities.js +0 -24
  206. package/dist/server/node_modules/is-fullwidth-code-point/index.d.ts +0 -17
  207. package/dist/server/node_modules/is-fullwidth-code-point/index.js +0 -12
  208. package/dist/server/node_modules/is-fullwidth-code-point/license +0 -9
  209. package/dist/server/node_modules/is-fullwidth-code-point/package.json +0 -53
  210. package/dist/server/node_modules/is-fullwidth-code-point/readme.md +0 -31
  211. package/dist/server/node_modules/is-unicode-supported/index.d.ts +0 -12
  212. package/dist/server/node_modules/is-unicode-supported/index.js +0 -21
  213. package/dist/server/node_modules/is-unicode-supported/license +0 -9
  214. package/dist/server/node_modules/is-unicode-supported/package.json +0 -47
  215. package/dist/server/node_modules/is-unicode-supported/readme.md +0 -35
  216. package/dist/server/node_modules/pg/LICENSE +0 -21
  217. package/dist/server/node_modules/pg/README.md +0 -95
  218. package/dist/server/node_modules/pg/esm/index.mjs +0 -20
  219. package/dist/server/node_modules/pg/lib/client.js +0 -743
  220. package/dist/server/node_modules/pg/lib/connection-parameters.js +0 -171
  221. package/dist/server/node_modules/pg/lib/connection.js +0 -221
  222. package/dist/server/node_modules/pg/lib/crypto/cert-signatures.js +0 -122
  223. package/dist/server/node_modules/pg/lib/crypto/sasl.js +0 -212
  224. package/dist/server/node_modules/pg/lib/crypto/utils-legacy.js +0 -43
  225. package/dist/server/node_modules/pg/lib/crypto/utils-webcrypto.js +0 -89
  226. package/dist/server/node_modules/pg/lib/crypto/utils.js +0 -9
  227. package/dist/server/node_modules/pg/lib/defaults.js +0 -91
  228. package/dist/server/node_modules/pg/lib/index.js +0 -73
  229. package/dist/server/node_modules/pg/lib/native/client.js +0 -323
  230. package/dist/server/node_modules/pg/lib/native/index.js +0 -2
  231. package/dist/server/node_modules/pg/lib/native/query.js +0 -165
  232. package/dist/server/node_modules/pg/lib/query.js +0 -252
  233. package/dist/server/node_modules/pg/lib/result.js +0 -109
  234. package/dist/server/node_modules/pg/lib/stream.js +0 -83
  235. package/dist/server/node_modules/pg/lib/type-overrides.js +0 -35
  236. package/dist/server/node_modules/pg/lib/utils.js +0 -217
  237. package/dist/server/node_modules/pg/package.json +0 -76
  238. package/dist/server/node_modules/restore-cursor/index.d.ts +0 -11
  239. package/dist/server/node_modules/restore-cursor/index.js +0 -11
  240. package/dist/server/node_modules/restore-cursor/license +0 -9
  241. package/dist/server/node_modules/restore-cursor/package.json +0 -55
  242. package/dist/server/node_modules/restore-cursor/readme.md +0 -31
  243. package/dist/server/node_modules/string-width/index.d.ts +0 -39
  244. package/dist/server/node_modules/string-width/index.js +0 -82
  245. package/dist/server/node_modules/string-width/license +0 -9
  246. package/dist/server/node_modules/string-width/package.json +0 -64
  247. package/dist/server/node_modules/string-width/readme.md +0 -66
  248. package/dist/server/node_modules/xtend/.jshintrc +0 -30
  249. package/dist/server/node_modules/xtend/LICENSE +0 -20
  250. package/dist/server/node_modules/xtend/README.md +0 -32
  251. package/dist/server/node_modules/xtend/immutable.js +0 -19
  252. package/dist/server/node_modules/xtend/mutable.js +0 -17
  253. package/dist/server/node_modules/xtend/package.json +0 -55
  254. package/dist/server/node_modules/xtend/test.js +0 -103
  255. /package/dist/server/node_modules/{ansi-styles → ansi-regex}/license +0 -0
  256. /package/dist/server/node_modules/{environment → onetime}/license +0 -0
@@ -1 +1 @@
1
- import{e as b,s as k,o as E,bM as P,j as i,X as K,aG as _,K as S,x as q}from"./index-BV4BlnS9.js";import{P as x}from"./index-AqmdpH5c.js";import{d as I}from"./use-organization-settings-gFwljgrZ.js";import{S as Q}from"./switch-ChOgiOZl.js";import{n as R}from"./Container-BrskPoE3.js";import{b as w,S as z,a as F,d as M}from"./settings-section-DJf4hau9.js";import"./tooltip-DZT-1bal.js";import"./X-QdBx5oCM.js";import"./constants-Dm1wnwL3.js";import"./card-BGZ5LqAO.js";import"./ArrowUpRight-B9s_0HcJ.js";function N(){const e=b.c(17),{org:t,project:s}=k(),o=E();let u;e[0]!==s.enabledPlugins?(u=s.enabledPlugins??[],e[0]=s.enabledPlugins,e[1]=u):u=e[1];const c=u,l=I();let m;e[2]!==t||e[3]!==s.slug||e[4]!==o?(m=()=>{o.invalidateQueries({queryKey:S.project(t.id,s.slug)}),o.invalidateQueries({queryKey:S.projects(t.id)}),o.invalidateQueries({predicate:n=>{const r=n.queryKey;return r[1]===t.id&&r[3]==="collection"&&r[4]==="VIRTUAL_MCP"}})},e[2]=t,e[3]=s.slug,e[4]=o,e[5]=m):m=e[5];const j=m;let g;e[6]!==j||e[7]!==l||e[8]!==c?(g=(n,r)=>{const d=new Set(c);r?d.add(n):d.delete(n),l.mutate({enabled_plugins:Array.from(d)},{onSuccess:j,onError:A})},e[6]=j,e[7]=l,e[8]=c,e[9]=g):g=e[9];const p=g,y=$,C=U;if(P.length===0){let n;return e[10]===Symbol.for("react.memo_cache_sentinel")?(n=i.jsx("p",{className:"text-sm text-muted-foreground",children:"No plugins available."}),e[10]=n):n=e[10],n}let a;e[11]!==p||e[12]!==l||e[13]!==c?(a=P.map(n=>{const r=y(n.id),d=C(n.id),h=c.includes(n.id);return i.jsx(w,{title:r?.label??n.id,description:d??void 0,icon:i.jsx("span",{className:"text-muted-foreground [&>svg]:size-4",children:r?.icon??i.jsx(R,{size:14})}),onClick:()=>!l.isPending&&p(n.id,!h),action:i.jsx(Q,{checked:h,onCheckedChange:v=>p(n.id,v),disabled:l.isPending,onClick:T})},n.id)}),e[11]=p,e[12]=l,e[13]=c,e[14]=a):a=e[14];let f;return e[15]!==a?(f=i.jsx(z,{children:i.jsx(F,{children:a})}),e[15]=a,e[16]=f):f=e[16],f}function T(e){return e.stopPropagation()}function U(e){return P.find(s=>s.id===e)?.description??null}function $(e){const t=K.find(o=>o.pluginId===e);if(t)return{label:t.label,icon:t.items[0]?.icon};const s=_.find(o=>o.pluginId===e);return s?{label:s.label,icon:s.icon}:null}function A(e){q.error("Failed to update plugin: "+(e instanceof Error?e.message:"Unknown error"))}function D(){const e=b.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=i.jsx(x,{children:i.jsx(x.Content,{children:i.jsx(x.Body,{children:i.jsxs(M,{children:[i.jsx(x.Title,{children:"Plugins"}),i.jsx(N,{})]})})})}),e[0]=t):t=e[0],t}function ee(){const e=b.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=i.jsx(D,{}),e[0]=t):t=e[0],t}export{ee as default};
1
+ import{e as b,s as k,o as E,bM as P,j as i,X as K,aG as _,K as S,x as q}from"./index-0dtUnOR1.js";import{P as x}from"./index-CGKwbcyW.js";import{d as I}from"./use-organization-settings-CoHf1k_t.js";import{S as Q}from"./switch-DydlPJmA.js";import{n as R}from"./Container-zeFPXb1Q.js";import{b as w,S as z,a as F,d as M}from"./settings-section-HkZRSntL.js";import"./tooltip-XW5rFMNu.js";import"./X-CAquUT--.js";import"./constants-CMPjFkrZ.js";import"./card-CkFfla-m.js";import"./ArrowUpRight-Ds7CgDkL.js";function N(){const e=b.c(17),{org:t,project:s}=k(),o=E();let u;e[0]!==s.enabledPlugins?(u=s.enabledPlugins??[],e[0]=s.enabledPlugins,e[1]=u):u=e[1];const c=u,l=I();let m;e[2]!==t||e[3]!==s.slug||e[4]!==o?(m=()=>{o.invalidateQueries({queryKey:S.project(t.id,s.slug)}),o.invalidateQueries({queryKey:S.projects(t.id)}),o.invalidateQueries({predicate:n=>{const r=n.queryKey;return r[1]===t.id&&r[3]==="collection"&&r[4]==="VIRTUAL_MCP"}})},e[2]=t,e[3]=s.slug,e[4]=o,e[5]=m):m=e[5];const j=m;let g;e[6]!==j||e[7]!==l||e[8]!==c?(g=(n,r)=>{const d=new Set(c);r?d.add(n):d.delete(n),l.mutate({enabled_plugins:Array.from(d)},{onSuccess:j,onError:A})},e[6]=j,e[7]=l,e[8]=c,e[9]=g):g=e[9];const p=g,y=$,C=U;if(P.length===0){let n;return e[10]===Symbol.for("react.memo_cache_sentinel")?(n=i.jsx("p",{className:"text-sm text-muted-foreground",children:"No plugins available."}),e[10]=n):n=e[10],n}let a;e[11]!==p||e[12]!==l||e[13]!==c?(a=P.map(n=>{const r=y(n.id),d=C(n.id),h=c.includes(n.id);return i.jsx(w,{title:r?.label??n.id,description:d??void 0,icon:i.jsx("span",{className:"text-muted-foreground [&>svg]:size-4",children:r?.icon??i.jsx(R,{size:14})}),onClick:()=>!l.isPending&&p(n.id,!h),action:i.jsx(Q,{checked:h,onCheckedChange:v=>p(n.id,v),disabled:l.isPending,onClick:T})},n.id)}),e[11]=p,e[12]=l,e[13]=c,e[14]=a):a=e[14];let f;return e[15]!==a?(f=i.jsx(z,{children:i.jsx(F,{children:a})}),e[15]=a,e[16]=f):f=e[16],f}function T(e){return e.stopPropagation()}function U(e){return P.find(s=>s.id===e)?.description??null}function $(e){const t=K.find(o=>o.pluginId===e);if(t)return{label:t.label,icon:t.items[0]?.icon};const s=_.find(o=>o.pluginId===e);return s?{label:s.label,icon:s.icon}:null}function A(e){q.error("Failed to update plugin: "+(e instanceof Error?e.message:"Unknown error"))}function D(){const e=b.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=i.jsx(x,{children:i.jsx(x.Content,{children:i.jsx(x.Body,{children:i.jsxs(M,{children:[i.jsx(x.Title,{children:"Plugins"}),i.jsx(N,{})]})})})}),e[0]=t):t=e[0],t}function ee(){const e=b.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=i.jsx(D,{}),e[0]=t):t=e[0],t}export{ee as default};
@@ -1 +1 @@
1
- import{bW as b,e as f,j as c,D as C,r as d,c as p,aY as j,bX as v,bY as h}from"./index-BV4BlnS9.js";import{L as N}from"./label-CB1YxmGr.js";const E=b,g=d.createContext({}),M=t=>{const e=f.c(9);let s;e[0]!==t?({...s}=t,e[0]=t,e[1]=s):s=e[1];let o;e[2]!==s.name?(o={name:s.name},e[2]=s.name,e[3]=o):o=e[3];let n;e[4]!==s?(n=c.jsx(C,{...s}),e[4]=s,e[5]=n):n=e[5];let r;return e[6]!==o||e[7]!==n?(r=c.jsx(g.Provider,{value:o,children:n}),e[6]=o,e[7]=n,e[8]=r):r=e[8],r},x=()=>{const t=f.c(13),e=d.useContext(g),s=d.useContext($),{getFieldState:o}=v();let n;t[0]!==e.name?(n={name:e.name},t[0]=e.name,t[1]=n):n=t[1];const r=h(n);let a;t[2]!==e.name||t[3]!==r||t[4]!==o?(a=o(e.name,r),t[2]=e.name,t[3]=r,t[4]=o,t[5]=a):a=t[5];const l=a;if(!e)throw new Error("useFormField should be used within <FormField>");const{id:i}=s,m=`${i}-form-item`,F=`${i}-form-item-description`,I=`${i}-form-item-message`;let u;return t[6]!==e.name||t[7]!==l||t[8]!==i||t[9]!==m||t[10]!==F||t[11]!==I?(u={id:i,name:e.name,formItemId:m,formDescriptionId:F,formMessageId:I,...l},t[6]=e.name,t[7]=l,t[8]=i,t[9]=m,t[10]=F,t[11]=I,t[12]=u):u=t[12],u},$=d.createContext({});function w(t){const e=f.c(13);let s,o;e[0]!==t?({className:s,...o}=t,e[0]=t,e[1]=s,e[2]=o):(s=e[1],o=e[2]);const n=d.useId();let r;e[3]!==n?(r={id:n},e[3]=n,e[4]=r):r=e[4];let a;e[5]!==s?(a=p("grid gap-2",s),e[5]=s,e[6]=a):a=e[6];let l;e[7]!==o||e[8]!==a?(l=c.jsx("div",{"data-slot":"form-item",className:a,...o}),e[7]=o,e[8]=a,e[9]=l):l=e[9];let i;return e[10]!==r||e[11]!==l?(i=c.jsx($.Provider,{value:r,children:l}),e[10]=r,e[11]=l,e[12]=i):i=e[12],i}function L(t){const e=f.c(10);let s,o;e[0]!==t?({className:s,...o}=t,e[0]=t,e[1]=s,e[2]=o):(s=e[1],o=e[2]);const{error:n,formItemId:r}=x(),a=!!n;let l;e[3]!==s?(l=p("text-foreground data-[error=true]:text-destructive",s),e[3]=s,e[4]=l):l=e[4];let i;return e[5]!==r||e[6]!==o||e[7]!==a||e[8]!==l?(i=c.jsx(N,{"data-slot":"form-label","data-error":a,className:l,htmlFor:r,...o}),e[5]=r,e[6]=o,e[7]=a,e[8]=l,e[9]=i):i=e[9],i}function P(t){const e=f.c(7);let s;e[0]!==t?({...s}=t,e[0]=t,e[1]=s):s=e[1];const{error:o,formItemId:n,formDescriptionId:r,formMessageId:a}=x(),l=o?`${r} ${a}`:`${r}`,i=!!o;let m;return e[2]!==n||e[3]!==s||e[4]!==l||e[5]!==i?(m=c.jsx(j,{"data-slot":"form-control",id:n,"aria-describedby":l,"aria-invalid":i,...s}),e[2]=n,e[3]=s,e[4]=l,e[5]=i,e[6]=m):m=e[6],m}function y(t){const e=f.c(9);let s,o;e[0]!==t?({className:s,...o}=t,e[0]=t,e[1]=s,e[2]=o):(s=e[1],o=e[2]);const{formDescriptionId:n}=x();let r;e[3]!==s?(r=p("text-muted-foreground text-sm",s),e[3]=s,e[4]=r):r=e[4];let a;return e[5]!==n||e[6]!==o||e[7]!==r?(a=c.jsx("p",{"data-slot":"form-description",id:n,className:r,...o}),e[5]=n,e[6]=o,e[7]=r,e[8]=a):a=e[8],a}function R(t){const e=f.c(10);let s,o;e[0]!==t?({className:s,...o}=t,e[0]=t,e[1]=s,e[2]=o):(s=e[1],o=e[2]);const{error:n,formMessageId:r}=x(),a=n?String(n?.message??""):o.children;if(!a)return null;let l;e[3]!==s?(l=p("text-destructive text-sm",s),e[3]=s,e[4]=l):l=e[4];let i;return e[5]!==a||e[6]!==r||e[7]!==o||e[8]!==l?(i=c.jsx("p",{"data-slot":"form-message",id:r,className:l,...o,children:a}),e[5]=a,e[6]=r,e[7]=o,e[8]=l,e[9]=i):i=e[9],i}export{M as F,E as a,w as b,L as c,P as d,y as e,R as f};
1
+ import{bW as b,e as f,j as c,D as C,r as d,c as p,aY as j,bX as v,bY as h}from"./index-0dtUnOR1.js";import{L as N}from"./label-BGhcnROH.js";const E=b,g=d.createContext({}),M=t=>{const e=f.c(9);let s;e[0]!==t?({...s}=t,e[0]=t,e[1]=s):s=e[1];let o;e[2]!==s.name?(o={name:s.name},e[2]=s.name,e[3]=o):o=e[3];let n;e[4]!==s?(n=c.jsx(C,{...s}),e[4]=s,e[5]=n):n=e[5];let r;return e[6]!==o||e[7]!==n?(r=c.jsx(g.Provider,{value:o,children:n}),e[6]=o,e[7]=n,e[8]=r):r=e[8],r},x=()=>{const t=f.c(13),e=d.useContext(g),s=d.useContext($),{getFieldState:o}=v();let n;t[0]!==e.name?(n={name:e.name},t[0]=e.name,t[1]=n):n=t[1];const r=h(n);let a;t[2]!==e.name||t[3]!==r||t[4]!==o?(a=o(e.name,r),t[2]=e.name,t[3]=r,t[4]=o,t[5]=a):a=t[5];const l=a;if(!e)throw new Error("useFormField should be used within <FormField>");const{id:i}=s,m=`${i}-form-item`,F=`${i}-form-item-description`,I=`${i}-form-item-message`;let u;return t[6]!==e.name||t[7]!==l||t[8]!==i||t[9]!==m||t[10]!==F||t[11]!==I?(u={id:i,name:e.name,formItemId:m,formDescriptionId:F,formMessageId:I,...l},t[6]=e.name,t[7]=l,t[8]=i,t[9]=m,t[10]=F,t[11]=I,t[12]=u):u=t[12],u},$=d.createContext({});function w(t){const e=f.c(13);let s,o;e[0]!==t?({className:s,...o}=t,e[0]=t,e[1]=s,e[2]=o):(s=e[1],o=e[2]);const n=d.useId();let r;e[3]!==n?(r={id:n},e[3]=n,e[4]=r):r=e[4];let a;e[5]!==s?(a=p("grid gap-2",s),e[5]=s,e[6]=a):a=e[6];let l;e[7]!==o||e[8]!==a?(l=c.jsx("div",{"data-slot":"form-item",className:a,...o}),e[7]=o,e[8]=a,e[9]=l):l=e[9];let i;return e[10]!==r||e[11]!==l?(i=c.jsx($.Provider,{value:r,children:l}),e[10]=r,e[11]=l,e[12]=i):i=e[12],i}function L(t){const e=f.c(10);let s,o;e[0]!==t?({className:s,...o}=t,e[0]=t,e[1]=s,e[2]=o):(s=e[1],o=e[2]);const{error:n,formItemId:r}=x(),a=!!n;let l;e[3]!==s?(l=p("text-foreground data-[error=true]:text-destructive",s),e[3]=s,e[4]=l):l=e[4];let i;return e[5]!==r||e[6]!==o||e[7]!==a||e[8]!==l?(i=c.jsx(N,{"data-slot":"form-label","data-error":a,className:l,htmlFor:r,...o}),e[5]=r,e[6]=o,e[7]=a,e[8]=l,e[9]=i):i=e[9],i}function P(t){const e=f.c(7);let s;e[0]!==t?({...s}=t,e[0]=t,e[1]=s):s=e[1];const{error:o,formItemId:n,formDescriptionId:r,formMessageId:a}=x(),l=o?`${r} ${a}`:`${r}`,i=!!o;let m;return e[2]!==n||e[3]!==s||e[4]!==l||e[5]!==i?(m=c.jsx(j,{"data-slot":"form-control",id:n,"aria-describedby":l,"aria-invalid":i,...s}),e[2]=n,e[3]=s,e[4]=l,e[5]=i,e[6]=m):m=e[6],m}function y(t){const e=f.c(9);let s,o;e[0]!==t?({className:s,...o}=t,e[0]=t,e[1]=s,e[2]=o):(s=e[1],o=e[2]);const{formDescriptionId:n}=x();let r;e[3]!==s?(r=p("text-muted-foreground text-sm",s),e[3]=s,e[4]=r):r=e[4];let a;return e[5]!==n||e[6]!==o||e[7]!==r?(a=c.jsx("p",{"data-slot":"form-description",id:n,className:r,...o}),e[5]=n,e[6]=o,e[7]=r,e[8]=a):a=e[8],a}function R(t){const e=f.c(10);let s,o;e[0]!==t?({className:s,...o}=t,e[0]=t,e[1]=s,e[2]=o):(s=e[1],o=e[2]);const{error:n,formMessageId:r}=x(),a=n?String(n?.message??""):o.children;if(!a)return null;let l;e[3]!==s?(l=p("text-destructive text-sm",s),e[3]=s,e[4]=l):l=e[4];let i;return e[5]!==a||e[6]!==r||e[7]!==o||e[8]!==l?(i=c.jsx("p",{"data-slot":"form-message",id:r,className:l,...o,children:a}),e[5]=a,e[6]=r,e[7]=o,e[8]=l,e[9]=i):i=e[9],i}export{M as F,E as a,w as b,L as c,P as d,y as e,R as f};
@@ -1 +1 @@
1
- import{f as re,s as ce,o as de,z as me,C as ue,a as fe,t as Y,x as K,K as te,j as s,D as se,H as ge,J as W,e as $,r as H,B as G,c as xe,M as pe}from"./index-BV4BlnS9.js";import{P as V}from"./index-AqmdpH5c.js";import{u as he}from"./use-org-auth-client-Hwc_S6Fw.js";import{u as je}from"./use-debounced-autosave-BliXkuEQ.js";import{A as be}from"./avatar-D0sdobqD.js";import{I as ve}from"./input-Bs7mkNsF.js";import{S as X,a as Z,b as Q,c as Se,d as ye}from"./settings-section-DJf4hau9.js";import{D as Ne}from"./domain-settings-CckaLtjm.js";import{u as Ce,a as ne,D as we,c as _e,S as ze,v as De,K as Ae,P as Pe,d as ke,C as Ie,s as Ee,b as Te,e as Oe}from"./collection-search-bjPRZI3g.js";import{W as ee,i as Re}from"./constants-Dm1wnwL3.js";import{b as le}from"./use-virtual-mcp-BR6mzHHD.js";import{b as Le,P as $e,a as Fe}from"./popover-9-i1guS1.js";import{S as Me}from"./skeleton-DLT024S3.js";import{y as Be}from"./agent-icon-C2zAhw3X.js";import{s as He}from"./Plus-BYimMcAW.js";import{a as ae}from"./Users03-CIZBy7k3.js";import{i as Ke}from"./X-QdBx5oCM.js";import{I as J}from"./integration-icon-DgJZ63kl.js";import{u as Ue,c as qe}from"./use-organization-settings-gFwljgrZ.js";import"./tooltip-DZT-1bal.js";import"./User01-7U7nAEDg.js";import"./card-BGZ5LqAO.js";import"./ArrowUpRight-B9s_0HcJ.js";import"./unwrap-tool-result-BYXdCQMg.js";import"./switch-ChOgiOZl.js";import"./SearchMd-DzMVdOJP.js";import"./use-collections-ASqcb463.js";import"./AlertCircle-4Fij-rVg.js";import"./Tool01-DVcjHQGB.js";import"./XClose-BdbZPqCd.js";import"./RefreshCcw01-DIY3NFBI.js";import"./ArrowNarrowLeft-CxNzupMt.js";import"./XCircle-DokNvYvs.js";import"./ZapSquare-CnxL4Bs1.js";import"./CheckCircle-ROoANe3f.js";import"./Check-DC_iCN8Z.js";import"./ChevronDown-CnUhTqwX.js";import"./ChevronRight-X2lm_E9M.js";import"./ChevronUp-CgOfWCZA.js";import"./DotsVertical-C2-ev8jy.js";import"./Container-BrskPoE3.js";import"./Star01-iULH34rV.js";import"./Palette-CmZGtCez.js";import"./LinkExternal01-Bhhv-wHj.js";import"./Lock01-KbqVCyA7.js";import"./Sun-Dc78AQrj.js";import"./Play-EPgISV5B.js";import"./Settings02-BxmxMTOA.js";import"./Shield01-B9vNkAc4.js";import"./Trash01-CaZrP0UV.js";import"./Zap-DH1KrJ0w.js";const Ve=ge({name:W().min(1,"Name is required").max(255,"Name is too long"),slug:W().min(1,"Slug is required").max(50,"Slug is too long").regex(/^[a-z0-9-]+$/,"Slug must contain only lowercase letters, numbers, and hyphens"),logo:W().optional()});function Ge(t){const e=$.c(13),{value:a,onChange:l,name:r,disabled:d}=t,n=H.useRef(null);let h;e[0]===Symbol.for("react.memo_cache_sentinel")?(h=()=>n.current?.click(),e[0]=h):h=e[0];const m=h;let b;e[1]!==l?(b=z=>{const x=z.target.files?.[0];if(!x)return;if(x.size>2097152){K.error("Image must be smaller than 2MB");return}const v=new FileReader;v.onerror=We,v.onloadend=()=>{v.result&&l(v.result),n.current&&(n.current.value="")},v.readAsDataURL(x)},e[1]=l,e[2]=b):b=e[2];const o=b;let i;e[3]!==d||e[4]!==o?(i=s.jsx("input",{ref:n,type:"file",accept:"image/*",onChange:o,className:"hidden",disabled:d}),e[3]=d,e[4]=o,e[5]=i):i=e[5];const u=a||void 0,j=r??"?";let f;e[6]!==u||e[7]!==j?(f=s.jsx(be,{url:u,fallback:j,shape:"square",size:"base"}),e[6]=u,e[7]=j,e[8]=f):f=e[8];let g;return e[9]!==d||e[10]!==i||e[11]!==f?(g=s.jsxs("button",{type:"button",onClick:m,disabled:d,className:"rounded-lg overflow-hidden hover:ring-2 hover:ring-border transition-all disabled:opacity-50","aria-label":"Upload organization logo",children:[i,f]}),e[9]=d,e[10]=i,e[11]=f,e[12]=g):g=e[12],g}function We(){return K.error("Failed to read image")}function Qe(){const t=re(),{org:e}=ce(),a=he(),l=de(),r=me({resolver:ue(Ve),values:{name:e.name??"",slug:e.slug??"",logo:e.logo??""}}),d=fe({mutationFn:async o=>{const i={name:o.name,slug:o.slug};o.logo&&(i.logo=o.logo);const u=await a.organization.update({data:i});if(u?.error)throw new Error(u.error.message||"Failed to update organization");return u},onSuccess:(o,i)=>{Y("organization_settings_updated",{organization_id:e.id,fields:Object.keys(i)}),l.invalidateQueries({queryKey:te.organizations()}),l.invalidateQueries({queryKey:te.activeOrganization(e.slug)}),o?.data?.slug&&o.data.slug!==e.slug&&t({to:"/$org/settings/general",params:{org:o.data.slug}})},onError:(o,i)=>{Y("organization_settings_update_failed",{organization_id:e.id,fields:Object.keys(i),error:o instanceof Error?o.message:String(o)}),K.error(o instanceof Error?o.message:"Failed to update organization")}}),{schedule:n,flush:h}=je({save:async()=>{!r.formState.isDirty||!await r.trigger()||await d.mutateAsync(r.getValues())}}),m=r.formState.errors,b=typeof window<"u"?`${window.location.host}/`:"";return s.jsx(X,{children:s.jsxs(Z,{children:[s.jsx(Q,{title:"Logo",description:"Recommended size is 256x256px",action:s.jsx(Ge,{value:r.watch("logo"),onChange:o=>{r.setValue("logo",o??"",{shouldDirty:!0}),h()},name:r.watch("name")})}),s.jsx(Q,{title:"Name",action:s.jsx(se,{control:r.control,name:"name",render:({field:o})=>s.jsx(ve,{id:"org-name",...o,onChange:i=>{o.onChange(i),n()},onBlur:()=>{o.onBlur(),h()},placeholder:"Organization name",className:"w-[280px]"})})}),s.jsx(Q,{title:"URL",action:s.jsxs("div",{className:"flex items-center w-[280px] rounded-md border border-input bg-input/30 focus-within:ring-2 focus-within:ring-ring/50 overflow-hidden",children:[b&&s.jsx("span",{className:"pl-3 text-sm text-muted-foreground select-none",children:b}),s.jsx(se,{control:r.control,name:"slug",render:({field:o})=>s.jsx("input",{id:"org-slug",value:o.value??"",name:o.name,ref:o.ref,placeholder:"my-organization",className:"flex-1 min-w-0 bg-transparent px-2 py-1.5 text-sm text-foreground placeholder:text-muted-foreground/60 outline-none",onChange:i=>{const u=i.target.value.toLowerCase().replace(/[^a-z0-9-]/g,"");r.setValue("slug",u,{shouldDirty:!0,shouldTouch:!0,shouldValidate:!0}),n()},onBlur:()=>{o.onBlur(),h()}})})]})}),(m.name||m.slug||m.logo)&&s.jsxs("div",{className:"px-5 pb-3 flex flex-col gap-1",children:[m.name&&s.jsx("p",{className:"text-xs text-destructive",children:m.name.message}),m.slug&&s.jsx("p",{className:"text-xs text-destructive",children:m.slug.message}),m.logo&&s.jsx("p",{className:"text-xs text-destructive",children:m.logo.message})]})]})})}const oe=["site-editor","site-diagnostics","ai-image","ai-research"],ie=8;function Ye(t,e,a){const l=e.find(d=>d.id===t);if(l)return{id:l.id,title:l.title,icon:l.icon,kind:"template"};const r=a.find(d=>d.id===t);return r?{id:t,title:r.title,icon:r.icon??null,kind:"custom"}:{id:t,title:t,icon:null,kind:"missing"}}function Je(t){const e=$.c(39),{agent:a,onRemove:l}=t;let r;e[0]!==a.id?(r={id:a.id},e[0]=a.id,e[1]=r):r=e[1];const{attributes:d,listeners:n,setNodeRef:h,transform:m,transition:b,isDragging:o}=ke(r);let i;e[2]!==m?(i=Ie.Transform.toString(m),e[2]=m,e[3]=i):i=e[3];const u=o?.5:void 0,j=o?100:void 0;let f;e[4]!==i||e[5]!==u||e[6]!==j||e[7]!==b?(f={transform:i,transition:b,opacity:u,zIndex:j},e[4]=i,e[5]=u,e[6]=j,e[7]=b,e[8]=f):f=e[8];const g=f,z=o&&"shadow-lg";let x;e[9]!==z?(x=xe("flex items-center gap-3 px-3 py-2 rounded-lg border border-border bg-background",z),e[9]=z,e[10]=x):x=e[10];const v=`Drag to reorder ${a.title}`;let D;e[11]===Symbol.for("react.memo_cache_sentinel")?(D=s.jsx(Be,{size:14}),e[11]=D):D=e[11];let k;e[12]!==d||e[13]!==n||e[14]!==v?(k=s.jsx("button",{type:"button",...d,...n,className:"text-muted-foreground hover:text-foreground cursor-grab active:cursor-grabbing","aria-label":v,children:D}),e[12]=d,e[13]=n,e[14]=v,e[15]=k):k=e[15];let N;e[16]===Symbol.for("react.memo_cache_sentinel")?(N=s.jsx(ae,{size:14}),e[16]=N):N=e[16];let w;e[17]!==a.icon||e[18]!==a.title?(w=s.jsx(J,{icon:a.icon,name:a.title,size:"xs",fallbackIcon:N}),e[17]=a.icon,e[18]=a.title,e[19]=w):w=e[19];let S;e[20]!==a.title?(S=s.jsx("span",{className:"text-sm text-foreground truncate",children:a.title}),e[20]=a.title,e[21]=S):S=e[21];const _=a.kind==="template"?"Template":a.kind==="custom"?"Custom agent":"Unavailable";let p;e[22]!==_?(p=s.jsx("span",{className:"text-xs text-muted-foreground",children:_}),e[22]=_,e[23]=p):p=e[23];let y;e[24]!==S||e[25]!==p?(y=s.jsxs("div",{className:"flex flex-col min-w-0 flex-1",children:[S,p]}),e[24]=S,e[25]=p,e[26]=y):y=e[26];const I=`Remove ${a.title}`;let A;e[27]===Symbol.for("react.memo_cache_sentinel")?(A=s.jsx(Ke,{size:14}),e[27]=A):A=e[27];let C;e[28]!==l||e[29]!==I?(C=s.jsx("button",{type:"button",onClick:l,className:"text-muted-foreground hover:text-foreground p-1 rounded","aria-label":I,children:A}),e[28]=l,e[29]=I,e[30]=C):C=e[30];let P;return e[31]!==h||e[32]!==g||e[33]!==k||e[34]!==w||e[35]!==y||e[36]!==C||e[37]!==x?(P=s.jsxs("div",{ref:h,style:g,className:x,children:[k,w,y,C]}),e[31]=h,e[32]=g,e[33]=k,e[34]=w,e[35]=y,e[36]=C,e[37]=x,e[38]=P):P=e[38],P}function Xe(t){const e=$.c(48),{selectedIds:a,onAdd:l}=t,[r,d]=H.useState(!1),[n,h]=H.useState(""),m=le();let b;e[0]!==a?(b=new Set(a),e[0]=a,e[1]=b):b=e[1];const o=b;let i,u,j,f,g,z,x,v,D,k,N,w,S;if(e[2]!==m||e[3]!==l||e[4]!==r||e[5]!==n||e[6]!==o){const A=n.toLowerCase();f=ee.filter(c=>!o.has(c.id)&&(!n||c.title.toLowerCase().includes(A)));let C;e[20]!==o?(C=c=>c.id!==null&&!Re(c.id)&&!o.has(c.id),e[20]=o,e[21]=C):C=e[21],j=m.filter(C).filter(c=>!n||c.title.toLowerCase().includes(A));let P;e[22]!==l?(P=c=>{l(c),d(!1),h("")},e[22]=l,e[23]=P):P=e[23];const T=P;u=Le,w=r,S=d,e[24]===Symbol.for("react.memo_cache_sentinel")?(g=s.jsx($e,{asChild:!0,children:s.jsxs(G,{type:"button",variant:"outline",size:"sm",children:[s.jsx(He,{size:14}),"Add agent"]})}),e[24]=g):g=e[24],i=Fe,D="w-[320px] p-0 overflow-hidden",k="start",e[25]!==n?(N=s.jsx(Oe,{value:n,onChange:h,placeholder:"Search agents..."}),e[25]=n,e[26]=N):N=e[26],z="max-h-[320px] overflow-y-auto p-2 flex flex-col gap-3",x=f.length>0&&s.jsxs("div",{className:"flex flex-col gap-1",children:[s.jsx("span",{className:"text-xs font-medium text-muted-foreground px-1",children:"Templates"}),f.map(c=>s.jsxs("button",{type:"button",onClick:()=>T(c.id),className:"flex items-center gap-2 px-2 py-1.5 rounded-md hover:bg-accent text-left",children:[s.jsx(J,{icon:c.icon,name:c.title,size:"xs"}),s.jsx("span",{className:"text-sm truncate",children:c.title})]},c.id))]}),v=j.length>0&&s.jsxs("div",{className:"flex flex-col gap-1",children:[s.jsx("span",{className:"text-xs font-medium text-muted-foreground px-1",children:"Custom agents"}),j.map(c=>s.jsxs("button",{type:"button",onClick:()=>T(c.id),className:"flex items-center gap-2 px-2 py-1.5 rounded-md hover:bg-accent text-left",children:[s.jsx(J,{icon:c.icon,name:c.title,size:"xs",fallbackIcon:s.jsx(ae,{size:14})}),s.jsx("span",{className:"text-sm truncate",children:c.title})]},c.id))]}),e[2]=m,e[3]=l,e[4]=r,e[5]=n,e[6]=o,e[7]=i,e[8]=u,e[9]=j,e[10]=f,e[11]=g,e[12]=z,e[13]=x,e[14]=v,e[15]=D,e[16]=k,e[17]=N,e[18]=w,e[19]=S}else i=e[7],u=e[8],j=e[9],f=e[10],g=e[11],z=e[12],x=e[13],v=e[14],D=e[15],k=e[16],N=e[17],w=e[18],S=e[19];let _;e[27]!==j||e[28]!==f.length||e[29]!==n?(_=f.length===0&&j.length===0&&s.jsx("div",{className:"text-xs text-muted-foreground text-center py-6",children:n?"No agents found":"All agents are already added"}),e[27]=j,e[28]=f.length,e[29]=n,e[30]=_):_=e[30];let p;e[31]!==_||e[32]!==z||e[33]!==x||e[34]!==v?(p=s.jsxs("div",{className:z,children:[x,v,_]}),e[31]=_,e[32]=z,e[33]=x,e[34]=v,e[35]=p):p=e[35];let y;e[36]!==i||e[37]!==p||e[38]!==D||e[39]!==k||e[40]!==N?(y=s.jsxs(i,{className:D,align:k,children:[N,p]}),e[36]=i,e[37]=p,e[38]=D,e[39]=k,e[40]=N,e[41]=y):y=e[41];let I;return e[42]!==u||e[43]!==g||e[44]!==y||e[45]!==w||e[46]!==S?(I=s.jsxs(u,{open:w,onOpenChange:S,children:[g,y]}),e[42]=u,e[43]=g,e[44]=y,e[45]=w,e[46]=S,e[47]=I):I=e[47],I}function Ze(){const t=$.c(61),e=Ue(),a=le(),l=qe();let r;t[0]!==e?.ids?(r=e?.ids??[...oe],t[0]=e?.ids,t[1]=r):r=t[1];const d=r,[n,h]=H.useState(d);let m;t[2]!==n||t[3]!==d?(m=n.length!==d.length||n.some((E,O)=>E!==d[O]),t[2]=n,t[3]=d,t[4]=m):m=t[4];const b=m;let o;t[5]===Symbol.for("react.memo_cache_sentinel")?(o={activationConstraint:{distance:5}},t[5]=o):o=t[5];let i;t[6]===Symbol.for("react.memo_cache_sentinel")?(i={coordinateGetter:Ee},t[6]=i):i=t[6];const u=Ce(ne(Pe,o),ne(Ae,i));let j;t[7]!==n?(j=E=>{const{active:O,over:R}=E;if(!R||O.id===R.id)return;const L=n.indexOf(O.id),q=n.indexOf(R.id);L===-1||q===-1||h(Te([...n],L,q))},t[7]=n,t[8]=j):j=t[8];const f=j;let g;t[9]!==n?(g=E=>{n.includes(E)||h([...n,E])},t[9]=n,t[10]=g):g=t[10];const z=g;let x;t[11]!==n?(x=E=>{h(n.filter(O=>O!==E))},t[11]=n,t[12]=x):x=t[12];const v=x;let D;t[13]===Symbol.for("react.memo_cache_sentinel")?(D=()=>{h([...oe])},t[13]=D):D=t[13];const k=D;let N;t[14]!==n||t[15]!==l?(N=()=>{l.mutate({ids:n},{onSuccess:()=>{Y("default_home_agents_updated",{count:n.length,template_count:n.filter(tt).length}),K.success("Default home agents updated")},onError:et})},t[14]=n,t[15]=l,t[16]=N):N=t[16];const w=N;let S,_,p,y,I,A,C;if(t[17]!==a||t[18]!==n||t[19]!==f||t[20]!==v||t[21]!==u||t[22]!==l.isPending){let E;t[30]!==a?(E=L=>Ye(L,ee,a),t[30]=a,t[31]=E):E=t[31];const O=n.map(E);p=Math.max(0,n.length-ie),_=X,I="Default home agents";let R;t[32]===Symbol.for("react.memo_cache_sentinel")?(R=s.jsx(pe,{size:14}),t[32]=R):R=t[32],t[33]!==l.isPending?(A=s.jsxs(G,{type:"button",variant:"ghost",size:"sm",onClick:k,disabled:l.isPending,children:[R,"Reset defaults"]}),t[33]=l.isPending,t[34]=A):A=t[34],S=Z,C="px-5 py-5 flex flex-col gap-3",y=O.length===0?s.jsx("div",{className:"rounded-lg border border-dashed border-border p-6 text-center text-xs text-muted-foreground",children:'No agents selected. The home view will only show "Create agent".'}):s.jsx(we,{sensors:u,collisionDetection:_e,onDragEnd:f,children:s.jsx(ze,{items:n,strategy:De,children:s.jsx("div",{className:"flex flex-col gap-1.5",children:O.map((L,q)=>s.jsxs("div",{className:"flex flex-col gap-1.5",children:[q===ie&&s.jsxs("div",{className:"flex items-center gap-2 px-1 py-1 text-xs text-muted-foreground",children:[s.jsx("div",{className:"flex-1 h-px bg-border"}),s.jsx("span",{children:"Below this line is hidden on the home view"}),s.jsx("div",{className:"flex-1 h-px bg-border"})]}),s.jsx(Je,{agent:L,onRemove:()=>v(L.id)})]},L.id))})})}),t[17]=a,t[18]=n,t[19]=f,t[20]=v,t[21]=u,t[22]=l.isPending,t[23]=S,t[24]=_,t[25]=p,t[26]=y,t[27]=I,t[28]=A,t[29]=C}else S=t[23],_=t[24],p=t[25],y=t[26],I=t[27],A=t[28],C=t[29];let P;t[35]!==n||t[36]!==z?(P=s.jsx(Xe,{selectedIds:n,onAdd:z}),t[35]=n,t[36]=z,t[37]=P):P=t[37];let T;t[38]!==p?(T=p>0&&s.jsxs("span",{className:"text-xs text-muted-foreground",children:[p," agent",p===1?"":"s"," won't fit on the home view"]}),t[38]=p,t[39]=T):T=t[39];let c;t[40]!==P||t[41]!==T?(c=s.jsxs("div",{className:"flex items-center justify-between",children:[P,T]}),t[40]=P,t[41]=T,t[42]=c):c=t[42];let F;t[43]!==y||t[44]!==c||t[45]!==C?(F=s.jsxs("div",{className:C,children:[y,c]}),t[43]=y,t[44]=c,t[45]=C,t[46]=F):F=t[46];let M;t[47]!==w||t[48]!==d||t[49]!==b||t[50]!==l.isPending?(M=b&&s.jsxs(Se,{children:[s.jsx(G,{type:"button",variant:"outline",onClick:()=>h(d),disabled:l.isPending,children:"Cancel"}),s.jsx(G,{type:"button",onClick:w,disabled:l.isPending,children:l.isPending?"Saving…":"Save"})]}),t[47]=w,t[48]=d,t[49]=b,t[50]=l.isPending,t[51]=M):M=t[51];let B;t[52]!==S||t[53]!==F||t[54]!==M?(B=s.jsxs(S,{children:[F,M]}),t[52]=S,t[53]=F,t[54]=M,t[55]=B):B=t[55];let U;return t[56]!==_||t[57]!==I||t[58]!==A||t[59]!==B?(U=s.jsx(_,{title:I,actions:A,children:B}),t[56]=_,t[57]=I,t[58]=A,t[59]=B,t[60]=U):U=t[60],U}function et(t){K.error(t instanceof Error?t.message:"Failed to update default home agents")}function tt(t){return ee.some(e=>e.id===t)}function st(){const t=$.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(X,{title:"Default home agents",children:s.jsx(Z,{children:s.jsx("div",{className:"px-5 py-5 flex flex-col gap-2",children:Array.from({length:4}).map(nt)})})}),t[0]=e):e=t[0],e}function nt(t,e){return s.jsx(Me,{className:"h-12 w-full rounded-lg"},e)}function ot(){const t=$.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(H.Suspense,{fallback:s.jsx(st,{}),children:s.jsx(Ze,{})}),t[0]=e):e=t[0],e}function it(){const t=$.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(V,{children:s.jsx(V.Content,{children:s.jsx(V.Body,{children:s.jsxs(ye,{children:[s.jsx(V.Title,{children:"Organization"}),s.jsx(Qe,{}),s.jsx(Ne,{}),s.jsx(ot,{})]})})})}),t[0]=e):e=t[0],e}function ns(){const t=$.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(it,{}),t[0]=e):e=t[0],e}export{ns as default};
1
+ import{f as re,s as ce,o as de,z as me,C as ue,a as fe,t as Y,x as K,K as te,j as s,D as se,H as ge,J as W,e as $,r as H,B as G,c as xe,M as pe}from"./index-0dtUnOR1.js";import{P as V}from"./index-CGKwbcyW.js";import{u as he}from"./use-org-auth-client-CPZNMqkZ.js";import{u as je}from"./use-debounced-autosave-BFE3ZeG7.js";import{A as be}from"./avatar-JoKAxyik.js";import{I as ve}from"./input-Dh3J6cxA.js";import{S as X,a as Z,b as Q,c as Se,d as ye}from"./settings-section-HkZRSntL.js";import{D as Ne}from"./domain-settings-BEv8OnaD.js";import{u as Ce,a as ne,D as we,c as _e,S as ze,v as De,K as Ae,P as Pe,d as ke,C as Ie,s as Ee,b as Te,e as Oe}from"./collection-search-BHyuqRiT.js";import{W as ee,i as Re}from"./constants-CMPjFkrZ.js";import{b as le}from"./use-virtual-mcp-Dndzl8Kr.js";import{b as Le,P as $e,a as Fe}from"./popover-D4Clv1Kb.js";import{S as Me}from"./skeleton-BxQRt9FI.js";import{y as Be}from"./agent-icon-D9odI-qh.js";import{s as He}from"./Plus-28zZOE9T.js";import{a as ae}from"./Users03-rbWg-6tV.js";import{i as Ke}from"./X-CAquUT--.js";import{I as J}from"./integration-icon-CDE9CENl.js";import{u as Ue,c as qe}from"./use-organization-settings-CoHf1k_t.js";import"./tooltip-XW5rFMNu.js";import"./User01-DKnZn118.js";import"./card-CkFfla-m.js";import"./ArrowUpRight-Ds7CgDkL.js";import"./unwrap-tool-result-BYXdCQMg.js";import"./switch-DydlPJmA.js";import"./SearchMd-BpRj1P2W.js";import"./use-collections-BLOTVIAP.js";import"./AlertCircle-Cb7fTEMa.js";import"./Tool01-Cu4I31F8.js";import"./XClose-_Y5VAjW5.js";import"./RefreshCcw01-CCzpYBs0.js";import"./ArrowNarrowLeft-tcEBzg5K.js";import"./XCircle-B-00qJpY.js";import"./ZapSquare-Cpo7Z7gP.js";import"./CheckCircle-rZ5sDOOP.js";import"./Check-Dgq0jjpz.js";import"./ChevronDown-CH5lQohM.js";import"./ChevronRight-DfFDUpKj.js";import"./ChevronUp-DCsRkih0.js";import"./DotsVertical-BljfGuhu.js";import"./Container-zeFPXb1Q.js";import"./Star01-ChekdAzX.js";import"./Palette-CURRsupy.js";import"./LinkExternal01-MvI2bZbP.js";import"./Lock01-CidilFiJ.js";import"./Sun-TuktgENq.js";import"./Play-DLW6aJFn.js";import"./Settings02-CE5ZLw2I.js";import"./Shield01-Dtb2_AeI.js";import"./Trash01-4Dq6ympL.js";import"./Zap-B8xnzkap.js";const Ve=ge({name:W().min(1,"Name is required").max(255,"Name is too long"),slug:W().min(1,"Slug is required").max(50,"Slug is too long").regex(/^[a-z0-9-]+$/,"Slug must contain only lowercase letters, numbers, and hyphens"),logo:W().optional()});function Ge(t){const e=$.c(13),{value:a,onChange:l,name:r,disabled:d}=t,n=H.useRef(null);let h;e[0]===Symbol.for("react.memo_cache_sentinel")?(h=()=>n.current?.click(),e[0]=h):h=e[0];const m=h;let b;e[1]!==l?(b=z=>{const x=z.target.files?.[0];if(!x)return;if(x.size>2097152){K.error("Image must be smaller than 2MB");return}const v=new FileReader;v.onerror=We,v.onloadend=()=>{v.result&&l(v.result),n.current&&(n.current.value="")},v.readAsDataURL(x)},e[1]=l,e[2]=b):b=e[2];const o=b;let i;e[3]!==d||e[4]!==o?(i=s.jsx("input",{ref:n,type:"file",accept:"image/*",onChange:o,className:"hidden",disabled:d}),e[3]=d,e[4]=o,e[5]=i):i=e[5];const u=a||void 0,j=r??"?";let f;e[6]!==u||e[7]!==j?(f=s.jsx(be,{url:u,fallback:j,shape:"square",size:"base"}),e[6]=u,e[7]=j,e[8]=f):f=e[8];let g;return e[9]!==d||e[10]!==i||e[11]!==f?(g=s.jsxs("button",{type:"button",onClick:m,disabled:d,className:"rounded-lg overflow-hidden hover:ring-2 hover:ring-border transition-all disabled:opacity-50","aria-label":"Upload organization logo",children:[i,f]}),e[9]=d,e[10]=i,e[11]=f,e[12]=g):g=e[12],g}function We(){return K.error("Failed to read image")}function Qe(){const t=re(),{org:e}=ce(),a=he(),l=de(),r=me({resolver:ue(Ve),values:{name:e.name??"",slug:e.slug??"",logo:e.logo??""}}),d=fe({mutationFn:async o=>{const i={name:o.name,slug:o.slug};o.logo&&(i.logo=o.logo);const u=await a.organization.update({data:i});if(u?.error)throw new Error(u.error.message||"Failed to update organization");return u},onSuccess:(o,i)=>{Y("organization_settings_updated",{organization_id:e.id,fields:Object.keys(i)}),l.invalidateQueries({queryKey:te.organizations()}),l.invalidateQueries({queryKey:te.activeOrganization(e.slug)}),o?.data?.slug&&o.data.slug!==e.slug&&t({to:"/$org/settings/general",params:{org:o.data.slug}})},onError:(o,i)=>{Y("organization_settings_update_failed",{organization_id:e.id,fields:Object.keys(i),error:o instanceof Error?o.message:String(o)}),K.error(o instanceof Error?o.message:"Failed to update organization")}}),{schedule:n,flush:h}=je({save:async()=>{!r.formState.isDirty||!await r.trigger()||await d.mutateAsync(r.getValues())}}),m=r.formState.errors,b=typeof window<"u"?`${window.location.host}/`:"";return s.jsx(X,{children:s.jsxs(Z,{children:[s.jsx(Q,{title:"Logo",description:"Recommended size is 256x256px",action:s.jsx(Ge,{value:r.watch("logo"),onChange:o=>{r.setValue("logo",o??"",{shouldDirty:!0}),h()},name:r.watch("name")})}),s.jsx(Q,{title:"Name",action:s.jsx(se,{control:r.control,name:"name",render:({field:o})=>s.jsx(ve,{id:"org-name",...o,onChange:i=>{o.onChange(i),n()},onBlur:()=>{o.onBlur(),h()},placeholder:"Organization name",className:"w-[280px]"})})}),s.jsx(Q,{title:"URL",action:s.jsxs("div",{className:"flex items-center w-[280px] rounded-md border border-input bg-input/30 focus-within:ring-2 focus-within:ring-ring/50 overflow-hidden",children:[b&&s.jsx("span",{className:"pl-3 text-sm text-muted-foreground select-none",children:b}),s.jsx(se,{control:r.control,name:"slug",render:({field:o})=>s.jsx("input",{id:"org-slug",value:o.value??"",name:o.name,ref:o.ref,placeholder:"my-organization",className:"flex-1 min-w-0 bg-transparent px-2 py-1.5 text-sm text-foreground placeholder:text-muted-foreground/60 outline-none",onChange:i=>{const u=i.target.value.toLowerCase().replace(/[^a-z0-9-]/g,"");r.setValue("slug",u,{shouldDirty:!0,shouldTouch:!0,shouldValidate:!0}),n()},onBlur:()=>{o.onBlur(),h()}})})]})}),(m.name||m.slug||m.logo)&&s.jsxs("div",{className:"px-5 pb-3 flex flex-col gap-1",children:[m.name&&s.jsx("p",{className:"text-xs text-destructive",children:m.name.message}),m.slug&&s.jsx("p",{className:"text-xs text-destructive",children:m.slug.message}),m.logo&&s.jsx("p",{className:"text-xs text-destructive",children:m.logo.message})]})]})})}const oe=["site-editor","site-diagnostics","ai-image","ai-research"],ie=8;function Ye(t,e,a){const l=e.find(d=>d.id===t);if(l)return{id:l.id,title:l.title,icon:l.icon,kind:"template"};const r=a.find(d=>d.id===t);return r?{id:t,title:r.title,icon:r.icon??null,kind:"custom"}:{id:t,title:t,icon:null,kind:"missing"}}function Je(t){const e=$.c(39),{agent:a,onRemove:l}=t;let r;e[0]!==a.id?(r={id:a.id},e[0]=a.id,e[1]=r):r=e[1];const{attributes:d,listeners:n,setNodeRef:h,transform:m,transition:b,isDragging:o}=ke(r);let i;e[2]!==m?(i=Ie.Transform.toString(m),e[2]=m,e[3]=i):i=e[3];const u=o?.5:void 0,j=o?100:void 0;let f;e[4]!==i||e[5]!==u||e[6]!==j||e[7]!==b?(f={transform:i,transition:b,opacity:u,zIndex:j},e[4]=i,e[5]=u,e[6]=j,e[7]=b,e[8]=f):f=e[8];const g=f,z=o&&"shadow-lg";let x;e[9]!==z?(x=xe("flex items-center gap-3 px-3 py-2 rounded-lg border border-border bg-background",z),e[9]=z,e[10]=x):x=e[10];const v=`Drag to reorder ${a.title}`;let D;e[11]===Symbol.for("react.memo_cache_sentinel")?(D=s.jsx(Be,{size:14}),e[11]=D):D=e[11];let k;e[12]!==d||e[13]!==n||e[14]!==v?(k=s.jsx("button",{type:"button",...d,...n,className:"text-muted-foreground hover:text-foreground cursor-grab active:cursor-grabbing","aria-label":v,children:D}),e[12]=d,e[13]=n,e[14]=v,e[15]=k):k=e[15];let N;e[16]===Symbol.for("react.memo_cache_sentinel")?(N=s.jsx(ae,{size:14}),e[16]=N):N=e[16];let w;e[17]!==a.icon||e[18]!==a.title?(w=s.jsx(J,{icon:a.icon,name:a.title,size:"xs",fallbackIcon:N}),e[17]=a.icon,e[18]=a.title,e[19]=w):w=e[19];let S;e[20]!==a.title?(S=s.jsx("span",{className:"text-sm text-foreground truncate",children:a.title}),e[20]=a.title,e[21]=S):S=e[21];const _=a.kind==="template"?"Template":a.kind==="custom"?"Custom agent":"Unavailable";let p;e[22]!==_?(p=s.jsx("span",{className:"text-xs text-muted-foreground",children:_}),e[22]=_,e[23]=p):p=e[23];let y;e[24]!==S||e[25]!==p?(y=s.jsxs("div",{className:"flex flex-col min-w-0 flex-1",children:[S,p]}),e[24]=S,e[25]=p,e[26]=y):y=e[26];const I=`Remove ${a.title}`;let A;e[27]===Symbol.for("react.memo_cache_sentinel")?(A=s.jsx(Ke,{size:14}),e[27]=A):A=e[27];let C;e[28]!==l||e[29]!==I?(C=s.jsx("button",{type:"button",onClick:l,className:"text-muted-foreground hover:text-foreground p-1 rounded","aria-label":I,children:A}),e[28]=l,e[29]=I,e[30]=C):C=e[30];let P;return e[31]!==h||e[32]!==g||e[33]!==k||e[34]!==w||e[35]!==y||e[36]!==C||e[37]!==x?(P=s.jsxs("div",{ref:h,style:g,className:x,children:[k,w,y,C]}),e[31]=h,e[32]=g,e[33]=k,e[34]=w,e[35]=y,e[36]=C,e[37]=x,e[38]=P):P=e[38],P}function Xe(t){const e=$.c(48),{selectedIds:a,onAdd:l}=t,[r,d]=H.useState(!1),[n,h]=H.useState(""),m=le();let b;e[0]!==a?(b=new Set(a),e[0]=a,e[1]=b):b=e[1];const o=b;let i,u,j,f,g,z,x,v,D,k,N,w,S;if(e[2]!==m||e[3]!==l||e[4]!==r||e[5]!==n||e[6]!==o){const A=n.toLowerCase();f=ee.filter(c=>!o.has(c.id)&&(!n||c.title.toLowerCase().includes(A)));let C;e[20]!==o?(C=c=>c.id!==null&&!Re(c.id)&&!o.has(c.id),e[20]=o,e[21]=C):C=e[21],j=m.filter(C).filter(c=>!n||c.title.toLowerCase().includes(A));let P;e[22]!==l?(P=c=>{l(c),d(!1),h("")},e[22]=l,e[23]=P):P=e[23];const T=P;u=Le,w=r,S=d,e[24]===Symbol.for("react.memo_cache_sentinel")?(g=s.jsx($e,{asChild:!0,children:s.jsxs(G,{type:"button",variant:"outline",size:"sm",children:[s.jsx(He,{size:14}),"Add agent"]})}),e[24]=g):g=e[24],i=Fe,D="w-[320px] p-0 overflow-hidden",k="start",e[25]!==n?(N=s.jsx(Oe,{value:n,onChange:h,placeholder:"Search agents..."}),e[25]=n,e[26]=N):N=e[26],z="max-h-[320px] overflow-y-auto p-2 flex flex-col gap-3",x=f.length>0&&s.jsxs("div",{className:"flex flex-col gap-1",children:[s.jsx("span",{className:"text-xs font-medium text-muted-foreground px-1",children:"Templates"}),f.map(c=>s.jsxs("button",{type:"button",onClick:()=>T(c.id),className:"flex items-center gap-2 px-2 py-1.5 rounded-md hover:bg-accent text-left",children:[s.jsx(J,{icon:c.icon,name:c.title,size:"xs"}),s.jsx("span",{className:"text-sm truncate",children:c.title})]},c.id))]}),v=j.length>0&&s.jsxs("div",{className:"flex flex-col gap-1",children:[s.jsx("span",{className:"text-xs font-medium text-muted-foreground px-1",children:"Custom agents"}),j.map(c=>s.jsxs("button",{type:"button",onClick:()=>T(c.id),className:"flex items-center gap-2 px-2 py-1.5 rounded-md hover:bg-accent text-left",children:[s.jsx(J,{icon:c.icon,name:c.title,size:"xs",fallbackIcon:s.jsx(ae,{size:14})}),s.jsx("span",{className:"text-sm truncate",children:c.title})]},c.id))]}),e[2]=m,e[3]=l,e[4]=r,e[5]=n,e[6]=o,e[7]=i,e[8]=u,e[9]=j,e[10]=f,e[11]=g,e[12]=z,e[13]=x,e[14]=v,e[15]=D,e[16]=k,e[17]=N,e[18]=w,e[19]=S}else i=e[7],u=e[8],j=e[9],f=e[10],g=e[11],z=e[12],x=e[13],v=e[14],D=e[15],k=e[16],N=e[17],w=e[18],S=e[19];let _;e[27]!==j||e[28]!==f.length||e[29]!==n?(_=f.length===0&&j.length===0&&s.jsx("div",{className:"text-xs text-muted-foreground text-center py-6",children:n?"No agents found":"All agents are already added"}),e[27]=j,e[28]=f.length,e[29]=n,e[30]=_):_=e[30];let p;e[31]!==_||e[32]!==z||e[33]!==x||e[34]!==v?(p=s.jsxs("div",{className:z,children:[x,v,_]}),e[31]=_,e[32]=z,e[33]=x,e[34]=v,e[35]=p):p=e[35];let y;e[36]!==i||e[37]!==p||e[38]!==D||e[39]!==k||e[40]!==N?(y=s.jsxs(i,{className:D,align:k,children:[N,p]}),e[36]=i,e[37]=p,e[38]=D,e[39]=k,e[40]=N,e[41]=y):y=e[41];let I;return e[42]!==u||e[43]!==g||e[44]!==y||e[45]!==w||e[46]!==S?(I=s.jsxs(u,{open:w,onOpenChange:S,children:[g,y]}),e[42]=u,e[43]=g,e[44]=y,e[45]=w,e[46]=S,e[47]=I):I=e[47],I}function Ze(){const t=$.c(61),e=Ue(),a=le(),l=qe();let r;t[0]!==e?.ids?(r=e?.ids??[...oe],t[0]=e?.ids,t[1]=r):r=t[1];const d=r,[n,h]=H.useState(d);let m;t[2]!==n||t[3]!==d?(m=n.length!==d.length||n.some((E,O)=>E!==d[O]),t[2]=n,t[3]=d,t[4]=m):m=t[4];const b=m;let o;t[5]===Symbol.for("react.memo_cache_sentinel")?(o={activationConstraint:{distance:5}},t[5]=o):o=t[5];let i;t[6]===Symbol.for("react.memo_cache_sentinel")?(i={coordinateGetter:Ee},t[6]=i):i=t[6];const u=Ce(ne(Pe,o),ne(Ae,i));let j;t[7]!==n?(j=E=>{const{active:O,over:R}=E;if(!R||O.id===R.id)return;const L=n.indexOf(O.id),q=n.indexOf(R.id);L===-1||q===-1||h(Te([...n],L,q))},t[7]=n,t[8]=j):j=t[8];const f=j;let g;t[9]!==n?(g=E=>{n.includes(E)||h([...n,E])},t[9]=n,t[10]=g):g=t[10];const z=g;let x;t[11]!==n?(x=E=>{h(n.filter(O=>O!==E))},t[11]=n,t[12]=x):x=t[12];const v=x;let D;t[13]===Symbol.for("react.memo_cache_sentinel")?(D=()=>{h([...oe])},t[13]=D):D=t[13];const k=D;let N;t[14]!==n||t[15]!==l?(N=()=>{l.mutate({ids:n},{onSuccess:()=>{Y("default_home_agents_updated",{count:n.length,template_count:n.filter(tt).length}),K.success("Default home agents updated")},onError:et})},t[14]=n,t[15]=l,t[16]=N):N=t[16];const w=N;let S,_,p,y,I,A,C;if(t[17]!==a||t[18]!==n||t[19]!==f||t[20]!==v||t[21]!==u||t[22]!==l.isPending){let E;t[30]!==a?(E=L=>Ye(L,ee,a),t[30]=a,t[31]=E):E=t[31];const O=n.map(E);p=Math.max(0,n.length-ie),_=X,I="Default home agents";let R;t[32]===Symbol.for("react.memo_cache_sentinel")?(R=s.jsx(pe,{size:14}),t[32]=R):R=t[32],t[33]!==l.isPending?(A=s.jsxs(G,{type:"button",variant:"ghost",size:"sm",onClick:k,disabled:l.isPending,children:[R,"Reset defaults"]}),t[33]=l.isPending,t[34]=A):A=t[34],S=Z,C="px-5 py-5 flex flex-col gap-3",y=O.length===0?s.jsx("div",{className:"rounded-lg border border-dashed border-border p-6 text-center text-xs text-muted-foreground",children:'No agents selected. The home view will only show "Create agent".'}):s.jsx(we,{sensors:u,collisionDetection:_e,onDragEnd:f,children:s.jsx(ze,{items:n,strategy:De,children:s.jsx("div",{className:"flex flex-col gap-1.5",children:O.map((L,q)=>s.jsxs("div",{className:"flex flex-col gap-1.5",children:[q===ie&&s.jsxs("div",{className:"flex items-center gap-2 px-1 py-1 text-xs text-muted-foreground",children:[s.jsx("div",{className:"flex-1 h-px bg-border"}),s.jsx("span",{children:"Below this line is hidden on the home view"}),s.jsx("div",{className:"flex-1 h-px bg-border"})]}),s.jsx(Je,{agent:L,onRemove:()=>v(L.id)})]},L.id))})})}),t[17]=a,t[18]=n,t[19]=f,t[20]=v,t[21]=u,t[22]=l.isPending,t[23]=S,t[24]=_,t[25]=p,t[26]=y,t[27]=I,t[28]=A,t[29]=C}else S=t[23],_=t[24],p=t[25],y=t[26],I=t[27],A=t[28],C=t[29];let P;t[35]!==n||t[36]!==z?(P=s.jsx(Xe,{selectedIds:n,onAdd:z}),t[35]=n,t[36]=z,t[37]=P):P=t[37];let T;t[38]!==p?(T=p>0&&s.jsxs("span",{className:"text-xs text-muted-foreground",children:[p," agent",p===1?"":"s"," won't fit on the home view"]}),t[38]=p,t[39]=T):T=t[39];let c;t[40]!==P||t[41]!==T?(c=s.jsxs("div",{className:"flex items-center justify-between",children:[P,T]}),t[40]=P,t[41]=T,t[42]=c):c=t[42];let F;t[43]!==y||t[44]!==c||t[45]!==C?(F=s.jsxs("div",{className:C,children:[y,c]}),t[43]=y,t[44]=c,t[45]=C,t[46]=F):F=t[46];let M;t[47]!==w||t[48]!==d||t[49]!==b||t[50]!==l.isPending?(M=b&&s.jsxs(Se,{children:[s.jsx(G,{type:"button",variant:"outline",onClick:()=>h(d),disabled:l.isPending,children:"Cancel"}),s.jsx(G,{type:"button",onClick:w,disabled:l.isPending,children:l.isPending?"Saving…":"Save"})]}),t[47]=w,t[48]=d,t[49]=b,t[50]=l.isPending,t[51]=M):M=t[51];let B;t[52]!==S||t[53]!==F||t[54]!==M?(B=s.jsxs(S,{children:[F,M]}),t[52]=S,t[53]=F,t[54]=M,t[55]=B):B=t[55];let U;return t[56]!==_||t[57]!==I||t[58]!==A||t[59]!==B?(U=s.jsx(_,{title:I,actions:A,children:B}),t[56]=_,t[57]=I,t[58]=A,t[59]=B,t[60]=U):U=t[60],U}function et(t){K.error(t instanceof Error?t.message:"Failed to update default home agents")}function tt(t){return ee.some(e=>e.id===t)}function st(){const t=$.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(X,{title:"Default home agents",children:s.jsx(Z,{children:s.jsx("div",{className:"px-5 py-5 flex flex-col gap-2",children:Array.from({length:4}).map(nt)})})}),t[0]=e):e=t[0],e}function nt(t,e){return s.jsx(Me,{className:"h-12 w-full rounded-lg"},e)}function ot(){const t=$.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(H.Suspense,{fallback:s.jsx(st,{}),children:s.jsx(Ze,{})}),t[0]=e):e=t[0],e}function it(){const t=$.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(V,{children:s.jsx(V.Content,{children:s.jsx(V.Body,{children:s.jsxs(ye,{children:[s.jsx(V.Title,{children:"Organization"}),s.jsx(Qe,{}),s.jsx(Ne,{}),s.jsx(ot,{})]})})})}),t[0]=e):e=t[0],e}function ns(){const t=$.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(it,{}),t[0]=e):e=t[0],e}export{ns as default};
@@ -1,4 +1,4 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/plugin-header-CjcXnInr.js","assets/Check-DC_iCN8Z.js","assets/ChevronDown-CnUhTqwX.js","assets/login-JiD1cfP5.js","assets/input-Bs7mkNsF.js","assets/reset-password-DHyMDEUg.js","assets/shell-layout-BcsYrOTT.js","assets/dialog-0SvGB_9G.js","assets/X-QdBx5oCM.js","assets/required-auth-layout-Cm0GjYeR.js","assets/use-tasks-DqNLNkkM.js","assets/use-collections-ASqcb463.js","assets/constants-Dm1wnwL3.js","assets/use-organization-settings-gFwljgrZ.js","assets/use-org-sso-Cj1DBVz0.js","assets/Lock01-KbqVCyA7.js","assets/onboarding-CCZiORGK.js","assets/label-CB1YxmGr.js","assets/Users03-CIZBy7k3.js","assets/CheckCircle-ROoANe3f.js","assets/Palette-CmZGtCez.js","assets/index-Bhv1nOmU.js","assets/index-AqmdpH5c.js","assets/tooltip-DZT-1bal.js","assets/index-DvCRkopi.js","assets/agent-icon-C2zAhw3X.js","assets/AlertCircle-4Fij-rVg.js","assets/Tool01-DVcjHQGB.js","assets/XClose-BdbZPqCd.js","assets/RefreshCcw01-DIY3NFBI.js","assets/ArrowNarrowLeft-CxNzupMt.js","assets/XCircle-DokNvYvs.js","assets/ArrowUpRight-B9s_0HcJ.js","assets/ZapSquare-CnxL4Bs1.js","assets/ChevronRight-X2lm_E9M.js","assets/ChevronUp-CgOfWCZA.js","assets/DotsVertical-C2-ev8jy.js","assets/Container-BrskPoE3.js","assets/Star01-iULH34rV.js","assets/SearchMd-DzMVdOJP.js","assets/LinkExternal01-Bhhv-wHj.js","assets/Sun-Dc78AQrj.js","assets/Play-EPgISV5B.js","assets/Plus-BYimMcAW.js","assets/Settings02-BxmxMTOA.js","assets/Shield01-B9vNkAc4.js","assets/Trash01-CaZrP0UV.js","assets/User01-7U7nAEDg.js","assets/Zap-DH1KrJ0w.js","assets/pair-Hj9vutgK.js","assets/index-B8A_ReFj.js","assets/use-copy-qtJD_4jj.js","assets/differenceInSeconds-NQ4PDo0z.js","assets/content-blocks-o63cs2vh.js","assets/types-DA7k1cs0.js","assets/chat-context-iq-Q-O9L.js","assets/use-virtual-mcp-BR6mzHHD.js","assets/use-ai-providers-Bv-kgplO.js","assets/use-decopilot-events-tgKj5crX.js","assets/create-sse-subscription-CxkOgzKf.js","assets/integration-icon-DgJZ63kl.js","assets/skeleton-DLT024S3.js","assets/popover-9-i1guS1.js","assets/drawer-CyXE-C5x.js","assets/avatar-D0sdobqD.js","assets/alert-dialog-BytOwrWo.js","assets/form-BMjsxf1O.js","assets/index-CEyiW6G-.js","assets/use-mcp-tools-rNZ6JWxz.js","assets/index-D85QLvNR.js","assets/switch-ChOgiOZl.js","assets/use-connection-Ck4brnCx.js","assets/lean-canvas-recruit-modal-BkH3ZJD2.js","assets/use-navigate-to-agent-CwcBoswU.js","assets/collection-search-O8QAretn.js","assets/checkbox-IEnuEqAm.js","assets/extract-connection-data-CnUKkwJT.js","assets/constants-CWAA475A.js","assets/collections-DKW_jlNs.js","assets/tabs-y647ki3a.js","assets/dropdown-menu-BkrpBFy3.js","assets/select-DQy3AX-J.js","assets/toggle-group-CgDVnjbj.js","assets/select-model-BjvpQUyU.js","assets/ai-providers-logos-DD3qZ33J.js","assets/use-debounced-autosave-BliXkuEQ.js","assets/settings-section-DJf4hau9.js","assets/card-BGZ5LqAO.js","assets/formatDistanceToNow-Cb2QZZJn.js","assets/unwrap-tool-result-BYXdCQMg.js","assets/index-DYUyKEVO.js","assets/question-004-sINsf4GQ.js","assets/connection-slug-eyAPH6o3.js","assets/connection-card-Aj-8CWhX.js","assets/use-registry-connections-Dgb2TDlG.js","assets/useInfiniteQuery-C_BkERX4.js","assets/infiniteQueryObserver-DmPvCV47.js","assets/collection-tabs-CqINIlN4.js","assets/badge-tvsCFCHP.js","assets/textarea-CT4UCcWE.js","assets/connection-form-helpers-hlnQqQXV.js","assets/use-infinite-scroll-De_3UNjO.js","assets/useSuspenseInfiniteQuery-DFnwwxGS.js","assets/collection-search-bjPRZI3g.js","assets/use-create-virtual-mcp-CTxthd0a.js","assets/empty-state-Crsog8CF.js","assets/task-status-IiU7o7it.js","assets/index-DusASzPG.js","assets/command-Cbi8R9Tg.js","assets/index-CPDZUQ3g.js","assets/use-status-sounds-Cn3fBsPH.js","assets/accordion-81SrnINF.js","assets/user-BVu9y1Y7.js","assets/tools-list-Dl1EqLq_.js","assets/scroll-area-Dal58SLb.js","assets/view-mode-toggle-ZI-MN1pO.js","assets/automation-list-row-etrXhG1_.js","assets/search-input-BSfMPrXv.js","assets/index-DDGTF8rc.css","assets/index-CZ5qFDIg.js","assets/settings-layout-Hke-qhRP.js","assets/connections-CrOLesap.js","assets/collection-display-button-tJsvfx8o.js","assets/use-delete-connection-DM_4FfQI.js","assets/use-list-state-SVk88wog.js","assets/use-view-mode-D9kCRFMC.js","assets/connection-detail-G5l6bgwi.js","assets/index-tIIHK8_r.js","assets/index-CyJ-TyKU.js","assets/index-WBXV3t9A.js","assets/use-members-Bk-c46d0.js","assets/use-org-auth-client-Hwc_S6Fw.js","assets/layout-GReGu88m.js","assets/monitoring-stats-row-IV0nDqiB.js","assets/collection-detail-BnoKU_uS.js","assets/index-hSAfwkZQ.js","assets/monaco-editor-_r7N6eV-.js","assets/empty-state-CxZybw5m.js","assets/index-CYY5hWbm.js","assets/table-B48Xy50A.js","assets/general-CVe1Krdt.js","assets/domain-settings-CckaLtjm.js","assets/features-Ddtjf7i2.js","assets/brand-context-Cy-kcB0m.js","assets/ai-providers-BxrN55-q.js","assets/members-B72381x1.js","assets/collection-table-wrapper-CcyIZki9.js","assets/use-organization-roles--8BRYJrg.js","assets/roles-BRZ0jwUp.js","assets/sso-BuTvljxJ.js","assets/profile-C0pKX75D.js","assets/store-Iw0YIysI.js","assets/workflow-D5sDlQLV.js","assets/workflow-detail-BKMBH1Ij.js","assets/org-plugin-layout-C4CnG2ku.js","assets/plugin-layout-BJ0qU511.js","assets/agents-list-CH2sTwpj.js","assets/automations-DFRPWAOO.js","assets/dynamic-plugin-layout-DAf8nhzs.js"])))=>i.map(i=>d[i]);
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/plugin-header-2Ks_trAw.js","assets/Check-Dgq0jjpz.js","assets/ChevronDown-CH5lQohM.js","assets/login-HZPNR9xd.js","assets/input-Dh3J6cxA.js","assets/reset-password-Bn__ApCp.js","assets/shell-layout-CtEV3YzW.js","assets/dialog-sfEBwtz9.js","assets/X-CAquUT--.js","assets/required-auth-layout-DMKD_TV3.js","assets/use-tasks-DqkYGNHa.js","assets/use-collections-BLOTVIAP.js","assets/constants-CMPjFkrZ.js","assets/use-organization-settings-CoHf1k_t.js","assets/use-org-sso-DMUwA_K8.js","assets/Lock01-CidilFiJ.js","assets/onboarding-HMRjmRyP.js","assets/label-BGhcnROH.js","assets/Users03-rbWg-6tV.js","assets/CheckCircle-rZ5sDOOP.js","assets/Palette-CURRsupy.js","assets/index-BkJIlnCh.js","assets/index-CGKwbcyW.js","assets/tooltip-XW5rFMNu.js","assets/index-DlEDBVDU.js","assets/agent-icon-D9odI-qh.js","assets/AlertCircle-Cb7fTEMa.js","assets/Tool01-Cu4I31F8.js","assets/XClose-_Y5VAjW5.js","assets/RefreshCcw01-CCzpYBs0.js","assets/ArrowNarrowLeft-tcEBzg5K.js","assets/XCircle-B-00qJpY.js","assets/ArrowUpRight-Ds7CgDkL.js","assets/ZapSquare-Cpo7Z7gP.js","assets/ChevronRight-DfFDUpKj.js","assets/ChevronUp-DCsRkih0.js","assets/DotsVertical-BljfGuhu.js","assets/Container-zeFPXb1Q.js","assets/Star01-ChekdAzX.js","assets/SearchMd-BpRj1P2W.js","assets/LinkExternal01-MvI2bZbP.js","assets/Sun-TuktgENq.js","assets/Play-DLW6aJFn.js","assets/Plus-28zZOE9T.js","assets/Settings02-CE5ZLw2I.js","assets/Shield01-Dtb2_AeI.js","assets/Trash01-4Dq6ympL.js","assets/User01-DKnZn118.js","assets/Zap-B8xnzkap.js","assets/pair-D1MIu7ah.js","assets/index-mKsCyZ2c.js","assets/use-copy-BquaY5FR.js","assets/differenceInSeconds-NQ4PDo0z.js","assets/content-blocks-o63cs2vh.js","assets/types-BU1oqgjO.js","assets/chat-context-C4lTxfjV.js","assets/use-virtual-mcp-Dndzl8Kr.js","assets/use-ai-providers-ClmB64W8.js","assets/use-decopilot-events-nw-lJk37.js","assets/create-sse-subscription-CxkOgzKf.js","assets/integration-icon-CDE9CENl.js","assets/skeleton-BxQRt9FI.js","assets/popover-D4Clv1Kb.js","assets/drawer--MluJNWl.js","assets/avatar-JoKAxyik.js","assets/alert-dialog-DCT4MTMH.js","assets/form-DpB6tHPK.js","assets/index-B_IvwEkx.js","assets/use-mcp-tools-DkxVTDC9.js","assets/index-uTY5VsaX.js","assets/switch-DydlPJmA.js","assets/use-connection-DGPnnQz6.js","assets/lean-canvas-recruit-modal-DZfH4ZaB.js","assets/use-navigate-to-agent-zDaGGVEB.js","assets/collection-search-jhKWbxqo.js","assets/checkbox-Baro7Q1f.js","assets/extract-connection-data-B9BMTKgA.js","assets/constants-XGFAnuHn.js","assets/collections-B60eBxX4.js","assets/tabs-BArWG_lg.js","assets/dropdown-menu-BpPFRti7.js","assets/select-CG0rwGUX.js","assets/toggle-group-BdQafmUc.js","assets/select-model-DcRnjECr.js","assets/ai-providers-logos-DD3qZ33J.js","assets/use-debounced-autosave-BFE3ZeG7.js","assets/settings-section-HkZRSntL.js","assets/card-CkFfla-m.js","assets/formatDistanceToNow-Cb2QZZJn.js","assets/unwrap-tool-result-BYXdCQMg.js","assets/index-Cav3nFoE.js","assets/question-004-sINsf4GQ.js","assets/connection-slug-eyAPH6o3.js","assets/connection-card-ugyEg8FF.js","assets/use-registry-connections-DWMBdekg.js","assets/useInfiniteQuery-BzvZ_TDh.js","assets/infiniteQueryObserver-D69C8aZS.js","assets/collection-tabs-BPF8fjT2.js","assets/badge-BXVtVPzt.js","assets/textarea-Dkmw6W4u.js","assets/connection-form-helpers-CYrNbtwl.js","assets/use-infinite-scroll-KzNu752x.js","assets/useSuspenseInfiniteQuery-ZnAzp1qO.js","assets/collection-search-BHyuqRiT.js","assets/use-create-virtual-mcp-gYa1vYVG.js","assets/empty-state-Be0FdXg2.js","assets/task-status-Bi6NGRuA.js","assets/index-JYp8Y8Zk.js","assets/command-CJRvOxZ7.js","assets/index-BWMPhdit.js","assets/use-status-sounds-j2IA-viC.js","assets/accordion-CyIKHcCT.js","assets/user-Df7A58iD.js","assets/tools-list-C0MslVQp.js","assets/scroll-area-yWZqBKom.js","assets/view-mode-toggle-DoidsjaP.js","assets/automation-list-row-C0fNHM9j.js","assets/search-input-UA1Jjc1m.js","assets/index-DDGTF8rc.css","assets/index-DqWmbGe9.js","assets/settings-layout-ePFy_Zf4.js","assets/connections-I35i0t7r.js","assets/collection-display-button-BSv13jEo.js","assets/use-delete-connection-MTPofM5f.js","assets/use-list-state-BMUfPc5P.js","assets/use-view-mode-Bc5J1h4b.js","assets/connection-detail-EgRvIktM.js","assets/index-DE4jOyEe.js","assets/index-BAl-Vlym.js","assets/index-BG0omYxu.js","assets/use-members-DadnCd-C.js","assets/use-org-auth-client-CPZNMqkZ.js","assets/layout-DMQieMve.js","assets/monitoring-stats-row-CQqHcgiv.js","assets/collection-detail-CvBw6hsJ.js","assets/index-B-PMmlqs.js","assets/monaco-editor-BaDnBAIf.js","assets/empty-state-Vlkqr5Ha.js","assets/index-Bzh6y1DZ.js","assets/table-Cg2S62iB.js","assets/general-Bi8iKo_s.js","assets/domain-settings-BEv8OnaD.js","assets/features-ymCT4sQe.js","assets/brand-context-B00HyWuJ.js","assets/ai-providers-28dSCs53.js","assets/members-DXQFXjq8.js","assets/collection-table-wrapper-hR7H16-N.js","assets/use-organization-roles-CJVol15S.js","assets/roles-C4lGMFwb.js","assets/sso-DElvxw59.js","assets/profile-CjGu4VCE.js","assets/store-CQloMsrY.js","assets/workflow-DgvsxaIb.js","assets/workflow-detail-Bebyclsh.js","assets/org-plugin-layout-DXqded6M.js","assets/plugin-layout-CdtsQwFc.js","assets/agents-list-CLJAN1rm.js","assets/automations-CVam3JT8.js","assets/dynamic-plugin-layout-JwST599m.js"])))=>i.map(i=>d[i]);
2
2
  function z$(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const i in r)if(i!=="default"&&!(i in e)){const s=Object.getOwnPropertyDescriptor(r,i);s&&Object.defineProperty(e,i,s.get?s:{enumerable:!0,get:()=>r[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const s of i)if(s.type==="childList")for(const l of s.addedNodes)l.tagName==="LINK"&&l.rel==="modulepreload"&&r(l)}).observe(document,{childList:!0,subtree:!0});function n(i){const s={};return i.integrity&&(s.integrity=i.integrity),i.referrerPolicy&&(s.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?s.credentials="include":i.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function r(i){if(i.ep)return;i.ep=!0;const s=n(i);fetch(i.href,s)}})();const F$="modulepreload",B$=function(e){return"/"+e},X2={},At=function(t,n,r){let i=Promise.resolve();if(n&&n.length>0){let l=function(f){return Promise.all(f.map(m=>Promise.resolve(m).then(p=>({status:"fulfilled",value:p}),p=>({status:"rejected",reason:p}))))};document.getElementsByTagName("link");const c=document.querySelector("meta[property=csp-nonce]"),d=c?.nonce||c?.getAttribute("nonce");i=l(n.map(f=>{if(f=B$(f),f in X2)return;X2[f]=!0;const m=f.endsWith(".css"),p=m?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${f}"]${p}`))return;const g=document.createElement("link");if(g.rel=m?"stylesheet":F$,m||(g.as="script"),g.crossOrigin="",g.href=f,d&&g.setAttribute("nonce",d),document.head.appendChild(g),m)return new Promise((v,y)=>{g.addEventListener("load",v),g.addEventListener("error",()=>y(Error(`Unable to preload CSS for ${f}`)))})}))}function s(l){const c=new Event("vite:preloadError",{cancelable:!0});if(c.payload=l,window.dispatchEvent(c),!c.defaultPrevented)throw l}return i.then(l=>{for(const c of l||[])c.status==="rejected"&&s(c.reason);return t().catch(s)})};var ele=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function la(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var __={exports:{}},Bu={};var J2;function V$(){if(J2)return Bu;J2=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,i,s){var l=null;if(s!==void 0&&(l=""+s),i.key!==void 0&&(l=""+i.key),"key"in i){s={};for(var c in i)c!=="key"&&(s[c]=i[c])}else s=i;return i=s.ref,{$$typeof:e,type:r,key:l,ref:i!==void 0?i:null,props:s}}return Bu.Fragment=t,Bu.jsx=n,Bu.jsxs=n,Bu}var eO;function q$(){return eO||(eO=1,__.exports=V$()),__.exports}var T=q$(),y_={exports:{}},Vu={},b_={exports:{}},w_={};var tO;function H$(){return tO||(tO=1,(function(e){function t(q,W){var ee=q.length;q.push(W);e:for(;0<ee;){var ae=ee-1>>>1,Q=q[ae];if(0<i(Q,W))q[ae]=W,q[ee]=Q,ee=ae;else break e}}function n(q){return q.length===0?null:q[0]}function r(q){if(q.length===0)return null;var W=q[0],ee=q.pop();if(ee!==W){q[0]=ee;e:for(var ae=0,Q=q.length,k=Q>>>1;ae<k;){var K=2*(ae+1)-1,V=q[K],D=K+1,F=q[D];if(0>i(V,ee))D<Q&&0>i(F,V)?(q[ae]=F,q[D]=ee,ae=D):(q[ae]=V,q[K]=ee,ae=K);else if(D<Q&&0>i(F,ee))q[ae]=F,q[D]=ee,ae=D;else break e}}return W}function i(q,W){var ee=q.sortIndex-W.sortIndex;return ee!==0?ee:q.id-W.id}if(e.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var s=performance;e.unstable_now=function(){return s.now()}}else{var l=Date,c=l.now();e.unstable_now=function(){return l.now()-c}}var d=[],f=[],m=1,p=null,g=3,v=!1,y=!1,b=!1,x=!1,S=typeof setTimeout=="function"?setTimeout:null,E=typeof clearTimeout=="function"?clearTimeout:null,R=typeof setImmediate<"u"?setImmediate:null;function C(q){for(var W=n(f);W!==null;){if(W.callback===null)r(f);else if(W.startTime<=q)r(f),W.sortIndex=W.expirationTime,t(d,W);else break;W=n(f)}}function O(q){if(b=!1,C(q),!y)if(n(d)!==null)y=!0,A||(A=!0,B());else{var W=n(f);W!==null&&re(O,W.startTime-q)}}var A=!1,M=-1,P=5,L=-1;function H(){return x?!0:!(e.unstable_now()-L<P)}function j(){if(x=!1,A){var q=e.unstable_now();L=q;var W=!0;try{e:{y=!1,b&&(b=!1,E(M),M=-1),v=!0;var ee=g;try{t:{for(C(q),p=n(d);p!==null&&!(p.expirationTime>q&&H());){var ae=p.callback;if(typeof ae=="function"){p.callback=null,g=p.priorityLevel;var Q=ae(p.expirationTime<=q);if(q=e.unstable_now(),typeof Q=="function"){p.callback=Q,C(q),W=!0;break t}p===n(d)&&r(d),C(q)}else r(d);p=n(d)}if(p!==null)W=!0;else{var k=n(f);k!==null&&re(O,k.startTime-q),W=!1}}break e}finally{p=null,g=ee,v=!1}W=void 0}}finally{W?B():A=!1}}}var B;if(typeof R=="function")B=function(){R(j)};else if(typeof MessageChannel<"u"){var U=new MessageChannel,Z=U.port2;U.port1.onmessage=j,B=function(){Z.postMessage(null)}}else B=function(){S(j,0)};function re(q,W){M=S(function(){q(e.unstable_now())},W)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(q){q.callback=null},e.unstable_forceFrameRate=function(q){0>q||125<q?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):P=0<q?Math.floor(1e3/q):5},e.unstable_getCurrentPriorityLevel=function(){return g},e.unstable_next=function(q){switch(g){case 1:case 2:case 3:var W=3;break;default:W=g}var ee=g;g=W;try{return q()}finally{g=ee}},e.unstable_requestPaint=function(){x=!0},e.unstable_runWithPriority=function(q,W){switch(q){case 1:case 2:case 3:case 4:case 5:break;default:q=3}var ee=g;g=q;try{return W()}finally{g=ee}},e.unstable_scheduleCallback=function(q,W,ee){var ae=e.unstable_now();switch(typeof ee=="object"&&ee!==null?(ee=ee.delay,ee=typeof ee=="number"&&0<ee?ae+ee:ae):ee=ae,q){case 1:var Q=-1;break;case 2:Q=250;break;case 5:Q=1073741823;break;case 4:Q=1e4;break;default:Q=5e3}return Q=ee+Q,q={id:m++,callback:W,priorityLevel:q,startTime:ee,expirationTime:Q,sortIndex:-1},ee>ae?(q.sortIndex=ee,t(f,q),n(d)===null&&q===n(f)&&(b?(E(M),M=-1):b=!0,re(O,ee-ae))):(q.sortIndex=Q,t(d,q),y||v||(y=!0,A||(A=!0,B()))),q},e.unstable_shouldYield=H,e.unstable_wrapCallback=function(q){var W=g;return function(){var ee=g;g=W;try{return q.apply(this,arguments)}finally{g=ee}}}})(w_)),w_}var nO;function G$(){return nO||(nO=1,b_.exports=H$()),b_.exports}var S_={exports:{}},rt={};var rO;function K$(){if(rO)return rt;rO=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),s=Symbol.for("react.consumer"),l=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),f=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),p=Symbol.for("react.activity"),g=Symbol.iterator;function v(k){return k===null||typeof k!="object"?null:(k=g&&k[g]||k["@@iterator"],typeof k=="function"?k:null)}var y={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},b=Object.assign,x={};function S(k,K,V){this.props=k,this.context=K,this.refs=x,this.updater=V||y}S.prototype.isReactComponent={},S.prototype.setState=function(k,K){if(typeof k!="object"&&typeof k!="function"&&k!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,k,K,"setState")},S.prototype.forceUpdate=function(k){this.updater.enqueueForceUpdate(this,k,"forceUpdate")};function E(){}E.prototype=S.prototype;function R(k,K,V){this.props=k,this.context=K,this.refs=x,this.updater=V||y}var C=R.prototype=new E;C.constructor=R,b(C,S.prototype),C.isPureReactComponent=!0;var O=Array.isArray;function A(){}var M={H:null,A:null,T:null,S:null},P=Object.prototype.hasOwnProperty;function L(k,K,V){var D=V.ref;return{$$typeof:e,type:k,key:K,ref:D!==void 0?D:null,props:V}}function H(k,K){return L(k.type,K,k.props)}function j(k){return typeof k=="object"&&k!==null&&k.$$typeof===e}function B(k){var K={"=":"=0",":":"=2"};return"$"+k.replace(/[=:]/g,function(V){return K[V]})}var U=/\/+/g;function Z(k,K){return typeof k=="object"&&k!==null&&k.key!=null?B(""+k.key):K.toString(36)}function re(k){switch(k.status){case"fulfilled":return k.value;case"rejected":throw k.reason;default:switch(typeof k.status=="string"?k.then(A,A):(k.status="pending",k.then(function(K){k.status==="pending"&&(k.status="fulfilled",k.value=K)},function(K){k.status==="pending"&&(k.status="rejected",k.reason=K)})),k.status){case"fulfilled":return k.value;case"rejected":throw k.reason}}throw k}function q(k,K,V,D,F){var X=typeof k;(X==="undefined"||X==="boolean")&&(k=null);var fe=!1;if(k===null)fe=!0;else switch(X){case"bigint":case"string":case"number":fe=!0;break;case"object":switch(k.$$typeof){case e:case t:fe=!0;break;case m:return fe=k._init,q(fe(k._payload),K,V,D,F)}}if(fe)return F=F(k),fe=D===""?"."+Z(k,0):D,O(F)?(V="",fe!=null&&(V=fe.replace(U,"$&/")+"/"),q(F,K,V,"",function(Ue){return Ue})):F!=null&&(j(F)&&(F=H(F,V+(F.key==null||k&&k.key===F.key?"":(""+F.key).replace(U,"$&/")+"/")+fe)),K.push(F)),1;fe=0;var pe=D===""?".":D+":";if(O(k))for(var xe=0;xe<k.length;xe++)D=k[xe],X=pe+Z(D,xe),fe+=q(D,K,V,X,F);else if(xe=v(k),typeof xe=="function")for(k=xe.call(k),xe=0;!(D=k.next()).done;)D=D.value,X=pe+Z(D,xe++),fe+=q(D,K,V,X,F);else if(X==="object"){if(typeof k.then=="function")return q(re(k),K,V,D,F);throw K=String(k),Error("Objects are not valid as a React child (found: "+(K==="[object Object]"?"object with keys {"+Object.keys(k).join(", ")+"}":K)+"). If you meant to render a collection of children, use an array instead.")}return fe}function W(k,K,V){if(k==null)return k;var D=[],F=0;return q(k,D,"","",function(X){return K.call(V,X,F++)}),D}function ee(k){if(k._status===-1){var K=k._result;K=K(),K.then(function(V){(k._status===0||k._status===-1)&&(k._status=1,k._result=V)},function(V){(k._status===0||k._status===-1)&&(k._status=2,k._result=V)}),k._status===-1&&(k._status=0,k._result=K)}if(k._status===1)return k._result.default;throw k._result}var ae=typeof reportError=="function"?reportError:function(k){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var K=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof k=="object"&&k!==null&&typeof k.message=="string"?String(k.message):String(k),error:k});if(!window.dispatchEvent(K))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",k);return}console.error(k)},Q={map:W,forEach:function(k,K,V){W(k,function(){K.apply(this,arguments)},V)},count:function(k){var K=0;return W(k,function(){K++}),K},toArray:function(k){return W(k,function(K){return K})||[]},only:function(k){if(!j(k))throw Error("React.Children.only expected to receive a single React element child.");return k}};return rt.Activity=p,rt.Children=Q,rt.Component=S,rt.Fragment=n,rt.Profiler=i,rt.PureComponent=R,rt.StrictMode=r,rt.Suspense=d,rt.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=M,rt.__COMPILER_RUNTIME={__proto__:null,c:function(k){return M.H.useMemoCache(k)}},rt.cache=function(k){return function(){return k.apply(null,arguments)}},rt.cacheSignal=function(){return null},rt.cloneElement=function(k,K,V){if(k==null)throw Error("The argument must be a React element, but you passed "+k+".");var D=b({},k.props),F=k.key;if(K!=null)for(X in K.key!==void 0&&(F=""+K.key),K)!P.call(K,X)||X==="key"||X==="__self"||X==="__source"||X==="ref"&&K.ref===void 0||(D[X]=K[X]);var X=arguments.length-2;if(X===1)D.children=V;else if(1<X){for(var fe=Array(X),pe=0;pe<X;pe++)fe[pe]=arguments[pe+2];D.children=fe}return L(k.type,F,D)},rt.createContext=function(k){return k={$$typeof:l,_currentValue:k,_currentValue2:k,_threadCount:0,Provider:null,Consumer:null},k.Provider=k,k.Consumer={$$typeof:s,_context:k},k},rt.createElement=function(k,K,V){var D,F={},X=null;if(K!=null)for(D in K.key!==void 0&&(X=""+K.key),K)P.call(K,D)&&D!=="key"&&D!=="__self"&&D!=="__source"&&(F[D]=K[D]);var fe=arguments.length-2;if(fe===1)F.children=V;else if(1<fe){for(var pe=Array(fe),xe=0;xe<fe;xe++)pe[xe]=arguments[xe+2];F.children=pe}if(k&&k.defaultProps)for(D in fe=k.defaultProps,fe)F[D]===void 0&&(F[D]=fe[D]);return L(k,X,F)},rt.createRef=function(){return{current:null}},rt.forwardRef=function(k){return{$$typeof:c,render:k}},rt.isValidElement=j,rt.lazy=function(k){return{$$typeof:m,_payload:{_status:-1,_result:k},_init:ee}},rt.memo=function(k,K){return{$$typeof:f,type:k,compare:K===void 0?null:K}},rt.startTransition=function(k){var K=M.T,V={};M.T=V;try{var D=k(),F=M.S;F!==null&&F(V,D),typeof D=="object"&&D!==null&&typeof D.then=="function"&&D.then(A,ae)}catch(X){ae(X)}finally{K!==null&&V.types!==null&&(K.types=V.types),M.T=K}},rt.unstable_useCacheRefresh=function(){return M.H.useCacheRefresh()},rt.use=function(k){return M.H.use(k)},rt.useActionState=function(k,K,V){return M.H.useActionState(k,K,V)},rt.useCallback=function(k,K){return M.H.useCallback(k,K)},rt.useContext=function(k){return M.H.useContext(k)},rt.useDebugValue=function(){},rt.useDeferredValue=function(k,K){return M.H.useDeferredValue(k,K)},rt.useEffect=function(k,K){return M.H.useEffect(k,K)},rt.useEffectEvent=function(k){return M.H.useEffectEvent(k)},rt.useId=function(){return M.H.useId()},rt.useImperativeHandle=function(k,K,V){return M.H.useImperativeHandle(k,K,V)},rt.useInsertionEffect=function(k,K){return M.H.useInsertionEffect(k,K)},rt.useLayoutEffect=function(k,K){return M.H.useLayoutEffect(k,K)},rt.useMemo=function(k,K){return M.H.useMemo(k,K)},rt.useOptimistic=function(k,K){return M.H.useOptimistic(k,K)},rt.useReducer=function(k,K,V){return M.H.useReducer(k,K,V)},rt.useRef=function(k){return M.H.useRef(k)},rt.useState=function(k){return M.H.useState(k)},rt.useSyncExternalStore=function(k,K,V){return M.H.useSyncExternalStore(k,K,V)},rt.useTransition=function(){return M.H.useTransition()},rt.version="19.2.5",rt}var iO;function ca(){return iO||(iO=1,S_.exports=K$()),S_.exports}var E_={exports:{}},yr={};var oO;function Z$(){if(oO)return yr;oO=1;var e=ca();function t(d){var f="https://react.dev/errors/"+d;if(1<arguments.length){f+="?args[]="+encodeURIComponent(arguments[1]);for(var m=2;m<arguments.length;m++)f+="&args[]="+encodeURIComponent(arguments[m])}return"Minified React error #"+d+"; visit "+f+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function n(){}var r={d:{f:n,r:function(){throw Error(t(522))},D:n,C:n,L:n,m:n,X:n,S:n,M:n},p:0,findDOMNode:null},i=Symbol.for("react.portal");function s(d,f,m){var p=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:i,key:p==null?null:""+p,children:d,containerInfo:f,implementation:m}}var l=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function c(d,f){if(d==="font")return"";if(typeof f=="string")return f==="use-credentials"?f:""}return yr.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=r,yr.createPortal=function(d,f){var m=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!f||f.nodeType!==1&&f.nodeType!==9&&f.nodeType!==11)throw Error(t(299));return s(d,f,null,m)},yr.flushSync=function(d){var f=l.T,m=r.p;try{if(l.T=null,r.p=2,d)return d()}finally{l.T=f,r.p=m,r.d.f()}},yr.preconnect=function(d,f){typeof d=="string"&&(f?(f=f.crossOrigin,f=typeof f=="string"?f==="use-credentials"?f:"":void 0):f=null,r.d.C(d,f))},yr.prefetchDNS=function(d){typeof d=="string"&&r.d.D(d)},yr.preinit=function(d,f){if(typeof d=="string"&&f&&typeof f.as=="string"){var m=f.as,p=c(m,f.crossOrigin),g=typeof f.integrity=="string"?f.integrity:void 0,v=typeof f.fetchPriority=="string"?f.fetchPriority:void 0;m==="style"?r.d.S(d,typeof f.precedence=="string"?f.precedence:void 0,{crossOrigin:p,integrity:g,fetchPriority:v}):m==="script"&&r.d.X(d,{crossOrigin:p,integrity:g,fetchPriority:v,nonce:typeof f.nonce=="string"?f.nonce:void 0})}},yr.preinitModule=function(d,f){if(typeof d=="string")if(typeof f=="object"&&f!==null){if(f.as==null||f.as==="script"){var m=c(f.as,f.crossOrigin);r.d.M(d,{crossOrigin:m,integrity:typeof f.integrity=="string"?f.integrity:void 0,nonce:typeof f.nonce=="string"?f.nonce:void 0})}}else f==null&&r.d.M(d)},yr.preload=function(d,f){if(typeof d=="string"&&typeof f=="object"&&f!==null&&typeof f.as=="string"){var m=f.as,p=c(m,f.crossOrigin);r.d.L(d,m,{crossOrigin:p,integrity:typeof f.integrity=="string"?f.integrity:void 0,nonce:typeof f.nonce=="string"?f.nonce:void 0,type:typeof f.type=="string"?f.type:void 0,fetchPriority:typeof f.fetchPriority=="string"?f.fetchPriority:void 0,referrerPolicy:typeof f.referrerPolicy=="string"?f.referrerPolicy:void 0,imageSrcSet:typeof f.imageSrcSet=="string"?f.imageSrcSet:void 0,imageSizes:typeof f.imageSizes=="string"?f.imageSizes:void 0,media:typeof f.media=="string"?f.media:void 0})}},yr.preloadModule=function(d,f){if(typeof d=="string")if(f){var m=c(f.as,f.crossOrigin);r.d.m(d,{as:typeof f.as=="string"&&f.as!=="script"?f.as:void 0,crossOrigin:m,integrity:typeof f.integrity=="string"?f.integrity:void 0})}else r.d.m(d)},yr.requestFormReset=function(d){r.d.r(d)},yr.unstable_batchedUpdates=function(d,f){return d(f)},yr.useFormState=function(d,f,m){return l.H.useFormState(d,f,m)},yr.useFormStatus=function(){return l.H.useHostTransitionStatus()},yr.version="19.2.5",yr}var sO;function IM(){if(sO)return E_.exports;sO=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),E_.exports=Z$(),E_.exports}var aO;function Y$(){if(aO)return Vu;aO=1;var e=G$(),t=ca(),n=IM();function r(o){var a="https://react.dev/errors/"+o;if(1<arguments.length){a+="?args[]="+encodeURIComponent(arguments[1]);for(var u=2;u<arguments.length;u++)a+="&args[]="+encodeURIComponent(arguments[u])}return"Minified React error #"+o+"; visit "+a+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function i(o){return!(!o||o.nodeType!==1&&o.nodeType!==9&&o.nodeType!==11)}function s(o){var a=o,u=o;if(o.alternate)for(;a.return;)a=a.return;else{o=a;do a=o,(a.flags&4098)!==0&&(u=a.return),o=a.return;while(o)}return a.tag===3?u:null}function l(o){if(o.tag===13){var a=o.memoizedState;if(a===null&&(o=o.alternate,o!==null&&(a=o.memoizedState)),a!==null)return a.dehydrated}return null}function c(o){if(o.tag===31){var a=o.memoizedState;if(a===null&&(o=o.alternate,o!==null&&(a=o.memoizedState)),a!==null)return a.dehydrated}return null}function d(o){if(s(o)!==o)throw Error(r(188))}function f(o){var a=o.alternate;if(!a){if(a=s(o),a===null)throw Error(r(188));return a!==o?null:o}for(var u=o,h=a;;){var _=u.return;if(_===null)break;var w=_.alternate;if(w===null){if(h=_.return,h!==null){u=h;continue}break}if(_.child===w.child){for(w=_.child;w;){if(w===u)return d(_),o;if(w===h)return d(_),a;w=w.sibling}throw Error(r(188))}if(u.return!==h.return)u=_,h=w;else{for(var N=!1,$=_.child;$;){if($===u){N=!0,u=_,h=w;break}if($===h){N=!0,h=_,u=w;break}$=$.sibling}if(!N){for($=w.child;$;){if($===u){N=!0,u=w,h=_;break}if($===h){N=!0,h=w,u=_;break}$=$.sibling}if(!N)throw Error(r(189))}}if(u.alternate!==h)throw Error(r(190))}if(u.tag!==3)throw Error(r(188));return u.stateNode.current===u?o:a}function m(o){var a=o.tag;if(a===5||a===26||a===27||a===6)return o;for(o=o.child;o!==null;){if(a=m(o),a!==null)return a;o=o.sibling}return null}var p=Object.assign,g=Symbol.for("react.element"),v=Symbol.for("react.transitional.element"),y=Symbol.for("react.portal"),b=Symbol.for("react.fragment"),x=Symbol.for("react.strict_mode"),S=Symbol.for("react.profiler"),E=Symbol.for("react.consumer"),R=Symbol.for("react.context"),C=Symbol.for("react.forward_ref"),O=Symbol.for("react.suspense"),A=Symbol.for("react.suspense_list"),M=Symbol.for("react.memo"),P=Symbol.for("react.lazy"),L=Symbol.for("react.activity"),H=Symbol.for("react.memo_cache_sentinel"),j=Symbol.iterator;function B(o){return o===null||typeof o!="object"?null:(o=j&&o[j]||o["@@iterator"],typeof o=="function"?o:null)}var U=Symbol.for("react.client.reference");function Z(o){if(o==null)return null;if(typeof o=="function")return o.$$typeof===U?null:o.displayName||o.name||null;if(typeof o=="string")return o;switch(o){case b:return"Fragment";case S:return"Profiler";case x:return"StrictMode";case O:return"Suspense";case A:return"SuspenseList";case L:return"Activity"}if(typeof o=="object")switch(o.$$typeof){case y:return"Portal";case R:return o.displayName||"Context";case E:return(o._context.displayName||"Context")+".Consumer";case C:var a=o.render;return o=o.displayName,o||(o=a.displayName||a.name||"",o=o!==""?"ForwardRef("+o+")":"ForwardRef"),o;case M:return a=o.displayName||null,a!==null?a:Z(o.type)||"Memo";case P:a=o._payload,o=o._init;try{return Z(o(a))}catch{}}return null}var re=Array.isArray,q=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,W=n.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ee={pending:!1,data:null,method:null,action:null},ae=[],Q=-1;function k(o){return{current:o}}function K(o){0>Q||(o.current=ae[Q],ae[Q]=null,Q--)}function V(o,a){Q++,ae[Q]=o.current,o.current=a}var D=k(null),F=k(null),X=k(null),fe=k(null);function pe(o,a){switch(V(X,a),V(F,o),V(D,null),a.nodeType){case 9:case 11:o=(o=a.documentElement)&&(o=o.namespaceURI)?w2(o):0;break;default:if(o=a.tagName,a=a.namespaceURI)a=w2(a),o=S2(a,o);else switch(o){case"svg":o=1;break;case"math":o=2;break;default:o=0}}K(D),V(D,o)}function xe(){K(D),K(F),K(X)}function Ue(o){o.memoizedState!==null&&V(fe,o);var a=D.current,u=S2(a,o.type);a!==u&&(V(F,o),V(D,u))}function Y(o){F.current===o&&(K(D),K(F)),fe.current===o&&(K(fe),ju._currentValue=ee)}var te,ve;function se(o){if(te===void 0)try{throw Error()}catch(u){var a=u.stack.trim().match(/\n( *(at )?)/);te=a&&a[1]||"",ve=-1<u.stack.indexOf(`
3
3
  at`)?" (<anonymous>)":-1<u.stack.indexOf("@")?"@unknown:0:0":""}return`
4
4
  `+te+o+ve}var we=!1;function Oe(o,a){if(!o||we)return"";we=!0;var u=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var h={DetermineComponentFrameRoot:function(){try{if(a){var Se=function(){throw Error()};if(Object.defineProperty(Se.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(Se,[])}catch(ge){var he=ge}Reflect.construct(o,[],Se)}else{try{Se.call()}catch(ge){he=ge}o.call(Se.prototype)}}else{try{throw Error()}catch(ge){he=ge}(Se=o())&&typeof Se.catch=="function"&&Se.catch(function(){})}}catch(ge){if(ge&&he&&typeof ge.stack=="string")return[ge.stack,he.stack]}return[null,null]}};h.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var _=Object.getOwnPropertyDescriptor(h.DetermineComponentFrameRoot,"name");_&&_.configurable&&Object.defineProperty(h.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var w=h.DetermineComponentFrameRoot(),N=w[0],$=w[1];if(N&&$){var J=N.split(`
@@ -168,4 +168,4 @@ ${r}
168
168
  ${r}
169
169
  }`)}if(n.length>0){const r=document.createElement("style");r.id="mesh-theme-overrides",r.textContent=n.join(`
170
170
 
171
- `),document.head.appendChild(r)}}function Jse(e){const t=Ro.c(9),{children:n}=e;let r;t[0]===Symbol.for("react.memo_cache_sentinel")?(r={queryKey:GM.publicConfig(),queryFn:Qse,staleTime:1/0},t[0]=r):r=t[0];const{data:i}=HM(r),[s]=Yse();i.internalUrl&&Use(i.internalUrl);let l,c;t[1]!==i.theme?(l=()=>{Xse(i.theme)},c=[i.theme],t[1]=i.theme,t[2]=l,t[3]=c):(l=t[2],c=t[3]),I.useLayoutEffect(l,c);let d,f;t[4]!==s.theme?(d=()=>{const p=document.documentElement;if(s.theme==="dark"){p.classList.add("dark");return}if(s.theme==="light"){p.classList.remove("dark");return}const g=window.matchMedia("(prefers-color-scheme: dark)"),v=b=>p.classList.toggle("dark",b);v(g.matches);const y=b=>v(b.matches);return g.addEventListener("change",y),()=>g.removeEventListener("change",y)},f=[s.theme],t[4]=s.theme,t[5]=d,t[6]=f):(d=t[5],f=t[6]),I.useLayoutEffect(d,f);let m;return t[7]!==n?(m=T.jsx(T.Fragment,{children:n}),t[7]=n,t[8]=m):m=t[8],m}const eae=new bj({defaultOptions:{queries:{staleTime:6e4,refetchOnWindowFocus:!0,refetchOnMount:!0,retry:1,gcTime:300*1e3}}});function tae(e){const t=Ro.c(4),{children:n}=e;let r;t[0]===Symbol.for("react.memo_cache_sentinel")?(r=T.jsx(hH,{}),t[0]=r):r=t[0];let i;t[1]===Symbol.for("react.memo_cache_sentinel")?(i=T.jsx(jD,{}),t[1]=i):i=t[1];let s;return t[2]!==n?(s=T.jsxs(wj,{client:eae,children:[r,T.jsx(I.Suspense,{fallback:i,children:T.jsx(Jse,{children:T.jsx(Lj,{children:T.jsx(Fee,{children:T.jsx(Wne,{children:n})})})})})]}),t[2]=n,t[3]=s):s=t[3],s}function nae(...e){return BP(pw(e))}const rae=y4("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-lg text-sm transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/20 focus-visible:ring-[2px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/80",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",outline:"text-foreground bg-background hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:hover:bg-input/50 card-shadow",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",success:"bg-success text-success-foreground hover:bg-success/90 focus-visible:ring-success/20 dark:focus-visible:ring-success/40",special:"bg-special text-special-foreground hover:bg-special/90 focus-visible:ring-special/20 dark:focus-visible:ring-special/40",ghost:"hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",link:"text-foreground/80 hover:text-foreground"},size:{default:"h-8 px-3 has-[>svg]:px-2.5",sm:"h-7 gap-1.5 px-2.5 has-[>svg]:px-2",xs:"h-6 gap-1 px-1.5 text-xs has-[>svg]:px-1",lg:"h-10 px-3.5 has-[>svg]:px-3",icon:"size-8","icon-sm":"size-7"}},defaultVariants:{variant:"default",size:"default"}});function W1(e){const t=Ro.c(14);let n,r,i,s,l;t[0]!==e?({className:n,variant:l,size:i,asChild:s,...r}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=s,t[5]=l):(n=t[1],r=t[2],i=t[3],s=t[4],l=t[5]);const d=(s===void 0?!1:s)?jw:"button";let f;t[6]!==n||t[7]!==i||t[8]!==l?(f=nae(rae({variant:l,size:i,className:n})),t[6]=n,t[7]=i,t[8]=l,t[9]=f):f=t[9];let m;return t[10]!==d||t[11]!==r||t[12]!==f?(m=T.jsx(d,{"data-slot":"button",className:f,...r}),t[10]=d,t[11]=r,t[12]=f,t[13]=m):m=t[13],m}const CM="__mesh_chunk_reload_ts";function AM(e){if(!e)return!1;const t=e.message||"";return t.includes("Failed to fetch dynamically imported module")||t.includes("Importing a module script failed")||t.includes("error loading dynamically imported module")||t.includes("Failed to fetch")&&e.name==="TypeError"}class ice extends I.Component{state={hasError:!1,error:null};static getDerivedStateFromError(t){return{hasError:!0,error:t}}componentDidCatch(t,n){console.error("Uncaught error:",t,n),kD(t,{boundary:"default",error_name:t.name,error_message:t.message,component_stack:n.componentStack??null,route:typeof window<"u"?window.location.pathname:null})}resetError=()=>{this.setState({hasError:!1,error:null})};render(){if(this.state.hasError){const{fallback:t}=this.props;return typeof t=="function"?t({error:this.state.error,resetError:this.resetError}):t!==void 0?t:T.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center h-full p-6 text-center space-y-4",children:[T.jsx("div",{className:"bg-destructive/10 p-3 rounded-full",children:T.jsx(NS,{className:"h-6 w-6 text-destructive"})}),T.jsxs("div",{className:"space-y-2",children:[T.jsx("h3",{className:"text-lg font-medium",children:"Something went wrong"}),T.jsx("p",{className:"text-sm text-muted-foreground max-w-xs mx-auto",children:this.state.error?.message||"An unexpected error occurred"})]}),T.jsx(W1,{variant:"outline",onClick:this.resetError,children:"Try again"})]})}return this.props.children}}class iae extends I.Component{state={hasError:!1,error:null};static getDerivedStateFromError(t){return{hasError:!0,error:t}}componentDidCatch(t,n){console.error("Uncaught error:",t,n);const r=AM(t);if(kD(t,{boundary:"chunk_root",is_chunk_load_error:r,error_name:t.name,error_message:t.message,component_stack:n.componentStack??null,route:typeof window<"u"?window.location.pathname:null}),!r)return;const i=sessionStorage.getItem(CM),s=Date.now();(!i||s-Number(i)>1e4)&&(sessionStorage.setItem(CM,String(s)),window.location.reload())}render(){return this.state.hasError&&AM(this.state.error)?T.jsxs("div",{className:"flex min-h-dvh flex-col items-center justify-center p-6 text-center space-y-4",children:[T.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:T.jsx($D,{className:"h-6 w-6 text-primary"})}),T.jsxs("div",{className:"space-y-2",children:[T.jsx("h3",{className:"text-lg font-medium",children:"New version available"}),T.jsx("p",{className:"text-sm text-muted-foreground max-w-xs mx-auto",children:"A new version has been deployed. Refresh to continue."})]}),T.jsx(W1,{onClick:()=>window.location.reload(),children:"Refresh"})]}):this.state.hasError?T.jsxs("div",{className:"flex min-h-dvh flex-col items-center justify-center p-6 text-center space-y-4",children:[T.jsx("div",{className:"bg-destructive/10 p-3 rounded-full",children:T.jsx(NS,{className:"h-6 w-6 text-destructive"})}),T.jsxs("div",{className:"space-y-2",children:[T.jsx("h3",{className:"text-lg font-medium",children:"Something went wrong"}),T.jsx("p",{className:"text-sm text-muted-foreground max-w-xs mx-auto",children:this.state.error?.message||"An unexpected error occurred"})]}),T.jsx(W1,{variant:"outline",onClick:()=>this.setState({hasError:!1,error:null}),children:"Try again"})]}):this.props.children}}const oae="MCP Workflows",sae="Create workflows using your MCP tools",aae=I.lazy(()=>At(()=>import("./plugin-header-CjcXnInr.js"),__vite__mapDeps([0,1,2]))),lae=I.lazy(()=>At(()=>import("./plugin-empty-state-DtiwhoNI.js"),[])),cae={id:oae,description:sae,bindingName:"WORKFLOW",renderHeader:e=>T.jsx(aae,{...e}),renderEmptyState:()=>T.jsx(lae,{}),setup:e=>{e.registerSettingsSidebarItem({key:"workflows",icon:T.jsx(DD,{size:14}),label:"MCP Workflows",to:"/$org/settings/workflows"})}},uae=[cae],ma=t7({component:()=>T.jsx(iae,{children:T.jsx(tae,{children:T.jsx(I.Suspense,{fallback:T.jsx(jD,{}),children:T.jsx(mP,{})})})})}),dae=mt({getParentRoute:()=>ma,path:"/login",component:It(()=>At(()=>import("./login-JiD1cfP5.js"),__vite__mapDeps([3,4]))),validateSearch:ul(()=>Ee({next:z().optional(),client_id:z().optional(),redirect_uri:z().optional(),response_type:z().optional(),state:z().optional(),scope:z().optional(),code_challenge:z().optional(),code_challenge_method:z().optional()}))}),fae=mt({getParentRoute:()=>ma,path:"/reset-password",component:It(()=>At(()=>import("./reset-password-DHyMDEUg.js"),__vite__mapDeps([5,4]))),validateSearch:ul(()=>Ee({token:z().optional(),error:z().optional()}))}),hae=mt({getParentRoute:()=>ma,path:"/auth/$pathname",component:It(()=>At(()=>import("./auth-catchall-BcUDEqD5.js"),[]))}),pae=mt({getParentRoute:()=>ma,path:"/oauth/callback",component:It(()=>At(()=>import("./oauth-callback-CkFjLbE_.js"),[]))}),mae=mt({getParentRoute:()=>ma,path:"/oauth/callback/ai-provider",component:It(()=>At(()=>import("./oauth-callback-ai-provider-By5VSIqz.js"),[]))}),rE=mt({getParentRoute:()=>ma,id:"shell",component:It(()=>At(()=>import("./shell-layout-BcsYrOTT.js").then(e=>e.s),__vite__mapDeps([6,7,8,9,10,11,12,13,14,15])))}),gae=mt({getParentRoute:()=>rE,path:"/",beforeLoad:async()=>{const{data:e}=await Mg.organization.list();if(!e)return;const t=localStorage.getItem(Rg.lastOrgSlug());if(t){if(e.some(i=>i.slug===t))throw Oc({to:"/$org",params:{org:t}});localStorage.removeItem(Rg.lastOrgSlug())}const n=e[0];throw Oc(n?{to:"/$org",params:{org:n.slug}}:{to:"/onboarding"})}}),vae=mt({getParentRoute:()=>ma,path:"/onboarding",beforeLoad:async()=>{const{data:e}=await Mg.organization.list();if(e&&e.length>0)throw Oc({to:"/"})},component:It(()=>At(()=>import("./onboarding-CCZiORGK.js"),__vite__mapDeps([16,9,4,17,18,19,20])))}),iE=mt({getParentRoute:()=>rE,path:"/$org",component:It(()=>At(()=>import("./org-layout-DF3EY572.js"),[]))}),oE=mt({getParentRoute:()=>iE,id:"org-shell",component:It(()=>At(()=>import("./index-Bhv1nOmU.js"),__vite__mapDeps([21,22,23,8,24,25,26,27,28,29,30,31,32,33,18,19,1,2,34,35,36,37,38,20,39,40,15,41,42,43,44,45,46,47,48,6,7,9,10,11,12,13,14,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,17,4,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106])))}),sE=mt({getParentRoute:()=>oE,id:"agent-shell",component:It(()=>At(()=>import("./index-DusASzPG.js"),__vite__mapDeps([107,69,7,8,70,4,71,11,12,72,73,56,29,74,39,75,1,15,25,26,27,28,30,31,32,33,18,19,2,34,35,36,37,38,20,22,23,40,41,42,43,44,45,46,47,48,76,77,78,63,60,68,55,57,58,59,10,13,6,9,14,49,50,51,52,53,54,79,66,17,80,81,82,83,61,84,85,86,87,64,65,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,108,109,62,24,67,103,104,105,106,110,111,112,113,114,115,116,117,118])))}),_ae=Ee({virtualmcpid:z().optional(),tab:z().optional(),main:z().optional(),id:z().optional(),toolName:z().optional(),tasks:St().optional(),mainOpen:St().optional(),chat:St().optional(),autosend:z().optional()}),O6=mt({getParentRoute:()=>sE,path:"/$taskId",validateSearch:_ae,component:()=>null}),yae=mt({getParentRoute:()=>oE,path:"/",component:It(()=>At(()=>import("./index-CZ5qFDIg.js"),__vite__mapDeps([119,60,37,25,26,27,28,29,30,31,32,33,18,19,1,2,34,35,36,38,20,39,22,23,8,40,15,41,42,43,44,45,46,47,48,61,12,56,11,13,72,73,7,74,75,71,76,77,78,63,68,69,70,4,55,57,58,59,10,6,9,14,49,50,51,52,53,54,79,66,17,80,81,82,83,84,85,86,87,64,65,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,104])))}),Pn=mt({getParentRoute:()=>iE,path:"/settings",component:It(()=>At(()=>import("./settings-layout-Hke-qhRP.js"),__vite__mapDeps([120,22,23,8,30,33,18,34,15,45,47,48,110,91,58,59])))}),bae=mt({getParentRoute:()=>Pn,path:"/",beforeLoad:({params:e})=>{throw Oc({to:"/$org/settings/general",params:{org:e.org}})},component:()=>null}),wae=mt({getParentRoute:()=>Pn,path:"/connections",component:It(()=>At(()=>import("./connections-CrOLesap.js"),__vite__mapDeps([121,77,78,122,80,1,34,36,28,23,115,98,117,39,97,93,92,94,71,11,12,13,95,96,76,87,60,37,25,26,27,29,30,31,32,33,18,19,2,35,38,20,22,8,40,15,41,42,43,44,45,46,47,48,105,123,65,101,124,125,75,7,63,66,17,4,81,99,56,100]))),validateSearch:ul(()=>Ee({action:dn(["create"]).optional(),tab:dn(["all","connected"]).optional()}))}),Sae=mt({getParentRoute:()=>Pn,path:"/connections/$appSlug",component:It(()=>At(()=>import("./connection-detail-G5l6bgwi.js"),__vite__mapDeps([126,77,78,105,100,4,43,46,127,12,68,25,26,27,28,29,30,31,32,33,18,19,1,2,34,35,36,37,38,20,39,22,23,8,40,15,41,42,44,45,47,48,71,11,128,129,76,94,13,81,109,62,56,104,73,113,98,54,130,131,64,79,60,66,17,123,65,132,133,92,74,87,80]))),validateSearch:ul(()=>Ee({tab:z().optional()}))}),Eae=mt({getParentRoute:()=>Pn,path:"/connections/$appSlug/$collectionName/$itemId",component:It(()=>At(()=>import("./collection-detail-BnoKU_uS.js"),__vite__mapDeps([134,105,11,12,66,17,4,99,132,22,23,8,135,128,78,129,56,136,50,111,25,26,27,28,29,30,31,32,33,18,19,1,2,34,35,36,37,38,20,39,40,15,41,42,43,44,45,46,47,48,98,81,115,71,68,7,90,80,60,114,67,137,59,54,127,76,77,94,13,109,62,104,73,92,113,53,55,57,58,10,6,9,14]))),validateSearch:ul(()=>Ee({replayId:z().optional()}))}),xae=mt({getParentRoute:()=>Pn,path:"/monitor",component:It(()=>At(()=>import("./index-CYY5hWbm.js"),__vite__mapDeps([138,117,39,22,23,8,105,98,62,1,31,42,25,26,27,28,29,30,32,33,18,19,2,34,35,36,37,38,20,40,15,41,43,44,45,46,47,48,136,50,130,131,71,11,12,56,4,75,108,109,81,114,99,97,70,17,60,64,87,133,129,68,92,102,96,139,101,95,49,51,52,7,53,54,55,57,58,59,10,13,6,9,14,106]))),validateSearch:ul(()=>Ee({tab:dn(["overview","audit","threads"]).default("overview"),from:z().default("now-30m"),to:z().default("now"),connectionId:Ie(z()).optional().default([]),virtualMcpId:Ie(z()).optional().default([]),tool:z().default(""),status:dn(["all","success","errors"]).default("all"),search:z().default(""),page:St().optional(),streaming:Pt().default(!0),propertyFilters:z().default(""),hideSystem:Pt().default(!1)}))}),Rae=mt({getParentRoute:()=>Pn,path:"/general",component:It(()=>At(()=>import("./general-CVe1Krdt.js"),__vite__mapDeps([140,22,23,8,131,85,64,47,4,86,87,32,141,89,12,70,103,39,56,11,62,61,25,26,27,28,29,30,31,33,18,19,1,2,34,35,36,37,38,20,40,15,41,42,43,44,45,46,48,60,13])))}),Oae=mt({getParentRoute:()=>Pn,path:"/features",component:It(()=>At(()=>import("./features-Ddtjf7i2.js"),__vite__mapDeps([142,22,23,8,13,12,70,37,86,87,32])))}),Tae=mt({getParentRoute:()=>Pn,path:"/brand-context",component:It(()=>At(()=>import("./brand-context-Cy-kcB0m.js"),__vite__mapDeps([143,12,2,34,38,40,43,46,48,65,4,99,22,23,8,89,85])))}),Cae=mt({getParentRoute:()=>Pn,path:"/ai-providers",component:It(()=>At(()=>import("./ai-providers-BxrN55-q.js"),__vite__mapDeps([144,83,75,1,4,7,8,63,23,81,2,35,61,27,29,39,44,57,12,55,56,11,58,59,10,13,84,48,85,26,19,46,22,86,87,32,70,82,64,47,65,88,52,89])))}),Aae=mt({getParentRoute:()=>Pn,path:"/members",component:It(()=>At(()=>import("./members-B72381x1.js"),__vite__mapDeps([145,122,80,1,34,36,28,23,115,98,117,39,22,8,146,139,105,7,66,17,81,2,35,99,131,147,130,12,65,64,47,87,45,46,75,108,109,62,43])))}),Iae=mt({getParentRoute:()=>Pn,path:"/roles",component:It(()=>At(()=>import("./roles-BRZ0jwUp.js"),__vite__mapDeps([148,147,131,98,65,80,1,34,36,15,43,46,146,139,28,22,23,8,105,117,39,84,60,37,25,26,27,29,30,31,32,33,18,19,2,35,38,20,40,41,42,44,45,47,48,101,75,102,96,12,74,130,71,11,57,64,70,86,87]))),validateSearch:ul(()=>Ee({role:z().optional()}))}),Mae=mt({getParentRoute:()=>Pn,path:"/sso",component:It(()=>At(()=>import("./sso-BuTvljxJ.js"),__vite__mapDeps([149,141,89,12,70,86,87,32,22,23,8,4,14,46])))}),Pae=mt({getParentRoute:()=>Pn,path:"/profile",component:It(()=>At(()=>import("./profile-C0pKX75D.js"),__vite__mapDeps([150,22,23,8,64,47,70,81,1,2,35,82,4,41,42,85,91,67,86,87,32])))}),Nae=mt({getParentRoute:()=>Pn,path:"/store",component:It(()=>At(()=>import("./store-Iw0YIysI.js"),__vite__mapDeps([151,26,34,43,46,4,70,61,64,47,62,71,11,12,22,23,8,94,13,86,87,32])))}),kae=mt({getParentRoute:()=>Pn,path:"/registry",component:It(()=>At(()=>import("./registry-Bhz5Jlkf.js"),[]))}),Dae=mt({getParentRoute:()=>Pn,path:"/store/registry",component:It(()=>At(()=>import("./store-registry-Df9fj_hE.js"),[]))}),Lae=mt({getParentRoute:()=>Pn,path:"/workflows",component:It(()=>At(()=>import("./workflow-D5sDlQLV.js"),__vite__mapDeps([152,12,77,78,122,80,1,34,36,28,23,115,98,74,39,87,60,37,25,26,27,29,30,31,32,33,18,19,2,35,38,20,22,8,40,15,41,42,43,44,45,46,47,48,146,139,137,112,64,105,124,125,92,65,11,71,132])))}),$ae=mt({getParentRoute:()=>Pn,path:"/workflows/$itemId",component:It(()=>At(()=>import("./workflow-detail-BKMBH1Ij.js"),__vite__mapDeps([153,135,128,12,78,129,56,11,136,50,111,25,26,27,28,29,30,31,32,33,18,19,1,2,34,35,36,37,38,20,39,22,23,8,40,15,41,42,43,44,45,46,47,48,98,81,115,132,71,68,7,90,80,60,114,67,137,59,4])))}),jae=mt({getParentRoute:()=>sE,path:"/plugins/$pluginId",component:It(()=>At(()=>import("./org-plugin-layout-C4CnG2ku.js"),__vite__mapDeps([154,155,71,11,12,44,22,23,8])))}),Uae=mt({getParentRoute:()=>Pn,path:"/agents",component:It(()=>At(()=>import("./agents-list-CH2sTwpj.js"),__vite__mapDeps([156,80,1,34,36,18,72,12,73,56,11,7,8,29,74,39,75,71,15,25,26,27,28,30,31,32,33,19,2,35,37,38,20,22,23,40,41,42,43,44,45,46,47,48,76,77,78,63,60,68,87,88,52,105,104,65,117])))}),zae=mt({getParentRoute:()=>Pn,path:"/automations",component:It(()=>At(()=>import("./automations-DFRPWAOO.js"),__vite__mapDeps([157,43,48,117,39,22,23,8,105,116,65,80,1,34,36,25,26,27,28,29,30,31,32,33,18,19,2,35,37,38,20,40,15,41,42,44,45,46,47,56,11,12,73])))}),T6=mt({getParentRoute:()=>O6,path:"/$pluginId",component:It(()=>At(()=>import("./dynamic-plugin-layout-DAf8nhzs.js"),__vite__mapDeps([158,155,71,11,12,44,22,23,8])))}),Fae=[],Bae=[],Vae=[],C6=[];uae.forEach(e=>{if(!e.setup)return;const t={parentRoute:T6,routing:{createRoute:mt,lazyRouteComponent:It},registerRootSidebarItem:n=>Fae.push({pluginId:e.id,...n}),registerSidebarGroup:n=>Bae.push({pluginId:e.id,...n}),registerSettingsSidebarItem:n=>Vae.push({pluginId:e.id,...n}),registerPluginRoutes:n=>{C6.push(...n)}};e.setup(t)});const qae=T6.addChildren(C6),Hae=Pn.addChildren([bae,wae,Sae,Eae,Uae,zae,xae,Rae,Oae,Tae,Cae,Aae,Iae,Mae,Pae,Nae,Dae,kae,Lae,$ae]),Gae=O6.addChildren([qae]),Kae=sE.addChildren([Gae,jae]),Zae=oE.addChildren([yae,Kae]),Yae=iE.addChildren([Zae,Hae]),Wae=rE.addChildren([gae,Yae]),Qae=ma.addChildren([Wae,vae,dae,fae,hae,pae,mae]),Xae=u7({routeTree:Qae,defaultNotFoundComponent:()=>T.jsx("div",{className:"flex h-full items-center justify-center",children:T.jsxs("div",{className:"flex flex-col items-center gap-4 p-8",children:[T.jsx("h3",{className:"text-lg font-medium text-foreground",children:"Page not found"}),T.jsx("p",{className:"text-sm text-muted-foreground text-center max-w-[300px]",children:"The page you are looking for does not exist or has been moved."}),T.jsx("button",{type:"button",onClick:()=>window.history.back(),className:"text-sm text-primary hover:underline",children:"Go back"})]})})}),Jae=document.getElementById("root");Q$.createRoot(Jae).render(T.jsx(I.StrictMode,{children:T.jsx(h7,{router:Xae})}));export{KM as $,Mle as A,W1 as B,To as C,tG as D,ice as E,ece as F,nce as G,Ee as H,St as I,z as J,GM as K,fw as L,$D as M,cle as N,mP as O,Yse as P,Gse as Q,Rg as R,jD as S,LJ as T,Yr as U,Jle as V,Fae as W,Bae as X,oae as Y,DD as Z,At as _,kj as a,Ye as a$,sle as a0,xo as a1,eee as a2,ht as a3,no as a4,cW as a5,uW as a6,yn as a7,lt as a8,dW as a9,t3 as aA,sY as aB,cY as aC,aY as aD,ZZ as aE,Ole as aF,Vae as aG,tle as aH,Ut as aI,Xt as aJ,Ie as aK,JH as aL,Xle as aM,Qle as aN,HS as aO,vg as aP,DY as aQ,x3 as aR,X4 as aS,lf as aT,ta as aU,kY as aV,ds as aW,y4 as aX,jw as aY,Wr as aZ,Pt as a_,fW as aa,mW as ab,bW as ac,I3 as ad,fl as ae,hW as af,pW as ag,gW as ah,vW as ai,_W as aj,yW as ak,wW as al,EW as am,xW as an,Ig as ao,dn as ap,fC as aq,Q1 as ar,iY as as,ro as at,Kd as au,Ww as av,jc as aw,aa as ax,fs as ay,io as az,Mg as b,nZ as b$,RV as b0,BP as b1,pw as b2,Rk as b3,Tk as b4,YW as b5,Wn as b6,wQ as b7,d3 as b8,Q4 as b9,wre as bA,xre as bB,Dre as bC,Zre as bD,Qre as bE,bre as bF,Sre as bG,Rre as bH,Ore as bI,Lre as bJ,qre as bK,qle as bL,uae as bM,pV as bN,ule as bO,mle as bP,gq as bQ,ul as bR,VN as bS,GN as bT,fle as bU,rce as bV,rG as bW,nG as bX,u4 as bY,pf as bZ,eZ as b_,rae as ba,la as bb,ne as bc,ele as bd,iZ as be,Lle as bf,uP as bg,ca as bh,as as bi,Dle as bj,$le as bk,rn as bl,dle as bm,qN as bn,zre as bo,Fre as bp,VS as bq,l6 as br,qS as bs,nv as bt,GD as bu,tie as bv,ZD as bw,Wre as bx,cie as by,yre as bz,nae as c,n6 as c$,rZ as c0,af as c1,qM as c2,Aj as c3,S3 as c4,wY as c5,Fw as c6,h3 as c7,k4 as c8,Bw as c9,Wle as cA,eoe as cB,pt as cC,Hoe as cD,to as cE,XW as cF,fP as cG,Ale as cH,oZ as cI,sZ as cJ,tZ as cK,aZ as cL,Bz as cM,HD as cN,YD as cO,XD as cP,e6 as cQ,t6 as cR,r6 as cS,Ble as cT,Vle as cU,zle as cV,Fle as cW,Jne as cX,Ule as cY,WD as cZ,JD as c_,Gd as ca,R4 as cb,zw as cc,Uw as cd,SY as ce,EY as cf,oQ as cg,sQ as ch,iQ as ci,Or as cj,lle as ck,QH as cl,YH as cm,HH as cn,n4 as co,HV as cp,Sw as cq,EV as cr,hle as cs,ZV as ct,xw as cu,Ew as cv,XV as cw,ple as cx,Yle as cy,_se as cz,dw as d,Gle as d0,QD as d1,Zle as d2,kS as d3,fre as d4,jle as d5,qD as d6,Die as d7,Vre as d8,Kle as d9,Tie as da,Iie as db,die as dc,uie as dd,Hle as de,gle as df,BW as dg,VW as dh,GW as di,qW as dj,HW as dk,yle as dl,ble as dm,xle as dn,Rle as dp,Tle as dq,Ele as dr,Sle as ds,wle as dt,_le as du,vle as dv,UM as dw,yO as dx,rle as dy,nle as dz,Ro as e,rf as f,uw as g,Ple as h,Ile as i,T as j,Nle as k,LD as l,tce as m,Nj as n,nw as o,PM as p,Zn as q,I as r,Xne as s,kle as t,ale as u,ole as v,HM as w,RT as x,NS as y,Oo as z};
171
+ `),document.head.appendChild(r)}}function Jse(e){const t=Ro.c(9),{children:n}=e;let r;t[0]===Symbol.for("react.memo_cache_sentinel")?(r={queryKey:GM.publicConfig(),queryFn:Qse,staleTime:1/0},t[0]=r):r=t[0];const{data:i}=HM(r),[s]=Yse();i.internalUrl&&Use(i.internalUrl);let l,c;t[1]!==i.theme?(l=()=>{Xse(i.theme)},c=[i.theme],t[1]=i.theme,t[2]=l,t[3]=c):(l=t[2],c=t[3]),I.useLayoutEffect(l,c);let d,f;t[4]!==s.theme?(d=()=>{const p=document.documentElement;if(s.theme==="dark"){p.classList.add("dark");return}if(s.theme==="light"){p.classList.remove("dark");return}const g=window.matchMedia("(prefers-color-scheme: dark)"),v=b=>p.classList.toggle("dark",b);v(g.matches);const y=b=>v(b.matches);return g.addEventListener("change",y),()=>g.removeEventListener("change",y)},f=[s.theme],t[4]=s.theme,t[5]=d,t[6]=f):(d=t[5],f=t[6]),I.useLayoutEffect(d,f);let m;return t[7]!==n?(m=T.jsx(T.Fragment,{children:n}),t[7]=n,t[8]=m):m=t[8],m}const eae=new bj({defaultOptions:{queries:{staleTime:6e4,refetchOnWindowFocus:!0,refetchOnMount:!0,retry:1,gcTime:300*1e3}}});function tae(e){const t=Ro.c(4),{children:n}=e;let r;t[0]===Symbol.for("react.memo_cache_sentinel")?(r=T.jsx(hH,{}),t[0]=r):r=t[0];let i;t[1]===Symbol.for("react.memo_cache_sentinel")?(i=T.jsx(jD,{}),t[1]=i):i=t[1];let s;return t[2]!==n?(s=T.jsxs(wj,{client:eae,children:[r,T.jsx(I.Suspense,{fallback:i,children:T.jsx(Jse,{children:T.jsx(Lj,{children:T.jsx(Fee,{children:T.jsx(Wne,{children:n})})})})})]}),t[2]=n,t[3]=s):s=t[3],s}function nae(...e){return BP(pw(e))}const rae=y4("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-lg text-sm transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/20 focus-visible:ring-[2px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/80",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",outline:"text-foreground bg-background hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:hover:bg-input/50 card-shadow",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",success:"bg-success text-success-foreground hover:bg-success/90 focus-visible:ring-success/20 dark:focus-visible:ring-success/40",special:"bg-special text-special-foreground hover:bg-special/90 focus-visible:ring-special/20 dark:focus-visible:ring-special/40",ghost:"hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",link:"text-foreground/80 hover:text-foreground"},size:{default:"h-8 px-3 has-[>svg]:px-2.5",sm:"h-7 gap-1.5 px-2.5 has-[>svg]:px-2",xs:"h-6 gap-1 px-1.5 text-xs has-[>svg]:px-1",lg:"h-10 px-3.5 has-[>svg]:px-3",icon:"size-8","icon-sm":"size-7"}},defaultVariants:{variant:"default",size:"default"}});function W1(e){const t=Ro.c(14);let n,r,i,s,l;t[0]!==e?({className:n,variant:l,size:i,asChild:s,...r}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=s,t[5]=l):(n=t[1],r=t[2],i=t[3],s=t[4],l=t[5]);const d=(s===void 0?!1:s)?jw:"button";let f;t[6]!==n||t[7]!==i||t[8]!==l?(f=nae(rae({variant:l,size:i,className:n})),t[6]=n,t[7]=i,t[8]=l,t[9]=f):f=t[9];let m;return t[10]!==d||t[11]!==r||t[12]!==f?(m=T.jsx(d,{"data-slot":"button",className:f,...r}),t[10]=d,t[11]=r,t[12]=f,t[13]=m):m=t[13],m}const CM="__mesh_chunk_reload_ts";function AM(e){if(!e)return!1;const t=e.message||"";return t.includes("Failed to fetch dynamically imported module")||t.includes("Importing a module script failed")||t.includes("error loading dynamically imported module")||t.includes("Failed to fetch")&&e.name==="TypeError"}class ice extends I.Component{state={hasError:!1,error:null};static getDerivedStateFromError(t){return{hasError:!0,error:t}}componentDidCatch(t,n){console.error("Uncaught error:",t,n),kD(t,{boundary:"default",error_name:t.name,error_message:t.message,component_stack:n.componentStack??null,route:typeof window<"u"?window.location.pathname:null})}resetError=()=>{this.setState({hasError:!1,error:null})};render(){if(this.state.hasError){const{fallback:t}=this.props;return typeof t=="function"?t({error:this.state.error,resetError:this.resetError}):t!==void 0?t:T.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center h-full p-6 text-center space-y-4",children:[T.jsx("div",{className:"bg-destructive/10 p-3 rounded-full",children:T.jsx(NS,{className:"h-6 w-6 text-destructive"})}),T.jsxs("div",{className:"space-y-2",children:[T.jsx("h3",{className:"text-lg font-medium",children:"Something went wrong"}),T.jsx("p",{className:"text-sm text-muted-foreground max-w-xs mx-auto",children:this.state.error?.message||"An unexpected error occurred"})]}),T.jsx(W1,{variant:"outline",onClick:this.resetError,children:"Try again"})]})}return this.props.children}}class iae extends I.Component{state={hasError:!1,error:null};static getDerivedStateFromError(t){return{hasError:!0,error:t}}componentDidCatch(t,n){console.error("Uncaught error:",t,n);const r=AM(t);if(kD(t,{boundary:"chunk_root",is_chunk_load_error:r,error_name:t.name,error_message:t.message,component_stack:n.componentStack??null,route:typeof window<"u"?window.location.pathname:null}),!r)return;const i=sessionStorage.getItem(CM),s=Date.now();(!i||s-Number(i)>1e4)&&(sessionStorage.setItem(CM,String(s)),window.location.reload())}render(){return this.state.hasError&&AM(this.state.error)?T.jsxs("div",{className:"flex min-h-dvh flex-col items-center justify-center p-6 text-center space-y-4",children:[T.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:T.jsx($D,{className:"h-6 w-6 text-primary"})}),T.jsxs("div",{className:"space-y-2",children:[T.jsx("h3",{className:"text-lg font-medium",children:"New version available"}),T.jsx("p",{className:"text-sm text-muted-foreground max-w-xs mx-auto",children:"A new version has been deployed. Refresh to continue."})]}),T.jsx(W1,{onClick:()=>window.location.reload(),children:"Refresh"})]}):this.state.hasError?T.jsxs("div",{className:"flex min-h-dvh flex-col items-center justify-center p-6 text-center space-y-4",children:[T.jsx("div",{className:"bg-destructive/10 p-3 rounded-full",children:T.jsx(NS,{className:"h-6 w-6 text-destructive"})}),T.jsxs("div",{className:"space-y-2",children:[T.jsx("h3",{className:"text-lg font-medium",children:"Something went wrong"}),T.jsx("p",{className:"text-sm text-muted-foreground max-w-xs mx-auto",children:this.state.error?.message||"An unexpected error occurred"})]}),T.jsx(W1,{variant:"outline",onClick:()=>this.setState({hasError:!1,error:null}),children:"Try again"})]}):this.props.children}}const oae="MCP Workflows",sae="Create workflows using your MCP tools",aae=I.lazy(()=>At(()=>import("./plugin-header-2Ks_trAw.js"),__vite__mapDeps([0,1,2]))),lae=I.lazy(()=>At(()=>import("./plugin-empty-state-BSfCLmcP.js"),[])),cae={id:oae,description:sae,bindingName:"WORKFLOW",renderHeader:e=>T.jsx(aae,{...e}),renderEmptyState:()=>T.jsx(lae,{}),setup:e=>{e.registerSettingsSidebarItem({key:"workflows",icon:T.jsx(DD,{size:14}),label:"MCP Workflows",to:"/$org/settings/workflows"})}},uae=[cae],ma=t7({component:()=>T.jsx(iae,{children:T.jsx(tae,{children:T.jsx(I.Suspense,{fallback:T.jsx(jD,{}),children:T.jsx(mP,{})})})})}),dae=mt({getParentRoute:()=>ma,path:"/login",component:It(()=>At(()=>import("./login-HZPNR9xd.js"),__vite__mapDeps([3,4]))),validateSearch:ul(()=>Ee({next:z().optional(),client_id:z().optional(),redirect_uri:z().optional(),response_type:z().optional(),state:z().optional(),scope:z().optional(),code_challenge:z().optional(),code_challenge_method:z().optional()}))}),fae=mt({getParentRoute:()=>ma,path:"/reset-password",component:It(()=>At(()=>import("./reset-password-Bn__ApCp.js"),__vite__mapDeps([5,4]))),validateSearch:ul(()=>Ee({token:z().optional(),error:z().optional()}))}),hae=mt({getParentRoute:()=>ma,path:"/auth/$pathname",component:It(()=>At(()=>import("./auth-catchall-DoKHQvfb.js"),[]))}),pae=mt({getParentRoute:()=>ma,path:"/oauth/callback",component:It(()=>At(()=>import("./oauth-callback-Du4eDSpz.js"),[]))}),mae=mt({getParentRoute:()=>ma,path:"/oauth/callback/ai-provider",component:It(()=>At(()=>import("./oauth-callback-ai-provider-BhxrV53q.js"),[]))}),rE=mt({getParentRoute:()=>ma,id:"shell",component:It(()=>At(()=>import("./shell-layout-CtEV3YzW.js").then(e=>e.s),__vite__mapDeps([6,7,8,9,10,11,12,13,14,15])))}),gae=mt({getParentRoute:()=>rE,path:"/",beforeLoad:async()=>{const{data:e}=await Mg.organization.list();if(!e)return;const t=localStorage.getItem(Rg.lastOrgSlug());if(t){if(e.some(i=>i.slug===t))throw Oc({to:"/$org",params:{org:t}});localStorage.removeItem(Rg.lastOrgSlug())}const n=e[0];throw Oc(n?{to:"/$org",params:{org:n.slug}}:{to:"/onboarding"})}}),vae=mt({getParentRoute:()=>ma,path:"/onboarding",beforeLoad:async()=>{const{data:e}=await Mg.organization.list();if(e&&e.length>0)throw Oc({to:"/"})},component:It(()=>At(()=>import("./onboarding-HMRjmRyP.js"),__vite__mapDeps([16,9,4,17,18,19,20])))}),iE=mt({getParentRoute:()=>rE,path:"/$org",component:It(()=>At(()=>import("./org-layout-DoqHSWQn.js"),[]))}),oE=mt({getParentRoute:()=>iE,id:"org-shell",component:It(()=>At(()=>import("./index-BkJIlnCh.js"),__vite__mapDeps([21,22,23,8,24,25,26,27,28,29,30,31,32,33,18,19,1,2,34,35,36,37,38,20,39,40,15,41,42,43,44,45,46,47,48,6,7,9,10,11,12,13,14,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,17,4,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106])))}),sE=mt({getParentRoute:()=>oE,id:"agent-shell",component:It(()=>At(()=>import("./index-JYp8Y8Zk.js"),__vite__mapDeps([107,69,7,8,70,4,71,11,12,72,73,56,29,74,39,75,1,15,25,26,27,28,30,31,32,33,18,19,2,34,35,36,37,38,20,22,23,40,41,42,43,44,45,46,47,48,76,77,78,63,60,68,55,57,58,59,10,13,6,9,14,49,50,51,52,53,54,79,66,17,80,81,82,83,61,84,85,86,87,64,65,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,108,109,62,24,67,103,104,105,106,110,111,112,113,114,115,116,117,118])))}),_ae=Ee({virtualmcpid:z().optional(),tab:z().optional(),main:z().optional(),id:z().optional(),toolName:z().optional(),tasks:St().optional(),mainOpen:St().optional(),chat:St().optional(),autosend:z().optional()}),O6=mt({getParentRoute:()=>sE,path:"/$taskId",validateSearch:_ae,component:()=>null}),yae=mt({getParentRoute:()=>oE,path:"/",component:It(()=>At(()=>import("./index-DqWmbGe9.js"),__vite__mapDeps([119,60,37,25,26,27,28,29,30,31,32,33,18,19,1,2,34,35,36,38,20,39,22,23,8,40,15,41,42,43,44,45,46,47,48,61,12,56,11,13,72,73,7,74,75,71,76,77,78,63,68,69,70,4,55,57,58,59,10,6,9,14,49,50,51,52,53,54,79,66,17,80,81,82,83,84,85,86,87,64,65,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102,104])))}),Pn=mt({getParentRoute:()=>iE,path:"/settings",component:It(()=>At(()=>import("./settings-layout-ePFy_Zf4.js"),__vite__mapDeps([120,22,23,8,30,33,18,34,15,45,47,48,110,91,58,59])))}),bae=mt({getParentRoute:()=>Pn,path:"/",beforeLoad:({params:e})=>{throw Oc({to:"/$org/settings/general",params:{org:e.org}})},component:()=>null}),wae=mt({getParentRoute:()=>Pn,path:"/connections",component:It(()=>At(()=>import("./connections-I35i0t7r.js"),__vite__mapDeps([121,77,78,122,80,1,34,36,28,23,115,98,117,39,97,93,92,94,71,11,12,13,95,96,76,87,60,37,25,26,27,29,30,31,32,33,18,19,2,35,38,20,22,8,40,15,41,42,43,44,45,46,47,48,105,123,65,101,124,125,75,7,63,66,17,4,81,99,56,100]))),validateSearch:ul(()=>Ee({action:dn(["create"]).optional(),tab:dn(["all","connected"]).optional()}))}),Sae=mt({getParentRoute:()=>Pn,path:"/connections/$appSlug",component:It(()=>At(()=>import("./connection-detail-EgRvIktM.js"),__vite__mapDeps([126,77,78,105,100,4,43,46,127,12,68,25,26,27,28,29,30,31,32,33,18,19,1,2,34,35,36,37,38,20,39,22,23,8,40,15,41,42,44,45,47,48,71,11,128,129,76,94,13,81,109,62,56,104,73,113,98,54,130,131,64,79,60,66,17,123,65,132,133,92,74,87,80]))),validateSearch:ul(()=>Ee({tab:z().optional()}))}),Eae=mt({getParentRoute:()=>Pn,path:"/connections/$appSlug/$collectionName/$itemId",component:It(()=>At(()=>import("./collection-detail-CvBw6hsJ.js"),__vite__mapDeps([134,105,11,12,66,17,4,99,132,22,23,8,135,128,78,129,56,136,50,111,25,26,27,28,29,30,31,32,33,18,19,1,2,34,35,36,37,38,20,39,40,15,41,42,43,44,45,46,47,48,98,81,115,71,68,7,90,80,60,114,67,137,59,54,127,76,77,94,13,109,62,104,73,92,113,53,55,57,58,10,6,9,14]))),validateSearch:ul(()=>Ee({replayId:z().optional()}))}),xae=mt({getParentRoute:()=>Pn,path:"/monitor",component:It(()=>At(()=>import("./index-Bzh6y1DZ.js"),__vite__mapDeps([138,117,39,22,23,8,105,98,62,1,31,42,25,26,27,28,29,30,32,33,18,19,2,34,35,36,37,38,20,40,15,41,43,44,45,46,47,48,136,50,130,131,71,11,12,56,4,75,108,109,81,114,99,97,70,17,60,64,87,133,129,68,92,102,96,139,101,95,49,51,52,7,53,54,55,57,58,59,10,13,6,9,14,106]))),validateSearch:ul(()=>Ee({tab:dn(["overview","audit","threads"]).default("overview"),from:z().default("now-30m"),to:z().default("now"),connectionId:Ie(z()).optional().default([]),virtualMcpId:Ie(z()).optional().default([]),tool:z().default(""),status:dn(["all","success","errors"]).default("all"),search:z().default(""),page:St().optional(),streaming:Pt().default(!0),propertyFilters:z().default(""),hideSystem:Pt().default(!1)}))}),Rae=mt({getParentRoute:()=>Pn,path:"/general",component:It(()=>At(()=>import("./general-Bi8iKo_s.js"),__vite__mapDeps([140,22,23,8,131,85,64,47,4,86,87,32,141,89,12,70,103,39,56,11,62,61,25,26,27,28,29,30,31,33,18,19,1,2,34,35,36,37,38,20,40,15,41,42,43,44,45,46,48,60,13])))}),Oae=mt({getParentRoute:()=>Pn,path:"/features",component:It(()=>At(()=>import("./features-ymCT4sQe.js"),__vite__mapDeps([142,22,23,8,13,12,70,37,86,87,32])))}),Tae=mt({getParentRoute:()=>Pn,path:"/brand-context",component:It(()=>At(()=>import("./brand-context-B00HyWuJ.js"),__vite__mapDeps([143,12,2,34,38,40,43,46,48,65,4,99,22,23,8,89,85])))}),Cae=mt({getParentRoute:()=>Pn,path:"/ai-providers",component:It(()=>At(()=>import("./ai-providers-28dSCs53.js"),__vite__mapDeps([144,83,75,1,4,7,8,63,23,81,2,35,61,27,29,39,44,57,12,55,56,11,58,59,10,13,84,48,85,26,19,46,22,86,87,32,70,82,64,47,65,88,52,89])))}),Aae=mt({getParentRoute:()=>Pn,path:"/members",component:It(()=>At(()=>import("./members-DXQFXjq8.js"),__vite__mapDeps([145,122,80,1,34,36,28,23,115,98,117,39,22,8,146,139,105,7,66,17,81,2,35,99,131,147,130,12,65,64,47,87,45,46,75,108,109,62,43])))}),Iae=mt({getParentRoute:()=>Pn,path:"/roles",component:It(()=>At(()=>import("./roles-C4lGMFwb.js"),__vite__mapDeps([148,147,131,98,65,80,1,34,36,15,43,46,146,139,28,22,23,8,105,117,39,84,60,37,25,26,27,29,30,31,32,33,18,19,2,35,38,20,40,41,42,44,45,47,48,101,75,102,96,12,74,130,71,11,57,64,70,86,87]))),validateSearch:ul(()=>Ee({role:z().optional()}))}),Mae=mt({getParentRoute:()=>Pn,path:"/sso",component:It(()=>At(()=>import("./sso-DElvxw59.js"),__vite__mapDeps([149,141,89,12,70,86,87,32,22,23,8,4,14,46])))}),Pae=mt({getParentRoute:()=>Pn,path:"/profile",component:It(()=>At(()=>import("./profile-CjGu4VCE.js"),__vite__mapDeps([150,22,23,8,64,47,70,81,1,2,35,82,4,41,42,85,91,67,86,87,32])))}),Nae=mt({getParentRoute:()=>Pn,path:"/store",component:It(()=>At(()=>import("./store-CQloMsrY.js"),__vite__mapDeps([151,26,34,43,46,4,70,61,64,47,62,71,11,12,22,23,8,94,13,86,87,32])))}),kae=mt({getParentRoute:()=>Pn,path:"/registry",component:It(()=>At(()=>import("./registry-YuZMNy-0.js"),[]))}),Dae=mt({getParentRoute:()=>Pn,path:"/store/registry",component:It(()=>At(()=>import("./store-registry-h--qJyio.js"),[]))}),Lae=mt({getParentRoute:()=>Pn,path:"/workflows",component:It(()=>At(()=>import("./workflow-DgvsxaIb.js"),__vite__mapDeps([152,12,77,78,122,80,1,34,36,28,23,115,98,74,39,87,60,37,25,26,27,29,30,31,32,33,18,19,2,35,38,20,22,8,40,15,41,42,43,44,45,46,47,48,146,139,137,112,64,105,124,125,92,65,11,71,132])))}),$ae=mt({getParentRoute:()=>Pn,path:"/workflows/$itemId",component:It(()=>At(()=>import("./workflow-detail-Bebyclsh.js"),__vite__mapDeps([153,135,128,12,78,129,56,11,136,50,111,25,26,27,28,29,30,31,32,33,18,19,1,2,34,35,36,37,38,20,39,22,23,8,40,15,41,42,43,44,45,46,47,48,98,81,115,132,71,68,7,90,80,60,114,67,137,59,4])))}),jae=mt({getParentRoute:()=>sE,path:"/plugins/$pluginId",component:It(()=>At(()=>import("./org-plugin-layout-DXqded6M.js"),__vite__mapDeps([154,155,71,11,12,44,22,23,8])))}),Uae=mt({getParentRoute:()=>Pn,path:"/agents",component:It(()=>At(()=>import("./agents-list-CLJAN1rm.js"),__vite__mapDeps([156,80,1,34,36,18,72,12,73,56,11,7,8,29,74,39,75,71,15,25,26,27,28,30,31,32,33,19,2,35,37,38,20,22,23,40,41,42,43,44,45,46,47,48,76,77,78,63,60,68,87,88,52,105,104,65,117])))}),zae=mt({getParentRoute:()=>Pn,path:"/automations",component:It(()=>At(()=>import("./automations-CVam3JT8.js"),__vite__mapDeps([157,43,48,117,39,22,23,8,105,116,65,80,1,34,36,25,26,27,28,29,30,31,32,33,18,19,2,35,37,38,20,40,15,41,42,44,45,46,47,56,11,12,73])))}),T6=mt({getParentRoute:()=>O6,path:"/$pluginId",component:It(()=>At(()=>import("./dynamic-plugin-layout-JwST599m.js"),__vite__mapDeps([158,155,71,11,12,44,22,23,8])))}),Fae=[],Bae=[],Vae=[],C6=[];uae.forEach(e=>{if(!e.setup)return;const t={parentRoute:T6,routing:{createRoute:mt,lazyRouteComponent:It},registerRootSidebarItem:n=>Fae.push({pluginId:e.id,...n}),registerSidebarGroup:n=>Bae.push({pluginId:e.id,...n}),registerSettingsSidebarItem:n=>Vae.push({pluginId:e.id,...n}),registerPluginRoutes:n=>{C6.push(...n)}};e.setup(t)});const qae=T6.addChildren(C6),Hae=Pn.addChildren([bae,wae,Sae,Eae,Uae,zae,xae,Rae,Oae,Tae,Cae,Aae,Iae,Mae,Pae,Nae,Dae,kae,Lae,$ae]),Gae=O6.addChildren([qae]),Kae=sE.addChildren([Gae,jae]),Zae=oE.addChildren([yae,Kae]),Yae=iE.addChildren([Zae,Hae]),Wae=rE.addChildren([gae,Yae]),Qae=ma.addChildren([Wae,vae,dae,fae,hae,pae,mae]),Xae=u7({routeTree:Qae,defaultNotFoundComponent:()=>T.jsx("div",{className:"flex h-full items-center justify-center",children:T.jsxs("div",{className:"flex flex-col items-center gap-4 p-8",children:[T.jsx("h3",{className:"text-lg font-medium text-foreground",children:"Page not found"}),T.jsx("p",{className:"text-sm text-muted-foreground text-center max-w-[300px]",children:"The page you are looking for does not exist or has been moved."}),T.jsx("button",{type:"button",onClick:()=>window.history.back(),className:"text-sm text-primary hover:underline",children:"Go back"})]})})}),Jae=document.getElementById("root");Q$.createRoot(Jae).render(T.jsx(I.StrictMode,{children:T.jsx(h7,{router:Xae})}));export{KM as $,Mle as A,W1 as B,To as C,tG as D,ice as E,ece as F,nce as G,Ee as H,St as I,z as J,GM as K,fw as L,$D as M,cle as N,mP as O,Yse as P,Gse as Q,Rg as R,jD as S,LJ as T,Yr as U,Jle as V,Fae as W,Bae as X,oae as Y,DD as Z,At as _,kj as a,Ye as a$,sle as a0,xo as a1,eee as a2,ht as a3,no as a4,cW as a5,uW as a6,yn as a7,lt as a8,dW as a9,t3 as aA,sY as aB,cY as aC,aY as aD,ZZ as aE,Ole as aF,Vae as aG,tle as aH,Ut as aI,Xt as aJ,Ie as aK,JH as aL,Xle as aM,Qle as aN,HS as aO,vg as aP,DY as aQ,x3 as aR,X4 as aS,lf as aT,ta as aU,kY as aV,ds as aW,y4 as aX,jw as aY,Wr as aZ,Pt as a_,fW as aa,mW as ab,bW as ac,I3 as ad,fl as ae,hW as af,pW as ag,gW as ah,vW as ai,_W as aj,yW as ak,wW as al,EW as am,xW as an,Ig as ao,dn as ap,fC as aq,Q1 as ar,iY as as,ro as at,Kd as au,Ww as av,jc as aw,aa as ax,fs as ay,io as az,Mg as b,nZ as b$,RV as b0,BP as b1,pw as b2,Rk as b3,Tk as b4,YW as b5,Wn as b6,wQ as b7,d3 as b8,Q4 as b9,wre as bA,xre as bB,Dre as bC,Zre as bD,Qre as bE,bre as bF,Sre as bG,Rre as bH,Ore as bI,Lre as bJ,qre as bK,qle as bL,uae as bM,pV as bN,ule as bO,mle as bP,gq as bQ,ul as bR,VN as bS,GN as bT,fle as bU,rce as bV,rG as bW,nG as bX,u4 as bY,pf as bZ,eZ as b_,rae as ba,la as bb,ne as bc,ele as bd,iZ as be,Lle as bf,uP as bg,ca as bh,as as bi,Dle as bj,$le as bk,rn as bl,dle as bm,qN as bn,zre as bo,Fre as bp,VS as bq,l6 as br,qS as bs,nv as bt,GD as bu,tie as bv,ZD as bw,Wre as bx,cie as by,yre as bz,nae as c,n6 as c$,rZ as c0,af as c1,qM as c2,Aj as c3,S3 as c4,wY as c5,Fw as c6,h3 as c7,k4 as c8,Bw as c9,Wle as cA,eoe as cB,pt as cC,Hoe as cD,to as cE,XW as cF,fP as cG,Ale as cH,oZ as cI,sZ as cJ,tZ as cK,aZ as cL,Bz as cM,HD as cN,YD as cO,XD as cP,e6 as cQ,t6 as cR,r6 as cS,Ble as cT,Vle as cU,zle as cV,Fle as cW,Jne as cX,Ule as cY,WD as cZ,JD as c_,Gd as ca,R4 as cb,zw as cc,Uw as cd,SY as ce,EY as cf,oQ as cg,sQ as ch,iQ as ci,Or as cj,lle as ck,QH as cl,YH as cm,HH as cn,n4 as co,HV as cp,Sw as cq,EV as cr,hle as cs,ZV as ct,xw as cu,Ew as cv,XV as cw,ple as cx,Yle as cy,_se as cz,dw as d,Gle as d0,QD as d1,Zle as d2,kS as d3,fre as d4,jle as d5,qD as d6,Die as d7,Vre as d8,Kle as d9,Tie as da,Iie as db,die as dc,uie as dd,Hle as de,gle as df,BW as dg,VW as dh,GW as di,qW as dj,HW as dk,yle as dl,ble as dm,xle as dn,Rle as dp,Tle as dq,Ele as dr,Sle as ds,wle as dt,_le as du,vle as dv,UM as dw,yO as dx,rle as dy,nle as dz,Ro as e,rf as f,uw as g,Ple as h,Ile as i,T as j,Nle as k,LD as l,tce as m,Nj as n,nw as o,PM as p,Zn as q,I as r,Xne as s,kle as t,ale as u,ole as v,HM as w,RT as x,NS as y,Oo as z};
@@ -1,4 +1,4 @@
1
- import{cj as ne,e as _,j as o,B as te,l as ln,bc as ze,ck as ms,r as T,s as oe,c as O,g as ps,o as cn,c5 as xs,a7 as hs,a8 as fe,aW as an,c6 as gs,aT as bs,c4 as Ss,c7 as un,b6 as js,cd as ys,ce as vs,ae as ws,cf as Ns,cl as $t,cm as dn,x as ks,y as _s,cn as Cs,co as Is}from"./index-BV4BlnS9.js";import{D as Ts,F as Es,B as $s}from"./index-CyJ-TyKU.js";import{e as Fe,i as Os,u as ae}from"./constants-Dm1wnwL3.js";import{b as fn}from"./use-virtual-mcp-BR6mzHHD.js";import{M as Re}from"./monaco-editor-_r7N6eV-.js";import{A as Rs,c as Ms,a as Ls,b as Ps,e as As,R as Ut,d as zs}from"./accordion-81SrnINF.js";import{B as le}from"./badge-tvsCFCHP.js";import{c as vt,S as wt,d as nt,b as Nt,a as kt}from"./select-DQy3AX-J.js";import{N as Ws,h as Ds,j as Fs,m as Be,P as Hs,i as Vs,R as Us,c as qs,k as Ks,e as qt,d as Bs,S as st}from"./index-B8A_ReFj.js";import{V as Xs}from"./view-mode-toggle-ZI-MN1pO.js";import{a9 as Js,aa as Gs,i as Qs,a1 as mn,ab as Ys,P as Zs,r as eo,ac as pn,Y as to,U as xn,ad as no,ae as so,S as bt,af as oo}from"./agent-icon-C2zAhw3X.js";import{i as hn}from"./Play-EPgISV5B.js";import{b as ro,a as io,V as Qe}from"./layout-GReGu88m.js";import{c as gn,T as bn,a as Sn,b as jn}from"./tooltip-DZT-1bal.js";import{u as lo,a as co}from"./use-connection-Ck4brnCx.js";import{u as Ot,d as Rt,b as yn}from"./use-mcp-tools-rNZ6JWxz.js";import{c as ao,d as uo,e as fo,D as mo,a as po,b as xo}from"./dialog-0SvGB_9G.js";import"./index-WBXV3t9A.js";import{S as ho}from"./index-DYUyKEVO.js";import{D as vn,a as wn,b as Nn,c as Ye}from"./dropdown-menu-BkrpBFy3.js";import{s as go}from"./Plus-BYimMcAW.js";import{b as kn}from"./Tool01-DVcjHQGB.js";import{i as He}from"./Check-DC_iCN8Z.js";import{s as Mt}from"./XClose-BdbZPqCd.js";import{I as Lt}from"./integration-icon-DgJZ63kl.js";import{a as bo,S as So}from"./scroll-area-Dal58SLb.js";import"./index-CEyiW6G-.js";import{i as _n}from"./X-QdBx5oCM.js";import{u as Cn,a as jo}from"./use-collections-ASqcb463.js";import{E as In}from"./empty-state-CxZybw5m.js";import{c as yo}from"./create-sse-subscription-CxkOgzKf.js";import{I as Kt}from"./input-Bs7mkNsF.js";const Tn=ne("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 En=ne("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 ot=ne("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);const rt=ne("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);const vo=ne("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);const $n=ne("Code",[["polyline",{points:"16 18 22 12 16 6",key:"z7tu5w"}],["polyline",{points:"8 6 2 12 8 18",key:"1eg1df"}]]);const wo=ne("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 On=ne("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 Rn=ne("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 Mn=ne("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 No=ne("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 Ln=ne("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);const Pn=ne("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 ko=ne("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 An=ne("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 _o(t){const e=_.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(Js,{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(ln,{size:14,className:"animate-spin"}):o.jsx(Gs,{size:14}),e[5]=r,e[6]=m):m=e[6];let x;e[7]!==r||e[8]!==n||e[9]!==a||e[10]!==m?(x=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]=x):x=e[11];let p;return e[12]!==f||e[13]!==x?(p=o.jsxs(o.Fragment,{children:[f,x]}),e[12]=f,e[13]=x,e[14]=p):p=e[14],p}const Bt=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(x=>x(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},Pt=(t=>t?Bt(t):Bt),Co=t=>t;function _t(t,e=Co){const n=ze.useSyncExternalStore(t.subscribe,ze.useCallback(()=>e(t.getState()),[t,e]),ze.useCallback(()=>e(t.getInitialState()),[t,e]));return ze.useDebugValue(n),n}const Io=t=>{const e=Pt(t),n=s=>_t(e,s);return Object.assign(n,e),n},To=(t=>Io);function zn(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 Ct=t=>e=>{try{const n=t(e);return n instanceof Promise?n:{then(s){return Ct(s)(n)},catch(s){return this}}}catch(n){return{then(s){return this},catch(s){return Ct(s)(n)}}}},Eo=(t,e)=>(n,s,i)=>{let r={storage:zn(()=>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 x=t((...g)=>(n(...g),f()),s,i);i.getInitialState=()=>x;let p;const h=()=>{var g,b;if(!d)return;const j=++c;l=!1,a.forEach(y=>{var S;return y((S=s())!=null?S:x)});const v=((b=r.onRehydrateStorage)==null?void 0:b.call(r,(g=s())!=null?g:x))||void 0;return Ct(d.getItem.bind(d))(r.name).then(y=>{if(y)if(typeof y.version=="number"&&y.version!==r.version){if(r.migrate){const S=r.migrate(y.state,y.version);return S instanceof Promise?S.then(w=>[!0,w]):[!0,S]}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 S;if(j!==c)return;const[w,N]=y;if(p=r.merge(N,(S=s())!=null?S:x),n(p,!0),w)return f()}).then(()=>{j===c&&(v?.(s(),void 0),p=s(),l=!0,u.forEach(y=>y(p)))}).catch(y=>{j===c&&v?.(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(),p||x},Wn=Eo,{useSyncExternalStoreWithSelector:$o}=ms,Oo=t=>t;function Ro(t,e=Oo,n){const s=$o(t.subscribe,t.getState,t.getInitialState,e,n);return ze.useDebugValue(s),s}const Xt=t=>Symbol.iterator in t,Jt=t=>"entries"in t,Gt=(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},Mo=(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 Lo(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:Xt(t)&&Xt(e)?Jt(t)&&Jt(e)?Gt(t,e):Mo(t,e):Gt({entries:()=>Object.entries(t)},{entries:()=>Object.entries(e)})}function Dn(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{cj as ne,e as _,j as o,B as te,l as ln,bc as ze,ck as ms,r as T,s as oe,c as O,g as ps,o as cn,c5 as xs,a7 as hs,a8 as fe,aW as an,c6 as gs,aT as bs,c4 as Ss,c7 as un,b6 as js,cd as ys,ce as vs,ae as ws,cf as Ns,cl as $t,cm as dn,x as ks,y as _s,cn as Cs,co as Is}from"./index-0dtUnOR1.js";import{D as Ts,F as Es,B as $s}from"./index-BAl-Vlym.js";import{e as Fe,i as Os,u as ae}from"./constants-CMPjFkrZ.js";import{b as fn}from"./use-virtual-mcp-Dndzl8Kr.js";import{M as Re}from"./monaco-editor-BaDnBAIf.js";import{A as Rs,c as Ms,a as Ls,b as Ps,e as As,R as Ut,d as zs}from"./accordion-CyIKHcCT.js";import{B as le}from"./badge-BXVtVPzt.js";import{c as vt,S as wt,d as nt,b as Nt,a as kt}from"./select-CG0rwGUX.js";import{N as Ws,h as Ds,j as Fs,m as Be,P as Hs,i as Vs,R as Us,c as qs,k as Ks,e as qt,d as Bs,S as st}from"./index-mKsCyZ2c.js";import{V as Xs}from"./view-mode-toggle-DoidsjaP.js";import{a9 as Js,aa as Gs,i as Qs,a1 as mn,ab as Ys,P as Zs,r as eo,ac as pn,Y as to,U as xn,ad as no,ae as so,S as bt,af as oo}from"./agent-icon-D9odI-qh.js";import{i as hn}from"./Play-DLW6aJFn.js";import{b as ro,a as io,V as Qe}from"./layout-DMQieMve.js";import{c as gn,T as bn,a as Sn,b as jn}from"./tooltip-XW5rFMNu.js";import{u as lo,a as co}from"./use-connection-DGPnnQz6.js";import{u as Ot,d as Rt,b as yn}from"./use-mcp-tools-DkxVTDC9.js";import{c as ao,d as uo,e as fo,D as mo,a as po,b as xo}from"./dialog-sfEBwtz9.js";import"./index-BG0omYxu.js";import{S as ho}from"./index-Cav3nFoE.js";import{D as vn,a as wn,b as Nn,c as Ye}from"./dropdown-menu-BpPFRti7.js";import{s as go}from"./Plus-28zZOE9T.js";import{b as kn}from"./Tool01-Cu4I31F8.js";import{i as He}from"./Check-Dgq0jjpz.js";import{s as Mt}from"./XClose-_Y5VAjW5.js";import{I as Lt}from"./integration-icon-CDE9CENl.js";import{a as bo,S as So}from"./scroll-area-yWZqBKom.js";import"./index-B_IvwEkx.js";import{i as _n}from"./X-CAquUT--.js";import{u as Cn,a as jo}from"./use-collections-BLOTVIAP.js";import{E as In}from"./empty-state-Vlkqr5Ha.js";import{c as yo}from"./create-sse-subscription-CxkOgzKf.js";import{I as Kt}from"./input-Dh3J6cxA.js";const Tn=ne("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 En=ne("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 ot=ne("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);const rt=ne("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);const vo=ne("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);const $n=ne("Code",[["polyline",{points:"16 18 22 12 16 6",key:"z7tu5w"}],["polyline",{points:"8 6 2 12 8 18",key:"1eg1df"}]]);const wo=ne("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 On=ne("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 Rn=ne("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 Mn=ne("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 No=ne("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 Ln=ne("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);const Pn=ne("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 ko=ne("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 An=ne("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 _o(t){const e=_.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(Js,{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(ln,{size:14,className:"animate-spin"}):o.jsx(Gs,{size:14}),e[5]=r,e[6]=m):m=e[6];let x;e[7]!==r||e[8]!==n||e[9]!==a||e[10]!==m?(x=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]=x):x=e[11];let p;return e[12]!==f||e[13]!==x?(p=o.jsxs(o.Fragment,{children:[f,x]}),e[12]=f,e[13]=x,e[14]=p):p=e[14],p}const Bt=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(x=>x(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},Pt=(t=>t?Bt(t):Bt),Co=t=>t;function _t(t,e=Co){const n=ze.useSyncExternalStore(t.subscribe,ze.useCallback(()=>e(t.getState()),[t,e]),ze.useCallback(()=>e(t.getInitialState()),[t,e]));return ze.useDebugValue(n),n}const Io=t=>{const e=Pt(t),n=s=>_t(e,s);return Object.assign(n,e),n},To=(t=>Io);function zn(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 Ct=t=>e=>{try{const n=t(e);return n instanceof Promise?n:{then(s){return Ct(s)(n)},catch(s){return this}}}catch(n){return{then(s){return this},catch(s){return Ct(s)(n)}}}},Eo=(t,e)=>(n,s,i)=>{let r={storage:zn(()=>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 x=t((...g)=>(n(...g),f()),s,i);i.getInitialState=()=>x;let p;const h=()=>{var g,b;if(!d)return;const j=++c;l=!1,a.forEach(y=>{var S;return y((S=s())!=null?S:x)});const v=((b=r.onRehydrateStorage)==null?void 0:b.call(r,(g=s())!=null?g:x))||void 0;return Ct(d.getItem.bind(d))(r.name).then(y=>{if(y)if(typeof y.version=="number"&&y.version!==r.version){if(r.migrate){const S=r.migrate(y.state,y.version);return S instanceof Promise?S.then(w=>[!0,w]):[!0,S]}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 S;if(j!==c)return;const[w,N]=y;if(p=r.merge(N,(S=s())!=null?S:x),n(p,!0),w)return f()}).then(()=>{j===c&&(v?.(s(),void 0),p=s(),l=!0,u.forEach(y=>y(p)))}).catch(y=>{j===c&&v?.(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(),p||x},Wn=Eo,{useSyncExternalStoreWithSelector:$o}=ms,Oo=t=>t;function Ro(t,e=Oo,n){const s=$o(t.subscribe,t.getState,t.getInitialState,e,n);return ze.useDebugValue(s),s}const Xt=t=>Symbol.iterator in t,Jt=t=>"entries"in t,Gt=(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},Mo=(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 Lo(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:Xt(t)&&Xt(e)?Jt(t)&&Jt(e)?Gt(t,e):Mo(t,e):Gt({entries:()=>Object.entries(t)},{entries:()=>Object.entries(e)})}function Dn(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,4 +1,4 @@
1
- import{cp as Fe,bn as Os,J as oe,I as ge,a_ as ti,bS as _i,aK as Ie,bl as mt,a$ as qe,ap as mr,cq as rn,H as _e,cr as Ii,cs as ws,ct as ec,bQ as tc,cu as ia,cv as nc,cw as rc,cx as ic,cy as fn,cz as Tr,cA as xs,bL as sa,bD as sc,aJ as ze,bR as oc,aI as On,bb as Ci,cB as ac,r as N,j as w,cC as oa,cD as lc}from"./index-BV4BlnS9.js";import{f as cc,h as uc,n as fc,j as dc,C as hc,A as pc}from"./constants-Dm1wnwL3.js";import{B as Ti,c as Pi}from"./collections-DKW_jlNs.js";import{R as Es}from"./index-WBXV3t9A.js";var mc=class{apply(e,t){if(!t.type)return;const n=Array.isArray(t.type)?t.type:[t.type],r=new Set(n);if(r.has("string")||(e.string=!1),!r.has("number")&&!r.has("integer")&&(e.number=!1),r.has("boolean")||(e.boolean=!1),r.has("null")||(e.null=!1),r.has("array")||(e.array=!1),r.has("object")||(e.object=!1),r.has("integer")&&e.number!==!1){const i=e.number||ge();i instanceof rn&&(e.number=i.int())}}},yc=class{apply(e,t){if(t.const===void 0)return;const n=t.const;e.string=!1,e.number=!1,e.boolean=!1,e.null=!1,e.array=!1,e.object=!1,typeof n=="string"?e.string=qe(n):typeof n=="number"?e.number=qe(n):typeof n=="boolean"?e.boolean=qe(n):n===null?e.null=_i():Array.isArray(n)?e.array=void 0:typeof n=="object"&&(e.object=void 0)}},gc=class{apply(e,t){if(!t.enum)return;if(t.enum.length===0){t.type||(e.string=!1,e.number=!1,e.boolean=!1,e.null=!1,e.array=!1,e.object=!1);return}const n={string:t.enum.filter(r=>typeof r=="string"),number:t.enum.filter(r=>typeof r=="number"),boolean:t.enum.filter(r=>typeof r=="boolean"),null:t.enum.filter(r=>r===null),array:t.enum.filter(r=>Array.isArray(r)),object:t.enum.filter(r=>typeof r=="object"&&r!==null&&!Array.isArray(r))};e.string=this.createTypeSchema(n.string,"string"),e.number=this.createTypeSchema(n.number,"number"),e.boolean=this.createTypeSchema(n.boolean,"boolean"),e.null=n.null.length>0?_i():!1,e.array=n.array.length>0?void 0:!1,e.object=n.object.length>0?void 0:!1}createTypeSchema(e,t){if(e.length===0)return!1;if(e.length===1)return qe(e[0]);if(t==="string")return mr(e);if(t==="number"){const[n,r,...i]=e;return mt([qe(n),qe(r),...i.map(s=>qe(s))])}return t==="boolean"?mt([qe(!0),qe(!1)]):!1}},bc=class{apply(e,t){const n=t;if(n.type==="string"&&n.format==="binary"&&n.contentEncoding==="binary"){let r=ic();n.minLength!==void 0&&(r=r.min(n.minLength)),n.maxLength!==void 0&&(r=r.max(n.maxLength)),n.contentMediaType!==void 0&&(r=r.mime(n.contentMediaType)),e.file=r,e.string=!1}}},Sc=class{apply(e,t){const n=t;t.type===void 0&&(n.minLength!==void 0||n.maxLength!==void 0||n.pattern!==void 0)&&e.string===void 0&&(e.string=oe())}},vc=class{apply(e,t){const n=t;if(n.minLength!==void 0&&e.string!==!1){const r=e.string||oe();r instanceof Ii&&(e.string=r.refine(i=>Array.from(i).length>=n.minLength,{message:`String must be at least ${n.minLength} characters long`}))}}},Oc=class{apply(e,t){const n=t;if(n.maxLength!==void 0&&e.string!==!1){const r=e.string||oe();r instanceof Ii&&(e.string=r.refine(i=>Array.from(i).length<=n.maxLength,{message:`String must be at most ${n.maxLength} characters long`}))}}},wc=class{apply(e,t){const n=t;if(n.pattern&&e.string!==!1){const r=e.string||oe();if(r instanceof Ii){const i=new RegExp(n.pattern);e.string=r.regex(i)}}}},xc=class{apply(e,t){const n=t;if(n.minimum!==void 0&&e.number!==!1){const r=e.number||ge();r instanceof rn&&(e.number=r.min(n.minimum))}}},Ec=class{apply(e,t){const n=t;if(n.maximum!==void 0&&e.number!==!1){const r=e.number||ge();r instanceof rn&&(e.number=r.max(n.maximum))}}},Ac=class{apply(e,t){const n=t;if(n.exclusiveMinimum!==void 0&&e.number!==!1){const r=e.number||ge();r instanceof rn&&(typeof n.exclusiveMinimum=="number"?e.number=r.gt(n.exclusiveMinimum):e.number=!1)}}},_c=class{apply(e,t){const n=t;if(n.exclusiveMaximum!==void 0&&e.number!==!1){const r=e.number||ge();r instanceof rn&&(typeof n.exclusiveMaximum=="number"?e.number=r.lt(n.exclusiveMaximum):e.number=!1)}}},Ic=class{apply(e,t){const n=t;if(n.multipleOf!==void 0&&e.number!==!1){const r=e.number||ge();r instanceof rn&&(e.number=r.refine(i=>{if(n.multipleOf===0)return!1;const s=i/n.multipleOf,o=Math.round(s),a=Math.min(Math.abs(i)*Number.EPSILON*10,Math.abs(n.multipleOf)*Number.EPSILON*10);return Math.abs(s-o)<=a/Math.abs(n.multipleOf)},{message:`Must be a multiple of ${n.multipleOf}`}))}}},Cc=class{apply(e,t){const n=t;t.type===void 0&&(n.minItems!==void 0||n.maxItems!==void 0||n.items!==void 0||n.prefixItems!==void 0)&&e.array===void 0&&(e.array=Ie(Fe()))}},Tc=class{apply(e,t){const n=t;n.minItems!==void 0&&e.array!==!1&&(e.array=(e.array||Ie(Fe())).min(n.minItems))}},Pc=class{apply(e,t){const n=t;n.maxItems!==void 0&&e.array!==!1&&(e.array=(e.array||Ie(Fe())).max(n.maxItems))}},Fc=class{apply(e,t){const n=t;if(e.array!==!1)if(Array.isArray(n.items))e.array=e.array||Ie(Fe());else if(n.items&&typeof n.items!="boolean"&&!n.prefixItems){const r=Ae(n.items);let i=Ie(r);if(e.array&&e.array instanceof ec){const s=e.array._def;s.checks&&s.checks.forEach(o=>{if(o._zod&&o._zod.def){const a=o._zod.def;a.check==="min_length"&&a.minimum!==void 0?i=i.min(a.minimum):a.check==="max_length"&&a.maximum!==void 0&&(i=i.max(a.maximum))}})}e.array=i}else typeof n.items=="boolean"&&n.items===!1?n.prefixItems?e.array=e.array||Ie(Fe()):e.array=Ie(Fe()).max(0):typeof n.items=="boolean"&&n.items===!0?e.array=e.array||Ie(Fe()):n.prefixItems&&(e.array=e.array||Ie(Fe()))}},jc=class{apply(e,t){if(t.type!=="array")return;const n=t;if(!Array.isArray(n.items)||e.array===!1)return;const r=n.items.map(s=>Ae(s));let i;r.length===0?i=ws([]):i=ws(r),n.minItems!==void 0&&n.minItems>r.length&&(i=!1),n.maxItems!==void 0&&n.maxItems<r.length&&(i=!1),e.tuple=i,e.array=!1}},$c=class{apply(e,t){const n=t;e.object!==!1&&(n.properties||n.required||n.additionalProperties!==void 0)&&(e.object=e.object||_e({}).passthrough())}},Dc=class{apply(e,t){const n=t;t.type===void 0&&(n.maxProperties!==void 0||n.minProperties!==void 0)&&e.object===void 0&&(e.object=_e({}).passthrough())}},Nc=class{apply(e,t){const n=t;if(n.maxProperties!==void 0&&e.object!==!1){const r=e.object||_e({}).passthrough();e.object=r.refine(i=>Object.keys(i).length<=n.maxProperties,{message:`Object must have at most ${n.maxProperties} properties`})}}},Rc=class{apply(e,t){const n=t;if(n.minProperties!==void 0&&e.object!==!1){const r=e.object||_e({}).passthrough();e.object=r.refine(i=>Object.keys(i).length>=n.minProperties,{message:`Object must have at least ${n.minProperties} properties`})}}};function Tn(e,t){if(e===t)return!0;if(e==null||t==null)return e===t;if(typeof e!=typeof t)return!1;if(Array.isArray(e)&&Array.isArray(t))return e.length!==t.length?!1:e.every((n,r)=>Tn(n,t[r]));if(typeof e=="object"&&typeof t=="object"){const n=Object.keys(e),r=Object.keys(t);return n.length!==r.length?!1:n.every(i=>r.includes(i)&&Tn(e[i],t[i]))}return!1}function Mc(){return e=>{if(!Array.isArray(e))return!0;const t=[];return e.every(n=>t.some(i=>Tn(n,i))?!1:(t.push(n),!0))}}function cr(e,t){return e.safeParse(t).success}var Uc=class{apply(e,t){if(!t.not)return e;const n=Ae(t.not);return e.refine(r=>!cr(n,r),{message:"Value must not match the 'not' schema"})}},kc=class{apply(e,t){return t.uniqueItems!==!0?e:e.refine(Mc(),{message:"Array items must be unique"})}},Lc=class{apply(e,t){return!t.allOf||t.allOf.length===0?e:t.allOf.map(r=>Ae(r)).reduce((r,i)=>ia(r,i),e)}},Bc=class{apply(e,t){if(!t.anyOf||t.anyOf.length===0)return e;const n=t.anyOf.length===1?Ae(t.anyOf[0]):mt([Ae(t.anyOf[0]),Ae(t.anyOf[1]),...t.anyOf.slice(2).map(r=>Ae(r))]);return ia(e,n)}},Wc=class{apply(e,t){if(!t.oneOf||t.oneOf.length===0)return e;const n=t.oneOf.map(r=>Ae(r));return e.refine(r=>{let i=0;for(const s of n)if(s.safeParse(r).success&&(i++,i>1))return!1;return i===1},{message:"Value must match exactly one of the oneOf schemas"})}},qc=class{apply(e,t){const n=t;if(n.prefixItems&&Array.isArray(n.prefixItems)){const i=n.prefixItems.map(s=>Ae(s));return e.refine(s=>{if(!Array.isArray(s))return!0;for(let o=0;o<Math.min(s.length,i.length);o++)if(!cr(i[o],s[o]))return!1;if(s.length>i.length){if(typeof n.items=="boolean"&&n.items===!1)return!1;if(n.items&&typeof n.items=="object"&&!Array.isArray(n.items)){const o=Ae(n.items);for(let a=i.length;a<s.length;a++)if(!cr(o,s[a]))return!1}}return!0},{message:"Array does not match prefixItems schema"})}return e}},Vc=class{apply(e,t){const n=t;if(!n.properties&&!n.required&&n.additionalProperties!==!1)return e;if(e instanceof nc||e instanceof rc){const r={};if(n.properties)for(const[i,s]of Object.entries(n.properties))s!==void 0&&(r[i]=Ae(s));if(n.required&&Array.isArray(n.required)){const i=new Set(n.required);for(const s of Object.keys(r))i.has(s)||(r[s]=r[s].optional())}else for(const i of Object.keys(r))r[i]=r[i].optional();return n.additionalProperties===!1?_e(r):_e(r).passthrough()}return e.refine(r=>{if(typeof r!="object"||r===null||Array.isArray(r))return!0;if(n.properties){for(const[i,s]of Object.entries(n.properties))if(s!==void 0&&Object.getOwnPropertyDescriptor(r,i)!==void 0&&!Ae(s).safeParse(r[i]).success)return!1}if(n.required&&Array.isArray(n.required)){for(const i of n.required)if(!(Object.getOwnPropertyDescriptor(r,i)!==void 0))return!1}if(n.additionalProperties===!1&&n.properties){const i=new Set(Object.keys(n.properties));for(const s in r)if(!i.has(s))return!1}return!0},{message:"Object constraints validation failed"})}},Hc=class{apply(e,t){if(!t.enum||t.enum.length===0)return e;const n=t.enum.filter(r=>Array.isArray(r)||typeof r=="object"&&r!==null);return n.length===0?e:e.refine(r=>typeof r!="object"||r===null?!0:n.some(i=>Tn(r,i)),{message:"Value must match one of the enum values"})}},Kc=class{apply(e,t){if(t.const===void 0)return e;const n=t.const;return typeof n!="object"||n===null?e:e.refine(r=>Tn(r,n),{message:"Value must equal the const value"})}},Gc=class{apply(e,t){return t.description&&(e=e.describe(t.description)),e}},zc=class{apply(e,t){var n;const r=t;return!((n=r.required)!=null&&n.includes("__proto__"))||t.type!==void 0?e:Fe().refine(i=>this.validateRequired(i,r.required),{message:"Missing required properties"})}validateRequired(e,t){return typeof e!="object"||e===null||Array.isArray(e)?!0:t.every(n=>Object.prototype.hasOwnProperty.call(e,n))}},Yc=class{apply(e,t){var n;const r=t;if(r.contains===void 0)return e;const i=Ae(r.contains),s=(n=r.minContains)!=null?n:1,o=r.maxContains;return e.refine(a=>{if(!Array.isArray(a))return!0;let l=0;for(const c of a)cr(i,c)&&l++;return!(l<s||o!==void 0&&l>o)},{message:"Array must contain required items matching the schema"})}},Jc=class{apply(e,t){const{default:n}=t;return n===void 0||!e.safeParse(n).success?e:e.default(n)}},Zc=[new yc,new gc,new mc,new bc,new Sc,new Cc,new Dc,new vc,new Oc,new wc,new xc,new Ec,new Ac,new _c,new Ic,new jc,new Tc,new Pc,new Fc,new Nc,new Rc,new $c],Xc=[new zc,new Hc,new Kc,new Lc,new Bc,new Wc,new qc,new Vc,new Yc,new Uc,new kc,new Jc,new Gc];function Ae(e){if(typeof e=="boolean")return e?Fe():Os();const t={};for(const i of Zc)i.apply(t,e);const n=[];if(t.string!==!1&&n.push(t.string||oe()),t.number!==!1&&n.push(t.number||ge()),t.boolean!==!1&&n.push(t.boolean||ti()),t.null!==!1&&n.push(t.null||_i()),t.array!==!1&&n.push(t.array||Ie(Fe())),t.tuple!==!1&&t.tuple!==void 0&&n.push(t.tuple),t.object!==!1)if(t.object)n.push(t.object);else{const i=tc(s=>typeof s=="object"&&s!==null&&!Array.isArray(s),"Must be an object, not an array");n.push(i)}t.file!==!1&&t.file!==void 0&&n.push(t.file);let r;n.length===0?r=Os():n.length===1?r=n[0]:Object.keys(e).some(s=>s!=="$schema"&&s!=="title"&&s!=="description")?r=mt(n):r=Fe();for(const i of Xc)r=i.apply(r,e);return r}class As extends Event{constructor(t,n){var r,i;super(t),this.code=(r=n?.code)!=null?r:void 0,this.message=(i=n?.message)!=null?i:void 0}[Symbol.for("nodejs.util.inspect.custom")](t,n,r){return r(_s(this),n)}[Symbol.for("Deno.customInspect")](t,n){return t(_s(this),n)}}function Qc(e){const t=globalThis.DOMException;return typeof t=="function"?new t(e,"SyntaxError"):new SyntaxError(e)}function ni(e){return e instanceof Error?"errors"in e&&Array.isArray(e.errors)?e.errors.map(ni).join(", "):"cause"in e&&e.cause instanceof Error?`${e}: ${ni(e.cause)}`:e.message:`${e}`}function _s(e){return{type:e.type,message:e.message,code:e.code,defaultPrevented:e.defaultPrevented,cancelable:e.cancelable,timeStamp:e.timeStamp}}var aa=e=>{throw TypeError(e)},Fi=(e,t,n)=>t.has(e)||aa("Cannot "+n),G=(e,t,n)=>(Fi(e,t,"read from private field"),n?n.call(e):t.get(e)),Se=(e,t,n)=>t.has(e)?aa("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),he=(e,t,n,r)=>(Fi(e,t,"write to private field"),t.set(e,n),n),Qe=(e,t,n)=>(Fi(e,t,"access private method"),n),Ce,Et,kt,Qn,ur,wn,qt,xn,ct,Lt,Gt,Bt,mn,Re,ri,ii,si,Is,oi,ai,yn,li,ci;class er extends EventTarget{constructor(t,n){var r,i;super(),Se(this,Re),this.CONNECTING=0,this.OPEN=1,this.CLOSED=2,Se(this,Ce),Se(this,Et),Se(this,kt),Se(this,Qn),Se(this,ur),Se(this,wn),Se(this,qt),Se(this,xn,null),Se(this,ct),Se(this,Lt),Se(this,Gt,null),Se(this,Bt,null),Se(this,mn,null),Se(this,ii,async s=>{var o;G(this,Lt).reset();const{body:a,redirected:l,status:c,headers:u}=s;if(c===204){Qe(this,Re,yn).call(this,"Server sent HTTP 204, not reconnecting",204),this.close();return}if(l?he(this,kt,new URL(s.url)):he(this,kt,void 0),c!==200){Qe(this,Re,yn).call(this,`Non-200 status code (${c})`,c);return}if(!(u.get("content-type")||"").startsWith("text/event-stream")){Qe(this,Re,yn).call(this,'Invalid content type, expected "text/event-stream"',c);return}if(G(this,Ce)===this.CLOSED)return;he(this,Ce,this.OPEN);const f=new Event("open");if((o=G(this,mn))==null||o.call(this,f),this.dispatchEvent(f),typeof a!="object"||!a||!("getReader"in a)){Qe(this,Re,yn).call(this,"Invalid response body, expected a web ReadableStream",c),this.close();return}const h=new TextDecoder,m=a.getReader();let d=!0;do{const{done:p,value:y}=await m.read();y&&G(this,Lt).feed(h.decode(y,{stream:!p})),p&&(d=!1,G(this,Lt).reset(),Qe(this,Re,li).call(this))}while(d)}),Se(this,si,s=>{he(this,ct,void 0),!(s.name==="AbortError"||s.type==="aborted")&&Qe(this,Re,li).call(this,ni(s))}),Se(this,oi,s=>{typeof s.id=="string"&&he(this,xn,s.id);const o=new MessageEvent(s.event||"message",{data:s.data,origin:G(this,kt)?G(this,kt).origin:G(this,Et).origin,lastEventId:s.id||""});G(this,Bt)&&(!s.event||s.event==="message")&&G(this,Bt).call(this,o),this.dispatchEvent(o)}),Se(this,ai,s=>{he(this,wn,s)}),Se(this,ci,()=>{he(this,qt,void 0),G(this,Ce)===this.CONNECTING&&Qe(this,Re,ri).call(this)});try{if(t instanceof URL)he(this,Et,t);else if(typeof t=="string")he(this,Et,new URL(t,eu()));else throw new Error("Invalid URL")}catch{throw Qc("An invalid or illegal string was specified")}he(this,Lt,cc({onEvent:G(this,oi),onRetry:G(this,ai)})),he(this,Ce,this.CONNECTING),he(this,wn,3e3),he(this,ur,(r=n?.fetch)!=null?r:globalThis.fetch),he(this,Qn,(i=n?.withCredentials)!=null?i:!1),Qe(this,Re,ri).call(this)}get readyState(){return G(this,Ce)}get url(){return G(this,Et).href}get withCredentials(){return G(this,Qn)}get onerror(){return G(this,Gt)}set onerror(t){he(this,Gt,t)}get onmessage(){return G(this,Bt)}set onmessage(t){he(this,Bt,t)}get onopen(){return G(this,mn)}set onopen(t){he(this,mn,t)}addEventListener(t,n,r){const i=n;super.addEventListener(t,i,r)}removeEventListener(t,n,r){const i=n;super.removeEventListener(t,i,r)}close(){G(this,qt)&&clearTimeout(G(this,qt)),G(this,Ce)!==this.CLOSED&&(G(this,ct)&&G(this,ct).abort(),he(this,Ce,this.CLOSED),he(this,ct,void 0))}}Ce=new WeakMap,Et=new WeakMap,kt=new WeakMap,Qn=new WeakMap,ur=new WeakMap,wn=new WeakMap,qt=new WeakMap,xn=new WeakMap,ct=new WeakMap,Lt=new WeakMap,Gt=new WeakMap,Bt=new WeakMap,mn=new WeakMap,Re=new WeakSet,ri=function(){he(this,Ce,this.CONNECTING),he(this,ct,new AbortController),G(this,ur)(G(this,Et),Qe(this,Re,Is).call(this)).then(G(this,ii)).catch(G(this,si))},ii=new WeakMap,si=new WeakMap,Is=function(){var e;const t={mode:"cors",redirect:"follow",headers:{Accept:"text/event-stream",...G(this,xn)?{"Last-Event-ID":G(this,xn)}:void 0},cache:"no-store",signal:(e=G(this,ct))==null?void 0:e.signal};return"window"in globalThis&&(t.credentials=this.withCredentials?"include":"same-origin"),t},oi=new WeakMap,ai=new WeakMap,yn=function(e,t){var n;G(this,Ce)!==this.CLOSED&&he(this,Ce,this.CLOSED);const r=new As("error",{code:t,message:e});(n=G(this,Gt))==null||n.call(this,r),this.dispatchEvent(r)},li=function(e,t){var n;if(G(this,Ce)===this.CLOSED)return;he(this,Ce,this.CONNECTING);const r=new As("error",{code:t,message:e});(n=G(this,Gt))==null||n.call(this,r),this.dispatchEvent(r),he(this,qt,setTimeout(G(this,ci),G(this,wn)))},ci=new WeakMap,er.CONNECTING=0,er.OPEN=1,er.CLOSED=2;function eu(){const e="document"in globalThis?globalThis.document:void 0;return e&&typeof e=="object"&&"baseURI"in e&&typeof e.baseURI=="string"?e.baseURI:void 0}class tu extends Error{constructor(t,n,r){super(`SSE error: ${n}`),this.code=t,this.event=r}}class nu{constructor(t,n){this._url=t,this._resourceMetadataUrl=void 0,this._scope=void 0,this._eventSourceInit=n?.eventSourceInit,this._requestInit=n?.requestInit,this._authProvider=n?.authProvider,this._fetch=n?.fetch,this._fetchWithInit=uc(n?.fetch,n?.requestInit)}async _authThenStart(){if(!this._authProvider)throw new fn("No auth provider");let t;try{t=await Tr(this._authProvider,{serverUrl:this._url,resourceMetadataUrl:this._resourceMetadataUrl,scope:this._scope,fetchFn:this._fetchWithInit})}catch(n){throw this.onerror?.(n),n}if(t!=="AUTHORIZED")throw new fn;return await this._startOrAuth()}async _commonHeaders(){const t={};if(this._authProvider){const r=await this._authProvider.tokens();r&&(t.Authorization=`Bearer ${r.access_token}`)}this._protocolVersion&&(t["mcp-protocol-version"]=this._protocolVersion);const n=fc(this._requestInit?.headers);return new Headers({...t,...n})}_startOrAuth(){const t=this?._eventSourceInit?.fetch??this._fetch??fetch;return new Promise((n,r)=>{this._eventSource=new er(this._url.href,{...this._eventSourceInit,fetch:async(i,s)=>{const o=await this._commonHeaders();o.set("Accept","text/event-stream");const a=await t(i,{...s,headers:o});if(a.status===401&&a.headers.has("www-authenticate")){const{resourceMetadataUrl:l,scope:c}=xs(a);this._resourceMetadataUrl=l,this._scope=c}return a}}),this._abortController=new AbortController,this._eventSource.onerror=i=>{if(i.code===401&&this._authProvider){this._authThenStart().then(n,r);return}const s=new tu(i.code,i.message,i);r(s),this.onerror?.(s)},this._eventSource.onopen=()=>{},this._eventSource.addEventListener("endpoint",i=>{const s=i;try{if(this._endpoint=new URL(s.data,this._url),this._endpoint.origin!==this._url.origin)throw new Error(`Endpoint origin does not match connection origin: ${this._endpoint.origin}`)}catch(o){r(o),this.onerror?.(o),this.close();return}n()}),this._eventSource.onmessage=i=>{const s=i;let o;try{o=sa.parse(JSON.parse(s.data))}catch(a){this.onerror?.(a);return}this.onmessage?.(o)}})}async start(){if(this._eventSource)throw new Error("SSEClientTransport already started! If using Client class, note that connect() calls start() automatically.");return await this._startOrAuth()}async finishAuth(t){if(!this._authProvider)throw new fn("No auth provider");if(await Tr(this._authProvider,{serverUrl:this._url,authorizationCode:t,resourceMetadataUrl:this._resourceMetadataUrl,scope:this._scope,fetchFn:this._fetchWithInit})!=="AUTHORIZED")throw new fn("Failed to authorize")}async close(){this._abortController?.abort(),this._eventSource?.close(),this.onclose?.()}async send(t){if(!this._endpoint)throw new Error("Not connected");try{const n=await this._commonHeaders();n.set("content-type","application/json");const r={...this._requestInit,method:"POST",headers:n,body:JSON.stringify(t),signal:this._abortController?.signal},i=await(this._fetch??fetch)(this._endpoint,r);if(!i.ok){const s=await i.text().catch(()=>null);if(i.status===401&&this._authProvider){const{resourceMetadataUrl:o,scope:a}=xs(i);if(this._resourceMetadataUrl=o,this._scope=a,await Tr(this._authProvider,{serverUrl:this._url,resourceMetadataUrl:this._resourceMetadataUrl,scope:this._scope,fetchFn:this._fetchWithInit})!=="AUTHORIZED")throw new fn;return this.send(t)}throw new Error(`Error POSTing to endpoint (HTTP ${i.status}): ${s}`)}await i.body?.cancel()}catch(n){throw this.onerror?.(n),n}}setProtocolVersion(t){this._protocolVersion=t}}const ru="mcp";class iu{constructor(t){this._url=t}start(){if(this._socket)throw new Error("WebSocketClientTransport already started! If using Client class, note that connect() calls start() automatically.");return new Promise((t,n)=>{this._socket=new WebSocket(this._url,ru),this._socket.onerror=r=>{const i="error"in r?r.error:new Error(`WebSocket error: ${JSON.stringify(r)}`);n(i),this.onerror?.(i)},this._socket.onopen=()=>{t()},this._socket.onclose=()=>{this.onclose?.()},this._socket.onmessage=r=>{let i;try{i=sa.parse(JSON.parse(r.data))}catch(s){this.onerror?.(s);return}this.onmessage?.(i)}})}async close(){this._socket?.close()}send(t){return new Promise((n,r)=>{if(!this._socket){r(new Error("Not connected"));return}this._socket?.send(JSON.stringify(t)),n()})}}class su extends dc{constructor(t,n){super(t,n)}send(t,n){const r=ou(t);return r?.type==="emit"?(this.onmessage?.(r.message),Promise.resolve()):r?.type==="suppress"?Promise.resolve():super.send(t,n)}}function ou(e){const t=e;if(!t||typeof t!="object"||!("method"in t))return null;switch(t.method){case"initialize":{const n=t?.params?.protocolVersion;return n?{type:"emit",message:{result:{protocolVersion:n,capabilities:{tools:{}},serverInfo:{name:"deco-chat-server",version:"1.0.0"}},jsonrpc:t.jsonrpc??"2.0",id:t.id}}:null}case"notifications/roots/list_changed":case"notifications/initialized":case"notifications/cancelled":case"notifications/progress":return{type:"suppress"};default:return null}}class au extends hc{constructor(t,n){super(t,n)}async listTools(t,n){return await this.request({method:"tools/list",params:t},sc,n)}}const lu=async(e,t,n)=>{const r=cu(e.connection,t,n);if(!r)throw new Error("Unknown MCP connection type");const i=new au({name:e?.name??"MCP Client",version:"1.0.0"});return await i.connect(r),{client:i}},cu=(e,t,n)=>{if(e.type==="Websocket")return new iu(new URL(e.url));if(e.type!=="SSE"&&e.type!=="HTTP")return null;const i={...e.token?{authorization:`Bearer ${e.token}`}:{},...n??{},..."headers"in e?e.headers||{}:{}};if(e.type==="SSE"){const s={requestInit:{headers:i,signal:t}};return e.token&&(s.eventSourceInit={fetch:(o,a)=>fetch(o,{...a,headers:{...i,Accept:"text/event-stream"},signal:t})}),new nu(new URL(e.url),s)}return new su(new URL(e.url),{requestInit:{headers:i,signal:t,credentials:"include"}})},Cs=e=>{try{return JSON.parse(e)}catch{return e}},zn=new Map,Ts=(e,t)=>({...e,id:e.name,inputSchema:e.inputSchema?Ae(e.inputSchema):void 0,outputSchema:e.outputSchema?Ae(e.outputSchema):void 0,execute:n=>t(n.context,e.name)});function uu(e){const t=n=>"connection"in e?lu({connection:e.connection},void 0,n):e.client;return new Proxy({},{get(n,r){if(r==="toJSON")return null;if(typeof r!="string")throw new Error("Name must be a string");if(r==="listTools")return a;async function i(l,c=r){const u=e?.debugId?.(),f=u?{"x-trace-debug-id":u}:void 0,{client:h}=await t(f),{structuredContent:m,isError:d,content:p}=await h.callTool({name:String(c),arguments:l});if(d){const S=p?.[0]?.text,O=typeof S=="string"?Cs(S):null,E=O?.code&&typeof e?.getErrorByStatusCode=="function"?e.getErrorByStatusCode(O.code,O.message,O.traceId):null;throw E||new Error(`Tool ${String(c)} returned an error: ${JSON.stringify(m??p)}`)}if(m!==void 0)return m;const y=p?.[0]?.text;return typeof y=="string"?Cs(y):void 0}async function s(){const{client:l}=await t(),{tools:c}=await l.listTools();return c}async function o(){if(!("connection"in e))return s();const l=e.connection,c=JSON.stringify(l);try{return zn.has(c)||zn.set(c,s()),await zn.get(c)}catch(u){console.error("Failed to list tools",u),zn.delete(c);return}}async function a(){return(await o()??[]).map(c=>Ts(c,i))}return i.asTool=async()=>{const c=(await o()??[]).find(u=>u.name===r);if(!c)throw new Error(`Tool ${r} not found`);return Ts(c,i)},i}})}new Proxy({},{get(e,t){return t==="toJSON"?null:t==="forConnection"?n=>fu({connection:n}):global[t]}});function fu(e){return uu(e)}const du=_e({toolName:oe().describe("Name of the tool to invoke on that connection"),transformCode:oe().optional().describe("Pure TypeScript function for data transformation of the tool call result. Must be a TypeScript file that declares the Output interface and exports a default function: `interface Output { ... } export default async function(stepInput): Output { ... }`\n The stepInput will match with the tool call outputSchema. If transformCode is not provided, the tool call result will be used as the step output.\n Providing an transformCode is recommended because it both allows you to transform the data and validate it against a JSON Schema - tools are ephemeral and may return unexpected data.")}),hu=_e({code:oe().describe(`Pure TypeScript function for data transformation. Useful to merge data from multiple steps and transform it. Must be a TypeScript file that declares the Output interface and exports a default function: \`interface Output { ... } export default async function(stepInput): Output { ... }\`
1
+ import{cp as Fe,bn as Os,J as oe,I as ge,a_ as ti,bS as _i,aK as Ie,bl as mt,a$ as qe,ap as mr,cq as rn,H as _e,cr as Ii,cs as ws,ct as ec,bQ as tc,cu as ia,cv as nc,cw as rc,cx as ic,cy as fn,cz as Tr,cA as xs,bL as sa,bD as sc,aJ as ze,bR as oc,aI as On,bb as Ci,cB as ac,r as N,j as w,cC as oa,cD as lc}from"./index-0dtUnOR1.js";import{f as cc,h as uc,n as fc,j as dc,C as hc,A as pc}from"./constants-CMPjFkrZ.js";import{B as Ti,c as Pi}from"./collections-B60eBxX4.js";import{R as Es}from"./index-BG0omYxu.js";var mc=class{apply(e,t){if(!t.type)return;const n=Array.isArray(t.type)?t.type:[t.type],r=new Set(n);if(r.has("string")||(e.string=!1),!r.has("number")&&!r.has("integer")&&(e.number=!1),r.has("boolean")||(e.boolean=!1),r.has("null")||(e.null=!1),r.has("array")||(e.array=!1),r.has("object")||(e.object=!1),r.has("integer")&&e.number!==!1){const i=e.number||ge();i instanceof rn&&(e.number=i.int())}}},yc=class{apply(e,t){if(t.const===void 0)return;const n=t.const;e.string=!1,e.number=!1,e.boolean=!1,e.null=!1,e.array=!1,e.object=!1,typeof n=="string"?e.string=qe(n):typeof n=="number"?e.number=qe(n):typeof n=="boolean"?e.boolean=qe(n):n===null?e.null=_i():Array.isArray(n)?e.array=void 0:typeof n=="object"&&(e.object=void 0)}},gc=class{apply(e,t){if(!t.enum)return;if(t.enum.length===0){t.type||(e.string=!1,e.number=!1,e.boolean=!1,e.null=!1,e.array=!1,e.object=!1);return}const n={string:t.enum.filter(r=>typeof r=="string"),number:t.enum.filter(r=>typeof r=="number"),boolean:t.enum.filter(r=>typeof r=="boolean"),null:t.enum.filter(r=>r===null),array:t.enum.filter(r=>Array.isArray(r)),object:t.enum.filter(r=>typeof r=="object"&&r!==null&&!Array.isArray(r))};e.string=this.createTypeSchema(n.string,"string"),e.number=this.createTypeSchema(n.number,"number"),e.boolean=this.createTypeSchema(n.boolean,"boolean"),e.null=n.null.length>0?_i():!1,e.array=n.array.length>0?void 0:!1,e.object=n.object.length>0?void 0:!1}createTypeSchema(e,t){if(e.length===0)return!1;if(e.length===1)return qe(e[0]);if(t==="string")return mr(e);if(t==="number"){const[n,r,...i]=e;return mt([qe(n),qe(r),...i.map(s=>qe(s))])}return t==="boolean"?mt([qe(!0),qe(!1)]):!1}},bc=class{apply(e,t){const n=t;if(n.type==="string"&&n.format==="binary"&&n.contentEncoding==="binary"){let r=ic();n.minLength!==void 0&&(r=r.min(n.minLength)),n.maxLength!==void 0&&(r=r.max(n.maxLength)),n.contentMediaType!==void 0&&(r=r.mime(n.contentMediaType)),e.file=r,e.string=!1}}},Sc=class{apply(e,t){const n=t;t.type===void 0&&(n.minLength!==void 0||n.maxLength!==void 0||n.pattern!==void 0)&&e.string===void 0&&(e.string=oe())}},vc=class{apply(e,t){const n=t;if(n.minLength!==void 0&&e.string!==!1){const r=e.string||oe();r instanceof Ii&&(e.string=r.refine(i=>Array.from(i).length>=n.minLength,{message:`String must be at least ${n.minLength} characters long`}))}}},Oc=class{apply(e,t){const n=t;if(n.maxLength!==void 0&&e.string!==!1){const r=e.string||oe();r instanceof Ii&&(e.string=r.refine(i=>Array.from(i).length<=n.maxLength,{message:`String must be at most ${n.maxLength} characters long`}))}}},wc=class{apply(e,t){const n=t;if(n.pattern&&e.string!==!1){const r=e.string||oe();if(r instanceof Ii){const i=new RegExp(n.pattern);e.string=r.regex(i)}}}},xc=class{apply(e,t){const n=t;if(n.minimum!==void 0&&e.number!==!1){const r=e.number||ge();r instanceof rn&&(e.number=r.min(n.minimum))}}},Ec=class{apply(e,t){const n=t;if(n.maximum!==void 0&&e.number!==!1){const r=e.number||ge();r instanceof rn&&(e.number=r.max(n.maximum))}}},Ac=class{apply(e,t){const n=t;if(n.exclusiveMinimum!==void 0&&e.number!==!1){const r=e.number||ge();r instanceof rn&&(typeof n.exclusiveMinimum=="number"?e.number=r.gt(n.exclusiveMinimum):e.number=!1)}}},_c=class{apply(e,t){const n=t;if(n.exclusiveMaximum!==void 0&&e.number!==!1){const r=e.number||ge();r instanceof rn&&(typeof n.exclusiveMaximum=="number"?e.number=r.lt(n.exclusiveMaximum):e.number=!1)}}},Ic=class{apply(e,t){const n=t;if(n.multipleOf!==void 0&&e.number!==!1){const r=e.number||ge();r instanceof rn&&(e.number=r.refine(i=>{if(n.multipleOf===0)return!1;const s=i/n.multipleOf,o=Math.round(s),a=Math.min(Math.abs(i)*Number.EPSILON*10,Math.abs(n.multipleOf)*Number.EPSILON*10);return Math.abs(s-o)<=a/Math.abs(n.multipleOf)},{message:`Must be a multiple of ${n.multipleOf}`}))}}},Cc=class{apply(e,t){const n=t;t.type===void 0&&(n.minItems!==void 0||n.maxItems!==void 0||n.items!==void 0||n.prefixItems!==void 0)&&e.array===void 0&&(e.array=Ie(Fe()))}},Tc=class{apply(e,t){const n=t;n.minItems!==void 0&&e.array!==!1&&(e.array=(e.array||Ie(Fe())).min(n.minItems))}},Pc=class{apply(e,t){const n=t;n.maxItems!==void 0&&e.array!==!1&&(e.array=(e.array||Ie(Fe())).max(n.maxItems))}},Fc=class{apply(e,t){const n=t;if(e.array!==!1)if(Array.isArray(n.items))e.array=e.array||Ie(Fe());else if(n.items&&typeof n.items!="boolean"&&!n.prefixItems){const r=Ae(n.items);let i=Ie(r);if(e.array&&e.array instanceof ec){const s=e.array._def;s.checks&&s.checks.forEach(o=>{if(o._zod&&o._zod.def){const a=o._zod.def;a.check==="min_length"&&a.minimum!==void 0?i=i.min(a.minimum):a.check==="max_length"&&a.maximum!==void 0&&(i=i.max(a.maximum))}})}e.array=i}else typeof n.items=="boolean"&&n.items===!1?n.prefixItems?e.array=e.array||Ie(Fe()):e.array=Ie(Fe()).max(0):typeof n.items=="boolean"&&n.items===!0?e.array=e.array||Ie(Fe()):n.prefixItems&&(e.array=e.array||Ie(Fe()))}},jc=class{apply(e,t){if(t.type!=="array")return;const n=t;if(!Array.isArray(n.items)||e.array===!1)return;const r=n.items.map(s=>Ae(s));let i;r.length===0?i=ws([]):i=ws(r),n.minItems!==void 0&&n.minItems>r.length&&(i=!1),n.maxItems!==void 0&&n.maxItems<r.length&&(i=!1),e.tuple=i,e.array=!1}},$c=class{apply(e,t){const n=t;e.object!==!1&&(n.properties||n.required||n.additionalProperties!==void 0)&&(e.object=e.object||_e({}).passthrough())}},Dc=class{apply(e,t){const n=t;t.type===void 0&&(n.maxProperties!==void 0||n.minProperties!==void 0)&&e.object===void 0&&(e.object=_e({}).passthrough())}},Nc=class{apply(e,t){const n=t;if(n.maxProperties!==void 0&&e.object!==!1){const r=e.object||_e({}).passthrough();e.object=r.refine(i=>Object.keys(i).length<=n.maxProperties,{message:`Object must have at most ${n.maxProperties} properties`})}}},Rc=class{apply(e,t){const n=t;if(n.minProperties!==void 0&&e.object!==!1){const r=e.object||_e({}).passthrough();e.object=r.refine(i=>Object.keys(i).length>=n.minProperties,{message:`Object must have at least ${n.minProperties} properties`})}}};function Tn(e,t){if(e===t)return!0;if(e==null||t==null)return e===t;if(typeof e!=typeof t)return!1;if(Array.isArray(e)&&Array.isArray(t))return e.length!==t.length?!1:e.every((n,r)=>Tn(n,t[r]));if(typeof e=="object"&&typeof t=="object"){const n=Object.keys(e),r=Object.keys(t);return n.length!==r.length?!1:n.every(i=>r.includes(i)&&Tn(e[i],t[i]))}return!1}function Mc(){return e=>{if(!Array.isArray(e))return!0;const t=[];return e.every(n=>t.some(i=>Tn(n,i))?!1:(t.push(n),!0))}}function cr(e,t){return e.safeParse(t).success}var Uc=class{apply(e,t){if(!t.not)return e;const n=Ae(t.not);return e.refine(r=>!cr(n,r),{message:"Value must not match the 'not' schema"})}},kc=class{apply(e,t){return t.uniqueItems!==!0?e:e.refine(Mc(),{message:"Array items must be unique"})}},Lc=class{apply(e,t){return!t.allOf||t.allOf.length===0?e:t.allOf.map(r=>Ae(r)).reduce((r,i)=>ia(r,i),e)}},Bc=class{apply(e,t){if(!t.anyOf||t.anyOf.length===0)return e;const n=t.anyOf.length===1?Ae(t.anyOf[0]):mt([Ae(t.anyOf[0]),Ae(t.anyOf[1]),...t.anyOf.slice(2).map(r=>Ae(r))]);return ia(e,n)}},Wc=class{apply(e,t){if(!t.oneOf||t.oneOf.length===0)return e;const n=t.oneOf.map(r=>Ae(r));return e.refine(r=>{let i=0;for(const s of n)if(s.safeParse(r).success&&(i++,i>1))return!1;return i===1},{message:"Value must match exactly one of the oneOf schemas"})}},qc=class{apply(e,t){const n=t;if(n.prefixItems&&Array.isArray(n.prefixItems)){const i=n.prefixItems.map(s=>Ae(s));return e.refine(s=>{if(!Array.isArray(s))return!0;for(let o=0;o<Math.min(s.length,i.length);o++)if(!cr(i[o],s[o]))return!1;if(s.length>i.length){if(typeof n.items=="boolean"&&n.items===!1)return!1;if(n.items&&typeof n.items=="object"&&!Array.isArray(n.items)){const o=Ae(n.items);for(let a=i.length;a<s.length;a++)if(!cr(o,s[a]))return!1}}return!0},{message:"Array does not match prefixItems schema"})}return e}},Vc=class{apply(e,t){const n=t;if(!n.properties&&!n.required&&n.additionalProperties!==!1)return e;if(e instanceof nc||e instanceof rc){const r={};if(n.properties)for(const[i,s]of Object.entries(n.properties))s!==void 0&&(r[i]=Ae(s));if(n.required&&Array.isArray(n.required)){const i=new Set(n.required);for(const s of Object.keys(r))i.has(s)||(r[s]=r[s].optional())}else for(const i of Object.keys(r))r[i]=r[i].optional();return n.additionalProperties===!1?_e(r):_e(r).passthrough()}return e.refine(r=>{if(typeof r!="object"||r===null||Array.isArray(r))return!0;if(n.properties){for(const[i,s]of Object.entries(n.properties))if(s!==void 0&&Object.getOwnPropertyDescriptor(r,i)!==void 0&&!Ae(s).safeParse(r[i]).success)return!1}if(n.required&&Array.isArray(n.required)){for(const i of n.required)if(!(Object.getOwnPropertyDescriptor(r,i)!==void 0))return!1}if(n.additionalProperties===!1&&n.properties){const i=new Set(Object.keys(n.properties));for(const s in r)if(!i.has(s))return!1}return!0},{message:"Object constraints validation failed"})}},Hc=class{apply(e,t){if(!t.enum||t.enum.length===0)return e;const n=t.enum.filter(r=>Array.isArray(r)||typeof r=="object"&&r!==null);return n.length===0?e:e.refine(r=>typeof r!="object"||r===null?!0:n.some(i=>Tn(r,i)),{message:"Value must match one of the enum values"})}},Kc=class{apply(e,t){if(t.const===void 0)return e;const n=t.const;return typeof n!="object"||n===null?e:e.refine(r=>Tn(r,n),{message:"Value must equal the const value"})}},Gc=class{apply(e,t){return t.description&&(e=e.describe(t.description)),e}},zc=class{apply(e,t){var n;const r=t;return!((n=r.required)!=null&&n.includes("__proto__"))||t.type!==void 0?e:Fe().refine(i=>this.validateRequired(i,r.required),{message:"Missing required properties"})}validateRequired(e,t){return typeof e!="object"||e===null||Array.isArray(e)?!0:t.every(n=>Object.prototype.hasOwnProperty.call(e,n))}},Yc=class{apply(e,t){var n;const r=t;if(r.contains===void 0)return e;const i=Ae(r.contains),s=(n=r.minContains)!=null?n:1,o=r.maxContains;return e.refine(a=>{if(!Array.isArray(a))return!0;let l=0;for(const c of a)cr(i,c)&&l++;return!(l<s||o!==void 0&&l>o)},{message:"Array must contain required items matching the schema"})}},Jc=class{apply(e,t){const{default:n}=t;return n===void 0||!e.safeParse(n).success?e:e.default(n)}},Zc=[new yc,new gc,new mc,new bc,new Sc,new Cc,new Dc,new vc,new Oc,new wc,new xc,new Ec,new Ac,new _c,new Ic,new jc,new Tc,new Pc,new Fc,new Nc,new Rc,new $c],Xc=[new zc,new Hc,new Kc,new Lc,new Bc,new Wc,new qc,new Vc,new Yc,new Uc,new kc,new Jc,new Gc];function Ae(e){if(typeof e=="boolean")return e?Fe():Os();const t={};for(const i of Zc)i.apply(t,e);const n=[];if(t.string!==!1&&n.push(t.string||oe()),t.number!==!1&&n.push(t.number||ge()),t.boolean!==!1&&n.push(t.boolean||ti()),t.null!==!1&&n.push(t.null||_i()),t.array!==!1&&n.push(t.array||Ie(Fe())),t.tuple!==!1&&t.tuple!==void 0&&n.push(t.tuple),t.object!==!1)if(t.object)n.push(t.object);else{const i=tc(s=>typeof s=="object"&&s!==null&&!Array.isArray(s),"Must be an object, not an array");n.push(i)}t.file!==!1&&t.file!==void 0&&n.push(t.file);let r;n.length===0?r=Os():n.length===1?r=n[0]:Object.keys(e).some(s=>s!=="$schema"&&s!=="title"&&s!=="description")?r=mt(n):r=Fe();for(const i of Xc)r=i.apply(r,e);return r}class As extends Event{constructor(t,n){var r,i;super(t),this.code=(r=n?.code)!=null?r:void 0,this.message=(i=n?.message)!=null?i:void 0}[Symbol.for("nodejs.util.inspect.custom")](t,n,r){return r(_s(this),n)}[Symbol.for("Deno.customInspect")](t,n){return t(_s(this),n)}}function Qc(e){const t=globalThis.DOMException;return typeof t=="function"?new t(e,"SyntaxError"):new SyntaxError(e)}function ni(e){return e instanceof Error?"errors"in e&&Array.isArray(e.errors)?e.errors.map(ni).join(", "):"cause"in e&&e.cause instanceof Error?`${e}: ${ni(e.cause)}`:e.message:`${e}`}function _s(e){return{type:e.type,message:e.message,code:e.code,defaultPrevented:e.defaultPrevented,cancelable:e.cancelable,timeStamp:e.timeStamp}}var aa=e=>{throw TypeError(e)},Fi=(e,t,n)=>t.has(e)||aa("Cannot "+n),G=(e,t,n)=>(Fi(e,t,"read from private field"),n?n.call(e):t.get(e)),Se=(e,t,n)=>t.has(e)?aa("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),he=(e,t,n,r)=>(Fi(e,t,"write to private field"),t.set(e,n),n),Qe=(e,t,n)=>(Fi(e,t,"access private method"),n),Ce,Et,kt,Qn,ur,wn,qt,xn,ct,Lt,Gt,Bt,mn,Re,ri,ii,si,Is,oi,ai,yn,li,ci;class er extends EventTarget{constructor(t,n){var r,i;super(),Se(this,Re),this.CONNECTING=0,this.OPEN=1,this.CLOSED=2,Se(this,Ce),Se(this,Et),Se(this,kt),Se(this,Qn),Se(this,ur),Se(this,wn),Se(this,qt),Se(this,xn,null),Se(this,ct),Se(this,Lt),Se(this,Gt,null),Se(this,Bt,null),Se(this,mn,null),Se(this,ii,async s=>{var o;G(this,Lt).reset();const{body:a,redirected:l,status:c,headers:u}=s;if(c===204){Qe(this,Re,yn).call(this,"Server sent HTTP 204, not reconnecting",204),this.close();return}if(l?he(this,kt,new URL(s.url)):he(this,kt,void 0),c!==200){Qe(this,Re,yn).call(this,`Non-200 status code (${c})`,c);return}if(!(u.get("content-type")||"").startsWith("text/event-stream")){Qe(this,Re,yn).call(this,'Invalid content type, expected "text/event-stream"',c);return}if(G(this,Ce)===this.CLOSED)return;he(this,Ce,this.OPEN);const f=new Event("open");if((o=G(this,mn))==null||o.call(this,f),this.dispatchEvent(f),typeof a!="object"||!a||!("getReader"in a)){Qe(this,Re,yn).call(this,"Invalid response body, expected a web ReadableStream",c),this.close();return}const h=new TextDecoder,m=a.getReader();let d=!0;do{const{done:p,value:y}=await m.read();y&&G(this,Lt).feed(h.decode(y,{stream:!p})),p&&(d=!1,G(this,Lt).reset(),Qe(this,Re,li).call(this))}while(d)}),Se(this,si,s=>{he(this,ct,void 0),!(s.name==="AbortError"||s.type==="aborted")&&Qe(this,Re,li).call(this,ni(s))}),Se(this,oi,s=>{typeof s.id=="string"&&he(this,xn,s.id);const o=new MessageEvent(s.event||"message",{data:s.data,origin:G(this,kt)?G(this,kt).origin:G(this,Et).origin,lastEventId:s.id||""});G(this,Bt)&&(!s.event||s.event==="message")&&G(this,Bt).call(this,o),this.dispatchEvent(o)}),Se(this,ai,s=>{he(this,wn,s)}),Se(this,ci,()=>{he(this,qt,void 0),G(this,Ce)===this.CONNECTING&&Qe(this,Re,ri).call(this)});try{if(t instanceof URL)he(this,Et,t);else if(typeof t=="string")he(this,Et,new URL(t,eu()));else throw new Error("Invalid URL")}catch{throw Qc("An invalid or illegal string was specified")}he(this,Lt,cc({onEvent:G(this,oi),onRetry:G(this,ai)})),he(this,Ce,this.CONNECTING),he(this,wn,3e3),he(this,ur,(r=n?.fetch)!=null?r:globalThis.fetch),he(this,Qn,(i=n?.withCredentials)!=null?i:!1),Qe(this,Re,ri).call(this)}get readyState(){return G(this,Ce)}get url(){return G(this,Et).href}get withCredentials(){return G(this,Qn)}get onerror(){return G(this,Gt)}set onerror(t){he(this,Gt,t)}get onmessage(){return G(this,Bt)}set onmessage(t){he(this,Bt,t)}get onopen(){return G(this,mn)}set onopen(t){he(this,mn,t)}addEventListener(t,n,r){const i=n;super.addEventListener(t,i,r)}removeEventListener(t,n,r){const i=n;super.removeEventListener(t,i,r)}close(){G(this,qt)&&clearTimeout(G(this,qt)),G(this,Ce)!==this.CLOSED&&(G(this,ct)&&G(this,ct).abort(),he(this,Ce,this.CLOSED),he(this,ct,void 0))}}Ce=new WeakMap,Et=new WeakMap,kt=new WeakMap,Qn=new WeakMap,ur=new WeakMap,wn=new WeakMap,qt=new WeakMap,xn=new WeakMap,ct=new WeakMap,Lt=new WeakMap,Gt=new WeakMap,Bt=new WeakMap,mn=new WeakMap,Re=new WeakSet,ri=function(){he(this,Ce,this.CONNECTING),he(this,ct,new AbortController),G(this,ur)(G(this,Et),Qe(this,Re,Is).call(this)).then(G(this,ii)).catch(G(this,si))},ii=new WeakMap,si=new WeakMap,Is=function(){var e;const t={mode:"cors",redirect:"follow",headers:{Accept:"text/event-stream",...G(this,xn)?{"Last-Event-ID":G(this,xn)}:void 0},cache:"no-store",signal:(e=G(this,ct))==null?void 0:e.signal};return"window"in globalThis&&(t.credentials=this.withCredentials?"include":"same-origin"),t},oi=new WeakMap,ai=new WeakMap,yn=function(e,t){var n;G(this,Ce)!==this.CLOSED&&he(this,Ce,this.CLOSED);const r=new As("error",{code:t,message:e});(n=G(this,Gt))==null||n.call(this,r),this.dispatchEvent(r)},li=function(e,t){var n;if(G(this,Ce)===this.CLOSED)return;he(this,Ce,this.CONNECTING);const r=new As("error",{code:t,message:e});(n=G(this,Gt))==null||n.call(this,r),this.dispatchEvent(r),he(this,qt,setTimeout(G(this,ci),G(this,wn)))},ci=new WeakMap,er.CONNECTING=0,er.OPEN=1,er.CLOSED=2;function eu(){const e="document"in globalThis?globalThis.document:void 0;return e&&typeof e=="object"&&"baseURI"in e&&typeof e.baseURI=="string"?e.baseURI:void 0}class tu extends Error{constructor(t,n,r){super(`SSE error: ${n}`),this.code=t,this.event=r}}class nu{constructor(t,n){this._url=t,this._resourceMetadataUrl=void 0,this._scope=void 0,this._eventSourceInit=n?.eventSourceInit,this._requestInit=n?.requestInit,this._authProvider=n?.authProvider,this._fetch=n?.fetch,this._fetchWithInit=uc(n?.fetch,n?.requestInit)}async _authThenStart(){if(!this._authProvider)throw new fn("No auth provider");let t;try{t=await Tr(this._authProvider,{serverUrl:this._url,resourceMetadataUrl:this._resourceMetadataUrl,scope:this._scope,fetchFn:this._fetchWithInit})}catch(n){throw this.onerror?.(n),n}if(t!=="AUTHORIZED")throw new fn;return await this._startOrAuth()}async _commonHeaders(){const t={};if(this._authProvider){const r=await this._authProvider.tokens();r&&(t.Authorization=`Bearer ${r.access_token}`)}this._protocolVersion&&(t["mcp-protocol-version"]=this._protocolVersion);const n=fc(this._requestInit?.headers);return new Headers({...t,...n})}_startOrAuth(){const t=this?._eventSourceInit?.fetch??this._fetch??fetch;return new Promise((n,r)=>{this._eventSource=new er(this._url.href,{...this._eventSourceInit,fetch:async(i,s)=>{const o=await this._commonHeaders();o.set("Accept","text/event-stream");const a=await t(i,{...s,headers:o});if(a.status===401&&a.headers.has("www-authenticate")){const{resourceMetadataUrl:l,scope:c}=xs(a);this._resourceMetadataUrl=l,this._scope=c}return a}}),this._abortController=new AbortController,this._eventSource.onerror=i=>{if(i.code===401&&this._authProvider){this._authThenStart().then(n,r);return}const s=new tu(i.code,i.message,i);r(s),this.onerror?.(s)},this._eventSource.onopen=()=>{},this._eventSource.addEventListener("endpoint",i=>{const s=i;try{if(this._endpoint=new URL(s.data,this._url),this._endpoint.origin!==this._url.origin)throw new Error(`Endpoint origin does not match connection origin: ${this._endpoint.origin}`)}catch(o){r(o),this.onerror?.(o),this.close();return}n()}),this._eventSource.onmessage=i=>{const s=i;let o;try{o=sa.parse(JSON.parse(s.data))}catch(a){this.onerror?.(a);return}this.onmessage?.(o)}})}async start(){if(this._eventSource)throw new Error("SSEClientTransport already started! If using Client class, note that connect() calls start() automatically.");return await this._startOrAuth()}async finishAuth(t){if(!this._authProvider)throw new fn("No auth provider");if(await Tr(this._authProvider,{serverUrl:this._url,authorizationCode:t,resourceMetadataUrl:this._resourceMetadataUrl,scope:this._scope,fetchFn:this._fetchWithInit})!=="AUTHORIZED")throw new fn("Failed to authorize")}async close(){this._abortController?.abort(),this._eventSource?.close(),this.onclose?.()}async send(t){if(!this._endpoint)throw new Error("Not connected");try{const n=await this._commonHeaders();n.set("content-type","application/json");const r={...this._requestInit,method:"POST",headers:n,body:JSON.stringify(t),signal:this._abortController?.signal},i=await(this._fetch??fetch)(this._endpoint,r);if(!i.ok){const s=await i.text().catch(()=>null);if(i.status===401&&this._authProvider){const{resourceMetadataUrl:o,scope:a}=xs(i);if(this._resourceMetadataUrl=o,this._scope=a,await Tr(this._authProvider,{serverUrl:this._url,resourceMetadataUrl:this._resourceMetadataUrl,scope:this._scope,fetchFn:this._fetchWithInit})!=="AUTHORIZED")throw new fn;return this.send(t)}throw new Error(`Error POSTing to endpoint (HTTP ${i.status}): ${s}`)}await i.body?.cancel()}catch(n){throw this.onerror?.(n),n}}setProtocolVersion(t){this._protocolVersion=t}}const ru="mcp";class iu{constructor(t){this._url=t}start(){if(this._socket)throw new Error("WebSocketClientTransport already started! If using Client class, note that connect() calls start() automatically.");return new Promise((t,n)=>{this._socket=new WebSocket(this._url,ru),this._socket.onerror=r=>{const i="error"in r?r.error:new Error(`WebSocket error: ${JSON.stringify(r)}`);n(i),this.onerror?.(i)},this._socket.onopen=()=>{t()},this._socket.onclose=()=>{this.onclose?.()},this._socket.onmessage=r=>{let i;try{i=sa.parse(JSON.parse(r.data))}catch(s){this.onerror?.(s);return}this.onmessage?.(i)}})}async close(){this._socket?.close()}send(t){return new Promise((n,r)=>{if(!this._socket){r(new Error("Not connected"));return}this._socket?.send(JSON.stringify(t)),n()})}}class su extends dc{constructor(t,n){super(t,n)}send(t,n){const r=ou(t);return r?.type==="emit"?(this.onmessage?.(r.message),Promise.resolve()):r?.type==="suppress"?Promise.resolve():super.send(t,n)}}function ou(e){const t=e;if(!t||typeof t!="object"||!("method"in t))return null;switch(t.method){case"initialize":{const n=t?.params?.protocolVersion;return n?{type:"emit",message:{result:{protocolVersion:n,capabilities:{tools:{}},serverInfo:{name:"deco-chat-server",version:"1.0.0"}},jsonrpc:t.jsonrpc??"2.0",id:t.id}}:null}case"notifications/roots/list_changed":case"notifications/initialized":case"notifications/cancelled":case"notifications/progress":return{type:"suppress"};default:return null}}class au extends hc{constructor(t,n){super(t,n)}async listTools(t,n){return await this.request({method:"tools/list",params:t},sc,n)}}const lu=async(e,t,n)=>{const r=cu(e.connection,t,n);if(!r)throw new Error("Unknown MCP connection type");const i=new au({name:e?.name??"MCP Client",version:"1.0.0"});return await i.connect(r),{client:i}},cu=(e,t,n)=>{if(e.type==="Websocket")return new iu(new URL(e.url));if(e.type!=="SSE"&&e.type!=="HTTP")return null;const i={...e.token?{authorization:`Bearer ${e.token}`}:{},...n??{},..."headers"in e?e.headers||{}:{}};if(e.type==="SSE"){const s={requestInit:{headers:i,signal:t}};return e.token&&(s.eventSourceInit={fetch:(o,a)=>fetch(o,{...a,headers:{...i,Accept:"text/event-stream"},signal:t})}),new nu(new URL(e.url),s)}return new su(new URL(e.url),{requestInit:{headers:i,signal:t,credentials:"include"}})},Cs=e=>{try{return JSON.parse(e)}catch{return e}},zn=new Map,Ts=(e,t)=>({...e,id:e.name,inputSchema:e.inputSchema?Ae(e.inputSchema):void 0,outputSchema:e.outputSchema?Ae(e.outputSchema):void 0,execute:n=>t(n.context,e.name)});function uu(e){const t=n=>"connection"in e?lu({connection:e.connection},void 0,n):e.client;return new Proxy({},{get(n,r){if(r==="toJSON")return null;if(typeof r!="string")throw new Error("Name must be a string");if(r==="listTools")return a;async function i(l,c=r){const u=e?.debugId?.(),f=u?{"x-trace-debug-id":u}:void 0,{client:h}=await t(f),{structuredContent:m,isError:d,content:p}=await h.callTool({name:String(c),arguments:l});if(d){const S=p?.[0]?.text,O=typeof S=="string"?Cs(S):null,E=O?.code&&typeof e?.getErrorByStatusCode=="function"?e.getErrorByStatusCode(O.code,O.message,O.traceId):null;throw E||new Error(`Tool ${String(c)} returned an error: ${JSON.stringify(m??p)}`)}if(m!==void 0)return m;const y=p?.[0]?.text;return typeof y=="string"?Cs(y):void 0}async function s(){const{client:l}=await t(),{tools:c}=await l.listTools();return c}async function o(){if(!("connection"in e))return s();const l=e.connection,c=JSON.stringify(l);try{return zn.has(c)||zn.set(c,s()),await zn.get(c)}catch(u){console.error("Failed to list tools",u),zn.delete(c);return}}async function a(){return(await o()??[]).map(c=>Ts(c,i))}return i.asTool=async()=>{const c=(await o()??[]).find(u=>u.name===r);if(!c)throw new Error(`Tool ${r} not found`);return Ts(c,i)},i}})}new Proxy({},{get(e,t){return t==="toJSON"?null:t==="forConnection"?n=>fu({connection:n}):global[t]}});function fu(e){return uu(e)}const du=_e({toolName:oe().describe("Name of the tool to invoke on that connection"),transformCode:oe().optional().describe("Pure TypeScript function for data transformation of the tool call result. Must be a TypeScript file that declares the Output interface and exports a default function: `interface Output { ... } export default async function(stepInput): Output { ... }`\n The stepInput will match with the tool call outputSchema. If transformCode is not provided, the tool call result will be used as the step output.\n Providing an transformCode is recommended because it both allows you to transform the data and validate it against a JSON Schema - tools are ephemeral and may return unexpected data.")}),hu=_e({code:oe().describe(`Pure TypeScript function for data transformation. Useful to merge data from multiple steps and transform it. Must be a TypeScript file that declares the Output interface and exports a default function: \`interface Output { ... } export default async function(stepInput): Output { ... }\`
2
2
  The stepInput is the resolved value of the references in the input field. Example:
3
3
  {
4
4
  "input": {
@@ -1 +1 @@
1
- import{bb as _}from"./index-BV4BlnS9.js";var b={exports:{}},r={};var $;function I(){if($)return r;$=1;var m=Symbol.for("react.element"),y=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),c=Symbol.for("react.provider"),f=Symbol.for("react.context"),x=Symbol.for("react.server_context"),u=Symbol.for("react.forward_ref"),i=Symbol.for("react.suspense"),l=Symbol.for("react.suspense_list"),a=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),R=Symbol.for("react.offscreen"),S;S=Symbol.for("react.module.reference");function t(e){if(typeof e=="object"&&e!==null){var d=e.$$typeof;switch(d){case m:switch(e=e.type,e){case o:case s:case n:case i:case l:return e;default:switch(e=e&&e.$$typeof,e){case x:case f:case u:case p:case a:case c:return e;default:return d}}case y:return d}}}return r.ContextConsumer=f,r.ContextProvider=c,r.Element=m,r.ForwardRef=u,r.Fragment=o,r.Lazy=p,r.Memo=a,r.Portal=y,r.Profiler=s,r.StrictMode=n,r.Suspense=i,r.SuspenseList=l,r.isAsyncMode=function(){return!1},r.isConcurrentMode=function(){return!1},r.isContextConsumer=function(e){return t(e)===f},r.isContextProvider=function(e){return t(e)===c},r.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===m},r.isForwardRef=function(e){return t(e)===u},r.isFragment=function(e){return t(e)===o},r.isLazy=function(e){return t(e)===p},r.isMemo=function(e){return t(e)===a},r.isPortal=function(e){return t(e)===y},r.isProfiler=function(e){return t(e)===s},r.isStrictMode=function(e){return t(e)===n},r.isSuspense=function(e){return t(e)===i},r.isSuspenseList=function(e){return t(e)===l},r.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===o||e===s||e===n||e===i||e===l||e===R||typeof e=="object"&&e!==null&&(e.$$typeof===p||e.$$typeof===a||e.$$typeof===c||e.$$typeof===f||e.$$typeof===u||e.$$typeof===S||e.getModuleId!==void 0)},r.typeOf=t,r}var v;function C(){return v||(v=1,b.exports=I()),b.exports}var g=C();const h=_(g);export{h as R,g as r};
1
+ import{bb as _}from"./index-0dtUnOR1.js";var b={exports:{}},r={};var $;function I(){if($)return r;$=1;var m=Symbol.for("react.element"),y=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),c=Symbol.for("react.provider"),f=Symbol.for("react.context"),x=Symbol.for("react.server_context"),u=Symbol.for("react.forward_ref"),i=Symbol.for("react.suspense"),l=Symbol.for("react.suspense_list"),a=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),R=Symbol.for("react.offscreen"),S;S=Symbol.for("react.module.reference");function t(e){if(typeof e=="object"&&e!==null){var d=e.$$typeof;switch(d){case m:switch(e=e.type,e){case o:case s:case n:case i:case l:return e;default:switch(e=e&&e.$$typeof,e){case x:case f:case u:case p:case a:case c:return e;default:return d}}case y:return d}}}return r.ContextConsumer=f,r.ContextProvider=c,r.Element=m,r.ForwardRef=u,r.Fragment=o,r.Lazy=p,r.Memo=a,r.Portal=y,r.Profiler=s,r.StrictMode=n,r.Suspense=i,r.SuspenseList=l,r.isAsyncMode=function(){return!1},r.isConcurrentMode=function(){return!1},r.isContextConsumer=function(e){return t(e)===f},r.isContextProvider=function(e){return t(e)===c},r.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===m},r.isForwardRef=function(e){return t(e)===u},r.isFragment=function(e){return t(e)===o},r.isLazy=function(e){return t(e)===p},r.isMemo=function(e){return t(e)===a},r.isPortal=function(e){return t(e)===y},r.isProfiler=function(e){return t(e)===s},r.isStrictMode=function(e){return t(e)===n},r.isSuspense=function(e){return t(e)===i},r.isSuspenseList=function(e){return t(e)===l},r.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===o||e===s||e===n||e===i||e===l||e===R||typeof e=="object"&&e!==null&&(e.$$typeof===p||e.$$typeof===a||e.$$typeof===c||e.$$typeof===f||e.$$typeof===u||e.$$typeof===S||e.getModuleId!==void 0)},r.typeOf=t,r}var v;function C(){return v||(v=1,b.exports=I()),b.exports}var g=C();const h=_(g);export{h as R,g as r};