pivtools 0.1.3__cp311-cp311-win_amd64.whl
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.
- pivtools-0.1.3.dist-info/METADATA +222 -0
- pivtools-0.1.3.dist-info/RECORD +127 -0
- pivtools-0.1.3.dist-info/WHEEL +5 -0
- pivtools-0.1.3.dist-info/entry_points.txt +3 -0
- pivtools-0.1.3.dist-info/top_level.txt +3 -0
- pivtools_cli/__init__.py +5 -0
- pivtools_cli/_build_marker.c +25 -0
- pivtools_cli/_build_marker.cp311-win_amd64.pyd +0 -0
- pivtools_cli/cli.py +225 -0
- pivtools_cli/example.py +139 -0
- pivtools_cli/lib/PIV_2d_cross_correlate.c +334 -0
- pivtools_cli/lib/PIV_2d_cross_correlate.h +22 -0
- pivtools_cli/lib/common.h +36 -0
- pivtools_cli/lib/interp2custom.c +146 -0
- pivtools_cli/lib/interp2custom.h +48 -0
- pivtools_cli/lib/peak_locate_gsl.c +711 -0
- pivtools_cli/lib/peak_locate_gsl.h +40 -0
- pivtools_cli/lib/peak_locate_gsl_print.c +736 -0
- pivtools_cli/lib/peak_locate_lm.c +751 -0
- pivtools_cli/lib/peak_locate_lm.h +27 -0
- pivtools_cli/lib/xcorr.c +342 -0
- pivtools_cli/lib/xcorr.h +31 -0
- pivtools_cli/lib/xcorr_cache.c +78 -0
- pivtools_cli/lib/xcorr_cache.h +26 -0
- pivtools_cli/piv/interp2custom/interp2custom.py +69 -0
- pivtools_cli/piv/piv.py +240 -0
- pivtools_cli/piv/piv_backend/base.py +825 -0
- pivtools_cli/piv/piv_backend/cpu_instantaneous.py +1005 -0
- pivtools_cli/piv/piv_backend/factory.py +28 -0
- pivtools_cli/piv/piv_backend/gpu_instantaneous.py +15 -0
- pivtools_cli/piv/piv_backend/infilling.py +445 -0
- pivtools_cli/piv/piv_backend/outlier_detection.py +306 -0
- pivtools_cli/piv/piv_backend/profile_cpu_instantaneous.py +230 -0
- pivtools_cli/piv/piv_result.py +40 -0
- pivtools_cli/piv/save_results.py +342 -0
- pivtools_cli/piv_cluster/cluster.py +108 -0
- pivtools_cli/preprocessing/filters.py +399 -0
- pivtools_cli/preprocessing/preprocess.py +79 -0
- pivtools_cli/tests/helpers.py +107 -0
- pivtools_cli/tests/instantaneous_piv/test_piv_integration.py +167 -0
- pivtools_cli/tests/instantaneous_piv/test_piv_integration_multi.py +553 -0
- pivtools_cli/tests/preprocessing/test_filters.py +41 -0
- pivtools_core/__init__.py +5 -0
- pivtools_core/config.py +703 -0
- pivtools_core/config.yaml +135 -0
- pivtools_core/image_handling/__init__.py +0 -0
- pivtools_core/image_handling/load_images.py +464 -0
- pivtools_core/image_handling/readers/__init__.py +53 -0
- pivtools_core/image_handling/readers/generic_readers.py +50 -0
- pivtools_core/image_handling/readers/lavision_reader.py +190 -0
- pivtools_core/image_handling/readers/registry.py +24 -0
- pivtools_core/paths.py +49 -0
- pivtools_core/vector_loading.py +248 -0
- pivtools_gui/__init__.py +3 -0
- pivtools_gui/app.py +687 -0
- pivtools_gui/calibration/__init__.py +0 -0
- pivtools_gui/calibration/app/__init__.py +0 -0
- pivtools_gui/calibration/app/views.py +1186 -0
- pivtools_gui/calibration/calibration_planar/planar_calibration_production.py +570 -0
- pivtools_gui/calibration/vector_calibration_production.py +544 -0
- pivtools_gui/config.py +703 -0
- pivtools_gui/image_handling/__init__.py +0 -0
- pivtools_gui/image_handling/load_images.py +464 -0
- pivtools_gui/image_handling/readers/__init__.py +53 -0
- pivtools_gui/image_handling/readers/generic_readers.py +50 -0
- pivtools_gui/image_handling/readers/lavision_reader.py +190 -0
- pivtools_gui/image_handling/readers/registry.py +24 -0
- pivtools_gui/masking/__init__.py +0 -0
- pivtools_gui/masking/app/__init__.py +0 -0
- pivtools_gui/masking/app/views.py +123 -0
- pivtools_gui/paths.py +49 -0
- pivtools_gui/piv_runner.py +261 -0
- pivtools_gui/pivtools.py +58 -0
- pivtools_gui/plotting/__init__.py +0 -0
- pivtools_gui/plotting/app/__init__.py +0 -0
- pivtools_gui/plotting/app/views.py +1671 -0
- pivtools_gui/plotting/plot_maker.py +220 -0
- pivtools_gui/post_processing/POD/__init__.py +0 -0
- pivtools_gui/post_processing/POD/app/__init__.py +0 -0
- pivtools_gui/post_processing/POD/app/views.py +647 -0
- pivtools_gui/post_processing/POD/pod_decompose.py +979 -0
- pivtools_gui/post_processing/POD/views.py +1096 -0
- pivtools_gui/post_processing/__init__.py +0 -0
- pivtools_gui/static/404.html +1 -0
- pivtools_gui/static/_next/static/chunks/117-d5793c8e79de5511.js +2 -0
- pivtools_gui/static/_next/static/chunks/484-cfa8b9348ce4f00e.js +1 -0
- pivtools_gui/static/_next/static/chunks/869-320a6b9bdafbb6d3.js +1 -0
- pivtools_gui/static/_next/static/chunks/app/_not-found/page-12f067ceb7415e55.js +1 -0
- pivtools_gui/static/_next/static/chunks/app/layout-b907d5f31ac82e9d.js +1 -0
- pivtools_gui/static/_next/static/chunks/app/page-334cc4e8444cde2f.js +1 -0
- pivtools_gui/static/_next/static/chunks/fd9d1056-ad15f396ddf9b7e5.js +1 -0
- pivtools_gui/static/_next/static/chunks/framework-f66176bb897dc684.js +1 -0
- pivtools_gui/static/_next/static/chunks/main-a1b3ced4d5f6d998.js +1 -0
- pivtools_gui/static/_next/static/chunks/main-app-8a63c6f5e7baee11.js +1 -0
- pivtools_gui/static/_next/static/chunks/pages/_app-72b849fbd24ac258.js +1 -0
- pivtools_gui/static/_next/static/chunks/pages/_error-7ba65e1336b92748.js +1 -0
- pivtools_gui/static/_next/static/chunks/polyfills-42372ed130431b0a.js +1 -0
- pivtools_gui/static/_next/static/chunks/webpack-4a8ca7c99e9bb3d8.js +1 -0
- pivtools_gui/static/_next/static/css/7d3f2337d7ea12a5.css +3 -0
- pivtools_gui/static/_next/static/vQeR20OUdSSKlK4vukC4q/_buildManifest.js +1 -0
- pivtools_gui/static/_next/static/vQeR20OUdSSKlK4vukC4q/_ssgManifest.js +1 -0
- pivtools_gui/static/file.svg +1 -0
- pivtools_gui/static/globe.svg +1 -0
- pivtools_gui/static/grid.svg +8 -0
- pivtools_gui/static/index.html +1 -0
- pivtools_gui/static/index.txt +8 -0
- pivtools_gui/static/next.svg +1 -0
- pivtools_gui/static/vercel.svg +1 -0
- pivtools_gui/static/window.svg +1 -0
- pivtools_gui/stereo_reconstruction/__init__.py +0 -0
- pivtools_gui/stereo_reconstruction/app/__init__.py +0 -0
- pivtools_gui/stereo_reconstruction/app/views.py +1985 -0
- pivtools_gui/stereo_reconstruction/stereo_calibration_production.py +606 -0
- pivtools_gui/stereo_reconstruction/stereo_reconstruction_production.py +544 -0
- pivtools_gui/utils.py +63 -0
- pivtools_gui/vector_loading.py +248 -0
- pivtools_gui/vector_merging/__init__.py +1 -0
- pivtools_gui/vector_merging/app/__init__.py +1 -0
- pivtools_gui/vector_merging/app/views.py +759 -0
- pivtools_gui/vector_statistics/app/__init__.py +1 -0
- pivtools_gui/vector_statistics/app/views.py +710 -0
- pivtools_gui/vector_statistics/ensemble_statistics.py +49 -0
- pivtools_gui/vector_statistics/instantaneous_statistics.py +311 -0
- pivtools_gui/video_maker/__init__.py +0 -0
- pivtools_gui/video_maker/app/__init__.py +0 -0
- pivtools_gui/video_maker/app/views.py +436 -0
- pivtools_gui/video_maker/video_maker.py +662 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[484],{3581:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("camera",[["path",{d:"M14.5 4h-5L7 7H4a2 2 0 0 0-2 2v9a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V9a2 2 0 0 0-2-2h-3l-2.5-3z",key:"1tc9qg"}],["circle",{cx:"12",cy:"13",r:"3",key:"1vg3eu"}]])},401:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]])},875:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("chevron-down",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]])},407:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]])},2135:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("chevron-up",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]])},1671:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("circle-check-big",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]])},5685:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("circle-question-mark",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]])},9388:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("circle-x",[["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"}]])},4822:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("cpu",[["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M17 20v2",key:"1rnc9c"}],["path",{d:"M17 2v2",key:"11trls"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M2 17h2",key:"7oei6x"}],["path",{d:"M2 7h2",key:"asdhe0"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"M20 17h2",key:"1fpfkl"}],["path",{d:"M20 7h2",key:"1o8tra"}],["path",{d:"M7 20v2",key:"4gnj0m"}],["path",{d:"M7 2v2",key:"1i4yhu"}],["rect",{x:"4",y:"4",width:"16",height:"16",rx:"2",key:"1vbyd7"}],["rect",{x:"8",y:"8",width:"8",height:"8",rx:"1",key:"z9xiuo"}]])},2735:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("download",[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]])},4924:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]])},3577:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("funnel",[["path",{d:"M10 20a1 1 0 0 0 .553.895l2 1A1 1 0 0 0 14 21v-7a2 2 0 0 1 .517-1.341L21.74 4.67A1 1 0 0 0 21 3H3a1 1 0 0 0-.742 1.67l7.225 7.989A2 2 0 0 1 10 14z",key:"sc7q7i"}]])},5135:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("github",[["path",{d:"M15 22v-4a4.8 4.8 0 0 0-1-3.5c3 0 6-2 6-5.5.08-1.25-.27-2.48-1-3.5.28-1.15.28-2.35 0-3.5 0 0-1 0-3 1.5-2.64-.5-5.36-.5-8 0C6 2 5 2 5 2c-.3 1.15-.3 2.35 0 3.5A5.403 5.403 0 0 0 4 9c0 3.5 3 5.5 6 5.5-.39.49-.68 1.05-.85 1.65-.17.6-.22 1.23-.15 1.85v4",key:"tonef"}],["path",{d:"M9 18c-4.51 2-5-2-7-2",key:"9comsn"}]])},4428:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("hard-drive",[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["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"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]])},3113:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("image",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]])},1817:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("loader-circle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]])},8293:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("menu",[["path",{d:"M4 12h16",key:"1lakjw"}],["path",{d:"M4 18h16",key:"19g7jn"}],["path",{d:"M4 6h16",key:"1o0s65"}]])},1047:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("minus",[["path",{d:"M5 12h14",key:"1ays0h"}]])},3276:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("play",[["polygon",{points:"6 3 20 12 6 21 6 3",key:"1oa8hb"}]])},9397:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]])},2636:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("refresh-ccw",[["path",{d:"M21 12a9 9 0 0 0-9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"14sxne"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}],["path",{d:"M3 12a9 9 0 0 0 9 9 9.75 9.75 0 0 0 6.74-2.74L21 16",key:"1hlbsb"}],["path",{d:"M16 16h5v5",key:"ccwih5"}]])},3229:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("save",[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]])},8728:function(t,e,n){n.d(e,{Z:function(){return i}});let i=(0,n(9205).Z)("settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]])},2484:function(t,e,n){n.d(e,{u:function(){return i}});function i(t,[e,n]){return Math.min(n,Math.max(e,t))}},9114:function(t,e,n){n.d(e,{gm:function(){return o}});var i=n(2265);n(7437);var r=i.createContext(void 0);function o(t){let e=i.useContext(r);return t||e||"ltr"}},9255:function(t,e,n){n.d(e,{M:function(){return l}});var i,r=n(2265),o=n(1188),a=(i||(i=n.t(r,2)))[" useId ".trim().toString()]||(()=>void 0),s=0;function l(t){let[e,n]=r.useState(a());return(0,o.b)(()=>{t||n(t=>t??String(s++))},[t]),t||(e?`radix-${e}`:"")}},6394:function(t,e,n){n.d(e,{f:function(){return s}});var i=n(2265),r=n(6840),o=n(7437),a=i.forwardRef((t,e)=>(0,o.jsx)(r.WV.label,{...t,ref:e,onMouseDown:e=>{var n;e.target.closest("button, input, select, textarea")||(null===(n=t.onMouseDown)||void 0===n||n.call(t,e),!e.defaultPrevented&&e.detail>1&&e.preventDefault())}}));a.displayName="Label";var s=a},9930:function(t,e,n){let i;n.d(e,{VY:function(){return ig},ZA:function(){return iw},JO:function(){return im},ck:function(){return ib},wU:function(){return iT},eT:function(){return iS},__:function(){return ix},h_:function(){return iv},fC:function(){return id},$G:function(){return iE},u_:function(){return iP},Z0:function(){return iA},xz:function(){return ih},B4:function(){return ip},l_:function(){return iy}});var r,o,a,s,l,u,c,d,h=n(2265),f=n(4887),p=n(2484);function m(t,e,{checkForDefaultPrevented:n=!0}={}){return function(i){if(t?.(i),!1===n||!i.defaultPrevented)return e?.(i)}}"undefined"!=typeof window&&window.document&&window.document.createElement;var v=n(8068),g=n(8575),y=n(3966),w=n(9114),x=n(6840),b=n(6606),S=n(1096),T=n(7437),P="dismissableLayer.update",E=h.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),A=h.forwardRef((t,e)=>{var n,i;let{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:s,onInteractOutside:l,onDismiss:u,...d}=t,f=h.useContext(E),[p,v]=h.useState(null),y=null!==(i=null==p?void 0:p.ownerDocument)&&void 0!==i?i:null===(n=globalThis)||void 0===n?void 0:n.document,[,w]=h.useState({}),A=(0,g.e)(e,t=>v(t)),k=Array.from(f.layers),[R]=[...f.layersWithOutsidePointerEventsDisabled].slice(-1),D=k.indexOf(R),V=p?k.indexOf(p):-1,L=f.layersWithOutsidePointerEventsDisabled.size>0,j=V>=D,F=function(t){var e;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null===(e=globalThis)||void 0===e?void 0:e.document,i=(0,b.W)(t),r=h.useRef(!1),o=h.useRef(()=>{});return h.useEffect(()=>{let t=t=>{if(t.target&&!r.current){let e=function(){C("dismissableLayer.pointerDownOutside",i,r,{discrete:!0})},r={originalEvent:t};"touch"===t.pointerType?(n.removeEventListener("click",o.current),o.current=e,n.addEventListener("click",o.current,{once:!0})):e()}else n.removeEventListener("click",o.current);r.current=!1},e=window.setTimeout(()=>{n.addEventListener("pointerdown",t)},0);return()=>{window.clearTimeout(e),n.removeEventListener("pointerdown",t),n.removeEventListener("click",o.current)}},[n,i]),{onPointerDownCapture:()=>r.current=!0}}(t=>{let e=t.target,n=[...f.branches].some(t=>t.contains(e));!j||n||(null==a||a(t),null==l||l(t),t.defaultPrevented||null==u||u())},y),I=function(t){var e;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null===(e=globalThis)||void 0===e?void 0:e.document,i=(0,b.W)(t),r=h.useRef(!1);return h.useEffect(()=>{let t=t=>{t.target&&!r.current&&C("dismissableLayer.focusOutside",i,{originalEvent:t},{discrete:!1})};return n.addEventListener("focusin",t),()=>n.removeEventListener("focusin",t)},[n,i]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}(t=>{let e=t.target;[...f.branches].some(t=>t.contains(e))||(null==s||s(t),null==l||l(t),t.defaultPrevented||null==u||u())},y);return(0,S.e)(t=>{V!==f.layers.size-1||(null==o||o(t),!t.defaultPrevented&&u&&(t.preventDefault(),u()))},y),h.useEffect(()=>{if(p)return r&&(0===f.layersWithOutsidePointerEventsDisabled.size&&(c=y.body.style.pointerEvents,y.body.style.pointerEvents="none"),f.layersWithOutsidePointerEventsDisabled.add(p)),f.layers.add(p),M(),()=>{r&&1===f.layersWithOutsidePointerEventsDisabled.size&&(y.body.style.pointerEvents=c)}},[p,y,r,f]),h.useEffect(()=>()=>{p&&(f.layers.delete(p),f.layersWithOutsidePointerEventsDisabled.delete(p),M())},[p,f]),h.useEffect(()=>{let t=()=>w({});return document.addEventListener(P,t),()=>document.removeEventListener(P,t)},[]),(0,T.jsx)(x.WV.div,{...d,ref:A,style:{pointerEvents:L?j?"auto":"none":void 0,...t.style},onFocusCapture:m(t.onFocusCapture,I.onFocusCapture),onBlurCapture:m(t.onBlurCapture,I.onBlurCapture),onPointerDownCapture:m(t.onPointerDownCapture,F.onPointerDownCapture)})});function M(){let t=new CustomEvent(P);document.dispatchEvent(t)}function C(t,e,n,i){let{discrete:r}=i,o=n.originalEvent.target,a=new CustomEvent(t,{bubbles:!1,cancelable:!0,detail:n});e&&o.addEventListener(t,e,{once:!0}),r?(0,x.jH)(o,a):o.dispatchEvent(a)}A.displayName="DismissableLayer",h.forwardRef((t,e)=>{let n=h.useContext(E),i=h.useRef(null),r=(0,g.e)(e,i);return h.useEffect(()=>{let t=i.current;if(t)return n.branches.add(t),()=>{n.branches.delete(t)}},[n.branches]),(0,T.jsx)(x.WV.div,{...t,ref:r})}).displayName="DismissableLayerBranch";var k=0;function R(){let t=document.createElement("span");return t.setAttribute("data-radix-focus-guard",""),t.tabIndex=0,t.style.outline="none",t.style.opacity="0",t.style.position="fixed",t.style.pointerEvents="none",t}var D="focusScope.autoFocusOnMount",V="focusScope.autoFocusOnUnmount",L={bubbles:!1,cancelable:!0},j=h.forwardRef((t,e)=>{let{loop:n=!1,trapped:i=!1,onMountAutoFocus:r,onUnmountAutoFocus:o,...a}=t,[s,l]=h.useState(null),u=(0,b.W)(r),c=(0,b.W)(o),d=h.useRef(null),f=(0,g.e)(e,t=>l(t)),p=h.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;h.useEffect(()=>{if(i){let t=function(t){if(p.paused||!s)return;let e=t.target;s.contains(e)?d.current=e:O(d.current,{select:!0})},e=function(t){if(p.paused||!s)return;let e=t.relatedTarget;null===e||s.contains(e)||O(d.current,{select:!0})};document.addEventListener("focusin",t),document.addEventListener("focusout",e);let n=new MutationObserver(function(t){if(document.activeElement===document.body)for(let e of t)e.removedNodes.length>0&&O(s)});return s&&n.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",t),document.removeEventListener("focusout",e),n.disconnect()}}},[i,s,p.paused]),h.useEffect(()=>{if(s){B.add(p);let t=document.activeElement;if(!s.contains(t)){let e=new CustomEvent(D,L);s.addEventListener(D,u),s.dispatchEvent(e),e.defaultPrevented||(function(t){let{select:e=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=document.activeElement;for(let i of t)if(O(i,{select:e}),document.activeElement!==n)return}(F(s).filter(t=>"A"!==t.tagName),{select:!0}),document.activeElement===t&&O(s))}return()=>{s.removeEventListener(D,u),setTimeout(()=>{let e=new CustomEvent(V,L);s.addEventListener(V,c),s.dispatchEvent(e),e.defaultPrevented||O(null!=t?t:document.body,{select:!0}),s.removeEventListener(V,c),B.remove(p)},0)}}},[s,u,c,p]);let m=h.useCallback(t=>{if(!n&&!i||p.paused)return;let e="Tab"===t.key&&!t.altKey&&!t.ctrlKey&&!t.metaKey,r=document.activeElement;if(e&&r){let e=t.currentTarget,[i,o]=function(t){let e=F(t);return[I(e,t),I(e.reverse(),t)]}(e);i&&o?t.shiftKey||r!==o?t.shiftKey&&r===i&&(t.preventDefault(),n&&O(o,{select:!0})):(t.preventDefault(),n&&O(i,{select:!0})):r===e&&t.preventDefault()}},[n,i,p.paused]);return(0,T.jsx)(x.WV.div,{tabIndex:-1,...a,ref:f,onKeyDown:m})});function F(t){let e=[],n=document.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,{acceptNode:t=>{let e="INPUT"===t.tagName&&"hidden"===t.type;return t.disabled||t.hidden||e?NodeFilter.FILTER_SKIP:t.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)e.push(n.currentNode);return e}function I(t,e){for(let n of t)if(!function(t,e){let{upTo:n}=e;if("hidden"===getComputedStyle(t).visibility)return!0;for(;t&&(void 0===n||t!==n);){if("none"===getComputedStyle(t).display)return!0;t=t.parentElement}return!1}(n,{upTo:e}))return n}function O(t){let{select:e=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(t&&t.focus){var n;let i=document.activeElement;t.focus({preventScroll:!0}),t!==i&&(n=t)instanceof HTMLInputElement&&"select"in n&&e&&t.select()}}j.displayName="FocusScope";var B=(i=[],{add(t){let e=i[0];t!==e&&(null==e||e.pause()),(i=N(i,t)).unshift(t)},remove(t){var e;null===(e=(i=N(i,t))[0])||void 0===e||e.resume()}});function N(t,e){let n=[...t],i=n.indexOf(e);return -1!==i&&n.splice(i,1),n}var W=n(9255);let U=["top","right","bottom","left"],H=Math.min,z=Math.max,Z=Math.round,_=Math.floor,K=t=>({x:t,y:t}),$={left:"right",right:"left",bottom:"top",top:"bottom"},Y={start:"end",end:"start"};function X(t,e){return"function"==typeof t?t(e):t}function q(t){return t.split("-")[0]}function G(t){return t.split("-")[1]}function J(t){return"x"===t?"y":"x"}function Q(t){return"y"===t?"height":"width"}let tt=new Set(["top","bottom"]);function te(t){return tt.has(q(t))?"y":"x"}function tn(t){return t.replace(/start|end/g,t=>Y[t])}let ti=["left","right"],tr=["right","left"],to=["top","bottom"],ta=["bottom","top"];function ts(t){return t.replace(/left|right|bottom|top/g,t=>$[t])}function tl(t){return"number"!=typeof t?{top:0,right:0,bottom:0,left:0,...t}:{top:t,right:t,bottom:t,left:t}}function tu(t){let{x:e,y:n,width:i,height:r}=t;return{width:i,height:r,top:n,left:e,right:e+i,bottom:n+r,x:e,y:n}}function tc(t,e,n){let i,{reference:r,floating:o}=t,a=te(e),s=J(te(e)),l=Q(s),u=q(e),c="y"===a,d=r.x+r.width/2-o.width/2,h=r.y+r.height/2-o.height/2,f=r[l]/2-o[l]/2;switch(u){case"top":i={x:d,y:r.y-o.height};break;case"bottom":i={x:d,y:r.y+r.height};break;case"right":i={x:r.x+r.width,y:h};break;case"left":i={x:r.x-o.width,y:h};break;default:i={x:r.x,y:r.y}}switch(G(e)){case"start":i[s]-=f*(n&&c?-1:1);break;case"end":i[s]+=f*(n&&c?-1:1)}return i}let td=async(t,e,n)=>{let{placement:i="bottom",strategy:r="absolute",middleware:o=[],platform:a}=n,s=o.filter(Boolean),l=await (null==a.isRTL?void 0:a.isRTL(e)),u=await a.getElementRects({reference:t,floating:e,strategy:r}),{x:c,y:d}=tc(u,i,l),h=i,f={},p=0;for(let n=0;n<s.length;n++){let{name:o,fn:m}=s[n],{x:v,y:g,data:y,reset:w}=await m({x:c,y:d,initialPlacement:i,placement:h,strategy:r,middlewareData:f,rects:u,platform:a,elements:{reference:t,floating:e}});c=null!=v?v:c,d=null!=g?g:d,f={...f,[o]:{...f[o],...y}},w&&p<=50&&(p++,"object"==typeof w&&(w.placement&&(h=w.placement),w.rects&&(u=!0===w.rects?await a.getElementRects({reference:t,floating:e,strategy:r}):w.rects),{x:c,y:d}=tc(u,h,l)),n=-1)}return{x:c,y:d,placement:h,strategy:r,middlewareData:f}};async function th(t,e){var n;void 0===e&&(e={});let{x:i,y:r,platform:o,rects:a,elements:s,strategy:l}=t,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:h=!1,padding:f=0}=X(e,t),p=tl(f),m=s[h?"floating"===d?"reference":"floating":d],v=tu(await o.getClippingRect({element:null==(n=await (null==o.isElement?void 0:o.isElement(m)))||n?m:m.contextElement||await (null==o.getDocumentElement?void 0:o.getDocumentElement(s.floating)),boundary:u,rootBoundary:c,strategy:l})),g="floating"===d?{x:i,y:r,width:a.floating.width,height:a.floating.height}:a.reference,y=await (null==o.getOffsetParent?void 0:o.getOffsetParent(s.floating)),w=await (null==o.isElement?void 0:o.isElement(y))&&await (null==o.getScale?void 0:o.getScale(y))||{x:1,y:1},x=tu(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:g,offsetParent:y,strategy:l}):g);return{top:(v.top-x.top+p.top)/w.y,bottom:(x.bottom-v.bottom+p.bottom)/w.y,left:(v.left-x.left+p.left)/w.x,right:(x.right-v.right+p.right)/w.x}}function tf(t,e){return{top:t.top-e.height,right:t.right-e.width,bottom:t.bottom-e.height,left:t.left-e.width}}function tp(t){return U.some(e=>t[e]>=0)}let tm=new Set(["left","top"]);async function tv(t,e){let{placement:n,platform:i,elements:r}=t,o=await (null==i.isRTL?void 0:i.isRTL(r.floating)),a=q(n),s=G(n),l="y"===te(n),u=tm.has(a)?-1:1,c=o&&l?-1:1,d=X(e,t),{mainAxis:h,crossAxis:f,alignmentAxis:p}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&"number"==typeof p&&(f="end"===s?-1*p:p),l?{x:f*c,y:h*u}:{x:h*u,y:f*c}}function tg(){return"undefined"!=typeof window}function ty(t){return tb(t)?(t.nodeName||"").toLowerCase():"#document"}function tw(t){var e;return(null==t||null==(e=t.ownerDocument)?void 0:e.defaultView)||window}function tx(t){var e;return null==(e=(tb(t)?t.ownerDocument:t.document)||window.document)?void 0:e.documentElement}function tb(t){return!!tg()&&(t instanceof Node||t instanceof tw(t).Node)}function tS(t){return!!tg()&&(t instanceof Element||t instanceof tw(t).Element)}function tT(t){return!!tg()&&(t instanceof HTMLElement||t instanceof tw(t).HTMLElement)}function tP(t){return!!tg()&&"undefined"!=typeof ShadowRoot&&(t instanceof ShadowRoot||t instanceof tw(t).ShadowRoot)}let tE=new Set(["inline","contents"]);function tA(t){let{overflow:e,overflowX:n,overflowY:i,display:r}=tO(t);return/auto|scroll|overlay|hidden|clip/.test(e+i+n)&&!tE.has(r)}let tM=new Set(["table","td","th"]),tC=[":popover-open",":modal"];function tk(t){return tC.some(e=>{try{return t.matches(e)}catch(t){return!1}})}let tR=["transform","translate","scale","rotate","perspective"],tD=["transform","translate","scale","rotate","perspective","filter"],tV=["paint","layout","strict","content"];function tL(t){let e=tj(),n=tS(t)?tO(t):t;return tR.some(t=>!!n[t]&&"none"!==n[t])||!!n.containerType&&"normal"!==n.containerType||!e&&!!n.backdropFilter&&"none"!==n.backdropFilter||!e&&!!n.filter&&"none"!==n.filter||tD.some(t=>(n.willChange||"").includes(t))||tV.some(t=>(n.contain||"").includes(t))}function tj(){return"undefined"!=typeof CSS&&!!CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")}let tF=new Set(["html","body","#document"]);function tI(t){return tF.has(ty(t))}function tO(t){return tw(t).getComputedStyle(t)}function tB(t){return tS(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function tN(t){if("html"===ty(t))return t;let e=t.assignedSlot||t.parentNode||tP(t)&&t.host||tx(t);return tP(e)?e.host:e}function tW(t,e,n){var i;void 0===e&&(e=[]),void 0===n&&(n=!0);let r=function t(e){let n=tN(e);return tI(n)?e.ownerDocument?e.ownerDocument.body:e.body:tT(n)&&tA(n)?n:t(n)}(t),o=r===(null==(i=t.ownerDocument)?void 0:i.body),a=tw(r);if(o){let t=tU(a);return e.concat(a,a.visualViewport||[],tA(r)?r:[],t&&n?tW(t):[])}return e.concat(r,tW(r,[],n))}function tU(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function tH(t){let e=tO(t),n=parseFloat(e.width)||0,i=parseFloat(e.height)||0,r=tT(t),o=r?t.offsetWidth:n,a=r?t.offsetHeight:i,s=Z(n)!==o||Z(i)!==a;return s&&(n=o,i=a),{width:n,height:i,$:s}}function tz(t){return tS(t)?t:t.contextElement}function tZ(t){let e=tz(t);if(!tT(e))return K(1);let n=e.getBoundingClientRect(),{width:i,height:r,$:o}=tH(e),a=(o?Z(n.width):n.width)/i,s=(o?Z(n.height):n.height)/r;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}let t_=K(0);function tK(t){let e=tw(t);return tj()&&e.visualViewport?{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}:t_}function t$(t,e,n,i){var r;void 0===e&&(e=!1),void 0===n&&(n=!1);let o=t.getBoundingClientRect(),a=tz(t),s=K(1);e&&(i?tS(i)&&(s=tZ(i)):s=tZ(t));let l=(void 0===(r=n)&&(r=!1),i&&(!r||i===tw(a))&&r)?tK(a):K(0),u=(o.left+l.x)/s.x,c=(o.top+l.y)/s.y,d=o.width/s.x,h=o.height/s.y;if(a){let t=tw(a),e=i&&tS(i)?tw(i):i,n=t,r=tU(n);for(;r&&i&&e!==n;){let t=tZ(r),e=r.getBoundingClientRect(),i=tO(r),o=e.left+(r.clientLeft+parseFloat(i.paddingLeft))*t.x,a=e.top+(r.clientTop+parseFloat(i.paddingTop))*t.y;u*=t.x,c*=t.y,d*=t.x,h*=t.y,u+=o,c+=a,r=tU(n=tw(r))}}return tu({width:d,height:h,x:u,y:c})}function tY(t,e){let n=tB(t).scrollLeft;return e?e.left+n:t$(tx(t)).left+n}function tX(t,e,n){void 0===n&&(n=!1);let i=t.getBoundingClientRect();return{x:i.left+e.scrollLeft-(n?0:tY(t,i)),y:i.top+e.scrollTop}}let tq=new Set(["absolute","fixed"]);function tG(t,e,n){let i;if("viewport"===e)i=function(t,e){let n=tw(t),i=tx(t),r=n.visualViewport,o=i.clientWidth,a=i.clientHeight,s=0,l=0;if(r){o=r.width,a=r.height;let t=tj();(!t||t&&"fixed"===e)&&(s=r.offsetLeft,l=r.offsetTop)}return{width:o,height:a,x:s,y:l}}(t,n);else if("document"===e)i=function(t){let e=tx(t),n=tB(t),i=t.ownerDocument.body,r=z(e.scrollWidth,e.clientWidth,i.scrollWidth,i.clientWidth),o=z(e.scrollHeight,e.clientHeight,i.scrollHeight,i.clientHeight),a=-n.scrollLeft+tY(t),s=-n.scrollTop;return"rtl"===tO(i).direction&&(a+=z(e.clientWidth,i.clientWidth)-r),{width:r,height:o,x:a,y:s}}(tx(t));else if(tS(e))i=function(t,e){let n=t$(t,!0,"fixed"===e),i=n.top+t.clientTop,r=n.left+t.clientLeft,o=tT(t)?tZ(t):K(1),a=t.clientWidth*o.x;return{width:a,height:t.clientHeight*o.y,x:r*o.x,y:i*o.y}}(e,n);else{let n=tK(t);i={x:e.x-n.x,y:e.y-n.y,width:e.width,height:e.height}}return tu(i)}function tJ(t){return"static"===tO(t).position}function tQ(t,e){if(!tT(t)||"fixed"===tO(t).position)return null;if(e)return e(t);let n=t.offsetParent;return tx(t)===n&&(n=n.ownerDocument.body),n}function t0(t,e){var n;let i=tw(t);if(tk(t))return i;if(!tT(t)){let e=tN(t);for(;e&&!tI(e);){if(tS(e)&&!tJ(e))return e;e=tN(e)}return i}let r=tQ(t,e);for(;r&&(n=r,tM.has(ty(n)))&&tJ(r);)r=tQ(r,e);return r&&tI(r)&&tJ(r)&&!tL(r)?i:r||function(t){let e=tN(t);for(;tT(e)&&!tI(e);){if(tL(e))return e;if(tk(e))break;e=tN(e)}return null}(t)||i}let t1=async function(t){let e=this.getOffsetParent||t0,n=this.getDimensions,i=await n(t.floating);return{reference:function(t,e,n){let i=tT(e),r=tx(e),o="fixed"===n,a=t$(t,!0,o,e),s={scrollLeft:0,scrollTop:0},l=K(0);if(i||!i&&!o){if(("body"!==ty(e)||tA(r))&&(s=tB(e)),i){let t=t$(e,!0,o,e);l.x=t.x+e.clientLeft,l.y=t.y+e.clientTop}else r&&(l.x=tY(r))}o&&!i&&r&&(l.x=tY(r));let u=!r||i||o?K(0):tX(r,s);return{x:a.left+s.scrollLeft-l.x-u.x,y:a.top+s.scrollTop-l.y-u.y,width:a.width,height:a.height}}(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:i.width,height:i.height}}},t2={convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{elements:e,rect:n,offsetParent:i,strategy:r}=t,o="fixed"===r,a=tx(i),s=!!e&&tk(e.floating);if(i===a||s&&o)return n;let l={scrollLeft:0,scrollTop:0},u=K(1),c=K(0),d=tT(i);if((d||!d&&!o)&&(("body"!==ty(i)||tA(a))&&(l=tB(i)),tT(i))){let t=t$(i);u=tZ(i),c.x=t.x+i.clientLeft,c.y=t.y+i.clientTop}let h=!a||d||o?K(0):tX(a,l,!0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-l.scrollLeft*u.x+c.x+h.x,y:n.y*u.y-l.scrollTop*u.y+c.y+h.y}},getDocumentElement:tx,getClippingRect:function(t){let{element:e,boundary:n,rootBoundary:i,strategy:r}=t,o=[..."clippingAncestors"===n?tk(e)?[]:function(t,e){let n=e.get(t);if(n)return n;let i=tW(t,[],!1).filter(t=>tS(t)&&"body"!==ty(t)),r=null,o="fixed"===tO(t).position,a=o?tN(t):t;for(;tS(a)&&!tI(a);){let e=tO(a),n=tL(a);n||"fixed"!==e.position||(r=null),(o?!n&&!r:!n&&"static"===e.position&&!!r&&tq.has(r.position)||tA(a)&&!n&&function t(e,n){let i=tN(e);return!(i===n||!tS(i)||tI(i))&&("fixed"===tO(i).position||t(i,n))}(t,a))?i=i.filter(t=>t!==a):r=e,a=tN(a)}return e.set(t,i),i}(e,this._c):[].concat(n),i],a=o[0],s=o.reduce((t,n)=>{let i=tG(e,n,r);return t.top=z(i.top,t.top),t.right=H(i.right,t.right),t.bottom=H(i.bottom,t.bottom),t.left=z(i.left,t.left),t},tG(e,a,r));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:t0,getElementRects:t1,getClientRects:function(t){return Array.from(t.getClientRects())},getDimensions:function(t){let{width:e,height:n}=tH(t);return{width:e,height:n}},getScale:tZ,isElement:tS,isRTL:function(t){return"rtl"===tO(t).direction}};function t5(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}let t3=t=>({name:"arrow",options:t,async fn(e){let{x:n,y:i,placement:r,rects:o,platform:a,elements:s,middlewareData:l}=e,{element:u,padding:c=0}=X(t,e)||{};if(null==u)return{};let d=tl(c),h={x:n,y:i},f=J(te(r)),p=Q(f),m=await a.getDimensions(u),v="y"===f,g=v?"clientHeight":"clientWidth",y=o.reference[p]+o.reference[f]-h[f]-o.floating[p],w=h[f]-o.reference[f],x=await (null==a.getOffsetParent?void 0:a.getOffsetParent(u)),b=x?x[g]:0;b&&await (null==a.isElement?void 0:a.isElement(x))||(b=s.floating[g]||o.floating[p]);let S=b/2-m[p]/2-1,T=H(d[v?"top":"left"],S),P=H(d[v?"bottom":"right"],S),E=b-m[p]-P,A=b/2-m[p]/2+(y/2-w/2),M=z(T,H(A,E)),C=!l.arrow&&null!=G(r)&&A!==M&&o.reference[p]/2-(A<T?T:P)-m[p]/2<0,k=C?A<T?A-T:A-E:0;return{[f]:h[f]+k,data:{[f]:M,centerOffset:A-M-k,...C&&{alignmentOffset:k}},reset:C}}}),t6=(t,e,n)=>{let i=new Map,r={platform:t2,...n},o={...r.platform,_c:i};return td(t,e,{...r,platform:o})};var t9="undefined"!=typeof document?h.useLayoutEffect:function(){};function t4(t,e){let n,i,r;if(t===e)return!0;if(typeof t!=typeof e)return!1;if("function"==typeof t&&t.toString()===e.toString())return!0;if(t&&e&&"object"==typeof t){if(Array.isArray(t)){if((n=t.length)!==e.length)return!1;for(i=n;0!=i--;)if(!t4(t[i],e[i]))return!1;return!0}if((n=(r=Object.keys(t)).length)!==Object.keys(e).length)return!1;for(i=n;0!=i--;)if(!({}).hasOwnProperty.call(e,r[i]))return!1;for(i=n;0!=i--;){let n=r[i];if(("_owner"!==n||!t.$$typeof)&&!t4(t[n],e[n]))return!1}return!0}return t!=t&&e!=e}function t7(t){return"undefined"==typeof window?1:(t.ownerDocument.defaultView||window).devicePixelRatio||1}function t8(t,e){let n=t7(t);return Math.round(e*n)/n}function et(t){let e=h.useRef(t);return t9(()=>{e.current=t}),e}let ee=t=>({name:"arrow",options:t,fn(e){let{element:n,padding:i}="function"==typeof t?t(e):t;return n&&({}).hasOwnProperty.call(n,"current")?null!=n.current?t3({element:n.current,padding:i}).fn(e):{}:n?t3({element:n,padding:i}).fn(e):{}}}),en=(t,e)=>{var n;return{...(void 0===(n=t)&&(n=0),{name:"offset",options:n,async fn(t){var e,i;let{x:r,y:o,placement:a,middlewareData:s}=t,l=await tv(t,n);return a===(null==(e=s.offset)?void 0:e.placement)&&null!=(i=s.arrow)&&i.alignmentOffset?{}:{x:r+l.x,y:o+l.y,data:{...l,placement:a}}}}),options:[t,e]}},ei=(t,e)=>{var n;return{...(void 0===(n=t)&&(n={}),{name:"shift",options:n,async fn(t){let{x:e,y:i,placement:r}=t,{mainAxis:o=!0,crossAxis:a=!1,limiter:s={fn:t=>{let{x:e,y:n}=t;return{x:e,y:n}}},...l}=X(n,t),u={x:e,y:i},c=await th(t,l),d=te(q(r)),h=J(d),f=u[h],p=u[d];if(o){let t="y"===h?"top":"left",e="y"===h?"bottom":"right",n=f+c[t],i=f-c[e];f=z(n,H(f,i))}if(a){let t="y"===d?"top":"left",e="y"===d?"bottom":"right",n=p+c[t],i=p-c[e];p=z(n,H(p,i))}let m=s.fn({...t,[h]:f,[d]:p});return{...m,data:{x:m.x-e,y:m.y-i,enabled:{[h]:o,[d]:a}}}}}),options:[t,e]}},er=(t,e)=>{var n;return{...(void 0===(n=t)&&(n={}),{options:n,fn(t){let{x:e,y:i,placement:r,rects:o,middlewareData:a}=t,{offset:s=0,mainAxis:l=!0,crossAxis:u=!0}=X(n,t),c={x:e,y:i},d=te(r),h=J(d),f=c[h],p=c[d],m=X(s,t),v="number"==typeof m?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(l){let t="y"===h?"height":"width",e=o.reference[h]-o.floating[t]+v.mainAxis,n=o.reference[h]+o.reference[t]-v.mainAxis;f<e?f=e:f>n&&(f=n)}if(u){var g,y;let t="y"===h?"width":"height",e=tm.has(q(r)),n=o.reference[d]-o.floating[t]+(e&&(null==(g=a.offset)?void 0:g[d])||0)+(e?0:v.crossAxis),i=o.reference[d]+o.reference[t]+(e?0:(null==(y=a.offset)?void 0:y[d])||0)-(e?v.crossAxis:0);p<n?p=n:p>i&&(p=i)}return{[h]:f,[d]:p}}}),options:[t,e]}},eo=(t,e)=>{var n;return{...(void 0===(n=t)&&(n={}),{name:"flip",options:n,async fn(t){var e,i,r,o,a;let{placement:s,middlewareData:l,rects:u,initialPlacement:c,platform:d,elements:h}=t,{mainAxis:f=!0,crossAxis:p=!0,fallbackPlacements:m,fallbackStrategy:v="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:y=!0,...w}=X(n,t);if(null!=(e=l.arrow)&&e.alignmentOffset)return{};let x=q(s),b=te(c),S=q(c)===c,T=await (null==d.isRTL?void 0:d.isRTL(h.floating)),P=m||(S||!y?[ts(c)]:function(t){let e=ts(t);return[tn(t),e,tn(e)]}(c)),E="none"!==g;!m&&E&&P.push(...function(t,e,n,i){let r=G(t),o=function(t,e,n){switch(t){case"top":case"bottom":if(n)return e?tr:ti;return e?ti:tr;case"left":case"right":return e?to:ta;default:return[]}}(q(t),"start"===n,i);return r&&(o=o.map(t=>t+"-"+r),e&&(o=o.concat(o.map(tn)))),o}(c,y,g,T));let A=[c,...P],M=await th(t,w),C=[],k=(null==(i=l.flip)?void 0:i.overflows)||[];if(f&&C.push(M[x]),p){let t=function(t,e,n){void 0===n&&(n=!1);let i=G(t),r=J(te(t)),o=Q(r),a="x"===r?i===(n?"end":"start")?"right":"left":"start"===i?"bottom":"top";return e.reference[o]>e.floating[o]&&(a=ts(a)),[a,ts(a)]}(s,u,T);C.push(M[t[0]],M[t[1]])}if(k=[...k,{placement:s,overflows:C}],!C.every(t=>t<=0)){let t=((null==(r=l.flip)?void 0:r.index)||0)+1,e=A[t];if(e&&(!("alignment"===p&&b!==te(e))||k.every(t=>t.overflows[0]>0&&te(t.placement)===b)))return{data:{index:t,overflows:k},reset:{placement:e}};let n=null==(o=k.filter(t=>t.overflows[0]<=0).sort((t,e)=>t.overflows[1]-e.overflows[1])[0])?void 0:o.placement;if(!n)switch(v){case"bestFit":{let t=null==(a=k.filter(t=>{if(E){let e=te(t.placement);return e===b||"y"===e}return!0}).map(t=>[t.placement,t.overflows.filter(t=>t>0).reduce((t,e)=>t+e,0)]).sort((t,e)=>t[1]-e[1])[0])?void 0:a[0];t&&(n=t);break}case"initialPlacement":n=c}if(s!==n)return{reset:{placement:n}}}return{}}}),options:[t,e]}},ea=(t,e)=>{var n;return{...(void 0===(n=t)&&(n={}),{name:"size",options:n,async fn(t){var e,i;let r,o;let{placement:a,rects:s,platform:l,elements:u}=t,{apply:c=()=>{},...d}=X(n,t),h=await th(t,d),f=q(a),p=G(a),m="y"===te(a),{width:v,height:g}=s.floating;"top"===f||"bottom"===f?(r=f,o=p===(await (null==l.isRTL?void 0:l.isRTL(u.floating))?"start":"end")?"left":"right"):(o=f,r="end"===p?"top":"bottom");let y=g-h.top-h.bottom,w=v-h.left-h.right,x=H(g-h[r],y),b=H(v-h[o],w),S=!t.middlewareData.shift,T=x,P=b;if(null!=(e=t.middlewareData.shift)&&e.enabled.x&&(P=w),null!=(i=t.middlewareData.shift)&&i.enabled.y&&(T=y),S&&!p){let t=z(h.left,0),e=z(h.right,0),n=z(h.top,0),i=z(h.bottom,0);m?P=v-2*(0!==t||0!==e?t+e:z(h.left,h.right)):T=g-2*(0!==n||0!==i?n+i:z(h.top,h.bottom))}await c({...t,availableWidth:P,availableHeight:T});let E=await l.getDimensions(u.floating);return v!==E.width||g!==E.height?{reset:{rects:!0}}:{}}}),options:[t,e]}},es=(t,e)=>{var n;return{...(void 0===(n=t)&&(n={}),{name:"hide",options:n,async fn(t){let{rects:e}=t,{strategy:i="referenceHidden",...r}=X(n,t);switch(i){case"referenceHidden":{let n=tf(await th(t,{...r,elementContext:"reference"}),e.reference);return{data:{referenceHiddenOffsets:n,referenceHidden:tp(n)}}}case"escaped":{let n=tf(await th(t,{...r,altBoundary:!0}),e.floating);return{data:{escapedOffsets:n,escaped:tp(n)}}}default:return{}}}}),options:[t,e]}},el=(t,e)=>({...ee(t),options:[t,e]});var eu=h.forwardRef((t,e)=>{let{children:n,width:i=10,height:r=5,...o}=t;return(0,T.jsx)(x.WV.svg,{...o,ref:e,width:i,height:r,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:t.asChild?n:(0,T.jsx)("polygon",{points:"0,0 30,0 15,10"})})});eu.displayName="Arrow";var ec=n(1188),ed=n(420),eh="Popper",[ef,ep]=(0,y.b)(eh),[em,ev]=ef(eh),eg=t=>{let{__scopePopper:e,children:n}=t,[i,r]=h.useState(null);return(0,T.jsx)(em,{scope:e,anchor:i,onAnchorChange:r,children:n})};eg.displayName=eh;var ey="PopperAnchor",ew=h.forwardRef((t,e)=>{let{__scopePopper:n,virtualRef:i,...r}=t,o=ev(ey,n),a=h.useRef(null),s=(0,g.e)(e,a),l=h.useRef(null);return h.useEffect(()=>{let t=l.current;l.current=(null==i?void 0:i.current)||a.current,t!==l.current&&o.onAnchorChange(l.current)}),i?null:(0,T.jsx)(x.WV.div,{...r,ref:s})});ew.displayName=ey;var ex="PopperContent",[eb,eS]=ef(ex),eT=h.forwardRef((t,e)=>{var n,i,r,o,a,s,l,u;let{__scopePopper:c,side:d="bottom",sideOffset:p=0,align:m="center",alignOffset:v=0,arrowPadding:y=0,avoidCollisions:w=!0,collisionBoundary:S=[],collisionPadding:P=0,sticky:E="partial",hideWhenDetached:A=!1,updatePositionStrategy:M="optimized",onPlaced:C,...k}=t,R=ev(ex,c),[D,V]=h.useState(null),L=(0,g.e)(e,t=>V(t)),[j,F]=h.useState(null),I=(0,ed.t)(j),O=null!==(l=null==I?void 0:I.width)&&void 0!==l?l:0,B=null!==(u=null==I?void 0:I.height)&&void 0!==u?u:0,N="number"==typeof P?P:{top:0,right:0,bottom:0,left:0,...P},W=Array.isArray(S)?S:[S],U=W.length>0,Z={padding:N,boundary:W.filter(eM),altBoundary:U},{refs:K,floatingStyles:$,placement:Y,isPositioned:X,middlewareData:q}=function(t){void 0===t&&(t={});let{placement:e="bottom",strategy:n="absolute",middleware:i=[],platform:r,elements:{reference:o,floating:a}={},transform:s=!0,whileElementsMounted:l,open:u}=t,[c,d]=h.useState({x:0,y:0,strategy:n,placement:e,middlewareData:{},isPositioned:!1}),[p,m]=h.useState(i);t4(p,i)||m(i);let[v,g]=h.useState(null),[y,w]=h.useState(null),x=h.useCallback(t=>{t!==P.current&&(P.current=t,g(t))},[]),b=h.useCallback(t=>{t!==E.current&&(E.current=t,w(t))},[]),S=o||v,T=a||y,P=h.useRef(null),E=h.useRef(null),A=h.useRef(c),M=null!=l,C=et(l),k=et(r),R=et(u),D=h.useCallback(()=>{if(!P.current||!E.current)return;let t={placement:e,strategy:n,middleware:p};k.current&&(t.platform=k.current),t6(P.current,E.current,t).then(t=>{let e={...t,isPositioned:!1!==R.current};V.current&&!t4(A.current,e)&&(A.current=e,f.flushSync(()=>{d(e)}))})},[p,e,n,k,R]);t9(()=>{!1===u&&A.current.isPositioned&&(A.current.isPositioned=!1,d(t=>({...t,isPositioned:!1})))},[u]);let V=h.useRef(!1);t9(()=>(V.current=!0,()=>{V.current=!1}),[]),t9(()=>{if(S&&(P.current=S),T&&(E.current=T),S&&T){if(C.current)return C.current(S,T,D);D()}},[S,T,D,C,M]);let L=h.useMemo(()=>({reference:P,floating:E,setReference:x,setFloating:b}),[x,b]),j=h.useMemo(()=>({reference:S,floating:T}),[S,T]),F=h.useMemo(()=>{let t={position:n,left:0,top:0};if(!j.floating)return t;let e=t8(j.floating,c.x),i=t8(j.floating,c.y);return s?{...t,transform:"translate("+e+"px, "+i+"px)",...t7(j.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:e,top:i}},[n,s,j.floating,c.x,c.y]);return h.useMemo(()=>({...c,update:D,refs:L,elements:j,floatingStyles:F}),[c,D,L,j,F])}({strategy:"fixed",placement:d+("center"!==m?"-"+m:""),whileElementsMounted:function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];return function(t,e,n,i){let r;void 0===i&&(i={});let{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:s="function"==typeof ResizeObserver,layoutShift:l="function"==typeof IntersectionObserver,animationFrame:u=!1}=i,c=tz(t),d=o||a?[...c?tW(c):[],...tW(e)]:[];d.forEach(t=>{o&&t.addEventListener("scroll",n,{passive:!0}),a&&t.addEventListener("resize",n)});let h=c&&l?function(t,e){let n,i=null,r=tx(t);function o(){var t;clearTimeout(n),null==(t=i)||t.disconnect(),i=null}return!function a(s,l){void 0===s&&(s=!1),void 0===l&&(l=1),o();let u=t.getBoundingClientRect(),{left:c,top:d,width:h,height:f}=u;if(s||e(),!h||!f)return;let p=_(d),m=_(r.clientWidth-(c+h)),v={rootMargin:-p+"px "+-m+"px "+-_(r.clientHeight-(d+f))+"px "+-_(c)+"px",threshold:z(0,H(1,l))||1},g=!0;function y(e){let i=e[0].intersectionRatio;if(i!==l){if(!g)return a();i?a(!1,i):n=setTimeout(()=>{a(!1,1e-7)},1e3)}1!==i||t5(u,t.getBoundingClientRect())||a(),g=!1}try{i=new IntersectionObserver(y,{...v,root:r.ownerDocument})}catch(t){i=new IntersectionObserver(y,v)}i.observe(t)}(!0),o}(c,n):null,f=-1,p=null;s&&(p=new ResizeObserver(t=>{let[i]=t;i&&i.target===c&&p&&(p.unobserve(e),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var t;null==(t=p)||t.observe(e)})),n()}),c&&!u&&p.observe(c),p.observe(e));let m=u?t$(t):null;return u&&function e(){let i=t$(t);m&&!t5(m,i)&&n(),m=i,r=requestAnimationFrame(e)}(),n(),()=>{var t;d.forEach(t=>{o&&t.removeEventListener("scroll",n),a&&t.removeEventListener("resize",n)}),null==h||h(),null==(t=p)||t.disconnect(),p=null,u&&cancelAnimationFrame(r)}}(...e,{animationFrame:"always"===M})},elements:{reference:R.anchor},middleware:[en({mainAxis:p+B,alignmentAxis:v}),w&&ei({mainAxis:!0,crossAxis:!1,limiter:"partial"===E?er():void 0,...Z}),w&&eo({...Z}),ea({...Z,apply:t=>{let{elements:e,rects:n,availableWidth:i,availableHeight:r}=t,{width:o,height:a}=n.reference,s=e.floating.style;s.setProperty("--radix-popper-available-width","".concat(i,"px")),s.setProperty("--radix-popper-available-height","".concat(r,"px")),s.setProperty("--radix-popper-anchor-width","".concat(o,"px")),s.setProperty("--radix-popper-anchor-height","".concat(a,"px"))}}),j&&el({element:j,padding:y}),eC({arrowWidth:O,arrowHeight:B}),A&&es({strategy:"referenceHidden",...Z})]}),[G,J]=ek(Y),Q=(0,b.W)(C);(0,ec.b)(()=>{X&&(null==Q||Q())},[X,Q]);let tt=null===(n=q.arrow)||void 0===n?void 0:n.x,te=null===(i=q.arrow)||void 0===i?void 0:i.y,tn=(null===(r=q.arrow)||void 0===r?void 0:r.centerOffset)!==0,[ti,tr]=h.useState();return(0,ec.b)(()=>{D&&tr(window.getComputedStyle(D).zIndex)},[D]),(0,T.jsx)("div",{ref:K.setFloating,"data-radix-popper-content-wrapper":"",style:{...$,transform:X?$.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ti,"--radix-popper-transform-origin":[null===(o=q.transformOrigin)||void 0===o?void 0:o.x,null===(a=q.transformOrigin)||void 0===a?void 0:a.y].join(" "),...(null===(s=q.hide)||void 0===s?void 0:s.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:t.dir,children:(0,T.jsx)(eb,{scope:c,placedSide:G,onArrowChange:F,arrowX:tt,arrowY:te,shouldHideArrow:tn,children:(0,T.jsx)(x.WV.div,{"data-side":G,"data-align":J,...k,ref:L,style:{...k.style,animation:X?void 0:"none"}})})})});eT.displayName=ex;var eP="PopperArrow",eE={top:"bottom",right:"left",bottom:"top",left:"right"},eA=h.forwardRef(function(t,e){let{__scopePopper:n,...i}=t,r=eS(eP,n),o=eE[r.placedSide];return(0,T.jsx)("span",{ref:r.onArrowChange,style:{position:"absolute",left:r.arrowX,top:r.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[r.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[r.placedSide],visibility:r.shouldHideArrow?"hidden":void 0},children:(0,T.jsx)(eu,{...i,ref:e,style:{...i.style,display:"block"}})})});function eM(t){return null!==t}eA.displayName=eP;var eC=t=>({name:"transformOrigin",options:t,fn(e){var n,i,r,o,a;let{placement:s,rects:l,middlewareData:u}=e,c=(null===(n=u.arrow)||void 0===n?void 0:n.centerOffset)!==0,d=c?0:t.arrowWidth,h=c?0:t.arrowHeight,[f,p]=ek(s),m={start:"0%",center:"50%",end:"100%"}[p],v=(null!==(o=null===(i=u.arrow)||void 0===i?void 0:i.x)&&void 0!==o?o:0)+d/2,g=(null!==(a=null===(r=u.arrow)||void 0===r?void 0:r.y)&&void 0!==a?a:0)+h/2,y="",w="";return"bottom"===f?(y=c?m:"".concat(v,"px"),w="".concat(-h,"px")):"top"===f?(y=c?m:"".concat(v,"px"),w="".concat(l.floating.height+h,"px")):"right"===f?(y="".concat(-h,"px"),w=c?m:"".concat(g,"px")):"left"===f&&(y="".concat(l.floating.width+h,"px"),w=c?m:"".concat(g,"px")),{data:{x:y,y:w}}}});function ek(t){let[e,n="center"]=t.split("-");return[e,n]}var eR=n(3832),eD=n(7053),eV=n(886),eL=n(6718),ej=n(5098),eF=new WeakMap,eI=new WeakMap,eO={},eB=0,eN=function(t){return t&&(t.host||eN(t.parentNode))},eW=function(t,e,n,i){var r=(Array.isArray(t)?t:[t]).map(function(t){if(e.contains(t))return t;var n=eN(t);return n&&e.contains(n)?n:(console.error("aria-hidden",t,"in not contained inside",e,". Doing nothing"),null)}).filter(function(t){return!!t});eO[n]||(eO[n]=new WeakMap);var o=eO[n],a=[],s=new Set,l=new Set(r),u=function(t){!t||s.has(t)||(s.add(t),u(t.parentNode))};r.forEach(u);var c=function(t){!t||l.has(t)||Array.prototype.forEach.call(t.children,function(t){if(s.has(t))c(t);else try{var e=t.getAttribute(i),r=null!==e&&"false"!==e,l=(eF.get(t)||0)+1,u=(o.get(t)||0)+1;eF.set(t,l),o.set(t,u),a.push(t),1===l&&r&&eI.set(t,!0),1===u&&t.setAttribute(n,"true"),r||t.setAttribute(i,"true")}catch(e){console.error("aria-hidden: cannot operate on ",t,e)}})};return c(e),s.clear(),eB++,function(){a.forEach(function(t){var e=eF.get(t)-1,r=o.get(t)-1;eF.set(t,e),o.set(t,r),e||(eI.has(t)||t.removeAttribute(i),eI.delete(t)),r||t.removeAttribute(n)}),--eB||(eF=new WeakMap,eF=new WeakMap,eI=new WeakMap,eO={})}},eU=function(t,e,n){void 0===n&&(n="data-aria-hidden");var i=Array.from(Array.isArray(t)?t:[t]),r=e||("undefined"==typeof document?null:(Array.isArray(t)?t[0]:t).ownerDocument.body);return r?(i.push.apply(i,Array.from(r.querySelectorAll("[aria-live], script"))),eW(i,r,n,"aria-hidden")):function(){return null}},eH=function(){return(eH=Object.assign||function(t){for(var e,n=1,i=arguments.length;n<i;n++)for(var r in e=arguments[n])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)};function ez(t,e){var n={};for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&0>e.indexOf(i)&&(n[i]=t[i]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols)for(var r=0,i=Object.getOwnPropertySymbols(t);r<i.length;r++)0>e.indexOf(i[r])&&Object.prototype.propertyIsEnumerable.call(t,i[r])&&(n[i[r]]=t[i[r]]);return n}"function"==typeof SuppressedError&&SuppressedError;var eZ="right-scroll-bar-position",e_="width-before-scroll-bar";function eK(t,e){return"function"==typeof t?t(e):t&&(t.current=e),t}var e$="undefined"!=typeof window?h.useLayoutEffect:h.useEffect,eY=new WeakMap,eX=(void 0===r&&(r={}),(void 0===o&&(o=function(t){return t}),a=[],s=!1,l={read:function(){if(s)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return a.length?a[a.length-1]:null},useMedium:function(t){var e=o(t,s);return a.push(e),function(){a=a.filter(function(t){return t!==e})}},assignSyncMedium:function(t){for(s=!0;a.length;){var e=a;a=[],e.forEach(t)}a={push:function(e){return t(e)},filter:function(){return a}}},assignMedium:function(t){s=!0;var e=[];if(a.length){var n=a;a=[],n.forEach(t),e=a}var i=function(){var n=e;e=[],n.forEach(t)},r=function(){return Promise.resolve().then(i)};r(),a={push:function(t){e.push(t),r()},filter:function(t){return e=e.filter(t),a}}}}).options=eH({async:!0,ssr:!1},r),l),eq=function(){},eG=h.forwardRef(function(t,e){var n,i,r,o,a=h.useRef(null),s=h.useState({onScrollCapture:eq,onWheelCapture:eq,onTouchMoveCapture:eq}),l=s[0],u=s[1],c=t.forwardProps,d=t.children,f=t.className,p=t.removeScrollBar,m=t.enabled,v=t.shards,g=t.sideCar,y=t.noRelative,w=t.noIsolation,x=t.inert,b=t.allowPinchZoom,S=t.as,T=t.gapMode,P=ez(t,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),E=(n=[a,e],i=function(t){return n.forEach(function(e){return eK(e,t)})},(r=(0,h.useState)(function(){return{value:null,callback:i,facade:{get current(){return r.value},set current(value){var t=r.value;t!==value&&(r.value=value,r.callback(value,t))}}}})[0]).callback=i,o=r.facade,e$(function(){var t=eY.get(o);if(t){var e=new Set(t),i=new Set(n),r=o.current;e.forEach(function(t){i.has(t)||eK(t,null)}),i.forEach(function(t){e.has(t)||eK(t,r)})}eY.set(o,n)},[n]),o),A=eH(eH({},P),l);return h.createElement(h.Fragment,null,m&&h.createElement(g,{sideCar:eX,removeScrollBar:p,shards:v,noRelative:y,noIsolation:w,inert:x,setCallbacks:u,allowPinchZoom:!!b,lockRef:a,gapMode:T}),c?h.cloneElement(h.Children.only(d),eH(eH({},A),{ref:E})):h.createElement(void 0===S?"div":S,eH({},A,{className:f,ref:E}),d))});eG.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},eG.classNames={fullWidth:e_,zeroRight:eZ};var eJ=function(t){var e=t.sideCar,n=ez(t,["sideCar"]);if(!e)throw Error("Sidecar: please provide `sideCar` property to import the right car");var i=e.read();if(!i)throw Error("Sidecar medium not found");return h.createElement(i,eH({},n))};eJ.isSideCarExport=!0;var eQ=function(){var t=0,e=null;return{add:function(i){if(0==t&&(e=function(){if(!document)return null;var t=document.createElement("style");t.type="text/css";var e=d||n.nc;return e&&t.setAttribute("nonce",e),t}())){var r,o;(r=e).styleSheet?r.styleSheet.cssText=i:r.appendChild(document.createTextNode(i)),o=e,(document.head||document.getElementsByTagName("head")[0]).appendChild(o)}t++},remove:function(){--t||!e||(e.parentNode&&e.parentNode.removeChild(e),e=null)}}},e0=function(){var t=eQ();return function(e,n){h.useEffect(function(){return t.add(e),function(){t.remove()}},[e&&n])}},e1=function(){var t=e0();return function(e){return t(e.styles,e.dynamic),null}},e2={left:0,top:0,right:0,gap:0},e5=function(t){return parseInt(t||"",10)||0},e3=function(t){var e=window.getComputedStyle(document.body),n=e["padding"===t?"paddingLeft":"marginLeft"],i=e["padding"===t?"paddingTop":"marginTop"],r=e["padding"===t?"paddingRight":"marginRight"];return[e5(n),e5(i),e5(r)]},e6=function(t){if(void 0===t&&(t="margin"),"undefined"==typeof window)return e2;var e=e3(t),n=document.documentElement.clientWidth,i=window.innerWidth;return{left:e[0],top:e[1],right:e[2],gap:Math.max(0,i-n+e[2]-e[0])}},e9=e1(),e4="data-scroll-locked",e7=function(t,e,n,i){var r=t.left,o=t.top,a=t.right,s=t.gap;return void 0===n&&(n="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(i,";\n padding-right: ").concat(s,"px ").concat(i,";\n }\n body[").concat(e4,"] {\n overflow: hidden ").concat(i,";\n overscroll-behavior: contain;\n ").concat([e&&"position: relative ".concat(i,";"),"margin"===n&&"\n padding-left: ".concat(r,"px;\n padding-top: ").concat(o,"px;\n padding-right: ").concat(a,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(s,"px ").concat(i,";\n "),"padding"===n&&"padding-right: ".concat(s,"px ").concat(i,";")].filter(Boolean).join(""),"\n }\n \n .").concat(eZ," {\n right: ").concat(s,"px ").concat(i,";\n }\n \n .").concat(e_," {\n margin-right: ").concat(s,"px ").concat(i,";\n }\n \n .").concat(eZ," .").concat(eZ," {\n right: 0 ").concat(i,";\n }\n \n .").concat(e_," .").concat(e_," {\n margin-right: 0 ").concat(i,";\n }\n \n body[").concat(e4,"] {\n ").concat("--removed-body-scroll-bar-size",": ").concat(s,"px;\n }\n")},e8=function(){var t=parseInt(document.body.getAttribute(e4)||"0",10);return isFinite(t)?t:0},nt=function(){h.useEffect(function(){return document.body.setAttribute(e4,(e8()+1).toString()),function(){var t=e8()-1;t<=0?document.body.removeAttribute(e4):document.body.setAttribute(e4,t.toString())}},[])},ne=function(t){var e=t.noRelative,n=t.noImportant,i=t.gapMode,r=void 0===i?"margin":i;nt();var o=h.useMemo(function(){return e6(r)},[r]);return h.createElement(e9,{styles:e7(o,!e,r,n?"":"!important")})},nn=!1;if("undefined"!=typeof window)try{var ni=Object.defineProperty({},"passive",{get:function(){return nn=!0,!0}});window.addEventListener("test",ni,ni),window.removeEventListener("test",ni,ni)}catch(t){nn=!1}var nr=!!nn&&{passive:!1},no=function(t,e){if(!(t instanceof Element))return!1;var n=window.getComputedStyle(t);return"hidden"!==n[e]&&!(n.overflowY===n.overflowX&&"TEXTAREA"!==t.tagName&&"visible"===n[e])},na=function(t,e){var n=e.ownerDocument,i=e;do{if("undefined"!=typeof ShadowRoot&&i instanceof ShadowRoot&&(i=i.host),ns(t,i)){var r=nl(t,i);if(r[1]>r[2])return!0}i=i.parentNode}while(i&&i!==n.body);return!1},ns=function(t,e){return"v"===t?no(e,"overflowY"):no(e,"overflowX")},nl=function(t,e){return"v"===t?[e.scrollTop,e.scrollHeight,e.clientHeight]:[e.scrollLeft,e.scrollWidth,e.clientWidth]},nu=function(t,e,n,i,r){var o,a=(o=window.getComputedStyle(e).direction,"h"===t&&"rtl"===o?-1:1),s=a*i,l=n.target,u=e.contains(l),c=!1,d=s>0,h=0,f=0;do{if(!l)break;var p=nl(t,l),m=p[0],v=p[1]-p[2]-a*m;(m||v)&&ns(t,l)&&(h+=v,f+=m);var g=l.parentNode;l=g&&g.nodeType===Node.DOCUMENT_FRAGMENT_NODE?g.host:g}while(!u&&l!==document.body||u&&(e.contains(l)||e===l));return d&&(r&&1>Math.abs(h)||!r&&s>h)?c=!0:!d&&(r&&1>Math.abs(f)||!r&&-s>f)&&(c=!0),c},nc=function(t){return"changedTouches"in t?[t.changedTouches[0].clientX,t.changedTouches[0].clientY]:[0,0]},nd=function(t){return[t.deltaX,t.deltaY]},nh=function(t){return t&&"current"in t?t.current:t},nf=0,np=[],nm=(u=function(t){var e=h.useRef([]),n=h.useRef([0,0]),i=h.useRef(),r=h.useState(nf++)[0],o=h.useState(e1)[0],a=h.useRef(t);h.useEffect(function(){a.current=t},[t]),h.useEffect(function(){if(t.inert){document.body.classList.add("block-interactivity-".concat(r));var e=(function(t,e,n){if(n||2==arguments.length)for(var i,r=0,o=e.length;r<o;r++)!i&&r in e||(i||(i=Array.prototype.slice.call(e,0,r)),i[r]=e[r]);return t.concat(i||Array.prototype.slice.call(e))})([t.lockRef.current],(t.shards||[]).map(nh),!0).filter(Boolean);return e.forEach(function(t){return t.classList.add("allow-interactivity-".concat(r))}),function(){document.body.classList.remove("block-interactivity-".concat(r)),e.forEach(function(t){return t.classList.remove("allow-interactivity-".concat(r))})}}},[t.inert,t.lockRef.current,t.shards]);var s=h.useCallback(function(t,e){if("touches"in t&&2===t.touches.length||"wheel"===t.type&&t.ctrlKey)return!a.current.allowPinchZoom;var r,o=nc(t),s=n.current,l="deltaX"in t?t.deltaX:s[0]-o[0],u="deltaY"in t?t.deltaY:s[1]-o[1],c=t.target,d=Math.abs(l)>Math.abs(u)?"h":"v";if("touches"in t&&"h"===d&&"range"===c.type)return!1;var h=na(d,c);if(!h)return!0;if(h?r=d:(r="v"===d?"h":"v",h=na(d,c)),!h)return!1;if(!i.current&&"changedTouches"in t&&(l||u)&&(i.current=r),!r)return!0;var f=i.current||r;return nu(f,e,t,"h"===f?l:u,!0)},[]),l=h.useCallback(function(t){if(np.length&&np[np.length-1]===o){var n="deltaY"in t?nd(t):nc(t),i=e.current.filter(function(e){var i;return e.name===t.type&&(e.target===t.target||t.target===e.shadowParent)&&(i=e.delta)[0]===n[0]&&i[1]===n[1]})[0];if(i&&i.should){t.cancelable&&t.preventDefault();return}if(!i){var r=(a.current.shards||[]).map(nh).filter(Boolean).filter(function(e){return e.contains(t.target)});(r.length>0?s(t,r[0]):!a.current.noIsolation)&&t.cancelable&&t.preventDefault()}}},[]),u=h.useCallback(function(t,n,i,r){var o={name:t,delta:n,target:i,should:r,shadowParent:function(t){for(var e=null;null!==t;)t instanceof ShadowRoot&&(e=t.host,t=t.host),t=t.parentNode;return e}(i)};e.current.push(o),setTimeout(function(){e.current=e.current.filter(function(t){return t!==o})},1)},[]),c=h.useCallback(function(t){n.current=nc(t),i.current=void 0},[]),d=h.useCallback(function(e){u(e.type,nd(e),e.target,s(e,t.lockRef.current))},[]),f=h.useCallback(function(e){u(e.type,nc(e),e.target,s(e,t.lockRef.current))},[]);h.useEffect(function(){return np.push(o),t.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:f}),document.addEventListener("wheel",l,nr),document.addEventListener("touchmove",l,nr),document.addEventListener("touchstart",c,nr),function(){np=np.filter(function(t){return t!==o}),document.removeEventListener("wheel",l,nr),document.removeEventListener("touchmove",l,nr),document.removeEventListener("touchstart",c,nr)}},[]);var p=t.removeScrollBar,m=t.inert;return h.createElement(h.Fragment,null,m?h.createElement(o,{styles:"\n .block-interactivity-".concat(r," {pointer-events: none;}\n .allow-interactivity-").concat(r," {pointer-events: all;}\n")}):null,p?h.createElement(ne,{noRelative:t.noRelative,gapMode:t.gapMode}):null)},eX.useMedium(u),eJ),nv=h.forwardRef(function(t,e){return h.createElement(eG,eH({},t,{ref:e,sideCar:nm}))});nv.classNames=eG.classNames;var ng=[" ","Enter","ArrowUp","ArrowDown"],ny=[" ","Enter"],nw="Select",[nx,nb,nS]=(0,v.B)(nw),[nT,nP]=(0,y.b)(nw,[nS,ep]),nE=ep(),[nA,nM]=nT(nw),[nC,nk]=nT(nw),nR=t=>{let{__scopeSelect:e,children:n,open:i,defaultOpen:r,onOpenChange:o,value:a,defaultValue:s,onValueChange:l,dir:u,name:c,autoComplete:d,disabled:f,required:p,form:m}=t,v=nE(e),[g,y]=h.useState(null),[x,b]=h.useState(null),[S,P]=h.useState(!1),E=(0,w.gm)(u),[A,M]=(0,eV.T)({prop:i,defaultProp:null!=r&&r,onChange:o,caller:nw}),[C,k]=(0,eV.T)({prop:a,defaultProp:s,onChange:l,caller:nw}),R=h.useRef(null),D=!g||m||!!g.closest("form"),[V,L]=h.useState(new Set),j=Array.from(V).map(t=>t.props.value).join(";");return(0,T.jsx)(eg,{...v,children:(0,T.jsxs)(nA,{required:p,scope:e,trigger:g,onTriggerChange:y,valueNode:x,onValueNodeChange:b,valueNodeHasChildren:S,onValueNodeHasChildrenChange:P,contentId:(0,W.M)(),value:C,onValueChange:k,open:A,onOpenChange:M,dir:E,triggerPointerDownPosRef:R,disabled:f,children:[(0,T.jsx)(nx.Provider,{scope:e,children:(0,T.jsx)(nC,{scope:t.__scopeSelect,onNativeOptionAdd:h.useCallback(t=>{L(e=>new Set(e).add(t))},[]),onNativeOptionRemove:h.useCallback(t=>{L(e=>{let n=new Set(e);return n.delete(t),n})},[]),children:n})}),D?(0,T.jsxs)(is,{"aria-hidden":!0,required:p,tabIndex:-1,name:c,autoComplete:d,value:C,onChange:t=>k(t.target.value),disabled:f,form:m,children:[void 0===C?(0,T.jsx)("option",{value:""}):null,Array.from(V)]},j):null]})})};nR.displayName=nw;var nD="SelectTrigger",nV=h.forwardRef((t,e)=>{let{__scopeSelect:n,disabled:i=!1,...r}=t,o=nE(n),a=nM(nD,n),s=a.disabled||i,l=(0,g.e)(e,a.onTriggerChange),u=nb(n),c=h.useRef("touch"),[d,f,p]=iu(t=>{let e=u().filter(t=>!t.disabled),n=e.find(t=>t.value===a.value),i=ic(e,t,n);void 0!==i&&a.onValueChange(i.value)}),v=t=>{s||(a.onOpenChange(!0),p()),t&&(a.triggerPointerDownPosRef.current={x:Math.round(t.pageX),y:Math.round(t.pageY)})};return(0,T.jsx)(ew,{asChild:!0,...o,children:(0,T.jsx)(x.WV.button,{type:"button",role:"combobox","aria-controls":a.contentId,"aria-expanded":a.open,"aria-required":a.required,"aria-autocomplete":"none",dir:a.dir,"data-state":a.open?"open":"closed",disabled:s,"data-disabled":s?"":void 0,"data-placeholder":il(a.value)?"":void 0,...r,ref:l,onClick:m(r.onClick,t=>{t.currentTarget.focus(),"mouse"!==c.current&&v(t)}),onPointerDown:m(r.onPointerDown,t=>{c.current=t.pointerType;let e=t.target;e.hasPointerCapture(t.pointerId)&&e.releasePointerCapture(t.pointerId),0===t.button&&!1===t.ctrlKey&&"mouse"===t.pointerType&&(v(t),t.preventDefault())}),onKeyDown:m(r.onKeyDown,t=>{let e=""!==d.current;t.ctrlKey||t.altKey||t.metaKey||1!==t.key.length||f(t.key),(!e||" "!==t.key)&&ng.includes(t.key)&&(v(),t.preventDefault())})})})});nV.displayName=nD;var nL="SelectValue",nj=h.forwardRef((t,e)=>{let{__scopeSelect:n,className:i,style:r,children:o,placeholder:a="",...s}=t,l=nM(nL,n),{onValueNodeHasChildrenChange:u}=l,c=void 0!==o,d=(0,g.e)(e,l.onValueNodeChange);return(0,ec.b)(()=>{u(c)},[u,c]),(0,T.jsx)(x.WV.span,{...s,ref:d,style:{pointerEvents:"none"},children:il(l.value)?(0,T.jsx)(T.Fragment,{children:a}):o})});nj.displayName=nL;var nF=h.forwardRef((t,e)=>{let{__scopeSelect:n,children:i,...r}=t;return(0,T.jsx)(x.WV.span,{"aria-hidden":!0,...r,ref:e,children:i||"▼"})});nF.displayName="SelectIcon";var nI=t=>(0,T.jsx)(eR.h,{asChild:!0,...t});nI.displayName="SelectPortal";var nO="SelectContent",nB=h.forwardRef((t,e)=>{let n=nM(nO,t.__scopeSelect),[i,r]=h.useState();return((0,ec.b)(()=>{r(new DocumentFragment)},[]),n.open)?(0,T.jsx)(nH,{...t,ref:e}):i?f.createPortal((0,T.jsx)(nN,{scope:t.__scopeSelect,children:(0,T.jsx)(nx.Slot,{scope:t.__scopeSelect,children:(0,T.jsx)("div",{children:t.children})})}),i):null});nB.displayName=nO;var[nN,nW]=nT(nO),nU=(0,eD.Z8)("SelectContent.RemoveScroll"),nH=h.forwardRef((t,e)=>{let{__scopeSelect:n,position:i="item-aligned",onCloseAutoFocus:r,onEscapeKeyDown:o,onPointerDownOutside:a,side:s,sideOffset:l,align:u,alignOffset:c,arrowPadding:d,collisionBoundary:f,collisionPadding:p,sticky:v,hideWhenDetached:y,avoidCollisions:w,...x}=t,b=nM(nO,n),[S,P]=h.useState(null),[E,M]=h.useState(null),C=(0,g.e)(e,t=>P(t)),[D,V]=h.useState(null),[L,F]=h.useState(null),I=nb(n),[O,B]=h.useState(!1),N=h.useRef(!1);h.useEffect(()=>{if(S)return eU(S)},[S]),h.useEffect(()=>{var t,e;let n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",null!==(t=n[0])&&void 0!==t?t:R()),document.body.insertAdjacentElement("beforeend",null!==(e=n[1])&&void 0!==e?e:R()),k++,()=>{1===k&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),k--}},[]);let W=h.useCallback(t=>{let[e,...n]=I().map(t=>t.ref.current),[i]=n.slice(-1),r=document.activeElement;for(let n of t)if(n===r||(null==n||n.scrollIntoView({block:"nearest"}),n===e&&E&&(E.scrollTop=0),n===i&&E&&(E.scrollTop=E.scrollHeight),null==n||n.focus(),document.activeElement!==r))return},[I,E]),U=h.useCallback(()=>W([D,S]),[W,D,S]);h.useEffect(()=>{O&&U()},[O,U]);let{onOpenChange:H,triggerPointerDownPosRef:z}=b;h.useEffect(()=>{if(S){let t={x:0,y:0},e=e=>{var n,i,r,o;t={x:Math.abs(Math.round(e.pageX)-(null!==(r=null===(n=z.current)||void 0===n?void 0:n.x)&&void 0!==r?r:0)),y:Math.abs(Math.round(e.pageY)-(null!==(o=null===(i=z.current)||void 0===i?void 0:i.y)&&void 0!==o?o:0))}},n=n=>{t.x<=10&&t.y<=10?n.preventDefault():S.contains(n.target)||H(!1),document.removeEventListener("pointermove",e),z.current=null};return null!==z.current&&(document.addEventListener("pointermove",e),document.addEventListener("pointerup",n,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",e),document.removeEventListener("pointerup",n,{capture:!0})}}},[S,H,z]),h.useEffect(()=>{let t=()=>H(!1);return window.addEventListener("blur",t),window.addEventListener("resize",t),()=>{window.removeEventListener("blur",t),window.removeEventListener("resize",t)}},[H]);let[Z,_]=iu(t=>{let e=I().filter(t=>!t.disabled),n=e.find(t=>t.ref.current===document.activeElement),i=ic(e,t,n);i&&setTimeout(()=>i.ref.current.focus())}),K=h.useCallback((t,e,n)=>{let i=!N.current&&!n;(void 0!==b.value&&b.value===e||i)&&(V(t),i&&(N.current=!0))},[b.value]),$=h.useCallback(()=>null==S?void 0:S.focus(),[S]),Y=h.useCallback((t,e,n)=>{let i=!N.current&&!n;(void 0!==b.value&&b.value===e||i)&&F(t)},[b.value]),X="popper"===i?nZ:nz,q=X===nZ?{side:s,sideOffset:l,align:u,alignOffset:c,arrowPadding:d,collisionBoundary:f,collisionPadding:p,sticky:v,hideWhenDetached:y,avoidCollisions:w}:{};return(0,T.jsx)(nN,{scope:n,content:S,viewport:E,onViewportChange:M,itemRefCallback:K,selectedItem:D,onItemLeave:$,itemTextRefCallback:Y,focusSelectedItem:U,selectedItemText:L,position:i,isPositioned:O,searchRef:Z,children:(0,T.jsx)(nv,{as:nU,allowPinchZoom:!0,children:(0,T.jsx)(j,{asChild:!0,trapped:b.open,onMountAutoFocus:t=>{t.preventDefault()},onUnmountAutoFocus:m(r,t=>{var e;null===(e=b.trigger)||void 0===e||e.focus({preventScroll:!0}),t.preventDefault()}),children:(0,T.jsx)(A,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:t=>t.preventDefault(),onDismiss:()=>b.onOpenChange(!1),children:(0,T.jsx)(X,{role:"listbox",id:b.contentId,"data-state":b.open?"open":"closed",dir:b.dir,onContextMenu:t=>t.preventDefault(),...x,...q,onPlaced:()=>B(!0),ref:C,style:{display:"flex",flexDirection:"column",outline:"none",...x.style},onKeyDown:m(x.onKeyDown,t=>{let e=t.ctrlKey||t.altKey||t.metaKey;if("Tab"===t.key&&t.preventDefault(),e||1!==t.key.length||_(t.key),["ArrowUp","ArrowDown","Home","End"].includes(t.key)){let e=I().filter(t=>!t.disabled).map(t=>t.ref.current);if(["ArrowUp","End"].includes(t.key)&&(e=e.slice().reverse()),["ArrowUp","ArrowDown"].includes(t.key)){let n=t.target,i=e.indexOf(n);e=e.slice(i+1)}setTimeout(()=>W(e)),t.preventDefault()}})})})})})})});nH.displayName="SelectContentImpl";var nz=h.forwardRef((t,e)=>{let{__scopeSelect:n,onPlaced:i,...r}=t,o=nM(nO,n),a=nW(nO,n),[s,l]=h.useState(null),[u,c]=h.useState(null),d=(0,g.e)(e,t=>c(t)),f=nb(n),m=h.useRef(!1),v=h.useRef(!0),{viewport:y,selectedItem:w,selectedItemText:b,focusSelectedItem:S}=a,P=h.useCallback(()=>{if(o.trigger&&o.valueNode&&s&&u&&y&&w&&b){let t=o.trigger.getBoundingClientRect(),e=u.getBoundingClientRect(),n=o.valueNode.getBoundingClientRect(),r=b.getBoundingClientRect();if("rtl"!==o.dir){let i=r.left-e.left,o=n.left-i,a=t.left-o,l=t.width+a,u=Math.max(l,e.width),c=window.innerWidth-10,d=(0,p.u)(o,[10,Math.max(10,c-u)]);s.style.minWidth=l+"px",s.style.left=d+"px"}else{let i=e.right-r.right,o=window.innerWidth-n.right-i,a=window.innerWidth-t.right-o,l=t.width+a,u=Math.max(l,e.width),c=window.innerWidth-10,d=(0,p.u)(o,[10,Math.max(10,c-u)]);s.style.minWidth=l+"px",s.style.right=d+"px"}let a=f(),l=window.innerHeight-20,c=y.scrollHeight,d=window.getComputedStyle(u),h=parseInt(d.borderTopWidth,10),v=parseInt(d.paddingTop,10),g=parseInt(d.borderBottomWidth,10),x=h+v+c+parseInt(d.paddingBottom,10)+g,S=Math.min(5*w.offsetHeight,x),T=window.getComputedStyle(y),P=parseInt(T.paddingTop,10),E=parseInt(T.paddingBottom,10),A=t.top+t.height/2-10,M=w.offsetHeight/2,C=h+v+(w.offsetTop+M);if(C<=A){let t=a.length>0&&w===a[a.length-1].ref.current;s.style.bottom="0px";let e=u.clientHeight-y.offsetTop-y.offsetHeight;s.style.height=C+Math.max(l-A,M+(t?E:0)+e+g)+"px"}else{let t=a.length>0&&w===a[0].ref.current;s.style.top="0px";let e=Math.max(A,h+y.offsetTop+(t?P:0)+M);s.style.height=e+(x-C)+"px",y.scrollTop=C-A+y.offsetTop}s.style.margin="".concat(10,"px 0"),s.style.minHeight=S+"px",s.style.maxHeight=l+"px",null==i||i(),requestAnimationFrame(()=>m.current=!0)}},[f,o.trigger,o.valueNode,s,u,y,w,b,o.dir,i]);(0,ec.b)(()=>P(),[P]);let[E,A]=h.useState();(0,ec.b)(()=>{u&&A(window.getComputedStyle(u).zIndex)},[u]);let M=h.useCallback(t=>{t&&!0===v.current&&(P(),null==S||S(),v.current=!1)},[P,S]);return(0,T.jsx)(n_,{scope:n,contentWrapper:s,shouldExpandOnScrollRef:m,onScrollButtonChange:M,children:(0,T.jsx)("div",{ref:l,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:E},children:(0,T.jsx)(x.WV.div,{...r,ref:d,style:{boxSizing:"border-box",maxHeight:"100%",...r.style}})})})});nz.displayName="SelectItemAlignedPosition";var nZ=h.forwardRef((t,e)=>{let{__scopeSelect:n,align:i="start",collisionPadding:r=10,...o}=t,a=nE(n);return(0,T.jsx)(eT,{...a,...o,ref:e,align:i,collisionPadding:r,style:{boxSizing:"border-box",...o.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});nZ.displayName="SelectPopperPosition";var[n_,nK]=nT(nO,{}),n$="SelectViewport",nY=h.forwardRef((t,e)=>{let{__scopeSelect:n,nonce:i,...r}=t,o=nW(n$,n),a=nK(n$,n),s=(0,g.e)(e,o.onViewportChange),l=h.useRef(0);return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsx)("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:i}),(0,T.jsx)(nx.Slot,{scope:n,children:(0,T.jsx)(x.WV.div,{"data-radix-select-viewport":"",role:"presentation",...r,ref:s,style:{position:"relative",flex:1,overflow:"hidden auto",...r.style},onScroll:m(r.onScroll,t=>{let e=t.currentTarget,{contentWrapper:n,shouldExpandOnScrollRef:i}=a;if((null==i?void 0:i.current)&&n){let t=Math.abs(l.current-e.scrollTop);if(t>0){let i=window.innerHeight-20,r=Math.max(parseFloat(n.style.minHeight),parseFloat(n.style.height));if(r<i){let o=r+t,a=Math.min(i,o),s=o-a;n.style.height=a+"px","0px"===n.style.bottom&&(e.scrollTop=s>0?s:0,n.style.justifyContent="flex-end")}}}l.current=e.scrollTop})})})]})});nY.displayName=n$;var nX="SelectGroup",[nq,nG]=nT(nX),nJ=h.forwardRef((t,e)=>{let{__scopeSelect:n,...i}=t,r=(0,W.M)();return(0,T.jsx)(nq,{scope:n,id:r,children:(0,T.jsx)(x.WV.div,{role:"group","aria-labelledby":r,...i,ref:e})})});nJ.displayName=nX;var nQ="SelectLabel",n0=h.forwardRef((t,e)=>{let{__scopeSelect:n,...i}=t,r=nG(nQ,n);return(0,T.jsx)(x.WV.div,{id:r.id,...i,ref:e})});n0.displayName=nQ;var n1="SelectItem",[n2,n5]=nT(n1),n3=h.forwardRef((t,e)=>{let{__scopeSelect:n,value:i,disabled:r=!1,textValue:o,...a}=t,s=nM(n1,n),l=nW(n1,n),u=s.value===i,[c,d]=h.useState(null!=o?o:""),[f,p]=h.useState(!1),v=(0,g.e)(e,t=>{var e;return null===(e=l.itemRefCallback)||void 0===e?void 0:e.call(l,t,i,r)}),y=(0,W.M)(),w=h.useRef("touch"),b=()=>{r||(s.onValueChange(i),s.onOpenChange(!1))};if(""===i)throw Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return(0,T.jsx)(n2,{scope:n,value:i,disabled:r,textId:y,isSelected:u,onItemTextChange:h.useCallback(t=>{d(e=>{var n;return e||(null!==(n=null==t?void 0:t.textContent)&&void 0!==n?n:"").trim()})},[]),children:(0,T.jsx)(nx.ItemSlot,{scope:n,value:i,disabled:r,textValue:c,children:(0,T.jsx)(x.WV.div,{role:"option","aria-labelledby":y,"data-highlighted":f?"":void 0,"aria-selected":u&&f,"data-state":u?"checked":"unchecked","aria-disabled":r||void 0,"data-disabled":r?"":void 0,tabIndex:r?void 0:-1,...a,ref:v,onFocus:m(a.onFocus,()=>p(!0)),onBlur:m(a.onBlur,()=>p(!1)),onClick:m(a.onClick,()=>{"mouse"!==w.current&&b()}),onPointerUp:m(a.onPointerUp,()=>{"mouse"===w.current&&b()}),onPointerDown:m(a.onPointerDown,t=>{w.current=t.pointerType}),onPointerMove:m(a.onPointerMove,t=>{if(w.current=t.pointerType,r){var e;null===(e=l.onItemLeave)||void 0===e||e.call(l)}else"mouse"===w.current&&t.currentTarget.focus({preventScroll:!0})}),onPointerLeave:m(a.onPointerLeave,t=>{if(t.currentTarget===document.activeElement){var e;null===(e=l.onItemLeave)||void 0===e||e.call(l)}}),onKeyDown:m(a.onKeyDown,t=>{var e;(null===(e=l.searchRef)||void 0===e?void 0:e.current)!==""&&" "===t.key||(ny.includes(t.key)&&b()," "===t.key&&t.preventDefault())})})})})});n3.displayName=n1;var n6="SelectItemText",n9=h.forwardRef((t,e)=>{let{__scopeSelect:n,className:i,style:r,...o}=t,a=nM(n6,n),s=nW(n6,n),l=n5(n6,n),u=nk(n6,n),[c,d]=h.useState(null),p=(0,g.e)(e,t=>d(t),l.onItemTextChange,t=>{var e;return null===(e=s.itemTextRefCallback)||void 0===e?void 0:e.call(s,t,l.value,l.disabled)}),m=null==c?void 0:c.textContent,v=h.useMemo(()=>(0,T.jsx)("option",{value:l.value,disabled:l.disabled,children:m},l.value),[l.disabled,l.value,m]),{onNativeOptionAdd:y,onNativeOptionRemove:w}=u;return(0,ec.b)(()=>(y(v),()=>w(v)),[y,w,v]),(0,T.jsxs)(T.Fragment,{children:[(0,T.jsx)(x.WV.span,{id:l.textId,...o,ref:p}),l.isSelected&&a.valueNode&&!a.valueNodeHasChildren?f.createPortal(o.children,a.valueNode):null]})});n9.displayName=n6;var n4="SelectItemIndicator",n7=h.forwardRef((t,e)=>{let{__scopeSelect:n,...i}=t;return n5(n4,n).isSelected?(0,T.jsx)(x.WV.span,{"aria-hidden":!0,...i,ref:e}):null});n7.displayName=n4;var n8="SelectScrollUpButton",it=h.forwardRef((t,e)=>{let n=nW(n8,t.__scopeSelect),i=nK(n8,t.__scopeSelect),[r,o]=h.useState(!1),a=(0,g.e)(e,i.onScrollButtonChange);return(0,ec.b)(()=>{if(n.viewport&&n.isPositioned){let t=function(){o(e.scrollTop>0)},e=n.viewport;return t(),e.addEventListener("scroll",t),()=>e.removeEventListener("scroll",t)}},[n.viewport,n.isPositioned]),r?(0,T.jsx)(ir,{...t,ref:a,onAutoScroll:()=>{let{viewport:t,selectedItem:e}=n;t&&e&&(t.scrollTop=t.scrollTop-e.offsetHeight)}}):null});it.displayName=n8;var ie="SelectScrollDownButton",ii=h.forwardRef((t,e)=>{let n=nW(ie,t.__scopeSelect),i=nK(ie,t.__scopeSelect),[r,o]=h.useState(!1),a=(0,g.e)(e,i.onScrollButtonChange);return(0,ec.b)(()=>{if(n.viewport&&n.isPositioned){let t=function(){let t=e.scrollHeight-e.clientHeight;o(Math.ceil(e.scrollTop)<t)},e=n.viewport;return t(),e.addEventListener("scroll",t),()=>e.removeEventListener("scroll",t)}},[n.viewport,n.isPositioned]),r?(0,T.jsx)(ir,{...t,ref:a,onAutoScroll:()=>{let{viewport:t,selectedItem:e}=n;t&&e&&(t.scrollTop=t.scrollTop+e.offsetHeight)}}):null});ii.displayName=ie;var ir=h.forwardRef((t,e)=>{let{__scopeSelect:n,onAutoScroll:i,...r}=t,o=nW("SelectScrollButton",n),a=h.useRef(null),s=nb(n),l=h.useCallback(()=>{null!==a.current&&(window.clearInterval(a.current),a.current=null)},[]);return h.useEffect(()=>()=>l(),[l]),(0,ec.b)(()=>{var t;let e=s().find(t=>t.ref.current===document.activeElement);null==e||null===(t=e.ref.current)||void 0===t||t.scrollIntoView({block:"nearest"})},[s]),(0,T.jsx)(x.WV.div,{"aria-hidden":!0,...r,ref:e,style:{flexShrink:0,...r.style},onPointerDown:m(r.onPointerDown,()=>{null===a.current&&(a.current=window.setInterval(i,50))}),onPointerMove:m(r.onPointerMove,()=>{var t;null===(t=o.onItemLeave)||void 0===t||t.call(o),null===a.current&&(a.current=window.setInterval(i,50))}),onPointerLeave:m(r.onPointerLeave,()=>{l()})})}),io=h.forwardRef((t,e)=>{let{__scopeSelect:n,...i}=t;return(0,T.jsx)(x.WV.div,{"aria-hidden":!0,...i,ref:e})});io.displayName="SelectSeparator";var ia="SelectArrow";h.forwardRef((t,e)=>{let{__scopeSelect:n,...i}=t,r=nE(n),o=nM(ia,n),a=nW(ia,n);return o.open&&"popper"===a.position?(0,T.jsx)(eA,{...r,...i,ref:e}):null}).displayName=ia;var is=h.forwardRef((t,e)=>{let{__scopeSelect:n,value:i,...r}=t,o=h.useRef(null),a=(0,g.e)(e,o),s=(0,eL.D)(i);return h.useEffect(()=>{let t=o.current;if(!t)return;let e=Object.getOwnPropertyDescriptor(window.HTMLSelectElement.prototype,"value").set;if(s!==i&&e){let n=new Event("change",{bubbles:!0});e.call(t,i),t.dispatchEvent(n)}},[s,i]),(0,T.jsx)(x.WV.select,{...r,style:{...ej.C2,...r.style},ref:a,defaultValue:i})});function il(t){return""===t||void 0===t}function iu(t){let e=(0,b.W)(t),n=h.useRef(""),i=h.useRef(0),r=h.useCallback(t=>{let r=n.current+t;e(r),function t(e){n.current=e,window.clearTimeout(i.current),""!==e&&(i.current=window.setTimeout(()=>t(""),1e3))}(r)},[e]),o=h.useCallback(()=>{n.current="",window.clearTimeout(i.current)},[]);return h.useEffect(()=>()=>window.clearTimeout(i.current),[]),[n,r,o]}function ic(t,e,n){var i;let r=e.length>1&&Array.from(e).every(t=>t===e[0])?e[0]:e,o=(i=Math.max(n?t.indexOf(n):-1,0),t.map((e,n)=>t[(i+n)%t.length]));1===r.length&&(o=o.filter(t=>t!==n));let a=o.find(t=>t.textValue.toLowerCase().startsWith(r.toLowerCase()));return a!==n?a:void 0}is.displayName="SelectBubbleInput";var id=nR,ih=nV,ip=nj,im=nF,iv=nI,ig=nB,iy=nY,iw=nJ,ix=n0,ib=n3,iS=n9,iT=n7,iP=it,iE=ii,iA=io},8873:function(t,e,n){n.d(e,{e6:function(){return Z},fC:function(){return H},bU:function(){return _},fQ:function(){return z}});var i=n(2265),r=n(2484);function o(t,e,{checkForDefaultPrevented:n=!0}={}){return function(i){if(t?.(i),!1===n||!i.defaultPrevented)return e?.(i)}}"undefined"!=typeof window&&window.document&&window.document.createElement;var a=n(8575),s=n(3966),l=n(886),u=n(9114),c=n(6718),d=n(420),h=n(6840),f=n(8068),p=n(7437),m=["PageUp","PageDown"],v=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],g={"from-left":["Home","PageDown","ArrowDown","ArrowLeft"],"from-right":["Home","PageDown","ArrowDown","ArrowRight"],"from-bottom":["Home","PageDown","ArrowDown","ArrowLeft"],"from-top":["Home","PageDown","ArrowUp","ArrowLeft"]},y="Slider",[w,x,b]=(0,f.B)(y),[S,T]=(0,s.b)(y,[b]),[P,E]=S(y),A=i.forwardRef((t,e)=>{let{name:n,min:a=0,max:s=100,step:u=1,orientation:c="horizontal",disabled:d=!1,minStepsBetweenThumbs:h=0,defaultValue:f=[a],value:g,onValueChange:y=()=>{},onValueCommit:x=()=>{},inverted:b=!1,form:S,...T}=t,E=i.useRef(new Set),A=i.useRef(0),M="horizontal"===c?k:R,[C=[],D]=(0,l.T)({prop:g,defaultProp:f,onChange:t=>{var e;null===(e=[...E.current][A.current])||void 0===e||e.focus(),y(t)}}),V=i.useRef(C);function L(t,e){let{commit:n}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{commit:!1},i=(String(u).split(".")[1]||"").length,o=function(t,e){let n=Math.pow(10,e);return Math.round(t*n)/n}(Math.round((t-a)/u)*u+a,i),l=(0,r.u)(o,[a,s]);D(function(){var t,i;let r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],o=function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],e=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,i=[...t];return i[n]=e,i.sort((t,e)=>t-e)}(r,l,e);if(t=o,!(!((i=h*u)>0)||Math.min(...t.slice(0,-1).map((e,n)=>t[n+1]-e))>=i))return r;{A.current=o.indexOf(l);let t=String(o)!==String(r);return t&&n&&x(o),t?o:r}})}return(0,p.jsx)(P,{scope:t.__scopeSlider,name:n,disabled:d,min:a,max:s,valueIndexToChangeRef:A,thumbs:E.current,values:C,orientation:c,form:S,children:(0,p.jsx)(w.Provider,{scope:t.__scopeSlider,children:(0,p.jsx)(w.Slot,{scope:t.__scopeSlider,children:(0,p.jsx)(M,{"aria-disabled":d,"data-disabled":d?"":void 0,...T,ref:e,onPointerDown:o(T.onPointerDown,()=>{d||(V.current=C)}),min:a,max:s,inverted:b,onSlideStart:d?void 0:function(t){let e=function(t,e){if(1===t.length)return 0;let n=t.map(t=>Math.abs(t-e));return n.indexOf(Math.min(...n))}(C,t);L(t,e)},onSlideMove:d?void 0:function(t){L(t,A.current)},onSlideEnd:d?void 0:function(){let t=V.current[A.current];C[A.current]!==t&&x(C)},onHomeKeyDown:()=>!d&&L(a,0,{commit:!0}),onEndKeyDown:()=>!d&&L(s,C.length-1,{commit:!0}),onStepKeyDown:t=>{let{event:e,direction:n}=t;if(!d){let t=m.includes(e.key)||e.shiftKey&&v.includes(e.key),i=A.current;L(C[i]+u*(t?10:1)*n,i,{commit:!0})}}})})})})});A.displayName=y;var[M,C]=S(y,{startEdge:"left",endEdge:"right",size:"width",direction:1}),k=i.forwardRef((t,e)=>{let{min:n,max:r,dir:o,inverted:s,onSlideStart:l,onSlideMove:c,onSlideEnd:d,onStepKeyDown:h,...f}=t,[m,v]=i.useState(null),y=(0,a.e)(e,t=>v(t)),w=i.useRef(void 0),x=(0,u.gm)(o),b="ltr"===x,S=b&&!s||!b&&s;function T(t){let e=w.current||m.getBoundingClientRect(),i=U([0,e.width],S?[n,r]:[r,n]);return w.current=e,i(t-e.left)}return(0,p.jsx)(M,{scope:t.__scopeSlider,startEdge:S?"left":"right",endEdge:S?"right":"left",direction:S?1:-1,size:"width",children:(0,p.jsx)(D,{dir:x,"data-orientation":"horizontal",...f,ref:y,style:{...f.style,"--radix-slider-thumb-transform":"translateX(-50%)"},onSlideStart:t=>{let e=T(t.clientX);null==l||l(e)},onSlideMove:t=>{let e=T(t.clientX);null==c||c(e)},onSlideEnd:()=>{w.current=void 0,null==d||d()},onStepKeyDown:t=>{let e=g[S?"from-left":"from-right"].includes(t.key);null==h||h({event:t,direction:e?-1:1})}})})}),R=i.forwardRef((t,e)=>{let{min:n,max:r,inverted:o,onSlideStart:s,onSlideMove:l,onSlideEnd:u,onStepKeyDown:c,...d}=t,h=i.useRef(null),f=(0,a.e)(e,h),m=i.useRef(void 0),v=!o;function y(t){let e=m.current||h.current.getBoundingClientRect(),i=U([0,e.height],v?[r,n]:[n,r]);return m.current=e,i(t-e.top)}return(0,p.jsx)(M,{scope:t.__scopeSlider,startEdge:v?"bottom":"top",endEdge:v?"top":"bottom",size:"height",direction:v?1:-1,children:(0,p.jsx)(D,{"data-orientation":"vertical",...d,ref:f,style:{...d.style,"--radix-slider-thumb-transform":"translateY(50%)"},onSlideStart:t=>{let e=y(t.clientY);null==s||s(e)},onSlideMove:t=>{let e=y(t.clientY);null==l||l(e)},onSlideEnd:()=>{m.current=void 0,null==u||u()},onStepKeyDown:t=>{let e=g[v?"from-bottom":"from-top"].includes(t.key);null==c||c({event:t,direction:e?-1:1})}})})}),D=i.forwardRef((t,e)=>{let{__scopeSlider:n,onSlideStart:i,onSlideMove:r,onSlideEnd:a,onHomeKeyDown:s,onEndKeyDown:l,onStepKeyDown:u,...c}=t,d=E(y,n);return(0,p.jsx)(h.WV.span,{...c,ref:e,onKeyDown:o(t.onKeyDown,t=>{"Home"===t.key?(s(t),t.preventDefault()):"End"===t.key?(l(t),t.preventDefault()):m.concat(v).includes(t.key)&&(u(t),t.preventDefault())}),onPointerDown:o(t.onPointerDown,t=>{let e=t.target;e.setPointerCapture(t.pointerId),t.preventDefault(),d.thumbs.has(e)?e.focus():i(t)}),onPointerMove:o(t.onPointerMove,t=>{t.target.hasPointerCapture(t.pointerId)&&r(t)}),onPointerUp:o(t.onPointerUp,t=>{let e=t.target;e.hasPointerCapture(t.pointerId)&&(e.releasePointerCapture(t.pointerId),a(t))})})}),V="SliderTrack",L=i.forwardRef((t,e)=>{let{__scopeSlider:n,...i}=t,r=E(V,n);return(0,p.jsx)(h.WV.span,{"data-disabled":r.disabled?"":void 0,"data-orientation":r.orientation,...i,ref:e})});L.displayName=V;var j="SliderRange",F=i.forwardRef((t,e)=>{let{__scopeSlider:n,...r}=t,o=E(j,n),s=C(j,n),l=i.useRef(null),u=(0,a.e)(e,l),c=o.values.length,d=o.values.map(t=>W(t,o.min,o.max));return(0,p.jsx)(h.WV.span,{"data-orientation":o.orientation,"data-disabled":o.disabled?"":void 0,...r,ref:u,style:{...t.style,[s.startEdge]:(c>1?Math.min(...d):0)+"%",[s.endEdge]:100-Math.max(...d)+"%"}})});F.displayName=j;var I="SliderThumb",O=i.forwardRef((t,e)=>{let n=x(t.__scopeSlider),[r,o]=i.useState(null),s=(0,a.e)(e,t=>o(t)),l=i.useMemo(()=>r?n().findIndex(t=>t.ref.current===r):-1,[n,r]);return(0,p.jsx)(B,{...t,ref:s,index:l})}),B=i.forwardRef((t,e)=>{var n;let{__scopeSlider:r,index:s,name:l,...u}=t,c=E(I,r),f=C(I,r),[m,v]=i.useState(null),g=(0,a.e)(e,t=>v(t)),y=!m||c.form||!!m.closest("form"),x=(0,d.t)(m),b=c.values[s],S=void 0===b?0:W(b,c.min,c.max),T=(n=c.values.length)>2?"Value ".concat(s+1," of ").concat(n):2===n?["Minimum","Maximum"][s]:void 0,P=null==x?void 0:x[f.size],A=P?function(t,e,n){let i=t/2,r=U([0,50],[0,i]);return(i-r(e)*n)*n}(P,S,f.direction):0;return i.useEffect(()=>{if(m)return c.thumbs.add(m),()=>{c.thumbs.delete(m)}},[m,c.thumbs]),(0,p.jsxs)("span",{style:{transform:"var(--radix-slider-thumb-transform)",position:"absolute",[f.startEdge]:"calc(".concat(S,"% + ").concat(A,"px)")},children:[(0,p.jsx)(w.ItemSlot,{scope:t.__scopeSlider,children:(0,p.jsx)(h.WV.span,{role:"slider","aria-label":t["aria-label"]||T,"aria-valuemin":c.min,"aria-valuenow":b,"aria-valuemax":c.max,"aria-orientation":c.orientation,"data-orientation":c.orientation,"data-disabled":c.disabled?"":void 0,tabIndex:c.disabled?void 0:0,...u,ref:g,style:void 0===b?{display:"none"}:t.style,onFocus:o(t.onFocus,()=>{c.valueIndexToChangeRef.current=s})})}),y&&(0,p.jsx)(N,{name:null!=l?l:c.name?c.name+(c.values.length>1?"[]":""):void 0,form:c.form,value:b},s)]})});O.displayName=I;var N=i.forwardRef((t,e)=>{let{__scopeSlider:n,value:r,...o}=t,s=i.useRef(null),l=(0,a.e)(s,e),u=(0,c.D)(r);return i.useEffect(()=>{let t=s.current;if(!t)return;let e=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"value").set;if(u!==r&&e){let n=new Event("input",{bubbles:!0});e.call(t,r),t.dispatchEvent(n)}},[u,r]),(0,p.jsx)(h.WV.input,{style:{display:"none"},...o,ref:l,defaultValue:r})});function W(t,e,n){return(0,r.u)(100/(n-e)*(t-e),[0,100])}function U(t,e){return n=>{if(t[0]===t[1]||e[0]===e[1])return e[0];let i=(e[1]-e[0])/(t[1]-t[0]);return e[0]+i*(n-t[0])}}N.displayName="RadioBubbleInput";var H=A,z=L,Z=F,_=O},721:function(t,e,n){n.d(e,{bU:function(){return T},fC:function(){return S}});var i=n(2265),r=n(6741),o=n(8575),a=n(3966),s=n(886),l=n(6718),u=n(420),c=n(6840),d=n(7437),h="Switch",[f,p]=(0,a.b)(h),[m,v]=f(h),g=i.forwardRef((t,e)=>{let{__scopeSwitch:n,name:a,checked:l,defaultChecked:u,required:f,disabled:p,value:v="on",onCheckedChange:g,form:y,...w}=t,[S,T]=i.useState(null),P=(0,o.e)(e,t=>T(t)),E=i.useRef(!1),A=!S||y||!!S.closest("form"),[M,C]=(0,s.T)({prop:l,defaultProp:null!=u&&u,onChange:g,caller:h});return(0,d.jsxs)(m,{scope:n,checked:M,disabled:p,children:[(0,d.jsx)(c.WV.button,{type:"button",role:"switch","aria-checked":M,"aria-required":f,"data-state":b(M),"data-disabled":p?"":void 0,disabled:p,value:v,...w,ref:P,onClick:(0,r.M)(t.onClick,t=>{C(t=>!t),A&&(E.current=t.isPropagationStopped(),E.current||t.stopPropagation())})}),A&&(0,d.jsx)(x,{control:S,bubbles:!E.current,name:a,value:v,checked:M,required:f,disabled:p,form:y,style:{transform:"translateX(-100%)"}})]})});g.displayName=h;var y="SwitchThumb",w=i.forwardRef((t,e)=>{let{__scopeSwitch:n,...i}=t,r=v(y,n);return(0,d.jsx)(c.WV.span,{"data-state":b(r.checked),"data-disabled":r.disabled?"":void 0,...i,ref:e})});w.displayName=y;var x=i.forwardRef((t,e)=>{let{__scopeSwitch:n,control:r,checked:a,bubbles:s=!0,...c}=t,h=i.useRef(null),f=(0,o.e)(h,e),p=(0,l.D)(a),m=(0,u.t)(r);return i.useEffect(()=>{let t=h.current;if(!t)return;let e=Object.getOwnPropertyDescriptor(window.HTMLInputElement.prototype,"checked").set;if(p!==a&&e){let n=new Event("click",{bubbles:s});e.call(t,a),t.dispatchEvent(n)}},[p,a,s]),(0,d.jsx)("input",{type:"checkbox","aria-hidden":!0,defaultChecked:a,...c,tabIndex:-1,ref:f,style:{...c.style,...m,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});function b(t){return t?"checked":"unchecked"}x.displayName="SwitchBubbleInput";var S=g,T=w},1312:function(t,e,n){n.d(e,{VY:function(){return X},aV:function(){return $},fC:function(){return K},xz:function(){return Y}});var i=n(2265),r=n(6741),o=n(3966),a=n(8068),s=n(8575),l=n(9255),u=n(6840),c=n(6606),d=n(886),h=n(9114),f=n(7437),p="rovingFocusGroup.onEntryFocus",m={bubbles:!1,cancelable:!0},v="RovingFocusGroup",[g,y,w]=(0,a.B)(v),[x,b]=(0,o.b)(v,[w]),[S,T]=x(v),P=i.forwardRef((t,e)=>(0,f.jsx)(g.Provider,{scope:t.__scopeRovingFocusGroup,children:(0,f.jsx)(g.Slot,{scope:t.__scopeRovingFocusGroup,children:(0,f.jsx)(E,{...t,ref:e})})}));P.displayName=v;var E=i.forwardRef((t,e)=>{let{__scopeRovingFocusGroup:n,orientation:o,loop:a=!1,dir:l,currentTabStopId:g,defaultCurrentTabStopId:w,onCurrentTabStopIdChange:x,onEntryFocus:b,preventScrollOnEntryFocus:T=!1,...P}=t,E=i.useRef(null),A=(0,s.e)(e,E),M=(0,h.gm)(l),[C,R]=(0,d.T)({prop:g,defaultProp:null!=w?w:null,onChange:x,caller:v}),[D,V]=i.useState(!1),L=(0,c.W)(b),j=y(n),F=i.useRef(!1),[I,O]=i.useState(0);return i.useEffect(()=>{let t=E.current;if(t)return t.addEventListener(p,L),()=>t.removeEventListener(p,L)},[L]),(0,f.jsx)(S,{scope:n,orientation:o,dir:M,loop:a,currentTabStopId:C,onItemFocus:i.useCallback(t=>R(t),[R]),onItemShiftTab:i.useCallback(()=>V(!0),[]),onFocusableItemAdd:i.useCallback(()=>O(t=>t+1),[]),onFocusableItemRemove:i.useCallback(()=>O(t=>t-1),[]),children:(0,f.jsx)(u.WV.div,{tabIndex:D||0===I?-1:0,"data-orientation":o,...P,ref:A,style:{outline:"none",...t.style},onMouseDown:(0,r.M)(t.onMouseDown,()=>{F.current=!0}),onFocus:(0,r.M)(t.onFocus,t=>{let e=!F.current;if(t.target===t.currentTarget&&e&&!D){let e=new CustomEvent(p,m);if(t.currentTarget.dispatchEvent(e),!e.defaultPrevented){let t=j().filter(t=>t.focusable);k([t.find(t=>t.active),t.find(t=>t.id===C),...t].filter(Boolean).map(t=>t.ref.current),T)}}F.current=!1}),onBlur:(0,r.M)(t.onBlur,()=>V(!1))})})}),A="RovingFocusGroupItem",M=i.forwardRef((t,e)=>{let{__scopeRovingFocusGroup:n,focusable:o=!0,active:a=!1,tabStopId:s,children:c,...d}=t,h=(0,l.M)(),p=s||h,m=T(A,n),v=m.currentTabStopId===p,w=y(n),{onFocusableItemAdd:x,onFocusableItemRemove:b,currentTabStopId:S}=m;return i.useEffect(()=>{if(o)return x(),()=>b()},[o,x,b]),(0,f.jsx)(g.ItemSlot,{scope:n,id:p,focusable:o,active:a,children:(0,f.jsx)(u.WV.span,{tabIndex:v?0:-1,"data-orientation":m.orientation,...d,ref:e,onMouseDown:(0,r.M)(t.onMouseDown,t=>{o?m.onItemFocus(p):t.preventDefault()}),onFocus:(0,r.M)(t.onFocus,()=>m.onItemFocus(p)),onKeyDown:(0,r.M)(t.onKeyDown,t=>{if("Tab"===t.key&&t.shiftKey){m.onItemShiftTab();return}if(t.target!==t.currentTarget)return;let e=function(t,e,n){var i;let r=(i=t.key,"rtl"!==n?i:"ArrowLeft"===i?"ArrowRight":"ArrowRight"===i?"ArrowLeft":i);if(!("vertical"===e&&["ArrowLeft","ArrowRight"].includes(r))&&!("horizontal"===e&&["ArrowUp","ArrowDown"].includes(r)))return C[r]}(t,m.orientation,m.dir);if(void 0!==e){if(t.metaKey||t.ctrlKey||t.altKey||t.shiftKey)return;t.preventDefault();let r=w().filter(t=>t.focusable).map(t=>t.ref.current);if("last"===e)r.reverse();else if("prev"===e||"next"===e){var n,i;"prev"===e&&r.reverse();let o=r.indexOf(t.currentTarget);r=m.loop?(n=r,i=o+1,n.map((t,e)=>n[(i+e)%n.length])):r.slice(o+1)}setTimeout(()=>k(r))}}),children:"function"==typeof c?c({isCurrentTabStop:v,hasTabStop:null!=S}):c})})});M.displayName=A;var C={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function k(t){let e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=document.activeElement;for(let i of t)if(i===n||(i.focus({preventScroll:e}),document.activeElement!==n))return}var R=n(1599),D="Tabs",[V,L]=(0,o.b)(D,[b]),j=b(),[F,I]=V(D),O=i.forwardRef((t,e)=>{let{__scopeTabs:n,value:i,onValueChange:r,defaultValue:o,orientation:a="horizontal",dir:s,activationMode:c="automatic",...p}=t,m=(0,h.gm)(s),[v,g]=(0,d.T)({prop:i,onChange:r,defaultProp:null!=o?o:"",caller:D});return(0,f.jsx)(F,{scope:n,baseId:(0,l.M)(),value:v,onValueChange:g,orientation:a,dir:m,activationMode:c,children:(0,f.jsx)(u.WV.div,{dir:m,"data-orientation":a,...p,ref:e})})});O.displayName=D;var B="TabsList",N=i.forwardRef((t,e)=>{let{__scopeTabs:n,loop:i=!0,...r}=t,o=I(B,n),a=j(n);return(0,f.jsx)(P,{asChild:!0,...a,orientation:o.orientation,dir:o.dir,loop:i,children:(0,f.jsx)(u.WV.div,{role:"tablist","aria-orientation":o.orientation,...r,ref:e})})});N.displayName=B;var W="TabsTrigger",U=i.forwardRef((t,e)=>{let{__scopeTabs:n,value:i,disabled:o=!1,...a}=t,s=I(W,n),l=j(n),c=Z(s.baseId,i),d=_(s.baseId,i),h=i===s.value;return(0,f.jsx)(M,{asChild:!0,...l,focusable:!o,active:h,children:(0,f.jsx)(u.WV.button,{type:"button",role:"tab","aria-selected":h,"aria-controls":d,"data-state":h?"active":"inactive","data-disabled":o?"":void 0,disabled:o,id:c,...a,ref:e,onMouseDown:(0,r.M)(t.onMouseDown,t=>{o||0!==t.button||!1!==t.ctrlKey?t.preventDefault():s.onValueChange(i)}),onKeyDown:(0,r.M)(t.onKeyDown,t=>{[" ","Enter"].includes(t.key)&&s.onValueChange(i)}),onFocus:(0,r.M)(t.onFocus,()=>{let t="manual"!==s.activationMode;h||o||!t||s.onValueChange(i)})})})});U.displayName=W;var H="TabsContent",z=i.forwardRef((t,e)=>{let{__scopeTabs:n,value:r,forceMount:o,children:a,...s}=t,l=I(H,n),c=Z(l.baseId,r),d=_(l.baseId,r),h=r===l.value,p=i.useRef(h);return i.useEffect(()=>{let t=requestAnimationFrame(()=>p.current=!1);return()=>cancelAnimationFrame(t)},[]),(0,f.jsx)(R.z,{present:o||h,children:n=>{let{present:i}=n;return(0,f.jsx)(u.WV.div,{"data-state":h?"active":"inactive","data-orientation":l.orientation,role:"tabpanel","aria-labelledby":c,hidden:!i,id:d,tabIndex:0,...s,ref:e,style:{...t.style,animationDuration:p.current?"0s":void 0},children:i&&a})}})});function Z(t,e){return"".concat(t,"-trigger-").concat(e)}function _(t,e){return"".concat(t,"-content-").concat(e)}z.displayName=H;var K=O,$=N,Y=U,X=z},6718:function(t,e,n){n.d(e,{D:function(){return r}});var i=n(2265);function r(t){let e=i.useRef({value:t,previous:t});return i.useMemo(()=>(e.current.value!==t&&(e.current.previous=e.current.value,e.current.value=t),e.current.previous),[t])}},420:function(t,e,n){n.d(e,{t:function(){return o}});var i=n(2265),r=n(1188);function o(t){let[e,n]=i.useState(void 0);return(0,r.b)(()=>{if(t){n({width:t.offsetWidth,height:t.offsetHeight});let e=new ResizeObserver(e=>{let i,r;if(!Array.isArray(e)||!e.length)return;let o=e[0];if("borderBoxSize"in o){let t=o.borderBoxSize,e=Array.isArray(t)?t[0]:t;i=e.inlineSize,r=e.blockSize}else i=t.offsetWidth,r=t.offsetHeight;n({width:i,height:r})});return e.observe(t,{box:"border-box"}),()=>e.unobserve(t)}n(void 0)},[t]),e}},6478:function(t,e,n){let i;n.d(e,{E:function(){return oA}});var r,o=n(2265);let a=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],s=new Set(a),l=t=>180*t/Math.PI,u=t=>d(l(Math.atan2(t[1],t[0]))),c={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:t=>(Math.abs(t[0])+Math.abs(t[3]))/2,rotate:u,rotateZ:u,skewX:t=>l(Math.atan(t[1])),skewY:t=>l(Math.atan(t[2])),skew:t=>(Math.abs(t[1])+Math.abs(t[2]))/2},d=t=>((t%=360)<0&&(t+=360),t),h=t=>Math.sqrt(t[0]*t[0]+t[1]*t[1]),f=t=>Math.sqrt(t[4]*t[4]+t[5]*t[5]),p={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:h,scaleY:f,scale:t=>(h(t)+f(t))/2,rotateX:t=>d(l(Math.atan2(t[6],t[5]))),rotateY:t=>d(l(Math.atan2(-t[2],t[0]))),rotateZ:u,rotate:u,skewX:t=>l(Math.atan(t[4])),skewY:t=>l(Math.atan(t[1])),skew:t=>(Math.abs(t[1])+Math.abs(t[4]))/2};function m(t){return t.includes("scale")?1:0}function v(t,e){let n,i;if(!t||"none"===t)return m(e);let r=t.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);if(r)n=p,i=r;else{let e=t.match(/^matrix\(([-\d.e\s,]+)\)$/u);n=c,i=e}if(!i)return m(e);let o=n[e],a=i[1].split(",").map(y);return"function"==typeof o?o(a):a[o]}let g=(t,e)=>{let{transform:n="none"}=getComputedStyle(t);return v(n,e)};function y(t){return parseFloat(t.trim())}let w=t=>e=>"string"==typeof e&&e.startsWith(t),x=w("--"),b=w("var(--"),S=t=>!!b(t)&&T.test(t.split("/*")[0].trim()),T=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function P({top:t,left:e,right:n,bottom:i}){return{x:{min:e,max:n},y:{min:t,max:i}}}let E=(t,e,n)=>t+(e-t)*n;function A(t){return void 0===t||1===t}function M({scale:t,scaleX:e,scaleY:n}){return!A(t)||!A(e)||!A(n)}function C(t){return M(t)||k(t)||t.z||t.rotate||t.rotateX||t.rotateY||t.skewX||t.skewY}function k(t){var e,n;return(e=t.x)&&"0%"!==e||(n=t.y)&&"0%"!==n}function R(t,e,n,i,r){return void 0!==r&&(t=i+r*(t-i)),i+n*(t-i)+e}function D(t,e=0,n=1,i,r){t.min=R(t.min,e,n,i,r),t.max=R(t.max,e,n,i,r)}function V(t,{x:e,y:n}){D(t.x,e.translate,e.scale,e.originPoint),D(t.y,n.translate,n.scale,n.originPoint)}function L(t,e){t.min=t.min+e,t.max=t.max+e}function j(t,e,n,i,r=.5){let o=E(t.min,t.max,r);D(t,e,n,o,i)}function F(t,e){j(t.x,e.x,e.scaleX,e.scale,e.originX),j(t.y,e.y,e.scaleY,e.scale,e.originY)}function I(t,e){return P(function(t,e){if(!e)return t;let n=e({x:t.left,y:t.top}),i=e({x:t.right,y:t.bottom});return{top:n.y,left:n.x,bottom:i.y,right:i.x}}(t.getBoundingClientRect(),e))}let O=new Set(["width","height","top","left","right","bottom",...a]),B=(t,e,n)=>n>e?e:n<t?t:n,N={test:t=>"number"==typeof t,parse:parseFloat,transform:t=>t},W={...N,transform:t=>B(0,1,t)},U={...N,default:1},H=t=>({test:e=>"string"==typeof e&&e.endsWith(t)&&1===e.split(" ").length,parse:parseFloat,transform:e=>`${e}${t}`}),z=H("deg"),Z=H("%"),_=H("px"),K=H("vh"),$=H("vw"),Y={...Z,parse:t=>Z.parse(t)/100,transform:t=>Z.transform(100*t)},X=t=>e=>e.test(t),q=[N,_,Z,z,$,K,{test:t=>"auto"===t,parse:t=>t}],G=t=>q.find(X(t)),J=()=>{},Q=()=>{},tt=t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t),te=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u,tn=t=>t===N||t===_,ti=new Set(["x","y","z"]),tr=a.filter(t=>!ti.has(t)),to={width:({x:t},{paddingLeft:e="0",paddingRight:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),height:({y:t},{paddingTop:e="0",paddingBottom:n="0"})=>t.max-t.min-parseFloat(e)-parseFloat(n),top:(t,{top:e})=>parseFloat(e),left:(t,{left:e})=>parseFloat(e),bottom:({y:t},{top:e})=>parseFloat(e)+(t.max-t.min),right:({x:t},{left:e})=>parseFloat(e)+(t.max-t.min),x:(t,{transform:e})=>v(e,"x"),y:(t,{transform:e})=>v(e,"y")};to.translateX=to.x,to.translateY=to.y;let ta=t=>t,ts={},tl=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"],tu={value:null,addProjectionMetrics:null};function tc(t,e){let n=!1,i=!0,r={delta:0,timestamp:0,isProcessing:!1},o=()=>n=!0,a=tl.reduce((t,n)=>(t[n]=function(t,e){let n=new Set,i=new Set,r=!1,o=!1,a=new WeakSet,s={delta:0,timestamp:0,isProcessing:!1},l=0;function u(e){a.has(e)&&(c.schedule(e),t()),l++,e(s)}let c={schedule:(t,e=!1,o=!1)=>{let s=o&&r?n:i;return e&&a.add(t),s.has(t)||s.add(t),t},cancel:t=>{i.delete(t),a.delete(t)},process:t=>{if(s=t,r){o=!0;return}r=!0,[n,i]=[i,n],n.forEach(u),e&&tu.value&&tu.value.frameloop[e].push(l),l=0,n.clear(),r=!1,o&&(o=!1,c.process(t))}};return c}(o,e?n:void 0),t),{}),{setup:s,read:l,resolveKeyframes:u,preUpdate:c,update:d,preRender:h,render:f,postRender:p}=a,m=()=>{let o=ts.useManualTiming?r.timestamp:performance.now();n=!1,ts.useManualTiming||(r.delta=i?1e3/60:Math.max(Math.min(o-r.timestamp,40),1)),r.timestamp=o,r.isProcessing=!0,s.process(r),l.process(r),u.process(r),c.process(r),d.process(r),h.process(r),f.process(r),p.process(r),r.isProcessing=!1,n&&e&&(i=!1,t(m))},v=()=>{n=!0,i=!0,r.isProcessing||t(m)};return{schedule:tl.reduce((t,e)=>{let i=a[e];return t[e]=(t,e=!1,r=!1)=>(n||v(),i.schedule(t,e,r)),t},{}),cancel:t=>{for(let e=0;e<tl.length;e++)a[tl[e]].cancel(t)},state:r,steps:a}}let{schedule:td,cancel:th,state:tf,steps:tp}=tc("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:ta,!0),tm=new Set,tv=!1,tg=!1,ty=!1;function tw(){if(tg){let t=Array.from(tm).filter(t=>t.needsMeasurement),e=new Set(t.map(t=>t.element)),n=new Map;e.forEach(t=>{let e=function(t){let e=[];return tr.forEach(n=>{let i=t.getValue(n);void 0!==i&&(e.push([n,i.get()]),i.set(n.startsWith("scale")?1:0))}),e}(t);e.length&&(n.set(t,e),t.render())}),t.forEach(t=>t.measureInitialState()),e.forEach(t=>{t.render();let e=n.get(t);e&&e.forEach(([e,n])=>{t.getValue(e)?.set(n)})}),t.forEach(t=>t.measureEndState()),t.forEach(t=>{void 0!==t.suspendedScrollY&&window.scrollTo(0,t.suspendedScrollY)})}tg=!1,tv=!1,tm.forEach(t=>t.complete(ty)),tm.clear()}function tx(){tm.forEach(t=>{t.readKeyframes(),t.needsMeasurement&&(tg=!0)})}class tb{constructor(t,e,n,i,r,o=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=e,this.name=n,this.motionValue=i,this.element=r,this.isAsync=o}scheduleResolve(){this.state="scheduled",this.isAsync?(tm.add(this),tv||(tv=!0,td.read(tx),td.resolveKeyframes(tw))):(this.readKeyframes(),this.complete())}readKeyframes(){let{unresolvedKeyframes:t,name:e,element:n,motionValue:i}=this;if(null===t[0]){let r=i?.get(),o=t[t.length-1];if(void 0!==r)t[0]=r;else if(n&&e){let i=n.readValue(e,o);null!=i&&(t[0]=i)}void 0===t[0]&&(t[0]=o),i&&void 0===r&&i.set(t[0])}!function(t){for(let e=1;e<t.length;e++)t[e]??(t[e]=t[e-1])}(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),tm.delete(this)}cancel(){"scheduled"===this.state&&(tm.delete(this),this.state="pending")}resume(){"pending"===this.state&&this.scheduleResolve()}}let tS=t=>/^0[^.\s]+$/u.test(t),tT=t=>Math.round(1e5*t)/1e5,tP=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu,tE=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,tA=(t,e)=>n=>!!("string"==typeof n&&tE.test(n)&&n.startsWith(t)||e&&null!=n&&Object.prototype.hasOwnProperty.call(n,e)),tM=(t,e,n)=>i=>{if("string"!=typeof i)return i;let[r,o,a,s]=i.match(tP);return{[t]:parseFloat(r),[e]:parseFloat(o),[n]:parseFloat(a),alpha:void 0!==s?parseFloat(s):1}},tC=t=>B(0,255,t),tk={...N,transform:t=>Math.round(tC(t))},tR={test:tA("rgb","red"),parse:tM("red","green","blue"),transform:({red:t,green:e,blue:n,alpha:i=1})=>"rgba("+tk.transform(t)+", "+tk.transform(e)+", "+tk.transform(n)+", "+tT(W.transform(i))+")"},tD={test:tA("#"),parse:function(t){let e="",n="",i="",r="";return t.length>5?(e=t.substring(1,3),n=t.substring(3,5),i=t.substring(5,7),r=t.substring(7,9)):(e=t.substring(1,2),n=t.substring(2,3),i=t.substring(3,4),r=t.substring(4,5),e+=e,n+=n,i+=i,r+=r),{red:parseInt(e,16),green:parseInt(n,16),blue:parseInt(i,16),alpha:r?parseInt(r,16)/255:1}},transform:tR.transform},tV={test:tA("hsl","hue"),parse:tM("hue","saturation","lightness"),transform:({hue:t,saturation:e,lightness:n,alpha:i=1})=>"hsla("+Math.round(t)+", "+Z.transform(tT(e))+", "+Z.transform(tT(n))+", "+tT(W.transform(i))+")"},tL={test:t=>tR.test(t)||tD.test(t)||tV.test(t),parse:t=>tR.test(t)?tR.parse(t):tV.test(t)?tV.parse(t):tD.parse(t),transform:t=>"string"==typeof t?t:t.hasOwnProperty("red")?tR.transform(t):tV.transform(t),getAnimatableNone:t=>{let e=tL.parse(t);return e.alpha=0,tL.transform(e)}},tj=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu,tF="number",tI="color",tO=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function tB(t){let e=t.toString(),n=[],i={color:[],number:[],var:[]},r=[],o=0,a=e.replace(tO,t=>(tL.test(t)?(i.color.push(o),r.push(tI),n.push(tL.parse(t))):t.startsWith("var(")?(i.var.push(o),r.push("var"),n.push(t)):(i.number.push(o),r.push(tF),n.push(parseFloat(t))),++o,"${}")).split("${}");return{values:n,split:a,indexes:i,types:r}}function tN(t){return tB(t).values}function tW(t){let{split:e,types:n}=tB(t),i=e.length;return t=>{let r="";for(let o=0;o<i;o++)if(r+=e[o],void 0!==t[o]){let e=n[o];e===tF?r+=tT(t[o]):e===tI?r+=tL.transform(t[o]):r+=t[o]}return r}}let tU=t=>"number"==typeof t?0:tL.test(t)?tL.getAnimatableNone(t):t,tH={test:function(t){return isNaN(t)&&"string"==typeof t&&(t.match(tP)?.length||0)+(t.match(tj)?.length||0)>0},parse:tN,createTransformer:tW,getAnimatableNone:function(t){let e=tN(t);return tW(t)(e.map(tU))}},tz=new Set(["brightness","contrast","saturate","opacity"]);function tZ(t){let[e,n]=t.slice(0,-1).split("(");if("drop-shadow"===e)return t;let[i]=n.match(tP)||[];if(!i)return t;let r=n.replace(i,""),o=tz.has(e)?1:0;return i!==n&&(o*=100),e+"("+o+r+")"}let t_=/\b([a-z-]*)\(.*?\)/gu,tK={...tH,getAnimatableNone:t=>{let e=t.match(t_);return e?e.map(tZ).join(" "):t}},t$={...N,transform:Math.round},tY={borderWidth:_,borderTopWidth:_,borderRightWidth:_,borderBottomWidth:_,borderLeftWidth:_,borderRadius:_,radius:_,borderTopLeftRadius:_,borderTopRightRadius:_,borderBottomRightRadius:_,borderBottomLeftRadius:_,width:_,maxWidth:_,height:_,maxHeight:_,top:_,right:_,bottom:_,left:_,padding:_,paddingTop:_,paddingRight:_,paddingBottom:_,paddingLeft:_,margin:_,marginTop:_,marginRight:_,marginBottom:_,marginLeft:_,backgroundPositionX:_,backgroundPositionY:_,rotate:z,rotateX:z,rotateY:z,rotateZ:z,scale:U,scaleX:U,scaleY:U,scaleZ:U,skew:z,skewX:z,skewY:z,distance:_,translateX:_,translateY:_,translateZ:_,x:_,y:_,z:_,perspective:_,transformPerspective:_,opacity:W,originX:Y,originY:Y,originZ:_,zIndex:t$,fillOpacity:W,strokeOpacity:W,numOctaves:t$},tX={...tY,color:tL,backgroundColor:tL,outlineColor:tL,fill:tL,stroke:tL,borderColor:tL,borderTopColor:tL,borderRightColor:tL,borderBottomColor:tL,borderLeftColor:tL,filter:tK,WebkitFilter:tK},tq=t=>tX[t];function tG(t,e){let n=tq(t);return n!==tK&&(n=tH),n.getAnimatableNone?n.getAnimatableNone(e):void 0}let tJ=new Set(["auto","none","0"]);class tQ extends tb{constructor(t,e,n,i,r){super(t,e,n,i,r,!0)}readKeyframes(){let{unresolvedKeyframes:t,element:e,name:n}=this;if(!e||!e.current)return;super.readKeyframes();for(let n=0;n<t.length;n++){let i=t[n];if("string"==typeof i&&S(i=i.trim())){let r=function t(e,n,i=1){Q(i<=4,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");let[r,o]=function(t){let e=te.exec(t);if(!e)return[,];let[,n,i,r]=e;return[`--${n??i}`,r]}(e);if(!r)return;let a=window.getComputedStyle(n).getPropertyValue(r);if(a){let t=a.trim();return tt(t)?parseFloat(t):t}return S(o)?t(o,n,i+1):o}(i,e.current);void 0!==r&&(t[n]=r),n===t.length-1&&(this.finalKeyframe=i)}}if(this.resolveNoneKeyframes(),!O.has(n)||2!==t.length)return;let[i,r]=t,o=G(i),a=G(r);if(o!==a){if(tn(o)&&tn(a))for(let e=0;e<t.length;e++){let n=t[e];"string"==typeof n&&(t[e]=parseFloat(n))}else to[n]&&(this.needsMeasurement=!0)}}resolveNoneKeyframes(){let{unresolvedKeyframes:t,name:e}=this,n=[];for(let e=0;e<t.length;e++){var i;(null===t[e]||("number"==typeof(i=t[e])?0===i:null===i||"none"===i||"0"===i||tS(i)))&&n.push(e)}n.length&&function(t,e,n){let i,r=0;for(;r<t.length&&!i;){let e=t[r];"string"==typeof e&&!tJ.has(e)&&tB(e).values.length&&(i=t[r]),r++}if(i&&n)for(let r of e)t[r]=tG(n,i)}(t,n,e)}measureInitialState(){let{element:t,unresolvedKeyframes:e,name:n}=this;if(!t||!t.current)return;"height"===n&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=to[n](t.measureViewportBox(),window.getComputedStyle(t.current)),e[0]=this.measuredOrigin;let i=e[e.length-1];void 0!==i&&t.getValue(n,i).jump(i,!1)}measureEndState(){let{element:t,name:e,unresolvedKeyframes:n}=this;if(!t||!t.current)return;let i=t.getValue(e);i&&i.jump(this.measuredOrigin,!1);let r=n.length-1,o=n[r];n[r]=to[e](t.measureViewportBox(),window.getComputedStyle(t.current)),null!==o&&void 0===this.finalKeyframe&&(this.finalKeyframe=o),this.removedTransforms?.length&&this.removedTransforms.forEach(([e,n])=>{t.getValue(e).set(n)}),this.resolveNoneKeyframes()}}let t0=t=>!!(t&&t.getVelocity);function t1(){i=void 0}let t2={now:()=>(void 0===i&&t2.set(tf.isProcessing||ts.useManualTiming?tf.timestamp:performance.now()),i),set:t=>{i=t,queueMicrotask(t1)}};function t5(t,e){-1===t.indexOf(e)&&t.push(e)}function t3(t,e){let n=t.indexOf(e);n>-1&&t.splice(n,1)}class t6{constructor(){this.subscriptions=[]}add(t){return t5(this.subscriptions,t),()=>t3(this.subscriptions,t)}notify(t,e,n){let i=this.subscriptions.length;if(i){if(1===i)this.subscriptions[0](t,e,n);else for(let r=0;r<i;r++){let i=this.subscriptions[r];i&&i(t,e,n)}}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}let t9=t=>!isNaN(parseFloat(t)),t4={current:void 0};class t7{constructor(t,e={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=t=>{let e=t2.now();if(this.updatedAt!==e&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(t),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(let t of this.dependents)t.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=e.owner}setCurrent(t){this.current=t,this.updatedAt=t2.now(),null===this.canTrackVelocity&&void 0!==t&&(this.canTrackVelocity=t9(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,e){this.events[t]||(this.events[t]=new t6);let n=this.events[t].add(e);return"change"===t?()=>{n(),td.read(()=>{this.events.change.getSize()||this.stop()})}:n}clearListeners(){for(let t in this.events)this.events[t].clear()}attach(t,e){this.passiveEffect=t,this.stopPassiveEffect=e}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,e,n){this.set(e),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-n}jump(t,e=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,e&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return t4.current&&t4.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){var t;let e=t2.now();if(!this.canTrackVelocity||void 0===this.prevFrameValue||e-this.updatedAt>30)return 0;let n=Math.min(this.updatedAt-this.prevUpdatedAt,30);return t=parseFloat(this.current)-parseFloat(this.prevFrameValue),n?1e3/n*t:0}start(t){return this.stop(),new Promise(e=>{this.hasAnimated=!0,this.animation=t(e),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function t8(t,e){return new t7(t,e)}let et=[...q,tL,tH],ee=t=>et.find(X(t)),{schedule:en,cancel:ei}=tc(queueMicrotask,!1),er={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},eo={};for(let t in er)eo[t]={isEnabled:e=>er[t].some(t=>!!e[t])};let ea=()=>({translate:0,scale:1,origin:0,originPoint:0}),es=()=>({x:ea(),y:ea()}),el=()=>({min:0,max:0}),eu=()=>({x:el(),y:el()}),ec="undefined"!=typeof window,ed={current:null},eh={current:!1},ef=new WeakMap;function ep(t){return null!==t&&"object"==typeof t&&"function"==typeof t.start}function em(t){return"string"==typeof t||Array.isArray(t)}let ev=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],eg=["initial",...ev];function ey(t){return ep(t.animate)||eg.some(e=>em(t[e]))}function ew(t){return!!(ey(t)||t.variants)}function ex(t){let e=[{},{}];return t?.values.forEach((t,n)=>{e[0][n]=t.get(),e[1][n]=t.getVelocity()}),e}function eb(t,e,n,i){if("function"==typeof e){let[r,o]=ex(i);e=e(void 0!==n?n:t.custom,r,o)}if("string"==typeof e&&(e=t.variants&&t.variants[e]),"function"==typeof e){let[r,o]=ex(i);e=e(void 0!==n?n:t.custom,r,o)}return e}let eS=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class eT{scrapeMotionValuesFromProps(t,e,n){return{}}constructor({parent:t,props:e,presenceContext:n,reducedMotionConfig:i,blockInitialAnimation:r,visualState:o},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=tb,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{let t=t2.now();this.renderScheduledAt<t&&(this.renderScheduledAt=t,td.render(this.render,!1,!0))};let{latestValues:s,renderState:l}=o;this.latestValues=s,this.baseTarget={...s},this.initialValues=e.initial?{...s}:{},this.renderState=l,this.parent=t,this.props=e,this.presenceContext=n,this.depth=t?t.depth+1:0,this.reducedMotionConfig=i,this.options=a,this.blockInitialAnimation=!!r,this.isControllingVariants=ey(e),this.isVariantNode=ew(e),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);let{willChange:u,...c}=this.scrapeMotionValuesFromProps(e,{},this);for(let t in c){let e=c[t];void 0!==s[t]&&t0(e)&&e.set(s[t])}}mount(t){this.current=t,ef.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((t,e)=>this.bindToMotionValue(e,t)),eh.current||function(){if(eh.current=!0,ec){if(window.matchMedia){let t=window.matchMedia("(prefers-reduced-motion)"),e=()=>ed.current=t.matches;t.addEventListener("change",e),e()}else ed.current=!1}}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||ed.current),this.parent?.addChild(this),this.update(this.props,this.presenceContext)}unmount(){for(let t in this.projection&&this.projection.unmount(),th(this.notifyUpdate),th(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this),this.events)this.events[t].clear();for(let t in this.features){let e=this.features[t];e&&(e.unmount(),e.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,e){let n;this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();let i=s.has(t);i&&this.onBindTransform&&this.onBindTransform();let r=e.on("change",e=>{this.latestValues[t]=e,this.props.onUpdate&&td.preRender(this.notifyUpdate),i&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});window.MotionCheckAppearSync&&(n=window.MotionCheckAppearSync(this,t,e)),this.valueSubscriptions.set(t,()=>{r(),n&&n(),e.owner&&e.stop()})}sortNodePosition(t){return this.current&&this.sortInstanceNodePosition&&this.type===t.type?this.sortInstanceNodePosition(this.current,t.current):0}updateFeatures(){let t="animation";for(t in eo){let e=eo[t];if(!e)continue;let{isEnabled:n,Feature:i}=e;if(!this.features[t]&&i&&n(this.props)&&(this.features[t]=new i(this)),this.features[t]){let e=this.features[t];e.isMounted?e.update():(e.mount(),e.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):eu()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,e){this.latestValues[t]=e}update(t,e){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=e;for(let e=0;e<eS.length;e++){let n=eS[e];this.propEventSubscriptions[n]&&(this.propEventSubscriptions[n](),delete this.propEventSubscriptions[n]);let i=t["on"+n];i&&(this.propEventSubscriptions[n]=this.on(n,i))}this.prevMotionValues=function(t,e,n){for(let i in e){let r=e[i],o=n[i];if(t0(r))t.addValue(i,r);else if(t0(o))t.addValue(i,t8(r,{owner:t}));else if(o!==r){if(t.hasValue(i)){let e=t.getValue(i);!0===e.liveStyle?e.jump(r):e.hasAnimated||e.set(r)}else{let e=t.getStaticValue(i);t.addValue(i,t8(void 0!==e?e:r,{owner:t}))}}}for(let i in n)void 0===e[i]&&t.removeValue(i);return e}(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){let e=this.getClosestVariantNode();if(e)return e.variantChildren&&e.variantChildren.add(t),()=>e.variantChildren.delete(t)}addValue(t,e){let n=this.values.get(t);e!==n&&(n&&this.removeValue(t),this.bindToMotionValue(t,e),this.values.set(t,e),this.latestValues[t]=e.get())}removeValue(t){this.values.delete(t);let e=this.valueSubscriptions.get(t);e&&(e(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,e){if(this.props.values&&this.props.values[t])return this.props.values[t];let n=this.values.get(t);return void 0===n&&void 0!==e&&(n=t8(null===e?void 0:e,{owner:this}),this.addValue(t,n)),n}readValue(t,e){let n=void 0===this.latestValues[t]&&this.current?this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options):this.latestValues[t];return null!=n&&("string"==typeof n&&(tt(n)||tS(n))?n=parseFloat(n):!ee(n)&&tH.test(e)&&(n=tG(t,e)),this.setBaseTarget(t,t0(n)?n.get():n)),t0(n)?n.get():n}setBaseTarget(t,e){this.baseTarget[t]=e}getBaseTarget(t){let e;let{initial:n}=this.props;if("string"==typeof n||"object"==typeof n){let i=eb(this.props,n,this.presenceContext?.custom);i&&(e=i[t])}if(n&&void 0!==e)return e;let i=this.getBaseTargetFromProps(this.props,t);return void 0===i||t0(i)?void 0!==this.initialValues[t]&&void 0===e?void 0:this.baseTarget[t]:i}on(t,e){return this.events[t]||(this.events[t]=new t6),this.events[t].add(e)}notify(t,...e){this.events[t]&&this.events[t].notify(...e)}scheduleRenderMicrotask(){en.render(this.render)}}class eP extends eT{constructor(){super(...arguments),this.KeyframeResolver=tQ}sortInstanceNodePosition(t,e){return 2&t.compareDocumentPosition(e)?1:-1}getBaseTargetFromProps(t,e){return t.style?t.style[e]:void 0}removeValueFromRenderState(t,{vars:e,style:n}){delete e[t],delete n[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);let{children:t}=this.props;t0(t)&&(this.childSubscription=t.on("change",t=>{this.current&&(this.current.textContent=`${t}`)}))}}let eE=(t,e)=>e&&"number"==typeof t?e.transform(t):t,eA={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},eM=a.length;function eC(t,e,n){let{style:i,vars:r,transformOrigin:o}=t,l=!1,u=!1;for(let t in e){let n=e[t];if(s.has(t)){l=!0;continue}if(x(t)){r[t]=n;continue}{let e=eE(n,tY[t]);t.startsWith("origin")?(u=!0,o[t]=e):i[t]=e}}if(!e.transform&&(l||n?i.transform=function(t,e,n){let i="",r=!0;for(let o=0;o<eM;o++){let s=a[o],l=t[s];if(void 0===l)continue;let u=!0;if(!(u="number"==typeof l?l===(s.startsWith("scale")?1:0):0===parseFloat(l))||n){let t=eE(l,tY[s]);if(!u){r=!1;let e=eA[s]||s;i+=`${e}(${t}) `}n&&(e[s]=t)}}return i=i.trim(),n?i=n(e,r?"":i):r&&(i="none"),i}(e,t.transform,n):i.transform&&(i.transform="none")),u){let{originX:t="50%",originY:e="50%",originZ:n=0}=o;i.transformOrigin=`${t} ${e} ${n}`}}function ek(t,{style:e,vars:n},i,r){let o;let a=t.style;for(o in e)a[o]=e[o];for(o in r?.applyProjectionStyles(a,i),n)a.setProperty(o,n[o])}let eR={};function eD(t,{layout:e,layoutId:n}){return s.has(t)||t.startsWith("origin")||(e||void 0!==n)&&(!!eR[t]||"opacity"===t)}function eV(t,e,n){let{style:i}=t,r={};for(let o in i)(t0(i[o])||e.style&&t0(e.style[o])||eD(o,t)||n?.getValue(o)?.liveStyle!==void 0)&&(r[o]=i[o]);return r}class eL extends eP{constructor(){super(...arguments),this.type="html",this.renderInstance=ek}readValueFromInstance(t,e){if(s.has(e))return this.projection?.isProjecting?m(e):g(t,e);{let n=window.getComputedStyle(t),i=(x(e)?n.getPropertyValue(e):n[e])||0;return"string"==typeof i?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:e}){return I(t,e)}build(t,e,n){eC(t,e,n.transformTemplate)}scrapeMotionValuesFromProps(t,e,n){return eV(t,e,n)}}let ej=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),eF={offset:"stroke-dashoffset",array:"stroke-dasharray"},eI={offset:"strokeDashoffset",array:"strokeDasharray"};function eO(t,{attrX:e,attrY:n,attrScale:i,pathLength:r,pathSpacing:o=1,pathOffset:a=0,...s},l,u,c){if(eC(t,s,u),l){t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox);return}t.attrs=t.style,t.style={};let{attrs:d,style:h}=t;d.transform&&(h.transform=d.transform,delete d.transform),(h.transform||d.transformOrigin)&&(h.transformOrigin=d.transformOrigin??"50% 50%",delete d.transformOrigin),h.transform&&(h.transformBox=c?.transformBox??"fill-box",delete d.transformBox),void 0!==e&&(d.x=e),void 0!==n&&(d.y=n),void 0!==i&&(d.scale=i),void 0!==r&&function(t,e,n=1,i=0,r=!0){t.pathLength=1;let o=r?eF:eI;t[o.offset]=_.transform(-i);let a=_.transform(e),s=_.transform(n);t[o.array]=`${a} ${s}`}(d,r,o,a,!1)}let eB=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),eN=t=>"string"==typeof t&&"svg"===t.toLowerCase();function eW(t,e,n){let i=eV(t,e,n);for(let n in t)(t0(t[n])||t0(e[n]))&&(i[-1!==a.indexOf(n)?"attr"+n.charAt(0).toUpperCase()+n.substring(1):n]=t[n]);return i}class eU extends eP{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=eu}getBaseTargetFromProps(t,e){return t[e]}readValueFromInstance(t,e){if(s.has(e)){let t=tq(e);return t&&t.default||0}return e=eB.has(e)?e:ej(e),t.getAttribute(e)}scrapeMotionValuesFromProps(t,e,n){return eW(t,e,n)}build(t,e,n){eO(t,e,this.isSVGTag,n.transformTemplate,n.style)}renderInstance(t,e,n,i){!function(t,e,n,i){for(let n in ek(t,e,void 0,i),e.attrs)t.setAttribute(eB.has(n)?n:ej(n),e.attrs[n])}(t,e,0,i)}mount(t){this.isSVGTag=eN(t.tagName),super.mount(t)}}let eH=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function ez(t){if("string"!=typeof t||t.includes("-"));else if(eH.indexOf(t)>-1||/[A-Z]/u.test(t))return!0;return!1}var eZ=n(7437);let e_=(0,o.createContext)({}),eK=(0,o.createContext)({strict:!1}),e$=(0,o.createContext)({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"}),eY=(0,o.createContext)({});function eX(t){return Array.isArray(t)?t.join(" "):t}let eq=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function eG(t,e,n){for(let i in e)t0(e[i])||eD(i,n)||(t[i]=e[i])}let eJ=()=>({...eq(),attrs:{}}),eQ=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function e0(t){return t.startsWith("while")||t.startsWith("drag")&&"draggable"!==t||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||eQ.has(t)}let e1=t=>!e0(t);try{r=require("@emotion/is-prop-valid").default,"function"==typeof r&&(e1=t=>t.startsWith("on")?!e0(t):r(t))}catch{}let e2=(0,o.createContext)(null);function e5(t){return t0(t)?t.get():t}let e3=t=>(e,n)=>{let i=(0,o.useContext)(eY),r=(0,o.useContext)(e2),a=()=>(function({scrapeMotionValuesFromProps:t,createRenderState:e},n,i,r){return{latestValues:function(t,e,n,i){let r={},o=i(t,{});for(let t in o)r[t]=e5(o[t]);let{initial:a,animate:s}=t,l=ey(t),u=ew(t);e&&u&&!l&&!1!==t.inherit&&(void 0===a&&(a=e.initial),void 0===s&&(s=e.animate));let c=!!n&&!1===n.initial,d=(c=c||!1===a)?s:a;if(d&&"boolean"!=typeof d&&!ep(d)){let e=Array.isArray(d)?d:[d];for(let n=0;n<e.length;n++){let i=eb(t,e[n]);if(i){let{transitionEnd:t,transition:e,...n}=i;for(let t in n){let e=n[t];if(Array.isArray(e)){let t=c?e.length-1:0;e=e[t]}null!==e&&(r[t]=e)}for(let e in t)r[e]=t[e]}}}return r}(n,i,r,t),renderState:e()}})(t,e,i,r);return n?a():function(t){let e=(0,o.useRef)(null);return null===e.current&&(e.current=t()),e.current}(a)},e6=e3({scrapeMotionValuesFromProps:eV,createRenderState:eq}),e9=e3({scrapeMotionValuesFromProps:eW,createRenderState:eJ}),e4=Symbol.for("motionComponentSymbol");function e7(t){return t&&"object"==typeof t&&Object.prototype.hasOwnProperty.call(t,"current")}let e8="data-"+ej("framerAppearId"),nt=(0,o.createContext)({}),ne=ec?o.useLayoutEffect:o.useEffect;function nn(t){var e,n;let{forwardMotionProps:i=!1}=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0,a=arguments.length>3?arguments[3]:void 0;r&&function(t){for(let e in t)eo[e]={...eo[e],...t[e]}}(r);let s=ez(t)?e9:e6;function l(e,n){var r;let l;let u={...(0,o.useContext)(e$),...e,layoutId:function(t){let{layoutId:e}=t,n=(0,o.useContext)(e_).id;return n&&void 0!==e?n+"-"+e:e}(e)},{isStatic:c}=u,d=function(t){let{initial:e,animate:n}=function(t,e){if(ey(t)){let{initial:e,animate:n}=t;return{initial:!1===e||em(e)?e:void 0,animate:em(n)?n:void 0}}return!1!==t.inherit?e:{}}(t,(0,o.useContext)(eY));return(0,o.useMemo)(()=>({initial:e,animate:n}),[eX(e),eX(n)])}(e),h=s(e,c);if(!c&&ec){(0,o.useContext)(eK).strict;let e=function(t){let{drag:e,layout:n}=eo;if(!e&&!n)return{};let i={...e,...n};return{MeasureLayout:(null==e?void 0:e.isEnabled(t))||(null==n?void 0:n.isEnabled(t))?i.MeasureLayout:void 0,ProjectionNode:i.ProjectionNode}}(u);l=e.MeasureLayout,d.visualElement=function(t,e,n,i,r){let{visualElement:a}=(0,o.useContext)(eY),s=(0,o.useContext)(eK),l=(0,o.useContext)(e2),u=(0,o.useContext)(e$).reducedMotion,c=(0,o.useRef)(null);i=i||s.renderer,!c.current&&i&&(c.current=i(t,{visualState:e,parent:a,props:n,presenceContext:l,blockInitialAnimation:!!l&&!1===l.initial,reducedMotionConfig:u}));let d=c.current,h=(0,o.useContext)(nt);d&&!d.projection&&r&&("html"===d.type||"svg"===d.type)&&function(t,e,n,i){let{layoutId:r,layout:o,drag:a,dragConstraints:s,layoutScroll:l,layoutRoot:u,layoutCrossfade:c}=e;t.projection=new n(t.latestValues,e["data-framer-portal-id"]?void 0:function t(e){if(e)return!1!==e.options.allowProjection?e.projection:t(e.parent)}(t.parent)),t.projection.setOptions({layoutId:r,layout:o,alwaysMeasureLayout:!!a||s&&e7(s),visualElement:t,animationType:"string"==typeof o?o:"both",initialPromotionConfig:i,crossfade:c,layoutScroll:l,layoutRoot:u})}(c.current,n,r,h);let f=(0,o.useRef)(!1);(0,o.useInsertionEffect)(()=>{d&&f.current&&d.update(n,l)});let p=n[e8],m=(0,o.useRef)(!!p&&!window.MotionHandoffIsComplete?.(p)&&window.MotionHasOptimisedAnimation?.(p));return ne(()=>{d&&(f.current=!0,window.MotionIsMounted=!0,d.updateFeatures(),d.scheduleRenderMicrotask(),m.current&&d.animationState&&d.animationState.animateChanges())}),(0,o.useEffect)(()=>{d&&(!m.current&&d.animationState&&d.animationState.animateChanges(),m.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(p)}),m.current=!1),d.enteringChildren=void 0)}),d}(t,h,u,a,e.ProjectionNode)}return(0,eZ.jsxs)(eY.Provider,{value:d,children:[l&&d.visualElement?(0,eZ.jsx)(l,{visualElement:d.visualElement,...u}):null,function(t,e,n,{latestValues:i},r,a=!1){let s=(ez(t)?function(t,e,n,i){let r=(0,o.useMemo)(()=>{let n=eJ();return eO(n,e,eN(i),t.transformTemplate,t.style),{...n.attrs,style:{...n.style}}},[e]);if(t.style){let e={};eG(e,t.style,t),r.style={...e,...r.style}}return r}:function(t,e){let n={},i=function(t,e){let n=t.style||{},i={};return eG(i,n,t),Object.assign(i,function({transformTemplate:t},e){return(0,o.useMemo)(()=>{let n=eq();return eC(n,e,t),Object.assign({},n.vars,n.style)},[e])}(t,e)),i}(t,e);return t.drag&&!1!==t.dragListener&&(n.draggable=!1,i.userSelect=i.WebkitUserSelect=i.WebkitTouchCallout="none",i.touchAction=!0===t.drag?"none":`pan-${"x"===t.drag?"y":"x"}`),void 0===t.tabIndex&&(t.onTap||t.onTapStart||t.whileTap)&&(n.tabIndex=0),n.style=i,n})(e,i,r,t),l=function(t,e,n){let i={};for(let r in t)("values"!==r||"object"!=typeof t.values)&&(e1(r)||!0===n&&e0(r)||!e&&!e0(r)||t.draggable&&r.startsWith("onDrag"))&&(i[r]=t[r]);return i}(e,"string"==typeof t,a),u=t!==o.Fragment?{...l,...s,ref:n}:{},{children:c}=e,d=(0,o.useMemo)(()=>t0(c)?c.get():c,[c]);return(0,o.createElement)(t,{...u,children:d})}(t,e,(r=d.visualElement,(0,o.useCallback)(t=>{t&&h.onMount&&h.onMount(t),r&&(t?r.mount(t):r.unmount()),n&&("function"==typeof n?n(t):e7(n)&&(n.current=t))},[r])),h,c,i)]})}l.displayName="motion.".concat("string"==typeof t?t:"create(".concat(null!==(n=null!==(e=t.displayName)&&void 0!==e?e:t.name)&&void 0!==n?n:"",")"));let u=(0,o.forwardRef)(l);return u[e4]=t,u}function ni(t,e,n){let i=t.getProps();return eb(i,e,void 0!==n?n:i.custom,t)}function nr(t,e){return t?.[e]??t?.default??t}let no=t=>Array.isArray(t);function na(t,e){let n=t.getValue("willChange");if(t0(n)&&n.add)return n.add(e);if(!n&&ts.WillChange){let n=new ts.WillChange("auto");t.addValue("willChange",n),n.add(e)}}function ns(t){t.duration=0,t.type}let nl=(t,e)=>n=>e(t(n)),nu=(...t)=>t.reduce(nl),nc=t=>1e3*t,nd=t=>t/1e3,nh={layout:0,mainThread:0,waapi:0};function nf(t,e,n){return(n<0&&(n+=1),n>1&&(n-=1),n<1/6)?t+(e-t)*6*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t}function np(t,e){return n=>n>0?e:t}let nm=(t,e,n)=>{let i=t*t,r=n*(e*e-i)+i;return r<0?0:Math.sqrt(r)},nv=[tD,tR,tV],ng=t=>nv.find(e=>e.test(t));function ny(t){let e=ng(t);if(J(!!e,`'${t}' is not an animatable color. Use the equivalent color code instead.`,"color-not-animatable"),!e)return!1;let n=e.parse(t);return e===tV&&(n=function({hue:t,saturation:e,lightness:n,alpha:i}){t/=360,n/=100;let r=0,o=0,a=0;if(e/=100){let i=n<.5?n*(1+e):n+e-n*e,s=2*n-i;r=nf(s,i,t+1/3),o=nf(s,i,t),a=nf(s,i,t-1/3)}else r=o=a=n;return{red:Math.round(255*r),green:Math.round(255*o),blue:Math.round(255*a),alpha:i}}(n)),n}let nw=(t,e)=>{let n=ny(t),i=ny(e);if(!n||!i)return np(t,e);let r={...n};return t=>(r.red=nm(n.red,i.red,t),r.green=nm(n.green,i.green,t),r.blue=nm(n.blue,i.blue,t),r.alpha=E(n.alpha,i.alpha,t),tR.transform(r))},nx=new Set(["none","hidden"]);function nb(t,e){return n=>E(t,e,n)}function nS(t){return"number"==typeof t?nb:"string"==typeof t?S(t)?np:tL.test(t)?nw:nE:Array.isArray(t)?nT:"object"==typeof t?tL.test(t)?nw:nP:np}function nT(t,e){let n=[...t],i=n.length,r=t.map((t,n)=>nS(t)(t,e[n]));return t=>{for(let e=0;e<i;e++)n[e]=r[e](t);return n}}function nP(t,e){let n={...t,...e},i={};for(let r in n)void 0!==t[r]&&void 0!==e[r]&&(i[r]=nS(t[r])(t[r],e[r]));return t=>{for(let e in i)n[e]=i[e](t);return n}}let nE=(t,e)=>{let n=tH.createTransformer(e),i=tB(t),r=tB(e);return i.indexes.var.length===r.indexes.var.length&&i.indexes.color.length===r.indexes.color.length&&i.indexes.number.length>=r.indexes.number.length?nx.has(t)&&!r.values.length||nx.has(e)&&!i.values.length?nx.has(t)?n=>n<=0?t:e:n=>n>=1?e:t:nu(nT(function(t,e){let n=[],i={color:0,var:0,number:0};for(let r=0;r<e.values.length;r++){let o=e.types[r],a=t.indexes[o][i[o]],s=t.values[a]??0;n[r]=s,i[o]++}return n}(i,r),r.values),n):(J(!0,`Complex values '${t}' and '${e}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,"complex-values-different"),np(t,e))};function nA(t,e,n){return"number"==typeof t&&"number"==typeof e&&"number"==typeof n?E(t,e,n):nS(t)(t,e)}let nM=t=>{let e=({timestamp:e})=>t(e);return{start:(t=!0)=>td.update(e,t),stop:()=>th(e),now:()=>tf.isProcessing?tf.timestamp:t2.now()}},nC=(t,e,n=10)=>{let i="",r=Math.max(Math.round(e/n),2);for(let e=0;e<r;e++)i+=Math.round(1e4*t(e/(r-1)))/1e4+", ";return`linear(${i.substring(0,i.length-2)})`};function nk(t){let e=0,n=t.next(e);for(;!n.done&&e<2e4;)e+=50,n=t.next(e);return e>=2e4?1/0:e}function nR(t,e,n){var i,r;let o=Math.max(e-5,0);return i=n-t(o),(r=e-o)?1e3/r*i:0}let nD={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};function nV(t,e){return t*Math.sqrt(1-e*e)}let nL=["duration","bounce"],nj=["stiffness","damping","mass"];function nF(t,e){return e.some(e=>void 0!==t[e])}function nI(t=nD.visualDuration,e=nD.bounce){let n;let i="object"!=typeof t?{visualDuration:t,keyframes:[0,1],bounce:e}:t,{restSpeed:r,restDelta:o}=i,a=i.keyframes[0],s=i.keyframes[i.keyframes.length-1],l={done:!1,value:a},{stiffness:u,damping:c,mass:d,duration:h,velocity:f,isResolvedFromDuration:p}=function(t){let e={velocity:nD.velocity,stiffness:nD.stiffness,damping:nD.damping,mass:nD.mass,isResolvedFromDuration:!1,...t};if(!nF(t,nj)&&nF(t,nL)){if(t.visualDuration){let n=2*Math.PI/(1.2*t.visualDuration),i=n*n,r=2*B(.05,1,1-(t.bounce||0))*Math.sqrt(i);e={...e,mass:nD.mass,stiffness:i,damping:r}}else{let n=function({duration:t=nD.duration,bounce:e=nD.bounce,velocity:n=nD.velocity,mass:i=nD.mass}){let r,o;J(t<=nc(nD.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let a=1-e;a=B(nD.minDamping,nD.maxDamping,a),t=B(nD.minDuration,nD.maxDuration,nd(t)),a<1?(r=e=>{let i=e*a,r=i*t;return .001-(i-n)/nV(e,a)*Math.exp(-r)},o=e=>{let i=e*a*t,o=Math.pow(a,2)*Math.pow(e,2)*t,s=nV(Math.pow(e,2),a);return(i*n+n-o)*Math.exp(-i)*(-r(e)+.001>0?-1:1)/s}):(r=e=>-.001+Math.exp(-e*t)*((e-n)*t+1),o=e=>t*t*(n-e)*Math.exp(-e*t));let s=function(t,e,n){let i=n;for(let n=1;n<12;n++)i-=t(i)/e(i);return i}(r,o,5/t);if(t=nc(t),isNaN(s))return{stiffness:nD.stiffness,damping:nD.damping,duration:t};{let e=Math.pow(s,2)*i;return{stiffness:e,damping:2*a*Math.sqrt(i*e),duration:t}}}(t);(e={...e,...n,mass:nD.mass}).isResolvedFromDuration=!0}}return e}({...i,velocity:-nd(i.velocity||0)}),m=f||0,v=c/(2*Math.sqrt(u*d)),g=s-a,y=nd(Math.sqrt(u/d)),w=5>Math.abs(g);if(r||(r=w?nD.restSpeed.granular:nD.restSpeed.default),o||(o=w?nD.restDelta.granular:nD.restDelta.default),v<1){let t=nV(y,v);n=e=>s-Math.exp(-v*y*e)*((m+v*y*g)/t*Math.sin(t*e)+g*Math.cos(t*e))}else if(1===v)n=t=>s-Math.exp(-y*t)*(g+(m+y*g)*t);else{let t=y*Math.sqrt(v*v-1);n=e=>{let n=Math.exp(-v*y*e),i=Math.min(t*e,300);return s-n*((m+v*y*g)*Math.sinh(i)+t*g*Math.cosh(i))/t}}let x={calculatedDuration:p&&h||null,next:t=>{let e=n(t);if(p)l.done=t>=h;else{let i=0===t?m:0;v<1&&(i=0===t?nc(m):nR(n,t,e));let a=Math.abs(i)<=r,u=Math.abs(s-e)<=o;l.done=a&&u}return l.value=l.done?s:e,l},toString:()=>{let t=Math.min(nk(x),2e4),e=nC(e=>x.next(t*e).value,t,30);return t+"ms "+e},toTransition:()=>{}};return x}function nO({keyframes:t,velocity:e=0,power:n=.8,timeConstant:i=325,bounceDamping:r=10,bounceStiffness:o=500,modifyTarget:a,min:s,max:l,restDelta:u=.5,restSpeed:c}){let d,h;let f=t[0],p={done:!1,value:f},m=t=>void 0!==s&&t<s||void 0!==l&&t>l,v=t=>void 0===s?l:void 0===l?s:Math.abs(s-t)<Math.abs(l-t)?s:l,g=n*e,y=f+g,w=void 0===a?y:a(y);w!==y&&(g=w-f);let x=t=>-g*Math.exp(-t/i),b=t=>w+x(t),S=t=>{let e=x(t),n=b(t);p.done=Math.abs(e)<=u,p.value=p.done?w:n},T=t=>{m(p.value)&&(d=t,h=nI({keyframes:[p.value,v(p.value)],velocity:nR(b,t,p.value),damping:r,stiffness:o,restDelta:u,restSpeed:c}))};return T(0),{calculatedDuration:null,next:t=>{let e=!1;return(h||void 0!==d||(e=!0,S(t),T(t)),void 0!==d&&t>=d)?h.next(t-d):(e||S(t),p)}}}nI.applyToOptions=t=>{let e=function(t,e=100,n){let i=n({...t,keyframes:[0,e]}),r=Math.min(nk(i),2e4);return{type:"keyframes",ease:t=>i.next(r*t).value/e,duration:nd(r)}}(t,100,nI);return t.ease=e.ease,t.duration=nc(e.duration),t.type="keyframes",t};let nB=(t,e,n)=>(((1-3*n+3*e)*t+(3*n-6*e))*t+3*e)*t;function nN(t,e,n,i){if(t===e&&n===i)return ta;let r=e=>(function(t,e,n,i,r){let o,a;let s=0;do(o=nB(a=e+(n-e)/2,i,r)-t)>0?n=a:e=a;while(Math.abs(o)>1e-7&&++s<12);return a})(e,0,1,t,n);return t=>0===t||1===t?t:nB(r(t),e,i)}let nW=nN(.42,0,1,1),nU=nN(0,0,.58,1),nH=nN(.42,0,.58,1),nz=t=>Array.isArray(t)&&"number"!=typeof t[0],nZ=t=>e=>e<=.5?t(2*e)/2:(2-t(2*(1-e)))/2,n_=t=>e=>1-t(1-e),nK=nN(.33,1.53,.69,.99),n$=n_(nK),nY=nZ(n$),nX=t=>(t*=2)<1?.5*n$(t):.5*(2-Math.pow(2,-10*(t-1))),nq=t=>1-Math.sin(Math.acos(t)),nG=n_(nq),nJ=nZ(nq),nQ=t=>Array.isArray(t)&&"number"==typeof t[0],n0={linear:ta,easeIn:nW,easeInOut:nH,easeOut:nU,circIn:nq,circInOut:nJ,circOut:nG,backIn:n$,backInOut:nY,backOut:nK,anticipate:nX},n1=t=>"string"==typeof t,n2=t=>{if(nQ(t)){Q(4===t.length,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");let[e,n,i,r]=t;return nN(e,n,i,r)}return n1(t)?(Q(void 0!==n0[t],`Invalid easing type '${t}'`,"invalid-easing-type"),n0[t]):t},n5=(t,e,n)=>{let i=e-t;return 0===i?1:(n-t)/i};function n3({duration:t=300,keyframes:e,times:n,ease:i="easeInOut"}){let r=nz(i)?i.map(n2):n2(i),o={done:!1,value:e[0]},a=function(t,e,{clamp:n=!0,ease:i,mixer:r}={}){let o=t.length;if(Q(o===e.length,"Both input and output ranges must be the same length","range-length"),1===o)return()=>e[0];if(2===o&&e[0]===e[1])return()=>e[1];let a=t[0]===t[1];t[0]>t[o-1]&&(t=[...t].reverse(),e=[...e].reverse());let s=function(t,e,n){let i=[],r=n||ts.mix||nA,o=t.length-1;for(let n=0;n<o;n++){let o=r(t[n],t[n+1]);e&&(o=nu(Array.isArray(e)?e[n]||ta:e,o)),i.push(o)}return i}(e,i,r),l=s.length,u=n=>{if(a&&n<t[0])return e[0];let i=0;if(l>1)for(;i<t.length-2&&!(n<t[i+1]);i++);let r=n5(t[i],t[i+1],n);return s[i](r)};return n?e=>u(B(t[0],t[o-1],e)):u}((n&&n.length===e.length?n:function(t){let e=[0];return function(t,e){let n=t[t.length-1];for(let i=1;i<=e;i++){let r=n5(0,e,i);t.push(E(n,1,r))}}(e,t.length-1),e}(e)).map(e=>e*t),e,{ease:Array.isArray(r)?r:e.map(()=>r||nH).splice(0,e.length-1)});return{calculatedDuration:t,next:e=>(o.value=a(e),o.done=e>=t,o)}}let n6=t=>null!==t;function n9(t,{repeat:e,repeatType:n="loop"},i,r=1){let o=t.filter(n6),a=r<0||e&&"loop"!==n&&e%2==1?0:o.length-1;return a&&void 0!==i?i:o[a]}let n4={decay:nO,inertia:nO,tween:n3,keyframes:n3,spring:nI};function n7(t){"string"==typeof t.type&&(t.type=n4[t.type])}class n8{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,e){return this.finished.then(t,e)}}let it=t=>t/100;class ie extends n8{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{let{motionValue:t}=this.options;t&&t.updatedAt!==t2.now()&&this.tick(t2.now()),this.isStopped=!0,"idle"!==this.state&&(this.teardown(),this.options.onStop?.())},nh.mainThread++,this.options=t,this.initAnimation(),this.play(),!1===t.autoplay&&this.pause()}initAnimation(){let{options:t}=this;n7(t);let{type:e=n3,repeat:n=0,repeatDelay:i=0,repeatType:r,velocity:o=0}=t,{keyframes:a}=t,s=e||n3;s!==n3&&"number"!=typeof a[0]&&(this.mixKeyframes=nu(it,nA(a[0],a[1])),a=[0,100]);let l=s({...t,keyframes:a});"mirror"===r&&(this.mirroredGenerator=s({...t,keyframes:[...a].reverse(),velocity:-o})),null===l.calculatedDuration&&(l.calculatedDuration=nk(l));let{calculatedDuration:u}=l;this.calculatedDuration=u,this.resolvedDuration=u+i,this.totalDuration=this.resolvedDuration*(n+1)-i,this.generator=l}updateTime(t){let e=Math.round(t-this.startTime)*this.playbackSpeed;null!==this.holdTime?this.currentTime=this.holdTime:this.currentTime=e}tick(t,e=!1){let{generator:n,totalDuration:i,mixKeyframes:r,mirroredGenerator:o,resolvedDuration:a,calculatedDuration:s}=this;if(null===this.startTime)return n.next(0);let{delay:l=0,keyframes:u,repeat:c,repeatType:d,repeatDelay:h,type:f,onUpdate:p,finalKeyframe:m}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-i/this.speed,this.startTime)),e?this.currentTime=t:this.updateTime(t);let v=this.currentTime-l*(this.playbackSpeed>=0?1:-1),g=this.playbackSpeed>=0?v<0:v>i;this.currentTime=Math.max(v,0),"finished"===this.state&&null===this.holdTime&&(this.currentTime=i);let y=this.currentTime,w=n;if(c){let t=Math.min(this.currentTime,i)/a,e=Math.floor(t),n=t%1;!n&&t>=1&&(n=1),1===n&&e--,(e=Math.min(e,c+1))%2&&("reverse"===d?(n=1-n,h&&(n-=h/a)):"mirror"===d&&(w=o)),y=B(0,1,n)*a}let x=g?{done:!1,value:u[0]}:w.next(y);r&&(x.value=r(x.value));let{done:b}=x;g||null===s||(b=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);let S=null===this.holdTime&&("finished"===this.state||"running"===this.state&&b);return S&&f!==nO&&(x.value=n9(u,this.options,m,this.speed)),p&&p(x.value),S&&this.finish(),x}then(t,e){return this.finished.then(t,e)}get duration(){return nd(this.calculatedDuration)}get time(){return nd(this.currentTime)}set time(t){t=nc(t),this.currentTime=t,null===this.startTime||null!==this.holdTime||0===this.playbackSpeed?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(t2.now());let e=this.playbackSpeed!==t;this.playbackSpeed=t,e&&(this.time=nd(this.currentTime))}play(){if(this.isStopped)return;let{driver:t=nM,startTime:e}=this.options;this.driver||(this.driver=t(t=>this.tick(t))),this.options.onPlay?.();let n=this.driver.now();"finished"===this.state?(this.updateFinished(),this.startTime=n):null!==this.holdTime?this.startTime=n-this.holdTime:this.startTime||(this.startTime=e??n),"finished"===this.state&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(t2.now()),this.holdTime=this.currentTime}complete(){"running"!==this.state&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null,nh.mainThread--}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}}let ii=t=>t.startsWith("--");function ir(t){let e;return()=>(void 0===e&&(e=t()),e)}let io=ir(()=>void 0!==window.ScrollTimeline),ia={},is=function(t,e){let n=ir(t);return()=>ia[e]??n()}(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch(t){return!1}return!0},"linearEasing"),il=([t,e,n,i])=>`cubic-bezier(${t}, ${e}, ${n}, ${i})`,iu={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:il([0,.65,.55,1]),circOut:il([.55,0,1,.45]),backIn:il([.31,.01,.66,-.59]),backOut:il([.33,1.53,.69,.99])};function ic(t){return"function"==typeof t&&"applyToOptions"in t}class id extends n8{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,!t)return;let{element:e,name:n,keyframes:i,pseudoElement:r,allowFlatten:o=!1,finalKeyframe:a,onComplete:s}=t;this.isPseudoElement=!!r,this.allowFlatten=o,this.options=t,Q("string"!=typeof t.type,'Mini animate() doesn\'t support "type" as a string.',"mini-spring");let l=function({type:t,...e}){return ic(t)&&is()?t.applyToOptions(e):(e.duration??(e.duration=300),e.ease??(e.ease="easeOut"),e)}(t);this.animation=function(t,e,n,{delay:i=0,duration:r=300,repeat:o=0,repeatType:a="loop",ease:s="easeOut",times:l}={},u){let c={[e]:n};l&&(c.offset=l);let d=function t(e,n){if(e)return"function"==typeof e?is()?nC(e,n):"ease-out":nQ(e)?il(e):Array.isArray(e)?e.map(e=>t(e,n)||iu.easeOut):iu[e]}(s,r);Array.isArray(d)&&(c.easing=d),tu.value&&nh.waapi++;let h={delay:i,duration:r,easing:Array.isArray(d)?"linear":d,fill:"both",iterations:o+1,direction:"reverse"===a?"alternate":"normal"};u&&(h.pseudoElement=u);let f=t.animate(c,h);return tu.value&&f.finished.finally(()=>{nh.waapi--}),f}(e,n,i,l,r),!1===l.autoplay&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!r){let t=n9(i,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(t):ii(n)?e.style.setProperty(n,t):e.style[n]=t,this.animation.cancel()}s?.(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),"finished"===this.state&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch(t){}}stop(){if(this.isStopped)return;this.isStopped=!0;let{state:t}=this;"idle"!==t&&"finished"!==t&&(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){return nd(Number(this.animation.effect?.getComputedTiming?.().duration||0))}get time(){return nd(Number(this.animation.currentTime)||0)}set time(t){this.finishedTime=null,this.animation.currentTime=nc(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return null!==this.finishedTime?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(t){this.animation.startTime=t}attachTimeline({timeline:t,observe:e}){return(this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&io())?(this.animation.timeline=t,ta):e(this)}}let ih={anticipate:nX,backInOut:nY,circInOut:nJ};class ip extends id{constructor(t){"string"==typeof t.ease&&t.ease in ih&&(t.ease=ih[t.ease]),n7(t),super(t),t.startTime&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){let{motionValue:e,onUpdate:n,onComplete:i,element:r,...o}=this.options;if(!e)return;if(void 0!==t){e.set(t);return}let a=new ie({...o,autoplay:!1}),s=nc(this.finishedTime??this.time);e.setWithVelocity(a.sample(s-10).value,a.sample(s).value,10),a.stop()}}let im=(t,e)=>"zIndex"!==e&&!!("number"==typeof t||Array.isArray(t)||"string"==typeof t&&(tH.test(t)||"0"===t)&&!t.startsWith("url(")),iv=new Set(["opacity","clipPath","filter","transform"]),ig=ir(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));class iy extends n8{constructor({autoplay:t=!0,delay:e=0,type:n="keyframes",repeat:i=0,repeatDelay:r=0,repeatType:o="loop",keyframes:a,name:s,motionValue:l,element:u,...c}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=t2.now();let d={autoplay:t,delay:e,type:n,repeat:i,repeatDelay:r,repeatType:o,name:s,motionValue:l,element:u,...c},h=u?.KeyframeResolver||tb;this.keyframeResolver=new h(a,(t,e,n)=>this.onKeyframesResolved(t,e,d,!n),s,l,u),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,e,n,i){this.keyframeResolver=void 0;let{name:r,type:o,velocity:a,delay:s,isHandoff:l,onUpdate:u}=n;this.resolvedAt=t2.now(),!function(t,e,n,i){let r=t[0];if(null===r)return!1;if("display"===e||"visibility"===e)return!0;let o=t[t.length-1],a=im(r,e),s=im(o,e);return J(a===s,`You are trying to animate ${e} from "${r}" to "${o}". "${a?o:r}" is not an animatable value.`,"value-not-animatable"),!!a&&!!s&&(function(t){let e=t[0];if(1===t.length)return!0;for(let n=0;n<t.length;n++)if(t[n]!==e)return!0}(t)||("spring"===n||ic(n))&&i)}(t,r,o,a)&&((ts.instantAnimations||!s)&&u?.(n9(t,n,e)),t[0]=t[t.length-1],ns(n),n.repeat=0);let c={startTime:i?this.resolvedAt&&this.resolvedAt-this.createdAt>40?this.resolvedAt:this.createdAt:void 0,finalKeyframe:e,...n,keyframes:t},d=!l&&function(t){let{motionValue:e,name:n,repeatDelay:i,repeatType:r,damping:o,type:a}=t;if(!(e?.owner?.current instanceof HTMLElement))return!1;let{onUpdate:s,transformTemplate:l}=e.owner.getProps();return ig()&&n&&iv.has(n)&&("transform"!==n||!l)&&!s&&!i&&"mirror"!==r&&0!==o&&"inertia"!==a}(c)?new ip({...c,element:c.motionValue.owner.current}):new ie(c);d.finished.then(()=>this.notifyFinished()).catch(ta),this.pendingTimeline&&(this.stopTimeline=d.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=d}get finished(){return this._animation?this.animation.finished:this._finished}then(t,e){return this.finished.finally(t).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),ty=!0,tx(),tw(),ty=!1),this._animation}get duration(){return this.animation.duration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}}let iw=t=>null!==t,ix={type:"spring",stiffness:500,damping:25,restSpeed:10},ib=t=>({type:"spring",stiffness:550,damping:0===t?2*Math.sqrt(550):30,restSpeed:10}),iS={type:"keyframes",duration:.8},iT={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},iP=(t,{keyframes:e})=>e.length>2?iS:s.has(t)?t.startsWith("scale")?ib(e[1]):ix:iT,iE=(t,e,n,i={},r,o)=>a=>{let s=nr(i,t)||{},l=s.delay||i.delay||0,{elapsed:u=0}=i;u-=nc(l);let c={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:e.getVelocity(),...s,delay:-u,onUpdate:t=>{e.set(t),s.onUpdate&&s.onUpdate(t)},onComplete:()=>{a(),s.onComplete&&s.onComplete()},name:t,motionValue:e,element:o?void 0:r};!function({when:t,delay:e,delayChildren:n,staggerChildren:i,staggerDirection:r,repeat:o,repeatType:a,repeatDelay:s,from:l,elapsed:u,...c}){return!!Object.keys(c).length}(s)&&Object.assign(c,iP(t,c)),c.duration&&(c.duration=nc(c.duration)),c.repeatDelay&&(c.repeatDelay=nc(c.repeatDelay)),void 0!==c.from&&(c.keyframes[0]=c.from);let d=!1;if(!1!==c.type&&(0!==c.duration||c.repeatDelay)||(ns(c),0!==c.delay||(d=!0)),(ts.instantAnimations||ts.skipAnimations)&&(d=!0,ns(c),c.delay=0),c.allowFlatten=!s.type&&!s.ease,d&&!o&&void 0!==e.get()){let t=function(t,{repeat:e,repeatType:n="loop"},i){let r=t.filter(iw),o=e&&"loop"!==n&&e%2==1?0:r.length-1;return r[o]}(c.keyframes,s);if(void 0!==t){td.update(()=>{c.onUpdate(t),c.onComplete()});return}}return s.isSync?new ie(c):new iy(c)};function iA(t,e,{delay:n=0,transitionOverride:i,type:r}={}){let{transition:o=t.getDefaultTransition(),transitionEnd:a,...s}=e;i&&(o=i);let l=[],u=r&&t.animationState&&t.animationState.getState()[r];for(let e in s){let i=t.getValue(e,t.latestValues[e]??null),r=s[e];if(void 0===r||u&&function({protectedKeys:t,needsAnimating:e},n){let i=t.hasOwnProperty(n)&&!0!==e[n];return e[n]=!1,i}(u,e))continue;let a={delay:n,...nr(o||{},e)},c=i.get();if(void 0!==c&&!i.isAnimating&&!Array.isArray(r)&&r===c&&!a.velocity)continue;let d=!1;if(window.MotionHandoffAnimation){let n=t.props[e8];if(n){let t=window.MotionHandoffAnimation(n,e,td);null!==t&&(a.startTime=t,d=!0)}}na(t,e),i.start(iE(e,i,r,t.shouldReduceMotion&&O.has(e)?{type:!1}:a,t,d));let h=i.animation;h&&l.push(h)}return a&&Promise.all(l).then(()=>{td.update(()=>{a&&function(t,e){let{transitionEnd:n={},transition:i={},...r}=ni(t,e)||{};for(let e in r={...r,...n}){var o;let n=no(o=r[e])?o[o.length-1]||0:o;t.hasValue(e)?t.getValue(e).set(n):t.addValue(e,t8(n))}}(t,a)})}),l}function iM(t,e,n,i=0,r=1){let o=Array.from(t).sort((t,e)=>t.sortNodePosition(e)).indexOf(e),a=t.size,s=(a-1)*i;return"function"==typeof n?n(o,a):1===r?o*i:s-o*i}function iC(t,e,n={}){let i=ni(t,e,"exit"===n.type?t.presenceContext?.custom:void 0),{transition:r=t.getDefaultTransition()||{}}=i||{};n.transitionOverride&&(r=n.transitionOverride);let o=i?()=>Promise.all(iA(t,i,n)):()=>Promise.resolve(),a=t.variantChildren&&t.variantChildren.size?(i=0)=>{let{delayChildren:o=0,staggerChildren:a,staggerDirection:s}=r;return function(t,e,n=0,i=0,r=0,o=1,a){let s=[];for(let l of t.variantChildren)l.notify("AnimationStart",e),s.push(iC(l,e,{...a,delay:n+("function"==typeof i?0:i)+iM(t.variantChildren,l,i,r,o)}).then(()=>l.notify("AnimationComplete",e)));return Promise.all(s)}(t,e,i,o,a,s,n)}:()=>Promise.resolve(),{when:s}=r;if(!s)return Promise.all([o(),a(n.delay)]);{let[t,e]="beforeChildren"===s?[o,a]:[a,o];return t().then(()=>e())}}function ik(t,e){if(!Array.isArray(e))return!1;let n=e.length;if(n!==t.length)return!1;for(let i=0;i<n;i++)if(e[i]!==t[i])return!1;return!0}let iR=eg.length,iD=[...ev].reverse(),iV=ev.length;function iL(t=!1){return{isActive:t,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function ij(){return{animate:iL(!0),whileInView:iL(),whileHover:iL(),whileTap:iL(),whileDrag:iL(),whileFocus:iL(),exit:iL()}}class iF{constructor(t){this.isMounted=!1,this.node=t}update(){}}class iI extends iF{constructor(t){super(t),t.animationState||(t.animationState=function(t){let e=e=>Promise.all(e.map(({animation:e,options:n})=>(function(t,e,n={}){let i;if(t.notify("AnimationStart",e),Array.isArray(e))i=Promise.all(e.map(e=>iC(t,e,n)));else if("string"==typeof e)i=iC(t,e,n);else{let r="function"==typeof e?ni(t,e,n.custom):e;i=Promise.all(iA(t,r,n))}return i.then(()=>{t.notify("AnimationComplete",e)})})(t,e,n))),n=ij(),i=!0,r=e=>(n,i)=>{let r=ni(t,i,"exit"===e?t.presenceContext?.custom:void 0);if(r){let{transition:t,transitionEnd:e,...i}=r;n={...n,...i,...e}}return n};function o(o){let{props:a}=t,s=function t(e){if(!e)return;if(!e.isControllingVariants){let n=e.parent&&t(e.parent)||{};return void 0!==e.props.initial&&(n.initial=e.props.initial),n}let n={};for(let t=0;t<iR;t++){let i=eg[t],r=e.props[i];(em(r)||!1===r)&&(n[i]=r)}return n}(t.parent)||{},l=[],u=new Set,c={},d=1/0;for(let e=0;e<iV;e++){var h;let f=iD[e],p=n[f],m=void 0!==a[f]?a[f]:s[f],v=em(m),g=f===o?p.isActive:null;!1===g&&(d=e);let y=m===s[f]&&m!==a[f]&&v;if(y&&i&&t.manuallyAnimateOnMount&&(y=!1),p.protectedKeys={...c},!p.isActive&&null===g||!m&&!p.prevProp||ep(m)||"boolean"==typeof m)continue;let w=(h=p.prevProp,"string"==typeof m?m!==h:!!Array.isArray(m)&&!ik(m,h)),x=w||f===o&&p.isActive&&!y&&v||e>d&&v,b=!1,S=Array.isArray(m)?m:[m],T=S.reduce(r(f),{});!1===g&&(T={});let{prevResolvedValues:P={}}=p,E={...P,...T},A=e=>{x=!0,u.has(e)&&(b=!0,u.delete(e)),p.needsAnimating[e]=!0;let n=t.getValue(e);n&&(n.liveStyle=!1)};for(let t in E){let e=T[t],n=P[t];if(!c.hasOwnProperty(t))(no(e)&&no(n)?ik(e,n):e===n)?void 0!==e&&u.has(t)?A(t):p.protectedKeys[t]=!0:null!=e?A(t):u.add(t)}p.prevProp=m,p.prevResolvedValues=T,p.isActive&&(c={...c,...T}),i&&t.blockInitialAnimation&&(x=!1);let M=y&&w,C=!M||b;x&&C&&l.push(...S.map(e=>{let n={type:f};if("string"==typeof e&&i&&!M&&t.manuallyAnimateOnMount&&t.parent){let{parent:i}=t,r=ni(i,e);if(i.enteringChildren&&r){let{delayChildren:e}=r.transition||{};n.delay=iM(i.enteringChildren,t,e)}}return{animation:e,options:n}}))}if(u.size){let e={};if("boolean"!=typeof a.initial){let n=ni(t,Array.isArray(a.initial)?a.initial[0]:a.initial);n&&n.transition&&(e.transition=n.transition)}u.forEach(n=>{let i=t.getBaseTarget(n),r=t.getValue(n);r&&(r.liveStyle=!0),e[n]=i??null}),l.push({animation:e})}let f=!!l.length;return i&&(!1===a.initial||a.initial===a.animate)&&!t.manuallyAnimateOnMount&&(f=!1),i=!1,f?e(l):Promise.resolve()}return{animateChanges:o,setActive:function(e,i){if(n[e].isActive===i)return Promise.resolve();t.variantChildren?.forEach(t=>t.animationState?.setActive(e,i)),n[e].isActive=i;let r=o(e);for(let t in n)n[t].protectedKeys={};return r},setAnimateFunction:function(n){e=n(t)},getState:()=>n,reset:()=>{n=ij(),i=!0}}}(t))}updateAnimationControlsSubscription(){let{animate:t}=this.node.getProps();ep(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){let{animate:t}=this.node.getProps(),{animate:e}=this.node.prevProps||{};t!==e&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}}let iO=0;class iB extends iF{constructor(){super(...arguments),this.id=iO++}update(){if(!this.node.presenceContext)return;let{isPresent:t,onExitComplete:e}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===n)return;let i=this.node.animationState.setActive("exit",!t);e&&!t&&i.then(()=>{e(this.id)})}mount(){let{register:t,onExitComplete:e}=this.node.presenceContext||{};e&&e(this.id),t&&(this.unmount=t(this.id))}unmount(){}}let iN={x:!1,y:!1};function iW(t,e,n,i={passive:!0}){return t.addEventListener(e,n,i),()=>t.removeEventListener(e,n)}let iU=t=>"mouse"===t.pointerType?"number"!=typeof t.button||t.button<=0:!1!==t.isPrimary;function iH(t){return{point:{x:t.pageX,y:t.pageY}}}let iz=t=>e=>iU(e)&&t(e,iH(e));function iZ(t,e,n,i){return iW(t,e,iz(n),i)}function i_(t){return t.max-t.min}function iK(t,e,n,i=.5){t.origin=i,t.originPoint=E(e.min,e.max,t.origin),t.scale=i_(n)/i_(e),t.translate=E(n.min,n.max,t.origin)-t.originPoint,(t.scale>=.9999&&t.scale<=1.0001||isNaN(t.scale))&&(t.scale=1),(t.translate>=-.01&&t.translate<=.01||isNaN(t.translate))&&(t.translate=0)}function i$(t,e,n,i){iK(t.x,e.x,n.x,i?i.originX:void 0),iK(t.y,e.y,n.y,i?i.originY:void 0)}function iY(t,e,n){t.min=n.min+e.min,t.max=t.min+i_(e)}function iX(t,e,n){t.min=e.min-n.min,t.max=t.min+i_(e)}function iq(t,e,n){iX(t.x,e.x,n.x),iX(t.y,e.y,n.y)}function iG(t){return[t("x"),t("y")]}let iJ=({current:t})=>t?t.ownerDocument.defaultView:null,iQ=(t,e)=>Math.abs(t-e);class i0{constructor(t,e,{transformPagePoint:n,contextWindow:i=window,dragSnapToOrigin:r=!1,distanceThreshold:o=3}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{var t,e;if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let n=i5(this.lastMoveEventInfo,this.history),i=null!==this.startEvent,r=(t=n.offset,e={x:0,y:0},Math.sqrt(iQ(t.x,e.x)**2+iQ(t.y,e.y)**2)>=this.distanceThreshold);if(!i&&!r)return;let{point:o}=n,{timestamp:a}=tf;this.history.push({...o,timestamp:a});let{onStart:s,onMove:l}=this.handlers;i||(s&&s(this.lastMoveEvent,n),this.startEvent=this.lastMoveEvent),l&&l(this.lastMoveEvent,n)},this.handlePointerMove=(t,e)=>{this.lastMoveEvent=t,this.lastMoveEventInfo=i1(e,this.transformPagePoint),td.update(this.updatePoint,!0)},this.handlePointerUp=(t,e)=>{this.end();let{onEnd:n,onSessionEnd:i,resumeAnimation:r}=this.handlers;if(this.dragSnapToOrigin&&r&&r(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;let o=i5("pointercancel"===t.type?this.lastMoveEventInfo:i1(e,this.transformPagePoint),this.history);this.startEvent&&n&&n(t,o),i&&i(t,o)},!iU(t))return;this.dragSnapToOrigin=r,this.handlers=e,this.transformPagePoint=n,this.distanceThreshold=o,this.contextWindow=i||window;let a=i1(iH(t),this.transformPagePoint),{point:s}=a,{timestamp:l}=tf;this.history=[{...s,timestamp:l}];let{onSessionStart:u}=e;u&&u(t,i5(a,this.history)),this.removeListeners=nu(iZ(this.contextWindow,"pointermove",this.handlePointerMove),iZ(this.contextWindow,"pointerup",this.handlePointerUp),iZ(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),th(this.updatePoint)}}function i1(t,e){return e?{point:e(t.point)}:t}function i2(t,e){return{x:t.x-e.x,y:t.y-e.y}}function i5({point:t},e){return{point:t,delta:i2(t,i3(e)),offset:i2(t,e[0]),velocity:function(t,e){if(t.length<2)return{x:0,y:0};let n=t.length-1,i=null,r=i3(t);for(;n>=0&&(i=t[n],!(r.timestamp-i.timestamp>nc(.1)));)n--;if(!i)return{x:0,y:0};let o=nd(r.timestamp-i.timestamp);if(0===o)return{x:0,y:0};let a={x:(r.x-i.x)/o,y:(r.y-i.y)/o};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}(e,0)}}function i3(t){return t[t.length-1]}function i6(t,e,n){return{min:void 0!==e?t.min+e:void 0,max:void 0!==n?t.max+n-(t.max-t.min):void 0}}function i9(t,e){let n=e.min-t.min,i=e.max-t.max;return e.max-e.min<t.max-t.min&&([n,i]=[i,n]),{min:n,max:i}}function i4(t,e,n){return{min:i7(t,e),max:i7(t,n)}}function i7(t,e){return"number"==typeof t?t:t[e]||0}let i8=new WeakMap;class rt{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=eu(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:e=!1,distanceThreshold:n}={}){let{presenceContext:i}=this.visualElement;if(i&&!1===i.isPresent)return;let{dragSnapToOrigin:r}=this.getProps();this.panSession=new i0(t,{onSessionStart:t=>{let{dragSnapToOrigin:n}=this.getProps();n?this.pauseAnimation():this.stopAnimation(),e&&this.snapToCursor(iH(t).point)},onStart:(t,e)=>{let{drag:n,dragPropagation:i,onDragStart:r}=this.getProps();if(n&&!i&&(this.openDragLock&&this.openDragLock(),this.openDragLock="x"===n||"y"===n?iN[n]?null:(iN[n]=!0,()=>{iN[n]=!1}):iN.x||iN.y?null:(iN.x=iN.y=!0,()=>{iN.x=iN.y=!1}),!this.openDragLock))return;this.latestPointerEvent=t,this.latestPanInfo=e,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),iG(t=>{let e=this.getAxisMotionValue(t).get()||0;if(Z.test(e)){let{projection:n}=this.visualElement;if(n&&n.layout){let i=n.layout.layoutBox[t];if(i){let t=i_(i);e=parseFloat(e)/100*t}}}this.originPoint[t]=e}),r&&td.postRender(()=>r(t,e)),na(this.visualElement,"transform");let{animationState:o}=this.visualElement;o&&o.setActive("whileDrag",!0)},onMove:(t,e)=>{this.latestPointerEvent=t,this.latestPanInfo=e;let{dragPropagation:n,dragDirectionLock:i,onDirectionLock:r,onDrag:o}=this.getProps();if(!n&&!this.openDragLock)return;let{offset:a}=e;if(i&&null===this.currentDirection){this.currentDirection=function(t,e=10){let n=null;return Math.abs(t.y)>e?n="y":Math.abs(t.x)>e&&(n="x"),n}(a),null!==this.currentDirection&&r&&r(this.currentDirection);return}this.updateAxis("x",e.point,a),this.updateAxis("y",e.point,a),this.visualElement.render(),o&&o(t,e)},onSessionEnd:(t,e)=>{this.latestPointerEvent=t,this.latestPanInfo=e,this.stop(t,e),this.latestPointerEvent=null,this.latestPanInfo=null},resumeAnimation:()=>iG(t=>"paused"===this.getAnimationState(t)&&this.getAxisMotionValue(t).animation?.play())},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:r,distanceThreshold:n,contextWindow:iJ(this.visualElement)})}stop(t,e){let n=t||this.latestPointerEvent,i=e||this.latestPanInfo,r=this.isDragging;if(this.cancel(),!r||!i||!n)return;let{velocity:o}=i;this.startAnimation(o);let{onDragEnd:a}=this.getProps();a&&td.postRender(()=>a(n,i))}cancel(){this.isDragging=!1;let{projection:t,animationState:e}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;let{dragPropagation:n}=this.getProps();!n&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),e&&e.setActive("whileDrag",!1)}updateAxis(t,e,n){let{drag:i}=this.getProps();if(!n||!re(t,i,this.currentDirection))return;let r=this.getAxisMotionValue(t),o=this.originPoint[t]+n[t];this.constraints&&this.constraints[t]&&(o=function(t,{min:e,max:n},i){return void 0!==e&&t<e?t=i?E(e,t,i.min):Math.max(t,e):void 0!==n&&t>n&&(t=i?E(n,t,i.max):Math.min(t,n)),t}(o,this.constraints[t],this.elastic[t])),r.set(o)}resolveConstraints(){let{dragConstraints:t,dragElastic:e}=this.getProps(),n=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,i=this.constraints;t&&e7(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&n?this.constraints=function(t,{top:e,left:n,bottom:i,right:r}){return{x:i6(t.x,n,r),y:i6(t.y,e,i)}}(n.layoutBox,t):this.constraints=!1,this.elastic=function(t=.35){return!1===t?t=0:!0===t&&(t=.35),{x:i4(t,"left","right"),y:i4(t,"top","bottom")}}(e),i!==this.constraints&&n&&this.constraints&&!this.hasMutatedConstraints&&iG(t=>{!1!==this.constraints&&this.getAxisMotionValue(t)&&(this.constraints[t]=function(t,e){let n={};return void 0!==e.min&&(n.min=e.min-t.min),void 0!==e.max&&(n.max=e.max-t.min),n}(n.layoutBox[t],this.constraints[t]))})}resolveRefConstraints(){var t;let{dragConstraints:e,onMeasureDragConstraints:n}=this.getProps();if(!e||!e7(e))return!1;let i=e.current;Q(null!==i,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.","drag-constraints-ref");let{projection:r}=this.visualElement;if(!r||!r.layout)return!1;let o=function(t,e,n){let i=I(t,n),{scroll:r}=e;return r&&(L(i.x,r.offset.x),L(i.y,r.offset.y)),i}(i,r.root,this.visualElement.getTransformPagePoint()),a={x:i9((t=r.layout.layoutBox).x,o.x),y:i9(t.y,o.y)};if(n){let t=n(function({x:t,y:e}){return{top:e.min,right:t.max,bottom:e.max,left:t.min}}(a));this.hasMutatedConstraints=!!t,t&&(a=P(t))}return a}startAnimation(t){let{drag:e,dragMomentum:n,dragElastic:i,dragTransition:r,dragSnapToOrigin:o,onDragTransitionEnd:a}=this.getProps(),s=this.constraints||{};return Promise.all(iG(a=>{if(!re(a,e,this.currentDirection))return;let l=s&&s[a]||{};o&&(l={min:0,max:0});let u={type:"inertia",velocity:n?t[a]:0,bounceStiffness:i?200:1e6,bounceDamping:i?40:1e7,timeConstant:750,restDelta:1,restSpeed:10,...r,...l};return this.startAxisValueAnimation(a,u)})).then(a)}startAxisValueAnimation(t,e){let n=this.getAxisMotionValue(t);return na(this.visualElement,t),n.start(iE(t,n,0,e,this.visualElement,!1))}stopAnimation(){iG(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){iG(t=>this.getAxisMotionValue(t).animation?.pause())}getAnimationState(t){return this.getAxisMotionValue(t).animation?.state}getAxisMotionValue(t){let e=`_drag${t.toUpperCase()}`,n=this.visualElement.getProps();return n[e]||this.visualElement.getValue(t,(n.initial?n.initial[t]:void 0)||0)}snapToCursor(t){iG(e=>{let{drag:n}=this.getProps();if(!re(e,n,this.currentDirection))return;let{projection:i}=this.visualElement,r=this.getAxisMotionValue(e);if(i&&i.layout){let{min:n,max:o}=i.layout.layoutBox[e];r.set(t[e]-E(n,o,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;let{drag:t,dragConstraints:e}=this.getProps(),{projection:n}=this.visualElement;if(!e7(e)||!n||!this.constraints)return;this.stopAnimation();let i={x:0,y:0};iG(t=>{let e=this.getAxisMotionValue(t);if(e&&!1!==this.constraints){let n=e.get();i[t]=function(t,e){let n=.5,i=i_(t),r=i_(e);return r>i?n=n5(e.min,e.max-i,t.min):i>r&&(n=n5(t.min,t.max-r,e.min)),B(0,1,n)}({min:n,max:n},this.constraints[t])}});let{transformTemplate:r}=this.visualElement.getProps();this.visualElement.current.style.transform=r?r({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),iG(e=>{if(!re(e,t,null))return;let n=this.getAxisMotionValue(e),{min:r,max:o}=this.constraints[e];n.set(E(r,o,i[e]))})}addListeners(){if(!this.visualElement.current)return;i8.set(this.visualElement,this);let t=iZ(this.visualElement.current,"pointerdown",t=>{let{drag:e,dragListener:n=!0}=this.getProps();e&&n&&this.start(t)}),e=()=>{let{dragConstraints:t}=this.getProps();e7(t)&&t.current&&(this.constraints=this.resolveRefConstraints())},{projection:n}=this.visualElement,i=n.addEventListener("measure",e);n&&!n.layout&&(n.root&&n.root.updateScroll(),n.updateLayout()),td.read(e);let r=iW(window,"resize",()=>this.scalePositionWithinConstraints()),o=n.addEventListener("didUpdate",({delta:t,hasLayoutChanged:e})=>{this.isDragging&&e&&(iG(e=>{let n=this.getAxisMotionValue(e);n&&(this.originPoint[e]+=t[e].translate,n.set(n.get()+t[e].translate))}),this.visualElement.render())});return()=>{r(),t(),i(),o&&o()}}getProps(){let t=this.visualElement.getProps(),{drag:e=!1,dragDirectionLock:n=!1,dragPropagation:i=!1,dragConstraints:r=!1,dragElastic:o=.35,dragMomentum:a=!0}=t;return{...t,drag:e,dragDirectionLock:n,dragPropagation:i,dragConstraints:r,dragElastic:o,dragMomentum:a}}}function re(t,e,n){return(!0===e||e===t)&&(null===n||n===t)}class rn extends iF{constructor(t){super(t),this.removeGroupControls=ta,this.removeListeners=ta,this.controls=new rt(t)}mount(){let{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||ta}unmount(){this.removeGroupControls(),this.removeListeners()}}let ri=t=>(e,n)=>{t&&td.postRender(()=>t(e,n))};class rr extends iF{constructor(){super(...arguments),this.removePointerDownListener=ta}onPointerDown(t){this.session=new i0(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:iJ(this.node)})}createPanHandlers(){let{onPanSessionStart:t,onPanStart:e,onPan:n,onPanEnd:i}=this.node.getProps();return{onSessionStart:ri(t),onStart:ri(e),onMove:n,onEnd:(t,e)=>{delete this.session,i&&td.postRender(()=>i(t,e))}}}mount(){this.removePointerDownListener=iZ(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let ro={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function ra(t,e){return e.max===e.min?0:t/(e.max-e.min)*100}let rs={correct:(t,e)=>{if(!e.target)return t;if("string"==typeof t){if(!_.test(t))return t;t=parseFloat(t)}let n=ra(t,e.target.x),i=ra(t,e.target.y);return`${n}% ${i}%`}},rl=!1;class ru extends o.Component{componentDidMount(){let{visualElement:t,layoutGroup:e,switchLayoutGroup:n,layoutId:i}=this.props,{projection:r}=t;!function(t){for(let e in t)eR[e]=t[e],x(e)&&(eR[e].isCSSVariable=!0)}(rd),r&&(e.group&&e.group.add(r),n&&n.register&&i&&n.register(r),rl&&r.root.didUpdate(),r.addEventListener("animationComplete",()=>{this.safeToRemove()}),r.setOptions({...r.options,onExitComplete:()=>this.safeToRemove()})),ro.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){let{layoutDependency:e,visualElement:n,drag:i,isPresent:r}=this.props,{projection:o}=n;return o&&(o.isPresent=r,rl=!0,i||t.layoutDependency!==e||void 0===e||t.isPresent!==r?o.willUpdate():this.safeToRemove(),t.isPresent===r||(r?o.promote():o.relegate()||td.postRender(()=>{let t=o.getStack();t&&t.members.length||this.safeToRemove()}))),null}componentDidUpdate(){let{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),en.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){let{visualElement:t,layoutGroup:e,switchLayoutGroup:n}=this.props,{projection:i}=t;rl=!0,i&&(i.scheduleCheckAfterUnmount(),e&&e.group&&e.group.remove(i),n&&n.deregister&&n.deregister(i))}safeToRemove(){let{safeToRemove:t}=this.props;t&&t()}render(){return null}}function rc(t){let[e,n]=function(t=!0){let e=(0,o.useContext)(e2);if(null===e)return[!0,null];let{isPresent:n,onExitComplete:i,register:r}=e,a=(0,o.useId)();(0,o.useEffect)(()=>{if(t)return r(a)},[t]);let s=(0,o.useCallback)(()=>t&&i&&i(a),[a,i,t]);return!n&&i?[!1,s]:[!0]}(),i=(0,o.useContext)(e_);return(0,eZ.jsx)(ru,{...t,layoutGroup:i,switchLayoutGroup:(0,o.useContext)(nt),isPresent:e,safeToRemove:n})}let rd={borderRadius:{...rs,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:rs,borderTopRightRadius:rs,borderBottomLeftRadius:rs,borderBottomRightRadius:rs,boxShadow:{correct:(t,{treeScale:e,projectionDelta:n})=>{let i=tH.parse(t);if(i.length>5)return t;let r=tH.createTransformer(t),o="number"!=typeof i[0]?1:0,a=n.x.scale*e.x,s=n.y.scale*e.y;i[0+o]/=a,i[1+o]/=s;let l=E(a,s,.5);return"number"==typeof i[2+o]&&(i[2+o]/=l),"number"==typeof i[3+o]&&(i[3+o]/=l),r(i)}}};function rh(t){return"object"==typeof t&&null!==t}function rf(t){return rh(t)&&"ownerSVGElement"in t}let rp=(t,e)=>t.depth-e.depth;class rm{constructor(){this.children=[],this.isDirty=!1}add(t){t5(this.children,t),this.isDirty=!0}remove(t){t3(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(rp),this.isDirty=!1,this.children.forEach(t)}}let rv=["TopLeft","TopRight","BottomLeft","BottomRight"],rg=rv.length,ry=t=>"string"==typeof t?parseFloat(t):t,rw=t=>"number"==typeof t||_.test(t);function rx(t,e){return void 0!==t[e]?t[e]:t.borderRadius}let rb=rT(0,.5,nG),rS=rT(.5,.95,ta);function rT(t,e,n){return i=>i<t?0:i>e?1:n(n5(t,e,i))}function rP(t,e){t.min=e.min,t.max=e.max}function rE(t,e){rP(t.x,e.x),rP(t.y,e.y)}function rA(t,e){t.translate=e.translate,t.scale=e.scale,t.originPoint=e.originPoint,t.origin=e.origin}function rM(t,e,n,i,r){return t-=e,t=i+1/n*(t-i),void 0!==r&&(t=i+1/r*(t-i)),t}function rC(t,e,[n,i,r],o,a){!function(t,e=0,n=1,i=.5,r,o=t,a=t){if(Z.test(e)&&(e=parseFloat(e),e=E(a.min,a.max,e/100)-a.min),"number"!=typeof e)return;let s=E(o.min,o.max,i);t===o&&(s-=e),t.min=rM(t.min,e,n,s,r),t.max=rM(t.max,e,n,s,r)}(t,e[n],e[i],e[r],e.scale,o,a)}let rk=["x","scaleX","originX"],rR=["y","scaleY","originY"];function rD(t,e,n,i){rC(t.x,e,rk,n?n.x:void 0,i?i.x:void 0),rC(t.y,e,rR,n?n.y:void 0,i?i.y:void 0)}function rV(t){return 0===t.translate&&1===t.scale}function rL(t){return rV(t.x)&&rV(t.y)}function rj(t,e){return t.min===e.min&&t.max===e.max}function rF(t,e){return Math.round(t.min)===Math.round(e.min)&&Math.round(t.max)===Math.round(e.max)}function rI(t,e){return rF(t.x,e.x)&&rF(t.y,e.y)}function rO(t){return i_(t.x)/i_(t.y)}function rB(t,e){return t.translate===e.translate&&t.scale===e.scale&&t.originPoint===e.originPoint}class rN{constructor(){this.members=[]}add(t){t5(this.members,t),t.scheduleRender()}remove(t){if(t3(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){let t=this.members[this.members.length-1];t&&this.promote(t)}}relegate(t){let e;let n=this.members.findIndex(e=>t===e);if(0===n)return!1;for(let t=n;t>=0;t--){let n=this.members[t];if(!1!==n.isPresent){e=n;break}}return!!e&&(this.promote(e),!0)}promote(t,e){let n=this.lead;if(t!==n&&(this.prevLead=n,this.lead=t,t.show(),n)){n.instance&&n.scheduleRender(),t.scheduleRender(),t.resumeFrom=n,e&&(t.resumeFrom.preserveOpacity=!0),n.snapshot&&(t.snapshot=n.snapshot,t.snapshot.latestValues=n.animationValues||n.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);let{crossfade:i}=t.options;!1===i&&n.hide()}}exitAnimationComplete(){this.members.forEach(t=>{let{options:e,resumingFrom:n}=t;e.onExitComplete&&e.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}let rW={nodes:0,calculatedTargetDeltas:0,calculatedProjections:0},rU=["","X","Y","Z"],rH=0;function rz(t,e,n,i){let{latestValues:r}=e;r[t]&&(n[t]=r[t],e.setStaticValue(t,0),i&&(i[t]=0))}function rZ({attachResizeListener:t,defaultParent:e,measureScroll:n,checkIsScrollRoot:i,resetTransform:r}){return class{constructor(t={},n=e?.()){this.id=rH++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,tu.value&&(rW.nodes=rW.calculatedTargetDeltas=rW.calculatedProjections=0),this.nodes.forEach(r$),this.nodes.forEach(r0),this.nodes.forEach(r1),this.nodes.forEach(rY),tu.addProjectionMetrics&&tu.addProjectionMetrics(rW)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=t,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let t=0;t<this.path.length;t++)this.path[t].shouldResetTransform=!0;this.root===this&&(this.nodes=new rm)}addEventListener(t,e){return this.eventHandlers.has(t)||this.eventHandlers.set(t,new t6),this.eventHandlers.get(t).add(e)}notifyListeners(t,...e){let n=this.eventHandlers.get(t);n&&n.notify(...e)}hasListeners(t){return this.eventHandlers.has(t)}mount(e){if(this.instance)return;this.isSVG=rf(e)&&!(rf(e)&&"svg"===e.tagName),this.instance=e;let{layoutId:n,layout:i,visualElement:r}=this.options;if(r&&!r.current&&r.mount(e),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(i||n)&&(this.isLayoutDirty=!0),t){let n;let i=0,r=()=>this.root.updateBlockedByResize=!1;td.read(()=>{i=window.innerWidth}),t(e,()=>{let t=window.innerWidth;t!==i&&(i=t,this.root.updateBlockedByResize=!0,n&&n(),n=function(t,e){let n=t2.now(),i=({timestamp:e})=>{let r=e-n;r>=250&&(th(i),t(r-250))};return td.setup(i,!0),()=>th(i)}(r,0),ro.hasAnimatedSinceResize&&(ro.hasAnimatedSinceResize=!1,this.nodes.forEach(rQ)))})}n&&this.root.registerSharedNode(n,this),!1!==this.options.animate&&r&&(n||i)&&this.addEventListener("didUpdate",({delta:t,hasLayoutChanged:e,hasRelativeLayoutChanged:n,layout:i})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}let o=this.options.transition||r.getDefaultTransition()||r4,{onLayoutAnimationStart:a,onLayoutAnimationComplete:s}=r.getProps(),l=!this.targetLayout||!rI(this.targetLayout,i),u=!e&&n;if(this.options.layoutRoot||this.resumeFrom||u||e&&(l||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);let e={...nr(o,"layout"),onPlay:a,onComplete:s};(r.shouldReduceMotion||this.options.layoutRoot)&&(e.delay=0,e.type=!1),this.startAnimation(e),this.setAnimationOrigin(t,u)}else e||rQ(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=i})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);let t=this.getStack();t&&t.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),th(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){!this.isUpdateBlocked()&&(this.isUpdating=!0,this.nodes&&this.nodes.forEach(r2),this.animationId++)}getTransformTemplate(){let{visualElement:t}=this.options;return t&&t.getProps().transformTemplate}willUpdate(t=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&function t(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;let{visualElement:n}=e.options;if(!n)return;let i=n.props[e8];if(window.MotionHasOptimisedAnimation(i,"transform")){let{layout:t,layoutId:n}=e.options;window.MotionCancelOptimisedAnimation(i,"transform",td,!(t||n))}let{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&t(r)}(this),this.root.isUpdating||this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let t=0;t<this.path.length;t++){let e=this.path[t];e.shouldResetTransform=!0,e.updateScroll("snapshot"),e.options.layoutRoot&&e.willUpdate(!1)}let{layoutId:e,layout:n}=this.options;if(void 0===e&&!n)return;let i=this.getTransformTemplate();this.prevTransformTemplateValue=i?i(this.latestValues,""):void 0,this.updateSnapshot(),t&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(rq);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(rG);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(rJ),this.nodes.forEach(r_),this.nodes.forEach(rK)):this.nodes.forEach(rG),this.clearAllSnapshots();let t=t2.now();tf.delta=B(0,1e3/60,t-tf.timestamp),tf.timestamp=t,tf.isProcessing=!0,tp.update.process(tf),tp.preRender.process(tf),tp.render.process(tf),tf.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,en.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(rX),this.sharedNodes.forEach(r5)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,td.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){td.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),!this.snapshot||i_(this.snapshot.measuredBox.x)||i_(this.snapshot.measuredBox.y)||(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let t=0;t<this.path.length;t++)this.path[t].updateScroll();let t=this.layout;this.layout=this.measure(!1),this.layoutCorrected=eu(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);let{visualElement:e}=this.options;e&&e.notify("LayoutMeasure",this.layout.layoutBox,t?t.layoutBox:void 0)}updateScroll(t="measure"){let e=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===t&&(e=!1),e&&this.instance){let e=i(this.instance);this.scroll={animationId:this.root.animationId,phase:t,isRoot:e,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:e}}}resetTransform(){if(!r)return;let t=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,e=this.projectionDelta&&!rL(this.projectionDelta),n=this.getTransformTemplate(),i=n?n(this.latestValues,""):void 0,o=i!==this.prevTransformTemplateValue;t&&this.instance&&(e||C(this.latestValues)||o)&&(r(this.instance,i),this.shouldResetTransform=!1,this.scheduleRender())}measure(t=!0){var e;let n=this.measurePageBox(),i=this.removeElementScroll(n);return t&&(i=this.removeTransform(i)),ot((e=i).x),ot(e.y),{animationId:this.root.animationId,measuredBox:n,layoutBox:i,latestValues:{},source:this.id}}measurePageBox(){let{visualElement:t}=this.options;if(!t)return eu();let e=t.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(on))){let{scroll:t}=this.root;t&&(L(e.x,t.offset.x),L(e.y,t.offset.y))}return e}removeElementScroll(t){let e=eu();if(rE(e,t),this.scroll?.wasRoot)return e;for(let n=0;n<this.path.length;n++){let i=this.path[n],{scroll:r,options:o}=i;i!==this.root&&r&&o.layoutScroll&&(r.wasRoot&&rE(e,t),L(e.x,r.offset.x),L(e.y,r.offset.y))}return e}applyTransform(t,e=!1){let n=eu();rE(n,t);for(let t=0;t<this.path.length;t++){let i=this.path[t];!e&&i.options.layoutScroll&&i.scroll&&i!==i.root&&F(n,{x:-i.scroll.offset.x,y:-i.scroll.offset.y}),C(i.latestValues)&&F(n,i.latestValues)}return C(this.latestValues)&&F(n,this.latestValues),n}removeTransform(t){let e=eu();rE(e,t);for(let t=0;t<this.path.length;t++){let n=this.path[t];if(!n.instance||!C(n.latestValues))continue;M(n.latestValues)&&n.updateSnapshot();let i=eu();rE(i,n.measurePageBox()),rD(e,n.latestValues,n.snapshot?n.snapshot.layoutBox:void 0,i)}return C(this.latestValues)&&rD(e,this.latestValues),e}setTargetDelta(t){this.targetDelta=t,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(t){this.options={...this.options,...t,crossfade:void 0===t.crossfade||t.crossfade}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==tf.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(t=!1){let e=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=e.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=e.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=e.isSharedProjectionDirty);let n=!!this.resumingFrom||this!==e;if(!(t||n&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;let{layout:i,layoutId:r}=this.options;if(this.layout&&(i||r)){if(this.resolvedRelativeTargetAt=tf.timestamp,!this.targetDelta&&!this.relativeTarget){let t=this.getClosestProjectingParent();t&&t.layout&&1!==this.animationProgress?(this.relativeParent=t,this.forceRelativeParentToResolveTarget(),this.relativeTarget=eu(),this.relativeTargetOrigin=eu(),iq(this.relativeTargetOrigin,this.layout.layoutBox,t.layout.layoutBox),rE(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(this.relativeTarget||this.targetDelta){if(this.target||(this.target=eu(),this.targetWithTransforms=eu()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target){var o,a,s;this.forceRelativeParentToResolveTarget(),o=this.target,a=this.relativeTarget,s=this.relativeParent.target,iY(o.x,a.x,s.x),iY(o.y,a.y,s.y)}else this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):rE(this.target,this.layout.layoutBox),V(this.target,this.targetDelta)):rE(this.target,this.layout.layoutBox);if(this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;let t=this.getClosestProjectingParent();t&&!!t.resumingFrom==!!this.resumingFrom&&!t.options.layoutScroll&&t.target&&1!==this.animationProgress?(this.relativeParent=t,this.forceRelativeParentToResolveTarget(),this.relativeTarget=eu(),this.relativeTargetOrigin=eu(),iq(this.relativeTargetOrigin,this.target,t.target),rE(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}tu.value&&rW.calculatedTargetDeltas++}}}getClosestProjectingParent(){return!this.parent||M(this.parent.latestValues)||k(this.parent.latestValues)?void 0:this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){let t=this.getLead(),e=!!this.resumingFrom||this!==t,n=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(n=!1),e&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(n=!1),this.resolvedRelativeTargetAt===tf.timestamp&&(n=!1),n)return;let{layout:i,layoutId:r}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(i||r))return;rE(this.layoutCorrected,this.layout.layoutBox);let o=this.treeScale.x,a=this.treeScale.y;!function(t,e,n,i=!1){let r,o;let a=n.length;if(a){e.x=e.y=1;for(let s=0;s<a;s++){o=(r=n[s]).projectionDelta;let{visualElement:a}=r.options;(!a||!a.props.style||"contents"!==a.props.style.display)&&(i&&r.options.layoutScroll&&r.scroll&&r!==r.root&&F(t,{x:-r.scroll.offset.x,y:-r.scroll.offset.y}),o&&(e.x*=o.x.scale,e.y*=o.y.scale,V(t,o)),i&&C(r.latestValues)&&F(t,r.latestValues))}e.x<1.0000000000001&&e.x>.999999999999&&(e.x=1),e.y<1.0000000000001&&e.y>.999999999999&&(e.y=1)}}(this.layoutCorrected,this.treeScale,this.path,e),t.layout&&!t.target&&(1!==this.treeScale.x||1!==this.treeScale.y)&&(t.target=t.layout.layoutBox,t.targetWithTransforms=eu());let{target:s}=t;if(!s){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}this.projectionDelta&&this.prevProjectionDelta?(rA(this.prevProjectionDelta.x,this.projectionDelta.x),rA(this.prevProjectionDelta.y,this.projectionDelta.y)):this.createProjectionDeltas(),i$(this.projectionDelta,this.layoutCorrected,s,this.latestValues),this.treeScale.x===o&&this.treeScale.y===a&&rB(this.projectionDelta.x,this.prevProjectionDelta.x)&&rB(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",s)),tu.value&&rW.calculatedProjections++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(t=!0){if(this.options.visualElement?.scheduleRender(),t){let t=this.getStack();t&&t.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=es(),this.projectionDelta=es(),this.projectionDeltaWithTransform=es()}setAnimationOrigin(t,e=!1){let n;let i=this.snapshot,r=i?i.latestValues:{},o={...this.latestValues},a=es();this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!e;let s=eu(),l=(i?i.source:void 0)!==(this.layout?this.layout.source:void 0),u=this.getStack(),c=!u||u.members.length<=1,d=!!(l&&!c&&!0===this.options.crossfade&&!this.path.some(r9));this.animationProgress=0,this.mixTargetDelta=e=>{let i=e/1e3;if(r3(a.x,t.x,i),r3(a.y,t.y,i),this.setTargetDelta(a),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout){var u,h,f,p;iq(s,this.layout.layoutBox,this.relativeParent.layout.layoutBox),f=this.relativeTarget,p=this.relativeTargetOrigin,r6(f.x,p.x,s.x,i),r6(f.y,p.y,s.y,i),n&&(u=this.relativeTarget,h=n,rj(u.x,h.x)&&rj(u.y,h.y))&&(this.isProjectionDirty=!1),n||(n=eu()),rE(n,this.relativeTarget)}l&&(this.animationValues=o,function(t,e,n,i,r,o){r?(t.opacity=E(0,n.opacity??1,rb(i)),t.opacityExit=E(e.opacity??1,0,rS(i))):o&&(t.opacity=E(e.opacity??1,n.opacity??1,i));for(let r=0;r<rg;r++){let o=`border${rv[r]}Radius`,a=rx(e,o),s=rx(n,o);(void 0!==a||void 0!==s)&&(a||(a=0),s||(s=0),0===a||0===s||rw(a)===rw(s)?(t[o]=Math.max(E(ry(a),ry(s),i),0),(Z.test(s)||Z.test(a))&&(t[o]+="%")):t[o]=s)}(e.rotate||n.rotate)&&(t.rotate=E(e.rotate||0,n.rotate||0,i))}(o,r,this.latestValues,i,d,c)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=i},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(t){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(th(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=td.update(()=>{ro.hasAnimatedSinceResize=!0,nh.layout++,this.motionValue||(this.motionValue=t8(0)),this.currentAnimation=function(t,e,n){let i=t0(t)?t:t8(t);return i.start(iE("",i,e,n)),i.animation}(this.motionValue,[0,1e3],{...t,velocity:0,isSync:!0,onUpdate:e=>{this.mixTargetDelta(e),t.onUpdate&&t.onUpdate(e)},onStop:()=>{nh.layout--},onComplete:()=>{nh.layout--,t.onComplete&&t.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);let t=this.getStack();t&&t.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(1e3),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){let t=this.getLead(),{targetWithTransforms:e,target:n,layout:i,latestValues:r}=t;if(e&&n&&i){if(this!==t&&this.layout&&i&&oe(this.options.animationType,this.layout.layoutBox,i.layoutBox)){n=this.target||eu();let e=i_(this.layout.layoutBox.x);n.x.min=t.target.x.min,n.x.max=n.x.min+e;let i=i_(this.layout.layoutBox.y);n.y.min=t.target.y.min,n.y.max=n.y.min+i}rE(e,n),F(e,r),i$(this.projectionDeltaWithTransform,this.layoutCorrected,e,r)}}registerSharedNode(t,e){this.sharedNodes.has(t)||this.sharedNodes.set(t,new rN),this.sharedNodes.get(t).add(e);let n=e.options.initialPromotionConfig;e.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(e):void 0})}isLead(){let t=this.getStack();return!t||t.lead===this}getLead(){let{layoutId:t}=this.options;return t&&this.getStack()?.lead||this}getPrevLead(){let{layoutId:t}=this.options;return t?this.getStack()?.prevLead:void 0}getStack(){let{layoutId:t}=this.options;if(t)return this.root.sharedNodes.get(t)}promote({needsReset:t,transition:e,preserveFollowOpacity:n}={}){let i=this.getStack();i&&i.promote(this,n),t&&(this.projectionDelta=void 0,this.needsReset=!0),e&&this.setOptions({transition:e})}relegate(){let t=this.getStack();return!!t&&t.relegate(this)}resetSkewAndRotation(){let{visualElement:t}=this.options;if(!t)return;let e=!1,{latestValues:n}=t;if((n.z||n.rotate||n.rotateX||n.rotateY||n.rotateZ||n.skewX||n.skewY)&&(e=!0),!e)return;let i={};n.z&&rz("z",t,i,this.animationValues);for(let e=0;e<rU.length;e++)rz(`rotate${rU[e]}`,t,i,this.animationValues),rz(`skew${rU[e]}`,t,i,this.animationValues);for(let e in t.render(),i)t.setStaticValue(e,i[e]),this.animationValues&&(this.animationValues[e]=i[e]);t.scheduleRender()}applyProjectionStyles(t,e){if(!this.instance||this.isSVG)return;if(!this.isVisible){t.visibility="hidden";return}let n=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,t.visibility="",t.opacity="",t.pointerEvents=e5(e?.pointerEvents)||"",t.transform=n?n(this.latestValues,""):"none";return}let i=this.getLead();if(!this.projectionDelta||!this.layout||!i.target){this.options.layoutId&&(t.opacity=void 0!==this.latestValues.opacity?this.latestValues.opacity:1,t.pointerEvents=e5(e?.pointerEvents)||""),this.hasProjected&&!C(this.latestValues)&&(t.transform=n?n({},""):"none",this.hasProjected=!1);return}t.visibility="";let r=i.animationValues||i.latestValues;this.applyTransformsToTarget();let o=function(t,e,n){let i="",r=t.x.translate/e.x,o=t.y.translate/e.y,a=n?.z||0;if((r||o||a)&&(i=`translate3d(${r}px, ${o}px, ${a}px) `),(1!==e.x||1!==e.y)&&(i+=`scale(${1/e.x}, ${1/e.y}) `),n){let{transformPerspective:t,rotate:e,rotateX:r,rotateY:o,skewX:a,skewY:s}=n;t&&(i=`perspective(${t}px) ${i}`),e&&(i+=`rotate(${e}deg) `),r&&(i+=`rotateX(${r}deg) `),o&&(i+=`rotateY(${o}deg) `),a&&(i+=`skewX(${a}deg) `),s&&(i+=`skewY(${s}deg) `)}let s=t.x.scale*e.x,l=t.y.scale*e.y;return(1!==s||1!==l)&&(i+=`scale(${s}, ${l})`),i||"none"}(this.projectionDeltaWithTransform,this.treeScale,r);n&&(o=n(r,o)),t.transform=o;let{x:a,y:s}=this.projectionDelta;for(let e in t.transformOrigin=`${100*a.origin}% ${100*s.origin}% 0`,i.animationValues?t.opacity=i===this?r.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:r.opacityExit:t.opacity=i===this?void 0!==r.opacity?r.opacity:"":void 0!==r.opacityExit?r.opacityExit:0,eR){if(void 0===r[e])continue;let{correct:n,applyTo:a,isCSSVariable:s}=eR[e],l="none"===o?r[e]:n(r[e],i);if(a){let e=a.length;for(let n=0;n<e;n++)t[a[n]]=l}else s?this.options.visualElement.renderState.vars[e]=l:t[e]=l}this.options.layoutId&&(t.pointerEvents=i===this?e5(e?.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(t=>t.currentAnimation?.stop()),this.root.nodes.forEach(rq),this.root.sharedNodes.clear()}}}function r_(t){t.updateLayout()}function rK(t){let e=t.resumeFrom?.snapshot||t.snapshot;if(t.isLead()&&t.layout&&e&&t.hasListeners("didUpdate")){let{layoutBox:n,measuredBox:i}=t.layout,{animationType:r}=t.options,o=e.source!==t.layout.source;"size"===r?iG(t=>{let i=o?e.measuredBox[t]:e.layoutBox[t],r=i_(i);i.min=n[t].min,i.max=i.min+r}):oe(r,e.layoutBox,n)&&iG(i=>{let r=o?e.measuredBox[i]:e.layoutBox[i],a=i_(n[i]);r.max=r.min+a,t.relativeTarget&&!t.currentAnimation&&(t.isProjectionDirty=!0,t.relativeTarget[i].max=t.relativeTarget[i].min+a)});let a=es();i$(a,n,e.layoutBox);let s=es();o?i$(s,t.applyTransform(i,!0),e.measuredBox):i$(s,n,e.layoutBox);let l=!rL(a),u=!1;if(!t.resumeFrom){let i=t.getClosestProjectingParent();if(i&&!i.resumeFrom){let{snapshot:r,layout:o}=i;if(r&&o){let a=eu();iq(a,e.layoutBox,r.layoutBox);let s=eu();iq(s,n,o.layoutBox),rI(a,s)||(u=!0),i.options.layoutRoot&&(t.relativeTarget=s,t.relativeTargetOrigin=a,t.relativeParent=i)}}}t.notifyListeners("didUpdate",{layout:n,snapshot:e,delta:s,layoutDelta:a,hasLayoutChanged:l,hasRelativeLayoutChanged:u})}else if(t.isLead()){let{onExitComplete:e}=t.options;e&&e()}t.options.transition=void 0}function r$(t){tu.value&&rW.nodes++,t.parent&&(t.isProjecting()||(t.isProjectionDirty=t.parent.isProjectionDirty),t.isSharedProjectionDirty||(t.isSharedProjectionDirty=!!(t.isProjectionDirty||t.parent.isProjectionDirty||t.parent.isSharedProjectionDirty)),t.isTransformDirty||(t.isTransformDirty=t.parent.isTransformDirty))}function rY(t){t.isProjectionDirty=t.isSharedProjectionDirty=t.isTransformDirty=!1}function rX(t){t.clearSnapshot()}function rq(t){t.clearMeasurements()}function rG(t){t.isLayoutDirty=!1}function rJ(t){let{visualElement:e}=t.options;e&&e.getProps().onBeforeLayoutMeasure&&e.notify("BeforeLayoutMeasure"),t.resetTransform()}function rQ(t){t.finishAnimation(),t.targetDelta=t.relativeTarget=t.target=void 0,t.isProjectionDirty=!0}function r0(t){t.resolveTargetDelta()}function r1(t){t.calcProjection()}function r2(t){t.resetSkewAndRotation()}function r5(t){t.removeLeadSnapshot()}function r3(t,e,n){t.translate=E(e.translate,0,n),t.scale=E(e.scale,1,n),t.origin=e.origin,t.originPoint=e.originPoint}function r6(t,e,n,i){t.min=E(e.min,n.min,i),t.max=E(e.max,n.max,i)}function r9(t){return t.animationValues&&void 0!==t.animationValues.opacityExit}let r4={duration:.45,ease:[.4,0,.1,1]},r7=t=>"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(t),r8=r7("applewebkit/")&&!r7("chrome/")?Math.round:ta;function ot(t){t.min=r8(t.min),t.max=r8(t.max)}function oe(t,e,n){return"position"===t||"preserve-aspect"===t&&!(.2>=Math.abs(rO(e)-rO(n)))}function on(t){return t!==t.root&&t.scroll?.wasRoot}let oi=rZ({attachResizeListener:(t,e)=>iW(t,"resize",e),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),or={current:void 0},oo=rZ({measureScroll:t=>({x:t.scrollLeft,y:t.scrollTop}),defaultParent:()=>{if(!or.current){let t=new oi({});t.mount(window),t.setOptions({layoutScroll:!0}),or.current=t}return or.current},resetTransform:(t,e)=>{t.style.transform=void 0!==e?e:"none"},checkIsScrollRoot:t=>"fixed"===window.getComputedStyle(t).position});function oa(t,e){let n=function(t,e,n){if(t instanceof EventTarget)return[t];if("string"==typeof t){let e=document,n=(void 0)??e.querySelectorAll(t);return n?Array.from(n):[]}return Array.from(t)}(t),i=new AbortController;return[n,{passive:!0,...e,signal:i.signal},()=>i.abort()]}function os(t){return!("touch"===t.pointerType||iN.x||iN.y)}function ol(t,e,n){let{props:i}=t;t.animationState&&i.whileHover&&t.animationState.setActive("whileHover","Start"===n);let r=i["onHover"+n];r&&td.postRender(()=>r(e,iH(e)))}class ou extends iF{mount(){let{current:t}=this.node;t&&(this.unmount=function(t,e,n={}){let[i,r,o]=oa(t,n),a=t=>{if(!os(t))return;let{target:n}=t,i=e(n,t);if("function"!=typeof i||!n)return;let o=t=>{os(t)&&(i(t),n.removeEventListener("pointerleave",o))};n.addEventListener("pointerleave",o,r)};return i.forEach(t=>{t.addEventListener("pointerenter",a,r)}),o}(t,(t,e)=>(ol(this.node,e,"Start"),t=>ol(this.node,t,"End"))))}unmount(){}}class oc extends iF{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch(e){t=!0}t&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){this.isActive&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=nu(iW(this.node.current,"focus",()=>this.onFocus()),iW(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}let od=(t,e)=>!!e&&(t===e||od(t,e.parentElement)),oh=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]),of=new WeakSet;function op(t){return e=>{"Enter"===e.key&&t(e)}}function om(t,e){t.dispatchEvent(new PointerEvent("pointer"+e,{isPrimary:!0,bubbles:!0}))}let ov=(t,e)=>{let n=t.currentTarget;if(!n)return;let i=op(()=>{if(of.has(n))return;om(n,"down");let t=op(()=>{om(n,"up")});n.addEventListener("keyup",t,e),n.addEventListener("blur",()=>om(n,"cancel"),e)});n.addEventListener("keydown",i,e),n.addEventListener("blur",()=>n.removeEventListener("keydown",i),e)};function og(t){return iU(t)&&!(iN.x||iN.y)}function oy(t,e,n){let{props:i}=t;if(t.current instanceof HTMLButtonElement&&t.current.disabled)return;t.animationState&&i.whileTap&&t.animationState.setActive("whileTap","Start"===n);let r=i["onTap"+("End"===n?"":n)];r&&td.postRender(()=>r(e,iH(e)))}class ow extends iF{mount(){let{current:t}=this.node;t&&(this.unmount=function(t,e,n={}){let[i,r,o]=oa(t,n),a=t=>{let i=t.currentTarget;if(!og(t))return;of.add(i);let o=e(i,t),a=(t,e)=>{window.removeEventListener("pointerup",s),window.removeEventListener("pointercancel",l),of.has(i)&&of.delete(i),og(t)&&"function"==typeof o&&o(t,{success:e})},s=t=>{a(t,i===window||i===document||n.useGlobalTarget||od(i,t.target))},l=t=>{a(t,!1)};window.addEventListener("pointerup",s,r),window.addEventListener("pointercancel",l,r)};return i.forEach(t=>{(n.useGlobalTarget?window:t).addEventListener("pointerdown",a,r),rh(t)&&"offsetHeight"in t&&(t.addEventListener("focus",t=>ov(t,r)),oh.has(t.tagName)||-1!==t.tabIndex||t.hasAttribute("tabindex")||(t.tabIndex=0))}),o}(t,(t,e)=>(oy(this.node,e,"Start"),(t,{success:e})=>oy(this.node,t,e?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}let ox=new WeakMap,ob=new WeakMap,oS=t=>{let e=ox.get(t.target);e&&e(t)},oT=t=>{t.forEach(oS)},oP={some:0,all:1};class oE extends iF{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();let{viewport:t={}}=this.node.getProps(),{root:e,margin:n,amount:i="some",once:r}=t,o={root:e?e.current:void 0,rootMargin:n,threshold:"number"==typeof i?i:oP[i]};return function(t,e,n){let i=function({root:t,...e}){let n=t||document;ob.has(n)||ob.set(n,{});let i=ob.get(n),r=JSON.stringify(e);return i[r]||(i[r]=new IntersectionObserver(oT,{root:t,...e})),i[r]}(e);return ox.set(t,n),i.observe(t),()=>{ox.delete(t),i.unobserve(t)}}(this.node.current,o,t=>{let{isIntersecting:e}=t;if(this.isInView===e||(this.isInView=e,r&&!e&&this.hasEnteredView))return;e&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",e);let{onViewportEnter:n,onViewportLeave:i}=this.node.getProps(),o=e?n:i;o&&o(t)})}mount(){this.startObserver()}update(){if("undefined"==typeof IntersectionObserver)return;let{props:t,prevProps:e}=this.node;["amount","margin","root"].some(function({viewport:t={}},{viewport:e={}}={}){return n=>t[n]!==e[n]}(t,e))&&this.startObserver()}unmount(){}}let oA=function(t,e){if("undefined"==typeof Proxy)return nn;let n=new Map,i=(n,i)=>nn(n,i,t,e);return new Proxy((t,e)=>i(t,e),{get:(r,o)=>"create"===o?i:(n.has(o)||n.set(o,nn(o,void 0,t,e)),n.get(o))})}({animation:{Feature:iI},exit:{Feature:iB},inView:{Feature:oE},tap:{Feature:ow},focus:{Feature:oc},hover:{Feature:ou},pan:{Feature:rr},drag:{Feature:rn,ProjectionNode:oo,MeasureLayout:rc},layout:{ProjectionNode:oo,MeasureLayout:rc}},(t,e)=>ez(t)?new eU(e):new eL(e,{allowProjection:t!==o.Fragment}))}}]);
|