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