decocms 4.586.0 → 4.587.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (470) hide show
  1. package/dist/client/assets/{AlertCircle-CGZfuvxJ.js → AlertCircle-D_6mZhd3.js} +1 -1
  2. package/dist/client/assets/{AreaChart-DXqVsicd.js → AreaChart-DQSuG1yE.js} +1 -1
  3. package/dist/client/assets/{ArrowLeft-XURGfwpG.js → ArrowLeft-DjgSByoQ.js} +1 -1
  4. package/dist/client/assets/{ArrowRight-ZoKxZa45.js → ArrowRight-Du-vqw_x.js} +1 -1
  5. package/dist/client/assets/{ArrowUp-DJZ55cl-.js → ArrowUp-Hd6A0uf9.js} +1 -1
  6. package/dist/client/assets/{BookOpen01-gO5hgFUK.js → BookOpen01-gL1m_4-g.js} +1 -1
  7. package/dist/client/assets/{CartesianChart-B0LNjIyx.js → CartesianChart-ghS8jWki.js} +1 -1
  8. package/dist/client/assets/{CategoricalChart-CmAKQrAh.js → CategoricalChart-FLgBKuSu.js} +1 -1
  9. package/dist/client/assets/{CheckCircle-CmN8U1V5.js → CheckCircle-12UwMq4H.js} +1 -1
  10. package/dist/client/assets/{ChevronDown-ClblfTVV.js → ChevronDown-DeUpalBN.js} +1 -1
  11. package/dist/client/assets/{ChevronSelectorVertical-YxAp9GGa.js → ChevronSelectorVertical-DO-HHLr6.js} +1 -1
  12. package/dist/client/assets/{ChevronUp-0ZCAxpBW.js → ChevronUp-BzeZGyJH.js} +1 -1
  13. package/dist/client/assets/{CreditCard01-CcTQ1h3_.js → CreditCard01-C7IRKQGq.js} +1 -1
  14. package/dist/client/assets/{Eye-D5j_svLn.js → Eye-C1-H4NKN.js} +1 -1
  15. package/dist/client/assets/{File02-Cs751Kds.js → File02-CFyU1pAb.js} +1 -1
  16. package/dist/client/assets/Fingerprint04-BmN62_tt.js +1 -0
  17. package/dist/client/assets/{Globe04-DO1uUwfE.js → Globe04-DEUqOfwK.js} +1 -1
  18. package/dist/client/assets/{Image01-CJL4B_rR.js → Image01-D1EDWKnx.js} +1 -1
  19. package/dist/client/assets/{Key01-fuHivqLl.js → Key01-tELScC1h.js} +1 -1
  20. package/dist/client/assets/{LayoutLeft-CCeum9wV.js → LayoutLeft-551J-MO9.js} +1 -1
  21. package/dist/client/assets/{LinkBroken01-cq4srxHs.js → LinkBroken01-BdgK-qQO.js} +1 -1
  22. package/dist/client/assets/{MessageCircle01-Bf6dD94_.js → MessageCircle01-DVvYPWC-.js} +1 -1
  23. package/dist/client/assets/{Minus-Cc21R1KY.js → Minus-CwITAxnt.js} +1 -1
  24. package/dist/client/assets/{Monitor01-DGdgEYxG.js → Monitor01-Cj8V3TAw.js} +1 -1
  25. package/dist/client/assets/{Play-zYFs_vGL.js → Play-R1uGwJ-1.js} +1 -1
  26. package/dist/client/assets/{Plus--DcN-eh1.js → Plus-B-S-SZ1j.js} +1 -1
  27. package/dist/client/assets/{ReferenceLine-D6M1JZR1.js → ReferenceLine-DFNcBn1Q.js} +1 -1
  28. package/dist/client/assets/{SearchMd-BwYuN52e.js → SearchMd-BIZLsFUb.js} +1 -1
  29. package/dist/client/assets/{ShoppingBag01-D-gmqcz7.js → ShoppingBag01-bCe9ug4u.js} +1 -1
  30. package/dist/client/assets/{Sun-D9ql5ZlI.js → Sun-DJ9HokSi.js} +1 -1
  31. package/dist/client/assets/{SwitchHorizontal01-BQF84Li3.js → SwitchHorizontal01-DFAhxuil.js} +1 -1
  32. package/dist/client/assets/{Tool01-BeDQSGiN.js → Tool01-DSm8VUO0.js} +1 -1
  33. package/dist/client/assets/{Tooltip-C_RHysFo.js → Tooltip-DKAhw1l_.js} +1 -1
  34. package/dist/client/assets/{Trash01-BmQrADz0.js → Trash01-DmArjRF_.js} +1 -1
  35. package/dist/client/assets/{TrendUp01-_SFSHjzO.js → TrendUp01-Cb0Ss3qG.js} +1 -1
  36. package/dist/client/assets/{Upload01-DOfZqxci.js → Upload01-C0hxLVoS.js} +1 -1
  37. package/dist/client/assets/{UserCheck01-BMoOFYIZ.js → UserCheck01-DoVM7Q3H.js} +1 -1
  38. package/dist/client/assets/{UserSquare-Dn1UPzSD.js → UserSquare-CeU_BqyG.js} +1 -1
  39. package/dist/client/assets/{Users01-B_yoWxPn.js → Users01-CxZDOmOJ.js} +1 -1
  40. package/dist/client/assets/{XClose-C4MsAn9v.js → XClose-lVRJTaql.js} +1 -1
  41. package/dist/client/assets/{Zap-DoxB0q6B.js → Zap-Cnh7YlUV.js} +1 -1
  42. package/dist/client/assets/{access-gate-DQ55JjgP.js → access-gate-wCyQtv5A.js} +1 -1
  43. package/dist/client/assets/{add-connection-dialog-D0PlxcOk.js → add-connection-dialog-sOS8LW6V.js} +1 -1
  44. package/dist/client/assets/agent-app-Ddt_i3hs.js +1 -0
  45. package/dist/client/assets/agent-assets-4Dn6_LPJ.js +1 -0
  46. package/dist/client/assets/{agent-automation-DRfIHgf4.js → agent-automation-DxylbM6B.js} +2 -2
  47. package/dist/client/assets/agent-automations-DTCsvg04.js +1 -0
  48. package/dist/client/assets/agent-blog-YN3-KN-3.js +2 -0
  49. package/dist/client/assets/agent-blog-post-CM6piUKk.js +2 -0
  50. package/dist/client/assets/agent-calendar-BJOF6wGS.js +1 -0
  51. package/dist/client/assets/{agent-capabilities-Dh06TMfs.js → agent-capabilities-DFVJwxaH.js} +1 -1
  52. package/dist/client/assets/agent-connect-sources-DyiJgP9L.js +1 -0
  53. package/dist/client/assets/agent-deck-BJbp-kJP.js +1 -0
  54. package/dist/client/assets/agent-e2e-BPbuZrSW.js +1 -0
  55. package/dist/client/assets/agent-experiments-CdtDrGBl.js +1 -0
  56. package/dist/client/assets/agent-file-TtINmaDO.js +1 -0
  57. package/dist/client/assets/agent-hosting-C1oXMGvH.js +1 -0
  58. package/dist/client/assets/agent-icon-DA-Fg7pF.js +1 -0
  59. package/dist/client/assets/agent-library-DiFYtmp3.js +1 -0
  60. package/dist/client/assets/agent-library-file-B8tZpffC.js +1 -0
  61. package/dist/client/assets/agent-overview-BItm6Vlt.js +1 -0
  62. package/dist/client/assets/{agent-releases-CQDLHf-9.js → agent-releases-JJOjPP8D.js} +2 -2
  63. package/dist/client/assets/agent-settings-BMZl-puv.js +1 -0
  64. package/dist/client/assets/{agent-site-editor-Bn_zysVp.js → agent-site-editor-B1-p5Hbd.js} +2 -2
  65. package/dist/client/assets/agent-site-editor-code-GUBPAYOc.js +2 -0
  66. package/dist/client/assets/agent-site-editor-content-C0ANuka1.js +1 -0
  67. package/dist/client/assets/agent-site-editor-preview-BSvKajfu.js +1 -0
  68. package/dist/client/assets/agent-view-CuMB-zdu.js +1 -0
  69. package/dist/client/assets/{agent-view-guard-_UB25wdA.js → agent-view-guard-Dp1jnrh9.js} +1 -1
  70. package/dist/client/assets/{ai-providers-BZmTFJ6J.js → ai-providers-DhIAtcli.js} +1 -1
  71. package/dist/client/assets/{alert-Dl9RecsO.js → alert-D8-tLSOF.js} +1 -1
  72. package/dist/client/assets/{analytics-sections-ChR-yKgZ.js → analytics-sections-CMaRh5vg.js} +1 -1
  73. package/dist/client/assets/{api-keys-BAKKjcCM.js → api-keys-BYyk36lL.js} +1 -1
  74. package/dist/client/assets/api-keys-CZghJUH5.js +1 -0
  75. package/dist/client/assets/app-editor-D0csBY-b.js +1 -0
  76. package/dist/client/assets/{asset-utils-C40qdOgS.js → asset-utils-DZv-FEec.js} +1 -1
  77. package/dist/client/assets/{auth-DuSLyK-k.js → auth-CTQZGBnP.js} +1 -1
  78. package/dist/client/assets/{auth-catchall-CwzGmsez.js → auth-catchall-kXXiTe4J.js} +1 -1
  79. package/dist/client/assets/auth-entry-CmrAwa9A.js +1 -0
  80. package/dist/client/assets/{auth-split-layout-D0SngsR5.js → auth-split-layout-CHsrc83a.js} +1 -1
  81. package/dist/client/assets/{authenticate-and-persist-oauth-BrPxKw11.js → authenticate-and-persist-oauth-D44eIeUD.js} +1 -1
  82. package/dist/client/assets/{automation-list-row-C_0woHJW.js → automation-list-row-PeCAvjmp.js} +1 -1
  83. package/dist/client/assets/{automation-runs-DwwK7nJ3.js → automation-runs-BUHEghGv.js} +1 -1
  84. package/dist/client/assets/automations-DWMaGnJ_.js +1 -0
  85. package/dist/client/assets/{badge-BvHOfdxU.js → badge-CXWhQd3j.js} +1 -1
  86. package/dist/client/assets/{block-document-CGK32I9G.js → block-document-CGeTYWv-.js} +1 -1
  87. package/dist/client/assets/{blocks-preview-workspace-context-CN-ldvuU.js → blocks-preview-workspace-context-Dpk4HnW-.js} +1 -1
  88. package/dist/client/assets/{blocks-tab-states-DxLq1BL5.js → blocks-tab-states-CFYo4clt.js} +1 -1
  89. package/dist/client/assets/{blog-preview-url-cX5z_9aO.js → blog-preview-url-Dnn3CdoH.js} +1 -1
  90. package/dist/client/assets/{blog-schema-CTE9utzf.js → blog-schema-DciG3sv2.js} +1 -1
  91. package/dist/client/assets/{blog-source-gate-DWHD3Df5.js → blog-source-gate-DxXfL9t9.js} +1 -1
  92. package/dist/client/assets/{blog-view-gate-DT-8hHxE.js → blog-view-gate-DwmbI_7t.js} +1 -1
  93. package/dist/client/assets/{buckets-DMt9Xchk.js → buckets-Dn5vUsy9.js} +1 -1
  94. package/dist/client/assets/{build-improve-prompt-doc-D0Nbi1s7.js → build-improve-prompt-doc-CCMSIskc.js} +1 -1
  95. package/dist/client/assets/{calendar-BUgmhSfk.js → calendar-C8iDoCnd.js} +1 -1
  96. package/dist/client/assets/{capability-load-error-DCoklIp8.js → capability-load-error-DGMDILUu.js} +1 -1
  97. package/dist/client/assets/category-editor-CvyZlhDa.js +1 -0
  98. package/dist/client/assets/{category-tree-BeXLYa5S.js → category-tree-CoKnKzyW.js} +1 -1
  99. package/dist/client/assets/{chart-DfTUTOGH.js → chart-CxNNAoSv.js} +1 -1
  100. package/dist/client/assets/{chat-context-DG5tQFfU.js → chat-context-Bo7uj7QO.js} +1 -1
  101. package/dist/client/assets/{chat-draft-Bv2iw9Fr.js → chat-draft-1n081f6C.js} +1 -1
  102. package/dist/client/assets/{checkbox-DAnVkT6Q.js → checkbox-CouJku1L.js} +1 -1
  103. package/dist/client/assets/choose-editor-BudS68fU.js +1 -0
  104. package/dist/client/assets/{cli-auth-success-CY4cK7Ok.js → cli-auth-success-XgEBlx4y.js} +1 -1
  105. package/dist/client/assets/cms-settings-editor-BihAt8mo.js +1 -0
  106. package/dist/client/assets/{cms-store-drafts-BDhAH5vV.js → cms-store-drafts-aK3C7NIN.js} +1 -1
  107. package/dist/client/assets/{collapsible-DifRD2Ww.js → collapsible-BQXIF7yl.js} +1 -1
  108. package/dist/client/assets/collection-detail-kNjKSTlB.js +1 -0
  109. package/dist/client/assets/{collection-display-button-nfEDIRuH.js → collection-display-button-rcoJHzLM.js} +1 -1
  110. package/dist/client/assets/{collection-search-RWM-9f07.js → collection-search-DHGaqJoX.js} +1 -1
  111. package/dist/client/assets/{collection-table-wrapper-DVjGjn7R.js → collection-table-wrapper-nEvFtZNu.js} +1 -1
  112. package/dist/client/assets/{collection-tabs-BkmY1xp_.js → collection-tabs-DyPYpvut.js} +1 -1
  113. package/dist/client/assets/{combobox-D7DiHBHL.js → combobox-5tUoYNvN.js} +1 -1
  114. package/dist/client/assets/{command-DHGFzOhP.js → command-XtwrY353.js} +1 -1
  115. package/dist/client/assets/{companion-mcps-section-D7d32LFm.js → companion-mcps-section-BIxpu0CV.js} +1 -1
  116. package/dist/client/assets/{config-dB-x76iz.js → config-B-dLgcud.js} +1 -1
  117. package/dist/client/assets/{connect-D-G-5Mck.js → connect-IzhjVKIX.js} +3 -3
  118. package/dist/client/assets/{connect-key-DYxzA5cq.js → connect-key-Djf6OdTt.js} +1 -1
  119. package/dist/client/assets/{connect-layout-vX9TenPs.js → connect-layout-BLFE1r8J.js} +1 -1
  120. package/dist/client/assets/{connect-source-dialog-hJXgVRU-.js → connect-source-dialog-K-oLzdRz.js} +1 -1
  121. package/dist/client/assets/{connection-CeuJqjaI.js → connection-CVYLa59l.js} +1 -1
  122. package/dist/client/assets/{connection-card-bC9jkQR3.js → connection-card-DrE2nEQK.js} +1 -1
  123. package/dist/client/assets/connection-detail-BzNp4KYO.js +1 -0
  124. package/dist/client/assets/{connection-form-helpers-BVK3iXej.js → connection-form-helpers-ws_4888d.js} +1 -1
  125. package/dist/client/assets/{connection-slug-BofuMVWL.js → connection-slug-BnP-Wula.js} +1 -1
  126. package/dist/client/assets/connections-DYD0GVv1.js +1 -0
  127. package/dist/client/assets/{content-tab-B2YwxmJz.js → content-tab-DLB2Uvie.js} +3 -3
  128. package/dist/client/assets/context-E7CmO04l.js +1 -0
  129. package/dist/client/assets/{context-menu-BgKzmvfA.js → context-menu-OGQDG2f-.js} +1 -1
  130. package/dist/client/assets/{context-shell-Bnnp_FlP.js → context-shell-B2TiiX4o.js} +3 -3
  131. package/dist/client/assets/{create-organization-dialog-BeGGdtfc.js → create-organization-dialog-C58t7dGd.js} +1 -1
  132. package/dist/client/assets/{daily-pulse-D8S4f077.js → daily-pulse-C-8Ge7Gb.js} +1 -1
  133. package/dist/client/assets/{delete-copy-C7-0DCkQ.js → delete-copy-DsDE5E3R.js} +1 -1
  134. package/dist/client/assets/{device-hint-B6fw2qhI.js → device-hint-Cw9A4RTs.js} +1 -1
  135. package/dist/client/assets/{discover-BhyJuEKB.js → discover-Dt0njfXu.js} +1 -1
  136. package/dist/client/assets/{domain-settings-DWaq5CPi.js → domain-settings-DcqOrcxN.js} +1 -1
  137. package/dist/client/assets/{drawer-BXd80xtd.js → drawer-DDCMGagW.js} +1 -1
  138. package/dist/client/assets/{editor-DNZ-WgCS.js → editor-CIB3F1gV.js} +1 -1
  139. package/dist/client/assets/{editor-classes-CzejjvgI.js → editor-classes-CLvZguOr.js} +1 -1
  140. package/dist/client/assets/{empty-message-DVICFi26.js → empty-message-C5kN-FsM.js} +1 -1
  141. package/dist/client/assets/{empty-state-BK8GboWz.js → empty-state-BwwrJHKq.js} +1 -1
  142. package/dist/client/assets/{empty-state-LbEOn0Mj.js → empty-state-CiMt55-l.js} +1 -1
  143. package/dist/client/assets/{experiments-tab-choice-DYGF6IS1.js → experiments-tab-choice-HOP6qrjW.js} +1 -1
  144. package/dist/client/assets/{extract-connection-data-B1FMXoXK.js → extract-connection-data-BB3HY3pL.js} +1 -1
  145. package/dist/client/assets/{feature-gate-XyzkzO9l.js → feature-gate-DzJ2Wgrv.js} +1 -1
  146. package/dist/client/assets/{feature-paywall-DQF2iJDP.js → feature-paywall-D3CjJHet.js} +1 -1
  147. package/dist/client/assets/file-explorer-BUDGmFj3.js +2 -0
  148. package/dist/client/assets/{file-preview-A0GfMNED.js → file-preview-DrQhYw7q.js} +1 -1
  149. package/dist/client/assets/{file-share-button-pVEpOvSY.js → file-share-button-2PZ7snDO.js} +1 -1
  150. package/dist/client/assets/{file-type-icon-CSrE_noX.js → file-type-icon-CfPI0k5H.js} +1 -1
  151. package/dist/client/assets/{folder-icon-CA298KqN.js → folder-icon-Cc4PI_dN.js} +1 -1
  152. package/dist/client/assets/{form-Cxhh0mxt.js → form-DTFwvxGa.js} +1 -1
  153. package/dist/client/assets/{frame-navigation--4kFXAAS.js → frame-navigation-C2MkzXfc.js} +1 -1
  154. package/dist/client/assets/{gateway-client-PdaGLWBA.js → gateway-client-BWWNWG13.js} +1 -1
  155. package/dist/client/assets/{general-CuKnI3HJ.js → general-B4k9oqH9.js} +1 -1
  156. package/dist/client/assets/{github-icon-h_xg-qFR.js → github-icon-CAEaNNXe.js} +1 -1
  157. package/dist/client/assets/{held-block-view-zi4CM-KX.js → held-block-view-BoX35XB_.js} +1 -1
  158. package/dist/client/assets/home-CS3KzMJa.js +1 -0
  159. package/dist/client/assets/{home-overview-DrWyW-2I.js → home-overview-4hB9-fzq.js} +1 -1
  160. package/dist/client/assets/{hosted-reconcile-uX15ZUhb.js → hosted-reconcile-DD1fLsOV.js} +1 -1
  161. package/dist/client/assets/{icon-button-DzpdeaSs.js → icon-button-C7j9rC9Y.js} +1 -1
  162. package/dist/client/assets/{index-BK93qS26.js → index-6wJ9auoQ.js} +1 -1
  163. package/dist/client/assets/{index-DsWqYG3w.js → index-96oa6z-q.js} +1 -1
  164. package/dist/client/assets/{index-SPj0mL-J.js → index-BBzaKaTx.js} +1 -1
  165. package/dist/client/assets/{index-BpNyzjaQ.js → index-BOuugOzr.js} +1 -1
  166. package/dist/client/assets/{index-DNuvhcDO.js → index-BesTIQjb.js} +1 -1
  167. package/dist/client/assets/{index-BYaF8G7R.js → index-Bnvwu25R.js} +1 -1
  168. package/dist/client/assets/{index-5KkkYmJi.js → index-BuF029H4.js} +1 -1
  169. package/dist/client/assets/{index-CZTrNcsP.js → index-C1rZOaeR.js} +1 -1
  170. package/dist/client/assets/{index-BwBEUlXI.js → index-C3kpYdOE.js} +1 -1
  171. package/dist/client/assets/{index-C_n-5x2E.js → index-C3qV_QcY.js} +1 -1
  172. package/dist/client/assets/{index-3e8V4Do_.js → index-Cg9MjN_F.js} +1 -1
  173. package/dist/client/assets/{index-ba5Vf9vt.js → index-D6K919s-.js} +1 -1
  174. package/dist/client/assets/{index-DUn-LHzT.js → index-DFLWf492.js} +2 -2
  175. package/dist/client/assets/{index-Bld02Tnb.js → index-DdVVtGb-.js} +1 -1
  176. package/dist/client/assets/{index-BuZqAz74.js → index-DokE5sNF.js} +57 -56
  177. package/dist/client/assets/{index-SIZschZt.js → index-SNBsd1n5.js} +1 -1
  178. package/dist/client/assets/{index-redirect-DlIbuGOg.js → index-redirect-B0kETsWy.js} +1 -1
  179. package/dist/client/assets/{index-rt88hTRg.js → index-x-5-P0v0.js} +1 -1
  180. package/dist/client/assets/{infiniteQueryObserver-CHN_AvWa.js → infiniteQueryObserver-BXbGEZ4N.js} +1 -1
  181. package/dist/client/assets/{infra-billing-DHY4EnRE.js → infra-billing-DV-AbPt9.js} +1 -1
  182. package/dist/client/assets/{input-c6Cx2liY.js → input-BVDv3LEp.js} +3 -3
  183. package/dist/client/assets/{input--XeG2v6T.js → input-CfItTA2l.js} +1 -1
  184. package/dist/client/assets/{integration-icon-D7fga3kk.js → integration-icon-CimWL0HB.js} +1 -1
  185. package/dist/client/assets/{item-actions-Dld5lBtQ.js → item-actions-Be-0vSN9.js} +1 -1
  186. package/dist/client/assets/{jira-icon-_W0tffOR.js → jira-icon-zbkTgTO3.js} +1 -1
  187. package/dist/client/assets/{label-Dm_T3WyF.js → label-CELn1y0I.js} +1 -1
  188. package/dist/client/assets/{layout-DhN3YXX3.js → layout-D8GnCK_t.js} +1 -1
  189. package/dist/client/assets/{legacy-admin-welcome-dialog-C0w-pw6s.js → legacy-admin-welcome-dialog-Xn47ClHz.js} +1 -1
  190. package/dist/client/assets/{legacy-agents-deep-ab_jOs-e.js → legacy-agents-deep-CfDZP79N.js} +1 -1
  191. package/dist/client/assets/{legacy-main-redirect-ByIcJoSw.js → legacy-main-redirect-CXEG-wJ7.js} +1 -1
  192. package/dist/client/assets/library-OZMSR-Ss.js +1 -0
  193. package/dist/client/assets/{library-tab-Cui4e0pM.js → library-tab-B9UPnHBX.js} +1 -1
  194. package/dist/client/assets/login-lSvN3N4Q.js +1 -0
  195. package/dist/client/assets/{markdown-CwYBGb1B.js → markdown-CDaD-85D.js} +1 -1
  196. package/dist/client/assets/{mcp-app-renderer-CLuYD3rD.js → mcp-app-renderer-BS-4Ud35.js} +1 -1
  197. package/dist/client/assets/{mcp-oauth-i1ZYjV6U.js → mcp-oauth-Celefz8j.js} +1 -1
  198. package/dist/client/assets/{mcp-oauth-DZ8B5A_7.js → mcp-oauth-Cfk6BMjf.js} +1 -1
  199. package/dist/client/assets/{members-CvbIQPwh.js → members-CO93VCFa.js} +1 -1
  200. package/dist/client/assets/{memory-BhMXHewc.js → memory-BsFUXROk.js} +2 -2
  201. package/dist/client/assets/{mock-board-DN7OLcTA.js → mock-board-BhdBHUpK.js} +3 -3
  202. package/dist/client/assets/{monaco-editor-CTONBla7.js → monaco-editor-CnKR4oUp.js} +1 -1
  203. package/dist/client/assets/{monitoring-DPSQDGbL.js → monitoring-CQmjoD8Y.js} +2 -2
  204. package/dist/client/assets/{monitoring-stats-row-BUZplGDl.js → monitoring-stats-row-D45dscQU.js} +1 -1
  205. package/dist/client/assets/{multi-select-BSuPEET4.js → multi-select-D0i-_SFY.js} +1 -1
  206. package/dist/client/assets/{mustache-C50JF2sQ.js → mustache-9EZH88YQ.js} +1 -1
  207. package/dist/client/assets/{named-rule-step-D8j_NuRK.js → named-rule-step-yZefk1L5.js} +1 -1
  208. package/dist/client/assets/{named-rule-view-D9U19iHq.js → named-rule-view-BhK3WMdx.js} +1 -1
  209. package/dist/client/assets/{new-project-dialog-Bq2YhVDS.js → new-project-dialog-B-GOkKGZ.js} +1 -1
  210. package/dist/client/assets/{new-project-store-C82itd6a.js → new-project-store-BPGzwGDe.js} +1 -1
  211. package/dist/client/assets/{oauth-callback-xH1_0Q9p.js → oauth-callback-CPdQzJA-.js} +1 -1
  212. package/dist/client/assets/{oauth-callback-ai-provider-Dph1UX9E.js → oauth-callback-ai-provider-BYHZVJQa.js} +1 -1
  213. package/dist/client/assets/oauth-consent-R7d-lFg9.js +1 -0
  214. package/dist/client/assets/{onboarding-tM_LYdg0.js → onboarding-BQ661qWy.js} +1 -1
  215. package/dist/client/assets/openai-conversation-N65nOtwY.js +3 -0
  216. package/dist/client/assets/{optimistic-project-sidebar-views-TOzwQjCp.js → optimistic-project-sidebar-views-D5Qm8FhS.js} +1 -1
  217. package/dist/client/assets/{order-monitor-day-BqegE0N0.js → order-monitor-day-DqX4nMyS.js} +1 -1
  218. package/dist/client/assets/{organization-choice-BzjQ0aL1.js → organization-choice-DJgWzk8W.js} +1 -1
  219. package/dist/client/assets/{orgs-WruSV9A-.js → orgs-CEuotPd0.js} +1 -1
  220. package/dist/client/assets/{own-accounts-section-TMVLN8mQ.js → own-accounts-section-BUJ0fKWR.js} +1 -1
  221. package/dist/client/assets/{pair-BYbJa99U.js → pair-COq-ZPQq.js} +1 -1
  222. package/dist/client/assets/{parse-sections-CVDx-uBN.js → parse-sections-x0Kx4hiT.js} +2 -2
  223. package/dist/client/assets/{plan-DDx2VxJ0.js → plan-DKc8rH1K.js} +1 -1
  224. package/dist/client/assets/{plan-ladder-Ce2vSjaL.js → plan-ladder-pqZJNBpW.js} +1 -1
  225. package/dist/client/assets/{plan-usage-card-CvxOK5ad.js → plan-usage-card-BWKv5Sja.js} +1 -1
  226. package/dist/client/assets/{popover-D6EIL5sL.js → popover-BNjsYhzT.js} +1 -1
  227. package/dist/client/assets/post-calendar-D2IwNEqN.js +1 -0
  228. package/dist/client/assets/{post-editor-v1jKXm9-.js → post-editor-CCfke5Rf.js} +2 -2
  229. package/dist/client/assets/{preview-content-9gQGJiFY.js → preview-content-DvWQfE3X.js} +1 -1
  230. package/dist/client/assets/{preview-dialog-J4DJmy9P.js → preview-dialog-07cwMrWN.js} +1 -1
  231. package/dist/client/assets/{preview-panel-DLe0RaXg.js → preview-panel-C9bhKF_2.js} +1 -1
  232. package/dist/client/assets/preview-tab-COGaRa7u.js +557 -0
  233. package/dist/client/assets/{product-picker-dialog-DCC_2JmD.js → product-picker-dialog-ChT9yEE7.js} +1 -1
  234. package/dist/client/assets/profile-CAs6IhMO.js +1 -0
  235. package/dist/client/assets/project-app-view-DviUlYP5.js +1 -0
  236. package/dist/client/assets/{project-apps-Dezyz6_N.js → project-apps-BilxhqpE.js} +1 -1
  237. package/dist/client/assets/{project-icon-BHn6Xq54.js → project-icon-DzSzNLot.js} +1 -1
  238. package/dist/client/assets/{project-index-5c8GGatg.js → project-index-CR5OwtEu.js} +1 -1
  239. package/dist/client/assets/project-reports-BbMJz4mc.js +1 -0
  240. package/dist/client/assets/project-tasks-BrJzU4LM.js +1 -0
  241. package/dist/client/assets/projects-CEBGkLTr.js +1 -0
  242. package/dist/client/assets/{projects-empty-state-Dh0sHuPd.js → projects-empty-state-BfmuFuvO.js} +1 -1
  243. package/dist/client/assets/{prompts-CYFmsiS6.js → prompts-NPG6oRsv.js} +1 -1
  244. package/dist/client/assets/record-editor-BwlyH5jZ.js +1 -0
  245. package/dist/client/assets/redirect-editor-DtY_MKxf.js +1 -0
  246. package/dist/client/assets/{reports-Cj91Mylc.js → reports-CYPX_k6p.js} +2 -2
  247. package/dist/client/assets/reports-DAi0HbOS.js +1 -0
  248. package/dist/client/assets/reports-onboarding-DKaCbtdm.js +1 -0
  249. package/dist/client/assets/reports-tab-_GtIHZiT.js +2 -0
  250. package/dist/client/assets/repositories-DsojF3_X.js +1 -0
  251. package/dist/client/assets/{repositories-C_7l-hzO.js → repositories-uWeQw1G7.js} +1 -1
  252. package/dist/client/assets/{repository-binding-VVfcdUiy.js → repository-binding-CBLNaLcn.js} +1 -1
  253. package/dist/client/assets/{repository-picker-By75IHJa.js → repository-picker-CXy0gwnT.js} +1 -1
  254. package/dist/client/assets/{require-capability-DEShAaY8.js → require-capability-_6vPPsFH.js} +1 -1
  255. package/dist/client/assets/{required-auth-layout-GSSn-bTA.js → required-auth-layout-Da-vkWUX.js} +1 -1
  256. package/dist/client/assets/{reset-password-eGGPXuZQ.js → reset-password-BMooX7J1.js} +1 -1
  257. package/dist/client/assets/{resizable-XeFzd9pk.js → resizable-CFBuzfqY.js} +1 -1
  258. package/dist/client/assets/{resolve-tab-icon-DQMxOocF.js → resolve-tab-icon-DYcddXtb.js} +1 -1
  259. package/dist/client/assets/{review-settings-BOoUlwEx.js → review-settings-lJuLTN9Z.js} +1 -1
  260. package/dist/client/assets/{role-color-D-S7Ra1A.js → role-color-C2OQmHte.js} +1 -1
  261. package/dist/client/assets/roles-KUKC8vim.js +1 -0
  262. package/dist/client/assets/route-BLThcLzr.js +1 -0
  263. package/dist/client/assets/route-C9UFcNus.js +1 -0
  264. package/dist/client/assets/route-CC0eCWn4.js +1 -0
  265. package/dist/client/assets/{route-page-header-BqA32d57.js → route-page-header-9cHtL5F_.js} +1 -1
  266. package/dist/client/assets/{sandbox-git-api-CkSQDoxX.js → sandbox-git-api-C63hYsFx.js} +1 -1
  267. package/dist/client/assets/{sandbox-lifecycle-context-BBz4IKVo.js → sandbox-lifecycle-context-BBxxjkfA.js} +1 -1
  268. package/dist/client/assets/{save-status-CmYiPWXE.js → save-status-DSROJg37.js} +1 -1
  269. package/dist/client/assets/{schema-CCpL_LVZ.js → schema-BsNip7cg.js} +1 -1
  270. package/dist/client/assets/{schema-B0biNpls.js → schema-DFozZ1Hz.js} +1 -1
  271. package/dist/client/assets/{scroll-area-bkCFS0v8.js → scroll-area-pLrQCixi.js} +1 -1
  272. package/dist/client/assets/{search-input-C4sd-kKh.js → search-input-C2u6aF8T.js} +1 -1
  273. package/dist/client/assets/{search-toggle-rjC0c-Iy.js → search-toggle-CrQFK2VP.js} +1 -1
  274. package/dist/client/assets/{secret-picker-ujhqmuU6.js → secret-picker-Dv9xQHYk.js} +1 -1
  275. package/dist/client/assets/{secrets-CUx_W408.js → secrets-DB4lMKjl.js} +1 -1
  276. package/dist/client/assets/{section-array-field-DOngDm8U.js → section-array-field-DeyNfEV2.js} +1 -1
  277. package/dist/client/assets/{sections-DmtYqnPM.js → sections-DOqOQtJh.js} +1 -1
  278. package/dist/client/assets/sections-editor-Cw3wqkPx.js +1 -0
  279. package/dist/client/assets/{select-BkYZ4NYA.js → select-CKROachj.js} +1 -1
  280. package/dist/client/assets/{select-model-BNVZsPuq.js → select-model-BWtBiL3W.js} +1 -1
  281. package/dist/client/assets/{seo-editor-D-DOTzeP.js → seo-editor-DIdnRSzC.js} +1 -1
  282. package/dist/client/assets/{separator-DTKXzVmt.js → separator-DfXZNxTX.js} +1 -1
  283. package/dist/client/assets/{session-runtime-HHtypsTM.js → session-runtime-gzzgn7Pj.js} +1 -1
  284. package/dist/client/assets/settings-tab-BHrFLzvD.js +1 -0
  285. package/dist/client/assets/{sheet-Lq2qXLx8.js → sheet-DUgkYIwI.js} +1 -1
  286. package/dist/client/assets/{shell-layout-rYoN4RTk.js → shell-layout-4H95PNNw.js} +1 -1
  287. package/dist/client/assets/{site-draft-actions-D72ZWrGI.js → site-draft-actions-k_cj-bS_.js} +1 -1
  288. package/dist/client/assets/{site-draft-view-DdS4HrBp.js → site-draft-view-LE30E0qM.js} +1 -1
  289. package/dist/client/assets/site-editor-e8Hx_Aj4.js +1 -0
  290. package/dist/client/assets/{site-editor-toast-aupfR4Aq.js → site-editor-toast-Ynfp7Kjt.js} +1 -1
  291. package/dist/client/assets/skills-CDREZcnF.js +1 -0
  292. package/dist/client/assets/{slider-B4bXP1H_.js → slider-Bw577vCx.js} +1 -1
  293. package/dist/client/assets/{sortable.esm-n9zdQXyB.js → sortable.esm-CykrOV-3.js} +1 -1
  294. package/dist/client/assets/{sso-DIU8j1zk.js → sso-Cj24TaPV.js} +1 -1
  295. package/dist/client/assets/{suggestion-Nntdxi5T.js → suggestion-B9R_Jc1V.js} +1 -1
  296. package/dist/client/assets/{super-agent-icon-DHSnZQuw.js → super-agent-icon-DPyVQnGV.js} +1 -1
  297. package/dist/client/assets/{switch-COjzxQ39.js → switch-B_2aZNJw.js} +1 -1
  298. package/dist/client/assets/{synced-repos-s5ovH7Qr.js → synced-repos-CXSZMJ0F.js} +1 -1
  299. package/dist/client/assets/{tab-icon-glyph-CvvfUXQl.js → tab-icon-glyph-B4eeZpT6.js} +1 -1
  300. package/dist/client/assets/{table-DQIAY6r-.js → table-DsirtjTQ.js} +1 -1
  301. package/dist/client/assets/{tabs-CbfCGlFS.js → tabs-YBRFhTvN.js} +1 -1
  302. package/dist/client/assets/{task-board-DEUSGytR.js → task-board-DK1K-Mbd.js} +1 -1
  303. package/dist/client/assets/{task-key-DaPOId6s.js → task-key-DZxJr9g6.js} +1 -1
  304. package/dist/client/assets/{task-route-BJj40Yza.js → task-route-Cqr8SKPq.js} +1 -1
  305. package/dist/client/assets/{task-status-B6WfZxUN.js → task-status-bozQW5wT.js} +1 -1
  306. package/dist/client/assets/{taskboard-analytics-UnAzvxoh.js → taskboard-analytics-CBkUVAdj.js} +1 -1
  307. package/dist/client/assets/{tasks-vny6IFm0.js → tasks-ALHYjofA.js} +1 -1
  308. package/dist/client/assets/tasks-DtEwdEBz.js +1 -0
  309. package/dist/client/assets/{textarea-CcO-rfag.js → textarea-BJdJh9he.js} +1 -1
  310. package/dist/client/assets/thread-analytics-D1D-pLk-.js +1 -0
  311. package/dist/client/assets/{thread-button-DbVaWztE.js → thread-button-DZPQxeV0.js} +1 -1
  312. package/dist/client/assets/{thread-intent-CyH0Z8_7.js → thread-intent-GDKuN4r8.js} +1 -1
  313. package/dist/client/assets/{thread-route-Dw1cQjON.js → thread-route-9-m2-1gn.js} +1 -1
  314. package/dist/client/assets/thread-route-pIQL1n8l.js +1 -0
  315. package/dist/client/assets/{thread-sheet-body-C6XCaB8H.js → thread-sheet-body-j2UKM_n_.js} +1 -1
  316. package/dist/client/assets/{time-range-picker-C45MZ0gR.js → time-range-picker-BUjru-02.js} +1 -1
  317. package/dist/client/assets/{toggle-group-DFyE84bx.js → toggle-group-C134tdMJ.js} +1 -1
  318. package/dist/client/assets/{tool-set-selector-BgHdncVU.js → tool-set-selector-CxmO1N2o.js} +1 -1
  319. package/dist/client/assets/{toolbar-icon-button-BroRQfDx.js → toolbar-icon-button-dQBEwFVn.js} +1 -1
  320. package/dist/client/assets/{tooltip-DnGqcvtu.js → tooltip-CqEoC-F2.js} +1 -1
  321. package/dist/client/assets/{tooltipContext-BVc6eTu_.js → tooltipContext-BdzlPUCu.js} +1 -1
  322. package/dist/client/assets/{track-ENeykFhY.js → track-Drgb4ZQ6.js} +1 -1
  323. package/dist/client/assets/{types-B4ln4I1a.js → types-DF2iMJoX.js} +1 -1
  324. package/dist/client/assets/{url-slug-BCxEu7m_.js → url-slug-pPnhQQlO.js} +1 -1
  325. package/dist/client/assets/{usage-stats-C5Wj6kIy.js → usage-stats-BHc1sfxR.js} +1 -1
  326. package/dist/client/assets/{use-ai-providers-BG5EDM0R.js → use-ai-providers-Khsm6etv.js} +1 -1
  327. package/dist/client/assets/{use-api-keys-CjwRm6n8.js → use-api-keys-CktIN6Ip.js} +1 -1
  328. package/dist/client/assets/{use-apply-named-rule-BH9tV1RN.js → use-apply-named-rule-BH_mAqzD.js} +1 -1
  329. package/dist/client/assets/use-ask-in-chat-SQXk6mVC.js +1 -0
  330. package/dist/client/assets/{use-automations-D4bJmUmE.js → use-automations-it-dxpVL.js} +1 -1
  331. package/dist/client/assets/{use-autosave-Dq8gUNzN.js → use-autosave-DFZMnBbI.js} +1 -1
  332. package/dist/client/assets/use-blocks-v8-project-GUlVOp3p.js +1 -0
  333. package/dist/client/assets/use-blog-view-Bm6F2c8c.js +1 -0
  334. package/dist/client/assets/{use-chat-layout-state-D38zRykR.js → use-chat-layout-state-CyAMAqyg.js} +1 -1
  335. package/dist/client/assets/{use-cms-publish-actions-Bf5Y1rJL.js → use-cms-publish-actions-DGbVdkLh.js} +1 -1
  336. package/dist/client/assets/{use-connect-companion-leNqQRzW.js → use-connect-companion-C-Jq7bdY.js} +1 -1
  337. package/dist/client/assets/{use-connection-C4G0ZMoe.js → use-connection-BJP9eCiw.js} +1 -1
  338. package/dist/client/assets/{use-content-sync-CeYI53r8.js → use-content-sync-hirvqHbx.js} +1 -1
  339. package/dist/client/assets/{use-copy-BFeXylk9.js → use-copy-Bh0jH9rH.js} +1 -1
  340. package/dist/client/assets/{use-current-view-swKX6Bc6.js → use-current-view-xnQlJLn5.js} +1 -1
  341. package/dist/client/assets/{use-date-fns-locale-DX45EO9I.js → use-date-fns-locale-D_OgIl71.js} +1 -1
  342. package/dist/client/assets/{use-debounced-autosave-BVXsg1Of.js → use-debounced-autosave-BCqW4nkA.js} +1 -1
  343. package/dist/client/assets/{use-debounced-value-CPl0Wyl6.js → use-debounced-value-q_QhUSeI.js} +1 -1
  344. package/dist/client/assets/{use-deco-credits-C4mVYU5r.js → use-deco-credits-DrzaNgs_.js} +1 -1
  345. package/dist/client/assets/{use-decopilot-events-SRdggwTs.js → use-decopilot-events-TX8jybTQ.js} +1 -1
  346. package/dist/client/assets/{use-delete-block-CRyG6Do-.js → use-delete-block-BINjsTY1.js} +1 -1
  347. package/dist/client/assets/{use-delete-connection-C-kXdkQA.js → use-delete-connection-Ch7Fpvpo.js} +1 -1
  348. package/dist/client/assets/{use-deployment-admin-Dwt-RYsg.js → use-deployment-admin-h6uBbZPp.js} +1 -1
  349. package/dist/client/assets/{use-entitlements-DgXhk8I6.js → use-entitlements-B_976V5P.js} +1 -1
  350. package/dist/client/assets/{use-fast-preview-draft-url-DtikvUh-.js → use-fast-preview-draft-url-CQuFD5Lq.js} +1 -1
  351. package/dist/client/assets/{use-file-configs-BlRaUlfc.js → use-file-configs-iPUyCrpd.js} +1 -1
  352. package/dist/client/assets/{use-id-selection-CJdNm4ZY.js → use-id-selection-DnYJXQwW.js} +1 -1
  353. package/dist/client/assets/{use-in-settings-cNZb_oio.js → use-in-settings-DvVa8LTW.js} +1 -1
  354. package/dist/client/assets/{use-inbox-feed-BKl_0o2v.js → use-inbox-feed-C2oj6HbE.js} +1 -1
  355. package/dist/client/assets/{use-infinite-scroll-DgSz0aNh.js → use-infinite-scroll-BcBSkfyb.js} +1 -1
  356. package/dist/client/assets/{use-join-requests-pUhubFwu.js → use-join-requests-D2xu_Ec9.js} +1 -1
  357. package/dist/client/assets/{use-main-panel-tabs-B0lMlgyK.js → use-main-panel-tabs-PrqkAqrJ.js} +1 -1
  358. package/dist/client/assets/{use-mcp-auth-status-BLLNsVrE.js → use-mcp-auth-status-CVLoS2DG.js} +1 -1
  359. package/dist/client/assets/{use-mcp-client-UWOU8UbZ.js → use-mcp-client-DVaNUeKZ.js} +1 -1
  360. package/dist/client/assets/{use-mcp-prompts-CjwiiUTx.js → use-mcp-prompts-mR07NyXv.js} +1 -1
  361. package/dist/client/assets/{use-mcp-tools-C7Kg2Nto.js → use-mcp-tools-DAzNJiwR.js} +1 -1
  362. package/dist/client/assets/{use-mobile-Cq1k3-Gk.js → use-mobile-YQVdSq9V.js} +1 -1
  363. package/dist/client/assets/{use-move-blocks-DH3gSdil.js → use-move-blocks-B5nRM-da.js} +1 -1
  364. package/dist/client/assets/{use-navigate-to-agent-vJOwimSb.js → use-navigate-to-agent-O2aekGtL.js} +1 -1
  365. package/dist/client/assets/{use-never-published-BB5kYeS3.js → use-never-published-WdNVjWmr.js} +1 -1
  366. package/dist/client/assets/{use-org-fs-CAHuTLc_.js → use-org-fs-DcqFgCaV.js} +1 -1
  367. package/dist/client/assets/{use-org-notice-D_lLzWXp.js → use-org-notice-D_lzrT1v.js} +1 -1
  368. package/dist/client/assets/{use-org-repo-syncs-BxGs1Gi_.js → use-org-repo-syncs-CXR8xOyz.js} +1 -1
  369. package/dist/client/assets/{use-org-sso-fZ2uDAIp.js → use-org-sso-Fbk8Wwq4.js} +1 -1
  370. package/dist/client/assets/{use-organization-settings-D8JbZGlQ.js → use-organization-settings-DYnwG033.js} +1 -1
  371. package/dist/client/assets/{use-panel-navigate-B3thngCs.js → use-panel-navigate-DYNTPDzL.js} +1 -1
  372. package/dist/client/assets/{use-project-native-view-presence-BKZJ0lpX.js → use-project-native-view-presence-BWo3tL86.js} +1 -1
  373. package/dist/client/assets/{use-project-scope-CD-cb4-V.js → use-project-scope-Zk4IP7B6.js} +1 -1
  374. package/dist/client/assets/{use-recent-apps-Co5DoIGT.js → use-recent-apps-CGvNAmsp.js} +1 -1
  375. package/dist/client/assets/{use-reports-diagnostic-lGxrsSfr.js → use-reports-diagnostic-DYiqS51Q.js} +1 -1
  376. package/dist/client/assets/{use-sandbox-events-BcrE-YTF.js → use-sandbox-events--EgmreWQ.js} +1 -1
  377. package/dist/client/assets/{use-secrets-yIZbpwIn.js → use-secrets-BcD5BTqH.js} +1 -1
  378. package/dist/client/assets/{use-section-preview-base-C2vE3o4z.js → use-section-preview-base-QYSyjVux.js} +1 -1
  379. package/dist/client/assets/{use-sidebar-collapsed-Bo3tE9bK.js → use-sidebar-collapsed-DIdfXbOr.js} +1 -1
  380. package/dist/client/assets/{use-tags-BQcMuDty.js → use-tags-a6kkz9Aj.js} +1 -1
  381. package/dist/client/assets/{use-task-board-analytics-CIahrWuX.js → use-task-board-analytics-CXDDOLeW.js} +1 -1
  382. package/dist/client/assets/{use-task-board-item-prs-W9kboyPg.js → use-task-board-item-prs-CmeNcFe2.js} +1 -1
  383. package/dist/client/assets/{use-task-board-items-DP6ZFnrN.js → use-task-board-items-TENQt5cS.js} +1 -1
  384. package/dist/client/assets/{use-task-board-prompts-qQB1KZ8p.js → use-task-board-prompts-Dq_lA2pC.js} +1 -1
  385. package/dist/client/assets/{use-task-metadata-C2UpEUk-.js → use-task-metadata-C75UjZAF.js} +1 -1
  386. package/dist/client/assets/{use-thread-outputs-A3ms5KEO.js → use-thread-outputs-he6CbGJb.js} +1 -1
  387. package/dist/client/assets/{use-view-draft-kind-CXMOqIBD.js → use-view-draft-kind-DfBSo4Ua.js} +1 -1
  388. package/dist/client/assets/{use-voice-input-poVZeRVs.js → use-voice-input-B9tq3K2A.js} +1 -1
  389. package/dist/client/assets/useInfiniteQuery-BVFlK8XX.js +1 -0
  390. package/dist/client/assets/{useQueries-DhONZGBj.js → useQueries-UpDYaK89.js} +1 -1
  391. package/dist/client/assets/useSuspenseInfiniteQuery-CGXfA9jP.js +1 -0
  392. package/dist/client/assets/{users-B_cNHXhu.js → users-D5ojYrnY.js} +1 -1
  393. package/dist/client/assets/{utils-BdAsQahL.js → utils-Bsr3pAeq.js} +1 -1
  394. package/dist/client/assets/variant-calendar-CiQ54mcG.js +1 -0
  395. package/dist/client/assets/{variant-matcher-override-CxSxAvsY.js → variant-matcher-override-CylJ7vNA.js} +1 -1
  396. package/dist/client/assets/{view-header-CZchRX7c.js → view-header-BwRsIWg-.js} +1 -1
  397. package/dist/client/assets/{virtual-mcp-4VHtoaO4.js → virtual-mcp-BULA9FxB.js} +1 -1
  398. package/dist/client/assets/{watch-sse-pool-C7kLS2GY.js → watch-sse-pool-BlWzBx5R.js} +1 -1
  399. package/dist/client/index.html +1 -1
  400. package/dist/server/migrate.js +694 -389
  401. package/dist/server/server.js +1210 -905
  402. package/package.json +2 -1
  403. package/dist/client/assets/agent-app-Ch0m8w-u.js +0 -1
  404. package/dist/client/assets/agent-assets-COp9WevM.js +0 -1
  405. package/dist/client/assets/agent-automations-C02SU72h.js +0 -1
  406. package/dist/client/assets/agent-blog-post-BOz0k9l4.js +0 -2
  407. package/dist/client/assets/agent-blog-yxvdX-jE.js +0 -2
  408. package/dist/client/assets/agent-calendar-BrjcVSaH.js +0 -1
  409. package/dist/client/assets/agent-connect-sources-DhRc2-S_.js +0 -1
  410. package/dist/client/assets/agent-deck-BEYLEOzY.js +0 -1
  411. package/dist/client/assets/agent-e2e-w331hEXE.js +0 -1
  412. package/dist/client/assets/agent-experiments-CIRveYjB.js +0 -1
  413. package/dist/client/assets/agent-file-CRD-Yf8v.js +0 -1
  414. package/dist/client/assets/agent-hosting-Cf_5DVCs.js +0 -1
  415. package/dist/client/assets/agent-icon-DwJHakBB.js +0 -1
  416. package/dist/client/assets/agent-library-BDbVLVqf.js +0 -1
  417. package/dist/client/assets/agent-library-file-FdEtCyvQ.js +0 -1
  418. package/dist/client/assets/agent-overview-90jCAnhT.js +0 -1
  419. package/dist/client/assets/agent-settings-DazJIQdd.js +0 -1
  420. package/dist/client/assets/agent-site-editor-code-AxRnYsCW.js +0 -2
  421. package/dist/client/assets/agent-site-editor-content-Css28lBT.js +0 -1
  422. package/dist/client/assets/agent-site-editor-preview-rUOwwi2z.js +0 -1
  423. package/dist/client/assets/agent-view-BwA2SWmb.js +0 -1
  424. package/dist/client/assets/api-keys-7ijHuhZV.js +0 -1
  425. package/dist/client/assets/app-editor-aGjbireC.js +0 -1
  426. package/dist/client/assets/auth-entry-QpiCG8Kt.js +0 -1
  427. package/dist/client/assets/automations-Dc36NZHt.js +0 -1
  428. package/dist/client/assets/category-editor-B7D8BVkO.js +0 -1
  429. package/dist/client/assets/choose-editor-DX9vd71s.js +0 -1
  430. package/dist/client/assets/cms-settings-editor-Cj7WfazE.js +0 -1
  431. package/dist/client/assets/collection-detail-Bq38QGfT.js +0 -1
  432. package/dist/client/assets/connection-detail-BZxu1Il4.js +0 -1
  433. package/dist/client/assets/connections-_2oGT26C.js +0 -1
  434. package/dist/client/assets/context-RVZVsnak.js +0 -1
  435. package/dist/client/assets/file-explorer-DbKxpql5.js +0 -2
  436. package/dist/client/assets/home-w1KhoL46.js +0 -1
  437. package/dist/client/assets/library-LpeL-fNK.js +0 -1
  438. package/dist/client/assets/login-COwI3GAk.js +0 -1
  439. package/dist/client/assets/oauth-consent-BJ9Jn7G7.js +0 -1
  440. package/dist/client/assets/openai-conversation-DoQ_2Seq.js +0 -3
  441. package/dist/client/assets/post-calendar-J6Cs6vQ8.js +0 -1
  442. package/dist/client/assets/preview-tab-BxZksZBr.js +0 -557
  443. package/dist/client/assets/profile-CU5pOHcx.js +0 -1
  444. package/dist/client/assets/project-app-view-Chii7rIX.js +0 -1
  445. package/dist/client/assets/project-reports-BhJG82JT.js +0 -1
  446. package/dist/client/assets/project-tasks-AXDig_Zb.js +0 -1
  447. package/dist/client/assets/projects-C19Wu8MK.js +0 -1
  448. package/dist/client/assets/record-editor-D2NFDCNZ.js +0 -1
  449. package/dist/client/assets/redirect-editor-D9WJKRVv.js +0 -1
  450. package/dist/client/assets/reports-C-kEainI.js +0 -1
  451. package/dist/client/assets/reports-onboarding-gB4My80z.js +0 -1
  452. package/dist/client/assets/reports-tab-CsHbv07d.js +0 -2
  453. package/dist/client/assets/repositories-L_Jm13il.js +0 -1
  454. package/dist/client/assets/roles-C8YQ1Aw2.js +0 -1
  455. package/dist/client/assets/route-DjlZ9cbf.js +0 -1
  456. package/dist/client/assets/route-lr7i-nM3.js +0 -1
  457. package/dist/client/assets/route-ojZJTNbW.js +0 -1
  458. package/dist/client/assets/sections-editor-DsX6y72K.js +0 -1
  459. package/dist/client/assets/settings-tab-B50Sia1R.js +0 -1
  460. package/dist/client/assets/site-editor-B6Bvzk4_.js +0 -1
  461. package/dist/client/assets/skills-Cyx-LBzb.js +0 -1
  462. package/dist/client/assets/tasks-BtIOVSMQ.js +0 -1
  463. package/dist/client/assets/thread-analytics-BUAtXNjP.js +0 -1
  464. package/dist/client/assets/thread-route-BjDCYf6b.js +0 -1
  465. package/dist/client/assets/use-ask-in-chat-C6eCNqgR.js +0 -1
  466. package/dist/client/assets/use-blocks-v8-project-Dh0QtV4J.js +0 -1
  467. package/dist/client/assets/use-blog-view-w4rEUATy.js +0 -1
  468. package/dist/client/assets/useInfiniteQuery-CNxlkxws.js +0 -1
  469. package/dist/client/assets/useSuspenseInfiniteQuery-FHN2hj19.js +0 -1
  470. package/dist/client/assets/variant-calendar-DkWaMyhm.js +0 -1
@@ -1 +1 @@
1
- import{A as H,t as U,a9 as S,C as Z,aa as X,f as R,ab as J,ac as Q,o as z}from"./usage-stats-C5Wj6kIy.js";import{gA as C,hk as M,gz as P,hl as x,hm as L,hn as V,ho as K,hp as _,gC as A,eT as N,r as p,ca as $}from"./index-BuZqAz74.js";import{C as k}from"./index-CZTrNcsP.js";function tt(t,e){const i=Math.min(t.top,e.top),s=Math.max(t.bottom,e.bottom),l=Math.min(t.left,e.left),r=Math.max(t.right,e.right)-l,n=s-i;return new DOMRect(l,i,r,n)}var et=class{get middlewares(){const t=[];return this.floatingUIOptions.flip&&t.push(C(typeof this.floatingUIOptions.flip!="boolean"?this.floatingUIOptions.flip:void 0)),this.floatingUIOptions.shift&&t.push(M(typeof this.floatingUIOptions.shift!="boolean"?this.floatingUIOptions.shift:void 0)),this.floatingUIOptions.offset&&t.push(P(typeof this.floatingUIOptions.offset!="boolean"?this.floatingUIOptions.offset:void 0)),this.floatingUIOptions.arrow&&t.push(x(this.floatingUIOptions.arrow)),this.floatingUIOptions.size&&t.push(L(typeof this.floatingUIOptions.size!="boolean"?this.floatingUIOptions.size:void 0)),this.floatingUIOptions.autoPlacement&&t.push(V(typeof this.floatingUIOptions.autoPlacement!="boolean"?this.floatingUIOptions.autoPlacement:void 0)),this.floatingUIOptions.hide&&t.push(K(typeof this.floatingUIOptions.hide!="boolean"?this.floatingUIOptions.hide:void 0)),this.floatingUIOptions.inline&&t.push(_(typeof this.floatingUIOptions.inline!="boolean"?this.floatingUIOptions.inline:void 0)),t}get virtualElement(){var t,e;const{selection:i}=this.editor.state,s=(t=this.getReferencedVirtualElement)===null||t===void 0?void 0:t.call(this);if(s)return s;if(!(!((e=this.view)===null||e===void 0||(e=e.dom)===null||e===void 0)&&e.parentNode))return;const l=S(this.view,i.from,i.to);let r={getBoundingClientRect:()=>l,getClientRects:()=>[l]};if(i instanceof Z){let n=this.view.nodeDOM(i.from);const d=n.dataset.nodeViewWrapper?n:n.querySelector("[data-node-view-wrapper]");d&&(n=d),n&&(r={getBoundingClientRect:()=>n.getBoundingClientRect(),getClientRects:()=>[n.getBoundingClientRect()]})}if(i instanceof k){const{$anchorCell:n,$headCell:d}=i,g=n?n.pos:d.pos,f=d?d.pos:n.pos,u=this.view.nodeDOM(g),o=this.view.nodeDOM(f);if(!u||!o)return;const a=u===o?u.getBoundingClientRect():tt(u.getBoundingClientRect(),o.getBoundingClientRect());r={getBoundingClientRect:()=>a,getClientRects:()=>[a]}}return r}constructor({editor:t,element:e,view:i,pluginKey:s="bubbleMenu",updateDelay:l=250,resizeDelay:r=60,shouldShow:n,appendTo:d,getReferencedVirtualElement:g,options:f}){var u;this.preventHide=!1,this.isVisible=!1,this.scrollTarget=window,this.floatingUIOptions={strategy:"absolute",placement:"top",offset:8,flip:{},shift:{},arrow:!1,size:!1,autoPlacement:!1,hide:!1,inline:!1,onShow:void 0,onHide:void 0,onUpdate:void 0,onDestroy:void 0},this.shouldShow=({view:o,state:a,from:h,to:c})=>{const{doc:m,selection:y}=a,{empty:O}=y,b=!m.textBetween(h,c).length&&X(a.selection),v=this.element.contains(document.activeElement);return!(!(o.hasFocus()||v)||O||b||!this.editor.isEditable)},this.mousedownHandler=()=>{this.preventHide=!0},this.dragstartHandler=()=>{this.hide()},this.resizeHandler=()=>{this.resizeDebounceTimer&&clearTimeout(this.resizeDebounceTimer),this.resizeDebounceTimer=window.setTimeout(()=>{this.updatePosition()},this.resizeDelay)},this.focusHandler=()=>{setTimeout(()=>this.update(this.editor.view))},this.blurHandler=({event:o})=>{var a;if(this.editor.isDestroyed){this.destroy();return}if(this.preventHide){this.preventHide=!1;return}o?.relatedTarget&&(!((a=this.element.parentNode)===null||a===void 0)&&a.contains(o.relatedTarget))||o?.relatedTarget!==this.editor.view.dom&&this.hide()},this.handleDebouncedUpdate=(o,a)=>{const h=!a?.selection.eq(o.state.selection),c=!a?.doc.eq(o.state.doc);!h&&!c||(this.updateDebounceTimer&&clearTimeout(this.updateDebounceTimer),this.updateDebounceTimer=window.setTimeout(()=>{this.updateHandler(o,h,c,a)},this.updateDelay))},this.updateHandler=(o,a,h,c)=>{const{composing:m}=o;if(!(m||!a&&!h)){if(!this.getShouldShow(c)){this.hide();return}this.show(),this.updatePosition()}},this.transactionHandler=({transaction:o})=>{const a=o.getMeta(this.pluginKey);a==="updatePosition"?this.updatePosition():a&&typeof a=="object"&&a.type==="updateOptions"?this.updateOptions(a.options):a==="hide"?this.hide():a==="show"&&(this.updatePosition(),this.show())},this.editor=t,this.element=e,this.view=i,this.pluginKey=s,this.updateDelay=l,this.resizeDelay=r,this.appendTo=d,this.scrollTarget=(u=f?.scrollTarget)!==null&&u!==void 0?u:window,this.getReferencedVirtualElement=g,this.floatingUIOptions={...this.floatingUIOptions,...f},this.element.tabIndex=0,n&&(this.shouldShow=n),this.element.addEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.view.dom.addEventListener("dragstart",this.dragstartHandler),this.editor.on("focus",this.focusHandler),this.editor.on("blur",this.blurHandler),this.editor.on("transaction",this.transactionHandler),window.addEventListener("resize",this.resizeHandler),this.scrollTarget.addEventListener("scroll",this.resizeHandler),this.update(i,i.state),this.getShouldShow()&&(this.show(),this.updatePosition())}updatePosition(){if(!this.isVisible)return;const t=this.virtualElement;t&&A(t,this.element,{placement:this.floatingUIOptions.placement,strategy:this.floatingUIOptions.strategy,middleware:this.middlewares}).then(({x:e,y:i,strategy:s,middlewareData:l})=>{var r,n;if(!(!this.isVisible||this.editor.isDestroyed||!this.element.isConnected)){if(!((r=l.hide)===null||r===void 0)&&r.referenceHidden||!((n=l.hide)===null||n===void 0)&&n.escaped){this.element.style.visibility="hidden";return}this.element.style.visibility="visible",this.element.style.width="max-content",this.element.style.position=s,this.element.style.left=`${e}px`,this.element.style.top=`${i}px`,this.isVisible&&this.floatingUIOptions.onUpdate&&this.floatingUIOptions.onUpdate()}})}update(t,e){const{state:i}=t,s=i.selection.from!==i.selection.to;if(this.updateDelay>0&&s){this.handleDebouncedUpdate(t,e);return}const l=!e?.selection.eq(t.state.selection),r=!e?.doc.eq(t.state.doc);this.updateHandler(t,l,r,e)}getShouldShow(t){var e;const{state:i}=this.view,{selection:s}=i,{ranges:l}=s,r=Math.min(...l.map(d=>d.$from.pos)),n=Math.max(...l.map(d=>d.$to.pos));return((e=this.shouldShow)===null||e===void 0?void 0:e.call(this,{editor:this.editor,element:this.element,view:this.view,state:i,oldState:t,from:r,to:n}))||!1}show(){var t;if(this.isVisible)return;this.element.style.visibility="visible",this.element.style.opacity="1";const e=typeof this.appendTo=="function"?this.appendTo():this.appendTo;(t=e??this.view.dom.parentElement)===null||t===void 0||t.appendChild(this.element),this.floatingUIOptions.onShow&&this.floatingUIOptions.onShow(),this.isVisible=!0}hide(){this.isVisible&&(this.element.style.visibility="hidden",this.element.style.opacity="0",this.element.remove(),this.floatingUIOptions.onHide&&this.floatingUIOptions.onHide(),this.isVisible=!1)}updateOptions(t){if(t.updateDelay!==void 0&&(this.updateDelay=t.updateDelay),t.resizeDelay!==void 0&&(this.resizeDelay=t.resizeDelay),t.appendTo!==void 0&&(this.appendTo=t.appendTo),t.getReferencedVirtualElement!==void 0&&(this.getReferencedVirtualElement=t.getReferencedVirtualElement),t.shouldShow!==void 0&&t.shouldShow&&(this.shouldShow=t.shouldShow),t.options!==void 0){var e;const i=(e=t.options.scrollTarget)!==null&&e!==void 0?e:window;i!==this.scrollTarget&&(this.scrollTarget.removeEventListener("scroll",this.resizeHandler),this.scrollTarget=i,this.scrollTarget.addEventListener("scroll",this.resizeHandler)),this.floatingUIOptions={...this.floatingUIOptions,...t.options}}}destroy(){this.hide(),this.element.removeEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.view.dom.removeEventListener("dragstart",this.dragstartHandler),window.removeEventListener("resize",this.resizeHandler),this.scrollTarget.removeEventListener("scroll",this.resizeHandler),this.editor.off("focus",this.focusHandler),this.editor.off("blur",this.blurHandler),this.editor.off("transaction",this.transactionHandler),this.floatingUIOptions.onDestroy&&this.floatingUIOptions.onDestroy()}};const B=t=>new H({key:typeof t.pluginKey=="string"?new U(t.pluginKey):t.pluginKey,view:e=>new et({view:e,...t})});R.create({name:"bubbleMenu",addOptions(){return{element:null,pluginKey:"bubbleMenu",updateDelay:void 0,appendTo:void 0,shouldShow:null}},addProseMirrorPlugins(){return this.options.element?[B({pluginKey:this.options.pluginKey,editor:this.editor,element:this.options.element,updateDelay:this.options.updateDelay,options:this.options.options,appendTo:this.options.appendTo,getReferencedVirtualElement:this.options.getReferencedVirtualElement,shouldShow:this.options.shouldShow})]:[]}});var it=class{getTextContent(t){return J(t,{textSerializers:Q(this.editor.schema)})}get middlewares(){const t=[];return this.floatingUIOptions.flip&&t.push(C(typeof this.floatingUIOptions.flip!="boolean"?this.floatingUIOptions.flip:void 0)),this.floatingUIOptions.shift&&t.push(M(typeof this.floatingUIOptions.shift!="boolean"?this.floatingUIOptions.shift:void 0)),this.floatingUIOptions.offset&&t.push(P(typeof this.floatingUIOptions.offset!="boolean"?this.floatingUIOptions.offset:void 0)),this.floatingUIOptions.arrow&&t.push(x(this.floatingUIOptions.arrow)),this.floatingUIOptions.size&&t.push(L(typeof this.floatingUIOptions.size!="boolean"?this.floatingUIOptions.size:void 0)),this.floatingUIOptions.autoPlacement&&t.push(V(typeof this.floatingUIOptions.autoPlacement!="boolean"?this.floatingUIOptions.autoPlacement:void 0)),this.floatingUIOptions.hide&&t.push(K(typeof this.floatingUIOptions.hide!="boolean"?this.floatingUIOptions.hide:void 0)),this.floatingUIOptions.inline&&t.push(_(typeof this.floatingUIOptions.inline!="boolean"?this.floatingUIOptions.inline:void 0)),t}constructor({editor:t,element:e,view:i,pluginKey:s="floatingMenu",updateDelay:l=250,resizeDelay:r=60,options:n,appendTo:d,shouldShow:g}){var f;this.preventHide=!1,this.isVisible=!1,this.scrollTarget=window,this.shouldShow=({view:u,state:o})=>{const{selection:a}=o,{$anchor:h,empty:c}=a,m=h.depth===1,y=h.parent.isTextblock&&!h.parent.type.spec.code&&!h.parent.textContent&&h.parent.childCount===0&&!this.getTextContent(h.parent);return!(!u.hasFocus()||!c||!m||!y||!this.editor.isEditable)},this.floatingUIOptions={strategy:"absolute",placement:"right",offset:8,flip:{},shift:{},arrow:!1,size:!1,autoPlacement:!1,hide:!1,inline:!1},this.updateHandler=(u,o,a,h)=>{const{composing:c}=u;if(!(c||!o&&!a)){if(!this.getShouldShow(h)){this.hide();return}this.updatePosition(),this.show()}},this.mousedownHandler=()=>{this.preventHide=!0},this.focusHandler=()=>{setTimeout(()=>this.update(this.editor.view))},this.blurHandler=({event:u})=>{var o;if(this.preventHide){this.preventHide=!1;return}u?.relatedTarget&&(!((o=this.element.parentNode)===null||o===void 0)&&o.contains(u.relatedTarget))||u?.relatedTarget!==this.editor.view.dom&&this.hide()},this.transactionHandler=({transaction:u})=>{const o=u.getMeta(this.pluginKey);o==="updatePosition"?this.updatePosition():o&&typeof o=="object"&&o.type==="updateOptions"?this.updateOptions(o.options):o==="hide"?this.hide():o==="show"&&(this.updatePosition(),this.show())},this.resizeHandler=()=>{this.resizeDebounceTimer&&clearTimeout(this.resizeDebounceTimer),this.resizeDebounceTimer=window.setTimeout(()=>{this.updatePosition()},this.resizeDelay)},this.editor=t,this.element=e,this.view=i,this.pluginKey=s,this.updateDelay=l,this.resizeDelay=r,this.appendTo=d,this.scrollTarget=(f=n?.scrollTarget)!==null&&f!==void 0?f:window,this.floatingUIOptions={...this.floatingUIOptions,...n},this.element.tabIndex=0,g&&(this.shouldShow=g),this.element.addEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.editor.on("focus",this.focusHandler),this.editor.on("blur",this.blurHandler),this.editor.on("transaction",this.transactionHandler),window.addEventListener("resize",this.resizeHandler),this.scrollTarget.addEventListener("scroll",this.resizeHandler),this.update(i,i.state),this.getShouldShow()&&(this.show(),this.updatePosition())}getShouldShow(t){var e;const{state:i}=this.view,{selection:s}=i,{ranges:l}=s,r=Math.min(...l.map(d=>d.$from.pos)),n=Math.max(...l.map(d=>d.$to.pos));return(e=this.shouldShow)===null||e===void 0?void 0:e.call(this,{editor:this.editor,view:this.view,state:i,oldState:t,from:r,to:n})}updateOptions(t){if(t.updateDelay!==void 0&&(this.updateDelay=t.updateDelay),t.resizeDelay!==void 0&&(this.resizeDelay=t.resizeDelay),t.appendTo!==void 0&&(this.appendTo=t.appendTo),t.shouldShow!==void 0&&t.shouldShow&&(this.shouldShow=t.shouldShow),t.options!==void 0){var e;const i=(e=t.options.scrollTarget)!==null&&e!==void 0?e:window;i!==this.scrollTarget&&(this.scrollTarget.removeEventListener("scroll",this.resizeHandler),this.scrollTarget=i,this.scrollTarget.addEventListener("scroll",this.resizeHandler)),this.floatingUIOptions={...this.floatingUIOptions,...t.options}}}updatePosition(){var t;if(!(!((t=this.view)===null||t===void 0||(t=t.dom)===null||t===void 0)&&t.parentNode))return;const{selection:e}=this.editor.state,i=S(this.view,e.from,e.to);A({getBoundingClientRect:()=>i,getClientRects:()=>[i]},this.element,{placement:this.floatingUIOptions.placement,strategy:this.floatingUIOptions.strategy,middleware:this.middlewares}).then(({x:s,y:l,strategy:r,middlewareData:n})=>{var d,g;if(!((d=n.hide)===null||d===void 0)&&d.referenceHidden||!((g=n.hide)===null||g===void 0)&&g.escaped){this.element.style.visibility="hidden";return}this.element.style.visibility="visible",this.element.style.width="max-content",this.element.style.position=r,this.element.style.left=`${s}px`,this.element.style.top=`${l}px`,this.isVisible&&this.floatingUIOptions.onUpdate&&this.floatingUIOptions.onUpdate()})}update(t,e){const i=!e?.selection.eq(t.state.selection),s=!e?.doc.eq(t.state.doc);this.updateHandler(t,i,s,e)}show(){var t;if(this.isVisible)return;this.element.style.visibility="visible",this.element.style.opacity="1";const e=typeof this.appendTo=="function"?this.appendTo():this.appendTo;(t=e??this.view.dom.parentElement)===null||t===void 0||t.appendChild(this.element),this.floatingUIOptions.onShow&&this.floatingUIOptions.onShow(),this.isVisible=!0}hide(){this.isVisible&&(this.element.style.visibility="hidden",this.element.style.opacity="0",this.element.remove(),this.floatingUIOptions.onHide&&this.floatingUIOptions.onHide(),this.isVisible=!1)}destroy(){this.hide(),this.element.removeEventListener("mousedown",this.mousedownHandler,{capture:!0}),window.removeEventListener("resize",this.resizeHandler),this.scrollTarget.removeEventListener("scroll",this.resizeHandler),this.editor.off("focus",this.focusHandler),this.editor.off("blur",this.blurHandler),this.editor.off("transaction",this.transactionHandler),this.floatingUIOptions.onDestroy&&this.floatingUIOptions.onDestroy()}};const F=t=>new H({key:typeof t.pluginKey=="string"?new U(t.pluginKey):t.pluginKey,view:e=>new it({view:e,...t})});R.create({name:"floatingMenu",addOptions(){return{element:null,options:{},pluginKey:"floatingMenu",updateDelay:void 0,resizeDelay:void 0,appendTo:void 0,shouldShow:null}},addCommands(){return{updateFloatingMenuPosition:()=>({tr:t,dispatch:e})=>(e&&t.setMeta(this.options.pluginKey,"updatePosition"),!0)}},addProseMirrorPlugins(){return this.options.element?[F({pluginKey:this.options.pluginKey,editor:this.editor,element:this.options.element,updateDelay:this.options.updateDelay,resizeDelay:this.options.resizeDelay,options:this.options.options,appendTo:this.options.appendTo,shouldShow:this.options.shouldShow})]:[]}});function W(t,e){return t??new U(e)}const st=typeof window<"u"?p.useLayoutEffect:p.useEffect,j=new Set(["left","opacity","position","top","visibility","width"]),nt=new Set(["animationIterationCount","aspectRatio","borderImageOutset","borderImageSlice","borderImageWidth","columnCount","columns","fillOpacity","flex","flexGrow","flexShrink","fontWeight","gridArea","gridColumn","gridColumnEnd","gridColumnStart","gridRow","gridRowEnd","gridRowStart","lineClamp","lineHeight","opacity","order","orphans","scale","stopOpacity","strokeDasharray","strokeDashoffset","strokeMiterlimit","strokeOpacity","strokeWidth","tabSize","widows","zIndex","zoom"]),ot=new Set(["children","className","style"]),rt=new Set(["tabIndex"]),lt=new Set(["accessKey","autoCapitalize","contentEditable","contextMenu","dir","draggable","enterKeyHint","hidden","id","lang","nonce","role","slot","spellCheck","tabIndex","title","translate"]),at={Blur:"focusout",DoubleClick:"dblclick",Focus:"focusin",MouseEnter:"mouseenter",MouseLeave:"mouseleave"};function T(t,e){return/^on[A-Z]/.test(t)&&typeof e=="function"}function dt(t){return t.startsWith("aria-")||t.startsWith("data-"),t}function ut(t){return t.startsWith("aria-")||t.startsWith("data-")||lt.has(t)}function q(t){return t.startsWith("--")?t:t.replace(/[A-Z]/g,e=>`-${e.toLowerCase()}`)}function ht(t){var e;const i=t.endsWith("Capture"),s=(i?t.slice(0,-7):t).slice(2);return{eventName:(e=at[s])!==null&&e!==void 0?e:s.toLowerCase(),options:i?{capture:!0}:void 0}}function ct(t,e){let i=e.defaultPrevented,s=!1;const l=Object.create(e);return Object.defineProperties(l,{nativeEvent:{value:e},currentTarget:{value:t},target:{value:e.target},persist:{value:()=>{}},isDefaultPrevented:{value:()=>i},isPropagationStopped:{value:()=>s},preventDefault:{value:()=>{i=!0,e.preventDefault()}},stopPropagation:{value:()=>{s=!0,e.stopPropagation()}}}),l}function E(t){return rt.has(t)}function D(t,e,i){if(e==="tabIndex"){t.tabIndex=Number(i);return}t[e]=i}function ft(t,e){if(e==="tabIndex"){t.removeAttribute("tabindex");return}const i=t[e];if(typeof i=="boolean"){t[e]=!1;return}if(typeof i=="number"){t[e]=0;return}t[e]=""}function pt(t,e){return typeof e!="number"||e===0||t.startsWith("--")||nt.has(t)?String(e):`${e}px`}function gt(t,e){j.has(e)||t.style.removeProperty(q(e))}function mt(t,e,i){j.has(e)||t.style.setProperty(q(e),pt(e,i))}function vt(t,e,i){new Set([...Object.keys(e),...Object.keys(i)]).forEach(s=>{if(ot.has(s)||!ut(s)||T(s,e[s])||T(s,i[s]))return;const l=e[s],r=i[s];if(l===r)return;const n=dt(s);if(r==null||r===!1){E(s)&&ft(t,s),t.removeAttribute(n);return}if(r===!0){E(s)&&D(t,s,!0),t.setAttribute(n,"");return}if(E(s)){D(t,s,r);return}t.setAttribute(n,String(r))})}function yt(t,e,i){if(e!==i){if(i){t.className=i;return}t.removeAttribute("class")}}function bt(t,e,i){const s=e??{},l=i??{};new Set([...Object.keys(s),...Object.keys(l)]).forEach(r=>{const n=s[r],d=l[r];if(n!==d){if(d==null){gt(t,r);return}mt(t,r,d)}})}function wt(t,e,i){e.forEach(({eventName:l,listener:r,options:n})=>{t.removeEventListener(l,r,n)});const s=[];return Object.entries(i).forEach(([l,r])=>{if(!T(l,r))return;const{eventName:n,options:d}=ht(l),g=f=>{r(ct(t,f))};t.addEventListener(n,g,d),s.push({eventName:n,listener:g,options:d})}),s}function Y(t,e){const i=p.useRef({}),s=p.useRef([]);st(()=>{const l=i.current;return yt(t,l.className,e.className),bt(t,l.style,e.style),vt(t,l,e),s.current=wt(t,s.current,e),i.current=e,()=>{s.current.forEach(({eventName:r,listener:n,options:d})=>{t.removeEventListener(r,n,d)}),s.current=[]}},[t,e])}const Tt=N.forwardRef(({pluginKey:t,editor:e,updateDelay:i,resizeDelay:s,appendTo:l,shouldShow:r=null,getReferencedVirtualElement:n,options:d,children:g,...f},u)=>{const o=p.useRef(document.createElement("div")),a=p.useRef(W(t,"bubbleMenu")).current;Y(o.current,f),typeof u=="function"?u(o.current):u&&(u.current=o.current);const{editor:h}=z(),c=e||h,m={updateDelay:i,resizeDelay:s,appendTo:l,pluginKey:a,shouldShow:r,getReferencedVirtualElement:n,options:d},y=p.useRef(m);y.current=m;const[O,b]=p.useState(!1),v=p.useRef(!0);return p.useEffect(()=>{if(c?.isDestroyed)return;if(!c){console.warn("BubbleMenu component is not rendered inside of an editor component or does not have editor prop.");return}const w=o.current;w.style.visibility="hidden",w.style.position="absolute";const I=B({...y.current,editor:c,element:w});c.registerPlugin(I);const G=y.current.pluginKey;return v.current=!0,b(!0),()=>{b(!1),c.unregisterPlugin(G),window.requestAnimationFrame(()=>{w.parentNode&&w.parentNode.removeChild(w)})}},[c]),p.useEffect(()=>{if(!(!O||!c||c.isDestroyed)){if(v.current){v.current=!1;return}c.view.dispatch(c.state.tr.setMeta(a,{type:"updateOptions",options:y.current}))}},[O,c,i,s,r,d,l,n,a]),$.createPortal(g,o.current)});N.forwardRef(({pluginKey:t,editor:e,updateDelay:i,resizeDelay:s,appendTo:l,shouldShow:r=null,options:n,children:d,...g},f)=>{const u=p.useRef(document.createElement("div")),o=p.useRef(W(t,"floatingMenu")).current;Y(u.current,g),typeof f=="function"?f(u.current):f&&(f.current=u.current);const{editor:a}=z(),h=e||a,c={updateDelay:i,resizeDelay:s,appendTo:l,pluginKey:o,shouldShow:r,options:n},m=p.useRef(c);m.current=c;const[y,O]=p.useState(!1),b=p.useRef(!0);return p.useEffect(()=>{if(h?.isDestroyed)return;if(!h){console.warn("FloatingMenu component is not rendered inside of an editor component or does not have editor prop.");return}const v=u.current;v.style.visibility="hidden",v.style.position="absolute";const w=F({...m.current,editor:h,element:v});h.registerPlugin(w);const I=m.current.pluginKey;return b.current=!0,O(!0),()=>{O(!1),h.unregisterPlugin(I),window.requestAnimationFrame(()=>{v.parentNode&&v.parentNode.removeChild(v)})}},[h]),p.useEffect(()=>{if(!(!y||!h||h.isDestroyed)){if(b.current){b.current=!1;return}h.view.dispatch(h.state.tr.setMeta(o,{type:"updateOptions",options:m.current}))}},[y,h,i,s,r,n,l,o]),$.createPortal(d,u.current)});export{Tt as B};
1
+ import{A as H,t as U,a9 as S,C as Z,aa as X,f as R,ab as J,ac as Q,o as z}from"./usage-stats-BHc1sfxR.js";import{gA as C,hk as M,gz as P,hl as x,hm as L,hn as V,ho as K,hp as _,gC as A,eT as N,r as p,ca as $}from"./index-DokE5sNF.js";import{C as k}from"./index-C1rZOaeR.js";function tt(t,e){const i=Math.min(t.top,e.top),s=Math.max(t.bottom,e.bottom),l=Math.min(t.left,e.left),r=Math.max(t.right,e.right)-l,n=s-i;return new DOMRect(l,i,r,n)}var et=class{get middlewares(){const t=[];return this.floatingUIOptions.flip&&t.push(C(typeof this.floatingUIOptions.flip!="boolean"?this.floatingUIOptions.flip:void 0)),this.floatingUIOptions.shift&&t.push(M(typeof this.floatingUIOptions.shift!="boolean"?this.floatingUIOptions.shift:void 0)),this.floatingUIOptions.offset&&t.push(P(typeof this.floatingUIOptions.offset!="boolean"?this.floatingUIOptions.offset:void 0)),this.floatingUIOptions.arrow&&t.push(x(this.floatingUIOptions.arrow)),this.floatingUIOptions.size&&t.push(L(typeof this.floatingUIOptions.size!="boolean"?this.floatingUIOptions.size:void 0)),this.floatingUIOptions.autoPlacement&&t.push(V(typeof this.floatingUIOptions.autoPlacement!="boolean"?this.floatingUIOptions.autoPlacement:void 0)),this.floatingUIOptions.hide&&t.push(K(typeof this.floatingUIOptions.hide!="boolean"?this.floatingUIOptions.hide:void 0)),this.floatingUIOptions.inline&&t.push(_(typeof this.floatingUIOptions.inline!="boolean"?this.floatingUIOptions.inline:void 0)),t}get virtualElement(){var t,e;const{selection:i}=this.editor.state,s=(t=this.getReferencedVirtualElement)===null||t===void 0?void 0:t.call(this);if(s)return s;if(!(!((e=this.view)===null||e===void 0||(e=e.dom)===null||e===void 0)&&e.parentNode))return;const l=S(this.view,i.from,i.to);let r={getBoundingClientRect:()=>l,getClientRects:()=>[l]};if(i instanceof Z){let n=this.view.nodeDOM(i.from);const d=n.dataset.nodeViewWrapper?n:n.querySelector("[data-node-view-wrapper]");d&&(n=d),n&&(r={getBoundingClientRect:()=>n.getBoundingClientRect(),getClientRects:()=>[n.getBoundingClientRect()]})}if(i instanceof k){const{$anchorCell:n,$headCell:d}=i,g=n?n.pos:d.pos,f=d?d.pos:n.pos,u=this.view.nodeDOM(g),o=this.view.nodeDOM(f);if(!u||!o)return;const a=u===o?u.getBoundingClientRect():tt(u.getBoundingClientRect(),o.getBoundingClientRect());r={getBoundingClientRect:()=>a,getClientRects:()=>[a]}}return r}constructor({editor:t,element:e,view:i,pluginKey:s="bubbleMenu",updateDelay:l=250,resizeDelay:r=60,shouldShow:n,appendTo:d,getReferencedVirtualElement:g,options:f}){var u;this.preventHide=!1,this.isVisible=!1,this.scrollTarget=window,this.floatingUIOptions={strategy:"absolute",placement:"top",offset:8,flip:{},shift:{},arrow:!1,size:!1,autoPlacement:!1,hide:!1,inline:!1,onShow:void 0,onHide:void 0,onUpdate:void 0,onDestroy:void 0},this.shouldShow=({view:o,state:a,from:h,to:c})=>{const{doc:m,selection:y}=a,{empty:O}=y,b=!m.textBetween(h,c).length&&X(a.selection),v=this.element.contains(document.activeElement);return!(!(o.hasFocus()||v)||O||b||!this.editor.isEditable)},this.mousedownHandler=()=>{this.preventHide=!0},this.dragstartHandler=()=>{this.hide()},this.resizeHandler=()=>{this.resizeDebounceTimer&&clearTimeout(this.resizeDebounceTimer),this.resizeDebounceTimer=window.setTimeout(()=>{this.updatePosition()},this.resizeDelay)},this.focusHandler=()=>{setTimeout(()=>this.update(this.editor.view))},this.blurHandler=({event:o})=>{var a;if(this.editor.isDestroyed){this.destroy();return}if(this.preventHide){this.preventHide=!1;return}o?.relatedTarget&&(!((a=this.element.parentNode)===null||a===void 0)&&a.contains(o.relatedTarget))||o?.relatedTarget!==this.editor.view.dom&&this.hide()},this.handleDebouncedUpdate=(o,a)=>{const h=!a?.selection.eq(o.state.selection),c=!a?.doc.eq(o.state.doc);!h&&!c||(this.updateDebounceTimer&&clearTimeout(this.updateDebounceTimer),this.updateDebounceTimer=window.setTimeout(()=>{this.updateHandler(o,h,c,a)},this.updateDelay))},this.updateHandler=(o,a,h,c)=>{const{composing:m}=o;if(!(m||!a&&!h)){if(!this.getShouldShow(c)){this.hide();return}this.show(),this.updatePosition()}},this.transactionHandler=({transaction:o})=>{const a=o.getMeta(this.pluginKey);a==="updatePosition"?this.updatePosition():a&&typeof a=="object"&&a.type==="updateOptions"?this.updateOptions(a.options):a==="hide"?this.hide():a==="show"&&(this.updatePosition(),this.show())},this.editor=t,this.element=e,this.view=i,this.pluginKey=s,this.updateDelay=l,this.resizeDelay=r,this.appendTo=d,this.scrollTarget=(u=f?.scrollTarget)!==null&&u!==void 0?u:window,this.getReferencedVirtualElement=g,this.floatingUIOptions={...this.floatingUIOptions,...f},this.element.tabIndex=0,n&&(this.shouldShow=n),this.element.addEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.view.dom.addEventListener("dragstart",this.dragstartHandler),this.editor.on("focus",this.focusHandler),this.editor.on("blur",this.blurHandler),this.editor.on("transaction",this.transactionHandler),window.addEventListener("resize",this.resizeHandler),this.scrollTarget.addEventListener("scroll",this.resizeHandler),this.update(i,i.state),this.getShouldShow()&&(this.show(),this.updatePosition())}updatePosition(){if(!this.isVisible)return;const t=this.virtualElement;t&&A(t,this.element,{placement:this.floatingUIOptions.placement,strategy:this.floatingUIOptions.strategy,middleware:this.middlewares}).then(({x:e,y:i,strategy:s,middlewareData:l})=>{var r,n;if(!(!this.isVisible||this.editor.isDestroyed||!this.element.isConnected)){if(!((r=l.hide)===null||r===void 0)&&r.referenceHidden||!((n=l.hide)===null||n===void 0)&&n.escaped){this.element.style.visibility="hidden";return}this.element.style.visibility="visible",this.element.style.width="max-content",this.element.style.position=s,this.element.style.left=`${e}px`,this.element.style.top=`${i}px`,this.isVisible&&this.floatingUIOptions.onUpdate&&this.floatingUIOptions.onUpdate()}})}update(t,e){const{state:i}=t,s=i.selection.from!==i.selection.to;if(this.updateDelay>0&&s){this.handleDebouncedUpdate(t,e);return}const l=!e?.selection.eq(t.state.selection),r=!e?.doc.eq(t.state.doc);this.updateHandler(t,l,r,e)}getShouldShow(t){var e;const{state:i}=this.view,{selection:s}=i,{ranges:l}=s,r=Math.min(...l.map(d=>d.$from.pos)),n=Math.max(...l.map(d=>d.$to.pos));return((e=this.shouldShow)===null||e===void 0?void 0:e.call(this,{editor:this.editor,element:this.element,view:this.view,state:i,oldState:t,from:r,to:n}))||!1}show(){var t;if(this.isVisible)return;this.element.style.visibility="visible",this.element.style.opacity="1";const e=typeof this.appendTo=="function"?this.appendTo():this.appendTo;(t=e??this.view.dom.parentElement)===null||t===void 0||t.appendChild(this.element),this.floatingUIOptions.onShow&&this.floatingUIOptions.onShow(),this.isVisible=!0}hide(){this.isVisible&&(this.element.style.visibility="hidden",this.element.style.opacity="0",this.element.remove(),this.floatingUIOptions.onHide&&this.floatingUIOptions.onHide(),this.isVisible=!1)}updateOptions(t){if(t.updateDelay!==void 0&&(this.updateDelay=t.updateDelay),t.resizeDelay!==void 0&&(this.resizeDelay=t.resizeDelay),t.appendTo!==void 0&&(this.appendTo=t.appendTo),t.getReferencedVirtualElement!==void 0&&(this.getReferencedVirtualElement=t.getReferencedVirtualElement),t.shouldShow!==void 0&&t.shouldShow&&(this.shouldShow=t.shouldShow),t.options!==void 0){var e;const i=(e=t.options.scrollTarget)!==null&&e!==void 0?e:window;i!==this.scrollTarget&&(this.scrollTarget.removeEventListener("scroll",this.resizeHandler),this.scrollTarget=i,this.scrollTarget.addEventListener("scroll",this.resizeHandler)),this.floatingUIOptions={...this.floatingUIOptions,...t.options}}}destroy(){this.hide(),this.element.removeEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.view.dom.removeEventListener("dragstart",this.dragstartHandler),window.removeEventListener("resize",this.resizeHandler),this.scrollTarget.removeEventListener("scroll",this.resizeHandler),this.editor.off("focus",this.focusHandler),this.editor.off("blur",this.blurHandler),this.editor.off("transaction",this.transactionHandler),this.floatingUIOptions.onDestroy&&this.floatingUIOptions.onDestroy()}};const B=t=>new H({key:typeof t.pluginKey=="string"?new U(t.pluginKey):t.pluginKey,view:e=>new et({view:e,...t})});R.create({name:"bubbleMenu",addOptions(){return{element:null,pluginKey:"bubbleMenu",updateDelay:void 0,appendTo:void 0,shouldShow:null}},addProseMirrorPlugins(){return this.options.element?[B({pluginKey:this.options.pluginKey,editor:this.editor,element:this.options.element,updateDelay:this.options.updateDelay,options:this.options.options,appendTo:this.options.appendTo,getReferencedVirtualElement:this.options.getReferencedVirtualElement,shouldShow:this.options.shouldShow})]:[]}});var it=class{getTextContent(t){return J(t,{textSerializers:Q(this.editor.schema)})}get middlewares(){const t=[];return this.floatingUIOptions.flip&&t.push(C(typeof this.floatingUIOptions.flip!="boolean"?this.floatingUIOptions.flip:void 0)),this.floatingUIOptions.shift&&t.push(M(typeof this.floatingUIOptions.shift!="boolean"?this.floatingUIOptions.shift:void 0)),this.floatingUIOptions.offset&&t.push(P(typeof this.floatingUIOptions.offset!="boolean"?this.floatingUIOptions.offset:void 0)),this.floatingUIOptions.arrow&&t.push(x(this.floatingUIOptions.arrow)),this.floatingUIOptions.size&&t.push(L(typeof this.floatingUIOptions.size!="boolean"?this.floatingUIOptions.size:void 0)),this.floatingUIOptions.autoPlacement&&t.push(V(typeof this.floatingUIOptions.autoPlacement!="boolean"?this.floatingUIOptions.autoPlacement:void 0)),this.floatingUIOptions.hide&&t.push(K(typeof this.floatingUIOptions.hide!="boolean"?this.floatingUIOptions.hide:void 0)),this.floatingUIOptions.inline&&t.push(_(typeof this.floatingUIOptions.inline!="boolean"?this.floatingUIOptions.inline:void 0)),t}constructor({editor:t,element:e,view:i,pluginKey:s="floatingMenu",updateDelay:l=250,resizeDelay:r=60,options:n,appendTo:d,shouldShow:g}){var f;this.preventHide=!1,this.isVisible=!1,this.scrollTarget=window,this.shouldShow=({view:u,state:o})=>{const{selection:a}=o,{$anchor:h,empty:c}=a,m=h.depth===1,y=h.parent.isTextblock&&!h.parent.type.spec.code&&!h.parent.textContent&&h.parent.childCount===0&&!this.getTextContent(h.parent);return!(!u.hasFocus()||!c||!m||!y||!this.editor.isEditable)},this.floatingUIOptions={strategy:"absolute",placement:"right",offset:8,flip:{},shift:{},arrow:!1,size:!1,autoPlacement:!1,hide:!1,inline:!1},this.updateHandler=(u,o,a,h)=>{const{composing:c}=u;if(!(c||!o&&!a)){if(!this.getShouldShow(h)){this.hide();return}this.updatePosition(),this.show()}},this.mousedownHandler=()=>{this.preventHide=!0},this.focusHandler=()=>{setTimeout(()=>this.update(this.editor.view))},this.blurHandler=({event:u})=>{var o;if(this.preventHide){this.preventHide=!1;return}u?.relatedTarget&&(!((o=this.element.parentNode)===null||o===void 0)&&o.contains(u.relatedTarget))||u?.relatedTarget!==this.editor.view.dom&&this.hide()},this.transactionHandler=({transaction:u})=>{const o=u.getMeta(this.pluginKey);o==="updatePosition"?this.updatePosition():o&&typeof o=="object"&&o.type==="updateOptions"?this.updateOptions(o.options):o==="hide"?this.hide():o==="show"&&(this.updatePosition(),this.show())},this.resizeHandler=()=>{this.resizeDebounceTimer&&clearTimeout(this.resizeDebounceTimer),this.resizeDebounceTimer=window.setTimeout(()=>{this.updatePosition()},this.resizeDelay)},this.editor=t,this.element=e,this.view=i,this.pluginKey=s,this.updateDelay=l,this.resizeDelay=r,this.appendTo=d,this.scrollTarget=(f=n?.scrollTarget)!==null&&f!==void 0?f:window,this.floatingUIOptions={...this.floatingUIOptions,...n},this.element.tabIndex=0,g&&(this.shouldShow=g),this.element.addEventListener("mousedown",this.mousedownHandler,{capture:!0}),this.editor.on("focus",this.focusHandler),this.editor.on("blur",this.blurHandler),this.editor.on("transaction",this.transactionHandler),window.addEventListener("resize",this.resizeHandler),this.scrollTarget.addEventListener("scroll",this.resizeHandler),this.update(i,i.state),this.getShouldShow()&&(this.show(),this.updatePosition())}getShouldShow(t){var e;const{state:i}=this.view,{selection:s}=i,{ranges:l}=s,r=Math.min(...l.map(d=>d.$from.pos)),n=Math.max(...l.map(d=>d.$to.pos));return(e=this.shouldShow)===null||e===void 0?void 0:e.call(this,{editor:this.editor,view:this.view,state:i,oldState:t,from:r,to:n})}updateOptions(t){if(t.updateDelay!==void 0&&(this.updateDelay=t.updateDelay),t.resizeDelay!==void 0&&(this.resizeDelay=t.resizeDelay),t.appendTo!==void 0&&(this.appendTo=t.appendTo),t.shouldShow!==void 0&&t.shouldShow&&(this.shouldShow=t.shouldShow),t.options!==void 0){var e;const i=(e=t.options.scrollTarget)!==null&&e!==void 0?e:window;i!==this.scrollTarget&&(this.scrollTarget.removeEventListener("scroll",this.resizeHandler),this.scrollTarget=i,this.scrollTarget.addEventListener("scroll",this.resizeHandler)),this.floatingUIOptions={...this.floatingUIOptions,...t.options}}}updatePosition(){var t;if(!(!((t=this.view)===null||t===void 0||(t=t.dom)===null||t===void 0)&&t.parentNode))return;const{selection:e}=this.editor.state,i=S(this.view,e.from,e.to);A({getBoundingClientRect:()=>i,getClientRects:()=>[i]},this.element,{placement:this.floatingUIOptions.placement,strategy:this.floatingUIOptions.strategy,middleware:this.middlewares}).then(({x:s,y:l,strategy:r,middlewareData:n})=>{var d,g;if(!((d=n.hide)===null||d===void 0)&&d.referenceHidden||!((g=n.hide)===null||g===void 0)&&g.escaped){this.element.style.visibility="hidden";return}this.element.style.visibility="visible",this.element.style.width="max-content",this.element.style.position=r,this.element.style.left=`${s}px`,this.element.style.top=`${l}px`,this.isVisible&&this.floatingUIOptions.onUpdate&&this.floatingUIOptions.onUpdate()})}update(t,e){const i=!e?.selection.eq(t.state.selection),s=!e?.doc.eq(t.state.doc);this.updateHandler(t,i,s,e)}show(){var t;if(this.isVisible)return;this.element.style.visibility="visible",this.element.style.opacity="1";const e=typeof this.appendTo=="function"?this.appendTo():this.appendTo;(t=e??this.view.dom.parentElement)===null||t===void 0||t.appendChild(this.element),this.floatingUIOptions.onShow&&this.floatingUIOptions.onShow(),this.isVisible=!0}hide(){this.isVisible&&(this.element.style.visibility="hidden",this.element.style.opacity="0",this.element.remove(),this.floatingUIOptions.onHide&&this.floatingUIOptions.onHide(),this.isVisible=!1)}destroy(){this.hide(),this.element.removeEventListener("mousedown",this.mousedownHandler,{capture:!0}),window.removeEventListener("resize",this.resizeHandler),this.scrollTarget.removeEventListener("scroll",this.resizeHandler),this.editor.off("focus",this.focusHandler),this.editor.off("blur",this.blurHandler),this.editor.off("transaction",this.transactionHandler),this.floatingUIOptions.onDestroy&&this.floatingUIOptions.onDestroy()}};const F=t=>new H({key:typeof t.pluginKey=="string"?new U(t.pluginKey):t.pluginKey,view:e=>new it({view:e,...t})});R.create({name:"floatingMenu",addOptions(){return{element:null,options:{},pluginKey:"floatingMenu",updateDelay:void 0,resizeDelay:void 0,appendTo:void 0,shouldShow:null}},addCommands(){return{updateFloatingMenuPosition:()=>({tr:t,dispatch:e})=>(e&&t.setMeta(this.options.pluginKey,"updatePosition"),!0)}},addProseMirrorPlugins(){return this.options.element?[F({pluginKey:this.options.pluginKey,editor:this.editor,element:this.options.element,updateDelay:this.options.updateDelay,resizeDelay:this.options.resizeDelay,options:this.options.options,appendTo:this.options.appendTo,shouldShow:this.options.shouldShow})]:[]}});function W(t,e){return t??new U(e)}const st=typeof window<"u"?p.useLayoutEffect:p.useEffect,j=new Set(["left","opacity","position","top","visibility","width"]),nt=new Set(["animationIterationCount","aspectRatio","borderImageOutset","borderImageSlice","borderImageWidth","columnCount","columns","fillOpacity","flex","flexGrow","flexShrink","fontWeight","gridArea","gridColumn","gridColumnEnd","gridColumnStart","gridRow","gridRowEnd","gridRowStart","lineClamp","lineHeight","opacity","order","orphans","scale","stopOpacity","strokeDasharray","strokeDashoffset","strokeMiterlimit","strokeOpacity","strokeWidth","tabSize","widows","zIndex","zoom"]),ot=new Set(["children","className","style"]),rt=new Set(["tabIndex"]),lt=new Set(["accessKey","autoCapitalize","contentEditable","contextMenu","dir","draggable","enterKeyHint","hidden","id","lang","nonce","role","slot","spellCheck","tabIndex","title","translate"]),at={Blur:"focusout",DoubleClick:"dblclick",Focus:"focusin",MouseEnter:"mouseenter",MouseLeave:"mouseleave"};function T(t,e){return/^on[A-Z]/.test(t)&&typeof e=="function"}function dt(t){return t.startsWith("aria-")||t.startsWith("data-"),t}function ut(t){return t.startsWith("aria-")||t.startsWith("data-")||lt.has(t)}function q(t){return t.startsWith("--")?t:t.replace(/[A-Z]/g,e=>`-${e.toLowerCase()}`)}function ht(t){var e;const i=t.endsWith("Capture"),s=(i?t.slice(0,-7):t).slice(2);return{eventName:(e=at[s])!==null&&e!==void 0?e:s.toLowerCase(),options:i?{capture:!0}:void 0}}function ct(t,e){let i=e.defaultPrevented,s=!1;const l=Object.create(e);return Object.defineProperties(l,{nativeEvent:{value:e},currentTarget:{value:t},target:{value:e.target},persist:{value:()=>{}},isDefaultPrevented:{value:()=>i},isPropagationStopped:{value:()=>s},preventDefault:{value:()=>{i=!0,e.preventDefault()}},stopPropagation:{value:()=>{s=!0,e.stopPropagation()}}}),l}function E(t){return rt.has(t)}function D(t,e,i){if(e==="tabIndex"){t.tabIndex=Number(i);return}t[e]=i}function ft(t,e){if(e==="tabIndex"){t.removeAttribute("tabindex");return}const i=t[e];if(typeof i=="boolean"){t[e]=!1;return}if(typeof i=="number"){t[e]=0;return}t[e]=""}function pt(t,e){return typeof e!="number"||e===0||t.startsWith("--")||nt.has(t)?String(e):`${e}px`}function gt(t,e){j.has(e)||t.style.removeProperty(q(e))}function mt(t,e,i){j.has(e)||t.style.setProperty(q(e),pt(e,i))}function vt(t,e,i){new Set([...Object.keys(e),...Object.keys(i)]).forEach(s=>{if(ot.has(s)||!ut(s)||T(s,e[s])||T(s,i[s]))return;const l=e[s],r=i[s];if(l===r)return;const n=dt(s);if(r==null||r===!1){E(s)&&ft(t,s),t.removeAttribute(n);return}if(r===!0){E(s)&&D(t,s,!0),t.setAttribute(n,"");return}if(E(s)){D(t,s,r);return}t.setAttribute(n,String(r))})}function yt(t,e,i){if(e!==i){if(i){t.className=i;return}t.removeAttribute("class")}}function bt(t,e,i){const s=e??{},l=i??{};new Set([...Object.keys(s),...Object.keys(l)]).forEach(r=>{const n=s[r],d=l[r];if(n!==d){if(d==null){gt(t,r);return}mt(t,r,d)}})}function wt(t,e,i){e.forEach(({eventName:l,listener:r,options:n})=>{t.removeEventListener(l,r,n)});const s=[];return Object.entries(i).forEach(([l,r])=>{if(!T(l,r))return;const{eventName:n,options:d}=ht(l),g=f=>{r(ct(t,f))};t.addEventListener(n,g,d),s.push({eventName:n,listener:g,options:d})}),s}function Y(t,e){const i=p.useRef({}),s=p.useRef([]);st(()=>{const l=i.current;return yt(t,l.className,e.className),bt(t,l.style,e.style),vt(t,l,e),s.current=wt(t,s.current,e),i.current=e,()=>{s.current.forEach(({eventName:r,listener:n,options:d})=>{t.removeEventListener(r,n,d)}),s.current=[]}},[t,e])}const Tt=N.forwardRef(({pluginKey:t,editor:e,updateDelay:i,resizeDelay:s,appendTo:l,shouldShow:r=null,getReferencedVirtualElement:n,options:d,children:g,...f},u)=>{const o=p.useRef(document.createElement("div")),a=p.useRef(W(t,"bubbleMenu")).current;Y(o.current,f),typeof u=="function"?u(o.current):u&&(u.current=o.current);const{editor:h}=z(),c=e||h,m={updateDelay:i,resizeDelay:s,appendTo:l,pluginKey:a,shouldShow:r,getReferencedVirtualElement:n,options:d},y=p.useRef(m);y.current=m;const[O,b]=p.useState(!1),v=p.useRef(!0);return p.useEffect(()=>{if(c?.isDestroyed)return;if(!c){console.warn("BubbleMenu component is not rendered inside of an editor component or does not have editor prop.");return}const w=o.current;w.style.visibility="hidden",w.style.position="absolute";const I=B({...y.current,editor:c,element:w});c.registerPlugin(I);const G=y.current.pluginKey;return v.current=!0,b(!0),()=>{b(!1),c.unregisterPlugin(G),window.requestAnimationFrame(()=>{w.parentNode&&w.parentNode.removeChild(w)})}},[c]),p.useEffect(()=>{if(!(!O||!c||c.isDestroyed)){if(v.current){v.current=!1;return}c.view.dispatch(c.state.tr.setMeta(a,{type:"updateOptions",options:y.current}))}},[O,c,i,s,r,d,l,n,a]),$.createPortal(g,o.current)});N.forwardRef(({pluginKey:t,editor:e,updateDelay:i,resizeDelay:s,appendTo:l,shouldShow:r=null,options:n,children:d,...g},f)=>{const u=p.useRef(document.createElement("div")),o=p.useRef(W(t,"floatingMenu")).current;Y(u.current,g),typeof f=="function"?f(u.current):f&&(f.current=u.current);const{editor:a}=z(),h=e||a,c={updateDelay:i,resizeDelay:s,appendTo:l,pluginKey:o,shouldShow:r,options:n},m=p.useRef(c);m.current=c;const[y,O]=p.useState(!1),b=p.useRef(!0);return p.useEffect(()=>{if(h?.isDestroyed)return;if(!h){console.warn("FloatingMenu component is not rendered inside of an editor component or does not have editor prop.");return}const v=u.current;v.style.visibility="hidden",v.style.position="absolute";const w=F({...m.current,editor:h,element:v});h.registerPlugin(w);const I=m.current.pluginKey;return b.current=!0,O(!0),()=>{O(!1),h.unregisterPlugin(I),window.requestAnimationFrame(()=>{v.parentNode&&v.parentNode.removeChild(v)})}},[h]),p.useEffect(()=>{if(!(!y||!h||h.isDestroyed)){if(b.current){b.current=!1;return}h.view.dispatch(h.state.tr.setMeta(o,{type:"updateOptions",options:m.current}))}},[y,h,i,s,r,n,l,o]),$.createPortal(d,u.current)});export{Tt as B};
@@ -1 +1 @@
1
- import{c as f,f as p,ax as u,j as s,b7 as x,N as a}from"./index-BuZqAz74.js";import{C as j}from"./capability-load-error-DCoklIp8.js";function d(){const t=f.c(19);let o;t[0]===Symbol.for("react.memo_cache_sentinel")?(o={from:"/shell/$org"},t[0]=o):o=t[0];const{org:r}=p(o),{capabilities:l,isPrivileged:m,loading:g,error:c}=u();if(g){let e;return t[1]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(x,{}),t[1]=e):e=t[1],e}if(c){let e;return t[2]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(j,{}),t[2]=e):e=t[2],e}const i=e=>m||l[e]===!0;if(i("org:manage")){let e;return t[3]!==r?(e=s.jsx(a,{to:"/$org/settings/general",params:{org:r},replace:!0}),t[3]=r,t[4]=e):e=t[4],e}if(i("ai-providers:manage")){let e;return t[5]!==r?(e=s.jsx(a,{to:"/$org/settings/ai-providers",params:{org:r},replace:!0}),t[5]=r,t[6]=e):e=t[6],e}if(i("secrets:manage")){let e;return t[7]!==r?(e=s.jsx(a,{to:"/$org/settings/secrets",params:{org:r},replace:!0}),t[7]=r,t[8]=e):e=t[8],e}if(i("file-configs:manage")){let e;return t[9]!==r?(e=s.jsx(a,{to:"/$org/settings/buckets",params:{org:r},replace:!0}),t[9]=r,t[10]=e):e=t[10],e}if(i("automations:manage")){let e;return t[11]!==r?(e=s.jsx(a,{to:"/$org/settings/automations",params:{org:r},replace:!0}),t[11]=r,t[12]=e):e=t[12],e}if(i("monitoring:view")){let e;return t[13]!==r?(e=s.jsx(a,{to:"/$org/settings/monitor",params:{org:r},replace:!0}),t[13]=r,t[14]=e):e=t[14],e}if(i("members:manage")){let e;return t[15]!==r?(e=s.jsx(a,{to:"/$org/settings/members",params:{org:r},replace:!0}),t[15]=r,t[16]=e):e=t[16],e}let n;return t[17]!==r?(n=s.jsx(a,{to:"/$org/settings/profile",params:{org:r},replace:!0}),t[17]=r,t[18]=n):n=t[18],n}export{d as default};
1
+ import{c as f,f as p,ax as u,j as s,b7 as x,N as a}from"./index-DokE5sNF.js";import{C as j}from"./capability-load-error-DGMDILUu.js";function d(){const t=f.c(19);let o;t[0]===Symbol.for("react.memo_cache_sentinel")?(o={from:"/shell/$org"},t[0]=o):o=t[0];const{org:r}=p(o),{capabilities:l,isPrivileged:m,loading:g,error:c}=u();if(g){let e;return t[1]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(x,{}),t[1]=e):e=t[1],e}if(c){let e;return t[2]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(j,{}),t[2]=e):e=t[2],e}const i=e=>m||l[e]===!0;if(i("org:manage")){let e;return t[3]!==r?(e=s.jsx(a,{to:"/$org/settings/general",params:{org:r},replace:!0}),t[3]=r,t[4]=e):e=t[4],e}if(i("ai-providers:manage")){let e;return t[5]!==r?(e=s.jsx(a,{to:"/$org/settings/ai-providers",params:{org:r},replace:!0}),t[5]=r,t[6]=e):e=t[6],e}if(i("secrets:manage")){let e;return t[7]!==r?(e=s.jsx(a,{to:"/$org/settings/secrets",params:{org:r},replace:!0}),t[7]=r,t[8]=e):e=t[8],e}if(i("file-configs:manage")){let e;return t[9]!==r?(e=s.jsx(a,{to:"/$org/settings/buckets",params:{org:r},replace:!0}),t[9]=r,t[10]=e):e=t[10],e}if(i("automations:manage")){let e;return t[11]!==r?(e=s.jsx(a,{to:"/$org/settings/automations",params:{org:r},replace:!0}),t[11]=r,t[12]=e):e=t[12],e}if(i("monitoring:view")){let e;return t[13]!==r?(e=s.jsx(a,{to:"/$org/settings/monitor",params:{org:r},replace:!0}),t[13]=r,t[14]=e):e=t[14],e}if(i("members:manage")){let e;return t[15]!==r?(e=s.jsx(a,{to:"/$org/settings/members",params:{org:r},replace:!0}),t[15]=r,t[16]=e):e=t[16],e}let n;return t[17]!==r?(n=s.jsx(a,{to:"/$org/settings/profile",params:{org:r},replace:!0}),t[17]=r,t[18]=n):n=t[18],n}export{d as default};
@@ -1 +1 @@
1
- import{r as l,c1 as ce,j as p,c7 as _,c6 as T,c4 as C,cc as le,c0 as de,co as ue,ck as fe,cd as me}from"./index-BuZqAz74.js";import{c as Y}from"./index-BdQq_4o_.js";var $=["PageUp","PageDown"],X=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],G={"from-left":["Home","PageDown","ArrowDown","ArrowLeft"],"from-right":["Home","PageDown","ArrowDown","ArrowRight"],"from-bottom":["Home","PageDown","ArrowDown","ArrowLeft"],"from-top":["Home","PageDown","ArrowUp","ArrowLeft"]},M="Slider",[H,Se,pe]=le(M),[W]=fe(M,[pe]),[he,V]=W(M),q=l.forwardRef((e,t)=>{const{name:o,min:n=0,max:s=100,step:c=1,orientation:r="horizontal",disabled:a=!1,minStepsBetweenThumbs:u=0,defaultValue:w=[n],value:h,onValueChange:i=()=>{},onValueCommit:d=()=>{},inverted:v=!1,form:R,...g}=e,m=l.useRef(new Set),f=l.useRef(0),x=r==="horizontal"?ge:ve,[S=[],K]=ce({prop:h,defaultProp:w,onChange:b=>{[...m.current][f.current]?.focus(),i(b)}}),j=l.useRef(S);function B(b){const y=ye(S,b);I(b,y)}function se(b){I(b,f.current)}function ae(){const b=j.current[f.current];S[f.current]!==b&&d(S)}function I(b,y,{commit:k}={commit:!1}){const U=_e(c),z=Ce(Math.round((b-n)/c)*c+n,U),A=Y(z,[n,s]);K((E=[])=>{const P=be(E,A,y);if(Ee(P,u*c)){f.current=P.indexOf(A);const F=String(P)!==String(E);return F&&k&&d(P),F?P:E}else return E})}return p.jsx(he,{scope:e.__scopeSlider,name:o,disabled:a,min:n,max:s,valueIndexToChangeRef:f,thumbs:m.current,values:S,orientation:r,form:R,children:p.jsx(H.Provider,{scope:e.__scopeSlider,children:p.jsx(H.Slot,{scope:e.__scopeSlider,children:p.jsx(x,{"aria-disabled":a,"data-disabled":a?"":void 0,...g,ref:t,onPointerDown:_(g.onPointerDown,()=>{a||(j.current=S)}),min:n,max:s,inverted:v,onSlideStart:a?void 0:B,onSlideMove:a?void 0:se,onSlideEnd:a?void 0:ae,onHomeKeyDown:()=>!a&&I(n,0,{commit:!0}),onEndKeyDown:()=>!a&&I(s,S.length-1,{commit:!0}),onStepKeyDown:({event:b,direction:y})=>{if(!a){const z=$.includes(b.key)||b.shiftKey&&X.includes(b.key)?10:1,A=f.current,E=S[A],P=c*z*y;I(E+P,A,{commit:!0})}}})})})})});q.displayName=M;var[J,Q]=W(M,{startEdge:"left",endEdge:"right",size:"width",direction:1}),ge=l.forwardRef((e,t)=>{const{min:o,max:n,dir:s,inverted:c,onSlideStart:r,onSlideMove:a,onSlideEnd:u,onStepKeyDown:w,...h}=e,[i,d]=l.useState(null),v=C(t,x=>d(x)),R=l.useRef(void 0),g=de(s),m=g==="ltr",f=m&&!c||!m&&c;function D(x){const S=R.current||i.getBoundingClientRect(),K=[0,S.width],B=O(K,f?[o,n]:[n,o]);return R.current=S,B(x-S.left)}return p.jsx(J,{scope:e.__scopeSlider,startEdge:f?"left":"right",endEdge:f?"right":"left",direction:f?1:-1,size:"width",children:p.jsx(Z,{dir:g,"data-orientation":"horizontal",...h,ref:v,style:{...h.style,"--radix-slider-thumb-transform":"translateX(-50%)"},onSlideStart:x=>{const S=D(x.clientX);r?.(S)},onSlideMove:x=>{const S=D(x.clientX);a?.(S)},onSlideEnd:()=>{R.current=void 0,u?.()},onStepKeyDown:x=>{const K=G[f?"from-left":"from-right"].includes(x.key);w?.({event:x,direction:K?-1:1})}})})}),ve=l.forwardRef((e,t)=>{const{min:o,max:n,inverted:s,onSlideStart:c,onSlideMove:r,onSlideEnd:a,onStepKeyDown:u,...w}=e,h=l.useRef(null),i=C(t,h),d=l.useRef(void 0),v=!s;function R(g){const m=d.current||h.current.getBoundingClientRect(),f=[0,m.height],x=O(f,v?[n,o]:[o,n]);return d.current=m,x(g-m.top)}return p.jsx(J,{scope:e.__scopeSlider,startEdge:v?"bottom":"top",endEdge:v?"top":"bottom",size:"height",direction:v?1:-1,children:p.jsx(Z,{"data-orientation":"vertical",...w,ref:i,style:{...w.style,"--radix-slider-thumb-transform":"translateY(50%)"},onSlideStart:g=>{const m=R(g.clientY);c?.(m)},onSlideMove:g=>{const m=R(g.clientY);r?.(m)},onSlideEnd:()=>{d.current=void 0,a?.()},onStepKeyDown:g=>{const f=G[v?"from-bottom":"from-top"].includes(g.key);u?.({event:g,direction:f?-1:1})}})})}),Z=l.forwardRef((e,t)=>{const{__scopeSlider:o,onSlideStart:n,onSlideMove:s,onSlideEnd:c,onHomeKeyDown:r,onEndKeyDown:a,onStepKeyDown:u,...w}=e,h=V(M,o);return p.jsx(T.span,{...w,ref:t,onKeyDown:_(e.onKeyDown,i=>{i.key==="Home"?(r(i),i.preventDefault()):i.key==="End"?(a(i),i.preventDefault()):$.concat(X).includes(i.key)&&(u(i),i.preventDefault())}),onPointerDown:_(e.onPointerDown,i=>{const d=i.target;d.setPointerCapture(i.pointerId),i.preventDefault(),h.thumbs.has(d)?d.focus():n(i)}),onPointerMove:_(e.onPointerMove,i=>{i.target.hasPointerCapture(i.pointerId)&&s(i)}),onPointerUp:_(e.onPointerUp,i=>{const d=i.target;d.hasPointerCapture(i.pointerId)&&(d.releasePointerCapture(i.pointerId),c(i))})})}),ee="SliderTrack",te=l.forwardRef((e,t)=>{const{__scopeSlider:o,...n}=e,s=V(ee,o);return p.jsx(T.span,{"data-disabled":s.disabled?"":void 0,"data-orientation":s.orientation,...n,ref:t})});te.displayName=ee;var N="SliderRange",ne=l.forwardRef((e,t)=>{const{__scopeSlider:o,...n}=e,s=V(N,o),c=Q(N,o),r=l.useRef(null),a=C(t,r),u=s.values.length,w=s.values.map(d=>ie(d,s.min,s.max)),h=u>1?Math.min(...w):0,i=100-Math.max(...w);return p.jsx(T.span,{"data-orientation":s.orientation,"data-disabled":s.disabled?"":void 0,...n,ref:a,style:{...e.style,[c.startEdge]:h+"%",[c.endEdge]:i+"%"}})});ne.displayName=N;var L="SliderThumb",oe=l.forwardRef((e,t)=>{const o=Se(e.__scopeSlider),[n,s]=l.useState(null),c=C(t,a=>s(a)),r=l.useMemo(()=>n?o().findIndex(a=>a.ref.current===n):-1,[o,n]);return p.jsx(we,{...e,ref:c,index:r})}),we=l.forwardRef((e,t)=>{const{__scopeSlider:o,index:n,name:s,...c}=e,r=V(L,o),a=Q(L,o),[u,w]=l.useState(null),h=C(t,D=>w(D)),i=u?r.form||!!u.closest("form"):!0,d=ue(u),v=r.values[n],R=v===void 0?0:ie(v,r.min,r.max),g=Re(n,r.values.length),m=d?.[a.size],f=m?Pe(m,R,a.direction):0;return l.useEffect(()=>{if(u)return r.thumbs.add(u),()=>{r.thumbs.delete(u)}},[u,r.thumbs]),p.jsxs("span",{style:{transform:"var(--radix-slider-thumb-transform)",position:"absolute",[a.startEdge]:`calc(${R}% + ${f}px)`},children:[p.jsx(H.ItemSlot,{scope:e.__scopeSlider,children:p.jsx(T.span,{role:"slider","aria-label":e["aria-label"]||g,"aria-valuemin":r.min,"aria-valuenow":v,"aria-valuemax":r.max,"aria-orientation":r.orientation,"data-orientation":r.orientation,"data-disabled":r.disabled?"":void 0,tabIndex:r.disabled?void 0:0,...c,ref:h,style:v===void 0?{display:"none"}:e.style,onFocus:_(e.onFocus,()=>{r.valueIndexToChangeRef.current=n})})}),i&&p.jsx(re,{name:s??(r.name?r.name+(r.values.length>1?"[]":""):void 0),form:r.form,value:v},n)]})});oe.displayName=L;var xe="RadioBubbleInput",re=l.forwardRef(({__scopeSlider:e,value:t,...o},n)=>{const s=l.useRef(null),c=C(s,n),r=me(t);return l.useEffect(()=>{const a=s.current;if(!a)return;const u=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(u,"value").set;if(r!==t&&h){const i=new Event("input",{bubbles:!0});h.call(a,t),a.dispatchEvent(i)}},[r,t]),p.jsx(T.input,{style:{display:"none"},...o,ref:c,defaultValue:t})});re.displayName=xe;function be(e=[],t,o){const n=[...e];return n[o]=t,n.sort((s,c)=>s-c)}function ie(e,t,o){const c=100/(o-t)*(e-t);return Y(c,[0,100])}function Re(e,t){return t>2?`Value ${e+1} of ${t}`:t===2?["Minimum","Maximum"][e]:void 0}function ye(e,t){if(e.length===1)return 0;const o=e.map(s=>Math.abs(s-t)),n=Math.min(...o);return o.indexOf(n)}function Pe(e,t,o){const n=e/2,c=O([0,50],[0,n]);return(n-c(t)*o)*o}function De(e){return e.slice(0,-1).map((t,o)=>e[o+1]-t)}function Ee(e,t){if(t>0){const o=De(e);return Math.min(...o)>=t}return!0}function O(e,t){return o=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const n=(t[1]-t[0])/(e[1]-e[0]);return t[0]+n*(o-e[0])}}function _e(e){return(String(e).split(".")[1]||"").length}function Ce(e,t){const o=Math.pow(10,t);return Math.round(e*o)/o}var Ie=q,Ae=te,Te=ne,Ve=oe;export{Te as R,Ae as T,Ie as a,Ve as b};
1
+ import{r as l,c1 as ce,j as p,c7 as _,c6 as T,c4 as C,cc as le,c0 as de,co as ue,ck as fe,cd as me}from"./index-DokE5sNF.js";import{c as Y}from"./index-BdQq_4o_.js";var $=["PageUp","PageDown"],X=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],G={"from-left":["Home","PageDown","ArrowDown","ArrowLeft"],"from-right":["Home","PageDown","ArrowDown","ArrowRight"],"from-bottom":["Home","PageDown","ArrowDown","ArrowLeft"],"from-top":["Home","PageDown","ArrowUp","ArrowLeft"]},M="Slider",[H,Se,pe]=le(M),[W]=fe(M,[pe]),[he,V]=W(M),q=l.forwardRef((e,t)=>{const{name:o,min:n=0,max:s=100,step:c=1,orientation:r="horizontal",disabled:a=!1,minStepsBetweenThumbs:u=0,defaultValue:w=[n],value:h,onValueChange:i=()=>{},onValueCommit:d=()=>{},inverted:v=!1,form:R,...g}=e,m=l.useRef(new Set),f=l.useRef(0),x=r==="horizontal"?ge:ve,[S=[],K]=ce({prop:h,defaultProp:w,onChange:b=>{[...m.current][f.current]?.focus(),i(b)}}),j=l.useRef(S);function B(b){const y=ye(S,b);I(b,y)}function se(b){I(b,f.current)}function ae(){const b=j.current[f.current];S[f.current]!==b&&d(S)}function I(b,y,{commit:k}={commit:!1}){const U=_e(c),z=Ce(Math.round((b-n)/c)*c+n,U),A=Y(z,[n,s]);K((E=[])=>{const P=be(E,A,y);if(Ee(P,u*c)){f.current=P.indexOf(A);const F=String(P)!==String(E);return F&&k&&d(P),F?P:E}else return E})}return p.jsx(he,{scope:e.__scopeSlider,name:o,disabled:a,min:n,max:s,valueIndexToChangeRef:f,thumbs:m.current,values:S,orientation:r,form:R,children:p.jsx(H.Provider,{scope:e.__scopeSlider,children:p.jsx(H.Slot,{scope:e.__scopeSlider,children:p.jsx(x,{"aria-disabled":a,"data-disabled":a?"":void 0,...g,ref:t,onPointerDown:_(g.onPointerDown,()=>{a||(j.current=S)}),min:n,max:s,inverted:v,onSlideStart:a?void 0:B,onSlideMove:a?void 0:se,onSlideEnd:a?void 0:ae,onHomeKeyDown:()=>!a&&I(n,0,{commit:!0}),onEndKeyDown:()=>!a&&I(s,S.length-1,{commit:!0}),onStepKeyDown:({event:b,direction:y})=>{if(!a){const z=$.includes(b.key)||b.shiftKey&&X.includes(b.key)?10:1,A=f.current,E=S[A],P=c*z*y;I(E+P,A,{commit:!0})}}})})})})});q.displayName=M;var[J,Q]=W(M,{startEdge:"left",endEdge:"right",size:"width",direction:1}),ge=l.forwardRef((e,t)=>{const{min:o,max:n,dir:s,inverted:c,onSlideStart:r,onSlideMove:a,onSlideEnd:u,onStepKeyDown:w,...h}=e,[i,d]=l.useState(null),v=C(t,x=>d(x)),R=l.useRef(void 0),g=de(s),m=g==="ltr",f=m&&!c||!m&&c;function D(x){const S=R.current||i.getBoundingClientRect(),K=[0,S.width],B=O(K,f?[o,n]:[n,o]);return R.current=S,B(x-S.left)}return p.jsx(J,{scope:e.__scopeSlider,startEdge:f?"left":"right",endEdge:f?"right":"left",direction:f?1:-1,size:"width",children:p.jsx(Z,{dir:g,"data-orientation":"horizontal",...h,ref:v,style:{...h.style,"--radix-slider-thumb-transform":"translateX(-50%)"},onSlideStart:x=>{const S=D(x.clientX);r?.(S)},onSlideMove:x=>{const S=D(x.clientX);a?.(S)},onSlideEnd:()=>{R.current=void 0,u?.()},onStepKeyDown:x=>{const K=G[f?"from-left":"from-right"].includes(x.key);w?.({event:x,direction:K?-1:1})}})})}),ve=l.forwardRef((e,t)=>{const{min:o,max:n,inverted:s,onSlideStart:c,onSlideMove:r,onSlideEnd:a,onStepKeyDown:u,...w}=e,h=l.useRef(null),i=C(t,h),d=l.useRef(void 0),v=!s;function R(g){const m=d.current||h.current.getBoundingClientRect(),f=[0,m.height],x=O(f,v?[n,o]:[o,n]);return d.current=m,x(g-m.top)}return p.jsx(J,{scope:e.__scopeSlider,startEdge:v?"bottom":"top",endEdge:v?"top":"bottom",size:"height",direction:v?1:-1,children:p.jsx(Z,{"data-orientation":"vertical",...w,ref:i,style:{...w.style,"--radix-slider-thumb-transform":"translateY(50%)"},onSlideStart:g=>{const m=R(g.clientY);c?.(m)},onSlideMove:g=>{const m=R(g.clientY);r?.(m)},onSlideEnd:()=>{d.current=void 0,a?.()},onStepKeyDown:g=>{const f=G[v?"from-bottom":"from-top"].includes(g.key);u?.({event:g,direction:f?-1:1})}})})}),Z=l.forwardRef((e,t)=>{const{__scopeSlider:o,onSlideStart:n,onSlideMove:s,onSlideEnd:c,onHomeKeyDown:r,onEndKeyDown:a,onStepKeyDown:u,...w}=e,h=V(M,o);return p.jsx(T.span,{...w,ref:t,onKeyDown:_(e.onKeyDown,i=>{i.key==="Home"?(r(i),i.preventDefault()):i.key==="End"?(a(i),i.preventDefault()):$.concat(X).includes(i.key)&&(u(i),i.preventDefault())}),onPointerDown:_(e.onPointerDown,i=>{const d=i.target;d.setPointerCapture(i.pointerId),i.preventDefault(),h.thumbs.has(d)?d.focus():n(i)}),onPointerMove:_(e.onPointerMove,i=>{i.target.hasPointerCapture(i.pointerId)&&s(i)}),onPointerUp:_(e.onPointerUp,i=>{const d=i.target;d.hasPointerCapture(i.pointerId)&&(d.releasePointerCapture(i.pointerId),c(i))})})}),ee="SliderTrack",te=l.forwardRef((e,t)=>{const{__scopeSlider:o,...n}=e,s=V(ee,o);return p.jsx(T.span,{"data-disabled":s.disabled?"":void 0,"data-orientation":s.orientation,...n,ref:t})});te.displayName=ee;var N="SliderRange",ne=l.forwardRef((e,t)=>{const{__scopeSlider:o,...n}=e,s=V(N,o),c=Q(N,o),r=l.useRef(null),a=C(t,r),u=s.values.length,w=s.values.map(d=>ie(d,s.min,s.max)),h=u>1?Math.min(...w):0,i=100-Math.max(...w);return p.jsx(T.span,{"data-orientation":s.orientation,"data-disabled":s.disabled?"":void 0,...n,ref:a,style:{...e.style,[c.startEdge]:h+"%",[c.endEdge]:i+"%"}})});ne.displayName=N;var L="SliderThumb",oe=l.forwardRef((e,t)=>{const o=Se(e.__scopeSlider),[n,s]=l.useState(null),c=C(t,a=>s(a)),r=l.useMemo(()=>n?o().findIndex(a=>a.ref.current===n):-1,[o,n]);return p.jsx(we,{...e,ref:c,index:r})}),we=l.forwardRef((e,t)=>{const{__scopeSlider:o,index:n,name:s,...c}=e,r=V(L,o),a=Q(L,o),[u,w]=l.useState(null),h=C(t,D=>w(D)),i=u?r.form||!!u.closest("form"):!0,d=ue(u),v=r.values[n],R=v===void 0?0:ie(v,r.min,r.max),g=Re(n,r.values.length),m=d?.[a.size],f=m?Pe(m,R,a.direction):0;return l.useEffect(()=>{if(u)return r.thumbs.add(u),()=>{r.thumbs.delete(u)}},[u,r.thumbs]),p.jsxs("span",{style:{transform:"var(--radix-slider-thumb-transform)",position:"absolute",[a.startEdge]:`calc(${R}% + ${f}px)`},children:[p.jsx(H.ItemSlot,{scope:e.__scopeSlider,children:p.jsx(T.span,{role:"slider","aria-label":e["aria-label"]||g,"aria-valuemin":r.min,"aria-valuenow":v,"aria-valuemax":r.max,"aria-orientation":r.orientation,"data-orientation":r.orientation,"data-disabled":r.disabled?"":void 0,tabIndex:r.disabled?void 0:0,...c,ref:h,style:v===void 0?{display:"none"}:e.style,onFocus:_(e.onFocus,()=>{r.valueIndexToChangeRef.current=n})})}),i&&p.jsx(re,{name:s??(r.name?r.name+(r.values.length>1?"[]":""):void 0),form:r.form,value:v},n)]})});oe.displayName=L;var xe="RadioBubbleInput",re=l.forwardRef(({__scopeSlider:e,value:t,...o},n)=>{const s=l.useRef(null),c=C(s,n),r=me(t);return l.useEffect(()=>{const a=s.current;if(!a)return;const u=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(u,"value").set;if(r!==t&&h){const i=new Event("input",{bubbles:!0});h.call(a,t),a.dispatchEvent(i)}},[r,t]),p.jsx(T.input,{style:{display:"none"},...o,ref:c,defaultValue:t})});re.displayName=xe;function be(e=[],t,o){const n=[...e];return n[o]=t,n.sort((s,c)=>s-c)}function ie(e,t,o){const c=100/(o-t)*(e-t);return Y(c,[0,100])}function Re(e,t){return t>2?`Value ${e+1} of ${t}`:t===2?["Minimum","Maximum"][e]:void 0}function ye(e,t){if(e.length===1)return 0;const o=e.map(s=>Math.abs(s-t)),n=Math.min(...o);return o.indexOf(n)}function Pe(e,t,o){const n=e/2,c=O([0,50],[0,n]);return(n-c(t)*o)*o}function De(e){return e.slice(0,-1).map((t,o)=>e[o+1]-t)}function Ee(e,t){if(t>0){const o=De(e);return Math.min(...o)>=t}return!0}function O(e,t){return o=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const n=(t[1]-t[0])/(e[1]-e[0]);return t[0]+n*(o-e[0])}}function _e(e){return(String(e).split(".")[1]||"").length}function Ce(e,t){const o=Math.pow(10,t);return Math.round(e*o)/o}var Ie=q,Ae=te,Te=ne,Ve=oe;export{Te as R,Ae as T,Ie as a,Ve as b};
@@ -1 +1 @@
1
- import{e4 as g,e5 as d,e6 as v}from"./index-BuZqAz74.js";var b=class extends g{constructor(e,t){super(e,t)}bindMethods(){super.bindMethods(),this.fetchNextPage=this.fetchNextPage.bind(this),this.fetchPreviousPage=this.fetchPreviousPage.bind(this)}setOptions(e){e._type="infinite",super.setOptions(e)}getOptimisticResult(e){return e._type="infinite",super.getOptimisticResult(e)}fetchNextPage(e){return this.fetch({...e,meta:{fetchMore:{direction:"forward"}}})}fetchPreviousPage(e){return this.fetch({...e,meta:{fetchMore:{direction:"backward"}}})}createResult(e,t){const{state:s}=e,i=super.createResult(e,t),{isFetching:c,isRefetching:u,isError:a,isRefetchError:P}=i,r=s.fetchMeta?.fetchMore?.direction,h=a&&r==="forward",o=c&&r==="forward",n=a&&r==="backward",f=c&&r==="backward";return{...i,fetchNextPage:this.fetchNextPage,fetchPreviousPage:this.fetchPreviousPage,hasNextPage:v(t,s.data),hasPreviousPage:d(t,s.data),isFetchNextPageError:h,isFetchingNextPage:o,isFetchPreviousPageError:n,isFetchingPreviousPage:f,isRefetchError:P&&!h&&!n,isRefetching:u&&!o&&!f}}};export{b as I};
1
+ import{e4 as g,e5 as d,e6 as v}from"./index-DokE5sNF.js";var b=class extends g{constructor(e,t){super(e,t)}bindMethods(){super.bindMethods(),this.fetchNextPage=this.fetchNextPage.bind(this),this.fetchPreviousPage=this.fetchPreviousPage.bind(this)}setOptions(e){e._type="infinite",super.setOptions(e)}getOptimisticResult(e){return e._type="infinite",super.getOptimisticResult(e)}fetchNextPage(e){return this.fetch({...e,meta:{fetchMore:{direction:"forward"}}})}fetchPreviousPage(e){return this.fetch({...e,meta:{fetchMore:{direction:"backward"}}})}createResult(e,t){const{state:s}=e,i=super.createResult(e,t),{isFetching:c,isRefetching:u,isError:a,isRefetchError:P}=i,r=s.fetchMeta?.fetchMore?.direction,h=a&&r==="forward",o=c&&r==="forward",n=a&&r==="backward",f=c&&r==="backward";return{...i,fetchNextPage:this.fetchNextPage,fetchPreviousPage:this.fetchPreviousPage,hasNextPage:v(t,s.data),hasPreviousPage:d(t,s.data),isFetchNextPageError:h,isFetchingNextPage:o,isFetchPreviousPageError:n,isFetchingPreviousPage:f,isRefetchError:P&&!h&&!n,isRefetching:u&&!o&&!f}}};export{b as I};
@@ -1 +1 @@
1
- import{c as k,j as s,i4 as de,b as Z,i5 as ue,r as le,i6 as xe,i7 as re,gG as T,gV as W,B as J,e0 as V,a9 as pe}from"./index-BuZqAz74.js";import{i as he}from"./CreditCard01-CcTQ1h3_.js";import{B as L}from"./badge-BvHOfdxU.js";import{M as je}from"./multi-select-BSuPEET4.js";import{S as be,d as ve,c as Be,a as Ne,b as Se}from"./select-BkYZ4NYA.js";import{T as $,a as ye,b as ie,c as F,d as Te,e as we}from"./table-DQIAY6r-.js";import{C as ke,X as Ue,Y as Ce}from"./CartesianChart-B0LNjIyx.js";import{T as De}from"./Tooltip-C_RHysFo.js";import{a as _e,A as Me}from"./AreaChart-DXqVsicd.js";import{c2 as Re}from"./CategoricalChart-CmAKQrAh.js";import{R as Le}from"./require-capability-DEShAaY8.js";import"./checkbox-DAnVkT6Q.js";import"./Minus-Cc21R1KY.js";import"./ChevronDown-ClblfTVV.js";import"./command-DHGFzOhP.js";import"./index-DsWqYG3w.js";import"./SearchMd-BwYuN52e.js";import"./popover-D6EIL5sL.js";import"./index-BdQq_4o_.js";import"./index-DNuvhcDO.js";import"./ChevronUp-0ZCAxpBW.js";import"./index-BwBEUlXI.js";import"./access-gate-DQ55JjgP.js";import"./capability-load-error-DCoklIp8.js";const Q=new Intl.NumberFormat(void 0,{notation:"compact",maximumFractionDigits:1}),ne=["B","KB","MB","GB","TB","PB"];function oe(t){if(t<=0)return"0 B";const e=Math.min(ne.length-1,Math.floor(Math.log(t)/Math.log(1024))),n=t/1024**e;return`${n.toFixed(n>=100||e===0?0:1)} ${ne[e]}`}const X=50,$e="https://assets.decocache.com/decocms/45f9e905-046b-4aeb-8420-0377a7d0d041/deco_Transferencia.pdf",Fe=new Intl.NumberFormat("pt-BR",{style:"currency",currency:"BRL"});function ce(t){return new Date(`${t.slice(0,10)}T00:00:00Z`)}function ee(t){return ce(t).toLocaleDateString(void 0,{day:"numeric",month:"short",year:"numeric",timeZone:"UTC"})}function Ie(){const t=new Date;return Array.from({length:12},(e,n)=>{const l=new Date(Date.UTC(t.getUTCFullYear(),t.getUTCMonth()-n,1));return{value:l.toISOString().slice(0,10),label:l.toLocaleDateString(void 0,{month:"long",year:"numeric",timeZone:"UTC"})}})}function Pe(t){return new Date(`${t}T00:00:00Z`).toLocaleDateString(void 0,{month:"short",day:"numeric",timeZone:"UTC"})}function ae(t){const e=k.c(30),{usage:n,metric:l,colorNum:o,formatValue:f,height:i}=t,a=`var(--chart-${o})`,d=`infra-billing-${l}`;let g;e[0]!==n?(g=n.map(Ae),e[0]=n,e[1]=g):g=e[1];const x=g;let b;e[2]===Symbol.for("react.memo_cache_sentinel")?(b={left:0,right:4,top:8,bottom:0},e[2]=b):b=e[2];let r,p;e[3]!==a?(r=s.jsx("stop",{offset:"0%",stopColor:a,stopOpacity:.25}),p=s.jsx("stop",{offset:"100%",stopColor:a,stopOpacity:0}),e[3]=a,e[4]=r,e[5]=p):(r=e[4],p=e[5]);let h;e[6]!==d||e[7]!==r||e[8]!==p?(h=s.jsx("defs",{children:s.jsxs("linearGradient",{id:d,x1:"0",y1:"0",x2:"0",y2:"1",children:[r,p]})}),e[6]=d,e[7]=r,e[8]=p,e[9]=h):h=e[9];let u;e[10]!==f||e[11]!==i?(u=i>100&&s.jsxs(s.Fragment,{children:[s.jsx(ke,{strokeDasharray:"4 4",stroke:"var(--border)",strokeOpacity:.5,vertical:!1}),s.jsx(Ue,{dataKey:"label",axisLine:!1,tickLine:!1,tick:{fontSize:11,fill:"var(--muted-foreground)"},interval:"preserveStartEnd",tickMargin:8}),s.jsx(Ce,{orientation:"right",axisLine:!1,tickLine:!1,tick:{fontSize:11,fill:"var(--muted-foreground)"},tickFormatter:f,width:68})]}),e[10]=f,e[11]=i,e[12]=u):u=e[12];let B,v;e[13]===Symbol.for("react.memo_cache_sentinel")?(B={stroke:"var(--border)",strokeDasharray:"4 4"},v={background:"var(--background)",border:"1px solid var(--border)",borderRadius:8,fontSize:12},e[13]=B,e[14]=v):(B=e[13],v=e[14]);let j;e[15]!==f?(j=s.jsx(De,{cursor:B,contentStyle:v,formatter:C=>f(Number(C)||0)}),e[15]=f,e[16]=j):j=e[16];const y=`url(#${d})`;let N;e[17]!==a||e[18]!==l||e[19]!==y?(N=s.jsx(_e,{type:"linear",dataKey:l,stroke:a,strokeWidth:2,fill:y,dot:!1}),e[17]=a,e[18]=l,e[19]=y,e[20]=N):N=e[20];let m;e[21]!==x||e[22]!==N||e[23]!==h||e[24]!==u||e[25]!==j?(m=s.jsxs(Me,{data:x,margin:b,children:[h,u,j,N]}),e[21]=x,e[22]=N,e[23]=h,e[24]=u,e[25]=j,e[26]=m):m=e[26];let S;return e[27]!==i||e[28]!==m?(S=s.jsx(Re,{width:"100%",height:i,children:m}),e[27]=i,e[28]=m,e[29]=S):S=e[29],S}function Ae(t){return{...t,label:Pe(t.date)}}function G(t,e){return t.reduce((n,l)=>n+l[e],0)}function Ee(){const t=k.c(39),e=Z(),{sites:n,isLoading:l}=ue(),[o,f]=le.useState(null),i=Ie(),[a,d]=le.useState(i[0].value);let g;t[0]!==o||t[1]!==n?(g=o??n.slice(0,X),t[0]=o,t[1]=n,t[2]=g):g=t[2];const x=g,b=!o&&n.length>X,{data:r,isLoading:p}=xe(x,a),h=re();if(l){let c;return t[3]===Symbol.for("react.memo_cache_sentinel")?(c=s.jsx(V,{className:"h-64 w-full"}),t[3]=c):c=t[3],c}if(n.length===0){let c;t[4]!==e?(c=e("settings.infraBilling.noSites"),t[4]=e,t[5]=c):c=t[5];let w;return t[6]!==c?(w=s.jsx(T,{className:"p-6 text-sm text-muted-foreground",children:c}),t[6]=c,t[7]=w):w=t[7],w}const u=r?.usage??[],B=r?.pageviewsAvailable??!1,v=!!r&&!r.usageUnavailable,j=(c,w)=>v?w(G(u,c)):"—",y=[{key:"pageviews",title:e("settings.infraBilling.pageviews"),description:e("settings.infraBilling.pageviewsDescription"),colorNum:1,total:B&&v?Q.format(G(u,"pageviews")):"—"},{key:"requests",title:e("settings.infraBilling.requests"),description:e("settings.infraBilling.requestsDescription"),colorNum:2,total:j("requests",Ge)},{key:"dataTransferBytes",title:e("settings.infraBilling.dataTransfer"),description:e("settings.infraBilling.dataTransferDescription"),colorNum:3,total:j("dataTransferBytes",oe)}],N=Oe;let m;t[8]!==r?.teams?(m=r?.teams??[],t[8]=r?.teams,t[9]=m):m=t[9];const S=m;let C;t[10]!==r?.siteSlugsWithoutTeam?(C=r?.siteSlugsWithoutTeam??[],t[10]=r?.siteSlugsWithoutTeam,t[11]=C):C=t[11];const Y=C,U=S.length===1?S[0]:void 0,D=U?.billing??null,te=S.length+(Y.length>0?1:0)>1,K=G(u,"pageviews"),se=K>0?G(u,"requests")/K:0,me=B&&v&&K>0?se.toFixed(se<10?1:0):"—";let I;t[12]!==r?.billingUnavailable||t[13]!==U||t[14]!==e||t[15]!==S.length?(I=r?.billingUnavailable?e("settings.infraBilling.billingUnavailable"):S.length>1?e("settings.infraBilling.multipleTeams",{count:String(S.length)}):U?fe(U,e):e("settings.infraBilling.noTeam"),t[12]=r?.billingUnavailable,t[13]=U,t[14]=e,t[15]=S.length,t[16]=I):I=t[16];const ge=I;let _;t[17]!==n?(_=n.map(qe),t[17]=n,t[18]=_):_=t[18];let M;t[19]!==e?(M=e("settings.infraBilling.siteLabel"),t[19]=e,t[20]=M):M=t[20];let P;t[21]!==x||t[22]!==_||t[23]!==M?(P=s.jsx(je,{className:"w-auto min-w-56 max-w-full",options:_,defaultValue:x,maxCount:2,placeholder:M,onValueChange:f}),t[21]=x,t[22]=_,t[23]=M,t[24]=P):P=t[24];let R;t[25]!==e?(R=e("settings.infraBilling.monthLabel"),t[25]=e,t[26]=R):R=t[26];let A;t[27]===Symbol.for("react.memo_cache_sentinel")?(A=s.jsx(Ne,{}),t[27]=A):A=t[27];let E;t[28]!==R?(E=s.jsx(Se,{className:"w-48","aria-label":R,children:A}),t[28]=R,t[29]=E):E=t[29];let z;t[30]!==x.length||t[31]!==e?(z=x.length===0&&s.jsx(T,{className:"mx-4 p-4 text-sm text-muted-foreground",children:e("settings.infraBilling.pickASite")}),t[30]=x.length,t[31]=e,t[32]=z):z=t[32];let q;t[33]!==e||t[34]!==b?(q=b&&s.jsx(T,{className:"mx-4 p-4 text-sm text-muted-foreground",children:e("settings.infraBilling.tooManySites",{count:String(X)})}),t[33]=e,t[34]=b,t[35]=q):q=t[35];let O;return t[36]!==r?.usageUnavailable||t[37]!==e?(O=r?.usageUnavailable&&s.jsx(T,{className:"mx-4 p-4 text-sm text-muted-foreground",children:e("settings.infraBilling.warehouseUnavailable")}),t[36]=r?.usageUnavailable,t[37]=e,t[38]=O):O=t[38],s.jsxs("div",{className:"flex flex-col gap-8",children:[s.jsxs("div",{className:"flex flex-wrap items-center gap-3 px-4",children:[P,s.jsxs(be,{value:a,onValueChange:d,children:[E,s.jsx(ve,{children:i.map(ze)})]})]}),z,q,O,x.length>0&&s.jsxs(s.Fragment,{children:[s.jsx(W,{title:e("settings.infraBilling.summaryTitle"),children:s.jsxs("div",{className:"flex flex-col lg:flex-row gap-4 px-4",children:[s.jsxs(T,{className:"flex-1 flex flex-col gap-4 p-4",children:[s.jsxs("div",{className:"flex items-center justify-between gap-2",children:[s.jsxs("div",{className:"flex items-center gap-2",children:[s.jsx(he,{size:16,className:"text-muted-foreground"}),s.jsx("span",{className:"text-sm font-medium",children:e("settings.infraBilling.detailsTitle")})]}),U&&D?.canManageSubscription&&s.jsx(J,{variant:"outline",size:"sm",disabled:h.isPending,onClick:()=>h.mutate(U.siteSlugs),children:e("settings.infraBilling.manageButton")})]}),s.jsxs("div",{className:"flex flex-col gap-2 text-sm",children:[D?s.jsxs(s.Fragment,{children:[s.jsxs("div",{className:"flex justify-between gap-3",children:[s.jsx("span",{className:"text-muted-foreground",children:e("settings.infraBilling.currentPlan")}),p?s.jsx(V,{className:"h-5 w-16"}):s.jsx(L,{variant:D.planType==="free"?"secondary":"success",children:e(`settings.infraBilling.plan.${D.planType}`)})]}),s.jsxs("div",{className:"flex justify-between gap-3",children:[s.jsx("span",{className:"text-muted-foreground",children:e("settings.infraBilling.nextBilling")}),s.jsx("span",{className:"font-medium tabular-nums",children:D.nextBillingDate?ee(D.nextBillingDate):"—"})]})]}):!p&&s.jsx("p",{className:"text-xs text-muted-foreground",children:ge}),s.jsxs("div",{className:"flex justify-between gap-3",children:[s.jsx("span",{className:"text-muted-foreground",children:e("settings.infraBilling.requestsPerPageview")}),s.jsx("span",{className:"font-medium tabular-nums",children:me})]})]})]}),y.map(c=>s.jsxs(T,{className:"flex-1 flex flex-col gap-2 p-4",children:[s.jsxs("div",{className:"flex items-baseline justify-between gap-2",children:[s.jsx("span",{className:"text-sm font-medium",children:c.title}),s.jsx("span",{className:"text-xs text-muted-foreground",children:i.find(w=>w.value===a)?.label})]}),p?s.jsx(V,{className:"h-8 w-24"}):s.jsx("span",{className:"text-2xl font-semibold tabular-nums",children:c.total}),s.jsx("div",{className:"-mx-2",children:s.jsx(ae,{usage:u,metric:c.key,colorNum:c.colorNum,formatValue:N(c.key),height:64})})]},c.key))]})}),s.jsx(W,{title:e("settings.infraBilling.metricsTitle"),children:s.jsx("div",{className:"flex flex-col xl:flex-row gap-4 px-4",children:y.map(c=>s.jsxs(T,{className:"flex-1 flex flex-col gap-3 p-4",children:[s.jsxs("div",{className:"flex flex-col gap-1",children:[s.jsx("span",{className:"text-sm font-medium",children:c.title}),s.jsx("span",{className:"text-xs text-muted-foreground",children:c.description})]}),s.jsx(ae,{usage:u,metric:c.key,colorNum:c.colorNum,formatValue:N(c.key),height:220})]},c.key))})}),s.jsx(W,{title:e("settings.infraBilling.invoicesTitle"),children:s.jsx("div",{className:"flex flex-col gap-4 px-4",children:r?r.billingUnavailable?s.jsx(T,{className:"p-4 text-sm text-muted-foreground",children:e("settings.infraBilling.billingUnavailable")}):s.jsxs(s.Fragment,{children:[S.map(c=>s.jsx(Ze,{team:c,showSites:te},c.siteSlugs.join(","))),Y.length>0&&s.jsxs(T,{className:"flex flex-col gap-1 p-4",children:[te&&s.jsx("span",{className:"text-sm font-medium",children:Y.join(", ")}),s.jsx("p",{className:"text-sm text-muted-foreground",children:e("settings.infraBilling.noTeam")})]})]}):s.jsx(T,{size:"flush",children:s.jsx(V,{className:"m-4 h-24"})})})})]})]})}function ze(t){return s.jsx(Be,{value:t.value,children:t.label},t.value)}function qe(t){return{label:t,value:t}}function Oe(t){return t==="dataTransferBytes"?oe:Ve}function Ve(t){return Q.format(t)}function Ge(t){return Q.format(t)}function fe(t,e){return t.unavailableReason==="partial_team"?e("settings.infraBilling.partialTeam"):e("settings.infraBilling.billingUnavailable")}function Ze(t){const e=k.c(13),{team:n,showSites:l}=t,o=Z(),f=re(),i=n.billing;let a;e[0]!==i||e[1]!==f||e[2]!==l||e[3]!==o||e[4]!==n.siteSlugs?(a=l&&s.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-3 border-b border-border p-4",children:[s.jsx("span",{className:"text-sm font-medium",children:n.siteSlugs.join(", ")}),i&&s.jsxs("div",{className:"flex flex-wrap items-center gap-3 text-sm",children:[s.jsx(L,{variant:i.planType==="free"?"secondary":"success",children:o(`settings.infraBilling.plan.${i.planType}`)}),i.nextBillingDate&&s.jsxs("span",{className:"flex gap-1.5",children:[s.jsx("span",{className:"text-muted-foreground",children:o("settings.infraBilling.nextBilling")}),s.jsx("span",{className:"font-medium tabular-nums",children:ee(i.nextBillingDate)})]}),i.canManageSubscription&&s.jsx(J,{variant:"outline",size:"sm",disabled:f.isPending,onClick:()=>f.mutate(n.siteSlugs),children:o("settings.infraBilling.manageButton")})]})]}),e[0]=i,e[1]=f,e[2]=l,e[3]=o,e[4]=n.siteSlugs,e[5]=a):a=e[5];let d;e[6]!==i||e[7]!==o||e[8]!==n?(d=i?i.invoices.length===0?s.jsx("p",{className:"p-4 text-sm text-muted-foreground",children:o("settings.infraBilling.noInvoices")}):s.jsx(Ye,{invoices:i.invoices}):s.jsx("p",{className:"p-4 text-sm text-muted-foreground",children:fe(n,o)}),e[6]=i,e[7]=o,e[8]=n,e[9]=d):d=e[9];let g;return e[10]!==a||e[11]!==d?(g=s.jsxs(T,{size:"flush",className:"gap-0 overflow-x-auto",children:[a,d]}),e[10]=a,e[11]=d,e[12]=g):g=e[12],g}function Ye(t){const e=k.c(40),{invoices:n}=t,l=Z();let o;e[0]!==n?(o=n.some(Ke),e[0]=n,e[1]=o):o=e[1];const f=o;let i;e[2]!==l?(i=l("settings.infraBilling.invoiceReference"),e[2]=l,e[3]=i):i=e[3];let a;e[4]!==i?(a=s.jsx($,{children:i}),e[4]=i,e[5]=a):a=e[5];let d;e[6]!==l?(d=l("settings.infraBilling.invoiceDue"),e[6]=l,e[7]=d):d=e[7];let g;e[8]!==d?(g=s.jsx($,{children:d}),e[8]=d,e[9]=g):g=e[9];let x;e[10]!==l?(x=l("settings.infraBilling.invoiceAmount"),e[10]=l,e[11]=x):x=e[11];let b;e[12]!==x?(b=s.jsx($,{children:x}),e[12]=x,e[13]=b):b=e[13];let r;e[14]!==l?(r=l("settings.infraBilling.invoiceStatus"),e[14]=l,e[15]=r):r=e[15];let p;e[16]!==r?(p=s.jsx($,{children:r}),e[16]=r,e[17]=p):p=e[17];let h;e[18]!==l?(h=l("settings.infraBilling.invoiceDocuments"),e[18]=l,e[19]=h):h=e[19];let u;e[20]!==h?(u=s.jsx($,{children:h}),e[20]=h,e[21]=u):u=e[21];let B;e[22]!==u||e[23]!==a||e[24]!==g||e[25]!==b||e[26]!==p?(B=s.jsx(ye,{children:s.jsxs(ie,{children:[a,g,b,p,u]})}),e[22]=u,e[23]=a,e[24]=g,e[25]=b,e[26]=p,e[27]=B):B=e[27];let v;if(e[28]!==n||e[29]!==l||e[30]!==f){let N;e[32]!==l||e[33]!==f?(N=m=>s.jsxs(ie,{children:[s.jsx(F,{children:m.referenceMonth?ce(m.referenceMonth).toLocaleDateString(void 0,{month:"long",year:"numeric",timeZone:"UTC"}):"—"}),s.jsx(F,{children:m.dueDate?ee(m.dueDate):"—"}),s.jsx(F,{className:"tabular-nums",children:Fe.format(m.value)}),s.jsx(F,{children:s.jsx(We,{status:m.status})}),s.jsxs(F,{className:"flex gap-2",children:[m.nfUrl&&s.jsx(H,{href:m.nfUrl,label:l("settings.infraBilling.invoiceNf")}),m.bankSlipUrl&&s.jsx(H,{href:m.bankSlipUrl,label:l("settings.infraBilling.invoiceBankSlip")}),!m.bankSlipUrl&&!f&&m.nfUrl&&s.jsx(H,{href:$e,label:l("settings.infraBilling.invoiceBankTransfer")}),!m.nfUrl&&!m.bankSlipUrl&&"—"]})]},m.id),e[32]=l,e[33]=f,e[34]=N):N=e[34],v=n.map(N),e[28]=n,e[29]=l,e[30]=f,e[31]=v}else v=e[31];let j;e[35]!==v?(j=s.jsx(Te,{children:v}),e[35]=v,e[36]=j):j=e[36];let y;return e[37]!==B||e[38]!==j?(y=s.jsxs(we,{children:[B,j]}),e[37]=B,e[38]=j,e[39]=y):y=e[39],y}function Ke(t){return!!t.bankSlipUrl}function H(t){const e=k.c(4),{href:n,label:l}=t;let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o=s.jsx(pe,{size:14}),e[0]=o):o=e[0];let f;return e[1]!==n||e[2]!==l?(f=s.jsx(J,{variant:"outline",size:"sm",asChild:!0,children:s.jsxs("a",{href:n,target:"_blank",rel:"noreferrer",children:[o,l]})}),e[1]=n,e[2]=l,e[3]=f):f=e[3],f}function We(t){const e=k.c(14),{status:n}=t,l=Z(),o=n.toLowerCase();if(o==="paid"){let i;e[0]!==l?(i=l("settings.infraBilling.statusPaid"),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==i?(a=s.jsx(L,{variant:"success",children:i}),e[2]=i,e[3]=a):a=e[3],a}if(o==="overdue"){let i;e[4]!==l?(i=l("settings.infraBilling.statusOverdue"),e[4]=l,e[5]=i):i=e[5];let a;return e[6]!==i?(a=s.jsx(L,{variant:"destructive",children:i}),e[6]=i,e[7]=a):a=e[7],a}if(o==="registered"){let i;e[8]!==l?(i=l("settings.infraBilling.statusPending"),e[8]=l,e[9]=i):i=e[9];let a;return e[10]!==i?(a=s.jsx(L,{variant:"warning",children:i}),e[10]=i,e[11]=a):a=e[11],a}let f;return e[12]!==n?(f=s.jsx(L,{variant:"secondary",children:n}),e[12]=n,e[13]=f):f=e[13],f}function Xe(){const t=k.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(de,{group:"billing",children:s.jsx(Ee,{})}),t[0]=e):e=t[0],e}function Bt(){const t=k.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(Le,{capability:"members:manage",area:"billing",children:s.jsx(Xe,{})}),t[0]=e):e=t[0],e}export{Bt as default};
1
+ import{c as k,j as s,i4 as de,b as Z,i5 as ue,r as le,i6 as xe,i7 as re,gG as T,gV as W,B as J,e0 as V,a9 as pe}from"./index-DokE5sNF.js";import{i as he}from"./CreditCard01-C7IRKQGq.js";import{B as L}from"./badge-CXWhQd3j.js";import{M as je}from"./multi-select-D0i-_SFY.js";import{S as be,d as ve,c as Be,a as Ne,b as Se}from"./select-CKROachj.js";import{T as $,a as ye,b as ie,c as F,d as Te,e as we}from"./table-DsirtjTQ.js";import{C as ke,X as Ue,Y as Ce}from"./CartesianChart-ghS8jWki.js";import{T as De}from"./Tooltip-DKAhw1l_.js";import{a as _e,A as Me}from"./AreaChart-DQSuG1yE.js";import{c2 as Re}from"./CategoricalChart-FLgBKuSu.js";import{R as Le}from"./require-capability-_6vPPsFH.js";import"./checkbox-CouJku1L.js";import"./Minus-CwITAxnt.js";import"./ChevronDown-DeUpalBN.js";import"./command-XtwrY353.js";import"./index-96oa6z-q.js";import"./SearchMd-BIZLsFUb.js";import"./popover-BNjsYhzT.js";import"./index-BdQq_4o_.js";import"./index-BesTIQjb.js";import"./ChevronUp-BzeZGyJH.js";import"./index-C3kpYdOE.js";import"./access-gate-wCyQtv5A.js";import"./capability-load-error-DGMDILUu.js";const Q=new Intl.NumberFormat(void 0,{notation:"compact",maximumFractionDigits:1}),ne=["B","KB","MB","GB","TB","PB"];function oe(t){if(t<=0)return"0 B";const e=Math.min(ne.length-1,Math.floor(Math.log(t)/Math.log(1024))),n=t/1024**e;return`${n.toFixed(n>=100||e===0?0:1)} ${ne[e]}`}const X=50,$e="https://assets.decocache.com/decocms/45f9e905-046b-4aeb-8420-0377a7d0d041/deco_Transferencia.pdf",Fe=new Intl.NumberFormat("pt-BR",{style:"currency",currency:"BRL"});function ce(t){return new Date(`${t.slice(0,10)}T00:00:00Z`)}function ee(t){return ce(t).toLocaleDateString(void 0,{day:"numeric",month:"short",year:"numeric",timeZone:"UTC"})}function Ie(){const t=new Date;return Array.from({length:12},(e,n)=>{const l=new Date(Date.UTC(t.getUTCFullYear(),t.getUTCMonth()-n,1));return{value:l.toISOString().slice(0,10),label:l.toLocaleDateString(void 0,{month:"long",year:"numeric",timeZone:"UTC"})}})}function Pe(t){return new Date(`${t}T00:00:00Z`).toLocaleDateString(void 0,{month:"short",day:"numeric",timeZone:"UTC"})}function ae(t){const e=k.c(30),{usage:n,metric:l,colorNum:o,formatValue:f,height:i}=t,a=`var(--chart-${o})`,d=`infra-billing-${l}`;let g;e[0]!==n?(g=n.map(Ae),e[0]=n,e[1]=g):g=e[1];const x=g;let b;e[2]===Symbol.for("react.memo_cache_sentinel")?(b={left:0,right:4,top:8,bottom:0},e[2]=b):b=e[2];let r,p;e[3]!==a?(r=s.jsx("stop",{offset:"0%",stopColor:a,stopOpacity:.25}),p=s.jsx("stop",{offset:"100%",stopColor:a,stopOpacity:0}),e[3]=a,e[4]=r,e[5]=p):(r=e[4],p=e[5]);let h;e[6]!==d||e[7]!==r||e[8]!==p?(h=s.jsx("defs",{children:s.jsxs("linearGradient",{id:d,x1:"0",y1:"0",x2:"0",y2:"1",children:[r,p]})}),e[6]=d,e[7]=r,e[8]=p,e[9]=h):h=e[9];let u;e[10]!==f||e[11]!==i?(u=i>100&&s.jsxs(s.Fragment,{children:[s.jsx(ke,{strokeDasharray:"4 4",stroke:"var(--border)",strokeOpacity:.5,vertical:!1}),s.jsx(Ue,{dataKey:"label",axisLine:!1,tickLine:!1,tick:{fontSize:11,fill:"var(--muted-foreground)"},interval:"preserveStartEnd",tickMargin:8}),s.jsx(Ce,{orientation:"right",axisLine:!1,tickLine:!1,tick:{fontSize:11,fill:"var(--muted-foreground)"},tickFormatter:f,width:68})]}),e[10]=f,e[11]=i,e[12]=u):u=e[12];let B,v;e[13]===Symbol.for("react.memo_cache_sentinel")?(B={stroke:"var(--border)",strokeDasharray:"4 4"},v={background:"var(--background)",border:"1px solid var(--border)",borderRadius:8,fontSize:12},e[13]=B,e[14]=v):(B=e[13],v=e[14]);let j;e[15]!==f?(j=s.jsx(De,{cursor:B,contentStyle:v,formatter:C=>f(Number(C)||0)}),e[15]=f,e[16]=j):j=e[16];const y=`url(#${d})`;let N;e[17]!==a||e[18]!==l||e[19]!==y?(N=s.jsx(_e,{type:"linear",dataKey:l,stroke:a,strokeWidth:2,fill:y,dot:!1}),e[17]=a,e[18]=l,e[19]=y,e[20]=N):N=e[20];let m;e[21]!==x||e[22]!==N||e[23]!==h||e[24]!==u||e[25]!==j?(m=s.jsxs(Me,{data:x,margin:b,children:[h,u,j,N]}),e[21]=x,e[22]=N,e[23]=h,e[24]=u,e[25]=j,e[26]=m):m=e[26];let S;return e[27]!==i||e[28]!==m?(S=s.jsx(Re,{width:"100%",height:i,children:m}),e[27]=i,e[28]=m,e[29]=S):S=e[29],S}function Ae(t){return{...t,label:Pe(t.date)}}function G(t,e){return t.reduce((n,l)=>n+l[e],0)}function Ee(){const t=k.c(39),e=Z(),{sites:n,isLoading:l}=ue(),[o,f]=le.useState(null),i=Ie(),[a,d]=le.useState(i[0].value);let g;t[0]!==o||t[1]!==n?(g=o??n.slice(0,X),t[0]=o,t[1]=n,t[2]=g):g=t[2];const x=g,b=!o&&n.length>X,{data:r,isLoading:p}=xe(x,a),h=re();if(l){let c;return t[3]===Symbol.for("react.memo_cache_sentinel")?(c=s.jsx(V,{className:"h-64 w-full"}),t[3]=c):c=t[3],c}if(n.length===0){let c;t[4]!==e?(c=e("settings.infraBilling.noSites"),t[4]=e,t[5]=c):c=t[5];let w;return t[6]!==c?(w=s.jsx(T,{className:"p-6 text-sm text-muted-foreground",children:c}),t[6]=c,t[7]=w):w=t[7],w}const u=r?.usage??[],B=r?.pageviewsAvailable??!1,v=!!r&&!r.usageUnavailable,j=(c,w)=>v?w(G(u,c)):"—",y=[{key:"pageviews",title:e("settings.infraBilling.pageviews"),description:e("settings.infraBilling.pageviewsDescription"),colorNum:1,total:B&&v?Q.format(G(u,"pageviews")):"—"},{key:"requests",title:e("settings.infraBilling.requests"),description:e("settings.infraBilling.requestsDescription"),colorNum:2,total:j("requests",Ge)},{key:"dataTransferBytes",title:e("settings.infraBilling.dataTransfer"),description:e("settings.infraBilling.dataTransferDescription"),colorNum:3,total:j("dataTransferBytes",oe)}],N=Oe;let m;t[8]!==r?.teams?(m=r?.teams??[],t[8]=r?.teams,t[9]=m):m=t[9];const S=m;let C;t[10]!==r?.siteSlugsWithoutTeam?(C=r?.siteSlugsWithoutTeam??[],t[10]=r?.siteSlugsWithoutTeam,t[11]=C):C=t[11];const Y=C,U=S.length===1?S[0]:void 0,D=U?.billing??null,te=S.length+(Y.length>0?1:0)>1,K=G(u,"pageviews"),se=K>0?G(u,"requests")/K:0,me=B&&v&&K>0?se.toFixed(se<10?1:0):"—";let I;t[12]!==r?.billingUnavailable||t[13]!==U||t[14]!==e||t[15]!==S.length?(I=r?.billingUnavailable?e("settings.infraBilling.billingUnavailable"):S.length>1?e("settings.infraBilling.multipleTeams",{count:String(S.length)}):U?fe(U,e):e("settings.infraBilling.noTeam"),t[12]=r?.billingUnavailable,t[13]=U,t[14]=e,t[15]=S.length,t[16]=I):I=t[16];const ge=I;let _;t[17]!==n?(_=n.map(qe),t[17]=n,t[18]=_):_=t[18];let M;t[19]!==e?(M=e("settings.infraBilling.siteLabel"),t[19]=e,t[20]=M):M=t[20];let P;t[21]!==x||t[22]!==_||t[23]!==M?(P=s.jsx(je,{className:"w-auto min-w-56 max-w-full",options:_,defaultValue:x,maxCount:2,placeholder:M,onValueChange:f}),t[21]=x,t[22]=_,t[23]=M,t[24]=P):P=t[24];let R;t[25]!==e?(R=e("settings.infraBilling.monthLabel"),t[25]=e,t[26]=R):R=t[26];let A;t[27]===Symbol.for("react.memo_cache_sentinel")?(A=s.jsx(Ne,{}),t[27]=A):A=t[27];let E;t[28]!==R?(E=s.jsx(Se,{className:"w-48","aria-label":R,children:A}),t[28]=R,t[29]=E):E=t[29];let z;t[30]!==x.length||t[31]!==e?(z=x.length===0&&s.jsx(T,{className:"mx-4 p-4 text-sm text-muted-foreground",children:e("settings.infraBilling.pickASite")}),t[30]=x.length,t[31]=e,t[32]=z):z=t[32];let q;t[33]!==e||t[34]!==b?(q=b&&s.jsx(T,{className:"mx-4 p-4 text-sm text-muted-foreground",children:e("settings.infraBilling.tooManySites",{count:String(X)})}),t[33]=e,t[34]=b,t[35]=q):q=t[35];let O;return t[36]!==r?.usageUnavailable||t[37]!==e?(O=r?.usageUnavailable&&s.jsx(T,{className:"mx-4 p-4 text-sm text-muted-foreground",children:e("settings.infraBilling.warehouseUnavailable")}),t[36]=r?.usageUnavailable,t[37]=e,t[38]=O):O=t[38],s.jsxs("div",{className:"flex flex-col gap-8",children:[s.jsxs("div",{className:"flex flex-wrap items-center gap-3 px-4",children:[P,s.jsxs(be,{value:a,onValueChange:d,children:[E,s.jsx(ve,{children:i.map(ze)})]})]}),z,q,O,x.length>0&&s.jsxs(s.Fragment,{children:[s.jsx(W,{title:e("settings.infraBilling.summaryTitle"),children:s.jsxs("div",{className:"flex flex-col lg:flex-row gap-4 px-4",children:[s.jsxs(T,{className:"flex-1 flex flex-col gap-4 p-4",children:[s.jsxs("div",{className:"flex items-center justify-between gap-2",children:[s.jsxs("div",{className:"flex items-center gap-2",children:[s.jsx(he,{size:16,className:"text-muted-foreground"}),s.jsx("span",{className:"text-sm font-medium",children:e("settings.infraBilling.detailsTitle")})]}),U&&D?.canManageSubscription&&s.jsx(J,{variant:"outline",size:"sm",disabled:h.isPending,onClick:()=>h.mutate(U.siteSlugs),children:e("settings.infraBilling.manageButton")})]}),s.jsxs("div",{className:"flex flex-col gap-2 text-sm",children:[D?s.jsxs(s.Fragment,{children:[s.jsxs("div",{className:"flex justify-between gap-3",children:[s.jsx("span",{className:"text-muted-foreground",children:e("settings.infraBilling.currentPlan")}),p?s.jsx(V,{className:"h-5 w-16"}):s.jsx(L,{variant:D.planType==="free"?"secondary":"success",children:e(`settings.infraBilling.plan.${D.planType}`)})]}),s.jsxs("div",{className:"flex justify-between gap-3",children:[s.jsx("span",{className:"text-muted-foreground",children:e("settings.infraBilling.nextBilling")}),s.jsx("span",{className:"font-medium tabular-nums",children:D.nextBillingDate?ee(D.nextBillingDate):"—"})]})]}):!p&&s.jsx("p",{className:"text-xs text-muted-foreground",children:ge}),s.jsxs("div",{className:"flex justify-between gap-3",children:[s.jsx("span",{className:"text-muted-foreground",children:e("settings.infraBilling.requestsPerPageview")}),s.jsx("span",{className:"font-medium tabular-nums",children:me})]})]})]}),y.map(c=>s.jsxs(T,{className:"flex-1 flex flex-col gap-2 p-4",children:[s.jsxs("div",{className:"flex items-baseline justify-between gap-2",children:[s.jsx("span",{className:"text-sm font-medium",children:c.title}),s.jsx("span",{className:"text-xs text-muted-foreground",children:i.find(w=>w.value===a)?.label})]}),p?s.jsx(V,{className:"h-8 w-24"}):s.jsx("span",{className:"text-2xl font-semibold tabular-nums",children:c.total}),s.jsx("div",{className:"-mx-2",children:s.jsx(ae,{usage:u,metric:c.key,colorNum:c.colorNum,formatValue:N(c.key),height:64})})]},c.key))]})}),s.jsx(W,{title:e("settings.infraBilling.metricsTitle"),children:s.jsx("div",{className:"flex flex-col xl:flex-row gap-4 px-4",children:y.map(c=>s.jsxs(T,{className:"flex-1 flex flex-col gap-3 p-4",children:[s.jsxs("div",{className:"flex flex-col gap-1",children:[s.jsx("span",{className:"text-sm font-medium",children:c.title}),s.jsx("span",{className:"text-xs text-muted-foreground",children:c.description})]}),s.jsx(ae,{usage:u,metric:c.key,colorNum:c.colorNum,formatValue:N(c.key),height:220})]},c.key))})}),s.jsx(W,{title:e("settings.infraBilling.invoicesTitle"),children:s.jsx("div",{className:"flex flex-col gap-4 px-4",children:r?r.billingUnavailable?s.jsx(T,{className:"p-4 text-sm text-muted-foreground",children:e("settings.infraBilling.billingUnavailable")}):s.jsxs(s.Fragment,{children:[S.map(c=>s.jsx(Ze,{team:c,showSites:te},c.siteSlugs.join(","))),Y.length>0&&s.jsxs(T,{className:"flex flex-col gap-1 p-4",children:[te&&s.jsx("span",{className:"text-sm font-medium",children:Y.join(", ")}),s.jsx("p",{className:"text-sm text-muted-foreground",children:e("settings.infraBilling.noTeam")})]})]}):s.jsx(T,{size:"flush",children:s.jsx(V,{className:"m-4 h-24"})})})})]})]})}function ze(t){return s.jsx(Be,{value:t.value,children:t.label},t.value)}function qe(t){return{label:t,value:t}}function Oe(t){return t==="dataTransferBytes"?oe:Ve}function Ve(t){return Q.format(t)}function Ge(t){return Q.format(t)}function fe(t,e){return t.unavailableReason==="partial_team"?e("settings.infraBilling.partialTeam"):e("settings.infraBilling.billingUnavailable")}function Ze(t){const e=k.c(13),{team:n,showSites:l}=t,o=Z(),f=re(),i=n.billing;let a;e[0]!==i||e[1]!==f||e[2]!==l||e[3]!==o||e[4]!==n.siteSlugs?(a=l&&s.jsxs("div",{className:"flex flex-wrap items-center justify-between gap-3 border-b border-border p-4",children:[s.jsx("span",{className:"text-sm font-medium",children:n.siteSlugs.join(", ")}),i&&s.jsxs("div",{className:"flex flex-wrap items-center gap-3 text-sm",children:[s.jsx(L,{variant:i.planType==="free"?"secondary":"success",children:o(`settings.infraBilling.plan.${i.planType}`)}),i.nextBillingDate&&s.jsxs("span",{className:"flex gap-1.5",children:[s.jsx("span",{className:"text-muted-foreground",children:o("settings.infraBilling.nextBilling")}),s.jsx("span",{className:"font-medium tabular-nums",children:ee(i.nextBillingDate)})]}),i.canManageSubscription&&s.jsx(J,{variant:"outline",size:"sm",disabled:f.isPending,onClick:()=>f.mutate(n.siteSlugs),children:o("settings.infraBilling.manageButton")})]})]}),e[0]=i,e[1]=f,e[2]=l,e[3]=o,e[4]=n.siteSlugs,e[5]=a):a=e[5];let d;e[6]!==i||e[7]!==o||e[8]!==n?(d=i?i.invoices.length===0?s.jsx("p",{className:"p-4 text-sm text-muted-foreground",children:o("settings.infraBilling.noInvoices")}):s.jsx(Ye,{invoices:i.invoices}):s.jsx("p",{className:"p-4 text-sm text-muted-foreground",children:fe(n,o)}),e[6]=i,e[7]=o,e[8]=n,e[9]=d):d=e[9];let g;return e[10]!==a||e[11]!==d?(g=s.jsxs(T,{size:"flush",className:"gap-0 overflow-x-auto",children:[a,d]}),e[10]=a,e[11]=d,e[12]=g):g=e[12],g}function Ye(t){const e=k.c(40),{invoices:n}=t,l=Z();let o;e[0]!==n?(o=n.some(Ke),e[0]=n,e[1]=o):o=e[1];const f=o;let i;e[2]!==l?(i=l("settings.infraBilling.invoiceReference"),e[2]=l,e[3]=i):i=e[3];let a;e[4]!==i?(a=s.jsx($,{children:i}),e[4]=i,e[5]=a):a=e[5];let d;e[6]!==l?(d=l("settings.infraBilling.invoiceDue"),e[6]=l,e[7]=d):d=e[7];let g;e[8]!==d?(g=s.jsx($,{children:d}),e[8]=d,e[9]=g):g=e[9];let x;e[10]!==l?(x=l("settings.infraBilling.invoiceAmount"),e[10]=l,e[11]=x):x=e[11];let b;e[12]!==x?(b=s.jsx($,{children:x}),e[12]=x,e[13]=b):b=e[13];let r;e[14]!==l?(r=l("settings.infraBilling.invoiceStatus"),e[14]=l,e[15]=r):r=e[15];let p;e[16]!==r?(p=s.jsx($,{children:r}),e[16]=r,e[17]=p):p=e[17];let h;e[18]!==l?(h=l("settings.infraBilling.invoiceDocuments"),e[18]=l,e[19]=h):h=e[19];let u;e[20]!==h?(u=s.jsx($,{children:h}),e[20]=h,e[21]=u):u=e[21];let B;e[22]!==u||e[23]!==a||e[24]!==g||e[25]!==b||e[26]!==p?(B=s.jsx(ye,{children:s.jsxs(ie,{children:[a,g,b,p,u]})}),e[22]=u,e[23]=a,e[24]=g,e[25]=b,e[26]=p,e[27]=B):B=e[27];let v;if(e[28]!==n||e[29]!==l||e[30]!==f){let N;e[32]!==l||e[33]!==f?(N=m=>s.jsxs(ie,{children:[s.jsx(F,{children:m.referenceMonth?ce(m.referenceMonth).toLocaleDateString(void 0,{month:"long",year:"numeric",timeZone:"UTC"}):"—"}),s.jsx(F,{children:m.dueDate?ee(m.dueDate):"—"}),s.jsx(F,{className:"tabular-nums",children:Fe.format(m.value)}),s.jsx(F,{children:s.jsx(We,{status:m.status})}),s.jsxs(F,{className:"flex gap-2",children:[m.nfUrl&&s.jsx(H,{href:m.nfUrl,label:l("settings.infraBilling.invoiceNf")}),m.bankSlipUrl&&s.jsx(H,{href:m.bankSlipUrl,label:l("settings.infraBilling.invoiceBankSlip")}),!m.bankSlipUrl&&!f&&m.nfUrl&&s.jsx(H,{href:$e,label:l("settings.infraBilling.invoiceBankTransfer")}),!m.nfUrl&&!m.bankSlipUrl&&"—"]})]},m.id),e[32]=l,e[33]=f,e[34]=N):N=e[34],v=n.map(N),e[28]=n,e[29]=l,e[30]=f,e[31]=v}else v=e[31];let j;e[35]!==v?(j=s.jsx(Te,{children:v}),e[35]=v,e[36]=j):j=e[36];let y;return e[37]!==B||e[38]!==j?(y=s.jsxs(we,{children:[B,j]}),e[37]=B,e[38]=j,e[39]=y):y=e[39],y}function Ke(t){return!!t.bankSlipUrl}function H(t){const e=k.c(4),{href:n,label:l}=t;let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o=s.jsx(pe,{size:14}),e[0]=o):o=e[0];let f;return e[1]!==n||e[2]!==l?(f=s.jsx(J,{variant:"outline",size:"sm",asChild:!0,children:s.jsxs("a",{href:n,target:"_blank",rel:"noreferrer",children:[o,l]})}),e[1]=n,e[2]=l,e[3]=f):f=e[3],f}function We(t){const e=k.c(14),{status:n}=t,l=Z(),o=n.toLowerCase();if(o==="paid"){let i;e[0]!==l?(i=l("settings.infraBilling.statusPaid"),e[0]=l,e[1]=i):i=e[1];let a;return e[2]!==i?(a=s.jsx(L,{variant:"success",children:i}),e[2]=i,e[3]=a):a=e[3],a}if(o==="overdue"){let i;e[4]!==l?(i=l("settings.infraBilling.statusOverdue"),e[4]=l,e[5]=i):i=e[5];let a;return e[6]!==i?(a=s.jsx(L,{variant:"destructive",children:i}),e[6]=i,e[7]=a):a=e[7],a}if(o==="registered"){let i;e[8]!==l?(i=l("settings.infraBilling.statusPending"),e[8]=l,e[9]=i):i=e[9];let a;return e[10]!==i?(a=s.jsx(L,{variant:"warning",children:i}),e[10]=i,e[11]=a):a=e[11],a}let f;return e[12]!==n?(f=s.jsx(L,{variant:"secondary",children:n}),e[12]=n,e[13]=f):f=e[13],f}function Xe(){const t=k.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(de,{group:"billing",children:s.jsx(Ee,{})}),t[0]=e):e=t[0],e}function Bt(){const t=k.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=s.jsx(Le,{capability:"members:manage",area:"billing",children:s.jsx(Xe,{})}),t[0]=e):e=t[0],e}export{Bt as default};