decocms 2.367.13 → 2.367.25

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 (225) hide show
  1. package/dist/client/assets/{AlertCircle-BT4KzWnI.js → AlertCircle-B5W8e_5w.js} +1 -1
  2. package/dist/client/assets/{ArrowNarrowLeft-DL6IklHf.js → ArrowNarrowLeft-hiT9EAxM.js} +1 -1
  3. package/dist/client/assets/{ArrowUpRight-CuD8Ec0Q.js → ArrowUpRight-BngWaIVR.js} +1 -1
  4. package/dist/client/assets/{Check-BwR-n-sF.js → Check-8Z25AyId.js} +1 -1
  5. package/dist/client/assets/{CheckCircle-CeozB0CE.js → CheckCircle-BEasBYv4.js} +1 -1
  6. package/dist/client/assets/{ChevronDown-NgrGgemj.js → ChevronDown-DYIWk9ra.js} +1 -1
  7. package/dist/client/assets/{ChevronRight-DzTdh7eY.js → ChevronRight-C956u55G.js} +1 -1
  8. package/dist/client/assets/{ChevronUp-O1681VYk.js → ChevronUp-CdhHmg9Y.js} +1 -1
  9. package/dist/client/assets/{Container-2b4BXA-n.js → Container-eQJj-j5B.js} +1 -1
  10. package/dist/client/assets/{DotsVertical-DwV108_Y.js → DotsVertical-BY4pEp3W.js} +1 -1
  11. package/dist/client/assets/{FilterLines-DOivCNH_.js → FilterLines-z8ejuVIV.js} +1 -1
  12. package/dist/client/assets/{HardDrive-Cj4eW7va.js → HardDrive-C5cYoT_u.js} +1 -1
  13. package/dist/client/assets/{Key01-BQUJeWtG.js → Key01-D616GLzE.js} +1 -1
  14. package/dist/client/assets/{LayoutLeft-BtnBeX4Q.js → LayoutLeft-_rPJ3Xdj.js} +1 -1
  15. package/dist/client/assets/{LinkExternal01-gSnFHviP.js → LinkExternal01-DxWXfBDh.js} +1 -1
  16. package/dist/client/assets/{Lock01-CLcwdBbZ.js → Lock01-BCib8CWc.js} +1 -1
  17. package/dist/client/assets/{Monitor01-B72KxmOA.js → Monitor01-Bz4VCJsr.js} +1 -1
  18. package/dist/client/assets/{Palette-CDAteqS3.js → Palette-Vm3-5yKD.js} +1 -1
  19. package/dist/client/assets/{Play-3lq0IL_j.js → Play-CKvhUVKq.js} +1 -1
  20. package/dist/client/assets/{Plus-CuU_Vn1V.js → Plus-CpQnzuG3.js} +1 -1
  21. package/dist/client/assets/{RefreshCcw01-DYeBzgxl.js → RefreshCcw01-B7Js0dD2.js} +1 -1
  22. package/dist/client/assets/{SearchMd-YL-AZ1_e.js → SearchMd-D0mvaU5_.js} +1 -1
  23. package/dist/client/assets/{Settings02-CmAK-JQC.js → Settings02-CNt0vvEu.js} +1 -1
  24. package/dist/client/assets/{Shield01-DWmt0CsN.js → Shield01-CZAvPXer.js} +1 -1
  25. package/dist/client/assets/{Star01-B9_yj21o.js → Star01-CEifhmiR.js} +1 -1
  26. package/dist/client/assets/{Stars02-DjyZ6rm8.js → Stars02-M_tqgIvg.js} +1 -1
  27. package/dist/client/assets/{Sun-D3nbZYnT.js → Sun-Ch8hbN6j.js} +1 -1
  28. package/dist/client/assets/{SwitchHorizontal01-CoAD8Pso.js → SwitchHorizontal01-CJw113gN.js} +1 -1
  29. package/dist/client/assets/{Tool01-Cr9-Ayar.js → Tool01-CbzoidXH.js} +1 -1
  30. package/dist/client/assets/{Trash01-Bdgng8Ny.js → Trash01-CUZkoYoW.js} +1 -1
  31. package/dist/client/assets/{Upload01-DEH4hqbP.js → Upload01-DaqpbIUH.js} +1 -1
  32. package/dist/client/assets/{User01-DvR2FzxS.js → User01-CtOhLzXW.js} +1 -1
  33. package/dist/client/assets/{Users01-DKVYUvbH.js → Users01-DQVYpyq7.js} +1 -1
  34. package/dist/client/assets/{Users03-BScPbfBT.js → Users03-DGJmr08f.js} +1 -1
  35. package/dist/client/assets/{X-BpMfki2j.js → X-Coa3_vHC.js} +1 -1
  36. package/dist/client/assets/{XCircle-D4gl9x0F.js → XCircle-DvYTE78y.js} +1 -1
  37. package/dist/client/assets/{XClose-8wwGH-xu.js → XClose-wy0ZjI4q.js} +1 -1
  38. package/dist/client/assets/{Zap-DGOMtCmx.js → Zap-B74dlfsg.js} +1 -1
  39. package/dist/client/assets/{ZapSquare-C-QuJXiX.js → ZapSquare-BQ8gms0B.js} +1 -1
  40. package/dist/client/assets/{accordion-D87rF_9b.js → accordion-6vou0XmS.js} +1 -1
  41. package/dist/client/assets/{add-connection-dialog-cS9loTSU.js → add-connection-dialog-DopFZPio.js} +1 -1
  42. package/dist/client/assets/{agent-icon-BbgplFYb.js → agent-icon-CPWEcMkW.js} +1 -1
  43. package/dist/client/assets/{agent-icons-D769sO2y.js → agent-icons-DbyclYUt.js} +1 -1
  44. package/dist/client/assets/{agents-list-BqvI6z2f.js → agents-list-B_iou2CS.js} +1 -1
  45. package/dist/client/assets/{ai-providers-B7Nlf_fJ.js → ai-providers-jnOr5scM.js} +1 -1
  46. package/dist/client/assets/{alert-WZR80uYd.js → alert-DSWorcln.js} +1 -1
  47. package/dist/client/assets/{alert-dialog-CBfLU0-s.js → alert-dialog-jgkN1ow8.js} +1 -1
  48. package/dist/client/assets/{auth-catchall-drkgEnQI.js → auth-catchall-CibJUhS5.js} +1 -1
  49. package/dist/client/assets/{auth-split-layout-D19kU-YG.js → auth-split-layout-B_0OwIje.js} +1 -1
  50. package/dist/client/assets/{automation-list-row-D0ThPhss.js → automation-list-row-CBG4CRxM.js} +1 -1
  51. package/dist/client/assets/{automations-Cat5ivvi.js → automations-CtXXn5AE.js} +1 -1
  52. package/dist/client/assets/{avatar-DeKO2t6e.js → avatar-vA2R8qEK.js} +1 -1
  53. package/dist/client/assets/{badge-DYaA3f0o.js → badge-BFpOlUFq.js} +1 -1
  54. package/dist/client/assets/{brand-context-McBQ2_gj.js → brand-context-DSMoHChs.js} +1 -1
  55. package/dist/client/assets/{card-CzmU6DPx.js → card-Cd_hFdRe.js} +1 -1
  56. package/dist/client/assets/{chat-context-DsnxmnaH.js → chat-context-B5utwD_j.js} +1 -1
  57. package/dist/client/assets/{checkbox-VBT4OFjs.js → checkbox-cX_blfQo.js} +1 -1
  58. package/dist/client/assets/{cli-auth-success-BXNlJk3J.js → cli-auth-success-DRutP4ab.js} +1 -1
  59. package/dist/client/assets/{collection-detail-CNmVClMC.js → collection-detail-BtSEt034.js} +1 -1
  60. package/dist/client/assets/{collection-display-button-DO9Uub4Z.js → collection-display-button-DMY0cf-y.js} +1 -1
  61. package/dist/client/assets/{collection-search-CgHA_hw5.js → collection-search-CLSVS08U.js} +1 -1
  62. package/dist/client/assets/{collection-search-ZgHJOBo2.js → collection-search-XjYetQA3.js} +1 -1
  63. package/dist/client/assets/{collection-table-wrapper-DrLHkx2B.js → collection-table-wrapper-CqVfrSyn.js} +1 -1
  64. package/dist/client/assets/{collection-tabs-DW8sLdGn.js → collection-tabs-Cq1YLx0H.js} +1 -1
  65. package/dist/client/assets/{collections-DVQWcwMA.js → collections-DXz0tqzt.js} +1 -1
  66. package/dist/client/assets/{command-Cdu-1z9q.js → command-C_TH6iOa.js} +1 -1
  67. package/dist/client/assets/{connect-desktop-dialog-CejAAfIG.js → connect-desktop-dialog-CiOZeQs6.js} +1 -1
  68. package/dist/client/assets/{connection-card-kJpbPjBb.js → connection-card-BXYnxALA.js} +1 -1
  69. package/dist/client/assets/{connection-detail-D6x_V51B.js → connection-detail-DV4Eb2Ak.js} +1 -1
  70. package/dist/client/assets/{connection-form-helpers-Dg3964lu.js → connection-form-helpers-DNLR-aHd.js} +1 -1
  71. package/dist/client/assets/{connections-0_RrcJiG.js → connections-JdhjKCmC.js} +1 -1
  72. package/dist/client/assets/{constants-BwYc8BqM.js → constants-oggaZSfP.js} +1 -1
  73. package/dist/client/assets/{decopilot-sse-pool-B9BzYuaT.js → decopilot-sse-pool-atg0HfN2.js} +1 -1
  74. package/dist/client/assets/{dialog-TcaoJB0K.js → dialog-B_fGUV_0.js} +1 -1
  75. package/dist/client/assets/{domain-settings-BnZTuy7Y.js → domain-settings-CAp7ZsSN.js} +1 -1
  76. package/dist/client/assets/{drawer-Db2QUt1V.js → drawer-B6wZPR31.js} +1 -1
  77. package/dist/client/assets/{dropdown-menu-C_xsx5zL.js → dropdown-menu-BUe1eS9C.js} +1 -1
  78. package/dist/client/assets/{dynamic-plugin-layout-B1AK4Qfp.js → dynamic-plugin-layout-5vTDPOk1.js} +1 -1
  79. package/dist/client/assets/{empty-state-DTm9XCIk.js → empty-state-C6lTqnpg.js} +1 -1
  80. package/dist/client/assets/{empty-state-CewyMuo1.js → empty-state-DUBPA5NU.js} +1 -1
  81. package/dist/client/assets/{extract-connection-data-Bh_Tkl8z.js → extract-connection-data-DM9YCvRC.js} +1 -1
  82. package/dist/client/assets/{features-rGWmQRbS.js → features-DeqFL1TF.js} +1 -1
  83. package/dist/client/assets/{file-explorer-BxcoLq7k.js → file-explorer-DGNu1G6y.js} +1 -1
  84. package/dist/client/assets/{files-092UZxGN.js → files-CTFSKbFe.js} +1 -1
  85. package/dist/client/assets/{form-DD66RTDf.js → form-DIJniw7V.js} +1 -1
  86. package/dist/client/assets/{general-DTbdocsc.js → general-C1eIXBGl.js} +1 -1
  87. package/dist/client/assets/{generate-id-DMa8tQ_Y.js → generate-id-CUOrXJD_.js} +1 -1
  88. package/dist/client/assets/{github-repo-picker-BaZinHsd.js → github-repo-picker-CbPGsyKd.js} +1 -1
  89. package/dist/client/assets/{hooks-Bhk1YQ2I.js → hooks-wb_9T_1N.js} +1 -1
  90. package/dist/client/assets/{hover-card-szbVRwlX.js → hover-card-CKXherxT.js} +1 -1
  91. package/dist/client/assets/{index-y9b1xONk.js → index-4hlJQ9pJ.js} +1 -1
  92. package/dist/client/assets/{index-j4kSKfbx.js → index-BcTuPMjJ.js} +1 -1
  93. package/dist/client/assets/{index-BbdQ6KU8.js → index-C4lnfdzw.js} +1 -1
  94. package/dist/client/assets/{index-Dr77wSbz.js → index-C7pSmjIO.js} +1 -1
  95. package/dist/client/assets/{index-Bi14o9BI.js → index-C8daMTSw.js} +1 -1
  96. package/dist/client/assets/{index-DoZOGE8i.js → index-CCOM2TyZ.js} +1 -1
  97. package/dist/client/assets/{index-DbUSKXZz.js → index-CLNFUsz7.js} +1 -1
  98. package/dist/client/assets/{index-cthVMhmX.js → index-CZe7rsCu.js} +1 -1
  99. package/dist/client/assets/{index-CM1D3IOd.js → index-C_etCvW6.js} +2 -2
  100. package/dist/client/assets/{index-C9kZ7-22.js → index-CtrYWx6M.js} +1 -1
  101. package/dist/client/assets/{index-C5X_vClM.js → index-DQI8RGuh.js} +1 -1
  102. package/dist/client/assets/{index-DDxVYHfh.js → index-DTRFlXli.js} +1 -1
  103. package/dist/client/assets/{index-CN3piKjg.js → index-HbdqPSFx.js} +4 -4
  104. package/dist/client/assets/{index-joEaP8qc.js → index-JWYz3SFX.js} +1 -1
  105. package/dist/client/assets/{index-CN1EZuP6.js → index-iXiOYxiI.js} +1 -1
  106. package/dist/client/assets/{index-BNRl1Tot.js → index-oDkRJBov.js} +1 -1
  107. package/dist/client/assets/{infiniteQueryObserver-BThZVpCW.js → infiniteQueryObserver-ClfdJkk7.js} +1 -1
  108. package/dist/client/assets/{input-DrYpnRWV.js → input-CGbgb-E-.js} +1 -1
  109. package/dist/client/assets/{integration-icon-CpEacvrW.js → integration-icon-BruX6m5m.js} +1 -1
  110. package/dist/client/assets/{label-Cm89B89_.js → label-DZerbc9D.js} +1 -1
  111. package/dist/client/assets/{layout-D_sGbaUG.js → layout-BZH9O9Di.js} +1 -1
  112. package/dist/client/assets/{login-B0m7NoXF.js → login-DZffN_aA.js} +1 -1
  113. package/dist/client/assets/{members-TNc3XO9o.js → members-D7h7i7jo.js} +1 -1
  114. package/dist/client/assets/{monaco-editor-DA9r9xlp.js → monaco-editor-5gAmZPD0.js} +1 -1
  115. package/dist/client/assets/{monitoring-stats-row-BAGlU-cw.js → monitoring-stats-row-Bk1ZQbMo.js} +1 -1
  116. package/dist/client/assets/{oauth-callback-Bme8yHJx.js → oauth-callback-BIsI_jqc.js} +1 -1
  117. package/dist/client/assets/{oauth-callback-ai-provider-f1O1WajF.js → oauth-callback-ai-provider-C27n0WFg.js} +1 -1
  118. package/dist/client/assets/{onboarding-CQUJ9k5e.js → onboarding-Ck72MHHt.js} +1 -1
  119. package/dist/client/assets/{org-layout-I5rG58sc.js → org-layout-DKx39VER.js} +1 -1
  120. package/dist/client/assets/{org-plugin-layout-dR6pThVC.js → org-plugin-layout-BaK8uVO_.js} +1 -1
  121. package/dist/client/assets/{pair-DEIG2RgN.js → pair-Cgvtm3hX.js} +1 -1
  122. package/dist/client/assets/{plugin-empty-state-4_sYAII0.js → plugin-empty-state-DDY0jmoN.js} +1 -1
  123. package/dist/client/assets/{plugin-header-BwNgsj_9.js → plugin-header-CtGcek8l.js} +1 -1
  124. package/dist/client/assets/{plugin-layout-7nPkrfcu.js → plugin-layout-oaFFfdTI.js} +1 -1
  125. package/dist/client/assets/{popover-C9ON0IYH.js → popover-xTN6BEZL.js} +1 -1
  126. package/dist/client/assets/{profile-B1MkYulp.js → profile-Bt1eqeyk.js} +1 -1
  127. package/dist/client/assets/{project-app-view-BuPeSGT8.js → project-app-view-C4H7AVbl.js} +1 -1
  128. package/dist/client/assets/registry-BI9574MG.js +2 -0
  129. package/dist/client/assets/{registry-layout-gpmPSOEv.js → registry-layout-COVdyl2V.js} +1 -1
  130. package/dist/client/assets/{required-auth-layout-CUCq1Ujt.js → required-auth-layout-r_pSqbfY.js} +1 -1
  131. package/dist/client/assets/{reset-password-BVGQ_9V7.js → reset-password-C89Bjdhm.js} +1 -1
  132. package/dist/client/assets/{roles-DAPDhbwg.js → roles-Cg2trhAU.js} +1 -1
  133. package/dist/client/assets/{search-input-DKfonUQJ.js → search-input-CjfEjrnk.js} +1 -1
  134. package/dist/client/assets/{secrets-CHWB0VGD.js → secrets-CxfV7l1d.js} +1 -1
  135. package/dist/client/assets/{sections-editor-CeXP_fUW.js → sections-editor-Q3yGyCxb.js} +1 -1
  136. package/dist/client/assets/{select-Bi6n0v1l.js → select-DXIl-nWc.js} +1 -1
  137. package/dist/client/assets/{settings-layout-CCfPNWLq.js → settings-layout-skdEb6EQ.js} +1 -1
  138. package/dist/client/assets/{settings-section-CHdjpjU7.js → settings-section-DRZOyjZN.js} +1 -1
  139. package/dist/client/assets/{shell-controls-EFju5Xuz.js → shell-controls-Bh_0J4mE.js} +1 -1
  140. package/dist/client/assets/{shell-layout-odzNWxkB.js → shell-layout-DX8eVZ8L.js} +1 -1
  141. package/dist/client/assets/{sidebar-DapD5BLH.js → sidebar-BMGvDz3J.js} +1 -1
  142. package/dist/client/assets/{skeleton-BLQ-Z2or.js → skeleton-BNkut-Qo.js} +1 -1
  143. package/dist/client/assets/{sortable.esm-Dvr6sXXz.js → sortable.esm-gCXq3aZO.js} +1 -1
  144. package/dist/client/assets/{spinner-DSdP03Bc.js → spinner-TVmcFRIL.js} +1 -1
  145. package/dist/client/assets/{sso-06euccCF.js → sso-bbmzRIMK.js} +1 -1
  146. package/dist/client/assets/{store-C4RZhwKw.js → store-CioUjuaZ.js} +1 -1
  147. package/dist/client/assets/store-registry-B2Rmo0V0.js +2 -0
  148. package/dist/client/assets/{switch-BOO2ukng.js → switch-khv0BLvL.js} +1 -1
  149. package/dist/client/assets/{table-_uCDG2hl.js → table-C_yNGOnh.js} +1 -1
  150. package/dist/client/assets/{tabs-BQ9tTDv7.js → tabs-DRaRBGe3.js} +1 -1
  151. package/dist/client/assets/{task-status-GEjzAUmm.js → task-status-CkD92yfU.js} +1 -1
  152. package/dist/client/assets/{textarea-DMNeKZeZ.js → textarea-DASnyL4F.js} +1 -1
  153. package/dist/client/assets/{toggle-group-BwRgB5RE.js → toggle-group-DPmEdA-m.js} +1 -1
  154. package/dist/client/assets/{toolbar-ZFFuL6YR.js → toolbar-C9yYx7bm.js} +1 -1
  155. package/dist/client/assets/{tools-list-DXRB9DMK.js → tools-list-psDgt0om.js} +1 -1
  156. package/dist/client/assets/{tooltip-Cc8Oz_Tb.js → tooltip-8OqGw7oG.js} +1 -1
  157. package/dist/client/assets/{types-DETbs5zw.js → types-BmHvFlO1.js} +1 -1
  158. package/dist/client/assets/{use-ai-providers-BFMpjk_o.js → use-ai-providers-CCCd9SIG.js} +1 -1
  159. package/dist/client/assets/{use-collections-CW9RG6h4.js → use-collections-BsrK_euH.js} +1 -1
  160. package/dist/client/assets/{use-connection-BA0O34v3.js → use-connection--tE4CSIP.js} +1 -1
  161. package/dist/client/assets/{use-copy-BI1hoGvu.js → use-copy-CG-PSiHT.js} +1 -1
  162. package/dist/client/assets/{use-create-virtual-mcp-CPLlz8GU.js → use-create-virtual-mcp-DDF2B3SX.js} +1 -1
  163. package/dist/client/assets/{use-debounced-autosave-BwABkJt3.js → use-debounced-autosave-Dj2CoLmA.js} +1 -1
  164. package/dist/client/assets/{use-delete-connection-Dm_6Hsyx.js → use-delete-connection-CDD8AF8I.js} +1 -1
  165. package/dist/client/assets/{use-file-configs-DADtAUxx.js → use-file-configs-B37NAmGU.js} +1 -1
  166. package/dist/client/assets/{use-infinite-scroll-0oj3TOvR.js → use-infinite-scroll-BkFiyWBa.js} +1 -1
  167. package/dist/client/assets/{use-list-state-CCB61-YL.js → use-list-state-BcL02_1r.js} +1 -1
  168. package/dist/client/assets/{use-mcp-prompts-Coi1CKEf.js → use-mcp-prompts-D8zJ1XPI.js} +1 -1
  169. package/dist/client/assets/{use-mcp-tools-DSljy4qc.js → use-mcp-tools-C_ftxwer.js} +1 -1
  170. package/dist/client/assets/{use-members-B1GQuICM.js → use-members-CqC5jIzW.js} +1 -1
  171. package/dist/client/assets/{use-navigate-to-agent-TJFSx1rG.js → use-navigate-to-agent-bdiV5j2z.js} +1 -1
  172. package/dist/client/assets/{use-org-auth-client-CvyxOJ50.js → use-org-auth-client-DtBy8R2R.js} +1 -1
  173. package/dist/client/assets/{use-org-sso-BHhjzT3n.js → use-org-sso-T1wSzyZP.js} +1 -1
  174. package/dist/client/assets/{use-organization-roles-CqvnrNta.js → use-organization-roles-B6nrjgeY.js} +1 -1
  175. package/dist/client/assets/{use-organization-settings-Kf9UVBw8.js → use-organization-settings-CpDAWMUD.js} +1 -1
  176. package/dist/client/assets/{use-registry-connections-CaOaYe6E.js → use-registry-connections-BZm5h5va.js} +1 -1
  177. package/dist/client/assets/{use-secrets-DzvLviXH.js → use-secrets-Bzp6C09M.js} +1 -1
  178. package/dist/client/assets/{use-status-sounds-DAM8WOkV.js → use-status-sounds-BAU2JGUe.js} +1 -1
  179. package/dist/client/assets/{use-view-mode-X_MksRXE.js → use-view-mode-CL1AUq6a.js} +1 -1
  180. package/dist/client/assets/{use-virtual-mcp-2qLUU42J.js → use-virtual-mcp-D92JJRrE.js} +1 -1
  181. package/dist/client/assets/useInfiniteQuery-VRvGrh-Y.js +1 -0
  182. package/dist/client/assets/{useRouterState-D1LxQ93_.js → useRouterState-CFvTFlCq.js} +1 -1
  183. package/dist/client/assets/useSuspenseInfiniteQuery-DWV-fRnj.js +1 -0
  184. package/dist/client/assets/{user-BmoWQK0D.js → user-Cc4_vb_v.js} +1 -1
  185. package/dist/client/assets/{view-mode-toggle-Bt--nFn5.js → view-mode-toggle-B0PLoHTf.js} +1 -1
  186. package/dist/client/assets/workflow-detail-DMN9egvR.js +1 -0
  187. package/dist/client/assets/{workflow-CCgkz7n2.js → workflow-uatlbMiQ.js} +1 -1
  188. package/dist/client/index.html +1 -1
  189. package/dist/server/cli.js +1 -1
  190. package/package.json +1 -1
  191. package/dist/client/assets/registry-BPpui4Vv.js +0 -2
  192. package/dist/client/assets/store-registry-DOjXpenK.js +0 -2
  193. package/dist/client/assets/useInfiniteQuery-6Vl88Gwv.js +0 -1
  194. package/dist/client/assets/useSuspenseInfiniteQuery-Ciek5SC-.js +0 -1
  195. package/dist/client/assets/workflow-detail-C6NUgtqX.js +0 -1
  196. package/dist/server/node_modules/ansi-regex/index.d.ts +0 -33
  197. package/dist/server/node_modules/ansi-regex/index.js +0 -14
  198. package/dist/server/node_modules/ansi-regex/license +0 -9
  199. package/dist/server/node_modules/ansi-regex/package.json +0 -61
  200. package/dist/server/node_modules/ansi-regex/readme.md +0 -66
  201. package/dist/server/node_modules/emoji-regex/LICENSE-MIT.txt +0 -20
  202. package/dist/server/node_modules/emoji-regex/README.md +0 -107
  203. package/dist/server/node_modules/emoji-regex/index.d.ts +0 -3
  204. package/dist/server/node_modules/emoji-regex/index.js +0 -4
  205. package/dist/server/node_modules/emoji-regex/index.mjs +0 -4
  206. package/dist/server/node_modules/emoji-regex/package.json +0 -45
  207. package/dist/server/node_modules/pg-cloudflare/LICENSE +0 -21
  208. package/dist/server/node_modules/pg-cloudflare/README.md +0 -112
  209. package/dist/server/node_modules/pg-cloudflare/dist/empty.d.ts +0 -2
  210. package/dist/server/node_modules/pg-cloudflare/dist/empty.js +0 -6
  211. package/dist/server/node_modules/pg-cloudflare/dist/empty.js.map +0 -1
  212. package/dist/server/node_modules/pg-cloudflare/dist/index.d.ts +0 -31
  213. package/dist/server/node_modules/pg-cloudflare/dist/index.js +0 -152
  214. package/dist/server/node_modules/pg-cloudflare/dist/index.js.map +0 -1
  215. package/dist/server/node_modules/pg-cloudflare/esm/index.mjs +0 -3
  216. package/dist/server/node_modules/pg-cloudflare/package.json +0 -39
  217. package/dist/server/node_modules/pg-cloudflare/src/empty.ts +0 -3
  218. package/dist/server/node_modules/pg-cloudflare/src/index.ts +0 -166
  219. package/dist/server/node_modules/pg-cloudflare/src/types.d.ts +0 -25
  220. package/dist/server/node_modules/pg-connection-string/LICENSE +0 -21
  221. package/dist/server/node_modules/pg-connection-string/README.md +0 -105
  222. package/dist/server/node_modules/pg-connection-string/esm/index.mjs +0 -8
  223. package/dist/server/node_modules/pg-connection-string/index.d.ts +0 -36
  224. package/dist/server/node_modules/pg-connection-string/index.js +0 -231
  225. package/dist/server/node_modules/pg-connection-string/package.json +0 -52
@@ -1 +1 @@
1
- import{r as i,aR as nt,aS as Pe,j as d,c6 as rt,aT as be,b4 as k,c7 as st,a4 as j,a5 as N,c$ as $,c8 as lt,az as _e,c9 as Ee,b7 as at,b5 as ct,a1 as it,ca as dt,cd as ut,cb as pt,ce as ft,cf as mt,ab as ht,cc as gt,cg as vt,ch as xt,e as ee,c as oe}from"./index-CM1D3IOd.js";import{V as St}from"./tooltip-Cc8Oz_Tb.js";import{i as wt}from"./Check-BwR-n-sF.js";import{t as Re}from"./ChevronDown-NgrGgemj.js";import{n as Ct}from"./ChevronUp-O1681VYk.js";function Ne(r,[e,t]){return Math.min(t,Math.max(e,r))}var yt=[" ","Enter","ArrowUp","ArrowDown"],It=[" ","Enter"],J="Select",[de,ue,bt]=at(J),[ne]=ht(J,[bt,Ee]),pe=Ee(),[Tt,G]=ne(J),[Pt,Nt]=ne(J),je=r=>{const{__scopeSelect:e,children:t,open:o,defaultOpen:n,onOpenChange:c,value:s,defaultValue:l,onValueChange:a,dir:u,name:h,autoComplete:v,disabled:b,required:w,form:S}=r,p=pe(e),[g,C]=i.useState(null),[m,x]=i.useState(null),[F,M]=i.useState(!1),re=nt(u),[_,O]=Pe({prop:o,defaultProp:n??!1,onChange:c,caller:J}),[U,q]=Pe({prop:s,defaultProp:l,onChange:a,caller:J}),L=i.useRef(null),B=g?S||!!g.closest("form"):!0,[W,V]=i.useState(new Set),H=Array.from(W).map(E=>E.props.value).join(";");return d.jsx(rt,{...p,children:d.jsxs(Tt,{required:w,scope:e,trigger:g,onTriggerChange:C,valueNode:m,onValueNodeChange:x,valueNodeHasChildren:F,onValueNodeHasChildrenChange:M,contentId:be(),value:U,onValueChange:q,open:_,onOpenChange:O,dir:re,triggerPointerDownPosRef:L,disabled:b,children:[d.jsx(de.Provider,{scope:e,children:d.jsx(Pt,{scope:r.__scopeSelect,onNativeOptionAdd:i.useCallback(E=>{V(D=>new Set(D).add(E))},[]),onNativeOptionRemove:i.useCallback(E=>{V(D=>{const z=new Set(D);return z.delete(E),z})},[]),children:t})}),B?d.jsxs(Qe,{"aria-hidden":!0,required:w,tabIndex:-1,name:h,autoComplete:v,value:U,onChange:E=>q(E.target.value),disabled:b,form:S,children:[U===void 0?d.jsx("option",{value:""}):null,Array.from(W)]},H):null]})})};je.displayName=J;var Me="SelectTrigger",Ae=i.forwardRef((r,e)=>{const{__scopeSelect:t,disabled:o=!1,...n}=r,c=pe(t),s=G(Me,t),l=s.disabled||o,a=k(e,s.onTriggerChange),u=ue(t),h=i.useRef("touch"),[v,b,w]=tt(p=>{const g=u().filter(x=>!x.disabled),C=g.find(x=>x.value===s.value),m=ot(g,p,C);m!==void 0&&s.onValueChange(m.value)}),S=p=>{l||(s.onOpenChange(!0),w()),p&&(s.triggerPointerDownPosRef.current={x:Math.round(p.pageX),y:Math.round(p.pageY)})};return d.jsx(st,{asChild:!0,...c,children:d.jsx(j.button,{type:"button",role:"combobox","aria-controls":s.contentId,"aria-expanded":s.open,"aria-required":s.required,"aria-autocomplete":"none",dir:s.dir,"data-state":s.open?"open":"closed",disabled:l,"data-disabled":l?"":void 0,"data-placeholder":et(s.value)?"":void 0,...n,ref:a,onClick:N(n.onClick,p=>{p.currentTarget.focus(),h.current!=="mouse"&&S(p)}),onPointerDown:N(n.onPointerDown,p=>{h.current=p.pointerType;const g=p.target;g.hasPointerCapture(p.pointerId)&&g.releasePointerCapture(p.pointerId),p.button===0&&p.ctrlKey===!1&&p.pointerType==="mouse"&&(S(p),p.preventDefault())}),onKeyDown:N(n.onKeyDown,p=>{const g=v.current!=="";!(p.ctrlKey||p.altKey||p.metaKey)&&p.key.length===1&&b(p.key),!(g&&p.key===" ")&&yt.includes(p.key)&&(S(),p.preventDefault())})})})});Ae.displayName=Me;var Oe="SelectValue",De=i.forwardRef((r,e)=>{const{__scopeSelect:t,className:o,style:n,children:c,placeholder:s="",...l}=r,a=G(Oe,t),{onValueNodeHasChildrenChange:u}=a,h=c!==void 0,v=k(e,a.onValueNodeChange);return $(()=>{u(h)},[u,h]),d.jsx(j.span,{...l,ref:v,style:{pointerEvents:"none"},children:et(a.value)?d.jsx(d.Fragment,{children:s}):c})});De.displayName=Oe;var _t="SelectIcon",ke=i.forwardRef((r,e)=>{const{__scopeSelect:t,children:o,...n}=r;return d.jsx(j.span,{"aria-hidden":!0,...n,ref:e,children:o||"▼"})});ke.displayName=_t;var Et="SelectPortal",Le=r=>d.jsx(lt,{asChild:!0,...r});Le.displayName=Et;var Q="SelectContent",Be=i.forwardRef((r,e)=>{const t=G(Q,r.__scopeSelect),[o,n]=i.useState();if($(()=>{n(new DocumentFragment)},[]),!t.open){const c=o;return c?_e.createPortal(d.jsx(Ve,{scope:r.__scopeSelect,children:d.jsx(de.Slot,{scope:r.__scopeSelect,children:d.jsx("div",{children:r.children})})}),c):null}return d.jsx(He,{...r,ref:e})});Be.displayName=Q;var A=10,[Ve,Y]=ne(Q),Rt="SelectContentImpl",jt=gt("SelectContent.RemoveScroll"),He=i.forwardRef((r,e)=>{const{__scopeSelect:t,position:o="item-aligned",onCloseAutoFocus:n,onEscapeKeyDown:c,onPointerDownOutside:s,side:l,sideOffset:a,align:u,alignOffset:h,arrowPadding:v,collisionBoundary:b,collisionPadding:w,sticky:S,hideWhenDetached:p,avoidCollisions:g,...C}=r,m=G(Q,t),[x,F]=i.useState(null),[M,re]=i.useState(null),_=k(e,f=>F(f)),[O,U]=i.useState(null),[q,L]=i.useState(null),B=ue(t),[W,V]=i.useState(!1),H=i.useRef(!1);i.useEffect(()=>{if(x)return dt(x)},[x]),ut();const E=i.useCallback(f=>{const[T,...R]=B().map(P=>P.ref.current),[y]=R.slice(-1),I=document.activeElement;for(const P of f)if(P===I||(P?.scrollIntoView({block:"nearest"}),P===T&&M&&(M.scrollTop=0),P===y&&M&&(M.scrollTop=M.scrollHeight),P?.focus(),document.activeElement!==I))return},[B,M]),D=i.useCallback(()=>E([O,x]),[E,O,x]);i.useEffect(()=>{W&&D()},[W,D]);const{onOpenChange:z,triggerPointerDownPosRef:K}=m;i.useEffect(()=>{if(x){let f={x:0,y:0};const T=y=>{f={x:Math.abs(Math.round(y.pageX)-(K.current?.x??0)),y:Math.abs(Math.round(y.pageY)-(K.current?.y??0))}},R=y=>{f.x<=10&&f.y<=10?y.preventDefault():x.contains(y.target)||z(!1),document.removeEventListener("pointermove",T),K.current=null};return K.current!==null&&(document.addEventListener("pointermove",T),document.addEventListener("pointerup",R,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",T),document.removeEventListener("pointerup",R,{capture:!0})}}},[x,z,K]),i.useEffect(()=>{const f=()=>z(!1);return window.addEventListener("blur",f),window.addEventListener("resize",f),()=>{window.removeEventListener("blur",f),window.removeEventListener("resize",f)}},[z]);const[fe,ae]=tt(f=>{const T=B().filter(I=>!I.disabled),R=T.find(I=>I.ref.current===document.activeElement),y=ot(T,f,R);y&&setTimeout(()=>y.ref.current.focus())}),me=i.useCallback((f,T,R)=>{const y=!H.current&&!R;(m.value!==void 0&&m.value===T||y)&&(U(f),y&&(H.current=!0))},[m.value]),he=i.useCallback(()=>x?.focus(),[x]),te=i.useCallback((f,T,R)=>{const y=!H.current&&!R;(m.value!==void 0&&m.value===T||y)&&L(f)},[m.value]),ce=o==="popper"?Se:ze,se=ce===Se?{side:l,sideOffset:a,align:u,alignOffset:h,arrowPadding:v,collisionBoundary:b,collisionPadding:w,sticky:S,hideWhenDetached:p,avoidCollisions:g}:{};return d.jsx(Ve,{scope:t,content:x,viewport:M,onViewportChange:re,itemRefCallback:me,selectedItem:O,onItemLeave:he,itemTextRefCallback:te,focusSelectedItem:D,selectedItemText:q,position:o,isPositioned:W,searchRef:fe,children:d.jsx(pt,{as:jt,allowPinchZoom:!0,children:d.jsx(ft,{asChild:!0,trapped:m.open,onMountAutoFocus:f=>{f.preventDefault()},onUnmountAutoFocus:N(n,f=>{m.trigger?.focus({preventScroll:!0}),f.preventDefault()}),children:d.jsx(mt,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:c,onPointerDownOutside:s,onFocusOutside:f=>f.preventDefault(),onDismiss:()=>m.onOpenChange(!1),children:d.jsx(ce,{role:"listbox",id:m.contentId,"data-state":m.open?"open":"closed",dir:m.dir,onContextMenu:f=>f.preventDefault(),...C,...se,onPlaced:()=>V(!0),ref:_,style:{display:"flex",flexDirection:"column",outline:"none",...C.style},onKeyDown:N(C.onKeyDown,f=>{const T=f.ctrlKey||f.altKey||f.metaKey;if(f.key==="Tab"&&f.preventDefault(),!T&&f.key.length===1&&ae(f.key),["ArrowUp","ArrowDown","Home","End"].includes(f.key)){let y=B().filter(I=>!I.disabled).map(I=>I.ref.current);if(["ArrowUp","End"].includes(f.key)&&(y=y.slice().reverse()),["ArrowUp","ArrowDown"].includes(f.key)){const I=f.target,P=y.indexOf(I);y=y.slice(P+1)}setTimeout(()=>E(y)),f.preventDefault()}})})})})})})});He.displayName=Rt;var Mt="SelectItemAlignedPosition",ze=i.forwardRef((r,e)=>{const{__scopeSelect:t,onPlaced:o,...n}=r,c=G(Q,t),s=Y(Q,t),[l,a]=i.useState(null),[u,h]=i.useState(null),v=k(e,_=>h(_)),b=ue(t),w=i.useRef(!1),S=i.useRef(!0),{viewport:p,selectedItem:g,selectedItemText:C,focusSelectedItem:m}=s,x=i.useCallback(()=>{if(c.trigger&&c.valueNode&&l&&u&&p&&g&&C){const _=c.trigger.getBoundingClientRect(),O=u.getBoundingClientRect(),U=c.valueNode.getBoundingClientRect(),q=C.getBoundingClientRect();if(c.dir!=="rtl"){const I=q.left-O.left,P=U.left-I,X=_.left-P,Z=_.width+X,ge=Math.max(Z,O.width),ve=window.innerWidth-A,xe=Ne(P,[A,Math.max(A,ve-ge)]);l.style.minWidth=Z+"px",l.style.left=xe+"px"}else{const I=O.right-q.right,P=window.innerWidth-U.right-I,X=window.innerWidth-_.right-P,Z=_.width+X,ge=Math.max(Z,O.width),ve=window.innerWidth-A,xe=Ne(P,[A,Math.max(A,ve-ge)]);l.style.minWidth=Z+"px",l.style.right=xe+"px"}const L=b(),B=window.innerHeight-A*2,W=p.scrollHeight,V=window.getComputedStyle(u),H=parseInt(V.borderTopWidth,10),E=parseInt(V.paddingTop,10),D=parseInt(V.borderBottomWidth,10),z=parseInt(V.paddingBottom,10),K=H+E+W+z+D,fe=Math.min(g.offsetHeight*5,K),ae=window.getComputedStyle(p),me=parseInt(ae.paddingTop,10),he=parseInt(ae.paddingBottom,10),te=_.top+_.height/2-A,ce=B-te,se=g.offsetHeight/2,f=g.offsetTop+se,T=H+E+f,R=K-T;if(T<=te){const I=L.length>0&&g===L[L.length-1].ref.current;l.style.bottom="0px";const P=u.clientHeight-p.offsetTop-p.offsetHeight,X=Math.max(ce,se+(I?he:0)+P+D),Z=T+X;l.style.height=Z+"px"}else{const I=L.length>0&&g===L[0].ref.current;l.style.top="0px";const X=Math.max(te,H+p.offsetTop+(I?me:0)+se)+R;l.style.height=X+"px",p.scrollTop=T-te+p.offsetTop}l.style.margin=`${A}px 0`,l.style.minHeight=fe+"px",l.style.maxHeight=B+"px",o?.(),requestAnimationFrame(()=>w.current=!0)}},[b,c.trigger,c.valueNode,l,u,p,g,C,c.dir,o]);$(()=>x(),[x]);const[F,M]=i.useState();$(()=>{u&&M(window.getComputedStyle(u).zIndex)},[u]);const re=i.useCallback(_=>{_&&S.current===!0&&(x(),m?.(),S.current=!1)},[x,m]);return d.jsx(Ot,{scope:t,contentWrapper:l,shouldExpandOnScrollRef:w,onScrollButtonChange:re,children:d.jsx("div",{ref:a,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:F},children:d.jsx(j.div,{...n,ref:v,style:{boxSizing:"border-box",maxHeight:"100%",...n.style}})})})});ze.displayName=Mt;var At="SelectPopperPosition",Se=i.forwardRef((r,e)=>{const{__scopeSelect:t,align:o="start",collisionPadding:n=A,...c}=r,s=pe(t);return d.jsx(vt,{...s,...c,ref:e,align:o,collisionPadding:n,style:{boxSizing:"border-box",...c.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});Se.displayName=At;var[Ot,Te]=ne(Q,{}),we="SelectViewport",Fe=i.forwardRef((r,e)=>{const{__scopeSelect:t,nonce:o,...n}=r,c=Y(we,t),s=Te(we,t),l=k(e,c.onViewportChange),a=i.useRef(0);return d.jsxs(d.Fragment,{children:[d.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:o}),d.jsx(de.Slot,{scope:t,children:d.jsx(j.div,{"data-radix-select-viewport":"",role:"presentation",...n,ref:l,style:{position:"relative",flex:1,overflow:"hidden auto",...n.style},onScroll:N(n.onScroll,u=>{const h=u.currentTarget,{contentWrapper:v,shouldExpandOnScrollRef:b}=s;if(b?.current&&v){const w=Math.abs(a.current-h.scrollTop);if(w>0){const S=window.innerHeight-A*2,p=parseFloat(v.style.minHeight),g=parseFloat(v.style.height),C=Math.max(p,g);if(C<S){const m=C+w,x=Math.min(S,m),F=m-x;v.style.height=x+"px",v.style.bottom==="0px"&&(h.scrollTop=F>0?F:0,v.style.justifyContent="flex-end")}}}a.current=h.scrollTop})})})]})});Fe.displayName=we;var Ue="SelectGroup",[Dt,kt]=ne(Ue),Lt=i.forwardRef((r,e)=>{const{__scopeSelect:t,...o}=r,n=be();return d.jsx(Dt,{scope:t,id:n,children:d.jsx(j.div,{role:"group","aria-labelledby":n,...o,ref:e})})});Lt.displayName=Ue;var We="SelectLabel",Bt=i.forwardRef((r,e)=>{const{__scopeSelect:t,...o}=r,n=kt(We,t);return d.jsx(j.div,{id:n.id,...o,ref:e})});Bt.displayName=We;var ie="SelectItem",[Vt,Ke]=ne(ie),$e=i.forwardRef((r,e)=>{const{__scopeSelect:t,value:o,disabled:n=!1,textValue:c,...s}=r,l=G(ie,t),a=Y(ie,t),u=l.value===o,[h,v]=i.useState(c??""),[b,w]=i.useState(!1),S=k(e,m=>a.itemRefCallback?.(m,o,n)),p=be(),g=i.useRef("touch"),C=()=>{n||(l.onValueChange(o),l.onOpenChange(!1))};if(o==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return d.jsx(Vt,{scope:t,value:o,disabled:n,textId:p,isSelected:u,onItemTextChange:i.useCallback(m=>{v(x=>x||(m?.textContent??"").trim())},[]),children:d.jsx(de.ItemSlot,{scope:t,value:o,disabled:n,textValue:h,children:d.jsx(j.div,{role:"option","aria-labelledby":p,"data-highlighted":b?"":void 0,"aria-selected":u&&b,"data-state":u?"checked":"unchecked","aria-disabled":n||void 0,"data-disabled":n?"":void 0,tabIndex:n?void 0:-1,...s,ref:S,onFocus:N(s.onFocus,()=>w(!0)),onBlur:N(s.onBlur,()=>w(!1)),onClick:N(s.onClick,()=>{g.current!=="mouse"&&C()}),onPointerUp:N(s.onPointerUp,()=>{g.current==="mouse"&&C()}),onPointerDown:N(s.onPointerDown,m=>{g.current=m.pointerType}),onPointerMove:N(s.onPointerMove,m=>{g.current=m.pointerType,n?a.onItemLeave?.():g.current==="mouse"&&m.currentTarget.focus({preventScroll:!0})}),onPointerLeave:N(s.onPointerLeave,m=>{m.currentTarget===document.activeElement&&a.onItemLeave?.()}),onKeyDown:N(s.onKeyDown,m=>{a.searchRef?.current!==""&&m.key===" "||(It.includes(m.key)&&C(),m.key===" "&&m.preventDefault())})})})})});$e.displayName=ie;var le="SelectItemText",Ge=i.forwardRef((r,e)=>{const{__scopeSelect:t,className:o,style:n,...c}=r,s=G(le,t),l=Y(le,t),a=Ke(le,t),u=Nt(le,t),[h,v]=i.useState(null),b=k(e,C=>v(C),a.onItemTextChange,C=>l.itemTextRefCallback?.(C,a.value,a.disabled)),w=h?.textContent,S=i.useMemo(()=>d.jsx("option",{value:a.value,disabled:a.disabled,children:w},a.value),[a.disabled,a.value,w]),{onNativeOptionAdd:p,onNativeOptionRemove:g}=u;return $(()=>(p(S),()=>g(S)),[p,g,S]),d.jsxs(d.Fragment,{children:[d.jsx(j.span,{id:a.textId,...c,ref:b}),a.isSelected&&s.valueNode&&!s.valueNodeHasChildren?_e.createPortal(c.children,s.valueNode):null]})});Ge.displayName=le;var Ye="SelectItemIndicator",qe=i.forwardRef((r,e)=>{const{__scopeSelect:t,...o}=r;return Ke(Ye,t).isSelected?d.jsx(j.span,{"aria-hidden":!0,...o,ref:e}):null});qe.displayName=Ye;var Ce="SelectScrollUpButton",Xe=i.forwardRef((r,e)=>{const t=Y(Ce,r.__scopeSelect),o=Te(Ce,r.__scopeSelect),[n,c]=i.useState(!1),s=k(e,o.onScrollButtonChange);return $(()=>{if(t.viewport&&t.isPositioned){let l=function(){const u=a.scrollTop>0;c(u)};const a=t.viewport;return l(),a.addEventListener("scroll",l),()=>a.removeEventListener("scroll",l)}},[t.viewport,t.isPositioned]),n?d.jsx(Je,{...r,ref:s,onAutoScroll:()=>{const{viewport:l,selectedItem:a}=t;l&&a&&(l.scrollTop=l.scrollTop-a.offsetHeight)}}):null});Xe.displayName=Ce;var ye="SelectScrollDownButton",Ze=i.forwardRef((r,e)=>{const t=Y(ye,r.__scopeSelect),o=Te(ye,r.__scopeSelect),[n,c]=i.useState(!1),s=k(e,o.onScrollButtonChange);return $(()=>{if(t.viewport&&t.isPositioned){let l=function(){const u=a.scrollHeight-a.clientHeight,h=Math.ceil(a.scrollTop)<u;c(h)};const a=t.viewport;return l(),a.addEventListener("scroll",l),()=>a.removeEventListener("scroll",l)}},[t.viewport,t.isPositioned]),n?d.jsx(Je,{...r,ref:s,onAutoScroll:()=>{const{viewport:l,selectedItem:a}=t;l&&a&&(l.scrollTop=l.scrollTop+a.offsetHeight)}}):null});Ze.displayName=ye;var Je=i.forwardRef((r,e)=>{const{__scopeSelect:t,onAutoScroll:o,...n}=r,c=Y("SelectScrollButton",t),s=i.useRef(null),l=ue(t),a=i.useCallback(()=>{s.current!==null&&(window.clearInterval(s.current),s.current=null)},[]);return i.useEffect(()=>()=>a(),[a]),$(()=>{l().find(h=>h.ref.current===document.activeElement)?.ref.current?.scrollIntoView({block:"nearest"})},[l]),d.jsx(j.div,{"aria-hidden":!0,...n,ref:e,style:{flexShrink:0,...n.style},onPointerDown:N(n.onPointerDown,()=>{s.current===null&&(s.current=window.setInterval(o,50))}),onPointerMove:N(n.onPointerMove,()=>{c.onItemLeave?.(),s.current===null&&(s.current=window.setInterval(o,50))}),onPointerLeave:N(n.onPointerLeave,()=>{a()})})}),Ht="SelectSeparator",zt=i.forwardRef((r,e)=>{const{__scopeSelect:t,...o}=r;return d.jsx(j.div,{"aria-hidden":!0,...o,ref:e})});zt.displayName=Ht;var Ie="SelectArrow",Ft=i.forwardRef((r,e)=>{const{__scopeSelect:t,...o}=r,n=pe(t),c=G(Ie,t),s=Y(Ie,t);return c.open&&s.position==="popper"?d.jsx(xt,{...n,...o,ref:e}):null});Ft.displayName=Ie;var Ut="SelectBubbleInput",Qe=i.forwardRef(({__scopeSelect:r,value:e,...t},o)=>{const n=i.useRef(null),c=k(o,n),s=ct(e);return i.useEffect(()=>{const l=n.current;if(!l)return;const a=window.HTMLSelectElement.prototype,h=Object.getOwnPropertyDescriptor(a,"value").set;if(s!==e&&h){const v=new Event("change",{bubbles:!0});h.call(l,e),l.dispatchEvent(v)}},[s,e]),d.jsx(j.select,{...t,style:{...St,...t.style},ref:c,defaultValue:e})});Qe.displayName=Ut;function et(r){return r===""||r===void 0}function tt(r){const e=it(r),t=i.useRef(""),o=i.useRef(0),n=i.useCallback(s=>{const l=t.current+s;e(l),(function a(u){t.current=u,window.clearTimeout(o.current),u!==""&&(o.current=window.setTimeout(()=>a(""),1e3))})(l)},[e]),c=i.useCallback(()=>{t.current="",window.clearTimeout(o.current)},[]);return i.useEffect(()=>()=>window.clearTimeout(o.current),[]),[t,n,c]}function ot(r,e,t){const n=e.length>1&&Array.from(e).every(u=>u===e[0])?e[0]:e,c=t?r.indexOf(t):-1;let s=Wt(r,Math.max(c,0));n.length===1&&(s=s.filter(u=>u!==t));const a=s.find(u=>u.textValue.toLowerCase().startsWith(n.toLowerCase()));return a!==t?a:void 0}function Wt(r,e){return r.map((t,o)=>r[(e+o)%r.length])}var Kt=je,$t=Ae,Gt=De,Yt=ke,qt=Le,Xt=Be,Zt=Fe,Jt=$e,Qt=Ge,eo=qe,to=Xe,oo=Ze;function uo(r){const e=ee.c(4);let t;e[0]!==r?({...t}=r,e[0]=r,e[1]=t):t=e[1];let o;return e[2]!==t?(o=d.jsx(Kt,{"data-slot":"select",...t}),e[2]=t,e[3]=o):o=e[3],o}function po(r){const e=ee.c(4);let t;e[0]!==r?({...t}=r,e[0]=r,e[1]=t):t=e[1];let o;return e[2]!==t?(o=d.jsx(Gt,{"data-slot":"select-value",...t}),e[2]=t,e[3]=o):o=e[3],o}function fo(r){const e=ee.c(13);let t,o,n,c;e[0]!==r?({className:o,size:c,children:t,...n}=r,e[0]=r,e[1]=t,e[2]=o,e[3]=n,e[4]=c):(t=e[1],o=e[2],n=e[3],c=e[4]);const s=c===void 0?"default":c;let l;e[5]!==o?(l=oe("data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/20 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 hover:bg-accent hover:text-accent-foreground dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-lg bg-background px-3 py-2 text-sm whitespace-nowrap transition-[color,box-shadow] outline-none focus-visible:ring-[2px] card-shadow disabled:opacity-50 data-[size=default]:h-8 data-[size=sm]:h-7 data-[size=xs]:h-6 data-[size=xs]:px-2.5 data-[size=xs]:py-1.5 data-[size=xs]:rounded-lg *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",o),e[5]=o,e[6]=l):l=e[6];let a;e[7]===Symbol.for("react.memo_cache_sentinel")?(a=d.jsx(Yt,{asChild:!0,children:d.jsx(Re,{className:"size-4 opacity-50"})}),e[7]=a):a=e[7];let u;return e[8]!==t||e[9]!==n||e[10]!==s||e[11]!==l?(u=d.jsxs($t,{"data-slot":"select-trigger","data-size":s,className:l,...n,children:[t,a]}),e[8]=t,e[9]=n,e[10]=s,e[11]=l,e[12]=u):u=e[12],u}function mo(r){const e=ee.c(25);let t,o,n,c,s;e[0]!==r?({className:o,children:t,position:c,hideScrollButtons:s,...n}=r,e[0]=r,e[1]=t,e[2]=o,e[3]=n,e[4]=c,e[5]=s):(t=e[1],o=e[2],n=e[3],c=e[4],s=e[5]);const l=c===void 0?"popper":c,a=s===void 0?!1:s,u=l==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1";let h;e[6]!==o||e[7]!==u?(h=oe("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg border shadow-md",u,o),e[6]=o,e[7]=u,e[8]=h):h=e[8];let v;e[9]!==a?(v=!a&&d.jsx(no,{}),e[9]=a,e[10]=v):v=e[10];const b=l==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1";let w;e[11]!==b?(w=oe("p-1",b),e[11]=b,e[12]=w):w=e[12];let S;e[13]!==t||e[14]!==w?(S=d.jsx(Zt,{className:w,children:t}),e[13]=t,e[14]=w,e[15]=S):S=e[15];let p;e[16]!==a?(p=!a&&d.jsx(ro,{}),e[16]=a,e[17]=p):p=e[17];let g;return e[18]!==l||e[19]!==n||e[20]!==h||e[21]!==v||e[22]!==S||e[23]!==p?(g=d.jsx(qt,{children:d.jsxs(Xt,{"data-slot":"select-content",className:h,position:l,...n,children:[v,S,p]})}),e[18]=l,e[19]=n,e[20]=h,e[21]=v,e[22]=S,e[23]=p,e[24]=g):g=e[24],g}function ho(r){const e=ee.c(16);let t,o,n,c;e[0]!==r?({className:o,children:t,hideCheck:c,...n}=r,e[0]=r,e[1]=t,e[2]=o,e[3]=n,e[4]=c):(t=e[1],o=e[2],n=e[3],c=e[4]);const s=c===void 0?!1:c;let l;e[5]!==o?(l=oe("focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-lg py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",o),e[5]=o,e[6]=l):l=e[6];let a;e[7]!==s?(a=!s&&d.jsx("span",{className:"absolute right-2 flex size-3.5 items-center justify-center",children:d.jsx(eo,{children:d.jsx(wt,{className:"size-4"})})}),e[7]=s,e[8]=a):a=e[8];let u;e[9]!==t?(u=d.jsx(Qt,{children:t}),e[9]=t,e[10]=u):u=e[10];let h;return e[11]!==n||e[12]!==l||e[13]!==a||e[14]!==u?(h=d.jsxs(Jt,{"data-slot":"select-item",className:l,...n,children:[a,u]}),e[11]=n,e[12]=l,e[13]=a,e[14]=u,e[15]=h):h=e[15],h}function no(r){const e=ee.c(9);let t,o;e[0]!==r?({className:t,...o}=r,e[0]=r,e[1]=t,e[2]=o):(t=e[1],o=e[2]);let n;e[3]!==t?(n=oe("flex cursor-default items-center justify-center py-1",t),e[3]=t,e[4]=n):n=e[4];let c;e[5]===Symbol.for("react.memo_cache_sentinel")?(c=d.jsx(Ct,{className:"size-4"}),e[5]=c):c=e[5];let s;return e[6]!==o||e[7]!==n?(s=d.jsx(to,{"data-slot":"select-scroll-up-button",className:n,...o,children:c}),e[6]=o,e[7]=n,e[8]=s):s=e[8],s}function ro(r){const e=ee.c(9);let t,o;e[0]!==r?({className:t,...o}=r,e[0]=r,e[1]=t,e[2]=o):(t=e[1],o=e[2]);let n;e[3]!==t?(n=oe("flex cursor-default items-center justify-center py-1",t),e[3]=t,e[4]=n):n=e[4];let c;e[5]===Symbol.for("react.memo_cache_sentinel")?(c=d.jsx(Re,{className:"size-4"}),e[5]=c):c=e[5];let s;return e[6]!==o||e[7]!==n?(s=d.jsx(oo,{"data-slot":"select-scroll-down-button",className:n,...o,children:c}),e[6]=o,e[7]=n,e[8]=s):s=e[8],s}export{uo as S,fo as a,po as b,mo as c,ho as d,Ne as e};
1
+ import{r as i,aR as nt,aS as Pe,j as d,c6 as rt,aT as be,b4 as k,c7 as st,a4 as j,a5 as N,c$ as $,c8 as lt,az as _e,c9 as Ee,b7 as at,b5 as ct,a1 as it,ca as dt,cd as ut,cb as pt,ce as ft,cf as mt,ab as ht,cc as gt,cg as vt,ch as xt,e as ee,c as oe}from"./index-C_etCvW6.js";import{V as St}from"./tooltip-8OqGw7oG.js";import{i as wt}from"./Check-8Z25AyId.js";import{t as Re}from"./ChevronDown-DYIWk9ra.js";import{n as Ct}from"./ChevronUp-CdhHmg9Y.js";function Ne(r,[e,t]){return Math.min(t,Math.max(e,r))}var yt=[" ","Enter","ArrowUp","ArrowDown"],It=[" ","Enter"],J="Select",[de,ue,bt]=at(J),[ne]=ht(J,[bt,Ee]),pe=Ee(),[Tt,G]=ne(J),[Pt,Nt]=ne(J),je=r=>{const{__scopeSelect:e,children:t,open:o,defaultOpen:n,onOpenChange:c,value:s,defaultValue:l,onValueChange:a,dir:u,name:h,autoComplete:v,disabled:b,required:w,form:S}=r,p=pe(e),[g,C]=i.useState(null),[m,x]=i.useState(null),[F,M]=i.useState(!1),re=nt(u),[_,O]=Pe({prop:o,defaultProp:n??!1,onChange:c,caller:J}),[U,q]=Pe({prop:s,defaultProp:l,onChange:a,caller:J}),L=i.useRef(null),B=g?S||!!g.closest("form"):!0,[W,V]=i.useState(new Set),H=Array.from(W).map(E=>E.props.value).join(";");return d.jsx(rt,{...p,children:d.jsxs(Tt,{required:w,scope:e,trigger:g,onTriggerChange:C,valueNode:m,onValueNodeChange:x,valueNodeHasChildren:F,onValueNodeHasChildrenChange:M,contentId:be(),value:U,onValueChange:q,open:_,onOpenChange:O,dir:re,triggerPointerDownPosRef:L,disabled:b,children:[d.jsx(de.Provider,{scope:e,children:d.jsx(Pt,{scope:r.__scopeSelect,onNativeOptionAdd:i.useCallback(E=>{V(D=>new Set(D).add(E))},[]),onNativeOptionRemove:i.useCallback(E=>{V(D=>{const z=new Set(D);return z.delete(E),z})},[]),children:t})}),B?d.jsxs(Qe,{"aria-hidden":!0,required:w,tabIndex:-1,name:h,autoComplete:v,value:U,onChange:E=>q(E.target.value),disabled:b,form:S,children:[U===void 0?d.jsx("option",{value:""}):null,Array.from(W)]},H):null]})})};je.displayName=J;var Me="SelectTrigger",Ae=i.forwardRef((r,e)=>{const{__scopeSelect:t,disabled:o=!1,...n}=r,c=pe(t),s=G(Me,t),l=s.disabled||o,a=k(e,s.onTriggerChange),u=ue(t),h=i.useRef("touch"),[v,b,w]=tt(p=>{const g=u().filter(x=>!x.disabled),C=g.find(x=>x.value===s.value),m=ot(g,p,C);m!==void 0&&s.onValueChange(m.value)}),S=p=>{l||(s.onOpenChange(!0),w()),p&&(s.triggerPointerDownPosRef.current={x:Math.round(p.pageX),y:Math.round(p.pageY)})};return d.jsx(st,{asChild:!0,...c,children:d.jsx(j.button,{type:"button",role:"combobox","aria-controls":s.contentId,"aria-expanded":s.open,"aria-required":s.required,"aria-autocomplete":"none",dir:s.dir,"data-state":s.open?"open":"closed",disabled:l,"data-disabled":l?"":void 0,"data-placeholder":et(s.value)?"":void 0,...n,ref:a,onClick:N(n.onClick,p=>{p.currentTarget.focus(),h.current!=="mouse"&&S(p)}),onPointerDown:N(n.onPointerDown,p=>{h.current=p.pointerType;const g=p.target;g.hasPointerCapture(p.pointerId)&&g.releasePointerCapture(p.pointerId),p.button===0&&p.ctrlKey===!1&&p.pointerType==="mouse"&&(S(p),p.preventDefault())}),onKeyDown:N(n.onKeyDown,p=>{const g=v.current!=="";!(p.ctrlKey||p.altKey||p.metaKey)&&p.key.length===1&&b(p.key),!(g&&p.key===" ")&&yt.includes(p.key)&&(S(),p.preventDefault())})})})});Ae.displayName=Me;var Oe="SelectValue",De=i.forwardRef((r,e)=>{const{__scopeSelect:t,className:o,style:n,children:c,placeholder:s="",...l}=r,a=G(Oe,t),{onValueNodeHasChildrenChange:u}=a,h=c!==void 0,v=k(e,a.onValueNodeChange);return $(()=>{u(h)},[u,h]),d.jsx(j.span,{...l,ref:v,style:{pointerEvents:"none"},children:et(a.value)?d.jsx(d.Fragment,{children:s}):c})});De.displayName=Oe;var _t="SelectIcon",ke=i.forwardRef((r,e)=>{const{__scopeSelect:t,children:o,...n}=r;return d.jsx(j.span,{"aria-hidden":!0,...n,ref:e,children:o||"▼"})});ke.displayName=_t;var Et="SelectPortal",Le=r=>d.jsx(lt,{asChild:!0,...r});Le.displayName=Et;var Q="SelectContent",Be=i.forwardRef((r,e)=>{const t=G(Q,r.__scopeSelect),[o,n]=i.useState();if($(()=>{n(new DocumentFragment)},[]),!t.open){const c=o;return c?_e.createPortal(d.jsx(Ve,{scope:r.__scopeSelect,children:d.jsx(de.Slot,{scope:r.__scopeSelect,children:d.jsx("div",{children:r.children})})}),c):null}return d.jsx(He,{...r,ref:e})});Be.displayName=Q;var A=10,[Ve,Y]=ne(Q),Rt="SelectContentImpl",jt=gt("SelectContent.RemoveScroll"),He=i.forwardRef((r,e)=>{const{__scopeSelect:t,position:o="item-aligned",onCloseAutoFocus:n,onEscapeKeyDown:c,onPointerDownOutside:s,side:l,sideOffset:a,align:u,alignOffset:h,arrowPadding:v,collisionBoundary:b,collisionPadding:w,sticky:S,hideWhenDetached:p,avoidCollisions:g,...C}=r,m=G(Q,t),[x,F]=i.useState(null),[M,re]=i.useState(null),_=k(e,f=>F(f)),[O,U]=i.useState(null),[q,L]=i.useState(null),B=ue(t),[W,V]=i.useState(!1),H=i.useRef(!1);i.useEffect(()=>{if(x)return dt(x)},[x]),ut();const E=i.useCallback(f=>{const[T,...R]=B().map(P=>P.ref.current),[y]=R.slice(-1),I=document.activeElement;for(const P of f)if(P===I||(P?.scrollIntoView({block:"nearest"}),P===T&&M&&(M.scrollTop=0),P===y&&M&&(M.scrollTop=M.scrollHeight),P?.focus(),document.activeElement!==I))return},[B,M]),D=i.useCallback(()=>E([O,x]),[E,O,x]);i.useEffect(()=>{W&&D()},[W,D]);const{onOpenChange:z,triggerPointerDownPosRef:K}=m;i.useEffect(()=>{if(x){let f={x:0,y:0};const T=y=>{f={x:Math.abs(Math.round(y.pageX)-(K.current?.x??0)),y:Math.abs(Math.round(y.pageY)-(K.current?.y??0))}},R=y=>{f.x<=10&&f.y<=10?y.preventDefault():x.contains(y.target)||z(!1),document.removeEventListener("pointermove",T),K.current=null};return K.current!==null&&(document.addEventListener("pointermove",T),document.addEventListener("pointerup",R,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",T),document.removeEventListener("pointerup",R,{capture:!0})}}},[x,z,K]),i.useEffect(()=>{const f=()=>z(!1);return window.addEventListener("blur",f),window.addEventListener("resize",f),()=>{window.removeEventListener("blur",f),window.removeEventListener("resize",f)}},[z]);const[fe,ae]=tt(f=>{const T=B().filter(I=>!I.disabled),R=T.find(I=>I.ref.current===document.activeElement),y=ot(T,f,R);y&&setTimeout(()=>y.ref.current.focus())}),me=i.useCallback((f,T,R)=>{const y=!H.current&&!R;(m.value!==void 0&&m.value===T||y)&&(U(f),y&&(H.current=!0))},[m.value]),he=i.useCallback(()=>x?.focus(),[x]),te=i.useCallback((f,T,R)=>{const y=!H.current&&!R;(m.value!==void 0&&m.value===T||y)&&L(f)},[m.value]),ce=o==="popper"?Se:ze,se=ce===Se?{side:l,sideOffset:a,align:u,alignOffset:h,arrowPadding:v,collisionBoundary:b,collisionPadding:w,sticky:S,hideWhenDetached:p,avoidCollisions:g}:{};return d.jsx(Ve,{scope:t,content:x,viewport:M,onViewportChange:re,itemRefCallback:me,selectedItem:O,onItemLeave:he,itemTextRefCallback:te,focusSelectedItem:D,selectedItemText:q,position:o,isPositioned:W,searchRef:fe,children:d.jsx(pt,{as:jt,allowPinchZoom:!0,children:d.jsx(ft,{asChild:!0,trapped:m.open,onMountAutoFocus:f=>{f.preventDefault()},onUnmountAutoFocus:N(n,f=>{m.trigger?.focus({preventScroll:!0}),f.preventDefault()}),children:d.jsx(mt,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:c,onPointerDownOutside:s,onFocusOutside:f=>f.preventDefault(),onDismiss:()=>m.onOpenChange(!1),children:d.jsx(ce,{role:"listbox",id:m.contentId,"data-state":m.open?"open":"closed",dir:m.dir,onContextMenu:f=>f.preventDefault(),...C,...se,onPlaced:()=>V(!0),ref:_,style:{display:"flex",flexDirection:"column",outline:"none",...C.style},onKeyDown:N(C.onKeyDown,f=>{const T=f.ctrlKey||f.altKey||f.metaKey;if(f.key==="Tab"&&f.preventDefault(),!T&&f.key.length===1&&ae(f.key),["ArrowUp","ArrowDown","Home","End"].includes(f.key)){let y=B().filter(I=>!I.disabled).map(I=>I.ref.current);if(["ArrowUp","End"].includes(f.key)&&(y=y.slice().reverse()),["ArrowUp","ArrowDown"].includes(f.key)){const I=f.target,P=y.indexOf(I);y=y.slice(P+1)}setTimeout(()=>E(y)),f.preventDefault()}})})})})})})});He.displayName=Rt;var Mt="SelectItemAlignedPosition",ze=i.forwardRef((r,e)=>{const{__scopeSelect:t,onPlaced:o,...n}=r,c=G(Q,t),s=Y(Q,t),[l,a]=i.useState(null),[u,h]=i.useState(null),v=k(e,_=>h(_)),b=ue(t),w=i.useRef(!1),S=i.useRef(!0),{viewport:p,selectedItem:g,selectedItemText:C,focusSelectedItem:m}=s,x=i.useCallback(()=>{if(c.trigger&&c.valueNode&&l&&u&&p&&g&&C){const _=c.trigger.getBoundingClientRect(),O=u.getBoundingClientRect(),U=c.valueNode.getBoundingClientRect(),q=C.getBoundingClientRect();if(c.dir!=="rtl"){const I=q.left-O.left,P=U.left-I,X=_.left-P,Z=_.width+X,ge=Math.max(Z,O.width),ve=window.innerWidth-A,xe=Ne(P,[A,Math.max(A,ve-ge)]);l.style.minWidth=Z+"px",l.style.left=xe+"px"}else{const I=O.right-q.right,P=window.innerWidth-U.right-I,X=window.innerWidth-_.right-P,Z=_.width+X,ge=Math.max(Z,O.width),ve=window.innerWidth-A,xe=Ne(P,[A,Math.max(A,ve-ge)]);l.style.minWidth=Z+"px",l.style.right=xe+"px"}const L=b(),B=window.innerHeight-A*2,W=p.scrollHeight,V=window.getComputedStyle(u),H=parseInt(V.borderTopWidth,10),E=parseInt(V.paddingTop,10),D=parseInt(V.borderBottomWidth,10),z=parseInt(V.paddingBottom,10),K=H+E+W+z+D,fe=Math.min(g.offsetHeight*5,K),ae=window.getComputedStyle(p),me=parseInt(ae.paddingTop,10),he=parseInt(ae.paddingBottom,10),te=_.top+_.height/2-A,ce=B-te,se=g.offsetHeight/2,f=g.offsetTop+se,T=H+E+f,R=K-T;if(T<=te){const I=L.length>0&&g===L[L.length-1].ref.current;l.style.bottom="0px";const P=u.clientHeight-p.offsetTop-p.offsetHeight,X=Math.max(ce,se+(I?he:0)+P+D),Z=T+X;l.style.height=Z+"px"}else{const I=L.length>0&&g===L[0].ref.current;l.style.top="0px";const X=Math.max(te,H+p.offsetTop+(I?me:0)+se)+R;l.style.height=X+"px",p.scrollTop=T-te+p.offsetTop}l.style.margin=`${A}px 0`,l.style.minHeight=fe+"px",l.style.maxHeight=B+"px",o?.(),requestAnimationFrame(()=>w.current=!0)}},[b,c.trigger,c.valueNode,l,u,p,g,C,c.dir,o]);$(()=>x(),[x]);const[F,M]=i.useState();$(()=>{u&&M(window.getComputedStyle(u).zIndex)},[u]);const re=i.useCallback(_=>{_&&S.current===!0&&(x(),m?.(),S.current=!1)},[x,m]);return d.jsx(Ot,{scope:t,contentWrapper:l,shouldExpandOnScrollRef:w,onScrollButtonChange:re,children:d.jsx("div",{ref:a,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:F},children:d.jsx(j.div,{...n,ref:v,style:{boxSizing:"border-box",maxHeight:"100%",...n.style}})})})});ze.displayName=Mt;var At="SelectPopperPosition",Se=i.forwardRef((r,e)=>{const{__scopeSelect:t,align:o="start",collisionPadding:n=A,...c}=r,s=pe(t);return d.jsx(vt,{...s,...c,ref:e,align:o,collisionPadding:n,style:{boxSizing:"border-box",...c.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});Se.displayName=At;var[Ot,Te]=ne(Q,{}),we="SelectViewport",Fe=i.forwardRef((r,e)=>{const{__scopeSelect:t,nonce:o,...n}=r,c=Y(we,t),s=Te(we,t),l=k(e,c.onViewportChange),a=i.useRef(0);return d.jsxs(d.Fragment,{children:[d.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:o}),d.jsx(de.Slot,{scope:t,children:d.jsx(j.div,{"data-radix-select-viewport":"",role:"presentation",...n,ref:l,style:{position:"relative",flex:1,overflow:"hidden auto",...n.style},onScroll:N(n.onScroll,u=>{const h=u.currentTarget,{contentWrapper:v,shouldExpandOnScrollRef:b}=s;if(b?.current&&v){const w=Math.abs(a.current-h.scrollTop);if(w>0){const S=window.innerHeight-A*2,p=parseFloat(v.style.minHeight),g=parseFloat(v.style.height),C=Math.max(p,g);if(C<S){const m=C+w,x=Math.min(S,m),F=m-x;v.style.height=x+"px",v.style.bottom==="0px"&&(h.scrollTop=F>0?F:0,v.style.justifyContent="flex-end")}}}a.current=h.scrollTop})})})]})});Fe.displayName=we;var Ue="SelectGroup",[Dt,kt]=ne(Ue),Lt=i.forwardRef((r,e)=>{const{__scopeSelect:t,...o}=r,n=be();return d.jsx(Dt,{scope:t,id:n,children:d.jsx(j.div,{role:"group","aria-labelledby":n,...o,ref:e})})});Lt.displayName=Ue;var We="SelectLabel",Bt=i.forwardRef((r,e)=>{const{__scopeSelect:t,...o}=r,n=kt(We,t);return d.jsx(j.div,{id:n.id,...o,ref:e})});Bt.displayName=We;var ie="SelectItem",[Vt,Ke]=ne(ie),$e=i.forwardRef((r,e)=>{const{__scopeSelect:t,value:o,disabled:n=!1,textValue:c,...s}=r,l=G(ie,t),a=Y(ie,t),u=l.value===o,[h,v]=i.useState(c??""),[b,w]=i.useState(!1),S=k(e,m=>a.itemRefCallback?.(m,o,n)),p=be(),g=i.useRef("touch"),C=()=>{n||(l.onValueChange(o),l.onOpenChange(!1))};if(o==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return d.jsx(Vt,{scope:t,value:o,disabled:n,textId:p,isSelected:u,onItemTextChange:i.useCallback(m=>{v(x=>x||(m?.textContent??"").trim())},[]),children:d.jsx(de.ItemSlot,{scope:t,value:o,disabled:n,textValue:h,children:d.jsx(j.div,{role:"option","aria-labelledby":p,"data-highlighted":b?"":void 0,"aria-selected":u&&b,"data-state":u?"checked":"unchecked","aria-disabled":n||void 0,"data-disabled":n?"":void 0,tabIndex:n?void 0:-1,...s,ref:S,onFocus:N(s.onFocus,()=>w(!0)),onBlur:N(s.onBlur,()=>w(!1)),onClick:N(s.onClick,()=>{g.current!=="mouse"&&C()}),onPointerUp:N(s.onPointerUp,()=>{g.current==="mouse"&&C()}),onPointerDown:N(s.onPointerDown,m=>{g.current=m.pointerType}),onPointerMove:N(s.onPointerMove,m=>{g.current=m.pointerType,n?a.onItemLeave?.():g.current==="mouse"&&m.currentTarget.focus({preventScroll:!0})}),onPointerLeave:N(s.onPointerLeave,m=>{m.currentTarget===document.activeElement&&a.onItemLeave?.()}),onKeyDown:N(s.onKeyDown,m=>{a.searchRef?.current!==""&&m.key===" "||(It.includes(m.key)&&C(),m.key===" "&&m.preventDefault())})})})})});$e.displayName=ie;var le="SelectItemText",Ge=i.forwardRef((r,e)=>{const{__scopeSelect:t,className:o,style:n,...c}=r,s=G(le,t),l=Y(le,t),a=Ke(le,t),u=Nt(le,t),[h,v]=i.useState(null),b=k(e,C=>v(C),a.onItemTextChange,C=>l.itemTextRefCallback?.(C,a.value,a.disabled)),w=h?.textContent,S=i.useMemo(()=>d.jsx("option",{value:a.value,disabled:a.disabled,children:w},a.value),[a.disabled,a.value,w]),{onNativeOptionAdd:p,onNativeOptionRemove:g}=u;return $(()=>(p(S),()=>g(S)),[p,g,S]),d.jsxs(d.Fragment,{children:[d.jsx(j.span,{id:a.textId,...c,ref:b}),a.isSelected&&s.valueNode&&!s.valueNodeHasChildren?_e.createPortal(c.children,s.valueNode):null]})});Ge.displayName=le;var Ye="SelectItemIndicator",qe=i.forwardRef((r,e)=>{const{__scopeSelect:t,...o}=r;return Ke(Ye,t).isSelected?d.jsx(j.span,{"aria-hidden":!0,...o,ref:e}):null});qe.displayName=Ye;var Ce="SelectScrollUpButton",Xe=i.forwardRef((r,e)=>{const t=Y(Ce,r.__scopeSelect),o=Te(Ce,r.__scopeSelect),[n,c]=i.useState(!1),s=k(e,o.onScrollButtonChange);return $(()=>{if(t.viewport&&t.isPositioned){let l=function(){const u=a.scrollTop>0;c(u)};const a=t.viewport;return l(),a.addEventListener("scroll",l),()=>a.removeEventListener("scroll",l)}},[t.viewport,t.isPositioned]),n?d.jsx(Je,{...r,ref:s,onAutoScroll:()=>{const{viewport:l,selectedItem:a}=t;l&&a&&(l.scrollTop=l.scrollTop-a.offsetHeight)}}):null});Xe.displayName=Ce;var ye="SelectScrollDownButton",Ze=i.forwardRef((r,e)=>{const t=Y(ye,r.__scopeSelect),o=Te(ye,r.__scopeSelect),[n,c]=i.useState(!1),s=k(e,o.onScrollButtonChange);return $(()=>{if(t.viewport&&t.isPositioned){let l=function(){const u=a.scrollHeight-a.clientHeight,h=Math.ceil(a.scrollTop)<u;c(h)};const a=t.viewport;return l(),a.addEventListener("scroll",l),()=>a.removeEventListener("scroll",l)}},[t.viewport,t.isPositioned]),n?d.jsx(Je,{...r,ref:s,onAutoScroll:()=>{const{viewport:l,selectedItem:a}=t;l&&a&&(l.scrollTop=l.scrollTop+a.offsetHeight)}}):null});Ze.displayName=ye;var Je=i.forwardRef((r,e)=>{const{__scopeSelect:t,onAutoScroll:o,...n}=r,c=Y("SelectScrollButton",t),s=i.useRef(null),l=ue(t),a=i.useCallback(()=>{s.current!==null&&(window.clearInterval(s.current),s.current=null)},[]);return i.useEffect(()=>()=>a(),[a]),$(()=>{l().find(h=>h.ref.current===document.activeElement)?.ref.current?.scrollIntoView({block:"nearest"})},[l]),d.jsx(j.div,{"aria-hidden":!0,...n,ref:e,style:{flexShrink:0,...n.style},onPointerDown:N(n.onPointerDown,()=>{s.current===null&&(s.current=window.setInterval(o,50))}),onPointerMove:N(n.onPointerMove,()=>{c.onItemLeave?.(),s.current===null&&(s.current=window.setInterval(o,50))}),onPointerLeave:N(n.onPointerLeave,()=>{a()})})}),Ht="SelectSeparator",zt=i.forwardRef((r,e)=>{const{__scopeSelect:t,...o}=r;return d.jsx(j.div,{"aria-hidden":!0,...o,ref:e})});zt.displayName=Ht;var Ie="SelectArrow",Ft=i.forwardRef((r,e)=>{const{__scopeSelect:t,...o}=r,n=pe(t),c=G(Ie,t),s=Y(Ie,t);return c.open&&s.position==="popper"?d.jsx(xt,{...n,...o,ref:e}):null});Ft.displayName=Ie;var Ut="SelectBubbleInput",Qe=i.forwardRef(({__scopeSelect:r,value:e,...t},o)=>{const n=i.useRef(null),c=k(o,n),s=ct(e);return i.useEffect(()=>{const l=n.current;if(!l)return;const a=window.HTMLSelectElement.prototype,h=Object.getOwnPropertyDescriptor(a,"value").set;if(s!==e&&h){const v=new Event("change",{bubbles:!0});h.call(l,e),l.dispatchEvent(v)}},[s,e]),d.jsx(j.select,{...t,style:{...St,...t.style},ref:c,defaultValue:e})});Qe.displayName=Ut;function et(r){return r===""||r===void 0}function tt(r){const e=it(r),t=i.useRef(""),o=i.useRef(0),n=i.useCallback(s=>{const l=t.current+s;e(l),(function a(u){t.current=u,window.clearTimeout(o.current),u!==""&&(o.current=window.setTimeout(()=>a(""),1e3))})(l)},[e]),c=i.useCallback(()=>{t.current="",window.clearTimeout(o.current)},[]);return i.useEffect(()=>()=>window.clearTimeout(o.current),[]),[t,n,c]}function ot(r,e,t){const n=e.length>1&&Array.from(e).every(u=>u===e[0])?e[0]:e,c=t?r.indexOf(t):-1;let s=Wt(r,Math.max(c,0));n.length===1&&(s=s.filter(u=>u!==t));const a=s.find(u=>u.textValue.toLowerCase().startsWith(n.toLowerCase()));return a!==t?a:void 0}function Wt(r,e){return r.map((t,o)=>r[(e+o)%r.length])}var Kt=je,$t=Ae,Gt=De,Yt=ke,qt=Le,Xt=Be,Zt=Fe,Jt=$e,Qt=Ge,eo=qe,to=Xe,oo=Ze;function uo(r){const e=ee.c(4);let t;e[0]!==r?({...t}=r,e[0]=r,e[1]=t):t=e[1];let o;return e[2]!==t?(o=d.jsx(Kt,{"data-slot":"select",...t}),e[2]=t,e[3]=o):o=e[3],o}function po(r){const e=ee.c(4);let t;e[0]!==r?({...t}=r,e[0]=r,e[1]=t):t=e[1];let o;return e[2]!==t?(o=d.jsx(Gt,{"data-slot":"select-value",...t}),e[2]=t,e[3]=o):o=e[3],o}function fo(r){const e=ee.c(13);let t,o,n,c;e[0]!==r?({className:o,size:c,children:t,...n}=r,e[0]=r,e[1]=t,e[2]=o,e[3]=n,e[4]=c):(t=e[1],o=e[2],n=e[3],c=e[4]);const s=c===void 0?"default":c;let l;e[5]!==o?(l=oe("data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/20 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 hover:bg-accent hover:text-accent-foreground dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-lg bg-background px-3 py-2 text-sm whitespace-nowrap transition-[color,box-shadow] outline-none focus-visible:ring-[2px] card-shadow disabled:opacity-50 data-[size=default]:h-8 data-[size=sm]:h-7 data-[size=xs]:h-6 data-[size=xs]:px-2.5 data-[size=xs]:py-1.5 data-[size=xs]:rounded-lg *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",o),e[5]=o,e[6]=l):l=e[6];let a;e[7]===Symbol.for("react.memo_cache_sentinel")?(a=d.jsx(Yt,{asChild:!0,children:d.jsx(Re,{className:"size-4 opacity-50"})}),e[7]=a):a=e[7];let u;return e[8]!==t||e[9]!==n||e[10]!==s||e[11]!==l?(u=d.jsxs($t,{"data-slot":"select-trigger","data-size":s,className:l,...n,children:[t,a]}),e[8]=t,e[9]=n,e[10]=s,e[11]=l,e[12]=u):u=e[12],u}function mo(r){const e=ee.c(25);let t,o,n,c,s;e[0]!==r?({className:o,children:t,position:c,hideScrollButtons:s,...n}=r,e[0]=r,e[1]=t,e[2]=o,e[3]=n,e[4]=c,e[5]=s):(t=e[1],o=e[2],n=e[3],c=e[4],s=e[5]);const l=c===void 0?"popper":c,a=s===void 0?!1:s,u=l==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1";let h;e[6]!==o||e[7]!==u?(h=oe("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg border shadow-md",u,o),e[6]=o,e[7]=u,e[8]=h):h=e[8];let v;e[9]!==a?(v=!a&&d.jsx(no,{}),e[9]=a,e[10]=v):v=e[10];const b=l==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)] scroll-my-1";let w;e[11]!==b?(w=oe("p-1",b),e[11]=b,e[12]=w):w=e[12];let S;e[13]!==t||e[14]!==w?(S=d.jsx(Zt,{className:w,children:t}),e[13]=t,e[14]=w,e[15]=S):S=e[15];let p;e[16]!==a?(p=!a&&d.jsx(ro,{}),e[16]=a,e[17]=p):p=e[17];let g;return e[18]!==l||e[19]!==n||e[20]!==h||e[21]!==v||e[22]!==S||e[23]!==p?(g=d.jsx(qt,{children:d.jsxs(Xt,{"data-slot":"select-content",className:h,position:l,...n,children:[v,S,p]})}),e[18]=l,e[19]=n,e[20]=h,e[21]=v,e[22]=S,e[23]=p,e[24]=g):g=e[24],g}function ho(r){const e=ee.c(16);let t,o,n,c;e[0]!==r?({className:o,children:t,hideCheck:c,...n}=r,e[0]=r,e[1]=t,e[2]=o,e[3]=n,e[4]=c):(t=e[1],o=e[2],n=e[3],c=e[4]);const s=c===void 0?!1:c;let l;e[5]!==o?(l=oe("focus:bg-accent focus:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex w-full cursor-default items-center gap-2 rounded-lg py-1.5 pr-8 pl-2 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2",o),e[5]=o,e[6]=l):l=e[6];let a;e[7]!==s?(a=!s&&d.jsx("span",{className:"absolute right-2 flex size-3.5 items-center justify-center",children:d.jsx(eo,{children:d.jsx(wt,{className:"size-4"})})}),e[7]=s,e[8]=a):a=e[8];let u;e[9]!==t?(u=d.jsx(Qt,{children:t}),e[9]=t,e[10]=u):u=e[10];let h;return e[11]!==n||e[12]!==l||e[13]!==a||e[14]!==u?(h=d.jsxs(Jt,{"data-slot":"select-item",className:l,...n,children:[a,u]}),e[11]=n,e[12]=l,e[13]=a,e[14]=u,e[15]=h):h=e[15],h}function no(r){const e=ee.c(9);let t,o;e[0]!==r?({className:t,...o}=r,e[0]=r,e[1]=t,e[2]=o):(t=e[1],o=e[2]);let n;e[3]!==t?(n=oe("flex cursor-default items-center justify-center py-1",t),e[3]=t,e[4]=n):n=e[4];let c;e[5]===Symbol.for("react.memo_cache_sentinel")?(c=d.jsx(Ct,{className:"size-4"}),e[5]=c):c=e[5];let s;return e[6]!==o||e[7]!==n?(s=d.jsx(to,{"data-slot":"select-scroll-up-button",className:n,...o,children:c}),e[6]=o,e[7]=n,e[8]=s):s=e[8],s}function ro(r){const e=ee.c(9);let t,o;e[0]!==r?({className:t,...o}=r,e[0]=r,e[1]=t,e[2]=o):(t=e[1],o=e[2]);let n;e[3]!==t?(n=oe("flex cursor-default items-center justify-center py-1",t),e[3]=t,e[4]=n):n=e[4];let c;e[5]===Symbol.for("react.memo_cache_sentinel")?(c=d.jsx(Re,{className:"size-4"}),e[5]=c):c=e[5];let s;return e[6]!==o||e[7]!==n?(s=d.jsx(oo,{"data-slot":"select-scroll-down-button",className:n,...o,children:c}),e[6]=o,e[7]=n,e[8]=s):s=e[8],s}export{uo as S,fo as a,po as b,mo as c,ho as d,Ne as e};
@@ -1 +1 @@
1
- import{e as y,g as P,j as s,L as w,q as E,aK as D,c as C,t as G,b as T,l as J,r as Q,O as U}from"./index-CM1D3IOd.js";import{u as W}from"./useRouterState-D1LxQ93_.js";import{S as V,a as X,b as Y,h as M,i as I,j as O,f as A,g as L,l as Z,m as ee}from"./sidebar-DapD5BLH.js";import{a as se}from"./index-Dr77wSbz.js";import{i as te}from"./ArrowNarrowLeft-DL6IklHf.js";import{b as le,c as oe,a as ie,d as re,e as ne,i as q}from"./ZapSquare-C-QuJXiX.js";import{t as ae,a as R}from"./Users03-BScPbfBT.js";import{i as ce}from"./HardDrive-Cj4eW7va.js";import{i as me}from"./Key01-BQUJeWtG.js";import{i as fe}from"./Lock01-CLcwdBbZ.js";import{i as de}from"./Shield01-DWmt0CsN.js";import{s as xe}from"./User01-DvR2FzxS.js";import{i as B}from"./Zap-DGOMtCmx.js";import{u as F}from"./tooltip-Cc8Oz_Tb.js";import{u as be}from"./use-status-sounds-DAM8WOkV.js";import{a as S}from"./toolbar-ZFFuL6YR.js";import{S as he,M as ue}from"./shell-controls-EFju5Xuz.js";import"./LayoutLeft-BtnBeX4Q.js";import"./X-BpMfki2j.js";import"./question-004-sINsf4GQ.js";import"./decopilot-sse-pool-B9BzYuaT.js";import"./create-sse-subscription-CjI9SUTI.js";import"./ChevronRight-DzTdh7eY.js";function H(){const e=y.c(31),t=E().project;let m;e[0]!==t.enabledPlugins?(m=t.enabledPlugins??[],e[0]=t.enabledPlugins,e[1]=m):m=e[1];const r=m;let l,n,i,o,a;if(e[2]!==r){const u=D.filter(K=>r.includes(K.pluginId)).map(pe);let h;e[8]===Symbol.for("react.memo_cache_sentinel")?(h={key:"general",label:"General",icon:s.jsx(ae,{size:14}),to:"/$org/settings/general"},e[8]=h):h=e[8];let f;e[9]===Symbol.for("react.memo_cache_sentinel")?(f={key:"brand-context",label:"Brand Context",icon:s.jsx(le,{size:14}),to:"/$org/settings/brand-context"},e[9]=f):f=e[9];let p;e[10]===Symbol.for("react.memo_cache_sentinel")?(p={key:"ai-providers",label:"AI Providers",icon:s.jsx(oe,{size:14}),to:"/$org/settings/ai-providers"},e[10]=p):p=e[10];let c;e[11]===Symbol.for("react.memo_cache_sentinel")?(c={key:"secrets",label:"Secrets",icon:s.jsx(me,{size:14}),to:"/$org/settings/secrets"},e[11]=c):c=e[11],e[12]===Symbol.for("react.memo_cache_sentinel")?(i={label:"Organization",items:[h,f,p,c,{key:"files",label:"Files",icon:s.jsx(ce,{size:14}),to:"/$org/settings/files"}]},e[12]=i):i=e[12];let _;e[13]===Symbol.for("react.memo_cache_sentinel")?(_={key:"connections",label:"Connections",icon:s.jsx(ie,{size:14}),to:"/$org/settings/connections"},e[13]=_):_=e[13];let j;e[14]===Symbol.for("react.memo_cache_sentinel")?(j={key:"agents",label:"Agents",icon:s.jsx(R,{size:14}),to:"/$org/settings/agents"},e[14]=j):j=e[14];let v;e[15]===Symbol.for("react.memo_cache_sentinel")?(v={key:"automations",label:"Automations",icon:s.jsx(B,{size:14}),to:"/$org/settings/automations"},e[15]=v):v=e[15],e[16]===Symbol.for("react.memo_cache_sentinel")?(o={label:"Build",items:[_,j,v,{key:"store",label:"Store",icon:s.jsx(re,{size:14}),to:"/$org/settings/store"}]},e[16]=o):o=e[16];let N;e[17]===Symbol.for("react.memo_cache_sentinel")?(N={key:"monitor",label:"Monitor",icon:s.jsx(ne,{size:14}),to:"/$org/settings/monitor"},e[17]=N):N=e[17];let $;e[18]===Symbol.for("react.memo_cache_sentinel")?($={key:"members",label:"Members",icon:s.jsx(R,{size:14}),to:"/$org/settings/members"},e[18]=$):$=e[18];let k;e[19]===Symbol.for("react.memo_cache_sentinel")?(k={key:"roles",label:"Roles",icon:s.jsx(de,{size:14}),to:"/$org/settings/roles"},e[19]=k):k=e[19],e[20]===Symbol.for("react.memo_cache_sentinel")?(a={label:"Manage",items:[N,$,k,{key:"sso",label:"Security",icon:s.jsx(fe,{size:14}),to:"/$org/settings/sso"}]},e[20]=a):a=e[20],l="Extensions";let z;e[21]===Symbol.for("react.memo_cache_sentinel")?(z={key:"features",label:"Plugins",icon:s.jsx(B,{size:14}),to:"/$org/settings/features"},e[21]=z):z=e[21],n=[z,...u],e[2]=r,e[3]=l,e[4]=n,e[5]=i,e[6]=o,e[7]=a}else l=e[3],n=e[4],i=e[5],o=e[6],a=e[7];let x;e[22]!==l||e[23]!==n?(x={label:l,items:n},e[22]=l,e[23]=n,e[24]=x):x=e[24];let d;e[25]===Symbol.for("react.memo_cache_sentinel")?(d={label:"Account",items:[{key:"profile",label:"Profile & Preferences",icon:s.jsx(xe,{size:14}),to:"/$org/settings/profile"}]},e[25]=d):d=e[25];let b;return e[26]!==i||e[27]!==o||e[28]!==a||e[29]!==x?(b=[i,o,a,x,d],e[26]=i,e[27]=o,e[28]=a,e[29]=x,e[30]=b):b=e[30],b}function pe(e){const{key:t,label:m,icon:r,to:l}=e;return{key:t,label:m,icon:r,to:l}}function ge(){const e=y.c(19),t=H();let m;e[0]===Symbol.for("react.memo_cache_sentinel")?(m={from:"/shell/$org"},e[0]=m):m=e[0];const{org:r}=P(m);let l;e[1]===Symbol.for("react.memo_cache_sentinel")?(l={select:_e},e[1]=l):l=e[1];const n=W(l);let i;e[2]!==r||e[3]!==n?(i=h=>{const f=h.replace("$org",r);return n.startsWith(f)},e[2]=r,e[3]=n,e[4]=i):i=e[4];const o=i;let a;if(e[5]!==t||e[6]!==o||e[7]!==r){let h;e[9]!==o||e[10]!==r?(h=(f,p)=>s.jsxs(M,{className:"pt-0 pr-0 pb-0 pl-0",children:[f.label&&s.jsx("p",{className:C("px-2 pt-1.5 pb-0.5 text-xs font-medium text-muted-foreground/60",p>0&&"mt-3"),children:f.label}),s.jsx(I,{children:s.jsx(O,{className:"gap-0.5",children:f.items.map(c=>s.jsx(A,{children:s.jsx(L,{asChild:!0,isActive:o(c.to),children:s.jsxs(w,{to:c.to,params:{org:r},onClick:()=>G("settings_nav_clicked",{section_key:c.key,section_label:c.label,group_label:f.label||"main"}),className:"flex items-center gap-2.5 text-sm",children:[s.jsx("span",{className:"shrink-0",children:c.icon}),s.jsx("span",{className:"truncate",children:c.label})]})})},c.key))})})]},`${f.label}-${p}`),e[9]=o,e[10]=r,e[11]=h):h=e[11],a=t.map(h),e[5]=t,e[6]=o,e[7]=r,e[8]=a}else a=e[8];let x;e[12]===Symbol.for("react.memo_cache_sentinel")?(x=s.jsx("div",{className:"mx-2 my-2 border-t border-border/50"}),e[12]=x):x=e[12];let d;e[13]===Symbol.for("react.memo_cache_sentinel")?(d=s.jsxs(M,{className:"pt-0 pr-0 pb-0 pl-0",children:[x,s.jsx(I,{children:s.jsx(O,{className:"gap-0.5",children:s.jsx(A,{children:s.jsxs(L,{onClick:je,className:"flex items-center gap-2.5 text-sm",children:[s.jsx("span",{className:"shrink-0",children:s.jsx(q,{size:14})}),s.jsx("span",{className:"truncate",children:"Sign Out"})]})})})})]}),e[13]=d):d=e[13];let b;e[14]!==a?(b=s.jsxs(Z,{className:"flex flex-col flex-1 mt-2 px-2 pb-2 gap-0 overflow-y-auto",children:[a,d]}),e[14]=a,e[15]=b):b=e[15];let g;e[16]===Symbol.for("react.memo_cache_sentinel")?(g=s.jsx("div",{className:"mt-auto px-4 pb-1",children:s.jsxs("span",{className:"text-xs text-muted-foreground/50",children:["v","2.367.13"]})}),e[16]=g):g=e[16];let u;return e[17]!==b?(u=s.jsxs(ee,{variant:"sidebar",children:[b,g]}),e[17]=b,e[18]=u):u=e[18],u}function je(){G("signed_out",{source:"settings_sidebar"}),T.signOut()}function _e(e){return e.location.pathname}function Se(e){const t=y.c(21),{onClose:m}=e,r=H();let l;t[0]===Symbol.for("react.memo_cache_sentinel")?(l={from:"/shell/$org"},t[0]=l):l=t[0];const{org:n}=P(l);let i;t[1]===Symbol.for("react.memo_cache_sentinel")?(i={select:ve},t[1]=i):i=t[1];const o=W(i);let a;t[2]!==n||t[3]!==o?(a=p=>{const c=p.replace("$org",n);return o.startsWith(c)},t[2]=n,t[3]=o,t[4]=a):a=t[4];const x=a;let d;if(t[5]!==r||t[6]!==x||t[7]!==m||t[8]!==n){let p;t[10]!==x||t[11]!==m||t[12]!==n?(p=(c,_)=>s.jsxs("div",{className:"flex flex-col gap-0.5",children:[c.label&&s.jsx("p",{className:C("px-3 pt-1.5 pb-0.5 text-xs font-medium text-muted-foreground/60",_>0&&"mt-3"),children:c.label}),c.items.map(j=>s.jsxs(w,{to:j.to,params:{org:n},onClick:m,className:C("flex items-center gap-3 w-full px-3 py-2.5 rounded-lg transition-colors text-sm",x(j.to)?"bg-sidebar-accent text-sidebar-accent-foreground font-medium":"text-sidebar-foreground/70 hover:bg-sidebar-accent hover:text-sidebar-foreground"),children:[s.jsx("span",{className:"shrink-0",children:j.icon}),s.jsx("span",{className:"truncate",children:j.label})]},j.key))]},`${c.label}-${_}`),t[10]=x,t[11]=m,t[12]=n,t[13]=p):p=t[13],d=r.map(p),t[5]=r,t[6]=x,t[7]=m,t[8]=n,t[9]=d}else d=t[9];let b;t[14]===Symbol.for("react.memo_cache_sentinel")?(b=s.jsx("div",{className:"h-px bg-border/50 my-2"}),t[14]=b):b=t[14];let g;t[15]===Symbol.for("react.memo_cache_sentinel")?(g=s.jsxs("div",{className:"flex flex-col gap-0.5",children:[b,s.jsxs("button",{type:"button",onClick:ye,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:[s.jsx("span",{className:"shrink-0",children:s.jsx(q,{size:14})}),s.jsx("span",{className:"truncate",children:"Sign Out"})]})]}),t[15]=g):g=t[15];let u;t[16]!==d?(u=s.jsxs("div",{className:"flex flex-col flex-1 overflow-y-auto px-2 py-2 gap-0.5",children:[d,g]}),t[16]=d,t[17]=u):u=t[17];let h;t[18]===Symbol.for("react.memo_cache_sentinel")?(h=s.jsx("div",{className:"px-4 pb-3 pt-1 border-t border-border/50",children:s.jsxs("span",{className:"text-xs text-muted-foreground/50",children:["v","2.367.13"]})}),t[18]=h):h=t[18];let f;return t[19]!==u?(f=s.jsxs("div",{className:"flex flex-col h-full bg-sidebar",children:[u,h]}),t[19]=u,t[20]=f):f=t[20],f}function ye(){return T.signOut()}function ve(e){return e.location.pathname}function Ne(){const e=y.c(4),t=F(),{org:m}=E();be(m.slug);let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r=s.jsx("div",{className:"flex-1 flex items-center justify-center",children:s.jsx(J,{size:20,className:"animate-spin text-muted-foreground"})}),e[0]=r):r=e[0];let l;e[1]===Symbol.for("react.memo_cache_sentinel")?(l=s.jsx(Q.Suspense,{fallback:r,children:s.jsx("div",{className:"flex flex-1 items-center overflow-hidden rounded-[inherit]",children:s.jsx(se,{value:"p-0",children:s.jsx("div",{className:"flex-1 min-w-0 overflow-hidden h-full",children:s.jsx(U,{})})})})}),e[1]=l):l=e[1];const n=l;if(t){let o;return e[2]===Symbol.for("react.memo_cache_sentinel")?(o=s.jsx("div",{className:"flex flex-col flex-1 bg-background min-h-0 overflow-hidden",children:n}),e[2]=o):o=e[2],o}let i;return e[3]===Symbol.for("react.memo_cache_sentinel")?(i=s.jsx("div",{className:"flex-1 min-h-0 p-1",children:s.jsx("div",{className:C("flex flex-col h-full min-h-0 bg-background overflow-hidden","card-shadow","rounded-[0.75rem]"),children:n})}),e[3]=i):i=e[3],i}function Ue(){const e=y.c(29),t=F();let m;e[0]===Symbol.for("react.memo_cache_sentinel")?(m={from:"/shell/$org"},e[0]=m):m=e[0];const{org:r}=P(m);let l;e[1]!==r?(l={org:r},e[1]=r,e[2]=l):l=e[2];let n,i;e[3]===Symbol.for("react.memo_cache_sentinel")?(n=s.jsx(te,{size:14,className:"shrink-0"}),i=s.jsx("span",{children:"Settings"}),e[3]=n,e[4]=i):(n=e[3],i=e[4]);let o;e[5]!==l?(o=s.jsxs(w,{to:"/$org",params:l,className:"wco-no-drag flex items-center gap-1.5 px-2 h-7 rounded-md text-sm text-muted-foreground hover:text-foreground hover:bg-accent transition-colors",children:[n,i]}),e[5]=l,e[6]=o):o=e[6];let a;e[7]!==t?(a=t&&s.jsx(he,{}),e[7]=t,e[8]=a):a=e[8];let x;e[9]===Symbol.for("react.memo_cache_sentinel")?(x=s.jsx("span",{className:"hidden md:contents",children:s.jsx(S.Nav,{})}),e[9]=x):x=e[9];let d;e[10]!==o||e[11]!==a?(d=s.jsxs(S.LeftColumn,{children:[o,a,x]}),e[10]=o,e[11]=a,e[12]=d):d=e[12];let b;e[13]===Symbol.for("react.memo_cache_sentinel")?(b=s.jsx(S.CenterSlot,{}),e[13]=b):b=e[13];let g;e[14]===Symbol.for("react.memo_cache_sentinel")?(g=s.jsx(S.RightColumn,{children:s.jsx("span",{})}),e[14]=g):g=e[14];let u;e[15]!==d?(u=s.jsxs(S.Header,{children:[d,b,g]}),e[15]=d,e[16]=u):u=e[16];let h;e[17]===Symbol.for("react.memo_cache_sentinel")?(h={"--sidebar-width-icon":"3.5rem"},e[17]=h):h=e[17];let f;e[18]!==t?(f=!t&&s.jsx(ge,{}),e[18]=t,e[19]=f):f=e[19];let p;e[20]===Symbol.for("react.memo_cache_sentinel")?(p=s.jsx(V,{className:"flex flex-col",style:{background:"transparent",containerType:"inline-size"},children:s.jsx(Ne,{})}),e[20]=p):p=e[20];let c;e[21]!==f?(c=s.jsxs(X,{className:"flex-1 bg-sidebar min-h-0",style:h,children:[f,p]}),e[21]=f,e[22]=c):c=e[22];let _;e[23]!==t?(_=t&&s.jsx(ue,{renderSidebar:$e}),e[23]=t,e[24]=_):_=e[24];let j;return e[25]!==u||e[26]!==c||e[27]!==_?(j=s.jsx(S.Provider,{children:s.jsx(Y,{defaultOpen:!0,children:s.jsxs("div",{className:"app-shell-root flex flex-col h-dvh overflow-hidden",children:[u,c,_]})})}),e[25]=u,e[26]=c,e[27]=_,e[28]=j):j=e[28],j}function $e(e){const{onClose:t}=e;return s.jsx(Se,{onClose:t})}export{ge as SettingsSidebar,Se as SettingsSidebarMobile,Ue as default};
1
+ import{e as y,g as P,j as s,L as w,q as E,aK as D,c as C,t as G,b as T,l as J,r as Q,O as U}from"./index-C_etCvW6.js";import{u as W}from"./useRouterState-CFvTFlCq.js";import{S as V,a as X,b as Y,h as M,i as I,j as O,f as A,g as L,l as Z,m as ee}from"./sidebar-BMGvDz3J.js";import{a as se}from"./index-C7pSmjIO.js";import{i as te}from"./ArrowNarrowLeft-hiT9EAxM.js";import{b as le,c as oe,a as ie,d as re,e as ne,i as q}from"./ZapSquare-BQ8gms0B.js";import{t as ae,a as R}from"./Users03-DGJmr08f.js";import{i as ce}from"./HardDrive-C5cYoT_u.js";import{i as me}from"./Key01-D616GLzE.js";import{i as fe}from"./Lock01-BCib8CWc.js";import{i as de}from"./Shield01-CZAvPXer.js";import{s as xe}from"./User01-CtOhLzXW.js";import{i as B}from"./Zap-B74dlfsg.js";import{u as F}from"./tooltip-8OqGw7oG.js";import{u as be}from"./use-status-sounds-BAU2JGUe.js";import{a as S}from"./toolbar-C9yYx7bm.js";import{S as he,M as ue}from"./shell-controls-Bh_0J4mE.js";import"./LayoutLeft-_rPJ3Xdj.js";import"./X-Coa3_vHC.js";import"./question-004-sINsf4GQ.js";import"./decopilot-sse-pool-atg0HfN2.js";import"./create-sse-subscription-CjI9SUTI.js";import"./ChevronRight-C956u55G.js";function H(){const e=y.c(31),t=E().project;let m;e[0]!==t.enabledPlugins?(m=t.enabledPlugins??[],e[0]=t.enabledPlugins,e[1]=m):m=e[1];const r=m;let l,n,i,o,a;if(e[2]!==r){const u=D.filter(K=>r.includes(K.pluginId)).map(pe);let h;e[8]===Symbol.for("react.memo_cache_sentinel")?(h={key:"general",label:"General",icon:s.jsx(ae,{size:14}),to:"/$org/settings/general"},e[8]=h):h=e[8];let f;e[9]===Symbol.for("react.memo_cache_sentinel")?(f={key:"brand-context",label:"Brand Context",icon:s.jsx(le,{size:14}),to:"/$org/settings/brand-context"},e[9]=f):f=e[9];let p;e[10]===Symbol.for("react.memo_cache_sentinel")?(p={key:"ai-providers",label:"AI Providers",icon:s.jsx(oe,{size:14}),to:"/$org/settings/ai-providers"},e[10]=p):p=e[10];let c;e[11]===Symbol.for("react.memo_cache_sentinel")?(c={key:"secrets",label:"Secrets",icon:s.jsx(me,{size:14}),to:"/$org/settings/secrets"},e[11]=c):c=e[11],e[12]===Symbol.for("react.memo_cache_sentinel")?(i={label:"Organization",items:[h,f,p,c,{key:"files",label:"Files",icon:s.jsx(ce,{size:14}),to:"/$org/settings/files"}]},e[12]=i):i=e[12];let _;e[13]===Symbol.for("react.memo_cache_sentinel")?(_={key:"connections",label:"Connections",icon:s.jsx(ie,{size:14}),to:"/$org/settings/connections"},e[13]=_):_=e[13];let j;e[14]===Symbol.for("react.memo_cache_sentinel")?(j={key:"agents",label:"Agents",icon:s.jsx(R,{size:14}),to:"/$org/settings/agents"},e[14]=j):j=e[14];let v;e[15]===Symbol.for("react.memo_cache_sentinel")?(v={key:"automations",label:"Automations",icon:s.jsx(B,{size:14}),to:"/$org/settings/automations"},e[15]=v):v=e[15],e[16]===Symbol.for("react.memo_cache_sentinel")?(o={label:"Build",items:[_,j,v,{key:"store",label:"Store",icon:s.jsx(re,{size:14}),to:"/$org/settings/store"}]},e[16]=o):o=e[16];let N;e[17]===Symbol.for("react.memo_cache_sentinel")?(N={key:"monitor",label:"Monitor",icon:s.jsx(ne,{size:14}),to:"/$org/settings/monitor"},e[17]=N):N=e[17];let $;e[18]===Symbol.for("react.memo_cache_sentinel")?($={key:"members",label:"Members",icon:s.jsx(R,{size:14}),to:"/$org/settings/members"},e[18]=$):$=e[18];let k;e[19]===Symbol.for("react.memo_cache_sentinel")?(k={key:"roles",label:"Roles",icon:s.jsx(de,{size:14}),to:"/$org/settings/roles"},e[19]=k):k=e[19],e[20]===Symbol.for("react.memo_cache_sentinel")?(a={label:"Manage",items:[N,$,k,{key:"sso",label:"Security",icon:s.jsx(fe,{size:14}),to:"/$org/settings/sso"}]},e[20]=a):a=e[20],l="Extensions";let z;e[21]===Symbol.for("react.memo_cache_sentinel")?(z={key:"features",label:"Plugins",icon:s.jsx(B,{size:14}),to:"/$org/settings/features"},e[21]=z):z=e[21],n=[z,...u],e[2]=r,e[3]=l,e[4]=n,e[5]=i,e[6]=o,e[7]=a}else l=e[3],n=e[4],i=e[5],o=e[6],a=e[7];let x;e[22]!==l||e[23]!==n?(x={label:l,items:n},e[22]=l,e[23]=n,e[24]=x):x=e[24];let d;e[25]===Symbol.for("react.memo_cache_sentinel")?(d={label:"Account",items:[{key:"profile",label:"Profile & Preferences",icon:s.jsx(xe,{size:14}),to:"/$org/settings/profile"}]},e[25]=d):d=e[25];let b;return e[26]!==i||e[27]!==o||e[28]!==a||e[29]!==x?(b=[i,o,a,x,d],e[26]=i,e[27]=o,e[28]=a,e[29]=x,e[30]=b):b=e[30],b}function pe(e){const{key:t,label:m,icon:r,to:l}=e;return{key:t,label:m,icon:r,to:l}}function ge(){const e=y.c(19),t=H();let m;e[0]===Symbol.for("react.memo_cache_sentinel")?(m={from:"/shell/$org"},e[0]=m):m=e[0];const{org:r}=P(m);let l;e[1]===Symbol.for("react.memo_cache_sentinel")?(l={select:_e},e[1]=l):l=e[1];const n=W(l);let i;e[2]!==r||e[3]!==n?(i=h=>{const f=h.replace("$org",r);return n.startsWith(f)},e[2]=r,e[3]=n,e[4]=i):i=e[4];const o=i;let a;if(e[5]!==t||e[6]!==o||e[7]!==r){let h;e[9]!==o||e[10]!==r?(h=(f,p)=>s.jsxs(M,{className:"pt-0 pr-0 pb-0 pl-0",children:[f.label&&s.jsx("p",{className:C("px-2 pt-1.5 pb-0.5 text-xs font-medium text-muted-foreground/60",p>0&&"mt-3"),children:f.label}),s.jsx(I,{children:s.jsx(O,{className:"gap-0.5",children:f.items.map(c=>s.jsx(A,{children:s.jsx(L,{asChild:!0,isActive:o(c.to),children:s.jsxs(w,{to:c.to,params:{org:r},onClick:()=>G("settings_nav_clicked",{section_key:c.key,section_label:c.label,group_label:f.label||"main"}),className:"flex items-center gap-2.5 text-sm",children:[s.jsx("span",{className:"shrink-0",children:c.icon}),s.jsx("span",{className:"truncate",children:c.label})]})})},c.key))})})]},`${f.label}-${p}`),e[9]=o,e[10]=r,e[11]=h):h=e[11],a=t.map(h),e[5]=t,e[6]=o,e[7]=r,e[8]=a}else a=e[8];let x;e[12]===Symbol.for("react.memo_cache_sentinel")?(x=s.jsx("div",{className:"mx-2 my-2 border-t border-border/50"}),e[12]=x):x=e[12];let d;e[13]===Symbol.for("react.memo_cache_sentinel")?(d=s.jsxs(M,{className:"pt-0 pr-0 pb-0 pl-0",children:[x,s.jsx(I,{children:s.jsx(O,{className:"gap-0.5",children:s.jsx(A,{children:s.jsxs(L,{onClick:je,className:"flex items-center gap-2.5 text-sm",children:[s.jsx("span",{className:"shrink-0",children:s.jsx(q,{size:14})}),s.jsx("span",{className:"truncate",children:"Sign Out"})]})})})})]}),e[13]=d):d=e[13];let b;e[14]!==a?(b=s.jsxs(Z,{className:"flex flex-col flex-1 mt-2 px-2 pb-2 gap-0 overflow-y-auto",children:[a,d]}),e[14]=a,e[15]=b):b=e[15];let g;e[16]===Symbol.for("react.memo_cache_sentinel")?(g=s.jsx("div",{className:"mt-auto px-4 pb-1",children:s.jsxs("span",{className:"text-xs text-muted-foreground/50",children:["v","2.367.25"]})}),e[16]=g):g=e[16];let u;return e[17]!==b?(u=s.jsxs(ee,{variant:"sidebar",children:[b,g]}),e[17]=b,e[18]=u):u=e[18],u}function je(){G("signed_out",{source:"settings_sidebar"}),T.signOut()}function _e(e){return e.location.pathname}function Se(e){const t=y.c(21),{onClose:m}=e,r=H();let l;t[0]===Symbol.for("react.memo_cache_sentinel")?(l={from:"/shell/$org"},t[0]=l):l=t[0];const{org:n}=P(l);let i;t[1]===Symbol.for("react.memo_cache_sentinel")?(i={select:ve},t[1]=i):i=t[1];const o=W(i);let a;t[2]!==n||t[3]!==o?(a=p=>{const c=p.replace("$org",n);return o.startsWith(c)},t[2]=n,t[3]=o,t[4]=a):a=t[4];const x=a;let d;if(t[5]!==r||t[6]!==x||t[7]!==m||t[8]!==n){let p;t[10]!==x||t[11]!==m||t[12]!==n?(p=(c,_)=>s.jsxs("div",{className:"flex flex-col gap-0.5",children:[c.label&&s.jsx("p",{className:C("px-3 pt-1.5 pb-0.5 text-xs font-medium text-muted-foreground/60",_>0&&"mt-3"),children:c.label}),c.items.map(j=>s.jsxs(w,{to:j.to,params:{org:n},onClick:m,className:C("flex items-center gap-3 w-full px-3 py-2.5 rounded-lg transition-colors text-sm",x(j.to)?"bg-sidebar-accent text-sidebar-accent-foreground font-medium":"text-sidebar-foreground/70 hover:bg-sidebar-accent hover:text-sidebar-foreground"),children:[s.jsx("span",{className:"shrink-0",children:j.icon}),s.jsx("span",{className:"truncate",children:j.label})]},j.key))]},`${c.label}-${_}`),t[10]=x,t[11]=m,t[12]=n,t[13]=p):p=t[13],d=r.map(p),t[5]=r,t[6]=x,t[7]=m,t[8]=n,t[9]=d}else d=t[9];let b;t[14]===Symbol.for("react.memo_cache_sentinel")?(b=s.jsx("div",{className:"h-px bg-border/50 my-2"}),t[14]=b):b=t[14];let g;t[15]===Symbol.for("react.memo_cache_sentinel")?(g=s.jsxs("div",{className:"flex flex-col gap-0.5",children:[b,s.jsxs("button",{type:"button",onClick:ye,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:[s.jsx("span",{className:"shrink-0",children:s.jsx(q,{size:14})}),s.jsx("span",{className:"truncate",children:"Sign Out"})]})]}),t[15]=g):g=t[15];let u;t[16]!==d?(u=s.jsxs("div",{className:"flex flex-col flex-1 overflow-y-auto px-2 py-2 gap-0.5",children:[d,g]}),t[16]=d,t[17]=u):u=t[17];let h;t[18]===Symbol.for("react.memo_cache_sentinel")?(h=s.jsx("div",{className:"px-4 pb-3 pt-1 border-t border-border/50",children:s.jsxs("span",{className:"text-xs text-muted-foreground/50",children:["v","2.367.25"]})}),t[18]=h):h=t[18];let f;return t[19]!==u?(f=s.jsxs("div",{className:"flex flex-col h-full bg-sidebar",children:[u,h]}),t[19]=u,t[20]=f):f=t[20],f}function ye(){return T.signOut()}function ve(e){return e.location.pathname}function Ne(){const e=y.c(4),t=F(),{org:m}=E();be(m.slug);let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r=s.jsx("div",{className:"flex-1 flex items-center justify-center",children:s.jsx(J,{size:20,className:"animate-spin text-muted-foreground"})}),e[0]=r):r=e[0];let l;e[1]===Symbol.for("react.memo_cache_sentinel")?(l=s.jsx(Q.Suspense,{fallback:r,children:s.jsx("div",{className:"flex flex-1 items-center overflow-hidden rounded-[inherit]",children:s.jsx(se,{value:"p-0",children:s.jsx("div",{className:"flex-1 min-w-0 overflow-hidden h-full",children:s.jsx(U,{})})})})}),e[1]=l):l=e[1];const n=l;if(t){let o;return e[2]===Symbol.for("react.memo_cache_sentinel")?(o=s.jsx("div",{className:"flex flex-col flex-1 bg-background min-h-0 overflow-hidden",children:n}),e[2]=o):o=e[2],o}let i;return e[3]===Symbol.for("react.memo_cache_sentinel")?(i=s.jsx("div",{className:"flex-1 min-h-0 p-1",children:s.jsx("div",{className:C("flex flex-col h-full min-h-0 bg-background overflow-hidden","card-shadow","rounded-[0.75rem]"),children:n})}),e[3]=i):i=e[3],i}function Ue(){const e=y.c(29),t=F();let m;e[0]===Symbol.for("react.memo_cache_sentinel")?(m={from:"/shell/$org"},e[0]=m):m=e[0];const{org:r}=P(m);let l;e[1]!==r?(l={org:r},e[1]=r,e[2]=l):l=e[2];let n,i;e[3]===Symbol.for("react.memo_cache_sentinel")?(n=s.jsx(te,{size:14,className:"shrink-0"}),i=s.jsx("span",{children:"Settings"}),e[3]=n,e[4]=i):(n=e[3],i=e[4]);let o;e[5]!==l?(o=s.jsxs(w,{to:"/$org",params:l,className:"wco-no-drag flex items-center gap-1.5 px-2 h-7 rounded-md text-sm text-muted-foreground hover:text-foreground hover:bg-accent transition-colors",children:[n,i]}),e[5]=l,e[6]=o):o=e[6];let a;e[7]!==t?(a=t&&s.jsx(he,{}),e[7]=t,e[8]=a):a=e[8];let x;e[9]===Symbol.for("react.memo_cache_sentinel")?(x=s.jsx("span",{className:"hidden md:contents",children:s.jsx(S.Nav,{})}),e[9]=x):x=e[9];let d;e[10]!==o||e[11]!==a?(d=s.jsxs(S.LeftColumn,{children:[o,a,x]}),e[10]=o,e[11]=a,e[12]=d):d=e[12];let b;e[13]===Symbol.for("react.memo_cache_sentinel")?(b=s.jsx(S.CenterSlot,{}),e[13]=b):b=e[13];let g;e[14]===Symbol.for("react.memo_cache_sentinel")?(g=s.jsx(S.RightColumn,{children:s.jsx("span",{})}),e[14]=g):g=e[14];let u;e[15]!==d?(u=s.jsxs(S.Header,{children:[d,b,g]}),e[15]=d,e[16]=u):u=e[16];let h;e[17]===Symbol.for("react.memo_cache_sentinel")?(h={"--sidebar-width-icon":"3.5rem"},e[17]=h):h=e[17];let f;e[18]!==t?(f=!t&&s.jsx(ge,{}),e[18]=t,e[19]=f):f=e[19];let p;e[20]===Symbol.for("react.memo_cache_sentinel")?(p=s.jsx(V,{className:"flex flex-col",style:{background:"transparent",containerType:"inline-size"},children:s.jsx(Ne,{})}),e[20]=p):p=e[20];let c;e[21]!==f?(c=s.jsxs(X,{className:"flex-1 bg-sidebar min-h-0",style:h,children:[f,p]}),e[21]=f,e[22]=c):c=e[22];let _;e[23]!==t?(_=t&&s.jsx(ue,{renderSidebar:$e}),e[23]=t,e[24]=_):_=e[24];let j;return e[25]!==u||e[26]!==c||e[27]!==_?(j=s.jsx(S.Provider,{children:s.jsx(Y,{defaultOpen:!0,children:s.jsxs("div",{className:"app-shell-root flex flex-col h-dvh overflow-hidden",children:[u,c,_]})})}),e[25]=u,e[26]=c,e[27]=_,e[28]=j):j=e[28],j}function $e(e){const{onClose:t}=e;return s.jsx(Se,{onClose:t})}export{ge as SettingsSidebar,Se as SettingsSidebarMobile,Ue as default};
@@ -1 +1 @@
1
- import{e as v,c as N,j as r,r as S}from"./index-CM1D3IOd.js";import{C as w}from"./card-CzmU6DPx.js";import{i as E}from"./ArrowUpRight-CuD8Ec0Q.js";function I(c){const e=v.c(12),{title:i,description:l,docsHref:t,actions:s,className:n,headerClassName:a,children:d}=c;let m;e[0]!==n?(m=N("flex flex-col gap-3",n),e[0]=n,e[1]=m):m=e[1];let f;e[2]!==s||e[3]!==l||e[4]!==t||e[5]!==a||e[6]!==i?(f=(i||l||t||s)&&r.jsxs("div",{className:N("flex items-center justify-between gap-3 px-4",a),children:[r.jsxs("div",{className:"flex flex-col gap-1 min-w-0",children:[i&&r.jsx("h2",{className:"text-[15px] font-medium leading-tight",children:i}),(l||t)&&r.jsxs("p",{className:"text-sm text-muted-foreground leading-snug",children:[l,t&&r.jsxs("a",{href:t,target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-0.5 ml-1 text-foreground hover:underline",children:["Docs ",r.jsx(E,{size:12})]})]})]}),s&&r.jsx("div",{className:"shrink-0",children:s})]}),e[2]=s,e[3]=l,e[4]=t,e[5]=a,e[6]=i,e[7]=f):f=e[7];let o;return e[8]!==d||e[9]!==m||e[10]!==f?(o=r.jsxs("section",{className:m,children:[f,d]}),e[8]=d,e[9]=m,e[10]=f,e[11]=o):o=e[11],o}function P(c){const e=v.c(11),{className:i,children:l}=c;let t,s,n;if(e[0]!==l||e[1]!==i){const d=S.Children.toArray(l).filter(S.isValidElement);t=w,e[5]!==i?(s=N("p-0 gap-0 overflow-hidden",i),e[5]=i,e[6]=s):s=e[6],n=d.map($),e[0]=l,e[1]=i,e[2]=t,e[3]=s,e[4]=n}else t=e[2],s=e[3],n=e[4];let a;return e[7]!==t||e[8]!==s||e[9]!==n?(a=r.jsx(t,{className:s,children:n}),e[7]=t,e[8]=s,e[9]=n,e[10]=a):a=e[10],a}function $(c,e){return r.jsxs("div",{children:[e>0&&r.jsx("div",{className:"h-px bg-border mx-5"}),c]},e)}function R(c){const e=v.c(27),{icon:i,title:l,description:t,action:s,onClick:n,className:a,children:d}=c,m=d?"flex items-start gap-3 px-4 py-4":"flex items-center gap-3 px-4 py-4",f=n&&"hover:bg-muted/50 cursor-pointer";let o;e[0]!==a||e[1]!==m||e[2]!==f?(o=N(m,f,a),e[0]=a,e[1]=m,e[2]=f,e[3]=o):o=e[3];const b=n?"button":void 0,C=n?0:void 0;let x;e[4]!==n?(x=n?k=>{(k.key==="Enter"||k.key===" ")&&(k.preventDefault(),n())}:void 0,e[4]=n,e[5]=x):x=e[5];let p;e[6]!==i?(p=i&&r.jsx("div",{className:"size-8 shrink-0 rounded-lg bg-muted/60 flex items-center justify-center text-muted-foreground",children:i}),e[6]=i,e[7]=p):p=e[7];let u;e[8]!==l?(u=r.jsx("div",{className:"text-sm font-medium",children:l}),e[8]=l,e[9]=u):u=e[9];let h;e[10]!==t?(h=t&&r.jsx("p",{className:"text-xs text-muted-foreground mt-0.5 leading-relaxed",children:t}),e[10]=t,e[11]=h):h=e[11];let g;e[12]!==d||e[13]!==u||e[14]!==h?(g=r.jsxs("div",{className:"flex-1 min-w-0",children:[u,h,d]}),e[12]=d,e[13]=u,e[14]=h,e[15]=g):g=e[15];let j;e[16]!==s?(j=s&&r.jsx("div",{className:"shrink-0",onClick:D,children:s}),e[16]=s,e[17]=j):j=e[17];let y;return e[18]!==n||e[19]!==g||e[20]!==j||e[21]!==o||e[22]!==b||e[23]!==C||e[24]!==x||e[25]!==p?(y=r.jsxs("div",{className:o,onClick:n,role:b,tabIndex:C,onKeyDown:x,children:[p,g,j]}),e[18]=n,e[19]=g,e[20]=j,e[21]=o,e[22]=b,e[23]=C,e[24]=x,e[25]=p,e[26]=y):y=e[26],y}function D(c){return c.stopPropagation()}function H(c){const e=v.c(5),{children:i,className:l}=c;let t;e[0]!==l?(t=N("flex items-center justify-end gap-2 px-4 py-4",l),e[0]=l,e[1]=t):t=e[1];let s;return e[2]!==i||e[3]!==t?(s=r.jsx("div",{className:t,children:i}),e[2]=i,e[3]=t,e[4]=s):s=e[4],s}function K(c){const e=v.c(5),{className:i,children:l}=c;let t;e[0]!==i?(t=N("flex flex-col gap-10",i),e[0]=i,e[1]=t):t=e[1];let s;return e[2]!==l||e[3]!==t?(s=r.jsx("div",{className:t,children:l}),e[2]=l,e[3]=t,e[4]=s):s=e[4],s}export{I as S,P as a,R as b,H as c,K as d};
1
+ import{e as v,c as N,j as r,r as S}from"./index-C_etCvW6.js";import{C as w}from"./card-Cd_hFdRe.js";import{i as E}from"./ArrowUpRight-BngWaIVR.js";function I(c){const e=v.c(12),{title:i,description:l,docsHref:t,actions:s,className:n,headerClassName:a,children:d}=c;let m;e[0]!==n?(m=N("flex flex-col gap-3",n),e[0]=n,e[1]=m):m=e[1];let f;e[2]!==s||e[3]!==l||e[4]!==t||e[5]!==a||e[6]!==i?(f=(i||l||t||s)&&r.jsxs("div",{className:N("flex items-center justify-between gap-3 px-4",a),children:[r.jsxs("div",{className:"flex flex-col gap-1 min-w-0",children:[i&&r.jsx("h2",{className:"text-[15px] font-medium leading-tight",children:i}),(l||t)&&r.jsxs("p",{className:"text-sm text-muted-foreground leading-snug",children:[l,t&&r.jsxs("a",{href:t,target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-0.5 ml-1 text-foreground hover:underline",children:["Docs ",r.jsx(E,{size:12})]})]})]}),s&&r.jsx("div",{className:"shrink-0",children:s})]}),e[2]=s,e[3]=l,e[4]=t,e[5]=a,e[6]=i,e[7]=f):f=e[7];let o;return e[8]!==d||e[9]!==m||e[10]!==f?(o=r.jsxs("section",{className:m,children:[f,d]}),e[8]=d,e[9]=m,e[10]=f,e[11]=o):o=e[11],o}function P(c){const e=v.c(11),{className:i,children:l}=c;let t,s,n;if(e[0]!==l||e[1]!==i){const d=S.Children.toArray(l).filter(S.isValidElement);t=w,e[5]!==i?(s=N("p-0 gap-0 overflow-hidden",i),e[5]=i,e[6]=s):s=e[6],n=d.map($),e[0]=l,e[1]=i,e[2]=t,e[3]=s,e[4]=n}else t=e[2],s=e[3],n=e[4];let a;return e[7]!==t||e[8]!==s||e[9]!==n?(a=r.jsx(t,{className:s,children:n}),e[7]=t,e[8]=s,e[9]=n,e[10]=a):a=e[10],a}function $(c,e){return r.jsxs("div",{children:[e>0&&r.jsx("div",{className:"h-px bg-border mx-5"}),c]},e)}function R(c){const e=v.c(27),{icon:i,title:l,description:t,action:s,onClick:n,className:a,children:d}=c,m=d?"flex items-start gap-3 px-4 py-4":"flex items-center gap-3 px-4 py-4",f=n&&"hover:bg-muted/50 cursor-pointer";let o;e[0]!==a||e[1]!==m||e[2]!==f?(o=N(m,f,a),e[0]=a,e[1]=m,e[2]=f,e[3]=o):o=e[3];const b=n?"button":void 0,C=n?0:void 0;let x;e[4]!==n?(x=n?k=>{(k.key==="Enter"||k.key===" ")&&(k.preventDefault(),n())}:void 0,e[4]=n,e[5]=x):x=e[5];let p;e[6]!==i?(p=i&&r.jsx("div",{className:"size-8 shrink-0 rounded-lg bg-muted/60 flex items-center justify-center text-muted-foreground",children:i}),e[6]=i,e[7]=p):p=e[7];let u;e[8]!==l?(u=r.jsx("div",{className:"text-sm font-medium",children:l}),e[8]=l,e[9]=u):u=e[9];let h;e[10]!==t?(h=t&&r.jsx("p",{className:"text-xs text-muted-foreground mt-0.5 leading-relaxed",children:t}),e[10]=t,e[11]=h):h=e[11];let g;e[12]!==d||e[13]!==u||e[14]!==h?(g=r.jsxs("div",{className:"flex-1 min-w-0",children:[u,h,d]}),e[12]=d,e[13]=u,e[14]=h,e[15]=g):g=e[15];let j;e[16]!==s?(j=s&&r.jsx("div",{className:"shrink-0",onClick:D,children:s}),e[16]=s,e[17]=j):j=e[17];let y;return e[18]!==n||e[19]!==g||e[20]!==j||e[21]!==o||e[22]!==b||e[23]!==C||e[24]!==x||e[25]!==p?(y=r.jsxs("div",{className:o,onClick:n,role:b,tabIndex:C,onKeyDown:x,children:[p,g,j]}),e[18]=n,e[19]=g,e[20]=j,e[21]=o,e[22]=b,e[23]=C,e[24]=x,e[25]=p,e[26]=y):y=e[26],y}function D(c){return c.stopPropagation()}function H(c){const e=v.c(5),{children:i,className:l}=c;let t;e[0]!==l?(t=N("flex items-center justify-end gap-2 px-4 py-4",l),e[0]=l,e[1]=t):t=e[1];let s;return e[2]!==i||e[3]!==t?(s=r.jsx("div",{className:t,children:i}),e[2]=i,e[3]=t,e[4]=s):s=e[4],s}function K(c){const e=v.c(5),{className:i,children:l}=c;let t;e[0]!==i?(t=N("flex flex-col gap-10",i),e[0]=i,e[1]=t):t=e[1];let s;return e[2]!==l||e[3]!==t?(s=r.jsx("div",{className:t,children:l}),e[2]=l,e[3]=t,e[4]=s):s=e[4],s}export{I as S,P as a,R as b,H as c,K as d};
@@ -1 +1 @@
1
- import{e as f,j as a}from"./index-CM1D3IOd.js";import{u as d,c as b,d as p,e as h}from"./sidebar-DapD5BLH.js";import{i as u}from"./LayoutLeft-BtnBeX4Q.js";import{T as S}from"./toolbar-ZFFuL6YR.js";function T(){const t=f.c(3),{toggleSidebar:e}=d();let o;t[0]===Symbol.for("react.memo_cache_sentinel")?(o=a.jsx(u,{size:16}),t[0]=o):o=t[0];let s;return t[1]!==e?(s=a.jsx(S,{onClick:e,"aria-label":"Toggle sidebar",children:o}),t[1]=e,t[2]=s):s=t[2],s}function M(t){const e=f.c(12),{renderSidebar:o}=t,{openMobile:s,setOpenMobile:i}=d();let c;e[0]===Symbol.for("react.memo_cache_sentinel")?(c=a.jsx(b,{className:"sr-only",children:"Navigation"}),e[0]=c):c=e[0];let l;e[1]!==i?(l=()=>i(!1),e[1]=i,e[2]=l):l=e[2];let r;e[3]!==o||e[4]!==l?(r=o({onClose:l}),e[3]=o,e[4]=l,e[5]=r):r=e[5];let n;e[6]!==r?(n=a.jsxs(p,{side:"left",hideCloseButton:!0,className:"w-[calc(100vw-3rem)] sm:max-w-md! p-0",children:[c,r]}),e[6]=r,e[7]=n):n=e[7];let m;return e[8]!==s||e[9]!==i||e[10]!==n?(m=a.jsx(h,{open:s,onOpenChange:i,children:n}),e[8]=s,e[9]=i,e[10]=n,e[11]=m):m=e[11],m}export{M,T as S};
1
+ import{e as f,j as a}from"./index-C_etCvW6.js";import{u as d,c as b,d as p,e as h}from"./sidebar-BMGvDz3J.js";import{i as u}from"./LayoutLeft-_rPJ3Xdj.js";import{T as S}from"./toolbar-C9yYx7bm.js";function T(){const t=f.c(3),{toggleSidebar:e}=d();let o;t[0]===Symbol.for("react.memo_cache_sentinel")?(o=a.jsx(u,{size:16}),t[0]=o):o=t[0];let s;return t[1]!==e?(s=a.jsx(S,{onClick:e,"aria-label":"Toggle sidebar",children:o}),t[1]=e,t[2]=s):s=t[2],s}function M(t){const e=f.c(12),{renderSidebar:o}=t,{openMobile:s,setOpenMobile:i}=d();let c;e[0]===Symbol.for("react.memo_cache_sentinel")?(c=a.jsx(b,{className:"sr-only",children:"Navigation"}),e[0]=c):c=e[0];let l;e[1]!==i?(l=()=>i(!1),e[1]=i,e[2]=l):l=e[2];let r;e[3]!==o||e[4]!==l?(r=o({onClose:l}),e[3]=o,e[4]=l,e[5]=r):r=e[5];let n;e[6]!==r?(n=a.jsxs(p,{side:"left",hideCloseButton:!0,className:"w-[calc(100vw-3rem)] sm:max-w-md! p-0",children:[c,r]}),e[6]=r,e[7]=n):n=e[7];let m;return e[8]!==s||e[9]!==i||e[10]!==n?(m=a.jsx(h,{open:s,onOpenChange:i,children:n}),e[8]=s,e[9]=i,e[10]=n,e[11]=m):m=e[11],m}export{M,T as S};
@@ -1 +1 @@
1
- import{e as v,a as K,j as o,B as O,o as R,b as G,s as Y,K as Q,r as I,bi as ne,f as se,q as oe,g as ie,d as ae,Z as re,U as F,S as le,O as ce,bj as de}from"./index-CM1D3IOd.js";import{A as V}from"./avatar-DeKO2t6e.js";import{t as ue,a as me}from"./Users03-BScPbfBT.js";import{i as Z}from"./Lock01-CLcwdBbZ.js";import{a as fe,b as ge,s as P,n as he,i as pe}from"./Stars02-DjyZ6rm8.js";import{s as xe}from"./XClose-8wwGH-xu.js";import{i as L}from"./CheckCircle-CeozB0CE.js";import{i as q}from"./FilterLines-DOivCNH_.js";import{i as B}from"./Zap-DGOMtCmx.js";import{a as be,c as ye,d as Se,b as je}from"./dialog-TcaoJB0K.js";import{R as we}from"./required-auth-layout-CUCq1Ujt.js";import{g as ve,u as Ne,A as ke}from"./hooks-Bhk1YQ2I.js";import{g as _e}from"./constants-BwYc8BqM.js";import{a as ze}from"./use-organization-settings-Kf9UVBw8.js";import{u as Oe}from"./use-org-sso-BHhjzT3n.js";function Ce(t){const e=v.c(27),{orgName:s,orgSlug:n,orgLogo:c,domain:i}=t;let a;e[0]!==n?(a={mutationFn:async()=>{const y=await fetch("/api/auth/custom/domain-join",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({organizationSlug:n})}),k=await y.json();if(!y.ok||!k.success)throw new Error(k.error??"Failed to join organization");return k},onSuccess:y=>{window.location.href=`/${y.slug??n}`},onError:Ee},e[0]=n,e[1]=a):a=e[1];const l=K(a),d=$e;let u;e[2]!==c||e[3]!==s?(u=c?o.jsx(V,{url:c,fallback:s.charAt(0).toUpperCase(),shape:"square",size:"base",className:"h-12 w-12"}):o.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:o.jsx(ue,{className:"h-6 w-6 text-primary"})}),e[2]=c,e[3]=s,e[4]=u):u=e[4];let m;e[5]!==s?(m=o.jsxs("h3",{className:"text-lg font-medium",children:["Join ",s,"?"]}),e[5]=s,e[6]=m):m=e[6];let r;e[7]!==i?(r=o.jsxs("p",{className:"text-sm text-muted-foreground",children:["Anyone with an ",o.jsxs("strong",{children:["@",i]})," email can join this organization."]}),e[7]=i,e[8]=r):r=e[8];let h;e[9]!==m||e[10]!==r?(h=o.jsxs("div",{className:"space-y-2",children:[m,r]}),e[9]=m,e[10]=r,e[11]=h):h=e[11];let b;e[12]!==l?(b=()=>l.mutate(),e[12]=l,e[13]=b):b=e[13];const p=l.isPending?"Joining…":`Enter ${s}`;let f;e[14]!==l.isPending||e[15]!==b||e[16]!==p?(f=o.jsx(O,{onClick:b,disabled:l.isPending,children:p}),e[14]=l.isPending,e[15]=b,e[16]=p,e[17]=f):f=e[17];let g;e[18]!==l.isPending?(g=o.jsx(O,{variant:"ghost",onClick:d,disabled:l.isPending,children:"Go to home"}),e[18]=l.isPending,e[19]=g):g=e[19];let x;e[20]!==f||e[21]!==g?(x=o.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[f,g]}),e[20]=f,e[21]=g,e[22]=x):x=e[22];let j;return e[23]!==x||e[24]!==u||e[25]!==h?(j=o.jsx("div",{className:"flex items-center justify-center min-h-screen bg-background",children:o.jsxs("div",{className:"flex flex-col items-center text-center space-y-4 max-w-sm px-6",children:[u,h,x]})}),e[23]=x,e[24]=u,e[25]=h,e[26]=j):j=e[26],j}function $e(){window.location.href="/"}function Ee(t){R.error(t instanceof Error?t.message:"Failed to join organization")}function W(t){const e=v.c(17),{orgSlug:s,orgName:n,reason:c}=t,i=Ae,a=c==="not-found",l=a?fe:Z,d=a?"Organization not found":"No access";let u;e[0]!==a||e[1]!==n||e[2]!==s?(u=a?o.jsxs(o.Fragment,{children:["We couldn't find an organization called ",o.jsx("strong",{children:s}),"."]}):o.jsxs(o.Fragment,{children:["You don't have access to ",o.jsx("strong",{children:n??s}),". Ask an admin to invite you."]}),e[0]=a,e[1]=n,e[2]=s,e[3]=u):u=e[3];const m=u;let r;e[4]!==l?(r=o.jsx("div",{className:"bg-muted p-3 rounded-full",children:o.jsx(l,{className:"h-6 w-6 text-muted-foreground"})}),e[4]=l,e[5]=r):r=e[5];let h;e[6]!==d?(h=o.jsx("h3",{className:"text-lg font-medium",children:d}),e[6]=d,e[7]=h):h=e[7];let b;e[8]!==m?(b=o.jsx("p",{className:"text-sm text-muted-foreground",children:m}),e[8]=m,e[9]=b):b=e[9];let p;e[10]!==h||e[11]!==b?(p=o.jsxs("div",{className:"space-y-2",children:[h,b]}),e[10]=h,e[11]=b,e[12]=p):p=e[12];let f;e[13]===Symbol.for("react.memo_cache_sentinel")?(f=o.jsx(O,{onClick:i,children:"Go to home"}),e[13]=f):f=e[13];let g;return e[14]!==r||e[15]!==p?(g=o.jsx("div",{className:"flex items-center justify-center min-h-screen bg-background",children:o.jsxs("div",{className:"flex flex-col items-center text-center space-y-4 max-w-sm px-6",children:[r,p,f]})}),e[14]=r,e[15]=p,e[16]=g):g=e[16],g}function Ae(){window.location.href="/"}function Te(t){const e=v.c(39),{invitationId:s,orgName:n,orgSlug:c,orgLogo:i}=t;let a;e[0]!==s?(a=async()=>{const C=await G.organization.acceptInvitation({invitationId:s});if(C.error)throw new Error(C.error.message);return C.data},e[0]=s,e[1]=a):a=e[1];let l;e[2]!==c?(l=()=>{window.location.href=`/${c}`},e[2]=c,e[3]=l):l=e[3];let d;e[4]!==a||e[5]!==l?(d={mutationFn:a,onSuccess:l,onError:Ie},e[4]=a,e[5]=l,e[6]=d):d=e[6];const u=K(d);let m;e[7]!==s?(m=async()=>{const C=await G.organization.rejectInvitation({invitationId:s});if(C.error)throw new Error(C.error.message);return C.data},e[7]=s,e[8]=m):m=e[8];let r;e[9]===Symbol.for("react.memo_cache_sentinel")?(r=Pe,e[9]=r):r=e[9];let h;e[10]!==m?(h={mutationFn:m,onSuccess:r,onError:Me},e[10]=m,e[11]=h):h=e[11];const b=K(h),p=u.isPending||b.isPending;let f;e[12]!==i||e[13]!==n?(f=i?o.jsx(V,{url:i,fallback:n.charAt(0).toUpperCase(),shape:"square",size:"base",className:"h-12 w-12"}):o.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:o.jsx(ge,{className:"h-6 w-6 text-primary"})}),e[12]=i,e[13]=n,e[14]=f):f=e[14];let g;e[15]!==n?(g=o.jsxs("h3",{className:"text-lg font-medium",children:["You've been invited to ",o.jsx("strong",{children:n})]}),e[15]=n,e[16]=g):g=e[16];let x;e[17]===Symbol.for("react.memo_cache_sentinel")?(x=o.jsx("p",{className:"text-sm text-muted-foreground",children:"Accept the invitation to join this organization."}),e[17]=x):x=e[17];let j;e[18]!==g?(j=o.jsxs("div",{className:"space-y-2",children:[g,x]}),e[18]=g,e[19]=j):j=e[19];let y;e[20]!==u?(y=()=>u.mutate(),e[20]=u,e[21]=y):y=e[21];const k=u.isPending?"Accepting…":"Accept invitation";let N;e[22]!==p||e[23]!==y||e[24]!==k?(N=o.jsx(O,{onClick:y,disabled:p,children:k}),e[22]=p,e[23]=y,e[24]=k,e[25]=N):N=e[25];let _;e[26]!==b?(_=()=>b.mutate(),e[26]=b,e[27]=_):_=e[27];const S=b.isPending?"Declining…":"Decline";let w;e[28]!==p||e[29]!==_||e[30]!==S?(w=o.jsx(O,{variant:"ghost",onClick:_,disabled:p,children:S}),e[28]=p,e[29]=_,e[30]=S,e[31]=w):w=e[31];let T;e[32]!==N||e[33]!==w?(T=o.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[N,w]}),e[32]=N,e[33]=w,e[34]=T):T=e[34];let M;return e[35]!==j||e[36]!==T||e[37]!==f?(M=o.jsx("div",{className:"flex items-center justify-center min-h-screen bg-background",children:o.jsxs("div",{className:"flex flex-col items-center text-center space-y-4 max-w-sm px-6",children:[f,j,T]})}),e[35]=j,e[36]=T,e[37]=f,e[38]=M):M=e[38],M}function Me(t){R.error(t instanceof Error?t.message:"Failed to decline invitation")}function Pe(){R.success("Invitation declined"),window.location.href="/"}function Ie(t){R.error(t instanceof Error?t.message:"Failed to accept invitation")}function De(t){const e=v.c(7);let s;e[0]!==t?(s=Q.orgAccessStatus(t),e[0]=t,e[1]=s):s=e[1];let n;e[2]!==t?(n=async()=>{const i=await fetch(`/api/auth/custom/org-access-status/${encodeURIComponent(t)}`,{credentials:"include"});if(!i.ok)throw new Error(`org-access-status failed (${i.status})`);return await i.json()},e[2]=t,e[3]=n):n=e[3];let c;return e[4]!==s||e[5]!==n?(c={queryKey:s,queryFn:n,refetchOnWindowFocus:!1},e[4]=s,e[5]=n,e[6]=c):c=e[6],Y(c)}function Re(t){const e=v.c(15),{orgSlug:s}=t,{data:n}=De(s);if(n.status==="not-found"){let i;return e[0]!==s?(i=o.jsx(W,{orgSlug:s,reason:"not-found"}),e[0]=s,e[1]=i):i=e[1],i}if(n.status==="pending-invite"){let i;return e[2]!==n.invitation.id||e[3]!==n.organization.logo||e[4]!==n.organization.name||e[5]!==n.organization.slug?(i=o.jsx(Te,{invitationId:n.invitation.id,orgName:n.organization.name,orgSlug:n.organization.slug,orgLogo:n.organization.logo}),e[2]=n.invitation.id,e[3]=n.organization.logo,e[4]=n.organization.name,e[5]=n.organization.slug,e[6]=i):i=e[6],i}if(n.status==="auto-domain-join"){const i=n.organization.domain??"";let a;return e[7]!==n.organization.logo||e[8]!==n.organization.name||e[9]!==n.organization.slug||e[10]!==i?(a=o.jsx(Ce,{orgName:n.organization.name,orgSlug:n.organization.slug,orgLogo:n.organization.logo,domain:i}),e[7]=n.organization.logo,e[8]=n.organization.name,e[9]=n.organization.slug,e[10]=i,e[11]=a):a=e[11],a}if(n.status==="member")return window.location.reload(),null;let c;return e[12]!==n.organization.name||e[13]!==s?(c=o.jsx(W,{orgSlug:s,orgName:n.organization.name,reason:"no-access"}),e[12]=n.organization.name,e[13]=s,e[14]=c):c=e[14],c}function Fe(t){const e=v.c(20),{release:s,onCtaClick:n,onLearnMoreClick:c}=t;let i;e[0]!==s.eyebrow?(i=s.eyebrow&&o.jsx("p",{className:"text-xs text-muted-foreground",children:s.eyebrow}),e[0]=s.eyebrow,e[1]=i):i=e[1];let a;e[2]!==s.title?(a=o.jsx("h3",{className:"text-base font-semibold text-foreground",children:s.title}),e[2]=s.title,e[3]=a):a=e[3];let l;e[4]!==i||e[5]!==a?(l=o.jsxs("div",{children:[i,a]}),e[4]=i,e[5]=a,e[6]=l):l=e[6];let d;e[7]!==s.bullets?(d=s.bullets.map(Le),e[7]=s.bullets,e[8]=d):d=e[8];let u;e[9]!==d?(u=o.jsx("ul",{className:"flex flex-col gap-3",children:d}),e[9]=d,e[10]=u):u=e[10];let m;e[11]!==n||e[12]!==c||e[13]!==s.cta||e[14]!==s.learnMoreHref?(m=(s.cta||s.learnMoreHref)&&o.jsxs("div",{className:"flex items-center justify-between pt-1",children:[s.learnMoreHref?o.jsx("a",{href:s.learnMoreHref,target:"_blank",rel:"noreferrer",onClick:c,className:"text-xs text-muted-foreground hover:text-foreground underline-offset-2 hover:underline",children:"Learn More"}):o.jsx("span",{}),s.cta&&o.jsx(O,{asChild:!0,size:"sm",onClick:n,children:o.jsx("a",{href:s.cta.href,children:s.cta.label})})]}),e[11]=n,e[12]=c,e[13]=s.cta,e[14]=s.learnMoreHref,e[15]=m):m=e[15];let r;return e[16]!==l||e[17]!==u||e[18]!==m?(r=o.jsxs("div",{className:"flex flex-col gap-3",children:[l,u,m]}),e[16]=l,e[17]=u,e[18]=m,e[19]=r):r=e[19],r}function Le(t,e){return o.jsxs("li",{className:"flex items-start gap-3",children:[o.jsx(t.icon,{size:20,className:"text-muted-foreground mt-0.5 shrink-0"}),o.jsxs("div",{className:"min-w-0",children:[o.jsx("p",{className:"text-sm font-medium text-foreground",children:t.title}),o.jsx("p",{className:"text-xs text-muted-foreground",children:t.body})]})]},e)}const X=[{id:"claude-opus-4-8",date:"2026-05-28",eyebrow:"Now Available",title:"Claude Opus 4.8 is the new default",bullets:[{icon:P,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:L,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:B,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:P,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:q,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:L,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:me,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:B,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:L,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:P,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:q,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:P,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:he,title:"Unified inbox",body:"Org invitations and product updates now share one chronological feed in the sidebar."}]}],D="studio.release-feed.v1",U=new Set;let E="",A={},H=!1;function Ke(){if(H)return E||"{}";try{return localStorage.getItem(D)??"{}"}catch{return E||"{}"}}function ee(t){try{const e=JSON.parse(t);return e&&typeof e=="object"?e:{}}catch{return{}}}function J(){const t=Ke();return t!==E&&(E=t,A=ee(t)),A}function Ge(t){U.add(t);const e=s=>{if(!(s.key!==D&&s.key!==null)){try{const n=localStorage.getItem(D)??"{}",i={...ee(n),...A};A=i,E=JSON.stringify(i)}catch{}t()}};return window.addEventListener("storage",e),()=>{U.delete(t),window.removeEventListener("storage",e)}}function Ue(t){A=t,E=JSON.stringify(t);try{localStorage.setItem(D,E),H=!1}catch{H=!0}U.forEach(e=>e())}function He(){const t=v.c(7),e=I.useSyncExternalStore(Ge,J,J);let s;t[0]!==e?(s=d=>!!e[d],t[0]=e,t[1]=s):s=t[1];const n=s,c=qe;let i;t[2]!==e?(i=X.reduce((d,u)=>e[u.id]?d:d+1,0),t[2]=e,t[3]=i):i=t[3];const a=i;let l;return t[4]!==n||t[5]!==a?(l={isSeen:n,markSeen:c,unseenCount:a},t[4]=n,t[5]=a,t[6]=l):l=t[6],l}function qe(t){A[t]||Ue({...A,[t]:{seenAt:new Date().toISOString()}})}const Be=720*60*60*1e3;function We(t){const[e,s,n]=t.split("-").map(Number);return!e||!s||!n?new Date(t).getTime():new Date(e,s-1,n).getTime()}function Je(t){const e=X[0];if(!e)return null;const s=We(e.date),n=t-s;return n<0||n>Be?null:e}function Ye(){const t=v.c(21),{isSeen:e,markSeen:s}=He();let n,c,i;if(t[0]!==e){i=Symbol.for("react.early_return_sentinel");e:{if(n=Je(Date.now()),!n){i=null;break e}c=e(n.id)}t[0]=e,t[1]=n,t[2]=c,t[3]=i}else n=t[1],c=t[2],i=t[3];if(i!==Symbol.for("react.early_return_sentinel"))return i;if(c)return null;let a;t[4]!==n.id||t[5]!==s?(a=()=>s(n.id),t[4]=n.id,t[5]=s,t[6]=a):a=t[6];let l;t[7]===Symbol.for("react.memo_cache_sentinel")?(l=o.jsx(xe,{size:14}),t[7]=l):l=t[7];let d;t[8]!==a?(d=o.jsx(O,{size:"icon",variant:"ghost","aria-label":"Dismiss release announcement",className:"absolute right-2 top-2 size-7 text-muted-foreground",onClick:a,children:l}),t[8]=a,t[9]=d):d=t[9];let u,m;t[10]!==n.id||t[11]!==s?(u=()=>s(n.id),m=()=>s(n.id),t[10]=n.id,t[11]=s,t[12]=u,t[13]=m):(u=t[12],m=t[13]);let r;t[14]!==n||t[15]!==u||t[16]!==m?(r=o.jsx(Fe,{release:n,onCtaClick:u,onLearnMoreClick:m}),t[14]=n,t[15]=u,t[16]=m,t[17]=r):r=t[17];let h;return t[18]!==d||t[19]!==r?(h=o.jsxs("div",{role:"dialog","aria-label":"Release announcement",className:"fixed bottom-6 right-6 z-50 w-[min(360px,calc(100vw-3rem))] rounded-lg border border-border bg-background p-4 shadow-lg animate-in fade-in slide-in-from-bottom-2 duration-300",children:[d,r]}),t[18]=d,t[19]=r,t[20]=h):h=t[20],h}const te=typeof navigator<"u"&&/Mac|iPhone|iPad/.test(navigator.platform),$=te?"⌘":"Ctrl",z={keyboardShortcuts:{keys:[$,"K"],description:"Keyboard shortcuts"},focusChatInput:{keys:[$,"L"],description:"Focus chat input"},saveAndFormat:{keys:[$,"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:[$,"Enter"],description:"Apply filter"},togglePlanMode:{keys:[$,"Shift","L"],description:"Toggle plan mode"},newTask:{keys:["Shift",$,"S"],description:"New task"},toggleDaemon:{keys:[$,"D"],description:"Toggle daemon logs"}},Qe=[{label:"General",shortcuts:[z.keyboardShortcuts,z.newTask,z.toggleDaemon]},{label:"Editor",shortcuts:[z.saveAndFormat]},{label:"Chat",shortcuts:[z.focusChatInput,z.togglePlanMode,z.sendMessage,z.newLine]},{label:"Questions",shortcuts:[z.selectOption]},{label:"Monitoring",shortcuts:[z.applyFilter]}];function Ve(t){return te?t.metaKey:t.ctrlKey}function Ze(t){const e=v.c(5),{open:s,onOpenChange:n}=t;let c;e[0]===Symbol.for("react.memo_cache_sentinel")?(c=o.jsx(ye,{children:o.jsx(Se,{children:"Keyboard Shortcuts"})}),e[0]=c):c=e[0];let i;e[1]===Symbol.for("react.memo_cache_sentinel")?(i=o.jsxs(be,{className:"sm:max-w-md",children:[c,o.jsx("div",{className:"flex flex-col gap-4",children:Qe.map(Xe)})]}),e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==s?(a=o.jsx(je,{open:s,onOpenChange:n,children:i}),e[2]=n,e[3]=s,e[4]=a):a=e[4],a}function Xe(t){return o.jsxs("div",{children:[o.jsx("h3",{className:"text-xs font-medium text-muted-foreground uppercase tracking-wide mb-2",children:t.label}),o.jsx("div",{className:"flex flex-col gap-1.5",children:t.shortcuts.map(et)})]},t.label)}function et(t){return o.jsxs("div",{className:"flex items-center justify-between py-1",children:[o.jsx("span",{className:"text-sm",children:t.description}),o.jsx("div",{className:"flex items-center gap-1",children:t.keys.map(tt)})]},t.description)}function tt(t){return o.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)}function nt({activeOrg:t}){return t&&ne(t.id,{name:t.name??void 0,slug:t.slug??void 0}),null}function st(t,e,s){if(!s)return null;const n=ve(t,e);return n?n.threads.get().find(i=>i.id===s)?.branch??null:null}function ot(t){const e=v.c(17),{orgSlug:s,orgName:n,domain:c}=t;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,l=it;let d;e[2]===Symbol.for("react.memo_cache_sentinel")?(d=o.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:o.jsx(Z,{className:"h-6 w-6 text-primary"})}),e[2]=d):d=e[2];let u;e[3]===Symbol.for("react.memo_cache_sentinel")?(u=o.jsx("h3",{className:"text-lg font-medium",children:"SSO Authentication Required"}),e[3]=u):u=e[3];let m;e[4]!==c||e[5]!==n?(m=n?o.jsxs(o.Fragment,{children:[o.jsx("strong",{children:n})," requires SSO authentication",c?` via ${c}`:"","."]}):"This organization requires SSO authentication to access.",e[4]=c,e[5]=n,e[6]=m):m=e[6];let r;e[7]!==m?(r=o.jsxs("div",{className:"space-y-2",children:[u,o.jsx("p",{className:"text-sm text-muted-foreground",children:m})]}),e[7]=m,e[8]=r):r=e[8];let h;e[9]!==a?(h=o.jsx(O,{onClick:a,children:"Sign in with SSO"}),e[9]=a,e[10]=h):h=e[10];let b;e[11]===Symbol.for("react.memo_cache_sentinel")?(b=o.jsx(O,{variant:"ghost",onClick:l,children:"Go back"}),e[11]=b):b=e[11];let p;e[12]!==h?(p=o.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[h,b]}),e[12]=h,e[13]=p):p=e[13];let f;return e[14]!==r||e[15]!==p?(f=o.jsx("div",{className:"flex items-center justify-center min-h-screen bg-background",children:o.jsxs("div",{className:"flex flex-col items-center text-center space-y-4 max-w-sm px-6",children:[d,r,p]})}),e[14]=r,e[15]=p,e[16]=f):f=e[16],f}function it(){window.location.href="/"}function at(t){const e=v.c(9),{orgName:s}=t,n=rt;let c;e[0]===Symbol.for("react.memo_cache_sentinel")?(c=o.jsx("div",{className:"bg-muted p-3 rounded-full",children:o.jsx(pe,{className:"h-6 w-6 text-muted-foreground"})}),e[0]=c):c=e[0];let i;e[1]===Symbol.for("react.memo_cache_sentinel")?(i=o.jsx("h3",{className:"text-lg font-medium",children:"Organization unavailable"}),e[1]=i):i=e[1];let a;e[2]!==s?(a=s?o.jsxs(o.Fragment,{children:[o.jsx("strong",{children:s})," has been deleted or is no longer available."]}):"This organization has been deleted or is no longer available.",e[2]=s,e[3]=a):a=e[3];let l;e[4]!==a?(l=o.jsxs("div",{className:"space-y-2",children:[i,o.jsx("p",{className:"text-sm text-muted-foreground",children:a})]}),e[4]=a,e[5]=l):l=e[5];let d;e[6]===Symbol.for("react.memo_cache_sentinel")?(d=o.jsx(O,{onClick:n,children:"Go to home"}),e[6]=d):d=e[6];let u;return e[7]!==l?(u=o.jsx("div",{className:"flex items-center justify-center min-h-screen bg-background",children:o.jsxs("div",{className:"flex flex-col items-center text-center space-y-4 max-w-sm px-6",children:[c,l,d]})}),e[7]=l,e[8]=u):u=e[8],u}function rt(){window.location.href="/"}function lt(t){const e=v.c(8),{org:s,children:n}=t,i=ze(s.id,s.slug)?.enabled_plugins??null;let a;e[0]!==s.id||e[1]!==s.name||e[2]!==i?(a={id:s.id,organizationId:s.id,slug:"_org",name:s.name,enabledPlugins:i,ui:null},e[0]=s.id,e[1]=s.name,e[2]=i,e[3]=a):a=e[3];const l=a;let d;return e[4]!==n||e[5]!==s||e[6]!==l?(d=o.jsx(de,{org:s,project:l,children:n}),e[4]=n,e[5]=s,e[6]=l,e[7]=d):d=e[7],d}function ct(){const t=se(),{create:e}=Ne(),{org:s,locator:n}=oe(),c=ie({strict:!1}),i=ae({strict:!1}),a=c.org??"",l=c.taskId??"",d=(f,g,x=!0)=>t({to:"/$org/$taskId",params:{org:a,taskId:f},search:g,replace:x}),u=(f,g=!0)=>d(l,f,g),m=f=>u(g=>({...g,chat:f?1:0})),r=(f,g,x)=>d(f,j=>{const y={chat:1};return g?y.virtualmcpid=g:j.virtualmcpid&&(y.virtualmcpid=j.virtualmcpid),j.main&&(y.main=j.main),x?.autosend&&(y.autosend=ke),y},!1);return{setChatOpen:m,setTaskId:r,createNewTask:async f=>{const g=crypto.randomUUID(),x=f??i.virtualmcpid??_e(s.id).id,y=x===i.virtualmcpid?st(s.slug,n,l):null;try{await e({id:g,virtual_mcp_id:x,...y?{branch:y}:{}})}catch{}r(g,x)},openTab:f=>d(l||crypto.randomUUID(),g=>({...g,main:f})),toggleMain:()=>u(f=>{if(f.main!==void 0&&f.main!=="0")return{...f,main:"0"};const x={...f};return delete x.main,x})}}function dt(){const t=v.c(33);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e={from:"/shell/$org",shouldThrow:!1},t[0]=e):e=t[0];const n=re(e)?.params.org,[c,i]=I.useState(!1);let a,l;t[1]===Symbol.for("react.memo_cache_sentinel")?(a=()=>{const S=w=>{Ve(w)&&w.code==="KeyK"&&(w.preventDefault(),i(!0))};return document.addEventListener("keydown",S),()=>document.removeEventListener("keydown",S)},l=[],t[1]=a,t[2]=l):(a=t[1],l=t[2]),I.useEffect(a,l);let d;t[3]!==n?(d=Q.activeOrganization(n),t[3]=n,t[4]=d):d=t[4];let u;t[5]!==n?(u=async()=>{if(!n)return null;const{data:S}=await G.organization.getFullOrganization({query:{organizationSlug:n}}),w=S?.metadata?.archived===!0;return S&&!w&&localStorage.setItem(F.lastOrgSlug(),n),S},t[5]=n,t[6]=u):u=t[6];let m;t[7]!==d||t[8]!==u?(m={queryKey:d,queryFn:u,gcTime:1/0,refetchOnWindowFocus:!1},t[7]=d,t[8]=u,t[9]=m):m=t[9];const{data:r}=Y(m),h=r?.id,b=r?.slug,{data:p}=Oe(h,b);if(!r){let S;t[10]===Symbol.for("react.memo_cache_sentinel")?(S=o.jsx(le,{}),t[10]=S):S=t[10];let w;return t[11]!==n?(w=o.jsx(I.Suspense,{fallback:S,children:o.jsx(Re,{orgSlug:n})}),t[11]=n,t[12]=w):w=t[12],w}if(r.metadata?.archived===!0){localStorage.getItem(F.lastOrgSlug())===n&&localStorage.removeItem(F.lastOrgSlug());let S;return t[13]!==r.name?(S=o.jsx(at,{orgName:r.name}),t[13]=r.name,t[14]=S):S=t[14],S}if(p?.ssoRequired&&!p.authenticated){let S;return t[15]!==r.id||t[16]!==r.name||t[17]!==r.slug||t[18]!==p.domain?(S=o.jsx(ot,{orgId:r.id,orgSlug:r.slug,orgName:r.name,domain:p.domain}),t[15]=r.id,t[16]=r.name,t[17]=r.slug,t[18]=p.domain,t[19]=S):S=t[19],S}const g=r.logo??null;let x;t[20]!==r||t[21]!==g?(x={...r,logo:g},t[20]=r,t[21]=g,t[22]=x):x=t[22];let j;t[23]!==r?(j=o.jsx(nt,{activeOrg:r}),t[23]=r,t[24]=j):j=t[24];let y,k;t[25]===Symbol.for("react.memo_cache_sentinel")?(k=o.jsx(ce,{}),y=o.jsx(Ye,{}),t[25]=y,t[26]=k):(y=t[25],k=t[26]);let N;t[27]!==c?(N=o.jsx(Ze,{open:c,onOpenChange:i}),t[27]=c,t[28]=N):N=t[28];let _;return t[29]!==N||t[30]!==x||t[31]!==j?(_=o.jsxs(lt,{org:x,children:[j,k,y,N]}),t[29]=N,t[30]=x,t[31]=j,t[32]=_):_=t[32],_}function ut(){const t=v.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=o.jsx(we,{children:o.jsx(dt,{})}),t[0]=e):e=t[0],e}const zt=Object.freeze(Object.defineProperty({__proto__:null,default:ut,usePanelActions:ct},Symbol.toStringTag,{value:"Module"}));export{z as K,X as R,He as a,Fe as b,Ve as i,st as r,zt as s,ct as u};
1
+ import{e as v,a as K,j as o,B as O,o as R,b as G,s as Y,K as Q,r as I,bi as ne,f as se,q as oe,g as ie,d as ae,Z as re,U as F,S as le,O as ce,bj as de}from"./index-C_etCvW6.js";import{A as V}from"./avatar-vA2R8qEK.js";import{t as ue,a as me}from"./Users03-DGJmr08f.js";import{i as Z}from"./Lock01-BCib8CWc.js";import{a as fe,b as ge,s as P,n as he,i as pe}from"./Stars02-M_tqgIvg.js";import{s as xe}from"./XClose-wy0ZjI4q.js";import{i as L}from"./CheckCircle-BEasBYv4.js";import{i as q}from"./FilterLines-z8ejuVIV.js";import{i as B}from"./Zap-B74dlfsg.js";import{a as be,c as ye,d as Se,b as je}from"./dialog-B_fGUV_0.js";import{R as we}from"./required-auth-layout-r_pSqbfY.js";import{g as ve,u as Ne,A as ke}from"./hooks-wb_9T_1N.js";import{g as _e}from"./constants-oggaZSfP.js";import{a as ze}from"./use-organization-settings-CpDAWMUD.js";import{u as Oe}from"./use-org-sso-T1wSzyZP.js";function Ce(t){const e=v.c(27),{orgName:s,orgSlug:n,orgLogo:c,domain:i}=t;let a;e[0]!==n?(a={mutationFn:async()=>{const y=await fetch("/api/auth/custom/domain-join",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({organizationSlug:n})}),k=await y.json();if(!y.ok||!k.success)throw new Error(k.error??"Failed to join organization");return k},onSuccess:y=>{window.location.href=`/${y.slug??n}`},onError:Ee},e[0]=n,e[1]=a):a=e[1];const l=K(a),d=$e;let u;e[2]!==c||e[3]!==s?(u=c?o.jsx(V,{url:c,fallback:s.charAt(0).toUpperCase(),shape:"square",size:"base",className:"h-12 w-12"}):o.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:o.jsx(ue,{className:"h-6 w-6 text-primary"})}),e[2]=c,e[3]=s,e[4]=u):u=e[4];let m;e[5]!==s?(m=o.jsxs("h3",{className:"text-lg font-medium",children:["Join ",s,"?"]}),e[5]=s,e[6]=m):m=e[6];let r;e[7]!==i?(r=o.jsxs("p",{className:"text-sm text-muted-foreground",children:["Anyone with an ",o.jsxs("strong",{children:["@",i]})," email can join this organization."]}),e[7]=i,e[8]=r):r=e[8];let h;e[9]!==m||e[10]!==r?(h=o.jsxs("div",{className:"space-y-2",children:[m,r]}),e[9]=m,e[10]=r,e[11]=h):h=e[11];let b;e[12]!==l?(b=()=>l.mutate(),e[12]=l,e[13]=b):b=e[13];const p=l.isPending?"Joining…":`Enter ${s}`;let f;e[14]!==l.isPending||e[15]!==b||e[16]!==p?(f=o.jsx(O,{onClick:b,disabled:l.isPending,children:p}),e[14]=l.isPending,e[15]=b,e[16]=p,e[17]=f):f=e[17];let g;e[18]!==l.isPending?(g=o.jsx(O,{variant:"ghost",onClick:d,disabled:l.isPending,children:"Go to home"}),e[18]=l.isPending,e[19]=g):g=e[19];let x;e[20]!==f||e[21]!==g?(x=o.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[f,g]}),e[20]=f,e[21]=g,e[22]=x):x=e[22];let j;return e[23]!==x||e[24]!==u||e[25]!==h?(j=o.jsx("div",{className:"flex items-center justify-center min-h-screen bg-background",children:o.jsxs("div",{className:"flex flex-col items-center text-center space-y-4 max-w-sm px-6",children:[u,h,x]})}),e[23]=x,e[24]=u,e[25]=h,e[26]=j):j=e[26],j}function $e(){window.location.href="/"}function Ee(t){R.error(t instanceof Error?t.message:"Failed to join organization")}function W(t){const e=v.c(17),{orgSlug:s,orgName:n,reason:c}=t,i=Ae,a=c==="not-found",l=a?fe:Z,d=a?"Organization not found":"No access";let u;e[0]!==a||e[1]!==n||e[2]!==s?(u=a?o.jsxs(o.Fragment,{children:["We couldn't find an organization called ",o.jsx("strong",{children:s}),"."]}):o.jsxs(o.Fragment,{children:["You don't have access to ",o.jsx("strong",{children:n??s}),". Ask an admin to invite you."]}),e[0]=a,e[1]=n,e[2]=s,e[3]=u):u=e[3];const m=u;let r;e[4]!==l?(r=o.jsx("div",{className:"bg-muted p-3 rounded-full",children:o.jsx(l,{className:"h-6 w-6 text-muted-foreground"})}),e[4]=l,e[5]=r):r=e[5];let h;e[6]!==d?(h=o.jsx("h3",{className:"text-lg font-medium",children:d}),e[6]=d,e[7]=h):h=e[7];let b;e[8]!==m?(b=o.jsx("p",{className:"text-sm text-muted-foreground",children:m}),e[8]=m,e[9]=b):b=e[9];let p;e[10]!==h||e[11]!==b?(p=o.jsxs("div",{className:"space-y-2",children:[h,b]}),e[10]=h,e[11]=b,e[12]=p):p=e[12];let f;e[13]===Symbol.for("react.memo_cache_sentinel")?(f=o.jsx(O,{onClick:i,children:"Go to home"}),e[13]=f):f=e[13];let g;return e[14]!==r||e[15]!==p?(g=o.jsx("div",{className:"flex items-center justify-center min-h-screen bg-background",children:o.jsxs("div",{className:"flex flex-col items-center text-center space-y-4 max-w-sm px-6",children:[r,p,f]})}),e[14]=r,e[15]=p,e[16]=g):g=e[16],g}function Ae(){window.location.href="/"}function Te(t){const e=v.c(39),{invitationId:s,orgName:n,orgSlug:c,orgLogo:i}=t;let a;e[0]!==s?(a=async()=>{const C=await G.organization.acceptInvitation({invitationId:s});if(C.error)throw new Error(C.error.message);return C.data},e[0]=s,e[1]=a):a=e[1];let l;e[2]!==c?(l=()=>{window.location.href=`/${c}`},e[2]=c,e[3]=l):l=e[3];let d;e[4]!==a||e[5]!==l?(d={mutationFn:a,onSuccess:l,onError:Ie},e[4]=a,e[5]=l,e[6]=d):d=e[6];const u=K(d);let m;e[7]!==s?(m=async()=>{const C=await G.organization.rejectInvitation({invitationId:s});if(C.error)throw new Error(C.error.message);return C.data},e[7]=s,e[8]=m):m=e[8];let r;e[9]===Symbol.for("react.memo_cache_sentinel")?(r=Pe,e[9]=r):r=e[9];let h;e[10]!==m?(h={mutationFn:m,onSuccess:r,onError:Me},e[10]=m,e[11]=h):h=e[11];const b=K(h),p=u.isPending||b.isPending;let f;e[12]!==i||e[13]!==n?(f=i?o.jsx(V,{url:i,fallback:n.charAt(0).toUpperCase(),shape:"square",size:"base",className:"h-12 w-12"}):o.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:o.jsx(ge,{className:"h-6 w-6 text-primary"})}),e[12]=i,e[13]=n,e[14]=f):f=e[14];let g;e[15]!==n?(g=o.jsxs("h3",{className:"text-lg font-medium",children:["You've been invited to ",o.jsx("strong",{children:n})]}),e[15]=n,e[16]=g):g=e[16];let x;e[17]===Symbol.for("react.memo_cache_sentinel")?(x=o.jsx("p",{className:"text-sm text-muted-foreground",children:"Accept the invitation to join this organization."}),e[17]=x):x=e[17];let j;e[18]!==g?(j=o.jsxs("div",{className:"space-y-2",children:[g,x]}),e[18]=g,e[19]=j):j=e[19];let y;e[20]!==u?(y=()=>u.mutate(),e[20]=u,e[21]=y):y=e[21];const k=u.isPending?"Accepting…":"Accept invitation";let N;e[22]!==p||e[23]!==y||e[24]!==k?(N=o.jsx(O,{onClick:y,disabled:p,children:k}),e[22]=p,e[23]=y,e[24]=k,e[25]=N):N=e[25];let _;e[26]!==b?(_=()=>b.mutate(),e[26]=b,e[27]=_):_=e[27];const S=b.isPending?"Declining…":"Decline";let w;e[28]!==p||e[29]!==_||e[30]!==S?(w=o.jsx(O,{variant:"ghost",onClick:_,disabled:p,children:S}),e[28]=p,e[29]=_,e[30]=S,e[31]=w):w=e[31];let T;e[32]!==N||e[33]!==w?(T=o.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[N,w]}),e[32]=N,e[33]=w,e[34]=T):T=e[34];let M;return e[35]!==j||e[36]!==T||e[37]!==f?(M=o.jsx("div",{className:"flex items-center justify-center min-h-screen bg-background",children:o.jsxs("div",{className:"flex flex-col items-center text-center space-y-4 max-w-sm px-6",children:[f,j,T]})}),e[35]=j,e[36]=T,e[37]=f,e[38]=M):M=e[38],M}function Me(t){R.error(t instanceof Error?t.message:"Failed to decline invitation")}function Pe(){R.success("Invitation declined"),window.location.href="/"}function Ie(t){R.error(t instanceof Error?t.message:"Failed to accept invitation")}function De(t){const e=v.c(7);let s;e[0]!==t?(s=Q.orgAccessStatus(t),e[0]=t,e[1]=s):s=e[1];let n;e[2]!==t?(n=async()=>{const i=await fetch(`/api/auth/custom/org-access-status/${encodeURIComponent(t)}`,{credentials:"include"});if(!i.ok)throw new Error(`org-access-status failed (${i.status})`);return await i.json()},e[2]=t,e[3]=n):n=e[3];let c;return e[4]!==s||e[5]!==n?(c={queryKey:s,queryFn:n,refetchOnWindowFocus:!1},e[4]=s,e[5]=n,e[6]=c):c=e[6],Y(c)}function Re(t){const e=v.c(15),{orgSlug:s}=t,{data:n}=De(s);if(n.status==="not-found"){let i;return e[0]!==s?(i=o.jsx(W,{orgSlug:s,reason:"not-found"}),e[0]=s,e[1]=i):i=e[1],i}if(n.status==="pending-invite"){let i;return e[2]!==n.invitation.id||e[3]!==n.organization.logo||e[4]!==n.organization.name||e[5]!==n.organization.slug?(i=o.jsx(Te,{invitationId:n.invitation.id,orgName:n.organization.name,orgSlug:n.organization.slug,orgLogo:n.organization.logo}),e[2]=n.invitation.id,e[3]=n.organization.logo,e[4]=n.organization.name,e[5]=n.organization.slug,e[6]=i):i=e[6],i}if(n.status==="auto-domain-join"){const i=n.organization.domain??"";let a;return e[7]!==n.organization.logo||e[8]!==n.organization.name||e[9]!==n.organization.slug||e[10]!==i?(a=o.jsx(Ce,{orgName:n.organization.name,orgSlug:n.organization.slug,orgLogo:n.organization.logo,domain:i}),e[7]=n.organization.logo,e[8]=n.organization.name,e[9]=n.organization.slug,e[10]=i,e[11]=a):a=e[11],a}if(n.status==="member")return window.location.reload(),null;let c;return e[12]!==n.organization.name||e[13]!==s?(c=o.jsx(W,{orgSlug:s,orgName:n.organization.name,reason:"no-access"}),e[12]=n.organization.name,e[13]=s,e[14]=c):c=e[14],c}function Fe(t){const e=v.c(20),{release:s,onCtaClick:n,onLearnMoreClick:c}=t;let i;e[0]!==s.eyebrow?(i=s.eyebrow&&o.jsx("p",{className:"text-xs text-muted-foreground",children:s.eyebrow}),e[0]=s.eyebrow,e[1]=i):i=e[1];let a;e[2]!==s.title?(a=o.jsx("h3",{className:"text-base font-semibold text-foreground",children:s.title}),e[2]=s.title,e[3]=a):a=e[3];let l;e[4]!==i||e[5]!==a?(l=o.jsxs("div",{children:[i,a]}),e[4]=i,e[5]=a,e[6]=l):l=e[6];let d;e[7]!==s.bullets?(d=s.bullets.map(Le),e[7]=s.bullets,e[8]=d):d=e[8];let u;e[9]!==d?(u=o.jsx("ul",{className:"flex flex-col gap-3",children:d}),e[9]=d,e[10]=u):u=e[10];let m;e[11]!==n||e[12]!==c||e[13]!==s.cta||e[14]!==s.learnMoreHref?(m=(s.cta||s.learnMoreHref)&&o.jsxs("div",{className:"flex items-center justify-between pt-1",children:[s.learnMoreHref?o.jsx("a",{href:s.learnMoreHref,target:"_blank",rel:"noreferrer",onClick:c,className:"text-xs text-muted-foreground hover:text-foreground underline-offset-2 hover:underline",children:"Learn More"}):o.jsx("span",{}),s.cta&&o.jsx(O,{asChild:!0,size:"sm",onClick:n,children:o.jsx("a",{href:s.cta.href,children:s.cta.label})})]}),e[11]=n,e[12]=c,e[13]=s.cta,e[14]=s.learnMoreHref,e[15]=m):m=e[15];let r;return e[16]!==l||e[17]!==u||e[18]!==m?(r=o.jsxs("div",{className:"flex flex-col gap-3",children:[l,u,m]}),e[16]=l,e[17]=u,e[18]=m,e[19]=r):r=e[19],r}function Le(t,e){return o.jsxs("li",{className:"flex items-start gap-3",children:[o.jsx(t.icon,{size:20,className:"text-muted-foreground mt-0.5 shrink-0"}),o.jsxs("div",{className:"min-w-0",children:[o.jsx("p",{className:"text-sm font-medium text-foreground",children:t.title}),o.jsx("p",{className:"text-xs text-muted-foreground",children:t.body})]})]},e)}const X=[{id:"claude-opus-4-8",date:"2026-05-28",eyebrow:"Now Available",title:"Claude Opus 4.8 is the new default",bullets:[{icon:P,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:L,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:B,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:P,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:q,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:L,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:me,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:B,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:L,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:P,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:q,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:P,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:he,title:"Unified inbox",body:"Org invitations and product updates now share one chronological feed in the sidebar."}]}],D="studio.release-feed.v1",U=new Set;let E="",A={},H=!1;function Ke(){if(H)return E||"{}";try{return localStorage.getItem(D)??"{}"}catch{return E||"{}"}}function ee(t){try{const e=JSON.parse(t);return e&&typeof e=="object"?e:{}}catch{return{}}}function J(){const t=Ke();return t!==E&&(E=t,A=ee(t)),A}function Ge(t){U.add(t);const e=s=>{if(!(s.key!==D&&s.key!==null)){try{const n=localStorage.getItem(D)??"{}",i={...ee(n),...A};A=i,E=JSON.stringify(i)}catch{}t()}};return window.addEventListener("storage",e),()=>{U.delete(t),window.removeEventListener("storage",e)}}function Ue(t){A=t,E=JSON.stringify(t);try{localStorage.setItem(D,E),H=!1}catch{H=!0}U.forEach(e=>e())}function He(){const t=v.c(7),e=I.useSyncExternalStore(Ge,J,J);let s;t[0]!==e?(s=d=>!!e[d],t[0]=e,t[1]=s):s=t[1];const n=s,c=qe;let i;t[2]!==e?(i=X.reduce((d,u)=>e[u.id]?d:d+1,0),t[2]=e,t[3]=i):i=t[3];const a=i;let l;return t[4]!==n||t[5]!==a?(l={isSeen:n,markSeen:c,unseenCount:a},t[4]=n,t[5]=a,t[6]=l):l=t[6],l}function qe(t){A[t]||Ue({...A,[t]:{seenAt:new Date().toISOString()}})}const Be=720*60*60*1e3;function We(t){const[e,s,n]=t.split("-").map(Number);return!e||!s||!n?new Date(t).getTime():new Date(e,s-1,n).getTime()}function Je(t){const e=X[0];if(!e)return null;const s=We(e.date),n=t-s;return n<0||n>Be?null:e}function Ye(){const t=v.c(21),{isSeen:e,markSeen:s}=He();let n,c,i;if(t[0]!==e){i=Symbol.for("react.early_return_sentinel");e:{if(n=Je(Date.now()),!n){i=null;break e}c=e(n.id)}t[0]=e,t[1]=n,t[2]=c,t[3]=i}else n=t[1],c=t[2],i=t[3];if(i!==Symbol.for("react.early_return_sentinel"))return i;if(c)return null;let a;t[4]!==n.id||t[5]!==s?(a=()=>s(n.id),t[4]=n.id,t[5]=s,t[6]=a):a=t[6];let l;t[7]===Symbol.for("react.memo_cache_sentinel")?(l=o.jsx(xe,{size:14}),t[7]=l):l=t[7];let d;t[8]!==a?(d=o.jsx(O,{size:"icon",variant:"ghost","aria-label":"Dismiss release announcement",className:"absolute right-2 top-2 size-7 text-muted-foreground",onClick:a,children:l}),t[8]=a,t[9]=d):d=t[9];let u,m;t[10]!==n.id||t[11]!==s?(u=()=>s(n.id),m=()=>s(n.id),t[10]=n.id,t[11]=s,t[12]=u,t[13]=m):(u=t[12],m=t[13]);let r;t[14]!==n||t[15]!==u||t[16]!==m?(r=o.jsx(Fe,{release:n,onCtaClick:u,onLearnMoreClick:m}),t[14]=n,t[15]=u,t[16]=m,t[17]=r):r=t[17];let h;return t[18]!==d||t[19]!==r?(h=o.jsxs("div",{role:"dialog","aria-label":"Release announcement",className:"fixed bottom-6 right-6 z-50 w-[min(360px,calc(100vw-3rem))] rounded-lg border border-border bg-background p-4 shadow-lg animate-in fade-in slide-in-from-bottom-2 duration-300",children:[d,r]}),t[18]=d,t[19]=r,t[20]=h):h=t[20],h}const te=typeof navigator<"u"&&/Mac|iPhone|iPad/.test(navigator.platform),$=te?"⌘":"Ctrl",z={keyboardShortcuts:{keys:[$,"K"],description:"Keyboard shortcuts"},focusChatInput:{keys:[$,"L"],description:"Focus chat input"},saveAndFormat:{keys:[$,"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:[$,"Enter"],description:"Apply filter"},togglePlanMode:{keys:[$,"Shift","L"],description:"Toggle plan mode"},newTask:{keys:["Shift",$,"S"],description:"New task"},toggleDaemon:{keys:[$,"D"],description:"Toggle daemon logs"}},Qe=[{label:"General",shortcuts:[z.keyboardShortcuts,z.newTask,z.toggleDaemon]},{label:"Editor",shortcuts:[z.saveAndFormat]},{label:"Chat",shortcuts:[z.focusChatInput,z.togglePlanMode,z.sendMessage,z.newLine]},{label:"Questions",shortcuts:[z.selectOption]},{label:"Monitoring",shortcuts:[z.applyFilter]}];function Ve(t){return te?t.metaKey:t.ctrlKey}function Ze(t){const e=v.c(5),{open:s,onOpenChange:n}=t;let c;e[0]===Symbol.for("react.memo_cache_sentinel")?(c=o.jsx(ye,{children:o.jsx(Se,{children:"Keyboard Shortcuts"})}),e[0]=c):c=e[0];let i;e[1]===Symbol.for("react.memo_cache_sentinel")?(i=o.jsxs(be,{className:"sm:max-w-md",children:[c,o.jsx("div",{className:"flex flex-col gap-4",children:Qe.map(Xe)})]}),e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==s?(a=o.jsx(je,{open:s,onOpenChange:n,children:i}),e[2]=n,e[3]=s,e[4]=a):a=e[4],a}function Xe(t){return o.jsxs("div",{children:[o.jsx("h3",{className:"text-xs font-medium text-muted-foreground uppercase tracking-wide mb-2",children:t.label}),o.jsx("div",{className:"flex flex-col gap-1.5",children:t.shortcuts.map(et)})]},t.label)}function et(t){return o.jsxs("div",{className:"flex items-center justify-between py-1",children:[o.jsx("span",{className:"text-sm",children:t.description}),o.jsx("div",{className:"flex items-center gap-1",children:t.keys.map(tt)})]},t.description)}function tt(t){return o.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)}function nt({activeOrg:t}){return t&&ne(t.id,{name:t.name??void 0,slug:t.slug??void 0}),null}function st(t,e,s){if(!s)return null;const n=ve(t,e);return n?n.threads.get().find(i=>i.id===s)?.branch??null:null}function ot(t){const e=v.c(17),{orgSlug:s,orgName:n,domain:c}=t;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,l=it;let d;e[2]===Symbol.for("react.memo_cache_sentinel")?(d=o.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:o.jsx(Z,{className:"h-6 w-6 text-primary"})}),e[2]=d):d=e[2];let u;e[3]===Symbol.for("react.memo_cache_sentinel")?(u=o.jsx("h3",{className:"text-lg font-medium",children:"SSO Authentication Required"}),e[3]=u):u=e[3];let m;e[4]!==c||e[5]!==n?(m=n?o.jsxs(o.Fragment,{children:[o.jsx("strong",{children:n})," requires SSO authentication",c?` via ${c}`:"","."]}):"This organization requires SSO authentication to access.",e[4]=c,e[5]=n,e[6]=m):m=e[6];let r;e[7]!==m?(r=o.jsxs("div",{className:"space-y-2",children:[u,o.jsx("p",{className:"text-sm text-muted-foreground",children:m})]}),e[7]=m,e[8]=r):r=e[8];let h;e[9]!==a?(h=o.jsx(O,{onClick:a,children:"Sign in with SSO"}),e[9]=a,e[10]=h):h=e[10];let b;e[11]===Symbol.for("react.memo_cache_sentinel")?(b=o.jsx(O,{variant:"ghost",onClick:l,children:"Go back"}),e[11]=b):b=e[11];let p;e[12]!==h?(p=o.jsxs("div",{className:"flex flex-col gap-2 w-full",children:[h,b]}),e[12]=h,e[13]=p):p=e[13];let f;return e[14]!==r||e[15]!==p?(f=o.jsx("div",{className:"flex items-center justify-center min-h-screen bg-background",children:o.jsxs("div",{className:"flex flex-col items-center text-center space-y-4 max-w-sm px-6",children:[d,r,p]})}),e[14]=r,e[15]=p,e[16]=f):f=e[16],f}function it(){window.location.href="/"}function at(t){const e=v.c(9),{orgName:s}=t,n=rt;let c;e[0]===Symbol.for("react.memo_cache_sentinel")?(c=o.jsx("div",{className:"bg-muted p-3 rounded-full",children:o.jsx(pe,{className:"h-6 w-6 text-muted-foreground"})}),e[0]=c):c=e[0];let i;e[1]===Symbol.for("react.memo_cache_sentinel")?(i=o.jsx("h3",{className:"text-lg font-medium",children:"Organization unavailable"}),e[1]=i):i=e[1];let a;e[2]!==s?(a=s?o.jsxs(o.Fragment,{children:[o.jsx("strong",{children:s})," has been deleted or is no longer available."]}):"This organization has been deleted or is no longer available.",e[2]=s,e[3]=a):a=e[3];let l;e[4]!==a?(l=o.jsxs("div",{className:"space-y-2",children:[i,o.jsx("p",{className:"text-sm text-muted-foreground",children:a})]}),e[4]=a,e[5]=l):l=e[5];let d;e[6]===Symbol.for("react.memo_cache_sentinel")?(d=o.jsx(O,{onClick:n,children:"Go to home"}),e[6]=d):d=e[6];let u;return e[7]!==l?(u=o.jsx("div",{className:"flex items-center justify-center min-h-screen bg-background",children:o.jsxs("div",{className:"flex flex-col items-center text-center space-y-4 max-w-sm px-6",children:[c,l,d]})}),e[7]=l,e[8]=u):u=e[8],u}function rt(){window.location.href="/"}function lt(t){const e=v.c(8),{org:s,children:n}=t,i=ze(s.id,s.slug)?.enabled_plugins??null;let a;e[0]!==s.id||e[1]!==s.name||e[2]!==i?(a={id:s.id,organizationId:s.id,slug:"_org",name:s.name,enabledPlugins:i,ui:null},e[0]=s.id,e[1]=s.name,e[2]=i,e[3]=a):a=e[3];const l=a;let d;return e[4]!==n||e[5]!==s||e[6]!==l?(d=o.jsx(de,{org:s,project:l,children:n}),e[4]=n,e[5]=s,e[6]=l,e[7]=d):d=e[7],d}function ct(){const t=se(),{create:e}=Ne(),{org:s,locator:n}=oe(),c=ie({strict:!1}),i=ae({strict:!1}),a=c.org??"",l=c.taskId??"",d=(f,g,x=!0)=>t({to:"/$org/$taskId",params:{org:a,taskId:f},search:g,replace:x}),u=(f,g=!0)=>d(l,f,g),m=f=>u(g=>({...g,chat:f?1:0})),r=(f,g,x)=>d(f,j=>{const y={chat:1};return g?y.virtualmcpid=g:j.virtualmcpid&&(y.virtualmcpid=j.virtualmcpid),j.main&&(y.main=j.main),x?.autosend&&(y.autosend=ke),y},!1);return{setChatOpen:m,setTaskId:r,createNewTask:async f=>{const g=crypto.randomUUID(),x=f??i.virtualmcpid??_e(s.id).id,y=x===i.virtualmcpid?st(s.slug,n,l):null;try{await e({id:g,virtual_mcp_id:x,...y?{branch:y}:{}})}catch{}r(g,x)},openTab:f=>d(l||crypto.randomUUID(),g=>({...g,main:f})),toggleMain:()=>u(f=>{if(f.main!==void 0&&f.main!=="0")return{...f,main:"0"};const x={...f};return delete x.main,x})}}function dt(){const t=v.c(33);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e={from:"/shell/$org",shouldThrow:!1},t[0]=e):e=t[0];const n=re(e)?.params.org,[c,i]=I.useState(!1);let a,l;t[1]===Symbol.for("react.memo_cache_sentinel")?(a=()=>{const S=w=>{Ve(w)&&w.code==="KeyK"&&(w.preventDefault(),i(!0))};return document.addEventListener("keydown",S),()=>document.removeEventListener("keydown",S)},l=[],t[1]=a,t[2]=l):(a=t[1],l=t[2]),I.useEffect(a,l);let d;t[3]!==n?(d=Q.activeOrganization(n),t[3]=n,t[4]=d):d=t[4];let u;t[5]!==n?(u=async()=>{if(!n)return null;const{data:S}=await G.organization.getFullOrganization({query:{organizationSlug:n}}),w=S?.metadata?.archived===!0;return S&&!w&&localStorage.setItem(F.lastOrgSlug(),n),S},t[5]=n,t[6]=u):u=t[6];let m;t[7]!==d||t[8]!==u?(m={queryKey:d,queryFn:u,gcTime:1/0,refetchOnWindowFocus:!1},t[7]=d,t[8]=u,t[9]=m):m=t[9];const{data:r}=Y(m),h=r?.id,b=r?.slug,{data:p}=Oe(h,b);if(!r){let S;t[10]===Symbol.for("react.memo_cache_sentinel")?(S=o.jsx(le,{}),t[10]=S):S=t[10];let w;return t[11]!==n?(w=o.jsx(I.Suspense,{fallback:S,children:o.jsx(Re,{orgSlug:n})}),t[11]=n,t[12]=w):w=t[12],w}if(r.metadata?.archived===!0){localStorage.getItem(F.lastOrgSlug())===n&&localStorage.removeItem(F.lastOrgSlug());let S;return t[13]!==r.name?(S=o.jsx(at,{orgName:r.name}),t[13]=r.name,t[14]=S):S=t[14],S}if(p?.ssoRequired&&!p.authenticated){let S;return t[15]!==r.id||t[16]!==r.name||t[17]!==r.slug||t[18]!==p.domain?(S=o.jsx(ot,{orgId:r.id,orgSlug:r.slug,orgName:r.name,domain:p.domain}),t[15]=r.id,t[16]=r.name,t[17]=r.slug,t[18]=p.domain,t[19]=S):S=t[19],S}const g=r.logo??null;let x;t[20]!==r||t[21]!==g?(x={...r,logo:g},t[20]=r,t[21]=g,t[22]=x):x=t[22];let j;t[23]!==r?(j=o.jsx(nt,{activeOrg:r}),t[23]=r,t[24]=j):j=t[24];let y,k;t[25]===Symbol.for("react.memo_cache_sentinel")?(k=o.jsx(ce,{}),y=o.jsx(Ye,{}),t[25]=y,t[26]=k):(y=t[25],k=t[26]);let N;t[27]!==c?(N=o.jsx(Ze,{open:c,onOpenChange:i}),t[27]=c,t[28]=N):N=t[28];let _;return t[29]!==N||t[30]!==x||t[31]!==j?(_=o.jsxs(lt,{org:x,children:[j,k,y,N]}),t[29]=N,t[30]=x,t[31]=j,t[32]=_):_=t[32],_}function ut(){const t=v.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=o.jsx(we,{children:o.jsx(dt,{})}),t[0]=e):e=t[0],e}const zt=Object.freeze(Object.defineProperty({__proto__:null,default:ut,usePanelActions:ct},Symbol.toStringTag,{value:"Module"}));export{z as K,X as R,He as a,Fe as b,Ve as i,st as r,zt as s,ct as u};
@@ -1 +1 @@
1
- import{e as b,c as g,j as o,cW as P,bZ as R,bc as A,cX as H,b_ as W,cZ as V,b$ as q,r as T,aW as G,b0 as L,B as Z}from"./index-CM1D3IOd.js";import{i as F}from"./LayoutLeft-BtnBeX4Q.js";import{u as X,c as z,a as B,T as D,b as k}from"./tooltip-Cc8Oz_Tb.js";import{i as J}from"./X-BpMfki2j.js";function K(i){const e=b.c(4);let t;e[0]!==i?({...t}=i,e[0]=i,e[1]=t):t=e[1];let s;return e[2]!==t?(s=o.jsx(R,{"data-slot":"sheet",...t}),e[2]=t,e[3]=s):s=e[3],s}function Q(i){const e=b.c(4);let t;e[0]!==i?({...t}=i,e[0]=i,e[1]=t):t=e[1];let s;return e[2]!==t?(s=o.jsx(W,{"data-slot":"sheet-portal",...t}),e[2]=t,e[3]=s):s=e[3],s}function U(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx(q,{"data-slot":"sheet-overlay",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function Y(i){const e=b.c(20);let t,s,a,l,d;e[0]!==i?({className:s,children:t,side:l,hideCloseButton:d,...a}=i,e[0]=i,e[1]=t,e[2]=s,e[3]=a,e[4]=l,e[5]=d):(t=e[1],s=e[2],a=e[3],l=e[4],d=e[5]);const n=l===void 0?"right":l,r=d===void 0?!1:d;let m;e[6]===Symbol.for("react.memo_cache_sentinel")?(m=o.jsx(U,{}),e[6]=m):m=e[6];const u=n==="right"&&"data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm",h=n==="left"&&"data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm",f=n==="top"&&"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",p=n==="bottom"&&"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t";let x;e[7]!==s||e[8]!==u||e[9]!==h||e[10]!==f||e[11]!==p?(x=g("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out fixed z-50 flex flex-col gap-4 shadow-lg transition ease-in-out data-[state=closed]:duration-200 data-[state=open]:duration-200",u,h,f,p,s),e[7]=s,e[8]=u,e[9]=h,e[10]=f,e[11]=p,e[12]=x):x=e[12];let c;e[13]!==r?(c=!r&&o.jsxs(V,{className:"ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none",children:[o.jsx(J,{className:"size-4"}),o.jsx("span",{className:"sr-only",children:"Close"})]}),e[13]=r,e[14]=c):c=e[14];let v;return e[15]!==t||e[16]!==a||e[17]!==x||e[18]!==c?(v=o.jsxs(Q,{children:[m,o.jsxs(A,{"data-slot":"sheet-content",className:x,...a,children:[t,c]})]}),e[15]=t,e[16]=a,e[17]=x,e[18]=c,e[19]=v):v=e[19],v}function ee(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("flex flex-col gap-1.5 p-4",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-slot":"sheet-header",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function te(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("text-foreground font-semibold",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx(P,{"data-slot":"sheet-title",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function se(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("text-muted-foreground text-sm",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx(H,{"data-slot":"sheet-description",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}const ae="15rem",le="18rem",ie="4.5rem",E=T.createContext(null);function I(){const i=T.useContext(E);if(!i)throw new Error("useSidebar must be used within a SidebarProvider.");return i}function pe(i){const e=b.c(19),{children:t,defaultOpen:s,open:a,onOpenChange:l}=i,d=s===void 0?!1:s,n=X(),[r,m]=T.useState(d),[u,h]=T.useState(!1),f=a!==void 0,p=f?a:r;let x;e[0]!==f||e[1]!==l?(x=$=>{f||m($),l?.($)},e[0]=f,e[1]=l,e[2]=x):x=e[2];const c=x;let v;e[3]!==n||e[4]!==p||e[5]!==c?(v=()=>{n?h(oe):c(!p)},e[3]=n,e[4]=p,e[5]=c,e[6]=v):v=e[6];const y=v,w=p?"expanded":"collapsed";let j;e[7]!==n||e[8]!==p||e[9]!==u||e[10]!==c||e[11]!==w||e[12]!==y?(j={state:w,open:p,setOpen:c,isMobile:n,openMobile:u,setOpenMobile:h,toggleSidebar:y},e[7]=n,e[8]=p,e[9]=u,e[10]=c,e[11]=w,e[12]=y,e[13]=j):j=e[13];const S=j;let N;e[14]!==t?(N=o.jsx(z,{delayDuration:0,children:t}),e[14]=t,e[15]=N):N=e[15];let C;return e[16]!==S||e[17]!==N?(C=o.jsx(E.Provider,{value:S,children:N}),e[16]=S,e[17]=N,e[18]=C):C=e[18],C}function oe(i){return!i}function be(i){const e=b.c(14);let t,s,a,l;e[0]!==i?({className:s,style:l,children:t,...a}=i,e[0]=i,e[1]=t,e[2]=s,e[3]=a,e[4]=l):(t=e[1],s=e[2],a=e[3],l=e[4]);let d;e[5]!==l?(d={"--sidebar-width":ae,"--sidebar-width-icon":ie,...l},e[5]=l,e[6]=d):d=e[6];const n=d;let r;e[7]!==s?(r=g("group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex h-full w-full",s),e[7]=s,e[8]=r):r=e[8];let m;return e[9]!==t||e[10]!==a||e[11]!==n||e[12]!==r?(m=o.jsx("div",{"data-slot":"sidebar-wrapper",style:n,className:r,...a,children:t}),e[9]=t,e[10]=a,e[11]=n,e[12]=r,e[13]=m):m=e[13],m}function me(i){const e=b.c(36);let t,s,a,l,d;e[0]!==i?({side:l,variant:d,className:s,children:t,...a}=i,e[0]=i,e[1]=t,e[2]=s,e[3]=a,e[4]=l,e[5]=d):(t=e[1],s=e[2],a=e[3],l=e[4],d=e[5]);const n=l===void 0?"left":l,r=d===void 0?"sidebar":d,{isMobile:m,state:u,openMobile:h,setOpenMobile:f}=I();if(m){let C;e[6]===Symbol.for("react.memo_cache_sentinel")?(C={"--sidebar-width":le},e[6]=C):C=e[6];let $;e[7]===Symbol.for("react.memo_cache_sentinel")?($=o.jsxs(ee,{className:"sr-only",children:[o.jsx(te,{children:"Sidebar"}),o.jsx(se,{children:"Displays the mobile sidebar."})]}),e[7]=$):$=e[7];let _;e[8]!==t?(_=o.jsx("div",{className:"flex h-full w-full flex-col",children:t}),e[8]=t,e[9]=_):_=e[9];let M;e[10]!==n||e[11]!==_?(M=o.jsxs(Y,{"data-sidebar":"sidebar","data-slot":"sidebar","data-mobile":"true",className:"bg-sidebar text-sidebar-foreground w-(--sidebar-width) p-0 [&>button]:hidden",style:C,side:n,children:[$,_]}),e[10]=n,e[11]=_,e[12]=M):M=e[12];let O;return e[13]!==h||e[14]!==a||e[15]!==f||e[16]!==M?(O=o.jsx(K,{open:h,onOpenChange:f,...a,children:M}),e[13]=h,e[14]=a,e[15]=f,e[16]=M,e[17]=O):O=e[17],O}const p=u==="expanded",x=p?"w-(--sidebar-width)":"w-(--sidebar-width-icon)";let c;e[18]!==x?(c=g("group/sidebar peer text-sidebar-foreground hidden md:flex flex-col shrink-0 overflow-hidden","transition-[width] duration-150 ease-out motion-reduce:transition-none",x),e[18]=x,e[19]=c):c=e[19];const v=p?void 0:"icon",y=p?"w-(--sidebar-width)":"w-(--sidebar-width-icon)";let w;e[20]!==s||e[21]!==y?(w=g("flex flex-col h-full transition-[width] duration-150 ease-out motion-reduce:transition-none",y,s),e[20]=s,e[21]=y,e[22]=w):w=e[22];let j;e[23]!==t?(j=o.jsx("div",{"data-sidebar":"sidebar","data-slot":"sidebar-inner",className:"bg-sidebar flex h-full w-full flex-col",children:t}),e[23]=t,e[24]=j):j=e[24];let S;e[25]!==a||e[26]!==w||e[27]!==j?(S=o.jsx("div",{"data-slot":"sidebar-container",className:w,...a,children:j}),e[25]=a,e[26]=w,e[27]=j,e[28]=S):S=e[28];let N;return e[29]!==n||e[30]!==u||e[31]!==c||e[32]!==v||e[33]!==S||e[34]!==r?(N=o.jsx("div",{className:c,"data-state":u,"data-collapsible":v,"data-variant":r,"data-side":n,"data-slot":"sidebar",children:S}),e[29]=n,e[30]=u,e[31]=c,e[32]=v,e[33]=S,e[34]=r,e[35]=N):N=e[35],N}function he(i){const e=b.c(18);let t,s,a;e[0]!==i?({className:t,onClick:s,...a}=i,e[0]=i,e[1]=t,e[2]=s,e[3]=a):(t=e[1],s=e[2],a=e[3]);const{toggleSidebar:l}=I();let d;e[4]!==t?(d=g("size-7",t),e[4]=t,e[5]=d):d=e[5];let n;e[6]!==s||e[7]!==l?(n=p=>{s?.(p),l()},e[6]=s,e[7]=l,e[8]=n):n=e[8];let r,m;e[9]===Symbol.for("react.memo_cache_sentinel")?(r=o.jsx(F,{}),m=o.jsx("span",{className:"sr-only",children:"Toggle Sidebar"}),e[9]=r,e[10]=m):(r=e[9],m=e[10]);let u;e[11]!==a||e[12]!==d||e[13]!==n?(u=o.jsx(D,{asChild:!0,children:o.jsxs(Z,{"data-sidebar":"trigger","data-slot":"sidebar-trigger",variant:"ghost",size:"icon",className:d,onClick:n,...a,children:[r,m]})}),e[11]=a,e[12]=d,e[13]=n,e[14]=u):u=e[14];let h;e[15]===Symbol.for("react.memo_cache_sentinel")?(h=o.jsxs(B,{side:"bottom",className:"flex items-center gap-1.5",children:["Collapse sidebar",o.jsx("span",{className:"flex items-center gap-0.5",children:["⌘","B"].map(ne)})]}),e[15]=h):h=e[15];let f;return e[16]!==u?(f=o.jsx(z,{delayDuration:300,children:o.jsxs(k,{children:[u,h]})}),e[16]=u,e[17]=f):f=e[17],f}function ne(i){return o.jsx("kbd",{className:"inline-flex items-center justify-center min-w-5 h-5 px-1 rounded-sm border border-white/20 bg-white/10 text-white/70 text-xs font-mono",children:i},i)}function xe(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("bg-background relative flex w-full flex-1 flex-col min-w-0","md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow-sm md:peer-data-[variant=inset]:peer-data-[state=collapsed]:ml-2",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("main",{"data-slot":"sidebar-inset",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function ge(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("flex flex-col gap-2 p-2",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-slot":"sidebar-header","data-sidebar":"header",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function ve(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("flex flex-col gap-2 p-2",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-slot":"sidebar-footer","data-sidebar":"footer",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function je(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("h-4 m-0! w-full",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-sidebar":"separator",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function we(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("flex min-h-0 flex-1 flex-col gap-2",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-slot":"sidebar-content","data-sidebar":"content",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function Ne(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("relative flex w-full min-w-0 flex-col px-2 py-2 md:py-0",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-slot":"sidebar-group","data-sidebar":"group",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function Se(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("w-full text-sm overflow-visible",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-slot":"sidebar-group-content","data-sidebar":"group-content",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function ye(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("flex w-full min-w-0 flex-col gap-1 group-data-[state=collapsed]/sidebar:items-center",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("ul",{"data-slot":"sidebar-menu","data-sidebar":"menu",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function Ce(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("group/menu-item relative w-full",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("li",{"data-slot":"sidebar-menu-item","data-sidebar":"menu-item",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}const re=L("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-lg py-0 pr-0.5 pl-1.5 text-left text-sm outline-0 outline-sidebar-ring transition-[width,height,padding] duration-150 ease-out motion-reduce:transition-none focus-visible:outline-2 focus-visible:-outline-offset-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-data-[sidebar=menu-action]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-accent data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground [&>span:last-child]:truncate group-data-[state=collapsed]/sidebar:[&>span:last-child]:hidden [&>svg]:size-4 [&>svg]:shrink-0 [&_svg]:opacity-60 hover:[&_svg]:opacity-100",{variants:{variant:{default:"hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",outline:"bg-background ring-1 ring-sidebar-border hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:ring-sidebar-accent"},size:{default:"group-data-[state=expanded]/sidebar:h-8 group-data-[state=expanded]/sidebar:px-2 group-data-[state=collapsed]/sidebar:w-full! group-data-[state=collapsed]/sidebar:aspect-square! group-data-[state=collapsed]/sidebar:max-w-[calc(var(--sidebar-width-icon)-1rem)]! group-data-[state=collapsed]/sidebar:h-auto! group-data-[state=collapsed]/sidebar:p-0! group-data-[state=collapsed]/sidebar:mx-auto group-data-[state=collapsed]/sidebar:justify-center text-sm",sm:"h-7 text-xs",lg:"h-12 text-sm p-0!"}},defaultVariants:{variant:"default",size:"default"}});function $e(i){const e=b.c(28);let t,s,a,l,d,n,r;e[0]!==i?({asChild:a,isActive:l,variant:d,size:n,tooltip:r,className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s,e[3]=a,e[4]=l,e[5]=d,e[6]=n,e[7]=r):(t=e[1],s=e[2],a=e[3],l=e[4],d=e[5],n=e[6],r=e[7]);const m=a===void 0?!1:a,u=l===void 0?!1:l,h=d===void 0?"default":d,f=n===void 0?"default":n,p=m?G:"button",{isMobile:x}=I();let c;e[8]!==t||e[9]!==f||e[10]!==h?(c=g(re({variant:h,size:f}),t),e[8]=t,e[9]=f,e[10]=h,e[11]=c):c=e[11];let v;e[12]!==p||e[13]!==u||e[14]!==s||e[15]!==f||e[16]!==c?(v=o.jsx(p,{"data-slot":"sidebar-menu-button","data-sidebar":"menu-button","data-size":f,"data-active":u,className:c,...s}),e[12]=p,e[13]=u,e[14]=s,e[15]=f,e[16]=c,e[17]=v):v=e[17];const y=v;if(!r)return y;if(typeof r=="string"){let N;e[18]!==r?(N={children:r},e[18]=r,e[19]=N):N=e[19],r=N}let w;e[20]!==y?(w=o.jsx(D,{asChild:!0,children:y}),e[20]=y,e[21]=w):w=e[21];let j;e[22]!==x||e[23]!==r?(j=o.jsx(B,{side:"right",align:"center",hidden:x,...r}),e[22]=x,e[23]=r,e[24]=j):j=e[24];let S;return e[25]!==w||e[26]!==j?(S=o.jsxs(k,{children:[w,j]}),e[25]=w,e[26]=j,e[27]=S):S=e[27],S}export{xe as S,be as a,pe as b,te as c,Y as d,K as e,Ce as f,$e as g,Ne as h,Se as i,ye as j,je as k,we as l,me as m,ge as n,ve as o,ee as p,se as q,he as r,I as u};
1
+ import{e as b,c as g,j as o,cW as P,bZ as R,bc as A,cX as H,b_ as W,cZ as V,b$ as q,r as T,aW as G,b0 as L,B as Z}from"./index-C_etCvW6.js";import{i as F}from"./LayoutLeft-_rPJ3Xdj.js";import{u as X,c as z,a as B,T as D,b as k}from"./tooltip-8OqGw7oG.js";import{i as J}from"./X-Coa3_vHC.js";function K(i){const e=b.c(4);let t;e[0]!==i?({...t}=i,e[0]=i,e[1]=t):t=e[1];let s;return e[2]!==t?(s=o.jsx(R,{"data-slot":"sheet",...t}),e[2]=t,e[3]=s):s=e[3],s}function Q(i){const e=b.c(4);let t;e[0]!==i?({...t}=i,e[0]=i,e[1]=t):t=e[1];let s;return e[2]!==t?(s=o.jsx(W,{"data-slot":"sheet-portal",...t}),e[2]=t,e[3]=s):s=e[3],s}function U(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx(q,{"data-slot":"sheet-overlay",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function Y(i){const e=b.c(20);let t,s,a,l,d;e[0]!==i?({className:s,children:t,side:l,hideCloseButton:d,...a}=i,e[0]=i,e[1]=t,e[2]=s,e[3]=a,e[4]=l,e[5]=d):(t=e[1],s=e[2],a=e[3],l=e[4],d=e[5]);const n=l===void 0?"right":l,r=d===void 0?!1:d;let m;e[6]===Symbol.for("react.memo_cache_sentinel")?(m=o.jsx(U,{}),e[6]=m):m=e[6];const u=n==="right"&&"data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm",h=n==="left"&&"data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm",f=n==="top"&&"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",p=n==="bottom"&&"data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom inset-x-0 bottom-0 h-auto border-t";let x;e[7]!==s||e[8]!==u||e[9]!==h||e[10]!==f||e[11]!==p?(x=g("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out fixed z-50 flex flex-col gap-4 shadow-lg transition ease-in-out data-[state=closed]:duration-200 data-[state=open]:duration-200",u,h,f,p,s),e[7]=s,e[8]=u,e[9]=h,e[10]=f,e[11]=p,e[12]=x):x=e[12];let c;e[13]!==r?(c=!r&&o.jsxs(V,{className:"ring-offset-background focus:ring-ring data-[state=open]:bg-secondary absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none",children:[o.jsx(J,{className:"size-4"}),o.jsx("span",{className:"sr-only",children:"Close"})]}),e[13]=r,e[14]=c):c=e[14];let v;return e[15]!==t||e[16]!==a||e[17]!==x||e[18]!==c?(v=o.jsxs(Q,{children:[m,o.jsxs(A,{"data-slot":"sheet-content",className:x,...a,children:[t,c]})]}),e[15]=t,e[16]=a,e[17]=x,e[18]=c,e[19]=v):v=e[19],v}function ee(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("flex flex-col gap-1.5 p-4",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-slot":"sheet-header",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function te(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("text-foreground font-semibold",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx(P,{"data-slot":"sheet-title",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function se(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("text-muted-foreground text-sm",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx(H,{"data-slot":"sheet-description",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}const ae="15rem",le="18rem",ie="4.5rem",E=T.createContext(null);function I(){const i=T.useContext(E);if(!i)throw new Error("useSidebar must be used within a SidebarProvider.");return i}function pe(i){const e=b.c(19),{children:t,defaultOpen:s,open:a,onOpenChange:l}=i,d=s===void 0?!1:s,n=X(),[r,m]=T.useState(d),[u,h]=T.useState(!1),f=a!==void 0,p=f?a:r;let x;e[0]!==f||e[1]!==l?(x=$=>{f||m($),l?.($)},e[0]=f,e[1]=l,e[2]=x):x=e[2];const c=x;let v;e[3]!==n||e[4]!==p||e[5]!==c?(v=()=>{n?h(oe):c(!p)},e[3]=n,e[4]=p,e[5]=c,e[6]=v):v=e[6];const y=v,w=p?"expanded":"collapsed";let j;e[7]!==n||e[8]!==p||e[9]!==u||e[10]!==c||e[11]!==w||e[12]!==y?(j={state:w,open:p,setOpen:c,isMobile:n,openMobile:u,setOpenMobile:h,toggleSidebar:y},e[7]=n,e[8]=p,e[9]=u,e[10]=c,e[11]=w,e[12]=y,e[13]=j):j=e[13];const S=j;let N;e[14]!==t?(N=o.jsx(z,{delayDuration:0,children:t}),e[14]=t,e[15]=N):N=e[15];let C;return e[16]!==S||e[17]!==N?(C=o.jsx(E.Provider,{value:S,children:N}),e[16]=S,e[17]=N,e[18]=C):C=e[18],C}function oe(i){return!i}function be(i){const e=b.c(14);let t,s,a,l;e[0]!==i?({className:s,style:l,children:t,...a}=i,e[0]=i,e[1]=t,e[2]=s,e[3]=a,e[4]=l):(t=e[1],s=e[2],a=e[3],l=e[4]);let d;e[5]!==l?(d={"--sidebar-width":ae,"--sidebar-width-icon":ie,...l},e[5]=l,e[6]=d):d=e[6];const n=d;let r;e[7]!==s?(r=g("group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex h-full w-full",s),e[7]=s,e[8]=r):r=e[8];let m;return e[9]!==t||e[10]!==a||e[11]!==n||e[12]!==r?(m=o.jsx("div",{"data-slot":"sidebar-wrapper",style:n,className:r,...a,children:t}),e[9]=t,e[10]=a,e[11]=n,e[12]=r,e[13]=m):m=e[13],m}function me(i){const e=b.c(36);let t,s,a,l,d;e[0]!==i?({side:l,variant:d,className:s,children:t,...a}=i,e[0]=i,e[1]=t,e[2]=s,e[3]=a,e[4]=l,e[5]=d):(t=e[1],s=e[2],a=e[3],l=e[4],d=e[5]);const n=l===void 0?"left":l,r=d===void 0?"sidebar":d,{isMobile:m,state:u,openMobile:h,setOpenMobile:f}=I();if(m){let C;e[6]===Symbol.for("react.memo_cache_sentinel")?(C={"--sidebar-width":le},e[6]=C):C=e[6];let $;e[7]===Symbol.for("react.memo_cache_sentinel")?($=o.jsxs(ee,{className:"sr-only",children:[o.jsx(te,{children:"Sidebar"}),o.jsx(se,{children:"Displays the mobile sidebar."})]}),e[7]=$):$=e[7];let _;e[8]!==t?(_=o.jsx("div",{className:"flex h-full w-full flex-col",children:t}),e[8]=t,e[9]=_):_=e[9];let M;e[10]!==n||e[11]!==_?(M=o.jsxs(Y,{"data-sidebar":"sidebar","data-slot":"sidebar","data-mobile":"true",className:"bg-sidebar text-sidebar-foreground w-(--sidebar-width) p-0 [&>button]:hidden",style:C,side:n,children:[$,_]}),e[10]=n,e[11]=_,e[12]=M):M=e[12];let O;return e[13]!==h||e[14]!==a||e[15]!==f||e[16]!==M?(O=o.jsx(K,{open:h,onOpenChange:f,...a,children:M}),e[13]=h,e[14]=a,e[15]=f,e[16]=M,e[17]=O):O=e[17],O}const p=u==="expanded",x=p?"w-(--sidebar-width)":"w-(--sidebar-width-icon)";let c;e[18]!==x?(c=g("group/sidebar peer text-sidebar-foreground hidden md:flex flex-col shrink-0 overflow-hidden","transition-[width] duration-150 ease-out motion-reduce:transition-none",x),e[18]=x,e[19]=c):c=e[19];const v=p?void 0:"icon",y=p?"w-(--sidebar-width)":"w-(--sidebar-width-icon)";let w;e[20]!==s||e[21]!==y?(w=g("flex flex-col h-full transition-[width] duration-150 ease-out motion-reduce:transition-none",y,s),e[20]=s,e[21]=y,e[22]=w):w=e[22];let j;e[23]!==t?(j=o.jsx("div",{"data-sidebar":"sidebar","data-slot":"sidebar-inner",className:"bg-sidebar flex h-full w-full flex-col",children:t}),e[23]=t,e[24]=j):j=e[24];let S;e[25]!==a||e[26]!==w||e[27]!==j?(S=o.jsx("div",{"data-slot":"sidebar-container",className:w,...a,children:j}),e[25]=a,e[26]=w,e[27]=j,e[28]=S):S=e[28];let N;return e[29]!==n||e[30]!==u||e[31]!==c||e[32]!==v||e[33]!==S||e[34]!==r?(N=o.jsx("div",{className:c,"data-state":u,"data-collapsible":v,"data-variant":r,"data-side":n,"data-slot":"sidebar",children:S}),e[29]=n,e[30]=u,e[31]=c,e[32]=v,e[33]=S,e[34]=r,e[35]=N):N=e[35],N}function he(i){const e=b.c(18);let t,s,a;e[0]!==i?({className:t,onClick:s,...a}=i,e[0]=i,e[1]=t,e[2]=s,e[3]=a):(t=e[1],s=e[2],a=e[3]);const{toggleSidebar:l}=I();let d;e[4]!==t?(d=g("size-7",t),e[4]=t,e[5]=d):d=e[5];let n;e[6]!==s||e[7]!==l?(n=p=>{s?.(p),l()},e[6]=s,e[7]=l,e[8]=n):n=e[8];let r,m;e[9]===Symbol.for("react.memo_cache_sentinel")?(r=o.jsx(F,{}),m=o.jsx("span",{className:"sr-only",children:"Toggle Sidebar"}),e[9]=r,e[10]=m):(r=e[9],m=e[10]);let u;e[11]!==a||e[12]!==d||e[13]!==n?(u=o.jsx(D,{asChild:!0,children:o.jsxs(Z,{"data-sidebar":"trigger","data-slot":"sidebar-trigger",variant:"ghost",size:"icon",className:d,onClick:n,...a,children:[r,m]})}),e[11]=a,e[12]=d,e[13]=n,e[14]=u):u=e[14];let h;e[15]===Symbol.for("react.memo_cache_sentinel")?(h=o.jsxs(B,{side:"bottom",className:"flex items-center gap-1.5",children:["Collapse sidebar",o.jsx("span",{className:"flex items-center gap-0.5",children:["⌘","B"].map(ne)})]}),e[15]=h):h=e[15];let f;return e[16]!==u?(f=o.jsx(z,{delayDuration:300,children:o.jsxs(k,{children:[u,h]})}),e[16]=u,e[17]=f):f=e[17],f}function ne(i){return o.jsx("kbd",{className:"inline-flex items-center justify-center min-w-5 h-5 px-1 rounded-sm border border-white/20 bg-white/10 text-white/70 text-xs font-mono",children:i},i)}function xe(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("bg-background relative flex w-full flex-1 flex-col min-w-0","md:peer-data-[variant=inset]:m-2 md:peer-data-[variant=inset]:ml-0 md:peer-data-[variant=inset]:rounded-xl md:peer-data-[variant=inset]:shadow-sm md:peer-data-[variant=inset]:peer-data-[state=collapsed]:ml-2",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("main",{"data-slot":"sidebar-inset",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function ge(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("flex flex-col gap-2 p-2",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-slot":"sidebar-header","data-sidebar":"header",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function ve(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("flex flex-col gap-2 p-2",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-slot":"sidebar-footer","data-sidebar":"footer",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function je(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("h-4 m-0! w-full",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-sidebar":"separator",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function we(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("flex min-h-0 flex-1 flex-col gap-2",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-slot":"sidebar-content","data-sidebar":"content",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function Ne(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("relative flex w-full min-w-0 flex-col px-2 py-2 md:py-0",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-slot":"sidebar-group","data-sidebar":"group",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function Se(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("w-full text-sm overflow-visible",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("div",{"data-slot":"sidebar-group-content","data-sidebar":"group-content",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function ye(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("flex w-full min-w-0 flex-col gap-1 group-data-[state=collapsed]/sidebar:items-center",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("ul",{"data-slot":"sidebar-menu","data-sidebar":"menu",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}function Ce(i){const e=b.c(8);let t,s;e[0]!==i?({className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s):(t=e[1],s=e[2]);let a;e[3]!==t?(a=g("group/menu-item relative w-full",t),e[3]=t,e[4]=a):a=e[4];let l;return e[5]!==s||e[6]!==a?(l=o.jsx("li",{"data-slot":"sidebar-menu-item","data-sidebar":"menu-item",className:a,...s}),e[5]=s,e[6]=a,e[7]=l):l=e[7],l}const re=L("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-lg py-0 pr-0.5 pl-1.5 text-left text-sm outline-0 outline-sidebar-ring transition-[width,height,padding] duration-150 ease-out motion-reduce:transition-none focus-visible:outline-2 focus-visible:-outline-offset-2 active:bg-sidebar-accent active:text-sidebar-accent-foreground disabled:pointer-events-none disabled:opacity-50 group-has-data-[sidebar=menu-action]/menu-item:pr-8 aria-disabled:pointer-events-none aria-disabled:opacity-50 data-[active=true]:bg-sidebar-accent data-[active=true]:text-sidebar-accent-foreground data-[state=open]:hover:bg-sidebar-accent data-[state=open]:hover:text-sidebar-accent-foreground [&>span:last-child]:truncate group-data-[state=collapsed]/sidebar:[&>span:last-child]:hidden [&>svg]:size-4 [&>svg]:shrink-0 [&_svg]:opacity-60 hover:[&_svg]:opacity-100",{variants:{variant:{default:"hover:bg-sidebar-accent hover:text-sidebar-accent-foreground",outline:"bg-background ring-1 ring-sidebar-border hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:ring-sidebar-accent"},size:{default:"group-data-[state=expanded]/sidebar:h-8 group-data-[state=expanded]/sidebar:px-2 group-data-[state=collapsed]/sidebar:w-full! group-data-[state=collapsed]/sidebar:aspect-square! group-data-[state=collapsed]/sidebar:max-w-[calc(var(--sidebar-width-icon)-1rem)]! group-data-[state=collapsed]/sidebar:h-auto! group-data-[state=collapsed]/sidebar:p-0! group-data-[state=collapsed]/sidebar:mx-auto group-data-[state=collapsed]/sidebar:justify-center text-sm",sm:"h-7 text-xs",lg:"h-12 text-sm p-0!"}},defaultVariants:{variant:"default",size:"default"}});function $e(i){const e=b.c(28);let t,s,a,l,d,n,r;e[0]!==i?({asChild:a,isActive:l,variant:d,size:n,tooltip:r,className:t,...s}=i,e[0]=i,e[1]=t,e[2]=s,e[3]=a,e[4]=l,e[5]=d,e[6]=n,e[7]=r):(t=e[1],s=e[2],a=e[3],l=e[4],d=e[5],n=e[6],r=e[7]);const m=a===void 0?!1:a,u=l===void 0?!1:l,h=d===void 0?"default":d,f=n===void 0?"default":n,p=m?G:"button",{isMobile:x}=I();let c;e[8]!==t||e[9]!==f||e[10]!==h?(c=g(re({variant:h,size:f}),t),e[8]=t,e[9]=f,e[10]=h,e[11]=c):c=e[11];let v;e[12]!==p||e[13]!==u||e[14]!==s||e[15]!==f||e[16]!==c?(v=o.jsx(p,{"data-slot":"sidebar-menu-button","data-sidebar":"menu-button","data-size":f,"data-active":u,className:c,...s}),e[12]=p,e[13]=u,e[14]=s,e[15]=f,e[16]=c,e[17]=v):v=e[17];const y=v;if(!r)return y;if(typeof r=="string"){let N;e[18]!==r?(N={children:r},e[18]=r,e[19]=N):N=e[19],r=N}let w;e[20]!==y?(w=o.jsx(D,{asChild:!0,children:y}),e[20]=y,e[21]=w):w=e[21];let j;e[22]!==x||e[23]!==r?(j=o.jsx(B,{side:"right",align:"center",hidden:x,...r}),e[22]=x,e[23]=r,e[24]=j):j=e[24];let S;return e[25]!==w||e[26]!==j?(S=o.jsxs(k,{children:[w,j]}),e[25]=w,e[26]=j,e[27]=S):S=e[27],S}export{xe as S,be as a,pe as b,te as c,Y as d,K as e,Ce as f,$e as g,Ne as h,Se as i,ye as j,je as k,we as l,me as m,ge as n,ve as o,ee as p,se as q,he as r,I as u};
@@ -1 +1 @@
1
- import{e as n,c,j as i}from"./index-CM1D3IOd.js";function m(o){const e=n.c(8);let s,t;e[0]!==o?({className:s,...t}=o,e[0]=o,e[1]=s,e[2]=t):(s=e[1],t=e[2]);let l;e[3]!==s?(l=c("bg-accent animate-pulse rounded-md",s),e[3]=s,e[4]=l):l=e[4];let a;return e[5]!==t||e[6]!==l?(a=i.jsx("div",{"data-slot":"skeleton",className:l,...t}),e[5]=t,e[6]=l,e[7]=a):a=e[7],a}export{m as S};
1
+ import{e as n,c,j as i}from"./index-C_etCvW6.js";function m(o){const e=n.c(8);let s,t;e[0]!==o?({className:s,...t}=o,e[0]=o,e[1]=s,e[2]=t):(s=e[1],t=e[2]);let l;e[3]!==s?(l=c("bg-accent animate-pulse rounded-md",s),e[3]=s,e[4]=l):l=e[4];let a;return e[5]!==t||e[6]!==l?(a=i.jsx("div",{"data-slot":"skeleton",className:l,...t}),e[5]=t,e[6]=l,e[7]=a):a=e[7],a}export{m as S};
@@ -1,4 +1,4 @@
1
- import{r as c,ba as I,az as Ne}from"./index-CM1D3IOd.js";function Nn(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return c.useMemo(()=>r=>{t.forEach(o=>o(r))},t)}const rt=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function we(e){const t=Object.prototype.toString.call(e);return t==="[object Window]"||t==="[object global]"}function yt(e){return"nodeType"in e}function z(e){var t,n;return e?we(e)?e:yt(e)&&(t=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?t:window:window}function wt(e){const{Document:t}=z(e);return e instanceof t}function Fe(e){return we(e)?!1:e instanceof z(e).HTMLElement}function Ht(e){return e instanceof z(e).SVGElement}function xe(e){return e?we(e)?e.document:yt(e)?wt(e)?e:Fe(e)||Ht(e)?e.ownerDocument:document:document:document}const V=rt?c.useLayoutEffect:c.useEffect;function ot(e){const t=c.useRef(e);return V(()=>{t.current=e}),c.useCallback(function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return t.current==null?void 0:t.current(...r)},[])}function Tn(){const e=c.useRef(null),t=c.useCallback((r,o)=>{e.current=setInterval(r,o)},[]),n=c.useCallback(()=>{e.current!==null&&(clearInterval(e.current),e.current=null)},[]);return[t,n]}function Pe(e,t){t===void 0&&(t=[e]);const n=c.useRef(e);return V(()=>{n.current!==e&&(n.current=e)},t),n}function $e(e,t){const n=c.useRef();return c.useMemo(()=>{const r=e(n.current);return n.current=r,r},[...t])}function _e(e){const t=ot(e),n=c.useRef(null),r=c.useCallback(o=>{o!==n.current&&t?.(o,n.current),n.current=o},[]);return[n,r]}function Qe(e){const t=c.useRef();return c.useEffect(()=>{t.current=e},[e]),t.current}let ft={};function Xe(e,t){return c.useMemo(()=>{if(t)return t;const n=ft[e]==null?0:ft[e]+1;return ft[e]=n,e+"-"+n},[e,t])}function Vt(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return r.reduce((i,s)=>{const a=Object.entries(s);for(const[l,u]of a){const f=i[l];f!=null&&(i[l]=f+e*u)}return i},{...t})}}const ye=Vt(1),ze=Vt(-1);function Ln(e){return"clientX"in e&&"clientY"in e}function it(e){if(!e)return!1;const{KeyboardEvent:t}=z(e.target);return t&&e instanceof t}function kn(e){if(!e)return!1;const{TouchEvent:t}=z(e.target);return t&&e instanceof t}function Ze(e){if(kn(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}else if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return Ln(e)?{x:e.clientX,y:e.clientY}:null}const fe=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:n}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:n}=e;return"scaleX("+t+") scaleY("+n+")"}},Transform:{toString(e){if(e)return[fe.Translate.toString(e),fe.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:n,easing:r}=e;return t+" "+n+"ms "+r}}}),Tt="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function Pn(e){return e.matches(Tt)?e:e.querySelector(Tt)}const zn={display:"none"};function Bn(e){let{id:t,value:n}=e;return I.createElement("div",{id:t,style:zn},n)}function Fn(e){let{id:t,announcement:n,ariaLiveType:r="assertive"}=e;const o={position:"fixed",top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"};return I.createElement("div",{id:t,style:o,role:"status","aria-live":r,"aria-atomic":!0},n)}function $n(){const[e,t]=c.useState("");return{announce:c.useCallback(r=>{r!=null&&t(r)},[]),announcement:e}}const qt=c.createContext(null);function Xn(e){const t=c.useContext(qt);c.useEffect(()=>{if(!t)throw new Error("useDndMonitor must be used within a children of <DndContext>");return t(e)},[e,t])}function jn(){const[e]=c.useState(()=>new Set),t=c.useCallback(r=>(e.add(r),()=>e.delete(r)),[e]);return[c.useCallback(r=>{let{type:o,event:i}=r;e.forEach(s=>{var a;return(a=s[o])==null?void 0:a.call(s,i)})},[e]),t]}const Yn={draggable:`
1
+ import{r as c,ba as I,az as Ne}from"./index-C_etCvW6.js";function Nn(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return c.useMemo(()=>r=>{t.forEach(o=>o(r))},t)}const rt=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function we(e){const t=Object.prototype.toString.call(e);return t==="[object Window]"||t==="[object global]"}function yt(e){return"nodeType"in e}function z(e){var t,n;return e?we(e)?e:yt(e)&&(t=(n=e.ownerDocument)==null?void 0:n.defaultView)!=null?t:window:window}function wt(e){const{Document:t}=z(e);return e instanceof t}function Fe(e){return we(e)?!1:e instanceof z(e).HTMLElement}function Ht(e){return e instanceof z(e).SVGElement}function xe(e){return e?we(e)?e.document:yt(e)?wt(e)?e:Fe(e)||Ht(e)?e.ownerDocument:document:document:document}const V=rt?c.useLayoutEffect:c.useEffect;function ot(e){const t=c.useRef(e);return V(()=>{t.current=e}),c.useCallback(function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return t.current==null?void 0:t.current(...r)},[])}function Tn(){const e=c.useRef(null),t=c.useCallback((r,o)=>{e.current=setInterval(r,o)},[]),n=c.useCallback(()=>{e.current!==null&&(clearInterval(e.current),e.current=null)},[]);return[t,n]}function Pe(e,t){t===void 0&&(t=[e]);const n=c.useRef(e);return V(()=>{n.current!==e&&(n.current=e)},t),n}function $e(e,t){const n=c.useRef();return c.useMemo(()=>{const r=e(n.current);return n.current=r,r},[...t])}function _e(e){const t=ot(e),n=c.useRef(null),r=c.useCallback(o=>{o!==n.current&&t?.(o,n.current),n.current=o},[]);return[n,r]}function Qe(e){const t=c.useRef();return c.useEffect(()=>{t.current=e},[e]),t.current}let ft={};function Xe(e,t){return c.useMemo(()=>{if(t)return t;const n=ft[e]==null?0:ft[e]+1;return ft[e]=n,e+"-"+n},[e,t])}function Vt(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return r.reduce((i,s)=>{const a=Object.entries(s);for(const[l,u]of a){const f=i[l];f!=null&&(i[l]=f+e*u)}return i},{...t})}}const ye=Vt(1),ze=Vt(-1);function Ln(e){return"clientX"in e&&"clientY"in e}function it(e){if(!e)return!1;const{KeyboardEvent:t}=z(e.target);return t&&e instanceof t}function kn(e){if(!e)return!1;const{TouchEvent:t}=z(e.target);return t&&e instanceof t}function Ze(e){if(kn(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}else if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return Ln(e)?{x:e.clientX,y:e.clientY}:null}const fe=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:n}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:n}=e;return"scaleX("+t+") scaleY("+n+")"}},Transform:{toString(e){if(e)return[fe.Translate.toString(e),fe.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:n,easing:r}=e;return t+" "+n+"ms "+r}}}),Tt="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function Pn(e){return e.matches(Tt)?e:e.querySelector(Tt)}const zn={display:"none"};function Bn(e){let{id:t,value:n}=e;return I.createElement("div",{id:t,style:zn},n)}function Fn(e){let{id:t,announcement:n,ariaLiveType:r="assertive"}=e;const o={position:"fixed",top:0,left:0,width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"};return I.createElement("div",{id:t,style:o,role:"status","aria-live":r,"aria-atomic":!0},n)}function $n(){const[e,t]=c.useState("");return{announce:c.useCallback(r=>{r!=null&&t(r)},[]),announcement:e}}const qt=c.createContext(null);function Xn(e){const t=c.useContext(qt);c.useEffect(()=>{if(!t)throw new Error("useDndMonitor must be used within a children of <DndContext>");return t(e)},[e,t])}function jn(){const[e]=c.useState(()=>new Set),t=c.useCallback(r=>(e.add(r),()=>e.delete(r)),[e]);return[c.useCallback(r=>{let{type:o,event:i}=r;e.forEach(s=>{var a;return(a=s[o])==null?void 0:a.call(s,i)})},[e]),t]}const Yn={draggable:`
2
2
  To pick up a draggable item, press the space bar.
3
3
  While dragging, use the arrow keys to move the item.
4
4
  Press space again to drop the item in its new position, or press escape to cancel.
@@ -1 +1 @@
1
- import{e as C,c as d,b0 as u,j as l}from"./index-CM1D3IOd.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{e as C,c as d,b0 as u,j as l}from"./index-C_etCvW6.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{q as N,r as j,j as e,B as p,t as S,o as c,e as b}from"./index-CM1D3IOd.js";import{D as k}from"./domain-settings-BnZTuy7Y.js";import{P as f}from"./index-Dr77wSbz.js";import{I as l}from"./input-DrYpnRWV.js";import{S as z}from"./switch-BOO2ukng.js";import{a as P,b as R,c as A,d as T}from"./use-org-sso-BHhjzT3n.js";import{d as F,S as y,a as C,b as a,c as O}from"./settings-section-CHdjpjU7.js";import{s as L}from"./Trash01-Bdgng8Ny.js";import"./unwrap-tool-result-BYXdCQMg.js";import"./constants-BwYc8BqM.js";import"./sidebar-DapD5BLH.js";import"./LayoutLeft-BtnBeX4Q.js";import"./tooltip-Cc8Oz_Tb.js";import"./X-BpMfki2j.js";import"./card-CzmU6DPx.js";import"./ArrowUpRight-CuD8Ec0Q.js";function q(){const{org:t}=N(),{data:r,isLoading:E}=P(t.id,t.slug),x=R(t.id,t.slug),h=A(t.id,t.slug),v=T(t.id,t.slug),[s,d]=j.useState({issuer:"",clientId:"",clientSecret:"",discoveryEndpoint:"",domain:"",scopes:"openid email profile"}),[m,g]=j.useState(!1),u=r?.configured&&r.config,o=r?.config,I=()=>{o&&d({issuer:o.issuer,clientId:o.clientId,clientSecret:"",discoveryEndpoint:o.discoveryEndpoint??"",domain:o.domain,scopes:o.scopes.join(" ")}),g(!0)},w=async()=>{if(!s.issuer||!s.clientId||!s.domain){c.error("Issuer, Client ID, and Domain are required");return}if(!u&&!s.clientSecret){c.error("Client Secret is required for initial setup");return}try{await x.mutateAsync({issuer:s.issuer,clientId:s.clientId,clientSecret:s.clientSecret,discoveryEndpoint:s.discoveryEndpoint||void 0,scopes:s.scopes.split(/\s+/).filter(Boolean),domain:s.domain,enforced:o?.enforced??!1}),S(u?"sso_config_updated":"sso_configured",{organization_id:t.id,email_domain:s.domain}),c.success("SSO configuration saved"),g(!1)}catch(i){c.error(i instanceof Error?i.message:"Failed to save SSO config")}},_=async()=>{if(confirm("Are you sure you want to remove SSO configuration?"))try{await h.mutateAsync(),S("sso_config_removed",{organization_id:t.id}),c.success("SSO configuration removed"),g(!1)}catch{c.error("Failed to remove SSO config")}},D=async i=>{try{await v.mutateAsync(i),S("sso_enforcement_toggled",{organization_id:t.id,enforced:i}),c.success(i?"SSO enforcement enabled":"SSO enforcement disabled")}catch{c.error("Failed to toggle SSO enforcement")}};return e.jsx(f,{children:e.jsx(f.Content,{children:e.jsx(f.Body,{children:e.jsxs(F,{children:[e.jsx(f.Title,{children:"Security"}),e.jsx(k,{}),E?e.jsx("div",{className:"text-sm text-muted-foreground",children:"Loading..."}):e.jsxs(e.Fragment,{children:[u&&!m&&e.jsx(y,{title:"Single Sign-On",children:e.jsxs(C,{children:[e.jsx(a,{title:"Provider",action:e.jsx("span",{className:"font-medium",children:o.issuer})}),e.jsx(a,{title:"Client ID",action:e.jsx("span",{className:"font-mono text-xs",children:o.clientId})}),e.jsx(a,{title:"Domain",action:e.jsx("span",{className:"font-medium",children:o.domain})}),e.jsx(a,{title:"Scopes",action:e.jsx("span",{className:"font-mono text-xs",children:o.scopes.join(" ")})}),e.jsx("div",{className:"h-px bg-border mx-5"}),e.jsx(a,{title:"Enforce SSO",description:"Require all members to authenticate via SSO",action:e.jsx(z,{checked:o.enforced,onCheckedChange:D,disabled:v.isPending})}),e.jsxs(O,{children:[e.jsxs(p,{variant:"ghost",size:"sm",onClick:_,disabled:h.isPending,className:"text-destructive hover:text-destructive mr-auto",children:[e.jsx(L,{size:14}),"Remove"]}),e.jsx(p,{variant:"outline",size:"sm",onClick:()=>{window.open(`/api/${t.slug}/sso/authorize`,"_blank")},children:"Test SSO"}),e.jsx(p,{variant:"outline",size:"sm",onClick:I,children:"Edit configuration"})]})]})}),(!u||m)&&e.jsx(y,{title:"Single Sign-On",children:e.jsxs(C,{children:[e.jsx(a,{title:"Issuer URL",description:"The OIDC issuer URL of your identity provider.",action:e.jsx(l,{id:"sso-issuer",placeholder:"https://login.microsoftonline.com/{tenant}/v2.0",value:s.issuer,onChange:i=>d(n=>({...n,issuer:i.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:"Client ID",action:e.jsx(l,{id:"sso-client-id",placeholder:"your-client-id",value:s.clientId,onChange:i=>d(n=>({...n,clientId:i.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:"Client Secret",description:m&&u?"Leave empty to keep current":void 0,action:e.jsx(l,{id:"sso-client-secret",type:"password",placeholder:"your-client-secret",value:s.clientSecret,onChange:i=>d(n=>({...n,clientSecret:i.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:"Email Domain",description:"The email domain this SSO provider covers.",action:e.jsx(l,{id:"sso-domain",placeholder:"company.com",value:s.domain,onChange:i=>d(n=>({...n,domain:i.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:"Scopes",action:e.jsx(l,{id:"sso-scopes",placeholder:"openid email profile",value:s.scopes,onChange:i=>d(n=>({...n,scopes:i.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:"Discovery Endpoint",description:"Optional — auto-detected from issuer if omitted.",action:e.jsx(l,{id:"sso-discovery",placeholder:"Auto-detected from issuer",value:s.discoveryEndpoint,onChange:i=>d(n=>({...n,discoveryEndpoint:i.target.value})),className:"w-[280px]"})}),e.jsxs(O,{children:[m&&e.jsx(p,{variant:"outline",size:"sm",onClick:()=>g(!1),children:"Cancel"}),e.jsx(p,{onClick:w,disabled:x.isPending,size:"sm",children:x.isPending?"Saving...":m?"Update":"Configure SSO"})]})]})})]})]})})})})}function se(){const t=b.c(1);let r;return t[0]===Symbol.for("react.memo_cache_sentinel")?(r=e.jsx(q,{}),t[0]=r):r=t[0],r}export{se as default};
1
+ import{q as N,r as j,j as e,B as p,t as S,o as c,e as b}from"./index-C_etCvW6.js";import{D as k}from"./domain-settings-CAp7ZsSN.js";import{P as f}from"./index-C7pSmjIO.js";import{I as l}from"./input-CGbgb-E-.js";import{S as z}from"./switch-khv0BLvL.js";import{a as P,b as R,c as A,d as T}from"./use-org-sso-T1wSzyZP.js";import{d as F,S as y,a as C,b as a,c as O}from"./settings-section-DRZOyjZN.js";import{s as L}from"./Trash01-CUZkoYoW.js";import"./unwrap-tool-result-BYXdCQMg.js";import"./constants-oggaZSfP.js";import"./sidebar-BMGvDz3J.js";import"./LayoutLeft-_rPJ3Xdj.js";import"./tooltip-8OqGw7oG.js";import"./X-Coa3_vHC.js";import"./card-Cd_hFdRe.js";import"./ArrowUpRight-BngWaIVR.js";function q(){const{org:t}=N(),{data:r,isLoading:E}=P(t.id,t.slug),x=R(t.id,t.slug),h=A(t.id,t.slug),v=T(t.id,t.slug),[s,d]=j.useState({issuer:"",clientId:"",clientSecret:"",discoveryEndpoint:"",domain:"",scopes:"openid email profile"}),[m,g]=j.useState(!1),u=r?.configured&&r.config,o=r?.config,I=()=>{o&&d({issuer:o.issuer,clientId:o.clientId,clientSecret:"",discoveryEndpoint:o.discoveryEndpoint??"",domain:o.domain,scopes:o.scopes.join(" ")}),g(!0)},w=async()=>{if(!s.issuer||!s.clientId||!s.domain){c.error("Issuer, Client ID, and Domain are required");return}if(!u&&!s.clientSecret){c.error("Client Secret is required for initial setup");return}try{await x.mutateAsync({issuer:s.issuer,clientId:s.clientId,clientSecret:s.clientSecret,discoveryEndpoint:s.discoveryEndpoint||void 0,scopes:s.scopes.split(/\s+/).filter(Boolean),domain:s.domain,enforced:o?.enforced??!1}),S(u?"sso_config_updated":"sso_configured",{organization_id:t.id,email_domain:s.domain}),c.success("SSO configuration saved"),g(!1)}catch(i){c.error(i instanceof Error?i.message:"Failed to save SSO config")}},_=async()=>{if(confirm("Are you sure you want to remove SSO configuration?"))try{await h.mutateAsync(),S("sso_config_removed",{organization_id:t.id}),c.success("SSO configuration removed"),g(!1)}catch{c.error("Failed to remove SSO config")}},D=async i=>{try{await v.mutateAsync(i),S("sso_enforcement_toggled",{organization_id:t.id,enforced:i}),c.success(i?"SSO enforcement enabled":"SSO enforcement disabled")}catch{c.error("Failed to toggle SSO enforcement")}};return e.jsx(f,{children:e.jsx(f.Content,{children:e.jsx(f.Body,{children:e.jsxs(F,{children:[e.jsx(f.Title,{children:"Security"}),e.jsx(k,{}),E?e.jsx("div",{className:"text-sm text-muted-foreground",children:"Loading..."}):e.jsxs(e.Fragment,{children:[u&&!m&&e.jsx(y,{title:"Single Sign-On",children:e.jsxs(C,{children:[e.jsx(a,{title:"Provider",action:e.jsx("span",{className:"font-medium",children:o.issuer})}),e.jsx(a,{title:"Client ID",action:e.jsx("span",{className:"font-mono text-xs",children:o.clientId})}),e.jsx(a,{title:"Domain",action:e.jsx("span",{className:"font-medium",children:o.domain})}),e.jsx(a,{title:"Scopes",action:e.jsx("span",{className:"font-mono text-xs",children:o.scopes.join(" ")})}),e.jsx("div",{className:"h-px bg-border mx-5"}),e.jsx(a,{title:"Enforce SSO",description:"Require all members to authenticate via SSO",action:e.jsx(z,{checked:o.enforced,onCheckedChange:D,disabled:v.isPending})}),e.jsxs(O,{children:[e.jsxs(p,{variant:"ghost",size:"sm",onClick:_,disabled:h.isPending,className:"text-destructive hover:text-destructive mr-auto",children:[e.jsx(L,{size:14}),"Remove"]}),e.jsx(p,{variant:"outline",size:"sm",onClick:()=>{window.open(`/api/${t.slug}/sso/authorize`,"_blank")},children:"Test SSO"}),e.jsx(p,{variant:"outline",size:"sm",onClick:I,children:"Edit configuration"})]})]})}),(!u||m)&&e.jsx(y,{title:"Single Sign-On",children:e.jsxs(C,{children:[e.jsx(a,{title:"Issuer URL",description:"The OIDC issuer URL of your identity provider.",action:e.jsx(l,{id:"sso-issuer",placeholder:"https://login.microsoftonline.com/{tenant}/v2.0",value:s.issuer,onChange:i=>d(n=>({...n,issuer:i.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:"Client ID",action:e.jsx(l,{id:"sso-client-id",placeholder:"your-client-id",value:s.clientId,onChange:i=>d(n=>({...n,clientId:i.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:"Client Secret",description:m&&u?"Leave empty to keep current":void 0,action:e.jsx(l,{id:"sso-client-secret",type:"password",placeholder:"your-client-secret",value:s.clientSecret,onChange:i=>d(n=>({...n,clientSecret:i.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:"Email Domain",description:"The email domain this SSO provider covers.",action:e.jsx(l,{id:"sso-domain",placeholder:"company.com",value:s.domain,onChange:i=>d(n=>({...n,domain:i.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:"Scopes",action:e.jsx(l,{id:"sso-scopes",placeholder:"openid email profile",value:s.scopes,onChange:i=>d(n=>({...n,scopes:i.target.value})),className:"w-[280px]"})}),e.jsx(a,{title:"Discovery Endpoint",description:"Optional — auto-detected from issuer if omitted.",action:e.jsx(l,{id:"sso-discovery",placeholder:"Auto-detected from issuer",value:s.discoveryEndpoint,onChange:i=>d(n=>({...n,discoveryEndpoint:i.target.value})),className:"w-[280px]"})}),e.jsxs(O,{children:[m&&e.jsx(p,{variant:"outline",size:"sm",onClick:()=>g(!1),children:"Cancel"}),e.jsx(p,{onClick:w,disabled:x.isPending,size:"sm",children:x.isPending?"Saving...":m?"Update":"Configure SSO"})]})]})})]})]})})})})}function se(){const t=b.c(1);let r;return t[0]===Symbol.for("react.memo_cache_sentinel")?(r=e.jsx(q,{}),t[0]=r):r=t[0],r}export{se as default};
@@ -1 +1 @@
1
- import{e as D,j as s,E as le,r as K,q as ae,D as ce,f as de,g as me,B as Y,t as te,K as fe,a as ge,o as ie}from"./index-CM1D3IOd.js";import{i as ue}from"./AlertCircle-BT4KzWnI.js";import{i as pe}from"./ChevronRight-DzTdh7eY.js";import{s as xe}from"./Plus-CuU_Vn1V.js";import{s as he}from"./Trash01-Bdgng8Ny.js";import{I as X}from"./input-DrYpnRWV.js";import{S as ne}from"./switch-BOO2ukng.js";import{S as ye}from"./skeleton-BLQ-Z2or.js";import{A as oe}from"./avatar-DeKO2t6e.js";import{P as je,a as Ce,b as Se}from"./popover-C9ON0IYH.js";import{b as re}from"./use-connection-BA0O34v3.js";import{W as Z}from"./constants-BwYc8BqM.js";import{P as G}from"./index-Dr77wSbz.js";import{u as ve}from"./use-registry-connections-CaOaYe6E.js";import{g as _e,h as be}from"./use-organization-settings-Kf9UVBw8.js";import{d as Pe,b as I,S as ee,a as Q}from"./settings-section-CHdjpjU7.js";import"./User01-DvR2FzxS.js";import"./use-collections-CW9RG6h4.js";import"./sidebar-DapD5BLH.js";import"./LayoutLeft-BtnBeX4Q.js";import"./tooltip-Cc8Oz_Tb.js";import"./X-BpMfki2j.js";import"./card-CzmU6DPx.js";import"./ArrowUpRight-CuD8Ec0Q.js";function Re(t){const e=D.c(3),{error:n}=t;let m;e[0]===Symbol.for("react.memo_cache_sentinel")?(m=s.jsx(ue,{size:16}),e[0]=m):m=e[0];let o;return e[1]!==n.message?(o=s.jsxs("div",{className:"p-4 rounded-md bg-destructive/10 text-destructive flex items-center gap-2",children:[m,s.jsxs("span",{className:"text-sm font-medium",children:["Failed to load store settings: ",n.message]})]}),e[1]=n.message,e[2]=o):o=e[2],o}function ke(t){const e=D.c(36),{onCancel:n,onSuccess:m}=t,o=re(),[r,j]=K.useState(""),[a,S]=K.useState(""),[x,v]=K.useState("");let h;e[0]!==o||e[1]!==r||e[2]!==x||e[3]!==a?(h=async()=>(await o.create.mutateAsync({title:r||"Private Registry",description:"Private MCP registry",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]=x,e[3]=a,e[4]=h):h=e[4];let f;e[5]!==m?(f=C=>{te("store_private_registry_added",{connection_id:C}),ie.success("Private registry added"),m(C)},e[5]=m,e[6]=f):f=e[6];let y;e[7]!==h||e[8]!==f?(y={mutationFn:h,onSuccess:f,onError:we},e[7]=h,e[8]=f,e[9]=y):y=e[9];const{mutate:c,isPending:d}=ge(y);let g;e[10]===Symbol.for("react.memo_cache_sentinel")?(g=C=>j(C.target.value),e[10]=g):g=e[10];let u;e[11]!==r?(u=s.jsx(I,{title:"Name",action:s.jsx(X,{placeholder:"e.g. Acme Corp Registry",value:r,onChange:g,className:"w-[280px]"})}),e[11]=r,e[12]=u):u=e[12];let p;e[13]===Symbol.for("react.memo_cache_sentinel")?(p=C=>S(C.target.value),e[13]=p):p=e[13];let l;e[14]!==a?(l=s.jsx(I,{title:"Registry URL",action:s.jsx(X,{placeholder:"https://registry.example.com/mcp",value:a,onChange:p,className:"w-[280px]"})}),e[14]=a,e[15]=l):l=e[15];let _;e[16]===Symbol.for("react.memo_cache_sentinel")?(_=C=>v(C.target.value),e[16]=_):_=e[16];let b;e[17]!==x?(b=s.jsx(I,{title:"Auth Token",description:"Optional",action:s.jsx(X,{type:"password",placeholder:"Bearer token...",value:x,onChange:_,className:"w-[280px]"})}),e[17]=x,e[18]=b):b=e[18];let k;e[19]!==d||e[20]!==n?(k=s.jsx(Y,{variant:"ghost",size:"sm",onClick:n,disabled:d,children:"Cancel"}),e[19]=d,e[20]=n,e[21]=k):k=e[21];let N;e[22]!==c?(N=()=>c(),e[22]=c,e[23]=N):N=e[23];const O=!a||d,B=d?"Adding...":"Add Registry";let A;e[24]!==N||e[25]!==O||e[26]!==B?(A=s.jsx(Y,{size:"sm",onClick:N,disabled:O,children:B}),e[24]=N,e[25]=O,e[26]=B,e[27]=A):A=e[27];let R;e[28]!==k||e[29]!==A?(R=s.jsxs("div",{className:"px-5 py-4 flex justify-end gap-2",children:[k,A]}),e[28]=k,e[29]=A,e[30]=R):R=e[30];let P;return e[31]!==R||e[32]!==u||e[33]!==l||e[34]!==b?(P=s.jsxs(Q,{children:[u,l,b,R]}),e[31]=R,e[32]=u,e[33]=l,e[34]=b,e[35]=P):P=e[35],P}function we(t){ie.error(`Failed to add registry: ${t.message}`)}function L(t){const e=D.c(29),{name:n,description:m,icon:o,enabled:r,onToggle:j,onDelete:a,href:S}=t,x=de();let v;e[0]===Symbol.for("react.memo_cache_sentinel")?(v={from:"/shell/$org"},e[0]=v):v=e[0];const{org:h}=me(v);let f;e[1]!==r||e[2]!==S||e[3]!==x||e[4]!==j||e[5]!==h?(f=()=>{S?x({to:S,params:{org:h}}):j(!r)},e[1]=r,e[2]=S,e[3]=x,e[4]=j,e[5]=h,e[6]=f):f=e[6];const y=f;let c;e[7]!==o||e[8]!==n?(c=o?s.jsx("img",{src:o,alt:n,className:"size-8 rounded-md object-contain"}):s.jsx(oe,{fallback:n.charAt(0),className:"size-8 bg-primary/10 text-primary"}),e[7]=o,e[8]=n,e[9]=c):c=e[9];let d;e[10]!==a?(d=a&&s.jsxs(je,{children:[s.jsx(Ce,{asChild:!0,children:s.jsx(Y,{variant:"ghost",size:"icon",className:"h-6 w-6 text-muted-foreground hover:text-destructive",onClick:Ae,children:s.jsx(he,{size:14})})}),s.jsx(Se,{className:"w-auto p-2",align:"end",children:s.jsxs("div",{className:"flex flex-col gap-2",children:[s.jsx("p",{className:"text-xs font-medium",children:"Remove this registry?"}),s.jsx(Y,{variant:"destructive",size:"xs",onClick:b=>{b.stopPropagation(),a()},children:"Remove"})]})})]}),e[10]=a,e[11]=d):d=e[11];let g;e[12]!==j?(g=b=>j(b),e[12]=j,e[13]=g):g=e[13];let u;e[14]!==r||e[15]!==g?(u=s.jsx(ne,{checked:r,onClick:Ne,onCheckedChange:g}),e[14]=r,e[15]=g,e[16]=u):u=e[16];let p;e[17]!==S?(p=S&&s.jsx(pe,{size:14,className:"text-muted-foreground"}),e[17]=S,e[18]=p):p=e[18];let l;e[19]!==d||e[20]!==u||e[21]!==p?(l=s.jsxs("div",{className:"flex items-center gap-2",children:[d,u,p]}),e[19]=d,e[20]=u,e[21]=p,e[22]=l):l=e[22];let _;return e[23]!==m||e[24]!==y||e[25]!==n||e[26]!==c||e[27]!==l?(_=s.jsx(I,{title:n,description:m,onClick:y,icon:c,action:l}),e[23]=m,e[24]=y,e[25]=n,e[26]=c,e[27]=l,e[28]=_):_=e[28],_}function Ne(t){return t.stopPropagation()}function Ae(t){return t.stopPropagation()}function Me(){const t=D.c(59),{org:e}=ae(),n=ve(),m=re(),o=_e(),{mutateAsync:r}=be(),j=ce(),[a,S]=K.useState(!1);let x,v,h,f,y,c;if(t[0]!==m||t[1]!==e.id||t[2]!==j||t[3]!==o||t[4]!==n||t[5]!==a||t[6]!==r){const p=Z.REGISTRY(e.id),l=i=>{if(!o)return i===p;const w=o.registries[i];return w?w.enabled:i===p},_=Z.COMMUNITY_REGISTRY(e.id),b=n.find(i=>i.id===p),k=n.find(i=>i.id===_||i.id==="community-registry"),N=k?.id??_,O=Z.SELF(e.id),B=new Set([p,_,"community-registry",O]),A=n.filter(i=>!B.has(i.id));let R;t[13]!==o||t[14]!==r?(R=async(i,w)=>{te("store_registry_toggled",{connection_id:i,enabled:w});const se=o??{registries:{},blockedMcps:[]};await r({...se,registries:{...se.registries,[i]:{enabled:w}}})},t[13]=o,t[14]=r,t[15]=R):R=t[15];const P=R;let C;t[16]!==m||t[17]!==e.id||t[18]!==j?(C=async i=>{te("store_private_registry_removed",{connection_id:i}),await m.delete.mutateAsync(i),j.invalidateQueries({queryKey:fe.organizationSettings(e.id)})},t[16]=m,t[17]=e.id,t[18]=j,t[19]=C):C=t[19];const W=C;let U;t[20]!==o||t[21]!==r?(U=async i=>{S(!1);const w=o??{registries:{},blockedMcps:[]};await r({...w,registries:{...w.registries,[i]:{enabled:!0}}})},t[20]=o,t[21]=r,t[22]=U):U=t[22];const H=U,J=b?s.jsx(L,{name:"Deco Store",description:"Official deco MCP registry with curated integrations",icon:b.icon,enabled:l(p),onToggle:i=>P(p,i)}):s.jsx(I,{title:"Deco Store",description:"Connection not found — will be created automatically."});t[23]!==J?(y=s.jsx(ee,{title:"Deco Store",children:s.jsx(Q,{children:J})}),t[23]=J,t[24]=y):y=t[24];let M;t[25]!==a?(M=a?void 0:s.jsxs(Y,{variant:"outline",size:"sm",onClick:()=>S(!0),children:[s.jsx(xe,{size:14}),"Add registry"]}),t[25]=a,t[26]=M):M=t[26];let T;t[27]!==H||t[28]!==a?(T=a&&s.jsx(ke,{onCancel:()=>S(!1),onSuccess:H}),t[27]=H,t[28]=a,t[29]=T):T=t[29];let z;t[30]!==l?(z=l("self"),t[30]=l,t[31]=z):z=t[31];let E;t[32]!==P?(E=i=>P("self",i),t[32]=P,t[33]=E):E=t[33];let $;t[34]!==z||t[35]!==E?($=s.jsx(L,{name:"Private Registry",description:"Your organization's private MCP registry",enabled:z,onToggle:E,href:"/$org/settings/store/registry"}),t[34]=z,t[35]=E,t[36]=$):$=t[36];let q;t[37]!==W||t[38]!==P||t[39]!==l?(q=i=>s.jsx(L,{name:i.title,description:i.description??"Private MCP registry",icon:i.icon,enabled:l(i.id),onToggle:w=>P(i.id,w),onDelete:()=>W(i.id)},i.id),t[37]=W,t[38]=P,t[39]=l,t[40]=q):q=t[40];const V=A.map(q);let F;t[41]!==$||t[42]!==V?(F=s.jsxs(Q,{children:[$,V]}),t[41]=$,t[42]=V,t[43]=F):F=t[43],t[44]!==F||t[45]!==M||t[46]!==T?(c=s.jsxs(ee,{title:"Private Registries",actions:M,children:[T,F]}),t[44]=F,t[45]=M,t[46]=T,t[47]=c):c=t[47],v=ee,f="Community",x=Q,h=k?s.jsx(L,{name:"MCP Registry",description:"Community MCP registry with thousands of handy MCPs",icon:k.icon,enabled:l(N),onToggle:i=>P(N,i)}):s.jsx(I,{title:"MCP Registry",description:"Community MCP registry — not yet added",icon:s.jsx(oe,{fallback:"M",className:"size-8 bg-primary/10 text-primary"}),action:s.jsx(ne,{checked:!1,disabled:!0,onCheckedChange:Te})}),t[0]=m,t[1]=e.id,t[2]=j,t[3]=o,t[4]=n,t[5]=a,t[6]=r,t[7]=x,t[8]=v,t[9]=h,t[10]=f,t[11]=y,t[12]=c}else x=t[7],v=t[8],h=t[9],f=t[10],y=t[11],c=t[12];let d;t[48]!==x||t[49]!==h?(d=s.jsx(x,{children:h}),t[48]=x,t[49]=h,t[50]=d):d=t[50];let g;t[51]!==v||t[52]!==f||t[53]!==d?(g=s.jsx(v,{title:f,children:d}),t[51]=v,t[52]=f,t[53]=d,t[54]=g):g=t[54];let u;return t[55]!==y||t[56]!==c||t[57]!==g?(u=s.jsxs(s.Fragment,{children:[y,c,g]}),t[55]=y,t[56]=c,t[57]=g,t[58]=u):u=t[58],u}function Te(){}function ze(){const t=D.c(2);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(ye,{className:"h-64 w-full"}),t[0]=e):e=t[0];let n;return t[1]===Symbol.for("react.memo_cache_sentinel")?(n=s.jsx(le,{fallback:Ee,children:s.jsx(K.Suspense,{fallback:e,children:s.jsx(G,{children:s.jsx(G.Content,{children:s.jsx(G.Body,{children:s.jsxs(Pe,{children:[s.jsx(G.Title,{children:"Store"}),s.jsx(Me,{})]})})})})})}),t[1]=n):n=t[1],n}function Ee(t){const{error:e}=t;return s.jsx(Re,{error:e??new Error("Failed to load store settings")})}function ot(){const t=D.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(ze,{}),t[0]=e):e=t[0],e}export{ot as default};
1
+ import{e as D,j as s,E as le,r as K,q as ae,D as ce,f as de,g as me,B as Y,t as te,K as fe,a as ge,o as ie}from"./index-C_etCvW6.js";import{i as ue}from"./AlertCircle-B5W8e_5w.js";import{i as pe}from"./ChevronRight-C956u55G.js";import{s as xe}from"./Plus-CpQnzuG3.js";import{s as he}from"./Trash01-CUZkoYoW.js";import{I as X}from"./input-CGbgb-E-.js";import{S as ne}from"./switch-khv0BLvL.js";import{S as ye}from"./skeleton-BNkut-Qo.js";import{A as oe}from"./avatar-vA2R8qEK.js";import{P as je,a as Ce,b as Se}from"./popover-xTN6BEZL.js";import{b as re}from"./use-connection--tE4CSIP.js";import{W as Z}from"./constants-oggaZSfP.js";import{P as G}from"./index-C7pSmjIO.js";import{u as ve}from"./use-registry-connections-BZm5h5va.js";import{g as _e,h as be}from"./use-organization-settings-CpDAWMUD.js";import{d as Pe,b as I,S as ee,a as Q}from"./settings-section-DRZOyjZN.js";import"./User01-CtOhLzXW.js";import"./use-collections-BsrK_euH.js";import"./sidebar-BMGvDz3J.js";import"./LayoutLeft-_rPJ3Xdj.js";import"./tooltip-8OqGw7oG.js";import"./X-Coa3_vHC.js";import"./card-Cd_hFdRe.js";import"./ArrowUpRight-BngWaIVR.js";function Re(t){const e=D.c(3),{error:n}=t;let m;e[0]===Symbol.for("react.memo_cache_sentinel")?(m=s.jsx(ue,{size:16}),e[0]=m):m=e[0];let o;return e[1]!==n.message?(o=s.jsxs("div",{className:"p-4 rounded-md bg-destructive/10 text-destructive flex items-center gap-2",children:[m,s.jsxs("span",{className:"text-sm font-medium",children:["Failed to load store settings: ",n.message]})]}),e[1]=n.message,e[2]=o):o=e[2],o}function ke(t){const e=D.c(36),{onCancel:n,onSuccess:m}=t,o=re(),[r,j]=K.useState(""),[a,S]=K.useState(""),[x,v]=K.useState("");let h;e[0]!==o||e[1]!==r||e[2]!==x||e[3]!==a?(h=async()=>(await o.create.mutateAsync({title:r||"Private Registry",description:"Private MCP registry",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]=x,e[3]=a,e[4]=h):h=e[4];let f;e[5]!==m?(f=C=>{te("store_private_registry_added",{connection_id:C}),ie.success("Private registry added"),m(C)},e[5]=m,e[6]=f):f=e[6];let y;e[7]!==h||e[8]!==f?(y={mutationFn:h,onSuccess:f,onError:we},e[7]=h,e[8]=f,e[9]=y):y=e[9];const{mutate:c,isPending:d}=ge(y);let g;e[10]===Symbol.for("react.memo_cache_sentinel")?(g=C=>j(C.target.value),e[10]=g):g=e[10];let u;e[11]!==r?(u=s.jsx(I,{title:"Name",action:s.jsx(X,{placeholder:"e.g. Acme Corp Registry",value:r,onChange:g,className:"w-[280px]"})}),e[11]=r,e[12]=u):u=e[12];let p;e[13]===Symbol.for("react.memo_cache_sentinel")?(p=C=>S(C.target.value),e[13]=p):p=e[13];let l;e[14]!==a?(l=s.jsx(I,{title:"Registry URL",action:s.jsx(X,{placeholder:"https://registry.example.com/mcp",value:a,onChange:p,className:"w-[280px]"})}),e[14]=a,e[15]=l):l=e[15];let _;e[16]===Symbol.for("react.memo_cache_sentinel")?(_=C=>v(C.target.value),e[16]=_):_=e[16];let b;e[17]!==x?(b=s.jsx(I,{title:"Auth Token",description:"Optional",action:s.jsx(X,{type:"password",placeholder:"Bearer token...",value:x,onChange:_,className:"w-[280px]"})}),e[17]=x,e[18]=b):b=e[18];let k;e[19]!==d||e[20]!==n?(k=s.jsx(Y,{variant:"ghost",size:"sm",onClick:n,disabled:d,children:"Cancel"}),e[19]=d,e[20]=n,e[21]=k):k=e[21];let N;e[22]!==c?(N=()=>c(),e[22]=c,e[23]=N):N=e[23];const O=!a||d,B=d?"Adding...":"Add Registry";let A;e[24]!==N||e[25]!==O||e[26]!==B?(A=s.jsx(Y,{size:"sm",onClick:N,disabled:O,children:B}),e[24]=N,e[25]=O,e[26]=B,e[27]=A):A=e[27];let R;e[28]!==k||e[29]!==A?(R=s.jsxs("div",{className:"px-5 py-4 flex justify-end gap-2",children:[k,A]}),e[28]=k,e[29]=A,e[30]=R):R=e[30];let P;return e[31]!==R||e[32]!==u||e[33]!==l||e[34]!==b?(P=s.jsxs(Q,{children:[u,l,b,R]}),e[31]=R,e[32]=u,e[33]=l,e[34]=b,e[35]=P):P=e[35],P}function we(t){ie.error(`Failed to add registry: ${t.message}`)}function L(t){const e=D.c(29),{name:n,description:m,icon:o,enabled:r,onToggle:j,onDelete:a,href:S}=t,x=de();let v;e[0]===Symbol.for("react.memo_cache_sentinel")?(v={from:"/shell/$org"},e[0]=v):v=e[0];const{org:h}=me(v);let f;e[1]!==r||e[2]!==S||e[3]!==x||e[4]!==j||e[5]!==h?(f=()=>{S?x({to:S,params:{org:h}}):j(!r)},e[1]=r,e[2]=S,e[3]=x,e[4]=j,e[5]=h,e[6]=f):f=e[6];const y=f;let c;e[7]!==o||e[8]!==n?(c=o?s.jsx("img",{src:o,alt:n,className:"size-8 rounded-md object-contain"}):s.jsx(oe,{fallback:n.charAt(0),className:"size-8 bg-primary/10 text-primary"}),e[7]=o,e[8]=n,e[9]=c):c=e[9];let d;e[10]!==a?(d=a&&s.jsxs(je,{children:[s.jsx(Ce,{asChild:!0,children:s.jsx(Y,{variant:"ghost",size:"icon",className:"h-6 w-6 text-muted-foreground hover:text-destructive",onClick:Ae,children:s.jsx(he,{size:14})})}),s.jsx(Se,{className:"w-auto p-2",align:"end",children:s.jsxs("div",{className:"flex flex-col gap-2",children:[s.jsx("p",{className:"text-xs font-medium",children:"Remove this registry?"}),s.jsx(Y,{variant:"destructive",size:"xs",onClick:b=>{b.stopPropagation(),a()},children:"Remove"})]})})]}),e[10]=a,e[11]=d):d=e[11];let g;e[12]!==j?(g=b=>j(b),e[12]=j,e[13]=g):g=e[13];let u;e[14]!==r||e[15]!==g?(u=s.jsx(ne,{checked:r,onClick:Ne,onCheckedChange:g}),e[14]=r,e[15]=g,e[16]=u):u=e[16];let p;e[17]!==S?(p=S&&s.jsx(pe,{size:14,className:"text-muted-foreground"}),e[17]=S,e[18]=p):p=e[18];let l;e[19]!==d||e[20]!==u||e[21]!==p?(l=s.jsxs("div",{className:"flex items-center gap-2",children:[d,u,p]}),e[19]=d,e[20]=u,e[21]=p,e[22]=l):l=e[22];let _;return e[23]!==m||e[24]!==y||e[25]!==n||e[26]!==c||e[27]!==l?(_=s.jsx(I,{title:n,description:m,onClick:y,icon:c,action:l}),e[23]=m,e[24]=y,e[25]=n,e[26]=c,e[27]=l,e[28]=_):_=e[28],_}function Ne(t){return t.stopPropagation()}function Ae(t){return t.stopPropagation()}function Me(){const t=D.c(59),{org:e}=ae(),n=ve(),m=re(),o=_e(),{mutateAsync:r}=be(),j=ce(),[a,S]=K.useState(!1);let x,v,h,f,y,c;if(t[0]!==m||t[1]!==e.id||t[2]!==j||t[3]!==o||t[4]!==n||t[5]!==a||t[6]!==r){const p=Z.REGISTRY(e.id),l=i=>{if(!o)return i===p;const w=o.registries[i];return w?w.enabled:i===p},_=Z.COMMUNITY_REGISTRY(e.id),b=n.find(i=>i.id===p),k=n.find(i=>i.id===_||i.id==="community-registry"),N=k?.id??_,O=Z.SELF(e.id),B=new Set([p,_,"community-registry",O]),A=n.filter(i=>!B.has(i.id));let R;t[13]!==o||t[14]!==r?(R=async(i,w)=>{te("store_registry_toggled",{connection_id:i,enabled:w});const se=o??{registries:{},blockedMcps:[]};await r({...se,registries:{...se.registries,[i]:{enabled:w}}})},t[13]=o,t[14]=r,t[15]=R):R=t[15];const P=R;let C;t[16]!==m||t[17]!==e.id||t[18]!==j?(C=async i=>{te("store_private_registry_removed",{connection_id:i}),await m.delete.mutateAsync(i),j.invalidateQueries({queryKey:fe.organizationSettings(e.id)})},t[16]=m,t[17]=e.id,t[18]=j,t[19]=C):C=t[19];const W=C;let U;t[20]!==o||t[21]!==r?(U=async i=>{S(!1);const w=o??{registries:{},blockedMcps:[]};await r({...w,registries:{...w.registries,[i]:{enabled:!0}}})},t[20]=o,t[21]=r,t[22]=U):U=t[22];const H=U,J=b?s.jsx(L,{name:"Deco Store",description:"Official deco MCP registry with curated integrations",icon:b.icon,enabled:l(p),onToggle:i=>P(p,i)}):s.jsx(I,{title:"Deco Store",description:"Connection not found — will be created automatically."});t[23]!==J?(y=s.jsx(ee,{title:"Deco Store",children:s.jsx(Q,{children:J})}),t[23]=J,t[24]=y):y=t[24];let M;t[25]!==a?(M=a?void 0:s.jsxs(Y,{variant:"outline",size:"sm",onClick:()=>S(!0),children:[s.jsx(xe,{size:14}),"Add registry"]}),t[25]=a,t[26]=M):M=t[26];let T;t[27]!==H||t[28]!==a?(T=a&&s.jsx(ke,{onCancel:()=>S(!1),onSuccess:H}),t[27]=H,t[28]=a,t[29]=T):T=t[29];let z;t[30]!==l?(z=l("self"),t[30]=l,t[31]=z):z=t[31];let E;t[32]!==P?(E=i=>P("self",i),t[32]=P,t[33]=E):E=t[33];let $;t[34]!==z||t[35]!==E?($=s.jsx(L,{name:"Private Registry",description:"Your organization's private MCP registry",enabled:z,onToggle:E,href:"/$org/settings/store/registry"}),t[34]=z,t[35]=E,t[36]=$):$=t[36];let q;t[37]!==W||t[38]!==P||t[39]!==l?(q=i=>s.jsx(L,{name:i.title,description:i.description??"Private MCP registry",icon:i.icon,enabled:l(i.id),onToggle:w=>P(i.id,w),onDelete:()=>W(i.id)},i.id),t[37]=W,t[38]=P,t[39]=l,t[40]=q):q=t[40];const V=A.map(q);let F;t[41]!==$||t[42]!==V?(F=s.jsxs(Q,{children:[$,V]}),t[41]=$,t[42]=V,t[43]=F):F=t[43],t[44]!==F||t[45]!==M||t[46]!==T?(c=s.jsxs(ee,{title:"Private Registries",actions:M,children:[T,F]}),t[44]=F,t[45]=M,t[46]=T,t[47]=c):c=t[47],v=ee,f="Community",x=Q,h=k?s.jsx(L,{name:"MCP Registry",description:"Community MCP registry with thousands of handy MCPs",icon:k.icon,enabled:l(N),onToggle:i=>P(N,i)}):s.jsx(I,{title:"MCP Registry",description:"Community MCP registry — not yet added",icon:s.jsx(oe,{fallback:"M",className:"size-8 bg-primary/10 text-primary"}),action:s.jsx(ne,{checked:!1,disabled:!0,onCheckedChange:Te})}),t[0]=m,t[1]=e.id,t[2]=j,t[3]=o,t[4]=n,t[5]=a,t[6]=r,t[7]=x,t[8]=v,t[9]=h,t[10]=f,t[11]=y,t[12]=c}else x=t[7],v=t[8],h=t[9],f=t[10],y=t[11],c=t[12];let d;t[48]!==x||t[49]!==h?(d=s.jsx(x,{children:h}),t[48]=x,t[49]=h,t[50]=d):d=t[50];let g;t[51]!==v||t[52]!==f||t[53]!==d?(g=s.jsx(v,{title:f,children:d}),t[51]=v,t[52]=f,t[53]=d,t[54]=g):g=t[54];let u;return t[55]!==y||t[56]!==c||t[57]!==g?(u=s.jsxs(s.Fragment,{children:[y,c,g]}),t[55]=y,t[56]=c,t[57]=g,t[58]=u):u=t[58],u}function Te(){}function ze(){const t=D.c(2);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(ye,{className:"h-64 w-full"}),t[0]=e):e=t[0];let n;return t[1]===Symbol.for("react.memo_cache_sentinel")?(n=s.jsx(le,{fallback:Ee,children:s.jsx(K.Suspense,{fallback:e,children:s.jsx(G,{children:s.jsx(G.Content,{children:s.jsx(G.Body,{children:s.jsxs(Pe,{children:[s.jsx(G.Title,{children:"Store"}),s.jsx(Me,{})]})})})})})}),t[1]=n):n=t[1],n}function Ee(t){const{error:e}=t;return s.jsx(Re,{error:e??new Error("Failed to load store settings")})}function ot(){const t=D.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(ze,{}),t[0]=e):e=t[0],e}export{ot as default};