1import{r as e}from"./rolldown-runtime-QTnfLwEv.js";import{a as t,i as n,r}from"./bundle-mjs-DEz-Sy5m.js";import{a as i,i as a,o,r as s}from"./button-Bi0ogapc.js";import{a as c,i as l,n as u}from"./textarea-CYuQ2NZG.js";import{i as d,r as f}from"./label-Cmy49GLr.js";var p=o(`check`,[[`path`,{d:`M20 6 9 17l-5-5`,key:`1gmf2c`}]]),m=o(`chevron-down`,[[`path`,{d:`m6 9 6 6 6-6`,key:`qrunsl`}]]),h=o(`chevron-up`,[[`path`,{d:`m18 15-6-6-6 6`,key:`153udz`}]]),g=e(t(),1),_=e(n(),1),v=Object.defineProperty,y=(e,t)=>v(e,`name`,{value:t,configurable:!0}),b=!!(typeof window<`u`&&window.document&&window.document.createElement);function x(e,t,{checkForDefaultPrevented:n=!0}={}){return y(function(r){if(e?.(r),n===!1||!r||!r.defaultPrevented)return t?.(r)},`handleEvent`)}y(x,`composeEventHandlers`);function S(e){if(!b)throw Error(`Cannot access window outside of the DOM`);return e?.ownerDocument?.defaultView??window}y(S,`getOwnerWindow`);function C(e){if(!b)throw Error(`Cannot access document outside of the DOM`);return e?.ownerDocument??document}y(C,`getOwnerDocument`);function w(e,t=!1){let{activeElement:n}=C(e);if(!n?.nodeName)return null;if(T(n)&&n.contentDocument)return w(n.contentDocument.body,t);if(t){let e=n.getAttribute(`aria-activedescendant`);if(e){let t=C(n).getElementById(e);if(t)return t}}return n}y(w,`getActiveElement`);function T(e){return e.tagName===`IFRAME`}y(T,`isFrame`);var E=r(),D=Object.defineProperty,O=(e,t)=>D(e,`name`,{value:t,configurable:!0});function k(e,t){let n=g.createContext(t);n.displayName=e+`Context`;let r=O(e=>{let{children:t,...r}=e,i=g.useMemo(()=>r,Object.values(r));return(0,E.jsx)(n.Provider,{value:i,children:t})},`Provider`);r.displayName=e+`Provider`;function i(r,i={}){let{optional:a=!1}=i,o=g.useContext(n);if(o)return o;if(t!==void 0)return t;if(!a)throw Error(`\`${r}\` must be used within \`${e}\``)}return O(i,`useContext`),[r,i]}O(k,`createContext`);function A(e,t=[]){let n=[];function r(t,r){let i=g.createContext(r);i.displayName=t+`Context`;let a=n.length;n=[...n,r];let o=O(t=>{let{scope:n,children:r,...o}=t,s=n?.[e]?.[a]||i,c=g.useMemo(()=>o,Object.values(o));return(0,E.jsx)(s.Provider,{value:c,children:r})},`Provider`);o.displayName=t+`Provider`;function s(n,o,s={}){let{optional:c=!1}=s,l=o?.[e]?.[a]||i,u=g.useContext(l);if(u)return u;if(r!==void 0)return r;if(!c)throw Error(`\`${n}\` must be used within \`${t}\``)}return O(s,`useContext`),[o,s]}O(r,`createContext`);let i=O(()=>{let t=n.map(e=>g.createContext(e));return O(function(n){let r=n?.[e]||t;return g.useMemo(()=>({[`__scope${e}`]:{...n,[e]:r}}),[n,r])},`useScope`)},`createScope`);return i.scopeName=e,[r,j(i,...t)]}O(A,`createContextScope`);function j(...e){let t=e[0];if(e.length===1)return t;let n=O(()=>{let n=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return O(function(e){let r=n.reduce((t,{useScope:n,scopeName:r})=>{let i=n(e)[`__scope${r}`];return{...t,...i}},{});return g.useMemo(()=>({[`__scope${t.scopeName}`]:r}),[r])},`useComposedScopes`)},`createScope`);return n.scopeName=t.scopeName,n}O(j,`composeContextScopes`);var M=Object.defineProperty,N=(e,t)=>M(e,`name`,{value:t,configurable:!0});function P(e){let t=g.useRef(e);return g.useEffect(()=>{t.current=e}),g.useMemo(()=>((...e)=>t.current?.(...e)),[])}N(P,`useCallbackRef`);var ee=Object.defineProperty,F=(e,t)=>ee(e,`name`,{value:t,configurable:!0}),I=`dismissableLayer.update`,L=`dismissableLayer.pointerDownOutside`,R=`dismissableLayer.focusOutside`,te,ne=g.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set,dismissableSurfaces:new Set}),re=g.forwardRef(F(function(e,t){let{disableOutsidePointerEvents:n=!1,deferPointerDownOutside:r=!1,onEscapeKeyDown:i,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:c,onDismiss:l,...u}=e,d=g.useContext(ne),[p,m]=g.useState(null),h=p?.ownerDocument??globalThis?.document,[,_]=g.useState({}),v=a(t,m),y=Array.from(d.layers),[b]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),S=b?y.indexOf(b):-1,C=p?y.indexOf(p):-1,w=d.layersWithOutsidePointerEventsDisabled.size>0,T=C>=S,D=g.useRef(!1),O=oe(e=>{o?.(e),c?.(e),e.defaultPrevented||l?.()},{ownerDocument:h,deferPointerDownOutside:r,isDeferredPointerDownOutsideRef:D,dismissableSurfaces:d.dismissableSurfaces,shouldHandlePointerDownOutside:g.useCallback(e=>{if(!(e instanceof Node))return!1;let t=[...d.branches].some(t=>t.contains(e));return T&&!t},[d.branches,T])}),k=se(e=>{if(r&&D.current)return;let t=e.target;[...d.branches].some(e=>e.contains(t))||(s?.(e),c?.(e),e.defaultPrevented||l?.())},h),A=p?C===y.length-1:!1,j=P(e=>{e.key===`Escape`&&(i?.(e),!e.defaultPrevented&&l&&(e.preventDefault(),l()))});return g.useEffect(()=>
1{if(A)return h.addEventListener(`keydown`,j,{capture:!0}),()=>h.removeEventListener(`keydown`,j,{capture:!0})},[h,A,j]),g.useEffect(()=>{if(p)return n&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(te=h.body.style.pointerEvents,h.body.style.pointerEvents=`none`),d.layersWithOutsidePointerEventsDisabled.add(p)),d.layers.add(p),ce(),()=>{n&&(d.layersWithOutsidePointerEventsDisabled.delete(p),d.layersWithOutsidePointerEventsDisabled.size===0&&(h.body.style.pointerEvents=te))}},[p,h,n,d]),g.useEffect(()=>()=>{p&&(d.layers.delete(p),d.layersWithOutsidePointerEventsDisabled.delete(p),ce())},[p,d]),g.useEffect(()=>{let e=F(()=>_({}),`handleUpdate`);return document.addEventListener(I,e),()=>document.removeEventListener(I,e)},[]),(0,E.jsx)(f.div,{...u,ref:v,style:{pointerEvents:w?T?`auto`:`none`:void 0,...e.style},onFocusCapture:x(e.onFocusCapture,k.onFocusCapture),onBlurCapture:x(e.onBlurCapture,k.onBlurCapture),onPointerDownCapture:x(e.onPointerDownCapture,O.onPointerDownCapture)})},`DismissableLayer`));function ie(){let e=g.useContext(ne),[t,n]=g.useState(null);return g.useEffect(()=>{if(t)return e.dismissableSurfaces.add(t),()=>{e.dismissableSurfaces.delete(t)}},[t,e.dismissableSurfaces]),n}F(ie,`useDismissableLayerSurface`);var ae=F(()=>!0,`IS_TRUE`);function oe(e,t){let{ownerDocument:n=globalThis?.document,deferPointerDownOutside:r=!1,isDeferredPointerDownOutsideRef:i,dismissableSurfaces:a,shouldHandlePointerDownOutside:o=ae}=t,s=P(e),c=g.useRef(!1),l=g.useRef(!1),u=g.useRef(new Map),d=g.useRef(()=>{});return g.useEffect(()=>{function e(){l.current=!1,i.current=!1,u.current.clear()}F(e,`resetOutsideInteraction`);function t(){return Array.from(u.current.values()).some(Boolean)}F(t,`isOutsideInteractionIntercepted`);function f(e){if(!l.current)return;let t=e.target;t instanceof Node&&[...a].some(e=>e.contains(t))||u.current.set(e.type,!0),e.type===`click`&&window.setTimeout(()=>{l.current&&d.current()},0)}F(f,`handleInteractionCapture`);function p(e){l.current&&u.current.set(e.type,!1)}F(p,`handleInteractionBubble`);let m=F(a=>{if(a.target&&!c.current){let f=function(){n.removeEventListener(`click`,d.current);let r=t();e(),r||le(L,s,p,{discrete:!0})};if(F(f,`handleAndDispatchPointerDownOutsideEvent`),!o(a.target)){n.removeEventListener(`click`,d.current),e(),c.current=!1;return}let p={originalEvent:a};l.current=!0,i.current=r&&a.button===0,u.current.clear(),!r||a.button!==0?f():(n.removeEventListener(`click`,d.current),d.current=f,n.addEventListener(`click`,d.current,{once:!0}))}else n.removeEventListener(`click`,d.current),e();c.current=!1},`handlePointerDown`),h=[`pointerup`,`mousedown`,`mouseup`,`touchstart`,`touchend`,`click`];for(let e of h)n.addEventListener(e,f,!0),n.addEventListener(e,p);let g=window.setTimeout(()=>{n.addEventListener(`pointerdown`,m)},0);return()=>{window.clearTimeout(g),n.removeEventListener(`pointerdown`,m),n.removeEventListener(`click`,d.current);for(let e of h)n.removeEventListener(e,f,!0),n.removeEventListener(e,p)}},[n,s,r,i,a,o]),{onPointerDownCapture:F(()=>c.current=!0,`onPointerDownCapture`)}}F(oe,`usePointerDownOutside`);function se(e,t=globalThis?.document){let n=P(e),r=g.useRef(!1);return g.useEffect(()=>{let e=F(e=>{e.target&&!r.current&&le(R,n,{originalEvent:e},{discrete:!1})},`handleFocus`);return t.addEventListener(`focusin`,e),()=>t.removeEventListener(`focusin`,e)},[t,n]),{onFocusCapture:F(()=>r.current=!0,`onFocusCapture`),onBlurCapture:F(()=>r.current=!1,`onBlurCapture`)}}F(se,`useFocusOutside`);function ce(){let e=new CustomEvent(I);document.dispatchEvent(e)}F(ce,`dispatchUpdate`);function le(e,t,n,{discrete:r}){let i=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?d(i,a):i.dispatchEvent(a)}F(le,`handleAndDispatchCustomEvent`);var z=globalThis?.document?g.useLayoutEffect:()=>{},ue=Object.defineProperty,de=(e,t)=>ue(e,`name`,{value:t,configurable:!0}),fe=g.useId||(()=>void 0),pe=0;function me(e){let[t,n]=g.useState(fe());return z(()=>{e||n(e=>e??String(pe++))},[e]),e||(t?`radix-${t}`:``)}de(me,`useId`);var he=[`top`,`right`,`bottom`,`left`],ge=Math.min,B=Math.max,_e=Math.round,ve=Math.floor,V=e=>({x:e,y:e}),ye={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function be(e,t,n){return B(e,ge(t,n))}function H(e,t){return typeof e==`function`?e(t):e}function xe(e){return e.split(`-`)[0]}function Se(e){return e.split(`-`)[1]}function Ce(e){return e===`x`?`y`:`x`}function we(e){return e===`y`?`height`:`width`}function U(e){let t=e[0];return t===`t`||t===`b`?`y`:`x`}function Te(e){return Ce(U(e))}function Ee(e,t,n){n===void 0&&(n=!1);
vendor: 5,014 bytes, line 1
1let r=Se(e),i=Te(e),a=we(i),o=i===`x`?r===(n?`end`:`start`)?`right`:`left`:r===`start`?`bottom`:`top`;return t.reference[a]>t.floating[a]&&(o=Fe(o)),[o,Fe(o)]}function De(e){let t=Fe(e);return[Oe(e),t,Oe(t)]}function Oe(e){return e.includes(`start`)?e.replace(`start`,`end`):e.replace(`end`,`start`)}var ke=[`left`,`right`],Ae=[`right`,`left`],je=[`top`,`bottom`],Me=[`bottom`,`top`];function Ne(e,t,n){switch(e){case`top`:case`bottom`:return n?t?Ae:ke:t?ke:Ae;case`left`:case`right`:return t?je:Me;default:return[]}}function Pe(e,t,n,r){let i=Se(e),a=Ne(xe(e),n===`start`,r);return i&&(a=a.map(e=>e+`-`+i),t&&(a=a.concat(a.map(Oe)))),a}function Fe(e){let t=xe(e);return ye[t]+e.slice(t.length)}function Ie(e){return{top:e.top??0,right:e.right??0,bottom:e.bottom??0,left:e.left??0}}function Le(e){return typeof e==`number`?{top:e,right:e,bottom:e,left:e}:Ie(e)}function Re(e){let{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function ze(e,t,n){let{reference:r,floating:i}=e,a=U(t),o=Te(t),s=we(o),c=xe(t),l=a===`y`,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2,p;switch(c){case`top`:p={x:u,y:r.y-i.height};break;case`bottom`:p={x:u,y:r.y+r.height};break;case`right`:p={x:r.x+r.width,y:d};break;case`left`:p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}let m=Se(t);return m&&(p[o]+=f*(m===`end`?1:-1)*(n&&l?-1:1)),p}async function Be(e,t){t===void 0&&(t={});let{x:n,y:r,platform:i,rects:a,elements:o,strategy:s}=e,{boundary:c=`clippingAncestors`,rootBoundary:l=`viewport`,elementContext:u=`floating`,altBoundary:d=!1,padding:f=0}=H(t,e),p=Le(f),m=o[d?u===`floating`?`reference`:`floating`:u],h=Re(await i.getClippingRect({element:await(i.isElement==null?void 0:i.isElement(m))??!0?m:m.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(o.floating)),boundary:c,rootBoundary:l,strategy:s})),g=u===`floating`?{x:n,y:r,width:a.floating.width,height:a.floating.height}:a.reference,_=await(i.getOffsetParent==null?void 0:i.getOffsetParent(o.floating)),v=await(i.isElement==null?void 0:i.isElement(_))&&await(i.getScale==null?void 0:i.getScale(_))||{x:1,y:1},y=Re(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:o,rect:g,offsetParent:_,strategy:s}):g);return{top:(h.top-y.top+p.top)/v.y,bottom:(y.bottom-h.bottom+p.bottom)/v.y,left:(h.left-y.left+p.left)/v.x,right:(y.right-h.right+p.right)/v.x}}var Ve=50,He=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:Be},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=ze(l,r,c),f=r,p=0,m={};for(let n=0;n<a.length;n++){let h=a[n];if(!h)continue;let{name:g,fn:_}=h,{x:v,y,data:b,reset:x}=await _({x:u,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:m,rects:l,platform:s,elements:{reference:e,floating:t}});u=v??u,d=y??d,m[g]={...m[g],...b},x&&p<Ve&&(p++,typeof x==`object`&&(x.placement&&(f=x.placement),x.rects&&(l=x.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):x.rects),{x:u,y:d}=ze(l,f,c)),n=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:m}},Ue=e=>({name:`arrow`,options:e,async fn(t){let{x:n,y:r,placement:i,rects:a,platform:o,elements:s,middlewareData:c}=t,{element:l,padding:u=0}=H(e,t)||{};if(l==null)return{};let d=Le(u),f={x:n,y:r},p=Te(i),m=we(p),h=await o.getDimensions(l),g=p===`y`,_=g?`top`:`left`,v=g?`bottom`:`right`,y=g?`clientHeight`:`clientWidth`,b=a.reference[m]+a.reference[p]-f[p]-a.floating[m],x=f[p]-a.reference[p],S=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l)),C=S?S[y]:0;(!C||!await(o.isElement==null?void 0:o.isElement(S)))&&(C=s.floating[y]||a.floating[m]);let w=b/2-x/2,T=C/2-h[m]/2-1,E=ge(d[_],T),D=ge(d[v],T),O=C-h[m]-D,k=C/2-h[m]/2+w,A=be(E,k,O),j=!c.arrow&&Se(i)!=null&&k!==A&&a.reference[m]/2-(k<E?E:D)-h[m]/2<0,M=j?k<E?k-E:k-O:0;return{[p]:f[p]+M,data:{[p]:A,centerOffset:k-A-M,...j&&{alignmentOffset:M}},reset:j}}}),We=function(e){return e===void 0&&(e={}),{name:`flip`,options:e,async fn(t){var n;let{placement:r,middlewareData:i,rects:a,initialPlacement:o,platform:s,elements:c}=t,{mainAxis:l=!0,crossAxis:u=!0,fallbackPlacements:d,fallbackStrategy:f=`bestFit`,fallbackAxisSideDirection:p=`none`,flipAlignment:m=!0,...h}=H(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};let g=xe(r),_=U(o),v=xe(o)===o,y=await(s.isRTL==null?void 0:s.isRTL(c.floating)),b=d||(v||!m?[Fe(o)]:De(o)),x=p!==`none`;!d&&x&&b.push(...Pe(o,m,p,y));let S=[o,...b],C=await s.detectOverflow(t,h),w=[],T=i.flip?.overflows||[];if(l&&w.push(C[g]),u){let e=Ee(r,a,y);w.push(C[e[0]],C[e[1]])}if(T=[...T,{placement:r,overflows:w}],!w.every(e=>e<=0)){let e=(i.flip?.index||0)+1,t=S[e];if(t&&(u!==`alignment`||_===U(t)||T.every(e=>U(e.placement)!==_||e.overflows[0]>0)))return{data:{index:e,overflows:T},reset:{placement:t}};let n=T.filter(e=>e.overflows[0]<=0).sort((e,t)=>
1e.overflows[1]-t.overflows[1])[0]?.placement;if(!n)switch(f){case`bestFit`:{let e=T.filter(e=>{if(x){let t=U(e.placement);return t===_||t===`y`}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0]?.[0];e&&(n=e);break}case`initialPlacement`:n=o;break}if(r!==n)return{reset:{placement:n}}}return{}}}};function Ge(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Ke(e){return he.some(t=>e[t]>=0)}var qe=function(e){return e===void 0&&(e={}),{name:`hide`,options:e,async fn(t){let{rects:n,platform:r}=t,{strategy:i=`referenceHidden`,...a}=H(e,t);switch(i){case`referenceHidden`:{let e=Ge(await r.detectOverflow(t,{...a,elementContext:`reference`}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:Ke(e)}}}case`escaped`:{let e=Ge(await r.detectOverflow(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:Ke(e)}}}default:return{}}}}},Je=new Set([`left`,`top`]);async function Ye(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=xe(n),s=Se(n),c=U(n)===`y`,l=Je.has(o)?-1:1,u=a&&c?-1:1,d=H(t,e),{mainAxis:f,crossAxis:p,alignmentAxis:m}=typeof d==`number`?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof m==`number`&&(p=s===`end`?m*-1:m),c?{x:p*u,y:f*l}:{x:f*l,y:p*u}}var Xe=function(e){return e===void 0&&(e=0),{name:`offset`,options:e,async fn(t){var n;let{x:r,y:i,placement:a,middlewareData:o}=t,s=await Ye(t,e);return a===o.offset?.placement&&(n=o.arrow)!=null&&n.alignmentOffset?{}:{x:r+s.x,y:i+s.y,data:{...s,placement:a}}}}},Ze=function(e){return e===void 0&&(e={}),{name:`shift`,options:e,async fn(t){let{x:n,y:r,placement:i,platform:a}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:c={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=H(e,t),u={x:n,y:r},d=await a.detectOverflow(t,l),f=U(i),p=Ce(f),m=u[p],h=u[f],g=(e,t)=>be(t+d[e===`y`?`top`:`left`],t,t-d[e===`y`?`bottom`:`right`]);o&&(m=g(p,m)),s&&(h=g(f,h));let _=c.fn({...t,[p]:m,[f]:h});return{..._,data:{x:_.x-n,y:_.y-r,enabled:{[p]:o,[f]:s}}}}}},Qe=function(e){return e===void 0&&(e={}),{options:e,fn(t){let{x:n,y:r,placement:i,rects:a,middlewareData:o}=t,{offset:s=0,mainAxis:c=!0,crossAxis:l=!0}=H(e,t),u={x:n,y:r},d=U(i),f=Ce(d),p=u[f],m=u[d],h=H(s,t),g=typeof h==`number`?{mainAxis:h,crossAxis:0}:{mainAxis:h.mainAxis??0,crossAxis:h.crossAxis??0};if(c){let e=f===`y`?`height`:`width`,t=a.reference[f]-a.floating[e]+g.mainAxis,n=a.reference[f]+a.reference[e]-g.mainAxis;p<t?p=t:p>n&&(p=n)}if(l){let e=f===`y`?`width`:`height`,t=Je.has(xe(i)),n=a.reference[d]-a.floating[e]+(t&&o.offset?.[d]||0)+(t?0:g.crossAxis),r=a.reference[d]+a.reference[e]+(t?0:o.offset?.[d]||0)-(t?g.crossAxis:0);m<n?m=n:m>r&&(m=r)}return{[f]:p,[d]:m}}}},$e=function(e){return e===void 0&&(e={}),{name:`size`,options:e,async fn(t){let{placement:n,rects:r,platform:i,elements:a}=t,{apply:o=()=>{},...s}=H(e,t),c=await i.detectOverflow(t,s),l=xe(n),u=Se(n),d=U(n)===`y`,{width:f,height:p}=r.floating,m,h;l===`top`||l===`bottom`?(m=l,h=u===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?`start`:`end`)?`left`:`right`):(h=l,m=u===`end`?`top`:`bottom`);let g=p-c.top-c.bottom,_=f-c.left-c.right,v=ge(p-c[m],g),y=ge(f-c[h],_),b=t.middlewareData.shift,x=!b,S=v,C=y;b!=null&&b.enabled.x&&(C=_),b!=null&&b.enabled.y&&(S=g),x&&!u&&(d?C=f-2*B(c.left,c.right):S=p-2*B(c.top,c.bottom)),await o({...t,availableWidth:C,availableHeight:S});let w=await i.getDimensions(a.floating);return f!==w.width||p!==w.height?{reset:{rects:!0}}:{}}}};function et(){return typeof window<`u`}function tt(e){return nt(e)?(e.nodeName||``).toLowerCase():`#document`}function W(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function G(e){return((nt(e)?e.ownerDocument:e.document)||window.document)?.documentElement}function nt(e){return et()?e instanceof Node||e instanceof W(e).Node:!1}function K(e){return et()?e instanceof Element||e instanceof W(e).Element:!1}function rt(e){return et()?e instanceof HTMLElement||e instanceof W(e).HTMLElement:!1}function it(e){return!et()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof W(e).ShadowRoot}function at(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=q(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!==`inline`&&i!==`contents`}function ot(e){return/^(table|td|th)$/.test(tt(e))}function st(e){try{if(e.matches(`:popover-open`))return!0}catch{}try{return e.matches(`:modal`)}catch{return!1}}var ct=/transform|translate|scale|rotate|perspective|filter/,lt=/paint|layout|strict|content/,ut=e=>!!e&&e!==`none`,dt;function ft(e){let t=K(e)?q(e):e;return ut(t.transform)||ut(t.translate)||ut(t.scale)||ut(t.rotate)||ut(t.perspective)||!mt()&&(ut(t.backdropFilter)||ut(t.filter))||ct.test(t.willChange||``)||lt.test(t.contain||``)}function pt(e){let t=_t(e);for(;rt(t)&&!ht(t);){if(ft(t))return t;if(st(t))return null;t=_t(t)}return null}function mt(){return dt??=typeof CSS<`u`&&CSS.supports&&CSS.supports(`-webkit-backdrop-filter`,`none`),dt}function ht(e){return/^(html|body|#document)$/.test(tt(e))}function q(e){return W(e).getComputedStyle(e)}function gt(e){return K(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function _t(e){if(tt(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||it(e)&&e.host||G(e);return it(t)?t.host:t}function vt(e){let t=_t(e);return ht(t)?(e.ownerDocument||e).body:rt(t)&&at(t)?t:vt(t)}function yt(e,t,n){t===void 0&&(t=[]),n===void 0&&(n=!0);let r=vt(e),i=r===e.ownerDocument?.body,a=W(r);if(i){let e=bt(a);
vendor: 3,545 bytes, line 1
1return t.concat(a,a.visualViewport||[],at(r)?r:[],e&&n?yt(e):[])}else return t.concat(r,yt(r,[],n))}function bt(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function xt(e){let t=q(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=rt(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=_e(n)!==a||_e(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function St(e){return K(e)?e:e.contextElement}function Ct(e){let t=St(e);if(!rt(t))return V(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=xt(t),o=(a?_e(n.width):n.width)/r,s=(a?_e(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var wt=V(0);function Tt(e){let t=W(e);return!mt()||!t.visualViewport?wt:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Et(e,t,n){return t===void 0&&(t=!1),!!n&&t&&n===W(e)}function Dt(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=St(e),o=V(1);t&&(r?K(r)&&(o=Ct(r)):o=Ct(e));let s=Et(a,n,r)?Tt(a):V(0),c=(i.left+s.x)/o.x,l=(i.top+s.y)/o.y,u=i.width/o.x,d=i.height/o.y;if(a&&r){let e=W(a),t=K(r)?W(r):r,n=e,i=bt(n);for(;i&&t!==n;){let e=Ct(i),t=i.getBoundingClientRect(),r=q(i),a=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,o=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,l*=e.y,u*=e.x,d*=e.y,c+=a,l+=o,n=W(i),i=bt(n)}}return Re({width:u,height:d,x:c,y:l})}function Ot(e,t){let n=gt(e).scrollLeft;return t?t.left+n:Dt(G(e)).left+n}function kt(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-Ot(e,n),y:n.top+t.scrollTop}}function At(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=G(r),s=t?st(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=V(1),u=V(0),d=rt(r);if((d||!a)&&((tt(r)!==`body`||at(o))&&(c=gt(r)),d)){let e=Dt(r);l=Ct(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?kt(o,c):V(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+u.x+f.x,y:n.y*l.y-c.scrollTop*l.y+u.y+f.y}}function jt(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function Mt(e){let t=gt(e),n=e.ownerDocument.body,r=B(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),i=B(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight),a=-t.scrollLeft+Ot(e),o=-t.scrollTop;return q(n).direction===`rtl`&&(a+=B(e.clientWidth,n.clientWidth)-r),{width:r,height:i,x:a,y:o}}var Nt=25;function Pt(e,t,n){n===void 0&&(n=`viewport`);let r=n===`layoutViewport`,i=W(e),a=G(e),o=i.visualViewport,s=a.clientWidth,c=a.clientHeight,l=0,u=0;if(o){let e=!mt()||t===`fixed`;r?e||(l=-o.offsetLeft,u=-o.offsetTop):(s=o.width,c=o.height,e&&(l=o.offsetLeft,u=o.offsetTop))}if(Ot(a)<=0){let e=a.ownerDocument,t=e.body,n=getComputedStyle(t),r=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,i=Math.abs(a.clientWidth-t.clientWidth-r),o=getComputedStyle(a).scrollbarGutter===`stable both-edges`?i/2:i;o<=Nt&&(s-=o)}return{width:s,height:c,x:l,y:u}}function Ft(e,t){let n=Dt(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=Ct(e);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function It(e,t,n){let r;if(t===`viewport`||t===`layoutViewport`)r=Pt(e,n,t);else if(t===`document`)r=Mt(G(e));else if(K(t))r=Ft(t,n);else{let n=Tt(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return Re(r)}function Lt(e,t){let n=t.get(e);if(n)return n;let r=yt(e,[],!1).filter(e=>K(e)&&tt(e)!==`body`),i=null,a=q(e).position===`fixed`,o=a?_t(e):e;for(;K(o)&&!ht(o);
vendor: 4,874 bytes, line 1
1){let e=q(o),t=ft(o),n=i?i.position:a?`fixed`:``;!t&&(n===`fixed`||n===`absolute`&&e.position===`static`)?r=r.filter(e=>e!==o):i=e,o=_t(o)}return t.set(e,r),r}function Rt(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?st(t)?[]:Lt(t,this._c):[].concat(n),r],o=It(t,a[0],i),s=o.top,c=o.right,l=o.bottom,u=o.left;for(let e=1;e<a.length;e++){let n=It(t,a[e],i);s=B(n.top,s),c=ge(n.right,c),l=ge(n.bottom,l),u=B(n.left,u)}return{width:c-u,height:l-s,x:u,y:s}}function zt(e){let{width:t,height:n}=xt(e);return{width:t,height:n}}function Bt(e,t,n){let r=rt(t),i=G(t),a=n===`fixed`,o=Dt(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=V(0);if((r||!a)&&((tt(t)!==`body`||at(i))&&(s=gt(t)),r)){let e=Dt(t,!0,a,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}!r&&i&&(c.x=Ot(i));let l=i&&!r&&!a?kt(i,s):V(0);return{x:o.left+s.scrollLeft-c.x-l.x,y:o.top+s.scrollTop-c.y-l.y,width:o.width,height:o.height}}function Vt(e){return q(e).position===`static`}function Ht(e,t){if(!rt(e)||q(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return G(e)===n&&(n=n.ownerDocument.body),n}function Ut(e,t){let n=W(e);if(st(e))return n;if(!rt(e)){let t=_t(e);for(;t&&!ht(t);){if(K(t)&&!Vt(t))return t;t=_t(t)}return n}let r=Ht(e,t);for(;r&&ot(r)&&Vt(r);)r=Ht(r,t);return r&&ht(r)&&Vt(r)&&!ft(r)?n:r||pt(e)||n}var Wt=async function(e){let t=this.getOffsetParent||Ut,n=this.getDimensions,r=await n(e.floating);return{reference:Bt(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Gt(e){return q(e).direction===`rtl`}var Kt={convertOffsetParentRelativeRectToViewportRelativeRect:At,getDocumentElement:G,getClippingRect:Rt,getOffsetParent:Ut,getElementRects:Wt,getClientRects:jt,getDimensions:zt,getScale:Ct,isElement:K,isRTL:Gt};function qt(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Jt(e,t,n){let r=null,i,a=G(e);function o(){var e;clearTimeout(i),(e=r)==null||e.disconnect(),r=null}function s(n,c){n===void 0&&(n=!1),c===void 0&&(c=1),o();let l=e.getBoundingClientRect(),{left:u,top:d,width:f,height:p}=l;if(n||t(),!f||!p)return;let m=ve(d),h=ve(a.clientWidth-(u+f)),g=ve(a.clientHeight-(d+p)),_=ve(u),v={rootMargin:-m+`px `+-h+`px `+-g+`px `+-_+`px`,threshold:B(0,ge(1,c))||1},y=!0;function b(t){let n=t[0].intersectionRatio;if(!qt(l,e.getBoundingClientRect()))return s();if(n!==c){if(!y)return s();n?s(!1,n):i=setTimeout(()=>{s(!1,1e-7)},1e3)}y=!1}try{r=new IntersectionObserver(b,{...v,root:a.ownerDocument})}catch{r=new IntersectionObserver(b,v)}r.observe(e)}let c=W(e),l=()=>s(n);return c.addEventListener(`resize`,l),s(!0),()=>{c.removeEventListener(`resize`,l),o()}}function Yt(e,t,n,r){r===void 0&&(r={});let{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:o=typeof ResizeObserver==`function`,layoutShift:s=typeof IntersectionObserver==`function`,animationFrame:c=!1}=r,l=St(e),u=i||a?[...l?yt(l):[],...t?yt(t):[]]:[];u.forEach(e=>{i&&e.addEventListener(`scroll`,n),a&&e.addEventListener(`resize`,n)});let d=l&&s?Jt(l,n,a):null,f=-1,p=null;o&&(p=new ResizeObserver(e=>{let[r]=e;r&&r.target===l&&p&&t&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var e;(e=p)==null||e.observe(t)})),n()}),l&&!c&&p.observe(l),t&&p.observe(t));let m,h=c?Dt(e):null;c&&g();function g(){let t=Dt(e);h&&!qt(h,t)&&n(),h=t,m=requestAnimationFrame(g)}return n(),()=>{var e;u.forEach(e=>{i&&e.removeEventListener(`scroll`,n),a&&e.removeEventListener(`resize`,n)}),d?.(),(e=p)==null||e.disconnect(),p=null,c&&cancelAnimationFrame(m)}}var Xt=Xe,Zt=Ze,Qt=We,$t=$e,en=qe,tn=Ue,nn=Qe,rn=(e,t,n)=>{let r=new Map,i=n??{},a={...Kt,...i.platform,_c:r};return He(e,t,{...i,platform:a})},an=typeof document<`u`?g.useLayoutEffect:function(){};function on(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e==`function`&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e==`object`){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!on(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){let n=i[r];if(!(n===`_owner`&&e.$$typeof)&&!on(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function sn(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function cn(e,t){let n=sn(e);return Math.round(t*n)/n}function ln(e){let t=g.useRef(e);return an(()=>{t.current=e}),t}function un(e){e===void 0&&(e={});let{placement:t=`bottom`,strategy:n=`absolute`,middleware:r=[],platform:i,elements:{reference:a,floating:o}={},transform:s=!0,whileElementsMounted:c,open:l}=e,[u,d]=g.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=g.useState(r);on(f,r)||p(r);let[m,h]=g.useState(null),[v,y]=g.useState(null),b=g.useCallback(e=>
1{e!==w.current&&(w.current=e,h(e))},[]),x=g.useCallback(e=>{e!==T.current&&(T.current=e,y(e))},[]),S=a||m,C=o||v,w=g.useRef(null),T=g.useRef(null),E=g.useRef(u),D=c!=null,O=ln(c),k=ln(i),A=ln(l),j=g.useCallback(()=>{if(!w.current||!T.current)return;let e={placement:t,strategy:n,middleware:f};k.current&&(e.platform=k.current),rn(w.current,T.current,e).then(e=>{let t={...e,isPositioned:A.current!==!1};M.current&&!on(E.current,t)&&(E.current=t,_.flushSync(()=>{d(t)}))})},[f,t,n,k,A]);an(()=>{l===!1&&E.current.isPositioned&&(E.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[l]);let M=g.useRef(!1);an(()=>(M.current=!0,()=>{M.current=!1}),[]),an(()=>{if(S&&(w.current=S),C&&(T.current=C),S&&C){if(O.current)return O.current(S,C,j);j()}},[S,C,j,O,D]);let N=g.useMemo(()=>({reference:w,floating:T,setReference:b,setFloating:x}),[b,x]),P=g.useMemo(()=>({reference:S,floating:C}),[S,C]),ee=g.useMemo(()=>{let e={position:n,left:0,top:0};if(!P.floating)return e;let t=cn(P.floating,u.x),r=cn(P.floating,u.y);return s?{...e,transform:`translate(`+t+`px, `+r+`px)`,...sn(P.floating)>=1.5&&{willChange:`transform`}}:{position:n,left:t,top:r}},[n,s,P.floating,u.x,u.y]);return g.useMemo(()=>({...u,update:j,refs:N,elements:P,floatingStyles:ee}),[u,j,N,P,ee])}var dn=e=>{function t(e){return{}.hasOwnProperty.call(e,`current`)}return{name:`arrow`,options:e,fn(n){let{element:r,padding:i}=typeof e==`function`?e(n):e;return r&&t(r)?r.current==null?{}:tn({element:r.current,padding:i}).fn(n):r?tn({element:r,padding:i}).fn(n):{}}}},fn=(e,t)=>{let n=Xt(e);return{name:n.name,fn:n.fn,options:[e,t]}},pn=(e,t)=>{let n=Zt(e);return{name:n.name,fn:n.fn,options:[e,t]}},mn=(e,t)=>({fn:nn(e).fn,options:[e,t]}),hn=(e,t)=>{let n=Qt(e);return{name:n.name,fn:n.fn,options:[e,t]}},gn=(e,t)=>{let n=$t(e);return{name:n.name,fn:n.fn,options:[e,t]}},_n=(e,t)=>{let n=en(e);return{name:n.name,fn:n.fn,options:[e,t]}},vn=(e,t)=>{let n=dn(e);return{name:n.name,fn:n.fn,options:[e,t]}},yn=Object.defineProperty,bn=(e,t)=>yn(e,`name`,{value:t,configurable:!0});function xn(e){let[t,n]=g.useState(void 0);return z(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});let t=new ResizeObserver(t=>{if(!Array.isArray(t)||!t.length)return;let r=t[0],i,a;if(`borderBoxSize`in r){let e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;i=t.inlineSize,a=t.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return t.observe(e,{box:`border-box`}),()=>t.unobserve(e)}else n(void 0)},[e]),t}bn(xn,`useSize`);var Sn=Object.defineProperty,Cn=(e,t)=>Sn(e,`name`,{value:t,configurable:!0}),wn=`Popper`,[Tn,En]=A(wn),[Dn,On]=Tn(wn),kn=Cn(e=>{let{__scopePopper:t,children:n}=e,[r,i]=g.useState(null),[a,o]=g.useState(void 0);return(0,E.jsx)(Dn,{scope:t,anchor:r,onAnchorChange:i,placementState:a,setPlacementState:o,children:n})},`Popper`),An=`PopperAnchor`,jn=g.forwardRef(Cn(function(e,t){let{__scopePopper:n,virtualRef:r,...i}=e,o=On(An,n),s=g.useRef(null),c=o.onAnchorChange,l=a(t,g.useCallback(e=>{s.current=e,e&&c(e)},[c])),u=g.useRef(null);g.useEffect(()=>{if(!r)return;let e=u.current;u.current=r.current,e!==u.current&&c(u.current)});let d=o.placementState&&Rn(o.placementState),p=d?.[0],m=d?.[1];return r?null:(0,E.jsx)(f.div,{"data-radix-popper-side":p,"data-radix-popper-align":m,...i,ref:l})},`PopperAnchor`)),Mn=`PopperContent`,[Nn,Pn]=Tn(Mn),Fn=g.forwardRef(Cn(function(e,t){let{__scopePopper:n,side:r=`bottom`,sideOffset:i=0,align:o=`center`,alignOffset:s=0,arrowPadding:c=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:d=0,sticky:p=`partial`,hideWhenDetached:m=!1,updatePositionStrategy:h=`optimized`,onPlaced:_,...v}=e,y=On(Mn,n),[b,x]=g.useState(null),S=a(t,x),[C,w]=g.useState(null),T=xn(C),D=T?.width??0,O=T?.height??0,k=r+(o===`center`?``:`-`+o),A=typeof d==`number`?d:{top:0,right:0,bottom:0,left:0,...d},j=Array.isArray(u)?u:[u],M=j.length>0,N={padding:A,boundary:j.filter(In),altBoundary:M},{refs:ee,floatingStyles:F,placement:I,isPositioned:L,middlewareData:R}=un({strategy:`fixed`,placement:k,whileElementsMounted:Cn((...e)=>Yt(...e,{animationFrame:h===`always`}
1),`whileElementsMounted`),elements:{reference:y.anchor},middleware:[fn({mainAxis:i+O,alignmentAxis:s}),l&&pn({mainAxis:!0,crossAxis:!1,limiter:p===`partial`?mn():void 0,...N}),l&&hn({...N}),gn({...N,apply:Cn(({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{let{width:i,height:a}=t.reference,o=e.floating.style;o.setProperty(`--radix-popper-available-width`,`${n}px`),o.setProperty(`--radix-popper-available-height`,`${r}px`),o.setProperty(`--radix-popper-anchor-width`,`${i}px`),o.setProperty(`--radix-popper-anchor-height`,`${a}px`)},`apply`)}),C&&vn({element:C,padding:c}),Ln({arrowWidth:D,arrowHeight:O}),m&&_n({strategy:`referenceHidden`,...N,boundary:M?N.boundary:void 0})]}),te=y.setPlacementState;z(()=>(te(I),()=>{te(void 0)}),[I,te]);let[ne,re]=Rn(I),ie=P(_);z(()=>{L&&ie?.()},[L,ie]);let ae=R.arrow?.x,oe=R.arrow?.y,se=R.arrow?.centerOffset!==0,[ce,le]=g.useState();return z(()=>{b&&le(window.getComputedStyle(b).zIndex)},[b]),(0,E.jsx)(`div`,{ref:ee.setFloating,"data-radix-popper-content-wrapper":``,style:{...F,transform:L?F.transform:`translate(0, -200%)`,minWidth:`max-content`,zIndex:ce,"--radix-popper-transform-origin":[R.transformOrigin?.x,R.transformOrigin?.y].join(` `),...R.hide?.referenceHidden&&{visibility:`hidden`,pointerEvents:`none`}},dir:e.dir,children:(0,E.jsx)(Nn,{scope:n,placedSide:ne,placedAlign:re,onArrowChange:w,arrowX:ae,arrowY:oe,shouldHideArrow:se,children:(0,E.jsx)(f.div,{"data-side":ne,"data-align":re,...v,ref:S,style:{...v.style,animation:L?v.style?.animation:`none`}})})})},`PopperContent`));function In(e){return e!==null}Cn(In,`isNotNull`);var Ln=Cn(e=>({name:`transformOrigin`,options:e,fn(t){let{placement:n,rects:r,middlewareData:i}=t,a=i.arrow?.centerOffset!==0,o=a?0:e.arrowWidth,s=a?0:e.arrowHeight,[c,l]=Rn(n),u={start:`0%`,center:`50%`,end:`100%`}[l],d=(i.arrow?.x??0)+o/2,f=(i.arrow?.y??0)+s/2,p=``,m=``;return c===`bottom`?(p=a?u:`${d}px`,m=`${-s}px`):c===`top`?(p=a?u:`${d}px`,m=`${r.floating.height+s}px`):c===`right`?(p=`${-s}px`,m=a?u:`${f}px`):c===`left`&&(p=`${r.floating.width+s}px`,m=a?u:`${f}px`),{data:{x:p,y:m}}}}),`transformOrigin`);function Rn(e){let[t,n=`center`]=e.split(`-`);return[t,n]}Cn(Rn,`getSideAndAlignFromPlacement`);var zn=kn,Bn=jn,Vn=Fn,Hn=Object.defineProperty,Un=g.forwardRef(((e,t)=>Hn(e,`name`,{value:t,configurable:!0}))(function(e,t){let{container:n,...r}=e,[i,a]=g.useState(!1);z(()=>a(!0),[]);let o=n||i&&globalThis?.document?.body;return o?_.createPortal((0,E.jsx)(f.div,{...r,ref:t}),o):null},`Portal`)),Wn=Object.defineProperty,J=(e,t)=>Wn(e,`name`,{value:t,configurable:!0});function Gn(e,t){return g.useReducer((e,n)=>t[e][n]??e,e)}J(Gn,`useStateMachine`);var Kn=J(e=>{let{present:t,children:n}=e,r=qn(t),i=typeof n==`function`?n({present:r.isPresent}):g.Children.only(n),a=Yn(r.ref,Zn(i));return typeof n==`function`||r.isPresent?g.cloneElement(i,{ref:a}):null},`Presence`);function qn(e){let[t,n]=g.useState(),r=g.useRef(null),i=g.useRef(e),a=g.useRef(`none`),o=g.useRef(void 0),[s,c]=Gn(e?`mounted`:`unmounted`,{mounted:{UNMOUNT:`unmounted`,ANIMATION_OUT:`unmountSuspended`},unmountSuspended:{MOUNT:`mounted`,ANIMATION_END:`unmounted`},unmounted:{MOUNT:`mounted`}});return g.useEffect(()=>{s===`mounted`?(a.current=o.current??Xn(r.current),o.current=void 0):a.current=`none`},[s]),z(()=>{let t=r.current,n=i.current;if(n!==e){let r=a.current,s=Xn(t);e?(o.current=s,c(`MOUNT`)):s===`none`||t?.display===`none`?c(`UNMOUNT`):c(n&&r!==s?`ANIMATION_OUT`:`UNMOUNT`),i.current=e}},[e,c]),z(()=>{if(t){let e,n=t.ownerDocument.defaultView??window,o=J(a=>{let o=Xn(r.current).includes(CSS.escape(a.animationName));if(a.target===t&&o&&(c(`ANIMATION_END`),!i.current)){let r=t.style.animationFillMode;t.style.animationFillMode=`forwards`,e=n.setTimeout(()=>{t.style.animationFillMode===`forwards`&&(t.style.animationFillMode=r)})}},`handleAnimationEnd`),s=J(e=>{e.target===t&&(a.current=Xn(r.current))},`handleAnimationStart`);return t.addEventListener(`animationstart`,s),t.addEventListener(`animationcancel`,o),t.addEventListener(`animationend`,o),()=>{n.clearTimeout(e),t.removeEventListener(`animationstart`,s),t.removeEventListener(`animationcancel`,o),t.removeEventListener(`animationend`,o)}}
1else c(`ANIMATION_END`)},[t,c]),{isPresent:[`mounted`,`unmountSuspended`].includes(s),ref:g.useCallback(e=>{if(e){let t=getComputedStyle(e);r.current=t,o.current=Xn(t)}else r.current=null;n(e)},[])}}J(qn,`usePresence`);function Jn(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}J(Jn,`setRef`);function Yn(...e){let t=g.useRef(e);return t.current=e,g.useCallback(e=>{let n=t.current,r=!1,i=n.map(t=>{let n=Jn(t,e);return!r&&typeof n==`function`&&(r=!0),n});if(r)return()=>{for(let e=0;e<i.length;e++){let t=i[e];typeof t==`function`?t():Jn(n[e],null)}}},[])}J(Yn,`useStableComposedRefs`);function Xn(e){return e?.animationName||`none`}J(Xn,`getAnimationName`);function Zn(e){let t=Object.getOwnPropertyDescriptor(e.props,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,`ref`)?.get,n=t&&`isReactWarning`in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}J(Zn,`getElementRef`);var Qn=Object.defineProperty,$n=(e,t)=>Qn(e,`name`,{value:t,configurable:!0}),er=g.useEffectEvent,tr=g.useInsertionEffect;function nr(e){if(typeof er==`function`)return er(e);let t=g.useRef(()=>{throw Error(`Cannot call an event handler while rendering.`)});return typeof tr==`function`?tr(()=>{t.current=e}):z(()=>{t.current=e}),g.useMemo(()=>((...e)=>t.current?.(...e)),[])}$n(nr,`useEffectEvent`);var rr=Object.defineProperty,ir=(e,t)=>rr(e,`name`,{value:t,configurable:!0}),ar=g.useInsertionEffect||z;function or({prop:e,defaultProp:t,onChange:n=ir(()=>{},`onChange`),caller:r}){let[i,a,o]=sr({defaultProp:t,onChange:n}),s=e!==void 0;return[s?e:i,g.useCallback(t=>{if(s){let n=cr(t)?t(e):t;n!==e&&o.current?.(n)}else a(t)},[s,e,a,o])]}ir(or,`useControllableState`);function sr({defaultProp:e,onChange:t}){let[n,r]=g.useState(e),i=g.useRef(n),a=g.useRef(t);return ar(()=>{a.current=t},[t]),g.useEffect(()=>{i.current!==n&&(a.current?.(n),i.current=n)},[n,i]),[n,r,a]}ir(sr,`useUncontrolledState`);function cr(e){return typeof e==`function`}ir(cr,`isFunction`);var lr=Symbol(`RADIX:SYNC_STATE`);function ur(e,t,n,r){let{prop:i,defaultProp:a,onChange:o,caller:s}=t,c=i!==void 0,l=nr(o),u=[{...n,state:a}];r&&u.push(r);let[d,f]=g.useReducer((t,n)=>{if(n.type===lr)return{...t,state:n.state};let r=e(t,n);return c&&!Object.is(r.state,t.state)&&l(r.state),r},...u),p=d.state,m=g.useRef(p);g.useEffect(()=>{m.current!==p&&(m.current=p,c||l(p))},[p,m,c]);let h=g.useMemo(()=>i===void 0?d:{...d,state:i},[d,i]);return g.useEffect(()=>{c&&!Object.is(i,d.state)&&f({type:lr,state:i})},[i,d.state,c]),[h,f]}ir(ur,`useControllableStateReducer`);var dr=Object.freeze({position:`absolute`,border:0,width:1,height:1,padding:0,margin:-1,overflow:`hidden`,clip:`rect(0, 0, 0, 0)`,whiteSpace:`nowrap`,wordWrap:`normal`}),fr=Object.defineProperty,Y=(e,t)=>fr(e,`name`,{value:t,configurable:!0}),pr=`focusScope.autoFocusOnMount`,mr=`focusScope.autoFocusOnUnmount`,hr={bubbles:!1,cancelable:!0},gr=g.forwardRef(Y(function(e,t){let{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:o,...s}=e,[c,l]=g.useState(null),u=P(i),d=P(o),p=g.useRef(null),m=a(t,l),h=g.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;g.useEffect(()=>{if(r){let e=function(e){if(h.paused||!c)return;let t=e.target;c.contains(t)?p.current=t:X(p.current,{select:!0})},t=function(e){if(h.paused||!c)return;let t=e.relatedTarget;t!==null&&(c.contains(t)||X(p.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(let t of e)t.removedNodes.length>0&&X(c)};Y(e,`handleFocusIn`),Y(t,`handleFocusOut`),Y(n,`handleMutations`),document.addEventListener(`focusin`,e),document.addEventListener(`focusout`,t);let r=new MutationObserver(n);return c&&r.observe(c,{childList:!0,subtree:!0}),()=>{document.removeEventListener(`focusin`,e),document.removeEventListener(`focusout`,t),r.disconnect()}}},[r,c,h.paused]),g.useEffect(()=>{if(c){Cr.add(h);let e=document.activeElement;if(!c.contains(e)){let t=new CustomEvent(pr,hr);c.addEventListener(pr,u),c.dispatchEvent(t),t.defaultPrevented||(_r(Er(yr(c)),{select:!0}),document.activeElement===e&&X(c))}return()=>{c.removeEventListener(pr,u),setTimeout(()=>{let t=new CustomEvent(mr,hr);c.addEventListener(mr,d),c.dispatchEvent(t),t.defaultPrevented||X(e??document.body,{select:!0}),c.removeEventListener(mr,d),Cr.remove(h)}
1,0)}}},[c,u,d,h]);let _=g.useCallback(e=>{if(!n&&!r||h.paused)return;let t=e.key===`Tab`&&!e.altKey&&!e.ctrlKey&&!e.metaKey,i=document.activeElement;if(t&&i){let t=e.currentTarget,[r,a]=vr(t);r&&a?!e.shiftKey&&i===a?(e.preventDefault(),n&&X(r,{select:!0})):e.shiftKey&&i===r&&(e.preventDefault(),n&&X(a,{select:!0})):i===t&&e.preventDefault()}},[n,r,h.paused]);return(0,E.jsx)(f.div,{tabIndex:-1,...s,ref:m,onKeyDown:_})},`FocusScope`));function _r(e,{select:t=!1}={}){let n=document.activeElement;for(let r of e)if(X(r,{select:t}),document.activeElement!==n)return}Y(_r,`focusFirst`);function vr(e){let t=yr(e);return[br(t,e),br(t.reverse(),e)]}Y(vr,`getTabbableEdges`);function yr(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:Y(e=>{let t=e.tagName===`INPUT`&&e.type===`hidden`;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP},`acceptNode`)});for(;n.nextNode();)t.push(n.currentNode);return t}Y(yr,`getTabbableCandidates`);function br(e,t){let n=typeof t.checkVisibility==`function`&&t.checkVisibility({checkVisibilityCSS:!0});for(let r of e)if(!(n?!r.checkVisibility({checkVisibilityCSS:!0}):xr(r,{upTo:t})))return r}Y(br,`findVisible`);function xr(e,{upTo:t}){if(getComputedStyle(e).visibility===`hidden`)return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display===`none`)return!0;e=e.parentElement}return!1}Y(xr,`isHidden`);function Sr(e){return e instanceof HTMLInputElement&&`select`in e}Y(Sr,`isSelectableInput`);function X(e,{select:t=!1}={}){if(e&&e.focus){let n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Sr(e)&&t&&e.select()}}Y(X,`focus`);var Cr=wr();function wr(){let e=[];return{add(t){let n=e[0];t!==n&&n?.pause(),e=Tr(e,t),e.unshift(t)},remove(t){e=Tr(e,t),e[0]?.resume()}}}Y(wr,`createFocusScopesStack`);function Tr(e,t){let n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}Y(Tr,`arrayRemove`);function Er(e){return e.filter(e=>e.tagName!==`A`)}Y(Er,`removeLinks`);var Dr=Object.defineProperty,Or=(e,t)=>Dr(e,`name`,{value:t,configurable:!0}),kr=0,Ar=null;function jr(e){return Mr(),e.children}Or(jr,`FocusGuards`);function Mr(){g.useEffect(()=>{Ar||={start:Nr(),end:Nr()};let{start:e,end:t}=Ar;return document.body.firstElementChild!==e&&document.body.insertAdjacentElement(`afterbegin`,e),document.body.lastElementChild!==t&&document.body.insertAdjacentElement(`beforeend`,t),kr++,()=>{kr===1&&(Ar?.start.remove(),Ar?.end.remove(),Ar=null),kr=Math.max(0,kr-1)}},[])}Or(Mr,`useFocusGuards`);function Nr(){let e=document.createElement(`span`);return e.setAttribute(`data-radix-focus-guard`,``),e.tabIndex=0,e.style.outline=`none`,e.style.opacity=`0`,e.style.position=`fixed`,e.style.pointerEvents=`none`,e}Or(Nr,`createFocusGuard`);var Pr=`right-scroll-bar-position`,Fr=`width-before-scroll-bar`,Ir=`with-scroll-bars-hidden`,Lr=`--removed-body-scroll-bar-size`;function Rr(e,t){return typeof e==`function`?e(t):e&&(e.current=t),e}function zr(e,t){var n=(0,g.useState)(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(e){var t=n.value;t!==e&&(n.value=e,n.callback(e,t))}}}})[0];return n.callback=t,n.facade}var Br=typeof window<`u`?g.useLayoutEffect:g.useEffect,Vr=new WeakMap;function Hr(e,t){var n=zr(t||null,function(t){return e.forEach(function(e){return Rr(e,t)})});return Br(function(){var t=Vr.get(n);if(t){var r=new Set(t),i=new Set(e),a=n.current;r.forEach(function(e){i.has(e)||Rr(e,null)}),i.forEach(function(e){r.has(e)||Rr(e,a)})}Vr.set(n,e)},[e]),n}function Ur(e){return e}function Wr(e,t){t===void 0&&(t=Ur);var n=[],r=!1;return{read:function(){if(r)throw Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(e){var i=t(e,r);return n.push(i),function(){n=n.filter(function(e){return e!==i})}},assignSyncMedium:function(e){for(r=!0;n.length;){var t=n;n=[],t.forEach(e)}n={push:function(t){return e(t)},filter:function(){return n}}},assignMedium:function(e){r=!0;var t=[];if(n.length){var i=n;
vendor: 7,475 bytes, lines 1-41
1n=[],i.forEach(e),t=n}var a=function(){var n=t;t=[],n.forEach(e)},o=function(){return Promise.resolve().then(a)};o(),n={push:function(e){t.push(e),o()},filter:function(e){return t=t.filter(e),n}}}}}function Gr(e){e===void 0&&(e={});var t=Wr(null);return t.options=u({async:!0,ssr:!1},e),t}var Kr=function(e){var t=e.sideCar,n=l(e,[`sideCar`]);if(!t)throw Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw Error(`Sidecar medium not found`);return g.createElement(r,u({},n))};Kr.isSideCarExport=!0;function qr(e,t){return e.useMedium(t),Kr}var Jr=Gr(),Yr=function(){},Xr=g.forwardRef(function(e,t){var n=g.useRef(null),r=g.useState({onScrollCapture:Yr,onWheelCapture:Yr,onTouchMoveCapture:Yr}),i=r[0],a=r[1],o=e.forwardProps,s=e.children,c=e.className,d=e.removeScrollBar,f=e.enabled,p=e.shards,m=e.sideCar,h=e.noRelative,_=e.noIsolation,v=e.inert,y=e.allowPinchZoom,b=e.as,x=b===void 0?`div`:b,S=e.gapMode,C=l(e,[`forwardProps`,`children`,`className`,`removeScrollBar`,`enabled`,`shards`,`sideCar`,`noRelative`,`noIsolation`,`inert`,`allowPinchZoom`,`as`,`gapMode`]),w=m,T=Hr([n,t]),E=u(u({},C),i);return g.createElement(g.Fragment,null,f&&g.createElement(w,{sideCar:Jr,removeScrollBar:d,shards:p,noRelative:h,noIsolation:_,inert:v,setCallbacks:a,allowPinchZoom:!!y,lockRef:n,gapMode:S}),o?g.cloneElement(g.Children.only(s),u(u({},E),{ref:T})):g.createElement(x,u({},E,{className:c,ref:T}),s))});Xr.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},Xr.classNames={fullWidth:Fr,zeroRight:Pr};var Zr,Qr=function(){if(Zr)return Zr;if(typeof __webpack_nonce__<`u`)return __webpack_nonce__};function $r(){if(!document)return null;var e=document.createElement(`style`);e.type=`text/css`;var t=Qr();return t&&e.setAttribute(`nonce`,t),e}function ei(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function ti(e){(document.head||document.getElementsByTagName(`head`)[0]).appendChild(e)}var ni=function(){var e=0,t=null;return{add:function(n){e==0&&(t=$r())&&(ei(t,n),ti(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},ri=function(){var e=ni();return function(t,n){g.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},ii=function(){var e=ri();return function(t){var n=t.styles,r=t.dynamic;return e(n,r),null}},ai={left:0,top:0,right:0,gap:0},oi=function(e){return parseInt(e||``,10)||0},si=function(e){var t=window.getComputedStyle(document.body),n=t[e===`padding`?`paddingLeft`:`marginLeft`],r=t[e===`padding`?`paddingTop`:`marginTop`],i=t[e===`padding`?`paddingRight`:`marginRight`];return[oi(n),oi(r),oi(i)]},ci=function(e){if(e===void 0&&(e=`margin`),typeof window>`u`)return ai;var t=si(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},li=ii(),ui=`data-scroll-locked`,di=function(e,t,n,r){var i=e.left,a=e.top,o=e.right,s=e.gap;return n===void 0&&(n=`margin`),` 2 .${Ir} { 3 overflow: hidden ${r}; 4 padding-right: ${s}px ${r}; 5 } 6 body[${ui}] { 7 overflow: hidden ${r}; 8 overscroll-behavior: contain; 9 ${[t&&`position: relative ${r};`,n===`margin`&&` 10 padding-left: ${i}px; 11 padding-top: ${a}px; 12 padding-right: ${o}px; 13 margin-left:0; 14 margin-top:0; 15 margin-right: ${s}px ${r}; 16 `,n===`padding`&&`padding-right: ${s}px ${r};`].filter(Boolean).join(``)} 17 } 18 19 .${Pr} { 20 right: ${s}px ${r}; 21 } 22 23 .${Fr} { 24 margin-right: ${s}px ${r}; 25 } 26 27 .${Pr} .${Pr} { 28 right: 0 ${r}; 29 } 30 31 .${Fr} .${Fr} { 32 margin-right: 0 ${r}; 33 } 34 35 body[${ui}] { 36 ${Lr}: ${s}px; 37 } 38`},fi=function(){var e=parseInt(document.body.getAttribute(`data-scroll-locked`)||`0`,10);return isFinite(e)?e:0},pi=function(){g.useEffect(function(){return document.body.setAttribute(ui,(fi()+1).toString()),function(){var e=fi()-1;e<=0?document.body.removeAttribute(ui):document.body.setAttribute(ui,e.toString())}},[])},mi=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?`margin`:r;pi();var a=g.useMemo(function(){return ci(i)},[i]);return g.createElement(li,{styles:di(a,!t,i,n?``:`!important`)})},hi=!1;if(typeof window<`u`)try{var gi=Object.defineProperty({},"passive",{get:function(){return hi=!0,!0}});window.addEventListener(`test`,gi,gi),window.removeEventListener(`test`,gi,gi)}catch{hi=!1}var _i=hi?{passive:!1}:!1,vi=function(e){return e.tagName===`TEXTAREA`},yi=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!==`hidden`&&!(n.overflowY===n.overflowX&&!vi(e)&&n[t]===`visible`)},bi=function(e){return yi(e,`overflowY`)},xi=function(e){return yi(e,`overflowX`)},Si=function(e,t){var n=t.ownerDocument,r=t;do{if(typeof ShadowRoot<`u`&&r instanceof ShadowRoot&&(r=r.host),Ti(e,r)){var i=Ei(e,r);if(i[1]>i[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},Ci=function(e){return[e.scrollTop,e.scrollHeight,e.clientHeight]},wi=function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]},Ti=function(e,t){return e===`v`?bi(t):xi(t)},Ei=function(e,t){return e===`v`?Ci(t):wi(t)},Di=function(e,t){return e===`h`&&t===`rtl`?-1:1},Oi=function(e,t,n,r,i){var a=Di(e,window.getComputedStyle(t).direction),o=a*r,s=n.target,c=t.contains(s),l=!1,u=o>0,d=0,f=0;do{if(!s)break;var p=Ei(e,s),m=p[0],h=p[1]-p[2]-a*m;(m||h)&&Ti(e,s)&&(d+=h,f+=m);var g=s.parentNode;s=g&&g.nodeType===Node.DOCUMENT_FRAGMENT_NODE?g.host:g}while(!c&&s!==document.body||c&&(t.contains(s)||t===s));return(u&&(i&&Math.abs(d)<1||!i&&o>d)||!u&&(i&&Math.abs(f)<1||!i&&-o>f))&&(l=!0),l},ki=function(e){return`changedTouches`in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Ai=function(e){return[e.deltaX,e.deltaY]},ji=function(e){return e&&`current`in e?e.current:e},Mi=function(e,t){return e[0]===t[0]&&e[1]===t[1]},Ni=function(e){return` 39 .block-interactivity-${e} {pointer-events: none;} 40 .allow-interactivity-${e} {pointer-events: all;} 41`},Pi=0,Fi=[];function Ii(e){var t=g.useRef([]),n=g.useRef([0,0]),r=g.useRef(),i=g.useState(Pi++)[0],a=g.useState(ii)[0],o=g.useRef(e);g.useEffect(function(){o.current=e},[e]),g.useEffect(function(){if(e.inert){document.body.classList.add(`block-interactivity-${i}`);var t=c([e.lockRef.current],(e.shards||[]).map(ji),!0).filter(Boolean);return t.forEach(function(e){return e.classList.add(`allow-interactivity-${i}`)}),function(){document.body.classList.remove(`block-interactivity-${i}`),t.forEach(function(e){return e.classList.remove(`allow-interactivity-${i}`)})}}},[e.inert,e.lockRef.current,e.shards]);var s=g.useCallback(function(e,t){if(`touches`in e&&e.touches.length===2||e.type===`wheel`&&e.ctrlKey)return!o.current.allowPinchZoom;var i=ki(e),a=n.current,s=`deltaX`in e?e.deltaX:a[0]-i[0],c=`deltaY`in e?e.deltaY:a[1]-i[1],l,u=e.target,d=Math.abs(s)>Math.abs(c)?`h`:`v`;if(`touches`in e&&d===`h`&&u.type===`range`)return!1;var f=window.getSelection(),p=f&&f.anchorNode;if(p&&(p===u||p.contains(u)))return!1;var m=Si(d,u);if(!m)return!0;if(m?l=d:(l=d===`v`?`h`:`v`,m=Si(d,u)),!m)return!1;if(!r.current&&`changedTouches`in e&&(s||c)&&(r.current=l),!l)return!0;var h=r.current||l;return Oi(h,t,e,h===`h`?s:c,!0)},[]),l=g.useCallback(function(e){var n=e;if(!(!Fi.length||Fi[Fi.length-1]!==a)){var r=`deltaY`in n?Ai(n):ki(n),i=t.current.filter(function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&Mi(e.delta,r)})[0];if(i&&i.should){n.cancelable&&n.preventDefault();return}
41if(!i){var c=(o.current.shards||[]).map(ji).filter(Boolean).filter(function(e){return e.contains(n.target)});(c.length>0?s(n,c[0]):!o.current.noIsolation)&&n.cancelable&&n.preventDefault()}}},[]),u=g.useCallback(function(e,n,r,i){var a={name:e,delta:n,target:r,should:i,shadowParent:Li(r)};t.current.push(a),setTimeout(function(){t.current=t.current.filter(function(e){return e!==a})},1)},[]),d=g.useCallback(function(e){n.current=ki(e),r.current=void 0},[]),f=g.useCallback(function(t){u(t.type,Ai(t),t.target,s(t,e.lockRef.current))},[]),p=g.useCallback(function(t){u(t.type,ki(t),t.target,s(t,e.lockRef.current))},[]);g.useEffect(function(){return Fi.push(a),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:p}),document.addEventListener(`wheel`,l,_i),document.addEventListener(`touchmove`,l,_i),document.addEventListener(`touchstart`,d,_i),function(){Fi=Fi.filter(function(e){return e!==a}),document.removeEventListener(`wheel`,l,_i),document.removeEventListener(`touchmove`,l,_i),document.removeEventListener(`touchstart`,d,_i)}},[]);var m=e.removeScrollBar,h=e.inert;return g.createElement(g.Fragment,null,h?g.createElement(a,{styles:Ni(i)}):null,m?g.createElement(mi,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function Li(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}var Ri=qr(Jr,Ii),zi=g.forwardRef(function(e,t){return g.createElement(Xr,u({},e,{ref:t,sideCar:Ri}))});zi.classNames=Xr.classNames;var Bi=function(e){return typeof document>`u`?null:(Array.isArray(e)?e[0]:e).ownerDocument.body},Vi=new WeakMap,Hi=new WeakMap,Ui={},Wi=0,Gi=function(e){return e&&(e.host||Gi(e.parentNode))},Ki=function(e,t){return t.map(function(t){if(e.contains(t))return t;var n=Gi(t);return n&&e.contains(n)?n:(console.error(`aria-hidden`,t,`in not contained inside`,e,`. Doing nothing`),null)}).filter(function(e){return!!e})},qi=function(e,t,n,r){var i=Ki(t,Array.isArray(e)?e:[e]);Ui[n]||(Ui[n]=new WeakMap);var a=Ui[n],o=[],s=new Set,c=new Set(i),l=function(e){!e||s.has(e)||(s.add(e),l(e.parentNode))};i.forEach(l);var u=function(e){!e||c.has(e)||Array.prototype.forEach.call(e.children,function(e){if(s.has(e))u(e);else try{var t=e.getAttribute(r),i=t!==null&&t!==`false`,c=(Vi.get(e)||0)+1,l=(a.get(e)||0)+1;Vi.set(e,c),a.set(e,l),o.push(e),c===1&&i&&Hi.set(e,!0),l===1&&e.setAttribute(n,`true`),i||e.setAttribute(r,`true`)}catch(t){console.error(`aria-hidden: cannot operate on `,e,t)}})};return u(t),s.clear(),Wi++,function(){o.forEach(function(e){var t=Vi.get(e)-1,i=a.get(e)-1;Vi.set(e,t),a.set(e,i),t||(Hi.has(e)||e.removeAttribute(r),Hi.delete(e)),i||e.removeAttribute(n)}),Wi--,Wi||(Vi=new WeakMap,Vi=new WeakMap,Hi=new WeakMap,Ui={})}},Ji=function(e,t,n){n===void 0&&(n=`data-aria-hidden`);var r=Array.from(Array.isArray(e)?e:[e]),i=t||Bi(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll(`[aria-live], script`))),qi(r,i,n,`aria-hidden`)):function(){return null}},Yi=Object.defineProperty,Z=(e,t)=>Yi(e,`name`,{value:t,configurable:!0});function Xi(e){let t=e+`CollectionProvider`,[n,r]=A(t),[i,o]=n(t,{collectionRef:{current:null},itemMap:new Map}),c=Z(e=>{let{scope:t,children:n}=e,r=g.useRef(null),a=g.useRef(new Map).current;return(0,E.jsx)(i,{scope:t,itemMap:a,collectionRef:r,children:n})},`CollectionProvider`);c.displayName=t;let l=e+`CollectionSlot`,u=s(l),d=g.forwardRef((e,t)=>{let{scope:n,children:r}=e,i=a(t,o(l,n).collectionRef);return(0,E.jsx)(u,{ref:i,children:r})});d.displayName=l;let f=e+`CollectionItemSlot`,p=`data-radix-collection-item`,m=s(f),h=g.forwardRef((e,t)=>{let{scope:n,children:r,...i}=e,s=g.useRef(null),c=a(t,s),l=o(f,n);return g.useEffect(()=>(l.itemMap.set(s,{ref:s,...i}),()=>void l.itemMap.delete(s))),(0,E.jsx)(m,{[p]:``,ref:c,children:r})});h.displayName=f;function _(t){let n=o(e+`CollectionConsumer`,t);return g.useCallback(()=>{let e=n.collectionRef.current;if(!e)return[];let t=Array.from(e.querySelectorAll(`[${p}]`));return Array.from(n.itemMap.values()).sort((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current))},[n.collectionRef,n.itemMap])}return Z(_,`useCollection`),[{Provider:c,Slot:d,ItemSlot:h},_,r]}Z(Xi,`createCollection`);var Zi=new WeakMap,Qi=class e extends Map{static{Z(this,`OrderedDict`)}#e;constructor(e){super(e),this.#e=[...super.keys()],Zi.set(this,!0)}set(e,t){return Zi.get(this)&&(this.has(e)?this.#e[this.#e.indexOf(e)]=e:this.#e.push(e)),super.set(e,t),this}insert(e,t,n){let r=this.has(t),i=this.#e.length,a=ta(e),o=a>=0?a:i+a,s=o<0||o>=i?-1:o;if(s===this.size||r&&s===this.size-1||s===-1)return this.set(t,n),this;let c=this.size+ +!r;a<0&&o++;let l=[...this.#e],u,d=!1;for(let e=o;e<c;e++)if(o===e){let i=l[e];l[e]===t&&(i=l[e+1]),r&&this.delete(t),u=this.get(i),this.set(t,n)}else{!d&&l[e-1]===t&&(d=!0);let n=l[d?e:e-1],r=u;u=this.get(n),this.delete(n),this.set(n,r)}return this}with(t,n,r){let i=new e(this);return i.insert(t,n,r),i}before(e){let t=this.#e.indexOf(e)-1;if(!(t<0))return this.entryAt(t)}setBefore(e,t,n){let r=this.#e.indexOf(e);return r===-1?this:this.insert(r,t,n)}after(e){let t=this.#e.indexOf(e);if(t=t===-1||t===this.size-1?-1:t+1,t!==-1)return this.entryAt(t)}setAfter(e,t,n){let r=this.#e.indexOf(e);return r===-1?this:this.insert(r+1,t,n)}first(){return this.entryAt(0)}last(){return this.entryAt(-1)}clear(){return this.#e=[],super.clear()}delete(e){let t=super.delete(e);return t&&this.#e.splice(this.#e.indexOf(e),1),t}deleteAt(e){let t=this.keyAt(e);return t!==void 0&&this.delete(t)}at(e){let t=$i(this.#e,e);if(t!==void 0)return this.get(t)}entryAt(e){let t=$i(this.#e,e);if(t!==void 0)return[t,this.get(t)]}indexOf(e){return this.#e.indexOf(e)}keyAt(e){return $i(this.#e,e)}from(e,t){let n=this.indexOf(e);if(n===-1)return;let r=n+t;return r<0&&(r=0),r>=this.size&&(r=this.size-1),this.at(r)}keyFrom(e,t){let n=this.indexOf(e);if(n===-1)return;let r=n+t;return r<0&&(r=0),r>=this.size&&(r=this.size-1),this.keyAt(r)}find(e,t){let n=0;for(let r of this){if(Reflect.apply(e,t,[r,n,this]))return r;n++}
41}findIndex(e,t){let n=0;for(let r of this){if(Reflect.apply(e,t,[r,n,this]))return n;n++}return-1}filter(t,n){let r=[],i=0;for(let e of this)Reflect.apply(t,n,[e,i,this])&&r.push(e),i++;return new e(r)}map(t,n){let r=[],i=0;for(let e of this)r.push([e[0],Reflect.apply(t,n,[e,i,this])]),i++;return new e(r)}reduce(...e){let[t,n]=e,r=0,i=n??this.at(0);for(let n of this)i=r===0&&e.length===1?n:Reflect.apply(t,this,[i,n,r,this]),r++;return i}reduceRight(...e){let[t,n]=e,r=n??this.at(-1);for(let n=this.size-1;n>=0;n--){let i=this.at(n);r=n===this.size-1&&e.length===1?i:Reflect.apply(t,this,[r,i,n,this])}return r}toSorted(t){let n=[...this.entries()].sort(t);return new e(n)}toReversed(){let t=new e;for(let e=this.size-1;e>=0;e--){let n=this.keyAt(e),r=this.get(n);t.set(n,r)}return t}toSpliced(...t){let n=[...this.entries()];return n.splice(...t),new e(n)}slice(t,n){let r=new e,i=this.size-1;if(t===void 0)return r;t<0&&(t+=this.size),n!==void 0&&n>0&&(i=n-1);for(let e=t;e<=i;e++){let t=this.keyAt(e),n=this.get(t);r.set(t,n)}return r}every(e,t){let n=0;for(let r of this){if(!Reflect.apply(e,t,[r,n,this]))return!1;n++}return!0}some(e,t){let n=0;for(let r of this){if(Reflect.apply(e,t,[r,n,this]))return!0;n++}return!1}};function $i(e,t){if(`at`in Array.prototype)return Array.prototype.at.call(e,t);let n=ea(e,t);return n===-1?void 0:e[n]}Z($i,`at`);function ea(e,t){let n=e.length,r=ta(t),i=r>=0?r:n+r;return i<0||i>=n?-1:i}Z(ea,`toSafeIndex`);function ta(e){return e!==e||e===0?0:Math.trunc(e)}Z(ta,`toSafeInteger`);function na(e){let t=e+`CollectionProvider`,[n,r]=A(t),[i,o]=n(t,{collectionElement:null,collectionRef:{current:null},collectionRefObject:{current:null},itemMap:new Qi,setItemMap:Z(()=>void 0,`setItemMap`)}),c=Z(({state:e,...t})=>e?(0,E.jsx)(u,{...t,state:e}):(0,E.jsx)(l,{...t}),`CollectionProvider`);c.displayName=t;let l=Z(e=>{let t=v();return(0,E.jsx)(u,{...e,state:t})},`CollectionInit`);l.displayName=t+`Init`;let u=Z(e=>{let{scope:t,children:n,state:r}=e,o=g.useRef(null),[s,c]=g.useState(null),l=a(o,c),[u,d]=r;return g.useEffect(()=>{if(!s)return;let e=oa(()=>{});return e.observe(s,{childList:!0,subtree:!0}),()=>{e.disconnect()}},[s]),(0,E.jsx)(i,{scope:t,itemMap:u,setItemMap:d,collectionRef:l,collectionRefObject:o,collectionElement:s,children:n})},`CollectionProviderImpl`);u.displayName=t+`Impl`;let d=e+`CollectionSlot`,f=s(d),p=g.forwardRef((e,t)=>{let{scope:n,children:r}=e,i=a(t,o(d,n).collectionRef);return(0,E.jsx)(f,{ref:i,children:r})});p.displayName=d;let m=e+`CollectionItemSlot`,h=s(m),_=g.forwardRef((e,t)=>{let{scope:n,children:r,...i}=e,s=g.useRef(null),[c,l]=g.useState(null),u=a(t,s,l),{setItemMap:d}=o(m,n),f=g.useRef(i);ra(f.current,i)||(f.current=i);let p=f.current;return g.useEffect(()=>{let e=p;return d(t=>c?t.has(c)?t.set(c,{...e,element:c}).toSorted(aa):(t.set(c,{...e,element:c}),t.toSorted(aa)):t),()=>{d(e=>!c||!e.has(c)?e:(e.delete(c),new Qi(e)))}},[c,p,d]),(0,E.jsx)(h,{"data-radix-collection-item":``,ref:u,children:r})});_.displayName=m;function v(){return g.useState(new Qi)}Z(v,`useInitCollection`);function y(t){let{itemMap:n}=o(e+`CollectionConsumer`,t);return n}return Z(y,`useCollection`),[{Provider:c,Slot:p,ItemSlot:_},{createCollectionScope:r,useCollection:y,useInitCollection:v}]}Z(na,`createCollection`);function ra(e,t){if(e===t)return!0;if(typeof e!=`object`||typeof t!=`object`||e==null||t==null)return!1;let n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(let r of n)if(!Object.prototype.hasOwnProperty.call(t,r)||e[r]!==t[r])return!1;return!0}Z(ra,`shallowEqual`);function ia(e,t){return!!(t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_PRECEDING)}Z(ia,`isElementPreceding`);function aa(e,t){return!e[1].element||!t[1].element?0:ia(e[1].element,t[1].element)?-1:1}Z(aa,`sortByDocumentPosition`);function oa(e){return new MutationObserver(t=>{for(let n of t)if(n.type===`childList`){e();return}})}Z(oa,`getChildListObserver`);var sa=Object.defineProperty,ca=(e,t)=>sa(e,`name`,{value:t,configurable:!0}),la=g.createContext(void 0);function ua(e){let t=g.useContext(la);return e||t||`ltr`}ca(ua,`useDirection`);var da=Object.defineProperty,fa=(e,t)=>da(e,`name`,{value:t,configurable:!0});function pa(e,[t,n]){return Math.min(n,Math.max(t,e))}fa(pa,`clamp`);var ma=Object.defineProperty,ha=(e,t)=>ma(e,`name`,{value:t,configurable:!0});function ga(e){let t=g.useRef({value:e,previous:e});return g.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}ha(ga,`usePrevious`);var _a=Object.defineProperty,Q=(e,t)=>_a(e,`name`,{value:t,configurable:!0}),va=[` `,`Enter`,`ArrowUp`,`ArrowDown`],ya=[` `,`Enter`],ba=`Select`,[xa,Sa,Ca]=Xi(ba),[wa,Ta]=A(ba,[Ca,En]),Ea=En(),[Da,Oa]=wa(ba),[ka,Aa]=wa(ba);function ja(e){let{__scopeSelect:t,children:n,open:r,defaultOpen:i,onOpenChange:a,value:o,defaultValue:s,onValueChange:c,dir:l,name:u,autoComplete:d,disabled:f,required:p,form:m,internal_do_not_use_render:h}=e,_=Ea(t),[v,y]=g.useState(null),[b,x]=g.useState(null),[S,C]=g.useState(!1),w=ua(l),[T,D]=or({prop:r,defaultProp:i??!1,onChange:a,caller:ba}),[O,k]=or({prop:o,defaultProp:s,onChange:c,caller:ba}),A=g.useRef(null),j=g.useRef(O);g.useEffect(()=>{let e=m?v?.ownerDocument.getElementById(m):v?.form;if(e instanceof HTMLFormElement){let t=Q(()=>k(j.current),`reset`);return e.addEventListener(`reset`,t),()=>e.removeEventListener(`reset`,t)}},[m,v,k]);let M=!v||!!m||!!v.closest(`form`),[N,P]=g.useState(new Set),ee=me(),F=Array.from(N).map(e=>e.props.value).join(`;`),I=g.useCallback(e=>{P(t=>new Set(t).add(e))},[]),L=g.useCallback(e=>{P(t=>{let n=new Set(t);return n.delete(e),n})},[]),R={required:p,trigger:v,onTriggerChange:y,valueNode:b,onValueNodeChange:x,valueNodeHasChildren:S,onValueNodeHasChildrenChange:C,contentId:ee,value:O,onValueChange:k,open:T,onOpenChange:D,dir:w,triggerPointerDownPosRef:A,disabled:f,name:u,autoComplete:d,form:m,nativeOptions:N,nativeSelectKey:F,isFormControl:M};return(0,E.jsx)(zn,{..._,children:(0,E.jsx)(Da,{scope:t,...R,children:(0,E.jsx)(xa.Provider,{scope:t,children:(0,E.jsx)(ka,{scope:t,onNativeOptionAdd:I,onNativeOptionRemove:L,children:xo(h)?h(R):n})})})})}Q(ja,`SelectProvider`);var Ma=Q(e=>{let{__scopeSelect:t,children:n,...r}=e;return(0,E.jsx)(ja,{__scopeSelect:t,...r,internal_do_not_use_render:({isFormControl:e})=>(0,E.jsxs)(E.Fragment,{children:[n,e?(0,E.jsx)(bo,{__scopeSelect:t}):null]})})},`Select`),Na=`SelectTrigger`,Pa=g.forwardRef(Q(function(e,t){let{__scopeSelect:n,disabled:r=!1,...i}=e,o=Ea(n),s=Oa(Na,n),c=s.disabled||r,l=a(t,s.onTriggerChange),u=Sa(n),d=g.useRef(`touch`),[p,m,h]=Co(e=>{let t=u().filter(e=>!e.disabled),n=wo(t,e,t.find(e=>e.value===s.value));n!==void 0&&s.onValueChange(n.value)}),_=Q(e=>{c||(s.onOpenChange(!0),h()),e&&(s.triggerPointerDownPosRef.current={x:Math.round(e.pageX),y:Math.round(e.pageY)})},`handleOpen`);return(0,E.jsx)(Bn,{asChild:!0,...o,children:(0,E.jsx)(f.button,{type:`button`,role:`combobox`,"aria-controls":s.open?s.contentId:void 0,"aria-expanded":s.open,"aria-required":s.required,"aria-autocomplete":`none`,dir:s.dir,"data-state":s.open?`open`:`closed`,disabled:c,"data-disabled":c?``:void 0,"data-placeholder":So(s.value)?``:void 0,...i,ref:l,onClick:x(i.onClick,e=>
41{e.currentTarget.focus(),d.current!==`mouse`&&_(e)}),onPointerDown:x(i.onPointerDown,e=>{d.current=e.pointerType;let t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),e.button===0&&e.ctrlKey===!1&&e.pointerType===`mouse`&&(_(e),e.preventDefault())}),onKeyDown:x(i.onKeyDown,e=>{let t=p.current!==``;!(e.ctrlKey||e.altKey||e.metaKey)&&e.key.length===1&&m(e.key),!(t&&e.key===` `)&&va.includes(e.key)&&(_(),e.preventDefault())})})})},`SelectTrigger`)),Fa=`SelectValue`,Ia=g.forwardRef(Q(function(e,t){let{__scopeSelect:n,className:r,style:i,children:o,placeholder:s=``,...c}=e,l=Oa(Fa,n),{onValueNodeHasChildrenChange:u}=l,d=o!==void 0,p=a(t,l.onValueNodeChange);z(()=>{u(d)},[u,d]);let m=So(l.value);return(0,E.jsx)(f.span,{...c,asChild:!m&&c.asChild,ref:p,style:{pointerEvents:`none`},children:(0,E.jsx)(g.Fragment,{children:m?s:o},m?`placeholder`:`value`)})},`SelectValue`)),La=g.forwardRef(Q(function(e,t){let{__scopeSelect:n,children:r,...i}=e;return(0,E.jsx)(f.span,{"aria-hidden":!0,...i,ref:t,children:r||`â¼`})},`SelectIcon`)),[Ra,za]=wa(`SelectPortal`,{forceMount:void 0}),Ba=Q(e=>{let{__scopeSelect:t,forceMount:n,...r}=e;return(0,E.jsx)(Ra,{scope:e.__scopeSelect,forceMount:n,children:(0,E.jsx)(Un,{asChild:!0,...r})})},`SelectPortal`),Va=`SelectContent`,Ha=g.forwardRef(Q(function(e,t){let n=za(Va,e.__scopeSelect),{forceMount:r=n.forceMount,...i}=e,a=Oa(Va,e.__scopeSelect),[o,s]=g.useState();return z(()=>{s(new DocumentFragment)},[]),(0,E.jsx)(Kn,{present:r||a.open,children:({present:e})=>e?(0,E.jsx)(qa,{...i,ref:t}):(0,E.jsx)(Ua,{...i,fragment:o})})},`SelectContent`)),Ua=g.forwardRef(Q(function(e,t){let{__scopeSelect:n,children:r,fragment:i}=e;return i?_.createPortal((0,E.jsx)(Wa,{scope:n,children:(0,E.jsx)(xa.Slot,{scope:n,children:(0,E.jsx)(`div`,{ref:t,children:r})})}),i):null},`SelectContentFragment`)),$=10,[Wa,Ga]=wa(Va),Ka=s(`SelectContent.RemoveScroll`),qa=g.forwardRef(Q(function(e,t){let{__scopeSelect:n}=e,{position:r=`item-aligned`,onCloseAutoFocus:i,onEscapeKeyDown:o,onPointerDownOutside:s,side:c,sideOffset:l,align:u,alignOffset:d,arrowPadding:f,collisionBoundary:p,collisionPadding:m,sticky:
41h,hideWhenDetached:_,avoidCollisions:v,...y}=e,b=Oa(Va,n),[S,C]=g.useState(null),[w,T]=g.useState(null),D=a(t,C),[O,k]=g.useState(null),[A,j]=g.useState(null),M=Sa(n),[N,P]=g.useState(!1),ee=g.useRef(!1);g.useEffect(()=>{if(S)return Ji(S)},[S]),Mr();let F=g.useCallback(e=>{let[t,...n]=M().map(e=>e.ref.current),[r]=n.slice(-1),i=document.activeElement;for(let n of e)if(n===i||(n?.scrollIntoView({block:`nearest`}),n===t&&w&&(w.scrollTop=0),n===r&&w&&(w.scrollTop=w.scrollHeight),n?.focus(),document.activeElement!==i))return},[M,w]),I=g.useCallback(()=>F([O,S]),[F,O,S]);g.useEffect(()=>{N&&I()},[N,I]);let{onOpenChange:L,triggerPointerDownPosRef:R}=b;g.useEffect(()=>{if(S){let e={x:0,y:0},t=Q(t=>{e={x:Math.abs(Math.round(t.pageX)-(R.current?.x??0)),y:Math.abs(Math.round(t.pageY)-(R.current?.y??0))}},`handlePointerMove`),n=Q(n=>{e.x<=10&&e.y<=10?n.preventDefault():n.composedPath().includes(S)||L(!1),document.removeEventListener(`pointermove`,t),R.current=null},`handlePointerUp`);return R.current!==null&&(document.addEventListener(`pointermove`,t),document.addEventListener(`pointerup`,n,{capture:!0,once:!0})),()=>{document.removeEventListener(`pointermove`,t),document.removeEventListener(`pointerup`,n,{capture:!0})}}},[S,L,R]),g.useEffect(()=>{let e=Q(()=>L(!1),`close`);return window.addEventListener(`blur`,e),window.addEventListener(`resize`,e),()=>{window.removeEventListener(`blur`,e),window.removeEventListener(`resize`,e)}},[L]);let[te,ne]=Co(e=>{let t=M().filter(e=>!e.disabled),n=wo(t,e,t.find(e=>e.ref.current===document.activeElement));n&&setTimeout(()=>n.ref.current?.focus())}),ie=g.useCallback((e,t,n)=>{let r=!ee.current&&!n;(b.value!==void 0&&b.value===t||r)&&(k(e),r&&(ee.current=!0))},[b.value]),ae=g.useCallback(()=>S?.focus(),[S]),oe=g.useCallback((e,t,n)=>{let r=!ee.current&&!n;(b.value!==void 0&&b.value===t||r)&&j(e)},[b.value]),se=r===`popper`?Ya:Ja,ce=se===Ya?{side:c,sideOffset:l,align:u,alignOffset:d,arrowPadding:f,collisionBoundary:p,collisionPadding:m,sticky:
vendor: 6,655 bytes, line 41
41h,hideWhenDetached:_,avoidCollisions:v}:{};return(0,E.jsx)(Wa,{scope:n,content:S,viewport:w,onViewportChange:T,itemRefCallback:ie,selectedItem:O,onItemLeave:ae,itemTextRefCallback:oe,focusSelectedItem:I,selectedItemText:A,position:r,isPositioned:N,searchRef:te,children:(0,E.jsx)(zi,{as:Ka,allowPinchZoom:!0,children:(0,E.jsx)(gr,{asChild:!0,trapped:b.open,onMountAutoFocus:e=>{e.preventDefault()},onUnmountAutoFocus:x(i,e=>{b.trigger?.focus({preventScroll:!0}),e.preventDefault()}),children:(0,E.jsx)(re,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:o,onPointerDownOutside:s,onFocusOutside:e=>e.preventDefault(),onDismiss:()=>b.onOpenChange(!1),children:(0,E.jsx)(se,{role:`listbox`,id:b.contentId,"data-state":b.open?`open`:`closed`,dir:b.dir,onContextMenu:e=>e.preventDefault(),...y,...ce,onPlaced:()=>P(!0),ref:D,style:{display:`flex`,flexDirection:`column`,outline:`none`,...y.style},onKeyDown:x(y.onKeyDown,e=>{let t=e.ctrlKey||e.altKey||e.metaKey;if(e.key===`Tab`&&e.preventDefault(),!t&&e.key.length===1&&ne(e.key),[`ArrowUp`,`ArrowDown`,`Home`,`End`].includes(e.key)){let t=M().filter(e=>!e.disabled).map(e=>e.ref.current);if([`ArrowUp`,`End`].includes(e.key)&&(t=t.slice().reverse()),[`ArrowUp`,`ArrowDown`].includes(e.key)){let n=e.target,r=t.indexOf(n);t=t.slice(r+1)}setTimeout(()=>F(t)),e.preventDefault()}})})})})})})},`SelectContentImpl`)),Ja=g.forwardRef(Q(function(e,t){let{__scopeSelect:n,onPlaced:r,...i}=e,o=Oa(Va,n),s=Ga(Va,n),[c,l]=g.useState(null),[u,d]=g.useState(null),p=a(t,d),m=Sa(n),h=g.useRef(!1),_=g.useRef(!0),{viewport:v,selectedItem:y,selectedItemText:b,focusSelectedItem:x}=s,S=g.useCallback(()=>{if(o.trigger&&o.valueNode&&c&&u&&v&&y&&b){let e=o.trigger.getBoundingClientRect(),t=u.getBoundingClientRect(),n=o.valueNode.getBoundingClientRect(),i=b.getBoundingClientRect();if(o.dir!==`rtl`){let r=i.left-t.left,a=n.left-r,o=e.left-a,s=e.width+o,l=Math.max(s,t.width),u=window.innerWidth-$,d=pa(a,[$,Math.max($,u-l)]);c.style.minWidth=s+`px`,c.style.left=d+`px`}else{let r=t.right-i.right,a=window.innerWidth-n.right-r,o=window.innerWidth-e.right-a,s=e.width+o,l=Math.max(s,t.width),u=window.innerWidth-$,d=pa(a,[$,Math.max($,u-l)]);c.style.minWidth=s+`px`,c.style.right=d+`px`}let a=m(),s=window.innerHeight-$*2,l=v.scrollHeight,d=window.getComputedStyle(u),f=parseInt(d.borderTopWidth,10),p=parseInt(d.paddingTop,10),g=parseInt(d.borderBottomWidth,10),_=parseInt(d.paddingBottom,10),x=f+p+l+_+g,S=Math.min(y.offsetHeight*5,x),C=window.getComputedStyle(v),w=parseInt(C.paddingTop,10),T=parseInt(C.paddingBottom,10),E=e.top+e.height/2-$,D=s-E,O=y.offsetHeight/2,k=y.offsetTop+O,A=f+p+k,j=x-A;if(A<=E){let e=a.length>0&&y===a[a.length-1].ref.current;c.style.bottom=`0px`;let t=u.clientHeight-v.offsetTop-v.offsetHeight,n=A+Math.max(D,O+(e?T:0)+t+g);c.style.height=n+`px`}else{let e=a.length>0&&y===a[0].ref.current;c.style.top=`0px`;let t=Math.max(E,f+v.offsetTop+(e?w:0)+O)+j;c.style.height=t+`px`,v.scrollTop=A-E+v.offsetTop}c.style.margin=`${$}px 0`,c.style.minHeight=S+`px`,c.style.maxHeight=s+`px`,r?.(),requestAnimationFrame(()=>h.current=!0)}},[m,o.trigger,o.valueNode,c,u,v,y,b,o.dir,r]);z(()=>S(),[S]);let[C,w]=g.useState();return z(()=>{u&&w(window.getComputedStyle(u).zIndex)},[u]),(0,E.jsx)(Xa,{scope:n,contentWrapper:c,shouldExpandOnScrollRef:h,onScrollButtonChange:g.useCallback(e=>{e&&_.current===!0&&(S(),x?.(),_.current=!1)},[S,x]),children:(0,E.jsx)(`div`,{ref:l,style:{display:`flex`,flexDirection:`column`,position:`fixed`,zIndex:C},children:(0,E.jsx)(f.div,{...i,ref:p,style:{boxSizing:`border-box`,maxHeight:`100%`,...i.style}})})})},`SelectItemAlignedPosition`)),Ya=g.forwardRef(Q(function(e,t){let{__scopeSelect:n,align:r=`start`,collisionPadding:i=$,...a}=e,o=Ea(n);return(0,E.jsx)(Vn,{...o,...a,ref:t,align:r,collisionPadding:i,style:{boxSizing:`border-box`,...a.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)`}})},`SelectPopperPosition`)),[Xa,Za]=wa(Va,{}),Qa=`SelectViewport`,$a=g.forwardRef(Q(function(e,t){let{__scopeSelect:n,nonce:r,...i}=e,o=Ga(Qa,n),s=Za(Qa,n),c=a(t,o.onViewportChange),l=g.useRef(0);return(0,E.jsxs)(E.Fragment,{children:[(0,E.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:r}),(0,E.jsx)(xa.Slot,{scope:n,children:(0,E.jsx)(f.div,{"data-radix-select-viewport":``,role:`presentation`,...i,ref:c,style:{position:`relative`,flex:1,overflow:`hidden auto`,...i.style},onScroll:x(i.onScroll,e=>{let t=e.currentTarget,{contentWrapper:n,shouldExpandOnScrollRef:r}=s;if(r?.current&&n){let e=Math.abs(l.current-t.scrollTop);if(e>0){let r=window.innerHeight-$*2,i=parseFloat(n.style.minHeight),a=parseFloat(n.style.height),o=Math.max(i,a);if(o<r){let i=o+e,a=Math.min(r,i),s=i-a;n.style.height=a+`px`,n.style.bottom===`0px`&&(t.scrollTop=s>0?s:0,n.style.justifyContent=`flex-end`)}}}l.current=t.scrollTop})})})]})},`SelectViewport`)),[eo,to]=wa(`SelectGroup`),no=`SelectLabel`,ro=g.forwardRef(Q(function(e,t){let{__scopeSelect:n,...r}=e,i=to(no,n);return(0,E.jsx)(f.div,{id:i.id,...r,ref:t})},`SelectLabel`)),io=`SelectItem`,[ao,oo]=wa(io),so=g.forwardRef(Q(function(e,t){let{__scopeSelect:n,value:r,disabled:i=!1,textValue:o,...s}=e,c=Oa(io,n),l=Ga(io,n),u=c.value===r,[d,p]=g.useState(o??``),[m,h]=g.useState(!1),_=a(t,P(e=>l.itemRefCallback?.(e,r,i))),v=me(),y=g.useRef(`touch`),b=Q(()=>{i||(c.onValueChange(r),c.onOpenChange(!1))},`handleSelect`);return(0,E.jsx)(ao,{scope:n,value:r,disabled:i,textId:v,isSelected:u,onItemTextChange:g.useCallback(e=>{p(t=>t||(e?.textContent??``).trim())},[]),children:(0,E.jsx)(xa.ItemSlot,{scope:n,value:r,disabled:i,textValue:d,children:(0,E.jsx)(f.div,{role:`option`,"aria-labelledby":v,"data-highlighted":m?``:void 0,"aria-selected":u&&m,"data-state":u?`checked`:`unchecked`,"aria-disabled":i||void 0,"data-disabled":i?``:void 0,tabIndex:i?void 0:-1,...s,ref:_,onFocus:x(s.onFocus,()=>h(!0)),onBlur:x(s.onBlur,()=>h(!1)),onClick:x(s.onClick,()=>{y.current!==`mouse`&&b()}),onPointerUp:x(s.onPointerUp,()=>{y.current===`mouse`&&b()}),onPointerDown:x(s.onPointerDown,e=>{y.current=e.pointerType}),onPointerMove:x(s.onPointerMove,e=>{y.current=e.pointerType,i?l.onItemLeave?.():y.current===`mouse`&&e.currentTarget.focu
41s({preventScroll:!0})}),onPointerLeave:x(s.onPointerLeave,e=>{e.currentTarget===document.activeElement&&l.onItemLeave?.()}),onKeyDown:x(s.onKeyDown,e=>{i||e.target!==e.currentTarget||(l.searchRef?.current===``||e.key!==` `)&&(ya.includes(e.key)&&b(),e.key===` `&&e.preventDefault())})})})})},`SelectItem`)),co=`SelectItemText`,lo=g.forwardRef(Q(function(e,t){let{__scopeSelect:n,className:r,style:i,...o}=e,s=Oa(co,n),c=Ga(co,n),l=oo(co,n),u=Aa(co,n),[d,p]=g.useState(null),m=P(e=>c.itemTextRefCallback?.(e,l.value,l.disabled)),h=a(t,p,l.onItemTextChange,m),v=d?.textContent,y=g.useMemo(()=>(0,E.jsx)(`option`,{value:l.value,disabled:l.disabled,children:v},l.value),[l.disabled,l.value,v]),{onNativeOptionAdd:b,onNativeOptionRemove:x}=u;return z(()=>(b(y),()=>x(y)),[b,x,y]),(0,E.jsxs)(E.Fragment,{children:[(0,E.jsx)(f.span,{id:l.textId,...o,ref:h}),l.isSelected&&s.valueNode&&!s.valueNodeHasChildren&&!So(s.value)?_.createPortal(o.children,s.valueNode):null]})},`SelectItemText`)),uo=`SelectItemIndicator`,fo=g.forwardRef(Q(function(e,t){let{__scopeSelect:n,...r}=e;return oo(uo,n).isSelected?(0,E.jsx)(f.span,{"aria-hidden":!0,...r,ref:t}):null},`SelectItemIndicator`)),po=`SelectScrollUpButton`,mo=g.forwardRef(Q(function(e,t){let n=Ga(po,e.__scopeSelect),r=Za(po,e.__scopeSelect),[i,o]=g.useState(!1),s=a(t,r.onScrollButtonChange);return z(()=>{if(n.viewport&&n.isPositioned){let e=function(){let e=t.scrollTop>0;o(e)};Q(e,`handleScroll`);let t=n.viewport;return e(),t.addEventListener(`scroll`,e),()=>t.removeEventListener(`scroll`,e)}},[n.viewport,n.isPositioned]),i?(0,E.jsx)(_o,{...e,ref:s,onAutoScroll:()=>{let{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop-=t.offsetHeight)}}):null},`SelectScrollUpButton`)),ho=`SelectScrollDownButton`,go=g.forwardRef(Q(function(e,t){let n=Ga(ho,e.__scopeSelect),r=Za(ho,e.__scopeSelect),[i,o]=g.useState(!1),s=a(t,r.onScrollButtonChange);return z(()=>{if(n.viewport&&n.isPositioned){let e=function(){let e=t.scrollHeight-t.clientHeight,n=Math.ceil(t.scrollTop)<e;o(n)};Q(e,`handleScroll`);let t=n.viewport;return e(),t.addEventListener(`scroll`,e),()=>t.removeEventListener(`scroll`,e)}},[n.viewport,n.isPositioned]),i?(0,E.jsx)(_o,{...e,ref:s,onAutoScroll:()=>{let{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop+=t.offsetHeight)}}):null},`SelectScrollDownButton`)),_o=g.forwardRef(Q(function(e,t){let{__scopeSelect:n,onAutoScroll:r,...i}=e,a=Ga(`SelectScrollButton`,n),o=g.useRef(null),s=Sa(n),c=g.useCallback(()=>{o.current!==null&&(window.clearInterval(o.current),o.current=null)},[]);return g.useEffect(()=>()=>c(),[c]),z(()=>{s().find(e=>e.ref.current===document.activeElement)?.ref.current?.scrollIntoView({block:`nearest`})},[s]),(0,E.jsx)(f.div,{"aria-hidden":!0,...i,ref:t,style:{flexShrink:0,...i.style},onPointerDown:x(i.onPointerDown,()=>{o.current===null&&(o.current=window.setInterval(r,50))}),onPointerMove:x(i.onPointerMove,()=>{a.onItemLeave?.(),o.current===null&&(o.current=window.setInterval(r,50))}),onPointerLeave:x(i.onPointerLeave,()=>{c()})})},`SelectScrollButtonImpl`)),vo=g.forwardRef(Q(function(e,t){let{__scopeSelect:n,...r}=e;return(0,E.jsx)(f.div,{"aria-hidden":!0,...r,ref:t})},`SelectSeparator`)),yo=`SelectBubbleInput`,bo=g.forwardRef(Q(function({__scopeSelect:e,...t},n){let r=Oa(yo,e),{value:i,onValueChange:o,required:s,disabled:c,name:l,autoComplete:u,form:d}=r,{nativeOptions:p,nativeSelectKey:m}=r,h=g.useRef(null),_=a(n,h),v=i??``,y=ga(v),b=Array.from(p).some(e=>(e.props.value??``)===``);return g.useEffect(()=>{let e=h.current;if(!e)return;let t=window.HTMLSelectElement.prototype,n=Object.getOwnPropertyDescriptor(t,`value`).set;if(y!==v&&n){let t=new Event(`change`,{bubbles:!0});n.call(e,v),e.dispatchEvent(t)}},[y,v]),(0,E.jsxs)(f.select,{"aria-hidden":!0,required:s,tabIndex:-1,name:l,autoComplete:u,disabled:c,form:d,onChange:e=>o(e.target.value),...t,style:{...dr,...t.style},ref:_,defaultValue:v,children:[So(i)&&!b?(0,E.jsx)(`option`,{value:``}):null,Array.from(p)]},m)},`SelectBubbleInput`));function xo(e){return typeof e==`function`}Q(xo,`isFunction`);function So(e){return e===``||e===void 0}Q(So,`shouldShowPlaceholder`);function Co(e){let t=P(e),n=g.useRef(``),r=g.useRef(0),i=g.useCallback(e=>{let i=n.current+e;t(i),Q((function e(t){n.current=t,window.clearTimeout(r.current),t!==``&&(r.current=window.setTimeout(()=>e(``),1e3))}),`updateSearch`)(i)},[t]),a=g.useCallback(()=>{n.current=``,window.clearTimeout(r.current)},[]);return g.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,i,a]}Q(Co,`useTypeaheadSearch`);function wo(e,t,n){let r=t.length>1&&Array.from(t).every(e=>e===t[0])?t[0]:t,i=n?e.indexOf(n):-1,a=To(e,Math.max(i,0));r.length===1&&(a=a.filter(e=>e!==n));let o=a.find(e=>e.textValue.toLowerCase().startsWith(r.toLowerCase()));return o===n?void 0:o}Q(wo,`findNextItem`);function To(e,t){return e.map((n,r)=>e[(t+r)%e.length])}Q(To,`wrapArray`);var Eo=Ma,Do=Ia,Oo=g.forwardRef(({className:e,children:t,...n},r)=>(0,E.jsxs)(Pa,{ref:r,className:i(`flex h-9 w-full items-center justify-between whitespace-nowrap rounded-md border border-input bg-transparent px-3 py-2 text-sm shadow-sm ring-offset-background cursor-pointer data-[placeholder]:text-muted-foreground focus:outline-none focus:ring-1 focus:ring-ring disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1`,e),...n,children:[t,(0,E.jsx)(La,{asChild:!0,children:(0,E.jsx)(m,{className:`h-4 w-4 opacity-50`})})]}));Oo.displayName=Pa.displayName;var ko=g.forwardRef(({className:e,...t},n)=>(0,E.jsx)(mo,{ref:n,className:i(`flex cursor-default items-center justify-center py-1`,e),...t,children:(0,E.jsx)(h,{className:`h-4 w-4`})}));ko.displayName=mo.displayName;var Ao=g.forwardRef(({className:e,...t},n)=>(0,E.jsx)(go,{ref:n,className:i(`flex cursor-default items-center justify-center py-1`,e),...t,children:(0,E.jsx)(m,{className:`h-4 w-4`})}));Ao.displayName=go.displayName;var jo=g.forwardRef(({className:e,children:t,position:n=`popper`,...r},a)=>(0,E.jsx)(Ba,{children:(0,E.jsxs)(Ha,{ref:a,className:i(`relative z-50 max-h-(--radix-select-content-available-height) min-w-[8rem] overflow-y-auto overflow-x-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:sli
41de-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 origin-(--radix-select-content-transform-origin)`,n===`popper`&&`data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1`,e),position:n,...r,children:[(0,E.jsx)(ko,{}),(0,E.jsx)($a,{className:i(`p-1`,n===`popper`&&`h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]`),children:t}),(0,E.jsx)(Ao,{})]})}));jo.displayName=Ha.displayName;var Mo=g.forwardRef(({className:e,...t},n)=>(0,E.jsx)(ro,{ref:n,className:i(`px-2 py-1.5 text-sm font-semibold`,e),...t}));Mo.displayName=ro.displayName;var No=g.forwardRef(({className:e,children:t,...n},r)=>(0,E.jsxs)(so,{ref:r,className:i(`relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-2 pr-8 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50`,e),...n,children:[(0,E.jsx)(`span`,{className:`absolute right-2 flex h-3.5 w-3.5 items-center justify-center`,children:(0,E.jsx)(fo,{children:(0,E.jsx)(p,{className:`h-4 w-4`})})}),(0,E.jsx)(lo,{children:t})]}));No.displayName=so.displayName;var Po=g.forwardRef(({className:e,...t},n)=>(0,E.jsx)(vo,{ref:n,className:i(`-mx-1 my-1 h-px bg-muted`,e),...t}));Po.displayName=vo.displayName;export{p as _,Do as a,or as c,me as d,z as f,m as g,x as h,Oo as i,Kn as l,A as m,jo as n,ua as o,P as p,No as r,Xi as s,Eo as t,xn as u};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.