decocms 4.415.5 → 4.416.1

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 (350) hide show
  1. package/dist/client/assets/{AlertCircle-CIFSd5U6.js → AlertCircle-RWTRMbKB.js} +1 -1
  2. package/dist/client/assets/{AreaChart-n2dZBP5X.js → AreaChart-DXYhyL1O.js} +1 -1
  3. package/dist/client/assets/{ArrowLeft-Cs3E2BgS.js → ArrowLeft-B0Qy6MPA.js} +1 -1
  4. package/dist/client/assets/{ArrowRight-DdzTB6qI.js → ArrowRight-1ZRv0qj4.js} +1 -1
  5. package/dist/client/assets/{ArrowUp-D2UY3OMh.js → ArrowUp-CdkBKRTp.js} +1 -1
  6. package/dist/client/assets/{CartesianChart-V3ArQ0Ow.js → CartesianChart-DxxWBH9Y.js} +1 -1
  7. package/dist/client/assets/{Check-CaNT0o8-.js → Check-B08g8hfv.js} +1 -1
  8. package/dist/client/assets/{CheckCircle-BcLFM9-7.js → CheckCircle-C2FTUn3P.js} +1 -1
  9. package/dist/client/assets/{ChevronUp-BU7d4Get.js → ChevronUp-C43CLLe7.js} +1 -1
  10. package/dist/client/assets/{Copy01-BUTI0qm9.js → Copy01-BFGk4HTi.js} +1 -1
  11. package/dist/client/assets/{CreditCard01-JGaESeVs.js → CreditCard01-D1x66FDR.js} +1 -1
  12. package/dist/client/assets/{DotsVertical-CIYGxTTU.js → DotsVertical-D5Nqj0bW.js} +1 -1
  13. package/dist/client/assets/{ErrorBarContext--AuQGMxS.js → ErrorBarContext-Bka8_hCU.js} +1 -1
  14. package/dist/client/assets/{Image01-BZEauj2T.js → Image01-C3rMiZ72.js} +1 -1
  15. package/dist/client/assets/{Key01-RaCvEF1t.js → Key01-DJx3H4Mk.js} +1 -1
  16. package/dist/client/assets/{Line-Be2Fy-pZ.js → Line-U3trYLWi.js} +1 -1
  17. package/dist/client/assets/{Link01-B4kFCKUO.js → Link01-DpMZQMbW.js} +1 -1
  18. package/dist/client/assets/{LinkExternal01-Cn0PsKoO.js → LinkExternal01-Hrpy2rKU.js} +1 -1
  19. package/dist/client/assets/{Monitor01-DDhoI_iK.js → Monitor01-CHeJ4cBZ.js} +1 -1
  20. package/dist/client/assets/{Palette-BUkGC_ZN.js → Palette-Bowo13XO.js} +1 -1
  21. package/dist/client/assets/{Plus-0VzOcDpy.js → Plus-g-qUeP-5.js} +1 -1
  22. package/dist/client/assets/{SearchMd-DvVcOTQO.js → SearchMd-Bu5ZPloJ.js} +1 -1
  23. package/dist/client/assets/{Sector-9tybsTj9.js → Sector-CoFH2hT0.js} +1 -1
  24. package/dist/client/assets/{ShoppingBag01-DkKlB-7l.js → ShoppingBag01-eap5At3d.js} +1 -1
  25. package/dist/client/assets/{Sun-X5oRKWho.js → Sun-CQdyCDq1.js} +1 -1
  26. package/dist/client/assets/{Tool01-BThW1knZ.js → Tool01-CQE4YIlY.js} +1 -1
  27. package/dist/client/assets/{Trash01-CWZehatA.js → Trash01-ttayP08D.js} +1 -1
  28. package/dist/client/assets/{Upload01-DBJMMF89.js → Upload01-CxxYSCYc.js} +1 -1
  29. package/dist/client/assets/{User01-CkC9PpwU.js → User01-gfze9rr9.js} +1 -1
  30. package/dist/client/assets/{UserSquare-D_CN0irU.js → UserSquare-OqUaFYcL.js} +1 -1
  31. package/dist/client/assets/{Users01-Bly3LhS2.js → Users01-CrUbTlAS.js} +1 -1
  32. package/dist/client/assets/{X-B2uln9s5.js → X-DmQciAIn.js} +1 -1
  33. package/dist/client/assets/{XAxis-M6tZ2obd.js → XAxis-CXI1Q_NM.js} +1 -1
  34. package/dist/client/assets/{XClose-BXY1fsWn.js → XClose-C_pErei1.js} +1 -1
  35. package/dist/client/assets/{ZoomOut-T_sjF8JP.js → ZoomOut-CacJRCxL.js} +1 -1
  36. package/dist/client/assets/{access-gate-CA8I0iHR.js → access-gate-Dfd2-cvG.js} +1 -1
  37. package/dist/client/assets/{add-connection-dialog-kGctlCUa.js → add-connection-dialog-CpdIqje1.js} +1 -1
  38. package/dist/client/assets/{agent-analytics-BexuCA7I.js → agent-analytics-gXgo4wia.js} +1 -1
  39. package/dist/client/assets/agent-app-DEDo3dMv.js +1 -0
  40. package/dist/client/assets/{agent-assets-5R68kfP3.js → agent-assets-CZSlfOSJ.js} +1 -1
  41. package/dist/client/assets/{agent-automation-vuVO0lMZ.js → agent-automation-vBt8WQOK.js} +1 -1
  42. package/dist/client/assets/{agent-automations-BdmtLK0F.js → agent-automations-CP1b9Nsk.js} +1 -1
  43. package/dist/client/assets/{agent-connect-sources-nPGJrjJB.js → agent-connect-sources-5sgGl2E-.js} +1 -1
  44. package/dist/client/assets/agent-deck-BJYJReZO.js +1 -0
  45. package/dist/client/assets/{agent-e2e-EFIGYD5n.js → agent-e2e-B4edQET4.js} +1 -1
  46. package/dist/client/assets/{agent-experiments-DskaK8J-.js → agent-experiments-DQzvZ_es.js} +1 -1
  47. package/dist/client/assets/{agent-file-Cu8RBins.js → agent-file-DLxt_ubk.js} +1 -1
  48. package/dist/client/assets/{agent-git-Qk00_Ilv.js → agent-git-DEl486St.js} +1 -1
  49. package/dist/client/assets/{agent-hosting-DpQzkSmA.js → agent-hosting-4LPaLHdE.js} +1 -1
  50. package/dist/client/assets/{agent-icon-B0fEYlzS.js → agent-icon-DIz0uejY.js} +1 -1
  51. package/dist/client/assets/agent-library-CoHgiZIn.js +1 -0
  52. package/dist/client/assets/agent-library-file-7lDILbsL.js +1 -0
  53. package/dist/client/assets/{agent-monitor-7fRsRp5r.js → agent-monitor-Ah3eDirJ.js} +1 -1
  54. package/dist/client/assets/{agent-overview-CI4IBzdY.js → agent-overview-8ZN9_3uB.js} +1 -1
  55. package/dist/client/assets/agent-settings-DJzG_zQJ.js +1 -0
  56. package/dist/client/assets/{agent-site-editor-D5zeaP6i.js → agent-site-editor-Bx2zsPso.js} +1 -1
  57. package/dist/client/assets/agent-site-editor-code-ClSo7cnM.js +2 -0
  58. package/dist/client/assets/agent-site-editor-content-D_UDvzRI.js +9 -0
  59. package/dist/client/assets/{agent-site-editor-preview-zrEPcj_q.js → agent-site-editor-preview-C8TBrMnH.js} +3 -3
  60. package/dist/client/assets/agent-view-BZH9Da00.js +1 -0
  61. package/dist/client/assets/{agent-view-guard-CydgwF8V.js → agent-view-guard-xEP9IoJ0.js} +1 -1
  62. package/dist/client/assets/{agents-list-Dst0vLYD.js → agents-list-CtcL4kL-.js} +1 -1
  63. package/dist/client/assets/{ai-providers-Dyx-ekUR.js → ai-providers-Dj5oaz9D.js} +1 -1
  64. package/dist/client/assets/{alert-Cs3h8VEi.js → alert-BRnmUkhb.js} +1 -1
  65. package/dist/client/assets/{alert-dialog-DJp_Ityl.js → alert-dialog-UJiEdIyw.js} +1 -1
  66. package/dist/client/assets/{analytics-sections-DCH9uTvB.js → analytics-sections-B-DAxD5H.js} +1 -1
  67. package/dist/client/assets/{api-keys-1sQjJhuB.js → api-keys-BYl5Adwp.js} +1 -1
  68. package/dist/client/assets/api-keys-OITE72q9.js +1 -0
  69. package/dist/client/assets/app-editor-BOl-YTbj.js +1 -0
  70. package/dist/client/assets/{asset-utils-CH-E2ZK-.js → asset-utils-D9rWPK_p.js} +1 -1
  71. package/dist/client/assets/{auth-D32cXta1.js → auth-DATmrrln.js} +1 -1
  72. package/dist/client/assets/{auth-catchall-DMXzCu4C.js → auth-catchall-DuCdZlsp.js} +1 -1
  73. package/dist/client/assets/{auth-entry-DUD28kAE.js → auth-entry-BLVdqtxL.js} +1 -1
  74. package/dist/client/assets/{auth-split-layout-D4hDB6K9.js → auth-split-layout-hNFBrueo.js} +1 -1
  75. package/dist/client/assets/{authenticate-and-persist-oauth-nxqo5RHp.js → authenticate-and-persist-oauth-BLoneiuH.js} +1 -1
  76. package/dist/client/assets/{automation-list-row-DKge22DJ.js → automation-list-row-BtLqQMkH.js} +1 -1
  77. package/dist/client/assets/{automation-runs-BjPF6LD5.js → automation-runs-Bd5b1WuV.js} +1 -1
  78. package/dist/client/assets/{automations-CahUqw7W.js → automations-vKqxqQNC.js} +1 -1
  79. package/dist/client/assets/{autosend-B0cwcoZQ.js → autosend-CmBucBqr.js} +1 -1
  80. package/dist/client/assets/{avatar-DSv7rQey.js → avatar-DnHqCpqr.js} +1 -1
  81. package/dist/client/assets/{badge-BVm53kyq.js → badge-DsCXhAux.js} +1 -1
  82. package/dist/client/assets/{block-document-D8cOPhhp.js → block-document-mRUILn6g.js} +1 -1
  83. package/dist/client/assets/{blocks-preview-workspace-context-BKbOMRuN.js → blocks-preview-workspace-context-B0MPCoC-.js} +1 -1
  84. package/dist/client/assets/{buckets-qN50y_8N.js → buckets-BxgRyJ_U.js} +1 -1
  85. package/dist/client/assets/{build-improve-prompt-doc-CC90CrN1.js → build-improve-prompt-doc-B3NoXNkQ.js} +1 -1
  86. package/dist/client/assets/{calendar-DJtSYtKm.js → calendar-DqQMMLc-.js} +1 -1
  87. package/dist/client/assets/{capability-load-error-BE5lkHsD.js → capability-load-error-AKSk2IJm.js} +1 -1
  88. package/dist/client/assets/{category-editor-CiXlFZY7.js → category-editor-CMD4R07W.js} +1 -1
  89. package/dist/client/assets/{chart-DqY7SXIi.js → chart-CR5bi_LF.js} +1 -1
  90. package/dist/client/assets/{chat-context-DFdcIErL.js → chat-context-BUNOOLZ7.js} +1 -1
  91. package/dist/client/assets/{chat-draft-BtGF7bzA.js → chat-draft-BTyf-RT4.js} +1 -1
  92. package/dist/client/assets/{checkbox-CKTKlc0c.js → checkbox-kO5XQBSL.js} +1 -1
  93. package/dist/client/assets/{choose-editor-Err48-Lf.js → choose-editor-B6NluJVn.js} +1 -1
  94. package/dist/client/assets/{claim-phase-copy-iLfMCvUg.js → claim-phase-copy-qWrlXIki.js} +1 -1
  95. package/dist/client/assets/{cli-auth-success-BkmZGWTI.js → cli-auth-success-AbWgCiyC.js} +1 -1
  96. package/dist/client/assets/{client-icons-DAh8_gqZ.js → client-icons-CFQbQxLU.js} +1 -1
  97. package/dist/client/assets/{collapsible-CKtvk2qR.js → collapsible-cP4qew3h.js} +1 -1
  98. package/dist/client/assets/{collection-detail-Duw5_YbG.js → collection-detail-BLv1KOfa.js} +1 -1
  99. package/dist/client/assets/{collection-display-button-CoPEzt2N.js → collection-display-button-DaMyx89l.js} +1 -1
  100. package/dist/client/assets/{collection-search-BRvScCfK.js → collection-search-Ch2FLY2_.js} +1 -1
  101. package/dist/client/assets/{collection-table-wrapper-BbFo2vuN.js → collection-table-wrapper-CHr7Adsw.js} +1 -1
  102. package/dist/client/assets/{collection-tabs-DYXVQ5CX.js → collection-tabs-DVUgETfM.js} +1 -1
  103. package/dist/client/assets/{combobox-BSDZKZEG.js → combobox-DMurdTGm.js} +1 -1
  104. package/dist/client/assets/{command-3VOIGXTI.js → command-BDRqfDOz.js} +1 -1
  105. package/dist/client/assets/{companion-mcps-section-DjksUrm1.js → companion-mcps-section-Cc2aSyu_.js} +1 -1
  106. package/dist/client/assets/{config-CB5vGL2_.js → config-FL7tBmjS.js} +1 -1
  107. package/dist/client/assets/{connect-CJcFVZSc.js → connect-DuMnksNc.js} +1 -1
  108. package/dist/client/assets/{connect-layout-Df1OVOPH.js → connect-layout-Dynemyno.js} +1 -1
  109. package/dist/client/assets/{connection-CghRZvH1.js → connection-CTmr-OMV.js} +1 -1
  110. package/dist/client/assets/{connection-card-CM7cJdHp.js → connection-card-BMQxerrE.js} +1 -1
  111. package/dist/client/assets/{connection-detail-DZj5ll2f.js → connection-detail-BYLV3H48.js} +1 -1
  112. package/dist/client/assets/{connection-form-helpers-BXAo8rkG.js → connection-form-helpers-DwWzoy-c.js} +1 -1
  113. package/dist/client/assets/{connections-DOaUllXK.js → connections-DPwWFeUy.js} +1 -1
  114. package/dist/client/assets/{context-DD8l5XSD.js → context-CB_J_TC8.js} +1 -1
  115. package/dist/client/assets/{create-organization-dialog-C_zeaDpV.js → create-organization-dialog-whUB6mPv.js} +1 -1
  116. package/dist/client/assets/{decopilot-fXzeGhfJ.js → decopilot-Bv_sAiFM.js} +1 -1
  117. package/dist/client/assets/{dialog-CYKucQEn.js → dialog-5o2urGn5.js} +1 -1
  118. package/dist/client/assets/{discover-BeDY4eoX.js → discover-oeQTrlAh.js} +1 -1
  119. package/dist/client/assets/{domain-settings-COnOYeBB.js → domain-settings-DDBWv2RW.js} +1 -1
  120. package/dist/client/assets/{download-app-dialog-ilxwkPe1.js → download-app-dialog-IVAbk28w.js} +1 -1
  121. package/dist/client/assets/{drawer-DG-A7uu9.js → drawer-CkYlAGZd.js} +1 -1
  122. package/dist/client/assets/{editor-D6m-Mg9w.js → editor-D-lV1BCh.js} +1 -1
  123. package/dist/client/assets/{empty-state-CLHHI2Dq.js → empty-state-Bm3wB0lq.js} +1 -1
  124. package/dist/client/assets/{empty-state-C-cMIo1T.js → empty-state-ae548Szk.js} +1 -1
  125. package/dist/client/assets/{extract-connection-data-B-G_DpF-.js → extract-connection-data-mgYWyu5I.js} +1 -1
  126. package/dist/client/assets/{feature-gate-CysfdGto.js → feature-gate-Cg4_Q8Ke.js} +1 -1
  127. package/dist/client/assets/{feature-paywall-D7E_OmlQ.js → feature-paywall-CNWP0h2q.js} +1 -1
  128. package/dist/client/assets/{file-explorer-CCx_G_Xm.js → file-explorer-Bnzy8sav.js} +1 -1
  129. package/dist/client/assets/{file-preview-C7iqsPcD.js → file-preview-Cd-BJ067.js} +1 -1
  130. package/dist/client/assets/{file-share-button-weodJ1fg.js → file-share-button-DpD-UIy8.js} +1 -1
  131. package/dist/client/assets/{file-type-icon-GNT0wjq6.js → file-type-icon-ChEWF5Jy.js} +1 -1
  132. package/dist/client/assets/flat-project-nbeY-YkM.js +1 -0
  133. package/dist/client/assets/{folder-icon-DNT5ZPCH.js → folder-icon-BrQ4KNEw.js} +1 -1
  134. package/dist/client/assets/{form-BuKMCQ_-.js → form-CparX5oE.js} +1 -1
  135. package/dist/client/assets/{gateway-client-BtY2d8II.js → gateway-client-DGz23Vlr.js} +1 -1
  136. package/dist/client/assets/{general-Dd-PiJly.js → general-D7PWQ7-z.js} +1 -1
  137. package/dist/client/assets/{home-CA465RbP.js → home-890Qnqbx.js} +1 -1
  138. package/dist/client/assets/{index-DzdUtt7w.js → index-33Is4zHe.js} +1 -1
  139. package/dist/client/assets/{index-ySi4Pwot.js → index-BNVSW_Xa.js} +1 -1
  140. package/dist/client/assets/{index-8DK0gqav.js → index-Bencuqrd.js} +1 -1
  141. package/dist/client/assets/{index-BJCqpqJd.js → index-Bo0F7TR2.js} +4 -4
  142. package/dist/client/assets/{index-BUGmQlES.js → index-C-t9tcus.js} +1 -1
  143. package/dist/client/assets/{index-QiV1VAG0.js → index-C4bAKRLA.js} +1 -1
  144. package/dist/client/assets/{index-B20d8ck9.js → index-C5-WvLpU.js} +1 -1
  145. package/dist/client/assets/{index-D0r-H4rb.js → index-CQV19DFZ.js} +1 -1
  146. package/dist/client/assets/{index-CGwg_b5-.js → index-CSFjWyPp.js} +1 -1
  147. package/dist/client/assets/{index-DIZnX8_b.js → index-CUa4r7Sg.js} +3 -3
  148. package/dist/client/assets/{index-X0RgFz8Y.js → index-N982P05Q.js} +1 -1
  149. package/dist/client/assets/{index-Cv3qPBot.js → index-NYSezzil.js} +1 -1
  150. package/dist/client/assets/{index-_bGtHSkW.js → index-SNhzEDgK.js} +1 -1
  151. package/dist/client/assets/{index-BMdQXKlL.js → index-brBX7xEM.js} +1 -1
  152. package/dist/client/assets/{index-redirect-COkcwXCv.js → index-redirect-C3Q4Ea2j.js} +1 -1
  153. package/dist/client/assets/{index-Bz8Yokmw.js → index-vBxL1reA.js} +1 -1
  154. package/dist/client/assets/{infiniteQueryObserver-DWdmBz6y.js → infiniteQueryObserver-CJ3Kym5O.js} +1 -1
  155. package/dist/client/assets/{infra-billing-ItyhV52m.js → infra-billing-BPGokhjB.js} +1 -1
  156. package/dist/client/assets/{input-CE59clBd.js → input-Bg2anvwf.js} +1 -1
  157. package/dist/client/assets/{input-BjKsQzeZ.js → input-CymJ2z2F.js} +1 -1
  158. package/dist/client/assets/{input-CR5CoVD3.js → input-DDDJO7Ga.js} +1 -1
  159. package/dist/client/assets/{integration-icon-BjqLrrwW.js → integration-icon-ChmmjcAp.js} +1 -1
  160. package/dist/client/assets/{label-6ZrdaA5F.js → label-CuQBcvRg.js} +1 -1
  161. package/dist/client/assets/{last-preview-page-D1GT2WOl.js → last-preview-page-Ck1yMgyH.js} +1 -1
  162. package/dist/client/assets/{layout-kv8jD_6_.js → layout-L3W31J2n.js} +1 -1
  163. package/dist/client/assets/{legacy-agents-deep-C3JURVIJ.js → legacy-agents-deep-BodINWdJ.js} +1 -1
  164. package/dist/client/assets/{legacy-main-redirect-BBWHiN88.js → legacy-main-redirect-CMY7Rgwi.js} +1 -1
  165. package/dist/client/assets/library-DTGCzA9b.js +1 -0
  166. package/dist/client/assets/{library-tab-CPVjxTSo.js → library-tab-BBYiaPlx.js} +1 -1
  167. package/dist/client/assets/{login-DDQDV_ae.js → login-_DLabRI3.js} +1 -1
  168. package/dist/client/assets/{markdown-JTzUPlKH.js → markdown-ByHIpwAl.js} +1 -1
  169. package/dist/client/assets/{mcp-app-renderer-k0tZLm07.js → mcp-app-renderer-C0Zh7icj.js} +1 -1
  170. package/dist/client/assets/{mcp-oauth-C3J5q_hp.js → mcp-oauth-C7dtavBP.js} +1 -1
  171. package/dist/client/assets/{members-CZCpvZYc.js → members-B2F-Smyi.js} +1 -1
  172. package/dist/client/assets/{message-templates-lHg6ZlFI.js → message-templates-BBwpfvEM.js} +1 -1
  173. package/dist/client/assets/{mini-report-page-C9UKk1Vu.js → mini-report-page-Cuda554v.js} +1 -1
  174. package/dist/client/assets/{mock-board-CezSoFB6.js → mock-board-C601dKME.js} +1 -1
  175. package/dist/client/assets/{monaco-editor-CKKWy-x3.js → monaco-editor-CG3zzzea.js} +1 -1
  176. package/dist/client/assets/{monitoring-stats-row-Chh148qF.js → monitoring-stats-row-D90UQUZW.js} +1 -1
  177. package/dist/client/assets/{multi-select-BF6_Adhk.js → multi-select-BkL-dpTY.js} +1 -1
  178. package/dist/client/assets/{mustache-Cu104CQF.js → mustache-FFyi4GTi.js} +1 -1
  179. package/dist/client/assets/{new-project-dialog-BmmmSjjo.js → new-project-dialog-CmsEVtp0.js} +1 -1
  180. package/dist/client/assets/{oauth-callback-ywzLtSuG.js → oauth-callback-C_kdODmn.js} +1 -1
  181. package/dist/client/assets/{oauth-callback-ai-provider-CeS8kqA6.js → oauth-callback-ai-provider-Dfv924hu.js} +1 -1
  182. package/dist/client/assets/{onboarding-ZV52ZojZ.js → onboarding-CSOdI0rM.js} +1 -1
  183. package/dist/client/assets/{optimistic-project-sidebar-views-Db3TOzmO.js → optimistic-project-sidebar-views-DkmrtEno.js} +1 -1
  184. package/dist/client/assets/{org-file-open-context-kXusxtya.js → org-file-open-context-A6PAiYSr.js} +1 -1
  185. package/dist/client/assets/{organization-choice-B0xp612m.js → organization-choice-DZORHGb2.js} +1 -1
  186. package/dist/client/assets/{orgs-BQyi9DSo.js → orgs-3aCjhk83.js} +1 -1
  187. package/dist/client/assets/{page-seo-form-J76EvRZe.js → page-seo-form-CqpdqbvS.js} +1 -1
  188. package/dist/client/assets/{pair-BolEqp4H.js → pair-BCvCT-GT.js} +1 -1
  189. package/dist/client/assets/{plan-ladder-DxETvjP6.js → plan-ladder-BwZyCGet.js} +1 -1
  190. package/dist/client/assets/{popover-CxnAOud0.js → popover-a7N6zy94.js} +1 -1
  191. package/dist/client/assets/{post-calendar-BsKIBdi3.js → post-calendar-DWa-EtOs.js} +1 -1
  192. package/dist/client/assets/{post-editor-CKJ8pkhP.js → post-editor-av0QWKfS.js} +1 -1
  193. package/dist/client/assets/{preview-content-JHqQ9fqd.js → preview-content-CKQ8AZkH.js} +1 -1
  194. package/dist/client/assets/{preview-dialog-BXXWFhIT.js → preview-dialog-eYgaESCb.js} +1 -1
  195. package/dist/client/assets/{profile-GZ4cJ3Nb.js → profile-ChpZb0yE.js} +1 -1
  196. package/dist/client/assets/{project-app-view-CQb-TK1P.js → project-app-view-CR4akuKE.js} +1 -1
  197. package/dist/client/assets/{project-feed-DWzyADfx.js → project-feed-CA_L0suZ.js} +1 -1
  198. package/dist/client/assets/{project-icon-BWs8G7QE.js → project-icon-BE7eT2UX.js} +1 -1
  199. package/dist/client/assets/project-reports-BiEV7dxJ.js +1 -0
  200. package/dist/client/assets/project-tasks-B0NPlZ-3.js +1 -0
  201. package/dist/client/assets/{projects-BnImtVuG.js → projects-C-2UITE5.js} +1 -1
  202. package/dist/client/assets/{projects-empty-state-Yja7EiQA.js → projects-empty-state-CeqZ7rP7.js} +1 -1
  203. package/dist/client/assets/{prompts-B_jhy1Zt.js → prompts-D4zN017b.js} +1 -1
  204. package/dist/client/assets/record-editor-D_uvPYcM.js +1 -0
  205. package/dist/client/assets/{redirect-editor-BTQazxtK.js → redirect-editor-W70vWVrb.js} +1 -1
  206. package/dist/client/assets/{reports-CFcJ9_dw.js → reports-1jURhkyW.js} +1 -1
  207. package/dist/client/assets/reports-C5_7ssUz.js +1 -0
  208. package/dist/client/assets/{reports-onboarding-DsFX6Q2Y.js → reports-onboarding-VDeG9MUr.js} +1 -1
  209. package/dist/client/assets/{reports-tab-BMRQLhrU.js → reports-tab-CxLnzoM4.js} +2 -2
  210. package/dist/client/assets/{repositories-Cxp5gec8.js → repositories-DFQE8EEv.js} +1 -1
  211. package/dist/client/assets/{repository-binding--R5a6meD.js → repository-binding-BGULsexx.js} +1 -1
  212. package/dist/client/assets/{repository-import-picker-zA2aRMgM.js → repository-import-picker-Blpga-5j.js} +1 -1
  213. package/dist/client/assets/{repository-picker-Ch8MjhWT.js → repository-picker-B8Yoh_bh.js} +1 -1
  214. package/dist/client/assets/{require-capability-z1ZYrtyD.js → require-capability-1wZrr2Ds.js} +1 -1
  215. package/dist/client/assets/{required-auth-layout-DrK2Ahbq.js → required-auth-layout-DJxAIvUt.js} +1 -1
  216. package/dist/client/assets/{reset-password-o9kRT8P-.js → reset-password-D2-FVHfz.js} +1 -1
  217. package/dist/client/assets/{resizable-DRo3WucN.js → resizable-DT-ha9BR.js} +1 -1
  218. package/dist/client/assets/{resolve-tab-icon-BC_jCwlY.js → resolve-tab-icon-25xT6OFp.js} +1 -1
  219. package/dist/client/assets/{review-settings-BHVALtQt.js → review-settings-DaYTV2bK.js} +1 -1
  220. package/dist/client/assets/{rich-text-link-control-CKZNrR9n.js → rich-text-link-control-Bk19iHyH.js} +1 -1
  221. package/dist/client/assets/{roles-CGFPftX7.js → roles-DbbiUQ2v.js} +1 -1
  222. package/dist/client/assets/{route-BuDFfTf7.js → route-Bo7hoS8S.js} +1 -1
  223. package/dist/client/assets/{route-CwFuHhC1.js → route-Bz1yG2e8.js} +1 -1
  224. package/dist/client/assets/route-CnHChob6.js +1 -0
  225. package/dist/client/assets/{runnable-block-editor-q8wiTpdB.js → runnable-block-editor-tki6UkBr.js} +1 -1
  226. package/dist/client/assets/{sandbox-lifecycle-context-CwxdQlSb.js → sandbox-lifecycle-context-B-LQFFsw.js} +1 -1
  227. package/dist/client/assets/schema-CJ-VqkAD.js +1 -0
  228. package/dist/client/assets/{scroll-area-dZYwQnHa.js → scroll-area-B1sX42nb.js} +1 -1
  229. package/dist/client/assets/{search-input-BBMyMvHh.js → search-input-DhsU7Ify.js} +1 -1
  230. package/dist/client/assets/{search-toggle-DcNdKksf.js → search-toggle-DmuwYEgq.js} +1 -1
  231. package/dist/client/assets/{secret-picker-D2smZAsf.js → secret-picker-Dqn44GSh.js} +1 -1
  232. package/dist/client/assets/{secrets-DEuR_SKQ.js → secrets-BdtkdwtN.js} +1 -1
  233. package/dist/client/assets/{sections-editor-CXuKyDSq.js → sections-editor-B71EyeoU.js} +1 -1
  234. package/dist/client/assets/{select-CV06ESGC.js → select-B29Xhi6X.js} +1 -1
  235. package/dist/client/assets/{select-model-9Q75oIJD.js → select-model-Dmkrjf0v.js} +1 -1
  236. package/dist/client/assets/{seo-editor-DgkdnJ38.js → seo-editor-DFJ9VsFU.js} +1 -1
  237. package/dist/client/assets/{separator-DD8SvIJt.js → separator-BgwMr24m.js} +1 -1
  238. package/dist/client/assets/{settings-tab-DrI9h0MP.js → settings-tab-BoNmfuAJ.js} +1 -1
  239. package/dist/client/assets/{sheet-COySNUi4.js → sheet-Ds43gFnt.js} +1 -1
  240. package/dist/client/assets/{shell-layout-BR24Afar.js → shell-layout-DTPbTm7i.js} +1 -1
  241. package/dist/client/assets/{skills-DBhh4jev.js → skills-Bq-81Lp0.js} +1 -1
  242. package/dist/client/assets/{sso-_tSIdymt.js → sso-oY7z8oxv.js} +1 -1
  243. package/dist/client/assets/{suggestion-CqfoTsij.js → suggestion-DSzvJMf5.js} +1 -1
  244. package/dist/client/assets/{switch-DcKRnaVG.js → switch-chDwefPP.js} +1 -1
  245. package/dist/client/assets/{synced-repos-VW_LJoE6.js → synced-repos-BlExJ0qV.js} +1 -1
  246. package/dist/client/assets/{tab-icon-glyph-Bpgp9cBx.js → tab-icon-glyph-Chq2d8cr.js} +1 -1
  247. package/dist/client/assets/{table-ChI81Khw.js → table-BFhRn6m5.js} +1 -1
  248. package/dist/client/assets/{tabs-Bhcrjsbm.js → tabs-Bq5-PfFl.js} +1 -1
  249. package/dist/client/assets/{task-board-CJjc4xI-.js → task-board-C6pPuzYa.js} +1 -1
  250. package/dist/client/assets/{task-route-DhT_vkgX.js → task-route-BnZ6hudq.js} +1 -1
  251. package/dist/client/assets/{task-status-DB9VzvnI.js → task-status-D3QqYPID.js} +1 -1
  252. package/dist/client/assets/{taskboard-analytics-D2i3U7yF.js → taskboard-analytics-BMAi2ly0.js} +1 -1
  253. package/dist/client/assets/tasks-BUP0oNUi.js +1 -0
  254. package/dist/client/assets/{tasks-JNpK11cV.js → tasks-zArzTN8t.js} +1 -1
  255. package/dist/client/assets/{textarea-BXhBwPZM.js → textarea-CE_tOq7F.js} +1 -1
  256. package/dist/client/assets/{thread-analytics-Cih69yRb.js → thread-analytics-DAmG6cwU.js} +1 -1
  257. package/dist/client/assets/{thread-button-AF1WSMlL.js → thread-button-C7RONiC_.js} +1 -1
  258. package/dist/client/assets/{thread-intent-BUShkesP.js → thread-intent-J3vN5Vs_.js} +1 -1
  259. package/dist/client/assets/{thread-route-DQM8B2sI.js → thread-route-X4GbG7FV.js} +1 -1
  260. package/dist/client/assets/{thread-route-CqYgZaDv.js → thread-route-c94iFegN.js} +1 -1
  261. package/dist/client/assets/{thread-sheet-body-DwAizuR8.js → thread-sheet-body-DMUuynmz.js} +1 -1
  262. package/dist/client/assets/{toggle-group-DVGTd7pP.js → toggle-group-DNCEl3IR.js} +1 -1
  263. package/dist/client/assets/{toolbar-icon-button-Bzitet5K.js → toolbar-icon-button-BtgLueB7.js} +1 -1
  264. package/dist/client/assets/{tooltip-DymYYuRo.js → tooltip-CbYF5mhk.js} +1 -1
  265. package/dist/client/assets/{track-BsEyW3He.js → track-DvMbEwKy.js} +1 -1
  266. package/dist/client/assets/{types-cb53ubAI.js → types-ByzlXSpq.js} +1 -1
  267. package/dist/client/assets/{usage-stats-zkwjwtUJ.js → usage-stats-Bd-A9GxK.js} +1 -1
  268. package/dist/client/assets/{use-ai-providers-BkzLFMQR.js → use-ai-providers-C99u_E8Y.js} +1 -1
  269. package/dist/client/assets/{use-automations-D1SUlKHV.js → use-automations-BcWa2mzr.js} +1 -1
  270. package/dist/client/assets/{use-autosave-CB-vej23.js → use-autosave-DCrsKem-.js} +1 -1
  271. package/dist/client/assets/{use-chat-layout-state-CRef6D4d.js → use-chat-layout-state-BWgbiPAM.js} +1 -1
  272. package/dist/client/assets/{use-connect-companion-BBvbZk76.js → use-connect-companion-DqzvyX8B.js} +1 -1
  273. package/dist/client/assets/{use-connection-rm3wb9zf.js → use-connection-x5NSsBTY.js} +1 -1
  274. package/dist/client/assets/{use-copy-Bb6V_Y-2.js → use-copy-BfHUaImm.js} +1 -1
  275. package/dist/client/assets/{use-create-virtual-mcp-EiOYXG3-.js → use-create-virtual-mcp-CeGeCrlx.js} +1 -1
  276. package/dist/client/assets/{use-date-fns-locale-C9CWZMOZ.js → use-date-fns-locale-By6eCcki.js} +1 -1
  277. package/dist/client/assets/{use-debounced-autosave-D0o2B4Xo.js → use-debounced-autosave-1STwXu9S.js} +1 -1
  278. package/dist/client/assets/{use-debounced-value-BAjT0z0V.js → use-debounced-value-ClYZnycZ.js} +1 -1
  279. package/dist/client/assets/{use-deco-credits-CayxoltY.js → use-deco-credits-BmfUoRp4.js} +1 -1
  280. package/dist/client/assets/{use-decopilot-events-BXaRjj_f.js → use-decopilot-events-Bz4QYcmu.js} +1 -1
  281. package/dist/client/assets/{use-delete-connection-CynD9NKl.js → use-delete-connection-mxqSD2MW.js} +1 -1
  282. package/dist/client/assets/{use-deployment-admin-BMoGThMy.js → use-deployment-admin-DHv7D-iA.js} +1 -1
  283. package/dist/client/assets/{use-fast-preview-draft-url-Cv_bGV8Q.js → use-fast-preview-draft-url-wdnp9Gsw.js} +1 -1
  284. package/dist/client/assets/{use-file-configs-CQr5ImoR.js → use-file-configs-B4qsGcHc.js} +1 -1
  285. package/dist/client/assets/{use-infinite-scroll-CnOZ3QQs.js → use-infinite-scroll-B8GLgbd5.js} +1 -1
  286. package/dist/client/assets/{use-join-requests-CIOXMLDr.js → use-join-requests-DaoxOszb.js} +1 -1
  287. package/dist/client/assets/{use-main-panel-tabs-Bu2rGt1b.js → use-main-panel-tabs-BUvooKW_.js} +1 -1
  288. package/dist/client/assets/{use-mcp-auth-status-DkUE1YUf.js → use-mcp-auth-status-C1FbOTFp.js} +1 -1
  289. package/dist/client/assets/{use-mcp-client-dYAEJ2Jd.js → use-mcp-client-CgAwsTXX.js} +1 -1
  290. package/dist/client/assets/{use-mcp-prompts-CytnXWFX.js → use-mcp-prompts-BIwfN9eR.js} +1 -1
  291. package/dist/client/assets/{use-mcp-tools-DKcS99WV.js → use-mcp-tools-DWBMbNzW.js} +1 -1
  292. package/dist/client/assets/{use-members-BGeBcZAI.js → use-members-B5WIwJLk.js} +1 -1
  293. package/dist/client/assets/{use-mobile-Cr6YJGI_.js → use-mobile-BTzo-yNE.js} +1 -1
  294. package/dist/client/assets/{use-navigate-to-agent-DoVNCwHy.js → use-navigate-to-agent-CUailOkl.js} +1 -1
  295. package/dist/client/assets/use-new-blocks-editor-5rrvUzSm.js +1 -0
  296. package/dist/client/assets/{use-open-billing-url-D5IYp8zD.js → use-open-billing-url-hrUTQY32.js} +1 -1
  297. package/dist/client/assets/{use-org-auth-client-Cj2S4VtF.js → use-org-auth-client-VwQi3i7g.js} +1 -1
  298. package/dist/client/assets/{use-org-fs-DBAxCQBE.js → use-org-fs-JCXip5_c.js} +1 -1
  299. package/dist/client/assets/{use-org-repo-syncs-DASdWM3g.js → use-org-repo-syncs-CeS8Ysed.js} +1 -1
  300. package/dist/client/assets/{use-org-sso-C6AFvIzX.js → use-org-sso-C9wS7ZE_.js} +1 -1
  301. package/dist/client/assets/{use-organization-roles-CdTybrJA.js → use-organization-roles-BlaiSg9K.js} +1 -1
  302. package/dist/client/assets/{use-organization-settings-B7IVGPSk.js → use-organization-settings-C-0W-ky3.js} +1 -1
  303. package/dist/client/assets/{use-panel-navigate-BDo5oxs2.js → use-panel-navigate-EwAAwlcx.js} +1 -1
  304. package/dist/client/assets/{use-project-native-view-presence-DM97JCfv.js → use-project-native-view-presence-Bh04AhwN.js} +1 -1
  305. package/dist/client/assets/{use-project-scope-ELhrNYxO.js → use-project-scope-BQkBdDIR.js} +1 -1
  306. package/dist/client/assets/{use-releases-C6by0aYf.js → use-releases-eOVPDU9o.js} +1 -1
  307. package/dist/client/assets/{use-reports-diagnostic-D6LAqZld.js → use-reports-diagnostic-BH0V95xq.js} +1 -1
  308. package/dist/client/assets/{use-secrets-CETMiKli.js → use-secrets-B9XBVByA.js} +1 -1
  309. package/dist/client/assets/{use-section-preview-base-iMXSXAXB.js → use-section-preview-base-DVGdnf65.js} +1 -1
  310. package/dist/client/assets/{use-session-runtime-7EKtYywq.js → use-session-runtime-Bi7LhVpC.js} +1 -1
  311. package/dist/client/assets/{use-tags-CGk04KKn.js → use-tags-D6lRTA5X.js} +1 -1
  312. package/dist/client/assets/{use-task-board-analytics-CcDxmijQ.js → use-task-board-analytics-BQJBm-B1.js} +1 -1
  313. package/dist/client/assets/{use-task-metadata-CHjvR9nL.js → use-task-metadata-QWnE0BBk.js} +1 -1
  314. package/dist/client/assets/{use-thread-analytics-DgyRTsuJ.js → use-thread-analytics-B_SQZb1Z.js} +1 -1
  315. package/dist/client/assets/{use-thread-outputs-BEwXZ8Vh.js → use-thread-outputs-CKvUbe8p.js} +1 -1
  316. package/dist/client/assets/useInfiniteQuery-BUmcOy3_.js +1 -0
  317. package/dist/client/assets/{useQueries-IXTpZeMS.js → useQueries-DD2WW-FQ.js} +1 -1
  318. package/dist/client/assets/useSuspenseInfiniteQuery-BBD5zNHU.js +1 -0
  319. package/dist/client/assets/{users-CRc2HLrw.js → users-hMUh3_Dc.js} +1 -1
  320. package/dist/client/assets/{utils-BHJpTmNN.js → utils-DJvBBb8P.js} +1 -1
  321. package/dist/client/assets/{variant-calendar-BVIyYUNc.js → variant-calendar-BBLtccxZ.js} +1 -1
  322. package/dist/client/assets/{variant-matcher-override-D3ZX5GGx.js → variant-matcher-override-BlA7dm-k.js} +1 -1
  323. package/dist/client/assets/{view-mode-toggle-xsYxeBhI.js → view-mode-toggle--jH7JTVP.js} +1 -1
  324. package/dist/client/assets/{virtual-mcp-Bq8CmmOy.js → virtual-mcp-OnNDTvZE.js} +1 -1
  325. package/dist/client/index.html +1 -1
  326. package/dist/server/cli.js +132 -132
  327. package/dist/server/server.js +117 -117
  328. package/package.json +1 -1
  329. package/dist/client/assets/agent-app-D7JXTBCq.js +0 -1
  330. package/dist/client/assets/agent-deck-D3yxTAhn.js +0 -1
  331. package/dist/client/assets/agent-library-BXp8X7Kb.js +0 -1
  332. package/dist/client/assets/agent-library-file-DBTLr6wD.js +0 -1
  333. package/dist/client/assets/agent-settings-B02qGu9T.js +0 -1
  334. package/dist/client/assets/agent-site-editor-code-C1rCwcip.js +0 -2
  335. package/dist/client/assets/agent-site-editor-content-D-WwcHO0.js +0 -9
  336. package/dist/client/assets/agent-view-DNB9Q5mk.js +0 -1
  337. package/dist/client/assets/api-keys-Cid803mQ.js +0 -1
  338. package/dist/client/assets/app-editor-B04OoaGI.js +0 -1
  339. package/dist/client/assets/flat-project-DTc0SWpt.js +0 -1
  340. package/dist/client/assets/library-BYCJESrt.js +0 -1
  341. package/dist/client/assets/project-reports-DWdFvTXe.js +0 -1
  342. package/dist/client/assets/project-tasks-Cvmm21fI.js +0 -1
  343. package/dist/client/assets/record-editor-CN4HNCDe.js +0 -1
  344. package/dist/client/assets/reports-ftm5Lh7G.js +0 -1
  345. package/dist/client/assets/route-Crert7MH.js +0 -1
  346. package/dist/client/assets/schema-BPGmAw0J.js +0 -1
  347. package/dist/client/assets/tasks-C9nYVcwD.js +0 -1
  348. package/dist/client/assets/use-new-blocks-editor-CTbC874V.js +0 -1
  349. package/dist/client/assets/useInfiniteQuery-CrHqvHwZ.js +0 -1
  350. package/dist/client/assets/useSuspenseInfiniteQuery-Di3mCiFx.js +0 -1
@@ -1,2 +1,2 @@
1
- import{o as Ye,j as Ge,h as ie,D as ze,p as Qe,q as Ze}from"./index-ySi4Pwot.js";import{r as p,er as Je,es as we,et,eu as j,ev as te,j as I,aO as tt,ew as nt,ex as ne,ey as ot,ez as rt,eA as st,eB as it,eC as at,eD as lt,eE as Ce,eF as ct,c as H,D as ut,K as dt,eG as ft,eH as gt,eI as mt,b as pt,l as vt,h as ht}from"./index-BJCqpqJd.js";import{g as bt,d as xt}from"./gateway-client-BtY2d8II.js";import{A as yt}from"./agent-icon-B0fEYlzS.js";var Hn=Ye;var Et=["input:not([inert]):not([inert] *)","select:not([inert]):not([inert] *)","textarea:not([inert]):not([inert] *)","a[href]:not([inert]):not([inert] *)","button:not([inert]):not([inert] *)","[tabindex]:not(slot):not([inert]):not([inert] *)","audio[controls]:not([inert]):not([inert] *)","video[controls]:not([inert]):not([inert] *)",'[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)',"details>summary:first-of-type:not([inert]):not([inert] *)","details:not([inert]):not([inert] *)"],ae=Et.join(","),Ie=typeof Element>"u",z=Ie?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,J=!Ie&&Element.prototype.getRootNode?function(n){var e;return n==null||(e=n.getRootNode)===null||e===void 0?void 0:e.call(n)}:function(n){return n?.ownerDocument},ee=function(e,t){var o;t===void 0&&(t=!0);var r=e==null||(o=e.getAttribute)===null||o===void 0?void 0:o.call(e,"inert"),s=r===""||r==="true",i=s||t&&e&&(typeof e.closest=="function"?e.closest("[inert]"):ee(e.parentNode));return i},Rt=function(e){var t,o=e==null||(t=e.getAttribute)===null||t===void 0?void 0:t.call(e,"contenteditable");return o===""||o==="true"},St=function(e,t,o){if(ee(e))return[];var r=Array.prototype.slice.apply(e.querySelectorAll(ae));return t&&z.call(e,ae)&&r.unshift(e),r=r.filter(o),r},le=function(e,t,o){for(var r=[],s=Array.from(e);s.length;){var i=s.shift();if(!ee(i,!1))if(i.tagName==="SLOT"){var a=i.assignedElements(),l=a.length?a:i.children,c=le(l,!0,o);o.flatten?r.push.apply(r,c):r.push({scopeParent:i,candidates:c})}else{var d=z.call(i,ae);d&&o.filter(i)&&(t||!e.includes(i))&&r.push(i);var u=i.shadowRoot||typeof o.getShadowRoot=="function"&&o.getShadowRoot(i),g=!ee(u,!1)&&(!o.shadowRootFilter||o.shadowRootFilter(i));if(u&&g){var h=le(u===!0?i.children:u.children,!0,o);o.flatten?r.push.apply(r,h):r.push({scopeParent:i,candidates:h})}else s.unshift.apply(s,i.children)}}return r},Te=function(e){return!isNaN(parseInt(e.getAttribute("tabindex"),10))},Pe=function(e){if(!e)throw new Error("No node provided");return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||Rt(e))&&!Te(e)?0:e.tabIndex},wt=function(e,t){var o=Pe(e);return o<0&&t&&!Te(e)?0:o},Ct=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},Ae=function(e){return e.tagName==="INPUT"},It=function(e){return Ae(e)&&e.type==="hidden"},Tt=function(e){var t=e.tagName==="DETAILS"&&Array.prototype.slice.apply(e.children).some(function(o){return o.tagName==="SUMMARY"});return t},Pt=function(e,t){for(var o=0;o<e.length;o++)if(e[o].checked&&e[o].form===t)return e[o]},At=function(e){if(!e.name)return!0;var t=e.form||J(e),o=function(a){return t.querySelectorAll('input[type="radio"][name="'+a+'"]')},r;if(typeof window<"u"&&typeof window.CSS<"u"&&typeof window.CSS.escape=="function")r=o(window.CSS.escape(e.name));else try{r=o(e.name)}catch(i){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",i.message),!1}var s=Pt(r,e.form);return!s||s===e},Nt=function(e){return Ae(e)&&e.type==="radio"},Dt=function(e){return Nt(e)&&!At(e)},Mt=function(e){var t,o=e&&J(e),r=(t=o)===null||t===void 0?void 0:t.host,s=!1;if(o&&o!==e){var i,a,l;for(s=!!((i=r)!==null&&i!==void 0&&(a=i.ownerDocument)!==null&&a!==void 0&&a.contains(r)||e!=null&&(l=e.ownerDocument)!==null&&l!==void 0&&l.contains(e));!s&&r;){var c,d,u;o=J(r),r=(c=o)===null||c===void 0?void 0:c.host,s=!!((d=r)!==null&&d!==void 0&&(u=d.ownerDocument)!==null&&u!==void 0&&u.contains(r))}}return s},ge=function(e){var t=e.getBoundingClientRect(),o=t.width,r=t.height;return o===0&&r===0},Ot=function(e,t){var o=t.displayCheck,r=t.getShadowRoot;if(o==="full-native"&&"checkVisibility"in e){var s=e.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});return!s}if(getComputedStyle(e).visibility==="hidden")return!0;var i=z.call(e,"details>summary:first-of-type"),a=i?e.parentElement:e;if(z.call(a,"details:not([open]) *"))return!0;if(!o||o==="full"||o==="full-native"||o==="legacy-full"){if(typeof r=="function"){for(var l=e;e;){var c=e.parentElement,d=J(e);if(c&&!c.shadowRoot&&r(c)===!0)return ge(e);e.assignedSlot?e=e.assignedSlot:!c&&d!==e.ownerDocument?e=d.host:e=c}e=l}if(Mt(e))return!e.getClientRects().length;if(o!=="legacy-full")return!0}else if(o==="non-zero-area")return ge(e);return!1},Ft=function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if(t.tagName==="FIELDSET"&&t.disabled){for(var o=0;o<t.children.length;o++){var r=t.children.item(o);if(r.tagName==="LEGEND")return z.call(t,"fieldset[disabled] *")?!0:!r.contains(e)}return!0}t=t.parentElement}return!1},qt=function(e,t){return!(t.disabled||It(t)||Ot(t,e)||Tt(t)||Ft(t))},me=function(e,t){return!(Dt(t)||Pe(t)<0||!qt(e,t))},$t=function(e){var t=parseInt(e.getAttribute("tabindex"),10);return!!(isNaN(t)||t>=0)},Ne=function(e){var t=[],o=[];return e.forEach(function(r,s){var i=!!r.scopeParent,a=i?r.scopeParent:r,l=wt(a,i),c=i?Ne(r.candidates):a;l===0?i?t.push.apply(t,c):t.push(a):o.push({documentOrder:s,tabIndex:l,item:r,isScope:i,content:c})}),o.sort(Ct).reduce(function(r,s){return s.isScope?r.push.apply(r,s.content):r.push(s.content),r},[]).concat(t)},De=function(e,t){t=t||{};var o;return t.getShadowRoot?o=le([e],t.includeContainer,{filter:me.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:$t}):o=St(e,t.includeContainer,me.bind(null,t)),Ne(o)};function kt(){return/apple/i.test(navigator.vendor)}const pe="data-floating-ui-focusable";function _t(n){let e=n.activeElement;for(;((t=e)==null||(t=t.shadowRoot)==null?void 0:t.activeElement)!=null;){var t;e=e.shadowRoot.activeElement}return e}function ce(n,e){if(!n||!e)return!1;const t=e.getRootNode==null?void 0:e.getRootNode();if(n.contains(e))return!0;if(t&&Je(t)){let o=e;for(;o;){if(n===o)return!0;o=o.parentNode||o.host}}return!1}function G(n){return"composedPath"in n?n.composedPath()[0]:n.target}function oe(n,e){if(e==null)return!1;if("composedPath"in n)return n.composedPath().includes(e);const t=n;return t.target!=null&&e.contains(t.target)}function Lt(n){return n.matches("html,body")}function Q(n){return n?.ownerDocument||document}function jt(n){return n?n.hasAttribute(pe)?n:n.querySelector("["+pe+"]")||n:null}function Z(n,e,t){return t===void 0&&(t=!0),n.filter(r=>{var s;return r.parentId===e&&(!t||((s=r.context)==null?void 0:s.open))}).flatMap(r=>[r,...Z(n,r.id,t)])}function Kt(n){return"nativeEvent"in n}var Bt=typeof document<"u",Ut=function(){},V=Bt?p.useLayoutEffect:Ut;const Vt={...we},Wt=Vt.useInsertionEffect,Ht=Wt||(n=>n());function W(n){const e=p.useRef(()=>{});return Ht(()=>{e.current=n}),p.useCallback(function(){for(var t=arguments.length,o=new Array(t),r=0;r<t;r++)o[r]=arguments[r];return e.current==null?void 0:e.current(...o)},[])}const Me=()=>({getShadowRoot:!0,displayCheck:typeof ResizeObserver=="function"&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function Oe(n,e){const t=De(n,Me()),o=t.length;if(o===0)return;const r=_t(Q(n)),s=t.indexOf(r),i=s===-1?e===1?0:o-1:s+e;return t[i]}function Xt(n){return Oe(Q(n).body,1)||n}function Yt(n){return Oe(Q(n).body,-1)||n}function re(n,e){const t=e||n.currentTarget,o=n.relatedTarget;return!o||!ce(t,o)}function Gt(n){De(n,Me()).forEach(t=>{t.dataset.tabindex=t.getAttribute("tabindex")||"",t.setAttribute("tabindex","-1")})}function ve(n){n.querySelectorAll("[data-tabindex]").forEach(t=>{const o=t.dataset.tabindex;delete t.dataset.tabindex,o?t.setAttribute("tabindex",o):t.removeAttribute("tabindex")})}const zt="data-floating-ui-focusable",he="active",be="selected",Qt={...we};let xe=!1,Zt=0;const ye=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+Zt++;function Jt(){const[n,e]=p.useState(()=>xe?ye():void 0);return V(()=>{n==null&&e(ye())},[]),p.useEffect(()=>{xe=!0},[]),n}const en=Qt.useId,ue=en||Jt;function tn(){const n=new Map;return{emit(e,t){var o;(o=n.get(e))==null||o.forEach(r=>r(t))},on(e,t){n.has(e)||n.set(e,new Set),n.get(e).add(t)},off(e,t){var o;(o=n.get(e))==null||o.delete(t)}}}const nn=p.createContext(null),on=p.createContext(null),Fe=()=>{var n;return((n=p.useContext(nn))==null?void 0:n.id)||null},qe=()=>p.useContext(on);function de(n){return"data-floating-ui-"+n}const rn={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"fixed",whiteSpace:"nowrap",width:"1px",top:0,left:0},Ee=p.forwardRef(function(e,t){const[o,r]=p.useState();V(()=>{kt()&&r("button")},[]);const s={ref:t,tabIndex:0,role:o,"aria-hidden":o?void 0:!0,[de("focus-guard")]:"",style:rn};return I.jsx("span",{...e,...s})}),sn={clipPath:"inset(50%)",position:"fixed",top:0,left:0},$e=p.createContext(null),Re=de("portal");function an(n){n===void 0&&(n={});const{id:e,root:t}=n,o=ue(),r=cn(),[s,i]=p.useState(null),a=p.useRef(null);return V(()=>()=>{s?.remove(),queueMicrotask(()=>{a.current=null})},[s]),V(()=>{if(!o||a.current)return;const l=e?document.getElementById(e):null;if(!l)return;const c=document.createElement("div");c.id=o,c.setAttribute(Re,""),l.appendChild(c),a.current=c,i(c)},[e,o]),V(()=>{if(t===null||!o||a.current)return;let l=t||r?.portalNode;l&&!it(l)&&(l=l.current),l=l||document.body;let c=null;e&&(c=document.createElement("div"),c.id=e,l.appendChild(c));const d=document.createElement("div");d.id=o,d.setAttribute(Re,""),l=c||l,l.appendChild(d),a.current=d,i(d)},[e,t,o,r]),s}function ln(n){const{children:e,id:t,root:o,preserveTabOrder:r=!0}=n,s=an({id:t,root:o}),[i,a]=p.useState(null),l=p.useRef(null),c=p.useRef(null),d=p.useRef(null),u=p.useRef(null),g=i?.modal,h=i?.open,y=!!i&&!i.modal&&i.open&&r&&!!(o||s);return p.useEffect(()=>{if(!s||!r||g)return;function m(f){s&&re(f)&&(f.type==="focusin"?ve:Gt)(s)}return s.addEventListener("focusin",m,!0),s.addEventListener("focusout",m,!0),()=>{s.removeEventListener("focusin",m,!0),s.removeEventListener("focusout",m,!0)}},[s,r,g]),p.useEffect(()=>{s&&(h||ve(s))},[h,s]),I.jsxs($e.Provider,{value:p.useMemo(()=>({preserveTabOrder:r,beforeOutsideRef:l,afterOutsideRef:c,beforeInsideRef:d,afterInsideRef:u,portalNode:s,setFocusManagerState:a}),[r,s]),children:[y&&s&&I.jsx(Ee,{"data-type":"outside",ref:l,onFocus:m=>{if(re(m,s)){var f;(f=d.current)==null||f.focus()}else{const x=i?i.domReference:null,b=Yt(x);b?.focus()}}}),y&&s&&I.jsx("span",{"aria-owns":s.id,style:sn}),s&&tt.createPortal(e,s),y&&s&&I.jsx(Ee,{"data-type":"outside",ref:c,onFocus:m=>{if(re(m,s)){var f;(f=u.current)==null||f.focus()}else{const x=i?i.domReference:null,b=Xt(x);b?.focus(),i?.closeOnFocusOut&&i?.onOpenChange(!1,m.nativeEvent,"focus-out")}}})]})}const cn=()=>p.useContext($e),un={pointerdown:"onPointerDown",mousedown:"onMouseDown",click:"onClick"},dn={pointerdown:"onPointerDownCapture",mousedown:"onMouseDownCapture",click:"onClickCapture"},Se=n=>{var e,t;return{escapeKey:typeof n=="boolean"?n:(e=n?.escapeKey)!=null?e:!1,outsidePress:typeof n=="boolean"?n:(t=n?.outsidePress)!=null?t:!0}};function fn(n,e){e===void 0&&(e={});const{open:t,onOpenChange:o,elements:r,dataRef:s}=n,{enabled:i=!0,escapeKey:a=!0,outsidePress:l=!0,outsidePressEvent:c="pointerdown",referencePress:d=!1,referencePressEvent:u="pointerdown",ancestorScroll:g=!1,bubbles:h,capture:y}=e,m=qe(),f=W(typeof l=="function"?l:()=>!1),x=typeof l=="function"?f:l,b=p.useRef(!1),{escapeKey:E,outsidePress:v}=Se(h),{escapeKey:D,outsidePress:C}=Se(y),O=p.useRef(!1),A=W(R=>{var S;if(!t||!i||!a||R.key!=="Escape"||O.current)return;const P=(S=s.current.floatingContext)==null?void 0:S.nodeId,M=m?Z(m.nodesRef.current,P):[];if(!E&&(R.stopPropagation(),M.length>0)){let w=!0;if(M.forEach(N=>{var q;if((q=N.context)!=null&&q.open&&!N.context.dataRef.current.__escapeKeyBubbles){w=!1;return}}),!w)return}o(!1,Kt(R)?R.nativeEvent:R,"escape-key")}),F=W(R=>{var S;const P=()=>{var M;A(R),(M=G(R))==null||M.removeEventListener("keydown",P)};(S=G(R))==null||S.addEventListener("keydown",P)}),T=W(R=>{var S;const P=s.current.insideReactTree;s.current.insideReactTree=!1;const M=b.current;if(b.current=!1,c==="click"&&M||P||typeof x=="function"&&!x(R))return;const w=G(R),N="["+de("inert")+"]",q=Q(r.floating).querySelectorAll(N);let L=j(w)?w:null;for(;L&&!ne(L);){const k=ot(L);if(ne(k)||!j(k))break;L=k}if(q.length&&j(w)&&!Lt(w)&&!ce(w,r.floating)&&Array.from(q).every(k=>!ce(L,k)))return;if(rt(w)&&K){const k=ne(w),B=st(w),Y=/auto|scroll/,Ke=k||Y.test(B.overflowX),Be=k||Y.test(B.overflowY),Ue=Ke&&w.clientWidth>0&&w.scrollWidth>w.clientWidth,Ve=Be&&w.clientHeight>0&&w.scrollHeight>w.clientHeight,We=B.direction==="rtl",He=Ve&&(We?R.offsetX<=w.offsetWidth-w.clientWidth:R.offsetX>w.clientWidth),Xe=Ue&&R.offsetY>w.clientHeight;if(He||Xe)return}const U=(S=s.current.floatingContext)==null?void 0:S.nodeId,X=m&&Z(m.nodesRef.current,U).some(k=>{var B;return oe(R,(B=k.context)==null?void 0:B.elements.floating)});if(oe(R,r.floating)||oe(R,r.domReference)||X)return;const fe=m?Z(m.nodesRef.current,U):[];if(fe.length>0){let k=!0;if(fe.forEach(B=>{var Y;if((Y=B.context)!=null&&Y.open&&!B.context.dataRef.current.__outsidePressBubbles){k=!1;return}}),!k)return}o(!1,R,"outside-press")}),$=W(R=>{var S;const P=()=>{var M;T(R),(M=G(R))==null||M.removeEventListener(c,P)};(S=G(R))==null||S.addEventListener(c,P)});p.useEffect(()=>{if(!t||!i)return;s.current.__escapeKeyBubbles=E,s.current.__outsidePressBubbles=v;let R=-1;function S(q){o(!1,q,"ancestor-scroll")}function P(){window.clearTimeout(R),O.current=!0}function M(){R=window.setTimeout(()=>{O.current=!1},nt()?5:0)}const w=Q(r.floating);a&&(w.addEventListener("keydown",D?F:A,D),w.addEventListener("compositionstart",P),w.addEventListener("compositionend",M)),x&&w.addEventListener(c,C?$:T,C);let N=[];return g&&(j(r.domReference)&&(N=te(r.domReference)),j(r.floating)&&(N=N.concat(te(r.floating))),!j(r.reference)&&r.reference&&r.reference.contextElement&&(N=N.concat(te(r.reference.contextElement)))),N=N.filter(q=>{var L;return q!==((L=w.defaultView)==null?void 0:L.visualViewport)}),N.forEach(q=>{q.addEventListener("scroll",S,{passive:!0})}),()=>{a&&(w.removeEventListener("keydown",D?F:A,D),w.removeEventListener("compositionstart",P),w.removeEventListener("compositionend",M)),x&&w.removeEventListener(c,C?$:T,C),N.forEach(q=>{q.removeEventListener("scroll",S)}),window.clearTimeout(R)}},[s,r,a,x,c,t,o,g,i,E,v,A,D,F,T,C,$]),p.useEffect(()=>{s.current.insideReactTree=!1},[s,x,c]);const _=p.useMemo(()=>({onKeyDown:A,...d&&{[un[u]]:R=>{o(!1,R.nativeEvent,"reference-press")},...u!=="click"&&{onClick(R){o(!1,R.nativeEvent,"reference-press")}}}}),[A,o,d,u]),K=p.useMemo(()=>{function R(S){S.button===0&&(b.current=!0)}return{onKeyDown:A,onMouseDown:R,onMouseUp:R,[dn[c]]:()=>{s.current.insideReactTree=!0}}},[A,c,s]);return p.useMemo(()=>i?{reference:_,floating:K}:{},[i,_,K])}function gn(n){const{open:e=!1,onOpenChange:t,elements:o}=n,r=ue(),s=p.useRef({}),[i]=p.useState(()=>tn()),a=Fe()!=null,[l,c]=p.useState(o.reference),d=W((h,y,m)=>{s.current.openEvent=h?y:void 0,i.emit("openchange",{open:h,event:y,reason:m,nested:a}),t?.(h,y,m)}),u=p.useMemo(()=>({setPositionReference:c}),[]),g=p.useMemo(()=>({reference:l||o.reference||null,floating:o.floating||null,domReference:o.reference}),[l,o.reference,o.floating]);return p.useMemo(()=>({dataRef:s,open:e,onOpenChange:d,elements:g,events:i,floatingId:r,refs:u}),[e,d,g,i,r,u])}function mn(n){n===void 0&&(n={});const{nodeId:e}=n,t=gn({...n,elements:{reference:null,floating:null,...n.elements}}),o=n.rootContext||t,r=o.elements,[s,i]=p.useState(null),[a,l]=p.useState(null),d=r?.domReference||s,u=p.useRef(null),g=qe();V(()=>{d&&(u.current=d)},[d]);const h=et({...n,elements:{...r,...a&&{reference:a}}}),y=p.useCallback(E=>{const v=j(E)?{getBoundingClientRect:()=>E.getBoundingClientRect(),getClientRects:()=>E.getClientRects(),contextElement:E}:E;l(v),h.refs.setReference(v)},[h.refs]),m=p.useCallback(E=>{(j(E)||E===null)&&(u.current=E,i(E)),(j(h.refs.reference.current)||h.refs.reference.current===null||E!==null&&!j(E))&&h.refs.setReference(E)},[h.refs]),f=p.useMemo(()=>({...h.refs,setReference:m,setPositionReference:y,domReference:u}),[h.refs,m,y]),x=p.useMemo(()=>({...h.elements,domReference:d}),[h.elements,d]),b=p.useMemo(()=>({...h,...o,refs:f,elements:x,nodeId:e}),[h,f,x,e,o]);return V(()=>{o.dataRef.current.floatingContext=b;const E=g?.nodesRef.current.find(v=>v.id===e);E&&(E.context=b)}),p.useMemo(()=>({...h,context:b,refs:f,elements:x}),[h,f,x,b])}function se(n,e,t){const o=new Map,r=t==="item";let s=n;if(r&&n){const{[he]:i,[be]:a,...l}=n;s=l}return{...t==="floating"&&{tabIndex:-1,[zt]:""},...s,...e.map(i=>{const a=i?i[t]:null;return typeof a=="function"?n?a(n):null:a}).concat(n).reduce((i,a)=>(a&&Object.entries(a).forEach(l=>{let[c,d]=l;if(!(r&&[he,be].includes(c)))if(c.indexOf("on")===0){if(o.has(c)||o.set(c,[]),typeof d=="function"){var u;(u=o.get(c))==null||u.push(d),i[c]=function(){for(var g,h=arguments.length,y=new Array(h),m=0;m<h;m++)y[m]=arguments[m];return(g=o.get(c))==null?void 0:g.map(f=>f(...y)).find(f=>f!==void 0)}}}else i[c]=d}),i),{})}}function pn(n){n===void 0&&(n=[]);const e=n.map(a=>a?.reference),t=n.map(a=>a?.floating),o=n.map(a=>a?.item),r=p.useCallback(a=>se(a,n,"reference"),e),s=p.useCallback(a=>se(a,n,"floating"),t),i=p.useCallback(a=>se(a,n,"item"),o);return p.useMemo(()=>({getReferenceProps:r,getFloatingProps:s,getItemProps:i}),[r,s,i])}const vn=new Map([["select","listbox"],["combobox","listbox"],["label",!1]]);function hn(n,e){var t,o;e===void 0&&(e={});const{open:r,elements:s,floatingId:i}=n,{enabled:a=!0,role:l="dialog"}=e,c=ue(),d=((t=s.domReference)==null?void 0:t.id)||c,u=p.useMemo(()=>{var b;return((b=jt(s.floating))==null?void 0:b.id)||i},[s.floating,i]),g=(o=vn.get(l))!=null?o:l,y=Fe()!=null,m=p.useMemo(()=>g==="tooltip"||l==="label"?{["aria-"+(l==="label"?"labelledby":"describedby")]:r?u:void 0}:{"aria-expanded":r?"true":"false","aria-haspopup":g==="alertdialog"?"dialog":g,"aria-controls":r?u:void 0,...g==="listbox"&&{role:"combobox"},...g==="menu"&&{id:d},...g==="menu"&&y&&{role:"menuitem"},...l==="select"&&{"aria-autocomplete":"none"},...l==="combobox"&&{"aria-autocomplete":"list"}},[g,u,y,r,d,l]),f=p.useMemo(()=>{const b={id:u,...g&&{role:g}};return g==="tooltip"||l==="label"?b:{...b,...g==="menu"&&{"aria-labelledby":d}}},[g,u,d,l]),x=p.useCallback(b=>{let{active:E,selected:v}=b;const D={role:"option",...E&&{id:u+"-fui-option"}};switch(l){case"select":case"combobox":return{...D,"aria-selected":v}}return{}},[u,l]);return p.useMemo(()=>a?{reference:m,floating:f,item:x}:{},[a,m,f,x])}function bn(n){var e;const{char:t,allowSpaces:o,allowToIncludeChar:r,allowedPrefixes:s,startOfLine:i,$position:a}=n,l=o&&!r,c=Ze(t),d=new RegExp(`\\s${c}$`),u=i?"^":"",g=r?"":c,h=l?new RegExp(`${u}${c}.*?(?=\\s${g}|$)`,"gm"):new RegExp(`${u}(?:^)?${c}[^\\s${g}]*`,"gm"),y=((e=a.nodeBefore)===null||e===void 0?void 0:e.isText)&&a.nodeBefore.text;if(!y)return null;const m=a.pos-y.length,f=Array.from(y.matchAll(h)).pop();if(!f||f.input===void 0||f.index===void 0)return null;const x=f.input.slice(Math.max(0,f.index-1),f.index),b=new RegExp(`^[${s?.join("")}\0]?$`).test(x);if(s!==null&&!b)return null;const E=m+f.index;let v=E+f[0].length;return l&&d.test(y.slice(v-1,v+1))&&(f[0]+=" ",v+=1),E<a.pos&&v>=a.pos?{range:{from:E,to:v},query:f[0].slice(t.length),text:f[0]}:null}function xn(n){return n.docChanged?n.steps.some(e=>{const t=e.slice;if(!t?.content)return!1;const o=t.content.textBetween(0,t.content.size,`
1
+ import{o as Ye,j as Ge,h as ie,D as ze,p as Qe,q as Ze}from"./index-BNVSW_Xa.js";import{r as p,er as Je,es as we,et,eu as j,ev as te,j as I,aO as tt,ew as nt,ex as ne,ey as ot,ez as rt,eA as st,eB as it,eC as at,eD as lt,eE as Ce,eF as ct,c as H,D as ut,K as dt,eG as ft,eH as gt,eI as mt,b as pt,l as vt,h as ht}from"./index-Bo0F7TR2.js";import{g as bt,d as xt}from"./gateway-client-DGz23Vlr.js";import{A as yt}from"./agent-icon-DIz0uejY.js";var Hn=Ye;var Et=["input:not([inert]):not([inert] *)","select:not([inert]):not([inert] *)","textarea:not([inert]):not([inert] *)","a[href]:not([inert]):not([inert] *)","button:not([inert]):not([inert] *)","[tabindex]:not(slot):not([inert]):not([inert] *)","audio[controls]:not([inert]):not([inert] *)","video[controls]:not([inert]):not([inert] *)",'[contenteditable]:not([contenteditable="false"]):not([inert]):not([inert] *)',"details>summary:first-of-type:not([inert]):not([inert] *)","details:not([inert]):not([inert] *)"],ae=Et.join(","),Ie=typeof Element>"u",z=Ie?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,J=!Ie&&Element.prototype.getRootNode?function(n){var e;return n==null||(e=n.getRootNode)===null||e===void 0?void 0:e.call(n)}:function(n){return n?.ownerDocument},ee=function(e,t){var o;t===void 0&&(t=!0);var r=e==null||(o=e.getAttribute)===null||o===void 0?void 0:o.call(e,"inert"),s=r===""||r==="true",i=s||t&&e&&(typeof e.closest=="function"?e.closest("[inert]"):ee(e.parentNode));return i},Rt=function(e){var t,o=e==null||(t=e.getAttribute)===null||t===void 0?void 0:t.call(e,"contenteditable");return o===""||o==="true"},St=function(e,t,o){if(ee(e))return[];var r=Array.prototype.slice.apply(e.querySelectorAll(ae));return t&&z.call(e,ae)&&r.unshift(e),r=r.filter(o),r},le=function(e,t,o){for(var r=[],s=Array.from(e);s.length;){var i=s.shift();if(!ee(i,!1))if(i.tagName==="SLOT"){var a=i.assignedElements(),l=a.length?a:i.children,c=le(l,!0,o);o.flatten?r.push.apply(r,c):r.push({scopeParent:i,candidates:c})}else{var d=z.call(i,ae);d&&o.filter(i)&&(t||!e.includes(i))&&r.push(i);var u=i.shadowRoot||typeof o.getShadowRoot=="function"&&o.getShadowRoot(i),g=!ee(u,!1)&&(!o.shadowRootFilter||o.shadowRootFilter(i));if(u&&g){var h=le(u===!0?i.children:u.children,!0,o);o.flatten?r.push.apply(r,h):r.push({scopeParent:i,candidates:h})}else s.unshift.apply(s,i.children)}}return r},Te=function(e){return!isNaN(parseInt(e.getAttribute("tabindex"),10))},Pe=function(e){if(!e)throw new Error("No node provided");return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||Rt(e))&&!Te(e)?0:e.tabIndex},wt=function(e,t){var o=Pe(e);return o<0&&t&&!Te(e)?0:o},Ct=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},Ae=function(e){return e.tagName==="INPUT"},It=function(e){return Ae(e)&&e.type==="hidden"},Tt=function(e){var t=e.tagName==="DETAILS"&&Array.prototype.slice.apply(e.children).some(function(o){return o.tagName==="SUMMARY"});return t},Pt=function(e,t){for(var o=0;o<e.length;o++)if(e[o].checked&&e[o].form===t)return e[o]},At=function(e){if(!e.name)return!0;var t=e.form||J(e),o=function(a){return t.querySelectorAll('input[type="radio"][name="'+a+'"]')},r;if(typeof window<"u"&&typeof window.CSS<"u"&&typeof window.CSS.escape=="function")r=o(window.CSS.escape(e.name));else try{r=o(e.name)}catch(i){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",i.message),!1}var s=Pt(r,e.form);return!s||s===e},Nt=function(e){return Ae(e)&&e.type==="radio"},Dt=function(e){return Nt(e)&&!At(e)},Mt=function(e){var t,o=e&&J(e),r=(t=o)===null||t===void 0?void 0:t.host,s=!1;if(o&&o!==e){var i,a,l;for(s=!!((i=r)!==null&&i!==void 0&&(a=i.ownerDocument)!==null&&a!==void 0&&a.contains(r)||e!=null&&(l=e.ownerDocument)!==null&&l!==void 0&&l.contains(e));!s&&r;){var c,d,u;o=J(r),r=(c=o)===null||c===void 0?void 0:c.host,s=!!((d=r)!==null&&d!==void 0&&(u=d.ownerDocument)!==null&&u!==void 0&&u.contains(r))}}return s},ge=function(e){var t=e.getBoundingClientRect(),o=t.width,r=t.height;return o===0&&r===0},Ot=function(e,t){var o=t.displayCheck,r=t.getShadowRoot;if(o==="full-native"&&"checkVisibility"in e){var s=e.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});return!s}if(getComputedStyle(e).visibility==="hidden")return!0;var i=z.call(e,"details>summary:first-of-type"),a=i?e.parentElement:e;if(z.call(a,"details:not([open]) *"))return!0;if(!o||o==="full"||o==="full-native"||o==="legacy-full"){if(typeof r=="function"){for(var l=e;e;){var c=e.parentElement,d=J(e);if(c&&!c.shadowRoot&&r(c)===!0)return ge(e);e.assignedSlot?e=e.assignedSlot:!c&&d!==e.ownerDocument?e=d.host:e=c}e=l}if(Mt(e))return!e.getClientRects().length;if(o!=="legacy-full")return!0}else if(o==="non-zero-area")return ge(e);return!1},Ft=function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if(t.tagName==="FIELDSET"&&t.disabled){for(var o=0;o<t.children.length;o++){var r=t.children.item(o);if(r.tagName==="LEGEND")return z.call(t,"fieldset[disabled] *")?!0:!r.contains(e)}return!0}t=t.parentElement}return!1},qt=function(e,t){return!(t.disabled||It(t)||Ot(t,e)||Tt(t)||Ft(t))},me=function(e,t){return!(Dt(t)||Pe(t)<0||!qt(e,t))},$t=function(e){var t=parseInt(e.getAttribute("tabindex"),10);return!!(isNaN(t)||t>=0)},Ne=function(e){var t=[],o=[];return e.forEach(function(r,s){var i=!!r.scopeParent,a=i?r.scopeParent:r,l=wt(a,i),c=i?Ne(r.candidates):a;l===0?i?t.push.apply(t,c):t.push(a):o.push({documentOrder:s,tabIndex:l,item:r,isScope:i,content:c})}),o.sort(Ct).reduce(function(r,s){return s.isScope?r.push.apply(r,s.content):r.push(s.content),r},[]).concat(t)},De=function(e,t){t=t||{};var o;return t.getShadowRoot?o=le([e],t.includeContainer,{filter:me.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:$t}):o=St(e,t.includeContainer,me.bind(null,t)),Ne(o)};function kt(){return/apple/i.test(navigator.vendor)}const pe="data-floating-ui-focusable";function _t(n){let e=n.activeElement;for(;((t=e)==null||(t=t.shadowRoot)==null?void 0:t.activeElement)!=null;){var t;e=e.shadowRoot.activeElement}return e}function ce(n,e){if(!n||!e)return!1;const t=e.getRootNode==null?void 0:e.getRootNode();if(n.contains(e))return!0;if(t&&Je(t)){let o=e;for(;o;){if(n===o)return!0;o=o.parentNode||o.host}}return!1}function G(n){return"composedPath"in n?n.composedPath()[0]:n.target}function oe(n,e){if(e==null)return!1;if("composedPath"in n)return n.composedPath().includes(e);const t=n;return t.target!=null&&e.contains(t.target)}function Lt(n){return n.matches("html,body")}function Q(n){return n?.ownerDocument||document}function jt(n){return n?n.hasAttribute(pe)?n:n.querySelector("["+pe+"]")||n:null}function Z(n,e,t){return t===void 0&&(t=!0),n.filter(r=>{var s;return r.parentId===e&&(!t||((s=r.context)==null?void 0:s.open))}).flatMap(r=>[r,...Z(n,r.id,t)])}function Kt(n){return"nativeEvent"in n}var Bt=typeof document<"u",Ut=function(){},V=Bt?p.useLayoutEffect:Ut;const Vt={...we},Wt=Vt.useInsertionEffect,Ht=Wt||(n=>n());function W(n){const e=p.useRef(()=>{});return Ht(()=>{e.current=n}),p.useCallback(function(){for(var t=arguments.length,o=new Array(t),r=0;r<t;r++)o[r]=arguments[r];return e.current==null?void 0:e.current(...o)},[])}const Me=()=>({getShadowRoot:!0,displayCheck:typeof ResizeObserver=="function"&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function Oe(n,e){const t=De(n,Me()),o=t.length;if(o===0)return;const r=_t(Q(n)),s=t.indexOf(r),i=s===-1?e===1?0:o-1:s+e;return t[i]}function Xt(n){return Oe(Q(n).body,1)||n}function Yt(n){return Oe(Q(n).body,-1)||n}function re(n,e){const t=e||n.currentTarget,o=n.relatedTarget;return!o||!ce(t,o)}function Gt(n){De(n,Me()).forEach(t=>{t.dataset.tabindex=t.getAttribute("tabindex")||"",t.setAttribute("tabindex","-1")})}function ve(n){n.querySelectorAll("[data-tabindex]").forEach(t=>{const o=t.dataset.tabindex;delete t.dataset.tabindex,o?t.setAttribute("tabindex",o):t.removeAttribute("tabindex")})}const zt="data-floating-ui-focusable",he="active",be="selected",Qt={...we};let xe=!1,Zt=0;const ye=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+Zt++;function Jt(){const[n,e]=p.useState(()=>xe?ye():void 0);return V(()=>{n==null&&e(ye())},[]),p.useEffect(()=>{xe=!0},[]),n}const en=Qt.useId,ue=en||Jt;function tn(){const n=new Map;return{emit(e,t){var o;(o=n.get(e))==null||o.forEach(r=>r(t))},on(e,t){n.has(e)||n.set(e,new Set),n.get(e).add(t)},off(e,t){var o;(o=n.get(e))==null||o.delete(t)}}}const nn=p.createContext(null),on=p.createContext(null),Fe=()=>{var n;return((n=p.useContext(nn))==null?void 0:n.id)||null},qe=()=>p.useContext(on);function de(n){return"data-floating-ui-"+n}const rn={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"fixed",whiteSpace:"nowrap",width:"1px",top:0,left:0},Ee=p.forwardRef(function(e,t){const[o,r]=p.useState();V(()=>{kt()&&r("button")},[]);const s={ref:t,tabIndex:0,role:o,"aria-hidden":o?void 0:!0,[de("focus-guard")]:"",style:rn};return I.jsx("span",{...e,...s})}),sn={clipPath:"inset(50%)",position:"fixed",top:0,left:0},$e=p.createContext(null),Re=de("portal");function an(n){n===void 0&&(n={});const{id:e,root:t}=n,o=ue(),r=cn(),[s,i]=p.useState(null),a=p.useRef(null);return V(()=>()=>{s?.remove(),queueMicrotask(()=>{a.current=null})},[s]),V(()=>{if(!o||a.current)return;const l=e?document.getElementById(e):null;if(!l)return;const c=document.createElement("div");c.id=o,c.setAttribute(Re,""),l.appendChild(c),a.current=c,i(c)},[e,o]),V(()=>{if(t===null||!o||a.current)return;let l=t||r?.portalNode;l&&!it(l)&&(l=l.current),l=l||document.body;let c=null;e&&(c=document.createElement("div"),c.id=e,l.appendChild(c));const d=document.createElement("div");d.id=o,d.setAttribute(Re,""),l=c||l,l.appendChild(d),a.current=d,i(d)},[e,t,o,r]),s}function ln(n){const{children:e,id:t,root:o,preserveTabOrder:r=!0}=n,s=an({id:t,root:o}),[i,a]=p.useState(null),l=p.useRef(null),c=p.useRef(null),d=p.useRef(null),u=p.useRef(null),g=i?.modal,h=i?.open,y=!!i&&!i.modal&&i.open&&r&&!!(o||s);return p.useEffect(()=>{if(!s||!r||g)return;function m(f){s&&re(f)&&(f.type==="focusin"?ve:Gt)(s)}return s.addEventListener("focusin",m,!0),s.addEventListener("focusout",m,!0),()=>{s.removeEventListener("focusin",m,!0),s.removeEventListener("focusout",m,!0)}},[s,r,g]),p.useEffect(()=>{s&&(h||ve(s))},[h,s]),I.jsxs($e.Provider,{value:p.useMemo(()=>({preserveTabOrder:r,beforeOutsideRef:l,afterOutsideRef:c,beforeInsideRef:d,afterInsideRef:u,portalNode:s,setFocusManagerState:a}),[r,s]),children:[y&&s&&I.jsx(Ee,{"data-type":"outside",ref:l,onFocus:m=>{if(re(m,s)){var f;(f=d.current)==null||f.focus()}else{const x=i?i.domReference:null,b=Yt(x);b?.focus()}}}),y&&s&&I.jsx("span",{"aria-owns":s.id,style:sn}),s&&tt.createPortal(e,s),y&&s&&I.jsx(Ee,{"data-type":"outside",ref:c,onFocus:m=>{if(re(m,s)){var f;(f=u.current)==null||f.focus()}else{const x=i?i.domReference:null,b=Xt(x);b?.focus(),i?.closeOnFocusOut&&i?.onOpenChange(!1,m.nativeEvent,"focus-out")}}})]})}const cn=()=>p.useContext($e),un={pointerdown:"onPointerDown",mousedown:"onMouseDown",click:"onClick"},dn={pointerdown:"onPointerDownCapture",mousedown:"onMouseDownCapture",click:"onClickCapture"},Se=n=>{var e,t;return{escapeKey:typeof n=="boolean"?n:(e=n?.escapeKey)!=null?e:!1,outsidePress:typeof n=="boolean"?n:(t=n?.outsidePress)!=null?t:!0}};function fn(n,e){e===void 0&&(e={});const{open:t,onOpenChange:o,elements:r,dataRef:s}=n,{enabled:i=!0,escapeKey:a=!0,outsidePress:l=!0,outsidePressEvent:c="pointerdown",referencePress:d=!1,referencePressEvent:u="pointerdown",ancestorScroll:g=!1,bubbles:h,capture:y}=e,m=qe(),f=W(typeof l=="function"?l:()=>!1),x=typeof l=="function"?f:l,b=p.useRef(!1),{escapeKey:E,outsidePress:v}=Se(h),{escapeKey:D,outsidePress:C}=Se(y),O=p.useRef(!1),A=W(R=>{var S;if(!t||!i||!a||R.key!=="Escape"||O.current)return;const P=(S=s.current.floatingContext)==null?void 0:S.nodeId,M=m?Z(m.nodesRef.current,P):[];if(!E&&(R.stopPropagation(),M.length>0)){let w=!0;if(M.forEach(N=>{var q;if((q=N.context)!=null&&q.open&&!N.context.dataRef.current.__escapeKeyBubbles){w=!1;return}}),!w)return}o(!1,Kt(R)?R.nativeEvent:R,"escape-key")}),F=W(R=>{var S;const P=()=>{var M;A(R),(M=G(R))==null||M.removeEventListener("keydown",P)};(S=G(R))==null||S.addEventListener("keydown",P)}),T=W(R=>{var S;const P=s.current.insideReactTree;s.current.insideReactTree=!1;const M=b.current;if(b.current=!1,c==="click"&&M||P||typeof x=="function"&&!x(R))return;const w=G(R),N="["+de("inert")+"]",q=Q(r.floating).querySelectorAll(N);let L=j(w)?w:null;for(;L&&!ne(L);){const k=ot(L);if(ne(k)||!j(k))break;L=k}if(q.length&&j(w)&&!Lt(w)&&!ce(w,r.floating)&&Array.from(q).every(k=>!ce(L,k)))return;if(rt(w)&&K){const k=ne(w),B=st(w),Y=/auto|scroll/,Ke=k||Y.test(B.overflowX),Be=k||Y.test(B.overflowY),Ue=Ke&&w.clientWidth>0&&w.scrollWidth>w.clientWidth,Ve=Be&&w.clientHeight>0&&w.scrollHeight>w.clientHeight,We=B.direction==="rtl",He=Ve&&(We?R.offsetX<=w.offsetWidth-w.clientWidth:R.offsetX>w.clientWidth),Xe=Ue&&R.offsetY>w.clientHeight;if(He||Xe)return}const U=(S=s.current.floatingContext)==null?void 0:S.nodeId,X=m&&Z(m.nodesRef.current,U).some(k=>{var B;return oe(R,(B=k.context)==null?void 0:B.elements.floating)});if(oe(R,r.floating)||oe(R,r.domReference)||X)return;const fe=m?Z(m.nodesRef.current,U):[];if(fe.length>0){let k=!0;if(fe.forEach(B=>{var Y;if((Y=B.context)!=null&&Y.open&&!B.context.dataRef.current.__outsidePressBubbles){k=!1;return}}),!k)return}o(!1,R,"outside-press")}),$=W(R=>{var S;const P=()=>{var M;T(R),(M=G(R))==null||M.removeEventListener(c,P)};(S=G(R))==null||S.addEventListener(c,P)});p.useEffect(()=>{if(!t||!i)return;s.current.__escapeKeyBubbles=E,s.current.__outsidePressBubbles=v;let R=-1;function S(q){o(!1,q,"ancestor-scroll")}function P(){window.clearTimeout(R),O.current=!0}function M(){R=window.setTimeout(()=>{O.current=!1},nt()?5:0)}const w=Q(r.floating);a&&(w.addEventListener("keydown",D?F:A,D),w.addEventListener("compositionstart",P),w.addEventListener("compositionend",M)),x&&w.addEventListener(c,C?$:T,C);let N=[];return g&&(j(r.domReference)&&(N=te(r.domReference)),j(r.floating)&&(N=N.concat(te(r.floating))),!j(r.reference)&&r.reference&&r.reference.contextElement&&(N=N.concat(te(r.reference.contextElement)))),N=N.filter(q=>{var L;return q!==((L=w.defaultView)==null?void 0:L.visualViewport)}),N.forEach(q=>{q.addEventListener("scroll",S,{passive:!0})}),()=>{a&&(w.removeEventListener("keydown",D?F:A,D),w.removeEventListener("compositionstart",P),w.removeEventListener("compositionend",M)),x&&w.removeEventListener(c,C?$:T,C),N.forEach(q=>{q.removeEventListener("scroll",S)}),window.clearTimeout(R)}},[s,r,a,x,c,t,o,g,i,E,v,A,D,F,T,C,$]),p.useEffect(()=>{s.current.insideReactTree=!1},[s,x,c]);const _=p.useMemo(()=>({onKeyDown:A,...d&&{[un[u]]:R=>{o(!1,R.nativeEvent,"reference-press")},...u!=="click"&&{onClick(R){o(!1,R.nativeEvent,"reference-press")}}}}),[A,o,d,u]),K=p.useMemo(()=>{function R(S){S.button===0&&(b.current=!0)}return{onKeyDown:A,onMouseDown:R,onMouseUp:R,[dn[c]]:()=>{s.current.insideReactTree=!0}}},[A,c,s]);return p.useMemo(()=>i?{reference:_,floating:K}:{},[i,_,K])}function gn(n){const{open:e=!1,onOpenChange:t,elements:o}=n,r=ue(),s=p.useRef({}),[i]=p.useState(()=>tn()),a=Fe()!=null,[l,c]=p.useState(o.reference),d=W((h,y,m)=>{s.current.openEvent=h?y:void 0,i.emit("openchange",{open:h,event:y,reason:m,nested:a}),t?.(h,y,m)}),u=p.useMemo(()=>({setPositionReference:c}),[]),g=p.useMemo(()=>({reference:l||o.reference||null,floating:o.floating||null,domReference:o.reference}),[l,o.reference,o.floating]);return p.useMemo(()=>({dataRef:s,open:e,onOpenChange:d,elements:g,events:i,floatingId:r,refs:u}),[e,d,g,i,r,u])}function mn(n){n===void 0&&(n={});const{nodeId:e}=n,t=gn({...n,elements:{reference:null,floating:null,...n.elements}}),o=n.rootContext||t,r=o.elements,[s,i]=p.useState(null),[a,l]=p.useState(null),d=r?.domReference||s,u=p.useRef(null),g=qe();V(()=>{d&&(u.current=d)},[d]);const h=et({...n,elements:{...r,...a&&{reference:a}}}),y=p.useCallback(E=>{const v=j(E)?{getBoundingClientRect:()=>E.getBoundingClientRect(),getClientRects:()=>E.getClientRects(),contextElement:E}:E;l(v),h.refs.setReference(v)},[h.refs]),m=p.useCallback(E=>{(j(E)||E===null)&&(u.current=E,i(E)),(j(h.refs.reference.current)||h.refs.reference.current===null||E!==null&&!j(E))&&h.refs.setReference(E)},[h.refs]),f=p.useMemo(()=>({...h.refs,setReference:m,setPositionReference:y,domReference:u}),[h.refs,m,y]),x=p.useMemo(()=>({...h.elements,domReference:d}),[h.elements,d]),b=p.useMemo(()=>({...h,...o,refs:f,elements:x,nodeId:e}),[h,f,x,e,o]);return V(()=>{o.dataRef.current.floatingContext=b;const E=g?.nodesRef.current.find(v=>v.id===e);E&&(E.context=b)}),p.useMemo(()=>({...h,context:b,refs:f,elements:x}),[h,f,x,b])}function se(n,e,t){const o=new Map,r=t==="item";let s=n;if(r&&n){const{[he]:i,[be]:a,...l}=n;s=l}return{...t==="floating"&&{tabIndex:-1,[zt]:""},...s,...e.map(i=>{const a=i?i[t]:null;return typeof a=="function"?n?a(n):null:a}).concat(n).reduce((i,a)=>(a&&Object.entries(a).forEach(l=>{let[c,d]=l;if(!(r&&[he,be].includes(c)))if(c.indexOf("on")===0){if(o.has(c)||o.set(c,[]),typeof d=="function"){var u;(u=o.get(c))==null||u.push(d),i[c]=function(){for(var g,h=arguments.length,y=new Array(h),m=0;m<h;m++)y[m]=arguments[m];return(g=o.get(c))==null?void 0:g.map(f=>f(...y)).find(f=>f!==void 0)}}}else i[c]=d}),i),{})}}function pn(n){n===void 0&&(n=[]);const e=n.map(a=>a?.reference),t=n.map(a=>a?.floating),o=n.map(a=>a?.item),r=p.useCallback(a=>se(a,n,"reference"),e),s=p.useCallback(a=>se(a,n,"floating"),t),i=p.useCallback(a=>se(a,n,"item"),o);return p.useMemo(()=>({getReferenceProps:r,getFloatingProps:s,getItemProps:i}),[r,s,i])}const vn=new Map([["select","listbox"],["combobox","listbox"],["label",!1]]);function hn(n,e){var t,o;e===void 0&&(e={});const{open:r,elements:s,floatingId:i}=n,{enabled:a=!0,role:l="dialog"}=e,c=ue(),d=((t=s.domReference)==null?void 0:t.id)||c,u=p.useMemo(()=>{var b;return((b=jt(s.floating))==null?void 0:b.id)||i},[s.floating,i]),g=(o=vn.get(l))!=null?o:l,y=Fe()!=null,m=p.useMemo(()=>g==="tooltip"||l==="label"?{["aria-"+(l==="label"?"labelledby":"describedby")]:r?u:void 0}:{"aria-expanded":r?"true":"false","aria-haspopup":g==="alertdialog"?"dialog":g,"aria-controls":r?u:void 0,...g==="listbox"&&{role:"combobox"},...g==="menu"&&{id:d},...g==="menu"&&y&&{role:"menuitem"},...l==="select"&&{"aria-autocomplete":"none"},...l==="combobox"&&{"aria-autocomplete":"list"}},[g,u,y,r,d,l]),f=p.useMemo(()=>{const b={id:u,...g&&{role:g}};return g==="tooltip"||l==="label"?b:{...b,...g==="menu"&&{"aria-labelledby":d}}},[g,u,d,l]),x=p.useCallback(b=>{let{active:E,selected:v}=b;const D={role:"option",...E&&{id:u+"-fui-option"}};switch(l){case"select":case"combobox":return{...D,"aria-selected":v}}return{}},[u,l]);return p.useMemo(()=>a?{reference:m,floating:f,item:x}:{},[a,m,f,x])}function bn(n){var e;const{char:t,allowSpaces:o,allowToIncludeChar:r,allowedPrefixes:s,startOfLine:i,$position:a}=n,l=o&&!r,c=Ze(t),d=new RegExp(`\\s${c}$`),u=i?"^":"",g=r?"":c,h=l?new RegExp(`${u}${c}.*?(?=\\s${g}|$)`,"gm"):new RegExp(`${u}(?:^)?${c}[^\\s${g}]*`,"gm"),y=((e=a.nodeBefore)===null||e===void 0?void 0:e.isText)&&a.nodeBefore.text;if(!y)return null;const m=a.pos-y.length,f=Array.from(y.matchAll(h)).pop();if(!f||f.input===void 0||f.index===void 0)return null;const x=f.input.slice(Math.max(0,f.index-1),f.index),b=new RegExp(`^[${s?.join("")}\0]?$`).test(x);if(s!==null&&!b)return null;const E=m+f.index;let v=E+f[0].length;return l&&d.test(y.slice(v-1,v+1))&&(f[0]+=" ",v+=1),E<a.pos&&v>=a.pos?{range:{from:E,to:v},query:f[0].slice(t.length),text:f[0]}:null}function xn(n){return n.docChanged?n.steps.some(e=>{const t=e.slice;if(!t?.content)return!1;const o=t.content.textBetween(0,t.content.size,`
2
2
  `);return/\s/.test(o)}):!1}function yn(n){return()=>{const e=n.state.selection.$anchor.pos,{top:t,right:o,bottom:r,left:s}=n.view.coordsAtPos(e);try{return new DOMRect(s,t,o-s,r-t)}catch{return null}}}function En(n,e,t,o){return t?()=>{const r=o.getState(n.state),s=r?.decorationId,i=e.dom.querySelector(`[data-decoration-id="${s}"]`);return i?.getBoundingClientRect()||null}:yn(n)}function Rn({match:n,dismissedRange:e,state:t,transaction:o,editor:r,shouldResetDismissed:s,effectiveAllowSpaces:i}){return s?.({editor:r,state:t,range:e,match:n,transaction:o,allowSpaces:i})?!1:i?n.range.from===e.from:n.range.from===e.from&&!xn(o)}function Sn({view:n,pluginKeyRef:e}){const t=n.state.tr.setMeta(e,{exit:!0});n.dispatch(t)}function wn({pluginKey:n,decorationTag:e,decorationClass:t,decorationContent:o,decorationEmptyClass:r,renderer:s,dispatchExit:i}){return{handleKeyDown(a,l){var c;const d=n.getState(a.state);if(!d.active)return!1;if(l.key==="Escape"||l.key==="Esc"){var u;return s==null||(u=s.onKeyDown)===null||u===void 0||u.call(s,{view:a,event:l,range:d.range}),i(a),!0}return(s==null||(c=s.onKeyDown)===null||c===void 0?void 0:c.call(s,{view:a,event:l,range:d.range}))||!1},decorations(a){const{active:l,range:c,decorationId:d,query:u}=n.getState(a);if(!l)return null;const g=!u?.length,h=[t];return g&&h.push(r),ze.create(a.doc,[Qe.inline(c.from,c.to,{nodeName:e,class:h.join(" "),"data-decoration-id":d||void 0,"data-decoration-content":o})])}}}function Cn({editor:n,char:e,effectiveAllowSpaces:t,allowToIncludeChar:o,allowedPrefixes:r,startOfLine:s,findSuggestionMatch:i,allow:a,shouldShow:l,shouldKeepDismissed:c,pluginKey:d}){return{init(){return{active:!1,range:{from:0,to:0},query:null,text:null,composing:!1,dismissedRange:null}},apply(u,g,h,y){const{isEditable:m}=n,{composing:f}=n.view,{selection:x}=u,{empty:b,from:E}=x,v={...g},D=u.getMeta(d);if(D&&D.exit)return v.active=!1,v.decorationId=null,v.range={from:0,to:0},v.query=null,v.text=null,v.dismissedRange=g.active?{...g.range}:g.dismissedRange,v;if(v.composing=f,u.docChanged&&v.dismissedRange!==null&&(v.dismissedRange={from:u.mapping.map(v.dismissedRange.from),to:u.mapping.map(v.dismissedRange.to)}),m&&(b||n.view.composing)){(E<g.range.from||E>g.range.to)&&!f&&!g.composing&&(v.active=!1);const C=i({char:e,allowSpaces:t,allowToIncludeChar:o,allowedPrefixes:r,startOfLine:s,$position:x.$from}),O=`id_${Math.floor(Math.random()*4294967295)}`;C&&a({editor:n,state:y,range:C.range,isActive:g.active})&&(!l||l({editor:n,range:C.range,query:C.query,text:C.text,transaction:u}))?(v.dismissedRange!==null&&!c({match:C,dismissedRange:v.dismissedRange,state:y,transaction:u})&&(v.dismissedRange=null),v.dismissedRange===null?(v.active=!0,v.decorationId=g.decorationId||O,v.range=C.range,v.query=C.query,v.text=C.text):v.active=!1):(C||(v.dismissedRange=null),v.active=!1)}else v.active=!1;return v.active||(v.decorationId=null,v.range={from:0,to:0},v.query=null,v.text=null),v}}}function In({editor:n,items:e}){let t=null,o=null,r=null;const s=()=>{o!==null&&(clearTimeout(o),o=null),r?.(),r=null},i=c=>new Promise(d=>{r=d,o=setTimeout(()=>{o=null;const u=r;r=null,u?.()},c)}),a=()=>{t?.abort(),s(),t=null};return{abort:a,fetch:async(c,d)=>{a(),t=new AbortController;const u=t;if(d>0&&await i(d),t!==u||u.signal.aborted)return{status:"aborted"};try{const g=await e({editor:n,query:c,signal:u.signal});return t!==u||u.signal.aborted?{status:"aborted"}:{status:"resolved",items:g}}catch{return t!==u||u.signal.aborted?{status:"aborted"}:{status:"error"}}}}}function Tn({placement:n,offset:e,flip:t,floatingUi:o}){var r,s,i,a;const l=[at({mainAxis:(r=e.mainAxis)!==null&&r!==void 0?r:4,crossAxis:(s=e.crossAxis)!==null&&s!==void 0?s:0})];return t&&l.push(lt()),!(o==null||(i=o.middleware)===null||i===void 0)&&i.length&&l.push(...o.middleware),{placement:n,strategy:(a=o?.strategy)!==null&&a!==void 0?a:"absolute",middleware:l}}function Pn(n){if(n instanceof HTMLElement)return n;if(typeof n=="string")try{const e=document.querySelector(n);if(e)return e}catch{return document.body}return document.body}function An({getReferenceRect:n,contextElement:e,config:t,container:o,dismissOnOutsideClick:r,dismiss:s}){return(i,a={})=>{const l={getBoundingClientRect:()=>{var y;return(y=n())!==null&&y!==void 0?y:new DOMRect},contextElement:e};let c=!1;const d=!i.isConnected;d&&Pn(o).appendChild(i),a.onPosition||(i.style.visibility="hidden",i.style.width="max-content");const g=Ce(l,i,()=>{ct(l,i,{placement:t.placement,strategy:t.strategy,middleware:t.middleware}).then(({x:y,y:m,placement:f,strategy:x})=>{if(a.onPosition){a.onPosition({x:y,y:m,placement:f,strategy:x});return}Object.assign(i.style,{position:x,left:`${y}px`,top:`${m}px`}),c||(c=!0,i.style.visibility="")})},a.autoUpdate);let h;return r&&(h=y=>{const m=y.target;!(m instanceof Node)||i.contains(m)||e.contains(m)||s()},document.addEventListener("pointerdown",h,!0)),()=>{g(),h&&document.removeEventListener("pointerdown",h,!0),d&&i.remove()}}}function Nn({editor:n,pluginKey:e,items:t,renderer:o,minQueryLength:r,debounce:s,initialItems:i,placement:a,offset:l,container:c,flip:d,floatingUi:u,dismissOnOutsideClick:g,command:h,clientRectFor:y,dispatchExit:m}){let f;const x=In({editor:n,items:t}),b=Tn({placement:a,offset:l,flip:d,floatingUi:u});function E(v,D){switch(v){case"started":var C;o==null||(C=o.onStart)===null||C===void 0||C.call(o,D);break;case"updated":var O;o==null||(O=o.onUpdate)===null||O===void 0||O.call(o,D);break;case"stopped":var A;o==null||(A=o.onExit)===null||A===void 0||A.call(o,D)}}return{update:async(v,D)=>{var C,O;const A=e.getState(D),F=e.getState(v.state);if(!A||!F)return;let T=null;const $=A.query!==F.query,_=A.text!==F.text,K=A.range.from!==F.range.from||A.range.to!==F.range.to,R=$||_||K;if(!A.active&&F.active)T="started";else if(A.active&&!F.active)T="stopped";else if(F.active&&R)T="updated";else return;const S=T==="stopped"?A:F,P=v.dom.querySelector(`[data-decoration-id="${S.decorationId}"]`),M=y(v,P),w=r===0||(S.query?S.query.length>=r:!1),N=(T==="started"||T==="updated")&&w;if(f={editor:n,range:S.range,query:S.query||"",text:S.text||"",items:i??[],command:U=>h({editor:n,range:S.range,props:U}),decorationNode:P,clientRect:M,loading:N,placement:a,offset:{mainAxis:(C=l.mainAxis)!==null&&C!==void 0?C:4,crossAxis:(O=l.crossAxis)!==null&&O!==void 0?O:0},container:c,flip:d,floatingUi:b,mount:An({getReferenceRect:M,contextElement:v.dom,config:b,container:c,dismissOnOutsideClick:g,dismiss:()=>m(n.view)})},T==="started"){var q;o==null||(q=o.onBeforeStart)===null||q===void 0||q.call(o,f)}if(T==="updated"){var L;o==null||(L=o.onBeforeUpdate)===null||L===void 0||L.call(o,f)}if(T==="started"&&E(T,f),T==="started"||T==="updated")if(!N)x.abort(),f={...f,items:i??[],loading:!1};else{f={...f,items:i??[],loading:!0},T="updated",E(T,f);const U=await x.fetch(S.query||"",s);if(U.status==="aborted")return;const X=e.getState(v.state);if(!X?.active){x.abort();return}f=U.status==="resolved"?{...f,items:U.items,loading:!1}:{...f,loading:!1}}if(T==="stopped"){x.abort(),E(T,f),f=void 0;return}T==="updated"&&E(T,f)},destroy:()=>{var v;x.abort(),f&&(o==null||(v=o.onExit)===null||v===void 0||v.call(o,f))}}}const ke=new ie("suggestion");function _e({pluginKey:n=ke,editor:e,char:t="@",allowSpaces:o=!1,allowToIncludeChar:r=!1,allowedPrefixes:s=[" "],startOfLine:i=!1,decorationTag:a="span",decorationClass:l="suggestion",decorationContent:c="",decorationEmptyClass:d="is-empty",command:u=()=>null,items:g=()=>[],minQueryLength:h=0,debounce:y=0,initialItems:m,placement:f="bottom-start",offset:x={},container:b,flip:E=!0,floatingUi:v,dismissOnOutsideClick:D=!0,render:C=()=>({}),allow:O=()=>!0,findSuggestionMatch:A=bn,shouldShow:F,shouldResetDismissed:T}){const $=C?.(),_=o&&!r,K=(P,M)=>En(e,P,M,n);function R(P){return Rn({...P,editor:e,shouldResetDismissed:T,effectiveAllowSpaces:_})}const S=P=>Sn({view:P,pluginKeyRef:n});return new Ge({key:n,view:()=>Nn({editor:e,pluginKey:n,items:g,renderer:$,minQueryLength:h,debounce:y,initialItems:m,placement:f,offset:x,container:b,flip:E,floatingUi:v,dismissOnOutsideClick:D,command:u,clientRectFor:K,dispatchExit:S}),state:Cn({editor:e,char:t,effectiveAllowSpaces:_,allowToIncludeChar:r,allowedPrefixes:s,startOfLine:i,findSuggestionMatch:A,allow:O,shouldShow:F,shouldKeepDismissed:R,pluginKey:n}),props:wn({pluginKey:n,decorationTag:a,decorationClass:l,decorationContent:c,decorationEmptyClass:d,renderer:$,dispatchExit:S})})}function Xn(n,e=ke){const t=n.state.tr.setMeta(e,{exit:!0});n.dispatch(t)}var Yn=_e;function Dn(n){const e=H.c(17),{editor:t,query:o,items:r,onSelect:s,onClose:i}=n,[a,l]=p.useState(0),c=p.useRef(r),d=p.useRef(a),u=p.useRef(s),g=p.useRef(i),h=p.useDeferredValue(o),[y,m]=p.useState(h);y!==h&&(m(h),l(0)),a>=r.length&&r.length>0&&l(0);let f,x;e[0]!==r?(f=()=>{c.current=r},x=[r],e[0]=r,e[1]=f,e[2]=x):(f=e[1],x=e[2]),p.useEffect(f,x);let b,E;e[3]!==a?(b=()=>{d.current=a},E=[a],e[3]=a,e[4]=b,e[5]=E):(b=e[4],E=e[5]),p.useEffect(b,E);let v,D;e[6]!==s?(v=()=>{u.current=s},D=[s],e[6]=s,e[7]=v,e[8]=D):(v=e[7],D=e[8]),p.useEffect(v,D);let C,O;e[9]!==i?(C=()=>{g.current=i},O=[i],e[9]=i,e[10]=C,e[11]=O):(C=e[10],O=e[11]),p.useEffect(C,O);let A,F;e[12]!==t?(F=()=>{if(t?.isDestroyed)return;let _;try{_=t.view.dom}catch{return}if(!_)return;const K=S=>{const P=c.current;if(!P.length)return!1;const M=()=>l(N=>(N+1)%P.length),w=()=>l(N=>(N-1+P.length)%P.length);switch(S.key){case"ArrowUp":return S.preventDefault(),w(),!0;case"ArrowDown":return S.preventDefault(),M(),!0;case"Tab":return S.preventDefault(),S.shiftKey?w():M(),!0;case"Home":return S.preventDefault(),l(0),!0;case"End":return S.preventDefault(),l(P.length-1),!0;case"Enter":{if(S.isComposing)return!1;S.preventDefault();const N=d.current;return N!==-1&&P[N]&&u.current?.(P[N],N),!0}case"Escape":return S.preventDefault(),g.current?.(),!0;default:return!1}},R=S=>{K(S)};return _.addEventListener("keydown",R,!0),()=>{_?.removeEventListener("keydown",R,!0)}},A=[t],e[12]=t,e[13]=A,e[14]=F):(A=e[13],F=e[14]),p.useEffect(F,A);const T=r.length?a:void 0;let $;return e[15]!==T?($={selectedIndex:T,setSelectedIndex:l},e[15]=T,e[16]=$):$=e[16],$}function Mn(n,e){switch(e.type){case"SET_SELECTED_ITEM":return{...n,selectedItem:e.payload};case"ON_START":return{...n,open:!0,selectedItem:null,element:e.payload.element,query:e.payload.query,range:e.payload.range};case"ON_UPDATE":return{...n,element:e.payload.element,query:e.payload.query,range:e.payload.range};case"ON_EXIT":return{open:!1,element:null,query:"",range:null,selectedItem:null};default:return n}}const Le=p.createContext(void 0);function je(){const n=p.useContext(Le);if(!n)throw new Error("useSuggestionContext must be used within a SuggestionContext.Provider");return n}function On(n){const e=H.c(16),{editor:t,char:o,pluginKey:r,allow:s,onOpenChange:i}=n;let a;e[0]===Symbol.for("react.memo_cache_sentinel")?(a={open:!1,element:null,query:"",range:null,selectedItem:null},e[0]=a):a=e[0];const[l,c]=p.useReducer(Mn,a);let d;e[1]!==i?(d=m=>{i?.(m)},e[1]=i,e[2]=d):d=e[2];const u=p.useEffectEvent(d);let g;e[3]!==o||e[4]!==s||e[5]!==t||e[6]!==u||e[7]!==r?(g=()=>{if(t?.isDestroyed)return;const m=r instanceof ie?r:new ie(r);t.state.plugins.find(b=>b.spec.key===m)&&t.unregisterPlugin(m);const x=_e({pluginKey:m,editor:t,char:o,allow(b){const E=t.state.doc.resolve(b.range.from);for(let v=E.depth;v>0;v--)if(E.node(v).type.name==="image")return!1;return!(s&&!s(b))},command(){},render:()=>({onStart:b=>{c({type:"ON_START",payload:{element:b.decorationNode??null,query:b.query,range:b.range}}),u(!0)},onUpdate:b=>{c({type:"ON_UPDATE",payload:{element:b.decorationNode??null,query:b.query,range:b.range}})},onKeyDown:b=>b.event.key==="Escape"?(c({type:"ON_EXIT"}),!0):!1,onExit:()=>{c({type:"ON_EXIT"}),u(!1)}}),items:Fn});return t.registerPlugin(x),()=>{t?.isDestroyed||t.unregisterPlugin(m)}},e[3]=o,e[4]=s,e[5]=t,e[6]=u,e[7]=r,e[8]=g):g=e[8];let h;e[9]!==o||e[10]!==s||e[11]!==t||e[12]!==r?(h=[t,r,o,c,s],e[9]=o,e[10]=s,e[11]=t,e[12]=r,e[13]=h):h=e[13],p.useEffect(g,h);let y;return e[14]!==l?(y={state:l,dispatch:c},e[14]=l,e[15]=y):y=e[15],y}function Fn(){return[]}function qn({editor:n,queryKey:e,queryFn:t,onSelect:o}){const{state:r,dispatch:s}=je(),i=p.useDeferredValue(r.query),{data:a}=ut({queryKey:dt.suggestionItems(e,r.open,i),queryFn:()=>r.open?t({query:i}):[]}),l=()=>{s({type:"ON_EXIT"})},c=async(u,g)=>{if(!(r.selectedItem!==null||!r.range)){s({type:"SET_SELECTED_ITEM",payload:u});try{const{view:h}=n,m=h.state.selection.$to.nodeAfter?.text?.startsWith(" "),f=r.range?{...r.range}:{from:0,to:0};m&&r.range&&(f.to+=1),await o({range:f,item:u})===!1?s({type:"SET_SELECTED_ITEM",payload:null}):l()}catch{l()}}},{selectedIndex:d}=Dn({editor:n,query:i,items:a,onSelect:c,onClose:l});return{selectedItem:r.selectedItem,items:a,selectedIndex:d,close:l,onSelect:c}}function $n({children:n}){const{state:e,dispatch:t}=je(),{open:o,element:r}=e,s=()=>{t({type:"ON_EXIT"})},{refs:i,floatingStyles:a,context:l}=mn({placement:"bottom-start",open:o,onOpenChange:g=>{g||s()},elements:{reference:r},middleware:[ft(10),gt(),mt()],whileElementsMounted:Ce}),c=fn(l,{outsidePress:g=>!(g.target instanceof Element&&g.target.closest(".ProseMirror"))}),d=hn(l,{role:"listbox"}),{getFloatingProps:u}=pn([c,d]);return o?I.jsx(ln,{children:I.jsx("div",{ref:i.setFloating,style:a,...u(),className:"z-50 w-auto min-w-[360px] max-w-[520px] rounded-lg border bg-popover p-0 text-popover-foreground shadow-md outline-hidden overflow-hidden",children:n})}):null}const kn=n=>{const e=H.c(17),{item:t,isSelected:o,onSelect:r,isLoading:s,ref:i,renderItem:a}=n;let l;if(e[0]!==t){const x=bt(t._meta);l=t.title||xt(t.name,x),e[0]=t,e[1]=l}else l=e[1];const c=l,d=t.description||null,u=t.icon,g=o&&"bg-accent text-accent-foreground",h=s&&"pointer-events-none opacity-50";let y;e[2]!==g||e[3]!==h?(y=vt("relative flex w-full cursor-pointer select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none transition-colors","hover:bg-accent hover:text-accent-foreground","focus:bg-accent focus:text-accent-foreground",g,h),e[2]=g,e[3]=h,e[4]=y):y=e[4];let m;e[5]!==d||e[6]!==u||e[7]!==s||e[8]!==t||e[9]!==c||e[10]!==a?(m=a?a(t):I.jsxs(I.Fragment,{children:[u!==void 0&&I.jsx(yt,{icon:u,name:c,size:"xs",className:"mr-2"}),I.jsxs("div",{className:"flex flex-col gap-0.5 flex-1 min-w-0",children:[I.jsxs("div",{className:"flex items-center justify-between gap-2",children:[I.jsx("span",{className:"font-medium flex items-center truncate capitalize",children:c}),s&&I.jsx(ht,{size:"xs"})]}),d&&I.jsx("div",{className:"text-xs text-muted-foreground line-clamp-1",children:d})]}),t.drillable&&I.jsx("kbd",{className:"shrink-0 ml-2 px-1.5 py-0.5 text-[10px] font-medium text-muted-foreground bg-muted border border-border rounded",children:"↵"})]}),e[5]=d,e[6]=u,e[7]=s,e[8]=t,e[9]=c,e[10]=a,e[11]=m):m=e[11];let f;return e[12]!==r||e[13]!==i||e[14]!==y||e[15]!==m?(f=I.jsx("div",{ref:i,onClick:r,className:y,children:m}),e[12]=r,e[13]=i,e[14]=y,e[15]=m,e[16]=f):f=e[16],f},_n=n=>{const e=H.c(24),{editor:t,queryKey:o,queryFn:r,onSelect:s,renderItem:i,emptyLabel:a}=n,l=pt();let c;e[0]!==t||e[1]!==s||e[2]!==r||e[3]!==o?(c={editor:t,queryKey:o,queryFn:r,onSelect:s},e[0]=t,e[1]=s,e[2]=r,e[3]=o,e[4]=c):c=e[4];const{items:d,selectedIndex:u,onSelect:g,selectedItem:h}=qn(c);if(!d.length){let x;e[5]!==a||e[6]!==l?(x=a??l("chat.mention.noItemsFound"),e[5]=a,e[6]=l,e[7]=x):x=e[7];let b;return e[8]!==x?(b=I.jsx("div",{className:"min-w-[360px] max-w-[520px] bg-popover text-popover-foreground rounded-md border shadow-md p-3 text-sm",children:x}),e[8]=x,e[9]=b):b=e[9],b}let y;e[10]===Symbol.for("react.memo_cache_sentinel")?(y={maxHeight:"min(320px, var(--radix-popover-content-available-height, 320px))"},e[10]=y):y=e[10];let m;if(e[11]!==g||e[12]!==d||e[13]!==i||e[14]!==u||e[15]!==h?.name){let x;e[17]!==g||e[18]!==i||e[19]!==u||e[20]!==h?.name?(x=(b,E)=>I.jsx(kn,{item:b,isSelected:E===u,ref:E===u?Kn:void 0,onSelect:()=>g(b,E),isLoading:h?.name===b.name,renderItem:i},`${b.kind??"item"}:${b.name}`),e[17]=g,e[18]=i,e[19]=u,e[20]=h?.name,e[21]=x):x=e[21],m=d.map(x),e[11]=g,e[12]=d,e[13]=i,e[14]=u,e[15]=h?.name,e[16]=m}else m=e[16];let f;return e[22]!==m?(f=I.jsx("div",{className:"min-w-[360px] max-w-[520px] bg-popover text-popover-foreground rounded-md overflow-y-auto",style:y,children:I.jsx("div",{className:"p-1",children:m})}),e[22]=m,e[23]=f):f=e[23],f};function Ln(){const n=H.c(1);let e;return n[0]===Symbol.for("react.memo_cache_sentinel")?(e=I.jsx("div",{className:"p-1",children:[...Array(3)].map(jn)}),n[0]=e):e=n[0],e}function jn(n,e){return I.jsxs("div",{className:"flex items-center gap-1.5 px-2 py-1.5 animate-pulse",children:[I.jsx("div",{className:"h-4 w-24 bg-muted rounded"}),I.jsx("div",{className:"h-3 w-32 bg-muted rounded"})]},e)}function Gn(n){const e=H.c(20),{editor:t,char:o,pluginKey:r,queryKey:s,queryFn:i,onSelect:a,allow:l,onOpenChange:c,renderItem:d,emptyLabel:u}=n;let g;e[0]!==l||e[1]!==o||e[2]!==t||e[3]!==c||e[4]!==r?(g={editor:t,char:o,pluginKey:r,allow:l,onOpenChange:c},e[0]=l,e[1]=o,e[2]=t,e[3]=c,e[4]=r,e[5]=g):g=e[5];const{state:h,dispatch:y}=On(g);let m;e[6]!==y||e[7]!==h?(m={state:h,dispatch:y},e[6]=y,e[7]=h,e[8]=m):m=e[8];let f;e[9]===Symbol.for("react.memo_cache_sentinel")?(f=I.jsx(Ln,{}),e[9]=f):f=e[9];let x;e[10]!==t||e[11]!==u||e[12]!==a||e[13]!==i||e[14]!==s||e[15]!==d?(x=I.jsx($n,{children:I.jsx(p.Suspense,{fallback:f,children:I.jsx(_n,{editor:t,queryKey:s,queryFn:i,onSelect:a,renderItem:d,emptyLabel:u})})}),e[10]=t,e[11]=u,e[12]=a,e[13]=i,e[14]=s,e[15]=d,e[16]=x):x=e[16];let b;return e[17]!==m||e[18]!==x?(b=I.jsx(Le.Provider,{value:m,children:x}),e[17]=m,e[18]=x,e[19]=b):b=e[19],b}function Kn(n){n&&n.scrollIntoView({block:"center",behavior:"smooth"})}export{Gn as S,Yn as a,Xn as e,Hn as s};
@@ -1 +1 @@
1
- import{r as c,j as i,bo as C,bm as y,br as T,bp as I,by as M,bJ as H,bF as z,c as A,l as g}from"./index-BJCqpqJd.js";var m="Switch",[U]=z(m),[q,F]=U(m),E=c.forwardRef((a,e)=>{const{__scopeSwitch:t,name:r,checked:s,defaultChecked:n,required:o,disabled:d,value:u="on",onCheckedChange:k,form:l,...w}=a,[p,h]=c.useState(null),v=y(e,b=>h(b)),x=c.useRef(!1),S=p?l||!!p.closest("form"):!0,[f,N]=T({prop:s,defaultProp:n??!1,onChange:k,caller:m});return i.jsxs(q,{scope:t,checked:f,disabled:d,children:[i.jsx(C.button,{type:"button",role:"switch","aria-checked":f,"aria-required":o,"data-state":j(f),"data-disabled":d?"":void 0,disabled:d,value:u,...w,ref:v,onClick:I(a.onClick,b=>{N(B=>!B),S&&(x.current=b.isPropagationStopped(),x.current||b.stopPropagation())})}),S&&i.jsx(_,{control:p,bubbles:!x.current,name:r,value:u,checked:f,required:o,disabled:d,form:l,style:{transform:"translateX(-100%)"}})]})});E.displayName=m;var P="SwitchThumb",R=c.forwardRef((a,e)=>{const{__scopeSwitch:t,...r}=a,s=F(P,t);return i.jsx(C.span,{"data-state":j(s.checked),"data-disabled":s.disabled?"":void 0,...r,ref:e})});R.displayName=P;var L="SwitchBubbleInput",_=c.forwardRef(({__scopeSwitch:a,control:e,checked:t,bubbles:r=!0,...s},n)=>{const o=c.useRef(null),d=y(o,n),u=M(t),k=H(e);return c.useEffect(()=>{const l=o.current;if(!l)return;const w=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(w,"checked").set;if(u!==t&&h){const v=new Event("click",{bubbles:r});h.call(l,t),l.dispatchEvent(v)}},[u,t,r]),i.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:t,...s,tabIndex:-1,ref:d,style:{...s.style,...k,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});_.displayName=L;function j(a){return a?"checked":"unchecked"}var O=E,$=R;function J(a){const e=A.c(9);let t,r;e[0]!==a?({className:t,...r}=a,e[0]=a,e[1]=t,e[2]=r):(t=e[1],r=e[2]);let s;e[3]!==t?(s=g("peer data-[state=checked]:bg-primary data-[state=unchecked]:bg-input focus-visible:border-ring focus-visible:ring-ring/20 dark:data-[state=unchecked]:bg-input/80 inline-flex h-[1.15rem] w-8 shrink-0 items-center rounded-full border border-transparent shadow-xs transition-all outline-none focus-visible:ring-[2px] disabled:opacity-50",t),e[3]=t,e[4]=s):s=e[4];let n;e[5]===Symbol.for("react.memo_cache_sentinel")?(n=i.jsx($,{"data-slot":"switch-thumb",className:g("bg-background dark:data-[state=unchecked]:bg-foreground dark:data-[state=checked]:bg-primary-foreground pointer-events-none block size-4 rounded-full ring-0 transition-transform data-[state=checked]:translate-x-[calc(100%-2px)] data-[state=unchecked]:translate-x-0")}),e[5]=n):n=e[5];let o;return e[6]!==r||e[7]!==s?(o=i.jsx(O,{"data-slot":"switch",className:s,...r,children:n}),e[6]=r,e[7]=s,e[8]=o):o=e[8],o}export{J as S};
1
+ import{r as c,j as i,bo as C,bm as y,br as T,bp as I,by as M,bJ as H,bF as z,c as A,l as g}from"./index-Bo0F7TR2.js";var m="Switch",[U]=z(m),[q,F]=U(m),E=c.forwardRef((a,e)=>{const{__scopeSwitch:t,name:r,checked:s,defaultChecked:n,required:o,disabled:d,value:u="on",onCheckedChange:k,form:l,...w}=a,[p,h]=c.useState(null),v=y(e,b=>h(b)),x=c.useRef(!1),S=p?l||!!p.closest("form"):!0,[f,N]=T({prop:s,defaultProp:n??!1,onChange:k,caller:m});return i.jsxs(q,{scope:t,checked:f,disabled:d,children:[i.jsx(C.button,{type:"button",role:"switch","aria-checked":f,"aria-required":o,"data-state":j(f),"data-disabled":d?"":void 0,disabled:d,value:u,...w,ref:v,onClick:I(a.onClick,b=>{N(B=>!B),S&&(x.current=b.isPropagationStopped(),x.current||b.stopPropagation())})}),S&&i.jsx(_,{control:p,bubbles:!x.current,name:r,value:u,checked:f,required:o,disabled:d,form:l,style:{transform:"translateX(-100%)"}})]})});E.displayName=m;var P="SwitchThumb",R=c.forwardRef((a,e)=>{const{__scopeSwitch:t,...r}=a,s=F(P,t);return i.jsx(C.span,{"data-state":j(s.checked),"data-disabled":s.disabled?"":void 0,...r,ref:e})});R.displayName=P;var L="SwitchBubbleInput",_=c.forwardRef(({__scopeSwitch:a,control:e,checked:t,bubbles:r=!0,...s},n)=>{const o=c.useRef(null),d=y(o,n),u=M(t),k=H(e);return c.useEffect(()=>{const l=o.current;if(!l)return;const w=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(w,"checked").set;if(u!==t&&h){const v=new Event("click",{bubbles:r});h.call(l,t),l.dispatchEvent(v)}},[u,t,r]),i.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:t,...s,tabIndex:-1,ref:d,style:{...s.style,...k,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});_.displayName=L;function j(a){return a?"checked":"unchecked"}var O=E,$=R;function J(a){const e=A.c(9);let t,r;e[0]!==a?({className:t,...r}=a,e[0]=a,e[1]=t,e[2]=r):(t=e[1],r=e[2]);let s;e[3]!==t?(s=g("peer data-[state=checked]:bg-primary data-[state=unchecked]:bg-input focus-visible:border-ring focus-visible:ring-ring/20 dark:data-[state=unchecked]:bg-input/80 inline-flex h-[1.15rem] w-8 shrink-0 items-center rounded-full border border-transparent shadow-xs transition-all outline-none focus-visible:ring-[2px] disabled:opacity-50",t),e[3]=t,e[4]=s):s=e[4];let n;e[5]===Symbol.for("react.memo_cache_sentinel")?(n=i.jsx($,{"data-slot":"switch-thumb",className:g("bg-background dark:data-[state=unchecked]:bg-foreground dark:data-[state=checked]:bg-primary-foreground pointer-events-none block size-4 rounded-full ring-0 transition-transform data-[state=checked]:translate-x-[calc(100%-2px)] data-[state=unchecked]:translate-x-0")}),e[5]=n):n=e[5];let o;return e[6]!==r||e[7]!==s?(o=i.jsx(O,{"data-slot":"switch",className:s,...r,children:n}),e[6]=r,e[7]=s,e[8]=o):o=e[8],o}export{J as S};
@@ -1 +1 @@
1
- import{c as se,j as s,fq as he,b as ue,r as ae,B as te,ai as ge,l as je,t as ce,aP as be}from"./index-BJCqpqJd.js";import{s as xe}from"./Plus-0VzOcDpy.js";import{A as Re,a as ve,b as Se,c as De,g as Ne,d as Pe,e as _e,f as Ce}from"./alert-dialog-DJp_Ityl.js";import{d as Ae,h as ke,c as we,e as ze,b as Ee,D as Oe}from"./dialog-CYKucQEn.js";import{I as Ie}from"./input-CE59clBd.js";import{u as $e,a as Fe,R as Te}from"./repository-picker-Ch8MjhWT.js";import{u as qe,b as Be,c as Ge}from"./use-org-repo-syncs-DASdWM3g.js";import{t as He}from"./format-time-CjIPQhCN.js";import{R as Le}from"./require-capability-z1ZYrtyD.js";import"./X-B2uln9s5.js";import"./ArrowLeft-Cs3E2BgS.js";import"./LinkExternal01-Cn0PsKoO.js";import"./tooltip-DymYYuRo.js";import"./index-Cv3qPBot.js";import"./label-6ZrdaA5F.js";import"./useInfiniteQuery-CrHqvHwZ.js";import"./infiniteQueryObserver-DWdmBz6y.js";import"./collection-search-BRvScCfK.js";import"./SearchMd-DvVcOTQO.js";import"./ShoppingBag01-DkKlB-7l.js";import"./avatar-DSv7rQey.js";import"./User01-CkC9PpwU.js";import"./use-debounced-value-BAjT0z0V.js";import"./use-organization-settings-B7IVGPSk.js";import"./schema-BPGmAw0J.js";import"./task-board-CJjc4xI-.js";import"./differenceInSeconds-C3x8sHUj.js";import"./access-gate-CA8I0iHR.js";import"./capability-load-error-BE5lkHsD.js";function Ve(e){return e.toLowerCase().replace(/[^a-z0-9_.-]+/g,"-").replace(/^[.-]+|[.-]+$/g,"").slice(0,128)}function Je(e,t){return e.lastSyncError?{label:e.lastSyncError,error:!0}:e.lastSyncedAt?{label:t("library.syncedRepos.syncedAgo",{ago:He(e.lastSyncedAt)}),error:!1}:{label:t("library.syncedRepos.waitingFirstSync"),error:!1}}function Ke(e){const t=se.c(38),{config:i,onRemove:l}=e,o=ue();let u;t[0]!==i||t[1]!==o?(u=Je(i,o),t[0]=i,t[1]=o,t[2]=u):u=t[2];const m=u,r=$e();let f;t[3]!==i.repositoryId||t[4]!==r.data?(f=r.data?.find(_=>_.id===i.repositoryId),t[3]=i.repositoryId,t[4]=r.data,t[5]=f):f=t[5];const n=f;let g;t[6]!==n?(g=s.jsx("div",{className:"size-9 rounded-md bg-muted flex items-center justify-center shrink-0",children:n?s.jsx(Fe,{provider:n.provider,size:16,className:"text-muted-foreground"}):s.jsx(ge,{size:16,className:"text-muted-foreground"})}),t[6]=n,t[7]=g):g=t[7];const c=n?.path??`${i.repoOwner}/${i.repoName}`;let d;t[8]!==c?(d=s.jsx("span",{className:"font-medium text-sm truncate",children:c}),t[8]=c,t[9]=d):d=t[9];let p;t[10]!==i.ref?(p=s.jsxs("span",{className:"text-xs text-muted-foreground shrink-0",children:["@",i.ref]}),t[10]=i.ref,t[11]=p):p=t[11];let S;t[12]!==d||t[13]!==p?(S=s.jsxs("div",{className:"flex items-center gap-2",children:[d,p]}),t[12]=d,t[13]=p,t[14]=S):S=t[14];const P=m.error?"text-destructive":"text-muted-foreground";let D;t[15]!==P?(D=je("text-xs mt-0.5 truncate",P),t[15]=P,t[16]=D):D=t[16];let b;t[17]!==i.volume||t[18]!==o?(b=o("settings.syncedRepos.rowSubtitle",{volume:i.volume}),t[17]=i.volume,t[18]=o,t[19]=b):b=t[19];let R;t[20]!==m.label||t[21]!==b||t[22]!==D?(R=s.jsxs("p",{className:D,children:[b," ·"," ",m.label]}),t[20]=m.label,t[21]=b,t[22]=D,t[23]=R):R=t[23];let x;t[24]!==R||t[25]!==S?(x=s.jsxs("div",{className:"min-w-0",children:[S,R]}),t[24]=R,t[25]=S,t[26]=x):x=t[26];let y;t[27]!==x||t[28]!==g?(y=s.jsxs("div",{className:"flex items-start gap-3 min-w-0",children:[g,x]}),t[27]=x,t[28]=g,t[29]=y):y=t[29];let h;t[30]!==o?(h=o("settings.syncedRepos.remove"),t[30]=o,t[31]=h):h=t[31];let j;t[32]!==l||t[33]!==h?(j=s.jsx(te,{variant:"outline",size:"sm",onClick:l,children:h}),t[32]=l,t[33]=h,t[34]=j):j=t[34];let N;return t[35]!==y||t[36]!==j?(N=s.jsxs("div",{className:"flex items-center justify-between gap-4 py-3 border-b border-border/60 last:border-b-0",children:[y,j]}),t[35]=y,t[36]=j,t[37]=N):N=t[37],N}function Me(e){const t=se.c(21),{onAdd:i}=e,l=ue();let o;t[0]===Symbol.for("react.memo_cache_sentinel")?(o=s.jsx("div",{className:"size-12 rounded-full bg-muted flex items-center justify-center",children:s.jsx(ge,{size:20,className:"text-muted-foreground"})}),t[0]=o):o=t[0];let u;t[1]!==l?(u=l("settings.syncedRepos.emptyTitle"),t[1]=l,t[2]=u):u=t[2];let m;t[3]!==u?(m=s.jsx("p",{className:"font-medium text-sm",children:u}),t[3]=u,t[4]=m):m=t[4];let r;t[5]!==l?(r=l("settings.syncedRepos.emptyDescription"),t[5]=l,t[6]=r):r=t[6];let f;t[7]!==r?(f=s.jsx("p",{className:"text-xs text-muted-foreground mt-1 max-w-sm",children:r}),t[7]=r,t[8]=f):f=t[8];let n;t[9]!==m||t[10]!==f?(n=s.jsxs("div",{children:[m,f]}),t[9]=m,t[10]=f,t[11]=n):n=t[11];let g;t[12]===Symbol.for("react.memo_cache_sentinel")?(g=s.jsx(xe,{size:14}),t[12]=g):g=t[12];let c;t[13]!==l?(c=l("settings.syncedRepos.addRepo"),t[13]=l,t[14]=c):c=t[14];let d;t[15]!==i||t[16]!==c?(d=s.jsxs(te,{onClick:i,size:"sm",className:"mt-2",children:[g,c]}),t[15]=i,t[16]=c,t[17]=d):d=t[17];let p;return t[18]!==n||t[19]!==d?(p=s.jsxs("div",{className:"rounded-2xl border border-dashed border-border/60 p-10 flex flex-col items-center justify-center text-center gap-3",children:[o,n,d]}),t[18]=n,t[19]=d,t[20]=p):p=t[20],p}function Qe(){const e=se.c(107),t=ue(),i=qe(),l=Be(),o=Ge(),[u,m]=ae.useState(!1),[r,f]=ae.useState(null),[n,g]=ae.useState(""),[c,d]=ae.useState(null);let p;e[0]!==l||e[1]!==r||e[2]!==t||e[3]!==n?(p=function(){!r||!n.trim()||l.mutate({repositoryId:r.id,volume:n.trim()},{onSuccess:v=>{f(null),ce.success(t("settings.syncedRepos.created",{volume:v.volume}))},onError:v=>{ce.error(v instanceof Error?v.message:t("settings.syncedRepos.failed"))}})},e[0]=l,e[1]=r,e[2]=t,e[3]=n,e[4]=p):p=e[4];const S=p;let P;e[5]!==c||e[6]!==o||e[7]!==t?(P=function(){c&&o.mutate(c.id,{onSuccess:()=>ce.success(t("settings.syncedRepos.removed")),onError:v=>ce.error(v instanceof Error?v.message:t("settings.syncedRepos.failed")),onSettled:()=>d(null)})},e[5]=c,e[6]=o,e[7]=t,e[8]=P):P=e[8];const D=P;if(i.isPending){let a;return e[9]===Symbol.for("react.memo_cache_sentinel")?(a=s.jsx(be,{className:"h-32 w-full"}),e[9]=a):a=e[9],a}let b;e[10]!==i.data?(b=i.data??[],e[10]=i.data,e[11]=b):b=e[11];const R=b;let x;e[12]!==t?(x=t("settings.syncedRepos.pageDescription"),e[12]=t,e[13]=x):x=e[13];let y;e[14]!==x?(y=s.jsx("p",{className:"text-sm text-muted-foreground",children:x}),e[14]=x,e[15]=y):y=e[15];let h;e[16]!==R||e[17]!==t?(h=R.length===0?s.jsx(Me,{onAdd:()=>m(!0)}):s.jsxs(s.Fragment,{children:[s.jsx("div",{className:"flex items-center justify-end",children:s.jsxs(te,{onClick:()=>m(!0),size:"sm",children:[s.jsx(xe,{size:14}),t("settings.syncedRepos.addRepo")]})}),s.jsx("section",{className:"rounded-2xl border border-border/60 bg-background px-5 py-2",children:R.map(a=>s.jsx(Ke,{config:a,onRemove:()=>d(a)},a.id))})]}),e[16]=R,e[17]=t,e[18]=h):h=e[18];let j;e[19]!==t?(j=t("settings.syncedRepos.pickerTitle"),e[19]=t,e[20]=j):j=e[20];let N;e[21]===Symbol.for("react.memo_cache_sentinel")?(N=a=>{const{repository:v}=a;m(!1),f(v),g(Ve(v.path.split("/").at(-1)??v.path))},e[21]=N):N=e[21];let _;e[22]!==u||e[23]!==j?(_=s.jsx(Te,{open:u,onOpenChange:m,title:j,onPicked:N}),e[22]=u,e[23]=j,e[24]=_):_=e[24];const de=r!==null;let le;e[25]===Symbol.for("react.memo_cache_sentinel")?(le=a=>{a||f(null)},e[25]=le):le=e[25];let C;e[26]!==t?(C=t("settings.syncedRepos.nameDialogTitle"),e[26]=t,e[27]=C):C=e[27];let A;e[28]!==C?(A=s.jsx(Ae,{children:C}),e[28]=C,e[29]=A):A=e[29];const me=r?r.path:"";let k;e[30]!==t||e[31]!==me?(k=t("settings.syncedRepos.nameDialogDescription",{repo:me}),e[30]=t,e[31]=me,e[32]=k):k=e[32];let w;e[33]!==k?(w=s.jsx(ke,{children:k}),e[33]=k,e[34]=w):w=e[34];let z;e[35]!==A||e[36]!==w?(z=s.jsxs(we,{children:[A,w]}),e[35]=A,e[36]=w,e[37]=z):z=e[37];let ie;e[38]===Symbol.for("react.memo_cache_sentinel")?(ie=a=>g(a.target.value),e[38]=ie):ie=e[38];let E;e[39]!==t?(E=t("settings.syncedRepos.namePlaceholder"),e[39]=t,e[40]=E):E=e[40];let O;e[41]!==E||e[42]!==n?(O=s.jsx(Ie,{value:n,onChange:ie,placeholder:E,autoFocus:!0}),e[41]=E,e[42]=n,e[43]=O):O=e[43];let ne;e[44]===Symbol.for("react.memo_cache_sentinel")?(ne=()=>f(null),e[44]=ne):ne=e[44];const ye=l.isPending;let I;e[45]!==t?(I=t("settings.syncedRepos.cancel"),e[45]=t,e[46]=I):I=e[46];let $;e[47]!==l.isPending||e[48]!==I?($=s.jsx(te,{variant:"outline",onClick:ne,disabled:ye,children:I}),e[47]=l.isPending,e[48]=I,e[49]=$):$=e[49];let F;e[50]!==l.isPending||e[51]!==n?(F=!n.trim()||l.isPending,e[50]=l.isPending,e[51]=n,e[52]=F):F=e[52];let T;e[53]!==l.isPending||e[54]!==t?(T=l.isPending?t("settings.syncedRepos.creating"):t("settings.syncedRepos.create"),e[53]=l.isPending,e[54]=t,e[55]=T):T=e[55];let q;e[56]!==S||e[57]!==F||e[58]!==T?(q=s.jsx(te,{disabled:F,onClick:S,children:T}),e[56]=S,e[57]=F,e[58]=T,e[59]=q):q=e[59];let B;e[60]!==$||e[61]!==q?(B=s.jsxs(ze,{children:[$,q]}),e[60]=$,e[61]=q,e[62]=B):B=e[62];let G;e[63]!==z||e[64]!==O||e[65]!==B?(G=s.jsxs(Ee,{className:"sm:max-w-sm",children:[z,O,B]}),e[63]=z,e[64]=O,e[65]=B,e[66]=G):G=e[66];let H;e[67]!==G||e[68]!==de?(H=s.jsx(Oe,{open:de,onOpenChange:le,children:G}),e[67]=G,e[68]=de,e[69]=H):H=e[69];const fe=c!==null;let oe;e[70]===Symbol.for("react.memo_cache_sentinel")?(oe=a=>{a||d(null)},e[70]=oe):oe=e[70];const pe=c?.volume??"";let L;e[71]!==t||e[72]!==pe?(L=t("settings.syncedRepos.removeTitle",{volume:pe}),e[71]=t,e[72]=pe,e[73]=L):L=e[73];let V;e[74]!==L?(V=s.jsx(Re,{children:L}),e[74]=L,e[75]=V):V=e[75];let J;e[76]!==t?(J=t("settings.syncedRepos.removeDescription"),e[76]=t,e[77]=J):J=e[77];let K;e[78]!==J?(K=s.jsx(ve,{children:J}),e[78]=J,e[79]=K):K=e[79];let M;e[80]!==V||e[81]!==K?(M=s.jsxs(Se,{children:[V,K]}),e[80]=V,e[81]=K,e[82]=M):M=e[82];let Q;e[83]!==t?(Q=t("settings.syncedRepos.cancel"),e[83]=t,e[84]=Q):Q=e[84];let U;e[85]!==Q?(U=s.jsx(De,{children:Q}),e[85]=Q,e[86]=U):U=e[86];let W;e[87]!==t?(W=t("settings.syncedRepos.remove"),e[87]=t,e[88]=W):W=e[88];let X;e[89]!==D||e[90]!==W?(X=s.jsx(Ne,{onClick:D,children:W}),e[89]=D,e[90]=W,e[91]=X):X=e[91];let Y;e[92]!==U||e[93]!==X?(Y=s.jsxs(Pe,{children:[U,X]}),e[92]=U,e[93]=X,e[94]=Y):Y=e[94];let Z;e[95]!==M||e[96]!==Y?(Z=s.jsxs(_e,{children:[M,Y]}),e[95]=M,e[96]=Y,e[97]=Z):Z=e[97];let ee;e[98]!==fe||e[99]!==Z?(ee=s.jsx(Ce,{open:fe,onOpenChange:oe,children:Z}),e[98]=fe,e[99]=Z,e[100]=ee):ee=e[100];let re;return e[101]!==H||e[102]!==y||e[103]!==ee||e[104]!==h||e[105]!==_?(re=s.jsxs(s.Fragment,{children:[y,h,_,H,ee]}),e[101]=H,e[102]=y,e[103]=ee,e[104]=h,e[105]=_,e[106]=re):re=e[106],re}function Ue(){const e=se.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx(he,{group:"storage",children:s.jsx(Qe,{})}),e[0]=t):t=e[0],t}function Nt(){const e=se.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx(Le,{capability:"file-configs:manage",area:"files",children:s.jsx(Ue,{})}),e[0]=t):t=e[0],t}export{Nt as default};
1
+ import{c as se,j as s,fq as he,b as ue,r as ae,B as te,ai as ge,l as je,t as ce,aP as be}from"./index-Bo0F7TR2.js";import{s as xe}from"./Plus-g-qUeP-5.js";import{A as Re,a as ve,b as Se,c as De,g as Ne,d as Pe,e as _e,f as Ce}from"./alert-dialog-UJiEdIyw.js";import{d as Ae,h as ke,c as we,e as ze,b as Ee,D as Oe}from"./dialog-5o2urGn5.js";import{I as Ie}from"./input-Bg2anvwf.js";import{u as $e,a as Fe,R as Te}from"./repository-picker-B8Yoh_bh.js";import{u as qe,b as Be,c as Ge}from"./use-org-repo-syncs-CeS8Ysed.js";import{t as He}from"./format-time-CjIPQhCN.js";import{R as Le}from"./require-capability-1wZrr2Ds.js";import"./X-DmQciAIn.js";import"./ArrowLeft-B0Qy6MPA.js";import"./LinkExternal01-Hrpy2rKU.js";import"./tooltip-CbYF5mhk.js";import"./index-NYSezzil.js";import"./label-CuQBcvRg.js";import"./useInfiniteQuery-BUmcOy3_.js";import"./infiniteQueryObserver-CJ3Kym5O.js";import"./collection-search-Ch2FLY2_.js";import"./SearchMd-Bu5ZPloJ.js";import"./ShoppingBag01-eap5At3d.js";import"./avatar-DnHqCpqr.js";import"./User01-gfze9rr9.js";import"./use-debounced-value-ClYZnycZ.js";import"./use-organization-settings-C-0W-ky3.js";import"./schema-CJ-VqkAD.js";import"./task-board-C6pPuzYa.js";import"./differenceInSeconds-C3x8sHUj.js";import"./access-gate-Dfd2-cvG.js";import"./capability-load-error-AKSk2IJm.js";function Ve(e){return e.toLowerCase().replace(/[^a-z0-9_.-]+/g,"-").replace(/^[.-]+|[.-]+$/g,"").slice(0,128)}function Je(e,t){return e.lastSyncError?{label:e.lastSyncError,error:!0}:e.lastSyncedAt?{label:t("library.syncedRepos.syncedAgo",{ago:He(e.lastSyncedAt)}),error:!1}:{label:t("library.syncedRepos.waitingFirstSync"),error:!1}}function Ke(e){const t=se.c(38),{config:i,onRemove:l}=e,o=ue();let u;t[0]!==i||t[1]!==o?(u=Je(i,o),t[0]=i,t[1]=o,t[2]=u):u=t[2];const m=u,r=$e();let f;t[3]!==i.repositoryId||t[4]!==r.data?(f=r.data?.find(_=>_.id===i.repositoryId),t[3]=i.repositoryId,t[4]=r.data,t[5]=f):f=t[5];const n=f;let g;t[6]!==n?(g=s.jsx("div",{className:"size-9 rounded-md bg-muted flex items-center justify-center shrink-0",children:n?s.jsx(Fe,{provider:n.provider,size:16,className:"text-muted-foreground"}):s.jsx(ge,{size:16,className:"text-muted-foreground"})}),t[6]=n,t[7]=g):g=t[7];const c=n?.path??`${i.repoOwner}/${i.repoName}`;let d;t[8]!==c?(d=s.jsx("span",{className:"font-medium text-sm truncate",children:c}),t[8]=c,t[9]=d):d=t[9];let p;t[10]!==i.ref?(p=s.jsxs("span",{className:"text-xs text-muted-foreground shrink-0",children:["@",i.ref]}),t[10]=i.ref,t[11]=p):p=t[11];let S;t[12]!==d||t[13]!==p?(S=s.jsxs("div",{className:"flex items-center gap-2",children:[d,p]}),t[12]=d,t[13]=p,t[14]=S):S=t[14];const P=m.error?"text-destructive":"text-muted-foreground";let D;t[15]!==P?(D=je("text-xs mt-0.5 truncate",P),t[15]=P,t[16]=D):D=t[16];let b;t[17]!==i.volume||t[18]!==o?(b=o("settings.syncedRepos.rowSubtitle",{volume:i.volume}),t[17]=i.volume,t[18]=o,t[19]=b):b=t[19];let R;t[20]!==m.label||t[21]!==b||t[22]!==D?(R=s.jsxs("p",{className:D,children:[b," ·"," ",m.label]}),t[20]=m.label,t[21]=b,t[22]=D,t[23]=R):R=t[23];let x;t[24]!==R||t[25]!==S?(x=s.jsxs("div",{className:"min-w-0",children:[S,R]}),t[24]=R,t[25]=S,t[26]=x):x=t[26];let y;t[27]!==x||t[28]!==g?(y=s.jsxs("div",{className:"flex items-start gap-3 min-w-0",children:[g,x]}),t[27]=x,t[28]=g,t[29]=y):y=t[29];let h;t[30]!==o?(h=o("settings.syncedRepos.remove"),t[30]=o,t[31]=h):h=t[31];let j;t[32]!==l||t[33]!==h?(j=s.jsx(te,{variant:"outline",size:"sm",onClick:l,children:h}),t[32]=l,t[33]=h,t[34]=j):j=t[34];let N;return t[35]!==y||t[36]!==j?(N=s.jsxs("div",{className:"flex items-center justify-between gap-4 py-3 border-b border-border/60 last:border-b-0",children:[y,j]}),t[35]=y,t[36]=j,t[37]=N):N=t[37],N}function Me(e){const t=se.c(21),{onAdd:i}=e,l=ue();let o;t[0]===Symbol.for("react.memo_cache_sentinel")?(o=s.jsx("div",{className:"size-12 rounded-full bg-muted flex items-center justify-center",children:s.jsx(ge,{size:20,className:"text-muted-foreground"})}),t[0]=o):o=t[0];let u;t[1]!==l?(u=l("settings.syncedRepos.emptyTitle"),t[1]=l,t[2]=u):u=t[2];let m;t[3]!==u?(m=s.jsx("p",{className:"font-medium text-sm",children:u}),t[3]=u,t[4]=m):m=t[4];let r;t[5]!==l?(r=l("settings.syncedRepos.emptyDescription"),t[5]=l,t[6]=r):r=t[6];let f;t[7]!==r?(f=s.jsx("p",{className:"text-xs text-muted-foreground mt-1 max-w-sm",children:r}),t[7]=r,t[8]=f):f=t[8];let n;t[9]!==m||t[10]!==f?(n=s.jsxs("div",{children:[m,f]}),t[9]=m,t[10]=f,t[11]=n):n=t[11];let g;t[12]===Symbol.for("react.memo_cache_sentinel")?(g=s.jsx(xe,{size:14}),t[12]=g):g=t[12];let c;t[13]!==l?(c=l("settings.syncedRepos.addRepo"),t[13]=l,t[14]=c):c=t[14];let d;t[15]!==i||t[16]!==c?(d=s.jsxs(te,{onClick:i,size:"sm",className:"mt-2",children:[g,c]}),t[15]=i,t[16]=c,t[17]=d):d=t[17];let p;return t[18]!==n||t[19]!==d?(p=s.jsxs("div",{className:"rounded-2xl border border-dashed border-border/60 p-10 flex flex-col items-center justify-center text-center gap-3",children:[o,n,d]}),t[18]=n,t[19]=d,t[20]=p):p=t[20],p}function Qe(){const e=se.c(107),t=ue(),i=qe(),l=Be(),o=Ge(),[u,m]=ae.useState(!1),[r,f]=ae.useState(null),[n,g]=ae.useState(""),[c,d]=ae.useState(null);let p;e[0]!==l||e[1]!==r||e[2]!==t||e[3]!==n?(p=function(){!r||!n.trim()||l.mutate({repositoryId:r.id,volume:n.trim()},{onSuccess:v=>{f(null),ce.success(t("settings.syncedRepos.created",{volume:v.volume}))},onError:v=>{ce.error(v instanceof Error?v.message:t("settings.syncedRepos.failed"))}})},e[0]=l,e[1]=r,e[2]=t,e[3]=n,e[4]=p):p=e[4];const S=p;let P;e[5]!==c||e[6]!==o||e[7]!==t?(P=function(){c&&o.mutate(c.id,{onSuccess:()=>ce.success(t("settings.syncedRepos.removed")),onError:v=>ce.error(v instanceof Error?v.message:t("settings.syncedRepos.failed")),onSettled:()=>d(null)})},e[5]=c,e[6]=o,e[7]=t,e[8]=P):P=e[8];const D=P;if(i.isPending){let a;return e[9]===Symbol.for("react.memo_cache_sentinel")?(a=s.jsx(be,{className:"h-32 w-full"}),e[9]=a):a=e[9],a}let b;e[10]!==i.data?(b=i.data??[],e[10]=i.data,e[11]=b):b=e[11];const R=b;let x;e[12]!==t?(x=t("settings.syncedRepos.pageDescription"),e[12]=t,e[13]=x):x=e[13];let y;e[14]!==x?(y=s.jsx("p",{className:"text-sm text-muted-foreground",children:x}),e[14]=x,e[15]=y):y=e[15];let h;e[16]!==R||e[17]!==t?(h=R.length===0?s.jsx(Me,{onAdd:()=>m(!0)}):s.jsxs(s.Fragment,{children:[s.jsx("div",{className:"flex items-center justify-end",children:s.jsxs(te,{onClick:()=>m(!0),size:"sm",children:[s.jsx(xe,{size:14}),t("settings.syncedRepos.addRepo")]})}),s.jsx("section",{className:"rounded-2xl border border-border/60 bg-background px-5 py-2",children:R.map(a=>s.jsx(Ke,{config:a,onRemove:()=>d(a)},a.id))})]}),e[16]=R,e[17]=t,e[18]=h):h=e[18];let j;e[19]!==t?(j=t("settings.syncedRepos.pickerTitle"),e[19]=t,e[20]=j):j=e[20];let N;e[21]===Symbol.for("react.memo_cache_sentinel")?(N=a=>{const{repository:v}=a;m(!1),f(v),g(Ve(v.path.split("/").at(-1)??v.path))},e[21]=N):N=e[21];let _;e[22]!==u||e[23]!==j?(_=s.jsx(Te,{open:u,onOpenChange:m,title:j,onPicked:N}),e[22]=u,e[23]=j,e[24]=_):_=e[24];const de=r!==null;let le;e[25]===Symbol.for("react.memo_cache_sentinel")?(le=a=>{a||f(null)},e[25]=le):le=e[25];let C;e[26]!==t?(C=t("settings.syncedRepos.nameDialogTitle"),e[26]=t,e[27]=C):C=e[27];let A;e[28]!==C?(A=s.jsx(Ae,{children:C}),e[28]=C,e[29]=A):A=e[29];const me=r?r.path:"";let k;e[30]!==t||e[31]!==me?(k=t("settings.syncedRepos.nameDialogDescription",{repo:me}),e[30]=t,e[31]=me,e[32]=k):k=e[32];let w;e[33]!==k?(w=s.jsx(ke,{children:k}),e[33]=k,e[34]=w):w=e[34];let z;e[35]!==A||e[36]!==w?(z=s.jsxs(we,{children:[A,w]}),e[35]=A,e[36]=w,e[37]=z):z=e[37];let ie;e[38]===Symbol.for("react.memo_cache_sentinel")?(ie=a=>g(a.target.value),e[38]=ie):ie=e[38];let E;e[39]!==t?(E=t("settings.syncedRepos.namePlaceholder"),e[39]=t,e[40]=E):E=e[40];let O;e[41]!==E||e[42]!==n?(O=s.jsx(Ie,{value:n,onChange:ie,placeholder:E,autoFocus:!0}),e[41]=E,e[42]=n,e[43]=O):O=e[43];let ne;e[44]===Symbol.for("react.memo_cache_sentinel")?(ne=()=>f(null),e[44]=ne):ne=e[44];const ye=l.isPending;let I;e[45]!==t?(I=t("settings.syncedRepos.cancel"),e[45]=t,e[46]=I):I=e[46];let $;e[47]!==l.isPending||e[48]!==I?($=s.jsx(te,{variant:"outline",onClick:ne,disabled:ye,children:I}),e[47]=l.isPending,e[48]=I,e[49]=$):$=e[49];let F;e[50]!==l.isPending||e[51]!==n?(F=!n.trim()||l.isPending,e[50]=l.isPending,e[51]=n,e[52]=F):F=e[52];let T;e[53]!==l.isPending||e[54]!==t?(T=l.isPending?t("settings.syncedRepos.creating"):t("settings.syncedRepos.create"),e[53]=l.isPending,e[54]=t,e[55]=T):T=e[55];let q;e[56]!==S||e[57]!==F||e[58]!==T?(q=s.jsx(te,{disabled:F,onClick:S,children:T}),e[56]=S,e[57]=F,e[58]=T,e[59]=q):q=e[59];let B;e[60]!==$||e[61]!==q?(B=s.jsxs(ze,{children:[$,q]}),e[60]=$,e[61]=q,e[62]=B):B=e[62];let G;e[63]!==z||e[64]!==O||e[65]!==B?(G=s.jsxs(Ee,{className:"sm:max-w-sm",children:[z,O,B]}),e[63]=z,e[64]=O,e[65]=B,e[66]=G):G=e[66];let H;e[67]!==G||e[68]!==de?(H=s.jsx(Oe,{open:de,onOpenChange:le,children:G}),e[67]=G,e[68]=de,e[69]=H):H=e[69];const fe=c!==null;let oe;e[70]===Symbol.for("react.memo_cache_sentinel")?(oe=a=>{a||d(null)},e[70]=oe):oe=e[70];const pe=c?.volume??"";let L;e[71]!==t||e[72]!==pe?(L=t("settings.syncedRepos.removeTitle",{volume:pe}),e[71]=t,e[72]=pe,e[73]=L):L=e[73];let V;e[74]!==L?(V=s.jsx(Re,{children:L}),e[74]=L,e[75]=V):V=e[75];let J;e[76]!==t?(J=t("settings.syncedRepos.removeDescription"),e[76]=t,e[77]=J):J=e[77];let K;e[78]!==J?(K=s.jsx(ve,{children:J}),e[78]=J,e[79]=K):K=e[79];let M;e[80]!==V||e[81]!==K?(M=s.jsxs(Se,{children:[V,K]}),e[80]=V,e[81]=K,e[82]=M):M=e[82];let Q;e[83]!==t?(Q=t("settings.syncedRepos.cancel"),e[83]=t,e[84]=Q):Q=e[84];let U;e[85]!==Q?(U=s.jsx(De,{children:Q}),e[85]=Q,e[86]=U):U=e[86];let W;e[87]!==t?(W=t("settings.syncedRepos.remove"),e[87]=t,e[88]=W):W=e[88];let X;e[89]!==D||e[90]!==W?(X=s.jsx(Ne,{onClick:D,children:W}),e[89]=D,e[90]=W,e[91]=X):X=e[91];let Y;e[92]!==U||e[93]!==X?(Y=s.jsxs(Pe,{children:[U,X]}),e[92]=U,e[93]=X,e[94]=Y):Y=e[94];let Z;e[95]!==M||e[96]!==Y?(Z=s.jsxs(_e,{children:[M,Y]}),e[95]=M,e[96]=Y,e[97]=Z):Z=e[97];let ee;e[98]!==fe||e[99]!==Z?(ee=s.jsx(Ce,{open:fe,onOpenChange:oe,children:Z}),e[98]=fe,e[99]=Z,e[100]=ee):ee=e[100];let re;return e[101]!==H||e[102]!==y||e[103]!==ee||e[104]!==h||e[105]!==_?(re=s.jsxs(s.Fragment,{children:[y,h,_,H,ee]}),e[101]=H,e[102]=y,e[103]=ee,e[104]=h,e[105]=_,e[106]=re):re=e[106],re}function Ue(){const e=se.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx(he,{group:"storage",children:s.jsx(Qe,{})}),e[0]=t):t=e[0],t}function Nt(){const e=se.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx(Le,{capability:"file-configs:manage",area:"files",children:s.jsx(Ue,{})}),e[0]=t):t=e[0],t}export{Nt as default};
@@ -1 +1 @@
1
- import{c as a,l as f,j as i}from"./index-BJCqpqJd.js";import{a as p}from"./ZoomOut-T_sjF8JP.js";function j(m){const s=a.c(10),{icon:o,className:l}=m,e=l===void 0?"size-4":l;if(o.kind==="component"){const{Component:c}=o;let t;return s[0]!==c||s[1]!==e?(t=i.jsx(c,{className:e}),s[0]=c,s[1]=e,s[2]=t):t=s[2],t}if(o.kind==="url"){const c=o.src;let t;s[3]!==e?(t=f(e,"rounded-sm object-cover"),s[3]=e,s[4]=t):t=s[4];let r;return s[5]!==o.src||s[6]!==t?(r=i.jsx("img",{src:c,alt:"",className:t}),s[5]=o.src,s[6]=t,s[7]=r):r=s[7],r}let n;return s[8]!==e?(n=i.jsx(p,{className:e}),s[8]=e,s[9]=n):n=s[9],n}export{j as T};
1
+ import{c as a,l as f,j as i}from"./index-Bo0F7TR2.js";import{a as p}from"./ZoomOut-CacJRCxL.js";function j(m){const s=a.c(10),{icon:o,className:l}=m,e=l===void 0?"size-4":l;if(o.kind==="component"){const{Component:c}=o;let t;return s[0]!==c||s[1]!==e?(t=i.jsx(c,{className:e}),s[0]=c,s[1]=e,s[2]=t):t=s[2],t}if(o.kind==="url"){const c=o.src;let t;s[3]!==e?(t=f(e,"rounded-sm object-cover"),s[3]=e,s[4]=t):t=s[4];let r;return s[5]!==o.src||s[6]!==t?(r=i.jsx("img",{src:c,alt:"",className:t}),s[5]=o.src,s[6]=t,s[7]=r):r=s[7],r}let n;return s[8]!==e?(n=i.jsx(p,{className:e}),s[8]=e,s[9]=n):n=s[9],n}export{j as T};
@@ -1 +1 @@
1
- import{c,l as i,j as r}from"./index-BJCqpqJd.js";function d(o){const e=c.c(8);let t,l;e[0]!==o?({className:t,...l}=o,e[0]=o,e[1]=t,e[2]=l):(t=e[1],l=e[2]);let s;e[3]!==t?(s=i("w-full caption-bottom text-sm min-w-0",t),e[3]=t,e[4]=s):s=e[4];let a;return e[5]!==l||e[6]!==s?(a=r.jsx("div",{"data-slot":"table-container",className:"w-full min-w-0 bg-card rounded-xl card-shadow overflow-hidden",children:r.jsx("table",{"data-slot":"table",className:s,...l})}),e[5]=l,e[6]=s,e[7]=a):a=e[7],a}function f(o){const e=c.c(8);let t,l;e[0]!==o?({className:t,...l}=o,e[0]=o,e[1]=t,e[2]=l):(t=e[1],l=e[2]);let s;e[3]!==t?(s=i("[&_tr]:border-b sticky top-0 z-10 bg-card",t),e[3]=t,e[4]=s):s=e[4];let a;return e[5]!==l||e[6]!==s?(a=r.jsx("thead",{"data-slot":"table-header",className:s,...l}),e[5]=l,e[6]=s,e[7]=a):a=e[7],a}function b(o){const e=c.c(8);let t,l;e[0]!==o?({className:t,...l}=o,e[0]=o,e[1]=t,e[2]=l):(t=e[1],l=e[2]);let s;e[3]!==t?(s=i("[&_tr:last-child]:border-0",t),e[3]=t,e[4]=s):s=e[4];let a;return e[5]!==l||e[6]!==s?(a=r.jsx("tbody",{"data-slot":"table-body",className:s,...l}),e[5]=l,e[6]=s,e[7]=a):a=e[7],a}function p(o){const e=c.c(8);let t,l;e[0]!==o?({className:t,...l}=o,e[0]=o,e[1]=t,e[2]=l):(t=e[1],l=e[2]);let s;e[3]!==t?(s=i("data-[state=selected]:bg-muted border-b transition-colors",t),e[3]=t,e[4]=s):s=e[4];let a;return e[5]!==l||e[6]!==s?(a=r.jsx("tr",{"data-slot":"table-row",className:s,...l}),e[5]=l,e[6]=s,e[7]=a):a=e[7],a}function m(o){const e=c.c(8);let t,l;e[0]!==o?({className:t,...l}=o,e[0]=o,e[1]=t,e[2]=l):(t=e[1],l=e[2]);let s;e[3]!==t?(s=i("text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",t),e[3]=t,e[4]=s):s=e[4];let a;return e[5]!==l||e[6]!==s?(a=r.jsx("th",{"data-slot":"table-head",className:s,...l}),e[5]=l,e[6]=s,e[7]=a):a=e[7],a}function x(o){const e=c.c(8);let t,l;e[0]!==o?({className:t,...l}=o,e[0]=o,e[1]=t,e[2]=l):(t=e[1],l=e[2]);let s;e[3]!==t?(s=i("p-2 align-middle whitespace-nowrap text-sm [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",t),e[3]=t,e[4]=s):s=e[4];let a;return e[5]!==l||e[6]!==s?(a=r.jsx("td",{"data-slot":"table-cell",className:s,...l}),e[5]=l,e[6]=s,e[7]=a):a=e[7],a}export{m as T,f as a,p as b,x as c,b as d,d as e};
1
+ import{c,l as i,j as r}from"./index-Bo0F7TR2.js";function d(o){const e=c.c(8);let t,l;e[0]!==o?({className:t,...l}=o,e[0]=o,e[1]=t,e[2]=l):(t=e[1],l=e[2]);let s;e[3]!==t?(s=i("w-full caption-bottom text-sm min-w-0",t),e[3]=t,e[4]=s):s=e[4];let a;return e[5]!==l||e[6]!==s?(a=r.jsx("div",{"data-slot":"table-container",className:"w-full min-w-0 bg-card rounded-xl card-shadow overflow-hidden",children:r.jsx("table",{"data-slot":"table",className:s,...l})}),e[5]=l,e[6]=s,e[7]=a):a=e[7],a}function f(o){const e=c.c(8);let t,l;e[0]!==o?({className:t,...l}=o,e[0]=o,e[1]=t,e[2]=l):(t=e[1],l=e[2]);let s;e[3]!==t?(s=i("[&_tr]:border-b sticky top-0 z-10 bg-card",t),e[3]=t,e[4]=s):s=e[4];let a;return e[5]!==l||e[6]!==s?(a=r.jsx("thead",{"data-slot":"table-header",className:s,...l}),e[5]=l,e[6]=s,e[7]=a):a=e[7],a}function b(o){const e=c.c(8);let t,l;e[0]!==o?({className:t,...l}=o,e[0]=o,e[1]=t,e[2]=l):(t=e[1],l=e[2]);let s;e[3]!==t?(s=i("[&_tr:last-child]:border-0",t),e[3]=t,e[4]=s):s=e[4];let a;return e[5]!==l||e[6]!==s?(a=r.jsx("tbody",{"data-slot":"table-body",className:s,...l}),e[5]=l,e[6]=s,e[7]=a):a=e[7],a}function p(o){const e=c.c(8);let t,l;e[0]!==o?({className:t,...l}=o,e[0]=o,e[1]=t,e[2]=l):(t=e[1],l=e[2]);let s;e[3]!==t?(s=i("data-[state=selected]:bg-muted border-b transition-colors",t),e[3]=t,e[4]=s):s=e[4];let a;return e[5]!==l||e[6]!==s?(a=r.jsx("tr",{"data-slot":"table-row",className:s,...l}),e[5]=l,e[6]=s,e[7]=a):a=e[7],a}function m(o){const e=c.c(8);let t,l;e[0]!==o?({className:t,...l}=o,e[0]=o,e[1]=t,e[2]=l):(t=e[1],l=e[2]);let s;e[3]!==t?(s=i("text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",t),e[3]=t,e[4]=s):s=e[4];let a;return e[5]!==l||e[6]!==s?(a=r.jsx("th",{"data-slot":"table-head",className:s,...l}),e[5]=l,e[6]=s,e[7]=a):a=e[7],a}function x(o){const e=c.c(8);let t,l;e[0]!==o?({className:t,...l}=o,e[0]=o,e[1]=t,e[2]=l):(t=e[1],l=e[2]);let s;e[3]!==t?(s=i("p-2 align-middle whitespace-nowrap text-sm [&:has([role=checkbox])]:pr-0 [&>[role=checkbox]]:translate-y-[2px]",t),e[3]=t,e[4]=s):s=e[4];let a;return e[5]!==l||e[6]!==s?(a=r.jsx("td",{"data-slot":"table-cell",className:s,...l}),e[5]=l,e[6]=s,e[7]=a):a=e[7],a}export{m as T,f as a,p as b,x as c,b as d,d as e};
@@ -1 +1 @@
1
- import{r as v,j as d,ea as k,bo as p,bp as T,ec as F,dc as M,bq as P,br as S,bn as V,eb as y,bF as D,c as x,l as g}from"./index-BJCqpqJd.js";var m="Tabs",[G]=D(m,[y]),w=y(),[L,h]=G(m),C=v.forwardRef((n,e)=>{const{__scopeTabs:a,value:t,onValueChange:r,defaultValue:s,orientation:o="horizontal",dir:i,activationMode:l="automatic",...f}=n,u=P(i),[c,b]=S({prop:t,onChange:r,defaultProp:s??"",caller:m});return d.jsx(L,{scope:a,baseId:V(),value:c,onValueChange:b,orientation:o,dir:u,activationMode:l,children:d.jsx(p.div,{dir:u,"data-orientation":o,...f,ref:e})})});C.displayName=m;var N="TabsList",j=v.forwardRef((n,e)=>{const{__scopeTabs:a,loop:t=!0,...r}=n,s=h(N,a),o=w(a);return d.jsx(F,{asChild:!0,...o,orientation:s.orientation,dir:s.dir,loop:t,children:d.jsx(p.div,{role:"tablist","aria-orientation":s.orientation,...r,ref:e})})});j.displayName=N;var I="TabsTrigger",_=v.forwardRef((n,e)=>{const{__scopeTabs:a,value:t,disabled:r=!1,...s}=n,o=h(I,a),i=w(a),l=E(o.baseId,t),f=$(o.baseId,t),u=t===o.value;return d.jsx(k,{asChild:!0,...i,focusable:!r,active:u,children:d.jsx(p.button,{type:"button",role:"tab","aria-selected":u,"aria-controls":f,"data-state":u?"active":"inactive","data-disabled":r?"":void 0,disabled:r,id:l,...s,ref:e,onMouseDown:T(n.onMouseDown,c=>{!r&&c.button===0&&c.ctrlKey===!1?o.onValueChange(t):c.preventDefault()}),onKeyDown:T(n.onKeyDown,c=>{[" ","Enter"].includes(c.key)&&o.onValueChange(t)}),onFocus:T(n.onFocus,()=>{const c=o.activationMode!=="manual";!u&&!r&&c&&o.onValueChange(t)})})})});_.displayName=I;var R="TabsContent",A=v.forwardRef((n,e)=>{const{__scopeTabs:a,value:t,forceMount:r,children:s,...o}=n,i=h(R,a),l=E(i.baseId,t),f=$(i.baseId,t),u=t===i.value,c=v.useRef(u);return v.useEffect(()=>{const b=requestAnimationFrame(()=>c.current=!1);return()=>cancelAnimationFrame(b)},[]),d.jsx(M,{present:r||u,children:({present:b})=>d.jsx(p.div,{"data-state":u?"active":"inactive","data-orientation":i.orientation,role:"tabpanel","aria-labelledby":l,hidden:!b,id:f,tabIndex:0,...o,ref:e,style:{...n.style,animationDuration:c.current?"0s":void 0},children:b&&s})})});A.displayName=R;function E(n,e){return`${n}-trigger-${e}`}function $(n,e){return`${n}-content-${e}`}var z=C,K=j,q=_,B=A;function O(n){const e=x.c(10);let a,t,r;e[0]!==n?({className:a,variant:r,...t}=n,e[0]=n,e[1]=a,e[2]=t,e[3]=r):(a=e[1],t=e[2],r=e[3]);const s=r===void 0?"pill":r;let o;e[4]!==a?(o=g("flex flex-col gap-2",a),e[4]=a,e[5]=o):o=e[5];let i;return e[6]!==t||e[7]!==o||e[8]!==s?(i=d.jsx(z,{"data-slot":"tabs","data-variant":s,className:o,...t}),e[6]=t,e[7]=o,e[8]=s,e[9]=i):i=e[9],i}function J(n){const e=x.c(11);let a,t,r;e[0]!==n?({className:a,variant:r,...t}=n,e[0]=n,e[1]=a,e[2]=t,e[3]=r):(a=e[1],t=e[2],r=e[3]);const s=r||"pill",o=s==="underline"?"flex h-[52px] items-center border-b border-border":s==="canvas"?"flex h-10 items-center bg-background relative":"bg-muted text-muted-foreground inline-flex h-10 w-fit items-center justify-center rounded-xl p-[3px]";let i;e[4]!==a||e[5]!==o?(i=g(o,a),e[4]=a,e[5]=o,e[6]=i):i=e[6];let l;return e[7]!==s||e[8]!==t||e[9]!==i?(l=d.jsx(K,{"data-slot":"tabs-list","data-variant":s,className:i,...t}),e[7]=s,e[8]=t,e[9]=i,e[10]=l):l=e[10],l}function Q(n){const e=x.c(11);let a,t,r;e[0]!==n?({className:a,variant:r,...t}=n,e[0]=n,e[1]=a,e[2]=t,e[3]=r):(a=e[1],t=e[2],r=e[3]);const s=r||"pill",o=s==="underline"?"flex items-center h-full px-3 relative text-sm whitespace-nowrap border-b-2 mb-[-1px] transition-all text-muted-foreground border-transparent hover:text-foreground data-[state=active]:text-foreground data-[state=active]:border-primary disabled:pointer-events-none disabled:opacity-50":s==="canvas"?"flex items-center h-full px-3 gap-2.5 text-sm whitespace-nowrap transition-all border-r border-b border-border [&>*]:opacity-50 data-[state=active]:[&>*]:opacity-100 data-[state=active]:border-b-0 last:border-r-0 disabled:pointer-events-none max-w-2xs":"data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/20 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-lg border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[2px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4";let i;e[4]!==a||e[5]!==o?(i=g(o,a),e[4]=a,e[5]=o,e[6]=i):i=e[6];let l;return e[7]!==s||e[8]!==t||e[9]!==i?(l=d.jsx(q,{"data-slot":"tabs-trigger","data-variant":s,className:i,...t}),e[7]=s,e[8]=t,e[9]=i,e[10]=l):l=e[10],l}function U(n){const e=x.c(8);let a,t;e[0]!==n?({className:a,...t}=n,e[0]=n,e[1]=a,e[2]=t):(a=e[1],t=e[2]);let r;e[3]!==a?(r=g("flex-1 outline-none h-full",a),e[3]=a,e[4]=r):r=e[4];let s;return e[5]!==t||e[6]!==r?(s=d.jsx(B,{"data-slot":"tabs-content",className:r,...t}),e[5]=t,e[6]=r,e[7]=s):s=e[7],s}export{Q as T,J as a,O as b,U as c};
1
+ import{r as v,j as d,ea as k,bo as p,bp as T,ec as F,dc as M,bq as P,br as S,bn as V,eb as y,bF as D,c as x,l as g}from"./index-Bo0F7TR2.js";var m="Tabs",[G]=D(m,[y]),w=y(),[L,h]=G(m),C=v.forwardRef((n,e)=>{const{__scopeTabs:a,value:t,onValueChange:r,defaultValue:s,orientation:o="horizontal",dir:i,activationMode:l="automatic",...f}=n,u=P(i),[c,b]=S({prop:t,onChange:r,defaultProp:s??"",caller:m});return d.jsx(L,{scope:a,baseId:V(),value:c,onValueChange:b,orientation:o,dir:u,activationMode:l,children:d.jsx(p.div,{dir:u,"data-orientation":o,...f,ref:e})})});C.displayName=m;var N="TabsList",j=v.forwardRef((n,e)=>{const{__scopeTabs:a,loop:t=!0,...r}=n,s=h(N,a),o=w(a);return d.jsx(F,{asChild:!0,...o,orientation:s.orientation,dir:s.dir,loop:t,children:d.jsx(p.div,{role:"tablist","aria-orientation":s.orientation,...r,ref:e})})});j.displayName=N;var I="TabsTrigger",_=v.forwardRef((n,e)=>{const{__scopeTabs:a,value:t,disabled:r=!1,...s}=n,o=h(I,a),i=w(a),l=E(o.baseId,t),f=$(o.baseId,t),u=t===o.value;return d.jsx(k,{asChild:!0,...i,focusable:!r,active:u,children:d.jsx(p.button,{type:"button",role:"tab","aria-selected":u,"aria-controls":f,"data-state":u?"active":"inactive","data-disabled":r?"":void 0,disabled:r,id:l,...s,ref:e,onMouseDown:T(n.onMouseDown,c=>{!r&&c.button===0&&c.ctrlKey===!1?o.onValueChange(t):c.preventDefault()}),onKeyDown:T(n.onKeyDown,c=>{[" ","Enter"].includes(c.key)&&o.onValueChange(t)}),onFocus:T(n.onFocus,()=>{const c=o.activationMode!=="manual";!u&&!r&&c&&o.onValueChange(t)})})})});_.displayName=I;var R="TabsContent",A=v.forwardRef((n,e)=>{const{__scopeTabs:a,value:t,forceMount:r,children:s,...o}=n,i=h(R,a),l=E(i.baseId,t),f=$(i.baseId,t),u=t===i.value,c=v.useRef(u);return v.useEffect(()=>{const b=requestAnimationFrame(()=>c.current=!1);return()=>cancelAnimationFrame(b)},[]),d.jsx(M,{present:r||u,children:({present:b})=>d.jsx(p.div,{"data-state":u?"active":"inactive","data-orientation":i.orientation,role:"tabpanel","aria-labelledby":l,hidden:!b,id:f,tabIndex:0,...o,ref:e,style:{...n.style,animationDuration:c.current?"0s":void 0},children:b&&s})})});A.displayName=R;function E(n,e){return`${n}-trigger-${e}`}function $(n,e){return`${n}-content-${e}`}var z=C,K=j,q=_,B=A;function O(n){const e=x.c(10);let a,t,r;e[0]!==n?({className:a,variant:r,...t}=n,e[0]=n,e[1]=a,e[2]=t,e[3]=r):(a=e[1],t=e[2],r=e[3]);const s=r===void 0?"pill":r;let o;e[4]!==a?(o=g("flex flex-col gap-2",a),e[4]=a,e[5]=o):o=e[5];let i;return e[6]!==t||e[7]!==o||e[8]!==s?(i=d.jsx(z,{"data-slot":"tabs","data-variant":s,className:o,...t}),e[6]=t,e[7]=o,e[8]=s,e[9]=i):i=e[9],i}function J(n){const e=x.c(11);let a,t,r;e[0]!==n?({className:a,variant:r,...t}=n,e[0]=n,e[1]=a,e[2]=t,e[3]=r):(a=e[1],t=e[2],r=e[3]);const s=r||"pill",o=s==="underline"?"flex h-[52px] items-center border-b border-border":s==="canvas"?"flex h-10 items-center bg-background relative":"bg-muted text-muted-foreground inline-flex h-10 w-fit items-center justify-center rounded-xl p-[3px]";let i;e[4]!==a||e[5]!==o?(i=g(o,a),e[4]=a,e[5]=o,e[6]=i):i=e[6];let l;return e[7]!==s||e[8]!==t||e[9]!==i?(l=d.jsx(K,{"data-slot":"tabs-list","data-variant":s,className:i,...t}),e[7]=s,e[8]=t,e[9]=i,e[10]=l):l=e[10],l}function Q(n){const e=x.c(11);let a,t,r;e[0]!==n?({className:a,variant:r,...t}=n,e[0]=n,e[1]=a,e[2]=t,e[3]=r):(a=e[1],t=e[2],r=e[3]);const s=r||"pill",o=s==="underline"?"flex items-center h-full px-3 relative text-sm whitespace-nowrap border-b-2 mb-[-1px] transition-all text-muted-foreground border-transparent hover:text-foreground data-[state=active]:text-foreground data-[state=active]:border-primary disabled:pointer-events-none disabled:opacity-50":s==="canvas"?"flex items-center h-full px-3 gap-2.5 text-sm whitespace-nowrap transition-all border-r border-b border-border [&>*]:opacity-50 data-[state=active]:[&>*]:opacity-100 data-[state=active]:border-b-0 last:border-r-0 disabled:pointer-events-none max-w-2xs":"data-[state=active]:bg-background dark:data-[state=active]:text-foreground focus-visible:border-ring focus-visible:ring-ring/20 focus-visible:outline-ring dark:data-[state=active]:border-input dark:data-[state=active]:bg-input/30 text-foreground dark:text-muted-foreground inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center gap-1.5 rounded-lg border border-transparent px-2 py-1 text-sm font-medium whitespace-nowrap transition-[color,box-shadow] focus-visible:ring-[2px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:shadow-sm [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4";let i;e[4]!==a||e[5]!==o?(i=g(o,a),e[4]=a,e[5]=o,e[6]=i):i=e[6];let l;return e[7]!==s||e[8]!==t||e[9]!==i?(l=d.jsx(q,{"data-slot":"tabs-trigger","data-variant":s,className:i,...t}),e[7]=s,e[8]=t,e[9]=i,e[10]=l):l=e[10],l}function U(n){const e=x.c(8);let a,t;e[0]!==n?({className:a,...t}=n,e[0]=n,e[1]=a,e[2]=t):(a=e[1],t=e[2]);let r;e[3]!==a?(r=g("flex-1 outline-none h-full",a),e[3]=a,e[4]=r):r=e[4];let s;return e[5]!==t||e[6]!==r?(s=d.jsx(B,{"data-slot":"tabs-content",className:r,...t}),e[5]=t,e[6]=r,e[7]=s):s=e[7],s}export{Q as T,J as a,O as b,U as c};
@@ -1 +1 @@
1
- import{o as s}from"./schema-BPGmAw0J.js";const A="super-agent",o=["#9ca3af","#ef4444","#f97316","#f59e0b","#22c55e","#3b82f6","#a855f7","#ec4899"],c=o[0];function p(e){return o[e%o.length]??c}function w(e){return e.createdBy==="system"}const R="chore",d=["reviewer"],_={reviewer:"Reviewer"},E=["QA Agent","Code Reviewer"];function S(e){return e?.reviewer_enabled===void 0&&e?.qa_agent_enabled===!1&&e?.code_reviewer_enabled===!1?!1:s(e,"reviewer_enabled")}const u=["triage","todo","in_progress","in_review","approved","merged","post_deploy_validation","done","archived"],D={queue:"todo"};u.map((e,t)=>({key:e,title:e,position:t}));const L=["approved","merged","post_deploy_validation"];function f(e,t){return e?[_[t],...E].some(r=>e.startsWith(`${r}:`)):!1}function m(e){return e.reviewerEnabled||!e.hasPullRequest?!1:!e.threadTitles.some(t=>d.some(r=>f(t,r)))}function v(e,t){if(t)return new Date(t).getTime();let r=0;for(const n of e)n.action==="status_changed"&&n.data?.to==="in_review"&&(r=Math.max(r,new Date(n.occurredAt).getTime()));return r}function l(e,t){const r=v(e,t.cycleStartedAt),n=new Map;for(const a of e){if(a.action!=="review_approved"&&a.action!=="review_changes_requested"||new Date(a.occurredAt).getTime()<r)continue;const i=a.data??{};if(i.reviewer==="reviewer")if(a.action==="review_approved"){if(t?.verifiedOnly&&i.verified!==!0)continue;n.set("reviewer","approved")}else n.set("reviewer","changes_requested")}return n}function g(e,t,r){if(t.length===0)return!1;const n=l(e,r);return t.every(a=>n.get(a)==="approved")}const h="task-board.item.updated",b="task-board.item.deleted",N="task-board.item.prs.updated",C=4e3;export{u as C,R as D,D as L,d as R,A as S,h as T,b as a,N as b,c,L as d,g as e,f,m as g,C as h,w as i,p as n,S as r};
1
+ import{o as s}from"./schema-CJ-VqkAD.js";const A="super-agent",o=["#9ca3af","#ef4444","#f97316","#f59e0b","#22c55e","#3b82f6","#a855f7","#ec4899"],c=o[0];function p(e){return o[e%o.length]??c}function w(e){return e.createdBy==="system"}const R="chore",d=["reviewer"],_={reviewer:"Reviewer"},E=["QA Agent","Code Reviewer"];function S(e){return e?.reviewer_enabled===void 0&&e?.qa_agent_enabled===!1&&e?.code_reviewer_enabled===!1?!1:s(e,"reviewer_enabled")}const u=["triage","todo","in_progress","in_review","approved","merged","post_deploy_validation","done","archived"],D={queue:"todo"};u.map((e,t)=>({key:e,title:e,position:t}));const L=["approved","merged","post_deploy_validation"];function f(e,t){return e?[_[t],...E].some(r=>e.startsWith(`${r}:`)):!1}function m(e){return e.reviewerEnabled||!e.hasPullRequest?!1:!e.threadTitles.some(t=>d.some(r=>f(t,r)))}function v(e,t){if(t)return new Date(t).getTime();let r=0;for(const n of e)n.action==="status_changed"&&n.data?.to==="in_review"&&(r=Math.max(r,new Date(n.occurredAt).getTime()));return r}function l(e,t){const r=v(e,t.cycleStartedAt),n=new Map;for(const a of e){if(a.action!=="review_approved"&&a.action!=="review_changes_requested"||new Date(a.occurredAt).getTime()<r)continue;const i=a.data??{};if(i.reviewer==="reviewer")if(a.action==="review_approved"){if(t?.verifiedOnly&&i.verified!==!0)continue;n.set("reviewer","approved")}else n.set("reviewer","changes_requested")}return n}function g(e,t,r){if(t.length===0)return!1;const n=l(e,r);return t.every(a=>n.get(a)==="approved")}const h="task-board.item.updated",b="task-board.item.deleted",N="task-board.item.prs.updated",C=4e3;export{u as C,R as D,D as L,d as R,A as S,h as T,b as a,N as b,c,L as d,g as e,f,m as g,C as h,w as i,p as n,S as r};
@@ -1 +1 @@
1
- import{p as D,d as E}from"./repository-binding--R5a6meD.js";import{S as R}from"./task-board-CJjc4xI-.js";const S=4,b="TASK";function v(e){return e.replace(/[^a-zA-Z]/g,"").toUpperCase().slice(0,S)||b}function w(e,t){return t==null?null:`${v(e)}-${String(t).padStart(2,"0")}`}const M=/^(?:[a-z]{1,8}-)?0*(\d+)$/i;function y(e){const t=M.exec(e.trim())?.[1];return t===void 0?null:Number(t)}const j="__no_repo__";function i(e){return(e??"").trim().toLowerCase()}function P(e,t){const r=(e.created_at??"").localeCompare(t.created_at??"");return r!==0?r:e.id.localeCompare(t.id)}function C(e){return e.projects.length===1?e.projects[0]?.title??e.repo??e.id:e.repo??e.id}function G(e,t=[]){const r=new Map,n=new Map,s=[],a=o=>{const u=i(o),c=r.get(u);if(c)return c;const l={id:u,kind:"repo",repo:o.trim(),title:o.trim(),projects:[]};return r.set(u,l),l};for(const o of e){const u=D(o);if(u){const l=a(u);l.projects.push(o),n.set(o.id,l);continue}const c={id:o.id,kind:"project",repo:null,title:o.title,projects:[o]};s.push(c),n.set(o.id,c)}for(const o of t){const u=(o??"").trim();u&&!n.has(u)&&a(u)}for(const o of r.values())o.projects.sort(P),o.title=C(o);const p=[...r.values()].filter(o=>o.projects.length>0),T=[...r.values()].filter(o=>o.projects.length===0),f=(o,u)=>o.title.localeCompare(u.title),g=[...[...p,...s].sort(f),...T.sort(f)];return{entries:g,byId:new Map(g.map(o=>[o.id,o])),byRepo:r,byProject:n}}function d(e,t){for(const s of e.threads??[]){const a=s.virtualMcpId?t.byProject.get(s.virtualMcpId):void 0;if(a)return a}const r=t.byProject.get((e.repo??"").trim());if(r)return r;const n=i(e.repo);return(n?t.byRepo.get(n):void 0)??null}function m(e,t){const r=d(e,t);if(!r)return[];if(r.projects.length<=1)return r.projects;for(const s of e.threads??[]){const a=s.virtualMcpId?r.projects.find(p=>p.id===s.virtualMcpId):void 0;if(a)return[a]}const n=r.projects.find(s=>s.id===e.repo?.trim());return n?[n]:r.projects}function Y(e,t,r){return e.filter(n=>m(n,t).some(s=>s.id===r))}function z(e,t){const r=m(e,t);return r.length===1?r[0]??null:null}function h(e,t){return t.byId.get(e)??t.byRepo.get(i(e))??t.byProject.get(e)}function _(e,t,r){if(t===null)return!0;if(t===j)return d(e,r)===null;const n=h(t,r);return n?n.repo&&i(e.repo)===i(n.repo)?!0:d(e,r)===n:t.includes("/")?i(e.repo)===i(t):!0}function X(e,t){return e===null?!1:e===j?!0:!!h(e,t)||e.includes("/")}function q(e,t,r){return t===null?null:_(e,t,r)?t:null}function H(e){return e.entries.filter(t=>t.repo!==null&&(t.projects.length===0||t.projects.some(r=>E(r).status!=="detached")))}const L="__unassigned__",J={assignee:null,priority:null,due:null,tags:[],project:null,search:""},A=864e5;function I(e,t){const r=new Date(e),n=new Date(t);return r.getFullYear()===n.getFullYear()&&r.getMonth()===n.getMonth()&&r.getDate()===n.getDate()}function k(e,t){const r=e.trim();return r===""?!1:t!=null&&y(r)===t}function N(e,t){return e.assigneeId===t?!0:e.assigneeId===R&&e.assignedBy===t}function W(e,t,r){const n=t.search.trim().toLowerCase();if(n!==""&&!`${e.title} ${e.description??""}`.toLowerCase().includes(n)&&!k(n,e.keySeq))return!1;if(t.assignee!==null){if(t.assignee===L){if(e.assigneeId!==null)return!1}else if(!N(e,t.assignee))return!1}if(t.priority!==null&&e.priority!==t.priority)return!1;if(t.due!==null)if(t.due==="none"){if(e.dueDate)return!1}else{if(!e.dueDate)return!1;const s=new Date(e.dueDate).getTime(),a=Date.now();if(t.due==="overdue"&&s>=a||t.due==="today"&&!I(s,a)||t.due==="week"&&(s<a||s>a+7*A))return!1}if(t.tags.length>0){const s=e.tags.map(a=>a.id);if(!t.tags.some(a=>s.includes(a)))return!1}return!!_(e,t.project,r)}const F={overdue:"taskBoard.taskFilters.dueDateFilterOverdue",today:"taskBoard.taskFilters.dueDateFilterDueToday",week:"taskBoard.taskFilters.dueDateFilterDueThisWeek",none:"taskBoard.taskFilters.dueDateFilterNoDueDate"},Z=Object.keys(F);function Q(e){return F[e]}function $(e,t){return w(e,t.keySeq)??t.id}function V(e,t,r){const n=encodeURIComponent(e),s=encodeURIComponent($(e,t));return r?`/${n}/projects/${encodeURIComponent(r)}/tasks/${s}`:`/${n}/tasks/${s}`}function x(e,t){const r=t?.trim();if(r)return e.find(n=>k(r,n.keySeq))??e.find(n=>n.id===r)}const K=/^board_[\w-]+$/,B=64;function ee(e){const t=e.trim();return t.length>B?null:y(t)!==null||K.test(t)?t:null}export{Z as D,J as E,j as N,L as U,$ as a,G as b,z as c,Y as d,d as e,h as f,V as g,X as h,Q as i,W as j,x as k,q as l,ee as m,m as p,H as s,w as t};
1
+ import{p as D,d as E}from"./repository-binding-BGULsexx.js";import{S as R}from"./task-board-C6pPuzYa.js";const S=4,b="TASK";function v(e){return e.replace(/[^a-zA-Z]/g,"").toUpperCase().slice(0,S)||b}function w(e,t){return t==null?null:`${v(e)}-${String(t).padStart(2,"0")}`}const M=/^(?:[a-z]{1,8}-)?0*(\d+)$/i;function y(e){const t=M.exec(e.trim())?.[1];return t===void 0?null:Number(t)}const j="__no_repo__";function i(e){return(e??"").trim().toLowerCase()}function P(e,t){const r=(e.created_at??"").localeCompare(t.created_at??"");return r!==0?r:e.id.localeCompare(t.id)}function C(e){return e.projects.length===1?e.projects[0]?.title??e.repo??e.id:e.repo??e.id}function G(e,t=[]){const r=new Map,n=new Map,s=[],a=o=>{const u=i(o),c=r.get(u);if(c)return c;const l={id:u,kind:"repo",repo:o.trim(),title:o.trim(),projects:[]};return r.set(u,l),l};for(const o of e){const u=D(o);if(u){const l=a(u);l.projects.push(o),n.set(o.id,l);continue}const c={id:o.id,kind:"project",repo:null,title:o.title,projects:[o]};s.push(c),n.set(o.id,c)}for(const o of t){const u=(o??"").trim();u&&!n.has(u)&&a(u)}for(const o of r.values())o.projects.sort(P),o.title=C(o);const p=[...r.values()].filter(o=>o.projects.length>0),T=[...r.values()].filter(o=>o.projects.length===0),f=(o,u)=>o.title.localeCompare(u.title),g=[...[...p,...s].sort(f),...T.sort(f)];return{entries:g,byId:new Map(g.map(o=>[o.id,o])),byRepo:r,byProject:n}}function d(e,t){for(const s of e.threads??[]){const a=s.virtualMcpId?t.byProject.get(s.virtualMcpId):void 0;if(a)return a}const r=t.byProject.get((e.repo??"").trim());if(r)return r;const n=i(e.repo);return(n?t.byRepo.get(n):void 0)??null}function m(e,t){const r=d(e,t);if(!r)return[];if(r.projects.length<=1)return r.projects;for(const s of e.threads??[]){const a=s.virtualMcpId?r.projects.find(p=>p.id===s.virtualMcpId):void 0;if(a)return[a]}const n=r.projects.find(s=>s.id===e.repo?.trim());return n?[n]:r.projects}function Y(e,t,r){return e.filter(n=>m(n,t).some(s=>s.id===r))}function z(e,t){const r=m(e,t);return r.length===1?r[0]??null:null}function h(e,t){return t.byId.get(e)??t.byRepo.get(i(e))??t.byProject.get(e)}function _(e,t,r){if(t===null)return!0;if(t===j)return d(e,r)===null;const n=h(t,r);return n?n.repo&&i(e.repo)===i(n.repo)?!0:d(e,r)===n:t.includes("/")?i(e.repo)===i(t):!0}function X(e,t){return e===null?!1:e===j?!0:!!h(e,t)||e.includes("/")}function q(e,t,r){return t===null?null:_(e,t,r)?t:null}function H(e){return e.entries.filter(t=>t.repo!==null&&(t.projects.length===0||t.projects.some(r=>E(r).status!=="detached")))}const L="__unassigned__",J={assignee:null,priority:null,due:null,tags:[],project:null,search:""},A=864e5;function I(e,t){const r=new Date(e),n=new Date(t);return r.getFullYear()===n.getFullYear()&&r.getMonth()===n.getMonth()&&r.getDate()===n.getDate()}function k(e,t){const r=e.trim();return r===""?!1:t!=null&&y(r)===t}function N(e,t){return e.assigneeId===t?!0:e.assigneeId===R&&e.assignedBy===t}function W(e,t,r){const n=t.search.trim().toLowerCase();if(n!==""&&!`${e.title} ${e.description??""}`.toLowerCase().includes(n)&&!k(n,e.keySeq))return!1;if(t.assignee!==null){if(t.assignee===L){if(e.assigneeId!==null)return!1}else if(!N(e,t.assignee))return!1}if(t.priority!==null&&e.priority!==t.priority)return!1;if(t.due!==null)if(t.due==="none"){if(e.dueDate)return!1}else{if(!e.dueDate)return!1;const s=new Date(e.dueDate).getTime(),a=Date.now();if(t.due==="overdue"&&s>=a||t.due==="today"&&!I(s,a)||t.due==="week"&&(s<a||s>a+7*A))return!1}if(t.tags.length>0){const s=e.tags.map(a=>a.id);if(!t.tags.some(a=>s.includes(a)))return!1}return!!_(e,t.project,r)}const F={overdue:"taskBoard.taskFilters.dueDateFilterOverdue",today:"taskBoard.taskFilters.dueDateFilterDueToday",week:"taskBoard.taskFilters.dueDateFilterDueThisWeek",none:"taskBoard.taskFilters.dueDateFilterNoDueDate"},Z=Object.keys(F);function Q(e){return F[e]}function $(e,t){return w(e,t.keySeq)??t.id}function V(e,t,r){const n=encodeURIComponent(e),s=encodeURIComponent($(e,t));return r?`/${n}/projects/${encodeURIComponent(r)}/tasks/${s}`:`/${n}/tasks/${s}`}function x(e,t){const r=t?.trim();if(r)return e.find(n=>k(r,n.keySeq))??e.find(n=>n.id===r)}const K=/^board_[\w-]+$/,B=64;function ee(e){const t=e.trim();return t.length>B?null:y(t)!==null||K.test(t)?t:null}export{Z as D,J as E,j as N,L as U,$ as a,G as b,z as c,Y as d,d as e,h as f,V as g,X as h,Q as i,W as j,x as k,q as l,ee as m,m as p,H as s,w as t};
@@ -1 +1 @@
1
- import{i as n}from"./AlertCircle-CIFSd5U6.js";import{i as r}from"./CheckCircle-BcLFM9-7.js";import{d2 as i}from"./index-BJCqpqJd.js";import{a_ as s,a$ as l,v as m}from"./agent-icon-B0fEYlzS.js";const a={requires_action:{labelKey:"common.taskStatus.requiresAction",icon:n,iconClassName:"text-warning",labelColor:"text-warning"},failed:{labelKey:"common.taskStatus.failed",icon:m,iconClassName:"text-destructive",labelColor:"text-destructive"},expired:{labelKey:"common.taskStatus.expired",icon:l,iconClassName:"text-warning",labelColor:"text-warning"},in_progress:{labelKey:"common.taskStatus.inProgress",icon:s,iconClassName:"text-primary",labelColor:"text-primary"},completed:{labelKey:"common.taskStatus.completed",icon:r,iconClassName:"text-muted-foreground/50",labelColor:"text-muted-foreground"}},o={labelKey:"common.taskStatus.unknown",icon:i,iconClassName:"text-muted-foreground",labelColor:"text-muted-foreground"};function c(e){return e in a}function C(e){if(e===null)return o;const t=e??"completed";return c(t)?a[t]:o}export{a as S,C as g};
1
+ import{i as n}from"./AlertCircle-RWTRMbKB.js";import{i as r}from"./CheckCircle-C2FTUn3P.js";import{d2 as i}from"./index-Bo0F7TR2.js";import{a_ as s,a$ as l,v as m}from"./agent-icon-DIz0uejY.js";const a={requires_action:{labelKey:"common.taskStatus.requiresAction",icon:n,iconClassName:"text-warning",labelColor:"text-warning"},failed:{labelKey:"common.taskStatus.failed",icon:m,iconClassName:"text-destructive",labelColor:"text-destructive"},expired:{labelKey:"common.taskStatus.expired",icon:l,iconClassName:"text-warning",labelColor:"text-warning"},in_progress:{labelKey:"common.taskStatus.inProgress",icon:s,iconClassName:"text-primary",labelColor:"text-primary"},completed:{labelKey:"common.taskStatus.completed",icon:r,iconClassName:"text-muted-foreground/50",labelColor:"text-muted-foreground"}},o={labelKey:"common.taskStatus.unknown",icon:i,iconClassName:"text-muted-foreground",labelColor:"text-muted-foreground"};function c(e){return e in a}function C(e){if(e===null)return o;const t=e??"completed";return c(t)?a[t]:o}export{a as S,C as g};
@@ -1 +1 @@
1
- import{c as M,b as q,f as J,r as P,j as r,B as W,L as X,h as Z}from"./index-BJCqpqJd.js";import{C as tt}from"./index-_bGtHSkW.js";import{S as et}from"./analytics-sections-DCH9uTvB.js";import{u as rt,A as G,a as st}from"./use-task-board-analytics-CcDxmijQ.js";import{C as at}from"./combobox-BSDZKZEG.js";import{c as it,b as ot,a as lt,d as mt,S as nt}from"./select-CV06ESGC.js";import{T as pt,a as ct,c as ft,b as dt}from"./tabs-Bhcrjsbm.js";import"./use-mobile-Cr6YJGI_.js";import"./thread-button-AF1WSMlL.js";import"./agent-icon-B0fEYlzS.js";import"./AlertCircle-CIFSd5U6.js";import"./Tool01-BThW1knZ.js";import"./ArrowUp-D2UY3OMh.js";import"./ArrowLeft-Cs3E2BgS.js";import"./ArrowRight-DdzTB6qI.js";import"./ShoppingBag01-DkKlB-7l.js";import"./ZoomOut-T_sjF8JP.js";import"./Palette-BUkGC_ZN.js";import"./CheckCircle-BcLFM9-7.js";import"./Check-CaNT0o8-.js";import"./ChevronUp-BU7d4Get.js";import"./UserSquare-D_CN0irU.js";import"./Copy01-BUTI0qm9.js";import"./CreditCard01-JGaESeVs.js";import"./DotsVertical-CIYGxTTU.js";import"./Image01-BZEauj2T.js";import"./XClose-BXY1fsWn.js";import"./Key01-RaCvEF1t.js";import"./Link01-B4kFCKUO.js";import"./LinkExternal01-Cn0PsKoO.js";import"./Monitor01-DDhoI_iK.js";import"./Sun-X5oRKWho.js";import"./Plus-0VzOcDpy.js";import"./SearchMd-DvVcOTQO.js";import"./Trash01-CWZehatA.js";import"./Upload01-DBJMMF89.js";import"./User01-CkC9PpwU.js";import"./Users01-Bly3LhS2.js";import"./X-B2uln9s5.js";import"./use-chat-layout-state-CRef6D4d.js";import"./thread-route-DQM8B2sI.js";import"./use-panel-navigate-BDo5oxs2.js";import"./use-project-scope-ELhrNYxO.js";import"./repository-binding--R5a6meD.js";import"./use-mcp-client-dYAEJ2Jd.js";import"./auth-D32cXta1.js";import"./thread-intent-BUShkesP.js";import"./backoff-8mStPHYB.js";import"./task-board-CJjc4xI-.js";import"./schema-BPGmAw0J.js";import"./slugify-CEUa2lfQ.js";import"./sheet-COySNUi4.js";import"./tooltip-DymYYuRo.js";import"./index-Cv3qPBot.js";import"./toolbar-icon-button-Bzitet5K.js";import"./shell-layout-BR24Afar.js";import"./avatar-DSv7rQey.js";import"./download-app-dialog-ilxwkPe1.js";import"./dialog-CYKucQEn.js";import"./command-3VOIGXTI.js";import"./index-CGwg_b5-.js";import"./integration-icon-BjqLrrwW.js";import"./project-icon-BWs8G7QE.js";import"./new-project-dialog-BmmmSjjo.js";import"./input-CE59clBd.js";import"./label-6ZrdaA5F.js";import"./repository-import-picker-zA2aRMgM.js";import"./use-navigate-to-agent-DoVNCwHy.js";import"./repository-picker-Ch8MjhWT.js";import"./useInfiniteQuery-CrHqvHwZ.js";import"./infiniteQueryObserver-DWdmBz6y.js";import"./collection-search-BRvScCfK.js";import"./use-debounced-value-BAjT0z0V.js";import"./use-organization-settings-B7IVGPSk.js";import"./use-is-desktop-app-BNujXJc_.js";import"./required-auth-layout-DrK2Ahbq.js";import"./autosend-B0cwcoZQ.js";import"./use-org-sso-C6AFvIzX.js";import"./resizable-DRo3WucN.js";import"./chart-DqY7SXIi.js";import"./index-8DK0gqav.js";import"./CartesianChart-V3ArQ0Ow.js";import"./table-ChI81Khw.js";import"./Line-Be2Fy-pZ.js";import"./ErrorBarContext--AuQGMxS.js";import"./Sector-9tybsTj9.js";import"./XAxis-M6tZ2obd.js";import"./popover-CxnAOud0.js";const ut=[7,30,90],xt={TASK_BOARD_DELIVERY:"taskBoard.analytics.tabDelivery",TASK_BOARD_STUCK:"taskBoard.analytics.tabStuck",TASK_BOARD_COST:"taskBoard.analytics.tabCost",TASK_BOARD_QUALITY:"taskBoard.analytics.tabQuality",TASK_BOARD_ERRORS:"taskBoard.analytics.tabErrors",TASK_BOARD_TENANTS:"taskBoard.analytics.tabTenants"};function gt(t){const e=M.c(18),{tool:a,org:f,from:d,to:K}=t,o=q();let x;e[0]!==d||e[1]!==f||e[2]!==K?(x={org:f,from:d,to:K},e[0]=d,e[1]=f,e[2]=K,e[3]=x):x=e[3];const{data:i,isLoading:Q,error:m}=st(a,x);if(Q){let l;return e[4]===Symbol.for("react.memo_cache_sentinel")?(l=r.jsx("div",{className:"flex justify-center py-12",children:r.jsx(Z,{className:"size-5 text-muted-foreground"})}),e[4]=l):l=e[4],l}if(m){let l;return e[5]!==m.message?(l=r.jsx("div",{className:"rounded-lg border border-border p-8 text-center text-sm text-destructive",children:m.message}),e[5]=m.message,e[6]=l):l=e[6],l}if(!i)return null;let n;e[7]!==i.sections?(n=i.sections.map(St),e[7]=i.sections,e[8]=n):n=e[8];let c;e[9]!==i.range.from||e[10]!==i.range.to||e[11]!==o?(c=o("taskBoard.analytics.rangeFootnote",{from:i.range.from.slice(0,10),to:i.range.to.slice(0,10)}),e[9]=i.range.from,e[10]=i.range.to,e[11]=o,e[12]=c):c=e[12];let p;e[13]!==c?(p=r.jsx("p",{className:"text-xs text-muted-foreground",children:c}),e[13]=c,e[14]=p):p=e[14];let u;return e[15]!==n||e[16]!==p?(u=r.jsxs("div",{className:"flex flex-col gap-8 py-6",children:[n,p]}),e[15]=n,e[16]=p,e[17]=u):u=e[17],u}function St(t){return r.jsx(et,{section:t,threadLinks:!0},t.title)}function tr(){const t=M.c(75),e=q(),a=J({strict:!1}).org??"",f=rt(),[d,K]=P.useState(30),[o,x]=P.useState(a),[i,Q]=P.useState("TASK_BOARD_DELIVERY"),[m]=P.useState(yt);let n;t[0]!==m?(n=new Date(m).toISOString(),t[0]=m,t[1]=n):n=t[1];const c=n;let p;t[2]!==d||t[3]!==m?(p=new Date(m-d*864e5).toISOString(),t[2]=d,t[3]=m,t[4]=p):p=t[4];const u=p,l=f.data?.isTaskBoardAdmin??!1;let g;t[5]!==e?(g=e("taskBoard.analytics.orgCurrent"),t[5]=e,t[6]=g):g=t[6];let S;t[7]!==a||t[8]!==g?(S={value:a,label:g},t[7]=a,t[8]=g,t[9]=S):S=t[9];let h;t[10]!==e?(h=e("taskBoard.analytics.orgAll"),t[10]=e,t[11]=h):h=t[11];let y;t[12]!==h?(y={value:"all",label:h},t[12]=h,t[13]=y):y=t[13];let I;if(t[14]!==f.data?.orgs||t[15]!==a||t[16]!==S||t[17]!==y){let s;t[19]!==a?(s=H=>H.slug!==a,t[19]=a,t[20]=s):s=t[20],I=[S,y,...(f.data?.orgs??[]).filter(s).map(ht)],t[14]=f.data?.orgs,t[15]=a,t[16]=S,t[17]=y,t[18]=I}else I=t[18];const U=I;let b;t[21]!==e?(b=e("taskBoard.analytics.title"),t[21]=e,t[22]=b):b=t[22];let B;t[23]!==b?(B=r.jsx("h1",{className:"text-xl font-medium text-foreground",children:b}),t[23]=b,t[24]=B):B=t[24];let A;t[25]!==l||t[26]!==o||t[27]!==U||t[28]!==e?(A=l&&r.jsx(at,{options:U,value:o,onChange:x,width:"w-[240px]",searchPlaceholder:e("taskBoard.analytics.orgSearch"),emptyMessage:e("taskBoard.analytics.orgEmpty")}),t[25]=l,t[26]=o,t[27]=U,t[28]=e,t[29]=A):A=t[29];const F=String(d);let V;t[30]===Symbol.for("react.memo_cache_sentinel")?(V=s=>K(Number(s)),t[30]=V):V=t[30];let Y;t[31]===Symbol.for("react.memo_cache_sentinel")?(Y=r.jsx(ot,{className:"w-[140px]",size:"sm",children:r.jsx(lt,{})}),t[31]=Y):Y=t[31];let T;t[32]!==e?(T=ut.map(s=>r.jsx(it,{value:String(s),children:e("taskBoard.analytics.rangeDays",{days:String(s)})},s)),t[32]=e,t[33]=T):T=t[33];let j;t[34]!==T?(j=r.jsx(mt,{children:T}),t[34]=T,t[35]=j):j=t[35];let k;t[36]!==F||t[37]!==j?(k=r.jsxs(nt,{value:F,onValueChange:V,children:[Y,j]}),t[36]=F,t[37]=j,t[38]=k):k=t[38];let _;t[39]!==a?(_={org:a},t[39]=a,t[40]=_):_=t[40];let v;t[41]!==e?(v=e("taskBoard.analytics.backToBoard"),t[41]=e,t[42]=v):v=t[42];let N;t[43]!==_||t[44]!==v?(N=r.jsx(W,{size:"sm",variant:"outline",asChild:!0,children:r.jsx(X,{to:"/$org/tasks/{-$taskKey}",params:_,children:v})}),t[43]=_,t[44]=v,t[45]=N):N=t[45];let O;t[46]!==k||t[47]!==N||t[48]!==A?(O=r.jsxs("div",{className:"ml-auto flex items-center gap-2",children:[A,k,N]}),t[46]=k,t[47]=N,t[48]=A,t[49]=O):O=t[49];let C;t[50]!==O||t[51]!==B?(C=r.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[B,O]}),t[50]=O,t[51]=B,t[52]=C):C=t[52];let D;t[53]!==o||t[54]!==a||t[55]!==e?(D=o!==a&&r.jsx("div",{className:"rounded-lg bg-warning/10 px-3 py-2 text-sm text-warning",children:o==="all"?e("taskBoard.analytics.bannerAll"):e("taskBoard.analytics.bannerOrg",{org:o})}),t[53]=o,t[54]=a,t[55]=e,t[56]=D):D=t[56];let $;t[57]===Symbol.for("react.memo_cache_sentinel")?($=s=>Q(s),t[57]=$):$=t[57];let R;t[58]!==e?(R=G.map(s=>r.jsx(pt,{value:s,children:e(xt[s])},s)),t[58]=e,t[59]=R):R=t[59];let E;t[60]!==R?(E=r.jsx(ct,{children:R}),t[60]=R,t[61]=E):E=t[61];let w;t[62]!==u||t[63]!==o||t[64]!==i||t[65]!==c?(w=G.map(s=>r.jsx(ft,{value:s,children:i===s&&r.jsx(gt,{tool:s,org:o,from:u,to:c})},s)),t[62]=u,t[63]=o,t[64]=i,t[65]=c,t[66]=w):w=t[66];let L;t[67]!==E||t[68]!==w||t[69]!==i?(L=r.jsxs(dt,{value:i,onValueChange:$,children:[E,w]}),t[67]=E,t[68]=w,t[69]=i,t[70]=L):L=t[70];let z;return t[71]!==C||t[72]!==D||t[73]!==L?(z=r.jsx(tt.Content,{children:r.jsx("div",{className:"flex h-full min-h-0 flex-col overflow-auto",children:r.jsxs("div",{className:"mx-auto flex w-full max-w-[1680px] flex-col gap-4 px-4 py-6 sm:px-8 sm:py-8",children:[C,D,L]})})}),t[71]=C,t[72]=D,t[73]=L,t[74]=z):z=t[74],z}function ht(t){return{value:t.slug,label:`${t.slug} · ${t.name}`}}function yt(){return Date.now()}export{tr as default};
1
+ import{c as M,b as q,f as J,r as P,j as r,B as W,L as X,h as Z}from"./index-Bo0F7TR2.js";import{C as tt}from"./index-SNhzEDgK.js";import{S as et}from"./analytics-sections-B-DAxD5H.js";import{u as rt,A as G,a as st}from"./use-task-board-analytics-BQJBm-B1.js";import{C as at}from"./combobox-DMurdTGm.js";import{c as it,b as ot,a as lt,d as mt,S as nt}from"./select-B29Xhi6X.js";import{T as pt,a as ct,c as ft,b as dt}from"./tabs-Bq5-PfFl.js";import"./use-mobile-BTzo-yNE.js";import"./thread-button-C7RONiC_.js";import"./agent-icon-DIz0uejY.js";import"./AlertCircle-RWTRMbKB.js";import"./Tool01-CQE4YIlY.js";import"./ArrowUp-CdkBKRTp.js";import"./ArrowLeft-B0Qy6MPA.js";import"./ArrowRight-1ZRv0qj4.js";import"./ShoppingBag01-eap5At3d.js";import"./ZoomOut-CacJRCxL.js";import"./Palette-Bowo13XO.js";import"./CheckCircle-C2FTUn3P.js";import"./Check-B08g8hfv.js";import"./ChevronUp-C43CLLe7.js";import"./UserSquare-OqUaFYcL.js";import"./Copy01-BFGk4HTi.js";import"./CreditCard01-D1x66FDR.js";import"./DotsVertical-D5Nqj0bW.js";import"./Image01-C3rMiZ72.js";import"./XClose-C_pErei1.js";import"./Key01-DJx3H4Mk.js";import"./Link01-DpMZQMbW.js";import"./LinkExternal01-Hrpy2rKU.js";import"./Monitor01-CHeJ4cBZ.js";import"./Sun-CQdyCDq1.js";import"./Plus-g-qUeP-5.js";import"./SearchMd-Bu5ZPloJ.js";import"./Trash01-ttayP08D.js";import"./Upload01-CxxYSCYc.js";import"./User01-gfze9rr9.js";import"./Users01-CrUbTlAS.js";import"./X-DmQciAIn.js";import"./use-chat-layout-state-BWgbiPAM.js";import"./thread-route-X4GbG7FV.js";import"./use-panel-navigate-EwAAwlcx.js";import"./use-project-scope-BQkBdDIR.js";import"./repository-binding-BGULsexx.js";import"./use-mcp-client-CgAwsTXX.js";import"./auth-DATmrrln.js";import"./thread-intent-J3vN5Vs_.js";import"./backoff-8mStPHYB.js";import"./task-board-C6pPuzYa.js";import"./schema-CJ-VqkAD.js";import"./slugify-CEUa2lfQ.js";import"./sheet-Ds43gFnt.js";import"./tooltip-CbYF5mhk.js";import"./index-NYSezzil.js";import"./toolbar-icon-button-BtgLueB7.js";import"./shell-layout-DTPbTm7i.js";import"./avatar-DnHqCpqr.js";import"./download-app-dialog-IVAbk28w.js";import"./dialog-5o2urGn5.js";import"./command-BDRqfDOz.js";import"./index-CSFjWyPp.js";import"./integration-icon-ChmmjcAp.js";import"./project-icon-BE7eT2UX.js";import"./new-project-dialog-CmsEVtp0.js";import"./input-Bg2anvwf.js";import"./label-CuQBcvRg.js";import"./repository-import-picker-Blpga-5j.js";import"./use-navigate-to-agent-CUailOkl.js";import"./repository-picker-B8Yoh_bh.js";import"./useInfiniteQuery-BUmcOy3_.js";import"./infiniteQueryObserver-CJ3Kym5O.js";import"./collection-search-Ch2FLY2_.js";import"./use-debounced-value-ClYZnycZ.js";import"./use-organization-settings-C-0W-ky3.js";import"./use-is-desktop-app-BNujXJc_.js";import"./required-auth-layout-DJxAIvUt.js";import"./autosend-CmBucBqr.js";import"./use-org-sso-C9wS7ZE_.js";import"./resizable-DT-ha9BR.js";import"./chart-CR5bi_LF.js";import"./index-Bencuqrd.js";import"./CartesianChart-DxxWBH9Y.js";import"./table-BFhRn6m5.js";import"./Line-U3trYLWi.js";import"./ErrorBarContext-Bka8_hCU.js";import"./Sector-CoFH2hT0.js";import"./XAxis-CXI1Q_NM.js";import"./popover-a7N6zy94.js";const ut=[7,30,90],xt={TASK_BOARD_DELIVERY:"taskBoard.analytics.tabDelivery",TASK_BOARD_STUCK:"taskBoard.analytics.tabStuck",TASK_BOARD_COST:"taskBoard.analytics.tabCost",TASK_BOARD_QUALITY:"taskBoard.analytics.tabQuality",TASK_BOARD_ERRORS:"taskBoard.analytics.tabErrors",TASK_BOARD_TENANTS:"taskBoard.analytics.tabTenants"};function gt(t){const e=M.c(18),{tool:a,org:f,from:d,to:K}=t,o=q();let x;e[0]!==d||e[1]!==f||e[2]!==K?(x={org:f,from:d,to:K},e[0]=d,e[1]=f,e[2]=K,e[3]=x):x=e[3];const{data:i,isLoading:Q,error:m}=st(a,x);if(Q){let l;return e[4]===Symbol.for("react.memo_cache_sentinel")?(l=r.jsx("div",{className:"flex justify-center py-12",children:r.jsx(Z,{className:"size-5 text-muted-foreground"})}),e[4]=l):l=e[4],l}if(m){let l;return e[5]!==m.message?(l=r.jsx("div",{className:"rounded-lg border border-border p-8 text-center text-sm text-destructive",children:m.message}),e[5]=m.message,e[6]=l):l=e[6],l}if(!i)return null;let n;e[7]!==i.sections?(n=i.sections.map(St),e[7]=i.sections,e[8]=n):n=e[8];let c;e[9]!==i.range.from||e[10]!==i.range.to||e[11]!==o?(c=o("taskBoard.analytics.rangeFootnote",{from:i.range.from.slice(0,10),to:i.range.to.slice(0,10)}),e[9]=i.range.from,e[10]=i.range.to,e[11]=o,e[12]=c):c=e[12];let p;e[13]!==c?(p=r.jsx("p",{className:"text-xs text-muted-foreground",children:c}),e[13]=c,e[14]=p):p=e[14];let u;return e[15]!==n||e[16]!==p?(u=r.jsxs("div",{className:"flex flex-col gap-8 py-6",children:[n,p]}),e[15]=n,e[16]=p,e[17]=u):u=e[17],u}function St(t){return r.jsx(et,{section:t,threadLinks:!0},t.title)}function tr(){const t=M.c(75),e=q(),a=J({strict:!1}).org??"",f=rt(),[d,K]=P.useState(30),[o,x]=P.useState(a),[i,Q]=P.useState("TASK_BOARD_DELIVERY"),[m]=P.useState(yt);let n;t[0]!==m?(n=new Date(m).toISOString(),t[0]=m,t[1]=n):n=t[1];const c=n;let p;t[2]!==d||t[3]!==m?(p=new Date(m-d*864e5).toISOString(),t[2]=d,t[3]=m,t[4]=p):p=t[4];const u=p,l=f.data?.isTaskBoardAdmin??!1;let g;t[5]!==e?(g=e("taskBoard.analytics.orgCurrent"),t[5]=e,t[6]=g):g=t[6];let S;t[7]!==a||t[8]!==g?(S={value:a,label:g},t[7]=a,t[8]=g,t[9]=S):S=t[9];let h;t[10]!==e?(h=e("taskBoard.analytics.orgAll"),t[10]=e,t[11]=h):h=t[11];let y;t[12]!==h?(y={value:"all",label:h},t[12]=h,t[13]=y):y=t[13];let I;if(t[14]!==f.data?.orgs||t[15]!==a||t[16]!==S||t[17]!==y){let s;t[19]!==a?(s=H=>H.slug!==a,t[19]=a,t[20]=s):s=t[20],I=[S,y,...(f.data?.orgs??[]).filter(s).map(ht)],t[14]=f.data?.orgs,t[15]=a,t[16]=S,t[17]=y,t[18]=I}else I=t[18];const U=I;let b;t[21]!==e?(b=e("taskBoard.analytics.title"),t[21]=e,t[22]=b):b=t[22];let B;t[23]!==b?(B=r.jsx("h1",{className:"text-xl font-medium text-foreground",children:b}),t[23]=b,t[24]=B):B=t[24];let A;t[25]!==l||t[26]!==o||t[27]!==U||t[28]!==e?(A=l&&r.jsx(at,{options:U,value:o,onChange:x,width:"w-[240px]",searchPlaceholder:e("taskBoard.analytics.orgSearch"),emptyMessage:e("taskBoard.analytics.orgEmpty")}),t[25]=l,t[26]=o,t[27]=U,t[28]=e,t[29]=A):A=t[29];const F=String(d);let V;t[30]===Symbol.for("react.memo_cache_sentinel")?(V=s=>K(Number(s)),t[30]=V):V=t[30];let Y;t[31]===Symbol.for("react.memo_cache_sentinel")?(Y=r.jsx(ot,{className:"w-[140px]",size:"sm",children:r.jsx(lt,{})}),t[31]=Y):Y=t[31];let T;t[32]!==e?(T=ut.map(s=>r.jsx(it,{value:String(s),children:e("taskBoard.analytics.rangeDays",{days:String(s)})},s)),t[32]=e,t[33]=T):T=t[33];let j;t[34]!==T?(j=r.jsx(mt,{children:T}),t[34]=T,t[35]=j):j=t[35];let k;t[36]!==F||t[37]!==j?(k=r.jsxs(nt,{value:F,onValueChange:V,children:[Y,j]}),t[36]=F,t[37]=j,t[38]=k):k=t[38];let _;t[39]!==a?(_={org:a},t[39]=a,t[40]=_):_=t[40];let v;t[41]!==e?(v=e("taskBoard.analytics.backToBoard"),t[41]=e,t[42]=v):v=t[42];let N;t[43]!==_||t[44]!==v?(N=r.jsx(W,{size:"sm",variant:"outline",asChild:!0,children:r.jsx(X,{to:"/$org/tasks/{-$taskKey}",params:_,children:v})}),t[43]=_,t[44]=v,t[45]=N):N=t[45];let O;t[46]!==k||t[47]!==N||t[48]!==A?(O=r.jsxs("div",{className:"ml-auto flex items-center gap-2",children:[A,k,N]}),t[46]=k,t[47]=N,t[48]=A,t[49]=O):O=t[49];let C;t[50]!==O||t[51]!==B?(C=r.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[B,O]}),t[50]=O,t[51]=B,t[52]=C):C=t[52];let D;t[53]!==o||t[54]!==a||t[55]!==e?(D=o!==a&&r.jsx("div",{className:"rounded-lg bg-warning/10 px-3 py-2 text-sm text-warning",children:o==="all"?e("taskBoard.analytics.bannerAll"):e("taskBoard.analytics.bannerOrg",{org:o})}),t[53]=o,t[54]=a,t[55]=e,t[56]=D):D=t[56];let $;t[57]===Symbol.for("react.memo_cache_sentinel")?($=s=>Q(s),t[57]=$):$=t[57];let R;t[58]!==e?(R=G.map(s=>r.jsx(pt,{value:s,children:e(xt[s])},s)),t[58]=e,t[59]=R):R=t[59];let E;t[60]!==R?(E=r.jsx(ct,{children:R}),t[60]=R,t[61]=E):E=t[61];let w;t[62]!==u||t[63]!==o||t[64]!==i||t[65]!==c?(w=G.map(s=>r.jsx(ft,{value:s,children:i===s&&r.jsx(gt,{tool:s,org:o,from:u,to:c})},s)),t[62]=u,t[63]=o,t[64]=i,t[65]=c,t[66]=w):w=t[66];let L;t[67]!==E||t[68]!==w||t[69]!==i?(L=r.jsxs(dt,{value:i,onValueChange:$,children:[E,w]}),t[67]=E,t[68]=w,t[69]=i,t[70]=L):L=t[70];let z;return t[71]!==C||t[72]!==D||t[73]!==L?(z=r.jsx(tt.Content,{children:r.jsx("div",{className:"flex h-full min-h-0 flex-col overflow-auto",children:r.jsxs("div",{className:"mx-auto flex w-full max-w-[1680px] flex-col gap-4 px-4 py-6 sm:px-8 sm:py-8",children:[C,D,L]})})}),t[71]=C,t[72]=D,t[73]=L,t[74]=z):z=t[74],z}function ht(t){return{value:t.slug,label:`${t.slug} · ${t.name}`}}function yt(){return Date.now()}export{tr as default};
@@ -0,0 +1 @@
1
+ import{c as l,X as n,j as r,K as f}from"./index-Bo0F7TR2.js";import{C as d}from"./index-SNhzEDgK.js";import{T as u}from"./index-CUa4r7Sg.js";import{F as x}from"./feature-gate-Cg4_Q8Ke.js";import{m as h,P as j}from"./mock-board-C601dKME.js";import"./use-mobile-BTzo-yNE.js";import"./thread-button-C7RONiC_.js";import"./agent-icon-DIz0uejY.js";import"./AlertCircle-RWTRMbKB.js";import"./Tool01-CQE4YIlY.js";import"./ArrowUp-CdkBKRTp.js";import"./ArrowLeft-B0Qy6MPA.js";import"./ArrowRight-1ZRv0qj4.js";import"./ShoppingBag01-eap5At3d.js";import"./ZoomOut-CacJRCxL.js";import"./Palette-Bowo13XO.js";import"./CheckCircle-C2FTUn3P.js";import"./Check-B08g8hfv.js";import"./ChevronUp-C43CLLe7.js";import"./UserSquare-OqUaFYcL.js";import"./Copy01-BFGk4HTi.js";import"./CreditCard01-D1x66FDR.js";import"./DotsVertical-D5Nqj0bW.js";import"./Image01-C3rMiZ72.js";import"./XClose-C_pErei1.js";import"./Key01-DJx3H4Mk.js";import"./Link01-DpMZQMbW.js";import"./LinkExternal01-Hrpy2rKU.js";import"./Monitor01-CHeJ4cBZ.js";import"./Sun-CQdyCDq1.js";import"./Plus-g-qUeP-5.js";import"./SearchMd-Bu5ZPloJ.js";import"./Trash01-ttayP08D.js";import"./Upload01-CxxYSCYc.js";import"./User01-gfze9rr9.js";import"./Users01-CrUbTlAS.js";import"./X-DmQciAIn.js";import"./use-chat-layout-state-BWgbiPAM.js";import"./thread-route-X4GbG7FV.js";import"./use-panel-navigate-EwAAwlcx.js";import"./use-project-scope-BQkBdDIR.js";import"./repository-binding-BGULsexx.js";import"./use-mcp-client-CgAwsTXX.js";import"./auth-DATmrrln.js";import"./thread-intent-J3vN5Vs_.js";import"./backoff-8mStPHYB.js";import"./task-board-C6pPuzYa.js";import"./schema-CJ-VqkAD.js";import"./slugify-CEUa2lfQ.js";import"./sheet-Ds43gFnt.js";import"./tooltip-CbYF5mhk.js";import"./index-NYSezzil.js";import"./toolbar-icon-button-BtgLueB7.js";import"./shell-layout-DTPbTm7i.js";import"./avatar-DnHqCpqr.js";import"./download-app-dialog-IVAbk28w.js";import"./dialog-5o2urGn5.js";import"./command-BDRqfDOz.js";import"./index-CSFjWyPp.js";import"./integration-icon-ChmmjcAp.js";import"./project-icon-BE7eT2UX.js";import"./new-project-dialog-CmsEVtp0.js";import"./input-Bg2anvwf.js";import"./label-CuQBcvRg.js";import"./repository-import-picker-Blpga-5j.js";import"./use-navigate-to-agent-CUailOkl.js";import"./repository-picker-B8Yoh_bh.js";import"./useInfiniteQuery-BUmcOy3_.js";import"./infiniteQueryObserver-CJ3Kym5O.js";import"./collection-search-Ch2FLY2_.js";import"./use-debounced-value-ClYZnycZ.js";import"./use-organization-settings-C-0W-ky3.js";import"./use-is-desktop-app-BNujXJc_.js";import"./required-auth-layout-DJxAIvUt.js";import"./autosend-CmBucBqr.js";import"./use-org-sso-C9wS7ZE_.js";import"./resizable-DT-ha9BR.js";import"./rich-text-link-control-Bk19iHyH.js";import"./use-task-board-analytics-BQJBm-B1.js";import"./combobox-DMurdTGm.js";import"./popover-a7N6zy94.js";import"./get-initials-D-f_fDFw.js";import"./search-toggle-DmuwYEgq.js";import"./config-FL7tBmjS.js";import"./use-decopilot-events-Bz4QYcmu.js";import"./use-members-B5WIwJLk.js";import"./use-org-auth-client-VwQi3i7g.js";import"./format-time-CjIPQhCN.js";import"./differenceInSeconds-C3x8sHUj.js";import"./use-tags-D6lRTA5X.js";import"./task-route-BnZ6hudq.js";import"./calendar-DqQMMLc-.js";import"./alert-BRnmUkhb.js";import"./collapsible-cP4qew3h.js";import"./use-copy-BfHUaImm.js";import"./markdown-ByHIpwAl.js";import"./org-file-open-context-A6PAiYSr.js";import"./index-N982P05Q.js";import"./index-BNVSW_Xa.js";import"./gateway-client-DGz23Vlr.js";import"./form-CparX5oE.js";import"./utils-CVEq3hMx.js";import"./suggestion-DSzvJMf5.js";import"./index-vBxL1reA.js";import"./use-org-fs-JCXip5_c.js";import"./sandbox-start-errors-BK_aDCyt.js";import"./use-connection-x5NSsBTY.js";import"./github-repo-scope-C8GSbvaz.js";import"./thread-sheet-body-DMUuynmz.js";import"./useSuspenseInfiniteQuery-BBD5zNHU.js";import"./pair-BCvCT-GT.js";import"./usage-stats-Bd-A9GxK.js";import"./chat-context-BUNOOLZ7.js";import"./use-ai-providers-C99u_E8Y.js";import"./location-DBePU4bz.js";import"./content-blocks-o63cs2vh.js";import"./mcp-app-renderer-C0Zh7icj.js";import"./types-ByzlXSpq.js";import"./omit-sandbox-map-jj4lCB2U.js";import"./tool-namespace-DmnQIdtF.js";import"./use-mcp-prompts-BIwfN9eR.js";import"./use-thread-outputs-CKvUbe8p.js";import"./file-type-icon-ChEWF5Jy.js";import"./use-infinite-scroll-B8GLgbd5.js";import"./task-status-D3QqYPID.js";import"./use-open-billing-url-hrUTQY32.js";import"./chat-draft-BTyf-RT4.js";import"./badge-DsCXhAux.js";import"./separator-BgwMr24m.js";import"./feature-paywall-CNWP0h2q.js";import"./plan-ladder-BwZyCGet.js";function a(){const t=l.c(1);let o;return t[0]===Symbol.for("react.memo_cache_sentinel")?(o=r.jsx("div",{className:"flex h-full min-h-0 flex-col overflow-hidden",children:r.jsx(u,{})}),t[0]=o):o=t[0],o}function Xo(){const t=l.c(8),{locator:o}=n();let m;t[0]!==o?(m=c=>c.setQueryData(f.taskBoardItems(o),h()),t[0]=o,t[1]=m):m=t[1];let p;t[2]===Symbol.for("react.memo_cache_sentinel")?(p=r.jsx(a,{}),t[2]=p):p=t[2];let i;t[3]!==m?(i=r.jsx(j,{seed:m,children:p}),t[3]=m,t[4]=i):i=t[4];let e;t[5]===Symbol.for("react.memo_cache_sentinel")?(e=r.jsx(a,{}),t[5]=e):e=t[5];let s;return t[6]!==i?(s=r.jsx(d.Content,{children:r.jsx(x,{feature:"kanban",backdrop:i,children:e})}),t[6]=i,t[7]=s):s=t[7],s}export{Xo as default};
@@ -1,4 +1,4 @@
1
- import{c as _,j as r,X as J,a2 as H,K as W,m as re,o as pe,e as ae,b as D,r as w,aP as he,B as M,t as L,dW as fe,dX as G,dV as be,n as de,f6 as Te,s as Se,l as Ce,L as we}from"./index-BJCqpqJd.js";import{C as xe}from"./checkbox-CKTKlc0c.js";import{I as ue}from"./input-CE59clBd.js";import{T as Ne}from"./textarea-BXhBwPZM.js";import{i as _e}from"./Check-CaNT0o8-.js";import{i as Ae}from"./Tool01-BThW1knZ.js";import{i as Re}from"./Sun-X5oRKWho.js";import{s as Ie}from"./Plus-0VzOcDpy.js";import{s as $e}from"./Trash01-CWZehatA.js";import{C as Ee}from"./combobox-BSDZKZEG.js";import{S as Ke}from"./switch-DcKRnaVG.js";import{a as De,T as Le}from"./input-BjKsQzeZ.js";import{p as Oe}from"./skill-md-ChfVs4uF.js";import{A as Be,a as Fe,b as ze,c as Ue,g as qe,d as Me,e as Je,f as He}from"./alert-dialog-DJp_Ityl.js";import{R as We,A as Qe}from"./review-settings-BHVALtQt.js";import{h as Ge}from"./task-board-CJjc4xI-.js";import{R as Ve}from"./require-capability-z1ZYrtyD.js";import"./command-3VOIGXTI.js";import"./index-CGwg_b5-.js";import"./dialog-CYKucQEn.js";import"./X-B2uln9s5.js";import"./SearchMd-DvVcOTQO.js";import"./popover-CxnAOud0.js";import"./suggestion-CqfoTsij.js";import"./index-ySi4Pwot.js";import"./gateway-client-BtY2d8II.js";import"./form-BuKMCQ_-.js";import"./label-6ZrdaA5F.js";import"./utils-CVEq3hMx.js";import"./org-file-open-context-kXusxtya.js";import"./use-mobile-Cr6YJGI_.js";import"./use-panel-navigate-BDo5oxs2.js";import"./thread-route-DQM8B2sI.js";import"./use-project-scope-ELhrNYxO.js";import"./repository-binding--R5a6meD.js";import"./use-mcp-client-dYAEJ2Jd.js";import"./auth-D32cXta1.js";import"./tooltip-DymYYuRo.js";import"./index-Cv3qPBot.js";import"./agent-icon-B0fEYlzS.js";import"./AlertCircle-CIFSd5U6.js";import"./ArrowUp-D2UY3OMh.js";import"./ArrowLeft-Cs3E2BgS.js";import"./ArrowRight-DdzTB6qI.js";import"./ShoppingBag01-DkKlB-7l.js";import"./ZoomOut-T_sjF8JP.js";import"./Palette-BUkGC_ZN.js";import"./CheckCircle-BcLFM9-7.js";import"./ChevronUp-BU7d4Get.js";import"./UserSquare-D_CN0irU.js";import"./Copy01-BUTI0qm9.js";import"./CreditCard01-JGaESeVs.js";import"./DotsVertical-CIYGxTTU.js";import"./Image01-BZEauj2T.js";import"./XClose-BXY1fsWn.js";import"./Key01-RaCvEF1t.js";import"./Link01-B4kFCKUO.js";import"./LinkExternal01-Cn0PsKoO.js";import"./Monitor01-DDhoI_iK.js";import"./Upload01-DBJMMF89.js";import"./User01-CkC9PpwU.js";import"./Users01-Bly3LhS2.js";import"./chat-context-DFdcIErL.js";import"./autosend-B0cwcoZQ.js";import"./thread-intent-BUShkesP.js";import"./backoff-8mStPHYB.js";import"./slugify-CEUa2lfQ.js";import"./use-is-desktop-app-BNujXJc_.js";import"./use-decopilot-events-BXaRjj_f.js";import"./use-ai-providers-BkzLFMQR.js";import"./location-DBePU4bz.js";import"./use-organization-settings-B7IVGPSk.js";import"./schema-BPGmAw0J.js";import"./decopilot-fXzeGhfJ.js";import"./select-CV06ESGC.js";import"./ai-providers-logos-DD3qZ33J.js";import"./avatar-DSv7rQey.js";import"./download-app-dialog-ilxwkPe1.js";import"./use-mcp-prompts-CytnXWFX.js";import"./use-org-fs-DBAxCQBE.js";import"./use-new-blocks-editor-CTbC874V.js";import"./use-connection-rm3wb9zf.js";import"./access-gate-CA8I0iHR.js";import"./capability-load-error-BE5lkHsD.js";const Ye=/^([A-Za-z][A-Za-z0-9_]*-\d+)$/;function Ze(e){const t=e.trim();if(t==="")return null;const s=/(?:\/(?:browse|issues)\/|[?&]selectedIssue=)([A-Za-z][A-Za-z0-9_]*-\d+)/.exec(t)?.[1]??t.split(/[?#]/)[0]??"",i=Ye.exec(s);return i?.[1]?i[1].toUpperCase():null}function Pe(e){const t=[],n=[],s=new Set;for(const i of e.split(/[\n,;]+/)){const l=i.trim();if(l==="")continue;const a=Ze(l);if(!a){n.push(l);continue}s.has(a)||(s.add(a),t.push(a))}return{keys:t,invalid:n}}function Xe(e){return{type:"doc",content:e.split(`
1
+ import{c as _,j as r,X as J,a2 as H,K as W,m as re,o as pe,e as ae,b as D,r as w,aP as he,B as M,t as L,dW as fe,dX as G,dV as be,n as de,f6 as Te,s as Se,l as Ce,L as we}from"./index-Bo0F7TR2.js";import{C as xe}from"./checkbox-kO5XQBSL.js";import{I as ue}from"./input-Bg2anvwf.js";import{T as Ne}from"./textarea-CE_tOq7F.js";import{i as _e}from"./Check-B08g8hfv.js";import{i as Ae}from"./Tool01-CQE4YIlY.js";import{i as Re}from"./Sun-CQdyCDq1.js";import{s as Ie}from"./Plus-g-qUeP-5.js";import{s as $e}from"./Trash01-ttayP08D.js";import{C as Ee}from"./combobox-DMurdTGm.js";import{S as Ke}from"./switch-chDwefPP.js";import{a as De,T as Le}from"./input-CymJ2z2F.js";import{p as Oe}from"./skill-md-ChfVs4uF.js";import{A as Be,a as Fe,b as ze,c as Ue,g as qe,d as Me,e as Je,f as He}from"./alert-dialog-UJiEdIyw.js";import{R as We,A as Qe}from"./review-settings-DaYTV2bK.js";import{h as Ge}from"./task-board-C6pPuzYa.js";import{R as Ve}from"./require-capability-1wZrr2Ds.js";import"./command-BDRqfDOz.js";import"./index-CSFjWyPp.js";import"./dialog-5o2urGn5.js";import"./X-DmQciAIn.js";import"./SearchMd-Bu5ZPloJ.js";import"./popover-a7N6zy94.js";import"./suggestion-DSzvJMf5.js";import"./index-BNVSW_Xa.js";import"./gateway-client-DGz23Vlr.js";import"./form-CparX5oE.js";import"./label-CuQBcvRg.js";import"./utils-CVEq3hMx.js";import"./org-file-open-context-A6PAiYSr.js";import"./use-mobile-BTzo-yNE.js";import"./use-panel-navigate-EwAAwlcx.js";import"./thread-route-X4GbG7FV.js";import"./use-project-scope-BQkBdDIR.js";import"./repository-binding-BGULsexx.js";import"./use-mcp-client-CgAwsTXX.js";import"./auth-DATmrrln.js";import"./tooltip-CbYF5mhk.js";import"./index-NYSezzil.js";import"./agent-icon-DIz0uejY.js";import"./AlertCircle-RWTRMbKB.js";import"./ArrowUp-CdkBKRTp.js";import"./ArrowLeft-B0Qy6MPA.js";import"./ArrowRight-1ZRv0qj4.js";import"./ShoppingBag01-eap5At3d.js";import"./ZoomOut-CacJRCxL.js";import"./Palette-Bowo13XO.js";import"./CheckCircle-C2FTUn3P.js";import"./ChevronUp-C43CLLe7.js";import"./UserSquare-OqUaFYcL.js";import"./Copy01-BFGk4HTi.js";import"./CreditCard01-D1x66FDR.js";import"./DotsVertical-D5Nqj0bW.js";import"./Image01-C3rMiZ72.js";import"./XClose-C_pErei1.js";import"./Key01-DJx3H4Mk.js";import"./Link01-DpMZQMbW.js";import"./LinkExternal01-Hrpy2rKU.js";import"./Monitor01-CHeJ4cBZ.js";import"./Upload01-CxxYSCYc.js";import"./User01-gfze9rr9.js";import"./Users01-CrUbTlAS.js";import"./chat-context-BUNOOLZ7.js";import"./autosend-CmBucBqr.js";import"./thread-intent-J3vN5Vs_.js";import"./backoff-8mStPHYB.js";import"./slugify-CEUa2lfQ.js";import"./use-is-desktop-app-BNujXJc_.js";import"./use-decopilot-events-Bz4QYcmu.js";import"./use-ai-providers-C99u_E8Y.js";import"./location-DBePU4bz.js";import"./use-organization-settings-C-0W-ky3.js";import"./schema-CJ-VqkAD.js";import"./decopilot-Bv_sAiFM.js";import"./select-B29Xhi6X.js";import"./ai-providers-logos-DD3qZ33J.js";import"./avatar-DnHqCpqr.js";import"./download-app-dialog-IVAbk28w.js";import"./use-mcp-prompts-BIwfN9eR.js";import"./use-org-fs-JCXip5_c.js";import"./use-new-blocks-editor-5rrvUzSm.js";import"./use-connection-x5NSsBTY.js";import"./access-gate-Dfd2-cvG.js";import"./capability-load-error-AKSk2IJm.js";const Ye=/^([A-Za-z][A-Za-z0-9_]*-\d+)$/;function Ze(e){const t=e.trim();if(t==="")return null;const s=/(?:\/(?:browse|issues)\/|[?&]selectedIssue=)([A-Za-z][A-Za-z0-9_]*-\d+)/.exec(t)?.[1]??t.split(/[?#]/)[0]??"",i=Ye.exec(s);return i?.[1]?i[1].toUpperCase():null}function Pe(e){const t=[],n=[],s=new Set;for(const i of e.split(/[\n,;]+/)){const l=i.trim();if(l==="")continue;const a=Ze(l);if(!a){n.push(l);continue}s.has(a)||(s.add(a),t.push(a))}return{keys:t,invalid:n}}function Xe(e){return{type:"doc",content:e.split(`
2
2
  `).map(t=>({type:"paragraph",...t===""?{}:{content:[{type:"text",text:t}]}}))}}const et=new Set(["paragraph","heading","codeBlock","listItem"]);function tt(e){return(e.files??[]).filter(n=>n.content?.trim()).map(n=>n.relPath==="SKILL.md"?Oe(n.content).body.trim():`${n.relPath}:
3
3
  ${n.content.trim()}`).join(`
4
4
 
@@ -1 +1 @@
1
- import{c as o,l,j as n}from"./index-BJCqpqJd.js";function c(s){const e=o.c(8);let i,r;e[0]!==s?({className:i,...r}=s,e[0]=s,e[1]=i,e[2]=r):(i=e[1],r=e[2]);let t;e[3]!==i?(t=l("placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/20 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive flex field-sizing-content min-h-16 w-full rounded-[var(--studio-control-radius,var(--radius-xl))] bg-[var(--studio-input-background)] px-3 py-2 text-sm transition-[color,box-shadow] outline-none focus-visible:ring-[2px] card-shadow disabled:cursor-not-allowed disabled:opacity-50",i),e[3]=i,e[4]=t):t=e[4];let a;return e[5]!==r||e[6]!==t?(a=n.jsx("textarea",{"data-slot":"textarea",className:t,...r}),e[5]=r,e[6]=t,e[7]=a):a=e[7],a}export{c as T};
1
+ import{c as o,l,j as n}from"./index-Bo0F7TR2.js";function c(s){const e=o.c(8);let i,r;e[0]!==s?({className:i,...r}=s,e[0]=s,e[1]=i,e[2]=r):(i=e[1],r=e[2]);let t;e[3]!==i?(t=l("placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/20 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive flex field-sizing-content min-h-16 w-full rounded-[var(--studio-control-radius,var(--radius-xl))] bg-[var(--studio-input-background)] px-3 py-2 text-sm transition-[color,box-shadow] outline-none focus-visible:ring-[2px] card-shadow disabled:cursor-not-allowed disabled:opacity-50",i),e[3]=i,e[4]=t):t=e[4];let a;return e[5]!==r||e[6]!==t?(a=n.jsx("textarea",{"data-slot":"textarea",className:t,...r}),e[5]=r,e[6]=t,e[7]=a):a=e[7],a}export{c as T};
@@ -1 +1 @@
1
- import{c as U,b as ee,f as ge,r as z,j as s,h as je,X as pe,c2 as Se,z as ye}from"./index-BJCqpqJd.js";import{C as se}from"./index-_bGtHSkW.js";import{S as be}from"./analytics-sections-DCH9uTvB.js";import{u as ve,a as Ne,b as Te}from"./use-thread-analytics-DgyRTsuJ.js";import{B as Ce}from"./badge-BVm53kyq.js";import{C as _e}from"./combobox-BSDZKZEG.js";import{S as ie,b as oe,a as ne,d as ce,c as Z}from"./select-CV06ESGC.js";import{e as Ae,a as we,b as fe,T as V,d as ke,c as K}from"./table-ChI81Khw.js";import{T as le,a as Le,c as re,b as Ee}from"./tabs-Bhcrjsbm.js";import{c as Re,S as Ie,a as $e,b as Be}from"./sheet-COySNUi4.js";import{T as De}from"./thread-sheet-body-DwAizuR8.js";import{u as Oe}from"./use-connection-rm3wb9zf.js";import{u as Pe}from"./use-mcp-client-dYAEJ2Jd.js";import{b as He}from"./repository-binding--R5a6meD.js";import"./use-mobile-Cr6YJGI_.js";import"./thread-button-AF1WSMlL.js";import"./agent-icon-B0fEYlzS.js";import"./AlertCircle-CIFSd5U6.js";import"./Tool01-BThW1knZ.js";import"./ArrowUp-D2UY3OMh.js";import"./ArrowLeft-Cs3E2BgS.js";import"./ArrowRight-DdzTB6qI.js";import"./ShoppingBag01-DkKlB-7l.js";import"./ZoomOut-T_sjF8JP.js";import"./Palette-BUkGC_ZN.js";import"./CheckCircle-BcLFM9-7.js";import"./Check-CaNT0o8-.js";import"./ChevronUp-BU7d4Get.js";import"./UserSquare-D_CN0irU.js";import"./Copy01-BUTI0qm9.js";import"./CreditCard01-JGaESeVs.js";import"./DotsVertical-CIYGxTTU.js";import"./Image01-BZEauj2T.js";import"./XClose-BXY1fsWn.js";import"./Key01-RaCvEF1t.js";import"./Link01-B4kFCKUO.js";import"./LinkExternal01-Cn0PsKoO.js";import"./Monitor01-DDhoI_iK.js";import"./Sun-X5oRKWho.js";import"./Plus-0VzOcDpy.js";import"./SearchMd-DvVcOTQO.js";import"./Trash01-CWZehatA.js";import"./Upload01-DBJMMF89.js";import"./User01-CkC9PpwU.js";import"./Users01-Bly3LhS2.js";import"./X-B2uln9s5.js";import"./use-chat-layout-state-CRef6D4d.js";import"./thread-route-DQM8B2sI.js";import"./use-panel-navigate-BDo5oxs2.js";import"./use-project-scope-ELhrNYxO.js";import"./thread-intent-BUShkesP.js";import"./backoff-8mStPHYB.js";import"./task-board-CJjc4xI-.js";import"./schema-BPGmAw0J.js";import"./slugify-CEUa2lfQ.js";import"./tooltip-DymYYuRo.js";import"./index-Cv3qPBot.js";import"./toolbar-icon-button-Bzitet5K.js";import"./shell-layout-BR24Afar.js";import"./avatar-DSv7rQey.js";import"./download-app-dialog-ilxwkPe1.js";import"./dialog-CYKucQEn.js";import"./command-3VOIGXTI.js";import"./index-CGwg_b5-.js";import"./integration-icon-BjqLrrwW.js";import"./project-icon-BWs8G7QE.js";import"./new-project-dialog-BmmmSjjo.js";import"./input-CE59clBd.js";import"./label-6ZrdaA5F.js";import"./repository-import-picker-zA2aRMgM.js";import"./use-navigate-to-agent-DoVNCwHy.js";import"./repository-picker-Ch8MjhWT.js";import"./useInfiniteQuery-CrHqvHwZ.js";import"./infiniteQueryObserver-DWdmBz6y.js";import"./collection-search-BRvScCfK.js";import"./use-debounced-value-BAjT0z0V.js";import"./use-organization-settings-B7IVGPSk.js";import"./use-is-desktop-app-BNujXJc_.js";import"./required-auth-layout-DrK2Ahbq.js";import"./autosend-B0cwcoZQ.js";import"./use-org-sso-C6AFvIzX.js";import"./resizable-DRo3WucN.js";import"./chart-DqY7SXIi.js";import"./index-8DK0gqav.js";import"./CartesianChart-V3ArQ0Ow.js";import"./Line-Be2Fy-pZ.js";import"./ErrorBarContext--AuQGMxS.js";import"./Sector-9tybsTj9.js";import"./XAxis-M6tZ2obd.js";import"./popover-CxnAOud0.js";import"./useSuspenseInfiniteQuery-Di3mCiFx.js";import"./pair-BolEqp4H.js";import"./format-time-CjIPQhCN.js";import"./differenceInSeconds-C3x8sHUj.js";import"./collapsible-CKtvk2qR.js";import"./use-copy-Bb6V_Y-2.js";import"./usage-stats-zkwjwtUJ.js";import"./markdown-JTzUPlKH.js";import"./org-file-open-context-kXusxtya.js";import"./use-decopilot-events-BXaRjj_f.js";import"./chat-context-DFdcIErL.js";import"./use-ai-providers-BkzLFMQR.js";import"./location-DBePU4bz.js";import"./content-blocks-o63cs2vh.js";import"./mcp-app-renderer-k0tZLm07.js";import"./types-cb53ubAI.js";import"./omit-sandbox-map-jj4lCB2U.js";import"./gateway-client-BtY2d8II.js";import"./tool-namespace-DmnQIdtF.js";import"./utils-CVEq3hMx.js";import"./use-mcp-prompts-CytnXWFX.js";import"./index-ySi4Pwot.js";import"./form-BuKMCQ_-.js";import"./use-thread-outputs-BEwXZ8Vh.js";import"./file-type-icon-GNT0wjq6.js";import"./use-infinite-scroll-CnOZ3QQs.js";import"./task-status-DB9VzvnI.js";import"./auth-D32cXta1.js";const Ve=[1,7,30,90],Ke=["in_progress","requires_action","failed","completed"],Ue=["chat","automation","task"],Q="any",me={in_progress:"thread.analytics.statusRunning",requires_action:"thread.analytics.statusWaiting",failed:"thread.analytics.statusFailed",completed:"thread.analytics.statusCompleted"},xe={chat:"thread.analytics.kindChat",automation:"thread.analytics.kindAutomation",task:"thread.analytics.kindTask"},ze={in_progress:"default",requires_action:"warning",failed:"destructive",completed:"secondary"};function de(){const t=U.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx("div",{className:"flex justify-center py-12",children:s.jsx(je,{className:"size-5 text-muted-foreground"})}),t[0]=e):e=t[0],e}function he(t){const e=U.c(2),{message:l}=t;let r;return e[0]!==l?(r=s.jsx("div",{className:"rounded-lg border border-border p-8 text-center text-sm text-destructive",children:l}),e[0]=l,e[1]=r):r=e[1],r}function ae(t){const e=U.c(9),{label:l,value:r}=t;let a;e[0]!==l?(a=s.jsx("div",{className:"text-sm text-muted-foreground",children:l}),e[0]=l,e[1]=a):a=e[1];let m;e[2]!==r?(m=r.toLocaleString(),e[2]=r,e[3]=m):m=e[3];let o;e[4]!==m?(o=s.jsx("div",{className:"mt-1 text-2xl font-medium text-foreground tabular-nums",children:m}),e[4]=m,e[5]=o):o=e[5];let c;return e[6]!==a||e[7]!==o?(c=s.jsxs("div",{className:"rounded-lg border border-border p-4",children:[a,o]}),e[6]=a,e[7]=o,e[8]=c):c=e[8],c}function Fe(t){const e=U.c(56),{thread:l,onOpen:r}=t,a=ee(),m=l.status;let o;e[0]!==l.updatedAt?(o=new Date(l.updatedAt).toLocaleString(),e[0]=l.updatedAt,e[1]=o):o=e[1];let c;e[2]!==o?(c=s.jsx(K,{className:"whitespace-nowrap text-sm tabular-nums text-muted-foreground",children:o}),e[2]=o,e[3]=c):c=e[3];let i;e[4]!==l.orgSlug?(i=s.jsx(K,{className:"text-sm",children:l.orgSlug}),e[4]=l.orgSlug,e[5]=i):i=e[5];let u;e[6]!==r||e[7]!==l?(u=()=>r(l),e[6]=r,e[7]=l,e[8]=u):u=e[8];let n;e[9]!==a||e[10]!==l.title?(n=l.title||a("thread.analytics.untitled"),e[9]=a,e[10]=l.title,e[11]=n):n=e[11];let x;e[12]!==u||e[13]!==n?(x=s.jsx("button",{type:"button",onClick:u,className:"block max-w-full truncate text-left text-foreground underline-offset-2 hover:underline",children:n}),e[12]=u,e[13]=n,e[14]=x):x=e[14];let d;e[15]!==l.failureReason||e[16]!==l.lastError||e[17]!==l.status?(d=l.status==="failed"&&(l.lastError||l.failureReason)&&s.jsx("div",{className:"truncate text-xs text-destructive",children:l.lastError??l.failureReason}),e[15]=l.failureReason,e[16]=l.lastError,e[17]=l.status,e[18]=d):d=e[18];let h;e[19]!==x||e[20]!==d?(h=s.jsxs(K,{className:"max-w-sm text-sm",children:[x,d]}),e[19]=x,e[20]=d,e[21]=h):h=e[21];const g=xe[l.kind];let p;e[22]!==a||e[23]!==g?(p=a(g),e[22]=a,e[23]=g,e[24]=p):p=e[24];let w;e[25]!==p?(w=s.jsx(K,{className:"text-sm",children:p}),e[25]=p,e[26]=w):w=e[26];const k=ze[m]??"outline";let j;e[27]!==m||e[28]!==a||e[29]!==l.status?(j=me[m]?a(me[m]):l.status,e[27]=m,e[28]=a,e[29]=l.status,e[30]=j):j=e[30];let T;e[31]!==k||e[32]!==j?(T=s.jsx(K,{children:s.jsx(Ce,{variant:k,children:j})}),e[31]=k,e[32]=j,e[33]=T):T=e[33];const L=l.userEmail??l.userName??"—";let S;e[34]!==L?(S=s.jsx(K,{className:"max-w-48 truncate text-sm",children:L}),e[34]=L,e[35]=S):S=e[35];let y;e[36]!==l.agent?(y=s.jsx(K,{className:"max-w-48 truncate text-sm",children:l.agent}),e[36]=l.agent,e[37]=y):y=e[37];let C;e[38]!==l.usd?(C=l.usd===null?"—":`$${l.usd.toFixed(2)}`,e[38]=l.usd,e[39]=C):C=e[39];let b;e[40]!==C?(b=s.jsx(K,{className:"text-sm tabular-nums",children:C}),e[40]=C,e[41]=b):b=e[41];let v;e[42]!==l.tokens?(v=l.tokens===null?"—":l.tokens.toLocaleString(),e[42]=l.tokens,e[43]=v):v=e[43];let N;e[44]!==v?(N=s.jsx(K,{className:"text-sm tabular-nums",children:v}),e[44]=v,e[45]=N):N=e[45];let _;return e[46]!==w||e[47]!==T||e[48]!==S||e[49]!==y||e[50]!==b||e[51]!==c||e[52]!==N||e[53]!==i||e[54]!==h?(_=s.jsxs(fe,{children:[c,i,h,w,T,S,y,b,N]}),e[46]=w,e[47]=T,e[48]=S,e[49]=y,e[50]=b,e[51]=c,e[52]=N,e[53]=i,e[54]=h,e[55]=_):_=e[55],_}function Ye(t){const e=U.c(51),{org:l}=t,r=ee(),[a,m]=z.useState(Q),[o,c]=z.useState(Q),i=a===Q?void 0:a,u=o===Q?void 0:o;let n;e[0]!==l||e[1]!==i||e[2]!==u?(n={org:l,status:i,kind:u,limit:150},e[0]=l,e[1]=i,e[2]=u,e[3]=n):n=e[3];const x=n,{data:d,isLoading:h,error:g}=Ne(x,!0),[p,w]=z.useState(null);let k;e[4]===Symbol.for("react.memo_cache_sentinel")?(k=s.jsx(oe,{className:"w-[180px]",size:"sm",children:s.jsx(ne,{})}),e[4]=k):k=e[4];let j;e[5]!==r?(j=r("thread.analytics.anyStatus"),e[5]=r,e[6]=j):j=e[6];let T;e[7]!==j?(T=s.jsx(Z,{value:Q,children:j}),e[7]=j,e[8]=T):T=e[8];let L;e[9]!==r?(L=Ke.map(A=>s.jsx(Z,{value:A,children:r(me[A])},A)),e[9]=r,e[10]=L):L=e[10];let S;e[11]!==T||e[12]!==L?(S=s.jsxs(ce,{children:[T,L]}),e[11]=T,e[12]=L,e[13]=S):S=e[13];let y;e[14]!==a||e[15]!==S?(y=s.jsxs(ie,{value:a,onValueChange:m,children:[k,S]}),e[14]=a,e[15]=S,e[16]=y):y=e[16];let C;e[17]===Symbol.for("react.memo_cache_sentinel")?(C=s.jsx(oe,{className:"w-[180px]",size:"sm",children:s.jsx(ne,{})}),e[17]=C):C=e[17];let b;e[18]!==r?(b=r("thread.analytics.anyKind"),e[18]=r,e[19]=b):b=e[19];let v;e[20]!==b?(v=s.jsx(Z,{value:Q,children:b}),e[20]=b,e[21]=v):v=e[21];let N;e[22]!==r?(N=Ue.map(A=>s.jsx(Z,{value:A,children:r(xe[A])},A)),e[22]=r,e[23]=N):N=e[23];let _;e[24]!==v||e[25]!==N?(_=s.jsxs(ce,{children:[v,N]}),e[24]=v,e[25]=N,e[26]=_):_=e[26];let E;e[27]!==o||e[28]!==_?(E=s.jsxs(ie,{value:o,onValueChange:c,children:[C,_]}),e[27]=o,e[28]=_,e[29]=E):E=e[29];let D;e[30]===Symbol.for("react.memo_cache_sentinel")?(D=s.jsx("span",{className:"size-2 rounded-full bg-success"}),e[30]=D):D=e[30];let O;e[31]!==r?(O=r("thread.analytics.liveHint"),e[31]=r,e[32]=O):O=e[32];let R;e[33]!==O?(R=s.jsxs("span",{className:"ml-auto flex items-center gap-2 text-xs text-muted-foreground",children:[D,O]}),e[33]=O,e[34]=R):R=e[34];let I;e[35]!==E||e[36]!==R||e[37]!==y?(I=s.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[y,E,R]}),e[35]=E,e[36]=R,e[37]=y,e[38]=I):I=e[38];let $;e[39]!==d||e[40]!==g||e[41]!==h||e[42]!==r?($=h?s.jsx(de,{}):g?s.jsx(he,{message:g.message}):d?s.jsxs(s.Fragment,{children:[s.jsxs("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-3",children:[s.jsx(ae,{label:r("thread.analytics.countRunning"),value:d.counts.running}),s.jsx(ae,{label:r("thread.analytics.countWaiting"),value:d.counts.waiting}),s.jsx(ae,{label:r("thread.analytics.countFailedHour"),value:d.counts.failedLastHour})]}),d.threads.length===0?s.jsx("div",{className:"rounded-lg border border-border p-8 text-center text-sm text-muted-foreground",children:r("thread.analytics.empty")}):s.jsx("div",{className:"overflow-x-auto rounded-lg border border-border",children:s.jsxs(Ae,{children:[s.jsx(we,{children:s.jsxs(fe,{children:[s.jsx(V,{children:r("thread.analytics.colUpdated")}),s.jsx(V,{children:r("thread.analytics.colOrg")}),s.jsx(V,{children:r("thread.analytics.colChat")}),s.jsx(V,{children:r("thread.analytics.colKind")}),s.jsx(V,{children:r("thread.analytics.colStatus")}),s.jsx(V,{children:r("thread.analytics.colUser")}),s.jsx(V,{children:r("thread.analytics.colAgent")}),s.jsx(V,{children:r("thread.analytics.colCost")}),s.jsx(V,{children:r("thread.analytics.colTokens")})]})}),s.jsx(ke,{children:d.threads.map(A=>s.jsx(Fe,{thread:A,onOpen:w},A.id))})]})})]}):null,e[39]=d,e[40]=g,e[41]=h,e[42]=r,e[43]=$):$=e[43];let P;e[44]===Symbol.for("react.memo_cache_sentinel")?(P=()=>w(null),e[44]=P):P=e[44];let B;e[45]!==p?(B=s.jsx(qe,{thread:p,onClose:P}),e[45]=p,e[46]=B):B=e[46];let H;return e[47]!==I||e[48]!==$||e[49]!==B?(H=s.jsxs("div",{className:"flex flex-col gap-6 py-6",children:[I,$,B]}),e[47]=I,e[48]=$,e[49]=B,e[50]=H):H=e[50],H}function Me(t){const e=U.c(14),{thread:l}=t,{org:r,locator:a}=pe();let m;e[0]!==r.id||e[1]!==r.slug?(m={connectionId:ye,orgId:r.id,orgSlug:r.slug},e[0]=r.id,e[1]=r.slug,e[2]=m):m=e[2];const o=Pe(m),c=Oe(),i=He();let u;e[3]!==l.createdAt||e[4]!==l.id||e[5]!==l.status||e[6]!==l.title?(u={id:l.id,title:l.title,status:l.status,created_at:l.createdAt},e[3]=l.createdAt,e[4]=l.id,e[5]=l.status,e[6]=l.title,e[7]=u):u=e[7];let n;return e[8]!==o||e[9]!==c||e[10]!==a||e[11]!==u||e[12]!==i?(n=s.jsx(De,{thread:u,client:o,locator:a,connections:c,virtualMcps:i,members:void 0,meta:!1}),e[8]=o,e[9]=c,e[10]=a,e[11]=u,e[12]=i,e[13]=n):n=e[13],n}function qe(t){const e=U.c(12),{thread:l,onClose:r}=t,a=ee(),{project:m}=pe(),o=!!l;let c;e[0]!==r?(c=x=>!x&&r(),e[0]=r,e[1]=c):c=e[1];let i;e[2]!==m||e[3]!==a||e[4]!==l?(i=l&&s.jsx(Se,{org:{id:l.orgId,name:l.orgSlug,slug:l.orgSlug,logo:null},project:m,children:s.jsx(z.Suspense,{fallback:s.jsx(Re,{className:"shrink-0 border-b border-border px-5 pb-5 pt-6 md:px-6",children:s.jsx(Ie,{className:"truncate text-sm leading-snug",children:l.title||a("thread.analytics.untitled")})}),children:s.jsx(Me,{thread:l})})}),e[2]=m,e[3]=a,e[4]=l,e[5]=i):i=e[5];let u;e[6]!==i?(u=s.jsx($e,{className:"flex flex-col gap-0 p-0 sm:max-w-2xl",children:i}),e[6]=i,e[7]=u):u=e[7];let n;return e[8]!==o||e[9]!==c||e[10]!==u?(n=s.jsx(Be,{open:o,onOpenChange:c,children:u}),e[8]=o,e[9]=c,e[10]=u,e[11]=n):n=e[11],n}function ue(t){const e=U.c(16),{tool:l,org:r,from:a,to:m}=t,o=ee();let c;e[0]!==a||e[1]!==r||e[2]!==m?(c={org:r,from:a,to:m},e[0]=a,e[1]=r,e[2]=m,e[3]=c):c=e[3];const{data:i,isLoading:u,error:n}=Te(l,c);if(u){let p;return e[4]===Symbol.for("react.memo_cache_sentinel")?(p=s.jsx(de,{}),e[4]=p):p=e[4],p}if(n){let p;return e[5]!==n.message?(p=s.jsx(he,{message:n.message}),e[5]=n.message,e[6]=p):p=e[6],p}if(!i)return null;let x;e[7]!==i.sections?(x=i.sections.map(Ge),e[7]=i.sections,e[8]=x):x=e[8];let d;e[9]!==o?(d=o("thread.analytics.costFootnote"),e[9]=o,e[10]=d):d=e[10];let h;e[11]!==d?(h=s.jsx("p",{className:"text-xs text-muted-foreground",children:d}),e[11]=d,e[12]=h):h=e[12];let g;return e[13]!==x||e[14]!==h?(g=s.jsxs("div",{className:"flex flex-col gap-8 py-6",children:[x,h]}),e[13]=x,e[14]=h,e[15]=g):g=e[15],g}function Ge(t){return s.jsx(be,{section:t,threadLinks:!0},t.title)}function ol(){const t=U.c(99),e=ee(),l=ge({strict:!1}).org??"",r=ve(),[a,m]=z.useState("all"),[o,c]=z.useState(7),[i,u]=z.useState("live"),[n]=z.useState(Xe);let x;t[0]!==n?(x=new Date(n).toISOString(),t[0]=n,t[1]=x):x=t[1];const d=x;let h;t[2]!==o||t[3]!==n?(h=new Date(n-o*864e5).toISOString(),t[2]=o,t[3]=n,t[4]=h):h=t[4];const g=h;if(r.isLoading){let f;return t[5]===Symbol.for("react.memo_cache_sentinel")?(f=s.jsx(se.Content,{children:s.jsx(de,{})}),t[5]=f):f=t[5],f}if(!r.data?.isAdmin){let f;t[6]!==e?(f=e("thread.analytics.notAdmin"),t[6]=e,t[7]=f):f=t[7];let J;return t[8]!==f?(J=s.jsx(se.Content,{children:s.jsx("div",{className:"p-8 text-center text-sm text-muted-foreground",children:f})}),t[8]=f,t[9]=J):J=t[9],J}let p;t[10]!==e?(p=e("taskBoard.analytics.orgAll"),t[10]=e,t[11]=p):p=t[11];let w;t[12]!==p?(w={value:"all",label:p},t[12]=p,t[13]=w):w=t[13];let k;t[14]!==e?(k=e("taskBoard.analytics.orgCurrent"),t[14]=e,t[15]=k):k=t[15];let j;t[16]!==l||t[17]!==k?(j={value:l,label:k},t[16]=l,t[17]=k,t[18]=j):j=t[18];let T;if(t[19]!==r.data.orgs||t[20]!==l||t[21]!==w||t[22]!==j){let f;t[24]!==l?(f=J=>J.slug!==l,t[24]=l,t[25]=f):f=t[25],T=[w,j,...r.data.orgs.filter(f).map(We)],t[19]=r.data.orgs,t[20]=l,t[21]=w,t[22]=j,t[23]=T}else T=t[23];const L=T;let S;t[26]!==e?(S=e("thread.analytics.title"),t[26]=e,t[27]=S):S=t[27];let y;t[28]!==S?(y=s.jsx("h1",{className:"text-xl font-medium text-foreground",children:S}),t[28]=S,t[29]=y):y=t[29];let C;t[30]!==e?(C=e("taskBoard.analytics.orgSearch"),t[30]=e,t[31]=C):C=t[31];let b;t[32]!==e?(b=e("taskBoard.analytics.orgEmpty"),t[32]=e,t[33]=b):b=t[33];let v;t[34]!==a||t[35]!==L||t[36]!==b||t[37]!==C?(v=s.jsx(_e,{options:L,value:a,onChange:m,width:"w-[240px]",searchPlaceholder:C,emptyMessage:b}),t[34]=a,t[35]=L,t[36]=b,t[37]=C,t[38]=v):v=t[38];let N;t[39]!==o||t[40]!==e||t[41]!==i?(N=i!=="live"&&s.jsxs(ie,{value:String(o),onValueChange:f=>c(Number(f)),children:[s.jsx(oe,{className:"w-[140px]",size:"sm",children:s.jsx(ne,{})}),s.jsx(ce,{children:Ve.map(f=>s.jsx(Z,{value:String(f),children:e("taskBoard.analytics.rangeDays",{days:String(f)})},f))})]}),t[39]=o,t[40]=e,t[41]=i,t[42]=N):N=t[42];let _;t[43]!==v||t[44]!==N?(_=s.jsxs("div",{className:"ml-auto flex items-center gap-2",children:[v,N]}),t[43]=v,t[44]=N,t[45]=_):_=t[45];let E;t[46]!==_||t[47]!==y?(E=s.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[y,_]}),t[46]=_,t[47]=y,t[48]=E):E=t[48];let D;t[49]!==a||t[50]!==l||t[51]!==e?(D=a!==l&&s.jsx("div",{className:"rounded-lg bg-warning/10 px-3 py-2 text-sm text-warning",children:a==="all"?e("taskBoard.analytics.bannerAll"):e("taskBoard.analytics.bannerOrg",{org:a})}),t[49]=a,t[50]=l,t[51]=e,t[52]=D):D=t[52];let O;t[53]===Symbol.for("react.memo_cache_sentinel")?(O=f=>u(f),t[53]=O):O=t[53];let R;t[54]!==e?(R=e("thread.analytics.tabLive"),t[54]=e,t[55]=R):R=t[55];let I;t[56]!==R?(I=s.jsx(le,{value:"live",children:R}),t[56]=R,t[57]=I):I=t[57];let $;t[58]!==e?($=e("thread.analytics.tabUsage"),t[58]=e,t[59]=$):$=t[59];let P;t[60]!==$?(P=s.jsx(le,{value:"usage",children:$}),t[60]=$,t[61]=P):P=t[61];let B;t[62]!==e?(B=e("thread.analytics.tabErrors"),t[62]=e,t[63]=B):B=t[63];let H;t[64]!==B?(H=s.jsx(le,{value:"errors",children:B}),t[64]=B,t[65]=H):H=t[65];let A;t[66]!==I||t[67]!==P||t[68]!==H?(A=s.jsxs(Le,{children:[I,P,H]}),t[66]=I,t[67]=P,t[68]=H,t[69]=A):A=t[69];let F;t[70]!==a||t[71]!==i?(F=i==="live"&&s.jsx(Ye,{org:a}),t[70]=a,t[71]=i,t[72]=F):F=t[72];let Y;t[73]!==F?(Y=s.jsx(re,{value:"live",children:F}),t[73]=F,t[74]=Y):Y=t[74];let M;t[75]!==g||t[76]!==a||t[77]!==i||t[78]!==d?(M=i==="usage"&&s.jsx(ue,{tool:"THREAD_ANALYTICS_USAGE",org:a,from:g,to:d}),t[75]=g,t[76]=a,t[77]=i,t[78]=d,t[79]=M):M=t[79];let q;t[80]!==M?(q=s.jsx(re,{value:"usage",children:M}),t[80]=M,t[81]=q):q=t[81];let G;t[82]!==g||t[83]!==a||t[84]!==i||t[85]!==d?(G=i==="errors"&&s.jsx(ue,{tool:"THREAD_ANALYTICS_ERRORS",org:a,from:g,to:d}),t[82]=g,t[83]=a,t[84]=i,t[85]=d,t[86]=G):G=t[86];let W;t[87]!==G?(W=s.jsx(re,{value:"errors",children:G}),t[87]=G,t[88]=W):W=t[88];let X;t[89]!==A||t[90]!==Y||t[91]!==q||t[92]!==W||t[93]!==i?(X=s.jsxs(Ee,{value:i,onValueChange:O,children:[A,Y,q,W]}),t[89]=A,t[90]=Y,t[91]=q,t[92]=W,t[93]=i,t[94]=X):X=t[94];let te;return t[95]!==E||t[96]!==D||t[97]!==X?(te=s.jsx(se.Content,{children:s.jsx("div",{className:"flex h-full min-h-0 flex-col overflow-auto",children:s.jsxs("div",{className:"mx-auto flex w-full max-w-[1680px] flex-col gap-4 px-4 py-6 sm:px-8 sm:py-8",children:[E,D,X]})})}),t[95]=E,t[96]=D,t[97]=X,t[98]=te):te=t[98],te}function We(t){return{value:t.slug,label:`${t.slug} · ${t.name}`}}function Xe(){return Date.now()}export{ol as default};
1
+ import{c as U,b as ee,f as ge,r as z,j as s,h as je,X as pe,c2 as Se,z as ye}from"./index-Bo0F7TR2.js";import{C as se}from"./index-SNhzEDgK.js";import{S as be}from"./analytics-sections-B-DAxD5H.js";import{u as ve,a as Ne,b as Te}from"./use-thread-analytics-B_SQZb1Z.js";import{B as Ce}from"./badge-DsCXhAux.js";import{C as _e}from"./combobox-DMurdTGm.js";import{S as ie,b as oe,a as ne,d as ce,c as Z}from"./select-B29Xhi6X.js";import{e as Ae,a as we,b as fe,T as V,d as ke,c as K}from"./table-BFhRn6m5.js";import{T as le,a as Le,c as re,b as Ee}from"./tabs-Bq5-PfFl.js";import{c as Re,S as Ie,a as $e,b as Be}from"./sheet-Ds43gFnt.js";import{T as De}from"./thread-sheet-body-DMUuynmz.js";import{u as Oe}from"./use-connection-x5NSsBTY.js";import{u as Pe}from"./use-mcp-client-CgAwsTXX.js";import{b as He}from"./repository-binding-BGULsexx.js";import"./use-mobile-BTzo-yNE.js";import"./thread-button-C7RONiC_.js";import"./agent-icon-DIz0uejY.js";import"./AlertCircle-RWTRMbKB.js";import"./Tool01-CQE4YIlY.js";import"./ArrowUp-CdkBKRTp.js";import"./ArrowLeft-B0Qy6MPA.js";import"./ArrowRight-1ZRv0qj4.js";import"./ShoppingBag01-eap5At3d.js";import"./ZoomOut-CacJRCxL.js";import"./Palette-Bowo13XO.js";import"./CheckCircle-C2FTUn3P.js";import"./Check-B08g8hfv.js";import"./ChevronUp-C43CLLe7.js";import"./UserSquare-OqUaFYcL.js";import"./Copy01-BFGk4HTi.js";import"./CreditCard01-D1x66FDR.js";import"./DotsVertical-D5Nqj0bW.js";import"./Image01-C3rMiZ72.js";import"./XClose-C_pErei1.js";import"./Key01-DJx3H4Mk.js";import"./Link01-DpMZQMbW.js";import"./LinkExternal01-Hrpy2rKU.js";import"./Monitor01-CHeJ4cBZ.js";import"./Sun-CQdyCDq1.js";import"./Plus-g-qUeP-5.js";import"./SearchMd-Bu5ZPloJ.js";import"./Trash01-ttayP08D.js";import"./Upload01-CxxYSCYc.js";import"./User01-gfze9rr9.js";import"./Users01-CrUbTlAS.js";import"./X-DmQciAIn.js";import"./use-chat-layout-state-BWgbiPAM.js";import"./thread-route-X4GbG7FV.js";import"./use-panel-navigate-EwAAwlcx.js";import"./use-project-scope-BQkBdDIR.js";import"./thread-intent-J3vN5Vs_.js";import"./backoff-8mStPHYB.js";import"./task-board-C6pPuzYa.js";import"./schema-CJ-VqkAD.js";import"./slugify-CEUa2lfQ.js";import"./tooltip-CbYF5mhk.js";import"./index-NYSezzil.js";import"./toolbar-icon-button-BtgLueB7.js";import"./shell-layout-DTPbTm7i.js";import"./avatar-DnHqCpqr.js";import"./download-app-dialog-IVAbk28w.js";import"./dialog-5o2urGn5.js";import"./command-BDRqfDOz.js";import"./index-CSFjWyPp.js";import"./integration-icon-ChmmjcAp.js";import"./project-icon-BE7eT2UX.js";import"./new-project-dialog-CmsEVtp0.js";import"./input-Bg2anvwf.js";import"./label-CuQBcvRg.js";import"./repository-import-picker-Blpga-5j.js";import"./use-navigate-to-agent-CUailOkl.js";import"./repository-picker-B8Yoh_bh.js";import"./useInfiniteQuery-BUmcOy3_.js";import"./infiniteQueryObserver-CJ3Kym5O.js";import"./collection-search-Ch2FLY2_.js";import"./use-debounced-value-ClYZnycZ.js";import"./use-organization-settings-C-0W-ky3.js";import"./use-is-desktop-app-BNujXJc_.js";import"./required-auth-layout-DJxAIvUt.js";import"./autosend-CmBucBqr.js";import"./use-org-sso-C9wS7ZE_.js";import"./resizable-DT-ha9BR.js";import"./chart-CR5bi_LF.js";import"./index-Bencuqrd.js";import"./CartesianChart-DxxWBH9Y.js";import"./Line-U3trYLWi.js";import"./ErrorBarContext-Bka8_hCU.js";import"./Sector-CoFH2hT0.js";import"./XAxis-CXI1Q_NM.js";import"./popover-a7N6zy94.js";import"./useSuspenseInfiniteQuery-BBD5zNHU.js";import"./pair-BCvCT-GT.js";import"./format-time-CjIPQhCN.js";import"./differenceInSeconds-C3x8sHUj.js";import"./collapsible-cP4qew3h.js";import"./use-copy-BfHUaImm.js";import"./usage-stats-Bd-A9GxK.js";import"./markdown-ByHIpwAl.js";import"./org-file-open-context-A6PAiYSr.js";import"./use-decopilot-events-Bz4QYcmu.js";import"./chat-context-BUNOOLZ7.js";import"./use-ai-providers-C99u_E8Y.js";import"./location-DBePU4bz.js";import"./content-blocks-o63cs2vh.js";import"./mcp-app-renderer-C0Zh7icj.js";import"./types-ByzlXSpq.js";import"./omit-sandbox-map-jj4lCB2U.js";import"./gateway-client-DGz23Vlr.js";import"./tool-namespace-DmnQIdtF.js";import"./utils-CVEq3hMx.js";import"./use-mcp-prompts-BIwfN9eR.js";import"./index-BNVSW_Xa.js";import"./form-CparX5oE.js";import"./use-thread-outputs-CKvUbe8p.js";import"./file-type-icon-ChEWF5Jy.js";import"./use-infinite-scroll-B8GLgbd5.js";import"./task-status-D3QqYPID.js";import"./auth-DATmrrln.js";const Ve=[1,7,30,90],Ke=["in_progress","requires_action","failed","completed"],Ue=["chat","automation","task"],Q="any",me={in_progress:"thread.analytics.statusRunning",requires_action:"thread.analytics.statusWaiting",failed:"thread.analytics.statusFailed",completed:"thread.analytics.statusCompleted"},xe={chat:"thread.analytics.kindChat",automation:"thread.analytics.kindAutomation",task:"thread.analytics.kindTask"},ze={in_progress:"default",requires_action:"warning",failed:"destructive",completed:"secondary"};function de(){const t=U.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx("div",{className:"flex justify-center py-12",children:s.jsx(je,{className:"size-5 text-muted-foreground"})}),t[0]=e):e=t[0],e}function he(t){const e=U.c(2),{message:l}=t;let r;return e[0]!==l?(r=s.jsx("div",{className:"rounded-lg border border-border p-8 text-center text-sm text-destructive",children:l}),e[0]=l,e[1]=r):r=e[1],r}function ae(t){const e=U.c(9),{label:l,value:r}=t;let a;e[0]!==l?(a=s.jsx("div",{className:"text-sm text-muted-foreground",children:l}),e[0]=l,e[1]=a):a=e[1];let m;e[2]!==r?(m=r.toLocaleString(),e[2]=r,e[3]=m):m=e[3];let o;e[4]!==m?(o=s.jsx("div",{className:"mt-1 text-2xl font-medium text-foreground tabular-nums",children:m}),e[4]=m,e[5]=o):o=e[5];let c;return e[6]!==a||e[7]!==o?(c=s.jsxs("div",{className:"rounded-lg border border-border p-4",children:[a,o]}),e[6]=a,e[7]=o,e[8]=c):c=e[8],c}function Fe(t){const e=U.c(56),{thread:l,onOpen:r}=t,a=ee(),m=l.status;let o;e[0]!==l.updatedAt?(o=new Date(l.updatedAt).toLocaleString(),e[0]=l.updatedAt,e[1]=o):o=e[1];let c;e[2]!==o?(c=s.jsx(K,{className:"whitespace-nowrap text-sm tabular-nums text-muted-foreground",children:o}),e[2]=o,e[3]=c):c=e[3];let i;e[4]!==l.orgSlug?(i=s.jsx(K,{className:"text-sm",children:l.orgSlug}),e[4]=l.orgSlug,e[5]=i):i=e[5];let u;e[6]!==r||e[7]!==l?(u=()=>r(l),e[6]=r,e[7]=l,e[8]=u):u=e[8];let n;e[9]!==a||e[10]!==l.title?(n=l.title||a("thread.analytics.untitled"),e[9]=a,e[10]=l.title,e[11]=n):n=e[11];let x;e[12]!==u||e[13]!==n?(x=s.jsx("button",{type:"button",onClick:u,className:"block max-w-full truncate text-left text-foreground underline-offset-2 hover:underline",children:n}),e[12]=u,e[13]=n,e[14]=x):x=e[14];let d;e[15]!==l.failureReason||e[16]!==l.lastError||e[17]!==l.status?(d=l.status==="failed"&&(l.lastError||l.failureReason)&&s.jsx("div",{className:"truncate text-xs text-destructive",children:l.lastError??l.failureReason}),e[15]=l.failureReason,e[16]=l.lastError,e[17]=l.status,e[18]=d):d=e[18];let h;e[19]!==x||e[20]!==d?(h=s.jsxs(K,{className:"max-w-sm text-sm",children:[x,d]}),e[19]=x,e[20]=d,e[21]=h):h=e[21];const g=xe[l.kind];let p;e[22]!==a||e[23]!==g?(p=a(g),e[22]=a,e[23]=g,e[24]=p):p=e[24];let w;e[25]!==p?(w=s.jsx(K,{className:"text-sm",children:p}),e[25]=p,e[26]=w):w=e[26];const k=ze[m]??"outline";let j;e[27]!==m||e[28]!==a||e[29]!==l.status?(j=me[m]?a(me[m]):l.status,e[27]=m,e[28]=a,e[29]=l.status,e[30]=j):j=e[30];let T;e[31]!==k||e[32]!==j?(T=s.jsx(K,{children:s.jsx(Ce,{variant:k,children:j})}),e[31]=k,e[32]=j,e[33]=T):T=e[33];const L=l.userEmail??l.userName??"—";let S;e[34]!==L?(S=s.jsx(K,{className:"max-w-48 truncate text-sm",children:L}),e[34]=L,e[35]=S):S=e[35];let y;e[36]!==l.agent?(y=s.jsx(K,{className:"max-w-48 truncate text-sm",children:l.agent}),e[36]=l.agent,e[37]=y):y=e[37];let C;e[38]!==l.usd?(C=l.usd===null?"—":`$${l.usd.toFixed(2)}`,e[38]=l.usd,e[39]=C):C=e[39];let b;e[40]!==C?(b=s.jsx(K,{className:"text-sm tabular-nums",children:C}),e[40]=C,e[41]=b):b=e[41];let v;e[42]!==l.tokens?(v=l.tokens===null?"—":l.tokens.toLocaleString(),e[42]=l.tokens,e[43]=v):v=e[43];let N;e[44]!==v?(N=s.jsx(K,{className:"text-sm tabular-nums",children:v}),e[44]=v,e[45]=N):N=e[45];let _;return e[46]!==w||e[47]!==T||e[48]!==S||e[49]!==y||e[50]!==b||e[51]!==c||e[52]!==N||e[53]!==i||e[54]!==h?(_=s.jsxs(fe,{children:[c,i,h,w,T,S,y,b,N]}),e[46]=w,e[47]=T,e[48]=S,e[49]=y,e[50]=b,e[51]=c,e[52]=N,e[53]=i,e[54]=h,e[55]=_):_=e[55],_}function Ye(t){const e=U.c(51),{org:l}=t,r=ee(),[a,m]=z.useState(Q),[o,c]=z.useState(Q),i=a===Q?void 0:a,u=o===Q?void 0:o;let n;e[0]!==l||e[1]!==i||e[2]!==u?(n={org:l,status:i,kind:u,limit:150},e[0]=l,e[1]=i,e[2]=u,e[3]=n):n=e[3];const x=n,{data:d,isLoading:h,error:g}=Ne(x,!0),[p,w]=z.useState(null);let k;e[4]===Symbol.for("react.memo_cache_sentinel")?(k=s.jsx(oe,{className:"w-[180px]",size:"sm",children:s.jsx(ne,{})}),e[4]=k):k=e[4];let j;e[5]!==r?(j=r("thread.analytics.anyStatus"),e[5]=r,e[6]=j):j=e[6];let T;e[7]!==j?(T=s.jsx(Z,{value:Q,children:j}),e[7]=j,e[8]=T):T=e[8];let L;e[9]!==r?(L=Ke.map(A=>s.jsx(Z,{value:A,children:r(me[A])},A)),e[9]=r,e[10]=L):L=e[10];let S;e[11]!==T||e[12]!==L?(S=s.jsxs(ce,{children:[T,L]}),e[11]=T,e[12]=L,e[13]=S):S=e[13];let y;e[14]!==a||e[15]!==S?(y=s.jsxs(ie,{value:a,onValueChange:m,children:[k,S]}),e[14]=a,e[15]=S,e[16]=y):y=e[16];let C;e[17]===Symbol.for("react.memo_cache_sentinel")?(C=s.jsx(oe,{className:"w-[180px]",size:"sm",children:s.jsx(ne,{})}),e[17]=C):C=e[17];let b;e[18]!==r?(b=r("thread.analytics.anyKind"),e[18]=r,e[19]=b):b=e[19];let v;e[20]!==b?(v=s.jsx(Z,{value:Q,children:b}),e[20]=b,e[21]=v):v=e[21];let N;e[22]!==r?(N=Ue.map(A=>s.jsx(Z,{value:A,children:r(xe[A])},A)),e[22]=r,e[23]=N):N=e[23];let _;e[24]!==v||e[25]!==N?(_=s.jsxs(ce,{children:[v,N]}),e[24]=v,e[25]=N,e[26]=_):_=e[26];let E;e[27]!==o||e[28]!==_?(E=s.jsxs(ie,{value:o,onValueChange:c,children:[C,_]}),e[27]=o,e[28]=_,e[29]=E):E=e[29];let D;e[30]===Symbol.for("react.memo_cache_sentinel")?(D=s.jsx("span",{className:"size-2 rounded-full bg-success"}),e[30]=D):D=e[30];let O;e[31]!==r?(O=r("thread.analytics.liveHint"),e[31]=r,e[32]=O):O=e[32];let R;e[33]!==O?(R=s.jsxs("span",{className:"ml-auto flex items-center gap-2 text-xs text-muted-foreground",children:[D,O]}),e[33]=O,e[34]=R):R=e[34];let I;e[35]!==E||e[36]!==R||e[37]!==y?(I=s.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[y,E,R]}),e[35]=E,e[36]=R,e[37]=y,e[38]=I):I=e[38];let $;e[39]!==d||e[40]!==g||e[41]!==h||e[42]!==r?($=h?s.jsx(de,{}):g?s.jsx(he,{message:g.message}):d?s.jsxs(s.Fragment,{children:[s.jsxs("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-3",children:[s.jsx(ae,{label:r("thread.analytics.countRunning"),value:d.counts.running}),s.jsx(ae,{label:r("thread.analytics.countWaiting"),value:d.counts.waiting}),s.jsx(ae,{label:r("thread.analytics.countFailedHour"),value:d.counts.failedLastHour})]}),d.threads.length===0?s.jsx("div",{className:"rounded-lg border border-border p-8 text-center text-sm text-muted-foreground",children:r("thread.analytics.empty")}):s.jsx("div",{className:"overflow-x-auto rounded-lg border border-border",children:s.jsxs(Ae,{children:[s.jsx(we,{children:s.jsxs(fe,{children:[s.jsx(V,{children:r("thread.analytics.colUpdated")}),s.jsx(V,{children:r("thread.analytics.colOrg")}),s.jsx(V,{children:r("thread.analytics.colChat")}),s.jsx(V,{children:r("thread.analytics.colKind")}),s.jsx(V,{children:r("thread.analytics.colStatus")}),s.jsx(V,{children:r("thread.analytics.colUser")}),s.jsx(V,{children:r("thread.analytics.colAgent")}),s.jsx(V,{children:r("thread.analytics.colCost")}),s.jsx(V,{children:r("thread.analytics.colTokens")})]})}),s.jsx(ke,{children:d.threads.map(A=>s.jsx(Fe,{thread:A,onOpen:w},A.id))})]})})]}):null,e[39]=d,e[40]=g,e[41]=h,e[42]=r,e[43]=$):$=e[43];let P;e[44]===Symbol.for("react.memo_cache_sentinel")?(P=()=>w(null),e[44]=P):P=e[44];let B;e[45]!==p?(B=s.jsx(qe,{thread:p,onClose:P}),e[45]=p,e[46]=B):B=e[46];let H;return e[47]!==I||e[48]!==$||e[49]!==B?(H=s.jsxs("div",{className:"flex flex-col gap-6 py-6",children:[I,$,B]}),e[47]=I,e[48]=$,e[49]=B,e[50]=H):H=e[50],H}function Me(t){const e=U.c(14),{thread:l}=t,{org:r,locator:a}=pe();let m;e[0]!==r.id||e[1]!==r.slug?(m={connectionId:ye,orgId:r.id,orgSlug:r.slug},e[0]=r.id,e[1]=r.slug,e[2]=m):m=e[2];const o=Pe(m),c=Oe(),i=He();let u;e[3]!==l.createdAt||e[4]!==l.id||e[5]!==l.status||e[6]!==l.title?(u={id:l.id,title:l.title,status:l.status,created_at:l.createdAt},e[3]=l.createdAt,e[4]=l.id,e[5]=l.status,e[6]=l.title,e[7]=u):u=e[7];let n;return e[8]!==o||e[9]!==c||e[10]!==a||e[11]!==u||e[12]!==i?(n=s.jsx(De,{thread:u,client:o,locator:a,connections:c,virtualMcps:i,members:void 0,meta:!1}),e[8]=o,e[9]=c,e[10]=a,e[11]=u,e[12]=i,e[13]=n):n=e[13],n}function qe(t){const e=U.c(12),{thread:l,onClose:r}=t,a=ee(),{project:m}=pe(),o=!!l;let c;e[0]!==r?(c=x=>!x&&r(),e[0]=r,e[1]=c):c=e[1];let i;e[2]!==m||e[3]!==a||e[4]!==l?(i=l&&s.jsx(Se,{org:{id:l.orgId,name:l.orgSlug,slug:l.orgSlug,logo:null},project:m,children:s.jsx(z.Suspense,{fallback:s.jsx(Re,{className:"shrink-0 border-b border-border px-5 pb-5 pt-6 md:px-6",children:s.jsx(Ie,{className:"truncate text-sm leading-snug",children:l.title||a("thread.analytics.untitled")})}),children:s.jsx(Me,{thread:l})})}),e[2]=m,e[3]=a,e[4]=l,e[5]=i):i=e[5];let u;e[6]!==i?(u=s.jsx($e,{className:"flex flex-col gap-0 p-0 sm:max-w-2xl",children:i}),e[6]=i,e[7]=u):u=e[7];let n;return e[8]!==o||e[9]!==c||e[10]!==u?(n=s.jsx(Be,{open:o,onOpenChange:c,children:u}),e[8]=o,e[9]=c,e[10]=u,e[11]=n):n=e[11],n}function ue(t){const e=U.c(16),{tool:l,org:r,from:a,to:m}=t,o=ee();let c;e[0]!==a||e[1]!==r||e[2]!==m?(c={org:r,from:a,to:m},e[0]=a,e[1]=r,e[2]=m,e[3]=c):c=e[3];const{data:i,isLoading:u,error:n}=Te(l,c);if(u){let p;return e[4]===Symbol.for("react.memo_cache_sentinel")?(p=s.jsx(de,{}),e[4]=p):p=e[4],p}if(n){let p;return e[5]!==n.message?(p=s.jsx(he,{message:n.message}),e[5]=n.message,e[6]=p):p=e[6],p}if(!i)return null;let x;e[7]!==i.sections?(x=i.sections.map(Ge),e[7]=i.sections,e[8]=x):x=e[8];let d;e[9]!==o?(d=o("thread.analytics.costFootnote"),e[9]=o,e[10]=d):d=e[10];let h;e[11]!==d?(h=s.jsx("p",{className:"text-xs text-muted-foreground",children:d}),e[11]=d,e[12]=h):h=e[12];let g;return e[13]!==x||e[14]!==h?(g=s.jsxs("div",{className:"flex flex-col gap-8 py-6",children:[x,h]}),e[13]=x,e[14]=h,e[15]=g):g=e[15],g}function Ge(t){return s.jsx(be,{section:t,threadLinks:!0},t.title)}function ol(){const t=U.c(99),e=ee(),l=ge({strict:!1}).org??"",r=ve(),[a,m]=z.useState("all"),[o,c]=z.useState(7),[i,u]=z.useState("live"),[n]=z.useState(Xe);let x;t[0]!==n?(x=new Date(n).toISOString(),t[0]=n,t[1]=x):x=t[1];const d=x;let h;t[2]!==o||t[3]!==n?(h=new Date(n-o*864e5).toISOString(),t[2]=o,t[3]=n,t[4]=h):h=t[4];const g=h;if(r.isLoading){let f;return t[5]===Symbol.for("react.memo_cache_sentinel")?(f=s.jsx(se.Content,{children:s.jsx(de,{})}),t[5]=f):f=t[5],f}if(!r.data?.isAdmin){let f;t[6]!==e?(f=e("thread.analytics.notAdmin"),t[6]=e,t[7]=f):f=t[7];let J;return t[8]!==f?(J=s.jsx(se.Content,{children:s.jsx("div",{className:"p-8 text-center text-sm text-muted-foreground",children:f})}),t[8]=f,t[9]=J):J=t[9],J}let p;t[10]!==e?(p=e("taskBoard.analytics.orgAll"),t[10]=e,t[11]=p):p=t[11];let w;t[12]!==p?(w={value:"all",label:p},t[12]=p,t[13]=w):w=t[13];let k;t[14]!==e?(k=e("taskBoard.analytics.orgCurrent"),t[14]=e,t[15]=k):k=t[15];let j;t[16]!==l||t[17]!==k?(j={value:l,label:k},t[16]=l,t[17]=k,t[18]=j):j=t[18];let T;if(t[19]!==r.data.orgs||t[20]!==l||t[21]!==w||t[22]!==j){let f;t[24]!==l?(f=J=>J.slug!==l,t[24]=l,t[25]=f):f=t[25],T=[w,j,...r.data.orgs.filter(f).map(We)],t[19]=r.data.orgs,t[20]=l,t[21]=w,t[22]=j,t[23]=T}else T=t[23];const L=T;let S;t[26]!==e?(S=e("thread.analytics.title"),t[26]=e,t[27]=S):S=t[27];let y;t[28]!==S?(y=s.jsx("h1",{className:"text-xl font-medium text-foreground",children:S}),t[28]=S,t[29]=y):y=t[29];let C;t[30]!==e?(C=e("taskBoard.analytics.orgSearch"),t[30]=e,t[31]=C):C=t[31];let b;t[32]!==e?(b=e("taskBoard.analytics.orgEmpty"),t[32]=e,t[33]=b):b=t[33];let v;t[34]!==a||t[35]!==L||t[36]!==b||t[37]!==C?(v=s.jsx(_e,{options:L,value:a,onChange:m,width:"w-[240px]",searchPlaceholder:C,emptyMessage:b}),t[34]=a,t[35]=L,t[36]=b,t[37]=C,t[38]=v):v=t[38];let N;t[39]!==o||t[40]!==e||t[41]!==i?(N=i!=="live"&&s.jsxs(ie,{value:String(o),onValueChange:f=>c(Number(f)),children:[s.jsx(oe,{className:"w-[140px]",size:"sm",children:s.jsx(ne,{})}),s.jsx(ce,{children:Ve.map(f=>s.jsx(Z,{value:String(f),children:e("taskBoard.analytics.rangeDays",{days:String(f)})},f))})]}),t[39]=o,t[40]=e,t[41]=i,t[42]=N):N=t[42];let _;t[43]!==v||t[44]!==N?(_=s.jsxs("div",{className:"ml-auto flex items-center gap-2",children:[v,N]}),t[43]=v,t[44]=N,t[45]=_):_=t[45];let E;t[46]!==_||t[47]!==y?(E=s.jsxs("div",{className:"flex flex-wrap items-center gap-2",children:[y,_]}),t[46]=_,t[47]=y,t[48]=E):E=t[48];let D;t[49]!==a||t[50]!==l||t[51]!==e?(D=a!==l&&s.jsx("div",{className:"rounded-lg bg-warning/10 px-3 py-2 text-sm text-warning",children:a==="all"?e("taskBoard.analytics.bannerAll"):e("taskBoard.analytics.bannerOrg",{org:a})}),t[49]=a,t[50]=l,t[51]=e,t[52]=D):D=t[52];let O;t[53]===Symbol.for("react.memo_cache_sentinel")?(O=f=>u(f),t[53]=O):O=t[53];let R;t[54]!==e?(R=e("thread.analytics.tabLive"),t[54]=e,t[55]=R):R=t[55];let I;t[56]!==R?(I=s.jsx(le,{value:"live",children:R}),t[56]=R,t[57]=I):I=t[57];let $;t[58]!==e?($=e("thread.analytics.tabUsage"),t[58]=e,t[59]=$):$=t[59];let P;t[60]!==$?(P=s.jsx(le,{value:"usage",children:$}),t[60]=$,t[61]=P):P=t[61];let B;t[62]!==e?(B=e("thread.analytics.tabErrors"),t[62]=e,t[63]=B):B=t[63];let H;t[64]!==B?(H=s.jsx(le,{value:"errors",children:B}),t[64]=B,t[65]=H):H=t[65];let A;t[66]!==I||t[67]!==P||t[68]!==H?(A=s.jsxs(Le,{children:[I,P,H]}),t[66]=I,t[67]=P,t[68]=H,t[69]=A):A=t[69];let F;t[70]!==a||t[71]!==i?(F=i==="live"&&s.jsx(Ye,{org:a}),t[70]=a,t[71]=i,t[72]=F):F=t[72];let Y;t[73]!==F?(Y=s.jsx(re,{value:"live",children:F}),t[73]=F,t[74]=Y):Y=t[74];let M;t[75]!==g||t[76]!==a||t[77]!==i||t[78]!==d?(M=i==="usage"&&s.jsx(ue,{tool:"THREAD_ANALYTICS_USAGE",org:a,from:g,to:d}),t[75]=g,t[76]=a,t[77]=i,t[78]=d,t[79]=M):M=t[79];let q;t[80]!==M?(q=s.jsx(re,{value:"usage",children:M}),t[80]=M,t[81]=q):q=t[81];let G;t[82]!==g||t[83]!==a||t[84]!==i||t[85]!==d?(G=i==="errors"&&s.jsx(ue,{tool:"THREAD_ANALYTICS_ERRORS",org:a,from:g,to:d}),t[82]=g,t[83]=a,t[84]=i,t[85]=d,t[86]=G):G=t[86];let W;t[87]!==G?(W=s.jsx(re,{value:"errors",children:G}),t[87]=G,t[88]=W):W=t[88];let X;t[89]!==A||t[90]!==Y||t[91]!==q||t[92]!==W||t[93]!==i?(X=s.jsxs(Ee,{value:i,onValueChange:O,children:[A,Y,q,W]}),t[89]=A,t[90]=Y,t[91]=q,t[92]=W,t[93]=i,t[94]=X):X=t[94];let te;return t[95]!==E||t[96]!==D||t[97]!==X?(te=s.jsx(se.Content,{children:s.jsx("div",{className:"flex h-full min-h-0 flex-col overflow-auto",children:s.jsxs("div",{className:"mx-auto flex w-full max-w-[1680px] flex-col gap-4 px-4 py-6 sm:px-8 sm:py-8",children:[E,D,X]})})}),t[95]=E,t[96]=D,t[97]=X,t[98]=te):te=t[98],te}function We(t){return{value:t.slug,label:`${t.slug} · ${t.name}`}}function Xe(){return Date.now()}export{ol as default};