PageSourceSearch

https://www.emoodie.com/assets/vendor-radix-C0AOI2Ya.js

js emoodie.com collected 2026-10-04 11:32:09 UTC 52,999 bytes, 5 lines download raw bytes

vendor: 9,708 bytes, line 1
1import{r as i,j as d,R as z,a as tt,v as On,b as nt,u as Mn,o as Ln,s as Fn,f as kn,c as jn,d as $n,h as Kn,l as Bn,e as Hn,g as Vn,i as Wn}from"./vendor-HpIqlb1N.js";function R(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),n===!1||!r.defaultPrevented)return t?.(r)}}function Ue(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function ot(...e){return t=>{let n=!1;const o=e.map(r=>{const s=Ue(r,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let r=0;r<o.length;r++){const s=o[r];typeof s=="function"?s():Ue(e[r],null)}}}}function _(...e){return i.useCallback(ot(...e),e)}function Un(e,t){const n=i.createContext(t),o=s=>{const{children:a,...c}=s,u=i.useMemo(()=>c,Object.values(c));return d.jsx(n.Provider,{value:u,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 G(e,t=[]){let n=[];function o(s,a){const c=i.createContext(a),u=n.length;n=[...n,a];const l=f=>{const{scope:h,children:x,...b}=f,m=h?.[e]?.[u]||c,v=i.useMemo(()=>b,Object.values(b));return d.jsx(m.Provider,{value:v,children:x})};l.displayName=s+"Provider";function p(f,h){const x=h?.[e]?.[u]||c,b=i.useContext(x);if(b)return b;if(a!==void 0)return a;throw new Error(`\`${f}\` must be used within \`${s}\``)}return[l,p]}const r=()=>{const s=n.map(a=>i.createContext(a));return function(c){const u=c?.[e]||s;return i.useMemo(()=>({[`__scope${e}`]:{...c,[e]:u}}),[c,u])}};return r.scopeName=e,[o,zn(r,...t)]}function zn(...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:u,scopeName:l})=>{const f=u(s)[`__scope${l}`];return{...c,...f}},{});return i.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function te(e){const t=Yn(e),n=i.forwardRef((o,r)=>{const{children:s,...a}=o,c=i.Children.toArray(s),u=c.find(Xn);if(u){const l=u.props.children,p=c.map(f=>f===u?i.Children.count(l)>1?i.Children.only(null):i.isValidElement(l)?l.props.children:null:f);return d.jsx(t,{...a,ref:r,children:i.isValidElement(l)?i.cloneElement(l,void 0,p):null})}return d.jsx(t,{...a,ref:r,children:s})});return n.displayName=`${e}.Slot`,n}var es=te("Slot");function Yn(e){const t=i.forwardRef((n,o)=>{const{children:r,...s}=n;if(i.isValidElement(r)){const a=Zn(r),c=qn(s,r.props);return r.type!==i.Fragment&&(c.ref=o?ot(o,a):a),i.cloneElement(r,c)}return i.Children.count(r)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var rt=Symbol("radix.slottable");function Gn(e){const t=({children:n})=>d.jsx(d.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=rt,t}function Xn(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===rt}function qn(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)=>{const u=s(...c);return r(...c),u}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...e,...n}}function Zn(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function st(e){const t=e+"CollectionProvider",[n,o]=G(t),[r,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),a=m=>{const{scope:v,children:g}=m,y=z.useRef(null),E=z.useRef(new Map).current;return d.jsx(r,{scope:v,itemMap:E,collectionRef:y,children:g})};a.displayName=t;const c=e+"CollectionSlot",u=te(c),l=z.forwardRef((m,v)=>{const{scope:g,children:y}=m,E=s(c,g),w=_(v,E.collectionRef);return d.jsx(u,{ref:w,children:y})});l.displayName=c;const p=e+"CollectionItemSlot",f="data-radix-collection-item",h=te(p),x=z.forwardRef((m,v)=>{const{scope:g,children:y,...E}=m,w=z.useRef(null),T=_(v,w),S=s(p,g);return z.useEffect(()=>(S.itemMap.set(w,{ref:w,...E}),()=>{S.itemMap.delete(w)})),d.jsx(h,{[f]:"",ref:T,children:y})});x.displayName=p;function b(m){const v=s(e+"CollectionConsumer",m);return z.useCallback(()=>{const y=v.collectionRef.current;if(!y)return[];const E=Array.from(y.querySelectorAll(`[${f}]`));return Array.from(v.itemMap.values()).sort((S,P)=>E.indexOf(S.ref.current)-E.indexOf(P.ref.current))},[v.collectionRef,v.itemMap])}return[{Provider:a,Slot:l,ItemSlot:x},b,o]}var Jn=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],D=Jn.reduce((e,t)=>{const n=te(`Primitive.${t}`),o=i.forwardRef((r,s)=>{const{asChild:a,...c}=r,u=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),d.jsx(u,{...c,ref:s})});return o.displayName=`Primitive.${t}`,{...e,[t]:o}},{});function it(e,t){e&&tt.flushSync(()=>e.dispatchEvent(t))}function H(e){const t=i.useRef(e);return i.useEffect(()=>{t.current=e}),i.useMemo(()=>(...n)=>t.current?.(...n),[])}function Qn(e,t=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 eo="DismissableLayer",Pe="dismissableLayer.update",to="dismissableLayer.pointerDownOutside",no="dismissableLayer.focusOutside",ze,at=i.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),le=i.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:o,onPointerDownOutside:r,onFocusOutside:s,onInteractOutside:a,onDismiss:c,...u}=e,l=i.useContext(at),[p,f]=i.useState(null),h=p?.ownerDocument??globalThis?.document,[,x]=i.useState({}),b=_(t,P=>f(P)),m=Array.from(l.layers),[v]=[...l.layersWithOutsidePointerEventsDisabled].slice(-1),g=m.indexOf(v),y=p?m.indexOf(p):-1,E=l.layersWithOutsidePointerEventsDisabled.size>0,w=y>=g,T=ro(P=>{const F=P.target,j=[...l.branches].some(O=>O.contains(F));!w||j||(r?.(P),a?.(P),P.defaultPrevented||c?.())},h),S=so(P=>{const F=P.target;[...l.branches].some(O=>O.contains(F))||(s?.(P),a?.(P),P.defaultPrevented||c?.())},h);return Qn(P=>{y===l.layers.size-1&&(o?.(P),!P.defaultPrevented&&c&&(P.preventDefault(),c()))},h),i.useEffect(()=>{if(p)return n&&(l.layersWithOutsidePointerEventsDisabled.size===0&&(ze=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),l.layersWithOutsidePointerEventsDisabled.add(p)),l.layers.add(p),Ye(),()=>{n&&l.layersWithOutsidePointerEventsDisabled.size===1&&(h.body.style.pointerEvents=ze)}},[p,h,n,l]),i.useEffect(()=>()=>{p&&(l.layers.delete(p),l.layersWithOutsidePointerEventsDisabled.delete(p),Ye())},[p,l]),i.useEffect(()=>{const P=()=>x({});return document.addEventListener(Pe,P),()=>document.removeEventListener(Pe,P)},[]),d.jsx(D.div,{...u,ref:b,style:{pointerEvents:E?w?"auto":"none":void 0,...e.style},onFocusCapture:R(e.onFocusCapture,S.onFocusCapture),onBlurCapture:R(e.onBlurCapture,S.onBlurCapture),onPointerDownCapture:R(e.onPointerDownCapture,T.onPointerDownCapture)})});le.displayName=eo;var oo="DismissableLayerBranch",ct=i.forwardRef((e,t)=>{const n=i.useContext(at),o=i.useRef(null),r=_(t,o);return i.useEffect(()=>{const s=o.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),d.jsx(D.div,{...e,ref:r})});ct.displayName=oo;function ro(e,t=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 u=function(){lt(to,n,l,{discrete:!0})};const l={originalEvent:c};c.pointerType==="touch"?(t.removeEventListener("click",r.current),r.current=u,t.addEventListener("click",r.current,{once:!0})):u()}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 so(e,t=globalThis?.document){const n=H(e),o=i.useRef(!1);return i.useEffect(()=>{const r=s=>{s.target&&!o.current&&lt(no,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 Ye(){const e=new CustomEvent(Pe);document.dispatchEvent(e)}function lt(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?it(r,s):r.dispatchEvent(s)}var io=le,ao=ct,V=globalThis?.document?i.useLayoutEffect:()=>{},co="Portal",Ie=i.forwardRef((e,t)=>{const{container:n,...o}=e,[r,s]=i.useState(!1);V(()=>s(!0),[]);const a=n||r&&globalThis?.document?.body;return a?On.createPortal(d.jsx(D.div,{...o,ref:t}),a):null});Ie.displayName=co;function lo(e,t){return i.useReducer((n,o)=>t[n][o]??n,e)}var X=e=>{const{present:t,children:n}=e,o=uo(t),r=typeof n=="function"?n({present:o.isPresent}):i.Children.only(n),s=_(o.ref,fo(r));return typeof n=="function"||o.isPresent?i.cloneElement(r,{ref:s}):null};X.displayName="Presence";function uo(e){const[t,n]=i.useState(),o=i.useRef(null),r=i.useRef(e),s=i.useRef("none"),a=e?"mounted":"unmounted",[c,u]=lo(a,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return i.useEffect(()=>{const l=ie(o.current);s.current=c==="mounted"?l:"none"},[c]),V(()=>{const l=o.current,p=r.current;if(p!==e){const h=s.current,x=ie(l);e?u("MOUNT"):x==="none"||l?.display==="none"?u("UNMOUNT"):u(p&&h!==x?"ANIMATION_OUT":"UNMOUNT"),r.current=e}},[e,u]),V(()=>
1{if(t){let l;const p=t.ownerDocument.defaultView??window,f=x=>{const m=ie(o.current).includes(x.animationName);if(x.target===t&&m&&(u("ANIMATION_END"),!r.current)){const v=t.style.animationFillMode;t.style.animationFillMode="forwards",l=p.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=v)})}},h=x=>{x.target===t&&(s.current=ie(o.current))};return t.addEventListener("animationstart",h),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{p.clearTimeout(l),t.removeEventListener("animationstart",h),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else u("ANIMATION_END")},[t,u]),{isPresent:["mounted","unmountSuspended"].includes(c),ref:i.useCallback(l=>{o.current=l?getComputedStyle(l):null,n(l)},[])}}function ie(e){return e?.animationName||"none"}function fo(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var po=nt[" useInsertionEffect ".trim().toString()]||V;function ue({prop:e,defaultProp:t,onChange:n=()=>{},caller:o}){const[r,s,a]=mo({defaultProp:t,onChange:n}),c=e!==void 0,u=c?e:r;{const p=i.useRef(e!==void 0);i.useEffect(()=>{const f=p.current;f!==c&&console.warn(`${o} is changing from ${f?"controlled":"uncontrolled"} to ${c?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),p.current=c},[c,o])}const l=i.useCallback(p=>{if(c){const f=vo(p)?p(e):p;f!==e&&a.current?.(f)}else s(p)},[c,e,s,a]);return[u,l]}function mo({defaultProp:e,onChange:t}){const[n,o]=i.useState(e),r=i.useRef(n),s=i.useRef(t);return po(()=>{s.current=t},[t]),i.useEffect(()=>{r.current!==n&&(s.current?.(n),r.current=n)},[n,r]),[n,o,s]}function vo(e){return typeof e=="function"}var ho=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),go="VisuallyHidden",de=i.forwardRef((e,t)=>d.jsx(D.span,{...e,ref:t,style:{...ho,...e.style}}));de.displayName=go;var xo=de,Oe="ToastProvider",[Me,yo,Eo]=st("Toast"),[ut]=G("Toast",[Eo]),[wo,fe]=ut(Oe),dt=e=>{const{__scopeToast:t,label:n="Notification",duration:o=5e3,swipeDirection:r="right",swipeThreshold:s=50,children:a}=e,[c,u]=i.useState(null),[l,p]=i.useState(0),f=i.useRef(!1),h=i.useRef(!1);return n.trim()||console.error(`Invalid prop \`label\` supplied to \`${Oe}\`. Expected non-empty \`string\`.`),d.jsx(Me.Provider,{scope:t,children:d.jsx(wo,{scope:t,label:n,duration:o,swipeDirection:r,swipeThreshold:s,toastCount:l,viewport:c,onViewportChange:u,onToastAdd:i.useCallback(()=>p(x=>x+1),[]),onToastRemove:i.useCallback(()=>p(x=>x-1),[]),isFocusedToastEscapeKeyDownRef:f,isClosePausedRef:h,children:a})})};dt.displayName=Oe;var ft="ToastViewport",bo=["F8"],Te="toast.viewportPause",Re="toast.viewportResume",pt=i.forwardRef((e,t)=>{const{__scopeToast:n,hotkey:o=bo,label:r="Notifications ({hotkey})",...s}=e,a=fe(ft,n),c=yo(n),u=i.useRef(null),l=i.useRef(null),p=i.useRef(null),f=i.useRef(null),h=_(t,f,a.onViewportChange),x=o.join("+").replace(/Key/g,"").replace(/Digit/g,""),b=a.toastCount>0;i.useEffect(()=>{const v=g=>{o.length!==0&&o.every(E=>g[E]||g.code===E)&&f.current?.focus()};return document.addEventListener("keydown",v),()=>document.removeEventListener("keydown",v)},[o]),i.useEffect(()=>{const v=u.current,g=f.current;if(b&&v&&g){const y=()=>{if(!a.isClosePausedRef.current){const S=new CustomEvent(Te);g.dispatchEvent(S),a.isClosePausedRef.current=!0}},E=()=>{if(a.isClosePausedRef.current){const S=new CustomEvent(Re);g.dispatchEvent(S),a.isClosePausedRef.current=!1}},w=S=>{!v.contains(S.relatedTarget)&&E()},T=()=>{v.contains(document.activeElement)||E()};return v.addEventListener("focusin",y),v.addEventListener("focusout",w),v.addEventListener("pointermove",y),v.addEventListener("pointerleave",T),window.addEventListener("blur",y),window.addEventListener("focus",E),()=>{v.removeEventListener("focusin",y),v.removeEventListener("focusout",w),v.removeEventListener("pointermove",y),v.removeEventListener("pointerleave",T),window.removeEventListener("blur",y),window.removeEventListener("focus",E)}}},[b,a.isClosePausedRef]);const m=i.useCallback(({tabbingDirection:v})=>{const y=c().map(E=>{const w=E.ref.current,T=[w,...Lo(w)];return v==="forwards"?T:T.reverse()});return(v==="forwards"?y.reverse():y).flat()},[c]);return i.useEffect(()=>{const v=f.current;if(v){const g=y=>{const E=y.altKey||y.ctrlKey||y.metaKey;if(y.key==="Tab"&&!E){const T=document.activeElement,S=y.shiftKey;if(y.target===v&&S){l.current?.focus();return}const j=m({tabbingDirection:S?"backwards":"forwards"}),O=j.findIndex(A=>A===T);ye(j.slice(O+1))?y.preventDefault():S?l.current?.focus():p.current?.focus()}};return v.addEventListener("keydown",g),()=>v.removeEventListener("keydown",g)}},[c,m]),d.jsxs(ao,{ref:u,role:"region","aria-label":r.replace("{hotkey}",x),tabIndex:-1,style:{pointerEvents:b?void 0:"none"},children:[b&&d.jsx(Se,{ref:l,onFocusFromOutsideViewport:()=>{const v=m({tabbingDirection:"forwards"});ye(v)}}),d.jsx(Me.Slot,{scope:n,children:d.jsx(D.ol,{tabIndex:-1,...s,ref:h})}),b&&d.jsx(Se,{ref:p,onFocusFromOutsideViewport:()=>{const v=m({tabbingDirection:"backwards"});ye(v)}})]})});pt.displayName=ft;var mt="ToastFocusProxy",Se=i.forwardRef((e,t)=>
vendor: 9,231 bytes, line 1
1{const{__scopeToast:n,onFocusFromOutsideViewport:o,...r}=e,s=fe(mt,n);return d.jsx(de,{"aria-hidden":!0,tabIndex:0,...r,ref:t,style:{position:"fixed"},onFocus:a=>{const c=a.relatedTarget;!s.viewport?.contains(c)&&o()}})});Se.displayName=mt;var ne="Toast",Co="toast.swipeStart",Po="toast.swipeMove",To="toast.swipeCancel",Ro="toast.swipeEnd",vt=i.forwardRef((e,t)=>{const{forceMount:n,open:o,defaultOpen:r,onOpenChange:s,...a}=e,[c,u]=ue({prop:o,defaultProp:r??!0,onChange:s,caller:ne});return d.jsx(X,{present:n||c,children:d.jsx(Ao,{open:c,...a,ref:t,onClose:()=>u(!1),onPause:H(e.onPause),onResume:H(e.onResume),onSwipeStart:R(e.onSwipeStart,l=>{l.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:R(e.onSwipeMove,l=>{const{x:p,y:f}=l.detail.delta;l.currentTarget.setAttribute("data-swipe","move"),l.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${p}px`),l.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${f}px`)}),onSwipeCancel:R(e.onSwipeCancel,l=>{l.currentTarget.setAttribute("data-swipe","cancel"),l.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),l.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),l.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),l.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:R(e.onSwipeEnd,l=>{const{x:p,y:f}=l.detail.delta;l.currentTarget.setAttribute("data-swipe","end"),l.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),l.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),l.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${p}px`),l.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${f}px`),u(!1)})})})});vt.displayName=ne;var[So,Do]=ut(ne,{onClose(){}}),Ao=i.forwardRef((e,t)=>{const{__scopeToast:n,type:o="foreground",duration:r,open:s,onClose:a,onEscapeKeyDown:c,onPause:u,onResume:l,onSwipeStart:p,onSwipeMove:f,onSwipeCancel:h,onSwipeEnd:x,...b}=e,m=fe(ne,n),[v,g]=i.useState(null),y=_(t,C=>g(C)),E=i.useRef(null),w=i.useRef(null),T=r||m.duration,S=i.useRef(0),P=i.useRef(T),F=i.useRef(0),{onToastAdd:j,onToastRemove:O}=m,A=H(()=>{v?.contains(document.activeElement)&&m.viewport?.focus(),a()}),k=i.useCallback(C=>{!C||C===1/0||(window.clearTimeout(F.current),S.current=new Date().getTime(),F.current=window.setTimeout(A,C))},[A]);i.useEffect(()=>{const C=m.viewport;if(C){const M=()=>{k(P.current),l?.()},L=()=>{const I=new Date().getTime()-S.current;P.current=P.current-I,window.clearTimeout(F.current),u?.()};return C.addEventListener(Te,L),C.addEventListener(Re,M),()=>{C.removeEventListener(Te,L),C.removeEventListener(Re,M)}}},[m.viewport,T,u,l,k]),i.useEffect(()=>{s&&!m.isClosePausedRef.current&&k(T)},[s,T,m.isClosePausedRef,k]),i.useEffect(()=>(j(),()=>O()),[j,O]);const $=i.useMemo(()=>v?bt(v):null,[v]);return m.viewport?d.jsxs(d.Fragment,{children:[$&&d.jsx(_o,{__scopeToast:n,role:"status","aria-live":o==="foreground"?"assertive":"polite","aria-atomic":!0,children:$}),d.jsx(So,{scope:n,onClose:A,children:tt.createPortal(d.jsx(Me.ItemSlot,{scope:n,children:d.jsx(io,{asChild:!0,onEscapeKeyDown:R(c,()=>{m.isFocusedToastEscapeKeyDownRef.current||A(),m.isFocusedToastEscapeKeyDownRef.current=!1}),children:d.jsx(D.li,{role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":s?"open":"closed","data-swipe-direction":m.swipeDirection,...b,ref:y,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:R(e.onKeyDown,C=>{C.key==="Escape"&&(c?.(C.nativeEvent),C.nativeEvent.defaultPrevented||(m.isFocusedToastEscapeKeyDownRef.current=!0,A()))}),onPointerDown:R(e.onPointerDown,C=>{C.button===0&&(E.current={x:C.clientX,y:C.clientY})}),onPointerMove:R(e.onPointerMove,C=>{if(!E.current)return;const M=C.clientX-E.current.x,L=C.clientY-E.current.y,I=!!w.current,N=["left","right"].includes(m.swipeDirection),B=["left","up"].includes(m.swipeDirection)?Math.min:Math.max,xe=N?B(0,M):0,oe=N?0:B(0,L),Q=C.pointerType==="touch"?10:2,q={x:xe,y:oe},re={originalEvent:C,delta:q};I?(w.current=q,ae(Po,f,re,{discrete:!1})):Ge(q,m.swipeDirection,Q)?(w.current=q,ae(Co,p,re,{discrete:!1}),C.target.setPointerCapture(C.pointerId)):(Math.abs(M)>Q||Math.abs(L)>Q)&&(E.current=null)}),onPointerUp:R(e.onPointerUp,C=>{const M=w.current,L=C.target;if(L.hasPointerCapture(C.pointerId)&&L.releasePointerCapture(C.pointerId),w.current=null,E.current=null,M){const I=C.currentTarget,N={originalEvent:C,delta:M};Ge(M,m.swipeDirection,m.swipeThreshold)?ae(Ro,x,N,{discrete:!0}):ae(To,h,N,{discrete:!0}),I.addEventListener("click",B=>B.preventDefault(),{once:!0})}})})})}),m.viewport)})]}):null}),_o=e=>{const{__scopeToast:t,children:n,...o}=e,r=fe(ne,t),[s,a]=i.useState(!1),[c,u]=i.useState(!1);return Oo(()=>a(!0)),i.useEffect(()=>{const l=window.setTimeout(()=>u(!0),1e3);return()=>window.clearTimeout(l)},[]),c?null:d.jsx(Ie,{asChild:!0,children:d.jsx(de,{...o,children:s&&d.jsxs(d.Fragment,{children:[r.label," ",n]})})})},No="ToastTitle",ht=i.forwardRef((e,t)=>{const{__scopeToast:n,...o}=e;return d.jsx(D.div,{...o,ref:t})});ht.displayName=No;var Io="ToastDescription",gt=i.forwardRef((e,t)=>{const{__scopeToast:n,...o}=e;return d.jsx(D.div,{...o,ref:t})});gt.displayName=Io;var xt="ToastAction",yt=i.forwardRef((e,t)=>{const{altText:n,...o}=e;return n.trim()?d.jsx(wt,{altText:n,asChild:!0,children:d.jsx(Le,{...o,ref:t})}):(console.error(`Invalid prop \`altText\` supplied to \`${xt}\`. Expected non-empty \`string\`.`),null)});yt.displayName=xt;var Et="ToastClose",Le=i.forwardRef((e,t)=>{const{__scopeToast:n,...o}=e,r=Do(Et,n);return d.jsx(wt,{asChild:!0,children:d.jsx(D.button,{type:"button",...o,ref:t,onClick:R(e.onClick,r.onClose)})})});Le.displayName=Et;var wt=i.forwardRef((e,t)=>{const{__scopeToast:n,altText:o,...r}=e;return d.jsx(D.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":o||void 0,...r,ref:t})});function bt(e){const t=[];return Array.from(e.childNodes).forEach(o=>{if(o.nodeType===o.TEXT_NODE&&o.textContent&&t.push(o.textContent),Mo(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(...bt(o))}}),t}function ae(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?it(r,s):r.dispatchEvent(s)}var Ge=(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 Oo(e=()=>{}){const t=H(e);V(()=>{let n=0,o=0;return n=window.requestAnimationFrame(()=>o=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(n),window.cancelAnimationFrame(o)}},[t])}function Mo(e){return e.nodeType===e.ELEMENT_NODE}function Lo(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 ye(e){const t=document.activeElement;return e.some(n=>n===t?!0:(n.focus(),document.activeElement!==t))}var ts=dt,ns=pt,os=vt,rs=ht,ss=gt,is=yt,as=Le,Fo=nt[" useId ".trim().toString()]||(()=>{}),ko=0;function Ee(e){const[t,n]=i.useState(Fo());return V(()=>{n(o=>o??String(ko++))},[e]),e||(t?`radix-${t}`:"")}var jo="Arrow",Ct=i.forwardRef((e,t)=>{const{children:n,width:o=10,height:r=5,...s}=e;return d.jsx(D.svg,{...s,ref:t,width:o,height:r,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:d.jsx("polygon",{points:"0,0 30,0 15,10"})})});Ct.displayName=jo;var $o=Ct;function Fe(e){const[t,n]=i.useState(void 0);return V(()=>{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 u=s.borderBoxSize,l=Array.isArray(u)?u[0]:u;a=l.inlineSize,c=l.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 Pt="Popper",[Tt,Rt]=G(Pt),[cs,St]=Tt(Pt),Dt="PopperAnchor",At=i.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:o,...r}=e,s=St(Dt,n),a=i.useRef(null),c=_(t,a);return i.useEffect(()=>{s.onAnchorChange(o?.current||a.current)}),o?null:d.jsx(D.div,{...r,ref:c})});At.displayName=Dt;var ke="PopperContent",[Ko,Bo]=Tt(ke),_t=i.forwardRef((e,t)=>{const{__scopePopper:n,side:o="bottom",sideOffset:r=0,align:s="center",alignOffset:a=0,arrowPadding:c=0,avoidCollisions:u=!0,collisionBoundary:l=[],collisionPadding:p=0,sticky:f="partial",hideWhenDetached:h=!1,updatePositionStrategy:x="optimized",onPlaced:b,...m}=e,v=St(ke,n),[g,y]=i.useState(null),E=_(t,ee=>y(ee)),[w,T]=i.useState(null),S=Fe(w),P=S?.width??0,F=S?.height??0,j=o+(s!=="center"?"-"+s:""),O=typeof p=="number"?p:{top:0,right:0,bottom:0,left:0,...p},A=Array.isArray(l)?l:[l],k=A.length>0,$={padding:O,boundary:A.filter(Vo),altBoundary:k},{refs:C,floatingStyles:M,placement:L,isPositioned:I,middlewareData:N}=Mn({strategy:"fixed",placement:j,whileElementsMounted:(...ee)=>Hn(...ee,{animationFrame:x==="always"}),elements:{reference:v.anchor}
vendor: 4,391 bytes, line 1
1,middleware:[Ln({mainAxis:r+F,alignmentAxis:a}),u&&Fn({mainAxis:!0,crossAxis:!1,limiter:f==="partial"?Bn():void 0,...$}),u&&kn({...$}),jn({...$,apply:({elements:ee,rects:We,availableWidth:An,availableHeight:_n})=>{const{width:Nn,height:In}=We.reference,se=ee.floating.style;se.setProperty("--radix-popper-available-width",`${An}px`),se.setProperty("--radix-popper-available-height",`${_n}px`),se.setProperty("--radix-popper-anchor-width",`${Nn}px`),se.setProperty("--radix-popper-anchor-height",`${In}px`)}}),w&&$n({element:w,padding:c}),Wo({arrowWidth:P,arrowHeight:F}),h&&Kn({strategy:"referenceHidden",...$})]}),[B,xe]=Ot(L),oe=H(b);V(()=>{I&&oe?.()},[I,oe]);const Q=N.arrow?.x,q=N.arrow?.y,re=N.arrow?.centerOffset!==0,[Sn,Dn]=i.useState();return V(()=>{g&&Dn(window.getComputedStyle(g).zIndex)},[g]),d.jsx("div",{ref:C.setFloating,"data-radix-popper-content-wrapper":"",style:{...M,transform:I?M.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Sn,"--radix-popper-transform-origin":[N.transformOrigin?.x,N.transformOrigin?.y].join(" "),...N.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:d.jsx(Ko,{scope:n,placedSide:B,onArrowChange:T,arrowX:Q,arrowY:q,shouldHideArrow:re,children:d.jsx(D.div,{"data-side":B,"data-align":xe,...m,ref:E,style:{...m.style,animation:I?void 0:"none"}})})})});_t.displayName=ke;var Nt="PopperArrow",Ho={top:"bottom",right:"left",bottom:"top",left:"right"},It=i.forwardRef(function(t,n){const{__scopePopper:o,...r}=t,s=Bo(Nt,o),a=Ho[s.placedSide];return d.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:d.jsx($o,{...r,ref:n,style:{...r.style,display:"block"}})})});It.displayName=Nt;function Vo(e){return e!==null}var Wo=e=>({name:"transformOrigin",options:e,fn(t){const{placement:n,rects:o,middlewareData:r}=t,a=r.arrow?.centerOffset!==0,c=a?0:e.arrowWidth,u=a?0:e.arrowHeight,[l,p]=Ot(n),f={start:"0%",center:"50%",end:"100%"}[p],h=(r.arrow?.x??0)+c/2,x=(r.arrow?.y??0)+u/2;let b="",m="";return l==="bottom"?(b=a?f:`${h}px`,m=`${-u}px`):l==="top"?(b=a?f:`${h}px`,m=`${o.floating.height+u}px`):l==="right"?(b=`${-u}px`,m=a?f:`${x}px`):l==="left"&&(b=`${o.floating.width+u}px`,m=a?f:`${x}px`),{data:{x:b,y:m}}}});function Ot(e){const[t,n="center"]=e.split("-");return[t,n]}var Uo=At,zo=_t,Yo=It,[pe]=G("Tooltip",[Rt]),je=Rt(),Mt="TooltipProvider",Go=700,Xe="tooltip.open",[Xo,Lt]=pe(Mt),Ft=e=>{const{__scopeTooltip:t,delayDuration:n=Go,skipDelayDuration:o=300,disableHoverableContent:r=!1,children:s}=e,a=i.useRef(!0),c=i.useRef(!1),u=i.useRef(0);return i.useEffect(()=>{const l=u.current;return()=>window.clearTimeout(l)},[]),d.jsx(Xo,{scope:t,isOpenDelayedRef:a,delayDuration:n,onOpen:i.useCallback(()=>{window.clearTimeout(u.current),a.current=!1},[]),onClose:i.useCallback(()=>{window.clearTimeout(u.current),u.current=window.setTimeout(()=>a.current=!0,o)},[o]),isPointerInTransitRef:c,onPointerInTransitChange:i.useCallback(l=>{c.current=l},[]),disableHoverableContent:r,children:s})};Ft.displayName=Mt;var kt="Tooltip",[ls,me]=pe(kt),De="TooltipTrigger",qo=i.forwardRef((e,t)=>{const{__scopeTooltip:n,...o}=e,r=me(De,n),s=Lt(De,n),a=je(n),c=i.useRef(null),u=_(t,c,r.onTriggerChange),l=i.useRef(!1),p=i.useRef(!1),f=i.useCallback(()=>l.current=!1,[]);return i.useEffect(()=>()=>document.removeEventListener("pointerup",f),[f]),d.jsx(Uo,{asChild:!0,...a,children:d.jsx(D.button,{"aria-describedby":r.open?r.contentId:void 0,"data-state":r.stateAttribute,...o,ref:u,onPointerMove:R(e.onPointerMove,h=>{h.pointerType!=="touch"&&!p.current&&!s.isPointerInTransitRef.current&&(r.onTriggerEnter(),p.current=!0)}),onPointerLeave:R(e.onPointerLeave,()=>{r.onTriggerLeave(),p.current=!1}),onPointerDown:R(e.onPointerDown,()=>{r.open&&r.onClose(),l.current=!0,document.addEventListener("pointerup",f,{once:!0})}),onFocus:R(e.onFocus,()=>{l.current||r.onOpen()}),onBlur:R(e.onBlur,r.onClose),onClick:R(e.onClick,r.onClose)})})});qo.displayName=De;var Zo="TooltipPortal",[us,Jo]=pe(Zo,{forceMount:void 0}),Z="TooltipContent",jt=i.forwardRef((e,t)=>
vendor: 8,500 bytes, line 1
1{const n=Jo(Z,e.__scopeTooltip),{forceMount:o=n.forceMount,side:r="top",...s}=e,a=me(Z,e.__scopeTooltip);return d.jsx(X,{present:o||a.open,children:a.disableHoverableContent?d.jsx($t,{side:r,...s,ref:t}):d.jsx(Qo,{side:r,...s,ref:t})})}),Qo=i.forwardRef((e,t)=>{const n=me(Z,e.__scopeTooltip),o=Lt(Z,e.__scopeTooltip),r=i.useRef(null),s=_(t,r),[a,c]=i.useState(null),{trigger:u,onClose:l}=n,p=r.current,{onPointerInTransitChange:f}=o,h=i.useCallback(()=>{c(null),f(!1)},[f]),x=i.useCallback((b,m)=>{const v=b.currentTarget,g={x:b.clientX,y:b.clientY},y=rr(g,v.getBoundingClientRect()),E=sr(g,y),w=ir(m.getBoundingClientRect()),T=cr([...E,...w]);c(T),f(!0)},[f]);return i.useEffect(()=>()=>h(),[h]),i.useEffect(()=>{if(u&&p){const b=v=>x(v,p),m=v=>x(v,u);return u.addEventListener("pointerleave",b),p.addEventListener("pointerleave",m),()=>{u.removeEventListener("pointerleave",b),p.removeEventListener("pointerleave",m)}}},[u,p,x,h]),i.useEffect(()=>{if(a){const b=m=>{const v=m.target,g={x:m.clientX,y:m.clientY},y=u?.contains(v)||p?.contains(v),E=!ar(g,a);y?h():E&&(h(),l())};return document.addEventListener("pointermove",b),()=>document.removeEventListener("pointermove",b)}},[u,p,a,l,h]),d.jsx($t,{...e,ref:s})}),[er,tr]=pe(kt,{isInside:!1}),nr=Gn("TooltipContent"),$t=i.forwardRef((e,t)=>{const{__scopeTooltip:n,children:o,"aria-label":r,onEscapeKeyDown:s,onPointerDownOutside:a,...c}=e,u=me(Z,n),l=je(n),{onClose:p}=u;return i.useEffect(()=>(document.addEventListener(Xe,p),()=>document.removeEventListener(Xe,p)),[p]),i.useEffect(()=>{if(u.trigger){const f=h=>{h.target?.contains(u.trigger)&&p()};return window.addEventListener("scroll",f,{capture:!0}),()=>window.removeEventListener("scroll",f,{capture:!0})}},[u.trigger,p]),d.jsx(le,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:a,onFocusOutside:f=>f.preventDefault(),onDismiss:p,children:d.jsxs(zo,{"data-state":u.stateAttribute,...l,...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:[d.jsx(nr,{children:o}),d.jsx(er,{scope:n,isInside:!0,children:d.jsx(xo,{id:u.contentId,role:"tooltip",children:r||o})})]})})});jt.displayName=Z;var Kt="TooltipArrow",or=i.forwardRef((e,t)=>{const{__scopeTooltip:n,...o}=e,r=je(n);return tr(Kt,n).isInside?null:d.jsx(Yo,{...r,...o,ref:t})});or.displayName=Kt;function rr(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 sr(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 ir(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 ar(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],u=t[a],l=c.x,p=c.y,f=u.x,h=u.y;p>o!=h>o&&n<(f-l)*(o-p)/(h-p)+l&&(r=!r)}return r}function cr(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),lr(t)}function lr(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 ds=Ft,fs=jt,we="focusScope.autoFocusOnMount",be="focusScope.autoFocusOnUnmount",qe={bubbles:!1,cancelable:!0},ur="FocusScope",Bt=i.forwardRef((e,t)=>{const{loop:n=!1,trapped:o=!1,onMountAutoFocus:r,onUnmountAutoFocus:s,...a}=e,[c,u]=i.useState(null),l=H(r),p=H(s),f=i.useRef(null),h=_(t,m=>u(m)),x=i.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;i.useEffect(()=>{if(o){let m=function(E){if(x.paused||!c)return;const w=E.target;c.contains(w)?f.current=w:W(f.current,{select:!0})},v=function(E){if(x.paused||!c)return;const w=E.relatedTarget;w!==null&&(c.contains(w)||W(f.current,{select:!0}))},g=function(E){if(document.activeElement===document.body)for(const T of E)T.removedNodes.length>0&&W(c)};document.addEventListener("focusin",m),document.addEventListener("focusout",v);const y=new MutationObserver(g);return c&&y.observe(c,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",m),document.removeEventListener("focusout",v),y.disconnect()}}},[o,c,x.paused]),i.useEffect(()=>{if(c){Je.add(x);const m=document.activeElement;if(!c.contains(m)){const g=new CustomEvent(we,qe);c.addEventListener(we,l),c.dispatchEvent(g),g.defaultPrevented||(dr(hr(Ht(c)),{select:!0}),document.activeElement===m&&W(c))}return()=>{c.removeEventListener(we,l),setTimeout(()=>{const g=new CustomEvent(be,qe);c.addEventListener(be,p),c.dispatchEvent(g),g.defaultPrevented||W(m??document.body,{select:!0}),c.removeEventListener(be,p),Je.remove(x)},0)}}},[c,l,p,x]);const b=i.useCallback(m=>{if(!n&&!o||x.paused)return;const v=m.key==="Tab"&&!m.altKey&&!m.ctrlKey&&!m.metaKey,g=document.activeElement;if(v&&g){const y=m.currentTarget,[E,w]=fr(y);E&&w?!m.shiftKey&&g===w?(m.preventDefault(),n&&W(E,{select:!0})):m.shiftKey&&g===E&&(m.preventDefault(),n&&W(w,{select:!0})):g===y&&m.preventDefault()}},[n,o,x.paused]);return d.jsx(D.div,{tabIndex:-1,...a,ref:h,onKeyDown:b})});Bt.displayName=ur;function dr(e,{select:t=!1}={}){const n=document.activeElement;for(const o of e)if(W(o,{select:t}),document.activeElement!==n)return}function fr(e){const t=Ht(e),n=Ze(t,e),o=Ze(t.reverse(),e);return[n,o]}function Ht(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 Ze(e,t){for(const n of e)if(!pr(n,{upTo:t}))return n}function pr(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 mr(e){return e instanceof HTMLInputElement&&"select"in e}function W(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&mr(e)&&t&&e.select()}}var Je=vr();function vr(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=Qe(e,t),e.unshift(t)},remove(t){e=Qe(e,t),e[0]?.resume()}}}function Qe(e,t){const n=[...e],o=n.indexOf(t);return o!==-1&&n.splice(o,1),n}function hr(e){return e.filter(t=>t.tagName!=="A")}var Ce=0;function gr(){i.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??et()),document.body.insertAdjacentElement("beforeend",e[1]??et()),Ce++,()=>{Ce===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Ce--}},[])}function et(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var ve="Dialog",[Vt]=G(ve),[xr,K]=Vt(ve),Wt=e=>{const{__scopeDialog:t,children:n,open:o,defaultOpen:r,onOpenChange:s,modal:a=!0}=e,c=i.useRef(null),u=i.useRef(null),[l,p]=ue({prop:o,defaultProp:r??!1,onChange:s,caller:ve});return d.jsx(xr,{scope:t,triggerRef:c,contentRef:u,contentId:Ee(),titleId:Ee(),descriptionId:Ee(),open:l,onOpenChange:p,onOpenToggle:i.useCallback(()=>p(f=>!f),[p]),modal:a,children:n})};Wt.displayName=ve;var Ut="DialogTrigger",yr=i.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=K(Ut,n),s=_(t,r.triggerRef);return d.jsx(D.button,{type:"button","aria-haspopup":"dialog","aria-expanded":r.open,"aria-controls":r.contentId,"data-state":Be(r.o
vendor: 4,967 bytes, lines 1-5
1pen),...o,ref:s,onClick:R(e.onClick,r.onOpenToggle)})});yr.displayName=Ut;var $e="DialogPortal",[Er,zt]=Vt($e,{forceMount:void 0}),Yt=e=>{const{__scopeDialog:t,forceMount:n,children:o,container:r}=e,s=K($e,t);return d.jsx(Er,{scope:t,forceMount:n,children:i.Children.map(o,a=>d.jsx(X,{present:n||s.open,children:d.jsx(Ie,{asChild:!0,container:r,children:a})}))})};Yt.displayName=$e;var ce="DialogOverlay",Gt=i.forwardRef((e,t)=>{const n=zt(ce,e.__scopeDialog),{forceMount:o=n.forceMount,...r}=e,s=K(ce,e.__scopeDialog);return s.modal?d.jsx(X,{present:o||s.open,children:d.jsx(br,{...r,ref:t})}):null});Gt.displayName=ce;var wr=te("DialogOverlay.RemoveScroll"),br=i.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=K(ce,n);return d.jsx(Wn,{as:wr,allowPinchZoom:!0,shards:[r.contentRef],children:d.jsx(D.div,{"data-state":Be(r.open),...o,ref:t,style:{pointerEvents:"auto",...o.style}})})}),Y="DialogContent",Xt=i.forwardRef((e,t)=>{const n=zt(Y,e.__scopeDialog),{forceMount:o=n.forceMount,...r}=e,s=K(Y,e.__scopeDialog);return d.jsx(X,{present:o||s.open,children:s.modal?d.jsx(Cr,{...r,ref:t}):d.jsx(Pr,{...r,ref:t})})});Xt.displayName=Y;var Cr=i.forwardRef((e,t)=>{const n=K(Y,e.__scopeDialog),o=i.useRef(null),r=_(t,n.contentRef,o);return i.useEffect(()=>{const s=o.current;if(s)return Vn(s)},[]),d.jsx(qt,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:R(e.onCloseAutoFocus,s=>{s.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:R(e.onPointerDownOutside,s=>{const a=s.detail.originalEvent,c=a.button===0&&a.ctrlKey===!0;(a.button===2||c)&&s.preventDefault()}),onFocusOutside:R(e.onFocusOutside,s=>s.preventDefault())})}),Pr=i.forwardRef((e,t)=>{const n=K(Y,e.__scopeDialog),o=i.useRef(!1),r=i.useRef(!1);return d.jsx(qt,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{e.onCloseAutoFocus?.(s),s.defaultPrevented||(o.current||n.triggerRef.current?.focus(),s.preventDefault()),o.current=!1,r.current=!1},onInteractOutside:s=>{e.onInteractOutside?.(s),s.defaultPrevented||(o.current=!0,s.detail.originalEvent.type==="pointerdown"&&(r.current=!0));const a=s.target;n.triggerRef.current?.contains(a)&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&r.current&&s.preventDefault()}})}),qt=i.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:o,onOpenAutoFocus:r,onCloseAutoFocus:s,...a}=e,c=K(Y,n),u=i.useRef(null),l=_(t,u);return gr(),d.jsxs(d.Fragment,{children:[d.jsx(Bt,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:r,onUnmountAutoFocus:s,children:d.jsx(le,{role:"dialog",id:c.contentId,"aria-describedby":c.descriptionId,"aria-labelledby":c.titleId,"data-state":Be(c.open),...a,ref:l,onDismiss:()=>c.onOpenChange(!1)})}),d.jsxs(d.Fragment,{children:[d.jsx(Tr,{titleId:c.titleId}),d.jsx(Sr,{contentRef:u,descriptionId:c.descriptionId})]})]})}),Ke="DialogTitle",Zt=i.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=K(Ke,n);return d.jsx(D.h2,{id:r.titleId,...o,ref:t})});Zt.displayName=Ke;var Jt="DialogDescription",Qt=i.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=K(Jt,n);return d.jsx(D.p,{id:r.descriptionId,...o,ref:t})});Qt.displayName=Jt;var en="DialogClose",tn=i.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=K(en,n);return d.jsx(D.button,{type:"button",...o,ref:t,onClick:R(e.onClick,()=>r.onOpenChange(!1))})});tn.displayName=en;function Be(e){return e?"open":"closed"}var nn="DialogTitleWarning",[ps,on]=Un(nn,{contentName:Y,titleName:Ke,docsSlug:"dialog"}),Tr=({titleId:e})=>{const t=on(nn),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
2
3If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
4
5For 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},Rr="DialogDescriptionWarning",Sr=({contentRef:e,descriptionId:t})=>{const o=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${on(Rr).contentName}}.`;return i.useEffect(()=>{const r=e.current?.getAttribute("aria-describedby");t&&r&&(document.getElementById(t)||console.warn(o))},[o,e,t]),null},ms=Wt,vs=Yt,hs=Gt,gs=Xt,xs=Zt,ys=Qt,Es=tn;function rn(e,[t,n]){return Math.min(n,Math.max(t,e))}var Dr=i.createContext(void 0);function Ar(e){const t=i.useContext(Dr);return e||t||"ltr"}function sn(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 an=["PageUp","PageDown"],cn=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],ln={"from-left":["Home","PageDown","ArrowDown","ArrowLeft"],"from-right":["Home","PageDown","ArrowDown","ArrowRight"],"from-bottom":["Home","PageDown","ArrowDown","ArrowLeft"],"from-top":["Home","PageDown","ArrowUp","ArrowLeft"]},J="Slider",[Ae,_r,Nr]=st(J),[un]=G(J,[Nr]),[Ir,he]=un(J),dn=i.forwardRef((e,t)=>
vendor: 4,155 bytes, line 5
5{const{name:n,min:o=0,max:r=100,step:s=1,orientation:a="horizontal",disabled:c=!1,minStepsBetweenThumbs:u=0,defaultValue:l=[o],value:p,onValueChange:f=()=>{},onValueCommit:h=()=>{},inverted:x=!1,form:b,...m}=e,v=i.useRef(new Set),g=i.useRef(0),E=a==="horizontal"?Or:Mr,[w=[],T]=ue({prop:p,defaultProp:l,onChange:A=>{[...v.current][g.current]?.focus(),f(A)}}),S=i.useRef(w);function P(A){const k=Kr(w,A);O(A,k)}function F(A){O(A,g.current)}function j(){const A=S.current[g.current];w[g.current]!==A&&h(w)}function O(A,k,{commit:$}={commit:!1}){const C=Wr(s),M=Ur(Math.round((A-o)/s)*s+o,C),L=rn(M,[o,r]);T((I=[])=>{const N=jr(I,L,k);if(Vr(N,u*s)){g.current=N.indexOf(L);const B=String(N)!==String(I);return B&&$&&h(N),B?N:I}else return I})}return d.jsx(Ir,{scope:e.__scopeSlider,name:n,disabled:c,min:o,max:r,valueIndexToChangeRef:g,thumbs:v.current,values:w,orientation:a,form:b,children:d.jsx(Ae.Provider,{scope:e.__scopeSlider,children:d.jsx(Ae.Slot,{scope:e.__scopeSlider,children:d.jsx(E,{"aria-disabled":c,"data-disabled":c?"":void 0,...m,ref:t,onPointerDown:R(m.onPointerDown,()=>{c||(S.current=w)}),min:o,max:r,inverted:x,onSlideStart:c?void 0:P,onSlideMove:c?void 0:F,onSlideEnd:c?void 0:j,onHomeKeyDown:()=>!c&&O(o,0,{commit:!0}),onEndKeyDown:()=>!c&&O(r,w.length-1,{commit:!0}),onStepKeyDown:({event:A,direction:k})=>{if(!c){const M=an.includes(A.key)||A.shiftKey&&cn.includes(A.key)?10:1,L=g.current,I=w[L],N=s*M*k;O(I+N,L,{commit:!0})}}})})})})});dn.displayName=J;var[fn,pn]=un(J,{startEdge:"left",endEdge:"right",size:"width",direction:1}),Or=i.forwardRef((e,t)=>{const{min:n,max:o,dir:r,inverted:s,onSlideStart:a,onSlideMove:c,onSlideEnd:u,onStepKeyDown:l,...p}=e,[f,h]=i.useState(null),x=_(t,E=>h(E)),b=i.useRef(void 0),m=Ar(r),v=m==="ltr",g=v&&!s||!v&&s;function y(E){const w=b.current||f.getBoundingClientRect(),T=[0,w.width],P=He(T,g?[n,o]:[o,n]);return b.current=w,P(E-w.left)}return d.jsx(fn,{scope:e.__scopeSlider,startEdge:g?"left":"right",endEdge:g?"right":"left",direction:g?1:-1,size:"width",children:d.jsx(mn,{dir:m,"data-orientation":"horizontal",...p,ref:x,style:{...p.style,"--radix-slider-thumb-transform":"translateX(-50%)"},onSlideStart:E=>{const w=y(E.clientX);a?.(w)},onSlideMove:E=>{const w=y(E.clientX);c?.(w)},onSlideEnd:()=>{b.current=void 0,u?.()},onStepKeyDown:E=>{const T=ln[g?"from-left":"from-right"].includes(E.key);l?.({event:E,direction:T?-1:1})}})})}),Mr=i.forwardRef((e,t)=>{const{min:n,max:o,inverted:r,onSlideStart:s,onSlideMove:a,onSlideEnd:c,onStepKeyDown:u,...l}=e,p=i.useRef(null),f=_(t,p),h=i.useRef(void 0),x=!r;function b(m){const v=h.current||p.current.getBoundingClientRect(),g=[0,v.height],E=He(g,x?[o,n]:[n,o]);return h.current=v,E(m-v.top)}return d.jsx(fn,{scope:e.__scopeSlider,startEdge:x?"bottom":"top",endEdge:x?"top":"bottom",size:"height",direction:x?1:-1,children:d.jsx(mn,{"data-orientation":"vertical",...l,ref:f,style:{...l.style,"--radix-slider-thumb-transform":"translateY(50%)"},onSlideStart:m=>{const v=b(m.clientY);s?.(v)},onSlideMove:m=>{const v=b(m.clientY);a?.(v)},onSlideEnd:()=>{h.current=void 0,c?.()},onStepKeyDown:m=>{const g=ln[x?"from-bottom":"from-top"].includes(m.key);u?.({event:m,direction:g?-1:1})}})})}),mn=i.forwardRef((e,t)=>{const{__scopeSlider:n,onSlideStart:o,onSlideMove:r,onSlideEnd:s,onHomeKeyDown:a,onEndKeyDown:c,onStepKeyDown:u,...l}=e,p=he(J,n);return d.jsx(D.span,{...l,ref:t,onKeyDown:R(e.onKeyDown,f=>{f.key==="Home"?(a(f),f.preventDefault()):f.key==="End"?(c(f),f.preventDefault()):an.concat(cn).includes(f.key)&&(u(f),f.preventDefault())}),onPointerDown:R(e.onPointerDown,f=>{const h=f.target;h.setPointerCapture(f.pointerId),f.preventDefault(),p.thumbs.has(h)?h.focus():o(f)}),onPointerMove:R(e.onPointerMove,f=>{f.target.hasPointerCapture(f.pointerId)&&r(f)}),onPointerUp:R(e.onPointerUp,f=>{const h=f.target;h.hasPointerCapture(f.pointerId)&&(h.releasePointerCapture(f.pointerId),s(f))})})}),vn="SliderTrack",hn=i.forwardRef((e,t)=>{const{__scopeSlider:n,...o}=e,r=he(vn,n);return d.jsx(D.span,{"data-disabled":r.disabled?"":void 0,"data-orientation":r.orientation,...o,ref:t})});hn.displayName=vn;var _e="SliderRange",Lr=i.forwardRef((e,t)=>
5{const{__scopeSlider:n,...o}=e,r=he(_e,n),s=pn(_e,n),a=i.useRef(null),c=_(t,a),u=r.values.length,l=r.values.map(h=>yn(h,r.min,r.max)),p=u>1?Math.min(...l):0,f=100-Math.max(...l);return d.jsx(D.span,{"data-orientation":r.orientation,"data-disabled":r.disabled?"":void 0,...o,ref:c,style:{...e.style,[s.startEdge]:p+"%",[s.endEdge]:f+"%"}})});Lr.displayName=_e;var Ne="SliderThumb",gn=i.forwardRef((e,t)=>{const n=_r(e.__scopeSlider),[o,r]=i.useState(null),s=_(t,c=>r(c)),a=i.useMemo(()=>o?n().findIndex(c=>c.ref.current===o):-1,[n,o]);return d.jsx(Fr,{...e,ref:s,index:a})}),Fr=i.forwardRef((e,t)=>{const{__scopeSlider:n,index:o,name:r,...s}=e,a=he(Ne,n),c=pn(Ne,n),[u,l]=i.useState(null),p=_(t,y=>l(y)),f=u?a.form||!!u.closest("form"):!0,h=Fe(u),x=a.values[o],b=x===void 0?0:yn(x,a.min,a.max),m=$r(o,a.values.length),v=h?.[c.size],g=v?Br(v,b,c.direction):0;return i.useEffect(()=>{if(u)return a.thumbs.add(u),()=>{a.thumbs.delete(u)}},[u,a.thumbs]),d.jsxs("span",{style:{transform:"var(--radix-slider-thumb-transform)",position:"absolute",[c.startEdge]:`calc(${b}% + ${g}px)`},children:[d.jsx(Ae.ItemSlot,{scope:e.__scopeSlider,children:d.jsx(D.span,{role:"slider","aria-label":e["aria-label"]||m,"aria-valuemin":a.min,"aria-valuenow":x,"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:p,style:x===void 0?{display:"none"}:e.style,onFocus:R(e.onFocus,()=>{a.valueIndexToChangeRef.current=o})})}),f&&d.jsx(xn,{name:r??(a.name?a.name+(a.values.length>1?"[]":""):void 0),form:a.form,value:x},o)]})});gn.displayName=Ne;var kr="RadioBubbleInput",xn=i.forwardRef(({__scopeSlider:e,value:t,...n},o)=>{const r=i.useRef(null),s=_(r,o),a=sn(t);return i.useEffect(()=>{const c=r.current;if(!c)return;const u=window.HTMLInputElement.prototype,p=Object.getOwnPropertyDescriptor(u,"value").set;if(a!==t&&p){const f=new Event("input",{bubbles:!0});p.call(c,t),c.dispatchEvent(f)}},[a,t]),d.jsx(D.input,{style:{display:"none"},...n,ref:s,defaultValue:t})});xn.displayName=kr;function jr(e=[],t,n){const o=[...e];return o[n]=t,o.sort((r,s)=>r-s)}function yn(e,t,n){const s=100/(n-t)*(e-t);return rn(s,[0,100])}function $r(e,t){return t>2?`Value ${e+1} of ${t}`:t===2?["Minimum","Maximum"][e]:void 0}function Kr(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 Br(e,t,n){const o=e/2,s=He([0,50],[0,o]);return(o-s(t)*n)*n}function Hr(e){return e.slice(0,-1).map((t,n)=>e[n+1]-t)}function Vr(e,t){if(t>0){const n=Hr(e);return Math.min(...n)>=t}return!0}function He(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 Wr(e){return(String(e).split(".")[1]||"").length}function Ur(e,t){const n=Math.pow(10,t);return Math.round(e*n)/n}var ws=dn,bs=hn,Cs=gn,zr="Label",En=i.forwardRef((e,t)=>d.jsx(D.label,{...e,ref:t,onMouseDown:n=>{n.target.closest("button, input, select, textarea")||(e.onMouseDown?.(n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));En.displayName=zr;var Ps=En,ge="Checkbox",[Yr]=G(ge),[Gr,Ve]=Yr(ge);function Xr(e){const{__scopeCheckbox:t,checked:n,children:o,defaultChecked:r,disabled:s,form:a,name:c,onCheckedChange:u,required:l,value:p="on",internal_do_not_use_render:f}=e,[h,x]=ue({prop:n,defaultProp:r??!1,onChange:u,caller:ge}),[b,m]=i.useState(null),[v,g]=i.useState(null),y=i.useRef(!1),E=b?!!a||!!b.closest("form"):!0,w={checked:h,disabled:s,setChecked:x,control:b,setControl:m,name:c,form:a,value:p,hasConsumerStoppedPropagationRef:y,required:l,defaultChecked:U(r)?!1:r,isFormControl:E,bubbleInput:v,setBubbleInput:g};return d.jsx(Gr,{scope:t,...w,children:Jr(f)?f(w):o})}var wn="CheckboxTrigger",bn=i.forwardRef(({__scopeCheckbox:e,onKeyDown:t,onClick:n,...o},r)=>{const{control:s,value:a,disabled:c,checked:u,required:l,setControl:p,setChecked:f,hasConsumerStoppedPropagationRef:h,isFormControl:x,bubbleInput:b}=Ve(wn,e),m=_(r,p),v=i.useRef(u);return i.useEffect(()=>{const g=s?.form;if(g){const y=()=>f(v.current);return g.addEventListener("reset",y),()=>g.removeEventListener("reset",y)}},[s,f]),d.jsx(D.button,{type:"button",role:"checkbox","aria-checked":U(u)?"mixed":u,"aria-required":l,"data-state":Rn(u),"data-disabled":c?"":void 0,disabled:c,value:a,...o,ref:m,onKeyDown:R(t,g=>{g.key==="Enter"&&g.preventDefault()}),onClick:R(n,g=>{f(y=>U(y)?!0:!y),b&&x&&(h.current=g.isPropagationStopped(),h.current||g.stopPropagation())})})});bn.displayName=wn;var qr=i.forwardRef((e,t)=>
vendor: 1,940 bytes, line 5
5{const{__scopeCheckbox:n,name:o,checked:r,defaultChecked:s,required:a,disabled:c,value:u,onCheckedChange:l,form:p,...f}=e;return d.jsx(Xr,{__scopeCheckbox:n,checked:r,defaultChecked:s,disabled:c,required:a,onCheckedChange:l,name:o,form:p,value:u,internal_do_not_use_render:({isFormControl:h})=>d.jsxs(d.Fragment,{children:[d.jsx(bn,{...f,ref:t,__scopeCheckbox:n}),h&&d.jsx(Tn,{__scopeCheckbox:n})]})})});qr.displayName=ge;var Cn="CheckboxIndicator",Zr=i.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:o,...r}=e,s=Ve(Cn,n);return d.jsx(X,{present:o||U(s.checked)||s.checked===!0,children:d.jsx(D.span,{"data-state":Rn(s.checked),"data-disabled":s.disabled?"":void 0,...r,ref:t,style:{pointerEvents:"none",...e.style}})})});Zr.displayName=Cn;var Pn="CheckboxBubbleInput",Tn=i.forwardRef(({__scopeCheckbox:e,...t},n)=>{const{control:o,hasConsumerStoppedPropagationRef:r,checked:s,defaultChecked:a,required:c,disabled:u,name:l,value:p,form:f,bubbleInput:h,setBubbleInput:x}=Ve(Pn,e),b=_(n,x),m=sn(s),v=Fe(o);i.useEffect(()=>{const y=h;if(!y)return;const E=window.HTMLInputElement.prototype,T=Object.getOwnPropertyDescriptor(E,"checked").set,S=!r.current;if(m!==s&&T){const P=new Event("click",{bubbles:S});y.indeterminate=U(s),T.call(y,U(s)?!1:s),y.dispatchEvent(P)}},[h,m,s,r]);const g=i.useRef(U(s)?!1:s);return d.jsx(D.input,{type:"checkbox","aria-hidden":!0,defaultChecked:a??g.current,required:c,disabled:u,name:l,value:p,form:f,...t,tabIndex:-1,ref:b,style:{...t.style,...v,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});Tn.displayName=Pn;function Jr(e){return typeof e=="function"}function U(e){return e==="indeterminate"}function Rn(e){return U(e)?"indeterminate":e?"checked":"unchecked"}export{is as A,as as C,ss as D,hs as O,ts as P,os as R,es as S,rs as T,ns as V,ds as a,fs as b,ms as c,vs as d,gs as e,Es as f,xs as g,ys as h,ws as i,bs as j,Cs as k,qr as l,Zr as m,Ps as n};

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.