"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[958],{5068:function(e,n,t){t.d(n,{default:function(){return o.a}});var r=t(5363),o=t.n(r)},6560:function(e,n,t){t.d(n,{B:function(){return p}});var r=t(9026),o=t(9662),i=t(9371),a=t(8105),u=t(8182),c=t(835),l=t(1614),s=t(252),f=t(3372),d=t(513);function p(e){var n=e+"CollectionProvider",t=(0,u._)((0,l.b)(n),2),p=t[0],v=t[1],h=(0,u._)(p(n,{collectionRef:{current:null},itemMap:new Map}),2),_=h[0],g=h[1],m=function(e){var n=e.scope,t=e.children,r=c.useRef(null),o=c.useRef(new Map).current;return(0,d.jsx)(_,{scope:n,itemMap:o,collectionRef:r,children:t})};m.displayName=n;var w=e+"CollectionSlot",y=c.forwardRef(function(e,n){var t=e.scope,r=e.children,o=g(w,t),i=(0,s.e)(n,o.collectionRef);return(0,d.jsx)(f.g7,{ref:i,children:r})});y.displayName=w;var x=e+"CollectionItemSlot",b="data-radix-collection-item",M=c.forwardRef(function(e,n){var t=e.scope,u=e.children,l=(0,a._)(e,["scope","children"]),p=c.useRef(null),v=(0,s.e)(n,p),h=g(x,t);return c.useEffect(function(){return h.itemMap.set(p,(0,o._)({ref:p},l)),function(){h.itemMap.delete(p)}}),(0,d.jsx)(f.g7,(0,i._)((0,o._)({},(0,r._)({},b,"")),{ref:v,children:u}))});return M.displayName=x,[{Provider:m,Slot:y,ItemSlot:M},function(n){var t=g(e+"CollectionConsumer",n);return c.useCallback(function(){var e=t.collectionRef.current;if(!e)return[];var n=Array.from(e.querySelectorAll("[".concat(b,"]")));return Array.from(t.itemMap.values()).sort(function(e,t){return n.indexOf(e.ref.current)-n.indexOf(t.ref.current)})},[t.collectionRef,t.itemMap])},v]}},1960:function(e,n,t){t.d(n,{gm:function(){return i}});var r=t(835);t(513);var o=r.createContext(void 0);function i(e){let n=r.useContext(o);return e||n||"ltr"}},6889:function(e,n,t){t.d(n,{oC:function(){return t6},VY:function(){return t0},ZA:function(){return t1},ck:function(){return t5},wU:function(){return t9},__:function(){return t2},Uv:function(){return tQ},Ee:function(){return t3},Rk:function(){return t8},fC:function(){return t$},Z0:function(){return t7},Tr:function(){return t4},tu:function(){return rn},fF:function(){return re},xz:function(){return tJ}});var r=t(9662),o=t(9371),i=t(8105),a=t(8182),u=t(835),c=t(7134),l=t(252),s=t(1614),f=t(1677),d=t(2265),p=t(6078),v=t(6560),h=t(1960),_=t(1234),g=t(9965),m=t(4997),w=t(8015),y=t(9026);let x=["top","right","bottom","left"],b=Math.min,M=Math.max,R=Math.round,C=Math.floor,D=e=>({x:e,y:e}),E={left:"right",right:"left",bottom:"top",top:"bottom"},T={start:"end",end:"start"};function P(e,n){return"function"==typeof e?e(n):e}function j(e){return e.split("-")[0]}function S(e){return e.split("-")[1]}function N(e){return"x"===e?"y":"x"}function A(e){return"y"===e?"height":"width"}function k(e){return["top","bottom"].includes(j(e))?"y":"x"}function O(e){return e.replace(/start|end/g,e=>T[e])}function I(e){return e.replace(/left|right|bottom|top/g,e=>E[e])}function F(e){return"number"!=typeof e?{top:0,right:0,bottom:0,left:0,...e}:{top:e,right:e,bottom:e,left:e}}function L(e){let{x:n,y:t,width:r,height:o}=e;return{width:r,height:o,top:t,left:n,right:n+r,bottom:t+o,x:n,y:t}}function V(e,n,t){let r,{reference:o,floating:i}=e,a=k(n),u=N(k(n)),c=A(u),l=j(n),s="y"===a,f=o.x+o.width/2-i.width/2,d=o.y+o.height/2-i.height/2,p=o[c]/2-i[c]/2;switch(l){case"top":r={x:f,y:o.y-i.height};break;case"bottom":r={x:f,y:o.y+o.height};break;case"right":r={x:o.x+o.width,y:d};break;case"left":r={x:o.x-i.width,y:d};break;default:r={x:o.x,y:o.y}}switch(S(n)){case"start":r[u]-=p*(t&&s?-1:1);break;case"end":r[u]+=p*(t&&s?-1:1)}return r}let W=async(e,n,t)=>{let{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:a}=t,u=i.filter(Boolean),c=await (null==a.isRTL?void 0:a.isRTL(n)),l=await a.getElementRects({reference:e,floating:n,strategy:o}),{x:s,y:f}=V(l,r,c),d=r,p={},v=0;for(let t=0;t<u.length;t++){let{name:i,fn:h}=u[t],{x:_,y:g,data:m,reset:w}=await h({x:s,y:f,initialPlacement:r,placement:d,strategy:o,middlewareData:p,rects:l,platform:a,elements:{reference:e,floating:n}});s=null!=_?_:s,f=null!=g?g:f,p={...p,[i]:{...p[i],...m}},w&&v<=50&&(v++,"object"==typeof w&&(w.placement&&(d=w.placement),w.rects&&(l=!0===w.rects?await a.getElementRects({reference:e,floating:n,strategy:o}):w.rects),{x:s,y:f}=V(l,d,c)),t=-1)}return{x:s,y:f,placement:d,strategy:o,middlewareData:p}};async function K(e,n){var t;void 0===n&&(n={});let{x:r,y:o,platform:i,rects:a,elements:u,strategy:c}=e,{boundary:l="clippingAncestors",rootBoundary:s="viewport",elementContext:f="floating",altBoundary:d=!1,padding:p=0}=P(n,e),v=F(p),h=u[d?"floating"===f?"reference":"floating":f],_=L(await i.getClippingRect({element:null==(t=await (null==i.isElement?void 0:i.isElement(h)))||t?h:h.contextElement||await (null==i.getDocumentElement?void 0:i.getDocumentElement(u.floating)),boundary:l,rootBoundary:s,strategy:c})),g="floating"===f?{x:r,y:o,width:a.floating.width,height:a.floating.height}:a.reference,m=await (null==i.getOffsetParent?void 0:i.getOffsetParent(u.floating)),w=await (null==i.isElement?void 0:i.isElement(m))&&await (null==i.getScale?void 0:i.getScale(m))||{x:1,y:1},y=L(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:u,rect:g,offsetParent:m,strategy:c}):g);return{top:(_.top-y.top+v.top)/w.y,bottom:(y.bottom-_.bottom+v.bottom)/w.y,left:(_.left-y.left+v.left)/w.x,right:(y.right-_.right+v.right)/w.x}}function z(e,n){return{top:e.top-n.height,right:e.right-n.width,bottom:e.bottom-n.height,left:e.left-n.width}}function H(e){return x.some(n=>e[n]>=0)}async function B(e,n){let{placement:t,platform:r,elements:o}=e,i=await (null==r.isRTL?void 0:r.isRTL(o.floating)),a=j(t),u=S(t),c="y"===k(t),l=["left","top"].includes(a)?-1:1,s=i&&c?-1:1,f=P(n,e),{mainAxis:d,crossAxis:p,alignmentAxis:v}="number"==typeof f?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...f};return u&&"number"==typeof v&&(p="end"===u?-1*v:v),c?{x:p*s,y:d*l}:{x:d*l,y:p*s}}function G(e){return Y(e)?(e.nodeName||"").toLowerCase():"#document"}function U(e){var n;return(null==e||null==(n=e.ownerDocument)?void 0:n.defaultView)||window}function X(e){var n;return null==(n=(Y(e)?e.ownerDocument:e.document)||window.document)?void 0:n.documentElement}function Y(e){return e instanceof Node||e instanceof U(e).Node}function q(e){return e instanceof Element||e instanceof U(e).Element}function Z(e){return e instanceof HTMLElement||e instanceof U(e).HTMLElement}function $(e){return"undefined"!=typeof ShadowRoot&&(e instanceof ShadowRoot||e instanceof U(e).ShadowRoot)}function J(e){let{overflow:n,overflowX:t,overflowY:r,display:o}=er(e);return/auto|scroll|overlay|hidden|clip/.test(n+r+t)&&!["inline","contents"].includes(o)}function Q(e){return[":popover-open",":modal"].some(n=>{try{return e.matches(n)}catch(e){return!1}})}function ee(e){let n=en(),t=er(e);return"none"!==t.transform||"none"!==t.perspective||!!t.containerType&&"normal"!==t.containerType||!n&&!!t.backdropFilter&&"none"!==t.backdropFilter||!n&&!!t.filter&&"none"!==t.filter||["transform","perspective","filter"].some(e=>(t.willChange||"").includes(e))||["paint","layout","strict","content"].some(e=>(t.contain||"").includes(e))}function en(){return"undefined"!=typeof CSS&&!!CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")}function et(e){return["html","body","#document"].includes(G(e))}function er(e){return U(e).getComputedStyle(e)}function eo(e){return q(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function ei(e){if("html"===G(e))return e;let n=e.assignedSlot||e.parentNode||$(e)&&e.host||X(e);return $(n)?n.host:n}function ea(e,n,t){var r;void 0===n&&(n=[]),void 0===t&&(t=!0);let o=function e(n){let t=ei(n);return et(t)?n.ownerDocument?n.ownerDocument.body:n.body:Z(t)&&J(t)?t:e(t)}(e),i=o===(null==(r=e.ownerDocument)?void 0:r.body),a=U(o);return i?n.concat(a,a.visualViewport||[],J(o)?o:[],a.frameElement&&t?ea(a.frameElement):[]):n.concat(o,ea(o,[],t))}function eu(e){let n=er(e),t=parseFloat(n.width)||0,r=parseFloat(n.height)||0,o=Z(e),i=o?e.offsetWidth:t,a=o?e.offsetHeight:r,u=R(t)!==i||R(r)!==a;return u&&(t=i,r=a),{width:t,height:r,$:u}}function ec(e){return q(e)?e:e.contextElement}function el(e){let n=ec(e);if(!Z(n))return D(1);let t=n.getBoundingClientRect(),{width:r,height:o,$:i}=eu(n),a=(i?R(t.width):t.width)/r,u=(i?R(t.height):t.height)/o;return a&&Number.isFinite(a)||(a=1),u&&Number.isFinite(u)||(u=1),{x:a,y:u}}let es=D(0);function ef(e){let n=U(e);return en()&&n.visualViewport?{x:n.visualViewport.offsetLeft,y:n.visualViewport.offsetTop}:es}function ed(e,n,t,r){var o;void 0===n&&(n=!1),void 0===t&&(t=!1);let i=e.getBoundingClientRect(),a=ec(e),u=D(1);n&&(r?q(r)&&(u=el(r)):u=el(e));let c=(void 0===(o=t)&&(o=!1),r&&(!o||r===U(a))&&o)?ef(a):D(0),l=(i.left+c.x)/u.x,s=(i.top+c.y)/u.y,f=i.width/u.x,d=i.height/u.y;if(a){let e=U(a),n=r&&q(r)?U(r):r,t=e,o=t.frameElement;for(;o&&r&&n!==t;){let e=el(o),n=o.getBoundingClientRect(),r=er(o),i=n.left+(o.clientLeft+parseFloat(r.paddingLeft))*e.x,a=n.top+(o.clientTop+parseFloat(r.paddingTop))*e.y;l*=e.x,s*=e.y,f*=e.x,d*=e.y,l+=i,s+=a,o=(t=U(o)).frameElement}}return L({width:f,height:d,x:l,y:s})}function ep(e){return ed(X(e)).left+eo(e).scrollLeft}function ev(e,n,t){let r;if("viewport"===n)r=function(e,n){let t=U(e),r=X(e),o=t.visualViewport,i=r.clientWidth,a=r.clientHeight,u=0,c=0;if(o){i=o.width,a=o.height;let e=en();(!e||e&&"fixed"===n)&&(u=o.offsetLeft,c=o.offsetTop)}return{width:i,height:a,x:u,y:c}}(e,t);else if("document"===n)r=function(e){let n=X(e),t=eo(e),r=e.ownerDocument.body,o=M(n.scrollWidth,n.clientWidth,r.scrollWidth,r.clientWidth),i=M(n.scrollHeight,n.clientHeight,r.scrollHeight,r.clientHeight),a=-t.scrollLeft+ep(e),u=-t.scrollTop;return"rtl"===er(r).direction&&(a+=M(n.clientWidth,r.clientWidth)-o),{width:o,height:i,x:a,y:u}}(X(e));else if(q(n))r=function(e,n){let t=ed(e,!0,"fixed"===n),r=t.top+e.clientTop,o=t.left+e.clientLeft,i=Z(e)?el(e):D(1),a=e.clientWidth*i.x;return{width:a,height:e.clientHeight*i.y,x:o*i.x,y:r*i.y}}(n,t);else{let t=ef(e);r={...n,x:n.x-t.x,y:n.y-t.y}}return L(r)}function eh(e){return"static"===er(e).position}function e_(e,n){return Z(e)&&"fixed"!==er(e).position?n?n(e):e.offsetParent:null}function eg(e,n){let t=U(e);if(Q(e))return t;if(!Z(e)){let n=ei(e);for(;n&&!et(n);){if(q(n)&&!eh(n))return n;n=ei(n)}return t}let r=e_(e,n);for(;r&&["table","td","th"].includes(G(r))&&eh(r);)r=e_(r,n);return r&&et(r)&&eh(r)&&!ee(r)?t:r||function(e){let n=ei(e);for(;Z(n)&&!et(n)&&!Q(n);){if(ee(n))return n;n=ei(n)}return null}(e)||t}let em=async function(e){let n=this.getOffsetParent||eg,t=this.getDimensions,r=await t(e.floating);return{reference:function(e,n,t){let r=Z(n),o=X(n),i="fixed"===t,a=ed(e,!0,i,n),u={scrollLeft:0,scrollTop:0},c=D(0);if(r||!r&&!i){if(("body"!==G(n)||J(o))&&(u=eo(n)),r){let e=ed(n,!0,i,n);c.x=e.x+n.clientLeft,c.y=e.y+n.clientTop}else o&&(c.x=ep(o))}return{x:a.left+u.scrollLeft-c.x,y:a.top+u.scrollTop-c.y,width:a.width,height:a.height}}(e.reference,await n(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},ew={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:n,rect:t,offsetParent:r,strategy:o}=e,i="fixed"===o,a=X(r),u=!!n&&Q(n.floating);if(r===a||u&&i)return t;let c={scrollLeft:0,scrollTop:0},l=D(1),s=D(0),f=Z(r);if((f||!f&&!i)&&(("body"!==G(r)||J(a))&&(c=eo(r)),Z(r))){let e=ed(r);l=el(r),s.x=e.x+r.clientLeft,s.y=e.y+r.clientTop}return{width:t.width*l.x,height:t.height*l.y,x:t.x*l.x-c.scrollLeft*l.x+s.x,y:t.y*l.y-c.scrollTop*l.y+s.y}},getDocumentElement:X,getClippingRect:function(e){let{element:n,boundary:t,rootBoundary:r,strategy:o}=e,i=[..."clippingAncestors"===t?Q(n)?[]:function(e,n){let t=n.get(e);if(t)return t;let r=ea(e,[],!1).filter(e=>q(e)&&"body"!==G(e)),o=null,i="fixed"===er(e).position,a=i?ei(e):e;for(;q(a)&&!et(a);){let n=er(a),t=ee(a);t||"fixed"!==n.position||(o=null),(i?!t&&!o:!t&&"static"===n.position&&!!o&&["absolute","fixed"].includes(o.position)||J(a)&&!t&&function e(n,t){let r=ei(n);return!(r===t||!q(r)||et(r))&&("fixed"===er(r).position||e(r,t))}(e,a))?r=r.filter(e=>e!==a):o=n,a=ei(a)}return n.set(e,r),r}(n,this._c):[].concat(t),r],a=i[0],u=i.reduce((e,t)=>{let r=ev(n,t,o);return e.top=M(r.top,e.top),e.right=b(r.right,e.right),e.bottom=b(r.bottom,e.bottom),e.left=M(r.left,e.left),e},ev(n,a,o));return{width:u.right-u.left,height:u.bottom-u.top,x:u.left,y:u.top}},getOffsetParent:eg,getElementRects:em,getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){let{width:n,height:t}=eu(e);return{width:n,height:t}},getScale:el,isElement:q,isRTL:function(e){return"rtl"===er(e).direction}};function ey(e,n,t,r){let o;void 0===r&&(r={});let{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:u="function"==typeof ResizeObserver,layoutShift:c="function"==typeof IntersectionObserver,animationFrame:l=!1}=r,s=ec(e),f=i||a?[...s?ea(s):[],...ea(n)]:[];f.forEach(e=>{i&&e.addEventListener("scroll",t,{passive:!0}),a&&e.addEventListener("resize",t)});let d=s&&c?function(e,n){let t,r=null,o=X(e);function i(){var e;clearTimeout(t),null==(e=r)||e.disconnect(),r=null}return!function a(u,c){void 0===u&&(u=!1),void 0===c&&(c=1),i();let{left:l,top:s,width:f,height:d}=e.getBoundingClientRect();if(u||n(),!f||!d)return;let p=C(s),v=C(o.clientWidth-(l+f)),h={rootMargin:-p+"px "+-v+"px "+-C(o.clientHeight-(s+d))+"px "+-C(l)+"px",threshold:M(0,b(1,c))||1},_=!0;function g(e){let n=e[0].intersectionRatio;if(n!==c){if(!_)return a();n?a(!1,n):t=setTimeout(()=>{a(!1,1e-7)},1e3)}_=!1}try{r=new IntersectionObserver(g,{...h,root:o.ownerDocument})}catch(e){r=new IntersectionObserver(g,h)}r.observe(e)}(!0),i}(s,t):null,p=-1,v=null;u&&(v=new ResizeObserver(e=>{let[r]=e;r&&r.target===s&&v&&(v.unobserve(n),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var e;null==(e=v)||e.observe(n)})),t()}),s&&!l&&v.observe(s),v.observe(n));let h=l?ed(e):null;return l&&function n(){let r=ed(e);h&&(r.x!==h.x||r.y!==h.y||r.width!==h.width||r.height!==h.height)&&t(),h=r,o=requestAnimationFrame(n)}(),t(),()=>{var e;f.forEach(e=>{i&&e.removeEventListener("scroll",t),a&&e.removeEventListener("resize",t)}),null==d||d(),null==(e=v)||e.disconnect(),v=null,l&&cancelAnimationFrame(o)}}let ex=e=>({name:"arrow",options:e,async fn(n){let{x:t,y:r,placement:o,rects:i,platform:a,elements:u,middlewareData:c}=n,{element:l,padding:s=0}=P(e,n)||{};if(null==l)return{};let f=F(s),d={x:t,y:r},p=N(k(o)),v=A(p),h=await a.getDimensions(l),_="y"===p,g=_?"clientHeight":"clientWidth",m=i.reference[v]+i.reference[p]-d[p]-i.floating[v],w=d[p]-i.reference[p],y=await (null==a.getOffsetParent?void 0:a.getOffsetParent(l)),x=y?y[g]:0;x&&await (null==a.isElement?void 0:a.isElement(y))||(x=u.floating[g]||i.floating[v]);let R=x/2-h[v]/2-1,C=b(f[_?"top":"left"],R),D=b(f[_?"bottom":"right"],R),E=x-h[v]-D,T=x/2-h[v]/2+(m/2-w/2),j=M(C,b(T,E)),O=!c.arrow&&null!=S(o)&&T!==j&&i.reference[v]/2-(T<C?C:D)-h[v]/2<0,I=O?T<C?T-C:T-E:0;return{[p]:d[p]+I,data:{[p]:j,centerOffset:T-j-I,...O&&{alignmentOffset:I}},reset:O}}}),eb=(e,n,t)=>{let r=new Map,o={platform:ew,...t},i={...o.platform,_c:r};return W(e,n,{...o,platform:i})};var eM=t(8339),eR="undefined"!=typeof document?u.useLayoutEffect:u.useEffect;function eC(e,n){let t,r,o;if(e===n)return!0;if(typeof e!=typeof n)return!1;if("function"==typeof e&&e.toString()===n.toString())return!0;if(e&&n&&"object"==typeof e){if(Array.isArray(e)){if((t=e.length)!==n.length)return!1;for(r=t;0!=r--;)if(!eC(e[r],n[r]))return!1;return!0}if((t=(o=Object.keys(e)).length)!==Object.keys(n).length)return!1;for(r=t;0!=r--;)if(!({}).hasOwnProperty.call(n,o[r]))return!1;for(r=t;0!=r--;){let t=o[r];if(("_owner"!==t||!e.$$typeof)&&!eC(e[t],n[t]))return!1}return!0}return e!=e&&n!=n}function eD(e){return"undefined"==typeof window?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function eE(e,n){let t=eD(e);return Math.round(n*t)/t}function eT(e){let n=u.useRef(e);return eR(()=>{n.current=e}),n}let eP=e=>({name:"arrow",options:e,fn(n){let{element:t,padding:r}="function"==typeof e?e(n):e;return t&&({}).hasOwnProperty.call(t,"current")?null!=t.current?ex({element:t.current,padding:r}).fn(n):{}:t?ex({element:t,padding:r}).fn(n):{}}}),ej=(e,n)=>{var t;return{...(void 0===(t=e)&&(t=0),{name:"offset",options:t,async fn(e){var n,r;let{x:o,y:i,placement:a,middlewareData:u}=e,c=await B(e,t);return a===(null==(n=u.offset)?void 0:n.placement)&&null!=(r=u.arrow)&&r.alignmentOffset?{}:{x:o+c.x,y:i+c.y,data:{...c,placement:a}}}}),options:[e,n]}},eS=(e,n)=>{var t;return{...(void 0===(t=e)&&(t={}),{name:"shift",options:t,async fn(e){let{x:n,y:r,placement:o}=e,{mainAxis:i=!0,crossAxis:a=!1,limiter:u={fn:e=>{let{x:n,y:t}=e;return{x:n,y:t}}},...c}=P(t,e),l={x:n,y:r},s=await K(e,c),f=k(j(o)),d=N(f),p=l[d],v=l[f];if(i){let e="y"===d?"top":"left",n="y"===d?"bottom":"right",t=p+s[e],r=p-s[n];p=M(t,b(p,r))}if(a){let e="y"===f?"top":"left",n="y"===f?"bottom":"right",t=v+s[e],r=v-s[n];v=M(t,b(v,r))}let h=u.fn({...e,[d]:p,[f]:v});return{...h,data:{x:h.x-n,y:h.y-r}}}}),options:[e,n]}},eN=(e,n)=>{var t;return{...(void 0===(t=e)&&(t={}),{options:t,fn(e){let{x:n,y:r,placement:o,rects:i,middlewareData:a}=e,{offset:u=0,mainAxis:c=!0,crossAxis:l=!0}=P(t,e),s={x:n,y:r},f=k(o),d=N(f),p=s[d],v=s[f],h=P(u,e),_="number"==typeof h?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(c){let e="y"===d?"height":"width",n=i.reference[d]-i.floating[e]+_.mainAxis,t=i.reference[d]+i.reference[e]-_.mainAxis;p<n?p=n:p>t&&(p=t)}if(l){var g,m;let e="y"===d?"width":"height",n=["top","left"].includes(j(o)),t=i.reference[f]-i.floating[e]+(n&&(null==(g=a.offset)?void 0:g[f])||0)+(n?0:_.crossAxis),r=i.reference[f]+i.reference[e]+(n?0:(null==(m=a.offset)?void 0:m[f])||0)-(n?_.crossAxis:0);v<t?v=t:v>r&&(v=r)}return{[d]:p,[f]:v}}}),options:[e,n]}},eA=(e,n)=>{var t;return{...(void 0===(t=e)&&(t={}),{name:"flip",options:t,async fn(e){var n,r,o,i,a;let{placement:u,middlewareData:c,rects:l,initialPlacement:s,platform:f,elements:d}=e,{mainAxis:p=!0,crossAxis:v=!0,fallbackPlacements:h,fallbackStrategy:_="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:m=!0,...w}=P(t,e);if(null!=(n=c.arrow)&&n.alignmentOffset)return{};let y=j(u),x=k(s),b=j(s)===s,M=await (null==f.isRTL?void 0:f.isRTL(d.floating)),R=h||(b||!m?[I(s)]:function(e){let n=I(e);return[O(e),n,O(n)]}(s)),C="none"!==g;!h&&C&&R.push(...function(e,n,t,r){let o=S(e),i=function(e,n,t){let r=["left","right"],o=["right","left"];switch(e){case"top":case"bottom":if(t)return n?o:r;return n?r:o;case"left":case"right":return n?["top","bottom"]:["bottom","top"];default:return[]}}(j(e),"start"===t,r);return o&&(i=i.map(e=>e+"-"+o),n&&(i=i.concat(i.map(O)))),i}(s,m,g,M));let D=[s,...R],E=await K(e,w),T=[],F=(null==(r=c.flip)?void 0:r.overflows)||[];if(p&&T.push(E[y]),v){let e=function(e,n,t){void 0===t&&(t=!1);let r=S(e),o=N(k(e)),i=A(o),a="x"===o?r===(t?"end":"start")?"right":"left":"start"===r?"bottom":"top";return n.reference[i]>n.floating[i]&&(a=I(a)),[a,I(a)]}(u,l,M);T.push(E[e[0]],E[e[1]])}if(F=[...F,{placement:u,overflows:T}],!T.every(e=>e<=0)){let e=((null==(o=c.flip)?void 0:o.index)||0)+1,n=D[e];if(n)return{data:{index:e,overflows:F},reset:{placement:n}};let t=null==(i=F.filter(e=>e.overflows[0]<=0).sort((e,n)=>e.overflows[1]-n.overflows[1])[0])?void 0:i.placement;if(!t)switch(_){case"bestFit":{let e=null==(a=F.filter(e=>{if(C){let n=k(e.placement);return n===x||"y"===n}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,n)=>e+n,0)]).sort((e,n)=>e[1]-n[1])[0])?void 0:a[0];e&&(t=e);break}case"initialPlacement":t=s}if(u!==t)return{reset:{placement:t}}}return{}}}),options:[e,n]}},ek=(e,n)=>{var t;return{...(void 0===(t=e)&&(t={}),{name:"size",options:t,async fn(e){let n,r;let{placement:o,rects:i,platform:a,elements:u}=e,{apply:c=()=>{},...l}=P(t,e),s=await K(e,l),f=j(o),d=S(o),p="y"===k(o),{width:v,height:h}=i.floating;"top"===f||"bottom"===f?(n=f,r=d===(await (null==a.isRTL?void 0:a.isRTL(u.floating))?"start":"end")?"left":"right"):(r=f,n="end"===d?"top":"bottom");let _=h-s.top-s.bottom,g=v-s.left-s.right,m=b(h-s[n],_),w=b(v-s[r],g),y=!e.middlewareData.shift,x=m,R=w;if(p?R=d||y?b(w,g):g:x=d||y?b(m,_):_,y&&!d){let e=M(s.left,0),n=M(s.right,0),t=M(s.top,0),r=M(s.bottom,0);p?R=v-2*(0!==e||0!==n?e+n:M(s.left,s.right)):x=h-2*(0!==t||0!==r?t+r:M(s.top,s.bottom))}await c({...e,availableWidth:R,availableHeight:x});let C=await a.getDimensions(u.floating);return v!==C.width||h!==C.height?{reset:{rects:!0}}:{}}}),options:[e,n]}},eO=(e,n)=>{var t;return{...(void 0===(t=e)&&(t={}),{name:"hide",options:t,async fn(e){let{rects:n}=e,{strategy:r="referenceHidden",...o}=P(t,e);switch(r){case"referenceHidden":{let t=z(await K(e,{...o,elementContext:"reference"}),n.reference);return{data:{referenceHiddenOffsets:t,referenceHidden:H(t)}}}case"escaped":{let t=z(await K(e,{...o,altBoundary:!0}),n.floating);return{data:{escapedOffsets:t,escaped:H(t)}}}default:return{}}}}),options:[e,n]}},eI=(e,n)=>({...eP(e),options:[e,n]});var eF=t(513),eL=u.forwardRef((e,n)=>{let{children:t,width:r=10,height:o=5,...i}=e;return(0,eF.jsx)(d.WV.svg,{...i,ref:n,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?t:(0,eF.jsx)("polygon",{points:"0,0 30,0 15,10"})})});eL.displayName="Arrow";var eV=t(9652),eW=t(3464),eK="Popper",ez=(0,a._)((0,s.b)(eK),2),eH=ez[0],eB=ez[1],eG=(0,a._)(eH(eK),2),eU=eG[0],eX=eG[1],eY=function(e){var n=e.__scopePopper,t=e.children,r=(0,a._)(u.useState(null),2),o=r[0],i=r[1];return(0,eF.jsx)(eU,{scope:n,anchor:o,onAnchorChange:i,children:t})};eY.displayName=eK;var eq="PopperAnchor",eZ=u.forwardRef(function(e,n){var t=e.__scopePopper,a=e.virtualRef,c=(0,i._)(e,["__scopePopper","virtualRef"]),s=eX(eq,t),f=u.useRef(null),p=(0,l.e)(n,f);return u.useEffect(function(){s.onAnchorChange((null==a?void 0:a.current)||f.current)}),a?null:(0,eF.jsx)(d.WV.div,(0,o._)((0,r._)({},c),{ref:p}))});eZ.displayName=eq;var e$="PopperContent",eJ=(0,a._)(eH(e$),2),eQ=eJ[0],e0=eJ[1],e1=u.forwardRef(function(e,n){var t,c,s,f,v,h,_,g,m=e.__scopePopper,w=e.side,x=e.sideOffset,b=e.align,M=void 0===b?"center":b,R=e.alignOffset,C=e.arrowPadding,D=e.avoidCollisions,E=void 0===D||D,T=e.collisionBoundary,P=void 0===T?[]:T,j=e.collisionPadding,S=void 0===j?0:j,N=e.sticky,A=e.hideWhenDetached,k=e.updatePositionStrategy,O=void 0===k?"optimized":k,I=e.onPlaced,F=(0,i._)(e,["__scopePopper","side","sideOffset","align","alignOffset","arrowPadding","avoidCollisions","collisionBoundary","collisionPadding","sticky","hideWhenDetached","updatePositionStrategy","onPlaced"]),L=eX(e$,m),V=(0,a._)(u.useState(null),2),W=V[0],K=V[1],z=(0,l.e)(n,function(e){return K(e)}),H=(0,a._)(u.useState(null),2),B=H[0],G=H[1],U=function(e){let[n,t]=u.useState(void 0);return(0,eW.b)(()=>{if(e){t({width:e.offsetWidth,height:e.offsetHeight});let n=new ResizeObserver(n=>{let r,o;if(!Array.isArray(n)||!n.length)return;let i=n[0];if("borderBoxSize"in i){let e=i.borderBoxSize,n=Array.isArray(e)?e[0]:e;r=n.inlineSize,o=n.blockSize}else r=e.offsetWidth,o=e.offsetHeight;t({width:r,height:o})});return n.observe(e,{box:"border-box"}),()=>n.unobserve(e)}t(void 0)},[e]),n}(B),X=null!==(_=null==U?void 0:U.width)&&void 0!==_?_:0,Y=null!==(g=null==U?void 0:U.height)&&void 0!==g?g:0,q="number"==typeof S?S:(0,r._)({top:0,right:0,bottom:0,left:0},S),Z=Array.isArray(P)?P:[P],$=Z.length>0,J={padding:q,boundary:Z.filter(e3),altBoundary:$},Q=function(e){void 0===e&&(e={});let{placement:n="bottom",strategy:t="absolute",middleware:r=[],platform:o,elements:{reference:i,floating:a}={},transform:c=!0,whileElementsMounted:l,open:s}=e,[f,d]=u.useState({x:0,y:0,strategy:t,placement:n,middlewareData:{},isPositioned:!1}),[p,v]=u.useState(r);eC(p,r)||v(r);let[h,_]=u.useState(null),[g,m]=u.useState(null),w=u.useCallback(e=>{e!==M.current&&(M.current=e,_(e))},[]),y=u.useCallback(e=>{e!==R.current&&(R.current=e,m(e))},[]),x=i||h,b=a||g,M=u.useRef(null),R=u.useRef(null),C=u.useRef(f),D=null!=l,E=eT(l),T=eT(o),P=u.useCallback(()=>{if(!M.current||!R.current)return;let e={placement:n,strategy:t,middleware:p};T.current&&(e.platform=T.current),eb(M.current,R.current,e).then(e=>{let n={...e,isPositioned:!0};j.current&&!eC(C.current,n)&&(C.current=n,eM.flushSync(()=>{d(n)}))})},[p,n,t,T]);eR(()=>{!1===s&&C.current.isPositioned&&(C.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[s]);let j=u.useRef(!1);eR(()=>(j.current=!0,()=>{j.current=!1}),[]),eR(()=>{if(x&&(M.current=x),b&&(R.current=b),x&&b){if(E.current)return E.current(x,b,P);P()}},[x,b,P,E,D]);let S=u.useMemo(()=>({reference:M,floating:R,setReference:w,setFloating:y}),[w,y]),N=u.useMemo(()=>({reference:x,floating:b}),[x,b]),A=u.useMemo(()=>{let e={position:t,left:0,top:0};if(!N.floating)return e;let n=eE(N.floating,f.x),r=eE(N.floating,f.y);return c?{...e,transform:"translate("+n+"px, "+r+"px)",...eD(N.floating)>=1.5&&{willChange:"transform"}}:{position:t,left:n,top:r}},[t,c,N.floating,f.x,f.y]);return u.useMemo(()=>({...f,update:P,refs:S,elements:N,floatingStyles:A}),[f,P,S,N,A])}({strategy:"fixed",placement:(void 0===w?"bottom":w)+("center"!==M?"-"+M:""),whileElementsMounted:function(){for(var e=arguments.length,n=Array(e),t=0;t<e;t++)n[t]=arguments[t];return ey.apply(void 0,(0,p._)(n).concat([{animationFrame:"always"===O}]))},elements:{reference:L.anchor},middleware:[ej({mainAxis:(void 0===x?0:x)+Y,alignmentAxis:void 0===R?0:R}),E&&eS((0,r._)({mainAxis:!0,crossAxis:!1,limiter:"partial"===(void 0===N?"partial":N)?eN():void 0},J)),E&&eA((0,r._)({},J)),ek((0,o._)((0,r._)({},J),{apply:function(e){var n=e.elements,t=e.rects,r=e.availableWidth,o=e.availableHeight,i=t.reference,a=i.width,u=i.height,c=n.floating.style;c.setProperty("--radix-popper-available-width","".concat(r,"px")),c.setProperty("--radix-popper-available-height","".concat(o,"px")),c.setProperty("--radix-popper-anchor-width","".concat(a,"px")),c.setProperty("--radix-popper-anchor-height","".concat(u,"px"))}})),B&&eI({element:B,padding:void 0===C?0:C}),e8({arrowWidth:X,arrowHeight:Y}),void 0!==A&&A&&eO((0,r._)({strategy:"referenceHidden"},J))]}),ee=Q.refs,en=Q.floatingStyles,et=Q.placement,er=Q.isPositioned,eo=Q.middlewareData,ei=(0,a._)(e9(et),2),ea=ei[0],eu=ei[1],ec=(0,eV.W)(I);(0,eW.b)(function(){er&&(null==ec||ec())},[er,ec]);var el=null===(t=eo.arrow)||void 0===t?void 0:t.x,es=null===(c=eo.arrow)||void 0===c?void 0:c.y,ef=(null===(s=eo.arrow)||void 0===s?void 0:s.centerOffset)!==0,ed=(0,a._)(u.useState(),2),ep=ed[0],ev=ed[1];return(0,eW.b)(function(){W&&ev(window.getComputedStyle(W).zIndex)},[W]),(0,eF.jsx)("div",{ref:ee.setFloating,"data-radix-popper-content-wrapper":"",style:(0,r._)((0,o._)((0,r._)({},en),(0,y._)({transform:er?en.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ep},"--radix-popper-transform-origin",[null===(f=eo.transformOrigin)||void 0===f?void 0:f.x,null===(v=eo.transformOrigin)||void 0===v?void 0:v.y].join(" "))),(null===(h=eo.hide)||void 0===h?void 0:h.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}),dir:e.dir,children:(0,eF.jsx)(eQ,{scope:m,placedSide:ea,onArrowChange:G,arrowX:el,arrowY:es,shouldHideArrow:ef,children:(0,eF.jsx)(d.WV.div,(0,o._)((0,r._)({"data-side":ea,"data-align":eu},F),{ref:z,style:(0,o._)((0,r._)({},F.style),{animation:er?void 0:"none"})}))})})});e1.displayName=e$;var e2="PopperArrow",e5={top:"bottom",right:"left",bottom:"top",left:"right"},e6=u.forwardRef(function(e,n){var t,a=e.__scopePopper,u=(0,i._)(e,["__scopePopper"]),c=e0(e2,a),l=e5[c.placedSide];return(0,eF.jsx)("span",{ref:c.onArrowChange,style:(t={position:"absolute",left:c.arrowX,top:c.arrowY},(0,y._)(t,l,0),(0,y._)(t,"transformOrigin",{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[c.placedSide]),(0,y._)(t,"transform",{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[c.placedSide]),(0,y._)(t,"visibility",c.shouldHideArrow?"hidden":void 0),t),children:(0,eF.jsx)(eL,(0,o._)((0,r._)({},u),{ref:n,style:(0,o._)((0,r._)({},u.style),{display:"block"})}))})});function e3(e){return null!==e}e6.displayName=e2;var e8=function(e){return{name:"transformOrigin",options:e,fn:function(n){var t,r,o,i,u,c=n.placement,l=n.rects,s=n.middlewareData,f=(null===(t=s.arrow)||void 0===t?void 0:t.centerOffset)!==0,d=f?0:e.arrowWidth,p=f?0:e.arrowHeight,v=(0,a._)(e9(c),2),h=v[0],_={start:"0%",center:"50%",end:"100%"}[v[1]],g=(null!==(i=null===(r=s.arrow)||void 0===r?void 0:r.x)&&void 0!==i?i:0)+d/2,m=(null!==(u=null===(o=s.arrow)||void 0===o?void 0:o.y)&&void 0!==u?u:0)+p/2,w="",y="";return"bottom"===h?(w=f?_:"".concat(g,"px"),y="".concat(-p,"px")):"top"===h?(w=f?_:"".concat(g,"px"),y="".concat(l.floating.height+p,"px")):"right"===h?(w="".concat(-p,"px"),y=f?_:"".concat(m,"px")):"left"===h&&(w="".concat(l.floating.width+p,"px"),y=f?_:"".concat(m,"px")),{data:{x:w,y:y}}}}};function e9(e){var n=(0,a._)(e.split("-"),2),t=n[0],r=n[1];return[t,void 0===r?"center":r]}var e7=t(5482),e4=t(6941),ne="rovingFocusGroup.onEntryFocus",nn={bubbles:!1,cancelable:!0},nt="RovingFocusGroup",nr=(0,a._)((0,v.B)(nt),3),no=nr[0],ni=nr[1],na=nr[2],nu=(0,a._)((0,s.b)(nt,[na]),2),nc=nu[0],nl=nu[1],ns=(0,a._)(nc(nt),2),nf=ns[0],nd=ns[1],np=u.forwardRef(function(e,n){return(0,eF.jsx)(no.Provider,{scope:e.__scopeRovingFocusGroup,children:(0,eF.jsx)(no.Slot,{scope:e.__scopeRovingFocusGroup,children:(0,eF.jsx)(nv,(0,o._)((0,r._)({},e),{ref:n}))})})});np.displayName=nt;var nv=u.forwardRef(function(e,n){var t=e.__scopeRovingFocusGroup,s=e.orientation,v=e.loop,_=e.dir,g=e.currentTabStopId,m=e.defaultCurrentTabStopId,w=e.onCurrentTabStopIdChange,y=e.onEntryFocus,x=e.preventScrollOnEntryFocus,b=void 0!==x&&x,M=(0,i._)(e,["__scopeRovingFocusGroup","orientation","loop","dir","currentTabStopId","defaultCurrentTabStopId","onCurrentTabStopIdChange","onEntryFocus","preventScrollOnEntryFocus"]),R=u.useRef(null),C=(0,l.e)(n,R),D=(0,h.gm)(_),E=(0,a._)((0,f.T)({prop:g,defaultProp:m,onChange:w}),2),T=E[0],P=void 0===T?null:T,j=E[1],S=(0,a._)(u.useState(!1),2),N=S[0],A=S[1],k=(0,eV.W)(y),O=ni(t),I=u.useRef(!1),F=(0,a._)(u.useState(0),2),L=F[0],V=F[1];return u.useEffect(function(){var e=R.current;if(e)return e.addEventListener(ne,k),function(){return e.removeEventListener(ne,k)}},[k]),(0,eF.jsx)(nf,{scope:t,orientation:s,dir:D,loop:void 0!==v&&v,currentTabStopId:P,onItemFocus:u.useCallback(function(e){return j(e)},[j]),onItemShiftTab:u.useCallback(function(){return A(!0)},[]),onFocusableItemAdd:u.useCallback(function(){return V(function(e){return e+1})},[]),onFocusableItemRemove:u.useCallback(function(){return V(function(e){return e-1})},[]),children:(0,eF.jsx)(d.WV.div,(0,o._)((0,r._)({tabIndex:N||0===L?-1:0,"data-orientation":s},M),{ref:C,style:(0,r._)({outline:"none"},e.style),onMouseDown:(0,c.M)(e.onMouseDown,function(){I.current=!0}),onFocus:(0,c.M)(e.onFocus,function(e){var n=!I.current;if(e.target===e.currentTarget&&n&&!N){var t=new CustomEvent(ne,nn);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){var r=O().filter(function(e){return e.focusable});nm([r.find(function(e){return e.active}),r.find(function(e){return e.id===P})].concat((0,p._)(r)).filter(Boolean).map(function(e){return e.ref.current}),b)}}I.current=!1}),onBlur:(0,c.M)(e.onBlur,function(){return A(!1)})}))})}),nh="RovingFocusGroupItem",n_=u.forwardRef(function(e,n){var t=e.__scopeRovingFocusGroup,a=e.focusable,l=void 0===a||a,s=e.active,f=e.tabStopId,p=(0,i._)(e,["__scopeRovingFocusGroup","focusable","active","tabStopId"]),v=(0,w.M)(),h=f||v,_=nd(nh,t),g=_.currentTabStopId===h,m=ni(t),y=_.onFocusableItemAdd,x=_.onFocusableItemRemove;return u.useEffect(function(){if(l)return y(),function(){return x()}},[l,y,x]),(0,eF.jsx)(no.ItemSlot,{scope:t,id:h,focusable:l,active:void 0!==s&&s,children:(0,eF.jsx)(d.WV.span,(0,o._)((0,r._)({tabIndex:g?0:-1,"data-orientation":_.orientation},p),{ref:n,onMouseDown:(0,c.M)(e.onMouseDown,function(e){l?_.onItemFocus(h):e.preventDefault()}),onFocus:(0,c.M)(e.onFocus,function(){return _.onItemFocus(h)}),onKeyDown:(0,c.M)(e.onKeyDown,function(e){if("Tab"===e.key&&e.shiftKey){_.onItemShiftTab();return}if(e.target===e.currentTarget){var n=function(e,n,t){var r,o=(r=e.key,"rtl"!==t?r:"ArrowLeft"===r?"ArrowRight":"ArrowRight"===r?"ArrowLeft":r);if(!("vertical"===n&&["ArrowLeft","ArrowRight"].includes(o))&&!("horizontal"===n&&["ArrowUp","ArrowDown"].includes(o)))return ng[o]}(e,_.orientation,_.dir);if(void 0!==n){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();var t=m().filter(function(e){return e.focusable}).map(function(e){return e.ref.current});if("last"===n)t.reverse();else if("prev"===n||"next"===n){"prev"===n&&t.reverse();var r,o,i=t.indexOf(e.currentTarget);t=_.loop?(r=t,o=i+1,r.map(function(e,n){return r[(o+n)%r.length]})):t.slice(i+1)}setTimeout(function(){return nm(t)})}}})}))})});n_.displayName=nh;var ng={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function nm(e){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],t=document.activeElement,r=!0,o=!1,i=void 0;try{for(var a,u=e[Symbol.iterator]();!(r=(a=u.next()).done);r=!0){var c=a.value;if(c===t||(c.focus({preventScroll:n}),document.activeElement!==t))return}}catch(e){o=!0,i=e}finally{try{r||null==u.return||u.return()}finally{if(o)throw i}}}var nw=t(3372),ny=t(4628),nx=t(8300),nb=["Enter"," "],nM=["ArrowUp","PageDown","End"],nR=(0,p._)(["ArrowDown","PageUp","Home"]).concat((0,p._)(nM)),nC={ltr:(0,p._)(nb).concat(["ArrowRight"]),rtl:(0,p._)(nb).concat(["ArrowLeft"])},nD={ltr:["ArrowLeft"],rtl:["ArrowRight"]},nE="Menu",nT=(0,a._)((0,v.B)(nE),3),nP=nT[0],nj=nT[1],nS=nT[2],nN=(0,a._)((0,s.b)(nE,[nS,eB,nl]),2),nA=nN[0],nk=nN[1],nO=eB(),nI=nl(),nF=(0,a._)(nA(nE),2),nL=nF[0],nV=nF[1],nW=(0,a._)(nA(nE),2),nK=nW[0],nz=nW[1],nH=function(e){var n=e.__scopeMenu,t=e.open,i=e.children,c=e.dir,l=e.onOpenChange,s=e.modal,f=nO(n),d=(0,a._)(u.useState(null),2),p=d[0],v=d[1],_=u.useRef(!1),g=(0,eV.W)(l),m=(0,h.gm)(c);return u.useEffect(function(){var e=function(){_.current=!0,document.addEventListener("pointerdown",n,{capture:!0,once:!0}),document.addEventListener("pointermove",n,{capture:!0,once:!0})},n=function(){return _.current=!1};return document.addEventListener("keydown",e,{capture:!0}),function(){document.removeEventListener("keydown",e,{capture:!0}),document.removeEventListener("pointerdown",n,{capture:!0}),document.removeEventListener("pointermove",n,{capture:!0})}},[]),(0,eF.jsx)(eY,(0,o._)((0,r._)({},f),{children:(0,eF.jsx)(nL,{scope:n,open:void 0!==t&&t,onOpenChange:g,content:p,onContentChange:v,children:(0,eF.jsx)(nK,{scope:n,onClose:u.useCallback(function(){return g(!1)},[g]),isUsingKeyboardRef:_,dir:m,modal:void 0===s||s,children:i})})}))};nH.displayName=nE;var nB=u.forwardRef(function(e,n){var t=e.__scopeMenu,a=(0,i._)(e,["__scopeMenu"]),u=nO(t);return(0,eF.jsx)(eZ,(0,o._)((0,r._)({},u,a),{ref:n}))});nB.displayName="MenuAnchor";var nG="MenuPortal",nU=(0,a._)(nA(nG,{forceMount:void 0}),2),nX=nU[0],nY=nU[1],nq=function(e){var n=e.__scopeMenu,t=e.forceMount,r=e.children,o=e.container,i=nV(nG,n);return(0,eF.jsx)(nX,{scope:n,forceMount:t,children:(0,eF.jsx)(e4.z,{present:t||i.open,children:(0,eF.jsx)(e7.h,{asChild:!0,container:o,children:r})})})};nq.displayName=nG;var nZ="MenuContent",n$=(0,a._)(nA(nZ),2),nJ=n$[0],nQ=n$[1],n0=u.forwardRef(function(e,n){var t=nY(nZ,e.__scopeMenu),a=e.forceMount,u=void 0===a?t.forceMount:a,c=(0,i._)(e,["forceMount"]),l=nV(nZ,e.__scopeMenu),s=nz(nZ,e.__scopeMenu);return(0,eF.jsx)(nP.Provider,{scope:e.__scopeMenu,children:(0,eF.jsx)(e4.z,{present:u||l.open,children:(0,eF.jsx)(nP.Slot,{scope:e.__scopeMenu,children:s.modal?(0,eF.jsx)(n1,(0,o._)((0,r._)({},c),{ref:n})):(0,eF.jsx)(n2,(0,o._)((0,r._)({},c),{ref:n}))})})})}),n1=u.forwardRef(function(e,n){var t=nV(nZ,e.__scopeMenu),i=u.useRef(null),a=(0,l.e)(n,i);return u.useEffect(function(){var e=i.current;if(e)return(0,ny.Ry)(e)},[]),(0,eF.jsx)(n5,(0,o._)((0,r._)({},e),{ref:a,trapFocus:t.open,disableOutsidePointerEvents:t.open,disableOutsideScroll:!0,onFocusOutside:(0,c.M)(e.onFocusOutside,function(e){return e.preventDefault()},{checkForDefaultPrevented:!1}),onDismiss:function(){return t.onOpenChange(!1)}}))}),n2=u.forwardRef(function(e,n){var t=nV(nZ,e.__scopeMenu);return(0,eF.jsx)(n5,(0,o._)((0,r._)({},e),{ref:n,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:function(){return t.onOpenChange(!1)}}))}),n5=u.forwardRef(function(e,n){var t=e.__scopeMenu,s=e.loop,f=e.trapFocus,d=e.onOpenAutoFocus,p=e.onCloseAutoFocus,v=e.disableOutsidePointerEvents,h=e.onEntryFocus,w=e.onEscapeKeyDown,y=e.onPointerDownOutside,x=e.onFocusOutside,b=e.onInteractOutside,M=e.onDismiss,R=e.disableOutsideScroll,C=(0,i._)(e,["__scopeMenu","loop","trapFocus","onOpenAutoFocus","onCloseAutoFocus","disableOutsidePointerEvents","onEntryFocus","onEscapeKeyDown","onPointerDownOutside","onFocusOutside","onInteractOutside","onDismiss","disableOutsideScroll"]),D=nV(nZ,t),E=nz(nZ,t),T=nO(t),P=nI(t),j=nj(t),S=(0,a._)(u.useState(null),2),N=S[0],A=S[1],k=u.useRef(null),O=(0,l.e)(n,k,D.onContentChange),I=u.useRef(0),F=u.useRef(""),L=u.useRef(0),V=u.useRef(null),W=u.useRef("right"),K=u.useRef(0),z=R?nx.Z:u.Fragment,H=R?{as:nw.g7,allowPinchZoom:!0}:void 0,B=function(e){var n,t,r,o,i,a,u,c,l,s=F.current+e,f=j().filter(function(e){return!e.disabled}),d=document.activeElement,p=null===(c=f.find(function(e){return e.ref.current===d}))||void 0===c?void 0:c.textValue,v=(n=f.map(function(e){return e.textValue}),t=s,r=p,i=t.length>1&&Array.from(t).every(function(e){return e===t[0]})?t[0]:t,a=(o=Math.max(r?n.indexOf(r):-1,0),n.map(function(e,t){return n[(o+t)%n.length]})),1===i.length&&(a=a.filter(function(e){return e!==r})),(u=a.find(function(e){return e.toLowerCase().startsWith(i.toLowerCase())}))!==r?u:void 0),h=null===(l=f.find(function(e){return e.textValue===v}))||void 0===l?void 0:l.ref.current;!function e(n){F.current=n,window.clearTimeout(I.current),""!==n&&(I.current=window.setTimeout(function(){return e("")},1e3))}(s),h&&setTimeout(function(){return h.focus()})};u.useEffect(function(){return function(){return window.clearTimeout(I.current)}},[]),(0,g.EW)();var G=u.useCallback(function(e){var n,t,r;return W.current===(null===(n=V.current)||void 0===n?void 0:n.side)&&!!(r=null===(t=V.current)||void 0===t?void 0:t.area)&&function(e,n){for(var t=e.x,r=e.y,o=!1,i=0,a=n.length-1;i<n.length;a=i++){var u=n[i].x,c=n[i].y,l=n[a].x,s=n[a].y;c>r!=s>r&&t<(l-u)*(r-c)/(s-c)+u&&(o=!o)}return o}({x:e.clientX,y:e.clientY},r)},[]);return(0,eF.jsx)(nJ,{scope:t,searchRef:F,onItemEnter:u.useCallback(function(e){G(e)&&e.preventDefault()},[G]),onItemLeave:u.useCallback(function(e){var n;G(e)||(null===(n=k.current)||void 0===n||n.focus(),A(null))},[G]),onTriggerLeave:u.useCallback(function(e){G(e)&&e.preventDefault()},[G]),pointerGraceTimerRef:L,onPointerGraceIntentChange:u.useCallback(function(e){V.current=e},[]),children:(0,eF.jsx)(z,(0,o._)((0,r._)({},H),{children:(0,eF.jsx)(m.M,{asChild:!0,trapped:f,onMountAutoFocus:(0,c.M)(d,function(e){var n;e.preventDefault(),null===(n=k.current)||void 0===n||n.focus({preventScroll:!0})}),onUnmountAutoFocus:p,children:(0,eF.jsx)(_.XB,{asChild:!0,disableOutsidePointerEvents:v,onEscapeKeyDown:w,onPointerDownOutside:y,onFocusOutside:x,onInteractOutside:b,onDismiss:M,children:(0,eF.jsx)(np,(0,o._)((0,r._)({asChild:!0},P),{dir:E.dir,orientation:"vertical",loop:void 0!==s&&s,currentTabStopId:N,onCurrentTabStopIdChange:A,onEntryFocus:(0,c.M)(h,function(e){E.isUsingKeyboardRef.current||e.preventDefault()}),preventScrollOnEntryFocus:!0,children:(0,eF.jsx)(e1,(0,o._)((0,r._)({role:"menu","aria-orientation":"vertical","data-state":tR(D.open),"data-radix-menu-content":"",dir:E.dir},T,C),{ref:O,style:(0,r._)({outline:"none"},C.style),onKeyDown:(0,c.M)(C.onKeyDown,function(e){var n=e.target.closest("[data-radix-menu-content]")===e.currentTarget,t=e.ctrlKey||e.altKey||e.metaKey,r=1===e.key.length;n&&("Tab"===e.key&&e.preventDefault(),!t&&r&&B(e.key));var o=k.current;if(e.target===o&&nR.includes(e.key)){e.preventDefault();var i=j().filter(function(e){return!e.disabled}).map(function(e){return e.ref.current});nM.includes(e.key)&&i.reverse(),function(e){var n=document.activeElement,t=!0,r=!1,o=void 0;try{for(var i,a=e[Symbol.iterator]();!(t=(i=a.next()).done);t=!0){var u=i.value;if(u===n||(u.focus(),document.activeElement!==n))return}}catch(e){r=!0,o=e}finally{try{t||null==a.return||a.return()}finally{if(r)throw o}}}(i)}}),onBlur:(0,c.M)(e.onBlur,function(e){e.currentTarget.contains(e.target)||(window.clearTimeout(I.current),F.current="")}),onPointerMove:(0,c.M)(e.onPointerMove,tE(function(e){var n=e.target,t=K.current!==e.clientX;if(e.currentTarget.contains(n)&&t){var r=e.clientX>K.current?"right":"left";W.current=r,K.current=e.clientX}}))}))}))})})}))})});n0.displayName=nZ;var n6=u.forwardRef(function(e,n){e.__scopeMenu;var t=(0,i._)(e,["__scopeMenu"]);return(0,eF.jsx)(d.WV.div,(0,o._)((0,r._)({role:"group"},t),{ref:n}))});n6.displayName="MenuGroup";var n3=u.forwardRef(function(e,n){e.__scopeMenu;var t=(0,i._)(e,["__scopeMenu"]);return(0,eF.jsx)(d.WV.div,(0,o._)((0,r._)({},t),{ref:n}))});n3.displayName="MenuLabel";var n8="MenuItem",n9="menu.itemSelect",n7=u.forwardRef(function(e,n){var t=e.disabled,a=void 0!==t&&t,s=e.onSelect,f=(0,i._)(e,["disabled","onSelect"]),p=u.useRef(null),v=nz(n8,e.__scopeMenu),h=nQ(n8,e.__scopeMenu),_=(0,l.e)(n,p),g=u.useRef(!1);return(0,eF.jsx)(n4,(0,o._)((0,r._)({},f),{ref:_,disabled:a,onClick:(0,c.M)(e.onClick,function(){var e=p.current;if(!a&&e){var n=new CustomEvent(n9,{bubbles:!0,cancelable:!0});e.addEventListener(n9,function(e){return null==s?void 0:s(e)},{once:!0}),(0,d.jH)(e,n),n.defaultPrevented?g.current=!1:v.onClose()}}),onPointerDown:function(n){var t;null===(t=e.onPointerDown)||void 0===t||t.call(e,n),g.current=!0},onPointerUp:(0,c.M)(e.onPointerUp,function(e){var n;g.current||null===(n=e.currentTarget)||void 0===n||n.click()}),onKeyDown:(0,c.M)(e.onKeyDown,function(e){var n=""!==h.searchRef.current;!a&&(!n||" "!==e.key)&&nb.includes(e.key)&&(e.currentTarget.click(),e.preventDefault())})}))});n7.displayName=n8;var n4=u.forwardRef(function(e,n){var t=e.__scopeMenu,s=e.disabled,f=void 0!==s&&s,p=e.textValue,v=(0,i._)(e,["__scopeMenu","disabled","textValue"]),h=nQ(n8,t),_=nI(t),g=u.useRef(null),m=(0,l.e)(n,g),w=(0,a._)(u.useState(!1),2),y=w[0],x=w[1],b=(0,a._)(u.useState(""),2),M=b[0],R=b[1];return u.useEffect(function(){var e,n=g.current;n&&R((null!==(e=n.textContent)&&void 0!==e?e:"").trim())},[v.children]),(0,eF.jsx)(nP.ItemSlot,{scope:t,disabled:f,textValue:null!=p?p:M,children:(0,eF.jsx)(n_,(0,o._)((0,r._)({asChild:!0},_),{focusable:!f,children:(0,eF.jsx)(d.WV.div,(0,o._)((0,r._)({role:"menuitem","data-highlighted":y?"":void 0,"aria-disabled":f||void 0,"data-disabled":f?"":void 0},v),{ref:m,onPointerMove:(0,c.M)(e.onPointerMove,tE(function(e){f?h.onItemLeave(e):(h.onItemEnter(e),e.defaultPrevented||e.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:(0,c.M)(e.onPointerLeave,tE(function(e){return h.onItemLeave(e)})),onFocus:(0,c.M)(e.onFocus,function(){return x(!0)}),onBlur:(0,c.M)(e.onBlur,function(){return x(!1)})}))}))})}),te=u.forwardRef(function(e,n){var t=e.checked,a=void 0!==t&&t,u=e.onCheckedChange,l=(0,i._)(e,["checked","onCheckedChange"]);return(0,eF.jsx)(ts,{scope:e.__scopeMenu,checked:a,children:(0,eF.jsx)(n7,(0,o._)((0,r._)({role:"menuitemcheckbox","aria-checked":tC(a)?"mixed":a},l),{ref:n,"data-state":tD(a),onSelect:(0,c.M)(l.onSelect,function(){return null==u?void 0:u(!!tC(a)||!a)},{checkForDefaultPrevented:!1})}))})});te.displayName="MenuCheckboxItem";var tn="MenuRadioGroup",tt=(0,a._)(nA(tn,{value:void 0,onValueChange:function(){}}),2),tr=tt[0],to=tt[1],ti=u.forwardRef(function(e,n){var t=e.value,a=e.onValueChange,u=(0,i._)(e,["value","onValueChange"]),c=(0,eV.W)(a);return(0,eF.jsx)(tr,{scope:e.__scopeMenu,value:t,onValueChange:c,children:(0,eF.jsx)(n6,(0,o._)((0,r._)({},u),{ref:n}))})});ti.displayName=tn;var ta="MenuRadioItem",tu=u.forwardRef(function(e,n){var t=e.value,a=(0,i._)(e,["value"]),u=to(ta,e.__scopeMenu),l=t===u.value;return(0,eF.jsx)(ts,{scope:e.__scopeMenu,checked:l,children:(0,eF.jsx)(n7,(0,o._)((0,r._)({role:"menuitemradio","aria-checked":l},a),{ref:n,"data-state":tD(l),onSelect:(0,c.M)(a.onSelect,function(){var e;return null===(e=u.onValueChange)||void 0===e?void 0:e.call(u,t)},{checkForDefaultPrevented:!1})}))})});tu.displayName=ta;var tc="MenuItemIndicator",tl=(0,a._)(nA(tc,{checked:!1}),2),ts=tl[0],tf=tl[1],td=u.forwardRef(function(e,n){var t=e.__scopeMenu,a=e.forceMount,u=(0,i._)(e,["__scopeMenu","forceMount"]),c=tf(tc,t);return(0,eF.jsx)(e4.z,{present:a||tC(c.checked)||!0===c.checked,children:(0,eF.jsx)(d.WV.span,(0,o._)((0,r._)({},u),{ref:n,"data-state":tD(c.checked)}))})});td.displayName=tc;var tp=u.forwardRef(function(e,n){e.__scopeMenu;var t=(0,i._)(e,["__scopeMenu"]);return(0,eF.jsx)(d.WV.div,(0,o._)((0,r._)({role:"separator","aria-orientation":"horizontal"},t),{ref:n}))});tp.displayName="MenuSeparator";var tv=u.forwardRef(function(e,n){var t=e.__scopeMenu,a=(0,i._)(e,["__scopeMenu"]),u=nO(t);return(0,eF.jsx)(e6,(0,o._)((0,r._)({},u,a),{ref:n}))});tv.displayName="MenuArrow";var th="MenuSub",t_=(0,a._)(nA(th),2),tg=t_[0],tm=t_[1],tw=function(e){var n=e.__scopeMenu,t=e.children,i=e.open,c=e.onOpenChange,l=nV(th,n),s=nO(n),f=(0,a._)(u.useState(null),2),d=f[0],p=f[1],v=(0,a._)(u.useState(null),2),h=v[0],_=v[1],g=(0,eV.W)(c);return u.useEffect(function(){return!1===l.open&&g(!1),function(){return g(!1)}},[l.open,g]),(0,eF.jsx)(eY,(0,o._)((0,r._)({},s),{children:(0,eF.jsx)(nL,{scope:n,open:void 0!==i&&i,onOpenChange:g,content:h,onContentChange:_,children:(0,eF.jsx)(tg,{scope:n,contentId:(0,w.M)(),triggerId:(0,w.M)(),trigger:d,onTriggerChange:p,children:t})})}))};tw.displayName=th;var ty="MenuSubTrigger",tx=u.forwardRef(function(e,n){var t=nV(ty,e.__scopeMenu),i=nz(ty,e.__scopeMenu),a=tm(ty,e.__scopeMenu),s=nQ(ty,e.__scopeMenu),f=u.useRef(null),d=s.pointerGraceTimerRef,p=s.onPointerGraceIntentChange,v={__scopeMenu:e.__scopeMenu},h=u.useCallback(function(){f.current&&window.clearTimeout(f.current),f.current=null},[]);return u.useEffect(function(){return h},[h]),u.useEffect(function(){var e=d.current;return function(){window.clearTimeout(e),p(null)}},[d,p]),(0,eF.jsx)(nB,(0,o._)((0,r._)({asChild:!0},v),{children:(0,eF.jsx)(n4,(0,o._)((0,r._)({id:a.triggerId,"aria-haspopup":"menu","aria-expanded":t.open,"aria-controls":a.contentId,"data-state":tR(t.open)},e),{ref:(0,l.F)(n,a.onTriggerChange),onClick:function(n){var r;null===(r=e.onClick)||void 0===r||r.call(e,n),e.disabled||n.defaultPrevented||(n.currentTarget.focus(),t.open||t.onOpenChange(!0))},onPointerMove:(0,c.M)(e.onPointerMove,tE(function(n){s.onItemEnter(n),n.defaultPrevented||e.disabled||t.open||f.current||(s.onPointerGraceIntentChange(null),f.current=window.setTimeout(function(){t.onOpenChange(!0),h()},100))})),onPointerLeave:(0,c.M)(e.onPointerLeave,tE(function(e){h();var n=null===(r=t.content)||void 0===r?void 0:r.getBoundingClientRect();if(n){var r,o,i=null===(o=t.content)||void 0===o?void 0:o.dataset.side,a="right"===i,u=n[a?"left":"right"],c=n[a?"right":"left"];s.onPointerGraceIntentChange({area:[{x:e.clientX+(a?-5:5),y:e.clientY},{x:u,y:n.top},{x:c,y:n.top},{x:c,y:n.bottom},{x:u,y:n.bottom}],side:i}),window.clearTimeout(d.current),d.current=window.setTimeout(function(){return s.onPointerGraceIntentChange(null)},300)}else{if(s.onTriggerLeave(e),e.defaultPrevented)return;s.onPointerGraceIntentChange(null)}})),onKeyDown:(0,c.M)(e.onKeyDown,function(n){var r,o=""!==s.searchRef.current;!e.disabled&&(!o||" "!==n.key)&&nC[i.dir].includes(n.key)&&(t.onOpenChange(!0),null===(r=t.content)||void 0===r||r.focus(),n.preventDefault())})}))}))});tx.displayName=ty;var tb="MenuSubContent",tM=u.forwardRef(function(e,n){var t=nY(nZ,e.__scopeMenu),a=e.forceMount,s=void 0===a?t.forceMount:a,f=(0,i._)(e,["forceMount"]),d=nV(nZ,e.__scopeMenu),p=nz(nZ,e.__scopeMenu),v=tm(tb,e.__scopeMenu),h=u.useRef(null),_=(0,l.e)(n,h);return(0,eF.jsx)(nP.Provider,{scope:e.__scopeMenu,children:(0,eF.jsx)(e4.z,{present:s||d.open,children:(0,eF.jsx)(nP.Slot,{scope:e.__scopeMenu,children:(0,eF.jsx)(n5,(0,o._)((0,r._)({id:v.contentId,"aria-labelledby":v.triggerId},f),{ref:_,align:"start",side:"rtl"===p.dir?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:function(e){var n;p.isUsingKeyboardRef.current&&(null===(n=h.current)||void 0===n||n.focus()),e.preventDefault()},onCloseAutoFocus:function(e){return e.preventDefault()},onFocusOutside:(0,c.M)(e.onFocusOutside,function(e){e.target!==v.trigger&&d.onOpenChange(!1)}),onEscapeKeyDown:(0,c.M)(e.onEscapeKeyDown,function(e){p.onClose(),e.preventDefault()}),onKeyDown:(0,c.M)(e.onKeyDown,function(e){var n,t=e.currentTarget.contains(e.target),r=nD[p.dir].includes(e.key);t&&r&&(d.onOpenChange(!1),null===(n=v.trigger)||void 0===n||n.focus(),e.preventDefault())})}))})})})});function tR(e){return e?"open":"closed"}function tC(e){return"indeterminate"===e}function tD(e){return tC(e)?"indeterminate":e?"checked":"unchecked"}function tE(e){return function(n){return"mouse"===n.pointerType?e(n):void 0}}tM.displayName=tb;var tT="DropdownMenu",tP=(0,a._)((0,s.b)(tT,[nk]),2),tj=tP[0];tP[1];var tS=nk(),tN=(0,a._)(tj(tT),2),tA=tN[0],tk=tN[1],tO=function(e){var n=e.__scopeDropdownMenu,t=e.children,i=e.dir,c=e.open,l=e.defaultOpen,s=e.onOpenChange,d=e.modal,p=void 0===d||d,v=tS(n),h=u.useRef(null),_=(0,a._)((0,f.T)({prop:c,defaultProp:l,onChange:s}),2),g=_[0],m=void 0!==g&&g,y=_[1];return(0,eF.jsx)(tA,{scope:n,triggerId:(0,w.M)(),triggerRef:h,contentId:(0,w.M)(),open:m,onOpenChange:y,onOpenToggle:u.useCallback(function(){return y(function(e){return!e})},[y]),modal:p,children:(0,eF.jsx)(nH,(0,o._)((0,r._)({},v),{open:m,onOpenChange:y,dir:i,modal:p,children:t}))})};tO.displayName=tT;var tI="DropdownMenuTrigger",tF=u.forwardRef(function(e,n){var t=e.__scopeDropdownMenu,a=e.disabled,u=void 0!==a&&a,s=(0,i._)(e,["__scopeDropdownMenu","disabled"]),f=tk(tI,t),p=tS(t);return(0,eF.jsx)(nB,(0,o._)((0,r._)({asChild:!0},p),{children:(0,eF.jsx)(d.WV.button,(0,o._)((0,r._)({type:"button",id:f.triggerId,"aria-haspopup":"menu","aria-expanded":f.open,"aria-controls":f.open?f.contentId:void 0,"data-state":f.open?"open":"closed","data-disabled":u?"":void 0,disabled:u},s),{ref:(0,l.F)(n,f.triggerRef),onPointerDown:(0,c.M)(e.onPointerDown,function(e){u||0!==e.button||!1!==e.ctrlKey||(f.onOpenToggle(),f.open||e.preventDefault())}),onKeyDown:(0,c.M)(e.onKeyDown,function(e){!u&&(["Enter"," "].includes(e.key)&&f.onOpenToggle(),"ArrowDown"===e.key&&f.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(e.key)&&e.preventDefault())})}))}))});tF.displayName=tI;var tL=function(e){var n=e.__scopeDropdownMenu,t=(0,i._)(e,["__scopeDropdownMenu"]),o=tS(n);return(0,eF.jsx)(nq,(0,r._)({},o,t))};tL.displayName="DropdownMenuPortal";var tV="DropdownMenuContent",tW=u.forwardRef(function(e,n){var t=e.__scopeDropdownMenu,a=(0,i._)(e,["__scopeDropdownMenu"]),l=tk(tV,t),s=tS(t),f=u.useRef(!1);return(0,eF.jsx)(n0,(0,o._)((0,r._)({id:l.contentId,"aria-labelledby":l.triggerId},s,a),{ref:n,onCloseAutoFocus:(0,c.M)(e.onCloseAutoFocus,function(e){var n;f.current||null===(n=l.triggerRef.current)||void 0===n||n.focus(),f.current=!1,e.preventDefault()}),onInteractOutside:(0,c.M)(e.onInteractOutside,function(e){var n=e.detail.originalEvent,t=0===n.button&&!0===n.ctrlKey,r=2===n.button||t;(!l.modal||r)&&(f.current=!0)}),style:(0,r._)({},e.style,{"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"})}))});tW.displayName=tV;var tK=u.forwardRef(function(e,n){var t=e.__scopeDropdownMenu,a=(0,i._)(e,["__scopeDropdownMenu"]),u=tS(t);return(0,eF.jsx)(n6,(0,o._)((0,r._)({},u,a),{ref:n}))});tK.displayName="DropdownMenuGroup";var tz=u.forwardRef(function(e,n){var t=e.__scopeDropdownMenu,a=(0,i._)(e,["__scopeDropdownMenu"]),u=tS(t);return(0,eF.jsx)(n3,(0,o._)((0,r._)({},u,a),{ref:n}))});tz.displayName="DropdownMenuLabel";var tH=u.forwardRef(function(e,n){var t=e.__scopeDropdownMenu,a=(0,i._)(e,["__scopeDropdownMenu"]),u=tS(t);return(0,eF.jsx)(n7,(0,o._)((0,r._)({},u,a),{ref:n}))});tH.displayName="DropdownMenuItem";var tB=u.forwardRef(function(e,n){var t=e.__scopeDropdownMenu,a=(0,i._)(e,["__scopeDropdownMenu"]),u=tS(t);return(0,eF.jsx)(te,(0,o._)((0,r._)({},u,a),{ref:n}))});tB.displayName="DropdownMenuCheckboxItem";var tG=u.forwardRef(function(e,n){var t=e.__scopeDropdownMenu,a=(0,i._)(e,["__scopeDropdownMenu"]),u=tS(t);return(0,eF.jsx)(ti,(0,o._)((0,r._)({},u,a),{ref:n}))});tG.displayName="DropdownMenuRadioGroup";var tU=u.forwardRef(function(e,n){var t=e.__scopeDropdownMenu,a=(0,i._)(e,["__scopeDropdownMenu"]),u=tS(t);return(0,eF.jsx)(tu,(0,o._)((0,r._)({},u,a),{ref:n}))});tU.displayName="DropdownMenuRadioItem";var tX=u.forwardRef(function(e,n){var t=e.__scopeDropdownMenu,a=(0,i._)(e,["__scopeDropdownMenu"]),u=tS(t);return(0,eF.jsx)(td,(0,o._)((0,r._)({},u,a),{ref:n}))});tX.displayName="DropdownMenuItemIndicator";var tY=u.forwardRef(function(e,n){var t=e.__scopeDropdownMenu,a=(0,i._)(e,["__scopeDropdownMenu"]),u=tS(t);return(0,eF.jsx)(tp,(0,o._)((0,r._)({},u,a),{ref:n}))});tY.displayName="DropdownMenuSeparator",u.forwardRef(function(e,n){var t=e.__scopeDropdownMenu,a=(0,i._)(e,["__scopeDropdownMenu"]),u=tS(t);return(0,eF.jsx)(tv,(0,o._)((0,r._)({},u,a),{ref:n}))}).displayName="DropdownMenuArrow";var tq=u.forwardRef(function(e,n){var t=e.__scopeDropdownMenu,a=(0,i._)(e,["__scopeDropdownMenu"]),u=tS(t);return(0,eF.jsx)(tx,(0,o._)((0,r._)({},u,a),{ref:n}))});tq.displayName="DropdownMenuSubTrigger";var tZ=u.forwardRef(function(e,n){var t=e.__scopeDropdownMenu,a=(0,i._)(e,["__scopeDropdownMenu"]),u=tS(t);return(0,eF.jsx)(tM,(0,o._)((0,r._)({},u,a),{ref:n,style:(0,r._)({},e.style,{"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"})}))});tZ.displayName="DropdownMenuSubContent";var t$=tO,tJ=tF,tQ=tL,t0=tW,t1=tK,t2=tz,t5=tH,t6=tB,t3=tG,t8=tU,t9=tX,t7=tY,t4=function(e){var n=e.__scopeDropdownMenu,t=e.children,i=e.open,u=e.onOpenChange,c=e.defaultOpen,l=tS(n),s=(0,a._)((0,f.T)({prop:i,defaultProp:c,onChange:u}),2),d=s[0],p=s[1];return(0,eF.jsx)(tw,(0,o._)((0,r._)({},l),{open:void 0!==d&&d,onOpenChange:p,children:t}))},re=tq,rn=tZ},2690:function(e,n,t){t.d(n,{VY:function(){return eP},z$:function(){return eT},ck:function(){return eC},rU:function(){return eE},aV:function(){return eR},fC:function(){return eM},xz:function(){return eD},l_:function(){return ej}});var r=t(9026),o=t(9662),i=t(9371),a=t(8105),u=t(8182),c=t(6078),l=t(835),s=t(8339),f=t(1614),d=t(7134),p=t(2265),v=t(1677),h=t(252),_=t(1960),g=t(6941),m=t(8015),w=t(6560),y=t(1234),x=t(3464),b=t(9652),M=t(513),R=l.forwardRef((e,n)=>(0,M.jsx)(p.WV.span,{...e,ref:n,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}}));R.displayName="VisuallyHidden";var C="NavigationMenu",D=(0,u._)((0,w.B)(C),3),E=D[0],T=D[1],P=D[2],j=(0,u._)((0,w.B)(C),3),S=j[0],N=j[1],A=j[2],k=(0,u._)((0,f.b)(C,[P,A]),2),O=k[0];k[1];var I=(0,u._)(O(C),2),F=I[0],L=I[1],V=(0,u._)(O(C),2),W=V[0],K=V[1],z=l.forwardRef(function(e,n){var t=e.__scopeNavigationMenu,r=e.value,c=e.onValueChange,s=e.defaultValue,f=e.delayDuration,d=void 0===f?200:f,g=e.skipDelayDuration,m=void 0===g?300:g,w=e.orientation,y=void 0===w?"horizontal":w,x=e.dir,b=(0,a._)(e,["__scopeNavigationMenu","value","onValueChange","defaultValue","delayDuration","skipDelayDuration","orientation","dir"]),R=(0,u._)(l.useState(null),2),C=R[0],D=R[1],E=(0,h.e)(n,function(e){return D(e)}),T=(0,_.gm)(x),P=l.useRef(0),j=l.useRef(0),S=l.useRef(0),N=(0,u._)(l.useState(!0),2),A=N[0],k=N[1],O=(0,u._)((0,v.T)({prop:r,onChange:function(e){var n=m>0;""!==e?(window.clearTimeout(S.current),n&&k(!1)):(window.clearTimeout(S.current),S.current=window.setTimeout(function(){return k(!0)},m)),null==c||c(e)},defaultProp:s}),2),I=O[0],F=void 0===I?"":I,L=O[1],V=l.useCallback(function(){window.clearTimeout(j.current),j.current=window.setTimeout(function(){return L("")},150)},[L]),W=l.useCallback(function(e){window.clearTimeout(j.current),L(e)},[L]),K=l.useCallback(function(e){F===e?window.clearTimeout(j.current):P.current=window.setTimeout(function(){window.clearTimeout(j.current),L(e)},d)},[F,L,d]);return l.useEffect(function(){return function(){window.clearTimeout(P.current),window.clearTimeout(j.current),window.clearTimeout(S.current)}},[]),(0,M.jsx)(B,{scope:t,isRootMenu:!0,value:F,dir:T,orientation:y,rootNavigationMenu:C,onTriggerEnter:function(e){window.clearTimeout(P.current),A?K(e):W(e)},onTriggerLeave:function(){window.clearTimeout(P.current),V()},onContentEnter:function(){return window.clearTimeout(j.current)},onContentLeave:V,onItemSelect:function(e){L(function(n){return n===e?"":e})},onItemDismiss:function(){return L("")},children:(0,M.jsx)(p.WV.nav,(0,i._)((0,o._)({"aria-label":"Main","data-orientation":y,dir:T},b),{ref:E}))})});z.displayName=C;var H="NavigationMenuSub";l.forwardRef(function(e,n){var t=e.__scopeNavigationMenu,r=e.value,c=e.onValueChange,l=e.defaultValue,s=e.orientation,f=void 0===s?"horizontal":s,d=(0,a._)(e,["__scopeNavigationMenu","value","onValueChange","defaultValue","orientation"]),h=L(H,t),_=(0,u._)((0,v.T)({prop:r,onChange:c,defaultProp:l}),2),g=_[0],m=_[1];return(0,M.jsx)(B,{scope:t,isRootMenu:!1,value:void 0===g?"":g,dir:h.dir,orientation:f,rootNavigationMenu:h.rootNavigationMenu,onTriggerEnter:function(e){return m(e)},onItemSelect:function(e){return m(e)},onItemDismiss:function(){return m("")},children:(0,M.jsx)(p.WV.div,(0,i._)((0,o._)({"data-orientation":f},d),{ref:n}))})}).displayName=H;var B=function(e){var n=e.scope,t=e.isRootMenu,r=e.rootNavigationMenu,o=e.dir,i=e.orientation,a=e.children,c=e.value,s=e.onItemSelect,f=e.onItemDismiss,d=e.onTriggerEnter,p=e.onTriggerLeave,v=e.onContentEnter,h=e.onContentLeave,_=(0,u._)(l.useState(null),2),g=_[0],w=_[1],y=(0,u._)(l.useState(new Map),2),x=y[0],R=y[1],C=(0,u._)(l.useState(null),2),D=C[0],T=C[1];return(0,M.jsx)(F,{scope:n,isRootMenu:t,rootNavigationMenu:r,value:c,previousValue:function(e){let n=l.useRef({value:e,previous:e});return l.useMemo(()=>(n.current.value!==e&&(n.current.previous=n.current.value,n.current.value=e),n.current.previous),[e])}(c),baseId:(0,m.M)(),dir:o,orientation:i,viewport:g,onViewportChange:w,indicatorTrack:D,onIndicatorTrackChange:T,onTriggerEnter:(0,b.W)(d),onTriggerLeave:(0,b.W)(p),onContentEnter:(0,b.W)(v),onContentLeave:(0,b.W)(h),onItemSelect:(0,b.W)(s),onItemDismiss:(0,b.W)(f),onViewportContentChange:l.useCallback(function(e,n){R(function(t){return t.set(e,n),new Map(t)})},[]),onViewportContentRemove:l.useCallback(function(e){R(function(n){return n.has(e)?(n.delete(e),new Map(n)):n})},[]),children:(0,M.jsx)(E.Provider,{scope:n,children:(0,M.jsx)(W,{scope:n,items:x,children:a})})})},G="NavigationMenuList",U=l.forwardRef(function(e,n){var t=e.__scopeNavigationMenu,r=(0,a._)(e,["__scopeNavigationMenu"]),u=L(G,t),c=(0,M.jsx)(p.WV.ul,(0,i._)((0,o._)({"data-orientation":u.orientation},r),{ref:n}));return(0,M.jsx)(p.WV.div,{style:{position:"relative"},ref:u.onIndicatorTrackChange,children:(0,M.jsx)(E.Slot,{scope:t,children:u.isRootMenu?(0,M.jsx)(ep,{asChild:!0,children:c}):c})})});U.displayName=G;var X="NavigationMenuItem",Y=(0,u._)(O(X),2),q=Y[0],Z=Y[1],$=l.forwardRef(function(e,n){var t=e.__scopeNavigationMenu,r=e.value,u=(0,a._)(e,["__scopeNavigationMenu","value"]),c=(0,m.M)(),s=l.useRef(null),f=l.useRef(null),d=l.useRef(null),v=l.useRef(function(){}),h=l.useRef(!1),_=l.useCallback(function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"start";if(s.current){v.current();var n=e_(s.current);n.length&&eg("start"===e?n:n.reverse())}},[]),g=l.useCallback(function(){if(s.current){var e=e_(s.current);e.length&&(v.current=(e.forEach(function(e){e.dataset.tabindex=e.getAttribute("tabindex")||"",e.setAttribute("tabindex","-1")}),function(){e.forEach(function(e){var n=e.dataset.tabindex;e.setAttribute("tabindex",n)})}))}},[]);return(0,M.jsx)(q,{scope:t,value:r||c||"LEGACY_REACT_AUTO_VALUE",triggerRef:f,contentRef:s,focusProxyRef:d,wasEscapeCloseRef:h,onEntryKeyDown:_,onFocusProxyEnter:_,onRootContentClose:g,onContentFocusOutside:g,children:(0,M.jsx)(p.WV.li,(0,i._)((0,o._)({},u),{ref:n}))})});$.displayName=X;var J="NavigationMenuTrigger",Q=l.forwardRef(function(e,n){var t=e.__scopeNavigationMenu,r=e.disabled,u=(0,a._)(e,["__scopeNavigationMenu","disabled"]),c=L(J,e.__scopeNavigationMenu),s=Z(J,e.__scopeNavigationMenu),f=l.useRef(null),v=(0,h.e)(f,s.triggerRef,n),_=ey(c.baseId,s.value),g=ex(c.baseId,s.value),m=l.useRef(!1),w=l.useRef(!1),y=s.value===c.value;return(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(E.ItemSlot,{scope:t,value:s.value,children:(0,M.jsx)(eh,{asChild:!0,children:(0,M.jsx)(p.WV.button,(0,i._)((0,o._)({id:_,disabled:r,"data-disabled":r?"":void 0,"data-state":ew(y),"aria-expanded":y,"aria-controls":g},u),{ref:v,onPointerEnter:(0,d.M)(e.onPointerEnter,function(){w.current=!1,s.wasEscapeCloseRef.current=!1}),onPointerMove:(0,d.M)(e.onPointerMove,eb(function(){r||w.current||s.wasEscapeCloseRef.current||m.current||(c.onTriggerEnter(s.value),m.current=!0)})),onPointerLeave:(0,d.M)(e.onPointerLeave,eb(function(){r||(c.onTriggerLeave(),m.current=!1)})),onClick:(0,d.M)(e.onClick,function(){c.onItemSelect(s.value),w.current=y}),onKeyDown:(0,d.M)(e.onKeyDown,function(e){var n={horizontal:"ArrowDown",vertical:"rtl"===c.dir?"ArrowLeft":"ArrowRight"}[c.orientation];y&&e.key===n&&(s.onEntryKeyDown(),e.preventDefault())})}))})}),y&&(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(R,{"aria-hidden":!0,tabIndex:0,ref:s.focusProxyRef,onFocus:function(e){var n=s.contentRef.current,t=e.relatedTarget,r=t===f.current,o=null==n?void 0:n.contains(t);(r||!o)&&s.onFocusProxyEnter(r?"start":"end")}}),c.viewport&&(0,M.jsx)("span",{"aria-owns":g})]})]})});Q.displayName=J;var ee="navigationMenu.linkSelect",en=l.forwardRef(function(e,n){e.__scopeNavigationMenu;var t=e.active,r=e.onSelect,u=(0,a._)(e,["__scopeNavigationMenu","active","onSelect"]);return(0,M.jsx)(eh,{asChild:!0,children:(0,M.jsx)(p.WV.a,(0,i._)((0,o._)({"data-active":t?"":void 0,"aria-current":t?"page":void 0},u),{ref:n,onClick:(0,d.M)(e.onClick,function(e){var n=e.target,t=new CustomEvent(ee,{bubbles:!0,cancelable:!0});if(n.addEventListener(ee,function(e){return null==r?void 0:r(e)},{once:!0}),(0,p.jH)(n,t),!t.defaultPrevented&&!e.metaKey){var o=new CustomEvent(ec,{bubbles:!0,cancelable:!0});(0,p.jH)(n,o)}},{checkForDefaultPrevented:!1})}))})});en.displayName="NavigationMenuLink";var et="NavigationMenuIndicator",er=l.forwardRef(function(e,n){var t=e.forceMount,r=(0,a._)(e,["forceMount"]),u=L(et,e.__scopeNavigationMenu),c=!!u.value;return u.indicatorTrack?s.createPortal((0,M.jsx)(g.z,{present:t||c,children:(0,M.jsx)(eo,(0,i._)((0,o._)({},r),{ref:n}))}),u.indicatorTrack):null});er.displayName=et;var eo=l.forwardRef(function(e,n){var t=e.__scopeNavigationMenu,r=(0,a._)(e,["__scopeNavigationMenu"]),c=L(et,t),s=T(t),f=(0,u._)(l.useState(null),2),d=f[0],v=f[1],h=(0,u._)(l.useState(null),2),_=h[0],g=h[1],m="horizontal"===c.orientation,w=!!c.value;l.useEffect(function(){var e,n=null===(e=s().find(function(e){return e.value===c.value}))||void 0===e?void 0:e.ref.current;n&&v(n)},[s,c.value]);var y=function(){d&&g({size:m?d.offsetWidth:d.offsetHeight,offset:m?d.offsetLeft:d.offsetTop})};return em(d,y),em(c.indicatorTrack,y),_?(0,M.jsx)(p.WV.div,(0,i._)((0,o._)({"aria-hidden":!0,"data-state":w?"visible":"hidden","data-orientation":c.orientation},r),{ref:n,style:(0,o._)({position:"absolute"},m?{left:0,width:_.size+"px",transform:"translateX(".concat(_.offset,"px)")}:{top:0,height:_.size+"px",transform:"translateY(".concat(_.offset,"px)")},r.style)})):null}),ei="NavigationMenuContent",ea=l.forwardRef(function(e,n){var t=e.forceMount,r=(0,a._)(e,["forceMount"]),u=L(ei,e.__scopeNavigationMenu),c=Z(ei,e.__scopeNavigationMenu),l=(0,h.e)(c.contentRef,n),s=c.value===u.value,f=(0,o._)({value:c.value,triggerRef:c.triggerRef,focusProxyRef:c.focusProxyRef,wasEscapeCloseRef:c.wasEscapeCloseRef,onContentFocusOutside:c.onContentFocusOutside,onRootContentClose:c.onRootContentClose},r);return u.viewport?(0,M.jsx)(eu,(0,i._)((0,o._)({forceMount:t},f),{ref:l})):(0,M.jsx)(g.z,{present:t||s,children:(0,M.jsx)(el,(0,i._)((0,o._)({"data-state":ew(s)},f),{ref:l,onPointerEnter:(0,d.M)(e.onPointerEnter,u.onContentEnter),onPointerLeave:(0,d.M)(e.onPointerLeave,eb(u.onContentLeave)),style:(0,o._)({pointerEvents:!s&&u.isRootMenu?"none":void 0},f.style)}))})});ea.displayName=ei;var eu=l.forwardRef(function(e,n){var t=L(ei,e.__scopeNavigationMenu),r=t.onViewportContentChange,i=t.onViewportContentRemove;return(0,x.b)(function(){r(e.value,(0,o._)({ref:n},e))},[e,n,r]),(0,x.b)(function(){return function(){return i(e.value)}},[e.value,i]),null}),ec="navigationMenu.rootContentDismiss",el=l.forwardRef(function(e,n){var t=e.__scopeNavigationMenu,r=e.value,u=e.triggerRef,c=e.focusProxyRef,s=e.wasEscapeCloseRef,f=e.onRootContentClose,p=e.onContentFocusOutside,v=(0,a._)(e,["__scopeNavigationMenu","value","triggerRef","focusProxyRef","wasEscapeCloseRef","onRootContentClose","onContentFocusOutside"]),_=L(ei,t),g=l.useRef(null),m=(0,h.e)(g,n),w=ey(_.baseId,r),x=ex(_.baseId,r),b=T(t),R=l.useRef(null),C=_.onItemDismiss;l.useEffect(function(){var e=g.current;if(_.isRootMenu&&e){var n=function(){var n;C(),f(),e.contains(document.activeElement)&&(null===(n=u.current)||void 0===n||n.focus())};return e.addEventListener(ec,n),function(){return e.removeEventListener(ec,n)}}},[_.isRootMenu,e.value,u,C,f]);var D=l.useMemo(function(){var e=b().map(function(e){return e.value});"rtl"===_.dir&&e.reverse();var n=e.indexOf(_.value),t=e.indexOf(_.previousValue),o=r===_.value,i=t===e.indexOf(r);if(!o&&!i)return R.current;var a=function(){if(n!==t){if(o&&-1!==t)return n>t?"from-end":"from-start";if(i&&-1!==n)return n>t?"to-start":"to-end"}return null}();return R.current=a,a},[_.previousValue,_.value,_.dir,b,r]);return(0,M.jsx)(ep,{asChild:!0,children:(0,M.jsx)(y.XB,(0,i._)((0,o._)({id:x,"aria-labelledby":w,"data-motion":D,"data-orientation":_.orientation},v),{ref:m,disableOutsidePointerEvents:!1,onDismiss:function(){var e,n=new Event(ec,{bubbles:!0,cancelable:!0});null===(e=g.current)||void 0===e||e.dispatchEvent(n)},onFocusOutside:(0,d.M)(e.onFocusOutside,function(e){p();var n,t=e.target;(null===(n=_.rootNavigationMenu)||void 0===n?void 0:n.contains(t))&&e.preventDefault()}),onPointerDownOutside:(0,d.M)(e.onPointerDownOutside,function(e){var n,t=e.target,r=b().some(function(e){var n;return null===(n=e.ref.current)||void 0===n?void 0:n.contains(t)}),o=_.isRootMenu&&(null===(n=_.viewport)||void 0===n?void 0:n.contains(t));(r||o||!_.isRootMenu)&&e.preventDefault()}),onKeyDown:(0,d.M)(e.onKeyDown,function(e){var n=e.altKey||e.ctrlKey||e.metaKey;if("Tab"===e.key&&!n){var t,r=e_(e.currentTarget),o=document.activeElement,i=r.findIndex(function(e){return e===o});eg(e.shiftKey?r.slice(0,i).reverse():r.slice(i+1,r.length))?e.preventDefault():null===(t=c.current)||void 0===t||t.focus()}}),onEscapeKeyDown:(0,d.M)(e.onEscapeKeyDown,function(e){s.current=!0})}))})}),es="NavigationMenuViewport",ef=l.forwardRef(function(e,n){var t=e.forceMount,r=(0,a._)(e,["forceMount"]),u=!!L(es,e.__scopeNavigationMenu).value;return(0,M.jsx)(g.z,{present:t||u,children:(0,M.jsx)(ed,(0,i._)((0,o._)({},r),{ref:n}))})});ef.displayName=es;var ed=l.forwardRef(function(e,n){var t,c=e.__scopeNavigationMenu,s=(e.children,(0,a._)(e,["__scopeNavigationMenu","children"])),f=L(es,c),v=(0,h.e)(n,f.onViewportChange),_=K(ei,e.__scopeNavigationMenu),m=(0,u._)(l.useState(null),2),w=m[0],y=m[1],x=(0,u._)(l.useState(null),2),b=x[0],R=x[1],C=w?(null==w?void 0:w.width)+"px":void 0,D=w?(null==w?void 0:w.height)+"px":void 0,E=!!f.value,T=E?f.value:f.previousValue;return em(b,function(){b&&y({width:b.offsetWidth,height:b.offsetHeight})}),(0,M.jsx)(p.WV.div,(0,i._)((0,o._)({"data-state":ew(E),"data-orientation":f.orientation},s),{ref:v,style:(0,o._)((t={pointerEvents:!E&&f.isRootMenu?"none":void 0},(0,r._)(t,"--radix-navigation-menu-viewport-width",C),(0,r._)(t,"--radix-navigation-menu-viewport-height",D),t),s.style),onPointerEnter:(0,d.M)(e.onPointerEnter,f.onContentEnter),onPointerLeave:(0,d.M)(e.onPointerLeave,eb(f.onContentLeave)),children:Array.from(_.items).map(function(e){var n=(0,u._)(e,2),t=n[0],r=n[1],c=r.ref,l=r.forceMount,s=(0,a._)(e[1],["ref","forceMount"]),f=T===t;return(0,M.jsx)(g.z,{present:l||f,children:(0,M.jsx)(el,(0,i._)((0,o._)({},s),{ref:(0,h.F)(c,function(e){f&&e&&R(e)})}))},t)})}))}),ep=l.forwardRef(function(e,n){var t=e.__scopeNavigationMenu,r=(0,a._)(e,["__scopeNavigationMenu"]),u=L("FocusGroup",t);return(0,M.jsx)(S.Provider,{scope:t,children:(0,M.jsx)(S.Slot,{scope:t,children:(0,M.jsx)(p.WV.div,(0,i._)((0,o._)({dir:u.dir},r),{ref:n}))})})}),ev=["ArrowRight","ArrowLeft","ArrowUp","ArrowDown"],eh=l.forwardRef(function(e,n){var t=e.__scopeNavigationMenu,r=(0,a._)(e,["__scopeNavigationMenu"]),u=N(t),l=L("FocusGroupItem",t);return(0,M.jsx)(S.ItemSlot,{scope:t,children:(0,M.jsx)(p.WV.button,(0,i._)((0,o._)({},r),{ref:n,onKeyDown:(0,d.M)(e.onKeyDown,function(e){if(["Home","End"].concat((0,c._)(ev)).includes(e.key)){var n=u().map(function(e){return e.ref.current});if(["rtl"===l.dir?"ArrowRight":"ArrowLeft","ArrowUp","End"].includes(e.key)&&n.reverse(),ev.includes(e.key)){var t=n.indexOf(e.currentTarget);n=n.slice(t+1)}setTimeout(function(){return eg(n)}),e.preventDefault()}})}))})});function e_(e){for(var n=[],t=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:function(e){var n="INPUT"===e.tagName&&"hidden"===e.type;return e.disabled||e.hidden||n?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});t.nextNode();)n.push(t.currentNode);return n}function eg(e){var n=document.activeElement;return e.some(function(e){return e===n||(e.focus(),document.activeElement!==n)})}function em(e,n){var t=(0,b.W)(n);(0,x.b)(function(){var n=0;if(e){var r=new ResizeObserver(function(){cancelAnimationFrame(n),n=window.requestAnimationFrame(t)});return r.observe(e),function(){window.cancelAnimationFrame(n),r.unobserve(e)}}},[e,t])}function ew(e){return e?"open":"closed"}function ey(e,n){return"".concat(e,"-trigger-").concat(n)}function ex(e,n){return"".concat(e,"-content-").concat(n)}function eb(e){return function(n){return"mouse"===n.pointerType?e(n):void 0}}var eM=z,eR=U,eC=$,eD=Q,eE=en,eT=er,eP=ea,ej=ef}}]);