decocms 4.13.0 → 4.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (221) hide show
  1. package/dist/client/assets/{AlertCircle-B9j2NALT.js → AlertCircle-aJ6yDWPp.js} +1 -1
  2. package/dist/client/assets/{ArrowUpRight-D2OUoipa.js → ArrowUpRight-D6sLwFH1.js} +1 -1
  3. package/dist/client/assets/{CheckCircle-vBH9TcCu.js → CheckCircle-DGsZQInM.js} +1 -1
  4. package/dist/client/assets/{ChevronDown-Dfa1LeSc.js → ChevronDown-8yONr3Hi.js} +1 -1
  5. package/dist/client/assets/{ChevronRight-BaENZPcV.js → ChevronRight-DB2h96_u.js} +1 -1
  6. package/dist/client/assets/{ChevronUp-DUUcpPbv.js → ChevronUp-D-_M8lF1.js} +1 -1
  7. package/dist/client/assets/{DotsVertical-Ccteydn1.js → DotsVertical-B31sNKwc.js} +1 -1
  8. package/dist/client/assets/{Eye-C-jpM5nK.js → Eye-CvlE6sU8.js} +1 -1
  9. package/dist/client/assets/{FilterLines-Bn-qPJAD.js → FilterLines-XsQ0uCbx.js} +1 -1
  10. package/dist/client/assets/{Globe01-DxDPO9eI.js → Globe01-Bf9vWtn7.js} +1 -1
  11. package/dist/client/assets/{Globe04-Bel5dpSv.js → Globe04-st0JXkop.js} +1 -1
  12. package/dist/client/assets/{HardDrive-BhQyUqC1.js → HardDrive-h2t2tKsS.js} +1 -1
  13. package/dist/client/assets/{Key01-DTb-8z2n.js → Key01-CxupAcD6.js} +1 -1
  14. package/dist/client/assets/{LayoutLeft-BEL6Qq7i.js → LayoutLeft-7DRX8N1I.js} +1 -1
  15. package/dist/client/assets/{LinkExternal01-DUbMRHAl.js → LinkExternal01-D7Dw4j5l.js} +1 -1
  16. package/dist/client/assets/{Monitor01-VxvNot22.js → Monitor01-xlbwnKUK.js} +1 -1
  17. package/dist/client/assets/{Palette-Q9O74bLu.js → Palette-BTrYbyGg.js} +1 -1
  18. package/dist/client/assets/{Play-BLfDQNw5.js → Play-B36jtJwt.js} +1 -1
  19. package/dist/client/assets/{Plus-CYYMn5Hd.js → Plus-Dzo88B__.js} +1 -1
  20. package/dist/client/assets/{SearchLg-DmLiQ0fi.js → SearchLg-BcKg1MJX.js} +1 -1
  21. package/dist/client/assets/{SearchMd-D6dyPzQF.js → SearchMd-BF0YJH92.js} +1 -1
  22. package/dist/client/assets/{Settings02-C2s7RYQy.js → Settings02-DH25zVKm.js} +1 -1
  23. package/dist/client/assets/{Shield01-DRgXRZgZ.js → Shield01-BRXCbQOp.js} +1 -1
  24. package/dist/client/assets/{Star01-1j1KAatA.js → Star01-c00O9d3i.js} +1 -1
  25. package/dist/client/assets/{Stars01-DSeLCepl.js → Stars01-BTfT8vOu.js} +1 -1
  26. package/dist/client/assets/{Stars02-BlDXKEXS.js → Stars02-DmKdcoHU.js} +1 -1
  27. package/dist/client/assets/{Sun-DcCtK_JQ.js → Sun-vZ_hqPJl.js} +1 -1
  28. package/dist/client/assets/{SwitchHorizontal01-BVs7ZyE_.js → SwitchHorizontal01-DoFP0ihb.js} +1 -1
  29. package/dist/client/assets/{Tool01-CZmFMeMt.js → Tool01-JLz5YELx.js} +1 -1
  30. package/dist/client/assets/{Trash01-CGa_hcb0.js → Trash01-DdVmIYmM.js} +1 -1
  31. package/dist/client/assets/{Upload01-C5h_Ix7W.js → Upload01-upw1x0fu.js} +1 -1
  32. package/dist/client/assets/{User01-CUapW0fb.js → User01-C5TZQK7R.js} +1 -1
  33. package/dist/client/assets/{Users01-JUfxIgyp.js → Users01-BfpezPhr.js} +1 -1
  34. package/dist/client/assets/{Users03-z294ZsnP.js → Users03-CE96bjDU.js} +1 -1
  35. package/dist/client/assets/{X-JIEN58gT.js → X-BAcFjDLZ.js} +1 -1
  36. package/dist/client/assets/{XCircle-CiUvxVPE.js → XCircle-0AburiRk.js} +1 -1
  37. package/dist/client/assets/{XClose-wRBGncgC.js → XClose-Dblscjpe.js} +1 -1
  38. package/dist/client/assets/{Zap-BQYrqlMu.js → Zap-sGlb2pCe.js} +1 -1
  39. package/dist/client/assets/{ZapSquare-CfNDhosm.js → ZapSquare-Ct3pQbJk.js} +1 -1
  40. package/dist/client/assets/{ZoomOut-CpHKX3nF.js → ZoomOut-B7QFd4vA.js} +1 -1
  41. package/dist/client/assets/{access-gate-DqFWtT0W.js → access-gate-Cu_jbgfu.js} +1 -1
  42. package/dist/client/assets/{add-section-modal-BViw2wk8.js → add-section-modal-DEKDd_8K.js} +1 -1
  43. package/dist/client/assets/{agent-icon-sHVCKtO1.js → agent-icon-NyenwiCN.js} +1 -1
  44. package/dist/client/assets/{agents-list--z06TKpA.js → agents-list-DSWExxFq.js} +1 -1
  45. package/dist/client/assets/{ai-providers-CB5VnxdE.js → ai-providers-pvwu7Iju.js} +1 -1
  46. package/dist/client/assets/{alert-BVisiOH2.js → alert-DoxlbxTN.js} +1 -1
  47. package/dist/client/assets/{alert-dialog-C02OjM43.js → alert-dialog-tYGaVVY2.js} +1 -1
  48. package/dist/client/assets/{app-editor-nNikVeJ_.js → app-editor-BIFstkuK.js} +1 -1
  49. package/dist/client/assets/{auth-Dgiw8LxL.js → auth-BMh8AcPX.js} +1 -1
  50. package/dist/client/assets/{auth-catchall-zQDdfCHn.js → auth-catchall-B7DKnUZ0.js} +1 -1
  51. package/dist/client/assets/{auth-entry-DwnS23KG.js → auth-entry-DbfEf2Pk.js} +1 -1
  52. package/dist/client/assets/{auth-split-layout--pPotUGW.js → auth-split-layout-XDxT2PZ_.js} +1 -1
  53. package/dist/client/assets/{authenticate-and-persist-oauth-BDwtso9K.js → authenticate-and-persist-oauth-Bi10euVa.js} +1 -1
  54. package/dist/client/assets/{automation-list-row-CwwqrdK1.js → automation-list-row-CRj8u1mh.js} +1 -1
  55. package/dist/client/assets/{automation-runs-BHpGnh6a.js → automation-runs-Ciw8QwPp.js} +1 -1
  56. package/dist/client/assets/{automations-BsrkJz5z.js → automations-DtH6n0kg.js} +1 -1
  57. package/dist/client/assets/{avatar-da0REx-6.js → avatar-DZVCUWJa.js} +1 -1
  58. package/dist/client/assets/{badge-C-6dkeIL.js → badge-D6mycOdi.js} +1 -1
  59. package/dist/client/assets/{block-document-CJhQCpDD.js → block-document-Cn7SkBGw.js} +1 -1
  60. package/dist/client/assets/{brand-context-J6fF3GVn.js → brand-context-Byi3pAYU.js} +1 -1
  61. package/dist/client/assets/{buckets-CNEOIphi.js → buckets-Ck7ZrUFW.js} +1 -1
  62. package/dist/client/assets/{bulk-category-panel-B-y33Rfi.js → bulk-category-panel-Cl2xRz7X.js} +1 -1
  63. package/dist/client/assets/{capability-load-error-tQHnXmUE.js → capability-load-error-CLg0RHNn.js} +1 -1
  64. package/dist/client/assets/{card-lHrEcEcH.js → card-64hGMuaF.js} +1 -1
  65. package/dist/client/assets/{category-editor-BoqOkzGJ.js → category-editor-XT9_JnIL.js} +1 -1
  66. package/dist/client/assets/{chat-context-BQw7DpZg.js → chat-context-DL3uNsc1.js} +1 -1
  67. package/dist/client/assets/{checkbox-Bt7CFcXb.js → checkbox-BQRML9jU.js} +1 -1
  68. package/dist/client/assets/{cli-auth-success-wmRyg39W.js → cli-auth-success-CcmYSDeU.js} +1 -1
  69. package/dist/client/assets/{collection-detail-7A3T4wsC.js → collection-detail-Bz77vPS3.js} +1 -1
  70. package/dist/client/assets/{collection-display-button-b1yfn-9P.js → collection-display-button-jop7oebk.js} +1 -1
  71. package/dist/client/assets/{collection-search-D33vGvGy.js → collection-search-oAyjO01P.js} +1 -1
  72. package/dist/client/assets/{collection-tabs-DIk-bobx.js → collection-tabs-R0hXD9F9.js} +1 -1
  73. package/dist/client/assets/{command-Cicqwqt0.js → command-Bp0zF48s.js} +1 -1
  74. package/dist/client/assets/{commerce-onboarding-Be56Wa5i.js → commerce-onboarding-C4FFo6nm.js} +1 -1
  75. package/dist/client/assets/{connect-desktop-dialog-B29M4_7-.js → connect-desktop-dialog-RuXtmn34.js} +1 -1
  76. package/dist/client/assets/{connection-card-CMk4PYA8.js → connection-card-B_5qrhPY.js} +1 -1
  77. package/dist/client/assets/connection-detail-D2_MqKHL.js +1 -0
  78. package/dist/client/assets/{connection-form-helpers-Cs8UTQ6j.js → connection-form-helpers-CVxOGgHj.js} +1 -1
  79. package/dist/client/assets/{connections-BoAlPFcK.js → connections-Twq5fyFU.js} +1 -1
  80. package/dist/client/assets/{context-menu-DkNeFkFe.js → context-menu-s1j38JVH.js} +1 -1
  81. package/dist/client/assets/{decopilot-BdLKNpLx.js → decopilot-sgbWj36U.js} +1 -1
  82. package/dist/client/assets/{decopilot-sse-pool-CRUoU8id.js → decopilot-sse-pool-BlZovkkx.js} +1 -1
  83. package/dist/client/assets/{dialog-C6eN_GWo.js → dialog-tOuSiWZ7.js} +1 -1
  84. package/dist/client/assets/{domain-settings-BAMyh2aJ.js → domain-settings-DOxIl_FA.js} +1 -1
  85. package/dist/client/assets/{drawer-DBgVXL7W.js → drawer-2RKH_gmr.js} +1 -1
  86. package/dist/client/assets/{dropdown-menu-Ca0zE1FR.js → dropdown-menu-CKDjXx4n.js} +1 -1
  87. package/dist/client/assets/{empty-state-DU7VtTvQ.js → empty-state-BbQ4BMJ0.js} +1 -1
  88. package/dist/client/assets/{extract-connection-data-DdGMzQ2J.js → extract-connection-data-DdknClc7.js} +1 -1
  89. package/dist/client/assets/{file-explorer-DgKGNuiW.js → file-explorer-mfP_dCwb.js} +1 -1
  90. package/dist/client/assets/{file-type-icon-yCE2GCjV.js → file-type-icon-CnPken9t.js} +1 -1
  91. package/dist/client/assets/{files-BTTlFYBV.js → files-DR9gmv6n.js} +1 -1
  92. package/dist/client/assets/{form-BiEezRDH.js → form-CaERRu7j.js} +1 -1
  93. package/dist/client/assets/{general-Cm3dH1a_.js → general-Ctk6hAf1.js} +1 -1
  94. package/dist/client/assets/{github-repo-picker-DK2EHXWI.js → github-repo-picker-C_cKCDQx.js} +1 -1
  95. package/dist/client/assets/{hooks-B7ZPUa4b.js → hooks-DxBOXWRG.js} +1 -1
  96. package/dist/client/assets/{import-from-deco-dialog-BjaXwauD.js → import-from-deco-dialog-BPM0_lGT.js} +1 -1
  97. package/dist/client/assets/{index-CmQneLRt.js → index-B8cE9Ayk.js} +1 -1
  98. package/dist/client/assets/{index-Cnq2QP5O.js → index-BXV3H1Wh.js} +1 -1
  99. package/dist/client/assets/{index-BLv7aUWc.js → index-Bj8Fs0FD.js} +1 -1
  100. package/dist/client/assets/{index-CLjjbloj.js → index-Bjr1QCY4.js} +1 -1
  101. package/dist/client/assets/{index-D-l-WEeW.js → index-BwNhM2gi.js} +1 -1
  102. package/dist/client/assets/{index-PkC17ui6.js → index-By-7VKS-.js} +1 -1
  103. package/dist/client/assets/{index-B9Ao8wmt.js → index-BzY0nuu5.js} +3 -3
  104. package/dist/client/assets/{index-ChKXna8_.js → index-Cf4vEU0r.js} +1 -1
  105. package/dist/client/assets/{index-Bxkb3F-y.js → index-CpWea0QN.js} +1 -1
  106. package/dist/client/assets/{index-CWZqP71T.js → index-DB1Psi9W.js} +1 -1
  107. package/dist/client/assets/{index-BlBEM2P2.js → index-GlTWH3TF.js} +5 -5
  108. package/dist/client/assets/{index-DoDR3KfI.js → index-TAtYx4hs.js} +1 -1
  109. package/dist/client/assets/index-bX9YRrM1.js +3 -0
  110. package/dist/client/assets/{index-Baw6EDbK.js → index-mgkbr-pP.js} +1 -1
  111. package/dist/client/assets/{index-redirect-BMZF80XN.js → index-redirect-B91gJuyt.js} +1 -1
  112. package/dist/client/assets/{input-B9GInL8N.js → input-sCvWt9Sp.js} +1 -1
  113. package/dist/client/assets/{integration-icon-CS3QcYic.js → integration-icon-DVFv2J1b.js} +1 -1
  114. package/dist/client/assets/{label-igcYMqxR.js → label-CX0MNzad.js} +1 -1
  115. package/dist/client/assets/{login-DwqPD4pE.js → login-BN93KDRX.js} +1 -1
  116. package/dist/client/assets/{mcp-oauth-BjTMgazS.js → mcp-oauth-Boi65ssT.js} +1 -1
  117. package/dist/client/assets/{members-D1qMidJc.js → members-COVFPVHM.js} +1 -1
  118. package/dist/client/assets/{monaco-editor-Dzd-YjFt.js → monaco-editor-D_NDvKT6.js} +1 -1
  119. package/dist/client/assets/{monitoring-stats-row-LX-YEi8n.js → monitoring-stats-row-D_KgYgsn.js} +1 -1
  120. package/dist/client/assets/{oauth-callback-CYyBWKkC.js → oauth-callback-DMYUPpPj.js} +1 -1
  121. package/dist/client/assets/{oauth-callback-ai-provider-Cl9r-LnA.js → oauth-callback-ai-provider-CGZsXob9.js} +1 -1
  122. package/dist/client/assets/{onboarding-Aw1t9GvW.js → onboarding-BG-tkHy3.js} +1 -1
  123. package/dist/client/assets/{org-install-ClFp6XYO.js → org-install-ZlT7XbIG.js} +1 -1
  124. package/dist/client/assets/{org-layout-Dcj-0Nzw.js → org-layout-MAuxUQk3.js} +1 -1
  125. package/dist/client/assets/{organization-choice-lYnjfutg.js → organization-choice-DswXGxs6.js} +1 -1
  126. package/dist/client/assets/{page-seo-form-C-ySb_xa.js → page-seo-form-BSuDUHZS.js} +1 -1
  127. package/dist/client/assets/page-seo-sheet-7d-Bqnm_.js +1 -0
  128. package/dist/client/assets/{popover-C7-3mJmR.js → popover-D_Jq9AkI.js} +1 -1
  129. package/dist/client/assets/{post-editor-DY-1AmJQ.js → post-editor-DDUGbJ1Y.js} +1 -1
  130. package/dist/client/assets/{primitives-Dewleh8p.js → primitives-BSaRguDU.js} +1 -1
  131. package/dist/client/assets/{profile-B6XMKxEJ.js → profile-CRakuXqd.js} +1 -1
  132. package/dist/client/assets/project-app-view-BKZTYnYb.js +1 -0
  133. package/dist/client/assets/record-editor-Bx3V6q66.js +1 -0
  134. package/dist/client/assets/registry-Byh98gtT.js +2 -0
  135. package/dist/client/assets/{registry-layout-u9FQ35ay.js → registry-layout-B9h2VNuT.js} +1 -1
  136. package/dist/client/assets/{require-capability-CJ4BUjxP.js → require-capability-LhTLego4.js} +1 -1
  137. package/dist/client/assets/{required-auth-layout-DC2JipTC.js → required-auth-layout-BwlB3hT_.js} +1 -1
  138. package/dist/client/assets/{reset-password-DhGzTGzA.js → reset-password-45ElVXgZ.js} +1 -1
  139. package/dist/client/assets/{roles-CAeMWaBT.js → roles-D-F6uggn.js} +1 -1
  140. package/dist/client/assets/{scroll-area-C2MVvTv-.js → scroll-area-BcPhOSvB.js} +1 -1
  141. package/dist/client/assets/{search-input-pvyq0Ryr.js → search-input-qCzRqiCT.js} +1 -1
  142. package/dist/client/assets/{secrets-mSKm3E6f.js → secrets-LwuMF3vc.js} +1 -1
  143. package/dist/client/assets/{sections-editor-DelFsk_I.js → sections-editor-DoGcfaIZ.js} +1 -1
  144. package/dist/client/assets/{select-DowyP0RI.js → select-CJ7jz9Z9.js} +1 -1
  145. package/dist/client/assets/select-model-CPPb7cal.js +1 -0
  146. package/dist/client/assets/{seo-editor-yjCq2P7H.js → seo-editor-COls6IDg.js} +1 -1
  147. package/dist/client/assets/{settings-layout-Bw-IZzcG.js → settings-layout-DaKkW6au.js} +1 -1
  148. package/dist/client/assets/{settings-section-Dq55iBl8.js → settings-section-DKNJQzwy.js} +1 -1
  149. package/dist/client/assets/{sheet-Dv3VjQP4.js → sheet-CPEi7X73.js} +1 -1
  150. package/dist/client/assets/{shell-controls-Dnba06Bt.js → shell-controls-BrJEK4kE.js} +1 -1
  151. package/dist/client/assets/shell-layout-CXi8lOgR.js +1 -0
  152. package/dist/client/assets/{shell-route-loading-DQbg2DQh.js → shell-route-loading-CC3UimxD.js} +1 -1
  153. package/dist/client/assets/{sidebar-Bx0s2VtK.js → sidebar-CnKww5kc.js} +1 -1
  154. package/dist/client/assets/{skeleton-aNByr9de.js → skeleton-DoAd-S8T.js} +1 -1
  155. package/dist/client/assets/{sortable.esm-B_LAX6mE.js → sortable.esm-DtmjEMrN.js} +1 -1
  156. package/dist/client/assets/{sso-Nq7bnxRl.js → sso-B4xqoOHU.js} +1 -1
  157. package/dist/client/assets/{store-Cfptiv_R.js → store-BcY40njQ.js} +1 -1
  158. package/dist/client/assets/store-registry-BMCV63g3.js +2 -0
  159. package/dist/client/assets/{studio-tools-DCFULoxT.js → studio-tools-CMUk4Fd2.js} +1 -1
  160. package/dist/client/assets/{switch-BRZ0zvqu.js → switch-Dwex1Rv6.js} +1 -1
  161. package/dist/client/assets/{table-_HtJ8rTN.js → table-Dq0v4lcZ.js} +1 -1
  162. package/dist/client/assets/{tabs-CCkYAsZQ.js → tabs-DExerPbu.js} +1 -1
  163. package/dist/client/assets/{task-status-CmZ8DRjX.js → task-status-v2LGntNn.js} +1 -1
  164. package/dist/client/assets/{textarea-B_2rOx2H.js → textarea-BWac1Umj.js} +1 -1
  165. package/dist/client/assets/{toggle-group-Cslq4Ey4.js → toggle-group-DW5ZLR4W.js} +1 -1
  166. package/dist/client/assets/{toolbar-CQGEYEng.js → toolbar-DQcL3CcC.js} +1 -1
  167. package/dist/client/assets/{toolbar-icon-button-D85a3IGp.js → toolbar-icon-button-D30CBwf5.js} +1 -1
  168. package/dist/client/assets/{tools-list-B0B2oOae.js → tools-list-C7ppCIYO.js} +1 -1
  169. package/dist/client/assets/{tooltip-_iJUAbMm.js → tooltip-BvaBl3RJ.js} +1 -1
  170. package/dist/client/assets/{types-CIhITqRw.js → types-CXincWoJ.js} +1 -1
  171. package/dist/client/assets/{use-ai-providers-B1jelcLH.js → use-ai-providers-BPLfgqfn.js} +1 -1
  172. package/dist/client/assets/{use-automations-DSn173K_.js → use-automations-6yJ93w13.js} +1 -1
  173. package/dist/client/assets/{use-capability-CkA3H54A.js → use-capability-BN4M2_zd.js} +1 -1
  174. package/dist/client/assets/{use-clock-tick-Dvupf-bX.js → use-clock-tick-DP4boo43.js} +1 -1
  175. package/dist/client/assets/{use-collections-BFFwPD6f.js → use-collections-DAFjPv4P.js} +1 -1
  176. package/dist/client/assets/{use-connection-CYURjB42.js → use-connection-D0fdk0vC.js} +1 -1
  177. package/dist/client/assets/{use-copy-B63WXJYS.js → use-copy-hsSbPZh_.js} +1 -1
  178. package/dist/client/assets/{use-create-virtual-mcp-COiimVcI.js → use-create-virtual-mcp-DTigo2RO.js} +1 -1
  179. package/dist/client/assets/{use-debounced-autosave-BCnDXS-W.js → use-debounced-autosave-CvR4Yhm5.js} +1 -1
  180. package/dist/client/assets/{use-debounced-value-CxFeJegd.js → use-debounced-value-CjFamjEw.js} +1 -1
  181. package/dist/client/assets/{use-decopilot-events-C_RtJCkB.js → use-decopilot-events-BsDXAxg_.js} +1 -1
  182. package/dist/client/assets/{use-delete-connection-Th3I2Grd.js → use-delete-connection-Cotp4fTI.js} +1 -1
  183. package/dist/client/assets/{use-file-configs-DRzzEvWG.js → use-file-configs-DOrJatWn.js} +1 -1
  184. package/dist/client/assets/{use-infinite-scroll-C1LXuops.js → use-infinite-scroll-Dnu8L65D.js} +1 -1
  185. package/dist/client/assets/{use-join-requests-DbUQG7rY.js → use-join-requests--qKhZQIM.js} +1 -1
  186. package/dist/client/assets/{use-mcp-client-DayCKqno.js → use-mcp-client-DKWjg1-Y.js} +1 -1
  187. package/dist/client/assets/{use-mcp-prompts-C6bWF37H.js → use-mcp-prompts-CwX2ZwMB.js} +1 -1
  188. package/dist/client/assets/{use-mcp-tools-BOXutgpw.js → use-mcp-tools-BfF9xbHl.js} +1 -1
  189. package/dist/client/assets/{use-members-Bp8Gqbo1.js → use-members-B-7uBsaO.js} +1 -1
  190. package/dist/client/assets/{use-mobile-qKLe_Dqz.js → use-mobile-BCfNS3o9.js} +1 -1
  191. package/dist/client/assets/{use-navigate-to-agent-BXeOGWLV.js → use-navigate-to-agent-Ch6aOf0B.js} +1 -1
  192. package/dist/client/assets/{use-org-auth-client-CT5qCNsQ.js → use-org-auth-client-EOGiehN9.js} +1 -1
  193. package/dist/client/assets/{use-org-fs-BVm9Ww7F.js → use-org-fs-CTZb2QWX.js} +1 -1
  194. package/dist/client/assets/{use-org-sso-BboGU8lh.js → use-org-sso-CKAV0tB7.js} +1 -1
  195. package/dist/client/assets/{use-organization-roles-DuDqAUGX.js → use-organization-roles-C-3z4nPh.js} +1 -1
  196. package/dist/client/assets/{use-organization-settings-CuvVZBWJ.js → use-organization-settings-hXM3SSCg.js} +1 -1
  197. package/dist/client/assets/{use-registry-connections-Cnqb8BDD.js → use-registry-connections-C3IMaCyZ.js} +1 -1
  198. package/dist/client/assets/{use-secrets-DKYvfx6d.js → use-secrets-DOpeWkvY.js} +1 -1
  199. package/dist/client/assets/{use-status-sounds-Dq78-Nzu.js → use-status-sounds-CSeCYoKG.js} +1 -1
  200. package/dist/client/assets/{use-view-mode-B9c-blVw.js → use-view-mode-a59rshI9.js} +1 -1
  201. package/dist/client/assets/{use-virtual-mcp-BzT24lMl.js → use-virtual-mcp-CnHHAQgE.js} +1 -1
  202. package/dist/client/assets/useInfiniteQuery-CVlCz4fU.js +1 -0
  203. package/dist/client/assets/useSuspenseInfiniteQuery-DTOX03Si.js +1 -0
  204. package/dist/client/assets/{useSuspenseQueries-Dh0Teq7H.js → useSuspenseQueries-BiXjl6Cz.js} +1 -1
  205. package/dist/client/assets/{variant-calendar-CIqxwzxO.js → variant-calendar-DfNTT13S.js} +1 -1
  206. package/dist/client/assets/{view-mode-toggle-CTbcbrBN.js → view-mode-toggle-Dqi605OP.js} +1 -1
  207. package/dist/client/index.html +1 -1
  208. package/dist/server/cli.js +10 -7
  209. package/dist/server/server.js +6 -6
  210. package/package.json +1 -1
  211. package/dist/client/assets/connection-detail-BAAgodqv.js +0 -1
  212. package/dist/client/assets/index-CfAoQjOV.js +0 -3
  213. package/dist/client/assets/page-seo-sheet-B_9HDZv9.js +0 -1
  214. package/dist/client/assets/project-app-view-B2pyLY-d.js +0 -1
  215. package/dist/client/assets/record-editor-ZUyT16eI.js +0 -1
  216. package/dist/client/assets/registry-BFQtHGU7.js +0 -2
  217. package/dist/client/assets/select-model-spAZNms2.js +0 -1
  218. package/dist/client/assets/shell-layout-B_aCduIv.js +0 -1
  219. package/dist/client/assets/store-registry-Dvewd3Jk.js +0 -2
  220. package/dist/client/assets/useInfiniteQuery-jy1IZJY-.js +0 -1
  221. package/dist/client/assets/useSuspenseInfiniteQuery-D75NUtWE.js +0 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "decocms",
3
- "version": "4.13.0",
3
+ "version": "4.15.0",
4
4
  "description": "Deco CMS — Self-hostable MCP Gateway for managing AI connections and tools",
5
5
  "author": "Deco team",
6
6
  "repository": {
@@ -1 +0,0 @@
1
- import{o as fe,aF as Ie,b6 as Ae,s as le,aD as De,c as P,j as t,i as ge,B as V,r as G,l as je,D as J,q as $e,K as ne,b as Y,a9 as ce,z as Pe,b7 as Oe,E as ze,e as Me,b8 as Ee,m as Ve,p as Ue,n as Fe,t as q,b9 as Re}from"./index-B9Ao8wmt.js";import{a as Le}from"./extract-connection-data-DdGMzQ2J.js";import{E as ve}from"./empty-state-DU7VtTvQ.js";import{E as Be,c as He,r as We,b as Xe,d as qe}from"./connection-form-helpers-Cs8UTQ6j.js";import{c as Ge,S as Ke,V as Qe}from"./index-BLv7aUWc.js";import{u as be,T as Je}from"./tools-list-B0B2oOae.js";import{u as Ye}from"./use-members-Bp8Gqbo1.js";import{A as Ze}from"./avatar-da0REx-6.js";import{a as Ne,b as ye,u as et}from"./use-connection-CYURjB42.js";import{u as _e}from"./use-mcp-client-DayCKqno.js";import{a as tt}from"./use-mcp-tools-BOXutgpw.js";import{a as st}from"./use-mcp-prompts-C6bWF37H.js";import{i as nt,a as ot}from"./mcp-oauth-BjTMgazS.js";import{I as oe}from"./integration-icon-CS3QcYic.js";import{s as it}from"./Plus-CYYMn5Hd.js";import{C as at,E as rt,am as lt,ab as ct}from"./agent-icon-sHVCKtO1.js";import{a as Ce,s as dt}from"./Settings02-C2s7RYQy.js";import{s as ae}from"./Trash01-CGa_hcb0.js";import{d as mt,c as ut,b as xt,S as pt,a as ht}from"./sheet-Dv3VjQP4.js";import{F as L,b as B,c as H,d as E,e as W,f as ft,a as gt}from"./form-BiEezRDH.js";import{I as X}from"./input-B9GInL8N.js";import{u as jt,D as vt}from"./use-delete-connection-Th3I2Grd.js";import{c as bt,C as Nt,B as yt,a as _t,b as Ct,d as St,e as wt}from"./monitoring-stats-row-LX-YEi8n.js";import{u as kt}from"./studio-tools-DCFULoxT.js";import{u as Tt}from"./use-virtual-mcp-BzT24lMl.js";import{i as Se}from"./ChevronRight-BaENZPcV.js";import{a as we}from"./Users03-z294ZsnP.js";import{b as ee,a as It,c as te,T as At}from"./tabs-CCkYAsZQ.js";import{g as ke}from"./connection-slug-eyAPH6o3.js";import{n as Dt}from"./ZapSquare-CfNDhosm.js";import{c as $t}from"./Tool01-CZmFMeMt.js";import{g as re,M as Pt}from"./types-CIhITqRw.js";import{C as Ot}from"./collection-search-D33vGvGy.js";import{C as zt}from"./card-lHrEcEcH.js";import{B as Mt}from"./badge-C-6dkeIL.js";import{D as Et,a as Vt,b as Ut,c as de}from"./dropdown-menu-Ca0zE1FR.js";import{S as me,a as ue,b as xe,c as pe,d as R}from"./select-DowyP0RI.js";import{i as Ft}from"./CheckCircle-vBH9TcCu.js";import{t as Rt}from"./ChevronDown-Dfa1LeSc.js";import{n as Lt}from"./XCircle-CiUvxVPE.js";import{s as se}from"./Star01-1j1KAatA.js";import{s as Bt}from"./XClose-wRBGncgC.js";import"./index-Bxkb3F-y.js";import"./sidebar-Bx0s2VtK.js";import"./LayoutLeft-BEL6Qq7i.js";import"./use-mobile-qKLe_Dqz.js";import"./tooltip-_iJUAbMm.js";import"./ZoomOut-CpHKX3nF.js";import"./Key01-DTb-8z2n.js";import"./auth-Dgiw8LxL.js";import"./use-registry-connections-Cnqb8BDD.js";import"./use-organization-settings-CuvVZBWJ.js";import"./index-Baw6EDbK.js";import"./index-ChKXna8_.js";import"./index-CWZqP71T.js";import"./popover-C7-3mJmR.js";import"./ChevronUp-DUUcpPbv.js";import"./SearchMd-D6dyPzQF.js";import"./use-create-virtual-mcp-COiimVcI.js";import"./use-navigate-to-agent-BXeOGWLV.js";import"./Eye-C-jpM5nK.js";import"./use-org-auth-client-CT5qCNsQ.js";import"./User01-CUapW0fb.js";import"./use-collections-BFFwPD6f.js";import"./AlertCircle-B9j2NALT.js";import"./SwitchHorizontal01-BVs7ZyE_.js";import"./ArrowUpRight-D2OUoipa.js";import"./DotsVertical-Ccteydn1.js";import"./Stars02-BlDXKEXS.js";import"./Globe01-DxDPO9eI.js";import"./FilterLines-Bn-qPJAD.js";import"./Globe04-Bel5dpSv.js";import"./HardDrive-BhQyUqC1.js";import"./LinkExternal01-DUbMRHAl.js";import"./Monitor01-VxvNot22.js";import"./Sun-DcCtK_JQ.js";import"./Palette-Q9O74bLu.js";import"./Play-BLfDQNw5.js";import"./SearchLg-DmLiQ0fi.js";import"./Shield01-DRgXRZgZ.js";import"./Stars01-DSeLCepl.js";import"./Upload01-C5h_Ix7W.js";import"./Users01-JUfxIgyp.js";import"./X-JIEN58gT.js";import"./Zap-BQYrqlMu.js";import"./label-igcYMqxR.js";import"./alert-dialog-C02OjM43.js";const Ht=fe({scopes:De(le()).describe("List of scopes available"),stateSchema:Ie(le(),Ae()).describe("JSON Schema (draft-07) defining the state structure")}),Wt=[{name:"MCP_CONFIGURATION",inputSchema:fe({}),outputSchema:Ht}];function Xt(s){const e=P.c(46),{instance:n,onConfigure:a,onAuthenticate:r,onDelete:o,onToggleStatus:i}=s;let c;e[0]!==n.id?(c={connectionId:n.id},e[0]=n.id,e[1]=c):c=e[1];const l=be(c),x=!(n.connection_type==="VIRTUAL")&&l.supportsOAuth&&!l.isAuthenticated,p=n.status!=="active",d=x||p?"border-destructive/50 bg-destructive/5":"border-transparent";let f;e[2]!==d?(f=je("flex items-center gap-3 rounded-lg border px-4 py-2.5 transition-colors",d),e[2]=d,e[3]=f):f=e[3];let g;e[4]!==n.icon||e[5]!==n.title?(g=t.jsx(oe,{icon:n.icon,name:n.title,size:"xs",className:"shrink-0"}),e[4]=n.icon,e[5]=n.title,e[6]=g):g=e[6];let v;e[7]!==n.title?(v=t.jsx("p",{className:"text-sm font-medium truncate",children:n.title}),e[7]=n.title,e[8]=v):v=e[8];let b;e[9]!==n.status||e[10]!==p||e[11]!==x?(b=x?t.jsx("span",{className:"text-xs text-destructive font-medium",children:"Needs authorization"}):p?t.jsx("span",{className:"text-xs text-destructive font-medium",children:n.status==="error"?"Disabled (error)":"Disabled"}):null,e[9]=n.status,e[10]=p,e[11]=x,e[12]=b):b=e[12];let j;e[13]!==v||e[14]!==b?(j=t.jsxs("div",{className:"flex-1 min-w-0",children:[v,b]}),e[13]=v,e[14]=b,e[15]=j):j=e[15];let N;e[16]!==n||e[17]!==x||e[18]!==r?(N=x&&t.jsx(V,{variant:"outline",size:"sm",className:"h-7 text-xs",onClick:()=>r(n),children:"Authorize"}),e[16]=n,e[17]=x,e[18]=r,e[19]=N):N=e[19];let T;e[20]!==n||e[21]!==p||e[22]!==i?(T=p?t.jsxs(V,{variant:"outline",size:"sm",className:"h-7 text-xs gap-1.5",onClick:()=>i(n,"active"),children:[t.jsx(at,{size:13}),"Enable"]}):t.jsx(V,{variant:"ghost",size:"icon",className:"h-7 w-7 text-muted-foreground",onClick:()=>i(n,"inactive"),title:"Disable",children:t.jsx(rt,{size:13})}),e[20]=n,e[21]=p,e[22]=i,e[23]=T):T=e[23];let S;e[24]!==n||e[25]!==a?(S=()=>a(n),e[24]=n,e[25]=a,e[26]=S):S=e[26];let y;e[27]===Symbol.for("react.memo_cache_sentinel")?(y=t.jsx(Ce,{size:13}),e[27]=y):y=e[27];let I;e[28]!==S?(I=t.jsx(V,{variant:"ghost",size:"icon",className:"h-7 w-7",onClick:S,title:"Configure",children:y}),e[28]=S,e[29]=I):I=e[29];let _;e[30]!==n||e[31]!==o?(_=()=>o(n),e[30]=n,e[31]=o,e[32]=_):_=e[32];let k;e[33]===Symbol.for("react.memo_cache_sentinel")?(k=t.jsx(ae,{size:13}),e[33]=k):k=e[33];let C;e[34]!==_?(C=t.jsx(V,{variant:"ghost",size:"icon",className:"h-7 w-7 text-muted-foreground hover:text-destructive",onClick:_,title:"Delete",children:k}),e[34]=_,e[35]=C):C=e[35];let h;e[36]!==I||e[37]!==C||e[38]!==N||e[39]!==T?(h=t.jsxs("div",{className:"flex items-center gap-1 shrink-0",children:[N,T,I,C]}),e[36]=I,e[37]=C,e[38]=N,e[39]=T,e[40]=h):h=e[40];let w;return e[41]!==h||e[42]!==f||e[43]!==g||e[44]!==j?(w=t.jsxs("div",{className:f,children:[g,j,h]}),e[41]=h,e[42]=f,e[43]=g,e[44]=j,e[45]=w):w=e[45],w}function qt(s){const e=P.c(15),{instance:n,onConfigure:a}=s;let r;e[0]!==n.icon||e[1]!==n.title?(r=t.jsx(oe,{icon:n.icon,name:n.title,size:"xs",className:"shrink-0"}),e[0]=n.icon,e[1]=n.title,e[2]=r):r=e[2];let o;e[3]!==n.title?(o=t.jsx("div",{className:"flex-1 min-w-0",children:t.jsx("p",{className:"text-sm font-medium truncate",children:n.title})}),e[3]=n.title,e[4]=o):o=e[4];let i;e[5]!==n||e[6]!==a?(i=()=>a(n),e[5]=n,e[6]=a,e[7]=i):i=e[7];let c;e[8]===Symbol.for("react.memo_cache_sentinel")?(c=t.jsx(Ce,{size:13}),e[8]=c):c=e[8];let l;e[9]!==i?(l=t.jsx("div",{className:"flex items-center gap-1 shrink-0",children:t.jsx(V,{variant:"ghost",size:"icon",className:"h-7 w-7",onClick:i,title:"Configure",children:c})}),e[9]=i,e[10]=l):l=e[10];let u;return e[11]!==r||e[12]!==o||e[13]!==l?(u=t.jsxs("div",{className:"flex items-center gap-3 rounded-lg border border-transparent px-4 py-2.5 transition-colors",children:[r,o,l]}),e[11]=r,e[12]=o,e[13]=l,e[14]=u):u=e[14],u}function Gt(s){const e=P.c(27),{instances:n,onConfigure:a,onAuthenticate:r,onDelete:o,onToggleStatus:i,onAdd:c,isAdding:l}=s;if(n.length===0)return null;const u=n.length===1?"Instance":"Instances";let x;e[0]!==u?(x=t.jsx("h3",{className:"text-sm font-semibold text-foreground",children:u}),e[0]=u,e[1]=x):x=e[1];let p;e[2]!==l?(p=l?t.jsx(ge,{size:13,className:"animate-spin"}):t.jsx(it,{size:13}),e[2]=l,e[3]=p):p=e[3];let d;e[4]!==l||e[5]!==c||e[6]!==p?(d=t.jsxs(V,{variant:"default",size:"sm",className:"h-7 gap-1.5 text-xs",onClick:c,disabled:l,children:[p,"Add instance"]}),e[4]=l,e[5]=c,e[6]=p,e[7]=d):d=e[7];let f;e[8]!==x||e[9]!==d?(f=t.jsxs("div",{className:"px-5 py-4 border-b border-border flex items-center justify-between",children:[x,d]}),e[8]=x,e[9]=d,e[10]=f):f=e[10];let g;if(e[11]!==n||e[12]!==r||e[13]!==a||e[14]!==o||e[15]!==i){let j;e[17]!==r||e[18]!==a||e[19]!==o||e[20]!==i?(j=N=>t.jsx(G.Suspense,{fallback:t.jsx(qt,{instance:N,onConfigure:a}),children:t.jsx(Xt,{instance:N,onConfigure:a,onAuthenticate:r,onDelete:o,onToggleStatus:i})},N.id),e[17]=r,e[18]=a,e[19]=o,e[20]=i,e[21]=j):j=e[21],g=n.map(j),e[11]=n,e[12]=r,e[13]=a,e[14]=o,e[15]=i,e[16]=g}else g=e[16];let v;e[22]!==g?(v=t.jsx("div",{className:"p-2 flex flex-col gap-1",children:g}),e[22]=g,e[23]=v):v=e[23];let b;return e[24]!==f||e[25]!==v?(b=t.jsxs("div",{className:"rounded-xl border border-border bg-card overflow-hidden",children:[f,v]}),e[24]=f,e[25]=v,e[26]=b):b=e[26],b}const Kt=[{value:"7d",label:"7d"},{value:"14d",label:"14d"},{value:"30d",label:"30d"}];function Qt(s){const e=new Date,n=new Date(e);return s==="7d"?n.setDate(n.getDate()-7):s==="14d"?n.setDate(n.getDate()-14):n.setDate(n.getDate()-30),{startDate:n,endDate:e}}const Jt={calls:{label:"Tool calls"},errors:{label:"Errors"}};function Yt(s){const e=P.c(1),{connectionId:n,orgId:a,timeframe:r}=s,o=kt(),i=Qt(r),{data:c}=$e({queryKey:ne.connectionActivity(n,r,a),queryFn:async()=>await o.call("MONITORING_LOGS_LIST",{startDate:i.startDate.toISOString(),endDate:i.endDate.toISOString(),connectionId:n,limit:2e3,offset:0}),staleTime:3e5}),l=bt(c?.logs??[],i),u=l.data,x=l.totalCalls>0;let p;return e[0]===Symbol.for("react.memo_cache_sentinel")?(p=t.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"Tool calls"}),e[0]=p):p=e[0],t.jsxs("div",{children:[t.jsxs("div",{className:"flex gap-6 px-5 pb-4",children:[t.jsxs("div",{children:[t.jsx("p",{className:"text-2xl font-semibold text-foreground tabular-nums",children:l.totalCalls.toLocaleString()}),p]}),l.totalErrors>0&&t.jsxs("div",{children:[t.jsx("p",{className:"text-2xl font-semibold text-destructive tabular-nums",children:l.totalErrors.toLocaleString()}),t.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"Errors"})]}),l.avgDurationMs>0&&t.jsxs("div",{children:[t.jsxs("p",{className:"text-2xl font-semibold text-foreground tabular-nums",children:[Math.round(l.avgDurationMs),"ms"]}),t.jsx("p",{className:"text-xs text-muted-foreground mt-0.5",children:"Avg latency"})]})]}),x?t.jsxs("div",{children:[t.jsx(Nt,{config:Jt,className:"h-16 w-full",children:t.jsxs(yt,{data:u,barCategoryGap:"4%",children:[t.jsx(_t,{content:t.jsx(Ct,{labelFormatter:es}),cursor:{fill:"var(--muted)"}}),t.jsx(St,{dataKey:"calls",radius:[2,2,0,0],minPointSize:1,children:u.map(Zt)})]})}),t.jsxs("div",{className:"flex justify-between px-3 mt-1 pb-3",children:[t.jsx("span",{className:"text-[10px] text-muted-foreground",children:u[0]?.label}),t.jsx("span",{className:"text-[10px] text-muted-foreground",children:u[u.length-1]?.label})]})]}):t.jsx("div",{className:"h-20 flex items-center justify-center",children:t.jsx("p",{className:"text-sm text-muted-foreground/60",children:"No activity in this period"})})]})}function Zt(s,e){return t.jsx(wt,{fill:s.errorRate>50?"var(--destructive)":"var(--chart-1)",fillOpacity:s.calls===0?.2:s.errorRate>50?.7:.85},`cell-${e}`)}function es(s,e){const n=Array.isArray(e)?e[0]:void 0;return n&&typeof n=="object"&&"payload"in n?n.payload?.label??"":""}function ts(){const s=P.c(1);let e;return s[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsxs("div",{children:[t.jsx("div",{className:"flex gap-6 px-5 pb-4",children:t.jsxs("div",{className:"flex flex-col gap-1.5",children:[t.jsx("div",{className:"h-7 w-16 rounded-md bg-muted animate-pulse"}),t.jsx("div",{className:"h-3 w-14 rounded bg-muted animate-pulse"})]})}),t.jsx("div",{className:"h-20 w-full rounded-md bg-muted animate-pulse"})]}),s[0]=e):e=s[0],e}function ss(s){const e=P.c(13),{connectionId:n}=s,[a,r]=G.useState("14d"),{org:o}=J();let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=t.jsx("div",{children:t.jsx("h3",{className:"text-sm font-semibold text-foreground",children:"Activity"})}),e[0]=i):i=e[0];let c;e[1]!==a?(c=Kt.map(d=>t.jsx("button",{type:"button",onClick:()=>r(d.value),className:je("px-2.5 py-1 text-xs font-medium rounded-md transition-colors",a===d.value?"bg-background text-foreground shadow-sm":"text-muted-foreground hover:text-foreground"),children:d.label},d.value)),e[1]=a,e[2]=c):c=e[2];let l;e[3]!==c?(l=t.jsxs("div",{className:"px-5 py-4 flex items-center justify-between",children:[i,t.jsx("div",{className:"flex items-center gap-0.5 bg-muted rounded-lg p-0.5",children:c})]}),e[3]=c,e[4]=l):l=e[4];let u;e[5]===Symbol.for("react.memo_cache_sentinel")?(u=t.jsx(ts,{}),e[5]=u):u=e[5];let x;e[6]!==n||e[7]!==o.id||e[8]!==a?(x=t.jsx(G.Suspense,{fallback:u,children:t.jsx(Yt,{connectionId:n,orgId:o.id,timeframe:a})}),e[6]=n,e[7]=o.id,e[8]=a,e[9]=x):x=e[9];let p;return e[10]!==l||e[11]!==x?(p=t.jsxs("div",{className:"rounded-xl border border-border bg-card overflow-hidden",children:[l,x]}),e[10]=l,e[11]=x,e[12]=p):p=e[12],p}function ns(s){const e=P.c(15),{virtualMcp:n,org:a}=s,r=Y();let o;e[0]!==r||e[1]!==a||e[2]!==n.id?(o=()=>{const p=crypto.randomUUID();r({to:"/$org/$taskId",params:{org:a,taskId:p},search:{virtualmcpid:n.id}})},e[0]=r,e[1]=a,e[2]=n.id,e[3]=o):o=e[3];let i;e[4]===Symbol.for("react.memo_cache_sentinel")?(i=t.jsx(we,{size:16}),e[4]=i):i=e[4];let c;e[5]!==n.icon||e[6]!==n.title?(c=t.jsx(oe,{icon:n.icon,name:n.title,size:"xs",fallbackIcon:i}),e[5]=n.icon,e[6]=n.title,e[7]=c):c=e[7];let l;e[8]!==n.title?(l=t.jsx("span",{className:"flex-1 text-sm font-medium text-foreground truncate",children:n.title}),e[8]=n.title,e[9]=l):l=e[9];let u;e[10]===Symbol.for("react.memo_cache_sentinel")?(u=t.jsx(Se,{size:16,className:"text-muted-foreground group-hover:text-foreground transition-colors shrink-0"}),e[10]=u):u=e[10];let x;return e[11]!==o||e[12]!==c||e[13]!==l?(x=t.jsxs("button",{type:"button",onClick:o,className:"flex items-center gap-3 rounded-lg hover:bg-muted/50 transition-colors group text-left w-full",children:[c,l,u]}),e[11]=o,e[12]=c,e[13]=l,e[14]=x):x=e[14],x}function os(s){const e=P.c(7),{virtualMcps:n,org:a}=s;let r;if(e[0]!==a||e[1]!==n){let i;e[3]!==a?(i=c=>t.jsx(ns,{virtualMcp:c,org:a},c.id),e[3]=a,e[4]=i):i=e[4],r=n.map(i),e[0]=a,e[1]=n,e[2]=r}else r=e[2];let o;return e[5]!==r?(o=t.jsx("div",{className:"flex flex-col gap-3",children:t.jsx("div",{className:"flex flex-col gap-2",children:r})}),e[5]=r,e[6]=o):o=e[6],o}function is(s){const e=P.c(7),{connection:n}=s,{org:a}=J();let r;e[0]!==n.id?(r={filters:[{column:"connection_id",value:n.id}]},e[0]=n.id,e[1]=r):r=e[1];const o=Tt(r);if(!(o.length>0)){let u;return e[2]===Symbol.for("react.memo_cache_sentinel")?(u=t.jsx(t.Fragment,{}),e[2]=u):u=e[2],u}let c;e[3]===Symbol.for("react.memo_cache_sentinel")?(c=t.jsx("div",{className:"px-5 py-4 border-b border-border",children:t.jsx("h3",{className:"text-sm font-semibold text-foreground",children:"Used by agents"})}),e[3]=c):c=e[3];let l;return e[4]!==a.slug||e[5]!==o?(l=t.jsxs("div",{className:"rounded-xl border border-border bg-card overflow-hidden",children:[c,t.jsx("div",{className:"px-5 py-4",children:t.jsx(os,{virtualMcps:o,org:a.slug})})]}),e[4]=a.slug,e[5]=o,e[6]=l):l=e[6],l}function as(s){const e=P.c(31),{tools:n,connectionId:a,org:r}=s,o=Y(),{org:i}=J();let c;e[0]!==a||e[1]!==i.id||e[2]!==i.slug?(c={connectionId:a,orgId:i.id,orgSlug:i.slug},e[0]=a,e[1]=i.id,e[2]=i.slug,e[3]=c):c=e[3];const l=_e(c),u=Ne(a);let x;e[4]!==u||e[5]!==a?(x=u?ke(u):a,e[4]=u,e[5]=a,e[6]=x):x=e[6];const p=x,[d,f]=G.useState("");let g,v,b,j;if(e[7]!==p||e[8]!==l||e[9]!==o||e[10]!==r||e[11]!==d||e[12]!==n){const S=(n??[]).filter(rs),y=d.toLowerCase().trim(),I=y?S.filter(h=>h.name.toLowerCase().includes(y)||h.description&&h.description.toLowerCase().includes(y)):S;let _;e[17]!==p||e[18]!==o||e[19]!==r?(_=h=>{o({to:"/$org/settings/connections/$appSlug/$collectionName/$itemId",params:{org:r,appSlug:p,collectionName:"tools",itemId:encodeURIComponent(h.name)}})},e[17]=p,e[18]=o,e[19]=r,e[20]=_):_=e[20];const k=_;b="flex flex-col h-full overflow-hidden";let C;e[21]===Symbol.for("react.memo_cache_sentinel")?(C=h=>{h.key==="Escape"&&(f(""),h.target.blur())},e[21]=C):C=e[21],e[22]!==d?(j=t.jsx(Ot,{value:d,onChange:f,placeholder:"Search apps...",onKeyDown:C}),e[22]=d,e[23]=j):j=e[23],g="flex-1 overflow-auto p-5",v=I.length===0?t.jsx(ve,{image:null,title:d?"No apps found":"No apps available",description:d?"Try adjusting your search terms":"This connection doesn't have any tools with interactive UIs yet."}):t.jsx("div",{className:"grid grid-cols-[repeat(auto-fill,minmax(320px,1fr))] gap-4",children:I.map(h=>{const w=re(h._meta);return t.jsxs(zt,{className:"cursor-pointer transition-colors overflow-hidden gap-0",onClick:()=>k(h),children:[t.jsx("div",{className:"h-[200px] overflow-hidden border-b border-border",children:t.jsx(Pt,{resourceURI:w,toolInfo:{tool:h},displayMode:"inline",minHeight:200,maxHeight:200,client:l})}),t.jsxs("div",{className:"flex flex-col gap-2 p-4",children:[t.jsxs("div",{className:"flex items-center justify-between gap-2",children:[t.jsx("h3",{className:"text-base font-medium text-foreground truncate",children:h.name}),t.jsx(Je,{annotations:h.annotations,_meta:h._meta})]}),h.description&&t.jsx("p",{className:"text-sm text-muted-foreground line-clamp-2",children:h.description})]})]},h.name)})}),e[7]=p,e[8]=l,e[9]=o,e[10]=r,e[11]=d,e[12]=n,e[13]=g,e[14]=v,e[15]=b,e[16]=j}else g=e[13],v=e[14],b=e[15],j=e[16];let N;e[24]!==g||e[25]!==v?(N=t.jsx("div",{className:g,children:v}),e[24]=g,e[25]=v,e[26]=N):N=e[26];let T;return e[27]!==b||e[28]!==j||e[29]!==N?(T=t.jsxs("div",{className:b,children:[j,N]}),e[27]=b,e[28]=j,e[29]=N,e[30]=T):T=e[30],T}function rs(s){return!!re(s._meta)}function Te(s){const e=s.replace(/[._]/g," ").trim().split(/\s+/),n=i=>i.charAt(0).toUpperCase()+i.slice(1),a=new Set(["list","create","get","update","delete","fetch","search","run","trigger","review","send","check"]),r=e.map(n),o=e[e.length-1];return r.length>=2&&o&&a.has(o)?[r.pop(),...r].join(" "):r.join(" ")}function ie(s){const e=P.c(2),{label:n}=s;let a;return e[0]!==n?(a=t.jsx("div",{className:"px-5 py-8 text-center",children:t.jsxs("p",{className:"text-sm text-muted-foreground",children:["No ",n," available."]})}),e[0]=n,e[1]=a):a=e[1],a}function ls(s){const e=P.c(50),{tools:n,prompts:a,resources:r,connectionId:o,org:i}=s;let c;e[0]!==a?(c=a===void 0?[]:a,e[0]=a,e[1]=c):c=e[1];const l=c;let u;e[2]!==r?(u=r===void 0?[]:r,e[2]=r,e[3]=u):u=e[3];const x=u,p=Y(),d=Ne(o??"");let f;e[4]!==d||e[5]!==o?(f=d?ke(d):o,e[4]=d,e[5]=o,e[6]=f):f=e[6];const g=f;let v;e[7]!==g||e[8]!==o||e[9]!==p||e[10]!==i?(v=function(D){!o||!i||p({to:"/$org/settings/connections/$appSlug/$collectionName/$itemId",params:{org:i,appSlug:g,collectionName:"tools",itemId:encodeURIComponent(D)}})},e[7]=g,e[8]=o,e[9]=p,e[10]=i,e[11]=v):v=e[11];const b=v;let j;e[12]!==o||e[13]!==i||e[14]!==n?(j=o&&i&&n.some(ms),e[12]=o,e[13]=i,e[14]=n,e[15]=j):j=e[15];const N=j;if(n.length+l.length+x.length===0){let m;return e[16]===Symbol.for("react.memo_cache_sentinel")?(m=t.jsxs("div",{className:"rounded-xl border border-border bg-card p-5",children:[t.jsx("h3",{className:"text-sm font-semibold text-foreground mb-1",children:"Capabilities"}),t.jsx("p",{className:"text-sm text-muted-foreground",children:"No capabilities discovered yet. The connection may still be connecting."})]}),e[16]=m):m=e[16],m}let S;e[17]!==n.length?(S=t.jsxs(ee,{value:"tools",variant:"underline",children:["Tools (",n.length,")"]}),e[17]=n.length,e[18]=S):S=e[18];let y;e[19]!==N?(y=N&&t.jsx(ee,{value:"apps",variant:"underline",children:"UI"}),e[19]=N,e[20]=y):y=e[20];let I,_;e[21]===Symbol.for("react.memo_cache_sentinel")?(I=t.jsx(ee,{value:"prompts",variant:"underline",children:"Prompts"}),_=t.jsx(ee,{value:"resources",variant:"underline",children:"Resources"}),e[21]=I,e[22]=_):(I=e[21],_=e[22]);let k;e[23]!==S||e[24]!==y?(k=t.jsx("div",{className:"px-5 flex items-center justify-between border-b border-border",children:t.jsxs(It,{variant:"underline",className:"gap-1",children:[S,y,I,_]})}),e[23]=S,e[24]=y,e[25]=k):k=e[25];let C;e[26]!==b||e[27]!==n?(C=n.length>0?n.map(m=>t.jsxs("button",{type:"button",className:"w-full flex items-start gap-3 px-5 py-3 text-left hover:bg-muted/40 transition-colors cursor-pointer",onClick:()=>b(m.name),children:[t.jsx("div",{className:"mt-0.5 shrink-0 size-7 rounded-md bg-muted flex items-center justify-center",children:t.jsx($t,{size:13,className:"text-muted-foreground"})}),t.jsxs("div",{className:"flex-1 min-w-0",children:[t.jsx("div",{className:"text-sm font-medium text-foreground",children:Te(m.name)}),m.description&&t.jsx("div",{className:"text-xs text-muted-foreground mt-0.5 leading-relaxed line-clamp-2",children:m.description})]}),t.jsx(Se,{size:16,className:"text-muted-foreground shrink-0 mt-0.5"})]},m.name)):t.jsx(ie,{label:"tools"}),e[26]=b,e[27]=n,e[28]=C):C=e[28];let h;e[29]!==C?(h=t.jsx(te,{value:"tools",className:"h-auto",children:t.jsx("div",{className:"divide-y divide-border",children:C})}),e[29]=C,e[30]=h):h=e[30];let w;e[31]!==o||e[32]!==N||e[33]!==i||e[34]!==n?(w=N&&t.jsx(te,{value:"apps",className:"h-auto min-h-[200px]",children:t.jsx(as,{tools:n,connectionId:o,org:i})}),e[31]=o,e[32]=N,e[33]=i,e[34]=n,e[35]=w):w=e[35];let z;e[36]!==l?(z=l.length>0?l.map(ds):t.jsx(ie,{label:"prompts"}),e[36]=l,e[37]=z):z=e[37];let O;e[38]!==z?(O=t.jsx(te,{value:"prompts",className:"h-auto",children:t.jsx("div",{className:"divide-y divide-border",children:z})}),e[38]=z,e[39]=O):O=e[39];let A;e[40]!==x?(A=x.length>0?x.map(cs):t.jsx(ie,{label:"resources"}),e[40]=x,e[41]=A):A=e[41];let M;e[42]!==A?(M=t.jsx(te,{value:"resources",className:"h-auto",children:t.jsx("div",{className:"divide-y divide-border",children:A})}),e[42]=A,e[43]=M):M=e[43];let U;return e[44]!==k||e[45]!==h||e[46]!==w||e[47]!==O||e[48]!==M?(U=t.jsx("div",{className:"rounded-xl border border-border bg-card overflow-hidden",children:t.jsxs(At,{defaultValue:"tools",variant:"underline",children:[k,h,w,O,M]})}),e[44]=k,e[45]=h,e[46]=w,e[47]=O,e[48]=M,e[49]=U):U=e[49],U}function cs(s){return t.jsxs("div",{className:"flex items-start gap-3 px-5 py-3",children:[t.jsx("div",{className:"mt-0.5 shrink-0 size-7 rounded-md bg-muted flex items-center justify-center",children:t.jsx(lt,{size:13,className:"text-muted-foreground"})}),t.jsxs("div",{className:"flex-1 min-w-0",children:[t.jsx("div",{className:"text-sm font-medium text-foreground",children:s.name}),s.description&&t.jsx("div",{className:"text-xs text-muted-foreground mt-0.5 leading-relaxed line-clamp-2",children:s.description}),s.uri&&t.jsx("div",{className:"text-xs text-muted-foreground/60 font-mono mt-0.5 truncate",children:s.uri})]})]},s.uri??s.name)}function ds(s){return t.jsxs("div",{className:"flex items-start gap-3 px-5 py-3",children:[t.jsx("div",{className:"mt-0.5 shrink-0 size-7 rounded-md bg-muted flex items-center justify-center",children:t.jsx(Dt,{size:13,className:"text-muted-foreground"})}),t.jsxs("div",{className:"flex-1 min-w-0",children:[t.jsx("div",{className:"text-sm font-medium text-foreground",children:Te(s.name)}),s.description&&t.jsx("div",{className:"text-xs text-muted-foreground mt-0.5 leading-relaxed line-clamp-2",children:s.description})]})]},s.name)}function ms(s){return re(s._meta)}function us(s){const e=P.c(13),{connection:n,displayTitle:a}=s,r=a??n.title;let o;e[0]!==n.icon||e[1]!==r?(o=t.jsx(oe,{icon:n.icon,name:r,size:"xl",className:"shrink-0"}),e[0]=n.icon,e[1]=r,e[2]=o):o=e[2];let i;e[3]!==r?(i=t.jsx("div",{className:"flex flex-wrap items-center gap-2 mb-2",children:t.jsx("h1",{className:"text-lg md:text-xl font-semibold tracking-tight text-foreground leading-none",children:r})}),e[3]=r,e[4]=i):i=e[4];let c;e[5]!==n.description?(c=n.description&&t.jsx("p",{className:"text-sm text-muted-foreground leading-relaxed line-clamp-2",children:n.description}),e[5]=n.description,e[6]=c):c=e[6];let l;e[7]!==i||e[8]!==c?(l=t.jsxs("div",{className:"flex-1 min-w-0",children:[i,c]}),e[7]=i,e[8]=c,e[9]=l):l=e[9];let u;return e[10]!==o||e[11]!==l?(u=t.jsxs("div",{className:"flex items-center gap-4 md:gap-6 py-5 md:py-7 px-4 md:px-8 bg-background border-b border-border shrink-0",children:[o,l]}),e[10]=o,e[11]=l,e[12]=u):u=e[12],u}function xs({form:s,connection:e,hasOAuthToken:n,onReauthenticate:a,onRemoveOAuth:r}){const o=ce({control:s.control,name:"ui_type"}),i=ce({control:s.control,name:"connection_url"}),{stdioEnabled:c}=Pe(),l=(()=>{if(typeof i!="string"||!i)return!1;try{const d=new URL(i);return d.hostname==="api.githubcopilot.com"&&d.pathname.replace(/\/+$/,"")==="/mcp"}catch{return!1}})(),u=c||e.connection_type==="STDIO",x=e.connection_type==="VIRTUAL",p=x?Oe(e.connection_url):null;return x?t.jsxs("div",{className:"flex flex-col gap-4",children:[t.jsxs("div",{className:"flex flex-col gap-3",children:[t.jsx("span",{className:"text-xs text-muted-foreground font-medium",children:"Type"}),t.jsxs("div",{className:"flex items-center gap-2 h-10 px-3 border border-border rounded-lg bg-muted/50",children:[t.jsx(we,{className:"w-4 h-4 text-muted-foreground"}),t.jsx("span",{className:"text-sm",children:"Virtual MCP"})]}),t.jsx("p",{className:"text-xs text-muted-foreground",children:"This connection references a Virtual MCP. Tools and resources are aggregated dynamically from the Virtual MCP's underlying connections."})]}),p&&t.jsxs("div",{className:"flex flex-col gap-2",children:[t.jsx("span",{className:"text-xs text-muted-foreground font-medium",children:"Virtual MCP ID"}),t.jsx("div",{className:"flex items-center gap-2 h-10 px-3 border border-border rounded-lg bg-muted/50",children:t.jsx("code",{className:"text-sm text-muted-foreground",children:p})})]})]}):t.jsxs("div",{className:"flex flex-col gap-4",children:[t.jsx(L,{control:s.control,name:"ui_type",render:({field:d})=>t.jsxs(B,{className:"flex flex-col gap-3",children:[t.jsx(H,{className:"text-xs text-muted-foreground font-medium",children:"Connection"}),o!=="NPX"&&o!=="STDIO"?t.jsxs("div",{className:"flex items-stretch rounded-lg border border-border overflow-hidden",children:[t.jsxs(me,{value:d.value,onValueChange:d.onChange,children:[t.jsx(E,{children:t.jsxs(ue,{className:"h-full! w-auto min-w-[90px] border-0 rounded-none bg-muted/50 focus:ring-0 focus:ring-offset-0",children:[t.jsx(se,{className:"w-4 h-4 text-muted-foreground shrink-0"}),t.jsx(xe,{})]})}),t.jsxs(pe,{children:[t.jsx(R,{value:"HTTP",children:"HTTP"}),t.jsx(R,{value:"SSE",children:"SSE"}),t.jsx(R,{value:"Websocket",children:"Websocket"}),u&&t.jsxs(t.Fragment,{children:[t.jsx(R,{value:"NPX",children:"NPX Package"}),t.jsx(R,{value:"STDIO",children:"Custom Command"})]})]})]}),t.jsx("div",{className:"w-px bg-border"}),t.jsx(L,{control:s.control,name:"connection_url",render:({field:f})=>t.jsx(B,{className:"flex-1 min-w-0",children:t.jsx(E,{children:t.jsx(X,{placeholder:"https://example.com/mcp",...f,value:f.value??"",className:"h-10 border-0 rounded-none focus-visible:ring-0 focus-visible:ring-offset-0 bg-transparent"})})})})]}):t.jsxs(me,{value:d.value,onValueChange:d.onChange,children:[t.jsx(E,{children:t.jsx(ue,{className:"h-10",children:t.jsx(xe,{})})}),t.jsxs(pe,{children:[t.jsx(R,{value:"HTTP",children:t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(se,{className:"w-4 h-4"}),"HTTP"]})}),t.jsx(R,{value:"SSE",children:t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(se,{className:"w-4 h-4"}),"SSE"]})}),t.jsx(R,{value:"Websocket",children:t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(se,{className:"w-4 h-4"}),"Websocket"]})}),u&&t.jsxs(t.Fragment,{children:[t.jsx(R,{value:"NPX",children:t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(Lt,{className:"w-4 h-4"}),"NPX Package"]})}),t.jsx(R,{value:"STDIO",children:t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(ct,{className:"w-4 h-4"}),"Custom Command"]})})]})]})]}),t.jsx(W,{})]})}),o==="NPX"&&t.jsx(L,{control:s.control,name:"npx_package",render:({field:d})=>t.jsxs(B,{className:"flex flex-col gap-3",children:[t.jsx(H,{className:"text-xs text-muted-foreground font-medium",children:"NPM Package"}),t.jsx(E,{children:t.jsx(X,{placeholder:"@perplexity-ai/mcp-server",...d,value:d.value||"",className:"h-10 rounded-lg"})}),t.jsx(W,{})]})}),o==="STDIO"&&t.jsxs(t.Fragment,{children:[t.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[t.jsx(L,{control:s.control,name:"stdio_command",render:({field:d})=>t.jsxs(B,{className:"flex flex-col gap-3",children:[t.jsx(H,{className:"text-xs text-muted-foreground font-medium",children:"Command"}),t.jsx(E,{children:t.jsx(X,{placeholder:"node, bun, python...",...d,value:d.value||"",className:"h-10 rounded-lg"})}),t.jsx(W,{})]})}),t.jsx(L,{control:s.control,name:"stdio_args",render:({field:d})=>t.jsxs(B,{className:"flex flex-col gap-3",children:[t.jsx(H,{className:"text-xs text-muted-foreground font-medium",children:"Arguments"}),t.jsx(E,{children:t.jsx(X,{placeholder:"arg1 arg2 --flag value",...d,value:d.value||"",className:"h-10 rounded-lg"})}),t.jsx("p",{className:"text-xs text-muted-foreground",children:"Space-separated arguments"}),t.jsx(W,{})]})})]}),t.jsx(L,{control:s.control,name:"stdio_cwd",render:({field:d})=>t.jsxs(B,{className:"flex flex-col gap-3",children:[t.jsx(H,{className:"text-xs text-muted-foreground font-medium",children:"Working Directory"}),t.jsx(E,{children:t.jsx(X,{placeholder:"/path/to/project (optional)",...d,value:d.value||"",className:"h-10 rounded-lg"})}),t.jsx(W,{})]})})]}),(o==="NPX"||o==="STDIO")&&t.jsx(L,{control:s.control,name:"env_vars",render:({field:d})=>t.jsxs(B,{className:"flex flex-col gap-3",children:[t.jsx(H,{className:"text-xs text-muted-foreground font-medium",children:"Environment Variables"}),t.jsx(E,{children:t.jsx(Be,{value:d.value??[],onChange:d.onChange})}),t.jsx(W,{})]})}),o!=="NPX"&&o!=="STDIO"&&t.jsx(L,{control:s.control,name:"connection_token",render:({field:d})=>t.jsxs(B,{className:"flex flex-col gap-3",children:[t.jsx(H,{className:"text-xs text-muted-foreground font-medium",children:l?"GitHub Personal Access Token":"Token"}),n?t.jsx("div",{className:"flex items-center gap-2",children:t.jsxs(Et,{children:[t.jsx(Vt,{asChild:!0,children:t.jsx("button",{type:"button",className:"inline-flex items-center gap-1.5 cursor-pointer",children:t.jsxs(Mt,{variant:"success",className:"gap-1.5",children:[t.jsx(Ft,{size:12}),"Authenticated via OAuth",t.jsx(Rt,{size:12})]})})}),t.jsxs(Ut,{align:"start",children:[t.jsxs(de,{onClick:a,children:[t.jsx(dt,{size:16}),"Re-authenticate"]}),t.jsxs(de,{variant:"destructive",onClick:r,children:[t.jsx(ae,{size:16}),"Remove OAuth"]})]})]})}):e.connection_token&&d.value===null?t.jsxs("div",{className:"relative group",children:[t.jsx("div",{className:"h-10 px-3 flex items-center rounded-lg border border-border bg-muted/50 text-muted-foreground font-mono text-sm",children:"••••••••••••••••"}),t.jsx("button",{type:"button",onClick:()=>d.onChange(""),className:"absolute right-2 top-1/2 -translate-y-1/2 p-1 rounded hover:bg-muted opacity-0 group-hover:opacity-100 transition-opacity",title:"Clear and replace token",children:t.jsx(Bt,{size:14,className:"text-muted-foreground"})})]}):t.jsxs(t.Fragment,{children:[t.jsx(E,{children:t.jsx(X,{type:"password",placeholder:l?"Paste your GitHub PAT":"Enter access token...",...d,value:d.value||"",className:"h-10 rounded-lg"})}),l&&t.jsxs(ft,{children:["Create a PAT at"," ",t.jsx("a",{href:"https://github.com/settings/personal-access-tokens",target:"_blank",rel:"noopener noreferrer",className:"underline",children:"github.com/settings/personal-access-tokens"})]})]}),t.jsx(W,{})]})})]})}function ps(s){return s.command==="npx"}function hs(s){return s.args?.find(e=>!e.startsWith("-"))??""}function fs(s){return{command:s.command,args:s.args?.join(" ")??"",cwd:s.cwd??""}}function he(s,e){const n={title:s.title,description:s.description??"",icon:s.icon??null,configuration_state:s.configuration_state??{},configuration_scopes:s.configuration_scopes||[]};if(s.connection_type==="STDIO"&&Re(s.connection_headers)){const a=s.connection_headers,r=We(a.envVars);if(ps(a)){const i=hs(a);return{...n,ui_type:"NPX",connection_url:"",connection_token:null,npx_package:i,stdio_command:"",stdio_args:"",stdio_cwd:"",env_vars:r}}const o=fs(a);return{...n,ui_type:"STDIO",connection_url:"",connection_token:null,npx_package:"",stdio_command:o.command,stdio_args:o.args,stdio_cwd:o.cwd,env_vars:r}}return{...n,ui_type:s.connection_type,connection_url:s.connection_url??"",connection_token:null,npx_package:"",stdio_command:"",stdio_args:"",stdio_cwd:"",env_vars:[]}}function gs(s){let e,n=null,a=null,r=null;return s.ui_type==="NPX"?(e="STDIO",n="",r=Xe(s.npx_package||"",s.env_vars||[])):s.ui_type==="STDIO"?(e="STDIO",n="",r=qe(s.stdio_command||"",s.stdio_args||"",s.stdio_cwd,s.env_vars||[])):(e=s.ui_type,n=s.connection_url||"",a=s.connection_token||null),{title:s.title,description:s.description||null,icon:s.icon??null,connection_type:e,connection_url:n,...a&&{connection_token:a},...r&&{connection_headers:r},configuration_state:s.configuration_state??null,configuration_scopes:s.configuration_scopes??null}}function js({connection:s,connectionId:e,org:n,isUpdating:a,tools:r,prompts:o,resources:i,siblings:c}){const l=Y({from:"/$org/settings/connections/$appSlug"}),u=Ve(),x=ye(),{org:p}=J(),d=jt({onSuccess:()=>{c.length<=1&&l({to:"/$org/settings/connections",params:{org:n}})}}),[f,g]=G.useState(null),[v,b]=G.useState(!1),j=be({connectionId:e}),{data:N}=Ye(),T=N?.data?.members??[],S=f??s,y=T.find(m=>m.userId===S.created_by),_=s?.connection_type==="VIRTUAL"||j.isAuthenticated,k={...s,tools:r},C=Ge(k,Wt),h=Ue({resolver:Fe(He),values:he(f??s)}),w=h.formState.isDirty,z=async()=>{if(!await h.trigger())return;const D=h.getValues(),$=gs(D),F=f?.id??e;await x.update.mutateAsync({id:F,data:$}),h.reset(D)},O=()=>{h.reset(he(f??s))},A=async m=>{const{token:D,tokenInfo:$,error:F}=await ot({connectionId:m,orgSlug:p.slug,scope:"offline_access"});if(F||!D){q.error(`Authentication failed: ${F}`);return}if($)try{const K=await fetch(`/api/${p.slug}/connections/${m}/oauth-token`,{method:"POST",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({accessToken:$.accessToken,refreshToken:$.refreshToken,expiresIn:$.expiresIn,scope:$.scope,clientId:$.clientId,clientSecret:$.clientSecret,tokenEndpoint:$.tokenEndpoint})});if(!K.ok)console.error("Failed to save OAuth token:",await K.text()),await x.update.mutateAsync({id:m,data:{connection_token:D}});else try{await x.update.mutateAsync({id:m,data:{}})}catch(Z){console.warn("Failed to refresh connection tools after OAuth:",Z)}}catch(K){console.error("Error saving OAuth token:",K),await x.update.mutateAsync({id:m,data:{connection_token:D}})}else await x.update.mutateAsync({id:m,data:{connection_token:D}});const Q=new URL(`/api/${p.slug}/mcp/${m}`,window.location.origin);await u.invalidateQueries({queryKey:ne.isMCPAuthenticated(Q.href,null)}),await u.invalidateQueries({queryKey:ne.mcpClientPrefix()}),q.success("Authentication successful")},M=()=>A(s.id),U=async()=>{try{const m=await fetch(`/api/${p.slug}/connections/${s.id}/oauth-token`,{method:"DELETE",credentials:"include"});if(!m.ok){const $=await m.text();q.error(`Failed to remove OAuth: ${$}`);return}const D=new URL(`/api/${p.slug}/mcp/${s.id}`,window.location.origin);await u.invalidateQueries({queryKey:ne.isMCPAuthenticated(D.href,null)}),q.success("OAuth removed. You can now re-authenticate with a different account.")}catch(m){console.error("Error removing OAuth token:",m),q.error("Failed to remove OAuth")}};return t.jsxs(t.Fragment,{children:[t.jsx(vt,{...d}),t.jsx(mt,{open:f!==null,onOpenChange:m=>{m||g(null)},children:t.jsxs(ut,{side:"right",className:"sm:max-w-[520px] p-0 flex flex-col gap-0 overflow-hidden",children:[t.jsxs(xt,{className:"px-4 py-3 md:px-6 md:py-4 border-b border-border shrink-0",children:[t.jsx(pt,{className:"text-base",children:f?.title??s.title}),t.jsx(ht,{className:"text-xs",children:"Update URL, authentication, and other settings"}),y&&t.jsxs("div",{className:"flex items-center gap-1.5 pt-1",children:[t.jsx("span",{className:"text-xs text-muted-foreground",children:"Connected by"}),t.jsx(Ze,{url:y.user?.image??void 0,fallback:y.user?.name??y.user?.email??"?",size:"3xs",shape:"circle"}),t.jsx("span",{className:"text-xs font-medium text-foreground",children:y.user?.name||y.user?.email})]})]}),t.jsxs(gt,{...h,children:[t.jsxs("div",{className:"flex-1 overflow-y-auto px-4 py-3 md:px-6 md:py-5 flex flex-col gap-4 md:gap-6",children:[t.jsxs("div",{className:"flex flex-col gap-3 md:gap-4",children:[t.jsx(L,{control:h.control,name:"title",render:({field:m})=>t.jsxs(B,{children:[t.jsx(H,{children:"Name"}),t.jsx(E,{children:t.jsx(X,{...m})}),t.jsx(W,{})]})}),t.jsx(L,{control:h.control,name:"description",render:({field:m})=>t.jsxs(B,{children:[t.jsx(H,{children:"Description"}),t.jsx(E,{children:t.jsx(X,{...m,value:m.value||""})}),t.jsx(W,{})]})})]}),t.jsx(xs,{form:h,connection:f??s,hasOAuthToken:j.hasOAuthToken,onReauthenticate:M,onRemoveOAuth:U}),t.jsx(Ke,{connection:f??s,form:h,hasMcpBinding:C,isMCPAuthenticated:_,supportsOAuth:j.supportsOAuth,isServerError:j.isServerError,onAuthenticate:M,onViewReadme:void 0})]}),t.jsxs("div",{className:"px-6 py-4 border-t border-border flex gap-2 shrink-0",children:[t.jsx(V,{onClick:z,disabled:!w||a,className:"flex-1",children:a?"Saving…":"Save changes"}),w&&t.jsx(V,{variant:"outline",onClick:O,children:"Undo"}),t.jsxs(V,{variant:"outline",className:"gap-2 text-muted-foreground hover:text-destructive hover:border-destructive",onClick:()=>{const m=f??s;g(null),d.requestDelete(m)},children:[t.jsx(ae,{size:15}),"Delete"]})]})]},f?.id??s.id)]})}),t.jsx(Qe,{hideHeader:!0,children:t.jsxs("div",{className:"flex flex-col h-full overflow-hidden",children:[t.jsx(us,{connection:s,displayTitle:(()=>{const m=c[0]??s;return m.app_name?m.title.replace(/\s*\(\d+\)\s*$/,""):m.title})()}),t.jsx("div",{className:"flex-1 overflow-auto @container",children:t.jsxs("div",{className:"grid grid-cols-1 @3xl:grid-cols-2 gap-5 p-6",children:[t.jsx(ss,{connectionId:e}),t.jsxs("div",{className:"flex flex-col gap-5",children:[t.jsx(Gt,{instances:c,onConfigure:m=>g(m),onAuthenticate:m=>A(m.id),onDelete:m=>d.requestDelete(m),onToggleStatus:async(m,D)=>{try{await x.update.mutateAsync({id:m.id,data:{status:D}}),q.success(D==="active"?"Connection enabled":"Connection disabled")}catch{q.error("Failed to update connection")}},isAdding:v,onAdd:async()=>{b(!0);try{const m=c[0]??s,D=m.title.replace(/\s*\(\d+\)\s*$/,""),$=c.length+1,F=`${D} (${$})`,Q=Le("conn");await x.create.mutateAsync({id:Q,title:F,description:m.description??null,connection_type:m.connection_type,connection_url:m.connection_url??null,connection_token:null,created_at:new Date().toISOString(),updated_at:new Date().toISOString(),created_by:m.created_by,organization_id:m.organization_id,icon:m.icon??null,app_name:m.app_name??null,app_id:m.app_id??null,connection_headers:m.connection_headers??null,oauth_config:null,configuration_state:m.configuration_state??null,metadata:null,tools:null,bindings:null,status:"inactive"});const K=new URL(`/api/${p.slug}/mcp/${Q}`,window.location.origin),Z=await nt({url:K.href,token:null,orgId:p.id});Z.supportsOAuth&&!Z.isAuthenticated&&await A(Q)}finally{b(!1)}}}),t.jsx(is,{connection:s})]}),t.jsx("div",{className:"@3xl:col-span-2",children:t.jsx(ls,{tools:r,prompts:o,resources:i,connectionId:e,org:n})})]})})]})})]})}function vs(){const s=P.c(39);let e;s[0]===Symbol.for("react.memo_cache_sentinel")?(e={from:"/$org/settings/connections/$appSlug"},s[0]=e):e=s[0];const n=Y(e);let a;s[1]===Symbol.for("react.memo_cache_sentinel")?(a={from:"/shell/$org/settings/connections/$appSlug"},s[1]=a):a=s[1];const{appSlug:r,org:o}=Me(a),{org:i}=J(),c=ye();let l;s[2]!==r?(l={slug:r},s[2]=r,s[3]=l):l=s[3];const u=et(l),x=u[0]??null,p=x?.id??"",d=p||null;let f;s[4]!==i.id||s[5]!==i.slug||s[6]!==d?(f={connectionId:d,orgId:i.id,orgSlug:i.slug},s[4]=i.id,s[5]=i.slug,s[6]=d,s[7]=f):f=s[7];const g=_e(f);let v;s[8]!==g?(v={client:g},s[8]=g,s[9]=v):v=s[9];const{data:b}=tt(v);let j;if(s[10]!==x?.tools||s[11]!==p||s[12]!==u||s[13]!==b){const A=b?b.tools.map(Ss):(x?.tools??[]).map(Cs);e:{if(u.length<=1){j=A;break e}const M=new Set,U=[],m=ys;for(const D of u){const $=D.id===p?A:m(D.tools);for(const F of $)M.has(F.name)||(M.add(F.name),U.push(F))}j=U.length>0?U:A}s[10]=x?.tools,s[11]=p,s[12]=u,s[13]=b,s[14]=j}else j=s[14];const N=j;let T;s[15]!==g?(T={client:g},s[15]=g,s[16]=T):T=s[16];const{data:S}=st(T);let y;s[17]!==g?(y={client:g},s[17]=g,s[18]=y):y=s[18];const{data:I}=Ee(y);let _;s[19]!==S?.prompts?(_=S?.prompts??[],s[19]=S?.prompts,s[20]=_):_=s[20];let k;s[21]!==_?(k=_.map(Ns),s[21]=_,s[22]=k):k=s[22];const C=k;let h;s[23]!==I?.resources?(h=I?.resources??[],s[23]=I?.resources,s[24]=h):h=s[24];let w;s[25]!==h?(w=h.map(bs),s[25]=h,s[26]=w):w=s[26];const z=w;if(!x){let A;return s[27]!==n||s[28]!==o?(A=t.jsx("div",{className:"flex h-full w-full bg-background",children:t.jsx(ve,{title:"Connection not found",description:"This connection may have been deleted or you may not have access.",actions:t.jsx(V,{variant:"outline",onClick:()=>n({to:"/$org/settings/connections",params:{org:o}}),children:"Back to connections"})})}),s[27]=n,s[28]=o,s[29]=A):A=s[29],A}let O;return s[30]!==c.update.isPending||s[31]!==N||s[32]!==x||s[33]!==p||s[34]!==o||s[35]!==C||s[36]!==z||s[37]!==u?(O=t.jsx(js,{org:o,connection:x,connectionId:p,isUpdating:c.update.isPending,tools:N,prompts:C,resources:z,siblings:u}),s[30]=c.update.isPending,s[31]=N,s[32]=x,s[33]=p,s[34]=o,s[35]=C,s[36]=z,s[37]=u,s[38]=O):O=s[38],O}function bs(s){return{name:s.name,description:s.description,uri:s.uri}}function Ns(s){return{name:s.name,description:s.description}}function ys(s){return(s??[]).map(_s)}function _s(s){return{name:s.name,description:s.description,inputSchema:s.inputSchema??{},outputSchema:s.outputSchema,annotations:s.annotations,_meta:s._meta}}function Cs(s){return{name:s.name,description:s.description,inputSchema:s.inputSchema,outputSchema:s.outputSchema,annotations:s.annotations,_meta:s._meta}}function Ss(s){return{name:s.name,description:s.description,inputSchema:s.inputSchema,outputSchema:s.outputSchema,annotations:s.annotations,_meta:s._meta}}function ws(){const s=P.c(1);let e;return s[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx(ze,{children:t.jsx(G.Suspense,{fallback:t.jsx("div",{className:"flex h-full items-center justify-center bg-background",children:t.jsx(ge,{size:32,className:"animate-spin text-muted-foreground"})}),children:t.jsx(vs,{})})}),s[0]=e):e=s[0],e}function ro(){const s=P.c(1);let e;return s[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx(ws,{}),s[0]=e):e=s[0],e}export{ro as default};