1import{r as a,j as p,R as Y,a as Je,b as Es,$ as pn}from"./vendor-react-O1HtssjF.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="9e5401a6-35e9-4229-8c26-9157b167a31a",e._sentryDebugIdIdentifier="sentry-dbid-9e5401a6-35e9-4229-8c26-9157b167a31a")}catch{}})();function P(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e==null||e(r),n===!1||!r.defaultPrevented)return t==null?void 0:t(r)}}function Vr(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function vn(...e){return t=>{let n=!1;const o=e.map(r=>{const s=Vr(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():Vr(e[r],null)}}}}function F(...e){return a.useCallback(vn(...e),e)}function od(e,t){const n=a.createContext(t),o=s=>{const{children:i,...c}=s,l=a.useMemo(()=>c,Object.values(c));return p.jsx(n.Provider,{value:l,children:i})};o.displayName=e+"Provider";function r(s){const i=a.useContext(n);if(i)return i;if(t!==void 0)return t;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[o,r]}function Z(e,t=[]){let n=[];function o(s,i){const c=a.createContext(i),l=n.length;n=[...n,i];const u=d=>{var x;const{scope:v,children:h,...g}=d,m=((x=v==null?void 0:v[e])==null?void 0:x[l])||c,b=a.useMemo(()=>g,Object.values(g));return p.jsx(m.Provider,{value:b,children:h})};u.displayName=s+"Provider";function f(d,v){var m;const h=((m=v==null?void 0:v[e])==null?void 0:m[l])||c,g=a.useContext(h);if(g)return g;if(i!==void 0)return i;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[u,f]}const r=()=>{const s=n.map(i=>a.createContext(i));return function(c){const l=(c==null?void 0:c[e])||s;return a.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return r.scopeName=e,[o,rd(r,...t)]}function rd(...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:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return a.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}function Oe(e){const t=sd(e),n=a.forwardRef((o,r)=>{const{children:s,...i}=o,c=a.Children.toArray(s),l=c.find(ad);if(l){const u=l.props.children,f=c.map(d=>d===l?a.Children.count(u)>1?a.Children.only(null):a.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...i,ref:r,children:a.isValidElement(u)?a.cloneElement(u,void 0,f):null})}return p.jsx(t,{...i,ref:r,children:s})});return n.displayName=`${e}.Slot`,n}var Ux=Oe("Slot");function sd(e){const t=a.forwardRef((n,o)=>{const{children:r,...s}=n;if(a.isValidElement(r)){const i=cd(r),c=id(s,r.props);return r.type!==a.Fragment&&(c.ref=o?vn(o,i):i),a.cloneElement(r,c)}return a.Children.count(r)>1?a.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Ss=Symbol("radix.slottable");function Ps(e){const t=({children:n})=>p.jsx(p.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=Ss,t}function ad(e){return a.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Ss}function id(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 cd(e){var o,r;let t=(o=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(r=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function mt(e){const t=e+"CollectionProvider",[n,o]=Z(t),[r,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=m=>{const{scope:b,children:x}=m,w=Y.useRef(null),y=Y.useRef(new Map).current;return p.jsx(r,{scope:b,itemMap:y,collectionRef:w,children:x})};i.displayName=t;const c=e+"CollectionSlot",l=Oe(c),u=Y.forwardRef((m,b)=>{const{scope:x,children:w}=m,y=s(c,x),C=F(b,y.collectionRef);return p.jsx(l,{ref:C,children:w})});u.displayName=c;const f=e+"CollectionItemSlot",d="data-radix-collection-item",v=Oe(f),h=Y.forwardRef((m,b)=>{const{scope:x,children:w,...y}=m,C=Y.useRef(null),E=F(b,C),R=s(f,x);return Y.useEffect(()=>(R.itemMap.set(C,{ref:C,...y}),()=>void R.itemMap.delete(C))),p.jsx(v,{[d]:"",ref:E,children:w})});h.displayName=f;function g(m){const b=s(e+"CollectionConsumer",m);return Y.useCallback(()=>{const w=b.collectionRef.current;if(!w)return[];const y=Array.from(w.querySelectorAll(`[${d}]`));return Array.from(b.itemMap.values()).sort((R,S)=>y.indexOf(R.ref.current)-y.indexOf(S.ref.current))},[b.collectionRef,b.itemMap])}return[{Provider:i,Slot:u,ItemSlot:h},g,o]}var ld=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],I=ld.reduce((e,t)=>
1{const n=Oe(`Primitive.${t}`),o=a.forwardRef((r,s)=>{const{asChild:i,...c}=r,l=i?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return o.displayName=`Primitive.${t}`,{...e,[t]:o}},{});function Oo(e,t){e&&Je.flushSync(()=>e.dispatchEvent(t))}function q(e){const t=a.useRef(e);return a.useEffect(()=>{t.current=e}),a.useMemo(()=>(...n)=>{var o;return(o=t.current)==null?void 0:o.call(t,...n)},[])}function ud(e,t=globalThis==null?void 0:globalThis.document){const n=q(e);a.useEffect(()=>{const o=r=>{r.key==="Escape"&&n(r)};return t.addEventListener("keydown",o,{capture:!0}),()=>t.removeEventListener("keydown",o,{capture:!0})},[n,t])}var dd="DismissableLayer",ro="dismissableLayer.update",fd="dismissableLayer.pointerDownOutside",pd="dismissableLayer.focusOutside",Br,Rs=a.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),et=a.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:o,onPointerDownOutside:r,onFocusOutside:s,onInteractOutside:i,onDismiss:c,...l}=e,u=a.useContext(Rs),[f,d]=a.useState(null),v=(f==null?void 0:f.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,h]=a.useState({}),g=F(t,S=>d(S)),m=Array.from(u.layers),[b]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),x=m.indexOf(b),w=f?m.indexOf(f):-1,y=u.layersWithOutsidePointerEventsDisabled.size>0,C=w>=x,E=md(S=>{const A=S.target,$=[...u.branches].some(N=>N.contains(A));!C||$||(r==null||r(S),i==null||i(S),S.defaultPrevented||c==null||c())},v),R=hd(S=>{const A=S.target;[...u.branches].some(N=>N.contains(A))||(s==null||s(S),i==null||i(S),S.defaultPrevented||c==null||c())},v);return ud(S=>{w===u.layers.size-1&&(o==null||o(S),!S.defaultPrevented&&c&&(S.preventDefault(),c()))},v),a.useEffect(()=>{if(f)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(Br=v.body.style.pointerEvents,v.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(f)),u.layers.add(f),Wr(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(v.body.style.pointerEvents=Br)}},[f,v,n,u]),a.useEffect(()=>()=>{f&&(u.layers.delete(f),u.layersWithOutsidePointerEventsDisabled.delete(f),Wr())},[f,u]),a.useEffect(()=>{const S=()=>h({});return document.addEventListener(ro,S),()=>document.removeEventListener(ro,S)},[]),p.jsx(I.div,{...l,ref:g,style:{pointerEvents:y?C?"auto":"none":void 0,...e.style},onFocusCapture:P(e.onFocusCapture,R.onFocusCapture),onBlurCapture:P(e.onBlurCapture,R.onBlurCapture),onPointerDownCapture:P(e.onPointerDownCapture,E.onPointerDownCapture)})});et.displayName=dd;var vd="DismissableLayerBranch",As=a.forwardRef((e,t)=>{const n=a.useContext(Rs),o=a.useRef(null),r=F(t,o);return a.useEffect(()=>{const s=o.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),p.jsx(I.div,{...e,ref:r})});As.displayName=vd;function md(e,t=globalThis==null?void 0:globalThis.document){const n=q(e),o=a.useRef(!1),r=a.useRef(()=>{});return a.useEffect(()=>{const s=c=>{if(c.target&&!o.current){let l=function(){Ts(fd,n,u,{discrete:!0})};const u={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 hd(e,t=globalThis==null?void 0:globalThis.document){const n=q(e),o=a.useRef(!1);return a.useEffect(()=>{const r=s=>{s.target&&!o.current&&Ts(pd,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 Wr(){const e=new CustomEvent(ro);document.dispatchEvent(e)}function Ts(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?Oo(r,s):r.dispatchEvent(s)}var gd=et,bd=As,Q=globalThis!=null&&globalThis.document?a.useLayoutEffect:()=>{},xd="Portal",ht=a.forwardRef((e,t)=>
1{var c;const{container:n,...o}=e,[r,s]=a.useState(!1);Q(()=>s(!0),[]);const i=n||r&&((c=globalThis==null?void 0:globalThis.document)==null?void 0:c.body);return i?Es.createPortal(p.jsx(I.div,{...o,ref:t}),i):null});ht.displayName=xd;function wd(e,t){return a.useReducer((n,o)=>t[n][o]??n,e)}var ee=e=>{const{present:t,children:n}=e,o=yd(t),r=typeof n=="function"?n({present:o.isPresent}):a.Children.only(n),s=F(o.ref,Cd(r));return typeof n=="function"||o.isPresent?a.cloneElement(r,{ref:s}):null};ee.displayName="Presence";function yd(e){const[t,n]=a.useState(),o=a.useRef({}),r=a.useRef(e),s=a.useRef("none"),i=e?"mounted":"unmounted",[c,l]=wd(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return a.useEffect(()=>{const u=Wt(o.current);s.current=c==="mounted"?u:"none"},[c]),Q(()=>{const u=o.current,f=r.current;if(f!==e){const v=s.current,h=Wt(u);e?l("MOUNT"):h==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(f&&v!==h?"ANIMATION_OUT":"UNMOUNT"),r.current=e}},[e,l]),Q(()=>{if(t){let u;const f=t.ownerDocument.defaultView??window,d=h=>{const m=Wt(o.current).includes(h.animationName);if(h.target===t&&m&&(l("ANIMATION_END"),!r.current)){const b=t.style.animationFillMode;t.style.animationFillMode="forwards",u=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=b)})}},v=h=>{h.target===t&&(s.current=Wt(o.current))};return t.addEventListener("animationstart",v),t.addEventListener("animationcancel",d),t.addEventListener("animationend",d),()=>{f.clearTimeout(u),t.removeEventListener("animationstart",v),t.removeEventListener("animationcancel",d),t.removeEventListener("animationend",d)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(c),ref:a.useCallback(u=>{u&&(o.current=getComputedStyle(u)),n(u)},[])}}function Wt(e){return(e==null?void 0:e.animationName)||"none"}function Cd(e){var o,r;let t=(o=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(r=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function se({prop:e,defaultProp:t,onChange:n=()=>{}}){const[o,r]=Ed({defaultProp:t,onChange:n}),s=e!==void 0,i=s?e:o,c=q(n),l=a.useCallback(u=>{if(s){const d=typeof u=="function"?u(e):u;d!==e&&c(d)}else r(u)},[s,e,r,c]);return[i,l]}function Ed({defaultProp:e,onChange:t}){const n=a.useState(e),[o]=n,r=a.useRef(o),s=q(t);return a.useEffect(()=>{r.current!==o&&(s(o),r.current=o)},[o,r,s]),n}var Sd="VisuallyHidden",$t=a.forwardRef((e,t)=>p.jsx(I.span,{...e,ref:t,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}}));$t.displayName=Sd;var Pd=$t,Do="ToastProvider",[Lo,Rd,Ad]=mt("Toast"),[_s]=Z("Toast",[Ad]),[Td,mn]=_s(Do),$s=e=>{const{__scopeToast:t,label:n="Notification",duration:o=5e3,swipeDirection:r="right",swipeThreshold:s=50,children:i}=e,[c,l]=a.useState(null),[u,f]=a.useState(0),d=a.useRef(!1),v=a.useRef(!1);return n.trim()||console.error(`Invalid prop \`label\` supplied to \`${Do}\`. Expected non-empty \`string\`.`),p.jsx(Lo.Provider,{scope:t,children:p.jsx(Td,{scope:t,label:n,duration:o,swipeDirection:r,swipeThreshold:s,toastCount:u,viewport:c,onViewportChange:l,onToastAdd:a.useCallback(()=>f(h=>h+1),[]),onToastRemove:a.useCallback(()=>f(h=>h-1),[]),isFocusedToastEscapeKeyDownRef:d,isClosePausedRef:v,children:i})})};$s.displayName=Do;var Is="ToastViewport",_d=["F8"],so="toast.viewportPause",ao="toast.viewportResume",Ns=a.forwardRef((e,t)=>{const{__scopeToast:n,hotkey:o=_d,label:r="Notifications ({hotkey})",...s}=e,i=mn(Is,n),c=Rd(n),l=a.useRef(null),u=a.useRef(null),f=a.useRef(null),d=a.useRef(null),v=F(t,d,i.onViewportChange),h=o.join("+").replace(/Key/g,"").replace(/Digit/g,""),g=i.toastCount>0;a.useEffect(()=>{const b=x=>{var y;o.length!==0&&o.every(C=>x[C]||x.code===C)&&((y=d.current)==null||y.focus())};return document.addEventListener("keydown",b),()=>document.removeEventListener("keydown",b)},[o]),a.useEffect(()=>{const b=l.current,x=d.current;if(g&&b&&x){const w=()=>
1{if(!i.isClosePausedRef.current){const R=new CustomEvent(so);x.dispatchEvent(R),i.isClosePausedRef.current=!0}},y=()=>{if(i.isClosePausedRef.current){const R=new CustomEvent(ao);x.dispatchEvent(R),i.isClosePausedRef.current=!1}},C=R=>{!b.contains(R.relatedTarget)&&y()},E=()=>{b.contains(document.activeElement)||y()};return b.addEventListener("focusin",w),b.addEventListener("focusout",C),b.addEventListener("pointermove",w),b.addEventListener("pointerleave",E),window.addEventListener("blur",w),window.addEventListener("focus",y),()=>{b.removeEventListener("focusin",w),b.removeEventListener("focusout",C),b.removeEventListener("pointermove",w),b.removeEventListener("pointerleave",E),window.removeEventListener("blur",w),window.removeEventListener("focus",y)}}},[g,i.isClosePausedRef]);const m=a.useCallback(({tabbingDirection:b})=>{const w=c().map(y=>{const C=y.ref.current,E=[C,...Wd(C)];return b==="forwards"?E:E.reverse()});return(b==="forwards"?w.reverse():w).flat()},[c]);return a.useEffect(()=>{const b=d.current;if(b){const x=w=>{var E,R,S;const y=w.altKey||w.ctrlKey||w.metaKey;if(w.key==="Tab"&&!y){const A=document.activeElement,$=w.shiftKey;if(w.target===b&&$){(E=u.current)==null||E.focus();return}const j=m({tabbingDirection:$?"backwards":"forwards"}),V=j.findIndex(T=>T===A);Wn(j.slice(V+1))?w.preventDefault():$?(R=u.current)==null||R.focus():(S=f.current)==null||S.focus()}};return b.addEventListener("keydown",x),()=>b.removeEventListener("keydown",x)}},[c,m]),p.jsxs(bd,{ref:l,role:"region","aria-label":r.replace("{hotkey}",h),tabIndex:-1,style:{pointerEvents:g?void 0:"none"},children:[g&&p.jsx(io,{ref:u,onFocusFromOutsideViewport:()=>{const b=m({tabbingDirection:"forwards"});Wn(b)}}),p.jsx(Lo.Slot,{scope:n,children:p.jsx(I.ol,{tabIndex:-1,...s,ref:v})}),g&&p.jsx(io,{ref:f,onFocusFromOutsideViewport:()=>{const b=m({tabbingDirection:"backwards"});Wn(b)}})]})});Ns.displayName=Is;var Ms="ToastFocusProxy",io=a.forwardRef((e,t)=>{const{__scopeToast:n,onFocusFromOutsideViewport:o,...r}=e,s=mn(Ms,n);return p.jsx($t,{"aria-hidden":!0,tabIndex:0,...r,ref:t,style:{position:"fixed"},onFocus:i=>{var u;const c=i.relatedTarget;!((u=s.viewport)!=null&&u.contains(c))&&o()}})});io.displayName=Ms;var hn="Toast",$d="toast.swipeStart",Id="toast.swipeMove",Nd="toast.swipeCancel",Md="toast.swipeEnd",Os=a.forwardRef((e,t)=>{const{forceMount:n,open:o,defaultOpen:r,onOpenChange:s,...i}=e,[c=!0,l]=se({prop:o,defaultProp:r,onChange:s});return p.jsx(ee,{present:n||c,children:p.jsx(Ld,{open:c,...i,ref:t,onClose:()=>l(!1),onPause:q(e.onPause),onResume:q(e.onResume),onSwipeStart:P(e.onSwipeStart,u=>{u.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:P(e.onSwipeMove,u=>{const{x:f,y:d}=u.detail.delta;u.currentTarget.setAttribute("data-swipe","move"),u.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${f}px`),u.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${d}px`)}),onSwipeCancel:P(e.onSwipeCancel,u=>{u.currentTarget.setAttribute("data-swipe","cancel"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),u.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),u.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:P(e.onSwipeEnd,u=>{const{x:f,y:d}=u.detail.delta;u.currentTarget.setAttribute("data-swipe","end"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),u.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${f}px`),u.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${d}px`),l(!1)})})})});Os.displayName=hn;var[Od,Dd]=_s(hn,{onClose(){}}),Ld=a.forwardRef((e,t)=>{const{__scopeToast:n,type:o="foreground",duration:r,open:s,onClose:i,onEscapeKeyDown:c,onPause:l,onResume:u,onSwipeStart:f,onSwipeMove:d,onSwipeCancel:v,onSwipeEnd:h,...g}=e,m=mn(hn,n),[b,x]=a.useState(null),w=F(t,T=>x(T)),y=a.useRef(null),C=a.useRef(null),E=r||m.duration,R=a.useRef(0),S=a.useRef(E),A=a.useRef(0),{onToastAdd:$,onToastRemove:N}=m,O=q(()=>{var L;(b==null?void 0:b.contains(document.activeElement))&&((L=m.viewport)==null||L.focus()),i()}),j=a.useCallback(T=>
1{!T||T===1/0||(window.clearTimeout(A.current),R.current=new Date().getTime(),A.current=window.setTimeout(O,T))},[O]);a.useEffect(()=>{const T=m.viewport;if(T){const L=()=>{j(S.current),u==null||u()},D=()=>{const B=new Date().getTime()-R.current;S.current=S.current-B,window.clearTimeout(A.current),l==null||l()};return T.addEventListener(so,D),T.addEventListener(ao,L),()=>{T.removeEventListener(so,D),T.removeEventListener(ao,L)}}},[m.viewport,E,l,u,j]),a.useEffect(()=>{s&&!m.isClosePausedRef.current&&j(E)},[s,E,m.isClosePausedRef,j]),a.useEffect(()=>($(),()=>N()),[$,N]);const V=a.useMemo(()=>b?Bs(b):null,[b]);return m.viewport?p.jsxs(p.Fragment,{children:[V&&p.jsx(kd,{__scopeToast:n,role:"status","aria-live":o==="foreground"?"assertive":"polite","aria-atomic":!0,children:V}),p.jsx(Od,{scope:n,onClose:O,children:Je.createPortal(p.jsx(Lo.ItemSlot,{scope:n,children:p.jsx(gd,{asChild:!0,onEscapeKeyDown:P(c,()=>{m.isFocusedToastEscapeKeyDownRef.current||O(),m.isFocusedToastEscapeKeyDownRef.current=!1}),children:p.jsx(I.li,{role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":s?"open":"closed","data-swipe-direction":m.swipeDirection,...g,ref:w,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:P(e.onKeyDown,T=>{T.key==="Escape"&&(c==null||c(T.nativeEvent),T.nativeEvent.defaultPrevented||(m.isFocusedToastEscapeKeyDownRef.current=!0,O()))}),onPointerDown:P(e.onPointerDown,T=>{T.button===0&&(y.current={x:T.clientX,y:T.clientY})}),onPointerMove:P(e.onPointerMove,T=>{if(!y.current)return;const L=T.clientX-y.current.x,D=T.clientY-y.current.y,B=!!C.current,M=["left","right"].includes(m.swipeDirection),_=["left","up"].includes(m.swipeDirection)?Math.min:Math.max,H=M?_(0,L):0,X=M?0:_(0,D),J=T.pointerType==="touch"?10:2,re={x:H,y:X},oe={originalEvent:T,delta:re};B?(C.current=re,Ht(Id,d,oe,{discrete:!1})):Hr(re,m.swipeDirection,J)?(C.current=re,Ht($d,f,oe,{discrete:!1}),T.target.setPointerCapture(T.pointerId)):(Math.abs(L)>J||Math.abs(D)>J)&&(y.current=null)}),onPointerUp:P(e.onPointerUp,T=>{const L=C.current,D=T.target;if(D.hasPointerCapture(T.pointerId)&&D.releasePointerCapture(T.pointerId),C.current=null,y.current=null,L){const B=T.currentTarget,M={originalEvent:T,delta:L};Hr(L,m.swipeDirection,m.swipeThreshold)?Ht(Md,h,M,{discrete:!0}):Ht(Nd,v,M,{discrete:!0}),B.addEventListener("click",_=>_.preventDefault(),{once:!0})}})})})}),m.viewport)})]}):null}),kd=e=>{const{__scopeToast:t,children:n,...o}=e,r=mn(hn,t),[s,i]=a.useState(!1),[c,l]=a.useState(!1);return Vd(()=>i(!0)),a.useEffect(()=>{const u=window.setTimeout(()=>l(!0),1e3);return()=>window.clearTimeout(u)},[]),c?null:p.jsx(ht,{asChild:!0,children:p.jsx($t,{...o,children:s&&p.jsxs(p.Fragment,{children:[r.label," ",n]})})})},jd="ToastTitle",Ds=a.forwardRef((e,t)=>{const{__scopeToast:n,...o}=e;return p.jsx(I.div,{...o,ref:t})});Ds.displayName=jd;var Fd="ToastDescription",Ls=a.forwardRef((e,t)=>{const{__scopeToast:n,...o}=e;return p.jsx(I.div,{...o,ref:t})});Ls.displayName=Fd;var ks="ToastAction",js=a.forwardRef((e,t)=>{const{altText:n,...o}=e;return n.trim()?p.jsx(Vs,{altText:n,asChild:!0,children:p.jsx(ko,{...o,ref:t})}):(console.error(`Invalid prop \`altText\` supplied to \`${ks}\`. Expected non-empty \`string\`.`),null)});js.displayName=ks;var Fs="ToastClose",ko=a.forwardRef((e,t)=>{const{__scopeToast:n,...o}=e,r=Dd(Fs,n);return p.jsx(Vs,{asChild:!0,children:p.jsx(I.button,{type:"button",...o,ref:t,onClick:P(e.onClick,r.onClose)})})});ko.displayName=Fs;var Vs=a.forwardRef((e,t)=>{const{__scopeToast:n,altText:o,...r}=e;return p.jsx(I.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":o||void 0,...r,ref:t})});function Bs(e){const t=[];return Array.from(e.childNodes).forEach(o=>{if(o.nodeType===o.TEXT_NODE&&o.textContent&&t.push(o.textContent),Bd(o)){const r=o.ariaHidden||o.hidden||o.style.display==="none",s=o.dataset.radixToastAnnounceExclude==="";if(!r)if(s){const i=o.dataset.radixToastAnnounceAlt;i&&t.push(i)}else t.push(...Bs(o))}}),t}function Ht(e,t,n,{discrete:o}){const r=n.originalEvent.currentTarget,s=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:n});t&&r.addEventListener(e,t,{once:!0}),o?Oo(r,s):r.dispatchEvent(s)}var Hr=(e,t,n=0)=>{const o=Math.abs(e.x),r=Math.abs(e.y),s=o>r;return t==="left"||t==="right"?s&&o>n:!s&&r>n};function Vd(e=()=>{}){const t=q(e);Q(()=>{let n=0,o=0;return n=window.requestAnimationFrame(()=>o=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(n),window.cancelAnimationFrame(o)}},[t])}
vendor: 6,206 bytes, line 1
1function Bd(e){return e.nodeType===e.ELEMENT_NODE}function Wd(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 Wn(e){const t=document.activeElement;return e.some(n=>n===t?!0:(n.focus(),document.activeElement!==t))}var Kx=$s,Gx=Ns,zx=Os,Yx=Ds,Xx=Ls,qx=js,Zx=ko,Hd=pn[" useId ".trim().toString()]||(()=>{}),Ud=0;function ce(e){const[t,n]=a.useState(Hd());return Q(()=>{n(o=>o??String(Ud++))},[e]),e||(t?`radix-${t}`:"")}const Kd=["top","right","bottom","left"],De=Math.min,ue=Math.max,en=Math.round,Ut=Math.floor,we=e=>({x:e,y:e}),Gd={left:"right",right:"left",bottom:"top",top:"bottom"},zd={start:"end",end:"start"};function co(e,t,n){return ue(e,De(t,n))}function Pe(e,t){return typeof e=="function"?e(t):e}function Re(e){return e.split("-")[0]}function gt(e){return e.split("-")[1]}function jo(e){return e==="x"?"y":"x"}function Fo(e){return e==="y"?"height":"width"}function Le(e){return["top","bottom"].includes(Re(e))?"y":"x"}function Vo(e){return jo(Le(e))}function Yd(e,t,n){n===void 0&&(n=!1);const o=gt(e),r=Vo(e),s=Fo(r);let i=r==="x"?o===(n?"end":"start")?"right":"left":o==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=tn(i)),[i,tn(i)]}function Xd(e){const t=tn(e);return[lo(e),t,lo(t)]}function lo(e){return e.replace(/start|end/g,t=>zd[t])}function qd(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 Zd(e,t,n,o){const r=gt(e);let s=qd(Re(e),n==="start",o);return r&&(s=s.map(i=>i+"-"+r),t&&(s=s.concat(s.map(lo)))),s}function tn(e){return e.replace(/left|right|bottom|top/g,t=>Gd[t])}function Qd(e){return{top:0,right:0,bottom:0,left:0,...e}}function Ws(e){return typeof e!="number"?Qd(e):{top:e,right:e,bottom:e,left:e}}function nn(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 Ur(e,t,n){let{reference:o,floating:r}=e;const s=Le(t),i=Vo(t),c=Fo(i),l=Re(t),u=s==="y",f=o.x+o.width/2-r.width/2,d=o.y+o.height/2-r.height/2,v=o[c]/2-r[c]/2;let h;switch(l){case"top":h={x:f,y:o.y-r.height};break;case"bottom":h={x:f,y:o.y+o.height};break;case"right":h={x:o.x+o.width,y:d};break;case"left":h={x:o.x-r.width,y:d};break;default:h={x:o.x,y:o.y}}switch(gt(t)){case"start":h[i]-=v*(n&&u?-1:1);break;case"end":h[i]+=v*(n&&u?-1:1);break}return h}const Jd=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 u=await i.getElementRects({reference:e,floating:t,strategy:r}),{x:f,y:d}=Ur(u,o,l),v=o,h={},g=0;for(let m=0;m<c.length;m++){const{name:b,fn:x}=c[m],{x:w,y,data:C,reset:E}=await x({x:f,y:d,initialPlacement:o,placement:v,strategy:r,middlewareData:h,rects:u,platform:i,elements:{reference:e,floating:t}});f=w??f,d=y??d,h={...h,[b]:{...h[b],...C}},E&&g<=50&&(g++,typeof E=="object"&&(E.placement&&(v=E.placement),E.rects&&(u=E.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:r}):E.rects),{x:f,y:d}=Ur(u,v,l)),m=-1)}return{x:f,y:d,placement:v,strategy:r,middlewareData:h}};async function Pt(e,t){var n;t===void 0&&(t={});const{x:o,y:r,platform:s,rects:i,elements:c,strategy:l}=e,{boundary:u="clippingAncestors",rootBoundary:f="viewport",elementContext:d="floating",altBoundary:v=!1,padding:h=0}=Pe(t,e),g=Ws(h),b=c[v?d==="floating"?"reference":"floating":d],x=nn(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(b)))==null||n?b:b.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(c.floating)),boundary:u,rootBoundary:f,strategy:l})),w=d==="floating"?{x:o,y:r,width:i.floating.width,height:i.floating.height}:i.reference,y=await(s.getOffsetParent==null?void 0:s.getOffsetParent(c.floating)),C=await(s.isElement==null?void 0:s.isElement(y))?await(s.getScale==null?void 0:s.getScale(y))||{x:1,y:1}:{x:1,y:1},E=nn(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:w,offsetParent:y,strategy:l}):w);return{top:(x.top-E.top+g.top)/C.y,bottom:(E.bottom-x.bottom+g.bottom)/C.y,left:(x.left-E.left+g.left)/C.x,right:(E.right-x.right+g.right)/C.x}}const ef=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:u,padding:f=0}=Pe(e,t)||{};if(u==null)return{};const d=Ws(f),v={x:n,y:o},h=Vo(r),g=Fo(h),m=await i.getDimensions(u),b=h==="y",x=b?"top":"left",w=b?"bottom":"right",y=b?"clientHeight":"clientWidth",C=s.reference[g]+s.reference[h]-v[h]-s.floating[g],E=v[h]-s.reference[h],R=await(i.getOffsetParent==null?void 0:i.getOffsetParent(u));let S=R?R[y]:0;(!S||!await(i.isElement==null?void 0:i.isElement(R)))&&(S=c.floating[y]||s.floating[g]);const A=C/2-E/2,$=S/2-m[g]/2-1,N=De(d[x],$),O=De(d[w],$),j=N,V=S-m[g]-O,T=S/2-m[g]/2+A,L=co(j,T,V),D=!l.arrow&>(r)!=null&&T!==L&&s.reference[g]/2-(T<j?N:O)-m[g]/2<0,B=D?T<j?T-j:T-V:0;return{[h]:v[h]+B,data:{[h]:L,centerOffset:T-L-B,...D&&{alignmentOffset:B}},reset:D}}}),tf=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:u}=t,{mainAxis:f=!0,crossAxis:d=!0,fallbackPlacements:v,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:m=!0,...b}=Pe(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const x=Re(r),w=Le(c),y=Re(c)===c,C=await(l.isRTL==null?void 0:l.isRTL(u.floating)),E=v||(y||!m?[tn(c)]:Xd(c)),R=g!=="none";!v&&R&&E.push(...Zd(c,m,g,C));const S=[c,...E],A=await Pt(t,b),$=[];let N=((o=s.flip)==null?void 0:o.overflows)||[];if(f&&$.push(A[x]),d){const T=Yd(r,i,C);$.push(A[T[0]],A[T[1]])}if(N=[...N,{placement:r,overflows:$}],!$.every(T=>T<=0)){var O,j;const T=(((O=s.flip)==null?void 0:O.index)||0)+1,L=S[T];if(L)return{data:{index:T,overflows:N},reset:{placement:L}};
1let D=(j=N.filter(B=>B.overflows[0]<=0).sort((B,M)=>B.overflows[1]-M.overflows[1])[0])==null?void 0:j.placement;if(!D)switch(h){case"bestFit":{var V;const B=(V=N.filter(M=>{if(R){const _=Le(M.placement);return _===w||_==="y"}return!0}).map(M=>[M.placement,M.overflows.filter(_=>_>0).reduce((_,H)=>_+H,0)]).sort((M,_)=>M[1]-_[1])[0])==null?void 0:V[0];B&&(D=B);break}case"initialPlacement":D=c;break}if(r!==D)return{reset:{placement:D}}}return{}}}};function Kr(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Gr(e){return Kd.some(t=>e[t]>=0)}const nf=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:o="referenceHidden",...r}=Pe(e,t);switch(o){case"referenceHidden":{const s=await Pt(t,{...r,elementContext:"reference"}),i=Kr(s,n.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:Gr(i)}}}case"escaped":{const s=await Pt(t,{...r,altBoundary:!0}),i=Kr(s,n.floating);return{data:{escapedOffsets:i,escaped:Gr(i)}}}default:return{}}}}};async function of(e,t){const{placement:n,platform:o,elements:r}=e,s=await(o.isRTL==null?void 0:o.isRTL(r.floating)),i=Re(n),c=gt(n),l=Le(n)==="y",u=["left","top"].includes(i)?-1:1,f=s&&l?-1:1,d=Pe(t,e);let{mainAxis:v,crossAxis:h,alignmentAxis:g}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return c&&typeof g=="number"&&(h=c==="end"?g*-1:g),l?{x:h*f,y:v*u}:{x:v*u,y:h*f}}const rf=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 of(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}}}}},sf=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:b=>{let{x,y:w}=b;return{x,y:w}}},...l}=Pe(e,t),u={x:n,y:o},f=await Pt(t,l),d=Le(Re(r)),v=jo(d);let h=u[v],g=u[d];if(s){const b=v==="y"?"top":"left",x=v==="y"?"bottom":"right",w=h+f[b],y=h-f[x];h=co(w,h,y)}if(i){const b=d==="y"?"top":"left",x=d==="y"?"bottom":"right",w=g+f[b],y=g-f[x];g=co(w,g,y)}const m=c.fn({...t,[v]:h,[d]:g});return{...m,data:{x:m.x-n,y:m.y-o,enabled:{[v]:s,[d]:i}}}}}},af=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:u=!0}=Pe(e,t),f={x:n,y:o},d=Le(r),v=jo(d);let h=f[v],g=f[d];const m=Pe(c,t),b=typeof m=="number"?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(l){const y=v==="y"?"height":"width",C=s.reference[v]-s.floating[y]+b.mainAxis,E=s.reference[v]+s.reference[y]-b.mainAxis;h<C?h=C:h>E&&(h=E)}if(u){var x,w;const y=v==="y"?"width":"height",C=["top","left"].includes(Re(r)),E=s.reference[d]-s.floating[y]+(C&&((x=i.offset)==null?void 0:x[d])||0)+(C?0:b.crossAxis),R=s.reference[d]+s.reference[y]+(C?0:((w=i.offset)==null?void 0:w[d])||0)-(C?b.crossAxis:0);g<E?g=E:g>R&&(g=R)}return{[v]:h,[d]:g}}}},cf=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=()=>{},...u}=Pe(e,t),f=await Pt(t,u),d=Re(r),v=gt(r),h=Le(r)==="y",{width:g,height:m}=s.floating;let b,x;d==="top"||d==="bottom"?(b=d,x=v===(await(i.isRTL==null?void 0:i.isRTL(c.floating))?"start":"end")?"left":"right"):(x=d,b=v==="end"?"top":"bottom");const w=m-f.top-f.bottom,y=g-f.left-f.right,C=De(m-f[b],w),E=De(g-f[x],y),R=!t.middlewareData.shift;let S=C,A=E;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(A=y),(o=t.middlewareData.shift)!=null&&o.enabled.y&&(S=w),R&&!v){const N=ue(f.left,0),O=ue(f.right,0),j=ue(f.top,0),V=ue(f.bottom,0);h?A=g-2*(N!==0||O!==0?N+O:ue(f.left,f.right)):S=m-2*(j!==0||V!==0?j+V:ue(f.top,f.bottom))}await l({...t,availableWidth:A,availableHeight:S});const $=await i.getDimensions(c.floating);return g!==$.width||m!==$.height?{reset:{rects:!0}}:{}}}};function gn(){return typeof window<"u"}function bt(e){return Hs(e)?(e.nodeName||"").toLowerCase():"#document"}function de(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ce(e){var t;return(t=(Hs(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Hs(e){return gn()?e instanceof Node||e instanceof de(e).Node:!1}function he(e){return gn()?e instanceof Element||e instanceof de(e).Element:!1}function ye(e){return gn()?e instanceof HTMLElement||e instanceof de(e).HTMLElement:!1}function zr(e){return!gn()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof de(e).ShadowRoot}function It(e){const{overflow:t,overflowX:n,overflowY:o,display:r}=ge(e);return/auto|scroll|overlay|hidden|clip/.test(t+o+n)&&!["inline","contents"].includes(r)}function lf(e){return["table","td","th"].includes(bt(e))}function bn(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function Bo(e){const t=Wo(),n=he(e)?ge(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 uf(e){let t=ke(e);for(;ye(t)&&!ut(t);){if(Bo(t))return t;if(bn(t))return null;t=ke(t)}return null}function Wo(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function ut(e){return["html","body","#document"].includes(bt(e))}function ge(e){return de(e).getComputedStyle(e)}function xn(e){return he(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function ke(e){if(bt(e)==="html")return e;const t=e.assignedSlot||e.parentNode||zr(e)&&e.host||Ce(e);return zr(t)?t.host:t}function Us(e){const t=ke(e);return ut(t)?e.ownerDocument?e.ownerDocument.body:e.body:ye(t)&&It(t)?t:Us(t)}function Rt(e,t,n){var o;t===void 0&&(t=[]),n===void 0&&(n=!0);const r=Us(e),s=r===((o=e.ownerDocument)==null?void 0:o.body),i=de(r);if(s){const c=uo(i);
vendor: 7,091 bytes, line 1
1return t.concat(i,i.visualViewport||[],It(r)?r:[],c&&n?Rt(c):[])}return t.concat(r,Rt(r,[],n))}function uo(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Ks(e){const t=ge(e);let n=parseFloat(t.width)||0,o=parseFloat(t.height)||0;const r=ye(e),s=r?e.offsetWidth:n,i=r?e.offsetHeight:o,c=en(n)!==s||en(o)!==i;return c&&(n=s,o=i),{width:n,height:o,$:c}}function Ho(e){return he(e)?e:e.contextElement}function at(e){const t=Ho(e);if(!ye(t))return we(1);const n=t.getBoundingClientRect(),{width:o,height:r,$:s}=Ks(t);let i=(s?en(n.width):n.width)/o,c=(s?en(n.height):n.height)/r;return(!i||!Number.isFinite(i))&&(i=1),(!c||!Number.isFinite(c))&&(c=1),{x:i,y:c}}const df=we(0);function Gs(e){const t=de(e);return!Wo()||!t.visualViewport?df:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function ff(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==de(e)?!1:t}function Xe(e,t,n,o){t===void 0&&(t=!1),n===void 0&&(n=!1);const r=e.getBoundingClientRect(),s=Ho(e);let i=we(1);t&&(o?he(o)&&(i=at(o)):i=at(e));const c=ff(s,n,o)?Gs(s):we(0);let l=(r.left+c.x)/i.x,u=(r.top+c.y)/i.y,f=r.width/i.x,d=r.height/i.y;if(s){const v=de(s),h=o&&he(o)?de(o):o;let g=v,m=uo(g);for(;m&&o&&h!==g;){const b=at(m),x=m.getBoundingClientRect(),w=ge(m),y=x.left+(m.clientLeft+parseFloat(w.paddingLeft))*b.x,C=x.top+(m.clientTop+parseFloat(w.paddingTop))*b.y;l*=b.x,u*=b.y,f*=b.x,d*=b.y,l+=y,u+=C,g=de(m),m=uo(g)}}return nn({width:f,height:d,x:l,y:u})}function Uo(e,t){const n=xn(e).scrollLeft;return t?t.left+n:Xe(Ce(e)).left+n}function zs(e,t,n){n===void 0&&(n=!1);const o=e.getBoundingClientRect(),r=o.left+t.scrollLeft-(n?0:Uo(e,o)),s=o.top+t.scrollTop;return{x:r,y:s}}function pf(e){let{elements:t,rect:n,offsetParent:o,strategy:r}=e;const s=r==="fixed",i=Ce(o),c=t?bn(t.floating):!1;if(o===i||c&&s)return n;let l={scrollLeft:0,scrollTop:0},u=we(1);const f=we(0),d=ye(o);if((d||!d&&!s)&&((bt(o)!=="body"||It(i))&&(l=xn(o)),ye(o))){const h=Xe(o);u=at(o),f.x=h.x+o.clientLeft,f.y=h.y+o.clientTop}const v=i&&!d&&!s?zs(i,l,!0):we(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-l.scrollLeft*u.x+f.x+v.x,y:n.y*u.y-l.scrollTop*u.y+f.y+v.y}}function vf(e){return Array.from(e.getClientRects())}function mf(e){const t=Ce(e),n=xn(e),o=e.ownerDocument.body,r=ue(t.scrollWidth,t.clientWidth,o.scrollWidth,o.clientWidth),s=ue(t.scrollHeight,t.clientHeight,o.scrollHeight,o.clientHeight);let i=-n.scrollLeft+Uo(e);const c=-n.scrollTop;return ge(o).direction==="rtl"&&(i+=ue(t.clientWidth,o.clientWidth)-r),{width:r,height:s,x:i,y:c}}function hf(e,t){const n=de(e),o=Ce(e),r=n.visualViewport;let s=o.clientWidth,i=o.clientHeight,c=0,l=0;if(r){s=r.width,i=r.height;const u=Wo();(!u||u&&t==="fixed")&&(c=r.offsetLeft,l=r.offsetTop)}return{width:s,height:i,x:c,y:l}}function gf(e,t){const n=Xe(e,!0,t==="fixed"),o=n.top+e.clientTop,r=n.left+e.clientLeft,s=ye(e)?at(e):we(1),i=e.clientWidth*s.x,c=e.clientHeight*s.y,l=r*s.x,u=o*s.y;return{width:i,height:c,x:l,y:u}}function Yr(e,t,n){let o;if(t==="viewport")o=hf(e,n);else if(t==="document")o=mf(Ce(e));else if(he(t))o=gf(t,n);else{const r=Gs(e);o={x:t.x-r.x,y:t.y-r.y,width:t.width,height:t.height}}return nn(o)}function Ys(e,t){const n=ke(e);return n===t||!he(n)||ut(n)?!1:ge(n).position==="fixed"||Ys(n,t)}function bf(e,t){const n=t.get(e);if(n)return n;let o=Rt(e,[],!1).filter(c=>he(c)&&bt(c)!=="body"),r=null;const s=ge(e).position==="fixed";let i=s?ke(e):e;for(;he(i)&&!ut(i);){const c=ge(i),l=Bo(i);!l&&c.position==="fixed"&&(r=null),(s?!l&&!r:!l&&c.position==="static"&&!!r&&["absolute","fixed"].includes(r.position)||It(i)&&!l&&Ys(e,i))?o=o.filter(f=>f!==i):r=c,i=ke(i)}return t.set(e,o),o}function xf(e){let{element:t,boundary:n,rootBoundary:o,strategy:r}=e;const i=[...n==="clippingAncestors"?bn(t)?[]:bf(t,this._c):[].concat(n),o],c=i[0],l=i.reduce((u,f)=>{const d=Yr(t,f,r);return u.top=ue(d.top,u.top),u.right=De(d.right,u.right),u.bottom=De(d.bottom,u.bottom),u.left=ue(d.left,u.left),u},Yr(t,c,r));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function wf(e){const{width:t,height:n}=Ks(e);return{width:t,height:n}}function yf(e,t,n){const o=ye(t),r=Ce(t),s=n==="fixed",i=Xe(e,!0,s,t);let c={scrollLeft:0,scrollTop:0};const l=we(0);if(o||!o&&!s)if((bt(t)!=="body"||It(r))&&(c=xn(t)),o){const v=Xe(t,!0,s,t);l.x=v.x+t.clientLeft,l.y=v.y+t.clientTop}else r&&(l.x=Uo(r));const u=r&&!o&&!s?zs(r,c):we(0),f=i.left+c.scrollLeft-l.x-u.x,d=i.top+c.scrollTop-l.y-u.y;return{x:f,y:d,width:i.width,height:i.height}}function Hn(e){return ge(e).position==="static"}function Xr(e,t){if(!ye(e)||ge(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Ce(e)===n&&(n=n.ownerDocument.body),n}function Xs(e,t){const n=de(e);if(bn(e))return n;if(!ye(e)){let r=ke(e);for(;r&&!ut(r);){if(he(r)&&!Hn(r))return r;r=ke(r)}return n}let o=Xr(e,t);for(;o&&lf(o)&&Hn(o);)o=Xr(o,t);return o&&ut(o)&&Hn(o)&&!Bo(o)?n:o||uf(e)||n}const Cf=async function(e){const t=this.getOffsetParent||Xs,n=this.getDimensions,o=await n(e.floating);return{reference:yf(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}};function Ef(e){return ge(e).direction==="rtl"}const Sf={convertOffsetParentRelativeRectToViewportRelativeRect:pf,getDocumentElement:Ce,getClippingRect:xf,getOffsetParent:Xs,getElementRects:Cf,getClientRects:vf,getDimensions:wf,getScale:at,isElement:he,isRTL:Ef};function qs(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Pf(e,t){let n=null,o;const r=Ce(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 u=e.getBoundingClientRect(),{left:f,top:d,width:v,height:h}=u;if(c||t(),!v||!h)return;const g=Ut(d),m=Ut(r.clientWidth-(f+v)),b=Ut(r.clientHeight-(d+h)),x=Ut(f),y={rootMargin:-g+"px "+-m+"px "+-b+"px "+-x+"px",threshold:ue(0,De(1,l))||1};let C=!0;function E(R){const S=R[0].intersectionRatio;if(S!==l){if(!C)return i();S?i(!1,S):o=setTimeout(()=>{i(!1,1e-7)},1e3)}S===1&&!qs(u,e.getBoundingClientRect())&&i(),C=!1}try{n=new IntersectionObserver(E,{...y,root:r.ownerDocument})}catch{n=new IntersectionObserver(E,y)}n.observe(e)}return i(!0),s}function Zs(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,u=Ho(e),f=r||s?[...u?Rt(u):[],...Rt(t)]:[];f.forEach(x=>{r&&x.addEventListener("scroll",n,{passive:!0}),s&&x.addEventListener("resize",n)});const d=u&&c?Pf(u,n):null;let v=-1,h=null;i&&(h=new ResizeObserver(x=>{let[w]=x;w&&w.target===u&&h&&(h.unobserve(t),cancelAnimationFrame(v),v=requestAnimationFrame(()=>{var y;(y=h)==null||y.observe(t)})),n()}),u&&!l&&h.observe(u),h.observe(t));let g,m=l?Xe(e):null;l&&b();function b(){const x=Xe(e);m&&!qs(m,x)&&n(),m=x,g=requestAnimationFrame(b)}return n(),()=>{var x;f.forEach(w=>{r&&w.removeEventListener("scroll",n),s&&w.removeEventListener("resize",n)}),d==null||d(),(x=h)==null||x.disconnect(),h=null,l&&cancelAnimationFrame(g)}}
vendor: 1,146 bytes, line 1
1const Rf=rf,Af=sf,Tf=tf,_f=cf,$f=nf,qr=ef,If=af,Nf=(e,t,n)=>{const o=new Map,r={platform:Sf,...n},s={...r.platform,_c:o};return Jd(e,t,{...r,platform:s})};var Zt=typeof document<"u"?a.useLayoutEffect:a.useEffect;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,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(!on(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)&&!on(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function Qs(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Zr(e,t){const n=Qs(e);return Math.round(t*n)/n}function Un(e){const t=a.useRef(e);return Zt(()=>{t.current=e}),t}function Js(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:u}
1=e,[f,d]=a.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[v,h]=a.useState(o);on(v,o)||h(o);const[g,m]=a.useState(null),[b,x]=a.useState(null),w=a.useCallback(M=>{M!==R.current&&(R.current=M,m(M))},[]),y=a.useCallback(M=>{M!==S.current&&(S.current=M,x(M))},[]),C=s||g,E=i||b,R=a.useRef(null),S=a.useRef(null),A=a.useRef(f),$=l!=null,N=Un(l),O=Un(r),j=Un(u),V=a.useCallback(()=>{if(!R.current||!S.current)return;const M={placement:t,strategy:n,middleware:v};O.current&&(M.platform=O.current),Nf(R.current,S.current,M).then(_=>{const H={..._,isPositioned:j.current!==!1};T.current&&!on(A.current,H)&&(A.current=H,Je.flushSync(()=>{d(H)}))})},[v,t,n,O,j]);Zt(()=>{u===!1&&A.current.isPositioned&&(A.current.isPositioned=!1,d(M=>({...M,isPositioned:!1})))},[u]);const T=a.useRef(!1);Zt(()=>(T.current=!0,()=>{T.current=!1}),[]),Zt(()=>{if(C&&(R.current=C),E&&(S.current=E),C&&E){if(N.current)return N.current(C,E,V);V()}},[C,E,V,N,$]);const L=a.useMemo(()=>({reference:R,floating:S,setReference:w,setFloating:y}),[w,y]),D=a.useMemo(()=>({reference:C,floating:E}),[C,E]),B=a.useMemo(()=>{const M={position:n,left:0,top:0};if(!D.floating)return M;const _=Zr(D.floating,f.x),H=Zr(D.floating,f.y);return c?{...M,transform:"translate("+_+"px, "+H+"px)",...Qs(D.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:_,top:H}},[n,c,D.floating,f.x,f.y]);return a.useMemo(()=>({...f,update:V,refs:L,elements:D,floatingStyles:B}),[f,V,L,D,B])}const Mf=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?qr({element:o.current,padding:r}).fn(n):{}:o?qr({element:o,padding:r}).fn(n):{}}}},ea=(e,t)=>({...Rf(e),options:[e,t]}),ta=(e,t)=>({...Af(e),options:[e,t]}),na=(e,t)=>({...If(e),options:[e,t]}),oa=(e,t)=>({...Tf(e),options:[e,t]}),ra=(e,t)=>({..._f(e),options:[e,t]}),sa=(e,t)=>({...$f(e),options:[e,t]}),aa=(e,t)=>({...Mf(e),options:[e,t]});var Of="Arrow",ia=a.forwardRef((e,t)=>{const{children:n,width:o=10,height:r=5,...s}=e;return p.jsx(I.svg,{...s,ref:t,width:o,height:r,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:p.jsx("polygon",{points:"0,0 30,0 15,10"})})});ia.displayName=Of;var Df=ia;function Nt(e){const[t,n]=a.useState(void 0);return Q(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const o=new ResizeObserver(r=>{if(!Array.isArray(r)||!r.length)return;const s=r[0];let i,c;if("borderBoxSize"in s){const l=s.borderBoxSize,u=Array.isArray(l)?l[0]:l;i=u.inlineSize,c=u.blockSize}else i=e.offsetWidth,c=e.offsetHeight;n({width:i,height:c})});return o.observe(e,{box:"border-box"}),()=>o.unobserve(e)}else n(void 0)},[e]),t}var Ko="Popper",[ca,Fe]=Z(Ko),[Lf,la]=ca(Ko),ua=e=>{const{__scopePopper:t,children:n}=e,[o,r]=a.useState(null);return p.jsx(Lf,{scope:t,anchor:o,onAnchorChange:r,children:n})};ua.displayName=Ko;var da="PopperAnchor",fa=a.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:o,...r}=e,s=la(da,n),i=a.useRef(null),c=F(t,i);return a.useEffect(()=>{s.onAnchorChange((o==null?void 0:o.current)||i.current)}),o?null:p.jsx(I.div,{...r,ref:c})});fa.displayName=da;var Go="PopperContent",[kf,jf]=ca(Go),pa=a.forwardRef((e,t)=>{var k,U,z,W,K,G;const{__scopePopper:n,side:o="bottom",sideOffset:r=0,align:s="center",alignOffset:i=0,arrowPadding:c=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:f=0,sticky:d="partial",hideWhenDetached:v=!1,updatePositionStrategy:h="optimized",onPlaced:g,...m}=e,b=la(Go,n),[x,w]=a.useState(null),y=F(t,te=>w(te)),[C,E]=a.useState(null),R=Nt(C),S=(R==null?void 0:R.width)??0,A=(R==null?void 0:R.height)??0,$=o+(s!=="center"?"-"+s:""),N=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},O=Array.isArray(u)?u:[u],j=O.length>0,V={padding:N,boundary:O.filter(Vf),altBoundary:j},{refs:T,floatingStyles:L,placement:D,isPositioned:B,middlewareData:M}=Js({strategy:"fixed",placement:$,whileElementsMounted:(...te)=>Zs(...te,{animationFrame:h==="always"}),elements:{reference:b.anchor},middleware:[ea({mainAxis:r+A,alignmentAxis:i}),l&&ta({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?na():void 0,...V}),l&&oa({...V}),ra({...V,apply:({elements:te,rects:le,availableWidth:Ge,availableHeight:ze})=>{const{width:Ye,height:Bn}=le.reference,Se=te.floating.style;Se.setProperty("--radix-popper-available-width",`${Ge}px`),Se.setProperty("--radix-popper-available-height",`${ze}px`),Se.setProperty("--radix-popper-anchor-width",`${Ye}px`),Se.setProperty("--radix-popper-anchor-height",`${Bn}px`)}}),C&&aa({element:C,padding:c}),Bf({arrowWidth:S,arrowHeight:A}),v&&sa({strategy:"referenceHidden",...V})]}),[_,H]=ha(D),X=q(g);Q(()=>{B&&(X==null||X())},[B,X]);const J=(k=M.arrow)==null?void 0:k.x,re=(U=M.arrow)==null?void 0:U.y,oe=((z=M.arrow)==null?void 0:z.centerOffset)!==0,[ve,ae]=a.useState();return Q(()=>{x&&ae(window.getComputedStyle(x).zIndex)},[x]),p.jsx("div",{ref:T.setFloating,"data-radix-popper-content-wrapper":"",style:{...L,transform:B?L.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ve,"--radix-popper-transform-origin":[(W=M.transformOrigin)==null?void 0:W.x,(K=M.transformOrigin)==null?void 0:K.y].join(" "),...((G=M.hide)==null?void 0:G.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:p.jsx(kf,{scope:n,placedSide:_,onArrowChange:E,arrowX:J,arrowY:re,shouldHideArrow:oe,children:p.jsx(I.div,{"data-side":_,"data-align":H,...m,ref:y,style:{...m.style,animation:B?void 0:"none"}})})})});pa.displayName=Go;var va="PopperArrow",Ff={top:"bottom",right:"left",bottom:"top",left:"r
1ight"},ma=a.forwardRef(function(t,n){const{__scopePopper:o,...r}=t,s=jf(va,o),i=Ff[s.placedSide];return p.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:p.jsx(Df,{...r,ref:n,style:{...r.style,display:"block"}})})});ma.displayName=va;function Vf(e){return e!==null}var Bf=e=>({name:"transformOrigin",options:e,fn(t){var b,x,w;const{placement:n,rects:o,middlewareData:r}=t,i=((b=r.arrow)==null?void 0:b.centerOffset)!==0,c=i?0:e.arrowWidth,l=i?0:e.arrowHeight,[u,f]=ha(n),d={start:"0%",center:"50%",end:"100%"}[f],v=(((x=r.arrow)==null?void 0:x.x)??0)+c/2,h=(((w=r.arrow)==null?void 0:w.y)??0)+l/2;let g="",m="";return u==="bottom"?(g=i?d:`${v}px`,m=`${-l}px`):u==="top"?(g=i?d:`${v}px`,m=`${o.floating.height+l}px`):u==="right"?(g=`${-l}px`,m=i?d:`${h}px`):u==="left"&&(g=`${o.floating.width+l}px`,m=i?d:`${h}px`),{data:{x:g,y:m}}}});function ha(e){const[t,n="center"]=e.split("-");return[t,n]}var wn=ua,Mt=fa,yn=pa,Cn=ma,[En]=Z("Tooltip",[Fe]),Sn=Fe(),ga="TooltipProvider",Wf=700,fo="tooltip.open",[Hf,zo]=En(ga),ba=e=>{const{__scopeTooltip:t,delayDuration:n=Wf,skipDelayDuration:o=300,disableHoverableContent:r=!1,children:s}=e,i=a.useRef(!0),c=a.useRef(!1),l=a.useRef(0);return a.useEffect(()=>{const u=l.current;return()=>window.clearTimeout(u)},[]),p.jsx(Hf,{scope:t,isOpenDelayedRef:i,delayDuration:n,onOpen:a.useCallback(()=>{window.clearTimeout(l.current),i.current=!1},[]),onClose:a.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>i.current=!0,o)},[o]),isPointerInTransitRef:c,onPointerInTransitChange:a.useCallback(u=>{c.current=u},[]),disableHoverableContent:r,children:s})};ba.displayName=ga;var Pn="Tooltip",[Uf,Rn]=En(Pn),xa=e=>{const{__scopeTooltip:t,children:n,open:o,defaultOpen:r=!1,onOpenChange:s,disableHoverableContent:i,delayDuration:c}=e,l=zo(Pn,e.__scopeTooltip),u=Sn(t),[f,d]=a.useState(null),v=ce(),h=a.useRef(0),g=i??l.disableHoverableContent,m=c??l.delayDuration,b=a.useRef(!1),[x=!1,w]=se({prop:o,defaultProp:r,onChange:S=>{S?(l.onOpen(),document.dispatchEvent(new CustomEvent(fo))):l.onClose(),s==null||s(S)}}),y=a.useMemo(()=>x?b.current?"delayed-open":"instant-open":"closed",[x]),C=a.useCallback(()=>{window.clearTimeout(h.current),h.current=0,b.current=!1,w(!0)},[w]),E=a.useCallback(()=>{window.clearTimeout(h.current),h.current=0,w(!1)},[w]),R=a.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>{b.current=!0,w(!0),h.current=0},m)},[m,w]);return a.useEffect(()=>()=>{h.current&&(window.clearTimeout(h.current),h.current=0)},[]),p.jsx(wn,{...u,children:p.jsx(Uf,{scope:t,contentId:v,open:x,stateAttribute:y,trigger:f,onTriggerChange:d,onTriggerEnter:a.useCallback(()=>{l.isOpenDelayedRef.current?R():C()},[l.isOpenDelayedRef,R,C]),onTriggerLeave:a.useCallback(()=>{g?E():(window.clearTimeout(h.current),h.current=0)},[E,g]),onOpen:C,onClose:E,disableHoverableContent:g,children:n})})};xa.displayName=Pn;var po="TooltipTrigger",wa=a.forwardRef((e,t)=>{const{__scopeTooltip:n,...o}=e,r=Rn(po,n),s=zo(po,n),i=Sn(n),c=a.useRef(null),l=F(t,c,r.onTriggerChange),u=a.useRef(!1),f=a.useRef(!1),d=a.useCallback(()=>u.current=!1,[]);return a.useEffect(()=>()=>document.removeEventListener("pointerup",d),[d]),p.jsx(Mt,{asChild:!0,...i,children:p.jsx(I.button,{"aria-describedby":r.open?r.contentId:void 0,"data-state":r.stateAttribute,...o,ref:l,onPointerMove:P(e.onPointerMove,v=>{v.pointerType!=="touch"&&!f.current&&!s.isPointerInTransitRef.current&&(r.onTriggerEnter(),f.current=!0)}),onPointerLeave:P(e.onPointerLeave,()=>{r.onTriggerLeave(),f.current=!1}),onPointerDown:P(e.onPointerDown,()=>{r.open&&r.onClose(),u.current=!0,document.addEventListener("pointerup",d,{once:!0})}),onFocus:P(e.onFocus,()=>{u.current||r.onOpen()}),onBlur:P(e.onBlur,r.onClose),onClick:P(e.onClick,r.onClose)})})});wa.displayName=po;var Kf="TooltipPortal",[Qx,Gf]=En(Kf,{forceMount:void 0}),dt="TooltipContent",ya=a.forwardRef((e,t)=>
1{const n=Gf(dt,e.__scopeTooltip),{forceMount:o=n.forceMount,side:r="top",...s}=e,i=Rn(dt,e.__scopeTooltip);return p.jsx(ee,{present:o||i.open,children:i.disableHoverableContent?p.jsx(Ca,{side:r,...s,ref:t}):p.jsx(zf,{side:r,...s,ref:t})})}),zf=a.forwardRef((e,t)=>{const n=Rn(dt,e.__scopeTooltip),o=zo(dt,e.__scopeTooltip),r=a.useRef(null),s=F(t,r),[i,c]=a.useState(null),{trigger:l,onClose:u}=n,f=r.current,{onPointerInTransitChange:d}=o,v=a.useCallback(()=>{c(null),d(!1)},[d]),h=a.useCallback((g,m)=>{const b=g.currentTarget,x={x:g.clientX,y:g.clientY},w=Qf(x,b.getBoundingClientRect()),y=Jf(x,w),C=ep(m.getBoundingClientRect()),E=np([...y,...C]);c(E),d(!0)},[d]);return a.useEffect(()=>()=>v(),[v]),a.useEffect(()=>{if(l&&f){const g=b=>h(b,f),m=b=>h(b,l);return l.addEventListener("pointerleave",g),f.addEventListener("pointerleave",m),()=>{l.removeEventListener("pointerleave",g),f.removeEventListener("pointerleave",m)}}},[l,f,h,v]),a.useEffect(()=>{if(i){const g=m=>{const b=m.target,x={x:m.clientX,y:m.clientY},w=(l==null?void 0:l.contains(b))||(f==null?void 0:f.contains(b)),y=!tp(x,i);w?v():y&&(v(),u())};return document.addEventListener("pointermove",g),()=>document.removeEventListener("pointermove",g)}},[l,f,i,u,v]),p.jsx(Ca,{...e,ref:s})}),[Yf,Xf]=En(Pn,{isInside:!1}),qf=Ps("TooltipContent"),Ca=a.forwardRef((e,t)=>{const{__scopeTooltip:n,children:o,"aria-label":r,onEscapeKeyDown:s,onPointerDownOutside:i,...c}=e,l=Rn(dt,n),u=Sn(n),{onClose:f}=l;return a.useEffect(()=>(document.addEventListener(fo,f),()=>document.removeEventListener(fo,f)),[f]),a.useEffect(()=>{if(l.trigger){const d=v=>{const h=v.target;h!=null&&h.contains(l.trigger)&&f()};return window.addEventListener("scroll",d,{capture:!0}),()=>window.removeEventListener("scroll",d,{capture:!0})}},[l.trigger,f]),p.jsx(et,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:d=>d.preventDefault(),onDismiss:f,children:p.jsxs(yn,{"data-state":l.stateAttribute,...u,...c,ref:t,style:{...c.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[p.jsx(qf,{children:o}),p.jsx(Yf,{scope:n,isInside:!0,children:p.jsx(Pd,{id:l.contentId,role:"tooltip",children:r||o})})]})})});ya.displayName=dt;var Ea="TooltipArrow",Zf=a.forwardRef((e,t)=>{const{__scopeTooltip:n,...o}=e,r=Sn(n);return Xf(Ea,n).isInside?null:p.jsx(Cn,{...r,...o,ref:t})});Zf.displayName=Ea;function Qf(e,t){const n=Math.abs(t.top-e.y),o=Math.abs(t.bottom-e.y),r=Math.abs(t.right-e.x),s=Math.abs(t.left-e.x);switch(Math.min(n,o,r,s)){case s:return"left";case r:return"right";case n:return"top";case o:return"bottom";default:throw new Error("unreachable")}}function Jf(e,t,n=5){const o=[];switch(t){case"top":o.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":o.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":o.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":o.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return o}function ep(e){const{top:t,right:n,bottom:o,left:r}=e;return[{x:r,y:t},{x:n,y:t},{x:n,y:o},{x:r,y:o}]}function tp(e,t){const{x:n,y:o}=e;let r=!1;for(let s=0,i=t.length-1;s<t.length;i=s++){const c=t[s].x,l=t[s].y,u=t[i].x,f=t[i].y;l>o!=f>o&&n<(u-c)*(o-l)/(f-l)+c&&(r=!r)}return r}function np(e){const t=e.slice();return t.sort((n,o)=>n.x<o.x?-1:n.x>o.x?1:n.y<o.y?-1:n.y>o.y?1:0),op(t)}function op(e){if(e.length<=1)return e.slice();const t=[];for(let o=0;o<e.length;o++){const r=e[o];for(;t.length>=2;){const s=t[t.length-1],i=t[t.length-2];if((s.x-i.x)*(r.y-i.y)>=(s.y-i.y)*(r.x-i.x))t.pop();else break}t.push(r)}t.pop();const n=[];for(let o=e.length-1;o>=0;o--){const r=e[o];for(;n.length>=2;){const s=n[n.length-1],i=n[n.length-2];if((s.x-i.x)*(r.y-i.y)>=(s.y-i.y)*(r.x-i.x))n.pop();else break}n.push(r)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var Jx=ba,ew=xa,tw=wa,nw=ya;function Ot(e){const t=a.useRef({value:e,previous:e});return a.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var Yo="Switch",[rp]=Z(Yo),[sp,ap]=rp(Yo),Sa=a.forwardRef((e,t)=>
1{const{__scopeSwitch:n,name:o,checked:r,defaultChecked:s,required:i,disabled:c,value:l="on",onCheckedChange:u,form:f,...d}=e,[v,h]=a.useState(null),g=F(t,y=>h(y)),m=a.useRef(!1),b=v?f||!!v.closest("form"):!0,[x=!1,w]=se({prop:r,defaultProp:s,onChange:u});return p.jsxs(sp,{scope:n,checked:x,disabled:c,children:[p.jsx(I.button,{type:"button",role:"switch","aria-checked":x,"aria-required":i,"data-state":Aa(x),"data-disabled":c?"":void 0,disabled:c,value:l,...d,ref:g,onClick:P(e.onClick,y=>{w(C=>!C),b&&(m.current=y.isPropagationStopped(),m.current||y.stopPropagation())})}),b&&p.jsx(ip,{control:v,bubbles:!m.current,name:o,value:l,checked:x,required:i,disabled:c,form:f,style:{transform:"translateX(-100%)"}})]})});Sa.displayName=Yo;var Pa="SwitchThumb",Ra=a.forwardRef((e,t)=>{const{__scopeSwitch:n,...o}=e,r=ap(Pa,n);return p.jsx(I.span,{"data-state":Aa(r.checked),"data-disabled":r.disabled?"":void 0,...o,ref:t})});Ra.displayName=Pa;var ip=e=>{const{control:t,checked:n,bubbles:o=!0,...r}=e,s=a.useRef(null),i=Ot(n),c=Nt(t);return a.useEffect(()=>{const l=s.current,u=window.HTMLInputElement.prototype,d=Object.getOwnPropertyDescriptor(u,"checked").set;if(i!==n&&d){const v=new Event("click",{bubbles:o});d.call(l,n),l.dispatchEvent(v)}},[i,n,o]),p.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:n,...r,tabIndex:-1,ref:s,style:{...e.style,...c,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function Aa(e){return e?"checked":"unchecked"}var ow=Sa,rw=Ra,Kn="focusScope.autoFocusOnMount",Gn="focusScope.autoFocusOnUnmount",Qr={bubbles:!1,cancelable:!0},cp="FocusScope",Dt=a.forwardRef((e,t)=>{const{loop:n=!1,trapped:o=!1,onMountAutoFocus:r,onUnmountAutoFocus:s,...i}=e,[c,l]=a.useState(null),u=q(r),f=q(s),d=a.useRef(null),v=F(t,m=>l(m)),h=a.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;a.useEffect(()=>{if(o){let m=function(y){if(h.paused||!c)return;const C=y.target;c.contains(C)?d.current=C:$e(d.current,{select:!0})},b=function(y){if(h.paused||!c)return;const C=y.relatedTarget;C!==null&&(c.contains(C)||$e(d.current,{select:!0}))},x=function(y){if(document.activeElement===document.body)for(const E of y)E.removedNodes.length>0&&$e(c)};document.addEventListener("focusin",m),document.addEventListener("focusout",b);const w=new MutationObserver(x);return c&&w.observe(c,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",m),document.removeEventListener("focusout",b),w.disconnect()}}},[o,c,h.paused]),a.useEffect(()=>{if(c){es.add(h);const m=document.activeElement;if(!c.contains(m)){const x=new CustomEvent(Kn,Qr);c.addEventListener(Kn,u),c.dispatchEvent(x),x.defaultPrevented||(lp(vp(Ta(c)),{select:!0}),document.activeElement===m&&$e(c))}return()=>{c.removeEventListener(Kn,u),setTimeout(()=>{const x=new CustomEvent(Gn,Qr);c.addEventListener(Gn,f),c.dispatchEvent(x),x.defaultPrevented||$e(m??document.body,{select:!0}),c.removeEventListener(Gn,f),es.remove(h)},0)}}},[c,u,f,h]);const g=a.useCallback(m=>{if(!n&&!o||h.paused)return;const b=m.key==="Tab"&&!m.altKey&&!m.ctrlKey&&!m.metaKey,x=document.activeElement;if(b&&x){const w=m.currentTarget,[y,C]=up(w);y&&C?!m.shiftKey&&x===C?(m.preventDefault(),n&&$e(y,{select:!0})):m.shiftKey&&x===y&&(m.preventDefault(),n&&$e(C,{select:!0})):x===w&&m.preventDefault()}},[n,o,h.paused]);return p.jsx(I.div,{tabIndex:-1,...i,ref:v,onKeyDown:g})});Dt.displayName=cp;function lp(e,{select:t=!1}={}){const n=document.activeElement;for(const o of e)if($e(o,{select:t}),document.activeElement!==n)return}function up(e){const t=Ta(e),n=Jr(t,e),o=Jr(t.reverse(),e);return[n,o]}function Ta(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 Jr(e,t){for(const n of e)if(!dp(n,{upTo:t}))return n}function dp(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 fp(e){return e instanceof HTMLInputElement&&"select"in e}function $e(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&fp(e)&&t&&e.select()}}var es=pp();function pp(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=ts(e,t),e.unshift(t)},remove(t){var n;e=ts(e,t),(n=e[0])==null||n.resume()}}}function ts(e,t){const n=[...e],o=n.indexOf(t);return o!==-1&&n.splice(o,1),n}function vp(e){return e.filter(t=>t.tagName!=="A")}var zn=0;function An(){a.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??ns()),document.body.insertAdjacentElement("beforeend",e[1]??ns()),zn++,()=>{zn===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),zn--}},[])}function ns(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.
vendor: 5,610 bytes, lines 1-16
1style.position="fixed",e.style.pointerEvents="none",e}var xe=function(){return xe=Object.assign||function(t){for(var n,o=1,r=arguments.length;o<r;o++){n=arguments[o];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},xe.apply(this,arguments)};function _a(e,t){var n={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.indexOf(o)<0&&(n[o]=e[o]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var r=0,o=Object.getOwnPropertySymbols(e);r<o.length;r++)t.indexOf(o[r])<0&&Object.prototype.propertyIsEnumerable.call(e,o[r])&&(n[o[r]]=e[o[r]]);return n}function mp(e,t,n){if(n||arguments.length===2)for(var o=0,r=t.length,s;o<r;o++)(s||!(o in t))&&(s||(s=Array.prototype.slice.call(t,0,o)),s[o]=t[o]);return e.concat(s||Array.prototype.slice.call(t))}var Qt="right-scroll-bar-position",Jt="width-before-scroll-bar",hp="with-scroll-bars-hidden",gp="--removed-body-scroll-bar-size";function Yn(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function bp(e,t){var n=a.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(o){var r=n.value;r!==o&&(n.value=o,n.callback(o,r))}}}})[0];return n.callback=t,n.facade}var xp=typeof window<"u"?a.useLayoutEffect:a.useEffect,os=new WeakMap;function wp(e,t){var n=bp(null,function(o){return e.forEach(function(r){return Yn(r,o)})});return xp(function(){var o=os.get(n);if(o){var r=new Set(o),s=new Set(e),i=n.current;r.forEach(function(c){s.has(c)||Yn(c,null)}),s.forEach(function(c){r.has(c)||Yn(c,i)})}os.set(n,e)},[e]),n}function yp(e){return e}function Cp(e,t){t===void 0&&(t=yp);var n=[],o=!1,r={read:function(){if(o)throw new 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(s){var i=t(s,o);return n.push(i),function(){n=n.filter(function(c){return c!==i})}},assignSyncMedium:function(s){for(o=!0;n.length;){var i=n;n=[],i.forEach(s)}n={push:function(c){return s(c)},filter:function(){return n}}},assignMedium:function(s){o=!0;var i=[];if(n.length){var c=n;n=[],c.forEach(s),i=n}var l=function(){var f=i;i=[],f.forEach(s)},u=function(){return Promise.resolve().then(l)};u(),n={push:function(f){i.push(f),u()},filter:function(f){return i=i.filter(f),n}}}};return r}function Ep(e){e===void 0&&(e={});var t=Cp(null);return t.options=xe({async:!0,ssr:!1},e),t}var $a=function(e){var t=e.sideCar,n=_a(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var o=t.read();if(!o)throw new Error("Sidecar medium not found");return a.createElement(o,xe({},n))};$a.isSideCarExport=!0;function Sp(e,t){return e.useMedium(t),$a}var Ia=Ep(),Xn=function(){},Tn=a.forwardRef(function(e,t){var n=a.useRef(null),o=a.useState({onScrollCapture:Xn,onWheelCapture:Xn,onTouchMoveCapture:Xn}),r=o[0],s=o[1],i=e.forwardProps,c=e.children,l=e.className,u=e.removeScrollBar,f=e.enabled,d=e.shards,v=e.sideCar,h=e.noIsolation,g=e.inert,m=e.allowPinchZoom,b=e.as,x=b===void 0?"div":b,w=e.gapMode,y=_a(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),C=v,E=wp([n,t]),R=xe(xe({},y),r);return a.createElement(a.Fragment,null,f&&a.createElement(C,{sideCar:Ia,removeScrollBar:u,shards:d,noIsolation:h,inert:g,setCallbacks:s,allowPinchZoom:!!m,lockRef:n,gapMode:w}),i?a.cloneElement(a.Children.only(c),xe(xe({},R),{ref:E})):a.createElement(x,xe({},R,{className:l,ref:E}),c))});Tn.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Tn.classNames={fullWidth:Jt,zeroRight:Qt};var Pp=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function Rp(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=Pp();return t&&e.setAttribute("nonce",t),e}function Ap(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Tp(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var _p=function(){var e=0,t=null;return{add:function(n){e==0&&(t=Rp())&&(Ap(t,n),Tp(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},$p=function(){var e=_p();return function(t,n){a.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Na=function(){var e=$p(),t=function(n){var o=n.styles,r=n.dynamic;return e(o,r),null};return t},Ip={left:0,top:0,right:0,gap:0},qn=function(e){return parseInt(e||"",10)||0},Np=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],o=t[e==="padding"?"paddingTop":"marginTop"],r=t[e==="padding"?"paddingRight":"marginRight"];return[qn(n),qn(o),qn(r)]},Mp=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Ip;var t=Np(e),n=document.documentElement.clientWidth,o=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,o-n+t[2]-t[0])}},Op=Na(),it="data-scroll-locked",Dp=function(e,t,n,o){var r=e.left,s=e.top,i=e.right,c=e.gap;return n===void 0&&(n="margin"),` 2 .`.concat(hp,` { 3 overflow: hidden `).concat(o,`; 4 padding-right: `).concat(c,"px ").concat(o,`; 5 } 6 body[`).concat(it,`] { 7 overflow: hidden `).concat(o,`; 8 overscroll-behavior: contain; 9 `).concat([t&&"position: relative ".concat(o,";"),n==="margin"&&` 10 padding-left: `.concat(r,`px; 11 padding-top: `).concat(s,`px; 12 padding-right: `).concat(i,`px; 13 margin-left:0; 14 margin-top:0; 15 margin-right: `).concat(c,"px ").concat(o,`; 16 `),n==="padding"&&"padding-right: ".concat(c,"px ").concat(o,";
16")].filter(Boolean).join(""),` 17 } 18 19 .`).concat(Qt,` { 20 right: `).concat(c,"px ").concat(o,`; 21 } 22 23 .`).concat(Jt,` { 24 margin-right: `).concat(c,"px ").concat(o,`; 25 } 26 27 .`).concat(Qt," .").concat(Qt,` { 28 right: 0 `).concat(o,`; 29 } 30 31 .`).concat(Jt," .").concat(Jt,` { 32 margin-right: 0 `).concat(o,`; 33 } 34 35 body[`).concat(it,`] { 36 `).concat(gp,": ").concat(c,`px; 37 } 38`)},rs=function(){var e=parseInt(document.body.getAttribute(it)||"0",10);return isFinite(e)?e:0},Lp=function(){a.useEffect(function(){return document.body.setAttribute(it,(rs()+1).toString()),function(){var e=rs()-1;e<=0?document.body.removeAttribute(it):document.body.setAttribute(it,e.toString())}},[])},kp=function(e){var t=e.noRelative,n=e.noImportant,o=e.gapMode,r=o===void 0?"margin":o;Lp();var s=a.useMemo(function(){return Mp(r)},[r]);return a.createElement(Op,{styles:Dp(s,!t,r,n?"":"!important")})},vo=!1;if(typeof window<"u")try{var Kt=Object.defineProperty({},"passive",{get:function(){return vo=!0,!0}});window.addEventListener("test",Kt,Kt),window.removeEventListener("test",Kt,Kt)}catch{vo=!1}var ot=vo?{passive:!1}:!1,jp=function(e){return e.tagName==="TEXTAREA"},Ma=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!jp(e)&&n[t]==="visible")},Fp=function(e){return Ma(e,"overflowY")},Vp=function(e){return Ma(e,"overflowX")},ss=function(e,t){var n=t.ownerDocument,o=t;do{typeof ShadowRoot<"u"&&o instanceof ShadowRoot&&(o=o.host);var r=Oa(e,o);if(r){var s=Da(e,o),i=s[1],c=s[2];if(i>c)return!0}o=o.parentNode}while(o&&o!==n.body);return!1},Bp=function(e){var t=e.scrollTop,n=e.scrollHeight,o=e.clientHeight;return[t,n,o]},Wp=function(e){var t=e.scrollLeft,n=e.scrollWidth,o=e.clientWidth;return[t,n,o]},Oa=function(e,t){return e==="v"?Fp(t):Vp(t)},Da=function(e,t){return e==="v"?Bp(t):Wp(t)},Hp=function(e,t){return e==="h"&&t==="rtl"?-1:1},Up=function(e,t,n,o,r){var s=Hp(e,window.getComputedStyle(t).direction),i=s*o,c=n.target,l=t.contains(c),u=!1,f=i>0,d=0,v=0;do{var h=Da(e,c),g=h[0],m=h[1],b=h[2],x=m-b-s*g;(g||x)&&Oa(e,c)&&(d+=x,v+=g),c instanceof ShadowRoot?c=c.host:c=c.parentNode}while(!l&&c!==document.body||l&&(t.contains(c)||t===c));return(f&&Math.abs(d)<1||!f&&Math.abs(v)<1)&&(u=!0),u},Gt=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},as=function(e){return[e.deltaX,e.deltaY]},is=function(e){return e&&"current"in e?e.current:e},Kp=function(e,t){return e[0]===t[0]&&e[1]===t[1]},Gp=function(e){return` 39 .block-interactivity-`.concat(e,` {pointer-events: none;} 40 .allow-interactivity-`).concat(e,` {pointer-events: all;} 41`)},zp=0,rt=[];function Yp(e){var t=a.useRef([]),n=a.useRef([0,0]),o=a.useRef(),r=a.useState(zp++)[0],s=a.useState(Na)[0],i=a.useRef(e);a.useEffect(function(){i.current=e},[e]),a.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(r));var m=mp([e.lockRef.current],(e.shards||[]).map(is),!0).filter(Boolean);return m.forEach(function(b){return b.classList.add("allow-interactivity-".concat(r))}),function(){document.body.classList.remove("block-interactivity-".concat(r)),m.forEach(function(b){return b.classList.remove("allow-interactivity-".concat(r))})}}},[e.inert,e.lockRef.current,e.shards]);var c=a.useCallback(function(m,b){if("touches"in m&&m.touches.length===2||m.type==="wheel"&&m.ctrlKey)return!i.current.allowPinchZoom;var x=Gt(m),w=n.current,y="deltaX"in m?m.deltaX:w[0]-x[0],C="deltaY"in m?m.deltaY:w[1]-x[1],E,R=m.target,S=Math.abs(y)>Math.abs(C)?"h":"v";if("touches"in m&&S==="h"&&R.type==="range")return!1;var A=ss(S,R);if(!A)return!0;if(A?E=S:(E=S==="v"?"h":"v",A=ss(S,R)),!A)return!1;if(!o.current&&"changedTouches"in m&&(y||C)&&(o.current=E),!E)return!0;var $=o.current||E;return Up($,b,m,$==="h"?y:C)},[]),l=a.useCallback(function(m){var b=m;if(!(!rt.length||rt[rt.length-1]!==s)){var x="deltaY"in b?as(b):Gt(b),w=t.current.filter(function(E){return E.name===b.type&&(E.target===b.target||b.target===E.shadowParent)&&Kp(E.delta,x)})[0];if(w&&w.should){b.cancelable&&b.preventDefault();return}
vendor: 4,294 bytes, line 41
41if(!w){var y=(i.current.shards||[]).map(is).filter(Boolean).filter(function(E){return E.contains(b.target)}),C=y.length>0?c(b,y[0]):!i.current.noIsolation;C&&b.cancelable&&b.preventDefault()}}},[]),u=a.useCallback(function(m,b,x,w){var y={name:m,delta:b,target:x,should:w,shadowParent:Xp(x)};t.current.push(y),setTimeout(function(){t.current=t.current.filter(function(C){return C!==y})},1)},[]),f=a.useCallback(function(m){n.current=Gt(m),o.current=void 0},[]),d=a.useCallback(function(m){u(m.type,as(m),m.target,c(m,e.lockRef.current))},[]),v=a.useCallback(function(m){u(m.type,Gt(m),m.target,c(m,e.lockRef.current))},[]);a.useEffect(function(){return rt.push(s),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:v}),document.addEventListener("wheel",l,ot),document.addEventListener("touchmove",l,ot),document.addEventListener("touchstart",f,ot),function(){rt=rt.filter(function(m){return m!==s}),document.removeEventListener("wheel",l,ot),document.removeEventListener("touchmove",l,ot),document.removeEventListener("touchstart",f,ot)}},[]);var h=e.removeScrollBar,g=e.inert;return a.createElement(a.Fragment,null,g?a.createElement(s,{styles:Gp(r)}):null,h?a.createElement(kp,{gapMode:e.gapMode}):null)}function Xp(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const qp=Sp(Ia,Yp);var xt=a.forwardRef(function(e,t){return a.createElement(Tn,xe({},e,{ref:t,sideCar:qp}))});xt.classNames=Tn.classNames;var Zp=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},st=new WeakMap,zt=new WeakMap,Yt={},Zn=0,La=function(e){return e&&(e.host||La(e.parentNode))},Qp=function(e,t){return t.map(function(n){if(e.contains(n))return n;var o=La(n);return o&&e.contains(o)?o:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},Jp=function(e,t,n,o){var r=Qp(t,Array.isArray(e)?e:[e]);Yt[n]||(Yt[n]=new WeakMap);var s=Yt[n],i=[],c=new Set,l=new Set(r),u=function(d){!d||c.has(d)||(c.add(d),u(d.parentNode))};r.forEach(u);var f=function(d){!d||l.has(d)||Array.prototype.forEach.call(d.children,function(v){if(c.has(v))f(v);else try{var h=v.getAttribute(o),g=h!==null&&h!=="false",m=(st.get(v)||0)+1,b=(s.get(v)||0)+1;st.set(v,m),s.set(v,b),i.push(v),m===1&&g&&zt.set(v,!0),b===1&&v.setAttribute(n,"true"),g||v.setAttribute(o,"true")}catch(x){console.error("aria-hidden: cannot operate on ",v,x)}})};return f(t),c.clear(),Zn++,function(){i.forEach(function(d){var v=st.get(d)-1,h=s.get(d)-1;st.set(d,v),s.set(d,h),v||(zt.has(d)||d.removeAttribute(o),zt.delete(d)),h||d.removeAttribute(n)}),Zn--,Zn||(st=new WeakMap,st=new WeakMap,zt=new WeakMap,Yt={})}},Lt=function(e,t,n){n===void 0&&(n="data-aria-hidden");var o=Array.from(Array.isArray(e)?e:[e]),r=Zp(e);return r?(o.push.apply(o,Array.from(r.querySelectorAll("[aria-live]"))),Jp(o,r,n,"aria-hidden")):function(){return null}},Xo="Dialog",[ka,ja]=Z(Xo),[ev,be]=ka(Xo),Fa=e=>{const{__scopeDialog:t,children:n,open:o,defaultOpen:r,onOpenChange:s,modal:i=!0}=e,c=a.useRef(null),l=a.useRef(null),[u=!1,f]=se({prop:o,defaultProp:r,onChange:s});return p.jsx(ev,{scope:t,triggerRef:c,contentRef:l,contentId:ce(),titleId:ce(),descriptionId:ce(),open:u,onOpenChange:f,onOpenToggle:a.useCallback(()=>f(d=>!d),[f]),modal:i,children:n})};Fa.displayName=Xo;var Va="DialogTrigger",Ba=a.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=be(Va,n),s=F(t,r.triggerRef);return p.jsx(I.button,{type:"button","aria-haspopup":"dialog","aria-expanded":r.open,"aria-controls":r.contentId,"data-state":Qo(r.open),...o,ref:s,onClick:P(e.onClick,r.onOpenToggle)})});Ba.displayName=Va;var qo="DialogPortal",[tv,Wa]=ka(qo,{forceMount:void 0}),Ha=e=>{const{__scopeDialog:t,forceMount:n,children:o,container:r}=e,s=be(qo,t);return p.jsx(tv,{scope:t,forceMount:n,children:a.Children.map(o,i=>p.jsx(ee,{present:n||s.open,children:p.jsx(ht,{asChild:!0,container:r,children:i})}))})};Ha.displayName=qo;var rn="DialogOverlay",Ua=a.forwardRef((e,t)=>{const n=Wa(rn,e.__scopeDialog),{forceMount:o=n.forceMount,...r}=e,s=be(rn,e.__scopeDialog);return s.modal?p.jsx(ee,{present:o||s.open,children:p.jsx(ov,{...r,ref:t})}):null});Ua.displayName=rn;var nv=Oe("DialogOverlay.RemoveScroll"),ov=a.forwardRef((e,t)=>
41{const{__scopeDialog:n,...o}=e,r=be(rn,n);return p.jsx(xt,{as:nv,allowPinchZoom:!0,shards:[r.contentRef],children:p.jsx(I.div,{"data-state":Qo(r.open),...o,ref:t,style:{pointerEvents:"auto",...o.style}})})}),qe="DialogContent",Ka=a.forwardRef((e,t)=>{const n=Wa(qe,e.__scopeDialog),{forceMount:o=n.forceMount,...r}=e,s=be(qe,e.__scopeDialog);return p.jsx(ee,{present:o||s.open,children:s.modal?p.jsx(rv,{...r,ref:t}):p.jsx(sv,{...r,ref:t})})});Ka.displayName=qe;var rv=a.forwardRef((e,t)=>{const n=be(qe,e.__scopeDialog),o=a.useRef(null),r=F(t,n.contentRef,o);return a.useEffect(()=>{const s=o.current;if(s)return Lt(s)},[]),p.jsx(Ga,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:P(e.onCloseAutoFocus,s=>{var i;s.preventDefault(),(i=n.triggerRef.current)==null||i.focus()}),onPointerDownOutside:P(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,c=i.button===0&&i.ctrlKey===!0;(i.button===2||c)&&s.preventDefault()}),onFocusOutside:P(e.onFocusOutside,s=>s.preventDefault())})}),sv=a.forwardRef((e,t)=>{const n=be(qe,e.__scopeDialog),o=a.useRef(!1),r=a.useRef(!1);return p.jsx(Ga,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var i,c;(i=e.onCloseAutoFocus)==null||i.call(e,s),s.defaultPrevented||(o.current||(c=n.triggerRef.current)==null||c.focus(),s.preventDefault()),o.current=!1,r.current=!1},onInteractOutside:s=>{var l,u;(l=e.onInteractOutside)==null||l.call(e,s),s.defaultPrevented||(o.current=!0,s.detail.originalEvent.type==="pointerdown"&&(r.current=!0));const i=s.target;((u=n.triggerRef.current)==null?void 0:u.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&r.current&&s.preventDefault()}})}),Ga=a.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:o,onOpenAutoFocus:r,onCloseAutoFocus:s,...i}=e,c=be(qe,n),l=a.useRef(null),u=F(t,l);return An(),p.jsxs(p.Fragment,{children:[p.jsx(Dt,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:r,onUnmountAutoFocus:s,children:p.jsx(et,{role:"dialog",id:c.contentId,"aria-describedby":c.descriptionId,"aria-labelledby":c.titleId,"data-state":Qo(c.open),...i,ref:u,onDismiss:()=>c.onOpenChange(!1)})}),p.jsxs(p.Fragment,{children:[p.jsx(iv,{titleId:c.titleId}),p.jsx(lv,{contentRef:l,descriptionId:c.descriptionId})]})]})}),Zo="DialogTitle",za=a.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=be(Zo,n);return p.jsx(I.h2,{id:r.titleId,...o,ref:t})});za.displayName=Zo;var Ya="DialogDescription",Xa=a.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=be(Ya,n);return p.jsx(I.p,{id:r.descriptionId,...o,ref:t})});Xa.displayName=Ya;var qa="DialogClose",Za=a.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=be(qa,n);return p.jsx(I.button,{type:"button",...o,ref:t,onClick:P(e.onClick,()=>r.onOpenChange(!1))})});Za.displayName=qa;function Qo(e){return e?"open":"closed"}var Qa="DialogTitleWarning",[av,Ja]=od(Qa,{contentName:qe,titleName:Zo,docsSlug:"dialog"}),iv=({titleId:e})=>{const t=Ja(Qa),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users. 42 43If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component. 44 45For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return a.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},cv="DialogDescriptionWarning",lv=({contentRef:e,descriptionId:t})=>{const o=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${Ja(cv).contentName}}.`;return a.useEffect(()=>{var s;const r=(s=e.current)==null?void 0:s.getAttribute("aria-describedby");t&&r&&(document.getElementById(t)||console.warn(o))},[o,e,t]),null},uv=Fa,dv=Ba,fv=Ha,pv=Ua,vv=Ka,mv=za,hv=Xa,ei=Za,Jo="Avatar",[gv]=Z(Jo),[bv,ti]=gv(Jo),ni=a.forwardRef((e,t)=>{const{__scopeAvatar:n,...o}=e,[r,s]=a.useState("idle");return p.jsx(bv,{scope:n,imageLoadingStatus:r,onImageLoadingStatusChange:s,children:p.jsx(I.span,{...o,ref:t})})});ni.displayName=Jo;var oi="AvatarImage",ri=a.forwardRef((e,t)=>{const{__scopeAvatar:n,src:o,onLoadingStatusChange:r=()=>{},...s}=e,i=ti(oi,n),c=xv(o,s),l=q(u=>{r(u),i.onImageLoadingStatusChange(u)});return Q(()=>{c!=="idle"&&l(c)},[c,l]),c==="loaded"?p.jsx(I.img,{...s,ref:t,src:o}):null});ri.displayName=oi;var si="AvatarFallback",ai=a.forwardRef((e,t)=>
45{const{__scopeAvatar:n,delayMs:o,...r}=e,s=ti(si,n),[i,c]=a.useState(o===void 0);return a.useEffect(()=>{if(o!==void 0){const l=window.setTimeout(()=>c(!0),o);return()=>window.clearTimeout(l)}},[o]),i&&s.imageLoadingStatus!=="loaded"?p.jsx(I.span,{...r,ref:t}):null});ai.displayName=si;function cs(e,t){return e?t?(e.src!==t&&(e.src=t),e.complete&&e.naturalWidth>0?"loaded":"loading"):"error":"idle"}function xv(e,{referrerPolicy:t,crossOrigin:n}){const o=yv(),r=a.useRef(null),s=o?(r.current||(r.current=new window.Image),r.current):null,[i,c]=a.useState(()=>cs(s,e));return Q(()=>{c(cs(s,e))},[s,e]),Q(()=>{const l=d=>()=>{c(d)};if(!s)return;const u=l("loaded"),f=l("error");return s.addEventListener("load",u),s.addEventListener("error",f),t&&(s.referrerPolicy=t),typeof n=="string"&&(s.crossOrigin=n),()=>{s.removeEventListener("load",u),s.removeEventListener("error",f)}},[s,n,t]),i}function wv(){return()=>{}}function yv(){return a.useSyncExternalStore(wv,()=>!0,()=>!1)}var sw=ni,aw=ri,iw=ai,Cv=a.createContext(void 0);function Ve(e){const t=a.useContext(Cv);return e||t||"ltr"}var Qn="rovingFocusGroup.onEntryFocus",Ev={bubbles:!1,cancelable:!0},_n="RovingFocusGroup",[mo,ii,Sv]=mt(_n),[Pv,wt]=Z(_n,[Sv]),[Rv,Av]=Pv(_n),ci=a.forwardRef((e,t)=>p.jsx(mo.Provider,{scope:e.__scopeRovingFocusGroup,children:p.jsx(mo.Slot,{scope:e.__scopeRovingFocusGroup,children:p.jsx(Tv,{...e,ref:t})})}));ci.displayName=_n;var Tv=a.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:o,loop:r=!1,dir:s,currentTabStopId:i,defaultCurrentTabStopId:c,onCurrentTabStopIdChange:l,onEntryFocus:u,preventScrollOnEntryFocus:f=!1,...d}=e,v=a.useRef(null),h=F(t,v),g=Ve(s),[m=null,b]=se({prop:i,defaultProp:c,onChange:l}),[x,w]=a.useState(!1),y=q(u),C=ii(n),E=a.useRef(!1),[R,S]=a.useState(0);return a.useEffect(()=>{const A=v.current;if(A)return A.addEventListener(Qn,y),()=>A.removeEventListener(Qn,y)},[y]),p.jsx(Rv,{scope:n,orientation:o,dir:g,loop:r,currentTabStopId:m,onItemFocus:a.useCallback(A=>b(A),[b]),onItemShiftTab:a.useCallback(()=>w(!0),[]),onFocusableItemAdd:a.useCallback(()=>S(A=>A+1),[]),onFocusableItemRemove:a.useCallback(()=>S(A=>A-1),[]),children:p.jsx(I.div,{tabIndex:x||R===0?-1:0,"data-orientation":o,...d,ref:h,style:{outline:"none",...e.style},onMouseDown:P(e.onMouseDown,()=>{E.current=!0}),onFocus:P(e.onFocus,A=>{const $=!E.current;if(A.target===A.currentTarget&&$&&!x){const N=new CustomEvent(Qn,Ev);if(A.currentTarget.dispatchEvent(N),!N.defaultPrevented){const O=C().filter(D=>D.focusable),j=O.find(D=>D.active),V=O.find(D=>D.id===m),L=[j,V,...O].filter(Boolean).map(D=>D.ref.current);di(L,f)}}E.current=!1}),onBlur:P(e.onBlur,()=>w(!1))})})}),li="RovingFocusGroupItem",ui=a.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:o=!0,active:r=!1,tabStopId:s,...i}=e,c=ce(),l=s||c,u=Av(li,n),f=u.currentTabStopId===l,d=ii(n),{onFocusableItemAdd:v,onFocusableItemRemove:h}=u;return a.useEffect(()=>{if(o)return v(),()=>h()},[o,v,h]),p.jsx(mo.ItemSlot,{scope:n,id:l,focusable:o,active:r,children:p.jsx(I.span,{tabIndex:f?0:-1,"data-orientation":u.orientation,...i,ref:t,onMouseDown:P(e.onMouseDown,g=>{o?u.onItemFocus(l):g.preventDefault()}),onFocus:P(e.onFocus,()=>u.onItemFocus(l)),onKeyDown:P(e.onKeyDown,g=>{if(g.key==="Tab"&&g.shiftKey){u.onItemShiftTab();return}if(g.target!==g.currentTarget)return;const m=Iv(g,u.orientation,u.dir);if(m!==void 0){if(g.metaKey||g.ctrlKey||g.altKey||g.shiftKey)return;g.preventDefault();let x=d().filter(w=>w.focusable).map(w=>w.ref.current);if(m==="last")x.reverse();else if(m==="prev"||m==="next"){m==="prev"&&x.reverse();const w=x.indexOf(g.currentTarget);x=u.loop?Nv(x,w+1):x.slice(w+1)}setTimeout(()=>di(x))}})})})});ui.displayName=li;var _v={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function $v(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function Iv(e,t,n){const o=$v(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(o))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(o)))return _v[o]}function di(e,t=!1){const n=document.activeElement;for(const o of e)if(o===n||(o.focus({preventScroll:t}),document.activeElement!==n))return}function Nv(e,t){return e.map((n,o)=>e[(t+o)%e.length])}var er=ci,tr=ui,ho=["Enter"," "],Mv=["ArrowDown","PageUp","Home"],fi=["ArrowUp","PageDown","End"],Ov=[...Mv,...fi],Dv={ltr:[...ho,"ArrowRight"],rtl:[...ho,"ArrowLeft"]},Lv={ltr:["ArrowLeft"],rtl:["ArrowRight"]},kt="Menu",[At,kv,jv]=mt(kt),[tt,pi]=Z(kt,[jv,Fe,wt]),$n=Fe(),vi=wt(),[Fv,nt]=tt(kt),[Vv,jt]=tt(kt),mi=e=>{const{__scopeMenu:t,open:n=!1,children:o,dir:r,onOpenChange:s,modal:i=!0}=e,c=$n(t),[l,u]=a.useState(null),f=a.useRef(!1),d=q(s),v=Ve(r);return a.useEffect(()=>{const h=()=>{f.current=!0,document.addEventListener("pointerdown",g,{capture:!0,once:!0}),document.addEventListener("pointermove",g,{capture:!0,once:!0})},g=()=>f.current=!1;return document.addEventListener("keydown",h,{capture:!0}),()=>{document.removeEventListener("keydown",h,{capture:!0}),document.removeEventListener("pointerdown",g,{capture:!0}),document.removeEventListener("pointermove",g,{capture:!0})}},[]),p.jsx(wn,{...c,children:p.jsx(Fv,{scope:t,open:n,onOpenChange:d,content:l,onContentChange:u,children:p.jsx(Vv,{scope:t,onClose:a.useCallback(()=>d(!1),[d]),isUsingKeyboardRef:f,dir:v,modal:i,children:o})})})};mi.displayName=kt;var Bv="MenuAnchor",nr=a.forwardRef((e,t)=>
45{const{__scopeMenu:n,...o}=e,r=$n(n);return p.jsx(Mt,{...r,...o,ref:t})});nr.displayName=Bv;var or="MenuPortal",[Wv,hi]=tt(or,{forceMount:void 0}),gi=e=>{const{__scopeMenu:t,forceMount:n,children:o,container:r}=e,s=nt(or,t);return p.jsx(Wv,{scope:t,forceMount:n,children:p.jsx(ee,{present:n||s.open,children:p.jsx(ht,{asChild:!0,container:r,children:o})})})};gi.displayName=or;var fe="MenuContent",[Hv,rr]=tt(fe),bi=a.forwardRef((e,t)=>{const n=hi(fe,e.__scopeMenu),{forceMount:o=n.forceMount,...r}=e,s=nt(fe,e.__scopeMenu),i=jt(fe,e.__scopeMenu);return p.jsx(At.Provider,{scope:e.__scopeMenu,children:p.jsx(ee,{present:o||s.open,children:p.jsx(At.Slot,{scope:e.__scopeMenu,children:i.modal?p.jsx(Uv,{...r,ref:t}):p.jsx(Kv,{...r,ref:t})})})})}),Uv=a.forwardRef((e,t)=>{const n=nt(fe,e.__scopeMenu),o=a.useRef(null),r=F(t,o);return a.useEffect(()=>{const s=o.current;if(s)return Lt(s)},[]),p.jsx(sr,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:P(e.onFocusOutside,s=>s.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),Kv=a.forwardRef((e,t)=>{const n=nt(fe,e.__scopeMenu);return p.jsx(sr,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),Gv=Oe("MenuContent.ScrollLock"),sr=a.forwardRef((e,t)=>{const{__scopeMenu:n,loop:o=!1,trapFocus:r,onOpenAutoFocus:s,onCloseAutoFocus:i,disableOutsidePointerEvents:c,onEntryFocus:l,onEscapeKeyDown:u,onPointerDownOutside:f,onFocusOutside:d,onInteractOutside:v,onDismiss:h,disableOutsideScroll:g,...m}=e,b=nt(fe,n),x=jt(fe,n),w=$n(n),y=vi(n),C=kv(n),[E,R]=a.useState(null),S=a.useRef(null),A=F(t,S,b.onContentChange),$=a.useRef(0),N=a.useRef(""),O=a.useRef(0),j=a.useRef(null),V=a.useRef("right"),T=a.useRef(0),L=g?xt:a.Fragment,D=g?{as:Gv,allowPinchZoom:!0}:void 0,B=_=>{var k,U;const H=N.current+_,X=C().filter(z=>!z.disabled),J=document.activeElement,re=(k=X.find(z=>z.ref.current===J))==null?void 0:k.textValue,oe=X.map(z=>z.textValue),ve=rm(oe,H,re),ae=(U=X.find(z=>z.textValue===ve))==null?void 0:U.ref.current;(function z(W){N.current=W,window.clearTimeout($.current),W!==""&&($.current=window.setTimeout(()=>z(""),1e3))})(H),ae&&setTimeout(()=>ae.focus())};a.useEffect(()=>()=>window.clearTimeout($.current),[]),An();const M=a.useCallback(_=>{var X,J;return V.current===((X=j.current)==null?void 0:X.side)&&am(_,(J=j.current)==null?void 0:J.area)},[]);return p.jsx(Hv,{scope:n,searchRef:N,onItemEnter:a.useCallback(_=>{M(_)&&_.preventDefault()},[M]),onItemLeave:a.useCallback(_=>{var H;M(_)||((H=S.current)==null||H.focus(),R(null))},[M]),onTriggerLeave:a.useCallback(_=>{M(_)&&_.preventDefault()},[M]),pointerGraceTimerRef:O,onPointerGraceIntentChange:a.useCallback(_=>{j.current=_},[]),children:p.jsx(L,{...D,children:p.jsx(Dt,{asChild:!0,trapped:r,onMountAutoFocus:P(s,_=>{var H;_.preventDefault(),(H=S.current)==null||H.focus({preventScroll:!0})}),onUnmountAutoFocus:i,children:p.jsx(et,{asChild:!0,disableOutsidePointerEvents:c,onEscapeKeyDown:u,onPointerDownOutside:f,onFocusOutside:d,onInteractOutside:v,onDismiss:h,children:p.jsx(er,{asChild:!0,...y,dir:x.dir,orientation:"vertical",loop:o,currentTabStopId:E,onCurrentTabStopIdChange:R,onEntryFocus:P(l,_=>{x.isUsingKeyboardRef.current||_.preventDefault()}),preventScrollOnEntryFocus:!0,children:p.jsx(yn,{role:"menu","aria-orientation":"vertical","data-state":Oi(b.open),"data-radix-menu-content":"",dir:x.dir,...w,...m,ref:A,style:{outline:"none",...m.style},onKeyDown:P(m.onKeyDown,_=>{const X=_.target.closest("[data-radix-menu-content]")===_.currentTarget,J=_.ctrlKey||_.altKey||_.metaKey,re=_.key.length===1;X&&(_.key==="Tab"&&_.preventDefault(),!J&&re&&B(_.key));const oe=S.current;if(_.target!==oe||!Ov.includes(_.key))return;_.preventDefault();const ae=C().filter(k=>!k.disabled).map(k=>k.ref.current);fi.includes(_.key)&&ae.reverse(),nm(ae)}),onBlur:P(e.onBlur,_=>{_.currentTarget.contains(_.target)||(window.clearTimeout($.current),N.current="")}),onPointerMove:P(e.onPointerMove,Tt(_=>{const H=_.target,X=T.current!==_.clientX;if(_.currentTarget.contains(H)&&X){const J=_.clientX>T.current?"right":"left";V.current=J,T.current=_.clientX}}))})})})})})})});bi.displayName=fe;var zv="MenuGroup",ar=a.forwardRef((e,t)=>
45{const{__scopeMenu:n,...o}=e;return p.jsx(I.div,{role:"group",...o,ref:t})});ar.displayName=zv;var Yv="MenuLabel",xi=a.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e;return p.jsx(I.div,{...o,ref:t})});xi.displayName=Yv;var sn="MenuItem",ls="menu.itemSelect",In=a.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:o,...r}=e,s=a.useRef(null),i=jt(sn,e.__scopeMenu),c=rr(sn,e.__scopeMenu),l=F(t,s),u=a.useRef(!1),f=()=>{const d=s.current;if(!n&&d){const v=new CustomEvent(ls,{bubbles:!0,cancelable:!0});d.addEventListener(ls,h=>o==null?void 0:o(h),{once:!0}),Oo(d,v),v.defaultPrevented?u.current=!1:i.onClose()}};return p.jsx(wi,{...r,ref:l,disabled:n,onClick:P(e.onClick,f),onPointerDown:d=>{var v;(v=e.onPointerDown)==null||v.call(e,d),u.current=!0},onPointerUp:P(e.onPointerUp,d=>{var v;u.current||(v=d.currentTarget)==null||v.click()}),onKeyDown:P(e.onKeyDown,d=>{const v=c.searchRef.current!=="";n||v&&d.key===" "||ho.includes(d.key)&&(d.currentTarget.click(),d.preventDefault())})})});In.displayName=sn;var wi=a.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:o=!1,textValue:r,...s}=e,i=rr(sn,n),c=vi(n),l=a.useRef(null),u=F(t,l),[f,d]=a.useState(!1),[v,h]=a.useState("");return a.useEffect(()=>{const g=l.current;g&&h((g.textContent??"").trim())},[s.children]),p.jsx(At.ItemSlot,{scope:n,disabled:o,textValue:r??v,children:p.jsx(tr,{asChild:!0,...c,focusable:!o,children:p.jsx(I.div,{role:"menuitem","data-highlighted":f?"":void 0,"aria-disabled":o||void 0,"data-disabled":o?"":void 0,...s,ref:u,onPointerMove:P(e.onPointerMove,Tt(g=>{o?i.onItemLeave(g):(i.onItemEnter(g),g.defaultPrevented||g.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:P(e.onPointerLeave,Tt(g=>i.onItemLeave(g))),onFocus:P(e.onFocus,()=>d(!0)),onBlur:P(e.onBlur,()=>d(!1))})})})}),Xv="MenuCheckboxItem",yi=a.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:o,...r}=e;return p.jsx(Ri,{scope:e.__scopeMenu,checked:n,children:p.jsx(In,{role:"menuitemcheckbox","aria-checked":an(n)?"mixed":n,...r,ref:t,"data-state":cr(n),onSelect:P(r.onSelect,()=>o==null?void 0:o(an(n)?!0:!n),{checkForDefaultPrevented:!1})})})});yi.displayName=Xv;var Ci="MenuRadioGroup",[qv,Zv]=tt(Ci,{value:void 0,onValueChange:()=>{}}),Ei=a.forwardRef((e,t)=>{const{value:n,onValueChange:o,...r}=e,s=q(o);return p.jsx(qv,{scope:e.__scopeMenu,value:n,onValueChange:s,children:p.jsx(ar,{...r,ref:t})})});Ei.displayName=Ci;var Si="MenuRadioItem",Pi=a.forwardRef((e,t)=>{const{value:n,...o}=e,r=Zv(Si,e.__scopeMenu),s=n===r.value;return p.jsx(Ri,{scope:e.__scopeMenu,checked:s,children:p.jsx(In,{role:"menuitemradio","aria-checked":s,...o,ref:t,"data-state":cr(s),onSelect:P(o.onSelect,()=>{var i;return(i=r.onValueChange)==null?void 0:i.call(r,n)},{checkForDefaultPrevented:!1})})})});Pi.displayName=Si;var ir="MenuItemIndicator",[Ri,Qv]=tt(ir,{checked:!1}),Ai=a.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:o,...r}=e,s=Qv(ir,n);return p.jsx(ee,{present:o||an(s.checked)||s.checked===!0,children:p.jsx(I.span,{...r,ref:t,"data-state":cr(s.checked)})})});Ai.displayName=ir;var Jv="MenuSeparator",Ti=a.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e;return p.jsx(I.div,{role:"separator","aria-orientation":"horizontal",...o,ref:t})});Ti.displayName=Jv;var em="MenuArrow",_i=a.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e,r=$n(n);return p.jsx(Cn,{...r,...o,ref:t})});_i.displayName=em;var tm="MenuSub",[cw,$i]=tt(tm),Et="MenuSubTrigger",Ii=a.forwardRef((e,t)=>{const n=nt(Et,e.__scopeMenu),o=jt(Et,e.__scopeMenu),r=$i(Et,e.__scopeMenu),s=rr(Et,e.__scopeMenu),i=a.useRef(null),{pointerGraceTimerRef:c,onPointerGraceIntentChange:l}=s,u={__scopeMenu:e.__scopeMenu},f=a.useCallback(()=>{i.current&&window.clearTimeout(i.current),i.current=null},[]);return a.useEffect(()=>f,[f]),a.useEffect(()=>{const d=c.current;return()=>{window.clearTimeout(d),l(null)}},[c,l]),p.jsx(nr,{asChild:!0,...u,children:p.jsx(wi,{id:r.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":r.contentId,"data-state":Oi(n.open),...e,ref:vn(t,r.onTriggerChange),onClick:d=>{var v;(v=e.onClick)==null||v.call(e,d),!(e.disabled||d.defaultPrevented)&&(d.currentTarget.focu
45s(),n.open||n.onOpenChange(!0))},onPointerMove:P(e.onPointerMove,Tt(d=>{s.onItemEnter(d),!d.defaultPrevented&&!e.disabled&&!n.open&&!i.current&&(s.onPointerGraceIntentChange(null),i.current=window.setTimeout(()=>{n.onOpenChange(!0),f()},100))})),onPointerLeave:P(e.onPointerLeave,Tt(d=>{var h,g;f();const v=(h=n.content)==null?void 0:h.getBoundingClientRect();if(v){const m=(g=n.content)==null?void 0:g.dataset.side,b=m==="right",x=b?-5:5,w=v[b?"left":"right"],y=v[b?"right":"left"];s.onPointerGraceIntentChange({area:[{x:d.clientX+x,y:d.clientY},{x:w,y:v.top},{x:y,y:v.top},{x:y,y:v.bottom},{x:w,y:v.bottom}],side:m}),window.clearTimeout(c.current),c.current=window.setTimeout(()=>s.onPointerGraceIntentChange(null),300)}else{if(s.onTriggerLeave(d),d.defaultPrevented)return;s.onPointerGraceIntentChange(null)}})),onKeyDown:P(e.onKeyDown,d=>{var h;const v=s.searchRef.current!=="";e.disabled||v&&d.key===" "||Dv[o.dir].includes(d.key)&&(n.onOpenChange(!0),(h=n.content)==null||h.focus(),d.preventDefault())})})})});Ii.displayName=Et;var Ni="MenuSubContent",Mi=a.forwardRef((e,t)=>{const n=hi(fe,e.__scopeMenu),{forceMount:o=n.forceMount,...r}=e,s=nt(fe,e.__scopeMenu),i=jt(fe,e.__scopeMenu),c=$i(Ni,e.__scopeMenu),l=a.useRef(null),u=F(t,l);return p.jsx(At.Provider,{scope:e.__scopeMenu,children:p.jsx(ee,{present:o||s.open,children:p.jsx(At.Slot,{scope:e.__scopeMenu,children:p.jsx(sr,{id:c.contentId,"aria-labelledby":c.triggerId,...r,ref:u,align:"start",side:i.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:f=>{var d;i.isUsingKeyboardRef.current&&((d=l.current)==null||d.focus()),f.preventDefault()},onCloseAutoFocus:f=>f.preventDefault(),onFocusOutside:P(e.onFocusOutside,f=>{f.target!==c.trigger&&s.onOpenChange(!1)}),onEscapeKeyDown:P(e.onEscapeKeyDown,f=>{i.onClose(),f.preventDefault()}),onKeyDown:P(e.onKeyDown,f=>{var h;const d=f.currentTarget.contains(f.target),v=Lv[i.dir].includes(f.key);d&&v&&(s.onOpenChange(!1),(h=c.trigger)==null||h.focus(),f.preventDefault())})})})})})});Mi.displayName=Ni;function Oi(e){return e?"open":"closed"}function an(e){return e==="indeterminate"}function cr(e){return an(e)?"indeterminate":e?"checked":"unchecked"}function nm(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function om(e,t){return e.map((n,o)=>e[(t+o)%e.length])}function rm(e,t,n){const r=t.length>1&&Array.from(t).every(u=>u===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let i=om(e,Math.max(s,0));r.length===1&&(i=i.filter(u=>u!==n));const l=i.find(u=>u.toLowerCase().startsWith(r.toLowerCase()));return l!==n?l:void 0}function sm(e,t){const{x:n,y:o}=e;let r=!1;for(let s=0,i=t.length-1;s<t.length;i=s++){const c=t[s].x,l=t[s].y,u=t[i].x,f=t[i].y;l>o!=f>o&&n<(u-c)*(o-l)/(f-l)+c&&(r=!r)}return r}function am(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return sm(n,t)}function Tt(e){return t=>t.pointerType==="mouse"?e(t):void 0}var im=mi,cm=nr,lm=gi,um=bi,dm=ar,fm=xi,pm=In,vm=yi,mm=Ei,hm=Pi,gm=Ai,bm=Ti,xm=_i,wm=Ii,ym=Mi,lr="DropdownMenu",[Cm]=Z(lr,[pi]),ie=pi(),[Em,Di]=Cm(lr),Li=e=>{const{__scopeDropdownMenu:t,children:n,dir:o,open:r,defaultOpen:s,onOpenChange:i,modal:c=!0}=e,l=ie(t),u=a.useRef(null),[f=!1,d]=se({prop:r,defaultProp:s,onChange:i});return p.jsx(Em,{scope:t,triggerId:ce(),triggerRef:u,contentId:ce(),open:f,onOpenChange:d,onOpenToggle:a.useCallback(()=>d(v=>!v),[d]),modal:c,children:p.jsx(im,{...l,open:f,onOpenChange:d,dir:o,modal:c,children:n})})};Li.displayName=lr;var ki="DropdownMenuTrigger",ji=a.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:o=!1,...r}=e,s=Di(ki,n),i=ie(n);return p.jsx(cm,{asChild:!0,...i,children:p.jsx(I.button,{type:"button",id:s.triggerId,"aria-haspopup":"menu","aria-expanded":s.open,"aria-controls":s.open?s.contentId:void 0,"data-state":s.open?"open":"closed","data-disabled":o?"":void 0,disabled:o,...r,ref:vn(t,s.triggerRef),onPointerDown:P(e.onPointerDown,c=>{!o&&c.button===0&&c.ctrlKey===!1&&(s.onOpenToggle(),s.open||c.preventDefault())}),onKeyDown:P(e.onKeyDown,c=>{o||(["Enter"," "].includes(c.key)&&s.onOpenToggle(),c.key==="ArrowDown"&&s.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(c.key)&&c.preventDefault())})})})});ji.displayName=ki;var Sm="DropdownMenuPortal",Fi=e=>{const{__scopeDropdownMenu:t,...n}=e,o=ie(t);return p.jsx(lm,{...o,...n})};Fi.displayName=Sm;var Vi="DropdownMenuContent",Bi=a.forwardRef((e,t)=>
45{const{__scopeDropdownMenu:n,...o}=e,r=Di(Vi,n),s=ie(n),i=a.useRef(!1);return p.jsx(um,{id:r.contentId,"aria-labelledby":r.triggerId,...s,...o,ref:t,onCloseAutoFocus:P(e.onCloseAutoFocus,c=>{var l;i.current||(l=r.triggerRef.current)==null||l.focus(),i.current=!1,c.preventDefault()}),onInteractOutside:P(e.onInteractOutside,c=>{const l=c.detail.originalEvent,u=l.button===0&&l.ctrlKey===!0,f=l.button===2||u;(!r.modal||f)&&(i.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Bi.displayName=Vi;var Pm="DropdownMenuGroup",Rm=a.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=ie(n);return p.jsx(dm,{...r,...o,ref:t})});Rm.displayName=Pm;var Am="DropdownMenuLabel",Wi=a.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=ie(n);return p.jsx(fm,{...r,...o,ref:t})});Wi.displayName=Am;var Tm="DropdownMenuItem",Hi=a.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=ie(n);return p.jsx(pm,{...r,...o,ref:t})});Hi.displayName=Tm;var _m="DropdownMenuCheckboxItem",Ui=a.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=ie(n);return p.jsx(vm,{...r,...o,ref:t})});Ui.displayName=_m;var $m="DropdownMenuRadioGroup",Im=a.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=ie(n);return p.jsx(mm,{...r,...o,ref:t})});Im.displayName=$m;var Nm="DropdownMenuRadioItem",Ki=a.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=ie(n);return p.jsx(hm,{...r,...o,ref:t})});Ki.displayName=Nm;var Mm="DropdownMenuItemIndicator",Gi=a.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=ie(n);return p.jsx(gm,{...r,...o,ref:t})});Gi.displayName=Mm;var Om="DropdownMenuSeparator",zi=a.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=ie(n);return p.jsx(bm,{...r,...o,ref:t})});zi.displayName=Om;var Dm="DropdownMenuArrow",Lm=a.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=ie(n);return p.jsx(xm,{...r,...o,ref:t})});Lm.displayName=Dm;var km="DropdownMenuSubTrigger",Yi=a.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=ie(n);return p.jsx(wm,{...r,...o,ref:t})});Yi.displayName=km;var jm="DropdownMenuSubContent",Xi=a.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=ie(n);return p.jsx(ym,{...r,...o,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Xi.displayName=jm;var lw=Li,uw=ji,dw=Fi,fw=Bi,pw=Wi,vw=Hi,mw=Ui,hw=Ki,gw=Gi,bw=zi,xw=Yi,ww=Xi,ur="Collapsible",[Fm,qi]=Z(ur),[Vm,dr]=Fm(ur),Zi=a.forwardRef((e,t)=>{const{__scopeCollapsible:n,open:o,defaultOpen:r,disabled:s,onOpenChange:i,...c}=e,[l=!1,u]=se({prop:o,defaultProp:r,onChange:i});return p.jsx(Vm,{scope:n,disabled:s,contentId:ce(),open:l,onOpenToggle:a.useCallback(()=>u(f=>!f),[u]),children:p.jsx(I.div,{"data-state":pr(l),"data-disabled":s?"":void 0,...c,ref:t})})});Zi.displayName=ur;var Qi="CollapsibleTrigger",Ji=a.forwardRef((e,t)=>{const{__scopeCollapsible:n,...o}=e,r=dr(Qi,n);return p.jsx(I.button,{type:"button","aria-controls":r.contentId,"aria-expanded":r.open||!1,"data-state":pr(r.open),"data-disabled":r.disabled?"":void 0,disabled:r.disabled,...o,ref:t,onClick:P(e.onClick,r.onOpenToggle)})});Ji.displayName=Qi;var fr="CollapsibleContent",ec=a.forwardRef((e,t)=>{const{forceMount:n,...o}=e,r=dr(fr,e.__scopeCollapsible);return p.jsx(ee,{present:n||r.open,children:({present:s})=>p.jsx(Bm,{...o,ref:t,present:s})})});ec.displayName=fr;var Bm=a.forwardRef((e,t)=>{const{__scopeCollapsible:n,present:o,children:r,...s}=e,i=dr(fr,n),[c,l]=a.useState(o),u=a.useRef(null),f=F(t,u),d=a.useRef(0),v=d.current,h=a.useRef(0),g=h.current,m=i.open||c,b=a.useRef(m),x=a.useRef(void 0);return a.useEffect(()=>{const w=requestAnimationFrame(()=>b.current=!1);return()=>cancelAnimationFrame(w)},[]),Q(()=>{const w=u.current;if(w){x.current=x.current||{transitionDuration:w.style.transitionDuration,animationName:w.style.animationName},w.style.transitionDuration="0s",w.style.animationName="none";const y=w.getBoundingClientRect();d.current=y.height,h.current=y.width,b.current||(w.style.transitionDuration=x.current.transitionDuration,w.style.animationName=x.current.animationName),l(o)}},[i.open,o]),p.jsx(I.div,{"data-state":pr(i.open),"data-disabled":i.disabled?"":void 0,id:i.contentId,hidden:!m,...s,ref:f,style:{"--radix-collapsible-content-height":v?`${v}px`:void 0,"--radix-collapsible-content-width":g?`${g}px`:void 0,...e.style},children:m&&r})});function pr(e){return e?"open":"closed"}var Wm=Zi,Hm=Ji,Um=ec,Ae="Accordion",Km=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[vr,Gm,zm]=mt(Ae),[Nn]=Z(Ae,[zm,qi]),mr=qi(),tc=Y.forwardRef((e,t)=>
45{const{type:n,...o}=e,r=o,s=o;return p.jsx(vr.Provider,{scope:e.__scopeAccordion,children:n==="multiple"?p.jsx(Zm,{...s,ref:t}):p.jsx(qm,{...r,ref:t})})});tc.displayName=Ae;var[nc,Ym]=Nn(Ae),[oc,Xm]=Nn(Ae,{collapsible:!1}),qm=Y.forwardRef((e,t)=>{const{value:n,defaultValue:o,onValueChange:r=()=>{},collapsible:s=!1,...i}=e,[c,l]=se({prop:n,defaultProp:o,onChange:r});return p.jsx(nc,{scope:e.__scopeAccordion,value:c?[c]:[],onItemOpen:l,onItemClose:Y.useCallback(()=>s&&l(""),[s,l]),children:p.jsx(oc,{scope:e.__scopeAccordion,collapsible:s,children:p.jsx(rc,{...i,ref:t})})})}),Zm=Y.forwardRef((e,t)=>{const{value:n,defaultValue:o,onValueChange:r=()=>{},...s}=e,[i=[],c]=se({prop:n,defaultProp:o,onChange:r}),l=Y.useCallback(f=>c((d=[])=>[...d,f]),[c]),u=Y.useCallback(f=>c((d=[])=>d.filter(v=>v!==f)),[c]);return p.jsx(nc,{scope:e.__scopeAccordion,value:i,onItemOpen:l,onItemClose:u,children:p.jsx(oc,{scope:e.__scopeAccordion,collapsible:!0,children:p.jsx(rc,{...s,ref:t})})})}),[Qm,Mn]=Nn(Ae),rc=Y.forwardRef((e,t)=>{const{__scopeAccordion:n,disabled:o,dir:r,orientation:s="vertical",...i}=e,c=Y.useRef(null),l=F(c,t),u=Gm(n),d=Ve(r)==="ltr",v=P(e.onKeyDown,h=>{var A;if(!Km.includes(h.key))return;const g=h.target,m=u().filter($=>{var N;return!((N=$.ref.current)!=null&&N.disabled)}),b=m.findIndex($=>$.ref.current===g),x=m.length;if(b===-1)return;h.preventDefault();let w=b;const y=0,C=x-1,E=()=>{w=b+1,w>C&&(w=y)},R=()=>{w=b-1,w<y&&(w=C)};switch(h.key){case"Home":w=y;break;case"End":w=C;break;case"ArrowRight":s==="horizontal"&&(d?E():R());break;case"ArrowDown":s==="vertical"&&E();break;case"ArrowLeft":s==="horizontal"&&(d?R():E());break;case"ArrowUp":s==="vertical"&&R();break}const S=w%x;(A=m[S].ref.current)==null||A.focus()});return p.jsx(Qm,{scope:n,disabled:o,direction:r,orientation:s,children:p.jsx(vr.Slot,{scope:n,children:p.jsx(I.div,{...i,"data-orientation":s,ref:l,onKeyDown:o?void 0:v})})})}),cn="AccordionItem",[Jm,hr]=Nn(cn),sc=Y.forwardRef((e,t)=>{const{__scopeAccordion:n,value:o,...r}=e,s=Mn(cn,n),i=Ym(cn,n),c=mr(n),l=ce(),u=o&&i.value.includes(o)||!1,f=s.disabled||e.disabled;return p.jsx(Jm,{scope:n,open:u,disabled:f,triggerId:l,children:p.jsx(Wm,{"data-orientation":s.orientation,"data-state":dc(u),...c,...r,ref:t,disabled:f,open:u,onOpenChange:d=>{d?i.onItemOpen(o):i.onItemClose(o)}})})});sc.displayName=cn;var ac="AccordionHeader",ic=Y.forwardRef((e,t)=>{const{__scopeAccordion:n,...o}=e,r=Mn(Ae,n),s=hr(ac,n);return p.jsx(I.h3,{"data-orientation":r.orientation,"data-state":dc(s.open),"data-disabled":s.disabled?"":void 0,...o,ref:t})});ic.displayName=ac;var go="AccordionTrigger",cc=Y.forwardRef((e,t)=>{const{__scopeAccordion:n,...o}=e,r=Mn(Ae,n),s=hr(go,n),i=Xm(go,n),c=mr(n);return p.jsx(vr.ItemSlot,{scope:n,children:p.jsx(Hm,{"aria-disabled":s.open&&!i.collapsible||void 0,"data-orientation":r.orientation,id:s.triggerId,...c,...o,ref:t})})});cc.displayName=go;var lc="AccordionContent",uc=Y.forwardRef((e,t)=>{const{__scopeAccordion:n,...o}=e,r=Mn(Ae,n),s=hr(lc,n),i=mr(n);return p.jsx(Um,{role:"region","aria-labelledby":s.triggerId,"data-orientation":r.orientation,...i,...o,ref:t,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...e.style}})});uc.displayName=lc;function dc(e){return e?"open":"closed"}var yw=tc,Cw=sc,Ew=ic,Sw=cc,Pw=uc;function _t(e,[t,n]){return Math.min(n,Math.max(t,e))}function eh(e,t){return a.useReducer((n,o)=>t[n][o]??n,e)}var gr="ScrollArea",[fc]=Z(gr),[th,pe]=fc(gr),pc=a.forwardRef((e,t)=>{const{__scopeScrollArea:n,type:o="hover",dir:r,scrollHideDelay:s=600,...i}=e,[c,l]=a.useState(null),[u,f]=a.useState(null),[d,v]=a.useState(null),[h,g]=a.useState(null),[m,b]=a.useState(null),[x,w]=a.useState(0),[y,C]=a.useState(0),[E,R]=a.useState(!1),[S,A]=a.useState(!1),$=F(t,O=>l(O)),N=Ve(r);return p.jsx(th,{scope:n,type:o,dir:N,scrollHideDelay:s,scrollArea:c,viewport:u,onViewportChange:f,content:d,onContentChange:v,scrollbarX:h,onScrollbarXChange:g,scrollbarXEnabled:E,onScrollbarXEnabledChange:R,scrollbarY:m,onScrollbarYChange:b,scrollbarYEnabled:S,onScrollbarYEnabledChange:A,onCornerWidthChange:w,onCornerHeight
45Change:C,children:p.jsx(I.div,{dir:N,...i,ref:$,style:{position:"relative","--radix-scroll-area-corner-width":x+"px","--radix-scroll-area-corner-height":y+"px",...e.style}})})});pc.displayName=gr;var vc="ScrollAreaViewport",mc=a.forwardRef((e,t)=>{const{__scopeScrollArea:n,children:o,nonce:r,...s}=e,i=pe(vc,n),c=a.useRef(null),l=F(t,c,i.onViewportChange);return p.jsxs(p.Fragment,{children:[p.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"},nonce:r}),p.jsx(I.div,{"data-radix-scroll-area-viewport":"",...s,ref:l,style:{overflowX:i.scrollbarXEnabled?"scroll":"hidden",overflowY:i.scrollbarYEnabled?"scroll":"hidden",...e.style},children:p.jsx("div",{ref:i.onContentChange,style:{minWidth:"100%",display:"table"},children:o})})]})});mc.displayName=vc;var Ee="ScrollAreaScrollbar",nh=a.forwardRef((e,t)=>{const{forceMount:n,...o}=e,r=pe(Ee,e.__scopeScrollArea),{onScrollbarXEnabledChange:s,onScrollbarYEnabledChange:i}=r,c=e.orientation==="horizontal";return a.useEffect(()=>(c?s(!0):i(!0),()=>{c?s(!1):i(!1)}),[c,s,i]),r.type==="hover"?p.jsx(oh,{...o,ref:t,forceMount:n}):r.type==="scroll"?p.jsx(rh,{...o,ref:t,forceMount:n}):r.type==="auto"?p.jsx(hc,{...o,ref:t,forceMount:n}):r.type==="always"?p.jsx(br,{...o,ref:t}):null});nh.displayName=Ee;var oh=a.forwardRef((e,t)=>{const{forceMount:n,...o}=e,r=pe(Ee,e.__scopeScrollArea),[s,i]=a.useState(!1);return a.useEffect(()=>{const c=r.scrollArea;let l=0;if(c){const u=()=>{window.clearTimeout(l),i(!0)},f=()=>{l=window.setTimeout(()=>i(!1),r.scrollHideDelay)};return c.addEventListener("pointerenter",u),c.addEventListener("pointerleave",f),()=>{window.clearTimeout(l),c.removeEventListener("pointerenter",u),c.removeEventListener("pointerleave",f)}}},[r.scrollArea,r.scrollHideDelay]),p.jsx(ee,{present:n||s,children:p.jsx(hc,{"data-state":s?"visible":"hidden",...o,ref:t})})}),rh=a.forwardRef((e,t)=>{const{forceMount:n,...o}=e,r=pe(Ee,e.__scopeScrollArea),s=e.orientation==="horizontal",i=Dn(()=>l("SCROLL_END"),100),[c,l]=eh("hidden",{hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}});return a.useEffect(()=>{if(c==="idle"){const u=window.setTimeout(()=>l("HIDE"),r.scrollHideDelay);return()=>window.clearTimeout(u)}},[c,r.scrollHideDelay,l]),a.useEffect(()=>{const u=r.viewport,f=s?"scrollLeft":"scrollTop";if(u){let d=u[f];const v=()=>{const h=u[f];d!==h&&(l("SCROLL"),i()),d=h};return u.addEventListener("scroll",v),()=>u.removeEventListener("scroll",v)}},[r.viewport,s,l,i]),p.jsx(ee,{present:n||c!=="hidden",children:p.jsx(br,{"data-state":c==="hidden"?"hidden":"visible",...o,ref:t,onPointerEnter:P(e.onPointerEnter,()=>l("POINTER_ENTER")),onPointerLeave:P(e.onPointerLeave,()=>l("POINTER_LEAVE"))})})}),hc=a.forwardRef((e,t)=>{const n=pe(Ee,e.__scopeScrollArea),{forceMount:o,...r}=e,[s,i]=a.useState(!1),c=e.orientation==="horizontal",l=Dn(()=>{if(n.viewport){const u=n.viewport.offsetWidth<n.viewport.scrollWidth,f=n.viewport.offsetHeight<n.viewport.scrollHeight;i(c?u:f)}},10);return ft(n.viewport,l),ft(n.content,l),p.jsx(ee,{present:o||s,children:p.jsx(br,{"data-state":s?"visible":"hidden",...r,ref:t})})}),br=a.forwardRef((e,t)=>{const{orientation:n="vertical",...o}=e,r=pe(Ee,e.__scopeScrollArea),s=a.useRef(null),i=a.useRef(0),[c,l]=a.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),u=wc(c.viewport,c.content),f={...o,sizes:c,onSizesChange:l,hasThumb:u>0&&u<1,onThumbChange:v=>s.current=v,onThumbPointerUp:()=>i.current=0,onThumbPointerDown:v=>i.current=v};function d(v,h){return dh(v,i.current,c,h)}return n==="horizontal"?p.jsx(sh,{...f,ref:t,onThumbPositionChange:()=>{if(r.viewport&&s.current){const v=r.viewport.scrollLeft,h=us(v,c,r.dir);s.current.style.transform=`translate3d(${h}px, 0, 0)`}},onWheelScroll:v=>{r.viewport&&(r.viewport.scrollLeft=v)},onDragScroll:v=>{r.viewport&&(r.viewport.scrollLeft=d(v,r.dir))}}):n==="vertical"?p.jsx(ah,{...f,ref:t,onThumbPositionChange:()=>{if(r.viewport&&s.current){const v=r.viewport.scrollTop,h=us(v,c);s.current.style.transform=`translate3d(0, ${h}px, 0)`}}
vendor: 4,462 bytes, line 45
45,onWheelScroll:v=>{r.viewport&&(r.viewport.scrollTop=v)},onDragScroll:v=>{r.viewport&&(r.viewport.scrollTop=d(v))}}):null}),sh=a.forwardRef((e,t)=>{const{sizes:n,onSizesChange:o,...r}=e,s=pe(Ee,e.__scopeScrollArea),[i,c]=a.useState(),l=a.useRef(null),u=F(t,l,s.onScrollbarXChange);return a.useEffect(()=>{l.current&&c(getComputedStyle(l.current))},[l]),p.jsx(bc,{"data-orientation":"horizontal",...r,ref:u,sizes:n,style:{bottom:0,left:s.dir==="rtl"?"var(--radix-scroll-area-corner-width)":0,right:s.dir==="ltr"?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":On(n)+"px",...e.style},onThumbPointerDown:f=>e.onThumbPointerDown(f.x),onDragScroll:f=>e.onDragScroll(f.x),onWheelScroll:(f,d)=>{if(s.viewport){const v=s.viewport.scrollLeft+f.deltaX;e.onWheelScroll(v),Cc(v,d)&&f.preventDefault()}},onResize:()=>{l.current&&s.viewport&&i&&o({content:s.viewport.scrollWidth,viewport:s.viewport.offsetWidth,scrollbar:{size:l.current.clientWidth,paddingStart:un(i.paddingLeft),paddingEnd:un(i.paddingRight)}})}})}),ah=a.forwardRef((e,t)=>{const{sizes:n,onSizesChange:o,...r}=e,s=pe(Ee,e.__scopeScrollArea),[i,c]=a.useState(),l=a.useRef(null),u=F(t,l,s.onScrollbarYChange);return a.useEffect(()=>{l.current&&c(getComputedStyle(l.current))},[l]),p.jsx(bc,{"data-orientation":"vertical",...r,ref:u,sizes:n,style:{top:0,right:s.dir==="ltr"?0:void 0,left:s.dir==="rtl"?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":On(n)+"px",...e.style},onThumbPointerDown:f=>e.onThumbPointerDown(f.y),onDragScroll:f=>e.onDragScroll(f.y),onWheelScroll:(f,d)=>{if(s.viewport){const v=s.viewport.scrollTop+f.deltaY;e.onWheelScroll(v),Cc(v,d)&&f.preventDefault()}},onResize:()=>{l.current&&s.viewport&&i&&o({content:s.viewport.scrollHeight,viewport:s.viewport.offsetHeight,scrollbar:{size:l.current.clientHeight,paddingStart:un(i.paddingTop),paddingEnd:un(i.paddingBottom)}})}})}),[ih,gc]=fc(Ee),bc=a.forwardRef((e,t)=>{const{__scopeScrollArea:n,sizes:o,hasThumb:r,onThumbChange:s,onThumbPointerUp:i,onThumbPointerDown:c,onThumbPositionChange:l,onDragScroll:u,onWheelScroll:f,onResize:d,...v}=e,h=pe(Ee,n),[g,m]=a.useState(null),b=F(t,$=>m($)),x=a.useRef(null),w=a.useRef(""),y=h.viewport,C=o.content-o.viewport,E=q(f),R=q(l),S=Dn(d,10);function A($){if(x.current){const N=$.clientX-x.current.left,O=$.clientY-x.current.top;u({x:N,y:O})}}return a.useEffect(()=>{const $=N=>{const O=N.target;(g==null?void 0:g.contains(O))&&E(N,C)};return document.addEventListener("wheel",$,{passive:!1}),()=>document.removeEventListener("wheel",$,{passive:!1})},[y,g,C,E]),a.useEffect(R,[o,R]),ft(g,S),ft(h.content,S),p.jsx(ih,{scope:n,scrollbar:g,hasThumb:r,onThumbChange:q(s),onThumbPointerUp:q(i),onThumbPositionChange:R,onThumbPointerDown:q(c),children:p.jsx(I.div,{...v,ref:b,style:{position:"absolute",...v.style},onPointerDown:P(e.onPointerDown,$=>{$.button===0&&($.target.setPointerCapture($.pointerId),x.current=g.getBoundingClientRect(),w.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",h.viewport&&(h.viewport.style.scrollBehavior="auto"),A($))}),onPointerMove:P(e.onPointerMove,A),onPointerUp:P(e.onPointerUp,$=>{const N=$.target;N.hasPointerCapture($.pointerId)&&N.releasePointerCapture($.pointerId),document.body.style.webkitUserSelect=w.current,h.viewport&&(h.viewport.style.scrollBehavior=""),x.current=null})})})}),ln="ScrollAreaThumb",ch=a.forwardRef((e,t)=>{const{forceMount:n,...o}=e,r=gc(ln,e.__scopeScrollArea);return p.jsx(ee,{present:n||r.hasThumb,children:p.jsx(lh,{ref:t,...o})})}),lh=a.forwardRef((e,t)=>{const{__scopeScrollArea:n,style:o,...r}=e,s=pe(ln,n),i=gc(ln,n),{onThumbPositionChange:c}=i,l=F(t,d=>i.onThumbChange(d)),u=a.useRef(void 0),f=Dn(()=>{u.current&&(u.current(),u.current=void 0)},100);return a.useEffect(()=>{const d=s.viewport;if(d){const v=()=>{if(f(),!u.current){const h=fh(d,c);u.current=h,c()}};return c(),d.addEventListener("scroll",v),()=>d.removeEventListener("scroll",v)}},[s.viewport,f,c]),p.jsx(I.div,{"data-state":i.hasThumb?"visible":"hidden",...r,ref:l,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...o},onPointerDownCapture:P(e.onPointerDownCapture,d=>{const h=d.target.getBoundingClientRect(),g=d.clientX-h.left,m=d.clientY-h.top;i.onThumbPointerDown({x:g,y:m})}),onPointerUp:P(e.onPointerUp,i.onThumbPointerUp)})});ch.displayName=ln;var xr="ScrollAreaCorner",xc=a.forwardRef((e,t)=>
45{const n=pe(xr,e.__scopeScrollArea),o=!!(n.scrollbarX&&n.scrollbarY);return n.type!=="scroll"&&o?p.jsx(uh,{...e,ref:t}):null});xc.displayName=xr;var uh=a.forwardRef((e,t)=>{const{__scopeScrollArea:n,...o}=e,r=pe(xr,n),[s,i]=a.useState(0),[c,l]=a.useState(0),u=!!(s&&c);return ft(r.scrollbarX,()=>{var d;const f=((d=r.scrollbarX)==null?void 0:d.offsetHeight)||0;r.onCornerHeightChange(f),l(f)}),ft(r.scrollbarY,()=>{var d;const f=((d=r.scrollbarY)==null?void 0:d.offsetWidth)||0;r.onCornerWidthChange(f),i(f)}),u?p.jsx(I.div,{...o,ref:t,style:{width:s,height:c,position:"absolute",right:r.dir==="ltr"?0:void 0,left:r.dir==="rtl"?0:void 0,bottom:0,...e.style}}):null});function un(e){return e?parseInt(e,10):0}function wc(e,t){const n=e/t;return isNaN(n)?0:n}function On(e){const t=wc(e.viewport,e.content),n=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,o=(e.scrollbar.size-n)*t;return Math.max(o,18)}function dh(e,t,n,o="ltr"){const r=On(n),s=r/2,i=t||s,c=r-i,l=n.scrollbar.paddingStart+i,u=n.scrollbar.size-n.scrollbar.paddingEnd-c,f=n.content-n.viewport,d=o==="ltr"?[0,f]:[f*-1,0];return yc([l,u],d)(e)}function us(e,t,n="ltr"){const o=On(t),r=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,s=t.scrollbar.size-r,i=t.content-t.viewport,c=s-o,l=n==="ltr"?[0,i]:[i*-1,0],u=_t(e,l);return yc([0,i],[0,c])(u)}function yc(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const o=(t[1]-t[0])/(e[1]-e[0]);return t[0]+o*(n-e[0])}}function Cc(e,t){return e>0&&e<t}var fh=(e,t=()=>{})=>{let n={left:e.scrollLeft,top:e.scrollTop},o=0;return function r(){const s={left:e.scrollLeft,top:e.scrollTop},i=n.left!==s.left,c=n.top!==s.top;(i||c)&&t(),n=s,o=window.requestAnimationFrame(r)}(),()=>window.cancelAnimationFrame(o)};function Dn(e,t){const n=q(e),o=a.useRef(0);return a.useEffect(()=>()=>window.clearTimeout(o.current),[]),a.useCallback(()=>{window.clearTimeout(o.current),o.current=window.setTimeout(n,t)},[n,t])}function ft(e,t){const n=q(t);Q(()=>{let o=0;if(e){const r=new ResizeObserver(()=>{cancelAnimationFrame(o),o=window.requestAnimationFrame(n)});return r.observe(e),()=>{window.cancelAnimationFrame(o),r.unobserve(e)}}},[e,n])}var Rw=pc,Aw=mc,Tw=xc,wr="Checkbox",[ph]=Z(wr),[vh,mh]=ph(wr),Ec=a.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:o,checked:r,defaultChecked:s,required:i,disabled:c,value:l="on",onCheckedChange:u,form:f,...d}=e,[v,h]=a.useState(null),g=F(t,C=>h(C)),m=a.useRef(!1),b=v?f||!!v.closest("form"):!0,[x=!1,w]=se({prop:r,defaultProp:s,onChange:u}),y=a.useRef(x);return a.useEffect(()=>{const C=v==null?void 0:v.form;if(C){const E=()=>w(y.current);return C.addEventListener("reset",E),()=>C.removeEventListener("reset",E)}},[v,w]),p.jsxs(vh,{scope:n,state:x,disabled:c,children:[p.jsx(I.button,{type:"button",role:"checkbox","aria-checked":Ne(x)?"mixed":x,"aria-required":i,"data-state":Rc(x),"data-disabled":c?"":void 0,disabled:c,value:l,...d,ref:g,onKeyDown:P(e.onKeyDown,C=>{C.key==="Enter"&&C.preventDefault()}),onClick:P(e.onClick,C=>{w(E=>Ne(E)?!0:!E),b&&(m.current=C.isPropagationStopped(),m.current||C.stopPropagation())})}),b&&p.jsx(hh,{control:v,bubbles:!m.current,name:o,value:l,checked:x,required:i,disabled:c,form:f,style:{transform:"translateX(-100%)"},defaultChecked:Ne(s)?!1:s})]})});Ec.displayName=wr;var Sc="CheckboxIndicator",Pc=a.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:o,...r}=e,s=mh(Sc,n);return p.jsx(ee,{present:o||Ne(s.state)||s.state===!0,children:p.jsx(I.span,{"data-state":Rc(s.state),"data-disabled":s.disabled?"":void 0,...r,ref:t,style:{pointerEvents:"none",...e.style}})})});Pc.displayName=Sc;var hh=e=>{const{control:t,checked:n,bubbles:o=!0,defaultChecked:r,...s}=e,i=a.useRef(null),c=Ot(n),l=Nt(t);a.useEffect(()=>{const f=i.current,d=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(d,"checked").set;if(c!==n&&h){const g=new Event("click",{bubbles:o});f.indeterminate=Ne(n),h.call(f,Ne(n)?!1:n),f.dispatchEvent(g)}},[c,n,o]);const u=a.useRef(Ne(n)?!1:n);return p.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:r??u.current,...s,tabIndex:-1,ref:i,style:{...e.style,...l,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function Ne(e){return e==="indeterminate"}function Rc(e){return Ne(e)?"indeterminate":e?"checked":"unchecked"}var _w=Ec,$w=Pc;function ne(){return ne=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)({}).hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e},ne.apply(null,arguments)}var gh="Label",Ac=a.forwardRef((e,t)=>
45p.jsx(I.label,{...e,ref:t,onMouseDown:n=>{var r;n.target.closest("button, input, select, textarea")||((r=e.onMouseDown)==null||r.call(e,n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));Ac.displayName=gh;var Iw=Ac,yr="Popover",[Tc]=Z(yr,[Fe]),Ft=Fe(),[bh,Be]=Tc(yr),_c=e=>{const{__scopePopover:t,children:n,open:o,defaultOpen:r,onOpenChange:s,modal:i=!1}=e,c=Ft(t),l=a.useRef(null),[u,f]=a.useState(!1),[d=!1,v]=se({prop:o,defaultProp:r,onChange:s});return p.jsx(wn,{...c,children:p.jsx(bh,{scope:t,contentId:ce(),triggerRef:l,open:d,onOpenChange:v,onOpenToggle:a.useCallback(()=>v(h=>!h),[v]),hasCustomAnchor:u,onCustomAnchorAdd:a.useCallback(()=>f(!0),[]),onCustomAnchorRemove:a.useCallback(()=>f(!1),[]),modal:i,children:n})})};_c.displayName=yr;var $c="PopoverAnchor",xh=a.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=Be($c,n),s=Ft(n),{onCustomAnchorAdd:i,onCustomAnchorRemove:c}=r;return a.useEffect(()=>(i(),()=>c()),[i,c]),p.jsx(Mt,{...s,...o,ref:t})});xh.displayName=$c;var Ic="PopoverTrigger",Nc=a.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=Be(Ic,n),s=Ft(n),i=F(t,r.triggerRef),c=p.jsx(I.button,{type:"button","aria-haspopup":"dialog","aria-expanded":r.open,"aria-controls":r.contentId,"data-state":kc(r.open),...o,ref:i,onClick:P(e.onClick,r.onOpenToggle)});return r.hasCustomAnchor?c:p.jsx(Mt,{asChild:!0,...s,children:c})});Nc.displayName=Ic;var Cr="PopoverPortal",[wh,yh]=Tc(Cr,{forceMount:void 0}),Mc=e=>{const{__scopePopover:t,forceMount:n,children:o,container:r}=e,s=Be(Cr,t);return p.jsx(wh,{scope:t,forceMount:n,children:p.jsx(ee,{present:n||s.open,children:p.jsx(ht,{asChild:!0,container:r,children:o})})})};Mc.displayName=Cr;var pt="PopoverContent",Oc=a.forwardRef((e,t)=>{const n=yh(pt,e.__scopePopover),{forceMount:o=n.forceMount,...r}=e,s=Be(pt,e.__scopePopover);return p.jsx(ee,{present:o||s.open,children:s.modal?p.jsx(Eh,{...r,ref:t}):p.jsx(Sh,{...r,ref:t})})});Oc.displayName=pt;var Ch=Oe("PopoverContent.RemoveScroll"),Eh=a.forwardRef((e,t)=>{const n=Be(pt,e.__scopePopover),o=a.useRef(null),r=F(t,o),s=a.useRef(!1);return a.useEffect(()=>{const i=o.current;if(i)return Lt(i)},[]),p.jsx(xt,{as:Ch,allowPinchZoom:!0,children:p.jsx(Dc,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:P(e.onCloseAutoFocus,i=>{var c;i.preventDefault(),s.current||(c=n.triggerRef.current)==null||c.focus()}),onPointerDownOutside:P(e.onPointerDownOutside,i=>{const c=i.detail.originalEvent,l=c.button===0&&c.ctrlKey===!0,u=c.button===2||l;s.current=u},{checkForDefaultPrevented:!1}),onFocusOutside:P(e.onFocusOutside,i=>i.preventDefault(),{checkForDefaultPrevented:!1})})})}),Sh=a.forwardRef((e,t)=>{const n=Be(pt,e.__scopePopover),o=a.useRef(!1),r=a.useRef(!1);return p.jsx(Dc,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var i,c;(i=e.onCloseAutoFocus)==null||i.call(e,s),s.defaultPrevented||(o.current||(c=n.triggerRef.current)==null||c.focus(),s.preventDefault()),o.current=!1,r.current=!1},onInteractOutside:s=>{var l,u;(l=e.onInteractOutside)==null||l.call(e,s),s.defaultPrevented||(o.current=!0,s.detail.originalEvent.type==="pointerdown"&&(r.current=!0));const i=s.target;((u=n.triggerRef.current)==null?void 0:u.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&r.current&&s.preventDefault()}})}),Dc=a.forwardRef((e,t)=>{const{__scopePopover:n,trapFocus:o,onOpenAutoFocus:r,onCloseAutoFocus:s,disableOutsidePointerEvents:i,onEscapeKeyDown:c,onPointerDownOutside:l,onFocusOutside:u,onInteractOutside:f,...d}=e,v=Be(pt,n),h=Ft(n);return An(),p.jsx(Dt,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:r,onUnmountAutoFocus:s,children:p.jsx(et,{asChild:!0,disableOutsidePointerEvents:i,onInteractOutside:f,onEscapeKeyDown:c,onPointerDownOutside:l,onFocusOutside:u,onDismiss:()=>v.onOpenChange(!1),children:p.jsx(yn,{"data-state":kc(v.open),role:"dialog",id:v.contentId,...h,...d,ref:t,style:{...d.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)"}})})})}),Lc="PopoverClose",Ph=a.forwardRef((e,t)=>
45{const{__scopePopover:n,...o}=e,r=Be(Lc,n);return p.jsx(I.button,{type:"button",...o,ref:t,onClick:P(e.onClick,()=>r.onOpenChange(!1))})});Ph.displayName=Lc;var Rh="PopoverArrow",Ah=a.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=Ft(n);return p.jsx(Cn,{...r,...o,ref:t})});Ah.displayName=Rh;function kc(e){return e?"open":"closed"}var Nw=_c,Mw=Nc,Ow=Mc,Dw=Oc,Er="Progress",Sr=100,[Th]=Z(Er),[_h,$h]=Th(Er),jc=a.forwardRef((e,t)=>{const{__scopeProgress:n,value:o=null,max:r,getValueLabel:s=Ih,...i}=e;(r||r===0)&&!ds(r)&&console.error(Nh(`${r}`,"Progress"));const c=ds(r)?r:Sr;o!==null&&!fs(o,c)&&console.error(Mh(`${o}`,"Progress"));const l=fs(o,c)?o:null,u=dn(l)?s(l,c):void 0;return p.jsx(_h,{scope:n,value:l,max:c,children:p.jsx(I.div,{"aria-valuemax":c,"aria-valuemin":0,"aria-valuenow":dn(l)?l:void 0,"aria-valuetext":u,role:"progressbar","data-state":Bc(l,c),"data-value":l??void 0,"data-max":c,...i,ref:t})})});jc.displayName=Er;var Fc="ProgressIndicator",Vc=a.forwardRef((e,t)=>{const{__scopeProgress:n,...o}=e,r=$h(Fc,n);return p.jsx(I.div,{"data-state":Bc(r.value,r.max),"data-value":r.value??void 0,"data-max":r.max,...o,ref:t})});Vc.displayName=Fc;function Ih(e,t){return`${Math.round(e/t*100)}%`}function Bc(e,t){return e==null?"indeterminate":e===t?"complete":"loading"}function dn(e){return typeof e=="number"}function ds(e){return dn(e)&&!isNaN(e)&&e>0}function fs(e,t){return dn(e)&&!isNaN(e)&&e<=t&&e>=0}function Nh(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${Sr}\`.`}function Mh(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be: 46 - a positive number 47 - less than the value passed to \`max\` (or ${Sr} if no \`max\` prop is set) 48 - \`null\` or \`undefined\` if the progress is indeterminate. 49 50Defaulting to \`null\`.`}var Lw=jc,kw=Vc,Pr="Radio",[Oh,Wc]=Z(Pr),[Dh,Lh]=Oh(Pr),Hc=a.forwardRef((e,t)=>{const{__scopeRadio:n,name:o,checked:r=!1,required:s,disabled:i,value:c="on",onCheck:l,form:u,...f}=e,[d,v]=a.useState(null),h=F(t,b=>v(b)),g=a.useRef(!1),m=d?u||!!d.closest("form"):!0;return p.jsxs(Dh,{scope:n,checked:r,disabled:i,children:[p.jsx(I.button,{type:"button",role:"radio","aria-checked":r,"data-state":Gc(r),"data-disabled":i?"":void 0,disabled:i,value:c,...f,ref:h,onClick:P(e.onClick,b=>{r||l==null||l(),m&&(g.current=b.isPropagationStopped(),g.current||b.stopPropagation())})}),m&&p.jsx(kh,{control:d,bubbles:!g.current,name:o,value:c,checked:r,required:s,disabled:i,form:u,style:{transform:"translateX(-100%)"}})]})});Hc.displayName=Pr;var Uc="RadioIndicator",Kc=a.forwardRef((e,t)=>{const{__scopeRadio:n,forceMount:o,...r}=e,s=Lh(Uc,n);return p.jsx(ee,{present:o||s.checked,children:p.jsx(I.span,{"data-state":Gc(s.checked),"data-disabled":s.disabled?"":void 0,...r,ref:t})})});Kc.displayName=Uc;var kh=e=>{const{control:t,checked:n,bubbles:o=!0,...r}=e,s=a.useRef(null),i=Ot(n),c=Nt(t);return a.useEffect(()=>{const l=s.current,u=window.HTMLInputElement.prototype,d=Object.getOwnPropertyDescriptor(u,"checked").set;if(i!==n&&d){const v=new Event("click",{bubbles:o});d.call(l,n),l.dispatchEvent(v)}},[i,n,o]),p.jsx("input",{type:"radio","aria-hidden":!0,defaultChecked:n,...r,tabIndex:-1,ref:s,style:{...e.style,...c,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})};function Gc(e){return e?"checked":"unchecked"}var jh=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],Rr="RadioGroup",[Fh]=Z(Rr,[wt,Wc]),zc=wt(),Yc=Wc(),[Vh,Bh]=Fh(Rr),Xc=a.forwardRef((e,t)=>{const{__scopeRadioGroup:n,name:o,defaultValue:r,value:s,required:i=!1,disabled:c=!1,orientation:l,dir:u,loop:f=!0,onValueChange:d,...v}=e,h=zc(n),g=Ve(u),[m,b]=se({prop:s,defaultProp:r,onChange:d});return p.jsx(Vh,{scope:n,name:o,required:i,disabled:c,value:m,onValueChange:b,children:p.jsx(er,{asChild:!0,...h,orientation:l,dir:g,loop:f,children:p.jsx(I.div,{role:"radiogroup","aria-required":i,"aria-orientation":l,"data-disabled":c?"":void 0,dir:g,...v,ref:t})})})});Xc.displayName=Rr;var qc="RadioGroupItem",Zc=a.forwardRef((e,t)=>
50{const{__scopeRadioGroup:n,disabled:o,...r}=e,s=Bh(qc,n),i=s.disabled||o,c=zc(n),l=Yc(n),u=a.useRef(null),f=F(t,u),d=s.value===r.value,v=a.useRef(!1);return a.useEffect(()=>{const h=m=>{jh.includes(m.key)&&(v.current=!0)},g=()=>v.current=!1;return document.addEventListener("keydown",h),document.addEventListener("keyup",g),()=>{document.removeEventListener("keydown",h),document.removeEventListener("keyup",g)}},[]),p.jsx(tr,{asChild:!0,...c,focusable:!i,active:d,children:p.jsx(Hc,{disabled:i,required:s.required,checked:d,...l,...r,name:s.name,ref:f,onCheck:()=>s.onValueChange(r.value),onKeyDown:P(h=>{h.key==="Enter"&&h.preventDefault()}),onFocus:P(r.onFocus,()=>{var h;v.current&&((h=u.current)==null||h.click())})})})});Zc.displayName=qc;var Wh="RadioGroupIndicator",Qc=a.forwardRef((e,t)=>{const{__scopeRadioGroup:n,...o}=e,r=Yc(n);return p.jsx(Kc,{...r,...o,ref:t})});Qc.displayName=Wh;var jw=Xc,Fw=Zc,Vw=Qc,Jc="AlertDialog",[Hh]=Z(Jc,[ja]),Te=ja(),el=e=>{const{__scopeAlertDialog:t,...n}=e,o=Te(t);return p.jsx(uv,{...o,...n,modal:!0})};el.displayName=Jc;var Uh="AlertDialogTrigger",tl=a.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=Te(n);return p.jsx(dv,{...r,...o,ref:t})});tl.displayName=Uh;var Kh="AlertDialogPortal",nl=e=>{const{__scopeAlertDialog:t,...n}=e,o=Te(t);return p.jsx(fv,{...o,...n})};nl.displayName=Kh;var Gh="AlertDialogOverlay",ol=a.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=Te(n);return p.jsx(pv,{...r,...o,ref:t})});ol.displayName=Gh;var ct="AlertDialogContent",[zh,Yh]=Hh(ct),Xh=Ps("AlertDialogContent"),rl=a.forwardRef((e,t)=>{const{__scopeAlertDialog:n,children:o,...r}=e,s=Te(n),i=a.useRef(null),c=F(t,i),l=a.useRef(null);return p.jsx(av,{contentName:ct,titleName:sl,docsSlug:"alert-dialog",children:p.jsx(zh,{scope:n,cancelRef:l,children:p.jsxs(vv,{role:"alertdialog",...s,...r,ref:c,onOpenAutoFocus:P(r.onOpenAutoFocus,u=>{var f;u.preventDefault(),(f=l.current)==null||f.focus({preventScroll:!0})}),onPointerDownOutside:u=>u.preventDefault(),onInteractOutside:u=>u.preventDefault(),children:[p.jsx(Xh,{children:o}),p.jsx(Zh,{contentRef:i})]})})})});rl.displayName=ct;var sl="AlertDialogTitle",al=a.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=Te(n);return p.jsx(mv,{...r,...o,ref:t})});al.displayName=sl;var il="AlertDialogDescription",cl=a.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=Te(n);return p.jsx(hv,{...r,...o,ref:t})});cl.displayName=il;var qh="AlertDialogAction",ll=a.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,r=Te(n);return p.jsx(ei,{...r,...o,ref:t})});ll.displayName=qh;var ul="AlertDialogCancel",dl=a.forwardRef((e,t)=>{const{__scopeAlertDialog:n,...o}=e,{cancelRef:r}=Yh(ul,n),s=Te(n),i=F(t,r);return p.jsx(ei,{...s,...o,ref:i})});dl.displayName=ul;var Zh=({contentRef:e})=>{const t=`\`${ct}\` requires a description for the component to be accessible for screen reader users. 51 52You can add a description to the \`${ct}\` by passing a \`${il}\` component as a child, which also benefits sighted users by adding visible context to the dialog. 53 54Alternatively, you can use your own component as a description by assigning it an \`id\` and passing the same value to the \`aria-describedby\` prop in \`${ct}\`. If the description is confusing or duplicative for sighted users, you can use the \`@radix-ui/react-visually-hidden\` primitive as a wrapper around your description component. 55 56For more information, see https://radix-ui.com/primitives/docs/components/alert-dialog`;return a.useEffect(()=>{var o;document.getElementById((o=e.current)==null?void 0:o.getAttribute("aria-describedby"))||console.warn(t)},[t,e]),null},Bw=el,Ww=tl,Hw=nl,Uw=ol,Kw=rl,Gw=ll,zw=dl,Yw=al,Xw=cl,Qh=[" ","Enter","ArrowUp","ArrowDown"],Jh=[" ","Enter"],Vt="Select",[Ln,kn,eg]=mt(Vt),[yt]=Z(Vt,[eg,Fe]),jn=Fe(),[tg,We]=yt(Vt),[ng,og]=yt(Vt),fl=e=>{const{__scopeSelect:t,children:n,open:o,defaultOpen:r,onOpenChange:s,value:i,defaultValue:c,onValueChange:l,dir:u,name:f,autoComplete:d,disabled:v,required:h,form:g}=e,m=jn(t),[b,x]=a.useState(null),[w,y]=a.useState(null),[C,E]=a.useState(!1),R=Ve(u),[S=!1,A]=se({prop:o,defaultProp:r,onChange:s}
56),[$,N]=se({prop:i,defaultProp:c,onChange:l}),O=a.useRef(null),j=b?g||!!b.closest("form"):!0,[V,T]=a.useState(new Set),L=Array.from(V).map(D=>D.props.value).join(";");return p.jsx(wn,{...m,children:p.jsxs(tg,{required:h,scope:t,trigger:b,onTriggerChange:x,valueNode:w,onValueNodeChange:y,valueNodeHasChildren:C,onValueNodeHasChildrenChange:E,contentId:ce(),value:$,onValueChange:N,open:S,onOpenChange:A,dir:R,triggerPointerDownPosRef:O,disabled:v,children:[p.jsx(Ln.Provider,{scope:t,children:p.jsx(ng,{scope:e.__scopeSelect,onNativeOptionAdd:a.useCallback(D=>{T(B=>new Set(B).add(D))},[]),onNativeOptionRemove:a.useCallback(D=>{T(B=>{const M=new Set(B);return M.delete(D),M})},[]),children:n})}),j?p.jsxs(kl,{"aria-hidden":!0,required:h,tabIndex:-1,name:f,autoComplete:d,value:$,onChange:D=>N(D.target.value),disabled:v,form:g,children:[$===void 0?p.jsx("option",{value:""}):null,Array.from(V)]},L):null]})})};fl.displayName=Vt;var pl="SelectTrigger",vl=a.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:o=!1,...r}=e,s=jn(n),i=We(pl,n),c=i.disabled||o,l=F(t,i.onTriggerChange),u=kn(n),f=a.useRef("touch"),[d,v,h]=jl(m=>{const b=u().filter(y=>!y.disabled),x=b.find(y=>y.value===i.value),w=Fl(b,m,x);w!==void 0&&i.onValueChange(w.value)}),g=m=>{c||(i.onOpenChange(!0),h()),m&&(i.triggerPointerDownPosRef.current={x:Math.round(m.pageX),y:Math.round(m.pageY)})};return p.jsx(Mt,{asChild:!0,...s,children:p.jsx(I.button,{type:"button",role:"combobox","aria-controls":i.contentId,"aria-expanded":i.open,"aria-required":i.required,"aria-autocomplete":"none",dir:i.dir,"data-state":i.open?"open":"closed",disabled:c,"data-disabled":c?"":void 0,"data-placeholder":Ll(i.value)?"":void 0,...r,ref:l,onClick:P(r.onClick,m=>{m.currentTarget.focus(),f.current!=="mouse"&&g(m)}),onPointerDown:P(r.onPointerDown,m=>{f.current=m.pointerType;const b=m.target;b.hasPointerCapture(m.pointerId)&&b.releasePointerCapture(m.pointerId),m.button===0&&m.ctrlKey===!1&&m.pointerType==="mouse"&&(g(m),m.preventDefault())}),onKeyDown:P(r.onKeyDown,m=>{const b=d.current!=="";!(m.ctrlKey||m.altKey||m.metaKey)&&m.key.length===1&&v(m.key),!(b&&m.key===" ")&&Qh.includes(m.key)&&(g(),m.preventDefault())})})})});vl.displayName=pl;var ml="SelectValue",hl=a.forwardRef((e,t)=>{const{__scopeSelect:n,className:o,style:r,children:s,placeholder:i="",...c}=e,l=We(ml,n),{onValueNodeHasChildrenChange:u}=l,f=s!==void 0,d=F(t,l.onValueNodeChange);return Q(()=>{u(f)},[u,f]),p.jsx(I.span,{...c,ref:d,style:{pointerEvents:"none"},children:Ll(l.value)?p.jsx(p.Fragment,{children:i}):s})});hl.displayName=ml;var rg="SelectIcon",gl=a.forwardRef((e,t)=>{const{__scopeSelect:n,children:o,...r}=e;return p.jsx(I.span,{"aria-hidden":!0,...r,ref:t,children:o||"▼"})});gl.displayName=rg;var sg="SelectPortal",bl=e=>p.jsx(ht,{asChild:!0,...e});bl.displayName=sg;var Ze="SelectContent",xl=a.forwardRef((e,t)=>{const n=We(Ze,e.__scopeSelect),[o,r]=a.useState();if(Q(()=>{r(new DocumentFragment)},[]),!n.open){const s=o;return s?Je.createPortal(p.jsx(wl,{scope:e.__scopeSelect,children:p.jsx(Ln.Slot,{scope:e.__scopeSelect,children:p.jsx("div",{children:e.children})})}),s):null}return p.jsx(yl,{...e,ref:t})});xl.displayName=Ze;var me=10,[wl,He]=yt(Ze),ag="SelectContentImpl",ig=Oe("SelectContent.RemoveScroll"),yl=a.forwardRef((e,t)=>{const{__scopeSelect:n,position:o="item-aligned",onCloseAutoFocus:r,onEscapeKeyDown:s,onPointerDownOutside:i,side:c,sideOffset:l,align:u,alignOffset:f,arrowPadding:d,collisionBoundary:v,collisionPadding:h,sticky:g,hideWhenDetached:m,avoidCollisions:b,...x}=e,w=We(Ze,n),[y,C]=a.useState(null),[E,R]=a.useState(null),S=F(t,k=>C(k)),[A,$]=a.useState(null),[N,O]=a.useState(null),j=kn(n),[V,T]=a.useState(!1),L=a.useRef(!1);a.useEffect(()=>{if(y)return Lt(y)},[y]),An();const D=a.useCallback(k=>{const[U,...z]=j().map(G=>G.ref.current),[W]=z.slice(-1),K=document.activeElement;for(const G of k)if(G===K||(G==null||G.scrollIntoView({block:"nearest"}),G===U&&E&&(E.scrollTop=0),G===W&&E&&(E.scrollTop=E.scrollHeight),G==null||G.focus(),document.activeElement!==K))return},[j,E]),B=a.useCallback(()=>D([A,y]),[D,A,y]);a.useEffect(()=>{V&&B()},[V,B]);const{onOpenChange:M,triggerPointerDownPosRef:_}=w;a.useEffect(()=>{if(y){let k={x:0,y:0};const U=W=>{var K,G;k={x:Math.abs(Math.round(W.pageX)-(((K=_.current)==null?void 0:K.x)??0)),y:Math.abs(Math.round(W.pageY)-(((G=_.current)==null?void 0:G.y)??0))}},z=W=>{k.x<=10&&k.y<=10?W.preventDefault():y.contains(W.target)||M(!1),document.removeEventListener("pointermove",U),_.current=null};return _.current!==null&&(document.addEventListener("pointermove",U),document.addEventListener("pointerup",z,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",U),document.removeEventListener("pointerup",z,{capture:!0})}}},[y,M,_]),a.useEffect(()=>{const k=()=>M(!1);return window.addEventListener("blur",k),window.addEventListener("resize",k),()=>{window.removeEventListener("blur",k),window.removeEventListener("resize",k)}},[M]);const[H,X]=jl(k=>{const U=j().filter(K=>!K.disabled),z=U.find(K=>K.ref.current===document.activeElement),W=Fl(U,k,z);W&&setTimeout(()=>W.ref.current.focus())}),J=a.useCallback((k,U,z)=>{const W=!L.current&&!z;(w.value!==void 0&&w.value===U||W)&&($(k),W&&(L.current=!0))},[w.value]),re=a.useCallback(()=>y==null?void 0:y.focus(),[y]),oe=a.useCallback((k,U,z)=>{const W=!L.current&&!z;(w.value!==void 0&&w.value===U||W)&&O(k)},[w.value]),ve=o==="popper"?bo:Cl,ae=ve===bo?{side:c,sideOffset:l,align:u,alignOffset:f,arrowPadding:d,collisionBoundary:v,collisionPadding:h,sticky:g,hideWhenDetached:m,avoidCollisions:b}:{};return p.jsx(wl,{scope:n,content:y,viewport:E,onViewportChange:R,itemRefCallback:J,selectedItem:A,onItemLeave:re,itemTextRefCallback:oe,focusSelectedItem:B,selectedItemText:N,position:o,isPositioned:V,searchRef:H,children:p.jsx(xt,{as:ig,allowPinchZoom:!0,children:p.jsx(Dt,{asChild:!0,trapped:w.open,onMountAutoFocus:k=>{k.preventDefault()},onUnmountAutoFocus:P(r,k=>{var U;(U=w.trigger)==null||U.focus({preventScroll:!0}),k.preventDefault()}),children:p.jsx(et,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:k=>k.preventDefault(),onDismiss:()=>w.onOpenChange(!1),children:p.jsx(ve,{role:"listbox",id:w.contentId,"data-state":w.open?"open":"closed",dir:w.dir,onContextMenu:k=>k.preventDefault(),...x,...ae,onPlaced:()=>T(!0),ref:S,style:{display:"flex",flexDirection:"column",outline:"none",...x.style},onKeyDown:P(x.onKeyDown,k=>{const U=k.ctrlKey||k.altKey||k.metaKey;if(k.key==="Tab"&&k.preventDefault(),!U&&k.key.length===1&&X(k.key),["ArrowUp","ArrowDown","Home","End"].includes(k.key)){let W=j().filter(K=>!K.disabled).map(K=>K.ref.current);if(["ArrowUp","End"].includes(k.key)&&(W=W.slice().reverse()),["ArrowUp","ArrowDown"].includes(k.key)){const K=k.target,G=W.indexOf(K);W=W.slice(G+1)}setTimeout(()=>D(W)),k.preventDefault()}})})})})})})});yl.displayName=ag;var cg="SelectItemAlignedPosition",Cl=a.forwardRef((e,t)=>
56{const{__scopeSelect:n,onPlaced:o,...r}=e,s=We(Ze,n),i=He(Ze,n),[c,l]=a.useState(null),[u,f]=a.useState(null),d=F(t,S=>f(S)),v=kn(n),h=a.useRef(!1),g=a.useRef(!0),{viewport:m,selectedItem:b,selectedItemText:x,focusSelectedItem:w}=i,y=a.useCallback(()=>{if(s.trigger&&s.valueNode&&c&&u&&m&&b&&x){const S=s.trigger.getBoundingClientRect(),A=u.getBoundingClientRect(),$=s.valueNode.getBoundingClientRect(),N=x.getBoundingClientRect();if(s.dir!=="rtl"){const K=N.left-A.left,G=$.left-K,te=S.left-G,le=S.width+te,Ge=Math.max(le,A.width),ze=window.innerWidth-me,Ye=_t(G,[me,Math.max(me,ze-Ge)]);c.style.minWidth=le+"px",c.style.left=Ye+"px"}else{const K=A.right-N.right,G=window.innerWidth-$.right-K,te=window.innerWidth-S.right-G,le=S.width+te,Ge=Math.max(le,A.width),ze=window.innerWidth-me,Ye=_t(G,[me,Math.max(me,ze-Ge)]);c.style.minWidth=le+"px",c.style.right=Ye+"px"}const O=v(),j=window.innerHeight-me*2,V=m.scrollHeight,T=window.getComputedStyle(u),L=parseInt(T.borderTopWidth,10),D=parseInt(T.paddingTop,10),B=parseInt(T.borderBottomWidth,10),M=parseInt(T.paddingBottom,10),_=L+D+V+M+B,H=Math.min(b.offsetHeight*5,_),X=window.getComputedStyle(m),J=parseInt(X.paddingTop,10),re=parseInt(X.paddingBottom,10),oe=S.top+S.height/2-me,ve=j-oe,ae=b.offsetHeight/2,k=b.offsetTop+ae,U=L+D+k,z=_-U;if(U<=oe){const K=O.length>0&&b===O[O.length-1].ref.current;c.style.bottom="0px";const G=u.clientHeight-m.offsetTop-m.offsetHeight,te=Math.max(ve,ae+(K?re:0)+G+B),le=U+te;c.style.height=le+"px"}else{const K=O.length>0&&b===O[0].ref.current;c.style.top="0px";const te=Math.max(oe,L+m.offsetTop+(K?J:0)+ae)+z;c.style.height=te+"px",m.scrollTop=U-oe+m.offsetTop}c.style.margin=`${me}px 0`,c.style.minHeight=H+"px",c.style.maxHeight=j+"px",o==null||o(),requestAnimationFrame(()=>h.current=!0)}},[v,s.trigger,s.valueNode,c,u,m,b,x,s.dir,o]);Q(()=>y(),[y]);const[C,E]=a.useState();Q(()=>{u&&E(window.getComputedStyle(u).zIndex)},[u]);const R=a.useCallback(S=>{S&&g.current===!0&&(y(),w==null||w(),g.current=!1)},[y,w]);return p.jsx(ug,{scope:n,contentWrapper:c,shouldExpandOnScrollRef:h,onScrollButtonChange:R,children:p.jsx("div",{ref:l,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:C},children:p.jsx(I.div,{...r,ref:d,style:{boxSizing:"border-box",maxHeight:"100%",...r.style}})})})});Cl.displayName=cg;var lg="SelectPopperPosition",bo=a.forwardRef((e,t)=>{const{__scopeSelect:n,align:o="start",collisionPadding:r=me,...s}=e,i=jn(n);return p.jsx(yn,{...i,...s,ref:t,align:o,collisionPadding:r,style:{boxSizing:"border-box",...s.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)"}})});bo.displayName=lg;var[ug,Ar]=yt(Ze,{}),xo="SelectViewport",El=a.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:o,...r}=e,s=He(xo,n),i=Ar(xo,n),c=F(t,s.onViewportChange),l=a.useRef(0);return p.jsxs(p.Fragment,{children:[p.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:o}),p.jsx(Ln.Slot,{scope:n,children:p.jsx(I.div,{"data-radix-select-viewport":"",role:"presentation",...r,ref:c,style:{position:"relative",flex:1,overflow:"hidden auto",...r.style},onScroll:P(r.onScroll,u=>{const f=u.currentTarget,{contentWrapper:d,shouldExpandOnScrollRef:v}=i;if(v!=null&&v.current&&d){const h=Math.abs(l.current-f.scrollTop);if(h>0){const g=window.innerHeight-me*2,m=parseFloat(d.style.minHeight),b=parseFloat(d.style.height),x=Math.max(m,b);if(x<g){const w=x+h,y=Math.min(g,w),C=w-y;d.style.height=y+"px",d.style.bottom==="0px"&&(f.scrollTop=C>0?C:0,d.style.justifyContent="flex-end")}}}l.current=f.scrollTop})})})]})});El.displayName=xo;var Sl="SelectGroup",[dg,fg]=yt(Sl),pg=a.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e,r=ce();return p.jsx(dg,{scope:n,id:r,children:p.jsx(I.div,{role:"group","aria-labelledby":r,...o,ref:t})})});pg.displayName=Sl;var Pl="SelectLabel",Rl=a.forwardRef((e,t)=>
56{const{__scopeSelect:n,...o}=e,r=fg(Pl,n);return p.jsx(I.div,{id:r.id,...o,ref:t})});Rl.displayName=Pl;var fn="SelectItem",[vg,Al]=yt(fn),Tl=a.forwardRef((e,t)=>{const{__scopeSelect:n,value:o,disabled:r=!1,textValue:s,...i}=e,c=We(fn,n),l=He(fn,n),u=c.value===o,[f,d]=a.useState(s??""),[v,h]=a.useState(!1),g=F(t,w=>{var y;return(y=l.itemRefCallback)==null?void 0:y.call(l,w,o,r)}),m=ce(),b=a.useRef("touch"),x=()=>{r||(c.onValueChange(o),c.onOpenChange(!1))};if(o==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return p.jsx(vg,{scope:n,value:o,disabled:r,textId:m,isSelected:u,onItemTextChange:a.useCallback(w=>{d(y=>y||((w==null?void 0:w.textContent)??"").trim())},[]),children:p.jsx(Ln.ItemSlot,{scope:n,value:o,disabled:r,textValue:f,children:p.jsx(I.div,{role:"option","aria-labelledby":m,"data-highlighted":v?"":void 0,"aria-selected":u&&v,"data-state":u?"checked":"unchecked","aria-disabled":r||void 0,"data-disabled":r?"":void 0,tabIndex:r?void 0:-1,...i,ref:g,onFocus:P(i.onFocus,()=>h(!0)),onBlur:P(i.onBlur,()=>h(!1)),onClick:P(i.onClick,()=>{b.current!=="mouse"&&x()}),onPointerUp:P(i.onPointerUp,()=>{b.current==="mouse"&&x()}),onPointerDown:P(i.onPointerDown,w=>{b.current=w.pointerType}),onPointerMove:P(i.onPointerMove,w=>{var y;b.current=w.pointerType,r?(y=l.onItemLeave)==null||y.call(l):b.current==="mouse"&&w.currentTarget.focus({preventScroll:!0})}),onPointerLeave:P(i.onPointerLeave,w=>{var y;w.currentTarget===document.activeElement&&((y=l.onItemLeave)==null||y.call(l))}),onKeyDown:P(i.onKeyDown,w=>{var C;((C=l.searchRef)==null?void 0:C.current)!==""&&w.key===" "||(Jh.includes(w.key)&&x(),w.key===" "&&w.preventDefault())})})})})});Tl.displayName=fn;var St="SelectItemText",_l=a.forwardRef((e,t)=>{const{__scopeSelect:n,className:o,style:r,...s}=e,i=We(St,n),c=He(St,n),l=Al(St,n),u=og(St,n),[f,d]=a.useState(null),v=F(t,x=>d(x),l.onItemTextChange,x=>{var w;return(w=c.itemTextRefCallback)==null?void 0:w.call(c,x,l.value,l.disabled)}),h=f==null?void 0:f.textContent,g=a.useMemo(()=>p.jsx("option",{value:l.value,disabled:l.disabled,children:h},l.value),[l.disabled,l.value,h]),{onNativeOptionAdd:m,onNativeOptionRemove:b}=u;return Q(()=>(m(g),()=>b(g)),[m,b,g]),p.jsxs(p.Fragment,{children:[p.jsx(I.span,{id:l.textId,...s,ref:v}),l.isSelected&&i.valueNode&&!i.valueNodeHasChildren?Je.createPortal(s.children,i.valueNode):null]})});_l.displayName=St;var $l="SelectItemIndicator",Il=a.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e;return Al($l,n).isSelected?p.jsx(I.span,{"aria-hidden":!0,...o,ref:t}):null});Il.displayName=$l;var wo="SelectScrollUpButton",Nl=a.forwardRef((e,t)=>{const n=He(wo,e.__scopeSelect),o=Ar(wo,e.__scopeSelect),[r,s]=a.useState(!1),i=F(t,o.onScrollButtonChange);return Q(()=>{if(n.viewport&&n.isPositioned){let c=function(){const u=l.scrollTop>0;s(u)};const l=n.viewport;return c(),l.addEventListener("scroll",c),()=>l.removeEventListener("scroll",c)}},[n.viewport,n.isPositioned]),r?p.jsx(Ol,{...e,ref:i,onAutoScroll:()=>{const{viewport:c,selectedItem:l}=n;c&&l&&(c.scrollTop=c.scrollTop-l.offsetHeight)}}):null});Nl.displayName=wo;var yo="SelectScrollDownButton",Ml=a.forwardRef((e,t)=>{const n=He(yo,e.__scopeSelect),o=Ar(yo,e.__scopeSelect),[r,s]=a.useState(!1),i=F(t,o.onScrollButtonChange);return Q(()=>{if(n.viewport&&n.isPositioned){let c=function(){const u=l.scrollHeight-l.clientHeight,f=Math.ceil(l.scrollTop)<u;s(f)};const l=n.viewport;return c(),l.addEventListener("scroll",c),()=>l.removeEventListener("scroll",c)}},[n.viewport,n.isPositioned]),r?p.jsx(Ol,{...e,ref:i,onAutoScroll:()=>{const{viewport:c,selectedItem:l}=n;c&&l&&(c.scrollTop=c.scrollTop+l.offsetHeight)}}):null});Ml.displayName=yo;var Ol=a.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:o,...r}=e,s=He("SelectScrollButton",n),i=a.useRef(null),c=kn(n),l=a.useCallback(()=>{i.current!==null&&(window.clearInterval(i.current),i.current=null)},[]);return a.useEffect(()=>()=>l(),[l]),Q(()=>{var f;const u=c().find(d=>d.ref.current===document.activeElement);(f=u==null?void 0:u.ref.current)==null||f.scrollIntoView({block:"nearest"})},[c]),p.jsx(I.div,{"aria-hidden":!0,...r,ref:t,style:{flexShrink:0,...r.style},onPointerDown:P(r.onPointerDown,()=>{i.current===null&&(i.current=window.setInterval(o,50))}),onPointerMove:P(r.onPointerMove,()=>{var u;(u=s.onItemLeave)==null||u.call(s),i.current===null&&(i.current=window.setInterval(o,50))}),onPointerLeave:P(r.onPointerLeave,()=>{l()})})}),mg="SelectSeparator",Dl=a.forwardRef((e,t)=>
56{const{__scopeSelect:n,...o}=e;return p.jsx(I.div,{"aria-hidden":!0,...o,ref:t})});Dl.displayName=mg;var Co="SelectArrow",hg=a.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e,r=jn(n),s=We(Co,n),i=He(Co,n);return s.open&&i.position==="popper"?p.jsx(Cn,{...r,...o,ref:t}):null});hg.displayName=Co;function Ll(e){return e===""||e===void 0}var kl=a.forwardRef((e,t)=>{const{value:n,...o}=e,r=a.useRef(null),s=F(t,r),i=Ot(n);return a.useEffect(()=>{const c=r.current,l=window.HTMLSelectElement.prototype,f=Object.getOwnPropertyDescriptor(l,"value").set;if(i!==n&&f){const d=new Event("change",{bubbles:!0});f.call(c,n),c.dispatchEvent(d)}},[i,n]),p.jsx($t,{asChild:!0,children:p.jsx("select",{...o,ref:s,defaultValue:n})})});kl.displayName="BubbleSelect";function jl(e){const t=q(e),n=a.useRef(""),o=a.useRef(0),r=a.useCallback(i=>{const c=n.current+i;t(c),function l(u){n.current=u,window.clearTimeout(o.current),u!==""&&(o.current=window.setTimeout(()=>l(""),1e3))}(c)},[t]),s=a.useCallback(()=>{n.current="",window.clearTimeout(o.current)},[]);return a.useEffect(()=>()=>window.clearTimeout(o.current),[]),[n,r,s]}function Fl(e,t,n){const r=t.length>1&&Array.from(t).every(u=>u===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let i=gg(e,Math.max(s,0));r.length===1&&(i=i.filter(u=>u!==n));const l=i.find(u=>u.textValue.toLowerCase().startsWith(r.toLowerCase()));return l!==n?l:void 0}function gg(e,t){return e.map((n,o)=>e[(t+o)%e.length])}var qw=fl,Zw=vl,Qw=hl,Jw=gl,ey=bl,ty=xl,ny=El,oy=Rl,ry=Tl,sy=_l,ay=Il,iy=Nl,cy=Ml,ly=Dl,Vl=["PageUp","PageDown"],Bl=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],Wl={"from-left":["Home","PageDown","ArrowDown","ArrowLeft"],"from-right":["Home","PageDown","ArrowDown","ArrowRight"],"from-bottom":["Home","PageDown","ArrowDown","ArrowLeft"],"from-top":["Home","PageDown","ArrowUp","ArrowLeft"]},Ct="Slider",[Eo,bg,xg]=mt(Ct),[Hl]=Z(Ct,[xg]),[wg,Fn]=Hl(Ct),Ul=a.forwardRef((e,t)=>{const{name:n,min:o=0,max:r=100,step:s=1,orientation:i="horizontal",disabled:c=!1,minStepsBetweenThumbs:l=0,defaultValue:u=[o],value:f,onValueChange:d=()=>{},onValueCommit:v=()=>{},inverted:h=!1,form:g,...m}=e,b=a.useRef(new Set),x=a.useRef(0),y=i==="horizontal"?yg:Cg,[C=[],E]=se({prop:f,defaultProp:u,onChange:O=>{var V;(V=[...b.current][x.current])==null||V.focus(),d(O)}}),R=a.useRef(C);function S(O){const j=Ag(C,O);N(O,j)}function A(O){N(O,x.current)}function $(){const O=R.current[x.current];C[x.current]!==O&&v(C)}function N(O,j,{commit:V}={commit:!1}){const T=Ig(s),L=Ng(Math.round((O-o)/s)*s+o,T),D=_t(L,[o,r]);E((B=[])=>{const M=Pg(B,D,j);if($g(M,l*s)){x.current=M.indexOf(D);const _=String(M)!==String(B);return _&&V&&v(M),_?M:B}else return B})}return p.jsx(wg,{scope:e.__scopeSlider,name:n,disabled:c,min:o,max:r,valueIndexToChangeRef:x,thumbs:b.current,values:C,orientation:i,form:g,children:p.jsx(Eo.Provider,{scope:e.__scopeSlider,children:p.jsx(Eo.Slot,{scope:e.__scopeSlider,children:p.jsx(y,{"aria-disabled":c,"data-disabled":c?"":void 0,...m,ref:t,onPointerDown:P(m.onPointerDown,()=>{c||(R.current=C)}),min:o,max:r,inverted:h,onSlideStart:c?void 0:S,onSlideMove:c?void 0:A,onSlideEnd:c?void 0:$,onHomeKeyDown:()=>!c&&N(o,0,{commit:!0}),onEndKeyDown:()=>!c&&N(r,C.length-1,{commit:!0}),onStepKeyDown:({event:O,direction:j})=>{if(!c){const L=Vl.includes(O.key)||O.shiftKey&&Bl.includes(O.key)?10:1,D=x.current,B=C[D],M=s*L*j;N(B+M,D,{commit:!0})}}})})})})});Ul.displayName=Ct;var[Kl,Gl]=Hl(Ct,{startEdge:"left",endEdge:"right",size:"width",direction:1}),yg=a.forwardRef((e,t)=>{const{min:n,max:o,dir:r,inverted:s,onSlideStart:i,onSlideMove:c,onSlideEnd:l,onStepKeyDown:u,...f}=e,[d,v]=a.useState(null),h=F(t,y=>v(y)),g=a.useRef(void 0),m=Ve(r),b=m==="ltr",x=b&&!s||!b&&s;function w(y){const C=g.current||d.getBoundingClientRect(),E=[0,C.width],S=Tr(E,x?[n,o]:[o,n]);return g.current=C,S(y-C.left)}return p.jsx(Kl,{scope:e.__scopeSlider,startEdge:x?"left":"right",endEdge:x?"right":"left",direction:x?1:-1,size:"width",children:p.jsx(zl,{dir:m,"data-orientation":"horizontal",...f,ref:h,style:{...f.style,"--radix-slider-thumb-transform":"translateX(-50%)"},onSlideStart:y=>{const C=w(y.clientX);i==null||i(C)},onSlideMove:y=>{const C=w(y.clientX);c==null||c(C)},onSlideEnd:()=>{g.current=void 0,l==null||l()},onStepKeyDown:y=>{const E=Wl[x?"from-left":"from-right"].includes(y.key);u==null||u({event:y,direction:E?-1:1})}})})}),Cg=a.forwardRef((e,t)=>
56{const{min:n,max:o,inverted:r,onSlideStart:s,onSlideMove:i,onSlideEnd:c,onStepKeyDown:l,...u}=e,f=a.useRef(null),d=F(t,f),v=a.useRef(void 0),h=!r;function g(m){const b=v.current||f.current.getBoundingClientRect(),x=[0,b.height],y=Tr(x,h?[o,n]:[n,o]);return v.current=b,y(m-b.top)}return p.jsx(Kl,{scope:e.__scopeSlider,startEdge:h?"bottom":"top",endEdge:h?"top":"bottom",size:"height",direction:h?1:-1,children:p.jsx(zl,{"data-orientation":"vertical",...u,ref:d,style:{...u.style,"--radix-slider-thumb-transform":"translateY(50%)"},onSlideStart:m=>{const b=g(m.clientY);s==null||s(b)},onSlideMove:m=>{const b=g(m.clientY);i==null||i(b)},onSlideEnd:()=>{v.current=void 0,c==null||c()},onStepKeyDown:m=>{const x=Wl[h?"from-bottom":"from-top"].includes(m.key);l==null||l({event:m,direction:x?-1:1})}})})}),zl=a.forwardRef((e,t)=>{const{__scopeSlider:n,onSlideStart:o,onSlideMove:r,onSlideEnd:s,onHomeKeyDown:i,onEndKeyDown:c,onStepKeyDown:l,...u}=e,f=Fn(Ct,n);return p.jsx(I.span,{...u,ref:t,onKeyDown:P(e.onKeyDown,d=>{d.key==="Home"?(i(d),d.preventDefault()):d.key==="End"?(c(d),d.preventDefault()):Vl.concat(Bl).includes(d.key)&&(l(d),d.preventDefault())}),onPointerDown:P(e.onPointerDown,d=>{const v=d.target;v.setPointerCapture(d.pointerId),d.preventDefault(),f.thumbs.has(v)?v.focus():o(d)}),onPointerMove:P(e.onPointerMove,d=>{d.target.hasPointerCapture(d.pointerId)&&r(d)}),onPointerUp:P(e.onPointerUp,d=>{const v=d.target;v.hasPointerCapture(d.pointerId)&&(v.releasePointerCapture(d.pointerId),s(d))})})}),Yl="SliderTrack",Xl=a.forwardRef((e,t)=>{const{__scopeSlider:n,...o}=e,r=Fn(Yl,n);return p.jsx(I.span,{"data-disabled":r.disabled?"":void 0,"data-orientation":r.orientation,...o,ref:t})});Xl.displayName=Yl;var So="SliderRange",ql=a.forwardRef((e,t)=>{const{__scopeSlider:n,...o}=e,r=Fn(So,n),s=Gl(So,n),i=a.useRef(null),c=F(t,i),l=r.values.length,u=r.values.map(v=>Ql(v,r.min,r.max)),f=l>1?Math.min(...u):0,d=100-Math.max(...u);return p.jsx(I.span,{"data-orientation":r.orientation,"data-disabled":r.disabled?"":void 0,...o,ref:c,style:{...e.style,[s.startEdge]:f+"%",[s.endEdge]:d+"%"}})});ql.displayName=So;var Po="SliderThumb",Zl=a.forwardRef((e,t)=>{const n=bg(e.__scopeSlider),[o,r]=a.useState(null),s=F(t,c=>r(c)),i=a.useMemo(()=>o?n().findIndex(c=>c.ref.current===o):-1,[n,o]);return p.jsx(Eg,{...e,ref:s,index:i})}),Eg=a.forwardRef((e,t)=>{const{__scopeSlider:n,index:o,name:r,...s}=e,i=Fn(Po,n),c=Gl(Po,n),[l,u]=a.useState(null),f=F(t,w=>u(w)),d=l?i.form||!!l.closest("form"):!0,v=Nt(l),h=i.values[o],g=h===void 0?0:Ql(h,i.min,i.max),m=Rg(o,i.values.length),b=v==null?void 0:v[c.size],x=b?Tg(b,g,c.direction):0;return a.useEffect(()=>{if(l)return i.thumbs.add(l),()=>{i.thumbs.delete(l)}},[l,i.thumbs]),p.jsxs("span",{style:{transform:"var(--radix-slider-thumb-transform)",position:"absolute",[c.startEdge]:`calc(${g}% + ${x}px)`},children:[p.jsx(Eo.ItemSlot,{scope:e.__scopeSlider,children:p.jsx(I.span,{role:"slider","aria-label":e["aria-label"]||m,"aria-valuemin":i.min,"aria-valuenow":h,"aria-valuemax":i.max,"aria-orientation":i.orientation,"data-orientation":i.orientation,"data-disabled":i.disabled?"":void 0,tabIndex:i.disabled?void 0:0,...s,ref:f,style:h===void 0?{display:"none"}:e.style,onFocus:P(e.onFocus,()=>{i.valueIndexToChangeRef.current=o})})}),d&&p.jsx(Sg,{name:r??(i.name?i.name+(i.values.length>1?"[]":""):void 0),form:i.form,value:h},o)]})});Zl.displayName=Po;var Sg=e=>{const{value:t,...n}=e,o=a.useRef(null),r=Ot(t);return a.useEffect(()=>{const s=o.current,i=window.HTMLInputElement.prototype,l=Object.getOwnPropertyDescriptor(i,"value").set;if(r!==t&&l){const u=new Event("input",{bubbles:!0});l.call(s,t),s.dispatchEvent(u)}},[r,t]),p.jsx("input",{style:{display:"none"},...n,ref:o,defaultValue:t})};function Pg(e=[],t,n){const o=[...e];return o[n]=t,o.sort((r,s)=>r-s)}function Ql(e,t,n){const s=100/(n-t)*(e-t);return _t(s,[0,100])}function Rg(e,t){return t>2?`Value ${e+1} of ${t}`:t===2?["Minimum","Maximum"][e]:void 0}function Ag(e,t){if(e.length===1)return 0;const n=e.map(r=>Math.abs(r-t)),o=Math.min(...n);return n.indexOf(o)}function Tg(e,t,n){const o=e/2,s=Tr([0,50],[0,o]);return(o-s(t)*n)*n}function _g(e){return e.slice(0,-1).map((t,n)=>e[n+1]-t)}function $g(e,t){if(t>0){const n=_g(e);return Math.min(...n)>=t}return!0}function Tr(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const o=(t[1]-t[0])/(e[1]-e[0]);return t[0]+o*(n-e[0])}}function Ig(e){return(String(e).split(".")[1]||"").length}function Ng(e,t){const n=Math.pow(10,t);return Math.round(e*n)/n}var uy=Ul,dy=Xl,fy=ql,py=Zl,_r="Tabs",[Mg]=Z(_r,[wt]),Jl=wt(),[Og,$r]=Mg(_r),eu=a.forwardRef((e,t)=>
56{const{__scopeTabs:n,value:o,onValueChange:r,defaultValue:s,orientation:i="horizontal",dir:c,activationMode:l="automatic",...u}=e,f=Ve(c),[d,v]=se({prop:o,onChange:r,defaultProp:s});return p.jsx(Og,{scope:n,baseId:ce(),value:d,onValueChange:v,orientation:i,dir:f,activationMode:l,children:p.jsx(I.div,{dir:f,"data-orientation":i,...u,ref:t})})});eu.displayName=_r;var tu="TabsList",nu=a.forwardRef((e,t)=>{const{__scopeTabs:n,loop:o=!0,...r}=e,s=$r(tu,n),i=Jl(n);return p.jsx(er,{asChild:!0,...i,orientation:s.orientation,dir:s.dir,loop:o,children:p.jsx(I.div,{role:"tablist","aria-orientation":s.orientation,...r,ref:t})})});nu.displayName=tu;var ou="TabsTrigger",ru=a.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,disabled:r=!1,...s}=e,i=$r(ou,n),c=Jl(n),l=iu(i.baseId,o),u=cu(i.baseId,o),f=o===i.value;return p.jsx(tr,{asChild:!0,...c,focusable:!r,active:f,children:p.jsx(I.button,{type:"button",role:"tab","aria-selected":f,"aria-controls":u,"data-state":f?"active":"inactive","data-disabled":r?"":void 0,disabled:r,id:l,...s,ref:t,onMouseDown:P(e.onMouseDown,d=>{!r&&d.button===0&&d.ctrlKey===!1?i.onValueChange(o):d.preventDefault()}),onKeyDown:P(e.onKeyDown,d=>{[" ","Enter"].includes(d.key)&&i.onValueChange(o)}),onFocus:P(e.onFocus,()=>{const d=i.activationMode!=="manual";!f&&!r&&d&&i.onValueChange(o)})})})});ru.displayName=ou;var su="TabsContent",au=a.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,forceMount:r,children:s,...i}=e,c=$r(su,n),l=iu(c.baseId,o),u=cu(c.baseId,o),f=o===c.value,d=a.useRef(f);return a.useEffect(()=>{const v=requestAnimationFrame(()=>d.current=!1);return()=>cancelAnimationFrame(v)},[]),p.jsx(ee,{present:r||f,children:({present:v})=>p.jsx(I.div,{"data-state":f?"active":"inactive","data-orientation":c.orientation,role:"tabpanel","aria-labelledby":l,hidden:!v,id:u,tabIndex:0,...i,ref:t,style:{...e.style,animationDuration:d.current?"0s":void 0},children:v&&s})})});au.displayName=su;function iu(e,t){return`${e}-trigger-${t}`}function cu(e,t){return`${e}-content-${t}`}var vy=eu,my=nu,hy=ru,gy=au,Dg="Separator",ps="horizontal",Lg=["horizontal","vertical"],lu=a.forwardRef((e,t)=>{const{decorative:n,orientation:o=ps,...r}=e,s=kg(o)?o:ps,c=n?{role:"none"}:{"aria-orientation":s==="vertical"?s:void 0,role:"separator"};return p.jsx(I.div,{"data-orientation":s,...c,...r,ref:t})});lu.displayName=Dg;function kg(e){return Lg.includes(e)}var by=lu;function Me(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e==null||e(r),n===!1||!r.defaultPrevented)return t==null?void 0:t(r)}}function vs(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function uu(...e){return t=>{let n=!1;const o=e.map(r=>{const s=vs(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():vs(e[r],null)}}}}function Ue(...e){return a.useCallback(uu(...e),e)}function du(e,t=[]){let n=[];function o(s,i){const c=a.createContext(i),l=n.length;n=[...n,i];const u=d=>{var x;const{scope:v,children:h,...g}=d,m=((x=v==null?void 0:v[e])==null?void 0:x[l])||c,b=a.useMemo(()=>g,Object.values(g));return p.jsx(m.Provider,{value:b,children:h})};u.displayName=s+"Provider";function f(d,v){var m;const h=((m=v==null?void 0:v[e])==null?void 0:m[l])||c,g=a.useContext(h);if(g)return g;if(i!==void 0)return i;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[u,f]}const r=()=>{const s=n.map(i=>a.createContext(i));return function(c){const l=(c==null?void 0:c[e])||s;return a.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return r.scopeName=e,[o,jg(r,...t)]}function jg(...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:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return a.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}var Ir=a.forwardRef((e,t)=>{const{children:n,...o}=e,r=a.Children.toArray(n),s=r.find(Vg);if(s){const i=s.props.children,c=r.map(l=>l===s?a.Children.count(i)>1?a.Children.only(null):a.isValidElement(i)?i.props.children:null:l);return p.jsx(Ro,{...o,ref:t,children:a.isValidElement(i)?a.cloneElement(i,void 0,c):null})}return p.jsx(Ro,{...o,ref:t,children:n})});Ir.displayName="Slot";var Ro=a.forwardRef((e,t)=>
56{const{children:n,...o}=e;if(a.isValidElement(n)){const r=Wg(n),s=Bg(o,n.props);return n.type!==a.Fragment&&(s.ref=t?uu(t,r):r),a.cloneElement(n,s)}return a.Children.count(n)>1?a.Children.only(null):null});Ro.displayName="SlotClone";var Fg=({children:e})=>p.jsx(p.Fragment,{children:e});function Vg(e){return a.isValidElement(e)&&e.type===Fg}function Bg(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 Wg(e){var o,r;let t=(o=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(r=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Hg=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],_e=Hg.reduce((e,t)=>{const n=a.forwardRef((o,r)=>{const{asChild:s,...i}=o,c=s?Ir:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(c,{...i,ref:r})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function Ug(e,t){e&&Je.flushSync(()=>e.dispatchEvent(t))}function je(e){const t=a.useRef(e);return a.useEffect(()=>{t.current=e}),a.useMemo(()=>(...n)=>{var o;return(o=t.current)==null?void 0:o.call(t,...n)},[])}function Kg(e,t=globalThis==null?void 0:globalThis.document){const n=je(e);a.useEffect(()=>{const o=r=>{r.key==="Escape"&&n(r)};return t.addEventListener("keydown",o,{capture:!0}),()=>t.removeEventListener("keydown",o,{capture:!0})},[n,t])}var Gg="DismissableLayer",Ao="dismissableLayer.update",zg="dismissableLayer.pointerDownOutside",Yg="dismissableLayer.focusOutside",ms,fu=a.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),pu=a.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:o,onPointerDownOutside:r,onFocusOutside:s,onInteractOutside:i,onDismiss:c,...l}=e,u=a.useContext(fu),[f,d]=a.useState(null),v=(f==null?void 0:f.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,h]=a.useState({}),g=Ue(t,S=>d(S)),m=Array.from(u.layers),[b]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),x=m.indexOf(b),w=f?m.indexOf(f):-1,y=u.layersWithOutsidePointerEventsDisabled.size>0,C=w>=x,E=Zg(S=>{const A=S.target,$=[...u.branches].some(N=>N.contains(A));!C||$||(r==null||r(S),i==null||i(S),S.defaultPrevented||c==null||c())},v),R=Qg(S=>{const A=S.target;[...u.branches].some(N=>N.contains(A))||(s==null||s(S),i==null||i(S),S.defaultPrevented||c==null||c())},v);return Kg(S=>{w===u.layers.size-1&&(o==null||o(S),!S.defaultPrevented&&c&&(S.preventDefault(),c()))},v),a.useEffect(()=>{if(f)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(ms=v.body.style.pointerEvents,v.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(f)),u.layers.add(f),hs(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(v.body.style.pointerEvents=ms)}},[f,v,n,u]),a.useEffect(()=>()=>{f&&(u.layers.delete(f),u.layersWithOutsidePointerEventsDisabled.delete(f),hs())},[f,u]),a.useEffect(()=>{const S=()=>h({});return document.addEventListener(Ao,S),()=>document.removeEventListener(Ao,S)},[]),p.jsx(_e.div,{...l,ref:g,style:{pointerEvents:y?C?"auto":"none":void 0,...e.style},onFocusCapture:Me(e.onFocusCapture,R.onFocusCapture),onBlurCapture:Me(e.onBlurCapture,R.onBlurCapture),onPointerDownCapture:Me(e.onPointerDownCapture,E.onPointerDownCapture)})});pu.displayName=Gg;var Xg="DismissableLayerBranch",qg=a.forwardRef((e,t)=>{const n=a.useContext(fu),o=a.useRef(null),r=Ue(t,o);return a.useEffect(()=>{const s=o.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),p.jsx(_e.div,{...e,ref:r})});qg.displayName=Xg;function Zg(e,t=globalThis==null?void 0:globalThis.document){const n=je(e),o=a.useRef(!1),r=a.useRef(()=>{});return a.useEffect(()=>{const s=c=>{if(c.target&&!o.current){let l=function(){vu(zg,n,u,{discrete:!0})};const u={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 Qg(e,t=globalThis==null?void 0:globalThis.document){const n=je(e),o=a.useRef(!1);return a.useEffect(()=>{const r=s=>
56{s.target&&!o.current&&vu(Yg,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 hs(){const e=new CustomEvent(Ao);document.dispatchEvent(e)}function vu(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?Ug(r,s):r.dispatchEvent(s)}var Jn=0;function Jg(){a.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??gs()),document.body.insertAdjacentElement("beforeend",e[1]??gs()),Jn++,()=>{Jn===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Jn--}},[])}function gs(){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 eo="focusScope.autoFocusOnMount",to="focusScope.autoFocusOnUnmount",bs={bubbles:!1,cancelable:!0},eb="FocusScope",mu=a.forwardRef((e,t)=>{const{loop:n=!1,trapped:o=!1,onMountAutoFocus:r,onUnmountAutoFocus:s,...i}=e,[c,l]=a.useState(null),u=je(r),f=je(s),d=a.useRef(null),v=Ue(t,m=>l(m)),h=a.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;a.useEffect(()=>{if(o){let m=function(y){if(h.paused||!c)return;const C=y.target;c.contains(C)?d.current=C:Ie(d.current,{select:!0})},b=function(y){if(h.paused||!c)return;const C=y.relatedTarget;C!==null&&(c.contains(C)||Ie(d.current,{select:!0}))},x=function(y){if(document.activeElement===document.body)for(const E of y)E.removedNodes.length>0&&Ie(c)};document.addEventListener("focusin",m),document.addEventListener("focusout",b);const w=new MutationObserver(x);return c&&w.observe(c,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",m),document.removeEventListener("focusout",b),w.disconnect()}}},[o,c,h.paused]),a.useEffect(()=>{if(c){ws.add(h);const m=document.activeElement;if(!c.contains(m)){const x=new CustomEvent(eo,bs);c.addEventListener(eo,u),c.dispatchEvent(x),x.defaultPrevented||(tb(ab(hu(c)),{select:!0}),document.activeElement===m&&Ie(c))}return()=>{c.removeEventListener(eo,u),setTimeout(()=>{const x=new CustomEvent(to,bs);c.addEventListener(to,f),c.dispatchEvent(x),x.defaultPrevented||Ie(m??document.body,{select:!0}),c.removeEventListener(to,f),ws.remove(h)},0)}}},[c,u,f,h]);const g=a.useCallback(m=>{if(!n&&!o||h.paused)return;const b=m.key==="Tab"&&!m.altKey&&!m.ctrlKey&&!m.metaKey,x=document.activeElement;if(b&&x){const w=m.currentTarget,[y,C]=nb(w);y&&C?!m.shiftKey&&x===C?(m.preventDefault(),n&&Ie(y,{select:!0})):m.shiftKey&&x===y&&(m.preventDefault(),n&&Ie(C,{select:!0})):x===w&&m.preventDefault()}},[n,o,h.paused]);return p.jsx(_e.div,{tabIndex:-1,...i,ref:v,onKeyDown:g})});mu.displayName=eb;function tb(e,{select:t=!1}={}){const n=document.activeElement;for(const o of e)if(Ie(o,{select:t}),document.activeElement!==n)return}function nb(e){const t=hu(e),n=xs(t,e),o=xs(t.reverse(),e);return[n,o]}function hu(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 xs(e,t){for(const n of e)if(!ob(n,{upTo:t}))return n}function ob(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 rb(e){return e instanceof HTMLInputElement&&"select"in e}function Ie(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&rb(e)&&t&&e.select()}}var ws=sb();function sb(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=ys(e,t),e.unshift(t)},remove(t){var n;e=ys(e,t),(n=e[0])==null||n.resume()}}}function ys(e,t){const n=[...e],o=n.indexOf(t);return o!==-1&&n.splice(o,1),n}function ab(e){return e.filter(t=>t.tagName!=="A")}var Qe=globalThis!=null&&globalThis.document?a.useLayoutEffect:()=>{},ib=pn.useId||(()=>{}),cb=0;function lb(e){const[t,n]=a.useState(ib());return Qe(()=>{n(o=>o??String(cb++))},[e]),e||(t?`radix-${t}`:"")}var ub="Arrow",gu=a.forwardRef((e,t)=>
56{const{children:n,width:o=10,height:r=5,...s}=e;return p.jsx(_e.svg,{...s,ref:t,width:o,height:r,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:p.jsx("polygon",{points:"0,0 30,0 15,10"})})});gu.displayName=ub;var db=gu;function fb(e){const[t,n]=a.useState(void 0);return Qe(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const o=new ResizeObserver(r=>{if(!Array.isArray(r)||!r.length)return;const s=r[0];let i,c;if("borderBoxSize"in s){const l=s.borderBoxSize,u=Array.isArray(l)?l[0]:l;i=u.inlineSize,c=u.blockSize}else i=e.offsetWidth,c=e.offsetHeight;n({width:i,height:c})});return o.observe(e,{box:"border-box"}),()=>o.unobserve(e)}else n(void 0)},[e]),t}var Nr="Popper",[bu,xu]=du(Nr),[pb,wu]=bu(Nr),yu=e=>{const{__scopePopper:t,children:n}=e,[o,r]=a.useState(null);return p.jsx(pb,{scope:t,anchor:o,onAnchorChange:r,children:n})};yu.displayName=Nr;var Cu="PopperAnchor",Eu=a.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:o,...r}=e,s=wu(Cu,n),i=a.useRef(null),c=Ue(t,i);return a.useEffect(()=>{s.onAnchorChange((o==null?void 0:o.current)||i.current)}),o?null:p.jsx(_e.div,{...r,ref:c})});Eu.displayName=Cu;var Mr="PopperContent",[vb,mb]=bu(Mr),Su=a.forwardRef((e,t)=>{var k,U,z,W,K,G;const{__scopePopper:n,side:o="bottom",sideOffset:r=0,align:s="center",alignOffset:i=0,arrowPadding:c=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:f=0,sticky:d="partial",hideWhenDetached:v=!1,updatePositionStrategy:h="optimized",onPlaced:g,...m}=e,b=wu(Mr,n),[x,w]=a.useState(null),y=Ue(t,te=>w(te)),[C,E]=a.useState(null),R=fb(C),S=(R==null?void 0:R.width)??0,A=(R==null?void 0:R.height)??0,$=o+(s!=="center"?"-"+s:""),N=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},O=Array.isArray(u)?u:[u],j=O.length>0,V={padding:N,boundary:O.filter(gb),altBoundary:j},{refs:T,floatingStyles:L,placement:D,isPositioned:B,middlewareData:M}=Js({strategy:"fixed",placement:$,whileElementsMounted:(...te)=>Zs(...te,{animationFrame:h==="always"}),elements:{reference:b.anchor},middleware:[ea({mainAxis:r+A,alignmentAxis:i}),l&&ta({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?na():void 0,...V}),l&&oa({...V}),ra({...V,apply:({elements:te,rects:le,availableWidth:Ge,availableHeight:ze})=>{const{width:Ye,height:Bn}=le.reference,Se=te.floating.style;Se.setProperty("--radix-popper-available-width",`${Ge}px`),Se.setProperty("--radix-popper-available-height",`${ze}px`),Se.setProperty("--radix-popper-anchor-width",`${Ye}px`),Se.setProperty("--radix-popper-anchor-height",`${Bn}px`)}}),C&&aa({element:C,padding:c}),bb({arrowWidth:S,arrowHeight:A}),v&&sa({strategy:"referenceHidden",...V})]}),[_,H]=Au(D),X=je(g);Qe(()=>{B&&(X==null||X())},[B,X]);const J=(k=M.arrow)==null?void 0:k.x,re=(U=M.arrow)==null?void 0:U.y,oe=((z=M.arrow)==null?void 0:z.centerOffset)!==0,[ve,ae]=a.useState();return Qe(()=>{x&&ae(window.getComputedStyle(x).zIndex)},[x]),p.jsx("div",{ref:T.setFloating,"data-radix-popper-content-wrapper":"",style:{...L,transform:B?L.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ve,"--radix-popper-transform-origin":[(W=M.transformOrigin)==null?void 0:W.x,(K=M.transformOrigin)==null?void 0:K.y].join(" "),...((G=M.hide)==null?void 0:G.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:p.jsx(vb,{scope:n,placedSide:_,onArrowChange:E,arrowX:J,arrowY:re,shouldHideArrow:oe,children:p.jsx(_e.div,{"data-side":_,"data-align":H,...m,ref:y,style:{...m.style,animation:B?void 0:"none"}})})})});Su.displayName=Mr;var Pu="PopperArrow",hb={top:"bottom",right:"left",bottom:"top",left:"right"},Ru=a.forwardRef(function(t,n){const{__scopePopper:o,...r}=t,s=mb(Pu,o),i=hb[s.placedSide];return p.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:p.jsx(db,{...r,ref:n,style:{...r.style,display:"block"}})})});Ru.displayName=Pu;function gb(e){return e!==null}var bb=e=>({name:"transformOrigin",options:e,fn(t){var b,x,w;const{placement:n,rects:o,middlewareData:r}=t,i=((b=r.arrow)==null?void 0:b.centerOffset)!==0,c=i?0:e.arrowWidth,l=i?0:e.arrowHeight,[u,f]=Au(n),d={start:"0%",center:"50%",end:"100%"}[f],v=(((x=r.arrow)==null?void 0:x.x)??0)+c/2,h=(((w=r.arrow)==null?void 0:w.y)??0)+l/2;let g="",m="";return u==="bottom"?(g=i?d:`${v}px`,m=`${-l}px`):u==="top"?(g=i?d:`${v}px`,m=`${o.floating.height+l}px`):u==="right"?(g=`${-l}px`,m=i?d:`${h}px`):u==="left"&&(g=`${o.floating.width+l}px`,m=i?d:`${h}px`),{data:{x:g,y:m}}}});function Au(e){const[t,n="center"]=e.split("-");return[t,n]}var xb=yu,Tu=Eu,wb=Su,yb=Ru,Cb="Portal",_u=a.forwardRef((e,t)=>
56{var c;const{container:n,...o}=e,[r,s]=a.useState(!1);Qe(()=>s(!0),[]);const i=n||r&&((c=globalThis==null?void 0:globalThis.document)==null?void 0:c.body);return i?Es.createPortal(p.jsx(_e.div,{...o,ref:t}),i):null});_u.displayName=Cb;function Eb(e,t){return a.useReducer((n,o)=>t[n][o]??n,e)}var Or=e=>{const{present:t,children:n}=e,o=Sb(t),r=typeof n=="function"?n({present:o.isPresent}):a.Children.only(n),s=Ue(o.ref,Pb(r));return typeof n=="function"||o.isPresent?a.cloneElement(r,{ref:s}):null};Or.displayName="Presence";function Sb(e){const[t,n]=a.useState(),o=a.useRef({}),r=a.useRef(e),s=a.useRef("none"),i=e?"mounted":"unmounted",[c,l]=Eb(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return a.useEffect(()=>{const u=Xt(o.current);s.current=c==="mounted"?u:"none"},[c]),Qe(()=>{const u=o.current,f=r.current;if(f!==e){const v=s.current,h=Xt(u);e?l("MOUNT"):h==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(f&&v!==h?"ANIMATION_OUT":"UNMOUNT"),r.current=e}},[e,l]),Qe(()=>{if(t){let u;const f=t.ownerDocument.defaultView??window,d=h=>{const m=Xt(o.current).includes(h.animationName);if(h.target===t&&m&&(l("ANIMATION_END"),!r.current)){const b=t.style.animationFillMode;t.style.animationFillMode="forwards",u=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=b)})}},v=h=>{h.target===t&&(s.current=Xt(o.current))};return t.addEventListener("animationstart",v),t.addEventListener("animationcancel",d),t.addEventListener("animationend",d),()=>{f.clearTimeout(u),t.removeEventListener("animationstart",v),t.removeEventListener("animationcancel",d),t.removeEventListener("animationend",d)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(c),ref:a.useCallback(u=>{u&&(o.current=getComputedStyle(u)),n(u)},[])}}function Xt(e){return(e==null?void 0:e.animationName)||"none"}function Pb(e){var o,r;let t=(o=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(r=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function Rb({prop:e,defaultProp:t,onChange:n=()=>{}}){const[o,r]=Ab({defaultProp:t,onChange:n}),s=e!==void 0,i=s?e:o,c=je(n),l=a.useCallback(u=>{if(s){const d=typeof u=="function"?u(e):u;d!==e&&c(d)}else r(u)},[s,e,r,c]);return[i,l]}function Ab({defaultProp:e,onChange:t}){const n=a.useState(e),[o]=n,r=a.useRef(o),s=je(t);return a.useEffect(()=>{r.current!==o&&(s(o),r.current=o)},[o,r,s]),n}var Dr="Popover",[$u]=du(Dr,[xu]),Bt=xu(),[Tb,Ke]=$u(Dr),Iu=e=>{const{__scopePopover:t,children:n,open:o,defaultOpen:r,onOpenChange:s,modal:i=!1}=e,c=Bt(t),l=a.useRef(null),[u,f]=a.useState(!1),[d=!1,v]=Rb({prop:o,defaultProp:r,onChange:s});return p.jsx(xb,{...c,children:p.jsx(Tb,{scope:t,contentId:lb(),triggerRef:l,open:d,onOpenChange:v,onOpenToggle:a.useCallback(()=>v(h=>!h),[v]),hasCustomAnchor:u,onCustomAnchorAdd:a.useCallback(()=>f(!0),[]),onCustomAnchorRemove:a.useCallback(()=>f(!1),[]),modal:i,children:n})})};Iu.displayName=Dr;var Nu="PopoverAnchor",_b=a.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=Ke(Nu,n),s=Bt(n),{onCustomAnchorAdd:i,onCustomAnchorRemove:c}=r;return a.useEffect(()=>(i(),()=>c()),[i,c]),p.jsx(Tu,{...s,...o,ref:t})});_b.displayName=Nu;var Mu="PopoverTrigger",Ou=a.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=Ke(Mu,n),s=Bt(n),i=Ue(t,r.triggerRef),c=p.jsx(_e.button,{type:"button","aria-haspopup":"dialog","aria-expanded":r.open,"aria-controls":r.contentId,"data-state":Vu(r.open),...o,ref:i,onClick:Me(e.onClick,r.onOpenToggle)});return r.hasCustomAnchor?c:p.jsx(Tu,{asChild:!0,...s,children:c})});Ou.displayName=Mu;var Lr="PopoverPortal",[$b,Ib]=$u(Lr,{forceMount:void 0}),Du=e=>{const{__scopePopover:t,forceMount:n,children:o,container:r}=e,s=Ke(Lr,t);return p.jsx($b,{scope:t,forceMount:n,children:p.jsx(Or,{present:n||s.open,children:p.jsx(_u,{asChild:!0,container:r,children:o})})})};Du.displayName=Lr;var vt="PopoverContent",Lu=a.forwardRef((e,t)=>
56{const n=Ib(vt,e.__scopePopover),{forceMount:o=n.forceMount,...r}=e,s=Ke(vt,e.__scopePopover);return p.jsx(Or,{present:o||s.open,children:s.modal?p.jsx(Nb,{...r,ref:t}):p.jsx(Mb,{...r,ref:t})})});Lu.displayName=vt;var Nb=a.forwardRef((e,t)=>{const n=Ke(vt,e.__scopePopover),o=a.useRef(null),r=Ue(t,o),s=a.useRef(!1);return a.useEffect(()=>{const i=o.current;if(i)return Lt(i)},[]),p.jsx(xt,{as:Ir,allowPinchZoom:!0,children:p.jsx(ku,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Me(e.onCloseAutoFocus,i=>{var c;i.preventDefault(),s.current||(c=n.triggerRef.current)==null||c.focus()}),onPointerDownOutside:Me(e.onPointerDownOutside,i=>{const c=i.detail.originalEvent,l=c.button===0&&c.ctrlKey===!0,u=c.button===2||l;s.current=u},{checkForDefaultPrevented:!1}),onFocusOutside:Me(e.onFocusOutside,i=>i.preventDefault(),{checkForDefaultPrevented:!1})})})}),Mb=a.forwardRef((e,t)=>{const n=Ke(vt,e.__scopePopover),o=a.useRef(!1),r=a.useRef(!1);return p.jsx(ku,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var i,c;(i=e.onCloseAutoFocus)==null||i.call(e,s),s.defaultPrevented||(o.current||(c=n.triggerRef.current)==null||c.focus(),s.preventDefault()),o.current=!1,r.current=!1},onInteractOutside:s=>{var l,u;(l=e.onInteractOutside)==null||l.call(e,s),s.defaultPrevented||(o.current=!0,s.detail.originalEvent.type==="pointerdown"&&(r.current=!0));const i=s.target;((u=n.triggerRef.current)==null?void 0:u.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&r.current&&s.preventDefault()}})}),ku=a.forwardRef((e,t)=>{const{__scopePopover:n,trapFocus:o,onOpenAutoFocus:r,onCloseAutoFocus:s,disableOutsidePointerEvents:i,onEscapeKeyDown:c,onPointerDownOutside:l,onFocusOutside:u,onInteractOutside:f,...d}=e,v=Ke(vt,n),h=Bt(n);return Jg(),p.jsx(mu,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:r,onUnmountAutoFocus:s,children:p.jsx(pu,{asChild:!0,disableOutsidePointerEvents:i,onInteractOutside:f,onEscapeKeyDown:c,onPointerDownOutside:l,onFocusOutside:u,onDismiss:()=>v.onOpenChange(!1),children:p.jsx(wb,{"data-state":Vu(v.open),role:"dialog",id:v.contentId,...h,...d,ref:t,style:{...d.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)"}})})})}),ju="PopoverClose",Ob=a.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=Ke(ju,n);return p.jsx(_e.button,{type:"button",...o,ref:t,onClick:Me(e.onClick,()=>r.onOpenChange(!1))})});Ob.displayName=ju;var Db="PopoverArrow",Fu=a.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=Bt(n);return p.jsx(yb,{...r,...o,ref:t})});Fu.displayName=Db;function Vu(e){return e?"open":"closed"}var xy=Iu,wy=Ou,yy=Du,Cy=Lu,Ey=Fu;function no(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e==null||e(r),n===!1||!r.defaultPrevented)return t==null?void 0:t(r)}}function Lb(e,t=[]){let n=[];function o(s,i){const c=a.createContext(i),l=n.length;n=[...n,i];function u(d){const{scope:v,children:h,...g}=d,m=(v==null?void 0:v[e][l])||c,b=a.useMemo(()=>g,Object.values(g));return a.createElement(m.Provider,{value:b},h)}function f(d,v){const h=(v==null?void 0:v[e][l])||c,g=a.useContext(h);if(g)return g;if(i!==void 0)return i;throw new Error(`\`${d}\` must be used within \`${s}\``)}return u.displayName=s+"Provider",[u,f]}const r=()=>{const s=n.map(i=>a.createContext(i));return function(c){const l=(c==null?void 0:c[e])||s;return a.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return r.scopeName=e,[o,kb(r,...t)]}function kb(...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:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return a.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}function lt(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e==null||e(r),n===!1||!r.defaultPrevented)return t==null?void 0:t(r)}}
56function jb(e,t=[]){let n=[];function o(s,i){const c=a.createContext(i),l=n.length;n=[...n,i];function u(d){const{scope:v,children:h,...g}=d,m=(v==null?void 0:v[e][l])||c,b=a.useMemo(()=>g,Object.values(g));return a.createElement(m.Provider,{value:b},h)}function f(d,v){const h=(v==null?void 0:v[e][l])||c,g=a.useContext(h);if(g)return g;if(i!==void 0)return i;throw new Error(`\`${d}\` must be used within \`${s}\``)}return u.displayName=s+"Provider",[u,f]}const r=()=>{const s=n.map(i=>a.createContext(i));return function(c){const l=(c==null?void 0:c[e])||s;return a.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return r.scopeName=e,[o,Fb(r,...t)]}function Fb(...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:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return a.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}function Vb(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function Bu(...e){return t=>e.forEach(n=>Vb(n,t))}function Cs(...e){return a.useCallback(Bu(...e),e)}const To=a.forwardRef((e,t)=>{const{children:n,...o}=e,r=a.Children.toArray(n),s=r.find(Wb);if(s){const i=s.props.children,c=r.map(l=>l===s?a.Children.count(i)>1?a.Children.only(null):a.isValidElement(i)?i.props.children:null:l);return a.createElement(_o,ne({},o,{ref:t}),a.isValidElement(i)?a.cloneElement(i,void 0,c):null)}return a.createElement(_o,ne({},o,{ref:t}),n)});To.displayName="Slot";const _o=a.forwardRef((e,t)=>{const{children:n,...o}=e;return a.isValidElement(n)?a.cloneElement(n,{...Hb(o,n.props),ref:Bu(t,n.ref)}):a.Children.count(n)>1?a.Children.only(null):null});_o.displayName="SlotClone";const Bb=({children:e})=>a.createElement(a.Fragment,null,e);function Wb(e){return a.isValidElement(e)&&e.type===Bb}function Hb(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 Ub(e){const t=e+"CollectionProvider",[n,o]=jb(t),[r,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=h=>{const{scope:g,children:m}=h,b=Y.useRef(null),x=Y.useRef(new Map).current;return Y.createElement(r,{scope:g,itemMap:x,collectionRef:b},m)},c=e+"CollectionSlot",l=Y.forwardRef((h,g)=>{const{scope:m,children:b}=h,x=s(c,m),w=Cs(g,x.collectionRef);return Y.createElement(To,{ref:w},b)}),u=e+"CollectionItemSlot",f="data-radix-collection-item",d=Y.forwardRef((h,g)=>{const{scope:m,children:b,...x}=h,w=Y.useRef(null),y=Cs(g,w),C=s(u,m);return Y.useEffect(()=>(C.itemMap.set(w,{ref:w,...x}),()=>void C.itemMap.delete(w))),Y.createElement(To,{[f]:"",ref:y},b)});function v(h){const g=s(e+"CollectionConsumer",h);return Y.useCallback(()=>{const b=g.collectionRef.current;if(!b)return[];const x=Array.from(b.querySelectorAll(`[${f}]`));return Array.from(g.itemMap.values()).sort((C,E)=>x.indexOf(C.ref.current)-x.indexOf(E.ref.current))},[g.collectionRef,g.itemMap])}return[{Provider:i,Slot:l,ItemSlot:d},v,o]}function Kb(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function Wu(...e){return t=>e.forEach(n=>Kb(n,t))}function Gb(...e){return a.useCallback(Wu(...e),e)}function zb(e,t=[]){let n=[];function o(s,i){const c=a.createContext(i),l=n.length;n=[...n,i];function u(d){const{scope:v,children:h,...g}=d,m=(v==null?void 0:v[e][l])||c,b=a.useMemo(()=>g,Object.values(g));return a.createElement(m.Provider,{value:b},h)}function f(d,v){const h=(v==null?void 0:v[e][l])||c,g=a.useContext(h);if(g)return g;if(i!==void 0)return i;throw new Error(`\`${d}\` must be used within \`${s}\``)}return u.displayName=s+"Provider",[u,f]}const r=()=>{const s=n.map(i=>a.createContext(i));return function(c){const l=(c==null?void 0:c[e])||s;return a.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return r.scopeName=e,[o,Yb(r,...t)]}function Yb(...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:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return a.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}const Xb=globalThis!=null&&globalThis.document?a.useLayoutEffect:()=>{},qb=pn.useId||(()=>{});let Zb=0;function Qb(e){const[t,n]=a.useState(qb());return Xb(()=>{n(o=>o??String(Zb++))},[e]),t?`radix-${t}`:""}const Hu=a.forwardRef((e,t)=>
56{const{children:n,...o}=e,r=a.Children.toArray(n),s=r.find(ex);if(s){const i=s.props.children,c=r.map(l=>l===s?a.Children.count(i)>1?a.Children.only(null):a.isValidElement(i)?i.props.children:null:l);return a.createElement($o,ne({},o,{ref:t}),a.isValidElement(i)?a.cloneElement(i,void 0,c):null)}return a.createElement($o,ne({},o,{ref:t}),n)});Hu.displayName="Slot";const $o=a.forwardRef((e,t)=>{const{children:n,...o}=e;return a.isValidElement(n)?a.cloneElement(n,{...tx(o,n.props),ref:Wu(t,n.ref)}):a.Children.count(n)>1?a.Children.only(null):null});$o.displayName="SlotClone";const Jb=({children:e})=>a.createElement(a.Fragment,null,e);function ex(e){return a.isValidElement(e)&&e.type===Jb}function tx(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}}const nx=["a","button","div","h2","h3","img","label","li","nav","ol","p","span","svg","ul"],Uu=nx.reduce((e,t)=>{const n=a.forwardRef((o,r)=>{const{asChild:s,...i}=o,c=s?Hu:t;return a.useEffect(()=>{window[Symbol.for("radix-ui")]=!0},[]),a.createElement(c,ne({},i,{ref:r}))});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function kr(e){const t=a.useRef(e);return a.useEffect(()=>{t.current=e}),a.useMemo(()=>(...n)=>{var o;return(o=t.current)===null||o===void 0?void 0:o.call(t,...n)},[])}function ox({prop:e,defaultProp:t,onChange:n=()=>{}}){const[o,r]=rx({defaultProp:t,onChange:n}),s=e!==void 0,i=s?e:o,c=kr(n),l=a.useCallback(u=>{if(s){const d=typeof u=="function"?u(e):u;d!==e&&c(d)}else r(u)},[s,e,r,c]);return[i,l]}function rx({defaultProp:e,onChange:t}){const n=a.useState(e),[o]=n,r=a.useRef(o),s=kr(t);return a.useEffect(()=>{r.current!==o&&(s(o),r.current=o)},[o,r,s]),n}const sx=a.createContext(void 0);function Ku(e){const t=a.useContext(sx);return e||t||"ltr"}const oo="rovingFocusGroup.onEntryFocus",ax={bubbles:!1,cancelable:!0},jr="RovingFocusGroup",[Io,Gu,ix]=Ub(jr),[cx,zu]=zb(jr,[ix]),[lx,ux]=cx(jr),dx=a.forwardRef((e,t)=>a.createElement(Io.Provider,{scope:e.__scopeRovingFocusGroup},a.createElement(Io.Slot,{scope:e.__scopeRovingFocusGroup},a.createElement(fx,ne({},e,{ref:t}))))),fx=a.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:o,loop:r=!1,dir:s,currentTabStopId:i,defaultCurrentTabStopId:c,onCurrentTabStopIdChange:l,onEntryFocus:u,...f}=e,d=a.useRef(null),v=Gb(t,d),h=Ku(s),[g=null,m]=ox({prop:i,defaultProp:c,onChange:l}),[b,x]=a.useState(!1),w=kr(u),y=Gu(n),C=a.useRef(!1),[E,R]=a.useState(0);return a.useEffect(()=>{const S=d.current;if(S)return S.addEventListener(oo,w),()=>S.removeEventListener(oo,w)},[w]),a.createElement(lx,{scope:n,orientation:o,dir:h,loop:r,currentTabStopId:g,onItemFocus:a.useCallback(S=>m(S),[m]),onItemShiftTab:a.useCallback(()=>x(!0),[]),onFocusableItemAdd:a.useCallback(()=>R(S=>S+1),[]),onFocusableItemRemove:a.useCallback(()=>R(S=>S-1),[])},a.createElement(Uu.div,ne({tabIndex:b||E===0?-1:0,"data-orientation":o},f,{ref:v,style:{outline:"none",...e.style},onMouseDown:lt(e.onMouseDown,()=>{C.current=!0}),onFocus:lt(e.onFocus,S=>{const A=!C.current;if(S.target===S.currentTarget&&A&&!b){const $=new CustomEvent(oo,ax);if(S.currentTarget.dispatchEvent($),!$.defaultPrevented){const N=y().filter(L=>L.focusable),O=N.find(L=>L.active),j=N.find(L=>L.id===g),T=[O,j,...N].filter(Boolean).map(L=>L.ref.current);Yu(T)}}C.current=!1}),onBlur:lt(e.onBlur,()=>x(!1))})))}),px="RovingFocusGroupItem",vx=a.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:o=!0,active:r=!1,tabStopId:s,...i}=e,c=Qb(),l=s||c,u=ux(px,n),f=u.currentTabStopId===l,d=Gu(n),{onFocusableItemAdd:v,onFocusableItemRemove:h}=u;return a.useEffect(()=>{if(o)return v(),()=>h()},[o,v,h]),a.createElement(Io.ItemSlot,{scope:n,id:l,focusable:o,active:r},a.createElement(Uu.span,ne({tabIndex:f?0:-1,"data-orientation":u.orientation},i,{ref:t,onMouseDown:lt(e.onMouseDown,g=>{o?u.onItemFocus(l):g.preventDefault()}),onFocus:lt(e.onFocus,()=>u.onItemFocus(l)),onKeyDown:lt(e.onKeyDown,g=>{if(g.key==="Tab"&&g.shiftKey){u.onItemShiftTab();return}if(g.target!==g.currentTarget)return;const m=gx(g,u.orientation,u.dir);if(m!==void 0){g.preventDefault();let x=d().filter(w=>w.focusable).map(w=>w.ref.current);if(m==="last")x.reverse();else if(m==="prev"||m==="next"){m==="prev"&&x.reverse();const w=x.indexOf(g.currentTarget);x=u.loop?bx(x,w+1):x.slice(w+1)}setTimeout(()=>
56Yu(x))}})})))}),mx={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function hx(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function gx(e,t,n){const o=hx(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(o))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(o)))return mx[o]}function Yu(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function bx(e,t){return e.map((n,o)=>e[(t+o)%e.length])}const xx=dx,wx=vx;function yx(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function Xu(...e){return t=>e.forEach(n=>yx(n,t))}function Cx(...e){return a.useCallback(Xu(...e),e)}const No=globalThis!=null&&globalThis.document?a.useLayoutEffect:()=>{};function Ex(e,t){return a.useReducer((n,o)=>{const r=t[n][o];return r??n},e)}const qu=e=>{const{present:t,children:n}=e,o=Sx(t),r=typeof n=="function"?n({present:o.isPresent}):a.Children.only(n),s=Cx(o.ref,r.ref);return typeof n=="function"||o.isPresent?a.cloneElement(r,{ref:s}):null};qu.displayName="Presence";function Sx(e){const[t,n]=a.useState(),o=a.useRef({}),r=a.useRef(e),s=a.useRef("none"),i=e?"mounted":"unmounted",[c,l]=Ex(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return a.useEffect(()=>{const u=qt(o.current);s.current=c==="mounted"?u:"none"},[c]),No(()=>{const u=o.current,f=r.current;if(f!==e){const v=s.current,h=qt(u);e?l("MOUNT"):h==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(f&&v!==h?"ANIMATION_OUT":"UNMOUNT"),r.current=e}},[e,l]),No(()=>{if(t){const u=d=>{const h=qt(o.current).includes(d.animationName);d.target===t&&h&&Je.flushSync(()=>l("ANIMATION_END"))},f=d=>{d.target===t&&(s.current=qt(o.current))};return t.addEventListener("animationstart",f),t.addEventListener("animationcancel",u),t.addEventListener("animationend",u),()=>{t.removeEventListener("animationstart",f),t.removeEventListener("animationcancel",u),t.removeEventListener("animationend",u)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(c),ref:a.useCallback(u=>{u&&(o.current=getComputedStyle(u)),n(u)},[])}}function qt(e){return(e==null?void 0:e.animationName)||"none"}const Zu=a.forwardRef((e,t)=>{const{children:n,...o}=e,r=a.Children.toArray(n),s=r.find(Rx);if(s){const i=s.props.children,c=r.map(l=>l===s?a.Children.count(i)>1?a.Children.only(null):a.isValidElement(i)?i.props.children:null:l);return a.createElement(Mo,ne({},o,{ref:t}),a.isValidElement(i)?a.cloneElement(i,void 0,c):null)}return a.createElement(Mo,ne({},o,{ref:t}),n)});Zu.displayName="Slot";const Mo=a.forwardRef((e,t)=>{const{children:n,...o}=e;return a.isValidElement(n)?a.cloneElement(n,{...Ax(o,n.props),ref:Xu(t,n.ref)}):a.Children.count(n)>1?a.Children.only(null):null});Mo.displayName="SlotClone";const Px=({children:e})=>a.createElement(a.Fragment,null,e);function Rx(e){return a.isValidElement(e)&&e.type===Px}function Ax(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}}const Tx=["a","button","div","h2","h3","img","label","li","nav","ol","p","span","svg","ul"],Vn=Tx.reduce((e,t)=>{const n=a.forwardRef((o,r)=>{const{asChild:s,...i}=o,c=s?Zu:t;return a.useEffect(()=>{window[Symbol.for("radix-ui")]=!0},[]),a.createElement(c,ne({},i,{ref:r}))});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function Qu(e){const t=a.useRef(e);return a.useEffect(()=>{t.current=e}),a.useMemo(()=>(...n)=>{var o;return(o=t.current)===null||o===void 0?void 0:o.call(t,...n)},[])}function _x({prop:e,defaultProp:t,onChange:n=()=>{}}){const[o,r]=$x({defaultProp:t,onChange:n}),s=e!==void 0,i=s?e:o,c=Qu(n),l=a.useCallback(u=>{if(s){const d=typeof u=="function"?u(e):u;d!==e&&c(d)}else r(u)},[s,e,r,c]);return[i,l]}function $x({defaultProp:e,onChange:t}){const n=a.useState(e),[o]=n,r=a.useRef(o),s=Qu(t);return a.useEffect(()=>{r.current!==o&&(s(o),r.current=o)},[o,r,s]),n}const Ix=pn.useId||(()=>{});let Nx=0;function Mx(e){const[t,n]=a.useState(Ix());return No(()=>{n(o=>o??String(Nx++))},[e]),e||(t?`radix-${t}`:"")}const Ju="Tabs",[Ox]=Lb(Ju,[zu]),ed=zu(),[Dx,Fr]=Ox(Ju),Lx=a.forwardRef((e,t)=>
56{const{__scopeTabs:n,value:o,onValueChange:r,defaultValue:s,orientation:i="horizontal",dir:c,activationMode:l="automatic",...u}=e,f=Ku(c),[d,v]=_x({prop:o,onChange:r,defaultProp:s});return a.createElement(Dx,{scope:n,baseId:Mx(),value:d,onValueChange:v,orientation:i,dir:f,activationMode:l},a.createElement(Vn.div,ne({dir:f,"data-orientation":i},u,{ref:t})))}),kx="TabsList",jx=a.forwardRef((e,t)=>{const{__scopeTabs:n,loop:o=!0,...r}=e,s=Fr(kx,n),i=ed(n);return a.createElement(xx,ne({asChild:!0},i,{orientation:s.orientation,dir:s.dir,loop:o}),a.createElement(Vn.div,ne({role:"tablist","aria-orientation":s.orientation},r,{ref:t})))}),Fx="TabsTrigger",Vx=a.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,disabled:r=!1,...s}=e,i=Fr(Fx,n),c=ed(n),l=td(i.baseId,o),u=nd(i.baseId,o),f=o===i.value;return a.createElement(wx,ne({asChild:!0},c,{focusable:!r,active:f}),a.createElement(Vn.button,ne({type:"button",role:"tab","aria-selected":f,"aria-controls":u,"data-state":f?"active":"inactive","data-disabled":r?"":void 0,disabled:r,id:l},s,{ref:t,onMouseDown:no(e.onMouseDown,d=>{!r&&d.button===0&&d.ctrlKey===!1?i.onValueChange(o):d.preventDefault()}),onKeyDown:no(e.onKeyDown,d=>{[" ","Enter"].includes(d.key)&&i.onValueChange(o)}),onFocus:no(e.onFocus,()=>{const d=i.activationMode!=="manual";!f&&!r&&d&&i.onValueChange(o)})})))}),Bx="TabsContent",Wx=a.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,forceMount:r,children:s,...i}=e,c=Fr(Bx,n),l=td(c.baseId,o),u=nd(c.baseId,o),f=o===c.value,d=a.useRef(f);return a.useEffect(()=>{const v=requestAnimationFrame(()=>d.current=!1);return()=>cancelAnimationFrame(v)},[]),a.createElement(qu,{present:r||f},({present:v})=>a.createElement(Vn.div,ne({"data-state":f?"active":"inactive","data-orientation":c.orientation,role:"tabpanel","aria-labelledby":l,hidden:!v,id:u,tabIndex:0},i,{ref:t,style:{...e.style,animationDuration:d.current?"0s":void 0}}),v&&s))});function td(e,t){return`${e}-trigger-${t}`}function nd(e,t){return`${e}-content-${t}`}const Sy=Lx,Py=jx,Ry=Vx,Ay=Wx;export{my as $,Gw as A,ny as B,Dw as C,hv as D,ry as E,ay as F,sy as G,cy as H,$w as I,ly as J,Rw as K,oy as L,Aw as M,Tw as N,pv as O,Ow as P,nh as Q,Nw as R,iy as S,Mw as T,ch as U,Qw as V,uy as W,dy as X,fy as Y,py as Z,vy as _,_w as a,hy as a0,gy as a1,ce as a2,I as a3,vn as a4,by as a5,Ux as a6,Gx as a7,zx as a8,qx as a9,Ew as aA,Sw as aB,Pw as aC,yw as aD,xy as aE,wy as aF,Cy as aG,Ey as aH,yy as aI,Ay as aJ,Sy as aK,Ry as aL,Py as aM,Zx as aa,Yx as ab,Xx as ac,Kx as ad,nw as ae,ew as af,tw as ag,Jx as ah,ow as ai,rw as aj,sw as ak,aw as al,iw as am,xw as an,ww as ao,dw as ap,fw as aq,vw as ar,mw as as,gw as at,hw as au,pw as av,bw as aw,lw as ax,uw as ay,Cw as az,Iw as b,Lw as c,kw as d,uv as e,dv as f,fv as g,vv as h,ei as i,mv as j,jw as k,Fw as l,Vw as m,Bw as n,Ww as o,Hw as p,Kw as q,Yw as r,Xw as s,zw as t,Uw as u,qw as v,Zw as w,Jw as x,ey as y,ty as z}; 57//# sourceMappingURL=vendor-radix-Cn4zZLa9.js.map
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.