decocms 4.494.0 → 4.495.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 (368) hide show
  1. package/dist/client/assets/{ActiveShapeUtils-C-buMql8.js → ActiveShapeUtils-DCHlcSOh.js} +1 -1
  2. package/dist/client/assets/{AlertCircle-xh90NARB.js → AlertCircle-9YsZUjmj.js} +1 -1
  3. package/dist/client/assets/{AreaChart-hhJtx5W4.js → AreaChart-CeW2QCC3.js} +1 -1
  4. package/dist/client/assets/{ArrowLeft-Xffg7q8p.js → ArrowLeft-ZHARsvy9.js} +1 -1
  5. package/dist/client/assets/{ArrowUp-4iK8zoCx.js → ArrowUp-D1danNae.js} +1 -1
  6. package/dist/client/assets/{BarChart-CvyDfHpd.js → BarChart-DdrNiWaE.js} +1 -1
  7. package/dist/client/assets/{Building02-DAEF4UrO.js → Building02-ssxWkdBl.js} +1 -1
  8. package/dist/client/assets/{CategoricalChart-CMQWnNBW.js → CategoricalChart-ClYHeQF6.js} +1 -1
  9. package/dist/client/assets/{CheckCircle-DUpC1qQ4.js → CheckCircle-DiKVJkkJ.js} +1 -1
  10. package/dist/client/assets/{ChevronSelectorVertical-DCkH1mIQ.js → ChevronSelectorVertical-Dkzqp5pp.js} +1 -1
  11. package/dist/client/assets/{ChevronUp-D_Wjh1Pp.js → ChevronUp-wLOc_NTT.js} +1 -1
  12. package/dist/client/assets/{Copy01-BdyOQaoT.js → Copy01-Cr5x9Tlu.js} +1 -1
  13. package/dist/client/assets/{CreditCard01-YN58MJQp.js → CreditCard01-DCL7xzU2.js} +1 -1
  14. package/dist/client/assets/{DotsVertical-C0q218c1.js → DotsVertical-DZE2ktIm.js} +1 -1
  15. package/dist/client/assets/{ErrorBarContext-thUyR0rx.js → ErrorBarContext-D4j8kFWO.js} +1 -1
  16. package/dist/client/assets/{Globe04-brrhloqP.js → Globe04-DLL93yaf.js} +1 -1
  17. package/dist/client/assets/{Image01-Drnu_oTX.js → Image01-Doh_epPd.js} +1 -1
  18. package/dist/client/assets/{Key01-DXKey19o.js → Key01-rqwReuZQ.js} +1 -1
  19. package/dist/client/assets/{Link01-DAwi9mlM.js → Link01-DiFWbMaR.js} +1 -1
  20. package/dist/client/assets/{LinkBroken01-wTJMvAdz.js → LinkBroken01-DGQh_3WZ.js} +1 -1
  21. package/dist/client/assets/{Monitor01-Bm_bTKyL.js → Monitor01-Cp7iEwN0.js} +1 -1
  22. package/dist/client/assets/{Play-CqIDE5zC.js → Play-C2hvYOyw.js} +1 -1
  23. package/dist/client/assets/{Plus-j4aDTi8e.js → Plus-v0YpByfM.js} +1 -1
  24. package/dist/client/assets/{SearchMd-DhQxjm00.js → SearchMd-Bendi2p8.js} +1 -1
  25. package/dist/client/assets/{Sector-Dhm7L79o.js → Sector-Clpc9eH-.js} +1 -1
  26. package/dist/client/assets/{ShoppingBag01-BJ4cJNkc.js → ShoppingBag01-BG-1Jwuh.js} +1 -1
  27. package/dist/client/assets/{Sun-D0UkgT29.js → Sun-CJr96mBh.js} +1 -1
  28. package/dist/client/assets/{SwitchHorizontal01-6WEEE86B.js → SwitchHorizontal01-Dv53_XOE.js} +1 -1
  29. package/dist/client/assets/{Tool01-DG06N0su.js → Tool01-B-kpMrMZ.js} +1 -1
  30. package/dist/client/assets/{Trash01-C9lhbJs7.js → Trash01-3M9m1iIs.js} +1 -1
  31. package/dist/client/assets/{Upload01-Bt337Shk.js → Upload01-DBgIGKf8.js} +1 -1
  32. package/dist/client/assets/{User01-DXN8J2dA.js → User01-CT2R-iHD.js} +1 -1
  33. package/dist/client/assets/{UserSquare-B7AJhMXA.js → UserSquare-BuJqx7Ns.js} +1 -1
  34. package/dist/client/assets/{Users01-CHS_3A2d.js → Users01-gQNjKybb.js} +1 -1
  35. package/dist/client/assets/{XAxis-M9-_1D7_.js → XAxis-DBRxAeUY.js} +1 -1
  36. package/dist/client/assets/{XClose-pteQuwAH.js → XClose-Bpws6cjk.js} +1 -1
  37. package/dist/client/assets/{ZoomOut-D4nHzX79.js → ZoomOut-CVwCO-_8.js} +1 -1
  38. package/dist/client/assets/{access-gate-CNFrC5-Q.js → access-gate-DlhD9I9N.js} +1 -1
  39. package/dist/client/assets/{add-connection-dialog-BXB3P-4X.js → add-connection-dialog-CQiSl-Qe.js} +1 -1
  40. package/dist/client/assets/{agent-analytics-C1qxm1L0.js → agent-analytics-Dlpy_544.js} +1 -1
  41. package/dist/client/assets/agent-app-DtmEOrmX.js +1 -0
  42. package/dist/client/assets/{agent-assets-Doo6qn_B.js → agent-assets-Ba_4hhfI.js} +1 -1
  43. package/dist/client/assets/{agent-automation-BhXRsqWt.js → agent-automation-DuF9ZiWS.js} +1 -1
  44. package/dist/client/assets/{agent-automations-B3GOPyc3.js → agent-automations-BV2eTHQr.js} +1 -1
  45. package/dist/client/assets/{agent-connect-sources-Cj-TiW7a.js → agent-connect-sources-C_fgxaTV.js} +1 -1
  46. package/dist/client/assets/agent-deck--kR-tnhH.js +1 -0
  47. package/dist/client/assets/{agent-e2e-CyiK0Nn8.js → agent-e2e-CgGLFkHe.js} +1 -1
  48. package/dist/client/assets/{agent-experiments-Dero6WeN.js → agent-experiments-CpXLJckI.js} +1 -1
  49. package/dist/client/assets/{agent-file-Cao_W_me.js → agent-file-Cak5KHUl.js} +1 -1
  50. package/dist/client/assets/{agent-hosting-5VKfgGQd.js → agent-hosting-2pI_IIlr.js} +1 -1
  51. package/dist/client/assets/{agent-icon-CAaO4ypa.js → agent-icon-BTsTGfvr.js} +1 -1
  52. package/dist/client/assets/agent-library-CGtmUhYD.js +1 -0
  53. package/dist/client/assets/agent-library-file-CZlCJsi6.js +1 -0
  54. package/dist/client/assets/{agent-monitor-UjHCObOn.js → agent-monitor-BRq8qrkU.js} +1 -1
  55. package/dist/client/assets/{agent-overview-CARG35t2.js → agent-overview-UU6Y44eX.js} +1 -1
  56. package/dist/client/assets/agent-settings-_tzBjLDX.js +1 -0
  57. package/dist/client/assets/{agent-site-editor-CXDMfxCU.js → agent-site-editor-LLur_-_o.js} +1 -1
  58. package/dist/client/assets/agent-site-editor-code-DA20Pk7L.js +2 -0
  59. package/dist/client/assets/{agent-site-editor-content-BAjBb750.js → agent-site-editor-content-DXvV_eiy.js} +3 -3
  60. package/dist/client/assets/agent-site-editor-preview-5ii-TR0s.js +518 -0
  61. package/dist/client/assets/agent-view-CgtvUhvS.js +1 -0
  62. package/dist/client/assets/{agent-view-guard-1XKy1jVJ.js → agent-view-guard-CyNRuQw7.js} +1 -1
  63. package/dist/client/assets/{agents-list-BKQ9GkqQ.js → agents-list-BVqV3SYd.js} +1 -1
  64. package/dist/client/assets/{ai-providers-DQvwi-LI.js → ai-providers-jNZBkRl5.js} +1 -1
  65. package/dist/client/assets/{alert-DEeNrGpM.js → alert-B2FW115A.js} +1 -1
  66. package/dist/client/assets/{alert-dialog-DhiFzLmM.js → alert-dialog-Dr31Gqkz.js} +1 -1
  67. package/dist/client/assets/{analytics-sections-BW-0HIcE.js → analytics-sections-DOFncpfM.js} +1 -1
  68. package/dist/client/assets/{api-keys-B6xfTHb9.js → api-keys-DPKcfTUa.js} +1 -1
  69. package/dist/client/assets/api-keys-DXlZlPNT.js +1 -0
  70. package/dist/client/assets/app-editor-BlHRP4Rp.js +1 -0
  71. package/dist/client/assets/{asset-utils-RYK8HJ3w.js → asset-utils-CX1te1rQ.js} +1 -1
  72. package/dist/client/assets/{auth-CFVKU9If.js → auth-CM-DdMTE.js} +1 -1
  73. package/dist/client/assets/{auth-catchall-UV-w9rG5.js → auth-catchall-D9Jl5rTX.js} +1 -1
  74. package/dist/client/assets/{auth-entry-DI7FcrqT.js → auth-entry-Cn0jyyw6.js} +1 -1
  75. package/dist/client/assets/{auth-split-layout-CuIKSb1N.js → auth-split-layout-DiVs6WJ3.js} +1 -1
  76. package/dist/client/assets/{authenticate-and-persist-oauth-C4TrLSCm.js → authenticate-and-persist-oauth-DEaKhdcs.js} +1 -1
  77. package/dist/client/assets/{automation-list-row-Dv9cy6ec.js → automation-list-row-CG7kU51M.js} +1 -1
  78. package/dist/client/assets/{automation-runs-qbW12Sit.js → automation-runs-CGQu-nIx.js} +1 -1
  79. package/dist/client/assets/{automations-CVxx9AvI.js → automations-D9LXua4J.js} +1 -1
  80. package/dist/client/assets/{autosend-DqvDhR1V.js → autosend-B7QA12Tw.js} +1 -1
  81. package/dist/client/assets/{avatar-DC1Cmzej.js → avatar-ByGDtOvp.js} +1 -1
  82. package/dist/client/assets/{badge-C85ocGTA.js → badge-XA4dRNYq.js} +1 -1
  83. package/dist/client/assets/{block-document-DQft1xyS.js → block-document-B0n4B4IP.js} +1 -1
  84. package/dist/client/assets/{blocks-preview-workspace-context-6ZMkVqw_.js → blocks-preview-workspace-context-C7bCK2dG.js} +1 -1
  85. package/dist/client/assets/{blog-schema-vO6IoJBM.js → blog-schema-D2K9lxFN.js} +1 -1
  86. package/dist/client/assets/{board-analytics-DatP--tQ.js → board-analytics-B5mmzmBe.js} +1 -1
  87. package/dist/client/assets/{buckets-Cczodic8.js → buckets-Qu8B15tT.js} +1 -1
  88. package/dist/client/assets/{build-improve-prompt-doc-BQEdJK2P.js → build-improve-prompt-doc-on-tpDMo.js} +1 -1
  89. package/dist/client/assets/{calendar-BUi8IxeZ.js → calendar-CRpUCA4p.js} +1 -1
  90. package/dist/client/assets/{capability-load-error-rL1NTtJa.js → capability-load-error-Cwp75ry8.js} +1 -1
  91. package/dist/client/assets/{category-editor-B_XTuKuu.js → category-editor-B9myg9lh.js} +1 -1
  92. package/dist/client/assets/{chart-CjiGuzpk.js → chart-CvxQFl1V.js} +1 -1
  93. package/dist/client/assets/{chat-context-oLIKqlGE.js → chat-context-Cwuqjrlx.js} +1 -1
  94. package/dist/client/assets/{chat-draft-Cgc2XQsH.js → chat-draft-D0btcSjz.js} +1 -1
  95. package/dist/client/assets/{checkbox-DZ-_DOro.js → checkbox-DSNt2gzr.js} +1 -1
  96. package/dist/client/assets/{choose-editor-CryRu8AV.js → choose-editor-BKZj3uPE.js} +1 -1
  97. package/dist/client/assets/{claim-phase-copy--pyKC4gk.js → claim-phase-copy-DWZtPw6h.js} +1 -1
  98. package/dist/client/assets/{cli-auth-success-DmgEVi8V.js → cli-auth-success-C6o7zJ2p.js} +1 -1
  99. package/dist/client/assets/{client-icons-Dr3qA-pT.js → client-icons-BpKVWun3.js} +1 -1
  100. package/dist/client/assets/{collapsible-D6DR3zQ4.js → collapsible-DOY0YL_H.js} +1 -1
  101. package/dist/client/assets/{collection-detail-CDuDEGYz.js → collection-detail--7z4uSdQ.js} +1 -1
  102. package/dist/client/assets/{collection-display-button-DoIjEbJ3.js → collection-display-button-Dtu1j77F.js} +1 -1
  103. package/dist/client/assets/{collection-search-CacvIdKe.js → collection-search-DdqYzjim.js} +1 -1
  104. package/dist/client/assets/{collection-table-wrapper-hyzp9jUd.js → collection-table-wrapper-8VyRclLN.js} +1 -1
  105. package/dist/client/assets/{collection-tabs-ywProb31.js → collection-tabs-CWwn3uMq.js} +1 -1
  106. package/dist/client/assets/{column-rules-BK42oUF9.js → column-rules-_Ma8ZWf4.js} +1 -1
  107. package/dist/client/assets/{combobox-DOrn42oJ.js → combobox-D7N8SC25.js} +1 -1
  108. package/dist/client/assets/{command-fqp-0b5f.js → command-Crl7raeC.js} +1 -1
  109. package/dist/client/assets/{companion-mcps-section-CzRe8aZa.js → companion-mcps-section-DkjOETuc.js} +1 -1
  110. package/dist/client/assets/{config-CIO93PJU.js → config-YLu1LJhW.js} +1 -1
  111. package/dist/client/assets/{connect-Be6_BDOH.js → connect-BbV6U_hr.js} +1 -1
  112. package/dist/client/assets/{connect-layout-Dgmc1sNX.js → connect-layout-CQuvObDD.js} +1 -1
  113. package/dist/client/assets/{connection-BCelELHr.js → connection-BVvM5npe.js} +1 -1
  114. package/dist/client/assets/{connection-card-BWXrChNc.js → connection-card-sWgF9uUo.js} +1 -1
  115. package/dist/client/assets/{connection-detail-B7kDdVY9.js → connection-detail-AG67uG4I.js} +1 -1
  116. package/dist/client/assets/{connection-form-helpers-DCUMal7M.js → connection-form-helpers-Je0bq7c_.js} +1 -1
  117. package/dist/client/assets/{connections-BYbkoIDQ.js → connections-Dc6s7_rq.js} +1 -1
  118. package/dist/client/assets/{context-ByfIilVn.js → context-DgLSgDvh.js} +1 -1
  119. package/dist/client/assets/{context-menu-CiGJumcW.js → context-menu-JVsCdcDt.js} +1 -1
  120. package/dist/client/assets/{core.esm-C2_DCN6Y.js → core.esm-CIWIcR9H.js} +1 -1
  121. package/dist/client/assets/{create-organization-dialog-BHthlR2A.js → create-organization-dialog-Ddjs5dmA.js} +1 -1
  122. package/dist/client/assets/{daily-pulse-E_FUA1NH.js → daily-pulse-Dpe4FA_b.js} +1 -1
  123. package/dist/client/assets/{device-hint-DA_uRg_p.js → device-hint-D9SLM9ag.js} +1 -1
  124. package/dist/client/assets/{discover-J_sID2RZ.js → discover-DlwaiXCQ.js} +1 -1
  125. package/dist/client/assets/{domain-settings-BrzCpB_6.js → domain-settings-CwEiepSy.js} +1 -1
  126. package/dist/client/assets/{drawer-BMuDp3pZ.js → drawer-3zPC7EI9.js} +1 -1
  127. package/dist/client/assets/{editor-Dq4IMcxm.js → editor-BMb1eAhF.js} +1 -1
  128. package/dist/client/assets/{empty-state-DvEOfDhm.js → empty-state-DUChmUAz.js} +1 -1
  129. package/dist/client/assets/{empty-state-BV6Ywh9y.js → empty-state-DuauqtRJ.js} +1 -1
  130. package/dist/client/assets/{extract-connection-data-DU6Jox_T.js → extract-connection-data-DQ0ThsQw.js} +1 -1
  131. package/dist/client/assets/{feature-gate-BZc24_E5.js → feature-gate-DGH8G4ta.js} +1 -1
  132. package/dist/client/assets/{feature-paywall-D03mknXg.js → feature-paywall-Cdd2Shxl.js} +1 -1
  133. package/dist/client/assets/{file-explorer-Lz97U563.js → file-explorer-DPT-Gdf2.js} +1 -1
  134. package/dist/client/assets/{file-preview-CV8hE6WA.js → file-preview-wTY5J2MC.js} +1 -1
  135. package/dist/client/assets/{file-share-button-Bdi3sj_s.js → file-share-button-D4Hp3Pwr.js} +1 -1
  136. package/dist/client/assets/{file-type-icon-OOS78AjU.js → file-type-icon-7-3yF331.js} +1 -1
  137. package/dist/client/assets/flat-project-CNnQaq5E.js +1 -0
  138. package/dist/client/assets/{folder-icon-B0QLaV9K.js → folder-icon-H82laJL_.js} +1 -1
  139. package/dist/client/assets/{form-CZcQhZCa.js → form-BUOiUceD.js} +1 -1
  140. package/dist/client/assets/{general-BMgatBn-.js → general-BHuT0FSK.js} +1 -1
  141. package/dist/client/assets/{home-D1UZSXtn.js → home-BZZrU9O7.js} +1 -1
  142. package/dist/client/assets/{icon-button-DbTR-7FA.js → icon-button-DMzM4KWP.js} +1 -1
  143. package/dist/client/assets/{index-DcG5TBas.js → index-BVCIU8Mk.js} +1 -1
  144. package/dist/client/assets/{index-BrozBhiV.js → index-BmBVOCXW.js} +1 -1
  145. package/dist/client/assets/{index-BvTG_LLZ.js → index-CerQwuGf.js} +1 -1
  146. package/dist/client/assets/{index-Cql9s2oo.js → index-CvkEcM9-.js} +1 -1
  147. package/dist/client/assets/{index-BG5IZjO1.js → index-D5kx2mq6.js} +1 -1
  148. package/dist/client/assets/{index-BvhG_GL8.js → index-DIbARVXx.js} +3 -3
  149. package/dist/client/assets/{index-D_2G1SLW.js → index-D_C9gk4l.js} +1 -1
  150. package/dist/client/assets/{index-CX4bp0FC.js → index-D_aXURjc.js} +1 -1
  151. package/dist/client/assets/{index-D-F3H3Df.js → index-PaA2bHVT.js} +1 -1
  152. package/dist/client/assets/{index-DYLoE6lZ.js → index-V8pRA7Xy.js} +3 -3
  153. package/dist/client/assets/{index-C9YSJ0Pi.js → index-eP3gZugt.js} +1 -1
  154. package/dist/client/assets/{index-Box10IZB.js → index-gHDeYn5U.js} +1 -1
  155. package/dist/client/assets/{index-redirect-DnUfmxMQ.js → index-redirect-6gCqz6Y5.js} +1 -1
  156. package/dist/client/assets/{index-Cj4602fN.js → index-x-BjYR-J.js} +1 -1
  157. package/dist/client/assets/{infiniteQueryObserver-C-FPZrNN.js → infiniteQueryObserver-Bni-1Rrc.js} +1 -1
  158. package/dist/client/assets/{infra-billing-51h8KhW5.js → infra-billing-hHO33Bt1.js} +1 -1
  159. package/dist/client/assets/{input-B0wYSpb2.js → input-C7fKNsaf.js} +1 -1
  160. package/dist/client/assets/{input-Bv9QfIGh.js → input-ynU6Ij5H.js} +3 -3
  161. package/dist/client/assets/{integration-icon-CDrootbG.js → integration-icon-D-qpZQt8.js} +1 -1
  162. package/dist/client/assets/{jira-icon-BYFRiv-4.js → jira-icon-B4wDBFAC.js} +1 -1
  163. package/dist/client/assets/{label-COS7xlc4.js → label-3hwvsVXP.js} +1 -1
  164. package/dist/client/assets/{layout-CBzBOevY.js → layout-DHC2Bj1E.js} +1 -1
  165. package/dist/client/assets/{legacy-agents-deep-MO8oblzi.js → legacy-agents-deep-BSzJqFgZ.js} +1 -1
  166. package/dist/client/assets/{legacy-main-redirect-CudcgLCq.js → legacy-main-redirect-R36lgGCg.js} +1 -1
  167. package/dist/client/assets/library-BfEEZWGX.js +1 -0
  168. package/dist/client/assets/{library-tab-BhC4uvZL.js → library-tab-DiWbCdAf.js} +1 -1
  169. package/dist/client/assets/{login-DhV7QjVw.js → login-BPcnReJQ.js} +1 -1
  170. package/dist/client/assets/{markdown-FpxtcMsE.js → markdown-C_bpsjlQ.js} +1 -1
  171. package/dist/client/assets/{mcp-app-renderer-oNRSzgIY.js → mcp-app-renderer-DSXHJ5Wt.js} +1 -1
  172. package/dist/client/assets/{mcp-oauth-hlA0Q-1K.js → mcp-oauth-7pqu8EiB.js} +1 -1
  173. package/dist/client/assets/{mcp-oauth-_2kQOfTH.js → mcp-oauth-DLnUq2f9.js} +1 -1
  174. package/dist/client/assets/{members-NF923Ad9.js → members-Bunz7e6B.js} +1 -1
  175. package/dist/client/assets/{memory-CkWrgyW6.js → memory-BLa9O78J.js} +1 -1
  176. package/dist/client/assets/{mini-report-page-CtUg6esm.js → mini-report-page-BVO6pALW.js} +1 -1
  177. package/dist/client/assets/{mock-board-BbcelWvr.js → mock-board-B5k1LNJu.js} +1 -1
  178. package/dist/client/assets/{monaco-editor-DOjflLD3.js → monaco-editor-DMfRj7kt.js} +1 -1
  179. package/dist/client/assets/{monitoring-stats-row-5gnR_PsS.js → monitoring-stats-row-Bkq-86wh.js} +1 -1
  180. package/dist/client/assets/{multi-select-DHbRaRWn.js → multi-select-BwXBmTlI.js} +1 -1
  181. package/dist/client/assets/{mustache-CUJOpa04.js → mustache-CEXj2Yiz.js} +1 -1
  182. package/dist/client/assets/{new-project-dialog-Bytx7uX5.js → new-project-dialog-BZdoOBOz.js} +1 -1
  183. package/dist/client/assets/{oauth-callback-ai-provider-DHi7-rTD.js → oauth-callback-ai-provider-CbuzeLlJ.js} +1 -1
  184. package/dist/client/assets/{oauth-callback-BOiaAtqL.js → oauth-callback-z1ZK2Q1I.js} +1 -1
  185. package/dist/client/assets/{onboarding-BcQ_H-Ta.js → onboarding-BGszMdtv.js} +1 -1
  186. package/dist/client/assets/{openai-conversation-BgjVhT0d.js → openai-conversation-B5OySV1i.js} +1 -1
  187. package/dist/client/assets/{optimistic-project-sidebar-views-DuLy3JAN.js → optimistic-project-sidebar-views-C2x-Aaxu.js} +1 -1
  188. package/dist/client/assets/{organization-choice-obmsj85V.js → organization-choice-xhN7Yznf.js} +1 -1
  189. package/dist/client/assets/{orgs-D5F2hLXP.js → orgs-CEeF7hFm.js} +1 -1
  190. package/dist/client/assets/{page-seo-form-Ba1SWsx7.js → page-seo-form-J-VUwESz.js} +1 -1
  191. package/dist/client/assets/{pair-DfD0HGLO.js → pair-Dha2uqa_.js} +1 -1
  192. package/dist/client/assets/{plan-ladder-ByxenYnr.js → plan-ladder-BNRju_Rr.js} +1 -1
  193. package/dist/client/assets/{popover-CsrTLLWE.js → popover-CZB8RxoJ.js} +1 -1
  194. package/dist/client/assets/{post-calendar-CAVjY12v.js → post-calendar-CfLX9e_7.js} +1 -1
  195. package/dist/client/assets/{post-editor-CLhXk7zA.js → post-editor-BBmmo40q.js} +1 -1
  196. package/dist/client/assets/{preview-content-CcXQsTVX.js → preview-content-DCZG-NtD.js} +1 -1
  197. package/dist/client/assets/{preview-dialog-CuP09SDy.js → preview-dialog-DZmQ4_OU.js} +1 -1
  198. package/dist/client/assets/{preview-panel-si7dSHQt.js → preview-panel-BOJOfHU6.js} +1 -1
  199. package/dist/client/assets/{product-picker-dialog-Ch2ijOSh.js → product-picker-dialog-BRcRXNTc.js} +1 -1
  200. package/dist/client/assets/{profile-D0l--Bsl.js → profile-CtDXcfuO.js} +1 -1
  201. package/dist/client/assets/{project-app-view-Bz65jJNr.js → project-app-view-Cnchb-Ig.js} +1 -1
  202. package/dist/client/assets/{project-feed-DSA4fOC7.js → project-feed-Ctubs6D8.js} +1 -1
  203. package/dist/client/assets/{project-icon-C-N3cJkz.js → project-icon-DXev8VIW.js} +1 -1
  204. package/dist/client/assets/project-reports-Ci_iYRrd.js +1 -0
  205. package/dist/client/assets/project-tasks-CzZdSRDI.js +1 -0
  206. package/dist/client/assets/{projects-DvvpjGnZ.js → projects-DfF5wpqY.js} +1 -1
  207. package/dist/client/assets/{projects-empty-state-DfvyQfpd.js → projects-empty-state-Bkvn9wBz.js} +1 -1
  208. package/dist/client/assets/{prompts-BuofI3_s.js → prompts-JCRZXZfZ.js} +1 -1
  209. package/dist/client/assets/record-editor-BmUK9heP.js +1 -0
  210. package/dist/client/assets/redirect-editor-DARWO6oY.js +1 -0
  211. package/dist/client/assets/{reports-DOq1hOqC.js → reports-BiB14-w5.js} +1 -1
  212. package/dist/client/assets/reports-CJkqLIIg.js +1 -0
  213. package/dist/client/assets/{reports-onboarding-BC8kmZ8I.js → reports-onboarding-Ci2eFzgb.js} +1 -1
  214. package/dist/client/assets/{reports-tab-3R3ocdaz.js → reports-tab-CfLfXENf.js} +2 -2
  215. package/dist/client/assets/{repositories-Bt6nbmSu.js → repositories-Ddu7D_dm.js} +1 -1
  216. package/dist/client/assets/{repository-binding-4wb1SqGi.js → repository-binding-CGM8Ow1W.js} +1 -1
  217. package/dist/client/assets/{repository-import-picker-DgjVp-Rp.js → repository-import-picker-DpjUG5YI.js} +1 -1
  218. package/dist/client/assets/{repository-picker-Dhir_mBD.js → repository-picker-XHsJQrRg.js} +1 -1
  219. package/dist/client/assets/{require-capability-BXoL3s4D.js → require-capability-D5tJwX6A.js} +1 -1
  220. package/dist/client/assets/{required-auth-layout-rplY5gMF.js → required-auth-layout-BKYCK4WE.js} +1 -1
  221. package/dist/client/assets/{reset-password-CNXROw6o.js → reset-password-BDIEd0mg.js} +1 -1
  222. package/dist/client/assets/{resizable-CYDmoKgw.js → resizable-DBUNvXp7.js} +1 -1
  223. package/dist/client/assets/{resolve-tab-icon-CIzsgPiq.js → resolve-tab-icon-C3-zJZHp.js} +1 -1
  224. package/dist/client/assets/{review-settings-CIijxO9K.js → review-settings-iKeIZIxh.js} +1 -1
  225. package/dist/client/assets/{rich-text-link-control-BlJN8nO0.js → rich-text-link-control-B-mX9xD1.js} +1 -1
  226. package/dist/client/assets/{roles-rqo1THOy.js → roles-B4ZkD532.js} +1 -1
  227. package/dist/client/assets/{route-nWQgD8-7.js → route-Dbrk4VYq.js} +1 -1
  228. package/dist/client/assets/route-DmXxzobK.js +1 -0
  229. package/dist/client/assets/{route-D_4e8W74.js → route-lCR_XMKF.js} +1 -1
  230. package/dist/client/assets/{runnable-block-editor-Cq2CDyKN.js → runnable-block-editor-aENhZJE9.js} +1 -1
  231. package/dist/client/assets/{sandbox-lifecycle-context-qUf8Q_Xq.js → sandbox-lifecycle-context-BrrAiqEe.js} +1 -1
  232. package/dist/client/assets/{schema-B7T6zvOr.js → schema-DstuA0HH.js} +1 -1
  233. package/dist/client/assets/{scroll-area-C9CkDOV0.js → scroll-area-NCHj5pvE.js} +1 -1
  234. package/dist/client/assets/{search-input-CSa-vO3l.js → search-input-CdXxg7YI.js} +1 -1
  235. package/dist/client/assets/{search-toggle-CAbpMgN6.js → search-toggle-BepIBc_s.js} +1 -1
  236. package/dist/client/assets/{secret-picker-DoaNLSBs.js → secret-picker-C6OYpb8W.js} +1 -1
  237. package/dist/client/assets/{secrets-byDlZpmy.js → secrets-CZl02iRQ.js} +1 -1
  238. package/dist/client/assets/{sections-editor-Bhx-Ytw3.js → sections-editor-C91NghHX.js} +1 -1
  239. package/dist/client/assets/{select-BTxDOmEz.js → select-XceA90ql.js} +1 -1
  240. package/dist/client/assets/{select-model-DXgRM3p3.js → select-model-Cn7hOiT6.js} +1 -1
  241. package/dist/client/assets/{seo-editor-SjuXgM-3.js → seo-editor-BFWV0Cx1.js} +1 -1
  242. package/dist/client/assets/{separator-i5pMbmNF.js → separator-BTLDrzUc.js} +1 -1
  243. package/dist/client/assets/{settings-tab-CKfMYuwP.js → settings-tab-BqJQ3uPx.js} +1 -1
  244. package/dist/client/assets/{sheet-B-Hh_nak.js → sheet-wemU-aZ9.js} +1 -1
  245. package/dist/client/assets/{shell-layout-BYblzqjk.js → shell-layout-C7bQvu8M.js} +1 -1
  246. package/dist/client/assets/{skills-D04V2qi_.js → skills-BqpJ6duC.js} +1 -1
  247. package/dist/client/assets/{slider-D3apdx8g.js → slider-INBQ4Ci_.js} +1 -1
  248. package/dist/client/assets/{sortable.esm-BcPKBoEH.js → sortable.esm-jUEYWtPl.js} +1 -1
  249. package/dist/client/assets/{sso-Ba8xYn_P.js → sso-D804RM9B.js} +1 -1
  250. package/dist/client/assets/{suggestion-yrhgs0c3.js → suggestion-DIwPOBWx.js} +1 -1
  251. package/dist/client/assets/{switch-Bv7OaKpB.js → switch-J8K3vNdb.js} +1 -1
  252. package/dist/client/assets/{symbol-CotFyP2y.js → symbol-lUKWgdXD.js} +1 -1
  253. package/dist/client/assets/{synced-repos-MTGAuYvc.js → synced-repos-gT4FkxhN.js} +1 -1
  254. package/dist/client/assets/{tab-icon-glyph-gJ6W_ogl.js → tab-icon-glyph-DF33b7XO.js} +1 -1
  255. package/dist/client/assets/{table-CMo_Zd79.js → table-Bgls4vq9.js} +1 -1
  256. package/dist/client/assets/{tabs-DsQwfF9n.js → tabs-Duy7ODee.js} +1 -1
  257. package/dist/client/assets/{task-board-jYYT4T-P.js → task-board-DPQxW0jP.js} +1 -1
  258. package/dist/client/assets/{task-route-CWhoPEpW.js → task-route-BQDNl_5C.js} +1 -1
  259. package/dist/client/assets/{task-status-B1Q1IWuY.js → task-status-BGLLtgDf.js} +1 -1
  260. package/dist/client/assets/taskboard-analytics-2fBMPAxC.js +1 -0
  261. package/dist/client/assets/tasks-CqyFd60l.js +1 -0
  262. package/dist/client/assets/{tasks-sExg1TPS.js → tasks-IL-LS75-.js} +1 -1
  263. package/dist/client/assets/{textarea-CXxxIkE2.js → textarea-NyzjT40N.js} +1 -1
  264. package/dist/client/assets/{thread-analytics-CN8JIWoa.js → thread-analytics-CtoXhN32.js} +1 -1
  265. package/dist/client/assets/{thread-button-BjphGBFn.js → thread-button-BdG_noMn.js} +1 -1
  266. package/dist/client/assets/{thread-intent-Cv8T2W7d.js → thread-intent-k2Km9Dmr.js} +1 -1
  267. package/dist/client/assets/{thread-route-Y6_0A4lo.js → thread-route-Cx-o2xCf.js} +1 -1
  268. package/dist/client/assets/{thread-route-md0irSaA.js → thread-route-DbJLUn3d.js} +1 -1
  269. package/dist/client/assets/{thread-sheet-body-qCnpdPMv.js → thread-sheet-body-_3hMbQ_o.js} +1 -1
  270. package/dist/client/assets/{time-range-picker-nGk4jkHe.js → time-range-picker-CH7-gioV.js} +1 -1
  271. package/dist/client/assets/{toggle-group-MxDdKb-A.js → toggle-group-m6bc6yjp.js} +1 -1
  272. package/dist/client/assets/{tool-namespace-NA4CQCu7.js → tool-namespace-CPm912_s.js} +1 -1
  273. package/dist/client/assets/{toolbar-icon-button-DfPVpCUn.js → toolbar-icon-button-BxO5B0Sy.js} +1 -1
  274. package/dist/client/assets/{tooltip-D0bgPl8K.js → tooltip-C2m8ePE-.js} +1 -1
  275. package/dist/client/assets/{tooltipContext-BJ3U7dLG.js → tooltipContext-CxUJkkTI.js} +1 -1
  276. package/dist/client/assets/{track-BR4OSmkP.js → track-C5Z44Ul6.js} +1 -1
  277. package/dist/client/assets/{types-D0iAHfi-.js → types-ZqGSA7tu.js} +1 -1
  278. package/dist/client/assets/{url-slug-CsF5_jEJ.js → url-slug-DEN8nCcZ.js} +1 -1
  279. package/dist/client/assets/{usage-stats-DMZgLWXn.js → usage-stats-Dn2OeFoS.js} +1 -1
  280. package/dist/client/assets/{use-ai-providers-C1zAqMn5.js → use-ai-providers-jw2MMLa5.js} +1 -1
  281. package/dist/client/assets/{use-automations-guIq1Jf8.js → use-automations-D20-ruPj.js} +1 -1
  282. package/dist/client/assets/{use-autosave-KNHbArST.js → use-autosave-BYt2BXBs.js} +1 -1
  283. package/dist/client/assets/{use-chat-layout-state-DiI7M741.js → use-chat-layout-state-WRaaYm0y.js} +1 -1
  284. package/dist/client/assets/{use-chat-navigation-CoFd5UE7.js → use-chat-navigation-FGqN2bea.js} +1 -1
  285. package/dist/client/assets/{use-clock-tick-BMgzMfT6.js → use-clock-tick-DWBHoA2Q.js} +1 -1
  286. package/dist/client/assets/{use-connect-companion-BNtTOOiR.js → use-connect-companion-m9MlzSIA.js} +1 -1
  287. package/dist/client/assets/{use-connection-BlwV3kYC.js → use-connection-B2P9vQF_.js} +1 -1
  288. package/dist/client/assets/{use-copy-BzyND5sN.js → use-copy-Cu3Byc8S.js} +1 -1
  289. package/dist/client/assets/{use-create-virtual-mcp-CRjB3w_a.js → use-create-virtual-mcp-C8rAImjt.js} +1 -1
  290. package/dist/client/assets/{use-date-fns-locale-DHjSaunn.js → use-date-fns-locale-Beq3354R.js} +1 -1
  291. package/dist/client/assets/{use-debounced-autosave-DzioetsZ.js → use-debounced-autosave-DrUzoxBu.js} +1 -1
  292. package/dist/client/assets/{use-debounced-value-Bw9XyFDS.js → use-debounced-value-SDDhu8Id.js} +1 -1
  293. package/dist/client/assets/{use-deco-credits-BwBAsZjN.js → use-deco-credits-sdJPRntH.js} +1 -1
  294. package/dist/client/assets/{use-decopilot-events-LdqK-BR8.js → use-decopilot-events-CvdvLxq8.js} +1 -1
  295. package/dist/client/assets/{use-delete-connection-B1009COB.js → use-delete-connection-BOHbZqa4.js} +1 -1
  296. package/dist/client/assets/{use-deployment-admin-DqRcHfUs.js → use-deployment-admin-C-HUVf8B.js} +1 -1
  297. package/dist/client/assets/{use-ensure-project-folder-q_3EwSkl.js → use-ensure-project-folder-BS99-Vhk.js} +1 -1
  298. package/dist/client/assets/{use-fast-preview-draft-url-BGVVIo_d.js → use-fast-preview-draft-url-C5x2lifG.js} +1 -1
  299. package/dist/client/assets/{use-file-configs-CiMmOBPH.js → use-file-configs-CfW92ECv.js} +1 -1
  300. package/dist/client/assets/{use-infinite-scroll-CFznRnci.js → use-infinite-scroll-lPN0NCUm.js} +1 -1
  301. package/dist/client/assets/{use-join-requests-LdDd-D1N.js → use-join-requests-ChCzkc7_.js} +1 -1
  302. package/dist/client/assets/{use-main-panel-tabs-BVPkp8pd.js → use-main-panel-tabs-Dsv5nepq.js} +1 -1
  303. package/dist/client/assets/{use-mcp-auth-status-BAmLODpB.js → use-mcp-auth-status-DRKL-P8f.js} +1 -1
  304. package/dist/client/assets/{use-mcp-client-CyZFCbXf.js → use-mcp-client-CqsBL7uD.js} +1 -1
  305. package/dist/client/assets/{use-mcp-prompts-hbtCEuPx.js → use-mcp-prompts-1ZUYIWAu.js} +1 -1
  306. package/dist/client/assets/{use-mcp-tools-CqwLSwPQ.js → use-mcp-tools-D_yHtzDx.js} +1 -1
  307. package/dist/client/assets/{use-members-0uvS2aBL.js → use-members-BTcdjICA.js} +1 -1
  308. package/dist/client/assets/{use-mobile-DsnBmTih.js → use-mobile-D2A_YY4A.js} +1 -1
  309. package/dist/client/assets/{use-navigate-to-agent-e1Fty-W6.js → use-navigate-to-agent-RUWGGNCj.js} +1 -1
  310. package/dist/client/assets/use-new-blocks-editor-APcQuu-Z.js +1 -0
  311. package/dist/client/assets/{use-open-billing-url-CtVqEeze.js → use-open-billing-url-tDUbFoyb.js} +1 -1
  312. package/dist/client/assets/{use-org-auth-client--vi1jVLH.js → use-org-auth-client-qz-rdd-6.js} +1 -1
  313. package/dist/client/assets/{use-org-fs-XuRHX-wd.js → use-org-fs-Bpw1hkjS.js} +1 -1
  314. package/dist/client/assets/{use-org-repo-syncs-DIFvvjD1.js → use-org-repo-syncs-Dgz3AX_E.js} +1 -1
  315. package/dist/client/assets/{use-org-sso-BY1EpA2d.js → use-org-sso-FN6Hp6_O.js} +1 -1
  316. package/dist/client/assets/{use-organization-roles-WaawCXoD.js → use-organization-roles-lOM-6Cks.js} +1 -1
  317. package/dist/client/assets/{use-organization-settings-wIzO33y-.js → use-organization-settings-CvwbmZME.js} +1 -1
  318. package/dist/client/assets/{use-panel-navigate-BNghtY2T.js → use-panel-navigate-BcP-4Jk4.js} +1 -1
  319. package/dist/client/assets/{use-project-scope-kaofAo-2.js → use-project-scope-Ds7ag806.js} +1 -1
  320. package/dist/client/assets/{use-releases-DGpmgwQI.js → use-releases-DedSt3np.js} +1 -1
  321. package/dist/client/assets/{use-reports-diagnostic-C5t0yrnl.js → use-reports-diagnostic-CO2atgBG.js} +1 -1
  322. package/dist/client/assets/{use-sandbox-events-DFZHFjJV.js → use-sandbox-events-Cqb_Ym4F.js} +1 -1
  323. package/dist/client/assets/{use-secrets-H7WJMT_o.js → use-secrets-BjvGVY7t.js} +1 -1
  324. package/dist/client/assets/{use-section-preview-base-7My4H7me.js → use-section-preview-base-CoG0-wMI.js} +1 -1
  325. package/dist/client/assets/{use-tags-LkAv2_8e.js → use-tags-ja0CaL2g.js} +1 -1
  326. package/dist/client/assets/{use-task-board-analytics-DYzMdhLH.js → use-task-board-analytics-Dx24ixKr.js} +1 -1
  327. package/dist/client/assets/{use-task-board-events-DFFKnQzP.js → use-task-board-events-CZieAk2g.js} +1 -1
  328. package/dist/client/assets/{use-task-board-item-prs-DlBSKV0p.js → use-task-board-item-prs-C_5W7zcg.js} +1 -1
  329. package/dist/client/assets/{use-task-board-items-GPnynZhW.js → use-task-board-items-CkoW6-bn.js} +1 -1
  330. package/dist/client/assets/{use-task-metadata-Bj-IbI9d.js → use-task-metadata-C-eJemLF.js} +1 -1
  331. package/dist/client/assets/{use-thread-analytics-BaY4EBEv.js → use-thread-analytics-B8zFfdhr.js} +1 -1
  332. package/dist/client/assets/{use-thread-outputs-BE4mR7oi.js → use-thread-outputs-CHIrdXyI.js} +1 -1
  333. package/dist/client/assets/useInfiniteQuery-Cyz1DFAa.js +1 -0
  334. package/dist/client/assets/{useQueries-F64PMR6y.js → useQueries-Dpxh6EqM.js} +1 -1
  335. package/dist/client/assets/useSuspenseInfiniteQuery-B0qRbG8m.js +1 -0
  336. package/dist/client/assets/{users-BjFgJ7AD.js → users-xDH1jmUT.js} +1 -1
  337. package/dist/client/assets/{utils-DgqX0z1b.js → utils-BBHV2kqf.js} +1 -1
  338. package/dist/client/assets/{variant-calendar-DLNhYnQf.js → variant-calendar-BJGksOpn.js} +1 -1
  339. package/dist/client/assets/{variant-matcher-override-D3WXi6Ga.js → variant-matcher-override-3KgTJsm9.js} +1 -1
  340. package/dist/client/assets/{view-mode-toggle-0cm3AkV5.js → view-mode-toggle-5lUXeBq8.js} +1 -1
  341. package/dist/client/assets/{virtual-mcp-C_TeGFZa.js → virtual-mcp-CKveTc8W.js} +1 -1
  342. package/dist/client/assets/{watch-sse-pool-end_AVWu.js → watch-sse-pool-SMEeDp6D.js} +1 -1
  343. package/dist/client/index.html +1 -1
  344. package/dist/server/server.js +1 -1
  345. package/package.json +1 -1
  346. package/dist/client/assets/agent-app-BN1xlwca.js +0 -1
  347. package/dist/client/assets/agent-deck-gN98WSbp.js +0 -1
  348. package/dist/client/assets/agent-library-CxgcYBSr.js +0 -1
  349. package/dist/client/assets/agent-library-file-lpnZiokW.js +0 -1
  350. package/dist/client/assets/agent-settings-7e_XyBHe.js +0 -1
  351. package/dist/client/assets/agent-site-editor-code-yflTKEXl.js +0 -2
  352. package/dist/client/assets/agent-site-editor-preview-BgyDrf4u.js +0 -518
  353. package/dist/client/assets/agent-view-vQcOlN6j.js +0 -1
  354. package/dist/client/assets/api-keys-LZWLXizN.js +0 -1
  355. package/dist/client/assets/app-editor-B7dAjCr9.js +0 -1
  356. package/dist/client/assets/flat-project-Br0qxJS9.js +0 -1
  357. package/dist/client/assets/library-CMmULIMr.js +0 -1
  358. package/dist/client/assets/project-reports-iIDLiTtT.js +0 -1
  359. package/dist/client/assets/project-tasks-D52OJfjJ.js +0 -1
  360. package/dist/client/assets/record-editor-wVe5Wpmu.js +0 -1
  361. package/dist/client/assets/redirect-editor-D6yYqLjJ.js +0 -1
  362. package/dist/client/assets/reports-Bj-OdndV.js +0 -1
  363. package/dist/client/assets/route-3hj1gfVP.js +0 -1
  364. package/dist/client/assets/taskboard-analytics-BnPIIn86.js +0 -1
  365. package/dist/client/assets/tasks-aFMERcVH.js +0 -1
  366. package/dist/client/assets/use-new-blocks-editor-CGtkQLL-.js +0 -1
  367. package/dist/client/assets/useInfiniteQuery-D4wBC58J.js +0 -1
  368. package/dist/client/assets/useSuspenseInfiniteQuery-ZDUWj1v_.js +0 -1
@@ -1,4 +1,4 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/login-DhV7QjVw.js","assets/auth-entry-DI7FcrqT.js","assets/backoff-CrEUbyZT.js","assets/delay-CnY5UFtP.js","assets/auth-split-layout-CuIKSb1N.js","assets/cli-auth-success-DmgEVi8V.js","assets/oauth-callback-BOiaAtqL.js","assets/mcp-oauth-hlA0Q-1K.js","assets/auth-CFVKU9If.js","assets/layout-CBzBOevY.js","assets/required-auth-layout-rplY5gMF.js","assets/use-deployment-admin-DqRcHfUs.js","assets/users-BjFgJ7AD.js","assets/collection-table-wrapper-hyzp9jUd.js","assets/table-CMo_Zd79.js","assets/ArrowUp-4iK8zoCx.js","assets/empty-state-DvEOfDhm.js","assets/search-input-CSa-vO3l.js","assets/SearchMd-DhQxjm00.js","assets/avatar-DC1Cmzej.js","assets/User01-DXN8J2dA.js","assets/badge-C85ocGTA.js","assets/use-debounced-value-Bw9XyFDS.js","assets/admin-fetch-BhTJlAsX.js","assets/format-time-CjIPQhCN.js","assets/differenceInSeconds-C3x8sHUj.js","assets/get-initials-D-f_fDFw.js","assets/orgs-D5F2hLXP.js","assets/label-COS7xlc4.js","assets/select-BTxDOmEz.js","assets/index-BdQq_4o_.js","assets/index-Cql9s2oo.js","assets/ChevronUp-D_Wjh1Pp.js","assets/switch-Bv7OaKpB.js","assets/textarea-CXxxIkE2.js","assets/schema-B7T6zvOr.js","assets/site-slug-DebpOoQq.js","assets/prompts-BuofI3_s.js","assets/shell-layout-BYblzqjk.js","assets/Building02-DAEF4UrO.js","assets/UserSquare-B7AJhMXA.js","assets/agent-icon-CAaO4ypa.js","assets/AlertCircle-xh90NARB.js","assets/Tool01-DG06N0su.js","assets/ArrowLeft-Xffg7q8p.js","assets/LinkBroken01-wTJMvAdz.js","assets/ShoppingBag01-BJ4cJNkc.js","assets/ZoomOut-D4nHzX79.js","assets/CheckCircle-DUpC1qQ4.js","assets/ChevronSelectorVertical-DCkH1mIQ.js","assets/Copy01-BdyOQaoT.js","assets/CreditCard01-YN58MJQp.js","assets/DotsVertical-C0q218c1.js","assets/Image01-Drnu_oTX.js","assets/Globe04-brrhloqP.js","assets/SwitchHorizontal01-6WEEE86B.js","assets/Key01-DXKey19o.js","assets/Link01-DAwi9mlM.js","assets/Monitor01-Bm_bTKyL.js","assets/Sun-D0UkgT29.js","assets/Play-CqIDE5zC.js","assets/Plus-j4aDTi8e.js","assets/Trash01-C9lhbJs7.js","assets/Upload01-Bt337Shk.js","assets/Users01-CHS_3A2d.js","assets/XClose-pteQuwAH.js","assets/use-project-scope-kaofAo-2.js","assets/repository-binding-4wb1SqGi.js","assets/use-mcp-client-CyZFCbXf.js","assets/use-panel-navigate-BNghtY2T.js","assets/thread-route-md0irSaA.js","assets/use-clock-tick-BMgzMfT6.js","assets/command-fqp-0b5f.js","assets/index-DcG5TBas.js","assets/integration-icon-CDrootbG.js","assets/project-icon-C-N3cJkz.js","assets/new-project-dialog-Bytx7uX5.js","assets/repository-import-picker-DgjVp-Rp.js","assets/use-navigate-to-agent-e1Fty-W6.js","assets/thread-intent-Cv8T2W7d.js","assets/watch-sse-pool-end_AVWu.js","assets/task-board-jYYT4T-P.js","assets/slugify-CEUa2lfQ.js","assets/repository-picker-Dhir_mBD.js","assets/tooltip-D0bgPl8K.js","assets/useInfiniteQuery-D4wBC58J.js","assets/infiniteQueryObserver-C-FPZrNN.js","assets/collection-search-CacvIdKe.js","assets/use-organization-settings-wIzO33y-.js","assets/autosend-DqvDhR1V.js","assets/use-org-sso-BY1EpA2d.js","assets/shell-layout-CE2Eihra.css","assets/onboarding-BcQ_H-Ta.js","assets/organization-choice-obmsj85V.js","assets/reports-onboarding-BC8kmZ8I.js","assets/site-url-en5df9c-.js","assets/create-organization-dialog-BHthlR2A.js","assets/alert-dialog-DhiFzLmM.js","assets/form-CZcQhZCa.js","assets/companion-mcps-section-CzRe8aZa.js","assets/use-connect-companion-BNtTOOiR.js","assets/companions-core-DzyeM-yJ.js","assets/metadata-D72DunRR.js","assets/github-repo-scope-ByTYKy_L.js","assets/provision-repo-scoped-github-connection-lckxpDHD.js","assets/useQueries-F64PMR6y.js","assets/authenticate-and-persist-oauth-C4TrLSCm.js","assets/mcp-oauth-_2kQOfTH.js","assets/track-BR4OSmkP.js","assets/extract-connection-data-DU6Jox_T.js","assets/connection-BCelELHr.js","assets/url-slug-CsF5_jEJ.js","assets/self-tool-result-8OxPN9Nm.js","assets/site-error-Da6iapvu.js","assets/choose-editor-CryRu8AV.js","assets/reports-DOq1hOqC.js","assets/reports-Dl0n8WK0.css","assets/route-D_4e8W74.js","assets/thread-button-BjphGBFn.js","assets/use-chat-layout-state-DiI7M741.js","assets/use-file-configs-CiMmOBPH.js","assets/use-mobile-DsnBmTih.js","assets/sheet-B-Hh_nak.js","assets/toolbar-icon-button-DfPVpCUn.js","assets/core.esm-C2_DCN6Y.js","assets/sortable.esm-BcPKBoEH.js","assets/context-menu-CiGJumcW.js","assets/daily-pulse-E_FUA1NH.js","assets/config-CIO93PJU.js","assets/task-route-CWhoPEpW.js","assets/popover-CsrTLLWE.js","assets/drawer-BMuDp3pZ.js","assets/use-join-requests-LdDd-D1N.js","assets/use-org-auth-client--vi1jVLH.js","assets/use-organization-roles-WaawCXoD.js","assets/use-deco-credits-BwBAsZjN.js","assets/use-ai-providers-C1zAqMn5.js","assets/use-decopilot-events-LdqK-BR8.js","assets/plan-ladder-ByxenYnr.js","assets/scroll-area-C9CkDOV0.js","assets/use-task-board-items-GPnynZhW.js","assets/use-task-board-events-DFFKnQzP.js","assets/use-thread-analytics-BaY4EBEv.js","assets/project-profile-Cc4MG3QN.js","assets/optimistic-project-sidebar-views-DuLy3JAN.js","assets/resolve-tab-icon-CIzsgPiq.js","assets/tab-icon-glyph-gJ6W_ogl.js","assets/checkbox-DZ-_DOro.js","assets/icon-button-DbTR-7FA.js","assets/question-004-sINsf4GQ.js","assets/thread-route-Y6_0A4lo.js","assets/chat-context-oLIKqlGE.js","assets/use-chat-navigation-CoFd5UE7.js","assets/location-BjlyegC2.js","assets/use-reports-diagnostic-C5t0yrnl.js","assets/connect-layout-Dgmc1sNX.js","assets/route-nWQgD8-7.js","assets/use-sandbox-events-DFZHFjJV.js","assets/tool-namespace-NA4CQCu7.js","assets/use-mcp-prompts-hbtCEuPx.js","assets/usage-stats-DMZgLWXn.js","assets/utils-CVEq3hMx.js","assets/markdown-FpxtcMsE.js","assets/use-copy-BzyND5sN.js","assets/input-Bv9QfIGh.js","assets/file-type-icon-OOS78AjU.js","assets/chat-draft-Cgc2XQsH.js","assets/tabs-DsQwfF9n.js","assets/toggle-group-MxDdKb-A.js","assets/use-open-billing-url-CtVqEeze.js","assets/index-C9YSJ0Pi.js","assets/ai-providers-logos-DD3qZ33J.js","assets/input-B0wYSpb2.js","assets/suggestion-yrhgs0c3.js","assets/use-org-fs-XuRHX-wd.js","assets/use-members-0uvS2aBL.js","assets/feature-paywall-D03mknXg.js","assets/add-connection-dialog-BXB3P-4X.js","assets/connection-card-BWXrChNc.js","assets/connection-slug-CITJ0kGN.js","assets/use-connection-BlwV3kYC.js","assets/connection-form-helpers-DCUMal7M.js","assets/collection-tabs-ywProb31.js","assets/use-infinite-scroll-CFznRnci.js","assets/useSuspenseInfiniteQuery-ZDUWj1v_.js","assets/input-Bwd_JSM8.css","assets/pair-DfD0HGLO.js","assets/collapsible-D6DR3zQ4.js","assets/content-blocks-o63cs2vh.js","assets/mcp-app-renderer-oNRSzgIY.js","assets/types-D0iAHfi-.js","assets/omit-sandbox-map-jj4lCB2U.js","assets/use-thread-outputs-BE4mR7oi.js","assets/sandbox-url-D3mC8qhT.js","assets/use-releases-DGpmgwQI.js","assets/serial-task-queue-CGOeQgpr.js","assets/sandbox-lifecycle-context-qUf8Q_Xq.js","assets/sandbox-start-errors-BK_aDCyt.js","assets/index-D_2G1SLW.js","assets/resizable-CYDmoKgw.js","assets/task-status-B1Q1IWuY.js","assets/use-main-panel-tabs-BVPkp8pd.js","assets/use-mcp-tools-CqwLSwPQ.js","assets/use-task-metadata-Bj-IbI9d.js","assets/virtual-mcp-C_TeGFZa.js","assets/legacy-main-redirect-CudcgLCq.js","assets/preview-dialog-CuP09SDy.js","assets/preview-content-CcXQsTVX.js","assets/file-share-button-Bdi3sj_s.js","assets/file-preview-CV8hE6WA.js","assets/utils-DgqX0z1b.js","assets/editor-Dq4IMcxm.js","assets/blocks-preview-workspace-context-6ZMkVqw_.js","assets/home-D1UZSXtn.js","assets/chart-CjiGuzpk.js","assets/index-BG5IZjO1.js","assets/symbol-CotFyP2y.js","assets/CategoricalChart-CMQWnNBW.js","assets/AreaChart-hhJtx5W4.js","assets/use-automations-guIq1Jf8.js","assets/project-feed-DSA4fOC7.js","assets/mini-report-page-CtUg6esm.js","assets/client-icons-Dr3qA-pT.js","assets/projects-empty-state-DfvyQfpd.js","assets/flat-project-Br0qxJS9.js","assets/view-mode-toggle-0cm3AkV5.js","assets/index-BvhG_GL8.js","assets/use-task-board-analytics-DYzMdhLH.js","assets/combobox-DOrn42oJ.js","assets/column-rules-BK42oUF9.js","assets/search-toggle-CAbpMgN6.js","assets/use-tags-LkAv2_8e.js","assets/calendar-BUi8IxeZ.js","assets/alert-DEeNrGpM.js","assets/index-Cj4602fN.js","assets/rich-text-link-control-BlJN8nO0.js","assets/index-BvTG_LLZ.js","assets/use-task-board-item-prs-DlBSKV0p.js","assets/thread-sheet-body-qCnpdPMv.js","assets/separator-i5pMbmNF.js","assets/board-analytics-DatP--tQ.js","assets/time-range-picker-nGk4jkHe.js","assets/analytics-sections-BW-0HIcE.js","assets/BarChart-CvyDfHpd.js","assets/tooltipContext-BJ3U7dLG.js","assets/ActiveShapeUtils-C-buMql8.js","assets/Sector-Dhm7L79o.js","assets/ErrorBarContext-thUyR0rx.js","assets/XAxis-M9-_1D7_.js","assets/library-tab-BhC4uvZL.js","assets/use-org-repo-syncs-DIFvvjD1.js","assets/folder-icon-B0QLaV9K.js","assets/empty-state-BV6Ywh9y.js","assets/use-ensure-project-folder-q_3EwSkl.js","assets/agent-overview-CARG35t2.js","assets/project-tasks-D52OJfjJ.js","assets/feature-gate-BZc24_E5.js","assets/mock-board-BbcelWvr.js","assets/project-reports-iIDLiTtT.js","assets/reports-tab-3R3ocdaz.js","assets/agent-site-editor-CXDMfxCU.js","assets/claim-phase-copy--pyKC4gk.js","assets/device-hint-DA_uRg_p.js","assets/use-fast-preview-draft-url-BGVVIo_d.js","assets/section-preview-url-7zfngvgW.js","assets/sandbox-git-api-C7JbVL7R.js","assets/save-changes-debug-nBi-n9eV.js","assets/agent-site-editor-DDGTF8rc.css","assets/agent-site-editor-preview-BgyDrf4u.js","assets/agent-view-guard-1XKy1jVJ.js","assets/runnable-block-editor-Cq2CDyKN.js","assets/monaco-editor-DOjflLD3.js","assets/use-new-blocks-editor-CGtkQLL-.js","assets/asset-utils-RYK8HJ3w.js","assets/variant-matcher-override-D3WXi6Ga.js","assets/agent-site-editor-content-BAjBb750.js","assets/mustache-CUJOpa04.js","assets/agent-site-editor-code-yflTKEXl.js","assets/agent-automations-B3GOPyc3.js","assets/automation-list-row-Dv9cy6ec.js","assets/agent-automation-BhXRsqWt.js","assets/select-model-DXgRM3p3.js","assets/build-improve-prompt-doc-BQEdJK2P.js","assets/use-debounced-autosave-DzioetsZ.js","assets/jira-icon-BYFRiv-4.js","assets/multi-select-DHbRaRWn.js","assets/automation-runs-qbW12Sit.js","assets/agent-settings-7e_XyBHe.js","assets/settings-tab-CKfMYuwP.js","assets/use-date-fns-locale-DHjSaunn.js","assets/use-mcp-auth-status-BAmLODpB.js","assets/secret-picker-DoaNLSBs.js","assets/use-secrets-H7WJMT_o.js","assets/agent-library-CxgcYBSr.js","assets/agent-assets-Doo6qn_B.js","assets/agent-hosting-5VKfgGQd.js","assets/agent-e2e-CyiK0Nn8.js","assets/agent-analytics-C1qxm1L0.js","assets/taskboard-analytics-BnPIIn86.js","assets/agent-experiments-Dero6WeN.js","assets/slider-D3apdx8g.js","assets/index-Box10IZB.js","assets/agent-monitor-UjHCObOn.js","assets/agent-app-BN1xlwca.js","assets/project-app-view-Bz65jJNr.js","assets/agent-view-vQcOlN6j.js","assets/agent-file-Cao_W_me.js","assets/agent-deck-gN98WSbp.js","assets/agent-library-file-lpnZiokW.js","assets/preview-panel-si7dSHQt.js","assets/agent-connect-sources-Cj-TiW7a.js","assets/legacy-agents-deep-MO8oblzi.js","assets/tasks-aFMERcVH.js","assets/thread-analytics-CN8JIWoa.js","assets/reports-Bj-OdndV.js","assets/library-CMmULIMr.js","assets/discover-J_sID2RZ.js","assets/index-D-F3H3Df.js","assets/route-3hj1gfVP.js","assets/index-redirect-DnUfmxMQ.js","assets/capability-load-error-rL1NTtJa.js","assets/connections-BYbkoIDQ.js","assets/collection-display-button-DoIjEbJ3.js","assets/use-delete-connection-B1009COB.js","assets/connection-detail-B7kDdVY9.js","assets/index-BrozBhiV.js","assets/use-create-virtual-mcp-CRjB3w_a.js","assets/monitoring-stats-row-5gnR_PsS.js","assets/collection-detail-CDuDEGYz.js","assets/index-CX4bp0FC.js","assets/require-capability-BXoL3s4D.js","assets/access-gate-CNFrC5-Q.js","assets/general-BMgatBn-.js","assets/review-settings-CIijxO9K.js","assets/domain-settings-BrzCpB_6.js","assets/connect-Be6_BDOH.js","assets/api-keys-B6xfTHb9.js","assets/ai-providers-DQvwi-LI.js","assets/infra-billing-51h8KhW5.js","assets/secrets-byDlZpmy.js","assets/api-keys-LZWLXizN.js","assets/buckets-Cczodic8.js","assets/repositories-Bt6nbmSu.js","assets/synced-repos-MTGAuYvc.js","assets/tasks-sExg1TPS.js","assets/projects-DvvpjGnZ.js","assets/members-NF923Ad9.js","assets/role-color-Dn2tXDDF.js","assets/roles-rqo1THOy.js","assets/sso-Ba8xYn_P.js","assets/profile-D0l--Bsl.js","assets/agents-list-BKQ9GkqQ.js","assets/automations-CVxx9AvI.js","assets/skills-D04V2qi_.js","assets/memory-CkWrgyW6.js"])))=>i.map(i=>d[i]);
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/login-BPcnReJQ.js","assets/auth-entry-Cn0jyyw6.js","assets/backoff-CrEUbyZT.js","assets/delay-CnY5UFtP.js","assets/auth-split-layout-DiVs6WJ3.js","assets/cli-auth-success-C6o7zJ2p.js","assets/oauth-callback-z1ZK2Q1I.js","assets/mcp-oauth-7pqu8EiB.js","assets/auth-CM-DdMTE.js","assets/layout-DHC2Bj1E.js","assets/required-auth-layout-BKYCK4WE.js","assets/use-deployment-admin-C-HUVf8B.js","assets/users-xDH1jmUT.js","assets/collection-table-wrapper-8VyRclLN.js","assets/table-Bgls4vq9.js","assets/ArrowUp-D1danNae.js","assets/empty-state-DUChmUAz.js","assets/search-input-CdXxg7YI.js","assets/SearchMd-Bendi2p8.js","assets/avatar-ByGDtOvp.js","assets/User01-CT2R-iHD.js","assets/badge-XA4dRNYq.js","assets/use-debounced-value-SDDhu8Id.js","assets/admin-fetch-BhTJlAsX.js","assets/format-time-CjIPQhCN.js","assets/differenceInSeconds-C3x8sHUj.js","assets/get-initials-D-f_fDFw.js","assets/orgs-CEeF7hFm.js","assets/label-3hwvsVXP.js","assets/select-XceA90ql.js","assets/index-BdQq_4o_.js","assets/index-CvkEcM9-.js","assets/ChevronUp-wLOc_NTT.js","assets/switch-J8K3vNdb.js","assets/textarea-NyzjT40N.js","assets/schema-DstuA0HH.js","assets/site-slug-DebpOoQq.js","assets/prompts-JCRZXZfZ.js","assets/shell-layout-C7bQvu8M.js","assets/Building02-ssxWkdBl.js","assets/UserSquare-BuJqx7Ns.js","assets/agent-icon-BTsTGfvr.js","assets/AlertCircle-9YsZUjmj.js","assets/Tool01-B-kpMrMZ.js","assets/ArrowLeft-ZHARsvy9.js","assets/LinkBroken01-DGQh_3WZ.js","assets/ShoppingBag01-BG-1Jwuh.js","assets/ZoomOut-CVwCO-_8.js","assets/CheckCircle-DiKVJkkJ.js","assets/ChevronSelectorVertical-Dkzqp5pp.js","assets/Copy01-Cr5x9Tlu.js","assets/CreditCard01-DCL7xzU2.js","assets/DotsVertical-DZE2ktIm.js","assets/Image01-Doh_epPd.js","assets/Globe04-DLL93yaf.js","assets/SwitchHorizontal01-Dv53_XOE.js","assets/Key01-rqwReuZQ.js","assets/Link01-DiFWbMaR.js","assets/Monitor01-Cp7iEwN0.js","assets/Sun-CJr96mBh.js","assets/Play-C2hvYOyw.js","assets/Plus-v0YpByfM.js","assets/Trash01-3M9m1iIs.js","assets/Upload01-DBgIGKf8.js","assets/Users01-gQNjKybb.js","assets/XClose-Bpws6cjk.js","assets/use-project-scope-Ds7ag806.js","assets/repository-binding-CGM8Ow1W.js","assets/use-mcp-client-CqsBL7uD.js","assets/use-panel-navigate-BcP-4Jk4.js","assets/thread-route-DbJLUn3d.js","assets/use-clock-tick-DWBHoA2Q.js","assets/command-Crl7raeC.js","assets/index-BVCIU8Mk.js","assets/integration-icon-D-qpZQt8.js","assets/project-icon-DXev8VIW.js","assets/new-project-dialog-BZdoOBOz.js","assets/repository-import-picker-DpjUG5YI.js","assets/use-navigate-to-agent-RUWGGNCj.js","assets/thread-intent-k2Km9Dmr.js","assets/watch-sse-pool-SMEeDp6D.js","assets/task-board-DPQxW0jP.js","assets/slugify-CEUa2lfQ.js","assets/repository-picker-XHsJQrRg.js","assets/tooltip-C2m8ePE-.js","assets/useInfiniteQuery-Cyz1DFAa.js","assets/infiniteQueryObserver-Bni-1Rrc.js","assets/collection-search-DdqYzjim.js","assets/use-organization-settings-CvwbmZME.js","assets/autosend-B7QA12Tw.js","assets/use-org-sso-FN6Hp6_O.js","assets/shell-layout-CE2Eihra.css","assets/onboarding-BGszMdtv.js","assets/organization-choice-xhN7Yznf.js","assets/reports-onboarding-Ci2eFzgb.js","assets/site-url-en5df9c-.js","assets/create-organization-dialog-Ddjs5dmA.js","assets/alert-dialog-Dr31Gqkz.js","assets/form-BUOiUceD.js","assets/companion-mcps-section-DkjOETuc.js","assets/use-connect-companion-m9MlzSIA.js","assets/companions-core-DzyeM-yJ.js","assets/metadata-D72DunRR.js","assets/github-repo-scope-ByTYKy_L.js","assets/provision-repo-scoped-github-connection-lckxpDHD.js","assets/useQueries-Dpxh6EqM.js","assets/authenticate-and-persist-oauth-DEaKhdcs.js","assets/mcp-oauth-DLnUq2f9.js","assets/track-C5Z44Ul6.js","assets/extract-connection-data-DQ0ThsQw.js","assets/connection-BVvM5npe.js","assets/url-slug-DEN8nCcZ.js","assets/self-tool-result-8OxPN9Nm.js","assets/site-error-Da6iapvu.js","assets/choose-editor-BKZj3uPE.js","assets/reports-BiB14-w5.js","assets/reports-Dl0n8WK0.css","assets/route-lCR_XMKF.js","assets/thread-button-BdG_noMn.js","assets/use-chat-layout-state-WRaaYm0y.js","assets/use-file-configs-CfW92ECv.js","assets/use-mobile-D2A_YY4A.js","assets/sheet-wemU-aZ9.js","assets/toolbar-icon-button-BxO5B0Sy.js","assets/core.esm-CIWIcR9H.js","assets/sortable.esm-jUEYWtPl.js","assets/context-menu-JVsCdcDt.js","assets/daily-pulse-Dpe4FA_b.js","assets/config-YLu1LJhW.js","assets/task-route-BQDNl_5C.js","assets/popover-CZB8RxoJ.js","assets/drawer-3zPC7EI9.js","assets/use-join-requests-ChCzkc7_.js","assets/use-org-auth-client-qz-rdd-6.js","assets/use-organization-roles-lOM-6Cks.js","assets/use-deco-credits-sdJPRntH.js","assets/use-ai-providers-jw2MMLa5.js","assets/use-decopilot-events-CvdvLxq8.js","assets/plan-ladder-BNRju_Rr.js","assets/scroll-area-NCHj5pvE.js","assets/use-task-board-items-CkoW6-bn.js","assets/use-task-board-events-CZieAk2g.js","assets/use-thread-analytics-B8zFfdhr.js","assets/project-profile-Cc4MG3QN.js","assets/optimistic-project-sidebar-views-C2x-Aaxu.js","assets/resolve-tab-icon-C3-zJZHp.js","assets/tab-icon-glyph-DF33b7XO.js","assets/checkbox-DSNt2gzr.js","assets/icon-button-DMzM4KWP.js","assets/question-004-sINsf4GQ.js","assets/thread-route-Cx-o2xCf.js","assets/chat-context-Cwuqjrlx.js","assets/use-chat-navigation-FGqN2bea.js","assets/location-BjlyegC2.js","assets/use-reports-diagnostic-CO2atgBG.js","assets/connect-layout-CQuvObDD.js","assets/route-Dbrk4VYq.js","assets/use-sandbox-events-Cqb_Ym4F.js","assets/tool-namespace-CPm912_s.js","assets/use-mcp-prompts-1ZUYIWAu.js","assets/usage-stats-Dn2OeFoS.js","assets/utils-CVEq3hMx.js","assets/markdown-C_bpsjlQ.js","assets/use-copy-Cu3Byc8S.js","assets/input-ynU6Ij5H.js","assets/file-type-icon-7-3yF331.js","assets/chat-draft-D0btcSjz.js","assets/tabs-Duy7ODee.js","assets/toggle-group-m6bc6yjp.js","assets/use-open-billing-url-tDUbFoyb.js","assets/index-eP3gZugt.js","assets/ai-providers-logos-DD3qZ33J.js","assets/input-C7fKNsaf.js","assets/suggestion-DIwPOBWx.js","assets/use-org-fs-Bpw1hkjS.js","assets/use-members-BTcdjICA.js","assets/feature-paywall-Cdd2Shxl.js","assets/add-connection-dialog-CQiSl-Qe.js","assets/connection-card-sWgF9uUo.js","assets/connection-slug-CITJ0kGN.js","assets/use-connection-B2P9vQF_.js","assets/connection-form-helpers-Je0bq7c_.js","assets/collection-tabs-CWwn3uMq.js","assets/use-infinite-scroll-lPN0NCUm.js","assets/useSuspenseInfiniteQuery-B0qRbG8m.js","assets/input-Bwd_JSM8.css","assets/pair-Dha2uqa_.js","assets/collapsible-DOY0YL_H.js","assets/content-blocks-o63cs2vh.js","assets/mcp-app-renderer-DSXHJ5Wt.js","assets/types-ZqGSA7tu.js","assets/omit-sandbox-map-jj4lCB2U.js","assets/use-thread-outputs-CHIrdXyI.js","assets/sandbox-url-D3mC8qhT.js","assets/use-releases-DedSt3np.js","assets/serial-task-queue-CGOeQgpr.js","assets/sandbox-lifecycle-context-BrrAiqEe.js","assets/sandbox-start-errors-BK_aDCyt.js","assets/index-D_C9gk4l.js","assets/resizable-DBUNvXp7.js","assets/task-status-BGLLtgDf.js","assets/use-main-panel-tabs-Dsv5nepq.js","assets/use-mcp-tools-D_yHtzDx.js","assets/use-task-metadata-C-eJemLF.js","assets/virtual-mcp-CKveTc8W.js","assets/legacy-main-redirect-R36lgGCg.js","assets/preview-dialog-DZmQ4_OU.js","assets/preview-content-DCZG-NtD.js","assets/file-share-button-D4Hp3Pwr.js","assets/file-preview-wTY5J2MC.js","assets/utils-BBHV2kqf.js","assets/editor-BMb1eAhF.js","assets/blocks-preview-workspace-context-C7bCK2dG.js","assets/home-BZZrU9O7.js","assets/chart-CvxQFl1V.js","assets/index-D5kx2mq6.js","assets/symbol-lUKWgdXD.js","assets/CategoricalChart-ClYHeQF6.js","assets/AreaChart-CeW2QCC3.js","assets/use-automations-D20-ruPj.js","assets/project-feed-Ctubs6D8.js","assets/mini-report-page-BVO6pALW.js","assets/client-icons-BpKVWun3.js","assets/projects-empty-state-Bkvn9wBz.js","assets/flat-project-CNnQaq5E.js","assets/view-mode-toggle-5lUXeBq8.js","assets/index-DIbARVXx.js","assets/use-task-board-analytics-Dx24ixKr.js","assets/combobox-D7N8SC25.js","assets/column-rules-_Ma8ZWf4.js","assets/search-toggle-BepIBc_s.js","assets/use-tags-ja0CaL2g.js","assets/calendar-CRpUCA4p.js","assets/alert-B2FW115A.js","assets/index-x-BjYR-J.js","assets/rich-text-link-control-B-mX9xD1.js","assets/index-CerQwuGf.js","assets/use-task-board-item-prs-C_5W7zcg.js","assets/thread-sheet-body-_3hMbQ_o.js","assets/separator-BTLDrzUc.js","assets/board-analytics-B5mmzmBe.js","assets/time-range-picker-CH7-gioV.js","assets/analytics-sections-DOFncpfM.js","assets/BarChart-DdrNiWaE.js","assets/tooltipContext-CxUJkkTI.js","assets/ActiveShapeUtils-DCHlcSOh.js","assets/Sector-Clpc9eH-.js","assets/ErrorBarContext-D4j8kFWO.js","assets/XAxis-DBRxAeUY.js","assets/library-tab-DiWbCdAf.js","assets/use-org-repo-syncs-Dgz3AX_E.js","assets/folder-icon-H82laJL_.js","assets/empty-state-DuauqtRJ.js","assets/use-ensure-project-folder-BS99-Vhk.js","assets/agent-overview-UU6Y44eX.js","assets/project-tasks-CzZdSRDI.js","assets/feature-gate-DGH8G4ta.js","assets/mock-board-B5k1LNJu.js","assets/project-reports-Ci_iYRrd.js","assets/reports-tab-CfLfXENf.js","assets/agent-site-editor-LLur_-_o.js","assets/claim-phase-copy-DWZtPw6h.js","assets/device-hint-D9SLM9ag.js","assets/use-fast-preview-draft-url-C5x2lifG.js","assets/section-preview-url-7zfngvgW.js","assets/sandbox-git-api-C7JbVL7R.js","assets/save-changes-debug-nBi-n9eV.js","assets/agent-site-editor-DDGTF8rc.css","assets/agent-site-editor-preview-5ii-TR0s.js","assets/agent-view-guard-CyNRuQw7.js","assets/runnable-block-editor-aENhZJE9.js","assets/monaco-editor-DMfRj7kt.js","assets/use-new-blocks-editor-APcQuu-Z.js","assets/asset-utils-CX1te1rQ.js","assets/variant-matcher-override-3KgTJsm9.js","assets/agent-site-editor-content-DXvV_eiy.js","assets/mustache-CEXj2Yiz.js","assets/agent-site-editor-code-DA20Pk7L.js","assets/agent-automations-BV2eTHQr.js","assets/automation-list-row-CG7kU51M.js","assets/agent-automation-DuF9ZiWS.js","assets/select-model-Cn7hOiT6.js","assets/build-improve-prompt-doc-on-tpDMo.js","assets/use-debounced-autosave-DrUzoxBu.js","assets/jira-icon-B4wDBFAC.js","assets/multi-select-BwXBmTlI.js","assets/automation-runs-CGQu-nIx.js","assets/agent-settings-_tzBjLDX.js","assets/settings-tab-BqJQ3uPx.js","assets/use-date-fns-locale-Beq3354R.js","assets/use-mcp-auth-status-DRKL-P8f.js","assets/secret-picker-C6OYpb8W.js","assets/use-secrets-BjvGVY7t.js","assets/agent-library-CGtmUhYD.js","assets/agent-assets-Ba_4hhfI.js","assets/agent-hosting-2pI_IIlr.js","assets/agent-e2e-CgGLFkHe.js","assets/agent-analytics-Dlpy_544.js","assets/taskboard-analytics-2fBMPAxC.js","assets/agent-experiments-CpXLJckI.js","assets/slider-INBQ4Ci_.js","assets/index-gHDeYn5U.js","assets/agent-monitor-BRq8qrkU.js","assets/agent-app-DtmEOrmX.js","assets/project-app-view-Cnchb-Ig.js","assets/agent-view-CgtvUhvS.js","assets/agent-file-Cak5KHUl.js","assets/agent-deck--kR-tnhH.js","assets/agent-library-file-CZlCJsi6.js","assets/preview-panel-BOJOfHU6.js","assets/agent-connect-sources-C_fgxaTV.js","assets/legacy-agents-deep-BSzJqFgZ.js","assets/tasks-CqyFd60l.js","assets/thread-analytics-CtoXhN32.js","assets/reports-CJkqLIIg.js","assets/library-BfEEZWGX.js","assets/discover-DlwaiXCQ.js","assets/index-PaA2bHVT.js","assets/route-DmXxzobK.js","assets/index-redirect-6gCqz6Y5.js","assets/capability-load-error-Cwp75ry8.js","assets/connections-Dc6s7_rq.js","assets/collection-display-button-Dtu1j77F.js","assets/use-delete-connection-BOHbZqa4.js","assets/connection-detail-AG67uG4I.js","assets/index-BmBVOCXW.js","assets/use-create-virtual-mcp-C8rAImjt.js","assets/monitoring-stats-row-Bkq-86wh.js","assets/collection-detail--7z4uSdQ.js","assets/index-D_aXURjc.js","assets/require-capability-D5tJwX6A.js","assets/access-gate-DlhD9I9N.js","assets/general-BHuT0FSK.js","assets/review-settings-iKeIZIxh.js","assets/domain-settings-CwEiepSy.js","assets/connect-BbV6U_hr.js","assets/api-keys-DPKcfTUa.js","assets/ai-providers-jNZBkRl5.js","assets/infra-billing-hHO33Bt1.js","assets/secrets-CZl02iRQ.js","assets/api-keys-DXlZlPNT.js","assets/buckets-Qu8B15tT.js","assets/repositories-Ddu7D_dm.js","assets/synced-repos-gT4FkxhN.js","assets/tasks-IL-LS75-.js","assets/projects-DfF5wpqY.js","assets/members-Bunz7e6B.js","assets/role-color-Dn2tXDDF.js","assets/roles-B4ZkD532.js","assets/sso-D804RM9B.js","assets/profile-CtDXcfuO.js","assets/agents-list-BVqV3SYd.js","assets/automations-D9LXua4J.js","assets/skills-BqpJ6duC.js","assets/memory-BLa9O78J.js"])))=>i.map(i=>d[i]);
2
2
  function jz(e,t){for(var o=0;o<t.length;o++){const a=t[o];if(typeof a!="string"&&!Array.isArray(a)){for(const n in a)if(n!=="default"&&!(n in e)){const i=Object.getOwnPropertyDescriptor(a,n);i&&Object.defineProperty(e,n,i.get?i:{enumerable:!0,get:()=>a[n]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const n of document.querySelectorAll('link[rel="modulepreload"]'))a(n);new MutationObserver(n=>{for(const i of n)if(i.type==="childList")for(const l of i.addedNodes)l.tagName==="LINK"&&l.rel==="modulepreload"&&a(l)}).observe(document,{childList:!0,subtree:!0});function o(n){const i={};return n.integrity&&(i.integrity=n.integrity),n.referrerPolicy&&(i.referrerPolicy=n.referrerPolicy),n.crossOrigin==="use-credentials"?i.credentials="include":n.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function a(n){if(n.ep)return;n.ep=!0;const i=o(n);fetch(n.href,i)}})();var dfe=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Ml(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var vS={exports:{}},_u={};var S1;function zz(){if(S1)return _u;S1=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function o(a,n,i){var l=null;if(i!==void 0&&(l=""+i),n.key!==void 0&&(l=""+n.key),"key"in n){i={};for(var c in n)c!=="key"&&(i[c]=n[c])}else i=n;return n=i.ref,{$$typeof:e,type:a,key:l,ref:n!==void 0?n:null,props:i}}return _u.Fragment=t,_u.jsx=o,_u.jsxs=o,_u}var w1;function Uz(){return w1||(w1=1,vS.exports=zz()),vS.exports}var w=Uz(),bS={exports:{}},ct={};var T1;function $z(){if(T1)return ct;T1=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),a=Symbol.for("react.strict_mode"),n=Symbol.for("react.profiler"),i=Symbol.for("react.consumer"),l=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),p=Symbol.for("react.memo"),m=Symbol.for("react.lazy"),h=Symbol.for("react.activity"),f=Symbol.iterator;function v(N){return N===null||typeof N!="object"?null:(N=f&&N[f]||N["@@iterator"],typeof N=="function"?N:null)}var b={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},S=Object.assign,_={};function T(N,G,V){this.props=N,this.context=G,this.refs=_,this.updater=V||b}T.prototype.isReactComponent={},T.prototype.setState=function(N,G){if(typeof N!="object"&&typeof N!="function"&&N!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,N,G,"setState")},T.prototype.forceUpdate=function(N){this.updater.enqueueForceUpdate(this,N,"forceUpdate")};function x(){}x.prototype=T.prototype;function P(N,G,V){this.props=N,this.context=G,this.refs=_,this.updater=V||b}var C=P.prototype=new x;C.constructor=P,S(C,T.prototype),C.isPureReactComponent=!0;var E=Array.isArray;function R(){}var D={H:null,A:null,T:null,S:null},O=Object.prototype.hasOwnProperty;function L(N,G,V){var I=V.ref;return{$$typeof:e,type:N,key:G,ref:I!==void 0?I:null,props:V}}function $(N,G){return L(N.type,G,N.props)}function B(N){return typeof N=="object"&&N!==null&&N.$$typeof===e}function U(N){var G={"=":"=0",":":"=2"};return"$"+N.replace(/[=:]/g,function(V){return G[V]})}var j=/\/+/g;function W(N,G){return typeof N=="object"&&N!==null&&N.key!=null?U(""+N.key):G.toString(36)}function ne(N){switch(N.status){case"fulfilled":return N.value;case"rejected":throw N.reason;default:switch(typeof N.status=="string"?N.then(R,R):(N.status="pending",N.then(function(G){N.status==="pending"&&(N.status="fulfilled",N.value=G)},function(G){N.status==="pending"&&(N.status="rejected",N.reason=G)})),N.status){case"fulfilled":return N.value;case"rejected":throw N.reason}}throw N}function H(N,G,V,I,z){var J=typeof N;(J==="undefined"||J==="boolean")&&(N=null);var pe=!1;if(N===null)pe=!0;else switch(J){case"bigint":case"string":case"number":pe=!0;break;case"object":switch(N.$$typeof){case e:case t:pe=!0;break;case m:return pe=N._init,H(pe(N._payload),G,V,I,z)}}if(pe)return z=z(N),pe=I===""?"."+W(N,0):I,E(z)?(V="",pe!=null&&(V=pe.replace(j,"$&/")+"/"),H(z,G,V,"",function($e){return $e})):z!=null&&(B(z)&&(z=$(z,V+(z.key==null||N&&N.key===z.key?"":(""+z.key).replace(j,"$&/")+"/")+pe)),G.push(z)),1;pe=0;var he=I===""?".":I+":";if(E(N))for(var _e=0;_e<N.length;_e++)I=N[_e],J=he+W(I,_e),pe+=H(I,G,V,J,z);else if(_e=v(N),typeof _e=="function")for(N=_e.call(N),_e=0;!(I=N.next()).done;)I=I.value,J=he+W(I,_e++),pe+=H(I,G,V,J,z);else if(J==="object"){if(typeof N.then=="function")return H(ne(N),G,V,I,z);throw G=String(N),Error("Objects are not valid as a React child (found: "+(G==="[object Object]"?"object with keys {"+Object.keys(N).join(", ")+"}":G)+"). If you meant to render a collection of children, use an array instead.")}return pe}function Z(N,G,V){if(N==null)return N;var I=[],z=0;return H(N,I,"","",function(J){return G.call(V,J,z++)}),I}function te(N){if(N._status===-1){var G=N._result;G=G(),G.then(function(V){(N._status===0||N._status===-1)&&(N._status=1,N._result=V)},function(V){(N._status===0||N._status===-1)&&(N._status=2,N._result=V)}),N._status===-1&&(N._status=0,N._result=G)}if(N._status===1)return N._result.default;throw N._result}var le=typeof reportError=="function"?reportError:function(N){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var G=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof N=="object"&&N!==null&&typeof N.message=="string"?String(N.message):String(N),error:N});if(!window.dispatchEvent(G))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",N);return}console.error(N)},Q={map:Z,forEach:function(N,G,V){Z(N,function(){G.apply(this,arguments)},V)},count:function(N){var G=0;return Z(N,function(){G++}),G},toArray:function(N){return Z(N,function(G){return G})||[]},only:function(N){if(!B(N))throw Error("React.Children.only expected to receive a single React element child.");return N}};return ct.Activity=h,ct.Children=Q,ct.Component=T,ct.Fragment=o,ct.Profiler=n,ct.PureComponent=P,ct.StrictMode=a,ct.Suspense=u,ct.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=D,ct.__COMPILER_RUNTIME={__proto__:null,c:function(N){return D.H.useMemoCache(N)}},ct.cache=function(N){return function(){return N.apply(null,arguments)}},ct.cacheSignal=function(){return null},ct.cloneElement=function(N,G,V){if(N==null)throw Error("The argument must be a React element, but you passed "+N+".");var I=S({},N.props),z=N.key;if(G!=null)for(J in G.key!==void 0&&(z=""+G.key),G)!O.call(G,J)||J==="key"||J==="__self"||J==="__source"||J==="ref"&&G.ref===void 0||(I[J]=G[J]);var J=arguments.length-2;if(J===1)I.children=V;else if(1<J){for(var pe=Array(J),he=0;he<J;he++)pe[he]=arguments[he+2];I.children=pe}return L(N.type,z,I)},ct.createContext=function(N){return N={$$typeof:l,_currentValue:N,_currentValue2:N,_threadCount:0,Provider:null,Consumer:null},N.Provider=N,N.Consumer={$$typeof:i,_context:N},N},ct.createElement=function(N,G,V){var I,z={},J=null;if(G!=null)for(I in G.key!==void 0&&(J=""+G.key),G)O.call(G,I)&&I!=="key"&&I!=="__self"&&I!=="__source"&&(z[I]=G[I]);var pe=arguments.length-2;if(pe===1)z.children=V;else if(1<pe){for(var he=Array(pe),_e=0;_e<pe;_e++)he[_e]=arguments[_e+2];z.children=he}if(N&&N.defaultProps)for(I in pe=N.defaultProps,pe)z[I]===void 0&&(z[I]=pe[I]);return L(N,J,z)},ct.createRef=function(){return{current:null}},ct.forwardRef=function(N){return{$$typeof:c,render:N}},ct.isValidElement=B,ct.lazy=function(N){return{$$typeof:m,_payload:{_status:-1,_result:N},_init:te}},ct.memo=function(N,G){return{$$typeof:p,type:N,compare:G===void 0?null:G}},ct.startTransition=function(N){var G=D.T,V={};D.T=V;try{var I=N(),z=D.S;z!==null&&z(V,I),typeof I=="object"&&I!==null&&typeof I.then=="function"&&I.then(R,le)}catch(J){le(J)}finally{G!==null&&V.types!==null&&(G.types=V.types),D.T=G}},ct.unstable_useCacheRefresh=function(){return D.H.useCacheRefresh()},ct.use=function(N){return D.H.use(N)},ct.useActionState=function(N,G,V){return D.H.useActionState(N,G,V)},ct.useCallback=function(N,G){return D.H.useCallback(N,G)},ct.useContext=function(N){return D.H.useContext(N)},ct.useDebugValue=function(){},ct.useDeferredValue=function(N,G){return D.H.useDeferredValue(N,G)},ct.useEffect=function(N,G){return D.H.useEffect(N,G)},ct.useEffectEvent=function(N){return D.H.useEffectEvent(N)},ct.useId=function(){return D.H.useId()},ct.useImperativeHandle=function(N,G,V){return D.H.useImperativeHandle(N,G,V)},ct.useInsertionEffect=function(N,G){return D.H.useInsertionEffect(N,G)},ct.useLayoutEffect=function(N,G){return D.H.useLayoutEffect(N,G)},ct.useMemo=function(N,G){return D.H.useMemo(N,G)},ct.useOptimistic=function(N,G){return D.H.useOptimistic(N,G)},ct.useReducer=function(N,G,V){return D.H.useReducer(N,G,V)},ct.useRef=function(N){return D.H.useRef(N)},ct.useState=function(N){return D.H.useState(N)},ct.useSyncExternalStore=function(N,G,V){return D.H.useSyncExternalStore(N,G,V)},ct.useTransition=function(){return D.H.useTransition()},ct.version="19.2.6",ct}var x1;function Ls(){return x1||(x1=1,bS.exports=$z()),bS.exports}var A=Ls();const X=Ml(A),Sx=jz({__proto__:null,default:X},[A]);var yS={exports:{}},ku={},SS={exports:{}},wS={};var _1;function qz(){return _1||(_1=1,(function(e){function t(H,Z){var te=H.length;H.push(Z);e:for(;0<te;){var le=te-1>>>1,Q=H[le];if(0<n(Q,Z))H[le]=Z,H[te]=Q,te=le;else break e}}function o(H){return H.length===0?null:H[0]}function a(H){if(H.length===0)return null;var Z=H[0],te=H.pop();if(te!==Z){H[0]=te;e:for(var le=0,Q=H.length,N=Q>>>1;le<N;){var G=2*(le+1)-1,V=H[G],I=G+1,z=H[I];if(0>n(V,te))I<Q&&0>n(z,V)?(H[le]=z,H[I]=te,le=I):(H[le]=V,H[G]=te,le=G);else if(I<Q&&0>n(z,te))H[le]=z,H[I]=te,le=I;else break e}}return Z}function n(H,Z){var te=H.sortIndex-Z.sortIndex;return te!==0?te:H.id-Z.id}if(e.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var l=Date,c=l.now();e.unstable_now=function(){return l.now()-c}}var u=[],p=[],m=1,h=null,f=3,v=!1,b=!1,S=!1,_=!1,T=typeof setTimeout=="function"?setTimeout:null,x=typeof clearTimeout=="function"?clearTimeout:null,P=typeof setImmediate<"u"?setImmediate:null;function C(H){for(var Z=o(p);Z!==null;){if(Z.callback===null)a(p);else if(Z.startTime<=H)a(p),Z.sortIndex=Z.expirationTime,t(u,Z);else break;Z=o(p)}}function E(H){if(S=!1,C(H),!b)if(o(u)!==null)b=!0,R||(R=!0,U());else{var Z=o(p);Z!==null&&ne(E,Z.startTime-H)}}var R=!1,D=-1,O=5,L=-1;function $(){return _?!0:!(e.unstable_now()-L<O)}function B(){if(_=!1,R){var H=e.unstable_now();L=H;var Z=!0;try{e:{b=!1,S&&(S=!1,x(D),D=-1),v=!0;var te=f;try{t:{for(C(H),h=o(u);h!==null&&!(h.expirationTime>H&&$());){var le=h.callback;if(typeof le=="function"){h.callback=null,f=h.priorityLevel;var Q=le(h.expirationTime<=H);if(H=e.unstable_now(),typeof Q=="function"){h.callback=Q,C(H),Z=!0;break t}h===o(u)&&a(u),C(H)}else a(u);h=o(u)}if(h!==null)Z=!0;else{var N=o(p);N!==null&&ne(E,N.startTime-H),Z=!1}}break e}finally{h=null,f=te,v=!1}Z=void 0}}finally{Z?U():R=!1}}}var U;if(typeof P=="function")U=function(){P(B)};else if(typeof MessageChannel<"u"){var j=new MessageChannel,W=j.port2;j.port1.onmessage=B,U=function(){W.postMessage(null)}}else U=function(){T(B,0)};function ne(H,Z){D=T(function(){H(e.unstable_now())},Z)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(H){H.callback=null},e.unstable_forceFrameRate=function(H){0>H||125<H?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):O=0<H?Math.floor(1e3/H):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(H){switch(f){case 1:case 2:case 3:var Z=3;break;default:Z=f}var te=f;f=Z;try{return H()}finally{f=te}},e.unstable_requestPaint=function(){_=!0},e.unstable_runWithPriority=function(H,Z){switch(H){case 1:case 2:case 3:case 4:case 5:break;default:H=3}var te=f;f=H;try{return Z()}finally{f=te}},e.unstable_scheduleCallback=function(H,Z,te){var le=e.unstable_now();switch(typeof te=="object"&&te!==null?(te=te.delay,te=typeof te=="number"&&0<te?le+te:le):te=le,H){case 1:var Q=-1;break;case 2:Q=250;break;case 5:Q=1073741823;break;case 4:Q=1e4;break;default:Q=5e3}return Q=te+Q,H={id:m++,callback:Z,priorityLevel:H,startTime:te,expirationTime:Q,sortIndex:-1},te>le?(H.sortIndex=te,t(p,H),o(u)===null&&H===o(p)&&(S?(x(D),D=-1):S=!0,ne(E,te-le))):(H.sortIndex=Q,t(u,H),b||v||(b=!0,R||(R=!0,U()))),H},e.unstable_shouldYield=$,e.unstable_wrapCallback=function(H){var Z=f;return function(){var te=f;f=Z;try{return H.apply(this,arguments)}finally{f=te}}}})(wS)),wS}var k1;function Vz(){return k1||(k1=1,SS.exports=qz()),SS.exports}var TS={exports:{}},Ra={};var C1;function Hz(){if(C1)return Ra;C1=1;var e=Ls();function t(u){var p="https://react.dev/errors/"+u;if(1<arguments.length){p+="?args[]="+encodeURIComponent(arguments[1]);for(var m=2;m<arguments.length;m++)p+="&args[]="+encodeURIComponent(arguments[m])}return"Minified React error #"+u+"; visit "+p+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function o(){}var a={d:{f:o,r:function(){throw Error(t(522))},D:o,C:o,L:o,m:o,X:o,S:o,M:o},p:0,findDOMNode:null},n=Symbol.for("react.portal");function i(u,p,m){var h=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:n,key:h==null?null:""+h,children:u,containerInfo:p,implementation:m}}var l=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function c(u,p){if(u==="font")return"";if(typeof p=="string")return p==="use-credentials"?p:""}return Ra.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=a,Ra.createPortal=function(u,p){var m=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!p||p.nodeType!==1&&p.nodeType!==9&&p.nodeType!==11)throw Error(t(299));return i(u,p,null,m)},Ra.flushSync=function(u){var p=l.T,m=a.p;try{if(l.T=null,a.p=2,u)return u()}finally{l.T=p,a.p=m,a.d.f()}},Ra.preconnect=function(u,p){typeof u=="string"&&(p?(p=p.crossOrigin,p=typeof p=="string"?p==="use-credentials"?p:"":void 0):p=null,a.d.C(u,p))},Ra.prefetchDNS=function(u){typeof u=="string"&&a.d.D(u)},Ra.preinit=function(u,p){if(typeof u=="string"&&p&&typeof p.as=="string"){var m=p.as,h=c(m,p.crossOrigin),f=typeof p.integrity=="string"?p.integrity:void 0,v=typeof p.fetchPriority=="string"?p.fetchPriority:void 0;m==="style"?a.d.S(u,typeof p.precedence=="string"?p.precedence:void 0,{crossOrigin:h,integrity:f,fetchPriority:v}):m==="script"&&a.d.X(u,{crossOrigin:h,integrity:f,fetchPriority:v,nonce:typeof p.nonce=="string"?p.nonce:void 0})}},Ra.preinitModule=function(u,p){if(typeof u=="string")if(typeof p=="object"&&p!==null){if(p.as==null||p.as==="script"){var m=c(p.as,p.crossOrigin);a.d.M(u,{crossOrigin:m,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0})}}else p==null&&a.d.M(u)},Ra.preload=function(u,p){if(typeof u=="string"&&typeof p=="object"&&p!==null&&typeof p.as=="string"){var m=p.as,h=c(m,p.crossOrigin);a.d.L(u,m,{crossOrigin:h,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0,type:typeof p.type=="string"?p.type:void 0,fetchPriority:typeof p.fetchPriority=="string"?p.fetchPriority:void 0,referrerPolicy:typeof p.referrerPolicy=="string"?p.referrerPolicy:void 0,imageSrcSet:typeof p.imageSrcSet=="string"?p.imageSrcSet:void 0,imageSizes:typeof p.imageSizes=="string"?p.imageSizes:void 0,media:typeof p.media=="string"?p.media:void 0})}},Ra.preloadModule=function(u,p){if(typeof u=="string")if(p){var m=c(p.as,p.crossOrigin);a.d.m(u,{as:typeof p.as=="string"&&p.as!=="script"?p.as:void 0,crossOrigin:m,integrity:typeof p.integrity=="string"?p.integrity:void 0})}else a.d.m(u)},Ra.requestFormReset=function(u){a.d.r(u)},Ra.unstable_batchedUpdates=function(u,p){return u(p)},Ra.useFormState=function(u,p,m){return l.H.useFormState(u,p,m)},Ra.useFormStatus=function(){return l.H.useHostTransitionStatus()},Ra.version="19.2.6",Ra}var E1;function oM(){if(E1)return TS.exports;E1=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),TS.exports=Hz(),TS.exports}var P1;function Gz(){if(P1)return ku;P1=1;var e=Vz(),t=Ls(),o=oM();function a(r){var s="https://react.dev/errors/"+r;if(1<arguments.length){s+="?args[]="+encodeURIComponent(arguments[1]);for(var d=2;d<arguments.length;d++)s+="&args[]="+encodeURIComponent(arguments[d])}return"Minified React error #"+r+"; visit "+s+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function n(r){return!(!r||r.nodeType!==1&&r.nodeType!==9&&r.nodeType!==11)}function i(r){var s=r,d=r;if(r.alternate)for(;s.return;)s=s.return;else{r=s;do s=r,(s.flags&4098)!==0&&(d=s.return),r=s.return;while(r)}return s.tag===3?d:null}function l(r){if(r.tag===13){var s=r.memoizedState;if(s===null&&(r=r.alternate,r!==null&&(s=r.memoizedState)),s!==null)return s.dehydrated}return null}function c(r){if(r.tag===31){var s=r.memoizedState;if(s===null&&(r=r.alternate,r!==null&&(s=r.memoizedState)),s!==null)return s.dehydrated}return null}function u(r){if(i(r)!==r)throw Error(a(188))}function p(r){var s=r.alternate;if(!s){if(s=i(r),s===null)throw Error(a(188));return s!==r?null:r}for(var d=r,g=s;;){var y=d.return;if(y===null)break;var k=y.alternate;if(k===null){if(g=y.return,g!==null){d=g;continue}break}if(y.child===k.child){for(k=y.child;k;){if(k===d)return u(y),r;if(k===g)return u(y),s;k=k.sibling}throw Error(a(188))}if(d.return!==g.return)d=y,g=k;else{for(var M=!1,F=y.child;F;){if(F===d){M=!0,d=y,g=k;break}if(F===g){M=!0,g=y,d=k;break}F=F.sibling}if(!M){for(F=k.child;F;){if(F===d){M=!0,d=k,g=y;break}if(F===g){M=!0,g=k,d=y;break}F=F.sibling}if(!M)throw Error(a(189))}}if(d.alternate!==g)throw Error(a(190))}if(d.tag!==3)throw Error(a(188));return d.stateNode.current===d?r:s}function m(r){var s=r.tag;if(s===5||s===26||s===27||s===6)return r;for(r=r.child;r!==null;){if(s=m(r),s!==null)return s;r=r.sibling}return null}var h=Object.assign,f=Symbol.for("react.element"),v=Symbol.for("react.transitional.element"),b=Symbol.for("react.portal"),S=Symbol.for("react.fragment"),_=Symbol.for("react.strict_mode"),T=Symbol.for("react.profiler"),x=Symbol.for("react.consumer"),P=Symbol.for("react.context"),C=Symbol.for("react.forward_ref"),E=Symbol.for("react.suspense"),R=Symbol.for("react.suspense_list"),D=Symbol.for("react.memo"),O=Symbol.for("react.lazy"),L=Symbol.for("react.activity"),$=Symbol.for("react.memo_cache_sentinel"),B=Symbol.iterator;function U(r){return r===null||typeof r!="object"?null:(r=B&&r[B]||r["@@iterator"],typeof r=="function"?r:null)}var j=Symbol.for("react.client.reference");function W(r){if(r==null)return null;if(typeof r=="function")return r.$$typeof===j?null:r.displayName||r.name||null;if(typeof r=="string")return r;switch(r){case S:return"Fragment";case T:return"Profiler";case _:return"StrictMode";case E:return"Suspense";case R:return"SuspenseList";case L:return"Activity"}if(typeof r=="object")switch(r.$$typeof){case b:return"Portal";case P:return r.displayName||"Context";case x:return(r._context.displayName||"Context")+".Consumer";case C:var s=r.render;return r=r.displayName,r||(r=s.displayName||s.name||"",r=r!==""?"ForwardRef("+r+")":"ForwardRef"),r;case D:return s=r.displayName||null,s!==null?s:W(r.type)||"Memo";case O:s=r._payload,r=r._init;try{return W(r(s))}catch{}}return null}var ne=Array.isArray,H=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Z=o.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,te={pending:!1,data:null,method:null,action:null},le=[],Q=-1;function N(r){return{current:r}}function G(r){0>Q||(r.current=le[Q],le[Q]=null,Q--)}function V(r,s){Q++,le[Q]=r.current,r.current=s}var I=N(null),z=N(null),J=N(null),pe=N(null);function he(r,s){switch(V(J,s),V(z,r),V(I,null),s.nodeType){case 9:case 11:r=(r=s.documentElement)&&(r=r.namespaceURI)?qP(r):0;break;default:if(r=s.tagName,s=s.namespaceURI)s=qP(s),r=VP(s,r);else switch(r){case"svg":r=1;break;case"math":r=2;break;default:r=0}}G(I),V(I,r)}function _e(){G(I),G(z),G(J)}function $e(r){r.memoizedState!==null&&V(pe,r);var s=I.current,d=VP(s,r.type);s!==d&&(V(z,r),V(I,d))}function Y(r){z.current===r&&(G(I),G(z)),pe.current===r&&(G(pe),Su._currentValue=te)}var ae,ve;function ie(r){if(ae===void 0)try{throw Error()}catch(d){var s=d.stack.trim().match(/\n( *(at )?)/);ae=s&&s[1]||"",ve=-1<d.stack.indexOf(`
3
3
  at`)?" (<anonymous>)":-1<d.stack.indexOf("@")?"@unknown:0:0":""}return`
4
4
  `+ae+r+ve}var Te=!1;function Ce(r,s){if(!r||Te)return"";Te=!0;var d=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var g={DetermineComponentFrameRoot:function(){try{if(s){var xe=function(){throw Error()};if(Object.defineProperty(xe.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(xe,[])}catch(fe){var me=fe}Reflect.construct(r,[],xe)}else{try{xe.call()}catch(fe){me=fe}r.call(xe.prototype)}}else{try{throw Error()}catch(fe){me=fe}(xe=r())&&typeof xe.catch=="function"&&xe.catch(function(){})}}catch(fe){if(fe&&me&&typeof fe.stack=="string")return[fe.stack,me.stack]}return[null,null]}};g.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var y=Object.getOwnPropertyDescriptor(g.DetermineComponentFrameRoot,"name");y&&y.configurable&&Object.defineProperty(g.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var k=g.DetermineComponentFrameRoot(),M=k[0],F=k[1];if(M&&F){var ee=M.split(`
@@ -52,7 +52,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
52
52
  || ${O} === "boolean" || ${R} === null`).assign(L,(0,a._)`[${R}]`)}}}function f({gen:x,parentData:P,parentDataProperty:C},E){x.if((0,a._)`${P} !== undefined`,()=>x.assign((0,a._)`${P}[${C}]`,E))}function v(x,P,C,E=i.Correct){const R=E===i.Correct?a.operators.EQ:a.operators.NEQ;let D;switch(x){case"null":return(0,a._)`${P} ${R} null`;case"array":D=(0,a._)`Array.isArray(${P})`;break;case"object":D=(0,a._)`${P} && typeof ${P} == "object" && !Array.isArray(${P})`;break;case"integer":D=O((0,a._)`!(${P} % 1) && !isNaN(${P})`);break;case"number":D=O();break;default:return(0,a._)`typeof ${P} ${R} ${x}`}return E===i.Correct?D:(0,a.not)(D);function O(L=a.nil){return(0,a.and)((0,a._)`typeof ${P} == "number"`,L,C?(0,a._)`isFinite(${P})`:a.nil)}}ya.checkDataType=v;function b(x,P,C,E){if(x.length===1)return v(x[0],P,C,E);let R;const D=(0,n.toHash)(x);if(D.array&&D.object){const O=(0,a._)`typeof ${P} != "object"`;R=D.null?O:(0,a._)`!${P} || ${O}`,delete D.null,delete D.array,delete D.object}else R=a.nil;D.number&&delete D.integer;for(const O in D)R=(0,a.and)(R,v(O,P,C,E));return R}ya.checkDataTypes=b;const S={message:({schema:x})=>`must be ${x}`,params:({schema:x,schemaValue:P})=>typeof x=="string"?(0,a._)`{type: ${x}}`:(0,a._)`{type: ${P}}`};function _(x){const P=T(x);(0,o.reportError)(P,S)}ya.reportTypeError=_;function T(x){const{gen:P,data:C,schema:E}=x,R=(0,n.schemaRefOrVal)(x,E,"type");return{gen:P,keyword:"type",data:C,schema:E.type,schemaCode:R,schemaValue:R,parentSchema:E,params:{},it:x}}return ya}var Ru={},KA;function cK(){if(KA)return Ru;KA=1,Object.defineProperty(Ru,"__esModule",{value:!0}),Ru.assignDefaults=void 0;const e=yt(),t=Lt();function o(n,i){const{properties:l,items:c}=n.schema;if(i==="object"&&l)for(const u in l)a(n,u,l[u].default);else i==="array"&&Array.isArray(c)&&c.forEach((u,p)=>a(n,p,u.default))}Ru.assignDefaults=o;function a(n,i,l){const{gen:c,compositeRule:u,data:p,opts:m}=n;if(l===void 0)return;const h=(0,e._)`${p}${(0,e.getProperty)(i)}`;if(u){(0,t.checkStrictMode)(n,`default is ignored for: ${h}`);return}let f=(0,e._)`${h} === undefined`;m.useDefaults==="empty"&&(f=(0,e._)`${f} || ${h} === null || ${h} === ""`),c.if(f,(0,e._)`${h} = ${(0,e.stringify)(l)}`)}return Ru}var cr={},Kt={},YA;function kr(){if(YA)return Kt;YA=1,Object.defineProperty(Kt,"__esModule",{value:!0}),Kt.validateUnion=Kt.validateArray=Kt.usePattern=Kt.callValidateCode=Kt.schemaProperties=Kt.allSchemaProperties=Kt.noPropertyInData=Kt.propertyInData=Kt.isOwnProperty=Kt.hasPropFunc=Kt.reportMissingProp=Kt.checkMissingProp=Kt.checkReportMissingProp=void 0;const e=yt(),t=Lt(),o=js(),a=Lt();function n(x,P){const{gen:C,data:E,it:R}=x;C.if(m(C,E,P,R.opts.ownProperties),()=>{x.setParams({missingProperty:(0,e._)`${P}`},!0),x.error()})}Kt.checkReportMissingProp=n;function i({gen:x,data:P,it:{opts:C}},E,R){return(0,e.or)(...E.map(D=>(0,e.and)(m(x,P,D,C.ownProperties),(0,e._)`${R} = ${D}`)))}Kt.checkMissingProp=i;function l(x,P){x.setParams({missingProperty:P},!0),x.error()}Kt.reportMissingProp=l;function c(x){return x.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,e._)`Object.prototype.hasOwnProperty`})}Kt.hasPropFunc=c;function u(x,P,C){return(0,e._)`${c(x)}.call(${P}, ${C})`}Kt.isOwnProperty=u;function p(x,P,C,E){const R=(0,e._)`${P}${(0,e.getProperty)(C)} !== undefined`;return E?(0,e._)`${R} && ${u(x,P,C)}`:R}Kt.propertyInData=p;function m(x,P,C,E){const R=(0,e._)`${P}${(0,e.getProperty)(C)} === undefined`;return E?(0,e.or)(R,(0,e.not)(u(x,P,C))):R}Kt.noPropertyInData=m;function h(x){return x?Object.keys(x).filter(P=>P!=="__proto__"):[]}Kt.allSchemaProperties=h;function f(x,P){return h(P).filter(C=>!(0,t.alwaysValidSchema)(x,P[C]))}Kt.schemaProperties=f;function v({schemaCode:x,data:P,it:{gen:C,topSchemaRef:E,schemaPath:R,errorPath:D},it:O},L,$,B){const U=B?(0,e._)`${x}, ${P}, ${E}${R}`:P,j=[[o.default.instancePath,(0,e.strConcat)(o.default.instancePath,D)],[o.default.parentData,O.parentData],[o.default.parentDataProperty,O.parentDataProperty],[o.default.rootData,o.default.rootData]];O.opts.dynamicRef&&j.push([o.default.dynamicAnchors,o.default.dynamicAnchors]);const W=(0,e._)`${U}, ${C.object(...j)}`;return $!==e.nil?(0,e._)`${L}.call(${$}, ${W})`:(0,e._)`${L}(${W})`}Kt.callValidateCode=v;const b=(0,e._)`new RegExp`;function S({gen:x,it:{opts:P}},C){const E=P.unicodeRegExp?"u":"",{regExp:R}=P.code,D=R(C,E);return x.scopeValue("pattern",{key:D.toString(),ref:D,code:(0,e._)`${R.code==="new RegExp"?b:(0,a.useFunc)(x,R)}(${C}, ${E})`})}Kt.usePattern=S;function _(x){const{gen:P,data:C,keyword:E,it:R}=x,D=P.name("valid");if(R.allErrors){const L=P.let("valid",!0);return O(()=>P.assign(L,!1)),L}return P.var(D,!0),O(()=>P.break()),D;function O(L){const $=P.const("len",(0,e._)`${C}.length`);P.forRange("i",0,$,B=>{x.subschema({keyword:E,dataProp:B,dataPropType:t.Type.Num},D),P.if((0,e.not)(D),L)})}}Kt.validateArray=_;function T(x){const{gen:P,schema:C,keyword:E,it:R}=x;if(!Array.isArray(C))throw new Error("ajv implementation error");if(C.some($=>(0,t.alwaysValidSchema)(R,$))&&!R.opts.unevaluated)return;const O=P.let("valid",!1),L=P.name("_valid");P.block(()=>C.forEach(($,B)=>{const U=x.subschema({keyword:E,schemaProp:B,compositeRule:!0},L);P.assign(O,(0,e._)`${O} || ${L}`),x.mergeValidEvaluated(U,L)||P.if((0,e.not)(O))})),x.result(O,()=>x.reset(),()=>x.error(!0))}return Kt.validateUnion=T,Kt}var ZA;function dK(){if(ZA)return cr;ZA=1,Object.defineProperty(cr,"__esModule",{value:!0}),cr.validateKeywordUsage=cr.validSchemaType=cr.funcKeywordCode=cr.macroKeywordCode=void 0;const e=yt(),t=js(),o=kr(),a=Av();function n(f,v){const{gen:b,keyword:S,schema:_,parentSchema:T,it:x}=f,P=v.macro.call(x.self,_,T,x),C=p(b,S,P);x.opts.validateSchema!==!1&&x.self.validateSchema(P,!0);const E=b.name("valid");f.subschema({schema:P,schemaPath:e.nil,errSchemaPath:`${x.errSchemaPath}/${S}`,topSchemaRef:C,compositeRule:!0},E),f.pass(E,()=>f.error(!0))}cr.macroKeywordCode=n;function i(f,v){var b;const{gen:S,keyword:_,schema:T,parentSchema:x,$data:P,it:C}=f;u(C,v);const E=!P&&v.compile?v.compile.call(C.self,T,x,C):v.validate,R=p(S,_,E),D=S.let("valid");f.block$data(D,O),f.ok((b=v.valid)!==null&&b!==void 0?b:D);function O(){if(v.errors===!1)B(),v.modifying&&l(f),U(()=>f.error());else{const j=v.async?L():$();v.modifying&&l(f),U(()=>c(f,j))}}function L(){const j=S.let("ruleErrs",null);return S.try(()=>B((0,e._)`await `),W=>S.assign(D,!1).if((0,e._)`${W} instanceof ${C.ValidationError}`,()=>S.assign(j,(0,e._)`${W}.errors`),()=>S.throw(W))),j}function $(){const j=(0,e._)`${R}.errors`;return S.assign(j,null),B(e.nil),j}function B(j=v.async?(0,e._)`await `:e.nil){const W=C.opts.passContext?t.default.this:t.default.self,ne=!("compile"in v&&!P||v.schema===!1);S.assign(D,(0,e._)`${j}${(0,o.callValidateCode)(f,R,W,ne)}`,v.modifying)}function U(j){var W;S.if((0,e.not)((W=v.valid)!==null&&W!==void 0?W:D),j)}}cr.funcKeywordCode=i;function l(f){const{gen:v,data:b,it:S}=f;v.if(S.parentData,()=>v.assign(b,(0,e._)`${S.parentData}[${S.parentDataProperty}]`))}function c(f,v){const{gen:b}=f;b.if((0,e._)`Array.isArray(${v})`,()=>{b.assign(t.default.vErrors,(0,e._)`${t.default.vErrors} === null ? ${v} : ${t.default.vErrors}.concat(${v})`).assign(t.default.errors,(0,e._)`${t.default.vErrors}.length`),(0,a.extendErrors)(f)},()=>f.error())}function u({schemaEnv:f},v){if(v.async&&!f.$async)throw new Error("async keyword in sync schema")}function p(f,v,b){if(b===void 0)throw new Error(`keyword "${v}" failed to compile`);return f.scopeValue("keyword",typeof b=="function"?{ref:b}:{ref:b,code:(0,e.stringify)(b)})}function m(f,v,b=!1){return!v.length||v.some(S=>S==="array"?Array.isArray(f):S==="object"?f&&typeof f=="object"&&!Array.isArray(f):typeof f==S||b&&typeof f>"u")}cr.validSchemaType=m;function h({schema:f,opts:v,self:b,errSchemaPath:S},_,T){if(Array.isArray(_.keyword)?!_.keyword.includes(T):_.keyword!==T)throw new Error("ajv implementation error");const x=_.dependencies;if(x?.some(P=>!Object.prototype.hasOwnProperty.call(f,P)))throw new Error(`parent schema must have dependencies of ${T}: ${x.join(",")}`);if(_.validateSchema&&!_.validateSchema(f[T])){const C=`keyword "${T}" value is invalid at path "${S}": `+b.errorsText(_.validateSchema.errors);if(v.validateSchema==="log")b.logger.error(C);else throw new Error(C)}}return cr.validateKeywordUsage=h,cr}var yi={},QA;function uK(){if(QA)return yi;QA=1,Object.defineProperty(yi,"__esModule",{value:!0}),yi.extendSubschemaMode=yi.extendSubschemaData=yi.getSubschema=void 0;const e=yt(),t=Lt();function o(i,{keyword:l,schemaProp:c,schema:u,schemaPath:p,errSchemaPath:m,topSchemaRef:h}){if(l!==void 0&&u!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(l!==void 0){const f=i.schema[l];return c===void 0?{schema:f,schemaPath:(0,e._)`${i.schemaPath}${(0,e.getProperty)(l)}`,errSchemaPath:`${i.errSchemaPath}/${l}`}:{schema:f[c],schemaPath:(0,e._)`${i.schemaPath}${(0,e.getProperty)(l)}${(0,e.getProperty)(c)}`,errSchemaPath:`${i.errSchemaPath}/${l}/${(0,t.escapeFragment)(c)}`}}if(u!==void 0){if(p===void 0||m===void 0||h===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:u,schemaPath:p,topSchemaRef:h,errSchemaPath:m}}throw new Error('either "keyword" or "schema" must be passed')}yi.getSubschema=o;function a(i,l,{dataProp:c,dataPropType:u,data:p,dataTypes:m,propertyName:h}){if(p!==void 0&&c!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:f}=l;if(c!==void 0){const{errorPath:b,dataPathArr:S,opts:_}=l,T=f.let("data",(0,e._)`${l.data}${(0,e.getProperty)(c)}`,!0);v(T),i.errorPath=(0,e.str)`${b}${(0,t.getErrorPath)(c,u,_.jsPropertySyntax)}`,i.parentDataProperty=(0,e._)`${c}`,i.dataPathArr=[...S,i.parentDataProperty]}if(p!==void 0){const b=p instanceof e.Name?p:f.let("data",p,!0);v(b),h!==void 0&&(i.propertyName=h)}m&&(i.dataTypes=m);function v(b){i.data=b,i.dataLevel=l.dataLevel+1,i.dataTypes=[],l.definedProperties=new Set,i.parentData=l.data,i.dataNames=[...l.dataNames,b]}}yi.extendSubschemaData=a;function n(i,{jtdDiscriminator:l,jtdMetadata:c,compositeRule:u,createErrors:p,allErrors:m}){u!==void 0&&(i.compositeRule=u),p!==void 0&&(i.createErrors=p),m!==void 0&&(i.allErrors=m),i.jtdDiscriminator=l,i.jtdMetadata=c}return yi.extendSubschemaMode=n,yi}var $a={},VS,JA;function LI(){return JA||(JA=1,VS=function e(t,o){if(t===o)return!0;if(t&&o&&typeof t=="object"&&typeof o=="object"){if(t.constructor!==o.constructor)return!1;var a,n,i;if(Array.isArray(t)){if(a=t.length,a!=o.length)return!1;for(n=a;n--!==0;)if(!e(t[n],o[n]))return!1;return!0}if(t.constructor===RegExp)return t.source===o.source&&t.flags===o.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===o.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===o.toString();if(i=Object.keys(t),a=i.length,a!==Object.keys(o).length)return!1;for(n=a;n--!==0;)if(!Object.prototype.hasOwnProperty.call(o,i[n]))return!1;for(n=a;n--!==0;){var l=i[n];if(!e(t[l],o[l]))return!1}return!0}return t!==t&&o!==o}),VS}var HS={exports:{}},XA;function pK(){if(XA)return HS.exports;XA=1;var e=HS.exports=function(a,n,i){typeof n=="function"&&(i=n,n={}),i=n.cb||i;var l=typeof i=="function"?i:i.pre||function(){},c=i.post||function(){};t(n,l,c,a,"",a)};e.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0},e.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},e.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},e.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function t(a,n,i,l,c,u,p,m,h,f){if(l&&typeof l=="object"&&!Array.isArray(l)){n(l,c,u,p,m,h,f);for(var v in l){var b=l[v];if(Array.isArray(b)){if(v in e.arrayKeywords)for(var S=0;S<b.length;S++)t(a,n,i,b[S],c+"/"+v+"/"+S,u,c,v,l,S)}else if(v in e.propsKeywords){if(b&&typeof b=="object")for(var _ in b)t(a,n,i,b[_],c+"/"+v+"/"+o(_),u,c,v,l,_)}else(v in e.keywords||a.allKeys&&!(v in e.skipKeywords))&&t(a,n,i,b,c+"/"+v,u,c,v,l)}i(l,c,u,p,m,h,f)}}function o(a){return a.replace(/~/g,"~0").replace(/\//g,"~1")}return HS.exports}var eR;function Rv(){if(eR)return $a;eR=1,Object.defineProperty($a,"__esModule",{value:!0}),$a.getSchemaRefs=$a.resolveUrl=$a.normalizeId=$a._getFullPath=$a.getFullPath=$a.inlineRef=void 0;const e=Lt(),t=LI(),o=pK(),a=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function n(S,_=!0){return typeof S=="boolean"?!0:_===!0?!l(S):_?c(S)<=_:!1}$a.inlineRef=n;const i=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function l(S){for(const _ in S){if(i.has(_))return!0;const T=S[_];if(Array.isArray(T)&&T.some(l)||typeof T=="object"&&l(T))return!0}return!1}function c(S){let _=0;for(const T in S){if(T==="$ref")return 1/0;if(_++,!a.has(T)&&(typeof S[T]=="object"&&(0,e.eachItem)(S[T],x=>_+=c(x)),_===1/0))return 1/0}return _}function u(S,_="",T){T!==!1&&(_=h(_));const x=S.parse(_);return p(S,x)}$a.getFullPath=u;function p(S,_){return S.serialize(_).split("#")[0]+"#"}$a._getFullPath=p;const m=/#\/?$/;function h(S){return S?S.replace(m,""):""}$a.normalizeId=h;function f(S,_,T){return T=h(T),S.resolve(_,T)}$a.resolveUrl=f;const v=/^[a-z_][-a-z0-9._]*$/i;function b(S,_){if(typeof S=="boolean")return{};const{schemaId:T,uriResolver:x}=this.opts,P=h(S[T]||_),C={"":P},E=u(x,P,!1),R={},D=new Set;return o(S,{allKeys:!0},($,B,U,j)=>{if(j===void 0)return;const W=E+B;let ne=C[j];typeof $[T]=="string"&&(ne=H.call(this,$[T])),Z.call(this,$.$anchor),Z.call(this,$.$dynamicAnchor),C[B]=ne;function H(te){const le=this.opts.uriResolver.resolve;if(te=h(ne?le(ne,te):te),D.has(te))throw L(te);D.add(te);let Q=this.refs[te];return typeof Q=="string"&&(Q=this.refs[Q]),typeof Q=="object"?O($,Q.schema,te):te!==h(W)&&(te[0]==="#"?(O($,R[te],te),R[te]=$):this.refs[te]=W),te}function Z(te){if(typeof te=="string"){if(!v.test(te))throw new Error(`invalid anchor "${te}"`);H.call(this,`#${te}`)}}}),R;function O($,B,U){if(B!==void 0&&!t($,B))throw L(U)}function L($){return new Error(`reference "${$}" resolves to more than one schema`)}}return $a.getSchemaRefs=b,$a}var tR;function Dv(){if(tR)return vi;tR=1,Object.defineProperty(vi,"__esModule",{value:!0}),vi.getData=vi.KeywordCxt=vi.validateFunctionCode=void 0;const e=lK(),t=Ef(),o=II(),a=Ef(),n=cK(),i=dK(),l=uK(),c=yt(),u=js(),p=Rv(),m=Lt(),h=Av();function f(Y){if(E(Y)&&(D(Y),C(Y))){_(Y);return}v(Y,()=>(0,e.topBoolOrEmptySchema)(Y))}vi.validateFunctionCode=f;function v({gen:Y,validateName:ae,schema:ve,schemaEnv:ie,opts:Te},Ce){Te.code.es5?Y.func(ae,(0,c._)`${u.default.data}, ${u.default.valCxt}`,ie.$async,()=>{Y.code((0,c._)`"use strict"; ${x(ve,Te)}`),S(Y,Te),Y.code(Ce)}):Y.func(ae,(0,c._)`${u.default.data}, ${b(Te)}`,ie.$async,()=>Y.code(x(ve,Te)).code(Ce))}function b(Y){return(0,c._)`{${u.default.instancePath}="", ${u.default.parentData}, ${u.default.parentDataProperty}, ${u.default.rootData}=${u.default.data}${Y.dynamicRef?(0,c._)`, ${u.default.dynamicAnchors}={}`:c.nil}}={}`}function S(Y,ae){Y.if(u.default.valCxt,()=>{Y.var(u.default.instancePath,(0,c._)`${u.default.valCxt}.${u.default.instancePath}`),Y.var(u.default.parentData,(0,c._)`${u.default.valCxt}.${u.default.parentData}`),Y.var(u.default.parentDataProperty,(0,c._)`${u.default.valCxt}.${u.default.parentDataProperty}`),Y.var(u.default.rootData,(0,c._)`${u.default.valCxt}.${u.default.rootData}`),ae.dynamicRef&&Y.var(u.default.dynamicAnchors,(0,c._)`${u.default.valCxt}.${u.default.dynamicAnchors}`)},()=>{Y.var(u.default.instancePath,(0,c._)`""`),Y.var(u.default.parentData,(0,c._)`undefined`),Y.var(u.default.parentDataProperty,(0,c._)`undefined`),Y.var(u.default.rootData,u.default.data),ae.dynamicRef&&Y.var(u.default.dynamicAnchors,(0,c._)`{}`)})}function _(Y){const{schema:ae,opts:ve,gen:ie}=Y;v(Y,()=>{ve.$comment&&ae.$comment&&j(Y),$(Y),ie.let(u.default.vErrors,null),ie.let(u.default.errors,0),ve.unevaluated&&T(Y),O(Y),W(Y)})}function T(Y){const{gen:ae,validateName:ve}=Y;Y.evaluated=ae.const("evaluated",(0,c._)`${ve}.evaluated`),ae.if((0,c._)`${Y.evaluated}.dynamicProps`,()=>ae.assign((0,c._)`${Y.evaluated}.props`,(0,c._)`undefined`)),ae.if((0,c._)`${Y.evaluated}.dynamicItems`,()=>ae.assign((0,c._)`${Y.evaluated}.items`,(0,c._)`undefined`))}function x(Y,ae){const ve=typeof Y=="object"&&Y[ae.schemaId];return ve&&(ae.code.source||ae.code.process)?(0,c._)`/*# sourceURL=${ve} */`:c.nil}function P(Y,ae){if(E(Y)&&(D(Y),C(Y))){R(Y,ae);return}(0,e.boolOrEmptySchema)(Y,ae)}function C({schema:Y,self:ae}){if(typeof Y=="boolean")return!Y;for(const ve in Y)if(ae.RULES.all[ve])return!0;return!1}function E(Y){return typeof Y.schema!="boolean"}function R(Y,ae){const{schema:ve,gen:ie,opts:Te}=Y;Te.$comment&&ve.$comment&&j(Y),B(Y),U(Y);const Ce=ie.const("_errs",u.default.errors);O(Y,Ce),ie.var(ae,(0,c._)`${Ce} === ${u.default.errors}`)}function D(Y){(0,m.checkUnknownRules)(Y),L(Y)}function O(Y,ae){if(Y.opts.jtd)return H(Y,[],!1,ae);const ve=(0,t.getSchemaTypes)(Y.schema),ie=(0,t.coerceAndCheckDataType)(Y,ve);H(Y,ve,!ie,ae)}function L(Y){const{schema:ae,errSchemaPath:ve,opts:ie,self:Te}=Y;ae.$ref&&ie.ignoreKeywordsWithRef&&(0,m.schemaHasRulesButRef)(ae,Te.RULES)&&Te.logger.warn(`$ref: keywords ignored in schema at path "${ve}"`)}function $(Y){const{schema:ae,opts:ve}=Y;ae.default!==void 0&&ve.useDefaults&&ve.strictSchema&&(0,m.checkStrictMode)(Y,"default is ignored in the schema root")}function B(Y){const ae=Y.schema[Y.opts.schemaId];ae&&(Y.baseId=(0,p.resolveUrl)(Y.opts.uriResolver,Y.baseId,ae))}function U(Y){if(Y.schema.$async&&!Y.schemaEnv.$async)throw new Error("async schema in sync schema")}function j({gen:Y,schemaEnv:ae,schema:ve,errSchemaPath:ie,opts:Te}){const Ce=ve.$comment;if(Te.$comment===!0)Y.code((0,c._)`${u.default.self}.logger.log(${Ce})`);else if(typeof Te.$comment=="function"){const it=(0,c.str)`${ie}/$comment`,lt=Y.scopeValue("root",{ref:ae.root});Y.code((0,c._)`${u.default.self}.opts.$comment(${Ce}, ${it}, ${lt}.schema)`)}}function W(Y){const{gen:ae,schemaEnv:ve,validateName:ie,ValidationError:Te,opts:Ce}=Y;ve.$async?ae.if((0,c._)`${u.default.errors} === 0`,()=>ae.return(u.default.data),()=>ae.throw((0,c._)`new ${Te}(${u.default.vErrors})`)):(ae.assign((0,c._)`${ie}.errors`,u.default.vErrors),Ce.unevaluated&&ne(Y),ae.return((0,c._)`${u.default.errors} === 0`))}function ne({gen:Y,evaluated:ae,props:ve,items:ie}){ve instanceof c.Name&&Y.assign((0,c._)`${ae}.props`,ve),ie instanceof c.Name&&Y.assign((0,c._)`${ae}.items`,ie)}function H(Y,ae,ve,ie){const{gen:Te,schema:Ce,data:it,allErrors:lt,opts:Ge,self:tt}=Y,{RULES:Oe}=tt;if(Ce.$ref&&(Ge.ignoreKeywordsWithRef||!(0,m.schemaHasRulesButRef)(Ce,Oe))){Te.block(()=>pe(Y,"$ref",Oe.all.$ref.definition));return}Ge.jtd||te(Y,ae),Te.block(()=>{for(const He of Oe.rules)De(He);De(Oe.post)});function De(He){(0,o.shouldUseGroup)(Ce,He)&&(He.type?(Te.if((0,a.checkDataType)(He.type,it,Ge.strictNumbers)),Z(Y,He),ae.length===1&&ae[0]===He.type&&ve&&(Te.else(),(0,a.reportTypeError)(Y)),Te.endIf()):Z(Y,He),lt||Te.if((0,c._)`${u.default.errors} === ${ie||0}`))}}function Z(Y,ae){const{gen:ve,schema:ie,opts:{useDefaults:Te}}=Y;Te&&(0,n.assignDefaults)(Y,ae.type),ve.block(()=>{for(const Ce of ae.rules)(0,o.shouldUseRule)(ie,Ce)&&pe(Y,Ce.keyword,Ce.definition,ae.type)})}function te(Y,ae){Y.schemaEnv.meta||!Y.opts.strictTypes||(le(Y,ae),Y.opts.allowUnionTypes||Q(Y,ae),N(Y,Y.dataTypes))}function le(Y,ae){if(ae.length){if(!Y.dataTypes.length){Y.dataTypes=ae;return}ae.forEach(ve=>{V(Y.dataTypes,ve)||z(Y,`type "${ve}" not allowed by context "${Y.dataTypes.join(",")}"`)}),I(Y,ae)}}function Q(Y,ae){ae.length>1&&!(ae.length===2&&ae.includes("null"))&&z(Y,"use allowUnionTypes to allow union type keyword")}function N(Y,ae){const ve=Y.self.RULES.all;for(const ie in ve){const Te=ve[ie];if(typeof Te=="object"&&(0,o.shouldUseRule)(Y.schema,Te)){const{type:Ce}=Te.definition;Ce.length&&!Ce.some(it=>G(ae,it))&&z(Y,`missing type "${Ce.join(",")}" for keyword "${ie}"`)}}}function G(Y,ae){return Y.includes(ae)||ae==="number"&&Y.includes("integer")}function V(Y,ae){return Y.includes(ae)||ae==="integer"&&Y.includes("number")}function I(Y,ae){const ve=[];for(const ie of Y.dataTypes)V(ae,ie)?ve.push(ie):ae.includes("integer")&&ie==="number"&&ve.push("integer");Y.dataTypes=ve}function z(Y,ae){const ve=Y.schemaEnv.baseId+Y.errSchemaPath;ae+=` at "${ve}" (strictTypes)`,(0,m.checkStrictMode)(Y,ae,Y.opts.strictTypes)}class J{constructor(ae,ve,ie){if((0,i.validateKeywordUsage)(ae,ve,ie),this.gen=ae.gen,this.allErrors=ae.allErrors,this.keyword=ie,this.data=ae.data,this.schema=ae.schema[ie],this.$data=ve.$data&&ae.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,m.schemaRefOrVal)(ae,this.schema,ie,this.$data),this.schemaType=ve.schemaType,this.parentSchema=ae.schema,this.params={},this.it=ae,this.def=ve,this.$data)this.schemaCode=ae.gen.const("vSchema",$e(this.$data,ae));else if(this.schemaCode=this.schemaValue,!(0,i.validSchemaType)(this.schema,ve.schemaType,ve.allowUndefined))throw new Error(`${ie} value must be ${JSON.stringify(ve.schemaType)}`);("code"in ve?ve.trackErrors:ve.errors!==!1)&&(this.errsCount=ae.gen.const("_errs",u.default.errors))}result(ae,ve,ie){this.failResult((0,c.not)(ae),ve,ie)}failResult(ae,ve,ie){this.gen.if(ae),ie?ie():this.error(),ve?(this.gen.else(),ve(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(ae,ve){this.failResult((0,c.not)(ae),void 0,ve)}fail(ae){if(ae===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(ae),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(ae){if(!this.$data)return this.fail(ae);const{schemaCode:ve}=this;this.fail((0,c._)`${ve} !== undefined && (${(0,c.or)(this.invalid$data(),ae)})`)}error(ae,ve,ie){if(ve){this.setParams(ve),this._error(ae,ie),this.setParams({});return}this._error(ae,ie)}_error(ae,ve){(ae?h.reportExtraError:h.reportError)(this,this.def.error,ve)}$dataError(){(0,h.reportError)(this,this.def.$dataError||h.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,h.resetErrorsCount)(this.gen,this.errsCount)}ok(ae){this.allErrors||this.gen.if(ae)}setParams(ae,ve){ve?Object.assign(this.params,ae):this.params=ae}block$data(ae,ve,ie=c.nil){this.gen.block(()=>{this.check$data(ae,ie),ve()})}check$data(ae=c.nil,ve=c.nil){if(!this.$data)return;const{gen:ie,schemaCode:Te,schemaType:Ce,def:it}=this;ie.if((0,c.or)((0,c._)`${Te} === undefined`,ve)),ae!==c.nil&&ie.assign(ae,!0),(Ce.length||it.validateSchema)&&(ie.elseIf(this.invalid$data()),this.$dataError(),ae!==c.nil&&ie.assign(ae,!1)),ie.else()}invalid$data(){const{gen:ae,schemaCode:ve,schemaType:ie,def:Te,it:Ce}=this;return(0,c.or)(it(),lt());function it(){if(ie.length){if(!(ve instanceof c.Name))throw new Error("ajv implementation error");const Ge=Array.isArray(ie)?ie:[ie];return(0,c._)`${(0,a.checkDataTypes)(Ge,ve,Ce.opts.strictNumbers,a.DataType.Wrong)}`}return c.nil}function lt(){if(Te.validateSchema){const Ge=ae.scopeValue("validate$data",{ref:Te.validateSchema});return(0,c._)`!${Ge}(${ve})`}return c.nil}}subschema(ae,ve){const ie=(0,l.getSubschema)(this.it,ae);(0,l.extendSubschemaData)(ie,this.it,ae),(0,l.extendSubschemaMode)(ie,ae);const Te={...this.it,...ie,items:void 0,props:void 0};return P(Te,ve),Te}mergeEvaluated(ae,ve){const{it:ie,gen:Te}=this;ie.opts.unevaluated&&(ie.props!==!0&&ae.props!==void 0&&(ie.props=m.mergeEvaluated.props(Te,ae.props,ie.props,ve)),ie.items!==!0&&ae.items!==void 0&&(ie.items=m.mergeEvaluated.items(Te,ae.items,ie.items,ve)))}mergeValidEvaluated(ae,ve){const{it:ie,gen:Te}=this;if(ie.opts.unevaluated&&(ie.props!==!0||ie.items!==!0))return Te.if(ve,()=>this.mergeEvaluated(ae,c.Name)),!0}}vi.KeywordCxt=J;function pe(Y,ae,ve,ie){const Te=new J(Y,ve,ae);"code"in ve?ve.code(Te,ie):Te.$data&&ve.validate?(0,i.funcKeywordCode)(Te,ve):"macro"in ve?(0,i.macroKeywordCode)(Te,ve):(ve.compile||ve.validate)&&(0,i.funcKeywordCode)(Te,ve)}const he=/^\/(?:[^~]|~0|~1)*$/,_e=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function $e(Y,{dataLevel:ae,dataNames:ve,dataPathArr:ie}){let Te,Ce;if(Y==="")return u.default.rootData;if(Y[0]==="/"){if(!he.test(Y))throw new Error(`Invalid JSON-pointer: ${Y}`);Te=Y,Ce=u.default.rootData}else{const tt=_e.exec(Y);if(!tt)throw new Error(`Invalid JSON-pointer: ${Y}`);const Oe=+tt[1];if(Te=tt[2],Te==="#"){if(Oe>=ae)throw new Error(Ge("property/index",Oe));return ie[ae-Oe]}if(Oe>ae)throw new Error(Ge("data",Oe));if(Ce=ve[ae-Oe],!Te)return Ce}let it=Ce;const lt=Te.split("/");for(const tt of lt)tt&&(Ce=(0,c._)`${Ce}${(0,c.getProperty)((0,m.unescapeJsonPointer)(tt))}`,it=(0,c._)`${it} && ${Ce}`);return it;function Ge(tt,Oe){return`Cannot access ${tt} ${Oe} levels up, current level is ${ae}`}}return vi.getData=$e,vi}var Bh={},oR;function o_(){if(oR)return Bh;oR=1,Object.defineProperty(Bh,"__esModule",{value:!0});class e extends Error{constructor(o){super("validation failed"),this.errors=o,this.ajv=this.validation=!0}}return Bh.default=e,Bh}var Fh={},aR;function Ov(){if(aR)return Fh;aR=1,Object.defineProperty(Fh,"__esModule",{value:!0});const e=Rv();class t extends Error{constructor(a,n,i,l){super(l||`can't resolve reference ${i} from id ${n}`),this.missingRef=(0,e.resolveUrl)(a,n,i),this.missingSchema=(0,e.normalizeId)((0,e.getFullPath)(a,this.missingRef))}}return Fh.default=t,Fh}var Sn={},nR;function a_(){if(nR)return Sn;nR=1,Object.defineProperty(Sn,"__esModule",{value:!0}),Sn.resolveSchema=Sn.getCompilingSchema=Sn.resolveRef=Sn.compileSchema=Sn.SchemaEnv=void 0;const e=yt(),t=o_(),o=js(),a=Rv(),n=Lt(),i=Dv();class l{constructor(T){var x;this.refs={},this.dynamicAnchors={};let P;typeof T.schema=="object"&&(P=T.schema),this.schema=T.schema,this.schemaId=T.schemaId,this.root=T.root||this,this.baseId=(x=T.baseId)!==null&&x!==void 0?x:(0,a.normalizeId)(P?.[T.schemaId||"$id"]),this.schemaPath=T.schemaPath,this.localRefs=T.localRefs,this.meta=T.meta,this.$async=P?.$async,this.refs={}}}Sn.SchemaEnv=l;function c(_){const T=m.call(this,_);if(T)return T;const x=(0,a.getFullPath)(this.opts.uriResolver,_.root.baseId),{es5:P,lines:C}=this.opts.code,{ownProperties:E}=this.opts,R=new e.CodeGen(this.scope,{es5:P,lines:C,ownProperties:E});let D;_.$async&&(D=R.scopeValue("Error",{ref:t.default,code:(0,e._)`require("ajv/dist/runtime/validation_error").default`}));const O=R.scopeName("validate");_.validateName=O;const L={gen:R,allErrors:this.opts.allErrors,data:o.default.data,parentData:o.default.parentData,parentDataProperty:o.default.parentDataProperty,dataNames:[o.default.data],dataPathArr:[e.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:R.scopeValue("schema",this.opts.code.source===!0?{ref:_.schema,code:(0,e.stringify)(_.schema)}:{ref:_.schema}),validateName:O,ValidationError:D,schema:_.schema,schemaEnv:_,rootId:x,baseId:_.baseId||x,schemaPath:e.nil,errSchemaPath:_.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,e._)`""`,opts:this.opts,self:this};let $;try{this._compilations.add(_),(0,i.validateFunctionCode)(L),R.optimize(this.opts.code.optimize);const B=R.toString();$=`${R.scopeRefs(o.default.scope)}return ${B}`,this.opts.code.process&&($=this.opts.code.process($,_));const j=new Function(`${o.default.self}`,`${o.default.scope}`,$)(this,this.scope.get());if(this.scope.value(O,{ref:j}),j.errors=null,j.schema=_.schema,j.schemaEnv=_,_.$async&&(j.$async=!0),this.opts.code.source===!0&&(j.source={validateName:O,validateCode:B,scopeValues:R._values}),this.opts.unevaluated){const{props:W,items:ne}=L;j.evaluated={props:W instanceof e.Name?void 0:W,items:ne instanceof e.Name?void 0:ne,dynamicProps:W instanceof e.Name,dynamicItems:ne instanceof e.Name},j.source&&(j.source.evaluated=(0,e.stringify)(j.evaluated))}return _.validate=j,_}catch(B){throw delete _.validate,delete _.validateName,$&&this.logger.error("Error compiling schema, function code:",$),B}finally{this._compilations.delete(_)}}Sn.compileSchema=c;function u(_,T,x){var P;x=(0,a.resolveUrl)(this.opts.uriResolver,T,x);const C=_.refs[x];if(C)return C;let E=f.call(this,_,x);if(E===void 0){const R=(P=_.localRefs)===null||P===void 0?void 0:P[x],{schemaId:D}=this.opts;R&&(E=new l({schema:R,schemaId:D,root:_,baseId:T}))}if(E!==void 0)return _.refs[x]=p.call(this,E)}Sn.resolveRef=u;function p(_){return(0,a.inlineRef)(_.schema,this.opts.inlineRefs)?_.schema:_.validate?_:c.call(this,_)}function m(_){for(const T of this._compilations)if(h(T,_))return T}Sn.getCompilingSchema=m;function h(_,T){return _.schema===T.schema&&_.root===T.root&&_.baseId===T.baseId}function f(_,T){let x;for(;typeof(x=this.refs[T])=="string";)T=x;return x||this.schemas[T]||v.call(this,_,T)}function v(_,T){const x=this.opts.uriResolver.parse(T),P=(0,a._getFullPath)(this.opts.uriResolver,x);let C=(0,a.getFullPath)(this.opts.uriResolver,_.baseId,void 0);if(Object.keys(_.schema).length>0&&P===C)return S.call(this,x,_);const E=(0,a.normalizeId)(P),R=this.refs[E]||this.schemas[E];if(typeof R=="string"){const D=v.call(this,_,R);return typeof D?.schema!="object"?void 0:S.call(this,x,D)}if(typeof R?.schema=="object"){if(R.validate||c.call(this,R),E===(0,a.normalizeId)(T)){const{schema:D}=R,{schemaId:O}=this.opts,L=D[O];return L&&(C=(0,a.resolveUrl)(this.opts.uriResolver,C,L)),new l({schema:D,schemaId:O,root:_,baseId:C})}return S.call(this,x,R)}}Sn.resolveSchema=v;const b=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function S(_,{baseId:T,schema:x,root:P}){var C;if(((C=_.fragment)===null||C===void 0?void 0:C[0])!=="/")return;for(const D of _.fragment.slice(1).split("/")){if(typeof x=="boolean")return;const O=x[(0,n.unescapeFragment)(D)];if(O===void 0)return;x=O;const L=typeof x=="object"&&x[this.opts.schemaId];!b.has(D)&&L&&(T=(0,a.resolveUrl)(this.opts.uriResolver,T,L))}let E;if(typeof x!="boolean"&&x.$ref&&!(0,n.schemaHasRulesButRef)(x,this.RULES)){const D=(0,a.resolveUrl)(this.opts.uriResolver,T,x.$ref);E=v.call(this,P,D)}const{schemaId:R}=this.opts;if(E=E||new l({schema:x,schemaId:R,root:P,baseId:T}),E.schema!==E.root.schema)return E}return Sn}const mK="https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",hK="Meta-schema for $data reference (JSON AnySchema extension proposal)",gK="object",fK=["$data"],vK={$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},bK=!1,yK={$id:mK,description:hK,type:gK,required:fK,properties:vK,additionalProperties:bK};var jh={},Du={exports:{}},GS,rR;function BI(){if(rR)return GS;rR=1;const e=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),t=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u);function o(f){let v="",b=0,S=0;for(S=0;S<f.length;S++)if(b=f[S].charCodeAt(0),b!==48){if(!(b>=48&&b<=57||b>=65&&b<=70||b>=97&&b<=102))return"";v+=f[S];break}for(S+=1;S<f.length;S++){if(b=f[S].charCodeAt(0),!(b>=48&&b<=57||b>=65&&b<=70||b>=97&&b<=102))return"";v+=f[S]}return v}const a=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function n(f){return f.length=0,!0}function i(f,v,b){if(f.length){const S=o(f);if(S!=="")v.push(S);else return b.error=!0,!1;f.length=0}return!0}function l(f){let v=0;const b={error:!1,address:"",zone:""},S=[],_=[];let T=!1,x=!1,P=i;for(let C=0;C<f.length;C++){const E=f[C];if(!(E==="["||E==="]"))if(E===":"){if(T===!0&&(x=!0),!P(_,S,b))break;if(++v>7){b.error=!0;break}C>0&&f[C-1]===":"&&(T=!0),S.push(":");continue}else if(E==="%"){if(!P(_,S,b))break;P=n}else{_.push(E);continue}}return _.length&&(P===n?b.zone=_.join(""):x?S.push(_.join("")):S.push(o(_))),b.address=S.join(""),b}function c(f){if(u(f,":")<2)return{host:f,isIPV6:!1};const v=l(f);if(v.error)return{host:f,isIPV6:!1};{let b=v.address,S=v.address;return v.zone&&(b+="%"+v.zone,S+="%25"+v.zone),{host:b,isIPV6:!0,escapedHost:S}}}function u(f,v){let b=0;for(let S=0;S<f.length;S++)f[S]===v&&b++;return b}function p(f){let v=f;const b=[];let S=-1,_=0;for(;_=v.length;){if(_===1){if(v===".")break;if(v==="/"){b.push("/");break}else{b.push(v);break}}else if(_===2){if(v[0]==="."){if(v[1]===".")break;if(v[1]==="/"){v=v.slice(2);continue}}else if(v[0]==="/"&&(v[1]==="."||v[1]==="/")){b.push("/");break}}else if(_===3&&v==="/.."){b.length!==0&&b.pop(),b.push("/");break}if(v[0]==="."){if(v[1]==="."){if(v[2]==="/"){v=v.slice(3);continue}}else if(v[1]==="/"){v=v.slice(2);continue}}else if(v[0]==="/"&&v[1]==="."){if(v[2]==="/"){v=v.slice(2);continue}else if(v[2]==="."&&v[3]==="/"){v=v.slice(3),b.length!==0&&b.pop();continue}}if((S=v.indexOf("/",1))===-1){b.push(v);break}else b.push(v.slice(0,S)),v=v.slice(S)}return b.join("")}function m(f,v){const b=v!==!0?escape:unescape;return f.scheme!==void 0&&(f.scheme=b(f.scheme)),f.userinfo!==void 0&&(f.userinfo=b(f.userinfo)),f.host!==void 0&&(f.host=b(f.host)),f.path!==void 0&&(f.path=b(f.path)),f.query!==void 0&&(f.query=b(f.query)),f.fragment!==void 0&&(f.fragment=b(f.fragment)),f}function h(f){const v=[];if(f.userinfo!==void 0&&(v.push(f.userinfo),v.push("@")),f.host!==void 0){let b=unescape(f.host);if(!t(b)){const S=c(b);S.isIPV6===!0?b=`[${S.escapedHost}]`:b=f.host}v.push(b)}return(typeof f.port=="number"||typeof f.port=="string")&&(v.push(":"),v.push(String(f.port))),v.length?v.join(""):void 0}return GS={nonSimpleDomain:a,recomposeAuthority:h,normalizeComponentEncoding:m,removeDotSegments:p,isIPv4:t,isUUID:e,normalizeIPv6:c,stringArrayToHexStripped:o},GS}var WS,iR;function SK(){if(iR)return WS;iR=1;const{isUUID:e}=BI(),t=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,o=["http","https","ws","wss","urn","urn:uuid"];function a(E){return o.indexOf(E)!==-1}function n(E){return E.secure===!0?!0:E.secure===!1?!1:E.scheme?E.scheme.length===3&&(E.scheme[0]==="w"||E.scheme[0]==="W")&&(E.scheme[1]==="s"||E.scheme[1]==="S")&&(E.scheme[2]==="s"||E.scheme[2]==="S"):!1}function i(E){return E.host||(E.error=E.error||"HTTP URIs must have a host."),E}function l(E){const R=String(E.scheme).toLowerCase()==="https";return(E.port===(R?443:80)||E.port==="")&&(E.port=void 0),E.path||(E.path="/"),E}function c(E){return E.secure=n(E),E.resourceName=(E.path||"/")+(E.query?"?"+E.query:""),E.path=void 0,E.query=void 0,E}function u(E){if((E.port===(n(E)?443:80)||E.port==="")&&(E.port=void 0),typeof E.secure=="boolean"&&(E.scheme=E.secure?"wss":"ws",E.secure=void 0),E.resourceName){const[R,D]=E.resourceName.split("?");E.path=R&&R!=="/"?R:void 0,E.query=D,E.resourceName=void 0}return E.fragment=void 0,E}function p(E,R){if(!E.path)return E.error="URN can not be parsed",E;const D=E.path.match(t);if(D){const O=R.scheme||E.scheme||"urn";E.nid=D[1].toLowerCase(),E.nss=D[2];const L=`${O}:${R.nid||E.nid}`,$=C(L);E.path=void 0,$&&(E=$.parse(E,R))}else E.error=E.error||"URN can not be parsed.";return E}function m(E,R){if(E.nid===void 0)throw new Error("URN without nid cannot be serialized");const D=R.scheme||E.scheme||"urn",O=E.nid.toLowerCase(),L=`${D}:${R.nid||O}`,$=C(L);$&&(E=$.serialize(E,R));const B=E,U=E.nss;return B.path=`${O||R.nid}:${U}`,R.skipEscape=!0,B}function h(E,R){const D=E;return D.uuid=D.nss,D.nss=void 0,!R.tolerant&&(!D.uuid||!e(D.uuid))&&(D.error=D.error||"UUID is not valid."),D}function f(E){const R=E;return R.nss=(E.uuid||"").toLowerCase(),R}const v={scheme:"http",domainHost:!0,parse:i,serialize:l},b={scheme:"https",domainHost:v.domainHost,parse:i,serialize:l},S={scheme:"ws",domainHost:!0,parse:c,serialize:u},_={scheme:"wss",domainHost:S.domainHost,parse:S.parse,serialize:S.serialize},P={http:v,https:b,ws:S,wss:_,urn:{scheme:"urn",parse:p,serialize:m,skipNormalize:!0},"urn:uuid":{scheme:"urn:uuid",parse:h,serialize:f,skipNormalize:!0}};Object.setPrototypeOf(P,null);function C(E){return E&&(P[E]||P[E.toLowerCase()])||void 0}return WS={wsIsSecure:n,SCHEMES:P,isValidSchemeName:a,getSchemeHandler:C},WS}var sR;function wK(){if(sR)return Du.exports;sR=1;const{normalizeIPv6:e,removeDotSegments:t,recomposeAuthority:o,normalizeComponentEncoding:a,isIPv4:n,nonSimpleDomain:i}=BI(),{SCHEMES:l,getSchemeHandler:c}=SK();function u(_,T){return typeof _=="string"?_=f(b(_,T),T):typeof _=="object"&&(_=b(f(_,T),T)),_}function p(_,T,x){const P=x?Object.assign({scheme:"null"},x):{scheme:"null"},C=m(b(_,P),b(T,P),P,!0);return P.skipEscape=!0,f(C,P)}function m(_,T,x,P){const C={};return P||(_=b(f(_,x),x),T=b(f(T,x),x)),x=x||{},!x.tolerant&&T.scheme?(C.scheme=T.scheme,C.userinfo=T.userinfo,C.host=T.host,C.port=T.port,C.path=t(T.path||""),C.query=T.query):(T.userinfo!==void 0||T.host!==void 0||T.port!==void 0?(C.userinfo=T.userinfo,C.host=T.host,C.port=T.port,C.path=t(T.path||""),C.query=T.query):(T.path?(T.path[0]==="/"?C.path=t(T.path):((_.userinfo!==void 0||_.host!==void 0||_.port!==void 0)&&!_.path?C.path="/"+T.path:_.path?C.path=_.path.slice(0,_.path.lastIndexOf("/")+1)+T.path:C.path=T.path,C.path=t(C.path)),C.query=T.query):(C.path=_.path,T.query!==void 0?C.query=T.query:C.query=_.query),C.userinfo=_.userinfo,C.host=_.host,C.port=_.port),C.scheme=_.scheme),C.fragment=T.fragment,C}function h(_,T,x){return typeof _=="string"?(_=unescape(_),_=f(a(b(_,x),!0),{...x,skipEscape:!0})):typeof _=="object"&&(_=f(a(_,!0),{...x,skipEscape:!0})),typeof T=="string"?(T=unescape(T),T=f(a(b(T,x),!0),{...x,skipEscape:!0})):typeof T=="object"&&(T=f(a(T,!0),{...x,skipEscape:!0})),_.toLowerCase()===T.toLowerCase()}function f(_,T){const x={host:_.host,scheme:_.scheme,userinfo:_.userinfo,port:_.port,path:_.path,query:_.query,nid:_.nid,nss:_.nss,uuid:_.uuid,fragment:_.fragment,reference:_.reference,resourceName:_.resourceName,secure:_.secure,error:""},P=Object.assign({},T),C=[],E=c(P.scheme||x.scheme);E&&E.serialize&&E.serialize(x,P),x.path!==void 0&&(P.skipEscape?x.path=unescape(x.path):(x.path=escape(x.path),x.scheme!==void 0&&(x.path=x.path.split("%3A").join(":")))),P.reference!=="suffix"&&x.scheme&&C.push(x.scheme,":");const R=o(x);if(R!==void 0&&(P.reference!=="suffix"&&C.push("//"),C.push(R),x.path&&x.path[0]!=="/"&&C.push("/")),x.path!==void 0){let D=x.path;!P.absolutePath&&(!E||!E.absolutePath)&&(D=t(D)),R===void 0&&D[0]==="/"&&D[1]==="/"&&(D="/%2F"+D.slice(2)),C.push(D)}return x.query!==void 0&&C.push("?",x.query),x.fragment!==void 0&&C.push("#",x.fragment),C.join("")}const v=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function b(_,T){const x=Object.assign({},T),P={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0};let C=!1;x.reference==="suffix"&&(x.scheme?_=x.scheme+":"+_:_="//"+_);const E=_.match(v);if(E){if(P.scheme=E[1],P.userinfo=E[3],P.host=E[4],P.port=parseInt(E[5],10),P.path=E[6]||"",P.query=E[7],P.fragment=E[8],isNaN(P.port)&&(P.port=E[5]),P.host)if(n(P.host)===!1){const O=e(P.host);P.host=O.host.toLowerCase(),C=O.isIPV6}else C=!0;P.scheme===void 0&&P.userinfo===void 0&&P.host===void 0&&P.port===void 0&&P.query===void 0&&!P.path?P.reference="same-document":P.scheme===void 0?P.reference="relative":P.fragment===void 0?P.reference="absolute":P.reference="uri",x.reference&&x.reference!=="suffix"&&x.reference!==P.reference&&(P.error=P.error||"URI is not a "+x.reference+" reference.");const R=c(x.scheme||P.scheme);if(!x.unicodeSupport&&(!R||!R.unicodeSupport)&&P.host&&(x.domainHost||R&&R.domainHost)&&C===!1&&i(P.host))try{P.host=URL.domainToASCII(P.host.toLowerCase())}catch(D){P.error=P.error||"Host's domain name can not be converted to ASCII: "+D}(!R||R&&!R.skipNormalize)&&(_.indexOf("%")!==-1&&(P.scheme!==void 0&&(P.scheme=unescape(P.scheme)),P.host!==void 0&&(P.host=unescape(P.host))),P.path&&(P.path=escape(unescape(P.path))),P.fragment&&(P.fragment=encodeURI(decodeURIComponent(P.fragment)))),R&&R.parse&&R.parse(P,x)}else P.error=P.error||"URI can not be parsed.";return P}const S={SCHEMES:l,normalize:u,resolve:p,resolveComponent:m,equal:h,serialize:f,parse:b};return Du.exports=S,Du.exports.default=S,Du.exports.fastUri=S,Du.exports}var lR;function TK(){if(lR)return jh;lR=1,Object.defineProperty(jh,"__esModule",{value:!0});const e=wK();return e.code='require("ajv/dist/runtime/uri").default',jh.default=e,jh}var cR;function xK(){return cR||(cR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CodeGen=e.Name=e.nil=e.stringify=e.str=e._=e.KeywordCxt=void 0;var t=Dv();Object.defineProperty(e,"KeywordCxt",{enumerable:!0,get:function(){return t.KeywordCxt}});var o=yt();Object.defineProperty(e,"_",{enumerable:!0,get:function(){return o._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return o.str}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return o.stringify}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return o.nil}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return o.Name}}),Object.defineProperty(e,"CodeGen",{enumerable:!0,get:function(){return o.CodeGen}});const a=o_(),n=Ov(),i=NI(),l=a_(),c=yt(),u=Rv(),p=Ef(),m=Lt(),h=yK,f=TK(),v=(Q,N)=>new RegExp(Q,N);v.code="new RegExp";const b=["removeAdditional","useDefaults","coerceTypes"],S=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),_={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},T={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},x=200;function P(Q){var N,G,V,I,z,J,pe,he,_e,$e,Y,ae,ve,ie,Te,Ce,it,lt,Ge,tt,Oe,De,He,K,oe;const se=Q.strict,ke=(N=Q.code)===null||N===void 0?void 0:N.optimize,Pe=ke===!0||ke===void 0?1:ke||0,Ae=(V=(G=Q.code)===null||G===void 0?void 0:G.regExp)!==null&&V!==void 0?V:v,Ie=(I=Q.uriResolver)!==null&&I!==void 0?I:f.default;return{strictSchema:(J=(z=Q.strictSchema)!==null&&z!==void 0?z:se)!==null&&J!==void 0?J:!0,strictNumbers:(he=(pe=Q.strictNumbers)!==null&&pe!==void 0?pe:se)!==null&&he!==void 0?he:!0,strictTypes:($e=(_e=Q.strictTypes)!==null&&_e!==void 0?_e:se)!==null&&$e!==void 0?$e:"log",strictTuples:(ae=(Y=Q.strictTuples)!==null&&Y!==void 0?Y:se)!==null&&ae!==void 0?ae:"log",strictRequired:(ie=(ve=Q.strictRequired)!==null&&ve!==void 0?ve:se)!==null&&ie!==void 0?ie:!1,code:Q.code?{...Q.code,optimize:Pe,regExp:Ae}:{optimize:Pe,regExp:Ae},loopRequired:(Te=Q.loopRequired)!==null&&Te!==void 0?Te:x,loopEnum:(Ce=Q.loopEnum)!==null&&Ce!==void 0?Ce:x,meta:(it=Q.meta)!==null&&it!==void 0?it:!0,messages:(lt=Q.messages)!==null&&lt!==void 0?lt:!0,inlineRefs:(Ge=Q.inlineRefs)!==null&&Ge!==void 0?Ge:!0,schemaId:(tt=Q.schemaId)!==null&&tt!==void 0?tt:"$id",addUsedSchema:(Oe=Q.addUsedSchema)!==null&&Oe!==void 0?Oe:!0,validateSchema:(De=Q.validateSchema)!==null&&De!==void 0?De:!0,validateFormats:(He=Q.validateFormats)!==null&&He!==void 0?He:!0,unicodeRegExp:(K=Q.unicodeRegExp)!==null&&K!==void 0?K:!0,int32range:(oe=Q.int32range)!==null&&oe!==void 0?oe:!0,uriResolver:Ie}}class C{constructor(N={}){this.schemas={},this.refs={},this.formats=Object.create(null),this._compilations=new Set,this._loading={},this._cache=new Map,N=this.opts={...N,...P(N)};const{es5:G,lines:V}=this.opts.code;this.scope=new c.ValueScope({scope:{},prefixes:S,es5:G,lines:V}),this.logger=U(N.logger);const I=N.validateFormats;N.validateFormats=!1,this.RULES=(0,i.getRules)(),E.call(this,_,N,"NOT SUPPORTED"),E.call(this,T,N,"DEPRECATED","warn"),this._metaOpts=$.call(this),N.formats&&O.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),N.keywords&&L.call(this,N.keywords),typeof N.meta=="object"&&this.addMetaSchema(N.meta),D.call(this),N.validateFormats=I}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:N,meta:G,schemaId:V}=this.opts;let I=h;V==="id"&&(I={...h},I.id=I.$id,delete I.$id),G&&N&&this.addMetaSchema(I,I[V],!1)}defaultMeta(){const{meta:N,schemaId:G}=this.opts;return this.opts.defaultMeta=typeof N=="object"?N[G]||N:void 0}validate(N,G){let V;if(typeof N=="string"){if(V=this.getSchema(N),!V)throw new Error(`no schema with key or ref "${N}"`)}else V=this.compile(N);const I=V(G);return"$async"in V||(this.errors=V.errors),I}compile(N,G){const V=this._addSchema(N,G);return V.validate||this._compileSchemaEnv(V)}compileAsync(N,G){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");const{loadSchema:V}=this.opts;return I.call(this,N,G);async function I($e,Y){await z.call(this,$e.$schema);const ae=this._addSchema($e,Y);return ae.validate||J.call(this,ae)}async function z($e){$e&&!this.getSchema($e)&&await I.call(this,{$ref:$e},!0)}async function J($e){try{return this._compileSchemaEnv($e)}catch(Y){if(!(Y instanceof n.default))throw Y;return pe.call(this,Y),await he.call(this,Y.missingSchema),J.call(this,$e)}}function pe({missingSchema:$e,missingRef:Y}){if(this.refs[$e])throw new Error(`AnySchema ${$e} is loaded but ${Y} cannot be resolved`)}async function he($e){const Y=await _e.call(this,$e);this.refs[$e]||await z.call(this,Y.$schema),this.refs[$e]||this.addSchema(Y,$e,G)}async function _e($e){const Y=this._loading[$e];if(Y)return Y;try{return await(this._loading[$e]=V($e))}finally{delete this._loading[$e]}}}addSchema(N,G,V,I=this.opts.validateSchema){if(Array.isArray(N)){for(const J of N)this.addSchema(J,void 0,V,I);return this}let z;if(typeof N=="object"){const{schemaId:J}=this.opts;if(z=N[J],z!==void 0&&typeof z!="string")throw new Error(`schema ${J} must be string`)}return G=(0,u.normalizeId)(G||z),this._checkUnique(G),this.schemas[G]=this._addSchema(N,V,G,I,!0),this}addMetaSchema(N,G,V=this.opts.validateSchema){return this.addSchema(N,G,!0,V),this}validateSchema(N,G){if(typeof N=="boolean")return!0;let V;if(V=N.$schema,V!==void 0&&typeof V!="string")throw new Error("$schema must be a string");if(V=V||this.opts.defaultMeta||this.defaultMeta(),!V)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const I=this.validate(V,N);if(!I&&G){const z="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(z);else throw new Error(z)}return I}getSchema(N){let G;for(;typeof(G=R.call(this,N))=="string";)N=G;if(G===void 0){const{schemaId:V}=this.opts,I=new l.SchemaEnv({schema:{},schemaId:V});if(G=l.resolveSchema.call(this,I,N),!G)return;this.refs[N]=G}return G.validate||this._compileSchemaEnv(G)}removeSchema(N){if(N instanceof RegExp)return this._removeAllSchemas(this.schemas,N),this._removeAllSchemas(this.refs,N),this;switch(typeof N){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const G=R.call(this,N);return typeof G=="object"&&this._cache.delete(G.schema),delete this.schemas[N],delete this.refs[N],this}case"object":{const G=N;this._cache.delete(G);let V=N[this.opts.schemaId];return V&&(V=(0,u.normalizeId)(V),delete this.schemas[V],delete this.refs[V]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(N){for(const G of N)this.addKeyword(G);return this}addKeyword(N,G){let V;if(typeof N=="string")V=N,typeof G=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),G.keyword=V);else if(typeof N=="object"&&G===void 0){if(G=N,V=G.keyword,Array.isArray(V)&&!V.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(W.call(this,V,G),!G)return(0,m.eachItem)(V,z=>ne.call(this,z)),this;Z.call(this,G);const I={...G,type:(0,p.getJSONTypes)(G.type),schemaType:(0,p.getJSONTypes)(G.schemaType)};return(0,m.eachItem)(V,I.type.length===0?z=>ne.call(this,z,I):z=>I.type.forEach(J=>ne.call(this,z,I,J))),this}getKeyword(N){const G=this.RULES.all[N];return typeof G=="object"?G.definition:!!G}removeKeyword(N){const{RULES:G}=this;delete G.keywords[N],delete G.all[N];for(const V of G.rules){const I=V.rules.findIndex(z=>z.keyword===N);I>=0&&V.rules.splice(I,1)}return this}addFormat(N,G){return typeof G=="string"&&(G=new RegExp(G)),this.formats[N]=G,this}errorsText(N=this.errors,{separator:G=", ",dataVar:V="data"}={}){return!N||N.length===0?"No errors":N.map(I=>`${V}${I.instancePath} ${I.message}`).reduce((I,z)=>I+G+z)}$dataMetaSchema(N,G){const V=this.RULES.all;N=JSON.parse(JSON.stringify(N));for(const I of G){const z=I.split("/").slice(1);let J=N;for(const pe of z)J=J[pe];for(const pe in V){const he=V[pe];if(typeof he!="object")continue;const{$data:_e}=he.definition,$e=J[pe];_e&&$e&&(J[pe]=le($e))}}return N}_removeAllSchemas(N,G){for(const V in N){const I=N[V];(!G||G.test(V))&&(typeof I=="string"?delete N[V]:I&&!I.meta&&(this._cache.delete(I.schema),delete N[V]))}}_addSchema(N,G,V,I=this.opts.validateSchema,z=this.opts.addUsedSchema){let J;const{schemaId:pe}=this.opts;if(typeof N=="object")J=N[pe];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof N!="boolean")throw new Error("schema must be object or boolean")}let he=this._cache.get(N);if(he!==void 0)return he;V=(0,u.normalizeId)(J||V);const _e=u.getSchemaRefs.call(this,N,V);return he=new l.SchemaEnv({schema:N,schemaId:pe,meta:G,baseId:V,localRefs:_e}),this._cache.set(he.schema,he),z&&!V.startsWith("#")&&(V&&this._checkUnique(V),this.refs[V]=he),I&&this.validateSchema(N,!0),he}_checkUnique(N){if(this.schemas[N]||this.refs[N])throw new Error(`schema with key or id "${N}" already exists`)}_compileSchemaEnv(N){if(N.meta?this._compileMetaSchema(N):l.compileSchema.call(this,N),!N.validate)throw new Error("ajv implementation error");return N.validate}_compileMetaSchema(N){const G=this.opts;this.opts=this._metaOpts;try{l.compileSchema.call(this,N)}finally{this.opts=G}}}C.ValidationError=a.default,C.MissingRefError=n.default,e.default=C;function E(Q,N,G,V="error"){for(const I in Q){const z=I;z in N&&this.logger[V](`${G}: option ${I}. ${Q[z]}`)}}function R(Q){return Q=(0,u.normalizeId)(Q),this.schemas[Q]||this.refs[Q]}function D(){const Q=this.opts.schemas;if(Q)if(Array.isArray(Q))this.addSchema(Q);else for(const N in Q)this.addSchema(Q[N],N)}function O(){for(const Q in this.opts.formats){const N=this.opts.formats[Q];N&&this.addFormat(Q,N)}}function L(Q){if(Array.isArray(Q)){this.addVocabulary(Q);return}this.logger.warn("keywords option as map is deprecated, pass array");for(const N in Q){const G=Q[N];G.keyword||(G.keyword=N),this.addKeyword(G)}}function $(){const Q={...this.opts};for(const N of b)delete Q[N];return Q}const B={log(){},warn(){},error(){}};function U(Q){if(Q===!1)return B;if(Q===void 0)return console;if(Q.log&&Q.warn&&Q.error)return Q;throw new Error("logger must implement log, warn and error methods")}const j=/^[a-z_$][a-z0-9_$:-]*$/i;function W(Q,N){const{RULES:G}=this;if((0,m.eachItem)(Q,V=>{if(G.keywords[V])throw new Error(`Keyword ${V} is already defined`);if(!j.test(V))throw new Error(`Keyword ${V} has invalid name`)}),!!N&&N.$data&&!("code"in N||"validate"in N))throw new Error('$data keyword must have "code" or "validate" function')}function ne(Q,N,G){var V;const I=N?.post;if(G&&I)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:z}=this;let J=I?z.post:z.rules.find(({type:he})=>he===G);if(J||(J={type:G,rules:[]},z.rules.push(J)),z.keywords[Q]=!0,!N)return;const pe={keyword:Q,definition:{...N,type:(0,p.getJSONTypes)(N.type),schemaType:(0,p.getJSONTypes)(N.schemaType)}};N.before?H.call(this,J,pe,N.before):J.rules.push(pe),z.all[Q]=pe,(V=N.implements)===null||V===void 0||V.forEach(he=>this.addKeyword(he))}function H(Q,N,G){const V=Q.rules.findIndex(I=>I.keyword===G);V>=0?Q.rules.splice(V,0,N):(Q.rules.push(N),this.logger.warn(`rule ${G} is not defined`))}function Z(Q){let{metaSchema:N}=Q;N!==void 0&&(Q.$data&&this.opts.$data&&(N=le(N)),Q.validateSchema=this.compile(N,!0))}const te={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function le(Q){return{anyOf:[Q,te]}}})(jS)),jS}var zh={},Uh={},$h={},dR;function _K(){if(dR)return $h;dR=1,Object.defineProperty($h,"__esModule",{value:!0});const e={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};return $h.default=e,$h}var cs={},uR;function kK(){if(uR)return cs;uR=1,Object.defineProperty(cs,"__esModule",{value:!0}),cs.callRef=cs.getValidate=void 0;const e=Ov(),t=kr(),o=yt(),a=js(),n=a_(),i=Lt(),l={keyword:"$ref",schemaType:"string",code(p){const{gen:m,schema:h,it:f}=p,{baseId:v,schemaEnv:b,validateName:S,opts:_,self:T}=f,{root:x}=b;if((h==="#"||h==="#/")&&v===x.baseId)return C();const P=n.resolveRef.call(T,x,v,h);if(P===void 0)throw new e.default(f.opts.uriResolver,v,h);if(P instanceof n.SchemaEnv)return E(P);return R(P);function C(){if(b===x)return u(p,S,b,b.$async);const D=m.scopeValue("root",{ref:x});return u(p,(0,o._)`${D}.validate`,x,x.$async)}function E(D){const O=c(p,D);u(p,O,D,D.$async)}function R(D){const O=m.scopeValue("schema",_.code.source===!0?{ref:D,code:(0,o.stringify)(D)}:{ref:D}),L=m.name("valid"),$=p.subschema({schema:D,dataTypes:[],schemaPath:o.nil,topSchemaRef:O,errSchemaPath:h},L);p.mergeEvaluated($),p.ok(L)}}};function c(p,m){const{gen:h}=p;return m.validate?h.scopeValue("validate",{ref:m.validate}):(0,o._)`${h.scopeValue("wrapper",{ref:m})}.validate`}cs.getValidate=c;function u(p,m,h,f){const{gen:v,it:b}=p,{allErrors:S,schemaEnv:_,opts:T}=b,x=T.passContext?a.default.this:o.nil;f?P():C();function P(){if(!_.$async)throw new Error("async schema referenced by sync schema");const D=v.let("valid");v.try(()=>{v.code((0,o._)`await ${(0,t.callValidateCode)(p,m,x)}`),R(m),S||v.assign(D,!0)},O=>{v.if((0,o._)`!(${O} instanceof ${b.ValidationError})`,()=>v.throw(O)),E(O),S||v.assign(D,!1)}),p.ok(D)}function C(){p.result((0,t.callValidateCode)(p,m,x),()=>R(m),()=>E(m))}function E(D){const O=(0,o._)`${D}.errors`;v.assign(a.default.vErrors,(0,o._)`${a.default.vErrors} === null ? ${O} : ${a.default.vErrors}.concat(${O})`),v.assign(a.default.errors,(0,o._)`${a.default.vErrors}.length`)}function R(D){var O;if(!b.opts.unevaluated)return;const L=(O=h?.validate)===null||O===void 0?void 0:O.evaluated;if(b.props!==!0)if(L&&!L.dynamicProps)L.props!==void 0&&(b.props=i.mergeEvaluated.props(v,L.props,b.props));else{const $=v.var("props",(0,o._)`${D}.evaluated.props`);b.props=i.mergeEvaluated.props(v,$,b.props,o.Name)}if(b.items!==!0)if(L&&!L.dynamicItems)L.items!==void 0&&(b.items=i.mergeEvaluated.items(v,L.items,b.items));else{const $=v.var("items",(0,o._)`${D}.evaluated.items`);b.items=i.mergeEvaluated.items(v,$,b.items,o.Name)}}}return cs.callRef=u,cs.default=l,cs}var pR;function CK(){if(pR)return Uh;pR=1,Object.defineProperty(Uh,"__esModule",{value:!0});const e=_K(),t=kK(),o=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",e.default,t.default];return Uh.default=o,Uh}var qh={},Vh={},mR;function EK(){if(mR)return Vh;mR=1,Object.defineProperty(Vh,"__esModule",{value:!0});const e=yt(),t=e.operators,o={maximum:{okStr:"<=",ok:t.LTE,fail:t.GT},minimum:{okStr:">=",ok:t.GTE,fail:t.LT},exclusiveMaximum:{okStr:"<",ok:t.LT,fail:t.GTE},exclusiveMinimum:{okStr:">",ok:t.GT,fail:t.LTE}},a={message:({keyword:i,schemaCode:l})=>(0,e.str)`must be ${o[i].okStr} ${l}`,params:({keyword:i,schemaCode:l})=>(0,e._)`{comparison: ${o[i].okStr}, limit: ${l}}`},n={keyword:Object.keys(o),type:"number",schemaType:"number",$data:!0,error:a,code(i){const{keyword:l,data:c,schemaCode:u}=i;i.fail$data((0,e._)`${c} ${o[l].fail} ${u} || isNaN(${c})`)}};return Vh.default=n,Vh}var Hh={},hR;function PK(){if(hR)return Hh;hR=1,Object.defineProperty(Hh,"__esModule",{value:!0});const e=yt(),o={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:{message:({schemaCode:a})=>(0,e.str)`must be multiple of ${a}`,params:({schemaCode:a})=>(0,e._)`{multipleOf: ${a}}`},code(a){const{gen:n,data:i,schemaCode:l,it:c}=a,u=c.opts.multipleOfPrecision,p=n.let("res"),m=u?(0,e._)`Math.abs(Math.round(${p}) - ${p}) > 1e-${u}`:(0,e._)`${p} !== parseInt(${p})`;a.fail$data((0,e._)`(${l} === 0 || (${p} = ${i}/${l}, ${m}))`)}};return Hh.default=o,Hh}var Gh={},Wh={},gR;function AK(){if(gR)return Wh;gR=1,Object.defineProperty(Wh,"__esModule",{value:!0});function e(t){const o=t.length;let a=0,n=0,i;for(;n<o;)a++,i=t.charCodeAt(n++),i>=55296&&i<=56319&&n<o&&(i=t.charCodeAt(n),(i&64512)===56320&&n++);return a}return Wh.default=e,e.code='require("ajv/dist/runtime/ucs2length").default',Wh}var fR;function RK(){if(fR)return Gh;fR=1,Object.defineProperty(Gh,"__esModule",{value:!0});const e=yt(),t=Lt(),o=AK(),n={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:{message({keyword:i,schemaCode:l}){const c=i==="maxLength"?"more":"fewer";return(0,e.str)`must NOT have ${c} than ${l} characters`},params:({schemaCode:i})=>(0,e._)`{limit: ${i}}`},code(i){const{keyword:l,data:c,schemaCode:u,it:p}=i,m=l==="maxLength"?e.operators.GT:e.operators.LT,h=p.opts.unicode===!1?(0,e._)`${c}.length`:(0,e._)`${(0,t.useFunc)(i.gen,o.default)}(${c})`;i.fail$data((0,e._)`${h} ${m} ${u}`)}};return Gh.default=n,Gh}var Kh={},vR;function DK(){if(vR)return Kh;vR=1,Object.defineProperty(Kh,"__esModule",{value:!0});const e=kr(),t=Lt(),o=yt(),n={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:{message:({schemaCode:i})=>(0,o.str)`must match pattern "${i}"`,params:({schemaCode:i})=>(0,o._)`{pattern: ${i}}`},code(i){const{gen:l,data:c,$data:u,schema:p,schemaCode:m,it:h}=i,f=h.opts.unicodeRegExp?"u":"";if(u){const{regExp:v}=h.opts.code,b=v.code==="new RegExp"?(0,o._)`new RegExp`:(0,t.useFunc)(l,v),S=l.let("valid");l.try(()=>l.assign(S,(0,o._)`${b}(${m}, ${f}).test(${c})`),()=>l.assign(S,!1)),i.fail$data((0,o._)`!${S}`)}else{const v=(0,e.usePattern)(i,p);i.fail$data((0,o._)`!${v}.test(${c})`)}}};return Kh.default=n,Kh}var Yh={},bR;function OK(){if(bR)return Yh;bR=1,Object.defineProperty(Yh,"__esModule",{value:!0});const e=yt(),o={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:{message({keyword:a,schemaCode:n}){const i=a==="maxProperties"?"more":"fewer";return(0,e.str)`must NOT have ${i} than ${n} properties`},params:({schemaCode:a})=>(0,e._)`{limit: ${a}}`},code(a){const{keyword:n,data:i,schemaCode:l}=a,c=n==="maxProperties"?e.operators.GT:e.operators.LT;a.fail$data((0,e._)`Object.keys(${i}).length ${c} ${l}`)}};return Yh.default=o,Yh}var Zh={},yR;function MK(){if(yR)return Zh;yR=1,Object.defineProperty(Zh,"__esModule",{value:!0});const e=kr(),t=yt(),o=Lt(),n={keyword:"required",type:"object",schemaType:"array",$data:!0,error:{message:({params:{missingProperty:i}})=>(0,t.str)`must have required property '${i}'`,params:({params:{missingProperty:i}})=>(0,t._)`{missingProperty: ${i}}`},code(i){const{gen:l,schema:c,schemaCode:u,data:p,$data:m,it:h}=i,{opts:f}=h;if(!m&&c.length===0)return;const v=c.length>=f.loopRequired;if(h.allErrors?b():S(),f.strictRequired){const x=i.parentSchema.properties,{definedProperties:P}=i.it;for(const C of c)if(x?.[C]===void 0&&!P.has(C)){const E=h.schemaEnv.baseId+h.errSchemaPath,R=`required property "${C}" is not defined at "${E}" (strictRequired)`;(0,o.checkStrictMode)(h,R,h.opts.strictRequired)}}function b(){if(v||m)i.block$data(t.nil,_);else for(const x of c)(0,e.checkReportMissingProp)(i,x)}function S(){const x=l.let("missing");if(v||m){const P=l.let("valid",!0);i.block$data(P,()=>T(x,P)),i.ok(P)}else l.if((0,e.checkMissingProp)(i,c,x)),(0,e.reportMissingProp)(i,x),l.else()}function _(){l.forOf("prop",u,x=>{i.setParams({missingProperty:x}),l.if((0,e.noPropertyInData)(l,p,x,f.ownProperties),()=>i.error())})}function T(x,P){i.setParams({missingProperty:x}),l.forOf(x,u,()=>{l.assign(P,(0,e.propertyInData)(l,p,x,f.ownProperties)),l.if((0,t.not)(P),()=>{i.error(),l.break()})},t.nil)}}};return Zh.default=n,Zh}var Qh={},SR;function NK(){if(SR)return Qh;SR=1,Object.defineProperty(Qh,"__esModule",{value:!0});const e=yt(),o={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:{message({keyword:a,schemaCode:n}){const i=a==="maxItems"?"more":"fewer";return(0,e.str)`must NOT have ${i} than ${n} items`},params:({schemaCode:a})=>(0,e._)`{limit: ${a}}`},code(a){const{keyword:n,data:i,schemaCode:l}=a,c=n==="maxItems"?e.operators.GT:e.operators.LT;a.fail$data((0,e._)`${i}.length ${c} ${l}`)}};return Qh.default=o,Qh}var Jh={},Xh={},wR;function n_(){if(wR)return Xh;wR=1,Object.defineProperty(Xh,"__esModule",{value:!0});const e=LI();return e.code='require("ajv/dist/runtime/equal").default',Xh.default=e,Xh}var TR;function IK(){if(TR)return Jh;TR=1,Object.defineProperty(Jh,"__esModule",{value:!0});const e=Ef(),t=yt(),o=Lt(),a=n_(),i={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:{message:({params:{i:l,j:c}})=>(0,t.str)`must NOT have duplicate items (items ## ${c} and ${l} are identical)`,params:({params:{i:l,j:c}})=>(0,t._)`{i: ${l}, j: ${c}}`},code(l){const{gen:c,data:u,$data:p,schema:m,parentSchema:h,schemaCode:f,it:v}=l;if(!p&&!m)return;const b=c.let("valid"),S=h.items?(0,e.getSchemaTypes)(h.items):[];l.block$data(b,_,(0,t._)`${f} === false`),l.ok(b);function _(){const C=c.let("i",(0,t._)`${u}.length`),E=c.let("j");l.setParams({i:C,j:E}),c.assign(b,!0),c.if((0,t._)`${C} > 1`,()=>(T()?x:P)(C,E))}function T(){return S.length>0&&!S.some(C=>C==="object"||C==="array")}function x(C,E){const R=c.name("item"),D=(0,e.checkDataTypes)(S,R,v.opts.strictNumbers,e.DataType.Wrong),O=c.const("indices",(0,t._)`{}`);c.for((0,t._)`;${C}--;`,()=>{c.let(R,(0,t._)`${u}[${C}]`),c.if(D,(0,t._)`continue`),S.length>1&&c.if((0,t._)`typeof ${R} == "string"`,(0,t._)`${R} += "_"`),c.if((0,t._)`typeof ${O}[${R}] == "number"`,()=>{c.assign(E,(0,t._)`${O}[${R}]`),l.error(),c.assign(b,!1).break()}).code((0,t._)`${O}[${R}] = ${C}`)})}function P(C,E){const R=(0,o.useFunc)(c,a.default),D=c.name("outer");c.label(D).for((0,t._)`;${C}--;`,()=>c.for((0,t._)`${E} = ${C}; ${E}--;`,()=>c.if((0,t._)`${R}(${u}[${C}], ${u}[${E}])`,()=>{l.error(),c.assign(b,!1).break(D)})))}}};return Jh.default=i,Jh}var eg={},xR;function LK(){if(xR)return eg;xR=1,Object.defineProperty(eg,"__esModule",{value:!0});const e=yt(),t=Lt(),o=n_(),n={keyword:"const",$data:!0,error:{message:"must be equal to constant",params:({schemaCode:i})=>(0,e._)`{allowedValue: ${i}}`},code(i){const{gen:l,data:c,$data:u,schemaCode:p,schema:m}=i;u||m&&typeof m=="object"?i.fail$data((0,e._)`!${(0,t.useFunc)(l,o.default)}(${c}, ${p})`):i.fail((0,e._)`${m} !== ${c}`)}};return eg.default=n,eg}var tg={},_R;function BK(){if(_R)return tg;_R=1,Object.defineProperty(tg,"__esModule",{value:!0});const e=yt(),t=Lt(),o=n_(),n={keyword:"enum",schemaType:"array",$data:!0,error:{message:"must be equal to one of the allowed values",params:({schemaCode:i})=>(0,e._)`{allowedValues: ${i}}`},code(i){const{gen:l,data:c,$data:u,schema:p,schemaCode:m,it:h}=i;if(!u&&p.length===0)throw new Error("enum must have non-empty array");const f=p.length>=h.opts.loopEnum;let v;const b=()=>v??(v=(0,t.useFunc)(l,o.default));let S;if(f||u)S=l.let("valid"),i.block$data(S,_);else{if(!Array.isArray(p))throw new Error("ajv implementation error");const x=l.const("vSchema",m);S=(0,e.or)(...p.map((P,C)=>T(x,C)))}i.pass(S);function _(){l.assign(S,!1),l.forOf("v",m,x=>l.if((0,e._)`${b()}(${c}, ${x})`,()=>l.assign(S,!0).break()))}function T(x,P){const C=p[P];return typeof C=="object"&&C!==null?(0,e._)`${b()}(${c}, ${x}[${P}])`:(0,e._)`${c} === ${C}`}}};return tg.default=n,tg}var kR;function FK(){if(kR)return qh;kR=1,Object.defineProperty(qh,"__esModule",{value:!0});const e=EK(),t=PK(),o=RK(),a=DK(),n=OK(),i=MK(),l=NK(),c=IK(),u=LK(),p=BK(),m=[e.default,t.default,o.default,a.default,n.default,i.default,l.default,c.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},u.default,p.default];return qh.default=m,qh}var og={},Pc={},CR;function FI(){if(CR)return Pc;CR=1,Object.defineProperty(Pc,"__esModule",{value:!0}),Pc.validateAdditionalItems=void 0;const e=yt(),t=Lt(),a={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:{message:({params:{len:i}})=>(0,e.str)`must NOT have more than ${i} items`,params:({params:{len:i}})=>(0,e._)`{limit: ${i}}`},code(i){const{parentSchema:l,it:c}=i,{items:u}=l;if(!Array.isArray(u)){(0,t.checkStrictMode)(c,'"additionalItems" is ignored when "items" is not an array of schemas');return}n(i,u)}};function n(i,l){const{gen:c,schema:u,data:p,keyword:m,it:h}=i;h.items=!0;const f=c.const("len",(0,e._)`${p}.length`);if(u===!1)i.setParams({len:l.length}),i.pass((0,e._)`${f} <= ${l.length}`);else if(typeof u=="object"&&!(0,t.alwaysValidSchema)(h,u)){const b=c.var("valid",(0,e._)`${f} <= ${l.length}`);c.if((0,e.not)(b),()=>v(b)),i.ok(b)}function v(b){c.forRange("i",l.length,f,S=>{i.subschema({keyword:m,dataProp:S,dataPropType:t.Type.Num},b),h.allErrors||c.if((0,e.not)(b),()=>c.break())})}}return Pc.validateAdditionalItems=n,Pc.default=a,Pc}var ag={},Ac={},ER;function jI(){if(ER)return Ac;ER=1,Object.defineProperty(Ac,"__esModule",{value:!0}),Ac.validateTuple=void 0;const e=yt(),t=Lt(),o=kr(),a={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(i){const{schema:l,it:c}=i;if(Array.isArray(l))return n(i,"additionalItems",l);c.items=!0,!(0,t.alwaysValidSchema)(c,l)&&i.ok((0,o.validateArray)(i))}};function n(i,l,c=i.schema){const{gen:u,parentSchema:p,data:m,keyword:h,it:f}=i;S(p),f.opts.unevaluated&&c.length&&f.items!==!0&&(f.items=t.mergeEvaluated.items(u,c.length,f.items));const v=u.name("valid"),b=u.const("len",(0,e._)`${m}.length`);c.forEach((_,T)=>{(0,t.alwaysValidSchema)(f,_)||(u.if((0,e._)`${b} > ${T}`,()=>i.subschema({keyword:h,schemaProp:T,dataProp:T},v)),i.ok(v))});function S(_){const{opts:T,errSchemaPath:x}=f,P=c.length,C=P===_.minItems&&(P===_.maxItems||_[l]===!1);if(T.strictTuples&&!C){const E=`"${h}" is ${P}-tuple, but minItems or maxItems/${l} are not specified or different at path "${x}"`;(0,t.checkStrictMode)(f,E,T.strictTuples)}}}return Ac.validateTuple=n,Ac.default=a,Ac}var PR;function jK(){if(PR)return ag;PR=1,Object.defineProperty(ag,"__esModule",{value:!0});const e=jI(),t={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:o=>(0,e.validateTuple)(o,"items")};return ag.default=t,ag}var ng={},AR;function zK(){if(AR)return ng;AR=1,Object.defineProperty(ng,"__esModule",{value:!0});const e=yt(),t=Lt(),o=kr(),a=FI(),i={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:{message:({params:{len:l}})=>(0,e.str)`must NOT have more than ${l} items`,params:({params:{len:l}})=>(0,e._)`{limit: ${l}}`},code(l){const{schema:c,parentSchema:u,it:p}=l,{prefixItems:m}=u;p.items=!0,!(0,t.alwaysValidSchema)(p,c)&&(m?(0,a.validateAdditionalItems)(l,m):l.ok((0,o.validateArray)(l)))}};return ng.default=i,ng}var rg={},RR;function UK(){if(RR)return rg;RR=1,Object.defineProperty(rg,"__esModule",{value:!0});const e=yt(),t=Lt(),a={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:{message:({params:{min:n,max:i}})=>i===void 0?(0,e.str)`must contain at least ${n} valid item(s)`:(0,e.str)`must contain at least ${n} and no more than ${i} valid item(s)`,params:({params:{min:n,max:i}})=>i===void 0?(0,e._)`{minContains: ${n}}`:(0,e._)`{minContains: ${n}, maxContains: ${i}}`},code(n){const{gen:i,schema:l,parentSchema:c,data:u,it:p}=n;let m,h;const{minContains:f,maxContains:v}=c;p.opts.next?(m=f===void 0?1:f,h=v):m=1;const b=i.const("len",(0,e._)`${u}.length`);if(n.setParams({min:m,max:h}),h===void 0&&m===0){(0,t.checkStrictMode)(p,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(h!==void 0&&m>h){(0,t.checkStrictMode)(p,'"minContains" > "maxContains" is always invalid'),n.fail();return}if((0,t.alwaysValidSchema)(p,l)){let P=(0,e._)`${b} >= ${m}`;h!==void 0&&(P=(0,e._)`${P} && ${b} <= ${h}`),n.pass(P);return}p.items=!0;const S=i.name("valid");h===void 0&&m===1?T(S,()=>i.if(S,()=>i.break())):m===0?(i.let(S,!0),h!==void 0&&i.if((0,e._)`${u}.length > 0`,_)):(i.let(S,!1),_()),n.result(S,()=>n.reset());function _(){const P=i.name("_valid"),C=i.let("count",0);T(P,()=>i.if(P,()=>x(C)))}function T(P,C){i.forRange("i",0,b,E=>{n.subschema({keyword:"contains",dataProp:E,dataPropType:t.Type.Num,compositeRule:!0},P),C()})}function x(P){i.code((0,e._)`${P}++`),h===void 0?i.if((0,e._)`${P} >= ${m}`,()=>i.assign(S,!0).break()):(i.if((0,e._)`${P} > ${h}`,()=>i.assign(S,!1).break()),m===1?i.assign(S,!0):i.if((0,e._)`${P} >= ${m}`,()=>i.assign(S,!0)))}}};return rg.default=a,rg}var KS={},DR;function $K(){return DR||(DR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.validateSchemaDeps=e.validatePropertyDeps=e.error=void 0;const t=yt(),o=Lt(),a=kr();e.error={message:({params:{property:u,depsCount:p,deps:m}})=>{const h=p===1?"property":"properties";return(0,t.str)`must have ${h} ${m} when property ${u} is present`},params:({params:{property:u,depsCount:p,deps:m,missingProperty:h}})=>(0,t._)`{property: ${u},
53
53
  missingProperty: ${h},
54
54
  depsCount: ${p},
55
- deps: ${m}}`};const n={keyword:"dependencies",type:"object",schemaType:"object",error:e.error,code(u){const[p,m]=i(u);l(u,p),c(u,m)}};function i({schema:u}){const p={},m={};for(const h in u){if(h==="__proto__")continue;const f=Array.isArray(u[h])?p:m;f[h]=u[h]}return[p,m]}function l(u,p=u.schema){const{gen:m,data:h,it:f}=u;if(Object.keys(p).length===0)return;const v=m.let("missing");for(const b in p){const S=p[b];if(S.length===0)continue;const _=(0,a.propertyInData)(m,h,b,f.opts.ownProperties);u.setParams({property:b,depsCount:S.length,deps:S.join(", ")}),f.allErrors?m.if(_,()=>{for(const T of S)(0,a.checkReportMissingProp)(u,T)}):(m.if((0,t._)`${_} && (${(0,a.checkMissingProp)(u,S,v)})`),(0,a.reportMissingProp)(u,v),m.else())}}e.validatePropertyDeps=l;function c(u,p=u.schema){const{gen:m,data:h,keyword:f,it:v}=u,b=m.name("valid");for(const S in p)(0,o.alwaysValidSchema)(v,p[S])||(m.if((0,a.propertyInData)(m,h,S,v.opts.ownProperties),()=>{const _=u.subschema({keyword:f,schemaProp:S},b);u.mergeValidEvaluated(_,b)},()=>m.var(b,!0)),u.ok(b))}e.validateSchemaDeps=c,e.default=n})(KS)),KS}var ig={},OR;function qK(){if(OR)return ig;OR=1,Object.defineProperty(ig,"__esModule",{value:!0});const e=yt(),t=Lt(),a={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:{message:"property name must be valid",params:({params:n})=>(0,e._)`{propertyName: ${n.propertyName}}`},code(n){const{gen:i,schema:l,data:c,it:u}=n;if((0,t.alwaysValidSchema)(u,l))return;const p=i.name("valid");i.forIn("key",c,m=>{n.setParams({propertyName:m}),n.subschema({keyword:"propertyNames",data:m,dataTypes:["string"],propertyName:m,compositeRule:!0},p),i.if((0,e.not)(p),()=>{n.error(!0),u.allErrors||i.break()})}),n.ok(p)}};return ig.default=a,ig}var sg={},MR;function zI(){if(MR)return sg;MR=1,Object.defineProperty(sg,"__esModule",{value:!0});const e=kr(),t=yt(),o=js(),a=Lt(),i={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:{message:"must NOT have additional properties",params:({params:l})=>(0,t._)`{additionalProperty: ${l.additionalProperty}}`},code(l){const{gen:c,schema:u,parentSchema:p,data:m,errsCount:h,it:f}=l;if(!h)throw new Error("ajv implementation error");const{allErrors:v,opts:b}=f;if(f.props=!0,b.removeAdditional!=="all"&&(0,a.alwaysValidSchema)(f,u))return;const S=(0,e.allSchemaProperties)(p.properties),_=(0,e.allSchemaProperties)(p.patternProperties);T(),l.ok((0,t._)`${h} === ${o.default.errors}`);function T(){c.forIn("key",m,R=>{!S.length&&!_.length?C(R):c.if(x(R),()=>C(R))})}function x(R){let D;if(S.length>8){const O=(0,a.schemaRefOrVal)(f,p.properties,"properties");D=(0,e.isOwnProperty)(c,O,R)}else S.length?D=(0,t.or)(...S.map(O=>(0,t._)`${R} === ${O}`)):D=t.nil;return _.length&&(D=(0,t.or)(D,..._.map(O=>(0,t._)`${(0,e.usePattern)(l,O)}.test(${R})`))),(0,t.not)(D)}function P(R){c.code((0,t._)`delete ${m}[${R}]`)}function C(R){if(b.removeAdditional==="all"||b.removeAdditional&&u===!1){P(R);return}if(u===!1){l.setParams({additionalProperty:R}),l.error(),v||c.break();return}if(typeof u=="object"&&!(0,a.alwaysValidSchema)(f,u)){const D=c.name("valid");b.removeAdditional==="failing"?(E(R,D,!1),c.if((0,t.not)(D),()=>{l.reset(),P(R)})):(E(R,D),v||c.if((0,t.not)(D),()=>c.break()))}}function E(R,D,O){const L={keyword:"additionalProperties",dataProp:R,dataPropType:a.Type.Str};O===!1&&Object.assign(L,{compositeRule:!0,createErrors:!1,allErrors:!1}),l.subschema(L,D)}}};return sg.default=i,sg}var lg={},NR;function VK(){if(NR)return lg;NR=1,Object.defineProperty(lg,"__esModule",{value:!0});const e=Dv(),t=kr(),o=Lt(),a=zI(),n={keyword:"properties",type:"object",schemaType:"object",code(i){const{gen:l,schema:c,parentSchema:u,data:p,it:m}=i;m.opts.removeAdditional==="all"&&u.additionalProperties===void 0&&a.default.code(new e.KeywordCxt(m,a.default,"additionalProperties"));const h=(0,t.allSchemaProperties)(c);for(const _ of h)m.definedProperties.add(_);m.opts.unevaluated&&h.length&&m.props!==!0&&(m.props=o.mergeEvaluated.props(l,(0,o.toHash)(h),m.props));const f=h.filter(_=>!(0,o.alwaysValidSchema)(m,c[_]));if(f.length===0)return;const v=l.name("valid");for(const _ of f)b(_)?S(_):(l.if((0,t.propertyInData)(l,p,_,m.opts.ownProperties)),S(_),m.allErrors||l.else().var(v,!0),l.endIf()),i.it.definedProperties.add(_),i.ok(v);function b(_){return m.opts.useDefaults&&!m.compositeRule&&c[_].default!==void 0}function S(_){i.subschema({keyword:"properties",schemaProp:_,dataProp:_},v)}}};return lg.default=n,lg}var cg={},IR;function HK(){if(IR)return cg;IR=1,Object.defineProperty(cg,"__esModule",{value:!0});const e=kr(),t=yt(),o=Lt(),a=Lt(),n={keyword:"patternProperties",type:"object",schemaType:"object",code(i){const{gen:l,schema:c,data:u,parentSchema:p,it:m}=i,{opts:h}=m,f=(0,e.allSchemaProperties)(c),v=f.filter(C=>(0,o.alwaysValidSchema)(m,c[C]));if(f.length===0||v.length===f.length&&(!m.opts.unevaluated||m.props===!0))return;const b=h.strictSchema&&!h.allowMatchingProperties&&p.properties,S=l.name("valid");m.props!==!0&&!(m.props instanceof t.Name)&&(m.props=(0,a.evaluatedPropsToName)(l,m.props));const{props:_}=m;T();function T(){for(const C of f)b&&x(C),m.allErrors?P(C):(l.var(S,!0),P(C),l.if(S))}function x(C){for(const E in b)new RegExp(C).test(E)&&(0,o.checkStrictMode)(m,`property ${E} matches pattern ${C} (use allowMatchingProperties)`)}function P(C){l.forIn("key",u,E=>{l.if((0,t._)`${(0,e.usePattern)(i,C)}.test(${E})`,()=>{const R=v.includes(C);R||i.subschema({keyword:"patternProperties",schemaProp:C,dataProp:E,dataPropType:a.Type.Str},S),m.opts.unevaluated&&_!==!0?l.assign((0,t._)`${_}[${E}]`,!0):!R&&!m.allErrors&&l.if((0,t.not)(S),()=>l.break())})})}}};return cg.default=n,cg}var dg={},LR;function GK(){if(LR)return dg;LR=1,Object.defineProperty(dg,"__esModule",{value:!0});const e=Lt(),t={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(o){const{gen:a,schema:n,it:i}=o;if((0,e.alwaysValidSchema)(i,n)){o.fail();return}const l=a.name("valid");o.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},l),o.failResult(l,()=>o.reset(),()=>o.error())},error:{message:"must NOT be valid"}};return dg.default=t,dg}var ug={},BR;function WK(){if(BR)return ug;BR=1,Object.defineProperty(ug,"__esModule",{value:!0});const t={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:kr().validateUnion,error:{message:"must match a schema in anyOf"}};return ug.default=t,ug}var pg={},FR;function KK(){if(FR)return pg;FR=1,Object.defineProperty(pg,"__esModule",{value:!0});const e=yt(),t=Lt(),a={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:{message:"must match exactly one schema in oneOf",params:({params:n})=>(0,e._)`{passingSchemas: ${n.passing}}`},code(n){const{gen:i,schema:l,parentSchema:c,it:u}=n;if(!Array.isArray(l))throw new Error("ajv implementation error");if(u.opts.discriminator&&c.discriminator)return;const p=l,m=i.let("valid",!1),h=i.let("passing",null),f=i.name("_valid");n.setParams({passing:h}),i.block(v),n.result(m,()=>n.reset(),()=>n.error(!0));function v(){p.forEach((b,S)=>{let _;(0,t.alwaysValidSchema)(u,b)?i.var(f,!0):_=n.subschema({keyword:"oneOf",schemaProp:S,compositeRule:!0},f),S>0&&i.if((0,e._)`${f} && ${m}`).assign(m,!1).assign(h,(0,e._)`[${h}, ${S}]`).else(),i.if(f,()=>{i.assign(m,!0),i.assign(h,S),_&&n.mergeEvaluated(_,e.Name)})})}}};return pg.default=a,pg}var mg={},jR;function YK(){if(jR)return mg;jR=1,Object.defineProperty(mg,"__esModule",{value:!0});const e=Lt(),t={keyword:"allOf",schemaType:"array",code(o){const{gen:a,schema:n,it:i}=o;if(!Array.isArray(n))throw new Error("ajv implementation error");const l=a.name("valid");n.forEach((c,u)=>{if((0,e.alwaysValidSchema)(i,c))return;const p=o.subschema({keyword:"allOf",schemaProp:u},l);o.ok(l),o.mergeEvaluated(p)})}};return mg.default=t,mg}var hg={},zR;function ZK(){if(zR)return hg;zR=1,Object.defineProperty(hg,"__esModule",{value:!0});const e=yt(),t=Lt(),a={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:{message:({params:i})=>(0,e.str)`must match "${i.ifClause}" schema`,params:({params:i})=>(0,e._)`{failingKeyword: ${i.ifClause}}`},code(i){const{gen:l,parentSchema:c,it:u}=i;c.then===void 0&&c.else===void 0&&(0,t.checkStrictMode)(u,'"if" without "then" and "else" is ignored');const p=n(u,"then"),m=n(u,"else");if(!p&&!m)return;const h=l.let("valid",!0),f=l.name("_valid");if(v(),i.reset(),p&&m){const S=l.let("ifClause");i.setParams({ifClause:S}),l.if(f,b("then",S),b("else",S))}else p?l.if(f,b("then")):l.if((0,e.not)(f),b("else"));i.pass(h,()=>i.error(!0));function v(){const S=i.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},f);i.mergeEvaluated(S)}function b(S,_){return()=>{const T=i.subschema({keyword:S},f);l.assign(h,f),i.mergeValidEvaluated(T,h),_?l.assign(_,(0,e._)`${S}`):i.setParams({ifClause:S})}}}};function n(i,l){const c=i.schema[l];return c!==void 0&&!(0,t.alwaysValidSchema)(i,c)}return hg.default=a,hg}var gg={},UR;function QK(){if(UR)return gg;UR=1,Object.defineProperty(gg,"__esModule",{value:!0});const e=Lt(),t={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:o,parentSchema:a,it:n}){a.if===void 0&&(0,e.checkStrictMode)(n,`"${o}" without "if" is ignored`)}};return gg.default=t,gg}var $R;function JK(){if($R)return og;$R=1,Object.defineProperty(og,"__esModule",{value:!0});const e=FI(),t=jK(),o=jI(),a=zK(),n=UK(),i=$K(),l=qK(),c=zI(),u=VK(),p=HK(),m=GK(),h=WK(),f=KK(),v=YK(),b=ZK(),S=QK();function _(T=!1){const x=[m.default,h.default,f.default,v.default,b.default,S.default,l.default,c.default,i.default,u.default,p.default];return T?x.push(t.default,a.default):x.push(e.default,o.default),x.push(n.default),x}return og.default=_,og}var fg={},vg={},qR;function XK(){if(qR)return vg;qR=1,Object.defineProperty(vg,"__esModule",{value:!0});const e=yt(),o={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:{message:({schemaCode:a})=>(0,e.str)`must match format "${a}"`,params:({schemaCode:a})=>(0,e._)`{format: ${a}}`},code(a,n){const{gen:i,data:l,$data:c,schema:u,schemaCode:p,it:m}=a,{opts:h,errSchemaPath:f,schemaEnv:v,self:b}=m;if(!h.validateFormats)return;c?S():_();function S(){const T=i.scopeValue("formats",{ref:b.formats,code:h.code.formats}),x=i.const("fDef",(0,e._)`${T}[${p}]`),P=i.let("fType"),C=i.let("format");i.if((0,e._)`typeof ${x} == "object" && !(${x} instanceof RegExp)`,()=>i.assign(P,(0,e._)`${x}.type || "string"`).assign(C,(0,e._)`${x}.validate`),()=>i.assign(P,(0,e._)`"string"`).assign(C,x)),a.fail$data((0,e.or)(E(),R()));function E(){return h.strictSchema===!1?e.nil:(0,e._)`${p} && !${C}`}function R(){const D=v.$async?(0,e._)`(${x}.async ? await ${C}(${l}) : ${C}(${l}))`:(0,e._)`${C}(${l})`,O=(0,e._)`(typeof ${C} == "function" ? ${D} : ${C}.test(${l}))`;return(0,e._)`${C} && ${C} !== true && ${P} === ${n} && !${O}`}}function _(){const T=b.formats[u];if(!T){E();return}if(T===!0)return;const[x,P,C]=R(T);x===n&&a.pass(D());function E(){if(h.strictSchema===!1){b.logger.warn(O());return}throw new Error(O());function O(){return`unknown format "${u}" ignored in schema at path "${f}"`}}function R(O){const L=O instanceof RegExp?(0,e.regexpCode)(O):h.code.formats?(0,e._)`${h.code.formats}${(0,e.getProperty)(u)}`:void 0,$=i.scopeValue("formats",{key:u,ref:O,code:L});return typeof O=="object"&&!(O instanceof RegExp)?[O.type||"string",O.validate,(0,e._)`${$}.validate`]:["string",O,$]}function D(){if(typeof T=="object"&&!(T instanceof RegExp)&&T.async){if(!v.$async)throw new Error("async format in sync schema");return(0,e._)`await ${C}(${l})`}return typeof P=="function"?(0,e._)`${C}(${l})`:(0,e._)`${C}.test(${l})`}}}};return vg.default=o,vg}var VR;function eY(){if(VR)return fg;VR=1,Object.defineProperty(fg,"__esModule",{value:!0});const t=[XK().default];return fg.default=t,fg}var ll={},HR;function tY(){return HR||(HR=1,Object.defineProperty(ll,"__esModule",{value:!0}),ll.contentVocabulary=ll.metadataVocabulary=void 0,ll.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"],ll.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]),ll}var GR;function oY(){if(GR)return zh;GR=1,Object.defineProperty(zh,"__esModule",{value:!0});const e=CK(),t=FK(),o=JK(),a=eY(),n=tY(),i=[e.default,t.default,(0,o.default)(),a.default,n.metadataVocabulary,n.contentVocabulary];return zh.default=i,zh}var bg={},Ou={},WR;function aY(){if(WR)return Ou;WR=1,Object.defineProperty(Ou,"__esModule",{value:!0}),Ou.DiscrError=void 0;var e;return(function(t){t.Tag="tag",t.Mapping="mapping"})(e||(Ou.DiscrError=e={})),Ou}var KR;function nY(){if(KR)return bg;KR=1,Object.defineProperty(bg,"__esModule",{value:!0});const e=yt(),t=aY(),o=a_(),a=Ov(),n=Lt(),l={keyword:"discriminator",type:"object",schemaType:"object",error:{message:({params:{discrError:c,tagName:u}})=>c===t.DiscrError.Tag?`tag "${u}" must be string`:`value of tag "${u}" must be in oneOf`,params:({params:{discrError:c,tag:u,tagName:p}})=>(0,e._)`{error: ${c}, tag: ${p}, tagValue: ${u}}`},code(c){const{gen:u,data:p,schema:m,parentSchema:h,it:f}=c,{oneOf:v}=h;if(!f.opts.discriminator)throw new Error("discriminator: requires discriminator option");const b=m.propertyName;if(typeof b!="string")throw new Error("discriminator: requires propertyName");if(m.mapping)throw new Error("discriminator: mapping is not supported");if(!v)throw new Error("discriminator: requires oneOf keyword");const S=u.let("valid",!1),_=u.const("tag",(0,e._)`${p}${(0,e.getProperty)(b)}`);u.if((0,e._)`typeof ${_} == "string"`,()=>T(),()=>c.error(!1,{discrError:t.DiscrError.Tag,tag:_,tagName:b})),c.ok(S);function T(){const C=P();u.if(!1);for(const E in C)u.elseIf((0,e._)`${_} === ${E}`),u.assign(S,x(C[E]));u.else(),c.error(!1,{discrError:t.DiscrError.Mapping,tag:_,tagName:b}),u.endIf()}function x(C){const E=u.name("valid"),R=c.subschema({keyword:"oneOf",schemaProp:C},E);return c.mergeEvaluated(R,e.Name),E}function P(){var C;const E={},R=O(h);let D=!0;for(let B=0;B<v.length;B++){let U=v[B];if(U?.$ref&&!(0,n.schemaHasRulesButRef)(U,f.self.RULES)){const W=U.$ref;if(U=o.resolveRef.call(f.self,f.schemaEnv.root,f.baseId,W),U instanceof o.SchemaEnv&&(U=U.schema),U===void 0)throw new a.default(f.opts.uriResolver,f.baseId,W)}const j=(C=U?.properties)===null||C===void 0?void 0:C[b];if(typeof j!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${b}"`);D=D&&(R||O(U)),L(j,B)}if(!D)throw new Error(`discriminator: "${b}" must be required`);return E;function O({required:B}){return Array.isArray(B)&&B.includes(b)}function L(B,U){if(B.const)$(B.const,U);else if(B.enum)for(const j of B.enum)$(j,U);else throw new Error(`discriminator: "properties/${b}" must have "const" or "enum"`)}function $(B,U){if(typeof B!="string"||B in E)throw new Error(`discriminator: "${b}" values must be unique strings`);E[B]=U}}}};return bg.default=l,bg}const rY="http://json-schema.org/draft-07/schema#",iY="http://json-schema.org/draft-07/schema#",sY="Core schema meta-schema",lY={schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},cY=["object","boolean"],dY={$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},uY={$schema:rY,$id:iY,title:sY,definitions:lY,type:cY,properties:dY,default:!0};var YR;function pY(){return YR||(YR=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.MissingRefError=t.ValidationError=t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=t.Ajv=void 0;const o=xK(),a=oY(),n=nY(),i=uY,l=["/properties"],c="http://json-schema.org/draft-07/schema";class u extends o.default{_addVocabularies(){super._addVocabularies(),a.default.forEach(b=>this.addVocabulary(b)),this.opts.discriminator&&this.addKeyword(n.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const b=this.opts.$data?this.$dataMetaSchema(i,l):i;this.addMetaSchema(b,c,!1),this.refs["http://json-schema.org/schema"]=c}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(c)?c:void 0)}}t.Ajv=u,e.exports=t=u,e.exports.Ajv=u,Object.defineProperty(t,"__esModule",{value:!0}),t.default=u;var p=Dv();Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return p.KeywordCxt}});var m=yt();Object.defineProperty(t,"_",{enumerable:!0,get:function(){return m._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return m.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return m.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return m.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return m.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return m.CodeGen}});var h=o_();Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return h.default}});var f=Ov();Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return f.default}})})(Ih,Ih.exports)),Ih.exports}var yg={exports:{}},YS={},ZR;function mY(){return ZR||(ZR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.formatNames=e.fastFormats=e.fullFormats=void 0;function t(B,U){return{validate:B,compare:U}}e.fullFormats={date:t(i,l),time:t(u(!0),p),"date-time":t(f(!0),v),"iso-time":t(u(),m),"iso-date-time":t(f(),b),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:T,"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,url:/^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,regex:$,uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,byte:P,int32:{type:"number",validate:R},int64:{type:"number",validate:D},float:{type:"number",validate:O},double:{type:"number",validate:O},password:!0,binary:!0},e.fastFormats={...e.fullFormats,date:t(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,l),time:t(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,p),"date-time":t(/^\d\d\d\d-[0-1]\d-[0-3]\dt(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,v),"iso-time":t(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,m),"iso-date-time":t(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,b),uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i},e.formatNames=Object.keys(e.fullFormats);function o(B){return B%4===0&&(B%100!==0||B%400===0)}const a=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,n=[0,31,28,31,30,31,30,31,31,30,31,30,31];function i(B){const U=a.exec(B);if(!U)return!1;const j=+U[1],W=+U[2],ne=+U[3];return W>=1&&W<=12&&ne>=1&&ne<=(W===2&&o(j)?29:n[W])}function l(B,U){if(B&&U)return B>U?1:B<U?-1:0}const c=/^(\d\d):(\d\d):(\d\d(?:\.\d+)?)(z|([+-])(\d\d)(?::?(\d\d))?)?$/i;function u(B){return function(j){const W=c.exec(j);if(!W)return!1;const ne=+W[1],H=+W[2],Z=+W[3],te=W[4],le=W[5]==="-"?-1:1,Q=+(W[6]||0),N=+(W[7]||0);if(Q>23||N>59||B&&!te)return!1;if(ne<=23&&H<=59&&Z<60)return!0;const G=H-N*le,V=ne-Q*le-(G<0?1:0);return(V===23||V===-1)&&(G===59||G===-1)&&Z<61}}function p(B,U){if(!(B&&U))return;const j=new Date("2020-01-01T"+B).valueOf(),W=new Date("2020-01-01T"+U).valueOf();if(j&&W)return j-W}function m(B,U){if(!(B&&U))return;const j=c.exec(B),W=c.exec(U);if(j&&W)return B=j[1]+j[2]+j[3],U=W[1]+W[2]+W[3],B>U?1:B<U?-1:0}const h=/t|\s/i;function f(B){const U=u(B);return function(W){const ne=W.split(h);return ne.length===2&&i(ne[0])&&U(ne[1])}}function v(B,U){if(!(B&&U))return;const j=new Date(B).valueOf(),W=new Date(U).valueOf();if(j&&W)return j-W}function b(B,U){if(!(B&&U))return;const[j,W]=B.split(h),[ne,H]=U.split(h),Z=l(j,ne);if(Z!==void 0)return Z||p(W,H)}const S=/\/|:/,_=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;function T(B){return S.test(B)&&_.test(B)}const x=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function P(B){return x.lastIndex=0,x.test(B)}const C=-2147483648,E=2**31-1;function R(B){return Number.isInteger(B)&&B<=E&&B>=C}function D(B){return Number.isInteger(B)}function O(){return!0}const L=/[^\\]\\Z/;function $(B){if(L.test(B))return!1;try{return new RegExp(B),!0}catch{return!1}}})(YS)),YS}var ZS={},QR;function hY(){return QR||(QR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.formatLimitDefinition=void 0;const t=pY(),o=yt(),a=o.operators,n={formatMaximum:{okStr:"<=",ok:a.LTE,fail:a.GT},formatMinimum:{okStr:">=",ok:a.GTE,fail:a.LT},formatExclusiveMaximum:{okStr:"<",ok:a.LT,fail:a.GTE},formatExclusiveMinimum:{okStr:">",ok:a.GT,fail:a.LTE}},i={message:({keyword:c,schemaCode:u})=>(0,o.str)`should be ${n[c].okStr} ${u}`,params:({keyword:c,schemaCode:u})=>(0,o._)`{comparison: ${n[c].okStr}, limit: ${u}}`};e.formatLimitDefinition={keyword:Object.keys(n),type:"string",schemaType:"string",$data:!0,error:i,code(c){const{gen:u,data:p,schemaCode:m,keyword:h,it:f}=c,{opts:v,self:b}=f;if(!v.validateFormats)return;const S=new t.KeywordCxt(f,b.RULES.all.format.definition,"format");S.$data?_():T();function _(){const P=u.scopeValue("formats",{ref:b.formats,code:v.code.formats}),C=u.const("fmt",(0,o._)`${P}[${S.schemaCode}]`);c.fail$data((0,o.or)((0,o._)`typeof ${C} != "object"`,(0,o._)`${C} instanceof RegExp`,(0,o._)`typeof ${C}.compare != "function"`,x(C)))}function T(){const P=S.schema,C=b.formats[P];if(!C||C===!0)return;if(typeof C!="object"||C instanceof RegExp||typeof C.compare!="function")throw new Error(`"${h}": format "${P}" does not define "compare" function`);const E=u.scopeValue("formats",{key:P,ref:C,code:v.code.formats?(0,o._)`${v.code.formats}${(0,o.getProperty)(P)}`:void 0});c.fail$data(x(E))}function x(P){return(0,o._)`${P}.compare(${p}, ${m}) ${n[h].fail} 0`}},dependencies:["format"]};const l=c=>(c.addKeyword(e.formatLimitDefinition),c);e.default=l})(ZS)),ZS}var JR;function gY(){return JR||(JR=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const o=mY(),a=hY(),n=yt(),i=new n.Name("fullFormats"),l=new n.Name("fastFormats"),c=(p,m={keywords:!0})=>{if(Array.isArray(m))return u(p,m,o.fullFormats,i),p;const[h,f]=m.mode==="fast"?[o.fastFormats,l]:[o.fullFormats,i],v=m.formats||o.formatNames;return u(p,v,h,f),m.keywords&&(0,a.default)(p),p};c.get=(p,m="full")=>{const f=(m==="fast"?o.fastFormats:o.fullFormats)[p];if(!f)throw new Error(`Unknown format "${p}"`);return f};function u(p,m,h,f){var v,b;(v=(b=p.opts.code).formats)!==null&&v!==void 0||(b.formats=(0,n._)`require("ajv-formats/dist/formats").${f}`);for(const S of m)p.addFormat(S,h[S])}e.exports=t=c,Object.defineProperty(t,"__esModule",{value:!0}),t.default=c})(yg,yg.exports)),yg.exports}var fY=gY();const Qfe=Ml(fY);function vY({studioUrl:e,meshUrl:t},o){return e??t??o}let r_;r_=globalThis.crypto;async function bY(e){return(await r_).getRandomValues(new Uint8Array(e))}async function yY(e){const t="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-._~",o=Math.pow(2,8)-Math.pow(2,8)%t.length;let a="";for(;a.length<e;){const n=await bY(e-a.length);for(const i of n)i<o&&(a+=t[i%t.length])}return a}async function SY(e){return await yY(e)}async function wY(e){const t=await(await r_).subtle.digest("SHA-256",new TextEncoder().encode(e));return btoa(String.fromCharCode(...new Uint8Array(t))).replace(/\//g,"_").replace(/\+/g,"-").replace(/=/g,"")}async function Jfe(e){if(e||(e=43),e<43||e>128)throw`Expected a length between 43 and 128. Received ${e}.`;const t=await SY(e),o=await wY(t);return{code_verifier:t,code_challenge:o}}const xa=GN().superRefine((e,t)=>{if(!URL.canParse(e))return t.addIssue({code:kH.custom,message:"URL must be parseable",fatal:!0}),R8}).refine(e=>{const t=new URL(e);return t.protocol!=="javascript:"&&t.protocol!=="data:"&&t.protocol!=="vbscript:"},{message:"URL cannot use javascript:, data:, or vbscript: scheme"}),Xfe=_a({resource:q().url(),authorization_servers:Be(xa).optional(),jwks_uri:q().url().optional(),scopes_supported:Be(q()).optional(),bearer_methods_supported:Be(q()).optional(),resource_signing_alg_values_supported:Be(q()).optional(),resource_name:q().optional(),resource_documentation:q().optional(),resource_policy_uri:q().url().optional(),resource_tos_uri:q().url().optional(),tls_client_certificate_bound_access_tokens:$t().optional(),authorization_details_types_supported:Be(q()).optional(),dpop_signing_alg_values_supported:Be(q()).optional(),dpop_bound_access_tokens_required:$t().optional()}),TY=_a({issuer:q(),authorization_endpoint:xa,token_endpoint:xa,registration_endpoint:xa.optional(),scopes_supported:Be(q()).optional(),response_types_supported:Be(q()),response_modes_supported:Be(q()).optional(),grant_types_supported:Be(q()).optional(),token_endpoint_auth_methods_supported:Be(q()).optional(),token_endpoint_auth_signing_alg_values_supported:Be(q()).optional(),service_documentation:xa.optional(),revocation_endpoint:xa.optional(),revocation_endpoint_auth_methods_supported:Be(q()).optional(),revocation_endpoint_auth_signing_alg_values_supported:Be(q()).optional(),introspection_endpoint:q().optional(),introspection_endpoint_auth_methods_supported:Be(q()).optional(),introspection_endpoint_auth_signing_alg_values_supported:Be(q()).optional(),code_challenge_methods_supported:Be(q()).optional(),client_id_metadata_document_supported:$t().optional()}),xY=_a({issuer:q(),authorization_endpoint:xa,token_endpoint:xa,userinfo_endpoint:xa.optional(),jwks_uri:xa,registration_endpoint:xa.optional(),scopes_supported:Be(q()).optional(),response_types_supported:Be(q()),response_modes_supported:Be(q()).optional(),grant_types_supported:Be(q()).optional(),acr_values_supported:Be(q()).optional(),subject_types_supported:Be(q()),id_token_signing_alg_values_supported:Be(q()),id_token_encryption_alg_values_supported:Be(q()).optional(),id_token_encryption_enc_values_supported:Be(q()).optional(),userinfo_signing_alg_values_supported:Be(q()).optional(),userinfo_encryption_alg_values_supported:Be(q()).optional(),userinfo_encryption_enc_values_supported:Be(q()).optional(),request_object_signing_alg_values_supported:Be(q()).optional(),request_object_encryption_alg_values_supported:Be(q()).optional(),request_object_encryption_enc_values_supported:Be(q()).optional(),token_endpoint_auth_methods_supported:Be(q()).optional(),token_endpoint_auth_signing_alg_values_supported:Be(q()).optional(),display_values_supported:Be(q()).optional(),claim_types_supported:Be(q()).optional(),claims_supported:Be(q()).optional(),service_documentation:q().optional(),claims_locales_supported:Be(q()).optional(),ui_locales_supported:Be(q()).optional(),claims_parameter_supported:$t().optional(),request_parameter_supported:$t().optional(),request_uri_parameter_supported:$t().optional(),require_request_uri_registration:$t().optional(),op_policy_uri:xa.optional(),op_tos_uri:xa.optional(),client_id_metadata_document_supported:$t().optional()}),eve=we({...xY.shape,...TY.pick({code_challenge_methods_supported:!0}).shape}),tve=we({access_token:q(),id_token:q().optional(),token_type:q(),expires_in:tI().optional(),scope:q().optional(),refresh_token:q().optional()}).strip(),ove=we({error:q(),error_description:q().optional(),error_uri:q().optional()}),XR=xa.optional().or(Ze("").transform(()=>{})),_Y=we({redirect_uris:Be(xa),token_endpoint_auth_method:q().optional(),grant_types:Be(q()).optional(),response_types:Be(q()).optional(),client_name:q().optional(),client_uri:xa.optional(),logo_uri:XR,scope:q().optional(),contacts:Be(q()).optional(),tos_uri:XR,policy_uri:q().optional(),jwks_uri:xa.optional(),jwks:Q9().optional(),software_id:q().optional(),software_version:q().optional(),software_statement:q().optional()}).strip(),kY=we({client_id:q(),client_secret:q().optional(),client_id_issued_at:Mt().optional(),client_secret_expires_at:Mt().optional()}).strip(),ave=_Y.merge(kY);we({error:q(),error_description:q().optional()}).strip();we({token:q(),token_type_hint:q().optional()}).strip();class Pa extends Error{constructor(t,o){super(t),this.errorUri=o,this.name=this.constructor.name}toResponseObject(){const t={error:this.errorCode,error_description:this.message};return this.errorUri&&(t.error_uri=this.errorUri),t}get errorCode(){return this.constructor.errorCode}}class Iw extends Pa{}Iw.errorCode="invalid_request";class Lw extends Pa{}Lw.errorCode="invalid_client";class Bw extends Pa{}Bw.errorCode="invalid_grant";class Fw extends Pa{}Fw.errorCode="unauthorized_client";class jw extends Pa{}jw.errorCode="unsupported_grant_type";class zw extends Pa{}zw.errorCode="invalid_scope";class Uw extends Pa{}Uw.errorCode="access_denied";class $w extends Pa{}$w.errorCode="server_error";class qw extends Pa{}qw.errorCode="temporarily_unavailable";class Vw extends Pa{}Vw.errorCode="unsupported_response_type";class Hw extends Pa{}Hw.errorCode="unsupported_token_type";class Gw extends Pa{}Gw.errorCode="invalid_token";class Ww extends Pa{}Ww.errorCode="method_not_allowed";class Kw extends Pa{}Kw.errorCode="too_many_requests";class Yw extends Pa{}Yw.errorCode="invalid_client_metadata";class Zw extends Pa{}Zw.errorCode="insufficient_scope";class Qw extends Pa{}Qw.errorCode="invalid_target";const nve={[Iw.errorCode]:Iw,[Lw.errorCode]:Lw,[Bw.errorCode]:Bw,[Fw.errorCode]:Fw,[jw.errorCode]:jw,[zw.errorCode]:zw,[Uw.errorCode]:Uw,[$w.errorCode]:$w,[qw.errorCode]:qw,[Vw.errorCode]:Vw,[Hw.errorCode]:Hw,[Gw.errorCode]:Gw,[Ww.errorCode]:Ww,[Kw.errorCode]:Kw,[Yw.errorCode]:Yw,[Zw.errorCode]:Zw,[Qw.errorCode]:Qw};async function UI(e){if(!e.getServerCapabilities()?.resources)return{resources:[]};try{return await e.listResources()}catch(o){if(o instanceof Pv&&o.code===Cp.MethodNotFound)return{resources:[]};throw o}}async function CY(e,t){return await e.readResource({uri:t})}function rve(e){const t=Re.c(12);let o,a;t[0]!==e?({client:o,...a}=e,t[0]=e,t[1]=o,t[2]=a):(o=t[1],a=t[2]);let n;t[3]!==o?(n=On.mcpResourcesList(o),t[3]=o,t[4]=n):n=t[4];let i;t[5]!==o?(i=()=>UI(o),t[5]=o,t[6]=i):i=t[6];const l=a.staleTime??3e4;let c;return t[7]!==a||t[8]!==n||t[9]!==i||t[10]!==l?(c={...a,queryKey:n,queryFn:i,staleTime:l,retry:!1},t[7]=a,t[8]=n,t[9]=i,t[10]=l,t[11]=c):c=t[11],Il(c)}function ive(e){const t=Re.c(12);let o,a;t[0]!==e?({client:o,...a}=e,t[0]=e,t[1]=o,t[2]=a):(o=t[1],a=t[2]);let n;t[3]!==o?(n=On.mcpResourcesList(o),t[3]=o,t[4]=n):n=t[4];let i;t[5]!==o?(i=()=>UI(o),t[5]=o,t[6]=i):i=t[6];const l=a.staleTime??3e4;let c;return t[7]!==a||t[8]!==n||t[9]!==i||t[10]!==l?(c={...a,queryKey:n,queryFn:i,staleTime:l,retry:!1},t[7]=a,t[8]=n,t[9]=i,t[10]=l,t[11]=c):c=t[11],Rd(c)}function sve(e){const t=Re.c(15);let o,a,n;t[0]!==e?({client:o,uri:n,...a}=e,t[0]=e,t[1]=o,t[2]=a,t[3]=n):(o=t[1],a=t[2],n=t[3]);let i;t[4]!==o||t[5]!==n?(i=On.mcpReadResource(o,n),t[4]=o,t[5]=n,t[6]=i):i=t[6];let l;t[7]!==o||t[8]!==n?(l=()=>CY(o,n),t[7]=o,t[8]=n,t[9]=l):l=t[9];const c=a.staleTime??3e4;let u;return t[10]!==a||t[11]!==i||t[12]!==l||t[13]!==c?(u={...a,queryKey:i,queryFn:l,staleTime:c,retry:!1},t[10]=a,t[11]=i,t[12]=l,t[13]=c,t[14]=u):u=t[14],Il(u)}const $I="ui-resource-html";function lve(e){const t=Re.c(22);let o,a,n,i,l,c;t[0]!==e?({orgSlug:n,connectionId:o,uri:c,studioUrl:l,meshUrl:a,...i}=e,t[0]=e,t[1]=o,t[2]=a,t[3]=n,t[4]=i,t[5]=l,t[6]=c):(o=t[1],a=t[2],n=t[3],i=t[4],l=t[5],c=t[6]);let u;t[7]!==o||t[8]!==n||t[9]!==c?(u=On.mcpUiResourceHtml(n,o,c),t[7]=o,t[8]=n,t[9]=c,t[10]=u):u=t[10];let p;t[11]!==o||t[12]!==a||t[13]!==n||t[14]!==l||t[15]!==c?(p=async()=>{const v=`${vY({studioUrl:l,meshUrl:a},typeof window<"u"?window.location.origin:"")}/api/${encodeURIComponent(n)}/mcp/${encodeURIComponent(o)}/ui-resource?uri=${encodeURIComponent(c)}`,b=await fetch(v,{credentials:"include"});if(!b.ok)throw new Error(`Failed to read UI resource (${b.status})`);return b.text()},t[11]=o,t[12]=a,t[13]=n,t[14]=l,t[15]=c,t[16]=p):p=t[16];const m=i.staleTime??3e4;let h;return t[17]!==i||t[18]!==u||t[19]!==p||t[20]!==m?(h={...i,queryKey:u,queryFn:p,staleTime:m,retry:!1},t[17]=i,t[18]=u,t[19]=p,t[20]=m,t[21]=h):h=t[21],Il(h)}const qI={featureNotInPlan:"feature_not_in_plan",aiBudgetExhausted:"ai_budget_exhausted"};class Jw extends Error{constructor(t,o,a){super(t),this.status=o,this.code=a,this.name="StudioToolError"}status;code}function VI(e){return e instanceof Jw&&Object.values(qI).includes(e.code??"")?e.code:null}async function EY(e,t,o){const a=await fetch(`/api/${encodeURIComponent(e)}/tools/${encodeURIComponent(t)}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(o??{})});if(!a.ok){let n=`${t} failed (${a.status})`,i;try{const l=await a.json();l?.error&&(n=l.error),typeof l?.code=="string"&&(i=l.code)}catch{}throw new Jw(n,a.status,i)}try{return await a.json()}catch{throw new Jw(`${t} returned a non-JSON response`,a.status)}}function i_(){const e=Re.c(5),{org:t}=Zp(),o=t.slug;let a;e[0]!==o?(a=(i,l)=>EY(o,i,l),e[0]=o,e[1]=a):a=e[1];let n;return e[2]!==o||e[3]!==a?(n={orgSlug:o,call:a},e[2]=o,e[3]=a,e[4]=n):n=e[4],n}const s_=5*6e4;async function HI(){return(await(await fetch("/api/config")).json()).config}function GI(){const e=Re.c(1);let t;e[0]===Symbol.for("react.memo_cache_sentinel")?(t={queryKey:On.publicConfig(),queryFn:HI,staleTime:s_},e[0]=t):t=e[0];const{data:o}=Il(t);return o}function cve(){const e=Re.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t={queryKey:On.publicConfig(),queryFn:HI,staleTime:s_},e[0]=t):t=e[0],Rd(t).data}const WI=A.createContext(void 0);function PY(e){const t=Re.c(3),{children:o}=e,a=GI();let n;return t[0]!==o||t[1]!==a.auth?(n=w.jsx(WI.Provider,{value:a.auth,children:o}),t[0]=o,t[1]=a.auth,t[2]=n):n=t[2],n}function dve(){const e=A.useContext(WI);if(e===void 0)throw new Error("useAuthConfig must be used within AuthConfigProvider");return e}var AY={},eD={};const Qg=Object.create(null),Mu=e=>AY||globalThis.Deno?.env.toObject()||globalThis.__env__||(e?Qg:globalThis),Wn=new Proxy(Qg,{get(e,t){return Mu()[t]??Qg[t]},has(e,t){return t in Mu()||t in Qg},set(e,t,o){const a=Mu(!0);return a[t]=o,!0},deleteProperty(e,t){if(!t)return!1;const o=Mu(!0);return delete o[t],!0},ownKeys(){const e=Mu(!0);return Object.keys(e)}});function Ko(e,t){return typeof process<"u"&&eD?eD[e]??t:typeof Deno<"u"?Deno.env.get(e)??t:typeof Bun<"u"?Bun.env[e]??t:t}const Nu=1,ua=4,Fr=8,Cn=24,tD={eterm:ua,cons25:ua,console:ua,cygwin:ua,dtterm:ua,gnome:ua,hurd:ua,jfbterm:ua,konsole:ua,kterm:ua,mlterm:ua,mosh:Cn,putty:ua,st:ua,"rxvt-unicode-24bit":Cn,terminator:Cn,"xterm-kitty":Cn},RY=new Map(Object.entries({APPVEYOR:Fr,BUILDKITE:Fr,CIRCLECI:Cn,DRONE:Fr,GITEA_ACTIONS:Cn,GITHUB_ACTIONS:Cn,GITLAB_CI:Fr,TRAVIS:Fr})),DY=[/ansi/,/color/,/linux/,/direct/,/^con[0-9]*x[0-9]/,/^rxvt/,/^screen/,/^xterm/,/^vt100/,/^vt220/];function OY(){if(Ko("FORCE_COLOR")!==void 0)switch(Ko("FORCE_COLOR")){case"":case"1":case"true":return ua;case"2":return Fr;case"3":return Cn;default:return Nu}if(Ko("NODE_DISABLE_COLORS")!==void 0&&Ko("NODE_DISABLE_COLORS")!==""||Ko("NO_COLOR")!==void 0&&Ko("NO_COLOR")!==""||Ko("TERM")==="dumb")return Nu;if(Ko("TMUX"))return Cn;if("TF_BUILD"in Wn&&"AGENT_NAME"in Wn)return ua;if("CI"in Wn){for(const{0:e,1:t}of RY)if(e in Wn)return t;return Ko("CI_NAME")==="codeship"?Fr:Nu}if("TEAMCITY_VERSION"in Wn)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.exec(Ko("TEAMCITY_VERSION"))!==null?ua:Nu;switch(Ko("TERM_PROGRAM")){case"iTerm.app":return!Ko("TERM_PROGRAM_VERSION")||/^[0-2]\./.exec(Ko("TERM_PROGRAM_VERSION"))!==null?Fr:Cn;case"HyperTerm":case"MacTerm":return Cn;case"Apple_Terminal":return Fr}if(Ko("COLORTERM")==="truecolor"||Ko("COLORTERM")==="24bit")return Cn;if(Ko("TERM")){if(/truecolor/.exec(Ko("TERM"))!==null)return Cn;if(/^xterm-256/.exec(Ko("TERM"))!==null)return Fr;const e=Ko("TERM").toLowerCase();if(tD[e])return tD[e];if(DY.some(t=>t.exec(e)!==null))return ua}return Ko("COLORTERM")?ua:Nu}const jr={reset:"\x1B[0m",bright:"\x1B[1m",dim:"\x1B[2m",fg:{red:"\x1B[31m",green:"\x1B[32m",yellow:"\x1B[33m",blue:"\x1B[34m",magenta:"\x1B[35m"}},Xw=["debug","info","success","warn","error"];function MY(e,t){return Xw.indexOf(t)>=Xw.indexOf(e)}const NY={info:jr.fg.blue,success:jr.fg.green,warn:jr.fg.yellow,error:jr.fg.red,debug:jr.fg.magenta},IY=(e,t,o)=>{const a=new Date().toISOString();return o?`${jr.dim}${a}${jr.reset} ${NY[e]}${e.toUpperCase()}${jr.reset} ${jr.bright}[Better Auth]:${jr.reset} ${t}`:`${a} ${e.toUpperCase()} [Better Auth]: ${t}`},LY=e=>{const t="warn",o=OY()!==1,a=(n,i,l=[])=>{if(!MY(t,n))return;const c=IY(n,i,o);{n==="error"?console.error(c,...l):n==="warn"?console.warn(c,...l):console.log(c,...l);return}};return{...Object.fromEntries(Xw.map(n=>[n,(...[i,...l])=>a(n,i,l)])),get level(){return t}}};LY();function BY(e){return e.charAt(0).toUpperCase()+e.slice(1)}var lp=class extends Error{constructor(e,t){super(e,t),this.name="BetterAuthError",this.message=e,this.stack=""}};function FY(e){try{return(new URL(e).pathname.replace(/\/+$/,"")||"/")!=="/"}catch{throw new lp(`Invalid base URL: ${e}. Please provide a valid base URL.`)}}function jY(e){try{const t=new URL(e);if(t.protocol!=="http:"&&t.protocol!=="https:")throw new lp(`Invalid base URL: ${e}. URL must include 'http://' or 'https://'`)}catch(t){throw t instanceof lp?t:new lp(`Invalid base URL: ${e}. Please provide a valid base URL.`,{cause:t})}}function QS(e,t="/api/auth"){if(jY(e),FY(e))return e;const o=e.replace(/\/+$/,"");return!t||t==="/"?o:(t=t.startsWith("/")?t:`/${t}`,`${o}${t}`)}function zY(e,t,o,a,n){if(e)return QS(e,t);{const i=Wn.BETTER_AUTH_URL||Wn.NEXT_PUBLIC_BETTER_AUTH_URL||Wn.PUBLIC_BETTER_AUTH_URL||Wn.NUXT_PUBLIC_BETTER_AUTH_URL||Wn.NUXT_PUBLIC_AUTH_URL||(Wn.BASE_URL!=="/"?Wn.BASE_URL:void 0);if(i)return QS(i,t)}if(typeof window<"u"&&window.location)return QS(window.location.origin,t)}const UY={id:"redirect",name:"Redirect",hooks:{onSuccess(e){if(e.data?.url&&e.data?.redirect&&typeof window<"u"&&window.location&&window.location)try{window.location.href=e.data.url}catch{}}}},$Y={proto:/"(?:_|\\u0{2}5[Ff]){2}(?:p|\\u0{2}70)(?:r|\\u0{2}72)(?:o|\\u0{2}6[Ff])(?:t|\\u0{2}74)(?:o|\\u0{2}6[Ff])(?:_|\\u0{2}5[Ff]){2}"\s*:/,constructor:/"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/,protoShort:/"__proto__"\s*:/,constructorShort:/"constructor"\s*:/},qY=/^\s*["[{]|^\s*-?\d{1,16}(\.\d{1,17})?([Ee][+-]?\d+)?\s*$/,oD={true:!0,false:!1,null:null,undefined:void 0,nan:NaN,infinity:Number.POSITIVE_INFINITY,"-infinity":Number.NEGATIVE_INFINITY},VY=/^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2})(?:\.(\d{1,7}))?(?:Z|([+-])(\d{2}):(\d{2}))$/;function HY(e){return e instanceof Date&&!isNaN(e.getTime())}function GY(e){const t=VY.exec(e);if(!t)return null;const[,o,a,n,i,l,c,u,p,m,h]=t,f=new Date(Date.UTC(parseInt(o,10),parseInt(a,10)-1,parseInt(n,10),parseInt(i,10),parseInt(l,10),parseInt(c,10),u?parseInt(u.padEnd(3,"0"),10):0));if(p){const v=(parseInt(m,10)*60+parseInt(h,10))*(p==="+"?-1:1);f.setUTCMinutes(f.getUTCMinutes()+v)}return HY(f)?f:null}function WY(e,t={}){const{strict:o=!1,warnings:a=!1,reviver:n,parseDates:i=!0}=t;if(typeof e!="string")return e;const l=e.trim();if(l.length>0&&l[0]==='"'&&l.endsWith('"')&&!l.slice(1,-1).includes('"'))return l.slice(1,-1);const c=l.toLowerCase();if(c.length<=9&&c in oD)return oD[c];if(!qY.test(l)){if(o)throw new SyntaxError("[better-json] Invalid JSON");return e}if(Object.entries($Y).some(([u,p])=>{const m=p.test(l);return m&&a&&console.warn(`[better-json] Detected potential prototype pollution attempt using ${u} pattern`),m})&&o)throw new Error("[better-json] Potential prototype pollution attempt detected");try{return JSON.parse(l,(p,m)=>{if(p==="__proto__"||p==="constructor"&&m&&typeof m=="object"&&"prototype"in m){a&&console.warn(`[better-json] Dropping "${p}" key to prevent prototype pollution`);return}if(i&&typeof m=="string"){const h=GY(m);if(h)return h}return n?n(p,m):m})}catch(u){if(o)throw u;return e}}function KY(e,t={strict:!0}){return WY(e,t)}let dr=[],ds=0;const Sg=4,YY=globalThis.nanostoresGlobal||={epoch:0},Jc=e=>{let t=[],o={get(){return o.lc||o.listen(()=>{})(),o.value},init:e,lc:0,listen(a){return o.lc=t.push(a),()=>{for(let i=ds+Sg;i<dr.length;)dr[i]===a?dr.splice(i,Sg):i+=Sg;let n=t.indexOf(a);~n&&(t.splice(n,1),--o.lc||o.off())}},notify(a,n){YY.epoch++;let i=!dr.length;for(let l of t)dr.push(l,o.value,a,n);if(i){for(ds=0;ds<dr.length;ds+=Sg)dr[ds](dr[ds+1],dr[ds+2],dr[ds+3]);dr.length=0}},off(){},set(a){let n=o.value;n!==a&&(o.value=a,o.notify(n))},subscribe(a){let n=o.listen(a);return a(o.value),n},value:e};return o},ZY=5,wg=6,Tg=10;let QY=(e,t,o,a)=>(e.events=e.events||{},e.events[o+Tg]||(e.events[o+Tg]=a(n=>{e.events[o].reduceRight((i,l)=>(l(i),i),{shared:{},...n})})),e.events[o]=e.events[o]||[],e.events[o].push(t),()=>{let n=e.events[o],i=n.indexOf(t);n.splice(i,1),n.length||(delete e.events[o],e.events[o+Tg](),delete e.events[o+Tg])});const JY=1e3;let KI=(e,t)=>QY(e,a=>{let n=t(a);n&&e.events[wg].push(n)},ZY,a=>{let n=e.listen;e.listen=(...l)=>(!e.lc&&!e.active&&(e.active=!0,a()),n(...l));let i=e.off;return e.events[wg]=[],e.off=()=>{i(),setTimeout(()=>{if(e.active&&!e.lc){e.active=!1;for(let l of e.events[wg])l();e.events[wg]=[]}},JY)},()=>{e.listen=n,e.off=i}});function XY(e,t,o){let a=new Set(t).add(void 0);return e.listen((n,i,l)=>{a.has(l)&&o(n,i,l)})}const eZ=()=>typeof window>"u",Zu=(e,t,o,a)=>{const n=Jc({data:null,error:null,isPending:!0,isRefetching:!1,refetch:c=>i(c)}),i=async c=>new Promise(u=>{const p=typeof a=="function"?a({data:n.get().data,error:n.get().error,isPending:n.get().isPending}):a;o(t,{...p,query:{...p?.query,...c?.query},async onSuccess(m){n.set({data:m.data,error:null,isPending:!1,isRefetching:!1,refetch:n.value.refetch}),await p?.onSuccess?.(m)},async onError(m){const{request:h}=m,f=typeof h.retry=="number"?h.retry:h.retry?.attempts,v=h.retryAttempt||0;f&&v<f||(n.set({error:m.error,data:null,isPending:!1,isRefetching:!1,refetch:n.value.refetch}),await p?.onError?.(m))},async onRequest(m){const h=n.get();n.set({isPending:h.data===null,data:h.data,error:null,isRefetching:!0,refetch:n.value.refetch}),await p?.onRequest?.(m)}}).catch(m=>{n.set({error:m,data:null,isPending:!1,isRefetching:!1,refetch:n.value.refetch})}).finally(()=>{u(void 0)})});e=Array.isArray(e)?e:[e];let l=!1;for(const c of e)c.subscribe(async()=>{eZ()||(l?await i():KI(n,()=>{const u=setTimeout(async()=>{l||(await i(),l=!0)},0);return()=>{n.off(),c.off(),clearTimeout(u)}}))});return n},JS=Symbol.for("better-auth:broadcast-channel"),tZ=()=>Math.floor(Date.now()/1e3);var oZ=class{listeners=new Set;name;constructor(e="better-auth.message"){this.name=e}subscribe(e){return this.listeners.add(e),()=>{this.listeners.delete(e)}}post(e){if(!(typeof window>"u"))try{localStorage.setItem(this.name,JSON.stringify({...e,timestamp:tZ()}))}catch{}}setup(){if(typeof window>"u"||typeof window.addEventListener>"u")return()=>{};const e=t=>{if(t.key!==this.name)return;const o=JSON.parse(t.newValue??"{}");o?.event!=="session"||!o?.data||this.listeners.forEach(a=>a(o))};return window.addEventListener("storage",e),()=>{window.removeEventListener("storage",e)}}};function XS(e="better-auth.message"){return globalThis[JS]||(globalThis[JS]=new oZ(e)),globalThis[JS]}const e0=Symbol.for("better-auth:focus-manager");var aZ=class{listeners=new Set;subscribe(e){return this.listeners.add(e),()=>{this.listeners.delete(e)}}setFocused(e){this.listeners.forEach(t=>t(e))}setup(){if(typeof window>"u"||typeof document>"u"||typeof window.addEventListener>"u")return()=>{};const e=()=>{document.visibilityState==="visible"&&this.setFocused(!0)};return document.addEventListener("visibilitychange",e,!1),()=>{document.removeEventListener("visibilitychange",e,!1)}}};function aD(){return globalThis[e0]||(globalThis[e0]=new aZ),globalThis[e0]}const t0=Symbol.for("better-auth:online-manager");var nZ=class{listeners=new Set;isOnline=typeof navigator<"u"?navigator.onLine:!0;subscribe(e){return this.listeners.add(e),()=>{this.listeners.delete(e)}}setOnline(e){this.isOnline=e,this.listeners.forEach(t=>t(e))}setup(){if(typeof window>"u"||typeof window.addEventListener>"u")return()=>{};const e=()=>this.setOnline(!0),t=()=>this.setOnline(!1);return window.addEventListener("online",e,!1),window.addEventListener("offline",t,!1),()=>{window.removeEventListener("online",e,!1),window.removeEventListener("offline",t,!1)}}};function o0(){return globalThis[t0]||(globalThis[t0]=new nZ),globalThis[t0]}const Rc=()=>Math.floor(Date.now()/1e3),rZ=5;function iZ(e){const{sessionAtom:t,sessionSignal:o,$fetch:a,options:n={}}=e,i=n.sessionOptions?.refetchInterval??0,l=n.sessionOptions?.refetchOnWindowFocus??!0,c=n.sessionOptions?.refetchWhenOffline??!1,u={lastSync:0,lastSessionRequest:0,cachedSession:void 0},p=()=>c||o0().isOnline,m=x=>{if(!p())return;if(x?.event==="storage"){u.lastSync=Rc(),o.set(!o.get());return}const P=t.get();if(x?.event==="poll"){u.lastSessionRequest=Rc(),a("/get-session").then(C=>{C.error?t.set({...P,data:null,error:C.error}):t.set({...P,data:C.data,error:null}),u.lastSync=Rc(),o.set(!o.get())}).catch(()=>{});return}if(x?.event==="visibilitychange"){if(Rc()-u.lastSessionRequest<rZ)return;u.lastSessionRequest=Rc()}(P?.data===null||P?.data===void 0||x?.event==="visibilitychange")&&(u.lastSync=Rc(),o.set(!o.get()))},h=x=>{XS().post({event:"session",data:{trigger:x},clientId:Math.random().toString(36).substring(7)})},f=()=>{i&&i>0&&(u.pollInterval=setInterval(()=>{t.get()?.data&&m({event:"poll"})},i*1e3))},v=()=>{u.unsubscribeBroadcast=XS().subscribe(()=>{m({event:"storage"})})},b=()=>{l&&(u.unsubscribeFocus=aD().subscribe(()=>{m({event:"visibilitychange"})}))},S=()=>{u.unsubscribeOnline=o0().subscribe(x=>{x&&m({event:"visibilitychange"})})};return{init:()=>{f(),v(),b(),S(),XS().setup(),aD().setup(),o0().setup()},cleanup:()=>{u.pollInterval&&(clearInterval(u.pollInterval),u.pollInterval=void 0),u.unsubscribeBroadcast&&(u.unsubscribeBroadcast(),u.unsubscribeBroadcast=void 0),u.unsubscribeFocus&&(u.unsubscribeFocus(),u.unsubscribeFocus=void 0),u.unsubscribeOnline&&(u.unsubscribeOnline(),u.unsubscribeOnline=void 0),u.lastSync=0,u.lastSessionRequest=0,u.cachedSession=void 0},triggerRefetch:m,broadcastSessionUpdate:h}}function sZ(e,t){const o=Jc(!1),a=Zu(o,"/get-session",e,{method:"GET"});return KI(a,()=>{const n=iZ({sessionAtom:a,sessionSignal:o,$fetch:e,options:t});return n.init(),()=>{n.cleanup()}}),{session:a,$sessionSignal:o}}function a0(e){if(e===null||typeof e!="object")return!1;const t=Object.getPrototypeOf(e);return t!==null&&t!==Object.prototype&&Object.getPrototypeOf(t)!==null||Symbol.iterator in e?!1:Symbol.toStringTag in e?Object.prototype.toString.call(e)==="[object Module]":!0}function eT(e,t,o=".",a){if(!a0(t))return eT(e,{},o,a);const n={...t};for(const i of Object.keys(e)){if(i==="__proto__"||i==="constructor")continue;const l=e[i];l!=null&&(a&&a(n,i,l,o)||(Array.isArray(l)&&Array.isArray(n[i])?n[i]=[...l,...n[i]]:a0(l)&&a0(n[i])?n[i]=eT(l,n[i],(o?`${o}.`:"")+i.toString(),a):n[i]=l))}return n}function lZ(e){return(...t)=>t.reduce((o,a)=>eT(o,a,"",e),{})}const cZ=lZ();var dZ=Object.defineProperty,uZ=Object.defineProperties,pZ=Object.getOwnPropertyDescriptors,nD=Object.getOwnPropertySymbols,mZ=Object.prototype.hasOwnProperty,hZ=Object.prototype.propertyIsEnumerable,rD=(e,t,o)=>t in e?dZ(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o,hr=(e,t)=>{for(var o in t||(t={}))mZ.call(t,o)&&rD(e,o,t[o]);if(nD)for(var o of nD(t))hZ.call(t,o)&&rD(e,o,t[o]);return e},Ir=(e,t)=>uZ(e,pZ(t)),gZ=class extends Error{constructor(e,t,o){super(t||e.toString(),{cause:o}),this.status=e,this.statusText=t,this.error=o,Error.captureStackTrace(this,this.constructor)}},fZ=async(e,t)=>{var o,a,n,i,l,c;let u=t||{};const p={onRequest:[t?.onRequest],onResponse:[t?.onResponse],onSuccess:[t?.onSuccess],onError:[t?.onError],onRetry:[t?.onRetry]};if(!t||!t?.plugins)return{url:e,options:u,hooks:p};for(const m of t?.plugins||[]){if(m.init){const h=await((o=m.init)==null?void 0:o.call(m,e.toString(),t));u=h.options||u,e=h.url}p.onRequest.push((a=m.hooks)==null?void 0:a.onRequest),p.onResponse.push((n=m.hooks)==null?void 0:n.onResponse),p.onSuccess.push((i=m.hooks)==null?void 0:i.onSuccess),p.onError.push((l=m.hooks)==null?void 0:l.onError),p.onRetry.push((c=m.hooks)==null?void 0:c.onRetry)}return{url:e,options:u,hooks:p}},iD=class{constructor(e){this.options=e}shouldAttemptRetry(e,t){return this.options.shouldRetry?Promise.resolve(e<this.options.attempts&&this.options.shouldRetry(t)):Promise.resolve(e<this.options.attempts)}getDelay(){return this.options.delay}},vZ=class{constructor(e){this.options=e}shouldAttemptRetry(e,t){return this.options.shouldRetry?Promise.resolve(e<this.options.attempts&&this.options.shouldRetry(t)):Promise.resolve(e<this.options.attempts)}getDelay(e){return Math.min(this.options.maxDelay,this.options.baseDelay*2**e)}};function bZ(e){if(typeof e=="number")return new iD({type:"linear",attempts:e,delay:1e3});switch(e.type){case"linear":return new iD(e);case"exponential":return new vZ(e);default:throw new Error("Invalid retry strategy")}}var yZ=async e=>{const t={},o=async a=>typeof a=="function"?await a():a;if(e?.auth){if(e.auth.type==="Bearer"){const a=await o(e.auth.token);if(!a)return t;t.authorization=`Bearer ${a}`}else if(e.auth.type==="Basic"){const[a,n]=await Promise.all([o(e.auth.username),o(e.auth.password)]);if(!a||!n)return t;t.authorization=`Basic ${btoa(`${a}:${n}`)}`}else if(e.auth.type==="Custom"){const[a,n]=await Promise.all([o(e.auth.prefix),o(e.auth.value)]);if(!n)return t;t.authorization=`${a??""} ${n}`}}return t},SZ=/^application\/(?:[\w!#$%&*.^`~-]*\+)?json(;.+)?$/i;function wZ(e){const t=e.headers.get("content-type"),o=new Set(["image/svg","application/xml","application/xhtml","application/html"]);if(!t)return"json";const a=t.split(";").shift()||"";return SZ.test(a)?"json":o.has(a)||a.startsWith("text/")?"text":"blob"}function TZ(e){try{return JSON.parse(e),!0}catch{return!1}}function tT(e){if(e===void 0)return!1;const t=typeof e;return t==="string"||t==="number"||t==="boolean"||t===null?!0:t!=="object"?!1:Array.isArray(e)?!0:e.buffer?!1:e.constructor&&e.constructor.name==="Object"||typeof e.toJSON=="function"}function sD(e){try{return JSON.parse(e)}catch{return e}}function lD(e){return typeof e=="function"}function xZ(e){if(e?.customFetchImpl)return e.customFetchImpl;if(typeof globalThis<"u"&&lD(globalThis.fetch))return globalThis.fetch;if(typeof window<"u"&&lD(window.fetch))return window.fetch;throw new Error("No fetch implementation found")}async function _Z(e){const t=new Headers(e?.headers),o=await yZ(e);for(const[a,n]of Object.entries(o||{}))t.set(a,n);if(!t.has("content-type")){const a=kZ(e?.body);a&&t.set("content-type",a)}return t}function kZ(e){return tT(e)?"application/json":null}function CZ(e){if(!e?.body)return null;const t=new Headers(e?.headers);if(tT(e.body)&&!t.has("content-type")){for(const[o,a]of Object.entries(e?.body))a instanceof Date&&(e.body[o]=a.toISOString());return JSON.stringify(e.body)}return t.has("content-type")&&t.get("content-type")==="application/x-www-form-urlencoded"&&tT(e.body)?new URLSearchParams(e.body).toString():e.body}function EZ(e,t){var o;if(t?.method)return t.method.toUpperCase();if(e.startsWith("@")){const a=(o=e.split("@")[1])==null?void 0:o.split("/")[0];return ZI.includes(a)?a.toUpperCase():t?.body?"POST":"GET"}return t?.body?"POST":"GET"}function PZ(e,t){let o;return!e?.signal&&e?.timeout&&(o=setTimeout(()=>t?.abort(),e?.timeout)),{abortTimeout:o,clearTimeout:()=>{o&&clearTimeout(o)}}}var AZ=class YI extends Error{constructor(t,o){super(o||JSON.stringify(t,null,2)),this.issues=t,Object.setPrototypeOf(this,YI.prototype)}};async function Jg(e,t){const o=await e["~standard"].validate(t);if(o.issues)throw new AZ(o.issues);return o.value}var ZI=["get","post","put","patch","delete"],RZ=e=>({id:"apply-schema",name:"Apply Schema",version:"1.0.0",async init(t,o){var a,n,i,l;const c=((n=(a=e.plugins)==null?void 0:a.find(u=>{var p;return(p=u.schema)!=null&&p.config?t.startsWith(u.schema.config.baseURL||"")||t.startsWith(u.schema.config.prefix||""):!1}))==null?void 0:n.schema)||e.schema;if(c){let u=t;(i=c.config)!=null&&i.prefix&&u.startsWith(c.config.prefix)&&(u=u.replace(c.config.prefix,""),c.config.baseURL&&(t=t.replace(c.config.prefix,c.config.baseURL))),(l=c.config)!=null&&l.baseURL&&u.startsWith(c.config.baseURL)&&(u=u.replace(c.config.baseURL,""));const p=c.schema[u];if(p){let m=Ir(hr({},o),{method:p.method,output:p.output});return o?.disableValidation||(m=Ir(hr({},m),{body:p.input?await Jg(p.input,o?.body):o?.body,params:p.params?await Jg(p.params,o?.params):o?.params,query:p.query?await Jg(p.query,o?.query):o?.query})),{url:t,options:m}}}return{url:t,options:o}}}),DZ=e=>{async function t(o,a){const n=Ir(hr(hr({},e),a),{plugins:[...e?.plugins||[],RZ(e||{}),...a?.plugins||[]]});if(e?.catchAllError)try{return await oT(o,n)}catch(i){return{data:null,error:{status:500,statusText:"Fetch Error",message:"Fetch related error. Captured by catchAllError option. See error property for more details.",error:i}}}return await oT(o,n)}return t};function OZ(e,t){const{baseURL:o,params:a,query:n}=t||{query:{},params:{},baseURL:""};let i=e.startsWith("http")?e.split("/").slice(0,3).join("/"):o||"";if(e.startsWith("@")){const h=e.toString().split("@")[1].split("/")[0];ZI.includes(h)&&(e=e.replace(`@${h}/`,"/"))}i.endsWith("/")||(i+="/");let[l,c]=e.replace(i,"").split("?");const u=new URLSearchParams(c);for(const[h,f]of Object.entries(n||{})){if(f==null)continue;let v;if(typeof f=="string")v=f;else if(Array.isArray(f)){for(const b of f)u.append(h,b);continue}else v=JSON.stringify(f);u.set(h,v)}if(a)if(Array.isArray(a)){const h=l.split("/").filter(f=>f.startsWith(":"));for(const[f,v]of h.entries()){const b=a[f];l=l.replace(v,b)}}else for(const[h,f]of Object.entries(a))l=l.replace(`:${h}`,String(f));l=l.split("/").map(encodeURIComponent).join("/"),l.startsWith("/")&&(l=l.slice(1));let p=u.toString();return p=p.length>0?`?${p}`.replace(/\+/g,"%20"):"",i.startsWith("http")?new URL(`${l}${p}`,i):`${i}${l}${p}`}var oT=async(e,t)=>{var o,a,n,i,l,c,u,p;const{hooks:m,url:h,options:f}=await fZ(e,t),v=xZ(f),b=new AbortController,S=(o=f.signal)!=null?o:b.signal,_=OZ(h,f),T=CZ(f),x=await _Z(f),P=EZ(h,f);let C=Ir(hr({},f),{url:_,headers:x,body:T,method:P,signal:S});for(const j of m.onRequest)if(j){const W=await j(C);typeof W=="object"&&W!==null&&(C=W)}("pipeTo"in C&&typeof C.pipeTo=="function"||typeof((a=t?.body)==null?void 0:a.pipe)=="function")&&("duplex"in C||(C.duplex="half"));const{clearTimeout:E}=PZ(f,b);let R=await v(C.url,C);E();const D={response:R,request:C};for(const j of m.onResponse)if(j){const W=await j(Ir(hr({},D),{response:(n=t?.hookOptions)!=null&&n.cloneResponse?R.clone():R}));W instanceof Response?R=W:typeof W=="object"&&W!==null&&(R=W.response)}if(R.ok){if(!(C.method!=="HEAD"))return{data:"",error:null};const W=wZ(R),ne={data:null,response:R,request:C};if(W==="json"||W==="text"){const H=await R.text(),Z=(i=C.jsonParser)!=null?i:sD;ne.data=await Z(H)}else ne.data=await R[W]();C?.output&&C.output&&!C.disableValidation&&(ne.data=await Jg(C.output,ne.data));for(const H of m.onSuccess)H&&await H(Ir(hr({},ne),{response:(l=t?.hookOptions)!=null&&l.cloneResponse?R.clone():R}));return t?.throw?ne.data:{data:ne.data,error:null}}const O=(c=t?.jsonParser)!=null?c:sD,L=await R.text(),$=TZ(L),B=$?await O(L):null,U={response:R,responseText:L,request:C,error:Ir(hr({},B),{status:R.status,statusText:R.statusText})};for(const j of m.onError)j&&await j(Ir(hr({},U),{response:(u=t?.hookOptions)!=null&&u.cloneResponse?R.clone():R}));if(t?.retry){const j=bZ(t.retry),W=(p=t.retryAttempt)!=null?p:0;if(await j.shouldAttemptRetry(W,R)){for(const H of m.onRetry)H&&await H(D);const ne=j.getDelay(W);return await new Promise(H=>setTimeout(H,ne)),await oT(e,Ir(hr({},t),{retryAttempt:W+1}))}}if(t?.throw)throw new gZ(R.status,R.statusText,$?B:L);return{data:null,error:Ir(hr({},B),{status:R.status,statusText:R.statusText})}};const MZ=(e,t)=>{const o="credentials"in Request.prototype,a=zY(e?.baseURL,e?.basePath)??"/api/auth",n=e?.plugins?.flatMap(C=>C.fetchPlugins).filter(C=>C!==void 0)||[],i={id:"lifecycle-hooks",name:"lifecycle-hooks",hooks:{onSuccess:e?.fetchOptions?.onSuccess,onError:e?.fetchOptions?.onError,onRequest:e?.fetchOptions?.onRequest,onResponse:e?.fetchOptions?.onResponse}},{onSuccess:l,onError:c,onRequest:u,onResponse:p,...m}=e?.fetchOptions||{},h=DZ({baseURL:a,...o?{credentials:"include"}:{},method:"GET",jsonParser(C){return C?KY(C,{strict:!1}):null},customFetchImpl:fetch,...m,plugins:[i,...m.plugins||[],...e?.disableDefaultFetchPlugins?[]:[UY],...n]}),{$sessionSignal:f,session:v}=sZ(h,e),b=e?.plugins||[];let S={};const _={$sessionSignal:f,session:v},T={"/sign-out":"POST","/revoke-sessions":"POST","/revoke-other-sessions":"POST","/delete-user":"POST"},x=[{signal:"$sessionSignal",matcher(C){return C==="/sign-out"||C==="/update-user"||C==="/sign-up/email"||C==="/sign-in/email"||C==="/delete-user"||C==="/verify-email"||C==="/revoke-sessions"||C==="/revoke-session"||C==="/change-email"}}];for(const C of b)C.getAtoms&&Object.assign(_,C.getAtoms?.(h)),C.pathMethods&&Object.assign(T,C.pathMethods),C.atomListeners&&x.push(...C.atomListeners);const P={notify:C=>{_[C].set(!_[C].get())},listen:(C,E)=>{_[C].subscribe(E)},atoms:_};for(const C of b)C.getActions&&(S=cZ(C.getActions?.(h,P,e)??{},S));return{get baseURL(){return a},pluginsActions:S,pluginsAtoms:_,pluginPathMethods:T,atomListeners:x,$fetch:h,$store:P}};function NZ(e){return typeof e=="object"&&e!==null&&"get"in e&&typeof e.get=="function"&&"lc"in e&&typeof e.lc=="number"}function IZ(e,t,o){const a=t[e],{fetchOptions:n,query:i,...l}=o||{};return a||(n?.method?n.method:l&&Object.keys(l).length>0?"POST":"GET")}function LZ(e,t,o,a,n){function i(l=[]){return new Proxy(function(){},{get(c,u){if(typeof u!="string"||u==="then"||u==="catch"||u==="finally")return;const p=[...l,u];let m=e;for(const h of p)if(m&&typeof m=="object"&&h in m)m=m[h];else{m=void 0;break}return typeof m=="function"||NZ(m)?m:i(p)},apply:async(c,u,p)=>{const m="/"+l.map(x=>x.replace(/[A-Z]/g,P=>`-${P.toLowerCase()}`)).join("/"),h=p[0]||{},f=p[1]||{},{query:v,fetchOptions:b,...S}=h,_={...f,...b},T=IZ(m,o,h);return await t(m,{..._,body:T==="GET"?void 0:{...S,..._?.body||{}},query:v||_?.query,method:T,async onSuccess(x){if(await _?.onSuccess?.(x),!n||_.disableSignal)return;const P=n.filter(E=>E.matcher(m));if(!P.length)return;const C=new Set;for(const E of P){const R=a[E.signal];if(!R)return;if(C.has(E.signal))continue;C.add(E.signal);const D=R.get();setTimeout(()=>{R.set(!D)},10)}}})}})}return i()}function BZ(e,t={}){const o=A.useRef(e.get()),{keys:a,deps:n=[e,a]}=t,i=A.useCallback(c=>{const u=p=>{o.current!==p&&(o.current=p,c())};return u(e.value),a?.length?XY(e,a,u):e.listen(u)},n),l=()=>o.current;return A.useSyncExternalStore(i,l,l)}function FZ(e){return`use${BY(e)}`}function jZ(e){const{pluginPathMethods:t,pluginsActions:o,pluginsAtoms:a,$fetch:n,$store:i,atomListeners:l}=MZ(e),c={};for(const[u,p]of Object.entries(a))c[FZ(u)]=()=>BZ(p);return LZ({...o,...c,$fetch:n,$store:i},n,t,a,l)}function zZ(e){return{authorize(t,o="AND"){let a=!1;for(const[n,i]of Object.entries(t)){const l=e[n];if(!l)return{success:!1,error:`You are not allowed to access resource: ${n}`};if(Array.isArray(i))a=i.every(c=>l.includes(c));else if(typeof i=="object"){const c=i;c.connector==="OR"?a=c.actions.some(u=>l.includes(u)):a=c.actions.every(u=>l.includes(u))}else throw new lp("Invalid access control request");if(a&&o==="OR")return{success:a};if(!a&&o==="AND")return{success:!1,error:`unauthorized to access resource "${n}"`}}return a?{success:a}:{success:!1,error:"Not authorized"}},statements:e}}function QI(e){return{newRole(t){return zZ(t)},statements:e}}const UZ={user:["create","list","set-role","ban","impersonate","delete","set-password","get","update"],session:["list","revoke","delete"]},JI=QI(UZ),XI=JI.newRole({user:["create","list","set-role","ban","impersonate","delete","set-password","get","update"],session:["list","revoke","delete"]}),eL=JI.newRole({user:[],session:[]}),$Z={admin:XI,user:eL},qZ=e=>{if(e.userId&&e.options?.adminUserIds?.includes(e.userId))return!0;if(!e.permissions&&!e.permission)return!1;const t=(e.role||e.options?.defaultRole||"user").split(","),o=e.options?.roles||$Z;for(const a of t)if(o[a]?.authorize(e.permission??e.permissions)?.success)return!0;return!1},VZ=e=>{const t={admin:XI,user:eL,...e?.roles};return{id:"admin-client",$InferServerPlugin:{},getActions:()=>({admin:{checkRolePermission:o=>qZ({role:o.role,options:{ac:e?.ac,roles:t},permissions:o.permissions??o.permission})}}),pathMethods:{"/admin/list-users":"GET","/admin/stop-impersonating":"POST"}}},HZ=()=>({id:"email-otp",$InferServerPlugin:{},atomListeners:[{matcher:e=>e==="/email-otp/verify-email"||e==="/sign-in/email-otp",signal:"$sessionSignal"}]}),GZ=()=>({id:"magic-link",$InferServerPlugin:{}}),WZ={organization:["update","delete"],member:["create","update","delete"],invitation:["create","cancel"],team:["create","update","delete"],ac:["create","read","update","delete"]},l_=QI(WZ),tL=l_.newRole({organization:["update"],invitation:["create","cancel"],member:["create","update","delete"],team:["create","update","delete"],ac:["create","read","update","delete"]}),oL=l_.newRole({organization:["update","delete"],member:["create","update","delete"],invitation:["create","cancel"],team:["create","update","delete"],ac:["create","read","update","delete"]}),aL=l_.newRole({organization:[],member:[],invitation:[],team:[],ac:["read"]}),KZ={admin:tL,owner:oL,member:aL},YZ=(e,t)=>{if(!e.permissions&&!e.permission)return!1;const o=e.role.split(","),a=e.options.creatorRole||"owner",n=o.includes(a),i=e.allowCreatorAllPermissions||!1;if(n&&i)return!0;for(const l of o)if(t[l]?.authorize(e.permissions??e.permission)?.success)return!0;return!1},ZZ=e=>YZ(e,e.options.roles||KZ),QZ=e=>{const t=Jc(!1),o=Jc(!1),a=Jc(!1),n=Jc(!1),i={admin:tL,member:aL,owner:oL,...e?.roles};return{id:"organization",$InferServerPlugin:{},getActions:(l,c,u)=>({$Infer:{ActiveOrganization:{},Organization:{},Invitation:{},Member:{},Team:{}},organization:{checkRolePermission:p=>ZZ({role:p.role,options:{ac:e?.ac,roles:i},permissions:p.permissions??p.permission})}}),getAtoms:l=>{const c=Zu(t,"/organization/list",l,{method:"GET"});return{$listOrg:t,$activeOrgSignal:o,$activeMemberSignal:a,$activeMemberRoleSignal:n,activeOrganization:Zu([o],"/organization/get-full-organization",l,()=>({method:"GET"})),listOrganizations:c,activeMember:Zu([a],"/organization/get-active-member",l,{method:"GET"}),activeMemberRole:Zu([n],"/organization/get-active-member-role",l,{method:"GET"})}},pathMethods:{"/organization/get-full-organization":"GET","/organization/list-user-teams":"GET"},atomListeners:[{matcher(l){return l==="/organization/create"||l==="/organization/delete"||l==="/organization/update"},signal:"$listOrg"},{matcher(l){return l.startsWith("/organization")},signal:"$activeOrgSignal"},{matcher(l){return l.startsWith("/organization/set-active")},signal:"$sessionSignal"},{matcher(l){return l.includes("/organization/update-member-role")},signal:"$activeMemberSignal"},{matcher(l){return l.includes("/organization/update-member-role")},signal:"$activeMemberRoleSignal"}]}},JZ="1.6.11",XZ=e=>({id:"sso-client",version:JZ,$InferServerPlugin:{},pathMethods:{"/sso/providers":"GET","/sso/get-provider":"GET"}});function eQ(e){let t=e;if(typeof e=="string")try{t=JSON.parse(e)}catch{return{}}return t&&typeof t=="object"&&!Array.isArray(t)?Object.fromEntries(Object.entries(t)):{}}function nL(e){return eQ(e?.metadata).archived===!0}const tQ="Organization is archived",Qp=jZ({plugins:[QZ({}),VZ(),XZ(),GZ(),HZ()]}),oQ=3e4;let Qu=null,xg=null;function rL(){if(Qu&&Qu.expiresAt>Date.now())return Promise.resolve(Qu.result);if(xg)return xg;const e=Qp.organization.list().then(t=>{const o=t.data?{...t,data:t.data.filter(a=>!nL(a))}:t;return o.data&&(Qu={result:o,expiresAt:Date.now()+oQ}),o}).finally(()=>{xg=null});return xg=e,e}function uve(){const e=Qp.useListOrganizations(),t=e.data?.filter(o=>!nL(o));return{...e,data:t}}function pve(){Qu=null}const aQ="modulepreload",nQ=function(e){return"/"+e},cD={},je=function(t,o,a){let n=Promise.resolve();if(o&&o.length>0){let l=function(p){return Promise.all(p.map(m=>Promise.resolve(m).then(h=>({status:"fulfilled",value:h}),h=>({status:"rejected",reason:h}))))};document.getElementsByTagName("link");const c=document.querySelector("meta[property=csp-nonce]"),u=c?.nonce||c?.getAttribute("nonce");n=l(o.map(p=>{if(p=nQ(p),p in cD)return;cD[p]=!0;const m=p.endsWith(".css"),h=m?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${p}"]${h}`))return;const f=document.createElement("link");if(f.rel=m?"stylesheet":aQ,m||(f.as="script"),f.crossOrigin="",f.href=p,u&&f.setAttribute("nonce",u),document.head.appendChild(f),m)return new Promise((v,b)=>{f.addEventListener("load",v),f.addEventListener("error",()=>b(Error(`Unable to preload CSS for ${p}`)))})}))}function i(l){const c=new Event("vite:preloadError",{cancelable:!0});if(c.payload=l,window.dispatchEvent(c),!c.defaultPrevented)throw l}return n.then(l=>{for(const c of l||[])c.status==="rejected"&&i(c.reason);return t().catch(i)})};function rQ(e){try{return JSON.parse(e)}catch{return}}function dD(e,t){if(typeof localStorage>"u")return typeof t=="function"?t(void 0):t;const o=localStorage.getItem(e),a=o?rQ(o):void 0,n=typeof t=="function"?t(a):a??t;if(a===void 0||n!==a)try{const i=JSON.stringify(n);localStorage.setItem(e,i)}catch{}return n}function iQ(e,t){const o=Re.c(25),a=vv();let n;o[0]!==e?(n=["localStorage",e],o[0]=e,o[1]=n):n=o[1];const i=n;let l,c;o[2]!==t||o[3]!==e?(l=()=>dD(e,t),c=()=>dD(e,t),o[2]=t,o[3]=e,o[4]=l,o[5]=c):(l=o[4],c=o[5]);let u;o[6]!==i||o[7]!==l||o[8]!==c?(u={queryKey:i,queryFn:l,initialData:c,staleTime:1/0,gcTime:1/0},o[6]=i,o[7]=l,o[8]=c,o[9]=u):u=o[9];const{data:p}=Rd(u);let m;o[10]!==e?(m=async x=>(typeof localStorage<"u"&&localStorage.setItem(e,JSON.stringify(x)),x),o[10]=e,o[11]=m):m=o[11];let h;o[12]!==a||o[13]!==i?(h=x=>{a.setQueryData(i,x)},o[12]=a,o[13]=i,o[14]=h):h=o[14];let f;o[15]!==m||o[16]!==h?(f={mutationFn:m,onSuccess:h},o[15]=m,o[16]=h,o[17]=f):f=o[17];const v=sp(f);let b;o[18]!==v||o[19]!==a||o[20]!==i?(b=x=>{const P=a.getQueryData(i),C=typeof x=="function"?x(P):x;v.mutate(C)},o[18]=v,o[19]=a,o[20]=i,o[21]=b):b=o[21];const S=b,_=p;let T;return o[22]!==S||o[23]!==_?(T=[_,S],o[22]=S,o[23]=_,o[24]=T):T=o[24],T}const Bl={chatSelectedImageModel:e=>`studio:chat:selectedImageModel:${e}`,chatSelectedWebSearchModel:e=>`studio:chat:selectedWebSearchModel:${e}`,chatSelectedDeepResearchModel:e=>`studio:chat:selectedDeepResearchModel:${e}`,chatSimpleModeTier:e=>`studio:chat:simpleModeTier:${e}`,chatAutosend:(e,t)=>`studio:chat:autosend:${e}:${t}`,chatThreadIntent:(e,t)=>`studio:chat:threadIntent:${e}:${t}`,homeTaskMode:e=>`home-task-mode:${e}`,chatDraft:(e,t)=>`studio:chat:draft:${e}:${t}`,taskBoardPrs:e=>`studio:task-board-prs:${e}`,taskFeedBehindTheScenes:()=>"studio:task-feed:behind-the-scenes",taskBoardAssignee:(e,t)=>`studio:task-board-assignee:${e}:${t}`,recentApps:e=>`studio:recent-apps:${e}`,appOpens:e=>`studio:app-opens:${e}`,recentOrgs:()=>"studio:recent-orgs",railOrgPrefs:()=>"studio:rail-org-prefs",sidePanelWidth:()=>"studio:side-panel:width",sidebarOpen:()=>"studio:sidebar-open",preferences:()=>"studio:user:preferences",lastOrgSlug:()=>"studio:last-org-slug",lastLocation:()=>"studio:last-location",connectionsTab:e=>`studio:connections:tab:${e}`,taskLastViewed:e=>`studio:chat:task-last-viewed:${e}`,sidebarGroupOrder:(e,t)=>`sidebar.group-order.${e}.${t}`,sidebarSectionOpen:(e,t)=>`studio:sidebar:section-open:${e}:${t}`,ptBrAnnouncementSeen:e=>`studio:announcement:pt-br:${e}`,cmsTourSeen:e=>`studio:cms-tour:seen:${e}`,localPreviewUrl:e=>`studio:local-preview-url:${e}`},iL=["en","pt-BR"];function c_(){return typeof navigator<"u"&&navigator.language?.toLowerCase().startsWith("pt")?"pt-BR":"en"}const sQ={toolApprovalLevel:"auto",enableNotifications:typeof Notification<"u",enableSounds:!1,theme:"system",language:c_(),shownTaskBoardLanes:[],collapsedTaskBoardLanes:[],projectFirstNav:!1},sL=["auto","readonly"],mve=[{value:"readonly",labelKey:"settings.preferences.toolApprovalAsk",shortKey:"settings.preferences.toolApprovalAskShort"},{value:"auto",labelKey:"settings.preferences.toolApprovalAuto",shortKey:"settings.preferences.toolApprovalAutoShort"}],lQ=["light","dark","system"];function hve(){try{const e=JSON.parse(localStorage.getItem(Bl.preferences())??"{}");if(sL.includes(e.toolApprovalLevel))return e.toolApprovalLevel}catch{}return"auto"}function cQ(){try{const e=JSON.parse(localStorage.getItem(Bl.preferences())??"{}");if(iL.includes(e.language))return e.language}catch{}return c_()}function d_(){const e=Re.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=Bl.preferences(),e[0]=t):t=e[0],iQ(t,dQ)}function dQ(e){const t={...sQ,...e};return"showProjectSettingsGear"in t&&delete t.showProjectSettingsGear,"compactPageLayout"in t&&delete t.compactPageLayout,sL.includes(t.toolApprovalLevel)||(t.toolApprovalLevel="auto"),lQ.includes(t.theme)||(t.theme="system"),iL.includes(t.language)||(t.language=c_()),Array.isArray(t.shownTaskBoardLanes)||(t.shownTaskBoardLanes=[]),Array.isArray(t.collapsedTaskBoardLanes)||(t.collapsedTaskBoardLanes=[]),t.projectFirstNav=t.projectFirstNav===!0,t}function gve(){const[e]=d_();return e.projectFirstNav}const uQ={"page.overview":"Overview","page.app":"App","page.view":"View","page.file":"File","page.document":"Document","page.item":"Item","page.breadcrumbs":"Breadcrumbs","page.breadcrumbMenu":"Show navigation path","page.views":"Page views","page.openThread":"Open chat","page.closeThread":"Close chat","page.collapseSidebar":"Collapse sidebar","page.expandSidebar":"Expand sidebar"},pQ={"projects.platform.vtex":"VTEX","projects.platform.shopify":"Shopify","projects.platform.wake":"Wake","projects.platform.nuvemshop":"Nuvemshop","projects.platform.linx":"Linx","projects.platform.vnda":"VNDA","projects.home.newProject":"New project","projects.card.updated":"Updated {time}","projects.empty.title":"Your commerce, one project at a time","projects.empty.description":"A site, an app, a store. Each one keeps its own connections, report and board.","projects.empty.readOnly":"Ask an admin to create the first project.","projects.new.title":"New project","projects.new.subtitle":"What are you setting up?","projects.new.back":"Back","projects.new.create":"Create project","projects.new.creating":"Creating…","projects.new.nameLabel":"Project name","projects.new.namePlaceholder":"Farm web","projects.new.nameRequired":"Give the project a name","projects.new.failed":"Couldn't create the project","projects.new.created":"{title} is ready","projects.new.path.repository":"Import a codebase","projects.new.path.repository.hint":"Bring a storefront or app codebase in","projects.new.path.folder":"New project folder","projects.new.path.folder.hint":"Name it now, connect it later","projects.new.step.folder.title":"Name your project","projects.reports.chooserTitle":"Continue to Reports","projects.reports.chooserSubtitle":"Choose a project to continue","projects.reports.chooserSearch":"Find project…","projects.reports.chooserEmpty":"No project by that name.","projects.reports.status.ready":"Ready","projects.reports.status.running":"Running","projects.reports.status.none":"Not run","projects.reports.status.locked":"Locked","projects.connections.orgWide":"Organization-wide","projects.connections.usedBy":"{count} projects","projects.settings.title":"Projects","projects.settings.description":"Everything scoped to a project lives here: its repositories, connections, report and board.","projects.settings.searchPlaceholder":"Search projects…","projects.settings.open":"Open","projects.settings.openSettings":"Settings","projects.settings.orgScopeNote":"Members, billing, security and AI providers stay organization-wide.","projects.settings.noResults":"No projects match “{search}”","projects.identity.storeUrlLabel":"Store URL","projects.identity.storeUrlDescription":"The live storefront. Reports run against this address.","projects.flat.viewProject":"Project","projects.flat.viewFiles":"Files","projects.flat.viewAnalytics":"Analytics","projects.apps.heading":"Apps","projects.apps.seeAll":"See all","projects.apps.showLess":"Show less","projects.apps.reports":"Report","projects.apps.reportsCaption":"What is wrong with the storefront","projects.apps.siteEditor":"Site editor","projects.apps.siteEditorCaption":"Pages, sections and content","projects.apps.assets":"Assets","projects.apps.assetsCaption":"Images and files the site uses","projects.apps.hosting":"Hosting","projects.apps.hostingCaption":"Deploys, domains and environments","projects.apps.e2e":"End-to-end tests","projects.apps.e2eCaption":"Flows checked on every change","projects.apps.analytics":"Analytics","projects.apps.analyticsCaption":"Traffic, conversion and revenue","projects.apps.cdn":"Monitor","projects.apps.cdnCaption":"Cache, latency and errors","projects.apps.automations":"Automations","projects.apps.automationsCaption":"Work that runs on a schedule","projects.apps.experiments":"Experiments","projects.apps.experimentsCaption":"A/B tests and their results","projects.flat.close":"Close"},mQ={"virtualMcp.addConnectionDialog.addConnectionTitle":"Add Connection","virtualMcp.addConnectionDialog.authenticationFailedError":"Authentication failed: {error}","virtualMcp.addConnectionDialog.connected":"Connected","virtualMcp.addConnectionDialog.connectedAuthenticated":"Connected and authenticated","virtualMcp.addConnectionDialog.connectionsTitle":"Connections","virtualMcp.addConnectionDialog.failedToAddConnection":"Failed to add connection","virtualMcp.addConnectionDialog.failedToConnect":"Failed to connect","virtualMcp.addConnectionDialog.mcpServerConnectionError":"This MCP Server cannot be connected: no connection method available","virtualMcp.addConnectionDialog.searchConnectionsPlaceholder":"Search connections...","virtualMcp.addConnectionDialog.signInFailedDescription":"It was added to your project, but its sign-in setup looks off. You can try authenticating again later from the connection's settings. ({error})","virtualMcp.addConnectionDialog.signInFailedTitle":"Couldn't sign in to this connection","virtualMcp.connectionDialogContent.add":"Add","virtualMcp.connectionDialogContent.added":"Added","virtualMcp.connectionDialogContent.builtByDeco":"Built and maintained by Deco","virtualMcp.connectionDialogContent.builtByOfficial":"Built and maintained by the official vendor","virtualMcp.connectionDialogContent.connect":"Connect","virtualMcp.connectionDialogContent.connected":"Connected","virtualMcp.connectionDialogContent.customConnection":"Custom Connection","virtualMcp.connectionDialogContent.emptyStateNoConnectionsAvailable":"No connections available","virtualMcp.connectionDialogContent.emptyStateNoConnectionsYet":"No connections yet","virtualMcp.connectionDialogContent.emptyStateSearchNoMatch":'No connections match "{search}"',"virtualMcp.connectionDialogContent.madeByDeco":"Made by Deco","virtualMcp.connectionDialogContent.sectionAllConnections":"All connections","virtualMcp.connectionDialogContent.sectionVerified":"Verified","virtualMcp.connectionDialogContent.tabAll":"All","virtualMcp.connectionDialogContent.tabConnected":"Connected","virtualMcp.connectionDialogContent.verifiedByDeco":"Verified by the Deco team","virtualMcp.connectionItem.authorize":"Authorize","virtualMcp.connectionItem.configureResources":"Configure resources","virtualMcp.connectionItem.connectionDisabled":"Connection disabled","virtualMcp.connectionItem.connectionEnabled":"Connection enabled","virtualMcp.connectionItem.connectionNotFound":"Connection not found","virtualMcp.connectionItem.connectionSettings":"Connection settings","virtualMcp.connectionItem.disable":"Disable","virtualMcp.connectionItem.disableConnection":"Disable connection","virtualMcp.connectionItem.disabled":"Disabled","virtualMcp.connectionItem.disabledError":"Disabled (error)","virtualMcp.connectionItem.enable":"Enable","virtualMcp.connectionItem.failedToUpdateConnection":"Failed to update connection","virtualMcp.connectionItem.needsAuthorization":"Needs authorization","virtualMcp.connectionItem.newInstance":"New instance","virtualMcp.connectionItem.remove":"Remove","virtualMcp.connectionItem.removeConnection":"Remove connection","virtualMcp.dependencySelectionDialog.authorizationDescription":"This connection needs to be authorized before you can configure its tools and resources.","virtualMcp.dependencySelectionDialog.authorizationRequired":"Authorization required","virtualMcp.dependencySelectionDialog.authorize":"Authorize","virtualMcp.dependencySelectionDialog.deselectAll":"Deselect all","virtualMcp.dependencySelectionDialog.done":"Done","virtualMcp.dependencySelectionDialog.noActiveToolsSelected":"No active tools selected","virtualMcp.dependencySelectionDialog.noPromptsAvailable":"No prompts available","virtualMcp.dependencySelectionDialog.noResourcesAvailable":"No resources available","virtualMcp.dependencySelectionDialog.noToolsAvailable":"No tools available","virtualMcp.dependencySelectionDialog.promptsNotSupported":"Prompts not supported by this server","virtualMcp.dependencySelectionDialog.resourcesNotSupported":"Resources not supported by this server","virtualMcp.dependencySelectionDialog.selectAll":"Select all","virtualMcp.dependencySelectionDialog.somethingWentWrong":"Something went wrong","virtualMcp.dependencySelectionDialog.tabActive":"Active","virtualMcp.dependencySelectionDialog.tabPrompts":"Prompts","virtualMcp.dependencySelectionDialog.tabResources":"Resources","virtualMcp.dependencySelectionDialog.tabTools":"Tools","virtualMcp.dependencySelectionDialog.toolsNotSupported":"Tools not supported by this server","virtualMcp.dependencySelectionDialog.unexpectedError":"An unexpected error occurred","virtualMcp.filesSection.add":"Add","virtualMcp.filesSection.description":"Attach files and skills the project can always reference.","virtualMcp.filesSection.failedUploadFile":"Failed to upload file.","virtualMcp.filesSection.fileTooLargeDescription":"Exceeds the 25MB limit, not uploaded: {names}","virtualMcp.filesSection.fileTooLargeTitle":"File too large","virtualMcp.filesSection.filesAndSkills":"Files and skills","virtualMcp.filesSection.kindFile":"File","virtualMcp.filesSection.kindSkill":"Skill","virtualMcp.filesSection.noFilesFound":"No files found.","virtualMcp.filesSection.noFilesOrSkillsYet":"No files or skills yet. Add one or drag and drop here.","virtualMcp.filesSection.noSkillsFound":"No skills found.","virtualMcp.filesSection.removeAriaLabel":"Remove {name}","virtualMcp.filesSection.searchFilesPlaceholder":"Search files...","virtualMcp.filesSection.searchSkillsPlaceholder":"Search skills...","virtualMcp.filesSection.selectFileOrFolder":"Select file or folder","virtualMcp.filesSection.selectSkill":"Select skill","virtualMcp.filesSection.uploadFile":"Upload file","virtualMcp.layoutTabContent.noMainView":"No main view","virtualMcp.layoutTabContent.automations":"Automations","virtualMcp.layoutTabContent.chatAlwaysShown":"Chat is always shown when it is the default view","virtualMcp.layoutTabContent.layout":"Layout","virtualMcp.layoutTabContent.mainView":"Main view","virtualMcp.layoutTabContent.mainViewDescription":"What users see when they first open this project.","virtualMcp.layoutTabContent.settings":"Settings","virtualMcp.layoutTabContent.showChat":"Show chat","virtualMcp.layoutTabContent.showChatDescription":"Display Chat in the side panel alongside the main view.","virtualMcp.layoutTabContent.siteEditor":"Site Editor","virtualMcp.settings.title":"Project settings","virtualMcp.settings.navigation":"Project settings sections","virtualMcp.settings.identity.icon":"Project icon","virtualMcp.settings.identity.iconDescription":"How your project appears in the sidebar and across Studio.","virtualMcp.settings.identity.name":"Project name","virtualMcp.settings.identity.description":"Description","virtualMcp.settings.general.title":"General","virtualMcp.settings.site.title":"CMS","virtualMcp.settings.site.classicTitle":"Site and sandbox","virtualMcp.settings.groups.advanced":"Advanced","virtualMcp.settings.connections.title":"Connections","virtualMcp.settings.views.defaults":"Default layout","virtualMcp.settings.views.sidebar":"Views","virtualMcp.settings.views.open":"Open","virtualMcp.settings.views.pin":"Pin to sidebar","virtualMcp.settings.views.unpin":"Remove from sidebar","virtualMcp.settings.views.setMainView":"Set as main view","virtualMcp.settings.views.rowActions":"View options","virtualMcp.subAgentsSection.addSubAgent":"Add sub-project","virtualMcp.subAgentsSection.anyAgent":"Any project","virtualMcp.subAgentsSection.canDelegateToAnyAgent":"Can delegate to any project in the organization.","virtualMcp.subAgentsSection.canOnlyDelegateToItself":"Can only delegate to a fresh copy of itself, no other projects.","virtualMcp.subAgentsSection.emptyStateMessage":"No sub-projects selected yet. Add one — until then this project can only delegate to itself.","virtualMcp.subAgentsSection.noAgentsFound":"No projects found.","virtualMcp.subAgentsSection.onlyItself":"Only itself","virtualMcp.subAgentsSection.searchPlaceholder":"Search projects...","virtualMcp.subAgentsSection.specificAgents":"Specific projects","virtualMcp.subAgentsSection.title":"Sub-projects","virtualMcp.virtualMcp.addConnection":"Add connection","virtualMcp.virtualMcp.agentDeleted":'Deleted "{title}"',"virtualMcp.virtualMcp.agentNameFallback":"Agent","virtualMcp.virtualMcp.agentNamePlaceholder":"Project name","virtualMcp.virtualMcp.authenticationFailed":"Authentication failed: {error}","virtualMcp.virtualMcp.authenticationSuccessful":"Authentication successful","virtualMcp.virtualMcp.backToSpaces":"Back to spaces","virtualMcp.virtualMcp.cancel":"Cancel","virtualMcp.virtualMcp.connect":"Connect","virtualMcp.virtualMcp.connections":"Connections","virtualMcp.virtualMcp.created":"Created","virtualMcp.virtualMcp.delete":"Delete","virtualMcp.virtualMcp.deleteAgent":"Delete project","virtualMcp.virtualMcp.deleteAgentConfirm":"Delete Project?","virtualMcp.virtualMcp.deleteAgentConfirmDescription":"This action cannot be undone. This will permanently delete {title}.","virtualMcp.virtualMcp.deleteAgentDescription":"Permanently delete this project and all its data.","virtualMcp.virtualMcp.descriptionPlaceholder":"Add a description...","virtualMcp.virtualMcp.failedToCreateInstance":"Failed to create instance","virtualMcp.virtualMcp.fullscreen":"Fullscreen","virtualMcp.virtualMcp.improve":"Improve","virtualMcp.virtualMcp.instanceAlreadyAdded":"This instance is already added to the project","virtualMcp.virtualMcp.instructions":"Instructions","virtualMcp.virtualMcp.instructionsPlaceholder":"Define how this agent should behave, what tone to use, any constraints or guidelines...","virtualMcp.virtualMcp.lastUsed":"Last used {time}","virtualMcp.virtualMcp.neverUsed":"Never used","virtualMcp.virtualMcp.newInstanceCreated":"New instance created","virtualMcp.virtualMcp.noConnectionsYet":"No connections yet. Add one to get started.","virtualMcp.virtualMcp.openFullscreenEditor":"Open fullscreen editor","virtualMcp.virtualMcp.promptTemplate":"+ Prompt template","virtualMcp.virtualMcp.promptTemplateContent":`<role>
55
+ deps: ${m}}`};const n={keyword:"dependencies",type:"object",schemaType:"object",error:e.error,code(u){const[p,m]=i(u);l(u,p),c(u,m)}};function i({schema:u}){const p={},m={};for(const h in u){if(h==="__proto__")continue;const f=Array.isArray(u[h])?p:m;f[h]=u[h]}return[p,m]}function l(u,p=u.schema){const{gen:m,data:h,it:f}=u;if(Object.keys(p).length===0)return;const v=m.let("missing");for(const b in p){const S=p[b];if(S.length===0)continue;const _=(0,a.propertyInData)(m,h,b,f.opts.ownProperties);u.setParams({property:b,depsCount:S.length,deps:S.join(", ")}),f.allErrors?m.if(_,()=>{for(const T of S)(0,a.checkReportMissingProp)(u,T)}):(m.if((0,t._)`${_} && (${(0,a.checkMissingProp)(u,S,v)})`),(0,a.reportMissingProp)(u,v),m.else())}}e.validatePropertyDeps=l;function c(u,p=u.schema){const{gen:m,data:h,keyword:f,it:v}=u,b=m.name("valid");for(const S in p)(0,o.alwaysValidSchema)(v,p[S])||(m.if((0,a.propertyInData)(m,h,S,v.opts.ownProperties),()=>{const _=u.subschema({keyword:f,schemaProp:S},b);u.mergeValidEvaluated(_,b)},()=>m.var(b,!0)),u.ok(b))}e.validateSchemaDeps=c,e.default=n})(KS)),KS}var ig={},OR;function qK(){if(OR)return ig;OR=1,Object.defineProperty(ig,"__esModule",{value:!0});const e=yt(),t=Lt(),a={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:{message:"property name must be valid",params:({params:n})=>(0,e._)`{propertyName: ${n.propertyName}}`},code(n){const{gen:i,schema:l,data:c,it:u}=n;if((0,t.alwaysValidSchema)(u,l))return;const p=i.name("valid");i.forIn("key",c,m=>{n.setParams({propertyName:m}),n.subschema({keyword:"propertyNames",data:m,dataTypes:["string"],propertyName:m,compositeRule:!0},p),i.if((0,e.not)(p),()=>{n.error(!0),u.allErrors||i.break()})}),n.ok(p)}};return ig.default=a,ig}var sg={},MR;function zI(){if(MR)return sg;MR=1,Object.defineProperty(sg,"__esModule",{value:!0});const e=kr(),t=yt(),o=js(),a=Lt(),i={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:{message:"must NOT have additional properties",params:({params:l})=>(0,t._)`{additionalProperty: ${l.additionalProperty}}`},code(l){const{gen:c,schema:u,parentSchema:p,data:m,errsCount:h,it:f}=l;if(!h)throw new Error("ajv implementation error");const{allErrors:v,opts:b}=f;if(f.props=!0,b.removeAdditional!=="all"&&(0,a.alwaysValidSchema)(f,u))return;const S=(0,e.allSchemaProperties)(p.properties),_=(0,e.allSchemaProperties)(p.patternProperties);T(),l.ok((0,t._)`${h} === ${o.default.errors}`);function T(){c.forIn("key",m,R=>{!S.length&&!_.length?C(R):c.if(x(R),()=>C(R))})}function x(R){let D;if(S.length>8){const O=(0,a.schemaRefOrVal)(f,p.properties,"properties");D=(0,e.isOwnProperty)(c,O,R)}else S.length?D=(0,t.or)(...S.map(O=>(0,t._)`${R} === ${O}`)):D=t.nil;return _.length&&(D=(0,t.or)(D,..._.map(O=>(0,t._)`${(0,e.usePattern)(l,O)}.test(${R})`))),(0,t.not)(D)}function P(R){c.code((0,t._)`delete ${m}[${R}]`)}function C(R){if(b.removeAdditional==="all"||b.removeAdditional&&u===!1){P(R);return}if(u===!1){l.setParams({additionalProperty:R}),l.error(),v||c.break();return}if(typeof u=="object"&&!(0,a.alwaysValidSchema)(f,u)){const D=c.name("valid");b.removeAdditional==="failing"?(E(R,D,!1),c.if((0,t.not)(D),()=>{l.reset(),P(R)})):(E(R,D),v||c.if((0,t.not)(D),()=>c.break()))}}function E(R,D,O){const L={keyword:"additionalProperties",dataProp:R,dataPropType:a.Type.Str};O===!1&&Object.assign(L,{compositeRule:!0,createErrors:!1,allErrors:!1}),l.subschema(L,D)}}};return sg.default=i,sg}var lg={},NR;function VK(){if(NR)return lg;NR=1,Object.defineProperty(lg,"__esModule",{value:!0});const e=Dv(),t=kr(),o=Lt(),a=zI(),n={keyword:"properties",type:"object",schemaType:"object",code(i){const{gen:l,schema:c,parentSchema:u,data:p,it:m}=i;m.opts.removeAdditional==="all"&&u.additionalProperties===void 0&&a.default.code(new e.KeywordCxt(m,a.default,"additionalProperties"));const h=(0,t.allSchemaProperties)(c);for(const _ of h)m.definedProperties.add(_);m.opts.unevaluated&&h.length&&m.props!==!0&&(m.props=o.mergeEvaluated.props(l,(0,o.toHash)(h),m.props));const f=h.filter(_=>!(0,o.alwaysValidSchema)(m,c[_]));if(f.length===0)return;const v=l.name("valid");for(const _ of f)b(_)?S(_):(l.if((0,t.propertyInData)(l,p,_,m.opts.ownProperties)),S(_),m.allErrors||l.else().var(v,!0),l.endIf()),i.it.definedProperties.add(_),i.ok(v);function b(_){return m.opts.useDefaults&&!m.compositeRule&&c[_].default!==void 0}function S(_){i.subschema({keyword:"properties",schemaProp:_,dataProp:_},v)}}};return lg.default=n,lg}var cg={},IR;function HK(){if(IR)return cg;IR=1,Object.defineProperty(cg,"__esModule",{value:!0});const e=kr(),t=yt(),o=Lt(),a=Lt(),n={keyword:"patternProperties",type:"object",schemaType:"object",code(i){const{gen:l,schema:c,data:u,parentSchema:p,it:m}=i,{opts:h}=m,f=(0,e.allSchemaProperties)(c),v=f.filter(C=>(0,o.alwaysValidSchema)(m,c[C]));if(f.length===0||v.length===f.length&&(!m.opts.unevaluated||m.props===!0))return;const b=h.strictSchema&&!h.allowMatchingProperties&&p.properties,S=l.name("valid");m.props!==!0&&!(m.props instanceof t.Name)&&(m.props=(0,a.evaluatedPropsToName)(l,m.props));const{props:_}=m;T();function T(){for(const C of f)b&&x(C),m.allErrors?P(C):(l.var(S,!0),P(C),l.if(S))}function x(C){for(const E in b)new RegExp(C).test(E)&&(0,o.checkStrictMode)(m,`property ${E} matches pattern ${C} (use allowMatchingProperties)`)}function P(C){l.forIn("key",u,E=>{l.if((0,t._)`${(0,e.usePattern)(i,C)}.test(${E})`,()=>{const R=v.includes(C);R||i.subschema({keyword:"patternProperties",schemaProp:C,dataProp:E,dataPropType:a.Type.Str},S),m.opts.unevaluated&&_!==!0?l.assign((0,t._)`${_}[${E}]`,!0):!R&&!m.allErrors&&l.if((0,t.not)(S),()=>l.break())})})}}};return cg.default=n,cg}var dg={},LR;function GK(){if(LR)return dg;LR=1,Object.defineProperty(dg,"__esModule",{value:!0});const e=Lt(),t={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(o){const{gen:a,schema:n,it:i}=o;if((0,e.alwaysValidSchema)(i,n)){o.fail();return}const l=a.name("valid");o.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},l),o.failResult(l,()=>o.reset(),()=>o.error())},error:{message:"must NOT be valid"}};return dg.default=t,dg}var ug={},BR;function WK(){if(BR)return ug;BR=1,Object.defineProperty(ug,"__esModule",{value:!0});const t={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:kr().validateUnion,error:{message:"must match a schema in anyOf"}};return ug.default=t,ug}var pg={},FR;function KK(){if(FR)return pg;FR=1,Object.defineProperty(pg,"__esModule",{value:!0});const e=yt(),t=Lt(),a={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:{message:"must match exactly one schema in oneOf",params:({params:n})=>(0,e._)`{passingSchemas: ${n.passing}}`},code(n){const{gen:i,schema:l,parentSchema:c,it:u}=n;if(!Array.isArray(l))throw new Error("ajv implementation error");if(u.opts.discriminator&&c.discriminator)return;const p=l,m=i.let("valid",!1),h=i.let("passing",null),f=i.name("_valid");n.setParams({passing:h}),i.block(v),n.result(m,()=>n.reset(),()=>n.error(!0));function v(){p.forEach((b,S)=>{let _;(0,t.alwaysValidSchema)(u,b)?i.var(f,!0):_=n.subschema({keyword:"oneOf",schemaProp:S,compositeRule:!0},f),S>0&&i.if((0,e._)`${f} && ${m}`).assign(m,!1).assign(h,(0,e._)`[${h}, ${S}]`).else(),i.if(f,()=>{i.assign(m,!0),i.assign(h,S),_&&n.mergeEvaluated(_,e.Name)})})}}};return pg.default=a,pg}var mg={},jR;function YK(){if(jR)return mg;jR=1,Object.defineProperty(mg,"__esModule",{value:!0});const e=Lt(),t={keyword:"allOf",schemaType:"array",code(o){const{gen:a,schema:n,it:i}=o;if(!Array.isArray(n))throw new Error("ajv implementation error");const l=a.name("valid");n.forEach((c,u)=>{if((0,e.alwaysValidSchema)(i,c))return;const p=o.subschema({keyword:"allOf",schemaProp:u},l);o.ok(l),o.mergeEvaluated(p)})}};return mg.default=t,mg}var hg={},zR;function ZK(){if(zR)return hg;zR=1,Object.defineProperty(hg,"__esModule",{value:!0});const e=yt(),t=Lt(),a={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:{message:({params:i})=>(0,e.str)`must match "${i.ifClause}" schema`,params:({params:i})=>(0,e._)`{failingKeyword: ${i.ifClause}}`},code(i){const{gen:l,parentSchema:c,it:u}=i;c.then===void 0&&c.else===void 0&&(0,t.checkStrictMode)(u,'"if" without "then" and "else" is ignored');const p=n(u,"then"),m=n(u,"else");if(!p&&!m)return;const h=l.let("valid",!0),f=l.name("_valid");if(v(),i.reset(),p&&m){const S=l.let("ifClause");i.setParams({ifClause:S}),l.if(f,b("then",S),b("else",S))}else p?l.if(f,b("then")):l.if((0,e.not)(f),b("else"));i.pass(h,()=>i.error(!0));function v(){const S=i.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},f);i.mergeEvaluated(S)}function b(S,_){return()=>{const T=i.subschema({keyword:S},f);l.assign(h,f),i.mergeValidEvaluated(T,h),_?l.assign(_,(0,e._)`${S}`):i.setParams({ifClause:S})}}}};function n(i,l){const c=i.schema[l];return c!==void 0&&!(0,t.alwaysValidSchema)(i,c)}return hg.default=a,hg}var gg={},UR;function QK(){if(UR)return gg;UR=1,Object.defineProperty(gg,"__esModule",{value:!0});const e=Lt(),t={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:o,parentSchema:a,it:n}){a.if===void 0&&(0,e.checkStrictMode)(n,`"${o}" without "if" is ignored`)}};return gg.default=t,gg}var $R;function JK(){if($R)return og;$R=1,Object.defineProperty(og,"__esModule",{value:!0});const e=FI(),t=jK(),o=jI(),a=zK(),n=UK(),i=$K(),l=qK(),c=zI(),u=VK(),p=HK(),m=GK(),h=WK(),f=KK(),v=YK(),b=ZK(),S=QK();function _(T=!1){const x=[m.default,h.default,f.default,v.default,b.default,S.default,l.default,c.default,i.default,u.default,p.default];return T?x.push(t.default,a.default):x.push(e.default,o.default),x.push(n.default),x}return og.default=_,og}var fg={},vg={},qR;function XK(){if(qR)return vg;qR=1,Object.defineProperty(vg,"__esModule",{value:!0});const e=yt(),o={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:{message:({schemaCode:a})=>(0,e.str)`must match format "${a}"`,params:({schemaCode:a})=>(0,e._)`{format: ${a}}`},code(a,n){const{gen:i,data:l,$data:c,schema:u,schemaCode:p,it:m}=a,{opts:h,errSchemaPath:f,schemaEnv:v,self:b}=m;if(!h.validateFormats)return;c?S():_();function S(){const T=i.scopeValue("formats",{ref:b.formats,code:h.code.formats}),x=i.const("fDef",(0,e._)`${T}[${p}]`),P=i.let("fType"),C=i.let("format");i.if((0,e._)`typeof ${x} == "object" && !(${x} instanceof RegExp)`,()=>i.assign(P,(0,e._)`${x}.type || "string"`).assign(C,(0,e._)`${x}.validate`),()=>i.assign(P,(0,e._)`"string"`).assign(C,x)),a.fail$data((0,e.or)(E(),R()));function E(){return h.strictSchema===!1?e.nil:(0,e._)`${p} && !${C}`}function R(){const D=v.$async?(0,e._)`(${x}.async ? await ${C}(${l}) : ${C}(${l}))`:(0,e._)`${C}(${l})`,O=(0,e._)`(typeof ${C} == "function" ? ${D} : ${C}.test(${l}))`;return(0,e._)`${C} && ${C} !== true && ${P} === ${n} && !${O}`}}function _(){const T=b.formats[u];if(!T){E();return}if(T===!0)return;const[x,P,C]=R(T);x===n&&a.pass(D());function E(){if(h.strictSchema===!1){b.logger.warn(O());return}throw new Error(O());function O(){return`unknown format "${u}" ignored in schema at path "${f}"`}}function R(O){const L=O instanceof RegExp?(0,e.regexpCode)(O):h.code.formats?(0,e._)`${h.code.formats}${(0,e.getProperty)(u)}`:void 0,$=i.scopeValue("formats",{key:u,ref:O,code:L});return typeof O=="object"&&!(O instanceof RegExp)?[O.type||"string",O.validate,(0,e._)`${$}.validate`]:["string",O,$]}function D(){if(typeof T=="object"&&!(T instanceof RegExp)&&T.async){if(!v.$async)throw new Error("async format in sync schema");return(0,e._)`await ${C}(${l})`}return typeof P=="function"?(0,e._)`${C}(${l})`:(0,e._)`${C}.test(${l})`}}}};return vg.default=o,vg}var VR;function eY(){if(VR)return fg;VR=1,Object.defineProperty(fg,"__esModule",{value:!0});const t=[XK().default];return fg.default=t,fg}var ll={},HR;function tY(){return HR||(HR=1,Object.defineProperty(ll,"__esModule",{value:!0}),ll.contentVocabulary=ll.metadataVocabulary=void 0,ll.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"],ll.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]),ll}var GR;function oY(){if(GR)return zh;GR=1,Object.defineProperty(zh,"__esModule",{value:!0});const e=CK(),t=FK(),o=JK(),a=eY(),n=tY(),i=[e.default,t.default,(0,o.default)(),a.default,n.metadataVocabulary,n.contentVocabulary];return zh.default=i,zh}var bg={},Ou={},WR;function aY(){if(WR)return Ou;WR=1,Object.defineProperty(Ou,"__esModule",{value:!0}),Ou.DiscrError=void 0;var e;return(function(t){t.Tag="tag",t.Mapping="mapping"})(e||(Ou.DiscrError=e={})),Ou}var KR;function nY(){if(KR)return bg;KR=1,Object.defineProperty(bg,"__esModule",{value:!0});const e=yt(),t=aY(),o=a_(),a=Ov(),n=Lt(),l={keyword:"discriminator",type:"object",schemaType:"object",error:{message:({params:{discrError:c,tagName:u}})=>c===t.DiscrError.Tag?`tag "${u}" must be string`:`value of tag "${u}" must be in oneOf`,params:({params:{discrError:c,tag:u,tagName:p}})=>(0,e._)`{error: ${c}, tag: ${p}, tagValue: ${u}}`},code(c){const{gen:u,data:p,schema:m,parentSchema:h,it:f}=c,{oneOf:v}=h;if(!f.opts.discriminator)throw new Error("discriminator: requires discriminator option");const b=m.propertyName;if(typeof b!="string")throw new Error("discriminator: requires propertyName");if(m.mapping)throw new Error("discriminator: mapping is not supported");if(!v)throw new Error("discriminator: requires oneOf keyword");const S=u.let("valid",!1),_=u.const("tag",(0,e._)`${p}${(0,e.getProperty)(b)}`);u.if((0,e._)`typeof ${_} == "string"`,()=>T(),()=>c.error(!1,{discrError:t.DiscrError.Tag,tag:_,tagName:b})),c.ok(S);function T(){const C=P();u.if(!1);for(const E in C)u.elseIf((0,e._)`${_} === ${E}`),u.assign(S,x(C[E]));u.else(),c.error(!1,{discrError:t.DiscrError.Mapping,tag:_,tagName:b}),u.endIf()}function x(C){const E=u.name("valid"),R=c.subschema({keyword:"oneOf",schemaProp:C},E);return c.mergeEvaluated(R,e.Name),E}function P(){var C;const E={},R=O(h);let D=!0;for(let B=0;B<v.length;B++){let U=v[B];if(U?.$ref&&!(0,n.schemaHasRulesButRef)(U,f.self.RULES)){const W=U.$ref;if(U=o.resolveRef.call(f.self,f.schemaEnv.root,f.baseId,W),U instanceof o.SchemaEnv&&(U=U.schema),U===void 0)throw new a.default(f.opts.uriResolver,f.baseId,W)}const j=(C=U?.properties)===null||C===void 0?void 0:C[b];if(typeof j!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${b}"`);D=D&&(R||O(U)),L(j,B)}if(!D)throw new Error(`discriminator: "${b}" must be required`);return E;function O({required:B}){return Array.isArray(B)&&B.includes(b)}function L(B,U){if(B.const)$(B.const,U);else if(B.enum)for(const j of B.enum)$(j,U);else throw new Error(`discriminator: "properties/${b}" must have "const" or "enum"`)}function $(B,U){if(typeof B!="string"||B in E)throw new Error(`discriminator: "${b}" values must be unique strings`);E[B]=U}}}};return bg.default=l,bg}const rY="http://json-schema.org/draft-07/schema#",iY="http://json-schema.org/draft-07/schema#",sY="Core schema meta-schema",lY={schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},cY=["object","boolean"],dY={$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},uY={$schema:rY,$id:iY,title:sY,definitions:lY,type:cY,properties:dY,default:!0};var YR;function pY(){return YR||(YR=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.MissingRefError=t.ValidationError=t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=t.Ajv=void 0;const o=xK(),a=oY(),n=nY(),i=uY,l=["/properties"],c="http://json-schema.org/draft-07/schema";class u extends o.default{_addVocabularies(){super._addVocabularies(),a.default.forEach(b=>this.addVocabulary(b)),this.opts.discriminator&&this.addKeyword(n.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const b=this.opts.$data?this.$dataMetaSchema(i,l):i;this.addMetaSchema(b,c,!1),this.refs["http://json-schema.org/schema"]=c}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(c)?c:void 0)}}t.Ajv=u,e.exports=t=u,e.exports.Ajv=u,Object.defineProperty(t,"__esModule",{value:!0}),t.default=u;var p=Dv();Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return p.KeywordCxt}});var m=yt();Object.defineProperty(t,"_",{enumerable:!0,get:function(){return m._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return m.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return m.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return m.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return m.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return m.CodeGen}});var h=o_();Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return h.default}});var f=Ov();Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return f.default}})})(Ih,Ih.exports)),Ih.exports}var yg={exports:{}},YS={},ZR;function mY(){return ZR||(ZR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.formatNames=e.fastFormats=e.fullFormats=void 0;function t(B,U){return{validate:B,compare:U}}e.fullFormats={date:t(i,l),time:t(u(!0),p),"date-time":t(f(!0),v),"iso-time":t(u(),m),"iso-date-time":t(f(),b),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:T,"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,url:/^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,regex:$,uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,byte:P,int32:{type:"number",validate:R},int64:{type:"number",validate:D},float:{type:"number",validate:O},double:{type:"number",validate:O},password:!0,binary:!0},e.fastFormats={...e.fullFormats,date:t(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,l),time:t(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,p),"date-time":t(/^\d\d\d\d-[0-1]\d-[0-3]\dt(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,v),"iso-time":t(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,m),"iso-date-time":t(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,b),uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i},e.formatNames=Object.keys(e.fullFormats);function o(B){return B%4===0&&(B%100!==0||B%400===0)}const a=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,n=[0,31,28,31,30,31,30,31,31,30,31,30,31];function i(B){const U=a.exec(B);if(!U)return!1;const j=+U[1],W=+U[2],ne=+U[3];return W>=1&&W<=12&&ne>=1&&ne<=(W===2&&o(j)?29:n[W])}function l(B,U){if(B&&U)return B>U?1:B<U?-1:0}const c=/^(\d\d):(\d\d):(\d\d(?:\.\d+)?)(z|([+-])(\d\d)(?::?(\d\d))?)?$/i;function u(B){return function(j){const W=c.exec(j);if(!W)return!1;const ne=+W[1],H=+W[2],Z=+W[3],te=W[4],le=W[5]==="-"?-1:1,Q=+(W[6]||0),N=+(W[7]||0);if(Q>23||N>59||B&&!te)return!1;if(ne<=23&&H<=59&&Z<60)return!0;const G=H-N*le,V=ne-Q*le-(G<0?1:0);return(V===23||V===-1)&&(G===59||G===-1)&&Z<61}}function p(B,U){if(!(B&&U))return;const j=new Date("2020-01-01T"+B).valueOf(),W=new Date("2020-01-01T"+U).valueOf();if(j&&W)return j-W}function m(B,U){if(!(B&&U))return;const j=c.exec(B),W=c.exec(U);if(j&&W)return B=j[1]+j[2]+j[3],U=W[1]+W[2]+W[3],B>U?1:B<U?-1:0}const h=/t|\s/i;function f(B){const U=u(B);return function(W){const ne=W.split(h);return ne.length===2&&i(ne[0])&&U(ne[1])}}function v(B,U){if(!(B&&U))return;const j=new Date(B).valueOf(),W=new Date(U).valueOf();if(j&&W)return j-W}function b(B,U){if(!(B&&U))return;const[j,W]=B.split(h),[ne,H]=U.split(h),Z=l(j,ne);if(Z!==void 0)return Z||p(W,H)}const S=/\/|:/,_=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;function T(B){return S.test(B)&&_.test(B)}const x=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function P(B){return x.lastIndex=0,x.test(B)}const C=-2147483648,E=2**31-1;function R(B){return Number.isInteger(B)&&B<=E&&B>=C}function D(B){return Number.isInteger(B)}function O(){return!0}const L=/[^\\]\\Z/;function $(B){if(L.test(B))return!1;try{return new RegExp(B),!0}catch{return!1}}})(YS)),YS}var ZS={},QR;function hY(){return QR||(QR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.formatLimitDefinition=void 0;const t=pY(),o=yt(),a=o.operators,n={formatMaximum:{okStr:"<=",ok:a.LTE,fail:a.GT},formatMinimum:{okStr:">=",ok:a.GTE,fail:a.LT},formatExclusiveMaximum:{okStr:"<",ok:a.LT,fail:a.GTE},formatExclusiveMinimum:{okStr:">",ok:a.GT,fail:a.LTE}},i={message:({keyword:c,schemaCode:u})=>(0,o.str)`should be ${n[c].okStr} ${u}`,params:({keyword:c,schemaCode:u})=>(0,o._)`{comparison: ${n[c].okStr}, limit: ${u}}`};e.formatLimitDefinition={keyword:Object.keys(n),type:"string",schemaType:"string",$data:!0,error:i,code(c){const{gen:u,data:p,schemaCode:m,keyword:h,it:f}=c,{opts:v,self:b}=f;if(!v.validateFormats)return;const S=new t.KeywordCxt(f,b.RULES.all.format.definition,"format");S.$data?_():T();function _(){const P=u.scopeValue("formats",{ref:b.formats,code:v.code.formats}),C=u.const("fmt",(0,o._)`${P}[${S.schemaCode}]`);c.fail$data((0,o.or)((0,o._)`typeof ${C} != "object"`,(0,o._)`${C} instanceof RegExp`,(0,o._)`typeof ${C}.compare != "function"`,x(C)))}function T(){const P=S.schema,C=b.formats[P];if(!C||C===!0)return;if(typeof C!="object"||C instanceof RegExp||typeof C.compare!="function")throw new Error(`"${h}": format "${P}" does not define "compare" function`);const E=u.scopeValue("formats",{key:P,ref:C,code:v.code.formats?(0,o._)`${v.code.formats}${(0,o.getProperty)(P)}`:void 0});c.fail$data(x(E))}function x(P){return(0,o._)`${P}.compare(${p}, ${m}) ${n[h].fail} 0`}},dependencies:["format"]};const l=c=>(c.addKeyword(e.formatLimitDefinition),c);e.default=l})(ZS)),ZS}var JR;function gY(){return JR||(JR=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const o=mY(),a=hY(),n=yt(),i=new n.Name("fullFormats"),l=new n.Name("fastFormats"),c=(p,m={keywords:!0})=>{if(Array.isArray(m))return u(p,m,o.fullFormats,i),p;const[h,f]=m.mode==="fast"?[o.fastFormats,l]:[o.fullFormats,i],v=m.formats||o.formatNames;return u(p,v,h,f),m.keywords&&(0,a.default)(p),p};c.get=(p,m="full")=>{const f=(m==="fast"?o.fastFormats:o.fullFormats)[p];if(!f)throw new Error(`Unknown format "${p}"`);return f};function u(p,m,h,f){var v,b;(v=(b=p.opts.code).formats)!==null&&v!==void 0||(b.formats=(0,n._)`require("ajv-formats/dist/formats").${f}`);for(const S of m)p.addFormat(S,h[S])}e.exports=t=c,Object.defineProperty(t,"__esModule",{value:!0}),t.default=c})(yg,yg.exports)),yg.exports}var fY=gY();const Qfe=Ml(fY);function vY({studioUrl:e,meshUrl:t},o){return e??t??o}let r_;r_=globalThis.crypto;async function bY(e){return(await r_).getRandomValues(new Uint8Array(e))}async function yY(e){const t="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-._~",o=Math.pow(2,8)-Math.pow(2,8)%t.length;let a="";for(;a.length<e;){const n=await bY(e-a.length);for(const i of n)i<o&&(a+=t[i%t.length])}return a}async function SY(e){return await yY(e)}async function wY(e){const t=await(await r_).subtle.digest("SHA-256",new TextEncoder().encode(e));return btoa(String.fromCharCode(...new Uint8Array(t))).replace(/\//g,"_").replace(/\+/g,"-").replace(/=/g,"")}async function Jfe(e){if(e||(e=43),e<43||e>128)throw`Expected a length between 43 and 128. Received ${e}.`;const t=await SY(e),o=await wY(t);return{code_verifier:t,code_challenge:o}}const xa=GN().superRefine((e,t)=>{if(!URL.canParse(e))return t.addIssue({code:kH.custom,message:"URL must be parseable",fatal:!0}),R8}).refine(e=>{const t=new URL(e);return t.protocol!=="javascript:"&&t.protocol!=="data:"&&t.protocol!=="vbscript:"},{message:"URL cannot use javascript:, data:, or vbscript: scheme"}),Xfe=_a({resource:q().url(),authorization_servers:Be(xa).optional(),jwks_uri:q().url().optional(),scopes_supported:Be(q()).optional(),bearer_methods_supported:Be(q()).optional(),resource_signing_alg_values_supported:Be(q()).optional(),resource_name:q().optional(),resource_documentation:q().optional(),resource_policy_uri:q().url().optional(),resource_tos_uri:q().url().optional(),tls_client_certificate_bound_access_tokens:$t().optional(),authorization_details_types_supported:Be(q()).optional(),dpop_signing_alg_values_supported:Be(q()).optional(),dpop_bound_access_tokens_required:$t().optional()}),TY=_a({issuer:q(),authorization_endpoint:xa,token_endpoint:xa,registration_endpoint:xa.optional(),scopes_supported:Be(q()).optional(),response_types_supported:Be(q()),response_modes_supported:Be(q()).optional(),grant_types_supported:Be(q()).optional(),token_endpoint_auth_methods_supported:Be(q()).optional(),token_endpoint_auth_signing_alg_values_supported:Be(q()).optional(),service_documentation:xa.optional(),revocation_endpoint:xa.optional(),revocation_endpoint_auth_methods_supported:Be(q()).optional(),revocation_endpoint_auth_signing_alg_values_supported:Be(q()).optional(),introspection_endpoint:q().optional(),introspection_endpoint_auth_methods_supported:Be(q()).optional(),introspection_endpoint_auth_signing_alg_values_supported:Be(q()).optional(),code_challenge_methods_supported:Be(q()).optional(),client_id_metadata_document_supported:$t().optional()}),xY=_a({issuer:q(),authorization_endpoint:xa,token_endpoint:xa,userinfo_endpoint:xa.optional(),jwks_uri:xa,registration_endpoint:xa.optional(),scopes_supported:Be(q()).optional(),response_types_supported:Be(q()),response_modes_supported:Be(q()).optional(),grant_types_supported:Be(q()).optional(),acr_values_supported:Be(q()).optional(),subject_types_supported:Be(q()),id_token_signing_alg_values_supported:Be(q()),id_token_encryption_alg_values_supported:Be(q()).optional(),id_token_encryption_enc_values_supported:Be(q()).optional(),userinfo_signing_alg_values_supported:Be(q()).optional(),userinfo_encryption_alg_values_supported:Be(q()).optional(),userinfo_encryption_enc_values_supported:Be(q()).optional(),request_object_signing_alg_values_supported:Be(q()).optional(),request_object_encryption_alg_values_supported:Be(q()).optional(),request_object_encryption_enc_values_supported:Be(q()).optional(),token_endpoint_auth_methods_supported:Be(q()).optional(),token_endpoint_auth_signing_alg_values_supported:Be(q()).optional(),display_values_supported:Be(q()).optional(),claim_types_supported:Be(q()).optional(),claims_supported:Be(q()).optional(),service_documentation:q().optional(),claims_locales_supported:Be(q()).optional(),ui_locales_supported:Be(q()).optional(),claims_parameter_supported:$t().optional(),request_parameter_supported:$t().optional(),request_uri_parameter_supported:$t().optional(),require_request_uri_registration:$t().optional(),op_policy_uri:xa.optional(),op_tos_uri:xa.optional(),client_id_metadata_document_supported:$t().optional()}),eve=we({...xY.shape,...TY.pick({code_challenge_methods_supported:!0}).shape}),tve=we({access_token:q(),id_token:q().optional(),token_type:q(),expires_in:tI().optional(),scope:q().optional(),refresh_token:q().optional()}).strip(),ove=we({error:q(),error_description:q().optional(),error_uri:q().optional()}),XR=xa.optional().or(Ze("").transform(()=>{})),_Y=we({redirect_uris:Be(xa),token_endpoint_auth_method:q().optional(),grant_types:Be(q()).optional(),response_types:Be(q()).optional(),client_name:q().optional(),client_uri:xa.optional(),logo_uri:XR,scope:q().optional(),contacts:Be(q()).optional(),tos_uri:XR,policy_uri:q().optional(),jwks_uri:xa.optional(),jwks:Q9().optional(),software_id:q().optional(),software_version:q().optional(),software_statement:q().optional()}).strip(),kY=we({client_id:q(),client_secret:q().optional(),client_id_issued_at:Mt().optional(),client_secret_expires_at:Mt().optional()}).strip(),ave=_Y.merge(kY);we({error:q(),error_description:q().optional()}).strip();we({token:q(),token_type_hint:q().optional()}).strip();class Pa extends Error{constructor(t,o){super(t),this.errorUri=o,this.name=this.constructor.name}toResponseObject(){const t={error:this.errorCode,error_description:this.message};return this.errorUri&&(t.error_uri=this.errorUri),t}get errorCode(){return this.constructor.errorCode}}class Iw extends Pa{}Iw.errorCode="invalid_request";class Lw extends Pa{}Lw.errorCode="invalid_client";class Bw extends Pa{}Bw.errorCode="invalid_grant";class Fw extends Pa{}Fw.errorCode="unauthorized_client";class jw extends Pa{}jw.errorCode="unsupported_grant_type";class zw extends Pa{}zw.errorCode="invalid_scope";class Uw extends Pa{}Uw.errorCode="access_denied";class $w extends Pa{}$w.errorCode="server_error";class qw extends Pa{}qw.errorCode="temporarily_unavailable";class Vw extends Pa{}Vw.errorCode="unsupported_response_type";class Hw extends Pa{}Hw.errorCode="unsupported_token_type";class Gw extends Pa{}Gw.errorCode="invalid_token";class Ww extends Pa{}Ww.errorCode="method_not_allowed";class Kw extends Pa{}Kw.errorCode="too_many_requests";class Yw extends Pa{}Yw.errorCode="invalid_client_metadata";class Zw extends Pa{}Zw.errorCode="insufficient_scope";class Qw extends Pa{}Qw.errorCode="invalid_target";const nve={[Iw.errorCode]:Iw,[Lw.errorCode]:Lw,[Bw.errorCode]:Bw,[Fw.errorCode]:Fw,[jw.errorCode]:jw,[zw.errorCode]:zw,[Uw.errorCode]:Uw,[$w.errorCode]:$w,[qw.errorCode]:qw,[Vw.errorCode]:Vw,[Hw.errorCode]:Hw,[Gw.errorCode]:Gw,[Ww.errorCode]:Ww,[Kw.errorCode]:Kw,[Yw.errorCode]:Yw,[Zw.errorCode]:Zw,[Qw.errorCode]:Qw};async function UI(e){if(!e.getServerCapabilities()?.resources)return{resources:[]};try{return await e.listResources()}catch(o){if(o instanceof Pv&&o.code===Cp.MethodNotFound)return{resources:[]};throw o}}async function CY(e,t){return await e.readResource({uri:t})}function rve(e){const t=Re.c(12);let o,a;t[0]!==e?({client:o,...a}=e,t[0]=e,t[1]=o,t[2]=a):(o=t[1],a=t[2]);let n;t[3]!==o?(n=On.mcpResourcesList(o),t[3]=o,t[4]=n):n=t[4];let i;t[5]!==o?(i=()=>UI(o),t[5]=o,t[6]=i):i=t[6];const l=a.staleTime??3e4;let c;return t[7]!==a||t[8]!==n||t[9]!==i||t[10]!==l?(c={...a,queryKey:n,queryFn:i,staleTime:l,retry:!1},t[7]=a,t[8]=n,t[9]=i,t[10]=l,t[11]=c):c=t[11],Il(c)}function ive(e){const t=Re.c(12);let o,a;t[0]!==e?({client:o,...a}=e,t[0]=e,t[1]=o,t[2]=a):(o=t[1],a=t[2]);let n;t[3]!==o?(n=On.mcpResourcesList(o),t[3]=o,t[4]=n):n=t[4];let i;t[5]!==o?(i=()=>UI(o),t[5]=o,t[6]=i):i=t[6];const l=a.staleTime??3e4;let c;return t[7]!==a||t[8]!==n||t[9]!==i||t[10]!==l?(c={...a,queryKey:n,queryFn:i,staleTime:l,retry:!1},t[7]=a,t[8]=n,t[9]=i,t[10]=l,t[11]=c):c=t[11],Rd(c)}function sve(e){const t=Re.c(15);let o,a,n;t[0]!==e?({client:o,uri:n,...a}=e,t[0]=e,t[1]=o,t[2]=a,t[3]=n):(o=t[1],a=t[2],n=t[3]);let i;t[4]!==o||t[5]!==n?(i=On.mcpReadResource(o,n),t[4]=o,t[5]=n,t[6]=i):i=t[6];let l;t[7]!==o||t[8]!==n?(l=()=>CY(o,n),t[7]=o,t[8]=n,t[9]=l):l=t[9];const c=a.staleTime??3e4;let u;return t[10]!==a||t[11]!==i||t[12]!==l||t[13]!==c?(u={...a,queryKey:i,queryFn:l,staleTime:c,retry:!1},t[10]=a,t[11]=i,t[12]=l,t[13]=c,t[14]=u):u=t[14],Il(u)}const $I="ui-resource-html";function lve(e){const t=Re.c(22);let o,a,n,i,l,c;t[0]!==e?({orgSlug:n,connectionId:o,uri:c,studioUrl:l,meshUrl:a,...i}=e,t[0]=e,t[1]=o,t[2]=a,t[3]=n,t[4]=i,t[5]=l,t[6]=c):(o=t[1],a=t[2],n=t[3],i=t[4],l=t[5],c=t[6]);let u;t[7]!==o||t[8]!==n||t[9]!==c?(u=On.mcpUiResourceHtml(n,o,c),t[7]=o,t[8]=n,t[9]=c,t[10]=u):u=t[10];let p;t[11]!==o||t[12]!==a||t[13]!==n||t[14]!==l||t[15]!==c?(p=async()=>{const v=`${vY({studioUrl:l,meshUrl:a},typeof window<"u"?window.location.origin:"")}/api/${encodeURIComponent(n)}/mcp/${encodeURIComponent(o)}/ui-resource?uri=${encodeURIComponent(c)}`,b=await fetch(v,{credentials:"include"});if(!b.ok)throw new Error(`Failed to read UI resource (${b.status})`);return b.text()},t[11]=o,t[12]=a,t[13]=n,t[14]=l,t[15]=c,t[16]=p):p=t[16];const m=i.staleTime??3e4;let h;return t[17]!==i||t[18]!==u||t[19]!==p||t[20]!==m?(h={...i,queryKey:u,queryFn:p,staleTime:m,retry:!1},t[17]=i,t[18]=u,t[19]=p,t[20]=m,t[21]=h):h=t[21],Il(h)}const qI={featureNotInPlan:"feature_not_in_plan",aiBudgetExhausted:"ai_budget_exhausted"};class Jw extends Error{constructor(t,o,a){super(t),this.status=o,this.code=a,this.name="StudioToolError"}status;code}function VI(e){return e instanceof Jw&&Object.values(qI).includes(e.code??"")?e.code:null}async function EY(e,t,o){const a=await fetch(`/api/${encodeURIComponent(e)}/tools/${encodeURIComponent(t)}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(o??{})});if(!a.ok){let n=`${t} failed (${a.status})`,i;try{const l=await a.json();l?.error&&(n=l.error),typeof l?.code=="string"&&(i=l.code)}catch{}throw new Jw(n,a.status,i)}try{return await a.json()}catch{throw new Jw(`${t} returned a non-JSON response`,a.status)}}function i_(){const e=Re.c(5),{org:t}=Zp(),o=t.slug;let a;e[0]!==o?(a=(i,l)=>EY(o,i,l),e[0]=o,e[1]=a):a=e[1];let n;return e[2]!==o||e[3]!==a?(n={orgSlug:o,call:a},e[2]=o,e[3]=a,e[4]=n):n=e[4],n}const s_=5*6e4;async function HI(){return(await(await fetch("/api/config")).json()).config}function GI(){const e=Re.c(1);let t;e[0]===Symbol.for("react.memo_cache_sentinel")?(t={queryKey:On.publicConfig(),queryFn:HI,staleTime:s_},e[0]=t):t=e[0];const{data:o}=Il(t);return o}function cve(){const e=Re.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t={queryKey:On.publicConfig(),queryFn:HI,staleTime:s_},e[0]=t):t=e[0],Rd(t).data}const WI=A.createContext(void 0);function PY(e){const t=Re.c(3),{children:o}=e,a=GI();let n;return t[0]!==o||t[1]!==a.auth?(n=w.jsx(WI.Provider,{value:a.auth,children:o}),t[0]=o,t[1]=a.auth,t[2]=n):n=t[2],n}function dve(){const e=A.useContext(WI);if(e===void 0)throw new Error("useAuthConfig must be used within AuthConfigProvider");return e}var AY={},eD={};const Qg=Object.create(null),Mu=e=>AY||globalThis.Deno?.env.toObject()||globalThis.__env__||(e?Qg:globalThis),Wn=new Proxy(Qg,{get(e,t){return Mu()[t]??Qg[t]},has(e,t){return t in Mu()||t in Qg},set(e,t,o){const a=Mu(!0);return a[t]=o,!0},deleteProperty(e,t){if(!t)return!1;const o=Mu(!0);return delete o[t],!0},ownKeys(){const e=Mu(!0);return Object.keys(e)}});function Ko(e,t){return typeof process<"u"&&eD?eD[e]??t:typeof Deno<"u"?Deno.env.get(e)??t:typeof Bun<"u"?Bun.env[e]??t:t}const Nu=1,ua=4,Fr=8,Cn=24,tD={eterm:ua,cons25:ua,console:ua,cygwin:ua,dtterm:ua,gnome:ua,hurd:ua,jfbterm:ua,konsole:ua,kterm:ua,mlterm:ua,mosh:Cn,putty:ua,st:ua,"rxvt-unicode-24bit":Cn,terminator:Cn,"xterm-kitty":Cn},RY=new Map(Object.entries({APPVEYOR:Fr,BUILDKITE:Fr,CIRCLECI:Cn,DRONE:Fr,GITEA_ACTIONS:Cn,GITHUB_ACTIONS:Cn,GITLAB_CI:Fr,TRAVIS:Fr})),DY=[/ansi/,/color/,/linux/,/direct/,/^con[0-9]*x[0-9]/,/^rxvt/,/^screen/,/^xterm/,/^vt100/,/^vt220/];function OY(){if(Ko("FORCE_COLOR")!==void 0)switch(Ko("FORCE_COLOR")){case"":case"1":case"true":return ua;case"2":return Fr;case"3":return Cn;default:return Nu}if(Ko("NODE_DISABLE_COLORS")!==void 0&&Ko("NODE_DISABLE_COLORS")!==""||Ko("NO_COLOR")!==void 0&&Ko("NO_COLOR")!==""||Ko("TERM")==="dumb")return Nu;if(Ko("TMUX"))return Cn;if("TF_BUILD"in Wn&&"AGENT_NAME"in Wn)return ua;if("CI"in Wn){for(const{0:e,1:t}of RY)if(e in Wn)return t;return Ko("CI_NAME")==="codeship"?Fr:Nu}if("TEAMCITY_VERSION"in Wn)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.exec(Ko("TEAMCITY_VERSION"))!==null?ua:Nu;switch(Ko("TERM_PROGRAM")){case"iTerm.app":return!Ko("TERM_PROGRAM_VERSION")||/^[0-2]\./.exec(Ko("TERM_PROGRAM_VERSION"))!==null?Fr:Cn;case"HyperTerm":case"MacTerm":return Cn;case"Apple_Terminal":return Fr}if(Ko("COLORTERM")==="truecolor"||Ko("COLORTERM")==="24bit")return Cn;if(Ko("TERM")){if(/truecolor/.exec(Ko("TERM"))!==null)return Cn;if(/^xterm-256/.exec(Ko("TERM"))!==null)return Fr;const e=Ko("TERM").toLowerCase();if(tD[e])return tD[e];if(DY.some(t=>t.exec(e)!==null))return ua}return Ko("COLORTERM")?ua:Nu}const jr={reset:"\x1B[0m",bright:"\x1B[1m",dim:"\x1B[2m",fg:{red:"\x1B[31m",green:"\x1B[32m",yellow:"\x1B[33m",blue:"\x1B[34m",magenta:"\x1B[35m"}},Xw=["debug","info","success","warn","error"];function MY(e,t){return Xw.indexOf(t)>=Xw.indexOf(e)}const NY={info:jr.fg.blue,success:jr.fg.green,warn:jr.fg.yellow,error:jr.fg.red,debug:jr.fg.magenta},IY=(e,t,o)=>{const a=new Date().toISOString();return o?`${jr.dim}${a}${jr.reset} ${NY[e]}${e.toUpperCase()}${jr.reset} ${jr.bright}[Better Auth]:${jr.reset} ${t}`:`${a} ${e.toUpperCase()} [Better Auth]: ${t}`},LY=e=>{const t="warn",o=OY()!==1,a=(n,i,l=[])=>{if(!MY(t,n))return;const c=IY(n,i,o);{n==="error"?console.error(c,...l):n==="warn"?console.warn(c,...l):console.log(c,...l);return}};return{...Object.fromEntries(Xw.map(n=>[n,(...[i,...l])=>a(n,i,l)])),get level(){return t}}};LY();function BY(e){return e.charAt(0).toUpperCase()+e.slice(1)}var lp=class extends Error{constructor(e,t){super(e,t),this.name="BetterAuthError",this.message=e,this.stack=""}};function FY(e){try{return(new URL(e).pathname.replace(/\/+$/,"")||"/")!=="/"}catch{throw new lp(`Invalid base URL: ${e}. Please provide a valid base URL.`)}}function jY(e){try{const t=new URL(e);if(t.protocol!=="http:"&&t.protocol!=="https:")throw new lp(`Invalid base URL: ${e}. URL must include 'http://' or 'https://'`)}catch(t){throw t instanceof lp?t:new lp(`Invalid base URL: ${e}. Please provide a valid base URL.`,{cause:t})}}function QS(e,t="/api/auth"){if(jY(e),FY(e))return e;const o=e.replace(/\/+$/,"");return!t||t==="/"?o:(t=t.startsWith("/")?t:`/${t}`,`${o}${t}`)}function zY(e,t,o,a,n){if(e)return QS(e,t);{const i=Wn.BETTER_AUTH_URL||Wn.NEXT_PUBLIC_BETTER_AUTH_URL||Wn.PUBLIC_BETTER_AUTH_URL||Wn.NUXT_PUBLIC_BETTER_AUTH_URL||Wn.NUXT_PUBLIC_AUTH_URL||(Wn.BASE_URL!=="/"?Wn.BASE_URL:void 0);if(i)return QS(i,t)}if(typeof window<"u"&&window.location)return QS(window.location.origin,t)}const UY={id:"redirect",name:"Redirect",hooks:{onSuccess(e){if(e.data?.url&&e.data?.redirect&&typeof window<"u"&&window.location&&window.location)try{window.location.href=e.data.url}catch{}}}},$Y={proto:/"(?:_|\\u0{2}5[Ff]){2}(?:p|\\u0{2}70)(?:r|\\u0{2}72)(?:o|\\u0{2}6[Ff])(?:t|\\u0{2}74)(?:o|\\u0{2}6[Ff])(?:_|\\u0{2}5[Ff]){2}"\s*:/,constructor:/"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/,protoShort:/"__proto__"\s*:/,constructorShort:/"constructor"\s*:/},qY=/^\s*["[{]|^\s*-?\d{1,16}(\.\d{1,17})?([Ee][+-]?\d+)?\s*$/,oD={true:!0,false:!1,null:null,undefined:void 0,nan:NaN,infinity:Number.POSITIVE_INFINITY,"-infinity":Number.NEGATIVE_INFINITY},VY=/^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2})(?:\.(\d{1,7}))?(?:Z|([+-])(\d{2}):(\d{2}))$/;function HY(e){return e instanceof Date&&!isNaN(e.getTime())}function GY(e){const t=VY.exec(e);if(!t)return null;const[,o,a,n,i,l,c,u,p,m,h]=t,f=new Date(Date.UTC(parseInt(o,10),parseInt(a,10)-1,parseInt(n,10),parseInt(i,10),parseInt(l,10),parseInt(c,10),u?parseInt(u.padEnd(3,"0"),10):0));if(p){const v=(parseInt(m,10)*60+parseInt(h,10))*(p==="+"?-1:1);f.setUTCMinutes(f.getUTCMinutes()+v)}return HY(f)?f:null}function WY(e,t={}){const{strict:o=!1,warnings:a=!1,reviver:n,parseDates:i=!0}=t;if(typeof e!="string")return e;const l=e.trim();if(l.length>0&&l[0]==='"'&&l.endsWith('"')&&!l.slice(1,-1).includes('"'))return l.slice(1,-1);const c=l.toLowerCase();if(c.length<=9&&c in oD)return oD[c];if(!qY.test(l)){if(o)throw new SyntaxError("[better-json] Invalid JSON");return e}if(Object.entries($Y).some(([u,p])=>{const m=p.test(l);return m&&a&&console.warn(`[better-json] Detected potential prototype pollution attempt using ${u} pattern`),m})&&o)throw new Error("[better-json] Potential prototype pollution attempt detected");try{return JSON.parse(l,(p,m)=>{if(p==="__proto__"||p==="constructor"&&m&&typeof m=="object"&&"prototype"in m){a&&console.warn(`[better-json] Dropping "${p}" key to prevent prototype pollution`);return}if(i&&typeof m=="string"){const h=GY(m);if(h)return h}return n?n(p,m):m})}catch(u){if(o)throw u;return e}}function KY(e,t={strict:!0}){return WY(e,t)}let dr=[],ds=0;const Sg=4,YY=globalThis.nanostoresGlobal||={epoch:0},Jc=e=>{let t=[],o={get(){return o.lc||o.listen(()=>{})(),o.value},init:e,lc:0,listen(a){return o.lc=t.push(a),()=>{for(let i=ds+Sg;i<dr.length;)dr[i]===a?dr.splice(i,Sg):i+=Sg;let n=t.indexOf(a);~n&&(t.splice(n,1),--o.lc||o.off())}},notify(a,n){YY.epoch++;let i=!dr.length;for(let l of t)dr.push(l,o.value,a,n);if(i){for(ds=0;ds<dr.length;ds+=Sg)dr[ds](dr[ds+1],dr[ds+2],dr[ds+3]);dr.length=0}},off(){},set(a){let n=o.value;n!==a&&(o.value=a,o.notify(n))},subscribe(a){let n=o.listen(a);return a(o.value),n},value:e};return o},ZY=5,wg=6,Tg=10;let QY=(e,t,o,a)=>(e.events=e.events||{},e.events[o+Tg]||(e.events[o+Tg]=a(n=>{e.events[o].reduceRight((i,l)=>(l(i),i),{shared:{},...n})})),e.events[o]=e.events[o]||[],e.events[o].push(t),()=>{let n=e.events[o],i=n.indexOf(t);n.splice(i,1),n.length||(delete e.events[o],e.events[o+Tg](),delete e.events[o+Tg])});const JY=1e3;let KI=(e,t)=>QY(e,a=>{let n=t(a);n&&e.events[wg].push(n)},ZY,a=>{let n=e.listen;e.listen=(...l)=>(!e.lc&&!e.active&&(e.active=!0,a()),n(...l));let i=e.off;return e.events[wg]=[],e.off=()=>{i(),setTimeout(()=>{if(e.active&&!e.lc){e.active=!1;for(let l of e.events[wg])l();e.events[wg]=[]}},JY)},()=>{e.listen=n,e.off=i}});function XY(e,t,o){let a=new Set(t).add(void 0);return e.listen((n,i,l)=>{a.has(l)&&o(n,i,l)})}const eZ=()=>typeof window>"u",Zu=(e,t,o,a)=>{const n=Jc({data:null,error:null,isPending:!0,isRefetching:!1,refetch:c=>i(c)}),i=async c=>new Promise(u=>{const p=typeof a=="function"?a({data:n.get().data,error:n.get().error,isPending:n.get().isPending}):a;o(t,{...p,query:{...p?.query,...c?.query},async onSuccess(m){n.set({data:m.data,error:null,isPending:!1,isRefetching:!1,refetch:n.value.refetch}),await p?.onSuccess?.(m)},async onError(m){const{request:h}=m,f=typeof h.retry=="number"?h.retry:h.retry?.attempts,v=h.retryAttempt||0;f&&v<f||(n.set({error:m.error,data:null,isPending:!1,isRefetching:!1,refetch:n.value.refetch}),await p?.onError?.(m))},async onRequest(m){const h=n.get();n.set({isPending:h.data===null,data:h.data,error:null,isRefetching:!0,refetch:n.value.refetch}),await p?.onRequest?.(m)}}).catch(m=>{n.set({error:m,data:null,isPending:!1,isRefetching:!1,refetch:n.value.refetch})}).finally(()=>{u(void 0)})});e=Array.isArray(e)?e:[e];let l=!1;for(const c of e)c.subscribe(async()=>{eZ()||(l?await i():KI(n,()=>{const u=setTimeout(async()=>{l||(await i(),l=!0)},0);return()=>{n.off(),c.off(),clearTimeout(u)}}))});return n},JS=Symbol.for("better-auth:broadcast-channel"),tZ=()=>Math.floor(Date.now()/1e3);var oZ=class{listeners=new Set;name;constructor(e="better-auth.message"){this.name=e}subscribe(e){return this.listeners.add(e),()=>{this.listeners.delete(e)}}post(e){if(!(typeof window>"u"))try{localStorage.setItem(this.name,JSON.stringify({...e,timestamp:tZ()}))}catch{}}setup(){if(typeof window>"u"||typeof window.addEventListener>"u")return()=>{};const e=t=>{if(t.key!==this.name)return;const o=JSON.parse(t.newValue??"{}");o?.event!=="session"||!o?.data||this.listeners.forEach(a=>a(o))};return window.addEventListener("storage",e),()=>{window.removeEventListener("storage",e)}}};function XS(e="better-auth.message"){return globalThis[JS]||(globalThis[JS]=new oZ(e)),globalThis[JS]}const e0=Symbol.for("better-auth:focus-manager");var aZ=class{listeners=new Set;subscribe(e){return this.listeners.add(e),()=>{this.listeners.delete(e)}}setFocused(e){this.listeners.forEach(t=>t(e))}setup(){if(typeof window>"u"||typeof document>"u"||typeof window.addEventListener>"u")return()=>{};const e=()=>{document.visibilityState==="visible"&&this.setFocused(!0)};return document.addEventListener("visibilitychange",e,!1),()=>{document.removeEventListener("visibilitychange",e,!1)}}};function aD(){return globalThis[e0]||(globalThis[e0]=new aZ),globalThis[e0]}const t0=Symbol.for("better-auth:online-manager");var nZ=class{listeners=new Set;isOnline=typeof navigator<"u"?navigator.onLine:!0;subscribe(e){return this.listeners.add(e),()=>{this.listeners.delete(e)}}setOnline(e){this.isOnline=e,this.listeners.forEach(t=>t(e))}setup(){if(typeof window>"u"||typeof window.addEventListener>"u")return()=>{};const e=()=>this.setOnline(!0),t=()=>this.setOnline(!1);return window.addEventListener("online",e,!1),window.addEventListener("offline",t,!1),()=>{window.removeEventListener("online",e,!1),window.removeEventListener("offline",t,!1)}}};function o0(){return globalThis[t0]||(globalThis[t0]=new nZ),globalThis[t0]}const Rc=()=>Math.floor(Date.now()/1e3),rZ=5;function iZ(e){const{sessionAtom:t,sessionSignal:o,$fetch:a,options:n={}}=e,i=n.sessionOptions?.refetchInterval??0,l=n.sessionOptions?.refetchOnWindowFocus??!0,c=n.sessionOptions?.refetchWhenOffline??!1,u={lastSync:0,lastSessionRequest:0,cachedSession:void 0},p=()=>c||o0().isOnline,m=x=>{if(!p())return;if(x?.event==="storage"){u.lastSync=Rc(),o.set(!o.get());return}const P=t.get();if(x?.event==="poll"){u.lastSessionRequest=Rc(),a("/get-session").then(C=>{C.error?t.set({...P,data:null,error:C.error}):t.set({...P,data:C.data,error:null}),u.lastSync=Rc(),o.set(!o.get())}).catch(()=>{});return}if(x?.event==="visibilitychange"){if(Rc()-u.lastSessionRequest<rZ)return;u.lastSessionRequest=Rc()}(P?.data===null||P?.data===void 0||x?.event==="visibilitychange")&&(u.lastSync=Rc(),o.set(!o.get()))},h=x=>{XS().post({event:"session",data:{trigger:x},clientId:Math.random().toString(36).substring(7)})},f=()=>{i&&i>0&&(u.pollInterval=setInterval(()=>{t.get()?.data&&m({event:"poll"})},i*1e3))},v=()=>{u.unsubscribeBroadcast=XS().subscribe(()=>{m({event:"storage"})})},b=()=>{l&&(u.unsubscribeFocus=aD().subscribe(()=>{m({event:"visibilitychange"})}))},S=()=>{u.unsubscribeOnline=o0().subscribe(x=>{x&&m({event:"visibilitychange"})})};return{init:()=>{f(),v(),b(),S(),XS().setup(),aD().setup(),o0().setup()},cleanup:()=>{u.pollInterval&&(clearInterval(u.pollInterval),u.pollInterval=void 0),u.unsubscribeBroadcast&&(u.unsubscribeBroadcast(),u.unsubscribeBroadcast=void 0),u.unsubscribeFocus&&(u.unsubscribeFocus(),u.unsubscribeFocus=void 0),u.unsubscribeOnline&&(u.unsubscribeOnline(),u.unsubscribeOnline=void 0),u.lastSync=0,u.lastSessionRequest=0,u.cachedSession=void 0},triggerRefetch:m,broadcastSessionUpdate:h}}function sZ(e,t){const o=Jc(!1),a=Zu(o,"/get-session",e,{method:"GET"});return KI(a,()=>{const n=iZ({sessionAtom:a,sessionSignal:o,$fetch:e,options:t});return n.init(),()=>{n.cleanup()}}),{session:a,$sessionSignal:o}}function a0(e){if(e===null||typeof e!="object")return!1;const t=Object.getPrototypeOf(e);return t!==null&&t!==Object.prototype&&Object.getPrototypeOf(t)!==null||Symbol.iterator in e?!1:Symbol.toStringTag in e?Object.prototype.toString.call(e)==="[object Module]":!0}function eT(e,t,o=".",a){if(!a0(t))return eT(e,{},o,a);const n={...t};for(const i of Object.keys(e)){if(i==="__proto__"||i==="constructor")continue;const l=e[i];l!=null&&(a&&a(n,i,l,o)||(Array.isArray(l)&&Array.isArray(n[i])?n[i]=[...l,...n[i]]:a0(l)&&a0(n[i])?n[i]=eT(l,n[i],(o?`${o}.`:"")+i.toString(),a):n[i]=l))}return n}function lZ(e){return(...t)=>t.reduce((o,a)=>eT(o,a,"",e),{})}const cZ=lZ();var dZ=Object.defineProperty,uZ=Object.defineProperties,pZ=Object.getOwnPropertyDescriptors,nD=Object.getOwnPropertySymbols,mZ=Object.prototype.hasOwnProperty,hZ=Object.prototype.propertyIsEnumerable,rD=(e,t,o)=>t in e?dZ(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o,hr=(e,t)=>{for(var o in t||(t={}))mZ.call(t,o)&&rD(e,o,t[o]);if(nD)for(var o of nD(t))hZ.call(t,o)&&rD(e,o,t[o]);return e},Ir=(e,t)=>uZ(e,pZ(t)),gZ=class extends Error{constructor(e,t,o){super(t||e.toString(),{cause:o}),this.status=e,this.statusText=t,this.error=o,Error.captureStackTrace(this,this.constructor)}},fZ=async(e,t)=>{var o,a,n,i,l,c;let u=t||{};const p={onRequest:[t?.onRequest],onResponse:[t?.onResponse],onSuccess:[t?.onSuccess],onError:[t?.onError],onRetry:[t?.onRetry]};if(!t||!t?.plugins)return{url:e,options:u,hooks:p};for(const m of t?.plugins||[]){if(m.init){const h=await((o=m.init)==null?void 0:o.call(m,e.toString(),t));u=h.options||u,e=h.url}p.onRequest.push((a=m.hooks)==null?void 0:a.onRequest),p.onResponse.push((n=m.hooks)==null?void 0:n.onResponse),p.onSuccess.push((i=m.hooks)==null?void 0:i.onSuccess),p.onError.push((l=m.hooks)==null?void 0:l.onError),p.onRetry.push((c=m.hooks)==null?void 0:c.onRetry)}return{url:e,options:u,hooks:p}},iD=class{constructor(e){this.options=e}shouldAttemptRetry(e,t){return this.options.shouldRetry?Promise.resolve(e<this.options.attempts&&this.options.shouldRetry(t)):Promise.resolve(e<this.options.attempts)}getDelay(){return this.options.delay}},vZ=class{constructor(e){this.options=e}shouldAttemptRetry(e,t){return this.options.shouldRetry?Promise.resolve(e<this.options.attempts&&this.options.shouldRetry(t)):Promise.resolve(e<this.options.attempts)}getDelay(e){return Math.min(this.options.maxDelay,this.options.baseDelay*2**e)}};function bZ(e){if(typeof e=="number")return new iD({type:"linear",attempts:e,delay:1e3});switch(e.type){case"linear":return new iD(e);case"exponential":return new vZ(e);default:throw new Error("Invalid retry strategy")}}var yZ=async e=>{const t={},o=async a=>typeof a=="function"?await a():a;if(e?.auth){if(e.auth.type==="Bearer"){const a=await o(e.auth.token);if(!a)return t;t.authorization=`Bearer ${a}`}else if(e.auth.type==="Basic"){const[a,n]=await Promise.all([o(e.auth.username),o(e.auth.password)]);if(!a||!n)return t;t.authorization=`Basic ${btoa(`${a}:${n}`)}`}else if(e.auth.type==="Custom"){const[a,n]=await Promise.all([o(e.auth.prefix),o(e.auth.value)]);if(!n)return t;t.authorization=`${a??""} ${n}`}}return t},SZ=/^application\/(?:[\w!#$%&*.^`~-]*\+)?json(;.+)?$/i;function wZ(e){const t=e.headers.get("content-type"),o=new Set(["image/svg","application/xml","application/xhtml","application/html"]);if(!t)return"json";const a=t.split(";").shift()||"";return SZ.test(a)?"json":o.has(a)||a.startsWith("text/")?"text":"blob"}function TZ(e){try{return JSON.parse(e),!0}catch{return!1}}function tT(e){if(e===void 0)return!1;const t=typeof e;return t==="string"||t==="number"||t==="boolean"||t===null?!0:t!=="object"?!1:Array.isArray(e)?!0:e.buffer?!1:e.constructor&&e.constructor.name==="Object"||typeof e.toJSON=="function"}function sD(e){try{return JSON.parse(e)}catch{return e}}function lD(e){return typeof e=="function"}function xZ(e){if(e?.customFetchImpl)return e.customFetchImpl;if(typeof globalThis<"u"&&lD(globalThis.fetch))return globalThis.fetch;if(typeof window<"u"&&lD(window.fetch))return window.fetch;throw new Error("No fetch implementation found")}async function _Z(e){const t=new Headers(e?.headers),o=await yZ(e);for(const[a,n]of Object.entries(o||{}))t.set(a,n);if(!t.has("content-type")){const a=kZ(e?.body);a&&t.set("content-type",a)}return t}function kZ(e){return tT(e)?"application/json":null}function CZ(e){if(!e?.body)return null;const t=new Headers(e?.headers);if(tT(e.body)&&!t.has("content-type")){for(const[o,a]of Object.entries(e?.body))a instanceof Date&&(e.body[o]=a.toISOString());return JSON.stringify(e.body)}return t.has("content-type")&&t.get("content-type")==="application/x-www-form-urlencoded"&&tT(e.body)?new URLSearchParams(e.body).toString():e.body}function EZ(e,t){var o;if(t?.method)return t.method.toUpperCase();if(e.startsWith("@")){const a=(o=e.split("@")[1])==null?void 0:o.split("/")[0];return ZI.includes(a)?a.toUpperCase():t?.body?"POST":"GET"}return t?.body?"POST":"GET"}function PZ(e,t){let o;return!e?.signal&&e?.timeout&&(o=setTimeout(()=>t?.abort(),e?.timeout)),{abortTimeout:o,clearTimeout:()=>{o&&clearTimeout(o)}}}var AZ=class YI extends Error{constructor(t,o){super(o||JSON.stringify(t,null,2)),this.issues=t,Object.setPrototypeOf(this,YI.prototype)}};async function Jg(e,t){const o=await e["~standard"].validate(t);if(o.issues)throw new AZ(o.issues);return o.value}var ZI=["get","post","put","patch","delete"],RZ=e=>({id:"apply-schema",name:"Apply Schema",version:"1.0.0",async init(t,o){var a,n,i,l;const c=((n=(a=e.plugins)==null?void 0:a.find(u=>{var p;return(p=u.schema)!=null&&p.config?t.startsWith(u.schema.config.baseURL||"")||t.startsWith(u.schema.config.prefix||""):!1}))==null?void 0:n.schema)||e.schema;if(c){let u=t;(i=c.config)!=null&&i.prefix&&u.startsWith(c.config.prefix)&&(u=u.replace(c.config.prefix,""),c.config.baseURL&&(t=t.replace(c.config.prefix,c.config.baseURL))),(l=c.config)!=null&&l.baseURL&&u.startsWith(c.config.baseURL)&&(u=u.replace(c.config.baseURL,""));const p=c.schema[u];if(p){let m=Ir(hr({},o),{method:p.method,output:p.output});return o?.disableValidation||(m=Ir(hr({},m),{body:p.input?await Jg(p.input,o?.body):o?.body,params:p.params?await Jg(p.params,o?.params):o?.params,query:p.query?await Jg(p.query,o?.query):o?.query})),{url:t,options:m}}}return{url:t,options:o}}}),DZ=e=>{async function t(o,a){const n=Ir(hr(hr({},e),a),{plugins:[...e?.plugins||[],RZ(e||{}),...a?.plugins||[]]});if(e?.catchAllError)try{return await oT(o,n)}catch(i){return{data:null,error:{status:500,statusText:"Fetch Error",message:"Fetch related error. Captured by catchAllError option. See error property for more details.",error:i}}}return await oT(o,n)}return t};function OZ(e,t){const{baseURL:o,params:a,query:n}=t||{query:{},params:{},baseURL:""};let i=e.startsWith("http")?e.split("/").slice(0,3).join("/"):o||"";if(e.startsWith("@")){const h=e.toString().split("@")[1].split("/")[0];ZI.includes(h)&&(e=e.replace(`@${h}/`,"/"))}i.endsWith("/")||(i+="/");let[l,c]=e.replace(i,"").split("?");const u=new URLSearchParams(c);for(const[h,f]of Object.entries(n||{})){if(f==null)continue;let v;if(typeof f=="string")v=f;else if(Array.isArray(f)){for(const b of f)u.append(h,b);continue}else v=JSON.stringify(f);u.set(h,v)}if(a)if(Array.isArray(a)){const h=l.split("/").filter(f=>f.startsWith(":"));for(const[f,v]of h.entries()){const b=a[f];l=l.replace(v,b)}}else for(const[h,f]of Object.entries(a))l=l.replace(`:${h}`,String(f));l=l.split("/").map(encodeURIComponent).join("/"),l.startsWith("/")&&(l=l.slice(1));let p=u.toString();return p=p.length>0?`?${p}`.replace(/\+/g,"%20"):"",i.startsWith("http")?new URL(`${l}${p}`,i):`${i}${l}${p}`}var oT=async(e,t)=>{var o,a,n,i,l,c,u,p;const{hooks:m,url:h,options:f}=await fZ(e,t),v=xZ(f),b=new AbortController,S=(o=f.signal)!=null?o:b.signal,_=OZ(h,f),T=CZ(f),x=await _Z(f),P=EZ(h,f);let C=Ir(hr({},f),{url:_,headers:x,body:T,method:P,signal:S});for(const j of m.onRequest)if(j){const W=await j(C);typeof W=="object"&&W!==null&&(C=W)}("pipeTo"in C&&typeof C.pipeTo=="function"||typeof((a=t?.body)==null?void 0:a.pipe)=="function")&&("duplex"in C||(C.duplex="half"));const{clearTimeout:E}=PZ(f,b);let R=await v(C.url,C);E();const D={response:R,request:C};for(const j of m.onResponse)if(j){const W=await j(Ir(hr({},D),{response:(n=t?.hookOptions)!=null&&n.cloneResponse?R.clone():R}));W instanceof Response?R=W:typeof W=="object"&&W!==null&&(R=W.response)}if(R.ok){if(!(C.method!=="HEAD"))return{data:"",error:null};const W=wZ(R),ne={data:null,response:R,request:C};if(W==="json"||W==="text"){const H=await R.text(),Z=(i=C.jsonParser)!=null?i:sD;ne.data=await Z(H)}else ne.data=await R[W]();C?.output&&C.output&&!C.disableValidation&&(ne.data=await Jg(C.output,ne.data));for(const H of m.onSuccess)H&&await H(Ir(hr({},ne),{response:(l=t?.hookOptions)!=null&&l.cloneResponse?R.clone():R}));return t?.throw?ne.data:{data:ne.data,error:null}}const O=(c=t?.jsonParser)!=null?c:sD,L=await R.text(),$=TZ(L),B=$?await O(L):null,U={response:R,responseText:L,request:C,error:Ir(hr({},B),{status:R.status,statusText:R.statusText})};for(const j of m.onError)j&&await j(Ir(hr({},U),{response:(u=t?.hookOptions)!=null&&u.cloneResponse?R.clone():R}));if(t?.retry){const j=bZ(t.retry),W=(p=t.retryAttempt)!=null?p:0;if(await j.shouldAttemptRetry(W,R)){for(const H of m.onRetry)H&&await H(D);const ne=j.getDelay(W);return await new Promise(H=>setTimeout(H,ne)),await oT(e,Ir(hr({},t),{retryAttempt:W+1}))}}if(t?.throw)throw new gZ(R.status,R.statusText,$?B:L);return{data:null,error:Ir(hr({},B),{status:R.status,statusText:R.statusText})}};const MZ=(e,t)=>{const o="credentials"in Request.prototype,a=zY(e?.baseURL,e?.basePath)??"/api/auth",n=e?.plugins?.flatMap(C=>C.fetchPlugins).filter(C=>C!==void 0)||[],i={id:"lifecycle-hooks",name:"lifecycle-hooks",hooks:{onSuccess:e?.fetchOptions?.onSuccess,onError:e?.fetchOptions?.onError,onRequest:e?.fetchOptions?.onRequest,onResponse:e?.fetchOptions?.onResponse}},{onSuccess:l,onError:c,onRequest:u,onResponse:p,...m}=e?.fetchOptions||{},h=DZ({baseURL:a,...o?{credentials:"include"}:{},method:"GET",jsonParser(C){return C?KY(C,{strict:!1}):null},customFetchImpl:fetch,...m,plugins:[i,...m.plugins||[],...e?.disableDefaultFetchPlugins?[]:[UY],...n]}),{$sessionSignal:f,session:v}=sZ(h,e),b=e?.plugins||[];let S={};const _={$sessionSignal:f,session:v},T={"/sign-out":"POST","/revoke-sessions":"POST","/revoke-other-sessions":"POST","/delete-user":"POST"},x=[{signal:"$sessionSignal",matcher(C){return C==="/sign-out"||C==="/update-user"||C==="/sign-up/email"||C==="/sign-in/email"||C==="/delete-user"||C==="/verify-email"||C==="/revoke-sessions"||C==="/revoke-session"||C==="/change-email"}}];for(const C of b)C.getAtoms&&Object.assign(_,C.getAtoms?.(h)),C.pathMethods&&Object.assign(T,C.pathMethods),C.atomListeners&&x.push(...C.atomListeners);const P={notify:C=>{_[C].set(!_[C].get())},listen:(C,E)=>{_[C].subscribe(E)},atoms:_};for(const C of b)C.getActions&&(S=cZ(C.getActions?.(h,P,e)??{},S));return{get baseURL(){return a},pluginsActions:S,pluginsAtoms:_,pluginPathMethods:T,atomListeners:x,$fetch:h,$store:P}};function NZ(e){return typeof e=="object"&&e!==null&&"get"in e&&typeof e.get=="function"&&"lc"in e&&typeof e.lc=="number"}function IZ(e,t,o){const a=t[e],{fetchOptions:n,query:i,...l}=o||{};return a||(n?.method?n.method:l&&Object.keys(l).length>0?"POST":"GET")}function LZ(e,t,o,a,n){function i(l=[]){return new Proxy(function(){},{get(c,u){if(typeof u!="string"||u==="then"||u==="catch"||u==="finally")return;const p=[...l,u];let m=e;for(const h of p)if(m&&typeof m=="object"&&h in m)m=m[h];else{m=void 0;break}return typeof m=="function"||NZ(m)?m:i(p)},apply:async(c,u,p)=>{const m="/"+l.map(x=>x.replace(/[A-Z]/g,P=>`-${P.toLowerCase()}`)).join("/"),h=p[0]||{},f=p[1]||{},{query:v,fetchOptions:b,...S}=h,_={...f,...b},T=IZ(m,o,h);return await t(m,{..._,body:T==="GET"?void 0:{...S,..._?.body||{}},query:v||_?.query,method:T,async onSuccess(x){if(await _?.onSuccess?.(x),!n||_.disableSignal)return;const P=n.filter(E=>E.matcher(m));if(!P.length)return;const C=new Set;for(const E of P){const R=a[E.signal];if(!R)return;if(C.has(E.signal))continue;C.add(E.signal);const D=R.get();setTimeout(()=>{R.set(!D)},10)}}})}})}return i()}function BZ(e,t={}){const o=A.useRef(e.get()),{keys:a,deps:n=[e,a]}=t,i=A.useCallback(c=>{const u=p=>{o.current!==p&&(o.current=p,c())};return u(e.value),a?.length?XY(e,a,u):e.listen(u)},n),l=()=>o.current;return A.useSyncExternalStore(i,l,l)}function FZ(e){return`use${BY(e)}`}function jZ(e){const{pluginPathMethods:t,pluginsActions:o,pluginsAtoms:a,$fetch:n,$store:i,atomListeners:l}=MZ(e),c={};for(const[u,p]of Object.entries(a))c[FZ(u)]=()=>BZ(p);return LZ({...o,...c,$fetch:n,$store:i},n,t,a,l)}function zZ(e){return{authorize(t,o="AND"){let a=!1;for(const[n,i]of Object.entries(t)){const l=e[n];if(!l)return{success:!1,error:`You are not allowed to access resource: ${n}`};if(Array.isArray(i))a=i.every(c=>l.includes(c));else if(typeof i=="object"){const c=i;c.connector==="OR"?a=c.actions.some(u=>l.includes(u)):a=c.actions.every(u=>l.includes(u))}else throw new lp("Invalid access control request");if(a&&o==="OR")return{success:a};if(!a&&o==="AND")return{success:!1,error:`unauthorized to access resource "${n}"`}}return a?{success:a}:{success:!1,error:"Not authorized"}},statements:e}}function QI(e){return{newRole(t){return zZ(t)},statements:e}}const UZ={user:["create","list","set-role","ban","impersonate","delete","set-password","get","update"],session:["list","revoke","delete"]},JI=QI(UZ),XI=JI.newRole({user:["create","list","set-role","ban","impersonate","delete","set-password","get","update"],session:["list","revoke","delete"]}),eL=JI.newRole({user:[],session:[]}),$Z={admin:XI,user:eL},qZ=e=>{if(e.userId&&e.options?.adminUserIds?.includes(e.userId))return!0;if(!e.permissions&&!e.permission)return!1;const t=(e.role||e.options?.defaultRole||"user").split(","),o=e.options?.roles||$Z;for(const a of t)if(o[a]?.authorize(e.permission??e.permissions)?.success)return!0;return!1},VZ=e=>{const t={admin:XI,user:eL,...e?.roles};return{id:"admin-client",$InferServerPlugin:{},getActions:()=>({admin:{checkRolePermission:o=>qZ({role:o.role,options:{ac:e?.ac,roles:t},permissions:o.permissions??o.permission})}}),pathMethods:{"/admin/list-users":"GET","/admin/stop-impersonating":"POST"}}},HZ=()=>({id:"email-otp",$InferServerPlugin:{},atomListeners:[{matcher:e=>e==="/email-otp/verify-email"||e==="/sign-in/email-otp",signal:"$sessionSignal"}]}),GZ=()=>({id:"magic-link",$InferServerPlugin:{}}),WZ={organization:["update","delete"],member:["create","update","delete"],invitation:["create","cancel"],team:["create","update","delete"],ac:["create","read","update","delete"]},l_=QI(WZ),tL=l_.newRole({organization:["update"],invitation:["create","cancel"],member:["create","update","delete"],team:["create","update","delete"],ac:["create","read","update","delete"]}),oL=l_.newRole({organization:["update","delete"],member:["create","update","delete"],invitation:["create","cancel"],team:["create","update","delete"],ac:["create","read","update","delete"]}),aL=l_.newRole({organization:[],member:[],invitation:[],team:[],ac:["read"]}),KZ={admin:tL,owner:oL,member:aL},YZ=(e,t)=>{if(!e.permissions&&!e.permission)return!1;const o=e.role.split(","),a=e.options.creatorRole||"owner",n=o.includes(a),i=e.allowCreatorAllPermissions||!1;if(n&&i)return!0;for(const l of o)if(t[l]?.authorize(e.permissions??e.permission)?.success)return!0;return!1},ZZ=e=>YZ(e,e.options.roles||KZ),QZ=e=>{const t=Jc(!1),o=Jc(!1),a=Jc(!1),n=Jc(!1),i={admin:tL,member:aL,owner:oL,...e?.roles};return{id:"organization",$InferServerPlugin:{},getActions:(l,c,u)=>({$Infer:{ActiveOrganization:{},Organization:{},Invitation:{},Member:{},Team:{}},organization:{checkRolePermission:p=>ZZ({role:p.role,options:{ac:e?.ac,roles:i},permissions:p.permissions??p.permission})}}),getAtoms:l=>{const c=Zu(t,"/organization/list",l,{method:"GET"});return{$listOrg:t,$activeOrgSignal:o,$activeMemberSignal:a,$activeMemberRoleSignal:n,activeOrganization:Zu([o],"/organization/get-full-organization",l,()=>({method:"GET"})),listOrganizations:c,activeMember:Zu([a],"/organization/get-active-member",l,{method:"GET"}),activeMemberRole:Zu([n],"/organization/get-active-member-role",l,{method:"GET"})}},pathMethods:{"/organization/get-full-organization":"GET","/organization/list-user-teams":"GET"},atomListeners:[{matcher(l){return l==="/organization/create"||l==="/organization/delete"||l==="/organization/update"},signal:"$listOrg"},{matcher(l){return l.startsWith("/organization")},signal:"$activeOrgSignal"},{matcher(l){return l.startsWith("/organization/set-active")},signal:"$sessionSignal"},{matcher(l){return l.includes("/organization/update-member-role")},signal:"$activeMemberSignal"},{matcher(l){return l.includes("/organization/update-member-role")},signal:"$activeMemberRoleSignal"}]}},JZ="1.6.11",XZ=e=>({id:"sso-client",version:JZ,$InferServerPlugin:{},pathMethods:{"/sso/providers":"GET","/sso/get-provider":"GET"}});function eQ(e){let t=e;if(typeof e=="string")try{t=JSON.parse(e)}catch{return{}}return t&&typeof t=="object"&&!Array.isArray(t)?Object.fromEntries(Object.entries(t)):{}}function nL(e){return eQ(e?.metadata).archived===!0}const tQ="Organization is archived",Qp=jZ({plugins:[QZ({}),VZ(),XZ(),GZ(),HZ()]}),oQ=3e4;let Qu=null,xg=null;function rL(){if(Qu&&Qu.expiresAt>Date.now())return Promise.resolve(Qu.result);if(xg)return xg;const e=Qp.organization.list().then(t=>{const o=t.data?{...t,data:t.data.filter(a=>!nL(a))}:t;return o.data&&(Qu={result:o,expiresAt:Date.now()+oQ}),o}).finally(()=>{xg=null});return xg=e,e}function uve(){const e=Qp.useListOrganizations(),t=e.data?.filter(o=>!nL(o));return{...e,data:t}}function pve(){Qu=null}const aQ="modulepreload",nQ=function(e){return"/"+e},cD={},je=function(t,o,a){let n=Promise.resolve();if(o&&o.length>0){let l=function(p){return Promise.all(p.map(m=>Promise.resolve(m).then(h=>({status:"fulfilled",value:h}),h=>({status:"rejected",reason:h}))))};document.getElementsByTagName("link");const c=document.querySelector("meta[property=csp-nonce]"),u=c?.nonce||c?.getAttribute("nonce");n=l(o.map(p=>{if(p=nQ(p),p in cD)return;cD[p]=!0;const m=p.endsWith(".css"),h=m?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${p}"]${h}`))return;const f=document.createElement("link");if(f.rel=m?"stylesheet":aQ,m||(f.as="script"),f.crossOrigin="",f.href=p,u&&f.setAttribute("nonce",u),document.head.appendChild(f),m)return new Promise((v,b)=>{f.addEventListener("load",v),f.addEventListener("error",()=>b(Error(`Unable to preload CSS for ${p}`)))})}))}function i(l){const c=new Event("vite:preloadError",{cancelable:!0});if(c.payload=l,window.dispatchEvent(c),!c.defaultPrevented)throw l}return n.then(l=>{for(const c of l||[])c.status==="rejected"&&i(c.reason);return t().catch(i)})};function rQ(e){try{return JSON.parse(e)}catch{return}}function dD(e,t){if(typeof localStorage>"u")return typeof t=="function"?t(void 0):t;const o=localStorage.getItem(e),a=o?rQ(o):void 0,n=typeof t=="function"?t(a):a??t;if(a===void 0||n!==a)try{const i=JSON.stringify(n);localStorage.setItem(e,i)}catch{}return n}function iQ(e,t){const o=Re.c(25),a=vv();let n;o[0]!==e?(n=["localStorage",e],o[0]=e,o[1]=n):n=o[1];const i=n;let l,c;o[2]!==t||o[3]!==e?(l=()=>dD(e,t),c=()=>dD(e,t),o[2]=t,o[3]=e,o[4]=l,o[5]=c):(l=o[4],c=o[5]);let u;o[6]!==i||o[7]!==l||o[8]!==c?(u={queryKey:i,queryFn:l,initialData:c,staleTime:1/0,gcTime:1/0},o[6]=i,o[7]=l,o[8]=c,o[9]=u):u=o[9];const{data:p}=Rd(u);let m;o[10]!==e?(m=async x=>(typeof localStorage<"u"&&localStorage.setItem(e,JSON.stringify(x)),x),o[10]=e,o[11]=m):m=o[11];let h;o[12]!==a||o[13]!==i?(h=x=>{a.setQueryData(i,x)},o[12]=a,o[13]=i,o[14]=h):h=o[14];let f;o[15]!==m||o[16]!==h?(f={mutationFn:m,onSuccess:h},o[15]=m,o[16]=h,o[17]=f):f=o[17];const v=sp(f);let b;o[18]!==v||o[19]!==a||o[20]!==i?(b=x=>{const P=a.getQueryData(i),C=typeof x=="function"?x(P):x;v.mutate(C)},o[18]=v,o[19]=a,o[20]=i,o[21]=b):b=o[21];const S=b,_=p;let T;return o[22]!==S||o[23]!==_?(T=[_,S],o[22]=S,o[23]=_,o[24]=T):T=o[24],T}const Bl={chatSelectedImageModel:e=>`studio:chat:selectedImageModel:${e}`,chatSelectedWebSearchModel:e=>`studio:chat:selectedWebSearchModel:${e}`,chatSelectedDeepResearchModel:e=>`studio:chat:selectedDeepResearchModel:${e}`,chatSimpleModeTier:e=>`studio:chat:simpleModeTier:${e}`,chatAutosend:(e,t)=>`studio:chat:autosend:${e}:${t}`,chatThreadIntent:(e,t)=>`studio:chat:threadIntent:${e}:${t}`,homeTaskMode:e=>`home-task-mode:${e}`,chatDraft:(e,t)=>`studio:chat:draft:${e}:${t}`,taskBoardPrs:e=>`studio:task-board-prs:${e}`,taskFeedBehindTheScenes:()=>"studio:task-feed:behind-the-scenes",taskBoardAssignee:(e,t)=>`studio:task-board-assignee:${e}:${t}`,recentApps:e=>`studio:recent-apps:${e}`,appOpens:e=>`studio:app-opens:${e}`,recentOrgs:()=>"studio:recent-orgs",railOrgPrefs:()=>"studio:rail-org-prefs",sidePanelWidth:()=>"studio:side-panel:width",sidebarOpen:()=>"studio:sidebar-open",preferences:()=>"studio:user:preferences",lastOrgSlug:()=>"studio:last-org-slug",lastLocation:()=>"studio:last-location",connectionsTab:e=>`studio:connections:tab:${e}`,taskLastViewed:e=>`studio:chat:task-last-viewed:${e}`,sidebarGroupOrder:(e,t)=>`sidebar.group-order.${e}.${t}`,sidebarSectionOpen:(e,t)=>`studio:sidebar:section-open:${e}:${t}`,ptBrAnnouncementSeen:e=>`studio:announcement:pt-br:${e}`,cmsTourSeen:e=>`studio:cms-tour:seen:${e}`,localPreviewUrl:e=>`studio:local-preview-url:${e}`,previewDeviceSize:e=>`studio:preview:device-size:${e}`,previewEditingMode:e=>`studio:preview:editing-mode:${e}`},iL=["en","pt-BR"];function c_(){return typeof navigator<"u"&&navigator.language?.toLowerCase().startsWith("pt")?"pt-BR":"en"}const sQ={toolApprovalLevel:"auto",enableNotifications:typeof Notification<"u",enableSounds:!1,theme:"system",language:c_(),shownTaskBoardLanes:[],collapsedTaskBoardLanes:[],projectFirstNav:!1},sL=["auto","readonly"],mve=[{value:"readonly",labelKey:"settings.preferences.toolApprovalAsk",shortKey:"settings.preferences.toolApprovalAskShort"},{value:"auto",labelKey:"settings.preferences.toolApprovalAuto",shortKey:"settings.preferences.toolApprovalAutoShort"}],lQ=["light","dark","system"];function hve(){try{const e=JSON.parse(localStorage.getItem(Bl.preferences())??"{}");if(sL.includes(e.toolApprovalLevel))return e.toolApprovalLevel}catch{}return"auto"}function cQ(){try{const e=JSON.parse(localStorage.getItem(Bl.preferences())??"{}");if(iL.includes(e.language))return e.language}catch{}return c_()}function d_(){const e=Re.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=Bl.preferences(),e[0]=t):t=e[0],iQ(t,dQ)}function dQ(e){const t={...sQ,...e};return"showProjectSettingsGear"in t&&delete t.showProjectSettingsGear,"compactPageLayout"in t&&delete t.compactPageLayout,sL.includes(t.toolApprovalLevel)||(t.toolApprovalLevel="auto"),lQ.includes(t.theme)||(t.theme="system"),iL.includes(t.language)||(t.language=c_()),Array.isArray(t.shownTaskBoardLanes)||(t.shownTaskBoardLanes=[]),Array.isArray(t.collapsedTaskBoardLanes)||(t.collapsedTaskBoardLanes=[]),t.projectFirstNav=t.projectFirstNav===!0,t}function gve(){const[e]=d_();return e.projectFirstNav}const uQ={"page.overview":"Overview","page.app":"App","page.view":"View","page.file":"File","page.document":"Document","page.item":"Item","page.breadcrumbs":"Breadcrumbs","page.breadcrumbMenu":"Show navigation path","page.views":"Page views","page.openThread":"Open chat","page.closeThread":"Close chat","page.collapseSidebar":"Collapse sidebar","page.expandSidebar":"Expand sidebar"},pQ={"projects.platform.vtex":"VTEX","projects.platform.shopify":"Shopify","projects.platform.wake":"Wake","projects.platform.nuvemshop":"Nuvemshop","projects.platform.linx":"Linx","projects.platform.vnda":"VNDA","projects.home.newProject":"New project","projects.card.updated":"Updated {time}","projects.empty.title":"Your commerce, one project at a time","projects.empty.description":"A site, an app, a store. Each one keeps its own connections, report and board.","projects.empty.readOnly":"Ask an admin to create the first project.","projects.new.title":"New project","projects.new.subtitle":"What are you setting up?","projects.new.back":"Back","projects.new.create":"Create project","projects.new.creating":"Creating…","projects.new.nameLabel":"Project name","projects.new.namePlaceholder":"Farm web","projects.new.nameRequired":"Give the project a name","projects.new.failed":"Couldn't create the project","projects.new.created":"{title} is ready","projects.new.path.repository":"Import a codebase","projects.new.path.repository.hint":"Bring a storefront or app codebase in","projects.new.path.folder":"New project folder","projects.new.path.folder.hint":"Name it now, connect it later","projects.new.step.folder.title":"Name your project","projects.reports.chooserTitle":"Continue to Reports","projects.reports.chooserSubtitle":"Choose a project to continue","projects.reports.chooserSearch":"Find project…","projects.reports.chooserEmpty":"No project by that name.","projects.reports.status.ready":"Ready","projects.reports.status.running":"Running","projects.reports.status.none":"Not run","projects.reports.status.locked":"Locked","projects.connections.orgWide":"Organization-wide","projects.connections.usedBy":"{count} projects","projects.settings.title":"Projects","projects.settings.description":"Everything scoped to a project lives here: its repositories, connections, report and board.","projects.settings.searchPlaceholder":"Search projects…","projects.settings.open":"Open","projects.settings.openSettings":"Settings","projects.settings.orgScopeNote":"Members, billing, security and AI providers stay organization-wide.","projects.settings.noResults":"No projects match “{search}”","projects.identity.storeUrlLabel":"Store URL","projects.identity.storeUrlDescription":"The live storefront. Reports run against this address.","projects.flat.viewProject":"Project","projects.flat.viewFiles":"Files","projects.flat.viewAnalytics":"Analytics","projects.apps.heading":"Apps","projects.apps.seeAll":"See all","projects.apps.showLess":"Show less","projects.apps.reports":"Report","projects.apps.reportsCaption":"What is wrong with the storefront","projects.apps.siteEditor":"Site editor","projects.apps.siteEditorCaption":"Pages, sections and content","projects.apps.assets":"Assets","projects.apps.assetsCaption":"Images and files the site uses","projects.apps.hosting":"Hosting","projects.apps.hostingCaption":"Deploys, domains and environments","projects.apps.e2e":"End-to-end tests","projects.apps.e2eCaption":"Flows checked on every change","projects.apps.analytics":"Analytics","projects.apps.analyticsCaption":"Traffic, conversion and revenue","projects.apps.cdn":"Monitor","projects.apps.cdnCaption":"Cache, latency and errors","projects.apps.automations":"Automations","projects.apps.automationsCaption":"Work that runs on a schedule","projects.apps.experiments":"Experiments","projects.apps.experimentsCaption":"A/B tests and their results","projects.flat.close":"Close"},mQ={"virtualMcp.addConnectionDialog.addConnectionTitle":"Add Connection","virtualMcp.addConnectionDialog.authenticationFailedError":"Authentication failed: {error}","virtualMcp.addConnectionDialog.connected":"Connected","virtualMcp.addConnectionDialog.connectedAuthenticated":"Connected and authenticated","virtualMcp.addConnectionDialog.connectionsTitle":"Connections","virtualMcp.addConnectionDialog.failedToAddConnection":"Failed to add connection","virtualMcp.addConnectionDialog.failedToConnect":"Failed to connect","virtualMcp.addConnectionDialog.mcpServerConnectionError":"This MCP Server cannot be connected: no connection method available","virtualMcp.addConnectionDialog.searchConnectionsPlaceholder":"Search connections...","virtualMcp.addConnectionDialog.signInFailedDescription":"It was added to your project, but its sign-in setup looks off. You can try authenticating again later from the connection's settings. ({error})","virtualMcp.addConnectionDialog.signInFailedTitle":"Couldn't sign in to this connection","virtualMcp.connectionDialogContent.add":"Add","virtualMcp.connectionDialogContent.added":"Added","virtualMcp.connectionDialogContent.builtByDeco":"Built and maintained by Deco","virtualMcp.connectionDialogContent.builtByOfficial":"Built and maintained by the official vendor","virtualMcp.connectionDialogContent.connect":"Connect","virtualMcp.connectionDialogContent.connected":"Connected","virtualMcp.connectionDialogContent.customConnection":"Custom Connection","virtualMcp.connectionDialogContent.emptyStateNoConnectionsAvailable":"No connections available","virtualMcp.connectionDialogContent.emptyStateNoConnectionsYet":"No connections yet","virtualMcp.connectionDialogContent.emptyStateSearchNoMatch":'No connections match "{search}"',"virtualMcp.connectionDialogContent.madeByDeco":"Made by Deco","virtualMcp.connectionDialogContent.sectionAllConnections":"All connections","virtualMcp.connectionDialogContent.sectionVerified":"Verified","virtualMcp.connectionDialogContent.tabAll":"All","virtualMcp.connectionDialogContent.tabConnected":"Connected","virtualMcp.connectionDialogContent.verifiedByDeco":"Verified by the Deco team","virtualMcp.connectionItem.authorize":"Authorize","virtualMcp.connectionItem.configureResources":"Configure resources","virtualMcp.connectionItem.connectionDisabled":"Connection disabled","virtualMcp.connectionItem.connectionEnabled":"Connection enabled","virtualMcp.connectionItem.connectionNotFound":"Connection not found","virtualMcp.connectionItem.connectionSettings":"Connection settings","virtualMcp.connectionItem.disable":"Disable","virtualMcp.connectionItem.disableConnection":"Disable connection","virtualMcp.connectionItem.disabled":"Disabled","virtualMcp.connectionItem.disabledError":"Disabled (error)","virtualMcp.connectionItem.enable":"Enable","virtualMcp.connectionItem.failedToUpdateConnection":"Failed to update connection","virtualMcp.connectionItem.needsAuthorization":"Needs authorization","virtualMcp.connectionItem.newInstance":"New instance","virtualMcp.connectionItem.remove":"Remove","virtualMcp.connectionItem.removeConnection":"Remove connection","virtualMcp.dependencySelectionDialog.authorizationDescription":"This connection needs to be authorized before you can configure its tools and resources.","virtualMcp.dependencySelectionDialog.authorizationRequired":"Authorization required","virtualMcp.dependencySelectionDialog.authorize":"Authorize","virtualMcp.dependencySelectionDialog.deselectAll":"Deselect all","virtualMcp.dependencySelectionDialog.done":"Done","virtualMcp.dependencySelectionDialog.noActiveToolsSelected":"No active tools selected","virtualMcp.dependencySelectionDialog.noPromptsAvailable":"No prompts available","virtualMcp.dependencySelectionDialog.noResourcesAvailable":"No resources available","virtualMcp.dependencySelectionDialog.noToolsAvailable":"No tools available","virtualMcp.dependencySelectionDialog.promptsNotSupported":"Prompts not supported by this server","virtualMcp.dependencySelectionDialog.resourcesNotSupported":"Resources not supported by this server","virtualMcp.dependencySelectionDialog.selectAll":"Select all","virtualMcp.dependencySelectionDialog.somethingWentWrong":"Something went wrong","virtualMcp.dependencySelectionDialog.tabActive":"Active","virtualMcp.dependencySelectionDialog.tabPrompts":"Prompts","virtualMcp.dependencySelectionDialog.tabResources":"Resources","virtualMcp.dependencySelectionDialog.tabTools":"Tools","virtualMcp.dependencySelectionDialog.toolsNotSupported":"Tools not supported by this server","virtualMcp.dependencySelectionDialog.unexpectedError":"An unexpected error occurred","virtualMcp.filesSection.add":"Add","virtualMcp.filesSection.description":"Attach files and skills the project can always reference.","virtualMcp.filesSection.failedUploadFile":"Failed to upload file.","virtualMcp.filesSection.fileTooLargeDescription":"Exceeds the 25MB limit, not uploaded: {names}","virtualMcp.filesSection.fileTooLargeTitle":"File too large","virtualMcp.filesSection.filesAndSkills":"Files and skills","virtualMcp.filesSection.kindFile":"File","virtualMcp.filesSection.kindSkill":"Skill","virtualMcp.filesSection.noFilesFound":"No files found.","virtualMcp.filesSection.noFilesOrSkillsYet":"No files or skills yet. Add one or drag and drop here.","virtualMcp.filesSection.noSkillsFound":"No skills found.","virtualMcp.filesSection.removeAriaLabel":"Remove {name}","virtualMcp.filesSection.searchFilesPlaceholder":"Search files...","virtualMcp.filesSection.searchSkillsPlaceholder":"Search skills...","virtualMcp.filesSection.selectFileOrFolder":"Select file or folder","virtualMcp.filesSection.selectSkill":"Select skill","virtualMcp.filesSection.uploadFile":"Upload file","virtualMcp.layoutTabContent.noMainView":"No main view","virtualMcp.layoutTabContent.automations":"Automations","virtualMcp.layoutTabContent.chatAlwaysShown":"Chat is always shown when it is the default view","virtualMcp.layoutTabContent.layout":"Layout","virtualMcp.layoutTabContent.mainView":"Main view","virtualMcp.layoutTabContent.mainViewDescription":"What users see when they first open this project.","virtualMcp.layoutTabContent.settings":"Settings","virtualMcp.layoutTabContent.showChat":"Show chat","virtualMcp.layoutTabContent.showChatDescription":"Display Chat in the side panel alongside the main view.","virtualMcp.layoutTabContent.siteEditor":"Site Editor","virtualMcp.settings.title":"Project settings","virtualMcp.settings.navigation":"Project settings sections","virtualMcp.settings.identity.icon":"Project icon","virtualMcp.settings.identity.iconDescription":"How your project appears in the sidebar and across Studio.","virtualMcp.settings.identity.name":"Project name","virtualMcp.settings.identity.description":"Description","virtualMcp.settings.general.title":"General","virtualMcp.settings.site.title":"CMS","virtualMcp.settings.site.classicTitle":"Site and sandbox","virtualMcp.settings.groups.advanced":"Advanced","virtualMcp.settings.connections.title":"Connections","virtualMcp.settings.views.defaults":"Default layout","virtualMcp.settings.views.sidebar":"Views","virtualMcp.settings.views.open":"Open","virtualMcp.settings.views.pin":"Pin to sidebar","virtualMcp.settings.views.unpin":"Remove from sidebar","virtualMcp.settings.views.setMainView":"Set as main view","virtualMcp.settings.views.rowActions":"View options","virtualMcp.subAgentsSection.addSubAgent":"Add sub-project","virtualMcp.subAgentsSection.anyAgent":"Any project","virtualMcp.subAgentsSection.canDelegateToAnyAgent":"Can delegate to any project in the organization.","virtualMcp.subAgentsSection.canOnlyDelegateToItself":"Can only delegate to a fresh copy of itself, no other projects.","virtualMcp.subAgentsSection.emptyStateMessage":"No sub-projects selected yet. Add one — until then this project can only delegate to itself.","virtualMcp.subAgentsSection.noAgentsFound":"No projects found.","virtualMcp.subAgentsSection.onlyItself":"Only itself","virtualMcp.subAgentsSection.searchPlaceholder":"Search projects...","virtualMcp.subAgentsSection.specificAgents":"Specific projects","virtualMcp.subAgentsSection.title":"Sub-projects","virtualMcp.virtualMcp.addConnection":"Add connection","virtualMcp.virtualMcp.agentDeleted":'Deleted "{title}"',"virtualMcp.virtualMcp.agentNameFallback":"Agent","virtualMcp.virtualMcp.agentNamePlaceholder":"Project name","virtualMcp.virtualMcp.authenticationFailed":"Authentication failed: {error}","virtualMcp.virtualMcp.authenticationSuccessful":"Authentication successful","virtualMcp.virtualMcp.backToSpaces":"Back to spaces","virtualMcp.virtualMcp.cancel":"Cancel","virtualMcp.virtualMcp.connect":"Connect","virtualMcp.virtualMcp.connections":"Connections","virtualMcp.virtualMcp.created":"Created","virtualMcp.virtualMcp.delete":"Delete","virtualMcp.virtualMcp.deleteAgent":"Delete project","virtualMcp.virtualMcp.deleteAgentConfirm":"Delete Project?","virtualMcp.virtualMcp.deleteAgentConfirmDescription":"This action cannot be undone. This will permanently delete {title}.","virtualMcp.virtualMcp.deleteAgentDescription":"Permanently delete this project and all its data.","virtualMcp.virtualMcp.descriptionPlaceholder":"Add a description...","virtualMcp.virtualMcp.failedToCreateInstance":"Failed to create instance","virtualMcp.virtualMcp.fullscreen":"Fullscreen","virtualMcp.virtualMcp.improve":"Improve","virtualMcp.virtualMcp.instanceAlreadyAdded":"This instance is already added to the project","virtualMcp.virtualMcp.instructions":"Instructions","virtualMcp.virtualMcp.instructionsPlaceholder":"Define how this agent should behave, what tone to use, any constraints or guidelines...","virtualMcp.virtualMcp.lastUsed":"Last used {time}","virtualMcp.virtualMcp.neverUsed":"Never used","virtualMcp.virtualMcp.newInstanceCreated":"New instance created","virtualMcp.virtualMcp.noConnectionsYet":"No connections yet. Add one to get started.","virtualMcp.virtualMcp.openFullscreenEditor":"Open fullscreen editor","virtualMcp.virtualMcp.promptTemplate":"+ Prompt template","virtualMcp.virtualMcp.promptTemplateContent":`<role>
56
56
  Define who this agent is and what it specializes in.
57
57
  Example: You are a support triage agent for B2B merchants.
58
58
  </role>
@@ -165,7 +165,7 @@ Este site ainda não reporta sections de post — quando reportar, cite elas aqu
165
165
  .block-interactivity-`.concat(e,` {pointer-events: none;}
166
166
  .allow-interactivity-`).concat(e,` {pointer-events: all;}
167
167
  `)},$oe=0,Nc=[];function qoe(e){var t=A.useRef([]),o=A.useRef([0,0]),a=A.useRef(),n=A.useState($oe++)[0],i=A.useState(wB)[0],l=A.useRef(e);A.useEffect(function(){l.current=e},[e]),A.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(n));var S=doe([e.lockRef.current],(e.shards||[]).map(HD),!0).filter(Boolean);return S.forEach(function(_){return _.classList.add("allow-interactivity-".concat(n))}),function(){document.body.classList.remove("block-interactivity-".concat(n)),S.forEach(function(_){return _.classList.remove("allow-interactivity-".concat(n))})}}},[e.inert,e.lockRef.current,e.shards]);var c=A.useCallback(function(S,_){if("touches"in S&&S.touches.length===2||S.type==="wheel"&&S.ctrlKey)return!l.current.allowPinchZoom;var T=Dg(S),x=o.current,P="deltaX"in S?S.deltaX:x[0]-T[0],C="deltaY"in S?S.deltaY:x[1]-T[1],E,R=S.target,D=Math.abs(P)>Math.abs(C)?"h":"v";if("touches"in S&&D==="h"&&R.type==="range")return!1;var O=window.getSelection(),L=O&&O.anchorNode,$=L?L===R||L.contains(R):!1;if($)return!1;var B=qD(D,R);if(!B)return!0;if(B?E=D:(E=D==="v"?"h":"v",B=qD(D,R)),!B)return!1;if(!a.current&&"changedTouches"in S&&(P||C)&&(a.current=E),!E)return!0;var U=a.current||E;return joe(U,_,S,U==="h"?P:C)},[]),u=A.useCallback(function(S){var _=S;if(!(!Nc.length||Nc[Nc.length-1]!==i)){var T="deltaY"in _?VD(_):Dg(_),x=t.current.filter(function(E){return E.name===_.type&&(E.target===_.target||_.target===E.shadowParent)&&zoe(E.delta,T)})[0];if(x&&x.should){_.cancelable&&_.preventDefault();return}if(!x){var P=(l.current.shards||[]).map(HD).filter(Boolean).filter(function(E){return E.contains(_.target)}),C=P.length>0?c(_,P[0]):!l.current.noIsolation;C&&_.cancelable&&_.preventDefault()}}},[]),p=A.useCallback(function(S,_,T,x){var P={name:S,delta:_,target:T,should:x,shadowParent:Voe(T)};t.current.push(P),setTimeout(function(){t.current=t.current.filter(function(C){return C!==P})},1)},[]),m=A.useCallback(function(S){o.current=Dg(S),a.current=void 0},[]),h=A.useCallback(function(S){p(S.type,VD(S),S.target,c(S,e.lockRef.current))},[]),f=A.useCallback(function(S){p(S.type,Dg(S),S.target,c(S,e.lockRef.current))},[]);A.useEffect(function(){return Nc.push(i),e.setCallbacks({onScrollCapture:h,onWheelCapture:h,onTouchMoveCapture:f}),document.addEventListener("wheel",u,Mc),document.addEventListener("touchmove",u,Mc),document.addEventListener("touchstart",m,Mc),function(){Nc=Nc.filter(function(S){return S!==i}),document.removeEventListener("wheel",u,Mc),document.removeEventListener("touchmove",u,Mc),document.removeEventListener("touchstart",m,Mc)}},[]);var v=e.removeScrollBar,b=e.inert;return A.createElement(A.Fragment,null,b?A.createElement(i,{styles:Uoe(n)}):null,v?A.createElement(Ooe,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function Voe(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const Hoe=yoe(SB,qoe);var P_=A.forwardRef(function(e,t){return A.createElement(Bv,zr({},e,{ref:t,sideCar:Hoe}))});P_.classNames=Bv.classNames;var dT=["Enter"," "],Goe=["ArrowDown","PageUp","Home"],kB=["ArrowUp","PageDown","End"],Woe=[...Goe,...kB],Koe={ltr:[...dT,"ArrowRight"],rtl:[...dT,"ArrowLeft"]},Yoe={ltr:["ArrowLeft"],rtl:["ArrowRight"]},om="Menu",[Ap,Zoe,Qoe]=OL(om),[zl,CB]=jl(om,[Qoe,eB,uB]),am=eB(),EB=uB(),[PB,Us]=zl(om),[Joe,nm]=zl(om),AB=e=>{const{__scopeMenu:t,open:o=!1,children:a,dir:n,onOpenChange:i,modal:l=!0}=e,c=am(t),[u,p]=A.useState(null),m=A.useRef(!1),h=Sr(i),f=ML(n);return A.useEffect(()=>{const v=()=>{m.current=!0,document.addEventListener("pointerdown",b,{capture:!0,once:!0}),document.addEventListener("pointermove",b,{capture:!0,once:!0})},b=()=>m.current=!1;return document.addEventListener("keydown",v,{capture:!0}),()=>{document.removeEventListener("keydown",v,{capture:!0}),document.removeEventListener("pointerdown",b,{capture:!0}),document.removeEventListener("pointermove",b,{capture:!0})}},[]),w.jsx(cB,{...c,children:w.jsx(PB,{scope:t,open:o,onOpenChange:h,content:u,onContentChange:p,children:w.jsx(Joe,{scope:t,onClose:A.useCallback(()=>h(!1),[h]),isUsingKeyboardRef:m,dir:f,modal:l,children:a})})})};AB.displayName=om;var Xoe="MenuAnchor",A_=A.forwardRef((e,t)=>{const{__scopeMenu:o,...a}=e,n=am(o);return w.jsx($te,{...n,...a,ref:t})});A_.displayName=Xoe;var R_="MenuPortal",[eae,RB]=zl(R_,{forceMount:void 0}),DB=e=>{const{__scopeMenu:t,forceMount:o,children:a,container:n}=e,i=Us(R_,t);return w.jsx(eae,{scope:t,forceMount:o,children:w.jsx(Ni,{present:o||i.open,children:w.jsx(E_,{asChild:!0,container:n,children:a})})})};DB.displayName=R_;var Qn="MenuContent",[tae,D_]=zl(Qn),OB=A.forwardRef((e,t)=>{const o=RB(Qn,e.__scopeMenu),{forceMount:a=o.forceMount,...n}=e,i=Us(Qn,e.__scopeMenu),l=nm(Qn,e.__scopeMenu);return w.jsx(Ap.Provider,{scope:e.__scopeMenu,children:w.jsx(Ni,{present:a||i.open,children:w.jsx(Ap.Slot,{scope:e.__scopeMenu,children:l.modal?w.jsx(oae,{...n,ref:t}):w.jsx(aae,{...n,ref:t})})})})}),oae=A.forwardRef((e,t)=>{const o=Us(Qn,e.__scopeMenu),a=A.useRef(null),n=sa(t,a);return A.useEffect(()=>{const i=a.current;if(i)return vB(i)},[]),w.jsx(O_,{...e,ref:n,trapFocus:o.open,disableOutsidePointerEvents:o.open,disableOutsideScroll:!0,onFocusOutside:mt(e.onFocusOutside,i=>i.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>o.onOpenChange(!1)})}),aae=A.forwardRef((e,t)=>{const o=Us(Qn,e.__scopeMenu);return w.jsx(O_,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>o.onOpenChange(!1)})}),nae=Ep("MenuContent.ScrollLock"),O_=A.forwardRef((e,t)=>{const{__scopeMenu:o,loop:a=!1,trapFocus:n,onOpenAutoFocus:i,onCloseAutoFocus:l,disableOutsidePointerEvents:c,onEntryFocus:u,onEscapeKeyDown:p,onPointerDownOutside:m,onFocusOutside:h,onInteractOutside:f,onDismiss:v,disableOutsideScroll:b,...S}=e,_=Us(Qn,o),T=nm(Qn,o),x=am(o),P=EB(o),C=Zoe(o),[E,R]=A.useState(null),D=A.useRef(null),O=sa(t,D,_.onContentChange),L=A.useRef(0),$=A.useRef(""),B=A.useRef(0),U=A.useRef(null),j=A.useRef("right"),W=A.useRef(0),ne=b?P_:A.Fragment,H=b?{as:nae,allowPinchZoom:!0}:void 0,Z=le=>{const Q=$.current+le,N=C().filter(pe=>!pe.disabled),G=document.activeElement,V=N.find(pe=>pe.ref.current===G)?.textValue,I=N.map(pe=>pe.textValue),z=fae(I,Q,V),J=N.find(pe=>pe.textValue===z)?.ref.current;(function pe(he){$.current=he,window.clearTimeout(L.current),he!==""&&(L.current=window.setTimeout(()=>pe(""),1e3))})(Q),J&&setTimeout(()=>J.focus())};A.useEffect(()=>()=>window.clearTimeout(L.current),[]),LL();const te=A.useCallback(le=>j.current===U.current?.side&&bae(le,U.current?.area),[]);return w.jsx(tae,{scope:o,searchRef:$,onItemEnter:A.useCallback(le=>{te(le)&&le.preventDefault()},[te]),onItemLeave:A.useCallback(le=>{te(le)||(D.current?.focus(),R(null))},[te]),onTriggerLeave:A.useCallback(le=>{te(le)&&le.preventDefault()},[te]),pointerGraceTimerRef:B,onPointerGraceIntentChange:A.useCallback(le=>{U.current=le},[]),children:w.jsx(ne,{...H,children:w.jsx(v_,{asChild:!0,trapped:n,onMountAutoFocus:mt(i,le=>{le.preventDefault(),D.current?.focus({preventScroll:!0})}),onUnmountAutoFocus:l,children:w.jsx(f_,{asChild:!0,disableOutsidePointerEvents:c,onEscapeKeyDown:p,onPointerDownOutside:m,onFocusOutside:h,onInteractOutside:f,onDismiss:v,children:w.jsx(roe,{asChild:!0,...P,dir:T.dir,orientation:"vertical",loop:a,currentTabStopId:E,onCurrentTabStopIdChange:R,onEntryFocus:mt(u,le=>{T.isUsingKeyboardRef.current||le.preventDefault()}),preventScrollOnEntryFocus:!0,children:w.jsx(qte,{role:"menu","aria-orientation":"vertical","data-state":YB(_.open),"data-radix-menu-content":"",dir:T.dir,...x,...S,ref:O,style:{outline:"none",...S.style},onKeyDown:mt(S.onKeyDown,le=>{const N=le.target.closest("[data-radix-menu-content]")===le.currentTarget,G=le.ctrlKey||le.altKey||le.metaKey,V=le.key.length===1;N&&(le.key==="Tab"&&le.preventDefault(),!G&&V&&Z(le.key));const I=D.current;if(le.target!==I||!Woe.includes(le.key))return;le.preventDefault();const J=C().filter(pe=>!pe.disabled).map(pe=>pe.ref.current);kB.includes(le.key)&&J.reverse(),hae(J)}),onBlur:mt(e.onBlur,le=>{le.currentTarget.contains(le.target)||(window.clearTimeout(L.current),$.current="")}),onPointerMove:mt(e.onPointerMove,Rp(le=>{const Q=le.target,N=W.current!==le.clientX;if(le.currentTarget.contains(Q)&&N){const G=le.clientX>W.current?"right":"left";j.current=G,W.current=le.clientX}}))})})})})})})});OB.displayName=Qn;var rae="MenuGroup",M_=A.forwardRef((e,t)=>{const{__scopeMenu:o,...a}=e;return w.jsx(Ao.div,{role:"group",...a,ref:t})});M_.displayName=rae;var iae="MenuLabel",MB=A.forwardRef((e,t)=>{const{__scopeMenu:o,...a}=e;return w.jsx(Ao.div,{...a,ref:t})});MB.displayName=iae;var Nf="MenuItem",GD="menu.itemSelect",Fv=A.forwardRef((e,t)=>{const{disabled:o=!1,onSelect:a,...n}=e,i=A.useRef(null),l=nm(Nf,e.__scopeMenu),c=D_(Nf,e.__scopeMenu),u=sa(t,i),p=A.useRef(!1),m=()=>{const h=i.current;if(!o&&h){const f=new CustomEvent(GD,{bubbles:!0,cancelable:!0});h.addEventListener(GD,v=>a?.(v),{once:!0}),DL(h,f),f.defaultPrevented?p.current=!1:l.onClose()}};return w.jsx(NB,{...n,ref:u,disabled:o,onClick:mt(e.onClick,m),onPointerDown:h=>{e.onPointerDown?.(h),p.current=!0},onPointerUp:mt(e.onPointerUp,h=>{p.current||h.currentTarget?.click()}),onKeyDown:mt(e.onKeyDown,h=>{const f=c.searchRef.current!=="";o||f&&h.key===" "||dT.includes(h.key)&&(h.currentTarget.click(),h.preventDefault())})})});Fv.displayName=Nf;var NB=A.forwardRef((e,t)=>{const{__scopeMenu:o,disabled:a=!1,textValue:n,...i}=e,l=D_(Nf,o),c=EB(o),u=A.useRef(null),p=sa(t,u),[m,h]=A.useState(!1),[f,v]=A.useState("");return A.useEffect(()=>{const b=u.current;b&&v((b.textContent??"").trim())},[i.children]),w.jsx(Ap.ItemSlot,{scope:o,disabled:a,textValue:n??f,children:w.jsx(ioe,{asChild:!0,...c,focusable:!a,children:w.jsx(Ao.div,{role:"menuitem","data-highlighted":m?"":void 0,"aria-disabled":a||void 0,"data-disabled":a?"":void 0,...i,ref:p,onPointerMove:mt(e.onPointerMove,Rp(b=>{a?l.onItemLeave(b):(l.onItemEnter(b),b.defaultPrevented||b.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:mt(e.onPointerLeave,Rp(b=>l.onItemLeave(b))),onFocus:mt(e.onFocus,()=>h(!0)),onBlur:mt(e.onBlur,()=>h(!1))})})})}),sae="MenuCheckboxItem",IB=A.forwardRef((e,t)=>{const{checked:o=!1,onCheckedChange:a,...n}=e;return w.jsx(zB,{scope:e.__scopeMenu,checked:o,children:w.jsx(Fv,{role:"menuitemcheckbox","aria-checked":If(o)?"mixed":o,...n,ref:t,"data-state":L_(o),onSelect:mt(n.onSelect,()=>a?.(If(o)?!0:!o),{checkForDefaultPrevented:!1})})})});IB.displayName=sae;var LB="MenuRadioGroup",[lae,cae]=zl(LB,{value:void 0,onValueChange:()=>{}}),BB=A.forwardRef((e,t)=>{const{value:o,onValueChange:a,...n}=e,i=Sr(a);return w.jsx(lae,{scope:e.__scopeMenu,value:o,onValueChange:i,children:w.jsx(M_,{...n,ref:t})})});BB.displayName=LB;var FB="MenuRadioItem",jB=A.forwardRef((e,t)=>{const{value:o,...a}=e,n=cae(FB,e.__scopeMenu),i=o===n.value;return w.jsx(zB,{scope:e.__scopeMenu,checked:i,children:w.jsx(Fv,{role:"menuitemradio","aria-checked":i,...a,ref:t,"data-state":L_(i),onSelect:mt(a.onSelect,()=>n.onValueChange?.(o),{checkForDefaultPrevented:!1})})})});jB.displayName=FB;var N_="MenuItemIndicator",[zB,dae]=zl(N_,{checked:!1}),UB=A.forwardRef((e,t)=>{const{__scopeMenu:o,forceMount:a,...n}=e,i=dae(N_,o);return w.jsx(Ni,{present:a||If(i.checked)||i.checked===!0,children:w.jsx(Ao.span,{...n,ref:t,"data-state":L_(i.checked)})})});UB.displayName=N_;var uae="MenuSeparator",$B=A.forwardRef((e,t)=>{const{__scopeMenu:o,...a}=e;return w.jsx(Ao.div,{role:"separator","aria-orientation":"horizontal",...a,ref:t})});$B.displayName=uae;var pae="MenuArrow",qB=A.forwardRef((e,t)=>{const{__scopeMenu:o,...a}=e,n=am(o);return w.jsx(Vte,{...n,...a,ref:t})});qB.displayName=pae;var I_="MenuSub",[mae,VB]=zl(I_),HB=e=>{const{__scopeMenu:t,children:o,open:a=!1,onOpenChange:n}=e,i=Us(I_,t),l=am(t),[c,u]=A.useState(null),[p,m]=A.useState(null),h=Sr(n);return A.useEffect(()=>(i.open===!1&&h(!1),()=>h(!1)),[i.open,h]),w.jsx(cB,{...l,children:w.jsx(PB,{scope:t,open:a,onOpenChange:h,content:p,onContentChange:m,children:w.jsx(mae,{scope:t,contentId:Rs(),triggerId:Rs(),trigger:c,onTriggerChange:u,children:o})})})};HB.displayName=I_;var Ju="MenuSubTrigger",GB=A.forwardRef((e,t)=>{const o=Us(Ju,e.__scopeMenu),a=nm(Ju,e.__scopeMenu),n=VB(Ju,e.__scopeMenu),i=D_(Ju,e.__scopeMenu),l=A.useRef(null),{pointerGraceTimerRef:c,onPointerGraceIntentChange:u}=i,p={__scopeMenu:e.__scopeMenu},m=A.useCallback(()=>{l.current&&window.clearTimeout(l.current),l.current=null},[]);return A.useEffect(()=>m,[m]),A.useEffect(()=>{const h=c.current;return()=>{window.clearTimeout(h),u(null)}},[c,u]),w.jsx(A_,{asChild:!0,...p,children:w.jsx(NB,{id:n.triggerId,"aria-haspopup":"menu","aria-expanded":o.open,"aria-controls":n.contentId,"data-state":YB(o.open),...e,ref:Jp(t,n.onTriggerChange),onClick:h=>{e.onClick?.(h),!(e.disabled||h.defaultPrevented)&&(h.currentTarget.focus(),o.open||o.onOpenChange(!0))},onPointerMove:mt(e.onPointerMove,Rp(h=>{i.onItemEnter(h),!h.defaultPrevented&&!e.disabled&&!o.open&&!l.current&&(i.onPointerGraceIntentChange(null),l.current=window.setTimeout(()=>{o.onOpenChange(!0),m()},100))})),onPointerLeave:mt(e.onPointerLeave,Rp(h=>{m();const f=o.content?.getBoundingClientRect();if(f){const v=o.content?.dataset.side,b=v==="right",S=b?-5:5,_=f[b?"left":"right"],T=f[b?"right":"left"];i.onPointerGraceIntentChange({area:[{x:h.clientX+S,y:h.clientY},{x:_,y:f.top},{x:T,y:f.top},{x:T,y:f.bottom},{x:_,y:f.bottom}],side:v}),window.clearTimeout(c.current),c.current=window.setTimeout(()=>i.onPointerGraceIntentChange(null),300)}else{if(i.onTriggerLeave(h),h.defaultPrevented)return;i.onPointerGraceIntentChange(null)}})),onKeyDown:mt(e.onKeyDown,h=>{const f=i.searchRef.current!=="";e.disabled||f&&h.key===" "||Koe[a.dir].includes(h.key)&&(o.onOpenChange(!0),o.content?.focus(),h.preventDefault())})})})});GB.displayName=Ju;var WB="MenuSubContent",KB=A.forwardRef((e,t)=>{const o=RB(Qn,e.__scopeMenu),{forceMount:a=o.forceMount,...n}=e,i=Us(Qn,e.__scopeMenu),l=nm(Qn,e.__scopeMenu),c=VB(WB,e.__scopeMenu),u=A.useRef(null),p=sa(t,u);return w.jsx(Ap.Provider,{scope:e.__scopeMenu,children:w.jsx(Ni,{present:a||i.open,children:w.jsx(Ap.Slot,{scope:e.__scopeMenu,children:w.jsx(O_,{id:c.contentId,"aria-labelledby":c.triggerId,...n,ref:p,align:"start",side:l.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:m=>{l.isUsingKeyboardRef.current&&u.current?.focus(),m.preventDefault()},onCloseAutoFocus:m=>m.preventDefault(),onFocusOutside:mt(e.onFocusOutside,m=>{m.target!==c.trigger&&i.onOpenChange(!1)}),onEscapeKeyDown:mt(e.onEscapeKeyDown,m=>{l.onClose(),m.preventDefault()}),onKeyDown:mt(e.onKeyDown,m=>{const h=m.currentTarget.contains(m.target),f=Yoe[l.dir].includes(m.key);h&&f&&(i.onOpenChange(!1),c.trigger?.focus(),m.preventDefault())})})})})})});KB.displayName=WB;function YB(e){return e?"open":"closed"}function If(e){return e==="indeterminate"}function L_(e){return If(e)?"indeterminate":e?"checked":"unchecked"}function hae(e){const t=document.activeElement;for(const o of e)if(o===t||(o.focus(),document.activeElement!==t))return}function gae(e,t){return e.map((o,a)=>e[(t+a)%e.length])}function fae(e,t,o){const n=t.length>1&&Array.from(t).every(p=>p===t[0])?t[0]:t,i=o?e.indexOf(o):-1;let l=gae(e,Math.max(i,0));n.length===1&&(l=l.filter(p=>p!==o));const u=l.find(p=>p.toLowerCase().startsWith(n.toLowerCase()));return u!==o?u:void 0}function vae(e,t){const{x:o,y:a}=e;let n=!1;for(let i=0,l=t.length-1;i<t.length;l=i++){const c=t[i],u=t[l],p=c.x,m=c.y,h=u.x,f=u.y;m>a!=f>a&&o<(h-p)*(a-m)/(f-m)+p&&(n=!n)}return n}function bae(e,t){if(!t)return!1;const o={x:e.clientX,y:e.clientY};return vae(o,t)}function Rp(e){return t=>t.pointerType==="mouse"?e(t):void 0}var yae=AB,Sae=A_,wae=DB,Tae=OB,xae=M_,_ae=MB,kae=Fv,Cae=IB,Eae=BB,Pae=jB,Aae=UB,Rae=$B,Dae=qB,Oae=HB,Mae=GB,Nae=KB,jv="DropdownMenu",[Iae]=jl(jv,[CB]),ja=CB(),[Lae,ZB]=Iae(jv),QB=e=>{const{__scopeDropdownMenu:t,children:o,dir:a,open:n,defaultOpen:i,onOpenChange:l,modal:c=!0}=e,u=ja(t),p=A.useRef(null),[m,h]=Xp({prop:n,defaultProp:i??!1,onChange:l,caller:jv});return w.jsx(Lae,{scope:t,triggerId:Rs(),triggerRef:p,contentId:Rs(),open:m,onOpenChange:h,onOpenToggle:A.useCallback(()=>h(f=>!f),[h]),modal:c,children:w.jsx(yae,{...u,open:m,onOpenChange:h,dir:a,modal:c,children:o})})};QB.displayName=jv;var JB="DropdownMenuTrigger",XB=A.forwardRef((e,t)=>{const{__scopeDropdownMenu:o,disabled:a=!1,...n}=e,i=ZB(JB,o),l=ja(o);return w.jsx(Sae,{asChild:!0,...l,children:w.jsx(Ao.button,{type:"button",id:i.triggerId,"aria-haspopup":"menu","aria-expanded":i.open,"aria-controls":i.open?i.contentId:void 0,"data-state":i.open?"open":"closed","data-disabled":a?"":void 0,disabled:a,...n,ref:Jp(t,i.triggerRef),onPointerDown:mt(e.onPointerDown,c=>{!a&&c.button===0&&c.ctrlKey===!1&&(i.onOpenToggle(),i.open||c.preventDefault())}),onKeyDown:mt(e.onKeyDown,c=>{a||(["Enter"," "].includes(c.key)&&i.onOpenToggle(),c.key==="ArrowDown"&&i.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(c.key)&&c.preventDefault())})})})});XB.displayName=JB;var Bae="DropdownMenuPortal",eF=e=>{const{__scopeDropdownMenu:t,...o}=e,a=ja(t);return w.jsx(wae,{...a,...o})};eF.displayName=Bae;var tF="DropdownMenuContent",oF=A.forwardRef((e,t)=>{const{__scopeDropdownMenu:o,...a}=e,n=ZB(tF,o),i=ja(o),l=A.useRef(!1);return w.jsx(Tae,{id:n.contentId,"aria-labelledby":n.triggerId,...i,...a,ref:t,onCloseAutoFocus:mt(e.onCloseAutoFocus,c=>{l.current||n.triggerRef.current?.focus(),l.current=!1,c.preventDefault()}),onInteractOutside:mt(e.onInteractOutside,c=>{const u=c.detail.originalEvent,p=u.button===0&&u.ctrlKey===!0,m=u.button===2||p;(!n.modal||m)&&(l.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});oF.displayName=tF;var Fae="DropdownMenuGroup",jae=A.forwardRef((e,t)=>{const{__scopeDropdownMenu:o,...a}=e,n=ja(o);return w.jsx(xae,{...n,...a,ref:t})});jae.displayName=Fae;var zae="DropdownMenuLabel",aF=A.forwardRef((e,t)=>{const{__scopeDropdownMenu:o,...a}=e,n=ja(o);return w.jsx(_ae,{...n,...a,ref:t})});aF.displayName=zae;var Uae="DropdownMenuItem",nF=A.forwardRef((e,t)=>{const{__scopeDropdownMenu:o,...a}=e,n=ja(o);return w.jsx(kae,{...n,...a,ref:t})});nF.displayName=Uae;var $ae="DropdownMenuCheckboxItem",rF=A.forwardRef((e,t)=>{const{__scopeDropdownMenu:o,...a}=e,n=ja(o);return w.jsx(Cae,{...n,...a,ref:t})});rF.displayName=$ae;var qae="DropdownMenuRadioGroup",iF=A.forwardRef((e,t)=>{const{__scopeDropdownMenu:o,...a}=e,n=ja(o);return w.jsx(Eae,{...n,...a,ref:t})});iF.displayName=qae;var Vae="DropdownMenuRadioItem",sF=A.forwardRef((e,t)=>{const{__scopeDropdownMenu:o,...a}=e,n=ja(o);return w.jsx(Pae,{...n,...a,ref:t})});sF.displayName=Vae;var Hae="DropdownMenuItemIndicator",lF=A.forwardRef((e,t)=>{const{__scopeDropdownMenu:o,...a}=e,n=ja(o);return w.jsx(Aae,{...n,...a,ref:t})});lF.displayName=Hae;var Gae="DropdownMenuSeparator",cF=A.forwardRef((e,t)=>{const{__scopeDropdownMenu:o,...a}=e,n=ja(o);return w.jsx(Rae,{...n,...a,ref:t})});cF.displayName=Gae;var Wae="DropdownMenuArrow",Kae=A.forwardRef((e,t)=>{const{__scopeDropdownMenu:o,...a}=e,n=ja(o);return w.jsx(Dae,{...n,...a,ref:t})});Kae.displayName=Wae;var Yae=e=>{const{__scopeDropdownMenu:t,children:o,open:a,onOpenChange:n,defaultOpen:i}=e,l=ja(t),[c,u]=Xp({prop:a,defaultProp:i??!1,onChange:n,caller:"DropdownMenuSub"});return w.jsx(Oae,{...l,open:c,onOpenChange:u,children:o})},Zae="DropdownMenuSubTrigger",dF=A.forwardRef((e,t)=>{const{__scopeDropdownMenu:o,...a}=e,n=ja(o);return w.jsx(Mae,{...n,...a,ref:t})});dF.displayName=Zae;var Qae="DropdownMenuSubContent",uF=A.forwardRef((e,t)=>{const{__scopeDropdownMenu:o,...a}=e,n=ja(o);return w.jsx(Nae,{...n,...a,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});uF.displayName=Qae;var pF=QB,mF=XB,hF=eF,gF=oF,Jae=aF,fF=nF,Xae=rF,ene=iF,tne=sF,vF=lF,one=cF,ane=Yae,nne=dF,rne=uF;const B_=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M12 9v4m0 4h.01M10.615 3.892 2.39 18.098c-.456.788-.684 1.182-.65 1.506a1 1 0 0 0 .406.705c.263.191.718.191 1.629.191h16.45c.91 0 1.365 0 1.628-.191a1 1 0 0 0 .407-.705c.034-.324-.195-.718-.65-1.506L13.383 3.892c-.454-.785-.681-1.178-.978-1.31a1 1 0 0 0-.813 0c-.296.132-.523.525-.978 1.31Z"}));B_.displayName="AlertTriangle";const bF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M4 7.997a2.295 2.295 0 0 1-.39-.035A2 2 0 0 1 2.038 6.39C2 6.197 2 5.965 2 5.5s0-.697.038-.89A2 2 0 0 1 3.61 3.038C3.803 3 4.035 3 4.5 3h15c.465 0 .697 0 .89.038a2 2 0 0 1 1.572 1.572c.038.193.038.425.038.89s0 .697-.038.89a2 2 0 0 1-1.572 1.572c-.107.02-.226.03-.39.035M10 13h4M4 8h16v8.2c0 1.68 0 2.52-.327 3.162a3 3 0 0 1-1.311 1.311C17.72 21 16.88 21 15.2 21H8.8c-1.68 0-2.52 0-3.162-.327a3 3 0 0 1-1.311-1.311C4 18.72 4 17.88 4 16.2V8Z"}));bF.displayName="Archive";const yF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M7 17 17 7m0 0H7m10 0v10"}));yF.displayName="ArrowUpRight";const SF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M20 6 9 17l-5-5"}));SF.displayName="Check";const F_=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"m9 18 6-6-6-6"}));F_.displayName="ChevronRight";const wF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10Z"}));wF.displayName="Circle";const TF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M9 2v2m6-2v2M9 20v2m6-2v2m5-13h2m-2 5h2M2 9h2m-2 5h2m4.8 6h6.4c1.68 0 2.52 0 3.162-.327a3 3 0 0 0 1.311-1.311C20 17.72 20 16.88 20 15.2V8.8c0-1.68 0-2.52-.327-3.162a3 3 0 0 0-1.311-1.311C17.72 4 16.88 4 15.2 4H8.8c-1.68 0-2.52 0-3.162.327a3 3 0 0 0-1.311 1.311C4 6.28 4 7.12 4 8.8v6.4c0 1.68 0 2.52.327 3.162a3 3 0 0 0 1.311 1.311C6.28 20 7.12 20 8.8 20Zm1.8-5h2.8c.56 0 .84 0 1.054-.109a1 1 0 0 0 .437-.437C15 14.24 15 13.96 15 13.4v-2.8c0-.56 0-.84-.109-1.054a1 1 0 0 0-.437-.437C14.24 9 13.96 9 13.4 9h-2.8c-.56 0-.84 0-1.054.109a1 1 0 0 0-.437.437C9 9.76 9 10.04 9 10.6v2.8c0 .56 0 .84.109 1.054a1 1 0 0 0 .437.437C9.76 15 10.04 15 10.6 15Z"}));TF.displayName="CpuChip01";const xF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M12 13a1 1 0 1 0 0-2 1 1 0 0 0 0 2Zm7 0a1 1 0 1 0 0-2 1 1 0 0 0 0 2ZM5 13a1 1 0 1 0 0-2 1 1 0 0 0 0 2Z"}));xF.displayName="DotsHorizontal";const _F=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M3 3v10.2c0 1.68 0 2.52.327 3.162a3 3 0 0 0 1.311 1.311C5.28 18 6.12 18 7.8 18H15m0 0a3 3 0 1 0 6 0 3 3 0 0 0-6 0ZM3 8h12m0 0a3 3 0 1 0 6 0 3 3 0 0 0-6 0Z"}));_F.displayName="GitBranch01";const kF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M2.5 12h19M6 16h4M8.967 4h6.066c1.077 0 1.616 0 2.091.164a3 3 0 0 1 1.121.693c.36.352.6.833 1.082 1.796l2.166 4.333c.19.378.284.567.35.765.06.177.102.357.128.541.029.207.029.418.029.841V15.2c0 1.68 0 2.52-.327 3.162a3 3 0 0 1-1.311 1.311C19.72 20 18.88 20 17.2 20H6.8c-1.68 0-2.52 0-3.162-.327a3 3 0 0 1-1.311-1.311C2 17.72 2 16.88 2 15.2v-2.067c0-.422 0-.634.029-.84.026-.184.068-.365.128-.541.066-.199.16-.388.35-.766l2.166-4.333c.482-.963.723-1.444 1.082-1.796a3 3 0 0 1 1.12-.693C7.352 4 7.89 4 8.968 4Z"}));kF.displayName="HardDrive";const CF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M21 9V3m0 0h-6m6 0-8 8m-3-6H7.8c-1.68 0-2.52 0-3.162.327a3 3 0 0 0-1.311 1.311C3 7.28 3 8.12 3 9.8v6.4c0 1.68 0 2.52.327 3.162a3 3 0 0 0 1.311 1.311C5.28 21 6.12 21 7.8 21h6.4c1.68 0 2.52 0 3.162-.327a3 3 0 0 0 1.311-1.311C19 18.72 19 17.88 19 16.2V14"}));CF.displayName="LinkExternal01";const EF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M17 10V8A5 5 0 0 0 7 8v2m5 4.5v2M8.8 21h6.4c1.68 0 2.52 0 3.162-.327a3 3 0 0 0 1.311-1.311C20 18.72 20 17.88 20 16.2v-1.4c0-1.68 0-2.52-.327-3.162a3 3 0 0 0-1.311-1.311C17.72 10 16.88 10 15.2 10H8.8c-1.68 0-2.52 0-3.162.327a3 3 0 0 0-1.311 1.311C4 12.28 4 13.12 4 14.8v1.4c0 1.68 0 2.52.327 3.162a3 3 0 0 0 1.311 1.311C6.28 21 7.12 21 8.8 21Z"}));EF.displayName="Lock01";const PF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M21 10s-2.005-2.732-3.634-4.362a9 9 0 1 0 2.282 8.862M21 10V4m0 6h-6"}));PF.displayName="RefreshCw01";const AF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M6 6h.01M6 18h.01m-.81-8h13.6c1.12 0 1.68 0 2.108-.218a2 2 0 0 0 .874-.874C22 8.48 22 7.92 22 6.8V5.2c0-1.12 0-1.68-.218-2.108a2 2 0 0 0-.874-.874C20.48 2 19.92 2 18.8 2H5.2c-1.12 0-1.68 0-2.108.218a2 2 0 0 0-.874.874C2 3.52 2 4.08 2 5.2v1.6c0 1.12 0 1.68.218 2.108a2 2 0 0 0 .874.874C3.52 10 4.08 10 5.2 10Zm0 12h13.6c1.12 0 1.68 0 2.108-.218a2 2 0 0 0 .874-.874C22 20.48 22 19.92 22 18.8v-1.6c0-1.12 0-1.68-.218-2.108a2 2 0 0 0-.874-.874C20.48 14 19.92 14 18.8 14H5.2c-1.12 0-1.68 0-2.108.218a2 2 0 0 0-.874.874C2 15.52 2 16.08 2 17.2v1.6c0 1.12 0 1.68.218 2.108a2 2 0 0 0 .874.874C3.52 22 4.08 22 5.2 22Z"}));AF.displayName="Server01";const RF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M11.302 21.615c.221.129.332.194.488.227.122.026.298.026.42 0 .156-.034.267-.098.488-.227C14.646 20.478 20 16.908 20 12V7.217c0-.799 0-1.199-.13-1.542a2 2 0 0 0-.548-.79c-.275-.243-.65-.383-1.398-.664l-5.362-2.01c-.208-.078-.312-.117-.419-.133a1 1 0 0 0-.286 0c-.107.016-.21.055-.419.133L6.076 4.22c-.748.28-1.122.421-1.398.664a2 2 0 0 0-.547.79C4 6.018 4 6.418 4 7.217V12c0 4.908 5.354 8.478 7.302 9.615Z"}));RF.displayName="Shield01";const DF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M18 15.837c1.456.731 2.704 1.905 3.615 3.373.18.29.27.436.302.637.063.409-.216.912-.597 1.073-.188.08-.398.08-.82.08M16 11.532a4.5 4.5 0 0 0 0-8.064M14 7.5a4.5 4.5 0 1 1-9 0 4.5 4.5 0 0 1 9 0ZM2.56 18.938C4.153 16.545 6.67 15 9.5 15s5.346 1.545 6.94 3.938c.35.525.525.787.505 1.122-.016.26-.187.58-.396.738-.267.202-.635.202-1.371.202H3.822c-.736 0-1.104 0-1.372-.202a1.109 1.109 0 0 1-.395-.738c-.02-.335.155-.597.504-1.122Z"}));DF.displayName="Users03";const OF=({size:e=24,color:t="currentColor",...o})=>A.createElement("svg",{viewBox:"0 0 24 24",width:e,height:e,stroke:t,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},A.createElement("path",{d:"M17 7 7 17M7 7l10 10"}));OF.displayName="X";function ine(e){const t=Re.c(4);let o;t[0]!==e?({...o}=e,t[0]=e,t[1]=o):o=t[1];let a;return t[2]!==o?(a=w.jsx(pF,{"data-slot":"dropdown-menu",...o}),t[2]=o,t[3]=a):a=t[3],a}function sne(e){const t=Re.c(4);let o;t[0]!==e?({...o}=e,t[0]=e,t[1]=o):o=t[1];let a;return t[2]!==o?(a=w.jsx(mF,{"data-slot":"dropdown-menu-trigger",...o}),t[2]=o,t[3]=a):a=t[3],a}function lne(e){const t=Re.c(10);let o,a,n;t[0]!==e?({className:o,sideOffset:n,...a}=e,t[0]=e,t[1]=o,t[2]=a,t[3]=n):(o=t[1],a=t[2],n=t[3]);const i=n===void 0?4:n;let l;t[4]!==o?(l=gt("notranslate bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 max-h-(--radix-dropdown-menu-content-available-height) min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg border p-1 shadow-md",o),t[4]=o,t[5]=l):l=t[5];let c;return t[6]!==a||t[7]!==i||t[8]!==l?(c=w.jsx(hF,{children:w.jsx(gF,{"data-slot":"dropdown-menu-content",sideOffset:i,translate:"no",className:l,...a})}),t[6]=a,t[7]=i,t[8]=l,t[9]=c):c=t[9],c}function cne(e){const t=Re.c(12);let o,a,n,i;t[0]!==e?({className:o,inset:a,variant:i,...n}=e,t[0]=e,t[1]=o,t[2]=a,t[3]=n,t[4]=i):(o=t[1],a=t[2],n=t[3],i=t[4]);const l=i===void 0?"default":i;let c;t[5]!==o?(c=gt("focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:!text-destructive [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-pointer items-center gap-2 rounded-lg px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",o),t[5]=o,t[6]=c):c=t[6];let u;return t[7]!==a||t[8]!==n||t[9]!==c||t[10]!==l?(u=w.jsx(fF,{"data-slot":"dropdown-menu-item","data-inset":a,"data-variant":l,className:c,...n}),t[7]=a,t[8]=n,t[9]=c,t[10]=l,t[11]=u):u=t[11],u}function wve(e){const t=Re.c(13);let o,a,n,i;t[0]!==e?({className:n,children:a,checked:o,...i}=e,t[0]=e,t[1]=o,t[2]=a,t[3]=n,t[4]=i):(o=t[1],a=t[2],n=t[3],i=t[4]);let l;t[5]!==n?(l=gt("focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-lg py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",n),t[5]=n,t[6]=l):l=t[6];let c;t[7]===Symbol.for("react.memo_cache_sentinel")?(c=w.jsx("span",{className:"pointer-events-none absolute left-2 flex size-3.5 items-center justify-center",children:w.jsx(vF,{children:w.jsx(SF,{className:"size-4"})})}),t[7]=c):c=t[7];let u;return t[8]!==o||t[9]!==a||t[10]!==i||t[11]!==l?(u=w.jsxs(Xae,{"data-slot":"dropdown-menu-checkbox-item",className:l,checked:o,...i,children:[c,a]}),t[8]=o,t[9]=a,t[10]=i,t[11]=l,t[12]=u):u=t[12],u}function Tve(e){const t=Re.c(4);let o;t[0]!==e?({...o}=e,t[0]=e,t[1]=o):o=t[1];let a;return t[2]!==o?(a=w.jsx(ene,{"data-slot":"dropdown-menu-radio-group",...o}),t[2]=o,t[3]=a):a=t[3],a}function xve(e){const t=Re.c(11);let o,a,n;t[0]!==e?({className:a,children:o,...n}=e,t[0]=e,t[1]=o,t[2]=a,t[3]=n):(o=t[1],a=t[2],n=t[3]);let i;t[4]!==a?(i=gt("focus:bg-accent focus:text-accent-foreground relative flex cursor-default items-center gap-2 rounded-lg py-1.5 pr-2 pl-8 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",a),t[4]=a,t[5]=i):i=t[5];let l;t[6]===Symbol.for("react.memo_cache_sentinel")?(l=w.jsx("span",{className:"pointer-events-none absolute left-2 flex size-3.5 items-center justify-center",children:w.jsx(vF,{children:w.jsx(wF,{className:"size-2 fill-current"})})}),t[6]=l):l=t[6];let c;return t[7]!==o||t[8]!==n||t[9]!==i?(c=w.jsxs(tne,{"data-slot":"dropdown-menu-radio-item",className:i,...n,children:[l,o]}),t[7]=o,t[8]=n,t[9]=i,t[10]=c):c=t[10],c}function _ve(e){const t=Re.c(10);let o,a,n;t[0]!==e?({className:o,inset:a,...n}=e,t[0]=e,t[1]=o,t[2]=a,t[3]=n):(o=t[1],a=t[2],n=t[3]);let i;t[4]!==o?(i=gt("px-2 py-1.5 text-sm font-medium data-[inset]:pl-8",o),t[4]=o,t[5]=i):i=t[5];let l;return t[6]!==a||t[7]!==n||t[8]!==i?(l=w.jsx(Jae,{"data-slot":"dropdown-menu-label","data-inset":a,className:i,...n}),t[6]=a,t[7]=n,t[8]=i,t[9]=l):l=t[9],l}function kve(e){const t=Re.c(8);let o,a;t[0]!==e?({className:o,...a}=e,t[0]=e,t[1]=o,t[2]=a):(o=t[1],a=t[2]);let n;t[3]!==o?(n=gt("bg-border -mx-1 my-1 h-px",o),t[3]=o,t[4]=n):n=t[4];let i;return t[5]!==a||t[6]!==n?(i=w.jsx(one,{"data-slot":"dropdown-menu-separator",className:n,...a}),t[5]=a,t[6]=n,t[7]=i):i=t[7],i}function Cve(e){const t=Re.c(4);let o;t[0]!==e?({...o}=e,t[0]=e,t[1]=o):o=t[1];let a;return t[2]!==o?(a=w.jsx(ane,{"data-slot":"dropdown-menu-sub",...o}),t[2]=o,t[3]=a):a=t[3],a}function Eve(e){const t=Re.c(13);let o,a,n,i;t[0]!==e?({className:a,inset:n,children:o,...i}=e,t[0]=e,t[1]=o,t[2]=a,t[3]=n,t[4]=i):(o=t[1],a=t[2],n=t[3],i=t[4]);let l;t[5]!==a?(l=gt("focus:bg-accent focus:text-accent-foreground data-[state=open]:bg-accent data-[state=open]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground flex cursor-default items-center gap-2 rounded-lg px-2 py-1.5 text-sm outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",a),t[5]=a,t[6]=l):l=t[6];let c;t[7]===Symbol.for("react.memo_cache_sentinel")?(c=w.jsx(F_,{className:"ml-auto size-4"}),t[7]=c):c=t[7];let u;return t[8]!==o||t[9]!==n||t[10]!==i||t[11]!==l?(u=w.jsxs(nne,{"data-slot":"dropdown-menu-sub-trigger","data-inset":n,className:l,...i,children:[o,c]}),t[8]=o,t[9]=n,t[10]=i,t[11]=l,t[12]=u):u=t[12],u}function Pve(e){const t=Re.c(8);let o,a;t[0]!==e?({className:o,...a}=e,t[0]=e,t[1]=o,t[2]=a):(o=t[1],a=t[2]);let n;t[3]!==o?(n=gt("notranslate bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 min-w-[8rem] origin-(--radix-dropdown-menu-content-transform-origin) overflow-hidden rounded-md border p-1 shadow-lg",o),t[3]=o,t[4]=n):n=t[4];let i;return t[5]!==a||t[6]!==n?(i=w.jsx(rne,{"data-slot":"dropdown-menu-sub-content",translate:"no",className:n,...a}),t[5]=a,t[6]=n,t[7]=i):i=t[7],i}function dne(){const e=Re.c(3),[t,o]=A.useState(-1);let a;e[0]===Symbol.for("react.memo_cache_sentinel")?(a=l=>{if(!l)return;const c=()=>o(l.clientWidth);c();const u=new ResizeObserver(c);return u.observe(l),()=>u.disconnect()},e[0]=a):a=e[0];const n=a;let i;return e[1]!==t?(i=[t,n],e[1]=t,e[2]=i):i=e[2],i}function une(){let e=new Map;const t=new Set,o=()=>t.forEach(a=>a());return{getSnapshot:()=>e,subscribe(a){return t.add(a),()=>{t.delete(a)}},register(a){if(e.has(a.after))throw new Error(`Two components extend breadcrumb: ${a.after}`);return e=new Map(e).set(a.after,a),o(),()=>{if(e.get(a.after)!==a)return;const n=new Map(e);n.delete(a.after),e=n,o()}}}}const MF=A.createContext(null);function pne(e){const t=Re.c(3),{children:o}=e,[a]=A.useState(une);let n;return t[0]!==o||t[1]!==a?(n=w.jsx(MF,{value:a,children:o}),t[0]=o,t[1]=a,t[2]=n):n=t[2],n}function zv(){return A.use(MF)}function NF(e){const t=Re.c(3),o=zv();if(!o)throw new Error("Breadcrumb contributions require Page.Breadcrumbs.Provider");let a;return t[0]!==e||t[1]!==o?(a=w.jsx("span",{hidden:!0,ref:n=>n?o.register(e):void 0}),t[0]=e,t[1]=o,t[2]=a):a=t[2],a}function mne(e,t){const o=new Set,a=n=>{if(o.has(n.key))throw new Error(`Duplicate breadcrumb key: ${n.key}`);o.add(n.key);const i=t.get(n.key);return[{...n,...i?.parent},...i?.items?.flatMap(a)??[]]};return e.flatMap(a)}function hne(e,t){const o=e.map(a=>a.label).filter(a=>typeof a=="string").reverse();return t&&o.push(t),o.map(a=>a.trim()).filter(Boolean).join(" · ")}const IF=5;function gne(e,t=!1,o=IF){const a=e.map(l=>({type:"item",item:l}));if(e.length<=(t?1:o))return a;const n=t?0:1,i=e.length-(t?1:2);return a.splice(n,i-n,{type:"menu",items:e.slice(n,i)}),a}const LF=T$(function(t){return w.jsx("a",{...t,"aria-current":void 0})});function fne(e){const t=Re.c(12),{items:o}=e,a=ar();let n;t[0]!==a?(n=a("page.breadcrumbMenu"),t[0]=a,t[1]=n):n=t[1];let i;t[2]===Symbol.for("react.memo_cache_sentinel")?(i=w.jsx(xF,{"aria-hidden":"true",className:"size-4"}),t[2]=i):i=t[2];let l;t[3]!==n?(l=w.jsx(sne,{asChild:!0,children:w.jsx(Ri,{variant:"ghost",size:"icon-sm",className:"size-6 shrink-0","aria-label":n,children:i})}),t[3]=n,t[4]=l):l=t[4];let c;t[5]!==o?(c=o.map(vne),t[5]=o,t[6]=c):c=t[6];let u;t[7]!==c?(u=w.jsx(lne,{align:"start",children:c}),t[7]=c,t[8]=u):u=t[8];let p;return t[9]!==l||t[10]!==u?(p=w.jsxs(ine,{children:[l,u]}),t[9]=l,t[10]=u,t[11]=p):p=t[11],p}function vne(e){const t=w.jsx("span",{className:"max-w-64 truncate",title:typeof e.label=="string"?e.label:void 0,children:e.label});return w.jsx(cne,{asChild:!!e.link&&!e.onSelect,onSelect:e.onSelect,disabled:!e.onSelect&&!e.link,children:e.link&&!e.onSelect?w.jsx(LF,{...e.link,children:t}):t},e.key)}function bne(e){const t=Re.c(14),{item:o,current:a}=e,n=typeof o.label=="string"?o.label:void 0;if(a){let l;return t[0]!==o.label||t[1]!==n?(l=w.jsx("h1",{"data-slot":"page-title","aria-current":"page",title:n,className:"truncate text-sm font-medium text-foreground",children:o.label}),t[0]=o.label,t[1]=n,t[2]=l):l=t[2],l}if(o.onSelect){let l;return t[3]!==o.label||t[4]!==o.onSelect||t[5]!==n?(l=w.jsx("button",{type:"button",onClick:o.onSelect,title:n,className:"block max-w-40 truncate rounded-lg hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",children:o.label}),t[3]=o.label,t[4]=o.onSelect,t[5]=n,t[6]=l):l=t[6],l}if(o.link){let l;return t[7]!==o.label||t[8]!==o.link||t[9]!==n?(l=w.jsx(LF,{...o.link,title:n,className:"block max-w-40 truncate rounded-lg hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",children:o.label}),t[7]=o.label,t[8]=o.link,t[9]=n,t[10]=l):l=t[10],l}let i;return t[11]!==o.label||t[12]!==n?(i=w.jsx("span",{title:n,className:"block max-w-40 truncate",children:o.label}),t[11]=o.label,t[12]=n,t[13]=i):i=t[13],i}function BF(e){const t=Re.c(21),{items:o}=e,a=ar(),[n,i]=dne();let l,c,u,p,m,h;if(t[0]!==o||t[1]!==i||t[2]!==a||t[3]!==n){const b=gne(o,n>=0&&n<320,IF);p=i,t[10]!==a?(m=a("page.breadcrumbs"),t[10]=a,t[11]=m):m=t[11],h="min-w-0 flex-1",l="page-breadcrumbs",c="flex min-w-0 items-center gap-2 text-sm text-muted-foreground",u=b.map((S,_)=>w.jsxs("li",{className:gt("flex min-w-0 items-center gap-2",_>0&&"min-w-5",S.type==="item"?"last:min-w-16 last:flex-[1_1_auto]":"shrink-0"),children:[_>0&&w.jsx(F_,{"aria-hidden":"true",className:"size-3 shrink-0 text-muted-foreground/60"}),S.type==="item"?w.jsx(bne,{item:S.item,current:_===b.length-1}):w.jsx(fne,{items:S.items})]},S.type==="item"?`item:${S.item.key}`:"menu")),t[0]=o,t[1]=i,t[2]=a,t[3]=n,t[4]=l,t[5]=c,t[6]=u,t[7]=p,t[8]=m,t[9]=h}else l=t[4],c=t[5],u=t[6],p=t[7],m=t[8],h=t[9];let f;t[12]!==l||t[13]!==c||t[14]!==u?(f=w.jsx("ol",{"data-slot":l,className:c,children:u}),t[12]=l,t[13]=c,t[14]=u,t[15]=f):f=t[15];let v;return t[16]!==p||t[17]!==m||t[18]!==h||t[19]!==f?(v=w.jsx("nav",{ref:p,"aria-label":m,className:h,children:f}),t[16]=p,t[17]=m,t[18]=h,t[19]=f,t[20]=v):v=t[20],v}function yne(e){const t=Re.c(12),{items:o,scope:a}=e,n=zv();if(!n)throw new Error("Page.Header requires Page.Breadcrumbs.Provider");const i=A.useSyncExternalStore(n.subscribe,n.getSnapshot,n.getSnapshot);let l,c;t[0]!==i||t[1]!==o||t[2]!==a?(l=mne(o,i),c=hne(l,a),t[0]=i,t[1]=o,t[2]=a,t[3]=l,t[4]=c):(l=t[3],c=t[4]);const u=c;let p;t[5]!==u?(p=u&&w.jsx("title",{children:u}),t[5]=u,t[6]=p):p=t[6];let m;t[7]!==l?(m=w.jsx(BF,{items:l}),t[7]=l,t[8]=m):m=t[8];let h;return t[9]!==p||t[10]!==m?(h=w.jsxs(w.Fragment,{children:[p,m]}),t[9]=p,t[10]=m,t[11]=h):h=t[11],h}function Sne(e){const t=Re.c(3),o=zv();let a;return t[0]!==e||t[1]!==o?(a=o?w.jsx(NF,{...e}):w.jsx("div",{className:"min-w-0 shrink-0 border-b px-3 py-2",children:w.jsx(BF,{items:e.items??[]})}),t[0]=e,t[1]=o,t[2]=a):a=t[2],a}const wne=Object.assign(Sne,{Provider:pne});function Tne(e){const t=Re.c(8);let o,a;t[0]!==e?({className:o,...a}=e,t[0]=e,t[1]=o,t[2]=a):(o=t[1],a=t[2]);let n;t[3]!==o?(n=gt("flex h-full min-h-0 min-w-0 w-full flex-col overflow-hidden",o),t[3]=o,t[4]=n):n=t[4];let i;return t[5]!==a||t[6]!==n?(i=w.jsx("div",{...a,"data-slot":"page",className:n}),t[5]=a,t[6]=n,t[7]=i):i=t[7],i}function xne(e){const t=Re.c(8);let o,a;t[0]!==e?({className:o,...a}=e,t[0]=e,t[1]=o,t[2]=a):(o=t[1],a=t[2]);let n;t[3]!==o?(n=gt("min-h-0 min-w-0 flex-1 overflow-auto",o),t[3]=o,t[4]=n):n=t[4];let i;return t[5]!==a||t[6]!==n?(i=w.jsx("div",{...a,"data-slot":"page-content",className:n}),t[5]=a,t[6]=n,t[7]=i):i=t[7],i}const _ne={reading:"max-w-[720px]",standard:"max-w-5xl",wide:"max-w-[1200px]",fluid:"max-w-none"};function kne(e){const t=Re.c(11);let o,a,n;t[0]!==e?({className:o,width:n,...a}=e,t[0]=e,t[1]=o,t[2]=a,t[3]=n):(o=t[1],a=t[2],n=t[3]);const i=n===void 0?"wide":n,l=_ne[i];let c;t[4]!==o||t[5]!==l?(c=gt("mx-auto w-full px-4 py-6 md:px-8 md:py-8",l,o),t[4]=o,t[5]=l,t[6]=c):c=t[6];let u;return t[7]!==a||t[8]!==c||t[9]!==i?(u=w.jsx("div",{...a,"data-slot":"page-container","data-width":i,className:c}),t[7]=a,t[8]=c,t[9]=i,t[10]=u):u=t[10],u}function Cne(e){const t=Re.c(9),{children:o,actions:a,className:n}=e,i=zv();let l;t[0]!==o||t[1]!==n||t[2]!==i?(l=i?w.jsx(NF,{after:"page",parent:{label:o}}):w.jsx("div",{"data-slot":"page-title",className:gt("flex flex-wrap items-center justify-between gap-3",n),children:w.jsx("h1",{className:"min-w-0 text-xl font-medium",children:o})}),t[0]=o,t[1]=n,t[2]=i,t[3]=l):l=t[3];let c;t[4]!==a?(c=a&&w.jsx(FF,{children:a}),t[4]=a,t[5]=c):c=t[5];let u;return t[6]!==l||t[7]!==c?(u=w.jsxs(w.Fragment,{children:[l,c]}),t[6]=l,t[7]=c,t[8]=u):u=t[8],u}function FF(e){const t=Re.c(3),{children:o,secondary:a}=e;let n;if(t[0]!==o||t[1]!==a){const i=w.jsxs("div",{"data-slot":"page-actions",className:"flex shrink-0 items-center gap-2",children:[a,o]});n=w.jsx(nn.Topbar.Right.Portal,{fallback:i,children:i}),t[0]=o,t[1]=a,t[2]=n}else n=t[2];return n}function Ene(e){const t=Re.c(28),{breadcrumbs:o,scope:a,leading:n,actions:i,navigation:l,trailingActions:c}=e;let u;t[0]!==o||t[1]!==a?(u=w.jsx(yne,{items:o,scope:a}),t[0]=o,t[1]=a,t[2]=u):u=t[2];let p;t[3]===Symbol.for("react.memo_cache_sentinel")?(p=w.jsx(nn.Topbar.Left.Target,{}),t[3]=p):p=t[3];let m;t[4]!==n||t[5]!==u?(m=w.jsxs(nn.Topbar.Left,{className:"flex-1 gap-2",children:[n,u,p]}),t[4]=n,t[5]=u,t[6]=m):m=t[6];let h;t[7]!==i?(h=w.jsx("div",{className:"peer flex min-w-0 items-center gap-2 empty:hidden",children:i}),t[7]=i,t[8]=h):h=t[8];let f;t[9]===Symbol.for("react.memo_cache_sentinel")?(f=w.jsx(nn.Topbar.Right.Target,{className:"flex items-center gap-2 before:hidden before:h-4 before:w-px before:shrink-0 before:bg-border peer-[:not(:empty)]:before:block"}),t[9]=f):f=t[9];let v;t[10]!==h||t[11]!==c?(v=w.jsxs(nn.Topbar.Right,{className:"shrink-0 gap-2",children:[h,f,c]}),t[10]=h,t[11]=c,t[12]=v):v=t[12];let b;t[13]!==m||t[14]!==v?(b=w.jsxs(nn.Topbar,{className:"gap-3 border-b border-border/60 px-3","data-testid":"page-header",children:[m,v]}),t[13]=m,t[14]=v,t[15]=b):b=t[15];let S;t[16]!==l?(S=w.jsx("div",{"data-toolbar-content":"",className:"min-w-0 empty:hidden",children:l}),t[16]=l,t[17]=S):S=t[17];let _;t[18]===Symbol.for("react.memo_cache_sentinel")?(_=w.jsx(nn.Toolbar.Left.Target,{}),t[18]=_):_=t[18];let T;t[19]!==S?(T=w.jsxs(nn.Toolbar.Left,{children:[S,_]}),t[19]=S,t[20]=T):T=t[20];let x;t[21]===Symbol.for("react.memo_cache_sentinel")?(x=w.jsx(nn.Toolbar.Center,{className:"@max-xl/panel-toolbar:order-last @max-xl/panel-toolbar:basis-full [&:not(:has([data-toolbar-content]:not(:empty)))]:hidden",children:w.jsx(nn.Toolbar.Center.Target,{})}),t[21]=x):x=t[21];let P;t[22]===Symbol.for("react.memo_cache_sentinel")?(P=w.jsx(nn.Toolbar.Right,{children:w.jsx(nn.Toolbar.Right.Target,{})}),t[22]=P):P=t[22];let C;t[23]!==T?(C=w.jsxs(nn.Toolbar,{children:[T,x,P]}),t[23]=T,t[24]=C):C=t[24];let E;return t[25]!==C||t[26]!==b?(E=w.jsxs(w.Fragment,{children:[b,C]}),t[25]=C,t[26]=b,t[27]=E):E=t[27],E}function Pne(e){const t=Re.c(11);let o,a;t[0]!==e?({className:o,...a}=e,t[0]=e,t[1]=o,t[2]=a):(o=t[1],a=t[2]);const n=ar();let i;t[3]!==n?(i=n("page.views"),t[3]=n,t[4]=i):i=t[4];let l;t[5]!==o?(l=gt("-m-2 flex min-w-0 items-center gap-1 overflow-x-auto p-2 no-scrollbar",o),t[5]=o,t[6]=l):l=t[6];let c;return t[7]!==a||t[8]!==i||t[9]!==l?(c=w.jsx("nav",{"aria-label":i,...a,"data-slot":"page-tabs",className:l}),t[7]=a,t[8]=i,t[9]=l,t[10]=c):c=t[10],c}function Ane(e){const t=Re.c(14);let o,a,n,i;t[0]!==e?({active:o,asChild:i,className:a,...n}=e,t[0]=e,t[1]=o,t[2]=a,t[3]=n,t[4]=i):(o=t[1],a=t[2],n=t[3],i=t[4]);const l=i===void 0?!1:i,c=l?void 0:"button",u=l&&o?"page":void 0,p=l?void 0:o;let m;t[5]!==a?(m=gt("shrink-0",a),t[5]=a,t[6]=m):m=t[6];let h;return t[7]!==l||t[8]!==n||t[9]!==c||t[10]!==u||t[11]!==p||t[12]!==m?(h=w.jsx(Ri,{asChild:l,variant:"tab",size:"sm",...n,type:c,"aria-current":u,"aria-pressed":p,"data-slot":"page-tab",className:m}),t[7]=l,t[8]=n,t[9]=c,t[10]=u,t[11]=p,t[12]=m,t[13]=h):h=t[13],h}const ld=Object.assign(Tne,{Header:Ene,Tabs:Pne,Tab:Ane,Actions:FF,Content:xne,Container:kne,Title:Cne,Breadcrumbs:wne});var ge=typeof window<"u"?window:void 0,ia=typeof globalThis<"u"?globalThis:ge;typeof self>"u"&&(ia.self=ia),typeof File>"u"&&(ia.File=function(){});var En=ia?.navigator,ze=ia?.document,wa=ia?.location,uT=ia?.fetch,pT=ia!=null&&ia.XMLHttpRequest&&"withCredentials"in new ia.XMLHttpRequest?ia.XMLHttpRequest:void 0,WD=ia?.AbortController,Rne=ia?.CompressionStream,rn=En?.userAgent,et=ge??{},KD="1.372.3",Ga={DEBUG:!1,LIB_VERSION:KD,LIB_NAME:"web",JS_SDK_VERSION:KD};function YD(e,t,o,a,n,i,l){try{var c=e[i](l),u=c.value}catch(p){return void o(p)}c.done?t(u):Promise.resolve(u).then(a,n)}function Kn(e){return function(){var t=this,o=arguments;return new Promise((function(a,n){var i=e.apply(t,o);function l(u){YD(i,a,n,l,c,"next",u)}function c(u){YD(i,a,n,l,c,"throw",u)}l(void 0)}))}}function Me(){return Me=Object.assign?Object.assign.bind():function(e){for(var t=1;arguments.length>t;t++){var o=arguments[t];for(var a in o)({}).hasOwnProperty.call(o,a)&&(e[a]=o[a])}return e},Me.apply(null,arguments)}function jF(e,t){if(e==null)return{};var o={};for(var a in e)if({}.hasOwnProperty.call(e,a)){if(t.indexOf(a)!==-1)continue;o[a]=e[a]}return o}function mT(){return mT=Kn((function*(e,t,o){t===void 0&&(t=!0);try{var a=new CompressionStream("gzip"),n=a.writable.getWriter(),i=n.write(new TextEncoder().encode(e)).then((()=>n.close())).catch((function(){var u=Kn((function*(p){try{yield n.abort(p)}catch{}throw p}));return function(p){return u.apply(this,arguments)}})()),l=new Response(a.readable).blob(),[c]=yield Promise.all([l,i]);return c}catch(u){if(o!=null&&o.rethrow)throw u;return t&&console.error("Failed to gzip compress data",u),null}})),mT.apply(this,arguments)}var Dne=["amazonbot","amazonproductbot","app.hypefactors.com","applebot","archive.org_bot","awariobot","backlinksextendedbot","baiduspider","bingbot","bingpreview","chrome-lighthouse","dataforseobot","deepscan","duckduckbot","facebookexternal","facebookcatalog","http://yandex.com/bots","hubspot","ia_archiver","leikibot","linkedinbot","meta-externalagent","mj12bot","msnbot","nessus","petalbot","pinterest","prerender","rogerbot","screaming frog","sebot-wa","sitebulb","slackbot","slurp","trendictionbot","turnitin","twitterbot","vercel-screenshot","vercelbot","yahoo! slurp","yandexbot","zoombot","bot.htm","bot.php","(bot;","bot/","crawler","ahrefsbot","ahrefssiteaudit","semrushbot","siteauditbot","splitsignalbot","gptbot","oai-searchbot","chatgpt-user","perplexitybot","better uptime bot","sentryuptimebot","uptimerobot","headlesschrome","cypress","google-hoteladsverifier","adsbot-google","apis-google","duplexweb-google","feedfetcher-google","google favicon","google web preview","google-read-aloud","googlebot","googleother","google-cloudvertexbot","googleweblight","mediapartners-google","storebot-google","google-inspectiontool","bytespider"],ZD=function(e,t){if(t===void 0&&(t=[]),!e)return!1;var o=e.toLowerCase();return Dne.concat(t).some((a=>{var n=a.toLowerCase();return o.indexOf(n)!==-1}))},One=["$snapshot","$pageview","$pageleave","$set","survey dismissed","survey sent","survey shown","$identify","$groupidentify","$create_alias","$$client_ingestion_warning","$web_experiment_applied","$feature_enrollment_update","$feature_flag_called"];function kt(e,t){return e.indexOf(t)!==-1}var Uv=function(e){return e.trim()},hT=function(e){return e.replace(/^\$/,"")},zF=Object.prototype,UF=zF.hasOwnProperty,$v=zF.toString,It=Array.isArray||function(e){return $v.call(e)==="[object Array]"},_i=e=>typeof e=="function",Bo=e=>e===Object(e)&&!It(e),Xc=e=>{if(Bo(e)){for(var t in e)if(UF.call(e,t))return!1;return!0}return!1},qe=e=>e===void 0,ko=e=>$v.call(e)=="[object String]",of=e=>ko(e)&&e.trim().length===0,Ii=e=>e===null,Ct=e=>qe(e)||Ii(e),Xn=e=>$v.call(e)=="[object Number]"&&e==e,Gc=e=>Xn(e)&&e>0,$r=e=>$v.call(e)==="[object Boolean]",Mne=e=>e instanceof FormData,Nne=e=>kt(One,e);function $F(e){return e===null||typeof e!="object"}function Lf(e,t){return{}.toString.call(e)==="[object "+t+"]"}function j_(e){return typeof Event<"u"&&(function(t,o){try{return t instanceof o}catch{return!1}})(e,Event)}var Ine=[!0,"true",1,"1","yes"],f0=e=>kt(Ine,e),Lne=[!1,"false",0,"0","no"];function qr(e,t,o,a,n){return t>o&&(a.warn("min cannot be greater than max."),t=o),Xn(e)?e>o?(a.warn(" cannot be greater than max: "+o+". Using max value instead."),o):t>e?(a.warn(" cannot be less than min: "+t+". Using min value instead."),t):e:(a.warn(" must be a number. using max or fallback. max: "+o+", fallback: "+n),qr(n||o,t,o,a))}let Bne=class{constructor(t){this.$t={},this.zt=t.zt,this.Ut=qr(t.bucketSize,0,100,t.Gt),this.Wt=qr(t.refillRate,0,this.Ut,t.Gt),this.Xt=qr(t.refillInterval,0,864e5,t.Gt)}Jt(t,o){var a=Math.floor((o-t.lastAccess)/this.Xt);a>0&&(t.tokens=Math.min(t.tokens+a*this.Wt,this.Ut),t.lastAccess=t.lastAccess+a*this.Xt)}consumeRateLimit(t){var o,a=Date.now(),n=String(t),i=this.$t[n];return i?this.Jt(i,a):this.$t[n]=i={tokens:this.Ut,lastAccess:a},i.tokens===0||(i.tokens--,i.tokens===0&&((o=this.zt)==null||o.call(this,t)),i.tokens===0)}stop(){this.$t={}}};var Og,QD,v0,An="Mobile",Bf="iOS",Pi="Android",wd="Tablet",qF=Pi+" "+wd,VF="iPad",HF="Apple",GF=HF+" Watch",cp="Safari",Td="BlackBerry",WF="Samsung",KF=WF+"Browser",YF=WF+" Internet",Cl="Chrome",Fne=Cl+" OS",ZF=Cl+" "+Bf,z_="Internet Explorer",QF=z_+" "+An,U_="Opera",jne=U_+" Mini",$_="Edge",JF="Microsoft "+$_,cd="Firefox",XF=cd+" "+Bf,Dp="Nintendo",Op="PlayStation",dd="Xbox",ej=Pi+" "+An,tj=An+" "+cp,Xu="Windows",gT=Xu+" Phone",JD="Nokia",fT="Ouya",oj="Generic",zne=oj+" "+An.toLowerCase(),aj=oj+" "+wd.toLowerCase(),vT="Konqueror",Ha="(\\d+(\\.\\d+)?)",b0=new RegExp("Version/"+Ha),Une=new RegExp(dd,"i"),$ne=new RegExp(Op+" \\w+","i"),qne=new RegExp(Dp+" \\w+","i"),q_=new RegExp(Td+"|PlayBook|BB10","i"),Vne={"NT3.51":"NT 3.11","NT4.0":"NT 4.0","5.0":"2000",5.1:"XP",5.2:"XP","6.0":"Vista",6.1:"7",6.2:"8",6.3:"8.1",6.4:"10","10.0":"10"},nj=function(e,t){return t=t||"",kt(e," OPR/")&&kt(e,"Mini")?jne:kt(e," OPR/")?U_:q_.test(e)?Td:kt(e,"IE"+An)||kt(e,"WPDesktop")?QF:kt(e,KF)?YF:kt(e,$_)||kt(e,"Edg/")?JF:kt(e,"FBIOS")?"Facebook "+An:kt(e,"UCWEB")||kt(e,"UCBrowser")?"UC Browser":kt(e,"CriOS")?ZF:kt(e,"CrMo")||kt(e,Cl)?Cl:kt(e,Pi)&&kt(e,cp)?ej:kt(e,"FxiOS")?XF:kt(e.toLowerCase(),vT.toLowerCase())?vT:((o,a)=>a&&kt(a,HF)||(function(n){return kt(n,cp)&&!kt(n,Cl)&&!kt(n,Pi)})(o))(e,t)?kt(e,An)?tj:cp:kt(e,cd)?cd:kt(e,"MSIE")||kt(e,"Trident/")?z_:kt(e,"Gecko")?cd:""},Hne={[QF]:[new RegExp("rv:"+Ha)],[JF]:[new RegExp($_+"?\\/"+Ha)],[Cl]:[new RegExp("("+Cl+"|CrMo)\\/"+Ha)],[ZF]:[new RegExp("CriOS\\/"+Ha)],"UC Browser":[new RegExp("(UCBrowser|UCWEB)\\/"+Ha)],[cp]:[b0],[tj]:[b0],[U_]:[new RegExp("(Opera|OPR)\\/"+Ha)],[cd]:[new RegExp(cd+"\\/"+Ha)],[XF]:[new RegExp("FxiOS\\/"+Ha)],[vT]:[new RegExp("Konqueror[:/]?"+Ha,"i")],[Td]:[new RegExp(Td+" "+Ha),b0],[ej]:[new RegExp("android\\s"+Ha,"i")],[YF]:[new RegExp(KF+"\\/"+Ha)],[z_]:[new RegExp("(rv:|MSIE )"+Ha)],Mozilla:[new RegExp("rv:"+Ha)]},Gne=function(e,t){var o=nj(e,t),a=Hne[o];if(qe(a))return null;for(var n=0;a.length>n;n++){var i=e.match(a[n]);if(i)return parseFloat(i[i.length-2])}return null},XD=[[new RegExp(dd+"; "+dd+" (.*?)[);]","i"),e=>[dd,e&&e[1]||""]],[new RegExp(Dp,"i"),[Dp,""]],[new RegExp(Op,"i"),[Op,""]],[q_,[Td,""]],[new RegExp(Xu,"i"),(e,t)=>{if(/Phone/.test(t)||/WPDesktop/.test(t))return[gT,""];if(new RegExp(An).test(t)&&!/IEMobile\b/.test(t))return[Xu+" "+An,""];var o=/Windows NT ([0-9.]+)/i.exec(t);if(o&&o[1]){var a=Vne[o[1]]||"";return/arm/i.test(t)&&(a="RT"),[Xu,a]}return[Xu,""]}],[/((iPhone|iPad|iPod).*?OS (\d+)_(\d+)_?(\d+)?|iPhone)/,e=>e&&e[3]?[Bf,[e[3],e[4],e[5]||"0"].join(".")]:[Bf,""]],[/(watch.*\/(\d+\.\d+\.\d+)|watch os,(\d+\.\d+),)/i,e=>{var t="";return e&&e.length>=3&&(t=qe(e[2])?e[3]:e[2]),["watchOS",t]}],[new RegExp("("+Pi+" (\\d+)\\.(\\d+)\\.?(\\d+)?|"+Pi+")","i"),e=>e&&e[2]?[Pi,[e[2],e[3],e[4]||"0"].join(".")]:[Pi,""]],[/Mac OS X (\d+)[_.](\d+)[_.]?(\d+)?/i,e=>{var t=["Mac OS X",""];return e&&e[1]&&(t[1]=[e[1],e[2],e[3]||"0"].join(".")),t}],[/Mac/i,["Mac OS X",""]],[/CrOS/,[Fne,""]],[/Linux|debian/i,["Linux",""]]],eO=function(e){return qne.test(e)?Dp:$ne.test(e)?Op:Une.test(e)?dd:new RegExp(fT,"i").test(e)?fT:new RegExp("("+gT+"|WPDesktop)","i").test(e)?gT:/iPad/.test(e)?VF:/iPod/.test(e)?"iPod Touch":/iPhone/.test(e)?"iPhone":/(watch)(?: ?os[,/]|\d,\d\/)[\d.]+/i.test(e)?GF:q_.test(e)?Td:/(kobo)\s(ereader|touch)/i.test(e)?"Kobo":new RegExp(JD,"i").test(e)?JD:/(kf[a-z]{2}wi|aeo[c-r]{2})( bui|\))/i.test(e)||/(kf[a-z]+)( bui|\)).+silk\//i.test(e)?"Kindle Fire":/(Android|ZTE)/i.test(e)?new RegExp(An).test(e)&&!/(9138B|TB782B|Nexus [97]|pixel c|HUAWEISHT|BTV|noble nook|smart ultra 6)/i.test(e)||/pixel[\daxl ]{1,6}/i.test(e)&&!/pixel c/i.test(e)||/(huaweimed-al00|tah-|APA|SM-G92|i980|zte|U304AA)/i.test(e)||/lmy47v/i.test(e)&&!/QTAQZ3/i.test(e)?Pi:qF:new RegExp("(pda|"+An+")","i").test(e)?zne:new RegExp(wd,"i").test(e)&&!new RegExp(wd+" pc","i").test(e)?aj:""},Wne=e=>e instanceof Error,rj={trace:{text:"TRACE",number:1},debug:{text:"DEBUG",number:5},info:{text:"INFO",number:9},warn:{text:"WARN",number:13},error:{text:"ERROR",number:17},fatal:{text:"FATAL",number:21}},Kne=rj.info;function ij(e){if($r(e))return{boolValue:e};if(typeof e=="number")return Number.isFinite(e)?Number.isInteger(e)?{intValue:e}:{doubleValue:e}:{stringValue:String(e)};if(typeof e=="string")return{stringValue:e};if(It(e))return{arrayValue:{values:e.map((t=>ij(t)))}};try{return{stringValue:JSON.stringify(e)}}catch{return{stringValue:String(e)}}}function tO(e){var t=[];for(var o in e){var a=e[o];Ii(a)||qe(a)||t.push({key:o,value:ij(a)})}return t}function Yne(e){var t=globalThis._posthogChunkIds;if(t){var o=Object.keys(t);return v0&&o.length===QD||(QD=o.length,v0=o.reduce(((a,n)=>{Og||(Og={});var i=Og[n];if(i)a[i[0]]=i[1];else for(var l=e(n),c=l.length-1;c>=0;c--){var u=l[c],p=u?.filename,m=t[n];if(p&&m){a[p]=m,Og[n]=[p,m];break}}return a}),{})),v0}}class Zne{constructor(t,o,a){a===void 0&&(a=[]),this.coercers=t,this.stackParser=o,this.modifiers=a}buildFromUnknown(t,o){o===void 0&&(o={});var a=o&&o.mechanism||{handled:!0,type:"generic"},n=this.buildCoercingContext(a,o,0).apply(t),i=this.buildParsingContext(o),l=this.parseStacktrace(n,i);return{$exception_list:this.convertToExceptionList(l,a),$exception_level:"error"}}modifyFrames(t){var o=this;return Kn((function*(){for(var a of t)a.stacktrace&&a.stacktrace.frames&&It(a.stacktrace.frames)&&(a.stacktrace.frames=yield o.applyModifiers(a.stacktrace.frames));return t}))()}coerceFallback(t){var o;return{type:"Error",value:"Unknown error",stack:(o=t.syntheticException)==null?void 0:o.stack,synthetic:!0}}parseStacktrace(t,o){var a,n;return t.cause!=null&&(a=this.parseStacktrace(t.cause,o)),t.stack!=""&&t.stack!=null&&(n=this.applyChunkIds(this.stackParser(t.stack,t.synthetic?o.skipFirstLines:0),o.chunkIdMap)),Me({},t,{cause:a,stack:n})}applyChunkIds(t,o){return t.map((a=>(a.filename&&o&&(a.chunk_id=o[a.filename]),a)))}applyCoercers(t,o){for(var a of this.coercers)if(a.match(t))return a.coerce(t,o);return this.coerceFallback(o)}applyModifiers(t){var o=this;return Kn((function*(){var a=t;for(var n of o.modifiers)a=yield n(a);return a}))()}convertToExceptionList(t,o){var a,n,i,l={type:t.type,value:t.value,mechanism:{type:(a=o.type)!==null&&a!==void 0?a:"generic",handled:(n=o.handled)===null||n===void 0||n,synthetic:(i=t.synthetic)!==null&&i!==void 0&&i}};t.stack&&(l.stacktrace={type:"raw",frames:t.stack});var c=[l];return t.cause!=null&&c.push(...this.convertToExceptionList(t.cause,Me({},o,{handled:!0}))),c}buildParsingContext(t){var o;return{chunkIdMap:Yne(this.stackParser),skipFirstLines:(o=t.skipFirstLines)!==null&&o!==void 0?o:1}}buildCoercingContext(t,o,a){a===void 0&&(a=0);var n=(i,l)=>{if(4>=l){var c=this.buildCoercingContext(t,o,l);return this.applyCoercers(i,c)}};return Me({},o,{syntheticException:a==0?o.syntheticException:void 0,mechanism:t,apply:i=>n(i,a),next:i=>n(i,a+1)})}}var xd="?";function bT(e,t,o,a,n){var i={platform:e,filename:t,function:o==="<anonymous>"?xd:o,in_app:!0};return qe(a)||(i.lineno=a),qe(n)||(i.colno=n),i}var sj=(e,t)=>{var o=e.indexOf("safari-extension")!==-1,a=e.indexOf("safari-web-extension")!==-1;return o||a?[e.indexOf("@")!==-1?e.split("@")[0]:xd,o?"safari-extension:"+t:"safari-web-extension:"+t]:[e,t]},Qne=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,Jne=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,Xne=/\((\S*)(?::(\d+))(?::(\d+))\)/,ere=(e,t)=>{var o=Qne.exec(e);if(o){var[,a,n,i]=o;return bT(t,a,xd,+n,+i)}var l=Jne.exec(e);if(l){if(l[2]&&l[2].indexOf("eval")===0){var c=Xne.exec(l[2]);c&&(l[2]=c[1],l[3]=c[2],l[4]=c[3])}var[u,p]=sj(l[1]||xd,l[2]);return bT(t,p,u,l[3]?+l[3]:void 0,l[4]?+l[4]:void 0)}},tre=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,ore=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,are=(e,t)=>{var o=tre.exec(e);if(o){if(o[3]&&o[3].indexOf(" > eval")>-1){var a=ore.exec(o[3]);a&&(o[1]=o[1]||"eval",o[3]=a[1],o[4]=a[2],o[5]="")}var n=o[3],i=o[1]||xd;return[i,n]=sj(i,n),bT(t,n,i,o[4]?+o[4]:void 0,o[5]?+o[5]:void 0)}},oO=/\(error: (.*)\)/;let nre=class{match(t){return this.isDOMException(t)||this.isDOMError(t)}coerce(t,o){var a=ko(t.stack);return{type:this.getType(t),value:this.getValue(t),stack:a?t.stack:void 0,cause:t.cause?o.next(t.cause):void 0,synthetic:!1}}getType(t){return this.isDOMError(t)?"DOMError":"DOMException"}getValue(t){var o=t.name||(this.isDOMError(t)?"DOMError":"DOMException");return t.message?o+": "+t.message:o}isDOMException(t){return Lf(t,"DOMException")}isDOMError(t){return Lf(t,"DOMError")}};class rre{match(t){return(o=>o instanceof Error)(t)}coerce(t,o){return{type:this.getType(t),value:this.getMessage(t,o),stack:this.getStack(t),cause:t.cause?o.next(t.cause):void 0,synthetic:!1}}getType(t){return t.name||t.constructor.name}getMessage(t,o){var a=t.message;return String(a.error&&typeof a.error.message=="string"?a.error.message:a)}getStack(t){return t.stacktrace||t.stack||void 0}}let ire=class{constructor(){}match(t){return Lf(t,"ErrorEvent")&&t.error!=null}coerce(t,o){var a;return o.apply(t.error)||{type:"ErrorEvent",value:t.message,stack:(a=o.syntheticException)==null?void 0:a.stack,synthetic:!0}}};var sre=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i;let lre=class{match(t){return typeof t=="string"}coerce(t,o){var a,[n,i]=this.getInfos(t);return{type:n??"Error",value:i??t,stack:(a=o.syntheticException)==null?void 0:a.stack,synthetic:!0}}getInfos(t){var o="Error",a=t,n=t.match(sre);return n&&(o=n[1],a=n[2]),[o,a]}};var cre=["fatal","error","warning","log","info","debug"];function lj(e,t){t===void 0&&(t=40);var o=Object.keys(e);if(o.sort(),!o.length)return"[object has no keys]";for(var a=o.length;a>0;a--){var n=o.slice(0,a).join(", ");if(t>=n.length)return a===o.length?n:n.length>t?n.slice(0,t)+"...":n}return""}let dre=class{match(t){return typeof t=="object"&&t!==null}coerce(t,o){var a,n=this.getErrorPropertyFromObject(t);return n?o.apply(n):{type:this.getType(t),value:this.getValue(t),stack:(a=o.syntheticException)==null?void 0:a.stack,level:this.isSeverityLevel(t.level)?t.level:"error",synthetic:!0}}getType(t){return j_(t)?t.constructor.name:"Error"}getValue(t){if("name"in t&&typeof t.name=="string"){var o="'"+t.name+"' captured as exception";return"message"in t&&typeof t.message=="string"&&(o+=" with message: '"+t.message+"'"),o}if("message"in t&&typeof t.message=="string")return t.message;var a=this.getObjectClassName(t);return(a&&a!=="Object"?"'"+a+"'":"Object")+" captured as exception with keys: "+lj(t)}isSeverityLevel(t){return ko(t)&&!of(t)&&cre.indexOf(t)>=0}getErrorPropertyFromObject(t){for(var o in t)if({}.hasOwnProperty.call(t,o)){var a=t[o];if(Wne(a))return a}}getObjectClassName(t){try{var o=Object.getPrototypeOf(t);return o?o.constructor.name:void 0}catch{return}}},ure=class{match(t){return j_(t)}coerce(t,o){var a,n=t.constructor.name;return{type:n,value:n+" captured as exception with keys: "+lj(t),stack:(a=o.syntheticException)==null?void 0:a.stack,synthetic:!0}}},pre=class{match(t){return $F(t)}coerce(t,o){var a;return{type:"Error",value:"Primitive value captured as exception: "+String(t),stack:(a=o.syntheticException)==null?void 0:a.stack,synthetic:!0}}},mre=class{match(t){return Lf(t,"PromiseRejectionEvent")||this.isCustomEventWrappingRejection(t)}isCustomEventWrappingRejection(t){if(!j_(t))return!1;try{var o=t.detail;return o!=null&&typeof o=="object"&&"reason"in o}catch{return!1}}coerce(t,o){var a,n=this.getUnhandledRejectionReason(t);return $F(n)?{type:"UnhandledRejection",value:"Non-Error promise rejection captured with value: "+String(n),stack:(a=o.syntheticException)==null?void 0:a.stack,synthetic:!0}:o.apply(n)}getUnhandledRejectionReason(t){try{if("reason"in t)return t.reason;if("detail"in t&&t.detail!=null&&typeof t.detail=="object"&&"reason"in t.detail)return t.detail.reason}catch{}return t}};var Ff="$message",jf="$timestamp",hre=new Set([Ff,jf]),y0={enabled:!0,max_bytes:32768};function zf(e){var t;return e?{enabled:(t=e.enabled)!==null&&t!==void 0?t:y0.enabled,max_bytes:fre(e.max_bytes,y0.max_bytes)}:Me({},y0)}let gre=class{constructor(t){this.Kt=[],this.Qt=0,this.Bt=zf(t)}setConfig(t){this.Bt=zf(t),this.er()}add(t){var o=(function(n){var i=(function(m){var h=new WeakSet;try{return JSON.stringify(m,((f,v)=>{if(typeof v=="bigint")return v.toString();if(typeof v!="function"&&typeof v!="symbol"){if(v instanceof Date)return v.toISOString();if(v instanceof Error)return{name:v.name,message:v.message,stack:v.stack};if(v&&typeof v=="object"){if(h.has(v))return"[Circular]";h.add(v)}return v}}))}catch{return}})(n);if(i)try{var l=JSON.parse(i);if(!Bo(l))return;var c=l,u=c[Ff],p=c[jf];return!ko(u)||u.trim().length===0||!ko(p)&&!Xn(p)?void 0:{step:c,json:i}}catch{return}})(t);if(o){var a=(function(n){if(typeof TextEncoder<"u")return new TextEncoder().encode(n).length;for(var i=encodeURIComponent(n),l=0,c=0;i.length>c;c++)i[c]==="%"?(l+=1,c+=2):l+=1;return l})(o.json);a>this.Bt.max_bytes||(this.Kt.push({step:o.step,bytes:a}),this.Qt+=a,this.er())}}getAttachable(){return this.Kt.map((t=>t.step))}clear(){this.Kt=[],this.Qt=0}size(){return this.Kt.length}er(){for(;this.Qt>this.Bt.max_bytes&&this.Kt.length>0;){var t=this.Kt.shift();t&&(this.Qt-=t.bytes)}}};function fre(e,t){if(!Xn(e)||e===1/0||e===-1/0)return t;var o=Math.floor(e);return 0>o?t:o}var cj=function(e,t){var{debugEnabled:o}=t===void 0?{}:t,a={C(n){if(ge&&(Ga.DEBUG||et.POSTHOG_DEBUG||o)&&!qe(ge.console)&&ge.console){for(var i=("__rrweb_original__"in ge.console[n])?ge.console[n].__rrweb_original__:ge.console[n],l=arguments.length,c=new Array(l>1?l-1:0),u=1;l>u;u++)c[u-1]=arguments[u];i(e,...c)}},info(){for(var n=arguments.length,i=new Array(n),l=0;n>l;l++)i[l]=arguments[l];a.C("log",...i)},warn(){for(var n=arguments.length,i=new Array(n),l=0;n>l;l++)i[l]=arguments[l];a.C("warn",...i)},error(){for(var n=arguments.length,i=new Array(n),l=0;n>l;l++)i[l]=arguments[l];a.C("error",...i)},critical(){for(var n=arguments.length,i=new Array(n),l=0;n>l;l++)i[l]=arguments[l];console.error(e,...i)},uninitializedWarning(n){a.error("You must initialize PostHog before calling "+n)},createLogger:(n,i)=>cj(e+" "+n,i)};return a},Ue=cj("[PostHog.js]"),wo=Ue.createLogger,vre=wo("[ExternalScriptsLoader]"),S0=(e,t,o)=>{if(e.config.disable_external_dependency_loading)return vre.warn(t+" was requested but loading of external scripts is disabled."),o("Loading of external scripts is disabled");var a=ze?.querySelectorAll("script");if(a){for(var n,i=function(){if(a[l].src===t){var u=a[l];return u.__posthog_loading_callback_fired?{v:o()}:(u.addEventListener("load",(p=>{u.__posthog_loading_callback_fired=!0,o(void 0,p)})),u.onerror=p=>o(p),{v:void 0})}},l=0;a.length>l;l++)if(n=i())return n.v}var c=()=>{if(!ze)return o("document not found");var u=ze.createElement("script");if(u.type="text/javascript",u.crossOrigin="anonymous",u.src=t,u.onload=h=>{u.__posthog_loading_callback_fired=!0,o(void 0,h)},u.onerror=h=>o(h),e.config.prepare_external_dependency_script&&(u=e.config.prepare_external_dependency_script(u)),!u)return o("prepare_external_dependency_script returned null");if(e.config.external_scripts_inject_target==="head")ze.head.appendChild(u);else{var p,m=ze.querySelectorAll("body > script");m.length>0?(p=m[0].parentNode)==null||p.insertBefore(u,m[0]):ze.body.appendChild(u)}};ze!=null&&ze.body?c():ze?.addEventListener("DOMContentLoaded",c)};et.__PosthogExtensions__=et.__PosthogExtensions__||{},et.__PosthogExtensions__.loadExternalDependency=(e,t,o)=>{if(t!=="remote-config"){var a;if(e.config.__preview_external_dependency_versioned_paths)a=e.requestRouter.endpointFor("assets","/static/"+e.version+"/"+t+".js");else{var n="/static/"+t+".js?v="+e.version;if(t==="toolbar"){var i=3e5;n=n+"&t="+Math.floor(Date.now()/i)*i}a=e.requestRouter.endpointFor("assets",n)}S0(e,a,o)}else{var l=e.requestRouter.endpointFor("assets","/array/"+e.config.token+"/config.js");S0(e,l,o)}},et.__PosthogExtensions__.loadSiteApp=(e,t,o)=>{var a=e.requestRouter.endpointFor("api",t);S0(e,a,o)};var dj="$people_distinct_id",Uf="$device_id",ep="__alias",tp="__timers",yT="$autocapture_disabled_server_side",ST="$heatmaps_enabled_server_side",wT="$exception_capture_enabled_server_side",TT="$error_tracking_suppression_rules",xT="$error_tracking_capture_extension_exceptions",_T="$web_vitals_enabled_server_side",V_="$dead_clicks_enabled_server_side",kT="$product_tours_enabled_server_side",CT="$web_vitals_allowed_metrics",op="$session_recording_remote_config",uj="$replay_override_sampling",pj="$replay_override_linked_flag",mj="$replay_override_url_trigger",hj="$replay_override_event_trigger",$f="$sesid",H_="$session_is_sampled",ed="$enabled_feature_flags",af="$active_feature_flags",ap="$early_access_features",ET="$feature_flag_details",PT="$feature_flag_payloads",AT="$feature_flag_request_id",xi="$override_feature_flags",Wc="$override_feature_flag_payloads",np="$stored_person_properties",fl="$stored_group_properties",RT="$surveys",DT="$surveys_activated",nf="ph_product_tours",dp="$flag_call_reported",OT="$flag_call_reported_session_id",MT="$feature_flag_errors",qf="$feature_flag_evaluated_at",pr="$user_state",NT="$client_session_props",IT="$capture_rate_limit",LT="$initial_campaign_params",BT="$initial_referrer_info",Vf="$initial_person_info",Hf="$epp",gj="__POSTHOG_TOOLBAR__",Mg="$posthog_cookieless",fj="$sdk_debug_extensions_init_method",vj="$sdk_debug_extensions_init_time_ms",bj="$sdk_debug_recording_script_not_loaded",G_="PostHog loadExternalDependency extension not found.",vl="on_reject",ki="always",Ic="anonymous",Lc="identified",FT="identified_only",Gf="visibilitychange",Wf="beforeunload",Kc="$pageview",w0="$pageleave",T0="$identify",aO="$groupidentify";function Ng(e,t){It(e)&&e.forEach(t)}function go(e,t){if(!Ct(e))if(It(e))e.forEach(t);else if(Mne(e))e.forEach(((a,n)=>t(a,n)));else for(var o in e)UF.call(e,o)&&t(e[o],o)}var Mo=function(e){for(var t=arguments.length,o=new Array(t>1?t-1:0),a=1;t>a;a++)o[a-1]=arguments[a];for(var n of o)for(var i in n)n[i]!==void 0&&(e[i]=n[i]);return e};function rf(e){for(var t=Object.keys(e),o=t.length,a=new Array(o);o--;)a[o]=[t[o],e[t[o]]];return a}var nO=function(e){try{return e()}catch{return}},bre=function(e){return function(){try{for(var t=arguments.length,o=new Array(t),a=0;t>a;a++)o[a]=arguments[a];return e.apply(this,o)}catch(n){Ue.critical("Implementation error. Please turn on debug mode and open a ticket on https://app.posthog.com/home#panel=support%3Asupport%3A."),Ue.critical(n)}}},W_=function(e){var t={};return go(e,(function(o,a){(ko(o)&&o.length>0||Xn(o))&&(t[a]=o)})),t},yre=["herokuapp.com","vercel.app","netlify.app"];function Sre(e){var t=e?.hostname;if(!ko(t))return!1;var o=t.split(".").slice(-2).join(".");for(var a of yre)if(o===a)return!1;return!0}function Zo(e,t,o,a){var{capture:n=!1,passive:i=!0}=a??{};e?.addEventListener(t,o,{capture:n,passive:i})}function yj(e){return e.name==="ph_toolbar_internal"}Math.trunc||(Math.trunc=function(e){return 0>e?Math.ceil(e):Math.floor(e)}),Number.isInteger||(Number.isInteger=function(e){return Xn(e)&&isFinite(e)&&Math.floor(e)===e});class Kf{constructor(t){if(this.bytes=t,t.length!==16)throw new TypeError("not 128-bit length")}static fromFieldsV7(t,o,a,n){if(!Number.isInteger(t)||!Number.isInteger(o)||!Number.isInteger(a)||!Number.isInteger(n)||0>t||0>o||0>a||0>n||t>0xffffffffffff||o>4095||a>1073741823||n>4294967295)throw new RangeError("invalid field value");var i=new Uint8Array(16);return i[0]=t/Math.pow(2,40),i[1]=t/Math.pow(2,32),i[2]=t/Math.pow(2,24),i[3]=t/Math.pow(2,16),i[4]=t/Math.pow(2,8),i[5]=t,i[6]=112|o>>>8,i[7]=o,i[8]=128|a>>>24,i[9]=a>>>16,i[10]=a>>>8,i[11]=a,i[12]=n>>>24,i[13]=n>>>16,i[14]=n>>>8,i[15]=n,new Kf(i)}toString(){for(var t="",o=0;this.bytes.length>o;o++)t=t+(this.bytes[o]>>>4).toString(16)+(15&this.bytes[o]).toString(16),o!==3&&o!==5&&o!==7&&o!==9||(t+="-");if(t.length!==36)throw new Error("Invalid UUIDv7 was generated");return t}clone(){return new Kf(this.bytes.slice(0))}equals(t){return this.compareTo(t)===0}compareTo(t){for(var o=0;16>o;o++){var a=this.bytes[o]-t.bytes[o];if(a!==0)return Math.sign(a)}return 0}}class wre{constructor(){this.I=0,this.S=0,this.k=new Tre}generate(){var t=this.generateOrAbort();if(qe(t)){this.I=0;var o=this.generateOrAbort();if(qe(o))throw new Error("Could not generate UUID after timestamp reset");return o}return t}generateOrAbort(){var t=Date.now();if(t>this.I)this.I=t,this.A();else{if(this.I>=t+1e4)return;this.S++,this.S>4398046511103&&(this.I++,this.A())}return Kf.fromFieldsV7(this.I,Math.trunc(this.S/Math.pow(2,30)),this.S&Math.pow(2,30)-1,this.k.nextUint32())}A(){this.S=1024*this.k.nextUint32()+(1023&this.k.nextUint32())}}var rO,Sj=e=>{if(typeof UUIDV7_DENY_WEAK_RNG<"u"&&UUIDV7_DENY_WEAK_RNG)throw new Error("no cryptographically strong RNG available");for(var t=0;e.length>t;t++)e[t]=65536*Math.trunc(65536*Math.random())+Math.trunc(65536*Math.random());return e};ge&&!qe(ge.crypto)&&crypto.getRandomValues&&(Sj=e=>crypto.getRandomValues(e));class Tre{constructor(){this.T=new Uint32Array(8),this.N=1/0}nextUint32(){return this.T.length>this.N||(Sj(this.T),this.N=0),this.T[this.N++]}}var Ts=()=>xre().toString(),xre=()=>(rO||(rO=new wre)).generate(),Lu="",_re=/[a-z0-9][a-z0-9-]+\.[a-z]{2,}$/i,Ur={R:()=>!!ze,B(e){Ue.error("cookieStore error: "+e)},O(e){if(ze){try{for(var t=e+"=",o=ze.cookie.split(";").filter((i=>i.length)),a=0;o.length>a;a++){for(var n=o[a];n.charAt(0)==" ";)n=n.substring(1,n.length);if(n.indexOf(t)===0)return decodeURIComponent(n.substring(t.length,n.length))}}catch{}return null}},Z(e){var t;try{t=JSON.parse(Ur.O(e))||{}}catch{}return t},M(e,t,o,a,n){if(ze)try{var i="",l="",c=(function(m,h){if(h){var f=(function(b,S){if(S===void 0&&(S=ze),Lu)return Lu;if(!S||["localhost","127.0.0.1"].includes(b))return"";for(var _=b.split("."),T=Math.min(_.length,8),x="dmn_chk_"+Ts();!Lu&&T--;){var P=_.slice(T).join("."),C=x+"=1;domain=."+P+";path=/";S.cookie=C+";max-age=3",S.cookie.includes(x)&&(S.cookie=C+";max-age=0",Lu=P)}return Lu})(m);if(!f){var v=(b=>{var S=b.match(_re);return S?S[0]:""})(m);v!==f&&Ue.info("Warning: cookie subdomain discovery mismatch",v,f),f=v}return f?"; domain=."+f:""}return""})(ze.location.hostname,a);if(o){var u=new Date;u.setTime(u.getTime()+864e5*o),i="; expires="+u.toUTCString()}n&&(l="; secure");var p=e+"="+encodeURIComponent(JSON.stringify(t))+i+"; SameSite=Lax; path=/"+c+l;return p.length>3686.4&&Ue.warn("cookieStore warning: large cookie, len="+p.length),ze.cookie=p,p}catch{return}},F(e,t){if(ze!=null&&ze.cookie)try{Ur.M(e,"",-1,t)}catch{return}}},x0=null,_o={R(){if(!Ii(x0))return x0;var e=!0;if(qe(ge))e=!1;else try{var t="__mplssupport__";_o.M(t,"xyz"),_o.O(t)!=='"xyz"'&&(e=!1),_o.F(t)}catch{e=!1}return e||Ue.error("localStorage unsupported; falling back to cookie store"),x0=e,e},B(e){Ue.error("localStorage error: "+e)},O(e){try{return ge?.localStorage.getItem(e)}catch(t){_o.B(t)}return null},Z(e){try{return JSON.parse(_o.O(e))||{}}catch{}return null},M(e,t){try{ge?.localStorage.setItem(e,JSON.stringify(t))}catch(o){_o.B(o)}},F(e){try{ge?.localStorage.removeItem(e)}catch(t){_o.B(t)}}},kre=[Uf,"distinct_id",$f,H_,Hf,Vf,pr],Ig={},Cre={R:()=>!0,B(e){Ue.error("memoryStorage error: "+e)},O:e=>Ig[e]||null,Z:e=>Ig[e]||null,M(e,t){Ig[e]=t},F(e){delete Ig[e]}},ul=null,Ta={R(){if(!Ii(ul))return ul;if(ul=!0,qe(ge))ul=!1;else try{var e="__support__";Ta.M(e,"xyz"),Ta.O(e)!=='"xyz"'&&(ul=!1),Ta.F(e)}catch{ul=!1}return ul},B(e){Ue.error("sessionStorage error: ",e)},O(e){try{return ge?.sessionStorage.getItem(e)}catch(t){Ta.B(t)}return null},Z(e){try{return JSON.parse(Ta.O(e))||null}catch{}return null},M(e,t){try{ge?.sessionStorage.setItem(e,JSON.stringify(t))}catch(o){Ta.B(o)}},F(e){try{ge?.sessionStorage.removeItem(e)}catch(t){Ta.B(t)}}};class Ere{constructor(t){this._instance=t}get Bt(){return this._instance.config}get consent(){return this.rr()?0:this.ir}isOptedOut(){return this.Bt.cookieless_mode===ki||this.isRejected()||this.consent===-1&&this.Bt.cookieless_mode===vl}isOptedIn(){return!this.isOptedOut()}isExplicitlyOptedOut(){return this.consent===0}isRejected(){return this.consent===0||this.consent===-1&&this.Bt.opt_out_capturing_by_default}optInOut(t){this.nr.M(this.sr,t?1:0,this.Bt.cookie_expiration,this.Bt.cross_subdomain_cookie,this.Bt.secure_cookie)}reset(){this.nr.F(this.sr,this.Bt.cross_subdomain_cookie)}get sr(){var{token:t,opt_out_capturing_cookie_prefix:o,consent_persistence_name:a}=this._instance.config;return a||(o?o+t:"__ph_opt_in_out_"+t)}get ir(){var t=this.nr.O(this.sr);return f0(t)?1:kt(Lne,t)?0:-1}get nr(){var t=this.Bt.opt_out_capturing_persistence_type,o=t==="localStorage"?_o:Ur;if(!this.ar||this.ar!==o){this.ar=o;var a=t==="localStorage"?Ur:_o;a.O(this.sr)&&(this.ar.O(this.sr)||this.optInOut(f0(a.O(this.sr))),a.F(this.sr,this.Bt.cross_subdomain_cookie))}return this.ar}rr(){return!!this.Bt.respect_dnt&&[En?.doNotTrack,En?.msDoNotTrack,et.doNotTrack].some((t=>f0(t)))}}var Lg=wo("[Dead Clicks]"),Pre=()=>!0,Are=e=>{var t,o=!((t=e.instance.persistence)==null||!t.get_property(V_)),a=e.instance.config.capture_dead_clicks;return $r(a)?a:!!Bo(a)||o};class iO{get lazyLoadedDeadClicksAutocapture(){return this.lr}constructor(t,o,a){this.instance=t,this.isEnabled=o,this.onCapture=a,this.startIfEnabledOrStop()}onRemoteConfig(t){"captureDeadClicks"in t&&(this.instance.persistence&&this.instance.persistence.register({[V_]:t.captureDeadClicks}),this.startIfEnabledOrStop())}startIfEnabledOrStop(){this.isEnabled(this)?this.ur((()=>{this.hr()})):this.stop()}ur(t){var o,a;(o=et.__PosthogExtensions__)!=null&&o.initDeadClicksAutocapture&&t(),(a=et.__PosthogExtensions__)==null||a.loadExternalDependency==null||a.loadExternalDependency(this.instance,"dead-clicks-autocapture",(n=>{n?Lg.error("failed to load script",n):t()}))}hr(){var t;if(ze){if(!this.lr&&(t=et.__PosthogExtensions__)!=null&&t.initDeadClicksAutocapture){var o=Bo(this.instance.config.capture_dead_clicks)?this.instance.config.capture_dead_clicks:{};o.__onCapture=this.onCapture,this.lr=et.__PosthogExtensions__.initDeadClicksAutocapture(this.instance,o),this.lr.start(ze),Lg.info("starting...")}}else Lg.error("`document` not found. Cannot start.")}stop(){this.lr&&(this.lr.stop(),this.lr=void 0,Lg.info("stopping..."))}}var _0=wo("[SegmentIntegration]"),wj="posthog-js";function Tj(e,t){var{organization:o,projectId:a,prefix:n,severityAllowList:i=["error"],sendExceptionsToPostHog:l=!0}=t===void 0?{}:t;return c=>{var u,p,m,h,f;if(i!=="*"&&!i.includes(c.level)||!e.__loaded)return c;c.tags||(c.tags={});var v=e.requestRouter.endpointFor("ui","/project/"+e.config.token+"/person/"+e.get_distinct_id());c.tags["PostHog Person URL"]=v,e.sessionRecordingStarted()&&(c.tags["PostHog Recording URL"]=e.get_session_replay_url({withTimestamp:!0}));var b,S=((u=c.exception)==null?void 0:u.values)||[],_=S.map((x=>Me({},x,{stacktrace:x.stacktrace?Me({},x.stacktrace,{type:"raw",frames:(x.stacktrace.frames||[]).map((P=>Me({},P,{platform:"web:javascript"})))}):void 0}))),T={$exception_message:((p=S[0])==null?void 0:p.value)||c.message,$exception_type:(m=S[0])==null?void 0:m.type,$exception_level:c.level,$exception_list:_,$sentry_event_id:c.event_id,$sentry_exception:c.exception,$sentry_exception_message:((h=S[0])==null?void 0:h.value)||c.message,$sentry_exception_type:(f=S[0])==null?void 0:f.type,$sentry_tags:c.tags};return o&&a&&(T.$sentry_url=(n||"https://sentry.io/organizations/")+o+"/issues/?project="+a+"&query="+c.event_id),l&&((b=e.exceptions)==null||b.sendExceptionEvent(T)),c}}class Rre{constructor(t,o,a,n,i,l){this.name=wj,this.setupOnce=function(c){c(Tj(t,{organization:o,projectId:a,prefix:n,severityAllowList:i,sendExceptionsToPostHog:l==null||l}))}}}class sO{constructor(t){this.cr=(o,a,n)=>{n&&(n.noSessionId||n.activityTimeout||n.sessionPastMaximumLength)&&(Ue.info("[PageViewManager] Session rotated, clearing pageview state",{sessionId:o,changeReason:n}),this.dr=void 0,this._instance.scrollManager.resetContext())},this._instance=t,this.vr()}vr(){var t;this.pr=(t=this._instance.sessionManager)==null?void 0:t.onSessionId(this.cr)}destroy(){var t;(t=this.pr)==null||t.call(this),this.pr=void 0}doPageView(t,o){var a,n=this.gr(t,o);return this.dr={pathname:(a=ge?.location.pathname)!==null&&a!==void 0?a:"",pageViewId:o,timestamp:t},this._instance.scrollManager.resetContext(),n}doPageLeave(t){var o;return this.gr(t,(o=this.dr)==null?void 0:o.pageViewId)}doEvent(){var t;return{$pageview_id:(t=this.dr)==null?void 0:t.pageViewId}}gr(t,o){var a=this.dr;if(!a)return{$pageview_id:o};var n={$pageview_id:o,$prev_pageview_id:a.pageViewId},i=this._instance.scrollManager.getContext();if(i&&!this._instance.config.disable_scroll_properties){var{maxScrollHeight:l,lastScrollY:c,maxScrollY:u,maxContentHeight:p,lastContentY:m,maxContentY:h}=i;if(!(qe(l)||qe(c)||qe(u)||qe(p)||qe(m)||qe(h))){l=Math.ceil(l),c=Math.ceil(c),u=Math.ceil(u),p=Math.ceil(p),m=Math.ceil(m),h=Math.ceil(h);var f=l>1?qr(c/l,0,1,Ue):1,v=l>1?qr(u/l,0,1,Ue):1,b=p>1?qr(m/p,0,1,Ue):1,S=p>1?qr(h/p,0,1,Ue):1;n=Mo(n,{$prev_pageview_last_scroll:c,$prev_pageview_last_scroll_percentage:f,$prev_pageview_max_scroll:u,$prev_pageview_max_scroll_percentage:v,$prev_pageview_last_content:m,$prev_pageview_last_content_percentage:b,$prev_pageview_max_content:h,$prev_pageview_max_content_percentage:S})}}return a.pathname&&(n.$prev_pageview_pathname=a.pathname),a.timestamp&&(n.$prev_pageview_duration=(t.getTime()-a.timestamp.getTime())/1e3),n}}var Dre={[dj]:{exposure:"hidden"},[ep]:{exposure:"hidden"},__cmpns:{exposure:"hidden"},[tp]:{exposure:"hidden"},[yT]:{exposure:"event"},[ST]:{exposure:"hidden"},[wT]:{exposure:"event"},[TT]:{exposure:"hidden"},[xT]:{exposure:"event"},[_T]:{exposure:"event"},[V_]:{exposure:"event"},[kT]:{exposure:"hidden"},[CT]:{exposure:"event"},[op]:{exposure:"hidden"},$session_recording_enabled_server_side:{exposure:"hidden"},[$f]:{exposure:"hidden"},[H_]:{exposure:"event"},$session_past_minimum_duration:{exposure:"event"},$session_recording_url_trigger_activated_session:{exposure:"event"},$session_recording_event_trigger_activated_session:{exposure:"event"},$debug_first_full_snapshot_timestamp:{exposure:"event"},[ed]:{exposure:"derived",shouldSkipFromEventProperties:(e,t)=>t(),transformToEventProperties(e){if(!Bo(e))return{};for(var t={},o=Object.keys(e),a=0;o.length>a;a++)t["$feature/"+o[a]]=e[o[a]];return t}},[af]:{exposure:"event"},[ap]:{exposure:"hidden"},[ET]:{exposure:"hidden"},[PT]:{exposure:"event"},[AT]:{exposure:"event"},[xi]:{exposure:"event"},[Wc]:{exposure:"hidden"},[np]:{exposure:"hidden"},[fl]:{exposure:"hidden"},[RT]:{exposure:"hidden"},[DT]:{exposure:"event"},[nf]:{exposure:"hidden"},$product_tours_activated:{exposure:"hidden"},$conversations_widget_session_id:{exposure:"event"},$conversations_ticket_id:{exposure:"event"},$conversations_widget_state:{exposure:"event"},$conversations_user_traits:{exposure:"event"},[dp]:{exposure:"hidden"},[OT]:{exposure:"hidden"},[MT]:{exposure:"hidden"},[qf]:{exposure:"hidden"},[pr]:{exposure:"hidden"},[NT]:{exposure:"hidden"},[IT]:{exposure:"hidden"},[LT]:{exposure:"hidden"},[BT]:{exposure:"hidden"},[Vf]:{exposure:"hidden"},[Hf]:{exposure:"hidden"},[uj]:{exposure:"event"},[pj]:{exposure:"event"},[mj]:{exposure:"event"},[hj]:{exposure:"event"},[fj]:{exposure:"event"},[vj]:{exposure:"event"},[bj]:{exposure:"event"},$sdk_debug_replay_event_trigger_status:{exposure:"event"},$sdk_debug_replay_linked_flag_trigger_status:{exposure:"event"},$sdk_debug_replay_matched_recording_trigger_groups:{exposure:"event"},$sdk_debug_replay_remote_trigger_matching_config:{exposure:"event"},$sdk_debug_replay_trigger_groups_count:{exposure:"event"},$sdk_debug_replay_url_trigger_status:{exposure:"event"},$session_recording_start_reason:{exposure:"event"}},Ore=[["$posthog_sr_group_event_trigger_",{exposure:"hidden"}],["$posthog_sr_group_url_trigger_",{exposure:"hidden"}],["$posthog_sr_group_sampling_",{exposure:"hidden"}]],Yf=e=>{var t=ze?.createElement("a");return qe(t)?null:(t.href=e,t)},Zf=function(e,t){for(var o,a=((e.split("#")[0]||"").split(/\?(.*)/)[1]||"").replace(/^\?+/g,"").split("&"),n=0;a.length>n;n++){var i=a[n].split("=");if(i[0]===t){o=i;break}}if(!It(o)||2>o.length)return"";var l=o[1];try{l=decodeURIComponent(l)}catch{Ue.error("Skipping decoding for malformed query param: "+l)}return l.replace(/\+/g," ")},Mp=function(e,t,o){if(!e||!t||!t.length)return e;for(var a=e.split("#"),n=a[1],i=(a[0]||"").split("?"),l=i[1],c=i[0],u=(l||"").split("&"),p=[],m=0;u.length>m;m++){var h=u[m].split("=");It(h)&&(t.includes(h[0])?p.push(h[0]+"="+o):p.push(u[m]))}var f=c;return l!=null&&(f+="?"+p.join("&")),n!=null&&(f+="#"+n),f},Qf=function(e,t){var o=e.match(new RegExp(t+"=([^&]*)"));return o?o[1]:null},Bg="https?://(.*)",_d=["gclid","gclsrc","dclid","gbraid","wbraid","fbclid","msclkid","twclid","li_fat_id","igshid","ttclid","rdt_cid","epik","qclid","sccid","irclid","_kx"],Mre=["utm_source","utm_medium","utm_campaign","utm_content","utm_term","gad_source","mc_cid",..._d],Np="<masked>",Nre=["li_fat_id"];function xj(e,t,o){if(!ze)return{};var a,n=t?[..._d,...o||[]]:[],i=_j(Mp(ze.URL,n,Np),e),l=(a={},go(Nre,(function(c){var u=Ur.O(c);a[c]=u||null})),a);return Mo(l,i)}function _j(e,t){var o=Mre.concat(t||[]),a={};return go(o,(function(n){var i=Zf(e,n);a[n]=i||null})),a}function kj(e){var t=(function(i){return i?i.search(Bg+"google.([^/?]*)")===0?"google":i.search(Bg+"bing.com")===0?"bing":i.search(Bg+"yahoo.com")===0?"yahoo":i.search(Bg+"duckduckgo.com")===0?"duckduckgo":null:null})(e),o=t!="yahoo"?"q":"p",a={};if(!Ii(t)){a.$search_engine=t;var n=ze?Zf(ze.referrer,o):"";n.length&&(a.ph_keyword=n)}return a}function lO(){return navigator.language||navigator.userLanguage}var Jf="$direct";function Cj(){return ze?.referrer||Jf}function Ej(e,t){var o=e?[..._d,...t||[]]:[],a=wa?.href.substring(0,1e3);return{r:Cj().substring(0,1e3),u:a?Mp(a,o,Np):void 0}}function Pj(e){var t,{r:o,u:a}=e,n={$referrer:o,$referring_domain:o==null?void 0:o==Jf?Jf:(t=Yf(o))==null?void 0:t.host};if(a){n.$current_url=a;var i=Yf(a);n.$host=i?.host,n.$pathname=i?.pathname;var l=_j(a);Mo(n,l)}if(o){var c=kj(o);Mo(n,c)}return n}function Aj(){try{return Intl.DateTimeFormat().resolvedOptions().timeZone}catch{return}}function Ire(){try{return new Date().getTimezoneOffset()}catch{return}}var Lre=["cookie","localstorage","localstorage+cookie","sessionstorage","memory"];class k0{constructor(t,o){this.Bt=t,this.props={},this.mr=!1,this.yr=(a=>{var n="";return a.token&&(n=a.token.replace(/\+/g,"PL").replace(/\//g,"SL").replace(/=/g,"EQ")),a.persistence_name?"ph_"+a.persistence_name:"ph_"+n+"_posthog"})(t),this.nr=this.br(t),this.load(),t.debug&&Ue.info("Persistence loaded",t.persistence,Me({},this.props)),this.update_config(t,t,o),this.save()}isDisabled(){return!!this._r}br(t){Lre.indexOf(t.persistence.toLowerCase())===-1&&(Ue.critical("Unknown persistence type "+t.persistence+"; falling back to localStorage+cookie"),t.persistence="localStorage+cookie");var o=(function(n){n===void 0&&(n=[]);var i=[...kre,...n];return Me({},_o,{Z(l){try{var c={};try{c=Ur.Z(l)||{}}catch{}var u=Mo(c,JSON.parse(_o.O(l)||"{}"));return _o.M(l,u),u}catch{}return null},M(l,c,u,p,m,h){try{_o.M(l,c,void 0,void 0,h);var f={};i.forEach((v=>{c[v]&&(f[v]=c[v])})),Object.keys(f).length&&Ur.M(l,f,u,p,m,h)}catch(v){_o.B(v)}},F(l,c){try{ge?.localStorage.removeItem(l),Ur.F(l,c)}catch(u){_o.B(u)}}})})(t.cookie_persisted_properties||[]),a=t.persistence.toLowerCase();return a==="localstorage"&&_o.R()?_o:a==="localstorage+cookie"&&o.R()?o:a==="sessionstorage"&&Ta.R()?Ta:a==="memory"?Cre:a==="cookie"?Ur:o.R()?o:Ur}wr(t){var o=t??this.Bt.feature_flag_cache_ttl_ms;if(!o||0>=o)return!1;var a=this.props[qf];return!a||typeof a!="number"||Date.now()-a>o}properties(){var t={};return go(this.props,((o,a)=>{var n=(i=>{var l=Dre[i];if(l)return l;for(var[c,u]of Ore)if(i.indexOf(c)===0)return u})(a);if(n?.exposure==="derived"){if(n.shouldSkipFromEventProperties!=null&&n.shouldSkipFromEventProperties(o,a===ed?()=>this.wr():()=>!1))return;n.transformToEventProperties&&Mo(t,n.transformToEventProperties(o))}else n&&n.exposure!=="event"||(t[a]=o)})),t}load(){if(!this._r){var t=this.nr.Z(this.yr);t&&(this.props=Mo({},t))}}save(){this._r||this.nr.M(this.yr,this.props,this.Ir,this.Cr,this.Sr,this.Bt.debug)}remove(){this.nr.F(this.yr,!1),this.nr.F(this.yr,!0)}clear(){this.remove(),this.props={}}register_once(t,o,a){if(Bo(t)){qe(o)&&(o="None"),this.Ir=qe(a)?this.kr:a;var n=!1;if(go(t,((i,l)=>{this.props.hasOwnProperty(l)&&this.props[l]!==o||(this.Tr(l,i),n=!0)})),n)return this.save(),!0}return!1}register(t,o){if(Bo(t)){this.Ir=qe(o)?this.kr:o;var a=!1;if(go(t,((n,i)=>{t.hasOwnProperty(i)&&this.props[i]!==n&&(this.Tr(i,n),a=!0)})),a)return this.save(),!0}return!1}unregister(t){t in this.props&&(this.Ar(t),this.save())}update_campaign_params(){if(!this.mr){var t=xj(this.Bt.custom_campaign_params,this.Bt.mask_personal_data_properties,this.Bt.custom_personal_data_properties);Xc(W_(t))||this.register(t),this.mr=!0}}update_search_keyword(){var t;this.register((t=ze?.referrer)?kj(t):{})}update_referrer_info(){var t;this.register_once({$referrer:Cj(),$referring_domain:ze!=null&&ze.referrer&&((t=Yf(ze.referrer))==null?void 0:t.host)||Jf},void 0)}set_initial_person_info(){this.props[LT]||this.props[BT]||this.register_once({[Vf]:Ej(this.Bt.mask_personal_data_properties,this.Bt.custom_personal_data_properties)},void 0)}get_initial_props(){var t={};go([BT,LT],(l=>{var c=this.props[l];c&&go(c,(function(u,p){t["$initial_"+hT(p)]=u}))}));var o,a,n=this.props[Vf];if(n){var i=(o=Pj(n),a={},go(o,(function(l,c){a["$initial_"+hT(c)]=l})),a);Mo(t,i)}return t}safe_merge(t){return go(this.props,(function(o,a){a in t||(t[a]=o)})),t}update_config(t,o,a){if(this.kr=this.Ir=t.cookie_expiration,this.set_disabled(t.disable_persistence||!!a),this.set_cross_subdomain(t.cross_subdomain_cookie),this.set_secure(t.secure_cookie),t.persistence!==o.persistence||!((l,c)=>{if(l.length!==c.length)return!1;var u=[...l].sort(),p=[...c].sort();return u.every(((m,h)=>m===p[h]))})(t.cookie_persisted_properties||[],o.cookie_persisted_properties||[])){var n=this.br(t),i=this.props;this.clear(),this.nr=n,this.props=i,this.save()}}set_disabled(t){this._r=t,this._r?this.remove():this.save()}set_cross_subdomain(t){t!==this.Cr&&(this.Cr=t,this.remove(),this.save())}set_secure(t){t!==this.Sr&&(this.Sr=t,this.remove(),this.save())}set_event_timer(t,o){var a=this.props[tp]||{};a[t]=o,this.Tr(tp,a),this.save()}remove_event_timer(t){var o=this.props[tp]||{},a=o[t];return qe(a)||(delete o[t],this.Tr(tp,o),this.save()),a}get_property(t){return this.props[t]}set_property(t,o){this.Tr(t,o),this.save()}Tr(t,o){this.props[t]=o}Ar(t){delete this.props[t]}}var Bu={Activation:"events",Cancellation:"cancelEvents"},C0={Popover:"popover",API:"api",Widget:"widget"},rp={SHOWN:"survey shown",DISMISSED:"survey dismissed",SENT:"survey sent"},E0={SURVEY_ID:"$survey_id",SURVEY_ITERATION:"$survey_iteration",SURVEY_LAST_SEEN_DATE:"$survey_last_seen_date"},jT={Popover:"popover",Inline:"inline"},Bre={SHOWN:"product tour shown"},cO={TOUR_LAST_SEEN_DATE:"$product_tour_last_seen_date",TOUR_TYPE:"$product_tour_type"},dO=wo("[RateLimiter]");class Fre{constructor(t){this.serverLimits={},this.lastEventRateLimited=!1,this.checkForLimiting=o=>{var a=o.text;if(a&&a.length)try{(JSON.parse(a).quota_limited||[]).forEach((n=>{dO.info((n||"events")+" is quota limited."),this.serverLimits[n]=new Date().getTime()+6e4}))}catch(n){return void dO.warn('could not rate limit - continuing. Error: "'+n?.message+'"',{text:a})}},this.instance=t,this.lastEventRateLimited=this.clientRateLimitContext(!0).isRateLimited}get captureEventsPerSecond(){var t;return((t=this.instance.config.rate_limiting)==null?void 0:t.events_per_second)||10}get captureEventsBurstLimit(){var t;return Math.max(((t=this.instance.config.rate_limiting)==null?void 0:t.events_burst_limit)||10*this.captureEventsPerSecond,this.captureEventsPerSecond)}clientRateLimitContext(t){var o,a,n;t===void 0&&(t=!1);var{captureEventsBurstLimit:i,captureEventsPerSecond:l}=this,c=new Date().getTime(),u=(o=(a=this.instance.persistence)==null?void 0:a.get_property(IT))!==null&&o!==void 0?o:{tokens:i,last:c};u.tokens+=(c-u.last)/1e3*l,u.last=c,u.tokens>i&&(u.tokens=i);var p=1>u.tokens;return p||t||(u.tokens=Math.max(0,u.tokens-1)),!p||this.lastEventRateLimited||t||this.instance.capture("$$client_ingestion_warning",{$$client_ingestion_warning_message:"posthog-js client rate limited. Config is set to "+l+" events per second and "+i+" events burst limit."},{skip_client_rate_limiting:!0}),this.lastEventRateLimited=p,(n=this.instance.persistence)==null||n.set_property(IT,u),{isRateLimited:p,remainingTokens:u.tokens}}isServerRateLimited(t){var o=this.serverLimits[t||"events"]||!1;return o!==!1&&new Date().getTime()<o}}var Fu=wo("[RemoteConfig]");class Rj{constructor(t){this._instance=t}get remoteConfig(){var t;return(t=et._POSTHOG_REMOTE_CONFIG)==null||(t=t[this._instance.config.token])==null?void 0:t.config}Er(t){var o,a;(o=et.__PosthogExtensions__)!=null&&o.loadExternalDependency?(a=et.__PosthogExtensions__)==null||a.loadExternalDependency==null||a.loadExternalDependency(this._instance,"remote-config",(()=>t(this.remoteConfig))):t()}Rr(t){this._instance._send_request({method:"GET",url:this._instance.requestRouter.endpointFor("assets","/array/"+this._instance.config.token+"/config"),callback(o){t(o.json)}})}load(){try{if(this.remoteConfig)return Fu.info("Using preloaded remote config",this.remoteConfig),this.Nr(this.remoteConfig),void this.Mr();if(this._instance.Fr())return void Fu.warn("Remote config is disabled. Falling back to local config.");this.Er((t=>{if(!t)return Fu.info("No config found after loading remote JS config. Falling back to JSON."),void this.Rr((o=>{this.Nr(o),this.Mr()}));this.Nr(t),this.Mr()}))}catch(t){Fu.error("Error loading remote config",t)}}stop(){this.Or&&(clearInterval(this.Or),this.Or=void 0)}refresh(){this._instance.Fr()||ze?.visibilityState==="hidden"||this._instance.reloadFeatureFlags()}Mr(){var t;if(!this.Or){var o=(t=this._instance.config.remote_config_refresh_interval_ms)!==null&&t!==void 0?t:3e5;o!==0&&(this.Or=setInterval((()=>{this.refresh()}),o))}}Nr(t){var o;t||Fu.error("Failed to fetch remote config from PostHog."),this._instance.Nr(t??{}),t?.hasFeatureFlags!==!1&&(this._instance.config.advanced_disable_feature_flags_on_first_load||(o=this._instance.featureFlags)==null||o.ensureFlagsLoaded())}}var Lr={GZipJS:"gzip-js",Base64:"base64"},Jn=Uint8Array,cn=Uint16Array,kd=Uint32Array,K_=new Jn([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),Y_=new Jn([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),uO=new Jn([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),Dj=function(e,t){for(var o=new cn(31),a=0;31>a;++a)o[a]=t+=1<<e[a-1];var n=new kd(o[30]);for(a=1;30>a;++a)for(var i=o[a];o[a+1]>i;++i)n[i]=i-o[a]<<5|a;return[o,n]},Oj=Dj(K_,2),zT=Oj[1];Oj[0][28]=258,zT[258]=28;for(var pO=Dj(Y_,0)[1],Mj=new cn(32768),fo=0;32768>fo;++fo){var Bc=(43690&fo)>>>1|(21845&fo)<<1;Mj[fo]=((65280&(Bc=(61680&(Bc=(52428&Bc)>>>2|(13107&Bc)<<2))>>>4|(3855&Bc)<<4))>>>8|(255&Bc)<<8)>>>1}var up=function(e,t,o){for(var a=e.length,n=0,i=new cn(t);a>n;++n)++i[e[n]-1];var l,c=new cn(t);for(n=0;t>n;++n)c[n]=c[n-1]+i[n-1]<<1;for(l=new cn(a),n=0;a>n;++n)l[n]=Mj[c[e[n]-1]++]>>>15-e[n];return l},Rl=new Jn(288);for(fo=0;144>fo;++fo)Rl[fo]=8;for(fo=144;256>fo;++fo)Rl[fo]=9;for(fo=256;280>fo;++fo)Rl[fo]=7;for(fo=280;288>fo;++fo)Rl[fo]=8;var Xf=new Jn(32);for(fo=0;32>fo;++fo)Xf[fo]=5;var jre=up(Rl,9),zre=up(Xf,5),Nj=function(e){return(e/8>>0)+(7&e&&1)},Ij=function(e,t,o){(o==null||o>e.length)&&(o=e.length);var a=new(e instanceof cn?cn:e instanceof kd?kd:Jn)(o-t);return a.set(e.subarray(t,o)),a},wi=function(e,t,o){var a=t/8>>0;e[a]|=o<<=7&t,e[a+1]|=o>>>8},ju=function(e,t,o){var a=t/8>>0;e[a]|=o<<=7&t,e[a+1]|=o>>>8,e[a+2]|=o>>>16},P0=function(e,t){for(var o=[],a=0;e.length>a;++a)e[a]&&o.push({s:a,f:e[a]});var n=o.length,i=o.slice();if(!n)return[new Jn(0),0];if(n==1){var l=new Jn(o[0].s+1);return l[o[0].s]=1,[l,1]}o.sort((function(E,R){return E.f-R.f})),o.push({s:-1,f:25001});var c=o[0],u=o[1],p=0,m=1,h=2;for(o[0]={s:-1,f:c.f+u.f,l:c,r:u};m!=n-1;)c=o[o[h].f>o[p].f?p++:h++],u=o[p!=m&&o[h].f>o[p].f?p++:h++],o[m++]={s:-1,f:c.f+u.f,l:c,r:u};var f=i[0].s;for(a=1;n>a;++a)i[a].s>f&&(f=i[a].s);var v=new cn(f+1),b=UT(o[m-1],v,0);if(b>t){a=0;var S=0,_=b-t,T=1<<_;for(i.sort((function(E,R){return v[R.s]-v[E.s]||E.f-R.f}));n>a;++a){var x=i[a].s;if(t>=v[x])break;S+=T-(1<<b-v[x]),v[x]=t}for(S>>>=_;S>0;){var P=i[a].s;t>v[P]?S-=1<<t-v[P]++-1:++a}for(;a>=0&&S;--a){var C=i[a].s;v[C]==t&&(--v[C],++S)}b=t}return[new Jn(v),b]},UT=function(e,t,o){return e.s==-1?Math.max(UT(e.l,t,o+1),UT(e.r,t,o+1)):t[e.s]=o},mO=function(e){for(var t=e.length;t&&!e[--t];);for(var o=new cn(++t),a=0,n=e[0],i=1,l=function(u){o[a++]=u},c=1;t>=c;++c)if(e[c]==n&&c!=t)++i;else{if(!n&&i>2){for(;i>138;i-=138)l(32754);i>2&&(l(i>10?i-11<<5|28690:i-3<<5|12305),i=0)}else if(i>3){for(l(n),--i;i>6;i-=6)l(8304);i>2&&(l(i-3<<5|8208),i=0)}for(;i--;)l(n);i=1,n=e[c]}return[o.subarray(0,a),t]},zu=function(e,t){for(var o=0,a=0;t.length>a;++a)o+=e[a]*t[a];return o},$T=function(e,t,o){var a=o.length,n=Nj(t+2);e[n]=255&a,e[n+1]=a>>>8,e[n+2]=255^e[n],e[n+3]=255^e[n+1];for(var i=0;a>i;++i)e[n+i+4]=o[i];return 8*(n+4+a)},hO=function(e,t,o,a,n,i,l,c,u,p,m){wi(t,m++,o),++n[256];for(var h=P0(n,15),f=h[0],v=h[1],b=P0(i,15),S=b[0],_=b[1],T=mO(f),x=T[0],P=T[1],C=mO(S),E=C[0],R=C[1],D=new cn(19),O=0;x.length>O;++O)D[31&x[O]]++;for(O=0;E.length>O;++O)D[31&E[O]]++;for(var L=P0(D,7),$=L[0],B=L[1],U=19;U>4&&!$[uO[U-1]];--U);var j,W,ne,H,Z=p+5<<3,te=zu(n,Rl)+zu(i,Xf)+l,le=zu(n,f)+zu(i,S)+l+14+3*U+zu(D,$)+(2*D[16]+3*D[17]+7*D[18]);if(te>=Z&&le>=Z)return $T(t,m,e.subarray(u,u+p));if(wi(t,m,1+(te>le)),m+=2,te>le){j=up(f,v),W=f,ne=up(S,_),H=S;var Q=up($,B);for(wi(t,m,P-257),wi(t,m+5,R-1),wi(t,m+10,U-4),m+=14,O=0;U>O;++O)wi(t,m+3*O,$[uO[O]]);m+=3*U;for(var N=[x,E],G=0;2>G;++G){var V=N[G];for(O=0;V.length>O;++O)wi(t,m,Q[I=31&V[O]]),m+=$[I],I>15&&(wi(t,m,V[O]>>>5&127),m+=V[O]>>>12)}}else j=jre,W=Rl,ne=zre,H=Xf;for(O=0;c>O;++O)if(a[O]>255){var I;ju(t,m,j[257+(I=a[O]>>>18&31)]),m+=W[I+257],I>7&&(wi(t,m,a[O]>>>23&31),m+=K_[I]);var z=31&a[O];ju(t,m,ne[z]),m+=H[z],z>3&&(ju(t,m,a[O]>>>5&8191),m+=Y_[z])}else ju(t,m,j[a[O]]),m+=W[a[O]];return ju(t,m,j[256]),m+W[256]},Ure=new kd([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),$re=(function(){for(var e=new kd(256),t=0;256>t;++t){for(var o=t,a=9;--a;)o=(1&o&&3988292384)^o>>>1;e[t]=o}return e})(),A0=function(e,t,o){for(;o;++t)e[t]=o,o>>>=8};function qre(e,t){t===void 0&&(t={});var o=(function(){var h=4294967295;return{p(f){for(var v=h,b=0;f.length>b;++b)v=$re[255&v^f[b]]^v>>>8;h=v},d(){return 4294967295^h}}})(),a=e.length;o.p(e);var n,i,l,c,u,p=(c=10+((n=t).filename&&n.filename.length+1||0),u=8,(function(h,f,v,b,S,_){var T=h.length,x=new Jn(b+T+5*(1+Math.floor(T/7e3))+S),P=x.subarray(b,x.length-S),C=0;if(!f||8>T)for(var E=0;T>=E;E+=65535){var R=E+65535;T>R?C=$T(P,C,h.subarray(E,R)):(P[E]=!0,C=$T(P,C,h.subarray(E,T)))}else{for(var D=Ure[f-1],O=D>>>13,L=8191&D,$=(1<<v)-1,B=new cn(32768),U=new cn($+1),j=Math.ceil(v/3),W=2*j,ne=function(He){return(h[He]^h[He+1]<<j^h[He+2]<<W)&$},H=new kd(25e3),Z=new cn(288),te=new cn(32),le=0,Q=0,N=(E=0,0),G=0,V=0;T>E;++E){var I=ne(E),z=32767&E,J=U[I];if(B[z]=J,U[I]=z,E>=G){var pe=T-E;if((le>7e3||N>24576)&&pe>423){C=hO(h,P,0,H,Z,te,Q,N,V,E-V,C),N=le=Q=0,V=E;for(var he=0;286>he;++he)Z[he]=0;for(he=0;30>he;++he)te[he]=0}var _e=2,$e=0,Y=L,ae=z-J&32767;if(pe>2&&I==ne(E-ae))for(var ve=Math.min(O,pe)-1,ie=Math.min(32767,E),Te=Math.min(258,pe);ie>=ae&&--Y&&z!=J;){if(h[E+_e]==h[E+_e-ae]){for(var Ce=0;Te>Ce&&h[E+Ce]==h[E+Ce-ae];++Ce);if(Ce>_e){if(_e=Ce,$e=ae,Ce>ve)break;var it=Math.min(ae,Ce-2),lt=0;for(he=0;it>he;++he){var Ge=E-ae+he+32768&32767,tt=Ge-B[Ge]+32768&32767;tt>lt&&(lt=tt,J=Ge)}}}ae+=(z=J)-(J=B[z])+32768&32767}if($e){H[N++]=268435456|zT[_e]<<18|pO[$e];var Oe=31&zT[_e],De=31&pO[$e];Q+=K_[Oe]+Y_[De],++Z[257+Oe],++te[De],G=E+_e,++le}else H[N++]=h[E],++Z[h[E]]}}C=hO(h,P,!0,H,Z,te,Q,N,V,E-V,C)}return Ij(x,0,b+Nj(C)+S)})(i=e,(l=t).level==null?6:l.level,l.mem==null?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(i.length)))):12+l.mem,c,u)),m=p.length;return(function(h,f){var v=f.filename;if(h[0]=31,h[1]=139,h[2]=8,h[8]=2>f.level?4:f.level==9?2:0,h[9]=3,f.mtime!=0&&A0(h,4,Math.floor(new Date(f.mtime||Date.now())/1e3)),v){h[3]=8;for(var b=0;v.length>=b;++b)h[b+10]=v.charCodeAt(b)}})(p,t),A0(p,m-8,o.d()),A0(p,m-4,a),p}var Vre=!!pT||!!uT,Lj="text/plain",gO=!1,qv=function(e,t,o){var a;o===void 0&&(o=!0);var[n,i]=e.split("?"),l=Me({},t),c=(a=i?.split("&").map((p=>{var m,[h,f]=p.split("="),v=o&&(m=l[h])!==null&&m!==void 0?m:f;return delete l[h],h+"="+v})))!==null&&a!==void 0?a:[],u=(function(p,m){var h,f;m===void 0&&(m="&");var v=[];return go(p,(function(b,S){qe(b)||qe(S)||S==="undefined"||(h=encodeURIComponent((_=>_ instanceof File)(b)?b.name:b.toString()),f=encodeURIComponent(S),v[v.length]=f+"="+h)})),v.join(m)})(l);return u&&c.push(u),n+"?"+c.join("&")},td=(e,t)=>JSON.stringify(e,((o,a)=>typeof a=="bigint"?a.toString():a),t),R0=e=>{if(e.tr)return e.tr;var{data:t,compression:o}=e;if(t){if(o===Lr.GZipJS){var a=qre((function(c,u){var p=c.length;if(typeof TextEncoder<"u")return new TextEncoder().encode(c);for(var m=new Jn(c.length+(c.length>>>1)),h=0,f=function(_){m[h++]=_},v=0;p>v;++v){if(h+5>m.length){var b=new Jn(h+8+(p-v<<1));b.set(m),m=b}var S=c.charCodeAt(v);128>S?f(S):2048>S?(f(192|S>>>6),f(128|63&S)):S>55295&&57344>S?(f(240|(S=65536+(1047552&S)|1023&c.charCodeAt(++v))>>>18),f(128|S>>>12&63),f(128|S>>>6&63),f(128|63&S)):(f(224|S>>>12),f(128|S>>>6&63),f(128|63&S))}return Ij(m,0,h)})(td(t)),{mtime:0});return{contentType:Lj,body:a.buffer.slice(a.byteOffset,a.byteOffset+a.byteLength),estimatedSize:a.byteLength}}if(o===Lr.Base64){var n=(function(c){return c&&btoa(encodeURIComponent(c).replace(/%([0-9A-F]{2})/g,((u,p)=>String.fromCharCode(parseInt(p,16)))))})(td(t)),i=(c=>"data="+encodeURIComponent(typeof c=="string"?c:td(c)))(n);return{contentType:"application/x-www-form-urlencoded",body:i,estimatedSize:new Blob([i]).size}}var l=td(t);return{contentType:"application/json",body:l,estimatedSize:new Blob([l]).size}}},Hre=(function(){var e=Kn((function*(t){var o=td(t.data),a=yield(function(i,l,c){return mT.apply(this,arguments)})(o,Ga.DEBUG,{rethrow:!0});if(!a)return t;var n=yield a.arrayBuffer();return Me({},t,{tr:{contentType:Lj,body:n,estimatedSize:n.byteLength}})}));return function(t){return e.apply(this,arguments)}})(),fO=(e,t)=>qv(e,{_:new Date().getTime().toString(),ver:Ga.JS_SDK_VERSION,compression:t}),sf=[];uT&&sf.push({transport:"fetch",method(e){var t,o,{contentType:a,body:n,estimatedSize:i}=(t=R0(e))!==null&&t!==void 0?t:{},l=new Headers;go(e.headers,(function(m,h){l.append(h,m)})),a&&l.append("Content-Type",a);var c=e.url,u=null;if(WD){var p=new WD;u={signal:p.signal,timeout:setTimeout((()=>p.abort()),e.timeout)}}uT(c,Me({method:e?.method||"GET",headers:l,keepalive:e.method==="POST"&&52428.8>(i||0),body:n,signal:(o=u)==null?void 0:o.signal},e.fetchOptions)).then((m=>m.text().then((h=>{var f={statusCode:m.status,text:h};if(m.status===200)try{f.json=JSON.parse(h)}catch(v){Ue.error(v)}e.callback==null||e.callback(f)})))).catch((m=>{Ue.error(m),e.callback==null||e.callback({statusCode:0,error:m})})).finally((()=>u?clearTimeout(u.timeout):null))}}),pT&&sf.push({transport:"XHR",method(e){var t,o=new pT;o.open(e.method||"GET",e.url,!0);var{contentType:a,body:n}=(t=R0(e))!==null&&t!==void 0?t:{};go(e.headers,(function(i,l){o.setRequestHeader(l,i)})),a&&o.setRequestHeader("Content-Type",a),e.timeout&&(o.timeout=e.timeout),e.disableXHRCredentials||(o.withCredentials=!0),o.onreadystatechange=()=>{if(o.readyState===4){var i={statusCode:o.status,text:o.responseText};if(o.status===200)try{i.json=JSON.parse(o.responseText)}catch{}e.callback==null||e.callback(i)}},o.send(n)}}),En!=null&&En.sendBeacon&&sf.push({transport:"sendBeacon",method(e){var t=qv(e.url,{beacon:"1"});try{var o,{contentType:a,body:n}=(o=R0(e))!==null&&o!==void 0?o:{};if(!n)return;var i=n instanceof Blob?n:new Blob([n],{type:a});En.sendBeacon(t,i)}catch{}}});var qT=3e3;class Gre{constructor(t,o){this.Pr=!0,this.Lr=[],this.Dr=qr(o?.flush_interval_ms||qT,250,5e3,Ue.createLogger("flush interval"),qT),this.Br=t}enqueue(t){this.Lr.push(t),this.jr||this.$r()}unload(){this.qr();var t=this.Lr.length>0?this.Zr():{},o=Object.values(t);[...o.filter((a=>a.url.indexOf("/e")===0)),...o.filter((a=>a.url.indexOf("/e")!==0))].map((a=>{this.Br(Me({},a,{transport:"sendBeacon"}))}))}enable(){this.Pr=!1,this.$r()}$r(){var t=this;this.Pr||(this.jr=setTimeout((()=>{if(this.qr(),this.Lr.length>0){var o=this.Zr(),a=function(){var i=o[n],l=new Date().getTime();i.data&&It(i.data)&&go(i.data,(c=>{c.offset=Math.abs(c.timestamp-l),delete c.timestamp})),t.Br(i)};for(var n in o)a()}}),this.Dr))}qr(){clearTimeout(this.jr),this.jr=void 0}Zr(){var t={};return go(this.Lr,(o=>{var a,n=o,i=(n?n.batchKey:null)||n.url;qe(t[i])&&(t[i]=Me({},n,{data:[]})),(a=t[i].data)==null||a.push(n.data)})),this.Lr=[],t}}var Wre=["retriesPerformedSoFar"];class Kre{constructor(t){this.Vr=!1,this.Hr=3e3,this.Lr=[],this._instance=t,this.Lr=[],this.zr=!0,!qe(ge)&&"onLine"in ge.navigator&&(this.zr=ge.navigator.onLine,this.Ur=()=>{this.zr=!0,this.Yr()},this.Gr=()=>{this.zr=!1},Zo(ge,"online",this.Ur),Zo(ge,"offline",this.Gr))}get length(){return this.Lr.length}retriableRequest(t){var{retriesPerformedSoFar:o}=t,a=jF(t,Wre);Gc(o)&&(a.url=qv(a.url,{retry_count:o})),this._instance._send_request(Me({},a,{callback:n=>{n.statusCode===200||n.statusCode>=400&&500>n.statusCode||(o??0)>=10?a.callback==null||a.callback(n):this.Wr(Me({retriesPerformedSoFar:o},a))}}))}Wr(t){var o=t.retriesPerformedSoFar||0;t.retriesPerformedSoFar=o+1;var a=(function(l){var c=3e3*Math.pow(2,l),u=c/2,p=Math.min(18e5,c),m=Math.random()-.5;return Math.ceil(p+m*(p-u))})(o),n=Date.now()+a;this.Lr.push({retryAt:n,requestOptions:t});var i="Enqueued failed request for retry in "+a;navigator.onLine||(i+=" (Browser is offline)"),Ue.warn(i),this.Vr||(this.Vr=!0,this.Xr())}Xr(){if(this.Jr&&clearTimeout(this.Jr),this.Lr.length===0)return this.Vr=!1,void(this.Jr=void 0);this.Jr=setTimeout((()=>{this.zr&&this.Lr.length>0&&this.Yr(),this.Xr()}),this.Hr)}Yr(){var t=Date.now(),o=[],a=this.Lr.filter((i=>t>i.retryAt||(o.push(i),!1)));if(this.Lr=o,a.length>0)for(var{requestOptions:n}of a)this.retriableRequest(n)}unload(){for(var{requestOptions:t}of(this.Jr&&(clearTimeout(this.Jr),this.Jr=void 0),this.Vr=!1,qe(ge)||(this.Ur&&(ge.removeEventListener("online",this.Ur),this.Ur=void 0),this.Gr&&(ge.removeEventListener("offline",this.Gr),this.Gr=void 0)),this.Lr))try{this._instance._send_request(Me({},t,{transport:"sendBeacon"}))}catch(o){Ue.error(o)}this.Lr=[]}}class Yre{constructor(t){this.Kr=()=>{var o,a,n,i;this.Qr||(this.Qr={});var l=this.scrollElement(),c=this.scrollY(),u=l?Math.max(0,l.scrollHeight-l.clientHeight):0,p=c+(l?.clientHeight||0),m=l?.scrollHeight||0;this.Qr.lastScrollY=Math.ceil(c),this.Qr.maxScrollY=Math.max(c,(o=this.Qr.maxScrollY)!==null&&o!==void 0?o:0),this.Qr.maxScrollHeight=Math.max(u,(a=this.Qr.maxScrollHeight)!==null&&a!==void 0?a:0),this.Qr.lastContentY=p,this.Qr.maxContentY=Math.max(p,(n=this.Qr.maxContentY)!==null&&n!==void 0?n:0),this.Qr.maxContentHeight=Math.max(m,(i=this.Qr.maxContentHeight)!==null&&i!==void 0?i:0)},this._instance=t}get ei(){return this._instance.config.scroll_root_selector}getContext(){return this.Qr}resetContext(){var t=this.Qr;return setTimeout(this.Kr,0),t}startMeasuringScrollPosition(){Zo(ge,"scroll",this.Kr,{capture:!0}),Zo(ge,"scrollend",this.Kr,{capture:!0}),Zo(ge,"resize",this.Kr)}scrollElement(){if(!this.ei)return ge?.document.documentElement;var t=It(this.ei)?this.ei:[this.ei];for(var o of t){var a=ge?.document.querySelector(o);if(a)return a}}scrollY(){if(this.ei){var t=this.scrollElement();return t&&t.scrollTop||0}return ge&&(ge.scrollY||ge.pageYOffset||ge.document.documentElement.scrollTop)||0}scrollX(){if(this.ei){var t=this.scrollElement();return t&&t.scrollLeft||0}return ge&&(ge.scrollX||ge.pageXOffset||ge.document.documentElement.scrollLeft)||0}}var Zre=e=>Ej(e?.config.mask_personal_data_properties,e?.config.custom_personal_data_properties);class vO{constructor(t,o,a,n){this.ti=i=>{var l=this.ri();if(!l||l.sessionId!==i){var c={sessionId:i,props:this.ii(this._instance)};this.ni.register({[NT]:c})}},this._instance=t,this.si=o,this.ni=a,this.ii=n||Zre,this.si.onSessionId(this.ti)}ri(){return this.ni.props[NT]}getSetOnceProps(){var t,o=(t=this.ri())==null?void 0:t.props;return o?"r"in o?Pj(o):{$referring_domain:o.referringDomain,$pathname:o.initialPathName,utm_source:o.utm_source,utm_campaign:o.utm_campaign,utm_medium:o.utm_medium,utm_content:o.utm_content,utm_term:o.utm_term}:{}}getSessionProps(){var t={};return go(W_(this.getSetOnceProps()),((o,a)=>{a==="$current_url"&&(a="url"),t["$session_entry_"+hT(a)]=o})),t}}class Z_{constructor(){this.oi={}}on(t,o){return this.oi[t]||(this.oi[t]=[]),this.oi[t].push(o),()=>{this.oi[t]=this.oi[t].filter((a=>a!==o))}}emit(t,o){for(var a of this.oi[t]||[])a(o);for(var n of this.oi["*"]||[])n(t,o)}}var D0=wo("[SessionId]");class bO{on(t,o){return this.ai.on(t,o)}constructor(t,o,a){var n;if(this.li=[],this.ui=void 0,this.ai=new Z_,this.hi=(p,m)=>!(!Gc(p)||!Gc(m))&&Math.abs(p-m)>this.sessionTimeoutMs,!t.persistence)throw new Error("SessionIdManager requires a PostHogPersistence instance");if(t.config.cookieless_mode===ki)throw new Error('SessionIdManager cannot be used with cookieless_mode="always"');this.Bt=t.config,this.ni=t.persistence,this.ci=void 0,this.di=void 0,this._sessionStartTimestamp=null,this._sessionActivityTimestamp=null,this.vi=o||Ts,this.fi=a||Ts;var i=this.Bt.persistence_name||this.Bt.token;if(this._sessionTimeoutMs=1e3*qr(this.Bt.session_idle_timeout_seconds||1800,60,36e3,D0.createLogger("session_idle_timeout_seconds"),1800),t.register({$configured_session_timeout_ms:this._sessionTimeoutMs}),this.pi(),this.gi="ph_"+i+"_window_id",this.mi="ph_"+i+"_primary_window_exists",this.yi()){var l=Ta.Z(this.gi),c=Ta.Z(this.mi);l&&!c?this.ci=l:Ta.F(this.gi),Ta.M(this.mi,!0)}if((n=this.Bt.bootstrap)!=null&&n.sessionID)try{var u=(p=>{var m=this.Bt.bootstrap.sessionID.replace(/-/g,"");if(m.length!==32)throw new Error("Not a valid UUID");if(m[12]!=="7")throw new Error("Not a UUIDv7");return parseInt(m.substring(0,12),16)})();this.bi(this.Bt.bootstrap.sessionID,new Date().getTime(),u)}catch(p){D0.error("Invalid sessionID in bootstrap",p)}this.wi()}get sessionTimeoutMs(){return this._sessionTimeoutMs}onSessionId(t){return qe(this.li)&&(this.li=[]),this.li.push(t),this.di&&t(this.di,this.ci),()=>{this.li=this.li.filter((o=>o!==t))}}yi(){return this.Bt.persistence!=="memory"&&!this.ni._r&&Ta.R()}Ii(t){t!==this.ci&&(this.ci=t,this.yi()&&Ta.M(this.gi,t))}Ci(){return this.ci?this.ci:this.yi()?Ta.Z(this.gi):null}bi(t,o,a){t===this.di&&o===this._sessionActivityTimestamp&&a===this._sessionStartTimestamp||(this._sessionStartTimestamp=a,this._sessionActivityTimestamp=o,this.di=t,this.ni.register({[$f]:[o,t,a]}))}Si(){var t=this.ni.props[$f];return It(t)&&t.length===2&&t.push(t[0]),t||[0,null,0]}resetSessionId(){this.bi(null,null,null)}destroy(){clearTimeout(this.xi),this.xi=void 0,this.ui&&ge&&(ge.removeEventListener(Wf,this.ui,{capture:!1}),this.ui=void 0),this.li=[]}wi(){this.ui=()=>{this.yi()&&Ta.F(this.mi)},Zo(ge,Wf,this.ui,{capture:!1})}checkAndGetSessionAndWindowId(t,o){if(t===void 0&&(t=!1),o===void 0&&(o=null),this.Bt.cookieless_mode===ki)throw new Error('checkAndGetSessionAndWindowId should not be called with cookieless_mode="always"');var a=o||new Date().getTime(),[n,i,l]=this.Si(),c=this.Ci(),u=Gc(l)&&Math.abs(a-l)>864e5,p=!1,m=!i,h=!m&&!t&&this.hi(a,n);m||h||u?(i=this.vi(),c=this.fi(),D0.info("new session ID generated",{sessionId:i,windowId:c,changeReason:{noSessionId:m,activityTimeout:h,sessionPastMaximumLength:u}}),l=a,p=!0):c||(c=this.fi(),p=!0);var f=Gc(n)&&t&&!u?n:a,v=Gc(l)?l:new Date().getTime();return this.Ii(c),this.bi(i,f,v),t||this.pi(),p&&this.li.forEach((b=>b(i,c,p?{noSessionId:m,activityTimeout:h,sessionPastMaximumLength:u}:void 0))),{sessionId:i,windowId:c,sessionStartTimestamp:v,changeReason:p?{noSessionId:m,activityTimeout:h,sessionPastMaximumLength:u}:void 0,lastActivityTimestamp:n}}pi(){clearTimeout(this.xi),this.xi=setTimeout((()=>{var[t]=this.Si();if(this.hi(new Date().getTime(),t)){var o=this.di;this.resetSessionId(),this.ai.emit("forcedIdleReset",{idleSessionId:o})}}),1.1*this.sessionTimeoutMs)}}var Bj=function(e,t){if(!e)return!1;var o=e.userAgent;if(o&&ZD(o,t))return!0;try{var a=e?.userAgentData;if(a!=null&&a.brands&&a.brands.some((n=>ZD(n?.brand,t))))return!0}catch{}return!!e.webdriver},ev=function(e,t){if(!(function(o){try{new RegExp(o)}catch{return!1}return!0})(t))return!1;try{return new RegExp(t).test(e)}catch{return!1}};function yO(e,t,o){return td({distinct_id:e,userPropertiesToSet:t,userPropertiesToSetOnce:o})}var Fj={exact:(e,t)=>t.some((o=>e.some((a=>o===a)))),is_not:(e,t)=>t.every((o=>e.every((a=>o!==a)))),regex:(e,t)=>t.some((o=>e.some((a=>ev(o,a))))),not_regex:(e,t)=>t.every((o=>e.every((a=>!ev(o,a))))),icontains:(e,t)=>t.map(Fg).some((o=>e.map(Fg).some((a=>o.includes(a))))),not_icontains:(e,t)=>t.map(Fg).every((o=>e.map(Fg).every((a=>!o.includes(a))))),gt:(e,t)=>t.some((o=>{var a=parseFloat(o);return!isNaN(a)&&e.some((n=>a>parseFloat(n)))})),lt:(e,t)=>t.some((o=>{var a=parseFloat(o);return!isNaN(a)&&e.some((n=>a<parseFloat(n)))}))},Fg=e=>e.toLowerCase();function jj(e,t){return!e||Object.entries(e).every((o=>{var[a,n]=o,i=t?.[a];if(qe(i)||Ii(i))return!1;var l=[String(i)],c=Fj[n.operator];return!!c&&c(n.values,l)}))}var VT="custom",SO="i.posthog.com",Qre=/^\/static\//;class Jre{constructor(t){this.ki={},this.instance=t}get apiHost(){var t=this.instance.config.api_host.trim().replace(/\/$/,"");return t==="https://app.posthog.com"?"https://us.i.posthog.com":t}get flagsApiHost(){var t=this.instance.config.flags_api_host;return t?t.trim().replace(/\/$/,""):this.apiHost}get uiHost(){var t,o=(t=this.instance.config.ui_host)==null?void 0:t.replace(/\/$/,"");return o||(o=this.apiHost.replace("."+SO,".posthog.com")),o==="https://app.posthog.com"?"https://us.posthog.com":o}get region(){return this.ki[this.apiHost]||(this.ki[this.apiHost]=/https:\/\/(app|us|us-assets)(\.i)?\.posthog\.com/i.test(this.apiHost)?"us":/https:\/\/(eu|eu-assets)(\.i)?\.posthog\.com/i.test(this.apiHost)?"eu":VT),this.ki[this.apiHost]}Ti(t){var o=this.instance.config.__preview_external_dependency_versioned_paths;if(typeof o=="string"&&Qre.test(t))return o.trim().replace(/\/$/,"")||void 0}endpointFor(t,o){if(o===void 0&&(o=""),o&&(o=o[0]==="/"?o:"/"+o),t==="ui")return this.uiHost+o;if(t==="flags")return this.flagsApiHost+o;if(t==="assets"){var a=this.Ti(o);if(a)return""+a+o}if(this.region===VT)return this.apiHost+o;var n=SO+o;switch(t){case"assets":return"https://"+this.region+"-assets."+n;case"api":return"https://"+this.region+"."+n}}}var to=wo("[Surveys]"),HT="seenSurvey_",Xre=[C0.Popover,C0.Widget,C0.API],eie={ignoreConditions:!1,ignoreDelay:!1,displayType:jT.Popover},tie=wo("[PostHog ExternalIntegrations]"),oie={intercom:"intercom-integration",crispChat:"crisp-chat-integration"};class aie{constructor(t){this._instance=t}ur(t,o){var a;(a=et.__PosthogExtensions__)==null||a.loadExternalDependency==null||a.loadExternalDependency(this._instance,t,(n=>{if(n)return tie.error("failed to load script",n);o()}))}startIfEnabledOrStop(){var t=this,o=function(l){var c,u,p;!n||(c=et.__PosthogExtensions__)!=null&&(c=c.integrations)!=null&&c[l]||t.ur(oie[l],(()=>{var m;(m=et.__PosthogExtensions__)==null||(m=m.integrations)==null||(m=m[l])==null||m.start(t._instance)})),!n&&(u=et.__PosthogExtensions__)!=null&&(u=u.integrations)!=null&&u[l]&&((p=et.__PosthogExtensions__)==null||(p=p.integrations)==null||(p=p[l])==null||p.stop())};for(var[a,n]of Object.entries((i=this._instance.config.integrations)!==null&&i!==void 0?i:{})){var i;o(a)}}}var Fc,pp={},O0=0,GT=()=>{},wO='Consent opt in/out is not valid with cookieless_mode="always" and will be ignored',Uu="Surveys module not available",TO="sanitize_properties is deprecated. Use before_send instead",zj="Invalid value for property_denylist config: ",Yc="posthog",Uj=!Vre&&rn?.indexOf("MSIE")===-1&&rn?.indexOf("Mozilla")===-1,xO=e=>{var t;return Me({api_host:"https://us.i.posthog.com",flags_api_host:null,ui_host:null,token:"",autocapture:!0,cross_subdomain_cookie:Sre(ze?.location),persistence:"localStorage+cookie",persistence_name:"",cookie_persisted_properties:[],loaded:GT,save_campaign_params:!0,custom_campaign_params:[],custom_blocked_useragents:[],save_referrer:!0,capture_pageleave:"if_capture_pageview",defaults:e??"unset",__preview_deferred_init_extensions:!1,__preview_external_dependency_versioned_paths:!1,debug:wa&&ko(wa?.search)&&wa.search.indexOf("__posthog_debug=true")!==-1||!1,cookie_expiration:365,upgrade:!1,disable_session_recording:!1,disable_persistence:!1,disable_web_experiments:!0,disable_surveys:!1,disable_surveys_automatic_display:!1,disable_conversations:!1,disable_product_tours:!1,disable_external_dependency_loading:!1,enable_recording_console_log:void 0,secure_cookie:(ge==null||(t=ge.location)==null?void 0:t.protocol)==="https:",ip:!1,opt_out_capturing_by_default:!1,opt_out_persistence_by_default:!1,opt_out_useragent_filter:!1,opt_out_capturing_persistence_type:"localStorage",consent_persistence_name:null,opt_out_capturing_cookie_prefix:null,opt_in_site_apps:!1,property_denylist:[],respect_dnt:!1,sanitize_properties:null,request_headers:{},request_batching:!0,properties_string_max_length:65535,mask_all_element_attributes:!1,mask_all_text:!1,mask_personal_data_properties:!1,custom_personal_data_properties:[],advanced_disable_flags:!1,advanced_disable_decide:!1,advanced_disable_feature_flags:!1,advanced_disable_feature_flags_on_first_load:!1,advanced_only_evaluate_survey_feature_flags:!1,advanced_feature_flags_dedup_per_session:!1,advanced_enable_surveys:!1,advanced_disable_toolbar_metrics:!1,feature_flag_request_timeout_ms:3e3,surveys_request_timeout_ms:1e4,on_request_error(o){Ue.error("Bad HTTP status: "+o.statusCode+" "+o.text)},get_device_id:o=>o,capture_performance:void 0,name:"posthog",bootstrap:{},disable_compression:!1,session_idle_timeout_seconds:1800,person_profiles:FT,before_send:void 0,request_queue_config:{flush_interval_ms:qT},error_tracking:{},_onCapture:GT,__preview_eager_load_replay:!1},(o=>({rageclick:!o||"2025-11-30">o||{content_ignorelist:!0},capture_pageview:!o||"2025-05-24">o||"history_change",session_recording:o&&o>="2025-11-30"?{strictMinimumDuration:!0}:{},external_scripts_inject_target:o&&o>="2026-01-30"?"head":"body",internal_or_test_user_hostname:o&&o>="2026-01-30"?/^(localhost|127\.0\.0\.1)$/:void 0}))(e))},nie=[["process_person","person_profiles"],["xhr_headers","request_headers"],["cookie_name","persistence_name"],["disable_cookie","disable_persistence"],["store_google","save_campaign_params"],["verbose","debug"]],_O=e=>{var t={};for(var[o,a]of nie)qe(e[o])||(t[a]=e[o]);var n=Mo({},t,e);return It(e.property_blacklist)&&(qe(e.property_denylist)?n.property_denylist=e.property_blacklist:It(e.property_denylist)?n.property_denylist=[...e.property_blacklist,...e.property_denylist]:Ue.error(zj+e.property_denylist)),n};class rie{constructor(){this.__forceAllowLocalhost=!1}get Ai(){return this.__forceAllowLocalhost}set Ai(t){Ue.error("WebPerformanceObserver is deprecated and has no impact on network capture. Use `_forceAllowLocalhostNetworkCapture` on `posthog.sessionRecording`"),this.__forceAllowLocalhost=t}}class Yn{Ei(t,o){if(t){var a=this.Ri.indexOf(t);a!==-1&&this.Ri.splice(a,1)}return this.Ri.push(o),o.initialize==null||o.initialize(),o}Ni(){return this.config.cookieless_mode===ki||this.config.cookieless_mode===vl&&this.consent.isRejected()}get decideEndpointWasHit(){var t,o;return(t=(o=this.featureFlags)==null?void 0:o.hasLoadedFlags)!==null&&t!==void 0&&t}get flagsEndpointWasHit(){var t,o;return(t=(o=this.featureFlags)==null?void 0:o.hasLoadedFlags)!==null&&t!==void 0&&t}constructor(){var t;this.webPerformance=new rie,this.Mi=!1,this.version=Ga.LIB_VERSION,this.Fi=new Z_,this.Ri=[],this._calculate_event_properties=this.calculateEventProperties.bind(this),this.config=xO(),this.SentryIntegration=Rre,this.sentryIntegration=a=>(function(n,i){var l=Tj(n,i);return{name:wj,processEvent:c=>l(c)}})(this,a),this.__request_queue=[],this.__loaded=!1,this.analyticsDefaultEndpoint="/e/",this.Oi=!1,this.Pi=null,this.Li=null,this.Di=null,this.scrollManager=new Yre(this),this.pageViewManager=new sO(this),this.rateLimiter=new Fre(this),this.requestRouter=new Jre(this),this.consent=new Ere(this),this.externalIntegrations=new aie(this);var o=(t=Yn.__defaultExtensionClasses)!==null&&t!==void 0?t:{};this.featureFlags=o.featureFlags&&new o.featureFlags(this),this.toolbar=o.toolbar&&new o.toolbar(this),this.surveys=o.surveys&&new o.surveys(this),this.conversations=o.conversations&&new o.conversations(this),this.logs=o.logs&&new o.logs(this),this.experiments=o.experiments&&new o.experiments(this),this.exceptions=o.exceptions&&new o.exceptions(this),this.people={set:(a,n,i)=>{var l=ko(a)?{[a]:n}:a;this.setPersonProperties(l),i?.({})},set_once:(a,n,i)=>{var l=ko(a)?{[a]:n}:a;this.setPersonProperties(void 0,l),i?.({})}},this.on("eventCaptured",(a=>Ue.info('send "'+a?.event+'"',a)))}init(t,o,a){if(a&&a!==Yc){var n,i=(n=pp[a])!==null&&n!==void 0?n:new Yn;return i._init(t,o,a),pp[a]=i,pp[Yc][a]=i,i}return this._init(t,o,a)}_init(t,o,a){var n,i;if(o===void 0&&(o={}),qe(t)||of(t))return Ue.critical("PostHog was initialized without a token. This likely indicates a misconfiguration. Please check the first argument passed to posthog.init()"),this;if(this.__loaded)return console.warn("[PostHog.js]","You have already initialized PostHog! Re-initializing is a no-op"),this;this.__loaded=!0,this.config={},o.debug=this.Bi(o.debug),this.ji=o,this.$i=[],o.person_profiles?this.Li=o.person_profiles:o.process_person&&(this.Li=o.process_person),this.set_config(Mo({},xO(o.defaults),_O(o),{name:a,token:t})),this.config.on_xhr_error&&Ue.error("on_xhr_error is deprecated. Use on_request_error instead"),this.compression=o.disable_compression?void 0:Lr.GZipJS;var l=this.qi();this.persistence=new k0(this.config,l),this.sessionPersistence=this.config.persistence==="sessionStorage"||this.config.persistence==="memory"?this.persistence:new k0(Me({},this.config,{persistence:"sessionStorage"}),l);var c=Me({},this.persistence.props),u=Me({},this.sessionPersistence.props);this.register({$initialization_time:new Date().toISOString()}),this.Zi=new Gre((_=>this.Vi(_)),this.config.request_queue_config),this.Hi=new Kre(this),this.__request_queue=[];var p=this.Ni();if(p||(this.sessionManager=new bO(this),this.sessionPropsManager=new vO(this,this.sessionManager,this.persistence)),this.config.__preview_deferred_init_extensions?(Ue.info("Deferring extension initialization to improve startup performance"),setTimeout((()=>{this.zi(p)}),0)):(Ue.info("Initializing extensions synchronously"),this.zi(p)),Ga.DEBUG=Ga.DEBUG||this.config.debug,Ga.DEBUG&&Ue.info("Starting in debug mode",{this:this,config:o,thisC:Me({},this.config),p:c,s:u}),!this.config.identity_distinct_id||(n=o.bootstrap)!=null&&n.distinctID||(o.bootstrap=Me({},o.bootstrap,{distinctID:this.config.identity_distinct_id,isIdentifiedID:!0})),((i=o.bootstrap)==null?void 0:i.distinctID)!==void 0){var m=o.bootstrap.distinctID,h=this.get_distinct_id(),f=this.persistence.get_property(pr);if(o.bootstrap.isIdentifiedID&&h!=null&&h!==m&&f===Ic)this.identify(m);else if(o.bootstrap.isIdentifiedID&&h!=null&&h!==m&&f===Lc)Ue.warn("Bootstrap distinctID differs from an already-identified user. The existing identity is preserved. Call reset() before reinitializing if you intend to switch users.");else{var v=this.config.get_device_id(Ts()),b=o.bootstrap.isIdentifiedID?v:m;this.persistence.set_property(pr,o.bootstrap.isIdentifiedID?Lc:Ic),this.register({distinct_id:m,$device_id:b})}}if(p)this.register_once({distinct_id:Mg,$device_id:null},"");else if(!this.get_distinct_id()){var S=this.config.get_device_id(Ts());this.register_once({distinct_id:S,$device_id:S},""),this.persistence.set_property(pr,Ic)}return Zo(ge,"onpagehide"in self?"pagehide":"unload",this._handle_unload.bind(this),{passive:!1}),o.segment?(function(_,T){var x=_.config.segment;if(!x)return T();(function(P,C){var E=P.config.segment;if(!E)return C();var R=O=>{var L=()=>O.anonymousId()||Ts();P.config.get_device_id=L,O.id()&&(P.register({distinct_id:O.id(),$device_id:L()}),P.persistence.set_property(pr,Lc)),C()},D=E.user();"then"in D&&_i(D.then)?D.then(R):R(D)})(_,(()=>{x.register((P=>{Promise&&Promise.resolve||_0.warn("This browser does not have Promise support, and can not use the segment integration");var C=(E,R)=>{if(!R)return E;E.event.userId||E.event.anonymousId===P.get_distinct_id()||(_0.info("No userId set, resetting PostHog"),P.reset()),E.event.userId&&E.event.userId!==P.get_distinct_id()&&(_0.info("UserId set, identifying with PostHog"),P.identify(E.event.userId));var D=P.calculateEventProperties(R,E.event.properties);return E.event.properties=Object.assign({},D,E.event.properties),E};return{name:"PostHog JS",type:"enrichment",version:"1.0.0",isLoaded:()=>!0,load:()=>Promise.resolve(),track:E=>C(E,E.event.event),page:E=>C(E,Kc),identify:E=>C(E,T0),screen:E=>C(E,"$screen")}})(_)).then((()=>{T()}))}))})(this,(()=>this.Ui())):this.Ui(),_i(this.config._onCapture)&&this.config._onCapture!==GT&&(Ue.warn("onCapture is deprecated. Please use `before_send` instead"),this.on("eventCaptured",(_=>this.config._onCapture(_.event,_)))),this.config.ip&&Ue.warn('The `ip` config option has NO EFFECT AT ALL and has been deprecated. Use a custom transformation or "Discard IP data" project setting instead. See https://posthog.com/tutorials/web-redact-properties#hiding-customer-ip-address for more information.'),this}zi(t){var o,a,n,i,l,c,u,p=performance.now(),m=Me({},Yn.__defaultExtensionClasses,this.config.__extensionClasses),h=[];m.featureFlags&&this.Ri.push(this.featureFlags=(o=this.featureFlags)!==null&&o!==void 0?o:new m.featureFlags(this)),m.exceptions&&this.Ri.push(this.exceptions=(a=this.exceptions)!==null&&a!==void 0?a:new m.exceptions(this)),m.historyAutocapture&&this.Ri.push(this.historyAutocapture=new m.historyAutocapture(this)),m.tracingHeaders&&this.Ri.push(new m.tracingHeaders(this)),m.siteApps&&this.Ri.push(this.siteApps=new m.siteApps(this)),m.sessionRecording&&!t&&this.Ri.push(this.sessionRecording=new m.sessionRecording(this)),this.config.disable_scroll_properties||h.push((()=>{this.scrollManager.startMeasuringScrollPosition()})),m.autocapture&&this.Ri.push(this.autocapture=new m.autocapture(this)),m.surveys&&this.Ri.push(this.surveys=(n=this.surveys)!==null&&n!==void 0?n:new m.surveys(this)),m.logs&&this.Ri.push(this.logs=(i=this.logs)!==null&&i!==void 0?i:new m.logs(this)),m.conversations&&this.Ri.push(this.conversations=(l=this.conversations)!==null&&l!==void 0?l:new m.conversations(this)),m.productTours&&this.Ri.push(this.productTours=new m.productTours(this)),m.heatmaps&&this.Ri.push(this.heatmaps=new m.heatmaps(this)),m.webVitalsAutocapture&&this.Ri.push(this.webVitalsAutocapture=new m.webVitalsAutocapture(this)),m.exceptionObserver&&this.Ri.push(this.exceptionObserver=new m.exceptionObserver(this)),m.deadClicksAutocapture&&this.Ri.push(this.deadClicksAutocapture=new m.deadClicksAutocapture(this,Are)),m.toolbar&&this.Ri.push(this.toolbar=(c=this.toolbar)!==null&&c!==void 0?c:new m.toolbar(this)),m.experiments&&this.Ri.push(this.experiments=(u=this.experiments)!==null&&u!==void 0?u:new m.experiments(this)),this.Ri.forEach((f=>{f.initialize&&h.push((()=>{f.initialize==null||f.initialize()}))})),h.push((()=>{if(this.Yi){var f=this.Yi;this.Yi=void 0,this.Nr(f)}})),this.Gi(h,p)}Gi(t,o){for(;t.length>0;){if(this.config.__preview_deferred_init_extensions&&performance.now()-o>=30&&t.length>0)return void setTimeout((()=>{this.Gi(t,o)}),0);var a=t.shift();if(a)try{a()}catch(i){Ue.error("Error initializing extension:",i)}}var n=Math.round(performance.now()-o);this.register_for_session({[fj]:this.config.__preview_deferred_init_extensions?"deferred":"synchronous",[vj]:n}),this.config.__preview_deferred_init_extensions&&Ue.info("PostHog extensions initialized ("+n+"ms)")}Nr(t){var o;if(!ze||!ze.body)return Ue.info("document not ready yet, trying again in 500 milliseconds..."),void setTimeout((()=>{this.Nr(t)}),500);this.config.__preview_deferred_init_extensions&&(this.Yi=t),this.Wi=t,this.compression=void 0,t.supportedCompression&&!this.config.disable_compression&&(this.compression=kt(t.supportedCompression,Lr.GZipJS)?Lr.GZipJS:kt(t.supportedCompression,Lr.Base64)?Lr.Base64:void 0),(o=t.analytics)!=null&&o.endpoint&&(this.analyticsDefaultEndpoint=t.analytics.endpoint),this.set_config({person_profiles:this.Li?this.Li:FT}),this.Ri.forEach((a=>a.onRemoteConfig==null?void 0:a.onRemoteConfig(t)))}Ui(){try{this.config.loaded(this)}catch(a){Ue.critical("`loaded` function failed",a)}if(this.Xi(),this.config.internal_or_test_user_hostname&&wa!=null&&wa.hostname){var t=wa.hostname,o=this.config.internal_or_test_user_hostname;(typeof o=="string"?t===o:o.test(t))&&this.setInternalOrTestUser()}this.config.capture_pageview&&setTimeout((()=>{(this.consent.isOptedIn()||this.Ni())&&this.Ji()}),1),this.Ki=new Rj(this),this.Ki.load()}Xi(){var t;this.is_capturing()&&this.config.request_batching&&((t=this.Zi)==null||t.enable())}_dom_loaded(){this.is_capturing()&&Ng(this.__request_queue,(t=>this.Vi(t))),this.__request_queue=[],this.Xi()}_handle_unload(){var t,o,a,n;(t=this.surveys)==null||t.handlePageUnload(),this.config.request_batching?(this.Qi()&&this.capture(w0),(o=this.logs)==null||o.flushLogs("sendBeacon"),(a=this.Zi)==null||a.unload(),(n=this.Hi)==null||n.unload()):this.Qi()&&this.capture(w0,null,{transport:"sendBeacon"})}_send_request(t){this.__loaded&&(Uj?this.__request_queue.push(t):this.rateLimiter.isServerRateLimited(t.batchKey)||(t.transport=t.transport||this.config.api_transport,t.url=qv(t.url,{ip:this.config.ip?1:0}),t.headers=Me({},this.config.request_headers,t.headers),t.compression=t.compression==="best-available"?this.compression:t.compression,t.disableXHRCredentials=this.config.__preview_disable_xhr_credentials,this.config.__preview_disable_beacon&&(t.disableTransport=["sendBeacon"]),t.fetchOptions=t.fetchOptions||this.config.fetch_options,(o=>{var a,n,i,l=Me({},o);l.timeout=l.timeout||6e4,l.url=fO(l.url,l.compression);var c=(a=l.transport)!==null&&a!==void 0?a:"fetch",u=sf.filter((m=>!l.disableTransport||!m.transport||!l.disableTransport.includes(m.transport))),p=(n=(i=(function(m,h){for(var f=0;m.length>f;f++)if(m[f].transport===c)return m[f]})(u))==null?void 0:i.method)!==null&&n!==void 0?n:u[0].method;if(!p)throw new Error("No available transport method");c!=="sendBeacon"&&l.data&&l.compression===Lr.GZipJS&&Rne&&!gO?Hre(l).then((m=>{p(m)})).catch((m=>{if((h=>!(!h||typeof h!="object")&&("name"in h?String(h.name):"")==="NotReadableError")(m))return gO=!0,void p(Me({},l,{compression:void 0,url:fO(o.url,void 0)}));p(l)})):p(l)})(Me({},t,{callback:o=>{var a,n;this.rateLimiter.checkForLimiting(o),400>o.statusCode||(a=(n=this.config).on_request_error)==null||a.call(n,o),t.callback==null||t.callback(o)}}))))}Vi(t){this.Hi?this.Hi.retriableRequest(t):this._send_request(t)}_execute_array(t){O0++;try{var o,a=[],n=[],i=[];Ng(t,(c=>{c&&(It(o=c[0])?i.push(c):_i(c)?c.call(this):It(c)&&o==="alias"?a.push(c):It(c)&&o.indexOf("capture")!==-1&&_i(this[o])?i.push(c):n.push(c))}));var l=function(c,u){Ng(c,(function(p){if(It(p[0])){var m=u;go(p,(function(h){m=m[h[0]].apply(m,h.slice(1))}))}else u[p[0]].apply(u,p.slice(1))}))};l(a,this),l(n,this),l(i,this)}finally{O0--}}push(t){if(O0>0&&It(t)&&ko(t[0])){var o=Yn.prototype[t[0]];_i(o)&&o.apply(this,t.slice(1))}else this._execute_array([t])}capture(t,o,a){var n,i,l,c,u;if(this.__loaded&&this.persistence&&this.sessionPersistence&&this.Zi){if(this.is_capturing())if(!qe(t)&&ko(t)){var p=!this.config.opt_out_useragent_filter&&this._is_bot();if(!p||this.config.__preview_capture_bot_pageviews){var m=a!=null&&a.skip_client_rate_limiting?void 0:this.rateLimiter.clientRateLimitContext();if(m==null||!m.isRateLimited){o!=null&&o.$current_url&&!ko(o?.$current_url)&&(Ue.error("Invalid `$current_url` property provided to `posthog.capture`. Input must be a string. Ignoring provided value."),o==null||delete o.$current_url),t!=="$exception"||a!=null&&a.en||Ue.warn("Using `posthog.capture('$exception')` is unreliable because it does not attach required metadata. Use `posthog.captureException(error)` instead, which attaches required metadata automatically."),this.sessionPersistence.update_search_keyword(),this.config.save_campaign_params&&this.sessionPersistence.update_campaign_params(),this.config.save_referrer&&this.sessionPersistence.update_referrer_info(),(this.config.save_campaign_params||this.config.save_referrer)&&this.persistence.set_initial_person_info();var h=new Date,f=a?.timestamp||h,v=Ts(),b={uuid:v,event:t,properties:this.calculateEventProperties(t,o||{},f,v)};t===Kc&&this.config.__preview_capture_bot_pageviews&&p&&(b.event="$bot_pageview",b.properties.$browser_type="bot"),m&&(b.properties.$lib_rate_limit_remaining_tokens=m.remainingTokens),a?.$set&&(b.$set=a?.$set);var S,_,T,x=this.tn(a?.$set_once,t!==aO,t===T0);if(x&&(b.$set_once=x),a!=null&&a._noTruncate||(i=this.config.properties_string_max_length,l=b,c=L=>ko(L)?L.slice(0,i):L,u=new Set,b=(function L($,B){return $!==Object($)?c?c($):$:u.has($)?void 0:(u.add($),It($)?(U=[],Ng($,(j=>{U.push(L(j))}))):(U={},go($,((j,W)=>{u.has(j)||(U[W]=L(j))}))),U);var U})(l)),b.timestamp=f,qe(a?.timestamp)||(b.properties.$event_time_override_provided=!0,b.properties.$event_time_override_system_time=h),t===rp.DISMISSED||t===rp.SENT){var P=o?.[E0.SURVEY_ID],C=o?.[E0.SURVEY_ITERATION];(L=>{try{var $=(B=>((U,j)=>{var W=""+HT+j.id;return j.current_iteration&&j.current_iteration>0&&(W=""+HT+j.id+"_"+j.current_iteration),W})(0,B))(L);if(localStorage.getItem($))return;localStorage.setItem($,"true")}catch(B){to.error("Failed to persist survey seen state",B)}})({id:P,current_iteration:C}),b.$set=Me({},b.$set,{[(S={id:P,current_iteration:C},_=t===rp.SENT?"responded":"dismissed",T="$survey_"+_+"/"+S.id,S.current_iteration&&S.current_iteration>0&&(T="$survey_"+_+"/"+S.id+"/"+S.current_iteration),T)]:!0})}else t===rp.SHOWN&&(b.$set=Me({},b.$set,{[E0.SURVEY_LAST_SEEN_DATE]:new Date().toISOString()}));if(t===Bre.SHOWN){var E=o?.[cO.TOUR_TYPE];E&&(b.$set=Me({},b.$set,{[cO.TOUR_LAST_SEEN_DATE+"/"+E]:new Date().toISOString()}))}var R=Me({},b.properties.$set,b.$set);if(Xc(R)||this.setPersonPropertiesForFlags(R),!Ct(this.config.before_send)){var D=this.rn(b);if(!D)return;b=D}this.Fi.emit("eventCaptured",b);var O={method:"POST",url:(n=a?._url)!==null&&n!==void 0?n:this.requestRouter.endpointFor("api",this.analyticsDefaultEndpoint),data:b,compression:"best-available",batchKey:a?._batchKey};return!this.config.request_batching||a&&(a==null||!a._batchKey)||a!=null&&a.send_instantly?this.Vi(O):this.Zi.enqueue(O),b}Ue.critical("This capture call is ignored due to client rate limiting.")}}else Ue.error("No event name provided to posthog.capture")}else Ue.uninitializedWarning("posthog.capture")}_addCaptureHook(t){return this.on("eventCaptured",(o=>t(o.event,o)))}calculateEventProperties(t,o,a,n,i){if(a=a||new Date,!this.persistence||!this.sessionPersistence)return o;var l=i?void 0:this.persistence.remove_event_timer(t),c=Me({},o);if(c.token=this.config.token,c.$config_defaults=this.config.defaults,this.Ni()&&(c.$cookieless_mode=!0),t==="$snapshot"){var u=Me({},this.persistence.properties(),this.sessionPersistence.properties());return c.distinct_id=u.distinct_id,(!ko(c.distinct_id)&&!Xn(c.distinct_id)||of(c.distinct_id))&&Ue.error("Invalid distinct_id for replay event. This indicates a bug in your implementation"),c}var p,m=(function(T,x){var P,C,E,R;if(!rn)return{};var D,O,L,$,B,U,j,W,ne=T?[..._d,...x||[]]:[],[H,Z]=(function(te){for(var le=0;XD.length>le;le++){var[Q,N]=XD[le],G=Q.exec(te),V=G&&(_i(N)?N(G,te):N);if(V)return V}return["",""]})(rn);return Mo(W_({$os:H,$os_version:Z,$browser:nj(rn,navigator.vendor),$device:eO(rn),$device_type:(O=rn,L={userAgentDataPlatform:(P=navigator)==null||(P=P.userAgentData)==null?void 0:P.platform,maxTouchPoints:(C=navigator)==null?void 0:C.maxTouchPoints,screenWidth:ge==null||(E=ge.screen)==null?void 0:E.width,screenHeight:ge==null||(R=ge.screen)==null?void 0:R.height,devicePixelRatio:ge?.devicePixelRatio},W=eO(O),W===VF||W===qF||W==="Kobo"||W==="Kindle Fire"||W===aj?wd:W===Dp||W===dd||W===Op||W===fT?"Console":W===GF?"Wearable":W?An:L?.userAgentDataPlatform==="Android"&&(($=L?.maxTouchPoints)!==null&&$!==void 0?$:0)>0?600>Math.min((B=L?.screenWidth)!==null&&B!==void 0?B:0,(U=L?.screenHeight)!==null&&U!==void 0?U:0)/((j=L?.devicePixelRatio)!==null&&j!==void 0?j:1)?An:wd:"Desktop"),$timezone:Aj(),$timezone_offset:Ire()}),{$current_url:Mp(wa?.href,ne,Np),$host:wa?.host,$pathname:wa?.pathname,$raw_user_agent:rn.length>1e3?rn.substring(0,997)+"...":rn,$browser_version:Gne(rn,navigator.vendor),$browser_language:lO(),$browser_language_prefix:(D=lO(),typeof D=="string"?D.split("-")[0]:void 0),$screen_height:ge?.screen.height,$screen_width:ge?.screen.width,$viewport_height:ge?.innerHeight,$viewport_width:ge?.innerWidth,$lib:Ga.LIB_NAME,$lib_version:Ga.LIB_VERSION,$insert_id:Math.random().toString(36).substring(2,10)+Math.random().toString(36).substring(2,10),$time:Date.now()/1e3})})(this.config.mask_personal_data_properties,this.config.custom_personal_data_properties);if(this.sessionManager){var{sessionId:h,windowId:f}=this.sessionManager.checkAndGetSessionAndWindowId(i,a.getTime());c.$session_id=h,c.$window_id=f}this.sessionPropsManager&&Mo(c,this.sessionPropsManager.getSessionProps());try{var v;this.sessionRecording&&Mo(c,this.sessionRecording.sdkDebugProperties),c.$sdk_debug_retry_queue_size=(v=this.Hi)==null?void 0:v.length}catch(T){c.$sdk_debug_error_capturing_properties=String(T)}if(this.requestRouter.region===VT&&(c.$lib_custom_api_host=this.config.api_host),p=t!==Kc||i?t!==w0||i?this.pageViewManager.doEvent():this.pageViewManager.doPageLeave(a):this.pageViewManager.doPageView(a,n),c=Mo(c,p),t===Kc&&ze&&(c.title=ze.title),!qe(l)){var b=a.getTime()-l;c.$duration=parseFloat((b/1e3).toFixed(3))}rn&&this.config.opt_out_useragent_filter&&(c.$browser_type=this._is_bot()?"bot":"browser"),(c=Mo({},m,this.persistence.properties(),this.sessionPersistence.properties(),c)).$is_identified=this._isIdentified(),It(this.config.property_denylist)?go(this.config.property_denylist,(function(T){delete c[T]})):Ue.error(zj+this.config.property_denylist+" or property_blacklist config: "+this.config.property_blacklist);var S=this.config.sanitize_properties;S&&(Ue.error(TO),c=S(c,t));var _=this.nn();return c.$process_person_profile=_,_&&!i&&this.sn("_calculate_event_properties"),c}tn(t,o,a){var n;if(o===void 0&&(o=!0),a===void 0&&(a=!1),!this.persistence||!this.nn()||this.Mi&&!a)return t;var i=this.persistence.get_initial_props(),l=(n=this.sessionPropsManager)==null?void 0:n.getSetOnceProps(),c=Mo({},i,l||{},t||{}),u=this.config.sanitize_properties;return u&&(Ue.error(TO),c=u(c,"$set_once")),o&&(this.Mi=!0),Xc(c)?void 0:c}register(t,o){var a;(a=this.persistence)==null||a.register(t,o)}register_once(t,o,a){var n;(n=this.persistence)==null||n.register_once(t,o,a)}register_for_session(t){var o;(o=this.sessionPersistence)==null||o.register(t)}unregister(t){var o;(o=this.persistence)==null||o.unregister(t)}unregister_for_session(t){var o;(o=this.sessionPersistence)==null||o.unregister(t)}an(t,o){this.register({[t]:o})}getFeatureFlag(t,o){var a;return(a=this.featureFlags)==null?void 0:a.getFeatureFlag(t,o)}getFeatureFlagPayload(t){var o;return(o=this.featureFlags)==null?void 0:o.getFeatureFlagPayload(t)}getFeatureFlagResult(t,o){var a;return(a=this.featureFlags)==null?void 0:a.getFeatureFlagResult(t,o)}isFeatureEnabled(t,o){var a;return(a=this.featureFlags)==null?void 0:a.isFeatureEnabled(t,o)}reloadFeatureFlags(){var t;(t=this.featureFlags)==null||t.reloadFeatureFlags()}updateFlags(t,o,a){var n;(n=this.featureFlags)==null||n.updateFlags(t,o,a)}updateEarlyAccessFeatureEnrollment(t,o,a){var n;(n=this.featureFlags)==null||n.updateEarlyAccessFeatureEnrollment(t,o,a)}getEarlyAccessFeatures(t,o,a){var n;return o===void 0&&(o=!1),(n=this.featureFlags)==null?void 0:n.getEarlyAccessFeatures(t,o,a)}on(t,o){return this.Fi.on(t,o)}onFeatureFlags(t){return this.featureFlags?this.featureFlags.onFeatureFlags(t):(t([],{},{errorsLoading:!0}),()=>{})}onSurveysLoaded(t){return this.surveys?this.surveys.onSurveysLoaded(t):(t([],{isLoaded:!1,error:Uu}),()=>{})}onSessionId(t){var o,a;return(o=(a=this.sessionManager)==null?void 0:a.onSessionId(t))!==null&&o!==void 0?o:()=>{}}getSurveys(t,o){o===void 0&&(o=!1),this.surveys?this.surveys.getSurveys(t,o):t([],{isLoaded:!1,error:Uu})}getActiveMatchingSurveys(t,o){o===void 0&&(o=!1),this.surveys?this.surveys.getActiveMatchingSurveys(t,o):t([],{isLoaded:!1,error:Uu})}renderSurvey(t,o){var a;(a=this.surveys)==null||a.renderSurvey(t,o)}displaySurvey(t,o){var a;o===void 0&&(o=eie),(a=this.surveys)==null||a.displaySurvey(t,o)}cancelPendingSurvey(t){var o;(o=this.surveys)==null||o.cancelPendingSurvey(t)}canRenderSurvey(t){var o,a;return(o=(a=this.surveys)==null?void 0:a.canRenderSurvey(t))!==null&&o!==void 0?o:{visible:!1,disabledReason:Uu}}canRenderSurveyAsync(t,o){var a,n;return o===void 0&&(o=!1),(a=(n=this.surveys)==null?void 0:n.canRenderSurveyAsync(t,o))!==null&&a!==void 0?a:Promise.resolve({visible:!1,disabledReason:Uu})}ln(t){return!t||of(t)?(Ue.critical("Unique user id has not been set in posthog.identify"),!1):t===Mg?(Ue.critical('The string "'+t+'" was set in posthog.identify which indicates an error. This ID is only used as a sentinel value.'),!1):!["distinct_id","distinctid"].includes(t.toLowerCase())&&!["undefined","null"].includes(t.toLowerCase())||(Ue.critical('The string "'+t+'" was set in posthog.identify which indicates an error. This ID should be unique to the user and not a hardcoded string.'),!1)}identify(t,o,a){if(!this.__loaded||!this.persistence)return Ue.uninitializedWarning("posthog.identify");if(Xn(t)&&(t=t.toString(),Ue.warn("The first argument to posthog.identify was a number, but it should be a string. It has been converted to a string.")),this.ln(t)&&this.sn("posthog.identify")){var n=this.get_distinct_id();this.register({$user_id:t}),this.get_property(Uf)||this.register_once({$had_persisted_distinct_id:!0,$device_id:n},""),t!==n&&t!==this.get_property(ep)&&(this.unregister(ep),this.register({distinct_id:t}));var i,l=(this.persistence.get_property(pr)||Ic)===Ic;t!==n&&l?(this.persistence.set_property(pr,Lc),this.setPersonPropertiesForFlags({$set:o||{},$set_once:a||{}},!1),this.capture(T0,{distinct_id:t,$anon_distinct_id:n},{$set:o||{},$set_once:a||{}}),this.Di=yO(t,o,a),(i=this.featureFlags)==null||i.setAnonymousDistinctId(n)):(o||a)&&this.setPersonProperties(o,a),t!==n&&(this.reloadFeatureFlags(),this.unregister(dp))}}setPersonProperties(t,o){if((t||o)&&this.sn("posthog.setPersonProperties")){var a=yO(this.get_distinct_id(),t,o);this.Di!==a?(this.setPersonPropertiesForFlags({$set:t||{},$set_once:o||{}},!0),this.capture("$set",{$set:t||{},$set_once:o||{}}),this.Di=a):Ue.info("A duplicate setPersonProperties call was made with the same properties. It has been ignored.")}}group(t,o,a){if(t&&o){var n=this.getGroups(),i=n[t]!==o;if(i&&this.resetGroupPropertiesForFlags(t),this.register({$groups:Me({},n,{[t]:o})}),i||a){var l={$group_type:t,$group_key:o};a&&(l.$group_set=a),this.capture(aO,l)}a&&this.setGroupPropertiesForFlags({[t]:a}),i&&!a&&this.reloadFeatureFlags()}else Ue.error("posthog.group requires a group type and group key")}resetGroups(){this.register({$groups:{}}),this.resetGroupPropertiesForFlags(),this.reloadFeatureFlags()}setPersonPropertiesForFlags(t,o){var a;o===void 0&&(o=!0),(a=this.featureFlags)==null||a.setPersonPropertiesForFlags(t,o)}resetPersonPropertiesForFlags(){var t;(t=this.featureFlags)==null||t.resetPersonPropertiesForFlags()}setGroupPropertiesForFlags(t,o){var a;o===void 0&&(o=!0),this.sn("posthog.setGroupPropertiesForFlags")&&((a=this.featureFlags)==null||a.setGroupPropertiesForFlags(t,o))}resetGroupPropertiesForFlags(t){var o;(o=this.featureFlags)==null||o.resetGroupPropertiesForFlags(t)}reset(t){var o,a,n,i,l,c,u,p;if(Ue.info("reset"),!this.__loaded)return Ue.uninitializedWarning("posthog.reset");var m=this.get_property(Uf);if(this.consent.reset(),(o=this.persistence)==null||o.clear(),(a=this.sessionPersistence)==null||a.clear(),(n=this.surveys)==null||n.reset(),(i=this.Ki)==null||i.stop(),(l=this.featureFlags)==null||l.reset(),(c=this.conversations)==null||c.reset(),(u=this.persistence)==null||u.set_property(pr,Ic),(p=this.sessionManager)==null||p.resetSessionId(),this.Di=null,this.config.cookieless_mode===ki)this.register_once({distinct_id:Mg,$device_id:null},"");else{var h=this.config.get_device_id(Ts());this.register_once({distinct_id:h,$device_id:t?h:m},"")}this.register({$last_posthog_reset:new Date().toISOString()},1),delete this.config.identity_distinct_id,delete this.config.identity_hash,this.reloadFeatureFlags()}setIdentity(t,o){var a;this.config.identity_distinct_id=t,this.config.identity_hash=o,this.alias(t),(a=this.conversations)==null||a.un()}clearIdentity(){var t;delete this.config.identity_distinct_id,delete this.config.identity_hash,(t=this.conversations)==null||t.hn()}get_distinct_id(){return this.get_property("distinct_id")}getGroups(){return this.get_property("$groups")||{}}get_session_id(){var t,o;return(t=(o=this.sessionManager)==null?void 0:o.checkAndGetSessionAndWindowId(!0).sessionId)!==null&&t!==void 0?t:""}get_session_replay_url(t){if(!this.sessionManager)return"";var{sessionId:o,sessionStartTimestamp:a}=this.sessionManager.checkAndGetSessionAndWindowId(!0),n=this.requestRouter.endpointFor("ui","/project/"+this.config.token+"/replay/"+o);if(t!=null&&t.withTimestamp&&a){var i,l=(i=t.timestampLookBack)!==null&&i!==void 0?i:10;if(!a)return n;n+="?t="+Math.max(Math.floor((new Date().getTime()-a)/1e3)-l,0)}return n}alias(t,o){return t===this.get_property(dj)?(Ue.critical("Attempting to create alias for existing People user - aborting."),-2):this.sn("posthog.alias")?(qe(o)&&(o=this.get_distinct_id()),t!==o?(this.an(ep,t),this.capture("$create_alias",{alias:t,distinct_id:o})):(Ue.warn("alias matches current distinct_id - skipping api call."),this.identify(t),-1)):void 0}set_config(t){var o=Me({},this.config);if(Bo(t)){var a,n,i,l,c,u,p,m,h,f;Mo(this.config,_O(t));var v=this.qi();(a=this.persistence)==null||a.update_config(this.config,o,v),this.sessionPersistence=this.config.persistence==="sessionStorage"||this.config.persistence==="memory"?this.persistence:new k0(Me({},this.config,{persistence:"sessionStorage"}),v);var b=this.Bi(this.config.debug);$r(b)&&(this.config.debug=b),$r(this.config.debug)&&(this.config.debug?(Ga.DEBUG=!0,_o.R()&&_o.M("ph_debug",!0),Ue.info("set_config",{config:t,oldConfig:o,newConfig:Me({},this.config)})):(Ga.DEBUG=!1,_o.R()&&_o.F("ph_debug"))),(n=this.exceptionObserver)==null||n.onConfigChange(),(i=this.exceptions)==null||i.onConfigChange(),(l=this.sessionRecording)==null||l.startIfEnabledOrStop(),(c=this.autocapture)==null||c.startIfEnabled(),(u=this.heatmaps)==null||u.startIfEnabled(),(p=this.exceptionObserver)==null||p.startIfEnabledOrStop(),(m=this.deadClicksAutocapture)==null||m.startIfEnabledOrStop(),(h=this.surveys)==null||h.loadIfEnabled(),this.cn(),(f=this.externalIntegrations)==null||f.startIfEnabledOrStop()}}_overrideSDKInfo(t,o){Ga.LIB_NAME=t,Ga.LIB_VERSION=o}startSessionRecording(t){var o,a,n,i,l,c=t===!0,u={sampling:c||!(t==null||!t.sampling),linked_flag:c||!(t==null||!t.linked_flag),url_trigger:c||!(t==null||!t.url_trigger),event_trigger:c||!(t==null||!t.event_trigger)};Object.values(u).some(Boolean)&&((o=this.sessionManager)==null||o.checkAndGetSessionAndWindowId(),u.sampling&&((a=this.sessionRecording)==null||a.overrideSampling()),u.linked_flag&&((n=this.sessionRecording)==null||n.overrideLinkedFlag()),u.url_trigger&&((i=this.sessionRecording)==null||i.overrideTrigger("url")),u.event_trigger&&((l=this.sessionRecording)==null||l.overrideTrigger("event"))),this.set_config({disable_session_recording:!1})}stopSessionRecording(){this.set_config({disable_session_recording:!0})}sessionRecordingStarted(){var t;return!((t=this.sessionRecording)==null||!t.started)}captureException(t,o){if(this.exceptions){var a=new Error("PostHog syntheticException"),n=this.exceptions.buildProperties(t,{handled:!0,syntheticException:a});return this.exceptions.sendExceptionEvent(Me({},n,o))}}addExceptionStep(t,o){var a;(a=this.exceptions)==null||a.addExceptionStep(t,o)}captureLog(t){var o;(o=this.logs)==null||o.captureLog(t)}get logger(){var t,o;return(t=(o=this.logs)==null?void 0:o.logger)!==null&&t!==void 0?t:Yn.dn}startExceptionAutocapture(t){this.set_config({capture_exceptions:t==null||t})}stopExceptionAutocapture(){this.set_config({capture_exceptions:!1})}loadToolbar(t){var o,a;return(o=(a=this.toolbar)==null?void 0:a.loadToolbar(t))!==null&&o!==void 0&&o}get_property(t){var o;return(o=this.persistence)==null?void 0:o.props[t]}getSessionProperty(t){var o;return(o=this.sessionPersistence)==null?void 0:o.props[t]}toString(){var t,o=(t=this.config.name)!==null&&t!==void 0?t:Yc;return o!==Yc&&(o=Yc+"."+o),o}_isIdentified(){var t,o;return((t=this.persistence)==null?void 0:t.get_property(pr))===Lc||((o=this.sessionPersistence)==null?void 0:o.get_property(pr))===Lc}nn(){var t,o;return!(this.config.person_profiles==="never"||this.config.person_profiles===FT&&!this._isIdentified()&&Xc(this.getGroups())&&((t=this.persistence)==null||(t=t.props)==null||!t[ep])&&((o=this.persistence)==null||(o=o.props)==null||!o[Hf]))}Qi(){return this.config.capture_pageleave===!0||this.config.capture_pageleave==="if_capture_pageview"&&(this.config.capture_pageview===!0||this.config.capture_pageview==="history_change")}createPersonProfile(){this.nn()||this.sn("posthog.createPersonProfile")&&this.setPersonProperties({},{})}setInternalOrTestUser(){this.sn("posthog.setInternalOrTestUser")&&this.setPersonProperties({$internal_or_test_user:!0})}sn(t){return this.config.person_profiles==="never"?(Ue.error(t+' was called, but process_person is set to "never". This call will be ignored.'),!1):(this.an(Hf,!0),!0)}qi(){if(this.config.cookieless_mode==="always")return!0;var t=this.consent.isOptedOut();return this.config.disable_persistence||t&&!(!this.config.opt_out_persistence_by_default&&this.config.cookieless_mode!==vl)}cn(){var t,o,a,n,i=this.qi();return((t=this.persistence)==null?void 0:t._r)!==i&&((a=this.persistence)==null||a.set_disabled(i)),((o=this.sessionPersistence)==null?void 0:o._r)!==i&&((n=this.sessionPersistence)==null||n.set_disabled(i)),i}opt_in_capturing(t){var o;if(this.config.cookieless_mode!==ki){if(this.Ni()){var a,n,i,l,c;this.reset(!0),(a=this.sessionManager)==null||a.destroy(),(n=this.pageViewManager)==null||n.destroy(),this.sessionManager=new bO(this),this.pageViewManager=new sO(this),this.persistence&&(this.sessionPropsManager=new vO(this,this.sessionManager,this.persistence));var u,p=(i=(l=this.config.__extensionClasses)==null?void 0:l.sessionRecording)!==null&&i!==void 0?i:(c=Yn.__defaultExtensionClasses)==null?void 0:c.sessionRecording;p&&(this.sessionRecording=this.Ei(this.sessionRecording,new p(this)),this.Wi&&((u=this.sessionRecording)==null||u.onRemoteConfig==null||u.onRemoteConfig(this.Wi)))}var m,h;this.consent.optInOut(!0),this.cn(),this.Xi(),(o=this.sessionRecording)==null||o.startIfEnabledOrStop(),this.config.cookieless_mode==vl&&((m=this.surveys)==null||m.loadIfEnabled()),(qe(t?.captureEventName)||t!=null&&t.captureEventName)&&this.capture((h=t?.captureEventName)!==null&&h!==void 0?h:"$opt_in",t?.captureProperties,{send_instantly:!0}),this.config.capture_pageview&&this.Ji()}else Ue.warn(wO)}opt_out_capturing(){var t,o,a;this.config.cookieless_mode!==ki?(this.config.cookieless_mode===vl&&this.consent.isOptedIn()&&this.reset(!0),this.consent.optInOut(!1),this.cn(),this.config.cookieless_mode===vl&&(this.register({distinct_id:Mg,$device_id:null}),(t=this.sessionManager)==null||t.destroy(),(o=this.pageViewManager)==null||o.destroy(),this.sessionManager=void 0,this.sessionPropsManager=void 0,(a=this.sessionRecording)==null||a.stopRecording(),this.sessionRecording=void 0,this.Ji())):Ue.warn(wO)}has_opted_in_capturing(){return this.consent.isOptedIn()}has_opted_out_capturing(){return this.consent.isOptedOut()}get_explicit_consent_status(){var t=this.consent.consent;return t===1?"granted":t===0?"denied":"pending"}is_capturing(){return this.config.cookieless_mode===ki||(this.config.cookieless_mode===vl?this.consent.isRejected()||this.consent.isOptedIn():!this.has_opted_out_capturing())}clear_opt_in_out_capturing(){this.consent.reset(),this.cn()}_is_bot(){return En?Bj(En,this.config.custom_blocked_useragents):void 0}Ji(){ze&&(ze.visibilityState==="visible"?this.Oi||(this.Oi=!0,this.capture(Kc,{title:ze.title},{send_instantly:!0}),this.Pi&&(ze.removeEventListener(Gf,this.Pi),this.Pi=null)):this.Pi||(this.Pi=this.Ji.bind(this),Zo(ze,Gf,this.Pi)))}debug(t){t===!1?(ge?.console.log("You've disabled debug mode."),this.set_config({debug:!1})):(ge?.console.log("You're now in debug mode. All calls to PostHog will be logged in your console.\nYou can disable this with `posthog.debug(false)`."),this.set_config({debug:!0}))}Fr(){var t,o,a,n,i,l,c=this.ji||{};return"advanced_disable_flags"in c?!!c.advanced_disable_flags:this.config.advanced_disable_flags!==!1?!!this.config.advanced_disable_flags:this.config.advanced_disable_decide===!0?(Ue.warn("Config field 'advanced_disable_decide' is deprecated. Please use 'advanced_disable_flags' instead. The old field will be removed in a future major version."),!0):(a="advanced_disable_decide",n=Ue,i=(o="advanced_disable_flags")in(t=c)&&!Ct(t[o]),l=a in t&&!Ct(t[a]),i?t[o]:!!l&&(n&&n.warn("Config field '"+a+"' is deprecated. Please use '"+o+"' instead. The old field will be removed in a future major version."),t[a]))}rn(t){if(Ct(this.config.before_send))return t;var o=It(this.config.before_send)?this.config.before_send:[this.config.before_send],a=t;for(var n of o){if(a=n(a),Ct(a)){var i="Event '"+t.event+"' was rejected in beforeSend function";return Nne(t.event)?Ue.warn(i+". This can cause unexpected behavior."):Ue.info(i),null}a.properties&&!Xc(a.properties)||Ue.warn("Event '"+t.event+"' has no properties after beforeSend function, this is likely an error.")}return a}getPageViewId(){var t;return(t=this.pageViewManager.dr)==null?void 0:t.pageViewId}captureTraceFeedback(t,o){this.capture("$ai_feedback",{$ai_trace_id:String(t),$ai_feedback_text:o})}captureTraceMetric(t,o,a){this.capture("$ai_metric",{$ai_trace_id:String(t),$ai_metric_name:o,$ai_metric_value:String(a)})}Bi(t){var o=$r(t)&&!t,a=_o.R()&&_o.O("ph_debug")==="true";return!o&&(!!a||t)}}function kO(e){return e instanceof Element&&(e.id===gj||!(e.closest==null||!e.closest(".toolbar-global-fade-container")))}function Vv(e){return!!e&&e.nodeType===1}function Ds(e,t){return!!e&&!!e.tagName&&e.tagName.toLowerCase()===t.toLowerCase()}function $j(e){return!!e&&e.nodeType===3}function qj(e){return!!e&&e.nodeType===11}function Q_(e){return e?Uv(e).split(/\s+/):[]}function CO(e){var t=ge?.location.href;return!!(t&&e&&e.some((o=>t.match(o))))}function tv(e){var t="";switch(typeof e.className){case"string":t=e.className;break;case"object":t=(e.className&&"baseVal"in e.className?e.className.baseVal:null)||e.getAttribute("class")||"";break;default:t=""}return Q_(t)}function Vj(e){return Ct(e)?null:Uv(e).split(/(\s+)/).filter((t=>mp(t))).join("").replace(/[\r\n]/g," ").replace(/[ ]+/g," ").substring(0,255)}function Ip(e){var t="";return KT(e)&&!Gj(e)&&e.childNodes&&e.childNodes.length&&go(e.childNodes,(function(o){var a;$j(o)&&o.textContent&&(t+=(a=Vj(o.textContent))!==null&&a!==void 0?a:"")})),Uv(t)}function EO(e){return qe(e.target)?e.srcElement||null:(t=e.target)!=null&&t.shadowRoot?e.composedPath()[0]||null:e.target||null;var t}Yn.__defaultExtensionClasses={},Yn.dn={trace:Fc=()=>{},debug:Fc,info:Fc,warn:Fc,error:Fc,fatal:Fc},(function(e,t){for(var o=0;t.length>o;o++)e.prototype[t[o]]=bre(e.prototype[t[o]])})(Yn,["identify"]);var J_=["a","button","form","input","select","textarea","label"];function PO(e,t){if(qe(t))return!0;var o,a=function(i){if(t.some((l=>i.matches(l))))return{v:!0}};for(var n of e)if(o=a(n))return o.v;return!1}function Hj(e){var t=e.parentNode;return!(!t||!Vv(t))&&t}var iie=["next","previous","prev",">","<"],AO=[".ph-no-rageclick",".ph-no-capture"],WT=e=>!e||Ds(e,"html")||!Vv(e),RO=(e,t)=>{if(!ge||WT(e))return{parentIsUsefulElement:!1,targetElementList:[]};for(var o=!1,a=[e],n=e;n.parentNode&&!Ds(n,"body");)if(qj(n.parentNode))a.push(n.parentNode.host),n=n.parentNode.host;else{var i=Hj(n);if(!i)break;if(t||J_.indexOf(i.tagName.toLowerCase())>-1)o=!0;else{var l=ge.getComputedStyle(i);l&&l.getPropertyValue("cursor")==="pointer"&&(o=!0)}a.push(i),n=i}return{parentIsUsefulElement:o,targetElementList:a}};function KT(e){for(var t=e;t.parentNode&&!Ds(t,"body");t=t.parentNode){var o=tv(t);if(kt(o,"ph-sensitive")||kt(o,"ph-no-capture"))return!1}if(kt(tv(e),"ph-include"))return!0;var a=e.type||"";if(ko(a))switch(a.toLowerCase()){case"hidden":case"password":return!1}var n=e.name||e.id||"";return!ko(n)||!/^cc|cardnum|ccnum|creditcard|csc|cvc|cvv|exp|pass|pwd|routing|seccode|securitycode|securitynum|socialsec|socsec|ssn/i.test(n.replace(/[^a-zA-Z0-9]/g,""))}function Gj(e){return!!(Ds(e,"input")&&!["button","checkbox","submit","reset"].includes(e.type)||Ds(e,"select")||Ds(e,"textarea")||e.getAttribute("contenteditable")==="true")}var Wj="(4[0-9]{12}(?:[0-9]{3})?)|(5[1-5][0-9]{14})|(6(?:011|5[0-9]{2})[0-9]{12})|(3[47][0-9]{13})|(3(?:0[0-5]|[68][0-9])[0-9]{11})|((?:2131|1800|35[0-9]{3})[0-9]{11})",sie=new RegExp("^(?:"+Wj+")$"),lie=new RegExp(Wj),Kj="\\d{3}-?\\d{2}-?\\d{4}",cie=new RegExp("^("+Kj+")$"),die=new RegExp("("+Kj+")");function mp(e,t){return t===void 0&&(t=!0),!(Ct(e)||ko(e)&&(e=Uv(e),(t?sie:lie).test((e||"").replace(/[- ]/g,""))||(t?cie:die).test(e)))}function DO(e){var t=Ip(e);return mp(t=(t+" "+Yj(e)).trim())?t:""}function Yj(e){var t="";return e&&e.childNodes&&e.childNodes.length&&go(e.childNodes,(function(o){var a;if(o&&((a=o.tagName)==null?void 0:a.toLowerCase())==="span")try{var n=Ip(o);t=(t+" "+n).trim(),o.childNodes&&o.childNodes.length&&(t=(t+" "+Yj(o)).trim())}catch(i){Ue.error("[AutoCapture]",i)}})),t}function OO(e){return e.replace(/"|\\"/g,'\\"')}function uie(e){var t=e.attr__class;return t?It(t)?t:Q_(t):void 0}class MO{constructor(t){this.disabled=t===!1;var o=Bo(t)?t:{};this.thresholdPx=o.threshold_px||30,this.timeoutMs=o.timeout_ms||1e3,this.clickCount=o.click_count||3,this.clicks=[]}isRageClick(t,o,a){if(this.disabled)return!1;var n=this.clicks[this.clicks.length-1];if(n&&Math.abs(t-n.x)+Math.abs(o-n.y)<this.thresholdPx&&this.timeoutMs>a-n.timestamp){if(this.clicks.push({x:t,y:o,timestamp:a}),this.clicks.length===this.clickCount)return!0}else this.clicks=[{x:t,y:o,timestamp:a}];return!1}}var M0="$copy_autocapture",NO=wo("[AutoCapture]");function N0(e,t){return t.length>e?t.slice(0,e)+"...":t}function pie(e){if(e.previousElementSibling)return e.previousElementSibling;var t=e;do t=t.previousSibling;while(t&&!Vv(t));return t}function mie(e,t){for(var o,a,{e:n,maskAllElementAttributes:i,maskAllText:l,elementAttributeIgnoreList:c,elementsChainAsString:u}=t,p=[e],m=e;m.parentNode&&!Ds(m,"body");)qj(m.parentNode)?(p.push(m.parentNode.host),m=m.parentNode.host):(p.push(m.parentNode),m=m.parentNode);var h,f,v=[],b={},S=!1,_=!1;if(go(p,(E=>{var R=KT(E);E.tagName.toLowerCase()==="a"&&(S=E.getAttribute("href"),S=R&&S&&mp(S)&&S),kt(tv(E),"ph-no-capture")&&(_=!0),v.push((function(O,L,$,B){var U=O.tagName.toLowerCase(),j={tag_name:U};J_.indexOf(U)>-1&&!$&&(j.$el_text=U.toLowerCase()==="a"||U.toLowerCase()==="button"?N0(1024,DO(O)):N0(1024,Ip(O)));var W=tv(O);W.length>0&&(j.classes=W.filter((function(te){return te!==""}))),go(O.attributes,(function(te){var le;if((!Gj(O)||["name","id","class","aria-label"].indexOf(te.name)!==-1)&&(B==null||!B.includes(te.name))&&!L&&mp(te.value)&&(!ko(le=te.name)||le.substring(0,10)!=="_ngcontent"&&le.substring(0,7)!=="_nghost")){var Q=te.value;te.name==="class"&&(Q=Q_(Q).join(" ")),j["attr__"+te.name]=N0(1024,Q)}}));for(var ne=1,H=1,Z=O;Z=pie(Z);)ne++,Z.tagName===O.tagName&&H++;return j.nth_child=ne,j.nth_of_type=H,j})(E,i,l,c));var D=(function(O){if(!KT(O))return{};var L={};return go(O.attributes,(function($){if($.name&&$.name.indexOf("data-ph-capture-attribute")===0){var B=$.name.replace("data-ph-capture-attribute-",""),U=$.value;B&&U&&mp(U)&&(L[B]=U)}})),L})(E);Mo(b,D)})),_)return{props:{},explicitNoCapture:_};if(l||(v[0].$el_text=e.tagName.toLowerCase()==="a"||e.tagName.toLowerCase()==="button"?DO(e):Ip(e)),S){var T,x;v[0].attr__href=S;var P=(T=Yf(S))==null?void 0:T.host,C=ge==null||(x=ge.location)==null?void 0:x.host;P&&C&&P!==C&&(h=S)}return{props:Mo({$event_type:n.type,$ce_version:1},u?{}:{$elements:v},{$elements_chain:(f=v,(function(E){return E.map((R=>{var D,O,L="";if(R.tag_name&&(L+=R.tag_name),R.attr_class)for(var $ of(R.attr_class.sort(),R.attr_class))L+="."+$.replace(/"/g,"");var B=Me({},R.text?{text:R.text}:{},{"nth-child":(D=R.nth_child)!==null&&D!==void 0?D:0,"nth-of-type":(O=R.nth_of_type)!==null&&O!==void 0?O:0},R.href?{href:R.href}:{},R.attr_id?{attr_id:R.attr_id}:{},R.attributes),U={};return rf(B).sort(((j,W)=>{var[ne]=j,[H]=W;return ne.localeCompare(H)})).forEach((j=>{var[W,ne]=j;return U[OO(W.toString())]=OO(ne.toString())})),(L+=":")+rf(U).map((j=>{var[W,ne]=j;return W+'="'+ne+'"'})).join("")})).join(";")})((function(E){return E.map((R=>{var D,O,L={text:(D=R.$el_text)==null?void 0:D.slice(0,400),tag_name:R.tag_name,href:(O=R.attr__href)==null?void 0:O.slice(0,2048),attr_class:uie(R),attr_id:R.attr__id,nth_child:R.nth_child,nth_of_type:R.nth_of_type,attributes:{}};return rf(R).filter(($=>{var[B]=$;return B.indexOf("attr__")===0})).forEach(($=>{var[B,U]=$;return L.attributes[B]=U})),L}))})(f)))},(o=v[0])!=null&&o.$el_text?{$el_text:(a=v[0])==null?void 0:a.$el_text}:{},h&&n.type==="click"?{$external_click_url:h}:{},b)}}var $u=wo("[ExceptionAutocapture]");function IO(e,t,o){try{if(!(t in e))return()=>{};var a=e[t],n=o(a);return _i(n)&&(n.prototype=n.prototype||{},Object.defineProperties(n,{__posthog_wrapped__:{enumerable:!1,value:!0}})),e[t]=n,()=>{e[t]=a}}catch{return()=>{}}}var hie=wo("[TracingHeaders]"),ps=wo("[Web Vitals]"),LO=9e5,BO="disabled",FO="lazy_loading",qu="awaiting_config",jg="missing_config";wo("[SessionRecording]"),wo("[SessionRecording]");var YT="[SessionRecording]",ms=wo(YT),gie=wo("[Heatmaps]");function jO(e){return Bo(e)&&"clientX"in e&&"clientY"in e&&Xn(e.clientX)&&Xn(e.clientY)}var zO=wo("[Product Tours]"),fie=["$set_once","$set"],hs=wo("[SiteApps]"),UO="Error while initializing PostHog app with config id ";function jc(e,t,o){if(Ct(e))return!1;switch(o){case"exact":return e===t;case"contains":var a=t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&").replace(/_/g,".").replace(/%/g,".*");return new RegExp(a,"i").test(e);case"regex":try{return new RegExp(t).test(e)}catch{return!1}default:return!1}}class vie{constructor(t){this.vn=new Z_,this.fn=(o,a)=>this.pn(o,a)&&this.gn(o,a)&&this.mn(o,a)&&this.yn(o,a),this.pn=(o,a)=>a==null||!a.event||o?.event===a?.event,this._instance=t,this.bn=new Set,this._n=new Set}init(){var t,o;qe((t=this._instance)==null?void 0:t._addCaptureHook)||(o=this._instance)==null||o._addCaptureHook(((a,n)=>{this.on(a,n)}))}register(t){var o,a;if(!qe((o=this._instance)==null?void 0:o._addCaptureHook)&&(t.forEach((l=>{var c,u;(c=this._n)==null||c.add(l),(u=l.steps)==null||u.forEach((p=>{var m;(m=this.bn)==null||m.add(p?.event||"")}))})),(a=this._instance)!=null&&a.autocapture)){var n,i=new Set;t.forEach((l=>{var c;(c=l.steps)==null||c.forEach((u=>{u!=null&&u.selector&&i.add(u?.selector)}))})),(n=this._instance)==null||n.autocapture.setElementSelectors(i)}}on(t,o){var a;o!=null&&t.length!=0&&(this.bn.has(t)||this.bn.has(o?.event))&&this._n&&((a=this._n)==null?void 0:a.size)>0&&this._n.forEach((n=>{this.wn(o,n)&&this.vn.emit("actionCaptured",n.name)}))}In(t){this.onAction("actionCaptured",(o=>t(o)))}wn(t,o){if(o?.steps==null)return!1;for(var a of o.steps)if(this.fn(t,a))return!0;return!1}onAction(t,o){return this.vn.on(t,o)}gn(t,o){if(o!=null&&o.url){var a,n=t==null||(a=t.properties)==null?void 0:a.$current_url;if(!n||typeof n!="string"||!jc(n,o.url,o.url_matching||"contains"))return!1}return!0}mn(t,o){return!!this.Cn(t,o)&&!!this.Sn(t,o)&&!!this.xn(t,o)}Cn(t,o){var a;if(o==null||!o.href)return!0;var n=this.kn(t);if(n.length>0)return n.some((c=>jc(c.href,o.href,o.href_matching||"exact")));var i,l=(t==null||(a=t.properties)==null?void 0:a.$elements_chain)||"";return!!l&&jc((i=l.match(/(?::|")href="(.*?)"/))?i[1]:"",o.href,o.href_matching||"exact")}Sn(t,o){var a;if(o==null||!o.text)return!0;var n=this.kn(t);if(n.length>0)return n.some((p=>jc(p.text,o.text,o.text_matching||"exact")||jc(p.$el_text,o.text,o.text_matching||"exact")));var i,l,c,u=(t==null||(a=t.properties)==null?void 0:a.$elements_chain)||"";return!!u&&(i=(function(p){for(var m,h=[],f=/(?::|")text="(.*?)"/g;!Ct(m=f.exec(p));)h.includes(m[1])||h.push(m[1]);return h})(u),l=o.text,c=o.text_matching||"exact",i.some((p=>jc(p,l,c))))}xn(t,o){var a,n;if(o==null||!o.selector)return!0;var i=t==null||(a=t.properties)==null?void 0:a.$element_selectors;if(i!=null&&i.includes(o.selector))return!0;var l=(t==null||(n=t.properties)==null?void 0:n.$elements_chain)||"";if(o.selector_regex&&l)try{return new RegExp(o.selector_regex).test(l)}catch{return!1}return!1}kn(t){var o;return(t==null||(o=t.properties)==null?void 0:o.$elements)==null?[]:t?.properties.$elements}yn(t,o){return o==null||!o.properties||o.properties.length===0||jj(o.properties.reduce(((a,n)=>{var i=It(n.value)?n.value.map(String):n.value!=null?[String(n.value)]:[];return a[n.key]={values:i,operator:n.operator||"exact"},a}),{}),t?.properties)}}class bie{constructor(t){this._instance=t,this.Tn=new Map,this.An=new Map,this.En=new Map}Rn(t,o){return!!t&&jj(t.propertyFilters,o?.properties)}Nn(t,o){var a=new Map;return t.forEach((n=>{var i;(i=n.conditions)==null||(i=i[o])==null||(i=i.values)==null||i.forEach((l=>{if(l!=null&&l.name){var c=a.get(l.name)||[];c.push(n.id),a.set(l.name,c)}}))})),a}Mn(t,o,a){var n=(a===Bu.Activation?this.Tn:this.An).get(t),i=[];return this.Fn((l=>{i=l.filter((c=>n?.includes(c.id)))})),i.filter((l=>{var c,u=(c=l.conditions)==null||(c=c[a])==null||(c=c.values)==null?void 0:c.find((p=>p.name===t));return this.Rn(u,o)}))}register(t){var o;qe((o=this._instance)==null?void 0:o._addCaptureHook)||(this.On(t),this.Pn(t))}Pn(t){var o=t.filter((a=>{var n,i;return((n=a.conditions)==null?void 0:n.actions)&&((i=a.conditions)==null||(i=i.actions)==null||(i=i.values)==null?void 0:i.length)>0}));o.length!==0&&(this.Ln==null&&(this.Ln=new vie(this._instance),this.Ln.init(),this.Ln.In((a=>{this.onAction(a)}))),o.forEach((a=>{var n,i,l,c,u;a.conditions&&(n=a.conditions)!=null&&n.actions&&(i=a.conditions)!=null&&(i=i.actions)!=null&&i.values&&((l=a.conditions)==null||(l=l.actions)==null||(l=l.values)==null?void 0:l.length)>0&&((c=this.Ln)==null||c.register(a.conditions.actions.values),(u=a.conditions)==null||(u=u.actions)==null||(u=u.values)==null||u.forEach((p=>{if(p&&p.name){var m=this.En.get(p.name);m&&m.push(a.id),this.En.set(p.name,m||[a.id])}})))})))}On(t){var o,a=t.filter((i=>{var l,c;return((l=i.conditions)==null?void 0:l.events)&&((c=i.conditions)==null||(c=c.events)==null||(c=c.values)==null?void 0:c.length)>0})),n=t.filter((i=>{var l,c;return((l=i.conditions)==null?void 0:l.cancelEvents)&&((c=i.conditions)==null||(c=c.cancelEvents)==null||(c=c.values)==null?void 0:c.length)>0}));a.length===0&&n.length===0||((o=this._instance)==null||o._addCaptureHook(((i,l)=>{this.onEvent(i,l)})),this.Tn=this.Nn(t,Bu.Activation),this.An=this.Nn(t,Bu.Cancellation))}onEvent(t,o){var a,n=this.le(),i=this.Dn(),l=this.Bn(),c=((a=this._instance)==null||(a=a.persistence)==null?void 0:a.props[i])||[];if(l===t&&o&&c.length>0){var u,p;n.info("event matched, removing item from activated items",{event:t,eventPayload:o,existingActivatedItems:c});var m=(o==null||(u=o.properties)==null?void 0:u.$survey_id)||(o==null||(p=o.properties)==null?void 0:p.$product_tour_id);if(m){var h=c.indexOf(m);0>h||(c.splice(h,1),this.jn(c))}}else{if(this.An.has(t)){var f=this.Mn(t,o,Bu.Cancellation);f.length>0&&(n.info("cancel event matched, cancelling items",{event:t,itemsToCancel:f.map((b=>b.id))}),f.forEach((b=>{var S=c.indexOf(b.id);0>S||c.splice(S,1),this.$n(b.id)})),this.jn(c))}if(this.Tn.has(t)){n.info("event name matched",{event:t,eventPayload:o,items:this.Tn.get(t)});var v=this.Mn(t,o,Bu.Activation);this.jn(c.concat(v.map((b=>b.id))||[]))}}}onAction(t){var o,a=this.Dn(),n=((o=this._instance)==null||(o=o.persistence)==null?void 0:o.props[a])||[];this.En.has(t)&&this.jn(n.concat(this.En.get(t)||[]))}jn(t){var o=this.le(),a=[...new Set(t)].filter((n=>!this.qn(n)));o.info("updating activated items",{activatedItems:a}),this.Zn(a)}getActivatedIds(){var t,o=this.Dn();return((t=this._instance)==null||(t=t.persistence)==null?void 0:t.props[o])||[]}getEventToItemsMap(){return this.Tn}Vn(){return this.Ln}}class yie extends bie{constructor(t){super(t)}Dn(){return DT}Bn(){return rp.SHOWN}Fn(t){var o;(o=this._instance)==null||o.getSurveys(t)}$n(t){var o;(o=this._instance)==null||o.cancelPendingSurvey(t)}le(){return to}Zn(t){var o;(o=this._instance)==null||(o=o.persistence)==null||o.register({[DT]:t})}qn(){return!1}getSurveys(){return this.getActivatedIds()}getEventToSurveys(){return this.getEventToItemsMap()}}var I0="SDK is not enabled or survey functionality is not yet loaded",$O="Disabled. Not loading surveys.",Sie=ge!=null&&ge.location?Qf(ge.location.hash,"__posthog")||Qf(location.hash,"state"):null,qO="_postHogToolbarParams",VO=wo("[Toolbar]"),qa=wo("[FeatureFlags]"),pl=wo("[FeatureFlags]",{debugEnabled:!0}),L0=`" failed. Feature flags didn't load in time.`,HO=e=>{for(var t={},o=0;e.length>o;o++)t[e[o]]=!0;return t},GO=e=>{var t={};for(var[o,a]of rf(e||{}))a&&(t[o]=a);return t},Ti=wo("[Error tracking]"),WO="Refusing to render web experiment since the viewer is a likely bot",wie={icontains:(e,t)=>!!ge&&t.href.toLowerCase().indexOf(e.toLowerCase())>-1,not_icontains:(e,t)=>!!ge&&t.href.toLowerCase().indexOf(e.toLowerCase())===-1,regex:(e,t)=>!!ge&&ev(t.href,e),not_regex:(e,t)=>!!ge&&!ev(t.href,e),exact:(e,t)=>t.href===e,is_not:(e,t)=>t.href!==e};class Oa{get Bt(){return this._instance.config}constructor(t){var o=this;this.getWebExperimentsAndEvaluateDisplayLogic=function(a){a===void 0&&(a=!1),o.getWebExperiments((n=>{Oa.Hn("retrieved web experiments from the server"),o.zn=new Map,n.forEach((i=>{if(i.feature_flag_key){var l;o.zn&&(Oa.Hn("setting flag key ",i.feature_flag_key," to web experiment ",i),(l=o.zn)==null||l.set(i.feature_flag_key,i));var c=o._instance.getFeatureFlag(i.feature_flag_key);ko(c)&&i.variants[c]&&o.Un(i.name,c,i.variants[c].transforms)}else if(i.variants)for(var u in i.variants){var p=i.variants[u];Oa.Yn(p)&&o.Un(i.name,u,p.transforms)}}))}),a)},this._instance=t,this._instance.onFeatureFlags((a=>{this.onFeatureFlags(a)}))}initialize(){}onFeatureFlags(t){if(this._is_bot())Oa.Hn(WO);else if(!this.Bt.disable_web_experiments){if(Ct(this.zn))return this.zn=new Map,this.loadIfEnabled(),void this.previewWebExperiment();Oa.Hn("applying feature flags",t),t.forEach((o=>{var a;if(this.zn&&(a=this.zn)!=null&&a.has(o)){var n,i=this._instance.getFeatureFlag(o),l=(n=this.zn)==null?void 0:n.get(o);i&&l!=null&&l.variants[i]&&this.Un(l.name,i,l.variants[i].transforms)}}))}}previewWebExperiment(){var t=Oa.getWindowLocation();if(t!=null&&t.search){var o=Zf(t?.search,"__experiment_id"),a=Zf(t?.search,"__experiment_variant");o&&a&&(Oa.Hn("previewing web experiments "+o+" && "+a),this.getWebExperiments((n=>{this.Gn(parseInt(o),a,n)}),!1,!0))}}loadIfEnabled(){this.Bt.disable_web_experiments||this.getWebExperimentsAndEvaluateDisplayLogic()}getWebExperiments(t,o,a){if(this.Bt.disable_web_experiments&&!a)return t([]);var n=this._instance.get_property("$web_experiments");if(n&&!o)return t(n);this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/web_experiments/?token="+this.Bt.token),method:"GET",callback:i=>t(i.statusCode===200&&i.json&&i.json.experiments||[])})}Gn(t,o,a){var n=a.filter((i=>i.id===t));n&&n.length>0&&(Oa.Hn("Previewing web experiment ["+n[0].name+"] with variant ["+o+"]"),this.Un(n[0].name,o,n[0].variants[o].transforms))}static Yn(t){return!Ct(t.conditions)&&Oa.Wn(t)&&Oa.Xn(t)}static Wn(t){var o;if(Ct(t.conditions)||Ct((o=t.conditions)==null?void 0:o.url))return!0;var a,n,i,l=Oa.getWindowLocation();return!!l&&((a=t.conditions)==null||!a.url||wie[(n=(i=t.conditions)==null?void 0:i.urlMatchType)!==null&&n!==void 0?n:"icontains"](t.conditions.url,l))}static getWindowLocation(){return ge?.location}static Xn(t){var o;if(Ct(t.conditions)||Ct((o=t.conditions)==null?void 0:o.utm))return!0;var a=xj();if(a.utm_source){var n,i,l,c,u,p,m,h,f=(n=t.conditions)==null||(n=n.utm)==null||!n.utm_campaign||((i=t.conditions)==null||(i=i.utm)==null?void 0:i.utm_campaign)==a.utm_campaign,v=(l=t.conditions)==null||(l=l.utm)==null||!l.utm_source||((c=t.conditions)==null||(c=c.utm)==null?void 0:c.utm_source)==a.utm_source,b=(u=t.conditions)==null||(u=u.utm)==null||!u.utm_medium||((p=t.conditions)==null||(p=p.utm)==null?void 0:p.utm_medium)==a.utm_medium,S=(m=t.conditions)==null||(m=m.utm)==null||!m.utm_term||((h=t.conditions)==null||(h=h.utm)==null?void 0:h.utm_term)==a.utm_term;return f&&b&&S&&v}return!1}static Hn(t){for(var o=arguments.length,a=new Array(o>1?o-1:0),n=1;o>n;n++)a[n-1]=arguments[n];Ue.info("[WebExperiments] "+t,a)}Un(t,o,a){this._is_bot()?Oa.Hn(WO):o!=="control"?a.forEach((n=>{if(n.selector){var i;Oa.Hn("applying transform of variant "+o+" for experiment "+t+" ",n);var l=(i=document)==null?void 0:i.querySelectorAll(n.selector);l?.forEach((c=>{var u=c;n.html&&(u.innerHTML=n.html),n.css&&u.setAttribute("style",n.css)}))}})):Oa.Hn("Control variants leave the page unmodified.")}_is_bot(){return En&&this._instance?Bj(En,this.Bt.custom_blocked_useragents):void 0}}var Hn=wo("[Conversations]"),ml="Conversations not available yet.",Hv={featureFlags:class{constructor(e){this.Jn=!1,this.Kn=!1,this.Qn=!1,this.es=!1,this.ts=!1,this.rs=!1,this.ns=!1,this.ss=!1,this._instance=e,this.featureFlagEventHandlers=[]}get Bt(){return this._instance.config}get ni(){return this._instance.persistence}os(e){return this._instance.get_property(e)}ls(){var e,t;return(e=(t=this.ni)==null?void 0:t.wr(this.Bt.feature_flag_cache_ttl_ms))!==null&&e!==void 0&&e}us(){return!!this.ls()&&(this.ss||this.Qn||(this.ss=!0,qa.warn("Feature flag cache is stale, triggering refresh..."),this.reloadFeatureFlags()),!0)}hs(){var e,t=(e=this.Bt.evaluation_contexts)!==null&&e!==void 0?e:this.Bt.evaluation_environments;return!this.Bt.evaluation_environments||this.Bt.evaluation_contexts||this.ns||(qa.warn("evaluation_environments is deprecated. Use evaluation_contexts instead. evaluation_environments will be removed in a future version."),this.ns=!0),t!=null&&t.length?t.filter((o=>{var a=o&&typeof o=="string"&&o.trim().length>0;return a||qa.error("Invalid evaluation context found:",o,"Expected non-empty string"),a})):[]}cs(){return this.hs().length>0}initialize(){var e,t,{config:o}=this._instance,a=(e=(t=o.bootstrap)==null?void 0:t.featureFlags)!==null&&e!==void 0?e:{};if(Object.keys(a).length){var n,i,l=(n=(i=o.bootstrap)==null?void 0:i.featureFlagPayloads)!==null&&n!==void 0?n:{},c=Object.keys(a).filter((p=>!!a[p])).reduce(((p,m)=>(p[m]=a[m]||!1,p)),{}),u=Object.keys(l).filter((p=>c[p])).reduce(((p,m)=>(l[m]&&(p[m]=l[m]),p)),{});this.receivedFeatureFlags({featureFlags:c,featureFlagPayloads:u})}}updateFlags(e,t,o){var a=o!=null&&o.merge?this.getFlagVariants():{},n=o!=null&&o.merge?this.getFlagPayloads():{},i=Me({},a,e),l=Me({},n,t),c={};for(var[u,p]of Object.entries(i)){var m=typeof p=="string";c[u]={key:u,enabled:!!m||!!p,variant:m?p:void 0,reason:void 0,metadata:qe(l?.[u])?void 0:{id:0,version:void 0,description:void 0,payload:l[u]}}}this.receivedFeatureFlags({flags:c})}get hasLoadedFlags(){return this.Kn}getFlags(){return Object.keys(this.getFlagVariants())}getFlagsWithDetails(){var e=this.os(ET),t=this.os(xi),o=this.os(Wc);if(!o&&!t)return e||{};var a=Mo({},e||{}),n=[...new Set([...Object.keys(o||{}),...Object.keys(t||{})])];for(var i of n){var l,c,u=a[i],p=t?.[i],m=qe(p)?(l=u?.enabled)!==null&&l!==void 0&&l:!!p,h=qe(p)?u.variant:typeof p=="string"?p:void 0,f=o?.[i],v=Me({},u,{enabled:m,variant:m?h??u?.variant:void 0});m!==u?.enabled&&(v.original_enabled=u?.enabled),h!==u?.variant&&(v.original_variant=u?.variant),f&&(v.metadata=Me({},u?.metadata,{payload:f,original_payload:u==null||(c=u.metadata)==null?void 0:c.payload})),a[i]=v}return this.Jn||(qa.warn(" Overriding feature flag details!",{flagDetails:e,overriddenPayloads:o,finalDetails:a}),this.Jn=!0),a}getFlagVariants(){var e=this.os(ed),t=this.os(xi);if(!t)return e||{};for(var o=Mo({},e),a=Object.keys(t),n=0;a.length>n;n++)o[a[n]]=t[a[n]];return this.Jn||(qa.warn(" Overriding feature flags!",{enabledFlags:e,overriddenFlags:t,finalFlags:o}),this.Jn=!0),o}getFlagPayloads(){var e=this.os(PT),t=this.os(Wc);if(!t)return e||{};for(var o=Mo({},e||{}),a=Object.keys(t),n=0;a.length>n;n++)o[a[n]]=t[a[n]];return this.Jn||(qa.warn(" Overriding feature flag payloads!",{flagPayloads:e,overriddenPayloads:t,finalPayloads:o}),this.Jn=!0),o}reloadFeatureFlags(){this.es||this.Bt.advanced_disable_feature_flags||this.ds||(this._instance.Fi.emit("featureFlagsReloading",!0),this.ds=setTimeout((()=>{this.vs()}),5))}fs(){clearTimeout(this.ds),this.ds=void 0}ensureFlagsLoaded(){this.Kn||this.Qn||this.ds||this.reloadFeatureFlags()}setAnonymousDistinctId(e){this.$anon_distinct_id=e}setReloadingPaused(e){this.es=e}vs(e){var t;if(this.fs(),!this._instance.Fr())if(this.Qn)this.ts=!0;else{var o=this.Bt.token,a=this.os(Uf),n={token:o,distinct_id:this._instance.get_distinct_id(),groups:this._instance.getGroups(),$anon_distinct_id:this.$anon_distinct_id,person_properties:Me({},((t=this.ni)==null?void 0:t.get_initial_props())||{},this.os(np)||{}),group_properties:this.os(fl),timezone:Aj()};Ii(a)||qe(a)||(n.$device_id=a),(e!=null&&e.disableFlags||this.Bt.advanced_disable_feature_flags)&&(n.disable_flags=!0),this.cs()&&(n.evaluation_contexts=this.hs());var i=this._instance.requestRouter.endpointFor("flags","/flags/?v=2"+(this.Bt.advanced_only_evaluate_survey_feature_flags?"&only_evaluate_survey_feature_flags=true":""));this.Qn=!0,this._instance._send_request({method:"POST",url:i,data:n,compression:this.Bt.disable_compression?void 0:Lr.Base64,timeout:this.Bt.feature_flag_request_timeout_ms,callback:l=>{var c,u,p,m=!0;if(l.statusCode===200&&(this.ts||(this.$anon_distinct_id=void 0),m=!1),this.Qn=!1,!n.disable_flags||this.ts){this.rs=!m;var h=[];l.error?l.error instanceof Error?h.push(l.error.name==="AbortError"?"timeout":"connection_error"):h.push("unknown_error"):l.statusCode!==200&&h.push("api_error_"+l.statusCode),(c=l.json)!=null&&c.errorsWhileComputingFlags&&h.push("errors_while_computing_flags");var f,v=!((u=l.json)==null||(u=u.quotaLimited)==null||!u.includes("feature_flags"));v&&h.push("quota_limited"),(p=this.ni)==null||p.register({[MT]:h}),v?qa.warn("You have hit your feature flags quota limit, and will not be able to load feature flags until the quota is reset. Please visit https://posthog.com/docs/billing/limits-alerts to learn more."):(n.disable_flags||this.receivedFeatureFlags((f=l.json)!==null&&f!==void 0?f:{},m,{partialResponse:!!this.Bt.advanced_only_evaluate_survey_feature_flags}),this.ts&&(this.ts=!1,this.vs()))}}})}}getFeatureFlag(e,t){var o;if(t===void 0&&(t={}),!t.fresh||this.rs)if(this.Kn||this.getFlags()&&this.getFlags().length>0){if(!this.us()){var a=this.getFeatureFlagResult(e,t);return(o=a?.variant)!==null&&o!==void 0?o:a?.enabled}}else qa.warn('getFeatureFlag for key "'+e+L0)}getFeatureFlagDetails(e){return this.getFlagsWithDetails()[e]}getFeatureFlagPayload(e){var t=this.getFeatureFlagResult(e,{send_event:!1});return t?.payload}getFeatureFlagResult(e,t){if(t===void 0&&(t={}),!t.fresh||this.rs)if(this.Kn||this.getFlags()&&this.getFlags().length>0){if(!this.us()){var o=this.getFlagVariants(),a=e in o,n=o[e],i=this.getFlagPayloads()[e],l=String(n),c=this.os(AT)||void 0,u=this.os(qf)||void 0,p=this.os(dp)||{};if(this.Bt.advanced_feature_flags_dedup_per_session){var m,h=this._instance.get_session_id(),f=this.os(OT);h&&h!==f&&(p={},(m=this.ni)==null||m.register({[dp]:p,[OT]:h}))}if((t.send_event||!("send_event"in t))&&(!(e in p)||!p[e].includes(l))){var v,b,S,_,T,x,P,C,E,R;It(p[e])?p[e].push(l):p[e]=[l],(v=this.ni)==null||v.register({[dp]:p});var D=this.getFeatureFlagDetails(e),O=[...(b=this.os(MT))!==null&&b!==void 0?b:[]];qe(n)&&O.push("flag_missing");var L={$feature_flag:e,$feature_flag_response:n,$feature_flag_payload:i||null,$feature_flag_request_id:c,$feature_flag_evaluated_at:u,$feature_flag_bootstrapped_response:((S=this.Bt.bootstrap)==null||(S=S.featureFlags)==null?void 0:S[e])||null,$feature_flag_bootstrapped_payload:((_=this.Bt.bootstrap)==null||(_=_.featureFlagPayloads)==null?void 0:_[e])||null,$used_bootstrap_value:!this.rs};qe(D==null||(T=D.metadata)==null?void 0:T.version)||(L.$feature_flag_version=D.metadata.version);var $,B=(x=D==null||(P=D.reason)==null?void 0:P.description)!==null&&x!==void 0?x:D==null||(C=D.reason)==null?void 0:C.code;B&&(L.$feature_flag_reason=B),D!=null&&(E=D.metadata)!=null&&E.id&&(L.$feature_flag_id=D.metadata.id),qe(D?.original_variant)&&qe(D?.original_enabled)||(L.$feature_flag_original_response=qe(D.original_variant)?D.original_enabled:D.original_variant),D!=null&&(R=D.metadata)!=null&&R.original_payload&&(L.$feature_flag_original_payload=D==null||($=D.metadata)==null?void 0:$.original_payload),O.length&&(L.$feature_flag_error=O.join(",")),this._instance.capture("$feature_flag_called",L)}if(a){var U=i;if(!qe(i))try{U=JSON.parse(i)}catch{}return{key:e,enabled:!!n,variant:typeof n=="string"?n:void 0,payload:U}}}}else qa.warn('getFeatureFlagResult for key "'+e+L0)}getRemoteConfigPayload(e,t){var o=this.Bt.token,a={distinct_id:this._instance.get_distinct_id(),token:o};this.cs()&&(a.evaluation_contexts=this.hs()),this._instance._send_request({method:"POST",url:this._instance.requestRouter.endpointFor("flags","/flags/?v=2"),data:a,compression:this.Bt.disable_compression?void 0:Lr.Base64,timeout:this.Bt.feature_flag_request_timeout_ms,callback(n){var i,l=(i=n.json)==null?void 0:i.featureFlagPayloads;t(l?.[e]||void 0)}})}isFeatureEnabled(e,t){if(t===void 0&&(t={}),!t.fresh||this.rs){if(this.Kn||this.getFlags()&&this.getFlags().length>0){var o=this.getFeatureFlag(e,t);return qe(o)?void 0:!!o}qa.warn('isFeatureEnabled for key "'+e+L0)}}addFeatureFlagsHandler(e){this.featureFlagEventHandlers.push(e)}removeFeatureFlagsHandler(e){this.featureFlagEventHandlers=this.featureFlagEventHandlers.filter((t=>t!==e))}receivedFeatureFlags(e,t,o){if(this.ni){this.Kn=!0;var a=this.getFlagVariants(),n=this.getFlagPayloads(),i=this.getFlagsWithDetails();(function(l,c,u,p,m,h){u===void 0&&(u={}),p===void 0&&(p={}),m===void 0&&(m={});var f=(O=>{var L=O.flags;return L?(O.featureFlags=Object.fromEntries(Object.keys(L).map(($=>{var B;return[$,(B=L[$].variant)!==null&&B!==void 0?B:L[$].enabled]}))),O.featureFlagPayloads=Object.fromEntries(Object.keys(L).filter(($=>L[$].enabled)).filter(($=>{var B;return(B=L[$].metadata)==null?void 0:B.payload})).map(($=>{var B;return[$,(B=L[$].metadata)==null?void 0:B.payload]})))):qa.warn("Using an older version of the feature flags endpoint. Please upgrade your PostHog server to the latest version"),O})(l),v=f.flags,b=f.featureFlags,S=f.featureFlagPayloads;if(b){var _=l.requestId,T=l.evaluatedAt;if(It(b)){qa.warn("v1 of the feature flags endpoint is deprecated. Please use the latest version.");var x={};if(b)for(var P=0;b.length>P;P++)x[b[P]]=!0;c&&c.register({[af]:b,[ed]:x})}else{var C=b,E=S,R=v;if(h!=null&&h.partialResponse)C=Me({},u,C),E=Me({},p,E),R=Me({},m,R);else if(l.errorsWhileComputingFlags)if(v){var D=new Set(Object.keys(v).filter((O=>{var L;return!((L=v[O])!=null&&L.failed)})));C=Me({},u,Object.fromEntries(Object.entries(C).filter((O=>{var[L]=O;return D.has(L)})))),E=Me({},p,Object.fromEntries(Object.entries(E||{}).filter((O=>{var[L]=O;return D.has(L)})))),R=Me({},m,Object.fromEntries(Object.entries(R||{}).filter((O=>{var[L]=O;return D.has(L)}))))}else C=Me({},u,C),E=Me({},p,E),R=Me({},m,R);c&&c.register(Me({[af]:Object.keys(GO(C)),[ed]:C||{},[PT]:E||{},[ET]:R||{}},_?{[AT]:_}:{},T?{[qf]:T}:{}))}}})(e,this.ni,a,n,i,o),t||(this.ss=!1),this.ps(t)}}override(e,t){t===void 0&&(t=!1),qa.warn("override is deprecated. Please use overrideFeatureFlags instead."),this.overrideFeatureFlags({flags:e,suppressWarning:t})}overrideFeatureFlags(e){if(!this._instance.__loaded||!this.ni)return qa.uninitializedWarning("posthog.featureFlags.overrideFeatureFlags");if(e===!1)return this.ni.unregister(xi),this.ni.unregister(Wc),this.ps(),pl.info("All overrides cleared");if(It(e)){var t=HO(e);return this.ni.register({[xi]:t}),this.ps(),pl.info("Flag overrides set",{flags:e})}if(e&&typeof e=="object"&&("flags"in e||"payloads"in e)){var o,a=e;if(this.Jn=!!((o=a.suppressWarning)!==null&&o!==void 0&&o),"flags"in a){if(a.flags===!1)this.ni.unregister(xi),pl.info("Flag overrides cleared");else if(a.flags){if(It(a.flags)){var n=HO(a.flags);this.ni.register({[xi]:n})}else this.ni.register({[xi]:a.flags});pl.info("Flag overrides set",{flags:a.flags})}}return"payloads"in a&&(a.payloads===!1?(this.ni.unregister(Wc),pl.info("Payload overrides cleared")):a.payloads&&(this.ni.register({[Wc]:a.payloads}),pl.info("Payload overrides set",{payloads:a.payloads}))),void this.ps()}if(e&&typeof e=="object")return this.ni.register({[xi]:e}),this.ps(),pl.info("Flag overrides set",{flags:e});qa.warn("Invalid overrideOptions provided to overrideFeatureFlags",{overrideOptions:e})}onFeatureFlags(e){if(this.addFeatureFlagsHandler(e),this.Kn){var{flags:t,flagVariants:o}=this.gs();e(t,o)}return()=>this.removeFeatureFlagsHandler(e)}updateEarlyAccessFeatureEnrollment(e,t,o){var a,n=(this.os(ap)||[]).find((u=>u.flagKey===e)),i={["$feature_enrollment/"+e]:t},l={$feature_flag:e,$feature_enrollment:t,$set:i};n&&(l.$early_access_feature_name=n.name),o&&(l.$feature_enrollment_stage=o),this._instance.capture("$feature_enrollment_update",l),this.setPersonPropertiesForFlags(i,!1);var c=Me({},this.getFlagVariants(),{[e]:t});(a=this.ni)==null||a.register({[af]:Object.keys(GO(c)),[ed]:c}),this.ps()}getEarlyAccessFeatures(e,t,o){t===void 0&&(t=!1);var a=this.os(ap),n=o?"&"+o.map((i=>"stage="+i)).join("&"):"";if(a&&!t)return e(a);this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/early_access_features/?token="+this.Bt.token+n),method:"GET",callback:i=>{var l,c;if(i.json){var u=i.json.earlyAccessFeatures;return(l=this.ni)==null||l.unregister(ap),(c=this.ni)==null||c.register({[ap]:u}),e(u)}}})}gs(){var e=this.getFlags(),t=this.getFlagVariants();return{flags:e.filter((o=>t[o])),flagVariants:Object.keys(t).filter((o=>t[o])).reduce(((o,a)=>(o[a]=t[a],o)),{})}}ps(e){var{flags:t,flagVariants:o}=this.gs();this.featureFlagEventHandlers.forEach((a=>a(t,o,{errorsLoading:e})))}setPersonPropertiesForFlags(e,t){t===void 0&&(t=!0);var o=this.os(np)||{},a=e?.$set||(e!=null&&e.$set_once?{}:e),n=e?.$set_once,i={};if(n)for(var l in n)({}).hasOwnProperty.call(n,l)&&(l in o||(i[l]=n[l]));this._instance.register({[np]:Me({},o,i,a)}),t&&this._instance.reloadFeatureFlags()}resetPersonPropertiesForFlags(){this._instance.unregister(np)}setGroupPropertiesForFlags(e,t){t===void 0&&(t=!0);var o=this.os(fl)||{};Object.keys(o).length!==0&&Object.keys(o).forEach((a=>{o[a]=Me({},o[a],e[a]),delete e[a]})),this._instance.register({[fl]:Me({},o,e)}),t&&this._instance.reloadFeatureFlags()}resetGroupPropertiesForFlags(e){if(e){var t=this.os(fl)||{};this._instance.register({[fl]:Me({},t,{[e]:{}})})}else this._instance.unregister(fl)}reset(){this.Kn=!1,this.Qn=!1,this.es=!1,this.ts=!1,this.rs=!1,this.$anon_distinct_id=void 0,this.fs(),this.Jn=!1}}},Tie={sessionRecording:class{get Bt(){return this._instance.config}get ni(){return this._instance.persistence}get started(){var e;return!((e=this.ys)==null||!e.isStarted)}get status(){var e,t;return this.bs===qu||this.bs===jg?this.bs:(e=(t=this.ys)==null?void 0:t.status)!==null&&e!==void 0?e:this.bs}constructor(e){if(this._forceAllowLocalhostNetworkCapture=!1,this.bs=BO,this._s=void 0,this._instance=e,!this._instance.sessionManager)throw ms.error("started without valid sessionManager"),new Error(YT+" started without valid sessionManager. This is a bug.");if(this.Bt.cookieless_mode===ki)throw new Error(YT+' cannot be used with cookieless_mode="always"')}initialize(){this.startIfEnabledOrStop()}get ws(){var e,t=!((e=this._instance.get_property(op))==null||!e.enabled),o=!this.Bt.disable_session_recording,a=this.Bt.disable_session_recording||this._instance.consent.isOptedOut();return ge&&t&&o&&!a}startIfEnabledOrStop(e){var t;if(!this.ws||(t=this.ys)==null||!t.isStarted){var o=!qe(Object.assign)&&!qe(Array.from);this.ws&&o?(this.Is(e),ms.info("starting")):(this.bs=BO,this.stopRecording())}}Is(e){var t,o,a;this.ws&&(this.bs!==qu&&this.bs!==jg&&(this.bs=FO),et!=null&&(t=et.__PosthogExtensions__)!=null&&(t=t.rrweb)!=null&&t.record&&(o=et.__PosthogExtensions__)!=null&&o.initSessionRecording?this.Cs(e):(a=et.__PosthogExtensions__)==null||a.loadExternalDependency==null||a.loadExternalDependency(this._instance,this.Ss,(n=>{if(n)return ms.error("could not load recorder",n);this.Cs(e)})))}stopRecording(){var e,t;(e=this._s)==null||e.call(this),this._s=void 0,(t=this.ys)==null||t.stop()}xs(){var e,t;(e=this._s)==null||e.call(this),this._s=void 0,(t=this.ys)==null||t.discard()}ks(){var e;(e=this.ni)==null||e.unregister(H_)}Ts(e,t){if(Ct(e))return null;var o,a=Xn(e)?e:parseFloat(e);return typeof(o=a)!="number"||!Number.isFinite(o)||0>o||o>1?(ms.warn(t+" must be between 0 and 1. Ignoring invalid value:",e),null):a}As(e){if(this.ni){var t,o,a=this.ni,n=()=>{var i,l=e.sessionRecording===!1?void 0:e.sessionRecording,c=this.Ts((i=this.Bt.session_recording)==null?void 0:i.sampleRate,"session_recording.sampleRate"),u=this.Ts(l?.sampleRate,"remote config sampleRate"),p=c??u;Ct(p)&&this.ks();var m=l?.minimumDurationMilliseconds;a.register({[op]:Me({cache_timestamp:Date.now(),enabled:!!l},l,{networkPayloadCapture:Me({capturePerformance:e.capturePerformance},l?.networkPayloadCapture),canvasRecording:{enabled:l?.recordCanvas,fps:l?.canvasFps,quality:l?.canvasQuality},sampleRate:p,minimumDurationMilliseconds:qe(m)?null:m,endpoint:l?.endpoint,triggerMatchType:l?.triggerMatchType,masking:l?.masking,urlTriggers:l?.urlTriggers,version:l?.version,triggerGroups:l?.triggerGroups})})};n(),(t=this._s)==null||t.call(this),this._s=(o=this._instance.sessionManager)==null?void 0:o.onSessionId(n)}}onRemoteConfig(e){return"sessionRecording"in e?e.sessionRecording===!1?(this.As(e),void this.xs()):(this.As(e),void this.startIfEnabledOrStop()):(this.bs===qu&&(this.bs=jg,ms.warn("config refresh failed, recording will not start until page reload")),void this.startIfEnabledOrStop())}log(e,t){var o;t===void 0&&(t="log"),(o=this.ys)!=null&&o.log?this.ys.log(e,t):ms.warn("log called before recorder was ready")}get Ss(){var e,t,o=(e=this._instance)==null||(e=e.persistence)==null?void 0:e.get_property(op);return(o==null||(t=o.scriptConfig)==null?void 0:t.script)||"lazy-recorder"}Es(){var e,t=this._instance.get_property(op);if(!t)return!1;var o=(e=(typeof t=="object"?t:JSON.parse(t)).cache_timestamp)!==null&&e!==void 0?e:Date.now();return 36e5>=Date.now()-o}Cs(e){var t,o;if((t=et.__PosthogExtensions__)==null||!t.initSessionRecording)return ms.warn("Called on script loaded before session recording is available. This can be caused by adblockers."),void this._instance.register_for_session({[bj]:!0});if(this.ys||(this.ys=(o=et.__PosthogExtensions__)==null?void 0:o.initSessionRecording(this._instance),this.ys._forceAllowLocalhostNetworkCapture=this._forceAllowLocalhostNetworkCapture),!this.Es())return this.bs===jg||this.bs===qu?void 0:(this.bs=qu,ms.info("persisted remote config is stale, requesting fresh config before starting"),void new Rj(this._instance).load());this.bs=FO,this.ys.start(e)}onRRwebEmit(e){var t;(t=this.ys)==null||t.onRRwebEmit==null||t.onRRwebEmit(e)}overrideLinkedFlag(){var e,t;this.ys||(t=this.ni)==null||t.register({[pj]:!0}),(e=this.ys)==null||e.overrideLinkedFlag()}overrideSampling(){var e,t;this.ys||(t=this.ni)==null||t.register({[uj]:!0}),(e=this.ys)==null||e.overrideSampling()}overrideTrigger(e){var t,o;this.ys||(o=this.ni)==null||o.register({[e==="url"?mj:hj]:!0}),(t=this.ys)==null||t.overrideTrigger(e)}get sdkDebugProperties(){var e;return((e=this.ys)==null?void 0:e.sdkDebugProperties)||{$recording_status:this.status}}tryAddCustomEvent(e,t){var o;return!((o=this.ys)==null||!o.tryAddCustomEvent(e,t))}}},xie={autocapture:class{constructor(e){this.Rs=!1,this.Ns=null,this.Ms=!1,this.instance=e,this.rageclicks=new MO(e.config.rageclick),this.Fs=null}initialize(){this.startIfEnabled()}get Bt(){var e,t,o=Bo(this.instance.config.autocapture)?this.instance.config.autocapture:{};return o.url_allowlist=(e=o.url_allowlist)==null?void 0:e.map((a=>new RegExp(a))),o.url_ignorelist=(t=o.url_ignorelist)==null?void 0:t.map((a=>new RegExp(a))),o}Os(){if(this.isBrowserSupported()){if(ge&&ze){var e=o=>{o=o||ge?.event;try{this.Ps(o)}catch(a){NO.error("Failed to capture event",a)}};if(Zo(ze,"submit",e,{capture:!0}),Zo(ze,"change",e,{capture:!0}),Zo(ze,"click",e,{capture:!0}),this.Bt.capture_copied_text){var t=o=>{this.Ps(o=o||ge?.event,M0)};Zo(ze,"copy",t,{capture:!0}),Zo(ze,"cut",t,{capture:!0})}}}else NO.info("Disabling Automatic Event Collection because this browser is not supported")}startIfEnabled(){this.isEnabled&&!this.Rs&&(this.Os(),this.Rs=!0)}onRemoteConfig(e){e.elementsChainAsString&&(this.Ms=e.elementsChainAsString),this.instance.persistence&&this.instance.persistence.register({[yT]:!!e.autocapture_opt_out}),this.Ns=!!e.autocapture_opt_out,this.startIfEnabled()}setElementSelectors(e){this.Fs=e}getElementSelectors(e){var t,o=[];return(t=this.Fs)==null||t.forEach((a=>{var n=ze?.querySelectorAll(a);n?.forEach((i=>{e===i&&o.push(a)}))})),o}get isEnabled(){var e,t,o=(e=this.instance.persistence)==null?void 0:e.props[yT];if(Ii(this.Ns)&&!$r(o)&&!this.instance.Fr())return!1;var a=(t=this.Ns)!==null&&t!==void 0?t:!!o;return!!this.instance.config.autocapture&&!a}Ps(e,t){if(t===void 0&&(t="$autocapture"),this.isEnabled){var o,a=EO(e);$j(a)&&(a=a.parentNode||null),t==="$autocapture"&&e.type==="click"&&e instanceof MouseEvent&&this.instance.config.rageclick&&(o=this.rageclicks)!=null&&o.isRageClick(e.clientX,e.clientY,e.timeStamp||new Date().getTime())&&(function(h,f){if(!ge||WT(h))return!1;var v,b,S;if($r(f)?(v=!!f&&AO,b=void 0):(v=(S=f?.css_selector_ignorelist)!==null&&S!==void 0?S:AO,b=f?.content_ignorelist),v===!1)return!1;var{targetElementList:_}=RO(h,!1);return!(function(T,x){if(T===!1||qe(T))return!1;var P;if(T===!0)P=iie;else{if(!It(T))return!1;if(T.length>10)return Ue.error("[PostHog] content_ignorelist array cannot exceed 10 items. Use css_selector_ignorelist for more complex matching."),!1;P=T.map((C=>C.toLowerCase()))}return x.some((C=>{var{safeText:E,ariaLabel:R}=C;return P.some((D=>E.includes(D)||R.includes(D)))}))})(b,_.map((T=>{var x;return{safeText:Ip(T).toLowerCase(),ariaLabel:((x=T.getAttribute("aria-label"))==null?void 0:x.toLowerCase().trim())||""}})))&&!PO(_,v)})(a,this.instance.config.rageclick)&&this.Ps(e,"$rageclick");var n=t===M0;if(a&&(function(h,f,v,b,S){var _,T,x,P;if(v===void 0&&(v=void 0),!ge||WT(h)||(_=v)!=null&&_.url_allowlist&&!CO(v.url_allowlist)||(T=v)!=null&&T.url_ignorelist&&CO(v.url_ignorelist))return!1;if((x=v)!=null&&x.dom_event_allowlist){var C=v.dom_event_allowlist;if(C&&!C.some((L=>f.type===L)))return!1}var{parentIsUsefulElement:E,targetElementList:R}=RO(h,b);if(!(function(L,$){var B=$?.element_allowlist;if(qe(B))return!0;var U,j=function(ne){if(B.some((H=>ne.tagName.toLowerCase()===H)))return{v:!0}};for(var W of L)if(U=j(W))return U.v;return!1})(R,v)||!PO(R,(P=v)==null?void 0:P.css_selector_allowlist))return!1;var D=ge.getComputedStyle(h);if(D&&D.getPropertyValue("cursor")==="pointer"&&f.type==="click")return!0;var O=h.tagName.toLowerCase();switch(O){case"html":return!1;case"form":return(S||["submit"]).indexOf(f.type)>=0;case"input":case"select":case"textarea":return(S||["change","click"]).indexOf(f.type)>=0;default:return E?(S||["click"]).indexOf(f.type)>=0:(S||["click"]).indexOf(f.type)>=0&&(J_.indexOf(O)>-1||h.getAttribute("contenteditable")==="true")}})(a,e,this.Bt,n,n?["copy","cut"]:void 0)){var{props:i,explicitNoCapture:l}=mie(a,{e,maskAllElementAttributes:this.instance.config.mask_all_element_attributes,maskAllText:this.instance.config.mask_all_text,elementAttributeIgnoreList:this.Bt.element_attribute_ignorelist,elementsChainAsString:this.Ms});if(l)return!1;var c=this.getElementSelectors(a);if(c&&c.length>0&&(i.$element_selectors=c),t===M0){var u,p=Vj(ge==null||(u=ge.getSelection())==null?void 0:u.toString()),m=e.type||"clipboard";if(!p)return!1;i.$selected_content=p,i.$copy_type=m}return this.instance.capture(t,i),!0}}}isBrowserSupported(){return _i(ze?.querySelectorAll)}},historyAutocapture:class{constructor(e){var t;this._instance=e,this.Ls=(ge==null||(t=ge.location)==null?void 0:t.pathname)||""}initialize(){this.startIfEnabled()}get isEnabled(){return this._instance.config.capture_pageview==="history_change"}startIfEnabled(){this.isEnabled&&(Ue.info("History API monitoring enabled, starting..."),this.monitorHistoryChanges())}stop(){this.Ds&&this.Ds(),this.Ds=void 0,Ue.info("History API monitoring stopped")}monitorHistoryChanges(){var e,t;if(ge&&ge.history){var o=this;(e=ge.history.pushState)!=null&&e.__posthog_wrapped__||IO(ge.history,"pushState",(a=>function(n,i,l){a.call(this,n,i,l),o.Bs("pushState")})),(t=ge.history.replaceState)!=null&&t.__posthog_wrapped__||IO(ge.history,"replaceState",(a=>function(n,i,l){a.call(this,n,i,l),o.Bs("replaceState")})),this.js()}}Bs(e){try{var t,o=ge==null||(t=ge.location)==null?void 0:t.pathname;if(!o)return;o!==this.Ls&&this.isEnabled&&this._instance.capture(Kc,{navigation_type:e}),this.Ls=o}catch(a){Ue.error("Error capturing "+e+" pageview",a)}}js(){if(!this.Ds){var e=()=>{this.Bs("popstate")};Zo(ge,"popstate",e),this.Ds=()=>{ge&&ge.removeEventListener("popstate",e)}}}},heatmaps:class{get Bt(){return this.instance.config}constructor(e){var t;this.$s=!1,this.Rs=!1,this.qs=null,this.instance=e,this.$s=!((t=this.instance.persistence)==null||!t.props[ST]),this.rageclicks=new MO(e.config.rageclick)}initialize(){this.startIfEnabled()}get flushIntervalMilliseconds(){var e=5e3;return Bo(this.Bt.capture_heatmaps)&&this.Bt.capture_heatmaps.flush_interval_milliseconds&&(e=this.Bt.capture_heatmaps.flush_interval_milliseconds),e}get isEnabled(){return Ct(this.Bt.capture_heatmaps)?Ct(this.Bt.enable_heatmaps)?this.$s:this.Bt.enable_heatmaps:this.Bt.capture_heatmaps!==!1}startIfEnabled(){if(this.isEnabled){if(this.Rs)return;gie.info("starting..."),this.Zs(),this.Ft()}else{var e;clearInterval((e=this.qs)!==null&&e!==void 0?e:void 0),this.Vs(),this.getAndClearBuffer()}}onRemoteConfig(e){if("heatmaps"in e){var t=!!e.heatmaps;this.instance.persistence&&this.instance.persistence.register({[ST]:t}),this.$s=t,this.startIfEnabled()}}getAndClearBuffer(){var e=this.T;return this.T=void 0,e}Hs(e){this.Tt(e.originalEvent,"deadclick")}Ft(){this.qs&&clearInterval(this.qs),this.qs=ze?.visibilityState==="visible"?setInterval(this.Yr.bind(this),this.flushIntervalMilliseconds):null}Zs(){ge&&ze&&(this.zs=this.Yr.bind(this),Zo(ge,Wf,this.zs),this.Us=e=>this.Tt(e||ge?.event),Zo(ze,"click",this.Us,{capture:!0}),this.Ys=e=>this.Gs(e||ge?.event),Zo(ze,"mousemove",this.Ys,{capture:!0}),this.Ws=new iO(this.instance,Pre,this.Hs.bind(this)),this.Ws.startIfEnabledOrStop(),this.Xs=this.Ft.bind(this),Zo(ze,Gf,this.Xs),this.Rs=!0)}Vs(){var e;ge&&ze&&(this.zs&&ge.removeEventListener(Wf,this.zs),this.Us&&ze.removeEventListener("click",this.Us,{capture:!0}),this.Ys&&ze.removeEventListener("mousemove",this.Ys,{capture:!0}),this.Xs&&ze.removeEventListener(Gf,this.Xs),clearTimeout(this.Js),(e=this.Ws)==null||e.stop(),this.Rs=!1)}Ks(e,t){var o=this.instance.scrollManager.scrollY(),a=this.instance.scrollManager.scrollX(),n=this.instance.scrollManager.scrollElement(),i=(function(l,c,u){for(var p=l;p&&Vv(p)&&!Ds(p,"body");){if(p===u)return!1;if(kt(c,ge?.getComputedStyle(p).position))return!0;p=Hj(p)}return!1})(EO(e),["fixed","sticky"],n);return{x:e.clientX+(i?0:a),y:e.clientY+(i?0:o),target_fixed:i,type:t}}Tt(e,t){var o;if(t===void 0&&(t="click"),!kO(e.target)&&jO(e)){var a=this.Ks(e,t);(o=this.rageclicks)!=null&&o.isRageClick(e.clientX,e.clientY,new Date().getTime())&&this.Qs(Me({},a,{type:"rageclick"})),this.Qs(a)}}Gs(e){!kO(e.target)&&jO(e)&&(clearTimeout(this.Js),this.Js=setTimeout((()=>{this.Qs(this.Ks(e,"mousemove"))}),500))}Qs(e){if(ge){var t=ge.location.href,o=this.Bt.custom_personal_data_properties,a=this.Bt.mask_personal_data_properties?[..._d,...o||[]]:[],n=Mp(t,a,Np);this.T=this.T||{},this.T[n]||(this.T[n]=[]),this.T[n].push(e)}}Yr(){this.T&&!Xc(this.T)&&this.instance.capture("$$heatmap",{$heatmap_data:this.getAndClearBuffer()})}},deadClicksAutocapture:iO,webVitalsAutocapture:class{constructor(e){var t;this.$s=!1,this.Rs=!1,this.T={url:void 0,metrics:[],firstMetricTimestamp:void 0},this.eo=()=>{clearTimeout(this.ro),this.T.metrics.length!==0&&(this._instance.capture("$web_vitals",this.T.metrics.reduce(((o,a)=>Me({},o,{["$web_vitals_"+a.name+"_event"]:Me({},a),["$web_vitals_"+a.name+"_value"]:a.value})),{})),this.T={url:void 0,metrics:[],firstMetricTimestamp:void 0})},this.ht=o=>{var a,n=(a=this._instance.sessionManager)==null?void 0:a.checkAndGetSessionAndWindowId(!0);if(qe(n))ps.error("Could not read session ID. Dropping metrics!");else{this.T=this.T||{url:void 0,metrics:[],firstMetricTimestamp:void 0};var i=this.io();qe(i)||(Ct(o?.name)||Ct(o?.value)?ps.error("Invalid metric received",o):!this.no||this.no>o.value?(this.T.url!==i&&(this.eo(),this.ro=setTimeout(this.eo,this.flushToCaptureTimeoutMs)),qe(this.T.url)&&(this.T.url=i),this.T.firstMetricTimestamp=qe(this.T.firstMetricTimestamp)?Date.now():this.T.firstMetricTimestamp,o.attribution&&o.attribution.interactionTargetElement&&(o.attribution.interactionTargetElement=void 0),this.T.metrics.push(Me({},o,{$current_url:i,$session_id:n.sessionId,$window_id:n.windowId,timestamp:Date.now()})),this.T.metrics.length===this.allowedMetrics.length&&this.eo()):ps.error("Ignoring metric with value >= "+this.no,o))}},this.so=()=>{if(!this.Rs){var o,a,n,i,l=et.__PosthogExtensions__;qe(l)||qe(l.postHogWebVitalsCallbacks)||({onLCP:o,onCLS:a,onFCP:n,onINP:i}=l.postHogWebVitalsCallbacks),o&&a&&n&&i?(this.allowedMetrics.indexOf("LCP")>-1&&o(this.ht.bind(this)),this.allowedMetrics.indexOf("CLS")>-1&&a(this.ht.bind(this)),this.allowedMetrics.indexOf("FCP")>-1&&n(this.ht.bind(this)),this.allowedMetrics.indexOf("INP")>-1&&i(this.ht.bind(this)),this.Rs=!0):ps.error("web vitals callbacks not loaded - not starting")}},this._instance=e,this.$s=!((t=this._instance.persistence)==null||!t.props[_T]),this.startIfEnabled()}get oo(){return this._instance.config.capture_performance}get allowedMetrics(){var e,t,o=Bo(this.oo)?(e=this.oo)==null?void 0:e.web_vitals_allowed_metrics:void 0;return Ct(o)?((t=this._instance.persistence)==null?void 0:t.props[CT])||["CLS","FCP","INP","LCP"]:o}get flushToCaptureTimeoutMs(){return(Bo(this.oo)?this.oo.web_vitals_delayed_flush_ms:void 0)||5e3}get useAttribution(){var e=Bo(this.oo)?this.oo.web_vitals_attribution:void 0;return e!=null&&e}get no(){var e=Bo(this.oo)&&Xn(this.oo.__web_vitals_max_value)?this.oo.__web_vitals_max_value:LO;return e>0&&6e4>=e?LO:e}get isEnabled(){var e=wa?.protocol;if(e!=="http:"&&e!=="https:")return ps.info("Web Vitals are disabled on non-http/https protocols"),!1;var t=Bo(this.oo)?this.oo.web_vitals:$r(this.oo)?this.oo:void 0;return $r(t)?t:this.$s}startIfEnabled(){this.isEnabled&&!this.Rs&&(ps.info("enabled, starting..."),this.ur(this.so))}onRemoteConfig(e){if("capturePerformance"in e){var t=Bo(e.capturePerformance)&&!!e.capturePerformance.web_vitals,o=Bo(e.capturePerformance)?e.capturePerformance.web_vitals_allowed_metrics:void 0;this._instance.persistence&&(this._instance.persistence.register({[_T]:t}),this._instance.persistence.register({[CT]:o})),this.$s=t,this.startIfEnabled()}}ur(e){var t,o;(t=et.__PosthogExtensions__)!=null&&t.postHogWebVitalsCallbacks?e():(o=et.__PosthogExtensions__)==null||o.loadExternalDependency==null||o.loadExternalDependency(this._instance,this.useAttribution?"web-vitals-with-attribution":"web-vitals",(a=>{a?ps.error("failed to load script",a):e()}))}io(){var e=ge?ge.location.href:void 0;if(e){var t=this._instance.config.custom_personal_data_properties,o=this._instance.config.mask_personal_data_properties?[..._d,...t||[]]:[];return Mp(e,o,Np)}ps.error("Could not determine current URL")}}},_ie={exceptionObserver:class{constructor(e){var t,o,a;this.so=()=>{var n;if(ge&&this.isEnabled&&(n=et.__PosthogExtensions__)!=null&&n.errorWrappingFunctions){var i=et.__PosthogExtensions__.errorWrappingFunctions.wrapOnError,l=et.__PosthogExtensions__.errorWrappingFunctions.wrapUnhandledRejection,c=et.__PosthogExtensions__.errorWrappingFunctions.wrapConsoleError;try{!this.ao&&this.Bt.capture_unhandled_errors&&(this.ao=i(this.captureException.bind(this))),!this.lo&&this.Bt.capture_unhandled_rejections&&(this.lo=l(this.captureException.bind(this))),!this.uo&&this.Bt.capture_console_errors&&(this.uo=c(this.captureException.bind(this)))}catch(u){$u.error("failed to start",u),this.ho()}}},this._instance=e,this.co=!((t=this._instance.persistence)==null||!t.props[wT]),this.do=new Bne({refillRate:(o=this._instance.config.error_tracking.__exceptionRateLimiterRefillRate)!==null&&o!==void 0?o:1,bucketSize:(a=this._instance.config.error_tracking.__exceptionRateLimiterBucketSize)!==null&&a!==void 0?a:10,refillInterval:1e4,Gt:$u}),this.Bt=this.vo(),this.startIfEnabledOrStop()}vo(){var e=this._instance.config.capture_exceptions,t={capture_unhandled_errors:!1,capture_unhandled_rejections:!1,capture_console_errors:!1};return Bo(e)?t=Me({},t,e):(qe(e)?this.co:e)&&(t=Me({},t,{capture_unhandled_errors:!0,capture_unhandled_rejections:!0})),t}get isEnabled(){return this.Bt.capture_console_errors||this.Bt.capture_unhandled_errors||this.Bt.capture_unhandled_rejections}startIfEnabledOrStop(){this.isEnabled?($u.info("enabled"),this.ho(),this.ur(this.so)):this.ho()}ur(e){var t,o;(t=et.__PosthogExtensions__)!=null&&t.errorWrappingFunctions&&e(),(o=et.__PosthogExtensions__)==null||o.loadExternalDependency==null||o.loadExternalDependency(this._instance,"exception-autocapture",(a=>{if(a)return $u.error("failed to load script",a);e()}))}ho(){var e,t,o;(e=this.ao)==null||e.call(this),this.ao=void 0,(t=this.lo)==null||t.call(this),this.lo=void 0,(o=this.uo)==null||o.call(this),this.uo=void 0}onRemoteConfig(e){"autocaptureExceptions"in e&&(this.co=!!e.autocaptureExceptions||!1,this._instance.persistence&&this._instance.persistence.register({[wT]:this.co}),this.Bt=this.vo(),this.startIfEnabledOrStop())}onConfigChange(){this.Bt=this.vo()}captureException(e){var t,o,a,n=(t=e==null||(o=e.$exception_list)==null||(o=o[0])==null?void 0:o.type)!==null&&t!==void 0?t:"Exception";this.do.consumeRateLimit(n)?$u.info("Skipping exception capture because of client rate limiting.",{exception:n}):(a=this._instance.exceptions)==null||a.sendExceptionEvent(e)}},exceptions:class{constructor(e){var t,o;this.fo=[],this.po=new Zne([new nre,new mre,new ire,new rre,new ure,new dre,new lre,new pre],(function(a){for(var n=arguments.length,i=new Array(n>1?n-1:0),l=1;n>l;l++)i[l-1]=arguments[l];return function(c,u){u===void 0&&(u=0);for(var p=[],m=c.split(`
168
- `),h=u;m.length>h;h++){var f=m[h];if(1024>=f.length){var v=oO.test(f)?f.replace(oO,"$1"):f;if(!v.match(/\S*Error: /)){for(var b of i){var S=b(v,a);if(S){p.push(S);break}}if(p.length>=50)break}}}return(function(_){if(!_.length)return[];var T=Array.from(_);return T.reverse(),T.slice(0,50).map((x=>{return Me({},x,{filename:x.filename||(P=T,P[P.length-1]||{}).filename,function:x.function||xd});var P}))})(p)}})("web:javascript",ere,are)),this._instance=e,this.fo=(t=(o=this._instance.persistence)==null?void 0:o.get_property(TT))!==null&&t!==void 0?t:[],this.mo=zf(this.yo()),this.bo=new gre(this.mo)}onConfigChange(){this.mo=zf(this.yo()),this.bo.setConfig(this.mo)}onRemoteConfig(e){var t,o,a;if("errorTracking"in e){var n=(t=(o=e.errorTracking)==null?void 0:o.suppressionRules)!==null&&t!==void 0?t:[],i=(a=e.errorTracking)==null?void 0:a.captureExtensionExceptions;this.fo=n,this._instance.persistence&&this._instance.persistence.register({[TT]:this.fo,[xT]:i})}}get _o(){var e,t=!!this._instance.get_property(xT),o=this._instance.config.error_tracking.captureExtensionExceptions;return(e=o??t)!==null&&e!==void 0&&e}buildProperties(e,t){return this.po.buildFromUnknown(e,{syntheticException:t?.syntheticException,mechanism:{handled:t?.handled}})}addExceptionStep(e,t){if(this.mo.enabled)try{if(!ko(e)||e.trim().length===0)return void Ti.warn("Ignoring exception step because message must be a non-empty string");var o=this.wo(t),{sanitizedProperties:a,droppedKeys:n}=(function(i){if(!i)return{sanitizedProperties:{},droppedKeys:[]};var l=[];return{sanitizedProperties:Object.keys(i).reduce(((c,u)=>hre.has(u)?(l.push(u),c):(c[u]=i[u],c)),{}),droppedKeys:l}})(o);n.length>0&&Ti.warn("Ignoring reserved exception step fields",{droppedKeys:n}),this.bo.add(Me({[Ff]:e,[jf]:new Date().toISOString()},a))}catch(i){Ti.error("Failed to add exception step. Ignoring breadcrumb.",i)}}sendExceptionEvent(e){try{var t=e.$exception_list;if(this.Io(t)){if(this.Co(t))return this.So("Exception dropped: matched a suppression rule"),void Ti.info("Skipping exception capture because a suppression rule matched");if(!this._o&&this.xo(t))return this.So("Exception dropped: thrown by a browser extension"),void Ti.info("Skipping exception capture because it was thrown by an extension");if(!this._instance.config.error_tracking.__capturePostHogExceptions&&this.ko(t))return this.So("Exception dropped: thrown by the PostHog SDK"),void Ti.info("Skipping exception capture because it was thrown by the PostHog SDK")}var o=this.mo.enabled&&Ct(e.$exception_steps)?this.To(e):e;try{var a=this._instance.capture("$exception",o,{_noTruncate:!0,_batchKey:"exceptionEvent",en:!0});return a&&this.bo.clear(),a}catch(n){return Ti.error("Failed to capture exception event. Dropping this exception.",n),void this.bo.clear()}}catch(n){return void Ti.error("Failed to process exception event. Ignoring this exception.",n)}}To(e){try{var t=this.bo.getAttachable();return t.length===0?e:Me({},e,{$exception_steps:t})}catch(o){return Ti.error("Failed to read buffered exception steps. Capturing exception without steps.",o),e}}So(e){this.mo.enabled&&this.bo.add({[Ff]:e,[jf]:new Date().toISOString()})}wo(e){return Bo(e)?Me({},e):{}}yo(){var e,t;return(e=(t=this._instance.config.error_tracking)==null?void 0:t.exception_steps)!==null&&e!==void 0?e:{}}Co(e){if(e.length===0)return!1;var t=e.reduce(((o,a)=>{var{type:n,value:i}=a;return ko(n)&&n.length>0&&o.$exception_types.push(n),ko(i)&&i.length>0&&o.$exception_values.push(i),o}),{$exception_types:[],$exception_values:[]});return this.fo.some((o=>{var a=o.values.map((n=>{var i,l=Fj[n.operator],c=It(n.value)?n.value:[n.value],u=(i=t[n.key])!==null&&i!==void 0?i:[];return c.length>0&&l(c,u)}));return o.type==="OR"?a.some(Boolean):a.every(Boolean)}))}xo(e){return e.flatMap((t=>{var o,a;return(o=(a=t.stacktrace)==null?void 0:a.frames)!==null&&o!==void 0?o:[]})).some((t=>t.filename&&t.filename.startsWith("chrome-extension://")))}ko(e){if(e.length>0){var t,o,a,n,i=(t=(o=e[0].stacktrace)==null?void 0:o.frames)!==null&&t!==void 0?t:[],l=i[i.length-1];return(a=l==null||(n=l.filename)==null?void 0:n.includes("posthog.com/static"))!==null&&a!==void 0&&a}return!1}Io(e){return!Ct(e)&&It(e)}}},kie=Me({productTours:class{get ni(){return this._instance.persistence}constructor(e){this.Ao=null,this.Eo=null,this._instance=e}initialize(){this.loadIfEnabled()}onRemoteConfig(e){"productTours"in e&&(this.ni&&this.ni.register({[kT]:!!e.productTours}),this.loadIfEnabled())}loadIfEnabled(){var e,t;this.Ao||(e=this._instance).config.disable_product_tours||(t=e.persistence)==null||!t.get_property(kT)||this.ur((()=>this.Ro()))}ur(e){var t,o;(t=et.__PosthogExtensions__)!=null&&t.generateProductTours?e():(o=et.__PosthogExtensions__)==null||o.loadExternalDependency==null||o.loadExternalDependency(this._instance,"product-tours",(a=>{a?zO.error("Could not load product tours script",a):e()}))}Ro(){var e;!this.Ao&&(e=et.__PosthogExtensions__)!=null&&e.generateProductTours&&(this.Ao=et.__PosthogExtensions__.generateProductTours(this._instance,!0))}getProductTours(e,t){if(t===void 0&&(t=!1),!It(this.Eo)||t){var o=this.ni;if(o){var a=o.props[nf];if(It(a)&&!t)return this.Eo=a,void e(a,{isLoaded:!0})}this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/product_tours/?token="+this._instance.config.token),method:"GET",callback:n=>{var i=n.statusCode;if(i!==200||!n.json){var l="Product Tours API could not be loaded, status: "+i;return zO.error(l),void e([],{isLoaded:!1,error:l})}var c=It(n.json.product_tours)?n.json.product_tours:[];this.Eo=c,o&&o.register({[nf]:c}),e(c,{isLoaded:!0})}})}else e(this.Eo,{isLoaded:!0})}getActiveProductTours(e){Ct(this.Ao)?e([],{isLoaded:!1,error:"Product tours not loaded"}):this.Ao.getActiveProductTours(e)}showProductTour(e){var t;(t=this.Ao)==null||t.showTourById(e)}previewTour(e){this.Ao?this.Ao.previewTour(e):this.ur((()=>{var t;this.Ro(),(t=this.Ao)==null||t.previewTour(e)}))}dismissProductTour(){var e;(e=this.Ao)==null||e.dismissTour("user_clicked_skip")}nextStep(){var e;(e=this.Ao)==null||e.nextStep()}previousStep(){var e;(e=this.Ao)==null||e.previousStep()}clearCache(){var e;this.Eo=null,(e=this.ni)==null||e.unregister(nf)}resetTour(e){var t;(t=this.Ao)==null||t.resetTour(e)}resetAllTours(){var e;(e=this.Ao)==null||e.resetAllTours()}cancelPendingTour(e){var t;(t=this.Ao)==null||t.cancelPendingTour(e)}}},Hv),Cie={siteApps:class{constructor(e){this._instance=e,this.No=[],this.apps={}}get isEnabled(){return!!this._instance.config.opt_in_site_apps}Mo(e,t){if(t){var o=this.globalsForEvent(t);this.No.push(o),this.No.length>1e3&&(this.No=this.No.slice(10))}}get siteAppLoaders(){var e;return(e=et._POSTHOG_REMOTE_CONFIG)==null||(e=e[this._instance.config.token])==null?void 0:e.siteApps}initialize(){if(this.isEnabled){var e=this._instance._addCaptureHook(this.Mo.bind(this));this.Fo=()=>{e(),this.No=[],this.Fo=void 0}}}globalsForEvent(e){var t,o,a,n,i,l,c;if(!e)throw new Error("Event payload is required");var u={},p=this._instance.get_property("$groups")||[],m=this._instance.get_property("$stored_group_properties")||{};for(var[h,f]of Object.entries(m))u[h]={id:p[h],type:h,properties:f};var{$set_once:v,$set:b}=e;return{event:Me({},jF(e,fie),{properties:Me({},e.properties,b?{$set:Me({},(t=(o=e.properties)==null?void 0:o.$set)!==null&&t!==void 0?t:{},b)}:{},v?{$set_once:Me({},(a=(n=e.properties)==null?void 0:n.$set_once)!==null&&a!==void 0?a:{},v)}:{}),elements_chain:(i=(l=e.properties)==null?void 0:l.$elements_chain)!==null&&i!==void 0?i:"",distinct_id:(c=e.properties)==null?void 0:c.distinct_id}),person:{properties:this._instance.get_property("$stored_person_properties")},groups:u}}setupSiteApp(e){var t=this.apps[e.id],o=()=>{var l;!t.errored&&this.No.length&&(hs.info("Processing "+this.No.length+" events for site app with id "+e.id),this.No.forEach((c=>t.processEvent==null?void 0:t.processEvent(c))),t.processedBuffer=!0),Object.values(this.apps).every((c=>c.processedBuffer||c.errored))&&((l=this.Fo)==null||l.call(this))},a=!1,n=l=>{t.errored=!l,t.loaded=!0,hs.info("Site app with id "+e.id+" "+(l?"loaded":"errored")),a&&o()};try{var{processEvent:i}=e.init({posthog:this._instance,callback(l){n(l)}});i&&(t.processEvent=i),a=!0}catch(l){hs.error(UO+e.id,l),n(!1)}if(a&&t.loaded)try{o()}catch(l){hs.error("Error while processing buffered events PostHog app with config id "+e.id,l),t.errored=!0}}Oo(){var e=this.siteAppLoaders||[];for(var t of e)this.apps[t.id]={id:t.id,loaded:!1,errored:!1,processedBuffer:!1};for(var o of e)this.setupSiteApp(o)}Po(e){if(Object.keys(this.apps).length!==0){var t=this.globalsForEvent(e);for(var o of Object.values(this.apps))try{o.processEvent==null||o.processEvent(t)}catch(a){hs.error("Error while processing event "+e.event+" for site app "+o.id,a)}}}onRemoteConfig(e){var t,o,a,n=this;if((t=this.siteAppLoaders)!=null&&t.length)return this.isEnabled?(this.Oo(),void this._instance.on("eventCaptured",(u=>this.Po(u)))):void hs.error('PostHog site apps are disabled. Enable the "opt_in_site_apps" config to proceed.');if((o=this.Fo)==null||o.call(this),(a=e.siteApps)!=null&&a.length)if(this.isEnabled){var i=function(u){var p;et["__$$ph_site_app_"+u]=n._instance,(p=et.__PosthogExtensions__)==null||p.loadSiteApp==null||p.loadSiteApp(n._instance,c,(m=>{if(m)return hs.error(UO+u,m)}))};for(var{id:l,url:c}of e.siteApps)i(l)}else hs.error('PostHog site apps are disabled. Enable the "opt_in_site_apps" config to proceed.')}}},Eie={tracingHeaders:class{constructor(e){this.Lo=void 0,this.Do=void 0,this.so=()=>{var t,o,a=this.Bo()||[];qe(this.Lo)&&((t=et.__PosthogExtensions__)==null||(t=t.tracingHeadersPatchFns)==null||t._patchXHR(a,this._instance.get_distinct_id(),this._instance.sessionManager)),qe(this.Do)&&((o=et.__PosthogExtensions__)==null||(o=o.tracingHeadersPatchFns)==null||o._patchFetch(a,this._instance.get_distinct_id(),this._instance.sessionManager))},this._instance=e}initialize(){this.startIfEnabledOrStop()}ur(e){var t,o;(t=et.__PosthogExtensions__)!=null&&t.tracingHeadersPatchFns&&e(),(o=et.__PosthogExtensions__)==null||o.loadExternalDependency==null||o.loadExternalDependency(this._instance,"tracing-headers",(a=>{if(a)return hie.error("failed to load script",a);e()}))}Bo(){var e;return(e=this._instance.config.addTracingHeaders)!==null&&e!==void 0?e:this._instance.config.__add_tracing_headers}startIfEnabledOrStop(){var e,t;this.Bo()?this.ur(this.so):((e=this.Lo)==null||e.call(this),(t=this.Do)==null||t.call(this),this.Lo=void 0,this.Do=void 0)}}},Pie=Me({surveys:class{get Bt(){return this._instance.config}constructor(e){this.jo=void 0,this._surveyManager=null,this.$o=!1,this.qo=[],this.Zo=null,this._instance=e,this._surveyEventReceiver=null}initialize(){this.loadIfEnabled()}onRemoteConfig(e){if(!this.Bt.disable_surveys){var t=e.surveys;if(Ct(t))return to.warn("Flags not loaded yet. Not loading surveys.");var o=It(t);this.jo=o?t.length>0:t,to.info("flags response received, isSurveysEnabled: "+this.jo),this.loadIfEnabled()}}reset(){localStorage.removeItem("lastSeenSurveyDate");for(var e=[],t=0;t<localStorage.length;t++){var o=localStorage.key(t);(o!=null&&o.startsWith(HT)||o!=null&&o.startsWith("inProgressSurvey_"))&&e.push(o)}e.forEach((a=>localStorage.removeItem(a)))}loadIfEnabled(){if(!this._surveyManager)if(this.$o)to.info("Already initializing surveys, skipping...");else if(this.Bt.disable_surveys)to.info($O);else if(this.Bt.cookieless_mode&&this._instance.consent.isOptedOut())to.info("Not loading surveys in cookieless mode without consent.");else{var e=et?.__PosthogExtensions__;if(e){if(!qe(this.jo)||this.Bt.advanced_enable_surveys){var t=this.jo||this.Bt.advanced_enable_surveys;this.$o=!0;try{var o=e.generateSurveys;if(o)return void this.Vo(o,t);var a=e.loadExternalDependency;if(!a)return void this.Ho(G_);a(this._instance,"surveys",(n=>{n||!e.generateSurveys?this.Ho("Could not load surveys script",n):this.Vo(e.generateSurveys,t)}))}catch(n){throw this.Ho("Error initializing surveys",n),n}finally{this.$o=!1}}}else to.error("PostHog Extensions not found.")}}Vo(e,t){this._surveyManager=e(this._instance,t),this._surveyEventReceiver=new yie(this._instance),to.info("Surveys loaded successfully"),this.zo({isLoaded:!0})}Ho(e,t){to.error(e,t),this.zo({isLoaded:!1,error:e})}onSurveysLoaded(e){return this.qo.push(e),this._surveyManager&&this.zo({isLoaded:!0}),()=>{this.qo=this.qo.filter((t=>t!==e))}}getSurveys(e,t){if(t===void 0&&(t=!1),this.Bt.disable_surveys)return to.info($O),e([]);var o,a=this._instance.get_property(RT);if(a&&!t)return e(a,{isLoaded:!0});typeof Promise<"u"&&this.Zo?this.Zo.then((n=>{var{surveys:i,context:l}=n;return e(i,l)})):(typeof Promise<"u"&&(this.Zo=new Promise((n=>{o=n}))),this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/surveys/?token="+this.Bt.token),method:"GET",timeout:this.Bt.surveys_request_timeout_ms,callback:n=>{var i;this.Zo=null;var l=n.statusCode;if(l!==200||!n.json){var c="Surveys API could not be loaded, status: "+l;to.error(c);var u={isLoaded:!1,error:c};return e([],u),void(o==null||o({surveys:[],context:u}))}var p,m=n.json.surveys||[],h=m.filter((v=>(function(b){return!(!b.start_date||b.end_date)})(v)&&((function(b){var S;return!((S=b.conditions)==null||(S=S.events)==null||(S=S.values)==null||!S.length)})(v)||(function(b){var S;return!((S=b.conditions)==null||(S=S.actions)==null||(S=S.values)==null||!S.length)})(v))));h.length>0&&((p=this._surveyEventReceiver)==null||p.register(h)),(i=this._instance.persistence)==null||i.register({[RT]:m});var f={isLoaded:!0};e(m,f),o?.({surveys:m,context:f})}}))}zo(e){for(var t of this.qo)try{if(!e.isLoaded)return t([],e);this.getSurveys(t)}catch(o){to.error("Error in survey callback",o)}}getActiveMatchingSurveys(e,t){if(t===void 0&&(t=!1),!Ct(this._surveyManager))return this._surveyManager.getActiveMatchingSurveys(e,t);to.warn("init was not called")}Uo(e){var t=null;return this.getSurveys((o=>{var a;t=(a=o.find((n=>n.id===e)))!==null&&a!==void 0?a:null})),t}Yo(e){if(Ct(this._surveyManager))return{eligible:!1,reason:I0};var t=typeof e=="string"?this.Uo(e):e;return t?this._surveyManager.checkSurveyEligibility(t):{eligible:!1,reason:"Survey not found"}}canRenderSurvey(e){if(Ct(this._surveyManager))return to.warn("init was not called"),{visible:!1,disabledReason:I0};var t=this.Yo(e);return{visible:t.eligible,disabledReason:t.reason}}canRenderSurveyAsync(e,t){return Ct(this._surveyManager)?(to.warn("init was not called"),Promise.resolve({visible:!1,disabledReason:I0})):new Promise((o=>{this.getSurveys((a=>{var n,i=(n=a.find((c=>c.id===e)))!==null&&n!==void 0?n:null;if(i){var l=this.Yo(i);o({visible:l.eligible,disabledReason:l.reason})}else o({visible:!1,disabledReason:"Survey not found"})}),t)}))}renderSurvey(e,t,o){var a;if(Ct(this._surveyManager))to.warn("init was not called");else{var n=typeof e=="string"?this.Uo(e):e;if(n!=null&&n.id)if(Xre.includes(n.type)){var i=ze?.querySelector(t);if(i)return(a=n.appearance)!=null&&a.surveyPopupDelaySeconds?(to.info("Rendering survey "+n.id+" with delay of "+n.appearance.surveyPopupDelaySeconds+" seconds"),void setTimeout((()=>{var l,c;to.info("Rendering survey "+n.id+" with delay of "+((l=n.appearance)==null?void 0:l.surveyPopupDelaySeconds)+" seconds"),(c=this._surveyManager)==null||c.renderSurvey(n,i,o),to.info("Survey "+n.id+" rendered")}),1e3*n.appearance.surveyPopupDelaySeconds)):void this._surveyManager.renderSurvey(n,i,o);to.warn("Survey element not found")}else to.warn("Surveys of type "+n.type+" cannot be rendered in the app");else to.warn("Survey not found")}}displaySurvey(e,t){var o;if(Ct(this._surveyManager))to.warn("init was not called");else{var a=this.Uo(e);if(a){var n=a;if((o=a.appearance)!=null&&o.surveyPopupDelaySeconds&&t.ignoreDelay&&(n=Me({},a,{appearance:Me({},a.appearance,{surveyPopupDelaySeconds:0})})),t.displayType!==jT.Popover&&t.initialResponses&&to.warn("initialResponses is only supported for popover surveys. prefill will not be applied."),t.ignoreConditions===!1){var i=this.canRenderSurvey(a);if(!i.visible)return void to.warn("Survey is not eligible to be displayed: ",i.disabledReason)}t.displayType!==jT.Inline?this._surveyManager.handlePopoverSurvey(n,t):this.renderSurvey(n,t.selector,t.properties)}else to.warn("Survey not found")}}cancelPendingSurvey(e){Ct(this._surveyManager)?to.warn("init was not called"):this._surveyManager.cancelSurvey(e)}handlePageUnload(){var e;(e=this._surveyManager)==null||e.handlePageUnload()}}},Hv),Aie={toolbar:class{constructor(e){this.instance=e}Go(e){et.ph_toolbar_state=e}Wo(){var e;return(e=et.ph_toolbar_state)!==null&&e!==void 0?e:0}initialize(){return this.maybeLoadToolbar()}maybeLoadToolbar(e,t,o){if(e===void 0&&(e=void 0),t===void 0&&(t=void 0),o===void 0&&(o=void 0),yj(this.instance.config)||!ge||!ze)return!1;e=e??ge.location,o=o??ge.history;try{if(!t){try{ge.localStorage.setItem("test","test"),ge.localStorage.removeItem("test")}catch{return!1}t=ge?.localStorage}var a,n=Sie||Qf(e.hash,"__posthog")||Qf(e.hash,"state"),i=n?nO((()=>JSON.parse(atob(decodeURIComponent(n)))))||nO((()=>JSON.parse(decodeURIComponent(n)))):null;return i&&i.action==="ph_authorize"?((a=i).source="url",a&&Object.keys(a).length>0&&(i.desiredHash?e.hash=i.desiredHash:o?o.replaceState(o.state,"",e.pathname+e.search):e.hash="")):((a=JSON.parse(t.getItem(qO)||"{}")).source="localstorage",delete a.userIntent),!(!a.token||this.instance.config.token!==a.token||(this.loadToolbar(a),0))}catch{return!1}}Xo(e){var t=et.ph_load_toolbar||et.ph_load_editor;!Ct(t)&&_i(t)?t(e,this.instance):VO.warn("No toolbar load function found")}loadToolbar(e){var t=!(ze==null||!ze.getElementById(gj));if(!ge||t)return!1;var o=this.instance.requestRouter.region==="custom"&&this.instance.config.advanced_disable_toolbar_metrics,a=Me({token:this.instance.config.token},e,{apiURL:this.instance.requestRouter.endpointFor("ui")},o?{instrument:!1}:{});if(ge.localStorage.setItem(qO,JSON.stringify(Me({},a,{source:void 0}))),this.Wo()===2)this.Xo(a);else if(this.Wo()===0){var n;this.Go(1),(n=et.__PosthogExtensions__)==null||n.loadExternalDependency==null||n.loadExternalDependency(this.instance,"toolbar",(i=>{if(i)return VO.error("[Toolbar] Failed to load",i),void this.Go(0);this.Go(2),this.Xo(a)})),Zo(ge,"turbolinks:load",(()=>{this.Go(0),this.loadToolbar(a)}))}return!0}Jo(e){return this.loadToolbar(e)}maybeLoadEditor(e,t,o){return e===void 0&&(e=void 0),t===void 0&&(t=void 0),o===void 0&&(o=void 0),this.maybeLoadToolbar(e,t,o)}}},Rie=Me({experiments:Oa},Hv),Die={conversations:class{constructor(e){this.Ko=void 0,this._conversationsManager=null,this.Qo=!1,this.ea=null,this._instance=e}initialize(){this.loadIfEnabled()}onRemoteConfig(e){if(!this._instance.config.disable_conversations){var t=e.conversations;Ct(t)||($r(t)?this.Ko=t:(this.Ko=t.enabled,this.ea=t),this.loadIfEnabled())}}reset(){var e;(e=this._conversationsManager)==null||e.reset(),this._conversationsManager=null,this.Ko=void 0,this.ea=null}loadIfEnabled(){if(!(this._conversationsManager||this.Qo||this._instance.config.disable_conversations||yj(this._instance.config)||this._instance.config.cookieless_mode&&this._instance.consent.isOptedOut())){var e=et?.__PosthogExtensions__;if(e&&!qe(this.Ko)&&this.Ko)if(this.ea&&this.ea.token){this.Qo=!0;try{var t=e.initConversations;if(t)return this.ta(t),void(this.Qo=!1);var o=e.loadExternalDependency;if(!o)return void this.ra(G_);o(this._instance,"conversations",(a=>{a||!e.initConversations?this.ra("Could not load conversations script",a):this.ta(e.initConversations),this.Qo=!1}))}catch(a){this.ra("Error initializing conversations",a),this.Qo=!1}}else Hn.error("Conversations enabled but missing token in remote config.")}}ta(e){if(this.ea)try{this._conversationsManager=e(this.ea,this._instance),Hn.info("Conversations loaded successfully")}catch(t){this.ra("Error completing conversations initialization",t)}else Hn.error("Cannot complete initialization: remote config is null")}ra(e,t){Hn.error(e,t),this._conversationsManager=null,this.Qo=!1}show(){this._conversationsManager?this._conversationsManager.show():Hn.warn("Conversations not loaded yet.")}hide(){this._conversationsManager&&this._conversationsManager.hide()}isAvailable(){return this.Ko===!0&&!Ii(this._conversationsManager)}isVisible(){var e,t;return(e=(t=this._conversationsManager)==null?void 0:t.isVisible())!==null&&e!==void 0&&e}sendMessage(e,t,o){var a=this;return Kn((function*(){return a._conversationsManager?a._conversationsManager.sendMessage(e,t,o):(Hn.warn(ml),null)}))()}getMessages(e,t){var o=this;return Kn((function*(){return o._conversationsManager?o._conversationsManager.getMessages(e,t):(Hn.warn(ml),null)}))()}markAsRead(e){var t=this;return Kn((function*(){return t._conversationsManager?t._conversationsManager.markAsRead(e):(Hn.warn(ml),null)}))()}getTickets(e){var t=this;return Kn((function*(){return t._conversationsManager?t._conversationsManager.getTickets(e):(Hn.warn(ml),null)}))()}requestRestoreLink(e){var t=this;return Kn((function*(){return t._conversationsManager?t._conversationsManager.requestRestoreLink(e):(Hn.warn(ml),null)}))()}restoreFromToken(e){var t=this;return Kn((function*(){return t._conversationsManager?t._conversationsManager.restoreFromToken(e):(Hn.warn(ml),null)}))()}restoreFromUrlToken(){var e=this;return Kn((function*(){return e._conversationsManager?e._conversationsManager.restoreFromUrlToken():(Hn.warn(ml),null)}))()}getCurrentTicketId(){var e,t;return(e=(t=this._conversationsManager)==null?void 0:t.getCurrentTicketId())!==null&&e!==void 0?e:null}getWidgetSessionId(){var e,t;return(e=(t=this._conversationsManager)==null?void 0:t.getWidgetSessionId())!==null&&e!==void 0?e:null}un(){var e;(e=this._conversationsManager)==null||e.setIdentity()}hn(){var e;(e=this._conversationsManager)==null||e.clearIdentity()}}},Oie={logs:class{constructor(e){var t;this.ia=!1,this.na=!1,this.Gt=wo("[logs]"),this.sa=[],this.oa=0,this.aa=0,this.la=!1,this._instance=e,this._instance&&(t=this._instance.config.logs)!=null&&t.captureConsoleLogs&&(this.ia=!0)}initialize(){this.loadIfEnabled()}onRemoteConfig(e){var t,o=(t=e.logs)==null?void 0:t.captureConsoleLogs;!Ct(o)&&o&&(this.ia=!0,this.loadIfEnabled())}reset(){this.sa=[],this.jr&&(clearTimeout(this.jr),this.jr=void 0),this.oa=0,this.aa=0,this.la=!1}loadIfEnabled(){if(this.ia&&!this.na){var e=et?.__PosthogExtensions__;if(e){var t=e.loadExternalDependency;t?t(this._instance,"logs",(o=>{var a;o||(a=e.logs)==null||!a.initializeLogs?this.Gt.error("Could not load logs script",o):(e.logs.initializeLogs(this._instance),this.na=!0)})):this.Gt.error(G_)}else this.Gt.error("PostHog Extensions not found.")}}captureLog(e){var t,o,a,n,i,l;if(this._instance.is_capturing())if(e&&e.body){var c=(t=(o=this._instance.config.logs)==null?void 0:o.flushIntervalMs)!==null&&t!==void 0?t:3e3,u=(a=(n=this._instance.config.logs)==null?void 0:n.maxLogsPerInterval)!==null&&a!==void 0?a:1e3,p=Date.now();if(c>p-this.aa||(this.aa=p,this.oa=0,this.la=!1),u>this.oa){this.oa++;var m=(function(h,f){var v=h.level||"info",{text:b,number:S}=rj[v]||Kne,_=String(Date.now())+"000000",T={};f.distinctId&&(T.posthogDistinctId=f.distinctId),f.sessionId&&(T.sessionId=f.sessionId),f.currentUrl&&(T["url.full"]=f.currentUrl),f.screenName&&(T["screen.name"]=f.screenName),f.appState&&(T["app.state"]=f.appState),f.activeFeatureFlags&&f.activeFeatureFlags.length>0&&(T.feature_flags=f.activeFeatureFlags);var x=Me({},T,h.attributes||{}),P={timeUnixNano:_,observedTimeUnixNano:_,severityNumber:S,severityText:b,body:{stringValue:h.body},attributes:tO(x)};return h.trace_id&&(P.traceId=h.trace_id),h.span_id&&(P.spanId=h.span_id),qe(h.trace_flags)||(P.flags=h.trace_flags),P})(e,this.ua());this.sa.push({record:m}),((i=(l=this._instance.config.logs)==null?void 0:l.maxBufferSize)!==null&&i!==void 0?i:100)>this.sa.length?this.ha():this.flushLogs()}else this.la||(this.Gt.warn("captureLog dropping logs: exceeded "+u+" logs per "+c+"ms"),this.la=!0)}else this.Gt.warn("captureLog requires a body")}get logger(){return this.ca||(this.ca={trace:(e,t)=>this.captureLog({body:e,level:"trace",attributes:t}),debug:(e,t)=>this.captureLog({body:e,level:"debug",attributes:t}),info:(e,t)=>this.captureLog({body:e,level:"info",attributes:t}),warn:(e,t)=>this.captureLog({body:e,level:"warn",attributes:t}),error:(e,t)=>this.captureLog({body:e,level:"error",attributes:t}),fatal:(e,t)=>this.captureLog({body:e,level:"fatal",attributes:t})}),this.ca}flushLogs(e){if(this.jr&&(clearTimeout(this.jr),this.jr=void 0),this.sa.length!==0){var t=this.sa;this.sa=[];var o=this._instance.config.logs,a=Me({"service.name":o?.serviceName||"unknown_service"},o?.environment&&{"deployment.environment":o.environment},o?.serviceVersion&&{"service.version":o.serviceVersion},o?.resourceAttributes),n=(function(l,c,u,p){return{resourceLogs:[{resource:{attributes:tO(c)},scopeLogs:[{scope:{name:u,version:p},logRecords:l}]}]}})(t.map((l=>l.record)),a,Ga.LIB_NAME,Ga.LIB_VERSION),i=this._instance.requestRouter.endpointFor("api","/i/v1/logs")+"?token="+encodeURIComponent(this._instance.config.token);this._instance.Vi({method:"POST",url:i,data:n,compression:"best-available",batchKey:"logs",transport:e})}}ha(){var e,t;this.jr||(this.jr=setTimeout((()=>{this.jr=void 0,this.flushLogs()}),(e=(t=this._instance.config.logs)==null?void 0:t.flushIntervalMs)!==null&&e!==void 0?e:3e3))}ua(){var e,t={};if(t.distinctId=this._instance.get_distinct_id(),this._instance.sessionManager){var{sessionId:o}=this._instance.sessionManager.checkAndGetSessionAndWindowId(!0);t.sessionId=o}if(et!=null&&(e=et.location)!=null&&e.href&&(t.currentUrl=et.location.href),this._instance.featureFlags){var a=this._instance.featureFlags.getFlags();a&&a.length>0&&(t.activeFeatureFlags=a)}return t}}},Mie=Me({},Hv,Tie,xie,_ie,kie,Cie,Pie,Eie,Aie,Rie,Die,Oie);Yn.__defaultExtensionClasses=Me({},Mie);var KO,Li=(KO=pp[Yc]=new Yn,(function(){function e(){e.done||(e.done=!0,Uj=!1,go(pp,(function(t){t._dom_loaded()})))}ze!=null&&ze.addEventListener?ze.readyState==="complete"?e():Zo(ze,"DOMContentLoaded",e,{capture:!1}):ge&&Ue.error("Browser doesn't support `document.addEventListener` so PostHog couldn't be initialized")})(),KO);const Nie="studio-ui-resources",ov="html",Iie=10080*60*1e3,Lie=50,Bie=16*1024*1024;function Fie(e){return e[0]==="mcp"&&e[1]===$I}function Gv(){return new Promise((e,t)=>{const o=indexedDB.open(Nie,1);o.onupgradeneeded=()=>{o.result.objectStoreNames.contains(ov)||o.result.createObjectStore(ov)},o.onsuccess=()=>e(o.result),o.onerror=()=>t(o.error)})}function Cd(e,t){return e.transaction(ov,t).objectStore(ov)}function ZT(e){return new Promise((t,o)=>{e.onsuccess=()=>t(e.result),e.onerror=()=>o(e.error)})}async function jie(e){if(!(typeof indexedDB>"u"))try{const t=await Gv(),o=Cd(t,"readonly"),a=await ZT(o.getAllKeys()),n=await ZT(o.getAll()),i=Date.now(),l=a.map((p,m)=>({key:p,value:n[m]})).sort((p,m)=>(m.value?.updatedAt??0)-(p.value?.updatedAt??0)),c=[];let u=0;for(const{key:p,value:m}of l){if(!m||i-m.updatedAt>Iie||u>=Lie){c.push(p);continue}u++;try{const f=JSON.parse(String(p));e.getQueryData(f)===void 0&&e.setQueryData(f,m.html,{updatedAt:0})}catch{c.push(p)}}if(c.length>0){const p=Cd(t,"readwrite");for(const m of c)p.delete(m)}}catch{}}function zie(e){if(typeof indexedDB>"u")return()=>{};const t=Gv().catch(()=>null);return e.getQueryCache().subscribe(o=>{const a=o.query;if(!Array.isArray(a.queryKey)||!Fie(a.queryKey)||a.state.status!=="success")return;const n=a.state.data;typeof n!="string"||n.length>Bie||t.then(i=>{if(i)try{Cd(i,"readwrite").put({html:n,updatedAt:Date.now()},JSON.stringify(a.queryKey))}catch{}})})}function Uie(){typeof indexedDB>"u"||Gv().then(e=>Cd(e,"readwrite").clear()).catch(()=>{})}async function Fve(e){if(!(typeof indexedDB>"u"))try{const t=await Gv(),o=await ZT(Cd(t,"readonly").getAllKeys()),a=Cd(t,"readwrite");for(const n of o)try{const i=JSON.parse(String(n));i[1]===$I&&i[3]===e&&a.delete(n)}catch{}}catch{}}const av="studio:rq-cache",X_=1440*60*1e3,$ie=1e3,qie=new Set(["publicConfig","ai-provider-keys","organization-settings","home-next-actions"]),Vie=new Set(["VIRTUAL_MCP","CONNECTIONS"]);let Zj=!1,Qj=!1;function Hie(e){const t=e[0];return typeof t=="string"&&qie.has(t)?!0:e[3]==="collection"&&typeof e[4]=="string"&&Vie.has(e[4])}function Gie(e){if(!(typeof window>"u"))try{const t=window.localStorage.getItem(av);if(!t)return;const o=JSON.parse(t),a=!o.timestamp||Date.now()-o.timestamp>X_;if(o.buster!=="4.494.0"||a||!o.state){window.localStorage.removeItem(av);return}l8(e,o.state),e.invalidateQueries({queryKey:On.publicConfig(),refetchType:"none"}),Zj=!0}catch{Zie()}}function Wie(e){if(typeof window>"u")return()=>{};let t=null;const o=()=>{t=null;try{const i=s8(e,{shouldDehydrateQuery:l=>l.state.status==="success"&&Hie(l.queryKey)});window.localStorage.setItem(av,JSON.stringify({buster:"4.494.0",timestamp:Date.now(),state:i}))}catch{}},a=e.getQueryCache().subscribe(()=>{t==null&&(t=setTimeout(o,$ie))}),n=()=>{t!=null&&(clearTimeout(t),o())};return window.addEventListener("pagehide",n),()=>{t!=null&&clearTimeout(t),window.removeEventListener("pagehide",n),a()}}const Jj="studio:org-cache:",Kie=20;function Yie(e){const t=Date.now(),o=Object.entries(e).filter(([,a])=>t-a.updatedAt<=X_);for(o.sort(([,a],[,n])=>a.updatedAt-n.updatedAt);o.length>Kie;)o.shift();return Object.fromEntries(o)}function Xj(e){return`${Jj}${e}`}function jve(e,t){if(typeof window>"u")return null;try{const o=window.localStorage.getItem(Xj(e));if(!o)return null;const a=JSON.parse(o)[t];return!a||Date.now()-a.updatedAt>X_?null:(Qj=!0,a)}catch{return null}}function zve(e,t,o){if(!(typeof window>"u"))try{const a=Xj(e),n=window.localStorage.getItem(a),i=n?JSON.parse(n):{};i[t]={data:o,updatedAt:Date.now()},window.localStorage.setItem(a,JSON.stringify(Yie(i)))}catch{}}function Zie(){if(Uie(),!(typeof window>"u"))try{window.localStorage.removeItem(av);for(let e=window.localStorage.length-1;e>=0;e--){const t=window.localStorage.key(e);t?.startsWith(Jj)&&window.localStorage.removeItem(t)}}catch{}}function Qie(){return Zj}function Jie(){return Qj}let Di=!1,QT=null,YO=!1;const ek="studio:lp-distinct-id",e3="mesh:lp-distinct-id",B0="/api/_reports/link-token/",Xie=1440*60*1e3;function t3(e){const t="https://analytics.invalid",o=/^[a-z][a-z\d+.-]*:\/\//i.test(e),a=e.startsWith("//");try{const n=new URL(e,t);let i=!1;for(const l of["key","d"])n.searchParams.has(l)&&(n.searchParams.delete(l),i=!0);return n.pathname.startsWith(B0)&&n.pathname!==B0&&(n.pathname=`${B0}redacted`,i=!0),i?o?n.toString():a?`//${n.host}${n.pathname}${n.search}${n.hash}`:`${n.pathname}${n.search}${n.hash}`:e}catch{return e}}function F0(e){return Object.fromEntries(Object.entries(e).map(([t,o])=>[t,typeof o=="string"?t3(o):o]))}const ese=e=>e?(e.properties=F0(e.properties),e.$set&&(e.$set=F0(e.$set)),e.$set_once&&(e.$set_once=F0(e.$set_once)),e):null;function o3(){try{const e=window.localStorage.getItem(ek)??window.localStorage.getItem(e3);if(!e)return;const{id:t,ts:o}=JSON.parse(e);return typeof t!="string"||!t||typeof o!="number"?void 0:Date.now()-o<=Xie?t:void 0}catch{return}}function tse(){try{window.localStorage.removeItem(ek),window.localStorage.removeItem(e3)}catch{}}function ose(){try{const e=new URL(window.location.href),t=e.searchParams.get("ph_did");t&&(window.localStorage.setItem(ek,JSON.stringify({id:t,ts:Date.now()})),e.searchParams.delete("ph_did"),window.history.replaceState(window.history.state,"",e.toString()));const o=t??o3();return o?Object.keys(window.localStorage).some(n=>n.startsWith("ph_")&&n.endsWith("_posthog"))?void 0:o:void 0}catch{return}}function ase(e){const t=o3();if(t&&(tse(),t!==e))try{Li.alias(t)}catch{}}function nse(e,t){if(Di||typeof window>"u")return;const o=ose();Li.init(e,{api_host:t,ui_host:"https://us.posthog.com",cross_subdomain_cookie:!0,...o?{bootstrap:{distinctID:o}}:{},capture_pageview:"history_change",capture_pageleave:!0,autocapture:!0,before_send:ese,capture_performance:{web_vitals:!0,network_timing:!0},capture_exceptions:!0,session_recording:{maskAllInputs:!0,blockClass:"ph-no-capture",maskCapturedNetworkRequestFn:a=>({...a,...typeof a.name=="string"?{name:t3(a.name)}:{}})},person_profiles:"identified_only"}),Di=!0}function rse(e,t){Di&&(Li.identify(e,t),ase(e))}function ise(){Di&&(Li.reset(),QT=null)}function a3(e,t){Di&&Li.capture(e,t)}function Uve(){return Di}function $ve(){if(!Di||YO||typeof performance>"u")return;YO=!0;const e=performance.getEntriesByType("navigation")[0],t=o=>{const a=performance.getEntriesByName(o,"measure")[0];return a?Math.round(a.duration):void 0};a3("perf_app_bootstrap",{nav_type:e?.type,ttfb_ms:e?Math.round(e.responseStart):void 0,dom_interactive_ms:e?Math.round(e.domInteractive):void 0,dom_content_loaded_ms:e?Math.round(e.domContentLoadedEventEnd):void 0,config_fetch_ms:t("studio:config-fetch"),active_org_fetch_ms:t("studio:active-org-fetch"),time_to_shell_ms:Math.round(performance.now()),cache_restored:Qie(),org_cache_restored:Jie()})}function qve(e,t){Di&&e!==QT&&(Li.group("organization",e,t),QT=e)}function n3(e,t){if(Di)try{Li.captureException(e,t)}catch{}}const sse=["radial-gradient(ellipse 85% 85% at 0% 0%, rgba(165,149,255,0.6) 0%, transparent 72%)","radial-gradient(ellipse 85% 85% at 100% 100%, rgba(208,236,26,0.52) 0%, transparent 72%)","radial-gradient(ellipse 85% 85% at 0% 100%, rgba(255,193,22,0.48) 0%, transparent 72%)"].join(", ");function lse(e){const t=Re.c(3),{children:o}=e;let a;t[0]===Symbol.for("react.memo_cache_sentinel")?(a=w.jsx("div",{className:"absolute inset-0 pointer-events-none",style:{backgroundImage:sse}}),t[0]=a):a=t[0];let n;return t[1]!==o?(n=w.jsxs("div",{className:"relative flex items-center justify-center min-h-screen bg-background overflow-hidden",children:[a,w.jsx("div",{className:"relative flex flex-col items-center text-center space-y-4 max-w-sm px-6",children:o})]}),t[1]=o,t[2]=n):n=t[2],n}function r3(e){const t=Re.c(20),{orgName:o}=e,a=ar(),n=cse;let i;t[0]===Symbol.for("react.memo_cache_sentinel")?(i=w.jsx("div",{className:"bg-muted p-3 rounded-full","aria-hidden":"true",children:w.jsx(bF,{className:"h-6 w-6 text-muted-foreground"})}),t[0]=i):i=t[0];let l;t[1]!==a?(l=a("common.archivedOrgScreen.orgUnavailable"),t[1]=a,t[2]=l):l=t[2];let c;t[3]!==l?(c=w.jsx("h3",{className:"text-lg font-medium",children:l}),t[3]=l,t[4]=c):c=t[4];let u;t[5]!==o||t[6]!==a?(u=o?a("common.archivedOrgScreen.deletedWithName",{orgName:o}):a("common.archivedOrgScreen.deletedGeneric"),t[5]=o,t[6]=a,t[7]=u):u=t[7];let p;t[8]!==u?(p=w.jsx("p",{className:"text-sm text-muted-foreground",children:u}),t[8]=u,t[9]=p):p=t[9];let m;t[10]!==c||t[11]!==p?(m=w.jsxs("div",{className:"space-y-2",children:[c,p]}),t[10]=c,t[11]=p,t[12]=m):m=t[12];let h;t[13]!==a?(h=a("common.goHome"),t[13]=a,t[14]=h):h=t[14];let f;t[15]!==h?(f=w.jsx(Ri,{onClick:n,children:h}),t[15]=h,t[16]=f):f=t[16];let v;return t[17]!==m||t[18]!==f?(v=w.jsxs(lse,{children:[i,m,f]}),t[17]=m,t[18]=f,t[19]=v):v=t[19],v}function cse(){window.location.href="/"}function dse(){const e=Re.c(3);let t;e[0]===Symbol.for("react.memo_cache_sentinel")?(t={from:"/shell/$org"},e[0]=t):t=e[0];const{org:o}=Up(t);let a;return e[1]!==o?(a=w.jsx(Ri,{variant:"outline",size:"sm",asChild:!0,children:w.jsx(Nl,{to:"/$org/settings/profile",params:{org:o},children:"Go to your profile"})}),e[1]=o,e[2]=a):a=e[2],a}function use(e){const t=Re.c(13),{area:o,description:a,action:n}=e,i=o?`No access to ${o}`:"No access",l=a??"Your role doesn't include permission for this section. Ask an organization admin to update your role if you need it.";let c;t[0]===Symbol.for("react.memo_cache_sentinel")?(c=w.jsx("div",{className:"flex h-16 w-16 items-center justify-center rounded-full bg-muted text-muted-foreground",children:w.jsx(EF,{size:28})}),t[0]=c):c=t[0];let u;t[1]!==i?(u=w.jsx("h3",{className:"text-lg font-medium",children:i}),t[1]=i,t[2]=u):u=t[2];let p;t[3]!==l?(p=w.jsx("p",{className:"mx-auto max-w-sm text-sm text-muted-foreground",children:l}),t[3]=l,t[4]=p):p=t[4];let m;t[5]!==u||t[6]!==p?(m=w.jsxs("div",{className:"space-y-1",children:[u,p]}),t[5]=u,t[6]=p,t[7]=m):m=t[7];let h;t[8]!==n?(h=n??w.jsx(dse,{}),t[8]=n,t[9]=h):h=t[9];let f;return t[10]!==m||t[11]!==h?(f=w.jsxs("div",{className:"flex h-full min-h-[60vh] flex-1 flex-col items-center justify-center gap-4 p-6 text-center",children:[c,m,h]}),t[10]=m,t[11]=h,t[12]=f):f=t[12],f}const ZO="__studio_chunk_reload_ts";function i3(e){return e?.message===tQ}function pse(e){return!!e?.message?.includes("Access denied")}function QO(e){if(!e)return!1;const t=e.message||"";return t.includes("Failed to fetch dynamically imported module")||t.includes("Importing a module script failed")||t.includes("error loading dynamically imported module")||t.includes("Failed to fetch")&&e.name==="TypeError"}class mse extends A.Component{state={hasError:!1,error:null};static getDerivedStateFromError(t){return{hasError:!0,error:t}}componentDidCatch(t,o){console.error("Uncaught error:",t,o),n3(t,{boundary:"default",error_name:t.name,error_message:t.message,component_stack:o.componentStack??null,route:typeof window<"u"?window.location.pathname:null})}resetError=()=>{this.setState({hasError:!1,error:null})};render(){if(this.state.hasError){const{fallback:t,t:o}=this.props;return typeof t=="function"?t({error:this.state.error,resetError:this.resetError}):t!==void 0?t:i3(this.state.error)?w.jsx(r3,{}):pse(this.state.error)?w.jsx(use,{}):w.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center h-full p-6 text-center space-y-4",children:[w.jsx("div",{className:"bg-destructive/10 p-3 rounded-full",children:w.jsx(B_,{className:"h-6 w-6 text-destructive"})}),w.jsxs("div",{className:"space-y-2",children:[w.jsx("h3",{className:"text-lg font-medium",children:o("common.errorBoundary.somethingWentWrong")}),w.jsx("p",{className:"text-sm text-muted-foreground max-w-xs mx-auto",children:this.state.error?.message||o("common.errorBoundary.unexpectedError")})]}),w.jsx(Ri,{variant:"outline",onClick:this.resetError,children:o("common.errorBoundary.tryAgain")})]})}return this.props.children}}function hse(e){const t=Re.c(3),o=ar();let a;return t[0]!==e||t[1]!==o?(a=w.jsx(mse,{...e,t:o}),t[0]=e,t[1]=o,t[2]=a):a=t[2],a}class gse extends A.Component{state={hasError:!1,error:null};static getDerivedStateFromError(t){return{hasError:!0,error:t}}componentDidCatch(t,o){console.error("Uncaught error:",t,o);const a=QO(t);if(n3(t,{boundary:"chunk_root",is_chunk_load_error:a,error_name:t.name,error_message:t.message,component_stack:o.componentStack??null,route:typeof window<"u"?window.location.pathname:null}),!a)return;const n=sessionStorage.getItem(ZO),i=Date.now();(!n||i-Number(n)>1e4)&&(sessionStorage.setItem(ZO,String(i)),window.location.reload())}render(){const{t}=this.props;return this.state.hasError&&QO(this.state.error)?w.jsxs("div",{className:"flex min-h-dvh flex-col items-center justify-center p-6 text-center space-y-4",children:[w.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:w.jsx(PF,{className:"h-6 w-6 text-primary"})}),w.jsxs("div",{className:"space-y-2",children:[w.jsx("h3",{className:"text-lg font-medium",children:t("common.errorBoundary.newVersionAvailable")}),w.jsx("p",{className:"text-sm text-muted-foreground max-w-xs mx-auto",children:t("common.errorBoundary.newVersionDeployed")})]}),w.jsx(Ri,{onClick:()=>window.location.reload(),children:t("common.errorBoundary.refresh")})]}):this.state.hasError?i3(this.state.error)?w.jsx(r3,{}):w.jsxs("div",{className:"flex min-h-dvh flex-col items-center justify-center p-6 text-center space-y-4",children:[w.jsx("div",{className:"bg-destructive/10 p-3 rounded-full",children:w.jsx(B_,{className:"h-6 w-6 text-destructive"})}),w.jsxs("div",{className:"space-y-2",children:[w.jsx("h3",{className:"text-lg font-medium",children:t("common.errorBoundary.somethingWentWrong")}),w.jsx("p",{className:"text-sm text-muted-foreground max-w-xs mx-auto",children:this.state.error?.message||t("common.errorBoundary.unexpectedError")})]}),w.jsx(Ri,{variant:"outline",onClick:()=>this.setState({hasError:!1,error:null}),children:t("common.errorBoundary.tryAgain")})]}):this.props.children}}function fse(e){const t=Re.c(3),o=ar();let a;return t[0]!==e||t[1]!==o?(a=w.jsx(gse,{...e,t:o}),t[0]=e,t[1]=o,t[2]=a):a=t[2],a}function vse(e){const t=Re.c(8);let o,a;t[0]!==e?({className:o,...a}=e,t[0]=e,t[1]=o,t[2]=a):(o=t[1],a=t[2]);let n;t[3]!==o?(n=gt("surface flex flex-col gap-6",o),t[3]=o,t[4]=n):n=t[4];let i;return t[5]!==a||t[6]!==n?(i=w.jsx("div",{"data-slot":"card",className:n,...a}),t[5]=a,t[6]=n,t[7]=i):i=t[7],i}function Vve(e){const t=Re.c(4);let o;t[0]!==e?({...o}=e,t[0]=e,t[1]=o):o=t[1];let a;return t[2]!==o?(a=w.jsx("div",{"data-slot":"card-content",...o}),t[2]=o,t[3]=a):a=t[3],a}function Hve(e){const t=Re.c(12),{title:o,description:a,docsHref:n,actions:i,className:l,headerClassName:c,children:u}=e;let p;t[0]!==l?(p=gt("flex flex-col gap-3",l),t[0]=l,t[1]=p):p=t[1];let m;t[2]!==i||t[3]!==a||t[4]!==n||t[5]!==c||t[6]!==o?(m=(o||a||n||i)&&w.jsxs("div",{className:gt("flex items-center justify-between gap-3 px-4",c),children:[w.jsxs("div",{className:"flex flex-col gap-1 min-w-0",children:[o&&w.jsx("h2",{className:"text-[15px] font-medium leading-tight",children:o}),(a||n)&&w.jsxs("p",{className:"text-sm text-muted-foreground leading-snug",children:[a,n&&w.jsxs("a",{href:n,target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-0.5 ml-1 text-foreground hover:underline",children:["Docs ",w.jsx(yF,{size:12})]})]})]}),i&&w.jsx("div",{className:"shrink-0",children:i})]}),t[2]=i,t[3]=a,t[4]=n,t[5]=c,t[6]=o,t[7]=m):m=t[7];let h;return t[8]!==u||t[9]!==p||t[10]!==m?(h=w.jsxs("section",{className:p,children:[m,u]}),t[8]=u,t[9]=p,t[10]=m,t[11]=h):h=t[11],h}function Gve(e){const t=Re.c(11),{className:o,children:a}=e;let n,i,l;if(t[0]!==a||t[1]!==o){const u=A.Children.toArray(a).filter(A.isValidElement);n=vse,t[5]!==o?(i=gt("p-0 gap-0 overflow-hidden",o),t[5]=o,t[6]=i):i=t[6],l=u.map(bse),t[0]=a,t[1]=o,t[2]=n,t[3]=i,t[4]=l}else n=t[2],i=t[3],l=t[4];let c;return t[7]!==n||t[8]!==i||t[9]!==l?(c=w.jsx(n,{className:i,children:l}),t[7]=n,t[8]=i,t[9]=l,t[10]=c):c=t[10],c}function bse(e,t){return w.jsxs("div",{children:[t>0&&w.jsx("div",{className:"h-px bg-border mx-5"}),e]},t)}function Wve(e){const t=Re.c(27),{icon:o,title:a,description:n,action:i,onClick:l,className:c,children:u}=e,p=u?"flex items-start gap-3 px-4 py-4":"flex items-center gap-3 px-4 py-4",m=l&&"hover:bg-muted/50 cursor-pointer";let h;t[0]!==c||t[1]!==p||t[2]!==m?(h=gt(p,m,c),t[0]=c,t[1]=p,t[2]=m,t[3]=h):h=t[3];const f=l?"button":void 0,v=l?0:void 0;let b;t[4]!==l?(b=l?E=>{E.target===E.currentTarget&&(E.key==="Enter"||E.key===" ")&&(E.preventDefault(),l())}:void 0,t[4]=l,t[5]=b):b=t[5];let S;t[6]!==o?(S=o&&w.jsx("div",{className:"size-8 shrink-0 rounded-lg bg-muted/60 flex items-center justify-center text-muted-foreground",children:o}),t[6]=o,t[7]=S):S=t[7];let _;t[8]!==a?(_=w.jsx("div",{className:"text-sm font-medium",children:a}),t[8]=a,t[9]=_):_=t[9];let T;t[10]!==n?(T=n&&w.jsx("p",{className:"text-xs text-muted-foreground mt-0.5 leading-relaxed",children:n}),t[10]=n,t[11]=T):T=t[11];let x;t[12]!==u||t[13]!==_||t[14]!==T?(x=w.jsxs("div",{className:"flex-1 min-w-0",children:[_,T,u]}),t[12]=u,t[13]=_,t[14]=T,t[15]=x):x=t[15];let P;t[16]!==i?(P=i&&w.jsx("div",{className:"shrink-0",onClick:yse,children:i}),t[16]=i,t[17]=P):P=t[17];let C;return t[18]!==l||t[19]!==x||t[20]!==P||t[21]!==h||t[22]!==f||t[23]!==v||t[24]!==b||t[25]!==S?(C=w.jsxs("div",{className:h,onClick:l,role:f,tabIndex:v,onKeyDown:b,children:[S,x,P]}),t[18]=l,t[19]=x,t[20]=P,t[21]=h,t[22]=f,t[23]=v,t[24]=b,t[25]=S,t[26]=C):C=t[26],C}function yse(e){return e.stopPropagation()}function Kve(e){const t=Re.c(5),{className:o,children:a}=e;let n;t[0]!==o?(n=gt("px-4 py-4",o),t[0]=o,t[1]=n):n=t[1];let i;return t[2]!==a||t[3]!==n?(i=w.jsx("div",{className:n,children:a}),t[2]=a,t[3]=n,t[4]=i):i=t[4],i}function Yve(e){const t=Re.c(5),{children:o,className:a}=e;let n;t[0]!==a?(n=gt("flex items-center justify-end gap-2 px-4 py-4",a),t[0]=a,t[1]=n):n=t[1];let i;return t[2]!==o||t[3]!==n?(i=w.jsx("div",{className:n,children:o}),t[2]=o,t[3]=n,t[4]=i):i=t[4],i}function Sse(e){const t=Re.c(5),{className:o,children:a}=e;let n;t[0]!==o?(n=gt("flex flex-col gap-10",o),t[0]=o,t[1]=n):n=t[1];let i;return t[2]!==a||t[3]!==n?(i=w.jsx("div",{className:n,children:a}),t[2]=a,t[3]=n,t[4]=i):i=t[4],i}const Wv={connect:{key:"connect",titleKey:"settings.connectClients.pageTitle",tabs:[],ownedRoutes:["/$org/settings/api-keys"]},members:{key:"members",titleKey:"orgs.members.title",tabs:[{key:"members",icon:DF,labelKey:"orgs.members.title",to:"/$org/settings/members",requires:"members:manage"},{key:"roles",icon:RF,labelKey:"settings.roles.pageTitle",to:"/$org/settings/roles",privilegedOnly:!0}]},billing:{key:"billing",titleKey:"settings.nav.billing",tabs:[{key:"ai-providers",icon:TF,labelKey:"settings.nav.aiProviders",to:"/$org/settings/ai-providers",requires:"ai-providers:manage"},{key:"infra",icon:AF,labelKey:"settings.subnav.infrastructure",to:"/$org/settings/infra-billing",requires:"members:manage",requiresOwnedSites:!0}]},repositories:{key:"repositories",titleKey:"settings.nav.repositories",tabs:[],ownedRoutes:["/$org/settings/repositories"]},storage:{key:"storage",titleKey:"settings.nav.storage",tabs:[{key:"buckets",icon:kF,labelKey:"settings.nav.buckets",to:"/$org/settings/buckets",requires:"file-configs:manage"},{key:"synced-repos",icon:_F,labelKey:"settings.nav.syncedRepos",to:"/$org/settings/synced-repos",requires:"file-configs:manage"}]}};function Zve(e){const t=Wv[e];return[...t.tabs.map(o=>o.to),...t.ownedRoutes??[]]}function Qve(e){return Wv[e].tabs.length>0}const wse=new Set(["owner","admin"]);function s3(){const e=Re.c(11),{org:t,locator:o}=Zp();let a;e[0]!==o?(a=On.myCapabilities(o),e[0]=o,e[1]=a):a=e[1];let n;e[2]!==t?(n=async()=>{const m=await fetch(`/api/auth/custom/my-capabilities/${encodeURIComponent(t.slug)}`,{credentials:"include"});if(!m.ok)throw new Error(`my-capabilities request failed: ${m.status}`);return await m.json()},e[2]=t,e[3]=n):n=e[3];let i;e[4]!==a||e[5]!==n?(i={queryKey:a,queryFn:n,staleTime:3e4,retry:2},e[4]=a,e[5]=n,e[6]=i):i=e[6];const{data:l,isLoading:c,isError:u}=Rd(i);let p;return e[7]!==l||e[8]!==u||e[9]!==c?(p={data:l,loading:c,error:u},e[7]=l,e[8]=u,e[9]=c,e[10]=p):p=e[10],p}function Jve(e){const t=Re.c(8),{data:o,loading:a,error:n}=s3();if(a){let p;return t[0]===Symbol.for("react.memo_cache_sentinel")?(p={granted:!1,loading:!0,error:!1,reason:"loading"},t[0]=p):p=t[0],p}if(n){let p;return t[1]===Symbol.for("react.memo_cache_sentinel")?(p={granted:!1,loading:!1,error:!0,reason:"error"},t[1]=p):p=t[1],p}const i=o?.role??null;if(!i){let p;return t[2]===Symbol.for("react.memo_cache_sentinel")?(p={granted:!1,loading:!1,error:!1,reason:"denied"},t[2]=p):p=t[2],p}if(i==="owner"){let p;return t[3]===Symbol.for("react.memo_cache_sentinel")?(p={granted:!0,loading:!1,error:!1,reason:"owner"},t[3]=p):p=t[3],p}if(i==="admin"){let p;return t[4]===Symbol.for("react.memo_cache_sentinel")?(p={granted:!0,loading:!1,error:!1,reason:"admin"},t[4]=p):p=t[4],p}const l=o?.capabilities?.[e]===!0,c=l?"role":"denied";let u;return t[5]!==l||t[6]!==c?(u={granted:l,loading:!1,error:!1,reason:c},t[5]=l,t[6]=c,t[7]=u):u=t[7],u}function l3(){const e=Re.c(10),{data:t,loading:o,error:a}=s3(),n=t?.role??void 0;let i;e[0]!==n?(i=n?wse.has(n):!1,e[0]=n,e[1]=i):i=e[1];const l=i;let c;e[2]!==t?.capabilities?(c=t?.capabilities??{},e[2]=t?.capabilities,e[3]=c):c=e[3];const u=c;let p;return e[4]!==a||e[5]!==l||e[6]!==o||e[7]!==n||e[8]!==u?(p={capabilities:u,loading:o,error:a,isPrivileged:l,roleSlug:n},e[4]=a,e[5]=l,e[6]=o,e[7]=n,e[8]=u,e[9]=p):p=e[9],p}function Tse(){const e=Re.c(13),{org:t}=Zp(),o=i_(),{capabilities:a,isPrivileged:n}=l3(),i=n||!!a["members:manage"];let l;e[0]!==t.id?(l=On.infraBillingSites(t.id),e[0]=t.id,e[1]=l):l=e[1];const c=!!t.id&&i;let u;e[2]!==o?(u=()=>o.call("INFRA_BILLING_SITES_LIST",{}),e[2]=o,e[3]=u):u=e[3];let p;e[4]!==l||e[5]!==c||e[6]!==u?(p={queryKey:l,staleTime:3e5,enabled:c,queryFn:u},e[4]=l,e[5]=c,e[6]=u,e[7]=p):p=e[7];const{data:m,isLoading:h}=Rd(p);let f;e[8]!==m?.sites?(f=m?.sites.map(xse)??[],e[8]=m?.sites,e[9]=f):f=e[9];let v;return e[10]!==h||e[11]!==f?(v={sites:f,isLoading:h},e[10]=h,e[11]=f,e[12]=v):v=e[12],v}function xse(e){return e.slug}function Xve(){const e=Re.c(7),t=i_(),o=ar();let a;e[0]!==t?(a=l=>t.call("INFRA_BILLING_PORTAL",{siteSlugs:l}),e[0]=t,e[1]=a):a=e[1];let n;e[2]!==o?(n=l=>Vr.error(o("settings.infraBilling.portalError",{message:l.message})),e[2]=o,e[3]=n):n=e[3];let i;return e[4]!==a||e[5]!==n?(i={mutationFn:a,onSuccess:_se,onError:n},e[4]=a,e[5]=n,e[6]=i):i=e[6],sp(i)}function _se(e){const{url:t}=e;return window.open(t,"_blank","noopener,noreferrer")}function ebe(e,t){const o=Re.c(14),{org:a}=Zp(),n=i_();let i,l,c;o[0]!==a.id||o[1]!==t||o[2]!==e?(i=[...e].sort(),c=Rd,l=On.infraBilling(a.id,i.join(","),t),o[0]=a.id,o[1]=t,o[2]=e,o[3]=i,o[4]=l,o[5]=c):(i=o[3],l=o[4],c=o[5]);const u=i.length>0;let p;o[6]!==t||o[7]!==i||o[8]!==n?(p=()=>n.call("INFRA_BILLING_GET",{siteSlugs:i,period:t}),o[6]=t,o[7]=i,o[8]=n,o[9]=p):p=o[9];let m;return o[10]!==l||o[11]!==u||o[12]!==p?(m={queryKey:l,enabled:u,staleTime:6e4,queryFn:p},o[10]=l,o[11]=u,o[12]=p,o[13]=m):m=o[13],c(m)}function kse(){const e=Re.c(7),{capabilities:t,isPrivileged:o,loading:a,error:n}=l3(),{sites:i,isLoading:l}=Tse(),c=i.length>0;let u;if(e[0]!==t||e[1]!==n||e[2]!==o||e[3]!==a||e[4]!==c||e[5]!==l){const p=m=>m.requiresOwnedSites&&!c&&!l?!1:a||n?!0:m.privilegedOnly?o:m.requires?o||t[m.requires]:!0;u=Object.fromEntries(Object.values(Wv).map(m=>[m.key,m.tabs.filter(p)])),e[0]=t,e[1]=n,e[2]=o,e[3]=a,e[4]=c,e[5]=l,e[6]=u}else u=e[6];return u}function Cse(e){const t=Re.c(16),{group:o}=e,a=ar();let n;t[0]===Symbol.for("react.memo_cache_sentinel")?(n={from:"/shell/$org"},t[0]=n):n=t[0];const{org:i}=Up(n);let l;t[1]===Symbol.for("react.memo_cache_sentinel")?(l={select:Ese},t[1]=l):l=t[1];const c=Dx(l),u=kse()[o],{titleKey:p}=Wv[o];let m;t[2]!==a||t[3]!==p?(m=a(p),t[2]=a,t[3]=p,t[4]=m):m=t[4];let h;t[5]!==m?(h=w.jsx(ld.Title,{children:m}),t[5]=m,t[6]=h):h=t[6];let f;t[7]!==o||t[8]!==i||t[9]!==c||t[10]!==a||t[11]!==u?(f=u.length>1&&w.jsx(nn.Toolbar.Left.Portal,{children:w.jsx(ld.Tabs,{"data-testid":"settings-subnav","aria-label":a("settings.subnav.ariaLabel"),children:u.map(b=>{const S=b.to.replace("$org",i),_=c===S||c.startsWith(`${S}/`);return w.jsx(ld.Tab,{active:_,asChild:!0,children:w.jsx(Nl,{to:b.to,params:{org:i},onClick:()=>a3("settings_subnav_clicked",{group_key:o,tab_key:b.key}),children:a(b.labelKey)})},b.key)})})}),t[7]=o,t[8]=i,t[9]=c,t[10]=a,t[11]=u,t[12]=f):f=t[12];let v;return t[13]!==h||t[14]!==f?(v=w.jsxs(w.Fragment,{children:[h,f]}),t[13]=h,t[14]=f,t[15]=v):v=t[15],v}function Ese(e){return e.location.pathname}function c3(){const e=Re.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=w.jsxs("div",{"data-testid":"settings-content-loading",className:"flex flex-col gap-4",children:[w.jsx(yD,{className:"h-32 w-full"}),w.jsx(yD,{className:"h-32 w-full"})]}),e[0]=t):t=e[0],t}function Pse(e){const t=Re.c(14),{group:o,fallback:a,errorFallback:n,className:i,children:l}=e;let c;t[0]!==o?(c=w.jsx(Cse,{group:o}),t[0]=o,t[1]=c):c=t[1];let u;t[2]!==a?(u=a??w.jsx(c3,{}),t[2]=a,t[3]=u):u=t[3];let p;t[4]!==l||t[5]!==u?(p=w.jsx(A.Suspense,{fallback:u,children:l}),t[4]=l,t[5]=u,t[6]=p):p=t[6];let m;t[7]!==n||t[8]!==p?(m=w.jsx(hse,{fallback:n,children:p}),t[7]=n,t[8]=p,t[9]=m):m=t[9];let h;return t[10]!==i||t[11]!==c||t[12]!==m?(h=w.jsx(ld,{children:w.jsx(ld.Content,{children:w.jsx(ld.Container,{children:w.jsxs(Sse,{className:i,children:[c,m]})})})}),t[10]=i,t[11]=c,t[12]=m,t[13]=h):h=t[13],h}function Bi(e){return function(){return w.jsx(Pse,{group:e,children:w.jsx(c3,{})})}}function Ase(e){try{localStorage.setItem(Bl.lastLocation(),JSON.stringify(e))}catch{}}function Rse(){try{const e=localStorage.getItem(Bl.lastLocation());if(!e)return null;const t=JSON.parse(e);if(typeof t?.org=="string")return{org:t.org}}catch{}return null}function tbe(){try{localStorage.removeItem(Bl.lastLocation())}catch{}}const Nt={home:"/$org/home",projects:"/$org/projects/$agentId",tasks:"/$org/tasks/{-$taskKey}",reports:"/$org/reports",library:"/$org/library",threadAnalytics:"/$org/thread-analytics",discover:"/$org/discover",orgIndex:"/$org/"},rt={root:Nt.projects,tasks:"/$org/projects/$agentId/tasks/{-$taskKey}",reports:"/$org/projects/$agentId/reports",siteEditor:"/$org/projects/$agentId/site-editor",siteEditorContent:"/$org/projects/$agentId/site-editor/content",siteEditorCode:"/$org/projects/$agentId/site-editor/code",automations:"/$org/projects/$agentId/automations",automation:"/$org/projects/$agentId/automations/$automationId",app:"/$org/projects/$agentId/apps/$connectionId/$toolName",view:"/$org/projects/$agentId/views/$viewId",outputFile:"/$org/projects/$agentId/outputs/file",outputDeck:"/$org/projects/$agentId/outputs/deck",library:"/$org/projects/$agentId/library",libraryFile:"/$org/projects/$agentId/library/file",connectSources:"/$org/projects/$agentId/connect-sources",settings:"/$org/projects/$agentId/settings",assets:"/$org/projects/$agentId/assets",hosting:"/$org/projects/$agentId/hosting",e2e:"/$org/projects/$agentId/e2e",analytics:"/$org/projects/$agentId/analytics",experiments:"/$org/projects/$agentId/experiments",monitor:"/$org/projects/$agentId/cdn"};function obe(){const e=Re.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t={select:Dse},e[0]=t):t=e[0],Dx(t)}function Dse(e){return e.matches.at(-1)?.fullPath??""}const Ose=new Map([[Nt.reports,"project-only"],[Nt.library,"org-only"],[Nt.threadAnalytics,"org-only"]]);function abe(e,t){const o=Ose.get(e);return o===void 0?!0:o==="project-only"?t!==null:t===null}function nbe(){const e=Re.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t={select:Mse},e[0]=t):t=e[0],Dx(t)}function Mse(e){return e.matches.findLast(Nse)?.staticData.mainView}function Nse(e){return e.staticData.mainView}function lf(e){return`agent-view:${encodeURIComponent(e)}`}function Ise(e){if(!e?.startsWith("agent-view:"))return null;const t=e.slice(11);if(!t)return null;try{const o=decodeURIComponent(t);return o?{id:o}:null}catch{return null}}function d3(e){if(!e||!e.startsWith("automation:"))return null;const t=e.slice(11);return t?{id:t}:null}function tk(e,t){return`app:${e}:${t}`}function Lse(e){if(!e||!e.startsWith("app:"))return null;const t=e.slice(4),o=t.indexOf(":");if(o<=0)return null;const a=t.slice(0,o),n=t.slice(o+1);return!a||!n?null:{connectionId:a,toolName:n}}function u3(e){return`deck:${encodeURIComponent(e)}`}function Bse(e){if(!e||!e.startsWith("deck:"))return null;const t=e.slice(5);if(!t)return null;try{return{path:decodeURIComponent(t)}}catch{return null}}function p3(e){return`file:${encodeURIComponent(e)}`}function Fse(e){if(!e||!e.startsWith("file:"))return null;const t=e.slice(5);if(!t)return null;try{return{key:decodeURIComponent(t)}}catch{return null}}function m3(e){return`library-file:${encodeURIComponent(e)}`}function jse(e){if(!e||!e.startsWith("library-file:"))return null;const t=e.slice(13);if(!t)return null;try{return{path:decodeURIComponent(t)}}catch{return null}}function h3(e){return`code:${encodeURIComponent(e)}`}function zse(e){if(!e)return null;if(e==="code")return{path:null};if(!e.startsWith("code:"))return null;const t=e.slice(5);if(!t)return null;try{return{path:decodeURIComponent(t)}}catch{return null}}const g3=["overview","settings","automations","site-editor","code","content","assets","hosting","e2e","analytics","cdn"],Use=new Set(g3),f3=new Set(["hosting","e2e","analytics","cdn"]),$se=new Set(["board","files","connect-sources","reports"]);function rbe(e){return e.startsWith("app:")||e.startsWith("automation:")||e.startsWith("file:")||e.startsWith("deck:")||e.startsWith("library-file:")||e.startsWith("code:")}const qse=new Map([["preview","site-editor"],["git","site-editor"]]);function Kv(e){return qse.get(e)??e}const ok=new Set(["instructions","connections","layout","settings"]);function Vse(e){return!!e&&ok.has(e)}const Hse=new Set(["overview","board","reports"]);function ibe(e){const t=e?.defaultMainView??null;if(!(!t||t.type==="chat"))return v3(e??null)}function v3(e){const t=e?.defaultMainView??null;if(!t)return"settings";const o=Kv(t.type);if(ok.has(o))return"settings";if(Use.has(o)||Hse.has(o))return o;if(o==="ext-app"||o==="ext-apps"){if(t.id&&t.toolName)return tk(t.id,t.toolName);const n=e?.tabs?.map(i=>i.id)??[];return t.id&&n.includes(t.id)?lf(t.id):n[0]?lf(n[0]):"settings"}const a=e?.tabs?.[0]?.id;return a?lf(a):"settings"}function sbe(e){const t=e.routeDefaultMain||v3(e.metadata),o=e.panelTabId&&ok.has(e.panelTabId)?"settings":e.panelTabId?Kv(e.panelTabId):e.panelTabId,a=e.metadata?.defaultMainView??null,n=a==null||a.type==="chat";return{mainOpen:e.mainPanelParam??(!!o||!!e.routeDefaultMain||!n),activeTab:o??t}}function lbe(e){return e.mainOpen&&e.clickedId===e.activeTab?{close:!0}:{tabId:e.clickedId}}function cbe(e){return e.mainOpen?e.activeTab==="automations"?!0:d3(e.activeTab)!==null:!1}const Gse=new Set([...g3.filter(e=>!f3.has(e)),...$se,"app","file","deck","library-file","connect-sources","instructions","connections","layout","preview","discover"]);function Wse(e){return!!e&&Gse.has(e)}function Kse(e,t){if(e)switch(e){case"app":return t.connection&&t.tool?tk(t.connection,t.tool):void 0;case"automations":return t.automation?`automation:${t.automation}`:"automations";case"file":return t.key?p3(t.key):void 0;case"deck":return t.deck?u3(t.deck):void 0;case"library-file":return t.path?m3(t.path):void 0;case"code":return t.file?h3(t.file):"code";default:{const o=Kv(e);return o==="site-editor"&&t.main==="content"?"content":o}}}function dbe(e){const t=e.params??{},o=e.search??{};if(e.siteEditorView==="content")return"content";if(e.siteEditorView==="code")return o.file?h3(o.file):"code";if(e.siteEditorView==="preview")return"site-editor";switch(e.mainView){case"automation":return t.automationId?`automation:${t.automationId}`:"automations";case"app":return t.connectionId&&t.toolName?tk(t.connectionId,t.toolName):void 0;case"view":return t.viewId?lf(t.viewId):void 0;case"file":return o.key?p3(o.key):void 0;case"deck":return o.path?u3(o.path):void 0;case"library-file":return o.path?m3(o.path):void 0;default:return e.mainView}}const Yse={files:"library",discover:"discover"},Zse={board:"tasks",reports:"reports"},Qse={settings:"settings",assets:"assets",hosting:"hosting",e2e:"e2e",analytics:"analytics",experiments:"experiments",cdn:"monitor"};function b3(e){const t=Ise(e);if(t)return{kind:"agent-view",viewId:t.id};const o=Lse(e);if(o)return{kind:"app",connectionId:o.connectionId,toolName:o.toolName};const a=d3(e);if(a)return{kind:"automations",automationId:a.id};const n=Fse(e);if(n)return{kind:"output-file",key:n.key};const i=Bse(e);if(i)return{kind:"output-deck",path:i.path};const l=jse(e);if(l)return{kind:"library-file",path:l.path};const c=zse(e);if(c)return{kind:"site-editor",view:"code",...c.path?{file:c.path}:{}};if(Vse(e))return{kind:"agent-section",section:"settings"};const u=Kv(e);if(u==="overview")return{kind:"agent-overview"};if(u==="site-editor")return{kind:"site-editor",view:"preview"};if(u==="content")return{kind:"site-editor",view:"content"};if(u==="automations")return{kind:"automations"};if(u==="connect-sources")return{kind:"connect-sources"};const p=Zse[u];if(p)return{kind:"project-destination",destination:p};const m=Yse[u];if(m)return{kind:"org-destination",destination:m};const h=Qse[u];return h?{kind:"agent-section",section:h}:{kind:"agent-view",viewId:u}}function Dl(e){const{org:t,agentId:o}=e,a={org:t,agentId:o},n=b3(e.tabId);switch(n.kind){case"project-destination":return e.destinationScope==="organization"?n.destination==="tasks"?{to:Nt.tasks,params:{org:t,taskKey:e.taskKey},search:{}}:{to:Nt.reports,params:{org:t},search:{}}:n.destination==="tasks"?{to:rt.tasks,params:{...a,taskKey:e.taskKey},search:{}}:{to:rt.reports,params:a,search:{}};case"org-destination":switch(n.destination){case"home":return{to:Nt.home,params:{org:t},search:{}};case"discover":return{to:Nt.discover,params:{org:t},search:{}};case"library":return{to:Nt.library,params:{org:t},search:{}}}case"agent-overview":return{to:rt.root,params:a,search:{}};case"site-editor":return n.view==="content"?{to:rt.siteEditorContent,params:a,search:{}}:n.view==="code"?{to:rt.siteEditorCode,params:a,search:{file:n.file}}:{to:rt.siteEditor,params:a,search:{}};case"agent-section":return{to:rt[n.section],params:a,search:{}};case"automations":return n.automationId?{to:rt.automation,params:{...a,automationId:n.automationId},search:{}}:{to:rt.automations,params:a,search:{}};case"app":return{to:rt.app,params:{...a,connectionId:n.connectionId,toolName:n.toolName},search:{}};case"agent-view":return{to:rt.view,params:{...a,viewId:n.viewId},search:{}};case"output-file":return{to:rt.outputFile,params:a,search:{key:n.key}};case"output-deck":return{to:rt.outputDeck,params:a,search:{path:n.path}};case"library-file":return{to:rt.libraryFile,params:a,search:{path:n.path}};case"connect-sources":return{to:rt.connectSources,params:a,search:{}}}}function ube(e){if(!e.agentId||e.agentId===e.superAgentId&&(e.tabId===void 0||e.tabId==="overview"))return{to:Nt.home,params:{org:e.org},search:{}};const t=e.tabId??"overview",o=e.agentId!==e.superAgentId&&b3(t).kind==="org-destination"?"overview":t;return Dl({org:e.org,agentId:e.agentId,tabId:o,destinationScope:e.agentId===e.superAgentId?"organization":"project"})}function Jse(e,t,o={}){const a=i=>({...o.search?.(i)??{},...t.search}),n=o.replace??!0;switch(t.to){case Nt.tasks:e({to:Nt.tasks,params:t.params,search:a,replace:n});return;case Nt.home:e({to:Nt.home,params:t.params,search:a,replace:n});return;case Nt.reports:e({to:Nt.reports,params:t.params,search:a,replace:n});return;case Nt.discover:e({to:Nt.discover,params:t.params,search:a,replace:n});return;case Nt.library:e({to:Nt.library,params:t.params,search:a,replace:n});return;case rt.root:e({to:rt.root,params:t.params,search:a,replace:n});return;case rt.tasks:e({to:rt.tasks,params:t.params,search:a,replace:n});return;case rt.reports:e({to:rt.reports,params:t.params,search:a,replace:n});return;case rt.siteEditor:e({to:rt.siteEditor,params:t.params,search:a,replace:n});return;case rt.siteEditorContent:e({to:rt.siteEditorContent,params:t.params,search:a,replace:n});return;case rt.siteEditorCode:e({to:rt.siteEditorCode,params:t.params,search:a,replace:n});return;case rt.automations:e({to:rt.automations,params:t.params,search:a,replace:n});return;case rt.automation:e({to:rt.automation,params:t.params,search:a,replace:n});return;case rt.app:e({to:rt.app,params:t.params,search:a,replace:n});return;case rt.view:e({to:rt.view,params:t.params,search:a,replace:n});return;case rt.outputFile:e({to:rt.outputFile,params:t.params,search:a,replace:n});return;case rt.outputDeck:e({to:rt.outputDeck,params:t.params,search:a,replace:n});return;case rt.libraryFile:e({to:rt.libraryFile,params:t.params,search:a,replace:n});return;case rt.connectSources:e({to:rt.connectSources,params:t.params,search:a,replace:n});return;case rt.settings:case rt.assets:case rt.hosting:case rt.e2e:case rt.analytics:case rt.experiments:case rt.monitor:e({to:t.to,params:t.params,search:a,replace:n})}}function pbe(e,t){Jse(e,Dl(t),t)}function Xse(e){const t=/^(\/[^/]+)\/agents(?=\/|$)/.exec(e);return t?.[1]?`${t[1]}/projects${e.slice(t[0].length)}`:null}function ele(e){const t=e.split("/").filter(Boolean);return(t[1]==="projects"||t[1]==="agents")&&t.length>3}const tle=new Set(["main","virtualmcpid","file","key","deck","path","connection","tool","automation"]),y3=new Set(["main"]),ole=new Set(["virtualmcpid"]);function Yv(e,t){return Object.fromEntries(Object.entries(e).filter(([o])=>!t.has(o)))}function El(e,t){return{...Yv(e,tle),...t.search}}function ale(e){return Yv(e,ole)}function mbe(e){if(e.search.virtualmcpid===void 0)return null;const t=br(e.search.virtualmcpid);if(t){const o=e.routePath===Nt.tasks?"board":e.routePath===Nt.reports?"reports":null;if(e.routePath===Nt.home||o){const a=o?Dl({org:e.org,agentId:t,tabId:o}):Ed(e.org,t);return{kind:"canonical",route:a,search:El(e.search,a)}}}return e.routePath===Nt.home||e.routePath===Nt.tasks||e.routePath===Nt.reports||e.routePath===Nt.library?{kind:"same-route",search:ale(e.search)}:null}function br(e){return e?.trim()||void 0}function S3(e){return Wse(e)||e!==void 0&&f3.has(e)}function w3(e){const t=br(e);return t?t.startsWith("vir_")&&t.length>4||PI(t)!==null||wW(t)!==null||TW(t)!==null||RI(t)||DI(t):!1}function nle(e){const t=br(e.agentIdParam),o=S3(t);return t&&!o?t:br(e.virtualMcpIdSearch)??br(e.fallbackAgentId)}function hbe(e){const t=e.pathAgentId;if(t&&e.pathLegacyView){const l=JT({org:e.org,agentId:t,panel:e.pathLegacyView,source:"project-first",search:e.search});return l?.kind==="canonical"?{route:l.route,search:l.search}:null}if(!t||ele(e.pathname))return null;const o=e.search.virtualmcpid!==void 0&&!w3(t);if(!(S3(t)||o))return null;const n=nle({agentIdParam:o?void 0:t,virtualMcpIdSearch:e.search.virtualmcpid,fallbackAgentId:e.fallbackAgentId}),i=JT({org:e.org,agentId:n,panel:t,source:"view-first",search:e.search});return i?.kind==="canonical"?{route:i.route,search:i.search}:null}function rle(e,t,o,a){const n=br(a);switch(e){case"board":return n?Dl({org:t,agentId:n,tabId:"board"}):{to:Nt.tasks,params:{org:t,taskKey:void 0},search:{}};case"files":{const i=ys(o.path);return{to:Nt.library,params:{org:t},search:i?{path:i}:{}}}case"reports":return n?Dl({org:t,agentId:n,tabId:"reports"}):{to:Nt.reports,params:{org:t},search:{}};case"overview":return{to:Nt.home,params:{org:t},search:{}};case"discover":return{to:Nt.discover,params:{org:t},search:{}};default:return null}}function Lp(e){const t=rle(e.tabId,e.org,e.search,e.agentId);if(t)return t;if(e.tabId==="chat")return Ed(e.org,e.agentId);const o=br(e.agentId);return o?e.tabId==="app"||e.tabId==="file"||e.tabId==="deck"||e.tabId==="library-file"||e.tabId.trim()===""?{to:rt.root,params:{org:e.org,agentId:o},search:{}}:Dl({org:e.org,agentId:o,tabId:e.tabId}):null}function Ed(e,t){const o=br(t);return o?{to:rt.root,params:{org:e,agentId:o},search:{}}:{to:Nt.home,params:{org:e},search:{}}}function ile(e){const{main:t}=e;if(t===void 0)return null;const o=e.search??{};if(t===0||t==="0")return{kind:"same-route",search:{...Yv(o,y3),mainpanel:!1}};if(t==="chat"){const n=Ed(e.org,e.agentId);return{kind:"canonical",route:n,search:{...El(o,n),sidepanel:!0,mainpanel:!1}}}const a=Lp({org:e.org,agentId:e.agentId,tabId:t,search:o});return a?{kind:"canonical",route:a,search:El(o,a)}:null}function ys(e){return typeof e=="string"&&e.length>0?e:void 0}function JT(e){const t=e.search??{};if((t.main===0||t.main==="0")&&e.panel){const l=JT({...e,search:Yv(t,y3)});return l?.kind!=="canonical"?l:{...l,search:{...l.search,mainpanel:!1}}}if(t.main!==void 0)return ile({org:e.org,agentId:e.agentId,main:t.main,search:t});const o=br(e.agentId),a=e.panel;if(!a){const l=Ed(e.org,o);return{kind:"canonical",route:l,search:El(t,l)}}const n=Kse(a,{file:ys(t.file),key:ys(t.key),deck:ys(t.deck),path:ys(t.path),connection:ys(t.connection),tool:ys(t.tool),automation:ys(t.automation)}),i=n?e.source==="project-first"&&n==="overview"&&o?Dl({org:e.org,agentId:o,tabId:n}):Lp({org:e.org,agentId:o,tabId:n,search:t}):Lp({org:e.org,agentId:o,tabId:"",search:t});return i?{kind:"canonical",route:i,search:n==="chat"?{...El(t,i),sidepanel:!0,mainpanel:!1}:El(t,i)}:null}function gbe(e){const t=e.search??{},o=br(t.virtualmcpid),a=br(e.fallbackAgentId),n=t.main;let i;if(n==="chat")i=Ed(e.org,o);else if(n!==void 0&&n!==0&&n!=="0"){const l=Lp({org:e.org,agentId:o,tabId:n,search:t}),c=!l&&n.trim().length>0&&a?Lp({org:e.org,agentId:a,tabId:n,search:t}):null;i=l??c??{to:Nt.home,params:{org:e.org},search:{}}}else i=Ed(e.org,o);return{route:i,search:{...El(t,i),...n===void 0&&t.sidepanel===void 0?{sidepanel:!0}:{},...n===0||n==="0"?{mainpanel:!1}:{},...n==="chat"?{sidepanel:!0,mainpanel:!1}:{},thread:e.taskId}}}function T3(e,t){if(t.task===void 0)return null;const{task:o,...a}=t;return{taskKey:e??(o.trim()||void 0),search:a}}const sle={contentPageId:q().optional(),contentPath:q().optional(),contentPathTemplate:q().optional(),contentCollection:q().optional(),contentItem:q().optional()},x3=sle,ak={view:q().optional(),group:q().optional(),subgroup:q().optional(),sort:q().optional(),dir:q().optional(),q:q().optional(),assignee:q().optional(),priority:q().optional(),due:q().optional(),tags:q().optional(),repo:q().optional(),sprint:q().optional(),boardOrg:q().optional()},nv={fileView:So(["all","documents","media"]).catch("all").optional(),modified:So(["any","today","week","month"]).catch("any").optional(),layout:So(["list","grid"]).catch("list").optional(),sort:So(["name","updated","size"]).catch("name").optional(),path:q().optional(),preview:q().optional(),expanded:kp().optional().catch(void 0),skill:q().optional(),brand:q().optional()},lle={file:q().optional(),key:q().optional(),deck:q().optional(),path:q().optional(),connection:q().optional(),tool:q().optional(),automation:q().optional(),section:q().optional(),preview:q().optional(),autosend:q().optional(),connect:kv().optional(),siteUrl:q().optional(),...x3},_3={...lle,task:q().optional(),project:q().optional(),...ak,skill:nv.skill,brand:nv.brand},rm=we(_3),pn=E$({component:()=>w.jsx(fse,{children:w.jsx(Rx,{})})}),cle=Ne({getParentRoute:()=>pn,path:"/login",component:Fe(()=>je(()=>import("./login-DhV7QjVw.js"),__vite__mapDeps([0,1,2,3,4]))),validateSearch:Gr(()=>we({next:q().optional(),client_id:q().optional(),redirect_uri:q().optional(),response_type:q().optional(),state:q().optional(),scope:q().optional(),code_challenge:q().optional(),code_challenge_method:q().optional(),src:q().optional(),ref:q().optional()}))}),dle=Ne({getParentRoute:()=>pn,path:"/cli/auth-success",component:Fe(()=>je(()=>import("./cli-auth-success-DmgEVi8V.js"),__vite__mapDeps([5,4])))}),ule=Ne({getParentRoute:()=>pn,path:"/reset-password",component:Fe(()=>je(()=>import("./reset-password-CNXROw6o.js"),[])),validateSearch:Gr(()=>we({token:q().optional(),error:q().optional()}))}),ple=Ne({getParentRoute:()=>pn,path:"/auth/$pathname",component:Fe(()=>je(()=>import("./auth-catchall-UV-w9rG5.js"),[]))}),mle=Ne({getParentRoute:()=>pn,path:"/oauth/callback",component:Fe(()=>je(()=>import("./oauth-callback-BOiaAtqL.js"),__vite__mapDeps([6,7,8])))}),hle=Ne({getParentRoute:()=>pn,path:"/oauth/callback/ai-provider",component:Fe(()=>je(()=>import("./oauth-callback-ai-provider-DHi7-rTD.js"),[]))}),im=Ne({getParentRoute:()=>pn,path:"/_admin",component:Fe(()=>je(()=>import("./layout-CBzBOevY.js"),__vite__mapDeps([9,10,11])))}),gle=Ne({getParentRoute:()=>im,path:"/",beforeLoad:()=>{throw Jo({to:"/_admin/users"})}}),fle=Ne({getParentRoute:()=>im,path:"/users",component:Fe(()=>je(()=>import("./users-BjFgJ7AD.js"),__vite__mapDeps([12,13,14,15,16,17,18,19,20,21,22,23,24,25,26])))}),vle=Ne({getParentRoute:()=>im,path:"/orgs",component:Fe(()=>je(()=>import("./orgs-D5F2hLXP.js"),__vite__mapDeps([27,13,14,15,16,17,18,28,22,29,30,31,32,33,34,21,35,36,23,24,25])))}),ble=Ne({getParentRoute:()=>im,path:"/prompts",component:Fe(()=>je(()=>import("./prompts-BuofI3_s.js"),__vite__mapDeps([37,16,28,34,23])))}),yle=im.addChildren([gle,fle,vle,ble]),nk=Ne({getParentRoute:()=>pn,id:"shell",component:Fe(()=>je(()=>import("./shell-layout-BYblzqjk.js").then(e=>e.g),__vite__mapDeps([38,19,20,39,40,41,42,43,15,44,45,46,47,48,32,49,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,64,65,66,67,68,8,69,70,71,72,73,74,75,76,28,77,78,79,3,2,80,81,35,82,83,84,31,85,86,87,22,88,10,89,90,91])))}),Sle=Ne({getParentRoute:()=>nk,path:"/",beforeLoad:async()=>{const e=Rse();if(e)throw Jo({to:"/$org",params:{org:e.org}});const t=localStorage.getItem(Bl.lastOrgSlug());if(t)throw Jo({to:"/$org",params:{org:t}});const{data:o}=await rL();if(!o)return;const a=o[0];throw Jo(a?{to:"/$org",params:{org:a.slug}}:{to:"/onboarding"})}}),wle=Ne({getParentRoute:()=>pn,path:"/onboarding",beforeLoad:async()=>{const{data:e}=await rL();if(e&&e.length>0)throw Jo({to:"/"})},component:Fe(()=>je(()=>import("./onboarding-BcQ_H-Ta.js"),__vite__mapDeps([92,10,4,93,19,20,61,28,33,39,48,54,63])))}),k3=Gr(()=>we({org:q().optional(),siteUrl:q().optional(),fix:q().optional()})),Tle=Ne({getParentRoute:()=>pn,path:"/reports-onboarding",component:Fe(()=>je(()=>import("./reports-onboarding-BC8kmZ8I.js"),__vite__mapDeps([94,95,1,2,3,4,93,19,20,61,96,97,98,28,99,68,8,100,74,45,41,42,43,15,44,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,18,62,63,64,65,84,31,101,102,103,22,104,105,106,107,7,108,109,110,111,112,113]))),validateSearch:k3}),xle=Ne({getParentRoute:()=>pn,path:"/commerce-onboarding",validateSearch:k3,beforeLoad:({search:e})=>{throw Jo({to:"/reports-onboarding",search:e})}}),_le=Ne({getParentRoute:()=>pn,path:"/choose-editor",component:Fe(()=>je(()=>import("./choose-editor-CryRu8AV.js"),__vite__mapDeps([114,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,10]))),validateSearch:Gr(()=>we({site:q().optional(),domain:q().optional(),pageId:q().optional(),path:q().optional(),pathTemplate:q().optional()}))}),kle=Ne({getParentRoute:()=>pn,path:"/report/$domain",component:Fe(()=>je(()=>import("./reports-DOq1hOqC.js"),__vite__mapDeps([115,108,3,1,2,116])))}),Zv=Ne({getParentRoute:()=>nk,path:"/$org",beforeLoad:({params:e})=>{Ase({org:e.org})},component:Fe(()=>je(()=>import("./route-D_4e8W74.js"),__vite__mapDeps([117,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,121,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,124,125,126,96,97,98,127,128,129,130,131,11,132,29,30,34,133,134,135,136,137,138,139,140,141,26,24,25,142,143,144,145,146,147,148,33,149])))}),Qv=Ne({getParentRoute:()=>Zv,id:"org-shell",pendingComponent:Md,component:Fe(()=>je(()=>import("./thread-route-Y6_0A4lo.js"),__vite__mapDeps([150,151,69,70,66,67,68,8,89,79,3,2,80,81,35,82,137,136,152,153,88,95,154,101,102,103,45,99,100,74,41,42,43,15,44,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,84,31,98,28,22,104,105,106,107,7,108,109,110,111,155,112])))}),Cle=we({sidepanel:CL,mainpanel:EL,main:io([q(),Ze(0)]).optional(),thread:q().optional(),autosend:q().optional(),preview:q().optional(),virtualmcpid:q().optional()}),Mn=Ne({getParentRoute:()=>Qv,id:"agent-shell",validateSearch:Cle,search:{middlewares:[QU(["sidepanel"])]},pendingComponent:Md,component:Fe(()=>je(()=>import("./route-nWQgD8-7.js"),__vite__mapDeps([156,42,41,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,118,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,121,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,157,151,137,136,152,153,158,131,159,160,98,161,162,163,24,25,164,148,165,166,29,30,167,135,168,169,170,147,171,130,172,173,174,149,175,133,176,138,177,109,102,110,111,178,179,34,180,181,106,107,7,182,21,183,184,141,185,186,187,188,189,190,191,192,193,194,195,196,197,16,198,199,200,201,202,145,203,204,146,205,206,207,208,209,210,211,212])))}),Ele=rm.extend({virtualmcpid:q().optional()}),Ple=Ne({getParentRoute:()=>Mn,path:"/$taskId",validateSearch:Ele,component:()=>null}),oo=Fe(()=>je(()=>import("./index-D_2G1SLW.js").then(e=>e.i),__vite__mapDeps([198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148])),"ChatLayoutPending"),Zt=Fe(()=>je(()=>import("./index-D_2G1SLW.js").then(e=>e.i),__vite__mapDeps([198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148])),"ChatLayoutError"),Ale=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/home",staticData:{pageTitle:"sidebar.navDestinations.home",defaultMain:"overview",mainView:"overview"},validateSearch:we({connect:kv().optional(),siteUrl:q().optional(),view:So(["agents"]).optional()}),component:Fe(()=>je(()=>import("./home-D1UZSXtn.js"),__vite__mapDeps([213,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,140,141,137,127,128,124,129,214,215,216,217,218,219,164,160,158,98,161,162,163,153,24,25,151,136,152,165,166,29,30,167,135,168,169,170,147,171,130,131,172,173,159,174,149,175,133,176,138,177,109,102,110,111,178,179,34,180,181,106,107,7,182,21,183,184,185,220,154,101,103,221,26,222,143,223,16])))}),Rle=Ne({getParentRoute:()=>Mn,path:"/projects",staticData:{pageTitle:"projects.settings.title",defaultMain:"board"},validateSearch:rm.extend({files:kp().optional().catch(void 0),analytics:kp().optional().catch(void 0)}),component:Fe(()=>je(()=>import("./flat-project-Br0qxJS9.js"),__vite__mapDeps([224,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,225,84,31,198,121,118,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,223,226,124,125,227,228,130,160,158,98,161,162,163,153,24,25,137,151,136,152,173,229,21,33,34,174,219,26,230,140,141,175,133,29,30,129,128,231,232,233,187,234,235,236,197,237,180,103,238,184,186,188,189,190,191,159,192,165,183,200,169,166,239,240,182,241,139,242,214,215,216,217,14,243,244,245,246,247,218,248,249,97,250,208,206,207,209,210,211,251,252,253]))),beforeLoad:({params:e,search:t})=>{if(t.project?.trim())return;const o=t.virtualmcpid?.trim();throw Jo(o?{to:"/$org/projects/$agentId",params:{org:e.org,agentId:o},search:a=>({...a,virtualmcpid:void 0}),hash:!0,replace:!0}:{to:"/$org/home",params:{org:e.org},search:a=>({...a,virtualmcpid:void 0}),hash:!0,replace:!0})}}),Ro=Ne({errorComponent:Zt,getParentRoute:()=>Mn,path:"/projects/$agentId",validateSearch:rm,component:Rx}),Dle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/",staticData:{pageTitle:"page.overview",defaultMain:"overview",mainView:"overview"},component:Fe(()=>je(()=>import("./agent-overview-CARG35t2.js"),__vite__mapDeps([254,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,220,154,101,102,103,221,140,141,137,129,124,128,26,175,133,24,25,255,226,125,227,228,130,160,158,98,161,162,163,153,151,136,152,173,229,21,33,34,174,219,230,29,30,231,232,233,187,234,235,236,197,237,180,238,184,186,188,189,190,191,159,192,165,183,200,169,166,239,256,176,138,257])))}),Ole=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/tasks/{-$taskKey}",staticData:{pageTitle:"sidebar.navDestinations.tasks",defaultMain:"board",mainView:"board"},validateSearch:we({task:q().optional(),...ak}),beforeLoad:({params:e,search:t})=>{const o=T3(e.taskKey,t);if(o)throw Jo({to:"/$org/projects/$agentId/tasks/{-$taskKey}",params:{org:e.org,agentId:e.agentId,taskKey:o?.taskKey??e.taskKey},search:o.search,hash:!0,replace:!0})},component:Fe(()=>je(()=>import("./project-tasks-D52OJfjJ.js"),__vite__mapDeps([255,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,226,124,125,227,228,130,160,158,98,161,162,163,153,24,25,137,151,136,152,173,229,21,33,34,174,219,26,230,140,141,175,133,29,30,129,128,231,232,233,187,234,235,236,197,237,180,103,238,184,186,188,189,190,191,159,192,165,183,200,169,166,239,256,176,138,257])))}),Mle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/reports",staticData:{pageTitle:"sidebar.navDestinations.reports",defaultMain:"reports",mainView:"reports"},validateSearch:we({connect:kv().optional(),siteUrl:q().optional()}),component:Fe(()=>je(()=>import("./project-reports-iIDLiTtT.js"),__vite__mapDeps([258,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,259,95,154,101,102,103,221,112,113,223,143])))}),Jv=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/site-editor",staticData:{pageTitle:"sidebar.projectNav.siteEditor",defaultMain:"site-editor",mainView:"site-editor"},validateSearch:we({autosend:q().optional(),...x3}),component:Fe(()=>je(()=>import("./agent-site-editor-CXDMfxCU.js"),__vite__mapDeps([260,239,151,69,70,66,67,68,8,89,79,3,2,80,81,35,82,137,136,152,153,88,38,19,20,39,40,41,42,43,15,44,45,46,47,48,32,49,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,64,65,71,72,73,74,75,76,28,77,78,83,84,31,85,86,87,22,10,90,91,123,130,97,167,194,195,175,133,261,204,111,164,160,158,98,161,162,163,121,24,25,148,165,166,29,30,135,168,169,170,147,171,131,172,173,119,120,36,159,174,149,176,138,177,109,102,110,178,179,34,180,181,106,107,7,182,21,183,184,141,185,262,196,157,186,187,188,189,190,191,122,192,193,197,263,264,265,210,211,266,198,118,199,267])))}),Nle=Ne({getParentRoute:()=>Jv,path:"/",staticData:{defaultMain:"site-editor",mainView:"site-editor",siteEditorView:"preview"},component:Fe(()=>je(()=>import("./agent-site-editor-preview-BgyDrf4u.js"),__vite__mapDeps([268,269,201,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,180,202,190,161,157,151,89,137,136,152,153,158,84,31,131,87,121,159,160,98,28,162,163,24,25,164,148,165,38,19,71,72,73,74,75,76,77,78,83,85,86,22,10,90,91,166,29,30,167,135,168,169,170,147,171,130,172,173,174,149,175,133,176,138,177,109,102,110,111,178,179,34,181,106,107,7,182,21,183,184,141,185,186,187,188,189,191,122,192,193,145,203,204,256,196,197,261,123,270,210,139,271,211,232,272,235,33,124,125,228,97,17,273,265,274,264,263,262,105,212,16,199])))}),Ile=Ne({getParentRoute:()=>Jv,path:"/content",staticData:{defaultMain:"content",mainView:"content",siteEditorView:"content"},component:Fe(()=>je(()=>import("./agent-site-editor-content-BAjBb750.js").then(e=>e.aH),__vite__mapDeps([275,269,201,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,180,202,190,161,157,151,89,137,136,152,153,158,84,31,131,87,121,159,160,98,28,162,163,24,25,164,148,165,38,19,71,72,73,74,75,76,77,78,83,85,86,22,10,90,91,166,29,30,167,135,168,169,170,147,171,130,172,173,174,149,175,133,176,138,177,109,102,110,111,178,179,34,181,106,107,7,182,21,183,184,141,185,186,187,188,189,191,122,192,193,145,203,204,256,97,139,270,261,197,210,271,211,232,272,235,33,124,125,228,17,273,265,276,196,252,16])))}),Lle=Ne({getParentRoute:()=>Jv,path:"/code",staticData:{defaultMain:"code",mainView:"code",siteEditorView:"code"},validateSearch:we({file:q().optional()}),component:Fe(()=>je(()=>import("./agent-site-editor-code-yflTKEXl.js"),__vite__mapDeps([277,269,201,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,180,202,190,161,157,151,89,137,136,152,153,158,84,31,131,87,121,159,160,98,28,162,163,24,25,164,148,165,38,19,71,72,73,74,75,76,77,78,83,85,86,22,10,90,91,166,29,30,167,135,168,169,170,147,171,130,172,173,174,149,175,133,176,138,177,109,102,110,111,178,179,34,181,106,107,7,182,21,183,184,141,185,186,187,188,189,191,122,192,193,145,203,204,256,16])))}),Ble=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/automations",staticData:{pageTitle:"settings.nav.automations",defaultMain:"automations",mainView:"automations"},beforeLoad:({params:e,search:t})=>{const o=t.automation;if(o)throw Jo({to:"/$org/projects/$agentId/automations/$automationId",params:{org:e.org,agentId:e.agentId,automationId:o},search:a=>({...a,automation:void 0}),hash:!0,replace:!0})},component:Fe(()=>je(()=>import("./agent-automations-B3GOPyc3.js"),__vite__mapDeps([278,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,17,16,219,279,21,97])))}),Fle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/automations/$automationId",staticData:{pageTitle:"settings.nav.automations",defaultMain:"automations",mainView:"automation"},validateSearch:we({automationView:So(["settings","runs"]).optional()}),component:Fe(()=>je(()=>import("./agent-automation-BhXRsqWt.js"),__vite__mapDeps([280,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,21,147,33,130,158,180,202,281,131,151,137,136,152,153,170,29,30,171,282,219,187,283,172,173,160,98,161,162,163,24,25,159,174,284,128,124,285,167,271,211,97,286,14,16,183,175,133,200,238,184,186,188,189,190,191,192,165,182])))}),jle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/settings",staticData:{pageTitle:"sidebar.navDestinations.settings",defaultMain:"settings",mainView:"settings"},component:Fe(()=>je(()=>import("./agent-settings-7e_XyBHe.js"),__vite__mapDeps([287,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,97,34,180,283,177,178,179,131,98,29,30,181,106,182,21,183,184,165,174,147,17,290,190,202,159,161,33,130,139,144,204,193,291,292,191,195])))}),zle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/library",staticData:{pageTitle:"sidebar.navDestinations.library",defaultMain:"files",mainView:"files"},validateSearch:we(nv),component:Fe(()=>je(()=>import("./agent-library-CxgcYBSr.js"),__vite__mapDeps([293,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,249,230,97,153,152,174,250,34,162,163,208,130,206,207,209,210,211,165,251,252,225,24,25,14,175,133,253])))}),Ule=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/assets",staticData:{pageTitle:"common.mainPanelTabs.assets",defaultMain:"assets",mainView:"assets"},component:Fe(()=>je(()=>import("./agent-assets-Doo6qn_B.js"),__vite__mapDeps([294,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,269,201,180,202,190,161,157,151,137,136,152,153,158,131,159,160,98,162,163,24,25,164,165,166,29,30,167,135,168,169,170,147,171,130,172,173,174,149,175,133,176,138,177,109,102,110,111,178,179,34,181,106,107,7,182,21,183,184,141,185,186,187,188,189,191,192,193,145,203,204,97,17,273])))}),$le=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/hosting",staticData:{pageTitle:"common.mainPanelTabs.hosting",defaultMain:"hosting",mainView:"hosting"},component:Fe(()=>je(()=>import("./agent-hosting-5VKfgGQd.js"),__vite__mapDeps([295,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,21,252,97,14,187,29,30,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,34,180,283,177,178,179,131,98,181,106,182,183,184,165,174,147,17,290,190,202,159,161,33,130,139,144,204,193,291,292,191,195])))}),qle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/e2e",staticData:{pageTitle:"common.mainPanelTabs.e2e",defaultMain:"e2e",mainView:"e2e"},component:Fe(()=>je(()=>import("./agent-e2e-CyiK0Nn8.js"),__vite__mapDeps([296,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,21,97,29,30,14,252,187,167,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,34,180,283,177,178,179,131,98,181,106,182,183,184,165,174,147,17,290,190,202,159,161,33,130,139,144,204,193,291,292,191,195])))}),Vle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/analytics",staticData:{pageTitle:"common.mainPanelTabs.analytics",defaultMain:"analytics",mainView:"analytics"},validateSearch:we({view:q().optional()}),component:Fe(()=>je(()=>import("./agent-analytics-C1qxm1L0.js"),__vite__mapDeps([297,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,21,147,14,214,215,216,217,97,252,218,248,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,34,180,283,177,178,179,131,98,29,30,181,106,182,183,184,165,174,17,290,190,202,159,161,33,130,139,144,204,193,291,292,191,195])))}),Hle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/taskboard-analytics",staticData:{pageTitle:"taskBoard.analytics.title",defaultMain:"board",mainView:"board"},component:Fe(()=>je(()=>import("./taskboard-analytics-BnPIIn86.js"),__vite__mapDeps([298,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,240,182,21,227,241,130,139,30,232,242,214,215,216,217,14,225,24,25,128,124,243,244,245,246,247,218,248,129,228])))}),Gle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/experiments",staticData:{pageTitle:"common.mainPanelTabs.experiments",defaultMain:"experiments",mainView:"experiments"},validateSearch:we({ui:Ze("legacy").optional()}),component:Fe(()=>je(()=>import("./agent-experiments-Dero6WeN.js"),__vite__mapDeps([299,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,21,14,29,30,252,300,301,34,97,230,237,244,217,215,245,246,216,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,180,283,177,178,179,131,98,181,106,182,183,184,165,174,147,17,290,190,202,159,161,33,130,139,144,204,193,291,292,191,195])))}),Wle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/cdn",staticData:{pageTitle:"common.mainPanelTabs.cdn",defaultMain:"cdn",mainView:"cdn"},component:Fe(()=>je(()=>import("./agent-monitor-UjHCObOn.js"),__vite__mapDeps([302,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,214,215,216,217,252,130,218,248,247,245,246,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,97,34,180,283,177,178,179,131,98,29,30,181,106,182,21,183,184,165,174,147,17,290,190,202,159,161,33,139,144,204,193,291,292,191,195,256,176,138])))}),Kle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/apps/$connectionId/$toolName",staticData:{pageTitle:"page.app",defaultMain:"app",mainView:"app"},component:Fe(()=>je(()=>import("./agent-app-BN1xlwca.js"),__vite__mapDeps([303,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,203,304,158,202,188,189,190,151,137,136,152,153,129,124,95,100,101,102,103,98,104,105,106,107,7,108,109,110,111])))}),Yle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/views/$viewId",staticData:{pageTitle:"page.view",defaultMain:"view",mainView:"view"},component:Fe(()=>je(()=>import("./agent-view-vQcOlN6j.js"),__vite__mapDeps([305,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,304,158,202,188,189,190,151,137,136,152,153,129,124,95,100,101,102,103,98,104,105,106,107,7,108,109,110,111,288,282,16,289,25,97,34,180,283,177,178,179,131,29,30,181,182,21,183,184,165,174,147,17,290,159,161,33,130,139,144,204,193,291,292,191,195])))}),Zle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/outputs/file",staticData:{pageTitle:"page.file",defaultMain:"file",mainView:"file"},validateSearch:we({key:q().optional()}),component:Fe(()=>je(()=>import("./agent-file-Cao_W_me.js"),__vite__mapDeps([306,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,165,209,174,210,211,162,163,153,192,151,137,136,152,288,109,102,110,111,282,16,289,25,107,7,97,34,180,283,177,178,179,131,98,29,30,181,106,182,21,183,184,147,17,290,190,202,159,161,33,130,139,144,204,193,291,292,191,195])))}),Qle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/outputs/deck",staticData:{pageTitle:"page.document",defaultMain:"deck",mainView:"deck"},validateSearch:we({path:q().optional()}),component:Fe(()=>je(()=>import("./agent-deck-gN98WSbp.js"),__vite__mapDeps([307,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,208,174,130,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,97,34,180,283,177,178,179,131,98,29,30,181,106,182,21,183,184,165,147,17,290,190,202,159,161,33,139,144,204,193,291,292,191,195])))}),Jle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/library/file",staticData:{pageTitle:"page.file",defaultMain:"library-file",mainView:"library-file"},validateSearch:we({path:q().optional()}),component:Fe(()=>je(()=>import("./agent-library-file-lpnZiokW.js"),__vite__mapDeps([308,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,309,207,208,174,130,209,210,211,165,162,163,153,288,109,102,110,111,151,137,136,152,282,16,289,25,107,7,97,34,180,283,177,178,179,131,98,29,30,181,106,182,21,183,184,147,17,290,190,202,159,161,33,139,144,204,193,291,292,191,195])))}),Xle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/connect-sources",staticData:{pageTitle:"settings.nav.connect",defaultMain:"connect-sources",mainView:"connect-sources"},component:Fe(()=>je(()=>import("./agent-connect-sources-Cj-TiW7a.js"),__vite__mapDeps([310,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,99,95,100,101,102,103,98,104,105,106,107,7,108,109,110,111,155,112])))}),ece=Ne({getParentRoute:()=>Ro,path:"/$legacyView",component:()=>null}),tce=Ne({getParentRoute:()=>Mn,path:"/agents",validateSearch:rm,beforeLoad:({params:e,search:t})=>{const o=t.virtualmcpid?.trim();throw Jo(o?{to:"/$org/projects/$agentId",params:{org:e.org,agentId:o},search:a=>a,hash:!0,replace:!0}:{to:"/$org/projects",params:{org:e.org},search:a=>a,hash:!0,replace:!0})}}),oce=Ne({getParentRoute:()=>Mn,path:"/agents/$",validateSearch:rm,beforeLoad:({params:e,location:t})=>{const o=e._splat?.split("/").find(Boolean);if(!w3(o))return;const a=Xse(t.pathname);if(!a)return;const n=t.hash?`#${t.hash}`:"";throw Jo({href:`${a}${t.searchStr}${n}`,replace:!0})},component:Fe(()=>je(()=>import("./legacy-agents-deep-MO8oblzi.js"),__vite__mapDeps([311,205,70])))}),ace=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/tasks/{-$taskKey}",staticData:{pageTitle:"sidebar.navDestinations.tasks",defaultMain:"board",mainView:"board"},validateSearch:we({task:q().optional(),...ak}),beforeLoad:({params:e,search:t})=>{const o=T3(e.taskKey,t);if(o)throw Jo({to:"/$org/tasks/{-$taskKey}",params:{org:e.org,taskKey:o.taskKey},search:o.search,hash:!0,replace:!0})},component:Fe(()=>je(()=>import("./tasks-aFMERcVH.js"),__vite__mapDeps([312,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,226,124,125,227,228,130,160,158,98,161,162,163,153,24,25,137,151,136,152,173,229,21,33,34,174,219,26,230,140,141,175,133,29,30,129,128,231,232,233,187,234,235,236,197,237,180,103,238,184,186,188,189,190,191,159,192,165,183,200,169,166,239,256,176,138,257])))}),nce=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/taskboard-analytics",staticData:{defaultMain:"board",mainView:"board"},component:Fe(()=>je(()=>import("./taskboard-analytics-BnPIIn86.js"),__vite__mapDeps([298,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,240,182,21,227,241,130,139,30,232,242,214,215,216,217,14,225,24,25,128,124,243,244,245,246,247,218,248,129,228])))}),rce=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/thread-analytics",staticData:{defaultMain:"board",mainView:"board"},component:Fe(()=>je(()=>import("./thread-analytics-CN8JIWoa.js"),__vite__mapDeps([313,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,242,214,215,216,217,14,225,24,25,21,128,124,243,244,245,246,247,218,248,142,228,130,29,30,167,238,184,186,187,163,160,158,98,161,162,153,137,151,136,152,188,189,190,191,180,159,192,165,183,200])))}),ice=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/reports",staticData:{pageTitle:"sidebar.navDestinations.reports",defaultMain:"reports",mainView:"reports"},validateSearch:we({connect:kv().optional(),siteUrl:q().optional()}),component:Fe(()=>je(()=>import("./reports-Bj-OdndV.js"),__vite__mapDeps([314,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,259,95,154,101,102,103,221,112,113,223,143])))}),sce=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/library",staticData:{pageTitle:"sidebar.navDestinations.library",defaultMain:"files",mainView:"files"},validateSearch:we(nv),component:Fe(()=>je(()=>import("./library-CMmULIMr.js"),__vite__mapDeps([315,153,121,198,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,309,207,208,174,130,209,210,211,165,162,163,249,230,97,152,250,34,206,251,252,225,24,25,14,175,133])))}),lce=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/discover",staticData:{pageTitle:"sidebar.navDestinations.discover",defaultMain:"discover",mainView:"discover"},component:Fe(()=>je(()=>import("./discover-J_sID2RZ.js"),__vite__mapDeps([316,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,180,175,133,204,111])))}),cce=Ne({getParentRoute:()=>Zv,path:"/members",beforeLoad:({params:e})=>{throw Jo({to:"/$org/settings/members",params:{org:e.org}})}}),dce=we({main:io([q(),Ze(0)]).optional(),virtualmcpid:q().optional(),..._3,sidepanel:CL,mainpanel:EL,thread:q().optional()}),uce=Ne({getParentRoute:()=>Qv,path:"/",validateSearch:dce,pendingComponent:Md,component:Fe(()=>je(()=>import("./index-D-F3H3Df.js"),__vite__mapDeps([317,205,70])))}),pce=Ne({getParentRoute:()=>Qv,path:"/t/$taskKey",beforeLoad:({params:e})=>{throw Jo({to:"/$org/tasks/{-$taskKey}",params:{org:e.org,taskKey:e.taskKey},search:t=>t,hash:!0,replace:!0})}}),so=Ne({staticData:{pageTitle:"sidebar.navDestinations.settings"},getParentRoute:()=>Zv,path:"/settings",pendingComponent:Md,component:Fe(()=>je(()=>import("./route-3hj1gfVP.js"),__vite__mapDeps([318,121,198,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148])))}),mce=Ne({getParentRoute:()=>so,path:"/",component:Fe(()=>je(()=>import("./index-redirect-DnUfmxMQ.js"),__vite__mapDeps([319,320])))}),hce=Ne({staticData:{pageTitle:"settings.nav.connections"},getParentRoute:()=>so,path:"/connections",component:Fe(()=>je(()=>import("./connections-BYbkoIDQ.js"),__vite__mapDeps([321,109,102,110,111,322,15,55,84,31,225,21,17,18,182,178,85,86,179,82,74,45,41,42,43,44,46,47,39,48,32,49,40,50,51,52,53,54,56,57,58,59,60,61,62,63,20,64,65,16,323,97,183,121,131,98,28,29,30,34,180,68,8,67,190,66,181,106,107,7,147]))),validateSearch:Gr(()=>we({action:So(["create"]).optional(),tab:So(["all","connected"]).optional()}))}),gce=Ne({staticData:{pageTitle:"settings.nav.connections"},getParentRoute:()=>so,path:"/connections/$appSlug",component:Fe(()=>je(()=>import("./connection-detail-B7kDdVY9.js"),__vite__mapDeps([324,109,102,110,111,16,181,61,62,325,68,8,202,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,18,63,20,64,65,180,29,30,31,215,301,73,130,84,67,121,326,78,79,3,2,80,81,35,82,290,21,190,7,175,133,19,107,74,122,98,28,159,323,97,327,214,216,217,218,248,244,243,245,246,247,167,179,189,87]))),validateSearch:Gr(()=>we({tab:q().optional()}))}),fce=Ne({staticData:{pageTitle:"page.item"},getParentRoute:()=>so,path:"/connections/$appSlug/$collectionName/$itemId",component:Fe(()=>je(()=>import("./collection-detail-CDuDEGYz.js"),__vite__mapDeps([328,16,68,8,98,28,34,325,202,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,180,109,102,110,111,29,30,31,215,301,73,130,84,67,121,326,78,79,3,2,80,81,35,82,189,190,233,179,290,21,7,188,74,151,69,70,66,89,137,136,152,153,88,38,19,71,72,75,76,77,83,85,86,87,22,10,90,91,271,211,252]))),validateSearch:Gr(()=>we({replayId:q().optional()}))}),vce=Ne({staticData:{pageTitle:"orgs.monitoring.title"},getParentRoute:()=>so,path:"/monitor",component:Fe(()=>je(()=>import("./index-CX4bp0FC.js"),__vite__mapDeps([329,17,18,16,330,331,320,186,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,62,63,20,64,65,24,25,187,163,160,158,98,28,161,162,153,121,69,70,66,67,68,8,84,31,137,79,3,2,80,81,35,82,151,89,136,152,88,71,188,189,190,191,38,19,72,73,74,75,76,77,78,83,85,86,87,22,10,90,91,122,180,159,192,165,179,21,130,271,211,175,133,285,147,29,30,241,139,232,34,182,33,233,327,214,215,216,217,218,248,244,243,245,246,247,238,184,183,200,14,286,219]))),validateSearch:Gr(()=>we({tab:So(["overview","audit","dashboards","threads","automations"]).default("threads"),from:q().default("now-24h"),to:q().default("now"),connectionId:Be(q()).optional().default([]),virtualMcpId:Be(q()).optional().default([]),tool:q().default(""),status:So(["all","success","errors"]).default("all"),search:q().default(""),page:Mt().optional(),streaming:$t().default(!0),propertyFilters:q().default(""),hideSystem:$t().default(!1)}))}),bce=Ne({staticData:{pageTitle:"settings.nav.general"},getParentRoute:()=>so,path:"/general",component:Fe(()=>je(()=>import("./general-BMgatBn-.js"),__vite__mapDeps([332,133,283,19,20,333,33,40,88,35,81,272,180,68,8,334,21,29,30,31,32,97,320])))}),yce=Ne({staticData:{pageTitle:"settings.nav.connect"},getParentRoute:()=>so,path:"/connect",pendingComponent:Bi("connect"),component:Fe(()=>je(()=>import("./connect-Be6_BDOH.js"),__vite__mapDeps([335,233,21,29,30,31,32,167,163,50,56,57,222,336,42,61,62,97,28,68,8,330,331,320])))}),Sce=Ne({staticData:{pageTitle:"settings.nav.billing"},getParentRoute:()=>so,path:"/ai-providers",pendingComponent:Bi("billing"),component:Fe(()=>je(()=>import("./ai-providers-DQvwi-LI.js"),__vite__mapDeps([337,42,136,48,88,35,81,281,131,121,151,69,70,66,67,68,8,89,79,3,2,80,82,137,152,153,170,147,29,30,31,32,44,49,56,43,18,171,58,19,20,53,283,168,97,169,138,61,62,289,25,33,330,331,320])))}),wce=Ne({staticData:{pageTitle:"settings.nav.billing"},getParentRoute:()=>so,path:"/billing",beforeLoad:({params:e})=>{throw Jo({to:"/$org/settings/ai-providers",params:{org:e.org}})}}),Tce=Ne({staticData:{pageTitle:"settings.nav.billing"},getParentRoute:()=>so,path:"/infra-billing",pendingComponent:Bi("billing"),component:Fe(()=>je(()=>import("./infra-billing-51h8KhW5.js"),__vite__mapDeps([338,51,21,285,147,32,72,73,18,130,29,30,31,14,218,217,215,248,246,330,331,320])))}),xce=Ne({staticData:{pageTitle:"settings.nav.secrets"},getParentRoute:()=>so,path:"/secrets",component:Fe(()=>je(()=>import("./secrets-byDlZpmy.js"),__vite__mapDeps([339,42,61,20,64,28,29,30,31,32,34,292,330,331,320])))}),_ce=Ne({staticData:{pageTitle:"settings.nav.connect"},getParentRoute:()=>so,path:"/api-keys",pendingComponent:Bi("connect"),component:Fe(()=>je(()=>import("./api-keys-LZWLXizN.js"),__vite__mapDeps([340,336,42,50,56,61,62,97,28,68,8,330,331,320])))}),kce=Ne({staticData:{pageTitle:"settings.nav.storage"},getParentRoute:()=>so,path:"/buckets",pendingComponent:Bi("storage"),component:Fe(()=>je(()=>import("./buckets-Cczodic8.js"),__vite__mapDeps([341,42,61,62,97,28,29,30,31,32,33,34,120,330,331,320])))}),Cce=Ne({staticData:{pageTitle:"settings.nav.repositories"},getParentRoute:()=>so,path:"/repositories",validateSearch:we({git_error:q().optional().catch(void 0),git_flow:q().uuid().optional().catch(void 0),git_installation:Mt().int().positive().safe().optional().catch(void 0),git_return:$t().optional().catch(void 0)}),pendingComponent:Bi("repositories"),component:Fe(()=>je(()=>import("./repositories-Bt6nbmSu.js"),__vite__mapDeps([342,83,44,61,84,31,28,85,86,87,18,46,19,20,22,88,35,81,45,147,64,97,21,233,148,29,30,32,34,62,291,292,330,331,320])))}),Ece=Ne({staticData:{pageTitle:"settings.nav.storage"},getParentRoute:()=>so,path:"/synced-repos",pendingComponent:Bi("storage"),component:Fe(()=>je(()=>import("./synced-repos-MTGAuYvc.js"),__vite__mapDeps([343,61,97,83,44,84,31,28,85,86,87,18,46,19,20,22,88,35,81,250,24,25,330,331,320])))}),Pce=Ne({staticData:{pageTitle:"settings.nav.tasks"},getParentRoute:()=>so,path:"/task-board",component:Fe(()=>je(()=>import("./tasks-sExg1TPS.js"),__vite__mapDeps([344,147,34,49,60,61,228,72,73,18,130,285,21,32,29,30,31,33,97,284,333,40,88,35,81,272,180,68,8,22,219,229,65,148,84,122,174,85,86,80,2,330,331,320])))}),Ace=Ne({getParentRoute:()=>so,path:"/tasks",beforeLoad:({params:e})=>{throw Jo({to:"/$org/settings/task-board",params:{org:e.org}})}}),Rce=Ne({staticData:{pageTitle:"projects.settings.title"},getParentRoute:()=>so,path:"/projects",component:Fe(()=>je(()=>import("./projects-DvvpjGnZ.js"),__vite__mapDeps([345,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,21,17,76,28,77,68,8,78,67,79,3,2,80,81,35,82,83,84,31,85,86,87,19,22,88,223,289,25,154,101,102,103,143,66,180])))}),Dce=Ne({staticData:{pageTitle:"settings.nav.members"},getParentRoute:()=>so,path:"/members",pendingComponent:Bi("members"),component:Fe(()=>je(()=>import("./members-NF923Ad9.js"),__vite__mapDeps([346,322,15,55,84,31,225,21,17,18,13,14,16,132,98,28,29,30,32,34,133,134,19,20,24,25,26,175,347,97,52,56,62,65,147,72,73,130,61,231,330,331,320])))}),Oce=Ne({staticData:{pageTitle:"settings.nav.members"},getParentRoute:()=>so,path:"/roles",pendingComponent:Bi("members"),component:Fe(()=>je(()=>import("./roles-rqo1THOy.js"),__vite__mapDeps([348,134,133,347,21,97,52,61,62,13,14,15,16,17,18,171,74,45,41,42,43,44,46,47,39,48,32,49,40,50,51,53,54,55,56,57,58,59,60,63,20,64,65,183,147,184,86,68,8,87,110,111,175,26,180,67,136,19,33,84,31,75,66,331,320]))),validateSearch:Gr(()=>we({role:q().optional()}))}),Mce=Ne({staticData:{pageTitle:"settings.nav.security"},getParentRoute:()=>so,path:"/sso",component:Fe(()=>je(()=>import("./sso-Ba8xYn_P.js"),__vite__mapDeps([349,334,21,29,30,31,32,97,33,90,62,330,331,320])))}),Nce=Ne({staticData:{pageTitle:"settings.nav.profile"},getParentRoute:()=>so,path:"/profile",component:Fe(()=>je(()=>import("./profile-D0l--Bsl.js"),__vite__mapDeps([350,19,20,300,301,30,62,63,33,29,31,32,168,58,59,60,283,149])))}),Ice=Ne({staticData:{pageTitle:"settings.nav.agents"},getParentRoute:()=>so,path:"/agents",component:Fe(()=>je(()=>import("./agents-list-BKQ9GkqQ.js"),__vite__mapDeps([351,67,68,8,52,43,62,41,42,15,44,45,46,47,39,48,32,49,40,50,51,53,54,55,56,57,58,59,60,61,18,63,20,64,65,289,25,78,79,3,2,80,81,35,82,88,16,326,180,106,107,7,109,102,110,111,83,84,31,28,85,86,87,19,22,103,104,97,17,77])))}),Lce=Ne({staticData:{pageTitle:"settings.nav.automations"},getParentRoute:()=>so,path:"/automations",component:Fe(()=>je(()=>import("./automations-CVxx9AvI.js"),__vite__mapDeps([352,61,47,17,18,16,219,68,8,78,67,79,3,2,80,81,35,82,279,21,97,41,42,43,15,44,45,46,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,62,63,20,64,65,330,331,320])))}),Bce=Ne({staticData:{pageTitle:"settings.nav.skills"},getParentRoute:()=>so,path:"/skills",component:Fe(()=>je(()=>import("./skills-D04V2qi_.js"),__vite__mapDeps([353,52,47,62,63,17,18,97,16,182,21,251,162,163,50,153,121,69,70,66,67,68,8,209,174,85,86,210,53,211,165])))}),Fce=Ne({staticData:{pageTitle:"settings.nav.memory"},getParentRoute:()=>so,path:"/memory",component:Fe(()=>je(()=>import("./memory-CkWrgyW6.js"),__vite__mapDeps([354,39,20,233,84,31,182,21,16,71,174,85,86]))),validateSearch:Gr(()=>we({scope:So(["user"]).optional()}))}),jce=so.addChildren([mce,hce,gce,fce,Ice,Lce,Bce,Fce,vce,bce,yce,Sce,wce,Tce,xce,_ce,kce,Cce,Ece,Pce,Ace,Rce,Dce,Oce,Mce,Nce]),zce=Jv.addChildren([Nle,Ile,Lle]),Uce=Ro.addChildren([Dle,Ole,Mle,zce,Ble,Fle,jle,zle,Ule,$le,qle,Vle,Hle,Gle,Wle,Kle,Yle,Zle,Qle,Jle,Xle,ece]),$ce=Mn.addChildren([Ple,Ale,Rle,Uce,tce,oce,ace,nce,rce,ice,sce,lce]),qce=Qv.addChildren([uce,pce,$ce]),Vce=Zv.addChildren([qce,cce,jce]),Hce=nk.addChildren([Sle,Vce]),Gce=pn.addChildren([Hce,yle,wle,Tle,xle,_le,kle,cle,dle,ule,ple,mle,hle]);function Wce(){const e=Re.c(16),t=ar();let o;e[0]!==t?(o=t("common.index.pageNotFound"),e[0]=t,e[1]=o):o=e[1];let a;e[2]!==o?(a=w.jsx("h3",{className:"text-lg font-medium text-foreground",children:o}),e[2]=o,e[3]=a):a=e[3];let n;e[4]!==t?(n=t("common.index.pageNotFoundDescription"),e[4]=t,e[5]=n):n=e[5];let i;e[6]!==n?(i=w.jsx("p",{className:"text-sm text-muted-foreground text-center max-w-[300px]",children:n}),e[6]=n,e[7]=i):i=e[7];let l;e[8]!==t?(l=t("common.goBack"),e[8]=t,e[9]=l):l=e[9];let c;e[10]!==l?(c=w.jsx("button",{type:"button",onClick:Kce,className:"text-sm text-primary hover:underline",children:l}),e[10]=l,e[11]=c):c=e[11];let u;return e[12]!==a||e[13]!==i||e[14]!==c?(u=w.jsx("div",{className:"flex h-full items-center justify-center",children:w.jsxs("div",{className:"flex flex-col items-center gap-4 p-8",children:[a,i,c]})}),e[12]=a,e[13]=i,e[14]=c,e[15]=u):u=e[15],u}function Kce(){return window.history.back()}const Xv=F$({routeTree:Gce,defaultPendingComponent:Md,defaultPendingMs:200,defaultPendingMinMs:500,defaultNotFoundComponent:Wce});function Ee(...e){return kL(u_(e))}function Yce(e){return/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(e)}function $o({error:e,localization:t,localizeErrors:o=!0}){var a;const n="Request failed";if(!o)return e?.message?e.message:(a=e?.error)!=null&&a.message?e.error.message:n;if(typeof e=="string"&&t?.[e])return t[e];if(e?.error){if(e.error.code){const i=e.error.code;if(t?.[i])return t[i]}return e.error.message||e.error.code||e.error.statusText||t?.REQUEST_FAILED}return e?.message||t?.REQUEST_FAILED||n}function Ul(e){return typeof window<"u"?new URLSearchParams(window.location.search).get(e):null}function XT(e,t){for(const o in e)if(e[o]===t)return o}function Bp(e,t){let o=q().min(1,{message:t?.PASSWORD_REQUIRED});return e?.minLength&&(o=o.min(e.minLength,{message:t?.PASSWORD_TOO_SHORT})),e?.maxLength&&(o=o.max(e.maxLength,{message:t?.PASSWORD_TOO_LONG})),e?.regex&&(o=o.regex(e.regex,{message:t?.INVALID_PASSWORD})),o}var Zce={FAILED_TO_CREATE_USER:"Failed to create user",USER_ALREADY_EXISTS:"User already exists",YOU_CANNOT_BAN_YOURSELF:"You cannot ban yourself",YOU_ARE_NOT_ALLOWED_TO_CHANGE_USERS_ROLE:"You are not allowed to change users role",YOU_ARE_NOT_ALLOWED_TO_CREATE_USERS:"You are not allowed to create users",YOU_ARE_NOT_ALLOWED_TO_LIST_USERS:"You are not allowed to list users",YOU_ARE_NOT_ALLOWED_TO_LIST_USERS_SESSIONS:"You are not allowed to list users sessions",YOU_ARE_NOT_ALLOWED_TO_BAN_USERS:"You are not allowed to ban users",YOU_ARE_NOT_ALLOWED_TO_IMPERSONATE_USERS:"You are not allowed to impersonate users",YOU_ARE_NOT_ALLOWED_TO_REVOKE_USERS_SESSIONS:"You are not allowed to revoke users sessions",YOU_ARE_NOT_ALLOWED_TO_DELETE_USERS:"You are not allowed to delete users",YOU_ARE_NOT_ALLOWED_TO_SET_USERS_PASSWORD:"You are not allowed to set users password",BANNED_USER:"You have been banned from this application"},Qce={FAILED_TO_CREATE_USER:"Failed to create user",COULD_NOT_CREATE_SESSION:"Could not create session",ANONYMOUS_USERS_CANNOT_SIGN_IN_AGAIN_ANONYMOUSLY:"Anonymous users cannot sign in again anonymously"},Jce={INVALID_METADATA_TYPE:"metadata must be an object or undefined",REFILL_AMOUNT_AND_INTERVAL_REQUIRED:"refillAmount is required when refillInterval is provided",REFILL_INTERVAL_AND_AMOUNT_REQUIRED:"refillInterval is required when refillAmount is provided",USER_BANNED:"User is banned",UNAUTHORIZED_SESSION:"Unauthorized or invalid session",KEY_NOT_FOUND:"API Key not found",KEY_DISABLED:"API Key is disabled",KEY_EXPIRED:"API Key has expired",USAGE_EXCEEDED:"API Key has reached its usage limit",KEY_NOT_RECOVERABLE:"API Key is not recoverable",EXPIRES_IN_IS_TOO_SMALL:"The expiresIn is smaller than the predefined minimum value.",EXPIRES_IN_IS_TOO_LARGE:"The expiresIn is larger than the predefined maximum value.",INVALID_REMAINING:"The remaining count is either too large or too small.",INVALID_PREFIX_LENGTH:"The prefix length is either too large or too small.",INVALID_NAME_LENGTH:"The name length is either too large or too small.",METADATA_DISABLED:"Metadata is disabled.",RATE_LIMIT_EXCEEDED:"Rate limit exceeded.",NO_VALUES_TO_UPDATE:"No values to update.",KEY_DISABLED_EXPIRATION:"Custom key expiration values are disabled.",INVALID_API_KEY:"Invalid API key.",INVALID_USER_ID_FROM_API_KEY:"The user id from the API key is invalid.",INVALID_API_KEY_GETTER_RETURN_TYPE:"API Key getter returned an invalid key type. Expected string.",SERVER_ONLY_PROPERTY:"The property you're trying to set can only be set from the server auth instance only."},Xce={USER_NOT_FOUND:"User not found",FAILED_TO_CREATE_USER:"Failed to create user",FAILED_TO_CREATE_SESSION:"Failed to create session",FAILED_TO_UPDATE_USER:"Failed to update user",FAILED_TO_GET_SESSION:"Failed to get session",INVALID_PASSWORD:"Invalid password",INVALID_EMAIL:"Invalid email",INVALID_EMAIL_OR_PASSWORD:"Invalid email or password",SOCIAL_ACCOUNT_ALREADY_LINKED:"Social account already linked",PROVIDER_NOT_FOUND:"Provider not found",INVALID_TOKEN:"Invalid token",ID_TOKEN_NOT_SUPPORTED:"id_token not supported",FAILED_TO_GET_USER_INFO:"Failed to get user info",USER_EMAIL_NOT_FOUND:"User email not found",EMAIL_NOT_VERIFIED:"Email not verified",PASSWORD_TOO_SHORT:"Password too short",PASSWORD_TOO_LONG:"Password too long",USER_ALREADY_EXISTS:"User already exists",EMAIL_CAN_NOT_BE_UPDATED:"Email can not be updated",CREDENTIAL_ACCOUNT_NOT_FOUND:"Credential account not found",SESSION_EXPIRED:"Session expired. Re-authenticate to perform this action.",FAILED_TO_UNLINK_LAST_ACCOUNT:"You can't unlink your last account",ACCOUNT_NOT_FOUND:"Account not found",USER_ALREADY_HAS_PASSWORD:"User already has a password. Provide that to delete the account."},ede={VERIFICATION_FAILED:"Captcha verification failed",MISSING_RESPONSE:"Missing CAPTCHA response",UNKNOWN_ERROR:"Something went wrong"},tde={MISSING_SECRET_KEY:"Missing secret key",SERVICE_UNAVAILABLE:"CAPTCHA service unavailable"},ode={...ede,...tde},ade={OTP_EXPIRED:"otp expired",INVALID_OTP:"Invalid OTP",INVALID_EMAIL:"Invalid email",USER_NOT_FOUND:"User not found",TOO_MANY_ATTEMPTS:"Too many attempts"},nde={INVALID_OAUTH_CONFIGURATION:"Invalid OAuth configuration"},rde={PASSWORD_COMPROMISED:"The password you entered has been compromised. Please choose a different password."},ide={INVALID_SESSION_TOKEN:"Invalid session token"},sde={YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_ORGANIZATION:"You are not allowed to create a new organization",YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_ORGANIZATIONS:"You have reached the maximum number of organizations",ORGANIZATION_ALREADY_EXISTS:"Organization already exists",ORGANIZATION_NOT_FOUND:"Organization not found",USER_IS_NOT_A_MEMBER_OF_THE_ORGANIZATION:"User is not a member of the organization",YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_ORGANIZATION:"You are not allowed to update this organization",YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_ORGANIZATION:"You are not allowed to delete this organization",NO_ACTIVE_ORGANIZATION:"No active organization",USER_IS_ALREADY_A_MEMBER_OF_THIS_ORGANIZATION:"User is already a member of this organization",MEMBER_NOT_FOUND:"Member not found",ROLE_NOT_FOUND:"Role not found",YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM:"You are not allowed to create a new team",TEAM_ALREADY_EXISTS:"Team already exists",TEAM_NOT_FOUND:"Team not found",YOU_CANNOT_LEAVE_THE_ORGANIZATION_AS_THE_ONLY_OWNER:"You cannot leave the organization as the only owner",YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_MEMBER:"You are not allowed to delete this member",YOU_ARE_NOT_ALLOWED_TO_INVITE_USERS_TO_THIS_ORGANIZATION:"You are not allowed to invite users to this organization",USER_IS_ALREADY_INVITED_TO_THIS_ORGANIZATION:"User is already invited to this organization",INVITATION_NOT_FOUND:"Invitation not found",YOU_ARE_NOT_THE_RECIPIENT_OF_THE_INVITATION:"You are not the recipient of the invitation",YOU_ARE_NOT_ALLOWED_TO_CANCEL_THIS_INVITATION:"You are not allowed to cancel this invitation",INVITER_IS_NO_LONGER_A_MEMBER_OF_THE_ORGANIZATION:"Inviter is no longer a member of the organization",YOU_ARE_NOT_ALLOWED_TO_INVITE_USER_WITH_THIS_ROLE:"you are not allowed to invite user with this role",FAILED_TO_RETRIEVE_INVITATION:"Failed to retrieve invitation",YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_TEAMS:"You have reached the maximum number of teams",UNABLE_TO_REMOVE_LAST_TEAM:"Unable to remove last team",YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_MEMBER:"You are not allowed to update this member",ORGANIZATION_MEMBERSHIP_LIMIT_REACHED:"Organization membership limit reached",YOU_ARE_NOT_ALLOWED_TO_CREATE_TEAMS_IN_THIS_ORGANIZATION:"You are not allowed to create teams in this organization",YOU_ARE_NOT_ALLOWED_TO_DELETE_TEAMS_IN_THIS_ORGANIZATION:"You are not allowed to delete teams in this organization",YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_TEAM:"You are not allowed to update this team",YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_TEAM:"You are not allowed to delete this team",INVITATION_LIMIT_REACHED:"Invitation limit reached"},lde={CHALLENGE_NOT_FOUND:"Challenge not found",YOU_ARE_NOT_ALLOWED_TO_REGISTER_THIS_PASSKEY:"You are not allowed to register this passkey",FAILED_TO_VERIFY_REGISTRATION:"Failed to verify registration",PASSKEY_NOT_FOUND:"Passkey not found",AUTHENTICATION_FAILED:"Authentication failed",UNABLE_TO_CREATE_SESSION:"Unable to create session",FAILED_TO_UPDATE_PASSKEY:"Failed to update passkey"},cde={INVALID_PHONE_NUMBER:"Invalid phone number",PHONE_NUMBER_EXIST:"Phone number already exists",INVALID_PHONE_NUMBER_OR_PASSWORD:"Invalid phone number or password",UNEXPECTED_ERROR:"Unexpected error",OTP_NOT_FOUND:"OTP not found",OTP_EXPIRED:"OTP expired",INVALID_OTP:"Invalid OTP",PHONE_NUMBER_NOT_VERIFIED:"Phone number not verified"},dde={SUBSCRIPTION_NOT_FOUND:"Subscription not found",SUBSCRIPTION_PLAN_NOT_FOUND:"Subscription plan not found",ALREADY_SUBSCRIBED_PLAN:"You're already subscribed to this plan",UNABLE_TO_CREATE_CUSTOMER:"Unable to create customer",FAILED_TO_FETCH_PLANS:"Failed to fetch plans",EMAIL_VERIFICATION_REQUIRED:"Email verification is required before you can subscribe to a plan",SUBSCRIPTION_NOT_ACTIVE:"Subscription is not active",SUBSCRIPTION_NOT_SCHEDULED_FOR_CANCELLATION:"Subscription is not scheduled for cancellation"},ude={TEAM_LIMIT_REACHED:"Team limit reached for this organization",TEAM_MEMBER_LIMIT_REACHED:"Team member limit reached for this team",TEAM_NOT_FOUND:"Team not found",TEAM_MEMBER_NOT_FOUND:"Team member not found",TEAM_NAME_TOO_LONG:"Team name is too long",CANNOT_REMOVE_LAST_TEAM:"Cannot remove the last team",NOT_ORGANIZATION_MEMBER:"User is not a member of the organization",ALREADY_TEAM_MEMBER:"User is already a member of this team",INSUFFICIENT_TEAM_PERMISSIONS:"Insufficient permissions to perform this action on team"},pde={OTP_NOT_ENABLED:"OTP not enabled",OTP_HAS_EXPIRED:"OTP has expired",TOTP_NOT_ENABLED:"TOTP not enabled",TWO_FACTOR_NOT_ENABLED:"Two factor isn't enabled",BACKUP_CODES_NOT_ENABLED:"Backup codes aren't enabled",INVALID_BACKUP_CODE:"Invalid backup code",INVALID_CODE:"Invalid code",TOO_MANY_ATTEMPTS_REQUEST_NEW_CODE:"Too many attempts. Please request a new code.",INVALID_TWO_FACTOR_COOKIE:"Invalid two factor cookie"},mde={INVALID_USERNAME_OR_PASSWORD:"invalid username or password",EMAIL_NOT_VERIFIED:"email not verified",UNEXPECTED_ERROR:"unexpected error",USERNAME_IS_ALREADY_TAKEN:"username is already taken. please try another.",USERNAME_TOO_SHORT:"username is too short",USERNAME_TOO_LONG:"username is too long",INVALID_USERNAME:"username is invalid"},hde={APP:"App",ACCOUNT:"Account",ACCOUNTS:"Accounts",ACCOUNTS_DESCRIPTION:"Switch between your currently signed in accounts.",ACCOUNTS_INSTRUCTIONS:"Sign in to an additional account.",ADD_ACCOUNT:"Add Account",ADD_PASSKEY:"Add Passkey",ALREADY_HAVE_AN_ACCOUNT:"Already have an account?",AVATAR:"Avatar",AVATAR_DESCRIPTION:"Click on the avatar to upload a custom one from your files.",AVATAR_INSTRUCTIONS:"An avatar is optional but strongly recommended.",BACKUP_CODE_REQUIRED:"Backup code is required",BACKUP_CODES:"Backup Codes",BACKUP_CODES_DESCRIPTION:"Save these backup codes in a secure place. You can use them to access your account if you lose your two-factor authentication method.",BACKUP_CODE_PLACEHOLDER:"Backup Code",BACKUP_CODE:"Backup Code",CANCEL:"Cancel",CHANGE_PASSWORD:"Change Password",CHANGE_PASSWORD_DESCRIPTION:"Enter your current password and a new password.",CHANGE_PASSWORD_INSTRUCTIONS:"Please use 8 characters at minimum.",CHANGE_PASSWORD_SUCCESS:"Your password has been changed.",CONFIRM_PASSWORD:"Confirm Password",CONFIRM_PASSWORD_PLACEHOLDER:"Confirm Password",CONFIRM_PASSWORD_REQUIRED:"Confirm password is required",CONTINUE_WITH_AUTHENTICATOR:"Continue with Authenticator",COPIED_TO_CLIPBOARD:"Copied to clipboard",COPY_TO_CLIPBOARD:"Copy to clipboard",COPY_ALL_CODES:"Copy all codes",CONTINUE:"Continue",CURRENT_PASSWORD:"Current Password",CURRENT_PASSWORD_PLACEHOLDER:"Current Password",CURRENT_SESSION:"Current Session",UPDATE:"Update",DELETE:"Delete",DELETE_AVATAR:"Delete Avatar",DELETE_ACCOUNT:"Delete Account",DELETE_ACCOUNT_DESCRIPTION:"Permanently remove your account and all of its contents. This action is not reversible, so please continue with caution.",DELETE_ACCOUNT_INSTRUCTIONS:"Please confirm the deletion of your account. This action is not reversible, so please continue with caution.",DELETE_ACCOUNT_VERIFY:"Please check your email to verify the deletion of your account.",DELETE_ACCOUNT_SUCCESS:"Your account has been deleted.",DISABLE_TWO_FACTOR:"Disable Two-Factor",DISABLED_CREDENTIALS_DESCRIPTION:"Choose a provider to login to your account",DONT_HAVE_AN_ACCOUNT:"Don't have an account?",DONE:"Done",EMAIL:"Email",EMAIL_DESCRIPTION:"Enter the email address you want to use to log in.",EMAIL_INSTRUCTIONS:"Please enter a valid email address.",EMAIL_IS_THE_SAME:"Email is the same",EMAIL_PLACEHOLDER:"m@example.com",EMAIL_REQUIRED:"Email address is required",EMAIL_VERIFY_CHANGE:"Please check your email to verify the change.",EMAIL_VERIFICATION:"Email Verification",EMAIL_VERIFICATION_DESCRIPTION:"Please check your email for the verification code to complete your registration.",EMAIL_VERIFICATION_SUCCESS:"Email verification successful.",ENABLE_TWO_FACTOR:"Enable Two-Factor",IS_INVALID:"is invalid",IS_REQUIRED:"is required",IS_THE_SAME:"is the same",FORGOT_AUTHENTICATOR:"Forgot authenticator?",FORGOT_PASSWORD:"Forgot Password",FORGOT_PASSWORD_ACTION:"Send reset link",FORGOT_PASSWORD_DESCRIPTION:"Enter your email to reset your password",FORGOT_PASSWORD_EMAIL:"Check your email for the password reset link.",FORGOT_PASSWORD_LINK:"Forgot your password?",LINK:"Link",MAGIC_LINK:"Magic Link",MAGIC_LINK_ACTION:"Send magic link",MAGIC_LINK_DESCRIPTION:"Enter your email to receive a magic link",MAGIC_LINK_EMAIL:"Check your email for the magic link",EMAIL_OTP:"Email Code",EMAIL_OTP_SEND_ACTION:"Send code",EMAIL_OTP_VERIFY_ACTION:"Verify code",EMAIL_OTP_DESCRIPTION:"Enter your email to receive a code",EMAIL_OTP_VERIFICATION_SENT:"Please check your email for the verification code.",NAME:"Name",NAME_DESCRIPTION:"Please enter your full name, or a display name.",NAME_INSTRUCTIONS:"Please use 32 characters at maximum.",NAME_PLACEHOLDER:"Name",NEW_PASSWORD:"New Password",NEW_PASSWORD_PLACEHOLDER:"New Password",NEW_PASSWORD_REQUIRED:"New password is required",ONE_TIME_PASSWORD:"One-Time Password",OR_CONTINUE_WITH:"Or continue with",PASSKEY:"Passkey",PASSKEYS:"Passkeys",PASSKEYS_DESCRIPTION:"Manage your passkeys for secure access.",PASSKEYS_INSTRUCTIONS:"Securely access your account without a password.",PERSONAL_ACCOUNT:"Personal Account",API_KEYS:"API Keys",API_KEYS_DESCRIPTION:"Manage your API keys for secure access.",API_KEYS_INSTRUCTIONS:"Generate API keys to access your account programmatically.",CREATE_API_KEY:"Create API Key",CREATE_API_KEY_DESCRIPTION:"Enter a unique name for your API key to differentiate it from other keys.",API_KEY_NAME_PLACEHOLDER:"New API Key",API_KEY_CREATED:"API Key Created",CREATE_API_KEY_SUCCESS:"Please copy your API key and store it in a safe place. For security reasons we cannot show it again.",NEVER_EXPIRES:"Never Expires",EXPIRES:"Expires",NO_EXPIRATION:"No Expiration",CREATE_ORGANIZATION:"Create Organization",ORGANIZATION:"Organization",ORGANIZATION_NAME:"Name",ORGANIZATION_NAME_PLACEHOLDER:"Acme Inc.",ORGANIZATION_NAME_DESCRIPTION:"This is your organization's visible name.",ORGANIZATION_NAME_INSTRUCTIONS:"Please use 32 characters at maximum.",ORGANIZATION_SLUG:"Slug URL",ORGANIZATION_SLUG_DESCRIPTION:"This is your organization's URL namespace.",ORGANIZATION_SLUG_INSTRUCTIONS:"Please use 48 characters at maximum.",ORGANIZATION_SLUG_PLACEHOLDER:"acme-inc",CREATE_ORGANIZATION_SUCCESS:"Organization created successfully",PASSWORD:"Password",PASSWORD_PLACEHOLDER:"Password",PASSWORD_REQUIRED:"Password is required",PASSWORDS_DO_NOT_MATCH:"Passwords do not match",PROVIDERS:"Providers",PROVIDERS_DESCRIPTION:"Connect your account with a third-party service.",RECOVER_ACCOUNT:"Recover Account",RECOVER_ACCOUNT_ACTION:"Recover account",RECOVER_ACCOUNT_DESCRIPTION:"Please enter a backup code to access your account",REMEMBER_ME:"Remember me",RESEND_CODE:"Resend code",RESEND_VERIFICATION_EMAIL:"Resend Verification Email",RESET_PASSWORD:"Reset Password",RESET_PASSWORD_ACTION:"Save new password",RESET_PASSWORD_DESCRIPTION:"Enter your new password below",RESET_PASSWORD_SUCCESS:"Password reset successfully",REQUEST_FAILED:"Request failed",REVOKE:"Revoke",DELETE_API_KEY:"Delete API Key",DELETE_API_KEY_CONFIRM:"Are you sure you want to delete this API key?",API_KEY:"API Key",SIGN_IN:"Sign In",SIGN_IN_ACTION:"Login",SIGN_IN_DESCRIPTION:"Enter your email below to login to your account",SIGN_IN_USERNAME_DESCRIPTION:"Enter your username or email to login to your account",SIGN_IN_WITH:"Sign in with",SIGN_OUT:"Sign Out",SIGN_UP:"Sign Up",SIGN_UP_ACTION:"Create an account",SIGN_UP_DESCRIPTION:"Enter your information to create an account",SIGN_UP_EMAIL:"Check your email for the verification link.",SESSIONS:"Sessions",SESSIONS_DESCRIPTION:"Manage your active sessions and revoke access.",SET_PASSWORD:"Set Password",SET_PASSWORD_DESCRIPTION:"Click the button below to receive an email to set up a password for your account.",SETTINGS:"Settings",SAVE:"Save",SECURITY:"Security",SWITCH_ACCOUNT:"Switch Account",TRUST_DEVICE:"Trust this device",TWO_FACTOR:"Two-Factor",TWO_FACTOR_ACTION:"Verify code",TWO_FACTOR_DESCRIPTION:"Please enter your one-time password to continue",TWO_FACTOR_CARD_DESCRIPTION:"Add an extra layer of security to your account.",TWO_FACTOR_DISABLE_INSTRUCTIONS:"Please enter your password to disable 2FA.",TWO_FACTOR_ENABLE_INSTRUCTIONS:"Please enter your password to enable 2FA.",TWO_FACTOR_ENABLED:"Two-factor authentication has been enabled",TWO_FACTOR_DISABLED:"Two-Factor Authentication has been disabled",TWO_FACTOR_PROMPT:"Two-Factor Authentication",TWO_FACTOR_TOTP_LABEL:"Scan the QR Code with your Authenticator",SEND_VERIFICATION_CODE:"Send verification code",UNLINK:"Unlink",UPDATED_SUCCESSFULLY:"updated successfully",USERNAME:"Username",USERNAME_DESCRIPTION:"Enter the username you want to use to log in.",USERNAME_INSTRUCTIONS:"Please use 32 characters at maximum.",USERNAME_PLACEHOLDER:"Username",OPTIONAL_BRACKETS:"(Optional)",SIGN_IN_USERNAME_PLACEHOLDER:"Username or email",VERIFY_YOUR_EMAIL:"Verify Your Email",VERIFY_YOUR_EMAIL_DESCRIPTION:"Please verify your email address. Check your inbox for the verification email. If you haven't received the email, click the button below to resend.",GO_BACK:"Go back",SESSION_NOT_FRESH:"Your session is not fresh. Please sign in again.",UPLOAD_AVATAR:"Upload Avatar",LOGO:"Logo",LOGO_DESCRIPTION:"Click on the logo to upload a custom one from your files.",LOGO_INSTRUCTIONS:"A logo is optional but strongly recommended.",UPLOAD:"Upload",UPLOAD_LOGO:"Upload Logo",DELETE_LOGO:"Delete Logo",PRIVACY_POLICY:"Privacy Policy",TERMS_OF_SERVICE:"Terms of Service",PROTECTED_BY_RECAPTCHA:"This site is protected by reCAPTCHA.",BY_CONTINUING_YOU_AGREE:"By continuing, you agree to the",USER:"User",ORGANIZATIONS:"Organizations",ORGANIZATIONS_DESCRIPTION:"Manage your organizations and memberships.",ORGANIZATIONS_INSTRUCTIONS:"Create an organization to collaborate with other users.",LEAVE_ORGANIZATION:"Leave Organization",LEAVE_ORGANIZATION_CONFIRM:"Are you sure you want to leave this organization?",LEAVE_ORGANIZATION_SUCCESS:"You have successfully left the organization.",MANAGE_ORGANIZATION:"Manage Organization",REMOVE_MEMBER:"Remove Member",REMOVE_MEMBER_CONFIRM:"Are you sure you want to remove this member from the organization?",REMOVE_MEMBER_SUCCESS:"Member removed successfully",INVITE_MEMBER:"Invite Member",MEMBERS:"Members",MEMBERS_DESCRIPTION:"Add or remove members and manage their roles.",MEMBERS_INSTRUCTIONS:"Invite new members to your organization.",INVITE_MEMBER_DESCRIPTION:"Send an invitation to add a new member to your organization.",ROLE:"Role",SELECT_ROLE:"Select a role",ADMIN:"Admin",MEMBER:"Member",GUEST:"Guest",OWNER:"Owner",UPDATE_ROLE_DESCRIPTION:"Update the role for this member",UPDATE_ROLE:"Update Role",MEMBER_ROLE_UPDATED:"Member role updated successfully",SEND_INVITATION:"Send Invitation",SEND_INVITATION_SUCCESS:"Invitation sent successfully",PENDING_INVITATIONS:"Pending Invitations",PENDING_INVITATIONS_DESCRIPTION:"Manage pending invitations to your organization.",PENDING_USER_INVITATIONS_DESCRIPTION:"Invitations you've received from organizations.",CANCEL_INVITATION:"Cancel Invitation",INVITATION_CANCELLED:"Invitation cancelled successfully",ACCEPT_INVITATION:"Accept Invitation",ACCEPT_INVITATION_DESCRIPTION:"You have been invited to join an organization.",INVITATION_ACCEPTED:"Invitation accepted successfully",INVITATION_REJECTED:"Invitation rejected successfully",ACCEPT:"Accept",REJECT:"Reject",INVITATION_EXPIRED:"This invitation has expired",DELETE_ORGANIZATION:"Delete Organization",DELETE_ORGANIZATION_DESCRIPTION:"Permanently remove your organization and all of its contents. This action is not reversible — please continue with caution.",DELETE_ORGANIZATION_SUCCESS:"Organization deleted successfully",DELETE_ORGANIZATION_INSTRUCTIONS:"Enter the organization slug to continue:",SLUG_REQUIRED:"Organization slug is required",SLUG_DOES_NOT_MATCH:"The slug does not match",TEAM:"Team",TEAMS:"Teams",TEAM_ACTIVE:"Active",TEAM_SET_ACTIVE:"Set Active",CREATE_TEAM:"Create Team",CREATE_TEAM_SUCCESS:"Team created successfully",UPDATE_TEAM:"Update Team",UPDATE_TEAMS:"Update Teams",SELECT_TEAMS:"Select teams",ADD:"Add",REMOVE:"Remove",UPDATE_TEAM_DESCRIPTION:"Update the name for this team",UPDATE_TEAMS_DESCRIPTION:"Add or remove teams for this member",REMOVE_TEAM_CONFIRM:"Are you sure you want to remove this team from the organization?",CREATE_TEAM_INSTRUCTIONS:"Add new team to your organization.",TEAM_NAME:"Team Name",TEAM_NAME_PLACEHOLDER:"Engineering Team",TEAM_NAME_DESCRIPTION:"This is your team's visible name.",TEAM_NAME_INSTRUCTIONS:"Please use 64 characters at maximum.",TEAMS_DESCRIPTION:"Manage your teams within your organization.",USER_TEAMS_DESCRIPTION:"You are a member of the following teams.",DELETE_TEAM:"Delete Team",DELETE_TEAM_DESCRIPTION:"Permanently remove this team and all of its contents.",DELETE_TEAM_SUCCESS:"Team deleted successfully",DELETE_TEAM_INSTRUCTIONS:"Enter the team name to continue:",TEAM_NAME_REQUIRED:"Team name is required",TEAM_NAME_DOES_NOT_MATCH:"The team name does not match",TEAM_MEMBERS:"Team Members",TEAM_MEMBERS_DESCRIPTION:"Manage your team members and their roles.",ADD_TEAM_MEMBER:"Add Team Member",REMOVE_TEAM_MEMBER:"Remove Team Member",REMOVE_TEAM_MEMBER_CONFIRM:"Are you sure you want to remove this member from the team?",REMOVE_TEAM_MEMBER_SUCCESS:"Team member removed successfully",ADD_TEAM_MEMBER_SUCCESS:"Team member added successfully",UPDATE_TEAM_SUCCESS:"Team updated successfully",MANAGE_TEAM_MEMBERS:"Manage Team Members",MANAGE_TEAM_MEMBERS_DESCRIPTION:"Search and add organization members to this team.",NO_TEAMS_FOUND:"No teams found",MEMBER_SINGULAR:"member",MEMBER_PLURAL:"members",UNKNOWN:"Unknown",...Xce,...Zce,...Qce,...Jce,...ode,...ade,...nde,...rde,...ide,...sde,...lde,...cde,...dde,...ude,...pde,...mde},gde={CALLBACK:"callback",EMAIL_OTP:"email-otp",EMAIL_VERIFICATION:"email-verification",FORGOT_PASSWORD:"forgot-password",MAGIC_LINK:"magic-link",RECOVER_ACCOUNT:"recover-account",RESET_PASSWORD:"reset-password",SIGN_IN:"sign-in",SIGN_OUT:"sign-out",SIGN_UP:"sign-up",TWO_FACTOR:"two-factor",ACCEPT_INVITATION:"accept-invitation"},JO={SETTINGS:"settings",SECURITY:"security",TEAMS:"teams",API_KEYS:"api-keys",ORGANIZATIONS:"organizations"},XO={SETTINGS:"settings",MEMBERS:"members",TEAMS:"teams",API_KEYS:"api-keys"};const C3=A.createContext({});function E3(){return A.useContext(C3)}var j0,e2;function fde(){if(e2)return j0;e2=1;var e=function(){};return j0=e,j0}var vde=fde();const bde=Ml(vde);function yde({async:e,appendTo:t,defer:o,id:a,nonce:n,src:i}){const l=document.createElement("script");e!==void 0&&(l.async=e),o!==void 0&&(l.defer=o),a&&(l.id=a),n&&l.setAttribute("nonce",n),l.src=i,(t==="head"?document.head:document.body).appendChild(l)}var Sde=function(e,t){var o={};for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&t.indexOf(a)<0&&(o[a]=e[a]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,a=Object.getOwnPropertySymbols(e);n<a.length;n++)t.indexOf(a[n])<0&&Object.prototype.propertyIsEnumerable.call(e,a[n])&&(o[a[n]]=e[a[n]]);return o};let hp=null,Fp=!1;const rv=new Set,iv=new Set,wde=typeof window<"u",ud="___grecaptcha_cfg",P3=`onLoadCallback_${Math.random().toString(36).slice(2)}`;function Tde(){if(!wde)return;function e(o){if(Fp)o();else{window[ud]||(window[ud]={});const a=window[ud];a.fns||(a.fns=[]),a.fns.push(o)}}window.grecaptcha||(window.grecaptcha={}),window.grecaptcha.enterprise||(window.grecaptcha.enterprise={}),window.grecaptcha.ready=e,window.grecaptcha.enterprise.ready=e;function t(){Fp=!0;for(const o of iv)o();iv.clear()}window[P3]=t}function xde({language:e,onLoadCallbackName:t,render:o,useEnterprise:a=!1,useRecaptchaNet:n=!1}){const i=n?"recaptcha.net":"google.com",l=a?"enterprise.js":"api.js",c=new URLSearchParams({render:o});return t&&c.set("onload",t),e&&c.set("hl",e),`https://www.${i}/recaptcha/${l}?${c.toString()}`}function _de({language:e,render:t,scriptProps:o,useEnterprise:a,useRecaptchaNet:n}){const i={id:"google-recaptcha-v3"},l=xde({language:e,onLoadCallbackName:P3,render:t,useEnterprise:a,useRecaptchaNet:n});if(hp){if(hp!==l)throw new Error("reCAPTCHA has already been loaded with different parameters. Remove the existing script and load it again.");return}hp=l,yde(Object.assign(Object.assign(Object.assign({},i),o),{src:l}))}function kde(e){if(!window[ud])return;const t=window[ud];t.clients&&delete t.clients[e]}function Cde(e,t){var{onLoadCallback:o,onLoadCallbackName:a}=t,n=Sde(t,["onLoadCallback","onLoadCallbackName"]);if(rv.size===0&&Tde(),_de(n),rv.add(e),o&&(Fp?o():iv.add(o)),a){let i=function(){if(!a)return;const l=window[a];typeof l=="function"&&l()};Fp?i():iv.add(i)}}function Ede(e){var t,o,a;rv.delete(e),rv.size===0&&(window.grecaptcha=void 0,window[ud]=void 0,(t=document.querySelector(".grecaptcha-badge"))===null||t===void 0||t.remove(),(o=document.querySelector(`script[src="${hp}"]`))===null||o===void 0||o.remove(),(a=document.querySelector('script[src^="https://www.gstatic.com/recaptcha/releases"]'))===null||a===void 0||a.remove(),hp=null,Fp=!1)}let t2=!1;function Pde({container:e,children:t,language:o,reCaptchaKey:a,scriptProps:n,useEnterprise:i,useRecaptchaNet:l}){var c,u,p,m,h,f,v;const b=A.useId(),[S,_]=A.useState(null),[T,x]=A.useState(null),P=A.useRef(!1);A.useEffect(()=>{function D(){var O;const L=i?(O=window.grecaptcha)===null||O===void 0?void 0:O.enterprise:window.grecaptcha;if(!L)throw new Error("reCAPTCHA not found");if(!L.ready)throw new Error("reCAPTCHA ready callback not found");L.ready(()=>{_(L)})}return Cde(b,{language:o,onLoadCallback:D,onLoadCallbackName:n?.onLoadCallbackName,render:e?.element?"explicit":a,scriptProps:{appendTo:n?.appendTo,async:n?.async,defer:n?.defer,id:n?.id,nonce:n?.nonce},useEnterprise:i,useRecaptchaNet:l}),()=>{Ede(b),_(null)}},[e?.element,b,o,a,n?.appendTo,n?.async,n?.defer,n?.id,n?.nonce,n?.onLoadCallbackName,i,l]),A.useEffect(()=>{var D,O,L;if(!e?.element||!S?.render)return;const $={"error-callback":e.parameters.errorCallback,"expired-callback":e.parameters.expiredCallback,badge:((D=e.parameters)===null||D===void 0?void 0:D.badge)||"inline",callback:e.parameters.callback,sitekey:a,size:"invisible",tabindex:e.parameters.tabindex,theme:e.parameters.theme},B=typeof e?.element=="string"?document.getElementById(e.element):e?.element;if(!B)throw new Error("reCAPTCHA container element not found");const U=S.render(B,$);return!((O=e?.parameters)===null||O===void 0)&&O.hidden&&(t2||(bde(!1,"reCAPTCHA badge hidden. See https://cloud.google.com/recaptcha/docs/faq#id_like_to_hide_the_badge_what_is_allowed for more information."),t2=!0),(L=B.querySelector(".grecaptcha-badge"))===null||L===void 0||L.style.setProperty("display","none")),x(U),P.current=!0,()=>{x(null),P.current=!1,kde(U),B.innerHTML=""}},[e?.element,(c=e?.parameters)===null||c===void 0?void 0:c.badge,(u=e?.parameters)===null||u===void 0?void 0:u.hidden,(p=e?.parameters)===null||p===void 0?void 0:p.callback,(m=e?.parameters)===null||m===void 0?void 0:m.errorCallback,(h=e?.parameters)===null||h===void 0?void 0:h.expiredCallback,(f=e?.parameters)===null||f===void 0?void 0:f.tabindex,(v=e?.parameters)===null||v===void 0?void 0:v.theme,S,a]);const C=!!e?.element,E=C?T:a,R=A.useMemo(()=>E!==null&&S?.execute?D=>{if(E===null||!S?.execute)throw new Error("reCAPTCHA has not been loaded");return C&&!P.current?(console.warn("Client ID not mounted"),null):S.execute(E,{action:D})}:void 0,[E,S,C]);return w.jsx(C3.Provider,{value:{container:e?.element,executeRecaptcha:R,reCaptchaInstance:S},children:t})}var Ade=class{cache=new Map;listeners=new Map;inFlightRequests=new Map;get(e){return this.cache.get(e)}set(e,t){const o={data:t,timestamp:Date.now(),isRefetching:!1};this.cache.set(e,o),this.notify(e)}setRefetching(e,t){const o=this.cache.get(e);o&&(o.isRefetching=t,this.notify(e))}clear(e){if(e)this.cache.delete(e),this.inFlightRequests.delete(e),this.notify(e);else{this.cache.clear(),this.inFlightRequests.clear();const t=Array.from(this.listeners.keys());for(const o of t)this.notify(o)}}getInFlightRequest(e){return this.inFlightRequests.get(e)}setInFlightRequest(e,t){this.inFlightRequests.set(e,t)}removeInFlightRequest(e){this.inFlightRequests.delete(e)}subscribe(e,t){return this.listeners.has(e)||this.listeners.set(e,new Set),this.listeners.get(e).add(t),()=>{const o=this.listeners.get(e);o&&(o.delete(t),o.size===0&&this.listeners.delete(e))}}notify(e){const t=this.listeners.get(e);if(t){const o=Array.from(t);for(const a of o)a()}}},Gn=new Ade;function Rde(){return()=>{}}function Fi(){return A.useSyncExternalStore(Rde,()=>!0,()=>!1)}function A3(){const[e,t]=A.useState();return A.useEffect(()=>{const o=()=>{const n=document.documentElement.getAttribute("lang");t(n??void 0)};o();const a=new MutationObserver(n=>{for(const i of n)i.attributeName==="lang"&&o()});return a.observe(document.documentElement,{attributes:!0}),()=>{a.disconnect()}},[]),{lang:e}}function rk(){const[e,t]=A.useState("light");return A.useEffect(()=>{const o=()=>{var n;const i=document.documentElement.classList.contains("dark")||((n=document.documentElement.getAttribute("style"))==null?void 0:n.includes("color-scheme: dark"));t(i?"dark":"light")};o();const a=new MutationObserver(n=>{for(const i of n)(i.attributeName==="style"||i.attributeName==="class")&&o()});return a.observe(document.documentElement,{attributes:!0}),()=>{a.disconnect()}},[]),{theme:e}}function Dde({children:e}){const t=Fi(),{captcha:o}=A.useContext(St);return o?.provider!=="google-recaptcha-v3"?e:w.jsxs(Pde,{reCaptchaKey:o.siteKey,useEnterprise:o.enterprise,useRecaptchaNet:o.recaptchaNet,children:[t&&w.jsx("style",{children:`
168
+ `),h=u;m.length>h;h++){var f=m[h];if(1024>=f.length){var v=oO.test(f)?f.replace(oO,"$1"):f;if(!v.match(/\S*Error: /)){for(var b of i){var S=b(v,a);if(S){p.push(S);break}}if(p.length>=50)break}}}return(function(_){if(!_.length)return[];var T=Array.from(_);return T.reverse(),T.slice(0,50).map((x=>{return Me({},x,{filename:x.filename||(P=T,P[P.length-1]||{}).filename,function:x.function||xd});var P}))})(p)}})("web:javascript",ere,are)),this._instance=e,this.fo=(t=(o=this._instance.persistence)==null?void 0:o.get_property(TT))!==null&&t!==void 0?t:[],this.mo=zf(this.yo()),this.bo=new gre(this.mo)}onConfigChange(){this.mo=zf(this.yo()),this.bo.setConfig(this.mo)}onRemoteConfig(e){var t,o,a;if("errorTracking"in e){var n=(t=(o=e.errorTracking)==null?void 0:o.suppressionRules)!==null&&t!==void 0?t:[],i=(a=e.errorTracking)==null?void 0:a.captureExtensionExceptions;this.fo=n,this._instance.persistence&&this._instance.persistence.register({[TT]:this.fo,[xT]:i})}}get _o(){var e,t=!!this._instance.get_property(xT),o=this._instance.config.error_tracking.captureExtensionExceptions;return(e=o??t)!==null&&e!==void 0&&e}buildProperties(e,t){return this.po.buildFromUnknown(e,{syntheticException:t?.syntheticException,mechanism:{handled:t?.handled}})}addExceptionStep(e,t){if(this.mo.enabled)try{if(!ko(e)||e.trim().length===0)return void Ti.warn("Ignoring exception step because message must be a non-empty string");var o=this.wo(t),{sanitizedProperties:a,droppedKeys:n}=(function(i){if(!i)return{sanitizedProperties:{},droppedKeys:[]};var l=[];return{sanitizedProperties:Object.keys(i).reduce(((c,u)=>hre.has(u)?(l.push(u),c):(c[u]=i[u],c)),{}),droppedKeys:l}})(o);n.length>0&&Ti.warn("Ignoring reserved exception step fields",{droppedKeys:n}),this.bo.add(Me({[Ff]:e,[jf]:new Date().toISOString()},a))}catch(i){Ti.error("Failed to add exception step. Ignoring breadcrumb.",i)}}sendExceptionEvent(e){try{var t=e.$exception_list;if(this.Io(t)){if(this.Co(t))return this.So("Exception dropped: matched a suppression rule"),void Ti.info("Skipping exception capture because a suppression rule matched");if(!this._o&&this.xo(t))return this.So("Exception dropped: thrown by a browser extension"),void Ti.info("Skipping exception capture because it was thrown by an extension");if(!this._instance.config.error_tracking.__capturePostHogExceptions&&this.ko(t))return this.So("Exception dropped: thrown by the PostHog SDK"),void Ti.info("Skipping exception capture because it was thrown by the PostHog SDK")}var o=this.mo.enabled&&Ct(e.$exception_steps)?this.To(e):e;try{var a=this._instance.capture("$exception",o,{_noTruncate:!0,_batchKey:"exceptionEvent",en:!0});return a&&this.bo.clear(),a}catch(n){return Ti.error("Failed to capture exception event. Dropping this exception.",n),void this.bo.clear()}}catch(n){return void Ti.error("Failed to process exception event. Ignoring this exception.",n)}}To(e){try{var t=this.bo.getAttachable();return t.length===0?e:Me({},e,{$exception_steps:t})}catch(o){return Ti.error("Failed to read buffered exception steps. Capturing exception without steps.",o),e}}So(e){this.mo.enabled&&this.bo.add({[Ff]:e,[jf]:new Date().toISOString()})}wo(e){return Bo(e)?Me({},e):{}}yo(){var e,t;return(e=(t=this._instance.config.error_tracking)==null?void 0:t.exception_steps)!==null&&e!==void 0?e:{}}Co(e){if(e.length===0)return!1;var t=e.reduce(((o,a)=>{var{type:n,value:i}=a;return ko(n)&&n.length>0&&o.$exception_types.push(n),ko(i)&&i.length>0&&o.$exception_values.push(i),o}),{$exception_types:[],$exception_values:[]});return this.fo.some((o=>{var a=o.values.map((n=>{var i,l=Fj[n.operator],c=It(n.value)?n.value:[n.value],u=(i=t[n.key])!==null&&i!==void 0?i:[];return c.length>0&&l(c,u)}));return o.type==="OR"?a.some(Boolean):a.every(Boolean)}))}xo(e){return e.flatMap((t=>{var o,a;return(o=(a=t.stacktrace)==null?void 0:a.frames)!==null&&o!==void 0?o:[]})).some((t=>t.filename&&t.filename.startsWith("chrome-extension://")))}ko(e){if(e.length>0){var t,o,a,n,i=(t=(o=e[0].stacktrace)==null?void 0:o.frames)!==null&&t!==void 0?t:[],l=i[i.length-1];return(a=l==null||(n=l.filename)==null?void 0:n.includes("posthog.com/static"))!==null&&a!==void 0&&a}return!1}Io(e){return!Ct(e)&&It(e)}}},kie=Me({productTours:class{get ni(){return this._instance.persistence}constructor(e){this.Ao=null,this.Eo=null,this._instance=e}initialize(){this.loadIfEnabled()}onRemoteConfig(e){"productTours"in e&&(this.ni&&this.ni.register({[kT]:!!e.productTours}),this.loadIfEnabled())}loadIfEnabled(){var e,t;this.Ao||(e=this._instance).config.disable_product_tours||(t=e.persistence)==null||!t.get_property(kT)||this.ur((()=>this.Ro()))}ur(e){var t,o;(t=et.__PosthogExtensions__)!=null&&t.generateProductTours?e():(o=et.__PosthogExtensions__)==null||o.loadExternalDependency==null||o.loadExternalDependency(this._instance,"product-tours",(a=>{a?zO.error("Could not load product tours script",a):e()}))}Ro(){var e;!this.Ao&&(e=et.__PosthogExtensions__)!=null&&e.generateProductTours&&(this.Ao=et.__PosthogExtensions__.generateProductTours(this._instance,!0))}getProductTours(e,t){if(t===void 0&&(t=!1),!It(this.Eo)||t){var o=this.ni;if(o){var a=o.props[nf];if(It(a)&&!t)return this.Eo=a,void e(a,{isLoaded:!0})}this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/product_tours/?token="+this._instance.config.token),method:"GET",callback:n=>{var i=n.statusCode;if(i!==200||!n.json){var l="Product Tours API could not be loaded, status: "+i;return zO.error(l),void e([],{isLoaded:!1,error:l})}var c=It(n.json.product_tours)?n.json.product_tours:[];this.Eo=c,o&&o.register({[nf]:c}),e(c,{isLoaded:!0})}})}else e(this.Eo,{isLoaded:!0})}getActiveProductTours(e){Ct(this.Ao)?e([],{isLoaded:!1,error:"Product tours not loaded"}):this.Ao.getActiveProductTours(e)}showProductTour(e){var t;(t=this.Ao)==null||t.showTourById(e)}previewTour(e){this.Ao?this.Ao.previewTour(e):this.ur((()=>{var t;this.Ro(),(t=this.Ao)==null||t.previewTour(e)}))}dismissProductTour(){var e;(e=this.Ao)==null||e.dismissTour("user_clicked_skip")}nextStep(){var e;(e=this.Ao)==null||e.nextStep()}previousStep(){var e;(e=this.Ao)==null||e.previousStep()}clearCache(){var e;this.Eo=null,(e=this.ni)==null||e.unregister(nf)}resetTour(e){var t;(t=this.Ao)==null||t.resetTour(e)}resetAllTours(){var e;(e=this.Ao)==null||e.resetAllTours()}cancelPendingTour(e){var t;(t=this.Ao)==null||t.cancelPendingTour(e)}}},Hv),Cie={siteApps:class{constructor(e){this._instance=e,this.No=[],this.apps={}}get isEnabled(){return!!this._instance.config.opt_in_site_apps}Mo(e,t){if(t){var o=this.globalsForEvent(t);this.No.push(o),this.No.length>1e3&&(this.No=this.No.slice(10))}}get siteAppLoaders(){var e;return(e=et._POSTHOG_REMOTE_CONFIG)==null||(e=e[this._instance.config.token])==null?void 0:e.siteApps}initialize(){if(this.isEnabled){var e=this._instance._addCaptureHook(this.Mo.bind(this));this.Fo=()=>{e(),this.No=[],this.Fo=void 0}}}globalsForEvent(e){var t,o,a,n,i,l,c;if(!e)throw new Error("Event payload is required");var u={},p=this._instance.get_property("$groups")||[],m=this._instance.get_property("$stored_group_properties")||{};for(var[h,f]of Object.entries(m))u[h]={id:p[h],type:h,properties:f};var{$set_once:v,$set:b}=e;return{event:Me({},jF(e,fie),{properties:Me({},e.properties,b?{$set:Me({},(t=(o=e.properties)==null?void 0:o.$set)!==null&&t!==void 0?t:{},b)}:{},v?{$set_once:Me({},(a=(n=e.properties)==null?void 0:n.$set_once)!==null&&a!==void 0?a:{},v)}:{}),elements_chain:(i=(l=e.properties)==null?void 0:l.$elements_chain)!==null&&i!==void 0?i:"",distinct_id:(c=e.properties)==null?void 0:c.distinct_id}),person:{properties:this._instance.get_property("$stored_person_properties")},groups:u}}setupSiteApp(e){var t=this.apps[e.id],o=()=>{var l;!t.errored&&this.No.length&&(hs.info("Processing "+this.No.length+" events for site app with id "+e.id),this.No.forEach((c=>t.processEvent==null?void 0:t.processEvent(c))),t.processedBuffer=!0),Object.values(this.apps).every((c=>c.processedBuffer||c.errored))&&((l=this.Fo)==null||l.call(this))},a=!1,n=l=>{t.errored=!l,t.loaded=!0,hs.info("Site app with id "+e.id+" "+(l?"loaded":"errored")),a&&o()};try{var{processEvent:i}=e.init({posthog:this._instance,callback(l){n(l)}});i&&(t.processEvent=i),a=!0}catch(l){hs.error(UO+e.id,l),n(!1)}if(a&&t.loaded)try{o()}catch(l){hs.error("Error while processing buffered events PostHog app with config id "+e.id,l),t.errored=!0}}Oo(){var e=this.siteAppLoaders||[];for(var t of e)this.apps[t.id]={id:t.id,loaded:!1,errored:!1,processedBuffer:!1};for(var o of e)this.setupSiteApp(o)}Po(e){if(Object.keys(this.apps).length!==0){var t=this.globalsForEvent(e);for(var o of Object.values(this.apps))try{o.processEvent==null||o.processEvent(t)}catch(a){hs.error("Error while processing event "+e.event+" for site app "+o.id,a)}}}onRemoteConfig(e){var t,o,a,n=this;if((t=this.siteAppLoaders)!=null&&t.length)return this.isEnabled?(this.Oo(),void this._instance.on("eventCaptured",(u=>this.Po(u)))):void hs.error('PostHog site apps are disabled. Enable the "opt_in_site_apps" config to proceed.');if((o=this.Fo)==null||o.call(this),(a=e.siteApps)!=null&&a.length)if(this.isEnabled){var i=function(u){var p;et["__$$ph_site_app_"+u]=n._instance,(p=et.__PosthogExtensions__)==null||p.loadSiteApp==null||p.loadSiteApp(n._instance,c,(m=>{if(m)return hs.error(UO+u,m)}))};for(var{id:l,url:c}of e.siteApps)i(l)}else hs.error('PostHog site apps are disabled. Enable the "opt_in_site_apps" config to proceed.')}}},Eie={tracingHeaders:class{constructor(e){this.Lo=void 0,this.Do=void 0,this.so=()=>{var t,o,a=this.Bo()||[];qe(this.Lo)&&((t=et.__PosthogExtensions__)==null||(t=t.tracingHeadersPatchFns)==null||t._patchXHR(a,this._instance.get_distinct_id(),this._instance.sessionManager)),qe(this.Do)&&((o=et.__PosthogExtensions__)==null||(o=o.tracingHeadersPatchFns)==null||o._patchFetch(a,this._instance.get_distinct_id(),this._instance.sessionManager))},this._instance=e}initialize(){this.startIfEnabledOrStop()}ur(e){var t,o;(t=et.__PosthogExtensions__)!=null&&t.tracingHeadersPatchFns&&e(),(o=et.__PosthogExtensions__)==null||o.loadExternalDependency==null||o.loadExternalDependency(this._instance,"tracing-headers",(a=>{if(a)return hie.error("failed to load script",a);e()}))}Bo(){var e;return(e=this._instance.config.addTracingHeaders)!==null&&e!==void 0?e:this._instance.config.__add_tracing_headers}startIfEnabledOrStop(){var e,t;this.Bo()?this.ur(this.so):((e=this.Lo)==null||e.call(this),(t=this.Do)==null||t.call(this),this.Lo=void 0,this.Do=void 0)}}},Pie=Me({surveys:class{get Bt(){return this._instance.config}constructor(e){this.jo=void 0,this._surveyManager=null,this.$o=!1,this.qo=[],this.Zo=null,this._instance=e,this._surveyEventReceiver=null}initialize(){this.loadIfEnabled()}onRemoteConfig(e){if(!this.Bt.disable_surveys){var t=e.surveys;if(Ct(t))return to.warn("Flags not loaded yet. Not loading surveys.");var o=It(t);this.jo=o?t.length>0:t,to.info("flags response received, isSurveysEnabled: "+this.jo),this.loadIfEnabled()}}reset(){localStorage.removeItem("lastSeenSurveyDate");for(var e=[],t=0;t<localStorage.length;t++){var o=localStorage.key(t);(o!=null&&o.startsWith(HT)||o!=null&&o.startsWith("inProgressSurvey_"))&&e.push(o)}e.forEach((a=>localStorage.removeItem(a)))}loadIfEnabled(){if(!this._surveyManager)if(this.$o)to.info("Already initializing surveys, skipping...");else if(this.Bt.disable_surveys)to.info($O);else if(this.Bt.cookieless_mode&&this._instance.consent.isOptedOut())to.info("Not loading surveys in cookieless mode without consent.");else{var e=et?.__PosthogExtensions__;if(e){if(!qe(this.jo)||this.Bt.advanced_enable_surveys){var t=this.jo||this.Bt.advanced_enable_surveys;this.$o=!0;try{var o=e.generateSurveys;if(o)return void this.Vo(o,t);var a=e.loadExternalDependency;if(!a)return void this.Ho(G_);a(this._instance,"surveys",(n=>{n||!e.generateSurveys?this.Ho("Could not load surveys script",n):this.Vo(e.generateSurveys,t)}))}catch(n){throw this.Ho("Error initializing surveys",n),n}finally{this.$o=!1}}}else to.error("PostHog Extensions not found.")}}Vo(e,t){this._surveyManager=e(this._instance,t),this._surveyEventReceiver=new yie(this._instance),to.info("Surveys loaded successfully"),this.zo({isLoaded:!0})}Ho(e,t){to.error(e,t),this.zo({isLoaded:!1,error:e})}onSurveysLoaded(e){return this.qo.push(e),this._surveyManager&&this.zo({isLoaded:!0}),()=>{this.qo=this.qo.filter((t=>t!==e))}}getSurveys(e,t){if(t===void 0&&(t=!1),this.Bt.disable_surveys)return to.info($O),e([]);var o,a=this._instance.get_property(RT);if(a&&!t)return e(a,{isLoaded:!0});typeof Promise<"u"&&this.Zo?this.Zo.then((n=>{var{surveys:i,context:l}=n;return e(i,l)})):(typeof Promise<"u"&&(this.Zo=new Promise((n=>{o=n}))),this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/surveys/?token="+this.Bt.token),method:"GET",timeout:this.Bt.surveys_request_timeout_ms,callback:n=>{var i;this.Zo=null;var l=n.statusCode;if(l!==200||!n.json){var c="Surveys API could not be loaded, status: "+l;to.error(c);var u={isLoaded:!1,error:c};return e([],u),void(o==null||o({surveys:[],context:u}))}var p,m=n.json.surveys||[],h=m.filter((v=>(function(b){return!(!b.start_date||b.end_date)})(v)&&((function(b){var S;return!((S=b.conditions)==null||(S=S.events)==null||(S=S.values)==null||!S.length)})(v)||(function(b){var S;return!((S=b.conditions)==null||(S=S.actions)==null||(S=S.values)==null||!S.length)})(v))));h.length>0&&((p=this._surveyEventReceiver)==null||p.register(h)),(i=this._instance.persistence)==null||i.register({[RT]:m});var f={isLoaded:!0};e(m,f),o?.({surveys:m,context:f})}}))}zo(e){for(var t of this.qo)try{if(!e.isLoaded)return t([],e);this.getSurveys(t)}catch(o){to.error("Error in survey callback",o)}}getActiveMatchingSurveys(e,t){if(t===void 0&&(t=!1),!Ct(this._surveyManager))return this._surveyManager.getActiveMatchingSurveys(e,t);to.warn("init was not called")}Uo(e){var t=null;return this.getSurveys((o=>{var a;t=(a=o.find((n=>n.id===e)))!==null&&a!==void 0?a:null})),t}Yo(e){if(Ct(this._surveyManager))return{eligible:!1,reason:I0};var t=typeof e=="string"?this.Uo(e):e;return t?this._surveyManager.checkSurveyEligibility(t):{eligible:!1,reason:"Survey not found"}}canRenderSurvey(e){if(Ct(this._surveyManager))return to.warn("init was not called"),{visible:!1,disabledReason:I0};var t=this.Yo(e);return{visible:t.eligible,disabledReason:t.reason}}canRenderSurveyAsync(e,t){return Ct(this._surveyManager)?(to.warn("init was not called"),Promise.resolve({visible:!1,disabledReason:I0})):new Promise((o=>{this.getSurveys((a=>{var n,i=(n=a.find((c=>c.id===e)))!==null&&n!==void 0?n:null;if(i){var l=this.Yo(i);o({visible:l.eligible,disabledReason:l.reason})}else o({visible:!1,disabledReason:"Survey not found"})}),t)}))}renderSurvey(e,t,o){var a;if(Ct(this._surveyManager))to.warn("init was not called");else{var n=typeof e=="string"?this.Uo(e):e;if(n!=null&&n.id)if(Xre.includes(n.type)){var i=ze?.querySelector(t);if(i)return(a=n.appearance)!=null&&a.surveyPopupDelaySeconds?(to.info("Rendering survey "+n.id+" with delay of "+n.appearance.surveyPopupDelaySeconds+" seconds"),void setTimeout((()=>{var l,c;to.info("Rendering survey "+n.id+" with delay of "+((l=n.appearance)==null?void 0:l.surveyPopupDelaySeconds)+" seconds"),(c=this._surveyManager)==null||c.renderSurvey(n,i,o),to.info("Survey "+n.id+" rendered")}),1e3*n.appearance.surveyPopupDelaySeconds)):void this._surveyManager.renderSurvey(n,i,o);to.warn("Survey element not found")}else to.warn("Surveys of type "+n.type+" cannot be rendered in the app");else to.warn("Survey not found")}}displaySurvey(e,t){var o;if(Ct(this._surveyManager))to.warn("init was not called");else{var a=this.Uo(e);if(a){var n=a;if((o=a.appearance)!=null&&o.surveyPopupDelaySeconds&&t.ignoreDelay&&(n=Me({},a,{appearance:Me({},a.appearance,{surveyPopupDelaySeconds:0})})),t.displayType!==jT.Popover&&t.initialResponses&&to.warn("initialResponses is only supported for popover surveys. prefill will not be applied."),t.ignoreConditions===!1){var i=this.canRenderSurvey(a);if(!i.visible)return void to.warn("Survey is not eligible to be displayed: ",i.disabledReason)}t.displayType!==jT.Inline?this._surveyManager.handlePopoverSurvey(n,t):this.renderSurvey(n,t.selector,t.properties)}else to.warn("Survey not found")}}cancelPendingSurvey(e){Ct(this._surveyManager)?to.warn("init was not called"):this._surveyManager.cancelSurvey(e)}handlePageUnload(){var e;(e=this._surveyManager)==null||e.handlePageUnload()}}},Hv),Aie={toolbar:class{constructor(e){this.instance=e}Go(e){et.ph_toolbar_state=e}Wo(){var e;return(e=et.ph_toolbar_state)!==null&&e!==void 0?e:0}initialize(){return this.maybeLoadToolbar()}maybeLoadToolbar(e,t,o){if(e===void 0&&(e=void 0),t===void 0&&(t=void 0),o===void 0&&(o=void 0),yj(this.instance.config)||!ge||!ze)return!1;e=e??ge.location,o=o??ge.history;try{if(!t){try{ge.localStorage.setItem("test","test"),ge.localStorage.removeItem("test")}catch{return!1}t=ge?.localStorage}var a,n=Sie||Qf(e.hash,"__posthog")||Qf(e.hash,"state"),i=n?nO((()=>JSON.parse(atob(decodeURIComponent(n)))))||nO((()=>JSON.parse(decodeURIComponent(n)))):null;return i&&i.action==="ph_authorize"?((a=i).source="url",a&&Object.keys(a).length>0&&(i.desiredHash?e.hash=i.desiredHash:o?o.replaceState(o.state,"",e.pathname+e.search):e.hash="")):((a=JSON.parse(t.getItem(qO)||"{}")).source="localstorage",delete a.userIntent),!(!a.token||this.instance.config.token!==a.token||(this.loadToolbar(a),0))}catch{return!1}}Xo(e){var t=et.ph_load_toolbar||et.ph_load_editor;!Ct(t)&&_i(t)?t(e,this.instance):VO.warn("No toolbar load function found")}loadToolbar(e){var t=!(ze==null||!ze.getElementById(gj));if(!ge||t)return!1;var o=this.instance.requestRouter.region==="custom"&&this.instance.config.advanced_disable_toolbar_metrics,a=Me({token:this.instance.config.token},e,{apiURL:this.instance.requestRouter.endpointFor("ui")},o?{instrument:!1}:{});if(ge.localStorage.setItem(qO,JSON.stringify(Me({},a,{source:void 0}))),this.Wo()===2)this.Xo(a);else if(this.Wo()===0){var n;this.Go(1),(n=et.__PosthogExtensions__)==null||n.loadExternalDependency==null||n.loadExternalDependency(this.instance,"toolbar",(i=>{if(i)return VO.error("[Toolbar] Failed to load",i),void this.Go(0);this.Go(2),this.Xo(a)})),Zo(ge,"turbolinks:load",(()=>{this.Go(0),this.loadToolbar(a)}))}return!0}Jo(e){return this.loadToolbar(e)}maybeLoadEditor(e,t,o){return e===void 0&&(e=void 0),t===void 0&&(t=void 0),o===void 0&&(o=void 0),this.maybeLoadToolbar(e,t,o)}}},Rie=Me({experiments:Oa},Hv),Die={conversations:class{constructor(e){this.Ko=void 0,this._conversationsManager=null,this.Qo=!1,this.ea=null,this._instance=e}initialize(){this.loadIfEnabled()}onRemoteConfig(e){if(!this._instance.config.disable_conversations){var t=e.conversations;Ct(t)||($r(t)?this.Ko=t:(this.Ko=t.enabled,this.ea=t),this.loadIfEnabled())}}reset(){var e;(e=this._conversationsManager)==null||e.reset(),this._conversationsManager=null,this.Ko=void 0,this.ea=null}loadIfEnabled(){if(!(this._conversationsManager||this.Qo||this._instance.config.disable_conversations||yj(this._instance.config)||this._instance.config.cookieless_mode&&this._instance.consent.isOptedOut())){var e=et?.__PosthogExtensions__;if(e&&!qe(this.Ko)&&this.Ko)if(this.ea&&this.ea.token){this.Qo=!0;try{var t=e.initConversations;if(t)return this.ta(t),void(this.Qo=!1);var o=e.loadExternalDependency;if(!o)return void this.ra(G_);o(this._instance,"conversations",(a=>{a||!e.initConversations?this.ra("Could not load conversations script",a):this.ta(e.initConversations),this.Qo=!1}))}catch(a){this.ra("Error initializing conversations",a),this.Qo=!1}}else Hn.error("Conversations enabled but missing token in remote config.")}}ta(e){if(this.ea)try{this._conversationsManager=e(this.ea,this._instance),Hn.info("Conversations loaded successfully")}catch(t){this.ra("Error completing conversations initialization",t)}else Hn.error("Cannot complete initialization: remote config is null")}ra(e,t){Hn.error(e,t),this._conversationsManager=null,this.Qo=!1}show(){this._conversationsManager?this._conversationsManager.show():Hn.warn("Conversations not loaded yet.")}hide(){this._conversationsManager&&this._conversationsManager.hide()}isAvailable(){return this.Ko===!0&&!Ii(this._conversationsManager)}isVisible(){var e,t;return(e=(t=this._conversationsManager)==null?void 0:t.isVisible())!==null&&e!==void 0&&e}sendMessage(e,t,o){var a=this;return Kn((function*(){return a._conversationsManager?a._conversationsManager.sendMessage(e,t,o):(Hn.warn(ml),null)}))()}getMessages(e,t){var o=this;return Kn((function*(){return o._conversationsManager?o._conversationsManager.getMessages(e,t):(Hn.warn(ml),null)}))()}markAsRead(e){var t=this;return Kn((function*(){return t._conversationsManager?t._conversationsManager.markAsRead(e):(Hn.warn(ml),null)}))()}getTickets(e){var t=this;return Kn((function*(){return t._conversationsManager?t._conversationsManager.getTickets(e):(Hn.warn(ml),null)}))()}requestRestoreLink(e){var t=this;return Kn((function*(){return t._conversationsManager?t._conversationsManager.requestRestoreLink(e):(Hn.warn(ml),null)}))()}restoreFromToken(e){var t=this;return Kn((function*(){return t._conversationsManager?t._conversationsManager.restoreFromToken(e):(Hn.warn(ml),null)}))()}restoreFromUrlToken(){var e=this;return Kn((function*(){return e._conversationsManager?e._conversationsManager.restoreFromUrlToken():(Hn.warn(ml),null)}))()}getCurrentTicketId(){var e,t;return(e=(t=this._conversationsManager)==null?void 0:t.getCurrentTicketId())!==null&&e!==void 0?e:null}getWidgetSessionId(){var e,t;return(e=(t=this._conversationsManager)==null?void 0:t.getWidgetSessionId())!==null&&e!==void 0?e:null}un(){var e;(e=this._conversationsManager)==null||e.setIdentity()}hn(){var e;(e=this._conversationsManager)==null||e.clearIdentity()}}},Oie={logs:class{constructor(e){var t;this.ia=!1,this.na=!1,this.Gt=wo("[logs]"),this.sa=[],this.oa=0,this.aa=0,this.la=!1,this._instance=e,this._instance&&(t=this._instance.config.logs)!=null&&t.captureConsoleLogs&&(this.ia=!0)}initialize(){this.loadIfEnabled()}onRemoteConfig(e){var t,o=(t=e.logs)==null?void 0:t.captureConsoleLogs;!Ct(o)&&o&&(this.ia=!0,this.loadIfEnabled())}reset(){this.sa=[],this.jr&&(clearTimeout(this.jr),this.jr=void 0),this.oa=0,this.aa=0,this.la=!1}loadIfEnabled(){if(this.ia&&!this.na){var e=et?.__PosthogExtensions__;if(e){var t=e.loadExternalDependency;t?t(this._instance,"logs",(o=>{var a;o||(a=e.logs)==null||!a.initializeLogs?this.Gt.error("Could not load logs script",o):(e.logs.initializeLogs(this._instance),this.na=!0)})):this.Gt.error(G_)}else this.Gt.error("PostHog Extensions not found.")}}captureLog(e){var t,o,a,n,i,l;if(this._instance.is_capturing())if(e&&e.body){var c=(t=(o=this._instance.config.logs)==null?void 0:o.flushIntervalMs)!==null&&t!==void 0?t:3e3,u=(a=(n=this._instance.config.logs)==null?void 0:n.maxLogsPerInterval)!==null&&a!==void 0?a:1e3,p=Date.now();if(c>p-this.aa||(this.aa=p,this.oa=0,this.la=!1),u>this.oa){this.oa++;var m=(function(h,f){var v=h.level||"info",{text:b,number:S}=rj[v]||Kne,_=String(Date.now())+"000000",T={};f.distinctId&&(T.posthogDistinctId=f.distinctId),f.sessionId&&(T.sessionId=f.sessionId),f.currentUrl&&(T["url.full"]=f.currentUrl),f.screenName&&(T["screen.name"]=f.screenName),f.appState&&(T["app.state"]=f.appState),f.activeFeatureFlags&&f.activeFeatureFlags.length>0&&(T.feature_flags=f.activeFeatureFlags);var x=Me({},T,h.attributes||{}),P={timeUnixNano:_,observedTimeUnixNano:_,severityNumber:S,severityText:b,body:{stringValue:h.body},attributes:tO(x)};return h.trace_id&&(P.traceId=h.trace_id),h.span_id&&(P.spanId=h.span_id),qe(h.trace_flags)||(P.flags=h.trace_flags),P})(e,this.ua());this.sa.push({record:m}),((i=(l=this._instance.config.logs)==null?void 0:l.maxBufferSize)!==null&&i!==void 0?i:100)>this.sa.length?this.ha():this.flushLogs()}else this.la||(this.Gt.warn("captureLog dropping logs: exceeded "+u+" logs per "+c+"ms"),this.la=!0)}else this.Gt.warn("captureLog requires a body")}get logger(){return this.ca||(this.ca={trace:(e,t)=>this.captureLog({body:e,level:"trace",attributes:t}),debug:(e,t)=>this.captureLog({body:e,level:"debug",attributes:t}),info:(e,t)=>this.captureLog({body:e,level:"info",attributes:t}),warn:(e,t)=>this.captureLog({body:e,level:"warn",attributes:t}),error:(e,t)=>this.captureLog({body:e,level:"error",attributes:t}),fatal:(e,t)=>this.captureLog({body:e,level:"fatal",attributes:t})}),this.ca}flushLogs(e){if(this.jr&&(clearTimeout(this.jr),this.jr=void 0),this.sa.length!==0){var t=this.sa;this.sa=[];var o=this._instance.config.logs,a=Me({"service.name":o?.serviceName||"unknown_service"},o?.environment&&{"deployment.environment":o.environment},o?.serviceVersion&&{"service.version":o.serviceVersion},o?.resourceAttributes),n=(function(l,c,u,p){return{resourceLogs:[{resource:{attributes:tO(c)},scopeLogs:[{scope:{name:u,version:p},logRecords:l}]}]}})(t.map((l=>l.record)),a,Ga.LIB_NAME,Ga.LIB_VERSION),i=this._instance.requestRouter.endpointFor("api","/i/v1/logs")+"?token="+encodeURIComponent(this._instance.config.token);this._instance.Vi({method:"POST",url:i,data:n,compression:"best-available",batchKey:"logs",transport:e})}}ha(){var e,t;this.jr||(this.jr=setTimeout((()=>{this.jr=void 0,this.flushLogs()}),(e=(t=this._instance.config.logs)==null?void 0:t.flushIntervalMs)!==null&&e!==void 0?e:3e3))}ua(){var e,t={};if(t.distinctId=this._instance.get_distinct_id(),this._instance.sessionManager){var{sessionId:o}=this._instance.sessionManager.checkAndGetSessionAndWindowId(!0);t.sessionId=o}if(et!=null&&(e=et.location)!=null&&e.href&&(t.currentUrl=et.location.href),this._instance.featureFlags){var a=this._instance.featureFlags.getFlags();a&&a.length>0&&(t.activeFeatureFlags=a)}return t}}},Mie=Me({},Hv,Tie,xie,_ie,kie,Cie,Pie,Eie,Aie,Rie,Die,Oie);Yn.__defaultExtensionClasses=Me({},Mie);var KO,Li=(KO=pp[Yc]=new Yn,(function(){function e(){e.done||(e.done=!0,Uj=!1,go(pp,(function(t){t._dom_loaded()})))}ze!=null&&ze.addEventListener?ze.readyState==="complete"?e():Zo(ze,"DOMContentLoaded",e,{capture:!1}):ge&&Ue.error("Browser doesn't support `document.addEventListener` so PostHog couldn't be initialized")})(),KO);const Nie="studio-ui-resources",ov="html",Iie=10080*60*1e3,Lie=50,Bie=16*1024*1024;function Fie(e){return e[0]==="mcp"&&e[1]===$I}function Gv(){return new Promise((e,t)=>{const o=indexedDB.open(Nie,1);o.onupgradeneeded=()=>{o.result.objectStoreNames.contains(ov)||o.result.createObjectStore(ov)},o.onsuccess=()=>e(o.result),o.onerror=()=>t(o.error)})}function Cd(e,t){return e.transaction(ov,t).objectStore(ov)}function ZT(e){return new Promise((t,o)=>{e.onsuccess=()=>t(e.result),e.onerror=()=>o(e.error)})}async function jie(e){if(!(typeof indexedDB>"u"))try{const t=await Gv(),o=Cd(t,"readonly"),a=await ZT(o.getAllKeys()),n=await ZT(o.getAll()),i=Date.now(),l=a.map((p,m)=>({key:p,value:n[m]})).sort((p,m)=>(m.value?.updatedAt??0)-(p.value?.updatedAt??0)),c=[];let u=0;for(const{key:p,value:m}of l){if(!m||i-m.updatedAt>Iie||u>=Lie){c.push(p);continue}u++;try{const f=JSON.parse(String(p));e.getQueryData(f)===void 0&&e.setQueryData(f,m.html,{updatedAt:0})}catch{c.push(p)}}if(c.length>0){const p=Cd(t,"readwrite");for(const m of c)p.delete(m)}}catch{}}function zie(e){if(typeof indexedDB>"u")return()=>{};const t=Gv().catch(()=>null);return e.getQueryCache().subscribe(o=>{const a=o.query;if(!Array.isArray(a.queryKey)||!Fie(a.queryKey)||a.state.status!=="success")return;const n=a.state.data;typeof n!="string"||n.length>Bie||t.then(i=>{if(i)try{Cd(i,"readwrite").put({html:n,updatedAt:Date.now()},JSON.stringify(a.queryKey))}catch{}})})}function Uie(){typeof indexedDB>"u"||Gv().then(e=>Cd(e,"readwrite").clear()).catch(()=>{})}async function Fve(e){if(!(typeof indexedDB>"u"))try{const t=await Gv(),o=await ZT(Cd(t,"readonly").getAllKeys()),a=Cd(t,"readwrite");for(const n of o)try{const i=JSON.parse(String(n));i[1]===$I&&i[3]===e&&a.delete(n)}catch{}}catch{}}const av="studio:rq-cache",X_=1440*60*1e3,$ie=1e3,qie=new Set(["publicConfig","ai-provider-keys","organization-settings","home-next-actions"]),Vie=new Set(["VIRTUAL_MCP","CONNECTIONS"]);let Zj=!1,Qj=!1;function Hie(e){const t=e[0];return typeof t=="string"&&qie.has(t)?!0:e[3]==="collection"&&typeof e[4]=="string"&&Vie.has(e[4])}function Gie(e){if(!(typeof window>"u"))try{const t=window.localStorage.getItem(av);if(!t)return;const o=JSON.parse(t),a=!o.timestamp||Date.now()-o.timestamp>X_;if(o.buster!=="4.495.0"||a||!o.state){window.localStorage.removeItem(av);return}l8(e,o.state),e.invalidateQueries({queryKey:On.publicConfig(),refetchType:"none"}),Zj=!0}catch{Zie()}}function Wie(e){if(typeof window>"u")return()=>{};let t=null;const o=()=>{t=null;try{const i=s8(e,{shouldDehydrateQuery:l=>l.state.status==="success"&&Hie(l.queryKey)});window.localStorage.setItem(av,JSON.stringify({buster:"4.495.0",timestamp:Date.now(),state:i}))}catch{}},a=e.getQueryCache().subscribe(()=>{t==null&&(t=setTimeout(o,$ie))}),n=()=>{t!=null&&(clearTimeout(t),o())};return window.addEventListener("pagehide",n),()=>{t!=null&&clearTimeout(t),window.removeEventListener("pagehide",n),a()}}const Jj="studio:org-cache:",Kie=20;function Yie(e){const t=Date.now(),o=Object.entries(e).filter(([,a])=>t-a.updatedAt<=X_);for(o.sort(([,a],[,n])=>a.updatedAt-n.updatedAt);o.length>Kie;)o.shift();return Object.fromEntries(o)}function Xj(e){return`${Jj}${e}`}function jve(e,t){if(typeof window>"u")return null;try{const o=window.localStorage.getItem(Xj(e));if(!o)return null;const a=JSON.parse(o)[t];return!a||Date.now()-a.updatedAt>X_?null:(Qj=!0,a)}catch{return null}}function zve(e,t,o){if(!(typeof window>"u"))try{const a=Xj(e),n=window.localStorage.getItem(a),i=n?JSON.parse(n):{};i[t]={data:o,updatedAt:Date.now()},window.localStorage.setItem(a,JSON.stringify(Yie(i)))}catch{}}function Zie(){if(Uie(),!(typeof window>"u"))try{window.localStorage.removeItem(av);for(let e=window.localStorage.length-1;e>=0;e--){const t=window.localStorage.key(e);t?.startsWith(Jj)&&window.localStorage.removeItem(t)}}catch{}}function Qie(){return Zj}function Jie(){return Qj}let Di=!1,QT=null,YO=!1;const ek="studio:lp-distinct-id",e3="mesh:lp-distinct-id",B0="/api/_reports/link-token/",Xie=1440*60*1e3;function t3(e){const t="https://analytics.invalid",o=/^[a-z][a-z\d+.-]*:\/\//i.test(e),a=e.startsWith("//");try{const n=new URL(e,t);let i=!1;for(const l of["key","d"])n.searchParams.has(l)&&(n.searchParams.delete(l),i=!0);return n.pathname.startsWith(B0)&&n.pathname!==B0&&(n.pathname=`${B0}redacted`,i=!0),i?o?n.toString():a?`//${n.host}${n.pathname}${n.search}${n.hash}`:`${n.pathname}${n.search}${n.hash}`:e}catch{return e}}function F0(e){return Object.fromEntries(Object.entries(e).map(([t,o])=>[t,typeof o=="string"?t3(o):o]))}const ese=e=>e?(e.properties=F0(e.properties),e.$set&&(e.$set=F0(e.$set)),e.$set_once&&(e.$set_once=F0(e.$set_once)),e):null;function o3(){try{const e=window.localStorage.getItem(ek)??window.localStorage.getItem(e3);if(!e)return;const{id:t,ts:o}=JSON.parse(e);return typeof t!="string"||!t||typeof o!="number"?void 0:Date.now()-o<=Xie?t:void 0}catch{return}}function tse(){try{window.localStorage.removeItem(ek),window.localStorage.removeItem(e3)}catch{}}function ose(){try{const e=new URL(window.location.href),t=e.searchParams.get("ph_did");t&&(window.localStorage.setItem(ek,JSON.stringify({id:t,ts:Date.now()})),e.searchParams.delete("ph_did"),window.history.replaceState(window.history.state,"",e.toString()));const o=t??o3();return o?Object.keys(window.localStorage).some(n=>n.startsWith("ph_")&&n.endsWith("_posthog"))?void 0:o:void 0}catch{return}}function ase(e){const t=o3();if(t&&(tse(),t!==e))try{Li.alias(t)}catch{}}function nse(e,t){if(Di||typeof window>"u")return;const o=ose();Li.init(e,{api_host:t,ui_host:"https://us.posthog.com",cross_subdomain_cookie:!0,...o?{bootstrap:{distinctID:o}}:{},capture_pageview:"history_change",capture_pageleave:!0,autocapture:!0,before_send:ese,capture_performance:{web_vitals:!0,network_timing:!0},capture_exceptions:!0,session_recording:{maskAllInputs:!0,blockClass:"ph-no-capture",maskCapturedNetworkRequestFn:a=>({...a,...typeof a.name=="string"?{name:t3(a.name)}:{}})},person_profiles:"identified_only"}),Di=!0}function rse(e,t){Di&&(Li.identify(e,t),ase(e))}function ise(){Di&&(Li.reset(),QT=null)}function a3(e,t){Di&&Li.capture(e,t)}function Uve(){return Di}function $ve(){if(!Di||YO||typeof performance>"u")return;YO=!0;const e=performance.getEntriesByType("navigation")[0],t=o=>{const a=performance.getEntriesByName(o,"measure")[0];return a?Math.round(a.duration):void 0};a3("perf_app_bootstrap",{nav_type:e?.type,ttfb_ms:e?Math.round(e.responseStart):void 0,dom_interactive_ms:e?Math.round(e.domInteractive):void 0,dom_content_loaded_ms:e?Math.round(e.domContentLoadedEventEnd):void 0,config_fetch_ms:t("studio:config-fetch"),active_org_fetch_ms:t("studio:active-org-fetch"),time_to_shell_ms:Math.round(performance.now()),cache_restored:Qie(),org_cache_restored:Jie()})}function qve(e,t){Di&&e!==QT&&(Li.group("organization",e,t),QT=e)}function n3(e,t){if(Di)try{Li.captureException(e,t)}catch{}}const sse=["radial-gradient(ellipse 85% 85% at 0% 0%, rgba(165,149,255,0.6) 0%, transparent 72%)","radial-gradient(ellipse 85% 85% at 100% 100%, rgba(208,236,26,0.52) 0%, transparent 72%)","radial-gradient(ellipse 85% 85% at 0% 100%, rgba(255,193,22,0.48) 0%, transparent 72%)"].join(", ");function lse(e){const t=Re.c(3),{children:o}=e;let a;t[0]===Symbol.for("react.memo_cache_sentinel")?(a=w.jsx("div",{className:"absolute inset-0 pointer-events-none",style:{backgroundImage:sse}}),t[0]=a):a=t[0];let n;return t[1]!==o?(n=w.jsxs("div",{className:"relative flex items-center justify-center min-h-screen bg-background overflow-hidden",children:[a,w.jsx("div",{className:"relative flex flex-col items-center text-center space-y-4 max-w-sm px-6",children:o})]}),t[1]=o,t[2]=n):n=t[2],n}function r3(e){const t=Re.c(20),{orgName:o}=e,a=ar(),n=cse;let i;t[0]===Symbol.for("react.memo_cache_sentinel")?(i=w.jsx("div",{className:"bg-muted p-3 rounded-full","aria-hidden":"true",children:w.jsx(bF,{className:"h-6 w-6 text-muted-foreground"})}),t[0]=i):i=t[0];let l;t[1]!==a?(l=a("common.archivedOrgScreen.orgUnavailable"),t[1]=a,t[2]=l):l=t[2];let c;t[3]!==l?(c=w.jsx("h3",{className:"text-lg font-medium",children:l}),t[3]=l,t[4]=c):c=t[4];let u;t[5]!==o||t[6]!==a?(u=o?a("common.archivedOrgScreen.deletedWithName",{orgName:o}):a("common.archivedOrgScreen.deletedGeneric"),t[5]=o,t[6]=a,t[7]=u):u=t[7];let p;t[8]!==u?(p=w.jsx("p",{className:"text-sm text-muted-foreground",children:u}),t[8]=u,t[9]=p):p=t[9];let m;t[10]!==c||t[11]!==p?(m=w.jsxs("div",{className:"space-y-2",children:[c,p]}),t[10]=c,t[11]=p,t[12]=m):m=t[12];let h;t[13]!==a?(h=a("common.goHome"),t[13]=a,t[14]=h):h=t[14];let f;t[15]!==h?(f=w.jsx(Ri,{onClick:n,children:h}),t[15]=h,t[16]=f):f=t[16];let v;return t[17]!==m||t[18]!==f?(v=w.jsxs(lse,{children:[i,m,f]}),t[17]=m,t[18]=f,t[19]=v):v=t[19],v}function cse(){window.location.href="/"}function dse(){const e=Re.c(3);let t;e[0]===Symbol.for("react.memo_cache_sentinel")?(t={from:"/shell/$org"},e[0]=t):t=e[0];const{org:o}=Up(t);let a;return e[1]!==o?(a=w.jsx(Ri,{variant:"outline",size:"sm",asChild:!0,children:w.jsx(Nl,{to:"/$org/settings/profile",params:{org:o},children:"Go to your profile"})}),e[1]=o,e[2]=a):a=e[2],a}function use(e){const t=Re.c(13),{area:o,description:a,action:n}=e,i=o?`No access to ${o}`:"No access",l=a??"Your role doesn't include permission for this section. Ask an organization admin to update your role if you need it.";let c;t[0]===Symbol.for("react.memo_cache_sentinel")?(c=w.jsx("div",{className:"flex h-16 w-16 items-center justify-center rounded-full bg-muted text-muted-foreground",children:w.jsx(EF,{size:28})}),t[0]=c):c=t[0];let u;t[1]!==i?(u=w.jsx("h3",{className:"text-lg font-medium",children:i}),t[1]=i,t[2]=u):u=t[2];let p;t[3]!==l?(p=w.jsx("p",{className:"mx-auto max-w-sm text-sm text-muted-foreground",children:l}),t[3]=l,t[4]=p):p=t[4];let m;t[5]!==u||t[6]!==p?(m=w.jsxs("div",{className:"space-y-1",children:[u,p]}),t[5]=u,t[6]=p,t[7]=m):m=t[7];let h;t[8]!==n?(h=n??w.jsx(dse,{}),t[8]=n,t[9]=h):h=t[9];let f;return t[10]!==m||t[11]!==h?(f=w.jsxs("div",{className:"flex h-full min-h-[60vh] flex-1 flex-col items-center justify-center gap-4 p-6 text-center",children:[c,m,h]}),t[10]=m,t[11]=h,t[12]=f):f=t[12],f}const ZO="__studio_chunk_reload_ts";function i3(e){return e?.message===tQ}function pse(e){return!!e?.message?.includes("Access denied")}function QO(e){if(!e)return!1;const t=e.message||"";return t.includes("Failed to fetch dynamically imported module")||t.includes("Importing a module script failed")||t.includes("error loading dynamically imported module")||t.includes("Failed to fetch")&&e.name==="TypeError"}class mse extends A.Component{state={hasError:!1,error:null};static getDerivedStateFromError(t){return{hasError:!0,error:t}}componentDidCatch(t,o){console.error("Uncaught error:",t,o),n3(t,{boundary:"default",error_name:t.name,error_message:t.message,component_stack:o.componentStack??null,route:typeof window<"u"?window.location.pathname:null})}resetError=()=>{this.setState({hasError:!1,error:null})};render(){if(this.state.hasError){const{fallback:t,t:o}=this.props;return typeof t=="function"?t({error:this.state.error,resetError:this.resetError}):t!==void 0?t:i3(this.state.error)?w.jsx(r3,{}):pse(this.state.error)?w.jsx(use,{}):w.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center h-full p-6 text-center space-y-4",children:[w.jsx("div",{className:"bg-destructive/10 p-3 rounded-full",children:w.jsx(B_,{className:"h-6 w-6 text-destructive"})}),w.jsxs("div",{className:"space-y-2",children:[w.jsx("h3",{className:"text-lg font-medium",children:o("common.errorBoundary.somethingWentWrong")}),w.jsx("p",{className:"text-sm text-muted-foreground max-w-xs mx-auto",children:this.state.error?.message||o("common.errorBoundary.unexpectedError")})]}),w.jsx(Ri,{variant:"outline",onClick:this.resetError,children:o("common.errorBoundary.tryAgain")})]})}return this.props.children}}function hse(e){const t=Re.c(3),o=ar();let a;return t[0]!==e||t[1]!==o?(a=w.jsx(mse,{...e,t:o}),t[0]=e,t[1]=o,t[2]=a):a=t[2],a}class gse extends A.Component{state={hasError:!1,error:null};static getDerivedStateFromError(t){return{hasError:!0,error:t}}componentDidCatch(t,o){console.error("Uncaught error:",t,o);const a=QO(t);if(n3(t,{boundary:"chunk_root",is_chunk_load_error:a,error_name:t.name,error_message:t.message,component_stack:o.componentStack??null,route:typeof window<"u"?window.location.pathname:null}),!a)return;const n=sessionStorage.getItem(ZO),i=Date.now();(!n||i-Number(n)>1e4)&&(sessionStorage.setItem(ZO,String(i)),window.location.reload())}render(){const{t}=this.props;return this.state.hasError&&QO(this.state.error)?w.jsxs("div",{className:"flex min-h-dvh flex-col items-center justify-center p-6 text-center space-y-4",children:[w.jsx("div",{className:"bg-primary/10 p-3 rounded-full",children:w.jsx(PF,{className:"h-6 w-6 text-primary"})}),w.jsxs("div",{className:"space-y-2",children:[w.jsx("h3",{className:"text-lg font-medium",children:t("common.errorBoundary.newVersionAvailable")}),w.jsx("p",{className:"text-sm text-muted-foreground max-w-xs mx-auto",children:t("common.errorBoundary.newVersionDeployed")})]}),w.jsx(Ri,{onClick:()=>window.location.reload(),children:t("common.errorBoundary.refresh")})]}):this.state.hasError?i3(this.state.error)?w.jsx(r3,{}):w.jsxs("div",{className:"flex min-h-dvh flex-col items-center justify-center p-6 text-center space-y-4",children:[w.jsx("div",{className:"bg-destructive/10 p-3 rounded-full",children:w.jsx(B_,{className:"h-6 w-6 text-destructive"})}),w.jsxs("div",{className:"space-y-2",children:[w.jsx("h3",{className:"text-lg font-medium",children:t("common.errorBoundary.somethingWentWrong")}),w.jsx("p",{className:"text-sm text-muted-foreground max-w-xs mx-auto",children:this.state.error?.message||t("common.errorBoundary.unexpectedError")})]}),w.jsx(Ri,{variant:"outline",onClick:()=>this.setState({hasError:!1,error:null}),children:t("common.errorBoundary.tryAgain")})]}):this.props.children}}function fse(e){const t=Re.c(3),o=ar();let a;return t[0]!==e||t[1]!==o?(a=w.jsx(gse,{...e,t:o}),t[0]=e,t[1]=o,t[2]=a):a=t[2],a}function vse(e){const t=Re.c(8);let o,a;t[0]!==e?({className:o,...a}=e,t[0]=e,t[1]=o,t[2]=a):(o=t[1],a=t[2]);let n;t[3]!==o?(n=gt("surface flex flex-col gap-6",o),t[3]=o,t[4]=n):n=t[4];let i;return t[5]!==a||t[6]!==n?(i=w.jsx("div",{"data-slot":"card",className:n,...a}),t[5]=a,t[6]=n,t[7]=i):i=t[7],i}function Vve(e){const t=Re.c(4);let o;t[0]!==e?({...o}=e,t[0]=e,t[1]=o):o=t[1];let a;return t[2]!==o?(a=w.jsx("div",{"data-slot":"card-content",...o}),t[2]=o,t[3]=a):a=t[3],a}function Hve(e){const t=Re.c(12),{title:o,description:a,docsHref:n,actions:i,className:l,headerClassName:c,children:u}=e;let p;t[0]!==l?(p=gt("flex flex-col gap-3",l),t[0]=l,t[1]=p):p=t[1];let m;t[2]!==i||t[3]!==a||t[4]!==n||t[5]!==c||t[6]!==o?(m=(o||a||n||i)&&w.jsxs("div",{className:gt("flex items-center justify-between gap-3 px-4",c),children:[w.jsxs("div",{className:"flex flex-col gap-1 min-w-0",children:[o&&w.jsx("h2",{className:"text-[15px] font-medium leading-tight",children:o}),(a||n)&&w.jsxs("p",{className:"text-sm text-muted-foreground leading-snug",children:[a,n&&w.jsxs("a",{href:n,target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-0.5 ml-1 text-foreground hover:underline",children:["Docs ",w.jsx(yF,{size:12})]})]})]}),i&&w.jsx("div",{className:"shrink-0",children:i})]}),t[2]=i,t[3]=a,t[4]=n,t[5]=c,t[6]=o,t[7]=m):m=t[7];let h;return t[8]!==u||t[9]!==p||t[10]!==m?(h=w.jsxs("section",{className:p,children:[m,u]}),t[8]=u,t[9]=p,t[10]=m,t[11]=h):h=t[11],h}function Gve(e){const t=Re.c(11),{className:o,children:a}=e;let n,i,l;if(t[0]!==a||t[1]!==o){const u=A.Children.toArray(a).filter(A.isValidElement);n=vse,t[5]!==o?(i=gt("p-0 gap-0 overflow-hidden",o),t[5]=o,t[6]=i):i=t[6],l=u.map(bse),t[0]=a,t[1]=o,t[2]=n,t[3]=i,t[4]=l}else n=t[2],i=t[3],l=t[4];let c;return t[7]!==n||t[8]!==i||t[9]!==l?(c=w.jsx(n,{className:i,children:l}),t[7]=n,t[8]=i,t[9]=l,t[10]=c):c=t[10],c}function bse(e,t){return w.jsxs("div",{children:[t>0&&w.jsx("div",{className:"h-px bg-border mx-5"}),e]},t)}function Wve(e){const t=Re.c(27),{icon:o,title:a,description:n,action:i,onClick:l,className:c,children:u}=e,p=u?"flex items-start gap-3 px-4 py-4":"flex items-center gap-3 px-4 py-4",m=l&&"hover:bg-muted/50 cursor-pointer";let h;t[0]!==c||t[1]!==p||t[2]!==m?(h=gt(p,m,c),t[0]=c,t[1]=p,t[2]=m,t[3]=h):h=t[3];const f=l?"button":void 0,v=l?0:void 0;let b;t[4]!==l?(b=l?E=>{E.target===E.currentTarget&&(E.key==="Enter"||E.key===" ")&&(E.preventDefault(),l())}:void 0,t[4]=l,t[5]=b):b=t[5];let S;t[6]!==o?(S=o&&w.jsx("div",{className:"size-8 shrink-0 rounded-lg bg-muted/60 flex items-center justify-center text-muted-foreground",children:o}),t[6]=o,t[7]=S):S=t[7];let _;t[8]!==a?(_=w.jsx("div",{className:"text-sm font-medium",children:a}),t[8]=a,t[9]=_):_=t[9];let T;t[10]!==n?(T=n&&w.jsx("p",{className:"text-xs text-muted-foreground mt-0.5 leading-relaxed",children:n}),t[10]=n,t[11]=T):T=t[11];let x;t[12]!==u||t[13]!==_||t[14]!==T?(x=w.jsxs("div",{className:"flex-1 min-w-0",children:[_,T,u]}),t[12]=u,t[13]=_,t[14]=T,t[15]=x):x=t[15];let P;t[16]!==i?(P=i&&w.jsx("div",{className:"shrink-0",onClick:yse,children:i}),t[16]=i,t[17]=P):P=t[17];let C;return t[18]!==l||t[19]!==x||t[20]!==P||t[21]!==h||t[22]!==f||t[23]!==v||t[24]!==b||t[25]!==S?(C=w.jsxs("div",{className:h,onClick:l,role:f,tabIndex:v,onKeyDown:b,children:[S,x,P]}),t[18]=l,t[19]=x,t[20]=P,t[21]=h,t[22]=f,t[23]=v,t[24]=b,t[25]=S,t[26]=C):C=t[26],C}function yse(e){return e.stopPropagation()}function Kve(e){const t=Re.c(5),{className:o,children:a}=e;let n;t[0]!==o?(n=gt("px-4 py-4",o),t[0]=o,t[1]=n):n=t[1];let i;return t[2]!==a||t[3]!==n?(i=w.jsx("div",{className:n,children:a}),t[2]=a,t[3]=n,t[4]=i):i=t[4],i}function Yve(e){const t=Re.c(5),{children:o,className:a}=e;let n;t[0]!==a?(n=gt("flex items-center justify-end gap-2 px-4 py-4",a),t[0]=a,t[1]=n):n=t[1];let i;return t[2]!==o||t[3]!==n?(i=w.jsx("div",{className:n,children:o}),t[2]=o,t[3]=n,t[4]=i):i=t[4],i}function Sse(e){const t=Re.c(5),{className:o,children:a}=e;let n;t[0]!==o?(n=gt("flex flex-col gap-10",o),t[0]=o,t[1]=n):n=t[1];let i;return t[2]!==a||t[3]!==n?(i=w.jsx("div",{className:n,children:a}),t[2]=a,t[3]=n,t[4]=i):i=t[4],i}const Wv={connect:{key:"connect",titleKey:"settings.connectClients.pageTitle",tabs:[],ownedRoutes:["/$org/settings/api-keys"]},members:{key:"members",titleKey:"orgs.members.title",tabs:[{key:"members",icon:DF,labelKey:"orgs.members.title",to:"/$org/settings/members",requires:"members:manage"},{key:"roles",icon:RF,labelKey:"settings.roles.pageTitle",to:"/$org/settings/roles",privilegedOnly:!0}]},billing:{key:"billing",titleKey:"settings.nav.billing",tabs:[{key:"ai-providers",icon:TF,labelKey:"settings.nav.aiProviders",to:"/$org/settings/ai-providers",requires:"ai-providers:manage"},{key:"infra",icon:AF,labelKey:"settings.subnav.infrastructure",to:"/$org/settings/infra-billing",requires:"members:manage",requiresOwnedSites:!0}]},repositories:{key:"repositories",titleKey:"settings.nav.repositories",tabs:[],ownedRoutes:["/$org/settings/repositories"]},storage:{key:"storage",titleKey:"settings.nav.storage",tabs:[{key:"buckets",icon:kF,labelKey:"settings.nav.buckets",to:"/$org/settings/buckets",requires:"file-configs:manage"},{key:"synced-repos",icon:_F,labelKey:"settings.nav.syncedRepos",to:"/$org/settings/synced-repos",requires:"file-configs:manage"}]}};function Zve(e){const t=Wv[e];return[...t.tabs.map(o=>o.to),...t.ownedRoutes??[]]}function Qve(e){return Wv[e].tabs.length>0}const wse=new Set(["owner","admin"]);function s3(){const e=Re.c(11),{org:t,locator:o}=Zp();let a;e[0]!==o?(a=On.myCapabilities(o),e[0]=o,e[1]=a):a=e[1];let n;e[2]!==t?(n=async()=>{const m=await fetch(`/api/auth/custom/my-capabilities/${encodeURIComponent(t.slug)}`,{credentials:"include"});if(!m.ok)throw new Error(`my-capabilities request failed: ${m.status}`);return await m.json()},e[2]=t,e[3]=n):n=e[3];let i;e[4]!==a||e[5]!==n?(i={queryKey:a,queryFn:n,staleTime:3e4,retry:2},e[4]=a,e[5]=n,e[6]=i):i=e[6];const{data:l,isLoading:c,isError:u}=Rd(i);let p;return e[7]!==l||e[8]!==u||e[9]!==c?(p={data:l,loading:c,error:u},e[7]=l,e[8]=u,e[9]=c,e[10]=p):p=e[10],p}function Jve(e){const t=Re.c(8),{data:o,loading:a,error:n}=s3();if(a){let p;return t[0]===Symbol.for("react.memo_cache_sentinel")?(p={granted:!1,loading:!0,error:!1,reason:"loading"},t[0]=p):p=t[0],p}if(n){let p;return t[1]===Symbol.for("react.memo_cache_sentinel")?(p={granted:!1,loading:!1,error:!0,reason:"error"},t[1]=p):p=t[1],p}const i=o?.role??null;if(!i){let p;return t[2]===Symbol.for("react.memo_cache_sentinel")?(p={granted:!1,loading:!1,error:!1,reason:"denied"},t[2]=p):p=t[2],p}if(i==="owner"){let p;return t[3]===Symbol.for("react.memo_cache_sentinel")?(p={granted:!0,loading:!1,error:!1,reason:"owner"},t[3]=p):p=t[3],p}if(i==="admin"){let p;return t[4]===Symbol.for("react.memo_cache_sentinel")?(p={granted:!0,loading:!1,error:!1,reason:"admin"},t[4]=p):p=t[4],p}const l=o?.capabilities?.[e]===!0,c=l?"role":"denied";let u;return t[5]!==l||t[6]!==c?(u={granted:l,loading:!1,error:!1,reason:c},t[5]=l,t[6]=c,t[7]=u):u=t[7],u}function l3(){const e=Re.c(10),{data:t,loading:o,error:a}=s3(),n=t?.role??void 0;let i;e[0]!==n?(i=n?wse.has(n):!1,e[0]=n,e[1]=i):i=e[1];const l=i;let c;e[2]!==t?.capabilities?(c=t?.capabilities??{},e[2]=t?.capabilities,e[3]=c):c=e[3];const u=c;let p;return e[4]!==a||e[5]!==l||e[6]!==o||e[7]!==n||e[8]!==u?(p={capabilities:u,loading:o,error:a,isPrivileged:l,roleSlug:n},e[4]=a,e[5]=l,e[6]=o,e[7]=n,e[8]=u,e[9]=p):p=e[9],p}function Tse(){const e=Re.c(13),{org:t}=Zp(),o=i_(),{capabilities:a,isPrivileged:n}=l3(),i=n||!!a["members:manage"];let l;e[0]!==t.id?(l=On.infraBillingSites(t.id),e[0]=t.id,e[1]=l):l=e[1];const c=!!t.id&&i;let u;e[2]!==o?(u=()=>o.call("INFRA_BILLING_SITES_LIST",{}),e[2]=o,e[3]=u):u=e[3];let p;e[4]!==l||e[5]!==c||e[6]!==u?(p={queryKey:l,staleTime:3e5,enabled:c,queryFn:u},e[4]=l,e[5]=c,e[6]=u,e[7]=p):p=e[7];const{data:m,isLoading:h}=Rd(p);let f;e[8]!==m?.sites?(f=m?.sites.map(xse)??[],e[8]=m?.sites,e[9]=f):f=e[9];let v;return e[10]!==h||e[11]!==f?(v={sites:f,isLoading:h},e[10]=h,e[11]=f,e[12]=v):v=e[12],v}function xse(e){return e.slug}function Xve(){const e=Re.c(7),t=i_(),o=ar();let a;e[0]!==t?(a=l=>t.call("INFRA_BILLING_PORTAL",{siteSlugs:l}),e[0]=t,e[1]=a):a=e[1];let n;e[2]!==o?(n=l=>Vr.error(o("settings.infraBilling.portalError",{message:l.message})),e[2]=o,e[3]=n):n=e[3];let i;return e[4]!==a||e[5]!==n?(i={mutationFn:a,onSuccess:_se,onError:n},e[4]=a,e[5]=n,e[6]=i):i=e[6],sp(i)}function _se(e){const{url:t}=e;return window.open(t,"_blank","noopener,noreferrer")}function ebe(e,t){const o=Re.c(14),{org:a}=Zp(),n=i_();let i,l,c;o[0]!==a.id||o[1]!==t||o[2]!==e?(i=[...e].sort(),c=Rd,l=On.infraBilling(a.id,i.join(","),t),o[0]=a.id,o[1]=t,o[2]=e,o[3]=i,o[4]=l,o[5]=c):(i=o[3],l=o[4],c=o[5]);const u=i.length>0;let p;o[6]!==t||o[7]!==i||o[8]!==n?(p=()=>n.call("INFRA_BILLING_GET",{siteSlugs:i,period:t}),o[6]=t,o[7]=i,o[8]=n,o[9]=p):p=o[9];let m;return o[10]!==l||o[11]!==u||o[12]!==p?(m={queryKey:l,enabled:u,staleTime:6e4,queryFn:p},o[10]=l,o[11]=u,o[12]=p,o[13]=m):m=o[13],c(m)}function kse(){const e=Re.c(7),{capabilities:t,isPrivileged:o,loading:a,error:n}=l3(),{sites:i,isLoading:l}=Tse(),c=i.length>0;let u;if(e[0]!==t||e[1]!==n||e[2]!==o||e[3]!==a||e[4]!==c||e[5]!==l){const p=m=>m.requiresOwnedSites&&!c&&!l?!1:a||n?!0:m.privilegedOnly?o:m.requires?o||t[m.requires]:!0;u=Object.fromEntries(Object.values(Wv).map(m=>[m.key,m.tabs.filter(p)])),e[0]=t,e[1]=n,e[2]=o,e[3]=a,e[4]=c,e[5]=l,e[6]=u}else u=e[6];return u}function Cse(e){const t=Re.c(16),{group:o}=e,a=ar();let n;t[0]===Symbol.for("react.memo_cache_sentinel")?(n={from:"/shell/$org"},t[0]=n):n=t[0];const{org:i}=Up(n);let l;t[1]===Symbol.for("react.memo_cache_sentinel")?(l={select:Ese},t[1]=l):l=t[1];const c=Dx(l),u=kse()[o],{titleKey:p}=Wv[o];let m;t[2]!==a||t[3]!==p?(m=a(p),t[2]=a,t[3]=p,t[4]=m):m=t[4];let h;t[5]!==m?(h=w.jsx(ld.Title,{children:m}),t[5]=m,t[6]=h):h=t[6];let f;t[7]!==o||t[8]!==i||t[9]!==c||t[10]!==a||t[11]!==u?(f=u.length>1&&w.jsx(nn.Toolbar.Left.Portal,{children:w.jsx(ld.Tabs,{"data-testid":"settings-subnav","aria-label":a("settings.subnav.ariaLabel"),children:u.map(b=>{const S=b.to.replace("$org",i),_=c===S||c.startsWith(`${S}/`);return w.jsx(ld.Tab,{active:_,asChild:!0,children:w.jsx(Nl,{to:b.to,params:{org:i},onClick:()=>a3("settings_subnav_clicked",{group_key:o,tab_key:b.key}),children:a(b.labelKey)})},b.key)})})}),t[7]=o,t[8]=i,t[9]=c,t[10]=a,t[11]=u,t[12]=f):f=t[12];let v;return t[13]!==h||t[14]!==f?(v=w.jsxs(w.Fragment,{children:[h,f]}),t[13]=h,t[14]=f,t[15]=v):v=t[15],v}function Ese(e){return e.location.pathname}function c3(){const e=Re.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t=w.jsxs("div",{"data-testid":"settings-content-loading",className:"flex flex-col gap-4",children:[w.jsx(yD,{className:"h-32 w-full"}),w.jsx(yD,{className:"h-32 w-full"})]}),e[0]=t):t=e[0],t}function Pse(e){const t=Re.c(14),{group:o,fallback:a,errorFallback:n,className:i,children:l}=e;let c;t[0]!==o?(c=w.jsx(Cse,{group:o}),t[0]=o,t[1]=c):c=t[1];let u;t[2]!==a?(u=a??w.jsx(c3,{}),t[2]=a,t[3]=u):u=t[3];let p;t[4]!==l||t[5]!==u?(p=w.jsx(A.Suspense,{fallback:u,children:l}),t[4]=l,t[5]=u,t[6]=p):p=t[6];let m;t[7]!==n||t[8]!==p?(m=w.jsx(hse,{fallback:n,children:p}),t[7]=n,t[8]=p,t[9]=m):m=t[9];let h;return t[10]!==i||t[11]!==c||t[12]!==m?(h=w.jsx(ld,{children:w.jsx(ld.Content,{children:w.jsx(ld.Container,{children:w.jsxs(Sse,{className:i,children:[c,m]})})})}),t[10]=i,t[11]=c,t[12]=m,t[13]=h):h=t[13],h}function Bi(e){return function(){return w.jsx(Pse,{group:e,children:w.jsx(c3,{})})}}function Ase(e){try{localStorage.setItem(Bl.lastLocation(),JSON.stringify(e))}catch{}}function Rse(){try{const e=localStorage.getItem(Bl.lastLocation());if(!e)return null;const t=JSON.parse(e);if(typeof t?.org=="string")return{org:t.org}}catch{}return null}function tbe(){try{localStorage.removeItem(Bl.lastLocation())}catch{}}const Nt={home:"/$org/home",projects:"/$org/projects/$agentId",tasks:"/$org/tasks/{-$taskKey}",reports:"/$org/reports",library:"/$org/library",threadAnalytics:"/$org/thread-analytics",discover:"/$org/discover",orgIndex:"/$org/"},rt={root:Nt.projects,tasks:"/$org/projects/$agentId/tasks/{-$taskKey}",reports:"/$org/projects/$agentId/reports",siteEditor:"/$org/projects/$agentId/site-editor",siteEditorContent:"/$org/projects/$agentId/site-editor/content",siteEditorCode:"/$org/projects/$agentId/site-editor/code",automations:"/$org/projects/$agentId/automations",automation:"/$org/projects/$agentId/automations/$automationId",app:"/$org/projects/$agentId/apps/$connectionId/$toolName",view:"/$org/projects/$agentId/views/$viewId",outputFile:"/$org/projects/$agentId/outputs/file",outputDeck:"/$org/projects/$agentId/outputs/deck",library:"/$org/projects/$agentId/library",libraryFile:"/$org/projects/$agentId/library/file",connectSources:"/$org/projects/$agentId/connect-sources",settings:"/$org/projects/$agentId/settings",assets:"/$org/projects/$agentId/assets",hosting:"/$org/projects/$agentId/hosting",e2e:"/$org/projects/$agentId/e2e",analytics:"/$org/projects/$agentId/analytics",experiments:"/$org/projects/$agentId/experiments",monitor:"/$org/projects/$agentId/cdn"};function obe(){const e=Re.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t={select:Dse},e[0]=t):t=e[0],Dx(t)}function Dse(e){return e.matches.at(-1)?.fullPath??""}const Ose=new Map([[Nt.reports,"project-only"],[Nt.library,"org-only"],[Nt.threadAnalytics,"org-only"]]);function abe(e,t){const o=Ose.get(e);return o===void 0?!0:o==="project-only"?t!==null:t===null}function nbe(){const e=Re.c(1);let t;return e[0]===Symbol.for("react.memo_cache_sentinel")?(t={select:Mse},e[0]=t):t=e[0],Dx(t)}function Mse(e){return e.matches.findLast(Nse)?.staticData.mainView}function Nse(e){return e.staticData.mainView}function lf(e){return`agent-view:${encodeURIComponent(e)}`}function Ise(e){if(!e?.startsWith("agent-view:"))return null;const t=e.slice(11);if(!t)return null;try{const o=decodeURIComponent(t);return o?{id:o}:null}catch{return null}}function d3(e){if(!e||!e.startsWith("automation:"))return null;const t=e.slice(11);return t?{id:t}:null}function tk(e,t){return`app:${e}:${t}`}function Lse(e){if(!e||!e.startsWith("app:"))return null;const t=e.slice(4),o=t.indexOf(":");if(o<=0)return null;const a=t.slice(0,o),n=t.slice(o+1);return!a||!n?null:{connectionId:a,toolName:n}}function u3(e){return`deck:${encodeURIComponent(e)}`}function Bse(e){if(!e||!e.startsWith("deck:"))return null;const t=e.slice(5);if(!t)return null;try{return{path:decodeURIComponent(t)}}catch{return null}}function p3(e){return`file:${encodeURIComponent(e)}`}function Fse(e){if(!e||!e.startsWith("file:"))return null;const t=e.slice(5);if(!t)return null;try{return{key:decodeURIComponent(t)}}catch{return null}}function m3(e){return`library-file:${encodeURIComponent(e)}`}function jse(e){if(!e||!e.startsWith("library-file:"))return null;const t=e.slice(13);if(!t)return null;try{return{path:decodeURIComponent(t)}}catch{return null}}function h3(e){return`code:${encodeURIComponent(e)}`}function zse(e){if(!e)return null;if(e==="code")return{path:null};if(!e.startsWith("code:"))return null;const t=e.slice(5);if(!t)return null;try{return{path:decodeURIComponent(t)}}catch{return null}}const g3=["overview","settings","automations","site-editor","code","content","assets","hosting","e2e","analytics","cdn"],Use=new Set(g3),f3=new Set(["hosting","e2e","analytics","cdn"]),$se=new Set(["board","files","connect-sources","reports"]);function rbe(e){return e.startsWith("app:")||e.startsWith("automation:")||e.startsWith("file:")||e.startsWith("deck:")||e.startsWith("library-file:")||e.startsWith("code:")}const qse=new Map([["preview","site-editor"],["git","site-editor"]]);function Kv(e){return qse.get(e)??e}const ok=new Set(["instructions","connections","layout","settings"]);function Vse(e){return!!e&&ok.has(e)}const Hse=new Set(["overview","board","reports"]);function ibe(e){const t=e?.defaultMainView??null;if(!(!t||t.type==="chat"))return v3(e??null)}function v3(e){const t=e?.defaultMainView??null;if(!t)return"settings";const o=Kv(t.type);if(ok.has(o))return"settings";if(Use.has(o)||Hse.has(o))return o;if(o==="ext-app"||o==="ext-apps"){if(t.id&&t.toolName)return tk(t.id,t.toolName);const n=e?.tabs?.map(i=>i.id)??[];return t.id&&n.includes(t.id)?lf(t.id):n[0]?lf(n[0]):"settings"}const a=e?.tabs?.[0]?.id;return a?lf(a):"settings"}function sbe(e){const t=e.routeDefaultMain||v3(e.metadata),o=e.panelTabId&&ok.has(e.panelTabId)?"settings":e.panelTabId?Kv(e.panelTabId):e.panelTabId,a=e.metadata?.defaultMainView??null,n=a==null||a.type==="chat";return{mainOpen:e.mainPanelParam??(!!o||!!e.routeDefaultMain||!n),activeTab:o??t}}function lbe(e){return e.mainOpen&&e.clickedId===e.activeTab?{close:!0}:{tabId:e.clickedId}}function cbe(e){return e.mainOpen?e.activeTab==="automations"?!0:d3(e.activeTab)!==null:!1}const Gse=new Set([...g3.filter(e=>!f3.has(e)),...$se,"app","file","deck","library-file","connect-sources","instructions","connections","layout","preview","discover"]);function Wse(e){return!!e&&Gse.has(e)}function Kse(e,t){if(e)switch(e){case"app":return t.connection&&t.tool?tk(t.connection,t.tool):void 0;case"automations":return t.automation?`automation:${t.automation}`:"automations";case"file":return t.key?p3(t.key):void 0;case"deck":return t.deck?u3(t.deck):void 0;case"library-file":return t.path?m3(t.path):void 0;case"code":return t.file?h3(t.file):"code";default:{const o=Kv(e);return o==="site-editor"&&t.main==="content"?"content":o}}}function dbe(e){const t=e.params??{},o=e.search??{};if(e.siteEditorView==="content")return"content";if(e.siteEditorView==="code")return o.file?h3(o.file):"code";if(e.siteEditorView==="preview")return"site-editor";switch(e.mainView){case"automation":return t.automationId?`automation:${t.automationId}`:"automations";case"app":return t.connectionId&&t.toolName?tk(t.connectionId,t.toolName):void 0;case"view":return t.viewId?lf(t.viewId):void 0;case"file":return o.key?p3(o.key):void 0;case"deck":return o.path?u3(o.path):void 0;case"library-file":return o.path?m3(o.path):void 0;default:return e.mainView}}const Yse={files:"library",discover:"discover"},Zse={board:"tasks",reports:"reports"},Qse={settings:"settings",assets:"assets",hosting:"hosting",e2e:"e2e",analytics:"analytics",experiments:"experiments",cdn:"monitor"};function b3(e){const t=Ise(e);if(t)return{kind:"agent-view",viewId:t.id};const o=Lse(e);if(o)return{kind:"app",connectionId:o.connectionId,toolName:o.toolName};const a=d3(e);if(a)return{kind:"automations",automationId:a.id};const n=Fse(e);if(n)return{kind:"output-file",key:n.key};const i=Bse(e);if(i)return{kind:"output-deck",path:i.path};const l=jse(e);if(l)return{kind:"library-file",path:l.path};const c=zse(e);if(c)return{kind:"site-editor",view:"code",...c.path?{file:c.path}:{}};if(Vse(e))return{kind:"agent-section",section:"settings"};const u=Kv(e);if(u==="overview")return{kind:"agent-overview"};if(u==="site-editor")return{kind:"site-editor",view:"preview"};if(u==="content")return{kind:"site-editor",view:"content"};if(u==="automations")return{kind:"automations"};if(u==="connect-sources")return{kind:"connect-sources"};const p=Zse[u];if(p)return{kind:"project-destination",destination:p};const m=Yse[u];if(m)return{kind:"org-destination",destination:m};const h=Qse[u];return h?{kind:"agent-section",section:h}:{kind:"agent-view",viewId:u}}function Dl(e){const{org:t,agentId:o}=e,a={org:t,agentId:o},n=b3(e.tabId);switch(n.kind){case"project-destination":return e.destinationScope==="organization"?n.destination==="tasks"?{to:Nt.tasks,params:{org:t,taskKey:e.taskKey},search:{}}:{to:Nt.reports,params:{org:t},search:{}}:n.destination==="tasks"?{to:rt.tasks,params:{...a,taskKey:e.taskKey},search:{}}:{to:rt.reports,params:a,search:{}};case"org-destination":switch(n.destination){case"home":return{to:Nt.home,params:{org:t},search:{}};case"discover":return{to:Nt.discover,params:{org:t},search:{}};case"library":return{to:Nt.library,params:{org:t},search:{}}}case"agent-overview":return{to:rt.root,params:a,search:{}};case"site-editor":return n.view==="content"?{to:rt.siteEditorContent,params:a,search:{}}:n.view==="code"?{to:rt.siteEditorCode,params:a,search:{file:n.file}}:{to:rt.siteEditor,params:a,search:{}};case"agent-section":return{to:rt[n.section],params:a,search:{}};case"automations":return n.automationId?{to:rt.automation,params:{...a,automationId:n.automationId},search:{}}:{to:rt.automations,params:a,search:{}};case"app":return{to:rt.app,params:{...a,connectionId:n.connectionId,toolName:n.toolName},search:{}};case"agent-view":return{to:rt.view,params:{...a,viewId:n.viewId},search:{}};case"output-file":return{to:rt.outputFile,params:a,search:{key:n.key}};case"output-deck":return{to:rt.outputDeck,params:a,search:{path:n.path}};case"library-file":return{to:rt.libraryFile,params:a,search:{path:n.path}};case"connect-sources":return{to:rt.connectSources,params:a,search:{}}}}function ube(e){if(!e.agentId||e.agentId===e.superAgentId&&(e.tabId===void 0||e.tabId==="overview"))return{to:Nt.home,params:{org:e.org},search:{}};const t=e.tabId??"overview",o=e.agentId!==e.superAgentId&&b3(t).kind==="org-destination"?"overview":t;return Dl({org:e.org,agentId:e.agentId,tabId:o,destinationScope:e.agentId===e.superAgentId?"organization":"project"})}function Jse(e,t,o={}){const a=i=>({...o.search?.(i)??{},...t.search}),n=o.replace??!0;switch(t.to){case Nt.tasks:e({to:Nt.tasks,params:t.params,search:a,replace:n});return;case Nt.home:e({to:Nt.home,params:t.params,search:a,replace:n});return;case Nt.reports:e({to:Nt.reports,params:t.params,search:a,replace:n});return;case Nt.discover:e({to:Nt.discover,params:t.params,search:a,replace:n});return;case Nt.library:e({to:Nt.library,params:t.params,search:a,replace:n});return;case rt.root:e({to:rt.root,params:t.params,search:a,replace:n});return;case rt.tasks:e({to:rt.tasks,params:t.params,search:a,replace:n});return;case rt.reports:e({to:rt.reports,params:t.params,search:a,replace:n});return;case rt.siteEditor:e({to:rt.siteEditor,params:t.params,search:a,replace:n});return;case rt.siteEditorContent:e({to:rt.siteEditorContent,params:t.params,search:a,replace:n});return;case rt.siteEditorCode:e({to:rt.siteEditorCode,params:t.params,search:a,replace:n});return;case rt.automations:e({to:rt.automations,params:t.params,search:a,replace:n});return;case rt.automation:e({to:rt.automation,params:t.params,search:a,replace:n});return;case rt.app:e({to:rt.app,params:t.params,search:a,replace:n});return;case rt.view:e({to:rt.view,params:t.params,search:a,replace:n});return;case rt.outputFile:e({to:rt.outputFile,params:t.params,search:a,replace:n});return;case rt.outputDeck:e({to:rt.outputDeck,params:t.params,search:a,replace:n});return;case rt.libraryFile:e({to:rt.libraryFile,params:t.params,search:a,replace:n});return;case rt.connectSources:e({to:rt.connectSources,params:t.params,search:a,replace:n});return;case rt.settings:case rt.assets:case rt.hosting:case rt.e2e:case rt.analytics:case rt.experiments:case rt.monitor:e({to:t.to,params:t.params,search:a,replace:n})}}function pbe(e,t){Jse(e,Dl(t),t)}function Xse(e){const t=/^(\/[^/]+)\/agents(?=\/|$)/.exec(e);return t?.[1]?`${t[1]}/projects${e.slice(t[0].length)}`:null}function ele(e){const t=e.split("/").filter(Boolean);return(t[1]==="projects"||t[1]==="agents")&&t.length>3}const tle=new Set(["main","virtualmcpid","file","key","deck","path","connection","tool","automation"]),y3=new Set(["main"]),ole=new Set(["virtualmcpid"]);function Yv(e,t){return Object.fromEntries(Object.entries(e).filter(([o])=>!t.has(o)))}function El(e,t){return{...Yv(e,tle),...t.search}}function ale(e){return Yv(e,ole)}function mbe(e){if(e.search.virtualmcpid===void 0)return null;const t=br(e.search.virtualmcpid);if(t){const o=e.routePath===Nt.tasks?"board":e.routePath===Nt.reports?"reports":null;if(e.routePath===Nt.home||o){const a=o?Dl({org:e.org,agentId:t,tabId:o}):Ed(e.org,t);return{kind:"canonical",route:a,search:El(e.search,a)}}}return e.routePath===Nt.home||e.routePath===Nt.tasks||e.routePath===Nt.reports||e.routePath===Nt.library?{kind:"same-route",search:ale(e.search)}:null}function br(e){return e?.trim()||void 0}function S3(e){return Wse(e)||e!==void 0&&f3.has(e)}function w3(e){const t=br(e);return t?t.startsWith("vir_")&&t.length>4||PI(t)!==null||wW(t)!==null||TW(t)!==null||RI(t)||DI(t):!1}function nle(e){const t=br(e.agentIdParam),o=S3(t);return t&&!o?t:br(e.virtualMcpIdSearch)??br(e.fallbackAgentId)}function hbe(e){const t=e.pathAgentId;if(t&&e.pathLegacyView){const l=JT({org:e.org,agentId:t,panel:e.pathLegacyView,source:"project-first",search:e.search});return l?.kind==="canonical"?{route:l.route,search:l.search}:null}if(!t||ele(e.pathname))return null;const o=e.search.virtualmcpid!==void 0&&!w3(t);if(!(S3(t)||o))return null;const n=nle({agentIdParam:o?void 0:t,virtualMcpIdSearch:e.search.virtualmcpid,fallbackAgentId:e.fallbackAgentId}),i=JT({org:e.org,agentId:n,panel:t,source:"view-first",search:e.search});return i?.kind==="canonical"?{route:i.route,search:i.search}:null}function rle(e,t,o,a){const n=br(a);switch(e){case"board":return n?Dl({org:t,agentId:n,tabId:"board"}):{to:Nt.tasks,params:{org:t,taskKey:void 0},search:{}};case"files":{const i=ys(o.path);return{to:Nt.library,params:{org:t},search:i?{path:i}:{}}}case"reports":return n?Dl({org:t,agentId:n,tabId:"reports"}):{to:Nt.reports,params:{org:t},search:{}};case"overview":return{to:Nt.home,params:{org:t},search:{}};case"discover":return{to:Nt.discover,params:{org:t},search:{}};default:return null}}function Lp(e){const t=rle(e.tabId,e.org,e.search,e.agentId);if(t)return t;if(e.tabId==="chat")return Ed(e.org,e.agentId);const o=br(e.agentId);return o?e.tabId==="app"||e.tabId==="file"||e.tabId==="deck"||e.tabId==="library-file"||e.tabId.trim()===""?{to:rt.root,params:{org:e.org,agentId:o},search:{}}:Dl({org:e.org,agentId:o,tabId:e.tabId}):null}function Ed(e,t){const o=br(t);return o?{to:rt.root,params:{org:e,agentId:o},search:{}}:{to:Nt.home,params:{org:e},search:{}}}function ile(e){const{main:t}=e;if(t===void 0)return null;const o=e.search??{};if(t===0||t==="0")return{kind:"same-route",search:{...Yv(o,y3),mainpanel:!1}};if(t==="chat"){const n=Ed(e.org,e.agentId);return{kind:"canonical",route:n,search:{...El(o,n),sidepanel:!0,mainpanel:!1}}}const a=Lp({org:e.org,agentId:e.agentId,tabId:t,search:o});return a?{kind:"canonical",route:a,search:El(o,a)}:null}function ys(e){return typeof e=="string"&&e.length>0?e:void 0}function JT(e){const t=e.search??{};if((t.main===0||t.main==="0")&&e.panel){const l=JT({...e,search:Yv(t,y3)});return l?.kind!=="canonical"?l:{...l,search:{...l.search,mainpanel:!1}}}if(t.main!==void 0)return ile({org:e.org,agentId:e.agentId,main:t.main,search:t});const o=br(e.agentId),a=e.panel;if(!a){const l=Ed(e.org,o);return{kind:"canonical",route:l,search:El(t,l)}}const n=Kse(a,{file:ys(t.file),key:ys(t.key),deck:ys(t.deck),path:ys(t.path),connection:ys(t.connection),tool:ys(t.tool),automation:ys(t.automation)}),i=n?e.source==="project-first"&&n==="overview"&&o?Dl({org:e.org,agentId:o,tabId:n}):Lp({org:e.org,agentId:o,tabId:n,search:t}):Lp({org:e.org,agentId:o,tabId:"",search:t});return i?{kind:"canonical",route:i,search:n==="chat"?{...El(t,i),sidepanel:!0,mainpanel:!1}:El(t,i)}:null}function gbe(e){const t=e.search??{},o=br(t.virtualmcpid),a=br(e.fallbackAgentId),n=t.main;let i;if(n==="chat")i=Ed(e.org,o);else if(n!==void 0&&n!==0&&n!=="0"){const l=Lp({org:e.org,agentId:o,tabId:n,search:t}),c=!l&&n.trim().length>0&&a?Lp({org:e.org,agentId:a,tabId:n,search:t}):null;i=l??c??{to:Nt.home,params:{org:e.org},search:{}}}else i=Ed(e.org,o);return{route:i,search:{...El(t,i),...n===void 0&&t.sidepanel===void 0?{sidepanel:!0}:{},...n===0||n==="0"?{mainpanel:!1}:{},...n==="chat"?{sidepanel:!0,mainpanel:!1}:{},thread:e.taskId}}}function T3(e,t){if(t.task===void 0)return null;const{task:o,...a}=t;return{taskKey:e??(o.trim()||void 0),search:a}}const sle={contentPageId:q().optional(),contentPath:q().optional(),contentPathTemplate:q().optional(),contentCollection:q().optional(),contentItem:q().optional()},x3=sle,ak={view:q().optional(),group:q().optional(),subgroup:q().optional(),sort:q().optional(),dir:q().optional(),q:q().optional(),assignee:q().optional(),priority:q().optional(),due:q().optional(),tags:q().optional(),repo:q().optional(),sprint:q().optional(),boardOrg:q().optional()},nv={fileView:So(["all","documents","media"]).catch("all").optional(),modified:So(["any","today","week","month"]).catch("any").optional(),layout:So(["list","grid"]).catch("list").optional(),sort:So(["name","updated","size"]).catch("name").optional(),path:q().optional(),preview:q().optional(),expanded:kp().optional().catch(void 0),skill:q().optional(),brand:q().optional()},lle={file:q().optional(),key:q().optional(),deck:q().optional(),path:q().optional(),connection:q().optional(),tool:q().optional(),automation:q().optional(),section:q().optional(),preview:q().optional(),autosend:q().optional(),connect:kv().optional(),siteUrl:q().optional(),...x3},_3={...lle,task:q().optional(),project:q().optional(),...ak,skill:nv.skill,brand:nv.brand},rm=we(_3),pn=E$({component:()=>w.jsx(fse,{children:w.jsx(Rx,{})})}),cle=Ne({getParentRoute:()=>pn,path:"/login",component:Fe(()=>je(()=>import("./login-BPcnReJQ.js"),__vite__mapDeps([0,1,2,3,4]))),validateSearch:Gr(()=>we({next:q().optional(),client_id:q().optional(),redirect_uri:q().optional(),response_type:q().optional(),state:q().optional(),scope:q().optional(),code_challenge:q().optional(),code_challenge_method:q().optional(),src:q().optional(),ref:q().optional()}))}),dle=Ne({getParentRoute:()=>pn,path:"/cli/auth-success",component:Fe(()=>je(()=>import("./cli-auth-success-C6o7zJ2p.js"),__vite__mapDeps([5,4])))}),ule=Ne({getParentRoute:()=>pn,path:"/reset-password",component:Fe(()=>je(()=>import("./reset-password-BDIEd0mg.js"),[])),validateSearch:Gr(()=>we({token:q().optional(),error:q().optional()}))}),ple=Ne({getParentRoute:()=>pn,path:"/auth/$pathname",component:Fe(()=>je(()=>import("./auth-catchall-D9Jl5rTX.js"),[]))}),mle=Ne({getParentRoute:()=>pn,path:"/oauth/callback",component:Fe(()=>je(()=>import("./oauth-callback-z1ZK2Q1I.js"),__vite__mapDeps([6,7,8])))}),hle=Ne({getParentRoute:()=>pn,path:"/oauth/callback/ai-provider",component:Fe(()=>je(()=>import("./oauth-callback-ai-provider-CbuzeLlJ.js"),[]))}),im=Ne({getParentRoute:()=>pn,path:"/_admin",component:Fe(()=>je(()=>import("./layout-DHC2Bj1E.js"),__vite__mapDeps([9,10,11])))}),gle=Ne({getParentRoute:()=>im,path:"/",beforeLoad:()=>{throw Jo({to:"/_admin/users"})}}),fle=Ne({getParentRoute:()=>im,path:"/users",component:Fe(()=>je(()=>import("./users-xDH1jmUT.js"),__vite__mapDeps([12,13,14,15,16,17,18,19,20,21,22,23,24,25,26])))}),vle=Ne({getParentRoute:()=>im,path:"/orgs",component:Fe(()=>je(()=>import("./orgs-CEeF7hFm.js"),__vite__mapDeps([27,13,14,15,16,17,18,28,22,29,30,31,32,33,34,21,35,36,23,24,25])))}),ble=Ne({getParentRoute:()=>im,path:"/prompts",component:Fe(()=>je(()=>import("./prompts-JCRZXZfZ.js"),__vite__mapDeps([37,16,28,34,23])))}),yle=im.addChildren([gle,fle,vle,ble]),nk=Ne({getParentRoute:()=>pn,id:"shell",component:Fe(()=>je(()=>import("./shell-layout-C7bQvu8M.js").then(e=>e.g),__vite__mapDeps([38,19,20,39,40,41,42,43,15,44,45,46,47,48,32,49,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,64,65,66,67,68,8,69,70,71,72,73,74,75,76,28,77,78,79,3,2,80,81,35,82,83,84,31,85,86,87,22,88,10,89,90,91])))}),Sle=Ne({getParentRoute:()=>nk,path:"/",beforeLoad:async()=>{const e=Rse();if(e)throw Jo({to:"/$org",params:{org:e.org}});const t=localStorage.getItem(Bl.lastOrgSlug());if(t)throw Jo({to:"/$org",params:{org:t}});const{data:o}=await rL();if(!o)return;const a=o[0];throw Jo(a?{to:"/$org",params:{org:a.slug}}:{to:"/onboarding"})}}),wle=Ne({getParentRoute:()=>pn,path:"/onboarding",beforeLoad:async()=>{const{data:e}=await rL();if(e&&e.length>0)throw Jo({to:"/"})},component:Fe(()=>je(()=>import("./onboarding-BGszMdtv.js"),__vite__mapDeps([92,10,4,93,19,20,61,28,33,39,48,54,63])))}),k3=Gr(()=>we({org:q().optional(),siteUrl:q().optional(),fix:q().optional()})),Tle=Ne({getParentRoute:()=>pn,path:"/reports-onboarding",component:Fe(()=>je(()=>import("./reports-onboarding-Ci2eFzgb.js"),__vite__mapDeps([94,95,1,2,3,4,93,19,20,61,96,97,98,28,99,68,8,100,74,45,41,42,43,15,44,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,18,62,63,64,65,84,31,101,102,103,22,104,105,106,107,7,108,109,110,111,112,113]))),validateSearch:k3}),xle=Ne({getParentRoute:()=>pn,path:"/commerce-onboarding",validateSearch:k3,beforeLoad:({search:e})=>{throw Jo({to:"/reports-onboarding",search:e})}}),_le=Ne({getParentRoute:()=>pn,path:"/choose-editor",component:Fe(()=>je(()=>import("./choose-editor-BKZj3uPE.js"),__vite__mapDeps([114,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,10]))),validateSearch:Gr(()=>we({site:q().optional(),domain:q().optional(),pageId:q().optional(),path:q().optional(),pathTemplate:q().optional()}))}),kle=Ne({getParentRoute:()=>pn,path:"/report/$domain",component:Fe(()=>je(()=>import("./reports-BiB14-w5.js"),__vite__mapDeps([115,108,3,1,2,116])))}),Zv=Ne({getParentRoute:()=>nk,path:"/$org",beforeLoad:({params:e})=>{Ase({org:e.org})},component:Fe(()=>je(()=>import("./route-lCR_XMKF.js"),__vite__mapDeps([117,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,121,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,124,125,126,96,97,98,127,128,129,130,131,11,132,29,30,34,133,134,135,136,137,138,139,140,141,26,24,25,142,143,144,145,146,147,148,33,149])))}),Qv=Ne({getParentRoute:()=>Zv,id:"org-shell",pendingComponent:Md,component:Fe(()=>je(()=>import("./thread-route-Cx-o2xCf.js"),__vite__mapDeps([150,151,69,70,66,67,68,8,89,79,3,2,80,81,35,82,137,136,152,153,88,95,154,101,102,103,45,99,100,74,41,42,43,15,44,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,84,31,98,28,22,104,105,106,107,7,108,109,110,111,155,112])))}),Cle=we({sidepanel:CL,mainpanel:EL,main:io([q(),Ze(0)]).optional(),thread:q().optional(),autosend:q().optional(),preview:q().optional(),virtualmcpid:q().optional()}),Mn=Ne({getParentRoute:()=>Qv,id:"agent-shell",validateSearch:Cle,search:{middlewares:[QU(["sidepanel"])]},pendingComponent:Md,component:Fe(()=>je(()=>import("./route-Dbrk4VYq.js"),__vite__mapDeps([156,42,41,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,118,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,121,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,157,151,137,136,152,153,158,131,159,160,98,161,162,163,24,25,164,148,165,166,29,30,167,135,168,169,170,147,171,130,172,173,174,149,175,133,176,138,177,109,102,110,111,178,179,34,180,181,106,107,7,182,21,183,184,141,185,186,187,188,189,190,191,192,193,194,195,196,197,16,198,199,200,201,202,145,203,204,146,205,206,207,208,209,210,211,212])))}),Ele=rm.extend({virtualmcpid:q().optional()}),Ple=Ne({getParentRoute:()=>Mn,path:"/$taskId",validateSearch:Ele,component:()=>null}),oo=Fe(()=>je(()=>import("./index-D_C9gk4l.js").then(e=>e.i),__vite__mapDeps([198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148])),"ChatLayoutPending"),Zt=Fe(()=>je(()=>import("./index-D_C9gk4l.js").then(e=>e.i),__vite__mapDeps([198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148])),"ChatLayoutError"),Ale=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/home",staticData:{pageTitle:"sidebar.navDestinations.home",defaultMain:"overview",mainView:"overview"},validateSearch:we({connect:kv().optional(),siteUrl:q().optional(),view:So(["agents"]).optional()}),component:Fe(()=>je(()=>import("./home-BZZrU9O7.js"),__vite__mapDeps([213,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,140,141,137,127,128,124,129,214,215,216,217,218,219,164,160,158,98,161,162,163,153,24,25,151,136,152,165,166,29,30,167,135,168,169,170,147,171,130,131,172,173,159,174,149,175,133,176,138,177,109,102,110,111,178,179,34,180,181,106,107,7,182,21,183,184,185,220,154,101,103,221,26,222,143,223,16])))}),Rle=Ne({getParentRoute:()=>Mn,path:"/projects",staticData:{pageTitle:"projects.settings.title",defaultMain:"board"},validateSearch:rm.extend({files:kp().optional().catch(void 0),analytics:kp().optional().catch(void 0)}),component:Fe(()=>je(()=>import("./flat-project-CNnQaq5E.js"),__vite__mapDeps([224,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,225,84,31,198,121,118,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,223,226,124,125,227,228,130,160,158,98,161,162,163,153,24,25,137,151,136,152,173,229,21,33,34,174,219,26,230,140,141,175,133,29,30,129,128,231,232,233,187,234,235,236,197,237,180,103,238,184,186,188,189,190,191,159,192,165,183,200,169,166,239,240,182,241,139,242,214,215,216,217,14,243,244,245,246,247,218,248,249,97,250,208,206,207,209,210,211,251,252,253]))),beforeLoad:({params:e,search:t})=>{if(t.project?.trim())return;const o=t.virtualmcpid?.trim();throw Jo(o?{to:"/$org/projects/$agentId",params:{org:e.org,agentId:o},search:a=>({...a,virtualmcpid:void 0}),hash:!0,replace:!0}:{to:"/$org/home",params:{org:e.org},search:a=>({...a,virtualmcpid:void 0}),hash:!0,replace:!0})}}),Ro=Ne({errorComponent:Zt,getParentRoute:()=>Mn,path:"/projects/$agentId",validateSearch:rm,component:Rx}),Dle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/",staticData:{pageTitle:"page.overview",defaultMain:"overview",mainView:"overview"},component:Fe(()=>je(()=>import("./agent-overview-UU6Y44eX.js"),__vite__mapDeps([254,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,220,154,101,102,103,221,140,141,137,129,124,128,26,175,133,24,25,255,226,125,227,228,130,160,158,98,161,162,163,153,151,136,152,173,229,21,33,34,174,219,230,29,30,231,232,233,187,234,235,236,197,237,180,238,184,186,188,189,190,191,159,192,165,183,200,169,166,239,256,176,138,257])))}),Ole=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/tasks/{-$taskKey}",staticData:{pageTitle:"sidebar.navDestinations.tasks",defaultMain:"board",mainView:"board"},validateSearch:we({task:q().optional(),...ak}),beforeLoad:({params:e,search:t})=>{const o=T3(e.taskKey,t);if(o)throw Jo({to:"/$org/projects/$agentId/tasks/{-$taskKey}",params:{org:e.org,agentId:e.agentId,taskKey:o?.taskKey??e.taskKey},search:o.search,hash:!0,replace:!0})},component:Fe(()=>je(()=>import("./project-tasks-CzZdSRDI.js"),__vite__mapDeps([255,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,226,124,125,227,228,130,160,158,98,161,162,163,153,24,25,137,151,136,152,173,229,21,33,34,174,219,26,230,140,141,175,133,29,30,129,128,231,232,233,187,234,235,236,197,237,180,103,238,184,186,188,189,190,191,159,192,165,183,200,169,166,239,256,176,138,257])))}),Mle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/reports",staticData:{pageTitle:"sidebar.navDestinations.reports",defaultMain:"reports",mainView:"reports"},validateSearch:we({connect:kv().optional(),siteUrl:q().optional()}),component:Fe(()=>je(()=>import("./project-reports-Ci_iYRrd.js"),__vite__mapDeps([258,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,259,95,154,101,102,103,221,112,113,223,143])))}),Jv=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/site-editor",staticData:{pageTitle:"sidebar.projectNav.siteEditor",defaultMain:"site-editor",mainView:"site-editor"},validateSearch:we({autosend:q().optional(),...x3}),component:Fe(()=>je(()=>import("./agent-site-editor-LLur_-_o.js"),__vite__mapDeps([260,239,151,69,70,66,67,68,8,89,79,3,2,80,81,35,82,137,136,152,153,88,38,19,20,39,40,41,42,43,15,44,45,46,47,48,32,49,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,64,65,71,72,73,74,75,76,28,77,78,83,84,31,85,86,87,22,10,90,91,123,130,97,167,194,195,175,133,261,204,111,164,160,158,98,161,162,163,121,24,25,148,165,166,29,30,135,168,169,170,147,171,131,172,173,119,120,36,159,174,149,176,138,177,109,102,110,178,179,34,180,181,106,107,7,182,21,183,184,141,185,262,196,157,186,187,188,189,190,191,122,192,193,197,263,264,265,210,211,266,198,118,199,267])))}),Nle=Ne({getParentRoute:()=>Jv,path:"/",staticData:{defaultMain:"site-editor",mainView:"site-editor",siteEditorView:"preview"},component:Fe(()=>je(()=>import("./agent-site-editor-preview-5ii-TR0s.js"),__vite__mapDeps([268,269,201,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,180,202,190,161,157,151,89,137,136,152,153,158,84,31,131,87,121,159,160,98,28,162,163,24,25,164,148,165,38,19,71,72,73,74,75,76,77,78,83,85,86,22,10,90,91,166,29,30,167,135,168,169,170,147,171,130,172,173,174,149,175,133,176,138,177,109,102,110,111,178,179,34,181,106,107,7,182,21,183,184,141,185,186,187,188,189,191,122,192,193,145,203,204,256,196,197,261,123,270,210,139,271,211,232,272,235,33,124,125,228,97,17,273,265,274,264,263,262,105,212,16,199])))}),Ile=Ne({getParentRoute:()=>Jv,path:"/content",staticData:{defaultMain:"content",mainView:"content",siteEditorView:"content"},component:Fe(()=>je(()=>import("./agent-site-editor-content-DXvV_eiy.js").then(e=>e.aH),__vite__mapDeps([275,269,201,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,180,202,190,161,157,151,89,137,136,152,153,158,84,31,131,87,121,159,160,98,28,162,163,24,25,164,148,165,38,19,71,72,73,74,75,76,77,78,83,85,86,22,10,90,91,166,29,30,167,135,168,169,170,147,171,130,172,173,174,149,175,133,176,138,177,109,102,110,111,178,179,34,181,106,107,7,182,21,183,184,141,185,186,187,188,189,191,122,192,193,145,203,204,256,97,139,270,261,197,210,271,211,232,272,235,33,124,125,228,17,273,265,276,196,252,16])))}),Lle=Ne({getParentRoute:()=>Jv,path:"/code",staticData:{defaultMain:"code",mainView:"code",siteEditorView:"code"},validateSearch:we({file:q().optional()}),component:Fe(()=>je(()=>import("./agent-site-editor-code-DA20Pk7L.js"),__vite__mapDeps([277,269,201,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,180,202,190,161,157,151,89,137,136,152,153,158,84,31,131,87,121,159,160,98,28,162,163,24,25,164,148,165,38,19,71,72,73,74,75,76,77,78,83,85,86,22,10,90,91,166,29,30,167,135,168,169,170,147,171,130,172,173,174,149,175,133,176,138,177,109,102,110,111,178,179,34,181,106,107,7,182,21,183,184,141,185,186,187,188,189,191,122,192,193,145,203,204,256,16])))}),Ble=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/automations",staticData:{pageTitle:"settings.nav.automations",defaultMain:"automations",mainView:"automations"},beforeLoad:({params:e,search:t})=>{const o=t.automation;if(o)throw Jo({to:"/$org/projects/$agentId/automations/$automationId",params:{org:e.org,agentId:e.agentId,automationId:o},search:a=>({...a,automation:void 0}),hash:!0,replace:!0})},component:Fe(()=>je(()=>import("./agent-automations-BV2eTHQr.js"),__vite__mapDeps([278,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,17,16,219,279,21,97])))}),Fle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/automations/$automationId",staticData:{pageTitle:"settings.nav.automations",defaultMain:"automations",mainView:"automation"},validateSearch:we({automationView:So(["settings","runs"]).optional()}),component:Fe(()=>je(()=>import("./agent-automation-DuF9ZiWS.js"),__vite__mapDeps([280,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,21,147,33,130,158,180,202,281,131,151,137,136,152,153,170,29,30,171,282,219,187,283,172,173,160,98,161,162,163,24,25,159,174,284,128,124,285,167,271,211,97,286,14,16,183,175,133,200,238,184,186,188,189,190,191,192,165,182])))}),jle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/settings",staticData:{pageTitle:"sidebar.navDestinations.settings",defaultMain:"settings",mainView:"settings"},component:Fe(()=>je(()=>import("./agent-settings-_tzBjLDX.js"),__vite__mapDeps([287,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,97,34,180,283,177,178,179,131,98,29,30,181,106,182,21,183,184,165,174,147,17,290,190,202,159,161,33,130,139,144,204,193,291,292,191,195])))}),zle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/library",staticData:{pageTitle:"sidebar.navDestinations.library",defaultMain:"files",mainView:"files"},validateSearch:we(nv),component:Fe(()=>je(()=>import("./agent-library-CGtmUhYD.js"),__vite__mapDeps([293,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,249,230,97,153,152,174,250,34,162,163,208,130,206,207,209,210,211,165,251,252,225,24,25,14,175,133,253])))}),Ule=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/assets",staticData:{pageTitle:"common.mainPanelTabs.assets",defaultMain:"assets",mainView:"assets"},component:Fe(()=>je(()=>import("./agent-assets-Ba_4hhfI.js"),__vite__mapDeps([294,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,269,201,180,202,190,161,157,151,137,136,152,153,158,131,159,160,98,162,163,24,25,164,165,166,29,30,167,135,168,169,170,147,171,130,172,173,174,149,175,133,176,138,177,109,102,110,111,178,179,34,181,106,107,7,182,21,183,184,141,185,186,187,188,189,191,192,193,145,203,204,97,17,273])))}),$le=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/hosting",staticData:{pageTitle:"common.mainPanelTabs.hosting",defaultMain:"hosting",mainView:"hosting"},component:Fe(()=>je(()=>import("./agent-hosting-2pI_IIlr.js"),__vite__mapDeps([295,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,21,252,97,14,187,29,30,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,34,180,283,177,178,179,131,98,181,106,182,183,184,165,174,147,17,290,190,202,159,161,33,130,139,144,204,193,291,292,191,195])))}),qle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/e2e",staticData:{pageTitle:"common.mainPanelTabs.e2e",defaultMain:"e2e",mainView:"e2e"},component:Fe(()=>je(()=>import("./agent-e2e-CgGLFkHe.js"),__vite__mapDeps([296,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,21,97,29,30,14,252,187,167,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,34,180,283,177,178,179,131,98,181,106,182,183,184,165,174,147,17,290,190,202,159,161,33,130,139,144,204,193,291,292,191,195])))}),Vle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/analytics",staticData:{pageTitle:"common.mainPanelTabs.analytics",defaultMain:"analytics",mainView:"analytics"},validateSearch:we({view:q().optional()}),component:Fe(()=>je(()=>import("./agent-analytics-Dlpy_544.js"),__vite__mapDeps([297,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,21,147,14,214,215,216,217,97,252,218,248,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,34,180,283,177,178,179,131,98,29,30,181,106,182,183,184,165,174,17,290,190,202,159,161,33,130,139,144,204,193,291,292,191,195])))}),Hle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/taskboard-analytics",staticData:{pageTitle:"taskBoard.analytics.title",defaultMain:"board",mainView:"board"},component:Fe(()=>je(()=>import("./taskboard-analytics-2fBMPAxC.js"),__vite__mapDeps([298,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,240,182,21,227,241,130,139,30,232,242,214,215,216,217,14,225,24,25,128,124,243,244,245,246,247,218,248,129,228])))}),Gle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/experiments",staticData:{pageTitle:"common.mainPanelTabs.experiments",defaultMain:"experiments",mainView:"experiments"},validateSearch:we({ui:Ze("legacy").optional()}),component:Fe(()=>je(()=>import("./agent-experiments-CpXLJckI.js"),__vite__mapDeps([299,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,21,14,29,30,252,300,301,34,97,230,237,244,217,215,245,246,216,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,180,283,177,178,179,131,98,181,106,182,183,184,165,174,147,17,290,190,202,159,161,33,130,139,144,204,193,291,292,191,195])))}),Wle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/cdn",staticData:{pageTitle:"common.mainPanelTabs.cdn",defaultMain:"cdn",mainView:"cdn"},component:Fe(()=>je(()=>import("./agent-monitor-BRq8qrkU.js"),__vite__mapDeps([302,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,214,215,216,217,252,130,218,248,247,245,246,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,97,34,180,283,177,178,179,131,98,29,30,181,106,182,21,183,184,165,174,147,17,290,190,202,159,161,33,139,144,204,193,291,292,191,195,256,176,138])))}),Kle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/apps/$connectionId/$toolName",staticData:{pageTitle:"page.app",defaultMain:"app",mainView:"app"},component:Fe(()=>je(()=>import("./agent-app-DtmEOrmX.js"),__vite__mapDeps([303,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,203,304,158,202,188,189,190,151,137,136,152,153,129,124,95,100,101,102,103,98,104,105,106,107,7,108,109,110,111])))}),Yle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/views/$viewId",staticData:{pageTitle:"page.view",defaultMain:"view",mainView:"view"},component:Fe(()=>je(()=>import("./agent-view-CgtvUhvS.js"),__vite__mapDeps([305,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,304,158,202,188,189,190,151,137,136,152,153,129,124,95,100,101,102,103,98,104,105,106,107,7,108,109,110,111,288,282,16,289,25,97,34,180,283,177,178,179,131,29,30,181,182,21,183,184,165,174,147,17,290,159,161,33,130,139,144,204,193,291,292,191,195])))}),Zle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/outputs/file",staticData:{pageTitle:"page.file",defaultMain:"file",mainView:"file"},validateSearch:we({key:q().optional()}),component:Fe(()=>je(()=>import("./agent-file-Cak5KHUl.js"),__vite__mapDeps([306,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,165,209,174,210,211,162,163,153,192,151,137,136,152,288,109,102,110,111,282,16,289,25,107,7,97,34,180,283,177,178,179,131,98,29,30,181,106,182,21,183,184,147,17,290,190,202,159,161,33,130,139,144,204,193,291,292,191,195])))}),Qle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/outputs/deck",staticData:{pageTitle:"page.document",defaultMain:"deck",mainView:"deck"},validateSearch:we({path:q().optional()}),component:Fe(()=>je(()=>import("./agent-deck--kR-tnhH.js"),__vite__mapDeps([307,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,208,174,130,288,109,102,110,111,151,137,136,152,153,282,16,289,25,107,7,97,34,180,283,177,178,179,131,98,29,30,181,106,182,21,183,184,165,147,17,290,190,202,159,161,33,139,144,204,193,291,292,191,195])))}),Jle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/library/file",staticData:{pageTitle:"page.file",defaultMain:"library-file",mainView:"library-file"},validateSearch:we({path:q().optional()}),component:Fe(()=>je(()=>import("./agent-library-file-CZlCJsi6.js"),__vite__mapDeps([308,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,309,207,208,174,130,209,210,211,165,162,163,153,288,109,102,110,111,151,137,136,152,282,16,289,25,107,7,97,34,180,283,177,178,179,131,98,29,30,181,106,182,21,183,184,147,17,290,190,202,159,161,33,139,144,204,193,291,292,191,195])))}),Xle=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Ro,path:"/connect-sources",staticData:{pageTitle:"settings.nav.connect",defaultMain:"connect-sources",mainView:"connect-sources"},component:Fe(()=>je(()=>import("./agent-connect-sources-C_fgxaTV.js"),__vite__mapDeps([310,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,99,95,100,101,102,103,98,104,105,106,107,7,108,109,110,111,155,112])))}),ece=Ne({getParentRoute:()=>Ro,path:"/$legacyView",component:()=>null}),tce=Ne({getParentRoute:()=>Mn,path:"/agents",validateSearch:rm,beforeLoad:({params:e,search:t})=>{const o=t.virtualmcpid?.trim();throw Jo(o?{to:"/$org/projects/$agentId",params:{org:e.org,agentId:o},search:a=>a,hash:!0,replace:!0}:{to:"/$org/projects",params:{org:e.org},search:a=>a,hash:!0,replace:!0})}}),oce=Ne({getParentRoute:()=>Mn,path:"/agents/$",validateSearch:rm,beforeLoad:({params:e,location:t})=>{const o=e._splat?.split("/").find(Boolean);if(!w3(o))return;const a=Xse(t.pathname);if(!a)return;const n=t.hash?`#${t.hash}`:"";throw Jo({href:`${a}${t.searchStr}${n}`,replace:!0})},component:Fe(()=>je(()=>import("./legacy-agents-deep-BSzJqFgZ.js"),__vite__mapDeps([311,205,70])))}),ace=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/tasks/{-$taskKey}",staticData:{pageTitle:"sidebar.navDestinations.tasks",defaultMain:"board",mainView:"board"},validateSearch:we({task:q().optional(),...ak}),beforeLoad:({params:e,search:t})=>{const o=T3(e.taskKey,t);if(o)throw Jo({to:"/$org/tasks/{-$taskKey}",params:{org:e.org,taskKey:o.taskKey},search:o.search,hash:!0,replace:!0})},component:Fe(()=>je(()=>import("./tasks-CqyFd60l.js"),__vite__mapDeps([312,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,226,124,125,227,228,130,160,158,98,161,162,163,153,24,25,137,151,136,152,173,229,21,33,34,174,219,26,230,140,141,175,133,29,30,129,128,231,232,233,187,234,235,236,197,237,180,103,238,184,186,188,189,190,191,159,192,165,183,200,169,166,239,256,176,138,257])))}),nce=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/taskboard-analytics",staticData:{defaultMain:"board",mainView:"board"},component:Fe(()=>je(()=>import("./taskboard-analytics-2fBMPAxC.js"),__vite__mapDeps([298,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,240,182,21,227,241,130,139,30,232,242,214,215,216,217,14,225,24,25,128,124,243,244,245,246,247,218,248,129,228])))}),rce=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/thread-analytics",staticData:{defaultMain:"board",mainView:"board"},component:Fe(()=>je(()=>import("./thread-analytics-CtoXhN32.js"),__vite__mapDeps([313,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,242,214,215,216,217,14,225,24,25,21,128,124,243,244,245,246,247,218,248,142,228,130,29,30,167,238,184,186,187,163,160,158,98,161,162,153,137,151,136,152,188,189,190,191,180,159,192,165,183,200])))}),ice=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/reports",staticData:{pageTitle:"sidebar.navDestinations.reports",defaultMain:"reports",mainView:"reports"},validateSearch:we({connect:kv().optional(),siteUrl:q().optional()}),component:Fe(()=>je(()=>import("./reports-CJkqLIIg.js"),__vite__mapDeps([314,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,259,95,154,101,102,103,221,112,113,223,143])))}),sce=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/library",staticData:{pageTitle:"sidebar.navDestinations.library",defaultMain:"files",mainView:"files"},validateSearch:we(nv),component:Fe(()=>je(()=>import("./library-BfEEZWGX.js"),__vite__mapDeps([315,153,121,198,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,309,207,208,174,130,209,210,211,165,162,163,249,230,97,152,250,34,206,251,252,225,24,25,14,175,133])))}),lce=Ne({pendingComponent:oo,errorComponent:Zt,getParentRoute:()=>Mn,path:"/discover",staticData:{pageTitle:"sidebar.navDestinations.discover",defaultMain:"discover",mainView:"discover"},component:Fe(()=>je(()=>import("./discover-DlwaiXCQ.js"),__vite__mapDeps([316,198,121,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148,180,175,133,204,111])))}),cce=Ne({getParentRoute:()=>Zv,path:"/members",beforeLoad:({params:e})=>{throw Jo({to:"/$org/settings/members",params:{org:e.org}})}}),dce=we({main:io([q(),Ze(0)]).optional(),virtualmcpid:q().optional(),..._3,sidepanel:CL,mainpanel:EL,thread:q().optional()}),uce=Ne({getParentRoute:()=>Qv,path:"/",validateSearch:dce,pendingComponent:Md,component:Fe(()=>je(()=>import("./index-PaA2bHVT.js"),__vite__mapDeps([317,205,70])))}),pce=Ne({getParentRoute:()=>Qv,path:"/t/$taskKey",beforeLoad:({params:e})=>{throw Jo({to:"/$org/tasks/{-$taskKey}",params:{org:e.org,taskKey:e.taskKey},search:t=>t,hash:!0,replace:!0})}}),so=Ne({staticData:{pageTitle:"sidebar.navDestinations.settings"},getParentRoute:()=>Zv,path:"/settings",pendingComponent:Md,component:Fe(()=>je(()=>import("./route-DmXxzobK.js"),__vite__mapDeps([318,121,198,118,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,119,120,88,35,81,36,67,68,8,70,69,66,79,3,2,80,82,122,84,31,123,38,19,71,72,73,74,75,76,28,77,78,83,85,86,87,22,10,89,90,91,199,148])))}),mce=Ne({getParentRoute:()=>so,path:"/",component:Fe(()=>je(()=>import("./index-redirect-6gCqz6Y5.js"),__vite__mapDeps([319,320])))}),hce=Ne({staticData:{pageTitle:"settings.nav.connections"},getParentRoute:()=>so,path:"/connections",component:Fe(()=>je(()=>import("./connections-Dc6s7_rq.js"),__vite__mapDeps([321,109,102,110,111,322,15,55,84,31,225,21,17,18,182,178,85,86,179,82,74,45,41,42,43,44,46,47,39,48,32,49,40,50,51,52,53,54,56,57,58,59,60,61,62,63,20,64,65,16,323,97,183,121,131,98,28,29,30,34,180,68,8,67,190,66,181,106,107,7,147]))),validateSearch:Gr(()=>we({action:So(["create"]).optional(),tab:So(["all","connected"]).optional()}))}),gce=Ne({staticData:{pageTitle:"settings.nav.connections"},getParentRoute:()=>so,path:"/connections/$appSlug",component:Fe(()=>je(()=>import("./connection-detail-AG67uG4I.js"),__vite__mapDeps([324,109,102,110,111,16,181,61,62,325,68,8,202,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,18,63,20,64,65,180,29,30,31,215,301,73,130,84,67,121,326,78,79,3,2,80,81,35,82,290,21,190,7,175,133,19,107,74,122,98,28,159,323,97,327,214,216,217,218,248,244,243,245,246,247,167,179,189,87]))),validateSearch:Gr(()=>we({tab:q().optional()}))}),fce=Ne({staticData:{pageTitle:"page.item"},getParentRoute:()=>so,path:"/connections/$appSlug/$collectionName/$itemId",component:Fe(()=>je(()=>import("./collection-detail--7z4uSdQ.js"),__vite__mapDeps([328,16,68,8,98,28,34,325,202,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,180,109,102,110,111,29,30,31,215,301,73,130,84,67,121,326,78,79,3,2,80,81,35,82,189,190,233,179,290,21,7,188,74,151,69,70,66,89,137,136,152,153,88,38,19,71,72,75,76,77,83,85,86,87,22,10,90,91,271,211,252]))),validateSearch:Gr(()=>we({replayId:q().optional()}))}),vce=Ne({staticData:{pageTitle:"orgs.monitoring.title"},getParentRoute:()=>so,path:"/monitor",component:Fe(()=>je(()=>import("./index-D_aXURjc.js"),__vite__mapDeps([329,17,18,16,330,331,320,186,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,62,63,20,64,65,24,25,187,163,160,158,98,28,161,162,153,121,69,70,66,67,68,8,84,31,137,79,3,2,80,81,35,82,151,89,136,152,88,71,188,189,190,191,38,19,72,73,74,75,76,77,78,83,85,86,87,22,10,90,91,122,180,159,192,165,179,21,130,271,211,175,133,285,147,29,30,241,139,232,34,182,33,233,327,214,215,216,217,218,248,244,243,245,246,247,238,184,183,200,14,286,219]))),validateSearch:Gr(()=>we({tab:So(["overview","audit","dashboards","threads","automations"]).default("threads"),from:q().default("now-24h"),to:q().default("now"),connectionId:Be(q()).optional().default([]),virtualMcpId:Be(q()).optional().default([]),tool:q().default(""),status:So(["all","success","errors"]).default("all"),search:q().default(""),page:Mt().optional(),streaming:$t().default(!0),propertyFilters:q().default(""),hideSystem:$t().default(!1)}))}),bce=Ne({staticData:{pageTitle:"settings.nav.general"},getParentRoute:()=>so,path:"/general",component:Fe(()=>je(()=>import("./general-BHuT0FSK.js"),__vite__mapDeps([332,133,283,19,20,333,33,40,88,35,81,272,180,68,8,334,21,29,30,31,32,97,320])))}),yce=Ne({staticData:{pageTitle:"settings.nav.connect"},getParentRoute:()=>so,path:"/connect",pendingComponent:Bi("connect"),component:Fe(()=>je(()=>import("./connect-BbV6U_hr.js"),__vite__mapDeps([335,233,21,29,30,31,32,167,163,50,56,57,222,336,42,61,62,97,28,68,8,330,331,320])))}),Sce=Ne({staticData:{pageTitle:"settings.nav.billing"},getParentRoute:()=>so,path:"/ai-providers",pendingComponent:Bi("billing"),component:Fe(()=>je(()=>import("./ai-providers-jNZBkRl5.js"),__vite__mapDeps([337,42,136,48,88,35,81,281,131,121,151,69,70,66,67,68,8,89,79,3,2,80,82,137,152,153,170,147,29,30,31,32,44,49,56,43,18,171,58,19,20,53,283,168,97,169,138,61,62,289,25,33,330,331,320])))}),wce=Ne({staticData:{pageTitle:"settings.nav.billing"},getParentRoute:()=>so,path:"/billing",beforeLoad:({params:e})=>{throw Jo({to:"/$org/settings/ai-providers",params:{org:e.org}})}}),Tce=Ne({staticData:{pageTitle:"settings.nav.billing"},getParentRoute:()=>so,path:"/infra-billing",pendingComponent:Bi("billing"),component:Fe(()=>je(()=>import("./infra-billing-hHO33Bt1.js"),__vite__mapDeps([338,51,21,285,147,32,72,73,18,130,29,30,31,14,218,217,215,248,246,330,331,320])))}),xce=Ne({staticData:{pageTitle:"settings.nav.secrets"},getParentRoute:()=>so,path:"/secrets",component:Fe(()=>je(()=>import("./secrets-CZl02iRQ.js"),__vite__mapDeps([339,42,61,20,64,28,29,30,31,32,34,292,330,331,320])))}),_ce=Ne({staticData:{pageTitle:"settings.nav.connect"},getParentRoute:()=>so,path:"/api-keys",pendingComponent:Bi("connect"),component:Fe(()=>je(()=>import("./api-keys-DXlZlPNT.js"),__vite__mapDeps([340,336,42,50,56,61,62,97,28,68,8,330,331,320])))}),kce=Ne({staticData:{pageTitle:"settings.nav.storage"},getParentRoute:()=>so,path:"/buckets",pendingComponent:Bi("storage"),component:Fe(()=>je(()=>import("./buckets-Qu8B15tT.js"),__vite__mapDeps([341,42,61,62,97,28,29,30,31,32,33,34,120,330,331,320])))}),Cce=Ne({staticData:{pageTitle:"settings.nav.repositories"},getParentRoute:()=>so,path:"/repositories",validateSearch:we({git_error:q().optional().catch(void 0),git_flow:q().uuid().optional().catch(void 0),git_installation:Mt().int().positive().safe().optional().catch(void 0),git_return:$t().optional().catch(void 0)}),pendingComponent:Bi("repositories"),component:Fe(()=>je(()=>import("./repositories-Ddu7D_dm.js"),__vite__mapDeps([342,83,44,61,84,31,28,85,86,87,18,46,19,20,22,88,35,81,45,147,64,97,21,233,148,29,30,32,34,62,291,292,330,331,320])))}),Ece=Ne({staticData:{pageTitle:"settings.nav.storage"},getParentRoute:()=>so,path:"/synced-repos",pendingComponent:Bi("storage"),component:Fe(()=>je(()=>import("./synced-repos-gT4FkxhN.js"),__vite__mapDeps([343,61,97,83,44,84,31,28,85,86,87,18,46,19,20,22,88,35,81,250,24,25,330,331,320])))}),Pce=Ne({staticData:{pageTitle:"settings.nav.tasks"},getParentRoute:()=>so,path:"/task-board",component:Fe(()=>je(()=>import("./tasks-IL-LS75-.js"),__vite__mapDeps([344,147,34,49,60,61,228,72,73,18,130,285,21,32,29,30,31,33,97,284,333,40,88,35,81,272,180,68,8,22,219,229,65,148,84,122,174,85,86,80,2,330,331,320])))}),Ace=Ne({getParentRoute:()=>so,path:"/tasks",beforeLoad:({params:e})=>{throw Jo({to:"/$org/settings/task-board",params:{org:e.org}})}}),Rce=Ne({staticData:{pageTitle:"projects.settings.title"},getParentRoute:()=>so,path:"/projects",component:Fe(()=>je(()=>import("./projects-DfF5wpqY.js"),__vite__mapDeps([345,41,42,43,15,44,45,46,47,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,61,18,62,63,20,64,65,21,17,76,28,77,68,8,78,67,79,3,2,80,81,35,82,83,84,31,85,86,87,19,22,88,223,289,25,154,101,102,103,143,66,180])))}),Dce=Ne({staticData:{pageTitle:"settings.nav.members"},getParentRoute:()=>so,path:"/members",pendingComponent:Bi("members"),component:Fe(()=>je(()=>import("./members-Bunz7e6B.js"),__vite__mapDeps([346,322,15,55,84,31,225,21,17,18,13,14,16,132,98,28,29,30,32,34,133,134,19,20,24,25,26,175,347,97,52,56,62,65,147,72,73,130,61,231,330,331,320])))}),Oce=Ne({staticData:{pageTitle:"settings.nav.members"},getParentRoute:()=>so,path:"/roles",pendingComponent:Bi("members"),component:Fe(()=>je(()=>import("./roles-B4ZkD532.js"),__vite__mapDeps([348,134,133,347,21,97,52,61,62,13,14,15,16,17,18,171,74,45,41,42,43,44,46,47,39,48,32,49,40,50,51,53,54,55,56,57,58,59,60,63,20,64,65,183,147,184,86,68,8,87,110,111,175,26,180,67,136,19,33,84,31,75,66,331,320]))),validateSearch:Gr(()=>we({role:q().optional()}))}),Mce=Ne({staticData:{pageTitle:"settings.nav.security"},getParentRoute:()=>so,path:"/sso",component:Fe(()=>je(()=>import("./sso-D804RM9B.js"),__vite__mapDeps([349,334,21,29,30,31,32,97,33,90,62,330,331,320])))}),Nce=Ne({staticData:{pageTitle:"settings.nav.profile"},getParentRoute:()=>so,path:"/profile",component:Fe(()=>je(()=>import("./profile-CtDXcfuO.js"),__vite__mapDeps([350,19,20,300,301,30,62,63,33,29,31,32,168,58,59,60,283,149])))}),Ice=Ne({staticData:{pageTitle:"settings.nav.agents"},getParentRoute:()=>so,path:"/agents",component:Fe(()=>je(()=>import("./agents-list-BVqV3SYd.js"),__vite__mapDeps([351,67,68,8,52,43,62,41,42,15,44,45,46,47,39,48,32,49,40,50,51,53,54,55,56,57,58,59,60,61,18,63,20,64,65,289,25,78,79,3,2,80,81,35,82,88,16,326,180,106,107,7,109,102,110,111,83,84,31,28,85,86,87,19,22,103,104,97,17,77])))}),Lce=Ne({staticData:{pageTitle:"settings.nav.automations"},getParentRoute:()=>so,path:"/automations",component:Fe(()=>je(()=>import("./automations-D9LXua4J.js"),__vite__mapDeps([352,61,47,17,18,16,219,68,8,78,67,79,3,2,80,81,35,82,279,21,97,41,42,43,15,44,45,46,39,48,32,49,40,50,51,52,53,54,55,56,57,58,59,60,62,63,20,64,65,330,331,320])))}),Bce=Ne({staticData:{pageTitle:"settings.nav.skills"},getParentRoute:()=>so,path:"/skills",component:Fe(()=>je(()=>import("./skills-BqpJ6duC.js"),__vite__mapDeps([353,52,47,62,63,17,18,97,16,182,21,251,162,163,50,153,121,69,70,66,67,68,8,209,174,85,86,210,53,211,165])))}),Fce=Ne({staticData:{pageTitle:"settings.nav.memory"},getParentRoute:()=>so,path:"/memory",component:Fe(()=>je(()=>import("./memory-BLa9O78J.js"),__vite__mapDeps([354,39,20,233,84,31,182,21,16,71,174,85,86]))),validateSearch:Gr(()=>we({scope:So(["user"]).optional()}))}),jce=so.addChildren([mce,hce,gce,fce,Ice,Lce,Bce,Fce,vce,bce,yce,Sce,wce,Tce,xce,_ce,kce,Cce,Ece,Pce,Ace,Rce,Dce,Oce,Mce,Nce]),zce=Jv.addChildren([Nle,Ile,Lle]),Uce=Ro.addChildren([Dle,Ole,Mle,zce,Ble,Fle,jle,zle,Ule,$le,qle,Vle,Hle,Gle,Wle,Kle,Yle,Zle,Qle,Jle,Xle,ece]),$ce=Mn.addChildren([Ple,Ale,Rle,Uce,tce,oce,ace,nce,rce,ice,sce,lce]),qce=Qv.addChildren([uce,pce,$ce]),Vce=Zv.addChildren([qce,cce,jce]),Hce=nk.addChildren([Sle,Vce]),Gce=pn.addChildren([Hce,yle,wle,Tle,xle,_le,kle,cle,dle,ule,ple,mle,hle]);function Wce(){const e=Re.c(16),t=ar();let o;e[0]!==t?(o=t("common.index.pageNotFound"),e[0]=t,e[1]=o):o=e[1];let a;e[2]!==o?(a=w.jsx("h3",{className:"text-lg font-medium text-foreground",children:o}),e[2]=o,e[3]=a):a=e[3];let n;e[4]!==t?(n=t("common.index.pageNotFoundDescription"),e[4]=t,e[5]=n):n=e[5];let i;e[6]!==n?(i=w.jsx("p",{className:"text-sm text-muted-foreground text-center max-w-[300px]",children:n}),e[6]=n,e[7]=i):i=e[7];let l;e[8]!==t?(l=t("common.goBack"),e[8]=t,e[9]=l):l=e[9];let c;e[10]!==l?(c=w.jsx("button",{type:"button",onClick:Kce,className:"text-sm text-primary hover:underline",children:l}),e[10]=l,e[11]=c):c=e[11];let u;return e[12]!==a||e[13]!==i||e[14]!==c?(u=w.jsx("div",{className:"flex h-full items-center justify-center",children:w.jsxs("div",{className:"flex flex-col items-center gap-4 p-8",children:[a,i,c]})}),e[12]=a,e[13]=i,e[14]=c,e[15]=u):u=e[15],u}function Kce(){return window.history.back()}const Xv=F$({routeTree:Gce,defaultPendingComponent:Md,defaultPendingMs:200,defaultPendingMinMs:500,defaultNotFoundComponent:Wce});function Ee(...e){return kL(u_(e))}function Yce(e){return/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(e)}function $o({error:e,localization:t,localizeErrors:o=!0}){var a;const n="Request failed";if(!o)return e?.message?e.message:(a=e?.error)!=null&&a.message?e.error.message:n;if(typeof e=="string"&&t?.[e])return t[e];if(e?.error){if(e.error.code){const i=e.error.code;if(t?.[i])return t[i]}return e.error.message||e.error.code||e.error.statusText||t?.REQUEST_FAILED}return e?.message||t?.REQUEST_FAILED||n}function Ul(e){return typeof window<"u"?new URLSearchParams(window.location.search).get(e):null}function XT(e,t){for(const o in e)if(e[o]===t)return o}function Bp(e,t){let o=q().min(1,{message:t?.PASSWORD_REQUIRED});return e?.minLength&&(o=o.min(e.minLength,{message:t?.PASSWORD_TOO_SHORT})),e?.maxLength&&(o=o.max(e.maxLength,{message:t?.PASSWORD_TOO_LONG})),e?.regex&&(o=o.regex(e.regex,{message:t?.INVALID_PASSWORD})),o}var Zce={FAILED_TO_CREATE_USER:"Failed to create user",USER_ALREADY_EXISTS:"User already exists",YOU_CANNOT_BAN_YOURSELF:"You cannot ban yourself",YOU_ARE_NOT_ALLOWED_TO_CHANGE_USERS_ROLE:"You are not allowed to change users role",YOU_ARE_NOT_ALLOWED_TO_CREATE_USERS:"You are not allowed to create users",YOU_ARE_NOT_ALLOWED_TO_LIST_USERS:"You are not allowed to list users",YOU_ARE_NOT_ALLOWED_TO_LIST_USERS_SESSIONS:"You are not allowed to list users sessions",YOU_ARE_NOT_ALLOWED_TO_BAN_USERS:"You are not allowed to ban users",YOU_ARE_NOT_ALLOWED_TO_IMPERSONATE_USERS:"You are not allowed to impersonate users",YOU_ARE_NOT_ALLOWED_TO_REVOKE_USERS_SESSIONS:"You are not allowed to revoke users sessions",YOU_ARE_NOT_ALLOWED_TO_DELETE_USERS:"You are not allowed to delete users",YOU_ARE_NOT_ALLOWED_TO_SET_USERS_PASSWORD:"You are not allowed to set users password",BANNED_USER:"You have been banned from this application"},Qce={FAILED_TO_CREATE_USER:"Failed to create user",COULD_NOT_CREATE_SESSION:"Could not create session",ANONYMOUS_USERS_CANNOT_SIGN_IN_AGAIN_ANONYMOUSLY:"Anonymous users cannot sign in again anonymously"},Jce={INVALID_METADATA_TYPE:"metadata must be an object or undefined",REFILL_AMOUNT_AND_INTERVAL_REQUIRED:"refillAmount is required when refillInterval is provided",REFILL_INTERVAL_AND_AMOUNT_REQUIRED:"refillInterval is required when refillAmount is provided",USER_BANNED:"User is banned",UNAUTHORIZED_SESSION:"Unauthorized or invalid session",KEY_NOT_FOUND:"API Key not found",KEY_DISABLED:"API Key is disabled",KEY_EXPIRED:"API Key has expired",USAGE_EXCEEDED:"API Key has reached its usage limit",KEY_NOT_RECOVERABLE:"API Key is not recoverable",EXPIRES_IN_IS_TOO_SMALL:"The expiresIn is smaller than the predefined minimum value.",EXPIRES_IN_IS_TOO_LARGE:"The expiresIn is larger than the predefined maximum value.",INVALID_REMAINING:"The remaining count is either too large or too small.",INVALID_PREFIX_LENGTH:"The prefix length is either too large or too small.",INVALID_NAME_LENGTH:"The name length is either too large or too small.",METADATA_DISABLED:"Metadata is disabled.",RATE_LIMIT_EXCEEDED:"Rate limit exceeded.",NO_VALUES_TO_UPDATE:"No values to update.",KEY_DISABLED_EXPIRATION:"Custom key expiration values are disabled.",INVALID_API_KEY:"Invalid API key.",INVALID_USER_ID_FROM_API_KEY:"The user id from the API key is invalid.",INVALID_API_KEY_GETTER_RETURN_TYPE:"API Key getter returned an invalid key type. Expected string.",SERVER_ONLY_PROPERTY:"The property you're trying to set can only be set from the server auth instance only."},Xce={USER_NOT_FOUND:"User not found",FAILED_TO_CREATE_USER:"Failed to create user",FAILED_TO_CREATE_SESSION:"Failed to create session",FAILED_TO_UPDATE_USER:"Failed to update user",FAILED_TO_GET_SESSION:"Failed to get session",INVALID_PASSWORD:"Invalid password",INVALID_EMAIL:"Invalid email",INVALID_EMAIL_OR_PASSWORD:"Invalid email or password",SOCIAL_ACCOUNT_ALREADY_LINKED:"Social account already linked",PROVIDER_NOT_FOUND:"Provider not found",INVALID_TOKEN:"Invalid token",ID_TOKEN_NOT_SUPPORTED:"id_token not supported",FAILED_TO_GET_USER_INFO:"Failed to get user info",USER_EMAIL_NOT_FOUND:"User email not found",EMAIL_NOT_VERIFIED:"Email not verified",PASSWORD_TOO_SHORT:"Password too short",PASSWORD_TOO_LONG:"Password too long",USER_ALREADY_EXISTS:"User already exists",EMAIL_CAN_NOT_BE_UPDATED:"Email can not be updated",CREDENTIAL_ACCOUNT_NOT_FOUND:"Credential account not found",SESSION_EXPIRED:"Session expired. Re-authenticate to perform this action.",FAILED_TO_UNLINK_LAST_ACCOUNT:"You can't unlink your last account",ACCOUNT_NOT_FOUND:"Account not found",USER_ALREADY_HAS_PASSWORD:"User already has a password. Provide that to delete the account."},ede={VERIFICATION_FAILED:"Captcha verification failed",MISSING_RESPONSE:"Missing CAPTCHA response",UNKNOWN_ERROR:"Something went wrong"},tde={MISSING_SECRET_KEY:"Missing secret key",SERVICE_UNAVAILABLE:"CAPTCHA service unavailable"},ode={...ede,...tde},ade={OTP_EXPIRED:"otp expired",INVALID_OTP:"Invalid OTP",INVALID_EMAIL:"Invalid email",USER_NOT_FOUND:"User not found",TOO_MANY_ATTEMPTS:"Too many attempts"},nde={INVALID_OAUTH_CONFIGURATION:"Invalid OAuth configuration"},rde={PASSWORD_COMPROMISED:"The password you entered has been compromised. Please choose a different password."},ide={INVALID_SESSION_TOKEN:"Invalid session token"},sde={YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_ORGANIZATION:"You are not allowed to create a new organization",YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_ORGANIZATIONS:"You have reached the maximum number of organizations",ORGANIZATION_ALREADY_EXISTS:"Organization already exists",ORGANIZATION_NOT_FOUND:"Organization not found",USER_IS_NOT_A_MEMBER_OF_THE_ORGANIZATION:"User is not a member of the organization",YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_ORGANIZATION:"You are not allowed to update this organization",YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_ORGANIZATION:"You are not allowed to delete this organization",NO_ACTIVE_ORGANIZATION:"No active organization",USER_IS_ALREADY_A_MEMBER_OF_THIS_ORGANIZATION:"User is already a member of this organization",MEMBER_NOT_FOUND:"Member not found",ROLE_NOT_FOUND:"Role not found",YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM:"You are not allowed to create a new team",TEAM_ALREADY_EXISTS:"Team already exists",TEAM_NOT_FOUND:"Team not found",YOU_CANNOT_LEAVE_THE_ORGANIZATION_AS_THE_ONLY_OWNER:"You cannot leave the organization as the only owner",YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_MEMBER:"You are not allowed to delete this member",YOU_ARE_NOT_ALLOWED_TO_INVITE_USERS_TO_THIS_ORGANIZATION:"You are not allowed to invite users to this organization",USER_IS_ALREADY_INVITED_TO_THIS_ORGANIZATION:"User is already invited to this organization",INVITATION_NOT_FOUND:"Invitation not found",YOU_ARE_NOT_THE_RECIPIENT_OF_THE_INVITATION:"You are not the recipient of the invitation",YOU_ARE_NOT_ALLOWED_TO_CANCEL_THIS_INVITATION:"You are not allowed to cancel this invitation",INVITER_IS_NO_LONGER_A_MEMBER_OF_THE_ORGANIZATION:"Inviter is no longer a member of the organization",YOU_ARE_NOT_ALLOWED_TO_INVITE_USER_WITH_THIS_ROLE:"you are not allowed to invite user with this role",FAILED_TO_RETRIEVE_INVITATION:"Failed to retrieve invitation",YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_TEAMS:"You have reached the maximum number of teams",UNABLE_TO_REMOVE_LAST_TEAM:"Unable to remove last team",YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_MEMBER:"You are not allowed to update this member",ORGANIZATION_MEMBERSHIP_LIMIT_REACHED:"Organization membership limit reached",YOU_ARE_NOT_ALLOWED_TO_CREATE_TEAMS_IN_THIS_ORGANIZATION:"You are not allowed to create teams in this organization",YOU_ARE_NOT_ALLOWED_TO_DELETE_TEAMS_IN_THIS_ORGANIZATION:"You are not allowed to delete teams in this organization",YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_TEAM:"You are not allowed to update this team",YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_TEAM:"You are not allowed to delete this team",INVITATION_LIMIT_REACHED:"Invitation limit reached"},lde={CHALLENGE_NOT_FOUND:"Challenge not found",YOU_ARE_NOT_ALLOWED_TO_REGISTER_THIS_PASSKEY:"You are not allowed to register this passkey",FAILED_TO_VERIFY_REGISTRATION:"Failed to verify registration",PASSKEY_NOT_FOUND:"Passkey not found",AUTHENTICATION_FAILED:"Authentication failed",UNABLE_TO_CREATE_SESSION:"Unable to create session",FAILED_TO_UPDATE_PASSKEY:"Failed to update passkey"},cde={INVALID_PHONE_NUMBER:"Invalid phone number",PHONE_NUMBER_EXIST:"Phone number already exists",INVALID_PHONE_NUMBER_OR_PASSWORD:"Invalid phone number or password",UNEXPECTED_ERROR:"Unexpected error",OTP_NOT_FOUND:"OTP not found",OTP_EXPIRED:"OTP expired",INVALID_OTP:"Invalid OTP",PHONE_NUMBER_NOT_VERIFIED:"Phone number not verified"},dde={SUBSCRIPTION_NOT_FOUND:"Subscription not found",SUBSCRIPTION_PLAN_NOT_FOUND:"Subscription plan not found",ALREADY_SUBSCRIBED_PLAN:"You're already subscribed to this plan",UNABLE_TO_CREATE_CUSTOMER:"Unable to create customer",FAILED_TO_FETCH_PLANS:"Failed to fetch plans",EMAIL_VERIFICATION_REQUIRED:"Email verification is required before you can subscribe to a plan",SUBSCRIPTION_NOT_ACTIVE:"Subscription is not active",SUBSCRIPTION_NOT_SCHEDULED_FOR_CANCELLATION:"Subscription is not scheduled for cancellation"},ude={TEAM_LIMIT_REACHED:"Team limit reached for this organization",TEAM_MEMBER_LIMIT_REACHED:"Team member limit reached for this team",TEAM_NOT_FOUND:"Team not found",TEAM_MEMBER_NOT_FOUND:"Team member not found",TEAM_NAME_TOO_LONG:"Team name is too long",CANNOT_REMOVE_LAST_TEAM:"Cannot remove the last team",NOT_ORGANIZATION_MEMBER:"User is not a member of the organization",ALREADY_TEAM_MEMBER:"User is already a member of this team",INSUFFICIENT_TEAM_PERMISSIONS:"Insufficient permissions to perform this action on team"},pde={OTP_NOT_ENABLED:"OTP not enabled",OTP_HAS_EXPIRED:"OTP has expired",TOTP_NOT_ENABLED:"TOTP not enabled",TWO_FACTOR_NOT_ENABLED:"Two factor isn't enabled",BACKUP_CODES_NOT_ENABLED:"Backup codes aren't enabled",INVALID_BACKUP_CODE:"Invalid backup code",INVALID_CODE:"Invalid code",TOO_MANY_ATTEMPTS_REQUEST_NEW_CODE:"Too many attempts. Please request a new code.",INVALID_TWO_FACTOR_COOKIE:"Invalid two factor cookie"},mde={INVALID_USERNAME_OR_PASSWORD:"invalid username or password",EMAIL_NOT_VERIFIED:"email not verified",UNEXPECTED_ERROR:"unexpected error",USERNAME_IS_ALREADY_TAKEN:"username is already taken. please try another.",USERNAME_TOO_SHORT:"username is too short",USERNAME_TOO_LONG:"username is too long",INVALID_USERNAME:"username is invalid"},hde={APP:"App",ACCOUNT:"Account",ACCOUNTS:"Accounts",ACCOUNTS_DESCRIPTION:"Switch between your currently signed in accounts.",ACCOUNTS_INSTRUCTIONS:"Sign in to an additional account.",ADD_ACCOUNT:"Add Account",ADD_PASSKEY:"Add Passkey",ALREADY_HAVE_AN_ACCOUNT:"Already have an account?",AVATAR:"Avatar",AVATAR_DESCRIPTION:"Click on the avatar to upload a custom one from your files.",AVATAR_INSTRUCTIONS:"An avatar is optional but strongly recommended.",BACKUP_CODE_REQUIRED:"Backup code is required",BACKUP_CODES:"Backup Codes",BACKUP_CODES_DESCRIPTION:"Save these backup codes in a secure place. You can use them to access your account if you lose your two-factor authentication method.",BACKUP_CODE_PLACEHOLDER:"Backup Code",BACKUP_CODE:"Backup Code",CANCEL:"Cancel",CHANGE_PASSWORD:"Change Password",CHANGE_PASSWORD_DESCRIPTION:"Enter your current password and a new password.",CHANGE_PASSWORD_INSTRUCTIONS:"Please use 8 characters at minimum.",CHANGE_PASSWORD_SUCCESS:"Your password has been changed.",CONFIRM_PASSWORD:"Confirm Password",CONFIRM_PASSWORD_PLACEHOLDER:"Confirm Password",CONFIRM_PASSWORD_REQUIRED:"Confirm password is required",CONTINUE_WITH_AUTHENTICATOR:"Continue with Authenticator",COPIED_TO_CLIPBOARD:"Copied to clipboard",COPY_TO_CLIPBOARD:"Copy to clipboard",COPY_ALL_CODES:"Copy all codes",CONTINUE:"Continue",CURRENT_PASSWORD:"Current Password",CURRENT_PASSWORD_PLACEHOLDER:"Current Password",CURRENT_SESSION:"Current Session",UPDATE:"Update",DELETE:"Delete",DELETE_AVATAR:"Delete Avatar",DELETE_ACCOUNT:"Delete Account",DELETE_ACCOUNT_DESCRIPTION:"Permanently remove your account and all of its contents. This action is not reversible, so please continue with caution.",DELETE_ACCOUNT_INSTRUCTIONS:"Please confirm the deletion of your account. This action is not reversible, so please continue with caution.",DELETE_ACCOUNT_VERIFY:"Please check your email to verify the deletion of your account.",DELETE_ACCOUNT_SUCCESS:"Your account has been deleted.",DISABLE_TWO_FACTOR:"Disable Two-Factor",DISABLED_CREDENTIALS_DESCRIPTION:"Choose a provider to login to your account",DONT_HAVE_AN_ACCOUNT:"Don't have an account?",DONE:"Done",EMAIL:"Email",EMAIL_DESCRIPTION:"Enter the email address you want to use to log in.",EMAIL_INSTRUCTIONS:"Please enter a valid email address.",EMAIL_IS_THE_SAME:"Email is the same",EMAIL_PLACEHOLDER:"m@example.com",EMAIL_REQUIRED:"Email address is required",EMAIL_VERIFY_CHANGE:"Please check your email to verify the change.",EMAIL_VERIFICATION:"Email Verification",EMAIL_VERIFICATION_DESCRIPTION:"Please check your email for the verification code to complete your registration.",EMAIL_VERIFICATION_SUCCESS:"Email verification successful.",ENABLE_TWO_FACTOR:"Enable Two-Factor",IS_INVALID:"is invalid",IS_REQUIRED:"is required",IS_THE_SAME:"is the same",FORGOT_AUTHENTICATOR:"Forgot authenticator?",FORGOT_PASSWORD:"Forgot Password",FORGOT_PASSWORD_ACTION:"Send reset link",FORGOT_PASSWORD_DESCRIPTION:"Enter your email to reset your password",FORGOT_PASSWORD_EMAIL:"Check your email for the password reset link.",FORGOT_PASSWORD_LINK:"Forgot your password?",LINK:"Link",MAGIC_LINK:"Magic Link",MAGIC_LINK_ACTION:"Send magic link",MAGIC_LINK_DESCRIPTION:"Enter your email to receive a magic link",MAGIC_LINK_EMAIL:"Check your email for the magic link",EMAIL_OTP:"Email Code",EMAIL_OTP_SEND_ACTION:"Send code",EMAIL_OTP_VERIFY_ACTION:"Verify code",EMAIL_OTP_DESCRIPTION:"Enter your email to receive a code",EMAIL_OTP_VERIFICATION_SENT:"Please check your email for the verification code.",NAME:"Name",NAME_DESCRIPTION:"Please enter your full name, or a display name.",NAME_INSTRUCTIONS:"Please use 32 characters at maximum.",NAME_PLACEHOLDER:"Name",NEW_PASSWORD:"New Password",NEW_PASSWORD_PLACEHOLDER:"New Password",NEW_PASSWORD_REQUIRED:"New password is required",ONE_TIME_PASSWORD:"One-Time Password",OR_CONTINUE_WITH:"Or continue with",PASSKEY:"Passkey",PASSKEYS:"Passkeys",PASSKEYS_DESCRIPTION:"Manage your passkeys for secure access.",PASSKEYS_INSTRUCTIONS:"Securely access your account without a password.",PERSONAL_ACCOUNT:"Personal Account",API_KEYS:"API Keys",API_KEYS_DESCRIPTION:"Manage your API keys for secure access.",API_KEYS_INSTRUCTIONS:"Generate API keys to access your account programmatically.",CREATE_API_KEY:"Create API Key",CREATE_API_KEY_DESCRIPTION:"Enter a unique name for your API key to differentiate it from other keys.",API_KEY_NAME_PLACEHOLDER:"New API Key",API_KEY_CREATED:"API Key Created",CREATE_API_KEY_SUCCESS:"Please copy your API key and store it in a safe place. For security reasons we cannot show it again.",NEVER_EXPIRES:"Never Expires",EXPIRES:"Expires",NO_EXPIRATION:"No Expiration",CREATE_ORGANIZATION:"Create Organization",ORGANIZATION:"Organization",ORGANIZATION_NAME:"Name",ORGANIZATION_NAME_PLACEHOLDER:"Acme Inc.",ORGANIZATION_NAME_DESCRIPTION:"This is your organization's visible name.",ORGANIZATION_NAME_INSTRUCTIONS:"Please use 32 characters at maximum.",ORGANIZATION_SLUG:"Slug URL",ORGANIZATION_SLUG_DESCRIPTION:"This is your organization's URL namespace.",ORGANIZATION_SLUG_INSTRUCTIONS:"Please use 48 characters at maximum.",ORGANIZATION_SLUG_PLACEHOLDER:"acme-inc",CREATE_ORGANIZATION_SUCCESS:"Organization created successfully",PASSWORD:"Password",PASSWORD_PLACEHOLDER:"Password",PASSWORD_REQUIRED:"Password is required",PASSWORDS_DO_NOT_MATCH:"Passwords do not match",PROVIDERS:"Providers",PROVIDERS_DESCRIPTION:"Connect your account with a third-party service.",RECOVER_ACCOUNT:"Recover Account",RECOVER_ACCOUNT_ACTION:"Recover account",RECOVER_ACCOUNT_DESCRIPTION:"Please enter a backup code to access your account",REMEMBER_ME:"Remember me",RESEND_CODE:"Resend code",RESEND_VERIFICATION_EMAIL:"Resend Verification Email",RESET_PASSWORD:"Reset Password",RESET_PASSWORD_ACTION:"Save new password",RESET_PASSWORD_DESCRIPTION:"Enter your new password below",RESET_PASSWORD_SUCCESS:"Password reset successfully",REQUEST_FAILED:"Request failed",REVOKE:"Revoke",DELETE_API_KEY:"Delete API Key",DELETE_API_KEY_CONFIRM:"Are you sure you want to delete this API key?",API_KEY:"API Key",SIGN_IN:"Sign In",SIGN_IN_ACTION:"Login",SIGN_IN_DESCRIPTION:"Enter your email below to login to your account",SIGN_IN_USERNAME_DESCRIPTION:"Enter your username or email to login to your account",SIGN_IN_WITH:"Sign in with",SIGN_OUT:"Sign Out",SIGN_UP:"Sign Up",SIGN_UP_ACTION:"Create an account",SIGN_UP_DESCRIPTION:"Enter your information to create an account",SIGN_UP_EMAIL:"Check your email for the verification link.",SESSIONS:"Sessions",SESSIONS_DESCRIPTION:"Manage your active sessions and revoke access.",SET_PASSWORD:"Set Password",SET_PASSWORD_DESCRIPTION:"Click the button below to receive an email to set up a password for your account.",SETTINGS:"Settings",SAVE:"Save",SECURITY:"Security",SWITCH_ACCOUNT:"Switch Account",TRUST_DEVICE:"Trust this device",TWO_FACTOR:"Two-Factor",TWO_FACTOR_ACTION:"Verify code",TWO_FACTOR_DESCRIPTION:"Please enter your one-time password to continue",TWO_FACTOR_CARD_DESCRIPTION:"Add an extra layer of security to your account.",TWO_FACTOR_DISABLE_INSTRUCTIONS:"Please enter your password to disable 2FA.",TWO_FACTOR_ENABLE_INSTRUCTIONS:"Please enter your password to enable 2FA.",TWO_FACTOR_ENABLED:"Two-factor authentication has been enabled",TWO_FACTOR_DISABLED:"Two-Factor Authentication has been disabled",TWO_FACTOR_PROMPT:"Two-Factor Authentication",TWO_FACTOR_TOTP_LABEL:"Scan the QR Code with your Authenticator",SEND_VERIFICATION_CODE:"Send verification code",UNLINK:"Unlink",UPDATED_SUCCESSFULLY:"updated successfully",USERNAME:"Username",USERNAME_DESCRIPTION:"Enter the username you want to use to log in.",USERNAME_INSTRUCTIONS:"Please use 32 characters at maximum.",USERNAME_PLACEHOLDER:"Username",OPTIONAL_BRACKETS:"(Optional)",SIGN_IN_USERNAME_PLACEHOLDER:"Username or email",VERIFY_YOUR_EMAIL:"Verify Your Email",VERIFY_YOUR_EMAIL_DESCRIPTION:"Please verify your email address. Check your inbox for the verification email. If you haven't received the email, click the button below to resend.",GO_BACK:"Go back",SESSION_NOT_FRESH:"Your session is not fresh. Please sign in again.",UPLOAD_AVATAR:"Upload Avatar",LOGO:"Logo",LOGO_DESCRIPTION:"Click on the logo to upload a custom one from your files.",LOGO_INSTRUCTIONS:"A logo is optional but strongly recommended.",UPLOAD:"Upload",UPLOAD_LOGO:"Upload Logo",DELETE_LOGO:"Delete Logo",PRIVACY_POLICY:"Privacy Policy",TERMS_OF_SERVICE:"Terms of Service",PROTECTED_BY_RECAPTCHA:"This site is protected by reCAPTCHA.",BY_CONTINUING_YOU_AGREE:"By continuing, you agree to the",USER:"User",ORGANIZATIONS:"Organizations",ORGANIZATIONS_DESCRIPTION:"Manage your organizations and memberships.",ORGANIZATIONS_INSTRUCTIONS:"Create an organization to collaborate with other users.",LEAVE_ORGANIZATION:"Leave Organization",LEAVE_ORGANIZATION_CONFIRM:"Are you sure you want to leave this organization?",LEAVE_ORGANIZATION_SUCCESS:"You have successfully left the organization.",MANAGE_ORGANIZATION:"Manage Organization",REMOVE_MEMBER:"Remove Member",REMOVE_MEMBER_CONFIRM:"Are you sure you want to remove this member from the organization?",REMOVE_MEMBER_SUCCESS:"Member removed successfully",INVITE_MEMBER:"Invite Member",MEMBERS:"Members",MEMBERS_DESCRIPTION:"Add or remove members and manage their roles.",MEMBERS_INSTRUCTIONS:"Invite new members to your organization.",INVITE_MEMBER_DESCRIPTION:"Send an invitation to add a new member to your organization.",ROLE:"Role",SELECT_ROLE:"Select a role",ADMIN:"Admin",MEMBER:"Member",GUEST:"Guest",OWNER:"Owner",UPDATE_ROLE_DESCRIPTION:"Update the role for this member",UPDATE_ROLE:"Update Role",MEMBER_ROLE_UPDATED:"Member role updated successfully",SEND_INVITATION:"Send Invitation",SEND_INVITATION_SUCCESS:"Invitation sent successfully",PENDING_INVITATIONS:"Pending Invitations",PENDING_INVITATIONS_DESCRIPTION:"Manage pending invitations to your organization.",PENDING_USER_INVITATIONS_DESCRIPTION:"Invitations you've received from organizations.",CANCEL_INVITATION:"Cancel Invitation",INVITATION_CANCELLED:"Invitation cancelled successfully",ACCEPT_INVITATION:"Accept Invitation",ACCEPT_INVITATION_DESCRIPTION:"You have been invited to join an organization.",INVITATION_ACCEPTED:"Invitation accepted successfully",INVITATION_REJECTED:"Invitation rejected successfully",ACCEPT:"Accept",REJECT:"Reject",INVITATION_EXPIRED:"This invitation has expired",DELETE_ORGANIZATION:"Delete Organization",DELETE_ORGANIZATION_DESCRIPTION:"Permanently remove your organization and all of its contents. This action is not reversible — please continue with caution.",DELETE_ORGANIZATION_SUCCESS:"Organization deleted successfully",DELETE_ORGANIZATION_INSTRUCTIONS:"Enter the organization slug to continue:",SLUG_REQUIRED:"Organization slug is required",SLUG_DOES_NOT_MATCH:"The slug does not match",TEAM:"Team",TEAMS:"Teams",TEAM_ACTIVE:"Active",TEAM_SET_ACTIVE:"Set Active",CREATE_TEAM:"Create Team",CREATE_TEAM_SUCCESS:"Team created successfully",UPDATE_TEAM:"Update Team",UPDATE_TEAMS:"Update Teams",SELECT_TEAMS:"Select teams",ADD:"Add",REMOVE:"Remove",UPDATE_TEAM_DESCRIPTION:"Update the name for this team",UPDATE_TEAMS_DESCRIPTION:"Add or remove teams for this member",REMOVE_TEAM_CONFIRM:"Are you sure you want to remove this team from the organization?",CREATE_TEAM_INSTRUCTIONS:"Add new team to your organization.",TEAM_NAME:"Team Name",TEAM_NAME_PLACEHOLDER:"Engineering Team",TEAM_NAME_DESCRIPTION:"This is your team's visible name.",TEAM_NAME_INSTRUCTIONS:"Please use 64 characters at maximum.",TEAMS_DESCRIPTION:"Manage your teams within your organization.",USER_TEAMS_DESCRIPTION:"You are a member of the following teams.",DELETE_TEAM:"Delete Team",DELETE_TEAM_DESCRIPTION:"Permanently remove this team and all of its contents.",DELETE_TEAM_SUCCESS:"Team deleted successfully",DELETE_TEAM_INSTRUCTIONS:"Enter the team name to continue:",TEAM_NAME_REQUIRED:"Team name is required",TEAM_NAME_DOES_NOT_MATCH:"The team name does not match",TEAM_MEMBERS:"Team Members",TEAM_MEMBERS_DESCRIPTION:"Manage your team members and their roles.",ADD_TEAM_MEMBER:"Add Team Member",REMOVE_TEAM_MEMBER:"Remove Team Member",REMOVE_TEAM_MEMBER_CONFIRM:"Are you sure you want to remove this member from the team?",REMOVE_TEAM_MEMBER_SUCCESS:"Team member removed successfully",ADD_TEAM_MEMBER_SUCCESS:"Team member added successfully",UPDATE_TEAM_SUCCESS:"Team updated successfully",MANAGE_TEAM_MEMBERS:"Manage Team Members",MANAGE_TEAM_MEMBERS_DESCRIPTION:"Search and add organization members to this team.",NO_TEAMS_FOUND:"No teams found",MEMBER_SINGULAR:"member",MEMBER_PLURAL:"members",UNKNOWN:"Unknown",...Xce,...Zce,...Qce,...Jce,...ode,...ade,...nde,...rde,...ide,...sde,...lde,...cde,...dde,...ude,...pde,...mde},gde={CALLBACK:"callback",EMAIL_OTP:"email-otp",EMAIL_VERIFICATION:"email-verification",FORGOT_PASSWORD:"forgot-password",MAGIC_LINK:"magic-link",RECOVER_ACCOUNT:"recover-account",RESET_PASSWORD:"reset-password",SIGN_IN:"sign-in",SIGN_OUT:"sign-out",SIGN_UP:"sign-up",TWO_FACTOR:"two-factor",ACCEPT_INVITATION:"accept-invitation"},JO={SETTINGS:"settings",SECURITY:"security",TEAMS:"teams",API_KEYS:"api-keys",ORGANIZATIONS:"organizations"},XO={SETTINGS:"settings",MEMBERS:"members",TEAMS:"teams",API_KEYS:"api-keys"};const C3=A.createContext({});function E3(){return A.useContext(C3)}var j0,e2;function fde(){if(e2)return j0;e2=1;var e=function(){};return j0=e,j0}var vde=fde();const bde=Ml(vde);function yde({async:e,appendTo:t,defer:o,id:a,nonce:n,src:i}){const l=document.createElement("script");e!==void 0&&(l.async=e),o!==void 0&&(l.defer=o),a&&(l.id=a),n&&l.setAttribute("nonce",n),l.src=i,(t==="head"?document.head:document.body).appendChild(l)}var Sde=function(e,t){var o={};for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&t.indexOf(a)<0&&(o[a]=e[a]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,a=Object.getOwnPropertySymbols(e);n<a.length;n++)t.indexOf(a[n])<0&&Object.prototype.propertyIsEnumerable.call(e,a[n])&&(o[a[n]]=e[a[n]]);return o};let hp=null,Fp=!1;const rv=new Set,iv=new Set,wde=typeof window<"u",ud="___grecaptcha_cfg",P3=`onLoadCallback_${Math.random().toString(36).slice(2)}`;function Tde(){if(!wde)return;function e(o){if(Fp)o();else{window[ud]||(window[ud]={});const a=window[ud];a.fns||(a.fns=[]),a.fns.push(o)}}window.grecaptcha||(window.grecaptcha={}),window.grecaptcha.enterprise||(window.grecaptcha.enterprise={}),window.grecaptcha.ready=e,window.grecaptcha.enterprise.ready=e;function t(){Fp=!0;for(const o of iv)o();iv.clear()}window[P3]=t}function xde({language:e,onLoadCallbackName:t,render:o,useEnterprise:a=!1,useRecaptchaNet:n=!1}){const i=n?"recaptcha.net":"google.com",l=a?"enterprise.js":"api.js",c=new URLSearchParams({render:o});return t&&c.set("onload",t),e&&c.set("hl",e),`https://www.${i}/recaptcha/${l}?${c.toString()}`}function _de({language:e,render:t,scriptProps:o,useEnterprise:a,useRecaptchaNet:n}){const i={id:"google-recaptcha-v3"},l=xde({language:e,onLoadCallbackName:P3,render:t,useEnterprise:a,useRecaptchaNet:n});if(hp){if(hp!==l)throw new Error("reCAPTCHA has already been loaded with different parameters. Remove the existing script and load it again.");return}hp=l,yde(Object.assign(Object.assign(Object.assign({},i),o),{src:l}))}function kde(e){if(!window[ud])return;const t=window[ud];t.clients&&delete t.clients[e]}function Cde(e,t){var{onLoadCallback:o,onLoadCallbackName:a}=t,n=Sde(t,["onLoadCallback","onLoadCallbackName"]);if(rv.size===0&&Tde(),_de(n),rv.add(e),o&&(Fp?o():iv.add(o)),a){let i=function(){if(!a)return;const l=window[a];typeof l=="function"&&l()};Fp?i():iv.add(i)}}function Ede(e){var t,o,a;rv.delete(e),rv.size===0&&(window.grecaptcha=void 0,window[ud]=void 0,(t=document.querySelector(".grecaptcha-badge"))===null||t===void 0||t.remove(),(o=document.querySelector(`script[src="${hp}"]`))===null||o===void 0||o.remove(),(a=document.querySelector('script[src^="https://www.gstatic.com/recaptcha/releases"]'))===null||a===void 0||a.remove(),hp=null,Fp=!1)}let t2=!1;function Pde({container:e,children:t,language:o,reCaptchaKey:a,scriptProps:n,useEnterprise:i,useRecaptchaNet:l}){var c,u,p,m,h,f,v;const b=A.useId(),[S,_]=A.useState(null),[T,x]=A.useState(null),P=A.useRef(!1);A.useEffect(()=>{function D(){var O;const L=i?(O=window.grecaptcha)===null||O===void 0?void 0:O.enterprise:window.grecaptcha;if(!L)throw new Error("reCAPTCHA not found");if(!L.ready)throw new Error("reCAPTCHA ready callback not found");L.ready(()=>{_(L)})}return Cde(b,{language:o,onLoadCallback:D,onLoadCallbackName:n?.onLoadCallbackName,render:e?.element?"explicit":a,scriptProps:{appendTo:n?.appendTo,async:n?.async,defer:n?.defer,id:n?.id,nonce:n?.nonce},useEnterprise:i,useRecaptchaNet:l}),()=>{Ede(b),_(null)}},[e?.element,b,o,a,n?.appendTo,n?.async,n?.defer,n?.id,n?.nonce,n?.onLoadCallbackName,i,l]),A.useEffect(()=>{var D,O,L;if(!e?.element||!S?.render)return;const $={"error-callback":e.parameters.errorCallback,"expired-callback":e.parameters.expiredCallback,badge:((D=e.parameters)===null||D===void 0?void 0:D.badge)||"inline",callback:e.parameters.callback,sitekey:a,size:"invisible",tabindex:e.parameters.tabindex,theme:e.parameters.theme},B=typeof e?.element=="string"?document.getElementById(e.element):e?.element;if(!B)throw new Error("reCAPTCHA container element not found");const U=S.render(B,$);return!((O=e?.parameters)===null||O===void 0)&&O.hidden&&(t2||(bde(!1,"reCAPTCHA badge hidden. See https://cloud.google.com/recaptcha/docs/faq#id_like_to_hide_the_badge_what_is_allowed for more information."),t2=!0),(L=B.querySelector(".grecaptcha-badge"))===null||L===void 0||L.style.setProperty("display","none")),x(U),P.current=!0,()=>{x(null),P.current=!1,kde(U),B.innerHTML=""}},[e?.element,(c=e?.parameters)===null||c===void 0?void 0:c.badge,(u=e?.parameters)===null||u===void 0?void 0:u.hidden,(p=e?.parameters)===null||p===void 0?void 0:p.callback,(m=e?.parameters)===null||m===void 0?void 0:m.errorCallback,(h=e?.parameters)===null||h===void 0?void 0:h.expiredCallback,(f=e?.parameters)===null||f===void 0?void 0:f.tabindex,(v=e?.parameters)===null||v===void 0?void 0:v.theme,S,a]);const C=!!e?.element,E=C?T:a,R=A.useMemo(()=>E!==null&&S?.execute?D=>{if(E===null||!S?.execute)throw new Error("reCAPTCHA has not been loaded");return C&&!P.current?(console.warn("Client ID not mounted"),null):S.execute(E,{action:D})}:void 0,[E,S,C]);return w.jsx(C3.Provider,{value:{container:e?.element,executeRecaptcha:R,reCaptchaInstance:S},children:t})}var Ade=class{cache=new Map;listeners=new Map;inFlightRequests=new Map;get(e){return this.cache.get(e)}set(e,t){const o={data:t,timestamp:Date.now(),isRefetching:!1};this.cache.set(e,o),this.notify(e)}setRefetching(e,t){const o=this.cache.get(e);o&&(o.isRefetching=t,this.notify(e))}clear(e){if(e)this.cache.delete(e),this.inFlightRequests.delete(e),this.notify(e);else{this.cache.clear(),this.inFlightRequests.clear();const t=Array.from(this.listeners.keys());for(const o of t)this.notify(o)}}getInFlightRequest(e){return this.inFlightRequests.get(e)}setInFlightRequest(e,t){this.inFlightRequests.set(e,t)}removeInFlightRequest(e){this.inFlightRequests.delete(e)}subscribe(e,t){return this.listeners.has(e)||this.listeners.set(e,new Set),this.listeners.get(e).add(t),()=>{const o=this.listeners.get(e);o&&(o.delete(t),o.size===0&&this.listeners.delete(e))}}notify(e){const t=this.listeners.get(e);if(t){const o=Array.from(t);for(const a of o)a()}}},Gn=new Ade;function Rde(){return()=>{}}function Fi(){return A.useSyncExternalStore(Rde,()=>!0,()=>!1)}function A3(){const[e,t]=A.useState();return A.useEffect(()=>{const o=()=>{const n=document.documentElement.getAttribute("lang");t(n??void 0)};o();const a=new MutationObserver(n=>{for(const i of n)i.attributeName==="lang"&&o()});return a.observe(document.documentElement,{attributes:!0}),()=>{a.disconnect()}},[]),{lang:e}}function rk(){const[e,t]=A.useState("light");return A.useEffect(()=>{const o=()=>{var n;const i=document.documentElement.classList.contains("dark")||((n=document.documentElement.getAttribute("style"))==null?void 0:n.includes("color-scheme: dark"));t(i?"dark":"light")};o();const a=new MutationObserver(n=>{for(const i of n)(i.attributeName==="style"||i.attributeName==="class")&&o()});return a.observe(document.documentElement,{attributes:!0}),()=>{a.disconnect()}},[]),{theme:e}}function Dde({children:e}){const t=Fi(),{captcha:o}=A.useContext(St);return o?.provider!=="google-recaptcha-v3"?e:w.jsxs(Pde,{reCaptchaKey:o.siteKey,useEnterprise:o.enterprise,useRecaptchaNet:o.recaptchaNet,children:[t&&w.jsx("style",{children:`
169
169
  .grecaptcha-badge {
170
170
  visibility: hidden;
171
171
  border-radius: var(--radius) !important;