PageSourceSearch

https://www.flexcar.com/cdn/cfa/c9cd0935cb1346044d74dcab52f77f3fb8cb7ff9/assets/popover-Bz_Auyo_.js

js flexcar.com collected 2026-09-24 09:46:59 UTC 45,001 bytes, 6 lines download raw bytes

1
2!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="ca7bbccf-ab7f-59cd-b816-b32b334866d9")}catch(e){}}();
3import{r as u,j as A}from"./chunk-62JRHF6Z-Cg50Stu2.js";import{r as gt,R as mn}from"./index-B-9bbPAc.js";import{u as le,a as ue,b as hn,c as gn}from"./index-BM383GJL.js";import{u as vn}from"./index-7ATJMyab.js";import{u as xn}from"./index-Dm-I-jvQ.js";import{h as yn,R as wn}from"./index-DJMJsl4U.js";import{c as De}from"./spacer-y5aqkyMZ.js";function G(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),n===!1||!r.defaultPrevented)return t?.(r)}}function et(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function vt(...e){return t=>{let n=!1;const o=e.map(r=>{const s=et(r,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let r=0;r<o.length;r++){const s=o[r];typeof s=="function"?s():et(e[r],null)}}}}function ee(...e){return u.useCallback(vt(...e),e)}function xt(e,t=[]){let n=[];function o(s,i){const c=u.createContext(i),l=n.length;n=[...n,i];const a=p=>{const{scope:m,children:d,...g}=p,h=m?.[e]?.[l]||c,x=u.useMemo(()=>g,Object.values(g));return A.jsx(h.Provider,{value:x,children:d})};a.displayName=s+"Provider";function f(p,m){const d=m?.[e]?.[l]||c,g=u.useContext(d);if(g)return g;if(i!==void 0)return i;throw new Error(`\`${p}\` must be used within \`${s}\``)}return[a,f]}const r=()=>{const s=n.map(i=>u.createContext(i));return function(c){const l=c?.[e]||s;return u.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return r.scopeName=e,[o,bn(r,...t)]}function bn(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const o=e.map(r=>({useScope:r(),scopeName:r.scopeName}));return function(s){const i=o.reduce((c,{useScope:l,scopeName:a})=>{const p=l(s)[`__scope${a}`];return{...c,...p}},{});return u.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}var je=u.forwardRef((e,t)=>{const{children:n,...o}=e,r=u.Children.toArray(n),s=r.find(En);if(s){const i=s.props.children,c=r.map(l=>l===s?u.Children.count(i)>1?u.Children.only(null):u.isValidElement(i)?i.props.children:null:l);return A.jsx(Fe,{...o,ref:t,children:u.isValidElement(i)?u.cloneElement(i,void 0,c):null})}return A.jsx(Fe,{...o,ref:t,children:n})});je.displayName="Slot";var Fe=u.forwardRef((e,t)=>{const{children:n,...o}=e;if(u.isValidElement(n)){const r=Cn(n),s=An(o,n.props);return n.type!==u.Fragment&&(s.ref=t?vt(t,r):r),u.cloneElement(n,s)}return u.Children.count(n)>1?u.Children.only(null):null});Fe.displayName="SlotClone";var Pn=({children:e})=>A.jsx(A.Fragment,{children:e});function En(e){return u.isValidElement(e)&&e.type===Pn}function An(e,t){const n={...t};for(const o in t){const r=e[o],s=t[o];/^on[A-Z]/.test(o)?r&&s?n[o]=(...c)=>{s(...c),r(...c)}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...e,...n}}function Cn(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)}var On=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],X=On.reduce((e,t)=>{const n=u.forwardRef((o,r)=>{const{asChild:s,...i}=o,c=s?je:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),A.jsx(c,{...i,ref:r})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function Rn(e,t){e&&gt.flushSync(()=>e.dispatchEvent(t))}var Sn="DismissableLayer",Me="dismissableLayer.update",Nn="dismissableLayer.pointerDownOutside",Tn="dismissableLayer.focusOutside",tt,yt=u.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),wt=u.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:o,onPointerDownOutside:r,onFocusOutside:s,onInteractOutside:i,onDismiss:c,...l}=e,a=u.useContext(yt),[f,p]=u.useState(null),m=f?.ownerDocument??globalThis?.document,[,d]=u.useState({}),g=ee(t,P=>p(P)),h=Array.from(a.layers),[x]=[...a.layersWithOutsidePointerEventsDisabled].slice(-1),v=h.indexOf(x),b=f?h.indexOf(f):-1,w=a.layersWithOutsidePointerEventsDisabled.size>0,y=b>=v,E=Mn(P=>{const R=P.target,M=[...a.branches].some(S=>S.contains(R));!y||M||(r?.(P),i?.(P),P.defaultPrevented||c?.())},m),O=Ln(P=>{const R=P.target;[...a.branches].some(S=>S.contains(R))||(s?.(P),i?.(P),P.defaultPrevented||c?.())},m);return vn(P=>{b===a.layers.size-1&&(o?.(P),!P.defaultPrevented&&c&&(P.preventDefault(),c()))},m),u.useEffect(()=>{if(f)return n&&(a.layersWithOutsidePointerEventsDisabled.size===0&&(tt=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),a.layersWithOutsidePointerEventsDisabled.add(f)),a.layers.add(f),nt(),()=>{n&&a.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=tt)}},[f,m,n,a]),u.useEffect(()=>()=>{f&&(a.layers.delete(f),a.layersWithOutsidePointerEventsDisabled.delete(f),nt())},[f,a]),u.useEffect(()=>{const P=()=>d({});return document.addEventListener(Me,P),()=>document.removeEventListener(Me,P)},[]),A.jsx(X.div,{...l,ref:g,style:{pointerEvents:w?y?"auto":"none":void 0,...e.style},onFocusCapture:G(e.onFocusCapture,O.onFocusCapture),onBlurCapture:G(e.onBlurCapture,O.onBlurCapture),onPointerDownCapture:G(e.onPointerDownCapture,E.onPointerDownCapture)})});wt.displayName=Sn;var Dn="DismissableLayerBranch",Fn=u.forwardRef((e,t)=>
3{const n=u.useContext(yt),o=u.useRef(null),r=ee(t,o);return u.useEffect(()=>{const s=o.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),A.jsx(X.div,{...e,ref:r})});Fn.displayName=Dn;function Mn(e,t=globalThis?.document){const n=le(e),o=u.useRef(!1),r=u.useRef(()=>{});return u.useEffect(()=>{const s=c=>{if(c.target&&!o.current){let l=function(){bt(Nn,n,a,{discrete:!0})};const a={originalEvent:c};c.pointerType==="touch"?(t.removeEventListener("click",r.current),r.current=l,t.addEventListener("click",r.current,{once:!0})):l()}else t.removeEventListener("click",r.current);o.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",s),t.removeEventListener("click",r.current)}},[t,n]),{onPointerDownCapture:()=>o.current=!0}}function Ln(e,t=globalThis?.document){const n=le(e),o=u.useRef(!1);return u.useEffect(()=>{const r=s=>{s.target&&!o.current&&bt(Tn,n,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",r),()=>t.removeEventListener("focusin",r)},[t,n]),{onFocusCapture:()=>o.current=!0,onBlurCapture:()=>o.current=!1}}function nt(){const e=new CustomEvent(Me);document.dispatchEvent(e)}function bt(e,t,n,{discrete:o}){const r=n.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&r.addEventListener(e,t,{once:!0}),o?Rn(r,s):r.dispatchEvent(s)}var Oe=0;function _n(){u.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??ot()),document.body.insertAdjacentElement("beforeend",e[1]??ot()),Oe++,()=>{Oe===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Oe--}},[])}function ot(){const 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}var Re="focusScope.autoFocusOnMount",Se="focusScope.autoFocusOnUnmount",rt={bubbles:!1,cancelable:!0},kn="FocusScope",Pt=u.forwardRef((e,t)=>{const{loop:n=!1,trapped:o=!1,onMountAutoFocus:r,onUnmountAutoFocus:s,...i}=e,[c,l]=u.useState(null),a=le(r),f=le(s),p=u.useRef(null),m=ee(t,h=>l(h)),d=u.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;u.useEffect(()=>{if(o){let h=function(w){if(d.paused||!c)return;const y=w.target;c.contains(y)?p.current=y:q(p.current,{select:!0})},x=function(w){if(d.paused||!c)return;const y=w.relatedTarget;y!==null&&(c.contains(y)||q(p.current,{select:!0}))},v=function(w){if(document.activeElement===document.body)for(const E of w)E.removedNodes.length>0&&q(c)};document.addEventListener("focusin",h),document.addEventListener("focusout",x);const b=new MutationObserver(v);return c&&b.observe(c,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",h),document.removeEventListener("focusout",x),b.disconnect()}}},[o,c,d.paused]),u.useEffect(()=>{if(c){it.add(d);const h=document.activeElement;if(!c.contains(h)){const v=new CustomEvent(Re,rt);c.addEventListener(Re,a),c.dispatchEvent(v),v.defaultPrevented||(In(Bn(Et(c)),{select:!0}),document.activeElement===h&&q(c))}return()=>{c.removeEventListener(Re,a),setTimeout(()=>{const v=new CustomEvent(Se,rt);c.addEventListener(Se,f),c.dispatchEvent(v),v.defaultPrevented||q(h??document.body,{select:!0}),c.removeEventListener(Se,f),it.remove(d)},0)}}},[c,a,f,d]);const g=u.useCallback(h=>{if(!n&&!o||d.paused)return;const x=h.key==="Tab"&&!h.altKey&&!h.ctrlKey&&!h.metaKey,v=document.activeElement;if(x&&v){const b=h.currentTarget,[w,y]=jn(b);w&&y?!h.shiftKey&&v===y?(h.preventDefault(),n&&q(w,{select:!0})):h.shiftKey&&v===w&&(h.preventDefault(),n&&q(y,{select:!0})):v===b&&h.preventDefault()}},[n,o,d.paused]);return A.jsx(X.div,{tabIndex:-1,...i,ref:m,onKeyDown:g})});Pt.displayName=kn;function In(e,{select:t=!1}={}){const n=document.activeElement;for(const o of e)if(q(o,{select:t}),document.activeElement!==n)return}function jn(e){const t=Et(e),n=st(t,e),o=st(t.reverse(),e);return[n,o]}function Et(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:o=>{const r=o.tagName==="INPUT"&&o.type==="hidden";return o.disabled||o.hidden||r?NodeFilter.FILTER_SKIP:o.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function st(e,t){for(const n of e)if(!$n(n,{upTo:t}))return n}function $n(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}function Wn(e){return e instanceof HTMLInputElement&&"select"in e}function q(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Wn(e)&&t&&e.select()}}var it=Hn();function Hn(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=ct(e,t),e.unshift(t)},remove(t){e=ct(e,t),e[0]?.resume()}}}function ct(e,t){const n=[...e],o=n.indexOf(t);return o!==-1&&n.splice(o,1),n}function Bn(e){return e.filter(t=>t.tagName!=="A")}const Un=["top","right","bottom","left"],Z=Math.min,I=Math.max,ye=Math.round,ge=Math.floor,U=e=>({x:e,y:e}
3),zn={left:"right",right:"left",bottom:"top",top:"bottom"},Vn={start:"end",end:"start"};function Le(e,t,n){return I(e,Z(t,n))}function K(e,t){return typeof e=="function"?e(t):e}function Y(e){return e.split("-")[0]}function ie(e){return e.split("-")[1]}function $e(e){return e==="x"?"y":"x"}function We(e){return e==="y"?"height":"width"}function J(e){return["top","bottom"].includes(Y(e))?"y":"x"}function He(e){return $e(J(e))}function Kn(e,t,n){n===void 0&&(n=!1);const o=ie(e),r=He(e),s=We(r);let i=r==="x"?o===(n?"end":"start")?"right":"left":o==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=we(i)),[i,we(i)]}function Yn(e){const t=we(e);return[_e(e),t,_e(t)]}function _e(e){return e.replace(/start|end/g,t=>Vn[t])}function Xn(e,t,n){const o=["left","right"],r=["right","left"],s=["top","bottom"],i=["bottom","top"];switch(e){case"top":case"bottom":return n?t?r:o:t?o:r;case"left":case"right":return t?s:i;default:return[]}}function qn(e,t,n,o){const r=ie(e);let s=Xn(Y(e),n==="start",o);return r&&(s=s.map(i=>i+"-"+r),t&&(s=s.concat(s.map(_e)))),s}function we(e){return e.replace(/left|right|bottom|top/g,t=>zn[t])}function Gn(e){return{top:0,right:0,bottom:0,left:0,...e}}function At(e){return typeof e!="number"?Gn(e):{top:e,right:e,bottom:e,left:e}}function be(e){const{x:t,y:n,width:o,height:r}=e;return{width:o,height:r,top:n,left:t,right:t+o,bottom:n+r,x:t,y:n}}function at(e,t,n){let{reference:o,floating:r}=e;const s=J(t),i=He(t),c=We(i),l=Y(t),a=s==="y",f=o.x+o.width/2-r.width/2,p=o.y+o.height/2-r.height/2,m=o[c]/2-r[c]/2;let d;switch(l){case"top":d={x:f,y:o.y-r.height};break;case"bottom":d={x:f,y:o.y+o.height};break;case"right":d={x:o.x+o.width,y:p};break;case"left":d={x:o.x-r.width,y:p};break;default:d={x:o.x,y:o.y}}switch(ie(t)){case"start":d[i]-=m*(n&&a?-1:1);break;case"end":d[i]+=m*(n&&a?-1:1);break}return d}const Zn=async(e,t,n)=>{const{placement:o="bottom",strategy:r="absolute",middleware:s=[],platform:i}=n,c=s.filter(Boolean),l=await(i.isRTL==null?void 0:i.isRTL(t));let a=await i.getElementRects({reference:e,floating:t,strategy:r}),{x:f,y:p}=at(a,o,l),m=o,d={},g=0;for(let h=0;h<c.length;h++){const{name:x,fn:v}=c[h],{x:b,y:w,data:y,reset:E}=await v({x:f,y:p,initialPlacement:o,placement:m,strategy:r,middlewareData:d,rects:a,platform:i,elements:{reference:e,floating:t}});f=b??f,p=w??p,d={...d,[x]:{...d[x],...y}},E&&g<=50&&(g++,typeof E=="object"&&(E.placement&&(m=E.placement),E.rects&&(a=E.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:r}):E.rects),{x:f,y:p}=at(a,m,l)),h=-1)}return{x:f,y:p,placement:m,strategy:r,middlewareData:d}};async function fe(e,t){var n;t===void 0&&(t={});const{x:o,y:r,platform:s,rects:i,elements:c,strategy:l}=e,{boundary:a="clippingAncestors",rootBoundary:f="viewport",elementContext:p="floating",altBoundary:m=!1,padding:d=0}=K(t,e),g=At(d),x=c[m?p==="floating"?"reference":"floating":p],v=be(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(x)))==null||n?x:x.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(c.floating)),boundary:a,rootBoundary:f,strategy:l})),b=p==="floating"?{x:o,y:r,width:i.floating.width,height:i.floating.height}:i.reference,w=await(s.getOffsetParent==null?void 0:s.getOffsetParent(c.floating)),y=await(s.isElement==null?void 0:s.isElement(w))?await(s.getScale==null?void 0:s.getScale(w))||{x:1,y:1}:{x:1,y:1},E=be(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:b,offsetParent:w,strategy:l}):b);return{top:(v.top-E.top+g.top)/y.y,bottom:(E.bottom-v.bottom+g.bottom)/y.y,left:(v.left-E.left+g.left)/y.x,right:(E.right-v.right+g.right)/y.x}}const Jn=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:o,placement:r,rects:s,platform:i,elements:c,middlewareData:l}=t,{element:a,padding:f=0}=K(e,t)||{};if(a==null)return{};const p=At(f),m={x:n,y:o},d=He(r),g=We(d),h=await i.getDimensions(a),x=d==="y",v=x?"top":"left",b=x?"bottom":"right",w=x?"clientHeight":"clientWidth",y=s.reference[g]+s.reference[d]-m[d]-s.floating[g],E=m[d]-s.reference[d],O=await(i.getOffsetParent==null?void 0:i.getOffsetParent(a));let P=O?O[w]:0;(!P||!await(i.isElement==null?void 0:i.isElement(O)))&&(P=c.floating[w]||s.floating[g]);const R=y/2-E/2,M=P/2-h[g]/2-1,S=Z(p[v],M),_=Z(p[b],M),k=S,T=P-h[g]-_,N=P/2-h[g]/2+R,$=Le(k,N,T),D=!l.arrow&&ie(r)!=null&&N!==$&&s.reference[g]/2-(N<k?S:_)-h[g]/2<0,F=D?N<k?N-k:N-T:0;return{[d]:m[d]+F,data:{[d]:$,centerOffset:N-$-F,...D&&{alignmentOffset:F}},reset:D}}}),Qn=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,o;const{placement:r,middlewareData:s,rects:i,initialPlacement:c,platform:l,elements:a}=t,{mainAxis:f=!0,crossAxis:p=!0,fallbackPlacements:m,fallbackStrategy:d="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:h=!0,...x}=K(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const v=Y(r),b=J(c),w=Y(c)===c,y=await(l.isRTL==null?void 0:l.isRTL(a.floating)),E=m||(w||!h?[we(c)]:Yn(c)),O=g!=="none";!m&&O&&E.push(...qn(c,h,g,y));const P=[c,...E],R=await fe(t,x),M=[];let S=((o=s.flip)==null?void 0:o.overflows)||[];if(f&&M.push(R[v]),p){const N=Kn(r,i,y);M.push(R[N[0]],R[N[1]])}if(S=[...S,{placement:r,overflows:M}],!M.every(N=>N<=0)){var _,k;const N=(((_=s.flip)==null?void 0:_.index)||0)+1,$=P[N];if($)return{data:{index:N,overflows:S},reset:{placement:$}};let D=(k=S.filter(F=>F.overflows[0]<=0).sort((F,C)=>F.overflows[1]-C.overflows[1])[0])==null?void 0:k.placement;if(!D)switch(d){case"bestFit":{var T;const F=(T=S.filter(C=>{if(O){const L=J(C.placement);return L===b||L==="y"}return!0}).map(C=>[C.placement,C.overflows.filter(L=>L>0).reduce((L,B)=>L+B,0)]).sort((C,L)=>C[1]-L[1])[0])==null?void 0:T[0];F&&(D=F);break}case"initialPlacement":D=c;break}if(r!==D)return{reset:{placement:D}}}return{}}}};function lt(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function ut(e){return Un.some(t=>e[t]>=0)}const eo=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:o="referenceHidden",...r}=K(e,t);switch(o){case"referenceHidden":{const s=await fe(t,{...r,elementContext:"reference"}),i=lt(s,n.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:ut(i)}}}case"escaped":{const s=await fe(t,{...r,altBoundary:!0}),i=lt(s,n.floating);return{data:{escapedOffsets:i,escaped:ut(i)}}}default:return{}}}}};async function to(e,t){const{placement:n,platform:o,elements:r}=e,s=await(o.isRTL==null?void 0:o.isRTL(r.floating)),i=Y(n),c=ie(n),l=J(n)==="y",a=["left","top"].includes(i)?-1:1,f=s&&l?-1:1,p=K(t,e);let{mainAxis:m,crossAxis:d,alignmentAxis:g}=typeof p=="number"?{mainAxis:p,crossAxis:0,alignmentAxis:null}
3:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return c&&typeof g=="number"&&(d=c==="end"?g*-1:g),l?{x:d*f,y:m*a}:{x:m*a,y:d*f}}const no=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,o;const{x:r,y:s,placement:i,middlewareData:c}=t,l=await to(t,e);return i===((n=c.offset)==null?void 0:n.placement)&&(o=c.arrow)!=null&&o.alignmentOffset?{}:{x:r+l.x,y:s+l.y,data:{...l,placement:i}}}}},oo=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:o,placement:r}=t,{mainAxis:s=!0,crossAxis:i=!1,limiter:c={fn:x=>{let{x:v,y:b}=x;return{x:v,y:b}}},...l}=K(e,t),a={x:n,y:o},f=await fe(t,l),p=J(Y(r)),m=$e(p);let d=a[m],g=a[p];if(s){const x=m==="y"?"top":"left",v=m==="y"?"bottom":"right",b=d+f[x],w=d-f[v];d=Le(b,d,w)}if(i){const x=p==="y"?"top":"left",v=p==="y"?"bottom":"right",b=g+f[x],w=g-f[v];g=Le(b,g,w)}const h=c.fn({...t,[m]:d,[p]:g});return{...h,data:{x:h.x-n,y:h.y-o,enabled:{[m]:s,[p]:i}}}}}},ro=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:o,placement:r,rects:s,middlewareData:i}=t,{offset:c=0,mainAxis:l=!0,crossAxis:a=!0}=K(e,t),f={x:n,y:o},p=J(r),m=$e(p);let d=f[m],g=f[p];const h=K(c,t),x=typeof h=="number"?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(l){const w=m==="y"?"height":"width",y=s.reference[m]-s.floating[w]+x.mainAxis,E=s.reference[m]+s.reference[w]-x.mainAxis;d<y?d=y:d>E&&(d=E)}if(a){var v,b;const w=m==="y"?"width":"height",y=["top","left"].includes(Y(r)),E=s.reference[p]-s.floating[w]+(y&&((v=i.offset)==null?void 0:v[p])||0)+(y?0:x.crossAxis),O=s.reference[p]+s.reference[w]+(y?0:((b=i.offset)==null?void 0:b[p])||0)-(y?x.crossAxis:0);g<E?g=E:g>O&&(g=O)}return{[m]:d,[p]:g}}}},so=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,o;const{placement:r,rects:s,platform:i,elements:c}=t,{apply:l=()=>{},...a}=K(e,t),f=await fe(t,a),p=Y(r),m=ie(r),d=J(r)==="y",{width:g,height:h}=s.floating;let x,v;p==="top"||p==="bottom"?(x=p,v=m===(await(i.isRTL==null?void 0:i.isRTL(c.floating))?"start":"end")?"left":"right"):(v=p,x=m==="end"?"top":"bottom");const b=h-f.top-f.bottom,w=g-f.left-f.right,y=Z(h-f[x],b),E=Z(g-f[v],w),O=!t.middlewareData.shift;let P=y,R=E;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(R=w),(o=t.middlewareData.shift)!=null&&o.enabled.y&&(P=b),O&&!m){const S=I(f.left,0),_=I(f.right,0),k=I(f.top,0),T=I(f.bottom,0);d?R=g-2*(S!==0||_!==0?S+_:I(f.left,f.right)):P=h-2*(k!==0||T!==0?k+T:I(f.top,f.bottom))}await l({...t,availableWidth:R,availableHeight:P});const M=await i.getDimensions(c.floating);return g!==M.width||h!==M.height?{reset:{rects:!0}}:{}}}};function Ee(){return typeof window<"u"}function ce(e){return Ct(e)?(e.nodeName||"").toLowerCase():"#document"}function j(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function V(e){var t;return(t=(Ct(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Ct(e){return Ee()?e instanceof Node||e instanceof j(e).Node:!1}function W(e){return Ee()?e instanceof Element||e instanceof j(e).Element:!1}function z(e){return Ee()?e instanceof HTMLElement||e instanceof j(e).HTMLElement:!1}function ft(e){return!Ee()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof j(e).ShadowRoot}function pe(e){const{overflow:t,overflowX:n,overflowY:o,display:r}=H(e);return/auto|scroll|overlay|hidden|clip/.test(t+o+n)&&!["inline","contents"].includes(r)}function io(e){return["table","td","th"].includes(ce(e))}function Ae(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function Be(e){const t=Ue(),n=W(e)?H(e):e;return["transform","translate","scale","rotate","perspective"].some(o=>n[o]?n[o]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","translate","scale","rotate","perspective","filter"].some(o=>(n.willChange||"").includes(o))||["paint","layout","strict","content"].some(o=>(n.contain||"").includes(o))}function co(e){let t=Q(e);for(;z(t)&&!re(t);){if(Be(t))return t;if(Ae(t))return null;t=Q(t)}return null}function Ue(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function re(e){return["html","body","#document"].includes(ce(e))}function H(e){return j(e).getComputedStyle(e)}function Ce(e){return W(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Q(e){if(ce(e)==="html")return e;const t=e.assignedSlot||e.parentNode||ft(e)&&e.host||V(e);return ft(t)?t.host:t}function Ot(e){const t=Q(e);return re(t)?e.ownerDocument?e.ownerDocument.body:e.body:z(t)&&pe(t)?t:Ot(t)}function de(e,t,n){var o;t===void 0&&(t=[]),n===void 0&&(n=!0);const r=Ot(e),s=r===((o=e.ownerDocument)==null?void 0:o.body),i=j(r);if(s){const c=ke(i);
3return t.concat(i,i.visualViewport||[],pe(r)?r:[],c&&n?de(c):[])}return t.concat(r,de(r,[],n))}function ke(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Rt(e){const t=H(e);let n=parseFloat(t.width)||0,o=parseFloat(t.height)||0;const r=z(e),s=r?e.offsetWidth:n,i=r?e.offsetHeight:o,c=ye(n)!==s||ye(o)!==i;return c&&(n=s,o=i),{width:n,height:o,$:c}}function ze(e){return W(e)?e:e.contextElement}function oe(e){const t=ze(e);if(!z(t))return U(1);const n=t.getBoundingClientRect(),{width:o,height:r,$:s}=Rt(t);let i=(s?ye(n.width):n.width)/o,c=(s?ye(n.height):n.height)/r;return(!i||!Number.isFinite(i))&&(i=1),(!c||!Number.isFinite(c))&&(c=1),{x:i,y:c}}const ao=U(0);function St(e){const t=j(e);return!Ue()||!t.visualViewport?ao:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function lo(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==j(e)?!1:t}function ne(e,t,n,o){t===void 0&&(t=!1),n===void 0&&(n=!1);const r=e.getBoundingClientRect(),s=ze(e);let i=U(1);t&&(o?W(o)&&(i=oe(o)):i=oe(e));const c=lo(s,n,o)?St(s):U(0);let l=(r.left+c.x)/i.x,a=(r.top+c.y)/i.y,f=r.width/i.x,p=r.height/i.y;if(s){const m=j(s),d=o&&W(o)?j(o):o;let g=m,h=ke(g);for(;h&&o&&d!==g;){const x=oe(h),v=h.getBoundingClientRect(),b=H(h),w=v.left+(h.clientLeft+parseFloat(b.paddingLeft))*x.x,y=v.top+(h.clientTop+parseFloat(b.paddingTop))*x.y;l*=x.x,a*=x.y,f*=x.x,p*=x.y,l+=w,a+=y,g=j(h),h=ke(g)}}return be({width:f,height:p,x:l,y:a})}function Ve(e,t){const n=Ce(e).scrollLeft;return t?t.left+n:ne(V(e)).left+n}function Nt(e,t,n){n===void 0&&(n=!1);const o=e.getBoundingClientRect(),r=o.left+t.scrollLeft-(n?0:Ve(e,o)),s=o.top+t.scrollTop;return{x:r,y:s}}function uo(e){let{elements:t,rect:n,offsetParent:o,strategy:r}=e;const s=r==="fixed",i=V(o),c=t?Ae(t.floating):!1;if(o===i||c&&s)return n;let l={scrollLeft:0,scrollTop:0},a=U(1);const f=U(0),p=z(o);if((p||!p&&!s)&&((ce(o)!=="body"||pe(i))&&(l=Ce(o)),z(o))){const d=ne(o);a=oe(o),f.x=d.x+o.clientLeft,f.y=d.y+o.clientTop}const m=i&&!p&&!s?Nt(i,l,!0):U(0);return{width:n.width*a.x,height:n.height*a.y,x:n.x*a.x-l.scrollLeft*a.x+f.x+m.x,y:n.y*a.y-l.scrollTop*a.y+f.y+m.y}}function fo(e){return Array.from(e.getClientRects())}function po(e){const t=V(e),n=Ce(e),o=e.ownerDocument.body,r=I(t.scrollWidth,t.clientWidth,o.scrollWidth,o.clientWidth),s=I(t.scrollHeight,t.clientHeight,o.scrollHeight,o.clientHeight);let i=-n.scrollLeft+Ve(e);const c=-n.scrollTop;return H(o).direction==="rtl"&&(i+=I(t.clientWidth,o.clientWidth)-r),{width:r,height:s,x:i,y:c}}function mo(e,t){const n=j(e),o=V(e),r=n.visualViewport;let s=o.clientWidth,i=o.clientHeight,c=0,l=0;if(r){s=r.width,i=r.height;const a=Ue();(!a||a&&t==="fixed")&&(c=r.offsetLeft,l=r.offsetTop)}return{width:s,height:i,x:c,y:l}}function ho(e,t){const n=ne(e,!0,t==="fixed"),o=n.top+e.clientTop,r=n.left+e.clientLeft,s=z(e)?oe(e):U(1),i=e.clientWidth*s.x,c=e.clientHeight*s.y,l=r*s.x,a=o*s.y;return{width:i,height:c,x:l,y:a}}function dt(e,t,n){let o;if(t==="viewport")o=mo(e,n);else if(t==="document")o=po(V(e));else if(W(t))o=ho(t,n);else{const r=St(e);o={x:t.x-r.x,y:t.y-r.y,width:t.width,height:t.height}}return be(o)}function Tt(e,t){const n=Q(e);return n===t||!W(n)||re(n)?!1:H(n).position==="fixed"||Tt(n,t)}function go(e,t){const n=t.get(e);if(n)return n;let o=de(e,[],!1).filter(c=>W(c)&&ce(c)!=="body"),r=null;const s=H(e).position==="fixed";let i=s?Q(e):e;for(;W(i)&&!re(i);){const c=H(i),l=Be(i);!l&&c.position==="fixed"&&(r=null),(s?!l&&!r:!l&&c.position==="static"&&!!r&&["absolute","fixed"].includes(r.position)||pe(i)&&!l&&Tt(e,i))?o=o.filter(f=>f!==i):r=c,i=Q(i)}return t.set(e,o),o}function vo(e){let{element:t,boundary:n,rootBoundary:o,strategy:r}=e;const i=[...n==="clippingAncestors"?Ae(t)?[]:go(t,this._c):[].concat(n),o],c=i[0],l=i.reduce((a,f)=>{const p=dt(t,f,r);return a.top=I(p.top,a.top),a.right=Z(p.right,a.right),a.bottom=Z(p.bottom,a.bottom),a.left=I(p.left,a.left),a},dt(t,c,r));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function xo(e){const{width:t,height:n}=Rt(e);return{width:t,height:n}}function yo(e,t,n){const o=z(t),r=V(t),s=n==="fixed",i=ne(e,!0,s,t);let c={scrollLeft:0,scrollTop:0};const l=U(0);if(o||!o&&!s)if((ce(t)!=="body"||pe(r))&&(c=Ce(t)),o){const m=ne(t,!0,s,t);l.x=m.x+t.clientLeft,l.y=m.y+t.clientTop}else r&&(l.x=Ve(r));const a=r&&!o&&!s?Nt(r,c):U(0),f=i.left+c.scrollLeft-l.x-a.x,p=i.top+c.scrollTop-l.y-a.y;return{x:f,y:p,width:i.width,height:i.height}}function Ne(e){return H(e).position==="static"}function pt(e,t){if(!z(e)||H(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return V(e)===n&&(n=n.ownerDocument.body),n}function Dt(e,t){const n=j(e);if(Ae(e))return n;if(!z(e)){let r=Q(e);for(;r&&!re(r);){if(W(r)&&!Ne(r))return r;r=Q(r)}return n}let o=pt(e,t);for(;o&&io(o)&&Ne(o);)o=pt(o,t);return o&&re(o)&&Ne(o)&&!Be(o)?n:o||co(e)||n}const wo=async function(e){const t=this.getOffsetParent||Dt,n=this.getDimensions,o=await n(e.floating);return{reference:yo(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}};function bo(e){return H(e).direction==="rtl"}const Po={convertOffsetParentRelativeRectToViewportRelativeRect:uo,getDocumentElement:V,getClippingRect:vo,getOffsetParent:Dt,getElementRects:wo,getClientRects:fo,getDimensions:xo,getScale:oe,isElement:W,isRTL:bo};function Ft(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Eo(e,t){let n=null,o;const r=V(e);function s(){var c;clearTimeout(o),(c=n)==null||c.disconnect(),n=null}function i(c,l){c===void 0&&(c=!1),l===void 0&&(l=1),s();const a=e.getBoundingClientRect(),{left:f,top:p,width:m,height:d}=a;if(c||t(),!m||!d)return;const g=ge(p),h=ge(r.clientWidth-(f+m)),x=ge(r.clientHeight-(p+d)),v=ge(f),w={rootMargin:-g+"px "+-h+"px "+-x+"px "+-v+"px",threshold:I(0,Z(1,l))||1};let y=!0;function E(O){const P=O[0].intersectionRatio;if(P!==l){if(!y)return i();P?i(!1,P):o=setTimeout(()=>{i(!1,1e-7)},1e3)}P===1&&!Ft(a,e.getBoundingClientRect())&&i(),y=!1}try{n=new IntersectionObserver(E,{...w,root:r.ownerDocument})}catch{n=new IntersectionObserver(E,w)}n.observe(e)}return i(!0),s}function Ao(e,t,n,o){o===void 0&&(o={});const{ancestorScroll:r=!0,ancestorResize:s=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:l=!1}=o,a=ze(e),f=r||s?[...a?de(a):[],...de(t)]:[];f.forEach(v=>{r&&v.addEventListener("scroll",n,{passive:!0}),s&&v.addEventListener("resize",n)});const p=a&&c?Eo(a,n):null;let m=-1,d=null;i&&(d=new ResizeObserver(v=>{let[b]=v;b&&b.target===a&&d&&(d.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var w;(w=d)==null||w.observe(t)})),n()}),a&&!l&&d.observe(a),d.observe(t));let g,h=l?ne(e):null;l&&x();function x(){const v=ne(e);
3h&&!Ft(h,v)&&n(),h=v,g=requestAnimationFrame(x)}return n(),()=>{var v;f.forEach(b=>{r&&b.removeEventListener("scroll",n),s&&b.removeEventListener("resize",n)}),p?.(),(v=d)==null||v.disconnect(),d=null,l&&cancelAnimationFrame(g)}}const Co=no,Oo=oo,Ro=Qn,So=so,No=eo,mt=Jn,To=ro,Do=(e,t,n)=>{const o=new Map,r={platform:Po,...n},s={...r.platform,_c:o};return Zn(e,t,{...r,platform:s})};var xe=typeof document<"u"?u.useLayoutEffect:u.useEffect;function Pe(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,o,r;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(o=n;o--!==0;)if(!Pe(e[o],t[o]))return!1;return!0}if(r=Object.keys(e),n=r.length,n!==Object.keys(t).length)return!1;for(o=n;o--!==0;)if(!{}.hasOwnProperty.call(t,r[o]))return!1;for(o=n;o--!==0;){const s=r[o];if(!(s==="_owner"&&e.$$typeof)&&!Pe(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function Mt(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function ht(e,t){const n=Mt(e);return Math.round(t*n)/n}function Te(e){const t=u.useRef(e);return xe(()=>{t.current=e}),t}function Fo(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:o=[],platform:r,elements:{reference:s,floating:i}={},transform:c=!0,whileElementsMounted:l,open:a}=e,[f,p]=u.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[m,d]=u.useState(o);Pe(m,o)||d(o);const[g,h]=u.useState(null),[x,v]=u.useState(null),b=u.useCallback(C=>{C!==O.current&&(O.current=C,h(C))},[]),w=u.useCallback(C=>{C!==P.current&&(P.current=C,v(C))},[]),y=s||g,E=i||x,O=u.useRef(null),P=u.useRef(null),R=u.useRef(f),M=l!=null,S=Te(l),_=Te(r),k=Te(a),T=u.useCallback(()=>{if(!O.current||!P.current)return;const C={placement:t,strategy:n,middleware:m};_.current&&(C.platform=_.current),Do(O.current,P.current,C).then(L=>{const B={...L,isPositioned:k.current!==!1};N.current&&!Pe(R.current,B)&&(R.current=B,gt.flushSync(()=>{p(B)}))})},[m,t,n,_,k]);xe(()=>{a===!1&&R.current.isPositioned&&(R.current.isPositioned=!1,p(C=>({...C,isPositioned:!1})))},[a]);const N=u.useRef(!1);xe(()=>(N.current=!0,()=>{N.current=!1}),[]),xe(()=>{if(y&&(O.current=y),E&&(P.current=E),y&&E){if(S.current)return S.current(y,E,T);T()}},[y,E,T,S,M]);const $=u.useMemo(()=>({reference:O,floating:P,setReference:b,setFloating:w}),[b,w]),D=u.useMemo(()=>({reference:y,floating:E}),[y,E]),F=u.useMemo(()=>{const C={position:n,left:0,top:0};if(!D.floating)return C;const L=ht(D.floating,f.x),B=ht(D.floating,f.y);return c?{...C,transform:"translate("+L+"px, "+B+"px)",...Mt(D.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:L,top:B}},[n,c,D.floating,f.x,f.y]);return u.useMemo(()=>({...f,update:T,refs:$,elements:D,floatingStyles:F}),[f,T,$,D,F])}const Mo=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:o,padding:r}=typeof e=="function"?e(n):e;return o&&t(o)?o.current!=null?mt({element:o.current,padding:r}).fn(n):{}:o?mt({element:o,padding:r}).fn(n):{}}}},Lo=(e,t)=>({...Co(e),options:[e,t]}),_o=(e,t)=>({...Oo(e),options:[e,t]}),ko=(e,t)=>({...To(e),options:[e,t]}),Io=(e,t)=>({...Ro(e),options:[e,t]}),jo=(e,t)=>({...So(e),options:[e,t]}),$o=(e,t)=>({...No(e),options:[e,t]}),Wo=(e,t)=>({...Mo(e),options:[e,t]});var Ho="Arrow",Lt=u.forwardRef((e,t)=>{const{children:n,width:o=10,height:r=5,...s}=e;return A.jsx(X.svg,{...s,ref:t,width:o,height:r,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:A.jsx("polygon",{points:"0,0 30,0 15,10"})})});Lt.displayName=Ho;var Bo=Lt,Ke="Popper",[_t,kt]=xt(Ke),[Uo,It]=_t(Ke),jt=e=>{const{__scopePopper:t,children:n}=e,[o,r]=u.useState(null);return A.jsx(Uo,{scope:t,anchor:o,onAnchorChange:r,children:n})};jt.displayName=Ke;var $t="PopperAnchor",Wt=u.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:o,...r}=e,s=It($t,n),i=u.useRef(null),c=ee(t,i);return u.useEffect(()=>{s.onAnchorChange(o?.current||i.current)}),o?null:A.jsx(X.div,{...r,ref:c})});Wt.displayName=$t;var Ye="PopperContent",[zo,Vo]=_t(Ye),Ht=u.forwardRef((e,t)=>
3{const{__scopePopper:n,side:o="bottom",sideOffset:r=0,align:s="center",alignOffset:i=0,arrowPadding:c=0,avoidCollisions:l=!0,collisionBoundary:a=[],collisionPadding:f=0,sticky:p="partial",hideWhenDetached:m=!1,updatePositionStrategy:d="optimized",onPlaced:g,...h}=e,x=It(Ye,n),[v,b]=u.useState(null),w=ee(t,ae=>b(ae)),[y,E]=u.useState(null),O=xn(y),P=O?.width??0,R=O?.height??0,M=o+(s!=="center"?"-"+s:""),S=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},_=Array.isArray(a)?a:[a],k=_.length>0,T={padding:S,boundary:_.filter(Yo),altBoundary:k},{refs:N,floatingStyles:$,placement:D,isPositioned:F,middlewareData:C}=Fo({strategy:"fixed",placement:M,whileElementsMounted:(...ae)=>Ao(...ae,{animationFrame:d==="always"}),elements:{reference:x.anchor},middleware:[Lo({mainAxis:r+R,alignmentAxis:i}),l&&_o({mainAxis:!0,crossAxis:!1,limiter:p==="partial"?ko():void 0,...T}),l&&Io({...T}),jo({...T,apply:({elements:ae,rects:Qe,availableWidth:un,availableHeight:fn})=>{const{width:dn,height:pn}=Qe.reference,he=ae.floating.style;he.setProperty("--radix-popper-available-width",`${un}px`),he.setProperty("--radix-popper-available-height",`${fn}px`),he.setProperty("--radix-popper-anchor-width",`${dn}px`),he.setProperty("--radix-popper-anchor-height",`${pn}px`)}}),y&&Wo({element:y,padding:c}),Xo({arrowWidth:P,arrowHeight:R}),m&&$o({strategy:"referenceHidden",...T})]}),[L,B]=zt(D),Je=le(g);ue(()=>{F&&Je?.()},[F,Je]);const rn=C.arrow?.x,sn=C.arrow?.y,cn=C.arrow?.centerOffset!==0,[an,ln]=u.useState();return ue(()=>{v&&ln(window.getComputedStyle(v).zIndex)},[v]),A.jsx("div",{ref:N.setFloating,"data-radix-popper-content-wrapper":"",style:{...$,transform:F?$.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:an,"--radix-popper-transform-origin":[C.transformOrigin?.x,C.transformOrigin?.y].join(" "),...C.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:A.jsx(zo,{scope:n,placedSide:L,onArrowChange:E,arrowX:rn,arrowY:sn,shouldHideArrow:cn,children:A.jsx(X.div,{"data-side":L,"data-align":B,...h,ref:w,style:{...h.style,animation:F?void 0:"none"}})})})});Ht.displayName=Ye;var Bt="PopperArrow",Ko={top:"bottom",right:"left",bottom:"top",left:"right"},Ut=u.forwardRef(function(t,n){const{__scopePopper:o,...r}=t,s=Vo(Bt,o),i=Ko[s.placedSide];return A.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[i]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:A.jsx(Bo,{...r,ref:n,style:{...r.style,display:"block"}})})});Ut.displayName=Bt;function Yo(e){return e!==null}var Xo=e=>({name:"transformOrigin",options:e,fn(t){const{placement:n,rects:o,middlewareData:r}=t,i=r.arrow?.centerOffset!==0,c=i?0:e.arrowWidth,l=i?0:e.arrowHeight,[a,f]=zt(n),p={start:"0%",center:"50%",end:"100%"}[f],m=(r.arrow?.x??0)+c/2,d=(r.arrow?.y??0)+l/2;let g="",h="";return a==="bottom"?(g=i?p:`${m}px`,h=`${-l}px`):a==="top"?(g=i?p:`${m}px`,h=`${o.floating.height+l}px`):a==="right"?(g=`${-l}px`,h=i?p:`${d}px`):a==="left"&&(g=`${o.floating.width+l}px`,h=i?p:`${d}px`),{data:{x:g,y:h}}}});function zt(e){const[t,n="center"]=e.split("-");return[t,n]}var qo=jt,Vt=Wt,Go=Ht,Zo=Ut,Jo="Portal",Kt=u.forwardRef((e,t)=>{const{container:n,...o}=e,[r,s]=u.useState(!1);ue(()=>s(!0),[]);const i=n||r&&globalThis?.document?.body;return i?mn.createPortal(A.jsx(X.div,{...o,ref:t}),i):null});Kt.displayName=Jo;function Qo(e,t){return u.useReducer((n,o)=>t[n][o]??n,e)}var Xe=e=>{const{present:t,children:n}=e,o=er(t),r=typeof n=="function"?n({present:o.isPresent}):u.Children.only(n),s=ee(o.ref,tr(r));return typeof n=="function"||o.isPresent?u.cloneElement(r,{ref:s}):null};Xe.displayName="Presence";function er(e){const[t,n]=u.useState(),o=u.useRef({}),r=u.useRef(e),s=u.useRef("none"),i=e?"mounted":"unmounted",[c,l]=Qo(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return u.useEffect(()=>{const a=ve(o.current);s.current=c==="mounted"?a:"none"},[c]),ue(()=>{const a=o.current,f=r.current;if(f!==e){const m=s.current,d=ve(a);e?l("MOUNT"):d==="none"||a?.display==="none"?l("UNMOUNT"):l(f&&m!==d?"ANIMATION_OUT":"UNMOUNT"),r.current=e}},[e,l]),ue(()=>{if(t){let a;const f=t.ownerDocument.defaultView??window,p=d=>{const h=ve(o.current).includes(d.animationName);if(d.target===t&&h&&(l("ANIMATION_END"),!r.current)){const x=t.style.animationFillMode;t.style.animationFillMode="forwards",a=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=x)})}},m=d=>{d.target===t&&(s.current=ve(o.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",p),t.addEventListener("animationend",p),()=>{f.clearTimeout(a),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",p),t.removeEventListener("animationend",p)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(c),ref:u.useCallback(a=>{a&&(o.current=getComputedStyle(a)),n(a)},[])}}function ve(e){return e?.animationName||"none"}function tr(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)}var qe="Popover",[Yt]=xt(qe,[kt]),me=kt(),[nr,te]=Yt(qe),Xt=e=>{const{__scopePopover:t,children:n,open:o,defaultOpen:r,onOpenChange:s,modal:i=!1}=e,c=me(t),l=u.useRef(null),[a,f]=u.useState(!1),[p=!1,m]=hn({prop:o,defaultProp:r,onChange:s});return A.jsx(qo,{...c,children:A.jsx(nr,{scope:t,contentId:gn(),triggerRef:l,open:p,onOpenChange:m,onOpenToggle:u.useCallback(()=>m(d=>!d),[m]),hasCustomAnchor:a,onCustomAnchorAdd:u.useCallback(()=>f(!0),[]),onCustomAnchorRemove:u.useCallback(()=>f(!1),[]),modal:i,children:n})})};Xt.displayName=qe;var qt="PopoverAnchor",or=u.forwardRef((e,t)=>
3{const{__scopePopover:n,...o}=e,r=te(qt,n),s=me(n),{onCustomAnchorAdd:i,onCustomAnchorRemove:c}=r;return u.useEffect(()=>(i(),()=>c()),[i,c]),A.jsx(Vt,{...s,...o,ref:t})});or.displayName=qt;var Gt="PopoverTrigger",Zt=u.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=te(Gt,n),s=me(n),i=ee(t,r.triggerRef),c=A.jsx(X.button,{type:"button","aria-haspopup":"dialog","aria-expanded":r.open,"aria-controls":r.contentId,"data-state":on(r.open),...o,ref:i,onClick:G(e.onClick,r.onOpenToggle)});return r.hasCustomAnchor?c:A.jsx(Vt,{asChild:!0,...s,children:c})});Zt.displayName=Gt;var Ge="PopoverPortal",[rr,sr]=Yt(Ge,{forceMount:void 0}),Jt=e=>{const{__scopePopover:t,forceMount:n,children:o,container:r}=e,s=te(Ge,t);return A.jsx(rr,{scope:t,forceMount:n,children:A.jsx(Xe,{present:n||s.open,children:A.jsx(Kt,{asChild:!0,container:r,children:o})})})};Jt.displayName=Ge;var se="PopoverContent",Qt=u.forwardRef((e,t)=>{const n=sr(se,e.__scopePopover),{forceMount:o=n.forceMount,...r}=e,s=te(se,e.__scopePopover);return A.jsx(Xe,{present:o||s.open,children:s.modal?A.jsx(ir,{...r,ref:t}):A.jsx(cr,{...r,ref:t})})});Qt.displayName=se;var ir=u.forwardRef((e,t)=>{const n=te(se,e.__scopePopover),o=u.useRef(null),r=ee(t,o),s=u.useRef(!1);return u.useEffect(()=>{const i=o.current;if(i)return yn(i)},[]),A.jsx(wn,{as:je,allowPinchZoom:!0,children:A.jsx(en,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:G(e.onCloseAutoFocus,i=>{i.preventDefault(),s.current||n.triggerRef.current?.focus()}),onPointerDownOutside:G(e.onPointerDownOutside,i=>{const c=i.detail.originalEvent,l=c.button===0&&c.ctrlKey===!0,a=c.button===2||l;s.current=a},{checkForDefaultPrevented:!1}),onFocusOutside:G(e.onFocusOutside,i=>i.preventDefault(),{checkForDefaultPrevented:!1})})})}),cr=u.forwardRef((e,t)=>{const n=te(se,e.__scopePopover),o=u.useRef(!1),r=u.useRef(!1);return A.jsx(en,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{e.onCloseAutoFocus?.(s),s.defaultPrevented||(o.current||n.triggerRef.current?.focus(),s.preventDefault()),o.current=!1,r.current=!1},onInteractOutside:s=>{e.onInteractOutside?.(s),s.defaultPrevented||(o.current=!0,s.detail.originalEvent.type==="pointerdown"&&(r.current=!0));const i=s.target;n.triggerRef.current?.contains(i)&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&r.current&&s.preventDefault()}})}),en=u.forwardRef((e,t)=>{const{__scopePopover:n,trapFocus:o,onOpenAutoFocus:r,onCloseAutoFocus:s,disableOutsidePointerEvents:i,onEscapeKeyDown:c,onPointerDownOutside:l,onFocusOutside:a,onInteractOutside:f,...p}=e,m=te(se,n),d=me(n);return _n(),A.jsx(Pt,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:r,onUnmountAutoFocus:s,children:A.jsx(wt,{asChild:!0,disableOutsidePointerEvents:i,onInteractOutside:f,onEscapeKeyDown:c,onPointerDownOutside:l,onFocusOutside:a,onDismiss:()=>m.onOpenChange(!1),children:A.jsx(Go,{"data-state":on(m.open),role:"dialog",id:m.contentId,...d,...p,ref:t,style:{...p.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),tn="PopoverClose",nn=u.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=te(tn,n);return A.jsx(X.button,{type:"button",...o,ref:t,onClick:G(e.onClick,()=>r.onOpenChange(!1))})});nn.displayName=tn;var ar="PopoverArrow",Ze=u.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=me(n);return A.jsx(Zo,{...r,...o,ref:t})});Ze.displayName=ar;function on(e){return e?"open":"closed"}var lr=Xt,ur=Zt,fr=Jt,Ie=Qt,dr=nn,pr=Ze;const Er=lr,Ar=ur,Cr=dr,mr=u.forwardRef(({className:e},t)=>A.jsx(Ze,{ref:t,className:De("PopoverArrow fill-flexcar-neutral100",e)}));mr.displayName=pr.displayName;const hr=u.forwardRef(({className:e,align:t="center",sideOffset:n=4,portalContainer:o,inModal:r=!1,...s},i)=>r?A.jsx(Ie,{ref:i,align:t,sideOffset:n,className:De("z-[51] w-auto rounded-md border-none bg-flexcar-neutral100 px-[12px] py-[4px] text-popover-foreground shadow-md outline-none 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
3de-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...s}):A.jsx(fr,{container:o,children:A.jsx(Ie,{ref:i,align:t,sideOffset:n,className:De("z-[51] w-auto rounded-md border-none bg-flexcar-neutral100 px-[12px] py-[4px] text-popover-foreground shadow-md outline-none 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]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...s})}));hr.displayName=Ie.displayName;export{Er as P,Ar as a,hr as b,mr as c,Cr as d,jo as e,Io as f,Wo as g,$o as h,Ao as i,ko as l,Lo as o,_o as s,Fo as u};
4//# sourceMappingURL=popover-Bz_Auyo_.js.map
5
6//# debugId=ca7bbccf-ab7f-59cd-b816-b32b334866d9

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.