@lunora/studio 1.0.0-alpha.3 → 1.0.0-alpha.300

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 (353) hide show
  1. package/LICENSE.md +6 -0
  2. package/README.md +1 -1
  3. package/__assets__/package-og.svg +1 -1
  4. package/dist/index.d.mts +1581 -0
  5. package/dist/index.d.ts +982 -803
  6. package/dist/index.mjs +1 -0
  7. package/dist/mount.d.mts +22 -0
  8. package/dist/mount.d.ts +11 -10
  9. package/dist/mount.mjs +1 -0
  10. package/dist/packem_chunks/AdvisorHealthPanel.mjs +1 -0
  11. package/dist/packem_chunks/ApiTab.mjs +1 -0
  12. package/dist/packem_chunks/AuditPanel.mjs +1 -0
  13. package/dist/packem_chunks/DeploymentHealthPanel.mjs +1 -0
  14. package/dist/packem_chunks/ExportImportPanel.mjs +3 -0
  15. package/dist/packem_chunks/FileBrowser.mjs +4 -0
  16. package/dist/packem_chunks/FunctionRunner.mjs +1 -0
  17. package/dist/packem_chunks/FunctionStatsPanel.mjs +1 -0
  18. package/dist/packem_chunks/HealthPanel.mjs +1 -0
  19. package/dist/packem_chunks/InsightsPanel.mjs +1 -0
  20. package/dist/packem_chunks/LogsPanel.mjs +1 -0
  21. package/dist/packem_chunks/MailPanel.mjs +2 -0
  22. package/dist/packem_chunks/MetricsPanel.mjs +1 -0
  23. package/dist/packem_chunks/NotificationsPanel.mjs +1 -0
  24. package/dist/packem_chunks/PitrPanel.mjs +1 -0
  25. package/dist/packem_chunks/SchemaViewer.mjs +1 -0
  26. package/dist/packem_chunks/SecurityAdvisorPanel.mjs +1 -0
  27. package/dist/packem_chunks/SettingsPanel.mjs +1 -0
  28. package/dist/packem_chunks/SqlEditorPanel.mjs +10 -0
  29. package/dist/packem_chunks/TableEditor.mjs +1 -0
  30. package/dist/packem_chunks/agents-panel.mjs +1 -0
  31. package/dist/packem_chunks/ai-usage-panel.mjs +1 -0
  32. package/dist/packem_chunks/analytics-panel.mjs +1 -0
  33. package/dist/packem_chunks/architecture-panel.mjs +1 -0
  34. package/dist/packem_chunks/auth-audit-panel.mjs +1 -0
  35. package/dist/packem_chunks/auth-config-panel.mjs +1 -0
  36. package/dist/packem_chunks/auth-sessions-panel.mjs +1 -0
  37. package/dist/packem_chunks/containers-panel.mjs +1 -0
  38. package/dist/packem_chunks/dashboards-panel.mjs +1 -0
  39. package/dist/packem_chunks/evals-panel.mjs +1 -0
  40. package/dist/packem_chunks/fanout-panel.mjs +1 -0
  41. package/dist/packem_chunks/flags-panel.mjs +1 -0
  42. package/dist/packem_chunks/issues-panel.mjs +1 -0
  43. package/dist/packem_chunks/kv-browser.mjs +1 -0
  44. package/dist/packem_chunks/log-drains-panel.mjs +4 -0
  45. package/dist/packem_chunks/migrations-route.mjs +1 -0
  46. package/dist/packem_chunks/organizations-panel.mjs +1 -0
  47. package/dist/packem_chunks/payments-panel.mjs +1 -0
  48. package/dist/packem_chunks/permissions-panel.mjs +1 -0
  49. package/dist/packem_chunks/privacy-requests-panel.mjs +1 -0
  50. package/dist/packem_chunks/queues-panel.mjs +1 -0
  51. package/dist/packem_chunks/reactors-panel.mjs +1 -0
  52. package/dist/packem_chunks/rls-panel.mjs +1 -0
  53. package/dist/packem_chunks/schedule-panel.mjs +1 -0
  54. package/dist/packem_chunks/sparkline.mjs +1 -0
  55. package/dist/packem_chunks/storage-rules-panel.mjs +1 -0
  56. package/dist/packem_chunks/subscriptions-panel.mjs +1 -0
  57. package/dist/packem_chunks/sync-client-panel.mjs +1 -0
  58. package/dist/packem_chunks/traces-panel.mjs +1 -0
  59. package/dist/packem_chunks/users-panel.mjs +1 -0
  60. package/dist/packem_chunks/vector-browser.mjs +1 -0
  61. package/dist/packem_chunks/workflows-panel.mjs +1 -0
  62. package/dist/packem_shared/ADMIN_FUNCTIONS-B8yyk5BX.mjs +1 -0
  63. package/dist/packem_shared/ApiDocsPanel-fhDlZGE4.mjs +2 -0
  64. package/dist/packem_shared/ApiReferencePanel-nAf8tNRr.mjs +1 -0
  65. package/dist/packem_shared/CommandPalette-D9ZY-qQd.mjs +1 -0
  66. package/dist/packem_shared/ConfirmButton-DU4p72Er.mjs +1 -0
  67. package/dist/packem_shared/ConnectionBadge-B8Hj5DaE.mjs +1 -0
  68. package/dist/packem_shared/DEFAULT_AUTO_REFRESH_MS-DuULO4XM.mjs +1 -0
  69. package/dist/packem_shared/DEFAULT_INSIGHT_THRESHOLDS-D5YMT0gM.mjs +1 -0
  70. package/dist/packem_shared/DEFAULT_LOCALE-A1Yg5ORA.mjs +1 -0
  71. package/dist/packem_shared/DataBrowser-C14aRmmR.mjs +4 -0
  72. package/dist/packem_shared/DataFilters-CYZFt2EK.mjs +1 -0
  73. package/dist/packem_shared/ErrorBoundary-BWNF98VF.mjs +1 -0
  74. package/dist/packem_shared/GlobalDataBrowser-DhObcZDY.mjs +1 -0
  75. package/dist/packem_shared/HomePanel-CUuYsApa.mjs +1 -0
  76. package/dist/packem_shared/MigrationsPanel-CkVIwAbK.mjs +1 -0
  77. package/dist/packem_shared/OpenRpcReferencePanel-BxEr49D9.mjs +1 -0
  78. package/dist/packem_shared/STUDIO_ROOT_CLASS-C6MccdVk.mjs +1 -0
  79. package/dist/packem_shared/ScheduledJobs-BZNcYWBP.mjs +1 -0
  80. package/dist/packem_shared/ShardInput-C6mjgAh4.mjs +1 -0
  81. package/dist/packem_shared/Studio-CZjQXFHC.mjs +1 -0
  82. package/dist/packem_shared/StudioApp-C9ENwcOH.mjs +1 -0
  83. package/dist/packem_shared/StudioI18nProvider-fVsCSs5L.mjs +1 -0
  84. package/dist/packem_shared/advisor-view-DzI2RQhY.mjs +1 -0
  85. package/dist/packem_shared/aggregateMetrics-DKFJc-o5.mjs +1 -0
  86. package/dist/packem_shared/alert-PB5W11MM.mjs +1 -0
  87. package/dist/packem_shared/app.d-D7vL0y8y.d.mts +349 -0
  88. package/dist/packem_shared/app.d-D7vL0y8y.d.ts +349 -0
  89. package/dist/packem_shared/auth-pager-DiDnXsfe.mjs +1 -0
  90. package/dist/packem_shared/badge-r_5B4LHP.mjs +1 -0
  91. package/dist/packem_shared/bar-chart-BCsEIQoQ.mjs +6 -0
  92. package/dist/packem_shared/browser-storage-BH1MxLZs.mjs +1 -0
  93. package/dist/packem_shared/button-q0UYSmrn.mjs +1 -0
  94. package/dist/packem_shared/card-By2O8ULa.mjs +1 -0
  95. package/dist/packem_shared/cf-links-CBJ5SywP.mjs +1 -0
  96. package/dist/packem_shared/checkbox-CnS9cyCz.mjs +1 -0
  97. package/dist/packem_shared/control-button-BOZ5K-FC.mjs +1 -0
  98. package/dist/packem_shared/data-grid-DIiNmDR9.mjs +1 -0
  99. package/dist/packem_shared/data-view-params-DhYmAkcj.mjs +1 -0
  100. package/dist/packem_shared/diagram-export-panel-D5CVNJkp.mjs +2 -0
  101. package/dist/packem_shared/dropdown-menu-jLZenfWH.mjs +2 -0
  102. package/dist/packem_shared/empty-state-D7jEML_T.mjs +1 -0
  103. package/dist/packem_shared/error-alert-DueSEkt-.mjs +1 -0
  104. package/dist/packem_shared/grid-features-OVIMIQan.mjs +6 -0
  105. package/dist/packem_shared/grid-pagination-DgzyzfBh.mjs +1 -0
  106. package/dist/packem_shared/home-panel-BcE8S2Nn.mjs +3 -0
  107. package/dist/packem_shared/input-CXhxesPC.mjs +1 -0
  108. package/dist/packem_shared/internal-Df43vQI0.mjs +2 -0
  109. package/dist/packem_shared/label-DKFzyHq6.mjs +1 -0
  110. package/dist/packem_shared/live-status-BuJdUZFU.mjs +1 -0
  111. package/dist/packem_shared/log-fields-BolUoZ9g.mjs +1 -0
  112. package/dist/packem_shared/log-line-CICyJ_kc.mjs +1 -0
  113. package/dist/packem_shared/metrics-format-1sNGG47R.mjs +1 -0
  114. package/dist/packem_shared/modal-shell-CDztwLnv.mjs +1 -0
  115. package/dist/packem_shared/operation-console-provider-DoloEvon.mjs +1 -0
  116. package/dist/packem_shared/recording-client-CyFiAE2l.mjs +1 -0
  117. package/dist/packem_shared/reference-view-CIHyURU6.mjs +13 -0
  118. package/dist/packem_shared/schema-diagram-C5oilX7l.mjs +2 -0
  119. package/dist/packem_shared/scroll-area-CXCQH7VT.mjs +2 -0
  120. package/dist/packem_shared/select-DPyS18Vy.mjs +2 -0
  121. package/dist/packem_shared/shard-history-CaO3C4KQ.mjs +1 -0
  122. package/dist/packem_shared/shortcuts-B9gDaXmw.mjs +1 -0
  123. package/dist/packem_shared/skeleton-DX1gfixl.mjs +1 -0
  124. package/dist/packem_shared/sparkline-B_sPPO_8.mjs +1 -0
  125. package/dist/packem_shared/sql-result-table-DyK762_A.mjs +1 -0
  126. package/dist/packem_shared/stat-card-BAv73QtB.mjs +1 -0
  127. package/dist/packem_shared/storage-tier-C2mKwYRj.mjs +1 -0
  128. package/dist/packem_shared/studio-fK2DTLde.mjs +2 -0
  129. package/dist/packem_shared/table-D0SBiDu-.mjs +2 -0
  130. package/dist/packem_shared/table-list-sidebar-DkPO_Qtz.mjs +1 -0
  131. package/dist/packem_shared/textarea--40GKAyz.mjs +1 -0
  132. package/dist/packem_shared/trace-handoff-BV3EWqy_.mjs +1 -0
  133. package/dist/packem_shared/use-admin-query-tlBof8Yg.mjs +1 -0
  134. package/dist/packem_shared/use-admin-spec-Bir7V68L.mjs +1 -0
  135. package/dist/packem_shared/use-async-submit-CZqCMTJ_.mjs +1 -0
  136. package/dist/packem_shared/use-auth-config-Z_n4ABCI.mjs +1 -0
  137. package/dist/packem_shared/use-mirrored-ref-CVDf2z1M.mjs +1 -0
  138. package/dist/packem_shared/use-open-trace-DMVhpnyG.mjs +1 -0
  139. package/dist/packem_shared/use-shard-key-BsP3o5wT.mjs +1 -0
  140. package/dist/packem_shared/use-sql-assistant-CZydTzd5.mjs +1 -0
  141. package/dist/packem_shared/useDebounced-DVeQ5-oW.mjs +1 -0
  142. package/dist/packem_shared/utils-bhneXptQ.mjs +1 -0
  143. package/dist/packem_shared/virtual-rect-D_j7aLxX.mjs +1 -0
  144. package/dist/packem_shared/wire-codec-B2DgCbKt.mjs +1 -0
  145. package/dist/standalone/chunk-23DA2KK5.js +9 -0
  146. package/dist/standalone/chunk-253UHWDX.js +1 -0
  147. package/dist/standalone/chunk-2I4NHEKA.js +1 -0
  148. package/dist/standalone/chunk-2IKDEUCX.js +1 -0
  149. package/dist/standalone/chunk-2VA5S3IA.js +1 -0
  150. package/dist/standalone/chunk-2WCD2IHE.js +1 -0
  151. package/dist/standalone/chunk-2XNKJZR7.js +1 -0
  152. package/dist/standalone/chunk-37WYCOQ2.js +1 -0
  153. package/dist/standalone/chunk-3CTF6VCQ.js +1 -0
  154. package/dist/standalone/chunk-3T5F2LKG.js +1 -0
  155. package/dist/standalone/chunk-3YXASVTP.js +1 -0
  156. package/dist/standalone/chunk-47INSVZQ.js +1 -0
  157. package/dist/standalone/chunk-4FFZMCLM.js +1 -0
  158. package/dist/standalone/chunk-4QO356DN.js +1 -0
  159. package/dist/standalone/chunk-4WD4XGC3.js +1 -0
  160. package/dist/standalone/chunk-4ZEL6BYL.js +1 -0
  161. package/dist/standalone/chunk-55UGUCQ6.js +1 -0
  162. package/dist/standalone/chunk-57L3MFDQ.js +14 -0
  163. package/dist/standalone/chunk-5AORAJFI.js +1 -0
  164. package/dist/standalone/chunk-5B2RTXBS.js +1 -0
  165. package/dist/standalone/chunk-5QR2SQIS.js +1 -0
  166. package/dist/standalone/chunk-6EZBEZ7D.js +1 -0
  167. package/dist/standalone/chunk-6HLARDYO.js +1 -0
  168. package/dist/standalone/chunk-6K53DCPW.js +2 -0
  169. package/dist/standalone/chunk-6MHPVN2Q.js +15 -0
  170. package/dist/standalone/chunk-6QTAHSDD.js +1 -0
  171. package/dist/standalone/chunk-76GDLOCA.js +1 -0
  172. package/dist/standalone/chunk-7G4Z6Q7X.js +1 -0
  173. package/dist/standalone/chunk-7RKB5KS7.js +1 -0
  174. package/dist/standalone/chunk-7Y3SY37W.js +1 -0
  175. package/dist/standalone/chunk-A4GRIXDU.js +1 -0
  176. package/dist/standalone/chunk-APEMVK3W.js +1 -0
  177. package/dist/standalone/chunk-AUAECCXB.js +1 -0
  178. package/dist/standalone/chunk-AUGKHAMQ.js +1 -0
  179. package/dist/standalone/chunk-AUO3CXYH.js +1 -0
  180. package/dist/standalone/chunk-AXU6L4JV.js +1 -0
  181. package/dist/standalone/chunk-BOMPSVRC.js +1 -0
  182. package/dist/standalone/chunk-C3TKN336.js +1 -0
  183. package/dist/standalone/chunk-C5NU4UZY.js +1 -0
  184. package/dist/standalone/chunk-CCDX5RYT.js +1 -0
  185. package/dist/standalone/chunk-CGQMJYCW.js +1 -0
  186. package/dist/standalone/chunk-CKEE7CZ6.js +1 -0
  187. package/dist/standalone/chunk-CQILUV6T.js +1 -0
  188. package/dist/standalone/chunk-CVXNHIQW.js +1 -0
  189. package/dist/standalone/chunk-DG4MKUNK.js +1 -0
  190. package/dist/standalone/chunk-E4PXACVL.js +3 -0
  191. package/dist/standalone/chunk-E6E3H5HA.js +4 -0
  192. package/dist/standalone/chunk-ECY2JC5F.js +1 -0
  193. package/dist/standalone/chunk-F2HHJDID.js +1 -0
  194. package/dist/standalone/chunk-FJKOBDDS.js +1 -0
  195. package/dist/standalone/chunk-FMJPASTV.js +1 -0
  196. package/dist/standalone/chunk-FPI7AMQJ.js +1 -0
  197. package/dist/standalone/chunk-FUYEZFBP.js +1 -0
  198. package/dist/standalone/chunk-FZIZZO3M.js +5 -0
  199. package/dist/standalone/chunk-G3MCWHRS.js +1 -0
  200. package/dist/standalone/chunk-G6DD6BH4.js +3 -0
  201. package/dist/standalone/chunk-G74GIEU4.js +1 -0
  202. package/dist/standalone/chunk-G7O4XEPM.js +1 -0
  203. package/dist/standalone/chunk-GBS5ACLN.js +1 -0
  204. package/dist/standalone/chunk-GHQ2VDI2.js +1 -0
  205. package/dist/standalone/chunk-GMIJJY43.js +1 -0
  206. package/dist/standalone/chunk-GUAU5JHQ.js +1 -0
  207. package/dist/standalone/chunk-HCTJKP5J.js +1 -0
  208. package/dist/standalone/chunk-HJHSQPHW.js +19 -0
  209. package/dist/standalone/chunk-I26MS5PJ.js +1 -0
  210. package/dist/standalone/chunk-IALIMFV2.js +1 -0
  211. package/dist/standalone/chunk-IHPBU2X4.js +1 -0
  212. package/dist/standalone/chunk-IMBXNH5M.js +1 -0
  213. package/dist/standalone/chunk-IT6VW5MM.js +1 -0
  214. package/dist/standalone/chunk-IWZ7GVQO.js +1 -0
  215. package/dist/standalone/chunk-JQXA2OYK.js +1 -0
  216. package/dist/standalone/chunk-JZGTSH2C.js +4 -0
  217. package/dist/standalone/chunk-KCNSN6ZF.js +1 -0
  218. package/dist/standalone/chunk-KQSQVNVI.js +1 -0
  219. package/dist/standalone/chunk-KUFFHQPR.js +1 -0
  220. package/dist/standalone/chunk-LOKJEEUS.js +1 -0
  221. package/dist/standalone/chunk-LUNNBKUL.js +1 -0
  222. package/dist/standalone/chunk-MK7SA3YV.js +8 -0
  223. package/dist/standalone/chunk-MVWZMWPD.js +1 -0
  224. package/dist/standalone/chunk-NCPW7WHO.js +1 -0
  225. package/dist/standalone/chunk-NDTQTKDX.js +6 -0
  226. package/dist/standalone/chunk-NGVP66OH.js +1 -0
  227. package/dist/standalone/chunk-NQZALRU3.js +1 -0
  228. package/dist/standalone/chunk-NRP22GKC.js +1 -0
  229. package/dist/standalone/chunk-NXQW5E6W.js +1 -0
  230. package/dist/standalone/chunk-OPM7ESDV.js +1 -0
  231. package/dist/standalone/chunk-OQ6I6OXT.js +2 -0
  232. package/dist/standalone/chunk-OSGXNEFA.js +1 -0
  233. package/dist/standalone/chunk-OWD32MWS.js +1 -0
  234. package/dist/standalone/chunk-OYCUPD3Q.js +1 -0
  235. package/dist/standalone/chunk-P2I22USO.js +1 -0
  236. package/dist/standalone/chunk-P5OQ2T7O.js +1 -0
  237. package/dist/standalone/chunk-PIMTWCRD.js +1 -0
  238. package/dist/standalone/chunk-PPX63XHJ.js +1 -0
  239. package/dist/standalone/chunk-PTPKBYI5.js +1 -0
  240. package/dist/standalone/chunk-Q4UISMBL.js +1 -0
  241. package/dist/standalone/chunk-Q6ED4KUL.js +1 -0
  242. package/dist/standalone/chunk-Q6IT6ZD7.js +1 -0
  243. package/dist/standalone/chunk-QAQDMS6R.js +1 -0
  244. package/dist/standalone/chunk-QJLHH3ET.js +1 -0
  245. package/dist/standalone/chunk-R6U22RSY.js +1 -0
  246. package/dist/standalone/chunk-RGMVGZV4.js +1 -0
  247. package/dist/standalone/chunk-ROX6INV5.js +1 -0
  248. package/dist/standalone/chunk-RUBMOQH2.js +1 -0
  249. package/dist/standalone/chunk-RWVIV3U7.js +1 -0
  250. package/dist/standalone/chunk-RZ6QAA2I.js +1 -0
  251. package/dist/standalone/chunk-S4Z7K55A.js +1 -0
  252. package/dist/standalone/chunk-SA2OGF3F.js +1 -0
  253. package/dist/standalone/chunk-SJQERRSZ.js +1 -0
  254. package/dist/standalone/chunk-SV764LKQ.js +1 -0
  255. package/dist/standalone/chunk-UC7MNI2F.js +1 -0
  256. package/dist/standalone/chunk-UIC7EN6V.js +1 -0
  257. package/dist/standalone/chunk-UVUKVNCP.js +1 -0
  258. package/dist/standalone/chunk-UYEZR3BI.js +1 -0
  259. package/dist/standalone/chunk-VAITO6LM.js +3 -0
  260. package/dist/standalone/chunk-VAVZCMJZ.js +1 -0
  261. package/dist/standalone/chunk-VCFEO3RI.js +1 -0
  262. package/dist/standalone/chunk-VESGIGMQ.js +1 -0
  263. package/dist/standalone/chunk-VHLKUGQL.js +1 -0
  264. package/dist/standalone/chunk-VMLLR636.js +1 -0
  265. package/dist/standalone/chunk-VZWZIIP6.js +1 -0
  266. package/dist/standalone/chunk-WIASRPIC.js +59 -0
  267. package/dist/standalone/chunk-WJRYEML4.js +1 -0
  268. package/dist/standalone/chunk-XGCIDUJF.js +1 -0
  269. package/dist/standalone/chunk-XHRKNCCI.js +1 -0
  270. package/dist/standalone/chunk-XTUTKZ2F.js +1 -0
  271. package/dist/standalone/chunk-Y3AYVFTK.js +1 -0
  272. package/dist/standalone/chunk-YIDRRLUF.js +1 -0
  273. package/dist/standalone/chunk-YLPATGWK.js +15 -0
  274. package/dist/standalone/chunk-YSIOHDX6.js +1 -0
  275. package/dist/standalone/chunk-YVR4SEPU.js +1 -0
  276. package/dist/standalone/chunk-Z22BDS6N.js +1 -0
  277. package/dist/standalone/chunk-ZG4KF3SJ.js +1 -0
  278. package/dist/standalone/chunk-ZKJS6EBE.js +1 -0
  279. package/dist/standalone/studio.js +9 -356
  280. package/dist/styles.css +2 -2
  281. package/package.json +26 -21
  282. package/dist/index.js +0 -41
  283. package/dist/mount.js +0 -26
  284. package/dist/packem_shared/ADMIN_FUNCTIONS-DmBqMZ-z.js +0 -45
  285. package/dist/packem_shared/ApiDocsPanel-C5-yJ1p7.js +0 -842
  286. package/dist/packem_shared/ApiReferencePanel-1vubqG5s.js +0 -229
  287. package/dist/packem_shared/ApiTab-W3no0KOj.js +0 -251
  288. package/dist/packem_shared/AuditPanel-Bq4o_IqT.js +0 -212
  289. package/dist/packem_shared/CommandPalette-BtgkBzZI.js +0 -373
  290. package/dist/packem_shared/ConfirmButton-C2eVi2Qv.js +0 -59
  291. package/dist/packem_shared/ConnectionBadge-B2DDM2Tn.js +0 -111
  292. package/dist/packem_shared/DEFAULT_AUTO_REFRESH_MS-Vxwaxx51.js +0 -50
  293. package/dist/packem_shared/DEFAULT_INSIGHT_THRESHOLDS-DjF0h-gA.js +0 -89
  294. package/dist/packem_shared/DEFAULT_LOCALE-CiX4W7Kr.js +0 -27
  295. package/dist/packem_shared/DataBrowser-CtBe1So9.js +0 -4542
  296. package/dist/packem_shared/DataFilters-FNquMaiu.js +0 -249
  297. package/dist/packem_shared/ErrorBoundary-BzAApI7J.js +0 -66
  298. package/dist/packem_shared/ExportImportPanel-dxY56TDF.js +0 -193
  299. package/dist/packem_shared/FileBrowser-Dhy4zES8.js +0 -2932
  300. package/dist/packem_shared/FunctionRunner--fQJRPAD.js +0 -343
  301. package/dist/packem_shared/FunctionStatsPanel-BjRUA_G3.js +0 -432
  302. package/dist/packem_shared/GlobalDataBrowser-BTEmGrph.js +0 -318
  303. package/dist/packem_shared/HealthPanel-PxclMWmA.js +0 -640
  304. package/dist/packem_shared/HomePanel-Cw16stjq.js +0 -1273
  305. package/dist/packem_shared/InsightsPanel-CWS_C-xW.js +0 -423
  306. package/dist/packem_shared/LogsPanel-CTW8CFcM.js +0 -839
  307. package/dist/packem_shared/MailPanel-BwkvfIHF.js +0 -447
  308. package/dist/packem_shared/MetricsPanel-BLuOhZQ4.js +0 -1625
  309. package/dist/packem_shared/MigrationsPanel-DT3lnwHF.js +0 -246
  310. package/dist/packem_shared/OpenRpcReferencePanel-vbcYbv3V.js +0 -191
  311. package/dist/packem_shared/PitrPanel-CdErL7EJ.js +0 -252
  312. package/dist/packem_shared/STUDIO_ROOT_CLASS-D12gX2dV.js +0 -3
  313. package/dist/packem_shared/ScheduledJobs-CabfKbyM.js +0 -159
  314. package/dist/packem_shared/SchemaViewer-LJDcmNIO.js +0 -2512
  315. package/dist/packem_shared/SecurityAdvisorPanel-C_ETsPih.js +0 -79
  316. package/dist/packem_shared/SettingsPanel-C0uLRf5P.js +0 -176
  317. package/dist/packem_shared/ShardInput-gx_DZXXn.js +0 -107
  318. package/dist/packem_shared/SqlEditorPanel-CguV7otm.js +0 -13
  319. package/dist/packem_shared/Studio-DFWAlcuf.js +0 -33
  320. package/dist/packem_shared/StudioApp-CHOZA-z-.js +0 -383
  321. package/dist/packem_shared/StudioI18nProvider-B-tDCZIi.js +0 -48
  322. package/dist/packem_shared/TableEditor-ChfUOZec.js +0 -371
  323. package/dist/packem_shared/advisor-view-CGcfMiPq.js +0 -159
  324. package/dist/packem_shared/aggregateMetrics-D4nUHEKU.js +0 -108
  325. package/dist/packem_shared/app.d-CCmwDEVs.d.ts +0 -300
  326. package/dist/packem_shared/badge-B2PKA1-5.js +0 -49
  327. package/dist/packem_shared/bar-chart-CzJAgqkp.js +0 -3245
  328. package/dist/packem_shared/button-BhsN2uZH.js +0 -49
  329. package/dist/packem_shared/card-DURq3ElK.js +0 -175
  330. package/dist/packem_shared/cf-links-2cktDedA.js +0 -8
  331. package/dist/packem_shared/checkbox-UNkzAxl-.js +0 -63
  332. package/dist/packem_shared/data-grid-B5CaV3wS.js +0 -183
  333. package/dist/packem_shared/dropdown-menu-WY4B_eJO.js +0 -280
  334. package/dist/packem_shared/empty-state-DY_oe0k6.js +0 -98
  335. package/dist/packem_shared/grid-features-CzUfqgsM.js +0 -840
  336. package/dist/packem_shared/input-XH4r1Pt1.js +0 -53
  337. package/dist/packem_shared/internal-rXJEAhXS.js +0 -68
  338. package/dist/packem_shared/label-D8ykjn5J.js +0 -46
  339. package/dist/packem_shared/live-status-FZ0psC1z.js +0 -44
  340. package/dist/packem_shared/reference-view-B4E49Lip.js +0 -2180
  341. package/dist/packem_shared/shard-history-DyebH1R5.js +0 -38
  342. package/dist/packem_shared/sparkline-10dG-_f0.js +0 -93
  343. package/dist/packem_shared/sql-editor-panel-BFRpzj6r.js +0 -2562
  344. package/dist/packem_shared/storage-tier-CL98eOvn.js +0 -85
  345. package/dist/packem_shared/studio-Bj8psK1c.js +0 -10303
  346. package/dist/packem_shared/table-_RzNvy3R.js +0 -246
  347. package/dist/packem_shared/table-list-sidebar-Bg7uzbvC.js +0 -832
  348. package/dist/packem_shared/textarea-D3gaCU_-.js +0 -46
  349. package/dist/packem_shared/use-live-admin-Dq6g3daN.js +0 -73
  350. package/dist/packem_shared/use-live-shard-seed-Cuk3dnH0.js +0 -76
  351. package/dist/packem_shared/useDebounced-Dxncpg6z.js +0 -32
  352. package/dist/packem_shared/utils-B05Dmz_H.js +0 -8
  353. package/dist/packem_shared/virtual-rect-CVMUskSm.js +0 -10
@@ -0,0 +1 @@
1
+ import{a as r,d as B,e as N,g as fn}from"./chunk-I26MS5PJ.js";function Nt(t,e){t.indexOf(e)===-1&&t.push(e)}r(Nt,"addUniqueItem");function bt(t,e){let o=t.indexOf(e);o>-1&&t.splice(o,1)}r(bt,"removeItem");var W=r((t,e,o)=>o>e?e:o<t?t:o,"clamp");var xt=r(()=>{},"warning"),Z=r(()=>{},"invariant");var $={};var Gt=r(t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t),"isNumericalString");var Oe=r(t=>typeof t=="object"&&t!==null,"isObject");var Ut=r(t=>/^0[^.\s]+$/u.test(t),"isZeroValueString");function je(t){let e;return()=>(e===void 0&&(e=t()),e)}r(je,"memo");var O=r(t=>t,"noop");var st=r((...t)=>t.reduce((e,o)=>i=>o(e(i))),"pipe");var ct=r((t,e,o)=>{let i=e-t;return i?(o-t)/i:1},"progress");var ut=class{static{r(this,"SubscriptionManager")}constructor(){this.subscriptions=[]}add(e){return Nt(this.subscriptions,e),()=>this.remove(e)}remove(e){bt(this.subscriptions,e)}notify(e,o,i){let n=this.subscriptions.length;if(n)if(n===1)this.subscriptions[0](e,o,i);else for(let a=0;a<n;a++){let s=this.subscriptions[a];s&&s(e,o,i)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}};var G=r(t=>t*1e3,"secondsToMilliseconds"),K=r(t=>t/1e3,"millisecondsToSeconds");var Ne=r((t,e)=>e?t*(1e3/e):0,"velocityPerSecond");var pn=r((t,e,o)=>(((1-3*o+3*e)*t+(3*o-6*e))*t+3*e)*t,"calcBezier"),Rl=1e-7,Ll=12;function Il(t,e,o,i,n){let a,s,l=0;do s=e+(o-e)/2,a=pn(s,i,n)-t,a>0?o=s:e=s;while(Math.abs(a)>Rl&&++l<Ll);return s}r(Il,"binarySubdivide");function wt(t,e,o,i){if(t===e&&o===i)return O;let n=r(a=>Il(a,0,1,t,o),"getTForX");return a=>a===0||a===1?a:pn(n(a),e,i)}r(wt,"cubicBezier");var bo=r(t=>e=>e<=.5?t(2*e)/2:(2-t(2*(1-e)))/2,"mirrorEasing");var wo=r(t=>e=>1-t(1-e),"reverseEasing");var Ao=wt(.33,1.53,.69,.99),ue=wo(Ao),Ge=bo(ue);var Ue=r(t=>t>=1?1:(t*=2)<1?.5*ue(t):.5*(2-Math.pow(2,-10*(t-1))),"anticipate");var We=r(t=>1-Math.sin(Math.acos(t)),"circIn"),ze=wo(We),Ke=bo(We);var zr=wt(.42,0,1,1),Kr=wt(0,0,.58,1),me=wt(.42,0,.58,1);var Hr=r(t=>Array.isArray(t)&&typeof t[0]!="number","isEasingArray");var He=r(t=>Array.isArray(t)&&typeof t[0]=="number","isBezierDefinition");var hn={linear:O,easeIn:zr,easeInOut:me,easeOut:Kr,circIn:We,circInOut:Ke,circOut:ze,backIn:ue,backInOut:Ge,backOut:Ao,anticipate:Ue},Bl=r(t=>typeof t=="string","isValidEasing"),Co=r(t=>{if(He(t)){Z(t.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");let[e,o,i,n]=t;return wt(e,o,i,n)}else if(Bl(t))return Z(hn[t]!==void 0,`Invalid easing type '${t}'`,"invalid-easing-type"),hn[t];return t},"easingDefinitionToFunction");var E={delta:0,timestamp:0,isProcessing:!1};var Mo;function kl(){Mo=void 0}r(kl,"clearTime");var D={now:r(()=>(Mo===void 0&&D.set(E.isProcessing||$.useManualTiming?E.timestamp:performance.now()),Mo),"now"),set:r(t=>{Mo=t,queueMicrotask(kl)},"set")};var mt=r(t=>Math.round(t*1e5)/1e5,"sanitize");var dn=r(t=>e=>typeof e=="string"&&e.startsWith(t),"checkStringStartsWith"),Do=dn("--"),Fl=dn("var(--"),fe=r(t=>Fl(t)?Ol.test(t.split("/*")[0].trim()):!1,"isCSSVariableToken"),Ol=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function $r(t){return typeof t!="string"?!1:t.split("/*")[0].includes("var(--")}r($r,"containsCSSVariable");var ft={test:r(t=>typeof t=="number","test"),parse:parseFloat,transform:r(t=>t,"transform")},vt={...ft,transform:r(t=>W(0,1,t),"transform")},$e={...ft,default:1};var pe=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function gn(t){return t==null}r(gn,"isNullish");var yn=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu;var he=r((t,e)=>o=>!!(typeof o=="string"&&yn.test(o)&&o.startsWith(t)||e&&!gn(o)&&Object.prototype.hasOwnProperty.call(o,e)),"isColorString"),Eo=r((t,e,o)=>i=>{if(typeof i!="string")return i;let[n,a,s,l]=i.match(pe);return{[t]:parseFloat(n),[e]:parseFloat(a),[o]:parseFloat(s),alpha:l!==void 0?parseFloat(l):1}},"splitColor");var jl=r(t=>W(0,255,t),"clampRgbUnit"),_r={...ft,transform:r(t=>Math.round(jl(t)),"transform")},pt={test:he("rgb","red"),parse:Eo("red","green","blue"),transform:r(({red:t,green:e,blue:o,alpha:i=1})=>"rgba("+_r.transform(t)+", "+_r.transform(e)+", "+_r.transform(o)+", "+mt(vt.transform(i))+")","transform")};function Nl(t){let e="",o="",i="",n="";return t.length>5?(e=t.substring(1,3),o=t.substring(3,5),i=t.substring(5,7),n=t.substring(7,9)):(e=t.substring(1,2),o=t.substring(2,3),i=t.substring(3,4),n=t.substring(4,5),e+=e,o+=o,i+=i,n+=n),{red:parseInt(e,16),green:parseInt(o,16),blue:parseInt(i,16),alpha:n?parseInt(n,16)/255:1}}r(Nl,"parseHex");var _e={test:he("#"),parse:Nl,transform:pt.transform};var Ye=r(t=>({test:r(e=>typeof e=="string"&&e.endsWith(t)&&e.split(" ").length===1,"test"),parse:parseFloat,transform:r(e=>`${e}${t}`,"transform")}),"createUnitType"),ot=Ye("deg"),_=Ye("%"),v=Ye("px"),Yr=Ye("vh"),Xr=Ye("vw"),Ro={..._,parse:r(t=>_.parse(t)/100,"parse"),transform:r(t=>_.transform(t*100),"transform")};var At={test:he("hsl","hue"),parse:Eo("hue","saturation","lightness"),transform:r(({hue:t,saturation:e,lightness:o,alpha:i=1})=>"hsla("+Math.round(t)+", "+_.transform(mt(e))+", "+_.transform(mt(o))+", "+mt(vt.transform(i))+")","transform")};var k={test:r(t=>pt.test(t)||_e.test(t)||At.test(t),"test"),parse:r(t=>pt.test(t)?pt.parse(t):At.test(t)?At.parse(t):_e.parse(t),"parse"),transform:r(t=>typeof t=="string"?t:t.hasOwnProperty("red")?pt.transform(t):At.transform(t),"transform"),getAnimatableNone:r(t=>{let e=k.parse(t);return e.alpha=0,k.transform(e)},"getAnimatableNone")};var xn=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;var Tn=new RegExp(pe.source),Sn=new RegExp(xn.source,"i");function Gl(t){return isNaN(t)&&typeof t=="string"&&(Tn.test(t)||Sn.test(t))}r(Gl,"test");var Vn="number",Pn="color",Ul="var",Wl="var(",vn="${}",zl=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function bn(t){let e=t.toString();return Tn.test(e)||Sn.test(e)}r(bn,"hasComplexValues");function de(t){let e=t.toString(),o=[],i={color:[],number:[],var:[]},n=[],a=0,l=e.replace(zl,u=>(k.test(u)?(i.color.push(a),n.push(Pn),o.push(k.parse(u))):u.startsWith(Wl)?(i.var.push(a),n.push(Ul),o.push(u)):(i.number.push(a),n.push(Vn),o.push(parseFloat(u))),++a,vn)).split(vn);return{values:o,split:l,indexes:i,types:n}}r(de,"analyseComplexValue");function Kl(t){return de(t).values}r(Kl,"parseComplexValue");function wn({split:t,types:e}){let o=t.length;return i=>{let n="";for(let a=0;a<o;a++)if(n+=t[a],i[a]!==void 0){let s=e[a];s===Vn?n+=mt(i[a]):s===Pn?n+=k.transform(i[a]):n+=i[a]}return n}}r(wn,"buildTransformer");function Hl(t){return wn(de(t))}r(Hl,"createTransformer");var $l=r(t=>typeof t=="number"?0:k.test(t)?k.getAnimatableNone(t):t,"convertNumbersToZero"),_l=r((t,e)=>typeof t=="number"?e?.trim().endsWith("/")?t:0:$l(t),"convertToZero");function Yl(t){let e=de(t);return wn(e)(e.values.map((i,n)=>_l(i,e.split[n])))}r(Yl,"getAnimatableNone");var j={test:Gl,parse:Kl,createTransformer:Hl,getAnimatableNone:Yl};function qr(t,e,o){return o<0&&(o+=1),o>1&&(o-=1),o<1/6?t+(e-t)*6*o:o<1/2?e:o<2/3?t+(e-t)*(2/3-o)*6:t}r(qr,"hueToRgb");function An({hue:t,saturation:e,lightness:o,alpha:i}){t/=360,e/=100,o/=100;let n=0,a=0,s=0;if(!e)n=a=s=o;else{let l=o<.5?o*(1+e):o+e-o*e,u=2*o-l;n=qr(u,l,t+1/3),a=qr(u,l,t),s=qr(u,l,t-1/3)}return{red:Math.round(n*255),green:Math.round(a*255),blue:Math.round(s*255),alpha:i}}r(An,"hslaToRgba");function ge(t,e){return o=>o>0?e:t}r(ge,"mixImmediate");var A=r((t,e,o)=>t+(e-t)*o,"mixNumber");var Zr=r((t,e,o)=>{let i=t*t,n=o*(e*e-i)+i;return n<0?0:Math.sqrt(n)},"mixLinearColor"),Xl=[_e,pt,At],ql=r(t=>Xl.find(e=>e.test(t)),"getColorType");function Cn(t){let e=ql(t);if(!e)return xt(!1,`'${t}' is not an animatable color. Use the equivalent color code instead.`,"color-not-animatable"),!1;let o=e.parse(t);return e===At&&(o=An(o)),o}r(Cn,"asRGBA");var Jr=r((t,e)=>{let o=Cn(t),i=Cn(e);if(!o||!i)return ge(t,e);let n={...o};return a=>(n.red=Zr(o.red,i.red,a),n.green=Zr(o.green,i.green,a),n.blue=Zr(o.blue,i.blue,a),n.alpha=A(o.alpha,i.alpha,a),pt.transform(n))},"mixColor");var Lo=new Set(["none","hidden"]);function Mn(t,e){return Lo.has(t)?o=>o<=0?t:e:o=>o>=1?e:t}r(Mn,"mixVisibility");function Zl(t,e){return o=>A(t,e,o)}r(Zl,"mixNumber");function Io(t){return typeof t=="number"?Zl:typeof t=="string"?fe(t)?ge:k.test(t)?Jr:tc:Array.isArray(t)?Dn:typeof t=="object"?k.test(t)?Jr:Jl:ge}r(Io,"getMixer");function Dn(t,e){let o=[...t],i=o.length,n=t.map((a,s)=>Io(a)(a,e[s]));return a=>{for(let s=0;s<i;s++)o[s]=n[s](a);return o}}r(Dn,"mixArray");function Jl(t,e){let o={...t,...e},i={};for(let n in o)t[n]!==void 0&&e[n]!==void 0&&(i[n]=Io(t[n])(t[n],e[n]));return n=>{for(let a in i)o[a]=i[a](n);return o}}r(Jl,"mixObject");function Ql(t,e){let o=[],i={color:0,var:0,number:0};for(let n=0;n<e.values.length;n++){let a=e.types[n],s=t.indexes[a][i[a]],l=t.values[s]??0;o[n]=l,i[a]++}return o}r(Ql,"matchOrder");var tc=r((t,e)=>{let o=j.createTransformer(e),i=de(t),n=de(e);return i.indexes.var.length===n.indexes.var.length&&i.indexes.color.length===n.indexes.color.length&&i.indexes.number.length>=n.indexes.number.length?Lo.has(t)&&!n.values.length||Lo.has(e)&&!i.values.length?Mn(t,e):st(Dn(Ql(i,n),n.values),o):(xt(!0,`Complex values '${t}' and '${e}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,"complex-values-different"),ge(t,e))},"mixComplex");var En=/^(-?(?:\d+(?:\.\d*)?|\.\d+))([a-z%]*)$/iu;function ec(t,e){let o=En.exec(t);if(!o)return;let i=En.exec(e);if(!i||o[2]!==i[2])return;let n=o[2],a=parseFloat(o[1]),s=parseFloat(i[1]);return l=>mt(A(a,s,l))+n}r(ec,"mixUnit");function ye(t,e,o){if(typeof t=="number"&&typeof e=="number"&&typeof o=="number")return A(t,e,o);if(typeof t=="string"&&typeof e=="string"){let n=ec(t,e);if(n)return n}return Io(t)(t,e)}r(ye,"mix");var Xe=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function Rn(t){let e=new Set,o=new Set,i=!1,n=!1,a=new Set,s={delta:0,timestamp:0,isProcessing:!1};function l(c){a.has(c)&&(o.add(c),t()),c(s)}r(l,"triggerCallback");let u={schedule:r((c,m=!1,f=!1)=>{let d=f&&i?e:o;return m&&a.add(c),d.add(c),c},"schedule"),cancel:r(c=>{o.delete(c),a.delete(c)},"cancel"),process:r(c=>{if(s=c,i){n=!0;return}i=!0;let m=e;e=o,o=m,e.forEach(l),e.clear(),i=!1,n&&(n=!1,u.process(c))},"process")};return u}r(Rn,"createRenderStep");var oc=40;function Bo(t,e,o={delta:0,timestamp:0,isProcessing:!1}){let i=!1,n=!0,a=r(()=>i=!0,"flagRunNextFrame"),s=Xe.reduce((P,T)=>(P[T]=Rn(a),P),{}),{setup:l,read:u,resolveKeyframes:c,preUpdate:m,update:f,preRender:p,render:d,postRender:h}=s,x=r(()=>{let P=$.useManualTiming,T=P?o.timestamp:performance.now();i=!1,P||(o.delta=n?1e3/60:Math.max(Math.min(T-o.timestamp,oc),1)),o.timestamp=T,o.isProcessing=!0,l.process(o),u.process(o),c.process(o),m.process(o),f.process(o),p.process(o),d.process(o),h.process(o),o.isProcessing=!1,i&&e&&(n=!1,t(x))},"processBatch"),g=r(()=>{i=!0,n=!0,o.isProcessing||t(x)},"wake");return{schedule:Xe.reduce((P,T)=>{let C=s[T];return P[T]=(R,y=!1,S=!1)=>(i||g(),C.schedule(R,y,S)),P},{}),cancel:r(P=>{for(let T=0;T<Xe.length;T++)s[Xe[T]].cancel(P)},"cancel"),state:o,steps:s}}r(Bo,"createRenderBatcher");var{schedule:w,cancel:J,steps:qe}=Bo(typeof requestAnimationFrame<"u"?requestAnimationFrame:O,!0,E);var Ln=r(t=>{let e=r(({timestamp:o})=>t(o),"passTimestamp");return{start:r((o=!0)=>w.update(e,o),"start"),stop:r(()=>J(e),"stop"),now:r(()=>E.isProcessing?E.timestamp:D.now(),"now")}},"frameloopDriver");var ko=r((t,e,o=10)=>{let i="",n=Math.max(Math.round(e/o),2);for(let a=0;a<n;a++)i+=Math.round(t(a/(n-1))*1e4)/1e4+", ";return`linear(${i.substring(0,i.length-2)})`},"generateLinearEasing");function xe(t,e=50,o=2e4,i){let n=0,a=t.next(n);for(i?.push(a.value);!a.done&&n<o;)n+=e,a=t.next(n),i?.push(a.value);return n>=o?1/0:n}r(xe,"calcGeneratorDuration");function In(t,e=100,o){let i=o({...t,keyframes:[0,e]}),n=Math.min(xe(i),2e4);return{type:"keyframes",ease:r(a=>i.next(n*a).value/e,"ease"),duration:K(n)}}r(In,"createGeneratorEasing");var H={stiffness:100,damping:10,mass:1,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05},Bn=r(t=>t<0?1/Math.max(1+t,H.minDamping):Math.max(1-t,H.minDamping),"bounceToDampingRatio");function kn(t,e){if(!(t>1))return 1;let o=Math.sqrt(t*t-1),i=t-o,n=t+o,a=2*o*Math.exp(-e)*(1+e);return Fn(s=>n*Math.exp(-i*s)-i*Math.exp(-n*s)-a,s=>Math.exp(-n*s)-Math.exp(-i*s),e)/e}r(kn,"overdampedFreqScale");function oi(t,e){return t*Math.sqrt(1-e*e)}r(oi,"calcAngularFreq");var rc=12;function Fn(t,e,o){let i=o;for(let n=1;n<rc;n++)i=i-t(i)/e(i);return i}r(Fn,"approximateRoot");var ti=.001;function ic({duration:t=H.duration,bounce:e=H.bounce}){let o,i;xt(t<=G(H.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let n=Bn(e);t=W(H.minDuration,H.maxDuration,K(t)),n<1?(o=r(c=>{let m=c*n,f=m*t,p=oi(c,n),d=Math.exp(-f);return ti-m/p*d},"envelope"),i=r(c=>{let f=c*n*t,p=n*n*c*c*t,d=Math.exp(-f),h=oi(c*c,n);return(-o(c)+ti>0?-1:1)*-p*d/h},"derivative")):(o=r(c=>{let m=Math.exp(-c*t),f=c*t+1;return-ti+m*f},"envelope"),i=r(c=>{let m=Math.exp(-c*t),f=-c*(t*t);return m*f},"derivative"));let a=5/t,s=Fn(o,i,a),l=s*kn(n,s*t),u=l*l;return{stiffness:u,damping:n*2*Math.sqrt(u),duration:G(t)}}r(ic,"findSpring");var ri=r((t,e)=>(e?t>=0:t>0)&&t<1/0,"isValidPhysics");function ei(t,e){if(ri(t,e))return t}r(ei,"resolvePhysics");function nc(t){let e=ei(t.stiffness),o=ei(t.damping,!0),i=ei(t.mass),n={...t,stiffness:e??H.stiffness,damping:o??H.damping,mass:i??H.mass,isResolvedFromDuration:!1,isTimeDefined:(e??o??i)===void 0&&(t.duration!==void 0||t.bounce!==void 0)};if(n.isTimeDefined){if(t.visualDuration){let a=Bn(t.bounce||0),s=2*Math.PI/(t.visualDuration*1.2)*kn(a,2*Math.PI/1.2);n.stiffness=s*s,n.damping=2*a*Math.sqrt(n.stiffness)}else Object.assign(n,ic(n)),n.isResolvedFromDuration=!0;(!ri(n.stiffness)||!ri(n.damping,!0))&&(n.stiffness=H.stiffness,n.damping=H.damping)}return n}r(nc,"getSpringOptions");function ve(t=H.visualDuration,e=H.bounce){let o=typeof t!="object"?{visualDuration:t,keyframes:[0,1],bounce:e}:t,i=o.keyframes[0],n=o.keyframes[o.keyframes.length-1],a={done:!1,value:i},{stiffness:s,damping:l,mass:u,duration:c,isResolvedFromDuration:m,isTimeDefined:f}=nc({...o}),p=r(y=>f?0:-K(y),"inheritVelocity"),d=l/(2*Math.sqrt(s*u)),h=K(Math.sqrt(s/u)),x=d*h,g={target:n,delta:n-i,velocity:p(o.velocity||0)||0,restSpeed:0,restDelta:0},b=r(()=>{let y=Math.abs(g.delta)<5;g.restSpeed=o.restSpeed||(y?H.restSpeed.granular:H.restSpeed.default),g.restDelta=o.restDelta||(y?H.restDelta.granular:H.restDelta.default)},"setRestThresholds");b();let V,P,T;if(d<1){let y=oi(h,d),S={A:0,sinC:0,cosC:0,t:-1,env:0,sin:0,cos:0};T=r(()=>{S.A=(g.velocity+x*g.delta)/y,S.sinC=x*S.A+g.delta*y,S.cosC=x*g.delta-S.A*y},"update");let F=r(L=>{L!==S.t&&(S.t=L,S.env=Math.exp(-x*L),S.sin=Math.sin(y*L),S.cos=Math.cos(y*L))},"sample");V=r(L=>(F(L),g.target-S.env*(S.A*S.sin+g.delta*S.cos)),"resolveSpring"),P=r(L=>(F(L),S.env*(S.sinC*S.sin+S.cosC*S.cos)),"resolveVelocity")}else if(d===1){V=r(S=>g.target-Math.exp(-h*S)*(g.delta+(g.velocity+h*g.delta)*S),"resolveSpring");let y={C:0};T=r(()=>{y.C=g.velocity+h*g.delta},"update"),P=r(S=>Math.exp(-h*S)*(h*y.C*S-g.velocity),"resolveVelocity")}else{let y=h*Math.sqrt(d*d-1),S=x-y,F=x+y,L=f?1/0:300/y,gt=r((q,le)=>Math.exp(le>L?-q*L-x*(le-L):-q*le),"decayAt"),yt={S:0,F:0};T=r(()=>{let q=(g.velocity+x*g.delta)/y;yt.S=(g.delta+q)/2,yt.F=(g.delta-q)/2},"update"),V=r(q=>g.target-yt.S*gt(S,q)-yt.F*gt(F,q),"resolveSpring"),P=r(q=>S*yt.S*gt(S,q)+F*yt.F*gt(F,q),"resolveVelocity")}T();let C=m&&c||null,R={calculatedDuration:C,retarget:r((y,S)=>{g.target=y[y.length-1],g.delta=g.target-y[0],g.velocity=p(S),o.restSpeed&&o.restDelta||b(),R.calculatedDuration=C,a.done=!1,T()},"retarget"),velocity:r(y=>G(P(y)),"velocity"),next:r(y=>{let S=V(y);if(m)a.done=y>=c;else{let F=G(P(y));a.done=Math.abs(F)<=g.restSpeed&&Math.abs(g.target-S)<=g.restDelta}return a.value=a.done?g.target:S,a},"next"),toString:r(()=>{let y=Math.min(xe(R),2e4),S=ko(F=>R.next(y*F).value,y,30);return y+"ms "+S},"toString"),toTransition:r(()=>{},"toTransition")};return R}r(ve,"spring");ve.applyToOptions=t=>{let e=In(t,100,ve);return t.ease=e.ease,t.duration=G(e.duration),t.type="keyframes",t};function Ze({keyframes:t,velocity:e=0,power:o=.8,timeConstant:i=325,bounceDamping:n=10,bounceStiffness:a=500,modifyTarget:s,min:l,max:u,restDelta:c=.5,restSpeed:m}){let f=t[0],p={done:!1,value:f},d=r(y=>y<l||y>u,"isOutOfBounds"),h=r(y=>l===void 0?u:u===void 0||Math.abs(l-y)<Math.abs(u-y)?l:u,"nearestBoundary"),x=o*e,g=f+x,b=s===void 0?g:s(g);b!==g&&(x=b-f);let V=r(y=>-x*Math.exp(-y/i),"calcDelta"),P=r(y=>{let S=V(y);p.done=Math.abs(S)<=c,p.value=p.done?b:b+S},"applyFriction"),T,C,R=r(y=>{d(p.value)&&(T=y,C=ve({keyframes:[p.value,h(p.value)],velocity:-V(y)/i*1e3,damping:n,stiffness:a,restDelta:c,restSpeed:m}))},"checkCatchBoundary");return R(0),{calculatedDuration:null,next:r(y=>{let S=!1;return!C&&T===void 0&&(S=!0,P(y),R(y)),T!==void 0&&y>=T?C.next(y-T):(!S&&P(y),p)},"next")}}r(Ze,"inertia");function sc(t,e,o){let i=[],n=o||$.mix||ye,a=t.length-1;for(let s=0;s<a;s++){let l=n(t[s],t[s+1]);if(e){let u=Array.isArray(e)?e[s]||O:e;l=st(u,l)}i.push(l)}return i}r(sc,"createMixers");function On(t,e,{clamp:o=!0,ease:i,mixer:n}={}){let a=t.length;if(Z(a===e.length,"Both input and output ranges must be the same length","range-length"),a===1)return()=>e[0];if(a===2&&e[0]===e[1])return()=>e[1];let s=t[0]===t[1];t[0]>t[a-1]&&(t=[...t].reverse(),e=[...e].reverse());let l=sc(e,i,n),u=l.length,c=r(m=>{if(s&&m<t[0])return e[0];let f=0;if(u>1)for(;f<t.length-2&&!(m<t[f+1]);f++);let p=ct(t[f],t[f+1],m);return l[f](p)},"interpolator");return o?m=>c(W(t[0],t[a-1],m)):c}r(On,"interpolate");function jn(t,e){let o=t[t.length-1];for(let i=1;i<=e;i++){let n=ct(0,e,i);t.push(A(o,1,n))}}r(jn,"fillOffset");function Nn(t){let e=[0];return jn(e,t.length-1),e}r(Nn,"defaultOffset");function Gn(t,e){return t.map(o=>o*e)}r(Gn,"convertOffsetToTimes");function ac(t,e){return t.map(()=>e||me).splice(0,t.length-1)}r(ac,"defaultEasing");function Wt({duration:t=300,keyframes:e,times:o,ease:i="easeInOut"}){let n=Hr(i)?i.map(Co):Co(i)||me,a={done:!1,value:e[0]};if(e.length===2&&!Array.isArray(n)&&(!o||o.length!==2||o[0]===0&&o[1]===1)){let[u,c]=e,m=u===c?void 0:($.mix||ye)(u,c);return{calculatedDuration:t,next:r(f=>(a.value=m?m(n(t>0?W(0,1,f/t):1)):c,a.done=f>=t,a),"next")}}let s=Gn(o&&o.length===e.length?o:Nn(e),t),l=On(s,e,{ease:Array.isArray(n)?n:ac(e,n)});return{calculatedDuration:t,next:r(u=>(a.value=l(u),a.done=u>=t,a),"next")}}r(Wt,"keyframes");var lc=5;function cc(t,e,o){let i=Math.max(e-lc,0);return Ne(o-t(i),e-i)}r(cc,"getGeneratorVelocity");function Un(t,e,o=0){return e<=0?o:t.velocity?t.velocity(e):cc(i=>t.next(i).value,e,t.next(e).value)}r(Un,"calcGeneratorVelocity");var uc=r(t=>t!==null,"isNotNull");function Ct(t,{repeat:e,repeatType:o="loop"},i,n=1){let a=t.filter(uc),l=n<0||e&&o!=="loop"&&e%2===1?0:a.length-1;return!l||i===void 0?a[l]:i}r(Ct,"getFinalKeyframe");var mc={decay:Ze,inertia:Ze,tween:Wt,keyframes:Wt,spring:ve};function Fo(t){typeof t.type=="string"&&(t.type=mc[t.type])}r(Fo,"replaceTransitionType");function Wn(t,e){return{kind:t,animation:e,timestamp:D.now(),frameTimestamp:E.timestamp,frameIsProcessing:E.isProcessing}}r(Wn,"baseRecord");function Oo(t,e,o){let i=globalThis.__MOTION_INSPECT__;if(i)try{i({...Wn("animation-start",t),options:o?{...e,...o}:e})}catch{}}r(Oo,"notifyAnimationStart");function zn(t,e){let o=globalThis.__MOTION_INSPECT__;if(o)try{o({...Wn("layout-animation-start",t),node:e})}catch{}}r(zn,"notifyLayoutAnimationStart");var Mt=class{static{r(this,"WithPromise")}constructor(){this.isResolved=!1}get finished(){return this._finished||(this._finished=this.isResolved?Promise.resolve():new Promise(e=>{this._resolve=e})),this._finished}updateFinished(){this._finished=this._resolve=void 0,this.isResolved=!1}notifyFinished(){this.isResolved=!0,this._resolve?.()}then(e,o){return this.finished.then(e,o)}};var fc=r(t=>t/100,"percentToProgress"),Tt=class extends Mt{static{r(this,"JSAnimation")}constructor(e){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{let{motionValue:o}=this.options;o&&o.updatedAt!==D.now()&&this.tick(D.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),this.options.onStop?.())},this.options=e,this.initAnimation(),this.play(),e.autoplay===!1&&this.pause(),Oo(this,this.options)}initAnimation(){let{options:e}=this;Fo(e);let{type:o=Wt,repeat:i=0,repeatDelay:n=0,repeatType:a,velocity:s=0}=e,{keyframes:l}=e,u=o||Wt;u!==Wt&&typeof l[0]!="number"&&(this.mixKeyframes=st(fc,ye(l[0],l[1])),l=[0,100]);let c=u(l===e.keyframes?e:{...e,keyframes:l});a==="mirror"&&(this.mirroredGenerator=u({...e,keyframes:[...l].reverse(),velocity:-s})),c.calculatedDuration===null&&(c.calculatedDuration=xe(c));let{calculatedDuration:m}=c;this.calculatedDuration=m,this.resolvedDuration=m+n,this.totalDuration=this.resolvedDuration*(i+1)-n,this.generator=c}updateTime(e){let o=Math.round(e-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=o}tick(e,o=!1){let{generator:i,totalDuration:n,mixKeyframes:a,mirroredGenerator:s,resolvedDuration:l,calculatedDuration:u}=this;if(this.startTime===null)return i.next(0);let{delay:c=0,keyframes:m,repeat:f,repeatType:p,repeatDelay:d,type:h,onUpdate:x,finalKeyframe:g}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-n/this.speed,this.startTime)),o?this.currentTime=e:this.updateTime(e);let b=this.currentTime-c*(this.playbackSpeed>=0?1:-1),V=this.playbackSpeed>=0?b<0:b>n;this.currentTime=Math.max(b,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=n);let P=this.currentTime,T=i;if(f){let S=Math.min(this.currentTime,n)/l,F=Math.floor(S),L=S%1;!L&&S>=1&&(L=1),L===1&&F--,F=Math.min(F,f+1),F%2&&(p==="reverse"?(L=1-L,d&&(L-=d/l)):p==="mirror"&&(T=s)),P=W(0,1,L)*l}let C;V?(this.delayState.value=m[0],C=this.delayState):C=T.next(P),a&&!V&&(C.value=a(C.value));let{done:R}=C;!V&&u!==null&&(R=this.playbackSpeed>=0?this.currentTime>=n:this.currentTime<=0);let y=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&R);return y&&h!==Ze&&(C.value=Ct(m,this.options,g,this.speed)),x&&x(C.value),y&&this.finish(),C}then(e,o){return this.finished.then(e,o)}get duration(){return K(this.calculatedDuration)}get iterationDuration(){let{delay:e=0}=this.options||{};return this.duration+K(e)}get time(){return K(this.currentTime)}set time(e){e=G(e),this.currentTime=e,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.playbackSpeed),this.driver?this.driver.start(!1):(this.startTime=0,this.state="paused",this.holdTime=e,this.tick(e))}getGeneratorVelocity(){return Un(this.generator,this.currentTime,this.options.velocity)}get speed(){return this.playbackSpeed}set speed(e){let o=this.playbackSpeed!==e;o&&this.driver&&this.updateTime(D.now()),this.playbackSpeed=e,o&&this.driver&&(this.time=K(this.currentTime))}play(){if(this.isStopped)return;let{driver:e=Ln,startTime:o}=this.options;this.driver||(this.driver=e(n=>this.tick(n))),this.options.onPlay?.();let i=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=i):this.holdTime!==null?this.startTime=i-this.holdTime:this.startTime||(this.startTime=o??i),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(D.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}attachTimeline(e){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),e.observe(this)}};var pc=new Set(["brightness","contrast","saturate","opacity"]);function hc(t){let[e,o]=t.slice(0,-1).split("(");if(e==="drop-shadow")return t;let[i]=o.match(pe)||[];if(!i)return t;let n=o.replace(i,""),a=pc.has(e)?1:0;return i!==o&&(a*=100),e+"("+a+n+")"}r(hc,"applyDefaultFilter");var dc=/\b([a-z-]*)\(.*?\)/gu,Je={...j,getAnimatableNone:r(t=>{let e=t.match(dc);return e?e.map(hc).join(" "):t},"getAnimatableNone")};var Qe={...j,getAnimatableNone:r(t=>{let e=j.parse(t);return j.createTransformer(t)(e.map(i=>typeof i=="number"?0:typeof i=="object"?{...i,alpha:1}:i))},"getAnimatableNone")};var ii={...ft,transform:Math.round};var Kn={rotate:ot,pathRotation:ot,rotateX:ot,rotateY:ot,rotateZ:ot,scale:$e,scaleX:$e,scaleY:$e,scaleZ:$e,skew:ot,skewX:ot,skewY:ot,distance:v,translateX:v,translateY:v,translateZ:v,x:v,y:v,z:v,perspective:v,transformPerspective:v,opacity:vt,originX:Ro,originY:Ro,originZ:v};var zt={borderWidth:v,borderTopWidth:v,borderRightWidth:v,borderBottomWidth:v,borderLeftWidth:v,borderRadius:v,borderTopLeftRadius:v,borderTopRightRadius:v,borderBottomRightRadius:v,borderBottomLeftRadius:v,width:v,maxWidth:v,height:v,maxHeight:v,top:v,right:v,bottom:v,left:v,inset:v,insetBlock:v,insetBlockStart:v,insetBlockEnd:v,insetInline:v,insetInlineStart:v,insetInlineEnd:v,padding:v,paddingTop:v,paddingRight:v,paddingBottom:v,paddingLeft:v,paddingBlock:v,paddingBlockStart:v,paddingBlockEnd:v,paddingInline:v,paddingInlineStart:v,paddingInlineEnd:v,margin:v,marginTop:v,marginRight:v,marginBottom:v,marginLeft:v,marginBlock:v,marginBlockStart:v,marginBlockEnd:v,marginInline:v,marginInlineStart:v,marginInlineEnd:v,fontSize:v,backgroundPositionX:v,backgroundPositionY:v,...Kn,zIndex:ii,fillOpacity:vt,strokeOpacity:vt,numOctaves:ii};var gc={...zt,color:k,backgroundColor:k,outlineColor:k,fill:k,stroke:k,borderColor:k,borderTopColor:k,borderRightColor:k,borderBottomColor:k,borderLeftColor:k,filter:Je,WebkitFilter:Je,mask:Qe,WebkitMask:Qe},jo=r(t=>gc[t],"getDefaultValueType");var yc=new Set([Je,Qe]);function Te(t,e){let o=jo(t);return yc.has(o)||(o=j),o.getAnimatableNone?o.getAnimatableNone(e):void 0}r(Te,"getAnimatableNone");function Hn(t){for(let e=1;e<t.length;e++)t[e]??(t[e]=t[e-1])}r(Hn,"fillWildcards");var Kt=r(t=>t*180/Math.PI,"radToDeg"),ni=r(t=>{let e=Kt(Math.atan2(t[1],t[0]));return si(e)},"rotate"),xc={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:r(t=>(Math.abs(t[0])+Math.abs(t[3]))/2,"scale"),rotate:ni,rotateZ:ni,skewX:r(t=>Kt(Math.atan(t[1])),"skewX"),skewY:r(t=>Kt(Math.atan(t[2])),"skewY"),skew:r(t=>(Math.abs(t[1])+Math.abs(t[2]))/2,"skew")},si=r(t=>(t=t%360,t<0&&(t+=360),t),"rebaseAngle"),$n=ni,_n=r(t=>Math.sqrt(t[0]*t[0]+t[1]*t[1]),"scaleX"),Yn=r(t=>Math.sqrt(t[4]*t[4]+t[5]*t[5]),"scaleY"),vc={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:_n,scaleY:Yn,scale:r(t=>(_n(t)+Yn(t))/2,"scale"),rotateX:r(t=>si(Kt(Math.atan2(t[6],t[5]))),"rotateX"),rotateY:r(t=>si(Kt(Math.atan2(-t[2],t[0]))),"rotateY"),rotateZ:$n,rotate:$n,skewX:r(t=>Kt(Math.atan(t[4])),"skewX"),skewY:r(t=>Kt(Math.atan(t[1])),"skewY"),skew:r(t=>(Math.abs(t[1])+Math.abs(t[4]))/2,"skew")};function Ht(t){return t.includes("scale")?1:0}r(Ht,"defaultTransformValue");function No(t,e){if(!t||t==="none")return Ht(e);let o=t.match(/^matrix3d\(([-\d.e\s,]+)\)$/u),i,n;if(o)i=vc,n=o;else{let l=t.match(/^matrix\(([-\d.e\s,]+)\)$/u);i=xc,n=l}if(!n)return Ht(e);let a=i[e],s=n[1].split(",").map(Tc);return typeof a=="function"?a(s):s[a]}r(No,"parseValueFromTransform");var Xn=r((t,e)=>{let{transform:o="none"}=getComputedStyle(t);return No(o,e)},"readTransformValue");function Tc(t){return parseFloat(t.trim())}r(Tc,"convertTransformToNumber");var ht=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Q=new Set([...ht,"pathRotation"]);var ai=r(t=>t===ft||t===v,"isNumOrPxType"),Sc=new Set(["x","y","z"]),Vc=ht.filter(t=>!Sc.has(t));function Zn(t){let e=[];return Vc.forEach(o=>{let i=t.getValue(o);if(i!==void 0){let n=i.get(),a=o.startsWith("scale")?1:0;if(n===a)return;e.push([o,n]),i.set(a)}}),e}r(Zn,"removeNonTranslationalTransform");var Jn=new Set(["bottom","right"]);function qn(t,e,o,i,n,a){let s=parseFloat(t);if(!isNaN(s))return s;let{min:l,max:u}=e()[o],c=u-l;return a==="border-box"?c:c-parseFloat(i)-parseFloat(n)}r(qn,"measureDimension");var Dt={width:r(({width:t,paddingLeft:e="0",paddingRight:o="0",boxSizing:i},n)=>qn(t,n,"x",e,o,i),"width"),height:r(({height:t,paddingTop:e="0",paddingBottom:o="0",boxSizing:i},n)=>qn(t,n,"y",e,o,i),"height"),top:r(({top:t})=>parseFloat(t),"top"),left:r(({left:t})=>parseFloat(t),"left"),bottom:r(({top:t},e)=>{let{y:o}=e();return parseFloat(t)+(o.max-o.min)},"bottom"),right:r(({left:t},e)=>{let{x:o}=e();return parseFloat(t)+(o.max-o.min)},"right"),x:r(({transform:t})=>No(t,"x"),"x"),y:r(({transform:t})=>No(t,"y"),"y")};Dt.translateX=Dt.x;Dt.translateY=Dt.y;var $t=new Set,li=!1,ci=!1,ui=!1;function Qn(){if(ci){let t=[],e=new Set,o=new Set;$t.forEach(n=>{n.needsMeasurement&&(t.push(n),e.add(n.element),Jn.has(n.name)&&o.add(n.element))});let i=new Map;o.forEach(n=>{let a=Zn(n);a.length&&(i.set(n,a),n.render())}),t.forEach(n=>n.measureInitialState()),e.forEach(n=>{n.render();let a=i.get(n);a&&a.forEach(([s,l])=>{n.getValue(s)?.set(l)})}),t.forEach(n=>n.measureEndState()),t.forEach(n=>{n.suspendedScrollY!==void 0&&window.scrollTo(0,n.suspendedScrollY)})}ci=!1,li=!1,$t.forEach(t=>t.complete(ui)),$t.clear()}r(Qn,"measureAllKeyframes");function ts(){$t.forEach(t=>{t.readKeyframes(),t.needsMeasurement&&(ci=!0)})}r(ts,"readAllKeyframes");function es(){ui=!0,ts(),Qn(),ui=!1}r(es,"flushKeyframeResolvers");function Pc(t,e,o){if(typeof t=="string"){if(Gt(t)||Ut(t))return parseFloat(t);if(!j.test(t)&&j.test(o))return Te(e,o)}return t??void 0}r(Pc,"readOrigin");var Et=class{static{r(this,"KeyframeResolver")}constructor(e,o,i,n,a,s=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...e],this.onComplete=o,this.name=i,this.motionValue=n,this.element=a,this.isAsync=s}scheduleResolve(){this.state="scheduled",this.isAsync?($t.add(this),li||(li=!0,w.read(ts),w.resolveKeyframes(Qn))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:e,name:o,element:i,motionValue:n}=this;if(e[0]===null){let a=n?.get(),s=e[e.length-1];if(a!==void 0)e[0]=a;else if(i&&o){let l=Pc(i.readValue(o,s),o,s);l!==void 0&&(e[0]=l)}e[0]===void 0&&(e[0]=s),n&&a===void 0&&n.set(e[0])}Hn(e)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(e=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,e),$t.delete(this)}cancel(){this.state==="scheduled"&&($t.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}};var os=r(t=>t.startsWith("--"),"isCSSVar");function Go(t,e,o){os(e)?t.style.setProperty(e,o):t.style[e]=o}r(Go,"setStyle");var rs={};function Uo(t,e){let o=je(t);return()=>rs[e]??o()}r(Uo,"memoSupports");var is=Uo(()=>window.ScrollTimeline!==void 0,"scrollTimeline");var Wo=Uo(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing");var _t=r(([t,e,o,i])=>`cubic-bezier(${t}, ${e}, ${o}, ${i})`,"cubicBezierAsString");var mi={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:_t([0,.65,.55,1]),circOut:_t([.55,0,1,.45]),backIn:_t([.31,.01,.66,-.59]),backOut:_t([.33,1.53,.69,.99])};function fi(t,e){if(t)return typeof t=="function"?Wo()?ko(t,e):"ease-out":He(t)?_t(t):Array.isArray(t)?t.map(o=>fi(o,e)||mi.easeOut):mi[t]}r(fi,"mapEasingToNativeEasing");function ns(t,e,o,{delay:i=0,duration:n=300,repeat:a=0,repeatType:s="loop",ease:l="easeOut",times:u}={},c=void 0){let m={[e]:o};u&&(m.offset=u);let f=fi(l,n);Array.isArray(f)&&(m.easing=f);let p={delay:i,duration:n,easing:Array.isArray(f)?"linear":f,fill:"both",iterations:a+1,direction:s==="reverse"?"alternate":"normal"};return c&&(p.pseudoElement=c),t.animate(m,p)}r(ns,"startWaapiAnimation");function zo(t){return typeof t=="function"&&"applyToOptions"in t}r(zo,"isGenerator");function ss({type:t,...e}){return zo(t)&&Wo()?t.applyToOptions(e):(e.duration??(e.duration=300),e.ease??(e.ease="easeOut"),e)}r(ss,"applyGeneratorOptions");var Se=class extends Mt{static{r(this,"NativeAnimation")}constructor(e){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!e)return;let{element:o,name:i,keyframes:n,pseudoElement:a,allowFlatten:s=!1,finalKeyframe:l,onComplete:u}=e;this.isPseudoElement=!!a,this.allowFlatten=s,this.options=e,Z(typeof e.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");let c=ss(e);this.animation=ns(o,i,n,c,a),c.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!a){let m=Ct(n,this.options,l,this.speed);this.updateMotionValue&&this.updateMotionValue(m),Go(o,i,m),this.animation.cancel()}u?.(),this.notifyFinished()},Oo(this,e,c)}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;let{state:e}=this;e==="idle"||e==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){let e=this.options?.element;!this.isPseudoElement&&e?.isConnected&&this.animation.commitStyles?.()}get duration(){let e=this.animation.effect?.getComputedTiming?.().duration||0;return K(Number(e))}get iterationDuration(){let{delay:e=0}=this.options||{};return this.duration+K(e)}get time(){return K(Number(this.animation.currentTime)||0)}set time(e){let o=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=G(e),o&&this.animation.pause()}get speed(){return this.animation.playbackRate}set speed(e){e<0&&(this.finishedTime=null),this.animation.playbackRate=e}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(e){this.manualStartTime=this.animation.startTime=e}attachTimeline({timeline:e,onAttach:o,observe:i}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,e&&is()?(this.animation.timeline=e,o?.(this.animation),O):i(this)}};var as={anticipate:Ue,backInOut:Ge,circInOut:Ke};function bc(t){return t in as}r(bc,"isUnsupportedEase");function ls(t){typeof t.ease=="string"&&bc(t.ease)&&(t.ease=as[t.ease])}r(ls,"replaceStringEasing");var pi=10,Ko=class extends Se{static{r(this,"NativeAnimationExtended")}constructor(e){ls(e),Fo(e),super(e),e.startTime!==void 0&&e.autoplay!==!1&&(this.startTime=e.startTime),this.options=e}updateMotionValue(e){let{motionValue:o,onUpdate:i,onComplete:n,element:a,...s}=this.options;if(!o)return;if(e!==void 0){o.set(e);return}let l=new Tt({...s,autoplay:!1}),u=Math.max(pi,D.now()-this.startTime),c=W(0,pi,u-pi),m=l.sample(u).value,{name:f}=this.options;a&&f&&Go(a,f,m),o.setWithVelocity(l.sample(Math.max(0,u-c)).value,m,c),l.stop()}};var hi=r((t,e)=>e==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(j.test(t)||t==="0")&&!t.startsWith("url(")),"isAnimatable");function wc(t){let e=t[0];if(t.length===1)return!0;for(let o=0;o<t.length;o++)if(t[o]!==e)return!0}r(wc,"hasKeyframesChanged");function cs(t,e,o,i){let n=t[0];if(n===null)return!1;if(e==="display"||e==="visibility")return!0;let a=t[t.length-1],s=hi(n,e),l=hi(a,e);return!s||!l?(s!==l&&xt(!1,`You are trying to animate ${e} from "${n}" to "${a}". "${s?a:n}" is not an animatable value.`,"value-not-animatable"),!1):wc(t)||(o==="spring"||zo(o))&&i}r(cs,"canAnimate");function to(t){t.duration=0,t.type="keyframes"}r(to,"makeAnimationInstant");var eo=new Set(["opacity","clipPath","filter","transform","backgroundColor"]);var Ac=/^(?:oklch|oklab|lab|lch|color|color-mix|light-dark)\(/;function us(t){for(let e=0;e<t.length;e++)if(typeof t[e]=="string"&&Ac.test(t[e]))return!0;return!1}r(us,"hasBrowserOnlyColors");var ms=new Set(["color","backgroundColor","outlineColor","fill","stroke","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"]),Cc=je(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function fs(t){let{motionValue:e,name:o,repeatDelay:i,repeatType:n,damping:a,type:s,keyframes:l}=t;if(!o||!(eo.has(o)||ms.has(o)))return!1;let u=e?.owner?.current;if(!(u instanceof HTMLElement)&&!(u instanceof SVGElement))return!1;let{onUpdate:c,transformTemplate:m}=e.owner.getProps();return Cc()&&(eo.has(o)||ms.has(o)&&us(l))&&(o!=="transform"||!m)&&!c&&!i&&n!=="mirror"&&a!==0&&s!=="inertia"}r(fs,"supportsBrowserAnimation");var Mc=40,Ho=class extends Mt{static{r(this,"AsyncMotionValueAnimation")}constructor(e){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=D.now();let{keyframes:o,name:i,motionValue:n,element:a}=e,s=e;s.autoplay??(s.autoplay=!0),s.delay??(s.delay=0),s.type??(s.type="keyframes"),s.repeat??(s.repeat=0),s.repeatDelay??(s.repeatDelay=0),s.repeatType??(s.repeatType="loop");let l=a?.KeyframeResolver||Et;this.keyframeResolver=new l(o,(u,c,m)=>this.onKeyframesResolved(u,c,s,!m),i,n,a),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(e,o,i,n){this.keyframeResolver=void 0;let{name:a,type:s,velocity:l,delay:u,isHandoff:c,onUpdate:m}=i;this.resolvedAt=D.now();let f=!0;cs(e,a,s,l)||(f=!1,($.instantAnimations||!u)&&m?.(Ct(e,i,o)),e[0]=e[e.length-1],to(i),i.repeat=0);let p=n?this.resolvedAt?this.resolvedAt-this.createdAt>Mc?this.resolvedAt:this.createdAt:this.createdAt:void 0,{onComplete:d}=i;i.startTime??(i.startTime=p),i.finalKeyframe=o,i.keyframes=e,i.onComplete=()=>{d?.(),this.notifyFinished()};let h=f&&!c&&fs(i),x;if(h){i.element=i.motionValue?.owner?.current;try{x=new Ko(i)}catch{x=new Tt(i)}}else x=new Tt(i);this.pendingTimeline&&(this.stopTimeline=x.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=x}get finished(){return this._animation?this._animation.finished:super.finished}then(e,o){return this.finished.finally(e).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),es()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(e){this.animation.time=e}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(e){this.animation.speed=e}get startTime(){return this.animation.startTime}attachTimeline(e){return this._animation?this.stopTimeline=this.animation.attachTimeline(e):this.pendingTimeline=e,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}};function $o(t,e,o,i=0,n=1){let a=Array.from(t).sort((c,m)=>c.sortNodePosition(m)).indexOf(e),s=t.size,l=(s-1)*i;return typeof o=="function"?o(a,s):n===1?a*i:l-a*i}r($o,"calcChildStagger");var ps=30,Dc=r(t=>!isNaN(parseFloat(t)),"isFloat"),hs={current:void 0},di=class{static{r(this,"MotionValue")}constructor(e,o={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=i=>{let n=D.now();if(this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(i),this.current!==this.prev&&(this.notifyChange(),this.dependents))for(let a of this.dependents)a.dirty()},this.hasAnimated=!1,this.setCurrent(e),this.owner=o.owner}setCurrent(e){this.current=e,this.updatedAt=D.now(),this.canTrackVelocity===null&&e!==void 0&&(this.canTrackVelocity=Dc(this.current))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return this.on("change",e)}on(e,o){var i;return e==="change"?this.onChangeSubscribe(o):((i=this.events)[e]||(i[e]=new ut)).add(o)}onChangeSubscribe(e){let{events:o}=this;return!o.change&&!this.changeSubscriber?this.changeSubscriber=e:(o.change||(o.change=new ut,o.change.add(this.changeSubscriber),this.changeSubscriber=void 0),o.change.add(e)),()=>{this.changeSubscriber===e?this.changeSubscriber=void 0:o.change?.remove(e),this.stopIfUnobserved()}}stopIfUnobserved(){w.read(()=>{!this.changeSubscriber&&!this.events.change?.getSize()&&this.stop()})}clearListeners(){this.changeSubscriber=void 0;for(let e in this.events)this.events[e].clear()}attach(e,o){this.passiveEffect=e,this.stopPassiveEffect=o}set(e){this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e)}setWithVelocity(e,o,i){this.set(o),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-i}jump(e,o=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,o&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.notifyChange()}notifyChange(){let{current:e,changeSubscriber:o}=this;o?o(e):this.events.change?.notify(e)}addDependent(e){this.dependents||(this.dependents=new Set),this.dependents.add(e)}removeDependent(e){this.dependents&&this.dependents.delete(e)}get(){return hs.current&&hs.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){let e=D.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||e-this.updatedAt>ps)return 0;let o=Math.min(this.updatedAt-this.prevUpdatedAt,ps);return Ne(parseFloat(this.current)-parseFloat(this.prevFrameValue),o)}start(e){return this.stop(),new Promise(o=>{this.hasAnimated=!0;let i=!1,n;n=e(()=>{i=!0,this.events.animationComplete?.notify(),this.animation===n&&this.clearAnimation(),o()}),i||(this.animation=n),this.events.animationStart?.notify()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){this.animation=void 0}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}};function at(t,e){return new di(t,e)}r(at,"motionValue");function _o(t,e){if(t?.inherit&&e){let{inherit:o,...i}=t;return{...e,...i}}return t}r(_o,"resolveTransition");function Ve(t,e){let o=t?.[e]??t?.default??t;return o!==t?_o(o,t):o}r(Ve,"getValueTransition");var Ec={type:"spring",stiffness:500,damping:25,restSpeed:10},Rc=r(t=>({type:"spring",stiffness:550,damping:t===0?2*Math.sqrt(550):30,restSpeed:10}),"criticallyDampedSpring"),Lc={type:"keyframes",duration:.8},Ic={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},ds=r((t,{keyframes:e})=>e.length>2?Lc:Q.has(t)?t.startsWith("scale")?Rc(e[1]):Ec:Ic,"getDefaultTransition");var Bc=new Set(["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);function gs(t){for(let e in t)if(!Bc.has(e))return!0;return!1}r(gs,"isTransitionDefined");var Yt=r((t,e,o,i={},n,a)=>s=>{let l=Ve(i,t)||{},u=l.delay||i.delay||0,{elapsed:c=0}=i;c=c-G(u);let m={keyframes:Array.isArray(o)?o:[null,o],ease:"easeOut",velocity:e.getVelocity(),...l,delay:-c,onUpdate:r(p=>{e.set(p),l.onUpdate&&l.onUpdate(p)},"onUpdate"),onComplete:r(()=>{s(),l.onComplete&&l.onComplete()},"onComplete"),name:t,motionValue:e,element:a?void 0:n};gs(l)||Object.assign(m,ds(t,m)),m.duration&&(m.duration=G(m.duration)),m.repeatDelay&&(m.repeatDelay=G(m.repeatDelay)),m.from!==void 0&&(m.keyframes[0]=m.from);let f=!1;if((m.type===!1||m.duration===0&&!m.repeatDelay)&&(to(m),m.delay===0&&(f=!0)),($.instantAnimations||$.skipAnimations||n?.shouldSkipAnimations||l.skipAnimations)&&(f=!0,to(m),m.delay=0),m.allowFlatten=!l.type&&!l.ease,f&&!a&&e.get()!==void 0){let p=Ct(m.keyframes,l);if(p!==void 0){w.update(()=>{m.onUpdate(p),m.onComplete()});return}}return l.isSync?new Tt(m):new Ho(m)},"animateMotionValue");var kc=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Fc(t){let e=kc.exec(t);if(!e)return[,];let[,o,i,n]=e;return[`--${o??i}`,n]}r(Fc,"parseCSSVariable");var Oc=4;function gi(t,e,o=1){Z(o<=Oc,`Max CSS variable fallback depth detected in property "${t}". This may indicate a circular fallback dependency.`,"max-css-var-depth");let[i,n]=Fc(t);if(!i)return;let a=window.getComputedStyle(e).getPropertyValue(i);if(a){let s=a.trim();return Gt(s)?parseFloat(s):s}return fe(n)?gi(n,e,o+1):n}r(gi,"getVariableValue");function jc(t){let e=[{},{}];return t?.values.forEach((o,i)=>{e[0][i]=o.get(),e[1][i]=o.getVelocity()}),e}r(jc,"getValueState");function oo(t,e,o,i){let n=r(a=>typeof a=="function"?a(o!==void 0?o:t.custom,...jc(i)):a,"resolveFunction");return e=n(e),typeof e=="string"&&(e=t.variants&&t.variants[e]),n(e)}r(oo,"resolveVariantFromProps");function tt(t,e,o){return oo(t.getProps(),e,o,t)}r(tt,"resolveVariant");var Yo=r((t,e)=>e==="exit"?t.presenceContext?.custom:void 0,"getTypeCustom");var Xo=new Set(["width","height","top","left","right","bottom",...ht]);var ys=r(t=>Array.isArray(t),"isKeyframesTarget");function Nc(t,e,o){t.hasValue(e)?t.getValue(e).set(o):t.addValue(e,at(o))}r(Nc,"setMotionValue");function Gc(t){return ys(t)?t[t.length-1]||0:t}r(Gc,"resolveFinalValueInKeyframes");function xs(t,e){let o=tt(t,e),{transitionEnd:i={},transition:n={},...a}=o||{};a={...a,...i};for(let s in a){let l=Gc(a[s]);Nc(t,s,l)}}r(xs,"setTarget");var M=r(t=>!!(t&&t.getVelocity),"isMotionValue");function vs(t){return!!(M(t)&&t.add)}r(vs,"isWillChangeMotionValue");function Pe(t,e){let o=t.getValue("willChange");if(vs(o))return o.add(e);if(!o&&$.WillChange){let i=new $.WillChange("auto");t.addValue("willChange",i),i.add(e)}}r(Pe,"addValueToWillChange");function be(t){return t.replace(/([A-Z])/g,e=>`-${e.toLowerCase()}`)}r(be,"camelToDash");var Ts="framerAppearId",ro="data-"+be(Ts);function qo(t){return t.props[ro]}r(qo,"getOptimisedAppearId");var Uc=typeof window<"u";function Wc({protectedKeys:t,needsAnimating:e},o){let i=o in t&&!e[o];return e[o]=!1,i}r(Wc,"shouldBlockAnimation");function Zo(t,e,{delay:o=0,transitionOverride:i,type:n}={}){let{transition:a,transitionEnd:s,...l}=e,u=t.getDefaultTransition();a=a?_o(a,u):u;let c=a?.reduceMotion,m=a?.skipAnimations;i&&(a=i);let f=[],p=n&&t.animationState?.getState()[n],d=a?.path;d&&d.animateVisualElement(t,l,a,o,f);for(let h in l){let x=t.getValue(h,t.latestValues[h]??null),g=l[h];if(g===void 0||p&&Wc(p,h))continue;let b={delay:o,...Ve(a||{},h)};m&&(b.skipAnimations=!0);let V=x.get();if(V!==void 0&&!x.isAnimating()&&!Array.isArray(g)&&g===V&&!b.velocity){w.update(()=>x.set(g));continue}let P=!1;if(Uc&&window.MotionHandoffAnimation){let R=qo(t);if(R){let y=window.MotionHandoffAnimation(R,h,w);y!==null&&(b.startTime=y,P=!0)}}Pe(t,h);let T=c??t.shouldReduceMotion;x.start(Yt(h,x,g,T&&Xo.has(h)?{type:!1}:b,t,P));let C=x.animation;C&&f.push(C)}if(s){let h=r(()=>w.update(()=>{s&&xs(t,s)}),"applyTransitionEnd");f.length?Promise.all(f).then(h):h()}return f}r(Zo,"animateTarget");function Jo(t,e,o={}){let i=tt(t,e,Yo(t,o.type)),n=o.transitionOverride||(i?.transition??(t.getDefaultTransition()||{})),a=r(()=>Promise.all(i?Zo(t,i,o):[]),"getAnimation"),s=r((u=0)=>{let{variantChildren:c}=t,{delayChildren:m=0,staggerChildren:f,staggerDirection:p}=n,d=[];return c?.forEach(h=>{h.notify("AnimationStart",e),d.push(Jo(h,e,{...o,delay:u+(typeof m=="function"?0:m)+$o(c,h,m,f,p)}).then(()=>h.notify("AnimationComplete",e)))}),Promise.all(d)},"getChildAnimations"),{when:l}=n;return l?l==="beforeChildren"?a().then(()=>s()):s().then(a):Promise.all([a(),s(o.delay)])}r(Jo,"animateVariant");function Ss(t,e,o={}){return t.notify("AnimationStart",e),(Array.isArray(e)?Promise.all(e.map(n=>Jo(t,n,o))):typeof e=="string"?Jo(t,e,o):Promise.all(Zo(t,tt(t,e,o.custom),o))).then(()=>{t.notify("AnimationComplete",e)})}r(Ss,"animateVisualElement");var Vs={test:r(t=>t==="auto","test"),parse:r(t=>t,"parse")};var Ps=r(t=>e=>e.test(t),"testValueType");var zc=[ft,v,_,ot,Xr,Yr,Vs],yi=r(t=>zc.find(Ps(t)),"findDimensionValueType");function bs(t){return typeof t=="number"?t===0:t!==null?t==="none"||t==="0"||Ut(t):!0}r(bs,"isNone");var Kc=new Set(["auto","none","0"]);function ws(t,e,o){let i=0,n;for(;i<t.length&&!n;){let a=t[i];typeof a=="string"&&!Kc.has(a)&&bn(a)&&(n=t[i]),i++}if(n&&o)for(let a of e)t[a]!==n&&(t[a]=Te(o,n))}r(ws,"makeNoneKeyframesAnimatable");var Qo=class extends Et{static{r(this,"DOMKeyframesResolver")}constructor(e,o,i,n,a){super(e,o,i,n,a,!0)}readKeyframes(){let{unresolvedKeyframes:e,element:o,name:i}=this;if(!o||!o.current)return;super.readKeyframes();for(let m=0;m<e.length;m++){let f=e[m];if(typeof f=="string"&&(f=f.trim(),fe(f))){let p=gi(f,o.current);p!==void 0&&(e[m]=p),m===e.length-1&&(this.finalKeyframe=f)}}if(this.resolveNoneKeyframes(),!Xo.has(i)||e.length!==2)return;let[n,a]=e;if(typeof n=="number"&&typeof a=="number")return;let s=yi(n),l=yi(a),u=$r(n),c=$r(a);if(u!==c&&Dt[i]){this.needsMeasurement=!0;return}if(s!==l)if(ai(s)&&ai(l))for(let m=0;m<e.length;m++){let f=e[m];typeof f=="string"&&(e[m]=parseFloat(f))}else Dt[i]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){let{unresolvedKeyframes:e,name:o}=this,i=[];for(let n=0;n<e.length;n++)(e[n]===null||bs(e[n]))&&i.push(n);i.length&&ws(e,i,o)}measure(){let{element:e,name:o}=this;return Dt[o](window.getComputedStyle(e.current),()=>e.measureViewportBox())}measureInitialState(){let{element:e,unresolvedKeyframes:o,name:i}=this;if(!e||!e.current)return;i==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=this.measure(),o[0]=this.measuredOrigin;let n=o[o.length-1];n!==void 0&&this.motionValue?.jump(n,!1)}measureEndState(){let{element:e,unresolvedKeyframes:o}=this;if(!e||!e.current)return;this.motionValue?.jump(this.measuredOrigin,!1);let i=o.length-1,n=o[i];o[i]=this.measure(),n!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=n),this.removedTransforms?.length&&this.removedTransforms.forEach(([a,s])=>{e.getValue(a).set(s)}),this.resolveNoneKeyframes()}};var io=["borderTopLeftRadius","borderTopRightRadius","borderBottomRightRadius","borderBottomLeftRadius"];function As(t){return Oe(t)&&"offsetHeight"in t&&!("ownerSVGElement"in t)}r(As,"isHTMLElement");function we(t){return Oe(t)&&"ownerSVGElement"in t}r(we,"isSVGElement");var no=r((t,e)=>e&&typeof t=="number"?e.transform(t):t,"getValueAsType");function tr(t,e,o){if(t==null)return[];if(t instanceof EventTarget)return[t];if(typeof t=="string"){let i=document;e&&(i=e.current);let n=o?.[t]??i.querySelectorAll(t);return n?Array.from(n):[]}return Array.from(t).filter(i=>i!=null)}r(tr,"resolveElements");var Hc={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},$c=ht.length;function Cs(t,e,o){let i="",n=!0;for(let s=0;s<$c;s++){let l=ht[s],u=t[l];if(u===void 0)continue;let c=!0;if(typeof u=="number")c=u===(l.startsWith("scale")?1:0);else{let m=parseFloat(u);c=l.startsWith("scale")?m===1:m===0}if(!c||o){let m=no(u,zt[l]);if(!c){n=!1;let f=Hc[l]||l;i+=`${f}(${m}) `}o&&(e[l]=m)}}let a=t.pathRotation;return a&&(n=!1,i+=`rotate(${no(a,zt.pathRotation)}) `),i=i.trim(),o?i=o(e,n?"":i):n&&(i="none"),i}r(Cs,"buildTransform");function Xt(t,e,o){let{style:i,vars:n,transformOrigin:a}=t,s=!1,l=!1;for(let u in e){let c=e[u];if(Q.has(u)){s=!0;continue}else if(Do(u)){n[u]=c;continue}else{let m=no(c,zt[u]);u.startsWith("origin")?(l=!0,a[u]=m):i[u]=m}}if(e.transform||(s||o?i.transform=Cs(e,t.transform,o):i.transform&&(i.transform="none")),l){let{originX:u="50%",originY:c="50%",originZ:m=0}=a;i.transformOrigin=`${u} ${c} ${m}`}}r(Xt,"buildHTMLStyles");var _c={offset:"stroke-dashoffset",array:"stroke-dasharray"},Yc={offset:"strokeDashoffset",array:"strokeDasharray"};function Ms(t,e,o=1,i=0,n=!0){t.pathLength=1;let a=n?_c:Yc;t[a.offset]=`${-i}`,t[a.array]=`${e} ${o}`}r(Ms,"buildSVGPath");var xi=["transform","opacity","offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function so(t,{attrX:e,attrY:o,attrScale:i,pathLength:n,pathSpacing:a=1,pathOffset:s=0,...l},u,c,m){if(Xt(t,l,c),u){t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox);return}t.attrs=t.style,t.style={};let{attrs:f,style:p}=t;for(let d of xi)f[d]!==void 0&&(p[d]=f[d],delete f[d]);(p.transform||f.transformOrigin)&&(p.transformOrigin=f.transformOrigin??"50% 50%",delete f.transformOrigin),p.transform&&(p.transformBox=m?.transformBox??"fill-box",delete f.transformBox),e!==void 0&&(f.x=e),o!==void 0&&(f.y=o),i!==void 0&&(f.scale=i),n!==void 0&&Ms(f,n,a,s,!1)}r(so,"buildSVGAttrs");function ao({top:t,left:e,right:o,bottom:i}){return{x:{min:e,max:o},y:{min:t,max:i}}}r(ao,"convertBoundingBoxToBox");function vi({x:t,y:e}){return{top:e.min,right:t.max,bottom:e.max,left:t.min}}r(vi,"convertBoxToBoundingBox");function Ti(t,e){if(!e)return t;let o=e({x:t.left,y:t.top}),i=e({x:t.right,y:t.bottom});return{top:o.y,left:o.x,bottom:i.y,right:i.x}}r(Ti,"transformBoxPoints");function Si(t){return t===void 0||t===1}r(Si,"isIdentityScale");function er({scale:t,scaleX:e,scaleY:o}){return!Si(t)||!Si(e)||!Si(o)}r(er,"hasScale");function St(t){return er(t)||Vi(t)||t.z||t.rotate||t.rotateX||t.rotateY||t.skewX||t.skewY}r(St,"hasTransform");function Vi(t){return Ds(t.x)||Ds(t.y)}r(Vi,"has2DTranslate");function Ds(t){return t&&t!=="0%"}r(Ds,"is2DTranslate");function lo(t,e,o){let i=t-o,n=e*i;return o+n}r(lo,"scalePoint");function Es(t,e,o,i,n){return n!==void 0&&(t=lo(t,n,i)),lo(t,o,i)+e}r(Es,"applyPointDelta");function Pi(t,e=0,o=1,i,n){t.min=Es(t.min,e,o,i,n),t.max=Es(t.max,e,o,i,n)}r(Pi,"applyAxisDelta");function bi(t,{x:e,y:o}){Pi(t.x,e.translate,e.scale,e.originPoint),Pi(t.y,o.translate,o.scale,o.originPoint)}r(bi,"applyBoxDelta");var Rs=.999999999999,Ls=1.0000000000001;function ks(t,e,o,i=!1){let n=o.length;if(!n)return;e.x=e.y=1;let a,s;for(let l=0;l<n;l++){a=o[l],s=a.projectionDelta;let{visualElement:u}=a.options;u&&u.props.style&&u.props.style.display==="contents"||(i&&a.options.layoutScroll&&a.scroll&&a!==a.root&&(rt(t.x,-a.scroll.offset.x),rt(t.y,-a.scroll.offset.y)),s&&(e.x*=s.x.scale,e.y*=s.y.scale,bi(t,s)),i&&St(a.latestValues)&&co(t,a.latestValues,a.layout?.layoutBox))}e.x<Ls&&e.x>Rs&&(e.x=1),e.y<Ls&&e.y>Rs&&(e.y=1)}r(ks,"applyTreeDeltas");function rt(t,e){t.min+=e,t.max+=e}r(rt,"translateAxis");function Is(t,e,o,i,n=.5){let a=A(t.min,t.max,n);Pi(t,e,o,a,i)}r(Is,"transformAxis");function Bs(t,e){return typeof t=="string"?parseFloat(t)/100*(e.max-e.min):t}r(Bs,"resolveAxisTranslate");function co(t,e,o){let i=o??t;Is(t.x,Bs(e.x,i.x),e.scaleX,e.scale,e.originX),Is(t.y,Bs(e.y,i.y),e.scaleY,e.scale,e.originY)}r(co,"transformBox");function or(t,e){return ao(Ti(t.getBoundingClientRect(),e))}r(or,"measureViewportBox");function wi(t,e,o){let i=or(t,o),{scroll:n}=e;return n&&(rt(i.x,n.offset.x),rt(i.y,n.offset.y)),i}r(wi,"measurePageBox");var{schedule:qt,cancel:Xc}=Bo(queueMicrotask,!1);var it={x:!1,y:!1};function rr(){return it.x||it.y}r(rr,"isDragActive");function Ai(t){return t==="x"||t==="y"?it[t]?null:(it[t]=!0,()=>{it[t]=!1}):it.x||it.y?null:(it.x=it.y=!0,()=>{it.x=it.y=!1})}r(Ai,"setDragLock");function ir(t,e){let o=tr(t),i=new AbortController,n={passive:!0,...e,signal:i.signal};return[o,n,r(()=>i.abort(),"cancel")]}r(ir,"setupGesture");function qc(t){return!(t.pointerType==="touch"||rr())}r(qc,"isValidHover");function Ci(t,e,o={}){let[i,n,a]=ir(t,o);return i.forEach(s=>{let l=!1,u=!1,c,m=r(()=>{s.removeEventListener("pointerleave",h)},"removePointerLeave"),f=r(g=>{c&&(c(g),c=void 0),m()},"endHover"),p=r(g=>{l=!1,window.removeEventListener("pointerup",p),window.removeEventListener("pointercancel",p),u&&(u=!1,f(g))},"onPointerUp"),d=r(()=>{l=!0,window.addEventListener("pointerup",p,n),window.addEventListener("pointercancel",p,n)},"onPointerDown"),h=r(g=>{if(g.pointerType!=="touch"){if(l){u=!0;return}f(g)}},"onPointerLeave"),x=r(g=>{if(!qc(g))return;u=!1;let b=e(s,g);typeof b=="function"&&(c=b,s.addEventListener("pointerleave",h,n))},"onPointerEnter");s.addEventListener("pointerenter",x,n),s.addEventListener("pointerdown",d,n)}),a}r(Ci,"hover");var Mi=r((t,e)=>e?t===e?!0:Mi(t,e.parentElement):!1,"isNodeOrChild");var Zt=r(t=>t.pointerType==="mouse"?typeof t.button!="number"||t.button<=0:t.isPrimary!==!1,"isPrimaryPointer");var Zc=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function Di(t){return Zc.has(t.tagName)||t.isContentEditable===!0}r(Di,"isElementKeyboardAccessible");var Jc=new Set(["INPUT","SELECT","TEXTAREA"]);function Ei(t){return Jc.has(t.tagName)||t.isContentEditable===!0}r(Ei,"isElementTextInput");var Ae=new WeakSet;function Fs(t){return e=>{e.key==="Enter"&&t(e)}}r(Fs,"filterEvents");function Ri(t,e){t.dispatchEvent(new PointerEvent("pointer"+e,{isPrimary:!0,bubbles:!0}))}r(Ri,"firePointerEvent");var Os=r((t,e)=>{let o=t.currentTarget;if(!o)return;let i=Fs(()=>{if(Ae.has(o))return;Ri(o,"down");let n=Fs(()=>{Ri(o,"up")}),a=r(()=>Ri(o,"cancel"),"handleBlur");o.addEventListener("keyup",n,e),o.addEventListener("blur",a,e)});o.addEventListener("keydown",i,e),o.addEventListener("blur",()=>o.removeEventListener("keydown",i),e)},"enableKeyboardPress");function js(t){return Zt(t)&&!rr()}r(js,"isValidPressEvent");var Ns=new WeakSet;function Li(t,e,o={}){let[i,n,a]=ir(t,o),s=r(l=>{let u=l.currentTarget;if(!js(l)||Ns.has(l))return;Ae.add(u),o.stopPropagation&&Ns.add(l);let c=e(u,l),m={...n,capture:!0},f=r((h,x)=>{window.removeEventListener("pointerup",p,m),window.removeEventListener("pointercancel",d,m),Ae.has(u)&&Ae.delete(u),js(h)&&typeof c=="function"&&c(h,{success:x})},"onPointerEnd"),p=r(h=>{f(h,u===window||u===document||o.useGlobalTarget||Mi(u,h.target))},"onPointerUp"),d=r(h=>{f(h,!1)},"onPointerCancel");window.addEventListener("pointerup",p,m),window.addEventListener("pointercancel",d,m)},"startPress");return i.forEach(l=>{(o.useGlobalTarget?window:l).addEventListener("pointerdown",s,n),As(l)&&(l.addEventListener("focus",c=>Os(c,n)),!Di(l)&&!l.hasAttribute("tabindex")&&(l.tabIndex=0))}),a}r(Li,"press");var nr=new WeakMap,sr,Gs=r((t,e,o)=>(i,n)=>n&&n[0]?n[0][t+"Size"]:we(i)&&"getBBox"in i?i.getBBox()[e]:i[o],"getSize"),Qc=Gs("inline","width","offsetWidth"),tu=Gs("block","height","offsetHeight");function eu({target:t,borderBoxSize:e}){nr.get(t)?.forEach(o=>{o(t,{get width(){return Qc(t,e)},get height(){return tu(t,e)}})})}r(eu,"notifyTarget");function ou(t){t.forEach(eu)}r(ou,"notifyAll");function ru(){typeof ResizeObserver>"u"||(sr=new ResizeObserver(ou))}r(ru,"createResizeObserver");function Us(t,e){sr||ru();let o=tr(t);return o.forEach(i=>{let n=nr.get(i);n||(n=new Set,nr.set(i,n)),n.add(e),sr?.observe(i)}),()=>{o.forEach(i=>{let n=nr.get(i);n?.delete(e),n?.size||sr?.unobserve(i)})}}r(Us,"resizeElement");var ar=new Set,Ce;function iu(){Ce=r(()=>{let t={get width(){return window.innerWidth},get height(){return window.innerHeight}};ar.forEach(e=>e(t))},"windowResizeHandler"),window.addEventListener("resize",Ce)}r(iu,"createWindowResizeHandler");function Ws(t){return ar.add(t),Ce||iu(),()=>{ar.delete(t),!ar.size&&typeof Ce=="function"&&(window.removeEventListener("resize",Ce),Ce=void 0)}}r(Ws,"resizeWindow");function lr(t,e){return typeof t=="function"?Ws(t):Us(t,e)}r(lr,"resize");var Jt={value:null,addProjectionMetrics:null};function zs(t){return we(t)&&t.tagName==="svg"}r(zs,"isSVGSVGElement");var Ii=r(t=>typeof t=="number"?t:parseFloat(t),"asNumber");var Bi=r(()=>({translate:0,scale:1,origin:0,originPoint:0}),"createAxisDelta"),Rt=r(()=>({x:Bi(),y:Bi()}),"createDelta"),ki=r(()=>({min:0,max:0}),"createAxis"),I=r(()=>({x:ki(),y:ki()}),"createBox");var Ks=new WeakMap;function Vt(t){return t!==null&&typeof t=="object"&&typeof t.start=="function"}r(Vt,"isAnimationControls");function Pt(t){return typeof t=="string"||Array.isArray(t)}r(Pt,"isVariantLabel");var cr=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Fi=["initial",...cr];function Lt(t){if(Vt(t.animate))return!0;for(let e=0;e<Fi.length;e++)if(Pt(t[Fi[e]]))return!0;return!1}r(Lt,"isControllingVariants");function uo(t){return!!(Lt(t)||t.variants)}r(uo,"isVariantNode");function Hs(t,e,o){for(let i in e){let n=e[i],a=o[i];if(M(n))t.addValue(i,n);else if(M(a))t.addValue(i,at(n,{owner:t}));else if(a!==n)if(t.hasValue(i)){let s=t.getValue(i);s.liveStyle===!0?s.jump(n):s.hasAnimated||s.set(n)}else{let s=t.getStaticValue(i);t.addValue(i,at(s!==void 0?s:n,{owner:t}))}}for(let i in o)e[i]===void 0&&t.removeValue(i);return e}r(Hs,"updateMotionValuesFromProps");var It={current:null},Qt={current:!1};var nu=typeof window<"u";function mo(){if(Qt.current=!0,!!nu)if(window.matchMedia){let t=window.matchMedia("(prefers-reduced-motion)"),e=r(()=>It.current=t.matches,"setReducedMotionPreferences");t.addEventListener("change",e),e()}else It.current=!1}r(mo,"initPrefersReducedMotion");var $s=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],ur={};function po(t){ur=t}r(po,"setFeatureDefinitions");function Oi(){return ur}r(Oi,"getFeatureDefinitions");var fo=class{static{r(this,"VisualElement")}scrapeMotionValuesFromProps(e,o,i){return{}}constructor({parent:e,props:o,presenceContext:i,reducedMotionConfig:n,skipAnimations:a,blockInitialAnimation:s,visualState:l},u={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=Et,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{let d=D.now();this.renderScheduledAt<d&&(this.renderScheduledAt=d,w.render(this.render,!1,!0))};let{latestValues:c,renderState:m}=l;this.latestValues=c,this.baseTarget={...c},this.initialValues=o.initial?{...c}:{},this.renderState=m,this.parent=e,this.props=o,this.presenceContext=i,this.depth=e?e.depth+1:0,this.reducedMotionConfig=n,this.skipAnimationsConfig=a,this.options=u,this.blockInitialAnimation=!!s,this.isControllingVariants=Lt(o),this.isVariantNode=uo(o),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(e&&e.current);let{willChange:f,...p}=this.scrapeMotionValuesFromProps(o,{},this);for(let d in p){let h=p[d];c[d]!==void 0&&M(h)&&h.set(c[d])}}mount(e){if(this.hasBeenMounted)for(let o in this.initialValues)this.values.get(o)?.jump(this.initialValues[o]),this.latestValues[o]=this.initialValues[o];if(this.current=e,Ks.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.isVariantNode&&!this.isControllingVariants){let o=this;do o=o.props.inherit!==!1&&o.parent;while(o&&!o.isVariantNode);if(o){let{variantChildren:i}=o;i.add(this),this.removeFromVariantTree=()=>i.delete(this)}}this.values.forEach((o,i)=>this.bindToMotionValue(i,o)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(Qt.current||mo(),this.shouldReduceMotion=It.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,this.parent?.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){this.projection&&this.projection.unmount(),J(this.notifyUpdate),J(this.render),this.valueSubscriptions.forEach(e=>e()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(let e in this.events)this.events[e].clear();for(let e in this.features){let o=this.features[e];o&&(o.unmount(),o.isMounted=!1)}this.current=null}addChild(e){this.children.add(e),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(e)}removeChild(e){this.children.delete(e),this.enteringChildren&&this.enteringChildren.delete(e)}bindToMotionValue(e,o){if(this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)(),o.accelerate&&eo.has(e)&&this.current instanceof HTMLElement){let{factory:s,keyframes:l,times:u,ease:c,duration:m}=o.accelerate,f=new Se({element:this.current,name:e,keyframes:l,times:u,ease:c,duration:G(m)}),p=s(f);this.valueSubscriptions.set(e,()=>{p(),f.cancel()});return}let i=Q.has(e);i&&this.onBindTransform&&this.onBindTransform();let n=o.on("change",s=>{this.latestValues[e]=s,this.props.onUpdate&&w.preRender(this.notifyUpdate),i&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()}),a;typeof window<"u"&&window.MotionCheckAppearSync&&(a=window.MotionCheckAppearSync(this,e,o)),this.valueSubscriptions.set(e,()=>{n(),a&&a()})}sortNodePosition(e){return!this.current||!e.current||!this.sortInstanceNodePosition||this.type!==e.type?0:this.sortInstanceNodePosition(this.current,e.current)}updateFeatures(){let e="animation";for(e in ur){let o=ur[e];if(!o)continue;let{isEnabled:i,Feature:n}=o;if(!this.features[e]&&n&&i(this.props)&&(this.features[e]=new n(this)),this.features[e]){let a=this.features[e];a.isMounted?a.update():(a.mount(),a.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):I()}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,o){this.latestValues[e]=o}update(e,o){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=o;for(let i=0;i<$s.length;i++){let n=$s[i];this.propEventSubscriptions[n]&&(this.propEventSubscriptions[n](),delete this.propEventSubscriptions[n]);let a="on"+n,s=e[a];s&&(this.propEventSubscriptions[n]=this.on(n,s))}this.prevMotionValues=Hs(this,this.scrapeMotionValuesFromProps(e,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}addValue(e,o){let i=this.values.get(e);if(o!==i){i&&this.removeValue(e),this.bindToMotionValue(e,o),this.values.set(e,o);let n=o.get();n!==void 0&&(this.latestValues[e]=n)}}removeValue(e){this.values.delete(e);let o=this.valueSubscriptions.get(e);o&&(o(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,o){if(this.props.values&&this.props.values[e])return this.props.values[e];let i=this.values.get(e);return i===void 0&&o!==void 0&&(i=at(o??this.getDefaultValue?.(e),{owner:this}),this.addValue(e,i)),i}readValue(e,o){let i=this.latestValues[e]!==void 0||!this.current?this.latestValues[e]:this.getBaseTargetFromProps(this.props,e)??this.readValueFromInstance(this.current,e,this.options);return i!=null&&(typeof i=="string"&&(Gt(i)||Ut(i))?i=parseFloat(i):typeof i!="number"&&!j.test(i)&&j.test(o)&&(i=Te(e,o)),this.setBaseTarget(e,M(i)?i.get():i)),M(i)?i.get():i}setBaseTarget(e,o){this.baseTarget[e]=o}on(e,o){return this.events[e]||(this.events[e]=new ut),this.events[e].add(o)}notify(e,...o){this.events[e]&&this.events[e].notify(...o)}scheduleRenderMicrotask(){qt.render(this.render)}};var Me=class extends fo{static{r(this,"DOMVisualElement")}constructor(){super(...arguments),this.KeyframeResolver=Qo}sortInstanceNodePosition(e,o){return e.compareDocumentPosition(o)&2?1:-1}getBaseTargetFromProps(e,o){let i=e.style;return i?i[o]:void 0}removeValueFromRenderState(e,{vars:o,style:i}){delete o[e],delete i[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:e}=this.props;M(e)&&(this.childSubscription=e.on("change",o=>{this.current&&(this.current.textContent=`${o}`)}))}};var z=class{static{r(this,"Feature")}constructor(e){this.isMounted=!1,this.node=e}update(){}};function mr(t,{style:e,vars:o},i,n){let a=t.style,s;for(s in e)a[s]=e[s];n?.applyProjectionStyles(a,i);for(s in o)a.setProperty(s,o[s])}r(mr,"renderHTML");var te={};function ho(t,{layout:e,layoutId:o}){return Q.has(t)||t.startsWith("origin")||(e||o!==void 0)&&(!!te[t]||t==="opacity")}r(ho,"isForcedMotionValue");function ee(t,e,o){let i=t.style,n=e?.style,a={};if(!i)return a;for(let s in i)(M(i[s])||n&&M(n[s])||ho(s,t)||o?.getValue(s)?.liveStyle!==void 0)&&(a[s]=i[s]);return a}r(ee,"scrapeMotionValuesFromProps");function su(t){return window.getComputedStyle(t)}r(su,"getComputedStyle");var go=class extends Me{static{r(this,"HTMLVisualElement")}constructor(){super(...arguments),this.type="html",this.renderInstance=mr}mount(e){Z(!!e.style,"motion.create() components must forward their ref to a HTML or SVG element","custom-component-ref"),super.mount(e)}readValueFromInstance(e,o){if(Q.has(o))return this.projection?.isProjecting?Ht(o):Xn(e,o);{let i=su(e),n=(Do(o)?i.getPropertyValue(o):i[o])||0;return typeof n=="string"?n.trim():n}}measureInstanceViewportBox(e,{transformPagePoint:o}){return or(e,o)}build(e,o,i){Xt(e,o,i.transformTemplate)}scrapeMotionValuesFromProps(e,o,i){return ee(e,o,i)}};var fr=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);var yo=r(t=>typeof t=="string"&&t.toLowerCase()==="svg","isSVGTag");function _s(t,e,o,i){mr(t,e,void 0,i);for(let n in e.attrs)t.setAttribute(fr.has(n)?n:be(n),e.attrs[n])}r(_s,"renderSVG");function xo(t,e,o){let i=ee(t,e,o);for(let n in t)if(M(t[n])||M(e[n])){let a=ht.indexOf(n)!==-1?"attr"+n.charAt(0).toUpperCase()+n.substring(1):n;i[a]=t[n]}return i}r(xo,"scrapeMotionValuesFromProps");var vo=class extends Me{static{r(this,"SVGVisualElement")}constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=I}getBaseTargetFromProps(e,o){return Q.has(o)?super.getBaseTargetFromProps(e,o)??Ht(o):e[o]}getDefaultValue(e){return Q.has(e)?this.latestValues[e]??Ht(e):void 0}readValueFromInstance(e,o){if(Q.has(o)){let i=jo(o);return i&&i.default||0}if(xi.includes(o)){let n=getComputedStyle(e)[o];if(typeof n=="string"&&n)return n.trim()}return o=fr.has(o)?o:be(o),e.getAttribute(o)}scrapeMotionValuesFromProps(e,o,i){return xo(e,o,i)}build(e,o,i){so(e,o,this.isSVGTag,i.transformTemplate,i.style)}renderInstance(e,o,i,n){_s(e,o,i,n)}mount(e){this.isSVGTag=yo(e.tagName),super.mount(e)}};function ji(t,e){if(!Array.isArray(e))return!1;let o=e.length;if(o!==t.length)return!1;for(let i=0;i<o;i++)if(e[i]!==t[i])return!1;return!0}r(ji,"shallowCompare");var au=[...cr].reverse();function Ni(t){let e=r(l=>Promise.all(l.map(({animation:u,options:c})=>Ss(t,u,c))),"animate"),o=Ys(),i=!0,n=!1;function a(l){let{props:u,parent:c,manuallyAnimateOnMount:m}=t,f=i||n,p=[],d=new Set,h={},x=1/0,g=t;do g=g.props.inherit!==!1&&g.parent;while(g&&!g.isControllingVariants);if(au.forEach((V,P)=>{let T=o[V],C=u[V],R=g&&g.props[V],y=C!==void 0?C:Pt(R)||R===!1?R:void 0,S=Pt(y),F=V===l?T.isActive:null;F===!1&&(x=P);let L=S&&C===void 0&&!(f&&m);if(T.protectedKeys={...h},!T.isActive&&F===null||!y&&!T.prevProp||Vt(y)||typeof y=="boolean")return;if(V==="exit"&&T.isActive&&F!==!0){h={...h,...T.prevResolvedValues};return}let gt=Xs(T.prevProp,y),yt=gt||S&&(F&&!L||P>x),q=!1,le=Array.isArray(y)?y:[y],ce={};if(F!==!1)for(let Y of le){let{transition:lt,transitionEnd:jt,...Po}=tt(t,Y,Yo(t,V))||{};ce={...ce,...Po,...jt}}let{prevResolvedValues:un}=T;for(let Y in{...un,...ce}){if(Y in h)continue;let lt=ce[Y],jt=un[Y],Po=Array.isArray(lt)&&Array.isArray(jt)?!ji(lt,jt)||gt:lt!==jt;if(Po&&lt==null)d.add(Y);else if(Po||lt!==void 0&&d.has(Y)){yt=!0,d.delete(Y)&&(q=!0),T.needsAnimating[Y]=!0;let mn=t.getValue(Y);mn&&(mn.liveStyle=!1)}else T.protectedKeys[Y]=!0}if(T.prevProp=y,T.prevResolvedValues=ce,T.isActive&&(h={...h,...ce}),yt&&(!(L&&gt)||q))for(let Y of le){let lt={type:V};if(typeof Y=="string"&&f&&m&&c?.enteringChildren){let jt=tt(c,Y)?.transition?.delayChildren;lt.delay=$o(c.enteringChildren,t,jt)}p.push({animation:Y,options:lt})}}),d.size){let{initial:V}=u,P={},T=typeof V!="boolean"&&tt(t,Array.isArray(V)?V[0]:V,t.presenceContext?.custom);T&&T.transition&&(P.transition=T.transition),d.forEach(C=>{let R=t.getValue(C);R&&(R.liveStyle=!0);let y=T&&!Array.isArray(V)?T[C]:void 0,S=t.getBaseTargetFromProps(u,C);P[C]=(y!==void 0?y:S!==void 0&&!M(S)?S:t.initialValues[C]===void 0?t.baseTarget[C]:void 0)??null}),p.push({animation:P})}let b=f&&t.blockInitialAnimation||i&&!m&&(u.initial===!1||u.initial===u.animate);return i=n=!1,!b&&p.length?e(p):Promise.resolve()}r(a,"animateChanges");function s(l,u){if(o[l].isActive===u)return Promise.resolve();t.variantChildren?.forEach(m=>m.animationState?.setActive(l,u)),o[l].isActive=u;let c=a(l);for(let m in o)o[m].protectedKeys={};return c}return r(s,"setActive"),{animateChanges:a,setActive:s,setAnimateFunction:r(l=>{e=l(t)},"setAnimateFunction"),getState:r(()=>o,"getState"),reset:r(()=>{o=Ys(),n=!0},"reset")}}r(Ni,"createAnimationState");function Xs(t,e){return typeof e=="string"?e!==t:Array.isArray(e)?!ji(e,t):!1}r(Xs,"checkVariantsDidChange");function Ys(){let t={};for(let e of cr)t[e]={isActive:e==="animate",protectedKeys:{},needsAnimating:{},prevResolvedValues:{}};return t}r(Ys,"createState");function pr(t,e){t.min=e.min,t.max=e.max}r(pr,"copyAxisInto");function nt(t,e){pr(t.x,e.x),pr(t.y,e.y)}r(nt,"copyBoxInto");function Gi(t,e){t.translate=e.translate,t.scale=e.scale,t.originPoint=e.originPoint,t.origin=e.origin}r(Gi,"copyAxisDeltaInto");var qs=1e-4,lu=1-qs,cu=1+qs,Zs=.01,uu=0-Zs,mu=0+Zs;function U(t){return t.max-t.min}r(U,"calcLength");function Ki(t,e,o){return Math.abs(t-e)<=o}r(Ki,"isNear");function Ui(t,e,o,i=.5){t.origin=i,t.originPoint=A(e.min,e.max,t.origin),t.scale=U(o)/U(e),t.translate=A(o.min,o.max,t.origin)-t.originPoint,(t.scale>=lu&&t.scale<=cu||isNaN(t.scale))&&(t.scale=1),(t.translate>=uu&&t.translate<=mu||isNaN(t.translate))&&(t.translate=0)}r(Ui,"calcAxisDelta");function oe(t,e,o,i){Ui(t.x,e.x,o.x,i?i.originX:void 0),Ui(t.y,e.y,o.y,i?i.originY:void 0)}r(oe,"calcBoxDelta");function Wi(t,e,o,i=0){let n=i?A(o.min,o.max,i):o.min;t.min=n+e.min,t.max=t.min+U(e)}r(Wi,"calcRelativeAxis");function Hi(t,e,o,i){Wi(t.x,e.x,o.x,i?.x),Wi(t.y,e.y,o.y,i?.y)}r(Hi,"calcRelativeBox");function zi(t,e,o,i=0){let n=i?A(o.min,o.max,i):o.min;t.min=e.min-n,t.max=t.min+U(e)}r(zi,"calcRelativeAxisPosition");function De(t,e,o,i){zi(t.x,e.x,o.x,i?.x),zi(t.y,e.y,o.y,i?.y)}r(De,"calcRelativePosition");function Js(t,e,o,i,n){return t-=e,t=lo(t,1/o,i),n!==void 0&&(t=lo(t,1/n,i)),t}r(Js,"removePointDelta");function fu(t,e=0,o=1,i=.5,n,a=t,s=t){if(_.test(e)&&(e=parseFloat(e),e=A(s.min,s.max,e/100)-s.min),typeof e!="number")return;let l=A(a.min,a.max,i);t===a&&(l-=e),t.min=Js(t.min,e,o,l,n),t.max=Js(t.max,e,o,l,n)}r(fu,"removeAxisDelta");function Qs(t,e,[o,i,n],a,s){fu(t,e[o],e[i],e[n],e.scale,a,s)}r(Qs,"removeAxisTransforms");var pu=["x","scaleX","originX"],hu=["y","scaleY","originY"];function $i(t,e,o,i){Qs(t.x,e,pu,o?o.x:void 0,i?i.x:void 0),Qs(t.y,e,hu,o?o.y:void 0,i?i.y:void 0)}r($i,"removeBoxTransforms");function ta(t){return t.translate===0&&t.scale===1}r(ta,"isAxisDeltaZero");function _i(t){return ta(t.x)&&ta(t.y)}r(_i,"isDeltaZero");function ea(t,e){return t.min===e.min&&t.max===e.max}r(ea,"axisEquals");function ra(t,e){return ea(t.x,e.x)&&ea(t.y,e.y)}r(ra,"boxEquals");function oa(t,e){return Math.round(t.min)===Math.round(e.min)&&Math.round(t.max)===Math.round(e.max)}r(oa,"axisEqualsRounded");function Yi(t,e){return oa(t.x,e.x)&&oa(t.y,e.y)}r(Yi,"boxEqualsRounded");function Xi(t){return U(t.x)/U(t.y)}r(Xi,"aspectRatio");function qi(t,e){return t.translate===e.translate&&t.scale===e.scale&&t.originPoint===e.originPoint}r(qi,"axisDeltaEquals");function et(t){return[t("x"),t("y")]}r(et,"eachAxis");function ia(t,e){return e.max===e.min?0:t/(e.max-e.min)*100}r(ia,"pixelsToPercent");var Ee={correct:r((t,e)=>{if(!e.target)return t;if(typeof t=="string")if(v.test(t))t=parseFloat(t);else return t;let o=ia(t,e.target.x),i=ia(t,e.target.y);return`${o}% ${i}%`},"correct")};var na={correct:r((t,{treeScale:e,projectionDelta:o})=>{let i=t,n=j.parse(t);if(n.length>5)return i;let a=j.createTransformer(t),s=typeof n[0]!="number"?1:0,l=o.x.scale*e.x,u=o.y.scale*e.y;n[0+s]/=l,n[1+s]/=u;let c=A(l,u,.5);return typeof n[2+s]=="number"&&(n[2+s]/=c),typeof n[3+s]=="number"&&(n[3+s]/=c),a(n)},"correct")};function sa(t,e,o){let i="",n=t.x.translate/e.x,a=t.y.translate/e.y,s=o?.z||0;if((n||a||s)&&(i=`translate3d(${n}px, ${a}px, ${s}px) `),(e.x!==1||e.y!==1)&&(i+=`scale(${1/e.x}, ${1/e.y}) `),o){let{transformPerspective:c,rotate:m,pathRotation:f,rotateX:p,rotateY:d,skewX:h,skewY:x}=o;c&&(i=`perspective(${c}px) ${i}`),m&&(i+=`rotate(${m}deg) `),f&&(i+=`rotate(${f}deg) `),p&&(i+=`rotateX(${p}deg) `),d&&(i+=`rotateY(${d}deg) `),h&&(i+=`skewX(${h}deg) `),x&&(i+=`skewY(${x}deg) `)}let l=t.x.scale*e.x,u=t.y.scale*e.y;return(l!==1||u!==1)&&(i+=`scale(${l}, ${u})`),i||"none"}r(sa,"buildProjectionTransform");var du=io.length,aa=r(t=>typeof t=="number"||v.test(t),"isPx");function ca(t,e,o,i,n,a){n?(t.opacity=A(0,o.opacity??1,gu(i)),t.opacityExit=A(e.opacity??1,0,yu(i))):a&&(t.opacity=A(e.opacity??1,o.opacity??1,i));for(let s=0;s<du;s++){let l=io[s],u=la(e,l),c=la(o,l);if(u===void 0&&c===void 0)continue;u||(u=0),c||(c=0),u===0||c===0||aa(u)===aa(c)?(t[l]=Math.max(A(Ii(u),Ii(c),i),0),(_.test(c)||_.test(u))&&(t[l]+="%")):t[l]=c}(e.rotate||o.rotate)&&(t.rotate=A(e.rotate||0,o.rotate||0,i))}r(ca,"mixValues");function la(t,e){return t[e]!==void 0?t[e]:t.borderRadius}r(la,"getRadius");var gu=ua(0,.5,ze),yu=ua(.5,.95,O);function ua(t,e,o){return i=>i<t?0:i>e?1:o(ct(t,e,i))}r(ua,"compress");function ma(t,e,o){let i=M(t)?t:at(t);return i.start(Yt("",i,e,o)),i.animation}r(ma,"animateSingleValue");function dt(t,e,o,i={passive:!0}){return t.addEventListener(e,o,i),()=>t.removeEventListener(e,o,i)}r(dt,"addDomEvent");var fa=r((t,e)=>t.depth-e.depth,"compareByDepth");var hr=class{static{r(this,"FlatTree")}constructor(){this.children=[],this.isDirty=!1}add(e){Nt(this.children,e),this.isDirty=!0}remove(e){bt(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(fa),this.isDirty=!1,this.children.forEach(e)}};function pa(t,e){let o=D.now(),i=r(({timestamp:n})=>{let a=n-o;a>=e&&(J(i),t(a-e))},"checkElapsed");return w.setup(i,!0),()=>J(i)}r(pa,"delay");function re(t){return M(t)?t.get():t}r(re,"resolveMotionValue");var dr=class{static{r(this,"NodeStack")}constructor(){this.members=[]}add(e){Nt(this.members,e);for(let o=this.members.length-1;o>=0;o--){let i=this.members[o];if(i===e||i===this.lead||i===this.prevLead)continue;let n=i.instance;(!n||n.isConnected===!1)&&!i.snapshot&&(bt(this.members,i),i.unmount())}e.scheduleRender()}remove(e){if(bt(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){let o=this.members[this.members.length-1];o&&this.promote(o)}}relegate(e){for(let o=this.members.indexOf(e)-1;o>=0;o--){let i=this.members[o];if(i.isPresent!==!1&&i.instance?.isConnected!==!1)return this.promote(i),!0}return!1}promote(e,o){let i=this.lead;if(e!==i&&(this.prevLead=i,this.lead=e,e.show(),i)){i.updateSnapshot(),e.scheduleRender();let{layoutDependency:n}=i.options,{layoutDependency:a}=e.options;(n===void 0||n!==a)&&(e.resumeFrom=i,o&&(i.preserveOpacity=!0),i.snapshot&&(e.snapshot=i.snapshot,e.snapshot.latestValues=i.animationValues||i.latestValues),e.root?.isUpdating&&(e.isLayoutDirty=!0)),e.options.crossfade===!1&&i.hide()}}exitAnimationComplete(){this.members.forEach(e=>{e.options.onExitComplete?.(),e.resumingFrom?.options.onExitComplete?.()})}scheduleRender(){this.members.forEach(e=>e.instance&&e.scheduleRender(!1))}removeLeadSnapshot(){this.lead?.snapshot&&(this.lead.snapshot=void 0)}};var ha={borderRadius:{...Ee,applyTo:[...io]},borderTopLeftRadius:Ee,borderTopRightRadius:Ee,borderBottomLeftRadius:Ee,borderBottomRightRadius:Ee,boxShadow:na};var ie={hasAnimatedSinceResize:!0,hasEverUpdated:!1};Object.assign(te,{...ha,...te});var ne={nodes:0,calculatedTargetDeltas:0,calculatedProjections:0},Zi=["","X","Y","Z"],xu=1e3,vu=0;function Ji(t,e,o,i){let{latestValues:n}=e;n[t]&&(o[t]=n[t],e.setStaticValue(t,0),i&&(i[t]=0))}r(Ji,"resetDistortingTransform");function Pa(t){if(t.hasCheckedOptimisedAppear=!0,t.root===t)return;let{visualElement:e}=t.options;if(!e)return;let o=qo(e);if(window.MotionHasOptimisedAnimation(o,"transform")){let{layout:n,layoutId:a}=t.options;window.MotionCancelOptimisedAnimation(o,"transform",w,!(n||a))}let{parent:i}=t;i&&!i.hasCheckedOptimisedAppear&&Pa(i)}r(Pa,"cancelTreeOptimisedTransformAnimations");function gr({attachResizeListener:t,defaultParent:e,measureScroll:o,checkIsScrollRoot:i,resetTransform:n}){return class{static{r(this,"ProjectionNode")}constructor(s={},l=e?.()){this.id=vu++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,Jt.value&&(ne.nodes=ne.calculatedTargetDeltas=ne.calculatedProjections=0),this.nodes.forEach(Vu),this.nodes.forEach(Du),this.nodes.forEach(Eu),this.nodes.forEach(Pu),Jt.addProjectionMetrics&&Jt.addProjectionMetrics(ne)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=l?l.root||l:this,this.path=l?[...l.path,l]:[],this.parent=l,this.depth=l?l.depth+1:0;for(let u=0;u<this.path.length;u++)this.path[u].shouldResetTransform=!0;this.root===this&&(this.nodes=new hr)}addEventListener(s,l){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new ut),this.eventHandlers.get(s).add(l)}notifyListeners(s,...l){let u=this.eventHandlers.get(s);u&&u.notify(...l)}hasListeners(s){return this.eventHandlers.has(s)}mount(s){if(this.instance)return;this.isSVG=we(s)&&!zs(s),this.instance=s;let{layoutId:l,layout:u,visualElement:c}=this.options;if(c&&!c.current&&c.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(u||l)&&(this.isLayoutDirty=!0),t){let m,f=0,p=r(()=>this.root.updateBlockedByResize=!1,"resizeUnblockUpdate");w.read(()=>{f=window.innerWidth}),t(s,()=>{let d=window.innerWidth;d!==f&&(f=d,this.root.updateBlockedByResize=!0,m&&m(),m=pa(p,250),ie.hasAnimatedSinceResize&&(ie.hasAnimatedSinceResize=!1,this.nodes.forEach(ya)))})}l&&this.root.registerSharedNode(l,this),this.options.animate!==!1&&c&&(l||u)&&this.addEventListener("didUpdate",({delta:m,hasLayoutChanged:f,hasRelativeLayoutChanged:p,layout:d})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let h=this.options.transition||c.getDefaultTransition()||ku,{onLayoutAnimationStart:x,onLayoutAnimationComplete:g}=c.getProps(),b=!this.targetLayout||!Yi(this.targetLayout,d),V=!f&&p;if(this.options.layoutRoot||this.resumeFrom||V||f&&(b||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);let P={...Ve(h,"layout"),onPlay:x,onComplete:g};(c.shouldReduceMotion||this.options.layoutRoot)&&(P.delay=0,P.type=!1),this.startAnimation(P),this.setAnimationOrigin(m,V,P.path)}else f||ya(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=d})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);let s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),J(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(Ru),this.animationId++)}getTransformTemplate(){let{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Pa(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let m=0;m<this.path.length;m++){let f=this.path[m];f.shouldResetTransform=!0,(typeof f.latestValues.x=="string"||typeof f.latestValues.y=="string")&&(f.isLayoutDirty=!0),f.updateScroll("snapshot"),f.options.layoutRoot&&f.willUpdate(!1)}let{layoutId:l,layout:u}=this.options;if(l===void 0&&!u)return;let c=this.getTransformTemplate();this.prevTransformTemplateValue=c?c(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){let u=this.updateBlockedByResize;this.unblockUpdate(),this.updateBlockedByResize=!1,this.clearAllSnapshots(),u&&this.nodes.forEach(wu),this.nodes.forEach(da);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(ga);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(Au),this.nodes.forEach(Cu),this.nodes.forEach(Mu),this.nodes.forEach(Tu),this.nodes.forEach(Su)):this.nodes.forEach(ga),this.clearAllSnapshots();let l=D.now();E.delta=W(0,1e3/60,l-E.timestamp),E.timestamp=l,E.isProcessing=!0,qe.update.process(E),qe.preRender.process(E),qe.render.process(E),E.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,qt.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(bu),this.sharedNodes.forEach(Lu)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,w.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){w.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!U(this.snapshot.measuredBox.x)&&!U(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let u=0;u<this.path.length;u++)this.path[u].updateScroll();let s=this.layout;this.layout=this.measure(!1),this.layoutCorrected||(this.layoutCorrected=I()),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);let{visualElement:l}=this.options;l&&l.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let l=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(l=!1),l&&this.instance){let u=i(this.instance);this.scroll={animationId:this.root.animationId,phase:s,isRoot:u,offset:o(this.instance),wasRoot:this.scroll?this.scroll.isRoot:u}}}resetTransform(){if(!n)return;let s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,l=this.projectionDelta&&!_i(this.projectionDelta),u=this.getTransformTemplate(),c=u?u(this.latestValues,""):void 0,m=c!==this.prevTransformTemplateValue;s&&this.instance&&(l||St(this.latestValues)||m)&&(n(this.instance,c),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){let l=this.measurePageBox(),u=this.removeElementScroll(l);return s&&(u=this.removeTransform(u)),Fu(u),{animationId:this.root.animationId,measuredBox:l,layoutBox:u,latestValues:{},source:this.id}}measurePageBox(){let{visualElement:s}=this.options;if(!s)return I();let l=s.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(Ou))){let{scroll:c}=this.root;c&&(rt(l.x,c.offset.x),rt(l.y,c.offset.y))}return l}removeElementScroll(s){let l=I();if(nt(l,s),this.scroll?.wasRoot)return l;for(let u=0;u<this.path.length;u++){let c=this.path[u],{scroll:m,options:f}=c;c!==this.root&&m&&f.layoutScroll&&(m.wasRoot&&nt(l,s),rt(l.x,m.offset.x),rt(l.y,m.offset.y))}return l}applyTransform(s,l=!1,u){let c=u||I();nt(c,s);for(let m=0;m<this.path.length;m++){let f=this.path[m];!l&&f.options.layoutScroll&&f.scroll&&f!==f.root&&(rt(c.x,-f.scroll.offset.x),rt(c.y,-f.scroll.offset.y)),St(f.latestValues)&&co(c,f.latestValues,f.layout?.layoutBox)}return St(this.latestValues)&&co(c,this.latestValues,this.layout?.layoutBox),c}removeTransform(s){let l=I();nt(l,s);for(let u=0;u<this.path.length;u++){let c=this.path[u];if(!St(c.latestValues))continue;let m;c.instance&&(er(c.latestValues)&&c.updateSnapshot(),m=I(),nt(m,c.measurePageBox())),$i(l,c.latestValues,c.snapshot?.layoutBox,m)}return St(this.latestValues)&&$i(l,this.latestValues),l}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==E.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){let l=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=l.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=l.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=l.isSharedProjectionDirty);let u=!!this.resumingFrom||this!==l;if(!(s||u&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:m,layoutId:f}=this.options;if(!this.layout||!(m||f))return;this.resolvedRelativeTargetAt=E.timestamp;let p=this.getClosestProjectingParent();!this.targetDelta&&!this.relativeTarget&&(this.options.layoutAnchor!==!1&&p&&p.layout?this.createRelativeTarget(p,this.layout.layoutBox,p.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=I(),this.targetWithTransforms=I()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),Hi(this.target,this.relativeTarget,this.relativeParent.target,this.options.layoutAnchor||void 0)):this.targetDelta?(this.resumingFrom?this.applyTransform(this.layout.layoutBox,!1,this.target):nt(this.target,this.layout.layoutBox),bi(this.target,this.targetDelta)):nt(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,this.options.layoutAnchor!==!1&&p&&!!p.resumingFrom==!!this.resumingFrom&&!p.options.layoutScroll&&p.target&&this.animationProgress!==1?this.createRelativeTarget(p,this.target,p.target):this.relativeParent=this.relativeTarget=void 0),Jt.value&&ne.calculatedTargetDeltas++)}getClosestProjectingParent(){if(!(!this.parent||er(this.parent.latestValues)||Vi(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(s,l,u){this.relativeParent=s,this.forceRelativeParentToResolveTarget(),this.relativeTarget=I(),this.relativeTargetOrigin=I(),De(this.relativeTargetOrigin,l,u,this.options.layoutAnchor||void 0),nt(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){let s=this.getLead(),l=!!this.resumingFrom||this!==s,u=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(u=!1),l&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(u=!1),this.resolvedRelativeTargetAt===E.timestamp&&(u=!1),u)return;let{layout:c,layoutId:m}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(c||m))return;nt(this.layoutCorrected,this.layout.layoutBox);let f=this.treeScale.x,p=this.treeScale.y;ks(this.layoutCorrected,this.treeScale,this.path,l),s.layout&&!s.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(s.target=s.layout.layoutBox,s.targetWithTransforms=I());let{target:d}=s;if(!d){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Gi(this.prevProjectionDelta.x,this.projectionDelta.x),Gi(this.prevProjectionDelta.y,this.projectionDelta.y)),oe(this.projectionDelta,this.layoutCorrected,d,this.latestValues),(this.treeScale.x!==f||this.treeScale.y!==p||!qi(this.projectionDelta.x,this.prevProjectionDelta.x)||!qi(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",d)),Jt.value&&ne.calculatedProjections++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){if(this.options.visualElement?.scheduleRender(),s){let l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Rt(),this.projectionDelta=Rt(),this.projectionDeltaWithTransform=Rt()}setAnimationOrigin(s,l=!1,u){let c=this.snapshot,m=c?c.latestValues:{},f={...this.latestValues},p=Rt();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!l;let d=I(),h=c?c.source:void 0,x=this.layout?this.layout.source:void 0,g=h!==x,b=this.getStack(),V=!b||b.members.length<=1,P=!!(g&&!V&&this.options.crossfade===!0&&!this.path.some(Bu));this.animationProgress=0;let T,C=u?.interpolateProjection(s);this.mixTargetDelta=R=>{let y=R/1e3,S=C?.(y);S?(p.x.translate=S.x,p.x.scale=A(s.x.scale,1,y),p.x.origin=s.x.origin,p.x.originPoint=s.x.originPoint,p.y.translate=S.y,p.y.scale=A(s.y.scale,1,y),p.y.origin=s.y.origin,p.y.originPoint=s.y.originPoint):(xa(p.x,s.x,y),xa(p.y,s.y,y)),this.setTargetDelta(p),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(De(d,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),Iu(this.relativeTarget,this.relativeTargetOrigin,d,y),T&&ra(this.relativeTarget,T)&&(this.isProjectionDirty=!1),T||(T=I()),nt(T,this.relativeTarget)),g&&(this.animationValues=f,ca(f,m,this.latestValues,y,P,V)),S&&S.rotate!==void 0&&(this.animationValues||(this.animationValues=f),this.animationValues.pathRotation=S.rotate),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=y},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(J(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=w.update(()=>{ie.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=at(0)),this.motionValue.jump(0,!1),this.currentAnimation=ma(this.motionValue,[0,1e3],{...s,velocity:0,isSync:!0,onUpdate:r(l=>{this.mixTargetDelta(l),s.onUpdate&&s.onUpdate(l)},"onUpdate"),onComplete:r(()=>{s.onComplete&&s.onComplete(),this.completeAnimation()},"onComplete")}),zn(this.currentAnimation,this),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);let s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(xu),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let s=this.getLead(),{targetWithTransforms:l,layout:u,latestValues:c}=s,{target:m}=s;if(!(!l||!m||!u)){if(this!==s&&this.layout&&u&&ba(this.options.animationType,this.layout.layoutBox,u.layoutBox)){m=this.target||I();let f=U(this.layout.layoutBox.x);m.x.min=s.target.x.min,m.x.max=m.x.min+f;let p=U(this.layout.layoutBox.y);m.y.min=s.target.y.min,m.y.max=m.y.min+p}nt(l,m),co(l,c),oe(this.projectionDeltaWithTransform,this.layoutCorrected,l,c)}}registerSharedNode(s,l){this.sharedNodes.has(s)||this.sharedNodes.set(s,new dr),this.sharedNodes.get(s).add(l);let c=l.options.initialPromotionConfig;l.promote({transition:c?c.transition:void 0,preserveFollowOpacity:c&&c.shouldPreserveFollowOpacity?c.shouldPreserveFollowOpacity(l):void 0})}isLead(){let s=this.getStack();return s?s.lead===this:!0}getLead(){let{layoutId:s}=this.options;return s?this.getStack()?.lead||this:this}getPrevLead(){let{layoutId:s}=this.options;return s?this.getStack()?.prevLead:void 0}getStack(){let{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:l,preserveFollowOpacity:u}={}){let c=this.getStack();c&&c.promote(this,u),s&&(this.projectionDelta=void 0,this.needsReset=!0),l&&this.setOptions({transition:l})}relegate(){let s=this.getStack();return s?s.relegate(this):!1}resetSkewAndRotation(){let{visualElement:s}=this.options;if(!s)return;let l=!1,{latestValues:u}=s;if((u.z||u.rotate||u.rotateX||u.rotateY||u.rotateZ||u.skewX||u.skewY)&&(l=!0),!l)return;let c={};u.z&&Ji("z",s,c,this.animationValues);for(let m=0;m<Zi.length;m++)Ji(`rotate${Zi[m]}`,s,c,this.animationValues),Ji(`skew${Zi[m]}`,s,c,this.animationValues);s.render();for(let m in c)s.setStaticValue(m,c[m]),this.animationValues&&(this.animationValues[m]=c[m]);s.scheduleRender()}applyProjectionStyles(s,l){if(!this.instance||this.isSVG)return;if(!this.isVisible){s.visibility="hidden";return}let u=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,s.visibility="",s.opacity="",s.pointerEvents=re(l?.pointerEvents)||"",s.transform=u?u(this.latestValues,""):"none";return}let c=this.getLead();if(!this.projectionDelta||!this.layout||!c.target){this.options.layoutId&&(s.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,s.pointerEvents=re(l?.pointerEvents)||""),this.hasProjected&&!St(this.latestValues)&&(s.transform=u?u({},""):"none",this.hasProjected=!1);return}s.visibility="";let m=c.animationValues||c.latestValues;this.applyTransformsToTarget();let f=sa(this.projectionDeltaWithTransform,this.treeScale,m);u&&(f=u(m,f)),s.transform=f;let{x:p,y:d}=this.projectionDelta;s.transformOrigin=`${p.origin*100}% ${d.origin*100}% 0`,c.animationValues?s.opacity=c===this?m.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:m.opacityExit:s.opacity=c===this?m.opacity!==void 0?m.opacity:"":m.opacityExit!==void 0?m.opacityExit:0;for(let h in te){if(m[h]===void 0)continue;let{correct:x,applyTo:g,isCSSVariable:b}=te[h],V=f==="none"?m[h]:x(m[h],c);if(g){let P=g.length;for(let T=0;T<P;T++)s[g[T]]=V}else b?this.options.visualElement.renderState.vars[h]=V:s[h]=V}this.options.layoutId&&(s.pointerEvents=c===this?re(l?.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>s.currentAnimation?.stop()),this.root.nodes.forEach(da),this.root.sharedNodes.clear()}}}r(gr,"createProjectionNode");function Tu(t){t.updateLayout()}r(Tu,"updateLayout");function Su(t){let e=t.resumeFrom?.snapshot||t.snapshot;if(t.isLead()&&t.layout&&e&&t.hasListeners("didUpdate")){let{layoutBox:o,measuredBox:i}=t.layout,{animationType:n}=t.options,a=e.source!==t.layout.source;if(n==="size")et(m=>{let f=a?e.measuredBox[m]:e.layoutBox[m],p=U(f);f.min=o[m].min,f.max=f.min+p});else if(n==="x"||n==="y"){let m=n==="x"?"y":"x";pr(a?e.measuredBox[m]:e.layoutBox[m],o[m])}else ba(n,e.layoutBox,o)&&et(m=>{let f=a?e.measuredBox[m]:e.layoutBox[m],p=U(o[m]);f.max=f.min+p,t.relativeTarget&&!t.currentAnimation&&(t.isProjectionDirty=!0,t.relativeTarget[m].max=t.relativeTarget[m].min+p)});let s=Rt();oe(s,o,e.layoutBox);let l=Rt();a?oe(l,t.applyTransform(i,!0),e.measuredBox):oe(l,o,e.layoutBox);let u=!_i(s),c=!1;if(!t.resumeFrom){let m=t.getClosestProjectingParent();if(m&&!m.resumeFrom){let{snapshot:f,layout:p}=m;if(f&&p){let d=t.options.layoutAnchor||void 0,h=I();De(h,e.layoutBox,f.layoutBox,d);let x=I();De(x,o,p.layoutBox,d),Yi(h,x)||(c=!0),m.options.layoutRoot&&(t.relativeTarget=x,t.relativeTargetOrigin=h,t.relativeParent=m)}}}t.notifyListeners("didUpdate",{layout:o,snapshot:e,delta:l,layoutDelta:s,hasLayoutChanged:u,hasRelativeLayoutChanged:c})}else if(t.isLead()){let{onExitComplete:o}=t.options;o&&o()}t.options.transition=void 0}r(Su,"notifyLayoutUpdate");function Vu(t){Jt.value&&ne.nodes++,t.parent&&(t.isProjecting()||(t.isProjectionDirty=t.parent.isProjectionDirty),t.isSharedProjectionDirty||(t.isSharedProjectionDirty=!!(t.isProjectionDirty||t.parent.isProjectionDirty||t.parent.isSharedProjectionDirty)),t.isTransformDirty||(t.isTransformDirty=t.parent.isTransformDirty))}r(Vu,"propagateDirtyNodes");function Pu(t){t.isProjectionDirty=t.isSharedProjectionDirty=t.isTransformDirty=!1}r(Pu,"cleanDirtyNodes");function bu(t){t.clearSnapshot()}r(bu,"clearSnapshot");function da(t){t.clearMeasurements()}r(da,"clearMeasurements");function wu(t){t.isLayoutDirty=!0,t.updateLayout()}r(wu,"forceLayoutMeasure");function ga(t){t.isLayoutDirty=!1}r(ga,"clearIsLayoutDirty");function Au(t){t.isAnimationBlocked&&t.layout&&!t.isLayoutDirty&&(t.snapshot=t.layout,t.isLayoutDirty=!0)}r(Au,"ensureDraggedNodesSnapshotted");function Cu(t){t.relativeTarget&&t.relativeParent?.isLayoutDirty&&(t.currentAnimation?t.isLayoutDirty=!0:(t.targetDelta=void 0,t.removeRelativeTarget()))}r(Cu,"syncRelativeLayout");function Mu(t){let{visualElement:e}=t.options;e&&e.getProps().onBeforeLayoutMeasure&&e.notify("BeforeLayoutMeasure"),t.resetTransform()}r(Mu,"resetTransformStyle");function ya(t){t.finishAnimation(),t.targetDelta=t.relativeTarget=t.target=void 0,t.isProjectionDirty=!0}r(ya,"finishAnimation");function Du(t){t.resolveTargetDelta()}r(Du,"resolveTargetDelta");function Eu(t){t.calcProjection()}r(Eu,"calcProjection");function Ru(t){t.resetSkewAndRotation()}r(Ru,"resetSkewAndRotation");function Lu(t){t.removeLeadSnapshot()}r(Lu,"removeLeadSnapshots");function xa(t,e,o){t.translate=A(e.translate,0,o),t.scale=A(e.scale,1,o),t.origin=e.origin,t.originPoint=e.originPoint}r(xa,"mixAxisDeltaLinear");function va(t,e,o,i){t.min=A(e.min,o.min,i),t.max=A(e.max,o.max,i)}r(va,"mixAxis");function Iu(t,e,o,i){va(t.x,e.x,o.x,i),va(t.y,e.y,o.y,i)}r(Iu,"mixBox");function Bu(t){return t.animationValues&&t.animationValues.opacityExit!==void 0}r(Bu,"hasOpacityCrossfade");var ku={duration:.45,ease:[.4,0,.1,1]},Ta=r(t=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(t),"userAgentContains"),Sa=Ta("applewebkit/")&&!Ta("chrome/")?Math.round:O;function Va(t){t.min=Sa(t.min),t.max=Sa(t.max)}r(Va,"roundAxis");function Fu(t){Va(t.x),Va(t.y)}r(Fu,"roundBox");function ba(t,e,o){return t==="position"||t==="preserve-aspect"&&!Ki(Xi(e),Xi(o),.2)}r(ba,"shouldAnimatePositionOnly");function Ou(t){return t!==t.root&&t.scroll?.wasRoot}r(Ou,"checkNodeWasScrollRoot");var wa=gr({attachResizeListener:r((t,e)=>dt(t,"resize",e),"attachResizeListener"),measureScroll:r(()=>({x:document.documentElement.scrollLeft||document.body?.scrollLeft||0,y:document.documentElement.scrollTop||document.body?.scrollTop||0}),"measureScroll"),checkIsScrollRoot:r(()=>!0,"checkIsScrollRoot")});var yr={current:void 0},To=gr({measureScroll:r(t=>({x:t.scrollLeft,y:t.scrollTop}),"measureScroll"),defaultParent:r(()=>{if(!yr.current){let t=new wa({});t.mount(window),t.setOptions({layoutScroll:!0}),yr.current=t}return yr.current},"defaultParent"),resetTransform:r((t,e)=>{t.style.transform=e!==void 0?e:"none"},"resetTransform"),checkIsScrollRoot:r(t=>window.getComputedStyle(t).position==="fixed","checkIsScrollRoot")});var Aa=B(N(),1);function ju(){!Qt.current&&mo();let[t]=(0,Aa.useState)(It.current);return t}r(ju,"useReducedMotion");var Ca=B(N(),1),xr=(0,Ca.createContext)({});var Ma=B(N(),1);function Da(t){let e=(0,Ma.useRef)(null);return e.current===null&&(e.current=t()),e.current}r(Da,"useConstant");var vr=B(N(),1);var Ea=typeof window<"u";var Qi=Ea?vr.useLayoutEffect:vr.useEffect;var Ra=B(N(),1),Re=(0,Ra.createContext)(null);var La=B(N(),1);var Tr=(0,La.createContext)({transformPagePoint:r(t=>t,"transformPagePoint"),isStatic:!1,reducedMotion:"never"});var Bt=B(N(),1);function Ia(t=!0){let e=(0,Bt.useContext)(Re);if(e===null)return[!0,null];let{isPresent:o,onExitComplete:i,register:n}=e,a=(0,Bt.useId)();(0,Bt.useEffect)(()=>{if(t)return n(a)},[t]);let s=(0,Bt.useCallback)(()=>t&&i&&i(a),[a,i,t]);return!o&&i?[!1,s]:[!0]}r(Ia,"usePresence");var Ba=B(N(),1),Sr=(0,Ba.createContext)({strict:!1});var ka={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Fa=!1;function Nu(){if(Fa)return;let t={};for(let e in ka)t[e]={isEnabled:r(o=>ka[e].some(i=>!!o[i]),"isEnabled")};po(t),Fa=!0}r(Nu,"initFeatureDefinitions");function Vr(){return Nu(),Oi()}r(Vr,"getInitializedFeatureDefinitions");function Oa(t){let e=Vr();for(let o in t)e[o]={...e[o],...t[o]};po(e)}r(Oa,"loadFeatures");var Cr=B(fn(),1);var ke=B(N(),1);var ja=B(N(),1),kt=(0,ja.createContext)({});var Pr=B(N(),1);function Na(t,e){if(Lt(t)){let{initial:o,animate:i}=t;return{initial:o===!1||Pt(o)?o:void 0,animate:Pt(i)?i:void 0}}return t.inherit!==!1?e:{}}r(Na,"getCurrentTreeVariants");function Ua(t){let{initial:e,animate:o}=Na(t,(0,Pr.useContext)(kt));return(0,Pr.useMemo)(()=>({initial:e,animate:o}),[Ga(e),Ga(o)])}r(Ua,"useCreateMotionContext");function Ga(t){return Array.isArray(t)?t.join(" "):t}r(Ga,"variantLabelsAsDependency");var Be=B(N(),1);var Wa=B(N(),1);var Le=r(()=>({style:{},transform:{},transformOrigin:{},vars:{}}),"createHtmlRenderState");function tn(t,e,o){for(let i in e)!M(e[i])&&!ho(i,o)&&(t[i]=e[i])}r(tn,"copyRawValuesOnly");function Gu({transformTemplate:t},e){return(0,Wa.useMemo)(()=>{let o=Le();return Xt(o,e,t),Object.assign({},o.vars,o.style)},[e])}r(Gu,"useInitialMotionValues");function Uu(t,e){let o=t.style||{},i={};return tn(i,o,t),Object.assign(i,Gu(t,e)),i}r(Uu,"useStyle");function za(t,e){let o={},i=Uu(t,e);return t.drag&&t.dragListener!==!1&&(o.draggable=!1,i.userSelect=i.WebkitUserSelect=i.WebkitTouchCallout="none",i.touchAction=t.drag===!0?"none":`pan-${t.drag==="x"?"y":"x"}`),t.tabIndex===void 0&&(t.onTap||t.onTapStart||t.whileTap)&&(o.tabIndex=0),o.style=i,o}r(za,"useHTMLProps");var Ka=B(N(),1);var br=r(()=>({...Le(),attrs:{}}),"createSvgRenderState");function Ha(t,e,o,i){let n=(0,Ka.useMemo)(()=>{let a=br();return so(a,e,yo(i),t.transformTemplate,t.style),{...a.attrs,style:{...a.style}}},[e]);if(t.style){let a={};tn(a,t.style,t),n.style={...a,...n.style}}return n}r(Ha,"useSVGProps");var Wu=new Set(["animate","exit","variants","initial","style","values","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function So(t){return t.startsWith("while")||t.startsWith("drag")&&t!=="draggable"||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||Wu.has(t)}r(So,"isValidMotionProp");function zu(t,e){return t.startsWith("on")?!So(t):e?.(t)??!So(t)}r(zu,"shouldForward");function $a(t,e,o,i){let n={};for(let a in t)a==="values"&&typeof t.values=="object"||M(t[a])||(zu(a,i)||o===!0&&So(a)||!e&&!So(a)||t.draggable&&a.startsWith("onDrag"))&&(n[a]=t[a]);return n}r($a,"filterProps");var _a=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Ie(t){return typeof t!="string"||t.includes("-")?!1:!!(_a.indexOf(t)>-1||/[A-Z]/u.test(t))}r(Ie,"isSVGComponent");function Ya(t,e,o,{latestValues:i},n,a=!1,s,l){let c=(s??Ie(t)?Ha:za)(e,i,n,t),m=$a(e,typeof t=="string",a,l),f=t!==Be.Fragment?{...m,...c,ref:o}:{},{children:p}=e,d=(0,Be.useMemo)(()=>M(p)?p.get():p,[p]);return(0,Be.createElement)(t,{...f,children:d})}r(Ya,"useRender");var en=B(N(),1);function Ku({scrapeMotionValuesFromProps:t,createRenderState:e},o,i,n){return{latestValues:Hu(o,i,n,t),renderState:e()}}r(Ku,"makeState");function Hu(t,e,o,i){let n={},a=i(t,{});for(let p in a)n[p]=re(a[p]);let{initial:s,animate:l}=t,u=Lt(t),c=uo(t);e&&c&&!u&&t.inherit!==!1&&(s===void 0&&(s=e.initial),l===void 0&&(l=e.animate));let m=o?o.initial===!1:!1;m=m||s===!1;let f=m?l:s;if(f&&typeof f!="boolean"&&!Vt(f)){let p=Array.isArray(f)?f:[f];for(let d=0;d<p.length;d++){let h=oo(t,p[d]);if(h){let{transitionEnd:x,transition:g,...b}=h;for(let V in b){let P=b[V];if(Array.isArray(P)){let T=m?P.length-1:0;P=P[T]}P!==null&&(n[V]=P)}for(let V in x)n[V]=x[V]}}}return n}r(Hu,"makeLatestValues");var wr=r(t=>(e,o)=>{let i=(0,en.useContext)(kt),n=(0,en.useContext)(Re),a=r(()=>Ku(t,e,i,n),"make");return o?a():Da(a)},"makeUseVisualState");var Xa=wr({scrapeMotionValuesFromProps:ee,createRenderState:Le});var qa=wr({scrapeMotionValuesFromProps:xo,createRenderState:br});var Za=Symbol.for("motionComponentSymbol");var se=B(N(),1);function Ja(t,e,o){let i=(0,se.useRef)(o);(0,se.useInsertionEffect)(()=>{i.current=o});let n=(0,se.useRef)(null);return(0,se.useCallback)(a=>{a&&t.onMount?.(a),e&&(a?e.mount(a):e.unmount());let s=i.current;if(typeof s=="function")if(a){let l=s(a);typeof l=="function"&&(n.current=l)}else n.current?(n.current(),n.current=null):s(a);else s&&(s.current=a)},[e])}r(Ja,"useMotionRef");var X=B(N(),1);var Qa=B(N(),1),Ar=(0,Qa.createContext)({});function Ft(t){return t&&typeof t=="object"&&Object.prototype.hasOwnProperty.call(t,"current")}r(Ft,"isRefObject");function tl(t,e,o,i,n,a){let{visualElement:s}=(0,X.useContext)(kt),l=(0,X.useContext)(Sr),u=(0,X.useContext)(Re),c=(0,X.useContext)(Tr),m=c.reducedMotion,f=c.skipAnimations,p=(0,X.useRef)(null),d=(0,X.useRef)(!1);i=i||l.renderer,!p.current&&i&&(p.current=i(t,{visualState:e,parent:s,props:o,presenceContext:u,blockInitialAnimation:u?u.initial===!1:!1,reducedMotionConfig:m,skipAnimations:f,isSVG:a}),d.current&&p.current&&(p.current.manuallyAnimateOnMount=!0));let h=p.current,x=(0,X.useContext)(Ar);h&&!h.projection&&n&&(h.type==="html"||h.type==="svg")&&$u(p.current,o,n,x);let g=(0,X.useRef)(!1);(0,X.useInsertionEffect)(()=>{h&&g.current&&h.update(o,u)});let b=o[ro],V=(0,X.useRef)(!!b&&typeof window<"u"&&!window.MotionHandoffIsComplete?.(b)&&window.MotionHasOptimisedAnimation?.(b));return Qi(()=>{!d.current||!h||(h.animationState?.animateChanges(),h.enteringChildren=void 0)},[]),Qi(()=>{d.current=!0,h&&(g.current=!0,window.MotionIsMounted=!0,h.updateFeatures(),h.scheduleRenderMicrotask(),V.current&&h.animationState&&h.animationState.animateChanges())}),(0,X.useEffect)(()=>{h&&(!V.current&&h.animationState&&h.animationState.animateChanges(),V.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(b)}),V.current=!1),h.enteringChildren=void 0)}),h}r(tl,"useVisualElement");function $u(t,e,o,i){let{layoutId:n,layout:a,drag:s,dragConstraints:l,layoutScroll:u,layoutRoot:c,layoutAnchor:m,layoutCrossfade:f}=e;t.projection=new o(t.latestValues,e["data-framer-portal-id"]?void 0:el(t.parent)),t.projection.setOptions({layoutId:n,layout:a,alwaysMeasureLayout:!!s||l&&Ft(l),visualElement:t,animationType:typeof a=="string"?a:"both",initialPromotionConfig:i,crossfade:f,layoutScroll:u,layoutRoot:c,layoutAnchor:m})}r($u,"createProjectionNode");function el(t){if(t)return t.options.allowProjection!==!1?t.projection:el(t.parent)}r(el,"getClosestProjectingNode");function Mr(t,{forwardMotionProps:e=!1,type:o}={},i,n){i&&Oa(i);let a=o?o==="svg":Ie(t),s=a?qa:Xa;function l(c,m){let f,p={...(0,ke.useContext)(Tr),...c,layoutId:_u(c)},{isStatic:d,isValidProp:h}=p,x=Ua(c),g=s(c,d);if(!d&&typeof window<"u"){Yu(p,i);let b=Xu(p);f=b.MeasureLayout,x.visualElement=tl(t,g,p,n,b.ProjectionNode,a)}return(0,Cr.jsxs)(kt.Provider,{value:x,children:[f&&x.visualElement?(0,Cr.jsx)(f,{visualElement:x.visualElement,...p}):null,Ya(t,c,Ja(g,x.visualElement,m),g,d,e,a,h)]})}r(l,"MotionDOMComponent"),l.displayName=`motion.${typeof t=="string"?t:`create(${t.displayName??t.name??""})`}`;let u=(0,ke.forwardRef)(l);return u[Za]=t,u}r(Mr,"createMotionComponent");function _u({layoutId:t}){let e=(0,ke.useContext)(xr).id;return e&&t!==void 0?e+"-"+t:t}r(_u,"useLayoutId");function Yu(t,e){let o=(0,ke.useContext)(Sr).strict}r(Yu,"useStrictMode");function Xu(t){let e=Vr(),{drag:o,layout:i}=e;if(!o&&!i)return{};let n={...o,...i};return{MeasureLayout:o?.isEnabled(t)||i?.isEnabled(t)?n.MeasureLayout:void 0,ProjectionNode:n.ProjectionNode}}r(Xu,"getProjectionFunctionality");function ol(t,e){if(typeof Proxy>"u")return Mr;let o=new Map,i=r((a,s)=>Mr(a,s,t,e),"factory"),n=r((a,s)=>i(a,s),"deprecatedFactoryFunction");return new Proxy(n,{get:r((a,s)=>s==="create"?i:(o.has(s)||o.set(s,Mr(s,void 0,t,e)),o.get(s)),"get")})}r(ol,"createMotionProxy");var rl=B(N(),1);var il=r((t,e)=>e.isSVG??Ie(t)?new vo(e):new go(e,{allowProjection:t!==rl.Fragment}),"createDomVisualElement");var Dr=class extends z{static{r(this,"AnimationFeature")}constructor(e){super(e),e.animationState||(e.animationState=Ni(e))}updateAnimationControlsSubscription(){let{animate:e}=this.node.getProps();Vt(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){let{animate:e}=this.node.getProps(),{animate:o}=this.node.prevProps||{};e!==o&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}};var qu=0,Er=class extends z{static{r(this,"ExitAnimationFeature")}constructor(){super(...arguments),this.id=qu++}update(){let{presenceContext:e,prevPresenceContext:o,animationState:i}=this.node;if(!e||!i)return;let{isPresent:n,onExitComplete:a}=e,s=o?.isPresent;if(n===s)return;if(n&&s===!1){if(this.exit===!0){let{initial:u}=this.node.getProps();if(u&&!Array.isArray(u)){let{transition:c,transitionEnd:m,...f}=tt(this.node,u)||{};for(let p in f)this.node.getValue(p)?.jump(f[p])}this.node.blockInitialAnimation=!1,i.reset(),i.animateChanges()}else i.setActive("exit",!1);this.exit=void 0;return}let l=this.exit=i.setActive("exit",!n);a&&!n&&l.then(()=>{this.exit===l&&(this.exit=!0,a(this.id))})}mount(){let{register:e,onExitComplete:o}=this.node.presenceContext||{};o&&o(this.id),e&&(this.unmount=e(this.id))}unmount(){}};var nl={animation:{Feature:Dr},exit:{Feature:Er}};function ae(t){return{point:{x:t.pageX,y:t.pageY}}}r(ae,"extractEventInfo");var sl=r(t=>e=>Zt(e)&&t(e,ae(e)),"addPointerInfo");function Ot(t,e,o,i){return dt(t,e,sl(o),i)}r(Ot,"addPointerEvent");var Rr=r(({current:t})=>t?t.ownerDocument.defaultView:null,"getContextWindow");var al=r((t,e)=>Math.abs(t-e),"distance");function ll(t,e){let o=al(t.x,e.x),i=al(t.y,e.y);return Math.sqrt(o**2+i**2)}r(ll,"distance2D");var cl=new Set(["auto","scroll"]),Fe=class{static{r(this,"PanSession")}constructor(e,o,{transformPagePoint:i,contextWindow:n=window,dragSnapToOrigin:a=!1,distanceThreshold:s=3,element:l}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=h=>{this.handleScroll(h.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.hasPendingMove=!1,this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=Lr(this.lastRawMoveEventInfo,this.transformPagePoint));let h=on(this.lastMoveEventInfo,this.history),x=this.startEvent!==null,g=ll(h.offset,{x:0,y:0})>=this.distanceThreshold;if(!x&&!g)return;let{point:b}=h;this.history.push({...b,timestamp:D.now()});let{onStart:V,onMove:P}=this.handlers;x||(V&&V(this.lastMoveEvent,h),this.startEvent=this.lastMoveEvent),P&&P(this.lastMoveEvent,h)},this.handlePointerMove=(h,x)=>{this.lastMoveEvent=h,this.lastRawMoveEventInfo=x,this.lastMoveEventInfo=Lr(x,this.transformPagePoint),this.hasPendingMove=!0,w.update(this.updatePoint,!0)},this.handlePointerUp=(h,x)=>{this.hasPendingMove&&this.updatePoint(),this.end();let{onEnd:g,onSessionEnd:b,resumeAnimation:V}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&V&&V(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let P=on(h.type==="pointercancel"?this.lastMoveEventInfo:Lr(x,this.transformPagePoint),this.history);this.startEvent&&g&&g(h,P),b&&b(h,P)},!Zt(e))return;this.dragSnapToOrigin=a,this.handlers=o,this.transformPagePoint=i,this.distanceThreshold=s,this.contextWindow=n||window;let u=ae(e),c=Lr(u,this.transformPagePoint),{point:m}=c,{timestamp:f}=E;this.history=[{...m,timestamp:f}];let{onSessionStart:p}=o;p&&p(e,on(c,this.history));let d={passive:!0,capture:!0};this.removeListeners=st(Ot(this.contextWindow,"pointermove",this.handlePointerMove,d),Ot(this.contextWindow,"pointerup",this.handlePointerUp,d),Ot(this.contextWindow,"pointercancel",this.handlePointerUp,d)),l&&this.startScrollTracking(l)}startScrollTracking(e){let o=e.parentElement;for(;o;){let i=getComputedStyle(o);(cl.has(i.overflowX)||cl.has(i.overflowY))&&this.scrollPositions.set(o,{x:o.scrollLeft,y:o.scrollTop}),o=o.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(e){let o=this.scrollPositions.get(e);if(!o)return;let i=e===window,n=i?{x:window.scrollX,y:window.scrollY}:{x:e.scrollLeft,y:e.scrollTop},a={x:n.x-o.x,y:n.y-o.y};a.x===0&&a.y===0||(i?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=a.x,this.lastMoveEventInfo.point.y+=a.y):this.history.length>0&&(this.history[0].x-=a.x,this.history[0].y-=a.y),this.scrollPositions.set(e,n),w.update(this.updatePoint,!0))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),J(this.updatePoint)}};function Lr(t,e){return e?{point:e(t.point)}:t}r(Lr,"transformPoint");function ul(t,e){return{x:t.x-e.x,y:t.y-e.y}}r(ul,"subtractPoint");function on({point:t},e){return{point:t,delta:ul(t,ml(e)),offset:ul(t,Zu(e)),velocity:Ju(e,.1)}}r(on,"getPanInfo");function Zu(t){return t[0]}r(Zu,"startDevicePoint");function ml(t){return t[t.length-1]}r(ml,"lastDevicePoint");function Ju(t,e){if(t.length<2)return{x:0,y:0};let o=t.length-1,i=null,n=ml(t);for(;o>=0&&(i=t[o],!(n.timestamp-i.timestamp>G(e)));)o--;if(!i)return{x:0,y:0};i===t[0]&&t.length>2&&n.timestamp-i.timestamp>G(e)*2&&(i=t[1]);let a=K(n.timestamp-i.timestamp);if(a===0)return{x:0,y:0};let s={x:(n.x-i.x)/a,y:(n.y-i.y)/a};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}r(Ju,"getVelocity");function gl(t,{min:e,max:o},i){return e!==void 0&&t<e?t=i?A(e,t,i.min):Math.max(t,e):o!==void 0&&t>o&&(t=i?A(o,t,i.max):Math.min(t,o)),t}r(gl,"applyConstraints");function fl(t,e,o){return{min:e!==void 0?t.min+e:void 0,max:o!==void 0?t.max+o-(t.max-t.min):void 0}}r(fl,"calcRelativeAxisConstraints");function yl(t,{top:e,left:o,bottom:i,right:n}){return{x:fl(t.x,o,n),y:fl(t.y,e,i)}}r(yl,"calcRelativeConstraints");function pl(t,e){let o=e.min-t.min,i=e.max-t.max;return e.max-e.min<t.max-t.min&&([o,i]=[i,o]),{min:o,max:i}}r(pl,"calcViewportAxisConstraints");function xl(t,e){return{x:pl(t.x,e.x),y:pl(t.y,e.y)}}r(xl,"calcViewportConstraints");function vl(t,e){let o=.5,i=U(t),n=U(e);return n>i?o=ct(e.min,e.max-i,t.min):i>n&&(o=ct(t.min,t.max-n,e.min)),W(0,1,o)}r(vl,"calcOrigin");function Tl(t,e){let o={};return e.min!==void 0&&(o.min=e.min-t.min),e.max!==void 0&&(o.max=e.max-t.min),o}r(Tl,"rebaseAxisConstraints");var Ir=.35;function Sl(t=Ir){return t===!1?t=0:t===!0&&(t=Ir),{x:hl(t,"left","right"),y:hl(t,"top","bottom")}}r(Sl,"resolveDragElastic");function hl(t,e,o){return{min:dl(t,e),max:dl(t,o)}}r(hl,"resolveAxisElastic");function dl(t,e){return typeof t=="number"?t:t[e]||0}r(dl,"resolvePointElastic");var Qu=new WeakMap,kr=class{static{r(this,"VisualElementDragControls")}constructor(e){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=I(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=e}start(e,{snapToCursor:o=!1,distanceThreshold:i}={}){let{presenceContext:n}=this.visualElement;if(n&&n.isPresent===!1)return;let a=r(f=>{o&&this.snapToCursor(f),this.stopAnimation()},"onSessionStart"),s=r((f,p)=>{let{drag:d,dragPropagation:h,onDragStart:x}=this.getProps();if(d&&!h&&(this.openDragLock&&this.openDragLock(),this.openDragLock=Ai(d),!this.openDragLock))return;this.latestPointerEvent=f,this.latestPanInfo=p,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),et(b=>{let V=this.getAxisMotionValue(b).get()||0;if(_.test(V)){let{projection:P}=this.visualElement;if(P&&P.layout){let T=P.layout.layoutBox[b];T&&(V=U(T)*(parseFloat(V)/100))}}this.originPoint[b]=V}),x&&w.update(()=>x(f,p),!1,!0),Pe(this.visualElement,"transform");let{animationState:g}=this.visualElement;g&&g.setActive("whileDrag",!0)},"onStart"),l=r((f,p)=>{this.latestPointerEvent=f,this.latestPanInfo=p;let{dragPropagation:d,dragDirectionLock:h,onDirectionLock:x,onDrag:g}=this.getProps();if(!d&&!this.openDragLock)return;let{offset:b}=p;if(h&&this.currentDirection===null){this.currentDirection=em(b),this.currentDirection!==null&&x&&x(this.currentDirection);return}this.updateAxis("x",p.point,b),this.updateAxis("y",p.point,b),this.visualElement.render(),g&&w.update(()=>g(f,p),!1,!0)},"onMove"),u=r((f,p)=>{this.latestPointerEvent=f,this.latestPanInfo=p,this.stop(f,p),this.latestPointerEvent=null,this.latestPanInfo=null},"onSessionEnd"),c=r(()=>{let{dragSnapToOrigin:f}=this.getProps();(f||this.constraints)&&this.startAnimation({x:0,y:0})},"resumeAnimation"),{dragSnapToOrigin:m}=this.getProps();this.panSession=new Fe(e,{onSessionStart:a,onStart:s,onMove:l,onSessionEnd:u,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:m,distanceThreshold:i,contextWindow:Rr(this.visualElement),element:this.visualElement.current})}stop(e,o){let i=e||this.latestPointerEvent,n=o||this.latestPanInfo,a=this.isDragging;if(this.cancel(),!a||!n||!i)return;let{velocity:s}=n;this.startAnimation(s);let{onDragEnd:l}=this.getProps();l&&w.postRender(()=>l(i,n))}cancel(){this.isDragging=!1;let{projection:e,animationState:o}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.endPanSession();let{dragPropagation:i}=this.getProps();!i&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),o&&o.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(e,o,i){let{drag:n}=this.getProps();if(!i||!Br(e,n,this.currentDirection))return;let a=this.getAxisMotionValue(e),s=this.originPoint[e]+i[e];this.constraints&&this.constraints[e]&&(s=gl(s,this.constraints[e],this.elastic[e])),a.set(s)}resolveConstraints(){let{dragConstraints:e,dragElastic:o}=this.getProps(),i=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,n=this.constraints;e&&Ft(e)?this.constraints||(this.constraints=this.resolveRefConstraints()):e&&i?this.constraints=yl(i.layoutBox,e):this.constraints=!1,this.elastic=Sl(o),n!==this.constraints&&!Ft(e)&&i&&this.constraints&&!this.hasMutatedConstraints&&et(a=>{this.constraints!==!1&&this.getAxisMotionValue(a)&&(this.constraints[a]=Tl(i.layoutBox[a],this.constraints[a]))})}resolveRefConstraints(){let{dragConstraints:e,onMeasureDragConstraints:o}=this.getProps();if(!e||!Ft(e))return!1;let i=e.current;Z(i!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.","drag-constraints-ref");let{projection:n}=this.visualElement;if(!n||!n.layout)return!1;n.root&&(n.root.scroll=void 0,n.root.updateScroll());let a=wi(i,n.root,this.visualElement.getTransformPagePoint()),s=xl(n.layout.layoutBox,a);if(o){let l=o(vi(s));this.hasMutatedConstraints=!!l,l&&(s=ao(l))}return s}startAnimation(e){let{drag:o,dragMomentum:i,dragElastic:n,dragTransition:a,dragSnapToOrigin:s,onDragTransitionEnd:l}=this.getProps(),u=this.constraints||{},c=et(m=>{if(!Br(m,o,this.currentDirection))return;let f=u&&u[m]||{};(s===!0||s===m)&&(f={min:0,max:0});let p=n?200:1e6,d=n?40:1e7,h={type:"inertia",velocity:i?e[m]:0,bounceStiffness:p,bounceDamping:d,timeConstant:750,restDelta:1,restSpeed:10,...a,...f};return this.startAxisValueAnimation(m,h)});return Promise.all(c).then(l)}startAxisValueAnimation(e,o){let i=this.getAxisMotionValue(e);return Pe(this.visualElement,e),i.start(Yt(e,i,0,o,this.visualElement,!1))}stopAnimation(){et(e=>this.getAxisMotionValue(e).stop())}getAxisMotionValue(e){let o=`_drag${e.toUpperCase()}`,n=this.visualElement.getProps()[o];return n||this.visualElement.getValue(e,this.visualElement.latestValues[e]??0)}snapToCursor({clientX:e,clientY:o}){let{drag:i}=this.getProps(),n={x:e,y:o},a=this.visualElement.getTransformPagePoint()?.(n)||n,s=this.visualElement.measureViewportBox();et(l=>{if(!Br(l,i,this.currentDirection))return;let u=this.getAxisMotionValue(l),{min:c,max:m}=s[l];u.set((u.get()||0)+a[l]-A(c,m,.5))})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:e,dragConstraints:o}=this.getProps(),{projection:i}=this.visualElement;if(!Ft(o)||!i||!this.constraints)return;this.stopAnimation();let n=this.constraints,a={x:0,y:0};et(l=>{let u=this.getAxisMotionValue(l).get();a[l]=vl({min:u,max:u},n[l])});let{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",i.root&&i.root.updateScroll(),i.updateLayout(),this.constraints=!1,this.resolveConstraints(),et(l=>{let u=this.getAxisMotionValue(l);if(!Br(l,e,null)||!u.get())return;let{min:c,max:m}=this.constraints[l];u.set(A(c,m,a[l]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;Qu.set(this.visualElement,this);let e=this.visualElement.current,o=Ot(e,"pointerdown",c=>{let{drag:m,dragListener:f=!0}=this.getProps(),p=c.target,d=p!==e&&Ei(p);m&&f&&!d&&this.start(c)}),i,n=r(()=>{let{dragConstraints:c}=this.getProps();Ft(c)&&c.current&&(this.constraints=this.resolveRefConstraints(),i||(i=tm(e,c.current,()=>this.scalePositionWithinConstraints())))},"measureDragConstraints"),{projection:a}=this.visualElement,s=a.addEventListener("measure",n);a&&!a.layout&&(a.root&&a.root.updateScroll(),a.updateLayout()),w.read(n);let l=dt(window,"resize",()=>this.scalePositionWithinConstraints()),u=a.addEventListener("didUpdate",(({delta:c,hasLayoutChanged:m})=>{this.isDragging&&m&&(et(f=>{let p=this.getAxisMotionValue(f);p&&(this.originPoint[f]+=c[f].translate,p.set(p.get()+c[f].translate))}),this.visualElement.render())}));return()=>{l(),o(),s(),u&&u(),i&&i()}}getProps(){let e=this.visualElement.getProps(),{drag:o=!1,dragDirectionLock:i=!1,dragPropagation:n=!1,dragConstraints:a=!1,dragElastic:s=Ir,dragMomentum:l=!0}=e;return{...e,drag:o,dragDirectionLock:i,dragPropagation:n,dragConstraints:a,dragElastic:s,dragMomentum:l}}};function Vl(t){let e=!0;return()=>{if(e){e=!1;return}t()}}r(Vl,"skipFirstCall");function tm(t,e,o){let i=lr(t,Vl(o)),n=lr(e,Vl(o));return()=>{i(),n()}}r(tm,"startResizeObservers");function Br(t,e,o){return(e===!0||e===t)&&(o===null||o===t)}r(Br,"shouldDrag");function em(t,e=10){let o=null;return Math.abs(t.y)>e?o="y":Math.abs(t.x)>e&&(o="x"),o}r(em,"getCurrentDirection");var Fr=class extends z{static{r(this,"DragGesture")}constructor(e){super(e),this.removeGroupControls=O,this.removeListeners=O,this.controls=new kr(e)}mount(){let{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||O}update(){let{dragControls:e}=this.node.getProps(),{dragControls:o}=this.node.prevProps||{};e!==o&&(this.removeGroupControls(),e&&(this.removeGroupControls=e.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}};var rn=r(t=>(e,o)=>{t&&w.update(()=>t(e,o),!1,!0)},"asyncHandler"),Or=class extends z{static{r(this,"PanGesture")}constructor(){super(...arguments),this.removePointerDownListener=O}onPointerDown(e){this.session=new Fe(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Rr(this.node)})}createPanHandlers(){let{onPanSessionStart:e,onPanStart:o,onPan:i,onPanEnd:n}=this.node.getProps();return{onSessionStart:rn(e),onStart:rn(o),onMove:rn(i),onEnd:r((a,s)=>{delete this.session,n&&w.postRender(()=>n(a,s))},"onEnd")}}mount(){this.removePointerDownListener=Ot(this.node.current,"pointerdown",e=>this.onPointerDown(e))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}};var Pl=B(fn(),1);var Vo=B(N(),1);var nn=!1,sn=class extends Vo.Component{static{r(this,"MeasureLayoutWithContext")}componentDidMount(){let{visualElement:e,layoutGroup:o,switchLayoutGroup:i,layoutId:n}=this.props,{projection:a}=e;a&&(o.group&&o.group.add(a),i&&i.register&&n&&i.register(a),nn&&a.root.didUpdate(),a.addEventListener("animationComplete",()=>{this.safeToRemove()}),a.setOptions({...a.options,layoutDependency:this.props.layoutDependency,onExitComplete:r(()=>this.safeToRemove(),"onExitComplete")})),ie.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){let{layoutDependency:o,visualElement:i,drag:n,isPresent:a}=this.props,{projection:s}=i;return s&&(s.isPresent=a,e.layoutDependency!==o&&s.setOptions({...s.options,layoutDependency:o}),nn=!0,n||e.layoutDependency!==o||o===void 0||e.isPresent!==a?s.willUpdate():this.safeToRemove(),e.isPresent!==a&&(a?s.promote():s.relegate()||w.postRender(()=>{let l=s.getStack();(!l||!l.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){let{visualElement:e,layoutAnchor:o}=this.props,{projection:i}=e;i&&(i.options.layoutAnchor=o,i.root.didUpdate(),qt.postRender(()=>{!i.currentAnimation&&i.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:e,layoutGroup:o,switchLayoutGroup:i}=this.props,{projection:n}=e;nn=!0,n&&(n.scheduleCheckAfterUnmount(),o&&o.group&&o.group.remove(n),i&&i.deregister&&i.deregister(n))}safeToRemove(){let{safeToRemove:e}=this.props;e&&e()}render(){return null}};function jr(t){let[e,o]=Ia(),i=(0,Vo.useContext)(xr);return(0,Pl.jsx)(sn,{...t,layoutGroup:i,switchLayoutGroup:(0,Vo.useContext)(Ar),isPresent:e,safeToRemove:o})}r(jr,"MeasureLayout");var bl={pan:{Feature:Or},drag:{Feature:Fr,ProjectionNode:To,MeasureLayout:jr}};function wl(t,e,o){let{props:i}=t;t.animationState&&i.whileHover&&t.animationState.setActive("whileHover",o==="Start");let n="onHover"+o,a=i[n];a&&w.postRender(()=>a(e,ae(e)))}r(wl,"handleHoverEvent");var Nr=class extends z{static{r(this,"HoverGesture")}mount(){let{current:e}=this.node;e&&(this.unmount=Ci(e,(o,i)=>(wl(this.node,i,"Start"),n=>wl(this.node,n,"End"))))}unmount(){}};var Gr=class extends z{static{r(this,"FocusGesture")}constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch{e=!0}!e||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=st(dt(this.node.current,"focus",()=>this.onFocus()),dt(this.node.current,"blur",()=>this.onBlur()))}unmount(){}};function Al(t,e,o){let{props:i}=t;if(t.current instanceof HTMLButtonElement&&t.current.disabled)return;t.animationState&&i.whileTap&&t.animationState.setActive("whileTap",o==="Start");let n="onTap"+(o==="End"?"":o),a=i[n];a&&w.postRender(()=>a(e,ae(e)))}r(Al,"handlePressEvent");var Ur=class extends z{static{r(this,"PressGesture")}mount(){let{current:e}=this.node;if(!e)return;let{globalTapTarget:o,propagate:i}=this.node.props;this.unmount=Li(e,(n,a)=>(Al(this.node,a,"Start"),(s,{success:l})=>Al(this.node,s,l?"End":"Cancel")),{useGlobalTarget:o,stopPropagation:i?.tap===!1})}unmount(){}};var ln=new WeakMap,an=new WeakMap,om=r(t=>{let e=ln.get(t.target);e&&e(t)},"fireObserverCallback"),rm=r(t=>{t.forEach(om)},"fireAllObserverCallbacks");function im({root:t,...e}){let o=t||document;an.has(o)||an.set(o,{});let i=an.get(o),n=JSON.stringify(e);return i[n]||(i[n]=new IntersectionObserver(rm,{root:t,...e})),i[n]}r(im,"initIntersectionObserver");function Cl(t,e,o){let i=im(e);return ln.set(t,o),i.observe(t),()=>{ln.delete(t),i.unobserve(t)}}r(Cl,"observeIntersection");var nm={some:0,all:1},Wr=class extends z{static{r(this,"InViewFeature")}constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.stopObserver?.();let{viewport:e={}}=this.node.getProps(),{root:o,margin:i,amount:n="some",once:a}=e,s={root:o?o.current:void 0,rootMargin:i,threshold:typeof n=="number"?n:nm[n]},l=r(u=>{let{isIntersecting:c}=u;if(this.isInView===c||(this.isInView=c,a&&!c&&this.hasEnteredView))return;c&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",c);let{onViewportEnter:m,onViewportLeave:f}=this.node.getProps(),p=c?m:f;p&&p(u)},"onIntersectionUpdate");this.stopObserver=Cl(this.node.current,s,l)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;let{props:e,prevProps:o}=this.node;["amount","margin","root"].some(sm(e,o))&&this.startObserver()}unmount(){this.stopObserver?.(),this.hasEnteredView=!1,this.isInView=!1}};function sm({viewport:t={}},{viewport:e={}}={}){return o=>t[o]!==e[o]}r(sm,"hasViewportOptionChanged");var Ml={inView:{Feature:Wr},tap:{Feature:Ur},focus:{Feature:Gr},hover:{Feature:Nr}};var Dl={layout:{ProjectionNode:To,MeasureLayout:jr}};var El={...nl,...Ml,...bl,...Dl};var cn=ol(El,il);var KD=cn;export{ju as a,KD as b};
@@ -0,0 +1 @@
1
+ import{b as p,c as l}from"./chunk-RGMVGZV4.js";import{a as t,d as g,e as h}from"./chunk-I26MS5PJ.js";var u=g(h(),1);var a={console:"`",palette:"k"},c="lunora-studio-shortcuts",r=new Set,w=t(o=>{let n=typeof o?.console=="string"?o.console.toLowerCase():void 0,s=typeof o?.palette=="string"?o.palette.toLowerCase():void 0;return n?.length===1&&s?.length===1&&n!==s?{console:n,palette:s}:a},"p"),e=a,m=t(()=>{e=w(p(c)[0]);for(let o of r)o()},"S");m();var y=t(o=>(r.add(o),()=>{r.delete(o)}),"g"),i=t(()=>e,"a"),S=t(()=>(0,u.useSyncExternalStore)(y,i,i),"w"),L=t((o,n)=>{if(n.length!==1)return;let s=n.toLowerCase(),f=o==="console"?"palette":"console";e=e[f]===s?{...e,[o]:s,[f]:e[o]}:{...e,[o]:s},l(c,[e]);for(let d of r)d()},"y"),v=t(()=>{e=a,l(c,[e]);for(let o of r)o()},"C");export{S as a,L as b,v as c};
@@ -0,0 +1 @@
1
+ import{a as s}from"./chunk-7G4Z6Q7X.js";import{d}from"./chunk-HJHSQPHW.js";import{a as e,d as r,e as h,g as k}from"./chunk-I26MS5PJ.js";var l=r(h(),1);var t=r(k(),1);var g=e(({children:m,confirmLabel:c,disabled:a=!1,onConfirm:p,testId:i})=>{let o=d(),[f,n]=(0,l.useState)(!1),u=e(()=>{n(!0)},"f"),C=e(()=>{n(!1)},"l"),b=e(()=>{n(!1),p()},"p");return f?(0,t.jsxs)("span",{className:"inline-flex items-center gap-1","data-testid":`${i}-prompt`,role:"group",children:[(0,t.jsx)(s,{"data-testid":`${i}-confirm`,disabled:a,onClick:b,size:"sm",type:"button",variant:"destructive",children:c??o("Confirm")}),(0,t.jsx)(s,{"data-testid":`${i}-cancel`,onClick:C,size:"sm",type:"button",variant:"ghost",children:o("Cancel")})]}):(0,t.jsx)(s,{"data-testid":i,disabled:a,onClick:u,size:"sm",type:"button",variant:"outline",children:m})},"k");export{g as a};
@@ -0,0 +1 @@
1
+ import{a as $}from"./chunk-G74GIEU4.js";import{a as b}from"./chunk-3CTF6VCQ.js";import"./chunk-NCPW7WHO.js";import"./chunk-VZWZIIP6.js";import"./chunk-55UGUCQ6.js";import{a as u}from"./chunk-4ZEL6BYL.js";import{c as p}from"./chunk-C5NU4UZY.js";import"./chunk-23DA2KK5.js";import"./chunk-QAQDMS6R.js";import"./chunk-YLPATGWK.js";import{a as y,b as w,c as j,d as h,e as c,f as i}from"./chunk-HCTJKP5J.js";import{a as d,e as l}from"./chunk-2IKDEUCX.js";import{d as k}from"./chunk-HJHSQPHW.js";import{a as o,d as I,g as T,i as x}from"./chunk-I26MS5PJ.js";var e=I(T(),1);var m={clean:"text-emerald-600 dark:text-emerald-400",exempt:"text-muted-foreground",failing:"text-red-600 dark:text-red-400",warned:"text-amber-600 dark:text-amber-400"},A={"at-risk":"text-red-600 dark:text-red-400",excellent:"text-emerald-600 dark:text-emerald-400",good:"text-emerald-600 dark:text-emerald-400","needs-work":"text-amber-600 dark:text-amber-400"},C=o((r,a)=>`exempt: ${r.exemptReason===void 0||r.exemptReason===""?a:r.exemptReason}`,"E"),E=o(r=>r.toSorted((a,n)=>a.coverage==="clean"&&n.coverage!=="clean"?1:n.coverage==="clean"&&a.coverage!=="clean"?-1:a.score-n.score),"S"),Y=o(({testId:r="advisor-health"})=>{let a=k(),n=p(u.getAdvisories,{},{live:!0}),g=p(u.getAdvisorProcedures,{},{live:!0}),f=n.data?.advisories??null,N=g.data?.procedures??null,t=f===null||N===null?null:$(N,f),v=g.error??n.error;if(v!==null)return(0,e.jsx)(b,{error:v,testId:`${r}-error`});if(t===null)return(0,e.jsx)(d,{children:(0,e.jsx)(l,{className:"py-8 text-center text-muted-foreground","data-testid":`${r}-loading`,children:a("Loading\u2026")})});let R=E(t.procedures);return(0,e.jsxs)("div",{className:"space-y-4","data-testid":r,children:[(0,e.jsx)(d,{children:(0,e.jsxs)(l,{className:"flex flex-wrap items-baseline gap-x-6 gap-y-2 py-6",children:[(0,e.jsxs)("div",{children:[(0,e.jsx)("span",{className:x("text-4xl font-semibold tabular-nums",A[t.grade]),"data-testid":`${r}-score`,children:t.score}),(0,e.jsx)("span",{className:"text-muted-foreground text-lg",children:"/100"})]}),(0,e.jsx)("span",{className:x("text-sm font-medium uppercase tracking-wide",A[t.grade]),"data-testid":`${r}-grade`,children:t.grade}),(0,e.jsxs)("div",{className:"text-muted-foreground flex gap-4 text-sm tabular-nums","data-testid":`${r}-summary`,children:[(0,e.jsxs)("span",{className:m.clean,children:[t.summary.clean," ",a("clean")]}),(0,e.jsxs)("span",{className:m.warned,children:[t.summary.warned," ",a("warned")]}),(0,e.jsxs)("span",{className:m.failing,children:[t.summary.failing," ",a("failing")]}),(0,e.jsxs)("span",{className:m.exempt,children:[t.summary.exempt," ",a("exempt")]})]})]})}),t.project.checks.length>0&&(0,e.jsx)(d,{children:(0,e.jsxs)(l,{className:"py-4 text-sm","data-testid":`${r}-project`,children:[(0,e.jsxs)("span",{className:"font-medium",children:[a("Schema & config")," ",t.project.score,"/100"]}),(0,e.jsxs)("span",{className:"text-muted-foreground",children:[" \u2014 ",t.project.checks.map(s=>s.name).join(", ")]})]})}),(0,e.jsx)(d,{children:(0,e.jsx)(l,{className:"p-0",children:(0,e.jsxs)(y,{children:[(0,e.jsx)(w,{children:(0,e.jsxs)(h,{children:[(0,e.jsx)(c,{className:"w-20",children:a("Score")}),(0,e.jsx)(c,{children:a("Procedure")}),(0,e.jsx)(c,{className:"w-32",children:a("Kind")}),(0,e.jsx)(c,{children:a("Rules fired")})]})}),(0,e.jsx)(j,{children:R.map(s=>(0,e.jsxs)(h,{"data-testid":`${r}-row`,children:[(0,e.jsx)(i,{className:x("tabular-nums font-medium",m[s.coverage]),children:s.coverage==="exempt"?"\u2014":s.score}),(0,e.jsx)(i,{className:"font-mono text-xs",children:s.id}),(0,e.jsxs)(i,{className:"text-muted-foreground text-xs",children:[s.visibility," ",s.kind,s.sensitivity.level==="high"&&(0,e.jsx)("span",{className:"ml-1 text-amber-600 dark:text-amber-400",children:a("sensitive")})]}),(0,e.jsx)(i,{className:"text-muted-foreground text-xs",children:s.coverage==="exempt"?C(s,a("no reason given")):s.checks.map(S=>S.name).join(", ")})]},s.id))})]})})})]})},"Y");export{Y as default};
@@ -0,0 +1 @@
1
+ import{j as o}from"./chunk-BOMPSVRC.js";import{a as r,d as i,e as p}from"./chunk-I26MS5PJ.js";var a=i(p(),1);var R=a.forwardRef(r(function(e,n){let{className:l,render:m,orientation:t="horizontal",style:f,...s}=e;return o("div",e,{state:{orientation:t},ref:n,props:[{role:"separator","aria-orientation":t},s]})},"SeparatorComponent"));export{R as a};
@@ -0,0 +1 @@
1
+ import{b as Me}from"./chunk-2VA5S3IA.js";import{a as ve}from"./chunk-VCFEO3RI.js";import{b as ye,c as we}from"./chunk-VESGIGMQ.js";import{a as xe}from"./chunk-7RKB5KS7.js";import{a as Ne}from"./chunk-SV764LKQ.js";import"./chunk-NGVP66OH.js";import"./chunk-GHQ2VDI2.js";import{a as be}from"./chunk-R6U22RSY.js";import{a as fe}from"./chunk-YVR4SEPU.js";import{b as he}from"./chunk-ZKJS6EBE.js";import"./chunk-RGMVGZV4.js";import{i as me}from"./chunk-E4PXACVL.js";import"./chunk-MVWZMWPD.js";import"./chunk-7Y3SY37W.js";import"./chunk-3YXASVTP.js";import"./chunk-AUAECCXB.js";import{b as oe}from"./chunk-Q6ED4KUL.js";import"./chunk-BOMPSVRC.js";import{a as ge}from"./chunk-3CTF6VCQ.js";import"./chunk-NCPW7WHO.js";import"./chunk-VZWZIIP6.js";import"./chunk-55UGUCQ6.js";import{a as ce}from"./chunk-4ZEL6BYL.js";import{c as ie}from"./chunk-C5NU4UZY.js";import"./chunk-23DA2KK5.js";import"./chunk-QAQDMS6R.js";import"./chunk-YLPATGWK.js";import{a as ue}from"./chunk-RWVIV3U7.js";import{d as U,m as pe,t as de}from"./chunk-HJHSQPHW.js";import{a as m,d as le,e as Ce,f as Le,g as Te,i as te}from"./chunk-I26MS5PJ.js";var O=le(Le(),1),A=le(Ce(),1);var s=le(Te(),1);var Pe=.5,Ie=4,Se=m(n=>Math.min(100,Math.max(0,n)),"ce"),Ke=m((n,e)=>{if(!Number.isFinite(e)||e<=0)return{leftPercent:0,widthPercent:100};let t=Se(n.offsetMs/e*100),a=n.durationMs/e*100,l=Math.max(Pe,Math.min(Se(a),100-t));return{leftPercent:t,widthPercent:l}},"Ce"),De=m((n,e,t=!1)=>{let a=e.trim().toLowerCase(),l=t?n.filter(r=>!r.ok):n;return a===""?[...l]:l.filter(r=>r.rootName.toLowerCase().includes(a)||r.functionPath.toLowerCase().includes(a)||r.traceId.toLowerCase().includes(a)||r.spans.some(o=>o.name.toLowerCase().includes(a)||o.spanId.toLowerCase().includes(a)))},"Ee"),G=m(n=>Number.isFinite(n)?n>0&&n<1?`${n.toFixed(2)}ms`:`${String(Math.round(n))}ms`:"\u2014","q"),je=m(n=>!Number.isFinite(n)||n<=0?[]:Array.from({length:Ie},(e,t)=>{let a=(t+1)/Ie;return{label:G(n*a),percent:a*100}}),"Pe"),ke=m(n=>{if(typeof n=="string")return n;try{return JSON.stringify(n,pe)}catch{return String(n)}},"ue"),ee=m(n=>{let e=(0,O.c)(7),{label:t,value:a}=n,l;e[0]!==t?(l=(0,s.jsx)("dt",{className:"w-40 shrink-0 text-muted-foreground",children:t}),e[0]=t,e[1]=l):l=e[1];let r;e[2]!==a?(r=(0,s.jsx)("dd",{className:"min-w-0 break-all",children:a}),e[2]=a,e[3]=r):r=e[3];let o;return e[4]!==l||e[5]!==r?(o=(0,s.jsxs)("div",{className:"flex gap-2",children:[l,r]}),e[4]=l,e[5]=r,e[6]=o):o=e[6],o},"Y"),Fe=m(n=>{let e=(0,O.c)(68),{span:t}=n,a=U(),l,r,o,d,i,u;if(e[0]!==t.attributes||e[1]!==t.durationMs||e[2]!==t.error||e[3]!==t.events||e[4]!==t.kind||e[5]!==t.offsetMs||e[6]!==t.parentSpanId||e[7]!==t.spanId||e[8]!==a){let $=Object.entries(t.attributes??{}),_;e[15]!==t.events?(_=t.events??[],e[15]=t.events,e[16]=_):_=e[16],l=_,r="border-t border-border bg-background/60 px-3 py-2 font-mono text-xs",o="tr-span-detail";let y;e[17]!==a?(y=a("Span ID"),e[17]=a,e[18]=y):y=e[18];let w;e[19]!==t.spanId||e[20]!==y?(w=(0,s.jsx)(ee,{label:y,value:t.spanId}),e[19]=t.spanId,e[20]=y,e[21]=w):w=e[21];let M;e[22]!==a?(M=a("Parent span ID"),e[22]=a,e[23]=M):M=e[23];let p;e[24]!==t.parentSpanId||e[25]!==a?(p=t.parentSpanId===""?a("\u2014 (trace root)"):t.parentSpanId,e[24]=t.parentSpanId,e[25]=a,e[26]=p):p=e[26];let h;e[27]!==p||e[28]!==M?(h=(0,s.jsx)(ee,{label:M,value:p}),e[27]=p,e[28]=M,e[29]=h):h=e[29];let b;e[30]!==a?(b=a("Kind"),e[30]=a,e[31]=b):b=e[31];let C=t.kind??"internal",S;e[32]!==b||e[33]!==C?(S=(0,s.jsx)(ee,{label:b,value:C}),e[32]=b,e[33]=C,e[34]=S):S=e[34];let I;e[35]!==a?(I=a("Started at"),e[35]=a,e[36]=I):I=e[36];let g;e[37]!==t.offsetMs||e[38]!==a?(g=a("+{offset}",{offset:G(t.offsetMs)}),e[37]=t.offsetMs,e[38]=a,e[39]=g):g=e[39];let x;e[40]!==I||e[41]!==g?(x=(0,s.jsx)(ee,{label:I,value:g}),e[40]=I,e[41]=g,e[42]=x):x=e[42];let k;e[43]!==a?(k=a("Duration"),e[43]=a,e[44]=k):k=e[44];let f;e[45]!==t.durationMs?(f=G(t.durationMs),e[45]=t.durationMs,e[46]=f):f=e[46];let N;e[47]!==k||e[48]!==f?(N=(0,s.jsx)(ee,{label:k,value:f}),e[47]=k,e[48]=f,e[49]=N):N=e[49],e[50]!==h||e[51]!==S||e[52]!==x||e[53]!==N||e[54]!==w?(d=(0,s.jsxs)("dl",{className:"flex flex-col gap-1",children:[w,h,S,x,N]}),e[50]=h,e[51]=S,e[52]=x,e[53]=N,e[54]=w,e[55]=d):d=e[55],e[56]!==t.error?(i=t.error!==void 0&&(0,s.jsxs)("div",{className:"mt-2 rounded-md border border-destructive/40 bg-destructive/10 px-2 py-1.5","data-testid":"tr-detail-error",children:[(0,s.jsx)("span",{className:"font-semibold text-destructive",children:t.error.type}),(0,s.jsx)("p",{className:"whitespace-pre-wrap break-all text-destructive",children:t.error.message})]}),e[56]=t.error,e[57]=i):i=e[57],u=$.length>0&&(0,s.jsxs)("div",{className:"mt-2","data-testid":"tr-detail-attributes",children:[(0,s.jsx)("p",{className:"mb-1 text-muted-foreground",children:a("Attributes")}),(0,s.jsx)("dl",{className:"flex flex-col gap-1",children:$.map(Ee)})]}),e[0]=t.attributes,e[1]=t.durationMs,e[2]=t.error,e[3]=t.events,e[4]=t.kind,e[5]=t.offsetMs,e[6]=t.parentSpanId,e[7]=t.spanId,e[8]=a,e[9]=l,e[10]=r,e[11]=o,e[12]=d,e[13]=i,e[14]=u}else l=e[9],r=e[10],o=e[11],d=e[12],i=e[13],u=e[14];let c;e[58]!==l||e[59]!==a?(c=l.length>0&&(0,s.jsxs)("div",{className:"mt-2","data-testid":"tr-detail-events",children:[(0,s.jsx)("p",{className:"mb-1 text-muted-foreground",children:a("Events")}),(0,s.jsx)("ul",{className:"flex flex-col gap-1",children:l.map(Oe)})]}),e[58]=l,e[59]=a,e[60]=c):c=e[60];let v;return e[61]!==r||e[62]!==o||e[63]!==d||e[64]!==i||e[65]!==u||e[66]!==c?(v=(0,s.jsxs)("div",{className:r,"data-testid":o,children:[d,i,u,c]}),e[61]=r,e[62]=o,e[63]=d,e[64]=i,e[65]=u,e[66]=c,e[67]=v):v=e[67],v},"Fe");function Ee(n){let[e,t]=n;return(0,s.jsx)(ee,{label:e,value:ke(t)},e)}m(Ee,"Ke");function Ae(n){let[e,t]=n;return`${e}=${ke(t)}`}m(Ae,"Re");function Oe(n){return(0,s.jsxs)("li",{className:"flex gap-2",children:[(0,s.jsx)("span",{className:"shrink-0 tabular-nums text-muted-foreground",children:de(n.ts)}),(0,s.jsx)(oe,{variant:"secondary",children:n.name}),(0,s.jsx)("span",{className:"min-w-0 break-all text-muted-foreground",children:Object.entries(n.attributes??{}).map(Ae).join(" ")})]},`${n.name}:${String(n.ts)}`)}m(Oe,"Ae");var Be=14,_e="grid grid-cols-[14rem_1fr_4rem_16rem_16rem] items-center gap-2 px-3",We=m(n=>{let e=(0,O.c)(17),{traceDurationMs:t}=n,a,l,r,o,d,i;if(e[0]!==t){i=Symbol.for("react.early_return_sentinel");e:{let v=je(t);if(v.length===0){i=null;break e}e[7]===Symbol.for("react.memo_cache_sentinel")?(r=te(_e,"border-b border-border py-1 font-mono text-[10px] text-muted-foreground"),e[7]=r):r=e[7],o="tr-ruler",e[8]===Symbol.for("react.memo_cache_sentinel")?(d=(0,s.jsx)("span",{}),e[8]=d):d=e[8],a="relative h-3",l=v.map(Je)}e[0]=t,e[1]=a,e[2]=l,e[3]=r,e[4]=o,e[5]=d,e[6]=i}else a=e[1],l=e[2],r=e[3],o=e[4],d=e[5],i=e[6];if(i!==Symbol.for("react.early_return_sentinel"))return i;let u;e[9]!==a||e[10]!==l?(u=(0,s.jsx)("span",{className:a,children:l}),e[9]=a,e[10]=l,e[11]=u):u=e[11];let c;return e[12]!==r||e[13]!==o||e[14]!==d||e[15]!==u?(c=(0,s.jsxs)("div",{className:r,"data-testid":o,children:[d,u]}),e[12]=r,e[13]=o,e[14]=d,e[15]=u,e[16]=c):c=e[16],c},"je"),qe=m(n=>{let e=(0,O.c)(60),{span:t,traceDurationMs:a}=n,l=U(),[r,o]=(0,A.useState)(!1),d;e[0]!==t||e[1]!==a?(d=Ke(t,a),e[0]=t,e[1]=a,e[2]=d):d=e[2];let{leftPercent:i,widthPercent:u}=d,c;e[3]!==t.attributes?(c=ve(t.attributes),e[3]=t.attributes,e[4]=c):c=e[4];let v=c,$=t.depth*Be,_;e[5]!==$?(_={paddingLeft:$},e[5]=$,e[6]=_):_=e[6];let y=_,w=`${String(i)}%`,M=`${String(u)}%`,p;e[7]!==w||e[8]!==M?(p={left:w,width:M},e[7]=w,e[8]=M,e[9]=p):p=e[9];let h=p,b;e[10]===Symbol.for("react.memo_cache_sentinel")?(b=m(()=>{o(Ue)},"h"),e[10]=b):b=e[10];let C=b,S=t.depth,I=`tr-span-detail-${t.spanId}`,g;e[11]!==t.durationMs||e[12]!==t.error||e[13]!==t.name||e[14]!==t.offsetMs||e[15]!==l?(g=l("{name}, {duration}, starts {offset} in{failure}",{duration:G(t.durationMs),failure:t.error===void 0?"":l(", failed: {message}",{message:t.error.message}),name:t.name,offset:G(t.offsetMs)}),e[11]=t.durationMs,e[12]=t.error,e[13]=t.name,e[14]=t.offsetMs,e[15]=l,e[16]=g):g=e[16];let x;e[17]===Symbol.for("react.memo_cache_sentinel")?(x=te(_e,"w-full border-b border-border py-1.5 text-left font-mono text-xs hover:bg-muted/50"),e[17]=x):x=e[17];let k=`tr-span-toggle-${t.spanId}`,f;e[18]!==t.ok?(f=t.ok?null:(0,s.jsx)("span",{"aria-hidden":"true",className:"mr-1 text-destructive","data-testid":"tr-span-error",children:"\u25CF"}),e[18]=t.ok,e[19]=f):f=e[19];let N;e[20]!==y||e[21]!==t.name||e[22]!==f?(N=(0,s.jsxs)("span",{className:"truncate",style:y,title:t.name,children:[f,t.name]}),e[20]=y,e[21]=t.name,e[22]=f,e[23]=N):N=e[23];let B=t.ok?"bg-primary/70":"bg-destructive",L;e[24]!==B?(L=te("absolute inset-y-0 rounded-sm",B),e[24]=B,e[25]=L):L=e[25];let E;e[26]!==h||e[27]!==i||e[28]!==L||e[29]!==u?(E=(0,s.jsx)("span",{"aria-hidden":"true",className:"relative h-3 overflow-hidden rounded-sm bg-muted",children:(0,s.jsx)("span",{className:L,"data-left":i,"data-testid":"tr-span-bar","data-width":u,style:h})}),e[26]=h,e[27]=i,e[28]=L,e[29]=u,e[30]=E):E=e[30];let W;e[31]!==t.durationMs?(W=G(t.durationMs),e[31]=t.durationMs,e[32]=W):W=e[32];let D;e[33]!==W?(D=(0,s.jsx)("span",{className:"text-right tabular-nums text-muted-foreground",children:W}),e[33]=W,e[34]=D):D=e[34];let q;e[35]!==t.error?(q=t.error===void 0?null:(0,s.jsx)("span",{className:"text-destructive","data-testid":"tr-span-error-message",title:t.error.message,children:`${t.error.type}: ${t.error.message}`}),e[35]=t.error,e[36]=q):q=e[36];let T;e[37]!==q?(T=(0,s.jsx)("span",{className:"truncate text-muted-foreground",children:q}),e[37]=q,e[38]=T):T=e[38];let z;e[39]!==v?(z=v===""?null:(0,s.jsx)("span",{"data-testid":"tr-span-attributes",title:v,children:v}),e[39]=v,e[40]=z):z=e[40];let P;e[41]!==z?(P=(0,s.jsx)("span",{className:"truncate text-muted-foreground",children:z}),e[41]=z,e[42]=P):P=e[42];let J;e[43]!==r||e[44]!==I||e[45]!==g||e[46]!==k||e[47]!==N||e[48]!==E||e[49]!==D||e[50]!==T||e[51]!==P?(J=(0,s.jsxs)("button",{"aria-controls":I,"aria-expanded":r,"aria-label":g,className:x,"data-testid":k,onClick:C,type:"button",children:[N,E,D,T,P]}),e[43]=r,e[44]=I,e[45]=g,e[46]=k,e[47]=N,e[48]=E,e[49]=D,e[50]=T,e[51]=P,e[52]=J):J=e[52];let j;e[53]!==r||e[54]!==t?(j=r&&(0,s.jsx)("div",{id:`tr-span-detail-${t.spanId}`,children:(0,s.jsx)(Fe,{span:t})}),e[53]=r,e[54]=t,e[55]=j):j=e[55];let K;return e[56]!==t.depth||e[57]!==J||e[58]!==j?(K=(0,s.jsxs)("li",{"data-depth":S,"data-testid":"tr-span-row",children:[J,j]}),e[56]=t.depth,e[57]=J,e[58]=j,e[59]=K):K=e[59],K},"Be"),ze=m(n=>{let e=(0,O.c)(15),{durationMs:t,spans:a}=n,l=U(),r;e[0]!==t?(r=(0,s.jsx)(We,{traceDurationMs:t}),e[0]=t,e[1]=r):r=e[1];let o;e[2]!==l?(o=l("Trace waterfall"),e[2]=l,e[3]=o):o=e[3];let d;if(e[4]!==t||e[5]!==a){let c;e[7]!==t?(c=m(v=>(0,s.jsx)(qe,{span:v,traceDurationMs:t},v.spanId),"c"),e[7]=t,e[8]=c):c=e[8],d=a.map(c),e[4]=t,e[5]=a,e[6]=d}else d=e[6];let i;e[9]!==o||e[10]!==d?(i=(0,s.jsx)("ul",{"aria-label":o,children:d}),e[9]=o,e[10]=d,e[11]=i):i=e[11];let u;return e[12]!==r||e[13]!==i?(u=(0,s.jsxs)(s.Fragment,{children:[r,i]}),e[12]=r,e[13]=i,e[14]=u):u=e[14],u},"Oe");function Je(n){return(0,s.jsx)("span",{className:te("absolute inset-y-0 border-l border-border/70",n.percent===100?"-translate-x-full pr-1":"pl-1"),style:{left:`${String(n.percent)}%`},children:n.label},n.percent)}m(Je,"We");function Ue(n){return!n}m(Ue,"Ue");var Ge=m(n=>Array.isArray(n?.traces)?n.traces:[],"qe"),He=m(n=>{let e=(0,O.c)(12),{entries:t}=n,a=U(),l;e[0]!==t.length||e[1]!==a?(l=a("Logs ({count})",{count:t.length}),e[0]=t.length,e[1]=a,e[2]=l):l=e[2];let r;e[3]!==l?(r=(0,s.jsx)("p",{className:"mb-1 font-mono text-xs text-muted-foreground",children:l}),e[3]=l,e[4]=r):r=e[4];let o;e[5]!==t?(o=t.map(Ve),e[5]=t,e[6]=o):o=e[6];let d;e[7]!==o?(d=(0,s.jsx)("div",{role:"grid",children:o}),e[7]=o,e[8]=d):d=e[8];let i;return e[9]!==r||e[10]!==d?(i=(0,s.jsxs)("div",{className:"border-t border-border px-3 py-2","data-testid":"tr-logs",children:[r,d]}),e[9]=r,e[10]=d,e[11]=i):i=e[11],i},"ze"),Qe=m(n=>{let e=(0,O.c)(50),{expanded:t,logs:a,onToggle:l,trace:r}=n,o=U(),d;e[0]!==l||e[1]!==r.traceId?(d=m(()=>{l(r.traceId)},"i"),e[0]=l,e[1]=r.traceId,e[2]=d):d=e[2];let i=d,u=`tr-row-${r.traceId}`,c=`tr-waterfall-${r.traceId}`,v=`tr-toggle-${r.traceId}`,$=t?"\u25BE":"\u25B8",_;e[3]!==$?(_=(0,s.jsx)("span",{"aria-hidden":"true",className:"w-3 shrink-0 text-xs text-muted-foreground",children:$}),e[3]=$,e[4]=_):_=e[4];let y;e[5]!==r.rootName?(y=(0,s.jsx)("span",{className:"w-56 shrink-0 truncate text-sm font-medium",title:r.rootName,children:r.rootName}),e[5]=r.rootName,e[6]=y):y=e[6];let w;e[7]!==r.functionPath?(w=(0,s.jsx)("span",{className:"w-48 shrink-0 truncate font-mono text-xs text-muted-foreground",title:r.functionPath,children:r.functionPath}),e[7]=r.functionPath,e[8]=w):w=e[8];let M;e[9]!==r.durationMs?(M=G(r.durationMs),e[9]=r.durationMs,e[10]=M):M=e[10];let p;e[11]!==M?(p=(0,s.jsx)("span",{className:"w-20 shrink-0 text-right font-mono text-xs tabular-nums text-muted-foreground",children:M}),e[11]=M,e[12]=p):p=e[12];let h;e[13]!==o||e[14]!==r.spans.length?(h=o("{count} spans",{count:r.spans.length}),e[13]=o,e[14]=r.spans.length,e[15]=h):h=e[15];let b;e[16]!==h?(b=(0,s.jsx)("span",{className:"w-20 shrink-0 text-right font-mono text-xs tabular-nums text-muted-foreground",children:h}),e[16]=h,e[17]=b):b=e[17];let C=r.ok?"secondary":"destructive",S;e[18]!==o||e[19]!==r.ok?(S=r.ok?o("ok"):o("error"),e[18]=o,e[19]=r.ok,e[20]=S):S=e[20];let I;e[21]!==C||e[22]!==S?(I=(0,s.jsx)("span",{className:"shrink-0",children:(0,s.jsx)(oe,{variant:C,children:S})}),e[21]=C,e[22]=S,e[23]=I):I=e[23];let g;e[24]!==r.startTs?(g=de(r.startTs),e[24]=r.startTs,e[25]=g):g=e[25];let x;e[26]!==g?(x=(0,s.jsx)("span",{className:"flex-1 truncate text-right font-mono text-xs tabular-nums text-muted-foreground",children:g}),e[26]=g,e[27]=x):x=e[27];let k;e[28]!==t||e[29]!==i||e[30]!==p||e[31]!==b||e[32]!==I||e[33]!==x||e[34]!==c||e[35]!==v||e[36]!==_||e[37]!==y||e[38]!==w?(k=(0,s.jsxs)("button",{"aria-controls":c,"aria-expanded":t,className:"flex w-full items-center gap-3 px-3 py-2 text-left hover:bg-muted/50","data-testid":v,onClick:i,type:"button",children:[_,y,w,p,b,I,x]}),e[28]=t,e[29]=i,e[30]=p,e[31]=b,e[32]=I,e[33]=x,e[34]=c,e[35]=v,e[36]=_,e[37]=y,e[38]=w,e[39]=k):k=e[39];let f;e[40]!==t||e[41]!==a||e[42]!==r.durationMs||e[43]!==r.spans||e[44]!==r.traceId?(f=t&&(0,s.jsxs)("div",{className:"bg-muted/20","data-testid":`tr-waterfall-${r.traceId}`,id:`tr-waterfall-${r.traceId}`,children:[(0,s.jsx)(ze,{durationMs:r.durationMs,spans:r.spans}),a.length>0&&(0,s.jsx)(He,{entries:a})]}),e[40]=t,e[41]=a,e[42]=r.durationMs,e[43]=r.spans,e[44]=r.traceId,e[45]=f):f=e[45];let N;return e[46]!==k||e[47]!==f||e[48]!==u?(N=(0,s.jsxs)("div",{className:"border-b border-border last:border-b-0","data-testid":u,children:[k,f]}),e[46]=k,e[47]=f,e[48]=u,e[49]=N):N=e[49],N},"Ge"),bt=m(n=>{let e=(0,O.c)(58),{initialShardKey:t}=n,a=U(),[l]=(0,A.useState)(ye),{queryShardKey:r,setShardKey:o,shardKey:d}=be(l?.shardKey!==void 0&&l.shardKey!==""?l.shardKey:t??""),[i,u]=(0,A.useState)(l?.traceId??""),[c,v]=(0,A.useState)(!1),[$,_]=(0,A.useState)(Xe),y;e[0]===Symbol.for("react.memo_cache_sentinel")?(y=[],e[0]=y):y=e[0],(0,A.useEffect)(Ye,y);let w;e[1]===Symbol.for("react.memo_cache_sentinel")?(w={},e[1]=w):w=e[1];let M;e[2]!==r?(M={live:!0,shardKey:r},e[2]=r,e[3]=M):M=e[3];let{data:p,error:h,errorSource:b,isLoading:C,liveError:S}=ie(ce.getTraces,w,M),I;e[4]===Symbol.for("react.memo_cache_sentinel")?(I={},e[4]=I):I=e[4];let g=$.size>0,x;e[5]!==r||e[6]!==g?(x={enabled:g,live:!0,shardKey:r},e[5]=r,e[6]=g,e[7]=x):x=e[7];let{data:k}=ie(ce.getLogs,I,x),f,N;e[8]!==p||e[9]!==r?(f=m(()=>{p!==void 0&&he(r)},"p"),N=[p,r],e[8]=p,e[9]=r,e[10]=f,e[11]=N):(f=e[10],N=e[11]),(0,A.useEffect)(f,N);let B;if(e[12]!==p||e[13]!==h||e[14]!==b||e[15]!==$||e[16]!==C||e[17]!==S||e[18]!==k?.entries||e[19]!==c||e[20]!==i||e[21]!==o||e[22]!==d||e[23]!==a){let L=Ge(p),E=p?.total??L.length,W=E>L.length,D=De(L,i,c),q=Map.groupBy((k?.entries??[]).toReversed(),Ze),T;e[25]===Symbol.for("react.memo_cache_sentinel")?(T=m(F=>{u(F.target.value)},"C"),e[25]=T):T=e[25];let z=T,P;e[26]===Symbol.for("react.memo_cache_sentinel")?(P=m(F=>{_($e=>{let ne=new Set($e);return ne.has(F)?ne.delete(F):ne.add(F),ne})},"E"),e[26]=P):P=e[26];let J=P,j=h===null&&D.length===0&&!C,K;e[27]!==o||e[28]!==d?(K=(0,s.jsx)(fe,{onChange:o,testId:"tr-shard-input",value:d}),e[27]=o,e[28]=d,e[29]=K):K=e[29];let H;e[30]!==a?(H=a("Search traces"),e[30]=a,e[31]=H):H=e[31];let Q;e[32]!==a?(Q=a("search trace, span, or function"),e[32]=a,e[33]=Q):Q=e[33];let V;e[34]!==i||e[35]!==H||e[36]!==Q?(V=(0,s.jsx)(me,{"aria-label":H,className:"h-8 w-56","data-testid":"tr-search",onChange:z,placeholder:Q,value:i}),e[34]=i,e[35]=H,e[36]=Q,e[37]=V):V=e[37];let X;e[38]!==c?(X=(0,s.jsx)(xe,{checked:c,"data-testid":"tr-only-errors",id:"tr-only-errors",onCheckedChange:v}),e[38]=c,e[39]=X):X=e[39];let Y;e[40]!==a?(Y=a("Errors only"),e[40]=a,e[41]=Y):Y=e[41];let Z;e[42]!==X||e[43]!==Y?(Z=(0,s.jsxs)("label",{className:"flex items-center gap-2 text-xs text-muted-foreground",htmlFor:"tr-only-errors",children:[X,Y]}),e[42]=X,e[43]=Y,e[44]=Z):Z=e[44];let R;e[45]!==S?(R=(0,s.jsx)(Ne,{message:S,prefix:"tr"}),e[45]=S,e[46]=R):R=e[46];let re;e[47]!==K||e[48]!==V||e[49]!==Z||e[50]!==R?(re=(0,s.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[K,V,Z,R]}),e[47]=K,e[48]=V,e[49]=Z,e[50]=R,e[51]=re):re=e[51];let ae;e[52]!==h||e[53]!==b?(ae=h!==null&&(0,s.jsx)(ge,{error:b,testId:"tr-error"}),e[52]=h,e[53]=b,e[54]=ae):ae=e[54];let se;e[55]!==j||e[56]!==a?(se=j&&(0,s.jsx)(ue,{description:a("Traces recorded with ctx.trace show up here as your app handles traffic. The span buffer resets when the shard hibernates."),icon:(0,s.jsx)("svg",{"aria-hidden":"true",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.6,viewBox:"0 0 24 24",children:(0,s.jsx)("path",{d:"M4 6h10M7 12h13M10 18h7"})}),testId:"tr-empty",title:a("No traces")}),e[55]=j,e[56]=a,e[57]=se):se=e[57],B=(0,s.jsxs)("div",{className:"flex flex-col gap-4","data-testid":"lunora-traces-panel",children:[re,ae,se,h===null&&W&&(0,s.jsx)("p",{className:"text-xs text-muted-foreground","data-testid":"tr-truncated",children:a("Showing the {shown} most recent of {total} traces in the buffer.",{shown:L.length,total:E})}),h===null&&D.length>0&&(0,s.jsx)("div",{"aria-label":a("Recent traces"),className:"overflow-hidden rounded-xl border border-border shadow-xs","data-testid":"tr-list",children:D.map(F=>(0,s.jsx)(Qe,{expanded:$.has(F.traceId),logs:q.get(F.traceId)??[],onToggle:J,trace:F},F.traceId))})]}),e[12]=p,e[13]=h,e[14]=b,e[15]=$,e[16]=C,e[17]=S,e[18]=k?.entries,e[19]=c,e[20]=i,e[21]=o,e[22]=d,e[23]=a,e[24]=B}else B=e[24];return B},"bt");function Ve(n,e){return(0,s.jsx)("div",{className:"flex items-center border-b border-border py-1 font-mono text-xs last:border-b-0","data-testid":"tr-log-row",role:"row",children:(0,s.jsx)(Me,{entry:n})},`${String(e)}:${String(n.timestamp)}`)}m(Ve,"He");function Xe(){return new Set}m(Xe,"Je");function Ye(){we()}m(Ye,"Qe");function Ze(n){return n.traceId}m(Ze,"Ve");export{bt as default};
@@ -0,0 +1,15 @@
1
+ import{a}from"./chunk-I26MS5PJ.js";var r="https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-5xx-errors/",n="https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-1xxx-errors/",g=/string or blob too big/iu,l={BAD_REQUEST:{status:400,title:"Bad request"},UNAUTHORIZED:{status:401,title:"Unauthorized"},FORBIDDEN:{status:403,title:"Forbidden"},NOT_FOUND:{status:404,title:"Not found"},CONFLICT:{hint:["Another write changed this row while your mutation was running (optimistic concurrency conflict).","","Re-read the row and retry the mutation with the fresh value. Lunora serializes a DO's mutations, so a persistent conflict usually means the handler conflicts **with itself** (e.g. a trigger or cascade touching the same row) \u2014 split that work rather than adding a retry loop."],status:409,title:"Conflict"},NOT_UNIQUE:{hint:["`.unique()` matched more than one document \u2014 it expects the query to identify at most one row.","","- If several matches are legitimate, use `.first()` (take one) or `.collect()` (take all) instead.","- Otherwise tighten the query (e.g. filter on a unique/indexed field) so it can only match one row."],status:400,title:"Query matched more than one document"},VALIDATION_ERROR:{status:400,title:"Validation failed"},TOO_MANY_REQUESTS:{status:429,title:"Too many requests"},UNPROCESSABLE:{status:422,title:"Unprocessable"},NOT_IMPLEMENTED:{status:501,title:"Not implemented"},FUNCTION_NOT_FOUND:{status:404,title:"Function not found"},METHOD_NOT_ALLOWED:{status:405,title:"Method not allowed"},PAYLOAD_TOO_LARGE:{status:413,title:"Payload too large"},INTERNAL:{internal:!0,status:500,title:"Internal error"},INTERNAL_SERVER_ERROR:{internal:!0,status:500,title:"Internal error"},RPC_FAILED:{internal:!0,status:500,title:"Internal error"},COUNT_RLS_UNSUPPORTED:{status:422,title:"count() is unsupported under an RLS policy"},MASK_UNSUPPORTED:{status:422,title:"Aggregation over a masked column is unsupported"},RELATION_PREDICATE_UNSUPPORTED:{status:422,title:"Relation predicate is unsupported in a write policy"},RLS_REQUIRED:{hint:["This table is secure-by-default: it has no `.public()` marker and no RLS policy resolved for the caller, so the read fails closed.","","Add a read policy with `.rls(...)`, or mark the table `.public()` if it is intentionally world-readable."],status:403,title:"RLS policy required"},RUN_DEPTH_EXCEEDED:{internal:!0,status:500,title:"Run depth exceeded"},RUN_KIND_FORBIDDEN:{status:500,title:"Function kind may not be composed from a query"},TRANSACTION_LIMIT_EXCEEDED:{hint:["A single mutation may only read and write a bounded amount before it is stopped.","","Narrow the read with an index (`.withIndex(...)`) instead of scanning the table, or split the write across several mutations \u2014 for a large backfill use `defineMigration` + `lunora migrate up`, which batches and checkpoints for you.","","The ceilings are deliberately conservative \u2014 they exist to stop one request taking down the whole shard. A deployment that genuinely needs bigger transactions can raise them by overriding the `transactionLimits()` seam on its generated shard class."],status:413,title:"Transaction limit exceeded"},MIGRATION_NOT_FOUND:{status:404,title:"Data migration not found"},MIGRATION_DRIFT:{hint:["An applied SQL migration is never re-run, so the runner stopped before applying anything.","","- **Its text changed after it ran:** revert the edit and put the change in a new migration. If the edit is inert (a comment, whitespace, line endings), record the new hash with the `UPDATE` the message prints.","- **Tracking rows predate versions and match no migration:** set each row's `version` with the `UPDATE` the message prints, so the runner can tell what already ran."],status:409,title:"Migration drift"},UNKNOWN_TABLE:{status:404,title:"Unknown table"},GLOBAL_TABLE_NOT_EDITABLE:{status:400,title:"Global table is not editable"},SHARD_ERROR:{status:503,title:"Shard error"},SHARD_UNAVAILABLE:{status:503,title:"Shard unavailable"},SHARD_TIMEOUT:{status:504,title:"Shard timeout"},SHARD_HTTP_ERROR:{status:502,title:"Shard HTTP error"},SUBSCRIPTION_PERSIST_FAILED:{status:500,title:"Subscription persist failed"},TOO_MANY_SUBSCRIPTIONS:{status:429,title:"Too many subscriptions"},OFFLINE_IDENTITY_CHANGED:{status:409,title:"Offline identity changed"},IDENTITY_MISMATCH:{hint:["A write queued offline was replayed on a session that now belongs to someone else (a sign-out, or another user's sign-in, while it waited), so the worker refused it rather than commit it as them.","","`@lunora/client` re-resolves the session on this refusal and settles the write itself. If every replay is refused while the same user stays signed in, your worker's `resolveIdentity` returns a different `userId` than better-auth's `user.id`, or the RPC request carries no session cookie."],status:409,title:"Session changed since the write was queued"},CODEGEN_DIAGNOSTIC:{status:500,title:"Codegen diagnostic"},JURISDICTION_MOVE:{hint:["The schema declares `.jurisdiction(...)` and the project has DO-backed auth (`.auth({ namespace })`). Pinning the auth object to the jurisdiction resolves it to a new, empty one: every user, account and session stays in the unpinned object until copied across. Voice sessions are pinned without an acknowledgement: they store nothing, and their transcripts are rows in the already-pinned shards.","",'Acknowledge with `.jurisdiction("eu", { pinAuth: true })` and deploy, then copy the auth tables across with the `__lunora_admin__:copyAuthToJurisdiction` admin op and, once the counts check out, purge the unpinned copy with `__lunora_admin__:purgeUnpinnedAuth` (see [Pinning auth and voice](/docs/concepts/data-residency#pinning-auth-and-voice)). For D1-mode auth the acknowledgement changes nothing.'],status:422,title:"Unacknowledged jurisdiction move"},SCHEMA_SNAPSHOT_PARSE:{status:500,title:"Schema snapshot parse error"},ENV_INVALID:{internal:!0,status:500,title:"Invalid environment"},X402_FACILITATOR_ERROR:{internal:!0,status:502,title:"Payment facilitator error"},AUTH_HEADERS_MISSING:{internal:!0,status:500,title:"Auth headers missing"},PRIVACY_COVERAGE:{status:500,title:"Privacy coverage check failed"},PRIVACY_REQUEST_OPEN:{status:409,title:"A privacy request is already open"},PRIVACY_SESSION_NOT_FRESH:{status:403,title:"Recent sign-in required"},EMAIL_DOMAIN_BLOCKED:{hint:["This address's domain is on the disposable/throwaway blocklist (or your configured deny-list).","","Sign up with a permanent mailbox. To tune the policy, pass `blockDisposable` / `allowDomains` / `denyDomains` in the `EmailGateConfig` you hand `assertEmailAllowed` / `classifyEmail` / `emailGateMiddleware` (`@lunora/auth/email-guard`)."],status:400,title:"Email domain not allowed"},EMAIL_UNDELIVERABLE:{hint:["The address's domain publishes no MX (or fallback A/AAAA) records, so it can't receive mail.","","Check for a typo in the domain. MX verification is opt-in (`mx: true`) and needs DNS \u2014 leave it off on the edge path if DNS is unavailable."],status:400,title:"Email domain cannot receive mail"},ANALYTICS_SQL_QUERY_ERROR:{status:502,title:"Analytics SQL query error"},BROWSER_RUN_ERROR:{status:502,title:"Browser Run API error"},BROWSER_TOO_MANY_REDIRECTS:{status:502,title:"Too many redirects"},R2_SQL_ERROR:{status:502,title:"R2 SQL API error"},WORKFLOWS_REST_ERROR:{status:502,title:"Cloudflare Workflows REST API error"},CONFIG_INVALID:{internal:!0,status:500,title:"Payment configuration invalid"},CURRENCY_MISMATCH:{status:400,title:"Currency mismatch"},PROVIDER_ERROR:{status:502,title:"Payment provider error"},WEBHOOK_EVENT_ID_MISSING:{status:400,title:"Webhook event id missing"},WEBHOOK_SIGNATURE_INVALID:{status:400,title:"Webhook signature invalid"},WEBHOOK_TIMESTAMP_INVALID:{status:400,title:"Webhook timestamp outside tolerance"},ADMIN_FORBIDDEN:{status:403,title:"Admin access forbidden"},ADMIN_TOKEN_NOT_CONFIGURED:{status:400,title:"Admin token not configured"},AUTH_MIGRATOR_UNSUPPORTED:{hint:["better-auth migrates only through its Kysely adapter, so `ensureMigrated` / `compileMigrationsSql` need the raw D1 binding as `database` \u2014 a custom adapter (`lunoraD1Adapter`, `lunoraAuthAdapter`, `lunoraDoAdapter`) cannot be migrated through, and neither can an absent `database`.","","Build a SECOND, migration-only instance over the raw binding \u2014 `createMigrationAuth({ ...options, database: env.DB })` (from `@lunora/auth/migrate`) \u2014 and hand that one to `ensureMigrated`. Keep the adapter on the instance that serves requests: the adapter exists to dodge a dev-runner hang in `$context`, which the migration instance never resolves.","","To compile the SQL off-platform (`compileMigrationsSql`), diff against an empty local database \u2014 `new DatabaseSync(':memory:')` from `node:sqlite` \u2014 rather than passing no `database` at all."],status:500,title:"Auth migrator cannot drive the configured database"},AUTH_NOT_CONFIGURED:{status:400,title:"Auth admin not configured"},AUTH_OP_NOT_SUPPORTED:{status:400,title:"Auth admin operation not supported"},AUTH_CIMD_FETCH_NOT_PUBLIC:{hint:'Add "global_fetch_strictly_public" to "compatibility_flags" in wrangler.jsonc, so CIMD metadata fetches cannot reach private addresses. `lunora doctor` reports it as `cimd-fetch-not-strictly-public`.',status:500,title:"CIMD transport needs the global_fetch_strictly_public flag"},AUTH_MCP_RESOURCE_AMBIGUOUS:{hint:'Use `mcp` from "@lunora/auth/plugins" (not `@better-auth/mcp`) and pass the plugin object as is: it records its `resource`, which the worker needs to serve the protected-resource metadata when the provider names several resources.',status:500,title:"MCP resource cannot be told apart from the provider's other resources"},AUTH_MCP_RESOURCE_INVALID:{hint:"Pass `resource` to `requireMcpAuth` (and `mcp()`) as the absolute URL of the MCP route, e.g. `https://app.example.com/mcp`: issued tokens are audience-bound to it.",status:500,title:"MCP resource missing or not an absolute URL"},MCP_STEP_UP_MISCONFIGURED:{hint:"Give `createAuthedMcpFetchHandler`'s `stepUp` a non-empty `scope` (such as `lunora:write`) and a `challenge` (`createInsufficientScopeError` from `@lunora/auth/plugins`), or leave `stepUp` out.",status:500,title:"MCP step-up misconfigured"},BACKUP_NOT_CONFIGURED:{status:500,title:"Scheduled backup not configured"},BACKUP_RETENTION_NOT_CONFIGURED:{hint:["`lunora backup prune` removes snapshots past the retention window, and this worker has no window: set `backupRetain` (how many to keep) and `backupCron` (which decides whose snapshots retention owns) on `createWorker`.","","Nothing was deleted. A default is deliberately not invented here \u2014 retention deleting on its own is exactly what this command exists to replace."],status:400,title:"Backup retention window not configured"},BACKUP_TOO_LARGE:{hint:["The scheduled backup is assembled inside the Worker isolate, so it caps the snapshot it will build. Nothing was written.","","The cap is on the NDJSON, not on peak memory: the export fan-out resolves every shard's rows before the first row is encoded, so a snapshot under the cap can still exhaust the isolate. It is set well below the isolate's limit for that reason.","","Narrow the snapshot with `backupTables`, or take this backup off-platform with `lunora backup create --bucket`, which runs on a machine rather than in an isolate. Backing up more often does not help \u2014 every run is a full snapshot."],status:507,title:"Backup too large to assemble in a Worker"},CRON_JOBS_NOT_CONFIGURED:{status:400,title:"Cron jobs not configured"},CRON_JOB_NOT_FOUND:{status:404,title:"Cron job not found"},EXPORT_SHARD_FAILED:{hint:["One or more shards failed to export, so the snapshot would have been short. Nothing is written when this fires \u2014 a partial export must never be mistaken for a complete one.","","The message names each failed shard key and its error. Re-run the export once those shards are reachable; a shard that fails repeatedly is usually over the per-request memory budget, which `backupTables` narrows."],status:502,title:"Export failed on one or more shards"},EXPORT_TAP_NOT_CONFIGURED:{status:400,title:"Export tap not configured"},FUNCTIONS_NOT_CONFIGURED:{status:400,title:"Functions registry not configured"},GLOBALS_NOT_CONFIGURED:{status:400,title:"Global-table introspector not configured"},ID_COLLISION:{hint:["The imported row carries an `_id` that is already held by a DIFFERENT table in this shard. Ids are per-table, so inserting it would leave two tables claiming one id and make a later lookup resolve to whichever one it reached first.","","This is reported per row rather than aborting the import: the remaining rows still apply. Re-mint the id on the source side, or import that table into a shard that does not already hold it."],status:409,title:"Document id already belongs to another table"},KV_NOT_CONFIGURED:{status:400,title:"KV introspector not configured"},MIGRATION_ID_REQUIRED:{status:400,title:"Migration id required"},PITR_UNAVAILABLE:{status:409,title:"Point-in-time recovery unavailable"},SCHEDULER_NOT_CONFIGURED:{status:400,title:"Scheduler not configured"},STORAGE_CHECKSUM_MISMATCH:{hint:["The upload body did not match the declared `expectedSize` or `expectedSha256`, so nothing was written \u2014 this check fails closed.","","Re-read the bytes from the source export and retry the transfer. A persistent mismatch means the source blob is corrupt or truncated; fix the export rather than bypassing the check."],status:400,title:"Storage checksum mismatch"},STORAGE_DELETE_NOT_CONFIGURED:{status:400,title:"Storage delete not configured"},STORAGE_DOWNLOAD_NOT_CONFIGURED:{hint:["`GET /_lunora/admin/storage/object` needs a `storageDownload` function on the worker. The generated app worker wires it up; a hand-written `createWorker({ ... })` has to pass `(key, opts) => pick(opts?.bucket).download(key)` \u2014 forwarding `opts.bucket` to the right bucket, and wrapping rather than passing `createStorage(...).download` itself, whose second parameter is a byte range.","","Without it a bucket-backed `lunora backup restore --bucket` cannot read the snapshot. The object is still readable out of band with `wrangler r2 object get`."],status:400,title:"Storage download not configured"},STORAGE_NOT_CONFIGURED:{status:400,title:"Storage not configured"},STORAGE_OBJECT_NOT_FOUND:{status:404,title:"Storage object not found"},STORAGE_UPLOAD_NOT_CONFIGURED:{status:400,title:"Storage upload not configured"},STORAGE_URL_NOT_CONFIGURED:{status:400,title:"Storage signed URL not configured"},RAG_DIMENSION_MISMATCH:{hint:["A stored vector and the query embedding have different widths, so they cannot be compared.","","This is what changing a RAG index's `embeddingModel` (or a provider's `dimensions` option) without reindexing looks like. Either put the previous model back, or reindex the namespace under the new one \u2014 bump `embeddingModelVersion` so the index rebuilds instead of mixing widths."],status:409,title:"Embedding dimension mismatch"},VECTORS_NOT_CONFIGURED:{status:400,title:"Vector index introspector not configured"},VECTOR_QUERY_UNSUPPORTED:{status:400,title:"Vector index querying not enabled"},WORKFLOWS_NOT_CONFIGURED:{status:501,title:"Workflows not configured"},AUTH_AUDIT_NOT_CONFIGURED:{status:400,title:"Auth audit reader not configured"},AUTH_AUDIT_READ_FAILED:{internal:!0,status:500,title:"Auth audit read failed"},AUTH_MOVE_NOT_CONFIGURED:{hint:"The copy needs DO-backed auth (`.auth({ namespace })`) pinned with `.jurisdiction(\u2026, { pinAuth: true })`, and the auth object's `internalSecret` set.",status:400,title:"Auth jurisdiction move not configured"},AUTH_MOVE_TARGET_NOT_EMPTY:{hint:"The pinned auth object holds users the copy did not write (someone signed up there), so copying into it would merge two user bases. Pass `force: true` to copy anyway: a copied row that collides with one of the pinned object's rows is left out and counted under `conflicts`.",status:409,title:"Pinned auth object is not empty"},AUTH_MOVE_CONFLICT:{hint:"A copied row has the same key or unique value (such as an email) as a row the pinned auth object holds on its own, or the pinned object changed a row the source changed too. Nothing from that page was written. Pass `force: true` to keep the pinned object's rows and count the collisions under `conflicts`.",status:409,title:"Auth copy conflict"},AUTH_MOVE_SOURCE_CHANGED:{hint:"The un-pinned auth object changed after the copy read it (an update, a delete, or a new row), for example during a gradual rollout or a rollback. Run the copy again: it reconciles the changed tables. Then purge.",status:409,title:"Un-pinned auth object changed since the copy"},AUTH_MOVE_SOURCE_PURGED:{hint:"The un-pinned auth object was already purged. Its tables may exist again (a rollback served requests there), but they hold only rows written since, so the copy refuses rather than read them as deletions and remove the pinned object's users. Nothing is left to copy.",status:409,title:"Un-pinned auth object already purged"},AUTH_MOVE_INCOMPLETE:{hint:"Run `__lunora_admin__:copyAuthToJurisdiction` until it answers `done: true`, check the per-table counts, then purge.",status:409,title:"Auth copy not finished"},AUTH_MOVE_FAILED:{hint:"The message names the step, the table and the class of the SQLite error; the auth object's log has the full error. The copy resumes where it stopped once the cause is fixed.",status:500,title:"Auth jurisdiction move failed"},CRON_EXPR_INVALID:{status:500,title:"Invalid cron expression"},CRON_EXPR_NOT_STATIC:{status:500,title:"Cron expression is not statically analyzable"},CRON_JOB_FAILED:{internal:!0,status:500,title:"Cron job failed"},CRON_NAME_NOT_STATIC:{status:500,title:"Cron job name is not statically analyzable"},CRON_NON_STATIC_FN:{status:500,title:"Cron function reference is not statically analyzable"},CRON_NON_STATIC_VALUE:{status:500,title:"Cron value is not statically analyzable"},CRON_SCHEDULE_INVALID:{status:500,title:"Invalid cron schedule"},CRON_SCHEDULE_NOT_STATIC:{status:500,title:"Cron schedule is not statically analyzable"},DUPLICATE_CRON_NAME:{status:500,title:"Duplicate cron job name"},DUPLICATE_AGENT_CLASS:{status:500,title:"Duplicate agent generated class name"},DUPLICATE_AGENT_NAME:{status:500,title:"Duplicate agent name"},DUPLICATE_MIGRATION_ID:{status:500,title:"Duplicate migration id"},DUPLICATE_QUEUE_BINDING:{status:500,title:"Duplicate queue binding"},DUPLICATE_QUEUE_NAME:{status:500,title:"Duplicate queue name"},DUPLICATE_WORKFLOW_CLASS:{status:500,title:"Duplicate workflow generated class name"},MIGRATION_ID_NOT_STATIC:{status:500,title:"Migration id is not statically analyzable"},NAMESPACE_COLLISION:{status:500,title:"Function namespace collision"},BAD_ROW:{status:400,title:"Malformed import row"},BAD_SUBSCRIPTION_ARGS:{status:400,title:"Invalid subscription arguments"},BATCH_LIMIT_EXCEEDED:{status:400,title:"Batch limit exceeded"},CROSS_SHARD_RANK_UNSUPPORTED:{status:400,title:"Cross-shard rank() is unsupported"},DISPATCH_UNAUTHENTICATED:{hint:"The scheduler could not authenticate to the worker. Check that `LUNORA_SCHEDULER_SECRET` matches on both sides, or that `LUNORA_ADMIN_TOKEN` is set and current.",status:403,title:"Dispatch caller not authenticated"},DISPATCH_IN_PROGRESS:{hint:"A dispatch with this idempotency id is still running on the shard. Retry it; once the first attempt settles the same id is served from the replay cache.",status:409,title:"Dispatch already in progress"},FORBIDDEN_FANOUT:{status:403,title:"Fan-out forbidden"},GLOBAL_SEARCH_SCORES_UNSUPPORTED:{status:400,title:"collectWithScores() is unsupported on a global table"},FORBIDDEN_ORIGIN:{status:403,title:"Origin forbidden"},FORBIDDEN_SHARD:{status:403,title:"Shard access forbidden"},GLOBAL_NOT_CONFIGURED:{status:400,title:"Global table import not configured"},INVALID_INPUT:{status:400,title:"Invalid input"},INVALID_SCHEDULE_ID:{status:400,title:"Invalid schedule id"},RATE_LIMITED:{status:429,title:"Rate limited"},REPLICA_NOT_READY:{status:421,title:"Replica not caught up"},REPLICA_READ_ONLY:{status:421,title:"Replica is read-only"},SEARCH_INDEX_BUILDING:{status:503,title:"Search index is still building"},SERVICE_UNAVAILABLE:{status:503,title:"Service unavailable"},SHAPE_MEMORY_TABLE:{status:400,title:"Shape over a memory table is unsupported"},SHAPE_CROSS_SHARD_JOIN:{status:400,title:"Shape cross-shard join is unsupported"},SHAPE_RELATION_PREDICATE:{status:400,title:"Shape filtered by a relation is unsupported"},UNAUTHENTICATED:{status:401,title:"Unauthenticated"},WIRE_DECODE_FAILED:{status:502,title:"Could not decode a server frame"},WIRE_ENCODE_FAILED:{status:500,title:"Could not encode a return value"},UNKNOWN_COLUMN:{status:404,title:"Unknown column"},CDC_LOG_TRIMMED:{status:409,title:"CDC log trimmed"},CDC_TIMELINE_FORKED:{status:409,title:"CDC timeline forked"},CDC_PAYLOAD_COMPACTED:{status:409,title:"CDC payloads compacted"},EXPIRED:{status:404,title:"Session expired"},NESTED_TRANSACTION:{internal:!0,status:500,title:"Nested transaction"},OUT_OF_ORDER:{status:409,title:"Out-of-order mutation"},SHAPE_GLOBAL_TOO_LARGE:{status:413,title:"Global shape too large"},SHAPE_NOT_FOUND:{status:404,title:"Shape not found"},SHAPE_REQUIRES_CDC:{status:409,title:"Shape requires change-data-capture"},SQL_UNAVAILABLE:{internal:!0,status:500,title:"SQL storage unavailable"},STREAM_ID_IN_USE:{status:409,title:"Stream id already in use"},STREAM_INTERRUPTED:{status:503,title:"Durable stream interrupted"},STREAM_TOO_LONG:{status:507,title:"Durable stream exceeded its chunk ceiling"},TOKEN_EXPIRED:{hint:["The caller's credential verified but its expiry has passed. The worker refuses an HTTP call with this code before it runs; a shard drops a socket with close code `4001` and the same code.","","It is a refusal of the credential, not of the call: `@lunora/client` holds a queued write, fires `onTokenExpired`, and re-sends it after `setAuthToken`. The held write survives the refresh only if you pass the same `subject` (the user id) with the new token, `setAuthToken(freshToken, user.id)`; without one a refresh reads as a user switch and the write is rejected `OFFLINE_IDENTITY_CHANGED`. Under a cookie session there is no token to replace: renew the cookie and the write is re-sent on a backoff. The worker can only tell expired from anonymous if your `resolveIdentity` returns the identity with its past `exp` (or `expiresAtMs`), or throws a `LunoraError` with this code. Returning `null` runs the call anonymous."],status:401,title:"Authentication token expired"},TOO_MANY_STREAMS:{status:429,title:"Too many streams"},TOO_MANY_WHISPER_TOPICS:{hint:"Reuse a stable set of whisper topic names, or reconnect \u2014 the per-socket verdict memo is in-memory, so a new connection starts empty. Leaving a topic does not free its entry.",status:429,title:"Too many whisper topics"},UNKNOWN_ADMIN_OP:{status:404,title:"Unknown admin operation"},SOCKET_TAG_BUDGET_EXCEEDED:{status:400,title:"Socket tag budget exceeded"},RELAY_CANNOT_SEED:{status:500,title:"Relay cannot seed"},RELAY_MISCONFIGURED:{status:500,title:"Relay misconfigured"},RELAY_SEED_FAILED:{status:502,title:"Relay seed failed"},RELAY_SHAPE_UNROUTABLE:{status:500,title:"Relay shape unroutable"},MISCONFIGURED:{internal:!0,status:500,title:"Worker misconfigured"},LUNORA_RUNTIME_UNAVAILABLE:{status:500,title:"Lunora runtime unavailable"},INTERNAL_ERROR:{internal:!0,status:500,title:"Internal error"},BROWSER_TIMEOUT:{status:504,title:"Browser operation timed out"},CLIENT_CLOSED:{status:400,title:"Client is closed"},HTTP_STREAM_BAD_CHUNK:{status:502,title:"Malformed HTTP stream chunk"},HTTP_STREAM_INTERRUPTED:{status:502,title:"HTTP stream interrupted"},HTTP_STREAM_MISSING_PARAM:{status:400,title:"HTTP stream missing path parameter"},HTTP_STREAM_NO_BODY:{status:502,title:"HTTP stream response has no body"},HTTP_STREAM_STATUS:{status:502,title:"HTTP stream request failed"},HTTP_STREAM_TRANSPORT:{status:502,title:"HTTP stream transport error"},STREAM_BACKPRESSURE:{status:429,title:"Stream backpressure"},STREAM_DISCONNECTED:{status:503,title:"Stream disconnected"},STREAM_QUEUE_OVERFLOW:{status:429,title:"Stream queue overflow"},UNKNOWN_MUTATION_FN:{status:404,title:"Unknown mutation function"},LOCAL_DEPENDENCY_MISSING:{hint:["The command Lunora tried to run is not on your PATH, so nothing ran.","","Install it (or put it on PATH) and retry \u2014 `wrangler` ships as a dependency of a Lunora app, so `pnpm install` usually fixes that one; `git` and `docker` are installed separately."],status:500,title:"Required local tool not found"}},c=a(e=>Object.hasOwn(l,e)?l[e]:void 0,"h");var m=[{body:["A single row exceeded the storage engine's per-row ceiling \u2014 2 MB on a Durable Object's SQLite, and 2,000,000 bytes on D1.","","The limit is on the STORED bytes, which are UTF-8: a document of multi-byte text (CJK, emoji) costs up to 3x its character count. `v.bytes()` and `v.bigint()` columns cost more again on a shard-local table, where the row stores both a SQL-comparable projection and the original.","","Keep the large payload out of the row and store a reference to it:","","```ts","const key = `uploads/${crypto.randomUUID()}`;","await ctx.storage.uploads.put(key, bytes);",'await ctx.db.insert("documents", { storageKey: key, title });',"```","","R2 has no practical object-size ceiling, and the row stays small enough to read, index, and replicate."].join(`
2
+ `),header:"Row too large for the storage engine",id:"lunora-row-too-big",test:a(e=>g.test(e),"test")},{body:["Lunora codegen couldn't find a schema to generate from.","","Create `lunora/schema.ts` exporting a `defineSchema(...)` call:","","```ts",'import { defineSchema, defineTable, v } from "@lunora/server";',"","export default defineSchema({"," messages: defineTable({ body: v.string() }),","});","```","","Or run `lunora init` to scaffold Lunora (a sample `lunora/schema.ts` included) into your app."].join(`
3
+ `),header:"No Lunora schema found",id:"lunora-schema-missing",test:a(e=>e.includes("defineSchema() not found")||e.includes("schema.ts not found at"),"test")},{body:["`defineSchema(...)` must be called with an **inline object literal** mapping table names to `defineTable(...)`:","","```ts","export default defineSchema({"," todos: defineTable({ title: v.string(), done: v.boolean() }),","});","```","","Codegen reads the schema statically, so it can't follow a variable or a spread \u2014 pass the object literal directly."].join(`
4
+ `),header:"`defineSchema()` needs an inline object literal",id:"lunora-schema-not-object-literal",test:a(e=>e.includes("defineSchema() expects an object literal"),"test")},{body:["This table name collides with a built-in `ctx.db` member, so the generated client can't expose it.","","Rename the table to anything that isn't a `ctx.db` member (the error names the one it hit) \u2014 e.g. `userAccounts` instead of `insert`, or `pageViews` instead of `count`."].join(`
5
+ `),header:"Table name is reserved",id:"lunora-table-reserved",test:a(e=>e.includes("is reserved")&&e.includes("ctx.db"),"test")},{body:["Two tables resolve to the same name \u2014 usually a base table and a schema **extension** both defining it.","","Rename one of them, or drop the duplicate from the extension. Each table name must be unique across `defineSchema(...)` and every `.extend(...)`."].join(`
6
+ `),header:"Duplicate table name",id:"lunora-table-duplicate",test:a(e=>e.includes("already exists")&&e.includes(".extend("),"test")},{body:['`.jurisdiction(...)` accepts only a **string literal** of `"eu"`, `"us"`, or `"fedramp"`:',"","```ts",'defineSchema({ /* \u2026 */ }).jurisdiction("eu");',"```"].join(`
7
+ `),header:"Invalid `.jurisdiction(...)` value",id:"lunora-jurisdiction",test:a(e=>e.includes("unknown jurisdiction")||e.includes("jurisdiction")&&e.includes('"eu", "us", or "fedramp"'),"test")},{body:["The `unique` flag on an index must be a **literal** `true` or `false`, not a computed value \u2014 codegen needs to read it statically:","","```ts",'defineTable({ email: v.string() }).index("by_email", ["email"], { unique: true });',"```"].join(`
8
+ `),header:"`unique` must be a literal",id:"lunora-unique-literal",test:a(e=>e.includes("must be a literal")&&e.includes("unique"),"test")},{body:["A declared container/workflow class isn't re-exported by your worker entry, so `wrangler deploy` would reject it.","","Add the generated re-export shown in the error to your worker entry (e.g. `src/index.ts`):","","```ts",'export * from "./lunora/_generated/containers";',"```"].join(`
9
+ `),header:"Binding not exported by your worker entry",id:"lunora-worker-entry-export-gap",test:a(e=>e.includes("not exported by your worker entry"),"test")},{body:["A row with the same value already exists in a `unique` index.","","- If you meant to upsert, use `ctx.db.<table>().upsert(...)` (or `.patch(...)` an existing row) instead of `.insert(...)`.",`- Otherwise pick a value that isn't already taken, and consider surfacing a friendly "already exists" message to the user.`].join(`
10
+ `),header:"Unique constraint violation",id:"lunora-runtime-unique",test:a(e=>e.includes("unique constraint violation on"),"test")},{body:l.CONFLICT.hint.join(`
11
+ `),header:"Optimistic concurrency conflict",id:"lunora-runtime-occ",test:a(e=>e.includes("optimistic concurrency conflict"),"test")}],d=[{causes:"the origin returned an empty, unknown, or malformed response Cloudflare couldn't interpret (often an origin crash or an oversized response header)",code:"520",docsUrl:r,family:"5xx",fix:"check your origin's logs for a crash, ensure it returns a valid HTTP response, and keep response headers under the size limit",summary:"Cloudflare got an unknown/empty response from your origin web server.",title:"Web server returns an unknown error"},{causes:"the origin refused the connection \u2014 the web server is down, or a firewall is blocking Cloudflare's IP ranges",code:"521",docsUrl:r,family:"5xx",fix:"confirm the origin process is running and allowlist Cloudflare's published IP ranges in your firewall/security groups",summary:"Cloudflare could not connect to your origin because it refused the connection.",title:"Web server is down"},{causes:"Cloudflare could not establish a TCP connection to the origin in time \u2014 the origin is overloaded, a firewall is dropping packets, or the origin IP is wrong",code:"522",docsUrl:r,family:"5xx",fix:"verify the origin is reachable and not overloaded, and that the DNS record points at the correct origin IP",summary:"The connection to your origin timed out before it was established.",title:"Connection timed out"},{causes:"Cloudflare cannot route to the origin at all \u2014 a bad DNS record, an origin IP that changed, or invalid routing",code:"523",docsUrl:r,family:"5xx",fix:"verify the DNS A/AAAA record points at a reachable origin IP and that no upstream network is blocking Cloudflare",summary:"Cloudflare could not reach your origin server.",title:"Origin is unreachable"},{causes:"Cloudflare made a TCP connection but the origin did not return an HTTP response within 100 seconds \u2014 a slow handler or long-running request",code:"524",docsUrl:r,family:"5xx",fix:"speed up the slow origin handler, or move long work off the request path into a background job (a Durable Object, Queue, or Workflow)",summary:"Cloudflare connected to your origin but it did not respond in time.",title:"A timeout occurred"},{causes:"the TLS handshake between Cloudflare and the origin failed \u2014 a missing/invalid origin certificate, or a cipher/SNI mismatch under Full (Strict) SSL",code:"525",docsUrl:r,family:"5xx",fix:"install a valid certificate on the origin and align your Cloudflare SSL/TLS mode with the origin's certificate setup",summary:"The SSL handshake with your origin failed.",title:"SSL handshake failed"},{causes:"Cloudflare could not validate the origin's certificate under Full (Strict) SSL \u2014 it is expired, self-signed, or issued for the wrong hostname",code:"526",docsUrl:r,family:"5xx",fix:"install a valid, publicly-trusted certificate on the origin (or use a Cloudflare Origin CA cert), matching the request hostname",summary:"Cloudflare could not validate your origin's SSL certificate.",title:"Invalid SSL certificate"},{causes:"a DNS record points at a Cloudflare IP or another prohibited address instead of your real origin",code:"1000",docsUrl:n,family:"1xxx",fix:"point the DNS record at your real origin IP, not a Cloudflare-owned or loopback address",summary:"DNS points to a prohibited IP.",title:"DNS points to prohibited IP"},{causes:"Cloudflare could not resolve the requested hostname \u2014 a Worker fetched an unresolvable host, or a DNS record is misconfigured",code:"1001",docsUrl:n,family:"1xxx",fix:"check the hostname you're requesting and the DNS records for the zone resolve to a valid origin",summary:"Cloudflare could not resolve the origin DNS.",title:"DNS resolution error"},{causes:"a Worker or DNS record targets a restricted IP (for example a Cloudflare-owned or loopback address)",code:"1002",docsUrl:n,family:"1xxx",fix:"change the Worker fetch target or DNS record to a valid, non-restricted origin address",summary:"DNS points to a prohibited IP (Worker/restricted).",title:"DNS points to a prohibited IP"},{causes:"the visitor's IP was blocked by an IP Access Rule, WAF rule, or security configuration on the zone",code:"1006",docsUrl:n,family:"1xxx",fix:"review the zone's Firewall/WAF and IP Access Rules to see why the address was banned, and adjust if it was blocked in error",summary:"Access denied: the visitor's IP has been banned.",title:"Access denied: your IP has been banned"},{causes:"your Worker threw an unhandled JavaScript exception during the request",code:"1101",docsUrl:n,family:"1xxx",fix:"reproduce with `wrangler tail` (or the Workers Logs / Studio Logs panel) to get the stack trace, then handle the throwing code path",summary:"A Worker threw a JavaScript exception.",title:"Worker threw a JavaScript exception"},{causes:"the Worker used more CPU time than a single invocation is allowed \u2014 usually a hot loop or heavy synchronous work",code:"1102",docsUrl:n,family:"1xxx",fix:"reduce per-request CPU (optimize hot loops, avoid heavy synchronous work) or offload the heavy work to a Durable Object, Queue, or Workflow",summary:"A Worker exceeded its CPU-time resource limit.",title:"Worker exceeded resource limits"}],u=a(e=>e!==void 0&&e>="0"&&e<="9","l"),T=a((e,t)=>{for(let o=e.indexOf(t);o!==-1;o=e.indexOf(t,o+t.length))if(!u(e[o-1])&&!u(e[o+t.length]))return!0;return!1},"_"),A=a((e,t)=>{for(let o of[`error ${t}`,`error: ${t}`])for(let i=e.indexOf(o);i!==-1;i=e.indexOf(o,i+o.length))if(!u(e[i+o.length]))return!0;return!1},"f"),O=/error|cloudflare/iu,p=a(e=>({body:[e.summary,"",`**Likely cause:** ${e.causes}.`,"",`**Fix:** ${e.fix}.`,"",`See [Cloudflare's ${e.family} error docs](${e.docsUrl}).`].join(`
12
+ `),header:`Cloudflare Error ${e.code}: ${e.title}`,id:`cloudflare-error-${e.code}`}),"c"),f=a(e=>{if(!O.test(e))return;let t=e.toLowerCase(),o=t.includes("error"),i=t.includes("cloudflare");if(o){for(let s of d)if(A(t,s.code))return p(s)}if(i){for(let s of d)if(T(t,s.code))return p(s)}},"T"),b=a(e=>(typeof e=="string"?e:e.join(`
13
+ `)).split(`
14
+ `).filter(t=>!t.startsWith("```")).join(`
15
+ `).replaceAll(/\*\*(.+?)\*\*/gu,"$1").replaceAll(/`([^`]+)`/gu,"$1"),"A"),_=a(e=>{for(let t of m)if(t.test(e))return{body:t.body,header:t.header,id:t.id}},"d"),R=a(e=>_(e)??f(e),"b");var E=Symbol.for("@lunora/errors/LunoraError"),h=class e extends Error{static{a(this,"a")}static[Symbol.hasInstance](t){return this!==e?Function.prototype[Symbol.hasInstance].call(this,t):typeof t=="object"&&t!==null&&t[E]===!0}type="VisulimaError";hint;title;loc;code;status;docsUrl;data;constructor(t,o,i={}){let s=c(t);super(o??t,i.cause===void 0?void 0:{cause:i.cause}),this.name=i.name??"LunoraError",this.hint=i.hint??s?.hint,this.title=i.title??s?.title,this.loc=i.location,this.code=t,this.status=i.status??s?.status??500,this.docsUrl=i.docsUrl??s?.docsUrl,this.data=i.data,Object.defineProperty(this,E,{value:!0})}};export{l as a,b,R as c,h as d};
@@ -0,0 +1 @@
1
+ import{a as de}from"./chunk-7G4Z6Q7X.js";import"./chunk-3YXASVTP.js";import"./chunk-AUAECCXB.js";import{b as Y}from"./chunk-Q6ED4KUL.js";import"./chunk-BOMPSVRC.js";import{a as te}from"./chunk-3CTF6VCQ.js";import"./chunk-NCPW7WHO.js";import"./chunk-VZWZIIP6.js";import"./chunk-55UGUCQ6.js";import"./chunk-C5NU4UZY.js";import{c as se,d as ie,e as ae}from"./chunk-23DA2KK5.js";import"./chunk-QAQDMS6R.js";import"./chunk-YLPATGWK.js";import{a as ee}from"./chunk-RWVIV3U7.js";import{a as ne,b as ce,c as oe,d as re,e as O,f as S}from"./chunk-HCTJKP5J.js";import{d as X,t as Z}from"./chunk-HJHSQPHW.js";import{a as o,d as $,e as ve,f as me,g as pe,i as le}from"./chunk-I26MS5PJ.js";var _=$(me(),1);var ue=$(ve(),1);var s=$(pe(),1);var ye=new Set(["cancelled","completed","expired"]),he=o(i=>ye.has(i),"fe"),fe=o(i=>i.extendedDueAt??i.dueAt,"me"),xe=o(i=>!he(i)&&i!=="ready","ve"),ge=o((i,e)=>xe(i.status)&&e.getTime()>fe(i).getTime(),"pe"),qe=o((i,e)=>ge({dueAt:new Date(i.dueAt),status:i.status,...i.extendedDueAt===void 0||i.extendedDueAt===null?{}:{extendedDueAt:new Date(i.extendedDueAt)}},new Date(e)),"ye"),Ae=["studio","privacy-requests"],De={cancelled:"outline",completed:"success",expired:"outline",failed:"destructive",grace:"secondary",processing:"warning",ready:"success",received:"info"},be=o(i=>Z(i??void 0,"\u2014"),"Ae"),Pe=o(i=>{let e=(0,_.c)(55),{asOf:u,retrying:t,row:r,onRetry:b}=i,d=X(),n,c,I;e[0]!==u||e[1]!==r?(c=qe(r,u),n=re,I=le(c&&"bg-destructive/5"),e[0]=u,e[1]=r,e[2]=n,e[3]=c,e[4]=I):(n=e[2],c=e[3],I=e[4]);let N=c?"true":"false",v;e[5]!==r.id?(v=(0,s.jsx)(S,{className:"font-mono text-xs",children:r.id}),e[5]=r.id,e[6]=v):v=e[6];let m;e[7]!==r.type||e[8]!==d?(m=r.type==="export"?d("Export"):d("Erasure"),e[7]=r.type,e[8]=d,e[9]=m):m=e[9];let E;e[10]!==m?(E=(0,s.jsx)(S,{children:(0,s.jsx)(Y,{variant:"secondary",children:m})}),e[10]=m,e[11]=E):E=e[11];let l;e[12]!==r.subjectId?(l=(0,s.jsx)(S,{className:"font-mono text-xs",children:r.subjectId}),e[12]=r.subjectId,e[13]=l):l=e[13];let T=De[r.status],P;e[14]!==r.status||e[15]!==T?(P=(0,s.jsx)(S,{children:(0,s.jsx)(Y,{variant:T,children:r.status})}),e[14]=r.status,e[15]=T,e[16]=P):P=e[16];let w;e[17]!==r.receivedAt?(w=Z(r.receivedAt),e[17]=r.receivedAt,e[18]=w):w=e[18];let R;e[19]!==w?(R=(0,s.jsx)(S,{children:w}),e[19]=w,e[20]=R):R=e[20];let p;e[21]!==r.dueAt?(p=Z(r.dueAt),e[21]=r.dueAt,e[22]=p):p=e[22];let y;e[23]!==p?(y=(0,s.jsx)(S,{children:p}),e[23]=p,e[24]=y):y=e[24];let h;e[25]!==r.extendedDueAt?(h=be(r.extendedDueAt),e[25]=r.extendedDueAt,e[26]=h):h=e[26];let f;e[27]!==h?(f=(0,s.jsx)(S,{children:h}),e[27]=h,e[28]=f):f=e[28];let x;e[29]!==c||e[30]!==d?(x=c&&(0,s.jsx)(Y,{"data-testid":"privacy-overdue",variant:"destructive",children:d("Overdue")}),e[29]=c,e[30]=d,e[31]=x):x=e[31];let g;e[32]!==x?(g=(0,s.jsx)(S,{children:x}),e[32]=x,e[33]=g):g=e[33];let q;e[34]!==b||e[35]!==t||e[36]!==r.id||e[37]!==r.status||e[38]!==d?(q=r.status==="failed"&&(0,s.jsx)(de,{disabled:t,onClick:o(()=>{b(r.id)},"onClick"),size:"xs",variant:"outline",children:d("Retry")}),e[34]=b,e[35]=t,e[36]=r.id,e[37]=r.status,e[38]=d,e[39]=q):q=e[39];let A;e[40]!==q?(A=(0,s.jsx)(S,{children:q}),e[40]=q,e[41]=A):A=e[41];let j;return e[42]!==n||e[43]!==I||e[44]!==R||e[45]!==y||e[46]!==f||e[47]!==g||e[48]!==A||e[49]!==N||e[50]!==v||e[51]!==E||e[52]!==l||e[53]!==P?(j=(0,s.jsxs)(n,{className:I,"data-overdue":N,"data-testid":"privacy-request-row",children:[v,E,l,P,R,y,f,g,A]}),e[42]=n,e[43]=I,e[44]=R,e[45]=y,e[46]=f,e[47]=g,e[48]=A,e[49]=N,e[50]=v,e[51]=E,e[52]=l,e[53]=P,e[54]=j):j=e[54],j},"ge"),we=o(i=>{let e=(0,_.c)(95),{source:u}=i,t=X(),r=se(),b=(0,ue.useId)(),d;e[0]!==b?(d=[...Ae,b],e[0]=b,e[1]=d):d=e[1];let n=d,c;e[2]!==u?(c=o(async()=>({asOf:Date.now(),requests:await u.listOpenPrivacyRequests()}),"c"),e[2]=u,e[3]=c):c=e[3];let I;e[4]!==n||e[5]!==c?(I={queryKey:n,refetchInterval:6e4,queryFn:c,staleTime:0},e[4]=n,e[5]=c,e[6]=I):I=e[6];let N=ie(I),v;e[7]!==u?(v=o(a=>u.retryPrivacyRequest(a),"u"),e[7]=u,e[8]=v):v=e[8];let m;e[9]!==r||e[10]!==n?(m=o(async()=>{await r.invalidateQueries({queryKey:n})},"f"),e[9]=r,e[10]=n,e[11]=m):m=e[11];let E;e[12]!==v||e[13]!==m?(E={mutationFn:v,onSuccess:m},e[12]=v,e[13]=m,e[14]=E):E=e[14];let l=ae(E),T;e[15]!==l?(T=o(a=>{l.mutate(a)},"N"),e[15]=l,e[16]=T):T=e[16];let P=T;if(N.isPending){let a;e[17]!==t?(a=t("Loading privacy requests\u2026"),e[17]=t,e[18]=a):a=e[18];let D;return e[19]!==a?(D=(0,s.jsx)("p",{className:"text-sm text-muted-foreground","data-testid":"privacy-requests-loading",role:"status",children:a}),e[19]=a,e[20]=D):D=e[20],D}if(N.isError){let a;return e[21]!==N.error?(a=(0,s.jsx)(te,{error:N.error,testId:"privacy-requests-error"}),e[21]=N.error,e[22]=a):a=e[22],a}let{asOf:w,requests:R}=N.data;if(R.length===0){let a;e[23]!==t?(a=t("No open privacy requests."),e[23]=t,e[24]=a):a=e[24];let D;return e[25]!==a?(D=(0,s.jsx)(ee,{testId:"privacy-requests-empty",title:a}),e[25]=a,e[26]=D):D=e[26],D}let p;e[27]!==l.error||e[28]!==l.isError?(p=l.isError&&(0,s.jsx)(te,{error:l.error,testId:"privacy-retry-error"}),e[27]=l.error,e[28]=l.isError,e[29]=p):p=e[29];let y;e[30]!==t?(y=t("ID"),e[30]=t,e[31]=y):y=e[31];let h;e[32]!==y?(h=(0,s.jsx)(O,{children:y}),e[32]=y,e[33]=h):h=e[33];let f;e[34]!==t?(f=t("Type"),e[34]=t,e[35]=f):f=e[35];let x;e[36]!==f?(x=(0,s.jsx)(O,{children:f}),e[36]=f,e[37]=x):x=e[37];let g;e[38]!==t?(g=t("Subject"),e[38]=t,e[39]=g):g=e[39];let q;e[40]!==g?(q=(0,s.jsx)(O,{children:g}),e[40]=g,e[41]=q):q=e[41];let A;e[42]!==t?(A=t("Status"),e[42]=t,e[43]=A):A=e[43];let j;e[44]!==A?(j=(0,s.jsx)(O,{children:A}),e[44]=A,e[45]=j):j=e[45];let B;e[46]!==t?(B=t("Received"),e[46]=t,e[47]=B):B=e[47];let Q;e[48]!==B?(Q=(0,s.jsx)(O,{children:B}),e[48]=B,e[49]=Q):Q=e[49];let C;e[50]!==t?(C=t("Due"),e[50]=t,e[51]=C):C=e[51];let F;e[52]!==C?(F=(0,s.jsx)(O,{children:C}),e[52]=C,e[53]=F):F=e[53];let K;e[54]!==t?(K=t("Extended due"),e[54]=t,e[55]=K):K=e[55];let k;e[56]!==K?(k=(0,s.jsx)(O,{children:K}),e[56]=K,e[57]=k):k=e[57];let z;e[58]!==t?(z=t("Overdue"),e[58]=t,e[59]=z):z=e[59];let L;e[60]!==z?(L=(0,s.jsx)(O,{children:z}),e[60]=z,e[61]=L):L=e[61];let M;e[62]!==t?(M=t("Actions"),e[62]=t,e[63]=M):M=e[63];let G;e[64]!==M?(G=(0,s.jsx)(O,{children:M}),e[64]=M,e[65]=G):G=e[65];let H;e[66]!==h||e[67]!==x||e[68]!==q||e[69]!==j||e[70]!==Q||e[71]!==F||e[72]!==k||e[73]!==L||e[74]!==G?(H=(0,s.jsx)(ce,{children:(0,s.jsxs)(re,{children:[h,x,q,j,Q,F,k,L,G]})}),e[66]=h,e[67]=x,e[68]=q,e[69]=j,e[70]=Q,e[71]=F,e[72]=k,e[73]=L,e[74]=G,e[75]=H):H=e[75];let J;if(e[76]!==w||e[77]!==P||e[78]!==R||e[79]!==l.isPending||e[80]!==l.variables){let a;e[82]!==w||e[83]!==P||e[84]!==l.isPending||e[85]!==l.variables?(a=o(D=>(0,s.jsx)(Pe,{asOf:w,onRetry:P,retrying:l.isPending&&l.variables===D.id,row:D},D.id),"l"),e[82]=w,e[83]=P,e[84]=l.isPending,e[85]=l.variables,e[86]=a):a=e[86],J=R.map(a),e[76]=w,e[77]=P,e[78]=R,e[79]=l.isPending,e[80]=l.variables,e[81]=J}else J=e[81];let U;e[87]!==J?(U=(0,s.jsx)(oe,{children:J}),e[87]=J,e[88]=U):U=e[88];let V;e[89]!==H||e[90]!==U?(V=(0,s.jsxs)(ne,{children:[H,U]}),e[89]=H,e[90]=U,e[91]=V):V=e[91];let W;return e[92]!==V||e[93]!==p?(W=(0,s.jsxs)("div",{className:"flex flex-col gap-3",children:[p,V]}),e[92]=V,e[93]=p,e[94]=W):W=e[94],W},"Te"),Qe=o(i=>{let e=(0,_.c)(11),u;e[0]!==i?(u=i===void 0?{}:i,e[0]=i,e[1]=u):u=e[1];let{source:t}=u,r=X();if(t===void 0){let d;e[2]!==r?(d=r("Pass privacyRequests to the Studio to list and retry data-subject requests."),e[2]=r,e[3]=d):d=e[3];let n;e[4]!==r?(n=r("Privacy requests not configured"),e[4]=r,e[5]=n):n=e[5];let c;return e[6]!==d||e[7]!==n?(c=(0,s.jsx)(ee,{description:d,testId:"privacy-requests-not-configured",title:n}),e[6]=d,e[7]=n,e[8]=c):c=e[8],c}let b;return e[9]!==t?(b=(0,s.jsx)(we,{source:t}),e[9]=t,e[10]=b):b=e[10],b},"Be");export{Qe as PrivacyRequestsPanel};
@@ -0,0 +1 @@
1
+ import{a as k}from"./chunk-ZKJS6EBE.js";import{i as j}from"./chunk-E4PXACVL.js";import{d as b}from"./chunk-HJHSQPHW.js";import{a as m,d as S,e as w,f as $,g as A}from"./chunk-I26MS5PJ.js";var y=S($(),1),h=S(w(),1);var a=S(A(),1);var z=m(i=>{let t=(0,y.c)(21),{id:f,onChange:g,testId:e,value:v}=i,s=b(),u=(0,h.useId)(),[d]=(0,h.useState)(F),c;t[0]!==g?(c=m(C=>{g(C.target.value)},"d"),t[0]=g,t[1]=c):c=t[1];let I=c,o;t[2]!==s?(o=s("Shard key"),t[2]=s,t[3]=o):o=t[3];let x=d.length>0?u:void 0,r;t[4]!==s?(r=s("shard key (optional)"),t[4]=s,t[5]=r):r=t[5];let l;t[6]!==f||t[7]!==I||t[8]!==o||t[9]!==x||t[10]!==r||t[11]!==e||t[12]!==v?(l=(0,a.jsx)(j,{"aria-label":o,className:"h-8 w-48","data-testid":e,id:f,list:x,onChange:I,placeholder:r,value:v}),t[6]=f,t[7]=I,t[8]=o,t[9]=x,t[10]=r,t[11]=e,t[12]=v,t[13]=l):l=t[13];let n;t[14]!==u||t[15]!==d||t[16]!==e?(n=d.length>0&&(0,a.jsx)("datalist",{"data-testid":`${e}-recents`,id:u,children:d.map(N)}),t[14]=u,t[15]=d,t[16]=e,t[17]=n):n=t[17];let p;return t[18]!==l||t[19]!==n?(p=(0,a.jsxs)(a.Fragment,{children:[l,n]}),t[18]=l,t[19]=n,t[20]=p):p=t[20],p},"A");function F(){return k()}m(F,"$");function N(i){return(0,a.jsx)("option",{"aria-label":i,value:i},i)}m(N,"w");export{z as a};