decocms 2.181.2 → 2.181.3

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 (206) hide show
  1. package/dist/client/assets/{AlertCircle-Hpsw9_tf.js → AlertCircle-D2rRA9CS.js} +1 -1
  2. package/dist/client/assets/{ArrowLeft-U7OUoBhv.js → ArrowLeft-D4bkD9qi.js} +1 -1
  3. package/dist/client/assets/{ArrowUp-BrSLqvQo.js → ArrowUp-CpDF-NAu.js} +1 -1
  4. package/dist/client/assets/{Check-CVKUMJv3.js → Check-CecxQkQE.js} +1 -1
  5. package/dist/client/assets/{ChevronDown-Ds3IOx8p.js → ChevronDown-Cm9SuGtV.js} +1 -1
  6. package/dist/client/assets/{ChevronRight-CTHCKnjF.js → ChevronRight-2xVQHhsF.js} +1 -1
  7. package/dist/client/assets/{ChevronUp-DJbt-mXd.js → ChevronUp-B6bu9ZD3.js} +1 -1
  8. package/dist/client/assets/{Container-D4n2e11R.js → Container-sfWYtc36.js} +1 -1
  9. package/dist/client/assets/{Dataflow03-q5kzWw4s.js → Dataflow03-BcXlVxgR.js} +1 -1
  10. package/dist/client/assets/{Download01-BBRbjA11.js → Download01-DGSbxmSo.js} +1 -1
  11. package/dist/client/assets/{FolderClosed-CgbAGtho.js → FolderClosed-DlY-lqwP.js} +1 -1
  12. package/dist/client/assets/{Grid01-CbgVFQNg.js → Grid01-CLnEHof5.js} +1 -1
  13. package/dist/client/assets/{List-D35z7ORx.js → List-CnkQuVUq.js} +1 -1
  14. package/dist/client/assets/{Loading01-DDv5lfhX.js → Loading01-ZUH_hVSq.js} +1 -1
  15. package/dist/client/assets/{Play-Q9uDVIa5.js → Play-CCpyKlpN.js} +1 -1
  16. package/dist/client/assets/{Plus-DcUxQQXw.js → Plus-D9CNWrFQ.js} +1 -1
  17. package/dist/client/assets/{RefreshCcw01-nS96T2bf.js → RefreshCcw01-Cu6svfY5.js} +1 -1
  18. package/dist/client/assets/{SearchMd-CTpXH6F3.js → SearchMd-BH_J7-7p.js} +1 -1
  19. package/dist/client/assets/{Settings01-BVY96Vsg.js → Settings01-DTaoTYj1.js} +1 -1
  20. package/dist/client/assets/{Trash01-CzfVJZjl.js → Trash01-Cv31wiMP.js} +1 -1
  21. package/dist/client/assets/{Type01-BwsSTKh1.js → Type01-BRLQyycA.js} +1 -1
  22. package/dist/client/assets/{Upload01-Bn_9d04P.js → Upload01-BY6Noksk.js} +1 -1
  23. package/dist/client/assets/{User01-Dl4j8Eui.js → User01-BloSEKZw.js} +1 -1
  24. package/dist/client/assets/{VideoRecorder-0-qQusnp.js → VideoRecorder-CqjZf9cg.js} +1 -1
  25. package/dist/client/assets/{X-DvXlEl9E.js → X-1dO_8PIJ.js} +1 -1
  26. package/dist/client/assets/{XCircle-DI9HiD4A.js → XCircle-BEC1SvTX.js} +1 -1
  27. package/dist/client/assets/{XClose-Bw5018RM.js → XClose-BzyTilGE.js} +1 -1
  28. package/dist/client/assets/{Zap-DGbTVlYq.js → Zap-D6SUOiFY.js} +1 -1
  29. package/dist/client/assets/{agent-connections-preview-Cfflc0J5.js → agent-connections-preview-COmBlzCd.js} +1 -1
  30. package/dist/client/assets/{agent-detail-CehIC3W1.js → agent-detail-DAo3-7Gz.js} +1 -1
  31. package/dist/client/assets/{agents-DmtfY0M7.js → agents-Cy0iaygc.js} +1 -1
  32. package/dist/client/assets/{ai-providers-logos-BtOy-_hY.js → ai-providers-logos-Cr4iRu-0.js} +1 -1
  33. package/dist/client/assets/{alert-dialog-CIdU20ao.js → alert-dialog-DnwDlp7T.js} +1 -1
  34. package/dist/client/assets/{auth-catchall-DklKmwQO.js → auth-catchall-CJb2iecY.js} +1 -1
  35. package/dist/client/assets/{automation-detail-CIe1WG8E.js → automation-detail-DIl5XDBS.js} +1 -1
  36. package/dist/client/assets/{automations-KsqaYtsv.js → automations-4lM2x30V.js} +1 -1
  37. package/dist/client/assets/{avatar-Dz9Au16I.js → avatar-CahK8DWE.js} +1 -1
  38. package/dist/client/assets/{badge-BIY4HSu4.js → badge-a1yIqkX1.js} +1 -1
  39. package/dist/client/assets/{binder-DaeU7_Yt.js → binder-B_Xezby6.js} +1 -1
  40. package/dist/client/assets/{breadcrumb-DNInqlES.js → breadcrumb-DBLmG8ET.js} +1 -1
  41. package/dist/client/assets/{card-CoTaf7Bb.js → card-BkMKAjKJ.js} +1 -1
  42. package/dist/client/assets/{checkbox-UWf_Spym.js → checkbox-DFbWpPSa.js} +1 -1
  43. package/dist/client/assets/{collapsible-DGsDf05s.js → collapsible-CzCLTaIa.js} +1 -1
  44. package/dist/client/assets/{collection-detail-jT6_1Zus.js → collection-detail-CP2ikFfr.js} +1 -1
  45. package/dist/client/assets/{collection-display-button-CIwF6qiP.js → collection-display-button-BTy8OMGo.js} +1 -1
  46. package/dist/client/assets/{collection-search-DmeA1lkM.js → collection-search-BaA_5hnO.js} +1 -1
  47. package/dist/client/assets/{collection-table-wrapper-DZ9kkHHz.js → collection-table-wrapper-CeDvXZ6e.js} +1 -1
  48. package/dist/client/assets/{collection-tabs-VEtVQj8e.js → collection-tabs-B_Ive8CL.js} +1 -1
  49. package/dist/client/assets/{command-DS9L8dE9.js → command-DeF62mUG.js} +1 -1
  50. package/dist/client/assets/{connection-card-DY8BmloD.js → connection-card-ClL9bm7k.js} +1 -1
  51. package/dist/client/assets/{connection-detail-D6zDmZps.js → connection-detail-D6Ad6Uup.js} +1 -1
  52. package/dist/client/assets/{connections-BvDULZyp.js → connections-Dkdo-MxF.js} +1 -1
  53. package/dist/client/assets/{constants-C5g6K3-0.js → constants-kAo23sAc.js} +1 -1
  54. package/dist/client/assets/{context-0-m5aPvK.js → context-C2WVT2wI.js} +1 -1
  55. package/dist/client/assets/{create-organization-dialog-Bw7JkHCW.js → create-organization-dialog--yeW4Rp3.js} +1 -1
  56. package/dist/client/assets/{create-project-dialog-CofGaj8t.js → create-project-dialog-DX0tom06.js} +1 -1
  57. package/dist/client/assets/{danger-BxwsLFA0.js → danger-BEWSLgEr.js} +1 -1
  58. package/dist/client/assets/{danger-zone-DNgGGkaE.js → danger-zone-COttqiLk.js} +1 -1
  59. package/dist/client/assets/{dependencies-CscQrQx3.js → dependencies-DQpwdViP.js} +1 -1
  60. package/dist/client/assets/{dialog-Beaz2erB.js → dialog-B-I43lOk.js} +1 -1
  61. package/dist/client/assets/{drawer-DuM10S-O.js → drawer-Cc_fH-oc.js} +1 -1
  62. package/dist/client/assets/{dropdown-menu-IA1w2fjK.js → dropdown-menu-KiFp7XSX.js} +1 -1
  63. package/dist/client/assets/{dynamic-plugin-layout-CtDEEZnp.js → dynamic-plugin-layout-DqyTuAzp.js} +1 -1
  64. package/dist/client/assets/{editable-task-title-DuDIwQf_.js → editable-task-title-DABFKKXz.js} +1 -1
  65. package/dist/client/assets/{empty-state-DnJSxmJA.js → empty-state-BclY67WC.js} +1 -1
  66. package/dist/client/assets/{empty-state-hwIP0sm6.js → empty-state-UToLDOJO.js} +1 -1
  67. package/dist/client/assets/{env-vars-editor-Ceyzo9UT.js → env-vars-editor-D3JHoO0m.js} +1 -1
  68. package/dist/client/assets/{extract-connection-data-D13QyL30.js → extract-connection-data-GhIKo0Xr.js} +1 -1
  69. package/dist/client/assets/{file-browser-B-JXooL8.js → file-browser-CZHih4nP.js} +2 -2
  70. package/dist/client/assets/{form-CccEC3cm.js → form-edx7u0Be.js} +1 -1
  71. package/dist/client/assets/{general-axIGxWAv.js → general-rmW6kn_q.js} +1 -1
  72. package/dist/client/assets/{generate-id-0beDKMoR.js → generate-id-B0hqIne-.js} +1 -1
  73. package/dist/client/assets/{grid-view-VGzy6bo9.js → grid-view-SzsDCBqX.js} +1 -1
  74. package/dist/client/assets/{home-ED4EKgWV.js → home-BW8Jzf61.js} +1 -1
  75. package/dist/client/assets/{index-DxFKywdp.js → index--68a591R.js} +1 -1
  76. package/dist/client/assets/{index-Be3yjubl.js → index-B3DLUye8.js} +1 -1
  77. package/dist/client/assets/{index-CDessA1I.js → index-Bf3XZpZk.js} +1 -1
  78. package/dist/client/assets/{index-JasJqXzm.js → index-BsYB-j4p.js} +1 -1
  79. package/dist/client/assets/{index-VZp2CIbR.js → index-C45O1mgu.js} +1 -1
  80. package/dist/client/assets/{index-DQTOgFOw.js → index-CJ0BaJHY.js} +1 -1
  81. package/dist/client/assets/{index-BfJLXP0j.js → index-CNQ1T_R3.js} +1 -1
  82. package/dist/client/assets/{index-DqQdLYr7.js → index-Ca6dFB6s.js} +1 -1
  83. package/dist/client/assets/{index-C2aMuEoP.js → index-CyaqcTbn.js} +1 -1
  84. package/dist/client/assets/{index-BjxqoU_w.js → index-Di6oLb1g.js} +3 -3
  85. package/dist/client/assets/{index-DsV3YD3P.js → index-SfPPYQt8.js} +1 -1
  86. package/dist/client/assets/{infiniteQueryObserver-C0OPB4rx.js → infiniteQueryObserver-Cg7Qn-Py.js} +1 -1
  87. package/dist/client/assets/{input-Be0bLLQW.js → input-DQ4QcwHR.js} +1 -1
  88. package/dist/client/assets/{integration-icon-C9ac9VOj.js → integration-icon-DlCg0T4C.js} +1 -1
  89. package/dist/client/assets/{label-C6smVCIk.js → label-BGeQL0ka.js} +1 -1
  90. package/dist/client/assets/{layout-D0N63fj1.js → layout-D6ZxqJKi.js} +1 -1
  91. package/dist/client/assets/{layout-CYi_63K3.js → layout-DtwUtGx0.js} +1 -1
  92. package/dist/client/assets/{login-B4SjGwXr.js → login-DlB4I5sp.js} +1 -1
  93. package/dist/client/assets/{logo-upload-DwLQLlu7.js → logo-upload-BtAPf8sp.js} +1 -1
  94. package/dist/client/assets/{mcp-app-renderer-BWF6RI84.js → mcp-app-renderer-Cg9Eew2n.js} +1 -1
  95. package/dist/client/assets/{mcp-server-card-ksfI1Eyh.js → mcp-server-card-4V1eOOTX.js} +1 -1
  96. package/dist/client/assets/{mcp-server-detail-Cb-T_-Mb.js → mcp-server-detail-CX9gEsnH.js} +2 -2
  97. package/dist/client/assets/{members-DJ6DA7d5.js → members-D1cMWKgG.js} +1 -1
  98. package/dist/client/assets/{monaco-editor-D0GS_D3E.js → monaco-editor-DnqhgBvh.js} +1 -1
  99. package/dist/client/assets/{monitoring-osT0IqjS.js → monitoring-BQpDfDrf.js} +1 -1
  100. package/dist/client/assets/{monitoring-dashboard-edit-Bxyyp3mT.js → monitoring-dashboard-edit-Cbicjk63.js} +1 -1
  101. package/dist/client/assets/{monitoring-dashboard-view-D1jhpkzD.js → monitoring-dashboard-view-Ci-RFMRb.js} +1 -1
  102. package/dist/client/assets/{monitoring-stats-row-BzJ0yham.js → monitoring-stats-row-vvMdV41p.js} +1 -1
  103. package/dist/client/assets/{oauth-callback-B9dLIXA2.js → oauth-callback-DIjSwsej.js} +1 -1
  104. package/dist/client/assets/{oauth-callback-ai-provider-mFsE32vf.js → oauth-callback-ai-provider-Dh3KWtZ6.js} +1 -1
  105. package/dist/client/assets/{org-ai-providers-UG6FIdxB.js → org-ai-providers-DGjdQR3W.js} +1 -1
  106. package/dist/client/assets/{page-C4W1F739.js → page-DCh64rPG.js} +1 -1
  107. package/dist/client/assets/{page-Drtt1B9w.js → page-DqLtxYci.js} +1 -1
  108. package/dist/client/assets/{plugin-empty-state-C-XfLac2.js → plugin-empty-state-DXF12w3Y.js} +1 -1
  109. package/dist/client/assets/{plugin-empty-state-C7t75jMS.js → plugin-empty-state-KrWE8h_c.js} +1 -1
  110. package/dist/client/assets/{plugin-header-BJKUaApF.js → plugin-header-BRNld0B2.js} +1 -1
  111. package/dist/client/assets/{plugin-header-5ST0P5Q7.js → plugin-header-CxhFSwvz.js} +1 -1
  112. package/dist/client/assets/plugins-BVx4W74m.js +1 -0
  113. package/dist/client/assets/{popover-Dn0X9Fr1.js → popover-DnP50c_4.js} +1 -1
  114. package/dist/client/assets/{project-app-view-CcUsagsx.js → project-app-view-BjmqGgdc.js} +1 -1
  115. package/dist/client/assets/{project-layout-D9UABDEG.js → project-layout-B0N0-1u8.js} +1 -1
  116. package/dist/client/assets/{project-plugins-B2zBuBKC.js → project-plugins-W6YBdGTQ.js} +1 -1
  117. package/dist/client/assets/{projects-list-BWN1T4nW.js → projects-list-x0gTe3hu.js} +1 -1
  118. package/dist/client/assets/{registry-layout-tQMWJSmp.js → registry-layout-CCApya06.js} +1 -1
  119. package/dist/client/assets/{registry-utils-CVkiAvdy.js → registry-utils-B2MGgFdM.js} +1 -1
  120. package/dist/client/assets/{reset-password-DJ4VaB6B.js → reset-password-BGRs1AsG.js} +1 -1
  121. package/dist/client/assets/{resizable-BD6CMEjd.js → resizable-BUdS0TeH.js} +1 -1
  122. package/dist/client/assets/{save-actions-BFbH4lFH.js → save-actions-CZB_80fx.js} +1 -1
  123. package/dist/client/assets/{scroll-area-VqeDMOPN.js → scroll-area-BDvsWD3_.js} +1 -1
  124. package/dist/client/assets/{select-VEJvYQo7.js → select-DE6nOtq4.js} +1 -1
  125. package/dist/client/assets/{select-virtual-mcp-BVFbfMoH.js → select-virtual-mcp-BcDL714M.js} +1 -1
  126. package/dist/client/assets/{shell-layout-lPP98AcT.js → shell-layout-dlpBTl1V.js} +2 -2
  127. package/dist/client/assets/{sidebar-settings-Cvi9DQQC.js → sidebar-settings-DvmipHRI.js} +1 -1
  128. package/dist/client/assets/{skeleton-HKYMRn58.js → skeleton-jHSQmvNz.js} +1 -1
  129. package/dist/client/assets/{spinner-BFdTwge6.js → spinner-uIlWy8Tn.js} +1 -1
  130. package/dist/client/assets/{store-invite-BqHShMlA.js → store-invite-hyBdEV4m.js} +1 -1
  131. package/dist/client/assets/{switch-CG6Wlm7Y.js → switch-DqoVcDTw.js} +1 -1
  132. package/dist/client/assets/{table-C915-j5j.js → table-BtUXt-LB.js} +1 -1
  133. package/dist/client/assets/{tabs-EJf8mrdN.js → tabs-Co0v-Gtu.js} +1 -1
  134. package/dist/client/assets/{task-status-DwSGaLCq.js → task-status-mBvgK6CE.js} +5 -3
  135. package/dist/client/assets/tasks-D2ul5DI6.js +1 -0
  136. package/dist/client/assets/{tasks-panel-j-1pM09U.js → tasks-panel-CKxWhrpo.js} +1 -1
  137. package/dist/client/assets/{textarea-BpJcJgEu.js → textarea-DK_nHNH9.js} +1 -1
  138. package/dist/client/assets/{time-range-picker-CBrng89O.js → time-range-picker-Dq2GzTz_.js} +1 -1
  139. package/dist/client/assets/{toggle-group-D3jOZx6Z.js → toggle-group-C2i_WN24.js} +1 -1
  140. package/dist/client/assets/{tools-list-BJKvrBYn.js → tools-list-SO4mO2yz.js} +1 -1
  141. package/dist/client/assets/{tooltip-SqkLa6wk.js → tooltip-Bt2vWRpT.js} +1 -1
  142. package/dist/client/assets/{topbar-portal-Ul2d-lg1.js → topbar-portal-C9UZ6_6p.js} +1 -1
  143. package/dist/client/assets/{types-CdHbWvSx.js → types-C4sVrknd.js} +1 -1
  144. package/dist/client/assets/{use-automations-xjYa92g6.js → use-automations-DgVOPvmM.js} +1 -1
  145. package/dist/client/assets/{use-collections-Zp8eOwPm.js → use-collections-CojcRvND.js} +1 -1
  146. package/dist/client/assets/{use-connection-B-vgK3kN.js → use-connection-CJIltDo3.js} +1 -1
  147. package/dist/client/assets/{use-copy-Bor2cPit.js → use-copy-_cPtrtTH.js} +1 -1
  148. package/dist/client/assets/{use-create-virtual-mcp-DLLVUJBK.js → use-create-virtual-mcp-D7i1HcQg.js} +1 -1
  149. package/dist/client/assets/{use-infinite-scroll-QweqoXs4.js → use-infinite-scroll-xFnZb5m2.js} +1 -1
  150. package/dist/client/assets/{use-install-from-registry-BWF2XusE.js → use-install-from-registry-BUPQMjUV.js} +1 -1
  151. package/dist/client/assets/{use-list-state-BpX2jytt.js → use-list-state-Bp_aU4BI.js} +1 -1
  152. package/dist/client/assets/{use-mcp-prompts-qi4FHPHh.js → use-mcp-prompts-zeDoy0Xo.js} +1 -1
  153. package/dist/client/assets/{use-mcp-resources-B8ERGBbF.js → use-mcp-resources-BIFxFRhN.js} +1 -1
  154. package/dist/client/assets/{use-mcp-tools-DNLvgz5O.js → use-mcp-tools-BD0zsUGc.js} +1 -1
  155. package/dist/client/assets/{use-members-CcTYAvXH.js → use-members-CbUEMp3B.js} +1 -1
  156. package/dist/client/assets/{use-project-D_8V3WFM.js → use-project-BVkW8l1T.js} +1 -1
  157. package/dist/client/assets/{use-store-discovery-iIFblh2E.js → use-store-discovery-Dr1RNWE5.js} +1 -1
  158. package/dist/client/assets/{use-view-mode-BBlaOBUn.js → use-view-mode-DNywUlq7.js} +1 -1
  159. package/dist/client/assets/{use-virtual-mcp-BnUWdVw5.js → use-virtual-mcp-BdGbK3Wg.js} +1 -1
  160. package/dist/client/assets/useInfiniteQuery-BKFOAK_4.js +1 -0
  161. package/dist/client/assets/{useMutation-oWI4nFQG.js → useMutation-BOcaN318.js} +1 -1
  162. package/dist/client/assets/useQuery-BrfnS-T_.js +1 -0
  163. package/dist/client/assets/useSuspenseInfiniteQuery-XlSq2d-l.js +1 -0
  164. package/dist/client/assets/{user-BtGr8jKI.js → user-BdXDOTfV.js} +1 -1
  165. package/dist/client/assets/{workflow-CKtu7TZc.js → workflow-C2zJzxLb.js} +1 -1
  166. package/dist/client/index.html +1 -1
  167. package/dist/server/node_modules/xtend/.jshintrc +30 -0
  168. package/dist/server/node_modules/{postgres-bytea/license → xtend/LICENSE} +1 -2
  169. package/dist/server/node_modules/xtend/README.md +32 -0
  170. package/dist/server/node_modules/xtend/immutable.js +19 -0
  171. package/dist/server/node_modules/xtend/mutable.js +17 -0
  172. package/dist/server/node_modules/xtend/package.json +55 -0
  173. package/dist/server/node_modules/xtend/test.js +103 -0
  174. package/package.json +1 -1
  175. package/dist/client/assets/plugins-EgDqBTdv.js +0 -1
  176. package/dist/client/assets/tasks-B-KbBDgd.js +0 -1
  177. package/dist/client/assets/useInfiniteQuery-KvMZbxSR.js +0 -1
  178. package/dist/client/assets/useQuery-CmP1G4DA.js +0 -1
  179. package/dist/client/assets/useSuspenseInfiniteQuery-4eRk30PP.js +0 -1
  180. package/dist/server/node_modules/async-exit-hook/CHANGELOG.md +0 -62
  181. package/dist/server/node_modules/async-exit-hook/index.js +0 -171
  182. package/dist/server/node_modules/async-exit-hook/license +0 -21
  183. package/dist/server/node_modules/async-exit-hook/package.json +0 -66
  184. package/dist/server/node_modules/async-exit-hook/readme.md +0 -118
  185. package/dist/server/node_modules/pg-int8/LICENSE +0 -13
  186. package/dist/server/node_modules/pg-int8/README.md +0 -16
  187. package/dist/server/node_modules/pg-int8/index.js +0 -100
  188. package/dist/server/node_modules/pg-int8/package.json +0 -24
  189. package/dist/server/node_modules/postgres-bytea/index.js +0 -33
  190. package/dist/server/node_modules/postgres-bytea/package.json +0 -34
  191. package/dist/server/node_modules/postgres-bytea/readme.md +0 -34
  192. package/dist/server/node_modules/postgres-date/index.js +0 -116
  193. package/dist/server/node_modules/postgres-date/license +0 -21
  194. package/dist/server/node_modules/postgres-date/package.json +0 -33
  195. package/dist/server/node_modules/postgres-date/readme.md +0 -49
  196. package/dist/server/node_modules/postgres-interval/index.d.ts +0 -20
  197. package/dist/server/node_modules/postgres-interval/index.js +0 -125
  198. package/dist/server/node_modules/postgres-interval/license +0 -21
  199. package/dist/server/node_modules/postgres-interval/package.json +0 -36
  200. package/dist/server/node_modules/postgres-interval/readme.md +0 -48
  201. package/dist/server/node_modules/split2/LICENSE +0 -13
  202. package/dist/server/node_modules/split2/README.md +0 -85
  203. package/dist/server/node_modules/split2/bench.js +0 -27
  204. package/dist/server/node_modules/split2/index.js +0 -141
  205. package/dist/server/node_modules/split2/package.json +0 -39
  206. package/dist/server/node_modules/split2/test.js +0 -409
@@ -1 +1 @@
1
- import{c as D,D as I,r as E,j as s,w as K,v as w,B as z,aK as O}from"./index-BjxqoU_w.js";import{u as P}from"./topbar-portal-Ul2d-lg1.js";import{K as R,u as q,g as $,a as B,f as _}from"./file-browser-B-JXooL8.js";import{i as G}from"./AlertCircle-Hpsw9_tf.js";import{n as Q}from"./Download01-BBRbjA11.js";import{s as V,a as T}from"./List-D35z7ORx.js";import{a as M,i as A,b as H,c as J,d as Y,e as Z}from"./VideoRecorder-0-qQusnp.js";import{i as U}from"./Loading01-DDv5lfhX.js";import{s as S}from"./Trash01-CzfVJZjl.js";import{i as W}from"./Upload01-Bn_9d04P.js";import{u as L}from"./useMutation-oWI4nFQG.js";import{u as X}from"./useQuery-CmP1G4DA.js";import"./useInfiniteQuery-KvMZbxSR.js";import"./infiniteQueryObserver-C0OPB4rx.js";import"./checkbox-UWf_Spym.js";import"./Check-CVKUMJv3.js";import"./ChevronRight-CTHCKnjF.js";import"./Grid01-CbgVFQNg.js";function ee(p){const e=D.c(5),[t,h]=E.useState(!1),a=E.useRef(null),c=E.useRef(!1);let i;e[0]!==p?(i=m=>{a.current&&(a.current.disconnect(),a.current=null),m&&!c.current&&(a.current=new IntersectionObserver(y=>{const[n]=y;n?.isIntersecting&&!c.current&&(c.current=!0,h(!0),a.current?.disconnect(),a.current=null)},p),a.current.observe(m))},e[0]=p,e[1]=i):i=e[1];const l=i;let x;return e[2]!==t||e[3]!==l?(x=[t,l],e[2]=t,e[3]=l,e[4]=x):x=e[4],x}function te(p){const e=D.c(24),{objectKey:t,alt:h,className:a}=p,c=a===void 0?"":a,{connectionId:i,toolCaller:l}=P();let x;e[0]===Symbol.for("react.memo_cache_sentinel")?(x={rootMargin:"100px",threshold:0},e[0]=x):x=e[0];const[m,y]=ee(x);let n;e[1]!==i||e[2]!==t?(n=R.imagePreview(i,t),e[1]=i,e[2]=t,e[3]=n):n=e[3];let u;e[4]!==t||e[5]!==l?(u=async()=>{const{url:d}=await l("GET_PRESIGNED_URL",{key:t});return d},e[4]=t,e[5]=l,e[6]=u):u=e[6];let b;e[7]!==m||e[8]!==n||e[9]!==u?(b={queryKey:n,queryFn:u,enabled:m,staleTime:3e5,gcTime:6e5},e[7]=m,e[8]=n,e[9]=u,e[10]=b):b=e[10];const{data:v,isLoading:g,error:j}=X(b);let f;e[11]!==c?(f=I("relative w-full h-full flex items-center justify-center overflow-hidden",c),e[11]=c,e[12]=f):f=e[12];let r;e[13]!==h||e[14]!==j||e[15]!==v||e[16]!==g||e[17]!==m||e[18]!==t?(r=!m||g?s.jsx("div",{className:"flex flex-col items-center justify-center text-muted-foreground",children:g?s.jsx(U,{size:24,className:"animate-spin"}):s.jsx(M,{size:48})}):j?s.jsx("div",{className:"flex flex-col items-center justify-center text-muted-foreground",children:s.jsx(G,{size:24})}):v?s.jsx("img",{src:v,alt:h||t,className:"w-full h-full object-cover",loading:"lazy"}):null,e[13]=h,e[14]=j,e[15]=v,e[16]=g,e[17]=m,e[18]=t,e[19]=r):r=e[19];let o;return e[20]!==y||e[21]!==f||e[22]!==r?(o=s.jsx("div",{ref:y,className:f,children:r}),e[20]=y,e[21]=f,e[22]=r,e[23]=o):o=e[23],o}const C=12,se={Image01:M,VideoRecorder:Z,Music01:T,File02:T,File04:Y,File06:J,File07:H,FileCode01:A,Folder:O};function re(p){const e=p.split(".").pop()?.toLowerCase();return["jpg","jpeg","png","gif","webp","svg","bmp","ico"].includes(e||"")}function oe(p){const e=D.c(41),{item:t,onNavigate:h,onDownload:a,onDelete:c}=p;let i;e[0]!==t.key?(i=$(t.key),e[0]=t.key,e[1]=i):i=e[1];const l=i,x=t.isFolder?"Folder":B(t.key),m=se[x]||T;let y;e[2]!==t.isFolder||e[3]!==t.key?(y=!t.isFolder&&re(t.key),e[2]=t.isFolder,e[3]=t.key,e[4]=y):y=e[4];const n=y;let u;e[5]!==t.isFolder||e[6]!==t.key||e[7]!==h?(u=()=>t.isFolder?h(t.key):void 0,e[5]=t.isFolder,e[6]=t.key,e[7]=h,e[8]=u):u=e[8];const b=!n&&"p-4",v=t.isFolder?"cursor-pointer":"cursor-default";let g;e[9]!==b||e[10]!==v?(g=I("flex flex-col items-center justify-center w-full h-full",b,v),e[9]=b,e[10]=v,e[11]=g):g=e[11];let j;e[12]!==m||e[13]!==n||e[14]!==t.isFolder||e[15]!==t.key||e[16]!==l?(j=n?s.jsx("div",{className:"absolute inset-0",children:s.jsx(te,{objectKey:t.key,alt:l})}):s.jsx(m,{size:48,className:I(t.isFolder?"text-amber-500":"text-muted-foreground")}),e[12]=m,e[13]=n,e[14]=t.isFolder,e[15]=t.key,e[16]=l,e[17]=j):j=e[17];let f;e[18]!==n||e[19]!==t.isFolder||e[20]!==t.size||e[21]!==l?(f=n?s.jsxs("div",{className:"absolute bottom-0 left-0 right-0 bg-gradient-to-t from-black/70 to-transparent p-2 pt-6",children:[s.jsx("span",{className:"text-sm text-white text-center line-clamp-1 block",children:l}),s.jsx("span",{className:"text-xs text-white/70 text-center block",children:_(t.size)})]}):s.jsxs(s.Fragment,{children:[s.jsx("span",{className:"mt-3 text-sm text-center line-clamp-2 px-2",children:l}),!t.isFolder&&s.jsx("span",{className:"mt-1 text-xs text-muted-foreground",children:_(t.size)})]}),e[18]=n,e[19]=t.isFolder,e[20]=t.size,e[21]=l,e[22]=f):f=e[22];let r;e[23]!==u||e[24]!==g||e[25]!==j||e[26]!==f?(r=s.jsxs("button",{type:"button",onClick:u,className:g,children:[j,f]}),e[23]=u,e[24]=g,e[25]=j,e[26]=f,e[27]=r):r=e[27];let o;e[28]!==t.isFolder||e[29]!==t.key||e[30]!==c||e[31]!==a?(o=!t.isFolder&&s.jsxs("div",{className:"absolute top-2 right-2 flex gap-1 opacity-0 group-hover:opacity-100 transition-opacity",children:[s.jsx(z,{variant:"secondary",size:"sm",className:"size-7 p-0",onClick:F=>{F.stopPropagation(),a(t.key)},children:s.jsx(Q,{size:14})}),s.jsx(z,{variant:"secondary",size:"sm",className:"size-7 p-0 text-destructive hover:text-destructive",onClick:F=>{F.stopPropagation(),c(t.key)},children:s.jsx(S,{size:14})})]}),e[28]=t.isFolder,e[29]=t.key,e[30]=c,e[31]=a,e[32]=o):o=e[32];let d;e[33]!==t.isFolder||e[34]!==t.key||e[35]!==c?(d=t.isFolder&&s.jsx("div",{className:"absolute top-2 right-2 opacity-0 group-hover:opacity-100 transition-opacity",children:s.jsx(z,{variant:"secondary",size:"sm",className:"size-7 p-0 text-destructive hover:text-destructive",onClick:F=>{F.stopPropagation(),c(t.key)},children:s.jsx(S,{size:14})})}),e[33]=t.isFolder,e[34]=t.key,e[35]=c,e[36]=d):d=e[36];let N;return e[37]!==o||e[38]!==d||e[39]!==r?(N=s.jsxs("div",{className:"group relative aspect-square bg-muted/30 rounded-lg border border-border hover:border-primary/50 hover:bg-muted/50 transition-colors overflow-hidden",children:[r,o,d]}),e[37]=o,e[38]=d,e[39]=r,e[40]=N):N=e[40],N}function Fe({prefix:p,flat:e,onNavigate:t}){const h=E.useRef(null),a=K(),{connectionId:c,toolCaller:i}=P(),{objects:l,isLoading:x,isFetchingMore:m,hasMore:y,loadMore:n,error:u}=q({prefix:p,flat:e,pageSize:C}),b=L({mutationFn:async r=>{const o=p+r.name,{url:d}=await i("PUT_PRESIGNED_URL",{key:o,contentType:r.type||"application/octet-stream"}),N=await fetch(d,{method:"PUT",body:r,headers:{"Content-Type":r.type||"application/octet-stream"}});if(!N.ok)throw new Error(`Upload failed: ${N.statusText}`);return o},onSuccess:r=>{w.success(`Uploaded ${$(r)}`),a.invalidateQueries({queryKey:R.objects(c,p,e,C)})},onError:r=>{w.error(`Upload failed: ${r.message}`)}}),v=L({mutationFn:async r=>r.length===1&&r[0]?i("DELETE_OBJECT",{key:r[0]}):i("DELETE_OBJECTS",{keys:r}),onSuccess:()=>{w.success("Deleted successfully"),a.invalidateQueries({queryKey:R.objects(c,p,e,C)})},onError:r=>{w.error(`Delete failed: ${r.message}`)}}),g=async r=>{try{const{url:o}=await i("GET_PRESIGNED_URL",{key:r}),d=await fetch(o);if(!d.ok)throw new Error(`Failed to fetch file: ${d.statusText}`);const N=await d.blob(),F=URL.createObjectURL(N),k=document.createElement("a");k.href=F,k.download=$(r),document.body.appendChild(k),k.click(),document.body.removeChild(k),URL.revokeObjectURL(F)}catch(o){w.error(`Download failed: ${o instanceof Error?o.message:"Unknown error"}`)}},j=r=>{const o=r.target.files;if(o){for(const d of Array.from(o))b.mutate(d);r.target.value=""}},f=r=>{if(!y||m)return;const o=r.currentTarget;o.scrollHeight-o.scrollTop-o.clientHeight<200&&n()};return u?s.jsxs("div",{className:"flex flex-col items-center justify-center h-full p-8",children:[s.jsx(G,{size:48,className:"text-destructive mb-4"}),s.jsx("h3",{className:"text-lg font-medium mb-2",children:"Error loading files"}),s.jsx("p",{className:"text-muted-foreground text-center",children:u.message})]}):s.jsx("div",{className:"flex-1 overflow-y-auto p-4",onScroll:f,children:x?s.jsxs("div",{className:"flex flex-col items-center justify-center py-12",children:[s.jsx(U,{size:32,className:"animate-spin text-muted-foreground mb-4"}),s.jsx("p",{className:"text-sm text-muted-foreground",children:"Loading files..."})]}):l.length===0?s.jsxs("div",{className:"flex flex-col items-center justify-center py-12 text-center",children:[s.jsx(V,{size:48,className:"text-muted-foreground mb-4"}),s.jsx("h3",{className:"text-lg font-medium mb-2",children:"This folder is empty"}),s.jsx("p",{className:"text-muted-foreground mb-4",children:"Upload files to get started"}),s.jsx("input",{ref:h,type:"file",multiple:!0,className:"hidden",onChange:j}),s.jsxs(z,{variant:"outline",onClick:()=>h.current?.click(),children:[s.jsx(W,{size:14,className:"mr-1"}),"Upload files"]})]}):s.jsxs(s.Fragment,{children:[s.jsx("div",{className:"grid grid-cols-2 sm:grid-cols-3 md:grid-cols-4 gap-4",children:l.map(r=>s.jsx(oe,{item:r,onNavigate:t,onDownload:g,onDelete:o=>v.mutate([o])},r.key))}),m&&s.jsx("div",{className:"flex justify-center py-8",children:s.jsx(U,{size:24,className:"animate-spin text-muted-foreground"})})]})})}export{Fe as default};
1
+ import{c as D,D as I,r as E,j as s,w as K,v as w,B as z,aK as O}from"./index-Di6oLb1g.js";import{u as P}from"./topbar-portal-C9UZ6_6p.js";import{K as R,u as q,g as $,a as B,f as _}from"./file-browser-CZHih4nP.js";import{i as G}from"./AlertCircle-D2rRA9CS.js";import{n as Q}from"./Download01-DGSbxmSo.js";import{s as V,a as T}from"./List-CnkQuVUq.js";import{a as M,i as A,b as H,c as J,d as Y,e as Z}from"./VideoRecorder-CqjZf9cg.js";import{i as U}from"./Loading01-ZUH_hVSq.js";import{s as S}from"./Trash01-Cv31wiMP.js";import{i as W}from"./Upload01-BY6Noksk.js";import{u as L}from"./useMutation-BOcaN318.js";import{u as X}from"./useQuery-BrfnS-T_.js";import"./useInfiniteQuery-BKFOAK_4.js";import"./infiniteQueryObserver-Cg7Qn-Py.js";import"./checkbox-DFbWpPSa.js";import"./Check-CecxQkQE.js";import"./ChevronRight-2xVQHhsF.js";import"./Grid01-CLnEHof5.js";function ee(p){const e=D.c(5),[t,h]=E.useState(!1),a=E.useRef(null),c=E.useRef(!1);let i;e[0]!==p?(i=m=>{a.current&&(a.current.disconnect(),a.current=null),m&&!c.current&&(a.current=new IntersectionObserver(y=>{const[n]=y;n?.isIntersecting&&!c.current&&(c.current=!0,h(!0),a.current?.disconnect(),a.current=null)},p),a.current.observe(m))},e[0]=p,e[1]=i):i=e[1];const l=i;let x;return e[2]!==t||e[3]!==l?(x=[t,l],e[2]=t,e[3]=l,e[4]=x):x=e[4],x}function te(p){const e=D.c(24),{objectKey:t,alt:h,className:a}=p,c=a===void 0?"":a,{connectionId:i,toolCaller:l}=P();let x;e[0]===Symbol.for("react.memo_cache_sentinel")?(x={rootMargin:"100px",threshold:0},e[0]=x):x=e[0];const[m,y]=ee(x);let n;e[1]!==i||e[2]!==t?(n=R.imagePreview(i,t),e[1]=i,e[2]=t,e[3]=n):n=e[3];let u;e[4]!==t||e[5]!==l?(u=async()=>{const{url:d}=await l("GET_PRESIGNED_URL",{key:t});return d},e[4]=t,e[5]=l,e[6]=u):u=e[6];let b;e[7]!==m||e[8]!==n||e[9]!==u?(b={queryKey:n,queryFn:u,enabled:m,staleTime:3e5,gcTime:6e5},e[7]=m,e[8]=n,e[9]=u,e[10]=b):b=e[10];const{data:v,isLoading:g,error:j}=X(b);let f;e[11]!==c?(f=I("relative w-full h-full flex items-center justify-center overflow-hidden",c),e[11]=c,e[12]=f):f=e[12];let r;e[13]!==h||e[14]!==j||e[15]!==v||e[16]!==g||e[17]!==m||e[18]!==t?(r=!m||g?s.jsx("div",{className:"flex flex-col items-center justify-center text-muted-foreground",children:g?s.jsx(U,{size:24,className:"animate-spin"}):s.jsx(M,{size:48})}):j?s.jsx("div",{className:"flex flex-col items-center justify-center text-muted-foreground",children:s.jsx(G,{size:24})}):v?s.jsx("img",{src:v,alt:h||t,className:"w-full h-full object-cover",loading:"lazy"}):null,e[13]=h,e[14]=j,e[15]=v,e[16]=g,e[17]=m,e[18]=t,e[19]=r):r=e[19];let o;return e[20]!==y||e[21]!==f||e[22]!==r?(o=s.jsx("div",{ref:y,className:f,children:r}),e[20]=y,e[21]=f,e[22]=r,e[23]=o):o=e[23],o}const C=12,se={Image01:M,VideoRecorder:Z,Music01:T,File02:T,File04:Y,File06:J,File07:H,FileCode01:A,Folder:O};function re(p){const e=p.split(".").pop()?.toLowerCase();return["jpg","jpeg","png","gif","webp","svg","bmp","ico"].includes(e||"")}function oe(p){const e=D.c(41),{item:t,onNavigate:h,onDownload:a,onDelete:c}=p;let i;e[0]!==t.key?(i=$(t.key),e[0]=t.key,e[1]=i):i=e[1];const l=i,x=t.isFolder?"Folder":B(t.key),m=se[x]||T;let y;e[2]!==t.isFolder||e[3]!==t.key?(y=!t.isFolder&&re(t.key),e[2]=t.isFolder,e[3]=t.key,e[4]=y):y=e[4];const n=y;let u;e[5]!==t.isFolder||e[6]!==t.key||e[7]!==h?(u=()=>t.isFolder?h(t.key):void 0,e[5]=t.isFolder,e[6]=t.key,e[7]=h,e[8]=u):u=e[8];const b=!n&&"p-4",v=t.isFolder?"cursor-pointer":"cursor-default";let g;e[9]!==b||e[10]!==v?(g=I("flex flex-col items-center justify-center w-full h-full",b,v),e[9]=b,e[10]=v,e[11]=g):g=e[11];let j;e[12]!==m||e[13]!==n||e[14]!==t.isFolder||e[15]!==t.key||e[16]!==l?(j=n?s.jsx("div",{className:"absolute inset-0",children:s.jsx(te,{objectKey:t.key,alt:l})}):s.jsx(m,{size:48,className:I(t.isFolder?"text-amber-500":"text-muted-foreground")}),e[12]=m,e[13]=n,e[14]=t.isFolder,e[15]=t.key,e[16]=l,e[17]=j):j=e[17];let f;e[18]!==n||e[19]!==t.isFolder||e[20]!==t.size||e[21]!==l?(f=n?s.jsxs("div",{className:"absolute bottom-0 left-0 right-0 bg-gradient-to-t from-black/70 to-transparent p-2 pt-6",children:[s.jsx("span",{className:"text-sm text-white text-center line-clamp-1 block",children:l}),s.jsx("span",{className:"text-xs text-white/70 text-center block",children:_(t.size)})]}):s.jsxs(s.Fragment,{children:[s.jsx("span",{className:"mt-3 text-sm text-center line-clamp-2 px-2",children:l}),!t.isFolder&&s.jsx("span",{className:"mt-1 text-xs text-muted-foreground",children:_(t.size)})]}),e[18]=n,e[19]=t.isFolder,e[20]=t.size,e[21]=l,e[22]=f):f=e[22];let r;e[23]!==u||e[24]!==g||e[25]!==j||e[26]!==f?(r=s.jsxs("button",{type:"button",onClick:u,className:g,children:[j,f]}),e[23]=u,e[24]=g,e[25]=j,e[26]=f,e[27]=r):r=e[27];let o;e[28]!==t.isFolder||e[29]!==t.key||e[30]!==c||e[31]!==a?(o=!t.isFolder&&s.jsxs("div",{className:"absolute top-2 right-2 flex gap-1 opacity-0 group-hover:opacity-100 transition-opacity",children:[s.jsx(z,{variant:"secondary",size:"sm",className:"size-7 p-0",onClick:F=>{F.stopPropagation(),a(t.key)},children:s.jsx(Q,{size:14})}),s.jsx(z,{variant:"secondary",size:"sm",className:"size-7 p-0 text-destructive hover:text-destructive",onClick:F=>{F.stopPropagation(),c(t.key)},children:s.jsx(S,{size:14})})]}),e[28]=t.isFolder,e[29]=t.key,e[30]=c,e[31]=a,e[32]=o):o=e[32];let d;e[33]!==t.isFolder||e[34]!==t.key||e[35]!==c?(d=t.isFolder&&s.jsx("div",{className:"absolute top-2 right-2 opacity-0 group-hover:opacity-100 transition-opacity",children:s.jsx(z,{variant:"secondary",size:"sm",className:"size-7 p-0 text-destructive hover:text-destructive",onClick:F=>{F.stopPropagation(),c(t.key)},children:s.jsx(S,{size:14})})}),e[33]=t.isFolder,e[34]=t.key,e[35]=c,e[36]=d):d=e[36];let N;return e[37]!==o||e[38]!==d||e[39]!==r?(N=s.jsxs("div",{className:"group relative aspect-square bg-muted/30 rounded-lg border border-border hover:border-primary/50 hover:bg-muted/50 transition-colors overflow-hidden",children:[r,o,d]}),e[37]=o,e[38]=d,e[39]=r,e[40]=N):N=e[40],N}function Fe({prefix:p,flat:e,onNavigate:t}){const h=E.useRef(null),a=K(),{connectionId:c,toolCaller:i}=P(),{objects:l,isLoading:x,isFetchingMore:m,hasMore:y,loadMore:n,error:u}=q({prefix:p,flat:e,pageSize:C}),b=L({mutationFn:async r=>{const o=p+r.name,{url:d}=await i("PUT_PRESIGNED_URL",{key:o,contentType:r.type||"application/octet-stream"}),N=await fetch(d,{method:"PUT",body:r,headers:{"Content-Type":r.type||"application/octet-stream"}});if(!N.ok)throw new Error(`Upload failed: ${N.statusText}`);return o},onSuccess:r=>{w.success(`Uploaded ${$(r)}`),a.invalidateQueries({queryKey:R.objects(c,p,e,C)})},onError:r=>{w.error(`Upload failed: ${r.message}`)}}),v=L({mutationFn:async r=>r.length===1&&r[0]?i("DELETE_OBJECT",{key:r[0]}):i("DELETE_OBJECTS",{keys:r}),onSuccess:()=>{w.success("Deleted successfully"),a.invalidateQueries({queryKey:R.objects(c,p,e,C)})},onError:r=>{w.error(`Delete failed: ${r.message}`)}}),g=async r=>{try{const{url:o}=await i("GET_PRESIGNED_URL",{key:r}),d=await fetch(o);if(!d.ok)throw new Error(`Failed to fetch file: ${d.statusText}`);const N=await d.blob(),F=URL.createObjectURL(N),k=document.createElement("a");k.href=F,k.download=$(r),document.body.appendChild(k),k.click(),document.body.removeChild(k),URL.revokeObjectURL(F)}catch(o){w.error(`Download failed: ${o instanceof Error?o.message:"Unknown error"}`)}},j=r=>{const o=r.target.files;if(o){for(const d of Array.from(o))b.mutate(d);r.target.value=""}},f=r=>{if(!y||m)return;const o=r.currentTarget;o.scrollHeight-o.scrollTop-o.clientHeight<200&&n()};return u?s.jsxs("div",{className:"flex flex-col items-center justify-center h-full p-8",children:[s.jsx(G,{size:48,className:"text-destructive mb-4"}),s.jsx("h3",{className:"text-lg font-medium mb-2",children:"Error loading files"}),s.jsx("p",{className:"text-muted-foreground text-center",children:u.message})]}):s.jsx("div",{className:"flex-1 overflow-y-auto p-4",onScroll:f,children:x?s.jsxs("div",{className:"flex flex-col items-center justify-center py-12",children:[s.jsx(U,{size:32,className:"animate-spin text-muted-foreground mb-4"}),s.jsx("p",{className:"text-sm text-muted-foreground",children:"Loading files..."})]}):l.length===0?s.jsxs("div",{className:"flex flex-col items-center justify-center py-12 text-center",children:[s.jsx(V,{size:48,className:"text-muted-foreground mb-4"}),s.jsx("h3",{className:"text-lg font-medium mb-2",children:"This folder is empty"}),s.jsx("p",{className:"text-muted-foreground mb-4",children:"Upload files to get started"}),s.jsx("input",{ref:h,type:"file",multiple:!0,className:"hidden",onChange:j}),s.jsxs(z,{variant:"outline",onClick:()=>h.current?.click(),children:[s.jsx(W,{size:14,className:"mr-1"}),"Upload files"]})]}):s.jsxs(s.Fragment,{children:[s.jsx("div",{className:"grid grid-cols-2 sm:grid-cols-3 md:grid-cols-4 gap-4",children:l.map(r=>s.jsx(oe,{item:r,onNavigate:t,onDownload:g,onDelete:o=>v.mutate([o])},r.key))}),m&&s.jsx("div",{className:"flex justify-center py-8",children:s.jsx(U,{size:24,className:"animate-spin text-muted-foreground"})})]})})}export{Fe as default};
@@ -1 +1 @@
1
- import{c as f,D as y,j as s,f as _,r as C,B as $,bM as O,e as E,w as F,v as w,y as D,S as R,N as H}from"./index-BjxqoU_w.js";import{C as k}from"./card-CoTaf7Bb.js";import{A as G}from"./avatar-Dz9Au16I.js";import{i as Q}from"./AlertCircle-Hpsw9_tf.js";import{i as q}from"./Check-CVKUMJv3.js";import{s as B}from"./Plus-DcUxQQXw.js";import{i as M}from"./SearchMd-CTpXH6F3.js";import{s as T}from"./XClose-Bw5018RM.js";import{I as U}from"./input-Be0bLLQW.js";import{C as P}from"./create-organization-dialog-Bw7JkHCW.js";import"./User01-Dl4j8Eui.js";import"./alert-dialog-CIdU20ao.js";import"./form-CccEC3cm.js";import"./label-C6smVCIk.js";import"./spinner-BFdTwge6.js";import"./useMutation-oWI4nFQG.js";function V(t){const e=f.c(10),{children:n,className:l,onNavigate:i,showHoverRing:a}=t,c=a===void 0?!1:a;let o;e[0]!==i?(o=j=>{i&&i(j)},e[0]=i,e[1]=o):o=e[1];const m=o,x=i&&"cursor-pointer",r=c&&"hover:ring-2 hover:ring-primary";let d;e[2]!==l||e[3]!==x||e[4]!==r?(d=y("group transition-all flex flex-col gap-0",x,r,l),e[2]=l,e[3]=x,e[4]=r,e[5]=d):d=e[5];let g;return e[6]!==n||e[7]!==m||e[8]!==d?(g=s.jsx(k,{className:d,onClick:m,children:n}),e[6]=n,e[7]=m,e[8]=d,e[9]=g):g=e[9],g}function X(t){const e=f.c(7),{url:n,fallback:l,shape:i,size:a,objectFit:c,className:o}=t,m=i===void 0?"square":i,x=a===void 0?"lg":a,r=c===void 0?"contain":c;let d;return e[0]!==o||e[1]!==l||e[2]!==r||e[3]!==m||e[4]!==x||e[5]!==n?(d=s.jsx(G,{url:n,fallback:l,shape:m,size:x,objectFit:r,className:o}),e[0]=o,e[1]=l,e[2]=r,e[3]=m,e[4]=x,e[5]=n,e[6]=d):d=e[6],d}function Y(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("p-4 flex flex-col gap-4",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("div",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function J(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("font-medium truncate",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("p",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function K(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("text-sm text-muted-foreground truncate",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("h3",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function W(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("flex flex-col gap-[2px]",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("div",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function Z(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("flex justify-between items-start",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("div",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function ee(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("p-4 border-t border-border flex justify-between items-center",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("div",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function te(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("flex items-center text-xs text-muted-foreground",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("div",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function se(){const t=f.c(3);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx("div",{className:"flex justify-between items-start",children:s.jsx("div",{className:"h-12 w-12 bg-muted rounded-lg animate-pulse"})}),t[0]=e):e=t[0];let n;t[1]===Symbol.for("react.memo_cache_sentinel")?(n=s.jsxs("div",{className:"p-4 flex flex-col gap-4",children:[e,s.jsxs("div",{className:"flex flex-col gap-[2px]",children:[s.jsx("div",{className:"h-4 w-32 bg-muted rounded-lg animate-pulse"}),s.jsx("div",{className:"h-4 w-40 bg-muted rounded-lg animate-pulse"})]})]}),t[1]=n):n=t[1];let l;return t[2]===Symbol.for("react.memo_cache_sentinel")?(l=s.jsxs(k,{className:"group transition-colors flex flex-col",children:[n,s.jsxs("div",{className:"p-4 border-t border-border flex justify-between items-center",children:[s.jsx("div",{className:"h-6 w-6 bg-muted rounded-full animate-pulse"}),s.jsx("div",{className:"h-6 w-6 bg-muted rounded-full animate-pulse -ml-2"})]})]}),t[2]=l):l=t[2],l}const u=Object.assign(V,{Avatar:X,AvatarSection:Z,Header:Y,Title:J,Subtitle:K,Content:W,Footer:ee,Badge:te,Skeleton:se}),ie={0:"gap-0",1:"gap-1",2:"gap-2",3:"gap-3",4:"gap-4",5:"gap-5",6:"gap-6",8:"gap-8"},le={1:"grid-cols-1",2:"grid-cols-2",3:"grid-cols-3",4:"grid-cols-4",5:"grid-cols-5",6:"grid-cols-6",7:"grid-cols-7",8:"grid-cols-8"},ne={1:"@min-3xl:grid-cols-1",2:"@min-3xl:grid-cols-2",3:"@min-3xl:grid-cols-3",4:"@min-3xl:grid-cols-4",5:"@min-3xl:grid-cols-5",6:"@min-3xl:grid-cols-6",7:"@min-3xl:grid-cols-7",8:"@min-3xl:grid-cols-8"},ae={1:"@min-6xl:grid-cols-1",2:"@min-6xl:grid-cols-2",3:"@min-6xl:grid-cols-3",4:"@min-6xl:grid-cols-4",5:"@min-6xl:grid-cols-5",6:"@min-6xl:grid-cols-6",7:"@min-6xl:grid-cols-7",8:"@min-6xl:grid-cols-8"},re={1:"@min-7xl:grid-cols-1",2:"@min-7xl:grid-cols-2",3:"@min-7xl:grid-cols-3",4:"@min-7xl:grid-cols-4",5:"@min-7xl:grid-cols-5",6:"@min-7xl:grid-cols-6",7:"@min-7xl:grid-cols-7",8:"@min-7xl:grid-cols-8"},oe={1:"@min-8xl:grid-cols-1",2:"@min-8xl:grid-cols-2",3:"@min-8xl:grid-cols-3",4:"@min-8xl:grid-cols-4",5:"@min-8xl:grid-cols-5",6:"@min-8xl:grid-cols-6",7:"@min-8xl:grid-cols-7",8:"@min-8xl:grid-cols-8"};function L(t){const e=f.c(13),{children:n,columns:l,gap:i,className:a}=t;let c;e[0]!==l?(c=l===void 0?{sm:2,md:3,lg:4}:l,e[0]=l,e[1]=c):c=e[1];const o=c,x=ie[i===void 0?4:i],r=o.sm&&le[o.sm],d=o.md&&ne[o.md],g=o.lg&&ae[o.lg],j=o.xl&&re[o.xl],v=o["2xl"]&&oe[o["2xl"]];let N;e[2]!==a||e[3]!==x||e[4]!==r||e[5]!==d||e[6]!==g||e[7]!==j||e[8]!==v?(N=y("w-full grid",x,r,d,g,j,v,a),e[2]=a,e[3]=x,e[4]=r,e[5]=d,e[6]=g,e[7]=j,e[8]=v,e[9]=N):N=e[9];const b=N;let h;return e[10]!==n||e[11]!==b?(h=s.jsx("div",{className:b,children:n}),e[10]=n,e[11]=b,e[12]=h):h=e[12],h}function ce(t){const e=f.c(9),{count:n,columns:l,gap:i,className:a}=t,c=n===void 0?8:n;let o;e[0]!==l?(o=l===void 0?{sm:2,md:3,lg:4}:l,e[0]=l,e[1]=o):o=e[1];const m=o,x=i===void 0?4:i;let r;e[2]!==c?(r=Array.from({length:c}).map(de),e[2]=c,e[3]=r):r=e[3];let d;return e[4]!==a||e[5]!==m||e[6]!==x||e[7]!==r?(d=s.jsx(L,{columns:m,gap:x,className:a,children:r}),e[4]=a,e[5]=m,e[6]=x,e[7]=r,e[8]=d):d=e[8],d}function de(t,e){return s.jsxs("div",{className:"bg-card hover:bg-accent transition-colors flex flex-col rounded-lg animate-pulse",children:[s.jsxs("div",{className:"p-4 flex flex-col gap-4",children:[s.jsx("div",{className:"h-12 w-12 bg-muted rounded-lg"}),s.jsx("div",{className:"h-4 w-32 bg-muted rounded-lg"}),s.jsx("div",{className:"h-4 w-32 bg-muted rounded-lg"})]}),s.jsxs("div",{className:"p-4 border-t border-border flex items-center",children:[s.jsx("div",{className:"h-6 w-6 bg-muted rounded-full animate-pulse"}),s.jsx("div",{className:"h-6 w-6 bg-muted rounded-full animate-pulse -ml-2"}),s.jsx("div",{className:"h-6 w-6 bg-muted rounded-full animate-pulse -ml-2"})]})]},e)}const I=Object.assign(L,{Skeleton:ce});function me({invitation:t}){const[e,n]=C.useState(!1),[l,i]=C.useState(!1),a=F(),c=E(),o=async()=>{n(!0);try{const r=await _.organization.acceptInvitation({invitationId:t.id});if(r.error)w.error(r.error.message),n(!1);else{const d=await _.organization.setActive({organizationId:t.organizationId});d?.data?.slug?(w.success("Invitation accepted!"),c({to:"/$org",params:{org:d.data.slug}})):(w.success("Invitation accepted! Redirecting..."),c({to:"/"}))}}catch{w.error("Failed to accept invitation"),n(!1)}},m=async()=>{i(!0);try{const r=await _.organization.rejectInvitation({invitationId:t.id});r.error?(w.error(r.error.message),i(!1)):(w.success("Invitation rejected"),await a.invalidateQueries(),i(!1))}catch{w.error("Failed to reject invitation"),i(!1)}},x=t.organizationName||t.organizationId;return s.jsxs(u,{className:"border-dashed",children:[s.jsxs(u.Header,{children:[s.jsx(u.AvatarSection,{children:s.jsx(u.Avatar,{url:"",fallback:x,size:"lg",objectFit:"contain"})}),s.jsxs(u.Content,{children:[s.jsx(u.Subtitle,{children:"You've been invited to join"}),s.jsx(u.Title,{children:x})]})]}),s.jsx(u.Footer,{className:"border-t border-dashed",children:s.jsxs("div",{className:"flex h-3.5 items-center gap-2 w-full",children:[s.jsx($,{onClick:o,disabled:e||l,className:"flex-1",size:"sm",children:e?"Accepting...":s.jsxs(s.Fragment,{children:[s.jsx(q,{size:16}),"Accept"]})}),s.jsx($,{variant:"outline",onClick:m,disabled:e||l,className:"flex-1",size:"sm",children:l?"Declining...":s.jsxs(s.Fragment,{children:[s.jsx(T,{size:16}),"Decline"]})})]})})]})}function xe({query:t}){const e=C.useContext(O),{data:n}=e.hooks.useListUserInvitations(),i=(n??[]).filter(c=>c.status==="pending"&&new Date(c.expiresAt)>new Date),a=t?(()=>{const c=t.toLowerCase();return i.filter(o=>o.organizationName?.toLowerCase().includes(c)||o.organizationId.toLowerCase().includes(c))})():i;return a.length===0?null:s.jsxs("div",{className:"mb-16",children:[s.jsx("h2",{className:"text-lg font-medium pb-2 border-b border-border/50 mb-6 px-2",children:"Invitations"}),s.jsx(I,{columns:{sm:2,md:3,lg:4},children:a.map(c=>s.jsx(me,{invitation:c},c.id))})]})}function ue(t){const e=f.c(14),{query:n}=t,{data:l}=_.useListOrganizations(),i=E();let a;e[0]!==l||e[1]!==n?(a=l?n?(()=>{const r=n.toLowerCase();return l.filter(d=>d.name.toLowerCase().includes(r)||d.slug.toLowerCase().includes(r))})():l:[],e[0]=l,e[1]=n,e[2]=a):a=e[2];const c=a;if(!l||l.length===0){let r;return e[3]===Symbol.for("react.memo_cache_sentinel")?(r=s.jsx("div",{className:"flex flex-col items-center justify-center min-h-[400px] gap-4",children:s.jsx("div",{className:"text-sm text-muted-foreground text-center",children:"No organizations yet. Create your first organization to get started."})}),e[3]=r):r=e[3],r}if(c.length===0){let r;return e[4]!==n?(r=s.jsx("div",{className:"flex flex-col items-center justify-center min-h-[400px] gap-4",children:s.jsxs("div",{className:"text-sm text-muted-foreground text-center",children:['No organizations found matching "',n,'".']})}),e[4]=n,e[5]=r):r=e[5],r}let o;e[6]===Symbol.for("react.memo_cache_sentinel")?(o={sm:2,md:3,lg:4},e[6]=o):o=e[6];let m;if(e[7]!==c||e[8]!==i){let r;e[10]!==i?(r=d=>s.jsxs(u,{onNavigate:()=>i({to:"/$org",params:{org:d.slug}}),children:[s.jsxs(u.Header,{children:[s.jsx(u.AvatarSection,{children:s.jsx(u.Avatar,{url:d.logo||"",fallback:d.name,size:"lg",objectFit:"contain"})}),s.jsxs(u.Content,{children:[s.jsxs(u.Subtitle,{children:["@",d.slug]}),s.jsx(u.Title,{children:d.name})]})]}),s.jsx(u.Footer,{children:s.jsxs("div",{className:"flex h-3.5 items-center text-xs text-muted-foreground",children:["Created:"," ",new Date(d.createdAt).toLocaleDateString(void 0,{year:"numeric",month:"short",day:"numeric"})]})})]},d.id),e[10]=i,e[11]=r):r=e[11],m=c.map(r),e[7]=c,e[8]=i,e[9]=m}else m=e[9];let x;return e[12]!==m?(x=s.jsx(I,{columns:o,children:m}),e[12]=m,e[13]=x):x=e[13],x}function fe(t){const e=f.c(3),{error:n}=t;let l;e[0]===Symbol.for("react.memo_cache_sentinel")?(l=s.jsx(Q,{size:24,className:"text-destructive"}),e[0]=l):l=e[0];let i;return e[1]!==n.message?(i=s.jsxs("div",{className:"flex flex-col items-center justify-center min-h-[400px] gap-4",children:[l,s.jsxs("div",{className:"text-sm text-muted-foreground text-center",children:["Error loading organizations: ",n.message]})]}),e[1]=n.message,e[2]=i):i=e[2],i}function ge(){const t=f.c(27),{error:e,isPending:n}=_.useListOrganizations(),[l,i]=C.useState(""),[a,c]=C.useState(!1),o=C.useDeferredValue(l);if(n){let p;return t[0]===Symbol.for("react.memo_cache_sentinel")?(p=s.jsx("div",{className:"max-w-6xl mx-auto p-4 md:p-8",children:s.jsx("div",{className:"@container",children:s.jsx(I.Skeleton,{count:8,columns:{sm:2,md:3,lg:4}})})}),t[0]=p):p=t[0],p}if(e){let p;return t[1]!==e?(p=s.jsx("div",{className:"max-w-6xl mx-auto p-4 md:p-8",children:s.jsx(fe,{error:e})}),t[1]=e,t[2]=p):p=t[2],p}let m;t[3]!==o?(m=s.jsx(C.Suspense,{fallback:null,children:s.jsx(xe,{query:o})}),t[3]=o,t[4]=m):m=t[4];let x;t[5]===Symbol.for("react.memo_cache_sentinel")?(x=s.jsx("h2",{className:"text-lg font-medium",children:"My organizations"}),t[5]=x):x=t[5];let r;t[6]===Symbol.for("react.memo_cache_sentinel")?(r=s.jsx(M,{size:14,className:"absolute left-2.5 top-1/2 -translate-y-1/2 text-muted-foreground"}),t[6]=r):r=t[6];let d;t[7]===Symbol.for("react.memo_cache_sentinel")?(d=p=>i(p.target.value),t[7]=d):d=t[7];let g;t[8]!==l?(g=s.jsxs("div",{className:"relative flex-1 sm:flex-initial",children:[r,s.jsx(U,{className:"pl-8 h-8 w-full sm:w-52 border-none shadow-none focus-visible:ring-0",placeholder:"Search organizations...",value:l,onChange:d})]}),t[8]=l,t[9]=g):g=t[9];let j;t[10]===Symbol.for("react.memo_cache_sentinel")?(j=s.jsxs($,{size:"sm",onClick:()=>c(!0),children:[s.jsx(B,{size:16}),s.jsx("span",{className:"hidden sm:inline",children:"New organization"})]}),t[10]=j):j=t[10];let v;t[11]!==g?(v=s.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-3 pb-2 border-b border-border/50 mb-6 px-2",children:[x,s.jsxs("div",{className:"flex items-center gap-3",children:[g,j]})]}),t[11]=g,t[12]=v):v=t[12];let N;t[13]===Symbol.for("react.memo_cache_sentinel")?(N=s.jsx(I.Skeleton,{count:8,columns:{sm:2,md:3,lg:4}}),t[13]=N):N=t[13];let b;t[14]!==o?(b=s.jsx(C.Suspense,{fallback:N,children:s.jsx(ue,{query:o})}),t[14]=o,t[15]=b):b=t[15];let h;t[16]!==v||t[17]!==b?(h=s.jsxs("div",{children:[v,b]}),t[16]=v,t[17]=b,t[18]=h):h=t[18];let S;t[19]!==m||t[20]!==h?(S=s.jsxs("div",{className:"@container",children:[m,h]}),t[19]=m,t[20]=h,t[21]=S):S=t[21];let z;t[22]!==a?(z=s.jsx(P,{open:a,onOpenChange:c}),t[22]=a,t[23]=z):z=t[23];let A;return t[24]!==S||t[25]!==z?(A=s.jsxs("div",{className:"max-w-6xl mx-auto p-4 md:p-8",children:[S,z]}),t[24]=S,t[25]=z,t[26]=A):A=t[26],A}function ke(){const t=f.c(4),e=D(),{data:n,isPending:l}=_.useListOrganizations();if(e.localMode){if(l){let c;return t[0]===Symbol.for("react.memo_cache_sentinel")?(c=s.jsx(R,{}),t[0]=c):c=t[0],c}const a=n?.[0];if(a?.slug){const c=`/${a.slug}/org-admin`;let o;return t[1]!==c?(o=s.jsx(H,{to:c,replace:!0}),t[1]=c,t[2]=o):o=t[2],o}}let i;return t[3]===Symbol.for("react.memo_cache_sentinel")?(i=s.jsx("div",{className:"min-h-full",children:s.jsx(ge,{})}),t[3]=i):i=t[3],i}export{ke as default};
1
+ import{c as f,D as y,j as s,f as _,r as C,B as $,bM as O,e as E,w as F,v as w,y as D,S as R,N as H}from"./index-Di6oLb1g.js";import{C as k}from"./card-BkMKAjKJ.js";import{A as G}from"./avatar-CahK8DWE.js";import{i as Q}from"./AlertCircle-D2rRA9CS.js";import{i as q}from"./Check-CecxQkQE.js";import{s as B}from"./Plus-D9CNWrFQ.js";import{i as M}from"./SearchMd-BH_J7-7p.js";import{s as T}from"./XClose-BzyTilGE.js";import{I as U}from"./input-DQ4QcwHR.js";import{C as P}from"./create-organization-dialog--yeW4Rp3.js";import"./User01-BloSEKZw.js";import"./alert-dialog-DnwDlp7T.js";import"./form-edx7u0Be.js";import"./label-BGeQL0ka.js";import"./spinner-uIlWy8Tn.js";import"./useMutation-BOcaN318.js";function V(t){const e=f.c(10),{children:n,className:l,onNavigate:i,showHoverRing:a}=t,c=a===void 0?!1:a;let o;e[0]!==i?(o=j=>{i&&i(j)},e[0]=i,e[1]=o):o=e[1];const m=o,x=i&&"cursor-pointer",r=c&&"hover:ring-2 hover:ring-primary";let d;e[2]!==l||e[3]!==x||e[4]!==r?(d=y("group transition-all flex flex-col gap-0",x,r,l),e[2]=l,e[3]=x,e[4]=r,e[5]=d):d=e[5];let g;return e[6]!==n||e[7]!==m||e[8]!==d?(g=s.jsx(k,{className:d,onClick:m,children:n}),e[6]=n,e[7]=m,e[8]=d,e[9]=g):g=e[9],g}function X(t){const e=f.c(7),{url:n,fallback:l,shape:i,size:a,objectFit:c,className:o}=t,m=i===void 0?"square":i,x=a===void 0?"lg":a,r=c===void 0?"contain":c;let d;return e[0]!==o||e[1]!==l||e[2]!==r||e[3]!==m||e[4]!==x||e[5]!==n?(d=s.jsx(G,{url:n,fallback:l,shape:m,size:x,objectFit:r,className:o}),e[0]=o,e[1]=l,e[2]=r,e[3]=m,e[4]=x,e[5]=n,e[6]=d):d=e[6],d}function Y(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("p-4 flex flex-col gap-4",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("div",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function J(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("font-medium truncate",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("p",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function K(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("text-sm text-muted-foreground truncate",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("h3",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function W(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("flex flex-col gap-[2px]",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("div",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function Z(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("flex justify-between items-start",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("div",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function ee(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("p-4 border-t border-border flex justify-between items-center",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("div",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function te(t){const e=f.c(5),{children:n,className:l}=t;let i;e[0]!==l?(i=y("flex items-center text-xs text-muted-foreground",l),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==n||e[3]!==i?(a=s.jsx("div",{className:i,children:n}),e[2]=n,e[3]=i,e[4]=a):a=e[4],a}function se(){const t=f.c(3);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx("div",{className:"flex justify-between items-start",children:s.jsx("div",{className:"h-12 w-12 bg-muted rounded-lg animate-pulse"})}),t[0]=e):e=t[0];let n;t[1]===Symbol.for("react.memo_cache_sentinel")?(n=s.jsxs("div",{className:"p-4 flex flex-col gap-4",children:[e,s.jsxs("div",{className:"flex flex-col gap-[2px]",children:[s.jsx("div",{className:"h-4 w-32 bg-muted rounded-lg animate-pulse"}),s.jsx("div",{className:"h-4 w-40 bg-muted rounded-lg animate-pulse"})]})]}),t[1]=n):n=t[1];let l;return t[2]===Symbol.for("react.memo_cache_sentinel")?(l=s.jsxs(k,{className:"group transition-colors flex flex-col",children:[n,s.jsxs("div",{className:"p-4 border-t border-border flex justify-between items-center",children:[s.jsx("div",{className:"h-6 w-6 bg-muted rounded-full animate-pulse"}),s.jsx("div",{className:"h-6 w-6 bg-muted rounded-full animate-pulse -ml-2"})]})]}),t[2]=l):l=t[2],l}const u=Object.assign(V,{Avatar:X,AvatarSection:Z,Header:Y,Title:J,Subtitle:K,Content:W,Footer:ee,Badge:te,Skeleton:se}),ie={0:"gap-0",1:"gap-1",2:"gap-2",3:"gap-3",4:"gap-4",5:"gap-5",6:"gap-6",8:"gap-8"},le={1:"grid-cols-1",2:"grid-cols-2",3:"grid-cols-3",4:"grid-cols-4",5:"grid-cols-5",6:"grid-cols-6",7:"grid-cols-7",8:"grid-cols-8"},ne={1:"@min-3xl:grid-cols-1",2:"@min-3xl:grid-cols-2",3:"@min-3xl:grid-cols-3",4:"@min-3xl:grid-cols-4",5:"@min-3xl:grid-cols-5",6:"@min-3xl:grid-cols-6",7:"@min-3xl:grid-cols-7",8:"@min-3xl:grid-cols-8"},ae={1:"@min-6xl:grid-cols-1",2:"@min-6xl:grid-cols-2",3:"@min-6xl:grid-cols-3",4:"@min-6xl:grid-cols-4",5:"@min-6xl:grid-cols-5",6:"@min-6xl:grid-cols-6",7:"@min-6xl:grid-cols-7",8:"@min-6xl:grid-cols-8"},re={1:"@min-7xl:grid-cols-1",2:"@min-7xl:grid-cols-2",3:"@min-7xl:grid-cols-3",4:"@min-7xl:grid-cols-4",5:"@min-7xl:grid-cols-5",6:"@min-7xl:grid-cols-6",7:"@min-7xl:grid-cols-7",8:"@min-7xl:grid-cols-8"},oe={1:"@min-8xl:grid-cols-1",2:"@min-8xl:grid-cols-2",3:"@min-8xl:grid-cols-3",4:"@min-8xl:grid-cols-4",5:"@min-8xl:grid-cols-5",6:"@min-8xl:grid-cols-6",7:"@min-8xl:grid-cols-7",8:"@min-8xl:grid-cols-8"};function L(t){const e=f.c(13),{children:n,columns:l,gap:i,className:a}=t;let c;e[0]!==l?(c=l===void 0?{sm:2,md:3,lg:4}:l,e[0]=l,e[1]=c):c=e[1];const o=c,x=ie[i===void 0?4:i],r=o.sm&&le[o.sm],d=o.md&&ne[o.md],g=o.lg&&ae[o.lg],j=o.xl&&re[o.xl],v=o["2xl"]&&oe[o["2xl"]];let N;e[2]!==a||e[3]!==x||e[4]!==r||e[5]!==d||e[6]!==g||e[7]!==j||e[8]!==v?(N=y("w-full grid",x,r,d,g,j,v,a),e[2]=a,e[3]=x,e[4]=r,e[5]=d,e[6]=g,e[7]=j,e[8]=v,e[9]=N):N=e[9];const b=N;let h;return e[10]!==n||e[11]!==b?(h=s.jsx("div",{className:b,children:n}),e[10]=n,e[11]=b,e[12]=h):h=e[12],h}function ce(t){const e=f.c(9),{count:n,columns:l,gap:i,className:a}=t,c=n===void 0?8:n;let o;e[0]!==l?(o=l===void 0?{sm:2,md:3,lg:4}:l,e[0]=l,e[1]=o):o=e[1];const m=o,x=i===void 0?4:i;let r;e[2]!==c?(r=Array.from({length:c}).map(de),e[2]=c,e[3]=r):r=e[3];let d;return e[4]!==a||e[5]!==m||e[6]!==x||e[7]!==r?(d=s.jsx(L,{columns:m,gap:x,className:a,children:r}),e[4]=a,e[5]=m,e[6]=x,e[7]=r,e[8]=d):d=e[8],d}function de(t,e){return s.jsxs("div",{className:"bg-card hover:bg-accent transition-colors flex flex-col rounded-lg animate-pulse",children:[s.jsxs("div",{className:"p-4 flex flex-col gap-4",children:[s.jsx("div",{className:"h-12 w-12 bg-muted rounded-lg"}),s.jsx("div",{className:"h-4 w-32 bg-muted rounded-lg"}),s.jsx("div",{className:"h-4 w-32 bg-muted rounded-lg"})]}),s.jsxs("div",{className:"p-4 border-t border-border flex items-center",children:[s.jsx("div",{className:"h-6 w-6 bg-muted rounded-full animate-pulse"}),s.jsx("div",{className:"h-6 w-6 bg-muted rounded-full animate-pulse -ml-2"}),s.jsx("div",{className:"h-6 w-6 bg-muted rounded-full animate-pulse -ml-2"})]})]},e)}const I=Object.assign(L,{Skeleton:ce});function me({invitation:t}){const[e,n]=C.useState(!1),[l,i]=C.useState(!1),a=F(),c=E(),o=async()=>{n(!0);try{const r=await _.organization.acceptInvitation({invitationId:t.id});if(r.error)w.error(r.error.message),n(!1);else{const d=await _.organization.setActive({organizationId:t.organizationId});d?.data?.slug?(w.success("Invitation accepted!"),c({to:"/$org",params:{org:d.data.slug}})):(w.success("Invitation accepted! Redirecting..."),c({to:"/"}))}}catch{w.error("Failed to accept invitation"),n(!1)}},m=async()=>{i(!0);try{const r=await _.organization.rejectInvitation({invitationId:t.id});r.error?(w.error(r.error.message),i(!1)):(w.success("Invitation rejected"),await a.invalidateQueries(),i(!1))}catch{w.error("Failed to reject invitation"),i(!1)}},x=t.organizationName||t.organizationId;return s.jsxs(u,{className:"border-dashed",children:[s.jsxs(u.Header,{children:[s.jsx(u.AvatarSection,{children:s.jsx(u.Avatar,{url:"",fallback:x,size:"lg",objectFit:"contain"})}),s.jsxs(u.Content,{children:[s.jsx(u.Subtitle,{children:"You've been invited to join"}),s.jsx(u.Title,{children:x})]})]}),s.jsx(u.Footer,{className:"border-t border-dashed",children:s.jsxs("div",{className:"flex h-3.5 items-center gap-2 w-full",children:[s.jsx($,{onClick:o,disabled:e||l,className:"flex-1",size:"sm",children:e?"Accepting...":s.jsxs(s.Fragment,{children:[s.jsx(q,{size:16}),"Accept"]})}),s.jsx($,{variant:"outline",onClick:m,disabled:e||l,className:"flex-1",size:"sm",children:l?"Declining...":s.jsxs(s.Fragment,{children:[s.jsx(T,{size:16}),"Decline"]})})]})})]})}function xe({query:t}){const e=C.useContext(O),{data:n}=e.hooks.useListUserInvitations(),i=(n??[]).filter(c=>c.status==="pending"&&new Date(c.expiresAt)>new Date),a=t?(()=>{const c=t.toLowerCase();return i.filter(o=>o.organizationName?.toLowerCase().includes(c)||o.organizationId.toLowerCase().includes(c))})():i;return a.length===0?null:s.jsxs("div",{className:"mb-16",children:[s.jsx("h2",{className:"text-lg font-medium pb-2 border-b border-border/50 mb-6 px-2",children:"Invitations"}),s.jsx(I,{columns:{sm:2,md:3,lg:4},children:a.map(c=>s.jsx(me,{invitation:c},c.id))})]})}function ue(t){const e=f.c(14),{query:n}=t,{data:l}=_.useListOrganizations(),i=E();let a;e[0]!==l||e[1]!==n?(a=l?n?(()=>{const r=n.toLowerCase();return l.filter(d=>d.name.toLowerCase().includes(r)||d.slug.toLowerCase().includes(r))})():l:[],e[0]=l,e[1]=n,e[2]=a):a=e[2];const c=a;if(!l||l.length===0){let r;return e[3]===Symbol.for("react.memo_cache_sentinel")?(r=s.jsx("div",{className:"flex flex-col items-center justify-center min-h-[400px] gap-4",children:s.jsx("div",{className:"text-sm text-muted-foreground text-center",children:"No organizations yet. Create your first organization to get started."})}),e[3]=r):r=e[3],r}if(c.length===0){let r;return e[4]!==n?(r=s.jsx("div",{className:"flex flex-col items-center justify-center min-h-[400px] gap-4",children:s.jsxs("div",{className:"text-sm text-muted-foreground text-center",children:['No organizations found matching "',n,'".']})}),e[4]=n,e[5]=r):r=e[5],r}let o;e[6]===Symbol.for("react.memo_cache_sentinel")?(o={sm:2,md:3,lg:4},e[6]=o):o=e[6];let m;if(e[7]!==c||e[8]!==i){let r;e[10]!==i?(r=d=>s.jsxs(u,{onNavigate:()=>i({to:"/$org",params:{org:d.slug}}),children:[s.jsxs(u.Header,{children:[s.jsx(u.AvatarSection,{children:s.jsx(u.Avatar,{url:d.logo||"",fallback:d.name,size:"lg",objectFit:"contain"})}),s.jsxs(u.Content,{children:[s.jsxs(u.Subtitle,{children:["@",d.slug]}),s.jsx(u.Title,{children:d.name})]})]}),s.jsx(u.Footer,{children:s.jsxs("div",{className:"flex h-3.5 items-center text-xs text-muted-foreground",children:["Created:"," ",new Date(d.createdAt).toLocaleDateString(void 0,{year:"numeric",month:"short",day:"numeric"})]})})]},d.id),e[10]=i,e[11]=r):r=e[11],m=c.map(r),e[7]=c,e[8]=i,e[9]=m}else m=e[9];let x;return e[12]!==m?(x=s.jsx(I,{columns:o,children:m}),e[12]=m,e[13]=x):x=e[13],x}function fe(t){const e=f.c(3),{error:n}=t;let l;e[0]===Symbol.for("react.memo_cache_sentinel")?(l=s.jsx(Q,{size:24,className:"text-destructive"}),e[0]=l):l=e[0];let i;return e[1]!==n.message?(i=s.jsxs("div",{className:"flex flex-col items-center justify-center min-h-[400px] gap-4",children:[l,s.jsxs("div",{className:"text-sm text-muted-foreground text-center",children:["Error loading organizations: ",n.message]})]}),e[1]=n.message,e[2]=i):i=e[2],i}function ge(){const t=f.c(27),{error:e,isPending:n}=_.useListOrganizations(),[l,i]=C.useState(""),[a,c]=C.useState(!1),o=C.useDeferredValue(l);if(n){let p;return t[0]===Symbol.for("react.memo_cache_sentinel")?(p=s.jsx("div",{className:"max-w-6xl mx-auto p-4 md:p-8",children:s.jsx("div",{className:"@container",children:s.jsx(I.Skeleton,{count:8,columns:{sm:2,md:3,lg:4}})})}),t[0]=p):p=t[0],p}if(e){let p;return t[1]!==e?(p=s.jsx("div",{className:"max-w-6xl mx-auto p-4 md:p-8",children:s.jsx(fe,{error:e})}),t[1]=e,t[2]=p):p=t[2],p}let m;t[3]!==o?(m=s.jsx(C.Suspense,{fallback:null,children:s.jsx(xe,{query:o})}),t[3]=o,t[4]=m):m=t[4];let x;t[5]===Symbol.for("react.memo_cache_sentinel")?(x=s.jsx("h2",{className:"text-lg font-medium",children:"My organizations"}),t[5]=x):x=t[5];let r;t[6]===Symbol.for("react.memo_cache_sentinel")?(r=s.jsx(M,{size:14,className:"absolute left-2.5 top-1/2 -translate-y-1/2 text-muted-foreground"}),t[6]=r):r=t[6];let d;t[7]===Symbol.for("react.memo_cache_sentinel")?(d=p=>i(p.target.value),t[7]=d):d=t[7];let g;t[8]!==l?(g=s.jsxs("div",{className:"relative flex-1 sm:flex-initial",children:[r,s.jsx(U,{className:"pl-8 h-8 w-full sm:w-52 border-none shadow-none focus-visible:ring-0",placeholder:"Search organizations...",value:l,onChange:d})]}),t[8]=l,t[9]=g):g=t[9];let j;t[10]===Symbol.for("react.memo_cache_sentinel")?(j=s.jsxs($,{size:"sm",onClick:()=>c(!0),children:[s.jsx(B,{size:16}),s.jsx("span",{className:"hidden sm:inline",children:"New organization"})]}),t[10]=j):j=t[10];let v;t[11]!==g?(v=s.jsxs("div",{className:"flex flex-col sm:flex-row sm:items-center justify-between gap-3 pb-2 border-b border-border/50 mb-6 px-2",children:[x,s.jsxs("div",{className:"flex items-center gap-3",children:[g,j]})]}),t[11]=g,t[12]=v):v=t[12];let N;t[13]===Symbol.for("react.memo_cache_sentinel")?(N=s.jsx(I.Skeleton,{count:8,columns:{sm:2,md:3,lg:4}}),t[13]=N):N=t[13];let b;t[14]!==o?(b=s.jsx(C.Suspense,{fallback:N,children:s.jsx(ue,{query:o})}),t[14]=o,t[15]=b):b=t[15];let h;t[16]!==v||t[17]!==b?(h=s.jsxs("div",{children:[v,b]}),t[16]=v,t[17]=b,t[18]=h):h=t[18];let S;t[19]!==m||t[20]!==h?(S=s.jsxs("div",{className:"@container",children:[m,h]}),t[19]=m,t[20]=h,t[21]=S):S=t[21];let z;t[22]!==a?(z=s.jsx(P,{open:a,onOpenChange:c}),t[22]=a,t[23]=z):z=t[23];let A;return t[24]!==S||t[25]!==z?(A=s.jsxs("div",{className:"max-w-6xl mx-auto p-4 md:p-8",children:[S,z]}),t[24]=S,t[25]=z,t[26]=A):A=t[26],A}function ke(){const t=f.c(4),e=D(),{data:n,isPending:l}=_.useListOrganizations();if(e.localMode){if(l){let c;return t[0]===Symbol.for("react.memo_cache_sentinel")?(c=s.jsx(R,{}),t[0]=c):c=t[0],c}const a=n?.[0];if(a?.slug){const c=`/${a.slug}/org-admin`;let o;return t[1]!==c?(o=s.jsx(H,{to:c,replace:!0}),t[1]=c,t[2]=o):o=t[2],o}}let i;return t[3]===Symbol.for("react.memo_cache_sentinel")?(i=s.jsx("div",{className:"min-h-full",children:s.jsx(ge,{})}),t[3]=i):i=t[3],i}export{ke as default};
@@ -1 +1 @@
1
- import{C as i,L as l,O as u,P as n,V as C,a as c,h as P,i as p,b as m,p as M,s as E,u as L}from"./index-BjxqoU_w.js";import{E as T,b as g,a as O,c as S,u as x,d as _,e as R}from"./use-collections-Zp8eOwPm.js";import{u as y,a as b,b as A}from"./use-connection-B-vgK3kN.js";import{S as e}from"./constants-C5g6K3-0.js";import{K as I,a as h,W as V,c as U,g as K,b as W,d as N,e as Q,i as w,u as F,f as Y}from"./constants-C5g6K3-0.js";import{u as G,a as k,b as v,c as B,d as H}from"./use-mcp-tools-DNLvgz5O.js";import{l as q,r as z,u as X,a as Z,b as $}from"./use-mcp-resources-B8ERGBbF.js";import{g as es,l as as,u as ts,a as os}from"./use-mcp-prompts-qi4FHPHh.js";import{u as is,a as ls,b as us}from"./use-virtual-mcp-BnUWdVw5.js";import{A as Cs,D as cs}from"./decopilot-events-Brt4gAR6.js";import{D as ps,a as ms,c as Ms,e as Es,g as Ls,s as ds}from"./usage-BW6ztpN6.js";import"./useMutation-oWI4nFQG.js";import"./useQuery-CmP1G4DA.js";export{Cs as ALL_DECOPILOT_EVENT_TYPES,i as ConnectionEntitySchema,cs as DECOPILOT_EVENTS,ps as DEFAULT_MODEL_PREFERENCES,T as EMPTY_COLLECTION_LIST_RESULT,I as KEYS,l as Locator,u as ORG_ADMIN_PROJECT_SLUG,n as ProjectContextProvider,h as SELF_MCP_ALIAS_ID,e as StreamableHTTPClientTransport,C as VirtualMCPEntitySchema,V as WellKnownOrgMCPId,ms as addUsage,c as authenticateMcp,g as buildCollectionQueryKey,O as buildOrderByExpression,S as buildWhereExpression,Ms as calculateUsageStats,U as createMCPClient,Es as emptyUsageStats,Ls as getCostFromUsage,K as getDecopilotId,es as getPrompt,W as getWellKnownCommunityRegistryConnection,N as getWellKnownDecopilotVirtualMCP,Q as getWellKnownRegistryConnection,P as handleOAuthCallback,p as isConnectionAuthenticated,w as isDecopilot,m as isStdioParameters,as as listPrompts,q as listResources,M as parseVirtualUrl,z as readResource,ds as selectDefaultModel,E as setOAuthRedirectOrigin,x as useCollectionActions,_ as useCollectionItem,R as useCollectionList,y as useConnection,b as useConnectionActions,A as useConnections,F as useMCPClient,Y as useMCPClientOptional,ts as useMCPPromptsList,os as useMCPPromptsListQuery,X as useMCPReadResource,Z as useMCPResourcesList,$ as useMCPResourcesListQuery,G as useMCPToolCall,k as useMCPToolCallMutation,v as useMCPToolCallQuery,B as useMCPToolsList,H as useMCPToolsListQuery,L as useProjectContext,is as useVirtualMCP,ls as useVirtualMCPActions,us as useVirtualMCPs};
1
+ import{C as i,L as l,O as u,P as n,V as C,a as c,h as P,i as p,b as m,p as M,s as E,u as L}from"./index-Di6oLb1g.js";import{E as T,b as g,a as O,c as S,u as x,d as _,e as R}from"./use-collections-CojcRvND.js";import{u as y,a as b,b as A}from"./use-connection-CJIltDo3.js";import{S as e}from"./constants-kAo23sAc.js";import{K as I,a as h,W as V,c as U,g as K,b as W,d as N,e as Q,i as w,u as F,f as Y}from"./constants-kAo23sAc.js";import{u as G,a as k,b as v,c as B,d as H}from"./use-mcp-tools-BD0zsUGc.js";import{l as q,r as z,u as X,a as Z,b as $}from"./use-mcp-resources-BIFxFRhN.js";import{g as es,l as as,u as ts,a as os}from"./use-mcp-prompts-zeDoy0Xo.js";import{u as is,a as ls,b as us}from"./use-virtual-mcp-BdGbK3Wg.js";import{A as Cs,D as cs}from"./decopilot-events-Brt4gAR6.js";import{D as ps,a as ms,c as Ms,e as Es,g as Ls,s as ds}from"./usage-BW6ztpN6.js";import"./useMutation-BOcaN318.js";import"./useQuery-BrfnS-T_.js";export{Cs as ALL_DECOPILOT_EVENT_TYPES,i as ConnectionEntitySchema,cs as DECOPILOT_EVENTS,ps as DEFAULT_MODEL_PREFERENCES,T as EMPTY_COLLECTION_LIST_RESULT,I as KEYS,l as Locator,u as ORG_ADMIN_PROJECT_SLUG,n as ProjectContextProvider,h as SELF_MCP_ALIAS_ID,e as StreamableHTTPClientTransport,C as VirtualMCPEntitySchema,V as WellKnownOrgMCPId,ms as addUsage,c as authenticateMcp,g as buildCollectionQueryKey,O as buildOrderByExpression,S as buildWhereExpression,Ms as calculateUsageStats,U as createMCPClient,Es as emptyUsageStats,Ls as getCostFromUsage,K as getDecopilotId,es as getPrompt,W as getWellKnownCommunityRegistryConnection,N as getWellKnownDecopilotVirtualMCP,Q as getWellKnownRegistryConnection,P as handleOAuthCallback,p as isConnectionAuthenticated,w as isDecopilot,m as isStdioParameters,as as listPrompts,q as listResources,M as parseVirtualUrl,z as readResource,ds as selectDefaultModel,E as setOAuthRedirectOrigin,x as useCollectionActions,_ as useCollectionItem,R as useCollectionList,y as useConnection,b as useConnectionActions,A as useConnections,F as useMCPClient,Y as useMCPClientOptional,ts as useMCPPromptsList,os as useMCPPromptsListQuery,X as useMCPReadResource,Z as useMCPResourcesList,$ as useMCPResourcesListQuery,G as useMCPToolCall,k as useMCPToolCallMutation,v as useMCPToolCallQuery,B as useMCPToolsList,H as useMCPToolsListQuery,L as useProjectContext,is as useVirtualMCP,ls as useVirtualMCPActions,us as useVirtualMCPs};
@@ -1 +1 @@
1
- import{r as T,c as h,w as V,z as F,j as o,ab as G,D as g,ac as Q,ad as J,ae as U,af as X,ah as Y,ag as Z,B as P,M as ee,W as te,g as se,aL as ae}from"./index-BjxqoU_w.js";import{u as le}from"./useQuery-CmP1G4DA.js";import{u as ie}from"./useMutation-oWI4nFQG.js";import{a as D,u as B,c as L,b as I,T as M}from"./tooltip-SqkLa6wk.js";import{i as oe}from"./X-DvXlEl9E.js";const H=({size:l=24,color:e="currentColor",...t})=>T.createElement("svg",{viewBox:"0 0 24 24",width:l,height:l,stroke:e,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...t},T.createElement("path",{d:"M9 3v18M7.8 3h8.4c1.68 0 2.52 0 3.162.327a3 3 0 0 1 1.311 1.311C21 5.28 21 6.12 21 7.8v8.4c0 1.68 0 2.52-.327 3.162a3 3 0 0 1-1.311 1.311C18.72 21 17.88 21 16.2 21H7.8c-1.68 0-2.52 0-3.162-.327a3 3 0 0 1-1.311-1.311C3 18.72 3 17.88 3 16.2V7.8c0-1.68 0-2.52.327-3.162a3 3 0 0 1 1.311-1.311C5.28 3 6.12 3 7.8 3Z"}));H.displayName="LayoutLeft";const z=({size:l=24,color:e="currentColor",...t})=>T.createElement("svg",{viewBox:"0 0 24 24",width:l,height:l,stroke:e,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...t},T.createElement("path",{d:"M8 9.5h4M8 13h7m-3 8a9 9 0 1 0-8.342-5.616c.081.2.122.3.14.381a.907.907 0 0 1 .024.219c0 .083-.015.173-.045.353l-.593 3.558c-.062.373-.093.56-.035.694a.5.5 0 0 0 .262.262c.135.058.321.027.694-.035l3.558-.593c.18-.03.27-.045.353-.045.081 0 .14.006.219.024.08.018.18.059.38.14A8.973 8.973 0 0 0 12 21Z"}));z.displayName="MessageTextCircle02";function ne(l){try{return JSON.parse(l)}catch{return}}function R(l,e){const t=localStorage.getItem(l),a=t?ne(t):void 0,s=typeof e=="function"?e(a):a??e;if(a===void 0||s!==a)try{const i=JSON.stringify(s);localStorage.setItem(l,i)}catch{}return s}function re(l,e){const t=h.c(25),a=V();let s;t[0]!==l?(s=["localStorage",l],t[0]=l,t[1]=s):s=t[1];const i=s;let d,n;t[2]!==e||t[3]!==l?(d=()=>R(l,e),n=()=>R(l,e),t[2]=e,t[3]=l,t[4]=d,t[5]=n):(d=t[4],n=t[5]);let r;t[6]!==i||t[7]!==d||t[8]!==n?(r={queryKey:i,queryFn:d,initialData:n,staleTime:1/0,gcTime:1/0},t[6]=i,t[7]=d,t[8]=n,t[9]=r):r=t[9];const{data:u}=le(r);let f;t[10]!==l?(f=async v=>{const j=JSON.stringify(v);return localStorage.setItem(l,j),v},t[10]=l,t[11]=f):f=t[11];let m;t[12]!==a||t[13]!==i?(m=v=>{a.setQueryData(i,v)},t[12]=a,t[13]=i,t[14]=m):m=t[14];let c;t[15]!==f||t[16]!==m?(c={mutationFn:f,onSuccess:m},t[15]=f,t[16]=m,t[17]=c):c=t[17];const p=ie(c);let b;t[18]!==p||t[19]!==a||t[20]!==i?(b=v=>{const j=a.getQueryData(i),_=typeof v=="function"?v(j):v;p.mutate(_)},t[18]=p,t[19]=a,t[20]=i,t[21]=b):b=t[21];const S=b,x=u;let y;return t[22]!==S||t[23]!==x?(y=[x,S],t[22]=S,t[23]=x,t[24]=y):y=t[24],y}function ce(){const l=h.c(4);let e;l[0]===Symbol.for("react.memo_cache_sentinel")?(e=F.decoChatOpen(),l[0]=e):e=l[0];const[t,a]=re(e,de);let s;return l[1]!==t||l[2]!==a?(s=[t,a],l[1]=t,l[2]=a,l[3]=s):s=l[3],s}function de(l){return!!(l??!0)}function fe(l){const e=h.c(4);let t;e[0]!==l?({...t}=l,e[0]=l,e[1]=t):t=e[1];let a;return e[2]!==t?(a=o.jsx(G,{"data-slot":"sheet",...t}),e[2]=t,e[3]=a):a=e[3],a}function ue(l){const e=h.c(4);let t;e[0]!==l?({...t}=l,e[0]=l,e[1]=t):t=e[1];let a;return e[2]!==t?(a=o.jsx(X,{"data-slot":"sheet-portal",...t}),e[2]=t,e[3]=a):a=e[3],a}function me(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=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]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx(Z,{"data-slot":"sheet-overlay",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function pe(l){const e=h.c(17);let t,a,s,i;e[0]!==l?({className:a,children:t,side:i,...s}=l,e[0]=l,e[1]=t,e[2]=a,e[3]=s,e[4]=i):(t=e[1],a=e[2],s=e[3],i=e[4]);const d=i===void 0?"right":i;let n;e[5]===Symbol.for("react.memo_cache_sentinel")?(n=o.jsx(me,{}),e[5]=n):n=e[5];const r=d==="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",u=d==="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=d==="top"&&"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",m=d==="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 c;e[6]!==a||e[7]!==r||e[8]!==u||e[9]!==f||e[10]!==m?(c=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",r,u,f,m,a),e[6]=a,e[7]=r,e[8]=u,e[9]=f,e[10]=m,e[11]=c):c=e[11];let p;e[12]===Symbol.for("react.memo_cache_sentinel")?(p=o.jsxs(Y,{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(oe,{className:"size-4"}),o.jsx("span",{className:"sr-only",children:"Close"})]}),e[12]=p):p=e[12];let b;return e[13]!==t||e[14]!==s||e[15]!==c?(b=o.jsxs(ue,{children:[n,o.jsxs(Q,{"data-slot":"sheet-content",className:c,...s,children:[t,p]})]}),e[13]=t,e[14]=s,e[15]=c,e[16]=b):b=e[16],b}function be(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("flex flex-col gap-1.5 p-4",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-slot":"sheet-header",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function he(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("text-foreground font-semibold",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx(J,{"data-slot":"sheet-title",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function ge(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("text-muted-foreground text-sm",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx(U,{"data-slot":"sheet-description",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}const xe="sidebar_state",ve=3600*24*7,Ne="16rem",je="18rem",Se="3rem",we="b",K=T.createContext(null);function k(){const l=T.useContext(K);if(!l)throw new Error("useSidebar must be used within a SidebarProvider.");return l}function Le(l){const e=h.c(21),{defaultOpen:t,open:a,onOpenChange:s,children:i}=l,d=t===void 0?!0:t,n=B(),[r,u]=T.useState(!1),[f,m]=T.useState(d),c=a??f;let p;e[0]!==c||e[1]!==s?(p=O=>{const C=typeof O=="function"?O(c):O;s?s(C):m(C),document.cookie=`${xe}=${C}; path=/; max-age=${ve}`},e[0]=c,e[1]=s,e[2]=p):p=e[2];const b=p;let S;e[3]!==n||e[4]!==b?(S=()=>n?u(_e):b(ye),e[3]=n,e[4]=b,e[5]=S):S=e[5];const x=S;let y,v;e[6]!==x?(y=()=>{const O=C=>{if(C.key===we&&(C.metaKey||C.ctrlKey)){const E=C.target;if(E.tagName==="INPUT"||E.tagName==="TEXTAREA"||E.isContentEditable)return;C.preventDefault(),x()}};return globalThis.addEventListener("keydown",O),()=>globalThis.removeEventListener("keydown",O)},v=[x],e[6]=x,e[7]=y,e[8]=v):(y=e[7],v=e[8]),T.useEffect(y,v);const j=c?"expanded":"collapsed";let _;e[9]!==n||e[10]!==c||e[11]!==r||e[12]!==b||e[13]!==j||e[14]!==x?(_={state:j,open:c,setOpen:b,isMobile:n,openMobile:r,setOpenMobile:u,toggleSidebar:x},e[9]=n,e[10]=c,e[11]=r,e[12]=b,e[13]=j,e[14]=x,e[15]=_):_=e[15];const $=_;let N;e[16]!==i?(N=o.jsx(L,{delayDuration:0,children:i}),e[16]=i,e[17]=N):N=e[17];let w;return e[18]!==$||e[19]!==N?(w=o.jsx(K.Provider,{value:$,children:N}),e[18]=$,e[19]=N,e[20]=w):w=e[20],w}function ye(l){return!l}function _e(l){return!l}function He(l){const e=h.c(14);let t,a,s,i;e[0]!==l?({className:a,style:i,children:t,...s}=l,e[0]=l,e[1]=t,e[2]=a,e[3]=s,e[4]=i):(t=e[1],a=e[2],s=e[3],i=e[4]);let d;e[5]!==i?(d={"--sidebar-width":Ne,"--sidebar-width-icon":Se,...i},e[5]=i,e[6]=d):d=e[6];const n=d;let r;e[7]!==a?(r=g("group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex h-full w-full",a),e[7]=a,e[8]=r):r=e[8];let u;return e[9]!==t||e[10]!==s||e[11]!==n||e[12]!==r?(u=o.jsx("div",{"data-slot":"sidebar-wrapper",style:n,className:r,...s,children:t}),e[9]=t,e[10]=s,e[11]=n,e[12]=r,e[13]=u):u=e[13],u}function ze(l){const e=h.c(42);let t,a,s,i,d,n;e[0]!==l?({side:i,variant:d,collapsible:n,className:a,children:t,...s}=l,e[0]=l,e[1]=t,e[2]=a,e[3]=s,e[4]=i,e[5]=d,e[6]=n):(t=e[1],a=e[2],s=e[3],i=e[4],d=e[5],n=e[6]);const r=i===void 0?"left":i,u=d===void 0?"sidebar":d,f=n===void 0?"offcanvas":n,{isMobile:m,state:c,openMobile:p,setOpenMobile:b}=k();if(f==="none"){let N;e[7]!==a?(N=g("bg-sidebar text-sidebar-foreground flex h-full w-(--sidebar-width) flex-col",a),e[7]=a,e[8]=N):N=e[8];let w;return e[9]!==t||e[10]!==s||e[11]!==N?(w=o.jsx("div",{"data-slot":"sidebar",className:N,...s,children:t}),e[9]=t,e[10]=s,e[11]=N,e[12]=w):w=e[12],w}if(m){let N;e[13]===Symbol.for("react.memo_cache_sentinel")?(N={"--sidebar-width":je},e[13]=N):N=e[13];let w;e[14]===Symbol.for("react.memo_cache_sentinel")?(w=o.jsxs(be,{className:"sr-only",children:[o.jsx(he,{children:"Sidebar"}),o.jsx(ge,{children:"Displays the mobile sidebar."})]}),e[14]=w):w=e[14];let O;e[15]!==t?(O=o.jsx("div",{className:"flex h-full w-full flex-col",children:t}),e[15]=t,e[16]=O):O=e[16];let C;e[17]!==r||e[18]!==O?(C=o.jsxs(pe,{"data-sidebar":"sidebar","data-slot":"sidebar","data-mobile":"true",className:"bg-sidebar text-sidebar-foreground w-(--sidebar-width) p-0 [&>button]:hidden",style:N,side:r,children:[w,O]}),e[17]=r,e[18]=O,e[19]=C):C=e[19];let E;return e[20]!==p||e[21]!==s||e[22]!==b||e[23]!==C?(E=o.jsx(fe,{open:p,onOpenChange:b,...s,children:C}),e[20]=p,e[21]=s,e[22]=b,e[23]=C,e[24]=E):E=e[24],E}const S=u==="floating"||u==="inset"?"data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]":"data-[collapsible=icon]:w-(--sidebar-width-icon)";let x;e[25]!==S?(x=g("group peer text-sidebar-foreground hidden md:flex flex-col shrink-0 overflow-hidden","w-(--sidebar-width) transition-[width] duration-300 ease-[var(--ease-out-quart)]","data-[collapsible=offcanvas]:w-0",S),e[25]=S,e[26]=x):x=e[26];const y=c==="collapsed"?f:"";let v;e[27]!==a?(v=g("flex flex-col h-full w-(--sidebar-width)",a),e[27]=a,e[28]=v):v=e[28];let j;e[29]!==t?(j=o.jsx("div",{"data-sidebar":"sidebar","data-slot":"sidebar-inner",className:"bg-sidebar group-data-[variant=floating]:border-sidebar-border flex h-full w-full flex-col group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:shadow-sm",children:t}),e[29]=t,e[30]=j):j=e[30];let _;e[31]!==s||e[32]!==v||e[33]!==j?(_=o.jsx("div",{"data-slot":"sidebar-container",className:v,...s,children:j}),e[31]=s,e[32]=v,e[33]=j,e[34]=_):_=e[34];let $;return e[35]!==r||e[36]!==c||e[37]!==x||e[38]!==y||e[39]!==_||e[40]!==u?($=o.jsx("div",{className:x,"data-state":c,"data-collapsible":y,"data-variant":u,"data-side":r,"data-slot":"sidebar",children:_}),e[35]=r,e[36]=c,e[37]=x,e[38]=y,e[39]=_,e[40]=u,e[41]=$):$=e[41],$}function Ce(l){const e=h.c(18);let t,a,s;e[0]!==l?({className:t,onClick:a,...s}=l,e[0]=l,e[1]=t,e[2]=a,e[3]=s):(t=e[1],a=e[2],s=e[3]);const{toggleSidebar:i}=k();let d;e[4]!==t?(d=g("size-7",t),e[4]=t,e[5]=d):d=e[5];let n;e[6]!==a||e[7]!==i?(n=p=>{a?.(p),i()},e[6]=a,e[7]=i,e[8]=n):n=e[8];let r,u;e[9]===Symbol.for("react.memo_cache_sentinel")?(r=o.jsx(H,{}),u=o.jsx("span",{className:"sr-only",children:"Toggle Sidebar"}),e[9]=r,e[10]=u):(r=e[9],u=e[10]);let f;e[11]!==s||e[12]!==d||e[13]!==n?(f=o.jsx(D,{asChild:!0,children:o.jsxs(P,{"data-sidebar":"trigger","data-slot":"sidebar-trigger",variant:"ghost",size:"icon",className:d,onClick:n,...s,children:[r,u]})}),e[11]=s,e[12]=d,e[13]=n,e[14]=f):f=e[14];let m;e[15]===Symbol.for("react.memo_cache_sentinel")?(m=o.jsxs(I,{side:"bottom",className:"flex items-center gap-2",children:["Collapse sidebar",o.jsx("kbd",{className:"bg-background/20 rounded px-1 py-0.5 text-[10px] font-mono",children:"⌘B"})]}),e[15]=m):m=e[15];let c;return e[16]!==f?(c=o.jsx(L,{delayDuration:300,children:o.jsxs(M,{children:[f,m]})}),e[16]=f,e[17]=c):c=e[17],c}function Ke(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=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]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("main",{"data-slot":"sidebar-inset",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function We(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("flex flex-col gap-2 p-2",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-slot":"sidebar-header","data-sidebar":"header",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function qe(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("flex flex-col gap-2 p-2",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-slot":"sidebar-footer","data-sidebar":"footer",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function Ve(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("h-4 m-0! w-full",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-sidebar":"separator",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function Fe(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-slot":"sidebar-content","data-sidebar":"content",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function Ge(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("relative flex w-full min-w-0 flex-col px-2 py-2 md:py-0",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-slot":"sidebar-group","data-sidebar":"group",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function Qe(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("w-full text-sm",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-slot":"sidebar-group-content","data-sidebar":"group-content",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function Je(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("flex w-full min-w-0 flex-col gap-1",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("ul",{"data-slot":"sidebar-menu","data-sidebar":"menu",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function Ue(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("group/menu-item relative",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("li",{"data-slot":"sidebar-menu-item","data-sidebar":"menu-item",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}const $e=te("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md py-0 pr-0.5 pl-1.5 text-left text-sm outline-hidden ring-sidebar-ring transition-[width,height,padding] focus-visible:ring-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 [&>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 shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2!",sm:"h-7 text-xs",lg:"h-12 text-sm group-data-[collapsible=icon]:p-0!"}},defaultVariants:{variant:"default",size:"default"}});function Xe(l){const e=h.c(28);let t,a,s,i,d,n,r;e[0]!==l?({asChild:s,isActive:i,variant:d,size:n,tooltip:r,className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a,e[3]=s,e[4]=i,e[5]=d,e[6]=n,e[7]=r):(t=e[1],a=e[2],s=e[3],i=e[4],d=e[5],n=e[6],r=e[7]);const u=s===void 0?!1:s,f=i===void 0?!1:i,m=d===void 0?"default":d,c=n===void 0?"default":n,p=u?ee:"button",{isMobile:b,state:S}=k();let x;e[8]!==t||e[9]!==c||e[10]!==m?(x=g($e({variant:m,size:c}),t),e[8]=t,e[9]=c,e[10]=m,e[11]=x):x=e[11];let y;e[12]!==p||e[13]!==f||e[14]!==a||e[15]!==c||e[16]!==x?(y=o.jsx(p,{"data-slot":"sidebar-menu-button","data-sidebar":"menu-button","data-size":c,"data-active":f,className:x,...a}),e[12]=p,e[13]=f,e[14]=a,e[15]=c,e[16]=x,e[17]=y):y=e[17];const v=y;if(!r)return v;if(typeof r=="string"){let w;e[18]!==r?(w={children:r},e[18]=r,e[19]=w):w=e[19],r=w}let j;e[20]!==v?(j=o.jsx(D,{asChild:!0,children:v}),e[20]=v,e[21]=j):j=e[21];const _=S!=="collapsed"||b;let $;e[22]!==_||e[23]!==r?($=o.jsx(I,{side:"right",align:"center",hidden:_,...r}),e[22]=_,e[23]=r,e[24]=$):$=e[24];let N;return e[25]!==j||e[26]!==$?(N=o.jsxs(M,{children:[j,$]}),e[25]=j,e[26]=$,e[27]=N):N=e[27],N}function A(l,e){const t=T.Children.toArray(l);for(const a of t)if(T.isValidElement(a)&&a.type===e)return a;return null}function Oe(){const l=h.c(12),[e,t]=ce(),a=B();let s;l[0]===Symbol.for("react.memo_cache_sentinel")?(s={strict:!1},l[0]=s):s=l[0];const{org:i,project:d}=se(s),{location:n}=ae();if(n.pathname===`/${i}/${d}`||n.pathname===`/${i}/${d}/`||a)return null;const u=e&&"bg-accent text-foreground";let f;l[1]!==u?(f=g("h-7 px-2 gap-1.5 text-xs font-medium text-muted-foreground hover:text-foreground",u),l[1]=u,l[2]=f):f=l[2];let m;l[3]!==t?(m=()=>t(Te),l[3]=t,l[4]=m):m=l[4];let c;l[5]===Symbol.for("react.memo_cache_sentinel")?(c=o.jsx(z,{size:14,className:"text-inherit"}),l[5]=c):c=l[5];let p;l[6]!==f||l[7]!==m?(p=o.jsx(D,{asChild:!0,children:o.jsxs(P,{variant:"ghost",className:f,onClick:m,"aria-label":"Toggle Decopilot",children:[c,"Chat"]})}),l[6]=f,l[7]=m,l[8]=p):p=l[8];let b;l[9]===Symbol.for("react.memo_cache_sentinel")?(b=o.jsx(I,{side:"bottom",children:"Toggle Decopilot"}),l[9]=b):b=l[9];let S;return l[10]!==p?(S=o.jsxs(M,{children:[p,b]}),l[10]=p,l[11]=S):S=l[11],S}function Te(l){return!l}function Ee(l){const e=h.c(5),{children:t,className:a}=l;let s;e[0]!==a?(s=g("flex flex-col h-full bg-background overflow-hidden",a),e[0]=a,e[1]=s):s=e[1];let i;return e[2]!==t||e[3]!==s?(i=o.jsx("div",{className:s,children:t}),e[2]=t,e[3]=s,e[4]=i):i=e[4],i}function De(l){const e=h.c(20),{children:t,className:a,hideSidebarTrigger:s}=l;let i;e[0]!==t?(i=A(t,W),e[0]=t,e[1]=i):i=e[1];const d=i;let n;e[2]!==t?(n=A(t,q),e[2]=t,e[3]=n):n=e[3];const r=n;let u;e[4]!==a?(u=g("shrink-0 w-full border-b border-border/50 h-11","flex items-center justify-between gap-3 pr-2 pl-2 md:pl-4",a),e[4]=a,e[5]=u):u=e[5];let f;e[6]!==s?(f=!s&&o.jsx(Ce,{className:"md:hidden shrink-0"}),e[6]=s,e[7]=f):f=e[7];let m;e[8]!==d||e[9]!==f?(m=o.jsxs("div",{className:"flex items-center gap-1 min-w-0 flex-1",children:[f,d]}),e[8]=d,e[9]=f,e[10]=m):m=e[10];let c;e[11]!==s?(c=!s&&o.jsx("div",{className:"flex items-center pl-2 ml-1",children:o.jsx(Oe,{})}),e[11]=s,e[12]=c):c=e[12];let p;e[13]!==r||e[14]!==c?(p=o.jsxs("div",{className:"flex items-center",children:[r,c]}),e[13]=r,e[14]=c,e[15]=p):p=e[15];let b;return e[16]!==u||e[17]!==m||e[18]!==p?(b=o.jsxs("div",{className:u,children:[m,p]}),e[16]=u,e[17]=m,e[18]=p,e[19]=b):b=e[19],b}function W(l){const e=h.c(5),{children:t,className:a}=l;let s;e[0]!==a?(s=g("flex items-center gap-2 min-w-0 overflow-hidden",a),e[0]=a,e[1]=s):s=e[1];let i;return e[2]!==t||e[3]!==s?(i=o.jsx("div",{className:s,children:t}),e[2]=t,e[3]=s,e[4]=i):i=e[4],i}function q(l){const e=h.c(5),{children:t,className:a}=l;let s;e[0]!==a?(s=g("flex items-center gap-2 shrink-0 overflow-hidden",a),e[0]=a,e[1]=s):s=e[1];let i;return e[2]!==t||e[3]!==s?(i=o.jsx("div",{className:s,children:t}),e[2]=t,e[3]=s,e[4]=i):i=e[4],i}function Ie(l){const e=h.c(5),{children:t,className:a}=l;let s;e[0]!==a?(s=g("flex-1 overflow-auto",a),e[0]=a,e[1]=s):s=e[1];let i;return e[2]!==t||e[3]!==s?(i=o.jsx("div",{className:s,children:t}),e[2]=t,e[3]=s,e[4]=i):i=e[4],i}const Ye=Object.assign(Ee,{Header:Object.assign(De,{Left:W,Right:q}),Content:Ie});export{Ye as P,fe as S,ce as a,pe as b,be as c,he as d,ge as e,k as f,Je as g,Ue as h,H as i,Xe as j,Qe as k,Ge as l,Ve as m,Fe as n,ze as o,We as p,qe as q,Le as r,Ke as s,He as t,re as u,z as v};
1
+ import{r as T,c as h,w as V,z as F,j as o,ab as G,D as g,ac as Q,ad as J,ae as U,af as X,ah as Y,ag as Z,B as P,M as ee,W as te,g as se,aL as ae}from"./index-Di6oLb1g.js";import{u as le}from"./useQuery-BrfnS-T_.js";import{u as ie}from"./useMutation-BOcaN318.js";import{a as D,u as B,c as L,b as I,T as M}from"./tooltip-Bt2vWRpT.js";import{i as oe}from"./X-1dO_8PIJ.js";const H=({size:l=24,color:e="currentColor",...t})=>T.createElement("svg",{viewBox:"0 0 24 24",width:l,height:l,stroke:e,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...t},T.createElement("path",{d:"M9 3v18M7.8 3h8.4c1.68 0 2.52 0 3.162.327a3 3 0 0 1 1.311 1.311C21 5.28 21 6.12 21 7.8v8.4c0 1.68 0 2.52-.327 3.162a3 3 0 0 1-1.311 1.311C18.72 21 17.88 21 16.2 21H7.8c-1.68 0-2.52 0-3.162-.327a3 3 0 0 1-1.311-1.311C3 18.72 3 17.88 3 16.2V7.8c0-1.68 0-2.52.327-3.162a3 3 0 0 1 1.311-1.311C5.28 3 6.12 3 7.8 3Z"}));H.displayName="LayoutLeft";const z=({size:l=24,color:e="currentColor",...t})=>T.createElement("svg",{viewBox:"0 0 24 24",width:l,height:l,stroke:e,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...t},T.createElement("path",{d:"M8 9.5h4M8 13h7m-3 8a9 9 0 1 0-8.342-5.616c.081.2.122.3.14.381a.907.907 0 0 1 .024.219c0 .083-.015.173-.045.353l-.593 3.558c-.062.373-.093.56-.035.694a.5.5 0 0 0 .262.262c.135.058.321.027.694-.035l3.558-.593c.18-.03.27-.045.353-.045.081 0 .14.006.219.024.08.018.18.059.38.14A8.973 8.973 0 0 0 12 21Z"}));z.displayName="MessageTextCircle02";function ne(l){try{return JSON.parse(l)}catch{return}}function R(l,e){const t=localStorage.getItem(l),a=t?ne(t):void 0,s=typeof e=="function"?e(a):a??e;if(a===void 0||s!==a)try{const i=JSON.stringify(s);localStorage.setItem(l,i)}catch{}return s}function re(l,e){const t=h.c(25),a=V();let s;t[0]!==l?(s=["localStorage",l],t[0]=l,t[1]=s):s=t[1];const i=s;let d,n;t[2]!==e||t[3]!==l?(d=()=>R(l,e),n=()=>R(l,e),t[2]=e,t[3]=l,t[4]=d,t[5]=n):(d=t[4],n=t[5]);let r;t[6]!==i||t[7]!==d||t[8]!==n?(r={queryKey:i,queryFn:d,initialData:n,staleTime:1/0,gcTime:1/0},t[6]=i,t[7]=d,t[8]=n,t[9]=r):r=t[9];const{data:u}=le(r);let f;t[10]!==l?(f=async v=>{const j=JSON.stringify(v);return localStorage.setItem(l,j),v},t[10]=l,t[11]=f):f=t[11];let m;t[12]!==a||t[13]!==i?(m=v=>{a.setQueryData(i,v)},t[12]=a,t[13]=i,t[14]=m):m=t[14];let c;t[15]!==f||t[16]!==m?(c={mutationFn:f,onSuccess:m},t[15]=f,t[16]=m,t[17]=c):c=t[17];const p=ie(c);let b;t[18]!==p||t[19]!==a||t[20]!==i?(b=v=>{const j=a.getQueryData(i),_=typeof v=="function"?v(j):v;p.mutate(_)},t[18]=p,t[19]=a,t[20]=i,t[21]=b):b=t[21];const S=b,x=u;let y;return t[22]!==S||t[23]!==x?(y=[x,S],t[22]=S,t[23]=x,t[24]=y):y=t[24],y}function ce(){const l=h.c(4);let e;l[0]===Symbol.for("react.memo_cache_sentinel")?(e=F.decoChatOpen(),l[0]=e):e=l[0];const[t,a]=re(e,de);let s;return l[1]!==t||l[2]!==a?(s=[t,a],l[1]=t,l[2]=a,l[3]=s):s=l[3],s}function de(l){return!!(l??!0)}function fe(l){const e=h.c(4);let t;e[0]!==l?({...t}=l,e[0]=l,e[1]=t):t=e[1];let a;return e[2]!==t?(a=o.jsx(G,{"data-slot":"sheet",...t}),e[2]=t,e[3]=a):a=e[3],a}function ue(l){const e=h.c(4);let t;e[0]!==l?({...t}=l,e[0]=l,e[1]=t):t=e[1];let a;return e[2]!==t?(a=o.jsx(X,{"data-slot":"sheet-portal",...t}),e[2]=t,e[3]=a):a=e[3],a}function me(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=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]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx(Z,{"data-slot":"sheet-overlay",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function pe(l){const e=h.c(17);let t,a,s,i;e[0]!==l?({className:a,children:t,side:i,...s}=l,e[0]=l,e[1]=t,e[2]=a,e[3]=s,e[4]=i):(t=e[1],a=e[2],s=e[3],i=e[4]);const d=i===void 0?"right":i;let n;e[5]===Symbol.for("react.memo_cache_sentinel")?(n=o.jsx(me,{}),e[5]=n):n=e[5];const r=d==="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",u=d==="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=d==="top"&&"data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top inset-x-0 top-0 h-auto border-b",m=d==="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 c;e[6]!==a||e[7]!==r||e[8]!==u||e[9]!==f||e[10]!==m?(c=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",r,u,f,m,a),e[6]=a,e[7]=r,e[8]=u,e[9]=f,e[10]=m,e[11]=c):c=e[11];let p;e[12]===Symbol.for("react.memo_cache_sentinel")?(p=o.jsxs(Y,{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(oe,{className:"size-4"}),o.jsx("span",{className:"sr-only",children:"Close"})]}),e[12]=p):p=e[12];let b;return e[13]!==t||e[14]!==s||e[15]!==c?(b=o.jsxs(ue,{children:[n,o.jsxs(Q,{"data-slot":"sheet-content",className:c,...s,children:[t,p]})]}),e[13]=t,e[14]=s,e[15]=c,e[16]=b):b=e[16],b}function be(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("flex flex-col gap-1.5 p-4",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-slot":"sheet-header",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function he(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("text-foreground font-semibold",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx(J,{"data-slot":"sheet-title",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function ge(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("text-muted-foreground text-sm",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx(U,{"data-slot":"sheet-description",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}const xe="sidebar_state",ve=3600*24*7,Ne="16rem",je="18rem",Se="3rem",we="b",K=T.createContext(null);function k(){const l=T.useContext(K);if(!l)throw new Error("useSidebar must be used within a SidebarProvider.");return l}function Le(l){const e=h.c(21),{defaultOpen:t,open:a,onOpenChange:s,children:i}=l,d=t===void 0?!0:t,n=B(),[r,u]=T.useState(!1),[f,m]=T.useState(d),c=a??f;let p;e[0]!==c||e[1]!==s?(p=O=>{const C=typeof O=="function"?O(c):O;s?s(C):m(C),document.cookie=`${xe}=${C}; path=/; max-age=${ve}`},e[0]=c,e[1]=s,e[2]=p):p=e[2];const b=p;let S;e[3]!==n||e[4]!==b?(S=()=>n?u(_e):b(ye),e[3]=n,e[4]=b,e[5]=S):S=e[5];const x=S;let y,v;e[6]!==x?(y=()=>{const O=C=>{if(C.key===we&&(C.metaKey||C.ctrlKey)){const E=C.target;if(E.tagName==="INPUT"||E.tagName==="TEXTAREA"||E.isContentEditable)return;C.preventDefault(),x()}};return globalThis.addEventListener("keydown",O),()=>globalThis.removeEventListener("keydown",O)},v=[x],e[6]=x,e[7]=y,e[8]=v):(y=e[7],v=e[8]),T.useEffect(y,v);const j=c?"expanded":"collapsed";let _;e[9]!==n||e[10]!==c||e[11]!==r||e[12]!==b||e[13]!==j||e[14]!==x?(_={state:j,open:c,setOpen:b,isMobile:n,openMobile:r,setOpenMobile:u,toggleSidebar:x},e[9]=n,e[10]=c,e[11]=r,e[12]=b,e[13]=j,e[14]=x,e[15]=_):_=e[15];const $=_;let N;e[16]!==i?(N=o.jsx(L,{delayDuration:0,children:i}),e[16]=i,e[17]=N):N=e[17];let w;return e[18]!==$||e[19]!==N?(w=o.jsx(K.Provider,{value:$,children:N}),e[18]=$,e[19]=N,e[20]=w):w=e[20],w}function ye(l){return!l}function _e(l){return!l}function He(l){const e=h.c(14);let t,a,s,i;e[0]!==l?({className:a,style:i,children:t,...s}=l,e[0]=l,e[1]=t,e[2]=a,e[3]=s,e[4]=i):(t=e[1],a=e[2],s=e[3],i=e[4]);let d;e[5]!==i?(d={"--sidebar-width":Ne,"--sidebar-width-icon":Se,...i},e[5]=i,e[6]=d):d=e[6];const n=d;let r;e[7]!==a?(r=g("group/sidebar-wrapper has-data-[variant=inset]:bg-sidebar flex h-full w-full",a),e[7]=a,e[8]=r):r=e[8];let u;return e[9]!==t||e[10]!==s||e[11]!==n||e[12]!==r?(u=o.jsx("div",{"data-slot":"sidebar-wrapper",style:n,className:r,...s,children:t}),e[9]=t,e[10]=s,e[11]=n,e[12]=r,e[13]=u):u=e[13],u}function ze(l){const e=h.c(42);let t,a,s,i,d,n;e[0]!==l?({side:i,variant:d,collapsible:n,className:a,children:t,...s}=l,e[0]=l,e[1]=t,e[2]=a,e[3]=s,e[4]=i,e[5]=d,e[6]=n):(t=e[1],a=e[2],s=e[3],i=e[4],d=e[5],n=e[6]);const r=i===void 0?"left":i,u=d===void 0?"sidebar":d,f=n===void 0?"offcanvas":n,{isMobile:m,state:c,openMobile:p,setOpenMobile:b}=k();if(f==="none"){let N;e[7]!==a?(N=g("bg-sidebar text-sidebar-foreground flex h-full w-(--sidebar-width) flex-col",a),e[7]=a,e[8]=N):N=e[8];let w;return e[9]!==t||e[10]!==s||e[11]!==N?(w=o.jsx("div",{"data-slot":"sidebar",className:N,...s,children:t}),e[9]=t,e[10]=s,e[11]=N,e[12]=w):w=e[12],w}if(m){let N;e[13]===Symbol.for("react.memo_cache_sentinel")?(N={"--sidebar-width":je},e[13]=N):N=e[13];let w;e[14]===Symbol.for("react.memo_cache_sentinel")?(w=o.jsxs(be,{className:"sr-only",children:[o.jsx(he,{children:"Sidebar"}),o.jsx(ge,{children:"Displays the mobile sidebar."})]}),e[14]=w):w=e[14];let O;e[15]!==t?(O=o.jsx("div",{className:"flex h-full w-full flex-col",children:t}),e[15]=t,e[16]=O):O=e[16];let C;e[17]!==r||e[18]!==O?(C=o.jsxs(pe,{"data-sidebar":"sidebar","data-slot":"sidebar","data-mobile":"true",className:"bg-sidebar text-sidebar-foreground w-(--sidebar-width) p-0 [&>button]:hidden",style:N,side:r,children:[w,O]}),e[17]=r,e[18]=O,e[19]=C):C=e[19];let E;return e[20]!==p||e[21]!==s||e[22]!==b||e[23]!==C?(E=o.jsx(fe,{open:p,onOpenChange:b,...s,children:C}),e[20]=p,e[21]=s,e[22]=b,e[23]=C,e[24]=E):E=e[24],E}const S=u==="floating"||u==="inset"?"data-[collapsible=icon]:w-[calc(var(--sidebar-width-icon)+(--spacing(4)))]":"data-[collapsible=icon]:w-(--sidebar-width-icon)";let x;e[25]!==S?(x=g("group peer text-sidebar-foreground hidden md:flex flex-col shrink-0 overflow-hidden","w-(--sidebar-width) transition-[width] duration-300 ease-[var(--ease-out-quart)]","data-[collapsible=offcanvas]:w-0",S),e[25]=S,e[26]=x):x=e[26];const y=c==="collapsed"?f:"";let v;e[27]!==a?(v=g("flex flex-col h-full w-(--sidebar-width)",a),e[27]=a,e[28]=v):v=e[28];let j;e[29]!==t?(j=o.jsx("div",{"data-sidebar":"sidebar","data-slot":"sidebar-inner",className:"bg-sidebar group-data-[variant=floating]:border-sidebar-border flex h-full w-full flex-col group-data-[variant=floating]:rounded-lg group-data-[variant=floating]:border group-data-[variant=floating]:shadow-sm",children:t}),e[29]=t,e[30]=j):j=e[30];let _;e[31]!==s||e[32]!==v||e[33]!==j?(_=o.jsx("div",{"data-slot":"sidebar-container",className:v,...s,children:j}),e[31]=s,e[32]=v,e[33]=j,e[34]=_):_=e[34];let $;return e[35]!==r||e[36]!==c||e[37]!==x||e[38]!==y||e[39]!==_||e[40]!==u?($=o.jsx("div",{className:x,"data-state":c,"data-collapsible":y,"data-variant":u,"data-side":r,"data-slot":"sidebar",children:_}),e[35]=r,e[36]=c,e[37]=x,e[38]=y,e[39]=_,e[40]=u,e[41]=$):$=e[41],$}function Ce(l){const e=h.c(18);let t,a,s;e[0]!==l?({className:t,onClick:a,...s}=l,e[0]=l,e[1]=t,e[2]=a,e[3]=s):(t=e[1],a=e[2],s=e[3]);const{toggleSidebar:i}=k();let d;e[4]!==t?(d=g("size-7",t),e[4]=t,e[5]=d):d=e[5];let n;e[6]!==a||e[7]!==i?(n=p=>{a?.(p),i()},e[6]=a,e[7]=i,e[8]=n):n=e[8];let r,u;e[9]===Symbol.for("react.memo_cache_sentinel")?(r=o.jsx(H,{}),u=o.jsx("span",{className:"sr-only",children:"Toggle Sidebar"}),e[9]=r,e[10]=u):(r=e[9],u=e[10]);let f;e[11]!==s||e[12]!==d||e[13]!==n?(f=o.jsx(D,{asChild:!0,children:o.jsxs(P,{"data-sidebar":"trigger","data-slot":"sidebar-trigger",variant:"ghost",size:"icon",className:d,onClick:n,...s,children:[r,u]})}),e[11]=s,e[12]=d,e[13]=n,e[14]=f):f=e[14];let m;e[15]===Symbol.for("react.memo_cache_sentinel")?(m=o.jsxs(I,{side:"bottom",className:"flex items-center gap-2",children:["Collapse sidebar",o.jsx("kbd",{className:"bg-background/20 rounded px-1 py-0.5 text-[10px] font-mono",children:"⌘B"})]}),e[15]=m):m=e[15];let c;return e[16]!==f?(c=o.jsx(L,{delayDuration:300,children:o.jsxs(M,{children:[f,m]})}),e[16]=f,e[17]=c):c=e[17],c}function Ke(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=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]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("main",{"data-slot":"sidebar-inset",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function We(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("flex flex-col gap-2 p-2",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-slot":"sidebar-header","data-sidebar":"header",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function qe(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("flex flex-col gap-2 p-2",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-slot":"sidebar-footer","data-sidebar":"footer",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function Ve(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("h-4 m-0! w-full",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-sidebar":"separator",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function Fe(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("flex min-h-0 flex-1 flex-col gap-2 overflow-auto group-data-[collapsible=icon]:overflow-hidden",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-slot":"sidebar-content","data-sidebar":"content",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function Ge(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("relative flex w-full min-w-0 flex-col px-2 py-2 md:py-0",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-slot":"sidebar-group","data-sidebar":"group",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function Qe(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("w-full text-sm",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("div",{"data-slot":"sidebar-group-content","data-sidebar":"group-content",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function Je(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("flex w-full min-w-0 flex-col gap-1",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("ul",{"data-slot":"sidebar-menu","data-sidebar":"menu",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}function Ue(l){const e=h.c(8);let t,a;e[0]!==l?({className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a):(t=e[1],a=e[2]);let s;e[3]!==t?(s=g("group/menu-item relative",t),e[3]=t,e[4]=s):s=e[4];let i;return e[5]!==a||e[6]!==s?(i=o.jsx("li",{"data-slot":"sidebar-menu-item","data-sidebar":"menu-item",className:s,...a}),e[5]=a,e[6]=s,e[7]=i):i=e[7],i}const $e=te("peer/menu-button flex w-full items-center gap-2 overflow-hidden rounded-md py-0 pr-0.5 pl-1.5 text-left text-sm outline-hidden ring-sidebar-ring transition-[width,height,padding] focus-visible:ring-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 [&>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 shadow-[0_0_0_1px_hsl(var(--sidebar-border))] hover:bg-sidebar-accent hover:text-sidebar-accent-foreground hover:shadow-[0_0_0_1px_hsl(var(--sidebar-accent))]"},size:{default:"h-8 text-sm group-data-[collapsible=icon]:size-8! group-data-[collapsible=icon]:p-2!",sm:"h-7 text-xs",lg:"h-12 text-sm group-data-[collapsible=icon]:p-0!"}},defaultVariants:{variant:"default",size:"default"}});function Xe(l){const e=h.c(28);let t,a,s,i,d,n,r;e[0]!==l?({asChild:s,isActive:i,variant:d,size:n,tooltip:r,className:t,...a}=l,e[0]=l,e[1]=t,e[2]=a,e[3]=s,e[4]=i,e[5]=d,e[6]=n,e[7]=r):(t=e[1],a=e[2],s=e[3],i=e[4],d=e[5],n=e[6],r=e[7]);const u=s===void 0?!1:s,f=i===void 0?!1:i,m=d===void 0?"default":d,c=n===void 0?"default":n,p=u?ee:"button",{isMobile:b,state:S}=k();let x;e[8]!==t||e[9]!==c||e[10]!==m?(x=g($e({variant:m,size:c}),t),e[8]=t,e[9]=c,e[10]=m,e[11]=x):x=e[11];let y;e[12]!==p||e[13]!==f||e[14]!==a||e[15]!==c||e[16]!==x?(y=o.jsx(p,{"data-slot":"sidebar-menu-button","data-sidebar":"menu-button","data-size":c,"data-active":f,className:x,...a}),e[12]=p,e[13]=f,e[14]=a,e[15]=c,e[16]=x,e[17]=y):y=e[17];const v=y;if(!r)return v;if(typeof r=="string"){let w;e[18]!==r?(w={children:r},e[18]=r,e[19]=w):w=e[19],r=w}let j;e[20]!==v?(j=o.jsx(D,{asChild:!0,children:v}),e[20]=v,e[21]=j):j=e[21];const _=S!=="collapsed"||b;let $;e[22]!==_||e[23]!==r?($=o.jsx(I,{side:"right",align:"center",hidden:_,...r}),e[22]=_,e[23]=r,e[24]=$):$=e[24];let N;return e[25]!==j||e[26]!==$?(N=o.jsxs(M,{children:[j,$]}),e[25]=j,e[26]=$,e[27]=N):N=e[27],N}function A(l,e){const t=T.Children.toArray(l);for(const a of t)if(T.isValidElement(a)&&a.type===e)return a;return null}function Oe(){const l=h.c(12),[e,t]=ce(),a=B();let s;l[0]===Symbol.for("react.memo_cache_sentinel")?(s={strict:!1},l[0]=s):s=l[0];const{org:i,project:d}=se(s),{location:n}=ae();if(n.pathname===`/${i}/${d}`||n.pathname===`/${i}/${d}/`||a)return null;const u=e&&"bg-accent text-foreground";let f;l[1]!==u?(f=g("h-7 px-2 gap-1.5 text-xs font-medium text-muted-foreground hover:text-foreground",u),l[1]=u,l[2]=f):f=l[2];let m;l[3]!==t?(m=()=>t(Te),l[3]=t,l[4]=m):m=l[4];let c;l[5]===Symbol.for("react.memo_cache_sentinel")?(c=o.jsx(z,{size:14,className:"text-inherit"}),l[5]=c):c=l[5];let p;l[6]!==f||l[7]!==m?(p=o.jsx(D,{asChild:!0,children:o.jsxs(P,{variant:"ghost",className:f,onClick:m,"aria-label":"Toggle Decopilot",children:[c,"Chat"]})}),l[6]=f,l[7]=m,l[8]=p):p=l[8];let b;l[9]===Symbol.for("react.memo_cache_sentinel")?(b=o.jsx(I,{side:"bottom",children:"Toggle Decopilot"}),l[9]=b):b=l[9];let S;return l[10]!==p?(S=o.jsxs(M,{children:[p,b]}),l[10]=p,l[11]=S):S=l[11],S}function Te(l){return!l}function Ee(l){const e=h.c(5),{children:t,className:a}=l;let s;e[0]!==a?(s=g("flex flex-col h-full bg-background overflow-hidden",a),e[0]=a,e[1]=s):s=e[1];let i;return e[2]!==t||e[3]!==s?(i=o.jsx("div",{className:s,children:t}),e[2]=t,e[3]=s,e[4]=i):i=e[4],i}function De(l){const e=h.c(20),{children:t,className:a,hideSidebarTrigger:s}=l;let i;e[0]!==t?(i=A(t,W),e[0]=t,e[1]=i):i=e[1];const d=i;let n;e[2]!==t?(n=A(t,q),e[2]=t,e[3]=n):n=e[3];const r=n;let u;e[4]!==a?(u=g("shrink-0 w-full border-b border-border/50 h-11","flex items-center justify-between gap-3 pr-2 pl-2 md:pl-4",a),e[4]=a,e[5]=u):u=e[5];let f;e[6]!==s?(f=!s&&o.jsx(Ce,{className:"md:hidden shrink-0"}),e[6]=s,e[7]=f):f=e[7];let m;e[8]!==d||e[9]!==f?(m=o.jsxs("div",{className:"flex items-center gap-1 min-w-0 flex-1",children:[f,d]}),e[8]=d,e[9]=f,e[10]=m):m=e[10];let c;e[11]!==s?(c=!s&&o.jsx("div",{className:"flex items-center pl-2 ml-1",children:o.jsx(Oe,{})}),e[11]=s,e[12]=c):c=e[12];let p;e[13]!==r||e[14]!==c?(p=o.jsxs("div",{className:"flex items-center",children:[r,c]}),e[13]=r,e[14]=c,e[15]=p):p=e[15];let b;return e[16]!==u||e[17]!==m||e[18]!==p?(b=o.jsxs("div",{className:u,children:[m,p]}),e[16]=u,e[17]=m,e[18]=p,e[19]=b):b=e[19],b}function W(l){const e=h.c(5),{children:t,className:a}=l;let s;e[0]!==a?(s=g("flex items-center gap-2 min-w-0 overflow-hidden",a),e[0]=a,e[1]=s):s=e[1];let i;return e[2]!==t||e[3]!==s?(i=o.jsx("div",{className:s,children:t}),e[2]=t,e[3]=s,e[4]=i):i=e[4],i}function q(l){const e=h.c(5),{children:t,className:a}=l;let s;e[0]!==a?(s=g("flex items-center gap-2 shrink-0 overflow-hidden",a),e[0]=a,e[1]=s):s=e[1];let i;return e[2]!==t||e[3]!==s?(i=o.jsx("div",{className:s,children:t}),e[2]=t,e[3]=s,e[4]=i):i=e[4],i}function Ie(l){const e=h.c(5),{children:t,className:a}=l;let s;e[0]!==a?(s=g("flex-1 overflow-auto",a),e[0]=a,e[1]=s):s=e[1];let i;return e[2]!==t||e[3]!==s?(i=o.jsx("div",{className:s,children:t}),e[2]=t,e[3]=s,e[4]=i):i=e[4],i}const Ye=Object.assign(Ee,{Header:Object.assign(De,{Left:W,Right:q}),Content:Ie});export{Ye as P,fe as S,ce as a,pe as b,be as c,he as d,ge as e,k as f,Je as g,Ue as h,H as i,Xe as j,Qe as k,Ge as l,Ve as m,Fe as n,ze as o,We as p,qe as q,Le as r,Ke as s,He as t,re as u,z as v};
@@ -1 +1 @@
1
- import{bU as _}from"./index-BjxqoU_w.js";var S={exports:{}},r={};var $;function I(){if($)return r;$=1;var m=Symbol.for("react.element"),y=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),c=Symbol.for("react.provider"),f=Symbol.for("react.context"),x=Symbol.for("react.server_context"),u=Symbol.for("react.forward_ref"),i=Symbol.for("react.suspense"),l=Symbol.for("react.suspense_list"),a=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),R=Symbol.for("react.offscreen"),b;b=Symbol.for("react.module.reference");function t(e){if(typeof e=="object"&&e!==null){var d=e.$$typeof;switch(d){case m:switch(e=e.type,e){case o:case s:case n:case i:case l:return e;default:switch(e=e&&e.$$typeof,e){case x:case f:case u:case p:case a:case c:return e;default:return d}}case y:return d}}}return r.ContextConsumer=f,r.ContextProvider=c,r.Element=m,r.ForwardRef=u,r.Fragment=o,r.Lazy=p,r.Memo=a,r.Portal=y,r.Profiler=s,r.StrictMode=n,r.Suspense=i,r.SuspenseList=l,r.isAsyncMode=function(){return!1},r.isConcurrentMode=function(){return!1},r.isContextConsumer=function(e){return t(e)===f},r.isContextProvider=function(e){return t(e)===c},r.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===m},r.isForwardRef=function(e){return t(e)===u},r.isFragment=function(e){return t(e)===o},r.isLazy=function(e){return t(e)===p},r.isMemo=function(e){return t(e)===a},r.isPortal=function(e){return t(e)===y},r.isProfiler=function(e){return t(e)===s},r.isStrictMode=function(e){return t(e)===n},r.isSuspense=function(e){return t(e)===i},r.isSuspenseList=function(e){return t(e)===l},r.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===o||e===s||e===n||e===i||e===l||e===R||typeof e=="object"&&e!==null&&(e.$$typeof===p||e.$$typeof===a||e.$$typeof===c||e.$$typeof===f||e.$$typeof===u||e.$$typeof===b||e.getModuleId!==void 0)},r.typeOf=t,r}var v;function C(){return v||(v=1,S.exports=I()),S.exports}var g=C();const h=_(g);export{h as R,g as r};
1
+ import{bU as _}from"./index-Di6oLb1g.js";var S={exports:{}},r={};var $;function I(){if($)return r;$=1;var m=Symbol.for("react.element"),y=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),s=Symbol.for("react.profiler"),c=Symbol.for("react.provider"),f=Symbol.for("react.context"),x=Symbol.for("react.server_context"),u=Symbol.for("react.forward_ref"),i=Symbol.for("react.suspense"),l=Symbol.for("react.suspense_list"),a=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),R=Symbol.for("react.offscreen"),b;b=Symbol.for("react.module.reference");function t(e){if(typeof e=="object"&&e!==null){var d=e.$$typeof;switch(d){case m:switch(e=e.type,e){case o:case s:case n:case i:case l:return e;default:switch(e=e&&e.$$typeof,e){case x:case f:case u:case p:case a:case c:return e;default:return d}}case y:return d}}}return r.ContextConsumer=f,r.ContextProvider=c,r.Element=m,r.ForwardRef=u,r.Fragment=o,r.Lazy=p,r.Memo=a,r.Portal=y,r.Profiler=s,r.StrictMode=n,r.Suspense=i,r.SuspenseList=l,r.isAsyncMode=function(){return!1},r.isConcurrentMode=function(){return!1},r.isContextConsumer=function(e){return t(e)===f},r.isContextProvider=function(e){return t(e)===c},r.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===m},r.isForwardRef=function(e){return t(e)===u},r.isFragment=function(e){return t(e)===o},r.isLazy=function(e){return t(e)===p},r.isMemo=function(e){return t(e)===a},r.isPortal=function(e){return t(e)===y},r.isProfiler=function(e){return t(e)===s},r.isStrictMode=function(e){return t(e)===n},r.isSuspense=function(e){return t(e)===i},r.isSuspenseList=function(e){return t(e)===l},r.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===o||e===s||e===n||e===i||e===l||e===R||typeof e=="object"&&e!==null&&(e.$$typeof===p||e.$$typeof===a||e.$$typeof===c||e.$$typeof===f||e.$$typeof===u||e.$$typeof===b||e.getModuleId!==void 0)},r.typeOf=t,r}var v;function C(){return v||(v=1,S.exports=I()),S.exports}var g=C();const h=_(g);export{h as R,g as r};