decocms 4.319.6 → 4.319.8

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 (248) hide show
  1. package/dist/client/assets/{AlertCircle-DPUOoh5j.js → AlertCircle-f4nnpTTg.js} +1 -1
  2. package/dist/client/assets/{AreaChart-CR1kK7Z6.js → AreaChart-8HavjRhs.js} +1 -1
  3. package/dist/client/assets/{ArrowLeft-BUTpr7Zk.js → ArrowLeft-DeVXQ_Zc.js} +1 -1
  4. package/dist/client/assets/{ArrowUp-CORHojmg.js → ArrowUp-HzO4dq_k.js} +1 -1
  5. package/dist/client/assets/{Check-CZ_g5EHO.js → Check-DzHuFHoL.js} +1 -1
  6. package/dist/client/assets/{CheckCircle-B_Jj98KC.js → CheckCircle-tNccGo23.js} +1 -1
  7. package/dist/client/assets/{ChevronDown-Bt6RPgee.js → ChevronDown-s4Re3J16.js} +1 -1
  8. package/dist/client/assets/{ChevronRight-CNbZXCEK.js → ChevronRight-DtOnXnjv.js} +1 -1
  9. package/dist/client/assets/{ChevronSelectorVertical-8rrSZwTz.js → ChevronSelectorVertical-CwgLFWq0.js} +1 -1
  10. package/dist/client/assets/{ChevronUp-DkUmlK9q.js → ChevronUp-Xpnsttw1.js} +1 -1
  11. package/dist/client/assets/{Copy01-HfyvilSG.js → Copy01-BRPiRRUQ.js} +1 -1
  12. package/dist/client/assets/{CreditCard01-BpsRcf0P.js → CreditCard01-D7nD4MoT.js} +1 -1
  13. package/dist/client/assets/{DotsVertical-Cvjwtvf0.js → DotsVertical-BVchZPc_.js} +1 -1
  14. package/dist/client/assets/{Download01-BDdx-x6g.js → Download01-C8Yiywz6.js} +1 -1
  15. package/dist/client/assets/{ErrorBarContext-Bqlq569z.js → ErrorBarContext-Bhb5Qpt4.js} +1 -1
  16. package/dist/client/assets/{Eye-DsnJ6Hdj.js → Eye-WB67QJ1C.js} +1 -1
  17. package/dist/client/assets/{FilterLines-BUA3zaBV.js → FilterLines-pNRXDJ_z.js} +1 -1
  18. package/dist/client/assets/{GitBranch01-B2HQZMnv.js → GitBranch01-ByUdctAW.js} +1 -1
  19. package/dist/client/assets/{Globe01-Bi3FrG4r.js → Globe01-DXAw5CTM.js} +1 -1
  20. package/dist/client/assets/{Globe04-R1k9PcJw.js → Globe04-Cjk5Mw2y.js} +1 -1
  21. package/dist/client/assets/{HardDrive-Ckf8POt4.js → HardDrive-BTi8s38H.js} +1 -1
  22. package/dist/client/assets/{Image01-CdSDKzEr.js → Image01-fT4xR6P_.js} +1 -1
  23. package/dist/client/assets/{Key01-vZqkEk7C.js → Key01-CHTC8hwE.js} +1 -1
  24. package/dist/client/assets/{LinkExternal01-CvJ65RHZ.js → LinkExternal01-kAtb5ILy.js} +1 -1
  25. package/dist/client/assets/{LockUnlocked01-6p9kTpAw.js → LockUnlocked01-C4X5qfRd.js} +1 -1
  26. package/dist/client/assets/{LogOut01-BKqqcMKc.js → LogOut01-BkpjlgBP.js} +1 -1
  27. package/dist/client/assets/{Monitor01-CB7YoX25.js → Monitor01-Dhk7PXVV.js} +1 -1
  28. package/dist/client/assets/{Package-Bnouug7j.js → Package-CHpW5VM0.js} +1 -1
  29. package/dist/client/assets/{Palette-CCm7KdHj.js → Palette-BYFK4FA5.js} +1 -1
  30. package/dist/client/assets/{Play-D7lbeUou.js → Play-CZP4IMzd.js} +1 -1
  31. package/dist/client/assets/{Plus-N25KFjkP.js → Plus-CYNImaOJ.js} +1 -1
  32. package/dist/client/assets/{SearchLg-CHXkkIcP.js → SearchLg-8uAbG9P4.js} +1 -1
  33. package/dist/client/assets/{SearchMd-BVz5rgMO.js → SearchMd-bD349BM3.js} +1 -1
  34. package/dist/client/assets/{Sector-D9JRVcKv.js → Sector-tGY4Py8B.js} +1 -1
  35. package/dist/client/assets/{Settings02-JGeGuLpa.js → Settings02-CfL_uUCf.js} +1 -1
  36. package/dist/client/assets/{Share07-BaE_VewM.js → Share07-CPaO5Jno.js} +1 -1
  37. package/dist/client/assets/{Shield01-D_0zBkw-.js → Shield01-Y6gzbv7o.js} +1 -1
  38. package/dist/client/assets/{Stars01-Bm9KpsQB.js → Stars01-_AATW4G8.js} +1 -1
  39. package/dist/client/assets/{Stars02-BSN_fShX.js → Stars02-CqIkzwRk.js} +1 -1
  40. package/dist/client/assets/{Sun-CTLZrmxP.js → Sun-CwIE4PFj.js} +1 -1
  41. package/dist/client/assets/{SwitchHorizontal01-CU4u2Mx3.js → SwitchHorizontal01-BJLtWFX5.js} +1 -1
  42. package/dist/client/assets/{Tool01-6i_1iF0I.js → Tool01-hZtg6GbK.js} +1 -1
  43. package/dist/client/assets/{Tool02-CdWdC_dA.js → Tool02-DiIiNPwu.js} +1 -1
  44. package/dist/client/assets/{Trash01-DeEhE87T.js → Trash01-Bji2bWWh.js} +1 -1
  45. package/dist/client/assets/{TrendUp01-HQV90qh_.js → TrendUp01-Y6CIxEGk.js} +1 -1
  46. package/dist/client/assets/{Upload01-a-uHONMh.js → Upload01-CYRB-7yG.js} +1 -1
  47. package/dist/client/assets/{User01-BzW7liSD.js → User01-xX8OC8Hl.js} +1 -1
  48. package/dist/client/assets/{UserSquare-BIJUhRq9.js → UserSquare-B8RaUikS.js} +1 -1
  49. package/dist/client/assets/{Users01-DHt_zj2k.js → Users01-x11CoUFz.js} +1 -1
  50. package/dist/client/assets/{Users03-B7JMwHdE.js → Users03-Bg19q-V-.js} +1 -1
  51. package/dist/client/assets/{XCircle-DGpjgsOa.js → XCircle-YqRo5mD9.js} +1 -1
  52. package/dist/client/assets/{XClose-CcgBecn5.js → XClose-DyyJkORZ.js} +1 -1
  53. package/dist/client/assets/{YAxis-DHEFEMNz.js → YAxis-DVHrIG29.js} +1 -1
  54. package/dist/client/assets/{Zap-phia53Nn.js → Zap-DBnrIpUC.js} +1 -1
  55. package/dist/client/assets/{ZapSquare-C-dg-H1S.js → ZapSquare-tVtrCpPj.js} +1 -1
  56. package/dist/client/assets/{ZoomOut-B0fwcMBQ.js → ZoomOut-CVtN6QQg.js} +1 -1
  57. package/dist/client/assets/{access-gate-C2CuQeuA.js → access-gate-EoGcByM_.js} +1 -1
  58. package/dist/client/assets/{agent-icon-DBchm6Nb.js → agent-icon-DXnqgUdn.js} +1 -1
  59. package/dist/client/assets/agents-list-CjROH5af.js +1 -0
  60. package/dist/client/assets/{ai-providers-CwzG1Suk.js → ai-providers-B9LmqS60.js} +1 -1
  61. package/dist/client/assets/{alert-q_9y674t.js → alert-B5gYqXvO.js} +1 -1
  62. package/dist/client/assets/{alert-dialog-sgAetjem.js → alert-dialog-C1vr7a0B.js} +1 -1
  63. package/dist/client/assets/{analytics-tab-B3DNh-qY.js → analytics-tab-Dxb2aOcG.js} +1 -1
  64. package/dist/client/assets/{api-keys-B89ICCUP.js → api-keys-BVShXcJP.js} +1 -1
  65. package/dist/client/assets/{app-editor-fuCtyplA.js → app-editor-DqQdEHcH.js} +1 -1
  66. package/dist/client/assets/{auth-C0jQaNGd.js → auth-DXJPvHb_.js} +1 -1
  67. package/dist/client/assets/{auth-catchall-BuJcfhXs.js → auth-catchall-By1cz0Yu.js} +1 -1
  68. package/dist/client/assets/{auth-entry-O5b5_3Z2.js → auth-entry-B88UFhdg.js} +1 -1
  69. package/dist/client/assets/{auth-split-layout-CivnsjUE.js → auth-split-layout-Ub6OTBhx.js} +1 -1
  70. package/dist/client/assets/{authenticate-and-persist-oauth-B_ddEMoN.js → authenticate-and-persist-oauth-B322JeMG.js} +1 -1
  71. package/dist/client/assets/{automation-list-row-CGDHAky9.js → automation-list-row-l6-XvZu6.js} +1 -1
  72. package/dist/client/assets/{automation-runs-D6YBL96p.js → automation-runs-BwFV9_XZ.js} +1 -1
  73. package/dist/client/assets/{automations-CPRNSbP-.js → automations-DBKn4Q8k.js} +1 -1
  74. package/dist/client/assets/{avatar-DLQUtbSd.js → avatar-CpPlf24-.js} +1 -1
  75. package/dist/client/assets/{badge-CeB87lwb.js → badge-CFKeX0mn.js} +1 -1
  76. package/dist/client/assets/{block-document-Dpihi8bF.js → block-document-BL7oMI74.js} +1 -1
  77. package/dist/client/assets/{breadcrumb-KvM6LUMN.js → breadcrumb-QKUdhBOY.js} +1 -1
  78. package/dist/client/assets/{buckets-CtAQxsvY.js → buckets-DMVRQiOf.js} +1 -1
  79. package/dist/client/assets/{bulk-category-panel-Dxxw6gof.js → bulk-category-panel-B1qs1Dmy.js} +1 -1
  80. package/dist/client/assets/{capability-load-error-BEFZl7BI.js → capability-load-error-RVzxs7io.js} +1 -1
  81. package/dist/client/assets/{cards-DcMbn2wM.js → cards-BKe88FKP.js} +1 -1
  82. package/dist/client/assets/{category-editor-BqyKSX-k.js → category-editor-CacTrWLl.js} +1 -1
  83. package/dist/client/assets/{cdn-tab-CS6BQAKM.js → cdn-tab-Cy5BeFj-.js} +1 -1
  84. package/dist/client/assets/{chart-DikfTaxQ.js → chart-aqo9QCpr.js} +1 -1
  85. package/dist/client/assets/{chat-context-D7bBWEjV.js → chat-context-CgRJgEvq.js} +1 -1
  86. package/dist/client/assets/{checkbox-Bnn2cV2o.js → checkbox-BoivotQ-.js} +1 -1
  87. package/dist/client/assets/{choose-editor-CQKvK2nQ.js → choose-editor-QTv7--m3.js} +1 -1
  88. package/dist/client/assets/{cli-auth-success-C8fdvbK0.js → cli-auth-success-DTyiOyJd.js} +1 -1
  89. package/dist/client/assets/{collection-detail-BdZYqX07.js → collection-detail-NjFsNfcb.js} +1 -1
  90. package/dist/client/assets/{collection-display-button-BGPacmRH.js → collection-display-button-IsQl2qfL.js} +1 -1
  91. package/dist/client/assets/{collection-search-Bx0fHGdP.js → collection-search-BLs0Fnfs.js} +1 -1
  92. package/dist/client/assets/{collection-table-wrapper-Bq9o79bg.js → collection-table-wrapper-fvU83bN6.js} +1 -1
  93. package/dist/client/assets/{collection-tabs-wE5AjIxo.js → collection-tabs-Ir5Tsafl.js} +1 -1
  94. package/dist/client/assets/{command-B-8IVgOi.js → command-B5mpvvDf.js} +1 -1
  95. package/dist/client/assets/{commerce-onboarding-DvfkGGaG.js → commerce-onboarding-CTAvWzNK.js} +1 -1
  96. package/dist/client/assets/{config-BWjWcdbt.js → config-lfQlN5yZ.js} +1 -1
  97. package/dist/client/assets/{connect-BQldyEIH.js → connect-BlZW6L0a.js} +1 -1
  98. package/dist/client/assets/{connection-card-BgP76mdh.js → connection-card-R6-YJNhI.js} +1 -1
  99. package/dist/client/assets/{connection-detail-HtDHEVye.js → connection-detail-Bp_SrWC0.js} +1 -1
  100. package/dist/client/assets/{connection-form-helpers-D3UyncMx.js → connection-form-helpers-CObw_4nL.js} +1 -1
  101. package/dist/client/assets/{connection-Bu6CKKHo.js → connection-rpamShLy.js} +1 -1
  102. package/dist/client/assets/{connections-BFDSHlg7.js → connections-BS5_DsBn.js} +1 -1
  103. package/dist/client/assets/{decopilot-sse-pool-BDmk3gDD.js → decopilot-sse-pool-POUs7TGl.js} +1 -1
  104. package/dist/client/assets/{dialog-Dxe79goo.js → dialog-pwZ4KzZ6.js} +1 -1
  105. package/dist/client/assets/{domain-settings-CVK0PWLe.js → domain-settings-NdGxfDzI.js} +1 -1
  106. package/dist/client/assets/{drawer-DkejdWwz.js → drawer-C-xsc5eG.js} +1 -1
  107. package/dist/client/assets/{dropdown-menu-PmWQu__b.js → dropdown-menu-C16L90Tz.js} +1 -1
  108. package/dist/client/assets/{e2e-tab-DK2VRmcC.js → e2e-tab-C2uDcahp.js} +1 -1
  109. package/dist/client/assets/{editor-CDDmFeb8.js → editor-BHb3kJQ5.js} +1 -1
  110. package/dist/client/assets/{empty-state-DR2MeWCG.js → empty-state-C64gXBQU.js} +1 -1
  111. package/dist/client/assets/{empty-state-C8ZR6dk7.js → empty-state-DvA7VyTt.js} +1 -1
  112. package/dist/client/assets/{extract-connection-data-BRKwNJ15.js → extract-connection-data-CqOTDUuA.js} +1 -1
  113. package/dist/client/assets/{file-explorer-BHOrF9oj.js → file-explorer-CWrCpfsa.js} +1 -1
  114. package/dist/client/assets/{file-type-icon-B8SUHUXO.js → file-type-icon-xQ7VVCet.js} +1 -1
  115. package/dist/client/assets/{folder-icon-C9fCzh0e.js → folder-icon-DpeG2vsd.js} +1 -1
  116. package/dist/client/assets/{form-BzA23Elj.js → form-ENCNwobk.js} +1 -1
  117. package/dist/client/assets/{general-CBxcqCBJ.js → general-DOGR2kAx.js} +1 -1
  118. package/dist/client/assets/{github-repo-picker-EtIcW9an.js → github-repo-picker-BO3njSCf.js} +1 -1
  119. package/dist/client/assets/{hooks-X3Ivo2M-.js → hooks-DamZm9Dl.js} +1 -1
  120. package/dist/client/assets/{hosting-tab-BHDCkQun.js → hosting-tab-DHOJ7E0g.js} +1 -1
  121. package/dist/client/assets/{index-h1j6ujxS.js → index-BHv8b4bS.js} +1 -1
  122. package/dist/client/assets/{index-CtC5YrQv.js → index-BxeEwMkO.js} +1 -1
  123. package/dist/client/assets/{index-lveCx5PF.js → index-CVEDX-YS.js} +1 -1
  124. package/dist/client/assets/{index-a8Dvpxdi.js → index-CwiVxNC1.js} +1 -1
  125. package/dist/client/assets/{index-qCYv4MSE.js → index-DZLUP-bk.js} +5 -5
  126. package/dist/client/assets/{index-zpp84knt.js → index-Dg38LHEr.js} +1 -1
  127. package/dist/client/assets/{index-BrERmW69.js → index-DqZsb0Td.js} +6 -6
  128. package/dist/client/assets/{index-CKLDhHOO.js → index-Nfz_WfAJ.js} +1 -1
  129. package/dist/client/assets/{index-D0d43HMh.js → index-TjmjDCyo.js} +1 -1
  130. package/dist/client/assets/{index-redirect-L0iJfhY6.js → index-redirect-CJJKpI9F.js} +1 -1
  131. package/dist/client/assets/{infra-billing-CPf4fFDu.js → infra-billing-DJPDSczQ.js} +1 -1
  132. package/dist/client/assets/{input-CRGKfmn6.js → input-Cvmwm8KN.js} +1 -1
  133. package/dist/client/assets/{integration-icon-DBnJJnhq.js → integration-icon-DwhAeNBu.js} +1 -1
  134. package/dist/client/assets/{invite-member-dialog-BkIQ0dOi.js → invite-member-dialog-CgJgzzFp.js} +1 -1
  135. package/dist/client/assets/{label-CfDXMhl5.js → label-DZWNE7Y7.js} +1 -1
  136. package/dist/client/assets/{layout-D40hZqBj.js → layout-SayPzP68.js} +1 -1
  137. package/dist/client/assets/{login-DdLYUzng.js → login-C_A381mF.js} +1 -1
  138. package/dist/client/assets/{markdown-B7Ud7SgT.js → markdown-C1ZA9C8N.js} +1 -1
  139. package/dist/client/assets/{mcp-oauth-CGEvYC-J.js → mcp-oauth-BfeN-QCK.js} +1 -1
  140. package/dist/client/assets/{members-CDTLn-5g.js → members-Dgq0PRrT.js} +1 -1
  141. package/dist/client/assets/{monaco-editor-DjnM7g3H.js → monaco-editor-BJGC8gh7.js} +1 -1
  142. package/dist/client/assets/{monitoring-stats-row-BtKlGcG4.js → monitoring-stats-row-DZOfJtdy.js} +1 -1
  143. package/dist/client/assets/{multi-select-B338vBF_.js → multi-select-KLejsge1.js} +1 -1
  144. package/dist/client/assets/{oauth-callback-ByOfijBR.js → oauth-callback-Czlma0i-.js} +1 -1
  145. package/dist/client/assets/{oauth-callback-ai-provider-z49HmhKn.js → oauth-callback-ai-provider-ZdrQnvUS.js} +1 -1
  146. package/dist/client/assets/{onboarding-D50GvWIA.js → onboarding-B5ZjDPzC.js} +1 -1
  147. package/dist/client/assets/{org-layout-Bx5e_xav.js → org-layout-CdHLlafN.js} +1 -1
  148. package/dist/client/assets/{organization-choice-5Z25dFY6.js → organization-choice-DOTxufBd.js} +1 -1
  149. package/dist/client/assets/{orgs-CQPbK1d5.js → orgs-Dge8GFI6.js} +1 -1
  150. package/dist/client/assets/{page-seo-form-CFn8hcfO.js → page-seo-form-AxX8GGlf.js} +1 -1
  151. package/dist/client/assets/{popover-BzE481wQ.js → popover-CGQv5zzi.js} +1 -1
  152. package/dist/client/assets/{post-calendar-CJX3Ko38.js → post-calendar-BKq3211e.js} +1 -1
  153. package/dist/client/assets/{post-editor-BdbDvb-c.js → post-editor-pVnpiqgd.js} +1 -1
  154. package/dist/client/assets/{primitives-DEmITI2J.js → primitives-CiTG7vqX.js} +1 -1
  155. package/dist/client/assets/{profile-BwXGqXR4.js → profile-Beo16CzY.js} +1 -1
  156. package/dist/client/assets/{project-app-view-CeNx1fBu.js → project-app-view-CCRiXSdc.js} +1 -1
  157. package/dist/client/assets/{prompts-uqhpOUAX.js → prompts-DkqB1QMP.js} +1 -1
  158. package/dist/client/assets/record-editor-B4GimSNa.js +1 -0
  159. package/dist/client/assets/{redirect-editor-7e7Upnyf.js → redirect-editor-DGmMBPF8.js} +1 -1
  160. package/dist/client/assets/registry-BsOqDmeP.js +2 -0
  161. package/dist/client/assets/{registry-layout-DbvX20ly.js → registry-layout-CzKQ-sVC.js} +1 -1
  162. package/dist/client/assets/{reports-CrQDejVs.js → reports-CFFIWbjE.js} +1 -1
  163. package/dist/client/assets/{require-capability-BoL6jDgL.js → require-capability-CCEb5Sqs.js} +1 -1
  164. package/dist/client/assets/{required-auth-layout-5tFVnd1H.js → required-auth-layout-BmpA_-kW.js} +1 -1
  165. package/dist/client/assets/{reset-password-CS2Clij0.js → reset-password-CnsdaXsq.js} +1 -1
  166. package/dist/client/assets/{review-settings-DBmL8p2f.js → review-settings-gifV-niU.js} +1 -1
  167. package/dist/client/assets/{roles-D-X3mh9v.js → roles-CcQAq0Yr.js} +1 -1
  168. package/dist/client/assets/{schema-CYc80BIA.js → schema-B2Qlbge8.js} +1 -1
  169. package/dist/client/assets/{scroll-area-r1EYMKyQ.js → scroll-area-D1Ypr2e7.js} +1 -1
  170. package/dist/client/assets/{search-input-DXwr2899.js → search-input-CXMFw9Ub.js} +1 -1
  171. package/dist/client/assets/{secrets-BTH_8gqg.js → secrets-BOs-6B5A.js} +1 -1
  172. package/dist/client/assets/{sections-editor-90Gsfmg3.js → sections-editor-D7y_-PRI.js} +1 -1
  173. package/dist/client/assets/{select-Bz_3bOJv.js → select-SMcDHH3S.js} +1 -1
  174. package/dist/client/assets/{select-model-DH9jNXmH.js → select-model-C4PjzdGN.js} +1 -1
  175. package/dist/client/assets/{self-tool-result-Do1470Ib.js → self-tool-result-DFm5BFLJ.js} +1 -1
  176. package/dist/client/assets/{seo-editor-BkneoKKW.js → seo-editor-SQz-vDBx.js} +1 -1
  177. package/dist/client/assets/{settings-layout-B7WDpOx1.js → settings-layout-DT1hD9Qc.js} +1 -1
  178. package/dist/client/assets/{shell-controls-DCdB5eeb.js → shell-controls-BtldDShr.js} +1 -1
  179. package/dist/client/assets/{shell-layout-CYtE1aPw.js → shell-layout-OPAbVfwZ.js} +1 -1
  180. package/dist/client/assets/{skill-preview-DzcAaN-A.js → skill-preview-CyY0OP_z.js} +1 -1
  181. package/dist/client/assets/{skills-DbUTk6nR.js → skills-DdosW6Bc.js} +1 -1
  182. package/dist/client/assets/{spinner-Bgc6NWQ-.js → spinner-BJLy3OGx.js} +1 -1
  183. package/dist/client/assets/{sso-C1XWFvNa.js → sso-D53JjpHs.js} +1 -1
  184. package/dist/client/assets/{store-C3zBFUp-.js → store-lWrTp8UV.js} +1 -1
  185. package/dist/client/assets/store-registry-CbRGhfLY.js +2 -0
  186. package/dist/client/assets/{super-agent-icon-CRICd5zg.js → super-agent-icon-Bnh5ToBT.js} +1 -1
  187. package/dist/client/assets/{switch-Cz4K9iDZ.js → switch-C2vAz9hZ.js} +1 -1
  188. package/dist/client/assets/{synced-repos-C8bY52Sw.js → synced-repos-BhphaVQf.js} +1 -1
  189. package/dist/client/assets/{table-BrzSAp6e.js → table-C2U6VD6y.js} +1 -1
  190. package/dist/client/assets/{tabs-CQbWfZhJ.js → tabs-B70ZS4po.js} +1 -1
  191. package/dist/client/assets/{task-board-DCFA9I7S.js → task-board-DTv9gW69.js} +1 -1
  192. package/dist/client/assets/{tasks-siQjbDLL.js → tasks-DaUPg9Cd.js} +1 -1
  193. package/dist/client/assets/{textarea-p2bYTUAA.js → textarea-DsyQQY8o.js} +1 -1
  194. package/dist/client/assets/{thread-route-oU2v4HPI.js → thread-route-C79eC_qQ.js} +1 -1
  195. package/dist/client/assets/{toggle-group-C3G6c63e.js → toggle-group-CcQrFwsS.js} +1 -1
  196. package/dist/client/assets/{toolbar-BcAFop8I.js → toolbar-DVLlKODz.js} +1 -1
  197. package/dist/client/assets/{track-CC514-8k.js → track-CmZ4JwHl.js} +1 -1
  198. package/dist/client/assets/{types-BHR6d6Y2.js → types-GWf0mG7M.js} +1 -1
  199. package/dist/client/assets/{use-ai-providers-DPQuwb-3.js → use-ai-providers-Dj1Pomhd.js} +1 -1
  200. package/dist/client/assets/{use-api-keys-Cf-PDuMg.js → use-api-keys-v7JpdoOm.js} +1 -1
  201. package/dist/client/assets/{use-automations-CopIAiD9.js → use-automations-CxTksTg3.js} +1 -1
  202. package/dist/client/assets/{use-autosave-Df4gSSDP.js → use-autosave-BafK4Rjr.js} +1 -1
  203. package/dist/client/assets/{use-connection-BQeSoolZ.js → use-connection-BBRJTBMy.js} +1 -1
  204. package/dist/client/assets/{use-copy-DrncLLue.js → use-copy-QEjXenkb.js} +1 -1
  205. package/dist/client/assets/{use-create-virtual-mcp-DMgncd5a.js → use-create-virtual-mcp-B0jM9fDO.js} +1 -1
  206. package/dist/client/assets/{use-debounced-autosave-B-XG1FGZ.js → use-debounced-autosave-CSzP1LMa.js} +1 -1
  207. package/dist/client/assets/{use-debounced-value-CKaVv7Ac.js → use-debounced-value-0YLkJ58n.js} +1 -1
  208. package/dist/client/assets/{use-decopilot-events-B6E_Hlcz.js → use-decopilot-events-DVLYFd8Z.js} +1 -1
  209. package/dist/client/assets/{use-delete-connection-CJhsy60O.js → use-delete-connection-D3A1ZRW7.js} +1 -1
  210. package/dist/client/assets/{use-deployment-admin-DK88CLg4.js → use-deployment-admin-DzmvX_1c.js} +1 -1
  211. package/dist/client/assets/{use-destination-route-DAn4XmeU.js → use-destination-route-CgRHxPyq.js} +1 -1
  212. package/dist/client/assets/{use-file-configs-D7AMfTRS.js → use-file-configs-BtJ9owXL.js} +1 -1
  213. package/dist/client/assets/{use-infinite-scroll-wJNeU_LL.js → use-infinite-scroll-D9F23MOw.js} +1 -1
  214. package/dist/client/assets/{use-join-requests-Dh08Nva7.js → use-join-requests-CNUbcIoH.js} +1 -1
  215. package/dist/client/assets/{use-mcp-auth-status-BejOvzkI.js → use-mcp-auth-status-yMNjE6Uo.js} +1 -1
  216. package/dist/client/assets/{use-mcp-client-BJ8Gl7bN.js → use-mcp-client-Qp-dz21o.js} +1 -1
  217. package/dist/client/assets/{use-mcp-tools-aQw0C0zY.js → use-mcp-tools-C7FgaBkX.js} +1 -1
  218. package/dist/client/assets/{use-members-DZ8N99iL.js → use-members-BcS-quMh.js} +1 -1
  219. package/dist/client/assets/{use-navigate-to-agent-ctVWYeGN.js → use-navigate-to-agent-B8yDMTez.js} +1 -1
  220. package/dist/client/assets/{use-org-auth-client-BD5pSTKO.js → use-org-auth-client-Dp0AX4Aj.js} +1 -1
  221. package/dist/client/assets/{use-org-repo-syncs-BQHddGlx.js → use-org-repo-syncs-Brd5lrfI.js} +1 -1
  222. package/dist/client/assets/{use-org-sso-B37D2h-E.js → use-org-sso-wZB9SHX9.js} +1 -1
  223. package/dist/client/assets/{use-organization-roles-C4CfyaNV.js → use-organization-roles-C0_74J_y.js} +1 -1
  224. package/dist/client/assets/use-organization-settings-DoHw0Vrb.js +1 -0
  225. package/dist/client/assets/{use-panel-navigate-DUpzUMxR.js → use-panel-navigate-C7_AOzBX.js} +1 -1
  226. package/dist/client/assets/{use-registry-connections-pPrzjL2h.js → use-registry-connections-CB_vMkV_.js} +1 -1
  227. package/dist/client/assets/{use-secrets-ByjQEBQi.js → use-secrets-DWR3VHSi.js} +1 -1
  228. package/dist/client/assets/{use-section-preview-base-CgD6NC5X.js → use-section-preview-base-CWBthmZQ.js} +1 -1
  229. package/dist/client/assets/{use-status-sounds-DMS0qCWX.js → use-status-sounds-B4wpz7Bv.js} +1 -1
  230. package/dist/client/assets/{use-tags-CkxCFmu3.js → use-tags-TtpBUHZv.js} +1 -1
  231. package/dist/client/assets/{use-view-mode-DVYPz9HN.js → use-view-mode-CqPRLkgX.js} +1 -1
  232. package/dist/client/assets/{use-virtual-mcp-B7PM027K.js → use-virtual-mcp-BcsPJqk4.js} +1 -1
  233. package/dist/client/assets/useInfiniteQuery-Mj7WnppJ.js +1 -0
  234. package/dist/client/assets/useSuspenseInfiniteQuery-dJDa9vJh.js +1 -0
  235. package/dist/client/assets/{users-n6tGhrCq.js → users-DR4kDqbe.js} +1 -1
  236. package/dist/client/assets/{variant-calendar-BOfhcURI.js → variant-calendar-Bie9J8Up.js} +1 -1
  237. package/dist/client/assets/{view-mode-toggle-CVCfOvmN.js → view-mode-toggle-uQZ5XhwA.js} +1 -1
  238. package/dist/client/index.html +1 -1
  239. package/dist/server/cli.js +591 -591
  240. package/dist/server/server.js +366 -366
  241. package/package.json +1 -1
  242. package/dist/client/assets/agents-list-CpKsJdN9.js +0 -1
  243. package/dist/client/assets/record-editor-DwspN490.js +0 -1
  244. package/dist/client/assets/registry-DZdIIHBt.js +0 -2
  245. package/dist/client/assets/store-registry-5KlYurHE.js +0 -2
  246. package/dist/client/assets/use-organization-settings-DFlCOddU.js +0 -1
  247. package/dist/client/assets/useInfiniteQuery-DsTrslqR.js +0 -1
  248. package/dist/client/assets/useSuspenseInfiniteQuery-m-DwhjRi.js +0 -1
@@ -1 +1 @@
1
- import{c as j,a5 as P,b as _,j as t,ae as D,af as J,ag as Q,c1 as U,c2 as V,C as X,f as Z,m as F,r as T,H as K,n as S,c3 as Y,U as z,W as C,X as w,_ as q,Z as O,L,q as N,a1 as ee,a2 as se,a7 as R,a as A,k as te,c4 as ne,O as ie}from"./index-qCYv4MSE.js";import{n as le,a as ae,b as oe,c as re}from"./ZapSquare-C-dg-H1S.js";import{t as ce,a as M}from"./Users03-B7JMwHdE.js";import{t as me}from"./ChevronDown-Bt6RPgee.js";import{i as de}from"./ChevronRight-CNbZXCEK.js";import{i as fe}from"./CreditCard01-BpsRcf0P.js";import{i as ge}from"./HardDrive-Ckf8POt4.js";import{i as ue}from"./Key01-vZqkEk7C.js";import{n as xe}from"./LinkExternal01-CvJ65RHZ.js";import{i as I}from"./LogOut01-BKqqcMKc.js";import{t as be}from"./Stars01-Bm9KpsQB.js";import{s as pe}from"./User01-BzW7liSD.js";import{i as he}from"./Zap-phia53Nn.js";import{u as je}from"./use-join-requests-Dh08Nva7.js";import{u as ve}from"./use-status-sounds-DMS0qCWX.js";import{a as k}from"./toolbar-BcAFop8I.js";import{S as ye,M as ke}from"./shell-controls-DCdB5eeb.js";import"./question-004-sINsf4GQ.js";import"./use-decopilot-events-B6E_Hlcz.js";import"./decopilot-sse-pool-BDmk3gDD.js";import"./task-board-DCFA9I7S.js";import"./schema-CYc80BIA.js";import"./backoff-CrEUbyZT.js";function G(){const e=j.c(8),s=_(),{capabilities:n,isPrivileged:i,loading:a,error:o}=U(),r=je().length,l=V();let f;return e[0]!==n||e[1]!==o||e[2]!==i||e[3]!==r||e[4]!==a||e[5]!==s||e[6]!==l?(f=[{key:"account",label:"",items:[{key:"profile",label:s("settings.nav.profile"),icon:t.jsx(pe,{size:14}),to:"/$org/settings/profile"}]},{key:"organization",label:s("settings.nav.organization"),items:[{key:"general",label:s("settings.nav.general"),icon:t.jsx(ce,{size:14}),to:"/$org/settings/general",requires:"org:manage"},{key:"billing",label:s("settings.nav.billing"),icon:t.jsx(fe,{size:14}),to:"/$org/settings/ai-providers",group:"billing"},{key:"connect",label:s("settings.nav.connect"),icon:t.jsx(xe,{size:14}),to:"/$org/settings/connect",group:"connect"},{key:"tasks",label:s("settings.nav.tasks"),icon:t.jsx(le,{size:14}),to:"/$org/settings/task-board",requires:"org:manage"}]},{key:"build",label:s("settings.nav.build"),items:[{key:"connections",label:s("settings.nav.connections"),icon:t.jsx(ae,{size:14}),to:"/$org/settings/connections"},{key:"agents",label:s("settings.nav.agents"),icon:t.jsx(M,{size:14}),to:"/$org/settings/agents"},{key:"automations",label:s("settings.nav.automations"),icon:t.jsx(he,{size:14}),to:"/$org/settings/automations",requires:"automations:manage"},{key:"skills",label:s("settings.nav.skills"),icon:t.jsx(be,{size:14}),to:"/$org/settings/skills"}]},{key:"manage",label:s("settings.nav.manage"),items:[{key:"monitor",label:s("settings.nav.monitor"),icon:t.jsx(oe,{size:14}),to:"/$org/settings/monitor",requires:"monitoring:view"},{key:"members",label:s("settings.nav.members"),icon:t.jsx(M,{size:14}),to:"/$org/settings/members",group:"members",badge:r}]},{key:"advanced",label:s("settings.nav.advanced"),collapsible:!0,items:[{key:"secrets",label:s("settings.nav.secrets"),icon:t.jsx(ue,{size:14}),to:"/$org/settings/secrets",requires:"secrets:manage"},{key:"storage",label:s("settings.nav.storage"),icon:t.jsx(ge,{size:14}),to:"/$org/settings/buckets",group:"storage"},{key:"store",label:s("settings.nav.store"),icon:t.jsx(re,{size:14}),to:"/$org/settings/store",requires:"registry:manage"},{key:"sso",label:s("settings.nav.security"),icon:t.jsx(X,{size:14}),to:"/$org/settings/sso",requires:"org:manage"}]}].map(d=>({...d,items:d.items.flatMap(c=>{if(c.group){const[g]=l[c.group];return g?[{...c,to:g.to}]:[]}return a||o?[c]:c.privilegedOnly?i?[c]:[]:c.requires?i||n[c.requires]?[c]:[]:[c]})})).filter(Se),e[0]=n,e[1]=o,e[2]=i,e[3]=r,e[4]=a,e[5]=s,e[6]=l,e[7]=f):f=e[7],f}function Se(e){return e.items.length>0}function E(e){const s=j.c(5),{icon:n,badge:i}=e;let a;s[0]!==i?(a=i?t.jsx("span",{className:"absolute -right-1 -top-1 size-2 rounded-full bg-destructive pointer-events-none"}):null,s[0]=i,s[1]=a):a=s[1];let o;return s[2]!==n||s[3]!==a?(o=t.jsxs("span",{className:"relative shrink-0",children:[n,a]}),s[2]=n,s[3]=a,s[4]=o):o=s[4],o}function $(){const e=j.c(8);let s;e[0]===Symbol.for("react.memo_cache_sentinel")?(s={from:"/shell/$org"},e[0]=s):s=e[0];const{org:n}=Z(s);let i;e[1]===Symbol.for("react.memo_cache_sentinel")?(i={select:_e},e[1]=i):i=e[1];const a=F(i);let o;if(e[2]!==n||e[3]!==a){const f=m=>{const d=m.replace("$org",n);return a===d||a.startsWith(`${d}/`)};o=m=>(m.group?Y(m.group):[m.to]).some(f),e[2]=n,e[3]=a,e[4]=o}else o=e[4];const r=o;let l;return e[5]!==r||e[6]!==n?(l={org:n,isActive:r},e[5]=r,e[6]=n,e[7]=l):l=e[7],l}function _e(e){return e.location.pathname}function H(){const e=j.c(9),{isActive:s}=$();let n;e[0]===Symbol.for("react.memo_cache_sentinel")?(n={},e[0]=n):n=e[0];const[i,a]=T.useState(n);let o;e[1]!==s||e[2]!==i?(o=d=>i[d.key]??(!d.collapsible||d.items.some(s)),e[1]=s,e[2]=i,e[3]=o):o=e[3];const r=o;let l;e[4]!==r?(l=d=>a(c=>({...c,[d.key]:!r(d)})),e[4]=r,e[5]=l):l=e[5];const f=l;let m;return e[6]!==r||e[7]!==f?(m={isOpen:r,toggle:f},e[6]=r,e[7]=f,e[8]=m):m=e[8],m}function B(e){const s=j.c(21),{group:n,open:i,onToggle:a,className:o}=e;let r,l,f,m,d;if(s[0]!==o||s[1]!==n.collapsible||s[2]!==n.label||s[3]!==a||s[4]!==i){d=Symbol.for("react.early_return_sentinel");e:{const b=S("text-xs font-medium text-muted-foreground/60 truncate",o);if(!n.collapsible){d=t.jsx("p",{className:b,children:n.label});break e}r="button",l=a,f=i,m=S("flex w-full items-center gap-1 rounded-md hover:text-muted-foreground",b)}s[0]=o,s[1]=n.collapsible,s[2]=n.label,s[3]=a,s[4]=i,s[5]=r,s[6]=l,s[7]=f,s[8]=m,s[9]=d}else r=s[5],l=s[6],f=s[7],m=s[8],d=s[9];if(d!==Symbol.for("react.early_return_sentinel"))return d;let c;s[10]!==i?(c=i?t.jsx(me,{size:12}):t.jsx(de,{size:12}),s[10]=i,s[11]=c):c=s[11];let g;s[12]!==n.label?(g=t.jsx("span",{className:"truncate",children:n.label}),s[12]=n.label,s[13]=g):g=s[13];let u;return s[14]!==r||s[15]!==l||s[16]!==f||s[17]!==m||s[18]!==c||s[19]!==g?(u=t.jsxs("button",{type:r,onClick:l,"aria-expanded":f,className:m,children:[c,g]}),s[14]=r,s[15]=l,s[16]=f,s[17]=m,s[18]=c,s[19]=g,s[20]=u):u=s[20],u}function Ne(){const e=j.c(23),s=_(),n=G(),{org:i,isActive:a}=$(),{isOpen:o,toggle:r}=H();let l;if(e[0]!==n||e[1]!==a||e[2]!==o||e[3]!==i||e[4]!==r){let h;e[6]!==a||e[7]!==o||e[8]!==i||e[9]!==r?(h=(p,v)=>t.jsxs(z,{className:"pt-0 pr-0 pb-0 pl-0",children:[p.label&&t.jsx(B,{group:p,open:o(p),onToggle:()=>r(p),className:S("px-2 pt-1.5 pb-0.5",v>0&&"mt-3")}),o(p)&&t.jsx(C,{children:t.jsx(w,{className:"gap-0.5",children:p.items.map(x=>t.jsx(q,{children:t.jsx(O,{asChild:!0,isActive:a(x),children:t.jsxs(L,{to:x.to,params:{org:i},onClick:()=>N("settings_nav_clicked",{section_key:x.key,group_key:p.key}),className:"flex items-center gap-2.5 text-sm",children:[t.jsx(E,{icon:x.icon,badge:x.badge}),t.jsx("span",{className:"truncate",children:x.label})]})})},x.key))})})]},p.key),e[6]=a,e[7]=o,e[8]=i,e[9]=r,e[10]=h):h=e[10],l=n.map(h),e[0]=n,e[1]=a,e[2]=o,e[3]=i,e[4]=r,e[5]=l}else l=e[5];let f;e[11]===Symbol.for("react.memo_cache_sentinel")?(f=t.jsx("div",{className:"mx-2 my-2 border-t border-border/50"}),e[11]=f):f=e[11];let m;e[12]===Symbol.for("react.memo_cache_sentinel")?(m=t.jsx("span",{className:"shrink-0",children:t.jsx(I,{size:14})}),e[12]=m):m=e[12];let d;e[13]!==s?(d=s("settings.nav.signOut"),e[13]=s,e[14]=d):d=e[14];let c;e[15]!==d?(c=t.jsxs(z,{className:"mt-auto pt-0 pr-0 pb-0 pl-0",children:[f,t.jsx(C,{children:t.jsx(w,{className:"gap-0.5",children:t.jsx(q,{children:t.jsxs(O,{onClick:$e,className:"flex items-center gap-2.5 text-sm",children:[m,t.jsx("span",{className:"truncate",children:d})]})})})})]}),e[15]=d,e[16]=c):c=e[16];let g;e[17]!==l||e[18]!==c?(g=t.jsxs(ee,{className:"flex flex-col flex-1 mt-2 px-2 pb-2 gap-0 overflow-y-auto",children:[l,c]}),e[17]=l,e[18]=c,e[19]=g):g=e[19];let u;e[20]===Symbol.for("react.memo_cache_sentinel")?(u=t.jsx("div",{className:"mt-auto px-4 pb-1",children:t.jsxs("span",{className:"text-xs text-muted-foreground/50",children:["v","4.319.6"]})}),e[20]=u):u=e[20];let b;return e[21]!==g?(b=t.jsxs(se,{variant:"sidebar",children:[g,u]}),e[21]=g,e[22]=b):b=e[22],b}function $e(){N("signed_out",{source:"settings_sidebar"}),R(),A.signOut()}function ze(e){const s=j.c(25),{onClose:n}=e,i=_(),a=G(),{org:o,isActive:r}=$(),{isOpen:l,toggle:f}=H();let m;if(s[0]!==a||s[1]!==r||s[2]!==l||s[3]!==n||s[4]!==o||s[5]!==f){let v;s[7]!==r||s[8]!==l||s[9]!==n||s[10]!==o||s[11]!==f?(v=(x,W)=>t.jsxs("div",{className:"flex flex-col gap-0.5",children:[x.label&&t.jsx(B,{group:x,open:l(x),onToggle:()=>f(x),className:S("px-3 pt-1.5 pb-0.5",W>0&&"mt-3")}),l(x)&&x.items.map(y=>t.jsxs(L,{to:y.to,params:{org:o},onClick:n,className:S("flex items-center gap-3 w-full px-3 py-2.5 rounded-lg transition-colors text-sm",r(y)?"bg-sidebar-accent text-sidebar-accent-foreground font-medium":"text-sidebar-foreground/70 hover:bg-sidebar-accent hover:text-sidebar-foreground"),children:[t.jsx(E,{icon:y.icon,badge:y.badge}),t.jsx("span",{className:"truncate",children:y.label})]},y.key))]},x.key),s[7]=r,s[8]=l,s[9]=n,s[10]=o,s[11]=f,s[12]=v):v=s[12],m=a.map(v),s[0]=a,s[1]=r,s[2]=l,s[3]=n,s[4]=o,s[5]=f,s[6]=m}else m=s[6];let d;s[13]===Symbol.for("react.memo_cache_sentinel")?(d=t.jsx("div",{className:"h-px bg-border/50 my-2"}),s[13]=d):d=s[13];let c;s[14]===Symbol.for("react.memo_cache_sentinel")?(c=t.jsx("span",{className:"shrink-0",children:t.jsx(I,{size:14})}),s[14]=c):c=s[14];let g;s[15]!==i?(g=i("settings.nav.signOut"),s[15]=i,s[16]=g):g=s[16];let u;s[17]!==g?(u=t.jsxs("div",{className:"mt-auto flex flex-col gap-0.5",children:[d,t.jsxs("button",{type:"button",onClick:Ce,className:"flex items-center gap-3 w-full px-3 py-2.5 rounded-lg transition-colors text-sm text-sidebar-foreground/70 hover:bg-sidebar-accent hover:text-sidebar-foreground",children:[c,t.jsx("span",{className:"truncate",children:g})]})]}),s[17]=g,s[18]=u):u=s[18];let b;s[19]!==m||s[20]!==u?(b=t.jsxs("div",{className:"flex flex-col flex-1 overflow-y-auto px-2 py-2 gap-0.5",children:[m,u]}),s[19]=m,s[20]=u,s[21]=b):b=s[21];let h;s[22]===Symbol.for("react.memo_cache_sentinel")?(h=t.jsx("div",{className:"px-4 pb-3 pt-1 border-t border-border/50",children:t.jsxs("span",{className:"text-xs text-muted-foreground/50",children:["v","4.319.6"]})}),s[22]=h):h=s[22];let p;return s[23]!==b?(p=t.jsxs("div",{className:"flex flex-col h-full bg-sidebar",children:[b,h]}),s[23]=b,s[24]=p):p=s[24],p}function Ce(){N("signed_out",{source:"settings_sidebar"}),R(),A.signOut()}function we(){const e=j.c(4),s=P(),{org:n}=K();ve(n.slug);let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=t.jsx("div",{className:"flex-1 flex items-center justify-center",children:t.jsx(te,{size:20,className:"animate-spin text-muted-foreground"})}),e[0]=i):i=e[0];let a;e[1]===Symbol.for("react.memo_cache_sentinel")?(a=t.jsx(T.Suspense,{fallback:i,children:t.jsx("div",{className:"flex flex-1 items-center overflow-hidden rounded-[inherit]",children:t.jsx(ne,{value:"p-0",children:t.jsx("div",{className:"flex-1 min-w-0 overflow-hidden h-full",children:t.jsx(ie,{})})})})}),e[1]=a):a=e[1];const o=a;if(s){let l;return e[2]===Symbol.for("react.memo_cache_sentinel")?(l=t.jsx("div",{className:"flex flex-col flex-1 bg-background min-h-0 overflow-hidden",children:o}),e[2]=l):l=e[2],l}let r;return e[3]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsx("div",{className:"flex-1 min-h-0 p-1",children:t.jsx("div",{className:S("flex flex-col h-full min-h-0 bg-background overflow-hidden","card-shadow","rounded-[0.75rem]"),children:o})}),e[3]=r):r=e[3],r}function es(){const e=j.c(21),s=P();let n;e[0]===Symbol.for("react.memo_cache_sentinel")?(n=t.jsx(k.LogoLink,{}),e[0]=n):n=e[0];let i;e[1]!==s?(i=s&&t.jsx(ye,{}),e[1]=s,e[2]=i):i=e[2];let a;e[3]!==i?(a=t.jsxs(k.LeftColumn,{children:[n,i]}),e[3]=i,e[4]=a):a=e[4];let o;e[5]===Symbol.for("react.memo_cache_sentinel")?(o=t.jsx(k.CenterSlot,{}),e[5]=o):o=e[5];let r;e[6]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsx(k.RightColumn,{children:t.jsx("span",{})}),e[6]=r):r=e[6];let l;e[7]!==a?(l=t.jsxs(k.Header,{children:[a,o,r]}),e[7]=a,e[8]=l):l=e[8];let f;e[9]===Symbol.for("react.memo_cache_sentinel")?(f={"--sidebar-width-icon":"3.125rem"},e[9]=f):f=e[9];let m;e[10]!==s?(m=!s&&t.jsx(Ne,{}),e[10]=s,e[11]=m):m=e[11];let d;e[12]===Symbol.for("react.memo_cache_sentinel")?(d=t.jsx(D,{className:"flex flex-col",style:{background:"transparent",containerType:"inline-size"},children:t.jsx(we,{})}),e[12]=d):d=e[12];let c;e[13]!==m?(c=t.jsxs(J,{className:"flex-1 bg-sidebar min-h-0",style:f,children:[m,d]}),e[13]=m,e[14]=c):c=e[14];let g;e[15]!==s?(g=s&&t.jsx(ke,{renderSidebar:qe}),e[15]=s,e[16]=g):g=e[16];let u;return e[17]!==g||e[18]!==l||e[19]!==c?(u=t.jsx(k.Provider,{children:t.jsx(Q,{defaultOpen:!0,children:t.jsxs("div",{className:"app-shell-root flex flex-col h-dvh overflow-hidden",children:[l,c,g]})})}),e[17]=g,e[18]=l,e[19]=c,e[20]=u):u=e[20],u}function qe(e){const{onClose:s}=e;return t.jsx(ze,{onClose:s})}export{Ne as SettingsSidebar,ze as SettingsSidebarMobile,es as default};
1
+ import{c as j,a5 as P,b as _,j as t,ae as D,af as J,ag as Q,c1 as U,c2 as V,C as X,f as Z,m as F,r as T,H as K,n as S,c3 as Y,U as z,W as C,X as w,_ as q,Z as O,L,q as N,a1 as ee,a2 as se,a7 as R,a as A,k as te,c4 as ne,O as ie}from"./index-DZLUP-bk.js";import{n as le,a as ae,b as oe,c as re}from"./ZapSquare-tVtrCpPj.js";import{t as ce,a as M}from"./Users03-Bg19q-V-.js";import{t as me}from"./ChevronDown-s4Re3J16.js";import{i as de}from"./ChevronRight-DtOnXnjv.js";import{i as fe}from"./CreditCard01-D7nD4MoT.js";import{i as ge}from"./HardDrive-BTi8s38H.js";import{i as ue}from"./Key01-CHTC8hwE.js";import{n as xe}from"./LinkExternal01-kAtb5ILy.js";import{i as I}from"./LogOut01-BkpjlgBP.js";import{t as be}from"./Stars01-_AATW4G8.js";import{s as pe}from"./User01-xX8OC8Hl.js";import{i as he}from"./Zap-DBnrIpUC.js";import{u as je}from"./use-join-requests-CNUbcIoH.js";import{u as ve}from"./use-status-sounds-B4wpz7Bv.js";import{a as k}from"./toolbar-DVLlKODz.js";import{S as ye,M as ke}from"./shell-controls-BtldDShr.js";import"./question-004-sINsf4GQ.js";import"./use-decopilot-events-DVLYFd8Z.js";import"./decopilot-sse-pool-POUs7TGl.js";import"./task-board-DTv9gW69.js";import"./schema-B2Qlbge8.js";import"./backoff-CrEUbyZT.js";function G(){const e=j.c(8),s=_(),{capabilities:n,isPrivileged:i,loading:a,error:o}=U(),r=je().length,l=V();let f;return e[0]!==n||e[1]!==o||e[2]!==i||e[3]!==r||e[4]!==a||e[5]!==s||e[6]!==l?(f=[{key:"account",label:"",items:[{key:"profile",label:s("settings.nav.profile"),icon:t.jsx(pe,{size:14}),to:"/$org/settings/profile"}]},{key:"organization",label:s("settings.nav.organization"),items:[{key:"general",label:s("settings.nav.general"),icon:t.jsx(ce,{size:14}),to:"/$org/settings/general",requires:"org:manage"},{key:"billing",label:s("settings.nav.billing"),icon:t.jsx(fe,{size:14}),to:"/$org/settings/ai-providers",group:"billing"},{key:"connect",label:s("settings.nav.connect"),icon:t.jsx(xe,{size:14}),to:"/$org/settings/connect",group:"connect"},{key:"tasks",label:s("settings.nav.tasks"),icon:t.jsx(le,{size:14}),to:"/$org/settings/task-board",requires:"org:manage"}]},{key:"build",label:s("settings.nav.build"),items:[{key:"connections",label:s("settings.nav.connections"),icon:t.jsx(ae,{size:14}),to:"/$org/settings/connections"},{key:"agents",label:s("settings.nav.agents"),icon:t.jsx(M,{size:14}),to:"/$org/settings/agents"},{key:"automations",label:s("settings.nav.automations"),icon:t.jsx(he,{size:14}),to:"/$org/settings/automations",requires:"automations:manage"},{key:"skills",label:s("settings.nav.skills"),icon:t.jsx(be,{size:14}),to:"/$org/settings/skills"}]},{key:"manage",label:s("settings.nav.manage"),items:[{key:"monitor",label:s("settings.nav.monitor"),icon:t.jsx(oe,{size:14}),to:"/$org/settings/monitor",requires:"monitoring:view"},{key:"members",label:s("settings.nav.members"),icon:t.jsx(M,{size:14}),to:"/$org/settings/members",group:"members",badge:r}]},{key:"advanced",label:s("settings.nav.advanced"),collapsible:!0,items:[{key:"secrets",label:s("settings.nav.secrets"),icon:t.jsx(ue,{size:14}),to:"/$org/settings/secrets",requires:"secrets:manage"},{key:"storage",label:s("settings.nav.storage"),icon:t.jsx(ge,{size:14}),to:"/$org/settings/buckets",group:"storage"},{key:"store",label:s("settings.nav.store"),icon:t.jsx(re,{size:14}),to:"/$org/settings/store",requires:"registry:manage"},{key:"sso",label:s("settings.nav.security"),icon:t.jsx(X,{size:14}),to:"/$org/settings/sso",requires:"org:manage"}]}].map(d=>({...d,items:d.items.flatMap(c=>{if(c.group){const[g]=l[c.group];return g?[{...c,to:g.to}]:[]}return a||o?[c]:c.privilegedOnly?i?[c]:[]:c.requires?i||n[c.requires]?[c]:[]:[c]})})).filter(Se),e[0]=n,e[1]=o,e[2]=i,e[3]=r,e[4]=a,e[5]=s,e[6]=l,e[7]=f):f=e[7],f}function Se(e){return e.items.length>0}function E(e){const s=j.c(5),{icon:n,badge:i}=e;let a;s[0]!==i?(a=i?t.jsx("span",{className:"absolute -right-1 -top-1 size-2 rounded-full bg-destructive pointer-events-none"}):null,s[0]=i,s[1]=a):a=s[1];let o;return s[2]!==n||s[3]!==a?(o=t.jsxs("span",{className:"relative shrink-0",children:[n,a]}),s[2]=n,s[3]=a,s[4]=o):o=s[4],o}function $(){const e=j.c(8);let s;e[0]===Symbol.for("react.memo_cache_sentinel")?(s={from:"/shell/$org"},e[0]=s):s=e[0];const{org:n}=Z(s);let i;e[1]===Symbol.for("react.memo_cache_sentinel")?(i={select:_e},e[1]=i):i=e[1];const a=F(i);let o;if(e[2]!==n||e[3]!==a){const f=m=>{const d=m.replace("$org",n);return a===d||a.startsWith(`${d}/`)};o=m=>(m.group?Y(m.group):[m.to]).some(f),e[2]=n,e[3]=a,e[4]=o}else o=e[4];const r=o;let l;return e[5]!==r||e[6]!==n?(l={org:n,isActive:r},e[5]=r,e[6]=n,e[7]=l):l=e[7],l}function _e(e){return e.location.pathname}function H(){const e=j.c(9),{isActive:s}=$();let n;e[0]===Symbol.for("react.memo_cache_sentinel")?(n={},e[0]=n):n=e[0];const[i,a]=T.useState(n);let o;e[1]!==s||e[2]!==i?(o=d=>i[d.key]??(!d.collapsible||d.items.some(s)),e[1]=s,e[2]=i,e[3]=o):o=e[3];const r=o;let l;e[4]!==r?(l=d=>a(c=>({...c,[d.key]:!r(d)})),e[4]=r,e[5]=l):l=e[5];const f=l;let m;return e[6]!==r||e[7]!==f?(m={isOpen:r,toggle:f},e[6]=r,e[7]=f,e[8]=m):m=e[8],m}function B(e){const s=j.c(21),{group:n,open:i,onToggle:a,className:o}=e;let r,l,f,m,d;if(s[0]!==o||s[1]!==n.collapsible||s[2]!==n.label||s[3]!==a||s[4]!==i){d=Symbol.for("react.early_return_sentinel");e:{const b=S("text-xs font-medium text-muted-foreground/60 truncate",o);if(!n.collapsible){d=t.jsx("p",{className:b,children:n.label});break e}r="button",l=a,f=i,m=S("flex w-full items-center gap-1 rounded-md hover:text-muted-foreground",b)}s[0]=o,s[1]=n.collapsible,s[2]=n.label,s[3]=a,s[4]=i,s[5]=r,s[6]=l,s[7]=f,s[8]=m,s[9]=d}else r=s[5],l=s[6],f=s[7],m=s[8],d=s[9];if(d!==Symbol.for("react.early_return_sentinel"))return d;let c;s[10]!==i?(c=i?t.jsx(me,{size:12}):t.jsx(de,{size:12}),s[10]=i,s[11]=c):c=s[11];let g;s[12]!==n.label?(g=t.jsx("span",{className:"truncate",children:n.label}),s[12]=n.label,s[13]=g):g=s[13];let u;return s[14]!==r||s[15]!==l||s[16]!==f||s[17]!==m||s[18]!==c||s[19]!==g?(u=t.jsxs("button",{type:r,onClick:l,"aria-expanded":f,className:m,children:[c,g]}),s[14]=r,s[15]=l,s[16]=f,s[17]=m,s[18]=c,s[19]=g,s[20]=u):u=s[20],u}function Ne(){const e=j.c(23),s=_(),n=G(),{org:i,isActive:a}=$(),{isOpen:o,toggle:r}=H();let l;if(e[0]!==n||e[1]!==a||e[2]!==o||e[3]!==i||e[4]!==r){let h;e[6]!==a||e[7]!==o||e[8]!==i||e[9]!==r?(h=(p,v)=>t.jsxs(z,{className:"pt-0 pr-0 pb-0 pl-0",children:[p.label&&t.jsx(B,{group:p,open:o(p),onToggle:()=>r(p),className:S("px-2 pt-1.5 pb-0.5",v>0&&"mt-3")}),o(p)&&t.jsx(C,{children:t.jsx(w,{className:"gap-0.5",children:p.items.map(x=>t.jsx(q,{children:t.jsx(O,{asChild:!0,isActive:a(x),children:t.jsxs(L,{to:x.to,params:{org:i},onClick:()=>N("settings_nav_clicked",{section_key:x.key,group_key:p.key}),className:"flex items-center gap-2.5 text-sm",children:[t.jsx(E,{icon:x.icon,badge:x.badge}),t.jsx("span",{className:"truncate",children:x.label})]})})},x.key))})})]},p.key),e[6]=a,e[7]=o,e[8]=i,e[9]=r,e[10]=h):h=e[10],l=n.map(h),e[0]=n,e[1]=a,e[2]=o,e[3]=i,e[4]=r,e[5]=l}else l=e[5];let f;e[11]===Symbol.for("react.memo_cache_sentinel")?(f=t.jsx("div",{className:"mx-2 my-2 border-t border-border/50"}),e[11]=f):f=e[11];let m;e[12]===Symbol.for("react.memo_cache_sentinel")?(m=t.jsx("span",{className:"shrink-0",children:t.jsx(I,{size:14})}),e[12]=m):m=e[12];let d;e[13]!==s?(d=s("settings.nav.signOut"),e[13]=s,e[14]=d):d=e[14];let c;e[15]!==d?(c=t.jsxs(z,{className:"mt-auto pt-0 pr-0 pb-0 pl-0",children:[f,t.jsx(C,{children:t.jsx(w,{className:"gap-0.5",children:t.jsx(q,{children:t.jsxs(O,{onClick:$e,className:"flex items-center gap-2.5 text-sm",children:[m,t.jsx("span",{className:"truncate",children:d})]})})})})]}),e[15]=d,e[16]=c):c=e[16];let g;e[17]!==l||e[18]!==c?(g=t.jsxs(ee,{className:"flex flex-col flex-1 mt-2 px-2 pb-2 gap-0 overflow-y-auto",children:[l,c]}),e[17]=l,e[18]=c,e[19]=g):g=e[19];let u;e[20]===Symbol.for("react.memo_cache_sentinel")?(u=t.jsx("div",{className:"mt-auto px-4 pb-1",children:t.jsxs("span",{className:"text-xs text-muted-foreground/50",children:["v","4.319.8"]})}),e[20]=u):u=e[20];let b;return e[21]!==g?(b=t.jsxs(se,{variant:"sidebar",children:[g,u]}),e[21]=g,e[22]=b):b=e[22],b}function $e(){N("signed_out",{source:"settings_sidebar"}),R(),A.signOut()}function ze(e){const s=j.c(25),{onClose:n}=e,i=_(),a=G(),{org:o,isActive:r}=$(),{isOpen:l,toggle:f}=H();let m;if(s[0]!==a||s[1]!==r||s[2]!==l||s[3]!==n||s[4]!==o||s[5]!==f){let v;s[7]!==r||s[8]!==l||s[9]!==n||s[10]!==o||s[11]!==f?(v=(x,W)=>t.jsxs("div",{className:"flex flex-col gap-0.5",children:[x.label&&t.jsx(B,{group:x,open:l(x),onToggle:()=>f(x),className:S("px-3 pt-1.5 pb-0.5",W>0&&"mt-3")}),l(x)&&x.items.map(y=>t.jsxs(L,{to:y.to,params:{org:o},onClick:n,className:S("flex items-center gap-3 w-full px-3 py-2.5 rounded-lg transition-colors text-sm",r(y)?"bg-sidebar-accent text-sidebar-accent-foreground font-medium":"text-sidebar-foreground/70 hover:bg-sidebar-accent hover:text-sidebar-foreground"),children:[t.jsx(E,{icon:y.icon,badge:y.badge}),t.jsx("span",{className:"truncate",children:y.label})]},y.key))]},x.key),s[7]=r,s[8]=l,s[9]=n,s[10]=o,s[11]=f,s[12]=v):v=s[12],m=a.map(v),s[0]=a,s[1]=r,s[2]=l,s[3]=n,s[4]=o,s[5]=f,s[6]=m}else m=s[6];let d;s[13]===Symbol.for("react.memo_cache_sentinel")?(d=t.jsx("div",{className:"h-px bg-border/50 my-2"}),s[13]=d):d=s[13];let c;s[14]===Symbol.for("react.memo_cache_sentinel")?(c=t.jsx("span",{className:"shrink-0",children:t.jsx(I,{size:14})}),s[14]=c):c=s[14];let g;s[15]!==i?(g=i("settings.nav.signOut"),s[15]=i,s[16]=g):g=s[16];let u;s[17]!==g?(u=t.jsxs("div",{className:"mt-auto flex flex-col gap-0.5",children:[d,t.jsxs("button",{type:"button",onClick:Ce,className:"flex items-center gap-3 w-full px-3 py-2.5 rounded-lg transition-colors text-sm text-sidebar-foreground/70 hover:bg-sidebar-accent hover:text-sidebar-foreground",children:[c,t.jsx("span",{className:"truncate",children:g})]})]}),s[17]=g,s[18]=u):u=s[18];let b;s[19]!==m||s[20]!==u?(b=t.jsxs("div",{className:"flex flex-col flex-1 overflow-y-auto px-2 py-2 gap-0.5",children:[m,u]}),s[19]=m,s[20]=u,s[21]=b):b=s[21];let h;s[22]===Symbol.for("react.memo_cache_sentinel")?(h=t.jsx("div",{className:"px-4 pb-3 pt-1 border-t border-border/50",children:t.jsxs("span",{className:"text-xs text-muted-foreground/50",children:["v","4.319.8"]})}),s[22]=h):h=s[22];let p;return s[23]!==b?(p=t.jsxs("div",{className:"flex flex-col h-full bg-sidebar",children:[b,h]}),s[23]=b,s[24]=p):p=s[24],p}function Ce(){N("signed_out",{source:"settings_sidebar"}),R(),A.signOut()}function we(){const e=j.c(4),s=P(),{org:n}=K();ve(n.slug);let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=t.jsx("div",{className:"flex-1 flex items-center justify-center",children:t.jsx(te,{size:20,className:"animate-spin text-muted-foreground"})}),e[0]=i):i=e[0];let a;e[1]===Symbol.for("react.memo_cache_sentinel")?(a=t.jsx(T.Suspense,{fallback:i,children:t.jsx("div",{className:"flex flex-1 items-center overflow-hidden rounded-[inherit]",children:t.jsx(ne,{value:"p-0",children:t.jsx("div",{className:"flex-1 min-w-0 overflow-hidden h-full",children:t.jsx(ie,{})})})})}),e[1]=a):a=e[1];const o=a;if(s){let l;return e[2]===Symbol.for("react.memo_cache_sentinel")?(l=t.jsx("div",{className:"flex flex-col flex-1 bg-background min-h-0 overflow-hidden",children:o}),e[2]=l):l=e[2],l}let r;return e[3]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsx("div",{className:"flex-1 min-h-0 p-1",children:t.jsx("div",{className:S("flex flex-col h-full min-h-0 bg-background overflow-hidden","card-shadow","rounded-[0.75rem]"),children:o})}),e[3]=r):r=e[3],r}function es(){const e=j.c(21),s=P();let n;e[0]===Symbol.for("react.memo_cache_sentinel")?(n=t.jsx(k.LogoLink,{}),e[0]=n):n=e[0];let i;e[1]!==s?(i=s&&t.jsx(ye,{}),e[1]=s,e[2]=i):i=e[2];let a;e[3]!==i?(a=t.jsxs(k.LeftColumn,{children:[n,i]}),e[3]=i,e[4]=a):a=e[4];let o;e[5]===Symbol.for("react.memo_cache_sentinel")?(o=t.jsx(k.CenterSlot,{}),e[5]=o):o=e[5];let r;e[6]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsx(k.RightColumn,{children:t.jsx("span",{})}),e[6]=r):r=e[6];let l;e[7]!==a?(l=t.jsxs(k.Header,{children:[a,o,r]}),e[7]=a,e[8]=l):l=e[8];let f;e[9]===Symbol.for("react.memo_cache_sentinel")?(f={"--sidebar-width-icon":"3.125rem"},e[9]=f):f=e[9];let m;e[10]!==s?(m=!s&&t.jsx(Ne,{}),e[10]=s,e[11]=m):m=e[11];let d;e[12]===Symbol.for("react.memo_cache_sentinel")?(d=t.jsx(D,{className:"flex flex-col",style:{background:"transparent",containerType:"inline-size"},children:t.jsx(we,{})}),e[12]=d):d=e[12];let c;e[13]!==m?(c=t.jsxs(J,{className:"flex-1 bg-sidebar min-h-0",style:f,children:[m,d]}),e[13]=m,e[14]=c):c=e[14];let g;e[15]!==s?(g=s&&t.jsx(ke,{renderSidebar:qe}),e[15]=s,e[16]=g):g=e[16];let u;return e[17]!==g||e[18]!==l||e[19]!==c?(u=t.jsx(k.Provider,{children:t.jsx(Q,{defaultOpen:!0,children:t.jsxs("div",{className:"app-shell-root flex flex-col h-dvh overflow-hidden",children:[l,c,g]})})}),e[17]=g,e[18]=l,e[19]=c,e[20]=u):u=e[20],u}function qe(e){const{onClose:s}=e;return t.jsx(ze,{onClose:s})}export{Ne as SettingsSidebar,ze as SettingsSidebarMobile,es as default};
@@ -1 +1 @@
1
- import{c as m,b as u,M as d,j as b,a3 as S,be as p,bh as x,bi as g}from"./index-qCYv4MSE.js";import{T as j}from"./toolbar-BcAFop8I.js";function M(h){const e=m.c(7),{className:o}=h,n=u(),{toggleSidebar:i}=d();let t;e[0]!==n?(t=n("layouts.shellControls.toggleSidebar"),e[0]=n,e[1]=t):t=e[1];let s;e[2]===Symbol.for("react.memo_cache_sentinel")?(s=b.jsx(S,{size:16}),e[2]=s):s=e[2];let l;return e[3]!==o||e[4]!==t||e[5]!==i?(l=b.jsx(j,{onClick:i,"aria-label":t,className:o,children:s}),e[3]=o,e[4]=t,e[5]=i,e[6]=l):l=e[6],l}function y(h){const e=m.c(16),{renderSidebar:o}=h,n=u(),{openMobile:i,setOpenMobile:t}=d();let s;e[0]!==n?(s=n("layouts.shellControls.navigationTitle"),e[0]=n,e[1]=s):s=e[1];let l;e[2]!==s?(l=b.jsx(p,{className:"sr-only",children:s}),e[2]=s,e[3]=l):l=e[3];let a;e[4]!==t?(a=()=>t(!1),e[4]=t,e[5]=a):a=e[5];let r;e[6]!==o||e[7]!==a?(r=o({onClose:a}),e[6]=o,e[7]=a,e[8]=r):r=e[8];let c;e[9]!==l||e[10]!==r?(c=b.jsxs(x,{side:"left",hideCloseButton:!0,className:"w-screen max-w-none! p-0",children:[l,r]}),e[9]=l,e[10]=r,e[11]=c):c=e[11];let f;return e[12]!==i||e[13]!==t||e[14]!==c?(f=b.jsx(g,{open:i,onOpenChange:t,children:c}),e[12]=i,e[13]=t,e[14]=c,e[15]=f):f=e[15],f}export{y as M,M as S};
1
+ import{c as m,b as u,M as d,j as b,a3 as S,be as p,bh as x,bi as g}from"./index-DZLUP-bk.js";import{T as j}from"./toolbar-DVLlKODz.js";function M(h){const e=m.c(7),{className:o}=h,n=u(),{toggleSidebar:i}=d();let t;e[0]!==n?(t=n("layouts.shellControls.toggleSidebar"),e[0]=n,e[1]=t):t=e[1];let s;e[2]===Symbol.for("react.memo_cache_sentinel")?(s=b.jsx(S,{size:16}),e[2]=s):s=e[2];let l;return e[3]!==o||e[4]!==t||e[5]!==i?(l=b.jsx(j,{onClick:i,"aria-label":t,className:o,children:s}),e[3]=o,e[4]=t,e[5]=i,e[6]=l):l=e[6],l}function y(h){const e=m.c(16),{renderSidebar:o}=h,n=u(),{openMobile:i,setOpenMobile:t}=d();let s;e[0]!==n?(s=n("layouts.shellControls.navigationTitle"),e[0]=n,e[1]=s):s=e[1];let l;e[2]!==s?(l=b.jsx(p,{className:"sr-only",children:s}),e[2]=s,e[3]=l):l=e[3];let a;e[4]!==t?(a=()=>t(!1),e[4]=t,e[5]=a):a=e[5];let r;e[6]!==o||e[7]!==a?(r=o({onClose:a}),e[6]=o,e[7]=a,e[8]=r):r=e[8];let c;e[9]!==l||e[10]!==r?(c=b.jsxs(x,{side:"left",hideCloseButton:!0,className:"w-screen max-w-none! p-0",children:[l,r]}),e[9]=l,e[10]=r,e[11]=c):c=e[11];let f;return e[12]!==i||e[13]!==t||e[14]!==c?(f=b.jsx(g,{open:i,onOpenChange:t,children:c}),e[12]=i,e[13]=t,e[14]=c,e[15]=f):f=e[15],f}export{y as M,M as S};
@@ -1 +1 @@
1
- import{c as D,b as H,e as te,j as n,B as $,t as ee,cT as Z,C as je,a as X,y as Me,z as ke,K as le,cU as ze,cV as Fe,I as Y,n as de,r as B,o as ae,bc as ge,x as qe,cW as Be,q as he,cX as He,cY as Ue,cZ as Je,c_ as Ke,d as Ge,H as Ve,u as We,a4 as Qe,cd as Ye,c$ as Xe,d0 as pe,d1 as Ze,m as et,d2 as tt,S as nt,O as st,d3 as ot}from"./index-qCYv4MSE.js";import{A as ce}from"./avatar-DLQUtbSd.js";import{t as Ne,a as it}from"./Users03-B7JMwHdE.js";import{i as at}from"./SearchLg-CHXkkIcP.js";import{i as rt,s as lt,a as U,b as ct,n as dt}from"./Stars02-BSN_fShX.js";import{s as ut}from"./XClose-CcgBecn5.js";import{D as mt,d as ft,b as gt,e as ht,c as pt,A as bt}from"./thread-route-oU2v4HPI.js";import{i as J}from"./CheckCircle-B_Jj98KC.js";import{i as be}from"./FilterLines-BUA3zaBV.js";import{i as ye}from"./Monitor01-CB7YoX25.js";import{i as K}from"./Zap-phia53Nn.js";import{c as Ae,d as _e,b as Te,D as Oe,h as yt,e as xt}from"./dialog-Dxe79goo.js";import{u as wt}from"./use-is-desktop-app-BNujXJc_.js";import{R as St}from"./required-auth-layout-5tFVnd1H.js";import{m as vt}from"./use-mcp-client-BJ8Gl7bN.js";import{a as jt,S as kt}from"./constants-dLUUoWH7.js";import{u as Nt}from"./hooks-X3Ivo2M-.js";import{a as At,u as _t}from"./use-panel-navigate-DUpzUMxR.js";import{i as Tt}from"./use-organization-settings-DFlCOddU.js";import{u as Ot}from"./use-org-sso-B37D2h-E.js";function Ct(t){const e=D.c(49),{orgName:s,orgSlug:o,orgLogo:l,domain:r}=t,i=H();let a;e[0]!==o||e[1]!==i?(a=async()=>{const _=await fetch("/api/auth/custom/domain-join",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({organizationSlug:o})}),O=await _.json();if(!_.ok||!O.success)throw new Error(O.error??i("common.autoDomainJoinScreen.joinError"));return O},e[0]=o,e[1]=i,e[2]=a):a=e[2];let d;e[3]!==o?(d=_=>{window.location.href=`/${_.slug??o}`},e[3]=o,e[4]=d):d=e[4];let u;e[5]!==i?(u=_=>{ee.error(_ instanceof Error?_.message:i("common.autoDomainJoinScreen.joinError"))},e[5]=i,e[6]=u):u=e[6];let x;e[7]!==a||e[8]!==d||e[9]!==u?(x={mutationFn:a,onSuccess:d,onError:u},e[7]=a,e[8]=d,e[9]=u,e[10]=x):x=e[10];const c=te(x),v=It;let g;e[11]!==l||e[12]!==s?(g=l?n.jsx(ce,{url:l,fallback:s.charAt(0).toUpperCase(),shape:"square",size:"base",className:"h-12 w-12"}):n.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:n.jsx(Ne,{className:"h-6 w-6 text-primary"})}),e[11]=l,e[12]=s,e[13]=g):g=e[13];let w;e[14]!==s||e[15]!==i?(w=i("common.autoDomainJoinScreen.joinPrompt",{orgName:s}),e[14]=s,e[15]=i,e[16]=w):w=e[16];let f;e[17]!==w?(f=n.jsx("h3",{className:"text-lg font-medium",children:w}),e[17]=w,e[18]=f):f=e[18];let m;e[19]!==r||e[20]!==i?(m=i("common.autoDomainJoinScreen.joinDescription",{domain:r}),e[19]=r,e[20]=i,e[21]=m):m=e[21];let b;e[22]!==m?(b=n.jsx("p",{className:"text-sm text-muted-foreground",children:m}),e[22]=m,e[23]=b):b=e[23];let h;e[24]!==f||e[25]!==b?(h=n.jsxs("div",{className:"space-y-2",children:[f,b]}),e[24]=f,e[25]=b,e[26]=h):h=e[26];let p;e[27]!==c?(p=()=>c.mutate(),e[27]=c,e[28]=p):p=e[28];let S;e[29]!==c.isPending||e[30]!==s||e[31]!==i?(S=c.isPending?i("common.autoDomainJoinScreen.joining"):i("common.autoDomainJoinScreen.enterOrg",{orgName:s}),e[29]=c.isPending,e[30]=s,e[31]=i,e[32]=S):S=e[32];let k;e[33]!==c.isPending||e[34]!==p||e[35]!==S?(k=n.jsx($,{onClick:p,disabled:c.isPending,children:S}),e[33]=c.isPending,e[34]=p,e[35]=S,e[36]=k):k=e[36];const j=c.isPending;let y;e[37]!==i?(y=i("common.autoDomainJoinScreen.goHome"),e[37]=i,e[38]=y):y=e[38];let N;e[39]!==c.isPending||e[40]!==y?(N=n.jsx($,{variant:"ghost",onClick:v,disabled:j,children:y}),e[39]=c.isPending,e[40]=y,e[41]=N):N=e[41];let T;e[42]!==k||e[43]!==N?(T=n.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[k,N]}),e[42]=k,e[43]=N,e[44]=T):T=e[44];let A;return e[45]!==h||e[46]!==T||e[47]!==g?(A=n.jsxs(Z,{children:[g,h,T]}),e[45]=h,e[46]=T,e[47]=g,e[48]=A):A=e[48],A}function It(){window.location.href="/"}function xe(t){const e=D.c(25),{orgSlug:s,orgName:o,reason:l}=t,r=H(),i=Et,a=l==="not-found",d=a?at:je;let u;e[0]!==a||e[1]!==r?(u=r(a?"common.noAccessScreen.organizationNotFound":"common.noAccessScreen.noAccess"),e[0]=a,e[1]=r,e[2]=u):u=e[2];const x=u;let c;e[3]!==a||e[4]!==o||e[5]!==s||e[6]!==r?(c=a?n.jsxs(n.Fragment,{children:[r("common.noAccessScreen.couldNotFind")," ",n.jsx("strong",{children:s}),"."]}):n.jsxs(n.Fragment,{children:[r("common.noAccessScreen.noAccessTo")," ",n.jsx("strong",{children:o??s}),".",n.jsx("br",{}),r("common.noAccessScreen.askAdminToInvite")]}),e[3]=a,e[4]=o,e[5]=s,e[6]=r,e[7]=c):c=e[7];const v=c;let g;e[8]!==d?(g=n.jsx("div",{className:"bg-muted p-3 rounded-full",children:n.jsx(d,{className:"h-6 w-6 text-muted-foreground"})}),e[8]=d,e[9]=g):g=e[9];let w;e[10]!==x?(w=n.jsx("h3",{className:"text-lg font-medium",children:x}),e[10]=x,e[11]=w):w=e[11];let f;e[12]!==v?(f=n.jsx("p",{className:"text-sm text-muted-foreground",children:v}),e[12]=v,e[13]=f):f=e[13];let m;e[14]!==w||e[15]!==f?(m=n.jsxs("div",{className:"space-y-2",children:[w,f]}),e[14]=w,e[15]=f,e[16]=m):m=e[16];let b;e[17]!==r?(b=r("common.noAccessScreen.goToHome"),e[17]=r,e[18]=b):b=e[18];let h;e[19]!==b?(h=n.jsx($,{onClick:i,children:b}),e[19]=b,e[20]=h):h=e[20];let p;return e[21]!==g||e[22]!==m||e[23]!==h?(p=n.jsxs(Z,{children:[g,m,h]}),e[21]=g,e[22]=m,e[23]=h,e[24]=p):p=e[24],p}function Et(){window.location.href="/"}function Lt(t){const e=D.c(59),{invitationId:s,orgName:o,orgSlug:l,orgLogo:r}=t,i=H();let a;e[0]!==s?(a=async()=>{const E=await X.organization.acceptInvitation({invitationId:s});if(E.error)throw new Error(E.error.message);return E.data},e[0]=s,e[1]=a):a=e[1];let d;e[2]!==l?(d=()=>{Me(),window.location.href=`/${l}`},e[2]=l,e[3]=d):d=e[3];let u;e[4]!==i?(u=E=>{ee.error(E instanceof Error?E.message:i("common.pendingInviteScreen.failedToAccept"))},e[4]=i,e[5]=u):u=e[5];let x;e[6]!==a||e[7]!==d||e[8]!==u?(x={mutationFn:a,onSuccess:d,onError:u},e[6]=a,e[7]=d,e[8]=u,e[9]=x):x=e[9];const c=te(x);let v;e[10]!==s?(v=async()=>{const E=await X.organization.rejectInvitation({invitationId:s});if(E.error)throw new Error(E.error.message);return E.data},e[10]=s,e[11]=v):v=e[11];let g,w;e[12]!==i?(g=()=>{ee.success(i("common.pendingInviteScreen.invitationDeclined")),window.location.href="/"},w=E=>{ee.error(E instanceof Error?E.message:i("common.pendingInviteScreen.failedToDecline"))},e[12]=i,e[13]=g,e[14]=w):(g=e[13],w=e[14]);let f;e[15]!==v||e[16]!==g||e[17]!==w?(f={mutationFn:v,onSuccess:g,onError:w},e[15]=v,e[16]=g,e[17]=w,e[18]=f):f=e[18];const m=te(f),b=c.isPending||m.isPending;let h;e[19]!==r||e[20]!==o?(h=r?n.jsx(ce,{url:r,fallback:o.charAt(0).toUpperCase(),shape:"square",size:"base",className:"h-12 w-12"}):n.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:n.jsx(rt,{className:"h-6 w-6 text-primary"})}),e[19]=r,e[20]=o,e[21]=h):h=e[21];let p;e[22]!==o||e[23]!==i?(p=i("common.pendingInviteScreen.invitedTo",{orgName:o}),e[22]=o,e[23]=i,e[24]=p):p=e[24];let S;e[25]!==p?(S=n.jsx("h3",{className:"text-lg font-medium",children:p}),e[25]=p,e[26]=S):S=e[26];let k;e[27]!==i?(k=i("common.pendingInviteScreen.acceptDescription"),e[27]=i,e[28]=k):k=e[28];let j;e[29]!==k?(j=n.jsx("p",{className:"text-sm text-muted-foreground",children:k}),e[29]=k,e[30]=j):j=e[30];let y;e[31]!==S||e[32]!==j?(y=n.jsxs("div",{className:"space-y-2",children:[S,j]}),e[31]=S,e[32]=j,e[33]=y):y=e[33];let N;e[34]!==c?(N=()=>c.mutate(),e[34]=c,e[35]=N):N=e[35];let T;e[36]!==c.isPending||e[37]!==i?(T=c.isPending?i("common.pendingInviteScreen.acceptingButton"):i("common.pendingInviteScreen.acceptButton"),e[36]=c.isPending,e[37]=i,e[38]=T):T=e[38];let A;e[39]!==b||e[40]!==N||e[41]!==T?(A=n.jsx($,{onClick:N,disabled:b,children:T}),e[39]=b,e[40]=N,e[41]=T,e[42]=A):A=e[42];let _;e[43]!==m?(_=()=>m.mutate(),e[43]=m,e[44]=_):_=e[44];let O;e[45]!==m.isPending||e[46]!==i?(O=m.isPending?i("common.pendingInviteScreen.decliningButton"):i("common.pendingInviteScreen.declineButton"),e[45]=m.isPending,e[46]=i,e[47]=O):O=e[47];let C;e[48]!==b||e[49]!==_||e[50]!==O?(C=n.jsx($,{variant:"ghost",onClick:_,disabled:b,children:O}),e[48]=b,e[49]=_,e[50]=O,e[51]=C):C=e[51];let I;e[52]!==A||e[53]!==C?(I=n.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[A,C]}),e[52]=A,e[53]=C,e[54]=I):I=e[54];let L;return e[55]!==y||e[56]!==I||e[57]!==h?(L=n.jsxs(Z,{children:[h,y,I]}),e[55]=y,e[56]=I,e[57]=h,e[58]=L):L=e[58],L}function Pt(t){const e=D.c(23),{orgName:s,orgLogo:o}=t,l=H();let r;e[0]!==o||e[1]!==s?(r=o?n.jsx(ce,{url:o,fallback:s.charAt(0).toUpperCase(),shape:"square",size:"base",className:"h-12 w-12"}):n.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:n.jsx(lt,{className:"h-6 w-6 text-primary"})}),e[0]=o,e[1]=s,e[2]=r):r=e[2];let i;e[3]!==l?(i=l("common.requestPendingScreen.title"),e[3]=l,e[4]=i):i=e[4];let a;e[5]!==i?(a=n.jsx("h3",{className:"text-lg font-medium",children:i}),e[5]=i,e[6]=a):a=e[6];let d;e[7]!==s||e[8]!==l?(d=l("common.requestPendingScreen.description",{orgName:s}),e[7]=s,e[8]=l,e[9]=d):d=e[9];let u;e[10]!==d?(u=n.jsx("p",{className:"text-sm text-muted-foreground",children:d}),e[10]=d,e[11]=u):u=e[11];let x;e[12]!==a||e[13]!==u?(x=n.jsxs("div",{className:"space-y-2",children:[a,u]}),e[12]=a,e[13]=u,e[14]=x):x=e[14];let c;e[15]!==l?(c=l("common.requestPendingScreen.goHome"),e[15]=l,e[16]=c):c=e[16];let v;e[17]!==c?(v=n.jsx($,{variant:"ghost",onClick:Dt,children:c}),e[17]=c,e[18]=v):v=e[18];let g;return e[19]!==r||e[20]!==x||e[21]!==v?(g=n.jsxs(Z,{children:[r,x,v]}),e[19]=r,e[20]=x,e[21]=v,e[22]=g):g=e[22],g}function Dt(){window.location.href="/"}function $t(t){const e=D.c(45),{orgName:s,orgSlug:o,orgLogo:l,domain:r}=t,i=H();let a;e[0]!==o?(a=async()=>{const A=await fetch("/api/auth/custom/domain-request-join",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({organizationSlug:o})}),_=await A.json();if(!A.ok||!_.success)throw new Error(_.error??"Failed to request access");return _},e[0]=o,e[1]=a):a=e[1];let d;e[2]===Symbol.for("react.memo_cache_sentinel")?(d=Mt,e[2]=d):d=e[2];let u;e[3]!==i?(u=A=>{ee.error(A instanceof Error?A.message:i("common.requestToJoinScreen.failedToRequest"))},e[3]=i,e[4]=u):u=e[4];let x;e[5]!==a||e[6]!==u?(x={mutationFn:a,onSuccess:d,onError:u},e[5]=a,e[6]=u,e[7]=x):x=e[7];const c=te(x);let v;e[8]!==l||e[9]!==s?(v=l?n.jsx(ce,{url:l,fallback:s.charAt(0).toUpperCase(),shape:"square",size:"base",className:"h-12 w-12"}):n.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:n.jsx(Ne,{className:"h-6 w-6 text-primary"})}),e[8]=l,e[9]=s,e[10]=v):v=e[10];let g;e[11]!==s||e[12]!==i?(g=i("common.requestToJoinScreen.title",{orgName:s}),e[11]=s,e[12]=i,e[13]=g):g=e[13];let w;e[14]!==g?(w=n.jsx("h3",{className:"text-lg font-medium",children:g}),e[14]=g,e[15]=w):w=e[15];let f;e[16]!==r||e[17]!==i?(f=i("common.requestToJoinScreen.description",{domain:r}),e[16]=r,e[17]=i,e[18]=f):f=e[18];let m;e[19]!==f?(m=n.jsx("p",{className:"text-sm text-muted-foreground",children:f}),e[19]=f,e[20]=m):m=e[20];let b;e[21]!==w||e[22]!==m?(b=n.jsxs("div",{className:"space-y-2",children:[w,m]}),e[21]=w,e[22]=m,e[23]=b):b=e[23];let h;e[24]!==c?(h=()=>c.mutate(),e[24]=c,e[25]=h):h=e[25];let p;e[26]!==c.isPending||e[27]!==i?(p=c.isPending?i("common.requestToJoinScreen.requesting"):i("common.requestToJoinScreen.requestButton"),e[26]=c.isPending,e[27]=i,e[28]=p):p=e[28];let S;e[29]!==c.isPending||e[30]!==h||e[31]!==p?(S=n.jsx($,{onClick:h,disabled:c.isPending,children:p}),e[29]=c.isPending,e[30]=h,e[31]=p,e[32]=S):S=e[32];const k=c.isPending;let j;e[33]!==i?(j=i("common.requestToJoinScreen.goToHome"),e[33]=i,e[34]=j):j=e[34];let y;e[35]!==c.isPending||e[36]!==j?(y=n.jsx($,{variant:"ghost",onClick:Rt,disabled:k,children:j}),e[35]=c.isPending,e[36]=j,e[37]=y):y=e[37];let N;e[38]!==S||e[39]!==y?(N=n.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[S,y]}),e[38]=S,e[39]=y,e[40]=N):N=e[40];let T;return e[41]!==b||e[42]!==N||e[43]!==v?(T=n.jsxs(Z,{children:[v,b,N]}),e[41]=b,e[42]=N,e[43]=v,e[44]=T):T=e[44],T}function Rt(){window.location.href="/"}function Mt(t){if(t.alreadyMember&&t.slug){window.location.href=`/${t.slug}`;return}window.location.reload()}function zt(t){const e=D.c(7);let s;e[0]!==t?(s=le.orgAccessStatus(t),e[0]=t,e[1]=s):s=e[1];let o;e[2]!==t?(o=async()=>{const r=await fetch(`/api/auth/custom/org-access-status/${encodeURIComponent(t)}`,{credentials:"include"});if(!r.ok)throw new Error(`org-access-status failed (${r.status})`);return await r.json()},e[2]=t,e[3]=o):o=e[3];let l;return e[4]!==s||e[5]!==o?(l={queryKey:s,queryFn:o,refetchOnWindowFocus:!1},e[4]=s,e[5]=o,e[6]=l):l=e[6],ke(l)}function Ft({orgSlug:t}){const{data:e}=zt(t);if(e.status!=="member"){ze()?.org===t&&Fe();const s=localStorage.getItem(Y.lastOrgSlug())===t;if(s&&localStorage.removeItem(Y.lastOrgSlug()),s&&(e.status==="not-found"||e.status==="no-access"))return window.location.href="/",null}return e.status==="not-found"?n.jsx(xe,{orgSlug:t,reason:"not-found"}):e.status==="pending-invite"?n.jsx(Lt,{invitationId:e.invitation.id,orgName:e.organization.name,orgSlug:e.organization.slug,orgLogo:e.organization.logo}):e.status==="auto-domain-join"?n.jsx(Ct,{orgName:e.organization.name,orgSlug:e.organization.slug,orgLogo:e.organization.logo,domain:e.organization.domain??""}):e.status==="can-request"?n.jsx($t,{orgName:e.organization.name,orgSlug:e.organization.slug,orgLogo:e.organization.logo,domain:e.organization.domain??""}):e.status==="request-pending"?n.jsx(Pt,{orgName:e.organization.name,orgLogo:e.organization.logo}):e.status==="member"?(window.location.reload(),null):n.jsx(xe,{orgSlug:t,orgName:e.organization.name,reason:"no-access"})}function Ce(t){const e=D.c(42),{ariaLabel:s,dismissLabel:o,eyebrow:l,title:r,description:i,icon:a,children:d,footerLeading:u,actions:x,onDismiss:c,tone:v}=t,g=v===void 0?"neutral":v,w=u||x;let f;e[0]!==g?(f=g==="system"&&n.jsx("div",{className:"h-0.5 bg-special"}),e[0]=g,e[1]=f):f=e[1];let m;e[2]===Symbol.for("react.memo_cache_sentinel")?(m=n.jsx(ut,{size:14}),e[2]=m):m=e[2];let b;e[3]!==o||e[4]!==c?(b=n.jsx($,{size:"icon-sm",variant:"ghost","aria-label":o,className:"absolute right-2 top-2 z-10 text-muted-foreground",onClick:c,children:m}),e[3]=o,e[4]=c,e[5]=b):b=e[5];const h=a&&"flex items-start gap-3",p=d&&"pb-3";let S;e[6]!==h||e[7]!==p?(S=de("p-4 pr-11",h,p),e[6]=h,e[7]=p,e[8]=S):S=e[8];let k;e[9]!==a?(k=a&&n.jsx("div",{className:"flex size-8 shrink-0 items-center justify-center rounded-lg bg-special/10 text-special",children:a}),e[9]=a,e[10]=k):k=e[10];let j;e[11]!==l?(j=l&&n.jsx("p",{className:"text-xs text-muted-foreground",children:l}),e[11]=l,e[12]=j):j=e[12];let y;e[13]!==r?(y=n.jsx("h3",{className:"text-base font-semibold text-foreground",children:r}),e[13]=r,e[14]=y):y=e[14];let N;e[15]!==i?(N=i&&n.jsx("p",{className:"mt-1 text-xs text-muted-foreground",children:i}),e[15]=i,e[16]=N):N=e[16];let T;e[17]!==y||e[18]!==N||e[19]!==j?(T=n.jsxs("div",{children:[j,y,N]}),e[17]=y,e[18]=N,e[19]=j,e[20]=T):T=e[20];let A;e[21]!==d?(A=d&&n.jsx("div",{className:"mt-3",children:d}),e[21]=d,e[22]=A):A=e[22];let _;e[23]!==T||e[24]!==A?(_=n.jsxs("div",{className:"min-w-0 flex-1",children:[T,A]}),e[23]=T,e[24]=A,e[25]=_):_=e[25];let O;e[26]!==_||e[27]!==S||e[28]!==k?(O=n.jsxs("div",{className:S,children:[k,_]}),e[26]=_,e[27]=S,e[28]=k,e[29]=O):O=e[29];let C;e[30]!==x||e[31]!==u||e[32]!==w||e[33]!==g?(C=w&&n.jsxs("div",{className:de("flex items-center justify-between gap-3 px-4 py-2.5",g==="system"?"border-t border-border bg-muted/50":"pt-0"),children:[n.jsx("div",{className:"min-w-0 text-xs text-muted-foreground",children:u}),n.jsx("div",{className:"flex shrink-0 items-center gap-2",children:x})]}),e[30]=x,e[31]=u,e[32]=w,e[33]=g,e[34]=C):C=e[34];let I;return e[35]!==s||e[36]!==O||e[37]!==C||e[38]!==f||e[39]!==b||e[40]!==g?(I=n.jsxs("div",{role:"dialog","aria-label":s,"data-slot":"announcement-card","data-tone":g,className:"relative w-full overflow-hidden rounded-lg border border-border bg-background shadow-lg animate-in fade-in slide-in-from-bottom-2 duration-300",children:[f,b,O,C]}),e[35]=s,e[36]=O,e[37]=C,e[38]=f,e[39]=b,e[40]=g,e[41]=I):I=e[41],I}const qt=[{id:"native-app-linux-beta",date:"2026-08-20",eyebrow:"Now Available",title:"Studio for Linux is now in beta",bullets:[{icon:ye,title:"Native Linux desktop app",body:"Studio now ships as an AppImage for 64-bit x86 Linux, bringing the local desktop workflow to Linux."},{icon:J,title:"Verified, no-root install",body:"The installer verifies the download, installs Studio to ~/.local/bin, and adds it to your application launcher without sudo."},{icon:K,title:"Beta today, broader support next",body:"We're validating more distributions and desktop environments. Arm builds are not available yet, and your feedback will shape general availability."}],cta:{label:"Install Studio",action:"download-app"},learnMoreHref:"https://github.com/decocms/studio/releases/tag/native-v4.242.0"},{id:"native-app-macos",date:"2026-07-30",eyebrow:"Now Available",title:"New beta studio app",bullets:[{icon:K,title:"Faster CMS previews",body:"Every draft gets its own git worktree on your machine, so previews render instantly as you edit."},{icon:U,title:"Native Claude Code & Codex support",body:"State-of-the-art coding agents, running natively against your local files."},{icon:ct,title:"Boosted performance",body:"Entirely rewritten in Rust with a smaller memory footprint than the Bun-based runtime — fast even on modest machines."},{icon:ye,title:"Apple Silicon only — Windows coming soon",body:"Today's builds target macOS on Apple Silicon; Windows is next."}],cta:{label:"Install on Mac",action:"download-app"},learnMoreHref:"https://github.com/decocms/studio/releases"},{id:"codex-gpt-5-6-defaults",date:"2026-07-13",eyebrow:"Now Available",title:"Codex defaults move to GPT-5.6",bullets:[{icon:U,title:"Sol leads Thinking",body:"Codex Thinking now defaults to `gpt-5.6-sol` for deeper coding and reasoning work."},{icon:J,title:"Terra balances Smart",body:"The Smart tier now uses `gpt-5.6-terra`, replacing GPT-5.4 as the default balanced Codex model."},{icon:K,title:"Luna speeds up Fast",body:"The Fast tier and lightweight Codex title generation now use `gpt-5.6-luna`. Existing threads that reference older GPT-5.4 or GPT-5.5 model IDs remain supported."}]},{id:"claude-sonnet-5",date:"2026-06-30",eyebrow:"Now Available",title:"Claude Sonnet 5 powers the Smart tier",bullets:[{icon:U,title:"More agentic coding",body:"Sonnet 5 is Anthropic's strongest Sonnet model yet, with improved reasoning, tool use, coding, and knowledge work compared with Sonnet 4.6."},{icon:J,title:"Available in Claude Code",body:"The Claude Code harness now pins the Smart tier to the new `claude-sonnet-5` model id so new sessions use Sonnet 5 by default."},{icon:K,title:"Nothing to change",body:"Existing Smart-tier chats and agents pick up Sonnet 5 automatically. Thinking remains on Opus 4.8 1M."}],learnMoreHref:"https://www.anthropic.com/news/claude-sonnet-5"},{id:"fable-5-suspension",date:"2026-06-13",eyebrow:"Important Update",title:"Fable 5 & Mythos 5 suspended — Opus 4.8 takes over",bullets:[{icon:J,title:"US government directive",body:"Anthropic received an export control directive requiring the suspension of Fable 5 and Mythos 5 access for all users, citing national security concerns. Anthropic is complying while it works to resolve the matter."},{icon:U,title:"Opus 4.8 steps in as the Thinking tier",body:"The Thinking tier now runs on Claude Opus 4.8, which remains fully operational. Performance on most tasks is comparable, and Anthropic reports more than 95% of sessions were unaffected by the Fable 5 classifiers anyway."},{icon:K,title:"Nothing to change",body:"The switch is automatic — any chat or agent already using the Thinking tier is now served by Opus 4.8. Anthropic will share further details within 24 hours."}],learnMoreHref:"https://www.anthropic.com/news/fable-mythos-access"},{id:"claude-fable-5",date:"2026-06-09",eyebrow:"Now Available",title:"Claude Fable 5 leads the Thinking tier",bullets:[{icon:U,title:"State-of-the-art reasoning",body:"Fable 5 takes the Thinking tier, posting top scores across software engineering, knowledge work, and vision — and outperforming Opus 4.8 on nearly every benchmark Anthropic tested."},{icon:J,title:"Safety without the slowdown",body:"New classifiers route the small slice of high-risk requests (cybersecurity, bio/chem) back to Opus 4.8. Anthropic reports more than 95% of sessions never trigger a fallback."},{icon:K,title:"Nothing to change",body:"Chats and agents pick up Fable 5 automatically wherever the Thinking tier is selected. Opus 4.8 stays available as the safety fallback."}],learnMoreHref:"https://www.anthropic.com/news/claude-fable-5-mythos-5"},{id:"claude-opus-4-8",date:"2026-05-28",eyebrow:"Now Available",title:"Claude Opus 4.8 is the new default",bullets:[{icon:U,title:"Smarter thinking, same price",body:"Opus 4.8 now leads the Thinking and Smarter tiers, outperforming Opus 4.7 on coding, reasoning, and agent tasks at the same cost."},{icon:J,title:"More honest answers",body:"It's about 4× less likely to let a code flaw slip through unflagged, and surfaces uncertainty instead of making unsupported claims."},{icon:K,title:"Nothing to change",body:"Chats and agents pick up Opus 4.8 automatically wherever the Thinking or Smarter tier is selected."}],learnMoreHref:"https://www.anthropic.com/news/claude-opus-4-8"},{id:"enhanced-sidebar",date:"2026-05-28",eyebrow:"Now Available",title:"Enhanced sidebar",bullets:[{icon:U,title:"A clearer view of what's running",body:"See every task in your organization at a glance, with each agent and status group laid out so you can spot active work without hunting for it."},{icon:be,title:"Browse one group at a time",body:"Expand the groups you care about and pull in more results on demand — no more endless scrolling to find an older conversation."},{icon:J,title:"Polished and steadier",body:"Several sidebar bugs are fixed, including empty agent groups showing the right action and status filters returning the right tasks."}]},{id:"smarter-task-delegation",date:"2026-05-27",eyebrow:"Now Available",title:"Smarter task delegation",bullets:[{icon:it,title:"Real results from delegated agents",body:"When one agent hands work to another, you'll see the full report inline — no more empty replies hiding the work that was done."},{icon:K,title:"Same powers, top to bottom",body:"Delegated agents now work with the same tools, context, and memory as the agent that called them, so complex multi-agent investigations finish on the first try."},{icon:J,title:"Clearer progress signals",body:"When a delegated task hits its limit or runs into a problem, you get a plain-language message instead of a silent stall."}]},{id:"sidebar-task-groups",date:"2026-05-27",eyebrow:"Now Available",title:"Redesigned sidebar",bullets:[{icon:U,title:"Group by agent or status",body:"Switch the task list between grouping by agent or by status — pick whichever matches how you're working right now."},{icon:be,title:"Sharper filters",body:"Narrow the list to your tasks, manual chats, or automations from a compact filter row above the groups."}]},{id:"release-channel",date:"2026-05-26",eyebrow:"Now Available",title:"Release announcements",bullets:[{icon:U,title:"Heads-up when features ship",body:"New releases surface in a corner card the first time you see them, then stick around in your inbox."},{icon:dt,title:"Unified inbox",body:"Org invitations and product updates now share one chronological feed in the sidebar."}]}],Ie=qt,re="studio.release-feed.v1",ue=new Set;let V="",W={},me=!1;function Bt(){if(me)return V||"{}";try{return localStorage.getItem(re)??"{}"}catch{return V||"{}"}}function Ee(t){try{const e=JSON.parse(t);return e&&typeof e=="object"?e:{}}catch{return{}}}function we(){const t=Bt();return t!==V&&(V=t,W=Ee(t)),W}function Ht(t){ue.add(t);const e=s=>{if(!(s.key!==re&&s.key!==null)){try{const o=localStorage.getItem(re)??"{}",r={...Ee(o),...W};W=r,V=JSON.stringify(r)}catch{}t()}};return window.addEventListener("storage",e),()=>{ue.delete(t),window.removeEventListener("storage",e)}}function Ut(t){W=t,V=JSON.stringify(t);try{localStorage.setItem(re,V),me=!1}catch{me=!0}ue.forEach(e=>e())}function Jt(){const t=D.c(7),e=B.useSyncExternalStore(Ht,we,we);let s;t[0]!==e?(s=d=>!!e[d],t[0]=e,t[1]=s):s=t[1];const o=s,l=Kt;let r;t[2]!==e?(r=Ie.reduce((d,u)=>e[u.id]?d:d+1,0),t[2]=e,t[3]=r):r=t[3];const i=r;let a;return t[4]!==o||t[5]!==i?(a={isSeen:o,markSeen:l,unseenCount:i},t[4]=o,t[5]=i,t[6]=a):a=t[6],a}function Kt(t){W[t]||Ut({...W,[t]:{seenAt:new Date().toISOString()}})}const Gt=720*60*60*1e3,Vt=10080*60*1e3;function Wt(t){const[e,s,o]=t.split("-").map(Number);return!e||!s||!o?new Date(t).getTime():new Date(e,s-1,o).getTime()}function Qt(t){const e=Ie[0];if(!e)return null;const s=Wt(e.date),o=t-s;return o<0||o>Gt?null:e}function Yt(t){if(t instanceof Date)return t.getTime();if(typeof t=="string"||typeof t=="number"){const e=new Date(t).getTime();return Number.isFinite(e)?e:null}return null}function Xt(t,e){const s=Yt(t);return s===null?!1:e-s>=Vt}function Zt(){const t=D.c(41),e=H(),{data:s}=X.useSession(),{isSeen:o,markSeen:l}=Jt(),[r,i]=B.useState(!1);let a,d,u;if(t[0]!==o||t[1]!==s?.user?.createdAt){u=Symbol.for("react.early_return_sentinel");e:{const j=Date.now();if(a=Qt(j),!a){u=null;break e}if(!Xt(s?.user?.createdAt,j)){u=null;break e}d=o(a.id)}t[0]=o,t[1]=s?.user?.createdAt,t[2]=a,t[3]=d,t[4]=u}else a=t[2],d=t[3],u=t[4];if(u!==Symbol.for("react.early_return_sentinel"))return u;if(d)return null;let x;t[5]!==e?(x=e("announcements.release.ariaLabel"),t[5]=e,t[6]=x):x=t[6];let c;t[7]!==e?(c=e("announcements.release.dismiss"),t[7]=e,t[8]=c):c=t[8];const v=a.eyebrow,g=a.title;let w;t[9]!==a.id||t[10]!==l?(w=()=>l(a.id),t[9]=a.id,t[10]=l,t[11]=w):w=t[11];let f;t[12]!==a.id||t[13]!==a.learnMoreHref||t[14]!==l||t[15]!==e?(f=a.learnMoreHref?n.jsx("a",{href:a.learnMoreHref,target:"_blank",rel:"noreferrer",onClick:()=>l(a.id),className:"underline-offset-2 hover:text-foreground hover:underline",children:e("announcements.release.learnMore")}):null,t[12]=a.id,t[13]=a.learnMoreHref,t[14]=l,t[15]=e,t[16]=f):f=t[16];let m;t[17]!==a.cta||t[18]!==a.id||t[19]!==l?(m=a.cta?"href"in a.cta?n.jsx($,{asChild:!0,size:"sm",onClick:()=>l(a.id),children:n.jsx("a",{href:a.cta.href,children:a.cta.label})}):n.jsx($,{size:"sm",onClick:()=>i(!0),children:a.cta.label}):null,t[17]=a.cta,t[18]=a.id,t[19]=l,t[20]=m):m=t[20];let b;t[21]!==a.bullets?(b=a.bullets.map(en),t[21]=a.bullets,t[22]=b):b=t[22];let h;t[23]!==b?(h=n.jsx("ul",{className:"flex flex-col gap-3",children:b}),t[23]=b,t[24]=h):h=t[24];let p;t[25]!==a.id||t[26]!==l?(p=j=>{i(j),j||l(a.id)},t[25]=a.id,t[26]=l,t[27]=p):p=t[27];let S;t[28]!==r||t[29]!==p?(S=n.jsx(mt,{open:r,onOpenChange:p}),t[28]=r,t[29]=p,t[30]=S):S=t[30];let k;return t[31]!==a.eyebrow||t[32]!==a.title||t[33]!==h||t[34]!==S||t[35]!==x||t[36]!==c||t[37]!==w||t[38]!==f||t[39]!==m?(k=n.jsxs(Ce,{ariaLabel:x,dismissLabel:c,eyebrow:v,title:g,onDismiss:w,footerLeading:f,actions:m,children:[h,S]}),t[31]=a.eyebrow,t[32]=a.title,t[33]=h,t[34]=S,t[35]=x,t[36]=c,t[37]=w,t[38]=f,t[39]=m,t[40]=k):k=t[40],k}function en(t,e){return n.jsxs("li",{className:"flex items-start gap-3",children:[n.jsx(t.icon,{size:20,className:"mt-0.5 shrink-0 text-muted-foreground"}),n.jsxs("div",{className:"min-w-0",children:[n.jsx("p",{className:"text-sm font-medium text-foreground",children:t.title}),n.jsx("p",{className:"text-xs text-muted-foreground",children:t.body})]})]},e)}const Le=typeof navigator<"u"&&/Mac|iPhone|iPad/.test(navigator.platform),G=Le?"⌘":"Ctrl",F={keyboardShortcuts:{keys:[G,"K"],description:"Keyboard shortcuts"},back:{keys:[G,"["],description:"Back to previous"},focusChatInput:{keys:[G,"L"],description:"Focus chat input"},saveAndFormat:{keys:[G,"S"],description:"Save & format"},sendMessage:{keys:["Enter"],description:"Send message"},newLine:{keys:["Shift","Enter"],description:"New line"},selectOption:{keys:["1-9"],description:"Select option"},applyFilter:{keys:[G,"Enter"],description:"Apply filter"},togglePlanMode:{keys:[G,"Shift","L"],description:"Toggle plan mode"},newTask:{keys:["Shift",G,"S"],description:"New task"},toggleDaemon:{keys:[G,"D"],description:"Toggle daemon logs"}},tn=[{label:"General",shortcuts:[F.keyboardShortcuts,F.back,F.newTask,F.toggleDaemon]},{label:"Editor",shortcuts:[F.saveAndFormat]},{label:"Chat",shortcuts:[F.focusChatInput,F.togglePlanMode,F.sendMessage,F.newLine]},{label:"Questions",shortcuts:[F.selectOption]},{label:"Monitoring",shortcuts:[F.applyFilter]}];function Se(t){return Le?t.metaKey:t.ctrlKey}function nn(t){const e=D.c(11),{open:s,onOpenChange:o}=t,l=H();let r;e[0]!==l?(r=l("common.keyboardShortcutsDialog.title"),e[0]=l,e[1]=r):r=e[1];let i;e[2]!==r?(i=n.jsx(Ae,{children:n.jsx(_e,{children:r})}),e[2]=r,e[3]=i):i=e[3];let a;e[4]===Symbol.for("react.memo_cache_sentinel")?(a=n.jsx("div",{className:"flex flex-col gap-4",children:tn.map(sn)}),e[4]=a):a=e[4];let d;e[5]!==i?(d=n.jsxs(Te,{className:"sm:max-w-md",children:[i,a]}),e[5]=i,e[6]=d):d=e[6];let u;return e[7]!==o||e[8]!==s||e[9]!==d?(u=n.jsx(Oe,{open:s,onOpenChange:o,children:d}),e[7]=o,e[8]=s,e[9]=d,e[10]=u):u=e[10],u}function sn(t){return n.jsxs("div",{children:[n.jsx("h3",{className:"text-xs font-medium text-muted-foreground uppercase tracking-wide mb-2",children:t.label}),n.jsx("div",{className:"flex flex-col gap-1.5",children:t.shortcuts.map(on)})]},t.label)}function on(t){return n.jsxs("div",{className:"flex items-center justify-between py-1",children:[n.jsx("span",{className:"text-sm",children:t.description}),n.jsx("div",{className:"flex items-center gap-1",children:t.keys.map(an)})]},t.description)}function an(t){return n.jsx("kbd",{className:"inline-flex items-center justify-center min-w-6 h-6 px-1.5 rounded-sm border border-border bg-muted text-muted-foreground text-xs font-mono",children:t},t)}const rn=300*1e3,ln=2;function cn(t,e,s){return!e||e===s?{version:null,count:0}:t.version===e?{version:e,count:t.count+1}:{version:e,count:1}}function dn(t,e){return t.count>=ln&&t.version!==null&&t.version!==e}function un(){const t=D.c(43),e=H(),s=wt();let o;t[0]===Symbol.for("react.memo_cache_sentinel")?(o={mutationFn:fn},t[0]=o):o=t[0];const l=te(o);let r;t[1]===Symbol.for("react.memo_cache_sentinel")?(r={queryKey:le.appVersionCheck(),queryFn:mn,refetchInterval:rn,refetchIntervalInBackground:!0,staleTime:0},t[1]=r):r=t[1];const{data:i,dataUpdatedAt:a}=ae(r),[d,u]=B.useState(0);let x;t[2]===Symbol.for("react.memo_cache_sentinel")?(x={version:null,count:0},t[2]=x):x=t[2];const[c,v]=B.useState(x);a!==d&&(u(a),v(M=>cn(M,i,"4.319.6")));const[g,w]=B.useState(null),f=s;let m;t[3]!==s||t[4]!==l?(m=()=>window.location.reload(),t[3]=s,t[4]=l,t[5]=m):m=t[5];const b=m,h="announcements.version.refresh";if(!dn(c,g))return null;let p;t[6]!==e?(p=e("announcements.version.ariaLabel"),t[6]=e,t[7]=p):p=t[7];let S;t[8]!==e?(S=e("announcements.version.dismiss"),t[8]=e,t[9]=S):S=t[9];let k;t[10]!==e?(k=e("announcements.version.eyebrow"),t[10]=e,t[11]=k):k=t[11];let j;t[12]!==e?(j=e("announcements.version.title"),t[12]=e,t[13]=j):j=t[13];const y="announcements.version.description";let N;t[14]!==e||t[15]!==y?(N=e(y),t[14]=e,t[15]=y,t[16]=N):N=t[16];let T;t[17]===Symbol.for("react.memo_cache_sentinel")?(T=n.jsx(ge,{size:16}),t[17]=T):T=t[17];let A;t[18]!==c.version?(A=()=>w(c.version),t[18]=c.version,t[19]=A):A=t[19];let _;t[20]!==e?(_=e("announcements.version.currentSession",{version:"4.319.6"}),t[20]=e,t[21]=_):_=t[21];let O;t[22]!==h||t[23]!==e?(O=e(h),t[22]=h,t[23]=e,t[24]=O):O=t[24];const C=f;let I;t[25]!==C?(I=de(C),t[25]=C,t[26]=I):I=t[26];let L;t[27]!==I?(L=n.jsx(ge,{size:14,className:I}),t[27]=I,t[28]=L):L=t[28];let E;t[29]!==b||t[30]!==f||t[31]!==O||t[32]!==L?(E=n.jsxs($,{size:"sm",disabled:f,onClick:b,children:[O,L]}),t[29]=b,t[30]=f,t[31]=O,t[32]=L,t[33]=E):E=t[33];let R;return t[34]!==A||t[35]!==_||t[36]!==E||t[37]!==p||t[38]!==S||t[39]!==k||t[40]!==j||t[41]!==N?(R=n.jsx(Ce,{ariaLabel:p,dismissLabel:S,eyebrow:k,title:j,description:N,icon:T,tone:"system",onDismiss:A,footerLeading:_,actions:E}),t[34]=A,t[35]=_,t[36]=E,t[37]=p,t[38]=S,t[39]=k,t[40]=j,t[41]=N,t[42]=R):R=t[42],R}async function mn(){const t=await fetch("/api/config",{cache:"no-store"}),{config:e}=await t.json();return e.version}async function fn(){const t=await fetch("/_local/update/restart",{method:"POST"});if(!t.ok)throw new Error(`restart failed: ${t.status}`)}function gn(t){return{has(){try{return localStorage.getItem(t)==="1"}catch{return!1}},mark(){try{localStorage.setItem(t,"1")}catch{}}}}const hn=Date.parse("2026-07-21T00:00:00Z"),ve=t=>gn(Y.ptBrAnnouncementSeen(t));function pn(){const t=D.c(35),e=H(),[s,o]=qe(),{data:l,isPending:r}=X.useSession(),i=l?.user,a=i?.id,d=i?.createdAt,u=d!=null&&new Date(d).getTime()<hn,x=Be()==="pt-BR",c=!r&&!!a&&u&&x&&s.language==="en"&&!ve(a).has(),[v,g]=B.useState(!1),[w,f]=B.useState(!1);!v&&!r&&(g(!0),c&&a&&(ve(a).mark(),o(yn),f(!0),he("pt_br_auto_switch_shown")));let m;t[0]===Symbol.for("react.memo_cache_sentinel")?(m=q=>{he("pt_br_auto_switch_closed",{action:q}),f(!1)},t[0]=m):m=t[0];const b=m;let h;t[1]!==o?(h=()=>{o(bn),b("switch-back")},t[1]=o,t[2]=h):h=t[2];const p=h;let S;t[3]===Symbol.for("react.memo_cache_sentinel")?(S=q=>!q&&b("dismiss"),t[3]=S):S=t[3];let k;t[4]===Symbol.for("react.memo_cache_sentinel")?(k=n.jsx("div",{className:"text-4xl","aria-hidden":"true",children:"🇧🇷"}),t[4]=k):k=t[4];let j;t[5]!==e?(j=e("announcements.ptBr.title"),t[5]=e,t[6]=j):j=t[6];let y;t[7]!==j?(y=n.jsx(_e,{children:j}),t[7]=j,t[8]=y):y=t[8];let N;t[9]!==e?(N=e("announcements.ptBr.description"),t[9]=e,t[10]=N):N=t[10];let T;t[11]!==N?(T=n.jsx(yt,{children:N}),t[11]=N,t[12]=T):T=t[12];let A;t[13]!==y||t[14]!==T?(A=n.jsxs(Ae,{children:[y,T]}),t[13]=y,t[14]=T,t[15]=A):A=t[15];let _;t[16]!==e?(_=e("announcements.ptBr.switchBack"),t[16]=e,t[17]=_):_=t[17];let O;t[18]!==p||t[19]!==_?(O=n.jsx($,{variant:"outline",onClick:p,children:_}),t[18]=p,t[19]=_,t[20]=O):O=t[20];let C;t[21]===Symbol.for("react.memo_cache_sentinel")?(C=()=>b("ok"),t[21]=C):C=t[21];let I;t[22]!==e?(I=e("announcements.ptBr.ok"),t[22]=e,t[23]=I):I=t[23];let L;t[24]!==I?(L=n.jsx($,{onClick:C,children:I}),t[24]=I,t[25]=L):L=t[25];let E;t[26]!==O||t[27]!==L?(E=n.jsxs(xt,{children:[O,L]}),t[26]=O,t[27]=L,t[28]=E):E=t[28];let R;t[29]!==E||t[30]!==A?(R=n.jsxs(Te,{className:"sm:max-w-md",children:[k,A,E]}),t[29]=E,t[30]=A,t[31]=R):R=t[31];let M;return t[32]!==w||t[33]!==R?(M=n.jsx(Oe,{open:w,onOpenChange:S,children:R}),t[32]=w,t[33]=R,t[34]=M):M=t[34],M}function bn(t){return{...t,language:"en"}}function yn(t){return{...t,language:"pt-BR"}}function xn(t){const e=He(t);return typeof e=="string"?e:void 0}function wn(){return xn("experiment-pipeline-check"),null}function Sn(t){const e=D.c(1),{activeOrg:s}=t;if(!s)return null;Ue(s.id,{name:s.name??void 0,slug:s.slug??void 0}),Je();let o;return e[0]===Symbol.for("react.memo_cache_sentinel")?(o=n.jsx(wn,{}),e[0]=o):o=e[0],o}function vn(t){const{prev:e,virtualMcpId:s,decopilotId:o,savedLayout:l,opts:r,autosendValue:i}=t,a={mainpanel:void 0};s?a.virtualmcpid=s:e.virtualmcpid&&(a.virtualmcpid=e.virtualmcpid);const d=typeof e.virtualmcpid=="string"?e.virtualmcpid:o,x=(s??d)!==d;let c,v;return r?.panel?v=r.panel:l?(v=l.tab,l.sidepanel!==void 0&&(c=l.sidepanel),l.mainpanel!==void 0&&(a.mainpanel=l.mainpanel)):!x&&e.tabId&&!Ke(e.tabId)&&(v=e.tabId),c!==void 0&&(a.sidepanel=c),r?.autosend&&(a.autosend=i),{tabId:v,search:a}}const Pe="studio:thread-layout:v3",jn=50;function De(t){const e={};return t===null||typeof t!="object"||(typeof t.tab=="string"&&(e.tab=t.tab),typeof t.mainpanel=="boolean"&&(e.mainpanel=t.mainpanel),typeof t.sidepanel=="boolean"&&(e.sidepanel=t.sidepanel)),e}function kn(t,e,s,o=jn){const l=t.filter(([r])=>r!==e);for(l.push([e,De(s)]);l.length>o;)l.shift();return l}function fe(){try{const t=sessionStorage.getItem(Pe);if(!t)return[];const e=JSON.parse(t);return Array.isArray(e)?e.filter(s=>Array.isArray(s)&&s.length===2&&typeof s[0]=="string"):[]}catch{return[]}}function $e(t){try{sessionStorage.setItem(Pe,JSON.stringify(t))}catch{}}function Nn(t,e){t&&$e(kn(fe(),t,e))}function An(t){if(!t)return null;const e=fe().find(([s])=>s===t);return e?De(e[1]):null}function ss(t){if(!t)return;const e=fe(),s=e.filter(([o])=>o!==t);s.length!==e.length&&$e(s)}function Re(t){return{queryKey:le.homeNextActions(t),queryFn:async()=>{const e=await fetch(`/api/${t}/home-next-actions`,{cache:"no-store"});if(!e.ok)throw new Error("Failed to load home next actions");return await e.json()},staleTime:0,refetchOnWindowFocus:"always"}}function os(t){const e=D.c(10);let s;e[0]!==t?(s=Re(t),e[0]=t,e[1]=s):s=e[1];const o=ae(s);let l;e[2]!==o.data?.prompts?(l=o.data?.prompts??[],e[2]=o.data?.prompts,e[3]=l):l=e[3];let r;e[4]!==o.data?.tiles?(r=o.data?.tiles??[],e[4]=o.data?.tiles,e[5]=r):r=e[5];let i;return e[6]!==o.isLoading||e[7]!==l||e[8]!==r?(i={isLoading:o.isLoading,prompts:l,tiles:r},e[6]=o.isLoading,e[7]=l,e[8]=r,e[9]=i):i=e[9],i}function _n(t){const e=D.c(31),{orgSlug:s,orgName:o,domain:l}=t,r=H();let i;e[0]!==s?(i=()=>{window.location.href=`/api/${encodeURIComponent(s)}/sso/authorize`},e[0]=s,e[1]=i):i=e[1];const a=i,d=Tn;let u;e[2]===Symbol.for("react.memo_cache_sentinel")?(u=n.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:n.jsx(je,{className:"h-6 w-6 text-primary"})}),e[2]=u):u=e[2];let x;e[3]!==r?(x=r("common.ssoRequiredScreen.title"),e[3]=r,e[4]=x):x=e[4];let c;e[5]!==x?(c=n.jsx("h3",{className:"text-lg font-medium",children:x}),e[5]=x,e[6]=c):c=e[6];let v;e[7]!==l||e[8]!==o||e[9]!==r?(v=o?n.jsxs(n.Fragment,{children:[n.jsx("strong",{children:o})," ",r("common.ssoRequiredScreen.requiresSsoAuth"),l?` ${r("common.ssoRequiredScreen.via",{domain:l})}`:"","."]}):r("common.ssoRequiredScreen.orgRequiresSsoAuth"),e[7]=l,e[8]=o,e[9]=r,e[10]=v):v=e[10];let g;e[11]!==v?(g=n.jsx("p",{className:"text-sm text-muted-foreground",children:v}),e[11]=v,e[12]=g):g=e[12];let w;e[13]!==c||e[14]!==g?(w=n.jsxs("div",{className:"space-y-2",children:[c,g]}),e[13]=c,e[14]=g,e[15]=w):w=e[15];let f;e[16]!==r?(f=r("common.ssoRequiredScreen.signInWithSso"),e[16]=r,e[17]=f):f=e[17];let m;e[18]!==a||e[19]!==f?(m=n.jsx($,{onClick:a,children:f}),e[18]=a,e[19]=f,e[20]=m):m=e[20];let b;e[21]!==r?(b=r("common.ssoRequiredScreen.goBack"),e[21]=r,e[22]=b):b=e[22];let h;e[23]!==b?(h=n.jsx($,{variant:"ghost",onClick:d,children:b}),e[23]=b,e[24]=h):h=e[24];let p;e[25]!==h||e[26]!==m?(p=n.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[m,h]}),e[25]=h,e[26]=m,e[27]=p):p=e[27];let S;return e[28]!==p||e[29]!==w?(S=n.jsxs(Z,{children:[u,w,p]}),e[28]=p,e[29]=w,e[30]=S):S=e[30],S}function Tn(){window.location.href="/"}function On(t){const e=D.c(8),{org:s,children:o}=t,r=Tt(s.id,s.slug)?.enabled_plugins??null;let i;e[0]!==s.id||e[1]!==s.name||e[2]!==r?(i={id:s.id,organizationId:s.id,slug:"_org",name:s.name,enabledPlugins:r,ui:null},e[0]=s.id,e[1]=s.name,e[2]=r,e[3]=i):i=e[3];const a=i;let d;return e[4]!==o||e[5]!==s||e[6]!==a?(d=n.jsx(ot,{org:s,project:a,children:o}),e[4]=o,e[5]=s,e[6]=a,e[7]=d):d=e[7],d}function Cn(){const t=Ge(),e=Nt(),{org:s}=Ve(),o=We({strict:!1}),l=At(),{openPanel:r,closePanel:i}=_t(),a=ft(),d=gt(),u=ht(),x=pt(),c=(f,m=!0)=>t({to:".",search:f,replace:m}),v=()=>c(f=>({...f,sidepanel:!0})),g=(f,m,b)=>{const h=!!d&&d===f;d&&!h&&Nn(d,{tab:l,mainpanel:o.mainpanel,sidepanel:o.sidepanel});const p=h?null:An(f),S=jt(s.id).id,k=vn({prev:{virtualmcpid:a,tabId:l},virtualMcpId:m,decopilotId:S,savedLayout:p,opts:b,autosendValue:bt});return x(f,()=>k.search,{virtualMcpId:m,view:{tabId:k.tabId}})};return{openSidePanel:v,setTaskId:g,createNewTask:async(f,m,b)=>{const h=crypto.randomUUID(),p=f??u;try{await e?.create({id:h,virtual_mcp_id:p,...m?{branch:m}:{}})}catch{}g(h,p,b)},openTab:r,closeTab:i}}const In=new Set(["/$org/","/$org/home"]);function En(){const t=D.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e={select:Ln},t[0]=e):e=t[0],et(e)}function Ln(t){const e=t.matches.at(-1)?.fullPath;return e!==void 0&&In.has(e)}function Pn(){const t=D.c(52);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e={from:"/shell/$org",shouldThrow:!1},t[0]=e):e=t[0];const o=Qe(e)?.params.org,[l,r]=B.useState(!1),i=Ye(),a=En(),d=o??"";let u;t[1]!==d?(u=Re(d),t[1]=d,t[2]=u):u=t[2];const x=!!o&&a;let c;t[3]!==u||t[4]!==x?(c={...u,enabled:x},t[3]=u,t[4]=x,t[5]=c):c=t[5],ae(c);const{data:v}=X.useSession(),g=v?.user?.id;let w;t[6]!==o||t[7]!==g?(w=o&&g?Xe(g,o):null,t[6]=o,t[7]=g,t[8]=w):w=t[8];const f=w;let m,b;t[9]!==i?(m=()=>{const P=z=>{if(Se(z)&&z.code==="KeyK"){z.preventDefault(),r(!0);return}Se(z)&&z.code==="BracketLeft"&&i.history.canGoBack()&&(z.preventDefault(),i.history.back())};return document.addEventListener("keydown",P),()=>document.removeEventListener("keydown",P)},b=[i],t[9]=i,t[10]=m,t[11]=b):(m=t[10],b=t[11]),B.useEffect(m,b);let h;t[12]!==o?(h=le.activeOrganization(o),t[12]=o,t[13]=h):h=t[13];let p;t[14]!==o||t[15]!==g?(p=async()=>{if(!o)return null;performance.mark("mesh:active-org-fetch:start");const{data:P}=await X.organization.getFullOrganization({query:{organizationSlug:o}}).finally(Dn),z=pe(P);return P&&!z&&localStorage.setItem(Y.lastOrgSlug(),o),g&&P&&tt(g,o,P),P},t[14]=o,t[15]=g,t[16]=p):p=t[16];const S=f?f.data:void 0,k=f?.updatedAt;let j;t[17]!==S||t[18]!==k||t[19]!==h||t[20]!==p?(j={queryKey:h,queryFn:p,initialData:S,initialDataUpdatedAt:k,gcTime:1/0,refetchOnWindowFocus:!1},t[17]=S,t[18]=k,t[19]=h,t[20]=p,t[21]=j):j=t[21];const{data:y}=ke(j),N=y?.id,T=y?.slug,{data:A}=Ot(N,T),_=N??"",O=T??"";let C;t[22]!==_||t[23]!==O?(C=vt({connectionId:kt,orgId:_,orgSlug:O}),t[22]=_,t[23]=O,t[24]=C):C=t[24];const I=!!N&&!!T;let L;if(t[25]!==C||t[26]!==I?(L={...C,enabled:I},t[25]=C,t[26]=I,t[27]=L):L=t[27],ae(L),!y){let P;t[28]===Symbol.for("react.memo_cache_sentinel")?(P=n.jsx(nt,{}),t[28]=P):P=t[28];let z;return t[29]!==o?(z=n.jsx(B.Suspense,{fallback:P,children:n.jsx(Ft,{orgSlug:o})}),t[29]=o,t[30]=z):z=t[30],z}if(pe(y)){localStorage.getItem(Y.lastOrgSlug())===o&&localStorage.removeItem(Y.lastOrgSlug());let P;return t[31]!==y.name?(P=n.jsx(Ze,{orgName:y.name}),t[31]=y.name,t[32]=P):P=t[32],P}if(A?.ssoRequired&&!A.authenticated){let P;return t[33]!==y.id||t[34]!==y.name||t[35]!==y.slug||t[36]!==A.domain?(P=n.jsx(_n,{orgId:y.id,orgSlug:y.slug,orgName:y.name,domain:A.domain}),t[33]=y.id,t[34]=y.name,t[35]=y.slug,t[36]=A.domain,t[37]=P):P=t[37],P}const R=y.logo??null;let M;t[38]!==y||t[39]!==R?(M={...y,logo:R},t[38]=y,t[39]=R,t[40]=M):M=t[40];let q;t[41]!==y?(q=n.jsx(Sn,{activeOrg:y}),t[41]=y,t[42]=q):q=t[42];let ne;t[43]===Symbol.for("react.memo_cache_sentinel")?(ne=n.jsx(st,{}),t[43]=ne):ne=t[43];let se;t[44]===Symbol.for("react.memo_cache_sentinel")?(se=n.jsxs("div",{className:"fixed bottom-6 right-6 z-50 flex w-[min(360px,calc(100vw-3rem))] flex-col gap-3",children:[n.jsx(Zt,{}),n.jsx(un,{})]}),t[44]=se):se=t[44];let Q;t[45]!==l?(Q=n.jsx(nn,{open:l,onOpenChange:r}),t[45]=l,t[46]=Q):Q=t[46];let oe;t[47]===Symbol.for("react.memo_cache_sentinel")?(oe=n.jsx(pn,{}),t[47]=oe):oe=t[47];let ie;return t[48]!==M||t[49]!==q||t[50]!==Q?(ie=n.jsxs(On,{org:M,children:[q,ne,se,Q,oe]}),t[48]=M,t[49]=q,t[50]=Q,t[51]=ie):ie=t[51],ie}function Dn(){performance.mark("mesh:active-org-fetch:end"),performance.measure("mesh:active-org-fetch","mesh:active-org-fetch:start","mesh:active-org-fetch:end")}function $n(){const t=D.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=n.jsx(St,{children:n.jsx(Pn,{})}),t[0]=e):e=t[0],e}const is=Object.freeze(Object.defineProperty({__proto__:null,default:$n,usePanelActions:Cn},Symbol.toStringTag,{value:"Module"}));export{F as K,os as a,ss as f,Se as i,gn as m,is as s,Cn as u};
1
+ import{c as D,b as H,e as te,j as n,B as $,t as ee,cT as Z,C as je,a as X,y as Me,z as ke,K as le,cU as ze,cV as Fe,I as Y,n as de,r as B,o as ae,bc as ge,x as qe,cW as Be,q as he,cX as He,cY as Ue,cZ as Je,c_ as Ke,d as Ge,H as Ve,u as We,a4 as Qe,cd as Ye,c$ as Xe,d0 as pe,d1 as Ze,m as et,d2 as tt,S as nt,O as st,d3 as ot}from"./index-DZLUP-bk.js";import{A as ce}from"./avatar-CpPlf24-.js";import{t as Ne,a as it}from"./Users03-Bg19q-V-.js";import{i as at}from"./SearchLg-8uAbG9P4.js";import{i as rt,s as lt,a as U,b as ct,n as dt}from"./Stars02-CqIkzwRk.js";import{s as ut}from"./XClose-DyyJkORZ.js";import{D as mt,d as ft,b as gt,e as ht,c as pt,A as bt}from"./thread-route-C79eC_qQ.js";import{i as J}from"./CheckCircle-tNccGo23.js";import{i as be}from"./FilterLines-pNRXDJ_z.js";import{i as ye}from"./Monitor01-Dhk7PXVV.js";import{i as K}from"./Zap-DBnrIpUC.js";import{c as Ae,d as _e,b as Te,D as Oe,h as yt,e as xt}from"./dialog-pwZ4KzZ6.js";import{u as wt}from"./use-is-desktop-app-BNujXJc_.js";import{R as St}from"./required-auth-layout-BmpA_-kW.js";import{m as vt}from"./use-mcp-client-Qp-dz21o.js";import{a as jt,S as kt}from"./constants-dLUUoWH7.js";import{u as Nt}from"./hooks-DamZm9Dl.js";import{a as At,u as _t}from"./use-panel-navigate-C7_AOzBX.js";import{i as Tt}from"./use-organization-settings-DoHw0Vrb.js";import{u as Ot}from"./use-org-sso-wZB9SHX9.js";function Ct(t){const e=D.c(49),{orgName:s,orgSlug:o,orgLogo:l,domain:r}=t,i=H();let a;e[0]!==o||e[1]!==i?(a=async()=>{const _=await fetch("/api/auth/custom/domain-join",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({organizationSlug:o})}),O=await _.json();if(!_.ok||!O.success)throw new Error(O.error??i("common.autoDomainJoinScreen.joinError"));return O},e[0]=o,e[1]=i,e[2]=a):a=e[2];let d;e[3]!==o?(d=_=>{window.location.href=`/${_.slug??o}`},e[3]=o,e[4]=d):d=e[4];let u;e[5]!==i?(u=_=>{ee.error(_ instanceof Error?_.message:i("common.autoDomainJoinScreen.joinError"))},e[5]=i,e[6]=u):u=e[6];let x;e[7]!==a||e[8]!==d||e[9]!==u?(x={mutationFn:a,onSuccess:d,onError:u},e[7]=a,e[8]=d,e[9]=u,e[10]=x):x=e[10];const c=te(x),v=It;let g;e[11]!==l||e[12]!==s?(g=l?n.jsx(ce,{url:l,fallback:s.charAt(0).toUpperCase(),shape:"square",size:"base",className:"h-12 w-12"}):n.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:n.jsx(Ne,{className:"h-6 w-6 text-primary"})}),e[11]=l,e[12]=s,e[13]=g):g=e[13];let w;e[14]!==s||e[15]!==i?(w=i("common.autoDomainJoinScreen.joinPrompt",{orgName:s}),e[14]=s,e[15]=i,e[16]=w):w=e[16];let f;e[17]!==w?(f=n.jsx("h3",{className:"text-lg font-medium",children:w}),e[17]=w,e[18]=f):f=e[18];let m;e[19]!==r||e[20]!==i?(m=i("common.autoDomainJoinScreen.joinDescription",{domain:r}),e[19]=r,e[20]=i,e[21]=m):m=e[21];let b;e[22]!==m?(b=n.jsx("p",{className:"text-sm text-muted-foreground",children:m}),e[22]=m,e[23]=b):b=e[23];let h;e[24]!==f||e[25]!==b?(h=n.jsxs("div",{className:"space-y-2",children:[f,b]}),e[24]=f,e[25]=b,e[26]=h):h=e[26];let p;e[27]!==c?(p=()=>c.mutate(),e[27]=c,e[28]=p):p=e[28];let S;e[29]!==c.isPending||e[30]!==s||e[31]!==i?(S=c.isPending?i("common.autoDomainJoinScreen.joining"):i("common.autoDomainJoinScreen.enterOrg",{orgName:s}),e[29]=c.isPending,e[30]=s,e[31]=i,e[32]=S):S=e[32];let k;e[33]!==c.isPending||e[34]!==p||e[35]!==S?(k=n.jsx($,{onClick:p,disabled:c.isPending,children:S}),e[33]=c.isPending,e[34]=p,e[35]=S,e[36]=k):k=e[36];const j=c.isPending;let y;e[37]!==i?(y=i("common.autoDomainJoinScreen.goHome"),e[37]=i,e[38]=y):y=e[38];let N;e[39]!==c.isPending||e[40]!==y?(N=n.jsx($,{variant:"ghost",onClick:v,disabled:j,children:y}),e[39]=c.isPending,e[40]=y,e[41]=N):N=e[41];let T;e[42]!==k||e[43]!==N?(T=n.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[k,N]}),e[42]=k,e[43]=N,e[44]=T):T=e[44];let A;return e[45]!==h||e[46]!==T||e[47]!==g?(A=n.jsxs(Z,{children:[g,h,T]}),e[45]=h,e[46]=T,e[47]=g,e[48]=A):A=e[48],A}function It(){window.location.href="/"}function xe(t){const e=D.c(25),{orgSlug:s,orgName:o,reason:l}=t,r=H(),i=Et,a=l==="not-found",d=a?at:je;let u;e[0]!==a||e[1]!==r?(u=r(a?"common.noAccessScreen.organizationNotFound":"common.noAccessScreen.noAccess"),e[0]=a,e[1]=r,e[2]=u):u=e[2];const x=u;let c;e[3]!==a||e[4]!==o||e[5]!==s||e[6]!==r?(c=a?n.jsxs(n.Fragment,{children:[r("common.noAccessScreen.couldNotFind")," ",n.jsx("strong",{children:s}),"."]}):n.jsxs(n.Fragment,{children:[r("common.noAccessScreen.noAccessTo")," ",n.jsx("strong",{children:o??s}),".",n.jsx("br",{}),r("common.noAccessScreen.askAdminToInvite")]}),e[3]=a,e[4]=o,e[5]=s,e[6]=r,e[7]=c):c=e[7];const v=c;let g;e[8]!==d?(g=n.jsx("div",{className:"bg-muted p-3 rounded-full",children:n.jsx(d,{className:"h-6 w-6 text-muted-foreground"})}),e[8]=d,e[9]=g):g=e[9];let w;e[10]!==x?(w=n.jsx("h3",{className:"text-lg font-medium",children:x}),e[10]=x,e[11]=w):w=e[11];let f;e[12]!==v?(f=n.jsx("p",{className:"text-sm text-muted-foreground",children:v}),e[12]=v,e[13]=f):f=e[13];let m;e[14]!==w||e[15]!==f?(m=n.jsxs("div",{className:"space-y-2",children:[w,f]}),e[14]=w,e[15]=f,e[16]=m):m=e[16];let b;e[17]!==r?(b=r("common.noAccessScreen.goToHome"),e[17]=r,e[18]=b):b=e[18];let h;e[19]!==b?(h=n.jsx($,{onClick:i,children:b}),e[19]=b,e[20]=h):h=e[20];let p;return e[21]!==g||e[22]!==m||e[23]!==h?(p=n.jsxs(Z,{children:[g,m,h]}),e[21]=g,e[22]=m,e[23]=h,e[24]=p):p=e[24],p}function Et(){window.location.href="/"}function Lt(t){const e=D.c(59),{invitationId:s,orgName:o,orgSlug:l,orgLogo:r}=t,i=H();let a;e[0]!==s?(a=async()=>{const E=await X.organization.acceptInvitation({invitationId:s});if(E.error)throw new Error(E.error.message);return E.data},e[0]=s,e[1]=a):a=e[1];let d;e[2]!==l?(d=()=>{Me(),window.location.href=`/${l}`},e[2]=l,e[3]=d):d=e[3];let u;e[4]!==i?(u=E=>{ee.error(E instanceof Error?E.message:i("common.pendingInviteScreen.failedToAccept"))},e[4]=i,e[5]=u):u=e[5];let x;e[6]!==a||e[7]!==d||e[8]!==u?(x={mutationFn:a,onSuccess:d,onError:u},e[6]=a,e[7]=d,e[8]=u,e[9]=x):x=e[9];const c=te(x);let v;e[10]!==s?(v=async()=>{const E=await X.organization.rejectInvitation({invitationId:s});if(E.error)throw new Error(E.error.message);return E.data},e[10]=s,e[11]=v):v=e[11];let g,w;e[12]!==i?(g=()=>{ee.success(i("common.pendingInviteScreen.invitationDeclined")),window.location.href="/"},w=E=>{ee.error(E instanceof Error?E.message:i("common.pendingInviteScreen.failedToDecline"))},e[12]=i,e[13]=g,e[14]=w):(g=e[13],w=e[14]);let f;e[15]!==v||e[16]!==g||e[17]!==w?(f={mutationFn:v,onSuccess:g,onError:w},e[15]=v,e[16]=g,e[17]=w,e[18]=f):f=e[18];const m=te(f),b=c.isPending||m.isPending;let h;e[19]!==r||e[20]!==o?(h=r?n.jsx(ce,{url:r,fallback:o.charAt(0).toUpperCase(),shape:"square",size:"base",className:"h-12 w-12"}):n.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:n.jsx(rt,{className:"h-6 w-6 text-primary"})}),e[19]=r,e[20]=o,e[21]=h):h=e[21];let p;e[22]!==o||e[23]!==i?(p=i("common.pendingInviteScreen.invitedTo",{orgName:o}),e[22]=o,e[23]=i,e[24]=p):p=e[24];let S;e[25]!==p?(S=n.jsx("h3",{className:"text-lg font-medium",children:p}),e[25]=p,e[26]=S):S=e[26];let k;e[27]!==i?(k=i("common.pendingInviteScreen.acceptDescription"),e[27]=i,e[28]=k):k=e[28];let j;e[29]!==k?(j=n.jsx("p",{className:"text-sm text-muted-foreground",children:k}),e[29]=k,e[30]=j):j=e[30];let y;e[31]!==S||e[32]!==j?(y=n.jsxs("div",{className:"space-y-2",children:[S,j]}),e[31]=S,e[32]=j,e[33]=y):y=e[33];let N;e[34]!==c?(N=()=>c.mutate(),e[34]=c,e[35]=N):N=e[35];let T;e[36]!==c.isPending||e[37]!==i?(T=c.isPending?i("common.pendingInviteScreen.acceptingButton"):i("common.pendingInviteScreen.acceptButton"),e[36]=c.isPending,e[37]=i,e[38]=T):T=e[38];let A;e[39]!==b||e[40]!==N||e[41]!==T?(A=n.jsx($,{onClick:N,disabled:b,children:T}),e[39]=b,e[40]=N,e[41]=T,e[42]=A):A=e[42];let _;e[43]!==m?(_=()=>m.mutate(),e[43]=m,e[44]=_):_=e[44];let O;e[45]!==m.isPending||e[46]!==i?(O=m.isPending?i("common.pendingInviteScreen.decliningButton"):i("common.pendingInviteScreen.declineButton"),e[45]=m.isPending,e[46]=i,e[47]=O):O=e[47];let C;e[48]!==b||e[49]!==_||e[50]!==O?(C=n.jsx($,{variant:"ghost",onClick:_,disabled:b,children:O}),e[48]=b,e[49]=_,e[50]=O,e[51]=C):C=e[51];let I;e[52]!==A||e[53]!==C?(I=n.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[A,C]}),e[52]=A,e[53]=C,e[54]=I):I=e[54];let L;return e[55]!==y||e[56]!==I||e[57]!==h?(L=n.jsxs(Z,{children:[h,y,I]}),e[55]=y,e[56]=I,e[57]=h,e[58]=L):L=e[58],L}function Pt(t){const e=D.c(23),{orgName:s,orgLogo:o}=t,l=H();let r;e[0]!==o||e[1]!==s?(r=o?n.jsx(ce,{url:o,fallback:s.charAt(0).toUpperCase(),shape:"square",size:"base",className:"h-12 w-12"}):n.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:n.jsx(lt,{className:"h-6 w-6 text-primary"})}),e[0]=o,e[1]=s,e[2]=r):r=e[2];let i;e[3]!==l?(i=l("common.requestPendingScreen.title"),e[3]=l,e[4]=i):i=e[4];let a;e[5]!==i?(a=n.jsx("h3",{className:"text-lg font-medium",children:i}),e[5]=i,e[6]=a):a=e[6];let d;e[7]!==s||e[8]!==l?(d=l("common.requestPendingScreen.description",{orgName:s}),e[7]=s,e[8]=l,e[9]=d):d=e[9];let u;e[10]!==d?(u=n.jsx("p",{className:"text-sm text-muted-foreground",children:d}),e[10]=d,e[11]=u):u=e[11];let x;e[12]!==a||e[13]!==u?(x=n.jsxs("div",{className:"space-y-2",children:[a,u]}),e[12]=a,e[13]=u,e[14]=x):x=e[14];let c;e[15]!==l?(c=l("common.requestPendingScreen.goHome"),e[15]=l,e[16]=c):c=e[16];let v;e[17]!==c?(v=n.jsx($,{variant:"ghost",onClick:Dt,children:c}),e[17]=c,e[18]=v):v=e[18];let g;return e[19]!==r||e[20]!==x||e[21]!==v?(g=n.jsxs(Z,{children:[r,x,v]}),e[19]=r,e[20]=x,e[21]=v,e[22]=g):g=e[22],g}function Dt(){window.location.href="/"}function $t(t){const e=D.c(45),{orgName:s,orgSlug:o,orgLogo:l,domain:r}=t,i=H();let a;e[0]!==o?(a=async()=>{const A=await fetch("/api/auth/custom/domain-request-join",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({organizationSlug:o})}),_=await A.json();if(!A.ok||!_.success)throw new Error(_.error??"Failed to request access");return _},e[0]=o,e[1]=a):a=e[1];let d;e[2]===Symbol.for("react.memo_cache_sentinel")?(d=Mt,e[2]=d):d=e[2];let u;e[3]!==i?(u=A=>{ee.error(A instanceof Error?A.message:i("common.requestToJoinScreen.failedToRequest"))},e[3]=i,e[4]=u):u=e[4];let x;e[5]!==a||e[6]!==u?(x={mutationFn:a,onSuccess:d,onError:u},e[5]=a,e[6]=u,e[7]=x):x=e[7];const c=te(x);let v;e[8]!==l||e[9]!==s?(v=l?n.jsx(ce,{url:l,fallback:s.charAt(0).toUpperCase(),shape:"square",size:"base",className:"h-12 w-12"}):n.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:n.jsx(Ne,{className:"h-6 w-6 text-primary"})}),e[8]=l,e[9]=s,e[10]=v):v=e[10];let g;e[11]!==s||e[12]!==i?(g=i("common.requestToJoinScreen.title",{orgName:s}),e[11]=s,e[12]=i,e[13]=g):g=e[13];let w;e[14]!==g?(w=n.jsx("h3",{className:"text-lg font-medium",children:g}),e[14]=g,e[15]=w):w=e[15];let f;e[16]!==r||e[17]!==i?(f=i("common.requestToJoinScreen.description",{domain:r}),e[16]=r,e[17]=i,e[18]=f):f=e[18];let m;e[19]!==f?(m=n.jsx("p",{className:"text-sm text-muted-foreground",children:f}),e[19]=f,e[20]=m):m=e[20];let b;e[21]!==w||e[22]!==m?(b=n.jsxs("div",{className:"space-y-2",children:[w,m]}),e[21]=w,e[22]=m,e[23]=b):b=e[23];let h;e[24]!==c?(h=()=>c.mutate(),e[24]=c,e[25]=h):h=e[25];let p;e[26]!==c.isPending||e[27]!==i?(p=c.isPending?i("common.requestToJoinScreen.requesting"):i("common.requestToJoinScreen.requestButton"),e[26]=c.isPending,e[27]=i,e[28]=p):p=e[28];let S;e[29]!==c.isPending||e[30]!==h||e[31]!==p?(S=n.jsx($,{onClick:h,disabled:c.isPending,children:p}),e[29]=c.isPending,e[30]=h,e[31]=p,e[32]=S):S=e[32];const k=c.isPending;let j;e[33]!==i?(j=i("common.requestToJoinScreen.goToHome"),e[33]=i,e[34]=j):j=e[34];let y;e[35]!==c.isPending||e[36]!==j?(y=n.jsx($,{variant:"ghost",onClick:Rt,disabled:k,children:j}),e[35]=c.isPending,e[36]=j,e[37]=y):y=e[37];let N;e[38]!==S||e[39]!==y?(N=n.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[S,y]}),e[38]=S,e[39]=y,e[40]=N):N=e[40];let T;return e[41]!==b||e[42]!==N||e[43]!==v?(T=n.jsxs(Z,{children:[v,b,N]}),e[41]=b,e[42]=N,e[43]=v,e[44]=T):T=e[44],T}function Rt(){window.location.href="/"}function Mt(t){if(t.alreadyMember&&t.slug){window.location.href=`/${t.slug}`;return}window.location.reload()}function zt(t){const e=D.c(7);let s;e[0]!==t?(s=le.orgAccessStatus(t),e[0]=t,e[1]=s):s=e[1];let o;e[2]!==t?(o=async()=>{const r=await fetch(`/api/auth/custom/org-access-status/${encodeURIComponent(t)}`,{credentials:"include"});if(!r.ok)throw new Error(`org-access-status failed (${r.status})`);return await r.json()},e[2]=t,e[3]=o):o=e[3];let l;return e[4]!==s||e[5]!==o?(l={queryKey:s,queryFn:o,refetchOnWindowFocus:!1},e[4]=s,e[5]=o,e[6]=l):l=e[6],ke(l)}function Ft({orgSlug:t}){const{data:e}=zt(t);if(e.status!=="member"){ze()?.org===t&&Fe();const s=localStorage.getItem(Y.lastOrgSlug())===t;if(s&&localStorage.removeItem(Y.lastOrgSlug()),s&&(e.status==="not-found"||e.status==="no-access"))return window.location.href="/",null}return e.status==="not-found"?n.jsx(xe,{orgSlug:t,reason:"not-found"}):e.status==="pending-invite"?n.jsx(Lt,{invitationId:e.invitation.id,orgName:e.organization.name,orgSlug:e.organization.slug,orgLogo:e.organization.logo}):e.status==="auto-domain-join"?n.jsx(Ct,{orgName:e.organization.name,orgSlug:e.organization.slug,orgLogo:e.organization.logo,domain:e.organization.domain??""}):e.status==="can-request"?n.jsx($t,{orgName:e.organization.name,orgSlug:e.organization.slug,orgLogo:e.organization.logo,domain:e.organization.domain??""}):e.status==="request-pending"?n.jsx(Pt,{orgName:e.organization.name,orgLogo:e.organization.logo}):e.status==="member"?(window.location.reload(),null):n.jsx(xe,{orgSlug:t,orgName:e.organization.name,reason:"no-access"})}function Ce(t){const e=D.c(42),{ariaLabel:s,dismissLabel:o,eyebrow:l,title:r,description:i,icon:a,children:d,footerLeading:u,actions:x,onDismiss:c,tone:v}=t,g=v===void 0?"neutral":v,w=u||x;let f;e[0]!==g?(f=g==="system"&&n.jsx("div",{className:"h-0.5 bg-special"}),e[0]=g,e[1]=f):f=e[1];let m;e[2]===Symbol.for("react.memo_cache_sentinel")?(m=n.jsx(ut,{size:14}),e[2]=m):m=e[2];let b;e[3]!==o||e[4]!==c?(b=n.jsx($,{size:"icon-sm",variant:"ghost","aria-label":o,className:"absolute right-2 top-2 z-10 text-muted-foreground",onClick:c,children:m}),e[3]=o,e[4]=c,e[5]=b):b=e[5];const h=a&&"flex items-start gap-3",p=d&&"pb-3";let S;e[6]!==h||e[7]!==p?(S=de("p-4 pr-11",h,p),e[6]=h,e[7]=p,e[8]=S):S=e[8];let k;e[9]!==a?(k=a&&n.jsx("div",{className:"flex size-8 shrink-0 items-center justify-center rounded-lg bg-special/10 text-special",children:a}),e[9]=a,e[10]=k):k=e[10];let j;e[11]!==l?(j=l&&n.jsx("p",{className:"text-xs text-muted-foreground",children:l}),e[11]=l,e[12]=j):j=e[12];let y;e[13]!==r?(y=n.jsx("h3",{className:"text-base font-semibold text-foreground",children:r}),e[13]=r,e[14]=y):y=e[14];let N;e[15]!==i?(N=i&&n.jsx("p",{className:"mt-1 text-xs text-muted-foreground",children:i}),e[15]=i,e[16]=N):N=e[16];let T;e[17]!==y||e[18]!==N||e[19]!==j?(T=n.jsxs("div",{children:[j,y,N]}),e[17]=y,e[18]=N,e[19]=j,e[20]=T):T=e[20];let A;e[21]!==d?(A=d&&n.jsx("div",{className:"mt-3",children:d}),e[21]=d,e[22]=A):A=e[22];let _;e[23]!==T||e[24]!==A?(_=n.jsxs("div",{className:"min-w-0 flex-1",children:[T,A]}),e[23]=T,e[24]=A,e[25]=_):_=e[25];let O;e[26]!==_||e[27]!==S||e[28]!==k?(O=n.jsxs("div",{className:S,children:[k,_]}),e[26]=_,e[27]=S,e[28]=k,e[29]=O):O=e[29];let C;e[30]!==x||e[31]!==u||e[32]!==w||e[33]!==g?(C=w&&n.jsxs("div",{className:de("flex items-center justify-between gap-3 px-4 py-2.5",g==="system"?"border-t border-border bg-muted/50":"pt-0"),children:[n.jsx("div",{className:"min-w-0 text-xs text-muted-foreground",children:u}),n.jsx("div",{className:"flex shrink-0 items-center gap-2",children:x})]}),e[30]=x,e[31]=u,e[32]=w,e[33]=g,e[34]=C):C=e[34];let I;return e[35]!==s||e[36]!==O||e[37]!==C||e[38]!==f||e[39]!==b||e[40]!==g?(I=n.jsxs("div",{role:"dialog","aria-label":s,"data-slot":"announcement-card","data-tone":g,className:"relative w-full overflow-hidden rounded-lg border border-border bg-background shadow-lg animate-in fade-in slide-in-from-bottom-2 duration-300",children:[f,b,O,C]}),e[35]=s,e[36]=O,e[37]=C,e[38]=f,e[39]=b,e[40]=g,e[41]=I):I=e[41],I}const qt=[{id:"native-app-linux-beta",date:"2026-08-20",eyebrow:"Now Available",title:"Studio for Linux is now in beta",bullets:[{icon:ye,title:"Native Linux desktop app",body:"Studio now ships as an AppImage for 64-bit x86 Linux, bringing the local desktop workflow to Linux."},{icon:J,title:"Verified, no-root install",body:"The installer verifies the download, installs Studio to ~/.local/bin, and adds it to your application launcher without sudo."},{icon:K,title:"Beta today, broader support next",body:"We're validating more distributions and desktop environments. Arm builds are not available yet, and your feedback will shape general availability."}],cta:{label:"Install Studio",action:"download-app"},learnMoreHref:"https://github.com/decocms/studio/releases/tag/native-v4.242.0"},{id:"native-app-macos",date:"2026-07-30",eyebrow:"Now Available",title:"New beta studio app",bullets:[{icon:K,title:"Faster CMS previews",body:"Every draft gets its own git worktree on your machine, so previews render instantly as you edit."},{icon:U,title:"Native Claude Code & Codex support",body:"State-of-the-art coding agents, running natively against your local files."},{icon:ct,title:"Boosted performance",body:"Entirely rewritten in Rust with a smaller memory footprint than the Bun-based runtime — fast even on modest machines."},{icon:ye,title:"Apple Silicon only — Windows coming soon",body:"Today's builds target macOS on Apple Silicon; Windows is next."}],cta:{label:"Install on Mac",action:"download-app"},learnMoreHref:"https://github.com/decocms/studio/releases"},{id:"codex-gpt-5-6-defaults",date:"2026-07-13",eyebrow:"Now Available",title:"Codex defaults move to GPT-5.6",bullets:[{icon:U,title:"Sol leads Thinking",body:"Codex Thinking now defaults to `gpt-5.6-sol` for deeper coding and reasoning work."},{icon:J,title:"Terra balances Smart",body:"The Smart tier now uses `gpt-5.6-terra`, replacing GPT-5.4 as the default balanced Codex model."},{icon:K,title:"Luna speeds up Fast",body:"The Fast tier and lightweight Codex title generation now use `gpt-5.6-luna`. Existing threads that reference older GPT-5.4 or GPT-5.5 model IDs remain supported."}]},{id:"claude-sonnet-5",date:"2026-06-30",eyebrow:"Now Available",title:"Claude Sonnet 5 powers the Smart tier",bullets:[{icon:U,title:"More agentic coding",body:"Sonnet 5 is Anthropic's strongest Sonnet model yet, with improved reasoning, tool use, coding, and knowledge work compared with Sonnet 4.6."},{icon:J,title:"Available in Claude Code",body:"The Claude Code harness now pins the Smart tier to the new `claude-sonnet-5` model id so new sessions use Sonnet 5 by default."},{icon:K,title:"Nothing to change",body:"Existing Smart-tier chats and agents pick up Sonnet 5 automatically. Thinking remains on Opus 4.8 1M."}],learnMoreHref:"https://www.anthropic.com/news/claude-sonnet-5"},{id:"fable-5-suspension",date:"2026-06-13",eyebrow:"Important Update",title:"Fable 5 & Mythos 5 suspended — Opus 4.8 takes over",bullets:[{icon:J,title:"US government directive",body:"Anthropic received an export control directive requiring the suspension of Fable 5 and Mythos 5 access for all users, citing national security concerns. Anthropic is complying while it works to resolve the matter."},{icon:U,title:"Opus 4.8 steps in as the Thinking tier",body:"The Thinking tier now runs on Claude Opus 4.8, which remains fully operational. Performance on most tasks is comparable, and Anthropic reports more than 95% of sessions were unaffected by the Fable 5 classifiers anyway."},{icon:K,title:"Nothing to change",body:"The switch is automatic — any chat or agent already using the Thinking tier is now served by Opus 4.8. Anthropic will share further details within 24 hours."}],learnMoreHref:"https://www.anthropic.com/news/fable-mythos-access"},{id:"claude-fable-5",date:"2026-06-09",eyebrow:"Now Available",title:"Claude Fable 5 leads the Thinking tier",bullets:[{icon:U,title:"State-of-the-art reasoning",body:"Fable 5 takes the Thinking tier, posting top scores across software engineering, knowledge work, and vision — and outperforming Opus 4.8 on nearly every benchmark Anthropic tested."},{icon:J,title:"Safety without the slowdown",body:"New classifiers route the small slice of high-risk requests (cybersecurity, bio/chem) back to Opus 4.8. Anthropic reports more than 95% of sessions never trigger a fallback."},{icon:K,title:"Nothing to change",body:"Chats and agents pick up Fable 5 automatically wherever the Thinking tier is selected. Opus 4.8 stays available as the safety fallback."}],learnMoreHref:"https://www.anthropic.com/news/claude-fable-5-mythos-5"},{id:"claude-opus-4-8",date:"2026-05-28",eyebrow:"Now Available",title:"Claude Opus 4.8 is the new default",bullets:[{icon:U,title:"Smarter thinking, same price",body:"Opus 4.8 now leads the Thinking and Smarter tiers, outperforming Opus 4.7 on coding, reasoning, and agent tasks at the same cost."},{icon:J,title:"More honest answers",body:"It's about 4× less likely to let a code flaw slip through unflagged, and surfaces uncertainty instead of making unsupported claims."},{icon:K,title:"Nothing to change",body:"Chats and agents pick up Opus 4.8 automatically wherever the Thinking or Smarter tier is selected."}],learnMoreHref:"https://www.anthropic.com/news/claude-opus-4-8"},{id:"enhanced-sidebar",date:"2026-05-28",eyebrow:"Now Available",title:"Enhanced sidebar",bullets:[{icon:U,title:"A clearer view of what's running",body:"See every task in your organization at a glance, with each agent and status group laid out so you can spot active work without hunting for it."},{icon:be,title:"Browse one group at a time",body:"Expand the groups you care about and pull in more results on demand — no more endless scrolling to find an older conversation."},{icon:J,title:"Polished and steadier",body:"Several sidebar bugs are fixed, including empty agent groups showing the right action and status filters returning the right tasks."}]},{id:"smarter-task-delegation",date:"2026-05-27",eyebrow:"Now Available",title:"Smarter task delegation",bullets:[{icon:it,title:"Real results from delegated agents",body:"When one agent hands work to another, you'll see the full report inline — no more empty replies hiding the work that was done."},{icon:K,title:"Same powers, top to bottom",body:"Delegated agents now work with the same tools, context, and memory as the agent that called them, so complex multi-agent investigations finish on the first try."},{icon:J,title:"Clearer progress signals",body:"When a delegated task hits its limit or runs into a problem, you get a plain-language message instead of a silent stall."}]},{id:"sidebar-task-groups",date:"2026-05-27",eyebrow:"Now Available",title:"Redesigned sidebar",bullets:[{icon:U,title:"Group by agent or status",body:"Switch the task list between grouping by agent or by status — pick whichever matches how you're working right now."},{icon:be,title:"Sharper filters",body:"Narrow the list to your tasks, manual chats, or automations from a compact filter row above the groups."}]},{id:"release-channel",date:"2026-05-26",eyebrow:"Now Available",title:"Release announcements",bullets:[{icon:U,title:"Heads-up when features ship",body:"New releases surface in a corner card the first time you see them, then stick around in your inbox."},{icon:dt,title:"Unified inbox",body:"Org invitations and product updates now share one chronological feed in the sidebar."}]}],Ie=qt,re="studio.release-feed.v1",ue=new Set;let V="",W={},me=!1;function Bt(){if(me)return V||"{}";try{return localStorage.getItem(re)??"{}"}catch{return V||"{}"}}function Ee(t){try{const e=JSON.parse(t);return e&&typeof e=="object"?e:{}}catch{return{}}}function we(){const t=Bt();return t!==V&&(V=t,W=Ee(t)),W}function Ht(t){ue.add(t);const e=s=>{if(!(s.key!==re&&s.key!==null)){try{const o=localStorage.getItem(re)??"{}",r={...Ee(o),...W};W=r,V=JSON.stringify(r)}catch{}t()}};return window.addEventListener("storage",e),()=>{ue.delete(t),window.removeEventListener("storage",e)}}function Ut(t){W=t,V=JSON.stringify(t);try{localStorage.setItem(re,V),me=!1}catch{me=!0}ue.forEach(e=>e())}function Jt(){const t=D.c(7),e=B.useSyncExternalStore(Ht,we,we);let s;t[0]!==e?(s=d=>!!e[d],t[0]=e,t[1]=s):s=t[1];const o=s,l=Kt;let r;t[2]!==e?(r=Ie.reduce((d,u)=>e[u.id]?d:d+1,0),t[2]=e,t[3]=r):r=t[3];const i=r;let a;return t[4]!==o||t[5]!==i?(a={isSeen:o,markSeen:l,unseenCount:i},t[4]=o,t[5]=i,t[6]=a):a=t[6],a}function Kt(t){W[t]||Ut({...W,[t]:{seenAt:new Date().toISOString()}})}const Gt=720*60*60*1e3,Vt=10080*60*1e3;function Wt(t){const[e,s,o]=t.split("-").map(Number);return!e||!s||!o?new Date(t).getTime():new Date(e,s-1,o).getTime()}function Qt(t){const e=Ie[0];if(!e)return null;const s=Wt(e.date),o=t-s;return o<0||o>Gt?null:e}function Yt(t){if(t instanceof Date)return t.getTime();if(typeof t=="string"||typeof t=="number"){const e=new Date(t).getTime();return Number.isFinite(e)?e:null}return null}function Xt(t,e){const s=Yt(t);return s===null?!1:e-s>=Vt}function Zt(){const t=D.c(41),e=H(),{data:s}=X.useSession(),{isSeen:o,markSeen:l}=Jt(),[r,i]=B.useState(!1);let a,d,u;if(t[0]!==o||t[1]!==s?.user?.createdAt){u=Symbol.for("react.early_return_sentinel");e:{const j=Date.now();if(a=Qt(j),!a){u=null;break e}if(!Xt(s?.user?.createdAt,j)){u=null;break e}d=o(a.id)}t[0]=o,t[1]=s?.user?.createdAt,t[2]=a,t[3]=d,t[4]=u}else a=t[2],d=t[3],u=t[4];if(u!==Symbol.for("react.early_return_sentinel"))return u;if(d)return null;let x;t[5]!==e?(x=e("announcements.release.ariaLabel"),t[5]=e,t[6]=x):x=t[6];let c;t[7]!==e?(c=e("announcements.release.dismiss"),t[7]=e,t[8]=c):c=t[8];const v=a.eyebrow,g=a.title;let w;t[9]!==a.id||t[10]!==l?(w=()=>l(a.id),t[9]=a.id,t[10]=l,t[11]=w):w=t[11];let f;t[12]!==a.id||t[13]!==a.learnMoreHref||t[14]!==l||t[15]!==e?(f=a.learnMoreHref?n.jsx("a",{href:a.learnMoreHref,target:"_blank",rel:"noreferrer",onClick:()=>l(a.id),className:"underline-offset-2 hover:text-foreground hover:underline",children:e("announcements.release.learnMore")}):null,t[12]=a.id,t[13]=a.learnMoreHref,t[14]=l,t[15]=e,t[16]=f):f=t[16];let m;t[17]!==a.cta||t[18]!==a.id||t[19]!==l?(m=a.cta?"href"in a.cta?n.jsx($,{asChild:!0,size:"sm",onClick:()=>l(a.id),children:n.jsx("a",{href:a.cta.href,children:a.cta.label})}):n.jsx($,{size:"sm",onClick:()=>i(!0),children:a.cta.label}):null,t[17]=a.cta,t[18]=a.id,t[19]=l,t[20]=m):m=t[20];let b;t[21]!==a.bullets?(b=a.bullets.map(en),t[21]=a.bullets,t[22]=b):b=t[22];let h;t[23]!==b?(h=n.jsx("ul",{className:"flex flex-col gap-3",children:b}),t[23]=b,t[24]=h):h=t[24];let p;t[25]!==a.id||t[26]!==l?(p=j=>{i(j),j||l(a.id)},t[25]=a.id,t[26]=l,t[27]=p):p=t[27];let S;t[28]!==r||t[29]!==p?(S=n.jsx(mt,{open:r,onOpenChange:p}),t[28]=r,t[29]=p,t[30]=S):S=t[30];let k;return t[31]!==a.eyebrow||t[32]!==a.title||t[33]!==h||t[34]!==S||t[35]!==x||t[36]!==c||t[37]!==w||t[38]!==f||t[39]!==m?(k=n.jsxs(Ce,{ariaLabel:x,dismissLabel:c,eyebrow:v,title:g,onDismiss:w,footerLeading:f,actions:m,children:[h,S]}),t[31]=a.eyebrow,t[32]=a.title,t[33]=h,t[34]=S,t[35]=x,t[36]=c,t[37]=w,t[38]=f,t[39]=m,t[40]=k):k=t[40],k}function en(t,e){return n.jsxs("li",{className:"flex items-start gap-3",children:[n.jsx(t.icon,{size:20,className:"mt-0.5 shrink-0 text-muted-foreground"}),n.jsxs("div",{className:"min-w-0",children:[n.jsx("p",{className:"text-sm font-medium text-foreground",children:t.title}),n.jsx("p",{className:"text-xs text-muted-foreground",children:t.body})]})]},e)}const Le=typeof navigator<"u"&&/Mac|iPhone|iPad/.test(navigator.platform),G=Le?"⌘":"Ctrl",F={keyboardShortcuts:{keys:[G,"K"],description:"Keyboard shortcuts"},back:{keys:[G,"["],description:"Back to previous"},focusChatInput:{keys:[G,"L"],description:"Focus chat input"},saveAndFormat:{keys:[G,"S"],description:"Save & format"},sendMessage:{keys:["Enter"],description:"Send message"},newLine:{keys:["Shift","Enter"],description:"New line"},selectOption:{keys:["1-9"],description:"Select option"},applyFilter:{keys:[G,"Enter"],description:"Apply filter"},togglePlanMode:{keys:[G,"Shift","L"],description:"Toggle plan mode"},newTask:{keys:["Shift",G,"S"],description:"New task"},toggleDaemon:{keys:[G,"D"],description:"Toggle daemon logs"}},tn=[{label:"General",shortcuts:[F.keyboardShortcuts,F.back,F.newTask,F.toggleDaemon]},{label:"Editor",shortcuts:[F.saveAndFormat]},{label:"Chat",shortcuts:[F.focusChatInput,F.togglePlanMode,F.sendMessage,F.newLine]},{label:"Questions",shortcuts:[F.selectOption]},{label:"Monitoring",shortcuts:[F.applyFilter]}];function Se(t){return Le?t.metaKey:t.ctrlKey}function nn(t){const e=D.c(11),{open:s,onOpenChange:o}=t,l=H();let r;e[0]!==l?(r=l("common.keyboardShortcutsDialog.title"),e[0]=l,e[1]=r):r=e[1];let i;e[2]!==r?(i=n.jsx(Ae,{children:n.jsx(_e,{children:r})}),e[2]=r,e[3]=i):i=e[3];let a;e[4]===Symbol.for("react.memo_cache_sentinel")?(a=n.jsx("div",{className:"flex flex-col gap-4",children:tn.map(sn)}),e[4]=a):a=e[4];let d;e[5]!==i?(d=n.jsxs(Te,{className:"sm:max-w-md",children:[i,a]}),e[5]=i,e[6]=d):d=e[6];let u;return e[7]!==o||e[8]!==s||e[9]!==d?(u=n.jsx(Oe,{open:s,onOpenChange:o,children:d}),e[7]=o,e[8]=s,e[9]=d,e[10]=u):u=e[10],u}function sn(t){return n.jsxs("div",{children:[n.jsx("h3",{className:"text-xs font-medium text-muted-foreground uppercase tracking-wide mb-2",children:t.label}),n.jsx("div",{className:"flex flex-col gap-1.5",children:t.shortcuts.map(on)})]},t.label)}function on(t){return n.jsxs("div",{className:"flex items-center justify-between py-1",children:[n.jsx("span",{className:"text-sm",children:t.description}),n.jsx("div",{className:"flex items-center gap-1",children:t.keys.map(an)})]},t.description)}function an(t){return n.jsx("kbd",{className:"inline-flex items-center justify-center min-w-6 h-6 px-1.5 rounded-sm border border-border bg-muted text-muted-foreground text-xs font-mono",children:t},t)}const rn=300*1e3,ln=2;function cn(t,e,s){return!e||e===s?{version:null,count:0}:t.version===e?{version:e,count:t.count+1}:{version:e,count:1}}function dn(t,e){return t.count>=ln&&t.version!==null&&t.version!==e}function un(){const t=D.c(43),e=H(),s=wt();let o;t[0]===Symbol.for("react.memo_cache_sentinel")?(o={mutationFn:fn},t[0]=o):o=t[0];const l=te(o);let r;t[1]===Symbol.for("react.memo_cache_sentinel")?(r={queryKey:le.appVersionCheck(),queryFn:mn,refetchInterval:rn,refetchIntervalInBackground:!0,staleTime:0},t[1]=r):r=t[1];const{data:i,dataUpdatedAt:a}=ae(r),[d,u]=B.useState(0);let x;t[2]===Symbol.for("react.memo_cache_sentinel")?(x={version:null,count:0},t[2]=x):x=t[2];const[c,v]=B.useState(x);a!==d&&(u(a),v(M=>cn(M,i,"4.319.8")));const[g,w]=B.useState(null),f=s;let m;t[3]!==s||t[4]!==l?(m=()=>window.location.reload(),t[3]=s,t[4]=l,t[5]=m):m=t[5];const b=m,h="announcements.version.refresh";if(!dn(c,g))return null;let p;t[6]!==e?(p=e("announcements.version.ariaLabel"),t[6]=e,t[7]=p):p=t[7];let S;t[8]!==e?(S=e("announcements.version.dismiss"),t[8]=e,t[9]=S):S=t[9];let k;t[10]!==e?(k=e("announcements.version.eyebrow"),t[10]=e,t[11]=k):k=t[11];let j;t[12]!==e?(j=e("announcements.version.title"),t[12]=e,t[13]=j):j=t[13];const y="announcements.version.description";let N;t[14]!==e||t[15]!==y?(N=e(y),t[14]=e,t[15]=y,t[16]=N):N=t[16];let T;t[17]===Symbol.for("react.memo_cache_sentinel")?(T=n.jsx(ge,{size:16}),t[17]=T):T=t[17];let A;t[18]!==c.version?(A=()=>w(c.version),t[18]=c.version,t[19]=A):A=t[19];let _;t[20]!==e?(_=e("announcements.version.currentSession",{version:"4.319.8"}),t[20]=e,t[21]=_):_=t[21];let O;t[22]!==h||t[23]!==e?(O=e(h),t[22]=h,t[23]=e,t[24]=O):O=t[24];const C=f;let I;t[25]!==C?(I=de(C),t[25]=C,t[26]=I):I=t[26];let L;t[27]!==I?(L=n.jsx(ge,{size:14,className:I}),t[27]=I,t[28]=L):L=t[28];let E;t[29]!==b||t[30]!==f||t[31]!==O||t[32]!==L?(E=n.jsxs($,{size:"sm",disabled:f,onClick:b,children:[O,L]}),t[29]=b,t[30]=f,t[31]=O,t[32]=L,t[33]=E):E=t[33];let R;return t[34]!==A||t[35]!==_||t[36]!==E||t[37]!==p||t[38]!==S||t[39]!==k||t[40]!==j||t[41]!==N?(R=n.jsx(Ce,{ariaLabel:p,dismissLabel:S,eyebrow:k,title:j,description:N,icon:T,tone:"system",onDismiss:A,footerLeading:_,actions:E}),t[34]=A,t[35]=_,t[36]=E,t[37]=p,t[38]=S,t[39]=k,t[40]=j,t[41]=N,t[42]=R):R=t[42],R}async function mn(){const t=await fetch("/api/config",{cache:"no-store"}),{config:e}=await t.json();return e.version}async function fn(){const t=await fetch("/_local/update/restart",{method:"POST"});if(!t.ok)throw new Error(`restart failed: ${t.status}`)}function gn(t){return{has(){try{return localStorage.getItem(t)==="1"}catch{return!1}},mark(){try{localStorage.setItem(t,"1")}catch{}}}}const hn=Date.parse("2026-07-21T00:00:00Z"),ve=t=>gn(Y.ptBrAnnouncementSeen(t));function pn(){const t=D.c(35),e=H(),[s,o]=qe(),{data:l,isPending:r}=X.useSession(),i=l?.user,a=i?.id,d=i?.createdAt,u=d!=null&&new Date(d).getTime()<hn,x=Be()==="pt-BR",c=!r&&!!a&&u&&x&&s.language==="en"&&!ve(a).has(),[v,g]=B.useState(!1),[w,f]=B.useState(!1);!v&&!r&&(g(!0),c&&a&&(ve(a).mark(),o(yn),f(!0),he("pt_br_auto_switch_shown")));let m;t[0]===Symbol.for("react.memo_cache_sentinel")?(m=q=>{he("pt_br_auto_switch_closed",{action:q}),f(!1)},t[0]=m):m=t[0];const b=m;let h;t[1]!==o?(h=()=>{o(bn),b("switch-back")},t[1]=o,t[2]=h):h=t[2];const p=h;let S;t[3]===Symbol.for("react.memo_cache_sentinel")?(S=q=>!q&&b("dismiss"),t[3]=S):S=t[3];let k;t[4]===Symbol.for("react.memo_cache_sentinel")?(k=n.jsx("div",{className:"text-4xl","aria-hidden":"true",children:"🇧🇷"}),t[4]=k):k=t[4];let j;t[5]!==e?(j=e("announcements.ptBr.title"),t[5]=e,t[6]=j):j=t[6];let y;t[7]!==j?(y=n.jsx(_e,{children:j}),t[7]=j,t[8]=y):y=t[8];let N;t[9]!==e?(N=e("announcements.ptBr.description"),t[9]=e,t[10]=N):N=t[10];let T;t[11]!==N?(T=n.jsx(yt,{children:N}),t[11]=N,t[12]=T):T=t[12];let A;t[13]!==y||t[14]!==T?(A=n.jsxs(Ae,{children:[y,T]}),t[13]=y,t[14]=T,t[15]=A):A=t[15];let _;t[16]!==e?(_=e("announcements.ptBr.switchBack"),t[16]=e,t[17]=_):_=t[17];let O;t[18]!==p||t[19]!==_?(O=n.jsx($,{variant:"outline",onClick:p,children:_}),t[18]=p,t[19]=_,t[20]=O):O=t[20];let C;t[21]===Symbol.for("react.memo_cache_sentinel")?(C=()=>b("ok"),t[21]=C):C=t[21];let I;t[22]!==e?(I=e("announcements.ptBr.ok"),t[22]=e,t[23]=I):I=t[23];let L;t[24]!==I?(L=n.jsx($,{onClick:C,children:I}),t[24]=I,t[25]=L):L=t[25];let E;t[26]!==O||t[27]!==L?(E=n.jsxs(xt,{children:[O,L]}),t[26]=O,t[27]=L,t[28]=E):E=t[28];let R;t[29]!==E||t[30]!==A?(R=n.jsxs(Te,{className:"sm:max-w-md",children:[k,A,E]}),t[29]=E,t[30]=A,t[31]=R):R=t[31];let M;return t[32]!==w||t[33]!==R?(M=n.jsx(Oe,{open:w,onOpenChange:S,children:R}),t[32]=w,t[33]=R,t[34]=M):M=t[34],M}function bn(t){return{...t,language:"en"}}function yn(t){return{...t,language:"pt-BR"}}function xn(t){const e=He(t);return typeof e=="string"?e:void 0}function wn(){return xn("experiment-pipeline-check"),null}function Sn(t){const e=D.c(1),{activeOrg:s}=t;if(!s)return null;Ue(s.id,{name:s.name??void 0,slug:s.slug??void 0}),Je();let o;return e[0]===Symbol.for("react.memo_cache_sentinel")?(o=n.jsx(wn,{}),e[0]=o):o=e[0],o}function vn(t){const{prev:e,virtualMcpId:s,decopilotId:o,savedLayout:l,opts:r,autosendValue:i}=t,a={mainpanel:void 0};s?a.virtualmcpid=s:e.virtualmcpid&&(a.virtualmcpid=e.virtualmcpid);const d=typeof e.virtualmcpid=="string"?e.virtualmcpid:o,x=(s??d)!==d;let c,v;return r?.panel?v=r.panel:l?(v=l.tab,l.sidepanel!==void 0&&(c=l.sidepanel),l.mainpanel!==void 0&&(a.mainpanel=l.mainpanel)):!x&&e.tabId&&!Ke(e.tabId)&&(v=e.tabId),c!==void 0&&(a.sidepanel=c),r?.autosend&&(a.autosend=i),{tabId:v,search:a}}const Pe="studio:thread-layout:v3",jn=50;function De(t){const e={};return t===null||typeof t!="object"||(typeof t.tab=="string"&&(e.tab=t.tab),typeof t.mainpanel=="boolean"&&(e.mainpanel=t.mainpanel),typeof t.sidepanel=="boolean"&&(e.sidepanel=t.sidepanel)),e}function kn(t,e,s,o=jn){const l=t.filter(([r])=>r!==e);for(l.push([e,De(s)]);l.length>o;)l.shift();return l}function fe(){try{const t=sessionStorage.getItem(Pe);if(!t)return[];const e=JSON.parse(t);return Array.isArray(e)?e.filter(s=>Array.isArray(s)&&s.length===2&&typeof s[0]=="string"):[]}catch{return[]}}function $e(t){try{sessionStorage.setItem(Pe,JSON.stringify(t))}catch{}}function Nn(t,e){t&&$e(kn(fe(),t,e))}function An(t){if(!t)return null;const e=fe().find(([s])=>s===t);return e?De(e[1]):null}function ss(t){if(!t)return;const e=fe(),s=e.filter(([o])=>o!==t);s.length!==e.length&&$e(s)}function Re(t){return{queryKey:le.homeNextActions(t),queryFn:async()=>{const e=await fetch(`/api/${t}/home-next-actions`,{cache:"no-store"});if(!e.ok)throw new Error("Failed to load home next actions");return await e.json()},staleTime:0,refetchOnWindowFocus:"always"}}function os(t){const e=D.c(10);let s;e[0]!==t?(s=Re(t),e[0]=t,e[1]=s):s=e[1];const o=ae(s);let l;e[2]!==o.data?.prompts?(l=o.data?.prompts??[],e[2]=o.data?.prompts,e[3]=l):l=e[3];let r;e[4]!==o.data?.tiles?(r=o.data?.tiles??[],e[4]=o.data?.tiles,e[5]=r):r=e[5];let i;return e[6]!==o.isLoading||e[7]!==l||e[8]!==r?(i={isLoading:o.isLoading,prompts:l,tiles:r},e[6]=o.isLoading,e[7]=l,e[8]=r,e[9]=i):i=e[9],i}function _n(t){const e=D.c(31),{orgSlug:s,orgName:o,domain:l}=t,r=H();let i;e[0]!==s?(i=()=>{window.location.href=`/api/${encodeURIComponent(s)}/sso/authorize`},e[0]=s,e[1]=i):i=e[1];const a=i,d=Tn;let u;e[2]===Symbol.for("react.memo_cache_sentinel")?(u=n.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:n.jsx(je,{className:"h-6 w-6 text-primary"})}),e[2]=u):u=e[2];let x;e[3]!==r?(x=r("common.ssoRequiredScreen.title"),e[3]=r,e[4]=x):x=e[4];let c;e[5]!==x?(c=n.jsx("h3",{className:"text-lg font-medium",children:x}),e[5]=x,e[6]=c):c=e[6];let v;e[7]!==l||e[8]!==o||e[9]!==r?(v=o?n.jsxs(n.Fragment,{children:[n.jsx("strong",{children:o})," ",r("common.ssoRequiredScreen.requiresSsoAuth"),l?` ${r("common.ssoRequiredScreen.via",{domain:l})}`:"","."]}):r("common.ssoRequiredScreen.orgRequiresSsoAuth"),e[7]=l,e[8]=o,e[9]=r,e[10]=v):v=e[10];let g;e[11]!==v?(g=n.jsx("p",{className:"text-sm text-muted-foreground",children:v}),e[11]=v,e[12]=g):g=e[12];let w;e[13]!==c||e[14]!==g?(w=n.jsxs("div",{className:"space-y-2",children:[c,g]}),e[13]=c,e[14]=g,e[15]=w):w=e[15];let f;e[16]!==r?(f=r("common.ssoRequiredScreen.signInWithSso"),e[16]=r,e[17]=f):f=e[17];let m;e[18]!==a||e[19]!==f?(m=n.jsx($,{onClick:a,children:f}),e[18]=a,e[19]=f,e[20]=m):m=e[20];let b;e[21]!==r?(b=r("common.ssoRequiredScreen.goBack"),e[21]=r,e[22]=b):b=e[22];let h;e[23]!==b?(h=n.jsx($,{variant:"ghost",onClick:d,children:b}),e[23]=b,e[24]=h):h=e[24];let p;e[25]!==h||e[26]!==m?(p=n.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[m,h]}),e[25]=h,e[26]=m,e[27]=p):p=e[27];let S;return e[28]!==p||e[29]!==w?(S=n.jsxs(Z,{children:[u,w,p]}),e[28]=p,e[29]=w,e[30]=S):S=e[30],S}function Tn(){window.location.href="/"}function On(t){const e=D.c(8),{org:s,children:o}=t,r=Tt(s.id,s.slug)?.enabled_plugins??null;let i;e[0]!==s.id||e[1]!==s.name||e[2]!==r?(i={id:s.id,organizationId:s.id,slug:"_org",name:s.name,enabledPlugins:r,ui:null},e[0]=s.id,e[1]=s.name,e[2]=r,e[3]=i):i=e[3];const a=i;let d;return e[4]!==o||e[5]!==s||e[6]!==a?(d=n.jsx(ot,{org:s,project:a,children:o}),e[4]=o,e[5]=s,e[6]=a,e[7]=d):d=e[7],d}function Cn(){const t=Ge(),e=Nt(),{org:s}=Ve(),o=We({strict:!1}),l=At(),{openPanel:r,closePanel:i}=_t(),a=ft(),d=gt(),u=ht(),x=pt(),c=(f,m=!0)=>t({to:".",search:f,replace:m}),v=()=>c(f=>({...f,sidepanel:!0})),g=(f,m,b)=>{const h=!!d&&d===f;d&&!h&&Nn(d,{tab:l,mainpanel:o.mainpanel,sidepanel:o.sidepanel});const p=h?null:An(f),S=jt(s.id).id,k=vn({prev:{virtualmcpid:a,tabId:l},virtualMcpId:m,decopilotId:S,savedLayout:p,opts:b,autosendValue:bt});return x(f,()=>k.search,{virtualMcpId:m,view:{tabId:k.tabId}})};return{openSidePanel:v,setTaskId:g,createNewTask:async(f,m,b)=>{const h=crypto.randomUUID(),p=f??u;try{await e?.create({id:h,virtual_mcp_id:p,...m?{branch:m}:{}})}catch{}g(h,p,b)},openTab:r,closeTab:i}}const In=new Set(["/$org/","/$org/home"]);function En(){const t=D.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e={select:Ln},t[0]=e):e=t[0],et(e)}function Ln(t){const e=t.matches.at(-1)?.fullPath;return e!==void 0&&In.has(e)}function Pn(){const t=D.c(52);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e={from:"/shell/$org",shouldThrow:!1},t[0]=e):e=t[0];const o=Qe(e)?.params.org,[l,r]=B.useState(!1),i=Ye(),a=En(),d=o??"";let u;t[1]!==d?(u=Re(d),t[1]=d,t[2]=u):u=t[2];const x=!!o&&a;let c;t[3]!==u||t[4]!==x?(c={...u,enabled:x},t[3]=u,t[4]=x,t[5]=c):c=t[5],ae(c);const{data:v}=X.useSession(),g=v?.user?.id;let w;t[6]!==o||t[7]!==g?(w=o&&g?Xe(g,o):null,t[6]=o,t[7]=g,t[8]=w):w=t[8];const f=w;let m,b;t[9]!==i?(m=()=>{const P=z=>{if(Se(z)&&z.code==="KeyK"){z.preventDefault(),r(!0);return}Se(z)&&z.code==="BracketLeft"&&i.history.canGoBack()&&(z.preventDefault(),i.history.back())};return document.addEventListener("keydown",P),()=>document.removeEventListener("keydown",P)},b=[i],t[9]=i,t[10]=m,t[11]=b):(m=t[10],b=t[11]),B.useEffect(m,b);let h;t[12]!==o?(h=le.activeOrganization(o),t[12]=o,t[13]=h):h=t[13];let p;t[14]!==o||t[15]!==g?(p=async()=>{if(!o)return null;performance.mark("mesh:active-org-fetch:start");const{data:P}=await X.organization.getFullOrganization({query:{organizationSlug:o}}).finally(Dn),z=pe(P);return P&&!z&&localStorage.setItem(Y.lastOrgSlug(),o),g&&P&&tt(g,o,P),P},t[14]=o,t[15]=g,t[16]=p):p=t[16];const S=f?f.data:void 0,k=f?.updatedAt;let j;t[17]!==S||t[18]!==k||t[19]!==h||t[20]!==p?(j={queryKey:h,queryFn:p,initialData:S,initialDataUpdatedAt:k,gcTime:1/0,refetchOnWindowFocus:!1},t[17]=S,t[18]=k,t[19]=h,t[20]=p,t[21]=j):j=t[21];const{data:y}=ke(j),N=y?.id,T=y?.slug,{data:A}=Ot(N,T),_=N??"",O=T??"";let C;t[22]!==_||t[23]!==O?(C=vt({connectionId:kt,orgId:_,orgSlug:O}),t[22]=_,t[23]=O,t[24]=C):C=t[24];const I=!!N&&!!T;let L;if(t[25]!==C||t[26]!==I?(L={...C,enabled:I},t[25]=C,t[26]=I,t[27]=L):L=t[27],ae(L),!y){let P;t[28]===Symbol.for("react.memo_cache_sentinel")?(P=n.jsx(nt,{}),t[28]=P):P=t[28];let z;return t[29]!==o?(z=n.jsx(B.Suspense,{fallback:P,children:n.jsx(Ft,{orgSlug:o})}),t[29]=o,t[30]=z):z=t[30],z}if(pe(y)){localStorage.getItem(Y.lastOrgSlug())===o&&localStorage.removeItem(Y.lastOrgSlug());let P;return t[31]!==y.name?(P=n.jsx(Ze,{orgName:y.name}),t[31]=y.name,t[32]=P):P=t[32],P}if(A?.ssoRequired&&!A.authenticated){let P;return t[33]!==y.id||t[34]!==y.name||t[35]!==y.slug||t[36]!==A.domain?(P=n.jsx(_n,{orgId:y.id,orgSlug:y.slug,orgName:y.name,domain:A.domain}),t[33]=y.id,t[34]=y.name,t[35]=y.slug,t[36]=A.domain,t[37]=P):P=t[37],P}const R=y.logo??null;let M;t[38]!==y||t[39]!==R?(M={...y,logo:R},t[38]=y,t[39]=R,t[40]=M):M=t[40];let q;t[41]!==y?(q=n.jsx(Sn,{activeOrg:y}),t[41]=y,t[42]=q):q=t[42];let ne;t[43]===Symbol.for("react.memo_cache_sentinel")?(ne=n.jsx(st,{}),t[43]=ne):ne=t[43];let se;t[44]===Symbol.for("react.memo_cache_sentinel")?(se=n.jsxs("div",{className:"fixed bottom-6 right-6 z-50 flex w-[min(360px,calc(100vw-3rem))] flex-col gap-3",children:[n.jsx(Zt,{}),n.jsx(un,{})]}),t[44]=se):se=t[44];let Q;t[45]!==l?(Q=n.jsx(nn,{open:l,onOpenChange:r}),t[45]=l,t[46]=Q):Q=t[46];let oe;t[47]===Symbol.for("react.memo_cache_sentinel")?(oe=n.jsx(pn,{}),t[47]=oe):oe=t[47];let ie;return t[48]!==M||t[49]!==q||t[50]!==Q?(ie=n.jsxs(On,{org:M,children:[q,ne,se,Q,oe]}),t[48]=M,t[49]=q,t[50]=Q,t[51]=ie):ie=t[51],ie}function Dn(){performance.mark("mesh:active-org-fetch:end"),performance.measure("mesh:active-org-fetch","mesh:active-org-fetch:start","mesh:active-org-fetch:end")}function $n(){const t=D.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=n.jsx(St,{children:n.jsx(Pn,{})}),t[0]=e):e=t[0],e}const is=Object.freeze(Object.defineProperty({__proto__:null,default:$n,usePanelActions:Cn},Symbol.toStringTag,{value:"Module"}));export{F as K,os as a,ss as f,Se as i,gn as m,is as s,Cn as u};
@@ -1,4 +1,4 @@
1
- import{c as b,x as Q,j as r,k as Z,B as U,Y as g,r as ee,n as M,av as O}from"./index-qCYv4MSE.js";import{b as te,D as se,d as ne,i as re}from"./dialog-Dxe79goo.js";import{i as ie}from"./Zap-phia53Nn.js";import{M as H}from"./markdown-B7Ud7SgT.js";import{n as le}from"./Download01-BDdx-x6g.js";import{k as K,b as oe,l as ae,p as ce}from"./folder-icon-C9fCzh0e.js";import{a as L,s as fe,i as R}from"./ZoomOut-B0fwcMBQ.js";import{a as de}from"./Image01-CdSDKzEr.js";import{F as me}from"./editor-CDDmFeb8.js";import{F as q}from"./file-type-icon-B8SUHUXO.js";import{p as ue,b as j}from"./location-oTTXFrSF.js";function he(s){if(!s||s.includes("\\")||s.includes("..")||s.includes("\0"))return!0;try{const e=decodeURIComponent(s);return!!(e.includes("\\")||e.includes("..")||e.includes("\0"))}catch{return!0}}function pe(s){if(he(s))throw new Error(`Invalid block key: ${s||"(empty)"}`)}function xe(s){try{return decodeURIComponent(s)}catch{return s}}function ge(s){return pe(s),encodeURIComponent(s)}function Ae(s){return`.deco/blocks/${ge(s)}.json`}const He=1e4,we=3;function B(s){return s.trim()?(s.startsWith("/")?s:`/${s}`).replace(/\/+/g,"/"):"/"}function _(s){return s.startsWith("/")?s.slice(1):s}function Ke(s){const e=_(s);return!e||e.includes("..")||e.includes("\\")?!1:e.startsWith(".deco/blocks/")||!e.startsWith("/")&&!e.includes("://")}function W(s){return s.trim()?s.startsWith("/")?s:`/${s}`:"/"}function je(s){const e=W(s);if(e==="/")return"/";const t=e.split("/").filter(Boolean);return t.pop(),t.length===0?"/":`/${t.join("/")}`}function qe(s,e){const t=e.replace(/^\/+|\/+$/g,"");return W(t?`${s==="/"?"":s}/${t}`:s)}function Ve(s,e){return e==="directory"?s:je(s)}function Ye(s){const e=s.trim();return e?e.includes("/")||e.includes("\\")||e.includes("..")||e.includes("\0")?"Name cannot contain /, \\, or ..":null:"Name is required"}function be(s){const e=_(s);return e?e.split("/").filter(Boolean).length:0}function Je(s,e,t,i=!1){return{files:[...new Set([...s,...t.files])],directories:[...new Set([...e,...t.directories??[]])],truncated:i||!!t.truncated}}function Qe(s,e){return be(s)>=we&&!e.has(s)}function Ze(s,e,t=[]){const i=_(s);if(e.includes(i)||t.includes(i))return!0;if(!i)return!1;const n=`${i}/`;return e.some(o=>o.startsWith(n))||t.some(o=>o.startsWith(n))}function et(s){const e=_(s),t=".deco/blocks/";if(!e.startsWith(t)||!e.endsWith(".json"))return null;const i=e.slice(t.length,-5);return xe(i)}function ve(s){if(!s)return"plaintext";const e=s.toLowerCase();return e.endsWith(".tsx")||e.endsWith(".ts")?"typescript":e.endsWith(".jsx")||e.endsWith(".js")||e.endsWith(".mjs")||e.endsWith(".cjs")?"javascript":e.endsWith(".json")?"json":e.endsWith(".md")||e.endsWith(".mdx")?"markdown":e.endsWith(".css")?"css":e.endsWith(".scss")?"scss":e.endsWith(".html")?"html":e.endsWith(".yaml")||e.endsWith(".yml")?"yaml":e.endsWith(".xml")||e.endsWith(".svg")?"xml":e.endsWith(".py")?"python":e.endsWith(".sql")?"sql":e.endsWith(".sh")?"shell":"plaintext"}const ye="#94a3b8";function tt(s){const e=s.toLowerCase();return e.endsWith(".tsx")||e.endsWith(".ts")?{Icon:L,color:"#3b82f6"}:e.endsWith(".jsx")||e.endsWith(".js")||e.endsWith(".mjs")||e.endsWith(".cjs")?{Icon:L,color:"#d9a441"}:e.endsWith(".json")?{Icon:fe,color:"#cb9b3f"}:e.endsWith(".css")||e.endsWith(".scss")?{Icon:L,color:"#06b6d4"}:e.endsWith(".html")||e.endsWith(".xml")?{Icon:L,color:"#f97316"}:/\.(png|jpe?g|gif|webp|avif|ico|svg)$/.test(e)?{Icon:de,color:"#a855f7"}:e.endsWith(".md")||e.endsWith(".mdx")?{Icon:R,color:"#64748b"}:{Icon:R,color:ye}}function st(s){const e=B(s).split("/").filter(Boolean),t=["/"];let i="";for(const n of e.slice(0,-1))i+=`/${n}`,t.push(i);return t}function nt(s,e=[]){const t={path:"/",children:[]},i=new Map,n=c=>{let l=i.get(c.path);return l||(l=new Map,i.set(c.path,l)),l},o=c=>{const f=B(c).split("/").filter(Boolean);let d=t,u="";for(const m of f){u+=`/${m}`;const v=n(d);let h=v.get(m);h?h.kind==="file"&&(h.kind="directory"):(h={name:m,path:u,kind:"directory",children:[]},d.children.push(h),v.set(m,h)),d=h}};for(const c of s){const f=B(c).split("/").filter(Boolean);let d=t,u="";f.forEach((m,v)=>{u+=`/${m}`;const h=v===f.length-1,w=n(d);let x=w.get(m);x||(x={name:m,path:u,kind:h?"file":"directory",children:[]},d.children.push(x),w.set(m,x)),d=x})}for(const c of e)o(W(c));const a=c=>{c.sort((l,f)=>l.kind!==f.kind?l.kind==="directory"?-1:1:l.name.localeCompare(f.name));for(const l of c)l.children.length>0&&a(l.children)};return a(t.children),t.children}function ke(s,e,t=0){const i=[];for(const n of s)if(n.name!==".gitkeep"&&(i.push({node:n,depth:t}),n.kind==="directory"&&n.children.length>0&&e.has(n.path)))for(const o of ke(n.children,e,t+1))i.push(o);return i}function rt(s){const e=[];for(const t of s.split(`
1
+ import{c as b,x as Q,j as r,k as Z,B as U,Y as g,r as ee,n as M,av as O}from"./index-DZLUP-bk.js";import{b as te,D as se,d as ne,i as re}from"./dialog-pwZ4KzZ6.js";import{i as ie}from"./Zap-DBnrIpUC.js";import{M as H}from"./markdown-C1ZA9C8N.js";import{n as le}from"./Download01-C8Yiywz6.js";import{k as K,b as oe,l as ae,p as ce}from"./folder-icon-DpeG2vsd.js";import{a as L,s as fe,i as R}from"./ZoomOut-CVtN6QQg.js";import{a as de}from"./Image01-fT4xR6P_.js";import{F as me}from"./editor-BHb3kJQ5.js";import{F as q}from"./file-type-icon-xQ7VVCet.js";import{p as ue,b as j}from"./location-oTTXFrSF.js";function he(s){if(!s||s.includes("\\")||s.includes("..")||s.includes("\0"))return!0;try{const e=decodeURIComponent(s);return!!(e.includes("\\")||e.includes("..")||e.includes("\0"))}catch{return!0}}function pe(s){if(he(s))throw new Error(`Invalid block key: ${s||"(empty)"}`)}function xe(s){try{return decodeURIComponent(s)}catch{return s}}function ge(s){return pe(s),encodeURIComponent(s)}function Ae(s){return`.deco/blocks/${ge(s)}.json`}const He=1e4,we=3;function B(s){return s.trim()?(s.startsWith("/")?s:`/${s}`).replace(/\/+/g,"/"):"/"}function _(s){return s.startsWith("/")?s.slice(1):s}function Ke(s){const e=_(s);return!e||e.includes("..")||e.includes("\\")?!1:e.startsWith(".deco/blocks/")||!e.startsWith("/")&&!e.includes("://")}function W(s){return s.trim()?s.startsWith("/")?s:`/${s}`:"/"}function je(s){const e=W(s);if(e==="/")return"/";const t=e.split("/").filter(Boolean);return t.pop(),t.length===0?"/":`/${t.join("/")}`}function qe(s,e){const t=e.replace(/^\/+|\/+$/g,"");return W(t?`${s==="/"?"":s}/${t}`:s)}function Ve(s,e){return e==="directory"?s:je(s)}function Ye(s){const e=s.trim();return e?e.includes("/")||e.includes("\\")||e.includes("..")||e.includes("\0")?"Name cannot contain /, \\, or ..":null:"Name is required"}function be(s){const e=_(s);return e?e.split("/").filter(Boolean).length:0}function Je(s,e,t,i=!1){return{files:[...new Set([...s,...t.files])],directories:[...new Set([...e,...t.directories??[]])],truncated:i||!!t.truncated}}function Qe(s,e){return be(s)>=we&&!e.has(s)}function Ze(s,e,t=[]){const i=_(s);if(e.includes(i)||t.includes(i))return!0;if(!i)return!1;const n=`${i}/`;return e.some(o=>o.startsWith(n))||t.some(o=>o.startsWith(n))}function et(s){const e=_(s),t=".deco/blocks/";if(!e.startsWith(t)||!e.endsWith(".json"))return null;const i=e.slice(t.length,-5);return xe(i)}function ve(s){if(!s)return"plaintext";const e=s.toLowerCase();return e.endsWith(".tsx")||e.endsWith(".ts")?"typescript":e.endsWith(".jsx")||e.endsWith(".js")||e.endsWith(".mjs")||e.endsWith(".cjs")?"javascript":e.endsWith(".json")?"json":e.endsWith(".md")||e.endsWith(".mdx")?"markdown":e.endsWith(".css")?"css":e.endsWith(".scss")?"scss":e.endsWith(".html")?"html":e.endsWith(".yaml")||e.endsWith(".yml")?"yaml":e.endsWith(".xml")||e.endsWith(".svg")?"xml":e.endsWith(".py")?"python":e.endsWith(".sql")?"sql":e.endsWith(".sh")?"shell":"plaintext"}const ye="#94a3b8";function tt(s){const e=s.toLowerCase();return e.endsWith(".tsx")||e.endsWith(".ts")?{Icon:L,color:"#3b82f6"}:e.endsWith(".jsx")||e.endsWith(".js")||e.endsWith(".mjs")||e.endsWith(".cjs")?{Icon:L,color:"#d9a441"}:e.endsWith(".json")?{Icon:fe,color:"#cb9b3f"}:e.endsWith(".css")||e.endsWith(".scss")?{Icon:L,color:"#06b6d4"}:e.endsWith(".html")||e.endsWith(".xml")?{Icon:L,color:"#f97316"}:/\.(png|jpe?g|gif|webp|avif|ico|svg)$/.test(e)?{Icon:de,color:"#a855f7"}:e.endsWith(".md")||e.endsWith(".mdx")?{Icon:R,color:"#64748b"}:{Icon:R,color:ye}}function st(s){const e=B(s).split("/").filter(Boolean),t=["/"];let i="";for(const n of e.slice(0,-1))i+=`/${n}`,t.push(i);return t}function nt(s,e=[]){const t={path:"/",children:[]},i=new Map,n=c=>{let l=i.get(c.path);return l||(l=new Map,i.set(c.path,l)),l},o=c=>{const f=B(c).split("/").filter(Boolean);let d=t,u="";for(const m of f){u+=`/${m}`;const v=n(d);let h=v.get(m);h?h.kind==="file"&&(h.kind="directory"):(h={name:m,path:u,kind:"directory",children:[]},d.children.push(h),v.set(m,h)),d=h}};for(const c of s){const f=B(c).split("/").filter(Boolean);let d=t,u="";f.forEach((m,v)=>{u+=`/${m}`;const h=v===f.length-1,w=n(d);let x=w.get(m);x||(x={name:m,path:u,kind:h?"file":"directory",children:[]},d.children.push(x),w.set(m,x)),d=x})}for(const c of e)o(W(c));const a=c=>{c.sort((l,f)=>l.kind!==f.kind?l.kind==="directory"?-1:1:l.name.localeCompare(f.name));for(const l of c)l.children.length>0&&a(l.children)};return a(t.children),t.children}function ke(s,e,t=0){const i=[];for(const n of s)if(n.name!==".gitkeep"&&(i.push({node:n,depth:t}),n.kind==="directory"&&n.children.length>0&&e.has(n.path)))for(const o of ke(n.children,e,t+1))i.push(o);return i}function rt(s){const e=[];for(const t of s.split(`
2
2
  `)){if(!t)continue;const i=t.indexOf(":");if(i<0)continue;const n=t.indexOf(":",i+1);if(n<0)continue;const o=Number.parseInt(t.slice(i+1,n),10);Number.isFinite(o)&&e.push({path:W(t.slice(0,i)),line:o,text:t.slice(n+1)})}return e}function it(s,e,t){const i=e.trim().toLowerCase();if(!i)return[];const n=[];for(const o of s)if((o.split("/").pop()??o).toLowerCase().includes(i)&&(n.push(W(o)),n.length>=t))break;return n}const G=24;function lt(s,e){const t=s.replace(/^\s+/,""),i=e.trim().toLowerCase();if(!i)return{leadingEllipsis:!1,segments:[{text:t,match:!1}]};const n=t.toLowerCase().indexOf(i);if(n<0)return{leadingEllipsis:!1,segments:[{text:t,match:!1}]};const o=n>G,a=o?t.slice(n-G):t,c=a.toLowerCase(),l=[];let f=0;for(;;){const d=c.indexOf(i,f);if(d<0){f<a.length&&l.push({text:a.slice(f),match:!1});break}d>f&&l.push({text:a.slice(f,d),match:!1}),l.push({text:a.slice(d,d+i.length),match:!0}),f=d+i.length}return{leadingEllipsis:o,segments:l}}function ot(s){const e=[],t=new Map;for(const i of s){let n=t.get(i.path);n||(n={path:i.path,matches:[]},t.set(i.path,n),e.push(n)),n.matches.push(i)}return e}function at(s){return s.split(`
3
3
  `).map(e=>e.replace(/^\d+\t/,"")).join(`
4
4
  `)}function Ne(s){const e=b.c(11),{value:t,filename:i}=s,[n]=Q(),o=n.theme==="dark"||n.theme==="system"&&typeof window<"u"&&window.matchMedia("(prefers-color-scheme: dark)").matches;let a;e[0]!==i?(a=ve(i),e[0]=i,e[1]=a):a=e[1];const c=o?"vs-dark":"light";let l;e[2]===Symbol.for("react.memo_cache_sentinel")?(l=r.jsx("div",{className:"flex h-full w-full items-center justify-center",children:r.jsx(Z,{size:20,className:"animate-spin text-muted-foreground"})}),e[2]=l):l=e[2];let f,d;e[3]===Symbol.for("react.memo_cache_sentinel")?(f={enabled:!1},d={top:12,bottom:12},e[3]=f,e[4]=d):(f=e[3],d=e[4]);let u;e[5]===Symbol.for("react.memo_cache_sentinel")?(u={readOnly:!0,domReadOnly:!0,fontSize:13,scrollBeyondLastLine:!1,automaticLayout:!0,lineNumbersMinChars:3,wordWrap:"on",minimap:f,padding:d,renderLineHighlight:"none",scrollbar:{vertical:"auto",horizontal:"auto",verticalScrollbarSize:8,horizontalScrollbarSize:8}},e[5]=u):u=e[5];let m;return e[6]!==i||e[7]!==a||e[8]!==c||e[9]!==t?(m=r.jsx(me,{path:i,language:a,value:t,theme:c,loading:l,options:u},i),e[6]=i,e[7]=a,e[8]=c,e[9]=t,e[10]=m):m=e[10],m}function We(s){return s<1024?`${s} B`:s<1024*1024?`${(s/1024).toFixed(1)} KB`:`${(s/(1024*1024)).toFixed(1)} MB`}const Se=new Set(["png","jpg","jpeg","gif","webp","svg","avif"]),Ce=new Set(["txt","json","csv","tsv","log","yaml","yml","xml","toml","ts","tsx","js","jsx","py","rb","go","rs","java","sh","sql"]),X=2*1024*1024;function Ee(s,e){const t=s.split(".").pop()?.toLowerCase()??"";return Se.has(t)?"image":t==="pdf"?"pdf":t==="html"||t==="htm"?"html":t==="md"||t==="markdown"?e<=X?"markdown":"download":Ce.has(t)&&e<=X?"text":"download"}function Pe(){const s=b.c(2);let e;s[0]===Symbol.for("react.memo_cache_sentinel")?(e=r.jsx(g,{className:"h-6 w-2/3"}),s[0]=e):e=s[0];let t;return s[1]===Symbol.for("react.memo_cache_sentinel")?(t=r.jsx("div",{className:"flex h-full w-full items-center justify-center",children:r.jsxs("div",{className:"flex w-3/4 max-w-md flex-col gap-3 p-6",children:[e,r.jsxs("div",{className:"flex flex-col gap-1.5",children:[r.jsx(g,{className:"h-3 w-full"}),r.jsx(g,{className:"h-3 w-5/6"}),r.jsx(g,{className:"h-3 w-2/3"})]})]})}),s[1]=t):t=s[1],t}function V(s){const e=b.c(20),{file:t,note:i}=s;let n;e[0]!==t.filename?(n=r.jsx(q,{filename:t.filename,className:"h-12 w-10"}),e[0]=t.filename,e[1]=n):n=e[1];let o;e[2]!==t.filename?(o=r.jsx("span",{className:"text-sm font-medium text-foreground",children:t.filename}),e[2]=t.filename,e[3]=o):o=e[3];let a;e[4]!==t.size?(a=We(t.size),e[4]=t.size,e[5]=a):a=e[5];const c=i?` · ${i}`:"";let l;e[6]!==a||e[7]!==c?(l=r.jsxs("span",{className:"text-xs text-muted-foreground",children:[a,c]}),e[6]=a,e[7]=c,e[8]=l):l=e[8];let f;e[9]!==o||e[10]!==l?(f=r.jsxs("div",{className:"flex flex-col items-center gap-0.5",children:[o,l]}),e[9]=o,e[10]=l,e[11]=f):f=e[11];let d;e[12]===Symbol.for("react.memo_cache_sentinel")?(d=r.jsx(le,{size:14}),e[12]=d):d=e[12];let u;e[13]!==t.downloadUrl||e[14]!==t.filename?(u=r.jsx(U,{asChild:!0,variant:"outline",size:"sm",children:r.jsxs("a",{href:t.downloadUrl,download:t.filename,children:[d,"Download"]})}),e[13]=t.downloadUrl,e[14]=t.filename,e[15]=u):u=e[15];let m;return e[16]!==n||e[17]!==f||e[18]!==u?(m=r.jsx("div",{className:"flex h-full w-full items-center justify-center",children:r.jsxs("div",{className:"flex flex-col items-center gap-3 rounded-xl border border-border bg-muted/30 px-10 py-8",children:[n,f,u]})}),e[16]=n,e[17]=f,e[18]=u,e[19]=m):m=e[19],m}function A(s){const e=b.c(9),{file:t,markdown:i}=s,{data:n,isPending:o,isError:a}=K(t.downloadUrl);if(o){let l;return e[0]===Symbol.for("react.memo_cache_sentinel")?(l=r.jsx(Pe,{}),e[0]=l):l=e[0],l}if(a||!n){let l;return e[1]!==t?(l=r.jsx(V,{file:t,note:"preview unavailable"}),e[1]=t,e[2]=l):l=e[2],l}if(i){const l=`file-preview-${t.key}`;let f;return e[3]!==n||e[4]!==l?(f=r.jsx("div",{className:"h-full overflow-y-auto",children:r.jsx("div",{className:"prose prose-sm dark:prose-invert mx-auto max-w-3xl px-6 py-6",children:r.jsx(H,{id:l,text:n})})}),e[3]=n,e[4]=l,e[5]=f):f=e[5],f}let c;return e[6]!==n||e[7]!==t.filename?(c=r.jsx(Ne,{value:n,filename:t.filename}),e[6]=n,e[7]=t.filename,e[8]=c):c=e[8],c}function ze(s){const e=b.c(15),{file:t}=s;switch(Ee(t.filename,t.size)){case"image":{let n;return e[0]!==t.downloadUrl||e[1]!==t.filename?(n=r.jsx("div",{className:"flex h-full w-full items-center justify-center overflow-auto bg-muted/30 p-4",children:r.jsx("img",{src:t.downloadUrl,alt:t.filename,className:"max-h-full max-w-full rounded-lg object-contain"})}),e[0]=t.downloadUrl,e[1]=t.filename,e[2]=n):n=e[2],n}case"pdf":{let n;return e[3]!==t.downloadUrl||e[4]!==t.filename?(n=r.jsx("iframe",{src:t.downloadUrl,title:t.filename,className:"block h-full w-full bg-white"}),e[3]=t.downloadUrl,e[4]=t.filename,e[5]=n):n=e[5],n}case"html":{let n;return e[6]!==t.downloadUrl||e[7]!==t.filename?(n=r.jsx("iframe",{src:t.downloadUrl,title:t.filename,sandbox:"allow-scripts allow-downloads",className:"block h-full w-full bg-white"}),e[6]=t.downloadUrl,e[7]=t.filename,e[8]=n):n=e[8],n}case"markdown":{let n;return e[9]!==t?(n=r.jsx(A,{file:t,markdown:!0}),e[9]=t,e[10]=n):n=e[10],n}case"text":{let n;return e[11]!==t?(n=r.jsx(A,{file:t,markdown:!1}),e[11]=t,e[12]=n):n=e[12],n}default:{let n;return e[13]!==t?(n=r.jsx(V,{file:t}),e[13]=t,e[14]=n):n=e[14],n}}}function Fe(s){const e=b.c(18),{skillPath:t,onClose:i,variant:n}=s,o=ue(t),{volume:a,dirPath:c}=o,l=oe(),f=l(a??"",`${c}/SKILL.md`),d=K(f),u=ae(a??"",c);let m;e[0]!==c?(m=j(c),e[0]=c,e[1]=m):m=e[1];const v=m;let h;e[2]!==d.data?(h=d.data?ce(d.data):null,e[2]=d.data,e[3]=h):h=e[3];const w=h,x=Le;let C;e[4]===Symbol.for("react.memo_cache_sentinel")?(C=(p,S)=>x(p.path)?-1:x(S.path)?1:j(p.path).localeCompare(j(S.path)),e[4]=C):C=e[4];const D=(u.data??[]).filter($e).sort(C),[I,Y]=ee.useState(null),y=I===null?null:D.find(p=>p.path===I)??null,E=w?.name??v;let P;e[5]===Symbol.for("react.memo_cache_sentinel")?(P=r.jsx("div",{className:"flex size-9 shrink-0 items-center justify-center rounded-full bg-primary/10 text-primary",children:r.jsx(ie,{size:18})}),e[5]=P):P=e[5];let k;e[6]!==E||e[7]!==n?(k=n==="dialog"?r.jsx(ne,{className:"flex-1 truncate text-base font-medium text-foreground",children:E}):r.jsx("span",{className:"flex-1 truncate text-base font-medium text-foreground",children:E}),e[6]=E,e[7]=n,e[8]=k):k=e[8];let N;e[9]!==i||e[10]!==n?(N=n==="dialog"?r.jsx(re,{asChild:!0,children:r.jsx(U,{variant:"ghost",size:"icon",className:"size-8 shrink-0",children:r.jsx(O,{size:16})})}):r.jsx(U,{variant:"ghost",size:"icon",className:"size-8 shrink-0",onClick:i,children:r.jsx(O,{size:16})}),e[9]=i,e[10]=n,e[11]=N):N=e[11];let z;e[12]!==k||e[13]!==N?(z=r.jsxs("div",{className:"flex shrink-0 items-center gap-3 border-b border-border px-4 py-3",children:[P,k,N]}),e[12]=k,e[13]=N,e[14]=z):z=e[14];let F;e[15]===Symbol.for("react.memo_cache_sentinel")?(F=r.jsx("p",{className:"px-2 py-1.5 text-sm font-medium text-foreground",children:"Files"}),e[15]=F):F=e[15];const J="relative flex min-w-0 flex-1 flex-col overflow-y-auto",T=y?r.jsx(ze,{file:{key:y.path,filename:j(y.path),size:y.size,downloadUrl:l(a??"",y.path)}}):d.isPending?r.jsxs("div",{className:"flex flex-col gap-2 p-6",children:[r.jsx(g,{className:"h-4 w-1/3"}),r.jsx(g,{className:"h-3 w-full"}),r.jsx(g,{className:"h-3 w-5/6"}),r.jsx(g,{className:"h-3 w-2/3"})]}):d.isError||!w?r.jsx("div",{className:"flex h-full items-center justify-center text-sm text-muted-foreground",children:"This skill is no longer available."}):r.jsxs(r.Fragment,{children:[r.jsxs("div",{className:"flex flex-col gap-4 border-b border-border p-6",children:[r.jsx("p",{className:"text-sm font-medium text-foreground",children:"Description"}),r.jsx("p",{className:"text-base text-muted-foreground",children:w.description??"Claude Code skill"})]}),r.jsx("div",{className:"prose prose-sm dark:prose-invert max-w-none p-6",children:r.jsx(H,{id:`skill-preview-${t}`,text:w.body})})]});let $;return e[16]!==T?($=r.jsx("div",{className:J,children:T}),e[16]=T,e[17]=$):$=e[17],r.jsxs(r.Fragment,{children:[z,r.jsxs("div",{className:"flex min-h-0 flex-1",children:[r.jsxs("div",{className:"flex w-[220px] shrink-0 flex-col gap-1 overflow-y-auto border-r border-border bg-muted p-3",children:[F,u.isPending?r.jsx(g,{className:"mx-2 h-4 w-24"}):D.map(p=>{const S=x(p.path)?y===null:I===p.path;return r.jsxs("button",{type:"button",onClick:()=>Y(x(p.path)?null:p.path),className:M("flex items-center gap-2.5 rounded-lg px-2 py-1.5 text-left",S?"bg-background shadow-sm":"hover:bg-muted/60"),children:[r.jsx(q,{filename:j(p.path),className:"h-6 w-5 shrink-0"}),r.jsx("span",{className:M("truncate text-sm",S?"text-foreground":"text-muted-foreground"),children:j(p.path)})]},p.path)})]}),$]})]})}function $e(s){return s.kind==="file"}function Le(s){return j(s)==="SKILL.md"}function ct(s){const e=b.c(8),{skillPath:t,onClose:i}=s;let n;e[0]!==i?(n=c=>{c||i()},e[0]=i,e[1]=n):n=e[1];let o;e[2]!==i||e[3]!==t?(o=r.jsx(te,{className:"flex h-[88vh] w-[94vw] max-w-none! flex-col gap-0 overflow-hidden p-0 sm:max-w-5xl!",closeButtonClassName:"hidden",children:r.jsx(Fe,{skillPath:t,onClose:i,variant:"dialog"})}),e[2]=i,e[3]=t,e[4]=o):o=e[4];let a;return e[5]!==n||e[6]!==o?(a=r.jsx(se,{open:!0,onOpenChange:n,children:o}),e[5]=n,e[6]=o,e[7]=a):a=e[7],a}export{Je as A,we as E,Pe as F,ct as S,pe as a,ze as b,xe as c,Ae as d,He as e,We as f,ve as g,nt as h,Ke as i,ke as j,ot as k,Ve as l,W as m,tt as n,je as o,st as p,lt as q,Qe as r,at as s,_ as t,qe as u,Ye as v,Ze as w,it as x,rt as y,et as z};
@@ -1 +1 @@
1
- import{b as te,H as se,p as oe,r as T,j as t,B as Q,P as L,Y as ae,D as ce,t as w,c as ie,n as de,K as q,b8 as me}from"./index-qCYv4MSE.js";import{i as ue}from"./DotsVertical-Cvjwtvf0.js";import{i as pe}from"./GitBranch01-B2HQZMnv.js";import{a as ge}from"./Package-Bnouug7j.js";import{s as fe}from"./Trash01-DeEhE87T.js";import{i as he}from"./Upload01-a-uHONMh.js";import{i as le}from"./Zap-phia53Nn.js";import{S as xe}from"./search-input-DXwr2899.js";import{c as je,D as ke,b as ve,a as ye}from"./dropdown-menu-PmWQu__b.js";import{A as Se,a as be,b as we,c as De,d as Ce,e as Ne,f as Pe,g as Ee}from"./alert-dialog-sgAetjem.js";import{E as J}from"./empty-state-C8ZR6dk7.js";import{C as Ae}from"./collection-tabs-wE5AjIxo.js";import{p as Te,q as Me,u as Ie,r as Oe,F as ze}from"./folder-icon-C9fCzh0e.js";import{H as V,d as $e}from"./location-oTTXFrSF.js";import{S as Fe}from"./skill-preview-DzcAaN-A.js";import"./SearchMd-BVz5rgMO.js";import"./Check-CZ_g5EHO.js";import"./ChevronRight-CNbZXCEK.js";import"./badge-CeB87lwb.js";import"./Eye-DsnJ6Hdj.js";import"./dialog-Dxe79goo.js";import"./markdown-B7Ud7SgT.js";import"./Copy01-HfyvilSG.js";import"./Download01-BDdx-x6g.js";import"./ZoomOut-B0fwcMBQ.js";import"./use-panel-navigate-DUpzUMxR.js";import"./use-destination-route-DAn4XmeU.js";import"./Image01-CdSDKzEr.js";import"./editor-CDDmFeb8.js";import"./file-type-icon-B8SUHUXO.js";const Z=200,Re=new Set(["node_modules","__pycache__"]);function U(s){const[,...e]=s.webkitRelativePath.split("/");return e.length>0?e.join("/"):s.name}function Le(s){return U(s).split("/").every(e=>!e.startsWith(".")&&!Re.has(e))}function _e(s){return s.trim().toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"")||"skill"}function Be(s,e){const l=new Map;for(const r of s){const c=U(r).split("/");c.pop();const a=["skills",e,...c].join("/");l.set(a,[...l.get(a)??[],r])}return l}async function Ke(s,e){const r=(await Promise.allSettled([...s].map(([c,a])=>e({dir:c,files:a})))).find(c=>c.status==="rejected");if(r)throw r.reason}function He(s,e){const l=Te(e),r=`skills/${s}`;return{id:`home/${r}`,name:l.name??s,description:l.description,source:"home",volume:V,path:r,sandboxPath:`org/${V}/${r}`}}const _="*";function B(s){return s.volume==="home"}function re(s,e){const l=s.indexOf(":");return l===-1?{label:e,glyph:le}:{label:s.slice(l+1),glyph:s.startsWith("repo:")?pe:ge}}function qe(s){const e=ie.c(48),{entry:l,pending:r,onOpen:c,onDelete:a}=s,o=te(),{org:u}=se();let D;e[0]!==l.source||e[1]!==u.name?(D=re(l.source,u.name),e[0]=l.source,e[1]=u.name,e[2]=D):D=e[2];const{label:M,glyph:O}=D;let C;e[3]!==l?(C=B(l),e[3]=l,e[4]=C):C=e[4];const z=C,N=r?"opacity-60":"hover:bg-muted/50";let f;e[5]!==N?(f=de("relative transition-colors group overflow-hidden flex flex-col h-full",N),e[5]=N,e[6]=f):f=e[6];let d;e[7]!==l.name||e[8]!==c||e[9]!==r?(d=!r&&t.jsx("button",{type:"button",onClick:c,className:"absolute inset-0 z-0","aria-label":l.name}),e[7]=l.name,e[8]=c,e[9]=r,e[10]=d):d=e[10];const P=z?"default":"system",$=!z;let h;e[11]!==O||e[12]!==P||e[13]!==$?(h=t.jsx(ze,{glyph:O,tone:P,readOnly:$,className:"size-8 shrink-0"}),e[11]=O,e[12]=P,e[13]=$,e[14]=h):h=e[14];let x;e[15]!==a||e[16]!==o?(x=a&&t.jsx("div",{className:"relative z-10 pointer-events-auto transition-opacity sm:opacity-0 sm:group-hover:opacity-100",children:t.jsxs(je,{children:[t.jsx(ke,{asChild:!0,children:t.jsx(Q,{variant:"ghost",size:"sm",className:"h-8 w-8 p-0",children:t.jsx(ue,{size:16})})}),t.jsx(ve,{align:"end",children:t.jsxs(ye,{variant:"destructive",onClick:K=>{K.stopPropagation(),a()},children:[t.jsx(fe,{size:16}),o("settings.skills.deleteButton")]})})]})}),e[15]=a,e[16]=o,e[17]=x):x=e[17];let j;e[18]!==h||e[19]!==x?(j=t.jsxs("div",{className:"flex items-start justify-between",children:[h,x]}),e[18]=h,e[19]=x,e[20]=j):j=e[20];let b;e[21]!==l.name?(b=t.jsx("h3",{className:"text-sm font-medium text-foreground truncate",children:l.name}),e[21]=l.name,e[22]=b):b=e[22];let k;e[23]!==l.description||e[24]!==o?(k=l.description||o("settings.skills.noDescription"),e[23]=l.description,e[24]=o,e[25]=k):k=e[25];let m;e[26]!==k?(m=t.jsx("p",{className:"text-sm text-muted-foreground line-clamp-2",children:k}),e[26]=k,e[27]=m):m=e[27];let v;e[28]!==b||e[29]!==m?(v=t.jsxs("div",{className:"flex flex-col gap-1",children:[b,m]}),e[28]=b,e[29]=m,e[30]=v):v=e[30];let p;e[31]!==j||e[32]!==v?(p=t.jsxs("div",{className:"flex flex-col gap-3 p-4.5",children:[j,v]}),e[31]=j,e[32]=v,e[33]=p):p=e[33];let y;e[34]!==M||e[35]!==r||e[36]!==o?(y=r?o("settings.skills.importing"):M,e[34]=M,e[35]=r,e[36]=o,e[37]=y):y=e[37];let g;e[38]!==y?(g=t.jsx("div",{className:"border-t border-border mt-auto",children:t.jsx("div",{className:"h-10 flex items-center px-4.5",children:t.jsx("p",{className:"text-xs text-muted-foreground truncate",children:y})})}),e[38]=y,e[39]=g):g=e[39];let S;e[40]!==p||e[41]!==g?(S=t.jsxs("div",{className:"flex flex-col flex-1 pointer-events-none",children:[p,g]}),e[40]=p,e[41]=g,e[42]=S):S=e[42];let I;return e[43]!==r||e[44]!==S||e[45]!==f||e[46]!==d?(I=t.jsxs(me,{"aria-busy":r,className:f,children:[d,S]}),e[43]=r,e[44]=S,e[45]=f,e[46]=d,e[47]=I):I=e[47],I}function ee(s){const e=ie.c(2),{children:l}=s;let r;return e[0]!==l?(r=t.jsx("div",{className:"grid grid-cols-1 @lg:grid-cols-2 @4xl:grid-cols-3 @6xl:grid-cols-4 gap-4",children:l}),e[0]=l,e[1]=r):r=e[1],r}function yt(){const s=te(),{org:e}=se(),l=Me(),{remove:r,upload:c}=Ie("home"),a=oe(),o=T.useRef(null),[u,D]=T.useState(""),[M,O]=T.useState(_),[C,z]=T.useState(!1),[N,f]=T.useState(null),[d,P]=T.useState(null),[$,h]=T.useState(null),x=()=>{a.invalidateQueries({queryKey:q.slashSkills(e.id)}),a.invalidateQueries({queryKey:q.orgFsSkills(e.id)})},j=i=>a.setQueryData(q.slashSkills(e.id),n=>i(n??[]));async function b(i){const n=[...i??[]];if(o.current&&(o.current.value=""),n.length===0)return;const E=n[0]?.webkitRelativePath??"";if(!E){w.error(s("settings.skills.importNeedsFolder"));return}const H=E.split("/")[0]??"",R=n.filter(Le),W=R.find(A=>U(A)==="SKILL.md");if(!W){w.error(s("settings.skills.importMissingSkillMd"));return}if(R.length>Z){w.error(s("settings.skills.importTooManyFiles",{count:String(R.length),max:String(Z)}));return}const F=_e(H),Y=`skills/${F}`;let X=!1;z(!0);try{if(await Oe(e.slug,"home",Y)){w.error(s("settings.skills.importSlugTaken",{slug:F}));return}X=!0;const A=He(F,await W.text());j(ne=>[A,...ne]),h(A.id),await Ke(Be(R,F),c.mutateAsync),w.success(s("settings.skills.importSuccess",{name:F}))}catch(A){X&&await r.mutateAsync(Y).catch(()=>{}),w.error(A instanceof Error?A.message:s("settings.skills.importError"))}finally{h(null),x(),z(!1)}}const k=u.toLowerCase(),m=(l.data??[]).filter(i=>i.name.toLowerCase().includes(k)||(i.description??"").toLowerCase().includes(k)).sort((i,n)=>Number(B(n))-Number(B(i))||i.name.localeCompare(n.name)),v=new Set((l.data??[]).map(i=>i.source)),p=new Map;for(const i of m)p.set(i.source,(p.get(i.source)??0)+1);const y=[{id:_,label:s("settings.skills.filterAll"),count:m.length},...[...v].map(i=>({id:i,label:re(i,e.name).label,count:p.get(i)??0}))],g=v.has(M)?M:_,S=g===_?m:m.filter(i=>i.source===g),I=i=>f($e(i.volume,i.path)),K=async()=>{if(!d)return;const{id:i,path:n}=d;P(null),j(E=>E.filter(H=>H.id!==i));try{await r.mutateAsync(n),w.success(s("settings.skills.deleteSuccess"))}catch(E){w.error(E instanceof Error?E.message:s("settings.skills.deleteError"))}finally{x()}},G=t.jsxs(Q,{size:"sm",disabled:C,onClick:()=>o.current?.click(),children:[t.jsx(he,{size:14}),s(C?"settings.skills.importing":"settings.skills.importButton")]});return t.jsxs(L,{children:[t.jsx(L.Content,{children:t.jsx(L.Body,{children:t.jsxs("div",{className:"flex flex-col gap-6",children:[t.jsx(L.Title,{children:s("settings.skills.pageTitle")}),t.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[t.jsx(xe,{value:u,onChange:D,placeholder:s("settings.skills.searchPlaceholder"),className:"w-full md:w-[375px]",onKeyDown:i=>{i.key==="Escape"&&(D(""),i.target.blur())}}),G,t.jsx("input",{ref:o,type:"file",multiple:!0,webkitdirectory:"",className:"hidden",onChange:i=>{b(i.target.files)}})]}),y.length>2&&t.jsx(Ae,{tabs:y,activeTab:g,onTabChange:O}),l.isPending?t.jsx("div",{className:"@container",children:t.jsx(ee,{children:Array.from({length:8},(i,n)=>t.jsx(ae,{className:"h-[168px] rounded-xl"},n))})}):l.isError?t.jsx("div",{className:"flex items-center justify-center py-20",children:t.jsx(J,{image:t.jsx(ce,{size:48,className:"text-muted-foreground"}),title:s("settings.skills.errorTitle"),description:l.error instanceof Error?l.error.message:s("settings.skills.errorDescription"),actions:t.jsx(Q,{size:"sm",variant:"outline",onClick:()=>{l.refetch()},children:s("settings.skills.retry")})})}):S.length===0?t.jsx("div",{className:"flex items-center justify-center py-20",children:t.jsx(J,{image:t.jsx(le,{size:48,className:"text-muted-foreground"}),title:s(u?"settings.skills.noResultsTitle":"settings.skills.emptyTitle"),description:u?s("settings.skills.noResultsDescription",{search:u}):s("settings.skills.emptyDescription"),actions:!u&&G})}):t.jsx("div",{className:"@container",children:t.jsx(ee,{children:S.map(i=>{const n=i.id===$;return t.jsx(qe,{entry:i,pending:n,onOpen:()=>I(i),onDelete:B(i)&&!n?()=>P(i):void 0},i.id)})})})]})})}),N&&t.jsx(Fe,{skillPath:N,onClose:()=>f(null)},N),t.jsx(Se,{open:d!==null,onOpenChange:i=>!i&&P(null),children:t.jsxs(be,{children:[t.jsxs(we,{children:[t.jsx(De,{children:s("settings.skills.deleteDialogTitle")}),t.jsx(Ce,{children:s("settings.skills.deleteDialogDescription",{name:d?.name??""})})]}),t.jsxs(Ne,{children:[t.jsx(Pe,{children:s("settings.skills.cancel")}),t.jsx(Ee,{onClick:K,className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",children:s("settings.skills.deleteButton")})]})]})})]})}export{yt as default};
1
+ import{b as te,H as se,p as oe,r as T,j as t,B as Q,P as L,Y as ae,D as ce,t as w,c as ie,n as de,K as q,b8 as me}from"./index-DZLUP-bk.js";import{i as ue}from"./DotsVertical-BVchZPc_.js";import{i as pe}from"./GitBranch01-ByUdctAW.js";import{a as ge}from"./Package-CHpW5VM0.js";import{s as fe}from"./Trash01-Bji2bWWh.js";import{i as he}from"./Upload01-CYRB-7yG.js";import{i as le}from"./Zap-DBnrIpUC.js";import{S as xe}from"./search-input-CXMFw9Ub.js";import{c as je,D as ke,b as ve,a as ye}from"./dropdown-menu-C16L90Tz.js";import{A as Se,a as be,b as we,c as De,d as Ce,e as Ne,f as Pe,g as Ee}from"./alert-dialog-C1vr7a0B.js";import{E as J}from"./empty-state-DvA7VyTt.js";import{C as Ae}from"./collection-tabs-Ir5Tsafl.js";import{p as Te,q as Me,u as Ie,r as Oe,F as ze}from"./folder-icon-DpeG2vsd.js";import{H as V,d as $e}from"./location-oTTXFrSF.js";import{S as Fe}from"./skill-preview-CyY0OP_z.js";import"./SearchMd-bD349BM3.js";import"./Check-DzHuFHoL.js";import"./ChevronRight-DtOnXnjv.js";import"./badge-CFKeX0mn.js";import"./Eye-WB67QJ1C.js";import"./dialog-pwZ4KzZ6.js";import"./markdown-C1ZA9C8N.js";import"./Copy01-BRPiRRUQ.js";import"./Download01-C8Yiywz6.js";import"./ZoomOut-CVtN6QQg.js";import"./use-panel-navigate-C7_AOzBX.js";import"./use-destination-route-CgRHxPyq.js";import"./Image01-fT4xR6P_.js";import"./editor-BHb3kJQ5.js";import"./file-type-icon-xQ7VVCet.js";const Z=200,Re=new Set(["node_modules","__pycache__"]);function U(s){const[,...e]=s.webkitRelativePath.split("/");return e.length>0?e.join("/"):s.name}function Le(s){return U(s).split("/").every(e=>!e.startsWith(".")&&!Re.has(e))}function _e(s){return s.trim().toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"")||"skill"}function Be(s,e){const l=new Map;for(const r of s){const c=U(r).split("/");c.pop();const a=["skills",e,...c].join("/");l.set(a,[...l.get(a)??[],r])}return l}async function Ke(s,e){const r=(await Promise.allSettled([...s].map(([c,a])=>e({dir:c,files:a})))).find(c=>c.status==="rejected");if(r)throw r.reason}function He(s,e){const l=Te(e),r=`skills/${s}`;return{id:`home/${r}`,name:l.name??s,description:l.description,source:"home",volume:V,path:r,sandboxPath:`org/${V}/${r}`}}const _="*";function B(s){return s.volume==="home"}function re(s,e){const l=s.indexOf(":");return l===-1?{label:e,glyph:le}:{label:s.slice(l+1),glyph:s.startsWith("repo:")?pe:ge}}function qe(s){const e=ie.c(48),{entry:l,pending:r,onOpen:c,onDelete:a}=s,o=te(),{org:u}=se();let D;e[0]!==l.source||e[1]!==u.name?(D=re(l.source,u.name),e[0]=l.source,e[1]=u.name,e[2]=D):D=e[2];const{label:M,glyph:O}=D;let C;e[3]!==l?(C=B(l),e[3]=l,e[4]=C):C=e[4];const z=C,N=r?"opacity-60":"hover:bg-muted/50";let f;e[5]!==N?(f=de("relative transition-colors group overflow-hidden flex flex-col h-full",N),e[5]=N,e[6]=f):f=e[6];let d;e[7]!==l.name||e[8]!==c||e[9]!==r?(d=!r&&t.jsx("button",{type:"button",onClick:c,className:"absolute inset-0 z-0","aria-label":l.name}),e[7]=l.name,e[8]=c,e[9]=r,e[10]=d):d=e[10];const P=z?"default":"system",$=!z;let h;e[11]!==O||e[12]!==P||e[13]!==$?(h=t.jsx(ze,{glyph:O,tone:P,readOnly:$,className:"size-8 shrink-0"}),e[11]=O,e[12]=P,e[13]=$,e[14]=h):h=e[14];let x;e[15]!==a||e[16]!==o?(x=a&&t.jsx("div",{className:"relative z-10 pointer-events-auto transition-opacity sm:opacity-0 sm:group-hover:opacity-100",children:t.jsxs(je,{children:[t.jsx(ke,{asChild:!0,children:t.jsx(Q,{variant:"ghost",size:"sm",className:"h-8 w-8 p-0",children:t.jsx(ue,{size:16})})}),t.jsx(ve,{align:"end",children:t.jsxs(ye,{variant:"destructive",onClick:K=>{K.stopPropagation(),a()},children:[t.jsx(fe,{size:16}),o("settings.skills.deleteButton")]})})]})}),e[15]=a,e[16]=o,e[17]=x):x=e[17];let j;e[18]!==h||e[19]!==x?(j=t.jsxs("div",{className:"flex items-start justify-between",children:[h,x]}),e[18]=h,e[19]=x,e[20]=j):j=e[20];let b;e[21]!==l.name?(b=t.jsx("h3",{className:"text-sm font-medium text-foreground truncate",children:l.name}),e[21]=l.name,e[22]=b):b=e[22];let k;e[23]!==l.description||e[24]!==o?(k=l.description||o("settings.skills.noDescription"),e[23]=l.description,e[24]=o,e[25]=k):k=e[25];let m;e[26]!==k?(m=t.jsx("p",{className:"text-sm text-muted-foreground line-clamp-2",children:k}),e[26]=k,e[27]=m):m=e[27];let v;e[28]!==b||e[29]!==m?(v=t.jsxs("div",{className:"flex flex-col gap-1",children:[b,m]}),e[28]=b,e[29]=m,e[30]=v):v=e[30];let p;e[31]!==j||e[32]!==v?(p=t.jsxs("div",{className:"flex flex-col gap-3 p-4.5",children:[j,v]}),e[31]=j,e[32]=v,e[33]=p):p=e[33];let y;e[34]!==M||e[35]!==r||e[36]!==o?(y=r?o("settings.skills.importing"):M,e[34]=M,e[35]=r,e[36]=o,e[37]=y):y=e[37];let g;e[38]!==y?(g=t.jsx("div",{className:"border-t border-border mt-auto",children:t.jsx("div",{className:"h-10 flex items-center px-4.5",children:t.jsx("p",{className:"text-xs text-muted-foreground truncate",children:y})})}),e[38]=y,e[39]=g):g=e[39];let S;e[40]!==p||e[41]!==g?(S=t.jsxs("div",{className:"flex flex-col flex-1 pointer-events-none",children:[p,g]}),e[40]=p,e[41]=g,e[42]=S):S=e[42];let I;return e[43]!==r||e[44]!==S||e[45]!==f||e[46]!==d?(I=t.jsxs(me,{"aria-busy":r,className:f,children:[d,S]}),e[43]=r,e[44]=S,e[45]=f,e[46]=d,e[47]=I):I=e[47],I}function ee(s){const e=ie.c(2),{children:l}=s;let r;return e[0]!==l?(r=t.jsx("div",{className:"grid grid-cols-1 @lg:grid-cols-2 @4xl:grid-cols-3 @6xl:grid-cols-4 gap-4",children:l}),e[0]=l,e[1]=r):r=e[1],r}function yt(){const s=te(),{org:e}=se(),l=Me(),{remove:r,upload:c}=Ie("home"),a=oe(),o=T.useRef(null),[u,D]=T.useState(""),[M,O]=T.useState(_),[C,z]=T.useState(!1),[N,f]=T.useState(null),[d,P]=T.useState(null),[$,h]=T.useState(null),x=()=>{a.invalidateQueries({queryKey:q.slashSkills(e.id)}),a.invalidateQueries({queryKey:q.orgFsSkills(e.id)})},j=i=>a.setQueryData(q.slashSkills(e.id),n=>i(n??[]));async function b(i){const n=[...i??[]];if(o.current&&(o.current.value=""),n.length===0)return;const E=n[0]?.webkitRelativePath??"";if(!E){w.error(s("settings.skills.importNeedsFolder"));return}const H=E.split("/")[0]??"",R=n.filter(Le),W=R.find(A=>U(A)==="SKILL.md");if(!W){w.error(s("settings.skills.importMissingSkillMd"));return}if(R.length>Z){w.error(s("settings.skills.importTooManyFiles",{count:String(R.length),max:String(Z)}));return}const F=_e(H),Y=`skills/${F}`;let X=!1;z(!0);try{if(await Oe(e.slug,"home",Y)){w.error(s("settings.skills.importSlugTaken",{slug:F}));return}X=!0;const A=He(F,await W.text());j(ne=>[A,...ne]),h(A.id),await Ke(Be(R,F),c.mutateAsync),w.success(s("settings.skills.importSuccess",{name:F}))}catch(A){X&&await r.mutateAsync(Y).catch(()=>{}),w.error(A instanceof Error?A.message:s("settings.skills.importError"))}finally{h(null),x(),z(!1)}}const k=u.toLowerCase(),m=(l.data??[]).filter(i=>i.name.toLowerCase().includes(k)||(i.description??"").toLowerCase().includes(k)).sort((i,n)=>Number(B(n))-Number(B(i))||i.name.localeCompare(n.name)),v=new Set((l.data??[]).map(i=>i.source)),p=new Map;for(const i of m)p.set(i.source,(p.get(i.source)??0)+1);const y=[{id:_,label:s("settings.skills.filterAll"),count:m.length},...[...v].map(i=>({id:i,label:re(i,e.name).label,count:p.get(i)??0}))],g=v.has(M)?M:_,S=g===_?m:m.filter(i=>i.source===g),I=i=>f($e(i.volume,i.path)),K=async()=>{if(!d)return;const{id:i,path:n}=d;P(null),j(E=>E.filter(H=>H.id!==i));try{await r.mutateAsync(n),w.success(s("settings.skills.deleteSuccess"))}catch(E){w.error(E instanceof Error?E.message:s("settings.skills.deleteError"))}finally{x()}},G=t.jsxs(Q,{size:"sm",disabled:C,onClick:()=>o.current?.click(),children:[t.jsx(he,{size:14}),s(C?"settings.skills.importing":"settings.skills.importButton")]});return t.jsxs(L,{children:[t.jsx(L.Content,{children:t.jsx(L.Body,{children:t.jsxs("div",{className:"flex flex-col gap-6",children:[t.jsx(L.Title,{children:s("settings.skills.pageTitle")}),t.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-3",children:[t.jsx(xe,{value:u,onChange:D,placeholder:s("settings.skills.searchPlaceholder"),className:"w-full md:w-[375px]",onKeyDown:i=>{i.key==="Escape"&&(D(""),i.target.blur())}}),G,t.jsx("input",{ref:o,type:"file",multiple:!0,webkitdirectory:"",className:"hidden",onChange:i=>{b(i.target.files)}})]}),y.length>2&&t.jsx(Ae,{tabs:y,activeTab:g,onTabChange:O}),l.isPending?t.jsx("div",{className:"@container",children:t.jsx(ee,{children:Array.from({length:8},(i,n)=>t.jsx(ae,{className:"h-[168px] rounded-xl"},n))})}):l.isError?t.jsx("div",{className:"flex items-center justify-center py-20",children:t.jsx(J,{image:t.jsx(ce,{size:48,className:"text-muted-foreground"}),title:s("settings.skills.errorTitle"),description:l.error instanceof Error?l.error.message:s("settings.skills.errorDescription"),actions:t.jsx(Q,{size:"sm",variant:"outline",onClick:()=>{l.refetch()},children:s("settings.skills.retry")})})}):S.length===0?t.jsx("div",{className:"flex items-center justify-center py-20",children:t.jsx(J,{image:t.jsx(le,{size:48,className:"text-muted-foreground"}),title:s(u?"settings.skills.noResultsTitle":"settings.skills.emptyTitle"),description:u?s("settings.skills.noResultsDescription",{search:u}):s("settings.skills.emptyDescription"),actions:!u&&G})}):t.jsx("div",{className:"@container",children:t.jsx(ee,{children:S.map(i=>{const n=i.id===$;return t.jsx(qe,{entry:i,pending:n,onOpen:()=>I(i),onDelete:B(i)&&!n?()=>P(i):void 0},i.id)})})})]})})}),N&&t.jsx(Fe,{skillPath:N,onClose:()=>f(null)},N),t.jsx(Se,{open:d!==null,onOpenChange:i=>!i&&P(null),children:t.jsxs(be,{children:[t.jsxs(we,{children:[t.jsx(De,{children:s("settings.skills.deleteDialogTitle")}),t.jsx(Ce,{children:s("settings.skills.deleteDialogDescription",{name:d?.name??""})})]}),t.jsxs(Ne,{children:[t.jsx(Pe,{children:s("settings.skills.cancel")}),t.jsx(Ee,{onClick:K,className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",children:s("settings.skills.deleteButton")})]})]})})]})}export{yt as default};
@@ -1 +1 @@
1
- import{c as C,n as d,bJ as u,j as l}from"./index-qCYv4MSE.js";const m=u("animate-spin",{variants:{variant:{default:"fill-primary text-gray-200",destructive:"fill-destructive text-gray-200",secondary:"fill-secondary text-gray-200",success:"fill-success text-gray-200",special:"fill-special text-background"},size:{default:"h-7 w-7",sm:"h-6 w-6",lg:"h-8 w-8",icon:"h-6 w-6",xs:"h-4 w-4"}},defaultVariants:{variant:"default",size:"default"}});function h(f){const e=C.c(10),{variant:c,size:o}=f;let t;e[0]!==o||e[1]!==c?(t=d(m({variant:c,size:o})),e[0]=o,e[1]=c,e[2]=t):t=e[2];let a,i;e[3]===Symbol.for("react.memo_cache_sentinel")?(a=l.jsx("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:"currentColor"}),i=l.jsx("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:"currentFill"}),e[3]=a,e[4]=i):(a=e[3],i=e[4]);let s;e[5]!==t?(s=l.jsxs("svg",{"aria-hidden":"true",className:t,viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[a,i]}),e[5]=t,e[6]=s):s=e[6];let r;e[7]===Symbol.for("react.memo_cache_sentinel")?(r=l.jsx("span",{className:"sr-only",children:"Loading..."}),e[7]=r):r=e[7];let n;return e[8]!==s?(n=l.jsxs("div",{role:"status",children:[s,r]}),e[8]=s,e[9]=n):n=e[9],n}export{h as S};
1
+ import{c as C,n as d,bJ as u,j as l}from"./index-DZLUP-bk.js";const m=u("animate-spin",{variants:{variant:{default:"fill-primary text-gray-200",destructive:"fill-destructive text-gray-200",secondary:"fill-secondary text-gray-200",success:"fill-success text-gray-200",special:"fill-special text-background"},size:{default:"h-7 w-7",sm:"h-6 w-6",lg:"h-8 w-8",icon:"h-6 w-6",xs:"h-4 w-4"}},defaultVariants:{variant:"default",size:"default"}});function h(f){const e=C.c(10),{variant:c,size:o}=f;let t;e[0]!==o||e[1]!==c?(t=d(m({variant:c,size:o})),e[0]=o,e[1]=c,e[2]=t):t=e[2];let a,i;e[3]===Symbol.for("react.memo_cache_sentinel")?(a=l.jsx("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:"currentColor"}),i=l.jsx("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:"currentFill"}),e[3]=a,e[4]=i):(a=e[3],i=e[4]);let s;e[5]!==t?(s=l.jsxs("svg",{"aria-hidden":"true",className:t,viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[a,i]}),e[5]=t,e[6]=s):s=e[6];let r;e[7]===Symbol.for("react.memo_cache_sentinel")?(r=l.jsx("span",{className:"sr-only",children:"Loading..."}),e[7]=r):r=e[7];let n;return e[8]!==s?(n=l.jsxs("div",{role:"status",children:[s,r]}),e[8]=s,e[9]=n):n=e[9],n}export{h as S};
@@ -1 +1 @@
1
- import{b as B,H as L,r as v,j as e,P as x,dx as k,du as y,dv as E,dw as a,fl as D,B as m,q as C,t as c,c as z}from"./index-qCYv4MSE.js";import{D as T}from"./domain-settings-CVK0PWLe.js";import{A as O,a as R,b as q,c as F,e as M,f as U,g as H}from"./alert-dialog-sgAetjem.js";import{I as d}from"./input-CRGKfmn6.js";import{S as $}from"./switch-Cz4K9iDZ.js";import{a as G,b as J,c as K,d as Q}from"./use-org-sso-B37D2h-E.js";import{s as V}from"./Trash01-DeEhE87T.js";import{R as W}from"./require-capability-BoL6jDgL.js";import"./badge-CeB87lwb.js";import"./select-Bz_3bOJv.js";import"./Check-CZ_g5EHO.js";import"./ChevronDown-Bt6RPgee.js";import"./ChevronUp-DkUmlK9q.js";import"./access-gate-C2CuQeuA.js";import"./capability-load-error-BEFZl7BI.js";function X(){const s=B(),{org:o}=L(),{data:f,isLoading:P}=G(o.id,o.slug),h=J(o.id,o.slug),S=K(o.id,o.slug),b=Q(o.id,o.slug),[i,l]=v.useState({issuer:"",clientId:"",clientSecret:"",discoveryEndpoint:"",domain:"",scopes:"openid email profile"}),[g,p]=v.useState(!1),[I,j]=v.useState(!1),u=f?.configured&&f.config,n=f?.config,w=()=>{n&&l({issuer:n.issuer,clientId:n.clientId,clientSecret:"",discoveryEndpoint:n.discoveryEndpoint??"",domain:n.domain,scopes:n.scopes.join(" ")}),p(!0)},N=async()=>{if(!i.issuer||!i.clientId||!i.domain){c.error(s("settings.orgSso.requiredFieldsError"));return}if(!u&&!i.clientSecret){c.error(s("settings.orgSso.clientSecretRequiredError"));return}try{await h.mutateAsync({issuer:i.issuer,clientId:i.clientId,clientSecret:i.clientSecret,discoveryEndpoint:i.discoveryEndpoint||void 0,scopes:i.scopes.split(/\s+/).filter(Boolean),domain:i.domain,enforced:n?.enforced??!1}),C(u?"sso_config_updated":"sso_configured",{organization_id:o.id,email_domain:i.domain}),c.success(s("settings.orgSso.configurationSavedSuccess")),p(!1)}catch(t){c.error(t instanceof Error?t.message:s("settings.orgSso.saveSsoConfigError"))}},_=async()=>{try{await S.mutateAsync(),C("sso_config_removed",{organization_id:o.id}),c.success(s("settings.orgSso.configurationRemovedSuccess")),p(!1),j(!1)}catch{c.error(s("settings.orgSso.removeSsoConfigError"))}},A=async t=>{try{await b.mutateAsync(t),C("sso_enforcement_toggled",{organization_id:o.id,enforced:t}),c.success(s(t?"settings.orgSso.enforcementEnabledSuccess":"settings.orgSso.enforcementDisabledSuccess"))}catch{c.error(s("settings.orgSso.toggleEnforcementError"))}};return e.jsxs(x,{children:[e.jsx(x.Content,{children:e.jsx(x.Body,{children:e.jsxs(k,{children:[e.jsx(x.Title,{children:s("settings.orgSso.securityTitle")}),e.jsx(T,{}),P?e.jsx("div",{className:"text-sm text-muted-foreground",children:s("settings.orgSso.loading")}):e.jsxs(e.Fragment,{children:[u&&!g&&e.jsx(y,{title:s("settings.orgSso.sectionTitle"),children:e.jsxs(E,{children:[e.jsx(a,{title:s("settings.orgSso.providerLabel"),action:e.jsx("span",{className:"font-medium",children:n.issuer})}),e.jsx(a,{title:s("settings.orgSso.clientIdLabel"),action:e.jsx("span",{className:"font-mono text-xs",children:n.clientId})}),e.jsx(a,{title:s("settings.orgSso.domainLabel"),action:e.jsx("span",{className:"font-medium",children:n.domain})}),e.jsx(a,{title:s("settings.orgSso.scopesLabel"),action:e.jsx("span",{className:"font-mono text-xs",children:n.scopes.join(" ")})}),e.jsx("div",{className:"h-px bg-border mx-5"}),e.jsx(a,{title:s("settings.orgSso.enforceSsoLabel"),description:s("settings.orgSso.enforceSsoDescription"),action:e.jsx($,{checked:n.enforced,onCheckedChange:A,disabled:b.isPending})}),e.jsxs(D,{children:[e.jsxs(m,{variant:"ghost",size:"sm",onClick:()=>j(!0),disabled:S.isPending,className:"text-destructive hover:text-destructive mr-auto",children:[e.jsx(V,{size:14}),s("settings.orgSso.removeButton")]}),e.jsx(m,{variant:"outline",size:"sm",onClick:()=>{window.open(`/api/${o.slug}/sso/authorize`,"_blank")},children:s("settings.orgSso.testSsoButton")}),e.jsx(m,{variant:"outline",size:"sm",onClick:w,children:s("settings.orgSso.editConfigButton")})]})]})}),(!u||g)&&e.jsx(y,{title:s("settings.orgSso.sectionTitle"),children:e.jsxs(E,{children:[e.jsx(a,{title:s("settings.orgSso.issuerUrlLabel"),description:s("settings.orgSso.issuerUrlDescription"),action:e.jsx(d,{id:"sso-issuer",placeholder:s("settings.orgSso.issuerUrlPlaceholder"),value:i.issuer,onChange:t=>l(r=>({...r,issuer:t.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:s("settings.orgSso.clientIdLabel"),action:e.jsx(d,{id:"sso-client-id",placeholder:s("settings.orgSso.clientIdPlaceholder"),value:i.clientId,onChange:t=>l(r=>({...r,clientId:t.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:s("settings.orgSso.clientSecretLabel"),description:g&&u?s("settings.orgSso.clientSecretEditDescription"):void 0,action:e.jsx(d,{id:"sso-client-secret",type:"password",placeholder:s("settings.orgSso.clientSecretPlaceholder"),value:i.clientSecret,onChange:t=>l(r=>({...r,clientSecret:t.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:s("settings.orgSso.emailDomainLabel"),description:s("settings.orgSso.emailDomainDescription"),action:e.jsx(d,{id:"sso-domain",placeholder:s("settings.orgSso.emailDomainPlaceholder"),value:i.domain,onChange:t=>l(r=>({...r,domain:t.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:s("settings.orgSso.scopesLabel"),action:e.jsx(d,{id:"sso-scopes",placeholder:s("settings.orgSso.scopesPlaceholder"),value:i.scopes,onChange:t=>l(r=>({...r,scopes:t.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:s("settings.orgSso.discoveryEndpointLabel"),description:s("settings.orgSso.discoveryEndpointDescription"),action:e.jsx(d,{id:"sso-discovery",placeholder:s("settings.orgSso.discoveryEndpointPlaceholder"),value:i.discoveryEndpoint,onChange:t=>l(r=>({...r,discoveryEndpoint:t.target.value})),className:"w-[280px]"})}),e.jsxs(D,{children:[g&&e.jsx(m,{variant:"outline",size:"sm",onClick:()=>p(!1),children:s("settings.orgSso.cancelButton")}),e.jsx(m,{onClick:N,disabled:h.isPending,size:"sm",children:h.isPending?s("settings.orgSso.savingButton"):s(g?"settings.orgSso.updateButton":"settings.orgSso.configureSsoButton")})]})]})})]})]})})}),e.jsx(O,{open:I,onOpenChange:j,children:e.jsxs(R,{children:[e.jsx(q,{children:e.jsx(F,{children:s("settings.orgSso.removeConfirmation")})}),e.jsxs(M,{children:[e.jsx(U,{disabled:S.isPending,children:s("settings.orgSso.cancelButton")}),e.jsx(H,{onClick:_,disabled:S.isPending,className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",children:s("settings.orgSso.removeButton")})]})]})})]})}function me(){const s=z.c(1);let o;return s[0]===Symbol.for("react.memo_cache_sentinel")?(o=e.jsx(W,{capability:"org:manage",area:"security",children:e.jsx(X,{})}),s[0]=o):o=s[0],o}export{me as default};
1
+ import{b as B,H as L,r as v,j as e,P as x,dx as k,du as y,dv as E,dw as a,fl as D,B as m,q as C,t as c,c as z}from"./index-DZLUP-bk.js";import{D as T}from"./domain-settings-NdGxfDzI.js";import{A as O,a as R,b as q,c as F,e as M,f as U,g as H}from"./alert-dialog-C1vr7a0B.js";import{I as d}from"./input-Cvmwm8KN.js";import{S as $}from"./switch-C2vAz9hZ.js";import{a as G,b as J,c as K,d as Q}from"./use-org-sso-wZB9SHX9.js";import{s as V}from"./Trash01-Bji2bWWh.js";import{R as W}from"./require-capability-CCEb5Sqs.js";import"./badge-CFKeX0mn.js";import"./select-SMcDHH3S.js";import"./Check-DzHuFHoL.js";import"./ChevronDown-s4Re3J16.js";import"./ChevronUp-Xpnsttw1.js";import"./access-gate-EoGcByM_.js";import"./capability-load-error-RVzxs7io.js";function X(){const s=B(),{org:o}=L(),{data:f,isLoading:P}=G(o.id,o.slug),h=J(o.id,o.slug),S=K(o.id,o.slug),b=Q(o.id,o.slug),[i,l]=v.useState({issuer:"",clientId:"",clientSecret:"",discoveryEndpoint:"",domain:"",scopes:"openid email profile"}),[g,p]=v.useState(!1),[I,j]=v.useState(!1),u=f?.configured&&f.config,n=f?.config,w=()=>{n&&l({issuer:n.issuer,clientId:n.clientId,clientSecret:"",discoveryEndpoint:n.discoveryEndpoint??"",domain:n.domain,scopes:n.scopes.join(" ")}),p(!0)},N=async()=>{if(!i.issuer||!i.clientId||!i.domain){c.error(s("settings.orgSso.requiredFieldsError"));return}if(!u&&!i.clientSecret){c.error(s("settings.orgSso.clientSecretRequiredError"));return}try{await h.mutateAsync({issuer:i.issuer,clientId:i.clientId,clientSecret:i.clientSecret,discoveryEndpoint:i.discoveryEndpoint||void 0,scopes:i.scopes.split(/\s+/).filter(Boolean),domain:i.domain,enforced:n?.enforced??!1}),C(u?"sso_config_updated":"sso_configured",{organization_id:o.id,email_domain:i.domain}),c.success(s("settings.orgSso.configurationSavedSuccess")),p(!1)}catch(t){c.error(t instanceof Error?t.message:s("settings.orgSso.saveSsoConfigError"))}},_=async()=>{try{await S.mutateAsync(),C("sso_config_removed",{organization_id:o.id}),c.success(s("settings.orgSso.configurationRemovedSuccess")),p(!1),j(!1)}catch{c.error(s("settings.orgSso.removeSsoConfigError"))}},A=async t=>{try{await b.mutateAsync(t),C("sso_enforcement_toggled",{organization_id:o.id,enforced:t}),c.success(s(t?"settings.orgSso.enforcementEnabledSuccess":"settings.orgSso.enforcementDisabledSuccess"))}catch{c.error(s("settings.orgSso.toggleEnforcementError"))}};return e.jsxs(x,{children:[e.jsx(x.Content,{children:e.jsx(x.Body,{children:e.jsxs(k,{children:[e.jsx(x.Title,{children:s("settings.orgSso.securityTitle")}),e.jsx(T,{}),P?e.jsx("div",{className:"text-sm text-muted-foreground",children:s("settings.orgSso.loading")}):e.jsxs(e.Fragment,{children:[u&&!g&&e.jsx(y,{title:s("settings.orgSso.sectionTitle"),children:e.jsxs(E,{children:[e.jsx(a,{title:s("settings.orgSso.providerLabel"),action:e.jsx("span",{className:"font-medium",children:n.issuer})}),e.jsx(a,{title:s("settings.orgSso.clientIdLabel"),action:e.jsx("span",{className:"font-mono text-xs",children:n.clientId})}),e.jsx(a,{title:s("settings.orgSso.domainLabel"),action:e.jsx("span",{className:"font-medium",children:n.domain})}),e.jsx(a,{title:s("settings.orgSso.scopesLabel"),action:e.jsx("span",{className:"font-mono text-xs",children:n.scopes.join(" ")})}),e.jsx("div",{className:"h-px bg-border mx-5"}),e.jsx(a,{title:s("settings.orgSso.enforceSsoLabel"),description:s("settings.orgSso.enforceSsoDescription"),action:e.jsx($,{checked:n.enforced,onCheckedChange:A,disabled:b.isPending})}),e.jsxs(D,{children:[e.jsxs(m,{variant:"ghost",size:"sm",onClick:()=>j(!0),disabled:S.isPending,className:"text-destructive hover:text-destructive mr-auto",children:[e.jsx(V,{size:14}),s("settings.orgSso.removeButton")]}),e.jsx(m,{variant:"outline",size:"sm",onClick:()=>{window.open(`/api/${o.slug}/sso/authorize`,"_blank")},children:s("settings.orgSso.testSsoButton")}),e.jsx(m,{variant:"outline",size:"sm",onClick:w,children:s("settings.orgSso.editConfigButton")})]})]})}),(!u||g)&&e.jsx(y,{title:s("settings.orgSso.sectionTitle"),children:e.jsxs(E,{children:[e.jsx(a,{title:s("settings.orgSso.issuerUrlLabel"),description:s("settings.orgSso.issuerUrlDescription"),action:e.jsx(d,{id:"sso-issuer",placeholder:s("settings.orgSso.issuerUrlPlaceholder"),value:i.issuer,onChange:t=>l(r=>({...r,issuer:t.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:s("settings.orgSso.clientIdLabel"),action:e.jsx(d,{id:"sso-client-id",placeholder:s("settings.orgSso.clientIdPlaceholder"),value:i.clientId,onChange:t=>l(r=>({...r,clientId:t.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:s("settings.orgSso.clientSecretLabel"),description:g&&u?s("settings.orgSso.clientSecretEditDescription"):void 0,action:e.jsx(d,{id:"sso-client-secret",type:"password",placeholder:s("settings.orgSso.clientSecretPlaceholder"),value:i.clientSecret,onChange:t=>l(r=>({...r,clientSecret:t.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:s("settings.orgSso.emailDomainLabel"),description:s("settings.orgSso.emailDomainDescription"),action:e.jsx(d,{id:"sso-domain",placeholder:s("settings.orgSso.emailDomainPlaceholder"),value:i.domain,onChange:t=>l(r=>({...r,domain:t.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:s("settings.orgSso.scopesLabel"),action:e.jsx(d,{id:"sso-scopes",placeholder:s("settings.orgSso.scopesPlaceholder"),value:i.scopes,onChange:t=>l(r=>({...r,scopes:t.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:s("settings.orgSso.discoveryEndpointLabel"),description:s("settings.orgSso.discoveryEndpointDescription"),action:e.jsx(d,{id:"sso-discovery",placeholder:s("settings.orgSso.discoveryEndpointPlaceholder"),value:i.discoveryEndpoint,onChange:t=>l(r=>({...r,discoveryEndpoint:t.target.value})),className:"w-[280px]"})}),e.jsxs(D,{children:[g&&e.jsx(m,{variant:"outline",size:"sm",onClick:()=>p(!1),children:s("settings.orgSso.cancelButton")}),e.jsx(m,{onClick:N,disabled:h.isPending,size:"sm",children:h.isPending?s("settings.orgSso.savingButton"):s(g?"settings.orgSso.updateButton":"settings.orgSso.configureSsoButton")})]})]})})]})]})})}),e.jsx(O,{open:I,onOpenChange:j,children:e.jsxs(R,{children:[e.jsx(q,{children:e.jsx(F,{children:s("settings.orgSso.removeConfirmation")})}),e.jsxs(M,{children:[e.jsx(U,{disabled:S.isPending,children:s("settings.orgSso.cancelButton")}),e.jsx(H,{onClick:_,disabled:S.isPending,className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",children:s("settings.orgSso.removeButton")})]})]})})]})}function me(){const s=z.c(1);let o;return s[0]===Symbol.for("react.memo_cache_sentinel")?(o=e.jsx(W,{capability:"org:manage",area:"security",children:e.jsx(X,{})}),s[0]=o):o=s[0],o}export{me as default};
@@ -1 +1 @@
1
- import{c as J,b as Z,j as i,P as te,r as V,dx as ue,Y as pe,E as xe,H as Se,p as he,dw as W,B as X,d as ye,f as je,q as ae,K as ve,dv as ie,du as re,e as Ce,t as ge}from"./index-qCYv4MSE.js";import{i as _e}from"./AlertCircle-DPUOoh5j.js";import{i as be}from"./ChevronRight-CNbZXCEK.js";import{s as Re}from"./Plus-N25KFjkP.js";import{s as ke}from"./Trash01-DeEhE87T.js";import{I as ne}from"./input-CRGKfmn6.js";import{S as de}from"./switch-Cz4K9iDZ.js";import{A as me}from"./avatar-DLQUtbSd.js";import{P as Ne,a as we,b as Pe}from"./popover-BzE481wQ.js";import{b as fe}from"./use-connection-BQeSoolZ.js";import{W as le}from"./constants-dLUUoWH7.js";import{u as Te}from"./use-registry-connections-pPrzjL2h.js";import{l as Ae,o as ze}from"./use-organization-settings-DFlCOddU.js";import{R as Ee}from"./require-capability-BoL6jDgL.js";import"./User01-BzW7liSD.js";import"./use-mcp-client-BJ8Gl7bN.js";import"./auth-C0jQaNGd.js";import"./schema-CYc80BIA.js";import"./task-board-DCFA9I7S.js";import"./access-gate-C2CuQeuA.js";import"./capability-load-error-BEFZl7BI.js";function Me(t){const e=J.c(6),{error:l}=t,c=Z();let s;e[0]===Symbol.for("react.memo_cache_sentinel")?(s=i.jsx(_e,{size:16}),e[0]=s):s=e[0];let o;e[1]!==c?(o=c("settings.orgStore.failedLoadStoreSettings"),e[1]=c,e[2]=o):o=e[2];let r;return e[3]!==l.message||e[4]!==o?(r=i.jsxs("div",{className:"p-4 rounded-md bg-destructive/10 text-destructive flex items-center gap-2",children:[s,i.jsxs("span",{className:"text-sm font-medium",children:[o," ",l.message]})]}),e[3]=l.message,e[4]=o,e[5]=r):r=e[5],r}function $e(t){const e=J.c(74),{onCancel:l,onSuccess:c}=t,s=Z(),o=fe(),[r,p]=V.useState(""),[a,A]=V.useState(""),[x,b]=V.useState("");let j;e[0]!==o||e[1]!==r||e[2]!==s||e[3]!==x||e[4]!==a?(j=async()=>(await o.create.mutateAsync({title:r||s("settings.orgStore.privateRegistry"),description:s("settings.orgStore.privateMcpRegistry"),connection_type:"HTTP",connection_url:a,connection_token:x||null,connection_headers:null,oauth_config:null,configuration_state:null,configuration_scopes:null,metadata:{type:"registry"},app_name:null,app_id:null,icon:null})).id,e[0]=o,e[1]=r,e[2]=s,e[3]=x,e[4]=a,e[5]=j):j=e[5];let d;e[6]!==c||e[7]!==s?(d=y=>{ae("store_private_registry_added",{connection_id:y}),ge.success(s("settings.orgStore.privateRegistryAdded")),c(y)},e[6]=c,e[7]=s,e[8]=d):d=e[8];let S;e[9]!==s?(S=y=>{ge.error(s("settings.orgStore.failedAddRegistry",{error:y.message}))},e[9]=s,e[10]=S):S=e[10];let m;e[11]!==j||e[12]!==d||e[13]!==S?(m={mutationFn:j,onSuccess:d,onError:S},e[11]=j,e[12]=d,e[13]=S,e[14]=m):m=e[14];const{mutate:v,isPending:g}=Ce(m);let h;e[15]!==s?(h=s("settings.orgStore.nameLabel"),e[15]=s,e[16]=h):h=e[16];let f;e[17]!==s?(f=s("settings.orgStore.namePlaceholder"),e[17]=s,e[18]=f):f=e[18];let u;e[19]===Symbol.for("react.memo_cache_sentinel")?(u=y=>p(y.target.value),e[19]=u):u=e[19];let C;e[20]!==r||e[21]!==f?(C=i.jsx(ne,{placeholder:f,value:r,onChange:u,className:"w-[280px]"}),e[20]=r,e[21]=f,e[22]=C):C=e[22];let R;e[23]!==h||e[24]!==C?(R=i.jsx(W,{title:h,action:C}),e[23]=h,e[24]=C,e[25]=R):R=e[25];let F;e[26]!==s?(F=s("settings.orgStore.registryUrlLabel"),e[26]=s,e[27]=F):F=e[27];let U;e[28]!==s?(U=s("settings.orgStore.registryUrlPlaceholder"),e[28]=s,e[29]=U):U=e[29];let O;e[30]===Symbol.for("react.memo_cache_sentinel")?(O=y=>A(y.target.value),e[30]=O):O=e[30];let Y;e[31]!==U||e[32]!==a?(Y=i.jsx(ne,{placeholder:U,value:a,onChange:O,className:"w-[280px]"}),e[31]=U,e[32]=a,e[33]=Y):Y=e[33];let q;e[34]!==F||e[35]!==Y?(q=i.jsx(W,{title:F,action:Y}),e[34]=F,e[35]=Y,e[36]=q):q=e[36];let z;e[37]!==s?(z=s("settings.orgStore.authTokenLabel"),e[37]=s,e[38]=z):z=e[38];let _;e[39]!==s?(_=s("settings.orgStore.optional"),e[39]=s,e[40]=_):_=e[40];let E;e[41]!==s?(E=s("settings.orgStore.authTokenPlaceholder"),e[41]=s,e[42]=E):E=e[42];let B;e[43]===Symbol.for("react.memo_cache_sentinel")?(B=y=>b(y.target.value),e[43]=B):B=e[43];let M;e[44]!==E||e[45]!==x?(M=i.jsx(ne,{type:"password",placeholder:E,value:x,onChange:B,className:"w-[280px]"}),e[44]=E,e[45]=x,e[46]=M):M=e[46];let I;e[47]!==z||e[48]!==_||e[49]!==M?(I=i.jsx(W,{title:z,description:_,action:M}),e[47]=z,e[48]=_,e[49]=M,e[50]=I):I=e[50];let k;e[51]!==s?(k=s("settings.orgStore.cancel"),e[51]=s,e[52]=k):k=e[52];let D;e[53]!==g||e[54]!==l||e[55]!==k?(D=i.jsx(X,{variant:"ghost",size:"sm",onClick:l,disabled:g,children:k}),e[53]=g,e[54]=l,e[55]=k,e[56]=D):D=e[56];let N;e[57]!==v?(N=()=>v(),e[57]=v,e[58]=N):N=e[58];const L=!a||g;let w;e[59]!==g||e[60]!==s?(w=s(g?"settings.orgStore.adding":"settings.orgStore.addRegistry"),e[59]=g,e[60]=s,e[61]=w):w=e[61];let P;e[62]!==N||e[63]!==L||e[64]!==w?(P=i.jsx(X,{size:"sm",onClick:N,disabled:L,children:w}),e[62]=N,e[63]=L,e[64]=w,e[65]=P):P=e[65];let T;e[66]!==D||e[67]!==P?(T=i.jsxs("div",{className:"px-5 py-4 flex justify-end gap-2",children:[D,P]}),e[66]=D,e[67]=P,e[68]=T):T=e[68];let $;return e[69]!==q||e[70]!==I||e[71]!==T||e[72]!==R?($=i.jsxs(ie,{children:[R,q,I,T]}),e[69]=q,e[70]=I,e[71]=T,e[72]=R,e[73]=$):$=e[73],$}function se(t){const e=J.c(30),{name:l,description:c,icon:s,enabled:o,onToggle:r,onDelete:p,href:a}=t,A=Z(),x=ye();let b;e[0]===Symbol.for("react.memo_cache_sentinel")?(b={from:"/shell/$org"},e[0]=b):b=e[0];const{org:j}=je(b);let d;e[1]!==o||e[2]!==a||e[3]!==x||e[4]!==r||e[5]!==j?(d=()=>{a?x({to:a,params:{org:j}}):r(!o)},e[1]=o,e[2]=a,e[3]=x,e[4]=r,e[5]=j,e[6]=d):d=e[6];const S=d;let m;e[7]!==s||e[8]!==l?(m=s?i.jsx("img",{src:s,alt:l,className:"size-8 rounded-md object-contain"}):i.jsx(me,{fallback:l.charAt(0),className:"size-8 bg-primary/10 text-primary"}),e[7]=s,e[8]=l,e[9]=m):m=e[9];let v;e[10]!==p||e[11]!==A?(v=p&&i.jsxs(Ne,{children:[i.jsx(we,{asChild:!0,children:i.jsx(X,{variant:"ghost",size:"icon",className:"h-6 w-6 text-muted-foreground hover:text-destructive",onClick:Ie,children:i.jsx(ke,{size:14})})}),i.jsx(Pe,{className:"w-auto p-2",align:"end",children:i.jsxs("div",{className:"flex flex-col gap-2",children:[i.jsx("p",{className:"text-xs font-medium",children:A("settings.orgStore.removeRegistry")}),i.jsx(X,{variant:"destructive",size:"xs",onClick:R=>{R.stopPropagation(),p()},children:A("settings.orgStore.remove")})]})})]}),e[10]=p,e[11]=A,e[12]=v):v=e[12];let g;e[13]!==r?(g=R=>r(R),e[13]=r,e[14]=g):g=e[14];let h;e[15]!==o||e[16]!==g?(h=i.jsx(de,{checked:o,onClick:Fe,onCheckedChange:g}),e[15]=o,e[16]=g,e[17]=h):h=e[17];let f;e[18]!==a?(f=a&&i.jsx(be,{size:14,className:"text-muted-foreground"}),e[18]=a,e[19]=f):f=e[19];let u;e[20]!==v||e[21]!==h||e[22]!==f?(u=i.jsxs("div",{className:"flex items-center gap-2",children:[v,h,f]}),e[20]=v,e[21]=h,e[22]=f,e[23]=u):u=e[23];let C;return e[24]!==c||e[25]!==S||e[26]!==l||e[27]!==m||e[28]!==u?(C=i.jsx(W,{title:l,description:c,onClick:S,icon:m,action:u}),e[24]=c,e[25]=S,e[26]=l,e[27]=m,e[28]=u,e[29]=C):C=e[29],C}function Fe(t){return t.stopPropagation()}function Ie(t){return t.stopPropagation()}function De(){const t=J.c(78),e=Z(),{org:l}=Se(),c=Te(),s=fe(),o=Ae(),{mutateAsync:r}=ze(),p=he(),[a,A]=V.useState(!1);let x,b,j,d,S,m;if(t[0]!==s||t[1]!==l.id||t[2]!==p||t[3]!==o||t[4]!==c||t[5]!==a||t[6]!==e||t[7]!==r){const f=le.REGISTRY(l.id),u=n=>{if(!o)return n===f;const K=o.registries[n];return K?K.enabled:n===f},C=le.COMMUNITY_REGISTRY(l.id),R=c.find(n=>n.id===f),F=c.find(n=>n.id===C||n.id==="community-registry"),U=F?.id??C,O=le.SELF(l.id),Y=new Set([f,C,"community-registry",O]),q=c.filter(n=>!Y.has(n.id));let z;t[14]!==o||t[15]!==r?(z=async(n,K)=>{ae("store_registry_toggled",{connection_id:n,enabled:K});const ce=o??{registries:{},blockedMcps:[]};await r({...ce,registries:{...ce.registries,[n]:{enabled:K}}})},t[14]=o,t[15]=r,t[16]=z):z=t[16];const _=z;let E;t[17]!==s||t[18]!==l.id||t[19]!==p?(E=async n=>{ae("store_private_registry_removed",{connection_id:n}),await s.delete.mutateAsync(n),p.invalidateQueries({queryKey:ve.organizationSettings(l.id)})},t[17]=s,t[18]=l.id,t[19]=p,t[20]=E):E=t[20];const B=E;let M;t[21]!==o||t[22]!==r?(M=async n=>{A(!1);const K=o??{registries:{},blockedMcps:[]};await r({...K,registries:{...K.registries,[n]:{enabled:!0}}})},t[21]=o,t[22]=r,t[23]=M):M=t[23];const I=M;let k;t[24]!==e?(k=e("settings.orgStore.decoStoreSection"),t[24]=e,t[25]=k):k=t[25];const D=R?i.jsx(se,{name:e("settings.orgStore.decoStoreName"),description:e("settings.orgStore.decoStoreDescription"),icon:R.icon,enabled:u(f),onToggle:n=>_(f,n)}):i.jsx(W,{title:e("settings.orgStore.decoStoreName"),description:e("settings.orgStore.connectionNotFound")});let N;t[26]!==D?(N=i.jsx(ie,{children:D}),t[26]=D,t[27]=N):N=t[27],t[28]!==k||t[29]!==N?(S=i.jsx(re,{title:k,children:N}),t[28]=k,t[29]=N,t[30]=S):S=t[30];let L;t[31]!==e?(L=e("settings.orgStore.privateRegistriesSection"),t[31]=e,t[32]=L):L=t[32];let w;t[33]!==a||t[34]!==e?(w=a?void 0:i.jsxs(X,{variant:"outline",size:"sm",onClick:()=>A(!0),children:[i.jsx(Re,{size:14}),e("settings.orgStore.addRegistry")]}),t[33]=a,t[34]=e,t[35]=w):w=t[35];let P;t[36]!==I||t[37]!==a?(P=a&&i.jsx($e,{onCancel:()=>A(!1),onSuccess:I}),t[36]=I,t[37]=a,t[38]=P):P=t[38];let T;t[39]!==e?(T=e("settings.orgStore.privateRegistry"),t[39]=e,t[40]=T):T=t[40];let $;t[41]!==e?($=e("settings.orgStore.privateRegistryDescription"),t[41]=e,t[42]=$):$=t[42];let y;t[43]!==u?(y=u("self"),t[43]=u,t[44]=y):y=t[44];let G;t[45]!==_?(G=n=>_("self",n),t[45]=_,t[46]=G):G=t[46];let H;t[47]!==T||t[48]!==$||t[49]!==y||t[50]!==G?(H=i.jsx(se,{name:T,description:$,enabled:y,onToggle:G,href:"/$org/settings/store/registry"}),t[47]=T,t[48]=$,t[49]=y,t[50]=G,t[51]=H):H=t[51];let ee;t[52]!==B||t[53]!==_||t[54]!==u||t[55]!==e?(ee=n=>i.jsx(se,{name:n.title,description:n.description??e("settings.orgStore.privateMcpRegistry"),icon:n.icon,enabled:u(n.id),onToggle:K=>_(n.id,K),onDelete:()=>B(n.id)},n.id),t[52]=B,t[53]=_,t[54]=u,t[55]=e,t[56]=ee):ee=t[56];const oe=q.map(ee);let Q;t[57]!==H||t[58]!==oe?(Q=i.jsxs(ie,{children:[H,oe]}),t[57]=H,t[58]=oe,t[59]=Q):Q=t[59],t[60]!==L||t[61]!==w||t[62]!==P||t[63]!==Q?(m=i.jsxs(re,{title:L,actions:w,children:[P,Q]}),t[60]=L,t[61]=w,t[62]=P,t[63]=Q,t[64]=m):m=t[64],b=re,t[65]!==e?(d=e("settings.orgStore.communitySection"),t[65]=e,t[66]=d):d=t[66],x=ie,j=F?i.jsx(se,{name:e("settings.orgStore.mcpRegistry"),description:e("settings.orgStore.communityRegistryDescription"),icon:F.icon,enabled:u(U),onToggle:n=>_(U,n)}):i.jsx(W,{title:e("settings.orgStore.mcpRegistry"),description:e("settings.orgStore.communityRegistryNotAdded"),icon:i.jsx(me,{fallback:"M",className:"size-8 bg-primary/10 text-primary"}),action:i.jsx(de,{checked:!1,disabled:!0,onCheckedChange:Le})}),t[0]=s,t[1]=l.id,t[2]=p,t[3]=o,t[4]=c,t[5]=a,t[6]=e,t[7]=r,t[8]=x,t[9]=b,t[10]=j,t[11]=d,t[12]=S,t[13]=m}else x=t[8],b=t[9],j=t[10],d=t[11],S=t[12],m=t[13];let v;t[67]!==x||t[68]!==j?(v=i.jsx(x,{children:j}),t[67]=x,t[68]=j,t[69]=v):v=t[69];let g;t[70]!==b||t[71]!==d||t[72]!==v?(g=i.jsx(b,{title:d,children:v}),t[70]=b,t[71]=d,t[72]=v,t[73]=g):g=t[73];let h;return t[74]!==S||t[75]!==m||t[76]!==g?(h=i.jsxs(i.Fragment,{children:[S,m,g]}),t[74]=S,t[75]=m,t[76]=g,t[77]=h):h=t[77],h}function Le(){}function Ke(){const t=J.c(13),e=Z();let l;t[0]!==e?(l=A=>{const{error:x}=A;return i.jsx(Me,{error:x??new Error(e("settings.orgStore.failedLoadStoreSettings"))})},t[0]=e,t[1]=l):l=t[1];let c;t[2]===Symbol.for("react.memo_cache_sentinel")?(c=i.jsx(pe,{className:"h-64 w-full"}),t[2]=c):c=t[2];let s;t[3]!==e?(s=e("settings.orgStore.pageTitle"),t[3]=e,t[4]=s):s=t[4];let o;t[5]!==s?(o=i.jsx(te.Title,{children:s}),t[5]=s,t[6]=o):o=t[6];let r;t[7]===Symbol.for("react.memo_cache_sentinel")?(r=i.jsx(De,{}),t[7]=r):r=t[7];let p;t[8]!==o?(p=i.jsx(V.Suspense,{fallback:c,children:i.jsx(te,{children:i.jsx(te.Content,{children:i.jsx(te.Body,{children:i.jsxs(ue,{children:[o,r]})})})})}),t[8]=o,t[9]=p):p=t[9];let a;return t[10]!==l||t[11]!==p?(a=i.jsx(xe,{fallback:l,children:p}),t[10]=l,t[11]=p,t[12]=a):a=t[12],a}function at(){const t=J.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=i.jsx(Ee,{capability:"registry:manage",area:"the store",children:i.jsx(Ke,{})}),t[0]=e):e=t[0],e}export{at as default};
1
+ import{c as J,b as Z,j as i,P as te,r as V,dx as ue,Y as pe,E as xe,H as Se,p as he,dw as W,B as X,d as ye,f as je,q as ae,K as ve,dv as ie,du as re,e as Ce,t as ge}from"./index-DZLUP-bk.js";import{i as _e}from"./AlertCircle-f4nnpTTg.js";import{i as be}from"./ChevronRight-DtOnXnjv.js";import{s as Re}from"./Plus-CYNImaOJ.js";import{s as ke}from"./Trash01-Bji2bWWh.js";import{I as ne}from"./input-Cvmwm8KN.js";import{S as de}from"./switch-C2vAz9hZ.js";import{A as me}from"./avatar-CpPlf24-.js";import{P as Ne,a as we,b as Pe}from"./popover-CGQv5zzi.js";import{b as fe}from"./use-connection-BBRJTBMy.js";import{W as le}from"./constants-dLUUoWH7.js";import{u as Te}from"./use-registry-connections-CB_vMkV_.js";import{l as Ae,o as ze}from"./use-organization-settings-DoHw0Vrb.js";import{R as Ee}from"./require-capability-CCEb5Sqs.js";import"./User01-xX8OC8Hl.js";import"./use-mcp-client-Qp-dz21o.js";import"./auth-DXJPvHb_.js";import"./schema-B2Qlbge8.js";import"./task-board-DTv9gW69.js";import"./access-gate-EoGcByM_.js";import"./capability-load-error-RVzxs7io.js";function Me(t){const e=J.c(6),{error:l}=t,c=Z();let s;e[0]===Symbol.for("react.memo_cache_sentinel")?(s=i.jsx(_e,{size:16}),e[0]=s):s=e[0];let o;e[1]!==c?(o=c("settings.orgStore.failedLoadStoreSettings"),e[1]=c,e[2]=o):o=e[2];let r;return e[3]!==l.message||e[4]!==o?(r=i.jsxs("div",{className:"p-4 rounded-md bg-destructive/10 text-destructive flex items-center gap-2",children:[s,i.jsxs("span",{className:"text-sm font-medium",children:[o," ",l.message]})]}),e[3]=l.message,e[4]=o,e[5]=r):r=e[5],r}function $e(t){const e=J.c(74),{onCancel:l,onSuccess:c}=t,s=Z(),o=fe(),[r,p]=V.useState(""),[a,A]=V.useState(""),[x,b]=V.useState("");let j;e[0]!==o||e[1]!==r||e[2]!==s||e[3]!==x||e[4]!==a?(j=async()=>(await o.create.mutateAsync({title:r||s("settings.orgStore.privateRegistry"),description:s("settings.orgStore.privateMcpRegistry"),connection_type:"HTTP",connection_url:a,connection_token:x||null,connection_headers:null,oauth_config:null,configuration_state:null,configuration_scopes:null,metadata:{type:"registry"},app_name:null,app_id:null,icon:null})).id,e[0]=o,e[1]=r,e[2]=s,e[3]=x,e[4]=a,e[5]=j):j=e[5];let d;e[6]!==c||e[7]!==s?(d=y=>{ae("store_private_registry_added",{connection_id:y}),ge.success(s("settings.orgStore.privateRegistryAdded")),c(y)},e[6]=c,e[7]=s,e[8]=d):d=e[8];let S;e[9]!==s?(S=y=>{ge.error(s("settings.orgStore.failedAddRegistry",{error:y.message}))},e[9]=s,e[10]=S):S=e[10];let m;e[11]!==j||e[12]!==d||e[13]!==S?(m={mutationFn:j,onSuccess:d,onError:S},e[11]=j,e[12]=d,e[13]=S,e[14]=m):m=e[14];const{mutate:v,isPending:g}=Ce(m);let h;e[15]!==s?(h=s("settings.orgStore.nameLabel"),e[15]=s,e[16]=h):h=e[16];let f;e[17]!==s?(f=s("settings.orgStore.namePlaceholder"),e[17]=s,e[18]=f):f=e[18];let u;e[19]===Symbol.for("react.memo_cache_sentinel")?(u=y=>p(y.target.value),e[19]=u):u=e[19];let C;e[20]!==r||e[21]!==f?(C=i.jsx(ne,{placeholder:f,value:r,onChange:u,className:"w-[280px]"}),e[20]=r,e[21]=f,e[22]=C):C=e[22];let R;e[23]!==h||e[24]!==C?(R=i.jsx(W,{title:h,action:C}),e[23]=h,e[24]=C,e[25]=R):R=e[25];let F;e[26]!==s?(F=s("settings.orgStore.registryUrlLabel"),e[26]=s,e[27]=F):F=e[27];let U;e[28]!==s?(U=s("settings.orgStore.registryUrlPlaceholder"),e[28]=s,e[29]=U):U=e[29];let O;e[30]===Symbol.for("react.memo_cache_sentinel")?(O=y=>A(y.target.value),e[30]=O):O=e[30];let Y;e[31]!==U||e[32]!==a?(Y=i.jsx(ne,{placeholder:U,value:a,onChange:O,className:"w-[280px]"}),e[31]=U,e[32]=a,e[33]=Y):Y=e[33];let q;e[34]!==F||e[35]!==Y?(q=i.jsx(W,{title:F,action:Y}),e[34]=F,e[35]=Y,e[36]=q):q=e[36];let z;e[37]!==s?(z=s("settings.orgStore.authTokenLabel"),e[37]=s,e[38]=z):z=e[38];let _;e[39]!==s?(_=s("settings.orgStore.optional"),e[39]=s,e[40]=_):_=e[40];let E;e[41]!==s?(E=s("settings.orgStore.authTokenPlaceholder"),e[41]=s,e[42]=E):E=e[42];let B;e[43]===Symbol.for("react.memo_cache_sentinel")?(B=y=>b(y.target.value),e[43]=B):B=e[43];let M;e[44]!==E||e[45]!==x?(M=i.jsx(ne,{type:"password",placeholder:E,value:x,onChange:B,className:"w-[280px]"}),e[44]=E,e[45]=x,e[46]=M):M=e[46];let I;e[47]!==z||e[48]!==_||e[49]!==M?(I=i.jsx(W,{title:z,description:_,action:M}),e[47]=z,e[48]=_,e[49]=M,e[50]=I):I=e[50];let k;e[51]!==s?(k=s("settings.orgStore.cancel"),e[51]=s,e[52]=k):k=e[52];let D;e[53]!==g||e[54]!==l||e[55]!==k?(D=i.jsx(X,{variant:"ghost",size:"sm",onClick:l,disabled:g,children:k}),e[53]=g,e[54]=l,e[55]=k,e[56]=D):D=e[56];let N;e[57]!==v?(N=()=>v(),e[57]=v,e[58]=N):N=e[58];const L=!a||g;let w;e[59]!==g||e[60]!==s?(w=s(g?"settings.orgStore.adding":"settings.orgStore.addRegistry"),e[59]=g,e[60]=s,e[61]=w):w=e[61];let P;e[62]!==N||e[63]!==L||e[64]!==w?(P=i.jsx(X,{size:"sm",onClick:N,disabled:L,children:w}),e[62]=N,e[63]=L,e[64]=w,e[65]=P):P=e[65];let T;e[66]!==D||e[67]!==P?(T=i.jsxs("div",{className:"px-5 py-4 flex justify-end gap-2",children:[D,P]}),e[66]=D,e[67]=P,e[68]=T):T=e[68];let $;return e[69]!==q||e[70]!==I||e[71]!==T||e[72]!==R?($=i.jsxs(ie,{children:[R,q,I,T]}),e[69]=q,e[70]=I,e[71]=T,e[72]=R,e[73]=$):$=e[73],$}function se(t){const e=J.c(30),{name:l,description:c,icon:s,enabled:o,onToggle:r,onDelete:p,href:a}=t,A=Z(),x=ye();let b;e[0]===Symbol.for("react.memo_cache_sentinel")?(b={from:"/shell/$org"},e[0]=b):b=e[0];const{org:j}=je(b);let d;e[1]!==o||e[2]!==a||e[3]!==x||e[4]!==r||e[5]!==j?(d=()=>{a?x({to:a,params:{org:j}}):r(!o)},e[1]=o,e[2]=a,e[3]=x,e[4]=r,e[5]=j,e[6]=d):d=e[6];const S=d;let m;e[7]!==s||e[8]!==l?(m=s?i.jsx("img",{src:s,alt:l,className:"size-8 rounded-md object-contain"}):i.jsx(me,{fallback:l.charAt(0),className:"size-8 bg-primary/10 text-primary"}),e[7]=s,e[8]=l,e[9]=m):m=e[9];let v;e[10]!==p||e[11]!==A?(v=p&&i.jsxs(Ne,{children:[i.jsx(we,{asChild:!0,children:i.jsx(X,{variant:"ghost",size:"icon",className:"h-6 w-6 text-muted-foreground hover:text-destructive",onClick:Ie,children:i.jsx(ke,{size:14})})}),i.jsx(Pe,{className:"w-auto p-2",align:"end",children:i.jsxs("div",{className:"flex flex-col gap-2",children:[i.jsx("p",{className:"text-xs font-medium",children:A("settings.orgStore.removeRegistry")}),i.jsx(X,{variant:"destructive",size:"xs",onClick:R=>{R.stopPropagation(),p()},children:A("settings.orgStore.remove")})]})})]}),e[10]=p,e[11]=A,e[12]=v):v=e[12];let g;e[13]!==r?(g=R=>r(R),e[13]=r,e[14]=g):g=e[14];let h;e[15]!==o||e[16]!==g?(h=i.jsx(de,{checked:o,onClick:Fe,onCheckedChange:g}),e[15]=o,e[16]=g,e[17]=h):h=e[17];let f;e[18]!==a?(f=a&&i.jsx(be,{size:14,className:"text-muted-foreground"}),e[18]=a,e[19]=f):f=e[19];let u;e[20]!==v||e[21]!==h||e[22]!==f?(u=i.jsxs("div",{className:"flex items-center gap-2",children:[v,h,f]}),e[20]=v,e[21]=h,e[22]=f,e[23]=u):u=e[23];let C;return e[24]!==c||e[25]!==S||e[26]!==l||e[27]!==m||e[28]!==u?(C=i.jsx(W,{title:l,description:c,onClick:S,icon:m,action:u}),e[24]=c,e[25]=S,e[26]=l,e[27]=m,e[28]=u,e[29]=C):C=e[29],C}function Fe(t){return t.stopPropagation()}function Ie(t){return t.stopPropagation()}function De(){const t=J.c(78),e=Z(),{org:l}=Se(),c=Te(),s=fe(),o=Ae(),{mutateAsync:r}=ze(),p=he(),[a,A]=V.useState(!1);let x,b,j,d,S,m;if(t[0]!==s||t[1]!==l.id||t[2]!==p||t[3]!==o||t[4]!==c||t[5]!==a||t[6]!==e||t[7]!==r){const f=le.REGISTRY(l.id),u=n=>{if(!o)return n===f;const K=o.registries[n];return K?K.enabled:n===f},C=le.COMMUNITY_REGISTRY(l.id),R=c.find(n=>n.id===f),F=c.find(n=>n.id===C||n.id==="community-registry"),U=F?.id??C,O=le.SELF(l.id),Y=new Set([f,C,"community-registry",O]),q=c.filter(n=>!Y.has(n.id));let z;t[14]!==o||t[15]!==r?(z=async(n,K)=>{ae("store_registry_toggled",{connection_id:n,enabled:K});const ce=o??{registries:{},blockedMcps:[]};await r({...ce,registries:{...ce.registries,[n]:{enabled:K}}})},t[14]=o,t[15]=r,t[16]=z):z=t[16];const _=z;let E;t[17]!==s||t[18]!==l.id||t[19]!==p?(E=async n=>{ae("store_private_registry_removed",{connection_id:n}),await s.delete.mutateAsync(n),p.invalidateQueries({queryKey:ve.organizationSettings(l.id)})},t[17]=s,t[18]=l.id,t[19]=p,t[20]=E):E=t[20];const B=E;let M;t[21]!==o||t[22]!==r?(M=async n=>{A(!1);const K=o??{registries:{},blockedMcps:[]};await r({...K,registries:{...K.registries,[n]:{enabled:!0}}})},t[21]=o,t[22]=r,t[23]=M):M=t[23];const I=M;let k;t[24]!==e?(k=e("settings.orgStore.decoStoreSection"),t[24]=e,t[25]=k):k=t[25];const D=R?i.jsx(se,{name:e("settings.orgStore.decoStoreName"),description:e("settings.orgStore.decoStoreDescription"),icon:R.icon,enabled:u(f),onToggle:n=>_(f,n)}):i.jsx(W,{title:e("settings.orgStore.decoStoreName"),description:e("settings.orgStore.connectionNotFound")});let N;t[26]!==D?(N=i.jsx(ie,{children:D}),t[26]=D,t[27]=N):N=t[27],t[28]!==k||t[29]!==N?(S=i.jsx(re,{title:k,children:N}),t[28]=k,t[29]=N,t[30]=S):S=t[30];let L;t[31]!==e?(L=e("settings.orgStore.privateRegistriesSection"),t[31]=e,t[32]=L):L=t[32];let w;t[33]!==a||t[34]!==e?(w=a?void 0:i.jsxs(X,{variant:"outline",size:"sm",onClick:()=>A(!0),children:[i.jsx(Re,{size:14}),e("settings.orgStore.addRegistry")]}),t[33]=a,t[34]=e,t[35]=w):w=t[35];let P;t[36]!==I||t[37]!==a?(P=a&&i.jsx($e,{onCancel:()=>A(!1),onSuccess:I}),t[36]=I,t[37]=a,t[38]=P):P=t[38];let T;t[39]!==e?(T=e("settings.orgStore.privateRegistry"),t[39]=e,t[40]=T):T=t[40];let $;t[41]!==e?($=e("settings.orgStore.privateRegistryDescription"),t[41]=e,t[42]=$):$=t[42];let y;t[43]!==u?(y=u("self"),t[43]=u,t[44]=y):y=t[44];let G;t[45]!==_?(G=n=>_("self",n),t[45]=_,t[46]=G):G=t[46];let H;t[47]!==T||t[48]!==$||t[49]!==y||t[50]!==G?(H=i.jsx(se,{name:T,description:$,enabled:y,onToggle:G,href:"/$org/settings/store/registry"}),t[47]=T,t[48]=$,t[49]=y,t[50]=G,t[51]=H):H=t[51];let ee;t[52]!==B||t[53]!==_||t[54]!==u||t[55]!==e?(ee=n=>i.jsx(se,{name:n.title,description:n.description??e("settings.orgStore.privateMcpRegistry"),icon:n.icon,enabled:u(n.id),onToggle:K=>_(n.id,K),onDelete:()=>B(n.id)},n.id),t[52]=B,t[53]=_,t[54]=u,t[55]=e,t[56]=ee):ee=t[56];const oe=q.map(ee);let Q;t[57]!==H||t[58]!==oe?(Q=i.jsxs(ie,{children:[H,oe]}),t[57]=H,t[58]=oe,t[59]=Q):Q=t[59],t[60]!==L||t[61]!==w||t[62]!==P||t[63]!==Q?(m=i.jsxs(re,{title:L,actions:w,children:[P,Q]}),t[60]=L,t[61]=w,t[62]=P,t[63]=Q,t[64]=m):m=t[64],b=re,t[65]!==e?(d=e("settings.orgStore.communitySection"),t[65]=e,t[66]=d):d=t[66],x=ie,j=F?i.jsx(se,{name:e("settings.orgStore.mcpRegistry"),description:e("settings.orgStore.communityRegistryDescription"),icon:F.icon,enabled:u(U),onToggle:n=>_(U,n)}):i.jsx(W,{title:e("settings.orgStore.mcpRegistry"),description:e("settings.orgStore.communityRegistryNotAdded"),icon:i.jsx(me,{fallback:"M",className:"size-8 bg-primary/10 text-primary"}),action:i.jsx(de,{checked:!1,disabled:!0,onCheckedChange:Le})}),t[0]=s,t[1]=l.id,t[2]=p,t[3]=o,t[4]=c,t[5]=a,t[6]=e,t[7]=r,t[8]=x,t[9]=b,t[10]=j,t[11]=d,t[12]=S,t[13]=m}else x=t[8],b=t[9],j=t[10],d=t[11],S=t[12],m=t[13];let v;t[67]!==x||t[68]!==j?(v=i.jsx(x,{children:j}),t[67]=x,t[68]=j,t[69]=v):v=t[69];let g;t[70]!==b||t[71]!==d||t[72]!==v?(g=i.jsx(b,{title:d,children:v}),t[70]=b,t[71]=d,t[72]=v,t[73]=g):g=t[73];let h;return t[74]!==S||t[75]!==m||t[76]!==g?(h=i.jsxs(i.Fragment,{children:[S,m,g]}),t[74]=S,t[75]=m,t[76]=g,t[77]=h):h=t[77],h}function Le(){}function Ke(){const t=J.c(13),e=Z();let l;t[0]!==e?(l=A=>{const{error:x}=A;return i.jsx(Me,{error:x??new Error(e("settings.orgStore.failedLoadStoreSettings"))})},t[0]=e,t[1]=l):l=t[1];let c;t[2]===Symbol.for("react.memo_cache_sentinel")?(c=i.jsx(pe,{className:"h-64 w-full"}),t[2]=c):c=t[2];let s;t[3]!==e?(s=e("settings.orgStore.pageTitle"),t[3]=e,t[4]=s):s=t[4];let o;t[5]!==s?(o=i.jsx(te.Title,{children:s}),t[5]=s,t[6]=o):o=t[6];let r;t[7]===Symbol.for("react.memo_cache_sentinel")?(r=i.jsx(De,{}),t[7]=r):r=t[7];let p;t[8]!==o?(p=i.jsx(V.Suspense,{fallback:c,children:i.jsx(te,{children:i.jsx(te.Content,{children:i.jsx(te.Body,{children:i.jsxs(ue,{children:[o,r]})})})})}),t[8]=o,t[9]=p):p=t[9];let a;return t[10]!==l||t[11]!==p?(a=i.jsx(xe,{fallback:l,children:p}),t[10]=l,t[11]=p,t[12]=a):a=t[12],a}function at(){const t=J.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=i.jsx(Ee,{capability:"registry:manage",area:"the store",children:i.jsx(Ke,{})}),t[0]=e):e=t[0],e}export{at as default};
@@ -0,0 +1,2 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/registry-layout-CzKQ-sVC.js","assets/index-DZLUP-bk.js","assets/index-Blq7G79G.css","assets/Tool02-DiIiNPwu.js","assets/CheckCircle-tNccGo23.js","assets/Settings02-CfL_uUCf.js","assets/use-mcp-client-Qp-dz21o.js","assets/constants-dLUUoWH7.js","assets/auth-DXJPvHb_.js","assets/useInfiniteQuery-Mj7WnppJ.js","assets/use-infinite-scroll-D9F23MOw.js","assets/badge-CFKeX0mn.js","assets/input-Cvmwm8KN.js","assets/dropdown-menu-C16L90Tz.js","assets/Check-DzHuFHoL.js","assets/ChevronRight-DtOnXnjv.js","assets/DotsVertical-BVchZPc_.js","assets/table-C2U6VD6y.js","assets/toggle-group-CcQrFwsS.js","assets/use-view-mode-CqPRLkgX.js","assets/FilterLines-pNRXDJ_z.js","assets/Globe01-DXAw5CTM.js","assets/SearchMd-bD349BM3.js","assets/dialog-pwZ4KzZ6.js","assets/AlertCircle-f4nnpTTg.js","assets/Download01-C8Yiywz6.js","assets/Upload01-CYRB-7yG.js","assets/metadata-dUsYcpuu.js","assets/alert-dialog-C1vr7a0B.js","assets/Trash01-Bji2bWWh.js","assets/label-DZWNE7Y7.js","assets/select-SMcDHH3S.js","assets/ChevronDown-s4Re3J16.js","assets/ChevronUp-Xpnsttw1.js","assets/switch-C2vAz9hZ.js","assets/textarea-DsyQQY8o.js","assets/ArrowLeft-DeVXQ_Zc.js","assets/XCircle-YqRo5mD9.js","assets/checkbox-BoivotQ-.js","assets/Eye-WB67QJ1C.js","assets/LinkExternal01-kAtb5ILy.js","assets/use-copy-QEjXenkb.js","assets/Copy01-BRPiRRUQ.js","assets/Key01-CHTC8hwE.js","assets/Plus-CYNImaOJ.js","assets/mcp-oauth-BfeN-QCK.js","assets/Play-CZP4IMzd.js"])))=>i.map(i=>d[i]);
2
+ import{c as n,d as c,f as m,j as t,k as f,r as l,bq as p}from"./index-DZLUP-bk.js";import{R as u}from"./require-capability-CCEb5Sqs.js";import"./access-gate-EoGcByM_.js";import"./capability-load-error-RVzxs7io.js";const g=l.lazy(()=>p(()=>import("./registry-layout-CzKQ-sVC.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46])));function h(){const e=n.c(5),i=c();let s;e[0]===Symbol.for("react.memo_cache_sentinel")?(s={from:"/shell/$org"},e[0]=s):s=e[0];const{org:o}=m(s);let r;e[1]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsx("div",{className:"h-full flex items-center justify-center",children:t.jsx(f,{size:20,className:"animate-spin text-muted-foreground"})}),e[1]=r):r=e[1];let a;return e[2]!==i||e[3]!==o?(a=t.jsx(u,{capability:"registry:manage",area:"the registry",children:t.jsx(l.Suspense,{fallback:r,children:t.jsx(g,{onBack:()=>i({to:"/$org/settings/store",params:{org:o}})})})}),e[2]=i,e[3]=o,e[4]=a):a=e[4],a}export{h as default};