@aeolus-fleet/console 0.19.0 → 0.20.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (252) hide show
  1. package/.next/BUILD_ID +1 -1
  2. package/.next/app-path-routes-manifest.json +6 -0
  3. package/.next/build-manifest.json +3 -3
  4. package/.next/fallback-build-manifest.json +3 -3
  5. package/.next/prerender-manifest.json +3 -3
  6. package/.next/routes-manifest.json +40 -0
  7. package/.next/server/app/_global-error/page.js.nft.json +1 -1
  8. package/.next/server/app/_global-error.html +1 -1
  9. package/.next/server/app/_global-error.rsc +1 -1
  10. package/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  11. package/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  12. package/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  13. package/.next/server/app/_not-found/page.js.nft.json +1 -1
  14. package/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  15. package/.next/server/app/api/squadrons/[procedure]/route.js +1 -1
  16. package/.next/server/app/api/squadrons/[procedure]/route.js.nft.json +1 -1
  17. package/.next/server/app/api/trierarch-plugin/[procedure]/route/app-paths-manifest.json +3 -0
  18. package/.next/server/app/api/trierarch-plugin/[procedure]/route/build-manifest.json +12 -0
  19. package/.next/server/app/api/trierarch-plugin/[procedure]/route/server-reference-manifest.json +4 -0
  20. package/.next/server/app/api/trierarch-plugin/[procedure]/route.js +6 -0
  21. package/.next/server/app/api/trierarch-plugin/[procedure]/route.js.nft.json +1 -0
  22. package/.next/server/app/api/trierarch-plugin/[procedure]/route_client-reference-manifest.js +3 -0
  23. package/.next/server/app/health/route.js +1 -1
  24. package/.next/server/app/health/route.js.nft.json +1 -1
  25. package/.next/server/app/inbox/page.js.nft.json +1 -1
  26. package/.next/server/app/inbox/page_client-reference-manifest.js +1 -1
  27. package/.next/server/app/labels/page/app-paths-manifest.json +3 -0
  28. package/.next/server/app/labels/page/build-manifest.json +20 -0
  29. package/.next/server/app/labels/page/next-font-manifest.json +11 -0
  30. package/.next/server/app/labels/page/react-loadable-manifest.json +1 -0
  31. package/.next/server/app/labels/page/server-reference-manifest.json +4 -0
  32. package/.next/server/app/labels/page.js +14 -0
  33. package/.next/server/app/labels/page.js.nft.json +1 -0
  34. package/.next/server/app/labels/page_client-reference-manifest.js +3 -0
  35. package/.next/server/app/needs-attention/page.js.nft.json +1 -1
  36. package/.next/server/app/needs-attention/page_client-reference-manifest.js +1 -1
  37. package/.next/server/app/needs-crew/page/app-paths-manifest.json +3 -0
  38. package/.next/server/app/needs-crew/page/build-manifest.json +20 -0
  39. package/.next/server/app/needs-crew/page/next-font-manifest.json +11 -0
  40. package/.next/server/app/needs-crew/page/react-loadable-manifest.json +1 -0
  41. package/.next/server/app/needs-crew/page/server-reference-manifest.json +4 -0
  42. package/.next/server/app/needs-crew/page.js +14 -0
  43. package/.next/server/app/needs-crew/page.js.nft.json +1 -0
  44. package/.next/server/app/needs-crew/page_client-reference-manifest.js +3 -0
  45. package/.next/server/app/page.js.nft.json +1 -1
  46. package/.next/server/app/page_client-reference-manifest.js +1 -1
  47. package/.next/server/app/settings/page.js.nft.json +1 -1
  48. package/.next/server/app/settings/page_client-reference-manifest.js +1 -1
  49. package/.next/server/app/ships/[shipId]/page.js.nft.json +1 -1
  50. package/.next/server/app/ships/[shipId]/page_client-reference-manifest.js +1 -1
  51. package/.next/server/app/sign-in/failed/page.js.nft.json +1 -1
  52. package/.next/server/app/sign-in/failed/page_client-reference-manifest.js +1 -1
  53. package/.next/server/app/sign-in/page.js.nft.json +1 -1
  54. package/.next/server/app/sign-in/page_client-reference-manifest.js +1 -1
  55. package/.next/server/app/squadrons/[squadronId]/page.js.nft.json +1 -1
  56. package/.next/server/app/squadrons/[squadronId]/page_client-reference-manifest.js +1 -1
  57. package/.next/server/app/squadrons/blueprints/[name]/page.js.nft.json +1 -1
  58. package/.next/server/app/squadrons/blueprints/[name]/page_client-reference-manifest.js +1 -1
  59. package/.next/server/app/squadrons/connection/route.js +3 -3
  60. package/.next/server/app/squadrons/connection/route.js.nft.json +1 -1
  61. package/.next/server/app/squadrons/page.js.nft.json +1 -1
  62. package/.next/server/app/squadrons/page_client-reference-manifest.js +1 -1
  63. package/.next/server/app/squadrons/templates/[name]/page.js.nft.json +1 -1
  64. package/.next/server/app/squadrons/templates/[name]/page_client-reference-manifest.js +1 -1
  65. package/.next/server/app/trierarch-plugin/connection/route/app-paths-manifest.json +3 -0
  66. package/.next/server/app/trierarch-plugin/connection/route/build-manifest.json +12 -0
  67. package/.next/server/app/trierarch-plugin/connection/route/server-reference-manifest.json +4 -0
  68. package/.next/server/app/trierarch-plugin/connection/route.js +8 -0
  69. package/.next/server/app/trierarch-plugin/connection/route.js.nft.json +1 -0
  70. package/.next/server/app/trierarch-plugin/connection/route_client-reference-manifest.js +3 -0
  71. package/.next/server/app/trierarchs/[shipId]/page/app-paths-manifest.json +3 -0
  72. package/.next/server/app/trierarchs/[shipId]/page/build-manifest.json +20 -0
  73. package/.next/server/app/trierarchs/[shipId]/page/next-font-manifest.json +11 -0
  74. package/.next/server/app/trierarchs/[shipId]/page/react-loadable-manifest.json +1 -0
  75. package/.next/server/app/trierarchs/[shipId]/page/server-reference-manifest.json +4 -0
  76. package/.next/server/app/trierarchs/[shipId]/page.js +14 -0
  77. package/.next/server/app/trierarchs/[shipId]/page.js.nft.json +1 -0
  78. package/.next/server/app/trierarchs/[shipId]/page_client-reference-manifest.js +3 -0
  79. package/.next/server/app/trierarchs/page/app-paths-manifest.json +3 -0
  80. package/.next/server/app/trierarchs/page/build-manifest.json +20 -0
  81. package/.next/server/app/trierarchs/page/next-font-manifest.json +11 -0
  82. package/.next/server/app/trierarchs/page/react-loadable-manifest.json +1 -0
  83. package/.next/server/app/trierarchs/page/server-reference-manifest.json +4 -0
  84. package/.next/server/app/trierarchs/page.js +14 -0
  85. package/.next/server/app/trierarchs/page.js.nft.json +1 -0
  86. package/.next/server/app/trierarchs/page_client-reference-manifest.js +3 -0
  87. package/.next/server/app/version/route.js +3 -2
  88. package/.next/server/app/version/route.js.nft.json +1 -1
  89. package/.next/server/app-paths-manifest.json +6 -0
  90. package/.next/server/chunks/04lx_next-internal_server_app_api_trierarch-plugin_[procedure]_route_actions_0pov8t_.js +3 -0
  91. package/.next/server/chunks/1eui__next-internal_server_app_trierarch-plugin_connection_route_actions_1jgdi18.js +3 -0
  92. package/.next/server/chunks/{[root-of-the-server]__0w2mqex._.js → [root-of-the-server]__14rtv1n._.js} +2 -2
  93. package/.next/server/chunks/[root-of-the-server]__1c6takz._.js +3 -0
  94. package/.next/server/chunks/[root-of-the-server]__1f7engf._.js +3 -0
  95. package/.next/server/chunks/[root-of-the-server]__1f_8ohl._.js +3 -0
  96. package/.next/server/chunks/[root-of-the-server]__1h3r48l._.js +3 -0
  97. package/.next/server/chunks/[root-of-the-server]__1kc3njk._.js +3 -0
  98. package/.next/server/chunks/_0h366h9._.js +3 -0
  99. package/.next/server/chunks/packages_console_lib_connect-plugin_ts_197hf-1._.js +3 -0
  100. package/.next/server/chunks/ssr/0ysl_console__next-internal_server_app_trierarchs_[shipId]_page_actions_0e_rw4u.js +3 -0
  101. package/.next/server/chunks/ssr/[root-of-the-server]__0qbhnxj._.js +3 -0
  102. package/.next/server/chunks/ssr/[root-of-the-server]__18derwo._.js +3 -0
  103. package/.next/server/chunks/ssr/[root-of-the-server]__18g_7b-._.js +3 -0
  104. package/.next/server/chunks/ssr/[root-of-the-server]__1m1u7bl._.js +3 -0
  105. package/.next/server/chunks/ssr/[root-of-the-server]__1uan58j._.js +3 -3
  106. package/.next/server/chunks/ssr/_01f7zv3._.js +3 -0
  107. package/.next/server/chunks/ssr/_06c6zlg._.js +3 -0
  108. package/.next/server/chunks/ssr/_08f4mzr._.js +3 -0
  109. package/.next/server/chunks/ssr/_0bmd2ey._.js +3 -0
  110. package/.next/server/chunks/ssr/{_0plfddz._.js → _0dogq79._.js} +2 -2
  111. package/.next/server/chunks/ssr/_0exrpxl._.js +3 -0
  112. package/.next/server/chunks/ssr/_0gt230s._.js +3 -0
  113. package/.next/server/chunks/ssr/_0i0_i88._.js +3 -0
  114. package/.next/server/chunks/ssr/_0mob-i2._.js +3 -0
  115. package/.next/server/chunks/ssr/_0n4kirm._.js +3 -0
  116. package/.next/server/chunks/ssr/_0rvujxo._.js +3 -0
  117. package/.next/server/chunks/ssr/{_00yiulp._.js → _0s2b6hb._.js} +2 -2
  118. package/.next/server/chunks/ssr/{_050suap._.js → _0sko-kt._.js} +2 -2
  119. package/.next/server/chunks/ssr/_0snpwr0._.js +3 -0
  120. package/.next/server/chunks/ssr/_0t1jjxf._.js +1 -1
  121. package/.next/server/chunks/ssr/_0udw2gs._.js +3 -0
  122. package/.next/server/chunks/ssr/{_0-rsrfr._.js → _0wtj0e-._.js} +2 -2
  123. package/.next/server/chunks/ssr/_0xi2v5k._.js +3 -0
  124. package/.next/server/chunks/ssr/{_0igx2qf._.js → _0xvm1ng._.js} +2 -2
  125. package/.next/server/chunks/ssr/_0ziovn_._.js +3 -0
  126. package/.next/server/chunks/ssr/_1442xyx._.js +3 -0
  127. package/.next/server/chunks/ssr/_16jiag3._.js +3 -0
  128. package/.next/server/chunks/ssr/_181kpys._.js +3 -0
  129. package/.next/server/chunks/ssr/_19e0e-9._.js +3 -3
  130. package/.next/server/chunks/ssr/_1bqclkf._.js +3 -0
  131. package/.next/server/chunks/ssr/_1cn9_0f._.js +3 -0
  132. package/.next/server/chunks/ssr/_1d6cgif._.js +3 -0
  133. package/.next/server/chunks/ssr/_1g2wuzd._.js +1 -1
  134. package/.next/server/chunks/ssr/_1hcta3c._.js +3 -0
  135. package/.next/server/chunks/ssr/_1kv8ma5._.js +3 -0
  136. package/.next/server/chunks/ssr/{_1s07u90._.js → _1lu1eda._.js} +2 -2
  137. package/.next/server/chunks/ssr/_1ntb2un._.js +3 -0
  138. package/.next/server/chunks/ssr/_1ommvbv._.js +3 -0
  139. package/.next/server/chunks/ssr/_1oofkty._.js +3 -0
  140. package/.next/server/chunks/ssr/_1oqoc4e._.js +3 -0
  141. package/.next/server/chunks/ssr/_1r6ce_7._.js +3 -0
  142. package/.next/server/chunks/ssr/_1tsejml._.js +3 -0
  143. package/.next/server/chunks/ssr/{_1s8-j5t._.js → _1ub6rp3._.js} +2 -2
  144. package/.next/server/chunks/ssr/_20pku2-._.js +3 -0
  145. package/.next/server/chunks/ssr/packages_console_023iioa._.js +3 -0
  146. package/.next/server/chunks/ssr/packages_console_03isfmy._.js +3 -0
  147. package/.next/server/chunks/ssr/packages_console_0lv43wr._.js +3 -0
  148. package/.next/server/chunks/ssr/packages_console_10fqil_._.js +1 -1
  149. package/.next/server/chunks/ssr/packages_console__next-internal_server_app_labels_page_actions_0-7_20w.js +3 -0
  150. package/.next/server/chunks/ssr/packages_console__next-internal_server_app_needs-crew_page_actions_0rw7fgn.js +3 -0
  151. package/.next/server/chunks/ssr/packages_console__next-internal_server_app_trierarchs_page_actions_1zds6hw.js +3 -0
  152. package/.next/server/chunks/ssr/packages_console_app_inbox_page_tsx_1bpmlpx._.js +1 -1
  153. package/.next/server/chunks/ssr/packages_console_app_labels_page_tsx_0xxovjk._.js +3 -0
  154. package/.next/server/chunks/ssr/packages_console_app_needs-attention_page_tsx_1agfico._.js +1 -1
  155. package/.next/server/chunks/ssr/packages_console_app_page_tsx_16ln4px._.js +1 -1
  156. package/.next/server/chunks/ssr/packages_console_app_providers_tsx_06ai92n._.js +1 -1
  157. package/.next/server/chunks/ssr/packages_console_app_settings_page_tsx_1zqt7sk._.js +1 -1
  158. package/.next/server/chunks/ssr/packages_console_app_ships_[shipId]_page_tsx_0fudjay._.js +1 -1
  159. package/.next/server/chunks/ssr/packages_console_app_squadrons_[squadronId]_page_tsx_1umxs1g._.js +1 -1
  160. package/.next/server/chunks/ssr/packages_console_app_squadrons_page_tsx_1w6ym6z._.js +1 -1
  161. package/.next/server/chunks/ssr/packages_console_app_trierarchs_[shipId]_page_tsx_1rqyoj3._.js +3 -0
  162. package/.next/server/chunks/ssr/{packages_console_components_1_4zc74._.js → packages_console_components_1-5gwzg._.js} +2 -2
  163. package/.next/server/chunks/ssr/packages_console_components_atoms_select_tsx_1v_3j3i._.js +1 -1
  164. package/.next/server/chunks/ssr/packages_console_lib_crew-settings-form_ts_1_mrtph._.js +3 -0
  165. package/.next/server/middleware-build-manifest.js +3 -3
  166. package/.next/server/next-font-manifest.js +1 -1
  167. package/.next/server/next-font-manifest.json +16 -0
  168. package/.next/server/pages/500.html +1 -1
  169. package/.next/server/server-reference-manifest.js +1 -1
  170. package/.next/server/server-reference-manifest.json +1 -1
  171. package/.next/static/chunks/00pjrzynt0in-.js +1 -0
  172. package/.next/static/chunks/038sk3qwghvto.js +1 -0
  173. package/.next/static/chunks/{1cbzjk-qf984o.js → 0e6zs-5ou_ra4.js} +1 -1
  174. package/.next/static/chunks/0ez9e35zkfaz5.js +1 -0
  175. package/.next/static/chunks/0f5-vxw1bk8ym.js +1 -0
  176. package/.next/static/chunks/0vlyibw4rexm7.js +1 -0
  177. package/.next/static/chunks/{2ff-56ohrio7h.js → 0z1nza3zgavbi.js} +1 -1
  178. package/.next/static/chunks/16o3i61aw3cj2.js +1 -0
  179. package/.next/static/chunks/177iv_tzmr_0a.js +1 -0
  180. package/.next/static/chunks/17quvh6filhxh.js +1 -0
  181. package/.next/static/chunks/19x_u3cmb9s_j.js +1 -0
  182. package/.next/static/chunks/1auwxv_urmljv.js +1 -0
  183. package/.next/static/chunks/1mbia-jrmgpuu.js +1 -0
  184. package/.next/static/chunks/1zuzmwfsw_7q0.js +1 -0
  185. package/.next/static/chunks/{2z2hhi291ems4.js → 21jwgqx67q8ql.js} +12 -12
  186. package/.next/static/chunks/26dg2z_6kosr0.js +1 -0
  187. package/.next/static/chunks/2_txjvbug4b86.js +1 -0
  188. package/.next/static/chunks/2c1daktq2hun-.css +3 -0
  189. package/.next/static/chunks/{04p19br-6pr3q.js → 2k5tcu7bvrhet.js} +1 -1
  190. package/.next/static/chunks/2ne-qdcv-7ck1.js +1 -0
  191. package/.next/static/chunks/2r01e5tqyyrsv.js +1 -0
  192. package/.next/static/chunks/{0hl9b82m3b_kf.js → 2zu1o4z0tmf0-.js} +1 -1
  193. package/.next/static/chunks/{22wd2oyjf0iq_.js → 30ux5-xn650iq.js} +1 -1
  194. package/.next/static/chunks/32oc7qg77tpjj.js +1 -0
  195. package/.next/static/chunks/36_a72wj7_f-y.js +1 -0
  196. package/.next/static/chunks/39-cyg4qvxgbm.js +1 -0
  197. package/.next/static/chunks/3b5uomyz3knol.js +1 -0
  198. package/.next/static/chunks/3e1veij7vs6ao.js +1 -0
  199. package/.next/static/chunks/3eaxbdj-y982h.js +1 -0
  200. package/.next/static/chunks/{0nchi43nyih52.js → 3evbxrltn9tcu.js} +1 -1
  201. package/.next/static/chunks/3jsj5ozfio3me.js +1 -0
  202. package/.next/static/chunks/3pkfx52bufv4g.js +1 -0
  203. package/.next/static/chunks/{2quoh5csh67oz.js → 3t2amxc2hojri.js} +1 -1
  204. package/.next/static/chunks/3x_52f9if0z-8.js +1 -0
  205. package/.next/static/chunks/42y_hgylfwlq5.js +1 -0
  206. package/README.md +1 -0
  207. package/package.json +3 -3
  208. package/.next/server/chunks/[root-of-the-server]__0eg7gro._.js +0 -3
  209. package/.next/server/chunks/[root-of-the-server]__11ajlfh._.js +0 -3
  210. package/.next/server/chunks/[root-of-the-server]__1w1vtvn._.js +0 -3
  211. package/.next/server/chunks/_1mul6_v._.js +0 -3
  212. package/.next/server/chunks/ssr/_01eh2h5._.js +0 -3
  213. package/.next/server/chunks/ssr/_05wjy-d._.js +0 -3
  214. package/.next/server/chunks/ssr/_09pq8b7._.js +0 -3
  215. package/.next/server/chunks/ssr/_0_6abve._.js +0 -3
  216. package/.next/server/chunks/ssr/_0aqa8e3._.js +0 -3
  217. package/.next/server/chunks/ssr/_0c1ebla._.js +0 -3
  218. package/.next/server/chunks/ssr/_0g98qoq._.js +0 -3
  219. package/.next/server/chunks/ssr/_0k0kffc._.js +0 -3
  220. package/.next/server/chunks/ssr/_0ksc8ky._.js +0 -3
  221. package/.next/server/chunks/ssr/_0nxk8e5._.js +0 -3
  222. package/.next/server/chunks/ssr/_0sh180u._.js +0 -3
  223. package/.next/server/chunks/ssr/_0vz-_zq._.js +0 -3
  224. package/.next/server/chunks/ssr/_0y_ez3b._.js +0 -3
  225. package/.next/server/chunks/ssr/_0zz00ec._.js +0 -3
  226. package/.next/server/chunks/ssr/_101_mtq._.js +0 -3
  227. package/.next/server/chunks/ssr/_10vocmg._.js +0 -3
  228. package/.next/server/chunks/ssr/_16klr-g._.js +0 -3
  229. package/.next/server/chunks/ssr/_1_hm4gt._.js +0 -3
  230. package/.next/server/chunks/ssr/_1c2ijn5._.js +0 -3
  231. package/.next/server/chunks/ssr/_1jgnfkf._.js +0 -3
  232. package/.next/server/chunks/ssr/_1m_b36m._.js +0 -3
  233. package/.next/server/chunks/ssr/_1pif908._.js +0 -3
  234. package/.next/server/chunks/ssr/_20fp5al._.js +0 -3
  235. package/.next/static/chunks/05xsztb02v-3h.js +0 -1
  236. package/.next/static/chunks/0atm4wesk-4u8.js +0 -1
  237. package/.next/static/chunks/0es5vdu6lt-lm.css +0 -3
  238. package/.next/static/chunks/0jkliy--t1bbh.js +0 -1
  239. package/.next/static/chunks/0oh4dxohbk7m8.js +0 -1
  240. package/.next/static/chunks/0w8wux_7extu3.js +0 -1
  241. package/.next/static/chunks/0xdkx7wg739q7.js +0 -1
  242. package/.next/static/chunks/1q-shkfypoia-.js +0 -1
  243. package/.next/static/chunks/1t5mkoni0wrc0.js +0 -1
  244. package/.next/static/chunks/21py3ha_f_e3-.js +0 -1
  245. package/.next/static/chunks/2t6jzvnrf9ejw.js +0 -1
  246. package/.next/static/chunks/32-17dotvltga.js +0 -1
  247. package/.next/static/chunks/3m4-wgj579r4x.js +0 -1
  248. package/.next/static/chunks/3tsjbqptivphr.js +0 -1
  249. package/.next/static/chunks/42-u_9nvmdste.js +0 -1
  250. /package/.next/static/{4BHf_wBvFUce1tC4Uw_GD → LHmQaS8aizP80vXh3K-ws}/_buildManifest.js +0 -0
  251. /package/.next/static/{4BHf_wBvFUce1tC4Uw_GD → LHmQaS8aizP80vXh3K-ws}/_clientMiddlewareManifest.js +0 -0
  252. /package/.next/static/{4BHf_wBvFUce1tC4Uw_GD → LHmQaS8aizP80vXh3K-ws}/_ssgManifest.js +0 -0
@@ -1 +1 @@
1
- (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,25933,e=>{"use strict";e.i(79652);var t=e.i(45654),n=e.i(94268),r=e.i(31375),i=e.i(69534),o=e.i(93798),s=e.i(56212),a=e.i(5627),l=e.i(24889),u=e.i(89102),c=e.i(18118),d=e.i(98108),f=e.i(60375),p=e.i(37642),m=e.i(54463),g=e.i(111),h=e.i(36760),v=e.i(44013),b=e.i(6346),x=e.i(72705),y=e.i(87754),S=e.i(59182),C=e.i(53590),E=e.i(87445),R=e.i(51614),w=e.i(17088);let I=e.i(18438).ListboxSeparator;var T=e.i(56970),O=e.i(2672),k=e.i(56789),M=e.i(42191),A=e.i(91786);e.s(["Arrow",()=>p.ComboboxArrow,"Backdrop",()=>c.ComboboxBackdrop,"Chip",()=>y.ComboboxChip,"ChipRemove",()=>S.ComboboxChipRemove,"Chips",()=>x.ComboboxChips,"Clear",()=>w.ComboboxClear,"Collection",()=>E.ComboboxCollection,"Empty",()=>R.ComboboxEmpty,"Group",()=>g.ComboboxGroup,"GroupLabel",()=>h.ComboboxGroupLabel,"Icon",()=>m.ComboboxIcon,"Input",()=>i.ComboboxInput,"InputGroup",()=>o.ComboboxInputGroup,"Item",()=>v.ComboboxItem,"ItemIndicator",()=>b.ComboboxItemIndicator,"Label",()=>n.ComboboxLabel,"List",()=>a.ComboboxList,"Popup",()=>f.ComboboxPopup,"Portal",()=>u.ComboboxPortal,"Positioner",()=>d.ComboboxPositioner,"Root",()=>t.ComboboxRoot,"Row",()=>C.ComboboxRow,"Separator",0,I,"Status",()=>l.ComboboxStatus,"Trigger",()=>s.ComboboxTrigger,"Value",()=>r.ComboboxValue,"createItems",0,function(e,t){let{getValue:n,getLabel:r}=t,i=null;function o(){if(null===i){let t=new Map;for(let r of e?(0,M.flattenLeafItems)(e):k.EMPTY_ARRAY){if(null==r)continue;let e=n(r);t.has(e)||t.set(e,r)}i=t}return i}return{data:e,value:function(e){return null==e?e:n(e)},hasValue:(e,t)=>void 0!==(0,A.findCollectionItem)(o(),e,t),itemLabel:r,label(e,t,n){let i=(0,A.findCollectionItem)(o(),e,t);return void 0!==i?r(i):(0,M.stringifyAsLabel)(e,n)}}},"useFilter",()=>T.useComboboxFilter,"useFilteredItems",0,function(){return(0,O.useComboboxDerivedItemsContext)().filteredItems}],24189);var P=e.i(24189);e.s(["Combobox",0,P],25933)},44013,6346,72705,87754,59182,53590,51614,17088,e=>{"use strict";var t=e.i(71645),n=e.i(74080),r=e.i(46376),i=e.i(2672),o=e.i(73553),s=e.i(52245),a=e.i(33332);let l=t.createContext(void 0);function u(){let e=t.useContext(l);if(!e)throw Error((0,a.default)(19));return e}var c=e.i(40886);let d=t.createContext(!1);var f=e.i(84325),p=e.i(43476);function m(e){let{componentProps:a,forwardedRef:u,virtualized:m,indexFromFilter:g}=e,{render:h,className:v,style:b,value:x=null,index:y,disabled:S=!1,nativeButton:C=!1,...E}=a,R=t.useRef(null),w=(0,o.useCompositeListItem)({guess:!0,index:y,textRef:R}),I=(0,i.useComboboxRootContext)(),T=t.useContext(d),O=(0,i.useComboboxHasItemsContext)(),k=I.useState("selectionMode"),M=I.useState("disabled"),A=I.useState("readOnly"),P=I.useState("isItemEqualToValue"),N=M||S,j="none"!==k,L=y??g??w.index,D=-1!==L,z=I.useState("id"),F=I.useState("isActive",L),H=I.useState("isSelected",x),V=I.useState("itemProps"),_=t.useRef(null),B=null!=z&&D?`${z}-${L}`:void 0,q=H&&j;(0,r.useIsoLayoutEffect)(()=>{if(!(D&&(m||null!=y)))return;let e=I.context.listRef.current;return e[L]=_.current,()=>{delete e[L]}},[D,m,L,y,I]),(0,r.useIsoLayoutEffect)(()=>{if(!D||O)return;let e=I.context.valuesRef.current;return e[L]=x,()=>{delete e[L]}},[D,O,L,x,I]),(0,r.useIsoLayoutEffect)(()=>{if(!D||O)return;let e=I.state.selectedValue,t=I.state.selectedIndex;"multiple"===I.state.selectionMode&&Array.isArray(e)?t=(0,f.resolveSelectedIndex)(L,x,I.context.valuesRef.current,e,P,t):(0,f.compareItemEquality)(x,e,P)&&(t=L),I.set("selectedIndex",t)},[D,O,I,L,x,P]);let{getButtonProps:W,buttonRef:$}=(0,c.useButton)({disabled:N,focusableWhenDisabled:!0,native:C,composite:!0});function U(e){function t(){I.context.handleSelection(e,x)}I.state.submitOnItemClick?(n.flushSync(t),I.context.requestSubmit()):t()}let K=(0,s.useRenderElement)("div",a,{ref:[$,u,w.ref,_],state:{disabled:N,selected:q,highlighted:F},props:[V,{id:B,role:T?"gridcell":"option","aria-selected":j?q:void 0,tabIndex:void 0,onPointerDownCapture(e){e.isPrimary&&(I.context.pointerDownItemRef.current=e.currentTarget),e.preventDefault()},onMouseDown(e){e.preventDefault()},onClick(e){N||A||U(e.nativeEvent)},onMouseUp(e){let t=I.context.pointerDownItemRef.current===e.currentTarget;I.context.pointerDownItemRef.current=null,N||A||0!==e.button||t||!F||U(e.nativeEvent)}},E,W]}),G=t.useMemo(()=>({selected:q,textRef:R}),[q,R]);return(0,p.jsx)(l.Provider,{value:G,children:K})}function g(e){let{componentProps:t,forwardedRef:n}=e,r=(0,i.useComboboxRootContext)().useState("isItemEqualToValue"),{flatFilteredValues:o}=(0,i.useComboboxDerivedItemsContext)(),s=t.value??null,a=(0,f.findItemIndex)(o,s,r);return(0,p.jsx)(m,{componentProps:t,forwardedRef:n,virtualized:!0,indexFromFilter:a})}let h=t.memo(t.forwardRef(function(e,t){let n=(0,i.useComboboxRootContext)().useState("virtualized");return n&&null==e.index?(0,p.jsx)(g,{componentProps:e,forwardedRef:t}):(0,p.jsx)(m,{componentProps:e,forwardedRef:t,virtualized:n,indexFromFilter:void 0})}));e.s(["ComboboxItem",0,h],44013);var v=e.i(23910),b=e.i(37584),x=e.i(74354);let y=t.forwardRef(function(e,t){let{selected:n}=u();return e.keepMounted||n?(0,p.jsx)(S,{...e,ref:t}):null}),S=t.memo(t.forwardRef((e,n)=>{let{render:r,className:i,style:o,keepMounted:a,...l}=e,{selected:c}=u(),d=t.useRef(null),{transitionStatus:f,setMounted:p}=(0,v.useTransitionStatus)(c),m=(0,s.useRenderElement)("span",e,{ref:[n,d],state:{selected:c,transitionStatus:f},props:[{"aria-hidden":!0,children:"✔️"},l],stateAttributesMapping:x.transitionStatusMapping});return(0,b.useOpenChangeComplete)({batch:!0,enabled:!c,open:c,ref:d,onComplete(){c||p(!1)}}),m}));e.s(["ComboboxItemIndicator",0,y],6346);var C=e.i(56789),E=e.i(13735),R=e.i(53687),w=e.i(22994);let I=t.forwardRef(function(e,n){let{render:r,className:o,style:a,...l}=e,u=(0,i.useComboboxRootContext)(),c=u.useState("open"),d=u.useState("hasSelectionChips"),[f,m]=t.useState(void 0);c&&void 0!==f&&m(void 0);let g=t.useRef([]),h=(0,s.useRenderElement)("div",e,{ref:[n,u.context.chipsContainerRef],props:[d?{role:"toolbar"}:C.EMPTY_OBJECT,{onMouseDown(e){(0,w.handleInputPress)(e,u,u.state.disabled)}},l]}),v=t.useMemo(()=>({highlightedChipIndex:f,setHighlightedChipIndex:m,chipsRef:g}),[f,m,g]);return(0,p.jsx)(E.ComboboxChipsContext.Provider,{value:v,children:(0,p.jsx)(R.CompositeList,{elementsRef:g,children:h})})});e.s(["ComboboxChips",0,I],72705);let T=t.createContext(void 0);var O=e.i(57940),k=e.i(75606),M=e.i(56434),A=e.i(72855),P=e.i(97464);let N=t.forwardRef(function(e,r){let{render:a,className:l,style:u,...c}=e,d=(0,i.useComboboxRootContext)(),{setHighlightedChipIndex:f,chipsRef:m}=(0,E.useComboboxChipsContext)(),g=(0,A.useDirection)(),h=d.useState("disabled"),v=d.useState("readOnly"),b=d.useState("selectedValue"),{ref:x,index:y}=(0,o.useCompositeListItem)(),S=(0,s.useRenderElement)("div",e,{ref:[r,x],state:{disabled:h},props:[{tabIndex:-1,"aria-disabled":h||void 0,"aria-readonly":v||void 0,onKeyDown(e){if(h||v)return;let t=function(e){let t=y,[n,r]=(0,P.getChipNavigationKeys)(g);return e.key===n?(e.preventDefault(),t=y>0?y-1:void 0):e.key===r?(e.preventDefault(),t=y<m.current.length-1?y+1:void 0):"Backspace"===e.key||"Delete"===e.key?(t=(0,P.getIndexAfterChipRemoval)(y,b.length),(0,O.stopEvent)(e),d.context.setIndices({activeIndex:null,selectedIndex:null,type:M.REASONS.keyboard}),d.context.setSelectedValue(b.filter((e,t)=>t!==y),(0,k.createChangeEventDetails)(M.REASONS.none,e.nativeEvent))):"Enter"===e.key||" "===e.key?((0,O.stopEvent)(e),t=void 0):"ArrowDown"===e.key||"ArrowUp"===e.key?((0,O.stopEvent)(e),d.context.setOpen(!0,(0,k.createChangeEventDetails)(M.REASONS.listNavigation,e.nativeEvent)),t=void 0):1!==e.key.length||e.ctrlKey||e.metaKey||e.altKey||(t=void 0),t}(e);n.flushSync(()=>{f(t)}),void 0===t?d.context.inputRef.current?.focus():m.current[t]?.focus()}},c]}),C=t.useMemo(()=>({index:y}),[y]);return(0,p.jsx)(T.Provider,{value:C,children:S})});e.s(["ComboboxChip",0,N],87754);let j=t.forwardRef(function(e,n){let{render:r,className:o,disabled:l=!1,nativeButton:u=!0,style:d,...p}=e,m=(0,i.useComboboxRootContext)(),{index:g}=function(){let e=t.useContext(T);if(!e)throw Error((0,a.default)(17));return e}(),h=m.useState("disabled"),v=m.useState("readOnly"),b=m.useState("selectedValue"),x=m.useState("isItemEqualToValue"),y=h||l,{buttonRef:S,getButtonProps:C}=(0,c.useButton)({native:u,disabled:y||v,focusableWhenDisabled:!0});function E(e){let t=(0,k.createChangeEventDetails)(M.REASONS.chipRemovePress,e.nativeEvent);return!function(e){let t=m.state.activeIndex;if(null==t)return;let n=(0,f.findItemIndex)(m.context.valuesRef.current,e,x);-1!==n&&t===n&&m.context.setIndices({activeIndex:null,type:m.context.keyboardActiveRef.current?M.REASONS.keyboard:M.REASONS.pointer})}(b[g]),m.context.setSelectedValue(b.filter((e,t)=>t!==g),t),m.context.inputRef.current?.focus(),t}return(0,s.useRenderElement)("button",e,{ref:[n,S],state:{disabled:y},props:[{tabIndex:-1,onMouseDown(e){e.preventDefault()},onClick(e){E(e).isPropagationAllowed||e.stopPropagation()},onKeyDown(e){("Enter"===e.key||" "===e.key)&&(E(e).isPropagationAllowed||(0,O.stopEvent)(e))}},p,C]})});e.s(["ComboboxChipRemove",0,j],59182);let L=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...o}=e,a=(0,s.useRenderElement)("div",e,{ref:t,props:[{role:"row"},o]});return(0,p.jsx)(d.Provider,{value:!0,children:a})});e.s(["ComboboxRow",0,L],53590);var D=e.i(31766);let z=t.forwardRef(function(e,t){let{render:n,className:r,style:o,children:a,...l}=e,{filteredItems:u}=(0,i.useComboboxDerivedItemsContext)(),c=(0,i.useComboboxRootContext)(),d=(0,D.useInitialLiveRegionTextMutation)(),f=0===u.length?a:null;return(0,s.useRenderElement)("div",e,{ref:[t,c.context.emptyRef,d],props:[{children:f,role:"status","aria-live":"polite","aria-atomic":!0},l]})});e.s(["ComboboxEmpty",0,z],51614);var F=e.i(69690),H=e.i(79938);let V={...x.transitionStatusMapping,...H.triggerOpenStateMapping},_=t.forwardRef(function(e,t){let{render:n,className:r,disabled:o=!1,nativeButton:a=!0,keepMounted:l=!1,style:u,...d}=e,{disabled:f}=(0,F.useFieldRootContext)(),p=(0,i.useComboboxRootContext)(),m=p.useState("selectionMode"),g=p.useState("disabled"),h=p.useState("readOnly"),x=p.useState("open"),y=p.useState("selectedValue"),S=p.useState("hasSelectionChips"),C=(0,i.useComboboxInputValueContext)(),E=!1;E="none"===m?""!==C:"single"===m?null!=y:S;let R=f||g||o,{buttonRef:w,getButtonProps:I}=(0,c.useButton)({native:a,disabled:R}),{mounted:T,transitionStatus:O,setMounted:A}=(0,v.useTransitionStatus)(E),P={disabled:R,visible:E,open:x,transitionStatus:O};(0,b.useOpenChangeComplete)({open:E,ref:p.context.clearRef,onComplete(){E||A(!1)}});let N=(0,s.useRenderElement)("button",e,{state:P,ref:[t,w,p.context.clearRef],props:[{tabIndex:-1,children:"x",onMouseDown(e){e.preventDefault()},onClick(e){if(R||h)return;let t=p.context.keyboardActiveRef.current?M.REASONS.keyboard:M.REASONS.pointer;p.context.setInputValue("",(0,k.createChangeEventDetails)(M.REASONS.clearPress,e.nativeEvent)),"none"!==m?(p.context.setSelectedValue(Array.isArray(y)?[]:null,(0,k.createChangeEventDetails)(M.REASONS.clearPress,e.nativeEvent)),p.context.setIndices({activeIndex:null,selectedIndex:null,type:t})):p.context.setIndices({activeIndex:null,type:t}),p.context.inputRef.current?.focus()}},d,I],stateAttributesMapping:V});return l||T?N:null});e.s(["ComboboxClear",0,_],17088)},94268,31375,47018,13735,72441,83122,97464,69534,22994,93798,e=>{"use strict";var t=e.i(71645),n=e.i(52245),r=e.i(69690),i=e.i(75812),o=e.i(97886),s=e.i(50001),a=e.i(2672);let l=t.forwardRef(function(e,t){let{render:l,className:u,style:c,...d}=e;delete d.id;let f=(0,r.useFieldRootContext)(),p=(0,a.useComboboxRootContext)(),m=p.useState("inputInsidePopup"),g=p.useState("triggerElement");p.useState("inputElement");let h=p.useState("id"),v=(0,s.getDefaultLabelId)(h),b=g?.id??(m?h:void 0),x=(0,o.useLabel)({id:v,fallbackControlId:b,setLabelId(e){let t="function"==typeof e?e(p.state.labelId):e;p.set("labelId",t)}});return(0,n.useRenderElement)("div",e,{ref:t,state:f.state,props:[x,d],stateAttributesMapping:i.fieldValidityMapping})});e.s(["ComboboxLabel",0,l],94268);var u=e.i(42191),c=e.i(43476);e.s(["ComboboxValue",0,function(e){let{children:n,placeholder:r}=e,i=(0,a.useComboboxRootContext)(),o=i.useState("itemToStringLabel"),s=i.useState("selectedValue"),l=i.useState("items"),d="multiple"===i.useState("selectionMode"),f=i.useState("hasSelectedValue"),p=i.useState("hasNullItemLabel",!f&&null!=r&&null==n),m=null;return m="function"==typeof n?n(s):null!=n?n:f||null==r||p?d&&Array.isArray(s)?(0,u.resolveMultipleLabels)(s,l,o):(0,u.resolveSelectedLabel)(s,l,o):r,(0,c.jsx)(t.Fragment,{children:m})}],31375);var d=e.i(67865),f=e.i(28744),p=e.i(88015),m=e.i(79938),g=e.i(45147);g.CommonTriggerDataAttributes.popupOpen,g.CommonTriggerDataAttributes.pressed;let h={...m.pressableTriggerOpenStateMapping,...i.fieldValidityMapping,popupSide:e=>e?{"data-popup-side":e}:null,listEmpty:e=>e?{"data-list-empty":""}:null};e.s(["triggerStateAttributesMapping",0,h],47018);var v=e.i(47778);let b=t.createContext(void 0);function x(){return t.useContext(b)}e.s(["ComboboxChipsContext",0,b,"useComboboxChipsContext",0,x],13735);var y=e.i(57940),S=e.i(33332);let C=t.createContext(void 0);function E(e){let n=t.useContext(C);if(void 0===n&&!e)throw Error((0,S.default)(21));return n}e.s(["ComboboxPositionerContext",0,C,"useComboboxPositionerContext",0,E],72441);var R=e.i(75606),w=e.i(56434),I=e.i(72855),T=e.i(28918),O=e.i(2077),k=e.i(40886);let M=t.forwardRef(function(e,t){let n=(0,a.useComboboxRootContext)(),{buttonRef:r,getButtonProps:i}=(0,k.useButton)({native:!1}),o=(0,T.useMergedRefs)(t,r),s=i({onClick:function(e){n.context.setOpen(!1,(0,R.createChangeEventDetails)(w.REASONS.closePress,e.nativeEvent,e.currentTarget))}});return(0,c.jsx)("span",{ref:o,...s,"aria-label":"Dismiss",tabIndex:void 0,style:O.visuallyHiddenInput})});function A(e){let t=e.useState("mounted"),n=e.useState("popupSide"),r=e.useState("positionerElement");return t&&r?n:null}function P(){return 0===(0,a.useComboboxDerivedItemsContext)().filteredItems.length}function N(e){return"rtl"===e?["ArrowRight","ArrowLeft"]:["ArrowLeft","ArrowRight"]}function j(e,t){let n=e>=t-1?t-2:e;return n>=0?n:void 0}function L(e,t,n){let r=e.context.listRef.current[t];r&&(e.context.selectionEventRef.current=n,r.click(),e.context.selectionEventRef.current=null)}e.s(["ComboboxInternalDismissButton",0,M],83122),e.s(["clickHighlightedItem",0,L,"getChipNavigationKeys",0,N,"getIndexAfterChipRemoval",0,j,"useListEmpty",0,P,"usePopupSide",0,A],97464);let D=t.forwardRef(function(e,o){let{render:s,className:l,disabled:u=!1,id:m,style:g,...b}=e,{state:S,disabled:C,setTouched:T,setFocused:O,validationMode:k,validation:D}=(0,r.useFieldRootContext)(),{labelId:z}=(0,v.useLabelableContext)(),F=x(),H=!!E(!0),V=(0,a.useComboboxRootContext)(),_=(0,a.useComboboxInputValueContext)(),B=(0,I.useDirection)(),q=V.useState("required"),W=V.useState("disabled"),$=V.useState("readOnly"),U=V.useState("name"),K=V.useState("form"),G=V.useState("selectionMode"),Y=V.useState("autoHighlight"),Q=V.useState("inputProps"),X=V.useState("triggerProps"),J=V.useState("open"),Z=V.useState("mounted"),ee=V.useState("selectedValue"),et=V.useState("id"),en=V.useState("inline"),er=V.useState("modal"),ei=!!Y,eo=A(V),es=C||W||u,ea=P(),el=H||en,eu=(0,p.useBaseUiId)(m??(el?void 0:et)),ec=H?i.DEFAULT_FIELD_STATE_ATTRIBUTES:S,[ed,ef]=t.useState(null),ep=t.useRef(!1),em=t.useRef(null),eg=t.useRef(!1),eh="none"===G&&!H,ev=(0,d.useStableCallback)(e=>{let t=H||V.state.inline;t&&!V.state.hasInputValue&&V.context.setInputValue("",(0,R.createChangeEventDetails)(w.REASONS.none)),V.update({inputElement:e,inputInsidePopup:t,inputOwnsFormValue:eh})}),eb=H?b:D.getValidationProps(es,b);function ex(){V.context.setIndices({activeIndex:null,selectedIndex:null,type:V.context.keyboardActiveRef.current?w.REASONS.keyboard:w.REASONS.pointer})}function ey(){V.context.keyboardActiveRef.current=!1}let eS={...ec,open:J,disabled:es,readOnly:$,popupSide:eo,listEmpty:ea},eC=(0,n.useRenderElement)("input",e,{state:eS,ref:[o,V.context.inputRef,ev],props:[Q,X,{value:ed??_,"aria-readonly":$||void 0,"aria-required":q||void 0,"aria-labelledby":z,disabled:es,readOnly:$,required:"none"===G?q:void 0,form:K,...eh&&U&&{name:U},id:eu,onFocus(){if(O(!0),!en||!eg.current)return;eg.current=!1;let e=em.current;null!=e&&Object.hasOwn(V.context.valuesRef.current,e)&&V.context.setIndices({activeIndex:e})},onBlur(){T(!0),O(!1);let e=V.state.activeIndex;if(en&&null!==e&&"always"!==Y&&(em.current=e,eg.current=!0,V.context.setIndices({activeIndex:null})),"onBlur"===k){let e="none"===G?_:ee;D.commit(e)}},onCompositionStart(e){f.platform.os.android||(ep.current=!0,ef(e.currentTarget.value))},onCompositionEnd(e){ep.current=!1;let t=e.currentTarget.value;ef(null),V.context.setInputValue(t,(0,R.createChangeEventDetails)(w.REASONS.inputChange,e.nativeEvent))},onChange(e){let t=e.nativeEvent,n=t.inputType,r=ep.current||!(!n||"insertReplacementText"===n);function i(e){!$&&!es&&e&&r&&(V.context.setOpen(!0,(0,R.createChangeEventDetails)(w.REASONS.inputChange,t)),ei||ex())}if(ep.current){let n=e.currentTarget.value;ef(n),""!==n||V.state.openOnInputClick||V.state.inputInsidePopup||V.context.setOpen(!1,(0,R.createChangeEventDetails)(w.REASONS.inputClear,t));let r=n.trim(),o=ei&&""!==r;i(r),J&&null!==V.state.activeIndex&&!o&&ex();return}let o=(0,R.createChangeEventDetails)(w.REASONS.inputChange,t);if(V.context.setInputValue(e.currentTarget.value,o),o.isCanceled)return;let s=""===e.currentTarget.value,a=(0,R.createChangeEventDetails)(w.REASONS.inputClear,t);s&&!V.state.inputInsidePopup&&("single"===G&&V.context.setSelectedValue(null,a),V.state.openOnInputClick||V.context.setOpen(!1,a)),i(e.currentTarget.value.trim()),J&&null!==V.state.activeIndex&&!ei&&ex()},onKeyDown(e){if(e.ctrlKey||e.shiftKey||e.altKey||e.metaKey)return;if(V.context.keyboardActiveRef.current=!0,es||$){$&&"Enter"===e.key&&J&&null!==V.state.activeIndex&&(0,y.stopEvent)(e);return}let t=e.currentTarget,n=t.scrollWidth-t.clientWidth,r="rtl"===B;if("Home"===e.key){(0,y.stopEvent)(e);let n=f.platform.engine.gecko&&r?t.value.length:0;t.setSelectionRange(n,n),t.scrollLeft=0;return}if("End"===e.key){(0,y.stopEvent)(e);let i=f.platform.engine.gecko&&r?0:t.value.length;t.setSelectionRange(i,i),t.scrollLeft=r?-n:n;return}if(!Z&&"Escape"===e.key){let t="multiple"===G&&Array.isArray(ee)?0===ee.length:null===ee,n=(0,R.createChangeEventDetails)(w.REASONS.escapeKey,e.nativeEvent);V.context.setInputValue("",n),V.context.setSelectedValue("multiple"===G?[]:null,n),t||V.state.inline||n.isPropagationAllowed||e.stopPropagation();return}if(F&&"Backspace"===e.key&&""===t.value&&void 0===F.highlightedChipIndex&&Array.isArray(ee)&&ee.length>0){let t=F.chipsRef.current.length,n=t>0?t-1:ee.length-1,r=ee.filter((e,t)=>t!==n);ex(),V.context.setSelectedValue(r,(0,R.createChangeEventDetails)(w.REASONS.none,e.nativeEvent));return}let i=F?.highlightedChipIndex!==void 0,o=function(e){let t;if(!F)return;let{highlightedChipIndex:n}=F,r=F.chipsRef.current.length,[i,o]=N(B);return void 0!==n?e.key===i?(e.preventDefault(),t=n>0?n-1:void 0):e.key===o?(e.preventDefault(),t=n<r-1?n+1:void 0):("Backspace"===e.key||"Delete"===e.key)&&(e.preventDefault(),t=j(n,ee.length),ex()):e.key===i&&(e.currentTarget.selectionStart??0)===0&&ee.length>0&&(e.preventDefault(),t=r>0?r-1:void 0),t}(e);if(F?.setHighlightedChipIndex(o),void 0!==o?F?.chipsRef.current[o]?.focus():i&&V.context.inputRef.current?.focus(),229!==e.which&&"Enter"===e.key&&J){let t=V.state.activeIndex,n=e.nativeEvent;if(null===t){if(en)return;V.context.setOpen(!1,(0,R.createChangeEventDetails)(w.REASONS.none,n));return}(0,y.stopEvent)(e),L(V,t,n)}},onPointerMove:ey,onPointerDown:ey},eb],stateAttributesMapping:h}),eE=H?(0,c.jsx)(r.FieldRootContext.Provider,{value:r.DEFAULT_FIELD_ROOT_CONTEXT,children:eC}):eC;return(0,c.jsxs)(t.Fragment,{children:[J&&(!el||er)&&(0,c.jsx)(M,{ref:V.context.startDismissRef}),eE]})});e.s(["ComboboxInput",0,D],69534);var z=e.i(29315),F=e.i(84446),H=e.i(96296);function V(e,t,n,r){if(e.baseUIHandlerPrevented)return;let i=(0,F.getTarget)(e.nativeEvent),o=(0,z.isElement)(i)?i:null;o!==e.currentTarget&&(r?.(o)||(0,H.isInteractiveElement)(o))||(e.preventDefault(),!n&&(t.context.inputRef.current?.focus(),t.state.openOnInputClick&&t.context.setOpen(!0,(0,R.createChangeEventDetails)(w.REASONS.inputPress,e.nativeEvent))))}e.s(["handleInputPress",0,V],22994);let _=t.forwardRef(function(e,t){let{render:i,className:o,style:s,...l}=e,{state:u}=(0,r.useFieldRootContext)(),c=(0,a.useComboboxRootContext)(),f=c.useState("open"),p=c.useState("disabled"),m=c.useState("readOnly"),g=c.useState("hasSelectedValue"),v=c.useState("selectionMode"),b=A(c),x=P(),y={...u,open:f,disabled:p,readOnly:m,popupSide:b,listEmpty:x,placeholder:"none"!==v&&!g},S=(0,d.useStableCallback)(e=>{c.set("inputGroupElement",e)});return(0,n.useRenderElement)("div",e,{ref:[t,S],props:[{role:"group",onMouseDown(e){V(e,c,p,e=>(0,F.contains)(c.context.chipsContainerRef.current,e))}},l],state:y,stateAttributesMapping:h})});e.s(["ComboboxInputGroup",0,_],93798)},5627,31766,24889,78076,89102,18118,e=>{"use strict";var t=e.i(71645),n=e.i(67865),r=e.i(52245),i=e.i(2672),o=e.i(72441),s=e.i(87445),a=e.i(53687),l=e.i(57940),u=e.i(97464),c=e.i(43476);let d=t.forwardRef(function(e,d){var f;let{render:p,className:m,style:g,children:h,...v}=e,b=(0,i.useComboboxRootContext)(),x=(0,i.useComboboxFloatingContext)(),y=!!(0,o.useComboboxPositionerContext)(!0),{filteredItems:S,hasItems:C}=(0,i.useComboboxDerivedItemsContext)(),E=b.useState("selectionMode"),R=b.useState("grid"),w=b.useState("readOnly"),I=b.useState("listProps"),T=b.useState("virtualized"),O=b.useState("forceMounted"),k=0===S.length,M=(0,n.useStableCallback)(e=>{b.set("positionerElement",e)}),A=(0,n.useStableCallback)(e=>{b.set("listElement",e)}),P=t.useMemo(()=>"function"==typeof h?f||(f=(0,c.jsx)(s.ComboboxCollection,{children:h})):h,[h]),N=x.useState("floatingId"),j=(0,r.useRenderElement)("div",e,{state:{empty:k},ref:[d,A,y?null:M],props:[I,{children:P,tabIndex:-1,id:N,role:R?"grid":"listbox","aria-multiselectable":"multiple"===E?"true":void 0,"aria-readonly":!R&&!!w||void 0,onKeyDown(e){if(!b.state.disabled&&!b.state.readOnly&&"Enter"===e.key){let t=b.state.activeIndex;null!=t&&((0,l.stopEvent)(e),(0,u.clickHighlightedItem)(b,t,e.nativeEvent))}},onKeyDownCapture(){b.context.keyboardActiveRef.current=!0},onPointerMoveCapture(){b.context.keyboardActiveRef.current=!1}},v]});if(T)return j;let L=C&&!O?void 0:b.context.labelsRef;return(0,c.jsx)(a.CompositeList,{elementsRef:b.context.listRef,labelsRef:L,children:j})});e.s(["ComboboxList",0,d],5627);var f=e.i(28744),p=e.i(39957);function m(){let e=(0,p.useTimeout)(),n=t.useRef(null);return t.useEffect(()=>{if(f.platform.os.ios)return;let t=n.current;if(null==t)return;let r=function(e){let t=e.ownerDocument.createTreeWalker(e,NodeFilter.SHOW_TEXT),n=null;for(;t.nextNode();){let e=t.currentNode;""!==e.nodeValue&&(n=e)}return n}(t);if(null==r)return;let i=r.data,o=`${i}\u2060`;return r.nodeValue=o,e.start(200,()=>{r.nodeValue===o&&(r.nodeValue=i)}),()=>{e.clear(),r.nodeValue===o&&(r.nodeValue=i)}},[n,e]),n}e.s(["useInitialLiveRegionTextMutation",0,m],31766);let g=t.forwardRef(function(e,t){let{render:n,className:i,style:o,children:s,...a}=e,l=m();return(0,r.useRenderElement)("div",e,{ref:[t,l],props:[{children:s,role:"status","aria-live":"polite","aria-atomic":!0},a]})});e.s(["ComboboxStatus",0,g],24889);var h=e.i(26674),v=e.i(33332);let b=t.createContext(void 0);e.s(["ComboboxPortalContext",0,b,"useComboboxPortalContext",0,function(){let e=t.useContext(b);if(void 0===e)throw Error((0,v.default)(20));return e}],78076);let x=t.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e,o=(0,i.useComboboxRootContext)(),s=o.useState("mounted"),a=o.useState("forceMounted");return s||n||a?(0,c.jsx)(b.Provider,{value:n,children:(0,c.jsx)(h.FloatingPortal,{ref:t,...r})}):null});e.s(["ComboboxPortal",0,x],89102);var y=e.i(79938),S=e.i(74354);let C={...y.popupStateMapping,...S.transitionStatusMapping},E=t.forwardRef(function(e,t){let{render:n,className:o,style:s,...a}=e,l=(0,i.useComboboxRootContext)(),u=l.useState("open"),c=l.useState("mounted"),d=l.useState("transitionStatus");return(0,r.useRenderElement)("div",e,{state:{open:u,transitionStatus:d},ref:t,stateAttributesMapping:C,props:[{role:"presentation",hidden:!c,style:{userSelect:"none",WebkitUserSelect:"none"}},a]})});e.s(["ComboboxBackdrop",0,E],18118)},98108,60375,37642,54463,111,36760,e=>{"use strict";var t=e.i(71645),n=e.i(46376),r=e.i(67865),i=e.i(44394),o=e.i(2672),s=e.i(72441),a=e.i(97464),l=e.i(23706),u=e.i(78076),c=e.i(38396),d=e.i(426),f=e.i(89579),p=e.i(33383),m=e.i(43476);let g=t.forwardRef(function(e,t){let{render:g,className:h,anchor:v,positionMethod:b,side:x,align:y,sideOffset:S,alignOffset:C,collisionBoundary:E="clipping-ancestors",collisionPadding:R,arrowPadding:w,sticky:I,disableAnchorTracking:T=!1,collisionAvoidance:O=c.DROPDOWN_COLLISION_AVOIDANCE,style:k,...M}=e,A=(0,o.useComboboxRootContext)(),P=(0,o.useComboboxFloatingContext)(),N=(0,u.useComboboxPortalContext)(),j=A.useState("modal"),L=A.useState("open"),D=A.useState("mounted"),z=A.useState("openMethod"),F=A.useState("positionerElement"),H=A.useState("triggerElement"),V=A.useState("inputElement"),_=A.useState("inputGroupElement"),B=A.useState("inputInsidePopup"),q=A.useState("transitionStatus"),W=(0,a.useListEmpty)(),$=(0,l.useAnchorPositioning)({anchor:v??(B?H:_??V),floatingRootContext:P,positionMethod:b,mounted:D,side:x,sideOffset:S,align:y,alignOffset:C,arrowPadding:w,collisionBoundary:E,collisionPadding:R,sticky:I,disableAnchorTracking:T,keepMounted:N,collisionAvoidance:O,lazyFlip:!0});(0,p.useAnchoredPopupScrollLock)(L&&j,"touch"===z,F,H);let U={open:L,side:$.side,align:$.align,anchorHidden:$.anchorHidden,empty:W};(0,n.useIsoLayoutEffect)(()=>{A.set("popupSide",$.side)},[A,$.side]);let K=(0,r.useStableCallback)(e=>{A.set("positionerElement",e)}),G=(0,f.usePositioner)(e,U,{styles:$.positionerStyles,transitionStatus:q,props:M,refs:[t,K],hidden:!D,inert:!L});return(0,m.jsxs)(s.ComboboxPositionerContext.Provider,{value:$,children:[D&&j&&(0,m.jsx)(d.InternalBackdrop,{inert:(0,i.inertValue)(!L),cutout:_??V??H}),G]})});e.s(["ComboboxPositioner",0,g],98108);var h=e.i(61487),v=e.i(52245),b=e.i(79938),x=e.i(37584),y=e.i(74354),S=e.i(84446),C=e.i(53984),E=e.i(83122),R=e.i(36523);let w={...b.popupStateMapping,...y.transitionStatusMapping},I=t.forwardRef(function(e,r){let{render:i,className:l,style:u,initialFocus:c,finalFocus:d,...f}=e,p=(0,o.useComboboxRootContext)(),g=(0,s.useComboboxPositionerContext)(),b=(0,o.useComboboxFloatingContext)(),y=p.useState("mounted"),I=p.useState("open"),T=p.useState("openMethod"),O=p.useState("popupProps"),k=p.useState("transitionStatus"),M=p.useState("inputInsidePopup"),A=p.useState("inputElement"),P=p.useState("modal"),N=p.useState("id"),j=(0,a.useListEmpty)(),L=f.id??(M?(0,R.getComboboxPopupId)(N):void 0);(0,n.useIsoLayoutEffect)(()=>(p.set("popupId",p.context.popupRef.current?.id||L),()=>{p.set("popupId",void 0)}),[p,L]),(0,x.useOpenChangeComplete)({open:I,ref:p.context.popupRef,onComplete(){I&&p.context.onOpenChangeComplete(!0)}});let D={open:I,side:g.side,align:g.align,anchorHidden:g.anchorHidden,transitionStatus:k,empty:j},z=(0,v.useRenderElement)("div",e,{state:D,ref:[r,p.context.popupRef],props:[O,{id:L,role:M?"dialog":"presentation",onFocus(e){let t=(0,S.getTarget)(e.nativeEvent);"touch"!==T&&((0,S.contains)(p.state.listElement,t)||t===e.currentTarget)&&p.context.inputRef.current?.focus()}},(0,C.getDisabledMountTransitionStyles)(k),f],stateAttributesMapping:w}),F=!!M&&(e=>"touch"===e?p.context.popupRef.current:A),H=!M||P;return(0,m.jsx)(h.FloatingFocusManager,{context:b,disabled:!y,modal:H,openInteractionType:T,initialFocus:void 0===c?F:c,returnFocus:null!=d?d:!!M&&void 0,getInsideElements:()=>[p.context.startDismissRef.current,p.context.endDismissRef.current],children:(0,m.jsxs)(t.Fragment,{children:[z,H&&(0,m.jsx)(E.ComboboxInternalDismissButton,{ref:p.context.endDismissRef})]})})});e.s(["ComboboxPopup",0,I],60375);let T=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...a}=e,l=(0,o.useComboboxRootContext)(),{arrowRef:u,side:c,align:d,arrowUncentered:f,arrowStyles:p}=(0,s.useComboboxPositionerContext)(),m=l.useState("open");return(0,v.useRenderElement)("div",e,{ref:[u,t],stateAttributesMapping:b.popupStateMapping,state:{open:m,side:c,align:d,uncentered:f},props:{style:p,"aria-hidden":!0,...a}})});e.s(["ComboboxArrow",0,T],37642);let O=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...o}=e;return(0,v.useRenderElement)("span",e,{ref:t,props:[{"aria-hidden":!0,children:"▼"},o]})});e.s(["ComboboxIcon",0,O],54463);var k=e.i(33332);let M=t.createContext(void 0);var A=e.i(76459);let P=t.forwardRef(function(e,n){let{render:r,className:i,style:s,items:a,...l}=e,u=(0,o.useComboboxRootContext)().useState("grid"),[c,d]=t.useState(),f=t.useMemo(()=>({labelId:c,setLabelId:d,items:a}),[c,d,a]),p=(0,v.useRenderElement)("div",e,{ref:n,props:[{role:u?"rowgroup":"group","aria-labelledby":c},l]}),g=(0,m.jsx)(M.Provider,{value:f,children:p});return a?(0,m.jsx)(A.GroupCollectionProvider,{items:a,children:g}):g});e.s(["ComboboxGroup",0,P],111);var N=e.i(88015);let j=t.forwardRef(function(e,r){let{render:i,className:o,style:s,id:a,...l}=e,{setLabelId:u}=function(){let e=t.useContext(M);if(void 0===e)throw Error((0,k.default)(18));return e}(),c=(0,N.useBaseUiId)(a);return(0,n.useIsoLayoutEffect)(()=>(u(c),()=>{u(e=>e===c?void 0:e)}),[c,u]),(0,v.useRenderElement)("div",e,{ref:r,props:[{id:c,"aria-hidden":!0},l]})});e.s(["ComboboxGroupLabel",0,j],36760)},45654,91786,e=>{"use strict";var t=e.i(71645),n=e.i(33332),r=e.i(51437),i=e.i(46376),o=e.i(13203),s=e.i(67865),a=e.i(28918),l=e.i(46265),u=e.i(2077),c=e.i(88940),d=e.i(26352),f=e.i(56789),p=e.i(29315),m=e.i(17989),g=e.i(65858),h=e.i(60891),v=e.i(85689),b=e.i(64132),x=e.i(84446),y=e.i(75606),S=e.i(56434),C=e.i(2672),E=e.i(62156),R=e.i(37584),w=e.i(69690),I=e.i(81104),T=e.i(84708),O=e.i(38489),k=e.i(36523),M=e.i(56970),A=e.i(23910),P=e.i(32199),N=e.i(96545),j=e.i(6039),L=e.i(64111),D=e.i(76782),z=e.i(42191),F=e.i(84325),H=e.i(61919),V=e.i(72855);function _(e,t,n){let r=e.get(t);if(void 0!==r||n===F.defaultItemEquality)return r;for(let[r,i]of e)if((0,F.compareItemEquality)(r,t,n))return i}e.s(["findCollectionItem",0,_],91786);var B=e.i(43476);function q(e){let q,{id:W,onOpenChangeComplete:$,defaultSelectedValue:U=null,selectedValue:K,onSelectedValueChange:G,defaultInputValue:Y,inputValue:Q,open:X,defaultOpen:J=!1,selectionMode:Z,onItemHighlighted:ee,name:et,form:en,disabled:er=!1,readOnly:ei=!1,required:eo=!1,inputRef:es,grid:ea=!1,items:el,filteredItems:eu,filter:ec,filterQuery:ed,openOnInputClick:ef=!0,autoHighlight:ep=!1,keepHighlight:em=!1,highlightItemOnHover:eg=!0,loopFocus:eh=!0,itemToStringLabel:ev,itemToStringValue:eb,isItemEqualToValue:ex=F.defaultItemEquality,virtualized:ey=!1,inline:eS=!1,fillInputOnItemPress:eC=!0,modal:eE=!1,limit:eR=-1,autoComplete:ew="list",formAutoComplete:eI,locale:eT,submitOnItemClick:eO=!1}=e,{clearErrors:ek}=(0,T.useFormContext)(),{setDirty:eM,validityData:eA,setFilled:eP,name:eN,disabled:ej,setTouched:eL,setFocused:eD,validationMode:ez,validation:eF}=(0,w.useFieldRootContext)(),eH=(0,V.useDirection)(),eV=(0,O.useLabelableId)({id:W}),e_=(0,M.useCoreFilter)({locale:eT}),eB=Array.isArray(el)?null:el;if(eB&&"function"!=typeof eB.label)throw Error((0,n.default)(100));let eq=eB?eB.data:el,eW=eB?.value,e$=eW?void 0:eq,eU=t.useMemo(()=>{let e;if(!eu||!eW)return;let t=(0,z.flattenLeafItems)(eu),n=t.map(eW);return{values:n,findItem(r,i){if(!e){e=new Map;for(let r=0;r<n.length;r+=1)e.has(n[r])||e.set(n[r],t[r])}return _(e,r,i)}}},[eu,eW]),eK=t.useMemo(()=>eB?e=>eB.label(e,ex,e=>{let t=eU?.findItem(e,ex);return null!=t?eB.itemLabel(t):(0,z.stringifyAsLabel)(e,ev)}):ev,[eB,ev,eU,ex]),eG=t.useMemo(()=>eB?Object.assign(e=>eB.itemLabel(e),{selected:e=>(0,z.stringifyAsLabel)(e,eK)}):ev,[eB,eK,ev]);function eY(e){return(0,z.stringifyAsLabel)(e,eK)}let[eQ,eX]=t.useState(!1),[eJ,eZ]=t.useState(null),e0=t.useRef(eJ),e1=t.useRef([]),e4=t.useRef([]),e2=t.useRef(null),e6=t.useRef(null),e5=t.useRef(null),e7=t.useRef(null),e3=t.useRef(null),e8=t.useRef(!0),e9=t.useRef(!1),te=t.useRef(null),tt=t.useRef(null),tn=t.useRef(null),tr=t.useRef(H.INITIAL_LAST_HIGHLIGHT),ti=t.useRef(null),to=t.useRef([]),ts=t.useRef(null),ta=ej||er,tl=eN??et,tu="multiple"===Z,tc="single"===Z,td=void 0!==Q||void 0!==Y,tf=void 0!==eq,tp=void 0!==eu;q="always"===ep?"always":!!ep&&"input-change";let[tm,tg]=(0,r.useControlled)({controlled:K,default:tu?U??f.EMPTY_ARRAY:U,name:"Combobox",state:"selectedValue"}),th=t.useMemo(()=>null===ec?()=>!0:void 0!==ec?ec:(0,k.createCollatorItemFilter)(e_,eG),[ec,e_,eG]),tv=(0,c.useRefWithInit)(()=>td?Y??"":tc?eY(tm):"").current,[tb,tx]=(0,r.useControlled)({controlled:Q,default:tv,name:"Combobox",state:"inputValue"}),[ty,tS]=(0,r.useControlled)({controlled:X,default:J,name:"Combobox",state:"open"}),tC=(0,z.isGroupedItems)(eq),tE=ty||null===eJ?String(tb).trim():eJ,tR=tc?eY(tm):"",tw=tc&&!eQ&&""!==tE&&tR.length===tE.length&&e_.contains(tR,tE),tI=tw?"":ed??tE,tT=tf&&tp&&tw&&(!eB||eB.hasValue(tm,ex)),tO=t.useMemo(()=>eq?(0,z.flattenLeafItems)(eq):f.EMPTY_ARRAY,[eq]),tk=t.useMemo(()=>{if(eu&&!tT)return eu;if(!eq)return f.EMPTY_ARRAY;if(tC){let e=[],t=0;for(let n of eq){if(eR>-1&&t>=eR)break;let r=eR>-1?eR-t:1/0,i=""===tI?n.items.slice(0,r):[];if(""!==tI)for(let e of n.items){if(i.length>=r)break;th(e,tI,eG)&&i.push(e)}if(i.length>0){let r={...n,items:i};e.push(r),t+=i.length}}return e}if(""===tI)return eR>-1?tO.slice(0,eR):tO;let e=[];for(let t of tO){if(eR>-1&&e.length>=eR)break;th(t,tI,eG)&&e.push(t)}return e},[eu,tT,eq,tC,tI,eR,th,eG,tO]),tM=t.useMemo(()=>{if(eU&&tk===eu)return eU.values;let e=(0,z.flattenLeafItems)(tk);return eW?e.map(e=>eW(e)):e},[tk,eu,eU,eW]),tA=(0,c.useRefWithInit)(()=>{let e=null;return eS&&ty&&tf&&"none"!==Z&&(e=(0,F.findSelectionIndex)(tM,tm,ex,tu)),new d.ReactStore({id:eV,labelId:void 0,selectedValue:tm,open:ty,items:e$,selectionMode:Z,name:tl,form:en,disabled:ta,readOnly:ei,required:eo,grid:ea,virtualized:ey,openOnInputClick:ef,itemToStringLabel:eK,isItemEqualToValue:ex,modal:eE,autoHighlight:q,submitOnItemClick:eO,hasInputValue:td,mounted:!1,forceMounted:!1,transitionStatus:"idle",inline:eS,activeIndex:null,selectedIndex:e,popupProps:{},listProps:{},inputProps:{},triggerProps:{},itemProps:f.EMPTY_OBJECT,positionerElement:null,listElement:null,popupId:void 0,triggerElement:null,inputElement:null,inputGroupElement:null,popupSide:null,openMethod:null,inputInsidePopup:!0,inputOwnsFormValue:"none"===Z},{onOpenChangeComplete:f.NOOP,setOpen:f.NOOP,setInputValue:f.NOOP,setSelectedValue:f.NOOP,setIndices:f.NOOP,handleSelection:f.NOOP,forceMount:f.NOOP,requestSubmit:f.NOOP,listRef:e1,labelsRef:e4,popupRef:e2,emptyRef:e3,inputRef:e6,startDismissRef:e5,endDismissRef:e7,keyboardActiveRef:e8,chipsContainerRef:te,clearRef:tt,valuesRef:to,pointerDownItemRef:ts,selectionEventRef:tn},E.selectors)}).current,tP="none"===Z?tb:tm,tN=t.useMemo(()=>"none"===Z?tP:Array.isArray(tm)?tm.map(e=>(0,z.stringifyAsValue)(e,eb)):(0,z.stringifyAsValue)(tm,eb),[tP,eb,Z,tm]),tj=(0,s.useStableCallback)(ee),tL=(0,s.useStableCallback)($),tD=tA.useState("activeIndex"),tz=tA.useState("selectedIndex"),tF=tA.useState("positionerElement"),tH=tA.useState("listElement"),tV=tA.useState("triggerElement"),t_=tA.useState("inputElement"),tB=tA.useState("inputGroupElement"),tq=tA.useState("inline"),tW=tA.useState("inputInsidePopup"),t$=tA.useState("inputOwnsFormValue"),tU=tc&&!tW&&tb===tR,tK=(0,l.useValueAsRef)(tV),{mounted:tG,setMounted:tY,transitionStatus:tQ}=(0,A.useTransitionStatus)(ty),{openMethod:tX,triggerProps:tJ}=(0,P.useOpenInteractionType)(ty),tZ=(0,s.useStableCallback)(()=>tN);(0,I.useRegisterFieldControl)(tW?tK:e6,eV,tP,tZ,!ta,et);let t0=(0,s.useStableCallback)(()=>{eq?e4.current=tM.map(eY):tA.set("forceMounted",!0)}),t1=(0,s.useStableCallback)((e,t,n)=>{if(-1===t){if(tr.current===H.INITIAL_LAST_HIGHLIGHT)return;tr.current=H.INITIAL_LAST_HIGHLIGHT}else tr.current={value:e,index:t};tj(e,(0,y.createGenericEventDetails)(n,void 0,{index:t}))}),t4=(0,s.useStableCallback)(e=>{let t={};void 0!==e.activeIndex&&(t.activeIndex=e.activeIndex),void 0!==e.selectedIndex&&(t.selectedIndex=e.selectedIndex),tA.update(t);let n=e.activeIndex;if(void 0===n)return;let r=e.type||S.REASONS.none;null===n?t1(void 0,-1,r):t1(to.current[n],n,r)}),t2=(0,s.useStableCallback)((t,n)=>{if(e.onInputValueChange?.(t,n),!n.isCanceled){if(e9.current=n.reason===S.REASONS.inputClear,n.reason===S.REASONS.inputChange){ty&&null!==eJ&&eZ(null);let e=n.event,r=e.inputType;if("compositionend"===e.type||null!=r&&""!==r&&"insertReplacementText"!==r){let e=""!==t.trim();e&&eX(!0),ti.current={hasQuery:e};let n=tA.state.listElement;if(!tA.state.virtualized&&n){let e=e2.current;for(let t of(0,p.getOverflowAncestors)(n.firstElementChild??n)){if(!(0,p.isHTMLElement)(t)||(e?!(0,x.contains)(e,t):"dialog"===t.getAttribute("role")))break;if((0,N.isScrollableY)(t)){t.scrollTop=0;break}}}e&&q&&null==tA.state.activeIndex&&(ty||tq)&&tA.set("activeIndex",0)}}else n.reason===S.REASONS.inputClear&&""===t&&tA.state.inputInsidePopup&&(ti.current={hasQuery:!1,selection:!0});tx(t)}}),t6=(0,s.useStableCallback)(e=>{let t=!e&&tW&&!tq&&""!==tb&&(String(tb).trim()===eJ||tb===tR);!e&&(t||""===tb||tU)&&eX(!1),eZ(null),t&&t2("",(0,y.createChangeEventDetails)(S.REASONS.inputClear))}),t5=(0,s.useStableCallback)((t,n)=>{if(ty!==t&&(n.reason===S.REASONS.escapeKey&&tf&&0===tM.length&&!e3.current&&n.allowPropagation(),e.onOpenChange?.(t,n),!n.isCanceled&&(t&&null!==eJ&&t6(n.reason===S.REASONS.inputChange),!t&&eQ&&(tc?(tq||eZ(tE),""===tE&&eX(!1)):tu&&(tq||eZ(tE),tW&&t4({activeIndex:null}),(!tW||tq)&&t2("",(0,y.createChangeEventDetails)(S.REASONS.inputClear,n.event,void 0,{isItemPress:n.reason===S.REASONS.itemPress})))),tS(t),!t&&tW&&(n.reason===S.REASONS.focusOut||n.reason===S.REASONS.outsidePress))&&(eL(!0),eD(!1),"onBlur"===ez))){let e="none"===Z?tb:tm;eF.commit(e)}}),t7=(0,s.useStableCallback)((e,t)=>{G?.(e,t),t.isCanceled||(tg(e),("none"===Z&&e2.current&&eC||tc&&!tA.state.inputInsidePopup)&&t2(eY(e),(0,y.createChangeEventDetails)(t.reason,t.event)))}),t3=(0,s.useStableCallback)((e,t)=>{let n=(0,x.getTarget)(e),r=tn.current??e;tn.current=null;let i=(0,y.createChangeEventDetails)(S.REASONS.itemPress,r),o=n?.closest("a")?.getAttribute("href");if(o){o.startsWith("#")&&t5(!1,i);return}if(tu){let e=Array.isArray(tm)?tm:[],n=(0,F.selectedValueIncludes)(e,t,ex);if(t7(n?(0,F.removeItem)(e,t,ex):[...e,t],i),i.isCanceled||!(e6.current&&""!==e6.current.value.trim()))return;if(tA.state.inputInsidePopup){t2("",(0,y.createChangeEventDetails)(S.REASONS.inputClear,i.event,void 0,{isItemPress:!0}));let e=ti.current;e&&!n&&(e.toggledValue=t)}else t5(!1,i)}else{if(t7(t,i),i.isCanceled)return;t5(!1,i)}}),t8=(0,s.useStableCallback)(()=>{let e=eF.inputRef.current?.form??tA.state.inputElement?.form;e&&"function"==typeof e.requestSubmit&&e.requestSubmit()}),t9=(0,s.useStableCallback)(()=>{if(tY(!1),tL?.(!1),eX(!1),eZ(null),"none"===Z?t4({activeIndex:null,selectedIndex:null}):t4({activeIndex:null}),tu&&e6.current&&""!==e6.current.value&&!e9.current&&t2("",(0,y.createChangeEventDetails)(S.REASONS.inputClear)),tc)if(tA.state.inputInsidePopup)e6.current&&""!==e6.current.value&&t2("",(0,y.createChangeEventDetails)(S.REASONS.inputClear));else{let e=eY(tm);if(e6.current&&e6.current.value!==e){let t=""===e?S.REASONS.inputClear:S.REASONS.none;t2(e,(0,y.createChangeEventDetails)(t))}}}),ne=t.useMemo(()=>tq&&tF?{current:tF.closest('[role="dialog"]')}:e2,[tq,tF]);(0,R.useOpenChangeComplete)({enabled:!e.actionsRef,open:ty,ref:ne,onComplete(){ty||t9()}}),t.useImperativeHandle(e.actionsRef,()=>({unmount:t9}),[t9]),(0,i.useIsoLayoutEffect)(function(){let e=null!==e0.current&&null===eJ;if(e0.current=eJ,ty&&(!e||!tf)||(ty||(ts.current=null),"none"===Z))return;let t=tf?tM:to.current;t4({selectedIndex:(0,F.findSelectionIndex)(t,tm,ex,tu)})},[ty,eJ,tm,Z,tu,tf,tM,ex,t4]),(0,i.useIsoLayoutEffect)(()=>{eq&&(to.current=tM,e1.current.length=tM.length)},[eq,tM]),(0,i.useIsoLayoutEffect)(()=>{let e=ti.current;if(e){let t=ty||tq||tA.state.positionerElement?.hidden===!1;if(e.hasQuery)q&&t&&tA.set("activeIndex",0),ti.current=null;else if(""===String(tb).trim()&&(ti.current=null,t)){let t=e.selection;"always"!==q||t||"none"!==tA.state.selectionMode||tA.set("activeIndex",0),queueMicrotask(()=>{if(!tA.state.open&&!tA.state.inline||e6.current&&""!==e6.current.value.trim())return;let n=tA.state.selectedValue,r="multiple"===tA.state.selectionMode;if(r&&Array.isArray(n)?n.length>0:"none"!==tA.state.selectionMode&&null!=n){let t=tf||tp?tM:to.current,i=(0,F.findItemIndex)(t,e.toggledValue,tA.state.isItemEqualToValue);tA.set("activeIndex",-1!==i?i:(0,F.findSelectionIndex)(t,n,tA.state.isItemEqualToValue,r))}else t?tA.set("activeIndex",null):"always"===q&&tA.set("activeIndex",0)})}}if(!ty&&!tq)return;let t=tf||tp?tM:to.current,n=tA.state.activeIndex;if(null==n)return"always"===q&&t.length>0?void tA.set("activeIndex",0):void t1(void 0,-1,S.REASONS.none);if(n>=t.length){t1(void 0,-1,S.REASONS.none),tA.set("activeIndex",null);return}let r=t[n],i=tr.current.value,o=i!==H.NO_ACTIVE_VALUE&&(0,F.compareItemEquality)(r,i,tA.state.isItemEqualToValue);tr.current.index===n&&o||t1(r,n,S.REASONS.none)},[tD,q,t1,tp,tf,tM,tq,ty,tA,tb]),(0,i.useIsoLayoutEffect)(()=>{"none"===Z?eP(""!==String(tb)):eP(tu?Array.isArray(tm)&&tm.length>0:null!=tm)},[eP,Z,tb,tm,tu]),t.useEffect(()=>{tf&&q&&0===tM.length&&t4({activeIndex:null})},[tf,q,tM.length,t4]);let nt=!1;function nn(){nt||tb===tR||(nt=!0,t2(tR,(0,y.createChangeEventDetails)(S.REASONS.none)))}function nr(){!tc||td||tW||eQ||nn()}(0,j.useValueChanged)(tE,function(){ty&&""!==tE&&tE!==String(tv)&&!tU&&eX(!0)}),(0,j.useValueChanged)(ty,function(){ty&&null!==eJ&&t6(!1)}),(0,j.useValueChanged)(tm,function(){"none"!==Z&&(ek(tl),eM((0,F.isSelectedValueDirty)(tm,eA.initialValue,ex)),eF.change(tm),!tc||td||tW||nn())}),(0,j.useValueChanged)(tR,nr),(0,j.useValueChanged)(eq,nr),(0,j.useValueChanged)(tb,function(){"none"===Z&&(ek(tl),eM(tb!==eA.initialValue),eF.change(tb))});let ni=(0,g.useFloatingRootContext)({open:!!tq||ty,onOpenChange:t5,elements:{reference:tW?tV:t_,floating:tF}}),no=ea?"grid":"listbox",ns=ty||tq,na=ns?"true":"false",nl=t.useMemo(()=>{let e=t_?.tagName==="INPUT",t=null==t_||e,n=t||ns,r=t?{autoComplete:"off",spellCheck:"false",autoCorrect:"off",autoCapitalize:"none"}:{};return n&&(r.role="combobox",r["aria-expanded"]=na,r["aria-haspopup"]=no,r["aria-controls"]=ns?tH?.id:void 0,r["aria-autocomplete"]=ei?"none":ew),{reference:r,floating:{role:"presentation"}}},[t_,ns,na,no,tH?.id,ew,ei]),nu=(0,v.useClick)(ni,{enabled:!ta&&ef,event:"mousedown-only",toggle:!1,touchOpenDelay:100*!tW,reason:S.REASONS.inputPress}),nc=(0,m.useDismiss)(ni,{enabled:!ta&&!tq,outsidePressEvent:{mouse:"sloppy",touch:"intentional"},bubbles:!!tq||void 0,outsidePress(e){let t=(0,x.getTarget)(e);return!(0,x.contains)(tV,t)&&!(0,x.contains)(tt.current,t)&&!(0,x.contains)(te.current,t)&&!(0,x.contains)(tB,t)}}),nd=(0,h.useListNavigation)(ni,{enabled:!ta,id:eV,listRef:e1,activeIndex:tD,selectedIndex:tz,virtual:!0,loopFocus:eh,allowEscape:eh&&!q,focusItemOnOpen:!eQ&&("none"!==Z||!!q)&&"auto",focusItemOnHover:eg,resetOnPointerLeave:!em,orientation:ea?"horizontal":void 0,rtl:"rtl"===eH,disabledIndices:f.EMPTY_ARRAY,grid:ea?b.gridNavigation:void 0,onNavigate(e,t){(t||ty)&&"ending"!==tQ&&(t?t4({activeIndex:e,type:e8.current?S.REASONS.keyboard:S.REASONS.pointer}):t4({activeIndex:e}))}}),nf=t.useMemo(()=>(0,D.mergeProps)(nd.reference,{onKeyDown(e){ea&&null==tA.state.activeIndex&&("ArrowLeft"===e.key||"ArrowRight"===e.key)&&e.preventBaseUIHandler()}},nc.reference,nu.reference,nl.reference),[nd.reference,nc.reference,nu.reference,nl.reference,ea,tA]),np=t.useMemo(()=>(0,D.mergeProps)(L.FOCUSABLE_POPUP_PROPS,nc.floating),[nc.floating]),nm=t.useMemo(()=>(0,D.mergeProps)(nd.floating,nl.floating),[nd.floating,nl.floating]),ng=t.useMemo(()=>{let e=nd.item;return e?{...e,onFocus:void 0}:f.EMPTY_OBJECT},[nd.item]);tA.useContextCallback("setOpen",t5),tA.useContextCallback("setInputValue",t2),tA.useContextCallback("setSelectedValue",t7),tA.useContextCallback("setIndices",t4),tA.useContextCallback("handleSelection",t3),tA.useContextCallback("forceMount",t0),tA.useContextCallback("requestSubmit",t8),tA.useContextCallback("onOpenChangeComplete",$),(0,o.useOnFirstRender)(()=>{tA.update({inline:eS,popupProps:np,listProps:nm,inputProps:nf,triggerProps:tJ,itemProps:ng})});let nh={id:eV,selectedValue:tm,open:ty,mounted:tG,transitionStatus:tQ,items:e$,inline:eS,popupProps:np,listProps:nm,inputProps:nf,triggerProps:tJ,itemProps:ng,openMethod:tX,selectionMode:Z,name:tl,form:en,disabled:ta,readOnly:ei,required:eo,grid:ea,virtualized:ey,openOnInputClick:ef,itemToStringLabel:eK,modal:eE,autoHighlight:q,isItemEqualToValue:ex,submitOnItemClick:eO,hasInputValue:td};(0,i.useIsoLayoutEffect)(()=>{tA.update({...nh,inputOwnsFormValue:"none"===Z&&(eS||!tA.state.inputInsidePopup)})},[tA,...Object.values(nh)]);let nv=(0,a.useMergedRefs)(es,eF.inputRef),nb=t.useMemo(()=>({query:tE,hasItems:tf,filteredItems:tk,flatFilteredValues:tM}),[tE,tf,tk,tM]),nx=t.useMemo(()=>Array.isArray(tP)?"":(0,z.stringifyAsValue)(tP,eb),[tP,eb]),ny=tu&&Array.isArray(tm)&&tm.length>0,nS=tu||"none"===Z&&t$?void 0:tl,nC=t.useMemo(()=>tu&&Array.isArray(tm)&&tl?tm.map(e=>{let t=(0,z.stringifyAsValue)(e,eb);return(0,B.jsx)("input",{type:"hidden",form:en,name:tl,value:t,disabled:ta},t)}):null,[tu,tm,en,tl,eb,ta]),nE=(0,B.jsxs)(t.Fragment,{children:[e.children,(0,B.jsx)("input",{...eF.getValidationProps(ta,{onFocus(){tW?tV?.focus():(e6.current||tV)?.focus()},onChange(e){if(e.nativeEvent.defaultPrevented||ta||ei)return;let t=e.currentTarget.value,n=t.toLowerCase(),r=(0,y.createChangeEventDetails)(S.REASONS.none,e.nativeEvent),i=()=>to.current.findIndex(e=>(0,z.stringifyAsValue)(e,eb).toLowerCase()===n||eY(e).toLowerCase()===n);tc&&(t0(),eq&&-1===i()&&tA.set("forceMounted",!0)),queueMicrotask(function(){if(tu)return;if("none"===Z)return void t2(t,r);let e=i();-1===e&&(e=to.current.findIndex((e,t)=>{let r=e4.current[t];return null!=r&&r.toLowerCase()===n}));let o=-1===e?void 0:to.current[e];null!=o&&t7?.(o,r)})}}),id:eV&&null==nS?`${eV}-hidden-input`:void 0,form:en,name:nS,autoComplete:eI,disabled:ta,required:eo&&!ny,readOnly:ei,value:nx,ref:nv,style:nS?u.visuallyHiddenInput:u.visuallyHidden,tabIndex:-1,"aria-hidden":!0,suppressHydrationWarning:!0}),nC]});return(0,B.jsx)(C.ComboboxRootContext.Provider,{value:tA,children:(0,B.jsx)(C.ComboboxFloatingContext.Provider,{value:ni,children:(0,B.jsx)(C.ComboboxHasItemsContext.Provider,{value:tf,children:(0,B.jsx)(C.ComboboxDerivedItemsContext.Provider,{value:nb,children:(0,B.jsx)(C.ComboboxInputValueContext.Provider,{value:tb,children:nE})})})})})}e.s(["ComboboxRoot",0,function(e){let{multiple:t=!1,defaultValue:n,value:r,onValueChange:i,autoComplete:o,...s}=e;return(0,B.jsx)(q,{...s,selectionMode:t?"multiple":"single",selectedValue:r,defaultSelectedValue:n,onSelectedValueChange:i,formAutoComplete:o})}],45654)},62156,36523,56970,96545,61919,e=>{"use strict";var t=e.i(84325),n=e.i(42191);function r(e,t){return(n,r)=>null!=n&&e.contains(n,r,t)}function i(e,t,r){return(i,o)=>{if(null==i)return!1;if(!o)return!0;let s=t?.selected??t,a=null!=r?(0,n.stringifyAsLabel)(r,s):"";return!!(a&&e.contains(a,o))&&a.length===o.length||e.contains(i,o,t)}}e.s(["selectors",0,{id:e=>e.id,labelId:e=>e.labelId,items:e=>e.items,selectedValue:e=>e.selectedValue,hasSelectionChips:e=>{let t=e.selectedValue;return Array.isArray(t)&&t.length>0},hasSelectedValue:e=>{let{selectedValue:t,selectionMode:n}=e;return null!=t&&(!("multiple"===n&&Array.isArray(t))||t.length>0)},hasNullItemLabel:(e,t)=>!!t&&(0,n.hasNullItemLabel)(e.items),open:e=>e.open,mounted:e=>e.mounted,forceMounted:e=>e.forceMounted,inline:e=>e.inline,activeIndex:e=>e.activeIndex,selectedIndex:e=>e.selectedIndex,isActive:(e,t)=>e.activeIndex===t,isSelected:(e,n)=>{let r=e.isItemEqualToValue,i=e.selectedValue;return Array.isArray(i)?i.some(e=>(0,t.compareItemEquality)(n,e,r)):(0,t.compareItemEquality)(n,i,r)},transitionStatus:e=>e.transitionStatus,popupProps:e=>e.popupProps,listProps:e=>e.listProps,inputProps:e=>e.inputProps,triggerProps:e=>e.triggerProps,itemProps:e=>e.itemProps,positionerElement:e=>e.positionerElement,listElement:e=>e.listElement,popupId:e=>e.popupId,triggerElement:e=>e.triggerElement,inputElement:e=>e.inputElement,inputGroupElement:e=>e.inputGroupElement,popupSide:e=>e.popupSide,openMethod:e=>e.openMethod,inputInsidePopup:e=>e.inputInsidePopup,inputOwnsFormValue:e=>e.inputOwnsFormValue,selectionMode:e=>e.selectionMode,name:e=>e.name,form:e=>e.form,disabled:e=>e.disabled,readOnly:e=>e.readOnly,required:e=>e.required,grid:e=>e.grid,virtualized:e=>e.virtualized,itemToStringLabel:e=>e.itemToStringLabel,isItemEqualToValue:e=>e.isItemEqualToValue,modal:e=>e.modal,autoHighlight:e=>e.autoHighlight}],62156),e.s(["createCollatorItemFilter",0,r,"createSingleSelectionCollatorFilter",0,i,"getComboboxPopupId",0,function(e){return null==e?void 0:`${e}-popup`}],36523);var o=e.i(71645);let s=new Map;function a(e={}){let t={usage:"search",sensitivity:"base",ignorePunctuation:!0,...e},r=`${function e(t){return Array.isArray(t)?t.map(t=>e(t)).join(","):null==t?"":String(t)}(e.locale)}|${JSON.stringify(t)}`,i=s.get(r);if(i)return i;let o=new Intl.Collator(e.locale,t),l={contains(e,t,r){if(!t)return!0;let i=(0,n.stringifyAsLabel)(e,r);for(let e=0;e<=i.length-t.length;e+=1)if(0===o.compare(i.slice(e,e+t.length),t))return!0;return!1},startsWith(e,t,r){if(!t)return!0;let i=(0,n.stringifyAsLabel)(e,r);return 0===o.compare(i.slice(0,t.length),t)},endsWith(e,t,r){if(!t)return!0;let i=(0,n.stringifyAsLabel)(e,r),s=t.length;return i.length>=s&&0===o.compare(i.slice(i.length-s),t)}};return s.set(r,l),l}e.s(["useComboboxFilter",0,function(e={}){let{multiple:t=!1,value:n,...s}=e,l=a(s),u=o.useCallback((e,o,s)=>t?r(l,s)(e,o):i(l,s,n)(e,o),[l,n,t]);return o.useMemo(()=>({...l,contains:u}),[u,l])},"useCoreFilter",0,a],56970);var l=e.i(29315);e.s(["isScrollableY",0,function(e,t=!1){let{overflowY:n}=(0,l.getComputedStyle)(e);return("auto"===n||"scroll"===n)&&(t?e.clientHeight>0:e.scrollHeight>e.clientHeight)}],96545);let u=Symbol("none");e.s(["INITIAL_LAST_HIGHLIGHT",0,{value:u,index:-1},"NO_ACTIVE_VALUE",0,u],61919)},56212,76459,87445,e=>{"use strict";var t=e.i(71645),n=e.i(67865),r=e.i(39957),i=e.i(8868),o=e.i(52245),s=e.i(40886),a=e.i(2672),l=e.i(47018),u=e.i(69690),c=e.i(47778),d=e.i(57940),f=e.i(84446),p=e.i(64042),m=e.i(75606),g=e.i(56434),h=e.i(85689),v=e.i(5049),b=e.i(38489),x=e.i(50001),y=e.i(36523),S=e.i(97464);let C=t.forwardRef(function(e,C){let E,{render:R,className:w,nativeButton:I=!0,disabled:T=!1,id:O,style:k,...M}=e,{state:A,disabled:P,setTouched:N,setFocused:j,validationMode:L,validation:D}=(0,u.useFieldRootContext)(),{labelId:z}=(0,c.useLabelableContext)(),F=(0,a.useComboboxRootContext)(),H=F.useState("selectionMode"),V=F.useState("disabled"),_=F.useState("readOnly"),B=F.useState("required"),q=F.useState("positionerElement"),W=F.useState("listElement"),$=F.useState("popupId"),U=F.useState("triggerProps"),K=F.useState("inputInsidePopup"),G=F.useState("id"),Y=F.useState("labelId"),Q=F.useState("open"),X=F.useState("selectedValue"),J=F.useState("activeIndex"),Z=F.useState("selectedIndex"),ee=F.useState("hasSelectedValue"),et=(0,a.useComboboxFloatingContext)(),en=(0,a.useComboboxInputValueContext)(),er=(0,r.useTimeout)(),ei=P||V||T,eo=(0,S.useListEmpty)(),es=(0,S.usePopupSide)(F);(0,b.useLabelableId)({id:K?O:void 0});let ea=K?O??G:O,el=(0,x.resolveAriaLabelledBy)(z,Y);Q&&K?E=$??(0,y.getComboboxPopupId)(G):Q&&(E=W?.id);let eu=t.useRef("");function ec(e){eu.current=e.pointerType}let{reference:ed}=(0,v.useTypeahead)(et,{enabled:!Q&&!_&&!V&&"single"===H,listRef:F.context.labelsRef,activeIndex:J,selectedIndex:Z,onMatch(e){let t=F.context.valuesRef.current[e];void 0!==t&&F.context.setSelectedValue(t,(0,m.createChangeEventDetails)(g.REASONS.none))}}),{reference:ef}=(0,h.useClick)(et,{enabled:!V,event:"mousedown"}),{buttonRef:ep,getButtonProps:em}=(0,s.useButton)({native:I,disabled:ei}),eg={...A,readOnly:_,open:Q,disabled:ei,popupSide:es,listEmpty:eo,placeholder:"none"!==H&&!ee},eh=(0,n.useStableCallback)(e=>{F.set("triggerElement",e)});return(0,o.useRenderElement)("button",e,{ref:[C,ep,eh],state:eg,props:[U,ef,ed,{id:ea,tabIndex:K?0:-1,role:K?"combobox":void 0,"aria-expanded":Q,"aria-haspopup":K?"dialog":"listbox","aria-controls":E,"aria-required":K&&B||void 0,"aria-readonly":K&&_||void 0,"aria-labelledby":el,onPointerDown:ec,onPointerEnter:ec,onFocus(){j(!0),ei||er.start(0,F.context.forceMount)},onBlur(e){(0,f.contains)(q,e.relatedTarget)||(N(!0),j(!1),"onBlur"===L&&D.commit("none"===H?en:X))},onMouseDown(e){if(ei||(K||et.set("domReferenceElement",e.currentTarget),F.context.forceMount(),"touch"!==eu.current&&(F.context.inputRef.current?.focus(),K||e.preventDefault()),Q))return;let t=(0,i.ownerDocument)(e.currentTarget);K&&t.addEventListener("mouseup",function(e){let t=F.state.triggerElement;if(!t)return;let n=(0,f.getTarget)(e),r=F.state.positionerElement,i=F.state.listElement;(0,f.contains)(t,n)||(0,f.contains)(r,n)||(0,f.contains)(i,n)||(0,p.isMouseWithinBounds)(e,t)||F.context.setOpen(!1,(0,m.createChangeEventDetails)(g.REASONS.cancelOpen,e))},{once:!0})},onKeyDown(e){("ArrowDown"===e.key||"ArrowUp"===e.key)&&((0,d.stopEvent)(e),F.context.setOpen(!0,(0,m.createChangeEventDetails)(g.REASONS.listNavigation,e.nativeEvent)),F.context.inputRef.current?.focus())}},D.getValidationProps(ei,M),em],stateAttributesMapping:l.triggerStateAttributesMapping})});e.s(["ComboboxTrigger",0,C],56212);var E=e.i(43476);let R=t.createContext(null);function w(){return t.useContext(R)}e.s(["GroupCollectionProvider",0,function(e){let{children:n,items:r}=e,i=t.useMemo(()=>({items:r}),[r]);return(0,E.jsx)(R.Provider,{value:i,children:n})},"useGroupCollectionContext",0,w],76459),e.s(["ComboboxCollection",0,function(e){let{children:n}=e,{filteredItems:r}=(0,a.useComboboxDerivedItemsContext)(),i=w(),o=i?i.items:r;return(0,E.jsx)(t.Fragment,{children:o.map(n)})}],87445)},2820,56736,9793,e=>{"use strict";var t=e.i(71645),n=e.i(8821),r=e.i(52245),i=e.i(79938);let o=t.forwardRef(function(e,t){let{render:o,className:s,style:a,forceRender:l=!1,...u}=e,c=(0,n.useDialogRootContext)(),d=c.useState("open"),f=c.useState("nested"),p=c.useState("mounted"),m=c.useState("transitionStatus");return(0,r.useRenderElement)("div",e,{state:{open:d,transitionStatus:m},ref:[c.context.backdropRef,t],stateAttributesMapping:i.popupTransitionStateMapping,props:[{role:"presentation",hidden:!p,style:{userSelect:"none",WebkitUserSelect:"none"}},u],enabled:l||!f})});e.s(["DialogBackdrop",0,o],2820);var s=e.i(40886),a=e.i(75606),l=e.i(56434);let u=t.forwardRef(function(e,t){let{render:i,className:o,style:u,disabled:c=!1,nativeButton:d=!0,...f}=e,p=(0,n.useDialogRootContext)(),m=p.useState("open"),{getButtonProps:g,buttonRef:h}=(0,s.useButton)({disabled:c,native:d});return(0,r.useRenderElement)("button",e,{state:{disabled:c},ref:[t,h],props:[{onClick:function(e){m&&p.setOpen(!1,(0,a.createChangeEventDetails)(l.REASONS.closePress,e.nativeEvent))}},f,g]})});e.s(["DialogClose",0,u],56736);var c=e.i(88015);let d=t.forwardRef(function(e,t){let{render:i,className:o,style:s,id:a,...l}=e,u=(0,n.useDialogRootContext)(),d=(0,c.useBaseUiId)(a);return u.useSyncedValueWithCleanup("descriptionElementId",d),(0,r.useRenderElement)("p",e,{ref:t,props:[{id:d},l]})});e.s(["DialogDescription",0,d],9793)},84324,10199,e=>{"use strict";var t=e.i(71645),n=e.i(61487),r=e.i(8821),i=e.i(52245),o=e.i(25834),s=e.i(37584),a=e.i(73327),l=e.i(64111),u=e.i(74354),c=e.i(79938),d=e.i(38380),d=d;d.open,d.closed,d.startingStyle,d.endingStyle;let f={...c.popupStateMapping,...u.transitionStatusMapping,nestedDialogOpen:e=>e?{"data-nested-dialog-open":""}:null};e.s(["dialogStateAttributesMapping",0,f],10199);var p=e.i(43476);let m=t.forwardRef(function(e,t){let{render:u,className:c,style:d,finalFocus:m,initialFocus:g,...h}=e,v=(0,r.useDialogRootContext)(),b=v.useState("descriptionElementId"),x=v.useState("disablePointerDismissal"),y=v.useState("floatingRootContext"),S=v.useState("popupProps"),C=v.useState("modal"),E=v.useState("mounted"),R=v.useState("nested"),w=v.useState("nestedOpenDialogCount"),I=v.useState("open"),T=v.useState("openMethod"),O=v.useState("titleElementId"),k=v.useState("transitionStatus"),M=v.useState("role"),A=y.useState("floatingId");(0,o.useDialogPortalContext)(),(0,s.useOpenChangeComplete)({open:I,ref:v.context.popupRef,onComplete(){I&&v.context.onOpenChangeComplete?.(!0)}});let P=void 0===g?(0,l.createDefaultInitialFocus)(v.context.popupRef):g,N=v.useStateSetter("popupElement"),j=(0,i.useRenderElement)("div",e,{state:{open:I,nested:R,transitionStatus:k,nestedDialogOpen:w>0},props:[S,{id:A,"aria-labelledby":O,"aria-describedby":b,role:M,...l.FOCUSABLE_POPUP_PROPS,hidden:!E,onKeyDown(e){a.COMPOSITE_KEYS.has(e.key)&&e.stopPropagation()},style:{"--nested-dialogs":w}},h],ref:[t,v.context.popupRef,N],stateAttributesMapping:f});return(0,p.jsx)(n.FloatingFocusManager,{context:y,openInteractionType:T,disabled:!E,closeOnFocusOut:!x,initialFocus:P,returnFocus:m,modal:!1!==C,restoreFocus:"popup",children:j})});e.s(["DialogPopup",0,m],84324)},64951,e=>{"use strict";e.i(47167);var t=e.i(71645),n=e.i(44394),r=e.i(26674),i=e.i(8821),o=e.i(25834),s=e.i(426),a=e.i(43476);let l=t.forwardRef(function(e,t){let{keepMounted:l=!1,...u}=e,c=(0,i.useDialogRootContext)(),d=c.useState("mounted"),f=c.useState("modal"),p=c.useState("open");return d||l?(0,a.jsx)(o.DialogPortalContext.Provider,{value:l,children:(0,a.jsxs)(r.FloatingPortal,{ref:t,...u,children:[d&&!0===f&&(0,a.jsx)(s.InternalBackdrop,{ref:c.context.internalBackdropRef,inert:(0,n.inertValue)(!p)}),e.children]})}):null});e.s(["DialogPortal",0,l])},25834,e=>{"use strict";e.i(47167);var t=e.i(33332),n=e.i(71645);let r=n.createContext(void 0);e.s(["DialogPortalContext",0,r,"useDialogPortalContext",0,function(){let e=n.useContext(r);if(void 0===e)throw Error((0,t.default)(26));return e}])},50440,1807,66250,74217,77173,59636,e=>{"use strict";var t=e.i(96499),n=e.i(71645),r=e.i(67530),i=e.i(8821),o=e.i(26352),s=e.i(18478),a=e.i(16786),l=e.i(90627),u=e.i(64111);let c={...a.popupStoreSelectors,modal:e=>e.modal,nested:e=>e.nested,nestedOpenDialogCount:e=>e.nestedOpenDialogCount,nestedOpenDrawerCount:e=>e.nestedOpenDrawerCount,disablePointerDismissal:e=>e.disablePointerDismissal,openMethod:e=>e.openMethod,descriptionElementId:e=>e.descriptionElementId,titleElementId:e=>e.titleElementId,viewportElement:e=>e.viewportElement,role:e=>e.role};class d extends o.ReactStore{constructor(e,t,n){const r=new l.PopupTriggerMap;super(f(e,r,t,n),p(r),c)}setOpen=(e,t)=>{t.preventUnmountOnClose=()=>{this.set("preventUnmountingOnClose",!0)},e||null!=t.trigger||null==this.state.activeTriggerId||(t.trigger=this.state.activeTriggerElement??void 0),this.context.onOpenChange?.(e,t),t.isCanceled||(this.state.floatingRootContext.dispatchOpenChange(e,t),this.update((0,u.createPopupOpenState)(this.state,e,t.trigger)))}}function f(e,t,n,r=!1){return{...(0,a.createInitialPopupStoreState)(t,n,r),modal:!0,disablePointerDismissal:!1,viewportElement:null,descriptionElementId:void 0,titleElementId:void 0,openMethod:null,nested:!1,nestedOpenDialogCount:0,nestedOpenDrawerCount:0,role:"dialog",...e}}function p(e){return{popupRef:n.createRef(),backdropRef:n.createRef(),internalBackdropRef:n.createRef(),outsidePressEnabledRef:{current:!0},triggerElements:e,onOpenChange:void 0,onOpenChangeComplete:void 0}}e.s(["DialogStore",0,d,"createNullDialogStore",0,function(){let e=new l.PopupTriggerMap;return new s.NullStore(Object.freeze(f(void 0,e)),Object.freeze(p(e)),c)}],1807);var m=e.i(75606),g=e.i(56434),h=e.i(43476);function v(e,t){let{children:o,open:s,defaultOpen:a=!1,onOpenChange:l,onOpenChangeComplete:c,disablePointerDismissal:f=!1,modal:p=!0,actionsRef:v,handle:b,triggerId:x,defaultTriggerId:y=null}=t,S="alert-dialog"===e,C=(0,i.useDialogRootContext)(!0),E={modal:!!S||p,disablePointerDismissal:S||f,nested:null!=C,role:S?"alertdialog":"dialog"},R=(0,u.usePopupRootStore)((e,t)=>new d({open:a,openProp:s,activeTriggerId:y,triggerIdProp:x,...E},e,t),!0);R.useControlledProp("openProp",s),R.useControlledProp("triggerIdProp",x),R.useSyncedValues(E),R.useContextCallback("onOpenChange",l),R.useContextCallback("onOpenChangeComplete",c);let w=R.useState("open"),I=R.useState("mounted"),T=R.useState("payload");(0,u.usePopupRootSync)(R,w),(0,u.useImplicitActiveTrigger)(R);let{forceUnmount:O}=(0,u.useOpenStateTransitions)(w,R);n.useImperativeHandle(v,()=>({unmount:O,close:()=>R.setOpen(!1,(0,m.createChangeEventDetails)(g.REASONS.imperativeAction))}),[O,R]);let k=w||I;return(0,h.jsxs)(i.DialogRootContext.Provider,{value:R,children:[b&&(0,h.jsx)(u.PopupHandleAttachment,{handle:b,store:R}),k&&(0,h.jsx)(r.DialogInteractions,{store:R,parentContext:C?.context,isDrawer:"drawer"===e}),"function"==typeof o?o({payload:T}):o]})}e.s(["useRenderDialogRoot",0,v],66250);let b=(0,t.fastComponent)(function(e){return v("dialog",e)});e.s(["DialogRoot",0,b],50440);var x=e.i(52245),y=e.i(25834),S=e.i(10199);let C=n.forwardRef(function(e,t){let{render:n,className:r,style:o,children:s,...a}=e,l=(0,y.useDialogPortalContext)(),u=(0,i.useDialogRootContext)(),c=u.useState("open"),d=u.useState("nested"),f=u.useState("transitionStatus"),p=u.useState("nestedOpenDialogCount"),m=u.useState("mounted"),g=u.useStateSetter("viewportElement");return(0,x.useRenderElement)("div",e,{enabled:l||m,state:{open:c,nested:d,transitionStatus:f,nestedDialogOpen:p>0},ref:[t,g],stateAttributesMapping:S.dialogStateAttributesMapping,props:[{role:"presentation",hidden:!m,style:{pointerEvents:c?void 0:"none"},children:s},a]})});e.s(["DialogViewport",0,C],74217);var E=e.i(88015);let R=n.forwardRef(function(e,t){let{render:n,className:r,style:o,id:s,...a}=e,l=(0,i.useDialogRootContext)(),u=(0,E.useBaseUiId)(s);return l.useSyncedValueWithCleanup("titleElementId",u),(0,x.useRenderElement)("h2",e,{ref:t,props:[{id:u},a]})});e.s(["DialogTitle",0,R],77173);var w=e.i(2239),I=e.i(56789);e.s(["usePopupHandleStore",0,function(e){let t=n.useCallback(t=>void 0===e?I.NOOP:e.subscribeStore(t),[e]),r=n.useCallback(()=>void 0===e?void 0:e.store,[e]);return(0,w.useSyncExternalStore)(t,r,()=>e?.serverStore)}],59636)},67530,18478,16786,e=>{"use strict";var t=e.i(71645),n=e.i(46376),r=e.i(45484),i=e.i(17989),o=e.i(84446),s=e.i(64111);e.s(["DialogInteractions",0,function({store:e,parentContext:a,isDrawer:l}){let u=e.useState("open"),c=e.useState("disablePointerDismissal"),d=e.useState("modal"),f=e.useState("popupElement"),p=e.useState("floatingRootContext"),[m,g]=t.useState(0),[h,v]=t.useState(0),b=0===m,x=(0,i.useDismiss)(p,{outsidePressEvent:()=>e.context.internalBackdropRef.current||e.context.backdropRef.current?"intentional":{mouse:"trap-focus"===d?"sloppy":"intentional",touch:"sloppy"},outsidePress(t){if(!e.context.outsidePressEnabledRef.current||"button"in t&&0!==t.button)return!1;if("touches"in t){if("touchend"===t.type){if(1!==t.changedTouches.length||0!==t.touches.length)return!1}else if(1!==t.touches.length)return!1}let n=(0,o.getTarget)(t);if(b&&!c){if(d){let t=e.context.internalBackdropRef.current,r=e.context.backdropRef.current;return!t&&!r||t===n||r===n||(0,o.contains)(n,f)&&!n?.hasAttribute("data-base-ui-portal")}return!0}return!1},escapeKey:b});return(0,r.useScrollLock)(u&&!0===d,f),e.useContextCallback("onNestedDialogOpen",(e,t)=>{g(e),v(t)}),(0,n.useIsoLayoutEffect)(()=>(a?.onNestedDialogOpen&&(u?a.onNestedDialogOpen(m+1,h+ +!!l):a.onNestedDialogOpen(0,0)),()=>{a?.onNestedDialogOpen&&u&&a.onNestedDialogOpen(0,0)}),[l,u,m,h,a]),(0,s.usePopupInteractionProps)(e,{activeTriggerProps:x.reference,inactiveTriggerProps:x.trigger,popupProps:x.floating,nestedOpenDialogCount:m,nestedOpenDrawerCount:h}),null}],67530);var a=e.i(26352);class l extends a.ReactStore{setState(e){}update(e){}set(e,t){}notifyAll(){}}e.s(["NullStore",0,l],18478);var u=e.i(56789),c=e.i(56341);let d=e=>e.triggerIdProp??e.activeTriggerId,f=e=>e.openProp??e.open,p=e=>(e.popupElement?.id??e.floatingId)||void 0;function m(e,t){return void 0!==t&&f(e)&&d(e)===t}e.s(["createInitialPopupStoreState",0,function(e,t,n=!1){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:new c.FloatingRootStore({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:n,onOpenChange:void 0}),floatingId:t,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:u.EMPTY_OBJECT,inactiveTriggerProps:u.EMPTY_OBJECT,popupProps:u.EMPTY_OBJECT}},"popupStoreSelectors",0,{open:f,mounted:e=>e.mounted,transitionStatus:e=>e.transitionStatus,floatingRootContext:e=>e.floatingRootContext,triggerCount:e=>e.triggerCount,preventUnmountingOnClose:e=>e.preventUnmountingOnClose,payload:e=>e.payload,activeTriggerId:d,activeTriggerElement:e=>e.mounted?e.activeTriggerElement:null,popupId:p,isTriggerActive:(e,t)=>void 0!==t&&d(e)===t,isOpenedByTrigger:(e,t)=>m(e,t),isMountedByTrigger:(e,t)=>void 0!==t&&d(e)===t&&e.mounted,triggerProps:(e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps,triggerPopupId:(e,t)=>m(e,t)||void 0!==t&&f(e)&&null==d(e)&&1===e.triggerCount?p(e):void 0,popupProps:e=>e.popupProps,popupElement:e=>e.popupElement,positionerElement:e=>e.positionerElement}],16786)},61487,e=>{"use strict";var t=e.i(71645),n=e.i(29315),r=e.i(74735),i=e.i(65420),o=e.i(28918),s=e.i(46265),a=e.i(67865),l=e.i(46376),u=e.i(39957),c=e.i(28744),d=e.i(8445),f=e.i(8868),p=e.i(33848),m=e.i(52535),g=e.i(84446),h=e.i(96296),v=e.i(57940),b=e.i(83976),x=e.i(58408),y=e.i(21082),S=e.i(75606),C=e.i(56434),E=e.i(51321),R=e.i(3596),w=e.i(44659),I=e.i(26674),T=e.i(46420),O=e.i(38396),k=e.i(94603),M=e.i(43476);let A=[];function P(){A=A.filter(e=>e.deref()?.isConnected)}function N(e){P(),e&&"body"!==(0,n.getNodeName)(e)&&(A.push(new WeakRef(e)),A.length>20&&(A=A.slice(-20)))}function j(){return P(),A[A.length-1]?.deref()}function L(e){if(e.hasAttribute("tabindex")&&!e.hasAttribute("data-tabindex")||!e.getAttribute("role")?.includes("dialog"))return;let t=(0,b.focusable)(e).filter(e=>{let t=e.getAttribute("data-tabindex")||"";return(0,b.isTabbable)(e)||e.hasAttribute("data-tabindex")&&!t.startsWith("-")}),n=e.getAttribute("tabindex");0===t.length?"0"!==n&&(e.setAttribute("tabindex","0"),e.setAttribute("data-tabindex","0")):("-1"!==n||e.hasAttribute("data-tabindex")&&"-1"!==e.getAttribute("data-tabindex"))&&(e.setAttribute("tabindex","-1"),e.setAttribute("data-tabindex","-1"))}e.s(["FloatingFocusManager",0,function(e){let{context:A,children:D,disabled:z=!1,initialFocus:F=!0,returnFocus:H=!0,restoreFocus:V=!1,modal:_=!0,closeOnFocusOut:B=!0,openInteractionType:q="",nextFocusableElement:W,previousFocusableElement:$,beforeContentFocusGuardRef:U,externalTree:K,getInsideElements:G}=e,Y="rootStore"in A?A.rootStore:A,Q=Y.useState("open"),X=Y.useState("domReferenceElement"),J=Y.useState("floatingElement"),{events:Z,dataRef:ee}=Y.context,et=(0,a.useStableCallback)(()=>ee.current.floatingContext?.nodeId),en=(0,h.isTypeableCombobox)(X)&&!1===F,er=(0,s.useValueAsRef)(F),ei=(0,s.useValueAsRef)(H),eo=(0,s.useValueAsRef)(q),es=(0,s.useValueAsRef)(Q),ea=(0,T.useFloatingTree)(K),el=(0,I.usePortalContext)(),eu=t.useRef(!1),ec=t.useRef(!1),ed=t.useRef(!1),ef=t.useRef(null),ep=t.useRef(""),em=t.useRef(""),eg=t.useRef(null),eh=t.useRef(null),ev=(0,o.useMergedRefs)(eg,U,el?.beforeInsideRef),eb=(0,o.useMergedRefs)(eh,el?.afterInsideRef),ex=(0,u.useTimeout)(),ey=(0,u.useTimeout)(),eS=(0,d.useAnimationFrame)(),eC=null!=el,eE=(0,h.getFloatingFocusElement)(J),eR=(0,a.useStableCallback)((e=eE)=>e?(0,b.tabbable)(e):[]),ew=(0,a.useStableCallback)(()=>G?.().filter(e=>null!=e)??[]);t.useEffect(()=>{if(z||!_)return;let e=(0,f.ownerDocument)(eE);return(0,r.addEventListener)(e,"keydown",function(e){"Tab"===e.key&&(0,g.contains)(eE,(0,g.activeElement)((0,f.ownerDocument)(eE)))&&0===eR().length&&!en&&(0,v.stopEvent)(e)})},[z,eE,_,en,eR]),t.useEffect(()=>{if(z||!Q)return;let e=(0,f.ownerDocument)(eE);function t(){ed.current=!1}return(0,i.mergeCleanups)((0,r.addEventListener)(e,"pointerdown",function(e){let t=(0,g.getTarget)(e),n=ew();ed.current=!((0,g.contains)(J,t)||(0,g.contains)(X,t)||(0,g.contains)(el?.portalNode,t)||n.some(e=>e===t||(0,g.contains)(e,t))),em.current=e.pointerType||"keyboard",t?.closest(`[${O.CLICK_TRIGGER_IDENTIFIER}]`)&&(ec.current=!0,ey.start(0,()=>{ec.current=!1}))},!0),(0,r.addEventListener)(e,"pointerup",t,!0),(0,r.addEventListener)(e,"pointercancel",t,!0),(0,r.addEventListener)(e,"keydown",function(){em.current="keyboard"},!0),t)},[z,J,X,eE,Q,el,ey,ew]),t.useEffect(()=>{if(z||!B)return;let e=(0,f.ownerDocument)(eE);function t(t){let r=t.relatedTarget,i=t.currentTarget,o=(0,g.getTarget)(t);_&&null==r&&null!=o&&(0,g.contains)(J,o)&&N(o),queueMicrotask(()=>{let s=et(),a=Y.context.triggerElements,l=ew(),u=r?.hasAttribute((0,E.createAttribute)("focus-guard"))&&[eg.current,eh.current,el?.beforeInsideRef.current,el?.afterInsideRef.current,el?.beforeOutsideRef.current,el?.afterOutsideRef.current,(0,k.resolveRef)($),(0,k.resolveRef)(W)].includes(r),c=!((0,g.contains)(X,r)||(0,g.contains)(J,r)||(0,g.contains)(r,J)||(0,g.contains)(el?.portalNode,r)||l.some(e=>e===r||(0,g.contains)(e,r))||a.hasMatchingElement(e=>(0,g.contains)(e,r))||u||ea&&((0,x.getNodeChildren)(ea.nodesRef.current,s).find(e=>(0,g.contains)(e.context?.elements.floating,r)||(0,g.contains)(e.context?.elements.domReference,r))||(0,x.getNodeAncestors)(ea.nodesRef.current,s).find(e=>[e.context?.elements.floating,(0,h.getFloatingFocusElement)(e.context?.elements.floating)].includes(r)||e.context?.elements.domReference===r)));if(i===X&&eE&&L(eE),V&&i!==X&&!(0,y.isElementVisible)(o)&&(0,g.activeElement)(e)===e.body){if((0,n.isHTMLElement)(eE)&&(eE.focus(),"popup"===V))return void eS.request(()=>{eE.focus()});let e=eR(),t=ef.current,r=(t&&e.includes(t)?t:null)||e[e.length-1]||eE;(0,n.isHTMLElement)(r)&&r.focus()}if(ee.current.insideReactTree){ee.current.insideReactTree=!1;return}(en||!_)&&r&&c&&!ec.current&&(en||r!==j())&&(eu.current=!0,Y.setOpen(!1,(0,S.createChangeEventDetails)(C.REASONS.focusOut,t)))})}let o=(0,n.isHTMLElement)(X)?X:null;if(J||o)return(0,i.mergeCleanups)(o&&(0,r.addEventListener)(o,"focusout",t),o&&(0,r.addEventListener)(o,"pointerdown",function(){ec.current=!0,ey.start(0,()=>{ec.current=!1})}),J&&(0,r.addEventListener)(J,"focusin",function(e){let t=(0,g.getTarget)(e);(0,b.isTabbable)(t)&&(ef.current=t)}),J&&(0,r.addEventListener)(J,"focusout",t),J&&el&&(0,r.addEventListener)(J,"focusout",function(){ed.current||(ee.current.insideReactTree=!0,ex.start(0,()=>{ee.current.insideReactTree=!1}))},!0))},[z,X,J,eE,_,ea,el,Y,B,V,eR,en,et,ee,ex,ey,eS,W,$,ew]),t.useEffect(()=>{if(z||!J||!Q)return;let e=Array.from(el?.portalNode?.querySelectorAll(`[${(0,E.createAttribute)("portal")}]`)||[]),t=ea?(0,x.getNodeAncestors)(ea.nodesRef.current,et()):[],n=t.find(e=>(0,h.isTypeableCombobox)(e.context?.elements.domReference||null))?.context?.elements.domReference,r=[J,...e,eg.current,eh.current,el?.beforeOutsideRef.current,el?.afterOutsideRef.current,...ew(),n,(0,k.resolveRef)($),(0,k.resolveRef)(W),en?X:null].filter(e=>null!=e),i=(0,w.markOthers)(r,{ariaHidden:_||en,mark:!1}),o=[J,...e].filter(e=>null!=e),s=(0,w.markOthers)(o);return()=>{s(),i()}},[Q,z,X,J,_,el,en,ea,et,W,$,ew]),(0,l.useIsoLayoutEffect)(()=>{if(!Q||z||!(0,n.isHTMLElement)(eE))return;ep.current="",em.current="";let e=(0,f.ownerDocument)(eE),t=(0,g.activeElement)(e);queueMicrotask(()=>{let n,r=er.current,i="function"==typeof r?r(eo.current||""):r;if(void 0===i||!1===i||(0,g.contains)(eE,t))return;let o=null,s=()=>(null==o&&(o=eR(eE)),o[0]||eE);n=(n=!0===i||null===i?s():(0,k.resolveRef)(i))||s();let a=(0,g.contains)(eE,(0,g.activeElement)(e));(0,R.enqueueFocus)(n,{preventScroll:n===eE,shouldFocus(){if(!es.current)return!1;if(a)return!0;let t=(0,g.activeElement)(e);return!(t!==n&&(0,g.contains)(eE,t))}})})},[z,Q,eE,eR,er,eo,es]),(0,l.useIsoLayoutEffect)(()=>{if(z||!eE)return;let e=(0,f.ownerDocument)(eE),t=(0,g.activeElement)(e),r=null==eo.current;function i(e){var t,n;let r;if(e.open||(t=e.nativeEvent,n=em.current,r=(0,p.ownerWindow)((0,g.getTarget)(t)),ep.current=t instanceof r.KeyboardEvent?"keyboard":t instanceof r.FocusEvent?n||"keyboard":"pointerType"in t?t.pointerType||"keyboard":"touches"in t?"touch":t instanceof r.MouseEvent?n||(0===t.detail?"keyboard":"mouse"):""),e.reason===C.REASONS.triggerHover&&"mouseleave"===e.nativeEvent.type&&(eu.current=!0),e.reason===C.REASONS.outsidePress)if(e.nested)eu.current=!1;else if((0,v.isVirtualClick)(e.nativeEvent)||(0,v.isVirtualPointerEvent)(e.nativeEvent))eu.current=!1;else{let e=!1;(0,f.ownerDocument)(eE).createElement("div").focus({get preventScroll(){return e=!0,!1}}),e?eu.current=!1:eu.current=!0}}return N(t),Z.on("openchange",i),()=>{Z.off("openchange",i);let o=(0,g.activeElement)(e),s=ew(),a=(0,g.contains)(J,o)||s.some(e=>e===o||(0,g.contains)(e,o))||ea&&(0,x.getNodeChildren)(ea.nodesRef.current,et(),!1).some(e=>(0,g.contains)(e.context?.elements.floating,o)),l=ei.current,u=ep.current,c=function(e){let i=ei.current,o="function"==typeof i?i(e):i;if(void 0===o||!1===o)return null;null===o&&(o=!0);let s=X?.isConnected?X:null,a=t?.isConnected&&"body"!==(0,n.getNodeName)(t)?t:null,l=r?a||s:s||a;return(l||(l=j()||null),"boolean"==typeof o)?l:(0,k.resolveRef)(o)||l||null}(u);queueMicrotask(()=>{let t=c?(0,b.isTabbable)(c)?c:(0,b.tabbable)(c)[0]||c:null;if(l&&!eu.current&&(0,n.isHTMLElement)(t)&&("boolean"!=typeof l||t===o||o===e.body||a)){let e={preventScroll:!0};"keyboard"===u&&(e.focusVisible=!0),t.focus(e)}eu.current=!1})}},[z,J,eE,ei,eo,Z,ea,X,et,ew]),(0,l.useIsoLayoutEffect)(()=>{if(!c.platform.engine.webkit||Q||!J)return;let e=(0,g.activeElement)((0,f.ownerDocument)(J));(0,n.isHTMLElement)(e)&&(0,h.isTypeableElement)(e)&&(0,g.contains)(J,e)&&e.blur()},[Q,J]),(0,l.useIsoLayoutEffect)(()=>{if(!z&&el)return el.setFocusManagerState({modal:_,closeOnFocusOut:B,open:Q,onOpenChange:Y.setOpen,domReference:X}),()=>{el.setFocusManagerState(null)}},[z,el,_,Q,Y,B,X]),(0,l.useIsoLayoutEffect)(()=>{if(!z&&eE)return L(eE),()=>{queueMicrotask(P)}},[z,eE]);let eI=!z&&(!_||!en)&&(eC||_);return(0,M.jsxs)(t.Fragment,{children:[eI&&(0,M.jsx)(m.FocusGuard,{"data-type":"inside",ref:ev,onFocus:e=>{if(_){let e=eR();(0,R.enqueueFocus)(e[e.length-1])}else if(el?.portalNode)if(eu.current=!1,(0,b.isOutsideEvent)(e,el.portalNode)){let e=(0,b.getNextTabbable)(X);e?.focus()}else(0,k.resolveRef)($??el.beforeOutsideRef)?.focus()}}),D,eI&&(0,M.jsx)(m.FocusGuard,{"data-type":"inside",ref:eb,onFocus:e=>{if(_)(0,R.enqueueFocus)(eR()[0]);else if(el?.portalNode)if(B&&(eu.current=!0),(0,b.isOutsideEvent)(e,el.portalNode)){let e=(0,b.getPreviousTabbable)(X);e?.focus()}else(0,k.resolveRef)(W??el.afterOutsideRef)?.focus()}})]})}])},26674,38396,e=>{"use strict";var t=e.i(71645),n=e.i(74080),r=e.i(29315),i=e.i(74735),o=e.i(65420),s=e.i(83977),a=e.i(46376),l=e.i(67865),u=e.i(56789),c=e.i(52535),d=e.i(83976),f=e.i(75606),p=e.i(56434),m=e.i(51321),g=e.i(52245);let h={clipPath:"inset(50%)",position:"fixed",top:0,left:0};e.s(["CLICK_TRIGGER_IDENTIFIER",0,"data-base-ui-click-trigger","DISABLED_TRANSITIONS_STYLE",0,{style:{transition:"none"}},"DROPDOWN_COLLISION_AVOIDANCE",0,{fallbackAxisSide:"none"},"PATIENT_CLICK_THRESHOLD",0,500,"POPUP_COLLISION_AVOIDANCE",0,{fallbackAxisSide:"end"},"TYPEAHEAD_RESET_MS",0,500,"ownerVisuallyHidden",0,h],38396);var v=e.i(43476);let b=t.createContext(null),x=()=>t.useContext(b),y=(0,m.createAttribute)("portal");function S(e={}){let{ref:i,container:o,componentProps:c=u.EMPTY_OBJECT,elementProps:d}=e,f=(0,s.useId)(),p=x(),m=p?.portalNode,[h,v]=t.useState(null),[b,C]=t.useState(null),E=(0,l.useStableCallback)(e=>{null!==e&&C(e)}),R=t.useRef(null);(0,a.useIsoLayoutEffect)(()=>{if(null===o){R.current&&(R.current=null,C(null),v(null));return}let e=(o&&((0,r.isNode)(o)?o:o.current))??m??document.body;if(null==e){R.current&&(R.current=null,C(null),v(null));return}R.current!==e&&(R.current=e,C(null),v(e))},[o,m]);let w=(0,g.useRenderElement)("div",c,{ref:[i,E],props:[{id:f,[y]:""},d]}),I=h&&w?n.createPortal(w,h):null;return{node:b,nodeId:t.isValidElement(w)?w.props.id:void 0,subtree:I}}let C=t.forwardRef(function(e,r){let{render:s,className:l,style:u,children:m,container:g,portalOwnerRole:x,...y}=e,{node:C,nodeId:E,subtree:R}=S({container:g,ref:r,componentProps:e,elementProps:y}),w=t.useRef(null),I=t.useRef(null),T=t.useRef(null),O=t.useRef(null),[k,M]=t.useState(null),A=t.useRef(!1),P=k?.modal,N=k?.open,j=!!k&&!k.modal&&k.open&&!!C;t.useEffect(()=>{if(C&&!P)return(0,o.mergeCleanups)((0,i.addEventListener)(C,"focusin",e,!0),(0,i.addEventListener)(C,"focusout",e,!0));function e(e){C&&e.relatedTarget&&(0,d.isOutsideEvent)(e)&&("focusin"===e.type?A.current&&((0,d.enableFocusInside)(C),A.current=!1):((0,d.disableFocusInside)(C),A.current=!0))}},[C,P]),(0,a.useIsoLayoutEffect)(()=>{C&&!0===N&&A.current&&((0,d.enableFocusInside)(C),A.current=!1)},[N,C]);let L=t.useMemo(()=>({beforeOutsideRef:w,afterOutsideRef:I,beforeInsideRef:T,afterInsideRef:O,portalNode:C,setFocusManagerState:M}),[C]);return(0,v.jsxs)(t.Fragment,{children:[R,(0,v.jsxs)(b.Provider,{value:L,children:[j&&C&&(0,v.jsx)(c.FocusGuard,{"data-type":"outside",ref:w,onFocus:e=>{if((0,d.isOutsideEvent)(e,C))T.current?.focus();else{let e=k?k.domReference:null,t=(0,d.getPreviousTabbable)(e);t?.focus()}}}),j&&C&&(0,v.jsx)("span",{role:x,"aria-owns":E,style:h}),C&&n.createPortal(m,C),j&&C&&(0,v.jsx)(c.FocusGuard,{"data-type":"outside",ref:I,onFocus:e=>{if((0,d.isOutsideEvent)(e,C))O.current?.focus();else{let t=k?k.domReference:null,n=(0,d.getNextTabbable)(t);n?.focus(),k?.closeOnFocusOut&&k?.onOpenChange(!1,(0,f.createChangeEventDetails)(p.REASONS.focusOut,e.nativeEvent))}}})]})]})});e.s(["FloatingPortal",0,C,"useFloatingPortalNode",0,S,"usePortalContext",0,x],26674)},56341,e=>{"use strict";var t=e.i(26352),n=e.i(61286),r=e.i(57940);let i={open:e=>e.open,transitionStatus:e=>e.transitionStatus,domReferenceElement:e=>e.domReferenceElement,referenceElement:e=>e.positionReference??e.referenceElement,floatingElement:e=>e.floatingElement,floatingId:e=>e.floatingId};class o extends t.ReactStore{constructor(e){const{syncOnly:t,nested:r,onOpenChange:o,triggerElements:s,...a}=e;super({...a,positionReference:a.referenceElement,domReferenceElement:a.referenceElement},{onOpenChange:o,dataRef:{current:{}},events:(0,n.createEventEmitter)(),nested:r,triggerElements:s},i),this.syncOnly=t}syncOpenEvent=(e,t)=>{(!e||!this.state.open||null!=t&&(0,r.isClickLikeEvent)(t))&&(this.context.dataRef.current.openEvent=e?t:void 0)};dispatchOpenChange=(e,t)=>{this.syncOpenEvent(e,t.event);let n={open:e,reason:t.reason,nativeEvent:t.event,nested:this.context.nested,triggerElement:t.trigger};this.context.events.emit("openchange",n)};setOpen=(e,t)=>{this.syncOnly||this.dispatchOpenChange(e,t),this.context.onOpenChange?.(e,t)}}e.s(["FloatingRootStore",0,o])},46420,61286,79248,e=>{"use strict";var t=e.i(71645),n=e.i(83977),r=e.i(46376),i=e.i(88940);function o(){let e=new Map;return{emit(t,n){e.get(t)?.forEach(e=>e(n))},on(t,n){e.has(t)||e.set(t,new Set),e.get(t).add(n)},off(t,n){e.get(t)?.delete(n)}}}e.s(["createEventEmitter",0,o],61286);class s{nodesRef={current:[]};events=o();addNode(e){this.nodesRef.current.push(e)}removeNode(e){let t=this.nodesRef.current.findIndex(t=>t===e);-1!==t&&this.nodesRef.current.splice(t,1)}}e.s(["FloatingTreeStore",0,s],79248);var a=e.i(43476);let l=t.createContext(null),u=t.createContext(null),c=()=>t.useContext(l)?.id||null,d=e=>{let n=t.useContext(u);return e??n};e.s(["FloatingNode",0,function(e){let{children:n,id:r}=e,i=c();return(0,a.jsx)(l.Provider,{value:t.useMemo(()=>({id:r,parentId:i}),[r,i]),children:n})},"FloatingTree",0,function(e){let{children:t,externalTree:n}=e,r=(0,i.useRefWithInit)(()=>n??new s).current;return(0,a.jsx)(u.Provider,{value:r,children:t})},"useFloatingNodeId",0,function(e){let t=(0,n.useId)(),i=d(e),o=c();return(0,r.useIsoLayoutEffect)(()=>{if(!t)return;let e={id:t,parentId:o};return i?.addNode(e),()=>{i?.removeNode(e)}},[i,t,o]),t},"useFloatingParentNodeId",0,c,"useFloatingTree",0,d],46420)},64132,2672,e=>{"use strict";var t=e.i(21082);e.s(["gridNavigation",0,function(e,n,r,i,o,s,a,l,u,c=2){let d=(0,t.getGridNavigatedIndex)(r.current,{event:e,orientation:i,loopFocus:o,rtl:s,cols:c,disabledIndices:a,minIndex:l,maxIndex:u,prevIndex:n>u?l:n,stopEvent:!0});return(0,t.isIndexOutOfListBounds)(r.current,d)?void 0:d}],64132);var n=e.i(33332),r=e.i(71645);let i=r.createContext(void 0),o=r.createContext(void 0),s=r.createContext(void 0),a=r.createContext(!1),l=r.createContext("");e.s(["ComboboxDerivedItemsContext",0,s,"ComboboxFloatingContext",0,o,"ComboboxHasItemsContext",0,a,"ComboboxInputValueContext",0,l,"ComboboxRootContext",0,i,"useComboboxDerivedItemsContext",0,function(){let e=r.useContext(s);if(!e)throw Error((0,n.default)(24));return e},"useComboboxFloatingContext",0,function(){let e=r.useContext(o);if(!e)throw Error((0,n.default)(23));return e},"useComboboxHasItemsContext",0,function(){return r.useContext(a)},"useComboboxInputValueContext",0,function(){return r.useContext(l)},"useComboboxRootContext",0,function(){let e=r.useContext(i);if(!e)throw Error((0,n.default)(22));return e}],2672)},85689,e=>{"use strict";var t=e.i(71645),n=e.i(8445),r=e.i(39957),i=e.i(56789),o=e.i(84446),s=e.i(96296),a=e.i(57940),l=e.i(75606),u=e.i(56434);e.s(["useClick",0,function(e,c={}){let{enabled:d=!0,event:f="click",toggle:p=!0,ignoreMouse:m=!1,stickIfOpen:g=!0,touchOpenDelay:h=0,reason:v=u.REASONS.triggerPress}=c,b="rootStore"in e?e.rootStore:e,x=b.context.dataRef,y=t.useRef(void 0),S=(0,n.useAnimationFrame)(),C=(0,r.useTimeout)(),E=t.useMemo(()=>{function e(e,t,n,r){let i=(0,l.createChangeEventDetails)(v,t,n);e&&"touch"===r&&h>0?C.start(h,()=>{b.setOpen(!0,i)}):b.setOpen(e,i)}function t(e,t,n){let r=x.current.openEvent,i=b.select("domReferenceElement")!==t;return!!e&&!!i||!e||!p||!!r&&!!g&&!n(r.type)}return{onPointerDown(e){y.current=(0,a.isMouseLikePointerType)(e.pointerType,!0)&&(0,a.isVirtualPointerEvent)(e.nativeEvent)?"virtual":e.pointerType},onMouseDown(n){let r=y.current,i=n.nativeEvent,l=b.select("open");if(0!==n.button||"click"===f||(0,a.isMouseLikePointerType)(r,!0)&&m)return;let u=t(l,n.currentTarget,e=>"click"===e||"mousedown"===e),c=(0,o.getTarget)(i);if((0,s.isTypeableElement)(c))return void e(u,i,c,r);let d=n.currentTarget;S.request(()=>{e(u,i,d,r)})},onClick(n){if("mousedown-only"===f)return;let r=y.current;if("mousedown"===f&&r){y.current=void 0;return}(0,a.isMouseLikePointerType)(r,!0)&&m||e(t(b.select("open"),n.currentTarget,e=>"click"===e||"mousedown"===e||"keydown"===e||"keyup"===e),n.nativeEvent,n.currentTarget,r)},onKeyDown(){y.current=void 0}}},[x,f,m,v,b,g,p,S,C,h]);return t.useMemo(()=>d?{reference:E}:i.EMPTY_OBJECT,[d,E])}])},17989,e=>{"use strict";var t=e.i(71645),n=e.i(74735),r=e.i(65420),i=e.i(8868),o=e.i(67865),s=e.i(39957),a=e.i(29315),l=e.i(28744),u=e.i(46420),c=e.i(75606),d=e.i(56434),f=e.i(51321),p=e.i(84446),m=e.i(96296),g=e.i(57940),h=e.i(58408);function v(){return!1}e.s(["useDismiss",0,function(e,b={}){let{enabled:x=!0,escapeKey:y=!0,outsidePress:S=!0,outsidePressEvent:C="sloppy",referencePress:E=v,bubbles:R,externalTree:w}=b,I="rootStore"in e?e.rootStore:e,T=I.useState("open"),O=I.useState("floatingElement"),{dataRef:k,events:M}=I.context,A=(0,u.useFloatingTree)(w),P=(0,o.useStableCallback)("function"==typeof S?S:()=>!1),N="function"==typeof S?P:S,j=!1!==N,L=(0,o.useStableCallback)(()=>C),{escapeKey:D,outsidePress:z}={escapeKey:"boolean"==typeof R?R:R?.escapeKey??!1,outsidePress:"boolean"==typeof R?R:R?.outsidePress??!0},F=t.useRef(!1),H=t.useRef(!1),V=t.useRef(!1),_=t.useRef(!1),B=t.useRef(!1),q=t.useRef(""),W=t.useRef(null),$=(0,s.useTimeout)(),U=(0,s.useTimeout)(),K=(0,o.useStableCallback)(()=>{U.clear(),k.current.insideReactTree=!1}),G=(0,o.useStableCallback)(e=>{let t=k.current.floatingContext?.nodeId;return(A?(0,h.getNodeChildren)(A.nodesRef.current,t):[]).some(t=>t.context?.open&&!t.context.dataRef.current[e])}),Y=(0,o.useStableCallback)(e=>(0,m.isEventTargetWithin)(e,I.select("floatingElement"))||(0,m.isEventTargetWithin)(e,I.select("domReferenceElement"))),Q=(0,o.useStableCallback)(e=>{E()&&I.setOpen(!1,(0,c.createChangeEventDetails)(d.REASONS.triggerPress,e.nativeEvent))}),X=(0,o.useStableCallback)(e=>{if(!T||!x||!y||"Escape"!==e.key||B.current||!D&&G("__escapeKeyBubbles"))return;let t=(0,g.isReactEvent)(e)?e.nativeEvent:e,n=(0,c.createChangeEventDetails)(d.REASONS.escapeKey,t);I.setOpen(!1,n),n.isCanceled||e.preventDefault(),D||n.isPropagationAllowed||e.stopPropagation()}),J=(0,o.useStableCallback)(()=>{k.current.insideReactTree=!0,U.start(0,K)}),Z=(0,o.useStableCallback)(e=>{if(!T||!x||0!==e.button)return;let t=(0,p.getTarget)(e.nativeEvent);(0,p.contains)(I.select("floatingElement"),t)&&(F.current||(F.current=!0,H.current=!1))}),ee=(0,o.useStableCallback)(e=>{!T||!x||(e.defaultPrevented||e.nativeEvent.defaultPrevented)&&F.current&&(H.current=!0)});t.useEffect(()=>{function e(e){e.open||(_.current=!1)}return M.on("openchange",e),()=>{M.off("openchange",e)}},[M]),t.useEffect(()=>{if(!T||!x)return T||(_.current=!1),K;k.current.__escapeKeyBubbles=D,k.current.__outsidePressBubbles=z;let e=new s.Timeout,t=new s.Timeout,o=(0,i.ownerDocument)(O);function u(){V.current=!0,t.start(0,()=>{V.current=!1})}function v(){F.current=!1,H.current=!1}function b(){let e=q.current,t=L(),n="function"==typeof t?t():t;return"string"==typeof n?n:n["pen"!==e&&e?e:"mouse"]}function S(e){let t=k.current.floatingContext?.nodeId,n=A&&(0,h.getNodeChildren)(A.nodesRef.current,t).some(t=>(0,m.isEventTargetWithin)(e,t.context?.elements.floating));return Y(e)||n}function C(e){let n;if("intentional"===(n=b())&&"click"!==e.type||"sloppy"===n&&"click"===e.type){"click"===e.type||Y(e)||(t.clear(),V.current=!1),K();return}if(k.current.insideReactTree)return void K();let r=(0,p.getTarget)(e),o=`[${(0,f.createAttribute)("inert")}]`,s=(0,a.isElement)(r)?r.getRootNode():null,l=Array.from(((0,a.isShadowRoot)(s)?s:(0,i.ownerDocument)(I.select("floatingElement"))).querySelectorAll(o)),u=I.context.triggerElements;if(r&&(u.hasElement(r)||u.hasMatchingElement(e=>(0,p.contains)(e,r))))return;let h=(0,a.isElement)(r)?r:null;for(;h&&!(0,a.isLastTraversableNode)(h);){let e=(0,a.getParentNode)(h);if((0,a.isLastTraversableNode)(e)||!(0,a.isElement)(e))break;h=e}if(!(l.length&&(0,a.isElement)(r)&&!(0,m.isRootElement)(r)&&!(0,p.contains)(r,I.select("floatingElement"))&&l.every(e=>!(0,p.contains)(h,e)))){if((0,a.isHTMLElement)(r)&&!("touches"in e)){let t=(0,a.isLastTraversableNode)(r),n=(0,a.getComputedStyle)(r),i=/auto|scroll/,o=t||i.test(n.overflowX),s=t||i.test(n.overflowY),l=o&&r.clientWidth>0&&r.scrollWidth>r.clientWidth,u=s&&r.clientHeight>0&&r.scrollHeight>r.clientHeight,c="rtl"===n.direction,d=u&&(c?e.offsetX<=r.offsetWidth-r.clientWidth:e.offsetX>r.clientWidth),f=l&&e.offsetY>r.clientHeight;if(d||f)return}if(!S(e)){if("intentional"===b()){if(0!==e.detail&&!(0,g.isVirtualClick)(e)&&!_.current)return;if(V.current){t.clear(),V.current=!1;return}}"function"==typeof N&&!N(e)||G("__outsidePressBubbles")||(I.setOpen(!1,(0,c.createChangeEventDetails)(d.REASONS.outsidePress,e)),K())}}}function E(e){if("sloppy"!==b()||!I.select("open")||!x||Y(e))return;let t=e.touches[0];t&&(W.current={startTime:Date.now(),startX:t.clientX,startY:t.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},$.start(1e3,()=>{W.current&&(W.current.dismissOnTouchEnd=!1,W.current.dismissOnMouseDown=!1)}))}function R(e,t){let r=(0,p.getTarget)(e);if(!r)return;let i=(0,n.addEventListener)(r,e.type,()=>{t(e),i()})}function w(e){$.clear(),"pointerdown"===e.type&&(0===e.button&&(_.current=!0),q.current=e.pointerType),("mousedown"!==e.type||!W.current||W.current.dismissOnMouseDown)&&R(e,e=>{if("pointerdown"===e.type)"sloppy"!==b()||"touch"===e.pointerType||!I.select("open")||!x||Y(e)||C(e);else C(e)})}function M(e){if("pointercancel"===e.type&&(_.current=!1),!F.current)return;let n=H.current;if(v(),"intentional"===b()){if("pointercancel"===e.type){n&&u();return}S(e)||(n?u():("function"!=typeof N||N(e))&&(t.clear(),V.current=!0,K()))}}function P(e){if("sloppy"!==b()||!W.current||Y(e))return;let t=e.touches[0];if(!t)return;let n=Math.abs(t.clientX-W.current.startX),r=Math.abs(t.clientY-W.current.startY),i=Math.sqrt(n*n+r*r);i>5&&(W.current.dismissOnTouchEnd=!0),i>10&&(C(e),$.clear(),W.current=null)}function U(e){"sloppy"!==b()||!W.current||Y(e)||(W.current.dismissOnTouchEnd&&C(e),$.clear(),W.current=null)}let Q=(0,r.mergeCleanups)(y&&(0,r.mergeCleanups)((0,n.addEventListener)(o,"keydown",X),(0,n.addEventListener)(o,"compositionstart",function(){e.clear(),B.current=!0}),(0,n.addEventListener)(o,"compositionend",function(){e.start(5*!!l.platform.engine.webkit,()=>{B.current=!1})})),j&&(0,r.mergeCleanups)((0,n.addEventListener)(o,"click",w,!0),(0,n.addEventListener)(o,"pointerdown",w,!0),(0,n.addEventListener)(o,"pointerup",M,!0),(0,n.addEventListener)(o,"pointercancel",M,!0),(0,n.addEventListener)(o,"mousedown",w,!0),(0,n.addEventListener)(o,"mouseup",M,!0),(0,n.addEventListener)(o,"touchstart",function(e){q.current="touch",R(e,E)},{capture:!0,passive:!0}),(0,n.addEventListener)(o,"touchmove",function(e){R(e,P)},{capture:!0,passive:!0}),(0,n.addEventListener)(o,"touchend",function(e){R(e,U)},{capture:!0,passive:!0})));return()=>{Q(),e.clear(),t.clear(),v(),V.current=!1,K()}},[k,O,y,j,N,T,x,D,z,X,K,L,G,Y,A,I,$]);let et=t.useMemo(()=>({onKeyDown:X,onPointerDown:Q,onClick:Q}),[X,Q]),en=t.useMemo(()=>({onKeyDown:X,onPointerDown:ee,onMouseDown:ee,onClickCapture:J,onMouseDownCapture(e){J(),Z(e)},onPointerDownCapture(e){J(),Z(e)},onMouseUpCapture:J,onTouchEndCapture:J,onTouchMoveCapture:J}),[X,J,Z,ee]);return t.useMemo(()=>x?{reference:et,floating:en,trigger:et}:{},[x,et,en])}])},65858,e=>{"use strict";e.i(47167);var t=e.i(29315),n=e.i(83977),r=e.i(46376),i=e.i(88940),o=e.i(90627),s=e.i(46420),a=e.i(56341);e.s(["useFloatingRootContext",0,function(e){let{open:l=!1,onOpenChange:u,elements:c={}}=e,d=(0,n.useId)(),f=null!=(0,s.useFloatingParentNodeId)(),p=(0,i.useRefWithInit)(()=>new a.FloatingRootStore({open:l,transitionStatus:void 0,onOpenChange:u,referenceElement:c.reference??null,floatingElement:c.floating??null,triggerElements:new o.PopupTriggerMap,floatingId:d,syncOnly:!1,nested:f})).current;return(0,r.useIsoLayoutEffect)(()=>{let e={open:l,floatingId:d};void 0!==c.reference&&(e.referenceElement=c.reference,e.domReferenceElement=(0,t.isElement)(c.reference)?c.reference:null),void 0!==c.floating&&(e.floatingElement=c.floating),p.update(e)},[l,d,c.reference,c.floating,p]),p.context.onOpenChange=u,p.context.nested=f,p}])},13082,e=>{"use strict";var t=e.i(71645),n=e.i(74735),r=e.i(28744),i=e.i(65420),o=e.i(8868),s=e.i(39957),a=e.i(29315),l=e.i(51321),u=e.i(84446),c=e.i(96296),d=e.i(75606),f=e.i(56434);let p=r.platform.os.mac&&r.platform.engine.webkit;e.s(["useFocus",0,function(e,r={}){let{enabled:m=!0,delay:g}=r,h="rootStore"in e?e.rootStore:e,{events:v,dataRef:b}=h.context,x=t.useRef(!1),y=t.useRef(null),S=t.useRef(!0),C=(0,s.useTimeout)();t.useEffect(()=>{let e=h.select("domReferenceElement");if(!m)return;let t=(0,a.getWindow)(e);return(0,i.mergeCleanups)((0,n.addEventListener)(t,"blur",function(){let e=h.select("domReferenceElement");!h.select("open")&&(0,a.isHTMLElement)(e)&&e===(0,u.activeElement)((0,o.ownerDocument)(e))&&(x.current=!0,y.current=e)}),p&&(0,n.addEventListener)(t,"keydown",function(){S.current=!0},!0),p&&(0,n.addEventListener)(t,"pointerdown",function(){S.current=!1},!0))},[h,m]),t.useEffect(()=>{if(m)return v.on("openchange",e),()=>{v.off("openchange",e)};function e(e){if(e.reason===f.REASONS.triggerPress||e.reason===f.REASONS.escapeKey){let e=h.select("domReferenceElement");(0,a.isElement)(e)&&(y.current=e,x.current=!0)}}},[v,m,h]);let E=t.useMemo(()=>{function e(){x.current=!1,y.current=null}return{onMouseLeave(){e()},onFocus(t){let n=t.currentTarget;if(x.current){if(y.current===n)return;e()}let r=(0,u.getTarget)(t.nativeEvent);if((0,a.isElement)(r)){if(p&&!t.relatedTarget){if(!S.current&&!(0,c.isTypeableElement)(r))return}else if(!(0,c.matchesFocusVisible)(r))return}let i=(0,c.isTargetInsideEnabledTrigger)(t.relatedTarget,h.context.triggerElements),{nativeEvent:o,currentTarget:s}=t,l="function"==typeof g?g():g;h.select("open")&&i||0===l||void 0===l?h.setOpen(!0,(0,d.createChangeEventDetails)(f.REASONS.triggerFocus,o,s)):C.start(l,()=>{x.current||h.setOpen(!0,(0,d.createChangeEventDetails)(f.REASONS.triggerFocus,o,s))})},onBlur(t){e();let n=t.relatedTarget,r=t.nativeEvent,i=(0,a.isElement)(n)&&n.hasAttribute((0,l.createAttribute)("focus-guard"))&&"outside"===n.getAttribute("data-type");C.start(0,()=>{let e=h.select("domReferenceElement"),t=(0,u.activeElement)((0,o.ownerDocument)(e));if(!n&&t===e||(0,u.contains)(b.current.floatingContext?.refs.floating.current,t)||(0,u.contains)(e,t)||i)return;let s=n??t;(0,c.isTargetInsideEnabledTrigger)(s,h.context.triggerElements)||h.setOpen(!1,(0,d.createChangeEventDetails)(f.REASONS.triggerFocus,r))})}}},[b,g,h,C]);return t.useMemo(()=>m?{reference:E,trigger:E}:{},[m,E])}])},60891,e=>{"use strict";e.i(47167);var t=e.i(71645),n=e.i(8445),r=e.i(46376),i=e.i(8868),o=e.i(67865),s=e.i(46265),a=e.i(28744),l=e.i(29315),u=e.i(75606),c=e.i(56434),d=e.i(46420),f=e.i(21082),p=e.i(49055),m=e.i(84446),g=e.i(96296),h=e.i(3596),v=e.i(57940);function b(e){return a.platform.engine.webkit&&0===e.movementX&&0===e.movementY}function x(e,t,n){switch(e){case"vertical":return t;case"horizontal":return n;default:return t||n}}function y(e,t){return x(t,e===p.ARROW_UP||e===p.ARROW_DOWN,e===p.ARROW_LEFT||e===p.ARROW_RIGHT)}function S(e,t,n){return x(t,e===p.ARROW_DOWN,n?e===p.ARROW_LEFT:e===p.ARROW_RIGHT)||"Enter"===e||" "===e||""===e}e.s(["useListNavigation",0,function(e,a){let{listRef:C,activeIndex:E,onNavigate:R=()=>{},enabled:w=!0,selectedIndex:I=null,allowEscape:T=!1,loopFocus:O=!1,nested:k=!1,rtl:M=!1,virtual:A=!1,focusItemOnOpen:P="auto",focusItemOnHover:N=!0,openOnArrowKeyDown:j=!0,disabledIndices:L,orientation:D="vertical",parentOrientation:z,id:F,resetOnPointerLeave:H=!0,externalTree:V,grid:_}=a,B=null!=_,q="rootStore"in e?e.rootStore:e,W=q.useState("open"),$=q.useState("floatingElement"),U=q.useState("domReferenceElement"),K=q.context.dataRef,G=(0,g.getFloatingFocusElement)($),Y=(0,g.isTypeableCombobox)(U),Q=(0,s.useValueAsRef)(G),X=(0,d.useFloatingParentNodeId)(),J=(0,d.useFloatingTree)(V),Z=t.useRef(P),ee=t.useRef(I??-1),et=t.useRef(null),en=t.useRef(!0),er=(0,o.useStableCallback)(e=>{R(-1===ee.current?null:ee.current,e)}),ei=t.useRef(!!$),eo=t.useRef(W),es=t.useRef(!1),ea=t.useRef(!1),el=t.useRef(null),eu=(0,s.useValueAsRef)(L),ec=(0,s.useValueAsRef)(W),ed=(0,s.useValueAsRef)(I),ef=(0,s.useValueAsRef)(H),ep=(0,n.useAnimationFrame)(),em=(0,n.useAnimationFrame)(),eg=(0,o.useStableCallback)(()=>{function e(e){A?J?.events.emit("virtualfocus",e):el.current=(0,h.enqueueFocus)(e,{sync:es.current,preventScroll:!0})}let t=C.current[ee.current],n=ea.current;t&&e(t),(es.current?e=>e():e=>ep.request(e))(()=>{let r=C.current[ee.current]||t;!r||(t||e(r),eS&&(n||!en.current)&&r.scrollIntoView?.({block:"nearest",inline:"nearest"}))})});(0,r.useIsoLayoutEffect)(()=>{K.current.orientation=D},[K,D]),(0,r.useIsoLayoutEffect)(()=>{w&&(W&&$?(ee.current=I??-1,Z.current&&null!=I&&(ea.current=!0,er())):ei.current&&(ee.current=-1,er()))},[w,W,$,I,er]),(0,r.useIsoLayoutEffect)(()=>{if(w){if(!W){es.current=!1;return}if($)if(null==E){if(es.current=!1,null!=ed.current)return;if(ei.current&&(ee.current=-1,eg()),(!eo.current||!ei.current)&&Z.current&&(null!=et.current||!0===Z.current&&null==et.current)){let e=0,t=()=>{null==C.current[0]?(e<2&&(e?e=>em.request(e):queueMicrotask)(t),e+=1):(ee.current=null==et.current||S(et.current,D,M)||k?(0,f.getMinListIndex)(C):(0,f.getMaxListIndex)(C),et.current=null,er())};t()}}else(0,f.isIndexOutOfListBounds)(C.current,E)||(ee.current=E,eg(),ea.current=!1)}},[w,W,$,E,ed,k,C,D,M,er,eg,em]),(0,r.useIsoLayoutEffect)(()=>{if(!w||$||!J||A||!ei.current)return;let e=J.nodesRef.current,t=e.find(e=>e.id===X)?.context?.elements.floating,n=(0,m.activeElement)((0,i.ownerDocument)(U??t??null)),r=e.some(e=>e.context&&(0,m.contains)(e.context.elements.floating,n));t&&!r&&en.current&&t.focus({preventScroll:!0})},[w,$,U,J,X,A]),(0,r.useIsoLayoutEffect)(()=>{eo.current=W,ei.current=!!$}),(0,r.useIsoLayoutEffect)(()=>{W||(et.current=null,Z.current=P)},[W,P]);let eh=null!=E,ev=(0,o.useStableCallback)(e=>{if(!ec.current)return;let t=C.current.indexOf(e.currentTarget);-1!==t&&(ee.current!==t||E!==t)&&(ee.current=t,er(e))}),eb=(0,o.useStableCallback)(()=>z??J?.nodesRef.current.find(e=>e.id===X)?.context?.dataRef?.current.orientation),ex=(0,o.useStableCallback)(()=>(0,f.getMinListIndex)(C,eu.current)),ey=(0,o.useStableCallback)(e=>{var t;let n,r;if(en.current=!1,es.current=!0,229===e.which||!ec.current&&e.currentTarget===Q.current)return;if(k&&(t=e.key,n=M?t===p.ARROW_RIGHT:t===p.ARROW_LEFT,r=t===p.ARROW_UP,"both"===D||"horizontal"===D&&B?"Escape"===t:x(D,n,r))){y(e.key,eb())||(0,v.stopEvent)(e),q.setOpen(!1,(0,u.createChangeEventDetails)(c.REASONS.listNavigation,e.nativeEvent)),(0,l.isHTMLElement)(U)&&(A?J?.events.emit("virtualfocus",U):U.focus());return}let i=ee.current,o=(0,f.getMinListIndex)(C,L),s=(0,f.getMaxListIndex)(C,L);if(Y||("Home"===e.key&&((0,v.stopEvent)(e),ee.current=o,er(e)),"End"===e.key&&((0,v.stopEvent)(e),ee.current=s,er(e))),null!=_){let t=_(e,ee.current,C,D,O,M,L,o,s);if(null!=t&&(ee.current=t,er(e)),"both"===D)return}if(y(e.key,D)){if((0,v.stopEvent)(e),W&&!A&&(0,m.activeElement)(e.currentTarget.ownerDocument)===e.currentTarget){ee.current=S(e.key,D,M)?o:s,er(e);return}S(e.key,D,M)?O?i>=s?T&&i!==C.current.length?ee.current=-1:(es.current=!1,ee.current=o):ee.current=(0,f.findNonDisabledListIndex)(C.current,{startingIndex:i,disabledIndices:L}):ee.current=Math.min(s,(0,f.findNonDisabledListIndex)(C.current,{startingIndex:i,disabledIndices:L})):O?i<=o?T&&-1!==i?ee.current=C.current.length:(es.current=!1,ee.current=s):ee.current=(0,f.findNonDisabledListIndex)(C.current,{startingIndex:i,decrement:!0,disabledIndices:L}):ee.current=Math.max(o,(0,f.findNonDisabledListIndex)(C.current,{startingIndex:i,decrement:!0,disabledIndices:L})),(0,f.isIndexOutOfListBounds)(C.current,ee.current)&&(ee.current=-1),er(e)}}),eS=t.useMemo(()=>({onFocus(e){es.current=!0,ev(e)},onClick:({currentTarget:e})=>e.focus({preventScroll:!0}),onMouseMove(e){!b(e)&&(es.current=!0,ea.current=!1,N&&ev(e))},onPointerLeave(e){if(!ec.current||!en.current||"touch"===e.pointerType)return;es.current=!0;let t=e.relatedTarget;if(!(!N||C.current.includes(t))&&ef.current&&(el.current?.(),el.current=null,ee.current=-1,er(e),!A)){let e=Q.current,t=(0,m.activeElement)((0,i.ownerDocument)(e));e&&(0,m.contains)(e,t)&&e.focus({preventScroll:!0})}}}),[ev,ec,Q,N,C,er,ef,A]),eC=t.useMemo(()=>A&&W&&eh&&{"aria-activedescendant":`${F}-${E}`},[A,W,eh,F,E]),eE=t.useMemo(()=>({...!Y?eC:{},onKeyDown(e){if("Tab"===e.key&&e.shiftKey&&W&&!A){let t=(0,m.getTarget)(e.nativeEvent);if(t&&!(0,m.contains)(Q.current,t))return;(0,v.stopEvent)(e),q.setOpen(!1,(0,u.createChangeEventDetails)(c.REASONS.focusOut,e.nativeEvent)),(0,l.isHTMLElement)(U)&&U.focus();return}ey(e)},onPointerMove(e){b(e)||(en.current=!0)}}),[eC,ey,Q,Y,q,W,A,U]),eR=t.useMemo(()=>{function e(e){q.setOpen(!0,(0,u.createChangeEventDetails)(c.REASONS.listNavigation,e.nativeEvent,e.currentTarget))}function t(e){"auto"===P&&(0,v.isVirtualClick)(e.nativeEvent)&&(Z.current=!A)}function n(e){Z.current=P,"auto"===P&&(0,v.isVirtualPointerEvent)(e.nativeEvent)&&(Z.current=!0)}return{onKeyDown(t){var n,r;let i=q.select("open");en.current=!1;let o=t.key.startsWith("Arrow"),s=(n=t.key,r=eb(),x(r,M?n===p.ARROW_LEFT:n===p.ARROW_RIGHT,n===p.ARROW_DOWN)),a=y(t.key,D),l=(k?s:a)||"Enter"===t.key||""===t.key.trim();if(A&&i)return ey(t);if(i||j||!o){if(l){let e=y(t.key,eb());et.current=k&&e?null:t.key}if(k){s&&((0,v.stopEvent)(t),i?(ee.current=ex(),er(t)):e(t));return}a&&(null!=ed.current&&(ee.current=ed.current),(0,v.stopEvent)(t),!i&&j?e(t):ey(t),i&&er(t))}},onFocus(e){q.select("open")&&!A&&(ee.current=-1,er(e))},onPointerDown:n,onPointerEnter:n,onMouseDown:t,onClick:t}},[ey,P,ex,k,er,q,j,D,eb,M,ed,A]),ew=t.useMemo(()=>({...eC,...eR}),[eC,eR]);return t.useMemo(()=>w?{reference:ew,floating:eE,item:eS,trigger:eR}:{},[w,ew,eE,eR,eS])}])},5049,e=>{"use strict";var t=e.i(71645),n=e.i(46376),r=e.i(67865),i=e.i(39957),o=e.i(56789),s=e.i(21082),a=e.i(84446),l=e.i(57940);e.s(["useTypeahead",0,function(e,u){let{listRef:c,elementsRef:d,activeIndex:f,onMatch:p,disabledIndices:m,onTyping:g,enabled:h=!0,resetMs:v=750,selectedIndex:b=null}=u,x="rootStore"in e?e.rootStore:e,y=x.useState("open"),S=(0,i.useTimeout)(),C=t.useRef(""),E=t.useRef(b??f??-1),R=t.useRef(null),w=(0,r.useStableCallback)(e=>{function t(e){let t=d?.current[e];return!(t&&!(0,s.isElementVisible)(t)||t?.matches(":disabled"))&&(null==m||!(0,s.isListIndexDisabled)(o.EMPTY_ARRAY,e,m))}function n(e,r,i=0){if(0===e.length)return -1;let o=(i%e.length+e.length)%e.length,s=r.toLowerCase();for(let n=0;n<e.length;n+=1){let r=(o+n)%e.length,i=e[r];if(i?.toLowerCase().startsWith(s)&&t(r))return r}return -1}let r=c.current;if(C.current.length>0&&" "===e.key&&((0,l.stopEvent)(e),g?.(!0)),C.current.length>0&&" "!==C.current[0]&&-1===n(r,C.current)&&" "!==e.key&&g?.(!1),null==r||1!==e.key.length||e.ctrlKey||e.metaKey||e.altKey)return;y&&" "!==e.key&&((0,l.stopEvent)(e),g?.(!0));let i=""===C.current;i&&(E.current=b??f??-1),r.every((e,n)=>!(e&&t(n))||e[0]?.toLowerCase()!==e[1]?.toLowerCase())&&C.current===e.key&&(C.current="",E.current=R.current),C.current+=e.key,S.start(v,()=>{C.current="",E.current=R.current,g?.(!1)});let a=i?b??f??-1:E.current,u=n(r,C.current,(a??0)+1);-1!==u?(p?.(u),R.current=u):" "!==e.key&&(C.current="",g?.(!1))}),I=(0,r.useStableCallback)(e=>{let t=e.relatedTarget,n=x.select("domReferenceElement"),r=x.select("floatingElement");(0,a.contains)(n,t)||(0,a.contains)(r,t)||(S.clear(),C.current="",E.current=R.current,g?.(!1))});(0,n.useIsoLayoutEffect)(()=>{(y||null===b)&&(S.clear(),R.current=null,""!==C.current&&(C.current=""))},[y,b,S]);let T=t.useMemo(()=>({onKeyDown:w,onBlur:I}),[w,I]);return t.useMemo(()=>h?{reference:T,floating:T}:{},[h,T])}])},21082,e=>{"use strict";e.i(47167);var t=e.i(43084),n=e.i(29315),r=e.i(57940),i=e.i(49055);function o(e,t,n){return Math.floor(e/t)!==n}function s(e,t){return t<0||t>=e.length}function a(e,{startingIndex:t=-1,decrement:n=!1,disabledIndices:r,amount:i=1}={}){let o=t;do o+=n?-i:i;while(o>=0&&o<=e.length-1&&l(e,o,r))return o}function l(e,t,n){if("function"==typeof n?n(t):n?.includes(t)??!1)return!0;let r=e[t];return!!r&&(!!(!u(r)||r.matches(":disabled"))||!n&&(r.hasAttribute("disabled")||"true"===r.getAttribute("aria-disabled")))}function u(e,t=e?(0,n.getComputedStyle)(e):null){var r;return!!e&&!!e.isConnected&&!!t&&"hidden"!==(r=t).visibility&&"collapse"!==r.visibility&&("function"==typeof e.checkVisibility?e.checkVisibility():"none"!==t.display&&"contents"!==t.display)}e.s(["findNonDisabledListIndex",0,a,"getGridNavigatedIndex",0,function(e,{event:n,orientation:u,loopFocus:c,onLoop:d,rtl:f,cols:p,disabledIndices:m,minIndex:g,maxIndex:h,prevIndex:v,stopEvent:b=!1}){let x,y=v;if(n.key===i.ARROW_UP?x="up":n.key===i.ARROW_DOWN&&(x="down"),x){let i=[],o=[],u=!1,f=0;{let t=null,n=-1;e.forEach((e,r)=>{if(null==e)return;f+=1;let s=e.closest('[role="row"]');s&&(u=!0),(s!==t||-1===n)&&(t=s,i[n+=1]=[]),i[n].push(r),o[r]=n})}let S=!1,C=0;if(u)for(let e of i){let t=e.length;t>C&&(C=t),t!==p&&(S=!0)}let E=S&&f<e.length,R=C||p;b&&(0,r.stopEvent)(n);let w=(t=>{if(!S||-1===v)return;let r=o[v];if(null==r)return;let s=i[r].indexOf(v),a="up"===t?-1:1;for(let t=r+a,u=0;u<i.length;u+=1,t+=a){if(t<0||t>=i.length){if(!c||E)return;if(t=t<0?i.length-1:0,d){let e=Math.min(s,i[t].length-1);t=o[d(n,v,i[t][e]??i[t][0])]??t}}let r=i[t];for(let t=Math.min(s,r.length-1);t>=0;t-=1){let n=r[t];if(!l(e,n,m))return n}}})(x)??(n=>{if(!E||-1===v)return;let r=v%R,i="up"===n?-R:R,o=h-h%R,s=(0,t.floor)(h/R)+1;for(let t=v-r+i,n=0;n<s;n+=1,t+=i){if(t<0||t>h){if(!c)return;t=t<0?o:0}let n=Math.min(t+R-1,h);for(let i=Math.min(t+r,n);i>=t;i-=1)if(!l(e,i,m))return i}})(x);if(void 0!==w)y=w;else if(-1===v)y="up"===x?h:g;else if(y=a(e,{startingIndex:v,amount:R,decrement:"up"===x,disabledIndices:m}),c){if("up"===x&&(v-R<g||y<0)){let e=v%R,t=h%R,r=h-(t-e);y=t===e?h:t>e?r:r-R,d&&(y=d(n,v,y))}"down"===x&&v+R>h&&(y=a(e,{startingIndex:v%R-R,amount:R,disabledIndices:m}),d&&(y=d(n,v,y)))}s(e,y)&&(y=v)}if("both"===u){let l=(0,t.floor)(v/p);n.key===(f?i.ARROW_LEFT:i.ARROW_RIGHT)&&(b&&(0,r.stopEvent)(n),v%p!=p-1?(y=a(e,{startingIndex:v,disabledIndices:m}),c&&o(y,p,l)&&(y=a(e,{startingIndex:v-v%p-1,disabledIndices:m}),d&&(y=d(n,v,y)))):c&&(y=a(e,{startingIndex:v-v%p-1,disabledIndices:m}),d&&(y=d(n,v,y))),o(y,p,l)&&(y=v)),n.key===(f?i.ARROW_RIGHT:i.ARROW_LEFT)&&(b&&(0,r.stopEvent)(n),v%p!=0?(y=a(e,{startingIndex:v,decrement:!0,disabledIndices:m}),c&&o(y,p,l)&&(y=a(e,{startingIndex:v+(p-v%p),decrement:!0,disabledIndices:m}),d&&(y=d(n,v,y)))):c&&(y=a(e,{startingIndex:v+(p-v%p),decrement:!0,disabledIndices:m}),d&&(y=d(n,v,y))),o(y,p,l)&&(y=v));let u=(0,t.floor)(h/p)===l;s(e,y)&&(c&&u?(y=n.key===(f?i.ARROW_RIGHT:i.ARROW_LEFT)?h:a(e,{startingIndex:v-v%p-1,disabledIndices:m}),d&&(y=d(n,v,y))):y=v)}return y},"getMaxListIndex",0,function(e,t){return a(e.current,{decrement:!0,startingIndex:e.current.length,disabledIndices:t})},"getMinListIndex",0,function(e,t){return a(e.current,{disabledIndices:t})},"isElementVisible",0,u,"isIndexOutOfListBounds",0,s,"isListIndexDisabled",0,l])},49055,e=>{"use strict";e.s(["ARROW_DOWN",0,"ArrowDown","ARROW_LEFT",0,"ArrowLeft","ARROW_RIGHT",0,"ArrowRight","ARROW_UP",0,"ArrowUp","FOCUSABLE_ATTRIBUTE",0,"data-base-ui-focusable","TYPEABLE_SELECTOR",0,"input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])"])},51321,e=>{"use strict";e.s(["createAttribute",0,function(e){return`data-base-ui-${e}`}])},96296,45147,22846,e=>{"use strict";var t=e.i(29315),n=e.i(28744),r=e.i(84446),i=e.i(49055),o=e.i(15618);e.s(["CommonTriggerDataAttributes",0,o],45147);var o=o;o.popupOpen;let s="data-trigger-disabled";function a(e){return(0,t.isHTMLElement)(e)&&e.matches(i.TYPEABLE_SELECTOR)}e.s(["triggerDisabled",0,s],22846),e.s(["getFloatingFocusElement",0,function(e){return e?e.hasAttribute(i.FOCUSABLE_ATTRIBUTE)?e:e.querySelector(`[${i.FOCUSABLE_ATTRIBUTE}]`)||e:null},"isEventTargetWithin",0,function(e,t){return null!=t&&("composedPath"in e?e.composedPath().includes(t):null!=e.target&&t.contains(e.target))},"isInteractiveElement",0,function(e){return e?.closest(`button,a[href],[role="button"],select,[tabindex]:not([tabindex="-1"]),${i.TYPEABLE_SELECTOR}`)!=null},"isRootElement",0,function(e){return e.matches("html,body")},"isTargetInsideEnabledTrigger",0,function(e,n){if(!(0,t.isElement)(e))return!1;if(n.hasElement(e))return!e.hasAttribute(s);for(let[,t]of n.entries())if((0,r.contains)(t,e))return!t.hasAttribute(s);return!1},"isTypeableCombobox",0,function(e){return!!e&&"combobox"===e.getAttribute("role")&&a(e)},"isTypeableElement",0,a,"matchesFocusVisible",0,function(e){if(!e||n.platform.env.jsdom)return!0;try{return e.matches(":focus-visible")}catch(e){return!0}}],96296)},3596,e=>{"use strict";var t=e.i(56789);let n=0;e.s(["enqueueFocus",0,function(e,r={}){let{preventScroll:i=!1,sync:o=!1,shouldFocus:s}=r;function a(){(!s||s())&&e?.focus({preventScroll:i})}if(cancelAnimationFrame(n),o)return a(),t.NOOP;let l=requestAnimationFrame(a);return n=l,()=>{n===l&&(cancelAnimationFrame(l),n=0)}}])},57940,e=>{"use strict";var t=e.i(28744);e.s(["isClickLikeEvent",0,function(e){let t=e.type;return"click"===t||"mousedown"===t||"keydown"===t||"keyup"===t},"isMouseLikePointerType",0,function(e,t){let n=["mouse","pen"];return t||n.push("",void 0),n.includes(e)},"isReactEvent",0,function(e){return"nativeEvent"in e},"isVirtualClick",0,function(e){return""===e.pointerType&&!!e.isTrusted||(t.platform.os.android&&e.pointerType?"click"===e.type&&1===e.buttons:0===e.detail&&!e.pointerType)},"isVirtualPointerEvent",0,function(e){return!t.platform.env.jsdom&&(!t.platform.os.android&&0===e.width&&0===e.height||t.platform.os.android&&1===e.width&&1===e.height&&0===e.pressure&&0===e.detail&&"mouse"===e.pointerType||e.width<1&&e.height<1&&0===e.pressure&&0===e.detail&&"touch"===e.pointerType)},"stopEvent",0,function(e){e.preventDefault(),e.stopPropagation()}])},44659,e=>{"use strict";var t=e.i(29315),n=e.i(8868);let r={inert:new WeakMap,"aria-hidden":new WeakMap},i="data-base-ui-inert",o={inert:new WeakSet,"aria-hidden":new WeakSet},s=new WeakMap,a=0,l=(e,n)=>n.map(n=>{if(e.contains(n))return n;let r=function e(n){return n?(0,t.isShadowRoot)(n)?n.host:e(n.parentNode):null}(n);return e.contains(r)?r:null}).filter(e=>null!=e),u=e=>{let t=new Set;return e.forEach(e=>{let n=e;for(;n&&!t.has(n);)t.add(n),n=n.parentNode}),t},c=(e,n,r)=>{let i=[],o=e=>{!e||r.has(e)||Array.from(e.children).forEach(e=>{"script"!==(0,t.getNodeName)(e)&&(n.has(e)?o(e):i.push(e))})};return o(e),i};e.s(["markOthers",0,function(e,t={}){let{ariaHidden:d=!1,inert:f=!1,mark:p=!0}=t,m=(0,n.ownerDocument)(e[0]).body;return function(e,t,n,d,{mark:f=!0}){let p=null;d?p="inert":n&&(p="aria-hidden");let m=null,g=null,h=l(t,e),v=f?c(t,u(h),new Set(h)):[],b=[],x=[];if(p){let e=r[p],n=o[p];g=n,m=e;let i=l(t,Array.from(t.querySelectorAll("[aria-live]"))),s=h.concat(i);c(t,u(s),new Set(s)).forEach(t=>{let r=t.getAttribute(p),i=null!==r&&"false"!==r,o=(e.get(t)||0)+1;e.set(t,o),b.push(t),1===o&&i&&n.add(t),i||t.setAttribute(p,"inert"===p?"":"true")})}return f&&v.forEach(e=>{let t=(s.get(e)||0)+1;s.set(e,t),x.push(e),1===t&&e.setAttribute(i,"")}),a+=1,()=>{m&&b.forEach(e=>{let t=(m.get(e)||0)-1;m.set(e,t),t||(!g?.has(e)&&p&&e.removeAttribute(p),g?.delete(e))}),f&&x.forEach(e=>{let t=(s.get(e)||0)-1;s.set(e,t),t||e.removeAttribute(i)}),(a-=1)||(r.inert=new WeakMap,r["aria-hidden"]=new WeakMap,o.inert=new WeakSet,o["aria-hidden"]=new WeakSet,s=new WeakMap)}}(e,m,d,f,{mark:p})}])},58408,e=>{"use strict";e.s(["getNodeAncestors",0,function(e,t){let n=[],r=e.find(e=>e.id===t)?.parentId;for(;r;){let t=e.find(e=>e.id===r);r=t?.parentId,t&&(n=n.concat(t))}return n},"getNodeChildren",0,function e(t,n,r=!0){return t.filter(e=>e.parentId===n).flatMap(n=>[...!r||n.context?.open?[n]:[],...e(t,n.id,r)])}])},83976,e=>{"use strict";var t=e.i(29315),n=e.i(8868),r=e.i(84446),i=e.i(21082);function o(e){for(let n of Array.from(e.children))if("summary"===(0,t.getNodeName)(n))return n;return null}function s(e){let n=e?(0,t.getNodeName)(e):"";return null!=e&&e.matches('a[href],button,input,select,textarea,summary,details,iframe,object,embed,[tabindex],[contenteditable]:not([contenteditable="false"]),audio[controls],video[controls]')&&("summary"!==n||null!=e.parentElement&&"details"===(0,t.getNodeName)(e.parentElement)&&o(e.parentElement)===e)&&("details"!==n||null==o(e))&&("input"!==n||"hidden"!==e.type)}function a(e){if(!s(e)||!e.isConnected||e.matches(":disabled"))return!1;for(let n=e;n;n=function(e){let n=e.assignedSlot;if(n)return n;if(e.parentElement)return e.parentElement;let r=e.getRootNode();return(0,t.isShadowRoot)(r)?r.host:null}(n)){let s=n!==e,a="slot"===(0,t.getNodeName)(n);if(n.hasAttribute("inert")||s&&"details"===(0,t.getNodeName)(n)&&!n.open&&!function(e,t){let n=o(t);return!!n&&(e===n||(0,r.contains)(n,e))}(e,n)||n.hasAttribute("hidden")||!a&&!function(e,n){let r=(0,t.getComputedStyle)(e);return n?"none"!==r.display:(0,i.isElementVisible)(e,r)}(n,s))return!1}return!0}function l(e){let n=e.tabIndex;if(n<0){let n=(0,t.getNodeName)(e);if("details"===n||"audio"===n||"video"===n||(0,t.isHTMLElement)(e)&&e.isContentEditable)return 0}return n}function u(e){return"input"!==(0,t.getNodeName)(e)?null:"radio"===e.type&&""!==e.name?e:null}function c(e){if((0,t.isHTMLElement)(e)&&"slot"===(0,t.getNodeName)(e)){let t=e.assignedElements({flatten:!0});if(t.length>0)return t}return(0,t.isHTMLElement)(e)&&e.shadowRoot?Array.from(e.shadowRoot.children):Array.from(e.children)}function d(e){let t=[];return!function e(t,n){c(t).forEach(t=>{s(t)&&n.push(t),e(t,n)})}(e,t),t.filter(a)}function f(e){let t=d(e);return t.filter(e=>l(e)>=0&&function(e,t){let n=u(e);if(!n)return!0;let r=t.find(e=>{let t=u(e);return t?.name===n.name&&t.form===n.form&&t.checked});return r?r===n:t.find(e=>{let t=u(e);return t?.name===n.name&&t.form===n.form})===n}(e,t))}function p(e,t){let i=f(e),o=i.length;if(0===o)return;let s=(0,r.activeElement)((0,n.ownerDocument)(e)),a=i.indexOf(s);return i[-1===a?1===t?0:o-1:a+t]}function m(e,t){if(!e)return null;let r=f((0,n.ownerDocument)(e).body),i=r.length;if(0===i)return null;let o=r.indexOf(e);return -1===o?null:r[(o+t+i)%i]}e.s(["disableFocusInside",0,function(e){f(e).forEach(e=>{e.dataset.tabindex=e.getAttribute("tabindex")||"",e.setAttribute("tabindex","-1")})},"enableFocusInside",0,function(e){let n=[];!function e(n,r,i){c(n).forEach(n=>{(0,t.isHTMLElement)(n)&&n.matches(r)&&i.push(n),e(n,r,i)})}(e,"[data-tabindex]",n),n.forEach(e=>{let t=e.dataset.tabindex;delete e.dataset.tabindex,t?e.setAttribute("tabindex",t):e.removeAttribute("tabindex")})},"focusable",0,d,"getNextTabbable",0,function(e){return p((0,n.ownerDocument)(e).body,1)||e},"getPreviousTabbable",0,function(e){return p((0,n.ownerDocument)(e).body,-1)||e},"getTabbableAfterElement",0,function(e){return m(e,1)},"getTabbableBeforeElement",0,function(e){return m(e,-1)},"isOutsideEvent",0,function(e,t){let n=t||e.currentTarget,i=e.relatedTarget;return!i||!(0,r.contains)(n,i)},"isTabbable",0,function(e){return a(e)&&l(e)>=0},"tabbable",0,f])},93737,e=>{"use strict";e.i(71645);var t=e.i(1249),n=e.i(72410),r=e.i(43476);e.s(["PrehydrationScript",0,function(e){let{script:i}=e,{nonce:o}=(0,n.useCSPContext)();return(0,t.useIsHydrating)()?(0,r.jsx)("script",{nonce:o,dangerouslySetInnerHTML:{__html:i},suppressHydrationWarning:!0}):null}])},73327,e=>{"use strict";var t=e.i(29315);let n="ArrowUp",r="ArrowDown",i="ArrowLeft",o="ArrowRight",s="Home",a=new Set([n,r,i,o,s,"End"]);function l(e,t,n){let r="left"===n?"offsetLeft":"offsetTop",i=0;for(;t.offsetParent&&(i+=t[r],t.offsetParent!==e);)t=t.offsetParent;return i}function u(e){let t=getComputedStyle(e);return{scrollMarginTop:parseFloat(t.scrollMarginTop)||0,scrollMarginRight:parseFloat(t.scrollMarginRight)||0,scrollMarginBottom:parseFloat(t.scrollMarginBottom)||0,scrollMarginLeft:parseFloat(t.scrollMarginLeft)||0,scrollPaddingTop:parseFloat(t.scrollPaddingTop)||0,scrollPaddingRight:parseFloat(t.scrollPaddingRight)||0,scrollPaddingBottom:parseFloat(t.scrollPaddingBottom)||0,scrollPaddingLeft:parseFloat(t.scrollPaddingLeft)||0}}e.s(["ARROW_DOWN",0,r,"ARROW_LEFT",0,i,"ARROW_RIGHT",0,o,"ARROW_UP",0,n,"COMPOSITE_KEYS",0,a,"END",0,"End","HOME",0,s,"MODIFIER_KEYS",0,["Shift","Control","Alt","Meta"],"isNativeInput",0,function(e){return!!((0,t.isHTMLElement)(e)&&"INPUT"===e.tagName&&null!=e.selectionStart||(0,t.isHTMLElement)(e)&&"TEXTAREA"===e.tagName)},"scrollIntoViewIfNeeded",0,function(e,t,n,r){if(!e||!t||!t.scrollTo)return;let i=e.scrollLeft,o=e.scrollTop,s=e.clientWidth<e.scrollWidth,a=e.clientHeight<e.scrollHeight;if(s&&"vertical"!==r){let r=l(e,t,"left"),o=u(e),s=u(t);"ltr"===n&&(r+t.offsetWidth+s.scrollMarginRight>e.scrollLeft+e.clientWidth-o.scrollPaddingRight?i=r+t.offsetWidth+s.scrollMarginRight-e.clientWidth+o.scrollPaddingRight:r-s.scrollMarginLeft<e.scrollLeft+o.scrollPaddingLeft&&(i=r-s.scrollMarginLeft-o.scrollPaddingLeft)),"rtl"===n&&(r-s.scrollMarginLeft<e.scrollLeft+o.scrollPaddingLeft?i=r-s.scrollMarginLeft-o.scrollPaddingLeft:r+t.offsetWidth+s.scrollMarginRight>e.scrollLeft+e.clientWidth-o.scrollPaddingRight&&(i=r+t.offsetWidth+s.scrollMarginRight-e.clientWidth+o.scrollPaddingRight))}if(a&&"horizontal"!==r){let n=l(e,t,"top"),r=u(e),i=u(t);n-i.scrollMarginTop<e.scrollTop+r.scrollPaddingTop?o=n-i.scrollMarginTop-r.scrollPaddingTop:n+t.offsetHeight+i.scrollMarginBottom>e.scrollTop+e.clientHeight-r.scrollPaddingBottom&&(o=n+t.offsetHeight+i.scrollMarginBottom-e.clientHeight+r.scrollPaddingBottom)}e.scrollTo({left:i,top:o,behavior:"auto"})}])},53687,45356,e=>{"use strict";var t=e.i(71645),n=e.i(88940),r=e.i(67865),i=e.i(46376);let o=t.createContext({register:()=>{},unregister:()=>{},subscribeMapChange:()=>()=>{},nextIndexRef:{current:0}});e.s(["CompositeListContext",0,o,"useCompositeListContext",0,function(){return t.useContext(o)}],45356);var s=e.i(43476);function a(){return new Map}function l(){return new Set}function u(e,t){return e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_FOLLOWING?-1:1}e.s(["CompositeList",0,function(e){let{children:c,elementsRef:d,labelsRef:f,onMapChange:p}=e,m=(0,r.useStableCallback)(p),[,g]=t.useState(!1),h=(0,n.useRefWithInit)(l).current,v=(0,n.useRefWithInit)(a).current,b=t.useRef(0),x=t.useRef(!0),y=t.useRef(null),S=t.useRef(null),C=(0,r.useStableCallback)(()=>{x.current||(x.current=!0,g(e=>!e))}),E=(0,r.useStableCallback)((e,t)=>{v.set(e,t),C()}),R=(0,r.useStableCallback)(e=>{v.delete(e),C()}),w=(0,r.useStableCallback)(e=>{let t=new Map;return d.current.length=0,f&&(f.current.length=0),e.forEach(e=>{t.set(e.element,{...e.registration.metadata??{},index:e.index}),d.current[e.index]=e.element,f&&(f.current[e.index]=void 0!==e.registration.label?e.registration.label:e.registration.textRef?.current?.textContent??e.element.textContent)}),b.current=d.current.length,t}),I=(0,r.useStableCallback)(()=>{var e;let t,n,r,i,[o,s]=(e=v,t=new Set,n=[],r=[],e.forEach((e,i)=>{if(!i.isConnected)return;let o=e.index,s={index:o??-1,element:i,registration:e};null===o?r.push(s):o>=0&&(t.add(o),n.push(s))}),i=0,r.sort((e,t)=>u(e.element,t.element)),r.forEach(e=>{for(;t.has(i);)i+=1;e.index=i,n.push(e),i+=1}),t.size>0&&n.sort((e,t)=>e.index-t.index),[n,r.map(e=>e.element)]),a=w(o),l=y.current,c=!l||l.length!==o.length||o.some((e,t)=>{let n=l[t];return e.index!==n.index||e.element!==n.element||e.registration.index!==n.registration.index||e.registration.metadata!==n.registration.metadata});!function(e){if(S.current?.disconnect(),S.current=null,"function"!=typeof MutationObserver||e.length<2)return;let t=new MutationObserver(n=>{if(!function(e){for(let t of e)for(let e=0;e<t.removedNodes.length;e+=1)if(t.removedNodes[e].isConnected)return!0;return!1}(n))return;let r=null;for(let n of e)if(n.isConnected){if(r&&u(r,n)>0){t.disconnect(),C();return}r=n}});S.current=t;let n=new Set;for(let t=1;t<e.length;t+=1){let r=function(e,t){let n=e.parentElement;for(;n&&!n.contains(t);)n=n.parentElement;return n}(e[t-1],e[t]);r&&n.add(r)}n.forEach(e=>t.observe(e,{childList:!0}))}(s),y.current=o,x.current=!1,c&&(h.forEach(e=>e(a)),m(a))});(0,i.useIsoLayoutEffect)(()=>(!x.current&&y.current&&w(y.current),()=>{d.current=[],f&&(f.current=[])}),[d,f,w]),(0,i.useIsoLayoutEffect)(()=>{x.current&&I()}),(0,i.useIsoLayoutEffect)(()=>()=>{S.current?.disconnect(),x.current=!0},[]);let T=(0,r.useStableCallback)(e=>(h.add(e),()=>{h.delete(e)})),O=t.useMemo(()=>({register:E,unregister:R,subscribeMapChange:T,nextIndexRef:b}),[E,R,T,b]);return(0,s.jsx)(o.Provider,{value:O,children:c})}],53687)},73553,e=>{"use strict";var t=e.i(71645),n=e.i(46376),r=e.i(45356);e.s(["useCompositeListItem",0,function(e={}){let{guess:i,label:o,metadata:s,textRef:a,index:l}=e,{register:u,unregister:c,subscribeMapChange:d,nextIndexRef:f}=(0,r.useCompositeListContext)(),p=t.useRef(-1),[m,g]=t.useState(null==l&&i?()=>{if(-1===p.current){let e=f.current;f.current+=1,p.current=e}return p.current}:-1),h=l??m,v=t.useRef(null),b=t.useCallback(e=>{let t=v.current;t&&c(t),v.current=e,e&&u(e,{metadata:s??null,index:l??null,label:o,textRef:a})},[l,u,c,s,o,a]);return(0,n.useIsoLayoutEffect)(()=>{if(null==l)return d(e=>{let t=v.current?e.get(v.current)?.index:null;null!=t&&g(t)})},[l,d]),{ref:b,index:h}}])},19749,e=>{"use strict";var t=e.i(71645),n=e.i(90803),r=e.i(67865),i=e.i(28918),o=e.i(46376),s=e.i(56789),a=e.i(73327),l=e.i(21082),u=e.i(70359),c=e.i(84446);e.s(["useCompositeRoot",0,function(e){let{loopFocus:d=!0,orientation:f="both",grid:p,onLoop:m,direction:g,highlightedIndex:h,onHighlightedIndexChange:v,rootRef:b,enableHomeAndEndKeys:x=!1,stopEventPropagation:y,disabledIndices:S,modifierKeys:C=s.EMPTY_ARRAY}=e,[E,R]=t.useState(0),w=null!=p,I=t.useRef(null),T=(0,i.useMergedRefs)(I,b),O=t.useRef([]),k=t.useRef(!1),M=t.useRef(null),A=h??E,P=(0,r.useStableCallback)((e,t=!1)=>{if(M.current=O.current[e]??null,(v??R)(e),t){let t=O.current[e];(0,a.scrollIntoViewIfNeeded)(I.current,t,g,f)}}),N=(0,r.useStableCallback)(e=>{if(0===e.size)return;if(k.current){let e=O.current,t=e.indexOf(M.current);if(-1===t){let t=e[A];!t||(0,l.isListIndexDisabled)(e,A,S)?P(function(e,t){let n=-1;for(let r=0;r<e.length;r+=1){let i=e[r];if(!(!i||(0,l.isListIndexDisabled)(e,r,t))){if(i.hasAttribute(u.ACTIVE_COMPOSITE_ITEM))return r;-1===n&&(n=r)}}return Math.max(n,0)}(e,S)):M.current=t}else t!==A&&P(t);return}k.current=!0;let t=Array.from(e.keys()),n=t.find(e=>e?.hasAttribute(u.ACTIVE_COMPOSITE_ITEM))??null,r=n?e.get(n)?.index??-1:-1;if(-1!==r)P(r);else if((0,l.isListIndexDisabled)(t,A,S)){let e=(0,l.findNonDisabledListIndex)(t,{disabledIndices:S});(0,l.isIndexOutOfListBounds)(t,e)||P(e)}(0,a.scrollIntoViewIfNeeded)(I.current,n,g,f)});(0,o.useIsoLayoutEffect)(()=>{if(null==S||null!=h||!k.current)return;let e=O.current;if((0,l.isListIndexDisabled)(e,A,S)){let t=(0,l.findNonDisabledListIndex)(e,{disabledIndices:S});(0,l.isIndexOutOfListBounds)(e,t)||P(t)}},[S,h,A,O,P]);let j=(0,r.useStableCallback)((e,t,n)=>m?m(e,t,n,O):n),L=(0,r.useStableCallback)(e=>{let t=e.key===a.HOME||e.key===a.END;if(!a.COMPOSITE_KEYS.has(e.key)||!x&&t||function(e,t){for(let n of a.MODIFIER_KEYS)if(!t.includes(n)&&e.getModifierState(n))return!0;return!1}(e,C)||!I.current)return;let r="rtl"===g,i=r?a.ARROW_LEFT:a.ARROW_RIGHT,o=r?a.ARROW_RIGHT:a.ARROW_LEFT,s="vertical"===f?a.ARROW_DOWN:i,u="vertical"===f?a.ARROW_UP:o,h=(0,c.getTarget)(e.nativeEvent);if(null!=h&&(0,a.isNativeInput)(h)&&!(0,n.isElementDisabled)(h)){let t=h.selectionStart,n=h.selectionEnd,r=h.value;if(null==t||e.shiftKey||t!==n||e.key!==u&&t<r.length||e.key!==s&&t>0)return}let v=A,b=(0,l.getMinListIndex)(O,S),E=(0,l.getMaxListIndex)(O,S);null!=p&&(v=p({disabledIndices:S,elementsRef:O,event:e,highlightedIndex:A,loopFocus:d,maxIndex:E,minIndex:b,onLoop:j,orientation:f,rtl:r}));let R="vertical"!==f&&e.key===i||"horizontal"!==f&&e.key===a.ARROW_DOWN,T="vertical"!==f&&e.key===o||"horizontal"!==f&&e.key===a.ARROW_UP;x&&(e.key===a.HOME?v=b:e.key===a.END&&(v=E)),v===A&&(R||T)&&(d&&v===E&&R?(v=b,m&&(v=m(e,A,v,O))):d&&v===b&&T?(v=E,m&&(v=m(e,A,v,O))):v=(0,l.findNonDisabledListIndex)(O.current,{startingIndex:v,decrement:T,disabledIndices:S})),v===A||(0,l.isIndexOutOfListBounds)(O.current,v)||(y&&e.stopPropagation(),(w||t||R||T)&&e.preventDefault(),P(v,!0),queueMicrotask(()=>{O.current[v]?.focus()}))});return{props:{ref:T,onFocus(e){let t=I.current,n=(0,c.getTarget)(e.nativeEvent);t&&null!=n&&(0,a.isNativeInput)(n)&&n.setSelectionRange(0,n.value.length)},onKeyDown:L},highlightedIndex:A,onHighlightedIndexChange:P,elementsRef:O,onMapChange:N,relayKeyboardEvent:L}}])},72410,e=>{"use strict";e.i(47167);var t=e.i(71645);let n=t.createContext(void 0),r={disableStyleElements:!1};e.s(["useCSPContext",0,function(){return t.useContext(n)??r}])},72855,e=>{"use strict";e.i(47167);var t=e.i(71645);let n=t.createContext(void 0);e.s(["useDirection",0,function(){let e=t.useContext(n);return e?.direction??"ltr"}])},84325,42191,e=>{"use strict";let t=(e,t)=>Object.is(e,t);function n(e,t,n){return null==e||null==t?Object.is(e,t):n(e,t)}function r(e,t,r){return!!e&&e.some(e=>void 0!==e&&n(t,e,r))}function i(e,t,r){return e?e.findIndex(e=>void 0!==e&&n(e,t,r)):-1}function o(e,n,o,s){let a=s&&Array.isArray(n)?e.findIndex(function(e,n){if(n!==t)return t=>r(e,t,n);let i=new Set(e);return i.delete(void 0),t=>i.has(t)&&(0!==t||e.some(e=>Object.is(t,e)))}(n,o)):i(e,n,o);return -1===a?null:a}e.s(["compareItemEquality",0,n,"defaultItemEquality",0,t,"findItemIndex",0,i,"findSelectionIndex",0,o,"isSelectedValueDirty",0,function(e,t,r){return Array.isArray(e)&&Array.isArray(t)?!function(e,t,n=Object.is){let{length:r}=e;if(r!==t.length)return!1;for(let i=0;i<r;i+=1)if(!n(e[i],t[i]))return!1;return!0}(e,t,(e,t)=>n(e,t,r)):e!==t},"removeItem",0,function(e,t,r){return e.filter(e=>!n(t,e,r))},"resolveSelectedIndex",0,function(e,t,n,i,s,a){return r(i,t,s)?null!=a&&e>a&&r(i,n[a],s)?a:e:e===a?o(n,i,s,!0):a},"selectedValueIncludes",0,r],84325);var s=e.i(71645);function a(e){if(null==e)return"";if("string"==typeof e)return e;try{return JSON.stringify(e)}catch{return String(e)}}var l=e.i(43476);function u(e){var t;return"object"==typeof(t=e?.[0])&&null!=t&&Array.isArray(t.items)}function c(e){return u(e)?e.flatMap(e=>e.items):e}function d(e,t){if(t&&null!=e)return t(e)??"";if(e&&"object"==typeof e){if("label"in e&&null!=e.label)return String(e.label);if("value"in e)return String(e.value)}return a(e)}function f(e,t,n){if(n&&null!=e)return n(e);if(e&&"object"==typeof e&&"label"in e&&null!=e.label)return e.label;if(t&&!Array.isArray(t))return(Object.hasOwn(t,e)?t[e]:void 0)??d(e,n);if(Array.isArray(t)){let r=c(t);if(null==e||"object"!=typeof e){let t=r.find(t=>t.value===e);return t&&null!=t.label?t.label:d(e,n)}if("value"in e){let t=r.find(t=>t&&t.value===e.value);if(t&&null!=t.label)return t.label}}return d(e,n)}e.s(["flattenLeafItems",0,c,"hasNullItemLabel",0,function(e){if(!Array.isArray(e))return null!=e&&"null"in e;if(u(e)){for(let t of e)for(let e of t.items)if(e&&null==e.value&&null!=e.label)return!0;return!1}for(let t of e)if(t&&null==t.value&&null!=t.label)return!0;return!1},"isGroupedItems",0,u,"resolveMultipleLabels",0,function(e,t,n){return e.reduce((e,r,i)=>(i>0&&e.push(", "),e.push((0,l.jsx)(s.Fragment,{children:f(r,t,n)},i)),e),[])},"resolveSelectedLabel",0,f,"stringifyAsLabel",0,d,"stringifyAsValue",0,function(e,t){return t&&null!=e?t(e)??"":e&&"object"==typeof e&&"value"in e&&"label"in e?a(e.value):a(e)}],42191)},23706,9091,67387,e=>{"use strict";var t=e.i(71645),n=e.i(43084),r=e.i(8868),i=e.i(33848),o=e.i(46376),s=e.i(46265),a=e.i(67865),l=e.i(53760),u=e.i(58950),c=e.i(88643),d=e.i(72855);let f={name:"hide",async fn(e){let{width:t,height:n,x:r,y:i}=e.rects.reference,o=await e.platform.detectOverflow(e,{elementContext:"reference"});return{data:{referenceHidden:o.top-n>=0||o.right-t>=0||o.bottom-n>=0||o.left-t>=0||0===t&&0===n&&0===r&&0===i}}}},p={sideX:"left",sideY:"top"};e.s(["DEFAULT_SIDES",0,p],9091);let m="--available-width",g="--available-height",h="--anchor-width",v="--anchor-height",b="--transform-origin";function x(e,t,n){let r="inline-start"===e||"inline-end"===e;return({top:"top",right:r?n?"inline-start":"inline-end":"right",bottom:"bottom",left:r?n?"inline-end":"inline-start":"left"})[t]}function y(e,t,r){let{rects:i,placement:o}=e;return{side:x(t,(0,n.getSide)(o),r),align:(0,n.getAlignment)(o)||"center",anchor:{width:i.reference.width,height:i.reference.height},positioner:{width:i.floating.width,height:i.floating.height}}}function S(e){return null!=e&&"current"in e}e.s(["anchorHeight",0,v,"anchorWidth",0,h,"availableHeight",0,g,"availableWidth",0,m,"positionerHeight",0,"--positioner-height","positionerWidth",0,"--positioner-width","transformOrigin",0,b],67387),e.s(["useAnchorPositioning",0,function(e){return function(e,c){let{anchor:C,positionMethod:E="absolute",side:R="bottom",sideOffset:w=0,align:I="center",alignOffset:T=0,collisionBoundary:O,collisionPadding:k=5,sticky:M=!1,arrowPadding:A=5,disableAnchorTracking:P=!1,inline:N,keepMounted:j=!1,floatingRootContext:L,mounted:D,collisionAvoidance:z,shift:F,nodeId:H,adaptiveOrigin:V,lazyFlip:_=!1,externalTree:B}=e,[q,W]=t.useState(null);D||null===q||W(null);let $=z.side||"flip",U=z.align||"flip",K=z.fallbackAxisSide||"end",G=F?.crossAxis??!1,Y=F?.rootBoundary,Q="function"==typeof C?C:void 0,X=(0,a.useStableCallback)(Q),J=Q?X:C,Z=(0,s.useValueAsRef)(C),ee=(0,s.useValueAsRef)(D),et="rtl"===(0,d.useDirection)(),en=q||({top:"top",right:"right",bottom:"bottom",left:"left","inline-end":et?"left":"right","inline-start":et?"right":"left"})[R],er="center"===I?en:`${en}-${I}`,ei=k;"number"==typeof ei?ei={top:ei,right:ei,bottom:ei,left:ei}:ei&&(ei={top:ei.top||0,right:ei.right||0,bottom:ei.bottom||0,left:ei.left||0});let eo=+("bottom"===R),es=+("top"===R),ea=+("right"===R),el=+("left"===R),eu={boundary:"clipping-ancestors"===O?"clippingAncestors":O,padding:ei},ec=t.useRef(null),ed=(0,s.useValueAsRef)(w),ef=(0,s.useValueAsRef)(T),ep="function"!=typeof w?w:0,em="function"!=typeof T?T:0,eg=[];N&&eg.push(N),eg.push((0,u.offset)(e=>{let t=y(e,R,et),n="function"==typeof ed.current?ed.current(t):ed.current,r="function"==typeof ef.current?ef.current(t):ef.current;return{mainAxis:n,crossAxis:r,alignmentAxis:r}},[ep,em,et,R]));let eh="none"===U&&"shift"!==$,ev=!eh&&(M||G||"shift"===$),eb="none"===$?null:(0,u.flip)({...eu,padding:{top:ei.top+1+eo,right:ei.right+1+el,bottom:ei.bottom+1+es,left:ei.left+1+ea},mainAxis:!G&&"flip"===$,crossAxis:"flip"===U&&"alignment",fallbackAxisSideDirection:K}),ex=eh?null:(0,u.shift)({...eu,rootBoundary:Y,mainAxis:"none"!==U,crossAxis:ev,limiter:M||G?void 0:(0,u.limitShift)(e=>{if(!ec.current)return{};let{width:t,height:r}=ec.current.getBoundingClientRect(),i=(0,n.getSideAxis)((0,n.getSide)(e.placement)),o="y"===i?ei.left+ei.right:ei.top+ei.bottom;return{offset:("y"===i?t:r)/2+o/2}})},[eu,M,G,Y,ei,U]);"shift"===$||"shift"===U||"center"===I?eg.push(ex,eb):eg.push(eb,ex),eg.push((0,u.size)({...eu,apply({elements:{floating:e},availableWidth:t,availableHeight:n,rects:r}){if(!ee.current)return;let o=e.style;o.setProperty(m,`${t}px`),o.setProperty(g,`${n}px`);let s=(0,i.ownerWindow)(e).devicePixelRatio||1,{x:a,y:l,width:u,height:c}=r.reference,d=(Math.round((a+u)*s)-Math.round(a*s))/s,f=(Math.round((l+c)*s)-Math.round(l*s))/s;o.setProperty(h,`${d}px`),o.setProperty(v,`${f}px`)}}),((e,t)=>{let{name:r,fn:i}={name:"arrow",options:e,async fn(t){let{x:r,y:i,placement:o,rects:s,platform:a,elements:l,middlewareData:u}=t,{element:c,padding:d=0,offsetParent:f="real"}=(0,n.evaluate)(e,t)||{};if(null==c)return{};let p=(0,n.getPaddingObject)(d),m={x:r,y:i},g=(0,n.getAlignmentAxis)(o),h=(0,n.getAxisLength)(g),v=await a.getDimensions(c),b="y"===g,x=b?"clientHeight":"clientWidth",y=s.reference[h]+s.reference[g]-m[g]-s.floating[h],S=m[g]-s.reference[g],C="real"===f?await a.getOffsetParent?.(c):l.floating,E=l.floating[x]||s.floating[h];E&&await a.isElement?.(C)||(E=l.floating[x]||s.floating[h]);let R=E/2-v[h]/2-1,w=Math.min(p[b?"top":"left"],R),I=Math.min(p[b?"bottom":"right"],R),T=E-v[h]-I,O=E/2-v[h]/2+(y/2-S/2),k=(0,n.clamp)(w,O,T),M=!u.arrow&&null!=(0,n.getAlignment)(o)&&O!==k&&s.reference[h]/2-(O<w?w:I)-v[h]/2<0,A=M?O<w?O-w:O-T:0;return{[g]:m[g]+A,data:{[g]:k,centerOffset:O-k-A,...M&&{alignmentOffset:A}},reset:M}}};return{name:r,fn:i,options:[e,t]}})(e=>({element:ec.current||(0,r.ownerDocument)(e.elements.floating).createElement("div"),padding:ec.current?A:0,offsetParent:"floating"}),[A]),{name:"transformOrigin",fn(e){let t,{elements:{floating:r},middlewareData:i,placement:o,platform:s,rects:a,y:l}=e,u=(0,n.getSide)(o),c=(0,n.getAlignment)(o),d="y"===(0,n.getSideAxis)(u),f=ec.current,p="function"==typeof w?w(y(e,R,et)):w;if(!f&&c&&1>=Math.abs(d?i.shift?.x||0:i.shift?.y||0))t="start"===c===(d&&s.isRTL?.(r)===!0)?"100%":"0%";else{let e=d?i.arrow?.x||0:i.arrow?.y||0,n=d?f?.clientWidth||0:f?.clientHeight||0;t=`${e+n/2}px`}let m="top"===u||"left"===u?`calc(100% + ${p}px)`:`${-p}px`;return ev&&d&&Math.abs(i.shift?.y||0)>p&&(m=`${a.reference.y+a.reference.height/2-l}px`),r.style.setProperty(b,d?`${t} ${m}`:`${m} ${t}`),{}}},f,V),(0,o.useIsoLayoutEffect)(()=>{!D&&L&&L.update({referenceElement:null,floatingElement:null,domReferenceElement:null,positionReference:null})},[D,L]);let ey=t.useMemo(()=>({ancestorScroll:!P,elementResize:!P&&"u">typeof ResizeObserver,layoutShift:!P&&"u">typeof IntersectionObserver}),[P]),{refs:eS,elements:eC,x:eE,y:eR,middlewareData:ew,update:eI,placement:eT,context:eO,isPositioned:ek,floatingStyles:eM}=c({rootContext:L,open:j?D:void 0,placement:er,middleware:eg,strategy:E,whileElementsMounted:j?void 0:(...e)=>(0,l.autoUpdate)(...e,ey),nodeId:H,externalTree:B}),{sideX:eA,sideY:eP}=ew.adaptiveOrigin||p,eN=ek?E:"fixed",ej=t.useMemo(()=>{let e;return(e=ek?V?{position:eN,[eA]:eE,[eP]:eR}:{...eM,position:eN}:{position:eN,top:0,left:0})[m]="100vw",e[g]="100vh",ek||(e.opacity=0),e},[V,eN,eA,eE,eP,eR,eM,ek]),eL=t.useRef(null);(0,o.useIsoLayoutEffect)(()=>{if(!D)return;let e=Z.current,t="function"==typeof e?e():e,n=(S(t)?t.current:t)||null;n!==eL.current&&(eS.setPositionReference(n),eL.current=n)},[D,eS,J,Z]),t.useEffect(()=>{if(!D)return;let e=Z.current;"function"!=typeof e&&S(e)&&e.current!==eL.current&&(eS.setPositionReference(e.current),eL.current=e.current)},[D,eS,J,Z]),t.useEffect(()=>{if(j&&D&&eC.reference&&eC.floating)return(0,l.autoUpdate)(eC.reference,eC.floating,eI,ey)},[j,D,eC,eI,ey]);let eD=(0,n.getSide)(eT),ez=x(R,eD,et),eF=(0,n.getAlignment)(eT)||"center",eH=!!ew.hide?.referenceHidden;(0,o.useIsoLayoutEffect)(()=>{_&&D&&ek&&eD!==en&&W(eD)},[_,D,ek,eD,en]);let eV=t.useMemo(()=>({position:"absolute",top:ew.arrow?.y,left:ew.arrow?.x}),[ew.arrow]),e_=ew.arrow?.centerOffset!==0;return t.useMemo(()=>({positionerStyles:ej,arrowStyles:eV,arrowRef:ec,arrowUncentered:e_,side:ez,align:eF,physicalSide:eD,anchorHidden:eH,refs:eS,context:eO,isPositioned:ek,update:eI}),[ej,eV,ec,e_,ez,eF,eD,eH,eS,eO,ek,eI])}(e,c.useBaseUIFloating)}],23706)},61027,3414,78921,82370,89554,66506,85996,71714,81194,1545,91384,58307,64270,19712,82264,62050,82593,5953,7447,36481,74671,63947,77450,e=>{"use strict";e.s([],61027);var t=e.i(71645),n=e.i(33332);let r=t.createContext(void 0);function i(e){let i=t.useContext(r);if(void 0===i&&!e)throw Error((0,n.default)(33));return i}e.s(["MenuPositionerContext",0,r,"useMenuPositionerContext",0,i],3414);let o=t.createContext(void 0);function s(e){let r=t.useContext(o);if(void 0===r&&!e)throw Error((0,n.default)(36));return r}e.s(["MenuRootContext",0,o,"useMenuRootContext",0,s],78921);var a=e.i(52245),l=e.i(79938);let u=t.forwardRef(function(e,t){let{render:n,className:r,style:o,...u}=e,{store:c}=s(),{arrowRef:d,side:f,align:p,arrowUncentered:m,arrowStyles:g}=i(),h=c.useState("open");return(0,a.useRenderElement)("div",e,{ref:[d,t],stateAttributesMapping:l.popupStateMapping,state:{open:h,side:f,align:p,uncentered:m},props:{style:g,"aria-hidden":!0,...u}})});e.s(["MenuArrow",0,u],82370);let c=t.createContext(void 0);function d(e=!0){let r=t.useContext(c);if(void 0===r&&!e)throw Error((0,n.default)(25));return r}var f=e.i(56434);let p=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...o}=e,{store:u}=s(),c=u.useState("open"),p=u.useState("mounted"),m=u.useState("transitionStatus"),g=u.useState("lastOpenChangeReason"),h=d();return(0,a.useRenderElement)("div",e,{ref:h?.backdropRef?[t,h.backdropRef]:t,state:{open:c,transitionStatus:m},stateAttributesMapping:l.popupTransitionStateMapping,props:[{role:"presentation",hidden:!p,style:{pointerEvents:g===f.REASONS.triggerHover?"none":void 0,userSelect:"none",WebkitUserSelect:"none"}},o]})});e.s(["MenuBackdrop",0,p],89554);var m=e.i(51437),g=e.i(56789);let h=t.createContext(void 0);var v=e.i(28918),b=e.i(40886),x=e.i(76782),y=e.i(28744),S=e.i(64350);function C(e){let{closeOnClick:n,highlighted:r,id:i,nodeId:o,store:s,typingRef:a,itemRef:l,itemMetadata:u}=e,{events:c}=s.useState("floatingTreeRoot"),p=s.useState("open"),m=d(!0),g=void 0!==m;return t.useMemo(()=>({id:i,role:"menuitem",tabIndex:p&&r?0:-1,onKeyDown(e){" "===e.key&&a?.current&&e.preventDefault()},onMouseMove(e){o&&c.emit("itemhover",{nodeId:o,target:e.currentTarget})},onClick(e){n&&c.emit("close",{domEvent:e,reason:f.REASONS.itemPress})},onMouseUp(e){if(m){let t=m.initialCursorPointRef.current;if(m.initialCursorPointRef.current=null,g&&t&&1>=Math.abs(e.clientX-t.x)&&1>=Math.abs(e.clientY-t.y)||g&&!y.platform.os.mac&&2===e.button)return}l.current&&s.context.allowMouseUpTriggerRef.current&&(!g||2===e.button)&&"regular-item"===u.type&&(0,S.dispatchClickWithModifiers)(l.current,e,{detail:1})}}),[n,r,i,c,o,p,s,a,l,m,g,u])}let E={type:"regular-item"};function R(e){let{closeOnClick:n,disabled:r,highlighted:i,id:o,store:s,typingRef:a=s.context.typingRef,nativeButton:l,itemMetadata:u,nodeId:c}=e,d=t.useRef(null),{getButtonProps:f,buttonRef:p}=(0,b.useButton)({disabled:r,focusableWhenDisabled:!0,native:l,composite:!0}),m=C({closeOnClick:n,highlighted:i,id:o,nodeId:c,store:s,typingRef:a,itemRef:d,itemMetadata:u}),g=t.useCallback(e=>(0,x.mergeProps)(m,{onMouseEnter(){"submenu-trigger"===u.type&&u.setActive()}},e,f),[m,f,u]),h=(0,v.useMergedRefs)(d,p);return t.useMemo(()=>({getItemProps:g,itemRef:h}),[g,h])}e.s(["REGULAR_ITEM",0,E,"useMenuItem",0,R],66506);var w=e.i(73553),I=e.i(88015);let T={checked:e=>e?{"data-checked":""}:{"data-unchecked":""},...e.i(74354).transitionStatusMapping};var O=e.i(75606),k=e.i(43476);let M=t.forwardRef(function(e,n){let{render:r,className:o,id:l,label:u,nativeButton:c=!1,disabled:d=!1,closeOnClick:p=!1,checked:v,defaultChecked:b,onCheckedChange:x,style:y,...S}=e,C=(0,w.useCompositeListItem)({guess:!0,label:u}),M=i(!0),A=(0,I.useBaseUiId)(l),{store:P}=s(),N=P.useState("disabled"),j=d||N,L=P.useState("isActive",C.index),D=P.useState("itemProps"),[z,F]=(0,m.useControlled)({controlled:v,default:b??!1,name:"MenuCheckboxItem",state:"checked"}),{getItemProps:H,itemRef:V}=R({closeOnClick:p,disabled:j,highlighted:L,id:A,store:P,nativeButton:c,nodeId:M?.context.nodeId,itemMetadata:E}),_=t.useMemo(()=>({disabled:j,highlighted:L,checked:z}),[j,L,z]),B=(0,a.useRenderElement)("div",e,{state:_,stateAttributesMapping:T,props:[D,{role:"menuitemcheckbox","aria-checked":z,onClick:function(e){let t=(0,O.createChangeEventDetails)(f.REASONS.itemPress,e.nativeEvent,void 0,{preventUnmountOnClose:g.NOOP});x?.(!z,t),t.isCanceled||F(e=>!e)}},S,H],ref:[V,n,C.ref]});return(0,k.jsx)(h.Provider,{value:_,children:B})});e.s(["MenuCheckboxItem",0,M],85996);var A=e.i(23910),P=e.i(37584);let N=t.forwardRef(function(e,r){let{render:i,className:o,style:s,keepMounted:l=!1,...u}=e,c=function(){let e=t.useContext(h);if(void 0===e)throw Error((0,n.default)(30));return e}(),d=t.useRef(null),{transitionStatus:f,mounted:p,setMounted:m}=(0,A.useTransitionStatus)(c.checked);(0,P.useOpenChangeComplete)({batch:!0,enabled:!c.checked,open:c.checked,ref:d,onComplete(){c.checked||m(!1)}});let g={checked:c.checked,disabled:c.disabled,highlighted:c.highlighted,transitionStatus:f};return(0,a.useRenderElement)("span",e,{state:g,ref:[r,d],stateAttributesMapping:T,props:{"aria-hidden":!0,...u},enabled:l||p})});e.s(["MenuCheckboxItemIndicator",0,N],71714);let j=t.createContext(void 0),L=t.forwardRef(function(e,n){let{render:r,className:i,style:o,...s}=e,[l,u]=t.useState(void 0),c=(0,a.useRenderElement)("div",e,{ref:n,props:{role:"group","aria-labelledby":l,...s}});return(0,k.jsx)(j.Provider,{value:u,children:c})});e.s(["MenuGroup",0,L],81194);var D=e.i(46376);let z=t.forwardRef(function(e,r){let{render:i,className:o,style:s,id:l,...u}=e,c=(0,I.useBaseUiId)(l),d=function(){let e=t.useContext(j);if(void 0===e)throw Error((0,n.default)(31));return e}();return(0,D.useIsoLayoutEffect)(()=>(d(c),()=>{d(e=>e===c?void 0:e)}),[d,c]),(0,a.useRenderElement)("div",e,{ref:r,props:{id:c,"aria-hidden":!0,...u}})});e.s(["MenuGroupLabel",0,z],1545);let F=t.forwardRef(function(e,t){let{render:n,className:r,id:o,label:l,nativeButton:u=!1,disabled:c=!1,closeOnClick:d=!0,style:f,...p}=e,m=(0,w.useCompositeListItem)({guess:!0,label:l}),g=i(!0),h=(0,I.useBaseUiId)(o),{store:v}=s(),b=v.useState("disabled"),x=c||b,y=v.useState("isActive",m.index),S=v.useState("itemProps"),{getItemProps:C,itemRef:T}=R({closeOnClick:d,disabled:x,highlighted:y,id:h,store:v,nativeButton:u,nodeId:g?.context.nodeId,itemMetadata:E});return(0,a.useRenderElement)("div",e,{state:{disabled:x,highlighted:y},props:[S,p,C],ref:[T,t,m.ref]})});e.s(["MenuItem",0,F],91384);let H=t.forwardRef(function(e,n){let{render:r,className:o,id:l,label:u,closeOnClick:c=!1,style:d,...f}=e,p=t.useRef(null),m=(0,w.useCompositeListItem)({guess:!0,label:u}),g=i(!0),h=g?.context.nodeId,v=(0,I.useBaseUiId)(l),{store:y}=s(),S=y.useState("isActive",m.index),R=y.useState("itemProps"),T=y.context.typingRef,{getButtonProps:O,buttonRef:k}=(0,b.useButton)({native:!1,composite:!0}),M=C({closeOnClick:c,highlighted:S,id:v,nodeId:h,store:y,typingRef:T,itemRef:p,itemMetadata:E});return(0,a.useRenderElement)("a",e,{state:{highlighted:S},props:[R,f,function(e){return(0,x.mergeProps)(M,e,O)}],ref:[p,k,n,m.ref]})});e.s(["MenuLinkItem",0,H],58307);var V=e.i(61487),_=e.i(31157),B=e.i(96533),q=e.i(73327),W=e.i(53984);let $=t.forwardRef(function(e,n){let{render:r,className:o,style:u,finalFocus:c,...d}=e,{store:p}=s(),{side:m,align:g}=i(),h=null!=(0,B.useToolbarRootContext)(!0),v=p.useState("open"),b=p.useState("transitionStatus"),x=p.useState("popupProps"),y=p.useState("mounted"),S=p.useState("instantType"),C=p.useState("activeTriggerElement"),E=p.useState("parent"),R=p.useState("lastOpenChangeReason"),w=p.useState("rootId"),I=p.useState("floatingRootContext"),T=p.useState("floatingTreeRoot"),M=p.useState("closeDelay"),A=p.useState("hoverEnabled"),N=p.useState("disabled"),j=p.useState("openMethod"),L="context-menu"===E.type;(0,P.useOpenChangeComplete)({open:v,ref:p.context.popupRef,onComplete(){v&&p.context.onOpenChangeComplete?.(!0)}}),t.useEffect(()=>{function e(e){p.setOpen(!1,(0,O.createChangeEventDetails)(e.reason,e.domEvent))}return T.events.on("close",e),()=>{T.events.off("close",e)}},[T.events,p]),(0,_.useHoverFloatingInteraction)(I,{enabled:A&&!N&&!L&&"menubar"!==E.type,closeDelay:M});let D=p.useStateSetter("popupElement"),z={transitionStatus:b,side:m,align:g,open:v,nested:"menu"===E.type,instant:S},F=(0,a.useRenderElement)("div",e,{state:z,ref:[n,p.context.popupRef,D],stateAttributesMapping:l.popupTransitionStateMapping,props:[x,{onKeyDown(e){h&&q.COMPOSITE_KEYS.has(e.key)&&e.stopPropagation()}},(0,W.getDisabledMountTransitionStyles)(b),d,{"data-rootownerid":w}]}),H=void 0===E.type||L;return(C||"menubar"===E.type&&R!==f.REASONS.outsidePress)&&(H=!0),(0,k.jsx)(V.FloatingFocusManager,{context:I,openInteractionType:j,modal:L,disabled:!y,returnFocus:void 0===c?H:c,initialFocus:"menu"!==E.type,restoreFocus:!0,externalTree:"menubar"!==E.type?T:void 0,previousFocusableElement:C,nextFocusableElement:void 0===E.type?p.context.triggerFocusTargetRef:void 0,beforeContentFocusGuardRef:void 0===E.type?p.context.beforeContentFocusGuardRef:void 0,children:F})});e.s(["MenuPopup",0,$],64270);var U=e.i(26674);let K=t.createContext(void 0),G=t.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e,{store:i,parent:o}=s();if(!(i.useState("mounted")||n))return null;let a="menu"===o.type||"menubar"===o.type?"group":void 0;return(0,k.jsx)(K.Provider,{value:n,children:(0,k.jsx)(U.FloatingPortal,{ref:t,...r,portalOwnerRole:a})})});e.s(["MenuPortal",0,G],19712);var Y=e.i(44394),Q=e.i(39957),X=e.i(46420),J=e.i(23706),Z=e.i(53687),ee=e.i(426),et=e.i(38396),en=e.i(22640),er=e.i(89579),ei=e.i(33383);let eo=t.forwardRef(function(e,i){let{anchor:o,positionMethod:a="absolute",className:l,render:u,side:c,align:p,sideOffset:m=0,alignOffset:g=0,collisionBoundary:h="clipping-ancestors",collisionPadding:v=5,arrowPadding:b=5,sticky:x=!1,disableAnchorTracking:y=!1,collisionAvoidance:S=et.DROPDOWN_COLLISION_AVOIDANCE,style:C,...E}=e,{store:R}=s(),w=function(){let e=t.useContext(K);if(void 0===e)throw Error((0,n.default)(32));return e}(),I=d(!0),T=R.useState("parent"),M=R.useState("floatingRootContext"),A=R.useState("floatingTreeRoot"),P=R.useState("mounted"),N=R.useState("open"),j=R.useState("modal"),L=R.useState("openMethod"),z=R.useState("activeTriggerElement"),F=R.useState("transitionStatus"),H=R.useState("positionerElement"),V=R.useState("instantType"),_=R.useState("adaptiveOrigin"),B=R.useState("lastOpenChangeReason"),q=R.useState("floatingNodeId"),W=R.useState("floatingParentNodeId"),$=M.useState("domReferenceElement"),U=t.useRef(null),G=(0,en.useAnimationsFinished)(H),eo=o,es=m,ea=g,el=p,eu=S;"context-menu"===T.type&&(eo=o??T.context?.anchor,el=el??"start",c||"center"===el||(ea=e.alignOffset??2,es=e.sideOffset??-5));let ec=c,ed=el;"menu"===T.type?(ec=ec??"inline-end",ed=ed??"start",eu=e.collisionAvoidance??et.POPUP_COLLISION_AVOIDANCE):"menubar"===T.type&&(ec=ec??("vertical"===T.context.orientation?"inline-end":"bottom"),ed=ed??"start");let ef="context-menu"===T.type,ep=(0,J.useAnchorPositioning)({anchor:eo,floatingRootContext:M,positionMethod:I?"fixed":a,mounted:P,side:ec,sideOffset:es,align:ed,alignOffset:ea,arrowPadding:ef?0:b,collisionBoundary:h,collisionPadding:v,sticky:x,nodeId:q,keepMounted:w,disableAnchorTracking:y,collisionAvoidance:eu,shift:ef?{crossAxis:!("side"in eu&&"flip"===eu.side),rootBoundary:"layoutViewport"}:void 0,externalTree:A,adaptiveOrigin:_});t.useEffect(()=>{function e(e){e.open&&(e.parentNodeId===q&&R.set("hoverEnabled",!1),e.nodeId!==q&&e.parentNodeId===R.select("floatingParentNodeId")&&R.setOpen(!1,(0,O.createChangeEventDetails)(f.REASONS.siblingOpen)))}return A.events.on("menuopenchange",e),()=>{A.events.off("menuopenchange",e)}},[R,A.events,q]),t.useEffect(()=>{if(null!=R.select("floatingParentNodeId"))return A.events.on("menuopenchange",e),()=>{A.events.off("menuopenchange",e)};function e(e){if(e.open||e.nodeId!==R.select("floatingParentNodeId"))return;let t=e.reason??f.REASONS.siblingOpen;R.setOpen(!1,(0,O.createChangeEventDetails)(t))}},[A.events,R]);let em=(0,Q.useTimeout)();t.useEffect(()=>{N||em.clear()},[N,em]),t.useEffect(()=>{function e(e){if(N&&e.nodeId===R.select("floatingParentNodeId"))if(e.target&&z&&z!==e.target){let e=R.select("closeDelay");e>0?em.isStarted()||em.start(e,()=>{R.setOpen(!1,(0,O.createChangeEventDetails)(f.REASONS.siblingOpen))}):R.setOpen(!1,(0,O.createChangeEventDetails)(f.REASONS.siblingOpen))}else em.clear()}return A.events.on("itemhover",e),()=>{A.events.off("itemhover",e)}},[A.events,N,z,R,em]),t.useEffect(()=>{let e={open:N,nodeId:q,parentNodeId:W,reason:R.select("lastOpenChangeReason")};A.events.emit("menuopenchange",e)},[A.events,N,R,q,W]),(0,D.useIsoLayoutEffect)(()=>{let e=U.current;if($&&(U.current=$),e&&$&&$!==e){R.set("instantType",void 0);let e=new AbortController;return G(()=>{R.set("instantType","trigger-change")},e.signal),()=>{e.abort()}}},[$,G,R]);let eg={open:N,side:ep.side,align:ep.align,anchorHidden:ep.anchorHidden,nested:"menu"===T.type,instant:V},eh="menubar"===T.type&&T.context.modal,ev=j&&B!==f.REASONS.triggerHover;(0,ei.useAnchoredPopupScrollLock)(N&&(eh||ev),"touch"===L,H,z);let eb=(0,er.usePositioner)(e,eg,{styles:ep.positionerStyles,transitionStatus:F,props:E,refs:[i,R.useStateSetter("positionerElement")],hidden:!P,inert:!N}),ex=P&&"menu"!==T.type&&("menubar"!==T.type&&j&&B!==f.REASONS.triggerHover||"menubar"===T.type&&T.context.modal),ey=null;return"menubar"===T.type?ey=T.context.contentElement:void 0===T.type&&(ey=z),(0,k.jsxs)(r.Provider,{value:ep,children:[ex&&(0,k.jsx)(ee.InternalBackdrop,{ref:"context-menu"===T.type||"nested-context-menu"===T.type?T.context.internalBackdropRef:null,inert:(0,Y.inertValue)(!N),cutout:ey}),(0,k.jsx)(X.FloatingNode,{id:q,children:(0,k.jsx)(Z.CompositeList,{elementsRef:R.context.itemDomElements,labelsRef:R.context.itemLabels,children:eb})})]})});e.s(["MenuPositioner",0,eo],82264);var es=e.i(67865);let ea=t.createContext(void 0),el=t.memo(t.forwardRef(function(e,n){let{render:r,className:i,value:o,defaultValue:s,onValueChange:l,disabled:u=!1,style:c,"aria-labelledby":d,...f}=e,[p,g]=t.useState(void 0),[h,v]=(0,m.useControlled)({controlled:o,default:s,name:"MenuRadioGroup"}),b=(0,es.useStableCallback)((e,t)=>{l?.(e,t),t.isCanceled||v(e)}),x=(0,a.useRenderElement)("div",e,{state:{disabled:u},ref:n,props:{role:"group","aria-labelledby":d??p,"aria-disabled":u||void 0,...f}}),y=t.useMemo(()=>({value:h,setValue:b,disabled:u}),[h,b,u]);return(0,k.jsx)(j.Provider,{value:g,children:(0,k.jsx)(ea.Provider,{value:y,children:x})})}));e.s(["MenuRadioGroup",0,el],62050);let eu=t.createContext(void 0),ec=t.forwardRef(function(e,r){let{render:o,className:l,id:u,label:c,nativeButton:d=!1,disabled:p=!1,closeOnClick:m=!1,value:h,style:v,...b}=e,x=(0,w.useCompositeListItem)({guess:!0,label:c}),y=i(!0),S=(0,I.useBaseUiId)(u),{store:C}=s(),M=C.useState("isActive",x.index),A=C.useState("itemProps"),{value:P,setValue:N,disabled:j}=function(){let e=t.useContext(ea);if(void 0===e)throw Error((0,n.default)(34));return e}(),L=C.useState("disabled"),D=p||j||L,z=P===h,{getItemProps:F,itemRef:H}=R({closeOnClick:m,disabled:D,highlighted:M,id:S,store:C,nativeButton:d,nodeId:y?.context.nodeId,itemMetadata:E}),V=t.useMemo(()=>({disabled:D,highlighted:M,checked:z}),[D,M,z]),_=(0,a.useRenderElement)("div",e,{state:V,stateAttributesMapping:T,props:[A,{role:"menuitemradio","aria-checked":z,onClick:function(e){N(h,(0,O.createChangeEventDetails)(f.REASONS.itemPress,e.nativeEvent,void 0,{preventUnmountOnClose:g.NOOP}))}},b,F],ref:[H,r,x.ref]});return(0,k.jsx)(eu.Provider,{value:V,children:_})});e.s(["MenuRadioItem",0,ec],82593);let ed=t.forwardRef(function(e,r){let{render:i,className:o,style:s,keepMounted:l=!1,...u}=e,c=function(){let e=t.useContext(eu);if(void 0===e)throw Error((0,n.default)(35));return e}(),d=t.useRef(null),{transitionStatus:f,mounted:p,setMounted:m}=(0,A.useTransitionStatus)(c.checked);(0,P.useOpenChangeComplete)({batch:!0,enabled:!c.checked,open:c.checked,ref:d,onComplete(){c.checked||m(!1)}});let g={checked:c.checked,disabled:c.disabled,highlighted:c.highlighted,transitionStatus:f};return(0,a.useRenderElement)("span",e,{state:g,stateAttributesMapping:T,ref:[r,d],props:{"aria-hidden":!0,...u},enabled:l||p})});e.s(["MenuRadioItemIndicator",0,ed],5953);var ef=e.i(83977),ep=e.i(88940),em=e.i(96499),eg=e.i(17989),eh=e.i(60891),ev=e.i(5049),eb=e.i(50527);let ex=t.createContext(null);function ey(e){let r=t.useContext(ex);if(null===r&&!e)throw Error((0,n.default)(5));return r}e.s(["useMenubarContext",0,ey],7447);var eS=e.i(72855),eC=e.i(32199),eE=e.i(26352),eR=e.i(79248),ew=e.i(18478),eI=e.i(16786),eT=e.i(90627);let eO={...eI.popupStoreSelectors,disabled:e=>"menubar"===e.parent.type&&e.parent.context.disabled||e.disabled,modal:e=>(void 0===e.parent.type||"context-menu"===e.parent.type)&&(e.modal??!0),openMethod:e=>e.openMethod,allowMouseEnter:e=>e.allowMouseEnter,highlightItemOnHover:e=>e.highlightItemOnHover,parent:e=>e.parent,rootId:e=>"menu"===e.parent.type?e.parent.store.select("rootId"):void 0!==e.parent.type?e.parent.context.rootId:e.rootId,activeIndex:e=>e.activeIndex,isActive:(e,t)=>e.activeIndex===t,hoverEnabled:e=>e.hoverEnabled,instantType:e=>e.instantType,lastOpenChangeReason:e=>e.openChangeReason,floatingTreeRoot:e=>"menu"===e.parent.type?e.parent.store.select("floatingTreeRoot"):e.floatingTreeRoot,floatingNodeId:e=>e.floatingNodeId,floatingParentNodeId:e=>e.floatingParentNodeId,itemProps:e=>e.itemProps,closeDelay:e=>e.closeDelay,adaptiveOrigin:e=>e.adaptiveOrigin,keyboardEventRelay:e=>e.keyboardEventRelay?e.keyboardEventRelay:"menu"===e.parent.type?e.parent.store.select("keyboardEventRelay"):void 0};class ek extends eE.ReactStore{constructor(e,t,n=!1){const r=new eT.PopupTriggerMap;super(eA(r,t,n,e),eM(r),eO),this.unsubscribeParentListener=this.observe("parent",e=>{if(this.unsubscribeParentListener?.(),"menu"===e.type){let t=e.store.select("rootId"),n=e.store.select("floatingTreeRoot"),r=e.store.select("keyboardEventRelay");this.unsubscribeParentListener=e.store.subscribe(()=>{let i=e.store.select("rootId"),o=e.store.select("floatingTreeRoot"),s=e.store.select("keyboardEventRelay");(t!==i||n!==o||r!==s)&&(t=i,n=o,r=s,this.notifyAll())}),this.context.allowMouseUpTriggerRef=e.store.context.allowMouseUpTriggerRef;return}void 0!==e.type&&(this.context.allowMouseUpTriggerRef=e.context.allowMouseUpTriggerRef),this.unsubscribeParentListener=null})}setOpen(e,t){this.state.floatingRootContext.context.events.emit("setOpen",{open:e,eventDetails:t})}unsubscribeParentListener=null}function eM(e){return{positionerRef:t.createRef(),popupRef:t.createRef(),typingRef:{current:!1},itemDomElements:{current:[]},itemLabels:{current:[]},allowMouseUpTriggerRef:{current:!1},triggerFocusTargetRef:t.createRef(),beforeContentFocusGuardRef:t.createRef(),onOpenChangeComplete:void 0,triggerElements:e}}function eA(e,t,n=!1,r){return{...(0,eI.createInitialPopupStoreState)(e,t,n),disabled:!1,modal:!0,openMethod:null,allowMouseEnter:!1,highlightItemOnHover:!0,parent:{type:void 0},rootId:void 0,activeIndex:null,hoverEnabled:!0,instantType:void 0,openChangeReason:null,floatingTreeRoot:new eR.FloatingTreeStore,floatingNodeId:void 0,floatingParentNodeId:null,itemProps:g.EMPTY_OBJECT,keyboardEventRelay:void 0,closeDelay:0,adaptiveOrigin:void 0,...r}}e.s(["MenuStore",0,ek,"createNullMenuStore",0,function(){let e=new eT.PopupTriggerMap;return Object.assign(new ew.NullStore(Object.freeze(eA(e)),Object.freeze(eM(e)),eO),{setOpen:g.NOOP})}],36481);var eP=e.i(64111);let eN=t.createContext(void 0);function ej(){return t.useContext(eN)}e.s(["MenuSubmenuRootContext",0,eN,"useMenuSubmenuRootContext",0,ej],74671);let eL=(0,em.fastComponent)(function(e){var n,r,i;let a,{children:l,open:u,onOpenChange:c,onOpenChangeComplete:p,defaultOpen:m=!1,disabled:h=!1,modal:v,loopFocus:b=!0,orientation:y="vertical",actionsRef:S,closeParentOnEsc:C=!1,handle:E,triggerId:R,defaultTriggerId:w=null,highlightItemOnHover:I=!0}=e,T=d(!0),M=s(!0),A=ey(!0),P=ej(),N=t.useMemo(()=>P&&M?{type:"menu",store:M.store}:A?{type:"menubar",context:A}:T&&!M?{type:"context-menu",context:T}:{type:void 0},[T,M,A,P]),j=(0,ef.useId)(),L=(0,ef.useId)(),z=(0,X.useFloatingParentNodeId)(),F="menu"===N.type?N.store:void 0,H=(u??m)&&F?.state.transitionStatus==="starting",V=(0,ep.useRefWithInit)(()=>H?F?.state.instantType:void 0).current,_=(n={open:m,openProp:u,activeTriggerId:w,triggerIdProp:R,parent:N,disabled:h,highlightItemOnHover:I,modal:void 0===N.type?v:void 0,rootId:j,instantType:V},r=L,i=null!=z,(0,ep.useRefWithInit)(()=>new ek(n,r,i)).current);_.useControlledProp("openProp",u),_.useControlledProp("triggerIdProp",R),_.useContextCallback("onOpenChangeComplete",p);let B=_.useState("floatingTreeRoot"),q=(0,X.useFloatingNodeId)(B),W=_.useState("open"),$=_.useState("activeTriggerElement"),U=_.useState("positionerElement"),K=_.useState("hoverEnabled"),G=_.useState("disabled"),Y=_.useState("lastOpenChangeReason"),J=_.useState("parent"),Z=_.useState("activeIndex"),ee=_.useState("payload"),er=_.useState("floatingParentNodeId"),ei=t.useRef(null),eo=t.useRef("context-menu"!==J.type),ea=(0,Q.useTimeout)(),el=t.useRef(!0),eu=(0,Q.useTimeout)(),ec=null!=er,{openMethod:ed,triggerProps:em}=(0,eC.useOpenInteractionType)(W);_.useSyncedValues({disabled:h,highlightItemOnHover:I,modal:void 0===J.type?v:void 0,openMethod:ed,rootId:j}),(0,eP.useImplicitActiveTrigger)(_);let{forceUnmount:ex,transitionStatus:eE}=(0,eP.useOpenStateTransitions)(W,_,()=>{_.set("allowMouseEnter",!1)},H),eR=(0,en.useAnimationsFinished)(_.context.popupRef);t.useEffect(()=>{if(void 0===V)return;let e=()=>{_.state.instantType===V&&_.set("instantType",void 0)};if(!W)return void e();if(void 0!==eE)return;if(null==_.context.popupRef.current)return void e();let t=new AbortController;return eR(e,t.signal),()=>{t.abort()}},[V,W,eE,eR,_]),(0,D.useIsoLayoutEffect)(()=>{T&&!M?_.update({parent:{type:"context-menu",context:T},floatingNodeId:q,floatingParentNodeId:z}):M&&_.update({floatingNodeId:q,floatingParentNodeId:z})},[T,M,q,z,_]),t.useEffect(()=>{if(W||(ei.current=null),"context-menu"===J.type){if(!W){ea.clear(),eo.current=!1;return}ea.start(500,()=>{eo.current=!0})}},[ea,W,J.type]),(0,D.useIsoLayoutEffect)(()=>{W||K||_.set("hoverEnabled",!0)},[W,K,_]);let ew=(0,es.useStableCallback)((e,t)=>{let n=t.reason;if(!e&&!_.select("open")||W===e&&t.trigger===$&&Y===n)return;let r=(0,eP.attachPreventUnmountOnClose)(t);if(e||null!=t.trigger||(t.trigger=$??void 0),c?.(e,t),t.isCanceled)return;_.state.floatingRootContext.dispatchOpenChange(e,t);let i=t.event;if(!1===e&&i?.type==="click"&&"touch"===i.pointerType&&!el.current)return;e&&n===f.REASONS.triggerFocus?(el.current=!1,eu.start(300,()=>{el.current=!0})):(el.current=!0,eu.clear());let o=(n===f.REASONS.triggerPress||n===f.REASONS.itemPress)&&0===i.detail,s=!e&&(n===f.REASONS.escapeKey||null==n);ei.current=t.event;let a=(0,eP.createPopupOpenState)(_.state,e,t.trigger,r());a.openChangeReason=n,"menubar"===J.type&&(n===f.REASONS.triggerFocus||n===f.REASONS.focusOut||n===f.REASONS.triggerHover||n===f.REASONS.listNavigation||n===f.REASONS.siblingOpen)?a.instantType="group":o||s?a.instantType=o?"click":"dismiss":a.instantType=void 0,_.update(a)}),eI=(0,eb.useSyncedFloatingRootContext)({popupStore:_,floatingRootContext:_.state.floatingRootContext,floatingId:L,nested:null!=z,onOpenChange:ew}),eT=eI.context.events;(0,D.useIsoLayoutEffect)(()=>{let e=({open:e,eventDetails:t})=>ew(e,t);return eT.on("setOpen",e),()=>{eT?.off("setOpen",e)}},[eT,ew]);let eO=t.useCallback(()=>{_.setOpen(!1,(0,O.createChangeEventDetails)(f.REASONS.imperativeAction))},[_]);t.useImperativeHandle(S,()=>({unmount:ex,close:eO}),[ex,eO]),"context-menu"===J.type&&(a=J.context),t.useImperativeHandle(a?.positionerRef,()=>U,[U]),t.useImperativeHandle(a?.actionsRef,()=>({setOpen:ew}),[ew]);let eM=(0,eg.useDismiss)(eI,{enabled:!G,bubbles:{escapeKey:C&&"menu"===J.type},outsidePress:()=>"context-menu"!==J.type||ei.current?.type==="contextmenu"||eo.current,externalTree:ec?B:void 0}),eA=(0,eS.useDirection)(),eN=t.useCallback(e=>{_.select("activeIndex")!==e&&_.set("activeIndex",e)},[_]),eL=(0,eh.useListNavigation)(eI,{enabled:!G,listRef:_.context.itemDomElements,activeIndex:Z,nested:void 0!==J.type,loopFocus:b,orientation:y,parentOrientation:"menubar"===J.type?J.context.orientation:void 0,rtl:"rtl"===eA,disabledIndices:g.EMPTY_ARRAY,onNavigate:eN,openOnArrowKeyDown:"context-menu"!==J.type,externalTree:ec?B:void 0,focusItemOnHover:I}),eD=t.useCallback(e=>{_.context.typingRef.current=e},[_]),ez=(0,ev.useTypeahead)(eI,{enabled:!G,listRef:_.context.itemLabels,elementsRef:_.context.itemDomElements,activeIndex:Z,resetMs:et.TYPEAHEAD_RESET_MS,onMatch:e=>{W&&e!==Z&&_.set("activeIndex",e)},onTyping:eD}),eF=t.useMemo(()=>{let e=(0,x.mergeProps)(ez.reference,eL.reference,eM.reference,{onMouseMove(){_.set("allowMouseEnter",!0)}},em);return e["aria-haspopup"]="menu",e["aria-expanded"]=W,e},[_,ez.reference,eL.reference,eM.reference,em,W]),eH=t.useMemo(()=>{let e=(0,x.mergeProps)(eL.trigger,eM.trigger,em);return e["aria-haspopup"]="menu",e["aria-expanded"]=!1,e},[eL.trigger,eM.trigger,em]);(0,ep.useRefWithInit)(()=>(_.update({inactiveTriggerProps:eH}),null));let eV=t.useMemo(()=>(0,x.mergeProps)(eP.FOCUSABLE_POPUP_PROPS,{id:L,role:"menu","aria-orientation":"horizontal"===y?"horizontal":void 0,"aria-labelledby":$?.id,onMouseMove(){_.set("allowMouseEnter",!0),"menu"===J.type&&_.set("hoverEnabled",!1)},onClick(){_.select("hoverEnabled")&&_.set("hoverEnabled",!1)},onKeyDown(e){let t=_.select("keyboardEventRelay");t&&!e.isPropagationStopped()&&t(e)}},ez.floating,eL.floating,eM.floating),[$,L,y,J.type,_,ez.floating,eL.floating,eM.floating]),e_=eL.item??g.EMPTY_OBJECT;(0,eP.usePopupInteractionProps)(_,{floatingRootContext:eI,activeTriggerProps:eF,inactiveTriggerProps:eH,popupProps:eV,itemProps:e_});let eB=t.useMemo(()=>({store:_,parent:N}),[_,N]),eq=(0,k.jsxs)(o.Provider,{value:eB,children:[E&&(0,k.jsx)(eP.PopupHandleAttachment,{handle:E,store:_}),"function"==typeof l?l({payload:ee}):l]});return void 0===J.type||"context-menu"===J.type?(0,k.jsx)(X.FloatingTree,{externalTree:B,children:eq}):eq});e.s(["MenuRoot",0,eL],63947),e.s(["MenuSubmenuRoot",0,function(e){let n=s().store,r=t.useMemo(()=>({parentMenu:n}),[n]);return(0,k.jsx)(eN.Provider,{value:r,children:(0,k.jsx)(eL,{...e})})}],77450)},92235,10913,64493,69153,40370,89244,e=>{"use strict";var t=e.i(71645),n=e.i(29315),r=e.i(61487),i=e.i(31157),o=e.i(22646),s=e.i(73336),a=e.i(79938),l=e.i(37584),u=e.i(52245),c=e.i(56434),d=e.i(73327),f=e.i(96533),p=e.i(53984),m=e.i(46376),g=e.i(67865);let h=t.createContext(void 0);var v=e.i(64111),b=e.i(43476);let x=t.forwardRef(function(e,m){let{render:x,className:y,style:S,initialFocus:C,finalFocus:E,...R}=e,w=(0,o.usePopoverRootContext)(),I=(0,s.usePopoverPositionerContext)(),T=null!=(0,f.useToolbarRootContext)(!0),{context:O,hasClosePart:k}=function(){let[e,n]=t.useState(0),r=(0,g.useStableCallback)(()=>(n(e=>e+1),()=>{n(e=>Math.max(0,e-1))}));return{context:t.useMemo(()=>({register:r}),[r]),hasClosePart:e>0}}(),M=w.useState("open"),A=w.useState("openMethod"),P=w.useState("instantType"),N=w.useState("transitionStatus"),j=w.useState("popupProps"),L=w.useState("titleElementId"),D=w.useState("descriptionElementId"),z=w.useState("modal"),F=w.useState("mounted"),H=w.useState("openChangeReason"),V=w.useState("activeTriggerElement"),_=w.useState("floatingRootContext"),B=_.useState("floatingId"),q=w.useState("disabled"),W=w.useState("openOnHover"),$=w.useState("closeDelay");(0,l.useOpenChangeComplete)({open:M,ref:w.context.popupRef,onComplete(){M&&w.context.onOpenChangeComplete?.(!0)}}),(0,i.useHoverFloatingInteraction)(_,{enabled:W&&!q,closeDelay:$});let U=void 0===C?(0,v.createDefaultInitialFocus)(w.context.popupRef):C,K=!1!==z&&k;w.useSyncedValue("focusManagerModal",K);let G=w.useStateSetter("popupElement"),Y={open:M,side:I.side,align:I.align,instant:P,transitionStatus:N},Q=(0,u.useRenderElement)("div",e,{state:Y,ref:[m,w.context.popupRef,G],props:[j,{id:B,role:"dialog",...v.FOCUSABLE_POPUP_PROPS,"aria-labelledby":L,"aria-describedby":D,onKeyDown(e){T&&d.COMPOSITE_KEYS.has(e.key)&&e.stopPropagation()}},(0,p.getDisabledMountTransitionStyles)(N),R],stateAttributesMapping:a.popupTransitionStateMapping});return(0,b.jsx)(r.FloatingFocusManager,{context:_,openInteractionType:A,modal:K,disabled:!F||H===c.REASONS.triggerHover,initialFocus:U,returnFocus:E,restoreFocus:"popup",previousFocusableElement:(0,n.isHTMLElement)(V)?V:void 0,nextFocusableElement:w.context.triggerFocusTargetRef,beforeContentFocusGuardRef:w.context.beforeContentFocusGuardRef,children:(0,b.jsx)(h.Provider,{value:O,children:Q})})});e.s(["PopoverPopup",0,x],92235);let y=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...l}=e,c=(0,o.usePopoverRootContext)().useState("open"),{arrowRef:d,side:f,align:p,arrowUncentered:m,arrowStyles:g}=(0,s.usePopoverPositionerContext)();return(0,u.useRenderElement)("div",e,{state:{open:c,side:f,align:p,uncentered:m},ref:[t,d],props:[{style:g,"aria-hidden":!0},l],stateAttributesMapping:a.popupStateMapping})});e.s(["PopoverArrow",0,y],10913);let S=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...s}=e,l=(0,o.usePopoverRootContext)(),d=l.useState("open"),f=l.useState("mounted"),p=l.useState("transitionStatus"),m=l.useState("openChangeReason");return(0,u.useRenderElement)("div",e,{state:{open:d,transitionStatus:p},ref:t,props:[{role:"presentation",hidden:!f,style:{pointerEvents:m===c.REASONS.triggerHover?"none":void 0,userSelect:"none",WebkitUserSelect:"none"}},s],stateAttributesMapping:a.popupTransitionStateMapping})});e.s(["PopoverBackdrop",0,S],64493);var C=e.i(88015);let E=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...s}=e,a=(0,o.usePopoverRootContext)(),l=(0,C.useBaseUiId)(s.id);return a.useSyncedValueWithCleanup("titleElementId",l),(0,u.useRenderElement)("h2",e,{ref:t,props:[{id:l},s]})});e.s(["PopoverTitle",0,E],69153);let R=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...s}=e,a=(0,o.usePopoverRootContext)(),l=(0,C.useBaseUiId)(s.id);return a.useSyncedValueWithCleanup("descriptionElementId",l),(0,u.useRenderElement)("p",e,{ref:t,props:[{id:l},s]})});e.s(["PopoverDescription",0,R],40370);var w=e.i(40886),I=e.i(75606);let T=t.forwardRef(function(e,n){let r,{render:i,className:s,style:a,disabled:l=!1,nativeButton:d=!0,...f}=e,{buttonRef:p,getButtonProps:g}=(0,w.useButton)({disabled:l,focusableWhenDisabled:!1,native:d}),v=(0,o.usePopoverRootContext)();return r=t.useContext(h),(0,m.useIsoLayoutEffect)(()=>r?.register(),[r]),(0,u.useRenderElement)("button",e,{ref:[n,p],props:[{onClick(e){v.setOpen(!1,(0,I.createChangeEventDetails)(c.REASONS.closePress,e.nativeEvent))}},f,g]})});e.s(["PopoverClose",0,T],89244)},59657,e=>{"use strict";e.s([])},49637,73364,e=>{"use strict";var t,n=e.i(71645),r=e.i(29315),i=e.i(46802),o=e.i(33848),s=e.i(18593),a=e.i(93737),l=e.i(52245),u=e.i(43084);function c(e){let t=(0,r.getComputedStyle)(e),n=parseFloat(t.width)||0,i=parseFloat(t.height)||0,o=(0,r.isHTMLElement)(e),s=o?e.offsetWidth:n,a=o?e.offsetHeight:i;return((0,u.round)(n)!==s||(0,u.round)(i)!==a)&&(n=s,i=a),{width:n,height:i}}e.s(["getCssDimensions",0,c],73364);var d=e.i(1634),f=e.i(81524),p=e.i(7120),m=e.i(43476);let g={...f.tabsStateAttributesMapping,activeTabPosition:()=>null,activeTabSize:()=>null},h=n.forwardRef(function(e,u){let{className:f,render:h,renderBeforeHydration:x=!1,style:y,...S}=e,{getTabElementBySelectedValue:C,orientation:E,tabActivationDirection:R,value:w}=(0,d.useTabsRootContext)(),{tabsListElement:I,registerIndicatorUpdateListener:T}=(0,p.useTabsListContext)(),O=(0,i.useForcedRerendering)();n.useEffect(()=>T(O),[T,O]);let k=0,M=0,A=0,P=0,N=0,j=0,L=!1;if(null!=w&&null!=I){let e=C(w);if(null!=e){L=!0;let{width:t,height:n}=c(e),{width:i,height:s}=c(I),a=e.getBoundingClientRect(),l=I.getBoundingClientRect(),u=i>0?l.width/i:1,d=s>0?l.height/s:1,f=function(e,t){let n=v(e),i=v(t),o=n.left-i.left-t.clientLeft,s=n.top-i.top-t.clientTop,a=(0,r.getParentNode)(e);for(;(0,r.isHTMLElement)(a)&&a!==t&&!(0,r.isLastTraversableNode)(a);)o-=a.scrollLeft,s-=a.scrollTop,a=(0,r.getParentNode)(a);return{left:o,top:s}}(e,I);k=f.left,A=f.top;let p=(a.left-l.left)/u+I.scrollLeft-I.clientLeft,m=(a.top-l.top)/d+I.scrollTop-I.clientTop,g=function(e){let t=(0,o.ownerWindow)(e).getComputedStyle(e),{x:n,y:r}=function(e,t){let n=(t??(0,o.ownerWindow)(e).getComputedStyle(e)).transform,r=0,i=0,s=1;if(n&&"none"!==n){let e=n.match(/matrix(?:3d)?\(([^)]+)\)/);if(e){let t=e[1].split(", ").map(parseFloat);6===t.length?(r=t[4],i=t[5],s=Math.sqrt(t[0]*t[0]+t[1]*t[1])):16===t.length&&(r=t[12],i=t[13],s=t[0])}}return{x:r,y:i,scale:s}}(e,t),i=n,s=r,{translate:a}=t;if(a&&"none"!==a){let t=a.split(" ");i+=b(t[0],e.offsetWidth),s+=b(t[1],e.offsetHeight)}return{x:i,y:s}}(e);2>=Math.abs(p-g.x-k)&&2>=Math.abs(m-g.y-A)&&(k=p,A=m),N=t,j=n,M=I.scrollWidth-k-N,P=I.scrollHeight-A-j}}let D=L?{left:k,right:M,top:A,bottom:P}:null,z=L?{width:N,height:j}:null,F=L?{"--active-tab-left":`${k}px`,"--active-tab-right":`${M}px`,"--active-tab-top":`${A}px`,"--active-tab-bottom":`${P}px`,"--active-tab-width":`${N}px`,"--active-tab-height":`${j}px`}:void 0,H=L&&N>0&&j>0,V=(0,l.useRenderElement)("span",e,{state:{orientation:E,activeTabPosition:D,activeTabSize:z,tabActivationDirection:R},ref:u,props:[{role:"presentation",style:F,hidden:!H},S,{suppressHydrationWarning:!0}],stateAttributesMapping:g});return null==w?null:(0,m.jsxs)(n.Fragment,{children:[V,x&&(t||(t=(0,m.jsx)(a.PrehydrationScript,{script:s.script})))]})});function v(e){let t=0,n=0,r=e;for(;null!=r;){t+=r.offsetLeft,n+=r.offsetTop;let e=r.offsetParent;null!=e&&(t+=e.clientLeft,n+=e.clientTop),r=e}return{left:t,top:n}}function b(e,t){if(!e)return 0;let n=parseFloat(e);return Number.isFinite(n)?e.endsWith("%")?n/100*t:n:0}e.s(["TabsIndicator",0,h],49637)},49487,e=>{"use strict";var t=e.i(71645),n=e.i(44394),r=e.i(46376),i=e.i(88015),o=e.i(74354),s=e.i(37584),a=e.i(23910),l=e.i(52245),u=e.i(73553),c=e.i(81524),d=e.i(1634),f=e.i(80862),f=f;f.startingStyle,f.endingStyle;let p={...c.tabsStateAttributesMapping,...o.transitionStatusMapping},m=t.forwardRef(function(e,o){let{className:c,value:f,render:m,keepMounted:g=!1,style:h,...v}=e,{value:b,getTabIdByPanelValue:x,orientation:y,tabActivationDirection:S,registerMountedTabPanel:C}=(0,d.useTabsRootContext)(),E=(0,i.useBaseUiId)(),{ref:R,index:w}=(0,u.useCompositeListItem)(),I=f===b,{mounted:T,transitionStatus:O,setMounted:k}=(0,a.useTransitionStatus)(I),M=!T,A=x(f),P=t.useRef(null),N=(0,l.useRenderElement)("div",e,{state:{hidden:M,orientation:y,tabActivationDirection:S,transitionStatus:O},ref:[o,R,P],props:[{"aria-labelledby":A,hidden:M,id:E,role:"tabpanel",tabIndex:I?0:-1,inert:(0,n.inertValue)(!I),"data-index":w},v],stateAttributesMapping:p});return((0,s.useOpenChangeComplete)({open:I,ref:P,onComplete(){I||k(!1)}}),(0,r.useIsoLayoutEffect)(()=>{if(null!=E&&(!M||g))return C(f,E)},[M,g,f,E,C]),g||T)?N:null});e.s(["TabsPanel",0,m],49487)},41840,1634,81524,70359,e=>{"use strict";var t=e.i(71645),n=e.i(51437),r=e.i(46376),i=e.i(67865),o=e.i(52245),s=e.i(53687),a=e.i(33332);let l=t.createContext(void 0);e.s(["TabsRootContext",0,l,"useTabsRootContext",0,function(){let e=t.useContext(l);if(void 0===e)throw Error((0,a.default)(64));return e}],1634);let u={tabActivationDirection:e=>({"data-activation-direction":e})};e.s(["tabsStateAttributesMapping",0,u],81524);var c=e.i(75606),d=e.i(56434),f=e.i(43476);let p=t.forwardRef(function(e,a){let{className:p,defaultValue:h=0,onValueChange:v,orientation:b="horizontal",render:x,value:y,style:S,...C}=e,E=void 0!==e.defaultValue,R=t.useRef([]),[w,I]=t.useState(()=>new Map),[T,O]=(0,n.useControlled)({controlled:y,default:h,name:"Tabs",state:"value"}),k=void 0!==y,[M,A]=t.useState(()=>new Map),P=t.useRef(void 0),N=t.useCallback(e=>m(M,e),[M]),[j,L]=t.useState(()=>({previousValue:T,tabActivationDirection:"none"})),{previousValue:D,tabActivationDirection:z}=j,F=z,H=!1;D!==T&&(F=g(D,T,b,M),H=null!=D&&null!=T&&null==N(T));let V=H?D:T,_=D!==V||z!==F;(0,r.useIsoLayoutEffect)(()=>{_&&L({previousValue:V,tabActivationDirection:F})},[V,_,F]);let B=(0,i.useStableCallback)((e,t)=>{t.activationDirection=g(T,e,b,M),v?.(e,t),t.isCanceled||O(e)}),q=(0,i.useStableCallback)((e,t)=>{v?.(e,(0,c.createChangeEventDetails)(t,void 0,void 0,{activationDirection:"none"}))}),W=(0,i.useStableCallback)((e,t)=>(I(n=>{let r=new Map(n);return r.set(e,t),r}),()=>{I(n=>{if(n.get(e)!==t)return n;let r=new Map(n);return r.delete(e),r})})),$=t.useCallback(e=>w.get(e),[w]),U=t.useCallback(e=>{for(let t of M.values())if(e===t.value)return t.id},[M]),K=t.useMemo(()=>({getTabElementBySelectedValue:N,getTabIdByPanelValue:U,getTabPanelIdByValue:$,onValueChange:B,orientation:b,registerMountedTabPanel:W,setTabMap:A,tabActivationDirection:F,value:T}),[N,U,$,B,b,W,A,F,T]),G=t.useMemo(()=>{for(let e of M.values())if(e.value===T)return e},[M,T]),Y=t.useMemo(()=>{for(let e of M.values())if(!e.disabled)return e.value},[M]),Q=t.useRef(!E),X=t.useRef(h),J=t.useRef(E),Z=t.useRef(!1);(0,r.useIsoLayoutEffect)(()=>{if(k)return;function e(e,t){O(e),L({previousValue:e,tabActivationDirection:"none"}),q(e,t),Q.current=!1}if(0===M.size){Z.current&&null!==T&&!P.current?.isConnected&&e(null,d.REASONS.missing);return}Z.current=!0,P.current=M.keys().next().value;let t=G?.disabled,n=null==G&&null!==T;if(t||T!==X.current||(J.current=!1),J.current&&t&&T===X.current)return;let r=Q.current;if(t||n){let n=Y??null;if(T===n){Q.current=!1;return}let i=d.REASONS.missing;r?i=d.REASONS.initial:t&&(i=d.REASONS.disabled),e(n,i);return}r&&null!=G&&(q(T,d.REASONS.initial),Q.current=!1)},[Y,k,q,G,O,M,T]);let ee={orientation:b,tabActivationDirection:F},et=(0,o.useRenderElement)("div",e,{state:ee,ref:a,props:C,stateAttributesMapping:u});return(0,f.jsx)(l.Provider,{value:K,children:(0,f.jsx)(s.CompositeList,{elementsRef:R,children:et})})});function m(e,t){for(let[n,r]of e.entries())if(t===r.value)return n;return null}function g(e,t,n,r){if(null==e||null==t)return"none";let[i,o,s]="horizontal"===n?["left","left","right"]:["top","up","down"],a=m(r,e),l=m(r,t);if(null==a||null==l)return a!==l&&("number"==typeof e||"string"==typeof e)&&typeof e==typeof t?t>e?s:o:"none";let u=a.getBoundingClientRect()[i],c=l.getBoundingClientRect()[i];return c<u?o:c>u?s:"none"}e.s(["TabsRoot",0,p],41840),e.s(["ACTIVE_COMPOSITE_ITEM",0,"data-composite-item-active"],70359)},88368,95530,7120,46802,18593,1249,e=>{"use strict";var t=e.i(71645),n=e.i(8868),r=e.i(46376),i=e.i(67865),o=e.i(88015),s=e.i(52245),a=e.i(40886),l=e.i(70359),u=e.i(28918),c=e.i(38452),d=e.i(73553);function f(e={}){let{highlightItemOnHover:n,highlightedIndex:r,onHighlightedIndexChange:i}=(0,c.useCompositeRootContext)(),{ref:o,index:s}=(0,d.useCompositeListItem)(e),a=r===s,l=t.useRef(null),p=(0,u.useMergedRefs)(o,l);return{compositeProps:{tabIndex:a?0:-1,onFocus(){i(s)},onMouseMove(){let e=l.current;if(!n||!e)return;let t=e.hasAttribute("disabled")||"true"===e.ariaDisabled;a||t||e.focus()}},compositeRef:p,index:s}}e.s(["useCompositeItem",0,f],95530);var p=e.i(1634),m=e.i(81524),g=e.i(33332);let h=t.createContext(void 0);function v(){let e=t.useContext(h);if(void 0===e)throw Error((0,g.default)(65));return e}e.s(["TabsListContext",0,h,"useTabsListContext",0,v],7120);var b=e.i(75606),x=e.i(56434),y=e.i(84446);let S=t.forwardRef(function(e,u){let{className:d,disabled:g=!1,render:h,value:S,id:C,nativeButton:E=!0,style:R,...w}=e,{value:I,getTabPanelIdByValue:T,onValueChange:O,orientation:k,tabActivationDirection:M}=(0,p.useTabsRootContext)(),{activateOnFocus:A,registerTabResizeObserverElement:P,tabsListElement:N}=v(),{highlightedIndex:j,onHighlightedIndexChange:L}=(0,c.useCompositeRootContext)(),D=(0,o.useBaseUiId)(C),{compositeProps:z,compositeRef:F,index:H}=f({metadata:t.useMemo(()=>({disabled:g,id:D,value:S}),[g,D,S])}),V=S===I,_=t.useRef(!1),B=t.useRef(null),q=(0,i.useStableCallback)(e=>{B.current?.(),B.current=e?P(e):null});(0,r.useIsoLayoutEffect)(()=>{if(_.current){_.current=!1;return}if(V&&H>-1&&j!==H){if(null!=N){let e=(0,y.activeElement)((0,n.ownerDocument)(N));if(e&&(0,y.contains)(N,e))return}g||L(H)}},[V,H,j,L,g,N]);let{getButtonProps:W,buttonRef:$}=(0,a.useButton)({disabled:g,native:E,focusableWhenDisabled:!0}),U=T(S),K=t.useRef(!1),G=t.useRef(!1);function Y(e){O(S,(0,b.createChangeEventDetails)(x.REASONS.none,e.nativeEvent,void 0,{activationDirection:"none"}))}return(0,s.useRenderElement)("button",e,{state:{disabled:g,active:V,orientation:k,tabActivationDirection:M},ref:[u,$,F,q],props:[z,{role:"tab","aria-controls":U,"aria-selected":V,id:D,onClick:function(e){V||g||Y(e)},onFocus:function(e){V||g||A&&(!K.current||G.current)&&Y(e)},onPointerDown:function(e){if(V||g)return;K.current=!0,G.current=0===e.button;let t=(0,n.ownerDocument)(e.currentTarget);function r(){K.current=!1,G.current=!1,t.removeEventListener("pointerup",r),t.removeEventListener("pointercancel",r)}t.addEventListener("pointerup",r),t.addEventListener("pointercancel",r)},[l.ACTIVE_COMPOSITE_ITEM]:V?"":void 0,onKeyDownCapture(){_.current=!0}},w,W],stateAttributesMapping:m.tabsStateAttributesMapping})});e.s(["TabsTab",0,S],88368),e.s(["useForcedRerendering",0,function(){let[,e]=t.useState({});return t.useCallback(()=>{e({})},[])}],46802),e.s(["script",0,""],18593);var C=e.i(2239),E=e.i(56789);function R(){return E.NOOP}function w(){return!1}function I(){return!0}e.s(["useIsHydrating",0,function(){return(0,C.useSyncExternalStore)(R,w,I)}],1249)},96533,e=>{"use strict";e.i(47167);var t=e.i(33332),n=e.i(71645);let r=n.createContext(void 0);e.s(["useToolbarRootContext",0,function(e){let i=n.useContext(r);if(void 0===i&&!e)throw Error((0,t.default)(69));return i}])},38380,e=>{"use strict";var t=e.i(80862);let n=t.startingStyle,r=t.endingStyle;e.s(["align",0,"data-align","anchorHidden",0,"data-anchor-hidden","closed",0,"data-closed","endingStyle",0,r,"open",0,"data-open","side",0,"data-side","startingStyle",0,n])},15618,e=>{"use strict";e.s(["popupOpen",0,"data-popup-open","pressed",0,"data-pressed"])},52535,e=>{"use strict";e.i(47167);var t=e.i(71645),n=e.i(46376),r=e.i(28744),i=e.i(2077),o=e.i(43476);let s=t.forwardRef(function(e,s){let[a,l]=t.useState();return(0,n.useIsoLayoutEffect)(()=>{r.platform.screenReader.voiceOver&&r.platform.engine.webkit&&l("button")},[]),(0,o.jsx)("span",{...e,ref:s,style:i.visuallyHidden,"aria-hidden":!a||void 0,...{tabIndex:0,role:a},"data-base-ui-focus-guard":""})});e.s(["FocusGuard",0,s])},426,e=>{"use strict";e.i(47167);var t=e.i(71645),n=e.i(43476);let r=t.forwardRef(function(e,t){let r,{cutout:i,...o}=e;if(i){let e=i.getBoundingClientRect();r=`polygon(0% 0%,100% 0%,100% 100%,0% 100%,0% 0%,${e.left}px ${e.top}px,${e.left}px ${e.bottom}px,${e.right}px ${e.bottom}px,${e.right}px ${e.top}px,${e.left}px ${e.top}px)`}return(0,n.jsx)("div",{ref:t,role:"presentation","data-base-ui-inert":"",...o,style:{position:"fixed",inset:0,userSelect:"none",WebkitUserSelect:"none",clipPath:r}})});e.s(["InternalBackdrop",0,r])},64042,e=>{"use strict";var t=e.i(33848),n=e.i(28744);e.s(["isMouseWithinBounds",0,function(e,r){let i=function(e){let r=e.getBoundingClientRect(),i=(0,t.ownerWindow)(e);if(n.platform.env.jsdom)return r;let o=i.getComputedStyle(e,"::before"),s=i.getComputedStyle(e,"::after");if("none"===o.content&&"none"===s.content)return r;let a=parseFloat(o.width)||0,l=parseFloat(o.height)||0,u=parseFloat(s.width)||0,c=parseFloat(s.height)||0,d=Math.max(r.width,a,u),f=Math.max(r.height,l,c),p=d-r.width,m=f-r.height;return{left:r.left-p/2,right:r.right+p/2,top:r.top-m/2,bottom:r.bottom+m/2}}(r);return e.clientX>=i.left-5&&e.clientX<=i.right+5&&e.clientY>=i.top-5&&e.clientY<=i.bottom+5}])},18438,e=>{"use strict";e.i(47167);var t=e.i(71645),n=e.i(52245);let r=t.forwardRef(function(e,t){let{className:r,render:i,orientation:o="horizontal",style:s,...a}=e;return(0,n.useRenderElement)("div",e,{state:{orientation:o},ref:t,props:[{role:"presentation"},a]})});e.s(["ListboxSeparator",0,r])},79938,e=>{"use strict";var t=e.i(74354),n=e.i(38380),r=e.i(15618);let i={[r.popupOpen]:""},o={[r.popupOpen]:"",[r.pressed]:""},s={[n.open]:""},a={[n.closed]:""},l={[n.anchorHidden]:""},u={open:e=>e?s:a,anchorHidden:e=>e?l:null},c={...u,...t.transitionStatusMapping};e.s(["popupStateMapping",0,u,"popupTransitionStateMapping",0,c,"pressableTriggerOpenStateMapping",0,{open:e=>e?o:null},"triggerOpenStateMapping",0,{open:e=>e?i:null}])},64111,50527,e=>{"use strict";var t=e.i(71645),n=e.i(74080),r=e.i(56789),i=e.i(83977),o=e.i(67865),s=e.i(46376),a=e.i(88940),l=e.i(49055),u=e.i(46420),c=e.i(29315),d=e.i(56341);function f(e){let{popupStore:n,treatPopupAsFloatingElement:r=!1,floatingRootContext:i,floatingId:o,nested:a,onOpenChange:l}=e,u=n.useState("open"),f=n.useState("activeTriggerElement"),p=n.useState(r?"popupElement":"positionerElement"),m=n.context.triggerElements,g=t.useRef(null);void 0===i&&null===g.current&&(g.current=new d.FloatingRootStore({open:u,transitionStatus:void 0,referenceElement:f,floatingElement:p,triggerElements:m,onOpenChange:l,floatingId:o,syncOnly:!0,nested:a}));let h=i??g.current;return n.useSyncedValue("floatingId",o),(0,s.useIsoLayoutEffect)(()=>{let e={open:u,floatingId:o,referenceElement:f,floatingElement:p};(0,c.isElement)(f)&&(e.domReferenceElement=f),h.state.positionReference===h.state.referenceElement&&(e.positionReference=f),h.update(e)},[u,o,f,p,h]),h.context.onOpenChange=l,h.context.nested=a,h}e.s(["useSyncedFloatingRootContext",0,f],50527);var p=e.i(23910),m=e.i(37584),g=e.i(75606),h=e.i(56434);let v={tabIndex:-1,[l.FOCUSABLE_ATTRIBUTE]:""};function b(e){let t=e.context.triggerElements.size;e.select("open")&&e.state.triggerCount!==t&&e.set("triggerCount",t)}function x(e,n){let r=t.useRef(null);return(0,o.useStableCallback)(t=>{let i=r.current;if(null!==i){if(i.element===t&&i.store===n&&i.id===e)return;r.current=null;let o=i.store;o.context.triggerElements.getById(i.id)===i.element&&(o.context.triggerElements.delete(i.id),b(o))}null!==t&&void 0!==e&&(r.current={store:n,id:e,element:t},n.context.triggerElements.add(e,t),b(n))})}function y(e,t,n,r=!1){let i=e.preventUnmountingOnClose;t?i=!1:r&&(i=!0);let o=n?.id??null,s=e.activeTriggerId,a=e.activeTriggerElement;return(o||t)&&(s=o,a=n??null),{open:t,preventUnmountingOnClose:i,activeTriggerId:s,activeTriggerElement:a}}function S(e){let t=!1;return e.preventUnmountOnClose=()=>{t=!0},()=>t}e.s(["FOCUSABLE_POPUP_PROPS",0,v,"PopupHandleAttachment",0,function({handle:e,store:t}){return(0,s.useIsoLayoutEffect)(()=>e.attachStore(t),[e,t]),null},"applyPopupOpenChange",0,function(e,t,r,i={}){let o=r.reason,s=o===h.REASONS.triggerHover,a=t&&o===h.REASONS.triggerFocus,l=!t&&(o===h.REASONS.triggerPress||o===h.REASONS.escapeKey),u=S(r);if(e.context.onOpenChange?.(t,r),r.isCanceled)return;i.onBeforeDispatch?.(),e.state.floatingRootContext.dispatchOpenChange(t,r);let c=()=>{let n=y(e.state,t,r.trigger,u()),o={...i.extraState,...n};a?o.instantType="focus":l?o.instantType="dismiss":s&&(o.instantType=void 0),e.update(o)};s?n.flushSync(c):c()},"attachPreventUnmountOnClose",0,S,"createDefaultInitialFocus",0,function(e){return t=>"touch"!==t||e.current},"createPopupOpenState",0,y,"useImplicitActiveTrigger",0,function(e,n={}){let{closeOnActiveTriggerUnmount:r=!1}=n,i=t.useRef(null),o=e.useState("open"),a=e.useState("triggerCount"),l=e.useState("activeTriggerId"),u=e.useState("activeTriggerElement");(0,s.useIsoLayoutEffect)(()=>{if(!o){i.current=null,0!==e.state.triggerCount&&e.set("triggerCount",0);return}let t=e.context.triggerElements.size,n={};e.state.triggerCount!==t&&(n.triggerCount=t);let s=e.select("activeTriggerId"),a=null;if(s){let t=e.context.triggerElements.getById(s);if(t)i.current=s,t!==e.state.activeTriggerElement&&(n.activeTriggerElement=t);else{for(let[t,r]of e.context.triggerElements.entries())if(r===e.state.activeTriggerElement){n.activeTriggerId=t,n.activeTriggerElement=r,i.current=t;break}void 0===n.activeTriggerId&&(i.current===s?a=s:i.current=null)}}else i.current=null;if(!a&&!s&&1===t){let t=e.context.triggerElements.entries().next();if(!t.done){let[e,r]=t.value;n.activeTriggerId=e,n.activeTriggerElement=r,i.current=e}}(void 0!==n.triggerCount||void 0!==n.activeTriggerId||void 0!==n.activeTriggerElement)&&e.update(n),a&&r&&queueMicrotask(()=>{if(e.select("open")&&e.select("activeTriggerId")===a&&!e.context.triggerElements.getById(a)){let t=(0,g.createChangeEventDetails)(h.REASONS.none);e.setOpen(!1,t),t.isCanceled||e.update({activeTriggerId:null,activeTriggerElement:null})}})},[o,e,a,l,u,r])},"useOpenStateTransitions",0,function(e,t,n,r){let{mounted:i,setMounted:s,transitionStatus:a}=(0,p.useTransitionStatus)(e,!1,!1,r),l=t.useState("preventUnmountingOnClose"),u=!e&&l;t.useSyncedValues({mounted:i,transitionStatus:a,preventUnmountingOnClose:u});let c=(0,o.useStableCallback)(()=>{s(!1),t.update({activeTriggerId:null,activeTriggerElement:null,mounted:!1,preventUnmountingOnClose:!1}),n?.(),t.context.onOpenChangeComplete?.(!1)});return(0,m.useOpenChangeComplete)({enabled:i&&!e&&!u,open:e,ref:t.context.popupRef,onComplete(){e||c()}}),{forceUnmount:c,transitionStatus:a}},"usePopupInteractionProps",0,function(e,t){e.useSyncedValues(t),(0,s.useIsoLayoutEffect)(()=>()=>{e.update({activeTriggerProps:r.EMPTY_OBJECT,inactiveTriggerProps:r.EMPTY_OBJECT,popupProps:r.EMPTY_OBJECT})},[e])},"usePopupRootStore",0,function(e,t=!1){let n=(0,i.useId)(),r=null!=(0,u.useFloatingParentNodeId)(),o=(0,a.useRefWithInit)(()=>e(n,r)).current;return f({popupStore:o,treatPopupAsFloatingElement:t,floatingRootContext:o.state.floatingRootContext,floatingId:n,nested:r,onOpenChange:o.setOpen}),o},"usePopupRootSync",0,function(e,t){(0,s.useIsoLayoutEffect)(()=>{t||null===e.state.openMethod||e.set("openMethod",null)},[t,e]),(0,s.useIsoLayoutEffect)(()=>()=>{null!==e.state.openMethod&&e.set("openMethod",null)},[e])},"useTriggerDataForwarding",0,function(e,t,n,r){let i=n.useState("isMountedByTrigger",e),a=x(e,n),l=(0,o.useStableCallback)(t=>{let i=n.select("open"),o=n.select("activeTriggerId");if(o===e){let e={activeTriggerElement:t,...i?r:null};n.update(e);return}if(null==o&&i){let i={activeTriggerId:e??null,activeTriggerElement:t,...r};n.update(i)}}),u=(0,o.useStableCallback)(e=>{a(e),e&&l(e)});return(0,s.useIsoLayoutEffect)(()=>(u(t.current),()=>u(null)),[u,t,n,e]),(0,s.useIsoLayoutEffect)(()=>{if(i){let e={activeTriggerElement:t.current,...r};n.update(e)}},[i,n,t,...Object.values(r)]),{registerTrigger:u,isMountedByThisTrigger:i}},"useTriggerRegistration",0,x],64111)},90627,e=>{"use strict";e.i(47167),e.s(["PopupTriggerMap",0,class{constructor(){this.idMap=new Map}add(e,t){this.idMap.set(e,t)}delete(e){this.idMap.delete(e)}hasElement(e){for(let t of this.idMap.values())if(t===e)return!0;return!1}hasMatchingElement(e){for(let t of this.idMap.values())if(e(t))return!0;return!1}getById(e){return this.idMap.get(e)}entries(){return this.idMap.entries()}elements(){return this.idMap.values()}get size(){return this.idMap.size}}])},50001,e=>{"use strict";e.s(["getDefaultLabelId",0,function(e){return null==e?void 0:`${e}-label`},"resolveAriaLabelledBy",0,function(e,t){return e??t}])},33383,e=>{"use strict";var t=e.i(71645),n=e.i(8868),r=e.i(45484),i=e.i(46376);e.s(["useAnchoredPopupScrollLock",0,function(e,o,s,a){let[l,u]=t.useState(!1);(0,i.useIsoLayoutEffect)(()=>{if(!e||!o||null==s)return void u(!1);let t=(0,n.ownerDocument)(s).documentElement.clientWidth,r=s.offsetWidth;u(t>0&&r>0&&r>=t-20)},[e,o,s]),(0,r.useScrollLock)(e&&(!o||l),a)}])},32199,e=>{"use strict";var t=e.i(71645),n=e.i(67865),r=e.i(28744),i=e.i(6039);function o(e,i){var o;let s,a,{onClick:l,onPointerDown:u}=(o=(0,n.useStableCallback)((t,n)=>{("function"==typeof e?e():e)||i(n||(r.platform.os.ios?"touch":""))}),s=t.useRef(""),a=t.useCallback(e=>{e.defaultPrevented||(s.current=e.pointerType,o(e,e.pointerType))},[o]),{onClick:t.useCallback(e=>{0===e.detail?o(e,"keyboard"):("pointerType"in e?o(e,e.pointerType):o(e,s.current),s.current="")},[o]),onPointerDown:a});return t.useMemo(()=>({onClick:l,onPointerDown:u}),[l,u])}e.s(["useOpenInteractionType",0,function(e){let[n,r]=t.useState(null),s=o(e,r);return(0,i.useValueChanged)(e,t=>{t&&!e&&r(null)}),t.useMemo(()=>({openMethod:n,triggerProps:s}),[n,s])},"useOpenMethodTriggerProps",0,o],32199)},89579,53984,e=>{"use strict";var t=e.i(79938),n=e.i(52245),r=e.i(56789),i=e.i(38396);function o(e){return"starting"===e?i.DISABLED_TRANSITIONS_STYLE:r.EMPTY_OBJECT}e.s(["getDisabledMountTransitionStyles",0,o],53984),e.s(["usePositioner",0,function(e,r,{styles:i,transitionStatus:s,props:a,refs:l,hidden:u,inert:c=!1}){let d={...i};return c&&(d.pointerEvents="none"),(0,n.useRenderElement)("div",e,{state:r,ref:l,props:[{role:"presentation",hidden:u,style:d},o(s),a],stateAttributesMapping:t.popupStateMapping})}],89579)},74735,65420,e=>{"use strict";e.s(["addEventListener",0,function(e,t,n,r){return e.addEventListener(t,n,r),()=>{e.removeEventListener(t,n,r)}}],74735),e.s(["mergeCleanups",0,function(...e){return()=>{for(let t=0;t<e.length;t+=1){let n=e[t];n&&n()}}}],65420)},44394,e=>{"use strict";var t=e.i(58321);e.s(["inertValue",0,function(e){return(0,t.isReactVersionAtLeast)(19)?e:e?"true":void 0}])},90803,e=>{"use strict";e.s(["isElementDisabled",0,function(e){return null==e||e.hasAttribute("disabled")||"true"===e.getAttribute("aria-disabled")}])},28744,e=>{"use strict";e.s([],64949),e.i(64949);let{userAgent:t,platform:n,maxTouchPoints:r}="u"<typeof navigator?{userAgent:"",platform:"",maxTouchPoints:0}:{userAgent:navigator.userAgent,platform:navigator.platform??"",maxTouchPoints:navigator.maxTouchPoints??0},i=t.toLowerCase(),o=n.toLowerCase(),s=/^i(os$|p)/.test(o)||"macintel"===o&&r>1,a="android",l=o===a||i.includes(a),u=!s&&o.startsWith("mac"),c=o.startsWith("win"),d=!l&&/^(linux|chrome os)/.test(o),f=u||s;e.s(["android",0,l,"apple",0,f,"ios",0,s,"linux",0,d,"mac",0,u,"windows",0,c],3720);var p=e.i(3720);let m="u">typeof CSS&&!!CSS.supports?.("-webkit-backdrop-filter:none"),g=!m&&i.includes("firefox"),h=!m&&i.includes("chrom");e.s(["blink",0,h,"gecko",0,g,"webkit",0,m],79850);var v=e.i(79850);e.s(["voiceOver",0,f],99170);var b=e.i(99170);let x=/jsdom|happydom/.test(i);e.s(["jsdom",0,x],36174);var y=e.i(36174);e.s(["iOS",0,"@supports (-webkit-touch-callout: none)"],71351);var S=e.i(71351);e.s(["engine",0,v,"env",0,y,"mediaQuery",0,S,"os",0,p,"screenReader",0,b],79214);var C=e.i(79214);e.s(["platform",0,C],28744)},26352,96499,e=>{"use strict";let t;var n=e.i(71645),r=e.i(2239),i=e.i(30224),o=e.i(58321),s=e.i(88940);let a=[];function l(){return t}function u(e){a.push(e)}function c(e){let n=(n,r)=>{let i,o=(0,s.useRefWithInit)(d).current;try{for(let e of(t=o,a))e.before(o);for(let t of(i=e(n,r),a))t.after(o);o.didInitialize=!0}finally{t=void 0}return i};return n.displayName=e.displayName||e.name,n}function d(){return{didInitialize:!1}}e.s(["fastComponent",0,c,"fastComponentRef",0,function(e){return n.forwardRef(c(e))},"getInstance",0,l,"register",0,u],96499);let f=(0,o.isReactVersionAtLeast)(19)?function(e,t,i,o,s){let a,u=l();if(!u){let a;return a=n.useCallback(()=>t(e.getSnapshot(),i,o,s),[e,t,i,o,s]),(0,r.useSyncExternalStore)(e.subscribe,a,a)}let c=u.syncIndex;return u.syncIndex+=1,u.didInitialize?(a=u.syncHooks[c]).store===e&&a.selector===t&&Object.is(a.a1,i)&&Object.is(a.a2,o)&&Object.is(a.a3,s)||(a.store!==e&&(u.didChangeStore=!0),a.store=e,a.selector=t,a.a1=i,a.a2=o,a.a3=s,a.value=t(e.getSnapshot(),i,o,s)):(a={store:e,selector:t,a1:i,a2:o,a3:s,value:t(e.getSnapshot(),i,o,s)},u.syncHooks.push(a)),a.value}:function(e,t,n,r,o){return(0,i.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,e=>t(e,n,r,o))};u({before(e){e.syncIndex=0,e.didInitialize||(e.syncTick=1,e.syncHooks=[],e.didChangeStore=!0,e.getSnapshot=()=>{let t=!1;for(let n=0;n<e.syncHooks.length;n+=1){let r=e.syncHooks[n],i=r.selector(r.store.state,r.a1,r.a2,r.a3);Object.is(r.value,i)||(t=!0,r.value=i)}return t&&(e.syncTick+=1),e.syncTick})},after(e){e.syncHooks.length>0&&(e.didChangeStore&&(e.didChangeStore=!1,e.subscribe=t=>{let n=new Set;for(let t of e.syncHooks)n.add(t.store);let r=[];for(let e of n)r.push(e.subscribe(t));return()=>{for(let e of r)e()}}),(0,r.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getSnapshot))}});class p{static create(e){return new this(e)}constructor(e){this.state=e,this.listeners=new Set,this.updateTick=0}subscribe=e=>(this.listeners.add(e),()=>{this.listeners.delete(e)});getSnapshot=()=>this.state;setState(e){if(this.state===e)return;this.state=e,this.updateTick+=1;let t=this.updateTick;for(let n of this.listeners){if(t!==this.updateTick)return;n(e)}}update(e){for(let t in e)if(!Object.is(this.state[t],e[t]))return void this.setState({...this.state,...e})}set(e,t){Object.is(this.state[e],t)||this.setState({...this.state,[e]:t})}notifyAll(){let e={...this.state};this.setState(e)}use(e,t,n,r){return f(this,e,t,n,r)}}var m=e.i(67865),g=e.i(46376),h=e.i(56789);e.s(["ReactStore",0,class extends p{constructor(e,t={},n){super(e),this.context=t,this.selectors=n}useSyncedValue(e,t){n.useDebugValue(e);let r=this;(0,g.useIsoLayoutEffect)(()=>{r.state[e]!==t&&r.set(e,t)},[r,e,t])}useSyncedValueWithCleanup(e,t){let n=this;(0,g.useIsoLayoutEffect)(()=>(n.state[e]!==t&&n.set(e,t),()=>{n.set(e,void 0)}),[n,e,t])}useSyncedValues(e){let t=this,n=Object.values(e);(0,g.useIsoLayoutEffect)(()=>{t.update(e)},[t,...n])}useControlledProp(e,t){n.useDebugValue(e);let r=this,i=void 0!==t;(0,g.useIsoLayoutEffect)(()=>{i&&!Object.is(r.state[e],t)&&r.setState({...r.state,[e]:t})},[r,e,t,i])}select(e,t,n,r){return(0,this.selectors[e])(this.state,t,n,r)}useState(e,t,r,i){return n.useDebugValue(e),f(this,this.selectors[e],t,r,i)}useContextCallback(e,t){n.useDebugValue(e);let r=(0,m.useStableCallback)(t??h.NOOP);this.context[e]=r}useStateSetter(e){let t=n.useRef(void 0);return void 0===t.current&&(t.current=t=>{this.set(e,t)}),t.current}observe(e,t){let n,r=(n="function"==typeof e?e:this.selectors[e])(this.state);return t(r,r,this),this.subscribe(e=>{let i=n(e);if(!Object.is(r,i)){let e=r;r=i,t(i,e,this)}})}}],26352)},13203,e=>{"use strict";var t=e.i(71645);e.s(["useOnFirstRender",0,function(e){let n=t.useRef(!0);n.current&&(n.current=!1,e())}])},94258,e=>{"use strict";var t=e.i(71645);e.s(["usePreviousValue",0,function(e){let[n,r]=t.useState({current:e,previous:null});return Object.is(e,n.current)||r({current:e,previous:n.current}),n.previous}])},45484,e=>{"use strict";var t=e.i(29315),n=e.i(74735),r=e.i(28744),i=e.i(8868),o=e.i(33848),s=e.i(46376),a=e.i(39957),l=e.i(8445);let u={},c={},d="";function f(e,n){return(0,t.isOverflowElement)(e)?e:n}function p(e,t,n){return/hidden|clip/.test(e.getComputedStyle(f(t,n)).overflowY)}class m{lockCount=0;restore=null;timeoutLock=a.Timeout.create();timeoutUnlock=a.Timeout.create();acquire(e){return this.lockCount+=1,1===this.lockCount&&null===this.restore&&this.timeoutLock.start(0,()=>this.lock(e)),this.release}release=()=>{this.lockCount-=1,0===this.lockCount&&this.restore&&this.timeoutUnlock.start(0,this.unlock)};unlock=()=>{0===this.lockCount&&this.restore&&(this.restore?.(),this.restore=null)};lock(e){let t,s,a;if(0===this.lockCount||null!==this.restore)return;let m=(0,i.ownerDocument)(e),g=m.documentElement,h=m.body,v=(0,o.ownerWindow)(g);if(p(v,g,h)){let t=new v.MutationObserver(()=>{p(v,g,h)||(t.disconnect(),this.restore=null,this.lock(e))}),n={attributes:!0};t.observe(g,n),t.observe(h,n),this.restore=()=>t.disconnect();return}let b=r.platform.os.ios||!function(e){if("u"<typeof document)return!1;let t=(0,i.ownerDocument)(e);return(0,o.ownerWindow)(t).innerWidth-t.documentElement.clientWidth>0}(e);this.restore=b?(a={overflowY:(s=f((t=(0,i.ownerDocument)(e)).documentElement,t.body)).style.overflowY,overflowX:s.style.overflowX},Object.assign(s.style,{overflowY:"hidden",overflowX:"hidden"}),()=>{Object.assign(s.style,a)}):function(e){let t=(0,i.ownerDocument)(e),s=t.documentElement,a=t.body,p=(0,o.ownerWindow)(s),m=0,g=0,h=!1,v=l.AnimationFrame.create();if(r.platform.engine.webkit&&(p.visualViewport?.scale??1)!==1)return()=>{};function b(){let t=p.getComputedStyle(s),n=p.getComputedStyle(a),r=(t.scrollbarGutter||"").includes("both-edges")?"stable both-edges":"stable";m=s.scrollTop,g=s.scrollLeft,u={scrollbarGutter:s.style.scrollbarGutter,overflowY:s.style.overflowY,overflowX:s.style.overflowX},d=s.style.scrollBehavior,c={position:a.style.position,height:a.style.height,width:a.style.width,boxSizing:a.style.boxSizing,overflowY:a.style.overflowY,overflowX:a.style.overflowX,scrollBehavior:a.style.scrollBehavior};let o=s.scrollHeight>s.clientHeight,l=s.scrollWidth>s.clientWidth,v="scroll"===t.overflowY||"scroll"===n.overflowY,b="scroll"===t.overflowX||"scroll"===n.overflowX,x=Math.max(0,p.innerWidth-a.clientWidth),y=Math.max(0,p.innerHeight-a.clientHeight),S=parseFloat(n.marginTop)+parseFloat(n.marginBottom),C=parseFloat(n.marginLeft)+parseFloat(n.marginRight),E=f(s,a);if(h=function(e){if(!("u">typeof CSS&&CSS.supports&&CSS.supports("scrollbar-gutter","stable"))||"u"<typeof document)return!1;let t=(0,i.ownerDocument)(e),n=t.documentElement,r=f(n,t.body),o=r.style.overflowY,s=n.style.scrollbarGutter;n.style.scrollbarGutter="stable",r.style.overflowY="scroll";let a=r.offsetWidth;r.style.overflowY="hidden";let l=r.offsetWidth;return r.style.overflowY=o,n.style.scrollbarGutter=s,a===l}(e)){s.style.scrollbarGutter=r,E.style.overflowY="hidden",E.style.overflowX="hidden";return}Object.assign(s.style,{scrollbarGutter:r,overflowY:"hidden",overflowX:"hidden"}),(o||v)&&(s.style.overflowY="scroll"),(l||b)&&(s.style.overflowX="scroll"),Object.assign(a.style,{position:"relative",height:S||y?`calc(100dvh - ${S+y}px)`:"100dvh",width:C||x?`calc(100vw - ${C+x}px)`:"100vw",boxSizing:"border-box",overflowY:"hidden",overflowX:"hidden",scrollBehavior:"unset"}),a.scrollTop=m,a.scrollLeft=g,s.setAttribute("data-base-ui-scroll-locked",""),s.style.scrollBehavior="unset"}function x(){Object.assign(s.style,u),Object.assign(a.style,c),h||(s.scrollTop=m,s.scrollLeft=g,s.removeAttribute("data-base-ui-scroll-locked"),s.style.scrollBehavior=d)}b();let y=(0,n.addEventListener)(p,"resize",function(){x(),v.request(b)});return()=>{v.cancel(),x(),"function"==typeof p.removeEventListener&&y()}}(e)}}let g=new m;e.s(["useScrollLock",0,function(e=!0,t=null){(0,s.useIsoLayoutEffect)(()=>{if(e)return g.acquire(t)},[e,t])}])},46265,e=>{"use strict";var t=e.i(46376),n=e.i(88940);function r(e){let t={current:e,next:e,effect:()=>{t.current=t.next}};return t}e.s(["useValueAsRef",0,function(e){let i=(0,n.useRefWithInit)(r,e).current;return i.next=e,(0,t.useIsoLayoutEffect)(i.effect),i}])},2077,e=>{"use strict";let t={clipPath:"inset(50%)",overflow:"hidden",whiteSpace:"nowrap",border:0,padding:0,width:1,height:1,margin:-1},n={...t,position:"fixed",top:0,left:0},r={...t,position:"absolute"};e.s(["visuallyHidden",0,n,"visuallyHiddenInput",0,r])},53760,58950,88643,e=>{"use strict";var t=e.i(43084);function n(e,n,r){let i,{reference:o,floating:s}=e,a=(0,t.getSideAxis)(n),l=(0,t.getAlignmentAxis)(n),u=(0,t.getAxisLength)(l),c=(0,t.getSide)(n),d=o.x+o.width/2-s.width/2,f=o.y+o.height/2-s.height/2,p=o[u]/2-s[u]/2;switch(c){case"top":i={x:d,y:o.y-s.height};break;case"bottom":i={x:d,y:o.y+o.height};break;case"right":i={x:o.x+o.width,y:f};break;case"left":i={x:o.x-s.width,y:f};break;default:i={x:o.x,y:o.y}}let m=(0,t.getAlignment)(n);return m&&(i[l]+=p*("end"===m?1:-1)*(r&&"y"===a?-1:1)),i}async function r(e,n){var r;void 0===n&&(n={});let{x:i,y:o,platform:s,rects:a,elements:l,strategy:u}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:f="floating",altBoundary:p=!1,padding:m=0}=(0,t.evaluate)(n,e),g=(0,t.getPaddingObject)(m),h=l[p?"floating"===f?"reference":"floating":f],v=(0,t.rectToClientRect)(await s.getClippingRect({element:null==(r=await (null==s.isElement?void 0:s.isElement(h)))||r?h:h.contextElement||await (null==s.getDocumentElement?void 0:s.getDocumentElement(l.floating)),boundary:c,rootBoundary:d,strategy:u})),b="floating"===f?{x:i,y:o,width:a.floating.width,height:a.floating.height}:a.reference,x=await (null==s.getOffsetParent?void 0:s.getOffsetParent(l.floating)),y=await (null==s.isElement?void 0:s.isElement(x))&&await (null==s.getScale?void 0:s.getScale(x))||{x:1,y:1},S=(0,t.rectToClientRect)(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:b,offsetParent:x,strategy:u}):b);return{top:(v.top-S.top+g.top)/y.y,bottom:(S.bottom-v.bottom+g.bottom)/y.y,left:(v.left-S.left+g.left)/y.x,right:(S.right-v.right+g.right)/y.x}}let i=async(e,t,i)=>{let{placement:o="bottom",strategy:s="absolute",middleware:a=[],platform:l}=i,u=l.detectOverflow?l:{...l,detectOverflow:r},c=await (null==l.isRTL?void 0:l.isRTL(t)),d=await l.getElementRects({reference:e,floating:t,strategy:s}),{x:f,y:p}=n(d,o,c),m=o,g=0,h={};for(let r=0;r<a.length;r++){let i=a[r];if(!i)continue;let{name:v,fn:b}=i,{x:x,y:y,data:S,reset:C}=await b({x:f,y:p,initialPlacement:o,placement:m,strategy:s,middlewareData:h,rects:d,platform:u,elements:{reference:e,floating:t}});f=null!=x?x:f,p=null!=y?y:p,h[v]={...h[v],...S},C&&g<50&&(g++,"object"==typeof C&&(C.placement&&(m=C.placement),C.rects&&(d=!0===C.rects?await l.getElementRects({reference:e,floating:t,strategy:s}):C.rects),{x:f,y:p}=n(d,m,c)),r=-1)}return{x:f,y:p,placement:m,strategy:s,middlewareData:h}};function o(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function s(e){return t.sides.some(t=>e[t]>=0)}function a(e){let n=(0,t.min)(...e.map(e=>e.left)),r=(0,t.min)(...e.map(e=>e.top));return{x:n,y:r,width:(0,t.max)(...e.map(e=>e.right))-n,height:(0,t.max)(...e.map(e=>e.bottom))-r}}let l=new Set(["left","top"]);async function u(e,n){let{placement:r,platform:i,elements:o}=e,s=await (null==i.isRTL?void 0:i.isRTL(o.floating)),a=(0,t.getSide)(r),u=(0,t.getAlignment)(r),c="y"===(0,t.getSideAxis)(r),d=l.has(a)?-1:1,f=s&&c?-1:1,p=(0,t.evaluate)(n,e),{mainAxis:m,crossAxis:g,alignmentAxis:h}="number"==typeof p?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return u&&"number"==typeof h&&(g="end"===u?-1*h:h),c?{x:g*f,y:m*d}:{x:m*d,y:g*f}}var c=e.i(29315);function d(e){let n=(0,c.getComputedStyle)(e),r=parseFloat(n.width)||0,i=parseFloat(n.height)||0,o=(0,c.isHTMLElement)(e),s=o?e.offsetWidth:r,a=o?e.offsetHeight:i,l=(0,t.round)(r)!==s||(0,t.round)(i)!==a;return l&&(r=s,i=a),{width:r,height:i,$:l}}function f(e){return(0,c.isElement)(e)?e:e.contextElement}function p(e){let n=f(e);if(!(0,c.isHTMLElement)(n))return(0,t.createCoords)(1);let r=n.getBoundingClientRect(),{width:i,height:o,$:s}=d(n),a=(s?(0,t.round)(r.width):r.width)/i,l=(s?(0,t.round)(r.height):r.height)/o;return a&&Number.isFinite(a)||(a=1),l&&Number.isFinite(l)||(l=1),{x:a,y:l}}let m=(0,t.createCoords)(0);function g(e){let t=(0,c.getWindow)(e);return(0,c.isWebKit)()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:m}function h(e,n,r,i){var o;void 0===n&&(n=!1),void 0===r&&(r=!1);let s=e.getBoundingClientRect(),a=f(e),l=(0,t.createCoords)(1);n&&(i?(0,c.isElement)(i)&&(l=p(i)):l=p(e));let u=(void 0===(o=r)&&(o=!1),i&&o&&i===(0,c.getWindow)(a))?g(a):(0,t.createCoords)(0),d=(s.left+u.x)/l.x,m=(s.top+u.y)/l.y,h=s.width/l.x,v=s.height/l.y;if(a&&i){let e=(0,c.getWindow)(a),t=(0,c.isElement)(i)?(0,c.getWindow)(i):i,n=e,r=(0,c.getFrameElement)(n);for(;r&&t!==n;){let e=p(r),t=r.getBoundingClientRect(),i=(0,c.getComputedStyle)(r),o=t.left+(r.clientLeft+parseFloat(i.paddingLeft))*e.x,s=t.top+(r.clientTop+parseFloat(i.paddingTop))*e.y;d*=e.x,m*=e.y,h*=e.x,v*=e.y,d+=o,m+=s,n=(0,c.getWindow)(r),r=(0,c.getFrameElement)(n)}}return(0,t.rectToClientRect)({width:h,height:v,x:d,y:m})}function v(e,t){let n=(0,c.getNodeScroll)(e).scrollLeft;return t?t.left+n:h((0,c.getDocumentElement)(e)).left+n}function b(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-v(e,n),y:n.top+t.scrollTop}}function x(e,n,r){var i;let o;if("viewport"===n||"layoutViewport"===n)o=function(e,t,n){void 0===n&&(n="viewport");let r="layoutViewport"===n,i=(0,c.getWindow)(e),o=(0,c.getDocumentElement)(e),s=i.visualViewport,a=o.clientWidth,l=o.clientHeight,u=0,d=0;if(s){let e=!(0,c.isWebKit)()||"fixed"===t;r?e||(u=-s.offsetLeft,d=-s.offsetTop):(a=s.width,l=s.height,e&&(u=s.offsetLeft,d=s.offsetTop))}if(0>=v(o)){let e=o.ownerDocument,t=e.body,n=getComputedStyle(t),r="CSS1Compat"===e.compatMode&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,i=Math.abs(o.clientWidth-t.clientWidth-r),s="stable both-edges"===getComputedStyle(o).scrollbarGutter?i/2:i;s<=25&&(a-=s)}return{width:a,height:l,x:u,y:d}}(e,r,n);else if("document"===n){let n,r,s,a,l,u;i=(0,c.getDocumentElement)(e),n=(0,c.getNodeScroll)(i),r=i.ownerDocument.body,s=(0,t.max)(i.scrollWidth,i.clientWidth,r.scrollWidth,r.clientWidth),a=(0,t.max)(i.scrollHeight,i.clientHeight,r.scrollHeight,r.clientHeight),l=-n.scrollLeft+v(i),u=-n.scrollTop,"rtl"===(0,c.getComputedStyle)(r).direction&&(l+=(0,t.max)(i.clientWidth,r.clientWidth)-s),o={width:s,height:a,x:l,y:u}}else if((0,c.isElement)(n)){let e,t,i,s,a,l;t=(e=h(n,!0,"fixed"===r)).top+n.clientTop,i=e.left+n.clientLeft,s=p(n),a=n.clientWidth*s.x,l=n.clientHeight*s.y,o={width:a,height:l,x:i*s.x,y:t*s.y}}else{let t=g(e);o={x:n.x-t.x,y:n.y-t.y,width:n.width,height:n.height}}return(0,t.rectToClientRect)(o)}function y(e){return"static"===(0,c.getComputedStyle)(e).position}function S(e,t){if(!(0,c.isHTMLElement)(e)||"fixed"===(0,c.getComputedStyle)(e).position)return null;if(t)return t(e);let n=e.offsetParent;return(0,c.getDocumentElement)(e)===n&&(n=n.ownerDocument.body),n}function C(e,t){let n=(0,c.getWindow)(e);if((0,c.isTopLayer)(e))return n;if(!(0,c.isHTMLElement)(e)){let t=(0,c.getParentNode)(e);for(;t&&!(0,c.isLastTraversableNode)(t);){if((0,c.isElement)(t)&&!y(t))return t;t=(0,c.getParentNode)(t)}return n}let r=S(e,t);for(;r&&(0,c.isTableElement)(r)&&y(r);)r=S(r,t);return r&&(0,c.isLastTraversableNode)(r)&&y(r)&&!(0,c.isContainingBlock)(r)?n:r||(0,c.getContainingBlock)(e)||n}let E=async function(e){let n=this.getOffsetParent||C,r=this.getDimensions,i=await r(e.floating);return{reference:function(e,n,r){let i=(0,c.isHTMLElement)(n),o=(0,c.getDocumentElement)(n),s="fixed"===r,a=h(e,!0,s,n),l={scrollLeft:0,scrollTop:0},u=(0,t.createCoords)(0);if((i||!s)&&(("body"!==(0,c.getNodeName)(n)||(0,c.isOverflowElement)(o))&&(l=(0,c.getNodeScroll)(n)),i)){let e=h(n,!0,s,n);u.x=e.x+n.clientLeft,u.y=e.y+n.clientTop}!i&&o&&(u.x=v(o));let d=!o||i||s?(0,t.createCoords)(0):b(o,l);return{x:a.left+l.scrollLeft-u.x-d.x,y:a.top+l.scrollTop-u.y-d.y,width:a.width,height:a.height}}(e.reference,await n(e.floating),e.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}},R={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:n,rect:r,offsetParent:i,strategy:o}=e,s="fixed"===o,a=(0,c.getDocumentElement)(i),l=!!n&&(0,c.isTopLayer)(n.floating);if(i===a||l&&s)return r;let u={scrollLeft:0,scrollTop:0},d=(0,t.createCoords)(1),f=(0,t.createCoords)(0),m=(0,c.isHTMLElement)(i);if((m||!s)&&(("body"!==(0,c.getNodeName)(i)||(0,c.isOverflowElement)(a))&&(u=(0,c.getNodeScroll)(i)),m)){let e=h(i);d=p(i),f.x=e.x+i.clientLeft,f.y=e.y+i.clientTop}let g=!a||m||s?(0,t.createCoords)(0):b(a,u);return{width:r.width*d.x,height:r.height*d.y,x:r.x*d.x-u.scrollLeft*d.x+f.x+g.x,y:r.y*d.y-u.scrollTop*d.y+f.y+g.y}},getDocumentElement:c.getDocumentElement,getClippingRect:function(e){let{element:n,boundary:r,rootBoundary:i,strategy:o}=e,s=[..."clippingAncestors"===r?(0,c.isTopLayer)(n)?[]:function(e,t){let n=t.get(e);if(n)return n;let r=(0,c.getOverflowAncestors)(e,[],!1).filter(e=>(0,c.isElement)(e)&&"body"!==(0,c.getNodeName)(e)),i=null,o="fixed"===(0,c.getComputedStyle)(e).position,s=o?(0,c.getParentNode)(e):e;for(;(0,c.isElement)(s)&&!(0,c.isLastTraversableNode)(s);){let e=(0,c.getComputedStyle)(s),t=(0,c.isContainingBlock)(s),n=i?i.position:o?"fixed":"";t||"fixed"!==n&&("absolute"!==n||"static"!==e.position)?i=e:r=r.filter(e=>e!==s),s=(0,c.getParentNode)(s)}return t.set(e,r),r}(n,this._c):[].concat(r),i],a=x(n,s[0],o),l=a.top,u=a.right,d=a.bottom,f=a.left;for(let e=1;e<s.length;e++){let r=x(n,s[e],o);l=(0,t.max)(r.top,l),u=(0,t.min)(r.right,u),d=(0,t.min)(r.bottom,d),f=(0,t.max)(r.left,f)}return{width:u-f,height:d-l,x:f,y:l}},getOffsetParent:C,getElementRects:E,getClientRects:function(e){return e.getClientRects?Array.from(e.getClientRects()):[]},getDimensions:function(e){let{width:t,height:n}=d(e);return{width:t,height:n}},getScale:p,isElement:c.isElement,isRTL:function(e){return"rtl"===(0,c.getComputedStyle)(e).direction}};function w(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}let I=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;let{x:i,y:o,placement:s,middlewareData:a}=t,l=await u(t,e);return s===(null==(n=a.offset)?void 0:n.placement)&&null!=(r=a.arrow)&&r.alignmentOffset?{}:{x:i+l.x,y:o+l.y,data:{...l,placement:s}}}}},T=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(n){let{x:r,y:i,placement:o,platform:s}=n,{mainAxis:a=!0,crossAxis:l=!1,limiter:u={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...c}=(0,t.evaluate)(e,n),d={x:r,y:i},f=await s.detectOverflow(n,c),p=(0,t.getSideAxis)(o),m=(0,t.getOppositeAxis)(p),g=d[m],h=d[p],v=(e,n)=>(0,t.clamp)(n+f["y"===e?"top":"left"],n,n-f["y"===e?"bottom":"right"]);a&&(g=v(m,g)),l&&(h=v(p,h));let b=u.fn({...n,[m]:g,[p]:h});return{...b,data:{x:b.x-r,y:b.y-i,enabled:{[m]:a,[p]:l}}}}}},O=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(n){var r,i,o,s,a;let{placement:l,middlewareData:u,rects:c,initialPlacement:d,platform:f,elements:p}=n,{mainAxis:m=!0,crossAxis:g=!0,fallbackPlacements:h,fallbackStrategy:v="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:x=!0,...y}=(0,t.evaluate)(e,n);if(null!=(r=u.arrow)&&r.alignmentOffset)return{};let S=(0,t.getSide)(l),C=(0,t.getSideAxis)(d),E=(0,t.getSide)(d)===d,R=await (null==f.isRTL?void 0:f.isRTL(p.floating)),w=h||(E||!x?[(0,t.getOppositePlacement)(d)]:(0,t.getExpandedPlacements)(d)),I="none"!==b;!h&&I&&w.push(...(0,t.getOppositeAxisPlacements)(d,x,b,R));let T=[d,...w],O=await f.detectOverflow(n,y),k=[],M=(null==(i=u.flip)?void 0:i.overflows)||[];if(m&&k.push(O[S]),g){let e=(0,t.getAlignmentSides)(l,c,R);k.push(O[e[0]],O[e[1]])}if(M=[...M,{placement:l,overflows:k}],!k.every(e=>e<=0)){let e=((null==(o=u.flip)?void 0:o.index)||0)+1,n=T[e];if(n&&("alignment"!==g||C===(0,t.getSideAxis)(n)||M.every(e=>(0,t.getSideAxis)(e.placement)!==C||e.overflows[0]>0)))return{data:{index:e,overflows:M},reset:{placement:n}};let r=null==(s=M.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:s.placement;if(!r)switch(v){case"bestFit":{let e=null==(a=M.filter(e=>{if(I){let n=(0,t.getSideAxis)(e.placement);return n===C||"y"===n}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:a[0];e&&(r=e);break}case"initialPlacement":r=d}if(l!==r)return{reset:{placement:r}}}return{}}}},k=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(n){let r,i,{placement:o,rects:s,platform:a,elements:l}=n,{apply:u=()=>{},...c}=(0,t.evaluate)(e,n),d=await a.detectOverflow(n,c),f=(0,t.getSide)(o),p=(0,t.getAlignment)(o),m="y"===(0,t.getSideAxis)(o),{width:g,height:h}=s.floating;"top"===f||"bottom"===f?(r=f,i=p===(await (null==a.isRTL?void 0:a.isRTL(l.floating))?"start":"end")?"left":"right"):(i=f,r="end"===p?"top":"bottom");let v=h-d.top-d.bottom,b=g-d.left-d.right,x=(0,t.min)(h-d[r],v),y=(0,t.min)(g-d[i],b),S=n.middlewareData.shift,C=!S,E=x,R=y;null!=S&&S.enabled.x&&(R=b),null!=S&&S.enabled.y&&(E=v),C&&!p&&(m?R=g-2*(0,t.max)(d.left,d.right):E=h-2*(0,t.max)(d.top,d.bottom)),await u({...n,availableWidth:R,availableHeight:E});let w=await a.getDimensions(l.floating);return g!==w.width||h!==w.height?{reset:{rects:!0}}:{}}}},M=function(e){return void 0===e&&(e={}),{options:e,fn(n){var r,i,o,s;let{x:a,y:u,placement:c,rects:d,middlewareData:f}=n,{offset:p=0,mainAxis:m=!0,crossAxis:g=!0}=(0,t.evaluate)(e,n),h={x:a,y:u},v=(0,t.getSideAxis)(c),b=(0,t.getOppositeAxis)(v),x=h[b],y=h[v],S=(0,t.evaluate)(p,n),C="number"==typeof S?{mainAxis:S,crossAxis:0}:{mainAxis:null!=(r=S.mainAxis)?r:0,crossAxis:null!=(i=S.crossAxis)?i:0};if(m){let e="y"===b?"height":"width",t=d.reference[b]-d.floating[e]+C.mainAxis,n=d.reference[b]+d.reference[e]-C.mainAxis;x<t?x=t:x>n&&(x=n)}if(g){let e="y"===b?"width":"height",n=l.has((0,t.getSide)(c)),r=d.reference[v]-d.floating[e]+(n&&(null==(o=f.offset)?void 0:o[v])||0)+(n?0:C.crossAxis),i=d.reference[v]+d.reference[e]+(n?0:(null==(s=f.offset)?void 0:s[v])||0)-(n?C.crossAxis:0);y<r?y=r:y>i&&(y=i)}return{[b]:x,[v]:y}}}},A=(e,t,n)=>{let r=new Map,o=null!=n?n:{},s={...R,...o.platform,_c:r};return i(e,t,{...o,platform:s})};e.s(["arrow",0,e=>({name:"arrow",options:e,async fn(n){let{x:r,y:i,placement:o,rects:s,platform:a,elements:l,middlewareData:u}=n,{element:c,padding:d=0}=(0,t.evaluate)(e,n)||{};if(null==c)return{};let f=(0,t.getPaddingObject)(d),p={x:r,y:i},m=(0,t.getAlignmentAxis)(o),g=(0,t.getAxisLength)(m),h=await a.getDimensions(c),v="y"===m,b=v?"clientHeight":"clientWidth",x=s.reference[g]+s.reference[m]-p[m]-s.floating[g],y=p[m]-s.reference[m],S=await (null==a.getOffsetParent?void 0:a.getOffsetParent(c)),C=S?S[b]:0;C&&await (null==a.isElement?void 0:a.isElement(S))||(C=l.floating[b]||s.floating[g]);let E=C/2-h[g]/2-1,R=(0,t.min)(f[v?"top":"left"],E),w=(0,t.min)(f[v?"bottom":"right"],E),I=C-h[g]-w,T=C/2-h[g]/2+(x/2-y/2),O=(0,t.clamp)(R,T,I),k=!u.arrow&&null!=(0,t.getAlignment)(o)&&T!==O&&s.reference[g]/2-(T<R?R:w)-h[g]/2<0,M=k?T<R?T-R:T-I:0;return{[m]:p[m]+M,data:{[m]:O,centerOffset:T-O-M,...k&&{alignmentOffset:M}},reset:k}}}),"autoPlacement",0,function(e){return void 0===e&&(e={}),{name:"autoPlacement",options:e,async fn(n){var r,i,o,s;let{rects:a,middlewareData:l,placement:u,platform:c,elements:d}=n,{crossAxis:f=!1,alignment:p,allowedPlacements:m=t.placements,autoAlignment:g=!0,...h}=(0,t.evaluate)(e,n),v=void 0!==p||m===t.placements?((s=p||null)?[...m.filter(e=>(0,t.getAlignment)(e)===s),...m.filter(e=>(0,t.getAlignment)(e)!==s)]:m.filter(e=>(0,t.getSide)(e)===e)).filter(e=>!s||(0,t.getAlignment)(e)===s||!!g&&(0,t.getOppositeAlignmentPlacement)(e)!==e):m,b=(null==(r=l.autoPlacement)?void 0:r.index)||0,x=v[b];if(null==x)return{};if(u!==x)return{reset:{placement:v[0]}};let y=await c.detectOverflow(n,h),S=(0,t.getAlignmentSides)(x,a,await (null==c.isRTL?void 0:c.isRTL(d.floating))),C=[y[(0,t.getSide)(x)],y[S[0]],y[S[1]]],E=[...(null==(i=l.autoPlacement)?void 0:i.overflows)||[],{placement:x,overflows:C}],R=v[b+1];if(R)return{data:{index:b+1,overflows:E},reset:{placement:R}};let w=E.map(e=>{let n=(0,t.getAlignment)(e.placement);return[e.placement,n&&f?e.overflows.slice(0,2).reduce((e,t)=>e+t,0):e.overflows[0],e.overflows]}).sort((e,t)=>e[1]-t[1]),I=(null==(o=w.filter(e=>e[2].slice(0,(0,t.getAlignment)(e[0])?2:3).every(e=>e<=0))[0])?void 0:o[0])||w[0][0];return I!==u?{data:{index:b+1,overflows:E},reset:{placement:I}}:{}}}},"autoUpdate",0,function(e,n,r,i){let o;void 0===i&&(i={});let{ancestorScroll:s=!0,ancestorResize:a=!0,elementResize:l="function"==typeof ResizeObserver,layoutShift:u="function"==typeof IntersectionObserver,animationFrame:d=!1}=i,p=f(e),m=s||a?[...p?(0,c.getOverflowAncestors)(p):[],...n?(0,c.getOverflowAncestors)(n):[]]:[];m.forEach(e=>{s&&e.addEventListener("scroll",r),a&&e.addEventListener("resize",r)});let g=p&&u?function(e,n,r){let i,o=null,s=(0,c.getDocumentElement)(e);function a(){var e;clearTimeout(i),null==(e=o)||e.disconnect(),o=null}function l(r,u){void 0===r&&(r=!1),void 0===u&&(u=1),a();let c=e.getBoundingClientRect(),{left:d,top:f,width:p,height:m}=c;if(r||n(),!p||!m)return;let g={rootMargin:-(0,t.floor)(f)+"px "+-(0,t.floor)(s.clientWidth-(d+p))+"px "+-(0,t.floor)(s.clientHeight-(f+m))+"px "+-(0,t.floor)(d)+"px",threshold:(0,t.max)(0,(0,t.min)(1,u))||1},h=!0;function v(t){let n=t[0].intersectionRatio;if(!w(c,e.getBoundingClientRect()))return l();if(n!==u){if(!h)return l();n?l(!1,n):i=setTimeout(()=>{l(!1,1e-7)},1e3)}h=!1}try{o=new IntersectionObserver(v,{...g,root:s.ownerDocument})}catch(e){o=new IntersectionObserver(v,g)}o.observe(e)}let u=(0,c.getWindow)(e),d=()=>l(r);return u.addEventListener("resize",d),l(!0),()=>{u.removeEventListener("resize",d),a()}}(p,r,a):null,v=-1,b=null;l&&(b=new ResizeObserver(e=>{let[t]=e;t&&t.target===p&&b&&n&&(b.unobserve(n),cancelAnimationFrame(v),v=requestAnimationFrame(()=>{var e;null==(e=b)||e.observe(n)})),r()}),p&&!d&&b.observe(p),n&&b.observe(n));let x=d?h(e):null;return d&&function t(){let n=h(e);x&&!w(x,n)&&r(),x=n,o=requestAnimationFrame(t)}(),r(),()=>{var e;m.forEach(e=>{s&&e.removeEventListener("scroll",r),a&&e.removeEventListener("resize",r)}),null==g||g(),null==(e=b)||e.disconnect(),b=null,d&&cancelAnimationFrame(o)}},"computePosition",0,A,"flip",0,O,"hide",0,function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(n){let{rects:r,platform:i}=n,{strategy:a="referenceHidden",...l}=(0,t.evaluate)(e,n);switch(a){case"referenceHidden":{let e=o(await i.detectOverflow(n,{...l,elementContext:"reference"}),r.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:s(e)}}}case"escaped":{let e=o(await i.detectOverflow(n,{...l,altBoundary:!0}),r.floating);return{data:{escapedOffsets:e,escaped:s(e)}}}default:return{}}}}},"inline",0,function(e){return void 0===e&&(e={}),{name:"inline",options:e,async fn(n){let{placement:r,elements:i,rects:o,platform:s,strategy:l}=n,{padding:u=2,x:c,y:d}=(0,t.evaluate)(e,n),f=Array.from(await (null==s.getClientRects?void 0:s.getClientRects(i.reference))||[]);if(!f.length)return{};let p=function(e){let n=e.slice().sort((e,t)=>e.y-t.y),r=[],i=null;for(let e=0;e<n.length;e++){let t=n[e];!i||t.y-i.y>i.height/2?r.push([t]):r[r.length-1].push(t),i=t}return r.map(e=>(0,t.rectToClientRect)(a(e)))}(f),m=(0,t.rectToClientRect)(a(f)),g=(0,t.getPaddingObject)(u),h=await s.getElementRects({reference:{getBoundingClientRect:function(){if(2===p.length&&(p[0].left>p[1].right||p[1].left>p[0].right)&&null!=c&&null!=d)return p.find(e=>c>e.left-g.left&&c<e.right+g.right&&d>e.top-g.top&&d<e.bottom+g.bottom)||m;if(p.length>=2){if("y"===(0,t.getSideAxis)(r)){let e=p[0],n=p[p.length-1],i="top"===(0,t.getSide)(r),o=e.top,s=n.bottom,a=i?e.left:n.left,l=i?e.right:n.right;return(0,t.rectToClientRect)({x:a,y:o,width:l-a,height:s-o})}let e="left"===(0,t.getSide)(r),n=(0,t.max)(...p.map(e=>e.right)),i=(0,t.min)(...p.map(e=>e.left)),o=p.filter(t=>e?t.left===i:t.right===n),s=o[0].top,a=o[o.length-1].bottom;return(0,t.rectToClientRect)({x:i,y:s,width:n-i,height:a-s})}return m}},floating:i.floating,strategy:l});return o.reference.x!==h.reference.x||o.reference.y!==h.reference.y||o.reference.width!==h.reference.width||o.reference.height!==h.reference.height?{reset:{rects:h}}:{}}}},"limitShift",0,M,"offset",0,I,"platform",0,R,"shift",0,T,"size",0,k],53760);var P=e.i(71645),N=e.i(74080),j="u">typeof document?P.useLayoutEffect:function(){};function L(e,t){let n,r,i;if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if((n=e.length)!==t.length)return!1;for(r=n;0!=r--;)if(!L(e[r],t[r]))return!1;return!0}if((n=(i=Object.keys(e)).length)!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!({}).hasOwnProperty.call(t,i[r]))return!1;for(r=n;0!=r--;){let n=i[r];if(("_owner"!==n||!e.$$typeof)&&!L(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function D(e){return"u"<typeof window?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function z(e,t){let n=D(e);return Math.round(t*n)/n}function F(e){let t=P.useRef(e);return j(()=>{t.current=e}),t}function H(e){void 0===e&&(e={});let{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:s}={},transform:a=!0,whileElementsMounted:l,open:u}=e,[c,d]=P.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=P.useState(r);L(f,r)||p(r);let[m,g]=P.useState(null),[h,v]=P.useState(null),b=P.useCallback(e=>{e!==C.current&&(C.current=e,g(e))},[]),x=P.useCallback(e=>{e!==E.current&&(E.current=e,v(e))},[]),y=o||m,S=s||h,C=P.useRef(null),E=P.useRef(null),R=P.useRef(c),w=null!=l,I=F(l),T=F(i),O=F(u),k=P.useCallback(()=>{if(!C.current||!E.current)return;let e={placement:t,strategy:n,middleware:f};T.current&&(e.platform=T.current),A(C.current,E.current,e).then(e=>{let t={...e,isPositioned:!1!==O.current};M.current&&!L(R.current,t)&&(R.current=t,N.flushSync(()=>{d(t)}))})},[f,t,n,T,O]);j(()=>{!1===u&&R.current.isPositioned&&(R.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[u]);let M=P.useRef(!1);j(()=>(M.current=!0,()=>{M.current=!1}),[]),j(()=>{if(y&&(C.current=y),S&&(E.current=S),y&&S){if(I.current)return I.current(y,S,k);k()}},[y,S,k,I,w]);let H=P.useMemo(()=>({reference:C,floating:E,setReference:b,setFloating:x}),[b,x]),V=P.useMemo(()=>({reference:y,floating:S}),[y,S]),_=P.useMemo(()=>{let e={position:n,left:0,top:0};if(!V.floating)return e;let t=z(V.floating,c.x),r=z(V.floating,c.y);return a?{...e,transform:"translate("+t+"px, "+r+"px)",...D(V.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}},[n,a,V.floating,c.x,c.y]);return P.useMemo(()=>({...c,update:k,refs:H,elements:V,floatingStyles:_}),[c,k,H,V,_])}e.s(["flip",0,(e,t)=>{let n=O(e);return{name:n.name,fn:n.fn,options:[e,t]}},"limitShift",0,(e,t)=>({fn:M(e).fn,options:[e,t]}),"offset",0,(e,t)=>{let n=I(e);return{name:n.name,fn:n.fn,options:[e,t]}},"shift",0,(e,t)=>{let n=T(e);return{name:n.name,fn:n.fn,options:[e,t]}},"size",0,(e,t)=>{let n=k(e);return{name:n.name,fn:n.fn,options:[e,t]}},"useFloating",0,H],58950);var V=e.i(46376),_=e.i(46420);e.s(["useBaseUIFloating",0,function(e){return function(e,t){let{nodeId:n,externalTree:r}=e,i=t.useState("referenceElement"),o=t.useState("floatingElement"),s=t.useState("domReferenceElement"),a=t.useState("open"),l=t.useState("floatingId"),[u,d]=P.useState(null),[f,p]=P.useState(void 0),[m,g]=P.useState(void 0),h=P.useRef(null),v=(0,_.useFloatingTree)(r),b=P.useMemo(()=>({reference:i,floating:o,domReference:s}),[i,o,s]),x=H({...e,elements:{...b,...u&&{reference:u}}}),y=(0,c.isElement)(f)?f:null,S=void 0===m?t.state.floatingElement:m;t.useSyncedValue("referenceElement",f??null),t.useSyncedValue("domReferenceElement",void 0===f?s:y),t.useSyncedValue("floatingElement",S);let C=P.useCallback(e=>{let t=(0,c.isElement)(e)?{getBoundingClientRect:()=>e.getBoundingClientRect(),getClientRects:()=>e.getClientRects(),contextElement:e}:e;d(t),x.refs.setReference(t)},[x.refs]),E=P.useCallback(e=>{((0,c.isElement)(e)||null===e)&&(h.current=e,p(e)),((0,c.isElement)(x.refs.reference.current)||null===x.refs.reference.current||null!==e&&!(0,c.isElement)(e))&&x.refs.setReference(e)},[x.refs,p]),R=P.useCallback(e=>{g(e),x.refs.setFloating(e)},[x.refs]),w=P.useMemo(()=>({...x.refs,setReference:E,setFloating:R,setPositionReference:C,domReference:h}),[x.refs,E,R,C]),I=P.useMemo(()=>({...x.elements,domReference:s}),[x.elements,s]),T=P.useMemo(()=>({...x,dataRef:t.context.dataRef,open:a,onOpenChange:t.setOpen,events:t.context.events,floatingId:l,refs:w,elements:I,nodeId:n,rootStore:t}),[x,w,I,n,t,a,l]);return(0,V.useIsoLayoutEffect)(()=>{s&&(h.current=s)},[s]),(0,V.useIsoLayoutEffect)(()=>{t.context.dataRef.current.floatingContext=T;let e=v?.nodesRef.current.find(e=>e.id===n);e&&(e.context=T)}),P.useMemo(()=>({...x,context:T,refs:w,elements:I,rootStore:t}),[x,w,I,T,t])}(e,e.rootContext)}],88643)},43084,e=>{"use strict";let t=["top","right","bottom","left"],n=t.reduce((e,t)=>e.concat(t,t+"-start",t+"-end"),[]),r=Math.min,i=Math.max,o=Math.round,s=Math.floor,a={left:"right",right:"left",bottom:"top",top:"bottom"};function l(e){return e.split("-")[0]}function u(e){return e.split("-")[1]}function c(e){return"x"===e?"y":"x"}function d(e){return"y"===e?"height":"width"}function f(e){let t=e[0];return"t"===t||"b"===t?"y":"x"}function p(e){return c(f(e))}function m(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}let g=["left","right"],h=["right","left"],v=["top","bottom"],b=["bottom","top"];function x(e){let t=l(e);return a[t]+e.slice(t.length)}e.s(["clamp",0,function(e,t,n){return i(e,r(t,n))},"createCoords",0,e=>({x:e,y:e}),"evaluate",0,function(e,t){return"function"==typeof e?e(t):e},"floor",0,s,"getAlignment",0,u,"getAlignmentAxis",0,p,"getAlignmentSides",0,function(e,t,n){void 0===n&&(n=!1);let r=u(e),i=p(e),o=d(i),s="x"===i?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[o]>t.floating[o]&&(s=x(s)),[s,x(s)]},"getAxisLength",0,d,"getExpandedPlacements",0,function(e){let t=x(e);return[m(e),t,m(t)]},"getOppositeAlignmentPlacement",0,m,"getOppositeAxis",0,c,"getOppositeAxisPlacements",0,function(e,t,n,r){let i=u(e),o=function(e,t,n){switch(e){case"top":case"bottom":if(n)return t?h:g;return t?g:h;case"left":case"right":return t?v:b;default:return[]}}(l(e),"start"===n,r);return i&&(o=o.map(e=>e+"-"+i),t&&(o=o.concat(o.map(m)))),o},"getOppositePlacement",0,x,"getPaddingObject",0,function(e){var t,n,r,i;return"number"!=typeof e?{top:null!=(t=e.top)?t:0,right:null!=(n=e.right)?n:0,bottom:null!=(r=e.bottom)?r:0,left:null!=(i=e.left)?i:0}:{top:e,right:e,bottom:e,left:e}},"getSide",0,l,"getSideAxis",0,f,"max",0,i,"min",0,r,"placements",0,n,"rectToClientRect",0,function(e){let{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}},"round",0,o,"sides",0,t])},87255,76561,47211,50092,52886,26391,19647,16984,10001,e=>{"use strict";var t=e.i(56420);let n={name:"anchor",size:24,node:[["path",{d:"M12 6v16",key:"nqf5sj"}],["path",{d:"m19 13 2-1a9 9 0 0 1-18 0l2 1",key:"y7qv08"}],["path",{d:"M9 11h6",key:"1fldmi"}],["circle",{cx:"12",cy:"4",r:"2",key:"muu5ef"}]]};n.node;let r=(0,t.default)(n);e.s(["Anchor",0,r],87255);let i={name:"archive",size:24,node:[["rect",{width:"20",height:"5",x:"2",y:"3",rx:"1",key:"1wp1u1"}],["path",{d:"M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8",key:"1s80jp"}],["path",{d:"M10 12h4",key:"a56b0p"}]]};i.node;let o=(0,t.default)(i);e.s(["Archive",0,o],76561);let s={name:"ban",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M4.929 4.929 19.07 19.071",key:"196cmz"}]]};s.node;let a=(0,t.default)(s);e.s(["Ban",0,a],47211);let l={name:"circle-arrow-right",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m12 16 4-4-4-4",key:"1i9zcv"}],["path",{d:"M8 12h8",key:"1wcyev"}]],aliases:["arrow-right-circle"]};l.node;let u=(0,t.default)(l);e.s(["CircleArrowRight",0,u],50092);let c={name:"circle-dashed",size:24,node:[["path",{d:"M10.1 2.182a10 10 0 0 1 3.8 0",key:"5ilxe3"}],["path",{d:"M13.9 21.818a10 10 0 0 1-3.8 0",key:"11zvb9"}],["path",{d:"M17.609 3.721a10 10 0 0 1 2.69 2.7",key:"1iw5b2"}],["path",{d:"M2.182 13.9a10 10 0 0 1 0-3.8",key:"c0bmvh"}],["path",{d:"M20.279 17.609a10 10 0 0 1-2.7 2.69",key:"1ruxm7"}],["path",{d:"M21.818 10.1a10 10 0 0 1 0 3.8",key:"qkgqxc"}],["path",{d:"M3.721 6.391a10 10 0 0 1 2.7-2.69",key:"1mcia2"}],["path",{d:"M6.391 20.279a10 10 0 0 1-2.69-2.7",key:"1fvljs"}]]};c.node;let d=(0,t.default)(c);e.s(["CircleDashed",0,d],52886);let f={name:"circle-dot-dashed",size:24,node:[["path",{d:"M10.1 2.18a9.93 9.93 0 0 1 3.8 0",key:"1qdqn0"}],["path",{d:"M17.6 3.71a9.95 9.95 0 0 1 2.69 2.7",key:"1bq7p6"}],["path",{d:"M21.82 10.1a9.93 9.93 0 0 1 0 3.8",key:"1rlaqf"}],["path",{d:"M20.29 17.6a9.95 9.95 0 0 1-2.7 2.69",key:"1xk03u"}],["path",{d:"M13.9 21.82a9.94 9.94 0 0 1-3.8 0",key:"l7re25"}],["path",{d:"M6.4 20.29a9.95 9.95 0 0 1-2.69-2.7",key:"1v18p6"}],["path",{d:"M2.18 13.9a9.93 9.93 0 0 1 0-3.8",key:"xdo6bj"}],["path",{d:"M3.71 6.4a9.95 9.95 0 0 1 2.7-2.69",key:"1jjmaz"}],["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}]]};f.node;let p=(0,t.default)(f);e.s(["CircleDotDashed",0,p],26391);let m={name:"circle-minus",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}]],aliases:["minus-circle"]};m.node;let g=(0,t.default)(m);e.s(["CircleMinus",0,g],19647);let h={name:"circle-x",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]],aliases:["x-circle"]};h.node;let v=(0,t.default)(h);e.s(["CircleX",0,v],16984);let b={name:"flag-off",size:24,node:[["path",{d:"M16 16c-3 0-5-2-8-2a6 6 0 0 0-4 1.528",key:"1q158e"}],["path",{d:"m2 2 20 20",key:"1ooewy"}],["path",{d:"M4 22V4",key:"1plyxx"}],["path",{d:"M7.656 2H8c3 0 5 2 7.333 2q2 0 3.067-.8A1 1 0 0 1 20 4v10.347",key:"xj1b71"}]]};b.node;let x=(0,t.default)(b);e.s(["FlagOff",0,x],10001)},89664,e=>{"use strict";var t=e.i(56420);let n={name:"check",size:24,node:[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]};n.node;let r=(0,t.default)(n);e.s(["Check",0,r],89664)},24071,e=>{"use strict";var t=e.i(56420);let n={name:"chevron-left",size:24,node:[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]};n.node;let r=(0,t.default)(n);e.s(["ChevronLeft",0,r],24071)},67927,e=>{"use strict";var t=e.i(56420);let n={name:"chevron-right",size:24,node:[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]};n.node;let r=(0,t.default)(n);e.s(["ChevronRight",0,r],67927)},77913,e=>{"use strict";var t=e.i(56420);let n={name:"drafting-compass",size:24,node:[["path",{d:"m12.99 6.74 1.93 3.44",key:"iwagvd"}],["path",{d:"M19.136 12a10 10 0 0 1-14.271 0",key:"ppmlo4"}],["path",{d:"m21 21-2.16-3.84",key:"vylbct"}],["path",{d:"m3 21 8.02-14.26",key:"1ssaw4"}],["circle",{cx:"12",cy:"5",r:"2",key:"f1ur92"}]]};n.node;let r=(0,t.default)(n);e.s(["DraftingCompass",0,r],77913)},71028,e=>{"use strict";var t=e.i(56420);let n={name:"gauge",size:24,node:[["path",{d:"m12 14 4-4",key:"9kzdfg"}],["path",{d:"M3.34 19a10 10 0 1 1 17.32 0",key:"19p75a"}]]};n.node;let r=(0,t.default)(n);e.s(["Gauge",0,r],71028)},81658,85627,66787,92870,e=>{"use strict";var t=e.i(56420);let n={name:"hourglass",size:24,node:[["path",{d:"M5 22h14",key:"ehvnwv"}],["path",{d:"M5 2h14",key:"pdyrp9"}],["path",{d:"M17 22v-4.172a2 2 0 0 0-.586-1.414L12 12l-4.414 4.414A2 2 0 0 0 7 17.828V22",key:"1d314k"}],["path",{d:"M7 2v4.172a2 2 0 0 0 .586 1.414L12 12l4.414-4.414A2 2 0 0 0 17 6.172V2",key:"1vvvr6"}]]};n.node;let r=(0,t.default)(n);e.s(["Hourglass",0,r],81658);let i={name:"sailboat",size:24,node:[["path",{d:"M10 2v15",key:"1qf71f"}],["path",{d:"M7 22a4 4 0 0 1-4-4 1 1 0 0 1 1-1h16a1 1 0 0 1 1 1 4 4 0 0 1-4 4z",key:"1pxcvx"}],["path",{d:"M9.159 2.46a1 1 0 0 1 1.521-.193l9.977 8.98A1 1 0 0 1 20 13H4a1 1 0 0 1-.824-1.567z",key:"5oog16"}]]};i.node;let o=(0,t.default)(i);e.s(["Sailboat",0,o],85627);let s={name:"triangle-alert",size:24,node:[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]],aliases:["alert-triangle"]};s.node;let a=(0,t.default)(s);e.s(["TriangleAlert",0,a],66787);let l={name:"user-check",size:24,node:[["path",{d:"m16 11 2 2 4-4",key:"9rsbq5"}],["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]]};l.node;let u=(0,t.default)(l);e.s(["UserCheck",0,u],92870)},44594,e=>{"use strict";var t=e.i(56420);let n={name:"inbox",size:24,node:[["polyline",{points:"22 12 16 12 14 15 10 15 8 12 2 12",key:"o97t9d"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}]]};n.node;let r=(0,t.default)(n);e.s(["Inbox",0,r],44594)},67784,e=>{"use strict";var t=e.i(56420);let n={name:"log-out",size:24,node:[["path",{d:"m16 17 5-5-5-5",key:"1bji2h"}],["path",{d:"M21 12H9",key:"dn1m92"}],["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}]]};n.node;let r=(0,t.default)(n);e.s(["LogOut",0,r],67784)},46513,96699,35965,18162,e=>{"use strict";var t=e.i(56420);let n={name:"monitor",size:24,node:[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21",key:"1svkeh"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21",key:"vw1qmm"}]]};n.node;let r=(0,t.default)(n);e.s(["Monitor",0,r],46513);let i={name:"moon",size:24,node:[["path",{d:"M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401",key:"kfwtm"}]]};i.node;let o=(0,t.default)(i);e.s(["Moon",0,o],96699);let s={name:"sun",size:24,node:[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]]};s.node;let a=(0,t.default)(s);e.s(["Sun",0,a],35965),e.i(31627),e.i(68404);var l=e.i(49635);e.s(["THEME_LABELS",0,{light:"Light",dark:"Dark",system:"System"},"applyTheme",0,function(e){let t=document.documentElement;t.dataset.theme=e;let n="dark"===e||"system"===e&&window.matchMedia("(prefers-color-scheme: dark)").matches;t.classList.toggle("dark",n)},"sessionSince",0,function(e,t){let n=new Date(e.since),r=n.toDateString()===t.toDateString()?(0,l.clockTime)(n):(0,l.shortDateTime)(n);return`Device \xb7 ${e.device}, since ${r}`}],18162)},77071,e=>{"use strict";var t=e.i(56420);let n={name:"plus",size:24,node:[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]};n.node;let r=(0,t.default)(n);e.s(["Plus",0,r],77071)},60011,e=>{"use strict";var t=e.i(56420);let n={name:"shapes",size:24,node:[["path",{d:"M8.3 10a.7.7 0 0 1-.626-1.079L11.4 3a.7.7 0 0 1 1.198-.043L16.3 8.9a.7.7 0 0 1-.572 1.1Z",key:"1bo67w"}],["rect",{x:"3",y:"14",width:"7",height:"7",rx:"1",key:"1bkyp8"}],["circle",{cx:"17.5",cy:"17.5",r:"3.5",key:"w3z12y"}]]};n.node;let r=(0,t.default)(n);e.s(["Shapes",0,r],60011)},55838,(e,t,n)=>{"use strict";var r=e.r(71645),i="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},o=r.useState,s=r.useEffect,a=r.useLayoutEffect,l=r.useDebugValue;function u(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!i(e,n)}catch(e){return!0}}var c="u"<typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var n=t(),r=o({inst:{value:n,getSnapshot:t}}),i=r[0].inst,c=r[1];return a(function(){i.value=n,i.getSnapshot=t,u(i)&&c({inst:i})},[e,n,t]),s(function(){return u(i)&&c({inst:i}),e(function(){u(i)&&c({inst:i})})},[e]),l(n),n};n.useSyncExternalStore=void 0!==r.useSyncExternalStore?r.useSyncExternalStore:c},2239,(e,t,n)=>{"use strict";e.i(47167),t.exports=e.r(55838)},52822,(e,t,n)=>{"use strict";var r=e.r(71645),i=e.r(2239),o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},s=i.useSyncExternalStore,a=r.useRef,l=r.useEffect,u=r.useMemo,c=r.useDebugValue;n.useSyncExternalStoreWithSelector=function(e,t,n,r,i){var d=a(null);if(null===d.current){var f={hasValue:!1,value:null};d.current=f}else f=d.current;var p=s(e,(d=u(function(){function e(e){if(!l){if(l=!0,s=e,e=r(e),void 0!==i&&f.hasValue){var t=f.value;if(i(t,e))return a=t}return a=e}if(t=a,o(s,e))return t;var n=r(e);return void 0!==i&&i(t,n)?(s=e,t):(s=e,a=n)}var s,a,l=!1,u=void 0===n?null:n;return[function(){return e(t())},null===u?void 0:function(){return e(u())}]},[t,n,r,i]))[0],d[1]);return l(function(){f.hasValue=!0,f.value=p},[p]),c(p),p}},30224,(e,t,n)=>{"use strict";e.i(47167),t.exports=e.r(52822)},66390,e=>{"use strict";var t=e.i(76782),n=e.i(52245),r=e.i(25913),i=e.i(90063);let o=(0,r.cva)("inline-flex w-fit shrink-0 items-center justify-center gap-1.5 border font-medium whitespace-nowrap [&>svg]:pointer-events-none [&>svg]:size-(--size-icon-sm)",{variants:{variant:{secondary:"h-5.5 rounded-sm border-transparent bg-secondary px-1.5 text-caption text-secondary-foreground",outline:"h-5.5 rounded-sm border-border bg-transparent px-1.5 text-caption text-foreground",type:"h-5.5 rounded-sm border-transparent bg-secondary px-1.5 font-mono text-id text-foreground",kind:"h-5.5 rounded-sm border-transparent bg-highlight px-1.5 font-mono text-id text-primary",count:"h-5 min-w-5 rounded-full border-transparent bg-primary px-1.5 text-micro font-semibold text-primary-foreground tabular-nums","count-attention":"h-5 min-w-5 rounded-full border-tone-attention-border bg-tone-attention-bg px-1.5 text-micro font-semibold text-tone-attention-fg tabular-nums"}},defaultVariants:{variant:"secondary"}});e.s(["Badge",0,function({className:e,variant:r,render:s,...a}){var l;return l={defaultTagName:"span",props:(0,t.mergeProps)({className:(0,i.classNames)(o({variant:r}),e)},a),render:s,state:{slot:"badge",variant:r}},(0,n.useRenderElement)(l.defaultTagName??"div",l,l)}],66390)},33173,e=>{"use strict";var t=e.i(43476),n=e.i(25933),r=e.i(89664),i=e.i(71645),o=e.i(90063),s=e.i(12470);e.s(["Combobox",0,function({options:e,value:a,onValueChange:l,isFreeText:u=!1,toQuery:c,groupLabel:d,emptyText:f,leadingIcon:p,placeholder:m,id:g,isInvalid:h=!1,"aria-describedby":v,"aria-label":b,"data-testid":x}){let y=e.find(e=>e.value===a),[S,C]=(0,i.useState)(y?.label??(u?a??"":"")),[E,R]=(0,i.useState)(!1),w=e.filter(e=>e.label.toLowerCase().includes(S.trim().toLowerCase())),I=y?.label===S?y:void 0,T=void 0!==I&&(void 0!==I.detail||void 0!==I.trailing),O=u?e.find(e=>e.label===S):y;return(0,t.jsxs)(n.Combobox.Root,{items:w,filter:null,value:O??null,itemToStringLabel:e=>e.label,isItemEqualToValue:(e,t)=>e.value===t.value,inputValue:S,open:E&&""!==S.trim(),onOpenChange:R,onInputValueChange:(e,t)=>{if(u&&"input-change"!==t.reason&&"item-press"!==t.reason)return;let n="input-change"===t.reason&&c?c(e):e;C(n),u?l(""===n?null:n):void 0!==y&&n!==y.label&&l(null)},onValueChange:e=>{e&&(C(e.label),l(u?e.label:e.value))},children:[(0,t.jsxs)("div",{className:"relative w-full [&_svg]:size-(--size-icon)",children:[p?(0,t.jsx)("span",{"aria-hidden":!0,className:"pointer-events-none absolute inset-y-0 left-3 flex items-center text-muted-foreground",children:p}):null,(0,t.jsx)(n.Combobox.Input,{id:g,placeholder:m,"aria-invalid":h,"aria-describedby":v,"aria-label":b,"data-testid":x,"data-slot":"combobox-input",className:(0,o.classNames)((0,s.inputVariants)({isMono:!0}),p?"pl-9":void 0,T?"pr-44 max-sm:pr-28":void 0)}),T?(0,t.jsxs)("span",{className:"pointer-events-none absolute inset-y-0 right-2.5 flex items-center gap-2",children:[I.detail?(0,t.jsx)("span",{className:"truncate text-meta text-muted-foreground max-sm:hidden",children:I.detail}):null,I.trailing]}):null]}),(0,t.jsx)(n.Combobox.Portal,{children:(0,t.jsx)(n.Combobox.Positioner,{className:"isolate z-50 outline-none",sideOffset:4,children:(0,t.jsxs)(n.Combobox.Popup,{"data-slot":"combobox-content",className:"max-h-(--available-height) w-(--anchor-width) origin-(--transform-origin) overflow-y-auto rounded-lg border border-border bg-popover p-1 text-popover-foreground shadow-lg duration-(--duration-fast) outline-none data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",children:[f?(0,t.jsx)(n.Combobox.Empty,{className:"px-2.5 py-2 text-meta text-muted-foreground empty:hidden",children:f(S.trim())}):null,(0,t.jsxs)(n.Combobox.List,{children:[d&&w.length>0?(0,t.jsx)("div",{className:"px-2.5 pt-1.5 pb-1 text-caption text-muted-foreground",children:d}):null,w.map(e=>(0,t.jsxs)(n.Combobox.Item,{value:e,"data-slot":"combobox-item",className:"relative flex min-h-8.5 items-center gap-2.5 rounded-sm pr-8 pl-2.5 text-body text-foreground outline-none select-none data-disabled:pointer-events-none data-disabled:opacity-45 data-highlighted:bg-accent",children:[(0,t.jsx)("span",{className:"font-mono text-id font-medium",children:e.label}),e.detail?(0,t.jsx)("span",{className:"truncate text-meta text-muted-foreground",children:e.detail}):null,e.trailing?(0,t.jsx)("span",{className:"ml-auto flex items-center",children:e.trailing}):null,(0,t.jsx)(n.Combobox.ItemIndicator,{className:"absolute right-2.5 flex items-center",children:(0,t.jsx)(r.Check,{"aria-hidden":!0,className:"size-(--size-icon)"})})]},e.value))]})]})})})]})}])},22212,13488,64170,25326,53753,94945,43988,e=>{"use strict";var t=e.i(43476);e.i(14651);var n=e.i(2820),r=e.i(56736),i=e.i(9793),o=e.i(84324),s=e.i(64951),a=e.i(50440),l=e.i(74217),u=e.i(77173),c=e.i(33332),d=e.i(71645),f=e.i(96499),p=e.i(8821),m=e.i(40886),g=e.i(52245),h=e.i(79938),v=e.i(38396),b=e.i(59636),x=e.i(64111),y=e.i(88015),S=e.i(85689),C=e.i(32199);let E=(0,f.fastComponentRef)(function(e,t){let{render:n,className:r,style:i,disabled:o=!1,nativeButton:s=!0,id:a,payload:l,handle:u,...f}=e,E=(0,p.useDialogRootContext)(!0),R=(0,b.usePopupHandleStore)(u)??E;if(!R)throw Error((0,c.default)(79));let w=(0,y.useBaseUiId)(a),I=R.useState("floatingRootContext"),T=R.useState("isOpenedByTrigger",w),O=R.useState("triggerPopupId",w),k=d.useRef(null),{registerTrigger:M,isMountedByThisTrigger:A}=(0,x.useTriggerDataForwarding)(w,k,R,{payload:l}),{getButtonProps:P,buttonRef:N}=(0,m.useButton)({disabled:o,native:s}),j=(0,S.useClick)(I),L=(0,C.useOpenMethodTriggerProps)(()=>R.select("open"),e=>{R.set("openMethod",e)}),D=R.useState("triggerProps",A);return(0,g.useRenderElement)("button",e,{state:{disabled:o,open:T},ref:[N,t,M,k],props:[j.reference,D,L,{[v.CLICK_TRIGGER_IDENTIFIER]:"",id:w,"aria-haspopup":"dialog","aria-expanded":T,"aria-controls":O},f,P],stateAttributesMapping:h.triggerOpenStateMapping})});e.s(["DialogTrigger",0,E],13488);var R=e.i(1807),w=e.i(75606),I=e.i(56434);class T{attachedStores=[];attachedStoreValue=null;storeListeners=new Set;constructor(e,t,n=!0){this.fallbackStore=e,this.componentName=t,this.throwOnMissingTrigger=n}get attachedStore(){return this.attachedStoreValue}get store(){return this.attachedStoreValue??this.fallbackStore}get serverStore(){return this.fallbackStore}subscribeStore(e){return this.storeListeners.add(e),()=>{this.storeListeners.delete(e)}}attachStore(e){return this.attachedStores.push(e),this.setActiveStore(e),()=>{let t=this.attachedStores.lastIndexOf(e);-1!==t&&this.attachedStores.splice(t,1),this.setActiveStore(this.attachedStores[this.attachedStores.length-1]??null)}}setActiveStore(e){this.attachedStoreValue!==e&&(this.attachedStoreValue=e,this.storeListeners.forEach(e=>{e()}))}openByTrigger(e){let t,n=this.attachedStore;if(null!==n){if(e){for(let n=this.attachedStores.length-1;n>=0&&!t;n-=1)t=this.attachedStores[n].context.triggerElements.getById(e);t??=this.fallbackStore.context.triggerElements.getById(e)}if(e&&!t&&this.throwOnMissingTrigger)throw Error((0,c.default)(99,this.componentName,e,this.componentName));n.setOpen(!0,(0,w.createChangeEventDetails)(I.REASONS.imperativeAction,void 0,t))}}closePopup(){let e=this.attachedStore;null===e||e.setOpen(!1,(0,w.createChangeEventDetails)(I.REASONS.imperativeAction))}}e.s(["BasePopupHandle",0,T],64170);class O extends T{constructor(){super((0,R.createNullDialogStore)(),"Dialog",!1)}open(e){this.openByTrigger(e)}openWithPayload(e){let t=this.attachedStore;null===t||(t.set("payload",e),t.setOpen(!0,(0,w.createChangeEventDetails)(I.REASONS.imperativeAction)))}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}}function k(){return new O}e.s(["DialogHandle",0,O,"createDialogHandle",0,k],25326),e.s(["Backdrop",()=>n.DialogBackdrop,"Close",()=>r.DialogClose,"Description",()=>i.DialogDescription,"Handle",0,O,"Popup",()=>o.DialogPopup,"Portal",()=>s.DialogPortal,"Root",()=>a.DialogRoot,"Title",()=>u.DialogTitle,"Trigger",0,E,"Viewport",()=>l.DialogViewport,"createHandle",0,k],28376);var M=e.i(28376);e.s(["Dialog",0,M],53753);var M=M,A=e.i(90063),P=e.i(25913);let N={overlay:"fixed inset-0 isolate z-50 bg-overlay duration-(--duration-base) data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",popup:(0,P.cva)("fixed top-1/2 left-1/2 z-50 grid max-h-[calc(100dvh-var(--spacing)*8)] w-full max-w-[calc(100%-var(--spacing)*8)] -translate-x-1/2 -translate-y-1/2 gap-4 overflow-y-auto rounded-xl border border-border bg-popover p-6 text-body text-popover-foreground shadow-lg duration-(--duration-base) outline-none data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95 motion-reduce:data-open:zoom-in-100 motion-reduce:data-closed:zoom-out-100",{variants:{size:{sm:"sm:max-w-(--size-dialog-sm)",md:"sm:max-w-(--size-dialog-md)"}},defaultVariants:{size:"sm"}}),header:"flex flex-col gap-2",footer:"flex flex-col-reverse gap-2 pt-1 sm:flex-row sm:justify-end",title:"text-heading font-semibold text-foreground",description:"text-body text-muted-foreground",phoneSheet:"max-sm:top-auto max-sm:bottom-0 max-sm:left-0 max-sm:max-w-full max-sm:translate-x-0 max-sm:translate-y-0 max-sm:rounded-none max-sm:rounded-t-2xl max-sm:border-x-0 max-sm:border-b-0 max-sm:px-4 max-sm:pb-[max(calc(var(--spacing)*4),env(safe-area-inset-bottom))] max-sm:[&_[data-slot=button]]:h-(--size-control-touch) max-sm:[&_[data-slot=button]]:w-full",phoneFullScreen:"max-sm:top-0 max-sm:left-0 max-sm:h-dvh max-sm:max-w-full max-sm:translate-x-0 max-sm:translate-y-0 max-sm:content-start max-sm:overflow-y-auto max-sm:rounded-none max-sm:border-0"};e.s(["dialogSurface",0,N],94945),e.s(["Dialog",0,function(e){return(0,t.jsx)(M.Root,{"data-slot":"dialog",...e})},"DialogClose",0,function(e){return(0,t.jsx)(M.Close,{"data-slot":"dialog-close",...e})},"DialogContent",0,function({className:e,size:n,children:r,...i}){return(0,t.jsxs)(M.Portal,{children:[(0,t.jsx)(M.Backdrop,{"data-slot":"dialog-overlay",className:N.overlay}),(0,t.jsx)(M.Popup,{"data-slot":"dialog-content",className:(0,A.classNames)(N.popup({size:n}),e),...i,children:r})]})},"DialogDescription",0,function({className:e,...n}){return(0,t.jsx)(M.Description,{"data-slot":"dialog-description",className:(0,A.classNames)(N.description,e),...n})},"DialogFooter",0,function({className:e,...n}){return(0,t.jsx)("div",{"data-slot":"dialog-footer",className:(0,A.classNames)(N.footer,e),...n})},"DialogHeader",0,function({className:e,...n}){return(0,t.jsx)("div",{"data-slot":"dialog-header",className:(0,A.classNames)(N.header,e),...n})},"DialogTitle",0,function({className:e,...n}){return(0,t.jsx)(M.Title,{"data-slot":"dialog-title",className:(0,A.classNames)(N.title,e),...n})}],22212);let j=(0,P.cva)("w-full min-w-0 resize-none rounded-md border border-input bg-card px-3 py-2 text-foreground shadow-sm transition-[border-color,box-shadow] duration-(--duration-fast) outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/22 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/16 disabled:cursor-not-allowed disabled:bg-muted disabled:opacity-50 disabled:shadow-none",{variants:{size:{md:"text-body",touch:"rounded-lg text-input-touch"},isMono:{true:"font-mono",false:""}},compoundVariants:[{size:"md",isMono:!0,className:"text-code"}],defaultVariants:{size:"md",isMono:!1}});e.s(["Textarea",0,function({className:e,size:n,isMono:r,rows:i=4,...o}){return(0,t.jsx)("textarea",{"data-slot":"textarea",rows:i,className:(0,A.classNames)(j({size:n,isMono:r}),e),...o})}],43988)},57334,e=>{"use strict";var t=e.i(43476);e.i(61027);var n=e.i(82370),r=e.i(89554),i=e.i(85996),o=e.i(71714),s=e.i(81194),a=e.i(1545),l=e.i(91384),u=e.i(58307),c=e.i(64270),d=e.i(19712),f=e.i(82264),p=e.i(62050),m=e.i(82593),g=e.i(5953),h=e.i(63947),v=e.i(77450),b=e.i(33332),x=e.i(71645),y=e.i(39957),S=e.i(8868),C=e.i(96499),E=e.i(67865),R=e.i(46376),w=e.i(56789),I=e.i(50316),T=e.i(85689),O=e.i(46420),k=e.i(13082),M=e.i(72135),A=e.i(79248),P=e.i(84446),N=e.i(78921),j=e.i(79938),L=e.i(52245),D=e.i(40886),z=e.i(64042),F=e.i(95530);function H(e){let{render:t,className:n,style:r,state:i=w.EMPTY_OBJECT,props:o=w.EMPTY_ARRAY,refs:s=w.EMPTY_ARRAY,metadata:a,stateAttributesMapping:l,tag:u="div",...c}=e,{compositeProps:d,compositeRef:f}=(0,F.useCompositeItem)({metadata:a});return(0,L.useRenderElement)(u,e,{state:i,ref:[f,...s],props:[d,...o,c],stateAttributesMapping:l})}var V=e.i(38452),_=e.i(29315),B=e.i(59636),q=e.i(64111),W=e.i(46570),$=e.i(88015),U=e.i(56434),K=e.i(7447),G=e.i(38396),Y=e.i(52535),Q=e.i(76782);let X=(0,C.fastComponentRef)(function(e,n){let r,{render:i,className:o,style:s,disabled:a=!1,nativeButton:l=!0,id:u,openOnHover:c,delay:d=100,closeDelay:f=0,handle:p,payload:m,...g}=e,h=(0,N.useMenuRootContext)(!0),v=(0,B.usePopupHandleStore)(p)??h?.store;if(!v)throw Error((0,b.default)(85));let C=(0,$.useBaseUiId)(u),F=v.useState("isTriggerActive",C),X=v.useState("floatingRootContext"),J=v.useState("isOpenedByTrigger",C),Z=v.useState("triggerPopupId",C),ee=x.useRef(null),et=(r=(0,K.useMenubarContext)(!0),x.useMemo(()=>r?{type:"menubar",context:r}:{type:void 0},[r])),en=(0,V.useCompositeRootContext)(!0),er=(0,O.useFloatingTree)(),ei=x.useMemo(()=>er??new A.FloatingTreeStore,[er]),eo=(0,O.useFloatingNodeId)(ei),es=(0,O.useFloatingParentNodeId)(),{registerTrigger:ea,isMountedByThisTrigger:el}=(0,q.useTriggerDataForwarding)(C,ee,v,{payload:m,closeDelay:f,parent:et,floatingTreeRoot:ei,floatingNodeId:eo,floatingParentNodeId:es,keyboardEventRelay:en?.relayKeyboardEvent}),eu="menubar"===et.type,ec=v.useState("disabled"),ed=a||ec||eu&&et.context.disabled,{getButtonProps:ef,buttonRef:ep}=(0,D.useButton)({disabled:ed,native:l});x.useEffect(()=>{J||void 0!==et.type||(v.context.allowMouseUpTriggerRef.current=!1)},[v,J,et.type]);let em=x.useRef(null),eg=(0,y.useTimeout)(),eh=(0,E.useStableCallback)(e=>{if(!em.current)return;eg.clear(),v.context.allowMouseUpTriggerRef.current=!1;let t=e.target;(0,P.contains)(em.current,t)||(0,P.contains)(v.select("positionerElement"),t)||t===em.current||null!=t&&function e(t){return(0,_.isHTMLElement)(t)&&t.hasAttribute("data-rootownerid")?t.getAttribute("data-rootownerid"):(0,_.isLastTraversableNode)(t)?void 0:e((0,_.getParentNode)(t))}(t)===v.select("rootId")||(0,z.isMouseWithinBounds)(e,em.current)||ei.events.emit("close",{domEvent:e,reason:U.REASONS.cancelOpen})});x.useEffect(()=>{J&&v.select("lastOpenChangeReason")===U.REASONS.triggerHover&&(0,S.ownerDocument)(em.current).addEventListener("mouseup",eh,{once:!0})},[J,eh,v]);let ev=eu&&et.context.hasSubmenuOpen,eb=c??ev,ex=(0,M.useHoverReferenceInteraction)(X,{enabled:eb&&!ed&&(!eu||ev&&!el),handleClose:(0,I.safePolygon)({blockPointerEvents:!eu}),mouseOnly:!0,move:!1,restMs:void 0===et.type?d:void 0,delay:{close:f},triggerElementRef:ee,externalTree:ei,isActiveTrigger:F,isClosing:()=>"ending"===v.select("transitionStatus")}),ey=function(e,t){let n=(0,y.useTimeout)(),[r,i]=x.useState(!1);return(0,R.useIsoLayoutEffect)(()=>{e&&t===U.REASONS.triggerHover?(i(!0),n.start(G.PATIENT_CLICK_THRESHOLD,()=>{i(!1)})):e||(n.clear(),i(!1))},[e,t,n]),r}(J,v.select("lastOpenChangeReason")),eS=(0,T.useClick)(X,{enabled:!ed,event:J&&eu?"click":"mousedown",toggle:!0,ignoreMouse:!1,stickIfOpen:void 0===et.type&&ey}),eC=(0,k.useFocus)(X,{enabled:!ed&&ev}),eE=function(e){let{enabled:t=!0,mouseDownAction:n,open:r}=e,i=x.useRef(!1);return x.useMemo(()=>t?{onMouseDown:e=>{("open"===n&&!r||"close"===n&&r)&&(i.current=!0,(0,S.ownerDocument)(e.currentTarget).addEventListener("click",()=>{i.current=!1},{once:!0}))},onClick:e=>{i.current&&(i.current=!1,e.preventBaseUIHandler())}}:w.EMPTY_OBJECT,[t,n,r])}({open:J,enabled:eu,mouseDownAction:"open"}),eR=x.useMemo(()=>(0,Q.mergeProps)(eC.reference,eS.reference),[eC.reference,eS.reference]),ew=v.useState("triggerProps",el),{preFocusGuardRef:eI,handlePreFocusGuardFocus:eT,handleFocusTargetFocus:eO}=(0,W.useTriggerFocusGuards)(v,ee),ek={disabled:ed,open:J},eM=[em,n,ep,ea,ee],eA=[eR,ex??w.EMPTY_OBJECT,ew,{"aria-haspopup":"menu","aria-controls":Z,id:C,onMouseDown:e=>{v.select("open")||(eg.start(200,()=>{v.context.allowMouseUpTriggerRef.current=!0}),(0,S.ownerDocument)(e.currentTarget).addEventListener("mouseup",eh,{once:!0}))}},eu?{role:"menuitem"}:{},eE,g,ef],eP=(0,L.useRenderElement)("button",e,{enabled:!eu,stateAttributesMapping:j.pressableTriggerOpenStateMapping,state:ek,ref:eM,props:eA});return eu?(0,t.jsx)(H,{tag:"button",render:i,className:o,style:s,state:ek,refs:eM,props:eA,stateAttributesMapping:j.pressableTriggerOpenStateMapping}):J?(0,t.jsxs)(x.Fragment,{children:[(0,t.jsx)(Y.FocusGuard,{ref:eI,onFocus:eT},`${C}-pre-focus-guard`),(0,t.jsx)(x.Fragment,{children:eP},C),(0,t.jsx)(Y.FocusGuard,{ref:v.context.triggerFocusTargetRef,onFocus:eO},`${C}-post-focus-guard`)]}):(0,t.jsx)(x.Fragment,{children:eP},C)});var J=e.i(3414),Z=e.i(18390);let ee=x.forwardRef(function(e,t){let{render:n,className:r,style:i,children:o,...s}=e,{store:a}=(0,N.useMenuRootContext)(),{side:l}=(0,J.useMenuPositionerContext)(),u=a.useState("instantType"),{children:c,state:d}=(0,Z.usePopupViewport)({store:a,side:l,children:o}),f={activationDirection:d.activationDirection,transitioning:d.transitioning,instant:u};return(0,L.useRenderElement)("div",e,{state:f,ref:t,props:[s,{children:c}],stateAttributesMapping:Z.popupViewportStateMapping})}),et=x.forwardRef(function(e,t){let{className:n,render:r,orientation:i="horizontal",style:o,...s}=e;return(0,L.useRenderElement)("div",e,{state:{orientation:i},ref:t,props:[{role:"separator","aria-orientation":i},s]})});var en=e.i(28744),er=e.i(73553),ei=e.i(66506),eo=e.i(74671);let es={"aria-expanded":void 0},ea=x.forwardRef(function(e,t){let{render:n,className:r,style:i,label:o,id:s,nativeButton:a=!1,openOnHover:l=!0,delay:u=100,closeDelay:c=0,disabled:d=!1,...f}=e,p=(0,eo.useMenuSubmenuRootContext)();if(!p?.parentMenu)throw Error((0,b.default)(37));let m=(0,er.useCompositeListItem)({guess:!0,label:o}),g=(0,J.useMenuPositionerContext)(),{store:h}=(0,N.useMenuRootContext)(),v=(0,$.useBaseUiId)(s),y=h.useState("open"),S=h.useState("floatingRootContext"),C=h.useState("floatingTreeRoot"),O=h.useState("triggerPopupId",v),k=(0,q.useTriggerRegistration)(v,h),A=(0,E.useStableCallback)(e=>{k(e),null!==e&&h.select("open")&&null==h.select("activeTriggerId")&&h.update({activeTriggerId:v??null,activeTriggerElement:e,closeDelay:c})}),P=x.useRef(null),D=x.useCallback(e=>{P.current=e,h.set("activeTriggerElement",e)},[h]);(0,R.useIsoLayoutEffect)(()=>(A(P.current),()=>A(null)),[A,v,h]),h.useSyncedValue("closeDelay",c);let z=p.parentMenu,F=h.useState("disabled"),H=z.useState("disabled"),V=d||F||H,_=z.useState("itemProps"),B=z.useState("isActive",m.index),W=x.useMemo(()=>({type:"submenu-trigger",setActive(){z.select("highlightItemOnHover")&&z.set("activeIndex",m.index)}}),[z,m.index]),{getItemProps:K,itemRef:G}=(0,ei.useMenuItem)({closeOnClick:!1,disabled:V,highlighted:B,id:v,store:h,typingRef:z.context.typingRef,nativeButton:a,itemMetadata:W,nodeId:g?.context.nodeId}),Y=h.useState("hoverEnabled"),Q=(0,M.useHoverReferenceInteraction)(S,{enabled:Y&&l&&!V,handleClose:(0,I.safePolygon)({blockPointerEvents:!0}),mouseOnly:!0,move:!0,restMs:u,delay:{open:u,close:c},shouldOpen:u>0?()=>z.select("allowMouseEnter"):void 0,triggerElementRef:P,externalTree:C,isClosing:()=>"ending"===h.select("transitionStatus"),guardStaleOpen:!0}),X=(0,T.useClick)(S,{enabled:!V,event:"mousedown",toggle:!l,ignoreMouse:l,stickIfOpen:!1}).reference??w.EMPTY_OBJECT,Z=h.useState("triggerProps",!0);delete Z.id;let ee=h.useState("openMethod"),et=h.useState("lastOpenChangeReason")===U.REASONS.listNavigation||"keyboard"===ee,ea=y&&et&&en.platform.screenReader.voiceOver;return(0,L.useRenderElement)("div",e,{state:{disabled:V,highlighted:B,open:y},stateAttributesMapping:j.triggerOpenStateMapping,props:[X,Q,Z,_,ea?es:void 0,{"aria-controls":O,tabIndex:y||B?0:-1,onBlur(){B&&z.set("activeIndex",null)}},f,K],ref:[t,m.ref,G,A,D]})});var el=e.i(36481),eu=e.i(64170);class ec extends eu.BasePopupHandle{constructor(){super((0,el.createNullMenuStore)(),"Menu")}open(e){this.openByTrigger(e)}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}}e.s(["Arrow",()=>n.MenuArrow,"Backdrop",()=>r.MenuBackdrop,"CheckboxItem",()=>i.MenuCheckboxItem,"CheckboxItemIndicator",()=>o.MenuCheckboxItemIndicator,"Group",()=>s.MenuGroup,"GroupLabel",()=>a.MenuGroupLabel,"Handle",0,ec,"Item",()=>l.MenuItem,"LinkItem",()=>u.MenuLinkItem,"Popup",()=>c.MenuPopup,"Portal",()=>d.MenuPortal,"Positioner",()=>f.MenuPositioner,"RadioGroup",()=>p.MenuRadioGroup,"RadioItem",()=>m.MenuRadioItem,"RadioItemIndicator",()=>g.MenuRadioItemIndicator,"Root",()=>h.MenuRoot,"Separator",0,et,"SubmenuRoot",()=>v.MenuSubmenuRoot,"SubmenuTrigger",0,ea,"Trigger",0,X,"Viewport",0,ee,"createHandle",0,function(){return new ec}],60948);var ed=e.i(60948),ed=ed,ef=e.i(89664),ep=e.i(90063);e.s(["DropdownMenu",0,function(e){return(0,t.jsx)(ed.Root,{"data-slot":"dropdown-menu",...e})},"DropdownMenuContent",0,function({align:e="end",side:n="bottom",sideOffset:r=4,className:i,...o}){return(0,t.jsx)(ed.Portal,{children:(0,t.jsx)(ed.Positioner,{className:"isolate z-50 outline-none",align:e,side:n,sideOffset:r,children:(0,t.jsx)(ed.Popup,{"data-slot":"dropdown-menu-content",className:(0,ep.classNames)("max-h-(--available-height) min-w-48 origin-(--transform-origin) overflow-y-auto rounded-xl border border-border bg-popover p-1 text-popover-foreground shadow-lg duration-(--duration-fast) outline-none data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",i),...o})})})},"DropdownMenuGroup",0,function(e){return(0,t.jsx)(ed.Group,{"data-slot":"dropdown-menu-group",...e})},"DropdownMenuItem",0,function({className:e,variant:n="default",...r}){return(0,t.jsx)(ed.Item,{"data-slot":"dropdown-menu-item","data-variant":n,className:(0,ep.classNames)("relative flex h-8.5 items-center gap-2.5 rounded-sm px-2.5 text-body text-foreground outline-none select-none data-highlighted:bg-accent focus-visible:outline-2 focus-visible:outline-ring data-disabled:pointer-events-none data-disabled:opacity-45 data-[variant=destructive]:text-destructive-text [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-(--size-icon) [&_svg]:text-muted-foreground data-[variant=destructive]:[&_svg]:text-destructive-text",e),...r})},"DropdownMenuLabel",0,function({className:e,...n}){return(0,t.jsx)(ed.GroupLabel,{"data-slot":"dropdown-menu-label",className:(0,ep.classNames)("px-2.5 pt-1.5 pb-1 text-caption text-muted-foreground",e),...n})},"DropdownMenuRadioGroup",0,function(e){return(0,t.jsx)(ed.RadioGroup,{"data-slot":"dropdown-menu-radio-group",...e})},"DropdownMenuRadioItem",0,function({className:e,children:n,...r}){return(0,t.jsxs)(ed.RadioItem,{"data-slot":"dropdown-menu-radio-item",className:(0,ep.classNames)("relative flex h-8.5 items-center gap-2.5 rounded-sm px-2.5 text-body text-foreground outline-none select-none data-highlighted:bg-accent focus-visible:outline-2 focus-visible:outline-ring data-disabled:pointer-events-none data-disabled:opacity-45 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-(--size-icon) [&_svg]:text-muted-foreground",e),...r,children:[n,(0,t.jsx)(ed.RadioItemIndicator,{className:"ml-auto flex",children:(0,t.jsx)(ef.Check,{"aria-hidden":!0,className:"text-foreground"})})]})},"DropdownMenuSeparator",0,function({className:e,...n}){return(0,t.jsx)(ed.Separator,{"data-slot":"dropdown-menu-separator",className:(0,ep.classNames)("-mx-1 my-1 h-px bg-border",e),...n})},"DropdownMenuTrigger",0,function(e){return(0,t.jsx)(ed.Trigger,{"data-slot":"dropdown-menu-trigger",...e})}],57334)},75305,e=>{"use strict";var t=e.i(43476),n=e.i(53753),r=e.i(25913),i=e.i(60964),o=e.i(90063),s=e.i(15905);let a=(0,r.cva)("fixed z-50 flex flex-col bg-popover text-body text-popover-foreground shadow-lg outline-none duration-(--duration-slow) ease-(--ease-standard) data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",{variants:{side:{right:"inset-y-0 right-0 h-full w-full border-l border-border sm:max-w-(--size-sheet) motion-safe:data-open:slide-in-from-right motion-safe:data-closed:slide-out-to-right",bottom:"inset-x-0 bottom-0 max-h-[90dvh] rounded-t-2xl border-t border-border px-4 pt-2 pb-[max(calc(var(--spacing)*4),env(safe-area-inset-bottom))] motion-safe:data-open:slide-in-from-bottom motion-safe:data-closed:slide-out-to-bottom"}},defaultVariants:{side:"right"}});e.s(["Sheet",0,function(e){return(0,t.jsx)(n.Dialog.Root,{"data-slot":"sheet",...e})},"SheetBody",0,function({className:e,...n}){return(0,t.jsx)("div",{"data-slot":"sheet-body",className:(0,o.classNames)("min-h-0 flex-1 overflow-y-auto in-data-[side=right]:p-6",e),...n})},"SheetClose",0,function(e){return(0,t.jsx)(n.Dialog.Close,{"data-slot":"sheet-close",...e})},"SheetContent",0,function({className:e,children:r,side:l="right",...u}){return(0,t.jsxs)(n.Dialog.Portal,{children:[(0,t.jsx)(n.Dialog.Backdrop,{"data-slot":"sheet-overlay",className:"fixed inset-0 z-50 bg-overlay duration-(--duration-slow) data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0"}),(0,t.jsxs)(n.Dialog.Popup,{"data-slot":"sheet-content","data-side":l,className:(0,o.classNames)(a({side:l}),e),...u,children:["bottom"===l?(0,t.jsx)("div",{"aria-hidden":!0,className:"mx-auto mb-3 h-1 w-9 shrink-0 rounded-full bg-border"}):(0,t.jsx)(n.Dialog.Close,{"data-slot":"sheet-close",render:(0,t.jsx)(s.Button,{variant:"ghost",size:"sm",isIconOnly:!0,className:"absolute top-4 right-4","aria-label":"Close"}),children:(0,t.jsx)(i.XIcon,{})}),r]})]})},"SheetDescription",0,function({className:e,...r}){return(0,t.jsx)(n.Dialog.Description,{"data-slot":"sheet-description",className:(0,o.classNames)("text-meta text-muted-foreground",e),...r})},"SheetHeader",0,function({className:e,...n}){return(0,t.jsx)("div",{"data-slot":"sheet-header",className:(0,o.classNames)("flex flex-col gap-0.5 in-data-[side=right]:border-b in-data-[side=right]:px-6 in-data-[side=right]:py-5 in-data-[side=right]:pr-14",e),...n})},"SheetTitle",0,function({className:e,...r}){return(0,t.jsx)(n.Dialog.Title,{"data-slot":"sheet-title",className:(0,o.classNames)("text-heading font-semibold text-foreground in-data-[side=bottom]:py-2 in-data-[side=bottom]:text-section",e),...r})},"SheetTrigger",0,function(e){return(0,t.jsx)(n.Dialog.Trigger,{"data-slot":"sheet-trigger",...e})}])},19321,e=>{"use strict";var t=e.i(43476),n=e.i(90063);e.s(["Skeleton",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"skeleton","aria-hidden":!0,className:(0,n.classNames)("animate-pulse rounded-sm bg-secondary [animation-duration:var(--duration-pulse)] motion-reduce:animate-none",e),...r})}])},60592,e=>{"use strict";var t=e.i(43476);e.i(59657);var n=e.i(41840),r=e.i(88368),i=e.i(49637),o=e.i(49487),s=e.i(71645),a=e.i(67865),l=e.i(46376),u=e.i(56789),c=e.i(53687),d=e.i(19749),f=e.i(38452),p=e.i(52245),m=e.i(72855);function g(e){let{render:n,className:r,style:i,refs:o=u.EMPTY_ARRAY,props:a=u.EMPTY_ARRAY,state:l=u.EMPTY_OBJECT,stateAttributesMapping:g,highlightedIndex:h,onHighlightedIndexChange:v,orientation:b,grid:x,loopFocus:y,onLoop:S,enableHomeAndEndKeys:C,onMapChange:E,stopEventPropagation:R=!0,rootRef:w,disabledIndices:I,modifierKeys:T,highlightItemOnHover:O=!1,tag:k="div",...M}=e,A=(0,m.useDirection)(),{props:P,highlightedIndex:N,onHighlightedIndexChange:j,elementsRef:L,onMapChange:D,relayKeyboardEvent:z}=(0,d.useCompositeRoot)({grid:x,loopFocus:y,onLoop:S,orientation:b,highlightedIndex:h,onHighlightedIndexChange:v,rootRef:w,stopEventPropagation:R,enableHomeAndEndKeys:C,direction:A,disabledIndices:I,modifierKeys:T}),F=(0,p.useRenderElement)(k,e,{state:l,ref:o,props:[P,...a,M],stateAttributesMapping:g}),H=s.useMemo(()=>({highlightedIndex:N,onHighlightedIndexChange:j,highlightItemOnHover:O,relayKeyboardEvent:z}),[N,j,O,z]);return(0,t.jsx)(f.CompositeRootContext.Provider,{value:H,children:(0,t.jsx)(c.CompositeList,{elementsRef:L,onMapChange:e=>{E?.(e),D(e)},children:F})})}var h=e.i(81524),v=e.i(1634),b=e.i(7120);let x=s.forwardRef(function(e,n){let{activateOnFocus:r=!1,className:i,loopFocus:o=!0,render:c,style:d,...f}=e,{orientation:p,setTabMap:m,tabActivationDirection:x}=(0,v.useTabsRootContext)(),[y,S]=s.useState(0),[C,E]=s.useState(null),R=s.useRef(new Set),w=s.useRef(new Set),I=s.useRef(null);(0,l.useIsoLayoutEffect)(()=>{if("u"<typeof ResizeObserver)return;let e=new ResizeObserver(()=>{R.current.forEach(e=>{e()})});return I.current=e,C&&e.observe(C),w.current.forEach(t=>{e.observe(t)}),()=>{e.disconnect(),I.current=null}},[C]);let T=(0,a.useStableCallback)(e=>(R.current.add(e),()=>{R.current.delete(e)})),O=(0,a.useStableCallback)(e=>(w.current.add(e),I.current?.observe(e),()=>{w.current.delete(e),I.current?.unobserve(e)})),k=s.useMemo(()=>({activateOnFocus:r,registerIndicatorUpdateListener:T,registerTabResizeObserverElement:O,tabsListElement:C}),[r,T,O,C]);return(0,t.jsx)(b.TabsListContext.Provider,{value:k,children:(0,t.jsx)(g,{render:c,className:i,style:d,state:{orientation:p,tabActivationDirection:x},refs:[n,E],props:[{"aria-orientation":"vertical"===p?"vertical":void 0,role:"tablist"},f],stateAttributesMapping:h.tabsStateAttributesMapping,highlightedIndex:y,enableHomeAndEndKeys:!0,loopFocus:o,orientation:p,onHighlightedIndexChange:S,onMapChange:m,disabledIndices:u.EMPTY_ARRAY})})});e.s(["Indicator",()=>i.TabsIndicator,"List",0,x,"Panel",()=>o.TabsPanel,"Root",()=>n.TabsRoot,"Tab",()=>r.TabsTab],69281);var y=e.i(69281),y=y,S=e.i(25913),C=e.i(90063);let E=(0,S.cva)("",{variants:{variant:{segmented:"inline-flex items-center gap-0.5 rounded-md border border-border bg-muted p-0.75",line:"flex items-center gap-6 border-b border-border"}},defaultVariants:{variant:"segmented"}}),R=(0,S.cva)("group/tab inline-flex items-center justify-center gap-2 font-medium whitespace-nowrap text-muted-foreground transition-colors duration-(--duration-fast) outline-none hover:text-foreground focus-visible:outline-2 focus-visible:outline-ring data-active:text-foreground data-disabled:pointer-events-none data-disabled:opacity-45",{variants:{variant:{segmented:"h-7 gap-1.5 rounded-sm px-2.5 text-meta data-active:bg-card data-active:shadow-sm",line:"mb-[-1px] h-10 border-b-2 border-transparent px-0.5 text-body data-active:border-foreground"}},defaultVariants:{variant:"segmented"}});e.s(["Tabs",0,function({className:e,...n}){return(0,t.jsx)(y.Root,{"data-slot":"tabs",className:(0,C.classNames)("flex flex-col gap-4",e),...n})},"TabsContent",0,function({className:e,...n}){return(0,t.jsx)(y.Panel,{"data-slot":"tabs-content",className:(0,C.classNames)("outline-none",e),...n})},"TabsCount",0,function({className:e,...n}){return(0,t.jsx)("span",{"data-slot":"tabs-count",className:(0,C.classNames)("text-muted-foreground tabular-nums group-data-active/tab:text-foreground in-data-[variant=line]:inline-flex in-data-[variant=line]:size-5 in-data-[variant=line]:items-center in-data-[variant=line]:justify-center in-data-[variant=line]:rounded-full in-data-[variant=line]:bg-secondary in-data-[variant=line]:text-micro",e),...n})},"TabsList",0,function({className:e,variant:n="segmented",...r}){return(0,t.jsx)(y.List,{"data-slot":"tabs-list","data-variant":n,className:(0,C.classNames)(E({variant:n}),"max-sm:flex max-sm:w-full max-sm:gap-0.5 max-sm:rounded-lg max-sm:border max-sm:border-border max-sm:bg-muted max-sm:p-1",e),...r})},"TabsTrigger",0,function({className:e,variant:n="segmented",...r}){return(0,t.jsx)(y.Tab,{"data-slot":"tabs-trigger",className:(0,C.classNames)(R({variant:n}),"max-sm:h-(--size-control-touch) max-sm:flex-1 max-sm:rounded-md max-sm:border-0 max-sm:px-3 max-sm:text-body-touch max-sm:data-active:bg-card max-sm:data-active:shadow-sm",e),...r})}],60592)},67874,e=>{"use strict";var t=e.i(43476),n=e.i(90063);e.s(["EmptyState",0,function({title:e,description:r,icon:i,action:o,variant:s="page",className:a}){return"section"===s?(0,t.jsxs)("p",{"data-slot":"empty-state","data-variant":s,className:(0,n.classNames)("rounded-lg border border-border px-4 py-3 text-center text-meta text-muted-foreground",a),children:[e,r?(0,t.jsxs)(t.Fragment,{children:[" ",r]}):null]}):"no-results"===s?(0,t.jsxs)("div",{"data-slot":"empty-state","data-variant":s,className:(0,n.classNames)("flex flex-col items-center gap-2.5 rounded-lg border border-border bg-card px-4 py-6 text-center",a),children:[(0,t.jsx)("p",{className:"text-meta text-muted-foreground",children:e}),o]}):(0,t.jsxs)("div",{"data-slot":"empty-state","data-variant":s,className:(0,n.classNames)("flex flex-col items-center gap-3 rounded-lg border border-dashed border-border bg-card px-6 py-10 text-center",a),children:[i?(0,t.jsx)("span",{"aria-hidden":!0,className:"flex size-10 items-center justify-center rounded-lg border border-border bg-muted text-muted-foreground [&_svg]:size-(--size-icon-xl)",children:i}):null,(0,t.jsx)("h2",{className:"text-heading font-semibold text-foreground max-sm:text-heading-touch",children:e}),r?(0,t.jsx)("p",{className:"max-w-96 text-meta text-muted-foreground max-sm:text-body-touch",children:r}):null,o?(0,t.jsx)("div",{className:"mt-1 max-sm:w-full max-sm:[&>*]:w-full",children:o}):null]})}])},17981,25398,e=>{"use strict";var t=e.i(43476),n=e.i(22768),r=e.i(56420);let i={name:"cloud-off",size:24,node:[["path",{d:"M10.94 5.274A7 7 0 0 1 15.71 10h1.79a4.5 4.5 0 0 1 4.222 6.057",key:"1uxyv8"}],["path",{d:"M18.796 18.81A4.5 4.5 0 0 1 17.5 19H9A7 7 0 0 1 5.79 5.78",key:"99tcn7"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]};i.node;let o=(0,r.default)(i),s={name:"rotate-cw",size:24,node:[["path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8",key:"1p45f6"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}]]};s.node;let a=(0,r.default)(s);e.s(["RotateCw",0,a],25398);var l=e.i(90063),u=e.i(15905);e.s(["InlineError",0,function({title:e,description:r,detail:i,onRetry:s,retryNote:c,variant:d="section",id:f,className:p}){return"field"===d?(0,t.jsxs)("p",{id:f,"data-slot":"inline-error","data-variant":d,className:(0,l.classNames)("flex items-center gap-1.5 text-meta text-destructive-text [&_svg]:size-(--size-icon-sm) [&_svg]:shrink-0",p),children:[(0,t.jsx)(n.CircleAlert,{"aria-hidden":!0}),e]}):"section"===d?(0,t.jsxs)("div",{role:"alert","data-slot":"inline-error","data-variant":d,className:(0,l.classNames)("flex gap-2 rounded-lg border border-tone-attention-border bg-tone-attention-bg p-3 text-tone-attention-fg",p),children:[(0,t.jsx)(n.CircleAlert,{"aria-hidden":!0,className:"mt-0.5 size-(--size-icon) shrink-0"}),(0,t.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,t.jsx)("p",{className:"text-body font-medium",children:e}),r?(0,t.jsx)("p",{className:"text-meta text-foreground",children:r}):null,s?(0,t.jsx)(u.Button,{size:"xs",icon:(0,t.jsx)(a,{"aria-hidden":!0}),onClick:s,className:"self-start",children:"Try again"}):null]})]}):(0,t.jsxs)("div",{role:"alert","data-slot":"inline-error","data-variant":d,className:(0,l.classNames)("flex flex-col items-center gap-3 rounded-lg border border-border bg-card px-6 py-10 text-center",p),children:[(0,t.jsx)("span",{"aria-hidden":!0,className:"flex size-10 items-center justify-center rounded-lg border border-tone-attention-border bg-tone-attention-bg text-tone-attention-fg [&_svg]:size-(--size-icon-xl)",children:(0,t.jsx)(o,{})}),(0,t.jsx)("h2",{className:"text-heading font-semibold text-foreground max-sm:text-heading-touch",children:e}),r?(0,t.jsx)("p",{className:"max-w-96 text-meta text-muted-foreground max-sm:text-body-touch",children:r}):null,i?(0,t.jsx)("code",{className:"rounded-sm border border-border bg-muted px-2 py-0.5 font-mono text-id text-muted-foreground",children:i}):null,s?(0,t.jsxs)("div",{className:"flex items-center gap-2 max-sm:w-full max-sm:flex-col",children:[(0,t.jsx)(u.Button,{size:"sm",icon:(0,t.jsx)(a,{"aria-hidden":!0}),onClick:s,className:"max-sm:w-full",children:"Try again"}),c?(0,t.jsx)("span",{className:"text-meta text-muted-foreground",children:c}):null]}):null]})}],17981)},77435,66595,80799,40798,46150,65160,79652,e=>{"use strict";var t=e.i(43476),n=e.i(71028);e.s(["LimitNotice",0,function({title:e,description:r,accountUrl:i,testId:o}){return(0,t.jsxs)("div",{role:"status","data-testid":o,className:"flex gap-2 rounded-lg border border-tone-attention-border bg-tone-attention-bg p-3 text-tone-attention-fg",children:[(0,t.jsx)(n.Gauge,{"aria-hidden":!0,className:"mt-0.5 size-(--size-icon) shrink-0"}),(0,t.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,t.jsx)("p",{className:"text-body font-medium",children:e}),(0,t.jsx)("p",{className:"text-meta text-foreground",children:r}),void 0===i?null:(0,t.jsx)("a",{href:i,className:"self-start text-meta font-medium text-tone-attention-fg underline underline-offset-2","data-testid":void 0===o?void 0:`${o}-view`,children:"View limits"})]})]})}],77435);var r=e.i(56420);let i={name:"search",size:24,node:[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]]};i.node;let o=(0,r.default)(i);e.s(["Search",0,o],66595);let s={name:"tag",size:24,node:[["path",{d:"M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z",key:"vktsd0"}],["circle",{cx:"7.5",cy:"7.5",r:".5",fill:"currentColor",key:"kqv944"}]]};s.node;let a=(0,r.default)(s);e.s(["Tag",0,a],80799);let l={DEVICE:"Device",CLOUD:"Cloud",SERVER:"Server",OTHER:"Other"};e.s(["locationKindWord",0,function(e){return l[e]}],40798);let u="argo";e.s(["OPERATOR_NAME",0,u,"capitalised",0,function(e){return e.charAt(0).toUpperCase()+e.slice(1)},"counted",0,function(e,t){return`${String(e)} ${1===e?t.one:t.many}`},"ship",0,function(e){return{kind:"ship",party:e}},"text",0,function(e){return{kind:"text",text:e}}],46150),e.i(31627);var c=e.i(44827);let d=`Lowercase letters, digits, hyphens and colons, up to ${String(c.SHIP_HANDLE_MAX_LENGTH)} characters, unique among active ships.`;e.s(["asHandle",0,function(e){return e.toLowerCase()},"checkShipName",0,function(e,t){return""===e?{kind:"empty",message:d}:c.shipHandleSchema.safeParse(e).success?e===u?{kind:"reserved",message:`${u} is reserved for the operator ship.`}:e===t.current?{kind:"unchanged",message:"That is its name now."}:t.activeNames.includes(e)?{kind:"taken",message:`${e} is already used by an active ship.`}:{kind:"available",message:`${e} is available.`}:{kind:"invalid",message:`Use 1 to ${String(c.SHIP_HANDLE_MAX_LENGTH)} lowercase letters, digits, hyphens or colons.`}},"typeHint",0,function(e,t){let n=e.trim();return""===n?"Free text. Pick a type in use or write a new one.":0===t?`No ship uses this type yet. ${n} becomes a new type.`:1===t?"1 ship uses this type.":`${String(t)} ships use this type.`}],65160),e.s([],79652)},88393,e=>{"use strict";var t=e.i(43476),n=e.i(90063),r=e.i(19321);function i(e){return Array.from({length:e},(e,t)=>`row-${String(t)}`)}e.s(["LoadingSkeleton",0,function({variant:e,rows:o=4,label:s="Loading",className:a}){return(0,t.jsxs)("div",{role:"status","data-slot":"loading-skeleton","data-variant":e,className:(0,n.classNames)("w-full",a),children:[(0,t.jsx)("span",{className:"sr-only",children:s}),"table"===e?(0,t.jsxs)("div",{className:"overflow-hidden rounded-lg border border-border bg-card shadow-sm",children:[(0,t.jsx)("div",{className:"h-(--size-row-header) border-b border-border bg-muted"}),i(o).map(e=>(0,t.jsxs)("div",{className:"flex h-(--size-row) items-center gap-8 border-b border-border px-4 last:border-0",children:[(0,t.jsx)(r.Skeleton,{className:"h-2.5 w-24"}),(0,t.jsx)(r.Skeleton,{className:"h-5 w-16"}),(0,t.jsx)(r.Skeleton,{className:"h-5 w-20"}),(0,t.jsx)(r.Skeleton,{className:"h-2.5 w-28"})]},e))]}):null,"cards"===e?(0,t.jsx)("div",{className:"grid grid-cols-2 gap-3 lg:grid-cols-4",children:i(4).map(e=>(0,t.jsxs)("div",{className:"flex flex-col gap-3 rounded-lg border border-border bg-card p-4",children:[(0,t.jsx)(r.Skeleton,{className:"h-2.5 w-20"}),(0,t.jsx)(r.Skeleton,{className:"h-6 w-10"}),(0,t.jsx)(r.Skeleton,{className:"h-2.5 w-28"})]},e))}):null,"detail"===e?(0,t.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,t.jsx)(r.Skeleton,{className:"h-7 w-48"}),(0,t.jsxs)("div",{className:"flex gap-2",children:[(0,t.jsx)(r.Skeleton,{className:"h-5 w-20"}),(0,t.jsx)(r.Skeleton,{className:"h-5 w-16"})]}),(0,t.jsx)(r.Skeleton,{className:"h-16 w-full rounded-lg"})]}):null,"list"===e?(0,t.jsx)("div",{className:"overflow-hidden rounded-lg border border-border bg-card",children:i(o).map(e=>(0,t.jsxs)("div",{className:"flex flex-col gap-2.5 border-b border-border px-3.5 py-3 last:border-0",children:[(0,t.jsxs)("div",{className:"flex justify-between",children:[(0,t.jsx)(r.Skeleton,{className:"h-3 w-28"}),(0,t.jsx)(r.Skeleton,{className:"h-5 w-16"})]}),(0,t.jsx)(r.Skeleton,{className:"h-2.5 w-44"})]},e))}):null]})}])},78865,e=>{"use strict";var t=e.i(43476),n=e.i(87255),r=e.i(76561),i=e.i(47211),o=e.i(50092),s=e.i(85595),a=e.i(52886),l=e.i(26391),u=e.i(19647),c=e.i(16984),d=e.i(10001),f=e.i(71028),p=e.i(81658),m=e.i(85627),g=e.i(66787),h=e.i(92870),v=e.i(90063),b=e.i(66390);let x={waiting:"border-tone-waiting-border bg-tone-waiting-bg text-tone-waiting-fg",active:"border-tone-active-border bg-tone-active-bg text-tone-active-fg",ok:"border-tone-ok-border bg-tone-ok-bg text-tone-ok-fg",attention:"border-tone-attention-border bg-tone-attention-bg text-tone-attention-fg",ended:"border-tone-ended-border bg-tone-ended-bg text-tone-ended-fg"},y={awaitingCrew:{tone:"waiting",Icon:a.CircleDashed,label:"Awaiting crew"},crewed:{tone:"ok",Icon:h.UserCheck,label:"Crewed"},retired:{tone:"ended",Icon:r.Archive,label:"Retired"},pending:{tone:"waiting",Icon:p.Hourglass,label:"Pending"},delivered:{tone:"active",Icon:o.CircleArrowRight,label:"In flight"},acknowledged:{tone:"ok",Icon:s.CircleCheck,label:"Acknowledged"},undeliverable:{tone:"attention",Icon:c.CircleX,label:"Undeliverable"},dismissed:{tone:"ended",Icon:u.CircleMinus,label:"Dismissed"},abandoned:{tone:"ended",Icon:i.Ban,label:"Abandoned"},forming:{tone:"waiting",Icon:l.CircleDotDashed,label:"Forming"},sailing:{tone:"ok",Icon:m.Sailboat,label:"Sailing"},"standing-down":{tone:"active",Icon:n.Anchor,label:"Standing down"},disbanded:{tone:"ended",Icon:d.FlagOff,label:"Disbanded"},"at-limit":{tone:"waiting",Icon:f.Gauge,label:"At limit"},"over-limit":{tone:"attention",Icon:g.TriangleAlert,label:"Over limit"}};e.s(["StatusBadge",0,function({status:e,className:n}){let{tone:r,Icon:i,label:o}=y[e];return(0,t.jsxs)(b.Badge,{variant:"outline","data-slot":"status-badge","data-status":e,className:(0,v.classNames)(x[r],"abandoned"===e?"border-dashed":void 0,n),children:[(0,t.jsx)(i,{"aria-hidden":!0}),o]})},"statusLabel",0,function(e){return y[e].label}])},44824,36651,31071,90262,e=>{"use strict";var t=e.i(43476),n=e.i(71645),r=e.i(57497),i=e.i(5387),o=e.i(41880),s=e.i(49092),a=e.i(87600),l=e.i(16752);e.i(31627);var u=e.i(26006),c=e.i(30274),d=e.i(74470),f=e.i(15905),p=e.i(22212),m=e.i(94945),g=e.i(91727),h=e.i(43988),v=e.i(17981),b=e.i(77435),x=e.i(22768),y=e.i(66595),S=e.i(80799),C=e.i(40798),E=e.i(46150),R=e.i(65160),w=e.i(33173),I=e.i(60592),T=e.i(78865);let O=["ship","type"];function k(e){let{location:n}=e,r=null===n?null:n.description??(0,C.locationKindWord)(n.kind);return{value:e.id,label:e.name,detail:null===r?e.type:`${e.type} \xb7 ${r}`,trailing:(0,t.jsx)(T.StatusBadge,{status:e.status})}}let M={one:"ship",many:"ships"};function A(e,t){return e.filter(e=>e.type===t).length}function P({mode:e,onModeChange:r,value:i,onChange:o,ships:s,types:a,error:l}){let u=(0,n.useId)(),c=(0,n.useId)(),d=i?.kind==="type"?i.type:null,f=null===d?0:A(s,d);return(0,t.jsxs)("div",{"data-slot":"selector-picker",className:"flex flex-col gap-1.5",children:[(0,t.jsx)(g.Label,{htmlFor:u,children:"To"}),(0,t.jsx)(I.Tabs,{value:e,onValueChange:e=>{let t=O.find(t=>t===e);void 0!==t&&r(t)},children:(0,t.jsxs)(I.TabsList,{"aria-label":"Send to",className:"w-full",children:[(0,t.jsx)(I.TabsTrigger,{value:"ship","data-testid":"compose-mode-ship",className:"grow",children:"A specific ship"}),(0,t.jsx)(I.TabsTrigger,{value:"type","data-testid":"compose-mode-type",className:"grow",children:"Any ship of a type"})]})}),"ship"===e?(0,t.jsx)(w.Combobox,{id:u,options:s.map(k),value:i?.kind==="ship"?i.shipId:null,onValueChange:e=>{let t=s.find(t=>t.id===e);o(t?{kind:"ship",shipId:t.id}:null)},toQuery:R.asHandle,groupLabel:"Ships",emptyText:e=>`No ship matches "${e}". Retired ships are not listed.`,leadingIcon:(0,t.jsx)(y.Search,{}),placeholder:"Choose a ship",isInvalid:void 0!==l,"aria-describedby":c,"data-testid":"compose-ship"},"ship"):(0,t.jsx)(w.Combobox,{id:u,options:a.map(e=>({value:e,label:e,trailing:(0,t.jsx)("span",{className:"text-meta text-muted-foreground tabular-nums",children:(0,E.counted)(A(s,e),M)})})),value:d,onValueChange:e=>{o(null===e||""===e.trim()?null:{kind:"type",type:e.trim()})},isFreeText:!0,toQuery:R.asHandle,leadingIcon:(0,t.jsx)(S.Tag,{}),placeholder:"Type",isInvalid:void 0!==l,"aria-describedby":c,"data-testid":"compose-type"},"type"),void 0===l?(0,t.jsx)("p",{id:c,className:"text-meta text-muted-foreground",children:"ship"===e?"If the ship has no crew right now, the message waits in its inbox.":`Goes to a queue any ship of this type can claim from.${null===d?"":` ${(0,E.counted)(f,M)} ${1===f?"uses":"use"} this type.`}`}):(0,t.jsxs)("p",{id:c,role:"alert",className:"flex items-center gap-1.5 text-meta text-destructive [&_svg]:size-(--size-icon-sm)",children:[(0,t.jsx)(x.CircleAlert,{"aria-hidden":!0}),l]})]})}var N=e.i(90063);function j({className:e,...n}){return(0,t.jsx)("kbd",{"data-slot":"kbd",className:(0,N.classNames)("inline-flex h-5 min-w-5 shrink-0 items-center justify-center rounded-xs border border-border bg-muted px-1.25 font-sans text-micro font-medium text-muted-foreground max-sm:hidden",e),...n})}function L({platform:e}){return(0,t.jsx)(j,{"aria-hidden":!0,"data-testid":"send-shortcut-hint",className:"border-primary-foreground/25 bg-primary-foreground/10 text-primary-foreground",children:(0,d.sendShortcutKeys)(e)})}function D({ships:e,types:r,state:i,error:o,messageLimit:s,accountUrl:a,onSend:m,draft:x}){let y=(0,n.useId)(),S=(0,n.useId)(),[C,E]=(0,n.useState)(x?.selector.kind??"ship"),[R,w]=(0,n.useState)(x?.selector??null),[I,T]=(0,n.useState)(x?.payload??""),O=(0,u.payloadBytes)(I)>u.PAYLOAD_MAX_BYTES,k="sending"===i,M=null!==R&&""!==I.trim()&&!O&&!k,A=(0,d.useShortcutPlatform)();return(0,t.jsxs)("form",{className:"flex flex-col gap-4",onSubmit:e=>{e.preventDefault(),M&&m({selector:R,payload:I})},children:[(0,t.jsx)(P,{mode:C,onModeChange:e=>{E(e),w(null)},value:R,onChange:w,ships:e,types:r}),(0,t.jsxs)("div",{className:"flex flex-col gap-1.5",children:[(0,t.jsx)(g.Label,{htmlFor:y,children:"Message"}),(0,t.jsx)(h.Textarea,{id:y,isMono:!0,rows:6,value:I,onChange:e=>{T(e.target.value)},onKeyDown:d.submitOnSendShortcut,placeholder:"What the ship should do, and where the work lives","aria-invalid":O,"aria-describedby":O?S:void 0,"data-testid":"compose-payload"}),O?(0,t.jsx)(v.InlineError,{variant:"field",id:S,title:"A message is at most 64 KB. Send a reference to where the content lives."}):(0,t.jsx)("p",{className:"text-meta text-muted-foreground",children:"Sent as plain text from argo, stored before the fleet says OK."})]}),"failed"===i&&void 0!==s?(0,t.jsx)(b.LimitNotice,{...(0,l.composeRefusedNotice)(s),accountUrl:a,testId:"compose-message-limit"}):"failed"===i&&void 0!==o?(0,t.jsx)(v.InlineError,{title:"Couldn’t send the message",description:`${o} Nothing was sent; your message is kept here.`}):null,(0,t.jsxs)(p.DialogFooter,{children:[(0,t.jsx)(p.DialogClose,{render:(0,t.jsx)(f.Button,{disabled:k}),children:"Cancel"}),(0,t.jsxs)(f.Button,{type:"submit",variant:"primary",icon:(0,t.jsx)(c.Send,{"aria-hidden":!0}),disabled:!M&&!k,isLoading:k,"aria-keyshortcuts":null===A?void 0:(0,d.sendShortcutAria)(A),"data-testid":"compose-send",children:["Send",null===A?null:(0,t.jsx)(L,{platform:A})]})]})]})}function z({isOpen:e,onOpenChange:n,...r}){return(0,t.jsx)(p.Dialog,{open:e,onOpenChange:n,children:(0,t.jsxs)(p.DialogContent,{size:"md","data-testid":"compose-dialog",className:m.dialogSurface.phoneFullScreen,children:[(0,t.jsxs)(p.DialogHeader,{children:[(0,t.jsx)(p.DialogTitle,{children:"New message"}),(0,t.jsx)(p.DialogDescription,{children:"From argo. The ship receives it the next time its session asks for work."})]}),(0,t.jsx)(D,{...r})]})})}e.s(["Kbd",0,j],36651),e.s(["SendShortcutHint",0,L],31071),e.s(["ComposeMessage",0,function({isOpen:e,onOpenChange:u,replyTo:c,toShipId:d}){let f=(0,i.useFleetSnapshot)(),p=(0,r.useSendMessage)(),m=(0,s.useFleetLimits)(),g=(0,a.useHostedAccountUrl)(),[h,v]=(0,n.useState)(()=>crypto.randomUUID()),{ships:b,types:x}=(0,r.composeTargets)(f.data??[]);return(0,t.jsx)(z,{isOpen:e,onOpenChange:e=>{e||p.reset(),u(e)},ships:b,types:x,state:p.isPending?"sending":p.isError?"failed":"editing",error:p.error?.message,messageLimit:p.isError?(0,l.messageLimitReached)(m.data):void 0,accountUrl:g,draft:c?{selector:{kind:"ship",shipId:c.sender.id},payload:""}:d&&{selector:{kind:"ship",shipId:d},payload:""},onSend:e=>{p.mutate((0,r.sendInputOf)({...e,inReplyTo:c?.messageId},h),{onSuccess:()=>{v(crypto.randomUUID()),p.reset(),u(!1),(0,o.showToast)({title:"Message sent",description:"It waits in the inbox until a ship receives it.",tone:"success"})},onError:()=>{m.refetch()}})}})}],44824);var F=e.i(66027),H=e.i(27702);let V={canManage:!1,canSend:!1,canReceive:!1,isViewer:!1};e.s(["useAccess",0,function(){let e=(0,H.useTRPC)();return function(e){return void 0===e?V:{canManage:e.scopes.includes("fleet:manage"),canSend:e.scopes.includes("messages:send"),canReceive:e.scopes.includes("messages:receive"),isViewer:"viewer"===e.kind}}((0,F.useQuery)(e.console.session.queryOptions()).data)}],90262)},45608,19759,57443,47321,77155,58421,22646,94242,49237,50316,73752,44681,72135,46570,41225,21125,73336,63550,31157,e=>{"use strict";var t=e.i(43476),n=e.i(18566),r=e.i(71645),i=e.i(90262),o=e.i(76145),s=e.i(5387),a=e.i(86165),l=e.i(48695),u=e.i(84294),c=e.i(19191),d=e.i(77913),f=e.i(44594),p=e.i(77071),m=e.i(66595),g=e.i(60011),h=e.i(49287),v=e.i(56420);let b={name:"square-pen",size:24,node:[["path",{d:"M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7",key:"1m0v6g"}],["path",{d:"M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z",key:"ohrbg2"}]],aliases:["pen-box","edit","pen-square"]};b.node;let x=(0,v.default)(b);e.s(["SquarePen",0,x],19759);var y=e.i(66787);let S={name:"user-plus",size:24,node:[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["line",{x1:"19",x2:"19",y1:"8",y2:"14",key:"1bvyxn"}],["line",{x1:"22",x2:"16",y1:"11",y2:"11",key:"1shjgl"}]]};S.node;let C=(0,v.default)(S);e.s(["UserPlus",0,C],57443);let E={name:"waves-horizontal",size:24,node:[["path",{d:"M2 12q2.5 2 5 0t5 0 5 0 5 0",key:"8ddzzs"}],["path",{d:"M2 19q2.5 2 5 0t5 0 5 0 5 0",key:"1wj4st"}],["path",{d:"M2 5q2.5 2 5 0t5 0 5 0 5 0",key:"69x50u"}]],aliases:["waves"]};E.node;let R=(0,v.default)(E);e.s(["Waves",0,R],47321);var w=e.i(90063),I=e.i(94859),T=e.i(15905),O=e.i(22212),k=e.i(94945),M=e.i(36651),A=e.i(78865);let P={compose:x,commission:p.Plus,"form-squadron":p.Plus,overview:h.Ship,squadrons:g.Shapes,inbox:f.Inbox,attention:y.TriangleAlert};function N({item:e}){if("ship"===e.kind)return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(I.Avatar,{name:e.name,size:20}),(0,t.jsx)("span",{className:"min-w-0 truncate font-mono text-body font-medium text-foreground",children:e.name}),(0,t.jsx)("span",{className:"min-w-0 truncate text-meta text-muted-foreground",children:e.type}),(0,t.jsx)(A.StatusBadge,{status:e.status,className:"ml-auto"})]});if("squadron"===e.kind)return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(g.Shapes,{"aria-hidden":!0,className:"size-(--size-icon) shrink-0 text-muted-foreground"}),(0,t.jsx)("span",{className:"min-w-0 truncate text-body font-medium text-foreground",children:e.id}),(0,t.jsx)("span",{className:"min-w-0 truncate font-mono text-meta text-muted-foreground",children:e.blueprint}),(0,t.jsx)(A.StatusBadge,{status:e.state,className:"ml-auto"})]});if("blueprint"===e.kind)return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(d.DraftingCompass,{"aria-hidden":!0,className:"size-(--size-icon) shrink-0 text-muted-foreground"}),(0,t.jsx)("span",{className:"min-w-0 truncate font-mono text-body text-foreground",children:e.name}),(0,t.jsxs)("span",{className:"text-meta text-muted-foreground",children:["v",e.version]})]});if("squadron-action"===e.kind){let n="add-member"===e.action?C:R;return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(n,{"aria-hidden":!0,className:"size-(--size-icon) shrink-0 text-muted-foreground"}),(0,t.jsx)("span",{className:"min-w-0 truncate",children:e.label})]})}let n=P[e.id];return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(n,{"aria-hidden":!0,className:"size-(--size-icon) shrink-0 text-muted-foreground"}),(0,t.jsx)("span",{className:"min-w-0 truncate",children:e.label})]})}function j({items:e,onSelect:n,onOpenChange:i,initialQuery:s=""}){let a=(0,r.useId)(),l=(0,r.useId)(),[u,d]=(0,r.useState)(s),[f,p]=(0,r.useState)(0),g=(0,o.paletteGroups)(e,u),h=g.flatMap(e=>e.items),v=h[Math.min(f,h.length-1)],b=e=>`${l}-${(0,o.paletteKeyOf)(e)}`,x=e=>{n(e),i(!1)};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(O.DialogTitle,{className:"sr-only",children:"Search ships or jump to"}),(0,t.jsxs)("div",{className:"flex h-12 items-center gap-2.5 border-b border-border px-4 max-sm:h-(--size-header)",children:[(0,t.jsx)(m.Search,{"aria-hidden":!0,className:"size-(--size-icon) shrink-0 text-muted-foreground"}),(0,t.jsx)("input",{role:"combobox","aria-expanded":!0,"aria-controls":a,"aria-activedescendant":v?b(v):void 0,"aria-autocomplete":"list","aria-label":"Search ships or jump to",autoComplete:"off",autoCapitalize:"off",spellCheck:!1,placeholder:"Search ships or jump to","data-testid":"command-palette-input",className:"h-full min-w-0 grow bg-transparent text-body text-foreground outline-none placeholder:text-muted-foreground max-sm:text-body-touch",value:u,onChange:e=>{d(e.target.value),p(0)},onKeyDown:e=>{if(0!==h.length)if("ArrowDown"===e.key||"ArrowUp"===e.key){e.preventDefault();let t="ArrowDown"===e.key?1:-1;p(((v?h.indexOf(v):0)+t+h.length)%h.length)}else"Enter"===e.key&&v&&(e.preventDefault(),x(v))}}),(0,t.jsx)(M.Kbd,{children:"esc"}),(0,t.jsx)(O.DialogClose,{render:(0,t.jsx)(T.Button,{variant:"ghost",size:"sm",className:"sm:hidden"}),children:"Cancel"})]}),(0,t.jsx)("div",{className:"max-h-[min(60dvh,var(--spacing)*100)] overflow-y-auto p-2 max-sm:max-h-none max-sm:grow",children:0===h.length?(0,t.jsxs)("p",{className:"px-4 py-6 text-center text-meta text-muted-foreground",children:["Nothing matches “",u.trim(),"”. Ships are found by name or type; retired ships are not listed."]}):(0,t.jsx)("ul",{id:a,role:"listbox","aria-label":"Results",className:"flex flex-col gap-2",children:g.map(e=>(0,t.jsxs)("li",{role:"presentation",className:"flex flex-col gap-0.5",children:[(0,t.jsx)("p",{id:`${a}-${e.key}`,className:"px-2.5 pt-1 pb-0.5 text-caption font-medium text-muted-foreground",children:e.label}),(0,t.jsx)("ul",{role:"group","aria-labelledby":`${a}-${e.key}`,className:"flex flex-col gap-0.5",children:e.items.map(e=>{let n=e===v;return(0,t.jsx)("li",{id:b(e),role:"option","aria-selected":n,"data-testid":"command-palette-item","data-item-kind":e.kind,"data-item-id":e.id,className:(0,w.classNames)("flex h-(--size-control) cursor-pointer items-center gap-2.5 rounded-md px-2.5 text-body text-foreground max-sm:h-(--size-control-touch)",n?"bg-accent":void 0),onPointerMove:()=>{p(h.indexOf(e))},onClick:()=>{x(e)},children:(0,t.jsx)(N,{item:e})},(0,o.paletteKeyOf)(e))})})]},e.key))})}),(0,t.jsxs)("div",{className:"flex items-center gap-3 border-t border-border px-4 py-2 text-caption text-muted-foreground max-sm:hidden",children:[(0,t.jsxs)("span",{className:"inline-flex items-center gap-1",children:[(0,t.jsx)(M.Kbd,{children:"↑"}),(0,t.jsx)(M.Kbd,{children:"↓"}),"Move"]}),(0,t.jsxs)("span",{className:"inline-flex items-center gap-1",children:[(0,t.jsx)(M.Kbd,{children:(0,t.jsx)(c.CornerDownLeft,{"aria-hidden":!0,className:"size-3"})}),"Open"]}),(0,t.jsxs)("span",{className:"inline-flex items-center gap-1",children:[(0,t.jsx)(M.Kbd,{children:"esc"}),"Close"]})]})]})}function L({isOpen:e,onOpenChange:n,...r}){return(0,t.jsx)(O.Dialog,{open:e,onOpenChange:n,children:(0,t.jsx)(O.DialogContent,{size:"md","data-testid":"command-palette",className:(0,w.classNames)("gap-0 p-0 sm:top-[12dvh] sm:translate-y-0",k.dialogSurface.phoneFullScreen,"max-sm:flex max-sm:flex-col"),children:(0,t.jsx)(j,{onOpenChange:n,...r})})})}e.s(["ConsoleCommands",0,function({isOpen:e,onOpenChange:c,onCompose:d}){let f=(0,n.useRouter)(),p=(0,s.useFleetSnapshot)(),m=(0,a.useHasSquadrons)(),g=(0,l.useSquadrons)(),h=(0,l.useCatalogue)(),v=(0,i.useAccess)();return(0,r.useEffect)(()=>{let e=e=>{(e.metaKey||e.ctrlKey)&&"k"===e.key.toLowerCase()&&(e.preventDefault(),c(!0))};return document.addEventListener("keydown",e),()=>{document.removeEventListener("keydown",e)}},[c]),(0,t.jsx)(L,{isOpen:e,onOpenChange:c,items:(0,o.allowedPaletteItems)((0,o.paletteItemsOf)(p.data??[],m?{squadrons:g.data??[],blueprints:(0,u.blueprintChoices)(h.data??{blueprints:[]})}:void 0),v),onSelect:e=>{switch(e.kind){case"ship":case"page":case"squadron":case"squadron-action":case"blueprint":f.push(e.href);return;case"action":"compose"===e.id?d():"form-squadron"===e.id?f.push("/squadrons?form=new"):f.push("/?commission=new")}}})}],45608);var D=e.i(54616),z=e.i(66027),F=e.i(12598),H=e.i(41880),V=e.i(32150),_=e.i(27702);function B(e){return e.split(/[?#]/)[0]??e}function q(e){let t=new MutationObserver(e);return t.observe(document.body,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["class","hidden","style"]}),window.addEventListener("resize",e),()=>{t.disconnect(),window.removeEventListener("resize",e)}}e.s(["useConsoleGuide",0,function(){let e=(0,_.useTRPC)(),t=(0,n.useRouter)(),r=(0,n.usePathname)(),i=(0,F.useQueryClient)(),o=(0,z.useQuery)(e.console.guide.queryOptions()),s=e.console.guide.queryKey(),a=(0,D.useMutation)(e.console.recordGuideProgress.mutationOptions({onMutate:e=>{i.setQueryData(s,t=>t?{...t,progress:e}:t)},onError:()=>{(0,H.showToast)({title:"Couldn’t keep your place in the tour",description:"The server did not answer. Try again.",tone:"error"})},onSettled:()=>i.invalidateQueries({queryKey:s})})),{track:l}=(0,V.useAnalytics)(),u=o.data?.steps??[],c=o.data?.progress.step??0,d=function(e){if(e?.progress.state!=="open")return;let t=e.steps[e.progress.step];return void 0===t?void 0:{step:t,index:e.progress.step,total:e.steps.length}}(o.data??void 0),f=e=>{a.mutate(e);let n=u[e.step];"open"===e.state&&void 0!==n&&B(n.path)!==r&&t.push(n.path)},p=e=>{f({step:e,state:"open"}),l({name:"tour_step_reached",step:e+1,total:u.length})};return{view:d,onBack:()=>{p(Math.max(c-1,0))},onNext:()=>{p(Math.min(c+1,u.length-1))},onSkip:()=>{f({step:c,state:"skipped"}),l({name:"tour_skipped",step:c+1})},onFinish:()=>{f({step:c,state:"finished"}),l({name:"tour_finished"})},onTakeTour:0===u.length?void 0:()=>{f({step:0,state:"open"})}}},"useGuideAnchor",0,function(e){let t=(0,n.usePathname)(),i=e?void 0!==e.anchor&&B(e.path)===t?`[data-testid="${e.anchor}"]`:void 0:void 0;return(0,r.useSyncExternalStore)(q,()=>void 0===i?null:[...document.querySelectorAll(i)].find(e=>e.getClientRects().length>0)??null,()=>null)},"useTourStarted",0,function(e){let{track:t}=(0,V.useAnalytics)(),n=(0,r.useRef)(!1),i=void 0!==e,o=e?.index===0;(0,r.useEffect)(()=>{i&&!n.current&&o&&t({name:"tour_started"}),n.current=i},[i,o,t])}],77155),e.s([],58421);var W=e.i(96499),$=e.i(17989),U=e.i(46420),K=e.i(33332);let G=r.createContext(void 0);function Y(e){let t=r.useContext(G);if(void 0===t&&!e)throw Error((0,K.default)(47));return t}e.s(["PopoverRootContext",0,G,"usePopoverRootContext",0,Y],22646);var Q=e.i(74080),X=e.i(26352),J=e.i(39957),Z=e.i(56789),ee=e.i(56434),et=e.i(18478),en=e.i(64111),er=e.i(16786),ei=e.i(90627),eo=e.i(38396);let es={...er.popupStoreSelectors,disabled:e=>e.disabled,instantType:e=>e.instantType,openMethod:e=>e.openMethod,openChangeReason:e=>e.openChangeReason,modal:e=>e.modal,focusManagerModal:e=>e.focusManagerModal,stickIfOpen:e=>e.stickIfOpen,titleElementId:e=>e.titleElementId,descriptionElementId:e=>e.descriptionElementId,openOnHover:e=>e.openOnHover,closeDelay:e=>e.closeDelay,adaptiveOrigin:e=>e.adaptiveOrigin};class ea extends X.ReactStore{constructor(e,t,n){const r=new ei.PopupTriggerMap;super(el(e,r,t,n),eu(r),es)}setOpen=(e,t)=>{let n,r=t.reason===ee.REASONS.triggerHover,i=t.reason===ee.REASONS.triggerPress&&0===t.event.detail,o=!e&&(t.reason===ee.REASONS.escapeKey||null==t.reason),s=(0,en.attachPreventUnmountOnClose)(t),a=this.select("activeTriggerId");if(e||t.reason!==ee.REASONS.closePress||null!=t.trigger||null==a||(t.trigger=this.context.triggerElements.getById(a)??this.select("activeTriggerElement")??void 0),this.context.onOpenChange?.(e,t),t.isCanceled)return;this.state.floatingRootContext.dispatchOpenChange(e,t);let l=()=>{let n=(0,en.createPopupOpenState)(this.state,e,t.trigger,s());n.openChangeReason=t.reason,this.update(n)};r?(this.set("stickIfOpen",!0),this.context.stickIfOpenTimeout.start(eo.PATIENT_CLICK_THRESHOLD,()=>{this.set("stickIfOpen",!1)}),Q.flushSync(l)):l(),i?n="click":o?n="dismiss":t.reason===ee.REASONS.focusOut&&(n="focus"),this.set("instantType",n)}}function el(e,t,n,r=!1){let i={...(0,er.createInitialPopupStoreState)(t,n,r),disabled:!1,modal:!1,focusManagerModal:!1,instantType:void 0,openMethod:null,openChangeReason:null,titleElementId:void 0,descriptionElementId:void 0,stickIfOpen:!0,openOnHover:!1,closeDelay:0,adaptiveOrigin:void 0,...e};return i.open&&e?.mounted===void 0&&(i.mounted=!0),i}function eu(e){return{popupRef:r.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerFocusTargetRef:r.createRef(),beforeContentFocusGuardRef:r.createRef(),stickIfOpenTimeout:new J.Timeout,triggerElements:e}}e.s(["PopoverStore",0,ea,"createNullPopoverStore",0,function(){let e=new ei.PopupTriggerMap;return Object.assign(new et.NullStore(Object.freeze(el(void 0,e)),Object.freeze(eu(e)),es),{setOpen:Z.NOOP})}],94242);var ec=e.i(75606);let ed=(0,W.fastComponent)(function({props:e}){var n;let i,{children:o,open:s,defaultOpen:a=!1,onOpenChange:l,onOpenChangeComplete:u,modal:c=!1,handle:d,triggerId:f,defaultTriggerId:p=null}=e,m=(n={modal:c,open:a,openProp:s,activeTriggerId:p,triggerIdProp:f},i=(0,en.usePopupRootStore)((e,t)=>new ea(n,e,t)),r.useEffect(()=>i.context.stickIfOpenTimeout.disposeEffect(),[i]),i);m.useControlledProp("openProp",s),m.useControlledProp("triggerIdProp",f);let g=m.useState("open"),h=m.useState("mounted"),v=m.useState("payload");m.useContextCallback("onOpenChange",l),m.useContextCallback("onOpenChangeComplete",u),(0,en.usePopupRootSync)(m,g),(0,en.useImplicitActiveTrigger)(m);let{forceUnmount:b}=(0,en.useOpenStateTransitions)(g,m,()=>{m.update({stickIfOpen:!0,openChangeReason:null})});m.useSyncedValues({modal:c}),r.useEffect(()=>{g||m.context.stickIfOpenTimeout.clear()},[m,g]),r.useImperativeHandle(e.actionsRef,()=>({unmount:b,close:()=>m.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.imperativeAction))}),[b,m]);let x=g||h;return(0,t.jsxs)(G.Provider,{value:m,children:[d&&(0,t.jsx)(en.PopupHandleAttachment,{handle:d,store:m}),x&&(0,t.jsx)(ef,{store:m,modal:c}),"function"==typeof o?o({payload:v}):o]})});function ef({store:e,modal:t}){let n=e.useState("floatingRootContext"),r=(0,$.useDismiss)(n,{outsidePressEvent:{mouse:"trap-focus"===t?"sloppy":"intentional",touch:"sloppy"}}),i=r.reference,o=r.floating;return(0,en.usePopupInteractionProps)(e,{activeTriggerProps:i,inactiveTriggerProps:i,popupProps:o}),null}e.s(["PopoverRoot",0,function(e){return Y(!0)?(0,t.jsx)(ed,{props:e}):(0,t.jsx)(U.FloatingTree,{children:(0,t.jsx)(ed,{props:e})})}],49237);var ep=e.i(40886),em=e.i(79938),eg=e.i(52245),eh=e.i(29315),ev=e.i(84446),eb=e.i(58408);let ex=.1*.1;function ey(e,t,n,r,i,o){return r>=t!=o>=t&&e<=(i-n)*(t-r)/(o-r)+n}function eS(e,t,n,r,i,o,s,a,l,u){let c=!1;return ey(e,t,n,r,i,o)&&(c=!c),ey(e,t,i,o,s,a)&&(c=!c),ey(e,t,s,a,l,u)&&(c=!c),ey(e,t,l,u,n,r)&&(c=!c),c}function eC(e,t,n,r,i,o){let s=Math.min(n,i),a=Math.max(n,i),l=Math.min(r,o),u=Math.max(r,o);return e>=s&&e<=a&&t>=l&&t<=u}function eE(e={}){let{blockPointerEvents:t=!1}=e,n=new J.Timeout,r=({x:e,y:t,placement:r,elements:i,onClose:o,nodeId:s,tree:a})=>{let l=r?.split("-")[0],u=!1,c=null,d=null,f="u">typeof performance?performance.now():0;return function(r){n.clear();let p=i.domReference,m=i.floating;if(!p||!m||null==l||null==e||null==t)return;let{clientX:g,clientY:h}=r,v=(0,ev.getTarget)(r),b="mouseleave"===r.type,x=(0,ev.contains)(m,v),y=(0,ev.contains)(p,v);if(x&&(u=!0,!b))return;if(y&&(u=!1,!b)){u=!0;return}if(b&&(0,eh.isElement)(r.relatedTarget)&&(0,ev.contains)(m,r.relatedTarget))return;function S(){return!!(a&&(0,eb.getNodeChildren)(a.nodesRef.current,s).length>0)}function C(){S()||(n.clear(),o())}if(S())return;let E=p.getBoundingClientRect(),R=m.getBoundingClientRect(),w=e>R.right-R.width/2,I=t>R.bottom-R.height/2,T=R.width>E.width,O=R.height>E.height,k=(T?E:R).left,M=(T?E:R).right,A=(O?E:R).top,P=(O?E:R).bottom;if("top"===l&&t>=E.bottom-1||"bottom"===l&&t<=E.top+1||"left"===l&&e>=E.right-1||"right"===l&&e<=E.left+1)return void C();let N=!1;switch(l){case"top":N=eC(g,h,k,E.top+1,M,R.bottom-1);break;case"bottom":N=eC(g,h,k,R.top+1,M,E.bottom-1);break;case"left":N=eC(g,h,R.right-1,P,E.left+1,A);break;case"right":N=eC(g,h,E.right-1,P,R.left+1,A)}if(N)return;if(u&&(!(g>=E.x)||!(g<=E.x+E.width)||!(h>=E.y)||!(h<=E.y+E.height))||!b&&function(e,t){let n=performance.now(),r=n-f;if(null===c||null===d||0===r)return c=e,d=t,f=n,!1;let i=e-c,o=t-d;return c=e,d=t,f=n,i*i+o*o<r*r*ex}(g,h))return void C();let j=!1;switch(l){case"top":{let n=T?.25:2,r=t+.5+1,i=w||T?R.bottom-.5:R.top,o=w?T?R.bottom-.5:R.top:R.bottom-.5;j=eS(g,h,T||w?e+n:e-n,r,T?e-n:w?e+n:e-n,r,R.left,i,R.right,o);break}case"bottom":{let n=T?.25:2,r=t-.5,i=w||T?R.top+.5:R.bottom,o=w?T?R.top+.5:R.bottom:R.top+.5;j=eS(g,h,T||w?e+n:e-n,r,T?e-n:w?e+n:e-n,r,R.left,i,R.right,o);break}case"left":{let n=O?.25:2,r=e+.5+1,i=I||O?R.right-.5:R.left,o=I?O?R.right-.5:R.left:R.right-.5;j=eS(g,h,i,R.top,o,R.bottom,r,O||I?t+n:t-n,r,O?t-n:I?t+n:t-n);break}case"right":{let n=O?.25:2,r=e-.5,i=I||O?R.left+.5:R.right,o=I?O?R.left+.5:R.right:R.left+.5;j=eS(g,h,r,O||I?t+n:t-n,r,O?t-n:I?t+n:t-n,i,R.top,o,R.bottom)}}j?u||n.start(40,C):C()}};return r.__options={...e,blockPointerEvents:t},r}e.s(["safePolygon",0,eE],50316);var eR=e.i(85689),ew=e.i(74735),eI=e.i(65420),eT=e.i(8868),eO=e.i(67865),ek=e.i(46265),eM=e.i(57940),eA=e.i(26300),eP=e.i(88940),eN=e.i(96296);class ej{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new J.Timeout,this.restTimeout=new J.Timeout,this.handleCloseOptions=void 0}static create(){return new ej}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose}let eL=new WeakMap;function eD(e){if(!e.performedPointerEventsMutation)return;let t=e.pointerEventsScopeElement;t&&eL.get(t)===e&&(e.pointerEventsScopeElement?.style.removeProperty("pointer-events"),e.pointerEventsReferenceElement?.style.removeProperty("pointer-events"),e.pointerEventsFloatingElement?.style.removeProperty("pointer-events"),eL.delete(t)),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null}function ez(e,t){let{scopeElement:n,referenceElement:r,floatingElement:i}=t,o=eL.get(n);o&&o!==e&&eD(o),eD(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=n,e.pointerEventsReferenceElement=r,e.pointerEventsFloatingElement=i,eL.set(n,e),n.style.pointerEvents="none",r.style.pointerEvents="auto",i.style.pointerEvents="auto"}function eF(e){let t=e.context.dataRef.current,n=(0,eP.useRefWithInit)(()=>t.hoverInteractionState??ej.create()).current;return t.hoverInteractionState||(t.hoverInteractionState=n),(0,eA.useOnMount)(t.hoverInteractionState.disposeEffect),t.hoverInteractionState}function eH(e,t,n){let r=null==n||(0,eM.isMouseLikePointerType)(n)?"function"==typeof e?e():e:0;return"number"==typeof r?r:r?.[t]}function eV(e){return"function"==typeof e?e():e}function e_(e,t){return t||"click"===e||"mousedown"===e}function eB(e){return e?.includes("mouse")&&"mousedown"!==e}e.s(["applySafePolygonPointerEventsMutation",0,ez,"clearSafePolygonPointerEventsMutation",0,eD,"useHoverInteractionSharedState",0,eF],73752),e.s(["getDelay",0,eH,"getRestMs",0,eV,"isClickLikeOpenEvent",0,e_,"isHoverOpenEvent",0,eB],44681);var eq=eN;let eW={current:null};function e$(e,t={}){let{enabled:n=!0,delay:i=0,handleClose:o=null,mouseOnly:s=!1,restMs:a=0,move:l=!0,triggerElementRef:u=eW,externalTree:c,isActiveTrigger:d=!0,getHandleCloseContext:f,isClosing:p,shouldOpen:m,guardStaleOpen:g=!1}=t,h="rootStore"in e?e.rootStore:e,{dataRef:v,events:b}=h.context,x=(0,U.useFloatingTree)(c),y=eF(h),S=r.useRef(!1),C=(0,ek.useValueAsRef)(o),E=(0,ek.useValueAsRef)(i),R=(0,ek.useValueAsRef)(a),w=(0,ek.useValueAsRef)(n),I=(0,ek.useValueAsRef)(m),T=(0,ek.useValueAsRef)(p),O=(0,eO.useStableCallback)(()=>e_(v.current.openEvent?.type,y.interactedInside)),k=(0,eO.useStableCallback)(()=>I.current?.()!==!1),M=(0,eO.useStableCallback)((e,t,n)=>{let r=h.context.triggerElements;return r.hasElement(t)?!e||!(0,ev.contains)(e,t):!!(0,eh.isElement)(n)&&r.hasMatchingElement(e=>(0,ev.contains)(e,n))&&(!e||!(0,ev.contains)(e,n))}),A=(0,eO.useStableCallback)(()=>{y.handler&&((0,eT.ownerDocument)(h.select("domReferenceElement")).removeEventListener("mousemove",y.handler),y.handler=void 0)}),P=(0,eO.useStableCallback)(()=>{eD(y)});return d&&(y.handleCloseOptions=o?.__options),r.useEffect(()=>A,[A]),r.useEffect(()=>{if(n)return b.on("openchange",e),()=>{b.off("openchange",e)};function e(e){e.open?S.current=!1:(S.current=e.reason===ee.REASONS.triggerHover,A(),y.openChangeTimeout.clear(),y.restTimeout.clear(),y.blockMouseMove=!0,y.restTimeoutPending=!1)}},[n,b,y,A]),r.useEffect(()=>{if(!n)return;function e(t,n=!0){let r=eH(E.current,"close",y.pointerType);r?y.openChangeTimeout.start(r,()=>{h.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,t)),x?.events.emit("floating.closed",t)}):n&&(y.openChangeTimeout.clear(),h.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,t)),x?.events.emit("floating.closed",t))}let t=u.current??(d?h.select("domReferenceElement"):null);if(!(0,eh.isElement)(t))return;function r(e){if(y.openChangeTimeout.clear(),y.blockMouseMove=!1,s&&!(0,eM.isMouseLikePointerType)(y.pointerType))return;let t=eV(R.current),n=eH(E.current,"open",y.pointerType),r=(0,ev.getTarget)(e),i=e.currentTarget??null,o=h.select("domReferenceElement"),a=i;if((0,eh.isElement)(r)&&!h.context.triggerElements.hasElement(r)){for(let e of h.context.triggerElements.elements())if((0,ev.contains)(e,r)){a=e;break}}(0,eh.isElement)(i)&&(0,eh.isElement)(o)&&!h.context.triggerElements.hasElement(i)&&(0,ev.contains)(i,o)&&(a=o);let l=null!=a&&M(o,a,r),u=h.select("open"),c=T.current?.()??"ending"===h.select("transitionStatus"),d=!u&&c&&S.current,f=!l&&(0,eh.isElement)(a)&&(0,eh.isElement)(o)&&(0,ev.contains)(o,a)&&d,p=t>0&&!n,m=!u||l;if(l&&(u||d)||f){k()&&h.setOpen(!0,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,e,a));return}!p&&(n?y.openChangeTimeout.start(n,()=>{m&&k()&&h.setOpen(!0,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,e,a))}):m&&k()&&h.setOpen(!0,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,e,a)))}function i(t){if(O())return void P();A();let n=h.select("domReferenceElement"),r=(0,eT.ownerDocument)(n);y.restTimeout.clear(),y.restTimeoutPending=!1;let i=v.current.floatingContext??f?.();if(!(0,eq.isTargetInsideEnabledTrigger)(t.relatedTarget,h.context.triggerElements)){if(C.current&&i){h.select("open")||y.openChangeTimeout.clear();let n=u.current;y.handler=C.current({...i,tree:x,x:t.clientX,y:t.clientY,onClose(){P(),A(),w.current&&!O()&&n===h.select("domReferenceElement")&&e(t,!0)}}),r.addEventListener("mousemove",y.handler),y.handler(t);return}"touch"===y.pointerType&&(0,ev.contains)(h.select("floatingElement"),t.relatedTarget)||e(t)}}let o=g?(0,ew.addEventListener)(t,"mouseout",function(e){(0,ev.contains)(t,e.relatedTarget)||(y.openChangeTimeout.clear(),y.restTimeout.clear(),y.restTimeoutPending=!1)}):void 0;return l?(0,eI.mergeCleanups)((0,ew.addEventListener)(t,"mousemove",r,{once:!0}),(0,ew.addEventListener)(t,"mouseenter",r),(0,ew.addEventListener)(t,"mouseleave",i),o):(0,eI.mergeCleanups)((0,ew.addEventListener)(t,"mouseenter",r),(0,ew.addEventListener)(t,"mouseleave",i),o)},[A,P,v,E,h,n,C,y,d,M,O,s,l,R,u,x,w,f,T,k,g]),r.useMemo(()=>{if(n)return{onPointerDown:e,onPointerEnter:e,onMouseMove(e){let{nativeEvent:t}=e,n=e.currentTarget,r=h.select("domReferenceElement"),i=h.select("open"),o=M(r,n,e.target);if(s&&!(0,eM.isMouseLikePointerType)(y.pointerType))return;if(i&&o&&y.handleCloseOptions?.blockPointerEvents){let e=h.select("floatingElement");if(e){let t=y.handleCloseOptions?.getScope?.()??n.ownerDocument.body;ez(y,{scopeElement:t,referenceElement:n,floatingElement:e})}}let a=eV(R.current);function l(){if(y.restTimeoutPending=!1,O())return;let e=h.select("open");!y.blockMouseMove&&(!e||o)&&k()&&h.setOpen(!0,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,t,n))}(!i||o)&&0!==a&&(!o&&y.restTimeoutPending&&e.movementX**2+e.movementY**2<2||(y.restTimeout.clear(),"touch"===y.pointerType?Q.flushSync(()=>{l()}):o&&i?l():(y.restTimeoutPending=!0,y.restTimeout.start(a,l))))}};function e(e){y.pointerType=e.pointerType}},[n,y,O,M,s,h,R,k])}e.s(["useHoverReferenceInteraction",0,e$],72135);var eU=e.i(88015),eK=e.i(52535),eG=e.i(59636),eY=e.i(83976);function eQ(e,t){let n=r.useRef(null);return{preFocusGuardRef:n,handlePreFocusGuardFocus:function(t){Q.flushSync(()=>{e.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.focusOut,t.nativeEvent,t.currentTarget))});let r=(0,eY.getTabbableBeforeElement)(n.current);r?.focus()},handleFocusTargetFocus:function(n){let r=e.select("positionerElement");if(r&&(0,eY.isOutsideEvent)(n,r))e.context.beforeContentFocusGuardRef.current?.focus();else{Q.flushSync(()=>{e.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.focusOut,n.nativeEvent,n.currentTarget))});let i=(0,eY.getTabbableAfterElement)(e.context.triggerFocusTargetRef.current||t.current);for(;null!==i&&(0,ev.contains)(r,i);){let e=i;if((i=(0,eY.getNextTabbable)(i))===e)break}i?.focus()}}}}e.s(["useTriggerFocusGuards",0,eQ],46570);var eX=e.i(32199);let eJ=(0,W.fastComponentRef)(function(e,n){let{render:i,className:o,style:s,disabled:a=!1,nativeButton:l=!0,handle:u,payload:c,openOnHover:d=!1,delay:f=300,closeDelay:p=0,id:m,...g}=e,h=Y(!0),v=(0,eG.usePopupHandleStore)(u)??h;if(!v)throw Error((0,K.default)(74));let b=(0,eU.useBaseUiId)(m),x=v.useState("isTriggerActive",b),y=v.useState("floatingRootContext"),S=v.useState("isOpenedByTrigger",b),C=v.useState("triggerPopupId",b),E=r.useRef(null),{registerTrigger:R,isMountedByThisTrigger:w}=(0,en.useTriggerDataForwarding)(b,E,v,{payload:c,disabled:a,openOnHover:d,closeDelay:p}),I=v.useState("openChangeReason"),T=v.useState("stickIfOpen"),O=v.useState("openMethod"),k=v.useState("focusManagerModal"),M=e$(y,{enabled:!a&&d&&("touch"!==O||I!==ee.REASONS.triggerPress),mouseOnly:!0,move:!1,handleClose:eE(),restMs:f,delay:{close:p},triggerElementRef:E,isActiveTrigger:x,isClosing:()=>"ending"===v.select("transitionStatus")}),A=(0,eR.useClick)(y,{stickIfOpen:T}),P=(0,eX.useOpenMethodTriggerProps)(()=>v.select("open"),e=>{v.set("openMethod",e)}),N=v.useState("triggerProps",w),{getButtonProps:j,buttonRef:L}=(0,ep.useButton)({disabled:a,native:l}),{preFocusGuardRef:D,handlePreFocusGuardFocus:z,handleFocusTargetFocus:F}=eQ(v,E),H=(0,eg.useRenderElement)("button",e,{state:{disabled:a,open:S},ref:[L,n,R,E],props:[A.reference,M,N,P,{[eo.CLICK_TRIGGER_IDENTIFIER]:"",id:b,"aria-haspopup":"dialog","aria-expanded":S,"aria-controls":C},g,j],stateAttributesMapping:{open:e=>e&&I===ee.REASONS.triggerPress?em.pressableTriggerOpenStateMapping.open(e):em.triggerOpenStateMapping.open(e)}}),V=(0,t.jsx)(r.Fragment,{children:H},b);return w&&!k?(0,t.jsxs)(r.Fragment,{children:[(0,t.jsx)(eK.FocusGuard,{ref:D,onFocus:z}),V,(0,t.jsx)(eK.FocusGuard,{ref:v.context.triggerFocusTargetRef,onFocus:F})]}):V});e.s(["PopoverTrigger",0,eJ],41225);var eZ=e.i(26674);let e0=r.createContext(void 0),e1=r.forwardRef(function(e,n){let{keepMounted:r=!1,...i}=e;return Y().useState("mounted")||r?(0,t.jsx)(e0.Provider,{value:r,children:(0,t.jsx)(eZ.FloatingPortal,{ref:n,...i})}):null});e.s(["PopoverPortal",0,e1],21125);var e4=e.i(44394),e2=e.i(46376);let e6=r.createContext(void 0);e.s(["PopoverPositionerContext",0,e6,"usePopoverPositionerContext",0,function(){let e=r.useContext(e6);if(!e)throw Error((0,K.default)(46));return e}],73336);var e5=e.i(23706),e7=e.i(426),e3=e.i(22640),e8=e.i(89579),e9=e.i(33383);let te=r.forwardRef(function(e,n){let{render:i,className:o,style:s,anchor:a,positionMethod:l,side:u,align:c,sideOffset:d,alignOffset:f,collisionBoundary:p="clipping-ancestors",collisionPadding:m,arrowPadding:g,sticky:h,disableAnchorTracking:v=!1,collisionAvoidance:b=eo.POPUP_COLLISION_AVOIDANCE,...x}=e,y=Y(),S=function(){let e=r.useContext(e0);if(void 0===e)throw Error((0,K.default)(45));return e}(),C=(0,U.useFloatingNodeId)(),E=y.useState("floatingRootContext"),R=y.useState("mounted"),w=y.useState("open"),I=y.useState("openChangeReason"),T=y.useState("activeTriggerElement"),O=y.useState("modal"),k=y.useState("openMethod"),M=y.useState("positionerElement"),A=y.useState("instantType"),P=y.useState("transitionStatus"),N=y.useState("adaptiveOrigin"),j=r.useRef(null),L=(0,e3.useAnimationsFinished)(M),D=(0,e5.useAnchorPositioning)({anchor:a,floatingRootContext:E,positionMethod:l,mounted:R,side:u,sideOffset:d,align:c,alignOffset:f,arrowPadding:g,collisionBoundary:p,collisionPadding:m,sticky:h,disableAnchorTracking:v,keepMounted:S,nodeId:C,collisionAvoidance:b,adaptiveOrigin:N}),z=E.useState("domReferenceElement");(0,e2.useIsoLayoutEffect)(()=>{let e=j.current;if(z&&(j.current=z),e&&z&&z!==e){y.set("instantType",void 0);let e=new AbortController;return L(()=>{y.set("instantType","trigger-change")},e.signal),()=>{e.abort()}}},[z,L,y]);let F=!0===O&&I!==ee.REASONS.triggerHover;(0,e9.useAnchoredPopupScrollLock)(w&&F,"touch"===k,M,T);let H=y.useStateSetter("positionerElement"),V={open:w,side:D.side,align:D.align,anchorHidden:D.anchorHidden,instant:A},_=(0,e8.usePositioner)(e,V,{styles:D.positionerStyles,transitionStatus:P,props:x,refs:[n,H],hidden:!R,inert:!w});return(0,t.jsxs)(e6.Provider,{value:D,children:[R&&F&&(0,t.jsx)(e7.InternalBackdrop,{inert:(0,e4.inertValue)(!w),cutout:T}),(0,t.jsx)(U.FloatingNode,{id:C,children:_})]})});e.s(["PopoverPositioner",0,te],63550);var eq=eN;e.s(["useHoverFloatingInteraction",0,function(e,t={}){let{enabled:n=!0,closeDelay:i=0,nodeId:o}=t,s="rootStore"in e?e.rootStore:e,a=s.useState("open"),l=s.useState("floatingElement"),u=s.useState("domReferenceElement"),{dataRef:c}=s.context,d=(0,U.useFloatingTree)(),f=(0,U.useFloatingParentNodeId)(),p=eF(s),m=(0,J.useTimeout)(),g=(0,eO.useStableCallback)(()=>e_(c.current.openEvent?.type,p.interactedInside)),h=(0,eO.useStableCallback)(()=>eB(c.current.openEvent?.type)),v=(0,eO.useStableCallback)(()=>{eD(p)});(0,e2.useIsoLayoutEffect)(()=>{a||(p.pointerType=void 0,p.restTimeoutPending=!1,p.interactedInside=!1,v())},[a,p,v]),r.useEffect(()=>v,[v]),(0,e2.useIsoLayoutEffect)(()=>{if(n&&a&&p.handleCloseOptions?.blockPointerEvents&&h()&&(0,eh.isElement)(u)&&l){let e=(0,eT.ownerDocument)(l),t=d?.nodesRef.current.find(e=>e.id===f)?.context?.elements.floating;t&&(t.style.pointerEvents="");let n=p.pointerEventsScopeElement!==l?p.pointerEventsScopeElement:null,r=t!==l?t:null,i=p.handleCloseOptions?.getScope?.()??n??r??u.closest("[data-rootownerid]")??e.body;return ez(p,{scopeElement:i,referenceElement:u,floatingElement:l}),()=>{v()}}},[n,a,u,l,p,h,d,f,v]),r.useEffect(()=>{if(n)return(0,eI.mergeCleanups)(l&&(0,ew.addEventListener)(l,"mouseenter",function(){p.openChangeTimeout.clear(),m.clear(),d?.events.off("floating.closed",t),v()}),l&&(0,ew.addEventListener)(l,"mouseleave",function(n){if(e()&&d)return void d.events.on("floating.closed",t);if((0,eq.isTargetInsideEnabledTrigger)(n.relatedTarget,s.context.triggerElements))return;let r=c.current.floatingContext?.nodeId??o,a=n.relatedTarget;if(!(d&&r&&(0,eh.isElement)(a)&&(0,eb.getNodeChildren)(d.nodesRef.current,r,!1).some(e=>(0,ev.contains)(e.context?.elements.floating,a)))){let e,t;if(p.handler)return void p.handler(n);v(),h()&&!g()&&(e=eH(i,"close",p.pointerType),t=()=>{s.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,n)),d?.events.emit("floating.closed",n)},e?p.openChangeTimeout.start(e,t):(p.openChangeTimeout.clear(),t()))}}),l&&(0,ew.addEventListener)(l,"pointerdown",function(e){let t=(0,ev.getTarget)(e);if(!(0,eN.isInteractiveElement)(t)){p.interactedInside=!1;return}p.interactedInside=t?.closest("[aria-haspopup]")!=null},!0),()=>{d?.events.off("floating.closed",t)});function e(){return!!(d&&f&&(0,eb.getNodeChildren)(d.nodesRef.current,f).length>0)}function t(n){!d||!f||e()||m.start(0,()=>{d.events.off("floating.closed",t),s.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,n)),d.events.emit("floating.closed",n)})}},[n,l,s,c,i,o,h,g,v,p,d,f,m])}],31157)},95475,18390,2767,e=>{"use strict";var t=e.i(43476),n=e.i(77155),r=e.i(15905);e.i(58421);var i=e.i(49237),o=e.i(41225),s=e.i(21125),a=e.i(63550),l=e.i(92235),u=e.i(10913),c=e.i(64493),d=e.i(69153),f=e.i(40370),p=e.i(89244),m=e.i(71645),g=e.i(22646),h=e.i(73336),v=e.i(52245),b=e.i(74080),x=e.i(44394),y=e.i(8445),S=e.i(94258),C=e.i(46376),E=e.i(67865),R=e.i(8868),w=e.i(22640),I=e.i(56789),T=e.i(73364);let O="--popup-width",k="--popup-height";var M=e.i(67387);function A(e,t,n){let r=e.style.getPropertyValue(t);return e.style.setProperty(t,n),()=>{e.style.setProperty(t,r)}}function P(e,t){let n=[];for(let[r,i]of Object.entries(t))n.push(A(e,r,i));return n.length?()=>{n.forEach(e=>e())}:I.NOOP}function N(e,t){let n="auto"===t?"auto":`${t.width}px`,r="auto"===t?"auto":`${t.height}px`;e.style.setProperty(O,n),e.style.setProperty(k,r)}function j(e,t){let n="max-content"===t?"max-content":`${t.width}px`,r="max-content"===t?"max-content":`${t.height}px`;e.style.setProperty(M.positionerWidth,n),e.style.setProperty(M.positionerHeight,r)}var L=e.i(72855),D=e.i(33848),z=e.i(43084),F=e.i(9091);let H={name:"adaptiveOrigin",async fn(e){let{x:t,y:n,rects:{floating:r},elements:{floating:i},platform:o,strategy:s,placement:a}=e,l=(0,D.ownerWindow)(i),u=l.getComputedStyle(i);if("0s"===u.transitionDuration||""===u.transitionDuration)return{x:t,y:n,data:F.DEFAULT_SIDES};let c=await o.getOffsetParent?.(i),d={width:0,height:0};if("fixed"===s&&l?.visualViewport)d={width:l.visualViewport.width,height:l.visualViewport.height};else if(c===l){let e=(0,R.ownerDocument)(i);d={width:e.documentElement.clientWidth,height:e.documentElement.clientHeight}}else await o.isElement?.(c)&&(d=await o.getDimensions(c));let f=(0,z.getSide)(a),p=t,m=n;return"left"===f&&(p=d.width-(t+r.width)),"top"===f&&(m=d.height-(n+r.height)),{x:p,y:m,data:{sideX:"left"===f?"right":F.DEFAULT_SIDES.sideX,sideY:"top"===f?"bottom":F.DEFAULT_SIDES.sideY}}}},V={activationDirection:e=>e?{"data-activation-direction":e}:null};function _(e){let n,{store:r,side:i,children:o}=e,s=(0,L.useDirection)(),a=r.useState("activeTriggerElement"),l=r.useState("activeTriggerId"),u=r.useState("open"),c=r.useState("payload"),d=r.useState("mounted"),f=r.useState("popupElement"),p=r.useState("positionerElement"),g=(0,S.usePreviousValue)(u?a:null),h=function(e,t){let[n,r]=m.useState(0),i=m.useRef(e),o=m.useRef(t),s=m.useRef(!1);return(0,C.useIsoLayoutEffect)(()=>{let n=i.current,a=t!==o.current;e!==n?(r(e=>e+1),s.current=!a):s.current&&a&&(r(e=>e+1),s.current=!1),i.current=e,o.current=t},[e,t]),`${e??"current"}-${n}`}(l,c),v=m.useRef(null),[D,z]=m.useState(null),[F,V]=m.useState(null),_=m.useRef(null),B=m.useRef(null),q=(0,w.useAnimationsFinished)(_,!0),W=(0,y.useAnimationFrame)(),$=m.useRef(null),[U,K]=m.useState(null),[G,Y]=m.useState(!1);(0,C.useIsoLayoutEffect)(()=>(r.set("adaptiveOrigin",H),()=>{r.set("adaptiveOrigin",void 0)}),[r]);let Q=(0,E.useStableCallback)(()=>{_.current?.style.setProperty("animation","none"),_.current?.style.setProperty("transition","none"),B.current?.style.setProperty("display","none")}),X=(0,E.useStableCallback)(e=>{_.current?.style.removeProperty("animation"),_.current?.style.removeProperty("transition"),B.current?.style.removeProperty("display"),e&&K(e)}),J=(0,E.useStableCallback)(()=>{$.current?.abort();let e=new AbortController;$.current=e,q(()=>{z(null),K(null),v.current=null},e.signal)}),Z=m.useRef(null);(0,C.useIsoLayoutEffect)(()=>{u&&d||(Z.current=null)},[u,d]),(0,C.useIsoLayoutEffect)(()=>{var e,t;let n,r,i,o;a&&g&&a!==g&&Z.current!==a&&v.current&&(z(v.current),Y(!0),V((e=g,t=a,n=e.getBoundingClientRect(),r=t.getBoundingClientRect(),i={x:n.left+n.width/2,y:n.top+n.height/2},{horizontal:(o={x:r.left+r.width/2,y:r.top+r.height/2}).x-i.x,vertical:o.y-i.y})),Z.current=a)},[a,g]),(0,C.useIsoLayoutEffect)(()=>{null!=D&&($.current?.abort(),Y(!0),W.request(()=>{b.flushSync(()=>{Y(!1)}),J()}))},[h,D,J,W]),(0,C.useIsoLayoutEffect)(()=>{let e=_.current;if(!e)return;let t=(0,R.ownerDocument)(e).createElement("div");for(let n of Array.from(e.childNodes))t.appendChild(n.cloneNode(!0));v.current=t});let ee=null!=D;return n=ee?(0,t.jsxs)(m.Fragment,{children:[(0,t.jsx)("div",{"data-previous":!0,inert:(0,x.inertValue)(!0),ref:B,style:{...U?{[O]:`${U.width}px`,[k]:`${U.height}px`}:null,position:"absolute"},"data-ending-style":G?void 0:""},"previous"),(0,t.jsx)("div",{"data-current":!0,ref:_,"data-starting-style":G?"":void 0,children:o},h)]}):(0,t.jsx)("div",{"data-current":!0,ref:_,children:o},h),(0,C.useIsoLayoutEffect)(()=>{let e=B.current;e&&D&&e.replaceChildren(...Array.from(D.childNodes))},[D]),!function(e){let{popupElement:t,positionerElement:n,content:r,mounted:i,onMeasureLayout:o,onMeasureLayoutComplete:s,side:a,direction:l}=e,u=(0,w.useAnimationsFinished)(t,!0),c=(0,y.useAnimationFrame)(),d=m.useRef(null),f=m.useRef(!0),p=m.useRef(I.NOOP),g=(0,E.useStableCallback)(o),h=(0,E.useStableCallback)(s),v=m.useMemo(()=>{var e,t;let n,r;return e=a,t=l,n="top"===e,r="left"===e||e===("rtl"===t?"inline-end":"inline-start"),n||r?{position:"absolute",[n?"bottom":"top"]:"0",[r?"right":"left"]:"0"}:I.EMPTY_OBJECT},[a,l]);(0,C.useIsoLayoutEffect)(()=>{if(!i){p.current=I.NOOP,f.current=!0,d.current=null;return}if(!t||!n)return;p.current=P(t,v),N(t,"auto");let e=A(t,"position","static"),r=A(t,"transform","none"),o=A(t,"scale","1"),s=P(n,{[M.availableWidth]:"max-content",[M.availableHeight]:"max-content"});function a(){e(),r(),s(),o()}if(g?.(),f.current||null===d.current){j(n,"max-content");let e=(0,T.getCssDimensions)(t);return d.current=e,j(n,e),a(),h?.(null,e),f.current=!1,()=>{p.current(),p.current=I.NOOP}}j(n,"max-content");let l=d.current,m=(0,T.getCssDimensions)(t);d.current=m,N(t,l),a(),h?.(l,m),j(n,m);let b=new AbortController;return c.request(()=>{N(t,m),u(()=>{t.style.setProperty(O,"auto"),t.style.setProperty(k,"auto")},b.signal)}),()=>{b.abort(),c.cancel(),p.current(),p.current=I.NOOP}},[r,t,n,u,c,i,g,h,v])}({popupElement:f,positionerElement:p,mounted:d,content:c,onMeasureLayout:Q,onMeasureLayoutComplete:X,side:i,direction:s}),{children:n,state:{activationDirection:function(e){if(e)return`${function(e,t,n,r){return e>t?n:e<-t?r:""}(e.horizontal,5,"right","left")} ${function(e,t,n,r){return e>t?n:e<-t?r:""}(e.vertical,5,"down","up")}`}(F),transitioning:ee}}}e.s(["popupViewportStateMapping",0,V,"usePopupViewport",0,_],18390);let B=m.forwardRef(function(e,t){let{render:n,className:r,style:i,children:o,...s}=e,a=(0,g.usePopoverRootContext)(),{side:l}=(0,h.usePopoverPositionerContext)(),u=a.useState("instantType"),{children:c,state:d}=_({store:a,side:l,children:o}),f={activationDirection:d.activationDirection,transitioning:d.transitioning,instant:u};return(0,v.useRenderElement)("div",e,{state:f,ref:t,props:[s,{children:c}],stateAttributesMapping:V})});var q=e.i(94242),W=e.i(64170);class $ extends W.BasePopupHandle{constructor(){super((0,q.createNullPopoverStore)(),"Popover")}open(e){this.openByTrigger(e)}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}}e.s(["Arrow",()=>u.PopoverArrow,"Backdrop",()=>c.PopoverBackdrop,"Close",()=>p.PopoverClose,"Description",()=>f.PopoverDescription,"Handle",0,$,"Popup",()=>l.PopoverPopup,"Portal",()=>s.PopoverPortal,"Positioner",()=>a.PopoverPositioner,"Root",()=>i.PopoverRoot,"Title",()=>d.PopoverTitle,"Trigger",()=>o.PopoverTrigger,"Viewport",0,B,"createHandle",0,function(){return new $}],66914);var U=e.i(66914),U=U,K=e.i(90063);function G(e){return(0,t.jsx)(U.Root,{"data-slot":"popover",...e})}function Y({className:e,children:n,anchor:r,side:i="bottom",sideOffset:o=10,align:s="center",...a}){return(0,t.jsx)(U.Portal,{children:(0,t.jsx)(U.Positioner,{anchor:r,align:s,side:i,sideOffset:o,className:"isolate z-50",children:(0,t.jsxs)(U.Popup,{"data-slot":"popover-content",className:(0,K.classNames)("origin-(--transform-origin) rounded-xl border border-border bg-popover text-popover-foreground shadow-lg duration-(--duration-fast) outline-none data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",e),...a,children:[(0,t.jsx)(U.Arrow,{className:"data-[side=bottom]:-top-1.5 data-[side=left]:-right-1.5 data-[side=right]:-left-1.5 data-[side=top]:-bottom-1.5",children:(0,t.jsx)("span",{"aria-hidden":!0,className:"block size-3 rotate-45 border-t border-l border-border bg-popover in-data-[side=left]:rotate-135 in-data-[side=right]:-rotate-45 in-data-[side=top]:-rotate-135"})}),n]})})})}let Q=U.Title,X=U.Description;function J({index:e,total:n,onBack:i,onNext:o,onSkip:s,onFinish:a,children:l}){let u=e===n-1;return(0,t.jsxs)("div",{className:"flex w-80 max-w-[calc(100vw-2rem)] flex-col gap-2 p-4",children:[(0,t.jsxs)("p",{className:"text-caption text-muted-foreground","data-testid":"tour-step-count",children:[e+1," of ",n]}),l,(0,t.jsxs)("div",{className:"mt-2 flex items-center gap-2",children:[u?null:(0,t.jsx)(r.Button,{size:"sm",variant:"ghost","data-testid":"tour-step-skip",onClick:s,children:"Skip"}),(0,t.jsx)("span",{className:"grow"}),0===e?null:(0,t.jsx)(r.Button,{size:"sm","data-testid":"tour-step-back",onClick:i,children:"Back"}),u?(0,t.jsx)(r.Button,{size:"sm",variant:"primary","data-testid":"tour-step-finish",onClick:a,children:"Finish"}):(0,t.jsx)(r.Button,{size:"sm",variant:"primary","data-testid":"tour-step-next",onClick:o,children:"Next"})]})]})}function Z(e){let{title:n,text:r,anchor:i}=e;return null===i?(0,t.jsx)("div",{role:"dialog","aria-labelledby":"tour-step-title","aria-describedby":"tour-step-text","data-testid":"tour-step","data-placement":"centred",className:"fixed top-1/2 left-1/2 z-50 -translate-1/2 rounded-xl border border-border bg-popover text-popover-foreground shadow-lg",children:(0,t.jsxs)(J,{...e,children:[(0,t.jsx)("h2",{id:"tour-step-title",className:"text-body font-semibold text-foreground",children:n}),(0,t.jsx)("p",{id:"tour-step-text",className:"text-body text-muted-foreground",children:r})]})}):(0,t.jsx)(G,{open:!0,modal:!1,children:(0,t.jsx)(Y,{anchor:i,"data-testid":"tour-step","data-placement":"anchored",children:(0,t.jsxs)(J,{...e,children:[(0,t.jsx)(Q,{className:"text-body font-semibold text-foreground",children:n}),(0,t.jsx)(X,{className:"text-body text-muted-foreground",children:r})]})})})}e.s(["ConsoleGuide",0,function(){let{view:e,onBack:r,onNext:i,onSkip:o,onFinish:s}=(0,n.useConsoleGuide)(),a=(0,n.useGuideAnchor)(e?.step);return((0,n.useTourStarted)(e),e)?(0,t.jsx)(Z,{title:e.step.title,text:e.step.text,index:e.index,total:e.total,anchor:a,onBack:r,onNext:i,onSkip:o,onFinish:s}):null}],95475);var ee=e.i(10818),et=e.i(14387),et=et;function en({notice:e,onDismiss:n,onSignOut:i}){return(0,t.jsxs)("div",{role:"status","data-testid":"notice","data-notice-id":e.id,className:"flex items-start gap-2 border-b border-border bg-muted px-8 py-2.5 max-sm:px-4",children:[(0,t.jsx)(ee.Info,{"aria-hidden":!0,className:"mt-0.5 size-(--size-icon) shrink-0 text-muted-foreground"}),(0,t.jsxs)("div",{className:"flex min-w-0 grow flex-wrap items-baseline gap-x-3 gap-y-1",children:[(0,t.jsx)("p",{className:"text-meta text-foreground",children:e.text}),e.links.map(e=>!0===e.isSignOut?(0,t.jsx)("button",{type:"button","data-testid":"notice-link",className:"text-meta font-medium text-foreground underline underline-offset-2",onClick:()=>i?.(e),children:e.label},e.label):(0,t.jsx)("a",{href:e.url,"data-testid":"notice-link",className:"text-meta font-medium text-foreground underline underline-offset-2",children:e.label},e.label))]}),e.isDismissible&&n?(0,t.jsx)(r.Button,{variant:"ghost",size:"xs",isIconOnly:!0,"aria-label":"Dismiss","data-testid":"notice-dismiss",onClick:n,children:(0,t.jsx)(et.default,{"aria-hidden":!0})}):null]})}var er=e.i(54616),ei=e.i(66027),eo=e.i(12598),es=e.i(18566),ea=e.i(41880),el=e.i(27702);e.s(["ConsoleNotices",0,function(){let e,n,r,i,o,s,{notices:a,onDismiss:l,onSignOut:u}=(e=(0,el.useTRPC)(),n=(0,es.useRouter)(),r=(0,eo.useQueryClient)(),i=(0,ei.useQuery)(e.console.notices.queryOptions()),o=(0,er.useMutation)(e.console.dismissNotice.mutationOptions({onSuccess:()=>r.invalidateQueries({queryKey:e.console.notices.queryKey()}),onError:()=>{(0,ea.showToast)({title:"Couldn’t dismiss the notice",description:"The server did not answer. Try again.",tone:"error"})}})),s=(0,er.useMutation)(e.console.signOut.mutationOptions({onError:()=>{(0,ea.showToast)({title:"Couldn’t sign out",description:"The server did not answer. You are still signed in.",tone:"error"})}})),{notices:i.data??[],onDismiss:e=>{o.mutate({noticeId:e})},onSignOut:e=>{s.mutate(void 0,{onSuccess:()=>{r.clear();let t=e.url??"/sign-in";t.startsWith("/")?n.replace(t):window.location.assign(t)}})}});return 0===a.length?null:(0,t.jsx)("div",{"data-testid":"notices",children:a.map(e=>(0,t.jsx)(en,{notice:e,onDismiss:()=>{l(e.id)},onSignOut:u},e.id))})}],2767)},77880,24262,83140,66794,31513,63707,8619,28276,91772,e=>{"use strict";var t=e.i(43476),n=e.i(67927),r=e.i(66595),i=e.i(19759),o=e.i(22016),s=e.i(15905),a=e.i(36651),l=e.i(90063);let u={live:{label:"Live",dot:"bg-tone-ok-fg"},reconnecting:{label:"Reconnecting",dot:"bg-tone-waiting-fg"},offline:{label:"Offline",dot:"bg-tone-attention-fg"}};function c({state:e,className:n}){let{label:r,dot:i}=u[e];return(0,t.jsxs)("span",{"data-slot":"live-status","data-state":e,"aria-live":"polite",className:(0,l.classNames)("inline-flex items-center gap-1.5 text-meta text-muted-foreground",n),children:[(0,t.jsx)("span",{"aria-hidden":!0,className:(0,l.classNames)("size-2 shrink-0 rounded-full",i)}),r]})}e.s(["LiveStatus",0,c],24262),e.s(["Header",0,function({breadcrumb:e,parents:l=[],live:u,onCompose:d,onSearch:f}){return(0,t.jsxs)("header",{"data-slot":"header",className:"sticky top-0 z-30 hidden h-(--size-header) shrink-0 items-center justify-between gap-4 border-b border-border bg-background px-6 sm:flex",children:[(0,t.jsx)("nav",{"aria-label":"Breadcrumb","data-testid":"header-breadcrumb",className:"min-w-0 text-body",children:(0,t.jsxs)("ol",{className:"flex min-w-0 items-center gap-1.5",children:[l.map(e=>(0,t.jsxs)("li",{className:"flex shrink-0 items-center gap-1.5",children:[(0,t.jsx)(o.default,{href:e.href,className:"text-muted-foreground hover:text-foreground hover:underline",children:e.label}),(0,t.jsx)(n.ChevronRight,{"aria-hidden":!0,className:"size-3.5 text-muted-foreground"})]},e.href)),(0,t.jsx)("li",{"aria-current":"page",className:"truncate font-medium text-foreground",children:e})]})}),(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)(c,{state:u}),f?(0,t.jsxs)(s.Button,{size:"sm",icon:(0,t.jsx)(r.Search,{"aria-hidden":!0}),"data-testid":"header-search",className:"w-60 justify-start font-normal text-muted-foreground",onClick:f,children:[(0,t.jsx)("span",{className:"grow text-left",children:"Search ships or jump to"}),(0,t.jsx)(a.Kbd,{children:"⌘K"})]}):null,d?(0,t.jsx)(s.Button,{size:"sm",icon:(0,t.jsx)(i.SquarePen,{"aria-hidden":!0}),"data-testid":"header-compose",onClick:d,children:"Compose"}):null]})]})}],77880);var d=e.i(56420);let f={name:"code-xml",size:24,node:[["path",{d:"m18 16 4-4-4-4",key:"1inbqp"}],["path",{d:"m6 8-4 4 4 4",key:"15zrgr"}],["path",{d:"m14.5 4-5 16",key:"e7oirm"}]],aliases:["code-2"]};f.node;let p=(0,d.default)(f);e.s(["CodeXml",0,p],83140);let m={name:"settings",size:24,node:[["path",{d:"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",key:"1i5ecw"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]};m.node;let g=(0,d.default)(m);e.s(["Settings",0,g],66794),e.s(["SOURCE_URL",0,"https://github.com/ThomasHendrickx/aeolus-fleet"],31513);let h={name:"chevrons-up-down",size:24,node:[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]]};h.node;let v=(0,d.default)(h);e.s(["ChevronsUpDown",0,v],63707);let b={name:"circle-user-round",size:24,node:[["path",{d:"M17.925 20.056a6 6 0 0 0-11.851.001",key:"z69sun"}],["circle",{cx:"12",cy:"11",r:"4",key:"1gt34v"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],aliases:["user-circle-2"]};b.node;let x=(0,d.default)(b);e.s(["CircleUserRound",0,x],8619);let y={name:"compass",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m16.24 7.76-1.804 5.411a2 2 0 0 1-1.265 1.265L7.76 16.24l1.804-5.411a2 2 0 0 1 1.265-1.265z",key:"9ktpf1"}]]};y.node;let S=(0,d.default)(y);e.s(["Compass",0,S],28276);let C={name:"laptop-minimal",size:24,node:[["rect",{width:"18",height:"12",x:"3",y:"4",rx:"2",ry:"2",key:"1qhy41"}],["line",{x1:"2",x2:"22",y1:"20",y2:"20",key:"ni3hll"}]],aliases:["laptop-2"]};C.node;let E=(0,d.default)(C);e.s(["LaptopMinimal",0,E],91772)},36779,57957,15034,e=>{"use strict";var t=e.i(43476),n=e.i(83140),r=e.i(44594),i=e.i(66794),o=e.i(60011),s=e.i(49287),a=e.i(66787),l=e.i(22016),u=e.i(94859),c=e.i(66390),d=e.i(31513),f=e.i(63707),p=e.i(8619),m=e.i(28276),g=e.i(91772),h=e.i(11568),v=e.i(67784),b=e.i(46513),x=e.i(96699),y=e.i(35965),S=e.i(71645),C=e.i(90063),E=e.i(18162),R=e.i(68404),w=e.i(15905),I=e.i(57334),T=e.i(75305),O=e.i(60592);let k="Your account",M="Take the tour",A={light:y.Sun,dark:x.Moon,system:b.Monitor};function P(e){return e?.kind==="viewer"?{name:"viewer",detail:"Read-only"}:{name:"Operator",detail:e?.email??" "}}function N(e){return e?.kind!=="viewer"}function j(e){return R.THEMES.some(t=>t===e)}function L({account:e,now:n}){let{name:r,detail:i}=P(e);return(0,t.jsxs)("div",{className:"flex flex-col gap-2 px-2.5 pt-2 pb-2.5",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2.5",children:[(0,t.jsx)(u.Avatar,{kind:"account",size:28,name:r}),(0,t.jsxs)("span",{className:"flex min-w-0 flex-col",children:[(0,t.jsx)("span",{className:"truncate text-body font-medium text-foreground",children:r}),(0,t.jsx)("span",{"data-testid":"account-detail",className:"truncate text-caption text-muted-foreground",children:e?.kind==="viewer"?"Sees the whole fleet, changes nothing":i})]})]}),(0,t.jsxs)("p",{"data-testid":"account-session",className:"flex items-start gap-1.5 text-caption text-muted-foreground",children:[(0,t.jsx)(g.LaptopMinimal,{"aria-hidden":!0,className:"mt-px size-(--size-icon-sm) shrink-0"}),e?(0,t.jsxs)("span",{children:["This session: ",(0,t.jsx)("span",{className:"font-medium text-foreground",children:(0,E.sessionSince)(e.session,n)})]}):(0,t.jsx)("span",{children:"This session"})]})]})}function D({isSigningOut:e}){return e?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(h.LoaderCircle,{"aria-hidden":!0,className:"animate-spin motion-reduce:animate-none"}),"Signing out"]}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(v.LogOut,{"aria-hidden":!0}),"Sign out"]})}function z({account:e,onThemeChange:n,onSignOut:r,isSigningOut:i,now:o,accountUrl:s,onTakeTour:a}){let{name:l,detail:c}=P(e),d=e?.kind==="operator"?e.theme:void 0;return(0,t.jsxs)(I.DropdownMenu,{children:[(0,t.jsxs)(I.DropdownMenuTrigger,{"data-testid":"account-menu","aria-label":`Account menu, ${l}${e?`, ${c}`:""}`,className:"flex w-full items-center gap-2.5 rounded-md p-1.5 text-left transition-colors duration-(--duration-fast) outline-none hover:bg-accent focus-visible:outline-2 focus-visible:outline-ring aria-expanded:bg-accent max-lg:justify-center",children:[(0,t.jsx)(u.Avatar,{kind:"account",size:28,name:l}),(0,t.jsxs)("span",{className:"flex min-w-0 grow flex-col max-lg:sr-only",children:[(0,t.jsx)("span",{className:"truncate text-body font-medium text-foreground",children:l}),(0,t.jsx)("span",{className:"truncate text-caption text-muted-foreground",children:c})]}),(0,t.jsx)(f.ChevronsUpDown,{"aria-hidden":!0,className:"size-(--size-icon) shrink-0 text-muted-foreground max-lg:hidden"})]}),(0,t.jsxs)(I.DropdownMenuContent,{side:"top",align:"start",className:"w-64",children:[(0,t.jsx)(L,{account:e,now:o}),void 0===s||e?.kind==="viewer"?null:(0,t.jsxs)(I.DropdownMenuItem,{"data-testid":"account-hosted",render:e=>(0,t.jsx)("a",{...e,href:s,children:e.children}),children:[(0,t.jsx)(p.CircleUserRound,{"aria-hidden":!0}),k]}),void 0===a?null:(0,t.jsxs)(I.DropdownMenuItem,{"data-testid":"account-take-tour",onClick:a,children:[(0,t.jsx)(m.Compass,{"aria-hidden":!0}),M]}),N(e)&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(I.DropdownMenuSeparator,{}),(0,t.jsxs)(I.DropdownMenuGroup,{children:[(0,t.jsx)(I.DropdownMenuLabel,{children:"Theme"}),(0,t.jsx)(I.DropdownMenuRadioGroup,{value:d,onValueChange:e=>{j(e)&&n(e)},children:R.THEMES.map(n=>{let r=A[n];return(0,t.jsxs)(I.DropdownMenuRadioItem,{value:n,disabled:void 0===e,closeOnClick:!1,"data-testid":`account-theme-${n}`,children:[(0,t.jsx)(r,{"aria-hidden":!0}),E.THEME_LABELS[n]]},n)})})]})]}),(0,t.jsx)(I.DropdownMenuSeparator,{}),(0,t.jsx)(I.DropdownMenuItem,{"data-testid":"account-sign-out",disabled:i,closeOnClick:!1,onClick:r,children:(0,t.jsx)(D,{isSigningOut:i})})]})]})}e.s(["AccountMenu",0,z,"AccountMenuSheet",0,function({account:e,onThemeChange:r,onSignOut:i,isSigningOut:o,now:s,accountUrl:a,onTakeTour:l}){let[c,f]=(0,S.useState)(!1),{name:g,detail:h}=P(e),v=e?.kind==="operator"?e.theme:void 0;return(0,t.jsxs)(T.Sheet,{open:c,onOpenChange:f,children:[(0,t.jsx)(T.SheetTrigger,{"data-testid":"account-menu","aria-label":`Account menu, ${g}${e?`, ${h}`:""}`,className:"inline-flex size-(--size-control-touch) shrink-0 items-center justify-center rounded-full outline-none focus-visible:outline-2 focus-visible:outline-ring",children:(0,t.jsx)(u.Avatar,{kind:"account",size:28,name:g})}),(0,t.jsxs)(T.SheetContent,{side:"bottom","data-testid":"account-sheet",className:"gap-3",children:[(0,t.jsx)(T.SheetTitle,{className:"sr-only",children:"Account"}),(0,t.jsx)(L,{account:e,now:s}),void 0===a||e?.kind==="viewer"?null:(0,t.jsxs)("a",{href:a,"data-testid":"account-hosted",className:"flex h-(--size-control-touch) items-center gap-2.5 border-t border-border pt-3 text-body-touch text-foreground outline-none focus-visible:outline-2 focus-visible:outline-ring [&_svg]:size-(--size-icon) [&_svg]:text-muted-foreground",children:[(0,t.jsx)(p.CircleUserRound,{"aria-hidden":!0}),k]}),void 0===l?null:(0,t.jsxs)("button",{type:"button","data-testid":"account-take-tour",onClick:()=>{f(!1),l()},className:"flex h-(--size-control-touch) items-center gap-2.5 border-t border-border pt-3 text-body-touch text-foreground outline-none focus-visible:outline-2 focus-visible:outline-ring [&_svg]:size-(--size-icon) [&_svg]:text-muted-foreground",children:[(0,t.jsx)(m.Compass,{"aria-hidden":!0}),M]}),N(e)&&(0,t.jsxs)("div",{className:"flex flex-col gap-1.5 border-t border-border pt-3",children:[(0,t.jsx)("p",{className:"text-caption text-muted-foreground",children:"Theme"}),(0,t.jsx)(O.Tabs,{value:v,onValueChange:e=>{j(e)&&r(e)},children:(0,t.jsx)(O.TabsList,{"aria-label":"Theme",className:"w-full",children:R.THEMES.map(n=>{let r=A[n];return(0,t.jsxs)(O.TabsTrigger,{value:n,disabled:void 0===e,"data-testid":`account-theme-${n}`,className:"grow",children:[(0,t.jsx)(r,{"aria-hidden":!0}),E.THEME_LABELS[n]]},n)})})})]}),(0,t.jsxs)("a",{href:d.SOURCE_URL,target:"_blank",rel:"noreferrer","data-testid":"account-source",className:"flex h-(--size-control-touch) items-center gap-2.5 border-t border-border pt-3 text-body-touch text-foreground outline-none focus-visible:outline-2 focus-visible:outline-ring [&_svg]:size-(--size-icon) [&_svg]:text-muted-foreground",children:[(0,t.jsx)(n.CodeXml,{"aria-hidden":!0}),"Source on GitHub",(0,t.jsx)("span",{className:"sr-only",children:" (opens in a new tab)"})]}),(0,t.jsx)("button",{type:"button","data-testid":"account-sign-out",disabled:o,onClick:i,className:(0,C.classNames)("flex h-(--size-control-touch) items-center gap-2.5 border-t border-border pt-3 text-body-touch text-foreground outline-none focus-visible:outline-2 focus-visible:outline-ring disabled:opacity-60 [&_svg]:size-(--size-icon) [&_svg]:text-muted-foreground"),children:(0,t.jsx)(D,{isSigningOut:o})}),(0,t.jsx)(T.SheetClose,{render:(0,t.jsx)(w.Button,{size:"touch",className:"w-full"}),children:"Cancel"})]})]})}],57957);let F="relative flex h-(--size-control) items-center gap-2.5 rounded-md px-2.5 text-body text-muted-foreground transition-colors duration-(--duration-fast) hover:bg-accent hover:text-foreground aria-[current=page]:bg-accent aria-[current=page]:font-medium aria-[current=page]:text-foreground max-lg:justify-center max-lg:px-0 [&_svg]:size-(--size-icon) [&_svg]:shrink-0";function H({href:e,label:n,icon:r,isActive:i,testId:o,count:s}){return(0,t.jsxs)(l.default,{href:e,"aria-current":i?"page":void 0,"data-testid":o,className:F,children:[r,(0,t.jsx)("span",{className:"grow max-lg:sr-only",children:n}),s]})}function V({count:e}){return void 0===e||0===e?null:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(c.Badge,{variant:"count","data-testid":"nav-inbox-count",className:"max-lg:sr-only",children:[e,(0,t.jsx)("span",{className:"sr-only",children:" open"})]}),(0,t.jsx)("span",{"aria-hidden":!0,className:"absolute top-1.5 right-4 size-1.5 rounded-full bg-primary lg:hidden"})]})}function _({count:e}){return void 0===e||0===e?null:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(c.Badge,{variant:"count-attention","data-testid":"nav-attention-count",className:"max-lg:sr-only",children:[e,(0,t.jsx)("span",{className:"sr-only",children:" need attention"})]}),(0,t.jsx)("span",{"aria-hidden":!0,className:"absolute top-1.5 right-4 size-1.5 rounded-full bg-tone-attention-fg lg:hidden"})]})}function B({href:e,label:n,icon:r,isActive:i,testId:o,count:s}){let a=s?.value!==void 0&&s.value>0;return(0,t.jsxs)(l.default,{href:e,"aria-current":i?"page":void 0,"data-testid":o,className:"flex grow flex-col items-center justify-center gap-1 text-micro text-muted-foreground outline-none focus-visible:outline-2 focus-visible:-outline-offset-2 focus-visible:outline-ring aria-[current=page]:font-medium aria-[current=page]:text-primary [&_svg]:size-(--size-icon-tab)",children:[(0,t.jsxs)("span",{className:"relative",children:[r,a?(0,t.jsxs)("span",{"data-testid":`${o}-count`,className:(0,C.classNames)("absolute -top-1.5 -right-2 flex h-4 min-w-4 items-center justify-center rounded-full px-1 text-micro font-semibold tabular-nums","primary"===s.tone?"bg-primary text-primary-foreground":"bg-destructive text-destructive-foreground"),children:[s.value,(0,t.jsxs)("span",{className:"sr-only",children:[" ",s.words]})]}):null]}),n]})}e.s(["Sidebar",0,function({active:e,inboxCount:l,attentionCount:c,hasSquadrons:f=!1,hasSettings:p=!1,...m}){return(0,t.jsxs)("aside",{"data-slot":"sidebar",className:"sticky top-0 hidden h-dvh w-(--size-rail) shrink-0 flex-col border-r border-border bg-sidebar text-sidebar-foreground sm:flex lg:w-(--size-sidebar)",children:[(0,t.jsxs)("div",{className:"flex h-(--size-header) items-center gap-2.5 px-4 max-lg:justify-center max-lg:px-0",children:[(0,t.jsx)(u.Avatar,{kind:"app",size:28}),(0,t.jsxs)("div",{className:"flex flex-col max-lg:sr-only",children:[(0,t.jsx)("span",{className:"text-body font-semibold text-foreground",children:"Aeolus"}),(0,t.jsx)("span",{className:"text-caption text-muted-foreground",children:"Operator console"})]})]}),(0,t.jsxs)("nav",{"aria-label":"Console",className:"flex grow flex-col gap-0.5 px-2.5 py-2",children:[(0,t.jsx)(H,{href:"/",label:"Fleet overview",icon:(0,t.jsx)(s.Ship,{"aria-hidden":!0}),isActive:"overview"===e,testId:"nav-overview"}),f&&(0,t.jsx)(H,{href:"/squadrons",label:"Squadrons",icon:(0,t.jsx)(o.Shapes,{"aria-hidden":!0}),isActive:"squadrons"===e,testId:"nav-squadrons"}),(0,t.jsx)(H,{href:"/inbox",label:"Operator inbox",icon:(0,t.jsx)(r.Inbox,{"aria-hidden":!0}),isActive:"inbox"===e,testId:"nav-inbox",count:(0,t.jsx)(V,{count:l})}),(0,t.jsx)(H,{href:"/needs-attention",label:"Needs attention",icon:(0,t.jsx)(a.TriangleAlert,{"aria-hidden":!0}),isActive:"attention"===e,testId:"nav-attention",count:(0,t.jsx)(_,{count:c})})]}),(0,t.jsxs)("div",{className:"px-2.5 pb-2",children:[p&&(0,t.jsx)(H,{href:"/settings",label:"Settings",icon:(0,t.jsx)(i.Settings,{"aria-hidden":!0}),isActive:"settings"===e,testId:"nav-settings"}),(0,t.jsxs)("a",{href:d.SOURCE_URL,target:"_blank",rel:"noreferrer","data-testid":"nav-source",className:F,children:[(0,t.jsx)(n.CodeXml,{"aria-hidden":!0}),(0,t.jsx)("span",{className:"grow max-lg:sr-only",children:"Source on GitHub"}),(0,t.jsx)("span",{className:"sr-only",children:" (opens in a new tab)"})]})]}),(0,t.jsx)("div",{className:"border-t border-border p-2.5",children:(0,t.jsx)(z,{...m})})]})}],36779),e.s(["TabBar",0,function({active:e,inboxCount:n,attentionCount:i,hasSquadrons:l=!1}){return(0,t.jsxs)("nav",{"aria-label":"Console","data-slot":"tab-bar",className:"fixed inset-x-0 bottom-0 z-40 flex min-h-(--size-tabbar) border-t border-border bg-background pb-[env(safe-area-inset-bottom)] sm:hidden",children:[(0,t.jsx)(B,{href:"/",label:"Fleet",icon:(0,t.jsx)(s.Ship,{"aria-hidden":!0}),isActive:"fleet"===e,testId:"tab-fleet"}),l&&(0,t.jsx)(B,{href:"/squadrons",label:"Squadrons",icon:(0,t.jsx)(o.Shapes,{"aria-hidden":!0}),isActive:"squadrons"===e,testId:"tab-squadrons"}),(0,t.jsx)(B,{href:"/inbox",label:"Inbox",icon:(0,t.jsx)(r.Inbox,{"aria-hidden":!0}),isActive:"inbox"===e,testId:"tab-inbox",count:{value:n,tone:"primary",words:"open"}}),(0,t.jsx)(B,{href:"/needs-attention",label:"Attention",icon:(0,t.jsx)(a.TriangleAlert,{"aria-hidden":!0}),isActive:"attention"===e,testId:"tab-attention",count:{value:i,tone:"attention",words:"need attention"}})]})}],15034)},85538,e=>{"use strict";var t=e.i(43476),n=e.i(24071),r=e.i(66595),i=e.i(22016),o=e.i(15905),s=e.i(24262),a=e.i(57957);e.s(["TopBar",0,function({title:e,live:l,actions:u,back:c,account:d,onSearch:f}){let p=f&&!c?f:void 0;return(0,t.jsxs)("header",{"data-slot":"top-bar","data-mode":c?"detail":"root",className:"sticky top-0 z-30 flex h-(--size-header) items-center gap-2.5 border-b border-border bg-background px-4 sm:hidden",children:[c?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(i.default,{href:c.href,className:"-ml-1.5 inline-flex h-(--size-control-touch) shrink-0 items-center gap-0.5 rounded-md pr-2 text-body-touch text-foreground focus-visible:outline-2 focus-visible:outline-ring [&_svg]:size-(--size-icon)",children:[(0,t.jsx)(n.ChevronLeft,{"aria-hidden":!0}),c.label]}),(0,t.jsx)("p",{className:"min-w-0 flex-1 truncate text-center text-body-touch font-semibold text-foreground",children:e})]}):(0,t.jsx)("h1",{className:"truncate text-title-touch font-semibold tracking-tight text-foreground",children:e}),(0,t.jsx)(s.LiveStatus,{state:l}),u||p||d&&!c?(0,t.jsxs)("div",{className:"ml-auto flex items-center gap-1",children:[p?(0,t.jsx)(o.Button,{variant:"ghost",size:"touch",isIconOnly:!0,"aria-label":"Search ships or jump to","data-testid":"top-bar-search",onClick:p,children:(0,t.jsx)(r.Search,{"aria-hidden":!0})}):null,u,d&&!c?(0,t.jsx)(a.AccountMenuSheet,{...d}):null]}):null]})}])},88721,e=>{"use strict";var t=e.i(54616),n=e.i(66027),r=e.i(12598),i=e.i(18566),o=e.i(41880),s=e.i(87600),a=e.i(18162),l=e.i(77155),u=e.i(27702);e.s(["useAccountMenu",0,function(e){let c=(0,u.useTRPC)(),d=(0,i.useRouter)(),f=(0,r.useQueryClient)(),p=(0,n.useQuery)(c.console.account.queryOptions()),m=(0,s.useHostedAccountUrl)(),g=(0,l.useConsoleGuide)(),h=(0,t.useMutation)(c.console.setTheme.mutationOptions({onMutate:({theme:e})=>{(0,a.applyTheme)(e),f.setQueryData(c.console.account.queryKey(),t=>t?.kind!=="operator"?t:{...t,theme:e})},onError:()=>{(0,o.showToast)({title:"Couldn’t save the theme",description:"It applies here until the page reloads.",tone:"error"})}})),v=(0,t.useMutation)(c.console.signOut.mutationOptions({onSuccess:()=>{f.clear(),d.replace("/sign-in")}})),b=()=>{v.mutate(void 0,{onError:()=>{(0,o.showToast)({title:"Couldn’t sign out",description:"The server did not answer. You are still signed in.",tone:"error",action:{label:"Try again",onClick:b}})}})};return{account:p.data,onThemeChange:e=>{h.mutate({theme:e})},onSignOut:b,isSigningOut:v.isPending,now:e,...void 0===m?{}:{accountUrl:m},...void 0===g.onTakeTour?{}:{onTakeTour:g.onTakeTour}}}])},76145,48695,19191,e=>{"use strict";var t=e.i(84294);let n={compose:"canSend",commission:"canManage","form-squadron":"canManage"};e.s(["allowedPaletteItems",0,function(e,t){return e.filter(e=>"action"===e.kind?t[n[e.id]]:"squadron-action"!==e.kind||t.canManage)},"paletteGroups",0,function(e,t){let n=t.trim().toLowerCase(),r=e.filter(e=>""===n?"squadron-action"!==e.kind:("ship"===e.kind?[e.name,e.type]:"squadron"===e.kind?[e.id,e.blueprint]:"squadron-action"===e.kind?[e.squadronId]:"blueprint"===e.kind?[e.name]:[e.label]).some(e=>e.toLowerCase().includes(n))),i=r.filter(e=>"ship"===e.kind);return[{key:"actions",label:"Actions",items:r.filter(e=>"action"===e.kind||"squadron-action"===e.kind)},{key:"ships",label:"Ships",items:""===n?i.slice(0,8):i},{key:"squadrons",label:"Squadrons",items:r.filter(e=>"squadron"===e.kind)},{key:"blueprints",label:"Blueprints",items:r.filter(e=>"blueprint"===e.kind)},{key:"pages",label:"Go to",items:r.filter(e=>"page"===e.kind)}].filter(e=>e.items.length>0)},"paletteItemsOf",0,function(e,n){return[{kind:"action",id:"commission",label:"Commission ship"},...n?[{kind:"action",id:"form-squadron",label:"Form squadron"}]:[],{kind:"action",id:"compose",label:"Compose a message"},...e.filter(e=>"agent"===e.kind&&"retired"!==e.status).map(e=>({kind:"ship",id:e.id,name:e.name,type:e.type,status:e.status,href:`/ships/${e.id}`})),...(n?.squadrons??[]).filter(e=>"disbanded"!==e.state).map(e=>({kind:"squadron",id:e.id,blueprint:e.blueprint.name,state:e.state,href:`/squadrons/${e.id}`})),...(n?.squadrons??[]).filter(e=>"sailing"===e.state).flatMap(e=>[{kind:"squadron-action",id:`add-member:${e.id}`,squadronId:e.id,action:"add-member",label:`Add member to ${e.id}…`,href:`/squadrons/${e.id}?action=add-member`},{kind:"squadron-action",id:`stand-down:${e.id}`,squadronId:e.id,action:"stand-down",label:`Stand down ${e.id}…`,href:`/squadrons/${e.id}?action=stand-down`}]),...(n?.blueprints??[]).map(e=>({kind:"blueprint",id:e.key,name:e.name,version:e.versions[0]?.version??0,href:(0,t.blueprintPath)(e)})),{kind:"page",id:"overview",label:"Fleet overview",href:"/"},...n?[{kind:"page",id:"squadrons",label:"Squadrons",href:"/squadrons"}]:[],{kind:"page",id:"inbox",label:"Operator inbox",href:"/inbox"},{kind:"page",id:"attention",label:"Needs attention",href:"/needs-attention"}]},"paletteKeyOf",0,function(e){return`${e.kind}:${e.id}`}],76145);var r=e.i(54616),i=e.i(66027),o=e.i(12598);e.i(31627);var s=e.i(44827),a=e.i(81307),l=e.i(32150),u=e.i(86165);let c=["forming","sailing","standing-down","disbanded"],d=a.z.object({repository:a.z.string(),name:a.z.string(),version:a.z.number()}),f=a.z.object({templates:a.z.array(a.z.object({repository:a.z.string(),name:a.z.string(),version:a.z.number(),commit:a.z.string(),committedAt:a.z.string(),description:a.z.string(),checkInMinutes:a.z.number(),model:a.z.string().nullable(),launchNote:a.z.string().nullable(),charter:a.z.string(),handoffs:a.z.array(a.z.object({name:a.z.string(),carries:a.z.string()})),file:a.z.string()})),blueprints:a.z.array(a.z.object({repository:a.z.string(),name:a.z.string(),version:a.z.number(),commit:a.z.string(),committedAt:a.z.string(),description:a.z.string(),roles:a.z.array(a.z.object({name:a.z.string(),template:d,count:a.z.number()})),handoffs:a.z.array(a.z.object({role:a.z.string(),handoff:a.z.string(),to:a.z.string()})),memberNames:a.z.enum(["plain","prefixed"]),file:a.z.string()})),problems:a.z.array(a.z.object({repository:a.z.string(),kind:a.z.enum(["template","blueprint","tag"]),name:a.z.string(),version:a.z.number(),message:a.z.string()}))}),p=a.z.object({id:a.z.string(),state:a.z.enum(c),blueprint:a.z.object({repository:a.z.string(),name:a.z.string(),version:a.z.number(),commit:a.z.string()}),flagship:a.z.object({shipId:a.z.string(),name:a.z.string()}),members:a.z.array(a.z.object({shipId:a.z.string(),name:a.z.string(),role:a.z.string(),type:a.z.string(),onStationAt:a.z.string().nullable(),model:a.z.object({pinned:a.z.string().nullable(),stated:a.z.string().nullable(),isMismatch:a.z.boolean()}),health:a.z.enum(["not-on-station","on-time","late","silent"]),checkInMinutes:a.z.number(),crew:a.z.object({status:a.z.enum(["awaitingCrew","crewed","retired"]),lastSeenAt:a.z.string().nullable(),crewedSince:a.z.string().nullable()})})),formedAt:a.z.string(),sailedAt:a.z.string().nullable()}),m=a.z.object({squadronId:a.z.string(),flagship:a.z.object({shipId:a.z.string(),name:a.z.string()}),members:a.z.array(a.z.object({shipId:a.z.string(),name:a.z.string(),role:a.z.string(),crewLines:a.z.array(s.crewLineSchema),launchNote:a.z.string().nullable(),model:a.z.string().nullable()}))}),g=a.z.object({deliveryId:a.z.string(),messageId:a.z.string(),senderShipId:a.z.string(),senderName:a.z.string(),contentType:a.z.string(),payload:a.z.string(),inReplyTo:a.z.string().nullable(),receivedAt:a.z.string()}),h=a.z.union([a.z.object({result:a.z.object({data:a.z.unknown()})}),a.z.object({error:a.z.object({message:a.z.string()})})]);async function v(e,t){let n=`/api/squadrons/${e}`,r=t.isMutation?await fetch(n,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(t.input??{})}):await fetch(void 0===t.input?n:`${n}?input=${encodeURIComponent(JSON.stringify(t.input))}`,{cache:"no-store"}),i=h.safeParse(await r.json());if(!i.success)throw Error("squadrons answered something the console does not understand");if("error"in i.data)throw Error(i.data.error.message);return t.answers.parse(i.data.result.data)}let b=["squadrons","list"],x=a.z.object({shipId:a.z.string(),name:a.z.string(),role:a.z.string(),crewLines:a.z.array(s.crewLineSchema),launchNote:a.z.string().nullable(),model:a.z.string().nullable()}),y=a.z.object({crewLines:a.z.array(s.crewLineSchema),launchNote:a.z.string().nullable(),model:a.z.string().nullable()});function S(e){return["squadrons","crew-lines",e]}let C=a.z.object({name:a.z.string(),url:a.z.string(),path:a.z.string(),hasToken:a.z.boolean(),addedAt:a.z.string(),lastFetch:a.z.object({at:a.z.string(),error:a.z.string().nullable()}).nullable()}),E=["squadrons","repositories"];function R(){let e=(0,o.useQueryClient)();return async()=>{await Promise.all([e.invalidateQueries({queryKey:E}),e.invalidateQueries({queryKey:["squadrons","catalogue"]})])}}e.s(["SQUADRON_STATES",0,c,"useAddMember",0,function(){let e=(0,o.useQueryClient)();return(0,r.useMutation)({mutationFn:e=>v("squadrons.addMember",{input:e,isMutation:!0,answers:x}),onSuccess:async()=>{await e.invalidateQueries({queryKey:b})}})},"useAddRepository",0,function(){let e=R();return(0,r.useMutation)({mutationFn:e=>v("repositories.add",{input:e,isMutation:!0,answers:C}),onSettled:e})},"useCatalogue",0,function(){let e="connected"===(0,u.useSquadronsConnection)();return(0,i.useQuery)({queryKey:["squadrons","catalogue"],queryFn:()=>v("catalogue.list",{answers:f}),enabled:e})},"useForceStandDown",0,function(){let e=(0,o.useQueryClient)();return(0,r.useMutation)({mutationFn:e=>v("squadrons.forceStandDown",{input:{squadronId:e},isMutation:!0,answers:a.z.object({})}),onSuccess:async()=>{await e.invalidateQueries({queryKey:b})}})},"useFormSquadron",0,function(){let e=(0,o.useQueryClient)(),{track:t}=(0,l.useAnalytics)();return(0,r.useMutation)({mutationFn:e=>v("squadrons.form",{input:{blueprint:e},isMutation:!0,answers:m}),onSuccess:async n=>{t({name:"squadron_formed",roleCount:new Set(n.members.map(e=>e.role)).size}),e.setQueryData(S(n.squadronId),n.members),await e.invalidateQueries({queryKey:b})}})},"useIssuedCrewLines",0,function(e){return new Map(((0,o.useQueryClient)().getQueryData(S(e))??[]).map(e=>[e.shipId,{crewLines:e.crewLines,launchNote:e.launchNote,model:e.model}]))},"useKeptMessages",0,function(e){let t="connected"===(0,u.useSquadronsConnection)();return(0,i.useQuery)({queryKey:["squadrons","messages",e],queryFn:()=>v("squadrons.messages",{input:{squadronId:e},answers:a.z.array(g)}),refetchInterval:5e3,enabled:t})},"useNewCrewLine",0,function(){let e=(0,o.useQueryClient)();return(0,r.useMutation)({mutationFn:e=>v("squadrons.newCrewLine",{input:e,isMutation:!0,answers:y}),onSuccess:async()=>{await e.invalidateQueries({queryKey:b})}})},"useRefreshCatalogue",0,function(){let e=R();return(0,r.useMutation)({mutationFn:()=>v("catalogue.refresh",{isMutation:!0,answers:a.z.strictObject({})}),onSuccess:e})},"useRemoveMember",0,function(){let e=(0,o.useQueryClient)();return(0,r.useMutation)({mutationFn:e=>v("squadrons.removeMember",{input:e,isMutation:!0,answers:a.z.strictObject({})}),onSuccess:async()=>{await e.invalidateQueries({queryKey:b})}})},"useRemoveRepository",0,function(){let e=R();return(0,r.useMutation)({mutationFn:e=>v("repositories.remove",{input:{name:e},isMutation:!0,answers:a.z.strictObject({})}),onSettled:e})},"useRepositories",0,function(){let e="connected"===(0,u.useSquadronsConnection)();return(0,i.useQuery)({queryKey:E,queryFn:()=>v("repositories.list",{answers:a.z.array(C)}),enabled:e})},"useSquadrons",0,function(){let e="connected"===(0,u.useSquadronsConnection)();return(0,i.useQuery)({queryKey:b,queryFn:()=>v("squadrons.list",{answers:a.z.array(p)}),refetchInterval:5e3,enabled:e})},"useStandDown",0,function(){let e=(0,o.useQueryClient)();return(0,r.useMutation)({mutationFn:e=>v("squadrons.standDown",{input:{squadronId:e},isMutation:!0,answers:a.z.object({})}),onSuccess:async()=>{await e.invalidateQueries({queryKey:b})}})}],48695);var w=e.i(56420);let I={name:"corner-down-left",size:24,node:[["path",{d:"M20 4v7a4 4 0 0 1-4 4H4",key:"6o5b7l"}],["path",{d:"m9 10-5 5 5 5",key:"1kshq7"}]]};I.node;let T=(0,w.default)(I);e.s(["CornerDownLeft",0,T],19191)},57497,5387,49092,16752,30274,74470,14651,8821,e=>{"use strict";var t=e.i(54616),n=e.i(12598),r=e.i(27702);e.s(["composeTargets",0,function(e){let t=e.filter(e=>"agent"===e.kind&&"retired"!==e.status);return{ships:t,types:[...new Set(t.map(e=>e.type))].sort()}},"sendInputOf",0,function(e,t){let{selector:n,payload:r,inReplyTo:i}=e;return{selector:n,payload:r,contentType:"text/plain",idempotencyKey:t,...void 0===i?{}:{inReplyTo:i}}},"useSendMessage",0,function(){let e=(0,r.useTRPC)(),i=(0,n.useQueryClient)();return(0,t.useMutation)(e.ship.send.mutationOptions({onSuccess:()=>i.invalidateQueries({queryKey:e.fleet.pathKey()})}))}],57497);var i=e.i(66027),o=e.i(32150);function s(){let e=(0,r.useTRPC)(),t=(0,n.useQueryClient)();return()=>t.invalidateQueries({queryKey:e.fleet.pathKey()})}e.s(["LAST_SEEN_REFRESH_MS",0,3e4,"useCommissionShip",0,function(){let e=(0,r.useTRPC)(),n=s(),{track:i}=(0,o.useAnalytics)();return(0,t.useMutation)(e.fleet.commission.mutationOptions({onSuccess:async()=>{i({name:"ship_commissioned"}),await n()}}))},"useFleetSnapshot",0,function(){let e=(0,r.useTRPC)();return(0,i.useQuery)(e.fleet.list.queryOptions(void 0,{refetchInterval:3e4}))},"useGetStartingPrompt",0,function(){let e=(0,r.useTRPC)(),n=s();return(0,t.useMutation)(e.fleet.getStartingPrompt.mutationOptions({onSuccess:n}))},"usePingShip",0,function(){let e=(0,r.useTRPC)(),n=s();return(0,t.useMutation)(e.fleet.ping.mutationOptions({onSuccess:n}))},"useRecrewShip",0,function(){let e=(0,r.useTRPC)(),n=s();return(0,t.useMutation)(e.fleet.recrew.mutationOptions({onSuccess:n}))},"useReleaseShip",0,function(){let e=(0,r.useTRPC)(),n=s();return(0,t.useMutation)(e.fleet.release.mutationOptions({onSuccess:n}))},"useRenameShip",0,function(){let e=(0,r.useTRPC)(),n=s();return(0,t.useMutation)(e.fleet.rename.mutationOptions({onSuccess:n}))},"useRetireShip",0,function(){let e=(0,r.useTRPC)(),n=s();return(0,t.useMutation)(e.fleet.retire.mutationOptions({onSuccess:n}))}],5387),e.s(["useFleetLimits",0,function(){let e=(0,r.useTRPC)();return(0,i.useQuery)(e.fleet.limits.queryOptions(void 0,{refetchInterval:6e4}))}],49092);let a=new Intl.NumberFormat("en-US");function l(e){return a.format(e)}function u(e){return`${new Date(e).toISOString().slice(11,16)} UTC`}function c({count:e,limit:t}){return null===t?"none":e<t?"below":e===t?"at":"over"}e.s(["composeRefusedNotice",0,function(e){return{title:"This message wasn’t sent",description:`Your fleet reached its limit of ${l(e.limit)} messages today. Sending works again after the limit resets at ${u(e.resetsAt)}.`}},"hasLimits",0,function(e){return void 0!==e&&(null!==e.ships.limit||null!==e.dailyMessages.limit)},"messageLimitNotice",0,function(e){return{title:"Your fleet reached today’s message limit",description:`It sent ${l(e.limit)} messages today, its daily limit. New messages are refused until the limit resets at ${u(e.resetsAt)}.`}},"messageLimitReached",0,function(e){let t=e?.dailyMessages;return t?.limit!=null&&t.count>=t.limit?{limit:t.limit,resetsAt:t.resetsAt}:void 0},"meterCaption",0,function(e){let{count:t,limit:n}=e;if(null===n)return;let r=c(e);return"below"===r?`${l(n-t)} left`:"at"===r?"Limit reached":`${l(t-n)} over the limit`},"meterCount",0,function(e){return l(e)},"meterState",0,c,"resetTime",0,u,"shipLimitNotice",0,function(e){return{title:"Your fleet is at its ship limit",description:`This fleet can have ${l(e)} ships, so it can’t take a new one. Limits are listed on your account.`}},"shipLimitReached",0,function(e){let t=e?.ships;return t?.limit!=null&&t.count>=t.limit?t.limit:void 0}],16752);var d=e.i(56420);let f={name:"send",size:24,node:[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]]};f.node;let p=(0,d.default)(f);e.s(["Send",0,p],30274);var m=e.i(71645);let g=/Mac|iPhone|iPad|iPod/;function h(){return()=>void 0}function v(){var e;return e=navigator.userAgent,g.test(e)?"mac":"other"}function b(){return null}e.s(["sendShortcutAria",0,function(e){return"mac"===e?"Meta+Enter":"Control+Enter"},"sendShortcutKeys",0,function(e){return"mac"===e?"⌘↵":"Ctrl ↵"},"submitOnSendShortcut",0,function(e){var t;let{key:n,metaKey:r,ctrlKey:i}=e;"Enter"===(t={key:n,metaKey:r,ctrlKey:i,isComposing:e.nativeEvent.isComposing}).key&&(t.metaKey||t.ctrlKey)&&!t.isComposing&&(e.preventDefault(),e.currentTarget.form?.requestSubmit())},"useShortcutPlatform",0,function(){return(0,m.useSyncExternalStore)(h,v,b)}],74470),e.s([],14651);var x=e.i(33332);let y=m.createContext(void 0);e.s(["DialogRootContext",0,y,"useDialogRootContext",0,function(e){let t=m.useContext(y);if(!e&&void 0===t)throw Error((0,x.default)(27));return t}],8821)},86413,e=>{"use strict";var t=e.i(54616),n=e.i(66027),r=e.i(12598),i=e.i(27702);function o(){let e=(0,i.useTRPC)();return(0,n.useQuery)(e.fleet.inbox.queryOptions({filter:"all"}))}function s(e){return"pending"===e.state||"delivered"===e.state}function a(e,t){switch(t){case"open":return e.filter(s);case"done":return e.filter(e=>"acknowledged"===e.state);case"all":return[...e]}}function l(){let e=(0,i.useTRPC)(),t=(0,r.useQueryClient)();return()=>t.invalidateQueries({queryKey:e.fleet.pathKey()})}e.s(["filterCounts",0,function(e){return{open:a(e,"open").length,done:a(e,"done").length,all:e.length}},"inboxPathOf",0,function(e){let t=new URLSearchParams;"open"!==e.filter&&t.set("filter",e.filter),void 0!==e.deliveryId&&t.set("message",e.deliveryId);let n=t.toString();return""===n?"/inbox":`/inbox?${n}`},"messagesFor",0,a,"readInboxFilter",0,function(e){return"done"===e||"all"===e?e:"open"},"useInbox",0,o,"useMarkDone",0,function(){let e=(0,i.useTRPC)(),n=l();return(0,t.useMutation)(e.fleet.markDone.mutationOptions({onSuccess:n}))},"useMarkRead",0,function(){let e=(0,i.useTRPC)(),n=l();return(0,t.useMutation)(e.fleet.markRead.mutationOptions({onSuccess:n}))},"useOpenInboxCount",0,function(){let e=o().data;return void 0===e?void 0:e.filter(s).length},"useReply",0,function(){let e=(0,i.useTRPC)(),n=l();return(0,t.useMutation)(e.fleet.reply.mutationOptions({onSuccess:n}))}])},18423,e=>{"use strict";var t=e.i(12598),n=e.i(5861),r=e.i(71645),i=e.i(27702);let o=new Set(["FleetInitialised","ShipCommissioned","ShipClaimed","LeaseRevoked","CredentialRevoked","StartingPromptIssued","ShipRetired","DeliveryAcknowledged","DeliveryUndeliverable","ShipReported","CrewRequested","CrewRequestRemoved","CrewAssigned","CrewStatusChanged","CrewRequestExplained"]);async function s(e,t){await e.cancelQueries({queryKey:t,predicate:e=>void 0===e.state.data&&"fetching"===e.state.fetchStatus}),await e.invalidateQueries({queryKey:t})}let a=new Set(["DeliveryUndeliverable","DeliveryDismissed"]);e.s(["useLiveFleet",0,function(){let e=(0,i.useTRPC)(),l=(0,t.useQueryClient)(),[u,c]=(0,r.useState)(new Set),d=e=>{s(l,e)},f=(0,n.useSubscription)(e.fleet.events.subscriptionOptions({lastEventId:null},{onData:({data:t})=>{var n,r;if("resync"===t.kind)return void d(e.fleet.pathKey());let{event:i}=t;for(let t of new Set([i.shipId,i.actorShipId]))null!==t&&(d(e.fleet.ship.queryKey({shipId:t})),d(e.fleet.shipTimeline.queryKey({shipId:t})));if(null!==i.messageId&&(d(e.fleet.shipMessages.pathKey()),d(e.fleet.message.queryKey({messageId:i.messageId})),d(e.fleet.inbox.pathKey())),n=i.type,a.has(n)&&d(e.fleet.needsAttention.queryKey()),r=i.type,!o.has(r))return;d(e.fleet.list.queryKey());let{shipId:s}=i;"ShipCommissioned"===i.type&&null!==s&&c(e=>new Set([...e,s]))}}));return{live:function(e){switch(e){case"pending":return"live";case"connecting":return"reconnecting";case"idle":case"error":return"offline"}}(f.status),newShipIds:u,error:f.error}}])},28459,e=>{"use strict";e.i(31627);var t=e.i(53341),n=e.i(54616),r=e.i(66027),i=e.i(12598),o=e.i(48695),s=e.i(84294),a=e.i(27702);function l(){let e=(0,a.useTRPC)();return(0,r.useQuery)(e.fleet.needsAttention.queryOptions())}function u(){let e=(0,a.useTRPC)(),t=(0,i.useQueryClient)();return()=>t.invalidateQueries({queryKey:e.fleet.pathKey()})}e.s(["DISMISSED_TOAST",0,{title:"Delivery dismissed",description:"It stays in the timelines as dismissed."},"canResend",0,function(e){return!(0,t.isPingContentType)(e.message.contentType)},"deliveryWithId",0,function(e,t){return e?.find(e=>e.deliveryId===t)},"messagePathOf",0,function(e){let{message:t}=e;return`/ships/${t.sender.id}?tab=messages&message=${t.id}`},"resentToast",0,function(e){return{title:"Message resent",description:`A new message went to ${function(e){let{recipient:t}=e.message;return"ship"===t.kind?t.ship.name:`any ship of type ${t.type}`}(e)}. The original is dismissed.`}},"useAttentionCount",0,function(){let e=l().data?.length,t=(0,o.useSquadrons)();return void 0===e?void 0:e+(0,s.silentMembers)(t.data??[]).length},"useDismissDelivery",0,function(){let e=(0,a.useTRPC)(),t=u();return(0,n.useMutation)(e.fleet.dismiss.mutationOptions({onSuccess:t}))},"useNeedsAttention",0,l,"useResendDelivery",0,function(){let e=(0,a.useTRPC)(),t=u();return(0,n.useMutation)(e.fleet.resend.mutationOptions({onSuccess:t}))}])},96676,e=>{"use strict";let t;var n=e.i(71645);let r=Date.now(),i=new Set;function o(e){return i.add(e),t??=setInterval(()=>{for(let e of(r=Date.now(),i))e()},1e4),()=>{i.delete(e),0===i.size&&(clearInterval(t),t=void 0)}}function s(){return r}e.s(["useNow",0,function(){return new Date((0,n.useSyncExternalStore)(o,s,s))}])},78485,e=>{"use strict";var t=e.i(12598),n=e.i(18566),r=e.i(71645),i=e.i(46929);e.s(["useSignInWhenSessionEnds",0,function(e){let o=(0,n.useRouter)(),s=(0,t.useQueryClient)(),a=e.find(e=>"UNAUTHORIZED"===(0,i.trpcErrorCode)(e)),l=void 0===a?void 0:(0,i.isSignedInElsewhere)(a)?"/sign-in?notice=signed-in-elsewhere":"/sign-in";(0,r.useEffect)(()=>{void 0!==l&&(s.clear(),o.replace(l))},[l,s,o])}])},84294,e=>{"use strict";function t(e,t){return e.roles.map(e=>({role:e.name,template:`${e.template.name}@${String(e.template.version)}`,count:e.count,checkInMinutes:t.find(t=>t.repository===e.template.repository&&t.name===e.template.name&&t.version===e.template.version)?.checkInMinutes}))}function n(e){let t=Math.floor(e/60),n=e%60;return 0===t?`${String(n)} min`:0===n?`${String(t)} h`:`${String(t)} h ${String(n)} min`}e.s(["blueprintChoices",0,function(e){let t=new Map;for(let n of e.blueprints){let e=`${n.repository}#${n.name}`,r=t.get(e)??{key:e,repository:n.repository,name:n.name,versions:[]};r.versions.push(n),t.set(e,r)}return[...t.values()].map(e=>({...e,versions:[...e.versions].sort((e,t)=>t.version-e.version)})).sort((e,t)=>e.name.localeCompare(t.name))},"blueprintPath",0,function(e){let t=new URLSearchParams({repository:e.repository});return void 0!==e.version&&t.set("version",String(e.version)),`/squadrons/blueprints/${encodeURIComponent(e.name)}?${t.toString()}`},"blueprintsUsing",0,function(e,t){return e.filter(e=>e.roles.some(e=>e.template.repository===t.repository&&e.template.name===t.name&&(void 0===t.version||e.template.version===t.version)))},"checkInText",0,function(e){return e%60==0?`every ${String(e/60)} h`:`every ${String(e)} min`},"handoffsOf",0,function(e,t){let n=e=>[...new Set(e)];return{from:n(e.handoffs.filter(e=>e.to===t).map(e=>e.role)),to:n(e.handoffs.filter(e=>e.role===t).map(e=>e.to))}},"handoffsText",0,function(e){let t=[e.from.length>0?`from ${e.from.join(", ")}`:void 0,e.to.length>0?`to ${e.to.join(", ")}`:void 0].filter(e=>void 0!==e);return 0===t.length?"None":t.join(" · ")},"healthCounts",0,function(e){return["on-time","late","silent","not-on-station"].map(t=>({health:t,count:e.filter(e=>e.health===t).length})).filter(e=>e.count>0)},"memberCount",0,function(e){return e.roles.reduce((e,t)=>e+t.count,0)},"membersByRole",0,function(e){let t=new Map;for(let n of e)t.set(n.role,[...t.get(n.role)??[],n]);return[...t.entries()].map(([e,t])=>({role:e,members:t}))},"otherMembersOfRole",0,function(e,t){let n=e.members.find(e=>e.shipId===t)?.role;return e.members.filter(e=>e.role===n&&e.shipId!==t&&"retired"!==e.crew.status).map(e=>e.name)},"roleOptions",0,function(e,n){let{blueprint:r,templates:i}=n;return t(r,i).map(t=>({role:t.role,template:t.template,checkInMinutes:t.checkInMinutes,now:e.members.filter(e=>e.role===t.role&&"retired"!==e.crew.status).length,inBlueprint:t.count}))},"rolePreviews",0,t,"rolesText",0,function(e){return e.roles.map(e=>e.count>1?`${e.name} \xd7${String(e.count)}`:e.name).join(", ")},"shipsInSquadrons",0,function(e){let t=new Map;for(let n of e)if("disbanded"!==n.state)for(let e of(t.set(n.flagship.shipId,{squadronId:n.id,role:null}),n.members))t.set(e.shipId,{squadronId:n.id,role:e.role});return t},"silentMembers",0,function(e){return e.filter(e=>"disbanded"!==e.state).flatMap(e=>e.members.filter(e=>"silent"===e.health).map(t=>({squadronId:e.id,member:t})))},"squadronActionsOffered",0,function(e,t){let n="sailing"===e.state;return{canAddMember:t.canManage&&n&&t.hasRoles,canMessageFlagship:t.canSend&&"disbanded"!==e.state,canStandDown:t.canManage&&n,canForceStandDown:t.canManage&&"disbanded"!==e.state}},"squadronsFromBlueprint",0,function(e,t){return e.filter(e=>e.blueprint.repository===t.repository&&e.blueprint.name===t.name)},"squadronsText",0,function(e){return["forming","sailing","standing-down"].map(t=>({state:t,count:e.filter(e=>e.state===t).length})).filter(e=>e.count>0).map(e=>`${String(e.count)} ${e.state.replace("-"," ")}`).join(", ")},"stationCount",0,function(e){return{onStation:e.members.filter(e=>null!==e.onStationAt).length,total:e.members.length}},"templateChoices",0,function(e){let t=new Map;for(let n of e.templates){let e=`${n.repository}#${n.name}`,r=t.get(e)??{key:e,repository:n.repository,name:n.name,versions:[]};r.versions.push(n),t.set(e,r)}return[...t.values()].map(e=>({...e,versions:[...e.versions].sort((e,t)=>t.version-e.version)})).sort((e,t)=>e.name.localeCompare(t.name))},"templatePath",0,function(e){let t=new URLSearchParams({repository:e.repository});return void 0!==e.version&&t.set("version",String(e.version)),`/squadrons/templates/${encodeURIComponent(e.name)}?${t.toString()}`},"thresholdsText",0,function(e){return`Late after ${n(+e)}, silent after ${n(3*e)}`},"workCounts",0,function(e){return["working","idle","blocked"].map(t=>({state:t,count:e.filter(e=>e?.state===t).length})).filter(e=>e.count>0)}])}]);
1
+ (globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,25933,e=>{"use strict";e.i(79652);var t=e.i(45654),n=e.i(94268),r=e.i(31375),i=e.i(69534),o=e.i(93798),s=e.i(56212),a=e.i(5627),l=e.i(24889),u=e.i(89102),c=e.i(18118),d=e.i(98108),f=e.i(60375),p=e.i(37642),m=e.i(54463),g=e.i(111),h=e.i(36760),v=e.i(44013),b=e.i(6346),x=e.i(72705),y=e.i(87754),S=e.i(59182),C=e.i(53590),E=e.i(87445),R=e.i(51614),w=e.i(17088);let I=e.i(18438).ListboxSeparator;var T=e.i(56970),k=e.i(2672),O=e.i(56789),M=e.i(42191),A=e.i(91786);e.s(["Arrow",()=>p.ComboboxArrow,"Backdrop",()=>c.ComboboxBackdrop,"Chip",()=>y.ComboboxChip,"ChipRemove",()=>S.ComboboxChipRemove,"Chips",()=>x.ComboboxChips,"Clear",()=>w.ComboboxClear,"Collection",()=>E.ComboboxCollection,"Empty",()=>R.ComboboxEmpty,"Group",()=>g.ComboboxGroup,"GroupLabel",()=>h.ComboboxGroupLabel,"Icon",()=>m.ComboboxIcon,"Input",()=>i.ComboboxInput,"InputGroup",()=>o.ComboboxInputGroup,"Item",()=>v.ComboboxItem,"ItemIndicator",()=>b.ComboboxItemIndicator,"Label",()=>n.ComboboxLabel,"List",()=>a.ComboboxList,"Popup",()=>f.ComboboxPopup,"Portal",()=>u.ComboboxPortal,"Positioner",()=>d.ComboboxPositioner,"Root",()=>t.ComboboxRoot,"Row",()=>C.ComboboxRow,"Separator",0,I,"Status",()=>l.ComboboxStatus,"Trigger",()=>s.ComboboxTrigger,"Value",()=>r.ComboboxValue,"createItems",0,function(e,t){let{getValue:n,getLabel:r}=t,i=null;function o(){if(null===i){let t=new Map;for(let r of e?(0,M.flattenLeafItems)(e):O.EMPTY_ARRAY){if(null==r)continue;let e=n(r);t.has(e)||t.set(e,r)}i=t}return i}return{data:e,value:function(e){return null==e?e:n(e)},hasValue:(e,t)=>void 0!==(0,A.findCollectionItem)(o(),e,t),itemLabel:r,label(e,t,n){let i=(0,A.findCollectionItem)(o(),e,t);return void 0!==i?r(i):(0,M.stringifyAsLabel)(e,n)}}},"useFilter",()=>T.useComboboxFilter,"useFilteredItems",0,function(){return(0,k.useComboboxDerivedItemsContext)().filteredItems}],24189);var P=e.i(24189);e.s(["Combobox",0,P],25933)},44013,6346,72705,87754,59182,53590,51614,17088,e=>{"use strict";var t=e.i(71645),n=e.i(74080),r=e.i(46376),i=e.i(2672),o=e.i(73553),s=e.i(52245),a=e.i(33332);let l=t.createContext(void 0);function u(){let e=t.useContext(l);if(!e)throw Error((0,a.default)(19));return e}var c=e.i(40886);let d=t.createContext(!1);var f=e.i(84325),p=e.i(43476);function m(e){let{componentProps:a,forwardedRef:u,virtualized:m,indexFromFilter:g}=e,{render:h,className:v,style:b,value:x=null,index:y,disabled:S=!1,nativeButton:C=!1,...E}=a,R=t.useRef(null),w=(0,o.useCompositeListItem)({guess:!0,index:y,textRef:R}),I=(0,i.useComboboxRootContext)(),T=t.useContext(d),k=(0,i.useComboboxHasItemsContext)(),O=I.useState("selectionMode"),M=I.useState("disabled"),A=I.useState("readOnly"),P=I.useState("isItemEqualToValue"),N=M||S,j="none"!==O,L=y??g??w.index,D=-1!==L,z=I.useState("id"),F=I.useState("isActive",L),H=I.useState("isSelected",x),V=I.useState("itemProps"),q=t.useRef(null),_=null!=z&&D?`${z}-${L}`:void 0,B=H&&j;(0,r.useIsoLayoutEffect)(()=>{if(!(D&&(m||null!=y)))return;let e=I.context.listRef.current;return e[L]=q.current,()=>{delete e[L]}},[D,m,L,y,I]),(0,r.useIsoLayoutEffect)(()=>{if(!D||k)return;let e=I.context.valuesRef.current;return e[L]=x,()=>{delete e[L]}},[D,k,L,x,I]),(0,r.useIsoLayoutEffect)(()=>{if(!D||k)return;let e=I.state.selectedValue,t=I.state.selectedIndex;"multiple"===I.state.selectionMode&&Array.isArray(e)?t=(0,f.resolveSelectedIndex)(L,x,I.context.valuesRef.current,e,P,t):(0,f.compareItemEquality)(x,e,P)&&(t=L),I.set("selectedIndex",t)},[D,k,I,L,x,P]);let{getButtonProps:W,buttonRef:$}=(0,c.useButton)({disabled:N,focusableWhenDisabled:!0,native:C,composite:!0});function U(e){function t(){I.context.handleSelection(e,x)}I.state.submitOnItemClick?(n.flushSync(t),I.context.requestSubmit()):t()}let K=(0,s.useRenderElement)("div",a,{ref:[$,u,w.ref,q],state:{disabled:N,selected:B,highlighted:F},props:[V,{id:_,role:T?"gridcell":"option","aria-selected":j?B:void 0,tabIndex:void 0,onPointerDownCapture(e){e.isPrimary&&(I.context.pointerDownItemRef.current=e.currentTarget),e.preventDefault()},onMouseDown(e){e.preventDefault()},onClick(e){N||A||U(e.nativeEvent)},onMouseUp(e){let t=I.context.pointerDownItemRef.current===e.currentTarget;I.context.pointerDownItemRef.current=null,N||A||0!==e.button||t||!F||U(e.nativeEvent)}},E,W]}),G=t.useMemo(()=>({selected:B,textRef:R}),[B,R]);return(0,p.jsx)(l.Provider,{value:G,children:K})}function g(e){let{componentProps:t,forwardedRef:n}=e,r=(0,i.useComboboxRootContext)().useState("isItemEqualToValue"),{flatFilteredValues:o}=(0,i.useComboboxDerivedItemsContext)(),s=t.value??null,a=(0,f.findItemIndex)(o,s,r);return(0,p.jsx)(m,{componentProps:t,forwardedRef:n,virtualized:!0,indexFromFilter:a})}let h=t.memo(t.forwardRef(function(e,t){let n=(0,i.useComboboxRootContext)().useState("virtualized");return n&&null==e.index?(0,p.jsx)(g,{componentProps:e,forwardedRef:t}):(0,p.jsx)(m,{componentProps:e,forwardedRef:t,virtualized:n,indexFromFilter:void 0})}));e.s(["ComboboxItem",0,h],44013);var v=e.i(23910),b=e.i(37584),x=e.i(74354);let y=t.forwardRef(function(e,t){let{selected:n}=u();return e.keepMounted||n?(0,p.jsx)(S,{...e,ref:t}):null}),S=t.memo(t.forwardRef((e,n)=>{let{render:r,className:i,style:o,keepMounted:a,...l}=e,{selected:c}=u(),d=t.useRef(null),{transitionStatus:f,setMounted:p}=(0,v.useTransitionStatus)(c),m=(0,s.useRenderElement)("span",e,{ref:[n,d],state:{selected:c,transitionStatus:f},props:[{"aria-hidden":!0,children:"✔️"},l],stateAttributesMapping:x.transitionStatusMapping});return(0,b.useOpenChangeComplete)({batch:!0,enabled:!c,open:c,ref:d,onComplete(){c||p(!1)}}),m}));e.s(["ComboboxItemIndicator",0,y],6346);var C=e.i(56789),E=e.i(13735),R=e.i(53687),w=e.i(22994);let I=t.forwardRef(function(e,n){let{render:r,className:o,style:a,...l}=e,u=(0,i.useComboboxRootContext)(),c=u.useState("open"),d=u.useState("hasSelectionChips"),[f,m]=t.useState(void 0);c&&void 0!==f&&m(void 0);let g=t.useRef([]),h=(0,s.useRenderElement)("div",e,{ref:[n,u.context.chipsContainerRef],props:[d?{role:"toolbar"}:C.EMPTY_OBJECT,{onMouseDown(e){(0,w.handleInputPress)(e,u,u.state.disabled)}},l]}),v=t.useMemo(()=>({highlightedChipIndex:f,setHighlightedChipIndex:m,chipsRef:g}),[f,m,g]);return(0,p.jsx)(E.ComboboxChipsContext.Provider,{value:v,children:(0,p.jsx)(R.CompositeList,{elementsRef:g,children:h})})});e.s(["ComboboxChips",0,I],72705);let T=t.createContext(void 0);var k=e.i(57940),O=e.i(75606),M=e.i(56434),A=e.i(72855),P=e.i(97464);let N=t.forwardRef(function(e,r){let{render:a,className:l,style:u,...c}=e,d=(0,i.useComboboxRootContext)(),{setHighlightedChipIndex:f,chipsRef:m}=(0,E.useComboboxChipsContext)(),g=(0,A.useDirection)(),h=d.useState("disabled"),v=d.useState("readOnly"),b=d.useState("selectedValue"),{ref:x,index:y}=(0,o.useCompositeListItem)(),S=(0,s.useRenderElement)("div",e,{ref:[r,x],state:{disabled:h},props:[{tabIndex:-1,"aria-disabled":h||void 0,"aria-readonly":v||void 0,onKeyDown(e){if(h||v)return;let t=function(e){let t=y,[n,r]=(0,P.getChipNavigationKeys)(g);return e.key===n?(e.preventDefault(),t=y>0?y-1:void 0):e.key===r?(e.preventDefault(),t=y<m.current.length-1?y+1:void 0):"Backspace"===e.key||"Delete"===e.key?(t=(0,P.getIndexAfterChipRemoval)(y,b.length),(0,k.stopEvent)(e),d.context.setIndices({activeIndex:null,selectedIndex:null,type:M.REASONS.keyboard}),d.context.setSelectedValue(b.filter((e,t)=>t!==y),(0,O.createChangeEventDetails)(M.REASONS.none,e.nativeEvent))):"Enter"===e.key||" "===e.key?((0,k.stopEvent)(e),t=void 0):"ArrowDown"===e.key||"ArrowUp"===e.key?((0,k.stopEvent)(e),d.context.setOpen(!0,(0,O.createChangeEventDetails)(M.REASONS.listNavigation,e.nativeEvent)),t=void 0):1!==e.key.length||e.ctrlKey||e.metaKey||e.altKey||(t=void 0),t}(e);n.flushSync(()=>{f(t)}),void 0===t?d.context.inputRef.current?.focus():m.current[t]?.focus()}},c]}),C=t.useMemo(()=>({index:y}),[y]);return(0,p.jsx)(T.Provider,{value:C,children:S})});e.s(["ComboboxChip",0,N],87754);let j=t.forwardRef(function(e,n){let{render:r,className:o,disabled:l=!1,nativeButton:u=!0,style:d,...p}=e,m=(0,i.useComboboxRootContext)(),{index:g}=function(){let e=t.useContext(T);if(!e)throw Error((0,a.default)(17));return e}(),h=m.useState("disabled"),v=m.useState("readOnly"),b=m.useState("selectedValue"),x=m.useState("isItemEqualToValue"),y=h||l,{buttonRef:S,getButtonProps:C}=(0,c.useButton)({native:u,disabled:y||v,focusableWhenDisabled:!0});function E(e){let t=(0,O.createChangeEventDetails)(M.REASONS.chipRemovePress,e.nativeEvent);return!function(e){let t=m.state.activeIndex;if(null==t)return;let n=(0,f.findItemIndex)(m.context.valuesRef.current,e,x);-1!==n&&t===n&&m.context.setIndices({activeIndex:null,type:m.context.keyboardActiveRef.current?M.REASONS.keyboard:M.REASONS.pointer})}(b[g]),m.context.setSelectedValue(b.filter((e,t)=>t!==g),t),m.context.inputRef.current?.focus(),t}return(0,s.useRenderElement)("button",e,{ref:[n,S],state:{disabled:y},props:[{tabIndex:-1,onMouseDown(e){e.preventDefault()},onClick(e){E(e).isPropagationAllowed||e.stopPropagation()},onKeyDown(e){("Enter"===e.key||" "===e.key)&&(E(e).isPropagationAllowed||(0,k.stopEvent)(e))}},p,C]})});e.s(["ComboboxChipRemove",0,j],59182);let L=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...o}=e,a=(0,s.useRenderElement)("div",e,{ref:t,props:[{role:"row"},o]});return(0,p.jsx)(d.Provider,{value:!0,children:a})});e.s(["ComboboxRow",0,L],53590);var D=e.i(31766);let z=t.forwardRef(function(e,t){let{render:n,className:r,style:o,children:a,...l}=e,{filteredItems:u}=(0,i.useComboboxDerivedItemsContext)(),c=(0,i.useComboboxRootContext)(),d=(0,D.useInitialLiveRegionTextMutation)(),f=0===u.length?a:null;return(0,s.useRenderElement)("div",e,{ref:[t,c.context.emptyRef,d],props:[{children:f,role:"status","aria-live":"polite","aria-atomic":!0},l]})});e.s(["ComboboxEmpty",0,z],51614);var F=e.i(69690),H=e.i(79938);let V={...x.transitionStatusMapping,...H.triggerOpenStateMapping},q=t.forwardRef(function(e,t){let{render:n,className:r,disabled:o=!1,nativeButton:a=!0,keepMounted:l=!1,style:u,...d}=e,{disabled:f}=(0,F.useFieldRootContext)(),p=(0,i.useComboboxRootContext)(),m=p.useState("selectionMode"),g=p.useState("disabled"),h=p.useState("readOnly"),x=p.useState("open"),y=p.useState("selectedValue"),S=p.useState("hasSelectionChips"),C=(0,i.useComboboxInputValueContext)(),E=!1;E="none"===m?""!==C:"single"===m?null!=y:S;let R=f||g||o,{buttonRef:w,getButtonProps:I}=(0,c.useButton)({native:a,disabled:R}),{mounted:T,transitionStatus:k,setMounted:A}=(0,v.useTransitionStatus)(E),P={disabled:R,visible:E,open:x,transitionStatus:k};(0,b.useOpenChangeComplete)({open:E,ref:p.context.clearRef,onComplete(){E||A(!1)}});let N=(0,s.useRenderElement)("button",e,{state:P,ref:[t,w,p.context.clearRef],props:[{tabIndex:-1,children:"x",onMouseDown(e){e.preventDefault()},onClick(e){if(R||h)return;let t=p.context.keyboardActiveRef.current?M.REASONS.keyboard:M.REASONS.pointer;p.context.setInputValue("",(0,O.createChangeEventDetails)(M.REASONS.clearPress,e.nativeEvent)),"none"!==m?(p.context.setSelectedValue(Array.isArray(y)?[]:null,(0,O.createChangeEventDetails)(M.REASONS.clearPress,e.nativeEvent)),p.context.setIndices({activeIndex:null,selectedIndex:null,type:t})):p.context.setIndices({activeIndex:null,type:t}),p.context.inputRef.current?.focus()}},d,I],stateAttributesMapping:V});return l||T?N:null});e.s(["ComboboxClear",0,q],17088)},94268,31375,47018,13735,72441,83122,97464,69534,22994,93798,e=>{"use strict";var t=e.i(71645),n=e.i(52245),r=e.i(69690),i=e.i(75812),o=e.i(97886),s=e.i(50001),a=e.i(2672);let l=t.forwardRef(function(e,t){let{render:l,className:u,style:c,...d}=e;delete d.id;let f=(0,r.useFieldRootContext)(),p=(0,a.useComboboxRootContext)(),m=p.useState("inputInsidePopup"),g=p.useState("triggerElement");p.useState("inputElement");let h=p.useState("id"),v=(0,s.getDefaultLabelId)(h),b=g?.id??(m?h:void 0),x=(0,o.useLabel)({id:v,fallbackControlId:b,setLabelId(e){let t="function"==typeof e?e(p.state.labelId):e;p.set("labelId",t)}});return(0,n.useRenderElement)("div",e,{ref:t,state:f.state,props:[x,d],stateAttributesMapping:i.fieldValidityMapping})});e.s(["ComboboxLabel",0,l],94268);var u=e.i(42191),c=e.i(43476);e.s(["ComboboxValue",0,function(e){let{children:n,placeholder:r}=e,i=(0,a.useComboboxRootContext)(),o=i.useState("itemToStringLabel"),s=i.useState("selectedValue"),l=i.useState("items"),d="multiple"===i.useState("selectionMode"),f=i.useState("hasSelectedValue"),p=i.useState("hasNullItemLabel",!f&&null!=r&&null==n),m=null;return m="function"==typeof n?n(s):null!=n?n:f||null==r||p?d&&Array.isArray(s)?(0,u.resolveMultipleLabels)(s,l,o):(0,u.resolveSelectedLabel)(s,l,o):r,(0,c.jsx)(t.Fragment,{children:m})}],31375);var d=e.i(67865),f=e.i(28744),p=e.i(88015),m=e.i(79938),g=e.i(45147);g.CommonTriggerDataAttributes.popupOpen,g.CommonTriggerDataAttributes.pressed;let h={...m.pressableTriggerOpenStateMapping,...i.fieldValidityMapping,popupSide:e=>e?{"data-popup-side":e}:null,listEmpty:e=>e?{"data-list-empty":""}:null};e.s(["triggerStateAttributesMapping",0,h],47018);var v=e.i(47778);let b=t.createContext(void 0);function x(){return t.useContext(b)}e.s(["ComboboxChipsContext",0,b,"useComboboxChipsContext",0,x],13735);var y=e.i(57940),S=e.i(33332);let C=t.createContext(void 0);function E(e){let n=t.useContext(C);if(void 0===n&&!e)throw Error((0,S.default)(21));return n}e.s(["ComboboxPositionerContext",0,C,"useComboboxPositionerContext",0,E],72441);var R=e.i(75606),w=e.i(56434),I=e.i(72855),T=e.i(28918),k=e.i(2077),O=e.i(40886);let M=t.forwardRef(function(e,t){let n=(0,a.useComboboxRootContext)(),{buttonRef:r,getButtonProps:i}=(0,O.useButton)({native:!1}),o=(0,T.useMergedRefs)(t,r),s=i({onClick:function(e){n.context.setOpen(!1,(0,R.createChangeEventDetails)(w.REASONS.closePress,e.nativeEvent,e.currentTarget))}});return(0,c.jsx)("span",{ref:o,...s,"aria-label":"Dismiss",tabIndex:void 0,style:k.visuallyHiddenInput})});function A(e){let t=e.useState("mounted"),n=e.useState("popupSide"),r=e.useState("positionerElement");return t&&r?n:null}function P(){return 0===(0,a.useComboboxDerivedItemsContext)().filteredItems.length}function N(e){return"rtl"===e?["ArrowRight","ArrowLeft"]:["ArrowLeft","ArrowRight"]}function j(e,t){let n=e>=t-1?t-2:e;return n>=0?n:void 0}function L(e,t,n){let r=e.context.listRef.current[t];r&&(e.context.selectionEventRef.current=n,r.click(),e.context.selectionEventRef.current=null)}e.s(["ComboboxInternalDismissButton",0,M],83122),e.s(["clickHighlightedItem",0,L,"getChipNavigationKeys",0,N,"getIndexAfterChipRemoval",0,j,"useListEmpty",0,P,"usePopupSide",0,A],97464);let D=t.forwardRef(function(e,o){let{render:s,className:l,disabled:u=!1,id:m,style:g,...b}=e,{state:S,disabled:C,setTouched:T,setFocused:k,validationMode:O,validation:D}=(0,r.useFieldRootContext)(),{labelId:z}=(0,v.useLabelableContext)(),F=x(),H=!!E(!0),V=(0,a.useComboboxRootContext)(),q=(0,a.useComboboxInputValueContext)(),_=(0,I.useDirection)(),B=V.useState("required"),W=V.useState("disabled"),$=V.useState("readOnly"),U=V.useState("name"),K=V.useState("form"),G=V.useState("selectionMode"),Y=V.useState("autoHighlight"),Q=V.useState("inputProps"),X=V.useState("triggerProps"),J=V.useState("open"),Z=V.useState("mounted"),ee=V.useState("selectedValue"),et=V.useState("id"),en=V.useState("inline"),er=V.useState("modal"),ei=!!Y,eo=A(V),es=C||W||u,ea=P(),el=H||en,eu=(0,p.useBaseUiId)(m??(el?void 0:et)),ec=H?i.DEFAULT_FIELD_STATE_ATTRIBUTES:S,[ed,ef]=t.useState(null),ep=t.useRef(!1),em=t.useRef(null),eg=t.useRef(!1),eh="none"===G&&!H,ev=(0,d.useStableCallback)(e=>{let t=H||V.state.inline;t&&!V.state.hasInputValue&&V.context.setInputValue("",(0,R.createChangeEventDetails)(w.REASONS.none)),V.update({inputElement:e,inputInsidePopup:t,inputOwnsFormValue:eh})}),eb=H?b:D.getValidationProps(es,b);function ex(){V.context.setIndices({activeIndex:null,selectedIndex:null,type:V.context.keyboardActiveRef.current?w.REASONS.keyboard:w.REASONS.pointer})}function ey(){V.context.keyboardActiveRef.current=!1}let eS={...ec,open:J,disabled:es,readOnly:$,popupSide:eo,listEmpty:ea},eC=(0,n.useRenderElement)("input",e,{state:eS,ref:[o,V.context.inputRef,ev],props:[Q,X,{value:ed??q,"aria-readonly":$||void 0,"aria-required":B||void 0,"aria-labelledby":z,disabled:es,readOnly:$,required:"none"===G?B:void 0,form:K,...eh&&U&&{name:U},id:eu,onFocus(){if(k(!0),!en||!eg.current)return;eg.current=!1;let e=em.current;null!=e&&Object.hasOwn(V.context.valuesRef.current,e)&&V.context.setIndices({activeIndex:e})},onBlur(){T(!0),k(!1);let e=V.state.activeIndex;if(en&&null!==e&&"always"!==Y&&(em.current=e,eg.current=!0,V.context.setIndices({activeIndex:null})),"onBlur"===O){let e="none"===G?q:ee;D.commit(e)}},onCompositionStart(e){f.platform.os.android||(ep.current=!0,ef(e.currentTarget.value))},onCompositionEnd(e){ep.current=!1;let t=e.currentTarget.value;ef(null),V.context.setInputValue(t,(0,R.createChangeEventDetails)(w.REASONS.inputChange,e.nativeEvent))},onChange(e){let t=e.nativeEvent,n=t.inputType,r=ep.current||!(!n||"insertReplacementText"===n);function i(e){!$&&!es&&e&&r&&(V.context.setOpen(!0,(0,R.createChangeEventDetails)(w.REASONS.inputChange,t)),ei||ex())}if(ep.current){let n=e.currentTarget.value;ef(n),""!==n||V.state.openOnInputClick||V.state.inputInsidePopup||V.context.setOpen(!1,(0,R.createChangeEventDetails)(w.REASONS.inputClear,t));let r=n.trim(),o=ei&&""!==r;i(r),J&&null!==V.state.activeIndex&&!o&&ex();return}let o=(0,R.createChangeEventDetails)(w.REASONS.inputChange,t);if(V.context.setInputValue(e.currentTarget.value,o),o.isCanceled)return;let s=""===e.currentTarget.value,a=(0,R.createChangeEventDetails)(w.REASONS.inputClear,t);s&&!V.state.inputInsidePopup&&("single"===G&&V.context.setSelectedValue(null,a),V.state.openOnInputClick||V.context.setOpen(!1,a)),i(e.currentTarget.value.trim()),J&&null!==V.state.activeIndex&&!ei&&ex()},onKeyDown(e){if(e.ctrlKey||e.shiftKey||e.altKey||e.metaKey)return;if(V.context.keyboardActiveRef.current=!0,es||$){$&&"Enter"===e.key&&J&&null!==V.state.activeIndex&&(0,y.stopEvent)(e);return}let t=e.currentTarget,n=t.scrollWidth-t.clientWidth,r="rtl"===_;if("Home"===e.key){(0,y.stopEvent)(e);let n=f.platform.engine.gecko&&r?t.value.length:0;t.setSelectionRange(n,n),t.scrollLeft=0;return}if("End"===e.key){(0,y.stopEvent)(e);let i=f.platform.engine.gecko&&r?0:t.value.length;t.setSelectionRange(i,i),t.scrollLeft=r?-n:n;return}if(!Z&&"Escape"===e.key){let t="multiple"===G&&Array.isArray(ee)?0===ee.length:null===ee,n=(0,R.createChangeEventDetails)(w.REASONS.escapeKey,e.nativeEvent);V.context.setInputValue("",n),V.context.setSelectedValue("multiple"===G?[]:null,n),t||V.state.inline||n.isPropagationAllowed||e.stopPropagation();return}if(F&&"Backspace"===e.key&&""===t.value&&void 0===F.highlightedChipIndex&&Array.isArray(ee)&&ee.length>0){let t=F.chipsRef.current.length,n=t>0?t-1:ee.length-1,r=ee.filter((e,t)=>t!==n);ex(),V.context.setSelectedValue(r,(0,R.createChangeEventDetails)(w.REASONS.none,e.nativeEvent));return}let i=F?.highlightedChipIndex!==void 0,o=function(e){let t;if(!F)return;let{highlightedChipIndex:n}=F,r=F.chipsRef.current.length,[i,o]=N(_);return void 0!==n?e.key===i?(e.preventDefault(),t=n>0?n-1:void 0):e.key===o?(e.preventDefault(),t=n<r-1?n+1:void 0):("Backspace"===e.key||"Delete"===e.key)&&(e.preventDefault(),t=j(n,ee.length),ex()):e.key===i&&(e.currentTarget.selectionStart??0)===0&&ee.length>0&&(e.preventDefault(),t=r>0?r-1:void 0),t}(e);if(F?.setHighlightedChipIndex(o),void 0!==o?F?.chipsRef.current[o]?.focus():i&&V.context.inputRef.current?.focus(),229!==e.which&&"Enter"===e.key&&J){let t=V.state.activeIndex,n=e.nativeEvent;if(null===t){if(en)return;V.context.setOpen(!1,(0,R.createChangeEventDetails)(w.REASONS.none,n));return}(0,y.stopEvent)(e),L(V,t,n)}},onPointerMove:ey,onPointerDown:ey},eb],stateAttributesMapping:h}),eE=H?(0,c.jsx)(r.FieldRootContext.Provider,{value:r.DEFAULT_FIELD_ROOT_CONTEXT,children:eC}):eC;return(0,c.jsxs)(t.Fragment,{children:[J&&(!el||er)&&(0,c.jsx)(M,{ref:V.context.startDismissRef}),eE]})});e.s(["ComboboxInput",0,D],69534);var z=e.i(29315),F=e.i(84446),H=e.i(96296);function V(e,t,n,r){if(e.baseUIHandlerPrevented)return;let i=(0,F.getTarget)(e.nativeEvent),o=(0,z.isElement)(i)?i:null;o!==e.currentTarget&&(r?.(o)||(0,H.isInteractiveElement)(o))||(e.preventDefault(),!n&&(t.context.inputRef.current?.focus(),t.state.openOnInputClick&&t.context.setOpen(!0,(0,R.createChangeEventDetails)(w.REASONS.inputPress,e.nativeEvent))))}e.s(["handleInputPress",0,V],22994);let q=t.forwardRef(function(e,t){let{render:i,className:o,style:s,...l}=e,{state:u}=(0,r.useFieldRootContext)(),c=(0,a.useComboboxRootContext)(),f=c.useState("open"),p=c.useState("disabled"),m=c.useState("readOnly"),g=c.useState("hasSelectedValue"),v=c.useState("selectionMode"),b=A(c),x=P(),y={...u,open:f,disabled:p,readOnly:m,popupSide:b,listEmpty:x,placeholder:"none"!==v&&!g},S=(0,d.useStableCallback)(e=>{c.set("inputGroupElement",e)});return(0,n.useRenderElement)("div",e,{ref:[t,S],props:[{role:"group",onMouseDown(e){V(e,c,p,e=>(0,F.contains)(c.context.chipsContainerRef.current,e))}},l],state:y,stateAttributesMapping:h})});e.s(["ComboboxInputGroup",0,q],93798)},5627,31766,24889,78076,89102,18118,e=>{"use strict";var t=e.i(71645),n=e.i(67865),r=e.i(52245),i=e.i(2672),o=e.i(72441),s=e.i(87445),a=e.i(53687),l=e.i(57940),u=e.i(97464),c=e.i(43476);let d=t.forwardRef(function(e,d){var f;let{render:p,className:m,style:g,children:h,...v}=e,b=(0,i.useComboboxRootContext)(),x=(0,i.useComboboxFloatingContext)(),y=!!(0,o.useComboboxPositionerContext)(!0),{filteredItems:S,hasItems:C}=(0,i.useComboboxDerivedItemsContext)(),E=b.useState("selectionMode"),R=b.useState("grid"),w=b.useState("readOnly"),I=b.useState("listProps"),T=b.useState("virtualized"),k=b.useState("forceMounted"),O=0===S.length,M=(0,n.useStableCallback)(e=>{b.set("positionerElement",e)}),A=(0,n.useStableCallback)(e=>{b.set("listElement",e)}),P=t.useMemo(()=>"function"==typeof h?f||(f=(0,c.jsx)(s.ComboboxCollection,{children:h})):h,[h]),N=x.useState("floatingId"),j=(0,r.useRenderElement)("div",e,{state:{empty:O},ref:[d,A,y?null:M],props:[I,{children:P,tabIndex:-1,id:N,role:R?"grid":"listbox","aria-multiselectable":"multiple"===E?"true":void 0,"aria-readonly":!R&&!!w||void 0,onKeyDown(e){if(!b.state.disabled&&!b.state.readOnly&&"Enter"===e.key){let t=b.state.activeIndex;null!=t&&((0,l.stopEvent)(e),(0,u.clickHighlightedItem)(b,t,e.nativeEvent))}},onKeyDownCapture(){b.context.keyboardActiveRef.current=!0},onPointerMoveCapture(){b.context.keyboardActiveRef.current=!1}},v]});if(T)return j;let L=C&&!k?void 0:b.context.labelsRef;return(0,c.jsx)(a.CompositeList,{elementsRef:b.context.listRef,labelsRef:L,children:j})});e.s(["ComboboxList",0,d],5627);var f=e.i(28744),p=e.i(39957);function m(){let e=(0,p.useTimeout)(),n=t.useRef(null);return t.useEffect(()=>{if(f.platform.os.ios)return;let t=n.current;if(null==t)return;let r=function(e){let t=e.ownerDocument.createTreeWalker(e,NodeFilter.SHOW_TEXT),n=null;for(;t.nextNode();){let e=t.currentNode;""!==e.nodeValue&&(n=e)}return n}(t);if(null==r)return;let i=r.data,o=`${i}\u2060`;return r.nodeValue=o,e.start(200,()=>{r.nodeValue===o&&(r.nodeValue=i)}),()=>{e.clear(),r.nodeValue===o&&(r.nodeValue=i)}},[n,e]),n}e.s(["useInitialLiveRegionTextMutation",0,m],31766);let g=t.forwardRef(function(e,t){let{render:n,className:i,style:o,children:s,...a}=e,l=m();return(0,r.useRenderElement)("div",e,{ref:[t,l],props:[{children:s,role:"status","aria-live":"polite","aria-atomic":!0},a]})});e.s(["ComboboxStatus",0,g],24889);var h=e.i(26674),v=e.i(33332);let b=t.createContext(void 0);e.s(["ComboboxPortalContext",0,b,"useComboboxPortalContext",0,function(){let e=t.useContext(b);if(void 0===e)throw Error((0,v.default)(20));return e}],78076);let x=t.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e,o=(0,i.useComboboxRootContext)(),s=o.useState("mounted"),a=o.useState("forceMounted");return s||n||a?(0,c.jsx)(b.Provider,{value:n,children:(0,c.jsx)(h.FloatingPortal,{ref:t,...r})}):null});e.s(["ComboboxPortal",0,x],89102);var y=e.i(79938),S=e.i(74354);let C={...y.popupStateMapping,...S.transitionStatusMapping},E=t.forwardRef(function(e,t){let{render:n,className:o,style:s,...a}=e,l=(0,i.useComboboxRootContext)(),u=l.useState("open"),c=l.useState("mounted"),d=l.useState("transitionStatus");return(0,r.useRenderElement)("div",e,{state:{open:u,transitionStatus:d},ref:t,stateAttributesMapping:C,props:[{role:"presentation",hidden:!c,style:{userSelect:"none",WebkitUserSelect:"none"}},a]})});e.s(["ComboboxBackdrop",0,E],18118)},98108,60375,37642,54463,111,36760,e=>{"use strict";var t=e.i(71645),n=e.i(46376),r=e.i(67865),i=e.i(44394),o=e.i(2672),s=e.i(72441),a=e.i(97464),l=e.i(23706),u=e.i(78076),c=e.i(38396),d=e.i(426),f=e.i(89579),p=e.i(33383),m=e.i(43476);let g=t.forwardRef(function(e,t){let{render:g,className:h,anchor:v,positionMethod:b,side:x,align:y,sideOffset:S,alignOffset:C,collisionBoundary:E="clipping-ancestors",collisionPadding:R,arrowPadding:w,sticky:I,disableAnchorTracking:T=!1,collisionAvoidance:k=c.DROPDOWN_COLLISION_AVOIDANCE,style:O,...M}=e,A=(0,o.useComboboxRootContext)(),P=(0,o.useComboboxFloatingContext)(),N=(0,u.useComboboxPortalContext)(),j=A.useState("modal"),L=A.useState("open"),D=A.useState("mounted"),z=A.useState("openMethod"),F=A.useState("positionerElement"),H=A.useState("triggerElement"),V=A.useState("inputElement"),q=A.useState("inputGroupElement"),_=A.useState("inputInsidePopup"),B=A.useState("transitionStatus"),W=(0,a.useListEmpty)(),$=(0,l.useAnchorPositioning)({anchor:v??(_?H:q??V),floatingRootContext:P,positionMethod:b,mounted:D,side:x,sideOffset:S,align:y,alignOffset:C,arrowPadding:w,collisionBoundary:E,collisionPadding:R,sticky:I,disableAnchorTracking:T,keepMounted:N,collisionAvoidance:k,lazyFlip:!0});(0,p.useAnchoredPopupScrollLock)(L&&j,"touch"===z,F,H);let U={open:L,side:$.side,align:$.align,anchorHidden:$.anchorHidden,empty:W};(0,n.useIsoLayoutEffect)(()=>{A.set("popupSide",$.side)},[A,$.side]);let K=(0,r.useStableCallback)(e=>{A.set("positionerElement",e)}),G=(0,f.usePositioner)(e,U,{styles:$.positionerStyles,transitionStatus:B,props:M,refs:[t,K],hidden:!D,inert:!L});return(0,m.jsxs)(s.ComboboxPositionerContext.Provider,{value:$,children:[D&&j&&(0,m.jsx)(d.InternalBackdrop,{inert:(0,i.inertValue)(!L),cutout:q??V??H}),G]})});e.s(["ComboboxPositioner",0,g],98108);var h=e.i(61487),v=e.i(52245),b=e.i(79938),x=e.i(37584),y=e.i(74354),S=e.i(84446),C=e.i(53984),E=e.i(83122),R=e.i(36523);let w={...b.popupStateMapping,...y.transitionStatusMapping},I=t.forwardRef(function(e,r){let{render:i,className:l,style:u,initialFocus:c,finalFocus:d,...f}=e,p=(0,o.useComboboxRootContext)(),g=(0,s.useComboboxPositionerContext)(),b=(0,o.useComboboxFloatingContext)(),y=p.useState("mounted"),I=p.useState("open"),T=p.useState("openMethod"),k=p.useState("popupProps"),O=p.useState("transitionStatus"),M=p.useState("inputInsidePopup"),A=p.useState("inputElement"),P=p.useState("modal"),N=p.useState("id"),j=(0,a.useListEmpty)(),L=f.id??(M?(0,R.getComboboxPopupId)(N):void 0);(0,n.useIsoLayoutEffect)(()=>(p.set("popupId",p.context.popupRef.current?.id||L),()=>{p.set("popupId",void 0)}),[p,L]),(0,x.useOpenChangeComplete)({open:I,ref:p.context.popupRef,onComplete(){I&&p.context.onOpenChangeComplete(!0)}});let D={open:I,side:g.side,align:g.align,anchorHidden:g.anchorHidden,transitionStatus:O,empty:j},z=(0,v.useRenderElement)("div",e,{state:D,ref:[r,p.context.popupRef],props:[k,{id:L,role:M?"dialog":"presentation",onFocus(e){let t=(0,S.getTarget)(e.nativeEvent);"touch"!==T&&((0,S.contains)(p.state.listElement,t)||t===e.currentTarget)&&p.context.inputRef.current?.focus()}},(0,C.getDisabledMountTransitionStyles)(O),f],stateAttributesMapping:w}),F=!!M&&(e=>"touch"===e?p.context.popupRef.current:A),H=!M||P;return(0,m.jsx)(h.FloatingFocusManager,{context:b,disabled:!y,modal:H,openInteractionType:T,initialFocus:void 0===c?F:c,returnFocus:null!=d?d:!!M&&void 0,getInsideElements:()=>[p.context.startDismissRef.current,p.context.endDismissRef.current],children:(0,m.jsxs)(t.Fragment,{children:[z,H&&(0,m.jsx)(E.ComboboxInternalDismissButton,{ref:p.context.endDismissRef})]})})});e.s(["ComboboxPopup",0,I],60375);let T=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...a}=e,l=(0,o.useComboboxRootContext)(),{arrowRef:u,side:c,align:d,arrowUncentered:f,arrowStyles:p}=(0,s.useComboboxPositionerContext)(),m=l.useState("open");return(0,v.useRenderElement)("div",e,{ref:[u,t],stateAttributesMapping:b.popupStateMapping,state:{open:m,side:c,align:d,uncentered:f},props:{style:p,"aria-hidden":!0,...a}})});e.s(["ComboboxArrow",0,T],37642);let k=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...o}=e;return(0,v.useRenderElement)("span",e,{ref:t,props:[{"aria-hidden":!0,children:"▼"},o]})});e.s(["ComboboxIcon",0,k],54463);var O=e.i(33332);let M=t.createContext(void 0);var A=e.i(76459);let P=t.forwardRef(function(e,n){let{render:r,className:i,style:s,items:a,...l}=e,u=(0,o.useComboboxRootContext)().useState("grid"),[c,d]=t.useState(),f=t.useMemo(()=>({labelId:c,setLabelId:d,items:a}),[c,d,a]),p=(0,v.useRenderElement)("div",e,{ref:n,props:[{role:u?"rowgroup":"group","aria-labelledby":c},l]}),g=(0,m.jsx)(M.Provider,{value:f,children:p});return a?(0,m.jsx)(A.GroupCollectionProvider,{items:a,children:g}):g});e.s(["ComboboxGroup",0,P],111);var N=e.i(88015);let j=t.forwardRef(function(e,r){let{render:i,className:o,style:s,id:a,...l}=e,{setLabelId:u}=function(){let e=t.useContext(M);if(void 0===e)throw Error((0,O.default)(18));return e}(),c=(0,N.useBaseUiId)(a);return(0,n.useIsoLayoutEffect)(()=>(u(c),()=>{u(e=>e===c?void 0:e)}),[c,u]),(0,v.useRenderElement)("div",e,{ref:r,props:[{id:c,"aria-hidden":!0},l]})});e.s(["ComboboxGroupLabel",0,j],36760)},45654,91786,e=>{"use strict";var t=e.i(71645),n=e.i(33332),r=e.i(51437),i=e.i(46376),o=e.i(13203),s=e.i(67865),a=e.i(28918),l=e.i(46265),u=e.i(2077),c=e.i(88940),d=e.i(26352),f=e.i(56789),p=e.i(29315),m=e.i(17989),g=e.i(65858),h=e.i(60891),v=e.i(85689),b=e.i(64132),x=e.i(84446),y=e.i(75606),S=e.i(56434),C=e.i(2672),E=e.i(62156),R=e.i(37584),w=e.i(69690),I=e.i(81104),T=e.i(84708),k=e.i(38489),O=e.i(36523),M=e.i(56970),A=e.i(23910),P=e.i(32199),N=e.i(96545),j=e.i(6039),L=e.i(64111),D=e.i(76782),z=e.i(42191),F=e.i(84325),H=e.i(61919),V=e.i(72855);function q(e,t,n){let r=e.get(t);if(void 0!==r||n===F.defaultItemEquality)return r;for(let[r,i]of e)if((0,F.compareItemEquality)(r,t,n))return i}e.s(["findCollectionItem",0,q],91786);var _=e.i(43476);function B(e){let B,{id:W,onOpenChangeComplete:$,defaultSelectedValue:U=null,selectedValue:K,onSelectedValueChange:G,defaultInputValue:Y,inputValue:Q,open:X,defaultOpen:J=!1,selectionMode:Z,onItemHighlighted:ee,name:et,form:en,disabled:er=!1,readOnly:ei=!1,required:eo=!1,inputRef:es,grid:ea=!1,items:el,filteredItems:eu,filter:ec,filterQuery:ed,openOnInputClick:ef=!0,autoHighlight:ep=!1,keepHighlight:em=!1,highlightItemOnHover:eg=!0,loopFocus:eh=!0,itemToStringLabel:ev,itemToStringValue:eb,isItemEqualToValue:ex=F.defaultItemEquality,virtualized:ey=!1,inline:eS=!1,fillInputOnItemPress:eC=!0,modal:eE=!1,limit:eR=-1,autoComplete:ew="list",formAutoComplete:eI,locale:eT,submitOnItemClick:ek=!1}=e,{clearErrors:eO}=(0,T.useFormContext)(),{setDirty:eM,validityData:eA,setFilled:eP,name:eN,disabled:ej,setTouched:eL,setFocused:eD,validationMode:ez,validation:eF}=(0,w.useFieldRootContext)(),eH=(0,V.useDirection)(),eV=(0,k.useLabelableId)({id:W}),eq=(0,M.useCoreFilter)({locale:eT}),e_=Array.isArray(el)?null:el;if(e_&&"function"!=typeof e_.label)throw Error((0,n.default)(100));let eB=e_?e_.data:el,eW=e_?.value,e$=eW?void 0:eB,eU=t.useMemo(()=>{let e;if(!eu||!eW)return;let t=(0,z.flattenLeafItems)(eu),n=t.map(eW);return{values:n,findItem(r,i){if(!e){e=new Map;for(let r=0;r<n.length;r+=1)e.has(n[r])||e.set(n[r],t[r])}return q(e,r,i)}}},[eu,eW]),eK=t.useMemo(()=>e_?e=>e_.label(e,ex,e=>{let t=eU?.findItem(e,ex);return null!=t?e_.itemLabel(t):(0,z.stringifyAsLabel)(e,ev)}):ev,[e_,ev,eU,ex]),eG=t.useMemo(()=>e_?Object.assign(e=>e_.itemLabel(e),{selected:e=>(0,z.stringifyAsLabel)(e,eK)}):ev,[e_,eK,ev]);function eY(e){return(0,z.stringifyAsLabel)(e,eK)}let[eQ,eX]=t.useState(!1),[eJ,eZ]=t.useState(null),e0=t.useRef(eJ),e1=t.useRef([]),e4=t.useRef([]),e2=t.useRef(null),e5=t.useRef(null),e6=t.useRef(null),e7=t.useRef(null),e3=t.useRef(null),e8=t.useRef(!0),e9=t.useRef(!1),te=t.useRef(null),tt=t.useRef(null),tn=t.useRef(null),tr=t.useRef(H.INITIAL_LAST_HIGHLIGHT),ti=t.useRef(null),to=t.useRef([]),ts=t.useRef(null),ta=ej||er,tl=eN??et,tu="multiple"===Z,tc="single"===Z,td=void 0!==Q||void 0!==Y,tf=void 0!==eB,tp=void 0!==eu;B="always"===ep?"always":!!ep&&"input-change";let[tm,tg]=(0,r.useControlled)({controlled:K,default:tu?U??f.EMPTY_ARRAY:U,name:"Combobox",state:"selectedValue"}),th=t.useMemo(()=>null===ec?()=>!0:void 0!==ec?ec:(0,O.createCollatorItemFilter)(eq,eG),[ec,eq,eG]),tv=(0,c.useRefWithInit)(()=>td?Y??"":tc?eY(tm):"").current,[tb,tx]=(0,r.useControlled)({controlled:Q,default:tv,name:"Combobox",state:"inputValue"}),[ty,tS]=(0,r.useControlled)({controlled:X,default:J,name:"Combobox",state:"open"}),tC=(0,z.isGroupedItems)(eB),tE=ty||null===eJ?String(tb).trim():eJ,tR=tc?eY(tm):"",tw=tc&&!eQ&&""!==tE&&tR.length===tE.length&&eq.contains(tR,tE),tI=tw?"":ed??tE,tT=tf&&tp&&tw&&(!e_||e_.hasValue(tm,ex)),tk=t.useMemo(()=>eB?(0,z.flattenLeafItems)(eB):f.EMPTY_ARRAY,[eB]),tO=t.useMemo(()=>{if(eu&&!tT)return eu;if(!eB)return f.EMPTY_ARRAY;if(tC){let e=[],t=0;for(let n of eB){if(eR>-1&&t>=eR)break;let r=eR>-1?eR-t:1/0,i=""===tI?n.items.slice(0,r):[];if(""!==tI)for(let e of n.items){if(i.length>=r)break;th(e,tI,eG)&&i.push(e)}if(i.length>0){let r={...n,items:i};e.push(r),t+=i.length}}return e}if(""===tI)return eR>-1?tk.slice(0,eR):tk;let e=[];for(let t of tk){if(eR>-1&&e.length>=eR)break;th(t,tI,eG)&&e.push(t)}return e},[eu,tT,eB,tC,tI,eR,th,eG,tk]),tM=t.useMemo(()=>{if(eU&&tO===eu)return eU.values;let e=(0,z.flattenLeafItems)(tO);return eW?e.map(e=>eW(e)):e},[tO,eu,eU,eW]),tA=(0,c.useRefWithInit)(()=>{let e=null;return eS&&ty&&tf&&"none"!==Z&&(e=(0,F.findSelectionIndex)(tM,tm,ex,tu)),new d.ReactStore({id:eV,labelId:void 0,selectedValue:tm,open:ty,items:e$,selectionMode:Z,name:tl,form:en,disabled:ta,readOnly:ei,required:eo,grid:ea,virtualized:ey,openOnInputClick:ef,itemToStringLabel:eK,isItemEqualToValue:ex,modal:eE,autoHighlight:B,submitOnItemClick:ek,hasInputValue:td,mounted:!1,forceMounted:!1,transitionStatus:"idle",inline:eS,activeIndex:null,selectedIndex:e,popupProps:{},listProps:{},inputProps:{},triggerProps:{},itemProps:f.EMPTY_OBJECT,positionerElement:null,listElement:null,popupId:void 0,triggerElement:null,inputElement:null,inputGroupElement:null,popupSide:null,openMethod:null,inputInsidePopup:!0,inputOwnsFormValue:"none"===Z},{onOpenChangeComplete:f.NOOP,setOpen:f.NOOP,setInputValue:f.NOOP,setSelectedValue:f.NOOP,setIndices:f.NOOP,handleSelection:f.NOOP,forceMount:f.NOOP,requestSubmit:f.NOOP,listRef:e1,labelsRef:e4,popupRef:e2,emptyRef:e3,inputRef:e5,startDismissRef:e6,endDismissRef:e7,keyboardActiveRef:e8,chipsContainerRef:te,clearRef:tt,valuesRef:to,pointerDownItemRef:ts,selectionEventRef:tn},E.selectors)}).current,tP="none"===Z?tb:tm,tN=t.useMemo(()=>"none"===Z?tP:Array.isArray(tm)?tm.map(e=>(0,z.stringifyAsValue)(e,eb)):(0,z.stringifyAsValue)(tm,eb),[tP,eb,Z,tm]),tj=(0,s.useStableCallback)(ee),tL=(0,s.useStableCallback)($),tD=tA.useState("activeIndex"),tz=tA.useState("selectedIndex"),tF=tA.useState("positionerElement"),tH=tA.useState("listElement"),tV=tA.useState("triggerElement"),tq=tA.useState("inputElement"),t_=tA.useState("inputGroupElement"),tB=tA.useState("inline"),tW=tA.useState("inputInsidePopup"),t$=tA.useState("inputOwnsFormValue"),tU=tc&&!tW&&tb===tR,tK=(0,l.useValueAsRef)(tV),{mounted:tG,setMounted:tY,transitionStatus:tQ}=(0,A.useTransitionStatus)(ty),{openMethod:tX,triggerProps:tJ}=(0,P.useOpenInteractionType)(ty),tZ=(0,s.useStableCallback)(()=>tN);(0,I.useRegisterFieldControl)(tW?tK:e5,eV,tP,tZ,!ta,et);let t0=(0,s.useStableCallback)(()=>{eB?e4.current=tM.map(eY):tA.set("forceMounted",!0)}),t1=(0,s.useStableCallback)((e,t,n)=>{if(-1===t){if(tr.current===H.INITIAL_LAST_HIGHLIGHT)return;tr.current=H.INITIAL_LAST_HIGHLIGHT}else tr.current={value:e,index:t};tj(e,(0,y.createGenericEventDetails)(n,void 0,{index:t}))}),t4=(0,s.useStableCallback)(e=>{let t={};void 0!==e.activeIndex&&(t.activeIndex=e.activeIndex),void 0!==e.selectedIndex&&(t.selectedIndex=e.selectedIndex),tA.update(t);let n=e.activeIndex;if(void 0===n)return;let r=e.type||S.REASONS.none;null===n?t1(void 0,-1,r):t1(to.current[n],n,r)}),t2=(0,s.useStableCallback)((t,n)=>{if(e.onInputValueChange?.(t,n),!n.isCanceled){if(e9.current=n.reason===S.REASONS.inputClear,n.reason===S.REASONS.inputChange){ty&&null!==eJ&&eZ(null);let e=n.event,r=e.inputType;if("compositionend"===e.type||null!=r&&""!==r&&"insertReplacementText"!==r){let e=""!==t.trim();e&&eX(!0),ti.current={hasQuery:e};let n=tA.state.listElement;if(!tA.state.virtualized&&n){let e=e2.current;for(let t of(0,p.getOverflowAncestors)(n.firstElementChild??n)){if(!(0,p.isHTMLElement)(t)||(e?!(0,x.contains)(e,t):"dialog"===t.getAttribute("role")))break;if((0,N.isScrollableY)(t)){t.scrollTop=0;break}}}e&&B&&null==tA.state.activeIndex&&(ty||tB)&&tA.set("activeIndex",0)}}else n.reason===S.REASONS.inputClear&&""===t&&tA.state.inputInsidePopup&&(ti.current={hasQuery:!1,selection:!0});tx(t)}}),t5=(0,s.useStableCallback)(e=>{let t=!e&&tW&&!tB&&""!==tb&&(String(tb).trim()===eJ||tb===tR);!e&&(t||""===tb||tU)&&eX(!1),eZ(null),t&&t2("",(0,y.createChangeEventDetails)(S.REASONS.inputClear))}),t6=(0,s.useStableCallback)((t,n)=>{if(ty!==t&&(n.reason===S.REASONS.escapeKey&&tf&&0===tM.length&&!e3.current&&n.allowPropagation(),e.onOpenChange?.(t,n),!n.isCanceled&&(t&&null!==eJ&&t5(n.reason===S.REASONS.inputChange),!t&&eQ&&(tc?(tB||eZ(tE),""===tE&&eX(!1)):tu&&(tB||eZ(tE),tW&&t4({activeIndex:null}),(!tW||tB)&&t2("",(0,y.createChangeEventDetails)(S.REASONS.inputClear,n.event,void 0,{isItemPress:n.reason===S.REASONS.itemPress})))),tS(t),!t&&tW&&(n.reason===S.REASONS.focusOut||n.reason===S.REASONS.outsidePress))&&(eL(!0),eD(!1),"onBlur"===ez))){let e="none"===Z?tb:tm;eF.commit(e)}}),t7=(0,s.useStableCallback)((e,t)=>{G?.(e,t),t.isCanceled||(tg(e),("none"===Z&&e2.current&&eC||tc&&!tA.state.inputInsidePopup)&&t2(eY(e),(0,y.createChangeEventDetails)(t.reason,t.event)))}),t3=(0,s.useStableCallback)((e,t)=>{let n=(0,x.getTarget)(e),r=tn.current??e;tn.current=null;let i=(0,y.createChangeEventDetails)(S.REASONS.itemPress,r),o=n?.closest("a")?.getAttribute("href");if(o){o.startsWith("#")&&t6(!1,i);return}if(tu){let e=Array.isArray(tm)?tm:[],n=(0,F.selectedValueIncludes)(e,t,ex);if(t7(n?(0,F.removeItem)(e,t,ex):[...e,t],i),i.isCanceled||!(e5.current&&""!==e5.current.value.trim()))return;if(tA.state.inputInsidePopup){t2("",(0,y.createChangeEventDetails)(S.REASONS.inputClear,i.event,void 0,{isItemPress:!0}));let e=ti.current;e&&!n&&(e.toggledValue=t)}else t6(!1,i)}else{if(t7(t,i),i.isCanceled)return;t6(!1,i)}}),t8=(0,s.useStableCallback)(()=>{let e=eF.inputRef.current?.form??tA.state.inputElement?.form;e&&"function"==typeof e.requestSubmit&&e.requestSubmit()}),t9=(0,s.useStableCallback)(()=>{if(tY(!1),tL?.(!1),eX(!1),eZ(null),"none"===Z?t4({activeIndex:null,selectedIndex:null}):t4({activeIndex:null}),tu&&e5.current&&""!==e5.current.value&&!e9.current&&t2("",(0,y.createChangeEventDetails)(S.REASONS.inputClear)),tc)if(tA.state.inputInsidePopup)e5.current&&""!==e5.current.value&&t2("",(0,y.createChangeEventDetails)(S.REASONS.inputClear));else{let e=eY(tm);if(e5.current&&e5.current.value!==e){let t=""===e?S.REASONS.inputClear:S.REASONS.none;t2(e,(0,y.createChangeEventDetails)(t))}}}),ne=t.useMemo(()=>tB&&tF?{current:tF.closest('[role="dialog"]')}:e2,[tB,tF]);(0,R.useOpenChangeComplete)({enabled:!e.actionsRef,open:ty,ref:ne,onComplete(){ty||t9()}}),t.useImperativeHandle(e.actionsRef,()=>({unmount:t9}),[t9]),(0,i.useIsoLayoutEffect)(function(){let e=null!==e0.current&&null===eJ;if(e0.current=eJ,ty&&(!e||!tf)||(ty||(ts.current=null),"none"===Z))return;let t=tf?tM:to.current;t4({selectedIndex:(0,F.findSelectionIndex)(t,tm,ex,tu)})},[ty,eJ,tm,Z,tu,tf,tM,ex,t4]),(0,i.useIsoLayoutEffect)(()=>{eB&&(to.current=tM,e1.current.length=tM.length)},[eB,tM]),(0,i.useIsoLayoutEffect)(()=>{let e=ti.current;if(e){let t=ty||tB||tA.state.positionerElement?.hidden===!1;if(e.hasQuery)B&&t&&tA.set("activeIndex",0),ti.current=null;else if(""===String(tb).trim()&&(ti.current=null,t)){let t=e.selection;"always"!==B||t||"none"!==tA.state.selectionMode||tA.set("activeIndex",0),queueMicrotask(()=>{if(!tA.state.open&&!tA.state.inline||e5.current&&""!==e5.current.value.trim())return;let n=tA.state.selectedValue,r="multiple"===tA.state.selectionMode;if(r&&Array.isArray(n)?n.length>0:"none"!==tA.state.selectionMode&&null!=n){let t=tf||tp?tM:to.current,i=(0,F.findItemIndex)(t,e.toggledValue,tA.state.isItemEqualToValue);tA.set("activeIndex",-1!==i?i:(0,F.findSelectionIndex)(t,n,tA.state.isItemEqualToValue,r))}else t?tA.set("activeIndex",null):"always"===B&&tA.set("activeIndex",0)})}}if(!ty&&!tB)return;let t=tf||tp?tM:to.current,n=tA.state.activeIndex;if(null==n)return"always"===B&&t.length>0?void tA.set("activeIndex",0):void t1(void 0,-1,S.REASONS.none);if(n>=t.length){t1(void 0,-1,S.REASONS.none),tA.set("activeIndex",null);return}let r=t[n],i=tr.current.value,o=i!==H.NO_ACTIVE_VALUE&&(0,F.compareItemEquality)(r,i,tA.state.isItemEqualToValue);tr.current.index===n&&o||t1(r,n,S.REASONS.none)},[tD,B,t1,tp,tf,tM,tB,ty,tA,tb]),(0,i.useIsoLayoutEffect)(()=>{"none"===Z?eP(""!==String(tb)):eP(tu?Array.isArray(tm)&&tm.length>0:null!=tm)},[eP,Z,tb,tm,tu]),t.useEffect(()=>{tf&&B&&0===tM.length&&t4({activeIndex:null})},[tf,B,tM.length,t4]);let nt=!1;function nn(){nt||tb===tR||(nt=!0,t2(tR,(0,y.createChangeEventDetails)(S.REASONS.none)))}function nr(){!tc||td||tW||eQ||nn()}(0,j.useValueChanged)(tE,function(){ty&&""!==tE&&tE!==String(tv)&&!tU&&eX(!0)}),(0,j.useValueChanged)(ty,function(){ty&&null!==eJ&&t5(!1)}),(0,j.useValueChanged)(tm,function(){"none"!==Z&&(eO(tl),eM((0,F.isSelectedValueDirty)(tm,eA.initialValue,ex)),eF.change(tm),!tc||td||tW||nn())}),(0,j.useValueChanged)(tR,nr),(0,j.useValueChanged)(eB,nr),(0,j.useValueChanged)(tb,function(){"none"===Z&&(eO(tl),eM(tb!==eA.initialValue),eF.change(tb))});let ni=(0,g.useFloatingRootContext)({open:!!tB||ty,onOpenChange:t6,elements:{reference:tW?tV:tq,floating:tF}}),no=ea?"grid":"listbox",ns=ty||tB,na=ns?"true":"false",nl=t.useMemo(()=>{let e=tq?.tagName==="INPUT",t=null==tq||e,n=t||ns,r=t?{autoComplete:"off",spellCheck:"false",autoCorrect:"off",autoCapitalize:"none"}:{};return n&&(r.role="combobox",r["aria-expanded"]=na,r["aria-haspopup"]=no,r["aria-controls"]=ns?tH?.id:void 0,r["aria-autocomplete"]=ei?"none":ew),{reference:r,floating:{role:"presentation"}}},[tq,ns,na,no,tH?.id,ew,ei]),nu=(0,v.useClick)(ni,{enabled:!ta&&ef,event:"mousedown-only",toggle:!1,touchOpenDelay:100*!tW,reason:S.REASONS.inputPress}),nc=(0,m.useDismiss)(ni,{enabled:!ta&&!tB,outsidePressEvent:{mouse:"sloppy",touch:"intentional"},bubbles:!!tB||void 0,outsidePress(e){let t=(0,x.getTarget)(e);return!(0,x.contains)(tV,t)&&!(0,x.contains)(tt.current,t)&&!(0,x.contains)(te.current,t)&&!(0,x.contains)(t_,t)}}),nd=(0,h.useListNavigation)(ni,{enabled:!ta,id:eV,listRef:e1,activeIndex:tD,selectedIndex:tz,virtual:!0,loopFocus:eh,allowEscape:eh&&!B,focusItemOnOpen:!eQ&&("none"!==Z||!!B)&&"auto",focusItemOnHover:eg,resetOnPointerLeave:!em,orientation:ea?"horizontal":void 0,rtl:"rtl"===eH,disabledIndices:f.EMPTY_ARRAY,grid:ea?b.gridNavigation:void 0,onNavigate(e,t){(t||ty)&&"ending"!==tQ&&(t?t4({activeIndex:e,type:e8.current?S.REASONS.keyboard:S.REASONS.pointer}):t4({activeIndex:e}))}}),nf=t.useMemo(()=>(0,D.mergeProps)(nd.reference,{onKeyDown(e){ea&&null==tA.state.activeIndex&&("ArrowLeft"===e.key||"ArrowRight"===e.key)&&e.preventBaseUIHandler()}},nc.reference,nu.reference,nl.reference),[nd.reference,nc.reference,nu.reference,nl.reference,ea,tA]),np=t.useMemo(()=>(0,D.mergeProps)(L.FOCUSABLE_POPUP_PROPS,nc.floating),[nc.floating]),nm=t.useMemo(()=>(0,D.mergeProps)(nd.floating,nl.floating),[nd.floating,nl.floating]),ng=t.useMemo(()=>{let e=nd.item;return e?{...e,onFocus:void 0}:f.EMPTY_OBJECT},[nd.item]);tA.useContextCallback("setOpen",t6),tA.useContextCallback("setInputValue",t2),tA.useContextCallback("setSelectedValue",t7),tA.useContextCallback("setIndices",t4),tA.useContextCallback("handleSelection",t3),tA.useContextCallback("forceMount",t0),tA.useContextCallback("requestSubmit",t8),tA.useContextCallback("onOpenChangeComplete",$),(0,o.useOnFirstRender)(()=>{tA.update({inline:eS,popupProps:np,listProps:nm,inputProps:nf,triggerProps:tJ,itemProps:ng})});let nh={id:eV,selectedValue:tm,open:ty,mounted:tG,transitionStatus:tQ,items:e$,inline:eS,popupProps:np,listProps:nm,inputProps:nf,triggerProps:tJ,itemProps:ng,openMethod:tX,selectionMode:Z,name:tl,form:en,disabled:ta,readOnly:ei,required:eo,grid:ea,virtualized:ey,openOnInputClick:ef,itemToStringLabel:eK,modal:eE,autoHighlight:B,isItemEqualToValue:ex,submitOnItemClick:ek,hasInputValue:td};(0,i.useIsoLayoutEffect)(()=>{tA.update({...nh,inputOwnsFormValue:"none"===Z&&(eS||!tA.state.inputInsidePopup)})},[tA,...Object.values(nh)]);let nv=(0,a.useMergedRefs)(es,eF.inputRef),nb=t.useMemo(()=>({query:tE,hasItems:tf,filteredItems:tO,flatFilteredValues:tM}),[tE,tf,tO,tM]),nx=t.useMemo(()=>Array.isArray(tP)?"":(0,z.stringifyAsValue)(tP,eb),[tP,eb]),ny=tu&&Array.isArray(tm)&&tm.length>0,nS=tu||"none"===Z&&t$?void 0:tl,nC=t.useMemo(()=>tu&&Array.isArray(tm)&&tl?tm.map(e=>{let t=(0,z.stringifyAsValue)(e,eb);return(0,_.jsx)("input",{type:"hidden",form:en,name:tl,value:t,disabled:ta},t)}):null,[tu,tm,en,tl,eb,ta]),nE=(0,_.jsxs)(t.Fragment,{children:[e.children,(0,_.jsx)("input",{...eF.getValidationProps(ta,{onFocus(){tW?tV?.focus():(e5.current||tV)?.focus()},onChange(e){if(e.nativeEvent.defaultPrevented||ta||ei)return;let t=e.currentTarget.value,n=t.toLowerCase(),r=(0,y.createChangeEventDetails)(S.REASONS.none,e.nativeEvent),i=()=>to.current.findIndex(e=>(0,z.stringifyAsValue)(e,eb).toLowerCase()===n||eY(e).toLowerCase()===n);tc&&(t0(),eB&&-1===i()&&tA.set("forceMounted",!0)),queueMicrotask(function(){if(tu)return;if("none"===Z)return void t2(t,r);let e=i();-1===e&&(e=to.current.findIndex((e,t)=>{let r=e4.current[t];return null!=r&&r.toLowerCase()===n}));let o=-1===e?void 0:to.current[e];null!=o&&t7?.(o,r)})}}),id:eV&&null==nS?`${eV}-hidden-input`:void 0,form:en,name:nS,autoComplete:eI,disabled:ta,required:eo&&!ny,readOnly:ei,value:nx,ref:nv,style:nS?u.visuallyHiddenInput:u.visuallyHidden,tabIndex:-1,"aria-hidden":!0,suppressHydrationWarning:!0}),nC]});return(0,_.jsx)(C.ComboboxRootContext.Provider,{value:tA,children:(0,_.jsx)(C.ComboboxFloatingContext.Provider,{value:ni,children:(0,_.jsx)(C.ComboboxHasItemsContext.Provider,{value:tf,children:(0,_.jsx)(C.ComboboxDerivedItemsContext.Provider,{value:nb,children:(0,_.jsx)(C.ComboboxInputValueContext.Provider,{value:tb,children:nE})})})})})}e.s(["ComboboxRoot",0,function(e){let{multiple:t=!1,defaultValue:n,value:r,onValueChange:i,autoComplete:o,...s}=e;return(0,_.jsx)(B,{...s,selectionMode:t?"multiple":"single",selectedValue:r,defaultSelectedValue:n,onSelectedValueChange:i,formAutoComplete:o})}],45654)},62156,36523,56970,96545,61919,e=>{"use strict";var t=e.i(84325),n=e.i(42191);function r(e,t){return(n,r)=>null!=n&&e.contains(n,r,t)}function i(e,t,r){return(i,o)=>{if(null==i)return!1;if(!o)return!0;let s=t?.selected??t,a=null!=r?(0,n.stringifyAsLabel)(r,s):"";return!!(a&&e.contains(a,o))&&a.length===o.length||e.contains(i,o,t)}}e.s(["selectors",0,{id:e=>e.id,labelId:e=>e.labelId,items:e=>e.items,selectedValue:e=>e.selectedValue,hasSelectionChips:e=>{let t=e.selectedValue;return Array.isArray(t)&&t.length>0},hasSelectedValue:e=>{let{selectedValue:t,selectionMode:n}=e;return null!=t&&(!("multiple"===n&&Array.isArray(t))||t.length>0)},hasNullItemLabel:(e,t)=>!!t&&(0,n.hasNullItemLabel)(e.items),open:e=>e.open,mounted:e=>e.mounted,forceMounted:e=>e.forceMounted,inline:e=>e.inline,activeIndex:e=>e.activeIndex,selectedIndex:e=>e.selectedIndex,isActive:(e,t)=>e.activeIndex===t,isSelected:(e,n)=>{let r=e.isItemEqualToValue,i=e.selectedValue;return Array.isArray(i)?i.some(e=>(0,t.compareItemEquality)(n,e,r)):(0,t.compareItemEquality)(n,i,r)},transitionStatus:e=>e.transitionStatus,popupProps:e=>e.popupProps,listProps:e=>e.listProps,inputProps:e=>e.inputProps,triggerProps:e=>e.triggerProps,itemProps:e=>e.itemProps,positionerElement:e=>e.positionerElement,listElement:e=>e.listElement,popupId:e=>e.popupId,triggerElement:e=>e.triggerElement,inputElement:e=>e.inputElement,inputGroupElement:e=>e.inputGroupElement,popupSide:e=>e.popupSide,openMethod:e=>e.openMethod,inputInsidePopup:e=>e.inputInsidePopup,inputOwnsFormValue:e=>e.inputOwnsFormValue,selectionMode:e=>e.selectionMode,name:e=>e.name,form:e=>e.form,disabled:e=>e.disabled,readOnly:e=>e.readOnly,required:e=>e.required,grid:e=>e.grid,virtualized:e=>e.virtualized,itemToStringLabel:e=>e.itemToStringLabel,isItemEqualToValue:e=>e.isItemEqualToValue,modal:e=>e.modal,autoHighlight:e=>e.autoHighlight}],62156),e.s(["createCollatorItemFilter",0,r,"createSingleSelectionCollatorFilter",0,i,"getComboboxPopupId",0,function(e){return null==e?void 0:`${e}-popup`}],36523);var o=e.i(71645);let s=new Map;function a(e={}){let t={usage:"search",sensitivity:"base",ignorePunctuation:!0,...e},r=`${function e(t){return Array.isArray(t)?t.map(t=>e(t)).join(","):null==t?"":String(t)}(e.locale)}|${JSON.stringify(t)}`,i=s.get(r);if(i)return i;let o=new Intl.Collator(e.locale,t),l={contains(e,t,r){if(!t)return!0;let i=(0,n.stringifyAsLabel)(e,r);for(let e=0;e<=i.length-t.length;e+=1)if(0===o.compare(i.slice(e,e+t.length),t))return!0;return!1},startsWith(e,t,r){if(!t)return!0;let i=(0,n.stringifyAsLabel)(e,r);return 0===o.compare(i.slice(0,t.length),t)},endsWith(e,t,r){if(!t)return!0;let i=(0,n.stringifyAsLabel)(e,r),s=t.length;return i.length>=s&&0===o.compare(i.slice(i.length-s),t)}};return s.set(r,l),l}e.s(["useComboboxFilter",0,function(e={}){let{multiple:t=!1,value:n,...s}=e,l=a(s),u=o.useCallback((e,o,s)=>t?r(l,s)(e,o):i(l,s,n)(e,o),[l,n,t]);return o.useMemo(()=>({...l,contains:u}),[u,l])},"useCoreFilter",0,a],56970);var l=e.i(29315);e.s(["isScrollableY",0,function(e,t=!1){let{overflowY:n}=(0,l.getComputedStyle)(e);return("auto"===n||"scroll"===n)&&(t?e.clientHeight>0:e.scrollHeight>e.clientHeight)}],96545);let u=Symbol("none");e.s(["INITIAL_LAST_HIGHLIGHT",0,{value:u,index:-1},"NO_ACTIVE_VALUE",0,u],61919)},56212,76459,87445,e=>{"use strict";var t=e.i(71645),n=e.i(67865),r=e.i(39957),i=e.i(8868),o=e.i(52245),s=e.i(40886),a=e.i(2672),l=e.i(47018),u=e.i(69690),c=e.i(47778),d=e.i(57940),f=e.i(84446),p=e.i(64042),m=e.i(75606),g=e.i(56434),h=e.i(85689),v=e.i(5049),b=e.i(38489),x=e.i(50001),y=e.i(36523),S=e.i(97464);let C=t.forwardRef(function(e,C){let E,{render:R,className:w,nativeButton:I=!0,disabled:T=!1,id:k,style:O,...M}=e,{state:A,disabled:P,setTouched:N,setFocused:j,validationMode:L,validation:D}=(0,u.useFieldRootContext)(),{labelId:z}=(0,c.useLabelableContext)(),F=(0,a.useComboboxRootContext)(),H=F.useState("selectionMode"),V=F.useState("disabled"),q=F.useState("readOnly"),_=F.useState("required"),B=F.useState("positionerElement"),W=F.useState("listElement"),$=F.useState("popupId"),U=F.useState("triggerProps"),K=F.useState("inputInsidePopup"),G=F.useState("id"),Y=F.useState("labelId"),Q=F.useState("open"),X=F.useState("selectedValue"),J=F.useState("activeIndex"),Z=F.useState("selectedIndex"),ee=F.useState("hasSelectedValue"),et=(0,a.useComboboxFloatingContext)(),en=(0,a.useComboboxInputValueContext)(),er=(0,r.useTimeout)(),ei=P||V||T,eo=(0,S.useListEmpty)(),es=(0,S.usePopupSide)(F);(0,b.useLabelableId)({id:K?k:void 0});let ea=K?k??G:k,el=(0,x.resolveAriaLabelledBy)(z,Y);Q&&K?E=$??(0,y.getComboboxPopupId)(G):Q&&(E=W?.id);let eu=t.useRef("");function ec(e){eu.current=e.pointerType}let{reference:ed}=(0,v.useTypeahead)(et,{enabled:!Q&&!q&&!V&&"single"===H,listRef:F.context.labelsRef,activeIndex:J,selectedIndex:Z,onMatch(e){let t=F.context.valuesRef.current[e];void 0!==t&&F.context.setSelectedValue(t,(0,m.createChangeEventDetails)(g.REASONS.none))}}),{reference:ef}=(0,h.useClick)(et,{enabled:!V,event:"mousedown"}),{buttonRef:ep,getButtonProps:em}=(0,s.useButton)({native:I,disabled:ei}),eg={...A,readOnly:q,open:Q,disabled:ei,popupSide:es,listEmpty:eo,placeholder:"none"!==H&&!ee},eh=(0,n.useStableCallback)(e=>{F.set("triggerElement",e)});return(0,o.useRenderElement)("button",e,{ref:[C,ep,eh],state:eg,props:[U,ef,ed,{id:ea,tabIndex:K?0:-1,role:K?"combobox":void 0,"aria-expanded":Q,"aria-haspopup":K?"dialog":"listbox","aria-controls":E,"aria-required":K&&_||void 0,"aria-readonly":K&&q||void 0,"aria-labelledby":el,onPointerDown:ec,onPointerEnter:ec,onFocus(){j(!0),ei||er.start(0,F.context.forceMount)},onBlur(e){(0,f.contains)(B,e.relatedTarget)||(N(!0),j(!1),"onBlur"===L&&D.commit("none"===H?en:X))},onMouseDown(e){if(ei||(K||et.set("domReferenceElement",e.currentTarget),F.context.forceMount(),"touch"!==eu.current&&(F.context.inputRef.current?.focus(),K||e.preventDefault()),Q))return;let t=(0,i.ownerDocument)(e.currentTarget);K&&t.addEventListener("mouseup",function(e){let t=F.state.triggerElement;if(!t)return;let n=(0,f.getTarget)(e),r=F.state.positionerElement,i=F.state.listElement;(0,f.contains)(t,n)||(0,f.contains)(r,n)||(0,f.contains)(i,n)||(0,p.isMouseWithinBounds)(e,t)||F.context.setOpen(!1,(0,m.createChangeEventDetails)(g.REASONS.cancelOpen,e))},{once:!0})},onKeyDown(e){("ArrowDown"===e.key||"ArrowUp"===e.key)&&((0,d.stopEvent)(e),F.context.setOpen(!0,(0,m.createChangeEventDetails)(g.REASONS.listNavigation,e.nativeEvent)),F.context.inputRef.current?.focus())}},D.getValidationProps(ei,M),em],stateAttributesMapping:l.triggerStateAttributesMapping})});e.s(["ComboboxTrigger",0,C],56212);var E=e.i(43476);let R=t.createContext(null);function w(){return t.useContext(R)}e.s(["GroupCollectionProvider",0,function(e){let{children:n,items:r}=e,i=t.useMemo(()=>({items:r}),[r]);return(0,E.jsx)(R.Provider,{value:i,children:n})},"useGroupCollectionContext",0,w],76459),e.s(["ComboboxCollection",0,function(e){let{children:n}=e,{filteredItems:r}=(0,a.useComboboxDerivedItemsContext)(),i=w(),o=i?i.items:r;return(0,E.jsx)(t.Fragment,{children:o.map(n)})}],87445)},2820,56736,9793,e=>{"use strict";var t=e.i(71645),n=e.i(8821),r=e.i(52245),i=e.i(79938);let o=t.forwardRef(function(e,t){let{render:o,className:s,style:a,forceRender:l=!1,...u}=e,c=(0,n.useDialogRootContext)(),d=c.useState("open"),f=c.useState("nested"),p=c.useState("mounted"),m=c.useState("transitionStatus");return(0,r.useRenderElement)("div",e,{state:{open:d,transitionStatus:m},ref:[c.context.backdropRef,t],stateAttributesMapping:i.popupTransitionStateMapping,props:[{role:"presentation",hidden:!p,style:{userSelect:"none",WebkitUserSelect:"none"}},u],enabled:l||!f})});e.s(["DialogBackdrop",0,o],2820);var s=e.i(40886),a=e.i(75606),l=e.i(56434);let u=t.forwardRef(function(e,t){let{render:i,className:o,style:u,disabled:c=!1,nativeButton:d=!0,...f}=e,p=(0,n.useDialogRootContext)(),m=p.useState("open"),{getButtonProps:g,buttonRef:h}=(0,s.useButton)({disabled:c,native:d});return(0,r.useRenderElement)("button",e,{state:{disabled:c},ref:[t,h],props:[{onClick:function(e){m&&p.setOpen(!1,(0,a.createChangeEventDetails)(l.REASONS.closePress,e.nativeEvent))}},f,g]})});e.s(["DialogClose",0,u],56736);var c=e.i(88015);let d=t.forwardRef(function(e,t){let{render:i,className:o,style:s,id:a,...l}=e,u=(0,n.useDialogRootContext)(),d=(0,c.useBaseUiId)(a);return u.useSyncedValueWithCleanup("descriptionElementId",d),(0,r.useRenderElement)("p",e,{ref:t,props:[{id:d},l]})});e.s(["DialogDescription",0,d],9793)},84324,10199,e=>{"use strict";var t=e.i(71645),n=e.i(61487),r=e.i(8821),i=e.i(52245),o=e.i(25834),s=e.i(37584),a=e.i(73327),l=e.i(64111),u=e.i(74354),c=e.i(79938),d=e.i(38380),d=d;d.open,d.closed,d.startingStyle,d.endingStyle;let f={...c.popupStateMapping,...u.transitionStatusMapping,nestedDialogOpen:e=>e?{"data-nested-dialog-open":""}:null};e.s(["dialogStateAttributesMapping",0,f],10199);var p=e.i(43476);let m=t.forwardRef(function(e,t){let{render:u,className:c,style:d,finalFocus:m,initialFocus:g,...h}=e,v=(0,r.useDialogRootContext)(),b=v.useState("descriptionElementId"),x=v.useState("disablePointerDismissal"),y=v.useState("floatingRootContext"),S=v.useState("popupProps"),C=v.useState("modal"),E=v.useState("mounted"),R=v.useState("nested"),w=v.useState("nestedOpenDialogCount"),I=v.useState("open"),T=v.useState("openMethod"),k=v.useState("titleElementId"),O=v.useState("transitionStatus"),M=v.useState("role"),A=y.useState("floatingId");(0,o.useDialogPortalContext)(),(0,s.useOpenChangeComplete)({open:I,ref:v.context.popupRef,onComplete(){I&&v.context.onOpenChangeComplete?.(!0)}});let P=void 0===g?(0,l.createDefaultInitialFocus)(v.context.popupRef):g,N=v.useStateSetter("popupElement"),j=(0,i.useRenderElement)("div",e,{state:{open:I,nested:R,transitionStatus:O,nestedDialogOpen:w>0},props:[S,{id:A,"aria-labelledby":k,"aria-describedby":b,role:M,...l.FOCUSABLE_POPUP_PROPS,hidden:!E,onKeyDown(e){a.COMPOSITE_KEYS.has(e.key)&&e.stopPropagation()},style:{"--nested-dialogs":w}},h],ref:[t,v.context.popupRef,N],stateAttributesMapping:f});return(0,p.jsx)(n.FloatingFocusManager,{context:y,openInteractionType:T,disabled:!E,closeOnFocusOut:!x,initialFocus:P,returnFocus:m,modal:!1!==C,restoreFocus:"popup",children:j})});e.s(["DialogPopup",0,m],84324)},64951,e=>{"use strict";e.i(47167);var t=e.i(71645),n=e.i(44394),r=e.i(26674),i=e.i(8821),o=e.i(25834),s=e.i(426),a=e.i(43476);let l=t.forwardRef(function(e,t){let{keepMounted:l=!1,...u}=e,c=(0,i.useDialogRootContext)(),d=c.useState("mounted"),f=c.useState("modal"),p=c.useState("open");return d||l?(0,a.jsx)(o.DialogPortalContext.Provider,{value:l,children:(0,a.jsxs)(r.FloatingPortal,{ref:t,...u,children:[d&&!0===f&&(0,a.jsx)(s.InternalBackdrop,{ref:c.context.internalBackdropRef,inert:(0,n.inertValue)(!p)}),e.children]})}):null});e.s(["DialogPortal",0,l])},25834,e=>{"use strict";e.i(47167);var t=e.i(33332),n=e.i(71645);let r=n.createContext(void 0);e.s(["DialogPortalContext",0,r,"useDialogPortalContext",0,function(){let e=n.useContext(r);if(void 0===e)throw Error((0,t.default)(26));return e}])},50440,1807,66250,74217,77173,59636,e=>{"use strict";var t=e.i(96499),n=e.i(71645),r=e.i(67530),i=e.i(8821),o=e.i(26352),s=e.i(18478),a=e.i(16786),l=e.i(90627),u=e.i(64111);let c={...a.popupStoreSelectors,modal:e=>e.modal,nested:e=>e.nested,nestedOpenDialogCount:e=>e.nestedOpenDialogCount,nestedOpenDrawerCount:e=>e.nestedOpenDrawerCount,disablePointerDismissal:e=>e.disablePointerDismissal,openMethod:e=>e.openMethod,descriptionElementId:e=>e.descriptionElementId,titleElementId:e=>e.titleElementId,viewportElement:e=>e.viewportElement,role:e=>e.role};class d extends o.ReactStore{constructor(e,t,n){const r=new l.PopupTriggerMap;super(f(e,r,t,n),p(r),c)}setOpen=(e,t)=>{t.preventUnmountOnClose=()=>{this.set("preventUnmountingOnClose",!0)},e||null!=t.trigger||null==this.state.activeTriggerId||(t.trigger=this.state.activeTriggerElement??void 0),this.context.onOpenChange?.(e,t),t.isCanceled||(this.state.floatingRootContext.dispatchOpenChange(e,t),this.update((0,u.createPopupOpenState)(this.state,e,t.trigger)))}}function f(e,t,n,r=!1){return{...(0,a.createInitialPopupStoreState)(t,n,r),modal:!0,disablePointerDismissal:!1,viewportElement:null,descriptionElementId:void 0,titleElementId:void 0,openMethod:null,nested:!1,nestedOpenDialogCount:0,nestedOpenDrawerCount:0,role:"dialog",...e}}function p(e){return{popupRef:n.createRef(),backdropRef:n.createRef(),internalBackdropRef:n.createRef(),outsidePressEnabledRef:{current:!0},triggerElements:e,onOpenChange:void 0,onOpenChangeComplete:void 0}}e.s(["DialogStore",0,d,"createNullDialogStore",0,function(){let e=new l.PopupTriggerMap;return new s.NullStore(Object.freeze(f(void 0,e)),Object.freeze(p(e)),c)}],1807);var m=e.i(75606),g=e.i(56434),h=e.i(43476);function v(e,t){let{children:o,open:s,defaultOpen:a=!1,onOpenChange:l,onOpenChangeComplete:c,disablePointerDismissal:f=!1,modal:p=!0,actionsRef:v,handle:b,triggerId:x,defaultTriggerId:y=null}=t,S="alert-dialog"===e,C=(0,i.useDialogRootContext)(!0),E={modal:!!S||p,disablePointerDismissal:S||f,nested:null!=C,role:S?"alertdialog":"dialog"},R=(0,u.usePopupRootStore)((e,t)=>new d({open:a,openProp:s,activeTriggerId:y,triggerIdProp:x,...E},e,t),!0);R.useControlledProp("openProp",s),R.useControlledProp("triggerIdProp",x),R.useSyncedValues(E),R.useContextCallback("onOpenChange",l),R.useContextCallback("onOpenChangeComplete",c);let w=R.useState("open"),I=R.useState("mounted"),T=R.useState("payload");(0,u.usePopupRootSync)(R,w),(0,u.useImplicitActiveTrigger)(R);let{forceUnmount:k}=(0,u.useOpenStateTransitions)(w,R);n.useImperativeHandle(v,()=>({unmount:k,close:()=>R.setOpen(!1,(0,m.createChangeEventDetails)(g.REASONS.imperativeAction))}),[k,R]);let O=w||I;return(0,h.jsxs)(i.DialogRootContext.Provider,{value:R,children:[b&&(0,h.jsx)(u.PopupHandleAttachment,{handle:b,store:R}),O&&(0,h.jsx)(r.DialogInteractions,{store:R,parentContext:C?.context,isDrawer:"drawer"===e}),"function"==typeof o?o({payload:T}):o]})}e.s(["useRenderDialogRoot",0,v],66250);let b=(0,t.fastComponent)(function(e){return v("dialog",e)});e.s(["DialogRoot",0,b],50440);var x=e.i(52245),y=e.i(25834),S=e.i(10199);let C=n.forwardRef(function(e,t){let{render:n,className:r,style:o,children:s,...a}=e,l=(0,y.useDialogPortalContext)(),u=(0,i.useDialogRootContext)(),c=u.useState("open"),d=u.useState("nested"),f=u.useState("transitionStatus"),p=u.useState("nestedOpenDialogCount"),m=u.useState("mounted"),g=u.useStateSetter("viewportElement");return(0,x.useRenderElement)("div",e,{enabled:l||m,state:{open:c,nested:d,transitionStatus:f,nestedDialogOpen:p>0},ref:[t,g],stateAttributesMapping:S.dialogStateAttributesMapping,props:[{role:"presentation",hidden:!m,style:{pointerEvents:c?void 0:"none"},children:s},a]})});e.s(["DialogViewport",0,C],74217);var E=e.i(88015);let R=n.forwardRef(function(e,t){let{render:n,className:r,style:o,id:s,...a}=e,l=(0,i.useDialogRootContext)(),u=(0,E.useBaseUiId)(s);return l.useSyncedValueWithCleanup("titleElementId",u),(0,x.useRenderElement)("h2",e,{ref:t,props:[{id:u},a]})});e.s(["DialogTitle",0,R],77173);var w=e.i(2239),I=e.i(56789);e.s(["usePopupHandleStore",0,function(e){let t=n.useCallback(t=>void 0===e?I.NOOP:e.subscribeStore(t),[e]),r=n.useCallback(()=>void 0===e?void 0:e.store,[e]);return(0,w.useSyncExternalStore)(t,r,()=>e?.serverStore)}],59636)},67530,18478,16786,e=>{"use strict";var t=e.i(71645),n=e.i(46376),r=e.i(45484),i=e.i(17989),o=e.i(84446),s=e.i(64111);e.s(["DialogInteractions",0,function({store:e,parentContext:a,isDrawer:l}){let u=e.useState("open"),c=e.useState("disablePointerDismissal"),d=e.useState("modal"),f=e.useState("popupElement"),p=e.useState("floatingRootContext"),[m,g]=t.useState(0),[h,v]=t.useState(0),b=0===m,x=(0,i.useDismiss)(p,{outsidePressEvent:()=>e.context.internalBackdropRef.current||e.context.backdropRef.current?"intentional":{mouse:"trap-focus"===d?"sloppy":"intentional",touch:"sloppy"},outsidePress(t){if(!e.context.outsidePressEnabledRef.current||"button"in t&&0!==t.button)return!1;if("touches"in t){if("touchend"===t.type){if(1!==t.changedTouches.length||0!==t.touches.length)return!1}else if(1!==t.touches.length)return!1}let n=(0,o.getTarget)(t);if(b&&!c){if(d){let t=e.context.internalBackdropRef.current,r=e.context.backdropRef.current;return!t&&!r||t===n||r===n||(0,o.contains)(n,f)&&!n?.hasAttribute("data-base-ui-portal")}return!0}return!1},escapeKey:b});return(0,r.useScrollLock)(u&&!0===d,f),e.useContextCallback("onNestedDialogOpen",(e,t)=>{g(e),v(t)}),(0,n.useIsoLayoutEffect)(()=>(a?.onNestedDialogOpen&&(u?a.onNestedDialogOpen(m+1,h+ +!!l):a.onNestedDialogOpen(0,0)),()=>{a?.onNestedDialogOpen&&u&&a.onNestedDialogOpen(0,0)}),[l,u,m,h,a]),(0,s.usePopupInteractionProps)(e,{activeTriggerProps:x.reference,inactiveTriggerProps:x.trigger,popupProps:x.floating,nestedOpenDialogCount:m,nestedOpenDrawerCount:h}),null}],67530);var a=e.i(26352);class l extends a.ReactStore{setState(e){}update(e){}set(e,t){}notifyAll(){}}e.s(["NullStore",0,l],18478);var u=e.i(56789),c=e.i(56341);let d=e=>e.triggerIdProp??e.activeTriggerId,f=e=>e.openProp??e.open,p=e=>(e.popupElement?.id??e.floatingId)||void 0;function m(e,t){return void 0!==t&&f(e)&&d(e)===t}e.s(["createInitialPopupStoreState",0,function(e,t,n=!1){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:new c.FloatingRootStore({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:n,onOpenChange:void 0}),floatingId:t,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:u.EMPTY_OBJECT,inactiveTriggerProps:u.EMPTY_OBJECT,popupProps:u.EMPTY_OBJECT}},"popupStoreSelectors",0,{open:f,mounted:e=>e.mounted,transitionStatus:e=>e.transitionStatus,floatingRootContext:e=>e.floatingRootContext,triggerCount:e=>e.triggerCount,preventUnmountingOnClose:e=>e.preventUnmountingOnClose,payload:e=>e.payload,activeTriggerId:d,activeTriggerElement:e=>e.mounted?e.activeTriggerElement:null,popupId:p,isTriggerActive:(e,t)=>void 0!==t&&d(e)===t,isOpenedByTrigger:(e,t)=>m(e,t),isMountedByTrigger:(e,t)=>void 0!==t&&d(e)===t&&e.mounted,triggerProps:(e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps,triggerPopupId:(e,t)=>m(e,t)||void 0!==t&&f(e)&&null==d(e)&&1===e.triggerCount?p(e):void 0,popupProps:e=>e.popupProps,popupElement:e=>e.popupElement,positionerElement:e=>e.positionerElement}],16786)},61487,e=>{"use strict";var t=e.i(71645),n=e.i(29315),r=e.i(74735),i=e.i(65420),o=e.i(28918),s=e.i(46265),a=e.i(67865),l=e.i(46376),u=e.i(39957),c=e.i(28744),d=e.i(8445),f=e.i(8868),p=e.i(33848),m=e.i(52535),g=e.i(84446),h=e.i(96296),v=e.i(57940),b=e.i(83976),x=e.i(58408),y=e.i(21082),S=e.i(75606),C=e.i(56434),E=e.i(51321),R=e.i(3596),w=e.i(44659),I=e.i(26674),T=e.i(46420),k=e.i(38396),O=e.i(94603),M=e.i(43476);let A=[];function P(){A=A.filter(e=>e.deref()?.isConnected)}function N(e){P(),e&&"body"!==(0,n.getNodeName)(e)&&(A.push(new WeakRef(e)),A.length>20&&(A=A.slice(-20)))}function j(){return P(),A[A.length-1]?.deref()}function L(e){if(e.hasAttribute("tabindex")&&!e.hasAttribute("data-tabindex")||!e.getAttribute("role")?.includes("dialog"))return;let t=(0,b.focusable)(e).filter(e=>{let t=e.getAttribute("data-tabindex")||"";return(0,b.isTabbable)(e)||e.hasAttribute("data-tabindex")&&!t.startsWith("-")}),n=e.getAttribute("tabindex");0===t.length?"0"!==n&&(e.setAttribute("tabindex","0"),e.setAttribute("data-tabindex","0")):("-1"!==n||e.hasAttribute("data-tabindex")&&"-1"!==e.getAttribute("data-tabindex"))&&(e.setAttribute("tabindex","-1"),e.setAttribute("data-tabindex","-1"))}e.s(["FloatingFocusManager",0,function(e){let{context:A,children:D,disabled:z=!1,initialFocus:F=!0,returnFocus:H=!0,restoreFocus:V=!1,modal:q=!0,closeOnFocusOut:_=!0,openInteractionType:B="",nextFocusableElement:W,previousFocusableElement:$,beforeContentFocusGuardRef:U,externalTree:K,getInsideElements:G}=e,Y="rootStore"in A?A.rootStore:A,Q=Y.useState("open"),X=Y.useState("domReferenceElement"),J=Y.useState("floatingElement"),{events:Z,dataRef:ee}=Y.context,et=(0,a.useStableCallback)(()=>ee.current.floatingContext?.nodeId),en=(0,h.isTypeableCombobox)(X)&&!1===F,er=(0,s.useValueAsRef)(F),ei=(0,s.useValueAsRef)(H),eo=(0,s.useValueAsRef)(B),es=(0,s.useValueAsRef)(Q),ea=(0,T.useFloatingTree)(K),el=(0,I.usePortalContext)(),eu=t.useRef(!1),ec=t.useRef(!1),ed=t.useRef(!1),ef=t.useRef(null),ep=t.useRef(""),em=t.useRef(""),eg=t.useRef(null),eh=t.useRef(null),ev=(0,o.useMergedRefs)(eg,U,el?.beforeInsideRef),eb=(0,o.useMergedRefs)(eh,el?.afterInsideRef),ex=(0,u.useTimeout)(),ey=(0,u.useTimeout)(),eS=(0,d.useAnimationFrame)(),eC=null!=el,eE=(0,h.getFloatingFocusElement)(J),eR=(0,a.useStableCallback)((e=eE)=>e?(0,b.tabbable)(e):[]),ew=(0,a.useStableCallback)(()=>G?.().filter(e=>null!=e)??[]);t.useEffect(()=>{if(z||!q)return;let e=(0,f.ownerDocument)(eE);return(0,r.addEventListener)(e,"keydown",function(e){"Tab"===e.key&&(0,g.contains)(eE,(0,g.activeElement)((0,f.ownerDocument)(eE)))&&0===eR().length&&!en&&(0,v.stopEvent)(e)})},[z,eE,q,en,eR]),t.useEffect(()=>{if(z||!Q)return;let e=(0,f.ownerDocument)(eE);function t(){ed.current=!1}return(0,i.mergeCleanups)((0,r.addEventListener)(e,"pointerdown",function(e){let t=(0,g.getTarget)(e),n=ew();ed.current=!((0,g.contains)(J,t)||(0,g.contains)(X,t)||(0,g.contains)(el?.portalNode,t)||n.some(e=>e===t||(0,g.contains)(e,t))),em.current=e.pointerType||"keyboard",t?.closest(`[${k.CLICK_TRIGGER_IDENTIFIER}]`)&&(ec.current=!0,ey.start(0,()=>{ec.current=!1}))},!0),(0,r.addEventListener)(e,"pointerup",t,!0),(0,r.addEventListener)(e,"pointercancel",t,!0),(0,r.addEventListener)(e,"keydown",function(){em.current="keyboard"},!0),t)},[z,J,X,eE,Q,el,ey,ew]),t.useEffect(()=>{if(z||!_)return;let e=(0,f.ownerDocument)(eE);function t(t){let r=t.relatedTarget,i=t.currentTarget,o=(0,g.getTarget)(t);q&&null==r&&null!=o&&(0,g.contains)(J,o)&&N(o),queueMicrotask(()=>{let s=et(),a=Y.context.triggerElements,l=ew(),u=r?.hasAttribute((0,E.createAttribute)("focus-guard"))&&[eg.current,eh.current,el?.beforeInsideRef.current,el?.afterInsideRef.current,el?.beforeOutsideRef.current,el?.afterOutsideRef.current,(0,O.resolveRef)($),(0,O.resolveRef)(W)].includes(r),c=!((0,g.contains)(X,r)||(0,g.contains)(J,r)||(0,g.contains)(r,J)||(0,g.contains)(el?.portalNode,r)||l.some(e=>e===r||(0,g.contains)(e,r))||a.hasMatchingElement(e=>(0,g.contains)(e,r))||u||ea&&((0,x.getNodeChildren)(ea.nodesRef.current,s).find(e=>(0,g.contains)(e.context?.elements.floating,r)||(0,g.contains)(e.context?.elements.domReference,r))||(0,x.getNodeAncestors)(ea.nodesRef.current,s).find(e=>[e.context?.elements.floating,(0,h.getFloatingFocusElement)(e.context?.elements.floating)].includes(r)||e.context?.elements.domReference===r)));if(i===X&&eE&&L(eE),V&&i!==X&&!(0,y.isElementVisible)(o)&&(0,g.activeElement)(e)===e.body){if((0,n.isHTMLElement)(eE)&&(eE.focus(),"popup"===V))return void eS.request(()=>{eE.focus()});let e=eR(),t=ef.current,r=(t&&e.includes(t)?t:null)||e[e.length-1]||eE;(0,n.isHTMLElement)(r)&&r.focus()}if(ee.current.insideReactTree){ee.current.insideReactTree=!1;return}(en||!q)&&r&&c&&!ec.current&&(en||r!==j())&&(eu.current=!0,Y.setOpen(!1,(0,S.createChangeEventDetails)(C.REASONS.focusOut,t)))})}let o=(0,n.isHTMLElement)(X)?X:null;if(J||o)return(0,i.mergeCleanups)(o&&(0,r.addEventListener)(o,"focusout",t),o&&(0,r.addEventListener)(o,"pointerdown",function(){ec.current=!0,ey.start(0,()=>{ec.current=!1})}),J&&(0,r.addEventListener)(J,"focusin",function(e){let t=(0,g.getTarget)(e);(0,b.isTabbable)(t)&&(ef.current=t)}),J&&(0,r.addEventListener)(J,"focusout",t),J&&el&&(0,r.addEventListener)(J,"focusout",function(){ed.current||(ee.current.insideReactTree=!0,ex.start(0,()=>{ee.current.insideReactTree=!1}))},!0))},[z,X,J,eE,q,ea,el,Y,_,V,eR,en,et,ee,ex,ey,eS,W,$,ew]),t.useEffect(()=>{if(z||!J||!Q)return;let e=Array.from(el?.portalNode?.querySelectorAll(`[${(0,E.createAttribute)("portal")}]`)||[]),t=ea?(0,x.getNodeAncestors)(ea.nodesRef.current,et()):[],n=t.find(e=>(0,h.isTypeableCombobox)(e.context?.elements.domReference||null))?.context?.elements.domReference,r=[J,...e,eg.current,eh.current,el?.beforeOutsideRef.current,el?.afterOutsideRef.current,...ew(),n,(0,O.resolveRef)($),(0,O.resolveRef)(W),en?X:null].filter(e=>null!=e),i=(0,w.markOthers)(r,{ariaHidden:q||en,mark:!1}),o=[J,...e].filter(e=>null!=e),s=(0,w.markOthers)(o);return()=>{s(),i()}},[Q,z,X,J,q,el,en,ea,et,W,$,ew]),(0,l.useIsoLayoutEffect)(()=>{if(!Q||z||!(0,n.isHTMLElement)(eE))return;ep.current="",em.current="";let e=(0,f.ownerDocument)(eE),t=(0,g.activeElement)(e);queueMicrotask(()=>{let n,r=er.current,i="function"==typeof r?r(eo.current||""):r;if(void 0===i||!1===i||(0,g.contains)(eE,t))return;let o=null,s=()=>(null==o&&(o=eR(eE)),o[0]||eE);n=(n=!0===i||null===i?s():(0,O.resolveRef)(i))||s();let a=(0,g.contains)(eE,(0,g.activeElement)(e));(0,R.enqueueFocus)(n,{preventScroll:n===eE,shouldFocus(){if(!es.current)return!1;if(a)return!0;let t=(0,g.activeElement)(e);return!(t!==n&&(0,g.contains)(eE,t))}})})},[z,Q,eE,eR,er,eo,es]),(0,l.useIsoLayoutEffect)(()=>{if(z||!eE)return;let e=(0,f.ownerDocument)(eE),t=(0,g.activeElement)(e),r=null==eo.current;function i(e){var t,n;let r;if(e.open||(t=e.nativeEvent,n=em.current,r=(0,p.ownerWindow)((0,g.getTarget)(t)),ep.current=t instanceof r.KeyboardEvent?"keyboard":t instanceof r.FocusEvent?n||"keyboard":"pointerType"in t?t.pointerType||"keyboard":"touches"in t?"touch":t instanceof r.MouseEvent?n||(0===t.detail?"keyboard":"mouse"):""),e.reason===C.REASONS.triggerHover&&"mouseleave"===e.nativeEvent.type&&(eu.current=!0),e.reason===C.REASONS.outsidePress)if(e.nested)eu.current=!1;else if((0,v.isVirtualClick)(e.nativeEvent)||(0,v.isVirtualPointerEvent)(e.nativeEvent))eu.current=!1;else{let e=!1;(0,f.ownerDocument)(eE).createElement("div").focus({get preventScroll(){return e=!0,!1}}),e?eu.current=!1:eu.current=!0}}return N(t),Z.on("openchange",i),()=>{Z.off("openchange",i);let o=(0,g.activeElement)(e),s=ew(),a=(0,g.contains)(J,o)||s.some(e=>e===o||(0,g.contains)(e,o))||ea&&(0,x.getNodeChildren)(ea.nodesRef.current,et(),!1).some(e=>(0,g.contains)(e.context?.elements.floating,o)),l=ei.current,u=ep.current,c=function(e){let i=ei.current,o="function"==typeof i?i(e):i;if(void 0===o||!1===o)return null;null===o&&(o=!0);let s=X?.isConnected?X:null,a=t?.isConnected&&"body"!==(0,n.getNodeName)(t)?t:null,l=r?a||s:s||a;return(l||(l=j()||null),"boolean"==typeof o)?l:(0,O.resolveRef)(o)||l||null}(u);queueMicrotask(()=>{let t=c?(0,b.isTabbable)(c)?c:(0,b.tabbable)(c)[0]||c:null;if(l&&!eu.current&&(0,n.isHTMLElement)(t)&&("boolean"!=typeof l||t===o||o===e.body||a)){let e={preventScroll:!0};"keyboard"===u&&(e.focusVisible=!0),t.focus(e)}eu.current=!1})}},[z,J,eE,ei,eo,Z,ea,X,et,ew]),(0,l.useIsoLayoutEffect)(()=>{if(!c.platform.engine.webkit||Q||!J)return;let e=(0,g.activeElement)((0,f.ownerDocument)(J));(0,n.isHTMLElement)(e)&&(0,h.isTypeableElement)(e)&&(0,g.contains)(J,e)&&e.blur()},[Q,J]),(0,l.useIsoLayoutEffect)(()=>{if(!z&&el)return el.setFocusManagerState({modal:q,closeOnFocusOut:_,open:Q,onOpenChange:Y.setOpen,domReference:X}),()=>{el.setFocusManagerState(null)}},[z,el,q,Q,Y,_,X]),(0,l.useIsoLayoutEffect)(()=>{if(!z&&eE)return L(eE),()=>{queueMicrotask(P)}},[z,eE]);let eI=!z&&(!q||!en)&&(eC||q);return(0,M.jsxs)(t.Fragment,{children:[eI&&(0,M.jsx)(m.FocusGuard,{"data-type":"inside",ref:ev,onFocus:e=>{if(q){let e=eR();(0,R.enqueueFocus)(e[e.length-1])}else if(el?.portalNode)if(eu.current=!1,(0,b.isOutsideEvent)(e,el.portalNode)){let e=(0,b.getNextTabbable)(X);e?.focus()}else(0,O.resolveRef)($??el.beforeOutsideRef)?.focus()}}),D,eI&&(0,M.jsx)(m.FocusGuard,{"data-type":"inside",ref:eb,onFocus:e=>{if(q)(0,R.enqueueFocus)(eR()[0]);else if(el?.portalNode)if(_&&(eu.current=!0),(0,b.isOutsideEvent)(e,el.portalNode)){let e=(0,b.getPreviousTabbable)(X);e?.focus()}else(0,O.resolveRef)(W??el.afterOutsideRef)?.focus()}})]})}])},26674,38396,e=>{"use strict";var t=e.i(71645),n=e.i(74080),r=e.i(29315),i=e.i(74735),o=e.i(65420),s=e.i(83977),a=e.i(46376),l=e.i(67865),u=e.i(56789),c=e.i(52535),d=e.i(83976),f=e.i(75606),p=e.i(56434),m=e.i(51321),g=e.i(52245);let h={clipPath:"inset(50%)",position:"fixed",top:0,left:0};e.s(["CLICK_TRIGGER_IDENTIFIER",0,"data-base-ui-click-trigger","DISABLED_TRANSITIONS_STYLE",0,{style:{transition:"none"}},"DROPDOWN_COLLISION_AVOIDANCE",0,{fallbackAxisSide:"none"},"PATIENT_CLICK_THRESHOLD",0,500,"POPUP_COLLISION_AVOIDANCE",0,{fallbackAxisSide:"end"},"TYPEAHEAD_RESET_MS",0,500,"ownerVisuallyHidden",0,h],38396);var v=e.i(43476);let b=t.createContext(null),x=()=>t.useContext(b),y=(0,m.createAttribute)("portal");function S(e={}){let{ref:i,container:o,componentProps:c=u.EMPTY_OBJECT,elementProps:d}=e,f=(0,s.useId)(),p=x(),m=p?.portalNode,[h,v]=t.useState(null),[b,C]=t.useState(null),E=(0,l.useStableCallback)(e=>{null!==e&&C(e)}),R=t.useRef(null);(0,a.useIsoLayoutEffect)(()=>{if(null===o){R.current&&(R.current=null,C(null),v(null));return}let e=(o&&((0,r.isNode)(o)?o:o.current))??m??document.body;if(null==e){R.current&&(R.current=null,C(null),v(null));return}R.current!==e&&(R.current=e,C(null),v(e))},[o,m]);let w=(0,g.useRenderElement)("div",c,{ref:[i,E],props:[{id:f,[y]:""},d]}),I=h&&w?n.createPortal(w,h):null;return{node:b,nodeId:t.isValidElement(w)?w.props.id:void 0,subtree:I}}let C=t.forwardRef(function(e,r){let{render:s,className:l,style:u,children:m,container:g,portalOwnerRole:x,...y}=e,{node:C,nodeId:E,subtree:R}=S({container:g,ref:r,componentProps:e,elementProps:y}),w=t.useRef(null),I=t.useRef(null),T=t.useRef(null),k=t.useRef(null),[O,M]=t.useState(null),A=t.useRef(!1),P=O?.modal,N=O?.open,j=!!O&&!O.modal&&O.open&&!!C;t.useEffect(()=>{if(C&&!P)return(0,o.mergeCleanups)((0,i.addEventListener)(C,"focusin",e,!0),(0,i.addEventListener)(C,"focusout",e,!0));function e(e){C&&e.relatedTarget&&(0,d.isOutsideEvent)(e)&&("focusin"===e.type?A.current&&((0,d.enableFocusInside)(C),A.current=!1):((0,d.disableFocusInside)(C),A.current=!0))}},[C,P]),(0,a.useIsoLayoutEffect)(()=>{C&&!0===N&&A.current&&((0,d.enableFocusInside)(C),A.current=!1)},[N,C]);let L=t.useMemo(()=>({beforeOutsideRef:w,afterOutsideRef:I,beforeInsideRef:T,afterInsideRef:k,portalNode:C,setFocusManagerState:M}),[C]);return(0,v.jsxs)(t.Fragment,{children:[R,(0,v.jsxs)(b.Provider,{value:L,children:[j&&C&&(0,v.jsx)(c.FocusGuard,{"data-type":"outside",ref:w,onFocus:e=>{if((0,d.isOutsideEvent)(e,C))T.current?.focus();else{let e=O?O.domReference:null,t=(0,d.getPreviousTabbable)(e);t?.focus()}}}),j&&C&&(0,v.jsx)("span",{role:x,"aria-owns":E,style:h}),C&&n.createPortal(m,C),j&&C&&(0,v.jsx)(c.FocusGuard,{"data-type":"outside",ref:I,onFocus:e=>{if((0,d.isOutsideEvent)(e,C))k.current?.focus();else{let t=O?O.domReference:null,n=(0,d.getNextTabbable)(t);n?.focus(),O?.closeOnFocusOut&&O?.onOpenChange(!1,(0,f.createChangeEventDetails)(p.REASONS.focusOut,e.nativeEvent))}}})]})]})});e.s(["FloatingPortal",0,C,"useFloatingPortalNode",0,S,"usePortalContext",0,x],26674)},56341,e=>{"use strict";var t=e.i(26352),n=e.i(61286),r=e.i(57940);let i={open:e=>e.open,transitionStatus:e=>e.transitionStatus,domReferenceElement:e=>e.domReferenceElement,referenceElement:e=>e.positionReference??e.referenceElement,floatingElement:e=>e.floatingElement,floatingId:e=>e.floatingId};class o extends t.ReactStore{constructor(e){const{syncOnly:t,nested:r,onOpenChange:o,triggerElements:s,...a}=e;super({...a,positionReference:a.referenceElement,domReferenceElement:a.referenceElement},{onOpenChange:o,dataRef:{current:{}},events:(0,n.createEventEmitter)(),nested:r,triggerElements:s},i),this.syncOnly=t}syncOpenEvent=(e,t)=>{(!e||!this.state.open||null!=t&&(0,r.isClickLikeEvent)(t))&&(this.context.dataRef.current.openEvent=e?t:void 0)};dispatchOpenChange=(e,t)=>{this.syncOpenEvent(e,t.event);let n={open:e,reason:t.reason,nativeEvent:t.event,nested:this.context.nested,triggerElement:t.trigger};this.context.events.emit("openchange",n)};setOpen=(e,t)=>{this.syncOnly||this.dispatchOpenChange(e,t),this.context.onOpenChange?.(e,t)}}e.s(["FloatingRootStore",0,o])},46420,61286,79248,e=>{"use strict";var t=e.i(71645),n=e.i(83977),r=e.i(46376),i=e.i(88940);function o(){let e=new Map;return{emit(t,n){e.get(t)?.forEach(e=>e(n))},on(t,n){e.has(t)||e.set(t,new Set),e.get(t).add(n)},off(t,n){e.get(t)?.delete(n)}}}e.s(["createEventEmitter",0,o],61286);class s{nodesRef={current:[]};events=o();addNode(e){this.nodesRef.current.push(e)}removeNode(e){let t=this.nodesRef.current.findIndex(t=>t===e);-1!==t&&this.nodesRef.current.splice(t,1)}}e.s(["FloatingTreeStore",0,s],79248);var a=e.i(43476);let l=t.createContext(null),u=t.createContext(null),c=()=>t.useContext(l)?.id||null,d=e=>{let n=t.useContext(u);return e??n};e.s(["FloatingNode",0,function(e){let{children:n,id:r}=e,i=c();return(0,a.jsx)(l.Provider,{value:t.useMemo(()=>({id:r,parentId:i}),[r,i]),children:n})},"FloatingTree",0,function(e){let{children:t,externalTree:n}=e,r=(0,i.useRefWithInit)(()=>n??new s).current;return(0,a.jsx)(u.Provider,{value:r,children:t})},"useFloatingNodeId",0,function(e){let t=(0,n.useId)(),i=d(e),o=c();return(0,r.useIsoLayoutEffect)(()=>{if(!t)return;let e={id:t,parentId:o};return i?.addNode(e),()=>{i?.removeNode(e)}},[i,t,o]),t},"useFloatingParentNodeId",0,c,"useFloatingTree",0,d],46420)},64132,2672,e=>{"use strict";var t=e.i(21082);e.s(["gridNavigation",0,function(e,n,r,i,o,s,a,l,u,c=2){let d=(0,t.getGridNavigatedIndex)(r.current,{event:e,orientation:i,loopFocus:o,rtl:s,cols:c,disabledIndices:a,minIndex:l,maxIndex:u,prevIndex:n>u?l:n,stopEvent:!0});return(0,t.isIndexOutOfListBounds)(r.current,d)?void 0:d}],64132);var n=e.i(33332),r=e.i(71645);let i=r.createContext(void 0),o=r.createContext(void 0),s=r.createContext(void 0),a=r.createContext(!1),l=r.createContext("");e.s(["ComboboxDerivedItemsContext",0,s,"ComboboxFloatingContext",0,o,"ComboboxHasItemsContext",0,a,"ComboboxInputValueContext",0,l,"ComboboxRootContext",0,i,"useComboboxDerivedItemsContext",0,function(){let e=r.useContext(s);if(!e)throw Error((0,n.default)(24));return e},"useComboboxFloatingContext",0,function(){let e=r.useContext(o);if(!e)throw Error((0,n.default)(23));return e},"useComboboxHasItemsContext",0,function(){return r.useContext(a)},"useComboboxInputValueContext",0,function(){return r.useContext(l)},"useComboboxRootContext",0,function(){let e=r.useContext(i);if(!e)throw Error((0,n.default)(22));return e}],2672)},85689,e=>{"use strict";var t=e.i(71645),n=e.i(8445),r=e.i(39957),i=e.i(56789),o=e.i(84446),s=e.i(96296),a=e.i(57940),l=e.i(75606),u=e.i(56434);e.s(["useClick",0,function(e,c={}){let{enabled:d=!0,event:f="click",toggle:p=!0,ignoreMouse:m=!1,stickIfOpen:g=!0,touchOpenDelay:h=0,reason:v=u.REASONS.triggerPress}=c,b="rootStore"in e?e.rootStore:e,x=b.context.dataRef,y=t.useRef(void 0),S=(0,n.useAnimationFrame)(),C=(0,r.useTimeout)(),E=t.useMemo(()=>{function e(e,t,n,r){let i=(0,l.createChangeEventDetails)(v,t,n);e&&"touch"===r&&h>0?C.start(h,()=>{b.setOpen(!0,i)}):b.setOpen(e,i)}function t(e,t,n){let r=x.current.openEvent,i=b.select("domReferenceElement")!==t;return!!e&&!!i||!e||!p||!!r&&!!g&&!n(r.type)}return{onPointerDown(e){y.current=(0,a.isMouseLikePointerType)(e.pointerType,!0)&&(0,a.isVirtualPointerEvent)(e.nativeEvent)?"virtual":e.pointerType},onMouseDown(n){let r=y.current,i=n.nativeEvent,l=b.select("open");if(0!==n.button||"click"===f||(0,a.isMouseLikePointerType)(r,!0)&&m)return;let u=t(l,n.currentTarget,e=>"click"===e||"mousedown"===e),c=(0,o.getTarget)(i);if((0,s.isTypeableElement)(c))return void e(u,i,c,r);let d=n.currentTarget;S.request(()=>{e(u,i,d,r)})},onClick(n){if("mousedown-only"===f)return;let r=y.current;if("mousedown"===f&&r){y.current=void 0;return}(0,a.isMouseLikePointerType)(r,!0)&&m||e(t(b.select("open"),n.currentTarget,e=>"click"===e||"mousedown"===e||"keydown"===e||"keyup"===e),n.nativeEvent,n.currentTarget,r)},onKeyDown(){y.current=void 0}}},[x,f,m,v,b,g,p,S,C,h]);return t.useMemo(()=>d?{reference:E}:i.EMPTY_OBJECT,[d,E])}])},17989,e=>{"use strict";var t=e.i(71645),n=e.i(74735),r=e.i(65420),i=e.i(8868),o=e.i(67865),s=e.i(39957),a=e.i(29315),l=e.i(28744),u=e.i(46420),c=e.i(75606),d=e.i(56434),f=e.i(51321),p=e.i(84446),m=e.i(96296),g=e.i(57940),h=e.i(58408);function v(){return!1}e.s(["useDismiss",0,function(e,b={}){let{enabled:x=!0,escapeKey:y=!0,outsidePress:S=!0,outsidePressEvent:C="sloppy",referencePress:E=v,bubbles:R,externalTree:w}=b,I="rootStore"in e?e.rootStore:e,T=I.useState("open"),k=I.useState("floatingElement"),{dataRef:O,events:M}=I.context,A=(0,u.useFloatingTree)(w),P=(0,o.useStableCallback)("function"==typeof S?S:()=>!1),N="function"==typeof S?P:S,j=!1!==N,L=(0,o.useStableCallback)(()=>C),{escapeKey:D,outsidePress:z}={escapeKey:"boolean"==typeof R?R:R?.escapeKey??!1,outsidePress:"boolean"==typeof R?R:R?.outsidePress??!0},F=t.useRef(!1),H=t.useRef(!1),V=t.useRef(!1),q=t.useRef(!1),_=t.useRef(!1),B=t.useRef(""),W=t.useRef(null),$=(0,s.useTimeout)(),U=(0,s.useTimeout)(),K=(0,o.useStableCallback)(()=>{U.clear(),O.current.insideReactTree=!1}),G=(0,o.useStableCallback)(e=>{let t=O.current.floatingContext?.nodeId;return(A?(0,h.getNodeChildren)(A.nodesRef.current,t):[]).some(t=>t.context?.open&&!t.context.dataRef.current[e])}),Y=(0,o.useStableCallback)(e=>(0,m.isEventTargetWithin)(e,I.select("floatingElement"))||(0,m.isEventTargetWithin)(e,I.select("domReferenceElement"))),Q=(0,o.useStableCallback)(e=>{E()&&I.setOpen(!1,(0,c.createChangeEventDetails)(d.REASONS.triggerPress,e.nativeEvent))}),X=(0,o.useStableCallback)(e=>{if(!T||!x||!y||"Escape"!==e.key||_.current||!D&&G("__escapeKeyBubbles"))return;let t=(0,g.isReactEvent)(e)?e.nativeEvent:e,n=(0,c.createChangeEventDetails)(d.REASONS.escapeKey,t);I.setOpen(!1,n),n.isCanceled||e.preventDefault(),D||n.isPropagationAllowed||e.stopPropagation()}),J=(0,o.useStableCallback)(()=>{O.current.insideReactTree=!0,U.start(0,K)}),Z=(0,o.useStableCallback)(e=>{if(!T||!x||0!==e.button)return;let t=(0,p.getTarget)(e.nativeEvent);(0,p.contains)(I.select("floatingElement"),t)&&(F.current||(F.current=!0,H.current=!1))}),ee=(0,o.useStableCallback)(e=>{!T||!x||(e.defaultPrevented||e.nativeEvent.defaultPrevented)&&F.current&&(H.current=!0)});t.useEffect(()=>{function e(e){e.open||(q.current=!1)}return M.on("openchange",e),()=>{M.off("openchange",e)}},[M]),t.useEffect(()=>{if(!T||!x)return T||(q.current=!1),K;O.current.__escapeKeyBubbles=D,O.current.__outsidePressBubbles=z;let e=new s.Timeout,t=new s.Timeout,o=(0,i.ownerDocument)(k);function u(){V.current=!0,t.start(0,()=>{V.current=!1})}function v(){F.current=!1,H.current=!1}function b(){let e=B.current,t=L(),n="function"==typeof t?t():t;return"string"==typeof n?n:n["pen"!==e&&e?e:"mouse"]}function S(e){let t=O.current.floatingContext?.nodeId,n=A&&(0,h.getNodeChildren)(A.nodesRef.current,t).some(t=>(0,m.isEventTargetWithin)(e,t.context?.elements.floating));return Y(e)||n}function C(e){let n;if("intentional"===(n=b())&&"click"!==e.type||"sloppy"===n&&"click"===e.type){"click"===e.type||Y(e)||(t.clear(),V.current=!1),K();return}if(O.current.insideReactTree)return void K();let r=(0,p.getTarget)(e),o=`[${(0,f.createAttribute)("inert")}]`,s=(0,a.isElement)(r)?r.getRootNode():null,l=Array.from(((0,a.isShadowRoot)(s)?s:(0,i.ownerDocument)(I.select("floatingElement"))).querySelectorAll(o)),u=I.context.triggerElements;if(r&&(u.hasElement(r)||u.hasMatchingElement(e=>(0,p.contains)(e,r))))return;let h=(0,a.isElement)(r)?r:null;for(;h&&!(0,a.isLastTraversableNode)(h);){let e=(0,a.getParentNode)(h);if((0,a.isLastTraversableNode)(e)||!(0,a.isElement)(e))break;h=e}if(!(l.length&&(0,a.isElement)(r)&&!(0,m.isRootElement)(r)&&!(0,p.contains)(r,I.select("floatingElement"))&&l.every(e=>!(0,p.contains)(h,e)))){if((0,a.isHTMLElement)(r)&&!("touches"in e)){let t=(0,a.isLastTraversableNode)(r),n=(0,a.getComputedStyle)(r),i=/auto|scroll/,o=t||i.test(n.overflowX),s=t||i.test(n.overflowY),l=o&&r.clientWidth>0&&r.scrollWidth>r.clientWidth,u=s&&r.clientHeight>0&&r.scrollHeight>r.clientHeight,c="rtl"===n.direction,d=u&&(c?e.offsetX<=r.offsetWidth-r.clientWidth:e.offsetX>r.clientWidth),f=l&&e.offsetY>r.clientHeight;if(d||f)return}if(!S(e)){if("intentional"===b()){if(0!==e.detail&&!(0,g.isVirtualClick)(e)&&!q.current)return;if(V.current){t.clear(),V.current=!1;return}}"function"==typeof N&&!N(e)||G("__outsidePressBubbles")||(I.setOpen(!1,(0,c.createChangeEventDetails)(d.REASONS.outsidePress,e)),K())}}}function E(e){if("sloppy"!==b()||!I.select("open")||!x||Y(e))return;let t=e.touches[0];t&&(W.current={startTime:Date.now(),startX:t.clientX,startY:t.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},$.start(1e3,()=>{W.current&&(W.current.dismissOnTouchEnd=!1,W.current.dismissOnMouseDown=!1)}))}function R(e,t){let r=(0,p.getTarget)(e);if(!r)return;let i=(0,n.addEventListener)(r,e.type,()=>{t(e),i()})}function w(e){$.clear(),"pointerdown"===e.type&&(0===e.button&&(q.current=!0),B.current=e.pointerType),("mousedown"!==e.type||!W.current||W.current.dismissOnMouseDown)&&R(e,e=>{if("pointerdown"===e.type)"sloppy"!==b()||"touch"===e.pointerType||!I.select("open")||!x||Y(e)||C(e);else C(e)})}function M(e){if("pointercancel"===e.type&&(q.current=!1),!F.current)return;let n=H.current;if(v(),"intentional"===b()){if("pointercancel"===e.type){n&&u();return}S(e)||(n?u():("function"!=typeof N||N(e))&&(t.clear(),V.current=!0,K()))}}function P(e){if("sloppy"!==b()||!W.current||Y(e))return;let t=e.touches[0];if(!t)return;let n=Math.abs(t.clientX-W.current.startX),r=Math.abs(t.clientY-W.current.startY),i=Math.sqrt(n*n+r*r);i>5&&(W.current.dismissOnTouchEnd=!0),i>10&&(C(e),$.clear(),W.current=null)}function U(e){"sloppy"!==b()||!W.current||Y(e)||(W.current.dismissOnTouchEnd&&C(e),$.clear(),W.current=null)}let Q=(0,r.mergeCleanups)(y&&(0,r.mergeCleanups)((0,n.addEventListener)(o,"keydown",X),(0,n.addEventListener)(o,"compositionstart",function(){e.clear(),_.current=!0}),(0,n.addEventListener)(o,"compositionend",function(){e.start(5*!!l.platform.engine.webkit,()=>{_.current=!1})})),j&&(0,r.mergeCleanups)((0,n.addEventListener)(o,"click",w,!0),(0,n.addEventListener)(o,"pointerdown",w,!0),(0,n.addEventListener)(o,"pointerup",M,!0),(0,n.addEventListener)(o,"pointercancel",M,!0),(0,n.addEventListener)(o,"mousedown",w,!0),(0,n.addEventListener)(o,"mouseup",M,!0),(0,n.addEventListener)(o,"touchstart",function(e){B.current="touch",R(e,E)},{capture:!0,passive:!0}),(0,n.addEventListener)(o,"touchmove",function(e){R(e,P)},{capture:!0,passive:!0}),(0,n.addEventListener)(o,"touchend",function(e){R(e,U)},{capture:!0,passive:!0})));return()=>{Q(),e.clear(),t.clear(),v(),V.current=!1,K()}},[O,k,y,j,N,T,x,D,z,X,K,L,G,Y,A,I,$]);let et=t.useMemo(()=>({onKeyDown:X,onPointerDown:Q,onClick:Q}),[X,Q]),en=t.useMemo(()=>({onKeyDown:X,onPointerDown:ee,onMouseDown:ee,onClickCapture:J,onMouseDownCapture(e){J(),Z(e)},onPointerDownCapture(e){J(),Z(e)},onMouseUpCapture:J,onTouchEndCapture:J,onTouchMoveCapture:J}),[X,J,Z,ee]);return t.useMemo(()=>x?{reference:et,floating:en,trigger:et}:{},[x,et,en])}])},65858,e=>{"use strict";e.i(47167);var t=e.i(29315),n=e.i(83977),r=e.i(46376),i=e.i(88940),o=e.i(90627),s=e.i(46420),a=e.i(56341);e.s(["useFloatingRootContext",0,function(e){let{open:l=!1,onOpenChange:u,elements:c={}}=e,d=(0,n.useId)(),f=null!=(0,s.useFloatingParentNodeId)(),p=(0,i.useRefWithInit)(()=>new a.FloatingRootStore({open:l,transitionStatus:void 0,onOpenChange:u,referenceElement:c.reference??null,floatingElement:c.floating??null,triggerElements:new o.PopupTriggerMap,floatingId:d,syncOnly:!1,nested:f})).current;return(0,r.useIsoLayoutEffect)(()=>{let e={open:l,floatingId:d};void 0!==c.reference&&(e.referenceElement=c.reference,e.domReferenceElement=(0,t.isElement)(c.reference)?c.reference:null),void 0!==c.floating&&(e.floatingElement=c.floating),p.update(e)},[l,d,c.reference,c.floating,p]),p.context.onOpenChange=u,p.context.nested=f,p}])},13082,e=>{"use strict";var t=e.i(71645),n=e.i(74735),r=e.i(28744),i=e.i(65420),o=e.i(8868),s=e.i(39957),a=e.i(29315),l=e.i(51321),u=e.i(84446),c=e.i(96296),d=e.i(75606),f=e.i(56434);let p=r.platform.os.mac&&r.platform.engine.webkit;e.s(["useFocus",0,function(e,r={}){let{enabled:m=!0,delay:g}=r,h="rootStore"in e?e.rootStore:e,{events:v,dataRef:b}=h.context,x=t.useRef(!1),y=t.useRef(null),S=t.useRef(!0),C=(0,s.useTimeout)();t.useEffect(()=>{let e=h.select("domReferenceElement");if(!m)return;let t=(0,a.getWindow)(e);return(0,i.mergeCleanups)((0,n.addEventListener)(t,"blur",function(){let e=h.select("domReferenceElement");!h.select("open")&&(0,a.isHTMLElement)(e)&&e===(0,u.activeElement)((0,o.ownerDocument)(e))&&(x.current=!0,y.current=e)}),p&&(0,n.addEventListener)(t,"keydown",function(){S.current=!0},!0),p&&(0,n.addEventListener)(t,"pointerdown",function(){S.current=!1},!0))},[h,m]),t.useEffect(()=>{if(m)return v.on("openchange",e),()=>{v.off("openchange",e)};function e(e){if(e.reason===f.REASONS.triggerPress||e.reason===f.REASONS.escapeKey){let e=h.select("domReferenceElement");(0,a.isElement)(e)&&(y.current=e,x.current=!0)}}},[v,m,h]);let E=t.useMemo(()=>{function e(){x.current=!1,y.current=null}return{onMouseLeave(){e()},onFocus(t){let n=t.currentTarget;if(x.current){if(y.current===n)return;e()}let r=(0,u.getTarget)(t.nativeEvent);if((0,a.isElement)(r)){if(p&&!t.relatedTarget){if(!S.current&&!(0,c.isTypeableElement)(r))return}else if(!(0,c.matchesFocusVisible)(r))return}let i=(0,c.isTargetInsideEnabledTrigger)(t.relatedTarget,h.context.triggerElements),{nativeEvent:o,currentTarget:s}=t,l="function"==typeof g?g():g;h.select("open")&&i||0===l||void 0===l?h.setOpen(!0,(0,d.createChangeEventDetails)(f.REASONS.triggerFocus,o,s)):C.start(l,()=>{x.current||h.setOpen(!0,(0,d.createChangeEventDetails)(f.REASONS.triggerFocus,o,s))})},onBlur(t){e();let n=t.relatedTarget,r=t.nativeEvent,i=(0,a.isElement)(n)&&n.hasAttribute((0,l.createAttribute)("focus-guard"))&&"outside"===n.getAttribute("data-type");C.start(0,()=>{let e=h.select("domReferenceElement"),t=(0,u.activeElement)((0,o.ownerDocument)(e));if(!n&&t===e||(0,u.contains)(b.current.floatingContext?.refs.floating.current,t)||(0,u.contains)(e,t)||i)return;let s=n??t;(0,c.isTargetInsideEnabledTrigger)(s,h.context.triggerElements)||h.setOpen(!1,(0,d.createChangeEventDetails)(f.REASONS.triggerFocus,r))})}}},[b,g,h,C]);return t.useMemo(()=>m?{reference:E,trigger:E}:{},[m,E])}])},60891,e=>{"use strict";e.i(47167);var t=e.i(71645),n=e.i(8445),r=e.i(46376),i=e.i(8868),o=e.i(67865),s=e.i(46265),a=e.i(28744),l=e.i(29315),u=e.i(75606),c=e.i(56434),d=e.i(46420),f=e.i(21082),p=e.i(49055),m=e.i(84446),g=e.i(96296),h=e.i(3596),v=e.i(57940);function b(e){return a.platform.engine.webkit&&0===e.movementX&&0===e.movementY}function x(e,t,n){switch(e){case"vertical":return t;case"horizontal":return n;default:return t||n}}function y(e,t){return x(t,e===p.ARROW_UP||e===p.ARROW_DOWN,e===p.ARROW_LEFT||e===p.ARROW_RIGHT)}function S(e,t,n){return x(t,e===p.ARROW_DOWN,n?e===p.ARROW_LEFT:e===p.ARROW_RIGHT)||"Enter"===e||" "===e||""===e}e.s(["useListNavigation",0,function(e,a){let{listRef:C,activeIndex:E,onNavigate:R=()=>{},enabled:w=!0,selectedIndex:I=null,allowEscape:T=!1,loopFocus:k=!1,nested:O=!1,rtl:M=!1,virtual:A=!1,focusItemOnOpen:P="auto",focusItemOnHover:N=!0,openOnArrowKeyDown:j=!0,disabledIndices:L,orientation:D="vertical",parentOrientation:z,id:F,resetOnPointerLeave:H=!0,externalTree:V,grid:q}=a,_=null!=q,B="rootStore"in e?e.rootStore:e,W=B.useState("open"),$=B.useState("floatingElement"),U=B.useState("domReferenceElement"),K=B.context.dataRef,G=(0,g.getFloatingFocusElement)($),Y=(0,g.isTypeableCombobox)(U),Q=(0,s.useValueAsRef)(G),X=(0,d.useFloatingParentNodeId)(),J=(0,d.useFloatingTree)(V),Z=t.useRef(P),ee=t.useRef(I??-1),et=t.useRef(null),en=t.useRef(!0),er=(0,o.useStableCallback)(e=>{R(-1===ee.current?null:ee.current,e)}),ei=t.useRef(!!$),eo=t.useRef(W),es=t.useRef(!1),ea=t.useRef(!1),el=t.useRef(null),eu=(0,s.useValueAsRef)(L),ec=(0,s.useValueAsRef)(W),ed=(0,s.useValueAsRef)(I),ef=(0,s.useValueAsRef)(H),ep=(0,n.useAnimationFrame)(),em=(0,n.useAnimationFrame)(),eg=(0,o.useStableCallback)(()=>{function e(e){A?J?.events.emit("virtualfocus",e):el.current=(0,h.enqueueFocus)(e,{sync:es.current,preventScroll:!0})}let t=C.current[ee.current],n=ea.current;t&&e(t),(es.current?e=>e():e=>ep.request(e))(()=>{let r=C.current[ee.current]||t;!r||(t||e(r),eS&&(n||!en.current)&&r.scrollIntoView?.({block:"nearest",inline:"nearest"}))})});(0,r.useIsoLayoutEffect)(()=>{K.current.orientation=D},[K,D]),(0,r.useIsoLayoutEffect)(()=>{w&&(W&&$?(ee.current=I??-1,Z.current&&null!=I&&(ea.current=!0,er())):ei.current&&(ee.current=-1,er()))},[w,W,$,I,er]),(0,r.useIsoLayoutEffect)(()=>{if(w){if(!W){es.current=!1;return}if($)if(null==E){if(es.current=!1,null!=ed.current)return;if(ei.current&&(ee.current=-1,eg()),(!eo.current||!ei.current)&&Z.current&&(null!=et.current||!0===Z.current&&null==et.current)){let e=0,t=()=>{null==C.current[0]?(e<2&&(e?e=>em.request(e):queueMicrotask)(t),e+=1):(ee.current=null==et.current||S(et.current,D,M)||O?(0,f.getMinListIndex)(C):(0,f.getMaxListIndex)(C),et.current=null,er())};t()}}else(0,f.isIndexOutOfListBounds)(C.current,E)||(ee.current=E,eg(),ea.current=!1)}},[w,W,$,E,ed,O,C,D,M,er,eg,em]),(0,r.useIsoLayoutEffect)(()=>{if(!w||$||!J||A||!ei.current)return;let e=J.nodesRef.current,t=e.find(e=>e.id===X)?.context?.elements.floating,n=(0,m.activeElement)((0,i.ownerDocument)(U??t??null)),r=e.some(e=>e.context&&(0,m.contains)(e.context.elements.floating,n));t&&!r&&en.current&&t.focus({preventScroll:!0})},[w,$,U,J,X,A]),(0,r.useIsoLayoutEffect)(()=>{eo.current=W,ei.current=!!$}),(0,r.useIsoLayoutEffect)(()=>{W||(et.current=null,Z.current=P)},[W,P]);let eh=null!=E,ev=(0,o.useStableCallback)(e=>{if(!ec.current)return;let t=C.current.indexOf(e.currentTarget);-1!==t&&(ee.current!==t||E!==t)&&(ee.current=t,er(e))}),eb=(0,o.useStableCallback)(()=>z??J?.nodesRef.current.find(e=>e.id===X)?.context?.dataRef?.current.orientation),ex=(0,o.useStableCallback)(()=>(0,f.getMinListIndex)(C,eu.current)),ey=(0,o.useStableCallback)(e=>{var t;let n,r;if(en.current=!1,es.current=!0,229===e.which||!ec.current&&e.currentTarget===Q.current)return;if(O&&(t=e.key,n=M?t===p.ARROW_RIGHT:t===p.ARROW_LEFT,r=t===p.ARROW_UP,"both"===D||"horizontal"===D&&_?"Escape"===t:x(D,n,r))){y(e.key,eb())||(0,v.stopEvent)(e),B.setOpen(!1,(0,u.createChangeEventDetails)(c.REASONS.listNavigation,e.nativeEvent)),(0,l.isHTMLElement)(U)&&(A?J?.events.emit("virtualfocus",U):U.focus());return}let i=ee.current,o=(0,f.getMinListIndex)(C,L),s=(0,f.getMaxListIndex)(C,L);if(Y||("Home"===e.key&&((0,v.stopEvent)(e),ee.current=o,er(e)),"End"===e.key&&((0,v.stopEvent)(e),ee.current=s,er(e))),null!=q){let t=q(e,ee.current,C,D,k,M,L,o,s);if(null!=t&&(ee.current=t,er(e)),"both"===D)return}if(y(e.key,D)){if((0,v.stopEvent)(e),W&&!A&&(0,m.activeElement)(e.currentTarget.ownerDocument)===e.currentTarget){ee.current=S(e.key,D,M)?o:s,er(e);return}S(e.key,D,M)?k?i>=s?T&&i!==C.current.length?ee.current=-1:(es.current=!1,ee.current=o):ee.current=(0,f.findNonDisabledListIndex)(C.current,{startingIndex:i,disabledIndices:L}):ee.current=Math.min(s,(0,f.findNonDisabledListIndex)(C.current,{startingIndex:i,disabledIndices:L})):k?i<=o?T&&-1!==i?ee.current=C.current.length:(es.current=!1,ee.current=s):ee.current=(0,f.findNonDisabledListIndex)(C.current,{startingIndex:i,decrement:!0,disabledIndices:L}):ee.current=Math.max(o,(0,f.findNonDisabledListIndex)(C.current,{startingIndex:i,decrement:!0,disabledIndices:L})),(0,f.isIndexOutOfListBounds)(C.current,ee.current)&&(ee.current=-1),er(e)}}),eS=t.useMemo(()=>({onFocus(e){es.current=!0,ev(e)},onClick:({currentTarget:e})=>e.focus({preventScroll:!0}),onMouseMove(e){!b(e)&&(es.current=!0,ea.current=!1,N&&ev(e))},onPointerLeave(e){if(!ec.current||!en.current||"touch"===e.pointerType)return;es.current=!0;let t=e.relatedTarget;if(!(!N||C.current.includes(t))&&ef.current&&(el.current?.(),el.current=null,ee.current=-1,er(e),!A)){let e=Q.current,t=(0,m.activeElement)((0,i.ownerDocument)(e));e&&(0,m.contains)(e,t)&&e.focus({preventScroll:!0})}}}),[ev,ec,Q,N,C,er,ef,A]),eC=t.useMemo(()=>A&&W&&eh&&{"aria-activedescendant":`${F}-${E}`},[A,W,eh,F,E]),eE=t.useMemo(()=>({...!Y?eC:{},onKeyDown(e){if("Tab"===e.key&&e.shiftKey&&W&&!A){let t=(0,m.getTarget)(e.nativeEvent);if(t&&!(0,m.contains)(Q.current,t))return;(0,v.stopEvent)(e),B.setOpen(!1,(0,u.createChangeEventDetails)(c.REASONS.focusOut,e.nativeEvent)),(0,l.isHTMLElement)(U)&&U.focus();return}ey(e)},onPointerMove(e){b(e)||(en.current=!0)}}),[eC,ey,Q,Y,B,W,A,U]),eR=t.useMemo(()=>{function e(e){B.setOpen(!0,(0,u.createChangeEventDetails)(c.REASONS.listNavigation,e.nativeEvent,e.currentTarget))}function t(e){"auto"===P&&(0,v.isVirtualClick)(e.nativeEvent)&&(Z.current=!A)}function n(e){Z.current=P,"auto"===P&&(0,v.isVirtualPointerEvent)(e.nativeEvent)&&(Z.current=!0)}return{onKeyDown(t){var n,r;let i=B.select("open");en.current=!1;let o=t.key.startsWith("Arrow"),s=(n=t.key,r=eb(),x(r,M?n===p.ARROW_LEFT:n===p.ARROW_RIGHT,n===p.ARROW_DOWN)),a=y(t.key,D),l=(O?s:a)||"Enter"===t.key||""===t.key.trim();if(A&&i)return ey(t);if(i||j||!o){if(l){let e=y(t.key,eb());et.current=O&&e?null:t.key}if(O){s&&((0,v.stopEvent)(t),i?(ee.current=ex(),er(t)):e(t));return}a&&(null!=ed.current&&(ee.current=ed.current),(0,v.stopEvent)(t),!i&&j?e(t):ey(t),i&&er(t))}},onFocus(e){B.select("open")&&!A&&(ee.current=-1,er(e))},onPointerDown:n,onPointerEnter:n,onMouseDown:t,onClick:t}},[ey,P,ex,O,er,B,j,D,eb,M,ed,A]),ew=t.useMemo(()=>({...eC,...eR}),[eC,eR]);return t.useMemo(()=>w?{reference:ew,floating:eE,item:eS,trigger:eR}:{},[w,ew,eE,eR,eS])}])},5049,e=>{"use strict";var t=e.i(71645),n=e.i(46376),r=e.i(67865),i=e.i(39957),o=e.i(56789),s=e.i(21082),a=e.i(84446),l=e.i(57940);e.s(["useTypeahead",0,function(e,u){let{listRef:c,elementsRef:d,activeIndex:f,onMatch:p,disabledIndices:m,onTyping:g,enabled:h=!0,resetMs:v=750,selectedIndex:b=null}=u,x="rootStore"in e?e.rootStore:e,y=x.useState("open"),S=(0,i.useTimeout)(),C=t.useRef(""),E=t.useRef(b??f??-1),R=t.useRef(null),w=(0,r.useStableCallback)(e=>{function t(e){let t=d?.current[e];return!(t&&!(0,s.isElementVisible)(t)||t?.matches(":disabled"))&&(null==m||!(0,s.isListIndexDisabled)(o.EMPTY_ARRAY,e,m))}function n(e,r,i=0){if(0===e.length)return -1;let o=(i%e.length+e.length)%e.length,s=r.toLowerCase();for(let n=0;n<e.length;n+=1){let r=(o+n)%e.length,i=e[r];if(i?.toLowerCase().startsWith(s)&&t(r))return r}return -1}let r=c.current;if(C.current.length>0&&" "===e.key&&((0,l.stopEvent)(e),g?.(!0)),C.current.length>0&&" "!==C.current[0]&&-1===n(r,C.current)&&" "!==e.key&&g?.(!1),null==r||1!==e.key.length||e.ctrlKey||e.metaKey||e.altKey)return;y&&" "!==e.key&&((0,l.stopEvent)(e),g?.(!0));let i=""===C.current;i&&(E.current=b??f??-1),r.every((e,n)=>!(e&&t(n))||e[0]?.toLowerCase()!==e[1]?.toLowerCase())&&C.current===e.key&&(C.current="",E.current=R.current),C.current+=e.key,S.start(v,()=>{C.current="",E.current=R.current,g?.(!1)});let a=i?b??f??-1:E.current,u=n(r,C.current,(a??0)+1);-1!==u?(p?.(u),R.current=u):" "!==e.key&&(C.current="",g?.(!1))}),I=(0,r.useStableCallback)(e=>{let t=e.relatedTarget,n=x.select("domReferenceElement"),r=x.select("floatingElement");(0,a.contains)(n,t)||(0,a.contains)(r,t)||(S.clear(),C.current="",E.current=R.current,g?.(!1))});(0,n.useIsoLayoutEffect)(()=>{(y||null===b)&&(S.clear(),R.current=null,""!==C.current&&(C.current=""))},[y,b,S]);let T=t.useMemo(()=>({onKeyDown:w,onBlur:I}),[w,I]);return t.useMemo(()=>h?{reference:T,floating:T}:{},[h,T])}])},21082,e=>{"use strict";e.i(47167);var t=e.i(43084),n=e.i(29315),r=e.i(57940),i=e.i(49055);function o(e,t,n){return Math.floor(e/t)!==n}function s(e,t){return t<0||t>=e.length}function a(e,{startingIndex:t=-1,decrement:n=!1,disabledIndices:r,amount:i=1}={}){let o=t;do o+=n?-i:i;while(o>=0&&o<=e.length-1&&l(e,o,r))return o}function l(e,t,n){if("function"==typeof n?n(t):n?.includes(t)??!1)return!0;let r=e[t];return!!r&&(!!(!u(r)||r.matches(":disabled"))||!n&&(r.hasAttribute("disabled")||"true"===r.getAttribute("aria-disabled")))}function u(e,t=e?(0,n.getComputedStyle)(e):null){var r;return!!e&&!!e.isConnected&&!!t&&"hidden"!==(r=t).visibility&&"collapse"!==r.visibility&&("function"==typeof e.checkVisibility?e.checkVisibility():"none"!==t.display&&"contents"!==t.display)}e.s(["findNonDisabledListIndex",0,a,"getGridNavigatedIndex",0,function(e,{event:n,orientation:u,loopFocus:c,onLoop:d,rtl:f,cols:p,disabledIndices:m,minIndex:g,maxIndex:h,prevIndex:v,stopEvent:b=!1}){let x,y=v;if(n.key===i.ARROW_UP?x="up":n.key===i.ARROW_DOWN&&(x="down"),x){let i=[],o=[],u=!1,f=0;{let t=null,n=-1;e.forEach((e,r)=>{if(null==e)return;f+=1;let s=e.closest('[role="row"]');s&&(u=!0),(s!==t||-1===n)&&(t=s,i[n+=1]=[]),i[n].push(r),o[r]=n})}let S=!1,C=0;if(u)for(let e of i){let t=e.length;t>C&&(C=t),t!==p&&(S=!0)}let E=S&&f<e.length,R=C||p;b&&(0,r.stopEvent)(n);let w=(t=>{if(!S||-1===v)return;let r=o[v];if(null==r)return;let s=i[r].indexOf(v),a="up"===t?-1:1;for(let t=r+a,u=0;u<i.length;u+=1,t+=a){if(t<0||t>=i.length){if(!c||E)return;if(t=t<0?i.length-1:0,d){let e=Math.min(s,i[t].length-1);t=o[d(n,v,i[t][e]??i[t][0])]??t}}let r=i[t];for(let t=Math.min(s,r.length-1);t>=0;t-=1){let n=r[t];if(!l(e,n,m))return n}}})(x)??(n=>{if(!E||-1===v)return;let r=v%R,i="up"===n?-R:R,o=h-h%R,s=(0,t.floor)(h/R)+1;for(let t=v-r+i,n=0;n<s;n+=1,t+=i){if(t<0||t>h){if(!c)return;t=t<0?o:0}let n=Math.min(t+R-1,h);for(let i=Math.min(t+r,n);i>=t;i-=1)if(!l(e,i,m))return i}})(x);if(void 0!==w)y=w;else if(-1===v)y="up"===x?h:g;else if(y=a(e,{startingIndex:v,amount:R,decrement:"up"===x,disabledIndices:m}),c){if("up"===x&&(v-R<g||y<0)){let e=v%R,t=h%R,r=h-(t-e);y=t===e?h:t>e?r:r-R,d&&(y=d(n,v,y))}"down"===x&&v+R>h&&(y=a(e,{startingIndex:v%R-R,amount:R,disabledIndices:m}),d&&(y=d(n,v,y)))}s(e,y)&&(y=v)}if("both"===u){let l=(0,t.floor)(v/p);n.key===(f?i.ARROW_LEFT:i.ARROW_RIGHT)&&(b&&(0,r.stopEvent)(n),v%p!=p-1?(y=a(e,{startingIndex:v,disabledIndices:m}),c&&o(y,p,l)&&(y=a(e,{startingIndex:v-v%p-1,disabledIndices:m}),d&&(y=d(n,v,y)))):c&&(y=a(e,{startingIndex:v-v%p-1,disabledIndices:m}),d&&(y=d(n,v,y))),o(y,p,l)&&(y=v)),n.key===(f?i.ARROW_RIGHT:i.ARROW_LEFT)&&(b&&(0,r.stopEvent)(n),v%p!=0?(y=a(e,{startingIndex:v,decrement:!0,disabledIndices:m}),c&&o(y,p,l)&&(y=a(e,{startingIndex:v+(p-v%p),decrement:!0,disabledIndices:m}),d&&(y=d(n,v,y)))):c&&(y=a(e,{startingIndex:v+(p-v%p),decrement:!0,disabledIndices:m}),d&&(y=d(n,v,y))),o(y,p,l)&&(y=v));let u=(0,t.floor)(h/p)===l;s(e,y)&&(c&&u?(y=n.key===(f?i.ARROW_RIGHT:i.ARROW_LEFT)?h:a(e,{startingIndex:v-v%p-1,disabledIndices:m}),d&&(y=d(n,v,y))):y=v)}return y},"getMaxListIndex",0,function(e,t){return a(e.current,{decrement:!0,startingIndex:e.current.length,disabledIndices:t})},"getMinListIndex",0,function(e,t){return a(e.current,{disabledIndices:t})},"isElementVisible",0,u,"isIndexOutOfListBounds",0,s,"isListIndexDisabled",0,l])},49055,e=>{"use strict";e.s(["ARROW_DOWN",0,"ArrowDown","ARROW_LEFT",0,"ArrowLeft","ARROW_RIGHT",0,"ArrowRight","ARROW_UP",0,"ArrowUp","FOCUSABLE_ATTRIBUTE",0,"data-base-ui-focusable","TYPEABLE_SELECTOR",0,"input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])"])},51321,e=>{"use strict";e.s(["createAttribute",0,function(e){return`data-base-ui-${e}`}])},96296,45147,22846,e=>{"use strict";var t=e.i(29315),n=e.i(28744),r=e.i(84446),i=e.i(49055),o=e.i(15618);e.s(["CommonTriggerDataAttributes",0,o],45147);var o=o;o.popupOpen;let s="data-trigger-disabled";function a(e){return(0,t.isHTMLElement)(e)&&e.matches(i.TYPEABLE_SELECTOR)}e.s(["triggerDisabled",0,s],22846),e.s(["getFloatingFocusElement",0,function(e){return e?e.hasAttribute(i.FOCUSABLE_ATTRIBUTE)?e:e.querySelector(`[${i.FOCUSABLE_ATTRIBUTE}]`)||e:null},"isEventTargetWithin",0,function(e,t){return null!=t&&("composedPath"in e?e.composedPath().includes(t):null!=e.target&&t.contains(e.target))},"isInteractiveElement",0,function(e){return e?.closest(`button,a[href],[role="button"],select,[tabindex]:not([tabindex="-1"]),${i.TYPEABLE_SELECTOR}`)!=null},"isRootElement",0,function(e){return e.matches("html,body")},"isTargetInsideEnabledTrigger",0,function(e,n){if(!(0,t.isElement)(e))return!1;if(n.hasElement(e))return!e.hasAttribute(s);for(let[,t]of n.entries())if((0,r.contains)(t,e))return!t.hasAttribute(s);return!1},"isTypeableCombobox",0,function(e){return!!e&&"combobox"===e.getAttribute("role")&&a(e)},"isTypeableElement",0,a,"matchesFocusVisible",0,function(e){if(!e||n.platform.env.jsdom)return!0;try{return e.matches(":focus-visible")}catch(e){return!0}}],96296)},3596,e=>{"use strict";var t=e.i(56789);let n=0;e.s(["enqueueFocus",0,function(e,r={}){let{preventScroll:i=!1,sync:o=!1,shouldFocus:s}=r;function a(){(!s||s())&&e?.focus({preventScroll:i})}if(cancelAnimationFrame(n),o)return a(),t.NOOP;let l=requestAnimationFrame(a);return n=l,()=>{n===l&&(cancelAnimationFrame(l),n=0)}}])},57940,e=>{"use strict";var t=e.i(28744);e.s(["isClickLikeEvent",0,function(e){let t=e.type;return"click"===t||"mousedown"===t||"keydown"===t||"keyup"===t},"isMouseLikePointerType",0,function(e,t){let n=["mouse","pen"];return t||n.push("",void 0),n.includes(e)},"isReactEvent",0,function(e){return"nativeEvent"in e},"isVirtualClick",0,function(e){return""===e.pointerType&&!!e.isTrusted||(t.platform.os.android&&e.pointerType?"click"===e.type&&1===e.buttons:0===e.detail&&!e.pointerType)},"isVirtualPointerEvent",0,function(e){return!t.platform.env.jsdom&&(!t.platform.os.android&&0===e.width&&0===e.height||t.platform.os.android&&1===e.width&&1===e.height&&0===e.pressure&&0===e.detail&&"mouse"===e.pointerType||e.width<1&&e.height<1&&0===e.pressure&&0===e.detail&&"touch"===e.pointerType)},"stopEvent",0,function(e){e.preventDefault(),e.stopPropagation()}])},44659,e=>{"use strict";var t=e.i(29315),n=e.i(8868);let r={inert:new WeakMap,"aria-hidden":new WeakMap},i="data-base-ui-inert",o={inert:new WeakSet,"aria-hidden":new WeakSet},s=new WeakMap,a=0,l=(e,n)=>n.map(n=>{if(e.contains(n))return n;let r=function e(n){return n?(0,t.isShadowRoot)(n)?n.host:e(n.parentNode):null}(n);return e.contains(r)?r:null}).filter(e=>null!=e),u=e=>{let t=new Set;return e.forEach(e=>{let n=e;for(;n&&!t.has(n);)t.add(n),n=n.parentNode}),t},c=(e,n,r)=>{let i=[],o=e=>{!e||r.has(e)||Array.from(e.children).forEach(e=>{"script"!==(0,t.getNodeName)(e)&&(n.has(e)?o(e):i.push(e))})};return o(e),i};e.s(["markOthers",0,function(e,t={}){let{ariaHidden:d=!1,inert:f=!1,mark:p=!0}=t,m=(0,n.ownerDocument)(e[0]).body;return function(e,t,n,d,{mark:f=!0}){let p=null;d?p="inert":n&&(p="aria-hidden");let m=null,g=null,h=l(t,e),v=f?c(t,u(h),new Set(h)):[],b=[],x=[];if(p){let e=r[p],n=o[p];g=n,m=e;let i=l(t,Array.from(t.querySelectorAll("[aria-live]"))),s=h.concat(i);c(t,u(s),new Set(s)).forEach(t=>{let r=t.getAttribute(p),i=null!==r&&"false"!==r,o=(e.get(t)||0)+1;e.set(t,o),b.push(t),1===o&&i&&n.add(t),i||t.setAttribute(p,"inert"===p?"":"true")})}return f&&v.forEach(e=>{let t=(s.get(e)||0)+1;s.set(e,t),x.push(e),1===t&&e.setAttribute(i,"")}),a+=1,()=>{m&&b.forEach(e=>{let t=(m.get(e)||0)-1;m.set(e,t),t||(!g?.has(e)&&p&&e.removeAttribute(p),g?.delete(e))}),f&&x.forEach(e=>{let t=(s.get(e)||0)-1;s.set(e,t),t||e.removeAttribute(i)}),(a-=1)||(r.inert=new WeakMap,r["aria-hidden"]=new WeakMap,o.inert=new WeakSet,o["aria-hidden"]=new WeakSet,s=new WeakMap)}}(e,m,d,f,{mark:p})}])},58408,e=>{"use strict";e.s(["getNodeAncestors",0,function(e,t){let n=[],r=e.find(e=>e.id===t)?.parentId;for(;r;){let t=e.find(e=>e.id===r);r=t?.parentId,t&&(n=n.concat(t))}return n},"getNodeChildren",0,function e(t,n,r=!0){return t.filter(e=>e.parentId===n).flatMap(n=>[...!r||n.context?.open?[n]:[],...e(t,n.id,r)])}])},83976,e=>{"use strict";var t=e.i(29315),n=e.i(8868),r=e.i(84446),i=e.i(21082);function o(e){for(let n of Array.from(e.children))if("summary"===(0,t.getNodeName)(n))return n;return null}function s(e){let n=e?(0,t.getNodeName)(e):"";return null!=e&&e.matches('a[href],button,input,select,textarea,summary,details,iframe,object,embed,[tabindex],[contenteditable]:not([contenteditable="false"]),audio[controls],video[controls]')&&("summary"!==n||null!=e.parentElement&&"details"===(0,t.getNodeName)(e.parentElement)&&o(e.parentElement)===e)&&("details"!==n||null==o(e))&&("input"!==n||"hidden"!==e.type)}function a(e){if(!s(e)||!e.isConnected||e.matches(":disabled"))return!1;for(let n=e;n;n=function(e){let n=e.assignedSlot;if(n)return n;if(e.parentElement)return e.parentElement;let r=e.getRootNode();return(0,t.isShadowRoot)(r)?r.host:null}(n)){let s=n!==e,a="slot"===(0,t.getNodeName)(n);if(n.hasAttribute("inert")||s&&"details"===(0,t.getNodeName)(n)&&!n.open&&!function(e,t){let n=o(t);return!!n&&(e===n||(0,r.contains)(n,e))}(e,n)||n.hasAttribute("hidden")||!a&&!function(e,n){let r=(0,t.getComputedStyle)(e);return n?"none"!==r.display:(0,i.isElementVisible)(e,r)}(n,s))return!1}return!0}function l(e){let n=e.tabIndex;if(n<0){let n=(0,t.getNodeName)(e);if("details"===n||"audio"===n||"video"===n||(0,t.isHTMLElement)(e)&&e.isContentEditable)return 0}return n}function u(e){return"input"!==(0,t.getNodeName)(e)?null:"radio"===e.type&&""!==e.name?e:null}function c(e){if((0,t.isHTMLElement)(e)&&"slot"===(0,t.getNodeName)(e)){let t=e.assignedElements({flatten:!0});if(t.length>0)return t}return(0,t.isHTMLElement)(e)&&e.shadowRoot?Array.from(e.shadowRoot.children):Array.from(e.children)}function d(e){let t=[];return!function e(t,n){c(t).forEach(t=>{s(t)&&n.push(t),e(t,n)})}(e,t),t.filter(a)}function f(e){let t=d(e);return t.filter(e=>l(e)>=0&&function(e,t){let n=u(e);if(!n)return!0;let r=t.find(e=>{let t=u(e);return t?.name===n.name&&t.form===n.form&&t.checked});return r?r===n:t.find(e=>{let t=u(e);return t?.name===n.name&&t.form===n.form})===n}(e,t))}function p(e,t){let i=f(e),o=i.length;if(0===o)return;let s=(0,r.activeElement)((0,n.ownerDocument)(e)),a=i.indexOf(s);return i[-1===a?1===t?0:o-1:a+t]}function m(e,t){if(!e)return null;let r=f((0,n.ownerDocument)(e).body),i=r.length;if(0===i)return null;let o=r.indexOf(e);return -1===o?null:r[(o+t+i)%i]}e.s(["disableFocusInside",0,function(e){f(e).forEach(e=>{e.dataset.tabindex=e.getAttribute("tabindex")||"",e.setAttribute("tabindex","-1")})},"enableFocusInside",0,function(e){let n=[];!function e(n,r,i){c(n).forEach(n=>{(0,t.isHTMLElement)(n)&&n.matches(r)&&i.push(n),e(n,r,i)})}(e,"[data-tabindex]",n),n.forEach(e=>{let t=e.dataset.tabindex;delete e.dataset.tabindex,t?e.setAttribute("tabindex",t):e.removeAttribute("tabindex")})},"focusable",0,d,"getNextTabbable",0,function(e){return p((0,n.ownerDocument)(e).body,1)||e},"getPreviousTabbable",0,function(e){return p((0,n.ownerDocument)(e).body,-1)||e},"getTabbableAfterElement",0,function(e){return m(e,1)},"getTabbableBeforeElement",0,function(e){return m(e,-1)},"isOutsideEvent",0,function(e,t){let n=t||e.currentTarget,i=e.relatedTarget;return!i||!(0,r.contains)(n,i)},"isTabbable",0,function(e){return a(e)&&l(e)>=0},"tabbable",0,f])},93737,e=>{"use strict";e.i(71645);var t=e.i(1249),n=e.i(72410),r=e.i(43476);e.s(["PrehydrationScript",0,function(e){let{script:i}=e,{nonce:o}=(0,n.useCSPContext)();return(0,t.useIsHydrating)()?(0,r.jsx)("script",{nonce:o,dangerouslySetInnerHTML:{__html:i},suppressHydrationWarning:!0}):null}])},73327,e=>{"use strict";var t=e.i(29315);let n="ArrowUp",r="ArrowDown",i="ArrowLeft",o="ArrowRight",s="Home",a=new Set([n,r,i,o,s,"End"]);function l(e,t,n){let r="left"===n?"offsetLeft":"offsetTop",i=0;for(;t.offsetParent&&(i+=t[r],t.offsetParent!==e);)t=t.offsetParent;return i}function u(e){let t=getComputedStyle(e);return{scrollMarginTop:parseFloat(t.scrollMarginTop)||0,scrollMarginRight:parseFloat(t.scrollMarginRight)||0,scrollMarginBottom:parseFloat(t.scrollMarginBottom)||0,scrollMarginLeft:parseFloat(t.scrollMarginLeft)||0,scrollPaddingTop:parseFloat(t.scrollPaddingTop)||0,scrollPaddingRight:parseFloat(t.scrollPaddingRight)||0,scrollPaddingBottom:parseFloat(t.scrollPaddingBottom)||0,scrollPaddingLeft:parseFloat(t.scrollPaddingLeft)||0}}e.s(["ARROW_DOWN",0,r,"ARROW_LEFT",0,i,"ARROW_RIGHT",0,o,"ARROW_UP",0,n,"COMPOSITE_KEYS",0,a,"END",0,"End","HOME",0,s,"MODIFIER_KEYS",0,["Shift","Control","Alt","Meta"],"isNativeInput",0,function(e){return!!((0,t.isHTMLElement)(e)&&"INPUT"===e.tagName&&null!=e.selectionStart||(0,t.isHTMLElement)(e)&&"TEXTAREA"===e.tagName)},"scrollIntoViewIfNeeded",0,function(e,t,n,r){if(!e||!t||!t.scrollTo)return;let i=e.scrollLeft,o=e.scrollTop,s=e.clientWidth<e.scrollWidth,a=e.clientHeight<e.scrollHeight;if(s&&"vertical"!==r){let r=l(e,t,"left"),o=u(e),s=u(t);"ltr"===n&&(r+t.offsetWidth+s.scrollMarginRight>e.scrollLeft+e.clientWidth-o.scrollPaddingRight?i=r+t.offsetWidth+s.scrollMarginRight-e.clientWidth+o.scrollPaddingRight:r-s.scrollMarginLeft<e.scrollLeft+o.scrollPaddingLeft&&(i=r-s.scrollMarginLeft-o.scrollPaddingLeft)),"rtl"===n&&(r-s.scrollMarginLeft<e.scrollLeft+o.scrollPaddingLeft?i=r-s.scrollMarginLeft-o.scrollPaddingLeft:r+t.offsetWidth+s.scrollMarginRight>e.scrollLeft+e.clientWidth-o.scrollPaddingRight&&(i=r+t.offsetWidth+s.scrollMarginRight-e.clientWidth+o.scrollPaddingRight))}if(a&&"horizontal"!==r){let n=l(e,t,"top"),r=u(e),i=u(t);n-i.scrollMarginTop<e.scrollTop+r.scrollPaddingTop?o=n-i.scrollMarginTop-r.scrollPaddingTop:n+t.offsetHeight+i.scrollMarginBottom>e.scrollTop+e.clientHeight-r.scrollPaddingBottom&&(o=n+t.offsetHeight+i.scrollMarginBottom-e.clientHeight+r.scrollPaddingBottom)}e.scrollTo({left:i,top:o,behavior:"auto"})}])},53687,45356,e=>{"use strict";var t=e.i(71645),n=e.i(88940),r=e.i(67865),i=e.i(46376);let o=t.createContext({register:()=>{},unregister:()=>{},subscribeMapChange:()=>()=>{},nextIndexRef:{current:0}});e.s(["CompositeListContext",0,o,"useCompositeListContext",0,function(){return t.useContext(o)}],45356);var s=e.i(43476);function a(){return new Map}function l(){return new Set}function u(e,t){return e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_FOLLOWING?-1:1}e.s(["CompositeList",0,function(e){let{children:c,elementsRef:d,labelsRef:f,onMapChange:p}=e,m=(0,r.useStableCallback)(p),[,g]=t.useState(!1),h=(0,n.useRefWithInit)(l).current,v=(0,n.useRefWithInit)(a).current,b=t.useRef(0),x=t.useRef(!0),y=t.useRef(null),S=t.useRef(null),C=(0,r.useStableCallback)(()=>{x.current||(x.current=!0,g(e=>!e))}),E=(0,r.useStableCallback)((e,t)=>{v.set(e,t),C()}),R=(0,r.useStableCallback)(e=>{v.delete(e),C()}),w=(0,r.useStableCallback)(e=>{let t=new Map;return d.current.length=0,f&&(f.current.length=0),e.forEach(e=>{t.set(e.element,{...e.registration.metadata??{},index:e.index}),d.current[e.index]=e.element,f&&(f.current[e.index]=void 0!==e.registration.label?e.registration.label:e.registration.textRef?.current?.textContent??e.element.textContent)}),b.current=d.current.length,t}),I=(0,r.useStableCallback)(()=>{var e;let t,n,r,i,[o,s]=(e=v,t=new Set,n=[],r=[],e.forEach((e,i)=>{if(!i.isConnected)return;let o=e.index,s={index:o??-1,element:i,registration:e};null===o?r.push(s):o>=0&&(t.add(o),n.push(s))}),i=0,r.sort((e,t)=>u(e.element,t.element)),r.forEach(e=>{for(;t.has(i);)i+=1;e.index=i,n.push(e),i+=1}),t.size>0&&n.sort((e,t)=>e.index-t.index),[n,r.map(e=>e.element)]),a=w(o),l=y.current,c=!l||l.length!==o.length||o.some((e,t)=>{let n=l[t];return e.index!==n.index||e.element!==n.element||e.registration.index!==n.registration.index||e.registration.metadata!==n.registration.metadata});!function(e){if(S.current?.disconnect(),S.current=null,"function"!=typeof MutationObserver||e.length<2)return;let t=new MutationObserver(n=>{if(!function(e){for(let t of e)for(let e=0;e<t.removedNodes.length;e+=1)if(t.removedNodes[e].isConnected)return!0;return!1}(n))return;let r=null;for(let n of e)if(n.isConnected){if(r&&u(r,n)>0){t.disconnect(),C();return}r=n}});S.current=t;let n=new Set;for(let t=1;t<e.length;t+=1){let r=function(e,t){let n=e.parentElement;for(;n&&!n.contains(t);)n=n.parentElement;return n}(e[t-1],e[t]);r&&n.add(r)}n.forEach(e=>t.observe(e,{childList:!0}))}(s),y.current=o,x.current=!1,c&&(h.forEach(e=>e(a)),m(a))});(0,i.useIsoLayoutEffect)(()=>(!x.current&&y.current&&w(y.current),()=>{d.current=[],f&&(f.current=[])}),[d,f,w]),(0,i.useIsoLayoutEffect)(()=>{x.current&&I()}),(0,i.useIsoLayoutEffect)(()=>()=>{S.current?.disconnect(),x.current=!0},[]);let T=(0,r.useStableCallback)(e=>(h.add(e),()=>{h.delete(e)})),k=t.useMemo(()=>({register:E,unregister:R,subscribeMapChange:T,nextIndexRef:b}),[E,R,T,b]);return(0,s.jsx)(o.Provider,{value:k,children:c})}],53687)},73553,e=>{"use strict";var t=e.i(71645),n=e.i(46376),r=e.i(45356);e.s(["useCompositeListItem",0,function(e={}){let{guess:i,label:o,metadata:s,textRef:a,index:l}=e,{register:u,unregister:c,subscribeMapChange:d,nextIndexRef:f}=(0,r.useCompositeListContext)(),p=t.useRef(-1),[m,g]=t.useState(null==l&&i?()=>{if(-1===p.current){let e=f.current;f.current+=1,p.current=e}return p.current}:-1),h=l??m,v=t.useRef(null),b=t.useCallback(e=>{let t=v.current;t&&c(t),v.current=e,e&&u(e,{metadata:s??null,index:l??null,label:o,textRef:a})},[l,u,c,s,o,a]);return(0,n.useIsoLayoutEffect)(()=>{if(null==l)return d(e=>{let t=v.current?e.get(v.current)?.index:null;null!=t&&g(t)})},[l,d]),{ref:b,index:h}}])},19749,e=>{"use strict";var t=e.i(71645),n=e.i(90803),r=e.i(67865),i=e.i(28918),o=e.i(46376),s=e.i(56789),a=e.i(73327),l=e.i(21082),u=e.i(70359),c=e.i(84446);e.s(["useCompositeRoot",0,function(e){let{loopFocus:d=!0,orientation:f="both",grid:p,onLoop:m,direction:g,highlightedIndex:h,onHighlightedIndexChange:v,rootRef:b,enableHomeAndEndKeys:x=!1,stopEventPropagation:y,disabledIndices:S,modifierKeys:C=s.EMPTY_ARRAY}=e,[E,R]=t.useState(0),w=null!=p,I=t.useRef(null),T=(0,i.useMergedRefs)(I,b),k=t.useRef([]),O=t.useRef(!1),M=t.useRef(null),A=h??E,P=(0,r.useStableCallback)((e,t=!1)=>{if(M.current=k.current[e]??null,(v??R)(e),t){let t=k.current[e];(0,a.scrollIntoViewIfNeeded)(I.current,t,g,f)}}),N=(0,r.useStableCallback)(e=>{if(0===e.size)return;if(O.current){let e=k.current,t=e.indexOf(M.current);if(-1===t){let t=e[A];!t||(0,l.isListIndexDisabled)(e,A,S)?P(function(e,t){let n=-1;for(let r=0;r<e.length;r+=1){let i=e[r];if(!(!i||(0,l.isListIndexDisabled)(e,r,t))){if(i.hasAttribute(u.ACTIVE_COMPOSITE_ITEM))return r;-1===n&&(n=r)}}return Math.max(n,0)}(e,S)):M.current=t}else t!==A&&P(t);return}O.current=!0;let t=Array.from(e.keys()),n=t.find(e=>e?.hasAttribute(u.ACTIVE_COMPOSITE_ITEM))??null,r=n?e.get(n)?.index??-1:-1;if(-1!==r)P(r);else if((0,l.isListIndexDisabled)(t,A,S)){let e=(0,l.findNonDisabledListIndex)(t,{disabledIndices:S});(0,l.isIndexOutOfListBounds)(t,e)||P(e)}(0,a.scrollIntoViewIfNeeded)(I.current,n,g,f)});(0,o.useIsoLayoutEffect)(()=>{if(null==S||null!=h||!O.current)return;let e=k.current;if((0,l.isListIndexDisabled)(e,A,S)){let t=(0,l.findNonDisabledListIndex)(e,{disabledIndices:S});(0,l.isIndexOutOfListBounds)(e,t)||P(t)}},[S,h,A,k,P]);let j=(0,r.useStableCallback)((e,t,n)=>m?m(e,t,n,k):n),L=(0,r.useStableCallback)(e=>{let t=e.key===a.HOME||e.key===a.END;if(!a.COMPOSITE_KEYS.has(e.key)||!x&&t||function(e,t){for(let n of a.MODIFIER_KEYS)if(!t.includes(n)&&e.getModifierState(n))return!0;return!1}(e,C)||!I.current)return;let r="rtl"===g,i=r?a.ARROW_LEFT:a.ARROW_RIGHT,o=r?a.ARROW_RIGHT:a.ARROW_LEFT,s="vertical"===f?a.ARROW_DOWN:i,u="vertical"===f?a.ARROW_UP:o,h=(0,c.getTarget)(e.nativeEvent);if(null!=h&&(0,a.isNativeInput)(h)&&!(0,n.isElementDisabled)(h)){let t=h.selectionStart,n=h.selectionEnd,r=h.value;if(null==t||e.shiftKey||t!==n||e.key!==u&&t<r.length||e.key!==s&&t>0)return}let v=A,b=(0,l.getMinListIndex)(k,S),E=(0,l.getMaxListIndex)(k,S);null!=p&&(v=p({disabledIndices:S,elementsRef:k,event:e,highlightedIndex:A,loopFocus:d,maxIndex:E,minIndex:b,onLoop:j,orientation:f,rtl:r}));let R="vertical"!==f&&e.key===i||"horizontal"!==f&&e.key===a.ARROW_DOWN,T="vertical"!==f&&e.key===o||"horizontal"!==f&&e.key===a.ARROW_UP;x&&(e.key===a.HOME?v=b:e.key===a.END&&(v=E)),v===A&&(R||T)&&(d&&v===E&&R?(v=b,m&&(v=m(e,A,v,k))):d&&v===b&&T?(v=E,m&&(v=m(e,A,v,k))):v=(0,l.findNonDisabledListIndex)(k.current,{startingIndex:v,decrement:T,disabledIndices:S})),v===A||(0,l.isIndexOutOfListBounds)(k.current,v)||(y&&e.stopPropagation(),(w||t||R||T)&&e.preventDefault(),P(v,!0),queueMicrotask(()=>{k.current[v]?.focus()}))});return{props:{ref:T,onFocus(e){let t=I.current,n=(0,c.getTarget)(e.nativeEvent);t&&null!=n&&(0,a.isNativeInput)(n)&&n.setSelectionRange(0,n.value.length)},onKeyDown:L},highlightedIndex:A,onHighlightedIndexChange:P,elementsRef:k,onMapChange:N,relayKeyboardEvent:L}}])},72410,e=>{"use strict";e.i(47167);var t=e.i(71645);let n=t.createContext(void 0),r={disableStyleElements:!1};e.s(["useCSPContext",0,function(){return t.useContext(n)??r}])},72855,e=>{"use strict";e.i(47167);var t=e.i(71645);let n=t.createContext(void 0);e.s(["useDirection",0,function(){let e=t.useContext(n);return e?.direction??"ltr"}])},84325,42191,e=>{"use strict";let t=(e,t)=>Object.is(e,t);function n(e,t,n){return null==e||null==t?Object.is(e,t):n(e,t)}function r(e,t,r){return!!e&&e.some(e=>void 0!==e&&n(t,e,r))}function i(e,t,r){return e?e.findIndex(e=>void 0!==e&&n(e,t,r)):-1}function o(e,n,o,s){let a=s&&Array.isArray(n)?e.findIndex(function(e,n){if(n!==t)return t=>r(e,t,n);let i=new Set(e);return i.delete(void 0),t=>i.has(t)&&(0!==t||e.some(e=>Object.is(t,e)))}(n,o)):i(e,n,o);return -1===a?null:a}e.s(["compareItemEquality",0,n,"defaultItemEquality",0,t,"findItemIndex",0,i,"findSelectionIndex",0,o,"isSelectedValueDirty",0,function(e,t,r){return Array.isArray(e)&&Array.isArray(t)?!function(e,t,n=Object.is){let{length:r}=e;if(r!==t.length)return!1;for(let i=0;i<r;i+=1)if(!n(e[i],t[i]))return!1;return!0}(e,t,(e,t)=>n(e,t,r)):e!==t},"removeItem",0,function(e,t,r){return e.filter(e=>!n(t,e,r))},"resolveSelectedIndex",0,function(e,t,n,i,s,a){return r(i,t,s)?null!=a&&e>a&&r(i,n[a],s)?a:e:e===a?o(n,i,s,!0):a},"selectedValueIncludes",0,r],84325);var s=e.i(71645);function a(e){if(null==e)return"";if("string"==typeof e)return e;try{return JSON.stringify(e)}catch{return String(e)}}var l=e.i(43476);function u(e){var t;return"object"==typeof(t=e?.[0])&&null!=t&&Array.isArray(t.items)}function c(e){return u(e)?e.flatMap(e=>e.items):e}function d(e,t){if(t&&null!=e)return t(e)??"";if(e&&"object"==typeof e){if("label"in e&&null!=e.label)return String(e.label);if("value"in e)return String(e.value)}return a(e)}function f(e,t,n){if(n&&null!=e)return n(e);if(e&&"object"==typeof e&&"label"in e&&null!=e.label)return e.label;if(t&&!Array.isArray(t))return(Object.hasOwn(t,e)?t[e]:void 0)??d(e,n);if(Array.isArray(t)){let r=c(t);if(null==e||"object"!=typeof e){let t=r.find(t=>t.value===e);return t&&null!=t.label?t.label:d(e,n)}if("value"in e){let t=r.find(t=>t&&t.value===e.value);if(t&&null!=t.label)return t.label}}return d(e,n)}e.s(["flattenLeafItems",0,c,"hasNullItemLabel",0,function(e){if(!Array.isArray(e))return null!=e&&"null"in e;if(u(e)){for(let t of e)for(let e of t.items)if(e&&null==e.value&&null!=e.label)return!0;return!1}for(let t of e)if(t&&null==t.value&&null!=t.label)return!0;return!1},"isGroupedItems",0,u,"resolveMultipleLabels",0,function(e,t,n){return e.reduce((e,r,i)=>(i>0&&e.push(", "),e.push((0,l.jsx)(s.Fragment,{children:f(r,t,n)},i)),e),[])},"resolveSelectedLabel",0,f,"stringifyAsLabel",0,d,"stringifyAsValue",0,function(e,t){return t&&null!=e?t(e)??"":e&&"object"==typeof e&&"value"in e&&"label"in e?a(e.value):a(e)}],42191)},23706,9091,67387,e=>{"use strict";var t=e.i(71645),n=e.i(43084),r=e.i(8868),i=e.i(33848),o=e.i(46376),s=e.i(46265),a=e.i(67865),l=e.i(53760),u=e.i(58950),c=e.i(88643),d=e.i(72855);let f={name:"hide",async fn(e){let{width:t,height:n,x:r,y:i}=e.rects.reference,o=await e.platform.detectOverflow(e,{elementContext:"reference"});return{data:{referenceHidden:o.top-n>=0||o.right-t>=0||o.bottom-n>=0||o.left-t>=0||0===t&&0===n&&0===r&&0===i}}}},p={sideX:"left",sideY:"top"};e.s(["DEFAULT_SIDES",0,p],9091);let m="--available-width",g="--available-height",h="--anchor-width",v="--anchor-height",b="--transform-origin";function x(e,t,n){let r="inline-start"===e||"inline-end"===e;return({top:"top",right:r?n?"inline-start":"inline-end":"right",bottom:"bottom",left:r?n?"inline-end":"inline-start":"left"})[t]}function y(e,t,r){let{rects:i,placement:o}=e;return{side:x(t,(0,n.getSide)(o),r),align:(0,n.getAlignment)(o)||"center",anchor:{width:i.reference.width,height:i.reference.height},positioner:{width:i.floating.width,height:i.floating.height}}}function S(e){return null!=e&&"current"in e}e.s(["anchorHeight",0,v,"anchorWidth",0,h,"availableHeight",0,g,"availableWidth",0,m,"positionerHeight",0,"--positioner-height","positionerWidth",0,"--positioner-width","transformOrigin",0,b],67387),e.s(["useAnchorPositioning",0,function(e){return function(e,c){let{anchor:C,positionMethod:E="absolute",side:R="bottom",sideOffset:w=0,align:I="center",alignOffset:T=0,collisionBoundary:k,collisionPadding:O=5,sticky:M=!1,arrowPadding:A=5,disableAnchorTracking:P=!1,inline:N,keepMounted:j=!1,floatingRootContext:L,mounted:D,collisionAvoidance:z,shift:F,nodeId:H,adaptiveOrigin:V,lazyFlip:q=!1,externalTree:_}=e,[B,W]=t.useState(null);D||null===B||W(null);let $=z.side||"flip",U=z.align||"flip",K=z.fallbackAxisSide||"end",G=F?.crossAxis??!1,Y=F?.rootBoundary,Q="function"==typeof C?C:void 0,X=(0,a.useStableCallback)(Q),J=Q?X:C,Z=(0,s.useValueAsRef)(C),ee=(0,s.useValueAsRef)(D),et="rtl"===(0,d.useDirection)(),en=B||({top:"top",right:"right",bottom:"bottom",left:"left","inline-end":et?"left":"right","inline-start":et?"right":"left"})[R],er="center"===I?en:`${en}-${I}`,ei=O;"number"==typeof ei?ei={top:ei,right:ei,bottom:ei,left:ei}:ei&&(ei={top:ei.top||0,right:ei.right||0,bottom:ei.bottom||0,left:ei.left||0});let eo=+("bottom"===R),es=+("top"===R),ea=+("right"===R),el=+("left"===R),eu={boundary:"clipping-ancestors"===k?"clippingAncestors":k,padding:ei},ec=t.useRef(null),ed=(0,s.useValueAsRef)(w),ef=(0,s.useValueAsRef)(T),ep="function"!=typeof w?w:0,em="function"!=typeof T?T:0,eg=[];N&&eg.push(N),eg.push((0,u.offset)(e=>{let t=y(e,R,et),n="function"==typeof ed.current?ed.current(t):ed.current,r="function"==typeof ef.current?ef.current(t):ef.current;return{mainAxis:n,crossAxis:r,alignmentAxis:r}},[ep,em,et,R]));let eh="none"===U&&"shift"!==$,ev=!eh&&(M||G||"shift"===$),eb="none"===$?null:(0,u.flip)({...eu,padding:{top:ei.top+1+eo,right:ei.right+1+el,bottom:ei.bottom+1+es,left:ei.left+1+ea},mainAxis:!G&&"flip"===$,crossAxis:"flip"===U&&"alignment",fallbackAxisSideDirection:K}),ex=eh?null:(0,u.shift)({...eu,rootBoundary:Y,mainAxis:"none"!==U,crossAxis:ev,limiter:M||G?void 0:(0,u.limitShift)(e=>{if(!ec.current)return{};let{width:t,height:r}=ec.current.getBoundingClientRect(),i=(0,n.getSideAxis)((0,n.getSide)(e.placement)),o="y"===i?ei.left+ei.right:ei.top+ei.bottom;return{offset:("y"===i?t:r)/2+o/2}})},[eu,M,G,Y,ei,U]);"shift"===$||"shift"===U||"center"===I?eg.push(ex,eb):eg.push(eb,ex),eg.push((0,u.size)({...eu,apply({elements:{floating:e},availableWidth:t,availableHeight:n,rects:r}){if(!ee.current)return;let o=e.style;o.setProperty(m,`${t}px`),o.setProperty(g,`${n}px`);let s=(0,i.ownerWindow)(e).devicePixelRatio||1,{x:a,y:l,width:u,height:c}=r.reference,d=(Math.round((a+u)*s)-Math.round(a*s))/s,f=(Math.round((l+c)*s)-Math.round(l*s))/s;o.setProperty(h,`${d}px`),o.setProperty(v,`${f}px`)}}),((e,t)=>{let{name:r,fn:i}={name:"arrow",options:e,async fn(t){let{x:r,y:i,placement:o,rects:s,platform:a,elements:l,middlewareData:u}=t,{element:c,padding:d=0,offsetParent:f="real"}=(0,n.evaluate)(e,t)||{};if(null==c)return{};let p=(0,n.getPaddingObject)(d),m={x:r,y:i},g=(0,n.getAlignmentAxis)(o),h=(0,n.getAxisLength)(g),v=await a.getDimensions(c),b="y"===g,x=b?"clientHeight":"clientWidth",y=s.reference[h]+s.reference[g]-m[g]-s.floating[h],S=m[g]-s.reference[g],C="real"===f?await a.getOffsetParent?.(c):l.floating,E=l.floating[x]||s.floating[h];E&&await a.isElement?.(C)||(E=l.floating[x]||s.floating[h]);let R=E/2-v[h]/2-1,w=Math.min(p[b?"top":"left"],R),I=Math.min(p[b?"bottom":"right"],R),T=E-v[h]-I,k=E/2-v[h]/2+(y/2-S/2),O=(0,n.clamp)(w,k,T),M=!u.arrow&&null!=(0,n.getAlignment)(o)&&k!==O&&s.reference[h]/2-(k<w?w:I)-v[h]/2<0,A=M?k<w?k-w:k-T:0;return{[g]:m[g]+A,data:{[g]:O,centerOffset:k-O-A,...M&&{alignmentOffset:A}},reset:M}}};return{name:r,fn:i,options:[e,t]}})(e=>({element:ec.current||(0,r.ownerDocument)(e.elements.floating).createElement("div"),padding:ec.current?A:0,offsetParent:"floating"}),[A]),{name:"transformOrigin",fn(e){let t,{elements:{floating:r},middlewareData:i,placement:o,platform:s,rects:a,y:l}=e,u=(0,n.getSide)(o),c=(0,n.getAlignment)(o),d="y"===(0,n.getSideAxis)(u),f=ec.current,p="function"==typeof w?w(y(e,R,et)):w;if(!f&&c&&1>=Math.abs(d?i.shift?.x||0:i.shift?.y||0))t="start"===c===(d&&s.isRTL?.(r)===!0)?"100%":"0%";else{let e=d?i.arrow?.x||0:i.arrow?.y||0,n=d?f?.clientWidth||0:f?.clientHeight||0;t=`${e+n/2}px`}let m="top"===u||"left"===u?`calc(100% + ${p}px)`:`${-p}px`;return ev&&d&&Math.abs(i.shift?.y||0)>p&&(m=`${a.reference.y+a.reference.height/2-l}px`),r.style.setProperty(b,d?`${t} ${m}`:`${m} ${t}`),{}}},f,V),(0,o.useIsoLayoutEffect)(()=>{!D&&L&&L.update({referenceElement:null,floatingElement:null,domReferenceElement:null,positionReference:null})},[D,L]);let ey=t.useMemo(()=>({ancestorScroll:!P,elementResize:!P&&"u">typeof ResizeObserver,layoutShift:!P&&"u">typeof IntersectionObserver}),[P]),{refs:eS,elements:eC,x:eE,y:eR,middlewareData:ew,update:eI,placement:eT,context:ek,isPositioned:eO,floatingStyles:eM}=c({rootContext:L,open:j?D:void 0,placement:er,middleware:eg,strategy:E,whileElementsMounted:j?void 0:(...e)=>(0,l.autoUpdate)(...e,ey),nodeId:H,externalTree:_}),{sideX:eA,sideY:eP}=ew.adaptiveOrigin||p,eN=eO?E:"fixed",ej=t.useMemo(()=>{let e;return(e=eO?V?{position:eN,[eA]:eE,[eP]:eR}:{...eM,position:eN}:{position:eN,top:0,left:0})[m]="100vw",e[g]="100vh",eO||(e.opacity=0),e},[V,eN,eA,eE,eP,eR,eM,eO]),eL=t.useRef(null);(0,o.useIsoLayoutEffect)(()=>{if(!D)return;let e=Z.current,t="function"==typeof e?e():e,n=(S(t)?t.current:t)||null;n!==eL.current&&(eS.setPositionReference(n),eL.current=n)},[D,eS,J,Z]),t.useEffect(()=>{if(!D)return;let e=Z.current;"function"!=typeof e&&S(e)&&e.current!==eL.current&&(eS.setPositionReference(e.current),eL.current=e.current)},[D,eS,J,Z]),t.useEffect(()=>{if(j&&D&&eC.reference&&eC.floating)return(0,l.autoUpdate)(eC.reference,eC.floating,eI,ey)},[j,D,eC,eI,ey]);let eD=(0,n.getSide)(eT),ez=x(R,eD,et),eF=(0,n.getAlignment)(eT)||"center",eH=!!ew.hide?.referenceHidden;(0,o.useIsoLayoutEffect)(()=>{q&&D&&eO&&eD!==en&&W(eD)},[q,D,eO,eD,en]);let eV=t.useMemo(()=>({position:"absolute",top:ew.arrow?.y,left:ew.arrow?.x}),[ew.arrow]),eq=ew.arrow?.centerOffset!==0;return t.useMemo(()=>({positionerStyles:ej,arrowStyles:eV,arrowRef:ec,arrowUncentered:eq,side:ez,align:eF,physicalSide:eD,anchorHidden:eH,refs:eS,context:ek,isPositioned:eO,update:eI}),[ej,eV,ec,eq,ez,eF,eD,eH,eS,ek,eO,eI])}(e,c.useBaseUIFloating)}],23706)},61027,3414,78921,82370,89554,66506,85996,71714,81194,1545,91384,58307,64270,19712,82264,62050,82593,5953,7447,36481,74671,63947,77450,e=>{"use strict";e.s([],61027);var t=e.i(71645),n=e.i(33332);let r=t.createContext(void 0);function i(e){let i=t.useContext(r);if(void 0===i&&!e)throw Error((0,n.default)(33));return i}e.s(["MenuPositionerContext",0,r,"useMenuPositionerContext",0,i],3414);let o=t.createContext(void 0);function s(e){let r=t.useContext(o);if(void 0===r&&!e)throw Error((0,n.default)(36));return r}e.s(["MenuRootContext",0,o,"useMenuRootContext",0,s],78921);var a=e.i(52245),l=e.i(79938);let u=t.forwardRef(function(e,t){let{render:n,className:r,style:o,...u}=e,{store:c}=s(),{arrowRef:d,side:f,align:p,arrowUncentered:m,arrowStyles:g}=i(),h=c.useState("open");return(0,a.useRenderElement)("div",e,{ref:[d,t],stateAttributesMapping:l.popupStateMapping,state:{open:h,side:f,align:p,uncentered:m},props:{style:g,"aria-hidden":!0,...u}})});e.s(["MenuArrow",0,u],82370);let c=t.createContext(void 0);function d(e=!0){let r=t.useContext(c);if(void 0===r&&!e)throw Error((0,n.default)(25));return r}var f=e.i(56434);let p=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...o}=e,{store:u}=s(),c=u.useState("open"),p=u.useState("mounted"),m=u.useState("transitionStatus"),g=u.useState("lastOpenChangeReason"),h=d();return(0,a.useRenderElement)("div",e,{ref:h?.backdropRef?[t,h.backdropRef]:t,state:{open:c,transitionStatus:m},stateAttributesMapping:l.popupTransitionStateMapping,props:[{role:"presentation",hidden:!p,style:{pointerEvents:g===f.REASONS.triggerHover?"none":void 0,userSelect:"none",WebkitUserSelect:"none"}},o]})});e.s(["MenuBackdrop",0,p],89554);var m=e.i(51437),g=e.i(56789);let h=t.createContext(void 0);var v=e.i(28918),b=e.i(40886),x=e.i(76782),y=e.i(28744),S=e.i(64350);function C(e){let{closeOnClick:n,highlighted:r,id:i,nodeId:o,store:s,typingRef:a,itemRef:l,itemMetadata:u}=e,{events:c}=s.useState("floatingTreeRoot"),p=s.useState("open"),m=d(!0),g=void 0!==m;return t.useMemo(()=>({id:i,role:"menuitem",tabIndex:p&&r?0:-1,onKeyDown(e){" "===e.key&&a?.current&&e.preventDefault()},onMouseMove(e){o&&c.emit("itemhover",{nodeId:o,target:e.currentTarget})},onClick(e){n&&c.emit("close",{domEvent:e,reason:f.REASONS.itemPress})},onMouseUp(e){if(m){let t=m.initialCursorPointRef.current;if(m.initialCursorPointRef.current=null,g&&t&&1>=Math.abs(e.clientX-t.x)&&1>=Math.abs(e.clientY-t.y)||g&&!y.platform.os.mac&&2===e.button)return}l.current&&s.context.allowMouseUpTriggerRef.current&&(!g||2===e.button)&&"regular-item"===u.type&&(0,S.dispatchClickWithModifiers)(l.current,e,{detail:1})}}),[n,r,i,c,o,p,s,a,l,m,g,u])}let E={type:"regular-item"};function R(e){let{closeOnClick:n,disabled:r,highlighted:i,id:o,store:s,typingRef:a=s.context.typingRef,nativeButton:l,itemMetadata:u,nodeId:c}=e,d=t.useRef(null),{getButtonProps:f,buttonRef:p}=(0,b.useButton)({disabled:r,focusableWhenDisabled:!0,native:l,composite:!0}),m=C({closeOnClick:n,highlighted:i,id:o,nodeId:c,store:s,typingRef:a,itemRef:d,itemMetadata:u}),g=t.useCallback(e=>(0,x.mergeProps)(m,{onMouseEnter(){"submenu-trigger"===u.type&&u.setActive()}},e,f),[m,f,u]),h=(0,v.useMergedRefs)(d,p);return t.useMemo(()=>({getItemProps:g,itemRef:h}),[g,h])}e.s(["REGULAR_ITEM",0,E,"useMenuItem",0,R],66506);var w=e.i(73553),I=e.i(88015);let T={checked:e=>e?{"data-checked":""}:{"data-unchecked":""},...e.i(74354).transitionStatusMapping};var k=e.i(75606),O=e.i(43476);let M=t.forwardRef(function(e,n){let{render:r,className:o,id:l,label:u,nativeButton:c=!1,disabled:d=!1,closeOnClick:p=!1,checked:v,defaultChecked:b,onCheckedChange:x,style:y,...S}=e,C=(0,w.useCompositeListItem)({guess:!0,label:u}),M=i(!0),A=(0,I.useBaseUiId)(l),{store:P}=s(),N=P.useState("disabled"),j=d||N,L=P.useState("isActive",C.index),D=P.useState("itemProps"),[z,F]=(0,m.useControlled)({controlled:v,default:b??!1,name:"MenuCheckboxItem",state:"checked"}),{getItemProps:H,itemRef:V}=R({closeOnClick:p,disabled:j,highlighted:L,id:A,store:P,nativeButton:c,nodeId:M?.context.nodeId,itemMetadata:E}),q=t.useMemo(()=>({disabled:j,highlighted:L,checked:z}),[j,L,z]),_=(0,a.useRenderElement)("div",e,{state:q,stateAttributesMapping:T,props:[D,{role:"menuitemcheckbox","aria-checked":z,onClick:function(e){let t=(0,k.createChangeEventDetails)(f.REASONS.itemPress,e.nativeEvent,void 0,{preventUnmountOnClose:g.NOOP});x?.(!z,t),t.isCanceled||F(e=>!e)}},S,H],ref:[V,n,C.ref]});return(0,O.jsx)(h.Provider,{value:q,children:_})});e.s(["MenuCheckboxItem",0,M],85996);var A=e.i(23910),P=e.i(37584);let N=t.forwardRef(function(e,r){let{render:i,className:o,style:s,keepMounted:l=!1,...u}=e,c=function(){let e=t.useContext(h);if(void 0===e)throw Error((0,n.default)(30));return e}(),d=t.useRef(null),{transitionStatus:f,mounted:p,setMounted:m}=(0,A.useTransitionStatus)(c.checked);(0,P.useOpenChangeComplete)({batch:!0,enabled:!c.checked,open:c.checked,ref:d,onComplete(){c.checked||m(!1)}});let g={checked:c.checked,disabled:c.disabled,highlighted:c.highlighted,transitionStatus:f};return(0,a.useRenderElement)("span",e,{state:g,ref:[r,d],stateAttributesMapping:T,props:{"aria-hidden":!0,...u},enabled:l||p})});e.s(["MenuCheckboxItemIndicator",0,N],71714);let j=t.createContext(void 0),L=t.forwardRef(function(e,n){let{render:r,className:i,style:o,...s}=e,[l,u]=t.useState(void 0),c=(0,a.useRenderElement)("div",e,{ref:n,props:{role:"group","aria-labelledby":l,...s}});return(0,O.jsx)(j.Provider,{value:u,children:c})});e.s(["MenuGroup",0,L],81194);var D=e.i(46376);let z=t.forwardRef(function(e,r){let{render:i,className:o,style:s,id:l,...u}=e,c=(0,I.useBaseUiId)(l),d=function(){let e=t.useContext(j);if(void 0===e)throw Error((0,n.default)(31));return e}();return(0,D.useIsoLayoutEffect)(()=>(d(c),()=>{d(e=>e===c?void 0:e)}),[d,c]),(0,a.useRenderElement)("div",e,{ref:r,props:{id:c,"aria-hidden":!0,...u}})});e.s(["MenuGroupLabel",0,z],1545);let F=t.forwardRef(function(e,t){let{render:n,className:r,id:o,label:l,nativeButton:u=!1,disabled:c=!1,closeOnClick:d=!0,style:f,...p}=e,m=(0,w.useCompositeListItem)({guess:!0,label:l}),g=i(!0),h=(0,I.useBaseUiId)(o),{store:v}=s(),b=v.useState("disabled"),x=c||b,y=v.useState("isActive",m.index),S=v.useState("itemProps"),{getItemProps:C,itemRef:T}=R({closeOnClick:d,disabled:x,highlighted:y,id:h,store:v,nativeButton:u,nodeId:g?.context.nodeId,itemMetadata:E});return(0,a.useRenderElement)("div",e,{state:{disabled:x,highlighted:y},props:[S,p,C],ref:[T,t,m.ref]})});e.s(["MenuItem",0,F],91384);let H=t.forwardRef(function(e,n){let{render:r,className:o,id:l,label:u,closeOnClick:c=!1,style:d,...f}=e,p=t.useRef(null),m=(0,w.useCompositeListItem)({guess:!0,label:u}),g=i(!0),h=g?.context.nodeId,v=(0,I.useBaseUiId)(l),{store:y}=s(),S=y.useState("isActive",m.index),R=y.useState("itemProps"),T=y.context.typingRef,{getButtonProps:k,buttonRef:O}=(0,b.useButton)({native:!1,composite:!0}),M=C({closeOnClick:c,highlighted:S,id:v,nodeId:h,store:y,typingRef:T,itemRef:p,itemMetadata:E});return(0,a.useRenderElement)("a",e,{state:{highlighted:S},props:[R,f,function(e){return(0,x.mergeProps)(M,e,k)}],ref:[p,O,n,m.ref]})});e.s(["MenuLinkItem",0,H],58307);var V=e.i(61487),q=e.i(31157),_=e.i(96533),B=e.i(73327),W=e.i(53984);let $=t.forwardRef(function(e,n){let{render:r,className:o,style:u,finalFocus:c,...d}=e,{store:p}=s(),{side:m,align:g}=i(),h=null!=(0,_.useToolbarRootContext)(!0),v=p.useState("open"),b=p.useState("transitionStatus"),x=p.useState("popupProps"),y=p.useState("mounted"),S=p.useState("instantType"),C=p.useState("activeTriggerElement"),E=p.useState("parent"),R=p.useState("lastOpenChangeReason"),w=p.useState("rootId"),I=p.useState("floatingRootContext"),T=p.useState("floatingTreeRoot"),M=p.useState("closeDelay"),A=p.useState("hoverEnabled"),N=p.useState("disabled"),j=p.useState("openMethod"),L="context-menu"===E.type;(0,P.useOpenChangeComplete)({open:v,ref:p.context.popupRef,onComplete(){v&&p.context.onOpenChangeComplete?.(!0)}}),t.useEffect(()=>{function e(e){p.setOpen(!1,(0,k.createChangeEventDetails)(e.reason,e.domEvent))}return T.events.on("close",e),()=>{T.events.off("close",e)}},[T.events,p]),(0,q.useHoverFloatingInteraction)(I,{enabled:A&&!N&&!L&&"menubar"!==E.type,closeDelay:M});let D=p.useStateSetter("popupElement"),z={transitionStatus:b,side:m,align:g,open:v,nested:"menu"===E.type,instant:S},F=(0,a.useRenderElement)("div",e,{state:z,ref:[n,p.context.popupRef,D],stateAttributesMapping:l.popupTransitionStateMapping,props:[x,{onKeyDown(e){h&&B.COMPOSITE_KEYS.has(e.key)&&e.stopPropagation()}},(0,W.getDisabledMountTransitionStyles)(b),d,{"data-rootownerid":w}]}),H=void 0===E.type||L;return(C||"menubar"===E.type&&R!==f.REASONS.outsidePress)&&(H=!0),(0,O.jsx)(V.FloatingFocusManager,{context:I,openInteractionType:j,modal:L,disabled:!y,returnFocus:void 0===c?H:c,initialFocus:"menu"!==E.type,restoreFocus:!0,externalTree:"menubar"!==E.type?T:void 0,previousFocusableElement:C,nextFocusableElement:void 0===E.type?p.context.triggerFocusTargetRef:void 0,beforeContentFocusGuardRef:void 0===E.type?p.context.beforeContentFocusGuardRef:void 0,children:F})});e.s(["MenuPopup",0,$],64270);var U=e.i(26674);let K=t.createContext(void 0),G=t.forwardRef(function(e,t){let{keepMounted:n=!1,...r}=e,{store:i,parent:o}=s();if(!(i.useState("mounted")||n))return null;let a="menu"===o.type||"menubar"===o.type?"group":void 0;return(0,O.jsx)(K.Provider,{value:n,children:(0,O.jsx)(U.FloatingPortal,{ref:t,...r,portalOwnerRole:a})})});e.s(["MenuPortal",0,G],19712);var Y=e.i(44394),Q=e.i(39957),X=e.i(46420),J=e.i(23706),Z=e.i(53687),ee=e.i(426),et=e.i(38396),en=e.i(22640),er=e.i(89579),ei=e.i(33383);let eo=t.forwardRef(function(e,i){let{anchor:o,positionMethod:a="absolute",className:l,render:u,side:c,align:p,sideOffset:m=0,alignOffset:g=0,collisionBoundary:h="clipping-ancestors",collisionPadding:v=5,arrowPadding:b=5,sticky:x=!1,disableAnchorTracking:y=!1,collisionAvoidance:S=et.DROPDOWN_COLLISION_AVOIDANCE,style:C,...E}=e,{store:R}=s(),w=function(){let e=t.useContext(K);if(void 0===e)throw Error((0,n.default)(32));return e}(),I=d(!0),T=R.useState("parent"),M=R.useState("floatingRootContext"),A=R.useState("floatingTreeRoot"),P=R.useState("mounted"),N=R.useState("open"),j=R.useState("modal"),L=R.useState("openMethod"),z=R.useState("activeTriggerElement"),F=R.useState("transitionStatus"),H=R.useState("positionerElement"),V=R.useState("instantType"),q=R.useState("adaptiveOrigin"),_=R.useState("lastOpenChangeReason"),B=R.useState("floatingNodeId"),W=R.useState("floatingParentNodeId"),$=M.useState("domReferenceElement"),U=t.useRef(null),G=(0,en.useAnimationsFinished)(H),eo=o,es=m,ea=g,el=p,eu=S;"context-menu"===T.type&&(eo=o??T.context?.anchor,el=el??"start",c||"center"===el||(ea=e.alignOffset??2,es=e.sideOffset??-5));let ec=c,ed=el;"menu"===T.type?(ec=ec??"inline-end",ed=ed??"start",eu=e.collisionAvoidance??et.POPUP_COLLISION_AVOIDANCE):"menubar"===T.type&&(ec=ec??("vertical"===T.context.orientation?"inline-end":"bottom"),ed=ed??"start");let ef="context-menu"===T.type,ep=(0,J.useAnchorPositioning)({anchor:eo,floatingRootContext:M,positionMethod:I?"fixed":a,mounted:P,side:ec,sideOffset:es,align:ed,alignOffset:ea,arrowPadding:ef?0:b,collisionBoundary:h,collisionPadding:v,sticky:x,nodeId:B,keepMounted:w,disableAnchorTracking:y,collisionAvoidance:eu,shift:ef?{crossAxis:!("side"in eu&&"flip"===eu.side),rootBoundary:"layoutViewport"}:void 0,externalTree:A,adaptiveOrigin:q});t.useEffect(()=>{function e(e){e.open&&(e.parentNodeId===B&&R.set("hoverEnabled",!1),e.nodeId!==B&&e.parentNodeId===R.select("floatingParentNodeId")&&R.setOpen(!1,(0,k.createChangeEventDetails)(f.REASONS.siblingOpen)))}return A.events.on("menuopenchange",e),()=>{A.events.off("menuopenchange",e)}},[R,A.events,B]),t.useEffect(()=>{if(null!=R.select("floatingParentNodeId"))return A.events.on("menuopenchange",e),()=>{A.events.off("menuopenchange",e)};function e(e){if(e.open||e.nodeId!==R.select("floatingParentNodeId"))return;let t=e.reason??f.REASONS.siblingOpen;R.setOpen(!1,(0,k.createChangeEventDetails)(t))}},[A.events,R]);let em=(0,Q.useTimeout)();t.useEffect(()=>{N||em.clear()},[N,em]),t.useEffect(()=>{function e(e){if(N&&e.nodeId===R.select("floatingParentNodeId"))if(e.target&&z&&z!==e.target){let e=R.select("closeDelay");e>0?em.isStarted()||em.start(e,()=>{R.setOpen(!1,(0,k.createChangeEventDetails)(f.REASONS.siblingOpen))}):R.setOpen(!1,(0,k.createChangeEventDetails)(f.REASONS.siblingOpen))}else em.clear()}return A.events.on("itemhover",e),()=>{A.events.off("itemhover",e)}},[A.events,N,z,R,em]),t.useEffect(()=>{let e={open:N,nodeId:B,parentNodeId:W,reason:R.select("lastOpenChangeReason")};A.events.emit("menuopenchange",e)},[A.events,N,R,B,W]),(0,D.useIsoLayoutEffect)(()=>{let e=U.current;if($&&(U.current=$),e&&$&&$!==e){R.set("instantType",void 0);let e=new AbortController;return G(()=>{R.set("instantType","trigger-change")},e.signal),()=>{e.abort()}}},[$,G,R]);let eg={open:N,side:ep.side,align:ep.align,anchorHidden:ep.anchorHidden,nested:"menu"===T.type,instant:V},eh="menubar"===T.type&&T.context.modal,ev=j&&_!==f.REASONS.triggerHover;(0,ei.useAnchoredPopupScrollLock)(N&&(eh||ev),"touch"===L,H,z);let eb=(0,er.usePositioner)(e,eg,{styles:ep.positionerStyles,transitionStatus:F,props:E,refs:[i,R.useStateSetter("positionerElement")],hidden:!P,inert:!N}),ex=P&&"menu"!==T.type&&("menubar"!==T.type&&j&&_!==f.REASONS.triggerHover||"menubar"===T.type&&T.context.modal),ey=null;return"menubar"===T.type?ey=T.context.contentElement:void 0===T.type&&(ey=z),(0,O.jsxs)(r.Provider,{value:ep,children:[ex&&(0,O.jsx)(ee.InternalBackdrop,{ref:"context-menu"===T.type||"nested-context-menu"===T.type?T.context.internalBackdropRef:null,inert:(0,Y.inertValue)(!N),cutout:ey}),(0,O.jsx)(X.FloatingNode,{id:B,children:(0,O.jsx)(Z.CompositeList,{elementsRef:R.context.itemDomElements,labelsRef:R.context.itemLabels,children:eb})})]})});e.s(["MenuPositioner",0,eo],82264);var es=e.i(67865);let ea=t.createContext(void 0),el=t.memo(t.forwardRef(function(e,n){let{render:r,className:i,value:o,defaultValue:s,onValueChange:l,disabled:u=!1,style:c,"aria-labelledby":d,...f}=e,[p,g]=t.useState(void 0),[h,v]=(0,m.useControlled)({controlled:o,default:s,name:"MenuRadioGroup"}),b=(0,es.useStableCallback)((e,t)=>{l?.(e,t),t.isCanceled||v(e)}),x=(0,a.useRenderElement)("div",e,{state:{disabled:u},ref:n,props:{role:"group","aria-labelledby":d??p,"aria-disabled":u||void 0,...f}}),y=t.useMemo(()=>({value:h,setValue:b,disabled:u}),[h,b,u]);return(0,O.jsx)(j.Provider,{value:g,children:(0,O.jsx)(ea.Provider,{value:y,children:x})})}));e.s(["MenuRadioGroup",0,el],62050);let eu=t.createContext(void 0),ec=t.forwardRef(function(e,r){let{render:o,className:l,id:u,label:c,nativeButton:d=!1,disabled:p=!1,closeOnClick:m=!1,value:h,style:v,...b}=e,x=(0,w.useCompositeListItem)({guess:!0,label:c}),y=i(!0),S=(0,I.useBaseUiId)(u),{store:C}=s(),M=C.useState("isActive",x.index),A=C.useState("itemProps"),{value:P,setValue:N,disabled:j}=function(){let e=t.useContext(ea);if(void 0===e)throw Error((0,n.default)(34));return e}(),L=C.useState("disabled"),D=p||j||L,z=P===h,{getItemProps:F,itemRef:H}=R({closeOnClick:m,disabled:D,highlighted:M,id:S,store:C,nativeButton:d,nodeId:y?.context.nodeId,itemMetadata:E}),V=t.useMemo(()=>({disabled:D,highlighted:M,checked:z}),[D,M,z]),q=(0,a.useRenderElement)("div",e,{state:V,stateAttributesMapping:T,props:[A,{role:"menuitemradio","aria-checked":z,onClick:function(e){N(h,(0,k.createChangeEventDetails)(f.REASONS.itemPress,e.nativeEvent,void 0,{preventUnmountOnClose:g.NOOP}))}},b,F],ref:[H,r,x.ref]});return(0,O.jsx)(eu.Provider,{value:V,children:q})});e.s(["MenuRadioItem",0,ec],82593);let ed=t.forwardRef(function(e,r){let{render:i,className:o,style:s,keepMounted:l=!1,...u}=e,c=function(){let e=t.useContext(eu);if(void 0===e)throw Error((0,n.default)(35));return e}(),d=t.useRef(null),{transitionStatus:f,mounted:p,setMounted:m}=(0,A.useTransitionStatus)(c.checked);(0,P.useOpenChangeComplete)({batch:!0,enabled:!c.checked,open:c.checked,ref:d,onComplete(){c.checked||m(!1)}});let g={checked:c.checked,disabled:c.disabled,highlighted:c.highlighted,transitionStatus:f};return(0,a.useRenderElement)("span",e,{state:g,stateAttributesMapping:T,ref:[r,d],props:{"aria-hidden":!0,...u},enabled:l||p})});e.s(["MenuRadioItemIndicator",0,ed],5953);var ef=e.i(83977),ep=e.i(88940),em=e.i(96499),eg=e.i(17989),eh=e.i(60891),ev=e.i(5049),eb=e.i(50527);let ex=t.createContext(null);function ey(e){let r=t.useContext(ex);if(null===r&&!e)throw Error((0,n.default)(5));return r}e.s(["useMenubarContext",0,ey],7447);var eS=e.i(72855),eC=e.i(32199),eE=e.i(26352),eR=e.i(79248),ew=e.i(18478),eI=e.i(16786),eT=e.i(90627);let ek={...eI.popupStoreSelectors,disabled:e=>"menubar"===e.parent.type&&e.parent.context.disabled||e.disabled,modal:e=>(void 0===e.parent.type||"context-menu"===e.parent.type)&&(e.modal??!0),openMethod:e=>e.openMethod,allowMouseEnter:e=>e.allowMouseEnter,highlightItemOnHover:e=>e.highlightItemOnHover,parent:e=>e.parent,rootId:e=>"menu"===e.parent.type?e.parent.store.select("rootId"):void 0!==e.parent.type?e.parent.context.rootId:e.rootId,activeIndex:e=>e.activeIndex,isActive:(e,t)=>e.activeIndex===t,hoverEnabled:e=>e.hoverEnabled,instantType:e=>e.instantType,lastOpenChangeReason:e=>e.openChangeReason,floatingTreeRoot:e=>"menu"===e.parent.type?e.parent.store.select("floatingTreeRoot"):e.floatingTreeRoot,floatingNodeId:e=>e.floatingNodeId,floatingParentNodeId:e=>e.floatingParentNodeId,itemProps:e=>e.itemProps,closeDelay:e=>e.closeDelay,adaptiveOrigin:e=>e.adaptiveOrigin,keyboardEventRelay:e=>e.keyboardEventRelay?e.keyboardEventRelay:"menu"===e.parent.type?e.parent.store.select("keyboardEventRelay"):void 0};class eO extends eE.ReactStore{constructor(e,t,n=!1){const r=new eT.PopupTriggerMap;super(eA(r,t,n,e),eM(r),ek),this.unsubscribeParentListener=this.observe("parent",e=>{if(this.unsubscribeParentListener?.(),"menu"===e.type){let t=e.store.select("rootId"),n=e.store.select("floatingTreeRoot"),r=e.store.select("keyboardEventRelay");this.unsubscribeParentListener=e.store.subscribe(()=>{let i=e.store.select("rootId"),o=e.store.select("floatingTreeRoot"),s=e.store.select("keyboardEventRelay");(t!==i||n!==o||r!==s)&&(t=i,n=o,r=s,this.notifyAll())}),this.context.allowMouseUpTriggerRef=e.store.context.allowMouseUpTriggerRef;return}void 0!==e.type&&(this.context.allowMouseUpTriggerRef=e.context.allowMouseUpTriggerRef),this.unsubscribeParentListener=null})}setOpen(e,t){this.state.floatingRootContext.context.events.emit("setOpen",{open:e,eventDetails:t})}unsubscribeParentListener=null}function eM(e){return{positionerRef:t.createRef(),popupRef:t.createRef(),typingRef:{current:!1},itemDomElements:{current:[]},itemLabels:{current:[]},allowMouseUpTriggerRef:{current:!1},triggerFocusTargetRef:t.createRef(),beforeContentFocusGuardRef:t.createRef(),onOpenChangeComplete:void 0,triggerElements:e}}function eA(e,t,n=!1,r){return{...(0,eI.createInitialPopupStoreState)(e,t,n),disabled:!1,modal:!0,openMethod:null,allowMouseEnter:!1,highlightItemOnHover:!0,parent:{type:void 0},rootId:void 0,activeIndex:null,hoverEnabled:!0,instantType:void 0,openChangeReason:null,floatingTreeRoot:new eR.FloatingTreeStore,floatingNodeId:void 0,floatingParentNodeId:null,itemProps:g.EMPTY_OBJECT,keyboardEventRelay:void 0,closeDelay:0,adaptiveOrigin:void 0,...r}}e.s(["MenuStore",0,eO,"createNullMenuStore",0,function(){let e=new eT.PopupTriggerMap;return Object.assign(new ew.NullStore(Object.freeze(eA(e)),Object.freeze(eM(e)),ek),{setOpen:g.NOOP})}],36481);var eP=e.i(64111);let eN=t.createContext(void 0);function ej(){return t.useContext(eN)}e.s(["MenuSubmenuRootContext",0,eN,"useMenuSubmenuRootContext",0,ej],74671);let eL=(0,em.fastComponent)(function(e){var n,r,i;let a,{children:l,open:u,onOpenChange:c,onOpenChangeComplete:p,defaultOpen:m=!1,disabled:h=!1,modal:v,loopFocus:b=!0,orientation:y="vertical",actionsRef:S,closeParentOnEsc:C=!1,handle:E,triggerId:R,defaultTriggerId:w=null,highlightItemOnHover:I=!0}=e,T=d(!0),M=s(!0),A=ey(!0),P=ej(),N=t.useMemo(()=>P&&M?{type:"menu",store:M.store}:A?{type:"menubar",context:A}:T&&!M?{type:"context-menu",context:T}:{type:void 0},[T,M,A,P]),j=(0,ef.useId)(),L=(0,ef.useId)(),z=(0,X.useFloatingParentNodeId)(),F="menu"===N.type?N.store:void 0,H=(u??m)&&F?.state.transitionStatus==="starting",V=(0,ep.useRefWithInit)(()=>H?F?.state.instantType:void 0).current,q=(n={open:m,openProp:u,activeTriggerId:w,triggerIdProp:R,parent:N,disabled:h,highlightItemOnHover:I,modal:void 0===N.type?v:void 0,rootId:j,instantType:V},r=L,i=null!=z,(0,ep.useRefWithInit)(()=>new eO(n,r,i)).current);q.useControlledProp("openProp",u),q.useControlledProp("triggerIdProp",R),q.useContextCallback("onOpenChangeComplete",p);let _=q.useState("floatingTreeRoot"),B=(0,X.useFloatingNodeId)(_),W=q.useState("open"),$=q.useState("activeTriggerElement"),U=q.useState("positionerElement"),K=q.useState("hoverEnabled"),G=q.useState("disabled"),Y=q.useState("lastOpenChangeReason"),J=q.useState("parent"),Z=q.useState("activeIndex"),ee=q.useState("payload"),er=q.useState("floatingParentNodeId"),ei=t.useRef(null),eo=t.useRef("context-menu"!==J.type),ea=(0,Q.useTimeout)(),el=t.useRef(!0),eu=(0,Q.useTimeout)(),ec=null!=er,{openMethod:ed,triggerProps:em}=(0,eC.useOpenInteractionType)(W);q.useSyncedValues({disabled:h,highlightItemOnHover:I,modal:void 0===J.type?v:void 0,openMethod:ed,rootId:j}),(0,eP.useImplicitActiveTrigger)(q);let{forceUnmount:ex,transitionStatus:eE}=(0,eP.useOpenStateTransitions)(W,q,()=>{q.set("allowMouseEnter",!1)},H),eR=(0,en.useAnimationsFinished)(q.context.popupRef);t.useEffect(()=>{if(void 0===V)return;let e=()=>{q.state.instantType===V&&q.set("instantType",void 0)};if(!W)return void e();if(void 0!==eE)return;if(null==q.context.popupRef.current)return void e();let t=new AbortController;return eR(e,t.signal),()=>{t.abort()}},[V,W,eE,eR,q]),(0,D.useIsoLayoutEffect)(()=>{T&&!M?q.update({parent:{type:"context-menu",context:T},floatingNodeId:B,floatingParentNodeId:z}):M&&q.update({floatingNodeId:B,floatingParentNodeId:z})},[T,M,B,z,q]),t.useEffect(()=>{if(W||(ei.current=null),"context-menu"===J.type){if(!W){ea.clear(),eo.current=!1;return}ea.start(500,()=>{eo.current=!0})}},[ea,W,J.type]),(0,D.useIsoLayoutEffect)(()=>{W||K||q.set("hoverEnabled",!0)},[W,K,q]);let ew=(0,es.useStableCallback)((e,t)=>{let n=t.reason;if(!e&&!q.select("open")||W===e&&t.trigger===$&&Y===n)return;let r=(0,eP.attachPreventUnmountOnClose)(t);if(e||null!=t.trigger||(t.trigger=$??void 0),c?.(e,t),t.isCanceled)return;q.state.floatingRootContext.dispatchOpenChange(e,t);let i=t.event;if(!1===e&&i?.type==="click"&&"touch"===i.pointerType&&!el.current)return;e&&n===f.REASONS.triggerFocus?(el.current=!1,eu.start(300,()=>{el.current=!0})):(el.current=!0,eu.clear());let o=(n===f.REASONS.triggerPress||n===f.REASONS.itemPress)&&0===i.detail,s=!e&&(n===f.REASONS.escapeKey||null==n);ei.current=t.event;let a=(0,eP.createPopupOpenState)(q.state,e,t.trigger,r());a.openChangeReason=n,"menubar"===J.type&&(n===f.REASONS.triggerFocus||n===f.REASONS.focusOut||n===f.REASONS.triggerHover||n===f.REASONS.listNavigation||n===f.REASONS.siblingOpen)?a.instantType="group":o||s?a.instantType=o?"click":"dismiss":a.instantType=void 0,q.update(a)}),eI=(0,eb.useSyncedFloatingRootContext)({popupStore:q,floatingRootContext:q.state.floatingRootContext,floatingId:L,nested:null!=z,onOpenChange:ew}),eT=eI.context.events;(0,D.useIsoLayoutEffect)(()=>{let e=({open:e,eventDetails:t})=>ew(e,t);return eT.on("setOpen",e),()=>{eT?.off("setOpen",e)}},[eT,ew]);let ek=t.useCallback(()=>{q.setOpen(!1,(0,k.createChangeEventDetails)(f.REASONS.imperativeAction))},[q]);t.useImperativeHandle(S,()=>({unmount:ex,close:ek}),[ex,ek]),"context-menu"===J.type&&(a=J.context),t.useImperativeHandle(a?.positionerRef,()=>U,[U]),t.useImperativeHandle(a?.actionsRef,()=>({setOpen:ew}),[ew]);let eM=(0,eg.useDismiss)(eI,{enabled:!G,bubbles:{escapeKey:C&&"menu"===J.type},outsidePress:()=>"context-menu"!==J.type||ei.current?.type==="contextmenu"||eo.current,externalTree:ec?_:void 0}),eA=(0,eS.useDirection)(),eN=t.useCallback(e=>{q.select("activeIndex")!==e&&q.set("activeIndex",e)},[q]),eL=(0,eh.useListNavigation)(eI,{enabled:!G,listRef:q.context.itemDomElements,activeIndex:Z,nested:void 0!==J.type,loopFocus:b,orientation:y,parentOrientation:"menubar"===J.type?J.context.orientation:void 0,rtl:"rtl"===eA,disabledIndices:g.EMPTY_ARRAY,onNavigate:eN,openOnArrowKeyDown:"context-menu"!==J.type,externalTree:ec?_:void 0,focusItemOnHover:I}),eD=t.useCallback(e=>{q.context.typingRef.current=e},[q]),ez=(0,ev.useTypeahead)(eI,{enabled:!G,listRef:q.context.itemLabels,elementsRef:q.context.itemDomElements,activeIndex:Z,resetMs:et.TYPEAHEAD_RESET_MS,onMatch:e=>{W&&e!==Z&&q.set("activeIndex",e)},onTyping:eD}),eF=t.useMemo(()=>{let e=(0,x.mergeProps)(ez.reference,eL.reference,eM.reference,{onMouseMove(){q.set("allowMouseEnter",!0)}},em);return e["aria-haspopup"]="menu",e["aria-expanded"]=W,e},[q,ez.reference,eL.reference,eM.reference,em,W]),eH=t.useMemo(()=>{let e=(0,x.mergeProps)(eL.trigger,eM.trigger,em);return e["aria-haspopup"]="menu",e["aria-expanded"]=!1,e},[eL.trigger,eM.trigger,em]);(0,ep.useRefWithInit)(()=>(q.update({inactiveTriggerProps:eH}),null));let eV=t.useMemo(()=>(0,x.mergeProps)(eP.FOCUSABLE_POPUP_PROPS,{id:L,role:"menu","aria-orientation":"horizontal"===y?"horizontal":void 0,"aria-labelledby":$?.id,onMouseMove(){q.set("allowMouseEnter",!0),"menu"===J.type&&q.set("hoverEnabled",!1)},onClick(){q.select("hoverEnabled")&&q.set("hoverEnabled",!1)},onKeyDown(e){let t=q.select("keyboardEventRelay");t&&!e.isPropagationStopped()&&t(e)}},ez.floating,eL.floating,eM.floating),[$,L,y,J.type,q,ez.floating,eL.floating,eM.floating]),eq=eL.item??g.EMPTY_OBJECT;(0,eP.usePopupInteractionProps)(q,{floatingRootContext:eI,activeTriggerProps:eF,inactiveTriggerProps:eH,popupProps:eV,itemProps:eq});let e_=t.useMemo(()=>({store:q,parent:N}),[q,N]),eB=(0,O.jsxs)(o.Provider,{value:e_,children:[E&&(0,O.jsx)(eP.PopupHandleAttachment,{handle:E,store:q}),"function"==typeof l?l({payload:ee}):l]});return void 0===J.type||"context-menu"===J.type?(0,O.jsx)(X.FloatingTree,{externalTree:_,children:eB}):eB});e.s(["MenuRoot",0,eL],63947),e.s(["MenuSubmenuRoot",0,function(e){let n=s().store,r=t.useMemo(()=>({parentMenu:n}),[n]);return(0,O.jsx)(eN.Provider,{value:r,children:(0,O.jsx)(eL,{...e})})}],77450)},92235,10913,64493,69153,40370,89244,e=>{"use strict";var t=e.i(71645),n=e.i(29315),r=e.i(61487),i=e.i(31157),o=e.i(22646),s=e.i(73336),a=e.i(79938),l=e.i(37584),u=e.i(52245),c=e.i(56434),d=e.i(73327),f=e.i(96533),p=e.i(53984),m=e.i(46376),g=e.i(67865);let h=t.createContext(void 0);var v=e.i(64111),b=e.i(43476);let x=t.forwardRef(function(e,m){let{render:x,className:y,style:S,initialFocus:C,finalFocus:E,...R}=e,w=(0,o.usePopoverRootContext)(),I=(0,s.usePopoverPositionerContext)(),T=null!=(0,f.useToolbarRootContext)(!0),{context:k,hasClosePart:O}=function(){let[e,n]=t.useState(0),r=(0,g.useStableCallback)(()=>(n(e=>e+1),()=>{n(e=>Math.max(0,e-1))}));return{context:t.useMemo(()=>({register:r}),[r]),hasClosePart:e>0}}(),M=w.useState("open"),A=w.useState("openMethod"),P=w.useState("instantType"),N=w.useState("transitionStatus"),j=w.useState("popupProps"),L=w.useState("titleElementId"),D=w.useState("descriptionElementId"),z=w.useState("modal"),F=w.useState("mounted"),H=w.useState("openChangeReason"),V=w.useState("activeTriggerElement"),q=w.useState("floatingRootContext"),_=q.useState("floatingId"),B=w.useState("disabled"),W=w.useState("openOnHover"),$=w.useState("closeDelay");(0,l.useOpenChangeComplete)({open:M,ref:w.context.popupRef,onComplete(){M&&w.context.onOpenChangeComplete?.(!0)}}),(0,i.useHoverFloatingInteraction)(q,{enabled:W&&!B,closeDelay:$});let U=void 0===C?(0,v.createDefaultInitialFocus)(w.context.popupRef):C,K=!1!==z&&O;w.useSyncedValue("focusManagerModal",K);let G=w.useStateSetter("popupElement"),Y={open:M,side:I.side,align:I.align,instant:P,transitionStatus:N},Q=(0,u.useRenderElement)("div",e,{state:Y,ref:[m,w.context.popupRef,G],props:[j,{id:_,role:"dialog",...v.FOCUSABLE_POPUP_PROPS,"aria-labelledby":L,"aria-describedby":D,onKeyDown(e){T&&d.COMPOSITE_KEYS.has(e.key)&&e.stopPropagation()}},(0,p.getDisabledMountTransitionStyles)(N),R],stateAttributesMapping:a.popupTransitionStateMapping});return(0,b.jsx)(r.FloatingFocusManager,{context:q,openInteractionType:A,modal:K,disabled:!F||H===c.REASONS.triggerHover,initialFocus:U,returnFocus:E,restoreFocus:"popup",previousFocusableElement:(0,n.isHTMLElement)(V)?V:void 0,nextFocusableElement:w.context.triggerFocusTargetRef,beforeContentFocusGuardRef:w.context.beforeContentFocusGuardRef,children:(0,b.jsx)(h.Provider,{value:k,children:Q})})});e.s(["PopoverPopup",0,x],92235);let y=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...l}=e,c=(0,o.usePopoverRootContext)().useState("open"),{arrowRef:d,side:f,align:p,arrowUncentered:m,arrowStyles:g}=(0,s.usePopoverPositionerContext)();return(0,u.useRenderElement)("div",e,{state:{open:c,side:f,align:p,uncentered:m},ref:[t,d],props:[{style:g,"aria-hidden":!0},l],stateAttributesMapping:a.popupStateMapping})});e.s(["PopoverArrow",0,y],10913);let S=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...s}=e,l=(0,o.usePopoverRootContext)(),d=l.useState("open"),f=l.useState("mounted"),p=l.useState("transitionStatus"),m=l.useState("openChangeReason");return(0,u.useRenderElement)("div",e,{state:{open:d,transitionStatus:p},ref:t,props:[{role:"presentation",hidden:!f,style:{pointerEvents:m===c.REASONS.triggerHover?"none":void 0,userSelect:"none",WebkitUserSelect:"none"}},s],stateAttributesMapping:a.popupTransitionStateMapping})});e.s(["PopoverBackdrop",0,S],64493);var C=e.i(88015);let E=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...s}=e,a=(0,o.usePopoverRootContext)(),l=(0,C.useBaseUiId)(s.id);return a.useSyncedValueWithCleanup("titleElementId",l),(0,u.useRenderElement)("h2",e,{ref:t,props:[{id:l},s]})});e.s(["PopoverTitle",0,E],69153);let R=t.forwardRef(function(e,t){let{render:n,className:r,style:i,...s}=e,a=(0,o.usePopoverRootContext)(),l=(0,C.useBaseUiId)(s.id);return a.useSyncedValueWithCleanup("descriptionElementId",l),(0,u.useRenderElement)("p",e,{ref:t,props:[{id:l},s]})});e.s(["PopoverDescription",0,R],40370);var w=e.i(40886),I=e.i(75606);let T=t.forwardRef(function(e,n){let r,{render:i,className:s,style:a,disabled:l=!1,nativeButton:d=!0,...f}=e,{buttonRef:p,getButtonProps:g}=(0,w.useButton)({disabled:l,focusableWhenDisabled:!1,native:d}),v=(0,o.usePopoverRootContext)();return r=t.useContext(h),(0,m.useIsoLayoutEffect)(()=>r?.register(),[r]),(0,u.useRenderElement)("button",e,{ref:[n,p],props:[{onClick(e){v.setOpen(!1,(0,I.createChangeEventDetails)(c.REASONS.closePress,e.nativeEvent))}},f,g]})});e.s(["PopoverClose",0,T],89244)},59657,e=>{"use strict";e.s([])},49637,73364,e=>{"use strict";var t,n=e.i(71645),r=e.i(29315),i=e.i(46802),o=e.i(33848),s=e.i(18593),a=e.i(93737),l=e.i(52245),u=e.i(43084);function c(e){let t=(0,r.getComputedStyle)(e),n=parseFloat(t.width)||0,i=parseFloat(t.height)||0,o=(0,r.isHTMLElement)(e),s=o?e.offsetWidth:n,a=o?e.offsetHeight:i;return((0,u.round)(n)!==s||(0,u.round)(i)!==a)&&(n=s,i=a),{width:n,height:i}}e.s(["getCssDimensions",0,c],73364);var d=e.i(1634),f=e.i(81524),p=e.i(7120),m=e.i(43476);let g={...f.tabsStateAttributesMapping,activeTabPosition:()=>null,activeTabSize:()=>null},h=n.forwardRef(function(e,u){let{className:f,render:h,renderBeforeHydration:x=!1,style:y,...S}=e,{getTabElementBySelectedValue:C,orientation:E,tabActivationDirection:R,value:w}=(0,d.useTabsRootContext)(),{tabsListElement:I,registerIndicatorUpdateListener:T}=(0,p.useTabsListContext)(),k=(0,i.useForcedRerendering)();n.useEffect(()=>T(k),[T,k]);let O=0,M=0,A=0,P=0,N=0,j=0,L=!1;if(null!=w&&null!=I){let e=C(w);if(null!=e){L=!0;let{width:t,height:n}=c(e),{width:i,height:s}=c(I),a=e.getBoundingClientRect(),l=I.getBoundingClientRect(),u=i>0?l.width/i:1,d=s>0?l.height/s:1,f=function(e,t){let n=v(e),i=v(t),o=n.left-i.left-t.clientLeft,s=n.top-i.top-t.clientTop,a=(0,r.getParentNode)(e);for(;(0,r.isHTMLElement)(a)&&a!==t&&!(0,r.isLastTraversableNode)(a);)o-=a.scrollLeft,s-=a.scrollTop,a=(0,r.getParentNode)(a);return{left:o,top:s}}(e,I);O=f.left,A=f.top;let p=(a.left-l.left)/u+I.scrollLeft-I.clientLeft,m=(a.top-l.top)/d+I.scrollTop-I.clientTop,g=function(e){let t=(0,o.ownerWindow)(e).getComputedStyle(e),{x:n,y:r}=function(e,t){let n=(t??(0,o.ownerWindow)(e).getComputedStyle(e)).transform,r=0,i=0,s=1;if(n&&"none"!==n){let e=n.match(/matrix(?:3d)?\(([^)]+)\)/);if(e){let t=e[1].split(", ").map(parseFloat);6===t.length?(r=t[4],i=t[5],s=Math.sqrt(t[0]*t[0]+t[1]*t[1])):16===t.length&&(r=t[12],i=t[13],s=t[0])}}return{x:r,y:i,scale:s}}(e,t),i=n,s=r,{translate:a}=t;if(a&&"none"!==a){let t=a.split(" ");i+=b(t[0],e.offsetWidth),s+=b(t[1],e.offsetHeight)}return{x:i,y:s}}(e);2>=Math.abs(p-g.x-O)&&2>=Math.abs(m-g.y-A)&&(O=p,A=m),N=t,j=n,M=I.scrollWidth-O-N,P=I.scrollHeight-A-j}}let D=L?{left:O,right:M,top:A,bottom:P}:null,z=L?{width:N,height:j}:null,F=L?{"--active-tab-left":`${O}px`,"--active-tab-right":`${M}px`,"--active-tab-top":`${A}px`,"--active-tab-bottom":`${P}px`,"--active-tab-width":`${N}px`,"--active-tab-height":`${j}px`}:void 0,H=L&&N>0&&j>0,V=(0,l.useRenderElement)("span",e,{state:{orientation:E,activeTabPosition:D,activeTabSize:z,tabActivationDirection:R},ref:u,props:[{role:"presentation",style:F,hidden:!H},S,{suppressHydrationWarning:!0}],stateAttributesMapping:g});return null==w?null:(0,m.jsxs)(n.Fragment,{children:[V,x&&(t||(t=(0,m.jsx)(a.PrehydrationScript,{script:s.script})))]})});function v(e){let t=0,n=0,r=e;for(;null!=r;){t+=r.offsetLeft,n+=r.offsetTop;let e=r.offsetParent;null!=e&&(t+=e.clientLeft,n+=e.clientTop),r=e}return{left:t,top:n}}function b(e,t){if(!e)return 0;let n=parseFloat(e);return Number.isFinite(n)?e.endsWith("%")?n/100*t:n:0}e.s(["TabsIndicator",0,h],49637)},49487,e=>{"use strict";var t=e.i(71645),n=e.i(44394),r=e.i(46376),i=e.i(88015),o=e.i(74354),s=e.i(37584),a=e.i(23910),l=e.i(52245),u=e.i(73553),c=e.i(81524),d=e.i(1634),f=e.i(80862),f=f;f.startingStyle,f.endingStyle;let p={...c.tabsStateAttributesMapping,...o.transitionStatusMapping},m=t.forwardRef(function(e,o){let{className:c,value:f,render:m,keepMounted:g=!1,style:h,...v}=e,{value:b,getTabIdByPanelValue:x,orientation:y,tabActivationDirection:S,registerMountedTabPanel:C}=(0,d.useTabsRootContext)(),E=(0,i.useBaseUiId)(),{ref:R,index:w}=(0,u.useCompositeListItem)(),I=f===b,{mounted:T,transitionStatus:k,setMounted:O}=(0,a.useTransitionStatus)(I),M=!T,A=x(f),P=t.useRef(null),N=(0,l.useRenderElement)("div",e,{state:{hidden:M,orientation:y,tabActivationDirection:S,transitionStatus:k},ref:[o,R,P],props:[{"aria-labelledby":A,hidden:M,id:E,role:"tabpanel",tabIndex:I?0:-1,inert:(0,n.inertValue)(!I),"data-index":w},v],stateAttributesMapping:p});return((0,s.useOpenChangeComplete)({open:I,ref:P,onComplete(){I||O(!1)}}),(0,r.useIsoLayoutEffect)(()=>{if(null!=E&&(!M||g))return C(f,E)},[M,g,f,E,C]),g||T)?N:null});e.s(["TabsPanel",0,m],49487)},41840,1634,81524,70359,e=>{"use strict";var t=e.i(71645),n=e.i(51437),r=e.i(46376),i=e.i(67865),o=e.i(52245),s=e.i(53687),a=e.i(33332);let l=t.createContext(void 0);e.s(["TabsRootContext",0,l,"useTabsRootContext",0,function(){let e=t.useContext(l);if(void 0===e)throw Error((0,a.default)(64));return e}],1634);let u={tabActivationDirection:e=>({"data-activation-direction":e})};e.s(["tabsStateAttributesMapping",0,u],81524);var c=e.i(75606),d=e.i(56434),f=e.i(43476);let p=t.forwardRef(function(e,a){let{className:p,defaultValue:h=0,onValueChange:v,orientation:b="horizontal",render:x,value:y,style:S,...C}=e,E=void 0!==e.defaultValue,R=t.useRef([]),[w,I]=t.useState(()=>new Map),[T,k]=(0,n.useControlled)({controlled:y,default:h,name:"Tabs",state:"value"}),O=void 0!==y,[M,A]=t.useState(()=>new Map),P=t.useRef(void 0),N=t.useCallback(e=>m(M,e),[M]),[j,L]=t.useState(()=>({previousValue:T,tabActivationDirection:"none"})),{previousValue:D,tabActivationDirection:z}=j,F=z,H=!1;D!==T&&(F=g(D,T,b,M),H=null!=D&&null!=T&&null==N(T));let V=H?D:T,q=D!==V||z!==F;(0,r.useIsoLayoutEffect)(()=>{q&&L({previousValue:V,tabActivationDirection:F})},[V,q,F]);let _=(0,i.useStableCallback)((e,t)=>{t.activationDirection=g(T,e,b,M),v?.(e,t),t.isCanceled||k(e)}),B=(0,i.useStableCallback)((e,t)=>{v?.(e,(0,c.createChangeEventDetails)(t,void 0,void 0,{activationDirection:"none"}))}),W=(0,i.useStableCallback)((e,t)=>(I(n=>{let r=new Map(n);return r.set(e,t),r}),()=>{I(n=>{if(n.get(e)!==t)return n;let r=new Map(n);return r.delete(e),r})})),$=t.useCallback(e=>w.get(e),[w]),U=t.useCallback(e=>{for(let t of M.values())if(e===t.value)return t.id},[M]),K=t.useMemo(()=>({getTabElementBySelectedValue:N,getTabIdByPanelValue:U,getTabPanelIdByValue:$,onValueChange:_,orientation:b,registerMountedTabPanel:W,setTabMap:A,tabActivationDirection:F,value:T}),[N,U,$,_,b,W,A,F,T]),G=t.useMemo(()=>{for(let e of M.values())if(e.value===T)return e},[M,T]),Y=t.useMemo(()=>{for(let e of M.values())if(!e.disabled)return e.value},[M]),Q=t.useRef(!E),X=t.useRef(h),J=t.useRef(E),Z=t.useRef(!1);(0,r.useIsoLayoutEffect)(()=>{if(O)return;function e(e,t){k(e),L({previousValue:e,tabActivationDirection:"none"}),B(e,t),Q.current=!1}if(0===M.size){Z.current&&null!==T&&!P.current?.isConnected&&e(null,d.REASONS.missing);return}Z.current=!0,P.current=M.keys().next().value;let t=G?.disabled,n=null==G&&null!==T;if(t||T!==X.current||(J.current=!1),J.current&&t&&T===X.current)return;let r=Q.current;if(t||n){let n=Y??null;if(T===n){Q.current=!1;return}let i=d.REASONS.missing;r?i=d.REASONS.initial:t&&(i=d.REASONS.disabled),e(n,i);return}r&&null!=G&&(B(T,d.REASONS.initial),Q.current=!1)},[Y,O,B,G,k,M,T]);let ee={orientation:b,tabActivationDirection:F},et=(0,o.useRenderElement)("div",e,{state:ee,ref:a,props:C,stateAttributesMapping:u});return(0,f.jsx)(l.Provider,{value:K,children:(0,f.jsx)(s.CompositeList,{elementsRef:R,children:et})})});function m(e,t){for(let[n,r]of e.entries())if(t===r.value)return n;return null}function g(e,t,n,r){if(null==e||null==t)return"none";let[i,o,s]="horizontal"===n?["left","left","right"]:["top","up","down"],a=m(r,e),l=m(r,t);if(null==a||null==l)return a!==l&&("number"==typeof e||"string"==typeof e)&&typeof e==typeof t?t>e?s:o:"none";let u=a.getBoundingClientRect()[i],c=l.getBoundingClientRect()[i];return c<u?o:c>u?s:"none"}e.s(["TabsRoot",0,p],41840),e.s(["ACTIVE_COMPOSITE_ITEM",0,"data-composite-item-active"],70359)},88368,95530,7120,46802,18593,1249,e=>{"use strict";var t=e.i(71645),n=e.i(8868),r=e.i(46376),i=e.i(67865),o=e.i(88015),s=e.i(52245),a=e.i(40886),l=e.i(70359),u=e.i(28918),c=e.i(38452),d=e.i(73553);function f(e={}){let{highlightItemOnHover:n,highlightedIndex:r,onHighlightedIndexChange:i}=(0,c.useCompositeRootContext)(),{ref:o,index:s}=(0,d.useCompositeListItem)(e),a=r===s,l=t.useRef(null),p=(0,u.useMergedRefs)(o,l);return{compositeProps:{tabIndex:a?0:-1,onFocus(){i(s)},onMouseMove(){let e=l.current;if(!n||!e)return;let t=e.hasAttribute("disabled")||"true"===e.ariaDisabled;a||t||e.focus()}},compositeRef:p,index:s}}e.s(["useCompositeItem",0,f],95530);var p=e.i(1634),m=e.i(81524),g=e.i(33332);let h=t.createContext(void 0);function v(){let e=t.useContext(h);if(void 0===e)throw Error((0,g.default)(65));return e}e.s(["TabsListContext",0,h,"useTabsListContext",0,v],7120);var b=e.i(75606),x=e.i(56434),y=e.i(84446);let S=t.forwardRef(function(e,u){let{className:d,disabled:g=!1,render:h,value:S,id:C,nativeButton:E=!0,style:R,...w}=e,{value:I,getTabPanelIdByValue:T,onValueChange:k,orientation:O,tabActivationDirection:M}=(0,p.useTabsRootContext)(),{activateOnFocus:A,registerTabResizeObserverElement:P,tabsListElement:N}=v(),{highlightedIndex:j,onHighlightedIndexChange:L}=(0,c.useCompositeRootContext)(),D=(0,o.useBaseUiId)(C),{compositeProps:z,compositeRef:F,index:H}=f({metadata:t.useMemo(()=>({disabled:g,id:D,value:S}),[g,D,S])}),V=S===I,q=t.useRef(!1),_=t.useRef(null),B=(0,i.useStableCallback)(e=>{_.current?.(),_.current=e?P(e):null});(0,r.useIsoLayoutEffect)(()=>{if(q.current){q.current=!1;return}if(V&&H>-1&&j!==H){if(null!=N){let e=(0,y.activeElement)((0,n.ownerDocument)(N));if(e&&(0,y.contains)(N,e))return}g||L(H)}},[V,H,j,L,g,N]);let{getButtonProps:W,buttonRef:$}=(0,a.useButton)({disabled:g,native:E,focusableWhenDisabled:!0}),U=T(S),K=t.useRef(!1),G=t.useRef(!1);function Y(e){k(S,(0,b.createChangeEventDetails)(x.REASONS.none,e.nativeEvent,void 0,{activationDirection:"none"}))}return(0,s.useRenderElement)("button",e,{state:{disabled:g,active:V,orientation:O,tabActivationDirection:M},ref:[u,$,F,B],props:[z,{role:"tab","aria-controls":U,"aria-selected":V,id:D,onClick:function(e){V||g||Y(e)},onFocus:function(e){V||g||A&&(!K.current||G.current)&&Y(e)},onPointerDown:function(e){if(V||g)return;K.current=!0,G.current=0===e.button;let t=(0,n.ownerDocument)(e.currentTarget);function r(){K.current=!1,G.current=!1,t.removeEventListener("pointerup",r),t.removeEventListener("pointercancel",r)}t.addEventListener("pointerup",r),t.addEventListener("pointercancel",r)},[l.ACTIVE_COMPOSITE_ITEM]:V?"":void 0,onKeyDownCapture(){q.current=!0}},w,W],stateAttributesMapping:m.tabsStateAttributesMapping})});e.s(["TabsTab",0,S],88368),e.s(["useForcedRerendering",0,function(){let[,e]=t.useState({});return t.useCallback(()=>{e({})},[])}],46802),e.s(["script",0,""],18593);var C=e.i(2239),E=e.i(56789);function R(){return E.NOOP}function w(){return!1}function I(){return!0}e.s(["useIsHydrating",0,function(){return(0,C.useSyncExternalStore)(R,w,I)}],1249)},96533,e=>{"use strict";e.i(47167);var t=e.i(33332),n=e.i(71645);let r=n.createContext(void 0);e.s(["useToolbarRootContext",0,function(e){let i=n.useContext(r);if(void 0===i&&!e)throw Error((0,t.default)(69));return i}])},38380,e=>{"use strict";var t=e.i(80862);let n=t.startingStyle,r=t.endingStyle;e.s(["align",0,"data-align","anchorHidden",0,"data-anchor-hidden","closed",0,"data-closed","endingStyle",0,r,"open",0,"data-open","side",0,"data-side","startingStyle",0,n])},15618,e=>{"use strict";e.s(["popupOpen",0,"data-popup-open","pressed",0,"data-pressed"])},52535,e=>{"use strict";e.i(47167);var t=e.i(71645),n=e.i(46376),r=e.i(28744),i=e.i(2077),o=e.i(43476);let s=t.forwardRef(function(e,s){let[a,l]=t.useState();return(0,n.useIsoLayoutEffect)(()=>{r.platform.screenReader.voiceOver&&r.platform.engine.webkit&&l("button")},[]),(0,o.jsx)("span",{...e,ref:s,style:i.visuallyHidden,"aria-hidden":!a||void 0,...{tabIndex:0,role:a},"data-base-ui-focus-guard":""})});e.s(["FocusGuard",0,s])},426,e=>{"use strict";e.i(47167);var t=e.i(71645),n=e.i(43476);let r=t.forwardRef(function(e,t){let r,{cutout:i,...o}=e;if(i){let e=i.getBoundingClientRect();r=`polygon(0% 0%,100% 0%,100% 100%,0% 100%,0% 0%,${e.left}px ${e.top}px,${e.left}px ${e.bottom}px,${e.right}px ${e.bottom}px,${e.right}px ${e.top}px,${e.left}px ${e.top}px)`}return(0,n.jsx)("div",{ref:t,role:"presentation","data-base-ui-inert":"",...o,style:{position:"fixed",inset:0,userSelect:"none",WebkitUserSelect:"none",clipPath:r}})});e.s(["InternalBackdrop",0,r])},64042,e=>{"use strict";var t=e.i(33848),n=e.i(28744);e.s(["isMouseWithinBounds",0,function(e,r){let i=function(e){let r=e.getBoundingClientRect(),i=(0,t.ownerWindow)(e);if(n.platform.env.jsdom)return r;let o=i.getComputedStyle(e,"::before"),s=i.getComputedStyle(e,"::after");if("none"===o.content&&"none"===s.content)return r;let a=parseFloat(o.width)||0,l=parseFloat(o.height)||0,u=parseFloat(s.width)||0,c=parseFloat(s.height)||0,d=Math.max(r.width,a,u),f=Math.max(r.height,l,c),p=d-r.width,m=f-r.height;return{left:r.left-p/2,right:r.right+p/2,top:r.top-m/2,bottom:r.bottom+m/2}}(r);return e.clientX>=i.left-5&&e.clientX<=i.right+5&&e.clientY>=i.top-5&&e.clientY<=i.bottom+5}])},18438,e=>{"use strict";e.i(47167);var t=e.i(71645),n=e.i(52245);let r=t.forwardRef(function(e,t){let{className:r,render:i,orientation:o="horizontal",style:s,...a}=e;return(0,n.useRenderElement)("div",e,{state:{orientation:o},ref:t,props:[{role:"presentation"},a]})});e.s(["ListboxSeparator",0,r])},79938,e=>{"use strict";var t=e.i(74354),n=e.i(38380),r=e.i(15618);let i={[r.popupOpen]:""},o={[r.popupOpen]:"",[r.pressed]:""},s={[n.open]:""},a={[n.closed]:""},l={[n.anchorHidden]:""},u={open:e=>e?s:a,anchorHidden:e=>e?l:null},c={...u,...t.transitionStatusMapping};e.s(["popupStateMapping",0,u,"popupTransitionStateMapping",0,c,"pressableTriggerOpenStateMapping",0,{open:e=>e?o:null},"triggerOpenStateMapping",0,{open:e=>e?i:null}])},64111,50527,e=>{"use strict";var t=e.i(71645),n=e.i(74080),r=e.i(56789),i=e.i(83977),o=e.i(67865),s=e.i(46376),a=e.i(88940),l=e.i(49055),u=e.i(46420),c=e.i(29315),d=e.i(56341);function f(e){let{popupStore:n,treatPopupAsFloatingElement:r=!1,floatingRootContext:i,floatingId:o,nested:a,onOpenChange:l}=e,u=n.useState("open"),f=n.useState("activeTriggerElement"),p=n.useState(r?"popupElement":"positionerElement"),m=n.context.triggerElements,g=t.useRef(null);void 0===i&&null===g.current&&(g.current=new d.FloatingRootStore({open:u,transitionStatus:void 0,referenceElement:f,floatingElement:p,triggerElements:m,onOpenChange:l,floatingId:o,syncOnly:!0,nested:a}));let h=i??g.current;return n.useSyncedValue("floatingId",o),(0,s.useIsoLayoutEffect)(()=>{let e={open:u,floatingId:o,referenceElement:f,floatingElement:p};(0,c.isElement)(f)&&(e.domReferenceElement=f),h.state.positionReference===h.state.referenceElement&&(e.positionReference=f),h.update(e)},[u,o,f,p,h]),h.context.onOpenChange=l,h.context.nested=a,h}e.s(["useSyncedFloatingRootContext",0,f],50527);var p=e.i(23910),m=e.i(37584),g=e.i(75606),h=e.i(56434);let v={tabIndex:-1,[l.FOCUSABLE_ATTRIBUTE]:""};function b(e){let t=e.context.triggerElements.size;e.select("open")&&e.state.triggerCount!==t&&e.set("triggerCount",t)}function x(e,n){let r=t.useRef(null);return(0,o.useStableCallback)(t=>{let i=r.current;if(null!==i){if(i.element===t&&i.store===n&&i.id===e)return;r.current=null;let o=i.store;o.context.triggerElements.getById(i.id)===i.element&&(o.context.triggerElements.delete(i.id),b(o))}null!==t&&void 0!==e&&(r.current={store:n,id:e,element:t},n.context.triggerElements.add(e,t),b(n))})}function y(e,t,n,r=!1){let i=e.preventUnmountingOnClose;t?i=!1:r&&(i=!0);let o=n?.id??null,s=e.activeTriggerId,a=e.activeTriggerElement;return(o||t)&&(s=o,a=n??null),{open:t,preventUnmountingOnClose:i,activeTriggerId:s,activeTriggerElement:a}}function S(e){let t=!1;return e.preventUnmountOnClose=()=>{t=!0},()=>t}e.s(["FOCUSABLE_POPUP_PROPS",0,v,"PopupHandleAttachment",0,function({handle:e,store:t}){return(0,s.useIsoLayoutEffect)(()=>e.attachStore(t),[e,t]),null},"applyPopupOpenChange",0,function(e,t,r,i={}){let o=r.reason,s=o===h.REASONS.triggerHover,a=t&&o===h.REASONS.triggerFocus,l=!t&&(o===h.REASONS.triggerPress||o===h.REASONS.escapeKey),u=S(r);if(e.context.onOpenChange?.(t,r),r.isCanceled)return;i.onBeforeDispatch?.(),e.state.floatingRootContext.dispatchOpenChange(t,r);let c=()=>{let n=y(e.state,t,r.trigger,u()),o={...i.extraState,...n};a?o.instantType="focus":l?o.instantType="dismiss":s&&(o.instantType=void 0),e.update(o)};s?n.flushSync(c):c()},"attachPreventUnmountOnClose",0,S,"createDefaultInitialFocus",0,function(e){return t=>"touch"!==t||e.current},"createPopupOpenState",0,y,"useImplicitActiveTrigger",0,function(e,n={}){let{closeOnActiveTriggerUnmount:r=!1}=n,i=t.useRef(null),o=e.useState("open"),a=e.useState("triggerCount"),l=e.useState("activeTriggerId"),u=e.useState("activeTriggerElement");(0,s.useIsoLayoutEffect)(()=>{if(!o){i.current=null,0!==e.state.triggerCount&&e.set("triggerCount",0);return}let t=e.context.triggerElements.size,n={};e.state.triggerCount!==t&&(n.triggerCount=t);let s=e.select("activeTriggerId"),a=null;if(s){let t=e.context.triggerElements.getById(s);if(t)i.current=s,t!==e.state.activeTriggerElement&&(n.activeTriggerElement=t);else{for(let[t,r]of e.context.triggerElements.entries())if(r===e.state.activeTriggerElement){n.activeTriggerId=t,n.activeTriggerElement=r,i.current=t;break}void 0===n.activeTriggerId&&(i.current===s?a=s:i.current=null)}}else i.current=null;if(!a&&!s&&1===t){let t=e.context.triggerElements.entries().next();if(!t.done){let[e,r]=t.value;n.activeTriggerId=e,n.activeTriggerElement=r,i.current=e}}(void 0!==n.triggerCount||void 0!==n.activeTriggerId||void 0!==n.activeTriggerElement)&&e.update(n),a&&r&&queueMicrotask(()=>{if(e.select("open")&&e.select("activeTriggerId")===a&&!e.context.triggerElements.getById(a)){let t=(0,g.createChangeEventDetails)(h.REASONS.none);e.setOpen(!1,t),t.isCanceled||e.update({activeTriggerId:null,activeTriggerElement:null})}})},[o,e,a,l,u,r])},"useOpenStateTransitions",0,function(e,t,n,r){let{mounted:i,setMounted:s,transitionStatus:a}=(0,p.useTransitionStatus)(e,!1,!1,r),l=t.useState("preventUnmountingOnClose"),u=!e&&l;t.useSyncedValues({mounted:i,transitionStatus:a,preventUnmountingOnClose:u});let c=(0,o.useStableCallback)(()=>{s(!1),t.update({activeTriggerId:null,activeTriggerElement:null,mounted:!1,preventUnmountingOnClose:!1}),n?.(),t.context.onOpenChangeComplete?.(!1)});return(0,m.useOpenChangeComplete)({enabled:i&&!e&&!u,open:e,ref:t.context.popupRef,onComplete(){e||c()}}),{forceUnmount:c,transitionStatus:a}},"usePopupInteractionProps",0,function(e,t){e.useSyncedValues(t),(0,s.useIsoLayoutEffect)(()=>()=>{e.update({activeTriggerProps:r.EMPTY_OBJECT,inactiveTriggerProps:r.EMPTY_OBJECT,popupProps:r.EMPTY_OBJECT})},[e])},"usePopupRootStore",0,function(e,t=!1){let n=(0,i.useId)(),r=null!=(0,u.useFloatingParentNodeId)(),o=(0,a.useRefWithInit)(()=>e(n,r)).current;return f({popupStore:o,treatPopupAsFloatingElement:t,floatingRootContext:o.state.floatingRootContext,floatingId:n,nested:r,onOpenChange:o.setOpen}),o},"usePopupRootSync",0,function(e,t){(0,s.useIsoLayoutEffect)(()=>{t||null===e.state.openMethod||e.set("openMethod",null)},[t,e]),(0,s.useIsoLayoutEffect)(()=>()=>{null!==e.state.openMethod&&e.set("openMethod",null)},[e])},"useTriggerDataForwarding",0,function(e,t,n,r){let i=n.useState("isMountedByTrigger",e),a=x(e,n),l=(0,o.useStableCallback)(t=>{let i=n.select("open"),o=n.select("activeTriggerId");if(o===e){let e={activeTriggerElement:t,...i?r:null};n.update(e);return}if(null==o&&i){let i={activeTriggerId:e??null,activeTriggerElement:t,...r};n.update(i)}}),u=(0,o.useStableCallback)(e=>{a(e),e&&l(e)});return(0,s.useIsoLayoutEffect)(()=>(u(t.current),()=>u(null)),[u,t,n,e]),(0,s.useIsoLayoutEffect)(()=>{if(i){let e={activeTriggerElement:t.current,...r};n.update(e)}},[i,n,t,...Object.values(r)]),{registerTrigger:u,isMountedByThisTrigger:i}},"useTriggerRegistration",0,x],64111)},90627,e=>{"use strict";e.i(47167),e.s(["PopupTriggerMap",0,class{constructor(){this.idMap=new Map}add(e,t){this.idMap.set(e,t)}delete(e){this.idMap.delete(e)}hasElement(e){for(let t of this.idMap.values())if(t===e)return!0;return!1}hasMatchingElement(e){for(let t of this.idMap.values())if(e(t))return!0;return!1}getById(e){return this.idMap.get(e)}entries(){return this.idMap.entries()}elements(){return this.idMap.values()}get size(){return this.idMap.size}}])},50001,e=>{"use strict";e.s(["getDefaultLabelId",0,function(e){return null==e?void 0:`${e}-label`},"resolveAriaLabelledBy",0,function(e,t){return e??t}])},33383,e=>{"use strict";var t=e.i(71645),n=e.i(8868),r=e.i(45484),i=e.i(46376);e.s(["useAnchoredPopupScrollLock",0,function(e,o,s,a){let[l,u]=t.useState(!1);(0,i.useIsoLayoutEffect)(()=>{if(!e||!o||null==s)return void u(!1);let t=(0,n.ownerDocument)(s).documentElement.clientWidth,r=s.offsetWidth;u(t>0&&r>0&&r>=t-20)},[e,o,s]),(0,r.useScrollLock)(e&&(!o||l),a)}])},32199,e=>{"use strict";var t=e.i(71645),n=e.i(67865),r=e.i(28744),i=e.i(6039);function o(e,i){var o;let s,a,{onClick:l,onPointerDown:u}=(o=(0,n.useStableCallback)((t,n)=>{("function"==typeof e?e():e)||i(n||(r.platform.os.ios?"touch":""))}),s=t.useRef(""),a=t.useCallback(e=>{e.defaultPrevented||(s.current=e.pointerType,o(e,e.pointerType))},[o]),{onClick:t.useCallback(e=>{0===e.detail?o(e,"keyboard"):("pointerType"in e?o(e,e.pointerType):o(e,s.current),s.current="")},[o]),onPointerDown:a});return t.useMemo(()=>({onClick:l,onPointerDown:u}),[l,u])}e.s(["useOpenInteractionType",0,function(e){let[n,r]=t.useState(null),s=o(e,r);return(0,i.useValueChanged)(e,t=>{t&&!e&&r(null)}),t.useMemo(()=>({openMethod:n,triggerProps:s}),[n,s])},"useOpenMethodTriggerProps",0,o],32199)},89579,53984,e=>{"use strict";var t=e.i(79938),n=e.i(52245),r=e.i(56789),i=e.i(38396);function o(e){return"starting"===e?i.DISABLED_TRANSITIONS_STYLE:r.EMPTY_OBJECT}e.s(["getDisabledMountTransitionStyles",0,o],53984),e.s(["usePositioner",0,function(e,r,{styles:i,transitionStatus:s,props:a,refs:l,hidden:u,inert:c=!1}){let d={...i};return c&&(d.pointerEvents="none"),(0,n.useRenderElement)("div",e,{state:r,ref:l,props:[{role:"presentation",hidden:u,style:d},o(s),a],stateAttributesMapping:t.popupStateMapping})}],89579)},74735,65420,e=>{"use strict";e.s(["addEventListener",0,function(e,t,n,r){return e.addEventListener(t,n,r),()=>{e.removeEventListener(t,n,r)}}],74735),e.s(["mergeCleanups",0,function(...e){return()=>{for(let t=0;t<e.length;t+=1){let n=e[t];n&&n()}}}],65420)},44394,e=>{"use strict";var t=e.i(58321);e.s(["inertValue",0,function(e){return(0,t.isReactVersionAtLeast)(19)?e:e?"true":void 0}])},90803,e=>{"use strict";e.s(["isElementDisabled",0,function(e){return null==e||e.hasAttribute("disabled")||"true"===e.getAttribute("aria-disabled")}])},28744,e=>{"use strict";e.s([],64949),e.i(64949);let{userAgent:t,platform:n,maxTouchPoints:r}="u"<typeof navigator?{userAgent:"",platform:"",maxTouchPoints:0}:{userAgent:navigator.userAgent,platform:navigator.platform??"",maxTouchPoints:navigator.maxTouchPoints??0},i=t.toLowerCase(),o=n.toLowerCase(),s=/^i(os$|p)/.test(o)||"macintel"===o&&r>1,a="android",l=o===a||i.includes(a),u=!s&&o.startsWith("mac"),c=o.startsWith("win"),d=!l&&/^(linux|chrome os)/.test(o),f=u||s;e.s(["android",0,l,"apple",0,f,"ios",0,s,"linux",0,d,"mac",0,u,"windows",0,c],3720);var p=e.i(3720);let m="u">typeof CSS&&!!CSS.supports?.("-webkit-backdrop-filter:none"),g=!m&&i.includes("firefox"),h=!m&&i.includes("chrom");e.s(["blink",0,h,"gecko",0,g,"webkit",0,m],79850);var v=e.i(79850);e.s(["voiceOver",0,f],99170);var b=e.i(99170);let x=/jsdom|happydom/.test(i);e.s(["jsdom",0,x],36174);var y=e.i(36174);e.s(["iOS",0,"@supports (-webkit-touch-callout: none)"],71351);var S=e.i(71351);e.s(["engine",0,v,"env",0,y,"mediaQuery",0,S,"os",0,p,"screenReader",0,b],79214);var C=e.i(79214);e.s(["platform",0,C],28744)},26352,96499,e=>{"use strict";let t;var n=e.i(71645),r=e.i(2239),i=e.i(30224),o=e.i(58321),s=e.i(88940);let a=[];function l(){return t}function u(e){a.push(e)}function c(e){let n=(n,r)=>{let i,o=(0,s.useRefWithInit)(d).current;try{for(let e of(t=o,a))e.before(o);for(let t of(i=e(n,r),a))t.after(o);o.didInitialize=!0}finally{t=void 0}return i};return n.displayName=e.displayName||e.name,n}function d(){return{didInitialize:!1}}e.s(["fastComponent",0,c,"fastComponentRef",0,function(e){return n.forwardRef(c(e))},"getInstance",0,l,"register",0,u],96499);let f=(0,o.isReactVersionAtLeast)(19)?function(e,t,i,o,s){let a,u=l();if(!u){let a;return a=n.useCallback(()=>t(e.getSnapshot(),i,o,s),[e,t,i,o,s]),(0,r.useSyncExternalStore)(e.subscribe,a,a)}let c=u.syncIndex;return u.syncIndex+=1,u.didInitialize?(a=u.syncHooks[c]).store===e&&a.selector===t&&Object.is(a.a1,i)&&Object.is(a.a2,o)&&Object.is(a.a3,s)||(a.store!==e&&(u.didChangeStore=!0),a.store=e,a.selector=t,a.a1=i,a.a2=o,a.a3=s,a.value=t(e.getSnapshot(),i,o,s)):(a={store:e,selector:t,a1:i,a2:o,a3:s,value:t(e.getSnapshot(),i,o,s)},u.syncHooks.push(a)),a.value}:function(e,t,n,r,o){return(0,i.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,e=>t(e,n,r,o))};u({before(e){e.syncIndex=0,e.didInitialize||(e.syncTick=1,e.syncHooks=[],e.didChangeStore=!0,e.getSnapshot=()=>{let t=!1;for(let n=0;n<e.syncHooks.length;n+=1){let r=e.syncHooks[n],i=r.selector(r.store.state,r.a1,r.a2,r.a3);Object.is(r.value,i)||(t=!0,r.value=i)}return t&&(e.syncTick+=1),e.syncTick})},after(e){e.syncHooks.length>0&&(e.didChangeStore&&(e.didChangeStore=!1,e.subscribe=t=>{let n=new Set;for(let t of e.syncHooks)n.add(t.store);let r=[];for(let e of n)r.push(e.subscribe(t));return()=>{for(let e of r)e()}}),(0,r.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getSnapshot))}});class p{static create(e){return new this(e)}constructor(e){this.state=e,this.listeners=new Set,this.updateTick=0}subscribe=e=>(this.listeners.add(e),()=>{this.listeners.delete(e)});getSnapshot=()=>this.state;setState(e){if(this.state===e)return;this.state=e,this.updateTick+=1;let t=this.updateTick;for(let n of this.listeners){if(t!==this.updateTick)return;n(e)}}update(e){for(let t in e)if(!Object.is(this.state[t],e[t]))return void this.setState({...this.state,...e})}set(e,t){Object.is(this.state[e],t)||this.setState({...this.state,[e]:t})}notifyAll(){let e={...this.state};this.setState(e)}use(e,t,n,r){return f(this,e,t,n,r)}}var m=e.i(67865),g=e.i(46376),h=e.i(56789);e.s(["ReactStore",0,class extends p{constructor(e,t={},n){super(e),this.context=t,this.selectors=n}useSyncedValue(e,t){n.useDebugValue(e);let r=this;(0,g.useIsoLayoutEffect)(()=>{r.state[e]!==t&&r.set(e,t)},[r,e,t])}useSyncedValueWithCleanup(e,t){let n=this;(0,g.useIsoLayoutEffect)(()=>(n.state[e]!==t&&n.set(e,t),()=>{n.set(e,void 0)}),[n,e,t])}useSyncedValues(e){let t=this,n=Object.values(e);(0,g.useIsoLayoutEffect)(()=>{t.update(e)},[t,...n])}useControlledProp(e,t){n.useDebugValue(e);let r=this,i=void 0!==t;(0,g.useIsoLayoutEffect)(()=>{i&&!Object.is(r.state[e],t)&&r.setState({...r.state,[e]:t})},[r,e,t,i])}select(e,t,n,r){return(0,this.selectors[e])(this.state,t,n,r)}useState(e,t,r,i){return n.useDebugValue(e),f(this,this.selectors[e],t,r,i)}useContextCallback(e,t){n.useDebugValue(e);let r=(0,m.useStableCallback)(t??h.NOOP);this.context[e]=r}useStateSetter(e){let t=n.useRef(void 0);return void 0===t.current&&(t.current=t=>{this.set(e,t)}),t.current}observe(e,t){let n,r=(n="function"==typeof e?e:this.selectors[e])(this.state);return t(r,r,this),this.subscribe(e=>{let i=n(e);if(!Object.is(r,i)){let e=r;r=i,t(i,e,this)}})}}],26352)},13203,e=>{"use strict";var t=e.i(71645);e.s(["useOnFirstRender",0,function(e){let n=t.useRef(!0);n.current&&(n.current=!1,e())}])},94258,e=>{"use strict";var t=e.i(71645);e.s(["usePreviousValue",0,function(e){let[n,r]=t.useState({current:e,previous:null});return Object.is(e,n.current)||r({current:e,previous:n.current}),n.previous}])},45484,e=>{"use strict";var t=e.i(29315),n=e.i(74735),r=e.i(28744),i=e.i(8868),o=e.i(33848),s=e.i(46376),a=e.i(39957),l=e.i(8445);let u={},c={},d="";function f(e,n){return(0,t.isOverflowElement)(e)?e:n}function p(e,t,n){return/hidden|clip/.test(e.getComputedStyle(f(t,n)).overflowY)}class m{lockCount=0;restore=null;timeoutLock=a.Timeout.create();timeoutUnlock=a.Timeout.create();acquire(e){return this.lockCount+=1,1===this.lockCount&&null===this.restore&&this.timeoutLock.start(0,()=>this.lock(e)),this.release}release=()=>{this.lockCount-=1,0===this.lockCount&&this.restore&&this.timeoutUnlock.start(0,this.unlock)};unlock=()=>{0===this.lockCount&&this.restore&&(this.restore?.(),this.restore=null)};lock(e){let t,s,a;if(0===this.lockCount||null!==this.restore)return;let m=(0,i.ownerDocument)(e),g=m.documentElement,h=m.body,v=(0,o.ownerWindow)(g);if(p(v,g,h)){let t=new v.MutationObserver(()=>{p(v,g,h)||(t.disconnect(),this.restore=null,this.lock(e))}),n={attributes:!0};t.observe(g,n),t.observe(h,n),this.restore=()=>t.disconnect();return}let b=r.platform.os.ios||!function(e){if("u"<typeof document)return!1;let t=(0,i.ownerDocument)(e);return(0,o.ownerWindow)(t).innerWidth-t.documentElement.clientWidth>0}(e);this.restore=b?(a={overflowY:(s=f((t=(0,i.ownerDocument)(e)).documentElement,t.body)).style.overflowY,overflowX:s.style.overflowX},Object.assign(s.style,{overflowY:"hidden",overflowX:"hidden"}),()=>{Object.assign(s.style,a)}):function(e){let t=(0,i.ownerDocument)(e),s=t.documentElement,a=t.body,p=(0,o.ownerWindow)(s),m=0,g=0,h=!1,v=l.AnimationFrame.create();if(r.platform.engine.webkit&&(p.visualViewport?.scale??1)!==1)return()=>{};function b(){let t=p.getComputedStyle(s),n=p.getComputedStyle(a),r=(t.scrollbarGutter||"").includes("both-edges")?"stable both-edges":"stable";m=s.scrollTop,g=s.scrollLeft,u={scrollbarGutter:s.style.scrollbarGutter,overflowY:s.style.overflowY,overflowX:s.style.overflowX},d=s.style.scrollBehavior,c={position:a.style.position,height:a.style.height,width:a.style.width,boxSizing:a.style.boxSizing,overflowY:a.style.overflowY,overflowX:a.style.overflowX,scrollBehavior:a.style.scrollBehavior};let o=s.scrollHeight>s.clientHeight,l=s.scrollWidth>s.clientWidth,v="scroll"===t.overflowY||"scroll"===n.overflowY,b="scroll"===t.overflowX||"scroll"===n.overflowX,x=Math.max(0,p.innerWidth-a.clientWidth),y=Math.max(0,p.innerHeight-a.clientHeight),S=parseFloat(n.marginTop)+parseFloat(n.marginBottom),C=parseFloat(n.marginLeft)+parseFloat(n.marginRight),E=f(s,a);if(h=function(e){if(!("u">typeof CSS&&CSS.supports&&CSS.supports("scrollbar-gutter","stable"))||"u"<typeof document)return!1;let t=(0,i.ownerDocument)(e),n=t.documentElement,r=f(n,t.body),o=r.style.overflowY,s=n.style.scrollbarGutter;n.style.scrollbarGutter="stable",r.style.overflowY="scroll";let a=r.offsetWidth;r.style.overflowY="hidden";let l=r.offsetWidth;return r.style.overflowY=o,n.style.scrollbarGutter=s,a===l}(e)){s.style.scrollbarGutter=r,E.style.overflowY="hidden",E.style.overflowX="hidden";return}Object.assign(s.style,{scrollbarGutter:r,overflowY:"hidden",overflowX:"hidden"}),(o||v)&&(s.style.overflowY="scroll"),(l||b)&&(s.style.overflowX="scroll"),Object.assign(a.style,{position:"relative",height:S||y?`calc(100dvh - ${S+y}px)`:"100dvh",width:C||x?`calc(100vw - ${C+x}px)`:"100vw",boxSizing:"border-box",overflowY:"hidden",overflowX:"hidden",scrollBehavior:"unset"}),a.scrollTop=m,a.scrollLeft=g,s.setAttribute("data-base-ui-scroll-locked",""),s.style.scrollBehavior="unset"}function x(){Object.assign(s.style,u),Object.assign(a.style,c),h||(s.scrollTop=m,s.scrollLeft=g,s.removeAttribute("data-base-ui-scroll-locked"),s.style.scrollBehavior=d)}b();let y=(0,n.addEventListener)(p,"resize",function(){x(),v.request(b)});return()=>{v.cancel(),x(),"function"==typeof p.removeEventListener&&y()}}(e)}}let g=new m;e.s(["useScrollLock",0,function(e=!0,t=null){(0,s.useIsoLayoutEffect)(()=>{if(e)return g.acquire(t)},[e,t])}])},46265,e=>{"use strict";var t=e.i(46376),n=e.i(88940);function r(e){let t={current:e,next:e,effect:()=>{t.current=t.next}};return t}e.s(["useValueAsRef",0,function(e){let i=(0,n.useRefWithInit)(r,e).current;return i.next=e,(0,t.useIsoLayoutEffect)(i.effect),i}])},2077,e=>{"use strict";let t={clipPath:"inset(50%)",overflow:"hidden",whiteSpace:"nowrap",border:0,padding:0,width:1,height:1,margin:-1},n={...t,position:"fixed",top:0,left:0},r={...t,position:"absolute"};e.s(["visuallyHidden",0,n,"visuallyHiddenInput",0,r])},53760,58950,88643,e=>{"use strict";var t=e.i(43084);function n(e,n,r){let i,{reference:o,floating:s}=e,a=(0,t.getSideAxis)(n),l=(0,t.getAlignmentAxis)(n),u=(0,t.getAxisLength)(l),c=(0,t.getSide)(n),d=o.x+o.width/2-s.width/2,f=o.y+o.height/2-s.height/2,p=o[u]/2-s[u]/2;switch(c){case"top":i={x:d,y:o.y-s.height};break;case"bottom":i={x:d,y:o.y+o.height};break;case"right":i={x:o.x+o.width,y:f};break;case"left":i={x:o.x-s.width,y:f};break;default:i={x:o.x,y:o.y}}let m=(0,t.getAlignment)(n);return m&&(i[l]+=p*("end"===m?1:-1)*(r&&"y"===a?-1:1)),i}async function r(e,n){var r;void 0===n&&(n={});let{x:i,y:o,platform:s,rects:a,elements:l,strategy:u}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:f="floating",altBoundary:p=!1,padding:m=0}=(0,t.evaluate)(n,e),g=(0,t.getPaddingObject)(m),h=l[p?"floating"===f?"reference":"floating":f],v=(0,t.rectToClientRect)(await s.getClippingRect({element:null==(r=await (null==s.isElement?void 0:s.isElement(h)))||r?h:h.contextElement||await (null==s.getDocumentElement?void 0:s.getDocumentElement(l.floating)),boundary:c,rootBoundary:d,strategy:u})),b="floating"===f?{x:i,y:o,width:a.floating.width,height:a.floating.height}:a.reference,x=await (null==s.getOffsetParent?void 0:s.getOffsetParent(l.floating)),y=await (null==s.isElement?void 0:s.isElement(x))&&await (null==s.getScale?void 0:s.getScale(x))||{x:1,y:1},S=(0,t.rectToClientRect)(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:b,offsetParent:x,strategy:u}):b);return{top:(v.top-S.top+g.top)/y.y,bottom:(S.bottom-v.bottom+g.bottom)/y.y,left:(v.left-S.left+g.left)/y.x,right:(S.right-v.right+g.right)/y.x}}let i=async(e,t,i)=>{let{placement:o="bottom",strategy:s="absolute",middleware:a=[],platform:l}=i,u=l.detectOverflow?l:{...l,detectOverflow:r},c=await (null==l.isRTL?void 0:l.isRTL(t)),d=await l.getElementRects({reference:e,floating:t,strategy:s}),{x:f,y:p}=n(d,o,c),m=o,g=0,h={};for(let r=0;r<a.length;r++){let i=a[r];if(!i)continue;let{name:v,fn:b}=i,{x:x,y:y,data:S,reset:C}=await b({x:f,y:p,initialPlacement:o,placement:m,strategy:s,middlewareData:h,rects:d,platform:u,elements:{reference:e,floating:t}});f=null!=x?x:f,p=null!=y?y:p,h[v]={...h[v],...S},C&&g<50&&(g++,"object"==typeof C&&(C.placement&&(m=C.placement),C.rects&&(d=!0===C.rects?await l.getElementRects({reference:e,floating:t,strategy:s}):C.rects),{x:f,y:p}=n(d,m,c)),r=-1)}return{x:f,y:p,placement:m,strategy:s,middlewareData:h}};function o(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function s(e){return t.sides.some(t=>e[t]>=0)}function a(e){let n=(0,t.min)(...e.map(e=>e.left)),r=(0,t.min)(...e.map(e=>e.top));return{x:n,y:r,width:(0,t.max)(...e.map(e=>e.right))-n,height:(0,t.max)(...e.map(e=>e.bottom))-r}}let l=new Set(["left","top"]);async function u(e,n){let{placement:r,platform:i,elements:o}=e,s=await (null==i.isRTL?void 0:i.isRTL(o.floating)),a=(0,t.getSide)(r),u=(0,t.getAlignment)(r),c="y"===(0,t.getSideAxis)(r),d=l.has(a)?-1:1,f=s&&c?-1:1,p=(0,t.evaluate)(n,e),{mainAxis:m,crossAxis:g,alignmentAxis:h}="number"==typeof p?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return u&&"number"==typeof h&&(g="end"===u?-1*h:h),c?{x:g*f,y:m*d}:{x:m*d,y:g*f}}var c=e.i(29315);function d(e){let n=(0,c.getComputedStyle)(e),r=parseFloat(n.width)||0,i=parseFloat(n.height)||0,o=(0,c.isHTMLElement)(e),s=o?e.offsetWidth:r,a=o?e.offsetHeight:i,l=(0,t.round)(r)!==s||(0,t.round)(i)!==a;return l&&(r=s,i=a),{width:r,height:i,$:l}}function f(e){return(0,c.isElement)(e)?e:e.contextElement}function p(e){let n=f(e);if(!(0,c.isHTMLElement)(n))return(0,t.createCoords)(1);let r=n.getBoundingClientRect(),{width:i,height:o,$:s}=d(n),a=(s?(0,t.round)(r.width):r.width)/i,l=(s?(0,t.round)(r.height):r.height)/o;return a&&Number.isFinite(a)||(a=1),l&&Number.isFinite(l)||(l=1),{x:a,y:l}}let m=(0,t.createCoords)(0);function g(e){let t=(0,c.getWindow)(e);return(0,c.isWebKit)()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:m}function h(e,n,r,i){var o;void 0===n&&(n=!1),void 0===r&&(r=!1);let s=e.getBoundingClientRect(),a=f(e),l=(0,t.createCoords)(1);n&&(i?(0,c.isElement)(i)&&(l=p(i)):l=p(e));let u=(void 0===(o=r)&&(o=!1),i&&o&&i===(0,c.getWindow)(a))?g(a):(0,t.createCoords)(0),d=(s.left+u.x)/l.x,m=(s.top+u.y)/l.y,h=s.width/l.x,v=s.height/l.y;if(a&&i){let e=(0,c.getWindow)(a),t=(0,c.isElement)(i)?(0,c.getWindow)(i):i,n=e,r=(0,c.getFrameElement)(n);for(;r&&t!==n;){let e=p(r),t=r.getBoundingClientRect(),i=(0,c.getComputedStyle)(r),o=t.left+(r.clientLeft+parseFloat(i.paddingLeft))*e.x,s=t.top+(r.clientTop+parseFloat(i.paddingTop))*e.y;d*=e.x,m*=e.y,h*=e.x,v*=e.y,d+=o,m+=s,n=(0,c.getWindow)(r),r=(0,c.getFrameElement)(n)}}return(0,t.rectToClientRect)({width:h,height:v,x:d,y:m})}function v(e,t){let n=(0,c.getNodeScroll)(e).scrollLeft;return t?t.left+n:h((0,c.getDocumentElement)(e)).left+n}function b(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-v(e,n),y:n.top+t.scrollTop}}function x(e,n,r){var i;let o;if("viewport"===n||"layoutViewport"===n)o=function(e,t,n){void 0===n&&(n="viewport");let r="layoutViewport"===n,i=(0,c.getWindow)(e),o=(0,c.getDocumentElement)(e),s=i.visualViewport,a=o.clientWidth,l=o.clientHeight,u=0,d=0;if(s){let e=!(0,c.isWebKit)()||"fixed"===t;r?e||(u=-s.offsetLeft,d=-s.offsetTop):(a=s.width,l=s.height,e&&(u=s.offsetLeft,d=s.offsetTop))}if(0>=v(o)){let e=o.ownerDocument,t=e.body,n=getComputedStyle(t),r="CSS1Compat"===e.compatMode&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,i=Math.abs(o.clientWidth-t.clientWidth-r),s="stable both-edges"===getComputedStyle(o).scrollbarGutter?i/2:i;s<=25&&(a-=s)}return{width:a,height:l,x:u,y:d}}(e,r,n);else if("document"===n){let n,r,s,a,l,u;i=(0,c.getDocumentElement)(e),n=(0,c.getNodeScroll)(i),r=i.ownerDocument.body,s=(0,t.max)(i.scrollWidth,i.clientWidth,r.scrollWidth,r.clientWidth),a=(0,t.max)(i.scrollHeight,i.clientHeight,r.scrollHeight,r.clientHeight),l=-n.scrollLeft+v(i),u=-n.scrollTop,"rtl"===(0,c.getComputedStyle)(r).direction&&(l+=(0,t.max)(i.clientWidth,r.clientWidth)-s),o={width:s,height:a,x:l,y:u}}else if((0,c.isElement)(n)){let e,t,i,s,a,l;t=(e=h(n,!0,"fixed"===r)).top+n.clientTop,i=e.left+n.clientLeft,s=p(n),a=n.clientWidth*s.x,l=n.clientHeight*s.y,o={width:a,height:l,x:i*s.x,y:t*s.y}}else{let t=g(e);o={x:n.x-t.x,y:n.y-t.y,width:n.width,height:n.height}}return(0,t.rectToClientRect)(o)}function y(e){return"static"===(0,c.getComputedStyle)(e).position}function S(e,t){if(!(0,c.isHTMLElement)(e)||"fixed"===(0,c.getComputedStyle)(e).position)return null;if(t)return t(e);let n=e.offsetParent;return(0,c.getDocumentElement)(e)===n&&(n=n.ownerDocument.body),n}function C(e,t){let n=(0,c.getWindow)(e);if((0,c.isTopLayer)(e))return n;if(!(0,c.isHTMLElement)(e)){let t=(0,c.getParentNode)(e);for(;t&&!(0,c.isLastTraversableNode)(t);){if((0,c.isElement)(t)&&!y(t))return t;t=(0,c.getParentNode)(t)}return n}let r=S(e,t);for(;r&&(0,c.isTableElement)(r)&&y(r);)r=S(r,t);return r&&(0,c.isLastTraversableNode)(r)&&y(r)&&!(0,c.isContainingBlock)(r)?n:r||(0,c.getContainingBlock)(e)||n}let E=async function(e){let n=this.getOffsetParent||C,r=this.getDimensions,i=await r(e.floating);return{reference:function(e,n,r){let i=(0,c.isHTMLElement)(n),o=(0,c.getDocumentElement)(n),s="fixed"===r,a=h(e,!0,s,n),l={scrollLeft:0,scrollTop:0},u=(0,t.createCoords)(0);if((i||!s)&&(("body"!==(0,c.getNodeName)(n)||(0,c.isOverflowElement)(o))&&(l=(0,c.getNodeScroll)(n)),i)){let e=h(n,!0,s,n);u.x=e.x+n.clientLeft,u.y=e.y+n.clientTop}!i&&o&&(u.x=v(o));let d=!o||i||s?(0,t.createCoords)(0):b(o,l);return{x:a.left+l.scrollLeft-u.x-d.x,y:a.top+l.scrollTop-u.y-d.y,width:a.width,height:a.height}}(e.reference,await n(e.floating),e.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}},R={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:n,rect:r,offsetParent:i,strategy:o}=e,s="fixed"===o,a=(0,c.getDocumentElement)(i),l=!!n&&(0,c.isTopLayer)(n.floating);if(i===a||l&&s)return r;let u={scrollLeft:0,scrollTop:0},d=(0,t.createCoords)(1),f=(0,t.createCoords)(0),m=(0,c.isHTMLElement)(i);if((m||!s)&&(("body"!==(0,c.getNodeName)(i)||(0,c.isOverflowElement)(a))&&(u=(0,c.getNodeScroll)(i)),m)){let e=h(i);d=p(i),f.x=e.x+i.clientLeft,f.y=e.y+i.clientTop}let g=!a||m||s?(0,t.createCoords)(0):b(a,u);return{width:r.width*d.x,height:r.height*d.y,x:r.x*d.x-u.scrollLeft*d.x+f.x+g.x,y:r.y*d.y-u.scrollTop*d.y+f.y+g.y}},getDocumentElement:c.getDocumentElement,getClippingRect:function(e){let{element:n,boundary:r,rootBoundary:i,strategy:o}=e,s=[..."clippingAncestors"===r?(0,c.isTopLayer)(n)?[]:function(e,t){let n=t.get(e);if(n)return n;let r=(0,c.getOverflowAncestors)(e,[],!1).filter(e=>(0,c.isElement)(e)&&"body"!==(0,c.getNodeName)(e)),i=null,o="fixed"===(0,c.getComputedStyle)(e).position,s=o?(0,c.getParentNode)(e):e;for(;(0,c.isElement)(s)&&!(0,c.isLastTraversableNode)(s);){let e=(0,c.getComputedStyle)(s),t=(0,c.isContainingBlock)(s),n=i?i.position:o?"fixed":"";t||"fixed"!==n&&("absolute"!==n||"static"!==e.position)?i=e:r=r.filter(e=>e!==s),s=(0,c.getParentNode)(s)}return t.set(e,r),r}(n,this._c):[].concat(r),i],a=x(n,s[0],o),l=a.top,u=a.right,d=a.bottom,f=a.left;for(let e=1;e<s.length;e++){let r=x(n,s[e],o);l=(0,t.max)(r.top,l),u=(0,t.min)(r.right,u),d=(0,t.min)(r.bottom,d),f=(0,t.max)(r.left,f)}return{width:u-f,height:d-l,x:f,y:l}},getOffsetParent:C,getElementRects:E,getClientRects:function(e){return e.getClientRects?Array.from(e.getClientRects()):[]},getDimensions:function(e){let{width:t,height:n}=d(e);return{width:t,height:n}},getScale:p,isElement:c.isElement,isRTL:function(e){return"rtl"===(0,c.getComputedStyle)(e).direction}};function w(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}let I=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;let{x:i,y:o,placement:s,middlewareData:a}=t,l=await u(t,e);return s===(null==(n=a.offset)?void 0:n.placement)&&null!=(r=a.arrow)&&r.alignmentOffset?{}:{x:i+l.x,y:o+l.y,data:{...l,placement:s}}}}},T=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(n){let{x:r,y:i,placement:o,platform:s}=n,{mainAxis:a=!0,crossAxis:l=!1,limiter:u={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...c}=(0,t.evaluate)(e,n),d={x:r,y:i},f=await s.detectOverflow(n,c),p=(0,t.getSideAxis)(o),m=(0,t.getOppositeAxis)(p),g=d[m],h=d[p],v=(e,n)=>(0,t.clamp)(n+f["y"===e?"top":"left"],n,n-f["y"===e?"bottom":"right"]);a&&(g=v(m,g)),l&&(h=v(p,h));let b=u.fn({...n,[m]:g,[p]:h});return{...b,data:{x:b.x-r,y:b.y-i,enabled:{[m]:a,[p]:l}}}}}},k=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(n){var r,i,o,s,a;let{placement:l,middlewareData:u,rects:c,initialPlacement:d,platform:f,elements:p}=n,{mainAxis:m=!0,crossAxis:g=!0,fallbackPlacements:h,fallbackStrategy:v="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:x=!0,...y}=(0,t.evaluate)(e,n);if(null!=(r=u.arrow)&&r.alignmentOffset)return{};let S=(0,t.getSide)(l),C=(0,t.getSideAxis)(d),E=(0,t.getSide)(d)===d,R=await (null==f.isRTL?void 0:f.isRTL(p.floating)),w=h||(E||!x?[(0,t.getOppositePlacement)(d)]:(0,t.getExpandedPlacements)(d)),I="none"!==b;!h&&I&&w.push(...(0,t.getOppositeAxisPlacements)(d,x,b,R));let T=[d,...w],k=await f.detectOverflow(n,y),O=[],M=(null==(i=u.flip)?void 0:i.overflows)||[];if(m&&O.push(k[S]),g){let e=(0,t.getAlignmentSides)(l,c,R);O.push(k[e[0]],k[e[1]])}if(M=[...M,{placement:l,overflows:O}],!O.every(e=>e<=0)){let e=((null==(o=u.flip)?void 0:o.index)||0)+1,n=T[e];if(n&&("alignment"!==g||C===(0,t.getSideAxis)(n)||M.every(e=>(0,t.getSideAxis)(e.placement)!==C||e.overflows[0]>0)))return{data:{index:e,overflows:M},reset:{placement:n}};let r=null==(s=M.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:s.placement;if(!r)switch(v){case"bestFit":{let e=null==(a=M.filter(e=>{if(I){let n=(0,t.getSideAxis)(e.placement);return n===C||"y"===n}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:a[0];e&&(r=e);break}case"initialPlacement":r=d}if(l!==r)return{reset:{placement:r}}}return{}}}},O=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(n){let r,i,{placement:o,rects:s,platform:a,elements:l}=n,{apply:u=()=>{},...c}=(0,t.evaluate)(e,n),d=await a.detectOverflow(n,c),f=(0,t.getSide)(o),p=(0,t.getAlignment)(o),m="y"===(0,t.getSideAxis)(o),{width:g,height:h}=s.floating;"top"===f||"bottom"===f?(r=f,i=p===(await (null==a.isRTL?void 0:a.isRTL(l.floating))?"start":"end")?"left":"right"):(i=f,r="end"===p?"top":"bottom");let v=h-d.top-d.bottom,b=g-d.left-d.right,x=(0,t.min)(h-d[r],v),y=(0,t.min)(g-d[i],b),S=n.middlewareData.shift,C=!S,E=x,R=y;null!=S&&S.enabled.x&&(R=b),null!=S&&S.enabled.y&&(E=v),C&&!p&&(m?R=g-2*(0,t.max)(d.left,d.right):E=h-2*(0,t.max)(d.top,d.bottom)),await u({...n,availableWidth:R,availableHeight:E});let w=await a.getDimensions(l.floating);return g!==w.width||h!==w.height?{reset:{rects:!0}}:{}}}},M=function(e){return void 0===e&&(e={}),{options:e,fn(n){var r,i,o,s;let{x:a,y:u,placement:c,rects:d,middlewareData:f}=n,{offset:p=0,mainAxis:m=!0,crossAxis:g=!0}=(0,t.evaluate)(e,n),h={x:a,y:u},v=(0,t.getSideAxis)(c),b=(0,t.getOppositeAxis)(v),x=h[b],y=h[v],S=(0,t.evaluate)(p,n),C="number"==typeof S?{mainAxis:S,crossAxis:0}:{mainAxis:null!=(r=S.mainAxis)?r:0,crossAxis:null!=(i=S.crossAxis)?i:0};if(m){let e="y"===b?"height":"width",t=d.reference[b]-d.floating[e]+C.mainAxis,n=d.reference[b]+d.reference[e]-C.mainAxis;x<t?x=t:x>n&&(x=n)}if(g){let e="y"===b?"width":"height",n=l.has((0,t.getSide)(c)),r=d.reference[v]-d.floating[e]+(n&&(null==(o=f.offset)?void 0:o[v])||0)+(n?0:C.crossAxis),i=d.reference[v]+d.reference[e]+(n?0:(null==(s=f.offset)?void 0:s[v])||0)-(n?C.crossAxis:0);y<r?y=r:y>i&&(y=i)}return{[b]:x,[v]:y}}}},A=(e,t,n)=>{let r=new Map,o=null!=n?n:{},s={...R,...o.platform,_c:r};return i(e,t,{...o,platform:s})};e.s(["arrow",0,e=>({name:"arrow",options:e,async fn(n){let{x:r,y:i,placement:o,rects:s,platform:a,elements:l,middlewareData:u}=n,{element:c,padding:d=0}=(0,t.evaluate)(e,n)||{};if(null==c)return{};let f=(0,t.getPaddingObject)(d),p={x:r,y:i},m=(0,t.getAlignmentAxis)(o),g=(0,t.getAxisLength)(m),h=await a.getDimensions(c),v="y"===m,b=v?"clientHeight":"clientWidth",x=s.reference[g]+s.reference[m]-p[m]-s.floating[g],y=p[m]-s.reference[m],S=await (null==a.getOffsetParent?void 0:a.getOffsetParent(c)),C=S?S[b]:0;C&&await (null==a.isElement?void 0:a.isElement(S))||(C=l.floating[b]||s.floating[g]);let E=C/2-h[g]/2-1,R=(0,t.min)(f[v?"top":"left"],E),w=(0,t.min)(f[v?"bottom":"right"],E),I=C-h[g]-w,T=C/2-h[g]/2+(x/2-y/2),k=(0,t.clamp)(R,T,I),O=!u.arrow&&null!=(0,t.getAlignment)(o)&&T!==k&&s.reference[g]/2-(T<R?R:w)-h[g]/2<0,M=O?T<R?T-R:T-I:0;return{[m]:p[m]+M,data:{[m]:k,centerOffset:T-k-M,...O&&{alignmentOffset:M}},reset:O}}}),"autoPlacement",0,function(e){return void 0===e&&(e={}),{name:"autoPlacement",options:e,async fn(n){var r,i,o,s;let{rects:a,middlewareData:l,placement:u,platform:c,elements:d}=n,{crossAxis:f=!1,alignment:p,allowedPlacements:m=t.placements,autoAlignment:g=!0,...h}=(0,t.evaluate)(e,n),v=void 0!==p||m===t.placements?((s=p||null)?[...m.filter(e=>(0,t.getAlignment)(e)===s),...m.filter(e=>(0,t.getAlignment)(e)!==s)]:m.filter(e=>(0,t.getSide)(e)===e)).filter(e=>!s||(0,t.getAlignment)(e)===s||!!g&&(0,t.getOppositeAlignmentPlacement)(e)!==e):m,b=(null==(r=l.autoPlacement)?void 0:r.index)||0,x=v[b];if(null==x)return{};if(u!==x)return{reset:{placement:v[0]}};let y=await c.detectOverflow(n,h),S=(0,t.getAlignmentSides)(x,a,await (null==c.isRTL?void 0:c.isRTL(d.floating))),C=[y[(0,t.getSide)(x)],y[S[0]],y[S[1]]],E=[...(null==(i=l.autoPlacement)?void 0:i.overflows)||[],{placement:x,overflows:C}],R=v[b+1];if(R)return{data:{index:b+1,overflows:E},reset:{placement:R}};let w=E.map(e=>{let n=(0,t.getAlignment)(e.placement);return[e.placement,n&&f?e.overflows.slice(0,2).reduce((e,t)=>e+t,0):e.overflows[0],e.overflows]}).sort((e,t)=>e[1]-t[1]),I=(null==(o=w.filter(e=>e[2].slice(0,(0,t.getAlignment)(e[0])?2:3).every(e=>e<=0))[0])?void 0:o[0])||w[0][0];return I!==u?{data:{index:b+1,overflows:E},reset:{placement:I}}:{}}}},"autoUpdate",0,function(e,n,r,i){let o;void 0===i&&(i={});let{ancestorScroll:s=!0,ancestorResize:a=!0,elementResize:l="function"==typeof ResizeObserver,layoutShift:u="function"==typeof IntersectionObserver,animationFrame:d=!1}=i,p=f(e),m=s||a?[...p?(0,c.getOverflowAncestors)(p):[],...n?(0,c.getOverflowAncestors)(n):[]]:[];m.forEach(e=>{s&&e.addEventListener("scroll",r),a&&e.addEventListener("resize",r)});let g=p&&u?function(e,n,r){let i,o=null,s=(0,c.getDocumentElement)(e);function a(){var e;clearTimeout(i),null==(e=o)||e.disconnect(),o=null}function l(r,u){void 0===r&&(r=!1),void 0===u&&(u=1),a();let c=e.getBoundingClientRect(),{left:d,top:f,width:p,height:m}=c;if(r||n(),!p||!m)return;let g={rootMargin:-(0,t.floor)(f)+"px "+-(0,t.floor)(s.clientWidth-(d+p))+"px "+-(0,t.floor)(s.clientHeight-(f+m))+"px "+-(0,t.floor)(d)+"px",threshold:(0,t.max)(0,(0,t.min)(1,u))||1},h=!0;function v(t){let n=t[0].intersectionRatio;if(!w(c,e.getBoundingClientRect()))return l();if(n!==u){if(!h)return l();n?l(!1,n):i=setTimeout(()=>{l(!1,1e-7)},1e3)}h=!1}try{o=new IntersectionObserver(v,{...g,root:s.ownerDocument})}catch(e){o=new IntersectionObserver(v,g)}o.observe(e)}let u=(0,c.getWindow)(e),d=()=>l(r);return u.addEventListener("resize",d),l(!0),()=>{u.removeEventListener("resize",d),a()}}(p,r,a):null,v=-1,b=null;l&&(b=new ResizeObserver(e=>{let[t]=e;t&&t.target===p&&b&&n&&(b.unobserve(n),cancelAnimationFrame(v),v=requestAnimationFrame(()=>{var e;null==(e=b)||e.observe(n)})),r()}),p&&!d&&b.observe(p),n&&b.observe(n));let x=d?h(e):null;return d&&function t(){let n=h(e);x&&!w(x,n)&&r(),x=n,o=requestAnimationFrame(t)}(),r(),()=>{var e;m.forEach(e=>{s&&e.removeEventListener("scroll",r),a&&e.removeEventListener("resize",r)}),null==g||g(),null==(e=b)||e.disconnect(),b=null,d&&cancelAnimationFrame(o)}},"computePosition",0,A,"flip",0,k,"hide",0,function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(n){let{rects:r,platform:i}=n,{strategy:a="referenceHidden",...l}=(0,t.evaluate)(e,n);switch(a){case"referenceHidden":{let e=o(await i.detectOverflow(n,{...l,elementContext:"reference"}),r.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:s(e)}}}case"escaped":{let e=o(await i.detectOverflow(n,{...l,altBoundary:!0}),r.floating);return{data:{escapedOffsets:e,escaped:s(e)}}}default:return{}}}}},"inline",0,function(e){return void 0===e&&(e={}),{name:"inline",options:e,async fn(n){let{placement:r,elements:i,rects:o,platform:s,strategy:l}=n,{padding:u=2,x:c,y:d}=(0,t.evaluate)(e,n),f=Array.from(await (null==s.getClientRects?void 0:s.getClientRects(i.reference))||[]);if(!f.length)return{};let p=function(e){let n=e.slice().sort((e,t)=>e.y-t.y),r=[],i=null;for(let e=0;e<n.length;e++){let t=n[e];!i||t.y-i.y>i.height/2?r.push([t]):r[r.length-1].push(t),i=t}return r.map(e=>(0,t.rectToClientRect)(a(e)))}(f),m=(0,t.rectToClientRect)(a(f)),g=(0,t.getPaddingObject)(u),h=await s.getElementRects({reference:{getBoundingClientRect:function(){if(2===p.length&&(p[0].left>p[1].right||p[1].left>p[0].right)&&null!=c&&null!=d)return p.find(e=>c>e.left-g.left&&c<e.right+g.right&&d>e.top-g.top&&d<e.bottom+g.bottom)||m;if(p.length>=2){if("y"===(0,t.getSideAxis)(r)){let e=p[0],n=p[p.length-1],i="top"===(0,t.getSide)(r),o=e.top,s=n.bottom,a=i?e.left:n.left,l=i?e.right:n.right;return(0,t.rectToClientRect)({x:a,y:o,width:l-a,height:s-o})}let e="left"===(0,t.getSide)(r),n=(0,t.max)(...p.map(e=>e.right)),i=(0,t.min)(...p.map(e=>e.left)),o=p.filter(t=>e?t.left===i:t.right===n),s=o[0].top,a=o[o.length-1].bottom;return(0,t.rectToClientRect)({x:i,y:s,width:n-i,height:a-s})}return m}},floating:i.floating,strategy:l});return o.reference.x!==h.reference.x||o.reference.y!==h.reference.y||o.reference.width!==h.reference.width||o.reference.height!==h.reference.height?{reset:{rects:h}}:{}}}},"limitShift",0,M,"offset",0,I,"platform",0,R,"shift",0,T,"size",0,O],53760);var P=e.i(71645),N=e.i(74080),j="u">typeof document?P.useLayoutEffect:function(){};function L(e,t){let n,r,i;if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if((n=e.length)!==t.length)return!1;for(r=n;0!=r--;)if(!L(e[r],t[r]))return!1;return!0}if((n=(i=Object.keys(e)).length)!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!({}).hasOwnProperty.call(t,i[r]))return!1;for(r=n;0!=r--;){let n=i[r];if(("_owner"!==n||!e.$$typeof)&&!L(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function D(e){return"u"<typeof window?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function z(e,t){let n=D(e);return Math.round(t*n)/n}function F(e){let t=P.useRef(e);return j(()=>{t.current=e}),t}function H(e){void 0===e&&(e={});let{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:s}={},transform:a=!0,whileElementsMounted:l,open:u}=e,[c,d]=P.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=P.useState(r);L(f,r)||p(r);let[m,g]=P.useState(null),[h,v]=P.useState(null),b=P.useCallback(e=>{e!==C.current&&(C.current=e,g(e))},[]),x=P.useCallback(e=>{e!==E.current&&(E.current=e,v(e))},[]),y=o||m,S=s||h,C=P.useRef(null),E=P.useRef(null),R=P.useRef(c),w=null!=l,I=F(l),T=F(i),k=F(u),O=P.useCallback(()=>{if(!C.current||!E.current)return;let e={placement:t,strategy:n,middleware:f};T.current&&(e.platform=T.current),A(C.current,E.current,e).then(e=>{let t={...e,isPositioned:!1!==k.current};M.current&&!L(R.current,t)&&(R.current=t,N.flushSync(()=>{d(t)}))})},[f,t,n,T,k]);j(()=>{!1===u&&R.current.isPositioned&&(R.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[u]);let M=P.useRef(!1);j(()=>(M.current=!0,()=>{M.current=!1}),[]),j(()=>{if(y&&(C.current=y),S&&(E.current=S),y&&S){if(I.current)return I.current(y,S,O);O()}},[y,S,O,I,w]);let H=P.useMemo(()=>({reference:C,floating:E,setReference:b,setFloating:x}),[b,x]),V=P.useMemo(()=>({reference:y,floating:S}),[y,S]),q=P.useMemo(()=>{let e={position:n,left:0,top:0};if(!V.floating)return e;let t=z(V.floating,c.x),r=z(V.floating,c.y);return a?{...e,transform:"translate("+t+"px, "+r+"px)",...D(V.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}},[n,a,V.floating,c.x,c.y]);return P.useMemo(()=>({...c,update:O,refs:H,elements:V,floatingStyles:q}),[c,O,H,V,q])}e.s(["flip",0,(e,t)=>{let n=k(e);return{name:n.name,fn:n.fn,options:[e,t]}},"limitShift",0,(e,t)=>({fn:M(e).fn,options:[e,t]}),"offset",0,(e,t)=>{let n=I(e);return{name:n.name,fn:n.fn,options:[e,t]}},"shift",0,(e,t)=>{let n=T(e);return{name:n.name,fn:n.fn,options:[e,t]}},"size",0,(e,t)=>{let n=O(e);return{name:n.name,fn:n.fn,options:[e,t]}},"useFloating",0,H],58950);var V=e.i(46376),q=e.i(46420);e.s(["useBaseUIFloating",0,function(e){return function(e,t){let{nodeId:n,externalTree:r}=e,i=t.useState("referenceElement"),o=t.useState("floatingElement"),s=t.useState("domReferenceElement"),a=t.useState("open"),l=t.useState("floatingId"),[u,d]=P.useState(null),[f,p]=P.useState(void 0),[m,g]=P.useState(void 0),h=P.useRef(null),v=(0,q.useFloatingTree)(r),b=P.useMemo(()=>({reference:i,floating:o,domReference:s}),[i,o,s]),x=H({...e,elements:{...b,...u&&{reference:u}}}),y=(0,c.isElement)(f)?f:null,S=void 0===m?t.state.floatingElement:m;t.useSyncedValue("referenceElement",f??null),t.useSyncedValue("domReferenceElement",void 0===f?s:y),t.useSyncedValue("floatingElement",S);let C=P.useCallback(e=>{let t=(0,c.isElement)(e)?{getBoundingClientRect:()=>e.getBoundingClientRect(),getClientRects:()=>e.getClientRects(),contextElement:e}:e;d(t),x.refs.setReference(t)},[x.refs]),E=P.useCallback(e=>{((0,c.isElement)(e)||null===e)&&(h.current=e,p(e)),((0,c.isElement)(x.refs.reference.current)||null===x.refs.reference.current||null!==e&&!(0,c.isElement)(e))&&x.refs.setReference(e)},[x.refs,p]),R=P.useCallback(e=>{g(e),x.refs.setFloating(e)},[x.refs]),w=P.useMemo(()=>({...x.refs,setReference:E,setFloating:R,setPositionReference:C,domReference:h}),[x.refs,E,R,C]),I=P.useMemo(()=>({...x.elements,domReference:s}),[x.elements,s]),T=P.useMemo(()=>({...x,dataRef:t.context.dataRef,open:a,onOpenChange:t.setOpen,events:t.context.events,floatingId:l,refs:w,elements:I,nodeId:n,rootStore:t}),[x,w,I,n,t,a,l]);return(0,V.useIsoLayoutEffect)(()=>{s&&(h.current=s)},[s]),(0,V.useIsoLayoutEffect)(()=>{t.context.dataRef.current.floatingContext=T;let e=v?.nodesRef.current.find(e=>e.id===n);e&&(e.context=T)}),P.useMemo(()=>({...x,context:T,refs:w,elements:I,rootStore:t}),[x,w,I,T,t])}(e,e.rootContext)}],88643)},43084,e=>{"use strict";let t=["top","right","bottom","left"],n=t.reduce((e,t)=>e.concat(t,t+"-start",t+"-end"),[]),r=Math.min,i=Math.max,o=Math.round,s=Math.floor,a={left:"right",right:"left",bottom:"top",top:"bottom"};function l(e){return e.split("-")[0]}function u(e){return e.split("-")[1]}function c(e){return"x"===e?"y":"x"}function d(e){return"y"===e?"height":"width"}function f(e){let t=e[0];return"t"===t||"b"===t?"y":"x"}function p(e){return c(f(e))}function m(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}let g=["left","right"],h=["right","left"],v=["top","bottom"],b=["bottom","top"];function x(e){let t=l(e);return a[t]+e.slice(t.length)}e.s(["clamp",0,function(e,t,n){return i(e,r(t,n))},"createCoords",0,e=>({x:e,y:e}),"evaluate",0,function(e,t){return"function"==typeof e?e(t):e},"floor",0,s,"getAlignment",0,u,"getAlignmentAxis",0,p,"getAlignmentSides",0,function(e,t,n){void 0===n&&(n=!1);let r=u(e),i=p(e),o=d(i),s="x"===i?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[o]>t.floating[o]&&(s=x(s)),[s,x(s)]},"getAxisLength",0,d,"getExpandedPlacements",0,function(e){let t=x(e);return[m(e),t,m(t)]},"getOppositeAlignmentPlacement",0,m,"getOppositeAxis",0,c,"getOppositeAxisPlacements",0,function(e,t,n,r){let i=u(e),o=function(e,t,n){switch(e){case"top":case"bottom":if(n)return t?h:g;return t?g:h;case"left":case"right":return t?v:b;default:return[]}}(l(e),"start"===n,r);return i&&(o=o.map(e=>e+"-"+i),t&&(o=o.concat(o.map(m)))),o},"getOppositePlacement",0,x,"getPaddingObject",0,function(e){var t,n,r,i;return"number"!=typeof e?{top:null!=(t=e.top)?t:0,right:null!=(n=e.right)?n:0,bottom:null!=(r=e.bottom)?r:0,left:null!=(i=e.left)?i:0}:{top:e,right:e,bottom:e,left:e}},"getSide",0,l,"getSideAxis",0,f,"max",0,i,"min",0,r,"placements",0,n,"rectToClientRect",0,function(e){let{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}},"round",0,o,"sides",0,t])},87255,76561,47211,50092,32297,74544,52886,26391,19647,16984,10001,e=>{"use strict";var t=e.i(56420);let n={name:"anchor",size:24,node:[["path",{d:"M12 6v16",key:"nqf5sj"}],["path",{d:"m19 13 2-1a9 9 0 0 1-18 0l2 1",key:"y7qv08"}],["path",{d:"M9 11h6",key:"1fldmi"}],["circle",{cx:"12",cy:"4",r:"2",key:"muu5ef"}]]};n.node;let r=(0,t.default)(n);e.s(["Anchor",0,r],87255);let i={name:"archive",size:24,node:[["rect",{width:"20",height:"5",x:"2",y:"3",rx:"1",key:"1wp1u1"}],["path",{d:"M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8",key:"1s80jp"}],["path",{d:"M10 12h4",key:"a56b0p"}]]};i.node;let o=(0,t.default)(i);e.s(["Archive",0,o],76561);let s={name:"ban",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M4.929 4.929 19.07 19.071",key:"196cmz"}]]};s.node;let a=(0,t.default)(s);e.s(["Ban",0,a],47211);let l={name:"circle-arrow-right",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m12 16 4-4-4-4",key:"1i9zcv"}],["path",{d:"M8 12h8",key:"1wcyev"}]],aliases:["arrow-right-circle"]};l.node;let u=(0,t.default)(l);e.s(["CircleArrowRight",0,u],50092);let c={name:"circle-play",size:24,node:[["path",{d:"M9 9.003a1 1 0 0 1 1.517-.859l4.997 2.997a1 1 0 0 1 0 1.718l-4.997 2.997A1 1 0 0 1 9 14.996z",key:"kmsa83"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],aliases:["play-circle"]};c.node;let d=(0,t.default)(c);e.s(["CirclePlay",0,d],32297);let f={name:"clock",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 6v6l4 2",key:"mmk7yg"}]]};f.node;let p=(0,t.default)(f);e.s(["Clock",0,p],74544);let m={name:"circle-dashed",size:24,node:[["path",{d:"M10.1 2.182a10 10 0 0 1 3.8 0",key:"5ilxe3"}],["path",{d:"M13.9 21.818a10 10 0 0 1-3.8 0",key:"11zvb9"}],["path",{d:"M17.609 3.721a10 10 0 0 1 2.69 2.7",key:"1iw5b2"}],["path",{d:"M2.182 13.9a10 10 0 0 1 0-3.8",key:"c0bmvh"}],["path",{d:"M20.279 17.609a10 10 0 0 1-2.7 2.69",key:"1ruxm7"}],["path",{d:"M21.818 10.1a10 10 0 0 1 0 3.8",key:"qkgqxc"}],["path",{d:"M3.721 6.391a10 10 0 0 1 2.7-2.69",key:"1mcia2"}],["path",{d:"M6.391 20.279a10 10 0 0 1-2.69-2.7",key:"1fvljs"}]]};m.node;let g=(0,t.default)(m);e.s(["CircleDashed",0,g],52886);let h={name:"circle-dot-dashed",size:24,node:[["path",{d:"M10.1 2.18a9.93 9.93 0 0 1 3.8 0",key:"1qdqn0"}],["path",{d:"M17.6 3.71a9.95 9.95 0 0 1 2.69 2.7",key:"1bq7p6"}],["path",{d:"M21.82 10.1a9.93 9.93 0 0 1 0 3.8",key:"1rlaqf"}],["path",{d:"M20.29 17.6a9.95 9.95 0 0 1-2.7 2.69",key:"1xk03u"}],["path",{d:"M13.9 21.82a9.94 9.94 0 0 1-3.8 0",key:"l7re25"}],["path",{d:"M6.4 20.29a9.95 9.95 0 0 1-2.69-2.7",key:"1v18p6"}],["path",{d:"M2.18 13.9a9.93 9.93 0 0 1 0-3.8",key:"xdo6bj"}],["path",{d:"M3.71 6.4a9.95 9.95 0 0 1 2.7-2.69",key:"1jjmaz"}],["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}]]};h.node;let v=(0,t.default)(h);e.s(["CircleDotDashed",0,v],26391);let b={name:"circle-minus",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}]],aliases:["minus-circle"]};b.node;let x=(0,t.default)(b);e.s(["CircleMinus",0,x],19647);let y={name:"circle-x",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]],aliases:["x-circle"]};y.node;let S=(0,t.default)(y);e.s(["CircleX",0,S],16984);let C={name:"flag-off",size:24,node:[["path",{d:"M16 16c-3 0-5-2-8-2a6 6 0 0 0-4 1.528",key:"1q158e"}],["path",{d:"m2 2 20 20",key:"1ooewy"}],["path",{d:"M4 22V4",key:"1plyxx"}],["path",{d:"M7.656 2H8c3 0 5 2 7.333 2q2 0 3.067-.8A1 1 0 0 1 20 4v10.347",key:"xj1b71"}]]};C.node;let E=(0,t.default)(C);e.s(["FlagOff",0,E],10001)},89664,e=>{"use strict";var t=e.i(56420);let n={name:"check",size:24,node:[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]};n.node;let r=(0,t.default)(n);e.s(["Check",0,r],89664)},24071,e=>{"use strict";var t=e.i(56420);let n={name:"chevron-left",size:24,node:[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]};n.node;let r=(0,t.default)(n);e.s(["ChevronLeft",0,r],24071)},67927,e=>{"use strict";var t=e.i(56420);let n={name:"chevron-right",size:24,node:[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]};n.node;let r=(0,t.default)(n);e.s(["ChevronRight",0,r],67927)},63707,8619,28276,91772,e=>{"use strict";var t=e.i(56420);let n={name:"chevrons-up-down",size:24,node:[["path",{d:"m7 15 5 5 5-5",key:"1hf1tw"}],["path",{d:"m7 9 5-5 5 5",key:"sgt6xg"}]]};n.node;let r=(0,t.default)(n);e.s(["ChevronsUpDown",0,r],63707);let i={name:"circle-user-round",size:24,node:[["path",{d:"M17.925 20.056a6 6 0 0 0-11.851.001",key:"z69sun"}],["circle",{cx:"12",cy:"11",r:"4",key:"1gt34v"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],aliases:["user-circle-2"]};i.node;let o=(0,t.default)(i);e.s(["CircleUserRound",0,o],8619);let s={name:"compass",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m16.24 7.76-1.804 5.411a2 2 0 0 1-1.265 1.265L7.76 16.24l1.804-5.411a2 2 0 0 1 1.265-1.265z",key:"9ktpf1"}]]};s.node;let a=(0,t.default)(s);e.s(["Compass",0,a],28276);let l={name:"laptop-minimal",size:24,node:[["rect",{width:"18",height:"12",x:"3",y:"4",rx:"2",ry:"2",key:"1qhy41"}],["line",{x1:"2",x2:"22",y1:"20",y2:"20",key:"ni3hll"}]],aliases:["laptop-2"]};l.node;let u=(0,t.default)(l);e.s(["LaptopMinimal",0,u],91772)},77913,e=>{"use strict";var t=e.i(56420);let n={name:"drafting-compass",size:24,node:[["path",{d:"m12.99 6.74 1.93 3.44",key:"iwagvd"}],["path",{d:"M19.136 12a10 10 0 0 1-14.271 0",key:"ppmlo4"}],["path",{d:"m21 21-2.16-3.84",key:"vylbct"}],["path",{d:"m3 21 8.02-14.26",key:"1ssaw4"}],["circle",{cx:"12",cy:"5",r:"2",key:"f1ur92"}]]};n.node;let r=(0,t.default)(n);e.s(["DraftingCompass",0,r],77913)},71028,e=>{"use strict";var t=e.i(56420);let n={name:"gauge",size:24,node:[["path",{d:"m12 14 4-4",key:"9kzdfg"}],["path",{d:"M3.34 19a10 10 0 1 1 17.32 0",key:"19p75a"}]]};n.node;let r=(0,t.default)(n);e.s(["Gauge",0,r],71028)},81658,57665,95925,85627,66787,92870,e=>{"use strict";var t=e.i(56420);let n={name:"hourglass",size:24,node:[["path",{d:"M5 22h14",key:"ehvnwv"}],["path",{d:"M5 2h14",key:"pdyrp9"}],["path",{d:"M17 22v-4.172a2 2 0 0 0-.586-1.414L12 12l-4.414 4.414A2 2 0 0 0 7 17.828V22",key:"1d314k"}],["path",{d:"M7 2v4.172a2 2 0 0 0 .586 1.414L12 12l4.414-4.414A2 2 0 0 0 17 6.172V2",key:"1vvvr6"}]]};n.node;let r=(0,t.default)(n);e.s(["Hourglass",0,r],81658);let i={name:"power",size:24,node:[["path",{d:"M12 2v10",key:"mnfbl"}],["path",{d:"M18.4 6.6a9 9 0 1 1-12.77.04",key:"obofu9"}]]};i.node;let o=(0,t.default)(i);e.s(["Power",0,o],57665);let s={name:"rotate-ccw",size:24,node:[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]]};s.node;let a=(0,t.default)(s);e.s(["RotateCcw",0,a],95925);let l={name:"sailboat",size:24,node:[["path",{d:"M10 2v15",key:"1qf71f"}],["path",{d:"M7 22a4 4 0 0 1-4-4 1 1 0 0 1 1-1h16a1 1 0 0 1 1 1 4 4 0 0 1-4 4z",key:"1pxcvx"}],["path",{d:"M9.159 2.46a1 1 0 0 1 1.521-.193l9.977 8.98A1 1 0 0 1 20 13H4a1 1 0 0 1-.824-1.567z",key:"5oog16"}]]};l.node;let u=(0,t.default)(l);e.s(["Sailboat",0,u],85627);let c={name:"triangle-alert",size:24,node:[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]],aliases:["alert-triangle"]};c.node;let d=(0,t.default)(c);e.s(["TriangleAlert",0,d],66787);let f={name:"user-check",size:24,node:[["path",{d:"m16 11 2 2 4-4",key:"9rsbq5"}],["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]]};f.node;let p=(0,t.default)(f);e.s(["UserCheck",0,p],92870)},44594,e=>{"use strict";var t=e.i(56420);let n={name:"inbox",size:24,node:[["polyline",{points:"22 12 16 12 14 15 10 15 8 12 2 12",key:"o97t9d"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}]]};n.node;let r=(0,t.default)(n);e.s(["Inbox",0,r],44594)},18964,e=>{"use strict";var t=e.i(56420);let n={name:"list-checks",size:24,node:[["path",{d:"M13 5h8",key:"a7qcls"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 19h8",key:"c3s6r1"}],["path",{d:"m3 17 2 2 4-4",key:"1jhpwq"}],["path",{d:"m3 7 2 2 4-4",key:"1obspn"}]]};n.node;let r=(0,t.default)(n);e.s(["ListChecks",0,r],18964)},67784,e=>{"use strict";var t=e.i(56420);let n={name:"log-out",size:24,node:[["path",{d:"m16 17 5-5-5-5",key:"1bji2h"}],["path",{d:"M21 12H9",key:"dn1m92"}],["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}]]};n.node;let r=(0,t.default)(n);e.s(["LogOut",0,r],67784)},46513,96699,35965,18162,e=>{"use strict";var t=e.i(56420);let n={name:"monitor",size:24,node:[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21",key:"1svkeh"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21",key:"vw1qmm"}]]};n.node;let r=(0,t.default)(n);e.s(["Monitor",0,r],46513);let i={name:"moon",size:24,node:[["path",{d:"M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401",key:"kfwtm"}]]};i.node;let o=(0,t.default)(i);e.s(["Moon",0,o],96699);let s={name:"sun",size:24,node:[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]]};s.node;let a=(0,t.default)(s);e.s(["Sun",0,a],35965),e.i(31627),e.i(68404);var l=e.i(49635);e.s(["THEME_LABELS",0,{light:"Light",dark:"Dark",system:"System"},"applyTheme",0,function(e){let t=document.documentElement;t.dataset.theme=e;let n="dark"===e||"system"===e&&window.matchMedia("(prefers-color-scheme: dark)").matches;t.classList.toggle("dark",n)},"sessionSince",0,function(e,t){let n=new Date(e.since),r=n.toDateString()===t.toDateString()?(0,l.clockTime)(n):(0,l.shortDateTime)(n);return`Device \xb7 ${e.device}, since ${r}`}],18162)},77071,e=>{"use strict";var t=e.i(56420);let n={name:"plus",size:24,node:[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]};n.node;let r=(0,t.default)(n);e.s(["Plus",0,r],77071)},66794,e=>{"use strict";var t=e.i(56420);let n={name:"settings",size:24,node:[["path",{d:"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",key:"1i5ecw"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]};n.node;let r=(0,t.default)(n);e.s(["Settings",0,r],66794)},60011,e=>{"use strict";var t=e.i(56420);let n={name:"shapes",size:24,node:[["path",{d:"M8.3 10a.7.7 0 0 1-.626-1.079L11.4 3a.7.7 0 0 1 1.198-.043L16.3 8.9a.7.7 0 0 1-.572 1.1Z",key:"1bo67w"}],["rect",{x:"3",y:"14",width:"7",height:"7",rx:"1",key:"1bkyp8"}],["circle",{cx:"17.5",cy:"17.5",r:"3.5",key:"w3z12y"}]]};n.node;let r=(0,t.default)(n);e.s(["Shapes",0,r],60011)},86875,e=>{"use strict";var t=e.i(56420);let n={name:"ship-wheel",size:24,node:[["circle",{cx:"12",cy:"12",r:"8",key:"46899m"}],["path",{d:"M12 2v7.5",key:"1e5rl5"}],["path",{d:"m19 5-5.23 5.23",key:"1ezxxf"}],["path",{d:"M22 12h-7.5",key:"le1719"}],["path",{d:"m19 19-5.23-5.23",key:"p3fmgn"}],["path",{d:"M12 14.5V22",key:"dgcmos"}],["path",{d:"M10.23 13.77 5 19",key:"qwopd4"}],["path",{d:"M9.5 12H2",key:"r7bup8"}],["path",{d:"M10.23 10.23 5 5",key:"k2y7lj"}],["circle",{cx:"12",cy:"12",r:"2.5",key:"ix0uyj"}]]};n.node;let r=(0,t.default)(n);e.s(["ShipWheel",0,r],86875)},80799,e=>{"use strict";var t=e.i(56420);let n={name:"tag",size:24,node:[["path",{d:"M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z",key:"vktsd0"}],["circle",{cx:"7.5",cy:"7.5",r:".5",fill:"currentColor",key:"kqv944"}]]};n.node;let r=(0,t.default)(n);e.s(["Tag",0,r],80799)},55838,(e,t,n)=>{"use strict";var r=e.r(71645),i="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},o=r.useState,s=r.useEffect,a=r.useLayoutEffect,l=r.useDebugValue;function u(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!i(e,n)}catch(e){return!0}}var c="u"<typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var n=t(),r=o({inst:{value:n,getSnapshot:t}}),i=r[0].inst,c=r[1];return a(function(){i.value=n,i.getSnapshot=t,u(i)&&c({inst:i})},[e,n,t]),s(function(){return u(i)&&c({inst:i}),e(function(){u(i)&&c({inst:i})})},[e]),l(n),n};n.useSyncExternalStore=void 0!==r.useSyncExternalStore?r.useSyncExternalStore:c},2239,(e,t,n)=>{"use strict";e.i(47167),t.exports=e.r(55838)},52822,(e,t,n)=>{"use strict";var r=e.r(71645),i=e.r(2239),o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},s=i.useSyncExternalStore,a=r.useRef,l=r.useEffect,u=r.useMemo,c=r.useDebugValue;n.useSyncExternalStoreWithSelector=function(e,t,n,r,i){var d=a(null);if(null===d.current){var f={hasValue:!1,value:null};d.current=f}else f=d.current;var p=s(e,(d=u(function(){function e(e){if(!l){if(l=!0,s=e,e=r(e),void 0!==i&&f.hasValue){var t=f.value;if(i(t,e))return a=t}return a=e}if(t=a,o(s,e))return t;var n=r(e);return void 0!==i&&i(t,n)?(s=e,t):(s=e,a=n)}var s,a,l=!1,u=void 0===n?null:n;return[function(){return e(t())},null===u?void 0:function(){return e(u())}]},[t,n,r,i]))[0],d[1]);return l(function(){f.hasValue=!0,f.value=p},[p]),c(p),p}},30224,(e,t,n)=>{"use strict";e.i(47167),t.exports=e.r(52822)},66390,e=>{"use strict";var t=e.i(76782),n=e.i(52245),r=e.i(25913),i=e.i(90063);let o=(0,r.cva)("inline-flex w-fit shrink-0 items-center justify-center gap-1.5 border font-medium whitespace-nowrap [&>svg]:pointer-events-none [&>svg]:size-(--size-icon-sm)",{variants:{variant:{secondary:"h-5.5 rounded-sm border-transparent bg-secondary px-1.5 text-caption text-secondary-foreground",outline:"h-5.5 rounded-sm border-border bg-transparent px-1.5 text-caption text-foreground",type:"h-5.5 rounded-sm border-transparent bg-secondary px-1.5 font-mono text-id text-foreground",kind:"h-5.5 rounded-sm border-transparent bg-highlight px-1.5 font-mono text-id text-primary",count:"h-5 min-w-5 rounded-full border-transparent bg-primary px-1.5 text-micro font-semibold text-primary-foreground tabular-nums","count-neutral":"h-5 min-w-5 rounded-full border-transparent bg-secondary px-1.5 text-micro font-semibold text-foreground tabular-nums","count-attention":"h-5 min-w-5 rounded-full border-tone-attention-border bg-tone-attention-bg px-1.5 text-micro font-semibold text-tone-attention-fg tabular-nums"}},defaultVariants:{variant:"secondary"}});e.s(["Badge",0,function({className:e,variant:r,render:s,...a}){var l;return l={defaultTagName:"span",props:(0,t.mergeProps)({className:(0,i.classNames)(o({variant:r}),e)},a),render:s,state:{slot:"badge",variant:r}},(0,n.useRenderElement)(l.defaultTagName??"div",l,l)}],66390)},33173,e=>{"use strict";var t=e.i(43476),n=e.i(25933),r=e.i(89664),i=e.i(71645),o=e.i(90063),s=e.i(12470);e.s(["Combobox",0,function({options:e,value:a,onValueChange:l,isFreeText:u=!1,toQuery:c,groupLabel:d,emptyText:f,leadingIcon:p,placeholder:m,id:g,isInvalid:h=!1,"aria-describedby":v,"aria-label":b,"data-testid":x}){let y=e.find(e=>e.value===a),[S,C]=(0,i.useState)(y?.label??(u?a??"":"")),[E,R]=(0,i.useState)(!1),w=e.filter(e=>e.label.toLowerCase().includes(S.trim().toLowerCase())),I=y?.label===S?y:void 0,T=void 0!==I&&(void 0!==I.detail||void 0!==I.trailing),k=u?e.find(e=>e.label===S):y;return(0,t.jsxs)(n.Combobox.Root,{items:w,filter:null,value:k??null,itemToStringLabel:e=>e.label,isItemEqualToValue:(e,t)=>e.value===t.value,inputValue:S,open:E&&""!==S.trim(),onOpenChange:R,onInputValueChange:(e,t)=>{if(u&&"input-change"!==t.reason&&"item-press"!==t.reason)return;let n="input-change"===t.reason&&c?c(e):e;C(n),u?l(""===n?null:n):void 0!==y&&n!==y.label&&l(null)},onValueChange:e=>{e&&(C(e.label),l(u?e.label:e.value))},children:[(0,t.jsxs)("div",{className:"relative w-full [&_svg]:size-(--size-icon)",children:[p?(0,t.jsx)("span",{"aria-hidden":!0,className:"pointer-events-none absolute inset-y-0 left-3 flex items-center text-muted-foreground",children:p}):null,(0,t.jsx)(n.Combobox.Input,{id:g,placeholder:m,"aria-invalid":h,"aria-describedby":v,"aria-label":b,"data-testid":x,"data-slot":"combobox-input",className:(0,o.classNames)((0,s.inputVariants)({isMono:!0}),p?"pl-9":void 0,T?"pr-44 max-sm:pr-28":void 0)}),T?(0,t.jsxs)("span",{className:"pointer-events-none absolute inset-y-0 right-2.5 flex items-center gap-2",children:[I.detail?(0,t.jsx)("span",{className:"truncate text-meta text-muted-foreground max-sm:hidden",children:I.detail}):null,I.trailing]}):null]}),(0,t.jsx)(n.Combobox.Portal,{children:(0,t.jsx)(n.Combobox.Positioner,{className:"isolate z-50 outline-none",sideOffset:4,children:(0,t.jsxs)(n.Combobox.Popup,{"data-slot":"combobox-content",className:"max-h-(--available-height) w-(--anchor-width) origin-(--transform-origin) overflow-y-auto rounded-lg border border-border bg-popover p-1 text-popover-foreground shadow-lg duration-(--duration-fast) outline-none data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",children:[f?(0,t.jsx)(n.Combobox.Empty,{className:"px-2.5 py-2 text-meta text-muted-foreground empty:hidden",children:f(S.trim())}):null,(0,t.jsxs)(n.Combobox.List,{children:[d&&w.length>0?(0,t.jsx)("div",{className:"px-2.5 pt-1.5 pb-1 text-caption text-muted-foreground",children:d}):null,w.map(e=>(0,t.jsxs)(n.Combobox.Item,{value:e,"data-slot":"combobox-item",className:"relative flex min-h-8.5 items-center gap-2.5 rounded-sm pr-8 pl-2.5 text-body text-foreground outline-none select-none data-disabled:pointer-events-none data-disabled:opacity-45 data-highlighted:bg-accent",children:[(0,t.jsx)("span",{className:"font-mono text-id font-medium",children:e.label}),e.detail?(0,t.jsx)("span",{className:"truncate text-meta text-muted-foreground",children:e.detail}):null,e.trailing?(0,t.jsx)("span",{className:"ml-auto flex items-center",children:e.trailing}):null,(0,t.jsx)(n.Combobox.ItemIndicator,{className:"absolute right-2.5 flex items-center",children:(0,t.jsx)(r.Check,{"aria-hidden":!0,className:"size-(--size-icon)"})})]},e.value))]})]})})})]})}])},22212,13488,64170,25326,53753,94945,43988,e=>{"use strict";var t=e.i(43476);e.i(14651);var n=e.i(2820),r=e.i(56736),i=e.i(9793),o=e.i(84324),s=e.i(64951),a=e.i(50440),l=e.i(74217),u=e.i(77173),c=e.i(33332),d=e.i(71645),f=e.i(96499),p=e.i(8821),m=e.i(40886),g=e.i(52245),h=e.i(79938),v=e.i(38396),b=e.i(59636),x=e.i(64111),y=e.i(88015),S=e.i(85689),C=e.i(32199);let E=(0,f.fastComponentRef)(function(e,t){let{render:n,className:r,style:i,disabled:o=!1,nativeButton:s=!0,id:a,payload:l,handle:u,...f}=e,E=(0,p.useDialogRootContext)(!0),R=(0,b.usePopupHandleStore)(u)??E;if(!R)throw Error((0,c.default)(79));let w=(0,y.useBaseUiId)(a),I=R.useState("floatingRootContext"),T=R.useState("isOpenedByTrigger",w),k=R.useState("triggerPopupId",w),O=d.useRef(null),{registerTrigger:M,isMountedByThisTrigger:A}=(0,x.useTriggerDataForwarding)(w,O,R,{payload:l}),{getButtonProps:P,buttonRef:N}=(0,m.useButton)({disabled:o,native:s}),j=(0,S.useClick)(I),L=(0,C.useOpenMethodTriggerProps)(()=>R.select("open"),e=>{R.set("openMethod",e)}),D=R.useState("triggerProps",A);return(0,g.useRenderElement)("button",e,{state:{disabled:o,open:T},ref:[N,t,M,O],props:[j.reference,D,L,{[v.CLICK_TRIGGER_IDENTIFIER]:"",id:w,"aria-haspopup":"dialog","aria-expanded":T,"aria-controls":k},f,P],stateAttributesMapping:h.triggerOpenStateMapping})});e.s(["DialogTrigger",0,E],13488);var R=e.i(1807),w=e.i(75606),I=e.i(56434);class T{attachedStores=[];attachedStoreValue=null;storeListeners=new Set;constructor(e,t,n=!0){this.fallbackStore=e,this.componentName=t,this.throwOnMissingTrigger=n}get attachedStore(){return this.attachedStoreValue}get store(){return this.attachedStoreValue??this.fallbackStore}get serverStore(){return this.fallbackStore}subscribeStore(e){return this.storeListeners.add(e),()=>{this.storeListeners.delete(e)}}attachStore(e){return this.attachedStores.push(e),this.setActiveStore(e),()=>{let t=this.attachedStores.lastIndexOf(e);-1!==t&&this.attachedStores.splice(t,1),this.setActiveStore(this.attachedStores[this.attachedStores.length-1]??null)}}setActiveStore(e){this.attachedStoreValue!==e&&(this.attachedStoreValue=e,this.storeListeners.forEach(e=>{e()}))}openByTrigger(e){let t,n=this.attachedStore;if(null!==n){if(e){for(let n=this.attachedStores.length-1;n>=0&&!t;n-=1)t=this.attachedStores[n].context.triggerElements.getById(e);t??=this.fallbackStore.context.triggerElements.getById(e)}if(e&&!t&&this.throwOnMissingTrigger)throw Error((0,c.default)(99,this.componentName,e,this.componentName));n.setOpen(!0,(0,w.createChangeEventDetails)(I.REASONS.imperativeAction,void 0,t))}}closePopup(){let e=this.attachedStore;null===e||e.setOpen(!1,(0,w.createChangeEventDetails)(I.REASONS.imperativeAction))}}e.s(["BasePopupHandle",0,T],64170);class k extends T{constructor(){super((0,R.createNullDialogStore)(),"Dialog",!1)}open(e){this.openByTrigger(e)}openWithPayload(e){let t=this.attachedStore;null===t||(t.set("payload",e),t.setOpen(!0,(0,w.createChangeEventDetails)(I.REASONS.imperativeAction)))}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}}function O(){return new k}e.s(["DialogHandle",0,k,"createDialogHandle",0,O],25326),e.s(["Backdrop",()=>n.DialogBackdrop,"Close",()=>r.DialogClose,"Description",()=>i.DialogDescription,"Handle",0,k,"Popup",()=>o.DialogPopup,"Portal",()=>s.DialogPortal,"Root",()=>a.DialogRoot,"Title",()=>u.DialogTitle,"Trigger",0,E,"Viewport",()=>l.DialogViewport,"createHandle",0,O],28376);var M=e.i(28376);e.s(["Dialog",0,M],53753);var M=M,A=e.i(90063),P=e.i(25913);let N={overlay:"fixed inset-0 isolate z-50 bg-overlay duration-(--duration-base) data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",popup:(0,P.cva)("fixed top-1/2 left-1/2 z-50 grid max-h-[calc(100dvh-var(--spacing)*8)] w-full max-w-[calc(100%-var(--spacing)*8)] -translate-x-1/2 -translate-y-1/2 gap-4 overflow-y-auto rounded-xl border border-border bg-popover p-6 text-body text-popover-foreground shadow-lg duration-(--duration-base) outline-none data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95 motion-reduce:data-open:zoom-in-100 motion-reduce:data-closed:zoom-out-100",{variants:{size:{sm:"sm:max-w-(--size-dialog-sm)",md:"sm:max-w-(--size-dialog-md)"}},defaultVariants:{size:"sm"}}),header:"flex flex-col gap-2",footer:"flex flex-col-reverse gap-2 pt-1 sm:flex-row sm:justify-end",title:"text-heading font-semibold text-foreground",description:"text-body text-muted-foreground",phoneSheet:"max-sm:top-auto max-sm:bottom-0 max-sm:left-0 max-sm:max-w-full max-sm:translate-x-0 max-sm:translate-y-0 max-sm:rounded-none max-sm:rounded-t-2xl max-sm:border-x-0 max-sm:border-b-0 max-sm:px-4 max-sm:pb-[max(calc(var(--spacing)*4),env(safe-area-inset-bottom))] max-sm:[&_[data-slot=button]]:h-(--size-control-touch) max-sm:[&_[data-slot=button]]:w-full",phoneFullScreen:"max-sm:top-0 max-sm:left-0 max-sm:h-dvh max-sm:max-w-full max-sm:translate-x-0 max-sm:translate-y-0 max-sm:content-start max-sm:overflow-y-auto max-sm:rounded-none max-sm:border-0"};e.s(["dialogSurface",0,N],94945),e.s(["Dialog",0,function(e){return(0,t.jsx)(M.Root,{"data-slot":"dialog",...e})},"DialogClose",0,function(e){return(0,t.jsx)(M.Close,{"data-slot":"dialog-close",...e})},"DialogContent",0,function({className:e,size:n,children:r,...i}){return(0,t.jsxs)(M.Portal,{children:[(0,t.jsx)(M.Backdrop,{"data-slot":"dialog-overlay",className:N.overlay}),(0,t.jsx)(M.Popup,{"data-slot":"dialog-content",className:(0,A.classNames)(N.popup({size:n}),e),...i,children:r})]})},"DialogDescription",0,function({className:e,...n}){return(0,t.jsx)(M.Description,{"data-slot":"dialog-description",className:(0,A.classNames)(N.description,e),...n})},"DialogFooter",0,function({className:e,...n}){return(0,t.jsx)("div",{"data-slot":"dialog-footer",className:(0,A.classNames)(N.footer,e),...n})},"DialogHeader",0,function({className:e,...n}){return(0,t.jsx)("div",{"data-slot":"dialog-header",className:(0,A.classNames)(N.header,e),...n})},"DialogTitle",0,function({className:e,...n}){return(0,t.jsx)(M.Title,{"data-slot":"dialog-title",className:(0,A.classNames)(N.title,e),...n})}],22212);let j=(0,P.cva)("w-full min-w-0 resize-none rounded-md border border-input bg-card px-3 py-2 text-foreground shadow-sm transition-[border-color,box-shadow] duration-(--duration-fast) outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/22 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/16 disabled:cursor-not-allowed disabled:bg-muted disabled:opacity-50 disabled:shadow-none",{variants:{size:{md:"text-body",touch:"rounded-lg text-input-touch"},isMono:{true:"font-mono",false:""}},compoundVariants:[{size:"md",isMono:!0,className:"text-code"}],defaultVariants:{size:"md",isMono:!1}});e.s(["Textarea",0,function({className:e,size:n,isMono:r,rows:i=4,...o}){return(0,t.jsx)("textarea",{"data-slot":"textarea",rows:i,className:(0,A.classNames)(j({size:n,isMono:r}),e),...o})}],43988)},57334,e=>{"use strict";var t=e.i(43476);e.i(61027);var n=e.i(82370),r=e.i(89554),i=e.i(85996),o=e.i(71714),s=e.i(81194),a=e.i(1545),l=e.i(91384),u=e.i(58307),c=e.i(64270),d=e.i(19712),f=e.i(82264),p=e.i(62050),m=e.i(82593),g=e.i(5953),h=e.i(63947),v=e.i(77450),b=e.i(33332),x=e.i(71645),y=e.i(39957),S=e.i(8868),C=e.i(96499),E=e.i(67865),R=e.i(46376),w=e.i(56789),I=e.i(50316),T=e.i(85689),k=e.i(46420),O=e.i(13082),M=e.i(72135),A=e.i(79248),P=e.i(84446),N=e.i(78921),j=e.i(79938),L=e.i(52245),D=e.i(40886),z=e.i(64042),F=e.i(95530);function H(e){let{render:t,className:n,style:r,state:i=w.EMPTY_OBJECT,props:o=w.EMPTY_ARRAY,refs:s=w.EMPTY_ARRAY,metadata:a,stateAttributesMapping:l,tag:u="div",...c}=e,{compositeProps:d,compositeRef:f}=(0,F.useCompositeItem)({metadata:a});return(0,L.useRenderElement)(u,e,{state:i,ref:[f,...s],props:[d,...o,c],stateAttributesMapping:l})}var V=e.i(38452),q=e.i(29315),_=e.i(59636),B=e.i(64111),W=e.i(46570),$=e.i(88015),U=e.i(56434),K=e.i(7447),G=e.i(38396),Y=e.i(52535),Q=e.i(76782);let X=(0,C.fastComponentRef)(function(e,n){let r,{render:i,className:o,style:s,disabled:a=!1,nativeButton:l=!0,id:u,openOnHover:c,delay:d=100,closeDelay:f=0,handle:p,payload:m,...g}=e,h=(0,N.useMenuRootContext)(!0),v=(0,_.usePopupHandleStore)(p)??h?.store;if(!v)throw Error((0,b.default)(85));let C=(0,$.useBaseUiId)(u),F=v.useState("isTriggerActive",C),X=v.useState("floatingRootContext"),J=v.useState("isOpenedByTrigger",C),Z=v.useState("triggerPopupId",C),ee=x.useRef(null),et=(r=(0,K.useMenubarContext)(!0),x.useMemo(()=>r?{type:"menubar",context:r}:{type:void 0},[r])),en=(0,V.useCompositeRootContext)(!0),er=(0,k.useFloatingTree)(),ei=x.useMemo(()=>er??new A.FloatingTreeStore,[er]),eo=(0,k.useFloatingNodeId)(ei),es=(0,k.useFloatingParentNodeId)(),{registerTrigger:ea,isMountedByThisTrigger:el}=(0,B.useTriggerDataForwarding)(C,ee,v,{payload:m,closeDelay:f,parent:et,floatingTreeRoot:ei,floatingNodeId:eo,floatingParentNodeId:es,keyboardEventRelay:en?.relayKeyboardEvent}),eu="menubar"===et.type,ec=v.useState("disabled"),ed=a||ec||eu&&et.context.disabled,{getButtonProps:ef,buttonRef:ep}=(0,D.useButton)({disabled:ed,native:l});x.useEffect(()=>{J||void 0!==et.type||(v.context.allowMouseUpTriggerRef.current=!1)},[v,J,et.type]);let em=x.useRef(null),eg=(0,y.useTimeout)(),eh=(0,E.useStableCallback)(e=>{if(!em.current)return;eg.clear(),v.context.allowMouseUpTriggerRef.current=!1;let t=e.target;(0,P.contains)(em.current,t)||(0,P.contains)(v.select("positionerElement"),t)||t===em.current||null!=t&&function e(t){return(0,q.isHTMLElement)(t)&&t.hasAttribute("data-rootownerid")?t.getAttribute("data-rootownerid"):(0,q.isLastTraversableNode)(t)?void 0:e((0,q.getParentNode)(t))}(t)===v.select("rootId")||(0,z.isMouseWithinBounds)(e,em.current)||ei.events.emit("close",{domEvent:e,reason:U.REASONS.cancelOpen})});x.useEffect(()=>{J&&v.select("lastOpenChangeReason")===U.REASONS.triggerHover&&(0,S.ownerDocument)(em.current).addEventListener("mouseup",eh,{once:!0})},[J,eh,v]);let ev=eu&&et.context.hasSubmenuOpen,eb=c??ev,ex=(0,M.useHoverReferenceInteraction)(X,{enabled:eb&&!ed&&(!eu||ev&&!el),handleClose:(0,I.safePolygon)({blockPointerEvents:!eu}),mouseOnly:!0,move:!1,restMs:void 0===et.type?d:void 0,delay:{close:f},triggerElementRef:ee,externalTree:ei,isActiveTrigger:F,isClosing:()=>"ending"===v.select("transitionStatus")}),ey=function(e,t){let n=(0,y.useTimeout)(),[r,i]=x.useState(!1);return(0,R.useIsoLayoutEffect)(()=>{e&&t===U.REASONS.triggerHover?(i(!0),n.start(G.PATIENT_CLICK_THRESHOLD,()=>{i(!1)})):e||(n.clear(),i(!1))},[e,t,n]),r}(J,v.select("lastOpenChangeReason")),eS=(0,T.useClick)(X,{enabled:!ed,event:J&&eu?"click":"mousedown",toggle:!0,ignoreMouse:!1,stickIfOpen:void 0===et.type&&ey}),eC=(0,O.useFocus)(X,{enabled:!ed&&ev}),eE=function(e){let{enabled:t=!0,mouseDownAction:n,open:r}=e,i=x.useRef(!1);return x.useMemo(()=>t?{onMouseDown:e=>{("open"===n&&!r||"close"===n&&r)&&(i.current=!0,(0,S.ownerDocument)(e.currentTarget).addEventListener("click",()=>{i.current=!1},{once:!0}))},onClick:e=>{i.current&&(i.current=!1,e.preventBaseUIHandler())}}:w.EMPTY_OBJECT,[t,n,r])}({open:J,enabled:eu,mouseDownAction:"open"}),eR=x.useMemo(()=>(0,Q.mergeProps)(eC.reference,eS.reference),[eC.reference,eS.reference]),ew=v.useState("triggerProps",el),{preFocusGuardRef:eI,handlePreFocusGuardFocus:eT,handleFocusTargetFocus:ek}=(0,W.useTriggerFocusGuards)(v,ee),eO={disabled:ed,open:J},eM=[em,n,ep,ea,ee],eA=[eR,ex??w.EMPTY_OBJECT,ew,{"aria-haspopup":"menu","aria-controls":Z,id:C,onMouseDown:e=>{v.select("open")||(eg.start(200,()=>{v.context.allowMouseUpTriggerRef.current=!0}),(0,S.ownerDocument)(e.currentTarget).addEventListener("mouseup",eh,{once:!0}))}},eu?{role:"menuitem"}:{},eE,g,ef],eP=(0,L.useRenderElement)("button",e,{enabled:!eu,stateAttributesMapping:j.pressableTriggerOpenStateMapping,state:eO,ref:eM,props:eA});return eu?(0,t.jsx)(H,{tag:"button",render:i,className:o,style:s,state:eO,refs:eM,props:eA,stateAttributesMapping:j.pressableTriggerOpenStateMapping}):J?(0,t.jsxs)(x.Fragment,{children:[(0,t.jsx)(Y.FocusGuard,{ref:eI,onFocus:eT},`${C}-pre-focus-guard`),(0,t.jsx)(x.Fragment,{children:eP},C),(0,t.jsx)(Y.FocusGuard,{ref:v.context.triggerFocusTargetRef,onFocus:ek},`${C}-post-focus-guard`)]}):(0,t.jsx)(x.Fragment,{children:eP},C)});var J=e.i(3414),Z=e.i(18390);let ee=x.forwardRef(function(e,t){let{render:n,className:r,style:i,children:o,...s}=e,{store:a}=(0,N.useMenuRootContext)(),{side:l}=(0,J.useMenuPositionerContext)(),u=a.useState("instantType"),{children:c,state:d}=(0,Z.usePopupViewport)({store:a,side:l,children:o}),f={activationDirection:d.activationDirection,transitioning:d.transitioning,instant:u};return(0,L.useRenderElement)("div",e,{state:f,ref:t,props:[s,{children:c}],stateAttributesMapping:Z.popupViewportStateMapping})}),et=x.forwardRef(function(e,t){let{className:n,render:r,orientation:i="horizontal",style:o,...s}=e;return(0,L.useRenderElement)("div",e,{state:{orientation:i},ref:t,props:[{role:"separator","aria-orientation":i},s]})});var en=e.i(28744),er=e.i(73553),ei=e.i(66506),eo=e.i(74671);let es={"aria-expanded":void 0},ea=x.forwardRef(function(e,t){let{render:n,className:r,style:i,label:o,id:s,nativeButton:a=!1,openOnHover:l=!0,delay:u=100,closeDelay:c=0,disabled:d=!1,...f}=e,p=(0,eo.useMenuSubmenuRootContext)();if(!p?.parentMenu)throw Error((0,b.default)(37));let m=(0,er.useCompositeListItem)({guess:!0,label:o}),g=(0,J.useMenuPositionerContext)(),{store:h}=(0,N.useMenuRootContext)(),v=(0,$.useBaseUiId)(s),y=h.useState("open"),S=h.useState("floatingRootContext"),C=h.useState("floatingTreeRoot"),k=h.useState("triggerPopupId",v),O=(0,B.useTriggerRegistration)(v,h),A=(0,E.useStableCallback)(e=>{O(e),null!==e&&h.select("open")&&null==h.select("activeTriggerId")&&h.update({activeTriggerId:v??null,activeTriggerElement:e,closeDelay:c})}),P=x.useRef(null),D=x.useCallback(e=>{P.current=e,h.set("activeTriggerElement",e)},[h]);(0,R.useIsoLayoutEffect)(()=>(A(P.current),()=>A(null)),[A,v,h]),h.useSyncedValue("closeDelay",c);let z=p.parentMenu,F=h.useState("disabled"),H=z.useState("disabled"),V=d||F||H,q=z.useState("itemProps"),_=z.useState("isActive",m.index),W=x.useMemo(()=>({type:"submenu-trigger",setActive(){z.select("highlightItemOnHover")&&z.set("activeIndex",m.index)}}),[z,m.index]),{getItemProps:K,itemRef:G}=(0,ei.useMenuItem)({closeOnClick:!1,disabled:V,highlighted:_,id:v,store:h,typingRef:z.context.typingRef,nativeButton:a,itemMetadata:W,nodeId:g?.context.nodeId}),Y=h.useState("hoverEnabled"),Q=(0,M.useHoverReferenceInteraction)(S,{enabled:Y&&l&&!V,handleClose:(0,I.safePolygon)({blockPointerEvents:!0}),mouseOnly:!0,move:!0,restMs:u,delay:{open:u,close:c},shouldOpen:u>0?()=>z.select("allowMouseEnter"):void 0,triggerElementRef:P,externalTree:C,isClosing:()=>"ending"===h.select("transitionStatus"),guardStaleOpen:!0}),X=(0,T.useClick)(S,{enabled:!V,event:"mousedown",toggle:!l,ignoreMouse:l,stickIfOpen:!1}).reference??w.EMPTY_OBJECT,Z=h.useState("triggerProps",!0);delete Z.id;let ee=h.useState("openMethod"),et=h.useState("lastOpenChangeReason")===U.REASONS.listNavigation||"keyboard"===ee,ea=y&&et&&en.platform.screenReader.voiceOver;return(0,L.useRenderElement)("div",e,{state:{disabled:V,highlighted:_,open:y},stateAttributesMapping:j.triggerOpenStateMapping,props:[X,Q,Z,q,ea?es:void 0,{"aria-controls":k,tabIndex:y||_?0:-1,onBlur(){_&&z.set("activeIndex",null)}},f,K],ref:[t,m.ref,G,A,D]})});var el=e.i(36481),eu=e.i(64170);class ec extends eu.BasePopupHandle{constructor(){super((0,el.createNullMenuStore)(),"Menu")}open(e){this.openByTrigger(e)}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}}e.s(["Arrow",()=>n.MenuArrow,"Backdrop",()=>r.MenuBackdrop,"CheckboxItem",()=>i.MenuCheckboxItem,"CheckboxItemIndicator",()=>o.MenuCheckboxItemIndicator,"Group",()=>s.MenuGroup,"GroupLabel",()=>a.MenuGroupLabel,"Handle",0,ec,"Item",()=>l.MenuItem,"LinkItem",()=>u.MenuLinkItem,"Popup",()=>c.MenuPopup,"Portal",()=>d.MenuPortal,"Positioner",()=>f.MenuPositioner,"RadioGroup",()=>p.MenuRadioGroup,"RadioItem",()=>m.MenuRadioItem,"RadioItemIndicator",()=>g.MenuRadioItemIndicator,"Root",()=>h.MenuRoot,"Separator",0,et,"SubmenuRoot",()=>v.MenuSubmenuRoot,"SubmenuTrigger",0,ea,"Trigger",0,X,"Viewport",0,ee,"createHandle",0,function(){return new ec}],60948);var ed=e.i(60948),ed=ed,ef=e.i(89664),ep=e.i(90063);e.s(["DropdownMenu",0,function(e){return(0,t.jsx)(ed.Root,{"data-slot":"dropdown-menu",...e})},"DropdownMenuContent",0,function({align:e="end",side:n="bottom",sideOffset:r=4,className:i,...o}){return(0,t.jsx)(ed.Portal,{children:(0,t.jsx)(ed.Positioner,{className:"isolate z-50 outline-none",align:e,side:n,sideOffset:r,children:(0,t.jsx)(ed.Popup,{"data-slot":"dropdown-menu-content",className:(0,ep.classNames)("max-h-(--available-height) min-w-48 origin-(--transform-origin) overflow-y-auto rounded-xl border border-border bg-popover p-1 text-popover-foreground shadow-lg duration-(--duration-fast) outline-none data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",i),...o})})})},"DropdownMenuGroup",0,function(e){return(0,t.jsx)(ed.Group,{"data-slot":"dropdown-menu-group",...e})},"DropdownMenuItem",0,function({className:e,variant:n="default",...r}){return(0,t.jsx)(ed.Item,{"data-slot":"dropdown-menu-item","data-variant":n,className:(0,ep.classNames)("relative flex h-8.5 items-center gap-2.5 rounded-sm px-2.5 text-body text-foreground outline-none select-none data-highlighted:bg-accent focus-visible:outline-2 focus-visible:outline-ring data-disabled:pointer-events-none data-disabled:opacity-45 data-[variant=destructive]:text-destructive-text [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-(--size-icon) [&_svg]:text-muted-foreground data-[variant=destructive]:[&_svg]:text-destructive-text",e),...r})},"DropdownMenuLabel",0,function({className:e,...n}){return(0,t.jsx)(ed.GroupLabel,{"data-slot":"dropdown-menu-label",className:(0,ep.classNames)("px-2.5 pt-1.5 pb-1 text-caption text-muted-foreground",e),...n})},"DropdownMenuRadioGroup",0,function(e){return(0,t.jsx)(ed.RadioGroup,{"data-slot":"dropdown-menu-radio-group",...e})},"DropdownMenuRadioItem",0,function({className:e,children:n,...r}){return(0,t.jsxs)(ed.RadioItem,{"data-slot":"dropdown-menu-radio-item",className:(0,ep.classNames)("relative flex h-8.5 items-center gap-2.5 rounded-sm px-2.5 text-body text-foreground outline-none select-none data-highlighted:bg-accent focus-visible:outline-2 focus-visible:outline-ring data-disabled:pointer-events-none data-disabled:opacity-45 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-(--size-icon) [&_svg]:text-muted-foreground",e),...r,children:[n,(0,t.jsx)(ed.RadioItemIndicator,{className:"ml-auto flex",children:(0,t.jsx)(ef.Check,{"aria-hidden":!0,className:"text-foreground"})})]})},"DropdownMenuSeparator",0,function({className:e,...n}){return(0,t.jsx)(ed.Separator,{"data-slot":"dropdown-menu-separator",className:(0,ep.classNames)("-mx-1 my-1 h-px bg-border",e),...n})},"DropdownMenuTrigger",0,function(e){return(0,t.jsx)(ed.Trigger,{"data-slot":"dropdown-menu-trigger",...e})}],57334)},75305,e=>{"use strict";var t=e.i(43476),n=e.i(53753),r=e.i(25913),i=e.i(60964),o=e.i(90063),s=e.i(15905);let a=(0,r.cva)("fixed z-50 flex flex-col bg-popover text-body text-popover-foreground shadow-lg outline-none duration-(--duration-slow) ease-(--ease-standard) data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",{variants:{side:{right:"inset-y-0 right-0 h-full w-full border-l border-border sm:max-w-(--size-sheet) motion-safe:data-open:slide-in-from-right motion-safe:data-closed:slide-out-to-right",bottom:"inset-x-0 bottom-0 max-h-[90dvh] rounded-t-2xl border-t border-border px-4 pt-2 pb-[max(calc(var(--spacing)*4),env(safe-area-inset-bottom))] motion-safe:data-open:slide-in-from-bottom motion-safe:data-closed:slide-out-to-bottom"}},defaultVariants:{side:"right"}});e.s(["Sheet",0,function(e){return(0,t.jsx)(n.Dialog.Root,{"data-slot":"sheet",...e})},"SheetBody",0,function({className:e,...n}){return(0,t.jsx)("div",{"data-slot":"sheet-body",className:(0,o.classNames)("min-h-0 flex-1 overflow-y-auto in-data-[side=right]:p-6",e),...n})},"SheetClose",0,function(e){return(0,t.jsx)(n.Dialog.Close,{"data-slot":"sheet-close",...e})},"SheetContent",0,function({className:e,children:r,side:l="right",...u}){return(0,t.jsxs)(n.Dialog.Portal,{children:[(0,t.jsx)(n.Dialog.Backdrop,{"data-slot":"sheet-overlay",className:"fixed inset-0 z-50 bg-overlay duration-(--duration-slow) data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0"}),(0,t.jsxs)(n.Dialog.Popup,{"data-slot":"sheet-content","data-side":l,className:(0,o.classNames)(a({side:l}),e),...u,children:["bottom"===l?(0,t.jsx)("div",{"aria-hidden":!0,className:"mx-auto mb-3 h-1 w-9 shrink-0 rounded-full bg-border"}):(0,t.jsx)(n.Dialog.Close,{"data-slot":"sheet-close",render:(0,t.jsx)(s.Button,{variant:"ghost",size:"sm",isIconOnly:!0,className:"absolute top-4 right-4","aria-label":"Close"}),children:(0,t.jsx)(i.XIcon,{})}),r]})]})},"SheetDescription",0,function({className:e,...r}){return(0,t.jsx)(n.Dialog.Description,{"data-slot":"sheet-description",className:(0,o.classNames)("text-meta text-muted-foreground",e),...r})},"SheetHeader",0,function({className:e,...n}){return(0,t.jsx)("div",{"data-slot":"sheet-header",className:(0,o.classNames)("flex flex-col gap-0.5 in-data-[side=right]:border-b in-data-[side=right]:px-6 in-data-[side=right]:py-5 in-data-[side=right]:pr-14",e),...n})},"SheetTitle",0,function({className:e,...r}){return(0,t.jsx)(n.Dialog.Title,{"data-slot":"sheet-title",className:(0,o.classNames)("text-heading font-semibold text-foreground in-data-[side=bottom]:py-2 in-data-[side=bottom]:text-section",e),...r})},"SheetTrigger",0,function(e){return(0,t.jsx)(n.Dialog.Trigger,{"data-slot":"sheet-trigger",...e})}])},19321,e=>{"use strict";var t=e.i(43476),n=e.i(90063);e.s(["Skeleton",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"skeleton","aria-hidden":!0,className:(0,n.classNames)("animate-pulse rounded-sm bg-secondary [animation-duration:var(--duration-pulse)] motion-reduce:animate-none",e),...r})}])},60592,e=>{"use strict";var t=e.i(43476);e.i(59657);var n=e.i(41840),r=e.i(88368),i=e.i(49637),o=e.i(49487),s=e.i(71645),a=e.i(67865),l=e.i(46376),u=e.i(56789),c=e.i(53687),d=e.i(19749),f=e.i(38452),p=e.i(52245),m=e.i(72855);function g(e){let{render:n,className:r,style:i,refs:o=u.EMPTY_ARRAY,props:a=u.EMPTY_ARRAY,state:l=u.EMPTY_OBJECT,stateAttributesMapping:g,highlightedIndex:h,onHighlightedIndexChange:v,orientation:b,grid:x,loopFocus:y,onLoop:S,enableHomeAndEndKeys:C,onMapChange:E,stopEventPropagation:R=!0,rootRef:w,disabledIndices:I,modifierKeys:T,highlightItemOnHover:k=!1,tag:O="div",...M}=e,A=(0,m.useDirection)(),{props:P,highlightedIndex:N,onHighlightedIndexChange:j,elementsRef:L,onMapChange:D,relayKeyboardEvent:z}=(0,d.useCompositeRoot)({grid:x,loopFocus:y,onLoop:S,orientation:b,highlightedIndex:h,onHighlightedIndexChange:v,rootRef:w,stopEventPropagation:R,enableHomeAndEndKeys:C,direction:A,disabledIndices:I,modifierKeys:T}),F=(0,p.useRenderElement)(O,e,{state:l,ref:o,props:[P,...a,M],stateAttributesMapping:g}),H=s.useMemo(()=>({highlightedIndex:N,onHighlightedIndexChange:j,highlightItemOnHover:k,relayKeyboardEvent:z}),[N,j,k,z]);return(0,t.jsx)(f.CompositeRootContext.Provider,{value:H,children:(0,t.jsx)(c.CompositeList,{elementsRef:L,onMapChange:e=>{E?.(e),D(e)},children:F})})}var h=e.i(81524),v=e.i(1634),b=e.i(7120);let x=s.forwardRef(function(e,n){let{activateOnFocus:r=!1,className:i,loopFocus:o=!0,render:c,style:d,...f}=e,{orientation:p,setTabMap:m,tabActivationDirection:x}=(0,v.useTabsRootContext)(),[y,S]=s.useState(0),[C,E]=s.useState(null),R=s.useRef(new Set),w=s.useRef(new Set),I=s.useRef(null);(0,l.useIsoLayoutEffect)(()=>{if("u"<typeof ResizeObserver)return;let e=new ResizeObserver(()=>{R.current.forEach(e=>{e()})});return I.current=e,C&&e.observe(C),w.current.forEach(t=>{e.observe(t)}),()=>{e.disconnect(),I.current=null}},[C]);let T=(0,a.useStableCallback)(e=>(R.current.add(e),()=>{R.current.delete(e)})),k=(0,a.useStableCallback)(e=>(w.current.add(e),I.current?.observe(e),()=>{w.current.delete(e),I.current?.unobserve(e)})),O=s.useMemo(()=>({activateOnFocus:r,registerIndicatorUpdateListener:T,registerTabResizeObserverElement:k,tabsListElement:C}),[r,T,k,C]);return(0,t.jsx)(b.TabsListContext.Provider,{value:O,children:(0,t.jsx)(g,{render:c,className:i,style:d,state:{orientation:p,tabActivationDirection:x},refs:[n,E],props:[{"aria-orientation":"vertical"===p?"vertical":void 0,role:"tablist"},f],stateAttributesMapping:h.tabsStateAttributesMapping,highlightedIndex:y,enableHomeAndEndKeys:!0,loopFocus:o,orientation:p,onHighlightedIndexChange:S,onMapChange:m,disabledIndices:u.EMPTY_ARRAY})})});e.s(["Indicator",()=>i.TabsIndicator,"List",0,x,"Panel",()=>o.TabsPanel,"Root",()=>n.TabsRoot,"Tab",()=>r.TabsTab],69281);var y=e.i(69281),y=y,S=e.i(25913),C=e.i(90063);let E=(0,S.cva)("",{variants:{variant:{segmented:"inline-flex items-center gap-0.5 rounded-md border border-border bg-muted p-0.75",line:"flex items-center gap-6 border-b border-border"}},defaultVariants:{variant:"segmented"}}),R=(0,S.cva)("group/tab inline-flex items-center justify-center gap-2 font-medium whitespace-nowrap text-muted-foreground transition-colors duration-(--duration-fast) outline-none hover:text-foreground focus-visible:outline-2 focus-visible:outline-ring data-active:text-foreground data-disabled:pointer-events-none data-disabled:opacity-45",{variants:{variant:{segmented:"h-7 gap-1.5 rounded-sm px-2.5 text-meta data-active:bg-card data-active:shadow-sm",line:"mb-[-1px] h-10 border-b-2 border-transparent px-0.5 text-body data-active:border-foreground"}},defaultVariants:{variant:"segmented"}});e.s(["Tabs",0,function({className:e,...n}){return(0,t.jsx)(y.Root,{"data-slot":"tabs",className:(0,C.classNames)("flex flex-col gap-4",e),...n})},"TabsContent",0,function({className:e,...n}){return(0,t.jsx)(y.Panel,{"data-slot":"tabs-content",className:(0,C.classNames)("outline-none",e),...n})},"TabsCount",0,function({className:e,...n}){return(0,t.jsx)("span",{"data-slot":"tabs-count",className:(0,C.classNames)("text-muted-foreground tabular-nums group-data-active/tab:text-foreground in-data-[variant=line]:inline-flex in-data-[variant=line]:size-5 in-data-[variant=line]:items-center in-data-[variant=line]:justify-center in-data-[variant=line]:rounded-full in-data-[variant=line]:bg-secondary in-data-[variant=line]:text-micro",e),...n})},"TabsList",0,function({className:e,variant:n="segmented",...r}){return(0,t.jsx)(y.List,{"data-slot":"tabs-list","data-variant":n,className:(0,C.classNames)(E({variant:n}),"max-sm:flex max-sm:w-full max-sm:gap-0.5 max-sm:rounded-lg max-sm:border max-sm:border-border max-sm:bg-muted max-sm:p-1",e),...r})},"TabsTrigger",0,function({className:e,variant:n="segmented",...r}){return(0,t.jsx)(y.Tab,{"data-slot":"tabs-trigger",className:(0,C.classNames)(R({variant:n}),"max-sm:h-(--size-control-touch) max-sm:flex-1 max-sm:rounded-md max-sm:border-0 max-sm:px-3 max-sm:text-body-touch max-sm:data-active:bg-card max-sm:data-active:shadow-sm",e),...r})}],60592)},67874,e=>{"use strict";var t=e.i(43476),n=e.i(90063);e.s(["EmptyState",0,function({title:e,description:r,icon:i,action:o,variant:s="page",className:a}){return"section"===s?(0,t.jsxs)("p",{"data-slot":"empty-state","data-variant":s,className:(0,n.classNames)("rounded-lg border border-border px-4 py-3 text-center text-meta text-muted-foreground",a),children:[e,r?(0,t.jsxs)(t.Fragment,{children:[" ",r]}):null]}):"no-results"===s?(0,t.jsxs)("div",{"data-slot":"empty-state","data-variant":s,className:(0,n.classNames)("flex flex-col items-center gap-2.5 rounded-lg border border-border bg-card px-4 py-6 text-center",a),children:[(0,t.jsx)("p",{className:"text-meta text-muted-foreground",children:e}),o]}):(0,t.jsxs)("div",{"data-slot":"empty-state","data-variant":s,className:(0,n.classNames)("flex flex-col items-center gap-3 rounded-lg border border-dashed border-border bg-card px-6 py-10 text-center",a),children:[i?(0,t.jsx)("span",{"aria-hidden":!0,className:"flex size-10 items-center justify-center rounded-lg border border-border bg-muted text-muted-foreground [&_svg]:size-(--size-icon-xl)",children:i}):null,(0,t.jsx)("h2",{className:"text-heading font-semibold text-foreground max-sm:text-heading-touch",children:e}),r?(0,t.jsx)("p",{className:"max-w-96 text-meta text-muted-foreground max-sm:text-body-touch",children:r}):null,o?(0,t.jsx)("div",{className:"mt-1 max-sm:w-full max-sm:[&>*]:w-full",children:o}):null]})}])},17981,25398,e=>{"use strict";var t=e.i(43476),n=e.i(22768),r=e.i(56420);let i={name:"cloud-off",size:24,node:[["path",{d:"M10.94 5.274A7 7 0 0 1 15.71 10h1.79a4.5 4.5 0 0 1 4.222 6.057",key:"1uxyv8"}],["path",{d:"M18.796 18.81A4.5 4.5 0 0 1 17.5 19H9A7 7 0 0 1 5.79 5.78",key:"99tcn7"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]]};i.node;let o=(0,r.default)(i),s={name:"rotate-cw",size:24,node:[["path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8",key:"1p45f6"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}]]};s.node;let a=(0,r.default)(s);e.s(["RotateCw",0,a],25398);var l=e.i(90063),u=e.i(15905);e.s(["InlineError",0,function({title:e,description:r,detail:i,onRetry:s,retryNote:c,variant:d="section",id:f,className:p}){return"field"===d?(0,t.jsxs)("p",{id:f,"data-slot":"inline-error","data-variant":d,className:(0,l.classNames)("flex items-center gap-1.5 text-meta text-destructive-text [&_svg]:size-(--size-icon-sm) [&_svg]:shrink-0",p),children:[(0,t.jsx)(n.CircleAlert,{"aria-hidden":!0}),e]}):"section"===d?(0,t.jsxs)("div",{role:"alert","data-slot":"inline-error","data-variant":d,className:(0,l.classNames)("flex gap-2 rounded-lg border border-tone-attention-border bg-tone-attention-bg p-3 text-tone-attention-fg",p),children:[(0,t.jsx)(n.CircleAlert,{"aria-hidden":!0,className:"mt-0.5 size-(--size-icon) shrink-0"}),(0,t.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,t.jsx)("p",{className:"text-body font-medium",children:e}),r?(0,t.jsx)("p",{className:"text-meta text-foreground",children:r}):null,s?(0,t.jsx)(u.Button,{size:"xs",icon:(0,t.jsx)(a,{"aria-hidden":!0}),onClick:s,className:"self-start",children:"Try again"}):null]})]}):(0,t.jsxs)("div",{role:"alert","data-slot":"inline-error","data-variant":d,className:(0,l.classNames)("flex flex-col items-center gap-3 rounded-lg border border-border bg-card px-6 py-10 text-center",p),children:[(0,t.jsx)("span",{"aria-hidden":!0,className:"flex size-10 items-center justify-center rounded-lg border border-tone-attention-border bg-tone-attention-bg text-tone-attention-fg [&_svg]:size-(--size-icon-xl)",children:(0,t.jsx)(o,{})}),(0,t.jsx)("h2",{className:"text-heading font-semibold text-foreground max-sm:text-heading-touch",children:e}),r?(0,t.jsx)("p",{className:"max-w-96 text-meta text-muted-foreground max-sm:text-body-touch",children:r}):null,i?(0,t.jsx)("code",{className:"rounded-sm border border-border bg-muted px-2 py-0.5 font-mono text-id text-muted-foreground",children:i}):null,s?(0,t.jsxs)("div",{className:"flex items-center gap-2 max-sm:w-full max-sm:flex-col",children:[(0,t.jsx)(u.Button,{size:"sm",icon:(0,t.jsx)(a,{"aria-hidden":!0}),onClick:s,className:"max-sm:w-full",children:"Try again"}),c?(0,t.jsx)("span",{className:"text-meta text-muted-foreground",children:c}):null]}):null]})}],17981)},77435,66595,e=>{"use strict";var t=e.i(43476),n=e.i(71028);e.s(["LimitNotice",0,function({title:e,description:r,accountUrl:i,testId:o}){return(0,t.jsxs)("div",{role:"status","data-testid":o,className:"flex gap-2 rounded-lg border border-tone-attention-border bg-tone-attention-bg p-3 text-tone-attention-fg",children:[(0,t.jsx)(n.Gauge,{"aria-hidden":!0,className:"mt-0.5 size-(--size-icon) shrink-0"}),(0,t.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,t.jsx)("p",{className:"text-body font-medium",children:e}),(0,t.jsx)("p",{className:"text-meta text-foreground",children:r}),void 0===i?null:(0,t.jsx)("a",{href:i,className:"self-start text-meta font-medium text-tone-attention-fg underline underline-offset-2","data-testid":void 0===o?void 0:`${o}-view`,children:"View limits"})]})]})}],77435);var r=e.i(56420);let i={name:"search",size:24,node:[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]]};i.node;let o=(0,r.default)(i);e.s(["Search",0,o],66595)},88393,e=>{"use strict";var t=e.i(43476),n=e.i(90063),r=e.i(19321);function i(e){return Array.from({length:e},(e,t)=>`row-${String(t)}`)}e.s(["LoadingSkeleton",0,function({variant:e,rows:o=4,label:s="Loading",className:a}){return(0,t.jsxs)("div",{role:"status","data-slot":"loading-skeleton","data-variant":e,className:(0,n.classNames)("w-full",a),children:[(0,t.jsx)("span",{className:"sr-only",children:s}),"table"===e?(0,t.jsxs)("div",{className:"overflow-hidden rounded-lg border border-border bg-card shadow-sm",children:[(0,t.jsx)("div",{className:"h-(--size-row-header) border-b border-border bg-muted"}),i(o).map(e=>(0,t.jsxs)("div",{className:"flex h-(--size-row) items-center gap-8 border-b border-border px-4 last:border-0",children:[(0,t.jsx)(r.Skeleton,{className:"h-2.5 w-24"}),(0,t.jsx)(r.Skeleton,{className:"h-5 w-16"}),(0,t.jsx)(r.Skeleton,{className:"h-5 w-20"}),(0,t.jsx)(r.Skeleton,{className:"h-2.5 w-28"})]},e))]}):null,"cards"===e?(0,t.jsx)("div",{className:"grid grid-cols-2 gap-3 lg:grid-cols-4",children:i(4).map(e=>(0,t.jsxs)("div",{className:"flex flex-col gap-3 rounded-lg border border-border bg-card p-4",children:[(0,t.jsx)(r.Skeleton,{className:"h-2.5 w-20"}),(0,t.jsx)(r.Skeleton,{className:"h-6 w-10"}),(0,t.jsx)(r.Skeleton,{className:"h-2.5 w-28"})]},e))}):null,"detail"===e?(0,t.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,t.jsx)(r.Skeleton,{className:"h-7 w-48"}),(0,t.jsxs)("div",{className:"flex gap-2",children:[(0,t.jsx)(r.Skeleton,{className:"h-5 w-20"}),(0,t.jsx)(r.Skeleton,{className:"h-5 w-16"})]}),(0,t.jsx)(r.Skeleton,{className:"h-16 w-full rounded-lg"})]}):null,"list"===e?(0,t.jsx)("div",{className:"overflow-hidden rounded-lg border border-border bg-card",children:i(o).map(e=>(0,t.jsxs)("div",{className:"flex flex-col gap-2.5 border-b border-border px-3.5 py-3 last:border-0",children:[(0,t.jsxs)("div",{className:"flex justify-between",children:[(0,t.jsx)(r.Skeleton,{className:"h-3 w-28"}),(0,t.jsx)(r.Skeleton,{className:"h-5 w-16"})]}),(0,t.jsx)(r.Skeleton,{className:"h-2.5 w-44"})]},e))}):null]})}])},78865,e=>{"use strict";var t=e.i(43476),n=e.i(87255),r=e.i(76561),i=e.i(47211),o=e.i(50092),s=e.i(32297),a=e.i(74544),l=e.i(85595),u=e.i(52886),c=e.i(26391),d=e.i(19647),f=e.i(16984),p=e.i(10001),m=e.i(71028),g=e.i(81658),h=e.i(11568),v=e.i(57665),b=e.i(95925),x=e.i(85627),y=e.i(66787),S=e.i(92870),C=e.i(90063),E=e.i(66390);let R={waiting:"border-tone-waiting-border bg-tone-waiting-bg text-tone-waiting-fg",active:"border-tone-active-border bg-tone-active-bg text-tone-active-fg",ok:"border-tone-ok-border bg-tone-ok-bg text-tone-ok-fg",attention:"border-tone-attention-border bg-tone-attention-bg text-tone-attention-fg",ended:"border-tone-ended-border bg-tone-ended-bg text-tone-ended-fg"},w={awaitingCrew:{tone:"waiting",Icon:u.CircleDashed,label:"Awaiting crew"},crewed:{tone:"ok",Icon:S.UserCheck,label:"Crewed"},retired:{tone:"ended",Icon:r.Archive,label:"Retired"},pending:{tone:"waiting",Icon:g.Hourglass,label:"Pending"},delivered:{tone:"active",Icon:o.CircleArrowRight,label:"In flight"},acknowledged:{tone:"ok",Icon:l.CircleCheck,label:"Acknowledged"},undeliverable:{tone:"attention",Icon:f.CircleX,label:"Undeliverable"},dismissed:{tone:"ended",Icon:d.CircleMinus,label:"Dismissed"},abandoned:{tone:"ended",Icon:i.Ban,label:"Abandoned"},forming:{tone:"waiting",Icon:c.CircleDotDashed,label:"Forming"},sailing:{tone:"ok",Icon:x.Sailboat,label:"Sailing"},"standing-down":{tone:"active",Icon:n.Anchor,label:"Standing down"},disbanded:{tone:"ended",Icon:p.FlagOff,label:"Disbanded"},"at-limit":{tone:"waiting",Icon:m.Gauge,label:"At limit"},"over-limit":{tone:"attention",Icon:y.TriangleAlert,label:"Over limit"},needsCrew:{tone:"waiting",Icon:a.Clock,label:"Needs crew"},crewedByHand:{tone:"ok",Icon:S.UserCheck,label:"Crewed by hand"},crewing:{tone:"active",Icon:h.LoaderCircle,label:"Crewing"},running:{tone:"ok",Icon:s.CirclePlay,label:"Running"},restarting:{tone:"waiting",Icon:b.RotateCcw,label:"Restarting"},crashed:{tone:"attention",Icon:f.CircleX,label:"Crashed"},releasing:{tone:"active",Icon:v.Power,label:"Releasing"}};e.s(["StatusBadge",0,function({status:e,className:n}){let{tone:r,Icon:i,label:o}=w[e];return(0,t.jsxs)(E.Badge,{variant:"outline","data-slot":"status-badge","data-status":e,className:(0,C.classNames)(R[r],"abandoned"===e?"border-dashed":void 0,n),children:[(0,t.jsx)(i,{"aria-hidden":!0}),o]})},"statusLabel",0,function(e){return w[e].label}])},44824,36651,31071,e=>{"use strict";var t=e.i(43476),n=e.i(71645),r=e.i(57497),i=e.i(5387),o=e.i(41880),s=e.i(49092),a=e.i(87600),l=e.i(16752);e.i(31627);var u=e.i(26006),c=e.i(30274),d=e.i(74470),f=e.i(15905),p=e.i(22212),m=e.i(94945),g=e.i(91727),h=e.i(43988),v=e.i(17981),b=e.i(77435),x=e.i(22768),y=e.i(66595),S=e.i(80799),C=e.i(40798),E=e.i(46150),R=e.i(65160),w=e.i(33173),I=e.i(60592),T=e.i(78865);let k=["ship","type"];function O(e){let{location:n}=e,r=null===n?null:n.description??(0,C.locationKindWord)(n.kind);return{value:e.id,label:e.name,detail:null===r?e.type:`${e.type} \xb7 ${r}`,trailing:(0,t.jsx)(T.StatusBadge,{status:e.status})}}let M={one:"ship",many:"ships"};function A(e,t){return e.filter(e=>e.type===t).length}function P({mode:e,onModeChange:r,value:i,onChange:o,ships:s,types:a,error:l}){let u=(0,n.useId)(),c=(0,n.useId)(),d=i?.kind==="type"?i.type:null,f=null===d?0:A(s,d);return(0,t.jsxs)("div",{"data-slot":"selector-picker",className:"flex flex-col gap-1.5",children:[(0,t.jsx)(g.Label,{htmlFor:u,children:"To"}),(0,t.jsx)(I.Tabs,{value:e,onValueChange:e=>{let t=k.find(t=>t===e);void 0!==t&&r(t)},children:(0,t.jsxs)(I.TabsList,{"aria-label":"Send to",className:"w-full",children:[(0,t.jsx)(I.TabsTrigger,{value:"ship","data-testid":"compose-mode-ship",className:"grow",children:"A specific ship"}),(0,t.jsx)(I.TabsTrigger,{value:"type","data-testid":"compose-mode-type",className:"grow",children:"Any ship of a type"})]})}),"ship"===e?(0,t.jsx)(w.Combobox,{id:u,options:s.map(O),value:i?.kind==="ship"?i.shipId:null,onValueChange:e=>{let t=s.find(t=>t.id===e);o(t?{kind:"ship",shipId:t.id}:null)},toQuery:R.asHandle,groupLabel:"Ships",emptyText:e=>`No ship matches "${e}". Retired ships are not listed.`,leadingIcon:(0,t.jsx)(y.Search,{}),placeholder:"Choose a ship",isInvalid:void 0!==l,"aria-describedby":c,"data-testid":"compose-ship"},"ship"):(0,t.jsx)(w.Combobox,{id:u,options:a.map(e=>({value:e,label:e,trailing:(0,t.jsx)("span",{className:"text-meta text-muted-foreground tabular-nums",children:(0,E.counted)(A(s,e),M)})})),value:d,onValueChange:e=>{o(null===e||""===e.trim()?null:{kind:"type",type:e.trim()})},isFreeText:!0,toQuery:R.asHandle,leadingIcon:(0,t.jsx)(S.Tag,{}),placeholder:"Type",isInvalid:void 0!==l,"aria-describedby":c,"data-testid":"compose-type"},"type"),void 0===l?(0,t.jsx)("p",{id:c,className:"text-meta text-muted-foreground",children:"ship"===e?"If the ship has no crew right now, the message waits in its inbox.":`Goes to a queue any ship of this type can claim from.${null===d?"":` ${(0,E.counted)(f,M)} ${1===f?"uses":"use"} this type.`}`}):(0,t.jsxs)("p",{id:c,role:"alert",className:"flex items-center gap-1.5 text-meta text-destructive [&_svg]:size-(--size-icon-sm)",children:[(0,t.jsx)(x.CircleAlert,{"aria-hidden":!0}),l]})]})}var N=e.i(90063);function j({className:e,...n}){return(0,t.jsx)("kbd",{"data-slot":"kbd",className:(0,N.classNames)("inline-flex h-5 min-w-5 shrink-0 items-center justify-center rounded-xs border border-border bg-muted px-1.25 font-sans text-micro font-medium text-muted-foreground max-sm:hidden",e),...n})}function L({platform:e}){return(0,t.jsx)(j,{"aria-hidden":!0,"data-testid":"send-shortcut-hint",className:"border-primary-foreground/25 bg-primary-foreground/10 text-primary-foreground",children:(0,d.sendShortcutKeys)(e)})}function D({ships:e,types:r,state:i,error:o,messageLimit:s,accountUrl:a,onSend:m,draft:x}){let y=(0,n.useId)(),S=(0,n.useId)(),[C,E]=(0,n.useState)(x?.selector.kind??"ship"),[R,w]=(0,n.useState)(x?.selector??null),[I,T]=(0,n.useState)(x?.payload??""),k=(0,u.payloadBytes)(I)>u.PAYLOAD_MAX_BYTES,O="sending"===i,M=null!==R&&""!==I.trim()&&!k&&!O,A=(0,d.useShortcutPlatform)();return(0,t.jsxs)("form",{className:"flex flex-col gap-4",onSubmit:e=>{e.preventDefault(),M&&m({selector:R,payload:I})},children:[(0,t.jsx)(P,{mode:C,onModeChange:e=>{E(e),w(null)},value:R,onChange:w,ships:e,types:r}),(0,t.jsxs)("div",{className:"flex flex-col gap-1.5",children:[(0,t.jsx)(g.Label,{htmlFor:y,children:"Message"}),(0,t.jsx)(h.Textarea,{id:y,isMono:!0,rows:6,value:I,onChange:e=>{T(e.target.value)},onKeyDown:d.submitOnSendShortcut,placeholder:"What the ship should do, and where the work lives","aria-invalid":k,"aria-describedby":k?S:void 0,"data-testid":"compose-payload"}),k?(0,t.jsx)(v.InlineError,{variant:"field",id:S,title:"A message is at most 64 KB. Send a reference to where the content lives."}):(0,t.jsx)("p",{className:"text-meta text-muted-foreground",children:"Sent as plain text from argo, stored before the fleet says OK."})]}),"failed"===i&&void 0!==s?(0,t.jsx)(b.LimitNotice,{...(0,l.composeRefusedNotice)(s),accountUrl:a,testId:"compose-message-limit"}):"failed"===i&&void 0!==o?(0,t.jsx)(v.InlineError,{title:"Couldn’t send the message",description:`${o} Nothing was sent; your message is kept here.`}):null,(0,t.jsxs)(p.DialogFooter,{children:[(0,t.jsx)(p.DialogClose,{render:(0,t.jsx)(f.Button,{disabled:O}),children:"Cancel"}),(0,t.jsxs)(f.Button,{type:"submit",variant:"primary",icon:(0,t.jsx)(c.Send,{"aria-hidden":!0}),disabled:!M&&!O,isLoading:O,"aria-keyshortcuts":null===A?void 0:(0,d.sendShortcutAria)(A),"data-testid":"compose-send",children:["Send",null===A?null:(0,t.jsx)(L,{platform:A})]})]})]})}function z({isOpen:e,onOpenChange:n,...r}){return(0,t.jsx)(p.Dialog,{open:e,onOpenChange:n,children:(0,t.jsxs)(p.DialogContent,{size:"md","data-testid":"compose-dialog",className:m.dialogSurface.phoneFullScreen,children:[(0,t.jsxs)(p.DialogHeader,{children:[(0,t.jsx)(p.DialogTitle,{children:"New message"}),(0,t.jsx)(p.DialogDescription,{children:"From argo. The ship receives it the next time its session asks for work."})]}),(0,t.jsx)(D,{...r})]})})}e.s(["Kbd",0,j],36651),e.s(["SendShortcutHint",0,L],31071),e.s(["ComposeMessage",0,function({isOpen:e,onOpenChange:u,replyTo:c,toShipId:d}){let f=(0,i.useFleetSnapshot)(),p=(0,r.useSendMessage)(),m=(0,s.useFleetLimits)(),g=(0,a.useHostedAccountUrl)(),[h,v]=(0,n.useState)(()=>crypto.randomUUID()),{ships:b,types:x}=(0,r.composeTargets)(f.data??[]);return(0,t.jsx)(z,{isOpen:e,onOpenChange:e=>{e||p.reset(),u(e)},ships:b,types:x,state:p.isPending?"sending":p.isError?"failed":"editing",error:p.error?.message,messageLimit:p.isError?(0,l.messageLimitReached)(m.data):void 0,accountUrl:g,draft:c?{selector:{kind:"ship",shipId:c.sender.id},payload:""}:d&&{selector:{kind:"ship",shipId:d},payload:""},onSend:e=>{p.mutate((0,r.sendInputOf)({...e,inReplyTo:c?.messageId},h),{onSuccess:()=>{v(crypto.randomUUID()),p.reset(),u(!1),(0,o.showToast)({title:"Message sent",description:"It waits in the inbox until a ship receives it.",tone:"success"})},onError:()=>{m.refetch()}})}})}],44824)},45608,19759,57443,47321,77155,58421,22646,94242,49237,50316,73752,44681,72135,46570,41225,21125,73336,63550,31157,e=>{"use strict";var t=e.i(43476),n=e.i(18566),r=e.i(71645),i=e.i(90262),o=e.i(76145),s=e.i(5387),a=e.i(86165),l=e.i(48695),u=e.i(84294),c=e.i(19191),d=e.i(77913),f=e.i(44594),p=e.i(77071),m=e.i(66595),g=e.i(60011),h=e.i(49287),v=e.i(56420);let b={name:"square-pen",size:24,node:[["path",{d:"M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7",key:"1m0v6g"}],["path",{d:"M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z",key:"ohrbg2"}]],aliases:["pen-box","edit","pen-square"]};b.node;let x=(0,v.default)(b);e.s(["SquarePen",0,x],19759);var y=e.i(66787);let S={name:"user-plus",size:24,node:[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["line",{x1:"19",x2:"19",y1:"8",y2:"14",key:"1bvyxn"}],["line",{x1:"22",x2:"16",y1:"11",y2:"11",key:"1shjgl"}]]};S.node;let C=(0,v.default)(S);e.s(["UserPlus",0,C],57443);let E={name:"waves-horizontal",size:24,node:[["path",{d:"M2 12q2.5 2 5 0t5 0 5 0 5 0",key:"8ddzzs"}],["path",{d:"M2 19q2.5 2 5 0t5 0 5 0 5 0",key:"1wj4st"}],["path",{d:"M2 5q2.5 2 5 0t5 0 5 0 5 0",key:"69x50u"}]],aliases:["waves"]};E.node;let R=(0,v.default)(E);e.s(["Waves",0,R],47321);var w=e.i(90063),I=e.i(94859),T=e.i(15905),k=e.i(22212),O=e.i(94945),M=e.i(36651),A=e.i(78865);let P={compose:x,commission:p.Plus,"form-squadron":p.Plus,overview:h.Ship,squadrons:g.Shapes,inbox:f.Inbox,attention:y.TriangleAlert};function N({item:e}){if("ship"===e.kind)return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(I.Avatar,{name:e.name,size:20}),(0,t.jsx)("span",{className:"min-w-0 truncate font-mono text-body font-medium text-foreground",children:e.name}),(0,t.jsx)("span",{className:"min-w-0 truncate text-meta text-muted-foreground",children:e.type}),(0,t.jsx)(A.StatusBadge,{status:e.status,className:"ml-auto"})]});if("squadron"===e.kind)return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(g.Shapes,{"aria-hidden":!0,className:"size-(--size-icon) shrink-0 text-muted-foreground"}),(0,t.jsx)("span",{className:"min-w-0 truncate text-body font-medium text-foreground",children:e.id}),(0,t.jsx)("span",{className:"min-w-0 truncate font-mono text-meta text-muted-foreground",children:e.blueprint}),(0,t.jsx)(A.StatusBadge,{status:e.state,className:"ml-auto"})]});if("blueprint"===e.kind)return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(d.DraftingCompass,{"aria-hidden":!0,className:"size-(--size-icon) shrink-0 text-muted-foreground"}),(0,t.jsx)("span",{className:"min-w-0 truncate font-mono text-body text-foreground",children:e.name}),(0,t.jsxs)("span",{className:"text-meta text-muted-foreground",children:["v",e.version]})]});if("squadron-action"===e.kind){let n="add-member"===e.action?C:R;return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(n,{"aria-hidden":!0,className:"size-(--size-icon) shrink-0 text-muted-foreground"}),(0,t.jsx)("span",{className:"min-w-0 truncate",children:e.label})]})}let n=P[e.id];return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(n,{"aria-hidden":!0,className:"size-(--size-icon) shrink-0 text-muted-foreground"}),(0,t.jsx)("span",{className:"min-w-0 truncate",children:e.label})]})}function j({items:e,onSelect:n,onOpenChange:i,initialQuery:s=""}){let a=(0,r.useId)(),l=(0,r.useId)(),[u,d]=(0,r.useState)(s),[f,p]=(0,r.useState)(0),g=(0,o.paletteGroups)(e,u),h=g.flatMap(e=>e.items),v=h[Math.min(f,h.length-1)],b=e=>`${l}-${(0,o.paletteKeyOf)(e)}`,x=e=>{n(e),i(!1)};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(k.DialogTitle,{className:"sr-only",children:"Search ships or jump to"}),(0,t.jsxs)("div",{className:"flex h-12 items-center gap-2.5 border-b border-border px-4 max-sm:h-(--size-header)",children:[(0,t.jsx)(m.Search,{"aria-hidden":!0,className:"size-(--size-icon) shrink-0 text-muted-foreground"}),(0,t.jsx)("input",{role:"combobox","aria-expanded":!0,"aria-controls":a,"aria-activedescendant":v?b(v):void 0,"aria-autocomplete":"list","aria-label":"Search ships or jump to",autoComplete:"off",autoCapitalize:"off",spellCheck:!1,placeholder:"Search ships or jump to","data-testid":"command-palette-input",className:"h-full min-w-0 grow bg-transparent text-body text-foreground outline-none placeholder:text-muted-foreground max-sm:text-body-touch",value:u,onChange:e=>{d(e.target.value),p(0)},onKeyDown:e=>{if(0!==h.length)if("ArrowDown"===e.key||"ArrowUp"===e.key){e.preventDefault();let t="ArrowDown"===e.key?1:-1;p(((v?h.indexOf(v):0)+t+h.length)%h.length)}else"Enter"===e.key&&v&&(e.preventDefault(),x(v))}}),(0,t.jsx)(M.Kbd,{children:"esc"}),(0,t.jsx)(k.DialogClose,{render:(0,t.jsx)(T.Button,{variant:"ghost",size:"sm",className:"sm:hidden"}),children:"Cancel"})]}),(0,t.jsx)("div",{className:"max-h-[min(60dvh,var(--spacing)*100)] overflow-y-auto p-2 max-sm:max-h-none max-sm:grow",children:0===h.length?(0,t.jsxs)("p",{className:"px-4 py-6 text-center text-meta text-muted-foreground",children:["Nothing matches “",u.trim(),"”. Ships are found by name or type; retired ships are not listed."]}):(0,t.jsx)("ul",{id:a,role:"listbox","aria-label":"Results",className:"flex flex-col gap-2",children:g.map(e=>(0,t.jsxs)("li",{role:"presentation",className:"flex flex-col gap-0.5",children:[(0,t.jsx)("p",{id:`${a}-${e.key}`,className:"px-2.5 pt-1 pb-0.5 text-caption font-medium text-muted-foreground",children:e.label}),(0,t.jsx)("ul",{role:"group","aria-labelledby":`${a}-${e.key}`,className:"flex flex-col gap-0.5",children:e.items.map(e=>{let n=e===v;return(0,t.jsx)("li",{id:b(e),role:"option","aria-selected":n,"data-testid":"command-palette-item","data-item-kind":e.kind,"data-item-id":e.id,className:(0,w.classNames)("flex h-(--size-control) cursor-pointer items-center gap-2.5 rounded-md px-2.5 text-body text-foreground max-sm:h-(--size-control-touch)",n?"bg-accent":void 0),onPointerMove:()=>{p(h.indexOf(e))},onClick:()=>{x(e)},children:(0,t.jsx)(N,{item:e})},(0,o.paletteKeyOf)(e))})})]},e.key))})}),(0,t.jsxs)("div",{className:"flex items-center gap-3 border-t border-border px-4 py-2 text-caption text-muted-foreground max-sm:hidden",children:[(0,t.jsxs)("span",{className:"inline-flex items-center gap-1",children:[(0,t.jsx)(M.Kbd,{children:"↑"}),(0,t.jsx)(M.Kbd,{children:"↓"}),"Move"]}),(0,t.jsxs)("span",{className:"inline-flex items-center gap-1",children:[(0,t.jsx)(M.Kbd,{children:(0,t.jsx)(c.CornerDownLeft,{"aria-hidden":!0,className:"size-3"})}),"Open"]}),(0,t.jsxs)("span",{className:"inline-flex items-center gap-1",children:[(0,t.jsx)(M.Kbd,{children:"esc"}),"Close"]})]})]})}function L({isOpen:e,onOpenChange:n,...r}){return(0,t.jsx)(k.Dialog,{open:e,onOpenChange:n,children:(0,t.jsx)(k.DialogContent,{size:"md","data-testid":"command-palette",className:(0,w.classNames)("gap-0 p-0 sm:top-[12dvh] sm:translate-y-0",O.dialogSurface.phoneFullScreen,"max-sm:flex max-sm:flex-col"),children:(0,t.jsx)(j,{onOpenChange:n,...r})})})}e.s(["ConsoleCommands",0,function({isOpen:e,onOpenChange:c,onCompose:d}){let f=(0,n.useRouter)(),p=(0,s.useFleetSnapshot)(),m=(0,a.useHasSquadrons)(),g=(0,l.useSquadrons)(),h=(0,l.useCatalogue)(),v=(0,i.useAccess)();return(0,r.useEffect)(()=>{let e=e=>{(e.metaKey||e.ctrlKey)&&"k"===e.key.toLowerCase()&&(e.preventDefault(),c(!0))};return document.addEventListener("keydown",e),()=>{document.removeEventListener("keydown",e)}},[c]),(0,t.jsx)(L,{isOpen:e,onOpenChange:c,items:(0,o.allowedPaletteItems)((0,o.paletteItemsOf)(p.data??[],m?{squadrons:g.data??[],blueprints:(0,u.blueprintChoices)(h.data??{blueprints:[]})}:void 0),v),onSelect:e=>{switch(e.kind){case"ship":case"page":case"squadron":case"squadron-action":case"blueprint":f.push(e.href);return;case"action":"compose"===e.id?d():"form-squadron"===e.id?f.push("/squadrons?form=new"):f.push("/?commission=new")}}})}],45608);var D=e.i(54616),z=e.i(66027),F=e.i(12598),H=e.i(41880),V=e.i(32150),q=e.i(27702);function _(e){return e.split(/[?#]/)[0]??e}function B(e){let t=new MutationObserver(e);return t.observe(document.body,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["class","hidden","style"]}),window.addEventListener("resize",e),()=>{t.disconnect(),window.removeEventListener("resize",e)}}e.s(["useConsoleGuide",0,function(){let e=(0,q.useTRPC)(),t=(0,n.useRouter)(),r=(0,n.usePathname)(),i=(0,F.useQueryClient)(),o=(0,z.useQuery)(e.console.guide.queryOptions()),s=e.console.guide.queryKey(),a=(0,D.useMutation)(e.console.recordGuideProgress.mutationOptions({onMutate:e=>{i.setQueryData(s,t=>t?{...t,progress:e}:t)},onError:()=>{(0,H.showToast)({title:"Couldn’t keep your place in the tour",description:"The server did not answer. Try again.",tone:"error"})},onSettled:()=>i.invalidateQueries({queryKey:s})})),{track:l}=(0,V.useAnalytics)(),u=o.data?.steps??[],c=o.data?.progress.step??0,d=function(e){if(e?.progress.state!=="open")return;let t=e.steps[e.progress.step];return void 0===t?void 0:{step:t,index:e.progress.step,total:e.steps.length}}(o.data??void 0),f=e=>{a.mutate(e);let n=u[e.step];"open"===e.state&&void 0!==n&&_(n.path)!==r&&t.push(n.path)},p=e=>{f({step:e,state:"open"}),l({name:"tour_step_reached",step:e+1,total:u.length})};return{view:d,onBack:()=>{p(Math.max(c-1,0))},onNext:()=>{p(Math.min(c+1,u.length-1))},onSkip:()=>{f({step:c,state:"skipped"}),l({name:"tour_skipped",step:c+1})},onFinish:()=>{f({step:c,state:"finished"}),l({name:"tour_finished"})},onTakeTour:0===u.length?void 0:()=>{f({step:0,state:"open"})}}},"useGuideAnchor",0,function(e){let t=(0,n.usePathname)(),i=e?void 0!==e.anchor&&_(e.path)===t?`[data-testid="${e.anchor}"]`:void 0:void 0;return(0,r.useSyncExternalStore)(B,()=>void 0===i?null:[...document.querySelectorAll(i)].find(e=>e.getClientRects().length>0)??null,()=>null)},"useTourStarted",0,function(e){let{track:t}=(0,V.useAnalytics)(),n=(0,r.useRef)(!1),i=void 0!==e,o=e?.index===0;(0,r.useEffect)(()=>{i&&!n.current&&o&&t({name:"tour_started"}),n.current=i},[i,o,t])}],77155),e.s([],58421);var W=e.i(96499),$=e.i(17989),U=e.i(46420),K=e.i(33332);let G=r.createContext(void 0);function Y(e){let t=r.useContext(G);if(void 0===t&&!e)throw Error((0,K.default)(47));return t}e.s(["PopoverRootContext",0,G,"usePopoverRootContext",0,Y],22646);var Q=e.i(74080),X=e.i(26352),J=e.i(39957),Z=e.i(56789),ee=e.i(56434),et=e.i(18478),en=e.i(64111),er=e.i(16786),ei=e.i(90627),eo=e.i(38396);let es={...er.popupStoreSelectors,disabled:e=>e.disabled,instantType:e=>e.instantType,openMethod:e=>e.openMethod,openChangeReason:e=>e.openChangeReason,modal:e=>e.modal,focusManagerModal:e=>e.focusManagerModal,stickIfOpen:e=>e.stickIfOpen,titleElementId:e=>e.titleElementId,descriptionElementId:e=>e.descriptionElementId,openOnHover:e=>e.openOnHover,closeDelay:e=>e.closeDelay,adaptiveOrigin:e=>e.adaptiveOrigin};class ea extends X.ReactStore{constructor(e,t,n){const r=new ei.PopupTriggerMap;super(el(e,r,t,n),eu(r),es)}setOpen=(e,t)=>{let n,r=t.reason===ee.REASONS.triggerHover,i=t.reason===ee.REASONS.triggerPress&&0===t.event.detail,o=!e&&(t.reason===ee.REASONS.escapeKey||null==t.reason),s=(0,en.attachPreventUnmountOnClose)(t),a=this.select("activeTriggerId");if(e||t.reason!==ee.REASONS.closePress||null!=t.trigger||null==a||(t.trigger=this.context.triggerElements.getById(a)??this.select("activeTriggerElement")??void 0),this.context.onOpenChange?.(e,t),t.isCanceled)return;this.state.floatingRootContext.dispatchOpenChange(e,t);let l=()=>{let n=(0,en.createPopupOpenState)(this.state,e,t.trigger,s());n.openChangeReason=t.reason,this.update(n)};r?(this.set("stickIfOpen",!0),this.context.stickIfOpenTimeout.start(eo.PATIENT_CLICK_THRESHOLD,()=>{this.set("stickIfOpen",!1)}),Q.flushSync(l)):l(),i?n="click":o?n="dismiss":t.reason===ee.REASONS.focusOut&&(n="focus"),this.set("instantType",n)}}function el(e,t,n,r=!1){let i={...(0,er.createInitialPopupStoreState)(t,n,r),disabled:!1,modal:!1,focusManagerModal:!1,instantType:void 0,openMethod:null,openChangeReason:null,titleElementId:void 0,descriptionElementId:void 0,stickIfOpen:!0,openOnHover:!1,closeDelay:0,adaptiveOrigin:void 0,...e};return i.open&&e?.mounted===void 0&&(i.mounted=!0),i}function eu(e){return{popupRef:r.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerFocusTargetRef:r.createRef(),beforeContentFocusGuardRef:r.createRef(),stickIfOpenTimeout:new J.Timeout,triggerElements:e}}e.s(["PopoverStore",0,ea,"createNullPopoverStore",0,function(){let e=new ei.PopupTriggerMap;return Object.assign(new et.NullStore(Object.freeze(el(void 0,e)),Object.freeze(eu(e)),es),{setOpen:Z.NOOP})}],94242);var ec=e.i(75606);let ed=(0,W.fastComponent)(function({props:e}){var n;let i,{children:o,open:s,defaultOpen:a=!1,onOpenChange:l,onOpenChangeComplete:u,modal:c=!1,handle:d,triggerId:f,defaultTriggerId:p=null}=e,m=(n={modal:c,open:a,openProp:s,activeTriggerId:p,triggerIdProp:f},i=(0,en.usePopupRootStore)((e,t)=>new ea(n,e,t)),r.useEffect(()=>i.context.stickIfOpenTimeout.disposeEffect(),[i]),i);m.useControlledProp("openProp",s),m.useControlledProp("triggerIdProp",f);let g=m.useState("open"),h=m.useState("mounted"),v=m.useState("payload");m.useContextCallback("onOpenChange",l),m.useContextCallback("onOpenChangeComplete",u),(0,en.usePopupRootSync)(m,g),(0,en.useImplicitActiveTrigger)(m);let{forceUnmount:b}=(0,en.useOpenStateTransitions)(g,m,()=>{m.update({stickIfOpen:!0,openChangeReason:null})});m.useSyncedValues({modal:c}),r.useEffect(()=>{g||m.context.stickIfOpenTimeout.clear()},[m,g]),r.useImperativeHandle(e.actionsRef,()=>({unmount:b,close:()=>m.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.imperativeAction))}),[b,m]);let x=g||h;return(0,t.jsxs)(G.Provider,{value:m,children:[d&&(0,t.jsx)(en.PopupHandleAttachment,{handle:d,store:m}),x&&(0,t.jsx)(ef,{store:m,modal:c}),"function"==typeof o?o({payload:v}):o]})});function ef({store:e,modal:t}){let n=e.useState("floatingRootContext"),r=(0,$.useDismiss)(n,{outsidePressEvent:{mouse:"trap-focus"===t?"sloppy":"intentional",touch:"sloppy"}}),i=r.reference,o=r.floating;return(0,en.usePopupInteractionProps)(e,{activeTriggerProps:i,inactiveTriggerProps:i,popupProps:o}),null}e.s(["PopoverRoot",0,function(e){return Y(!0)?(0,t.jsx)(ed,{props:e}):(0,t.jsx)(U.FloatingTree,{children:(0,t.jsx)(ed,{props:e})})}],49237);var ep=e.i(40886),em=e.i(79938),eg=e.i(52245),eh=e.i(29315),ev=e.i(84446),eb=e.i(58408);let ex=.1*.1;function ey(e,t,n,r,i,o){return r>=t!=o>=t&&e<=(i-n)*(t-r)/(o-r)+n}function eS(e,t,n,r,i,o,s,a,l,u){let c=!1;return ey(e,t,n,r,i,o)&&(c=!c),ey(e,t,i,o,s,a)&&(c=!c),ey(e,t,s,a,l,u)&&(c=!c),ey(e,t,l,u,n,r)&&(c=!c),c}function eC(e,t,n,r,i,o){let s=Math.min(n,i),a=Math.max(n,i),l=Math.min(r,o),u=Math.max(r,o);return e>=s&&e<=a&&t>=l&&t<=u}function eE(e={}){let{blockPointerEvents:t=!1}=e,n=new J.Timeout,r=({x:e,y:t,placement:r,elements:i,onClose:o,nodeId:s,tree:a})=>{let l=r?.split("-")[0],u=!1,c=null,d=null,f="u">typeof performance?performance.now():0;return function(r){n.clear();let p=i.domReference,m=i.floating;if(!p||!m||null==l||null==e||null==t)return;let{clientX:g,clientY:h}=r,v=(0,ev.getTarget)(r),b="mouseleave"===r.type,x=(0,ev.contains)(m,v),y=(0,ev.contains)(p,v);if(x&&(u=!0,!b))return;if(y&&(u=!1,!b)){u=!0;return}if(b&&(0,eh.isElement)(r.relatedTarget)&&(0,ev.contains)(m,r.relatedTarget))return;function S(){return!!(a&&(0,eb.getNodeChildren)(a.nodesRef.current,s).length>0)}function C(){S()||(n.clear(),o())}if(S())return;let E=p.getBoundingClientRect(),R=m.getBoundingClientRect(),w=e>R.right-R.width/2,I=t>R.bottom-R.height/2,T=R.width>E.width,k=R.height>E.height,O=(T?E:R).left,M=(T?E:R).right,A=(k?E:R).top,P=(k?E:R).bottom;if("top"===l&&t>=E.bottom-1||"bottom"===l&&t<=E.top+1||"left"===l&&e>=E.right-1||"right"===l&&e<=E.left+1)return void C();let N=!1;switch(l){case"top":N=eC(g,h,O,E.top+1,M,R.bottom-1);break;case"bottom":N=eC(g,h,O,R.top+1,M,E.bottom-1);break;case"left":N=eC(g,h,R.right-1,P,E.left+1,A);break;case"right":N=eC(g,h,E.right-1,P,R.left+1,A)}if(N)return;if(u&&(!(g>=E.x)||!(g<=E.x+E.width)||!(h>=E.y)||!(h<=E.y+E.height))||!b&&function(e,t){let n=performance.now(),r=n-f;if(null===c||null===d||0===r)return c=e,d=t,f=n,!1;let i=e-c,o=t-d;return c=e,d=t,f=n,i*i+o*o<r*r*ex}(g,h))return void C();let j=!1;switch(l){case"top":{let n=T?.25:2,r=t+.5+1,i=w||T?R.bottom-.5:R.top,o=w?T?R.bottom-.5:R.top:R.bottom-.5;j=eS(g,h,T||w?e+n:e-n,r,T?e-n:w?e+n:e-n,r,R.left,i,R.right,o);break}case"bottom":{let n=T?.25:2,r=t-.5,i=w||T?R.top+.5:R.bottom,o=w?T?R.top+.5:R.bottom:R.top+.5;j=eS(g,h,T||w?e+n:e-n,r,T?e-n:w?e+n:e-n,r,R.left,i,R.right,o);break}case"left":{let n=k?.25:2,r=e+.5+1,i=I||k?R.right-.5:R.left,o=I?k?R.right-.5:R.left:R.right-.5;j=eS(g,h,i,R.top,o,R.bottom,r,k||I?t+n:t-n,r,k?t-n:I?t+n:t-n);break}case"right":{let n=k?.25:2,r=e-.5,i=I||k?R.left+.5:R.right,o=I?k?R.left+.5:R.right:R.left+.5;j=eS(g,h,r,k||I?t+n:t-n,r,k?t-n:I?t+n:t-n,i,R.top,o,R.bottom)}}j?u||n.start(40,C):C()}};return r.__options={...e,blockPointerEvents:t},r}e.s(["safePolygon",0,eE],50316);var eR=e.i(85689),ew=e.i(74735),eI=e.i(65420),eT=e.i(8868),ek=e.i(67865),eO=e.i(46265),eM=e.i(57940),eA=e.i(26300),eP=e.i(88940),eN=e.i(96296);class ej{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new J.Timeout,this.restTimeout=new J.Timeout,this.handleCloseOptions=void 0}static create(){return new ej}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose}let eL=new WeakMap;function eD(e){if(!e.performedPointerEventsMutation)return;let t=e.pointerEventsScopeElement;t&&eL.get(t)===e&&(e.pointerEventsScopeElement?.style.removeProperty("pointer-events"),e.pointerEventsReferenceElement?.style.removeProperty("pointer-events"),e.pointerEventsFloatingElement?.style.removeProperty("pointer-events"),eL.delete(t)),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null}function ez(e,t){let{scopeElement:n,referenceElement:r,floatingElement:i}=t,o=eL.get(n);o&&o!==e&&eD(o),eD(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=n,e.pointerEventsReferenceElement=r,e.pointerEventsFloatingElement=i,eL.set(n,e),n.style.pointerEvents="none",r.style.pointerEvents="auto",i.style.pointerEvents="auto"}function eF(e){let t=e.context.dataRef.current,n=(0,eP.useRefWithInit)(()=>t.hoverInteractionState??ej.create()).current;return t.hoverInteractionState||(t.hoverInteractionState=n),(0,eA.useOnMount)(t.hoverInteractionState.disposeEffect),t.hoverInteractionState}function eH(e,t,n){let r=null==n||(0,eM.isMouseLikePointerType)(n)?"function"==typeof e?e():e:0;return"number"==typeof r?r:r?.[t]}function eV(e){return"function"==typeof e?e():e}function eq(e,t){return t||"click"===e||"mousedown"===e}function e_(e){return e?.includes("mouse")&&"mousedown"!==e}e.s(["applySafePolygonPointerEventsMutation",0,ez,"clearSafePolygonPointerEventsMutation",0,eD,"useHoverInteractionSharedState",0,eF],73752),e.s(["getDelay",0,eH,"getRestMs",0,eV,"isClickLikeOpenEvent",0,eq,"isHoverOpenEvent",0,e_],44681);var eB=eN;let eW={current:null};function e$(e,t={}){let{enabled:n=!0,delay:i=0,handleClose:o=null,mouseOnly:s=!1,restMs:a=0,move:l=!0,triggerElementRef:u=eW,externalTree:c,isActiveTrigger:d=!0,getHandleCloseContext:f,isClosing:p,shouldOpen:m,guardStaleOpen:g=!1}=t,h="rootStore"in e?e.rootStore:e,{dataRef:v,events:b}=h.context,x=(0,U.useFloatingTree)(c),y=eF(h),S=r.useRef(!1),C=(0,eO.useValueAsRef)(o),E=(0,eO.useValueAsRef)(i),R=(0,eO.useValueAsRef)(a),w=(0,eO.useValueAsRef)(n),I=(0,eO.useValueAsRef)(m),T=(0,eO.useValueAsRef)(p),k=(0,ek.useStableCallback)(()=>eq(v.current.openEvent?.type,y.interactedInside)),O=(0,ek.useStableCallback)(()=>I.current?.()!==!1),M=(0,ek.useStableCallback)((e,t,n)=>{let r=h.context.triggerElements;return r.hasElement(t)?!e||!(0,ev.contains)(e,t):!!(0,eh.isElement)(n)&&r.hasMatchingElement(e=>(0,ev.contains)(e,n))&&(!e||!(0,ev.contains)(e,n))}),A=(0,ek.useStableCallback)(()=>{y.handler&&((0,eT.ownerDocument)(h.select("domReferenceElement")).removeEventListener("mousemove",y.handler),y.handler=void 0)}),P=(0,ek.useStableCallback)(()=>{eD(y)});return d&&(y.handleCloseOptions=o?.__options),r.useEffect(()=>A,[A]),r.useEffect(()=>{if(n)return b.on("openchange",e),()=>{b.off("openchange",e)};function e(e){e.open?S.current=!1:(S.current=e.reason===ee.REASONS.triggerHover,A(),y.openChangeTimeout.clear(),y.restTimeout.clear(),y.blockMouseMove=!0,y.restTimeoutPending=!1)}},[n,b,y,A]),r.useEffect(()=>{if(!n)return;function e(t,n=!0){let r=eH(E.current,"close",y.pointerType);r?y.openChangeTimeout.start(r,()=>{h.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,t)),x?.events.emit("floating.closed",t)}):n&&(y.openChangeTimeout.clear(),h.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,t)),x?.events.emit("floating.closed",t))}let t=u.current??(d?h.select("domReferenceElement"):null);if(!(0,eh.isElement)(t))return;function r(e){if(y.openChangeTimeout.clear(),y.blockMouseMove=!1,s&&!(0,eM.isMouseLikePointerType)(y.pointerType))return;let t=eV(R.current),n=eH(E.current,"open",y.pointerType),r=(0,ev.getTarget)(e),i=e.currentTarget??null,o=h.select("domReferenceElement"),a=i;if((0,eh.isElement)(r)&&!h.context.triggerElements.hasElement(r)){for(let e of h.context.triggerElements.elements())if((0,ev.contains)(e,r)){a=e;break}}(0,eh.isElement)(i)&&(0,eh.isElement)(o)&&!h.context.triggerElements.hasElement(i)&&(0,ev.contains)(i,o)&&(a=o);let l=null!=a&&M(o,a,r),u=h.select("open"),c=T.current?.()??"ending"===h.select("transitionStatus"),d=!u&&c&&S.current,f=!l&&(0,eh.isElement)(a)&&(0,eh.isElement)(o)&&(0,ev.contains)(o,a)&&d,p=t>0&&!n,m=!u||l;if(l&&(u||d)||f){O()&&h.setOpen(!0,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,e,a));return}!p&&(n?y.openChangeTimeout.start(n,()=>{m&&O()&&h.setOpen(!0,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,e,a))}):m&&O()&&h.setOpen(!0,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,e,a)))}function i(t){if(k())return void P();A();let n=h.select("domReferenceElement"),r=(0,eT.ownerDocument)(n);y.restTimeout.clear(),y.restTimeoutPending=!1;let i=v.current.floatingContext??f?.();if(!(0,eB.isTargetInsideEnabledTrigger)(t.relatedTarget,h.context.triggerElements)){if(C.current&&i){h.select("open")||y.openChangeTimeout.clear();let n=u.current;y.handler=C.current({...i,tree:x,x:t.clientX,y:t.clientY,onClose(){P(),A(),w.current&&!k()&&n===h.select("domReferenceElement")&&e(t,!0)}}),r.addEventListener("mousemove",y.handler),y.handler(t);return}"touch"===y.pointerType&&(0,ev.contains)(h.select("floatingElement"),t.relatedTarget)||e(t)}}let o=g?(0,ew.addEventListener)(t,"mouseout",function(e){(0,ev.contains)(t,e.relatedTarget)||(y.openChangeTimeout.clear(),y.restTimeout.clear(),y.restTimeoutPending=!1)}):void 0;return l?(0,eI.mergeCleanups)((0,ew.addEventListener)(t,"mousemove",r,{once:!0}),(0,ew.addEventListener)(t,"mouseenter",r),(0,ew.addEventListener)(t,"mouseleave",i),o):(0,eI.mergeCleanups)((0,ew.addEventListener)(t,"mouseenter",r),(0,ew.addEventListener)(t,"mouseleave",i),o)},[A,P,v,E,h,n,C,y,d,M,k,s,l,R,u,x,w,f,T,O,g]),r.useMemo(()=>{if(n)return{onPointerDown:e,onPointerEnter:e,onMouseMove(e){let{nativeEvent:t}=e,n=e.currentTarget,r=h.select("domReferenceElement"),i=h.select("open"),o=M(r,n,e.target);if(s&&!(0,eM.isMouseLikePointerType)(y.pointerType))return;if(i&&o&&y.handleCloseOptions?.blockPointerEvents){let e=h.select("floatingElement");if(e){let t=y.handleCloseOptions?.getScope?.()??n.ownerDocument.body;ez(y,{scopeElement:t,referenceElement:n,floatingElement:e})}}let a=eV(R.current);function l(){if(y.restTimeoutPending=!1,k())return;let e=h.select("open");!y.blockMouseMove&&(!e||o)&&O()&&h.setOpen(!0,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,t,n))}(!i||o)&&0!==a&&(!o&&y.restTimeoutPending&&e.movementX**2+e.movementY**2<2||(y.restTimeout.clear(),"touch"===y.pointerType?Q.flushSync(()=>{l()}):o&&i?l():(y.restTimeoutPending=!0,y.restTimeout.start(a,l))))}};function e(e){y.pointerType=e.pointerType}},[n,y,k,M,s,h,R,O])}e.s(["useHoverReferenceInteraction",0,e$],72135);var eU=e.i(88015),eK=e.i(52535),eG=e.i(59636),eY=e.i(83976);function eQ(e,t){let n=r.useRef(null);return{preFocusGuardRef:n,handlePreFocusGuardFocus:function(t){Q.flushSync(()=>{e.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.focusOut,t.nativeEvent,t.currentTarget))});let r=(0,eY.getTabbableBeforeElement)(n.current);r?.focus()},handleFocusTargetFocus:function(n){let r=e.select("positionerElement");if(r&&(0,eY.isOutsideEvent)(n,r))e.context.beforeContentFocusGuardRef.current?.focus();else{Q.flushSync(()=>{e.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.focusOut,n.nativeEvent,n.currentTarget))});let i=(0,eY.getTabbableAfterElement)(e.context.triggerFocusTargetRef.current||t.current);for(;null!==i&&(0,ev.contains)(r,i);){let e=i;if((i=(0,eY.getNextTabbable)(i))===e)break}i?.focus()}}}}e.s(["useTriggerFocusGuards",0,eQ],46570);var eX=e.i(32199);let eJ=(0,W.fastComponentRef)(function(e,n){let{render:i,className:o,style:s,disabled:a=!1,nativeButton:l=!0,handle:u,payload:c,openOnHover:d=!1,delay:f=300,closeDelay:p=0,id:m,...g}=e,h=Y(!0),v=(0,eG.usePopupHandleStore)(u)??h;if(!v)throw Error((0,K.default)(74));let b=(0,eU.useBaseUiId)(m),x=v.useState("isTriggerActive",b),y=v.useState("floatingRootContext"),S=v.useState("isOpenedByTrigger",b),C=v.useState("triggerPopupId",b),E=r.useRef(null),{registerTrigger:R,isMountedByThisTrigger:w}=(0,en.useTriggerDataForwarding)(b,E,v,{payload:c,disabled:a,openOnHover:d,closeDelay:p}),I=v.useState("openChangeReason"),T=v.useState("stickIfOpen"),k=v.useState("openMethod"),O=v.useState("focusManagerModal"),M=e$(y,{enabled:!a&&d&&("touch"!==k||I!==ee.REASONS.triggerPress),mouseOnly:!0,move:!1,handleClose:eE(),restMs:f,delay:{close:p},triggerElementRef:E,isActiveTrigger:x,isClosing:()=>"ending"===v.select("transitionStatus")}),A=(0,eR.useClick)(y,{stickIfOpen:T}),P=(0,eX.useOpenMethodTriggerProps)(()=>v.select("open"),e=>{v.set("openMethod",e)}),N=v.useState("triggerProps",w),{getButtonProps:j,buttonRef:L}=(0,ep.useButton)({disabled:a,native:l}),{preFocusGuardRef:D,handlePreFocusGuardFocus:z,handleFocusTargetFocus:F}=eQ(v,E),H=(0,eg.useRenderElement)("button",e,{state:{disabled:a,open:S},ref:[L,n,R,E],props:[A.reference,M,N,P,{[eo.CLICK_TRIGGER_IDENTIFIER]:"",id:b,"aria-haspopup":"dialog","aria-expanded":S,"aria-controls":C},g,j],stateAttributesMapping:{open:e=>e&&I===ee.REASONS.triggerPress?em.pressableTriggerOpenStateMapping.open(e):em.triggerOpenStateMapping.open(e)}}),V=(0,t.jsx)(r.Fragment,{children:H},b);return w&&!O?(0,t.jsxs)(r.Fragment,{children:[(0,t.jsx)(eK.FocusGuard,{ref:D,onFocus:z}),V,(0,t.jsx)(eK.FocusGuard,{ref:v.context.triggerFocusTargetRef,onFocus:F})]}):V});e.s(["PopoverTrigger",0,eJ],41225);var eZ=e.i(26674);let e0=r.createContext(void 0),e1=r.forwardRef(function(e,n){let{keepMounted:r=!1,...i}=e;return Y().useState("mounted")||r?(0,t.jsx)(e0.Provider,{value:r,children:(0,t.jsx)(eZ.FloatingPortal,{ref:n,...i})}):null});e.s(["PopoverPortal",0,e1],21125);var e4=e.i(44394),e2=e.i(46376);let e5=r.createContext(void 0);e.s(["PopoverPositionerContext",0,e5,"usePopoverPositionerContext",0,function(){let e=r.useContext(e5);if(!e)throw Error((0,K.default)(46));return e}],73336);var e6=e.i(23706),e7=e.i(426),e3=e.i(22640),e8=e.i(89579),e9=e.i(33383);let te=r.forwardRef(function(e,n){let{render:i,className:o,style:s,anchor:a,positionMethod:l,side:u,align:c,sideOffset:d,alignOffset:f,collisionBoundary:p="clipping-ancestors",collisionPadding:m,arrowPadding:g,sticky:h,disableAnchorTracking:v=!1,collisionAvoidance:b=eo.POPUP_COLLISION_AVOIDANCE,...x}=e,y=Y(),S=function(){let e=r.useContext(e0);if(void 0===e)throw Error((0,K.default)(45));return e}(),C=(0,U.useFloatingNodeId)(),E=y.useState("floatingRootContext"),R=y.useState("mounted"),w=y.useState("open"),I=y.useState("openChangeReason"),T=y.useState("activeTriggerElement"),k=y.useState("modal"),O=y.useState("openMethod"),M=y.useState("positionerElement"),A=y.useState("instantType"),P=y.useState("transitionStatus"),N=y.useState("adaptiveOrigin"),j=r.useRef(null),L=(0,e3.useAnimationsFinished)(M),D=(0,e6.useAnchorPositioning)({anchor:a,floatingRootContext:E,positionMethod:l,mounted:R,side:u,sideOffset:d,align:c,alignOffset:f,arrowPadding:g,collisionBoundary:p,collisionPadding:m,sticky:h,disableAnchorTracking:v,keepMounted:S,nodeId:C,collisionAvoidance:b,adaptiveOrigin:N}),z=E.useState("domReferenceElement");(0,e2.useIsoLayoutEffect)(()=>{let e=j.current;if(z&&(j.current=z),e&&z&&z!==e){y.set("instantType",void 0);let e=new AbortController;return L(()=>{y.set("instantType","trigger-change")},e.signal),()=>{e.abort()}}},[z,L,y]);let F=!0===k&&I!==ee.REASONS.triggerHover;(0,e9.useAnchoredPopupScrollLock)(w&&F,"touch"===O,M,T);let H=y.useStateSetter("positionerElement"),V={open:w,side:D.side,align:D.align,anchorHidden:D.anchorHidden,instant:A},q=(0,e8.usePositioner)(e,V,{styles:D.positionerStyles,transitionStatus:P,props:x,refs:[n,H],hidden:!R,inert:!w});return(0,t.jsxs)(e5.Provider,{value:D,children:[R&&F&&(0,t.jsx)(e7.InternalBackdrop,{inert:(0,e4.inertValue)(!w),cutout:T}),(0,t.jsx)(U.FloatingNode,{id:C,children:q})]})});e.s(["PopoverPositioner",0,te],63550);var eB=eN;e.s(["useHoverFloatingInteraction",0,function(e,t={}){let{enabled:n=!0,closeDelay:i=0,nodeId:o}=t,s="rootStore"in e?e.rootStore:e,a=s.useState("open"),l=s.useState("floatingElement"),u=s.useState("domReferenceElement"),{dataRef:c}=s.context,d=(0,U.useFloatingTree)(),f=(0,U.useFloatingParentNodeId)(),p=eF(s),m=(0,J.useTimeout)(),g=(0,ek.useStableCallback)(()=>eq(c.current.openEvent?.type,p.interactedInside)),h=(0,ek.useStableCallback)(()=>e_(c.current.openEvent?.type)),v=(0,ek.useStableCallback)(()=>{eD(p)});(0,e2.useIsoLayoutEffect)(()=>{a||(p.pointerType=void 0,p.restTimeoutPending=!1,p.interactedInside=!1,v())},[a,p,v]),r.useEffect(()=>v,[v]),(0,e2.useIsoLayoutEffect)(()=>{if(n&&a&&p.handleCloseOptions?.blockPointerEvents&&h()&&(0,eh.isElement)(u)&&l){let e=(0,eT.ownerDocument)(l),t=d?.nodesRef.current.find(e=>e.id===f)?.context?.elements.floating;t&&(t.style.pointerEvents="");let n=p.pointerEventsScopeElement!==l?p.pointerEventsScopeElement:null,r=t!==l?t:null,i=p.handleCloseOptions?.getScope?.()??n??r??u.closest("[data-rootownerid]")??e.body;return ez(p,{scopeElement:i,referenceElement:u,floatingElement:l}),()=>{v()}}},[n,a,u,l,p,h,d,f,v]),r.useEffect(()=>{if(n)return(0,eI.mergeCleanups)(l&&(0,ew.addEventListener)(l,"mouseenter",function(){p.openChangeTimeout.clear(),m.clear(),d?.events.off("floating.closed",t),v()}),l&&(0,ew.addEventListener)(l,"mouseleave",function(n){if(e()&&d)return void d.events.on("floating.closed",t);if((0,eB.isTargetInsideEnabledTrigger)(n.relatedTarget,s.context.triggerElements))return;let r=c.current.floatingContext?.nodeId??o,a=n.relatedTarget;if(!(d&&r&&(0,eh.isElement)(a)&&(0,eb.getNodeChildren)(d.nodesRef.current,r,!1).some(e=>(0,ev.contains)(e.context?.elements.floating,a)))){let e,t;if(p.handler)return void p.handler(n);v(),h()&&!g()&&(e=eH(i,"close",p.pointerType),t=()=>{s.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,n)),d?.events.emit("floating.closed",n)},e?p.openChangeTimeout.start(e,t):(p.openChangeTimeout.clear(),t()))}}),l&&(0,ew.addEventListener)(l,"pointerdown",function(e){let t=(0,ev.getTarget)(e);if(!(0,eN.isInteractiveElement)(t)){p.interactedInside=!1;return}p.interactedInside=t?.closest("[aria-haspopup]")!=null},!0),()=>{d?.events.off("floating.closed",t)});function e(){return!!(d&&f&&(0,eb.getNodeChildren)(d.nodesRef.current,f).length>0)}function t(n){!d||!f||e()||m.start(0,()=>{d.events.off("floating.closed",t),s.setOpen(!1,(0,ec.createChangeEventDetails)(ee.REASONS.triggerHover,n)),d.events.emit("floating.closed",n)})}},[n,l,s,c,i,o,h,g,v,p,d,f,m])}],31157)},95475,18390,6734,63676,2767,e=>{"use strict";var t=e.i(43476),n=e.i(77155),r=e.i(15905);e.i(58421);var i=e.i(49237),o=e.i(41225),s=e.i(21125),a=e.i(63550),l=e.i(92235),u=e.i(10913),c=e.i(64493),d=e.i(69153),f=e.i(40370),p=e.i(89244),m=e.i(71645),g=e.i(22646),h=e.i(73336),v=e.i(52245),b=e.i(74080),x=e.i(44394),y=e.i(8445),S=e.i(94258),C=e.i(46376),E=e.i(67865),R=e.i(8868),w=e.i(22640),I=e.i(56789),T=e.i(73364);let k="--popup-width",O="--popup-height";var M=e.i(67387);function A(e,t,n){let r=e.style.getPropertyValue(t);return e.style.setProperty(t,n),()=>{e.style.setProperty(t,r)}}function P(e,t){let n=[];for(let[r,i]of Object.entries(t))n.push(A(e,r,i));return n.length?()=>{n.forEach(e=>e())}:I.NOOP}function N(e,t){let n="auto"===t?"auto":`${t.width}px`,r="auto"===t?"auto":`${t.height}px`;e.style.setProperty(k,n),e.style.setProperty(O,r)}function j(e,t){let n="max-content"===t?"max-content":`${t.width}px`,r="max-content"===t?"max-content":`${t.height}px`;e.style.setProperty(M.positionerWidth,n),e.style.setProperty(M.positionerHeight,r)}var L=e.i(72855),D=e.i(33848),z=e.i(43084),F=e.i(9091);let H={name:"adaptiveOrigin",async fn(e){let{x:t,y:n,rects:{floating:r},elements:{floating:i},platform:o,strategy:s,placement:a}=e,l=(0,D.ownerWindow)(i),u=l.getComputedStyle(i);if("0s"===u.transitionDuration||""===u.transitionDuration)return{x:t,y:n,data:F.DEFAULT_SIDES};let c=await o.getOffsetParent?.(i),d={width:0,height:0};if("fixed"===s&&l?.visualViewport)d={width:l.visualViewport.width,height:l.visualViewport.height};else if(c===l){let e=(0,R.ownerDocument)(i);d={width:e.documentElement.clientWidth,height:e.documentElement.clientHeight}}else await o.isElement?.(c)&&(d=await o.getDimensions(c));let f=(0,z.getSide)(a),p=t,m=n;return"left"===f&&(p=d.width-(t+r.width)),"top"===f&&(m=d.height-(n+r.height)),{x:p,y:m,data:{sideX:"left"===f?"right":F.DEFAULT_SIDES.sideX,sideY:"top"===f?"bottom":F.DEFAULT_SIDES.sideY}}}},V={activationDirection:e=>e?{"data-activation-direction":e}:null};function q(e){let n,{store:r,side:i,children:o}=e,s=(0,L.useDirection)(),a=r.useState("activeTriggerElement"),l=r.useState("activeTriggerId"),u=r.useState("open"),c=r.useState("payload"),d=r.useState("mounted"),f=r.useState("popupElement"),p=r.useState("positionerElement"),g=(0,S.usePreviousValue)(u?a:null),h=function(e,t){let[n,r]=m.useState(0),i=m.useRef(e),o=m.useRef(t),s=m.useRef(!1);return(0,C.useIsoLayoutEffect)(()=>{let n=i.current,a=t!==o.current;e!==n?(r(e=>e+1),s.current=!a):s.current&&a&&(r(e=>e+1),s.current=!1),i.current=e,o.current=t},[e,t]),`${e??"current"}-${n}`}(l,c),v=m.useRef(null),[D,z]=m.useState(null),[F,V]=m.useState(null),q=m.useRef(null),_=m.useRef(null),B=(0,w.useAnimationsFinished)(q,!0),W=(0,y.useAnimationFrame)(),$=m.useRef(null),[U,K]=m.useState(null),[G,Y]=m.useState(!1);(0,C.useIsoLayoutEffect)(()=>(r.set("adaptiveOrigin",H),()=>{r.set("adaptiveOrigin",void 0)}),[r]);let Q=(0,E.useStableCallback)(()=>{q.current?.style.setProperty("animation","none"),q.current?.style.setProperty("transition","none"),_.current?.style.setProperty("display","none")}),X=(0,E.useStableCallback)(e=>{q.current?.style.removeProperty("animation"),q.current?.style.removeProperty("transition"),_.current?.style.removeProperty("display"),e&&K(e)}),J=(0,E.useStableCallback)(()=>{$.current?.abort();let e=new AbortController;$.current=e,B(()=>{z(null),K(null),v.current=null},e.signal)}),Z=m.useRef(null);(0,C.useIsoLayoutEffect)(()=>{u&&d||(Z.current=null)},[u,d]),(0,C.useIsoLayoutEffect)(()=>{var e,t;let n,r,i,o;a&&g&&a!==g&&Z.current!==a&&v.current&&(z(v.current),Y(!0),V((e=g,t=a,n=e.getBoundingClientRect(),r=t.getBoundingClientRect(),i={x:n.left+n.width/2,y:n.top+n.height/2},{horizontal:(o={x:r.left+r.width/2,y:r.top+r.height/2}).x-i.x,vertical:o.y-i.y})),Z.current=a)},[a,g]),(0,C.useIsoLayoutEffect)(()=>{null!=D&&($.current?.abort(),Y(!0),W.request(()=>{b.flushSync(()=>{Y(!1)}),J()}))},[h,D,J,W]),(0,C.useIsoLayoutEffect)(()=>{let e=q.current;if(!e)return;let t=(0,R.ownerDocument)(e).createElement("div");for(let n of Array.from(e.childNodes))t.appendChild(n.cloneNode(!0));v.current=t});let ee=null!=D;return n=ee?(0,t.jsxs)(m.Fragment,{children:[(0,t.jsx)("div",{"data-previous":!0,inert:(0,x.inertValue)(!0),ref:_,style:{...U?{[k]:`${U.width}px`,[O]:`${U.height}px`}:null,position:"absolute"},"data-ending-style":G?void 0:""},"previous"),(0,t.jsx)("div",{"data-current":!0,ref:q,"data-starting-style":G?"":void 0,children:o},h)]}):(0,t.jsx)("div",{"data-current":!0,ref:q,children:o},h),(0,C.useIsoLayoutEffect)(()=>{let e=_.current;e&&D&&e.replaceChildren(...Array.from(D.childNodes))},[D]),!function(e){let{popupElement:t,positionerElement:n,content:r,mounted:i,onMeasureLayout:o,onMeasureLayoutComplete:s,side:a,direction:l}=e,u=(0,w.useAnimationsFinished)(t,!0),c=(0,y.useAnimationFrame)(),d=m.useRef(null),f=m.useRef(!0),p=m.useRef(I.NOOP),g=(0,E.useStableCallback)(o),h=(0,E.useStableCallback)(s),v=m.useMemo(()=>{var e,t;let n,r;return e=a,t=l,n="top"===e,r="left"===e||e===("rtl"===t?"inline-end":"inline-start"),n||r?{position:"absolute",[n?"bottom":"top"]:"0",[r?"right":"left"]:"0"}:I.EMPTY_OBJECT},[a,l]);(0,C.useIsoLayoutEffect)(()=>{if(!i){p.current=I.NOOP,f.current=!0,d.current=null;return}if(!t||!n)return;p.current=P(t,v),N(t,"auto");let e=A(t,"position","static"),r=A(t,"transform","none"),o=A(t,"scale","1"),s=P(n,{[M.availableWidth]:"max-content",[M.availableHeight]:"max-content"});function a(){e(),r(),s(),o()}if(g?.(),f.current||null===d.current){j(n,"max-content");let e=(0,T.getCssDimensions)(t);return d.current=e,j(n,e),a(),h?.(null,e),f.current=!1,()=>{p.current(),p.current=I.NOOP}}j(n,"max-content");let l=d.current,m=(0,T.getCssDimensions)(t);d.current=m,N(t,l),a(),h?.(l,m),j(n,m);let b=new AbortController;return c.request(()=>{N(t,m),u(()=>{t.style.setProperty(k,"auto"),t.style.setProperty(O,"auto")},b.signal)}),()=>{b.abort(),c.cancel(),p.current(),p.current=I.NOOP}},[r,t,n,u,c,i,g,h,v])}({popupElement:f,positionerElement:p,mounted:d,content:c,onMeasureLayout:Q,onMeasureLayoutComplete:X,side:i,direction:s}),{children:n,state:{activationDirection:function(e){if(e)return`${function(e,t,n,r){return e>t?n:e<-t?r:""}(e.horizontal,5,"right","left")} ${function(e,t,n,r){return e>t?n:e<-t?r:""}(e.vertical,5,"down","up")}`}(F),transitioning:ee}}}e.s(["popupViewportStateMapping",0,V,"usePopupViewport",0,q],18390);let _=m.forwardRef(function(e,t){let{render:n,className:r,style:i,children:o,...s}=e,a=(0,g.usePopoverRootContext)(),{side:l}=(0,h.usePopoverPositionerContext)(),u=a.useState("instantType"),{children:c,state:d}=q({store:a,side:l,children:o}),f={activationDirection:d.activationDirection,transitioning:d.transitioning,instant:u};return(0,v.useRenderElement)("div",e,{state:f,ref:t,props:[s,{children:c}],stateAttributesMapping:V})});var B=e.i(94242),W=e.i(64170);class $ extends W.BasePopupHandle{constructor(){super((0,B.createNullPopoverStore)(),"Popover")}open(e){this.openByTrigger(e)}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}}e.s(["Arrow",()=>u.PopoverArrow,"Backdrop",()=>c.PopoverBackdrop,"Close",()=>p.PopoverClose,"Description",()=>f.PopoverDescription,"Handle",0,$,"Popup",()=>l.PopoverPopup,"Portal",()=>s.PopoverPortal,"Positioner",()=>a.PopoverPositioner,"Root",()=>i.PopoverRoot,"Title",()=>d.PopoverTitle,"Trigger",()=>o.PopoverTrigger,"Viewport",0,_,"createHandle",0,function(){return new $}],66914);var U=e.i(66914),U=U,K=e.i(90063);function G(e){return(0,t.jsx)(U.Root,{"data-slot":"popover",...e})}function Y({className:e,children:n,anchor:r,side:i="bottom",sideOffset:o=10,align:s="center",...a}){return(0,t.jsx)(U.Portal,{children:(0,t.jsx)(U.Positioner,{anchor:r,align:s,side:i,sideOffset:o,className:"isolate z-50",children:(0,t.jsxs)(U.Popup,{"data-slot":"popover-content",className:(0,K.classNames)("origin-(--transform-origin) rounded-xl border border-border bg-popover text-popover-foreground shadow-lg duration-(--duration-fast) outline-none data-open:animate-in data-open:fade-in-0 data-closed:animate-out data-closed:fade-out-0",e),...a,children:[(0,t.jsx)(U.Arrow,{className:"data-[side=bottom]:-top-1.5 data-[side=left]:-right-1.5 data-[side=right]:-left-1.5 data-[side=top]:-bottom-1.5",children:(0,t.jsx)("span",{"aria-hidden":!0,className:"block size-3 rotate-45 border-t border-l border-border bg-popover in-data-[side=left]:rotate-135 in-data-[side=right]:-rotate-45 in-data-[side=top]:-rotate-135"})}),n]})})})}let Q=U.Trigger,X=U.Title,J=U.Description;function Z({index:e,total:n,onBack:i,onNext:o,onSkip:s,onFinish:a,children:l}){let u=e===n-1;return(0,t.jsxs)("div",{className:"flex w-80 max-w-[calc(100vw-2rem)] flex-col gap-2 p-4",children:[(0,t.jsxs)("p",{className:"text-caption text-muted-foreground","data-testid":"tour-step-count",children:[e+1," of ",n]}),l,(0,t.jsxs)("div",{className:"mt-2 flex items-center gap-2",children:[u?null:(0,t.jsx)(r.Button,{size:"sm",variant:"ghost","data-testid":"tour-step-skip",onClick:s,children:"Skip"}),(0,t.jsx)("span",{className:"grow"}),0===e?null:(0,t.jsx)(r.Button,{size:"sm","data-testid":"tour-step-back",onClick:i,children:"Back"}),u?(0,t.jsx)(r.Button,{size:"sm",variant:"primary","data-testid":"tour-step-finish",onClick:a,children:"Finish"}):(0,t.jsx)(r.Button,{size:"sm",variant:"primary","data-testid":"tour-step-next",onClick:o,children:"Next"})]})]})}function ee(e){let{title:n,text:r,anchor:i}=e;return null===i?(0,t.jsx)("div",{role:"dialog","aria-labelledby":"tour-step-title","aria-describedby":"tour-step-text","data-testid":"tour-step","data-placement":"centred",className:"fixed top-1/2 left-1/2 z-50 -translate-1/2 rounded-xl border border-border bg-popover text-popover-foreground shadow-lg",children:(0,t.jsxs)(Z,{...e,children:[(0,t.jsx)("h2",{id:"tour-step-title",className:"text-body font-semibold text-foreground",children:n}),(0,t.jsx)("p",{id:"tour-step-text",className:"text-body text-muted-foreground",children:r})]})}):(0,t.jsx)(G,{open:!0,modal:!1,children:(0,t.jsx)(Y,{anchor:i,"data-testid":"tour-step","data-placement":"anchored",children:(0,t.jsxs)(Z,{...e,children:[(0,t.jsx)(X,{className:"text-body font-semibold text-foreground",children:n}),(0,t.jsx)(J,{className:"text-body text-muted-foreground",children:r})]})})})}e.s(["Popover",0,G,"PopoverContent",0,Y,"PopoverDescription",0,J,"PopoverTitle",0,X,"PopoverTrigger",0,Q],6734),e.s(["ConsoleGuide",0,function(){let{view:e,onBack:r,onNext:i,onSkip:o,onFinish:s}=(0,n.useConsoleGuide)(),a=(0,n.useGuideAnchor)(e?.step);return((0,n.useTourStarted)(e),e)?(0,t.jsx)(ee,{title:e.step.title,text:e.step.text,index:e.index,total:e.total,anchor:a,onBack:r,onNext:i,onSkip:o,onFinish:s}):null}],95475);var et=e.i(10818),en=e.i(14387);e.s(["X",()=>en.default],63676);var en=en;function er({notice:e,onDismiss:n,onSignOut:i}){return(0,t.jsxs)("div",{role:"status","data-testid":"notice","data-notice-id":e.id,className:"flex items-start gap-2 border-b border-border bg-muted px-8 py-2.5 max-sm:px-4",children:[(0,t.jsx)(et.Info,{"aria-hidden":!0,className:"mt-0.5 size-(--size-icon) shrink-0 text-muted-foreground"}),(0,t.jsxs)("div",{className:"flex min-w-0 grow flex-wrap items-baseline gap-x-3 gap-y-1",children:[(0,t.jsx)("p",{className:"text-meta text-foreground",children:e.text}),e.links.map(e=>!0===e.isSignOut?(0,t.jsx)("button",{type:"button","data-testid":"notice-link",className:"text-meta font-medium text-foreground underline underline-offset-2",onClick:()=>i?.(e),children:e.label},e.label):(0,t.jsx)("a",{href:e.url,"data-testid":"notice-link",className:"text-meta font-medium text-foreground underline underline-offset-2",children:e.label},e.label))]}),e.isDismissible&&n?(0,t.jsx)(r.Button,{variant:"ghost",size:"xs",isIconOnly:!0,"aria-label":"Dismiss","data-testid":"notice-dismiss",onClick:n,children:(0,t.jsx)(en.default,{"aria-hidden":!0})}):null]})}var ei=e.i(54616),eo=e.i(66027),es=e.i(12598),ea=e.i(18566),el=e.i(41880),eu=e.i(27702);e.s(["ConsoleNotices",0,function(){let e,n,r,i,o,s,{notices:a,onDismiss:l,onSignOut:u}=(e=(0,eu.useTRPC)(),n=(0,ea.useRouter)(),r=(0,es.useQueryClient)(),i=(0,eo.useQuery)(e.console.notices.queryOptions()),o=(0,ei.useMutation)(e.console.dismissNotice.mutationOptions({onSuccess:()=>r.invalidateQueries({queryKey:e.console.notices.queryKey()}),onError:()=>{(0,el.showToast)({title:"Couldn’t dismiss the notice",description:"The server did not answer. Try again.",tone:"error"})}})),s=(0,ei.useMutation)(e.console.signOut.mutationOptions({onError:()=>{(0,el.showToast)({title:"Couldn’t sign out",description:"The server did not answer. You are still signed in.",tone:"error"})}})),{notices:i.data??[],onDismiss:e=>{o.mutate({noticeId:e})},onSignOut:e=>{s.mutate(void 0,{onSuccess:()=>{r.clear();let t=e.url??"/sign-in";t.startsWith("/")?n.replace(t):window.location.assign(t)}})}});return 0===a.length?null:(0,t.jsx)("div",{"data-testid":"notices",children:a.map(e=>(0,t.jsx)(er,{notice:e,onDismiss:()=>{l(e.id)},onSignOut:u},e.id))})}],2767)},77880,24262,83140,e=>{"use strict";var t=e.i(43476),n=e.i(67927),r=e.i(66595),i=e.i(19759),o=e.i(22016),s=e.i(15905),a=e.i(36651),l=e.i(90063);let u={live:{label:"Live",dot:"bg-tone-ok-fg"},reconnecting:{label:"Reconnecting",dot:"bg-tone-waiting-fg"},offline:{label:"Offline",dot:"bg-tone-attention-fg"}};function c({state:e,className:n}){let{label:r,dot:i}=u[e];return(0,t.jsxs)("span",{"data-slot":"live-status","data-state":e,"aria-live":"polite",className:(0,l.classNames)("inline-flex items-center gap-1.5 text-meta text-muted-foreground",n),children:[(0,t.jsx)("span",{"aria-hidden":!0,className:(0,l.classNames)("size-2 shrink-0 rounded-full",i)}),r]})}e.s(["LiveStatus",0,c],24262),e.s(["Header",0,function({breadcrumb:e,parents:l=[],live:u,onCompose:d,onSearch:f}){return(0,t.jsxs)("header",{"data-slot":"header",className:"sticky top-0 z-30 hidden h-(--size-header) shrink-0 items-center justify-between gap-4 border-b border-border bg-background px-6 sm:flex",children:[(0,t.jsx)("nav",{"aria-label":"Breadcrumb","data-testid":"header-breadcrumb",className:"min-w-0 text-body",children:(0,t.jsxs)("ol",{className:"flex min-w-0 items-center gap-1.5",children:[l.map(e=>(0,t.jsxs)("li",{className:"flex shrink-0 items-center gap-1.5",children:[(0,t.jsx)(o.default,{href:e.href,className:"text-muted-foreground hover:text-foreground hover:underline",children:e.label}),(0,t.jsx)(n.ChevronRight,{"aria-hidden":!0,className:"size-3.5 text-muted-foreground"})]},e.href)),(0,t.jsx)("li",{"aria-current":"page",className:"truncate font-medium text-foreground",children:e})]})}),(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)(c,{state:u}),f?(0,t.jsxs)(s.Button,{size:"sm",icon:(0,t.jsx)(r.Search,{"aria-hidden":!0}),"data-testid":"header-search",className:"w-60 justify-start font-normal text-muted-foreground",onClick:f,children:[(0,t.jsx)("span",{className:"grow text-left",children:"Search ships or jump to"}),(0,t.jsx)(a.Kbd,{children:"⌘K"})]}):null,d?(0,t.jsx)(s.Button,{size:"sm",icon:(0,t.jsx)(i.SquarePen,{"aria-hidden":!0}),"data-testid":"header-compose",onClick:d,children:"Compose"}):null]})]})}],77880);var d=e.i(56420);let f={name:"code-xml",size:24,node:[["path",{d:"m18 16 4-4-4-4",key:"1inbqp"}],["path",{d:"m6 8-4 4 4 4",key:"15zrgr"}],["path",{d:"m14.5 4-5 16",key:"e7oirm"}]],aliases:["code-2"]};f.node;let p=(0,d.default)(f);e.s(["CodeXml",0,p],83140)},36779,57957,15034,e=>{"use strict";var t=e.i(43476),n=e.i(83140),r=e.i(44594),i=e.i(18964),o=e.i(66794),s=e.i(60011),a=e.i(49287),l=e.i(86875),u=e.i(66787),c=e.i(22016),d=e.i(94859),f=e.i(66390),p=e.i(31513),m=e.i(63707),g=e.i(8619),h=e.i(28276),v=e.i(91772),b=e.i(11568),x=e.i(67784),y=e.i(46513),S=e.i(96699),C=e.i(35965),E=e.i(71645),R=e.i(90063),w=e.i(18162),I=e.i(68404),T=e.i(15905),k=e.i(57334),O=e.i(75305),M=e.i(60592);let A="Your account",P="Take the tour",N={light:C.Sun,dark:S.Moon,system:y.Monitor};function j(e){return e?.kind==="viewer"?{name:"viewer",detail:"Read-only"}:{name:"Operator",detail:e?.email??" "}}function L(e){return e?.kind!=="viewer"}function D(e){return I.THEMES.some(t=>t===e)}function z({account:e,now:n}){let{name:r,detail:i}=j(e);return(0,t.jsxs)("div",{className:"flex flex-col gap-2 px-2.5 pt-2 pb-2.5",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2.5",children:[(0,t.jsx)(d.Avatar,{kind:"account",size:28,name:r}),(0,t.jsxs)("span",{className:"flex min-w-0 flex-col",children:[(0,t.jsx)("span",{className:"truncate text-body font-medium text-foreground",children:r}),(0,t.jsx)("span",{"data-testid":"account-detail",className:"truncate text-caption text-muted-foreground",children:e?.kind==="viewer"?"Sees the whole fleet, changes nothing":i})]})]}),(0,t.jsxs)("p",{"data-testid":"account-session",className:"flex items-start gap-1.5 text-caption text-muted-foreground",children:[(0,t.jsx)(v.LaptopMinimal,{"aria-hidden":!0,className:"mt-px size-(--size-icon-sm) shrink-0"}),e?(0,t.jsxs)("span",{children:["This session: ",(0,t.jsx)("span",{className:"font-medium text-foreground",children:(0,w.sessionSince)(e.session,n)})]}):(0,t.jsx)("span",{children:"This session"})]})]})}function F({isSigningOut:e}){return e?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(b.LoaderCircle,{"aria-hidden":!0,className:"animate-spin motion-reduce:animate-none"}),"Signing out"]}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(x.LogOut,{"aria-hidden":!0}),"Sign out"]})}function H({account:e,onThemeChange:n,onSignOut:r,isSigningOut:i,now:o,accountUrl:s,onTakeTour:a}){let{name:l,detail:u}=j(e),c=e?.kind==="operator"?e.theme:void 0;return(0,t.jsxs)(k.DropdownMenu,{children:[(0,t.jsxs)(k.DropdownMenuTrigger,{"data-testid":"account-menu","aria-label":`Account menu, ${l}${e?`, ${u}`:""}`,className:"flex w-full items-center gap-2.5 rounded-md p-1.5 text-left transition-colors duration-(--duration-fast) outline-none hover:bg-accent focus-visible:outline-2 focus-visible:outline-ring aria-expanded:bg-accent max-lg:justify-center",children:[(0,t.jsx)(d.Avatar,{kind:"account",size:28,name:l}),(0,t.jsxs)("span",{className:"flex min-w-0 grow flex-col max-lg:sr-only",children:[(0,t.jsx)("span",{className:"truncate text-body font-medium text-foreground",children:l}),(0,t.jsx)("span",{className:"truncate text-caption text-muted-foreground",children:u})]}),(0,t.jsx)(m.ChevronsUpDown,{"aria-hidden":!0,className:"size-(--size-icon) shrink-0 text-muted-foreground max-lg:hidden"})]}),(0,t.jsxs)(k.DropdownMenuContent,{side:"top",align:"start",className:"w-64",children:[(0,t.jsx)(z,{account:e,now:o}),void 0===s||e?.kind==="viewer"?null:(0,t.jsxs)(k.DropdownMenuItem,{"data-testid":"account-hosted",render:e=>(0,t.jsx)("a",{...e,href:s,children:e.children}),children:[(0,t.jsx)(g.CircleUserRound,{"aria-hidden":!0}),A]}),void 0===a?null:(0,t.jsxs)(k.DropdownMenuItem,{"data-testid":"account-take-tour",onClick:a,children:[(0,t.jsx)(h.Compass,{"aria-hidden":!0}),P]}),L(e)&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(k.DropdownMenuSeparator,{}),(0,t.jsxs)(k.DropdownMenuGroup,{children:[(0,t.jsx)(k.DropdownMenuLabel,{children:"Theme"}),(0,t.jsx)(k.DropdownMenuRadioGroup,{value:c,onValueChange:e=>{D(e)&&n(e)},children:I.THEMES.map(n=>{let r=N[n];return(0,t.jsxs)(k.DropdownMenuRadioItem,{value:n,disabled:void 0===e,closeOnClick:!1,"data-testid":`account-theme-${n}`,children:[(0,t.jsx)(r,{"aria-hidden":!0}),w.THEME_LABELS[n]]},n)})})]})]}),(0,t.jsx)(k.DropdownMenuSeparator,{}),(0,t.jsx)(k.DropdownMenuItem,{"data-testid":"account-sign-out",disabled:i,closeOnClick:!1,onClick:r,children:(0,t.jsx)(F,{isSigningOut:i})})]})]})}e.s(["AccountMenu",0,H,"AccountMenuSheet",0,function({account:e,onThemeChange:r,onSignOut:i,isSigningOut:s,now:a,accountUrl:l,onTakeTour:u,settingsHref:f}){let[m,v]=(0,E.useState)(!1),{name:b,detail:x}=j(e),y=e?.kind==="operator"?e.theme:void 0;return(0,t.jsxs)(O.Sheet,{open:m,onOpenChange:v,children:[(0,t.jsx)(O.SheetTrigger,{"data-testid":"account-menu","aria-label":`Account menu, ${b}${e?`, ${x}`:""}`,className:"inline-flex size-(--size-control-touch) shrink-0 items-center justify-center rounded-full outline-none focus-visible:outline-2 focus-visible:outline-ring",children:(0,t.jsx)(d.Avatar,{kind:"account",size:28,name:b})}),(0,t.jsxs)(O.SheetContent,{side:"bottom","data-testid":"account-sheet",className:"gap-3",children:[(0,t.jsx)(O.SheetTitle,{className:"sr-only",children:"Account"}),(0,t.jsx)(z,{account:e,now:a}),void 0===l||e?.kind==="viewer"?null:(0,t.jsxs)("a",{href:l,"data-testid":"account-hosted",className:"flex h-(--size-control-touch) items-center gap-2.5 border-t border-border pt-3 text-body-touch text-foreground outline-none focus-visible:outline-2 focus-visible:outline-ring [&_svg]:size-(--size-icon) [&_svg]:text-muted-foreground",children:[(0,t.jsx)(g.CircleUserRound,{"aria-hidden":!0}),A]}),void 0===u?null:(0,t.jsxs)("button",{type:"button","data-testid":"account-take-tour",onClick:()=>{v(!1),u()},className:"flex h-(--size-control-touch) items-center gap-2.5 border-t border-border pt-3 text-body-touch text-foreground outline-none focus-visible:outline-2 focus-visible:outline-ring [&_svg]:size-(--size-icon) [&_svg]:text-muted-foreground",children:[(0,t.jsx)(h.Compass,{"aria-hidden":!0}),P]}),void 0===f?null:(0,t.jsxs)(c.default,{href:f,"data-testid":"account-settings",onClick:()=>{v(!1)},className:"flex h-(--size-control-touch) items-center gap-2.5 border-t border-border pt-3 text-body-touch text-foreground outline-none focus-visible:outline-2 focus-visible:outline-ring [&_svg]:size-(--size-icon) [&_svg]:text-muted-foreground",children:[(0,t.jsx)(o.Settings,{"aria-hidden":!0}),"Settings"]}),L(e)&&(0,t.jsxs)("div",{className:"flex flex-col gap-1.5 border-t border-border pt-3",children:[(0,t.jsx)("p",{className:"text-caption text-muted-foreground",children:"Theme"}),(0,t.jsx)(M.Tabs,{value:y,onValueChange:e=>{D(e)&&r(e)},children:(0,t.jsx)(M.TabsList,{"aria-label":"Theme",className:"w-full",children:I.THEMES.map(n=>{let r=N[n];return(0,t.jsxs)(M.TabsTrigger,{value:n,disabled:void 0===e,"data-testid":`account-theme-${n}`,className:"grow",children:[(0,t.jsx)(r,{"aria-hidden":!0}),w.THEME_LABELS[n]]},n)})})})]}),(0,t.jsxs)("a",{href:p.SOURCE_URL,target:"_blank",rel:"noreferrer","data-testid":"account-source",className:"flex h-(--size-control-touch) items-center gap-2.5 border-t border-border pt-3 text-body-touch text-foreground outline-none focus-visible:outline-2 focus-visible:outline-ring [&_svg]:size-(--size-icon) [&_svg]:text-muted-foreground",children:[(0,t.jsx)(n.CodeXml,{"aria-hidden":!0}),"Source on GitHub",(0,t.jsx)("span",{className:"sr-only",children:" (opens in a new tab)"})]}),(0,t.jsx)("button",{type:"button","data-testid":"account-sign-out",disabled:s,onClick:i,className:(0,R.classNames)("flex h-(--size-control-touch) items-center gap-2.5 border-t border-border pt-3 text-body-touch text-foreground outline-none focus-visible:outline-2 focus-visible:outline-ring disabled:opacity-60 [&_svg]:size-(--size-icon) [&_svg]:text-muted-foreground"),children:(0,t.jsx)(F,{isSigningOut:s})}),(0,t.jsx)(O.SheetClose,{render:(0,t.jsx)(T.Button,{size:"touch",className:"w-full"}),children:"Cancel"})]})]})}],57957);let V="relative flex h-(--size-control) items-center gap-2.5 rounded-md px-2.5 text-body text-muted-foreground transition-colors duration-(--duration-fast) hover:bg-accent hover:text-foreground aria-[current=page]:bg-accent aria-[current=page]:font-medium aria-[current=page]:text-foreground max-lg:justify-center max-lg:px-0 [&_svg]:size-(--size-icon) [&_svg]:shrink-0";function q({href:e,label:n,icon:r,isActive:i,testId:o,count:s}){return(0,t.jsxs)(c.default,{href:e,"aria-current":i?"page":void 0,"data-testid":o,className:V,children:[r,(0,t.jsx)("span",{className:"grow max-lg:sr-only",children:n}),s]})}function _({count:e}){return void 0===e||0===e?null:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(f.Badge,{variant:"count","data-testid":"nav-inbox-count",className:"max-lg:sr-only",children:[e,(0,t.jsx)("span",{className:"sr-only",children:" open"})]}),(0,t.jsx)("span",{"aria-hidden":!0,className:"absolute top-1.5 right-4 size-1.5 rounded-full bg-primary lg:hidden"})]})}function B({count:e}){return void 0===e||0===e?null:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(f.Badge,{variant:"count-neutral","data-testid":"nav-needs-crew-count",className:"max-lg:sr-only",children:[e,(0,t.jsx)("span",{className:"sr-only",children:" need crew"})]}),(0,t.jsx)("span",{"aria-hidden":!0,className:"absolute top-1.5 right-4 size-1.5 rounded-full bg-muted-foreground lg:hidden"})]})}function W({count:e,testId:n="nav-attention-count"}){return void 0===e||0===e?null:(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(f.Badge,{variant:"count-attention","data-testid":n,className:"max-lg:sr-only",children:[e,(0,t.jsx)("span",{className:"sr-only",children:" need attention"})]}),(0,t.jsx)("span",{"aria-hidden":!0,className:"absolute top-1.5 right-4 size-1.5 rounded-full bg-tone-attention-fg lg:hidden"})]})}function $({href:e,label:n,icon:r,isActive:i,testId:o,count:s}){let a=s?.value!==void 0&&s.value>0;return(0,t.jsxs)(c.default,{href:e,"aria-current":i?"page":void 0,"data-testid":o,className:"flex grow flex-col items-center justify-center gap-1 text-micro text-muted-foreground outline-none focus-visible:outline-2 focus-visible:-outline-offset-2 focus-visible:outline-ring aria-[current=page]:font-medium aria-[current=page]:text-primary [&_svg]:size-(--size-icon-tab)",children:[(0,t.jsxs)("span",{className:"relative",children:[r,a?(0,t.jsxs)("span",{"data-testid":`${o}-count`,className:(0,R.classNames)("absolute -top-1.5 -right-2 flex h-4 min-w-4 items-center justify-center rounded-full px-1 text-micro font-semibold tabular-nums","primary"===s.tone?"bg-primary text-primary-foreground":"bg-destructive text-destructive-foreground"),children:[s.value,(0,t.jsxs)("span",{className:"sr-only",children:[" ",s.words]})]}):null]}),n]})}e.s(["Sidebar",0,function({active:e,inboxCount:c,attentionCount:f,needsCrewCount:m,hasSquadrons:g=!1,hasTrierarchs:h=!1,trierarchsCount:v,hasSettings:b=!1,...x}){return(0,t.jsxs)("aside",{"data-slot":"sidebar",className:"sticky top-0 hidden h-dvh w-(--size-rail) shrink-0 flex-col border-r border-border bg-sidebar text-sidebar-foreground sm:flex lg:w-(--size-sidebar)",children:[(0,t.jsxs)("div",{className:"flex h-(--size-header) items-center gap-2.5 px-4 max-lg:justify-center max-lg:px-0",children:[(0,t.jsx)(d.Avatar,{kind:"app",size:28}),(0,t.jsxs)("div",{className:"flex flex-col max-lg:sr-only",children:[(0,t.jsx)("span",{className:"text-body font-semibold text-foreground",children:"Aeolus"}),(0,t.jsx)("span",{className:"text-caption text-muted-foreground",children:"Operator console"})]})]}),(0,t.jsxs)("nav",{"aria-label":"Console",className:"flex grow flex-col gap-0.5 px-2.5 py-2",children:[(0,t.jsx)(q,{href:"/",label:"Fleet overview",icon:(0,t.jsx)(a.Ship,{"aria-hidden":!0}),isActive:"overview"===e,testId:"nav-overview"}),(0,t.jsx)(q,{href:"/needs-crew",label:"Needs crew",icon:(0,t.jsx)(i.ListChecks,{"aria-hidden":!0}),isActive:"needs-crew"===e,testId:"nav-needs-crew",count:(0,t.jsx)(B,{count:m})}),g&&(0,t.jsx)(q,{href:"/squadrons",label:"Squadrons",icon:(0,t.jsx)(s.Shapes,{"aria-hidden":!0}),isActive:"squadrons"===e,testId:"nav-squadrons"}),h&&(0,t.jsx)(q,{href:"/trierarchs",label:"Trierarchs",icon:(0,t.jsx)(l.ShipWheel,{"aria-hidden":!0}),isActive:"trierarchs"===e,testId:"nav-trierarchs",count:(0,t.jsx)(W,{count:v,testId:"nav-trierarchs-count"})}),(0,t.jsx)(q,{href:"/inbox",label:"Operator inbox",icon:(0,t.jsx)(r.Inbox,{"aria-hidden":!0}),isActive:"inbox"===e,testId:"nav-inbox",count:(0,t.jsx)(_,{count:c})}),(0,t.jsx)(q,{href:"/needs-attention",label:"Needs attention",icon:(0,t.jsx)(u.TriangleAlert,{"aria-hidden":!0}),isActive:"attention"===e,testId:"nav-attention",count:(0,t.jsx)(W,{count:f})})]}),(0,t.jsxs)("div",{className:"px-2.5 pb-2",children:[b&&(0,t.jsx)(q,{href:"/settings",label:"Settings",icon:(0,t.jsx)(o.Settings,{"aria-hidden":!0}),isActive:"settings"===e,testId:"nav-settings"}),(0,t.jsxs)("a",{href:p.SOURCE_URL,target:"_blank",rel:"noreferrer","data-testid":"nav-source",className:V,children:[(0,t.jsx)(n.CodeXml,{"aria-hidden":!0}),(0,t.jsx)("span",{className:"grow max-lg:sr-only",children:"Source on GitHub"}),(0,t.jsx)("span",{className:"sr-only",children:" (opens in a new tab)"})]})]}),(0,t.jsx)("div",{className:"border-t border-border p-2.5",children:(0,t.jsx)(H,{...x})})]})}],36779),e.s(["TabBar",0,function({active:e,inboxCount:n,attentionCount:i,hasSquadrons:o=!1,hasTrierarchs:c=!1,trierarchsCount:d}){return(0,t.jsxs)("nav",{"aria-label":"Console","data-slot":"tab-bar",className:"fixed inset-x-0 bottom-0 z-40 flex min-h-(--size-tabbar) border-t border-border bg-background pb-[env(safe-area-inset-bottom)] sm:hidden",children:[(0,t.jsx)($,{href:"/",label:"Fleet",icon:(0,t.jsx)(a.Ship,{"aria-hidden":!0}),isActive:"fleet"===e,testId:"tab-fleet"}),o&&(0,t.jsx)($,{href:"/squadrons",label:"Squadrons",icon:(0,t.jsx)(s.Shapes,{"aria-hidden":!0}),isActive:"squadrons"===e,testId:"tab-squadrons"}),c&&(0,t.jsx)($,{href:"/trierarchs",label:"Trierarchs",icon:(0,t.jsx)(l.ShipWheel,{"aria-hidden":!0}),isActive:"trierarchs"===e,testId:"tab-trierarchs",count:{value:d,tone:"attention",words:"silent"}}),(0,t.jsx)($,{href:"/inbox",label:"Inbox",icon:(0,t.jsx)(r.Inbox,{"aria-hidden":!0}),isActive:"inbox"===e,testId:"tab-inbox",count:{value:n,tone:"primary",words:"open"}}),(0,t.jsx)($,{href:"/needs-attention",label:"Attention",icon:(0,t.jsx)(u.TriangleAlert,{"aria-hidden":!0}),isActive:"attention"===e,testId:"tab-attention",count:{value:i,tone:"attention",words:"need attention"}})]})}],15034)},85538,e=>{"use strict";var t=e.i(43476),n=e.i(24071),r=e.i(66595),i=e.i(22016),o=e.i(15905),s=e.i(24262),a=e.i(57957);e.s(["TopBar",0,function({title:e,live:l,actions:u,back:c,account:d,onSearch:f}){let p=f&&!c?f:void 0;return(0,t.jsxs)("header",{"data-slot":"top-bar","data-mode":c?"detail":"root",className:"sticky top-0 z-30 flex h-(--size-header) items-center gap-2.5 border-b border-border bg-background px-4 sm:hidden",children:[c?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(i.default,{href:c.href,className:"-ml-1.5 inline-flex h-(--size-control-touch) shrink-0 items-center gap-0.5 rounded-md pr-2 text-body-touch text-foreground focus-visible:outline-2 focus-visible:outline-ring [&_svg]:size-(--size-icon)",children:[(0,t.jsx)(n.ChevronLeft,{"aria-hidden":!0}),c.label]}),(0,t.jsx)("p",{className:"min-w-0 flex-1 truncate text-center text-body-touch font-semibold text-foreground",children:e})]}):(0,t.jsx)("h1",{className:"truncate text-title-touch font-semibold tracking-tight text-foreground",children:e}),(0,t.jsx)(s.LiveStatus,{state:l}),u||p||d&&!c?(0,t.jsxs)("div",{className:"ml-auto flex items-center gap-1",children:[p?(0,t.jsx)(o.Button,{variant:"ghost",size:"touch",isIconOnly:!0,"aria-label":"Search ships or jump to","data-testid":"top-bar-search",onClick:p,children:(0,t.jsx)(r.Search,{"aria-hidden":!0})}):null,u,d&&!c?(0,t.jsx)(a.AccountMenuSheet,{...d}):null]}):null]})}])},88721,3979,e=>{"use strict";var t=e.i(54616),n=e.i(66027),r=e.i(12598),i=e.i(18566),o=e.i(41880),s=e.i(87600),a=e.i(18162),l=e.i(77155),u=e.i(27702),c=e.i(90262),d=e.i(5387),f=e.i(49841),p=e.i(86165),m=e.i(14695),g=e.i(265);function h(){let e=(0,c.useAccess)(),t=(0,p.useHasSquadrons)(),n=(0,g.useHasTrierarchPlugin)(),r=(0,g.useMachines)(),i=(0,d.useFleetSnapshot)();return{...void 0===i.data?{}:{needsCrewCount:(0,f.needsCrew)(i.data,{hasTrierarchs:n}).length},hasSquadrons:t,hasTrierarchs:n,...void 0===r.data?{}:{trierarchsCount:(0,m.silentCount)(r.data)},hasSettings:e.canManage&&(t||n)}}e.s(["usePluginNav",0,h],3979),e.s(["useAccountMenu",0,function(e){let c=(0,u.useTRPC)(),d=(0,i.useRouter)(),f=(0,r.useQueryClient)(),p=(0,n.useQuery)(c.console.account.queryOptions()),m=(0,s.useHostedAccountUrl)(),g=(0,l.useConsoleGuide)(),v=h(),b=(0,t.useMutation)(c.console.setTheme.mutationOptions({onMutate:({theme:e})=>{(0,a.applyTheme)(e),f.setQueryData(c.console.account.queryKey(),t=>t?.kind!=="operator"?t:{...t,theme:e})},onError:()=>{(0,o.showToast)({title:"Couldn’t save the theme",description:"It applies here until the page reloads.",tone:"error"})}})),x=(0,t.useMutation)(c.console.signOut.mutationOptions({onSuccess:()=>{f.clear(),d.replace("/sign-in")}})),y=()=>{x.mutate(void 0,{onError:()=>{(0,o.showToast)({title:"Couldn’t sign out",description:"The server did not answer. You are still signed in.",tone:"error",action:{label:"Try again",onClick:y}})}})};return{...v.hasTrierarchs&&v.hasSettings?{settingsHref:"/settings"}:{},account:p.data,onThemeChange:e=>{b.mutate({theme:e})},onSignOut:y,isSigningOut:x.isPending,now:e,...void 0===m?{}:{accountUrl:m},...void 0===g.onTakeTour?{}:{onTakeTour:g.onTakeTour}}}],88721)},76145,48695,19191,e=>{"use strict";var t=e.i(84294);let n={compose:"canSend",commission:"canManage","form-squadron":"canManage"};e.s(["allowedPaletteItems",0,function(e,t){return e.filter(e=>"action"===e.kind?t[n[e.id]]:"squadron-action"!==e.kind||t.canManage)},"paletteGroups",0,function(e,t){let n=t.trim().toLowerCase(),r=e.filter(e=>""===n?"squadron-action"!==e.kind:("ship"===e.kind?[e.name,e.type]:"squadron"===e.kind?[e.id,e.blueprint]:"squadron-action"===e.kind?[e.squadronId]:"blueprint"===e.kind?[e.name]:[e.label]).some(e=>e.toLowerCase().includes(n))),i=r.filter(e=>"ship"===e.kind);return[{key:"actions",label:"Actions",items:r.filter(e=>"action"===e.kind||"squadron-action"===e.kind)},{key:"ships",label:"Ships",items:""===n?i.slice(0,8):i},{key:"squadrons",label:"Squadrons",items:r.filter(e=>"squadron"===e.kind)},{key:"blueprints",label:"Blueprints",items:r.filter(e=>"blueprint"===e.kind)},{key:"pages",label:"Go to",items:r.filter(e=>"page"===e.kind)}].filter(e=>e.items.length>0)},"paletteItemsOf",0,function(e,n){return[{kind:"action",id:"commission",label:"Commission ship"},...n?[{kind:"action",id:"form-squadron",label:"Form squadron"}]:[],{kind:"action",id:"compose",label:"Compose a message"},...e.filter(e=>"agent"===e.kind&&"retired"!==e.status).map(e=>({kind:"ship",id:e.id,name:e.name,type:e.type,status:e.status,href:`/ships/${e.id}`})),...(n?.squadrons??[]).filter(e=>"disbanded"!==e.state).map(e=>({kind:"squadron",id:e.id,blueprint:e.blueprint.name,state:e.state,href:`/squadrons/${e.id}`})),...(n?.squadrons??[]).filter(e=>"sailing"===e.state).flatMap(e=>[{kind:"squadron-action",id:`add-member:${e.id}`,squadronId:e.id,action:"add-member",label:`Add member to ${e.id}…`,href:`/squadrons/${e.id}?action=add-member`},{kind:"squadron-action",id:`stand-down:${e.id}`,squadronId:e.id,action:"stand-down",label:`Stand down ${e.id}…`,href:`/squadrons/${e.id}?action=stand-down`}]),...(n?.blueprints??[]).map(e=>({kind:"blueprint",id:e.key,name:e.name,version:e.versions[0]?.version??0,href:(0,t.blueprintPath)(e)})),{kind:"page",id:"overview",label:"Fleet overview",href:"/"},...n?[{kind:"page",id:"squadrons",label:"Squadrons",href:"/squadrons"}]:[],{kind:"page",id:"inbox",label:"Operator inbox",href:"/inbox"},{kind:"page",id:"attention",label:"Needs attention",href:"/needs-attention"}]},"paletteKeyOf",0,function(e){return`${e.kind}:${e.id}`}],76145);var r=e.i(54616),i=e.i(66027),o=e.i(12598);e.i(31627);var s=e.i(44827),a=e.i(81307),l=e.i(32150),u=e.i(86165);let c=["forming","sailing","standing-down","disbanded"],d=a.z.object({repository:a.z.string(),name:a.z.string(),version:a.z.number()}),f=a.z.object({templates:a.z.array(a.z.object({repository:a.z.string(),name:a.z.string(),version:a.z.number(),commit:a.z.string(),committedAt:a.z.string(),description:a.z.string(),checkInMinutes:a.z.number(),model:a.z.string().nullable(),launchNote:a.z.string().nullable(),charter:a.z.string(),handoffs:a.z.array(a.z.object({name:a.z.string(),carries:a.z.string()})),file:a.z.string()})),blueprints:a.z.array(a.z.object({repository:a.z.string(),name:a.z.string(),version:a.z.number(),commit:a.z.string(),committedAt:a.z.string(),description:a.z.string(),roles:a.z.array(a.z.object({name:a.z.string(),template:d,count:a.z.number()})),handoffs:a.z.array(a.z.object({role:a.z.string(),handoff:a.z.string(),to:a.z.string()})),memberNames:a.z.enum(["plain","prefixed"]),file:a.z.string()})),problems:a.z.array(a.z.object({repository:a.z.string(),kind:a.z.enum(["template","blueprint","tag"]),name:a.z.string(),version:a.z.number(),message:a.z.string()}))}),p=a.z.object({id:a.z.string(),state:a.z.enum(c),blueprint:a.z.object({repository:a.z.string(),name:a.z.string(),version:a.z.number(),commit:a.z.string()}),flagship:a.z.object({shipId:a.z.string(),name:a.z.string()}),members:a.z.array(a.z.object({shipId:a.z.string(),name:a.z.string(),role:a.z.string(),type:a.z.string(),onStationAt:a.z.string().nullable(),model:a.z.object({pinned:a.z.string().nullable(),stated:a.z.string().nullable(),isMismatch:a.z.boolean()}),health:a.z.enum(["not-on-station","on-time","late","silent"]),checkInMinutes:a.z.number(),crew:a.z.object({status:a.z.enum(["awaitingCrew","crewed","retired"]),lastSeenAt:a.z.string().nullable(),crewedSince:a.z.string().nullable()})})),formedAt:a.z.string(),sailedAt:a.z.string().nullable()}),m=a.z.object({squadronId:a.z.string(),flagship:a.z.object({shipId:a.z.string(),name:a.z.string()}),members:a.z.array(a.z.object({shipId:a.z.string(),name:a.z.string(),role:a.z.string(),crewLines:a.z.array(s.crewLineSchema),launchNote:a.z.string().nullable(),model:a.z.string().nullable()}))}),g=a.z.object({deliveryId:a.z.string(),messageId:a.z.string(),senderShipId:a.z.string(),senderName:a.z.string(),contentType:a.z.string(),payload:a.z.string(),inReplyTo:a.z.string().nullable(),receivedAt:a.z.string()}),h=a.z.union([a.z.object({result:a.z.object({data:a.z.unknown()})}),a.z.object({error:a.z.object({message:a.z.string()})})]);async function v(e,t){let n=`/api/squadrons/${e}`,r=t.isMutation?await fetch(n,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(t.input??{})}):await fetch(void 0===t.input?n:`${n}?input=${encodeURIComponent(JSON.stringify(t.input))}`,{cache:"no-store"}),i=h.safeParse(await r.json());if(!i.success)throw Error("squadrons answered something the console does not understand");if("error"in i.data)throw Error(i.data.error.message);return t.answers.parse(i.data.result.data)}let b=["squadrons","list"],x=a.z.object({shipId:a.z.string(),name:a.z.string(),role:a.z.string(),crewLines:a.z.array(s.crewLineSchema),launchNote:a.z.string().nullable(),model:a.z.string().nullable()}),y=a.z.object({crewLines:a.z.array(s.crewLineSchema),launchNote:a.z.string().nullable(),model:a.z.string().nullable()});function S(e){return["squadrons","crew-lines",e]}let C=a.z.object({name:a.z.string(),url:a.z.string(),path:a.z.string(),hasToken:a.z.boolean(),addedAt:a.z.string(),lastFetch:a.z.object({at:a.z.string(),error:a.z.string().nullable()}).nullable()}),E=["squadrons","repositories"];function R(){let e=(0,o.useQueryClient)();return async()=>{await Promise.all([e.invalidateQueries({queryKey:E}),e.invalidateQueries({queryKey:["squadrons","catalogue"]})])}}e.s(["SQUADRON_STATES",0,c,"useAddMember",0,function(){let e=(0,o.useQueryClient)();return(0,r.useMutation)({mutationFn:e=>v("squadrons.addMember",{input:e,isMutation:!0,answers:x}),onSuccess:async()=>{await e.invalidateQueries({queryKey:b})}})},"useAddRepository",0,function(){let e=R();return(0,r.useMutation)({mutationFn:e=>v("repositories.add",{input:e,isMutation:!0,answers:C}),onSettled:e})},"useCatalogue",0,function(){let e="connected"===(0,u.useSquadronsConnection)();return(0,i.useQuery)({queryKey:["squadrons","catalogue"],queryFn:()=>v("catalogue.list",{answers:f}),enabled:e})},"useForceStandDown",0,function(){let e=(0,o.useQueryClient)();return(0,r.useMutation)({mutationFn:e=>v("squadrons.forceStandDown",{input:{squadronId:e},isMutation:!0,answers:a.z.object({})}),onSuccess:async()=>{await e.invalidateQueries({queryKey:b})}})},"useFormSquadron",0,function(){let e=(0,o.useQueryClient)(),{track:t}=(0,l.useAnalytics)();return(0,r.useMutation)({mutationFn:e=>v("squadrons.form",{input:{blueprint:e},isMutation:!0,answers:m}),onSuccess:async n=>{t({name:"squadron_formed",roleCount:new Set(n.members.map(e=>e.role)).size}),e.setQueryData(S(n.squadronId),n.members),await e.invalidateQueries({queryKey:b})}})},"useIssuedCrewLines",0,function(e){return new Map(((0,o.useQueryClient)().getQueryData(S(e))??[]).map(e=>[e.shipId,{crewLines:e.crewLines,launchNote:e.launchNote,model:e.model}]))},"useKeptMessages",0,function(e){let t="connected"===(0,u.useSquadronsConnection)();return(0,i.useQuery)({queryKey:["squadrons","messages",e],queryFn:()=>v("squadrons.messages",{input:{squadronId:e},answers:a.z.array(g)}),refetchInterval:5e3,enabled:t})},"useNewCrewLine",0,function(){let e=(0,o.useQueryClient)();return(0,r.useMutation)({mutationFn:e=>v("squadrons.newCrewLine",{input:e,isMutation:!0,answers:y}),onSuccess:async()=>{await e.invalidateQueries({queryKey:b})}})},"useRefreshCatalogue",0,function(){let e=R();return(0,r.useMutation)({mutationFn:()=>v("catalogue.refresh",{isMutation:!0,answers:a.z.strictObject({})}),onSuccess:e})},"useRemoveMember",0,function(){let e=(0,o.useQueryClient)();return(0,r.useMutation)({mutationFn:e=>v("squadrons.removeMember",{input:e,isMutation:!0,answers:a.z.strictObject({})}),onSuccess:async()=>{await e.invalidateQueries({queryKey:b})}})},"useRemoveRepository",0,function(){let e=R();return(0,r.useMutation)({mutationFn:e=>v("repositories.remove",{input:{name:e},isMutation:!0,answers:a.z.strictObject({})}),onSettled:e})},"useRepositories",0,function(){let e="connected"===(0,u.useSquadronsConnection)();return(0,i.useQuery)({queryKey:E,queryFn:()=>v("repositories.list",{answers:a.z.array(C)}),enabled:e})},"useSquadrons",0,function(){let e="connected"===(0,u.useSquadronsConnection)();return(0,i.useQuery)({queryKey:b,queryFn:()=>v("squadrons.list",{answers:a.z.array(p)}),refetchInterval:5e3,enabled:e})},"useStandDown",0,function(){let e=(0,o.useQueryClient)();return(0,r.useMutation)({mutationFn:e=>v("squadrons.standDown",{input:{squadronId:e},isMutation:!0,answers:a.z.object({})}),onSuccess:async()=>{await e.invalidateQueries({queryKey:b})}})}],48695);var w=e.i(56420);let I={name:"corner-down-left",size:24,node:[["path",{d:"M20 4v7a4 4 0 0 1-4 4H4",key:"6o5b7l"}],["path",{d:"m9 10-5 5 5 5",key:"1kshq7"}]]};I.node;let T=(0,w.default)(I);e.s(["CornerDownLeft",0,T],19191)},57497,90262,80581,5387,49092,16752,30274,74470,14651,8821,e=>{"use strict";var t=e.i(54616),n=e.i(12598),r=e.i(27702);e.s(["composeTargets",0,function(e){let t=e.filter(e=>"agent"===e.kind&&"retired"!==e.status);return{ships:t,types:[...new Set(t.map(e=>e.type))].sort()}},"sendInputOf",0,function(e,t){let{selector:n,payload:r,inReplyTo:i}=e;return{selector:n,payload:r,contentType:"text/plain",idempotencyKey:t,...void 0===i?{}:{inReplyTo:i}}},"useSendMessage",0,function(){let e=(0,r.useTRPC)(),i=(0,n.useQueryClient)();return(0,t.useMutation)(e.ship.send.mutationOptions({onSuccess:()=>i.invalidateQueries({queryKey:e.fleet.pathKey()})}))}],57497);var i=e.i(66027);let o={canManage:!1,canSend:!1,canReceive:!1,canDefineLabels:!1,canAssignLabels:!1,isViewer:!1};function s(){let e=(0,r.useTRPC)();return function(e){return void 0===e?o:{canManage:e.scopes.includes("fleet:manage"),canSend:e.scopes.includes("messages:send"),canReceive:e.scopes.includes("messages:receive"),canDefineLabels:e.scopes.includes("labels:define"),canAssignLabels:e.scopes.includes("labels:assign"),isViewer:"viewer"===e.kind}}((0,i.useQuery)(e.console.session.queryOptions()).data)}e.s(["useAccess",0,s],90262);var a=e.i(32150);e.i(31627);var l=e.i(93669);let u={"trierarch-plugin":"trierarch-plugin",squadrons:"squadrons"};function c(e,t){let n=new Map(t.ships.map(e=>[e.id,e])),r=new Map(e.map(e=>{let r=n.get(e.owner.id),i=t.isOperator&&r?.kind==="operator",o=i?"none":u[r?.type??""]??"ship";return[e.id,{name:e.owner.name,mark:o,isYours:i}]}));return{labels:e,ownerOf:r,ships:t.ships}}function d(e){let t=e.ships.filter(e=>"retired"!==e.status),n=new Map;for(let r of e.labels){let i=e.ownerOf.get(r.id),o=i?.isYours??!1,s=o?"Yours":`By ${r.owner.name}`,a=n.get(s)??{title:s,isYours:o,keys:[]};a.keys.push({labelId:r.id,key:r.key,mark:i?.mark??"ship",values:r.values.map(e=>({valueId:e.id,value:e.value,shipCount:t.filter(t=>t.labels.some(t=>t.valueId===e.id)).length}))}),n.set(s,a)}return[...n.values()].toSorted((e,t)=>Number(t.isYours)-Number(e.isYours)||e.title.localeCompare(t.title)).map(({title:e,keys:t})=>({title:e,keys:t.toSorted((e,t)=>e.key.localeCompare(t.key))}))}function f(e){return e.length<=1?e[0]??"":`${e.slice(0,-1).join(", ")} and ${e.at(-1)??""}`}function p(){let e=(0,r.useTRPC)();return(0,i.useQuery)(e.fleet.list.queryOptions(void 0,{refetchInterval:3e4}))}function m(){let e=(0,r.useTRPC)();return(0,i.useQuery)(e.fleet.labels.queryOptions())}function g(){let e=(0,r.useTRPC)(),t=(0,n.useQueryClient)();return()=>t.invalidateQueries({queryKey:e.fleet.pathKey()})}e.s(["activeShipCount",0,function(e){return e.ships.filter(e=>"retired"!==e.status).length},"assignKeysOf",0,function(e,t){let n=d(t).find(e=>"Yours"===e.title);return(n?.keys??[]).map(t=>({...t,carriedValueIds:e.labels.filter(e=>e.labelId===t.labelId).map(e=>e.valueId)}))},"carriesEvery",0,function(e,t){return t.every(t=>e.labels.some(e=>e.valueId===t))},"chipsOf",0,function(e,t){let n=e=>t.ownerOf.get(e.labelId)?.isYours??!1;return e.labels.map(e=>{let n=t.ownerOf.get(e.labelId);return{labelId:e.labelId,valueId:e.valueId,key:e.key,value:e.value,mark:n?.mark??"ship",ownerName:n?.name??""}}).toSorted((e,t)=>Number(n(t))-Number(n(e))||e.key.localeCompare(t.key)||e.value.localeCompare(t.value))},"filterGroupsOf",0,d,"labelContextOf",0,c,"labelLimitOf",0,function(e){let t=e.labels.length;return{...t>=15?{count:`${String(t)} of ${String(l.SHIP_LABELS_MAX)}`}:{},isAtLimit:t>=l.SHIP_LABELS_MAX}},"labelRowsOf",0,function(e){let t=e.ships.filter(e=>"retired"!==e.status);return e.labels.map(n=>{let r=e.ownerOf.get(n.id);return{labelId:n.id,key:n.key,owner:{name:n.owner.name,isYours:r?.isYours??!1,mark:r?.mark??"ship"},values:n.values.map(e=>{let n;return{valueId:e.id,value:e.value,shipCount:t.filter((n=e.id,e=>e.labels.some(e=>e.valueId===n))).length}}),shipCount:t.filter(e=>e.labels.some(e=>e.labelId===n.id)).length}}).toSorted((e,t)=>Number(t.owner.isYours)-Number(e.owner.isYours)||e.owner.name.localeCompare(t.owner.name)||e.key.localeCompare(t.key))},"labelTextProblem",0,function(e,t){if(!(""===e||e.length<=l.LABEL_HANDLE_MAX_LENGTH&&l.LABEL_HANDLE_PATTERN.test(e)))return`${t}: use lowercase letters, digits and - only, at most ${String(l.LABEL_HANDLE_MAX_LENGTH)} characters (decision 0031).`},"matchesLabelQuery",0,function(e,t){let n=t.trim().toLowerCase();return""===n||e.key.includes(n)||e.values.some(e=>e.value.includes(n))},"pickedChips",0,function(e,t){return e.flatMap(e=>{let n=t.labels.find(t=>t.values.some(t=>t.id===e)),r=n?.values.find(t=>t.id===e);if(void 0===n||void 0===r)return[];let i=t.ownerOf.get(n.id);return[{labelId:n.id,valueId:e,key:n.key,value:r.value,mark:i?.mark??"ship",ownerName:i?.name??n.owner.name}]})},"retireLabelLines",0,function(e){let t=[];if(e.carried.length>0&&t.push(`Its ${1===e.carried.length?"label is":`${String(e.carried.length)} labels are`} removed with it: ${e.carried.join(", ")}.`),void 0!==e.owned){let{keys:n,carriers:r}=e.owned;t.push(`Its ${1===n.length?"label retires":`${String(n.length)} labels retire`} with it: ${f(n)}. Nobody can assign ${1===n.length?"it":"them"} again.`),r.length>0&&t.push(`${1===n.length?"It is":"They are"} removed from the ${1===r.length?"ship that carries":`${String(r.length)} ships that carry`} ${1===n.length?"it":"them"}: ${f(r)}.`)}return t},"retiredLabelsOf",0,function(e,t){let n=e.labels.map(e=>`${e.key}=${e.value}`),r=t.labels.filter(t=>t.owner.id===e.id);if(0===r.length)return{carried:n};let i=new Set(r.map(e=>e.id)),o=t.ships.filter(t=>"retired"!==t.status&&t.id!==e.id&&t.labels.some(e=>i.has(e.labelId))).map(e=>e.name);return{carried:n,owned:{keys:r.map(e=>e.key),carriers:o}}},"rowChips",0,function(e,t){let n=0,r=e.findIndex((e,r)=>(n+=e.key.length+e.value.length+1,r>0&&n>t)),i=-1===r?e.length:r;return{shown:e.slice(0,i),folded:e.slice(i)}}],80581),e.s(["LAST_SEEN_REFRESH_MS",0,3e4,"useAssignLabel",0,function(){let e=(0,r.useTRPC)(),n=g();return(0,t.useMutation)(e.fleet.assignLabel.mutationOptions({onSuccess:n}))},"useChangeLabelValues",0,function(){let e=(0,r.useTRPC)(),n=g();return(0,t.useMutation)(e.fleet.changeLabelValues.mutationOptions({onSuccess:n}))},"useCommissionShip",0,function(){let e=(0,r.useTRPC)(),n=g(),{track:i}=(0,a.useAnalytics)();return(0,t.useMutation)(e.fleet.commission.mutationOptions({onSuccess:async()=>{i({name:"ship_commissioned"}),await n()}}))},"useDefineLabel",0,function(){let e=(0,r.useTRPC)(),n=g();return(0,t.useMutation)(e.fleet.defineLabel.mutationOptions({onSuccess:n}))},"useDeleteLabel",0,function(){let e=(0,r.useTRPC)(),n=g();return(0,t.useMutation)(e.fleet.deleteLabel.mutationOptions({onSuccess:n}))},"useFleetLabels",0,m,"useFleetSnapshot",0,p,"useGetStartingPrompt",0,function(){let e=(0,r.useTRPC)(),n=g();return(0,t.useMutation)(e.fleet.getStartingPrompt.mutationOptions({onSuccess:n}))},"useLabelContext",0,function(){let e=m(),t=p(),n=s();if(void 0!==e.data&&void 0!==t.data)return c(e.data,{ships:t.data,isOperator:!n.isViewer})},"usePingShip",0,function(){let e=(0,r.useTRPC)(),n=g();return(0,t.useMutation)(e.fleet.ping.mutationOptions({onSuccess:n}))},"useRecrewShip",0,function(){let e=(0,r.useTRPC)(),n=g();return(0,t.useMutation)(e.fleet.recrew.mutationOptions({onSuccess:n}))},"useReleaseShip",0,function(){let e=(0,r.useTRPC)(),n=g();return(0,t.useMutation)(e.fleet.release.mutationOptions({onSuccess:n}))},"useRemoveCrewRequest",0,function(){let e=(0,r.useTRPC)(),n=g();return(0,t.useMutation)(e.fleet.removeCrewRequest.mutationOptions({onSuccess:n}))},"useRenameShip",0,function(){let e=(0,r.useTRPC)(),n=g();return(0,t.useMutation)(e.fleet.rename.mutationOptions({onSuccess:n}))},"useRequestCrew",0,function(){let e=(0,r.useTRPC)(),n=g();return(0,t.useMutation)(e.fleet.crewRequest.mutationOptions({onSuccess:n}))},"useRetireShip",0,function(){let e=(0,r.useTRPC)(),n=g();return(0,t.useMutation)(e.fleet.retire.mutationOptions({onSuccess:n}))},"useUnassignLabel",0,function(){let e=(0,r.useTRPC)(),n=g();return(0,t.useMutation)(e.fleet.unassignLabel.mutationOptions({onSuccess:n}))}],5387),e.s(["useFleetLimits",0,function(){let e=(0,r.useTRPC)();return(0,i.useQuery)(e.fleet.limits.queryOptions(void 0,{refetchInterval:6e4}))}],49092);let h=new Intl.NumberFormat("en-US");function v(e){return h.format(e)}function b(e){return`${new Date(e).toISOString().slice(11,16)} UTC`}function x({count:e,limit:t}){return null===t?"none":e<t?"below":e===t?"at":"over"}e.s(["composeRefusedNotice",0,function(e){return{title:"This message wasn’t sent",description:`Your fleet reached its limit of ${v(e.limit)} messages today. Sending works again after the limit resets at ${b(e.resetsAt)}.`}},"hasLimits",0,function(e){return void 0!==e&&(null!==e.ships.limit||null!==e.dailyMessages.limit)},"messageLimitNotice",0,function(e){return{title:"Your fleet reached today’s message limit",description:`It sent ${v(e.limit)} messages today, its daily limit. New messages are refused until the limit resets at ${b(e.resetsAt)}.`}},"messageLimitReached",0,function(e){let t=e?.dailyMessages;return t?.limit!=null&&t.count>=t.limit?{limit:t.limit,resetsAt:t.resetsAt}:void 0},"meterCaption",0,function(e){let{count:t,limit:n}=e;if(null===n)return;let r=x(e);return"below"===r?`${v(n-t)} left`:"at"===r?"Limit reached":`${v(t-n)} over the limit`},"meterCount",0,function(e){return v(e)},"meterState",0,x,"resetTime",0,b,"shipLimitNotice",0,function(e){return{title:"Your fleet is at its ship limit",description:`This fleet can have ${v(e)} ships, so it can’t take a new one. Limits are listed on your account.`}},"shipLimitReached",0,function(e){let t=e?.ships;return t?.limit!=null&&t.count>=t.limit?t.limit:void 0}],16752);var y=e.i(56420);let S={name:"send",size:24,node:[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]]};S.node;let C=(0,y.default)(S);e.s(["Send",0,C],30274);var E=e.i(71645);let R=/Mac|iPhone|iPad|iPod/;function w(){return()=>void 0}function I(){var e;return e=navigator.userAgent,R.test(e)?"mac":"other"}function T(){return null}e.s(["sendShortcutAria",0,function(e){return"mac"===e?"Meta+Enter":"Control+Enter"},"sendShortcutKeys",0,function(e){return"mac"===e?"⌘↵":"Ctrl ↵"},"submitOnSendShortcut",0,function(e){var t;let{key:n,metaKey:r,ctrlKey:i}=e;"Enter"===(t={key:n,metaKey:r,ctrlKey:i,isComposing:e.nativeEvent.isComposing}).key&&(t.metaKey||t.ctrlKey)&&!t.isComposing&&(e.preventDefault(),e.currentTarget.form?.requestSubmit())},"useShortcutPlatform",0,function(){return(0,E.useSyncExternalStore)(w,I,T)}],74470),e.s([],14651);var k=e.i(33332);let O=E.createContext(void 0);e.s(["DialogRootContext",0,O,"useDialogRootContext",0,function(e){let t=E.useContext(O);if(!e&&void 0===t)throw Error((0,k.default)(27));return t}],8821)},54492,e=>{"use strict";e.s(["crewRequestAction",0,function(e){switch(e.kind){case"none":return;case"needsCrew":return"remove";case"crewedByHand":return"release";case"assigned":return"releasing"===e.status?void 0:"release"}},"crewRequestStage",0,function(e){let t=e.crewRequest;return null===t?{kind:"none"}:null!==t.assignedTo?{kind:"assigned",requestedAt:t.requestedAt,trierarch:t.assignedTo,status:t.status??"crewing",attempt:t.attempt,startedAt:t.startedAt}:null!==t.crewedBy?{kind:"crewedByHand",requestedAt:t.requestedAt,crewedBy:t.crewedBy,since:e.crewedSince??null}:{kind:"needsCrew",requestedAt:t.requestedAt,reason:t.reason}},"isRestartable",0,function(e){return"assigned"===e.kind&&"crashed"===e.status},"releaseSteps",0,function(e){return"crewedByHand"===e.kind?["removeCrewRequest","release"]:["removeCrewRequest"]},"requestedBy",0,function(e){return e.find(e=>"CrewRequested"===e.type)?.actor??null},"restartWords",0,function({status:e,attempt:t}){let n=`${String(t)} ${1===t?"restart":"restarts"}`;switch(e){case"restarting":return`attempt ${String(t)}`;case"crashed":return n;case"running":return 0===t?void 0:n;case"crewing":case"releasing":return}},"statusChangedAt",0,function(e){return e.find(e=>"CrewStatusChanged"===e.type)?.occurredAt}])},86413,e=>{"use strict";var t=e.i(54616),n=e.i(66027),r=e.i(12598),i=e.i(27702);function o(){let e=(0,i.useTRPC)();return(0,n.useQuery)(e.fleet.inbox.queryOptions({filter:"all"}))}function s(e){return"pending"===e.state||"delivered"===e.state}function a(e,t){switch(t){case"open":return e.filter(s);case"done":return e.filter(e=>"acknowledged"===e.state);case"all":return[...e]}}function l(){let e=(0,i.useTRPC)(),t=(0,r.useQueryClient)();return()=>t.invalidateQueries({queryKey:e.fleet.pathKey()})}e.s(["filterCounts",0,function(e){return{open:a(e,"open").length,done:a(e,"done").length,all:e.length}},"inboxPathOf",0,function(e){let t=new URLSearchParams;"open"!==e.filter&&t.set("filter",e.filter),void 0!==e.deliveryId&&t.set("message",e.deliveryId);let n=t.toString();return""===n?"/inbox":`/inbox?${n}`},"messagesFor",0,a,"readInboxFilter",0,function(e){return"done"===e||"all"===e?e:"open"},"useInbox",0,o,"useMarkDone",0,function(){let e=(0,i.useTRPC)(),n=l();return(0,t.useMutation)(e.fleet.markDone.mutationOptions({onSuccess:n}))},"useMarkRead",0,function(){let e=(0,i.useTRPC)(),n=l();return(0,t.useMutation)(e.fleet.markRead.mutationOptions({onSuccess:n}))},"useOpenInboxCount",0,function(){let e=o().data;return void 0===e?void 0:e.filter(s).length},"useReply",0,function(){let e=(0,i.useTRPC)(),n=l();return(0,t.useMutation)(e.fleet.reply.mutationOptions({onSuccess:n}))}])},18423,e=>{"use strict";var t=e.i(12598),n=e.i(5861),r=e.i(71645),i=e.i(27702);let o=new Set(["FleetInitialised","ShipCommissioned","ShipClaimed","LeaseRevoked","CredentialRevoked","StartingPromptIssued","ShipRetired","DeliveryAcknowledged","DeliveryUndeliverable","ShipReported","CrewRequested","CrewRequestRemoved","CrewAssigned","CrewStatusChanged","CrewRequestExplained","LabelAssigned","LabelUnassigned","LabelRetired"]);async function s(e,t){await e.cancelQueries({queryKey:t,predicate:e=>void 0===e.state.data&&"fetching"===e.state.fetchStatus}),await e.invalidateQueries({queryKey:t})}let a=new Set(["LabelDefined","LabelValuesChanged","LabelRetired","LabelAssigned","LabelUnassigned","LabelDeleted"]),l=new Set(["DeliveryUndeliverable","DeliveryDismissed"]);e.s(["useLiveFleet",0,function(){let e=(0,i.useTRPC)(),u=(0,t.useQueryClient)(),[c,d]=(0,r.useState)(new Set),f=e=>{s(u,e)},p=(0,n.useSubscription)(e.fleet.events.subscriptionOptions({lastEventId:null},{onData:({data:t})=>{var n,r,i;if("resync"===t.kind)return void f(e.fleet.pathKey());let{event:s}=t;for(let t of new Set([s.shipId,s.actorShipId]))null!==t&&(f(e.fleet.ship.queryKey({shipId:t})),f(e.fleet.shipTimeline.queryKey({shipId:t})));if(null!==s.messageId&&(f(e.fleet.shipMessages.pathKey()),f(e.fleet.message.queryKey({messageId:s.messageId})),f(e.fleet.inbox.pathKey())),n=s.type,l.has(n)&&f(e.fleet.needsAttention.queryKey()),r=s.type,a.has(r)&&f(e.fleet.labels.queryKey()),i=s.type,!o.has(i))return;f(e.fleet.list.queryKey());let{shipId:u}=s;"ShipCommissioned"===s.type&&null!==u&&d(e=>new Set([...e,u]))}}));return{live:function(e){switch(e){case"pending":return"live";case"connecting":return"reconnecting";case"idle":case"error":return"offline"}}(p.status),newShipIds:c,error:p.error}}])},40798,46150,65160,79652,e=>{"use strict";let t={DEVICE:"Device",CLOUD:"Cloud",SERVER:"Server",OTHER:"Other"};e.s(["locationKindWord",0,function(e){return t[e]}],40798);let n="argo";e.s(["OPERATOR_NAME",0,n,"capitalised",0,function(e){return e.charAt(0).toUpperCase()+e.slice(1)},"counted",0,function(e,t){return`${String(e)} ${1===e?t.one:t.many}`},"ship",0,function(e){return{kind:"ship",party:e}},"text",0,function(e){return{kind:"text",text:e}}],46150),e.i(31627);var r=e.i(44827);let i=`Lowercase letters, digits, hyphens and colons, up to ${String(r.SHIP_HANDLE_MAX_LENGTH)} characters, unique among active ships.`;e.s(["asHandle",0,function(e){return e.toLowerCase()},"checkShipName",0,function(e,t){return""===e?{kind:"empty",message:i}:r.shipHandleSchema.safeParse(e).success?e===n?{kind:"reserved",message:`${n} is reserved for the operator ship.`}:e===t.current?{kind:"unchanged",message:"That is its name now."}:t.activeNames.includes(e)?{kind:"taken",message:`${e} is already used by an active ship.`}:{kind:"available",message:`${e} is available.`}:{kind:"invalid",message:`Use 1 to ${String(r.SHIP_HANDLE_MAX_LENGTH)} lowercase letters, digits, hyphens or colons.`}},"typeHint",0,function(e,t){let n=e.trim();return""===n?"Free text. Pick a type in use or write a new one.":0===t?`No ship uses this type yet. ${n} becomes a new type.`:1===t?"1 ship uses this type.":`${String(t)} ships use this type.`}],65160),e.s([],79652)},14695,e=>{"use strict";e.i(31627);var t=e.i(9677);let n=["running","crashed","restarting","crewing","releasing"];e.s(["capacityLine",0,function(e,t){if(void 0===t)return;let r=t=>e.filter(e=>e.status===t).length,i=n.slice(1).flatMap(e=>0===r(e)?[]:[`${String(r(e))} ${e}`]),o=e.length>=t.ships;return[`${String(r("running"))} of ${String(t.ships)} running`,...i,...o?["full"]:[]].join(" · ")},"harnessOptions",0,function(e){let t=e.properties;return"object"!=typeof t||null===t?[]:Object.entries(t).flatMap(([e,t])=>{if("object"!=typeof t||null===t||!("enum"in t)||!Array.isArray(t.enum))return[];let n=t.enum.filter(e=>"string"==typeof e),r="default"in t&&"string"==typeof t.default?t.default:void 0;return[{name:e,values:n,...void 0===r?{}:{defaultValue:r}}]})},"machineLiveness",0,function(e){return"awaitingCrew"===e.status&&null===e.lastSeenAt?"not-started":e.isSilent?"silent":"alive"},"silentCount",0,function(e){return e.filter(e=>e.isSilent).length},"spotsOf",0,function(e,t){return t.flatMap(t=>t.crewRequest?.assignedTo?.id===e.shipId?[{shipId:t.id,name:t.name,status:t.crewRequest.status??"crewing",attempt:t.crewRequest.attempt,startedAt:t.crewRequest.startedAt}]:[]).toSorted((e,t)=>n.indexOf(e.status)-n.indexOf(t.status)||e.name.localeCompare(t.name))},"withWorkspaces",0,function(e,n){return e.map(e=>{let r=t.crewSettingsSchema.safeParse(n.get(e.shipId));if(!r.success)return e;let{workspace:i}=r.data;return{...e,workspace:"worktree"===i.kind?{name:i.repository,kind:"worktree"}:{name:i.name,kind:"folder"}}})}])},28459,e=>{"use strict";e.i(31627);var t=e.i(53341),n=e.i(54616),r=e.i(66027),i=e.i(12598),o=e.i(48695),s=e.i(84294),a=e.i(27702);function l(){let e=(0,a.useTRPC)();return(0,r.useQuery)(e.fleet.needsAttention.queryOptions())}function u(){let e=(0,a.useTRPC)(),t=(0,i.useQueryClient)();return()=>t.invalidateQueries({queryKey:e.fleet.pathKey()})}e.s(["DISMISSED_TOAST",0,{title:"Delivery dismissed",description:"It stays in the timelines as dismissed."},"canResend",0,function(e){return!(0,t.isPingContentType)(e.message.contentType)},"deliveryWithId",0,function(e,t){return e?.find(e=>e.deliveryId===t)},"messagePathOf",0,function(e){let{message:t}=e;return`/ships/${t.sender.id}?tab=messages&message=${t.id}`},"resentToast",0,function(e){return{title:"Message resent",description:`A new message went to ${function(e){let{recipient:t}=e.message;return"ship"===t.kind?t.ship.name:`any ship of type ${t.type}`}(e)}. The original is dismissed.`}},"useAttentionCount",0,function(){let e=l().data?.length,t=(0,o.useSquadrons)();return void 0===e?void 0:e+(0,s.silentMembers)(t.data??[]).length},"useDismissDelivery",0,function(){let e=(0,a.useTRPC)(),t=u();return(0,n.useMutation)(e.fleet.dismiss.mutationOptions({onSuccess:t}))},"useNeedsAttention",0,l,"useResendDelivery",0,function(){let e=(0,a.useTRPC)(),t=u();return(0,n.useMutation)(e.fleet.resend.mutationOptions({onSuccess:t}))}])},49841,e=>{"use strict";e.i(31627);var t=e.i(85939),n=e.i(54492);let r={crewing:{tone:"active",word:"Crewing"},running:{tone:"ok",word:"Running"},restarting:{tone:"waiting",word:"Restarting"},crashed:{tone:"attention",word:"Crashed"},releasing:{tone:"active",word:"Releasing"}},i=["none","needsCrew","crewedByHand",...t.CREW_STATUSES];e.s(["CREW_REQUEST_KEYS",0,i,"crewRequestCell",0,function(e){switch(e.kind){case"none":return;case"needsCrew":return{tone:"waiting",word:"Needs crew"};case"crewedByHand":return{tone:"ok",word:"Crewed by hand"};case"assigned":return r[e.status]}},"crewRequestKey",0,function(e){return"assigned"===e.kind?e.status:e.kind},"crewRequestKeyWord",0,function(e){return"none"===e?"No request":"needsCrew"===e?"Needs crew":"crewedByHand"===e?"Crewed by hand":r[e].word},"handCrewOf",0,function(e){return null===e.startingPrompt?{kind:"no-prompt"}:e.startingPrompt.isClaimed?{kind:"crew-ended",endedAt:e.awaitingCrewSince}:{kind:"prompt-unclaimed",issuedAt:e.startingPrompt.issuedAt}},"needsCrew",0,function(e,t){return e.filter(e=>(function(e,t){if("retired"===e.status)return!1;let r=(0,n.crewRequestStage)(e);return t.hasTrierarchs?"needsCrew"===r.kind||"assigned"===r.kind&&"running"!==r.status&&"releasing"!==r.status:"needsCrew"===r.kind&&"awaitingCrew"===e.status})(e,t)).toSorted((e,t)=>(e.crewRequest?.requestedAt??"").localeCompare(t.crewRequest?.requestedAt??""))}])},96676,e=>{"use strict";let t;var n=e.i(71645);let r=Date.now(),i=new Set;function o(e){return i.add(e),t??=setInterval(()=>{for(let e of(r=Date.now(),i))e()},1e4),()=>{i.delete(e),0===i.size&&(clearInterval(t),t=void 0)}}function s(){return r}e.s(["useNow",0,function(){return new Date((0,n.useSyncExternalStore)(o,s,s))}])},78485,e=>{"use strict";var t=e.i(12598),n=e.i(18566),r=e.i(71645),i=e.i(46929);e.s(["useSignInWhenSessionEnds",0,function(e){let o=(0,n.useRouter)(),s=(0,t.useQueryClient)(),a=e.find(e=>"UNAUTHORIZED"===(0,i.trpcErrorCode)(e)),l=void 0===a?void 0:(0,i.isSignedInElsewhere)(a)?"/sign-in?notice=signed-in-elsewhere":"/sign-in";(0,r.useEffect)(()=>{void 0!==l&&(s.clear(),o.replace(l))},[l,s,o])}])},31513,e=>{"use strict";e.s(["SOURCE_URL",0,"https://github.com/ThomasHendrickx/aeolus-fleet"])},84294,e=>{"use strict";function t(e,t){return e.roles.map(e=>({role:e.name,template:`${e.template.name}@${String(e.template.version)}`,count:e.count,checkInMinutes:t.find(t=>t.repository===e.template.repository&&t.name===e.template.name&&t.version===e.template.version)?.checkInMinutes}))}function n(e){let t=Math.floor(e/60),n=e%60;return 0===t?`${String(n)} min`:0===n?`${String(t)} h`:`${String(t)} h ${String(n)} min`}e.s(["blueprintChoices",0,function(e){let t=new Map;for(let n of e.blueprints){let e=`${n.repository}#${n.name}`,r=t.get(e)??{key:e,repository:n.repository,name:n.name,versions:[]};r.versions.push(n),t.set(e,r)}return[...t.values()].map(e=>({...e,versions:[...e.versions].sort((e,t)=>t.version-e.version)})).sort((e,t)=>e.name.localeCompare(t.name))},"blueprintPath",0,function(e){let t=new URLSearchParams({repository:e.repository});return void 0!==e.version&&t.set("version",String(e.version)),`/squadrons/blueprints/${encodeURIComponent(e.name)}?${t.toString()}`},"blueprintsUsing",0,function(e,t){return e.filter(e=>e.roles.some(e=>e.template.repository===t.repository&&e.template.name===t.name&&(void 0===t.version||e.template.version===t.version)))},"checkInText",0,function(e){return e%60==0?`every ${String(e/60)} h`:`every ${String(e)} min`},"handoffsOf",0,function(e,t){let n=e=>[...new Set(e)];return{from:n(e.handoffs.filter(e=>e.to===t).map(e=>e.role)),to:n(e.handoffs.filter(e=>e.role===t).map(e=>e.to))}},"handoffsText",0,function(e){let t=[e.from.length>0?`from ${e.from.join(", ")}`:void 0,e.to.length>0?`to ${e.to.join(", ")}`:void 0].filter(e=>void 0!==e);return 0===t.length?"None":t.join(" · ")},"healthCounts",0,function(e){return["on-time","late","silent","not-on-station"].map(t=>({health:t,count:e.filter(e=>e.health===t).length})).filter(e=>e.count>0)},"memberCount",0,function(e){return e.roles.reduce((e,t)=>e+t.count,0)},"membersByRole",0,function(e){let t=new Map;for(let n of e)t.set(n.role,[...t.get(n.role)??[],n]);return[...t.entries()].map(([e,t])=>({role:e,members:t}))},"otherMembersOfRole",0,function(e,t){let n=e.members.find(e=>e.shipId===t)?.role;return e.members.filter(e=>e.role===n&&e.shipId!==t&&"retired"!==e.crew.status).map(e=>e.name)},"roleOptions",0,function(e,n){let{blueprint:r,templates:i}=n;return t(r,i).map(t=>({role:t.role,template:t.template,checkInMinutes:t.checkInMinutes,now:e.members.filter(e=>e.role===t.role&&"retired"!==e.crew.status).length,inBlueprint:t.count}))},"rolePreviews",0,t,"rolesText",0,function(e){return e.roles.map(e=>e.count>1?`${e.name} \xd7${String(e.count)}`:e.name).join(", ")},"shipsInSquadrons",0,function(e){let t=new Map;for(let n of e)if("disbanded"!==n.state)for(let e of(t.set(n.flagship.shipId,{squadronId:n.id,role:null}),n.members))t.set(e.shipId,{squadronId:n.id,role:e.role});return t},"silentMembers",0,function(e){return e.filter(e=>"disbanded"!==e.state).flatMap(e=>e.members.filter(e=>"silent"===e.health).map(t=>({squadronId:e.id,member:t})))},"squadronActionsOffered",0,function(e,t){let n="sailing"===e.state;return{canAddMember:t.canManage&&n&&t.hasRoles,canMessageFlagship:t.canSend&&"disbanded"!==e.state,canStandDown:t.canManage&&n,canForceStandDown:t.canManage&&"disbanded"!==e.state}},"squadronsFromBlueprint",0,function(e,t){return e.filter(e=>e.blueprint.repository===t.repository&&e.blueprint.name===t.name)},"squadronsText",0,function(e){return["forming","sailing","standing-down"].map(t=>({state:t,count:e.filter(e=>e.state===t).length})).filter(e=>e.count>0).map(e=>`${String(e.count)} ${e.state.replace("-"," ")}`).join(", ")},"stationCount",0,function(e){return{onStation:e.members.filter(e=>null!==e.onStationAt).length,total:e.members.length}},"templateChoices",0,function(e){let t=new Map;for(let n of e.templates){let e=`${n.repository}#${n.name}`,r=t.get(e)??{key:e,repository:n.repository,name:n.name,versions:[]};r.versions.push(n),t.set(e,r)}return[...t.values()].map(e=>({...e,versions:[...e.versions].sort((e,t)=>t.version-e.version)})).sort((e,t)=>e.name.localeCompare(t.name))},"templatePath",0,function(e){let t=new URLSearchParams({repository:e.repository});return void 0!==e.version&&t.set("version",String(e.version)),`/squadrons/templates/${encodeURIComponent(e.name)}?${t.toString()}`},"thresholdsText",0,function(e){return`Late after ${n(+e)}, silent after ${n(3*e)}`},"workCounts",0,function(e){return["working","idle","blocked"].map(t=>({state:t,count:e.filter(e=>e?.state===t).length})).filter(e=>e.count>0)}])}]);