@json-to-office/jto 1.11.1 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +444 -99
- package/dist/cli.js.map +1 -1
- package/dist/client/assets/HomePage-DMpdYyZ0.js +251 -0
- package/dist/client/assets/HomePage-DMpdYyZ0.js.map +1 -0
- package/dist/client/assets/JsonEditorPage-Ct7wb9iA.js +3 -0
- package/dist/client/assets/JsonEditorPage-Ct7wb9iA.js.map +1 -0
- package/dist/client/assets/MonacoPluginProvider-B2fWYflh.js +85 -0
- package/dist/client/assets/MonacoPluginProvider-B2fWYflh.js.map +1 -0
- package/dist/client/assets/_virtual_jto-plugin-type-libs-BlMraosv.js +25700 -0
- package/dist/client/assets/_virtual_jto-plugin-type-libs-BlMraosv.js.map +1 -0
- package/dist/client/assets/_virtual_jto-sandbox-runtime-CNoAasd3.js +2 -0
- package/dist/client/assets/_virtual_jto-sandbox-runtime-CNoAasd3.js.map +1 -0
- package/dist/client/assets/editor-DFnlAOyt.js +16 -0
- package/dist/client/assets/editor-DFnlAOyt.js.map +1 -0
- package/dist/client/assets/{editor-monaco-json-BYUK4OUI.js → editor-monaco-json-B_1-Wxq5.js} +5 -5
- package/dist/client/assets/{editor-monaco-json-BYUK4OUI.js.map → editor-monaco-json-B_1-Wxq5.js.map} +1 -1
- package/dist/client/assets/{editor-refs-store-ChL2fzuX.js → editor-refs-store-DHeIvmr6.js} +2 -2
- package/dist/client/assets/{editor-refs-store-ChL2fzuX.js.map → editor-refs-store-DHeIvmr6.js.map} +1 -1
- package/dist/client/assets/index-Bj6ZAKUc.css +1 -0
- package/dist/client/assets/index-CeZaIyj_.js +5 -0
- package/dist/client/assets/index-CeZaIyj_.js.map +1 -0
- package/dist/client/assets/preview-CugO7y1j.js +4 -0
- package/dist/client/assets/preview-CugO7y1j.js.map +1 -0
- package/dist/client/assets/radix-ui-BzbaiLpZ.js +51 -0
- package/dist/client/assets/radix-ui-BzbaiLpZ.js.map +1 -0
- package/dist/client/assets/{ui-vendor-Bq4-oNFL.js → ui-vendor-BsAtAN16.js} +94 -64
- package/dist/client/assets/ui-vendor-BsAtAN16.js.map +1 -0
- package/dist/client/assets/useQualityAnalysis-DH2idzAY.js +6 -0
- package/dist/client/assets/useQualityAnalysis-DH2idzAY.js.map +1 -0
- package/dist/client/index.html +4 -4
- package/dist/client/templates/modern-annual-report-1.docx.json +0 -1
- package/dist/client/templates/modern-annual-report-2.docx.json +2 -4
- package/dist/client/templates/modern-annual-report-3.docx.json +1 -2
- package/dist/client/templates/standard-annual-report.docx.json +0 -1
- package/dist/client/templates/vermilion-annual-report.docx.json +0 -9
- package/dist/render-server.js.map +1 -1
- package/package.json +8 -6
- package/dist/client/assets/HomePage-r7ryeW_v.js +0 -106
- package/dist/client/assets/HomePage-r7ryeW_v.js.map +0 -1
- package/dist/client/assets/JsonEditorPage-BxUyYH8Z.js +0 -3
- package/dist/client/assets/JsonEditorPage-BxUyYH8Z.js.map +0 -1
- package/dist/client/assets/MonacoPluginProvider-CGvtVJKz.js +0 -3
- package/dist/client/assets/MonacoPluginProvider-CGvtVJKz.js.map +0 -1
- package/dist/client/assets/editor-gT4UjmPk.js +0 -9
- package/dist/client/assets/editor-gT4UjmPk.js.map +0 -1
- package/dist/client/assets/index-CgCY8SiY.js +0 -5
- package/dist/client/assets/index-CgCY8SiY.js.map +0 -1
- package/dist/client/assets/index-CrzIwHLS.css +0 -1
- package/dist/client/assets/preview-ZqhmQZJG.js +0 -2
- package/dist/client/assets/preview-ZqhmQZJG.js.map +0 -1
- package/dist/client/assets/radix-ui-DFNP5I4e.js +0 -51
- package/dist/client/assets/radix-ui-DFNP5I4e.js.map +0 -1
- package/dist/client/assets/ui-vendor-Bq4-oNFL.js.map +0 -1
- package/dist/client/assets/useQualityAnalysis-eKT8VcIt.js +0 -6
- package/dist/client/assets/useQualityAnalysis-eKT8VcIt.js.map +0 -1
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import{r as c,j as p,a as Gt,R as Kn,b as Ya,c as Oe}from"./react-vendor-BmQ2Ko_D.js";function R(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 Eo(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function dt(...e){return t=>{let n=!1;const o=e.map(r=>{const s=Eo(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():Eo(e[r],null)}}}}function j(...e){return c.useCallback(dt(...e),e)}function Xa(e,t){const n=c.createContext(t),o=s=>{const{children:i,...a}=s,l=c.useMemo(()=>a,Object.values(a));return p.jsx(n.Provider,{value:l,children:i})};o.displayName=e+"Provider";function r(s){const i=c.useContext(n);if(i)return i;if(t!==void 0)return t;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[o,r]}function se(e,t=[]){let n=[];function o(s,i){const a=c.createContext(i),l=n.length;n=[...n,i];const d=f=>{var w;const{scope:v,children:m,...g}=f,h=((w=v==null?void 0:v[e])==null?void 0:w[l])||a,x=c.useMemo(()=>g,Object.values(g));return p.jsx(h.Provider,{value:x,children:m})};d.displayName=s+"Provider";function u(f,v){var h;const m=((h=v==null?void 0:v[e])==null?void 0:h[l])||a,g=c.useContext(m);if(g)return g;if(i!==void 0)return i;throw new Error(`\`${f}\` must be used within \`${s}\``)}return[d,u]}const r=()=>{const s=n.map(i=>c.createContext(i));return function(a){const l=(a==null?void 0:a[e])||s;return c.useMemo(()=>({[`__scope${e}`]:{...a,[e]:l}}),[a,l])}};return r.scopeName=e,[o,qa(r,...t)]}function qa(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const o=e.map(r=>({useScope:r(),scopeName:r.scopeName}));return function(s){const i=o.reduce((a,{useScope:l,scopeName:d})=>{const f=l(s)[`__scope${d}`];return{...a,...f}},{});return c.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}function Le(e){const t=Za(e),n=c.forwardRef((o,r)=>{const{children:s,...i}=o,a=c.Children.toArray(s),l=a.find(Ja);if(l){const d=l.props.children,u=a.map(f=>f===l?c.Children.count(d)>1?c.Children.only(null):c.isValidElement(d)?d.props.children:null:f);return p.jsx(t,{...i,ref:r,children:c.isValidElement(d)?c.cloneElement(d,void 0,u):null})}return p.jsx(t,{...i,ref:r,children:s})});return n.displayName=`${e}.Slot`,n}function Za(e){const t=c.forwardRef((n,o)=>{const{children:r,...s}=n;if(c.isValidElement(r)){const i=tc(r),a=ec(s,r.props);return r.type!==c.Fragment&&(a.ref=o?dt(o,i):i),c.cloneElement(r,a)}return c.Children.count(r)>1?c.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Jo=Symbol("radix.slottable");function Qa(e){const t=({children:n})=>p.jsx(p.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=Jo,t}function Ja(e){return c.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Jo}function ec(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]=(...a)=>{const l=s(...a);return r(...a),l}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...e,...n}}function tc(e){var o,r;let t=(o=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(r=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var nc=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],O=nc.reduce((e,t)=>{const n=Le(`Primitive.${t}`),o=c.forwardRef((r,s)=>{const{asChild:i,...a}=r,l=i?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...a,ref:s})});return o.displayName=`Primitive.${t}`,{...e,[t]:o}},{});function er(e,t){e&&Gt.flushSync(()=>e.dispatchEvent(t))}function X(e){const t=c.useRef(e);return c.useEffect(()=>{t.current=e}),c.useMemo(()=>(...n)=>{var o;return(o=t.current)==null?void 0:o.call(t,...n)},[])}function oc(e,t=globalThis==null?void 0:globalThis.document){const n=X(e);c.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 rc="DismissableLayer",In="dismissableLayer.update",sc="dismissableLayer.pointerDownOutside",ic="dismissableLayer.focusOutside",Ro,tr=c.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Ze=c.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:o,onPointerDownOutside:r,onFocusOutside:s,onInteractOutside:i,onDismiss:a,...l}=e,d=c.useContext(tr),[u,f]=c.useState(null),v=(u==null?void 0:u.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,m]=c.useState({}),g=j(t,S=>f(S)),h=Array.from(d.layers),[x]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),w=h.indexOf(x),y=u?h.indexOf(u):-1,C=d.layersWithOutsidePointerEventsDisabled.size>0,b=y>=w,E=lc(S=>{const _=S.target,M=[...d.branches].some(A=>A.contains(_));!b||M||(r==null||r(S),i==null||i(S),S.defaultPrevented||a==null||a())},v),P=uc(S=>{const _=S.target;[...d.branches].some(A=>A.contains(_))||(s==null||s(S),i==null||i(S),S.defaultPrevented||a==null||a())},v);return oc(S=>{y===d.layers.size-1&&(o==null||o(S),!S.defaultPrevented&&a&&(S.preventDefault(),a()))},v),c.useEffect(()=>{if(u)return n&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(Ro=v.body.style.pointerEvents,v.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(u)),d.layers.add(u),Po(),()=>{n&&d.layersWithOutsidePointerEventsDisabled.size===1&&(v.body.style.pointerEvents=Ro)}},[u,v,n,d]),c.useEffect(()=>()=>{u&&(d.layers.delete(u),d.layersWithOutsidePointerEventsDisabled.delete(u),Po())},[u,d]),c.useEffect(()=>{const S=()=>m({});return document.addEventListener(In,S),()=>document.removeEventListener(In,S)},[]),p.jsx(O.div,{...l,ref:g,style:{pointerEvents:C?b?"auto":"none":void 0,...e.style},onFocusCapture:R(e.onFocusCapture,P.onFocusCapture),onBlurCapture:R(e.onBlurCapture,P.onBlurCapture),onPointerDownCapture:R(e.onPointerDownCapture,E.onPointerDownCapture)})});Ze.displayName=rc;var ac="DismissableLayerBranch",cc=c.forwardRef((e,t)=>{const n=c.useContext(tr),o=c.useRef(null),r=j(t,o);return c.useEffect(()=>{const s=o.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),p.jsx(O.div,{...e,ref:r})});cc.displayName=ac;function lc(e,t=globalThis==null?void 0:globalThis.document){const n=X(e),o=c.useRef(!1),r=c.useRef(()=>{});return c.useEffect(()=>{const s=a=>{if(a.target&&!o.current){let l=function(){nr(sc,n,d,{discrete:!0})};const d={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",r.current),r.current=l,t.addEventListener("click",r.current,{once:!0})):l()}else t.removeEventListener("click",r.current);o.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",s),t.removeEventListener("click",r.current)}},[t,n]),{onPointerDownCapture:()=>o.current=!0}}function uc(e,t=globalThis==null?void 0:globalThis.document){const n=X(e),o=c.useRef(!1);return c.useEffect(()=>{const r=s=>{s.target&&!o.current&&nr(ic,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 Po(){const e=new CustomEvent(In);document.dispatchEvent(e)}function nr(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?er(r,s):r.dispatchEvent(s)}var q=globalThis!=null&&globalThis.document?c.useLayoutEffect:()=>{},dc=Kn[" useId ".trim().toString()]||(()=>{}),fc=0;function ae(e){const[t,n]=c.useState(dc());return q(()=>{n(o=>o??String(fc++))},[e]),e||(t?`radix-${t}`:"")}const pc=["top","right","bottom","left"],Te=Math.min,oe=Math.max,Ot=Math.round,St=Math.floor,ge=e=>({x:e,y:e}),vc={left:"right",right:"left",bottom:"top",top:"bottom"};function Nn(e,t,n){return oe(e,Te(t,n))}function be(e,t){return typeof e=="function"?e(t):e}function Se(e){return e.split("-")[0]}function Qe(e){return e.split("-")[1]}function zn(e){return e==="x"?"y":"x"}function Yn(e){return e==="y"?"height":"width"}function me(e){const t=e[0];return t==="t"||t==="b"?"y":"x"}function Xn(e){return zn(me(e))}function hc(e,t,n){n===void 0&&(n=!1);const o=Qe(e),r=Xn(e),s=Yn(r);let i=r==="x"?o===(n?"end":"start")?"right":"left":o==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=Dt(i)),[i,Dt(i)]}function mc(e){const t=Dt(e);return[On(e),t,On(t)]}function On(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}const To=["left","right"],_o=["right","left"],gc=["top","bottom"],xc=["bottom","top"];function wc(e,t,n){switch(e){case"top":case"bottom":return n?t?_o:To:t?To:_o;case"left":case"right":return t?gc:xc;default:return[]}}function yc(e,t,n,o){const r=Qe(e);let s=wc(Se(e),n==="start",o);return r&&(s=s.map(i=>i+"-"+r),t&&(s=s.concat(s.map(On)))),s}function Dt(e){const t=Se(e);return vc[t]+e.slice(t.length)}function Cc(e){return{top:0,right:0,bottom:0,left:0,...e}}function or(e){return typeof e!="number"?Cc(e):{top:e,right:e,bottom:e,left:e}}function Lt(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 Mo(e,t,n){let{reference:o,floating:r}=e;const s=me(t),i=Xn(t),a=Yn(i),l=Se(t),d=s==="y",u=o.x+o.width/2-r.width/2,f=o.y+o.height/2-r.height/2,v=o[a]/2-r[a]/2;let m;switch(l){case"top":m={x:u,y:o.y-r.height};break;case"bottom":m={x:u,y:o.y+o.height};break;case"right":m={x:o.x+o.width,y:f};break;case"left":m={x:o.x-r.width,y:f};break;default:m={x:o.x,y:o.y}}switch(Qe(t)){case"start":m[i]-=v*(n&&d?-1:1);break;case"end":m[i]+=v*(n&&d?-1:1);break}return m}async function bc(e,t){var n;t===void 0&&(t={});const{x:o,y:r,platform:s,rects:i,elements:a,strategy:l}=e,{boundary:d="clippingAncestors",rootBoundary:u="viewport",elementContext:f="floating",altBoundary:v=!1,padding:m=0}=be(t,e),g=or(m),x=a[v?f==="floating"?"reference":"floating":f],w=Lt(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(x)))==null||n?x:x.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(a.floating)),boundary:d,rootBoundary:u,strategy:l})),y=f==="floating"?{x:o,y:r,width:i.floating.width,height:i.floating.height}:i.reference,C=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),b=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},E=Lt(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:y,offsetParent:C,strategy:l}):y);return{top:(w.top-E.top+g.top)/b.y,bottom:(E.bottom-w.bottom+g.bottom)/b.y,left:(w.left-E.left+g.left)/b.x,right:(E.right-w.right+g.right)/b.x}}const Sc=50,Ec=async(e,t,n)=>{const{placement:o="bottom",strategy:r="absolute",middleware:s=[],platform:i}=n,a=i.detectOverflow?i:{...i,detectOverflow:bc},l=await(i.isRTL==null?void 0:i.isRTL(t));let d=await i.getElementRects({reference:e,floating:t,strategy:r}),{x:u,y:f}=Mo(d,o,l),v=o,m=0;const g={};for(let h=0;h<s.length;h++){const x=s[h];if(!x)continue;const{name:w,fn:y}=x,{x:C,y:b,data:E,reset:P}=await y({x:u,y:f,initialPlacement:o,placement:v,strategy:r,middlewareData:g,rects:d,platform:a,elements:{reference:e,floating:t}});u=C??u,f=b??f,g[w]={...g[w],...E},P&&m<Sc&&(m++,typeof P=="object"&&(P.placement&&(v=P.placement),P.rects&&(d=P.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:r}):P.rects),{x:u,y:f}=Mo(d,v,l)),h=-1)}return{x:u,y:f,placement:v,strategy:r,middlewareData:g}},Rc=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:o,placement:r,rects:s,platform:i,elements:a,middlewareData:l}=t,{element:d,padding:u=0}=be(e,t)||{};if(d==null)return{};const f=or(u),v={x:n,y:o},m=Xn(r),g=Yn(m),h=await i.getDimensions(d),x=m==="y",w=x?"top":"left",y=x?"bottom":"right",C=x?"clientHeight":"clientWidth",b=s.reference[g]+s.reference[m]-v[m]-s.floating[g],E=v[m]-s.reference[m],P=await(i.getOffsetParent==null?void 0:i.getOffsetParent(d));let S=P?P[C]:0;(!S||!await(i.isElement==null?void 0:i.isElement(P)))&&(S=a.floating[C]||s.floating[g]);const _=b/2-E/2,M=S/2-h[g]/2-1,A=Te(f[w],M),L=Te(f[y],M),$=A,F=S-h[g]-L,k=S/2-h[g]/2+_,G=Nn($,k,F),D=!l.arrow&&Qe(r)!=null&&k!==G&&s.reference[g]/2-(k<$?A:L)-h[g]/2<0,B=D?k<$?k-$:k-F:0;return{[m]:v[m]+B,data:{[m]:G,centerOffset:k-G-B,...D&&{alignmentOffset:B}},reset:D}}}),Pc=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,o;const{placement:r,middlewareData:s,rects:i,initialPlacement:a,platform:l,elements:d}=t,{mainAxis:u=!0,crossAxis:f=!0,fallbackPlacements:v,fallbackStrategy:m="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:h=!0,...x}=be(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const w=Se(r),y=me(a),C=Se(a)===a,b=await(l.isRTL==null?void 0:l.isRTL(d.floating)),E=v||(C||!h?[Dt(a)]:mc(a)),P=g!=="none";!v&&P&&E.push(...yc(a,h,g,b));const S=[a,...E],_=await l.detectOverflow(t,x),M=[];let A=((o=s.flip)==null?void 0:o.overflows)||[];if(u&&M.push(_[w]),f){const k=hc(r,i,b);M.push(_[k[0]],_[k[1]])}if(A=[...A,{placement:r,overflows:M}],!M.every(k=>k<=0)){var L,$;const k=(((L=s.flip)==null?void 0:L.index)||0)+1,G=S[k];if(G&&(!(f==="alignment"?y!==me(G):!1)||A.every(I=>me(I.placement)===y?I.overflows[0]>0:!0)))return{data:{index:k,overflows:A},reset:{placement:G}};let D=($=A.filter(B=>B.overflows[0]<=0).sort((B,I)=>B.overflows[1]-I.overflows[1])[0])==null?void 0:$.placement;if(!D)switch(m){case"bestFit":{var F;const B=(F=A.filter(I=>{if(P){const T=me(I.placement);return T===y||T==="y"}return!0}).map(I=>[I.placement,I.overflows.filter(T=>T>0).reduce((T,K)=>T+K,0)]).sort((I,T)=>I[1]-T[1])[0])==null?void 0:F[0];B&&(D=B);break}case"initialPlacement":D=a;break}if(r!==D)return{reset:{placement:D}}}return{}}}};function Ao(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Io(e){return pc.some(t=>e[t]>=0)}const Tc=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n,platform:o}=t,{strategy:r="referenceHidden",...s}=be(e,t);switch(r){case"referenceHidden":{const i=await o.detectOverflow(t,{...s,elementContext:"reference"}),a=Ao(i,n.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:Io(a)}}}case"escaped":{const i=await o.detectOverflow(t,{...s,altBoundary:!0}),a=Ao(i,n.floating);return{data:{escapedOffsets:a,escaped:Io(a)}}}default:return{}}}}},rr=new Set(["left","top"]);async function _c(e,t){const{placement:n,platform:o,elements:r}=e,s=await(o.isRTL==null?void 0:o.isRTL(r.floating)),i=Se(n),a=Qe(n),l=me(n)==="y",d=rr.has(i)?-1:1,u=s&&l?-1:1,f=be(t,e);let{mainAxis:v,crossAxis:m,alignmentAxis:g}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return a&&typeof g=="number"&&(m=a==="end"?g*-1:g),l?{x:m*u,y:v*d}:{x:v*d,y:m*u}}const Mc=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,o;const{x:r,y:s,placement:i,middlewareData:a}=t,l=await _c(t,e);return i===((n=a.offset)==null?void 0:n.placement)&&(o=a.arrow)!=null&&o.alignmentOffset?{}:{x:r+l.x,y:s+l.y,data:{...l,placement:i}}}}},Ac=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:o,placement:r,platform:s}=t,{mainAxis:i=!0,crossAxis:a=!1,limiter:l={fn:w=>{let{x:y,y:C}=w;return{x:y,y:C}}},...d}=be(e,t),u={x:n,y:o},f=await s.detectOverflow(t,d),v=me(Se(r)),m=zn(v);let g=u[m],h=u[v];if(i){const w=m==="y"?"top":"left",y=m==="y"?"bottom":"right",C=g+f[w],b=g-f[y];g=Nn(C,g,b)}if(a){const w=v==="y"?"top":"left",y=v==="y"?"bottom":"right",C=h+f[w],b=h-f[y];h=Nn(C,h,b)}const x=l.fn({...t,[m]:g,[v]:h});return{...x,data:{x:x.x-n,y:x.y-o,enabled:{[m]:i,[v]:a}}}}}},Ic=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:o,placement:r,rects:s,middlewareData:i}=t,{offset:a=0,mainAxis:l=!0,crossAxis:d=!0}=be(e,t),u={x:n,y:o},f=me(r),v=zn(f);let m=u[v],g=u[f];const h=be(a,t),x=typeof h=="number"?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(l){const C=v==="y"?"height":"width",b=s.reference[v]-s.floating[C]+x.mainAxis,E=s.reference[v]+s.reference[C]-x.mainAxis;m<b?m=b:m>E&&(m=E)}if(d){var w,y;const C=v==="y"?"width":"height",b=rr.has(Se(r)),E=s.reference[f]-s.floating[C]+(b&&((w=i.offset)==null?void 0:w[f])||0)+(b?0:x.crossAxis),P=s.reference[f]+s.reference[C]+(b?0:((y=i.offset)==null?void 0:y[f])||0)-(b?x.crossAxis:0);g<E?g=E:g>P&&(g=P)}return{[v]:m,[f]:g}}}},Nc=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,o;const{placement:r,rects:s,platform:i,elements:a}=t,{apply:l=()=>{},...d}=be(e,t),u=await i.detectOverflow(t,d),f=Se(r),v=Qe(r),m=me(r)==="y",{width:g,height:h}=s.floating;let x,w;f==="top"||f==="bottom"?(x=f,w=v===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?"start":"end")?"left":"right"):(w=f,x=v==="end"?"top":"bottom");const y=h-u.top-u.bottom,C=g-u.left-u.right,b=Te(h-u[x],y),E=Te(g-u[w],C),P=!t.middlewareData.shift;let S=b,_=E;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(_=C),(o=t.middlewareData.shift)!=null&&o.enabled.y&&(S=y),P&&!v){const A=oe(u.left,0),L=oe(u.right,0),$=oe(u.top,0),F=oe(u.bottom,0);m?_=g-2*(A!==0||L!==0?A+L:oe(u.left,u.right)):S=h-2*($!==0||F!==0?$+F:oe(u.top,u.bottom))}await l({...t,availableWidth:_,availableHeight:S});const M=await i.getDimensions(a.floating);return g!==M.width||h!==M.height?{reset:{rects:!0}}:{}}}};function Kt(){return typeof window<"u"}function Je(e){return sr(e)?(e.nodeName||"").toLowerCase():"#document"}function re(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function xe(e){var t;return(t=(sr(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function sr(e){return Kt()?e instanceof Node||e instanceof re(e).Node:!1}function de(e){return Kt()?e instanceof Element||e instanceof re(e).Element:!1}function Re(e){return Kt()?e instanceof HTMLElement||e instanceof re(e).HTMLElement:!1}function No(e){return!Kt()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof re(e).ShadowRoot}function ft(e){const{overflow:t,overflowX:n,overflowY:o,display:r}=fe(e);return/auto|scroll|overlay|hidden|clip/.test(t+o+n)&&r!=="inline"&&r!=="contents"}function Oc(e){return/^(table|td|th)$/.test(Je(e))}function zt(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}const Dc=/transform|translate|scale|rotate|perspective|filter/,Lc=/paint|layout|strict|content/,De=e=>!!e&&e!=="none";let yn;function qn(e){const t=de(e)?fe(e):e;return De(t.transform)||De(t.translate)||De(t.scale)||De(t.rotate)||De(t.perspective)||!Zn()&&(De(t.backdropFilter)||De(t.filter))||Dc.test(t.willChange||"")||Lc.test(t.contain||"")}function jc(e){let t=_e(e);for(;Re(t)&&!ze(t);){if(qn(t))return t;if(zt(t))return null;t=_e(t)}return null}function Zn(){return yn==null&&(yn=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),yn}function ze(e){return/^(html|body|#document)$/.test(Je(e))}function fe(e){return re(e).getComputedStyle(e)}function Yt(e){return de(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function _e(e){if(Je(e)==="html")return e;const t=e.assignedSlot||e.parentNode||No(e)&&e.host||xe(e);return No(t)?t.host:t}function ir(e){const t=_e(e);return ze(t)?e.ownerDocument?e.ownerDocument.body:e.body:Re(t)&&ft(t)?t:ir(t)}function at(e,t,n){var o;t===void 0&&(t=[]),n===void 0&&(n=!0);const r=ir(e),s=r===((o=e.ownerDocument)==null?void 0:o.body),i=re(r);if(s){const a=Dn(i);return t.concat(i,i.visualViewport||[],ft(r)?r:[],a&&n?at(a):[])}else return t.concat(r,at(r,[],n))}function Dn(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function ar(e){const t=fe(e);let n=parseFloat(t.width)||0,o=parseFloat(t.height)||0;const r=Re(e),s=r?e.offsetWidth:n,i=r?e.offsetHeight:o,a=Ot(n)!==s||Ot(o)!==i;return a&&(n=s,o=i),{width:n,height:o,$:a}}function Qn(e){return de(e)?e:e.contextElement}function Ge(e){const t=Qn(e);if(!Re(t))return ge(1);const n=t.getBoundingClientRect(),{width:o,height:r,$:s}=ar(t);let i=(s?Ot(n.width):n.width)/o,a=(s?Ot(n.height):n.height)/r;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const kc=ge(0);function cr(e){const t=re(e);return!Zn()||!t.visualViewport?kc:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function $c(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==re(e)?!1:t}function je(e,t,n,o){t===void 0&&(t=!1),n===void 0&&(n=!1);const r=e.getBoundingClientRect(),s=Qn(e);let i=ge(1);t&&(o?de(o)&&(i=Ge(o)):i=Ge(e));const a=$c(s,n,o)?cr(s):ge(0);let l=(r.left+a.x)/i.x,d=(r.top+a.y)/i.y,u=r.width/i.x,f=r.height/i.y;if(s){const v=re(s),m=o&&de(o)?re(o):o;let g=v,h=Dn(g);for(;h&&o&&m!==g;){const x=Ge(h),w=h.getBoundingClientRect(),y=fe(h),C=w.left+(h.clientLeft+parseFloat(y.paddingLeft))*x.x,b=w.top+(h.clientTop+parseFloat(y.paddingTop))*x.y;l*=x.x,d*=x.y,u*=x.x,f*=x.y,l+=C,d+=b,g=re(h),h=Dn(g)}}return Lt({width:u,height:f,x:l,y:d})}function Xt(e,t){const n=Yt(e).scrollLeft;return t?t.left+n:je(xe(e)).left+n}function lr(e,t){const n=e.getBoundingClientRect(),o=n.left+t.scrollLeft-Xt(e,n),r=n.top+t.scrollTop;return{x:o,y:r}}function Fc(e){let{elements:t,rect:n,offsetParent:o,strategy:r}=e;const s=r==="fixed",i=xe(o),a=t?zt(t.floating):!1;if(o===i||a&&s)return n;let l={scrollLeft:0,scrollTop:0},d=ge(1);const u=ge(0),f=Re(o);if((f||!f&&!s)&&((Je(o)!=="body"||ft(i))&&(l=Yt(o)),f)){const m=je(o);d=Ge(o),u.x=m.x+o.clientLeft,u.y=m.y+o.clientTop}const v=i&&!f&&!s?lr(i,l):ge(0);return{width:n.width*d.x,height:n.height*d.y,x:n.x*d.x-l.scrollLeft*d.x+u.x+v.x,y:n.y*d.y-l.scrollTop*d.y+u.y+v.y}}function Bc(e){return Array.from(e.getClientRects())}function Wc(e){const t=xe(e),n=Yt(e),o=e.ownerDocument.body,r=oe(t.scrollWidth,t.clientWidth,o.scrollWidth,o.clientWidth),s=oe(t.scrollHeight,t.clientHeight,o.scrollHeight,o.clientHeight);let i=-n.scrollLeft+Xt(e);const a=-n.scrollTop;return fe(o).direction==="rtl"&&(i+=oe(t.clientWidth,o.clientWidth)-r),{width:r,height:s,x:i,y:a}}const Oo=25;function Hc(e,t){const n=re(e),o=xe(e),r=n.visualViewport;let s=o.clientWidth,i=o.clientHeight,a=0,l=0;if(r){s=r.width,i=r.height;const u=Zn();(!u||u&&t==="fixed")&&(a=r.offsetLeft,l=r.offsetTop)}const d=Xt(o);if(d<=0){const u=o.ownerDocument,f=u.body,v=getComputedStyle(f),m=u.compatMode==="CSS1Compat"&&parseFloat(v.marginLeft)+parseFloat(v.marginRight)||0,g=Math.abs(o.clientWidth-f.clientWidth-m);g<=Oo&&(s-=g)}else d<=Oo&&(s+=d);return{width:s,height:i,x:a,y:l}}function Vc(e,t){const n=je(e,!0,t==="fixed"),o=n.top+e.clientTop,r=n.left+e.clientLeft,s=Re(e)?Ge(e):ge(1),i=e.clientWidth*s.x,a=e.clientHeight*s.y,l=r*s.x,d=o*s.y;return{width:i,height:a,x:l,y:d}}function Do(e,t,n){let o;if(t==="viewport")o=Hc(e,n);else if(t==="document")o=Wc(xe(e));else if(de(t))o=Vc(t,n);else{const r=cr(e);o={x:t.x-r.x,y:t.y-r.y,width:t.width,height:t.height}}return Lt(o)}function ur(e,t){const n=_e(e);return n===t||!de(n)||ze(n)?!1:fe(n).position==="fixed"||ur(n,t)}function Uc(e,t){const n=t.get(e);if(n)return n;let o=at(e,[],!1).filter(a=>de(a)&&Je(a)!=="body"),r=null;const s=fe(e).position==="fixed";let i=s?_e(e):e;for(;de(i)&&!ze(i);){const a=fe(i),l=qn(i);!l&&a.position==="fixed"&&(r=null),(s?!l&&!r:!l&&a.position==="static"&&!!r&&(r.position==="absolute"||r.position==="fixed")||ft(i)&&!l&&ur(e,i))?o=o.filter(u=>u!==i):r=a,i=_e(i)}return t.set(e,o),o}function Gc(e){let{element:t,boundary:n,rootBoundary:o,strategy:r}=e;const i=[...n==="clippingAncestors"?zt(t)?[]:Uc(t,this._c):[].concat(n),o],a=Do(t,i[0],r);let l=a.top,d=a.right,u=a.bottom,f=a.left;for(let v=1;v<i.length;v++){const m=Do(t,i[v],r);l=oe(m.top,l),d=Te(m.right,d),u=Te(m.bottom,u),f=oe(m.left,f)}return{width:d-f,height:u-l,x:f,y:l}}function Kc(e){const{width:t,height:n}=ar(e);return{width:t,height:n}}function zc(e,t,n){const o=Re(t),r=xe(t),s=n==="fixed",i=je(e,!0,s,t);let a={scrollLeft:0,scrollTop:0};const l=ge(0);function d(){l.x=Xt(r)}if(o||!o&&!s)if((Je(t)!=="body"||ft(r))&&(a=Yt(t)),o){const m=je(t,!0,s,t);l.x=m.x+t.clientLeft,l.y=m.y+t.clientTop}else r&&d();s&&!o&&r&&d();const u=r&&!o&&!s?lr(r,a):ge(0),f=i.left+a.scrollLeft-l.x-u.x,v=i.top+a.scrollTop-l.y-u.y;return{x:f,y:v,width:i.width,height:i.height}}function Cn(e){return fe(e).position==="static"}function Lo(e,t){if(!Re(e)||fe(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return xe(e)===n&&(n=n.ownerDocument.body),n}function dr(e,t){const n=re(e);if(zt(e))return n;if(!Re(e)){let r=_e(e);for(;r&&!ze(r);){if(de(r)&&!Cn(r))return r;r=_e(r)}return n}let o=Lo(e,t);for(;o&&Oc(o)&&Cn(o);)o=Lo(o,t);return o&&ze(o)&&Cn(o)&&!qn(o)?n:o||jc(e)||n}const Yc=async function(e){const t=this.getOffsetParent||dr,n=this.getDimensions,o=await n(e.floating);return{reference:zc(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}};function Xc(e){return fe(e).direction==="rtl"}const qc={convertOffsetParentRelativeRectToViewportRelativeRect:Fc,getDocumentElement:xe,getClippingRect:Gc,getOffsetParent:dr,getElementRects:Yc,getClientRects:Bc,getDimensions:Kc,getScale:Ge,isElement:de,isRTL:Xc};function fr(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Zc(e,t){let n=null,o;const r=xe(e);function s(){var a;clearTimeout(o),(a=n)==null||a.disconnect(),n=null}function i(a,l){a===void 0&&(a=!1),l===void 0&&(l=1),s();const d=e.getBoundingClientRect(),{left:u,top:f,width:v,height:m}=d;if(a||t(),!v||!m)return;const g=St(f),h=St(r.clientWidth-(u+v)),x=St(r.clientHeight-(f+m)),w=St(u),C={rootMargin:-g+"px "+-h+"px "+-x+"px "+-w+"px",threshold:oe(0,Te(1,l))||1};let b=!0;function E(P){const S=P[0].intersectionRatio;if(S!==l){if(!b)return i();S?i(!1,S):o=setTimeout(()=>{i(!1,1e-7)},1e3)}S===1&&!fr(d,e.getBoundingClientRect())&&i(),b=!1}try{n=new IntersectionObserver(E,{...C,root:r.ownerDocument})}catch{n=new IntersectionObserver(E,C)}n.observe(e)}return i(!0),s}function Qc(e,t,n,o){o===void 0&&(o={});const{ancestorScroll:r=!0,ancestorResize:s=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=o,d=Qn(e),u=r||s?[...d?at(d):[],...t?at(t):[]]:[];u.forEach(w=>{r&&w.addEventListener("scroll",n,{passive:!0}),s&&w.addEventListener("resize",n)});const f=d&&a?Zc(d,n):null;let v=-1,m=null;i&&(m=new ResizeObserver(w=>{let[y]=w;y&&y.target===d&&m&&t&&(m.unobserve(t),cancelAnimationFrame(v),v=requestAnimationFrame(()=>{var C;(C=m)==null||C.observe(t)})),n()}),d&&!l&&m.observe(d),t&&m.observe(t));let g,h=l?je(e):null;l&&x();function x(){const w=je(e);h&&!fr(h,w)&&n(),h=w,g=requestAnimationFrame(x)}return n(),()=>{var w;u.forEach(y=>{r&&y.removeEventListener("scroll",n),s&&y.removeEventListener("resize",n)}),f==null||f(),(w=m)==null||w.disconnect(),m=null,l&&cancelAnimationFrame(g)}}const Jc=Mc,el=Ac,tl=Pc,nl=Nc,ol=Tc,jo=Rc,rl=Ic,sl=(e,t,n)=>{const o=new Map,r={platform:qc,...n},s={...r.platform,_c:o};return Ec(e,t,{...r,platform:s})};var il=typeof document<"u",al=function(){},At=il?c.useLayoutEffect:al;function jt(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,o,r;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(o=n;o--!==0;)if(!jt(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)&&!jt(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function pr(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function ko(e,t){const n=pr(e);return Math.round(t*n)/n}function bn(e){const t=c.useRef(e);return At(()=>{t.current=e}),t}function cl(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:o=[],platform:r,elements:{reference:s,floating:i}={},transform:a=!0,whileElementsMounted:l,open:d}=e,[u,f]=c.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[v,m]=c.useState(o);jt(v,o)||m(o);const[g,h]=c.useState(null),[x,w]=c.useState(null),y=c.useCallback(I=>{I!==P.current&&(P.current=I,h(I))},[]),C=c.useCallback(I=>{I!==S.current&&(S.current=I,w(I))},[]),b=s||g,E=i||x,P=c.useRef(null),S=c.useRef(null),_=c.useRef(u),M=l!=null,A=bn(l),L=bn(r),$=bn(d),F=c.useCallback(()=>{if(!P.current||!S.current)return;const I={placement:t,strategy:n,middleware:v};L.current&&(I.platform=L.current),sl(P.current,S.current,I).then(T=>{const K={...T,isPositioned:$.current!==!1};k.current&&!jt(_.current,K)&&(_.current=K,Gt.flushSync(()=>{f(K)}))})},[v,t,n,L,$]);At(()=>{d===!1&&_.current.isPositioned&&(_.current.isPositioned=!1,f(I=>({...I,isPositioned:!1})))},[d]);const k=c.useRef(!1);At(()=>(k.current=!0,()=>{k.current=!1}),[]),At(()=>{if(b&&(P.current=b),E&&(S.current=E),b&&E){if(A.current)return A.current(b,E,F);F()}},[b,E,F,A,M]);const G=c.useMemo(()=>({reference:P,floating:S,setReference:y,setFloating:C}),[y,C]),D=c.useMemo(()=>({reference:b,floating:E}),[b,E]),B=c.useMemo(()=>{const I={position:n,left:0,top:0};if(!D.floating)return I;const T=ko(D.floating,u.x),K=ko(D.floating,u.y);return a?{...I,transform:"translate("+T+"px, "+K+"px)",...pr(D.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:T,top:K}},[n,a,D.floating,u.x,u.y]);return c.useMemo(()=>({...u,update:F,refs:G,elements:D,floatingStyles:B}),[u,F,G,D,B])}const ll=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?jo({element:o.current,padding:r}).fn(n):{}:o?jo({element:o,padding:r}).fn(n):{}}}},ul=(e,t)=>{const n=Jc(e);return{name:n.name,fn:n.fn,options:[e,t]}},dl=(e,t)=>{const n=el(e);return{name:n.name,fn:n.fn,options:[e,t]}},fl=(e,t)=>({fn:rl(e).fn,options:[e,t]}),pl=(e,t)=>{const n=tl(e);return{name:n.name,fn:n.fn,options:[e,t]}},vl=(e,t)=>{const n=nl(e);return{name:n.name,fn:n.fn,options:[e,t]}},hl=(e,t)=>{const n=ol(e);return{name:n.name,fn:n.fn,options:[e,t]}},ml=(e,t)=>{const n=ll(e);return{name:n.name,fn:n.fn,options:[e,t]}};var gl="Arrow",vr=c.forwardRef((e,t)=>{const{children:n,width:o=10,height:r=5,...s}=e;return p.jsx(O.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"})})});vr.displayName=gl;var xl=vr;function hr(e){const[t,n]=c.useState(void 0);return q(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const o=new ResizeObserver(r=>{if(!Array.isArray(r)||!r.length)return;const s=r[0];let i,a;if("borderBoxSize"in s){const l=s.borderBoxSize,d=Array.isArray(l)?l[0]:l;i=d.inlineSize,a=d.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return o.observe(e,{box:"border-box"}),()=>o.unobserve(e)}else n(void 0)},[e]),t}var Jn="Popper",[mr,Me]=se(Jn),[wl,gr]=mr(Jn),xr=e=>{const{__scopePopper:t,children:n}=e,[o,r]=c.useState(null);return p.jsx(wl,{scope:t,anchor:o,onAnchorChange:r,children:n})};xr.displayName=Jn;var wr="PopperAnchor",yr=c.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:o,...r}=e,s=gr(wr,n),i=c.useRef(null),a=j(t,i),l=c.useRef(null);return c.useEffect(()=>{const d=l.current;l.current=(o==null?void 0:o.current)||i.current,d!==l.current&&s.onAnchorChange(l.current)}),o?null:p.jsx(O.div,{...r,ref:a})});yr.displayName=wr;var eo="PopperContent",[yl,Cl]=mr(eo),Cr=c.forwardRef((e,t)=>{var N,H,z,W,V,U;const{__scopePopper:n,side:o="bottom",sideOffset:r=0,align:s="center",alignOffset:i=0,arrowPadding:a=0,avoidCollisions:l=!0,collisionBoundary:d=[],collisionPadding:u=0,sticky:f="partial",hideWhenDetached:v=!1,updatePositionStrategy:m="optimized",onPlaced:g,...h}=e,x=gr(eo,n),[w,y]=c.useState(null),C=j(t,ne=>y(ne)),[b,E]=c.useState(null),P=hr(b),S=(P==null?void 0:P.width)??0,_=(P==null?void 0:P.height)??0,M=o+(s!=="center"?"-"+s:""),A=typeof u=="number"?u:{top:0,right:0,bottom:0,left:0,...u},L=Array.isArray(d)?d:[d],$=L.length>0,F={padding:A,boundary:L.filter(Sl),altBoundary:$},{refs:k,floatingStyles:G,placement:D,isPositioned:B,middlewareData:I}=cl({strategy:"fixed",placement:M,whileElementsMounted:(...ne)=>Qc(...ne,{animationFrame:m==="always"}),elements:{reference:x.anchor},middleware:[ul({mainAxis:r+_,alignmentAxis:i}),l&&dl({mainAxis:!0,crossAxis:!1,limiter:f==="partial"?fl():void 0,...F}),l&&pl({...F}),vl({...F,apply:({elements:ne,rects:ve,availableWidth:nt,availableHeight:ot})=>{const{width:rt,height:za}=ve.reference,bt=ne.floating.style;bt.setProperty("--radix-popper-available-width",`${nt}px`),bt.setProperty("--radix-popper-available-height",`${ot}px`),bt.setProperty("--radix-popper-anchor-width",`${rt}px`),bt.setProperty("--radix-popper-anchor-height",`${za}px`)}}),b&&ml({element:b,padding:a}),El({arrowWidth:S,arrowHeight:_}),v&&hl({strategy:"referenceHidden",...F})]}),[T,K]=Er(D),Y=X(g);q(()=>{B&&(Y==null||Y())},[B,Y]);const ee=(N=I.arrow)==null?void 0:N.x,ye=(H=I.arrow)==null?void 0:H.y,ie=((z=I.arrow)==null?void 0:z.centerOffset)!==0,[Ce,te]=c.useState();return q(()=>{w&&te(window.getComputedStyle(w).zIndex)},[w]),p.jsx("div",{ref:k.setFloating,"data-radix-popper-content-wrapper":"",style:{...G,transform:B?G.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Ce,"--radix-popper-transform-origin":[(W=I.transformOrigin)==null?void 0:W.x,(V=I.transformOrigin)==null?void 0:V.y].join(" "),...((U=I.hide)==null?void 0:U.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:p.jsx(yl,{scope:n,placedSide:T,onArrowChange:E,arrowX:ee,arrowY:ye,shouldHideArrow:ie,children:p.jsx(O.div,{"data-side":T,"data-align":K,...h,ref:C,style:{...h.style,animation:B?void 0:"none"}})})})});Cr.displayName=eo;var br="PopperArrow",bl={top:"bottom",right:"left",bottom:"top",left:"right"},Sr=c.forwardRef(function(t,n){const{__scopePopper:o,...r}=t,s=Cl(br,o),i=bl[s.placedSide];return p.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[i]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:p.jsx(xl,{...r,ref:n,style:{...r.style,display:"block"}})})});Sr.displayName=br;function Sl(e){return e!==null}var El=e=>({name:"transformOrigin",options:e,fn(t){var x,w,y;const{placement:n,rects:o,middlewareData:r}=t,i=((x=r.arrow)==null?void 0:x.centerOffset)!==0,a=i?0:e.arrowWidth,l=i?0:e.arrowHeight,[d,u]=Er(n),f={start:"0%",center:"50%",end:"100%"}[u],v=(((w=r.arrow)==null?void 0:w.x)??0)+a/2,m=(((y=r.arrow)==null?void 0:y.y)??0)+l/2;let g="",h="";return d==="bottom"?(g=i?f:`${v}px`,h=`${-l}px`):d==="top"?(g=i?f:`${v}px`,h=`${o.floating.height+l}px`):d==="right"?(g=`${-l}px`,h=i?f:`${m}px`):d==="left"&&(g=`${o.floating.width+l}px`,h=i?f:`${m}px`),{data:{x:g,y:h}}}});function Er(e){const[t,n="center"]=e.split("-");return[t,n]}var qt=xr,pt=yr,Zt=Cr,Qt=Sr,Rl="Portal",et=c.forwardRef((e,t)=>{var a;const{container:n,...o}=e,[r,s]=c.useState(!1);q(()=>s(!0),[]);const i=n||r&&((a=globalThis==null?void 0:globalThis.document)==null?void 0:a.body);return i?Ya.createPortal(p.jsx(O.div,{...o,ref:t}),i):null});et.displayName=Rl;function Pl(e,t){return c.useReducer((n,o)=>t[n][o]??n,e)}var Z=e=>{const{present:t,children:n}=e,o=Tl(t),r=typeof n=="function"?n({present:o.isPresent}):c.Children.only(n),s=j(o.ref,_l(r));return typeof n=="function"||o.isPresent?c.cloneElement(r,{ref:s}):null};Z.displayName="Presence";function Tl(e){const[t,n]=c.useState(),o=c.useRef(null),r=c.useRef(e),s=c.useRef("none"),i=e?"mounted":"unmounted",[a,l]=Pl(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return c.useEffect(()=>{const d=Et(o.current);s.current=a==="mounted"?d:"none"},[a]),q(()=>{const d=o.current,u=r.current;if(u!==e){const v=s.current,m=Et(d);e?l("MOUNT"):m==="none"||(d==null?void 0:d.display)==="none"?l("UNMOUNT"):l(u&&v!==m?"ANIMATION_OUT":"UNMOUNT"),r.current=e}},[e,l]),q(()=>{if(t){let d;const u=t.ownerDocument.defaultView??window,f=m=>{const h=Et(o.current).includes(CSS.escape(m.animationName));if(m.target===t&&h&&(l("ANIMATION_END"),!r.current)){const x=t.style.animationFillMode;t.style.animationFillMode="forwards",d=u.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=x)})}},v=m=>{m.target===t&&(s.current=Et(o.current))};return t.addEventListener("animationstart",v),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{u.clearTimeout(d),t.removeEventListener("animationstart",v),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:c.useCallback(d=>{o.current=d?getComputedStyle(d):null,n(d)},[])}}function Et(e){return(e==null?void 0:e.animationName)||"none"}function _l(e){var o,r;let t=(o=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(r=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Ml=Kn[" useInsertionEffect ".trim().toString()]||q;function Ee({prop:e,defaultProp:t,onChange:n=()=>{},caller:o}){const[r,s,i]=Al({defaultProp:t,onChange:n}),a=e!==void 0,l=a?e:r;{const u=c.useRef(e!==void 0);c.useEffect(()=>{const f=u.current;f!==a&&console.warn(`${o} is changing from ${f?"controlled":"uncontrolled"} to ${a?"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.`),u.current=a},[a,o])}const d=c.useCallback(u=>{var f;if(a){const v=Il(u)?u(e):u;v!==e&&((f=i.current)==null||f.call(i,v))}else s(u)},[a,e,s,i]);return[l,d]}function Al({defaultProp:e,onChange:t}){const[n,o]=c.useState(e),r=c.useRef(n),s=c.useRef(t);return Ml(()=>{s.current=t},[t]),c.useEffect(()=>{var i;r.current!==n&&((i=s.current)==null||i.call(s,n),r.current=n)},[n,r]),[n,o,s]}function Il(e){return typeof e=="function"}var Rr=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"}),Nl="VisuallyHidden",Pr=c.forwardRef((e,t)=>p.jsx(O.span,{...e,ref:t,style:{...Rr,...e.style}}));Pr.displayName=Nl;var Ol=Pr,[Jt]=se("Tooltip",[Me]),en=Me(),Tr="TooltipProvider",Dl=700,Ln="tooltip.open",[Ll,to]=Jt(Tr),_r=e=>{const{__scopeTooltip:t,delayDuration:n=Dl,skipDelayDuration:o=300,disableHoverableContent:r=!1,children:s}=e,i=c.useRef(!0),a=c.useRef(!1),l=c.useRef(0);return c.useEffect(()=>{const d=l.current;return()=>window.clearTimeout(d)},[]),p.jsx(Ll,{scope:t,isOpenDelayedRef:i,delayDuration:n,onOpen:c.useCallback(()=>{window.clearTimeout(l.current),i.current=!1},[]),onClose:c.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>i.current=!0,o)},[o]),isPointerInTransitRef:a,onPointerInTransitChange:c.useCallback(d=>{a.current=d},[]),disableHoverableContent:r,children:s})};_r.displayName=Tr;var ct="Tooltip",[jl,vt]=Jt(ct),Mr=e=>{const{__scopeTooltip:t,children:n,open:o,defaultOpen:r,onOpenChange:s,disableHoverableContent:i,delayDuration:a}=e,l=to(ct,e.__scopeTooltip),d=en(t),[u,f]=c.useState(null),v=ae(),m=c.useRef(0),g=i??l.disableHoverableContent,h=a??l.delayDuration,x=c.useRef(!1),[w,y]=Ee({prop:o,defaultProp:r??!1,onChange:S=>{S?(l.onOpen(),document.dispatchEvent(new CustomEvent(Ln))):l.onClose(),s==null||s(S)},caller:ct}),C=c.useMemo(()=>w?x.current?"delayed-open":"instant-open":"closed",[w]),b=c.useCallback(()=>{window.clearTimeout(m.current),m.current=0,x.current=!1,y(!0)},[y]),E=c.useCallback(()=>{window.clearTimeout(m.current),m.current=0,y(!1)},[y]),P=c.useCallback(()=>{window.clearTimeout(m.current),m.current=window.setTimeout(()=>{x.current=!0,y(!0),m.current=0},h)},[h,y]);return c.useEffect(()=>()=>{m.current&&(window.clearTimeout(m.current),m.current=0)},[]),p.jsx(qt,{...d,children:p.jsx(jl,{scope:t,contentId:v,open:w,stateAttribute:C,trigger:u,onTriggerChange:f,onTriggerEnter:c.useCallback(()=>{l.isOpenDelayedRef.current?P():b()},[l.isOpenDelayedRef,P,b]),onTriggerLeave:c.useCallback(()=>{g?E():(window.clearTimeout(m.current),m.current=0)},[E,g]),onOpen:b,onClose:E,disableHoverableContent:g,children:n})})};Mr.displayName=ct;var jn="TooltipTrigger",Ar=c.forwardRef((e,t)=>{const{__scopeTooltip:n,...o}=e,r=vt(jn,n),s=to(jn,n),i=en(n),a=c.useRef(null),l=j(t,a,r.onTriggerChange),d=c.useRef(!1),u=c.useRef(!1),f=c.useCallback(()=>d.current=!1,[]);return c.useEffect(()=>()=>document.removeEventListener("pointerup",f),[f]),p.jsx(pt,{asChild:!0,...i,children:p.jsx(O.button,{"aria-describedby":r.open?r.contentId:void 0,"data-state":r.stateAttribute,...o,ref:l,onPointerMove:R(e.onPointerMove,v=>{v.pointerType!=="touch"&&!u.current&&!s.isPointerInTransitRef.current&&(r.onTriggerEnter(),u.current=!0)}),onPointerLeave:R(e.onPointerLeave,()=>{r.onTriggerLeave(),u.current=!1}),onPointerDown:R(e.onPointerDown,()=>{r.open&&r.onClose(),d.current=!0,document.addEventListener("pointerup",f,{once:!0})}),onFocus:R(e.onFocus,()=>{d.current||r.onOpen()}),onBlur:R(e.onBlur,r.onClose),onClick:R(e.onClick,r.onClose)})})});Ar.displayName=jn;var no="TooltipPortal",[kl,$l]=Jt(no,{forceMount:void 0}),Ir=e=>{const{__scopeTooltip:t,forceMount:n,children:o,container:r}=e,s=vt(no,t);return p.jsx(kl,{scope:t,forceMount:n,children:p.jsx(Z,{present:n||s.open,children:p.jsx(et,{asChild:!0,container:r,children:o})})})};Ir.displayName=no;var Ye="TooltipContent",Nr=c.forwardRef((e,t)=>{const n=$l(Ye,e.__scopeTooltip),{forceMount:o=n.forceMount,side:r="top",...s}=e,i=vt(Ye,e.__scopeTooltip);return p.jsx(Z,{present:o||i.open,children:i.disableHoverableContent?p.jsx(Or,{side:r,...s,ref:t}):p.jsx(Fl,{side:r,...s,ref:t})})}),Fl=c.forwardRef((e,t)=>{const n=vt(Ye,e.__scopeTooltip),o=to(Ye,e.__scopeTooltip),r=c.useRef(null),s=j(t,r),[i,a]=c.useState(null),{trigger:l,onClose:d}=n,u=r.current,{onPointerInTransitChange:f}=o,v=c.useCallback(()=>{a(null),f(!1)},[f]),m=c.useCallback((g,h)=>{const x=g.currentTarget,w={x:g.clientX,y:g.clientY},y=Vl(w,x.getBoundingClientRect()),C=Ul(w,y),b=Gl(h.getBoundingClientRect()),E=zl([...C,...b]);a(E),f(!0)},[f]);return c.useEffect(()=>()=>v(),[v]),c.useEffect(()=>{if(l&&u){const g=x=>m(x,u),h=x=>m(x,l);return l.addEventListener("pointerleave",g),u.addEventListener("pointerleave",h),()=>{l.removeEventListener("pointerleave",g),u.removeEventListener("pointerleave",h)}}},[l,u,m,v]),c.useEffect(()=>{if(i){const g=h=>{const x=h.target,w={x:h.clientX,y:h.clientY},y=(l==null?void 0:l.contains(x))||(u==null?void 0:u.contains(x)),C=!Kl(w,i);y?v():C&&(v(),d())};return document.addEventListener("pointermove",g),()=>document.removeEventListener("pointermove",g)}},[l,u,i,d,v]),p.jsx(Or,{...e,ref:s})}),[Bl,Wl]=Jt(ct,{isInside:!1}),Hl=Qa("TooltipContent"),Or=c.forwardRef((e,t)=>{const{__scopeTooltip:n,children:o,"aria-label":r,onEscapeKeyDown:s,onPointerDownOutside:i,...a}=e,l=vt(Ye,n),d=en(n),{onClose:u}=l;return c.useEffect(()=>(document.addEventListener(Ln,u),()=>document.removeEventListener(Ln,u)),[u]),c.useEffect(()=>{if(l.trigger){const f=v=>{const m=v.target;m!=null&&m.contains(l.trigger)&&u()};return window.addEventListener("scroll",f,{capture:!0}),()=>window.removeEventListener("scroll",f,{capture:!0})}},[l.trigger,u]),p.jsx(Ze,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:f=>f.preventDefault(),onDismiss:u,children:p.jsxs(Zt,{"data-state":l.stateAttribute,...d,...a,ref:t,style:{...a.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(Hl,{children:o}),p.jsx(Bl,{scope:n,isInside:!0,children:p.jsx(Ol,{id:l.contentId,role:"tooltip",children:r||o})})]})})});Nr.displayName=Ye;var Dr="TooltipArrow",Lr=c.forwardRef((e,t)=>{const{__scopeTooltip:n,...o}=e,r=en(n);return Wl(Dr,n).isInside?null:p.jsx(Qt,{...r,...o,ref:t})});Lr.displayName=Dr;function Vl(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 Ul(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 Gl(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 Kl(e,t){const{x:n,y:o}=e;let r=!1;for(let s=0,i=t.length-1;s<t.length;i=s++){const a=t[s],l=t[i],d=a.x,u=a.y,f=l.x,v=l.y;u>o!=v>o&&n<(f-d)*(o-u)/(v-u)+d&&(r=!r)}return r}function zl(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),Yl(t)}function Yl(e){if(e.length<=1)return e.slice();const t=[];for(let o=0;o<e.length;o++){const r=e[o];for(;t.length>=2;){const s=t[t.length-1],i=t[t.length-2];if((s.x-i.x)*(r.y-i.y)>=(s.y-i.y)*(r.x-i.x))t.pop();else break}t.push(r)}t.pop();const n=[];for(let o=e.length-1;o>=0;o--){const r=e[o];for(;n.length>=2;){const s=n[n.length-1],i=n[n.length-2];if((s.x-i.x)*(r.y-i.y)>=(s.y-i.y)*(r.x-i.x))n.pop();else break}n.push(r)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var Np=_r,Op=Mr,Dp=Ar,Lp=Ir,jp=Nr,kp=Lr,Sn="focusScope.autoFocusOnMount",En="focusScope.autoFocusOnUnmount",$o={bubbles:!1,cancelable:!0},Xl="FocusScope",ht=c.forwardRef((e,t)=>{const{loop:n=!1,trapped:o=!1,onMountAutoFocus:r,onUnmountAutoFocus:s,...i}=e,[a,l]=c.useState(null),d=X(r),u=X(s),f=c.useRef(null),v=j(t,h=>l(h)),m=c.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;c.useEffect(()=>{if(o){let h=function(C){if(m.paused||!a)return;const b=C.target;a.contains(b)?f.current=b:Pe(f.current,{select:!0})},x=function(C){if(m.paused||!a)return;const b=C.relatedTarget;b!==null&&(a.contains(b)||Pe(f.current,{select:!0}))},w=function(C){if(document.activeElement===document.body)for(const E of C)E.removedNodes.length>0&&Pe(a)};document.addEventListener("focusin",h),document.addEventListener("focusout",x);const y=new MutationObserver(w);return a&&y.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",h),document.removeEventListener("focusout",x),y.disconnect()}}},[o,a,m.paused]),c.useEffect(()=>{if(a){Bo.add(m);const h=document.activeElement;if(!a.contains(h)){const w=new CustomEvent(Sn,$o);a.addEventListener(Sn,d),a.dispatchEvent(w),w.defaultPrevented||(ql(tu(jr(a)),{select:!0}),document.activeElement===h&&Pe(a))}return()=>{a.removeEventListener(Sn,d),setTimeout(()=>{const w=new CustomEvent(En,$o);a.addEventListener(En,u),a.dispatchEvent(w),w.defaultPrevented||Pe(h??document.body,{select:!0}),a.removeEventListener(En,u),Bo.remove(m)},0)}}},[a,d,u,m]);const g=c.useCallback(h=>{if(!n&&!o||m.paused)return;const x=h.key==="Tab"&&!h.altKey&&!h.ctrlKey&&!h.metaKey,w=document.activeElement;if(x&&w){const y=h.currentTarget,[C,b]=Zl(y);C&&b?!h.shiftKey&&w===b?(h.preventDefault(),n&&Pe(C,{select:!0})):h.shiftKey&&w===C&&(h.preventDefault(),n&&Pe(b,{select:!0})):w===y&&h.preventDefault()}},[n,o,m.paused]);return p.jsx(O.div,{tabIndex:-1,...i,ref:v,onKeyDown:g})});ht.displayName=Xl;function ql(e,{select:t=!1}={}){const n=document.activeElement;for(const o of e)if(Pe(o,{select:t}),document.activeElement!==n)return}function Zl(e){const t=jr(e),n=Fo(t,e),o=Fo(t.reverse(),e);return[n,o]}function jr(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 Fo(e,t){for(const n of e)if(!Ql(n,{upTo:t}))return n}function Ql(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 Jl(e){return e instanceof HTMLInputElement&&"select"in e}function Pe(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Jl(e)&&t&&e.select()}}var Bo=eu();function eu(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Wo(e,t),e.unshift(t)},remove(t){var n;e=Wo(e,t),(n=e[0])==null||n.resume()}}}function Wo(e,t){const n=[...e],o=n.indexOf(t);return o!==-1&&n.splice(o,1),n}function tu(e){return e.filter(t=>t.tagName!=="A")}var Rn=0;function tn(){c.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Ho()),document.body.insertAdjacentElement("beforeend",e[1]??Ho()),Rn++,()=>{Rn===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Rn--}},[])}function Ho(){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 he=function(){return he=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},he.apply(this,arguments)};function kr(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 nu(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 It="right-scroll-bar-position",Nt="width-before-scroll-bar",ou="with-scroll-bars-hidden",ru="--removed-body-scroll-bar-size";function Pn(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function su(e,t){var n=c.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 iu=typeof window<"u"?c.useLayoutEffect:c.useEffect,Vo=new WeakMap;function au(e,t){var n=su(null,function(o){return e.forEach(function(r){return Pn(r,o)})});return iu(function(){var o=Vo.get(n);if(o){var r=new Set(o),s=new Set(e),i=n.current;r.forEach(function(a){s.has(a)||Pn(a,null)}),s.forEach(function(a){r.has(a)||Pn(a,i)})}Vo.set(n,e)},[e]),n}function cu(e){return e}function lu(e,t){t===void 0&&(t=cu);var n=[],o=!1,r={read:function(){if(o)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(s){var i=t(s,o);return n.push(i),function(){n=n.filter(function(a){return a!==i})}},assignSyncMedium:function(s){for(o=!0;n.length;){var i=n;n=[],i.forEach(s)}n={push:function(a){return s(a)},filter:function(){return n}}},assignMedium:function(s){o=!0;var i=[];if(n.length){var a=n;n=[],a.forEach(s),i=n}var l=function(){var u=i;i=[],u.forEach(s)},d=function(){return Promise.resolve().then(l)};d(),n={push:function(u){i.push(u),d()},filter:function(u){return i=i.filter(u),n}}}};return r}function uu(e){e===void 0&&(e={});var t=lu(null);return t.options=he({async:!0,ssr:!1},e),t}var $r=function(e){var t=e.sideCar,n=kr(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 c.createElement(o,he({},n))};$r.isSideCarExport=!0;function du(e,t){return e.useMedium(t),$r}var Fr=uu(),Tn=function(){},nn=c.forwardRef(function(e,t){var n=c.useRef(null),o=c.useState({onScrollCapture:Tn,onWheelCapture:Tn,onTouchMoveCapture:Tn}),r=o[0],s=o[1],i=e.forwardProps,a=e.children,l=e.className,d=e.removeScrollBar,u=e.enabled,f=e.shards,v=e.sideCar,m=e.noRelative,g=e.noIsolation,h=e.inert,x=e.allowPinchZoom,w=e.as,y=w===void 0?"div":w,C=e.gapMode,b=kr(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),E=v,P=au([n,t]),S=he(he({},b),r);return c.createElement(c.Fragment,null,u&&c.createElement(E,{sideCar:Fr,removeScrollBar:d,shards:f,noRelative:m,noIsolation:g,inert:h,setCallbacks:s,allowPinchZoom:!!x,lockRef:n,gapMode:C}),i?c.cloneElement(c.Children.only(a),he(he({},S),{ref:P})):c.createElement(y,he({},S,{className:l,ref:P}),a))});nn.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};nn.classNames={fullWidth:Nt,zeroRight:It};var fu=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function pu(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=fu();return t&&e.setAttribute("nonce",t),e}function vu(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function hu(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var mu=function(){var e=0,t=null;return{add:function(n){e==0&&(t=pu())&&(vu(t,n),hu(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},gu=function(){var e=mu();return function(t,n){c.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},Br=function(){var e=gu(),t=function(n){var o=n.styles,r=n.dynamic;return e(o,r),null};return t},xu={left:0,top:0,right:0,gap:0},_n=function(e){return parseInt(e||"",10)||0},wu=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[_n(n),_n(o),_n(r)]},yu=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return xu;var t=wu(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])}},Cu=Br(),Ke="data-scroll-locked",bu=function(e,t,n,o){var r=e.left,s=e.top,i=e.right,a=e.gap;return n===void 0&&(n="margin"),`
|
|
2
|
+
.`.concat(ou,` {
|
|
3
|
+
overflow: hidden `).concat(o,`;
|
|
4
|
+
padding-right: `).concat(a,"px ").concat(o,`;
|
|
5
|
+
}
|
|
6
|
+
body[`).concat(Ke,`] {
|
|
7
|
+
overflow: hidden `).concat(o,`;
|
|
8
|
+
overscroll-behavior: contain;
|
|
9
|
+
`).concat([t&&"position: relative ".concat(o,";"),n==="margin"&&`
|
|
10
|
+
padding-left: `.concat(r,`px;
|
|
11
|
+
padding-top: `).concat(s,`px;
|
|
12
|
+
padding-right: `).concat(i,`px;
|
|
13
|
+
margin-left:0;
|
|
14
|
+
margin-top:0;
|
|
15
|
+
margin-right: `).concat(a,"px ").concat(o,`;
|
|
16
|
+
`),n==="padding"&&"padding-right: ".concat(a,"px ").concat(o,";")].filter(Boolean).join(""),`
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.`).concat(It,` {
|
|
20
|
+
right: `).concat(a,"px ").concat(o,`;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.`).concat(Nt,` {
|
|
24
|
+
margin-right: `).concat(a,"px ").concat(o,`;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.`).concat(It," .").concat(It,` {
|
|
28
|
+
right: 0 `).concat(o,`;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.`).concat(Nt," .").concat(Nt,` {
|
|
32
|
+
margin-right: 0 `).concat(o,`;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
body[`).concat(Ke,`] {
|
|
36
|
+
`).concat(ru,": ").concat(a,`px;
|
|
37
|
+
}
|
|
38
|
+
`)},Uo=function(){var e=parseInt(document.body.getAttribute(Ke)||"0",10);return isFinite(e)?e:0},Su=function(){c.useEffect(function(){return document.body.setAttribute(Ke,(Uo()+1).toString()),function(){var e=Uo()-1;e<=0?document.body.removeAttribute(Ke):document.body.setAttribute(Ke,e.toString())}},[])},Eu=function(e){var t=e.noRelative,n=e.noImportant,o=e.gapMode,r=o===void 0?"margin":o;Su();var s=c.useMemo(function(){return yu(r)},[r]);return c.createElement(Cu,{styles:bu(s,!t,r,n?"":"!important")})},kn=!1;if(typeof window<"u")try{var Rt=Object.defineProperty({},"passive",{get:function(){return kn=!0,!0}});window.addEventListener("test",Rt,Rt),window.removeEventListener("test",Rt,Rt)}catch{kn=!1}var He=kn?{passive:!1}:!1,Ru=function(e){return e.tagName==="TEXTAREA"},Wr=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!Ru(e)&&n[t]==="visible")},Pu=function(e){return Wr(e,"overflowY")},Tu=function(e){return Wr(e,"overflowX")},Go=function(e,t){var n=t.ownerDocument,o=t;do{typeof ShadowRoot<"u"&&o instanceof ShadowRoot&&(o=o.host);var r=Hr(e,o);if(r){var s=Vr(e,o),i=s[1],a=s[2];if(i>a)return!0}o=o.parentNode}while(o&&o!==n.body);return!1},_u=function(e){var t=e.scrollTop,n=e.scrollHeight,o=e.clientHeight;return[t,n,o]},Mu=function(e){var t=e.scrollLeft,n=e.scrollWidth,o=e.clientWidth;return[t,n,o]},Hr=function(e,t){return e==="v"?Pu(t):Tu(t)},Vr=function(e,t){return e==="v"?_u(t):Mu(t)},Au=function(e,t){return e==="h"&&t==="rtl"?-1:1},Iu=function(e,t,n,o,r){var s=Au(e,window.getComputedStyle(t).direction),i=s*o,a=n.target,l=t.contains(a),d=!1,u=i>0,f=0,v=0;do{if(!a)break;var m=Vr(e,a),g=m[0],h=m[1],x=m[2],w=h-x-s*g;(g||w)&&Hr(e,a)&&(f+=w,v+=g);var y=a.parentNode;a=y&&y.nodeType===Node.DOCUMENT_FRAGMENT_NODE?y.host:y}while(!l&&a!==document.body||l&&(t.contains(a)||t===a));return(u&&Math.abs(f)<1||!u&&Math.abs(v)<1)&&(d=!0),d},Pt=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Ko=function(e){return[e.deltaX,e.deltaY]},zo=function(e){return e&&"current"in e?e.current:e},Nu=function(e,t){return e[0]===t[0]&&e[1]===t[1]},Ou=function(e){return`
|
|
39
|
+
.block-interactivity-`.concat(e,` {pointer-events: none;}
|
|
40
|
+
.allow-interactivity-`).concat(e,` {pointer-events: all;}
|
|
41
|
+
`)},Du=0,Ve=[];function Lu(e){var t=c.useRef([]),n=c.useRef([0,0]),o=c.useRef(),r=c.useState(Du++)[0],s=c.useState(Br)[0],i=c.useRef(e);c.useEffect(function(){i.current=e},[e]),c.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(r));var h=nu([e.lockRef.current],(e.shards||[]).map(zo),!0).filter(Boolean);return h.forEach(function(x){return x.classList.add("allow-interactivity-".concat(r))}),function(){document.body.classList.remove("block-interactivity-".concat(r)),h.forEach(function(x){return x.classList.remove("allow-interactivity-".concat(r))})}}},[e.inert,e.lockRef.current,e.shards]);var a=c.useCallback(function(h,x){if("touches"in h&&h.touches.length===2||h.type==="wheel"&&h.ctrlKey)return!i.current.allowPinchZoom;var w=Pt(h),y=n.current,C="deltaX"in h?h.deltaX:y[0]-w[0],b="deltaY"in h?h.deltaY:y[1]-w[1],E,P=h.target,S=Math.abs(C)>Math.abs(b)?"h":"v";if("touches"in h&&S==="h"&&P.type==="range")return!1;var _=window.getSelection(),M=_&&_.anchorNode,A=M?M===P||M.contains(P):!1;if(A)return!1;var L=Go(S,P);if(!L)return!0;if(L?E=S:(E=S==="v"?"h":"v",L=Go(S,P)),!L)return!1;if(!o.current&&"changedTouches"in h&&(C||b)&&(o.current=E),!E)return!0;var $=o.current||E;return Iu($,x,h,$==="h"?C:b)},[]),l=c.useCallback(function(h){var x=h;if(!(!Ve.length||Ve[Ve.length-1]!==s)){var w="deltaY"in x?Ko(x):Pt(x),y=t.current.filter(function(E){return E.name===x.type&&(E.target===x.target||x.target===E.shadowParent)&&Nu(E.delta,w)})[0];if(y&&y.should){x.cancelable&&x.preventDefault();return}if(!y){var C=(i.current.shards||[]).map(zo).filter(Boolean).filter(function(E){return E.contains(x.target)}),b=C.length>0?a(x,C[0]):!i.current.noIsolation;b&&x.cancelable&&x.preventDefault()}}},[]),d=c.useCallback(function(h,x,w,y){var C={name:h,delta:x,target:w,should:y,shadowParent:ju(w)};t.current.push(C),setTimeout(function(){t.current=t.current.filter(function(b){return b!==C})},1)},[]),u=c.useCallback(function(h){n.current=Pt(h),o.current=void 0},[]),f=c.useCallback(function(h){d(h.type,Ko(h),h.target,a(h,e.lockRef.current))},[]),v=c.useCallback(function(h){d(h.type,Pt(h),h.target,a(h,e.lockRef.current))},[]);c.useEffect(function(){return Ve.push(s),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:v}),document.addEventListener("wheel",l,He),document.addEventListener("touchmove",l,He),document.addEventListener("touchstart",u,He),function(){Ve=Ve.filter(function(h){return h!==s}),document.removeEventListener("wheel",l,He),document.removeEventListener("touchmove",l,He),document.removeEventListener("touchstart",u,He)}},[]);var m=e.removeScrollBar,g=e.inert;return c.createElement(c.Fragment,null,g?c.createElement(s,{styles:Ou(r)}):null,m?c.createElement(Eu,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function ju(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const ku=du(Fr,Lu);var mt=c.forwardRef(function(e,t){return c.createElement(nn,he({},e,{ref:t,sideCar:ku}))});mt.classNames=nn.classNames;var $u=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Ue=new WeakMap,Tt=new WeakMap,_t={},Mn=0,Ur=function(e){return e&&(e.host||Ur(e.parentNode))},Fu=function(e,t){return t.map(function(n){if(e.contains(n))return n;var o=Ur(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})},Bu=function(e,t,n,o){var r=Fu(t,Array.isArray(e)?e:[e]);_t[n]||(_t[n]=new WeakMap);var s=_t[n],i=[],a=new Set,l=new Set(r),d=function(f){!f||a.has(f)||(a.add(f),d(f.parentNode))};r.forEach(d);var u=function(f){!f||l.has(f)||Array.prototype.forEach.call(f.children,function(v){if(a.has(v))u(v);else try{var m=v.getAttribute(o),g=m!==null&&m!=="false",h=(Ue.get(v)||0)+1,x=(s.get(v)||0)+1;Ue.set(v,h),s.set(v,x),i.push(v),h===1&&g&&Tt.set(v,!0),x===1&&v.setAttribute(n,"true"),g||v.setAttribute(o,"true")}catch(w){console.error("aria-hidden: cannot operate on ",v,w)}})};return u(t),a.clear(),Mn++,function(){i.forEach(function(f){var v=Ue.get(f)-1,m=s.get(f)-1;Ue.set(f,v),s.set(f,m),v||(Tt.has(f)||f.removeAttribute(o),Tt.delete(f)),m||f.removeAttribute(n)}),Mn--,Mn||(Ue=new WeakMap,Ue=new WeakMap,Tt=new WeakMap,_t={})}},on=function(e,t,n){n===void 0&&(n="data-aria-hidden");var o=Array.from(Array.isArray(e)?e:[e]),r=$u(e);return r?(o.push.apply(o,Array.from(r.querySelectorAll("[aria-live], script"))),Bu(o,r,n,"aria-hidden")):function(){return null}},rn="Dialog",[Gr]=se(rn),[Wu,pe]=Gr(rn),Kr=e=>{const{__scopeDialog:t,children:n,open:o,defaultOpen:r,onOpenChange:s,modal:i=!0}=e,a=c.useRef(null),l=c.useRef(null),[d,u]=Ee({prop:o,defaultProp:r??!1,onChange:s,caller:rn});return p.jsx(Wu,{scope:t,triggerRef:a,contentRef:l,contentId:ae(),titleId:ae(),descriptionId:ae(),open:d,onOpenChange:u,onOpenToggle:c.useCallback(()=>u(f=>!f),[u]),modal:i,children:n})};Kr.displayName=rn;var zr="DialogTrigger",Yr=c.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=pe(zr,n),s=j(t,r.triggerRef);return p.jsx(O.button,{type:"button","aria-haspopup":"dialog","aria-expanded":r.open,"aria-controls":r.contentId,"data-state":so(r.open),...o,ref:s,onClick:R(e.onClick,r.onOpenToggle)})});Yr.displayName=zr;var oo="DialogPortal",[Hu,Xr]=Gr(oo,{forceMount:void 0}),qr=e=>{const{__scopeDialog:t,forceMount:n,children:o,container:r}=e,s=pe(oo,t);return p.jsx(Hu,{scope:t,forceMount:n,children:c.Children.map(o,i=>p.jsx(Z,{present:n||s.open,children:p.jsx(et,{asChild:!0,container:r,children:i})}))})};qr.displayName=oo;var kt="DialogOverlay",Zr=c.forwardRef((e,t)=>{const n=Xr(kt,e.__scopeDialog),{forceMount:o=n.forceMount,...r}=e,s=pe(kt,e.__scopeDialog);return s.modal?p.jsx(Z,{present:o||s.open,children:p.jsx(Uu,{...r,ref:t})}):null});Zr.displayName=kt;var Vu=Le("DialogOverlay.RemoveScroll"),Uu=c.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=pe(kt,n);return p.jsx(mt,{as:Vu,allowPinchZoom:!0,shards:[r.contentRef],children:p.jsx(O.div,{"data-state":so(r.open),...o,ref:t,style:{pointerEvents:"auto",...o.style}})})}),ke="DialogContent",Qr=c.forwardRef((e,t)=>{const n=Xr(ke,e.__scopeDialog),{forceMount:o=n.forceMount,...r}=e,s=pe(ke,e.__scopeDialog);return p.jsx(Z,{present:o||s.open,children:s.modal?p.jsx(Gu,{...r,ref:t}):p.jsx(Ku,{...r,ref:t})})});Qr.displayName=ke;var Gu=c.forwardRef((e,t)=>{const n=pe(ke,e.__scopeDialog),o=c.useRef(null),r=j(t,n.contentRef,o);return c.useEffect(()=>{const s=o.current;if(s)return on(s)},[]),p.jsx(Jr,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:R(e.onCloseAutoFocus,s=>{var i;s.preventDefault(),(i=n.triggerRef.current)==null||i.focus()}),onPointerDownOutside:R(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,a=i.button===0&&i.ctrlKey===!0;(i.button===2||a)&&s.preventDefault()}),onFocusOutside:R(e.onFocusOutside,s=>s.preventDefault())})}),Ku=c.forwardRef((e,t)=>{const n=pe(ke,e.__scopeDialog),o=c.useRef(!1),r=c.useRef(!1);return p.jsx(Jr,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var i,a;(i=e.onCloseAutoFocus)==null||i.call(e,s),s.defaultPrevented||(o.current||(a=n.triggerRef.current)==null||a.focus(),s.preventDefault()),o.current=!1,r.current=!1},onInteractOutside:s=>{var l,d;(l=e.onInteractOutside)==null||l.call(e,s),s.defaultPrevented||(o.current=!0,s.detail.originalEvent.type==="pointerdown"&&(r.current=!0));const i=s.target;((d=n.triggerRef.current)==null?void 0:d.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&r.current&&s.preventDefault()}})}),Jr=c.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:o,onOpenAutoFocus:r,onCloseAutoFocus:s,...i}=e,a=pe(ke,n),l=c.useRef(null),d=j(t,l);return tn(),p.jsxs(p.Fragment,{children:[p.jsx(ht,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:r,onUnmountAutoFocus:s,children:p.jsx(Ze,{role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":so(a.open),...i,ref:d,onDismiss:()=>a.onOpenChange(!1)})}),p.jsxs(p.Fragment,{children:[p.jsx(zu,{titleId:a.titleId}),p.jsx(Xu,{contentRef:l,descriptionId:a.descriptionId})]})]})}),ro="DialogTitle",es=c.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=pe(ro,n);return p.jsx(O.h2,{id:r.titleId,...o,ref:t})});es.displayName=ro;var ts="DialogDescription",ns=c.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=pe(ts,n);return p.jsx(O.p,{id:r.descriptionId,...o,ref:t})});ns.displayName=ts;var os="DialogClose",rs=c.forwardRef((e,t)=>{const{__scopeDialog:n,...o}=e,r=pe(os,n);return p.jsx(O.button,{type:"button",...o,ref:t,onClick:R(e.onClick,()=>r.onOpenChange(!1))})});rs.displayName=os;function so(e){return e?"open":"closed"}var ss="DialogTitleWarning",[$p,is]=Xa(ss,{contentName:ke,titleName:ro,docsSlug:"dialog"}),zu=({titleId:e})=>{const t=is(ss),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
|
|
42
|
+
|
|
43
|
+
If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
44
|
+
|
|
45
|
+
For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return c.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},Yu="DialogDescriptionWarning",Xu=({contentRef:e,descriptionId:t})=>{const o=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${is(Yu).contentName}}.`;return c.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},Fp=Kr,Bp=Yr,Wp=qr,Hp=Zr,Vp=Qr,Up=es,Gp=ns,Kp=rs;function $n(e,[t,n]){return Math.min(n,Math.max(t,e))}function io(e){const t=e+"CollectionProvider",[n,o]=se(t),[r,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=h=>{const{scope:x,children:w}=h,y=Oe.useRef(null),C=Oe.useRef(new Map).current;return p.jsx(r,{scope:x,itemMap:C,collectionRef:y,children:w})};i.displayName=t;const a=e+"CollectionSlot",l=Le(a),d=Oe.forwardRef((h,x)=>{const{scope:w,children:y}=h,C=s(a,w),b=j(x,C.collectionRef);return p.jsx(l,{ref:b,children:y})});d.displayName=a;const u=e+"CollectionItemSlot",f="data-radix-collection-item",v=Le(u),m=Oe.forwardRef((h,x)=>{const{scope:w,children:y,...C}=h,b=Oe.useRef(null),E=j(x,b),P=s(u,w);return Oe.useEffect(()=>(P.itemMap.set(b,{ref:b,...C}),()=>void P.itemMap.delete(b))),p.jsx(v,{[f]:"",ref:E,children:y})});m.displayName=u;function g(h){const x=s(e+"CollectionConsumer",h);return Oe.useCallback(()=>{const y=x.collectionRef.current;if(!y)return[];const C=Array.from(y.querySelectorAll(`[${f}]`));return Array.from(x.itemMap.values()).sort((P,S)=>C.indexOf(P.ref.current)-C.indexOf(S.ref.current))},[x.collectionRef,x.itemMap])}return[{Provider:i,Slot:d,ItemSlot:m},g,o]}var qu=c.createContext(void 0);function gt(e){const t=c.useContext(qu);return e||t||"ltr"}function as(e){const t=c.useRef({value:e,previous:e});return c.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var Zu=[" ","Enter","ArrowUp","ArrowDown"],Qu=[" ","Enter"],$e="Select",[sn,an,Ju]=io($e),[tt]=se($e,[Ju,Me]),cn=Me(),[ed,Ae]=tt($e),[td,nd]=tt($e),cs=e=>{const{__scopeSelect:t,children:n,open:o,defaultOpen:r,onOpenChange:s,value:i,defaultValue:a,onValueChange:l,dir:d,name:u,autoComplete:f,disabled:v,required:m,form:g}=e,h=cn(t),[x,w]=c.useState(null),[y,C]=c.useState(null),[b,E]=c.useState(!1),P=gt(d),[S,_]=Ee({prop:o,defaultProp:r??!1,onChange:s,caller:$e}),[M,A]=Ee({prop:i,defaultProp:a,onChange:l,caller:$e}),L=c.useRef(null),$=x?g||!!x.closest("form"):!0,[F,k]=c.useState(new Set),G=Array.from(F).map(D=>D.props.value).join(";");return p.jsx(qt,{...h,children:p.jsxs(ed,{required:m,scope:t,trigger:x,onTriggerChange:w,valueNode:y,onValueNodeChange:C,valueNodeHasChildren:b,onValueNodeHasChildrenChange:E,contentId:ae(),value:M,onValueChange:A,open:S,onOpenChange:_,dir:P,triggerPointerDownPosRef:L,disabled:v,children:[p.jsx(sn.Provider,{scope:t,children:p.jsx(td,{scope:e.__scopeSelect,onNativeOptionAdd:c.useCallback(D=>{k(B=>new Set(B).add(D))},[]),onNativeOptionRemove:c.useCallback(D=>{k(B=>{const I=new Set(B);return I.delete(D),I})},[]),children:n})}),$?p.jsxs(Os,{"aria-hidden":!0,required:m,tabIndex:-1,name:u,autoComplete:f,value:M,onChange:D=>A(D.target.value),disabled:v,form:g,children:[M===void 0?p.jsx("option",{value:""}):null,Array.from(F)]},G):null]})})};cs.displayName=$e;var ls="SelectTrigger",us=c.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:o=!1,...r}=e,s=cn(n),i=Ae(ls,n),a=i.disabled||o,l=j(t,i.onTriggerChange),d=an(n),u=c.useRef("touch"),[f,v,m]=Ls(h=>{const x=d().filter(C=>!C.disabled),w=x.find(C=>C.value===i.value),y=js(x,h,w);y!==void 0&&i.onValueChange(y.value)}),g=h=>{a||(i.onOpenChange(!0),m()),h&&(i.triggerPointerDownPosRef.current={x:Math.round(h.pageX),y:Math.round(h.pageY)})};return p.jsx(pt,{asChild:!0,...s,children:p.jsx(O.button,{type:"button",role:"combobox","aria-controls":i.contentId,"aria-expanded":i.open,"aria-required":i.required,"aria-autocomplete":"none",dir:i.dir,"data-state":i.open?"open":"closed",disabled:a,"data-disabled":a?"":void 0,"data-placeholder":Ds(i.value)?"":void 0,...r,ref:l,onClick:R(r.onClick,h=>{h.currentTarget.focus(),u.current!=="mouse"&&g(h)}),onPointerDown:R(r.onPointerDown,h=>{u.current=h.pointerType;const x=h.target;x.hasPointerCapture(h.pointerId)&&x.releasePointerCapture(h.pointerId),h.button===0&&h.ctrlKey===!1&&h.pointerType==="mouse"&&(g(h),h.preventDefault())}),onKeyDown:R(r.onKeyDown,h=>{const x=f.current!=="";!(h.ctrlKey||h.altKey||h.metaKey)&&h.key.length===1&&v(h.key),!(x&&h.key===" ")&&Zu.includes(h.key)&&(g(),h.preventDefault())})})})});us.displayName=ls;var ds="SelectValue",fs=c.forwardRef((e,t)=>{const{__scopeSelect:n,className:o,style:r,children:s,placeholder:i="",...a}=e,l=Ae(ds,n),{onValueNodeHasChildrenChange:d}=l,u=s!==void 0,f=j(t,l.onValueNodeChange);return q(()=>{d(u)},[d,u]),p.jsx(O.span,{...a,ref:f,style:{pointerEvents:"none"},children:Ds(l.value)?p.jsx(p.Fragment,{children:i}):s})});fs.displayName=ds;var od="SelectIcon",ps=c.forwardRef((e,t)=>{const{__scopeSelect:n,children:o,...r}=e;return p.jsx(O.span,{"aria-hidden":!0,...r,ref:t,children:o||"▼"})});ps.displayName=od;var rd="SelectPortal",vs=e=>p.jsx(et,{asChild:!0,...e});vs.displayName=rd;var Fe="SelectContent",hs=c.forwardRef((e,t)=>{const n=Ae(Fe,e.__scopeSelect),[o,r]=c.useState();if(q(()=>{r(new DocumentFragment)},[]),!n.open){const s=o;return s?Gt.createPortal(p.jsx(ms,{scope:e.__scopeSelect,children:p.jsx(sn.Slot,{scope:e.__scopeSelect,children:p.jsx("div",{children:e.children})})}),s):null}return p.jsx(gs,{...e,ref:t})});hs.displayName=Fe;var ue=10,[ms,Ie]=tt(Fe),sd="SelectContentImpl",id=Le("SelectContent.RemoveScroll"),gs=c.forwardRef((e,t)=>{const{__scopeSelect:n,position:o="item-aligned",onCloseAutoFocus:r,onEscapeKeyDown:s,onPointerDownOutside:i,side:a,sideOffset:l,align:d,alignOffset:u,arrowPadding:f,collisionBoundary:v,collisionPadding:m,sticky:g,hideWhenDetached:h,avoidCollisions:x,...w}=e,y=Ae(Fe,n),[C,b]=c.useState(null),[E,P]=c.useState(null),S=j(t,N=>b(N)),[_,M]=c.useState(null),[A,L]=c.useState(null),$=an(n),[F,k]=c.useState(!1),G=c.useRef(!1);c.useEffect(()=>{if(C)return on(C)},[C]),tn();const D=c.useCallback(N=>{const[H,...z]=$().map(U=>U.ref.current),[W]=z.slice(-1),V=document.activeElement;for(const U of N)if(U===V||(U==null||U.scrollIntoView({block:"nearest"}),U===H&&E&&(E.scrollTop=0),U===W&&E&&(E.scrollTop=E.scrollHeight),U==null||U.focus(),document.activeElement!==V))return},[$,E]),B=c.useCallback(()=>D([_,C]),[D,_,C]);c.useEffect(()=>{F&&B()},[F,B]);const{onOpenChange:I,triggerPointerDownPosRef:T}=y;c.useEffect(()=>{if(C){let N={x:0,y:0};const H=W=>{var V,U;N={x:Math.abs(Math.round(W.pageX)-(((V=T.current)==null?void 0:V.x)??0)),y:Math.abs(Math.round(W.pageY)-(((U=T.current)==null?void 0:U.y)??0))}},z=W=>{N.x<=10&&N.y<=10?W.preventDefault():C.contains(W.target)||I(!1),document.removeEventListener("pointermove",H),T.current=null};return T.current!==null&&(document.addEventListener("pointermove",H),document.addEventListener("pointerup",z,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",H),document.removeEventListener("pointerup",z,{capture:!0})}}},[C,I,T]),c.useEffect(()=>{const N=()=>I(!1);return window.addEventListener("blur",N),window.addEventListener("resize",N),()=>{window.removeEventListener("blur",N),window.removeEventListener("resize",N)}},[I]);const[K,Y]=Ls(N=>{const H=$().filter(V=>!V.disabled),z=H.find(V=>V.ref.current===document.activeElement),W=js(H,N,z);W&&setTimeout(()=>W.ref.current.focus())}),ee=c.useCallback((N,H,z)=>{const W=!G.current&&!z;(y.value!==void 0&&y.value===H||W)&&(M(N),W&&(G.current=!0))},[y.value]),ye=c.useCallback(()=>C==null?void 0:C.focus(),[C]),ie=c.useCallback((N,H,z)=>{const W=!G.current&&!z;(y.value!==void 0&&y.value===H||W)&&L(N)},[y.value]),Ce=o==="popper"?Fn:xs,te=Ce===Fn?{side:a,sideOffset:l,align:d,alignOffset:u,arrowPadding:f,collisionBoundary:v,collisionPadding:m,sticky:g,hideWhenDetached:h,avoidCollisions:x}:{};return p.jsx(ms,{scope:n,content:C,viewport:E,onViewportChange:P,itemRefCallback:ee,selectedItem:_,onItemLeave:ye,itemTextRefCallback:ie,focusSelectedItem:B,selectedItemText:A,position:o,isPositioned:F,searchRef:K,children:p.jsx(mt,{as:id,allowPinchZoom:!0,children:p.jsx(ht,{asChild:!0,trapped:y.open,onMountAutoFocus:N=>{N.preventDefault()},onUnmountAutoFocus:R(r,N=>{var H;(H=y.trigger)==null||H.focus({preventScroll:!0}),N.preventDefault()}),children:p.jsx(Ze,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:s,onPointerDownOutside:i,onFocusOutside:N=>N.preventDefault(),onDismiss:()=>y.onOpenChange(!1),children:p.jsx(Ce,{role:"listbox",id:y.contentId,"data-state":y.open?"open":"closed",dir:y.dir,onContextMenu:N=>N.preventDefault(),...w,...te,onPlaced:()=>k(!0),ref:S,style:{display:"flex",flexDirection:"column",outline:"none",...w.style},onKeyDown:R(w.onKeyDown,N=>{const H=N.ctrlKey||N.altKey||N.metaKey;if(N.key==="Tab"&&N.preventDefault(),!H&&N.key.length===1&&Y(N.key),["ArrowUp","ArrowDown","Home","End"].includes(N.key)){let W=$().filter(V=>!V.disabled).map(V=>V.ref.current);if(["ArrowUp","End"].includes(N.key)&&(W=W.slice().reverse()),["ArrowUp","ArrowDown"].includes(N.key)){const V=N.target,U=W.indexOf(V);W=W.slice(U+1)}setTimeout(()=>D(W)),N.preventDefault()}})})})})})})});gs.displayName=sd;var ad="SelectItemAlignedPosition",xs=c.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:o,...r}=e,s=Ae(Fe,n),i=Ie(Fe,n),[a,l]=c.useState(null),[d,u]=c.useState(null),f=j(t,S=>u(S)),v=an(n),m=c.useRef(!1),g=c.useRef(!0),{viewport:h,selectedItem:x,selectedItemText:w,focusSelectedItem:y}=i,C=c.useCallback(()=>{if(s.trigger&&s.valueNode&&a&&d&&h&&x&&w){const S=s.trigger.getBoundingClientRect(),_=d.getBoundingClientRect(),M=s.valueNode.getBoundingClientRect(),A=w.getBoundingClientRect();if(s.dir!=="rtl"){const V=A.left-_.left,U=M.left-V,ne=S.left-U,ve=S.width+ne,nt=Math.max(ve,_.width),ot=window.innerWidth-ue,rt=$n(U,[ue,Math.max(ue,ot-nt)]);a.style.minWidth=ve+"px",a.style.left=rt+"px"}else{const V=_.right-A.right,U=window.innerWidth-M.right-V,ne=window.innerWidth-S.right-U,ve=S.width+ne,nt=Math.max(ve,_.width),ot=window.innerWidth-ue,rt=$n(U,[ue,Math.max(ue,ot-nt)]);a.style.minWidth=ve+"px",a.style.right=rt+"px"}const L=v(),$=window.innerHeight-ue*2,F=h.scrollHeight,k=window.getComputedStyle(d),G=parseInt(k.borderTopWidth,10),D=parseInt(k.paddingTop,10),B=parseInt(k.borderBottomWidth,10),I=parseInt(k.paddingBottom,10),T=G+D+F+I+B,K=Math.min(x.offsetHeight*5,T),Y=window.getComputedStyle(h),ee=parseInt(Y.paddingTop,10),ye=parseInt(Y.paddingBottom,10),ie=S.top+S.height/2-ue,Ce=$-ie,te=x.offsetHeight/2,N=x.offsetTop+te,H=G+D+N,z=T-H;if(H<=ie){const V=L.length>0&&x===L[L.length-1].ref.current;a.style.bottom="0px";const U=d.clientHeight-h.offsetTop-h.offsetHeight,ne=Math.max(Ce,te+(V?ye:0)+U+B),ve=H+ne;a.style.height=ve+"px"}else{const V=L.length>0&&x===L[0].ref.current;a.style.top="0px";const ne=Math.max(ie,G+h.offsetTop+(V?ee:0)+te)+z;a.style.height=ne+"px",h.scrollTop=H-ie+h.offsetTop}a.style.margin=`${ue}px 0`,a.style.minHeight=K+"px",a.style.maxHeight=$+"px",o==null||o(),requestAnimationFrame(()=>m.current=!0)}},[v,s.trigger,s.valueNode,a,d,h,x,w,s.dir,o]);q(()=>C(),[C]);const[b,E]=c.useState();q(()=>{d&&E(window.getComputedStyle(d).zIndex)},[d]);const P=c.useCallback(S=>{S&&g.current===!0&&(C(),y==null||y(),g.current=!1)},[C,y]);return p.jsx(ld,{scope:n,contentWrapper:a,shouldExpandOnScrollRef:m,onScrollButtonChange:P,children:p.jsx("div",{ref:l,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:b},children:p.jsx(O.div,{...r,ref:f,style:{boxSizing:"border-box",maxHeight:"100%",...r.style}})})})});xs.displayName=ad;var cd="SelectPopperPosition",Fn=c.forwardRef((e,t)=>{const{__scopeSelect:n,align:o="start",collisionPadding:r=ue,...s}=e,i=cn(n);return p.jsx(Zt,{...i,...s,ref:t,align:o,collisionPadding:r,style:{boxSizing:"border-box",...s.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});Fn.displayName=cd;var[ld,ao]=tt(Fe,{}),Bn="SelectViewport",ws=c.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:o,...r}=e,s=Ie(Bn,n),i=ao(Bn,n),a=j(t,s.onViewportChange),l=c.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(sn.Slot,{scope:n,children:p.jsx(O.div,{"data-radix-select-viewport":"",role:"presentation",...r,ref:a,style:{position:"relative",flex:1,overflow:"hidden auto",...r.style},onScroll:R(r.onScroll,d=>{const u=d.currentTarget,{contentWrapper:f,shouldExpandOnScrollRef:v}=i;if(v!=null&&v.current&&f){const m=Math.abs(l.current-u.scrollTop);if(m>0){const g=window.innerHeight-ue*2,h=parseFloat(f.style.minHeight),x=parseFloat(f.style.height),w=Math.max(h,x);if(w<g){const y=w+m,C=Math.min(g,y),b=y-C;f.style.height=C+"px",f.style.bottom==="0px"&&(u.scrollTop=b>0?b:0,f.style.justifyContent="flex-end")}}}l.current=u.scrollTop})})})]})});ws.displayName=Bn;var ys="SelectGroup",[ud,dd]=tt(ys),Cs=c.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e,r=ae();return p.jsx(ud,{scope:n,id:r,children:p.jsx(O.div,{role:"group","aria-labelledby":r,...o,ref:t})})});Cs.displayName=ys;var bs="SelectLabel",Ss=c.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e,r=dd(bs,n);return p.jsx(O.div,{id:r.id,...o,ref:t})});Ss.displayName=bs;var $t="SelectItem",[fd,Es]=tt($t),Rs=c.forwardRef((e,t)=>{const{__scopeSelect:n,value:o,disabled:r=!1,textValue:s,...i}=e,a=Ae($t,n),l=Ie($t,n),d=a.value===o,[u,f]=c.useState(s??""),[v,m]=c.useState(!1),g=j(t,y=>{var C;return(C=l.itemRefCallback)==null?void 0:C.call(l,y,o,r)}),h=ae(),x=c.useRef("touch"),w=()=>{r||(a.onValueChange(o),a.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(fd,{scope:n,value:o,disabled:r,textId:h,isSelected:d,onItemTextChange:c.useCallback(y=>{f(C=>C||((y==null?void 0:y.textContent)??"").trim())},[]),children:p.jsx(sn.ItemSlot,{scope:n,value:o,disabled:r,textValue:u,children:p.jsx(O.div,{role:"option","aria-labelledby":h,"data-highlighted":v?"":void 0,"aria-selected":d&&v,"data-state":d?"checked":"unchecked","aria-disabled":r||void 0,"data-disabled":r?"":void 0,tabIndex:r?void 0:-1,...i,ref:g,onFocus:R(i.onFocus,()=>m(!0)),onBlur:R(i.onBlur,()=>m(!1)),onClick:R(i.onClick,()=>{x.current!=="mouse"&&w()}),onPointerUp:R(i.onPointerUp,()=>{x.current==="mouse"&&w()}),onPointerDown:R(i.onPointerDown,y=>{x.current=y.pointerType}),onPointerMove:R(i.onPointerMove,y=>{var C;x.current=y.pointerType,r?(C=l.onItemLeave)==null||C.call(l):x.current==="mouse"&&y.currentTarget.focus({preventScroll:!0})}),onPointerLeave:R(i.onPointerLeave,y=>{var C;y.currentTarget===document.activeElement&&((C=l.onItemLeave)==null||C.call(l))}),onKeyDown:R(i.onKeyDown,y=>{var b;((b=l.searchRef)==null?void 0:b.current)!==""&&y.key===" "||(Qu.includes(y.key)&&w(),y.key===" "&&y.preventDefault())})})})})});Rs.displayName=$t;var st="SelectItemText",Ps=c.forwardRef((e,t)=>{const{__scopeSelect:n,className:o,style:r,...s}=e,i=Ae(st,n),a=Ie(st,n),l=Es(st,n),d=nd(st,n),[u,f]=c.useState(null),v=j(t,w=>f(w),l.onItemTextChange,w=>{var y;return(y=a.itemTextRefCallback)==null?void 0:y.call(a,w,l.value,l.disabled)}),m=u==null?void 0:u.textContent,g=c.useMemo(()=>p.jsx("option",{value:l.value,disabled:l.disabled,children:m},l.value),[l.disabled,l.value,m]),{onNativeOptionAdd:h,onNativeOptionRemove:x}=d;return q(()=>(h(g),()=>x(g)),[h,x,g]),p.jsxs(p.Fragment,{children:[p.jsx(O.span,{id:l.textId,...s,ref:v}),l.isSelected&&i.valueNode&&!i.valueNodeHasChildren?Gt.createPortal(s.children,i.valueNode):null]})});Ps.displayName=st;var Ts="SelectItemIndicator",_s=c.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e;return Es(Ts,n).isSelected?p.jsx(O.span,{"aria-hidden":!0,...o,ref:t}):null});_s.displayName=Ts;var Wn="SelectScrollUpButton",Ms=c.forwardRef((e,t)=>{const n=Ie(Wn,e.__scopeSelect),o=ao(Wn,e.__scopeSelect),[r,s]=c.useState(!1),i=j(t,o.onScrollButtonChange);return q(()=>{if(n.viewport&&n.isPositioned){let a=function(){const d=l.scrollTop>0;s(d)};const l=n.viewport;return a(),l.addEventListener("scroll",a),()=>l.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),r?p.jsx(Is,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:l}=n;a&&l&&(a.scrollTop=a.scrollTop-l.offsetHeight)}}):null});Ms.displayName=Wn;var Hn="SelectScrollDownButton",As=c.forwardRef((e,t)=>{const n=Ie(Hn,e.__scopeSelect),o=ao(Hn,e.__scopeSelect),[r,s]=c.useState(!1),i=j(t,o.onScrollButtonChange);return q(()=>{if(n.viewport&&n.isPositioned){let a=function(){const d=l.scrollHeight-l.clientHeight,u=Math.ceil(l.scrollTop)<d;s(u)};const l=n.viewport;return a(),l.addEventListener("scroll",a),()=>l.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),r?p.jsx(Is,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:l}=n;a&&l&&(a.scrollTop=a.scrollTop+l.offsetHeight)}}):null});As.displayName=Hn;var Is=c.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:o,...r}=e,s=Ie("SelectScrollButton",n),i=c.useRef(null),a=an(n),l=c.useCallback(()=>{i.current!==null&&(window.clearInterval(i.current),i.current=null)},[]);return c.useEffect(()=>()=>l(),[l]),q(()=>{var u;const d=a().find(f=>f.ref.current===document.activeElement);(u=d==null?void 0:d.ref.current)==null||u.scrollIntoView({block:"nearest"})},[a]),p.jsx(O.div,{"aria-hidden":!0,...r,ref:t,style:{flexShrink:0,...r.style},onPointerDown:R(r.onPointerDown,()=>{i.current===null&&(i.current=window.setInterval(o,50))}),onPointerMove:R(r.onPointerMove,()=>{var d;(d=s.onItemLeave)==null||d.call(s),i.current===null&&(i.current=window.setInterval(o,50))}),onPointerLeave:R(r.onPointerLeave,()=>{l()})})}),pd="SelectSeparator",Ns=c.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e;return p.jsx(O.div,{"aria-hidden":!0,...o,ref:t})});Ns.displayName=pd;var Vn="SelectArrow",vd=c.forwardRef((e,t)=>{const{__scopeSelect:n,...o}=e,r=cn(n),s=Ae(Vn,n),i=Ie(Vn,n);return s.open&&i.position==="popper"?p.jsx(Qt,{...r,...o,ref:t}):null});vd.displayName=Vn;var hd="SelectBubbleInput",Os=c.forwardRef(({__scopeSelect:e,value:t,...n},o)=>{const r=c.useRef(null),s=j(o,r),i=as(t);return c.useEffect(()=>{const a=r.current;if(!a)return;const l=window.HTMLSelectElement.prototype,u=Object.getOwnPropertyDescriptor(l,"value").set;if(i!==t&&u){const f=new Event("change",{bubbles:!0});u.call(a,t),a.dispatchEvent(f)}},[i,t]),p.jsx(O.select,{...n,style:{...Rr,...n.style},ref:s,defaultValue:t})});Os.displayName=hd;function Ds(e){return e===""||e===void 0}function Ls(e){const t=X(e),n=c.useRef(""),o=c.useRef(0),r=c.useCallback(i=>{const a=n.current+i;t(a),function l(d){n.current=d,window.clearTimeout(o.current),d!==""&&(o.current=window.setTimeout(()=>l(""),1e3))}(a)},[t]),s=c.useCallback(()=>{n.current="",window.clearTimeout(o.current)},[]);return c.useEffect(()=>()=>window.clearTimeout(o.current),[]),[n,r,s]}function js(e,t,n){const r=t.length>1&&Array.from(t).every(d=>d===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let i=md(e,Math.max(s,0));r.length===1&&(i=i.filter(d=>d!==n));const l=i.find(d=>d.textValue.toLowerCase().startsWith(r.toLowerCase()));return l!==n?l:void 0}function md(e,t){return e.map((n,o)=>e[(t+o)%e.length])}var zp=cs,Yp=us,Xp=fs,qp=ps,Zp=vs,Qp=hs,Jp=ws,ev=Cs,tv=Ss,nv=Rs,ov=Ps,rv=_s,sv=Ms,iv=As,av=Ns,gd=Symbol.for("react.lazy"),Ft=Kn[" use ".trim().toString()];function xd(e){return typeof e=="object"&&e!==null&&"then"in e}function ks(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===gd&&"_payload"in e&&xd(e._payload)}function $s(e){const t=wd(e),n=c.forwardRef((o,r)=>{let{children:s,...i}=o;ks(s)&&typeof Ft=="function"&&(s=Ft(s._payload));const a=c.Children.toArray(s),l=a.find(Cd);if(l){const d=l.props.children,u=a.map(f=>f===l?c.Children.count(d)>1?c.Children.only(null):c.isValidElement(d)?d.props.children:null:f);return p.jsx(t,{...i,ref:r,children:c.isValidElement(d)?c.cloneElement(d,void 0,u):null})}return p.jsx(t,{...i,ref:r,children:s})});return n.displayName=`${e}.Slot`,n}var cv=$s("Slot");function wd(e){const t=c.forwardRef((n,o)=>{let{children:r,...s}=n;if(ks(r)&&typeof Ft=="function"&&(r=Ft(r._payload)),c.isValidElement(r)){const i=Sd(r),a=bd(s,r.props);return r.type!==c.Fragment&&(a.ref=o?dt(o,i):i),c.cloneElement(r,a)}return c.Children.count(r)>1?c.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var yd=Symbol("radix.slottable");function Cd(e){return c.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===yd}function bd(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]=(...a)=>{const l=s(...a);return r(...a),l}:r&&(n[o]=r):o==="style"?n[o]={...r,...s}:o==="className"&&(n[o]=[r,s].filter(Boolean).join(" "))}return{...e,...n}}function Sd(e){var o,r;let t=(o=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(r=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Ed=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],ln=Ed.reduce((e,t)=>{const n=$s(`Primitive.${t}`),o=c.forwardRef((r,s)=>{const{asChild:i,...a}=r,l=i?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...a,ref:s})});return o.displayName=`Primitive.${t}`,{...e,[t]:o}},{}),Rd="Label",Fs=c.forwardRef((e,t)=>p.jsx(ln.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())}}));Fs.displayName=Rd;var lv=Fs,An="rovingFocusGroup.onEntryFocus",Pd={bubbles:!1,cancelable:!0},xt="RovingFocusGroup",[Un,Bs,Td]=io(xt),[_d,un]=se(xt,[Td]),[Md,Ad]=_d(xt),Ws=c.forwardRef((e,t)=>p.jsx(Un.Provider,{scope:e.__scopeRovingFocusGroup,children:p.jsx(Un.Slot,{scope:e.__scopeRovingFocusGroup,children:p.jsx(Id,{...e,ref:t})})}));Ws.displayName=xt;var Id=c.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:o,loop:r=!1,dir:s,currentTabStopId:i,defaultCurrentTabStopId:a,onCurrentTabStopIdChange:l,onEntryFocus:d,preventScrollOnEntryFocus:u=!1,...f}=e,v=c.useRef(null),m=j(t,v),g=gt(s),[h,x]=Ee({prop:i,defaultProp:a??null,onChange:l,caller:xt}),[w,y]=c.useState(!1),C=X(d),b=Bs(n),E=c.useRef(!1),[P,S]=c.useState(0);return c.useEffect(()=>{const _=v.current;if(_)return _.addEventListener(An,C),()=>_.removeEventListener(An,C)},[C]),p.jsx(Md,{scope:n,orientation:o,dir:g,loop:r,currentTabStopId:h,onItemFocus:c.useCallback(_=>x(_),[x]),onItemShiftTab:c.useCallback(()=>y(!0),[]),onFocusableItemAdd:c.useCallback(()=>S(_=>_+1),[]),onFocusableItemRemove:c.useCallback(()=>S(_=>_-1),[]),children:p.jsx(O.div,{tabIndex:w||P===0?-1:0,"data-orientation":o,...f,ref:m,style:{outline:"none",...e.style},onMouseDown:R(e.onMouseDown,()=>{E.current=!0}),onFocus:R(e.onFocus,_=>{const M=!E.current;if(_.target===_.currentTarget&&M&&!w){const A=new CustomEvent(An,Pd);if(_.currentTarget.dispatchEvent(A),!A.defaultPrevented){const L=b().filter(D=>D.focusable),$=L.find(D=>D.active),F=L.find(D=>D.id===h),G=[$,F,...L].filter(Boolean).map(D=>D.ref.current);Us(G,u)}}E.current=!1}),onBlur:R(e.onBlur,()=>y(!1))})})}),Hs="RovingFocusGroupItem",Vs=c.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:o=!0,active:r=!1,tabStopId:s,children:i,...a}=e,l=ae(),d=s||l,u=Ad(Hs,n),f=u.currentTabStopId===d,v=Bs(n),{onFocusableItemAdd:m,onFocusableItemRemove:g,currentTabStopId:h}=u;return c.useEffect(()=>{if(o)return m(),()=>g()},[o,m,g]),p.jsx(Un.ItemSlot,{scope:n,id:d,focusable:o,active:r,children:p.jsx(O.span,{tabIndex:f?0:-1,"data-orientation":u.orientation,...a,ref:t,onMouseDown:R(e.onMouseDown,x=>{o?u.onItemFocus(d):x.preventDefault()}),onFocus:R(e.onFocus,()=>u.onItemFocus(d)),onKeyDown:R(e.onKeyDown,x=>{if(x.key==="Tab"&&x.shiftKey){u.onItemShiftTab();return}if(x.target!==x.currentTarget)return;const w=Dd(x,u.orientation,u.dir);if(w!==void 0){if(x.metaKey||x.ctrlKey||x.altKey||x.shiftKey)return;x.preventDefault();let C=v().filter(b=>b.focusable).map(b=>b.ref.current);if(w==="last")C.reverse();else if(w==="prev"||w==="next"){w==="prev"&&C.reverse();const b=C.indexOf(x.currentTarget);C=u.loop?Ld(C,b+1):C.slice(b+1)}setTimeout(()=>Us(C))}}),children:typeof i=="function"?i({isCurrentTabStop:f,hasTabStop:h!=null}):i})})});Vs.displayName=Hs;var Nd={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Od(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function Dd(e,t,n){const o=Od(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(o))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(o)))return Nd[o]}function Us(e,t=!1){const n=document.activeElement;for(const o of e)if(o===n||(o.focus({preventScroll:t}),document.activeElement!==n))return}function Ld(e,t){return e.map((n,o)=>e[(t+o)%e.length])}var Gs=Ws,Ks=Vs,Gn=["Enter"," "],jd=["ArrowDown","PageUp","Home"],zs=["ArrowUp","PageDown","End"],kd=[...jd,...zs],$d={ltr:[...Gn,"ArrowRight"],rtl:[...Gn,"ArrowLeft"]},Fd={ltr:["ArrowLeft"],rtl:["ArrowRight"]},wt="Menu",[lt,Bd,Wd]=io(wt),[Be,dn]=se(wt,[Wd,Me,un]),fn=Me(),Ys=un(),[Hd,We]=Be(wt),[Vd,yt]=Be(wt),Xs=e=>{const{__scopeMenu:t,open:n=!1,children:o,dir:r,onOpenChange:s,modal:i=!0}=e,a=fn(t),[l,d]=c.useState(null),u=c.useRef(!1),f=X(s),v=gt(r);return c.useEffect(()=>{const m=()=>{u.current=!0,document.addEventListener("pointerdown",g,{capture:!0,once:!0}),document.addEventListener("pointermove",g,{capture:!0,once:!0})},g=()=>u.current=!1;return document.addEventListener("keydown",m,{capture:!0}),()=>{document.removeEventListener("keydown",m,{capture:!0}),document.removeEventListener("pointerdown",g,{capture:!0}),document.removeEventListener("pointermove",g,{capture:!0})}},[]),p.jsx(qt,{...a,children:p.jsx(Hd,{scope:t,open:n,onOpenChange:f,content:l,onContentChange:d,children:p.jsx(Vd,{scope:t,onClose:c.useCallback(()=>f(!1),[f]),isUsingKeyboardRef:u,dir:v,modal:i,children:o})})})};Xs.displayName=wt;var Ud="MenuAnchor",co=c.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e,r=fn(n);return p.jsx(pt,{...r,...o,ref:t})});co.displayName=Ud;var lo="MenuPortal",[Gd,qs]=Be(lo,{forceMount:void 0}),Zs=e=>{const{__scopeMenu:t,forceMount:n,children:o,container:r}=e,s=We(lo,t);return p.jsx(Gd,{scope:t,forceMount:n,children:p.jsx(Z,{present:n||s.open,children:p.jsx(et,{asChild:!0,container:r,children:o})})})};Zs.displayName=lo;var ce="MenuContent",[Kd,uo]=Be(ce),Qs=c.forwardRef((e,t)=>{const n=qs(ce,e.__scopeMenu),{forceMount:o=n.forceMount,...r}=e,s=We(ce,e.__scopeMenu),i=yt(ce,e.__scopeMenu);return p.jsx(lt.Provider,{scope:e.__scopeMenu,children:p.jsx(Z,{present:o||s.open,children:p.jsx(lt.Slot,{scope:e.__scopeMenu,children:i.modal?p.jsx(zd,{...r,ref:t}):p.jsx(Yd,{...r,ref:t})})})})}),zd=c.forwardRef((e,t)=>{const n=We(ce,e.__scopeMenu),o=c.useRef(null),r=j(t,o);return c.useEffect(()=>{const s=o.current;if(s)return on(s)},[]),p.jsx(fo,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:R(e.onFocusOutside,s=>s.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),Yd=c.forwardRef((e,t)=>{const n=We(ce,e.__scopeMenu);return p.jsx(fo,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),Xd=Le("MenuContent.ScrollLock"),fo=c.forwardRef((e,t)=>{const{__scopeMenu:n,loop:o=!1,trapFocus:r,onOpenAutoFocus:s,onCloseAutoFocus:i,disableOutsidePointerEvents:a,onEntryFocus:l,onEscapeKeyDown:d,onPointerDownOutside:u,onFocusOutside:f,onInteractOutside:v,onDismiss:m,disableOutsideScroll:g,...h}=e,x=We(ce,n),w=yt(ce,n),y=fn(n),C=Ys(n),b=Bd(n),[E,P]=c.useState(null),S=c.useRef(null),_=j(t,S,x.onContentChange),M=c.useRef(0),A=c.useRef(""),L=c.useRef(0),$=c.useRef(null),F=c.useRef("right"),k=c.useRef(0),G=g?mt:c.Fragment,D=g?{as:Xd,allowPinchZoom:!0}:void 0,B=T=>{var N,H;const K=A.current+T,Y=b().filter(z=>!z.disabled),ee=document.activeElement,ye=(N=Y.find(z=>z.ref.current===ee))==null?void 0:N.textValue,ie=Y.map(z=>z.textValue),Ce=cf(ie,K,ye),te=(H=Y.find(z=>z.textValue===Ce))==null?void 0:H.ref.current;(function z(W){A.current=W,window.clearTimeout(M.current),W!==""&&(M.current=window.setTimeout(()=>z(""),1e3))})(K),te&&setTimeout(()=>te.focus())};c.useEffect(()=>()=>window.clearTimeout(M.current),[]),tn();const I=c.useCallback(T=>{var Y,ee;return F.current===((Y=$.current)==null?void 0:Y.side)&&uf(T,(ee=$.current)==null?void 0:ee.area)},[]);return p.jsx(Kd,{scope:n,searchRef:A,onItemEnter:c.useCallback(T=>{I(T)&&T.preventDefault()},[I]),onItemLeave:c.useCallback(T=>{var K;I(T)||((K=S.current)==null||K.focus(),P(null))},[I]),onTriggerLeave:c.useCallback(T=>{I(T)&&T.preventDefault()},[I]),pointerGraceTimerRef:L,onPointerGraceIntentChange:c.useCallback(T=>{$.current=T},[]),children:p.jsx(G,{...D,children:p.jsx(ht,{asChild:!0,trapped:r,onMountAutoFocus:R(s,T=>{var K;T.preventDefault(),(K=S.current)==null||K.focus({preventScroll:!0})}),onUnmountAutoFocus:i,children:p.jsx(Ze,{asChild:!0,disableOutsidePointerEvents:a,onEscapeKeyDown:d,onPointerDownOutside:u,onFocusOutside:f,onInteractOutside:v,onDismiss:m,children:p.jsx(Gs,{asChild:!0,...C,dir:w.dir,orientation:"vertical",loop:o,currentTabStopId:E,onCurrentTabStopIdChange:P,onEntryFocus:R(l,T=>{w.isUsingKeyboardRef.current||T.preventDefault()}),preventScrollOnEntryFocus:!0,children:p.jsx(Zt,{role:"menu","aria-orientation":"vertical","data-state":vi(x.open),"data-radix-menu-content":"",dir:w.dir,...y,...h,ref:_,style:{outline:"none",...h.style},onKeyDown:R(h.onKeyDown,T=>{const Y=T.target.closest("[data-radix-menu-content]")===T.currentTarget,ee=T.ctrlKey||T.altKey||T.metaKey,ye=T.key.length===1;Y&&(T.key==="Tab"&&T.preventDefault(),!ee&&ye&&B(T.key));const ie=S.current;if(T.target!==ie||!kd.includes(T.key))return;T.preventDefault();const te=b().filter(N=>!N.disabled).map(N=>N.ref.current);zs.includes(T.key)&&te.reverse(),sf(te)}),onBlur:R(e.onBlur,T=>{T.currentTarget.contains(T.target)||(window.clearTimeout(M.current),A.current="")}),onPointerMove:R(e.onPointerMove,ut(T=>{const K=T.target,Y=k.current!==T.clientX;if(T.currentTarget.contains(K)&&Y){const ee=T.clientX>k.current?"right":"left";F.current=ee,k.current=T.clientX}}))})})})})})})});Qs.displayName=ce;var qd="MenuGroup",po=c.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e;return p.jsx(O.div,{role:"group",...o,ref:t})});po.displayName=qd;var Zd="MenuLabel",Js=c.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e;return p.jsx(O.div,{...o,ref:t})});Js.displayName=Zd;var Bt="MenuItem",Yo="menu.itemSelect",pn=c.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:o,...r}=e,s=c.useRef(null),i=yt(Bt,e.__scopeMenu),a=uo(Bt,e.__scopeMenu),l=j(t,s),d=c.useRef(!1),u=()=>{const f=s.current;if(!n&&f){const v=new CustomEvent(Yo,{bubbles:!0,cancelable:!0});f.addEventListener(Yo,m=>o==null?void 0:o(m),{once:!0}),er(f,v),v.defaultPrevented?d.current=!1:i.onClose()}};return p.jsx(ei,{...r,ref:l,disabled:n,onClick:R(e.onClick,u),onPointerDown:f=>{var v;(v=e.onPointerDown)==null||v.call(e,f),d.current=!0},onPointerUp:R(e.onPointerUp,f=>{var v;d.current||(v=f.currentTarget)==null||v.click()}),onKeyDown:R(e.onKeyDown,f=>{const v=a.searchRef.current!=="";n||v&&f.key===" "||Gn.includes(f.key)&&(f.currentTarget.click(),f.preventDefault())})})});pn.displayName=Bt;var ei=c.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:o=!1,textValue:r,...s}=e,i=uo(Bt,n),a=Ys(n),l=c.useRef(null),d=j(t,l),[u,f]=c.useState(!1),[v,m]=c.useState("");return c.useEffect(()=>{const g=l.current;g&&m((g.textContent??"").trim())},[s.children]),p.jsx(lt.ItemSlot,{scope:n,disabled:o,textValue:r??v,children:p.jsx(Ks,{asChild:!0,...a,focusable:!o,children:p.jsx(O.div,{role:"menuitem","data-highlighted":u?"":void 0,"aria-disabled":o||void 0,"data-disabled":o?"":void 0,...s,ref:d,onPointerMove:R(e.onPointerMove,ut(g=>{o?i.onItemLeave(g):(i.onItemEnter(g),g.defaultPrevented||g.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:R(e.onPointerLeave,ut(g=>i.onItemLeave(g))),onFocus:R(e.onFocus,()=>f(!0)),onBlur:R(e.onBlur,()=>f(!1))})})})}),Qd="MenuCheckboxItem",ti=c.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:o,...r}=e;return p.jsx(ii,{scope:e.__scopeMenu,checked:n,children:p.jsx(pn,{role:"menuitemcheckbox","aria-checked":Wt(n)?"mixed":n,...r,ref:t,"data-state":ho(n),onSelect:R(r.onSelect,()=>o==null?void 0:o(Wt(n)?!0:!n),{checkForDefaultPrevented:!1})})})});ti.displayName=Qd;var ni="MenuRadioGroup",[Jd,ef]=Be(ni,{value:void 0,onValueChange:()=>{}}),oi=c.forwardRef((e,t)=>{const{value:n,onValueChange:o,...r}=e,s=X(o);return p.jsx(Jd,{scope:e.__scopeMenu,value:n,onValueChange:s,children:p.jsx(po,{...r,ref:t})})});oi.displayName=ni;var ri="MenuRadioItem",si=c.forwardRef((e,t)=>{const{value:n,...o}=e,r=ef(ri,e.__scopeMenu),s=n===r.value;return p.jsx(ii,{scope:e.__scopeMenu,checked:s,children:p.jsx(pn,{role:"menuitemradio","aria-checked":s,...o,ref:t,"data-state":ho(s),onSelect:R(o.onSelect,()=>{var i;return(i=r.onValueChange)==null?void 0:i.call(r,n)},{checkForDefaultPrevented:!1})})})});si.displayName=ri;var vo="MenuItemIndicator",[ii,tf]=Be(vo,{checked:!1}),ai=c.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:o,...r}=e,s=tf(vo,n);return p.jsx(Z,{present:o||Wt(s.checked)||s.checked===!0,children:p.jsx(O.span,{...r,ref:t,"data-state":ho(s.checked)})})});ai.displayName=vo;var nf="MenuSeparator",ci=c.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e;return p.jsx(O.div,{role:"separator","aria-orientation":"horizontal",...o,ref:t})});ci.displayName=nf;var of="MenuArrow",li=c.forwardRef((e,t)=>{const{__scopeMenu:n,...o}=e,r=fn(n);return p.jsx(Qt,{...r,...o,ref:t})});li.displayName=of;var rf="MenuSub",[uv,ui]=Be(rf),it="MenuSubTrigger",di=c.forwardRef((e,t)=>{const n=We(it,e.__scopeMenu),o=yt(it,e.__scopeMenu),r=ui(it,e.__scopeMenu),s=uo(it,e.__scopeMenu),i=c.useRef(null),{pointerGraceTimerRef:a,onPointerGraceIntentChange:l}=s,d={__scopeMenu:e.__scopeMenu},u=c.useCallback(()=>{i.current&&window.clearTimeout(i.current),i.current=null},[]);return c.useEffect(()=>u,[u]),c.useEffect(()=>{const f=a.current;return()=>{window.clearTimeout(f),l(null)}},[a,l]),p.jsx(co,{asChild:!0,...d,children:p.jsx(ei,{id:r.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":r.contentId,"data-state":vi(n.open),...e,ref:dt(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:R(e.onPointerMove,ut(f=>{s.onItemEnter(f),!f.defaultPrevented&&!e.disabled&&!n.open&&!i.current&&(s.onPointerGraceIntentChange(null),i.current=window.setTimeout(()=>{n.onOpenChange(!0),u()},100))})),onPointerLeave:R(e.onPointerLeave,ut(f=>{var m,g;u();const v=(m=n.content)==null?void 0:m.getBoundingClientRect();if(v){const h=(g=n.content)==null?void 0:g.dataset.side,x=h==="right",w=x?-5:5,y=v[x?"left":"right"],C=v[x?"right":"left"];s.onPointerGraceIntentChange({area:[{x:f.clientX+w,y:f.clientY},{x:y,y:v.top},{x:C,y:v.top},{x:C,y:v.bottom},{x:y,y:v.bottom}],side:h}),window.clearTimeout(a.current),a.current=window.setTimeout(()=>s.onPointerGraceIntentChange(null),300)}else{if(s.onTriggerLeave(f),f.defaultPrevented)return;s.onPointerGraceIntentChange(null)}})),onKeyDown:R(e.onKeyDown,f=>{var m;const v=s.searchRef.current!=="";e.disabled||v&&f.key===" "||$d[o.dir].includes(f.key)&&(n.onOpenChange(!0),(m=n.content)==null||m.focus(),f.preventDefault())})})})});di.displayName=it;var fi="MenuSubContent",pi=c.forwardRef((e,t)=>{const n=qs(ce,e.__scopeMenu),{forceMount:o=n.forceMount,...r}=e,s=We(ce,e.__scopeMenu),i=yt(ce,e.__scopeMenu),a=ui(fi,e.__scopeMenu),l=c.useRef(null),d=j(t,l);return p.jsx(lt.Provider,{scope:e.__scopeMenu,children:p.jsx(Z,{present:o||s.open,children:p.jsx(lt.Slot,{scope:e.__scopeMenu,children:p.jsx(fo,{id:a.contentId,"aria-labelledby":a.triggerId,...r,ref:d,align:"start",side:i.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:u=>{var f;i.isUsingKeyboardRef.current&&((f=l.current)==null||f.focus()),u.preventDefault()},onCloseAutoFocus:u=>u.preventDefault(),onFocusOutside:R(e.onFocusOutside,u=>{u.target!==a.trigger&&s.onOpenChange(!1)}),onEscapeKeyDown:R(e.onEscapeKeyDown,u=>{i.onClose(),u.preventDefault()}),onKeyDown:R(e.onKeyDown,u=>{var m;const f=u.currentTarget.contains(u.target),v=Fd[i.dir].includes(u.key);f&&v&&(s.onOpenChange(!1),(m=a.trigger)==null||m.focus(),u.preventDefault())})})})})})});pi.displayName=fi;function vi(e){return e?"open":"closed"}function Wt(e){return e==="indeterminate"}function ho(e){return Wt(e)?"indeterminate":e?"checked":"unchecked"}function sf(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function af(e,t){return e.map((n,o)=>e[(t+o)%e.length])}function cf(e,t,n){const r=t.length>1&&Array.from(t).every(d=>d===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let i=af(e,Math.max(s,0));r.length===1&&(i=i.filter(d=>d!==n));const l=i.find(d=>d.toLowerCase().startsWith(r.toLowerCase()));return l!==n?l:void 0}function lf(e,t){const{x:n,y:o}=e;let r=!1;for(let s=0,i=t.length-1;s<t.length;i=s++){const a=t[s],l=t[i],d=a.x,u=a.y,f=l.x,v=l.y;u>o!=v>o&&n<(f-d)*(o-u)/(v-u)+d&&(r=!r)}return r}function uf(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return lf(n,t)}function ut(e){return t=>t.pointerType==="mouse"?e(t):void 0}var hi=Xs,mi=co,gi=Zs,xi=Qs,wi=po,yi=Js,Ci=pn,bi=ti,Si=oi,Ei=si,Ri=ai,Pi=ci,Ti=li,_i=di,Mi=pi,mo="ContextMenu",[df]=se(mo,[dn]),Q=dn(),[ff,Ai]=df(mo),Ii=e=>{const{__scopeContextMenu:t,children:n,onOpenChange:o,dir:r,modal:s=!0}=e,[i,a]=c.useState(!1),l=Q(t),d=X(o),u=c.useCallback(f=>{a(f),d(f)},[d]);return p.jsx(ff,{scope:t,open:i,onOpenChange:u,modal:s,children:p.jsx(hi,{...l,dir:r,open:i,onOpenChange:u,modal:s,children:n})})};Ii.displayName=mo;var Ni="ContextMenuTrigger",Oi=c.forwardRef((e,t)=>{const{__scopeContextMenu:n,disabled:o=!1,...r}=e,s=Ai(Ni,n),i=Q(n),a=c.useRef({x:0,y:0}),l=c.useRef({getBoundingClientRect:()=>DOMRect.fromRect({width:0,height:0,...a.current})}),d=c.useRef(0),u=c.useCallback(()=>window.clearTimeout(d.current),[]),f=v=>{a.current={x:v.clientX,y:v.clientY},s.onOpenChange(!0)};return c.useEffect(()=>u,[u]),c.useEffect(()=>void(o&&u()),[o,u]),p.jsxs(p.Fragment,{children:[p.jsx(mi,{...i,virtualRef:l}),p.jsx(O.span,{"data-state":s.open?"open":"closed","data-disabled":o?"":void 0,...r,ref:t,style:{WebkitTouchCallout:"none",...e.style},onContextMenu:o?e.onContextMenu:R(e.onContextMenu,v=>{u(),f(v),v.preventDefault()}),onPointerDown:o?e.onPointerDown:R(e.onPointerDown,Mt(v=>{u(),d.current=window.setTimeout(()=>f(v),700)})),onPointerMove:o?e.onPointerMove:R(e.onPointerMove,Mt(u)),onPointerCancel:o?e.onPointerCancel:R(e.onPointerCancel,Mt(u)),onPointerUp:o?e.onPointerUp:R(e.onPointerUp,Mt(u))})]})});Oi.displayName=Ni;var pf="ContextMenuPortal",Di=e=>{const{__scopeContextMenu:t,...n}=e,o=Q(t);return p.jsx(gi,{...o,...n})};Di.displayName=pf;var Li="ContextMenuContent",ji=c.forwardRef((e,t)=>{const{__scopeContextMenu:n,...o}=e,r=Ai(Li,n),s=Q(n),i=c.useRef(!1);return p.jsx(xi,{...s,...o,ref:t,side:"right",sideOffset:2,align:"start",onCloseAutoFocus:a=>{var l;(l=e.onCloseAutoFocus)==null||l.call(e,a),!a.defaultPrevented&&i.current&&a.preventDefault(),i.current=!1},onInteractOutside:a=>{var l;(l=e.onInteractOutside)==null||l.call(e,a),!a.defaultPrevented&&!r.modal&&(i.current=!0)},style:{...e.style,"--radix-context-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-context-menu-content-available-width":"var(--radix-popper-available-width)","--radix-context-menu-content-available-height":"var(--radix-popper-available-height)","--radix-context-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-context-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});ji.displayName=Li;var vf="ContextMenuGroup",hf=c.forwardRef((e,t)=>{const{__scopeContextMenu:n,...o}=e,r=Q(n);return p.jsx(wi,{...r,...o,ref:t})});hf.displayName=vf;var mf="ContextMenuLabel",ki=c.forwardRef((e,t)=>{const{__scopeContextMenu:n,...o}=e,r=Q(n);return p.jsx(yi,{...r,...o,ref:t})});ki.displayName=mf;var gf="ContextMenuItem",$i=c.forwardRef((e,t)=>{const{__scopeContextMenu:n,...o}=e,r=Q(n);return p.jsx(Ci,{...r,...o,ref:t})});$i.displayName=gf;var xf="ContextMenuCheckboxItem",Fi=c.forwardRef((e,t)=>{const{__scopeContextMenu:n,...o}=e,r=Q(n);return p.jsx(bi,{...r,...o,ref:t})});Fi.displayName=xf;var wf="ContextMenuRadioGroup",yf=c.forwardRef((e,t)=>{const{__scopeContextMenu:n,...o}=e,r=Q(n);return p.jsx(Si,{...r,...o,ref:t})});yf.displayName=wf;var Cf="ContextMenuRadioItem",Bi=c.forwardRef((e,t)=>{const{__scopeContextMenu:n,...o}=e,r=Q(n);return p.jsx(Ei,{...r,...o,ref:t})});Bi.displayName=Cf;var bf="ContextMenuItemIndicator",Wi=c.forwardRef((e,t)=>{const{__scopeContextMenu:n,...o}=e,r=Q(n);return p.jsx(Ri,{...r,...o,ref:t})});Wi.displayName=bf;var Sf="ContextMenuSeparator",Hi=c.forwardRef((e,t)=>{const{__scopeContextMenu:n,...o}=e,r=Q(n);return p.jsx(Pi,{...r,...o,ref:t})});Hi.displayName=Sf;var Ef="ContextMenuArrow",Rf=c.forwardRef((e,t)=>{const{__scopeContextMenu:n,...o}=e,r=Q(n);return p.jsx(Ti,{...r,...o,ref:t})});Rf.displayName=Ef;var Pf="ContextMenuSubTrigger",Vi=c.forwardRef((e,t)=>{const{__scopeContextMenu:n,...o}=e,r=Q(n);return p.jsx(_i,{...r,...o,ref:t})});Vi.displayName=Pf;var Tf="ContextMenuSubContent",Ui=c.forwardRef((e,t)=>{const{__scopeContextMenu:n,...o}=e,r=Q(n);return p.jsx(Mi,{...r,...o,ref:t,style:{...e.style,"--radix-context-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-context-menu-content-available-width":"var(--radix-popper-available-width)","--radix-context-menu-content-available-height":"var(--radix-popper-available-height)","--radix-context-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-context-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Ui.displayName=Tf;function Mt(e){return t=>t.pointerType!=="mouse"?e(t):void 0}var dv=Ii,fv=Oi,pv=Di,vv=ji,hv=ki,mv=$i,gv=Fi,xv=Bi,wv=Wi,yv=Hi,Cv=Vi,bv=Ui,vn="DropdownMenu",[_f]=se(vn,[dn]),J=dn(),[Mf,Gi]=_f(vn),Ki=e=>{const{__scopeDropdownMenu:t,children:n,dir:o,open:r,defaultOpen:s,onOpenChange:i,modal:a=!0}=e,l=J(t),d=c.useRef(null),[u,f]=Ee({prop:r,defaultProp:s??!1,onChange:i,caller:vn});return p.jsx(Mf,{scope:t,triggerId:ae(),triggerRef:d,contentId:ae(),open:u,onOpenChange:f,onOpenToggle:c.useCallback(()=>f(v=>!v),[f]),modal:a,children:p.jsx(hi,{...l,open:u,onOpenChange:f,dir:o,modal:a,children:n})})};Ki.displayName=vn;var zi="DropdownMenuTrigger",Yi=c.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:o=!1,...r}=e,s=Gi(zi,n),i=J(n);return p.jsx(mi,{asChild:!0,...i,children:p.jsx(O.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:dt(t,s.triggerRef),onPointerDown:R(e.onPointerDown,a=>{!o&&a.button===0&&a.ctrlKey===!1&&(s.onOpenToggle(),s.open||a.preventDefault())}),onKeyDown:R(e.onKeyDown,a=>{o||(["Enter"," "].includes(a.key)&&s.onOpenToggle(),a.key==="ArrowDown"&&s.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(a.key)&&a.preventDefault())})})})});Yi.displayName=zi;var Af="DropdownMenuPortal",Xi=e=>{const{__scopeDropdownMenu:t,...n}=e,o=J(t);return p.jsx(gi,{...o,...n})};Xi.displayName=Af;var qi="DropdownMenuContent",Zi=c.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=Gi(qi,n),s=J(n),i=c.useRef(!1);return p.jsx(xi,{id:r.contentId,"aria-labelledby":r.triggerId,...s,...o,ref:t,onCloseAutoFocus:R(e.onCloseAutoFocus,a=>{var l;i.current||(l=r.triggerRef.current)==null||l.focus(),i.current=!1,a.preventDefault()}),onInteractOutside:R(e.onInteractOutside,a=>{const l=a.detail.originalEvent,d=l.button===0&&l.ctrlKey===!0,u=l.button===2||d;(!r.modal||u)&&(i.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Zi.displayName=qi;var If="DropdownMenuGroup",Nf=c.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=J(n);return p.jsx(wi,{...r,...o,ref:t})});Nf.displayName=If;var Of="DropdownMenuLabel",Qi=c.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=J(n);return p.jsx(yi,{...r,...o,ref:t})});Qi.displayName=Of;var Df="DropdownMenuItem",Ji=c.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=J(n);return p.jsx(Ci,{...r,...o,ref:t})});Ji.displayName=Df;var Lf="DropdownMenuCheckboxItem",ea=c.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=J(n);return p.jsx(bi,{...r,...o,ref:t})});ea.displayName=Lf;var jf="DropdownMenuRadioGroup",kf=c.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=J(n);return p.jsx(Si,{...r,...o,ref:t})});kf.displayName=jf;var $f="DropdownMenuRadioItem",ta=c.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=J(n);return p.jsx(Ei,{...r,...o,ref:t})});ta.displayName=$f;var Ff="DropdownMenuItemIndicator",na=c.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=J(n);return p.jsx(Ri,{...r,...o,ref:t})});na.displayName=Ff;var Bf="DropdownMenuSeparator",oa=c.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=J(n);return p.jsx(Pi,{...r,...o,ref:t})});oa.displayName=Bf;var Wf="DropdownMenuArrow",Hf=c.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=J(n);return p.jsx(Ti,{...r,...o,ref:t})});Hf.displayName=Wf;var Vf="DropdownMenuSubTrigger",ra=c.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=J(n);return p.jsx(_i,{...r,...o,ref:t})});ra.displayName=Vf;var Uf="DropdownMenuSubContent",sa=c.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...o}=e,r=J(n);return p.jsx(Mi,{...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)"}})});sa.displayName=Uf;var Sv=Ki,Ev=Yi,Rv=Xi,Pv=Zi,Tv=Qi,_v=Ji,Mv=ea,Av=ta,Iv=na,Nv=oa,Ov=ra,Dv=sa,Gf="Separator",Xo="horizontal",Kf=["horizontal","vertical"],ia=c.forwardRef((e,t)=>{const{decorative:n,orientation:o=Xo,...r}=e,s=zf(o)?o:Xo,a=n?{role:"none"}:{"aria-orientation":s==="vertical"?s:void 0,role:"separator"};return p.jsx(ln.div,{"data-orientation":s,...a,...r,ref:t})});ia.displayName=Gf;function zf(e){return Kf.includes(e)}var Lv=ia;function Yf(e,t){return c.useReducer((n,o)=>t[n][o]??n,e)}var go="ScrollArea",[aa]=se(go),[Xf,le]=aa(go),ca=c.forwardRef((e,t)=>{const{__scopeScrollArea:n,type:o="hover",dir:r,scrollHideDelay:s=600,...i}=e,[a,l]=c.useState(null),[d,u]=c.useState(null),[f,v]=c.useState(null),[m,g]=c.useState(null),[h,x]=c.useState(null),[w,y]=c.useState(0),[C,b]=c.useState(0),[E,P]=c.useState(!1),[S,_]=c.useState(!1),M=j(t,L=>l(L)),A=gt(r);return p.jsx(Xf,{scope:n,type:o,dir:A,scrollHideDelay:s,scrollArea:a,viewport:d,onViewportChange:u,content:f,onContentChange:v,scrollbarX:m,onScrollbarXChange:g,scrollbarXEnabled:E,onScrollbarXEnabledChange:P,scrollbarY:h,onScrollbarYChange:x,scrollbarYEnabled:S,onScrollbarYEnabledChange:_,onCornerWidthChange:y,onCornerHeightChange:b,children:p.jsx(O.div,{dir:A,...i,ref:M,style:{position:"relative","--radix-scroll-area-corner-width":w+"px","--radix-scroll-area-corner-height":C+"px",...e.style}})})});ca.displayName=go;var la="ScrollAreaViewport",ua=c.forwardRef((e,t)=>{const{__scopeScrollArea:n,children:o,nonce:r,...s}=e,i=le(la,n),a=c.useRef(null),l=j(t,a,i.onViewportChange);return p.jsxs(p.Fragment,{children:[p.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"},nonce:r}),p.jsx(O.div,{"data-radix-scroll-area-viewport":"",...s,ref:l,style:{overflowX:i.scrollbarXEnabled?"scroll":"hidden",overflowY:i.scrollbarYEnabled?"scroll":"hidden",...e.style},children:p.jsx("div",{ref:i.onContentChange,style:{minWidth:"100%",display:"table"},children:o})})]})});ua.displayName=la;var we="ScrollAreaScrollbar",qf=c.forwardRef((e,t)=>{const{forceMount:n,...o}=e,r=le(we,e.__scopeScrollArea),{onScrollbarXEnabledChange:s,onScrollbarYEnabledChange:i}=r,a=e.orientation==="horizontal";return c.useEffect(()=>(a?s(!0):i(!0),()=>{a?s(!1):i(!1)}),[a,s,i]),r.type==="hover"?p.jsx(Zf,{...o,ref:t,forceMount:n}):r.type==="scroll"?p.jsx(Qf,{...o,ref:t,forceMount:n}):r.type==="auto"?p.jsx(da,{...o,ref:t,forceMount:n}):r.type==="always"?p.jsx(xo,{...o,ref:t}):null});qf.displayName=we;var Zf=c.forwardRef((e,t)=>{const{forceMount:n,...o}=e,r=le(we,e.__scopeScrollArea),[s,i]=c.useState(!1);return c.useEffect(()=>{const a=r.scrollArea;let l=0;if(a){const d=()=>{window.clearTimeout(l),i(!0)},u=()=>{l=window.setTimeout(()=>i(!1),r.scrollHideDelay)};return a.addEventListener("pointerenter",d),a.addEventListener("pointerleave",u),()=>{window.clearTimeout(l),a.removeEventListener("pointerenter",d),a.removeEventListener("pointerleave",u)}}},[r.scrollArea,r.scrollHideDelay]),p.jsx(Z,{present:n||s,children:p.jsx(da,{"data-state":s?"visible":"hidden",...o,ref:t})})}),Qf=c.forwardRef((e,t)=>{const{forceMount:n,...o}=e,r=le(we,e.__scopeScrollArea),s=e.orientation==="horizontal",i=mn(()=>l("SCROLL_END"),100),[a,l]=Yf("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 c.useEffect(()=>{if(a==="idle"){const d=window.setTimeout(()=>l("HIDE"),r.scrollHideDelay);return()=>window.clearTimeout(d)}},[a,r.scrollHideDelay,l]),c.useEffect(()=>{const d=r.viewport,u=s?"scrollLeft":"scrollTop";if(d){let f=d[u];const v=()=>{const m=d[u];f!==m&&(l("SCROLL"),i()),f=m};return d.addEventListener("scroll",v),()=>d.removeEventListener("scroll",v)}},[r.viewport,s,l,i]),p.jsx(Z,{present:n||a!=="hidden",children:p.jsx(xo,{"data-state":a==="hidden"?"hidden":"visible",...o,ref:t,onPointerEnter:R(e.onPointerEnter,()=>l("POINTER_ENTER")),onPointerLeave:R(e.onPointerLeave,()=>l("POINTER_LEAVE"))})})}),da=c.forwardRef((e,t)=>{const n=le(we,e.__scopeScrollArea),{forceMount:o,...r}=e,[s,i]=c.useState(!1),a=e.orientation==="horizontal",l=mn(()=>{if(n.viewport){const d=n.viewport.offsetWidth<n.viewport.scrollWidth,u=n.viewport.offsetHeight<n.viewport.scrollHeight;i(a?d:u)}},10);return Xe(n.viewport,l),Xe(n.content,l),p.jsx(Z,{present:o||s,children:p.jsx(xo,{"data-state":s?"visible":"hidden",...r,ref:t})})}),xo=c.forwardRef((e,t)=>{const{orientation:n="vertical",...o}=e,r=le(we,e.__scopeScrollArea),s=c.useRef(null),i=c.useRef(0),[a,l]=c.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),d=ha(a.viewport,a.content),u={...o,sizes:a,onSizesChange:l,hasThumb:d>0&&d<1,onThumbChange:v=>s.current=v,onThumbPointerUp:()=>i.current=0,onThumbPointerDown:v=>i.current=v};function f(v,m){return sp(v,i.current,a,m)}return n==="horizontal"?p.jsx(Jf,{...u,ref:t,onThumbPositionChange:()=>{if(r.viewport&&s.current){const v=r.viewport.scrollLeft,m=qo(v,a,r.dir);s.current.style.transform=`translate3d(${m}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(ep,{...u,ref:t,onThumbPositionChange:()=>{if(r.viewport&&s.current){const v=r.viewport.scrollTop,m=qo(v,a);s.current.style.transform=`translate3d(0, ${m}px, 0)`}},onWheelScroll:v=>{r.viewport&&(r.viewport.scrollTop=v)},onDragScroll:v=>{r.viewport&&(r.viewport.scrollTop=f(v))}}):null}),Jf=c.forwardRef((e,t)=>{const{sizes:n,onSizesChange:o,...r}=e,s=le(we,e.__scopeScrollArea),[i,a]=c.useState(),l=c.useRef(null),d=j(t,l,s.onScrollbarXChange);return c.useEffect(()=>{l.current&&a(getComputedStyle(l.current))},[l]),p.jsx(pa,{"data-orientation":"horizontal",...r,ref:d,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":hn(n)+"px",...e.style},onThumbPointerDown:u=>e.onThumbPointerDown(u.x),onDragScroll:u=>e.onDragScroll(u.x),onWheelScroll:(u,f)=>{if(s.viewport){const v=s.viewport.scrollLeft+u.deltaX;e.onWheelScroll(v),ga(v,f)&&u.preventDefault()}},onResize:()=>{l.current&&s.viewport&&i&&o({content:s.viewport.scrollWidth,viewport:s.viewport.offsetWidth,scrollbar:{size:l.current.clientWidth,paddingStart:Vt(i.paddingLeft),paddingEnd:Vt(i.paddingRight)}})}})}),ep=c.forwardRef((e,t)=>{const{sizes:n,onSizesChange:o,...r}=e,s=le(we,e.__scopeScrollArea),[i,a]=c.useState(),l=c.useRef(null),d=j(t,l,s.onScrollbarYChange);return c.useEffect(()=>{l.current&&a(getComputedStyle(l.current))},[l]),p.jsx(pa,{"data-orientation":"vertical",...r,ref:d,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":hn(n)+"px",...e.style},onThumbPointerDown:u=>e.onThumbPointerDown(u.y),onDragScroll:u=>e.onDragScroll(u.y),onWheelScroll:(u,f)=>{if(s.viewport){const v=s.viewport.scrollTop+u.deltaY;e.onWheelScroll(v),ga(v,f)&&u.preventDefault()}},onResize:()=>{l.current&&s.viewport&&i&&o({content:s.viewport.scrollHeight,viewport:s.viewport.offsetHeight,scrollbar:{size:l.current.clientHeight,paddingStart:Vt(i.paddingTop),paddingEnd:Vt(i.paddingBottom)}})}})}),[tp,fa]=aa(we),pa=c.forwardRef((e,t)=>{const{__scopeScrollArea:n,sizes:o,hasThumb:r,onThumbChange:s,onThumbPointerUp:i,onThumbPointerDown:a,onThumbPositionChange:l,onDragScroll:d,onWheelScroll:u,onResize:f,...v}=e,m=le(we,n),[g,h]=c.useState(null),x=j(t,M=>h(M)),w=c.useRef(null),y=c.useRef(""),C=m.viewport,b=o.content-o.viewport,E=X(u),P=X(l),S=mn(f,10);function _(M){if(w.current){const A=M.clientX-w.current.left,L=M.clientY-w.current.top;d({x:A,y:L})}}return c.useEffect(()=>{const M=A=>{const L=A.target;(g==null?void 0:g.contains(L))&&E(A,b)};return document.addEventListener("wheel",M,{passive:!1}),()=>document.removeEventListener("wheel",M,{passive:!1})},[C,g,b,E]),c.useEffect(P,[o,P]),Xe(g,S),Xe(m.content,S),p.jsx(tp,{scope:n,scrollbar:g,hasThumb:r,onThumbChange:X(s),onThumbPointerUp:X(i),onThumbPositionChange:P,onThumbPointerDown:X(a),children:p.jsx(O.div,{...v,ref:x,style:{position:"absolute",...v.style},onPointerDown:R(e.onPointerDown,M=>{M.button===0&&(M.target.setPointerCapture(M.pointerId),w.current=g.getBoundingClientRect(),y.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",m.viewport&&(m.viewport.style.scrollBehavior="auto"),_(M))}),onPointerMove:R(e.onPointerMove,_),onPointerUp:R(e.onPointerUp,M=>{const A=M.target;A.hasPointerCapture(M.pointerId)&&A.releasePointerCapture(M.pointerId),document.body.style.webkitUserSelect=y.current,m.viewport&&(m.viewport.style.scrollBehavior=""),w.current=null})})})}),Ht="ScrollAreaThumb",np=c.forwardRef((e,t)=>{const{forceMount:n,...o}=e,r=fa(Ht,e.__scopeScrollArea);return p.jsx(Z,{present:n||r.hasThumb,children:p.jsx(op,{ref:t,...o})})}),op=c.forwardRef((e,t)=>{const{__scopeScrollArea:n,style:o,...r}=e,s=le(Ht,n),i=fa(Ht,n),{onThumbPositionChange:a}=i,l=j(t,f=>i.onThumbChange(f)),d=c.useRef(void 0),u=mn(()=>{d.current&&(d.current(),d.current=void 0)},100);return c.useEffect(()=>{const f=s.viewport;if(f){const v=()=>{if(u(),!d.current){const m=ip(f,a);d.current=m,a()}};return a(),f.addEventListener("scroll",v),()=>f.removeEventListener("scroll",v)}},[s.viewport,u,a]),p.jsx(O.div,{"data-state":i.hasThumb?"visible":"hidden",...r,ref:l,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...o},onPointerDownCapture:R(e.onPointerDownCapture,f=>{const m=f.target.getBoundingClientRect(),g=f.clientX-m.left,h=f.clientY-m.top;i.onThumbPointerDown({x:g,y:h})}),onPointerUp:R(e.onPointerUp,i.onThumbPointerUp)})});np.displayName=Ht;var wo="ScrollAreaCorner",va=c.forwardRef((e,t)=>{const n=le(wo,e.__scopeScrollArea),o=!!(n.scrollbarX&&n.scrollbarY);return n.type!=="scroll"&&o?p.jsx(rp,{...e,ref:t}):null});va.displayName=wo;var rp=c.forwardRef((e,t)=>{const{__scopeScrollArea:n,...o}=e,r=le(wo,n),[s,i]=c.useState(0),[a,l]=c.useState(0),d=!!(s&&a);return Xe(r.scrollbarX,()=>{var f;const u=((f=r.scrollbarX)==null?void 0:f.offsetHeight)||0;r.onCornerHeightChange(u),l(u)}),Xe(r.scrollbarY,()=>{var f;const u=((f=r.scrollbarY)==null?void 0:f.offsetWidth)||0;r.onCornerWidthChange(u),i(u)}),d?p.jsx(O.div,{...o,ref:t,style:{width:s,height:a,position:"absolute",right:r.dir==="ltr"?0:void 0,left:r.dir==="rtl"?0:void 0,bottom:0,...e.style}}):null});function Vt(e){return e?parseInt(e,10):0}function ha(e,t){const n=e/t;return isNaN(n)?0:n}function hn(e){const t=ha(e.viewport,e.content),n=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,o=(e.scrollbar.size-n)*t;return Math.max(o,18)}function sp(e,t,n,o="ltr"){const r=hn(n),s=r/2,i=t||s,a=r-i,l=n.scrollbar.paddingStart+i,d=n.scrollbar.size-n.scrollbar.paddingEnd-a,u=n.content-n.viewport,f=o==="ltr"?[0,u]:[u*-1,0];return ma([l,d],f)(e)}function qo(e,t,n="ltr"){const o=hn(t),r=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,s=t.scrollbar.size-r,i=t.content-t.viewport,a=s-o,l=n==="ltr"?[0,i]:[i*-1,0],d=$n(e,l);return ma([0,i],[0,a])(d)}function ma(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 ga(e,t){return e>0&&e<t}var ip=(e,t=()=>{})=>{let n={left:e.scrollLeft,top:e.scrollTop},o=0;return function r(){const s={left:e.scrollLeft,top:e.scrollTop},i=n.left!==s.left,a=n.top!==s.top;(i||a)&&t(),n=s,o=window.requestAnimationFrame(r)}(),()=>window.cancelAnimationFrame(o)};function mn(e,t){const n=X(e),o=c.useRef(0);return c.useEffect(()=>()=>window.clearTimeout(o.current),[]),c.useCallback(()=>{window.clearTimeout(o.current),o.current=window.setTimeout(n,t)},[n,t])}function Xe(e,t){const n=X(t);q(()=>{let o=0;if(e){const r=new ResizeObserver(()=>{cancelAnimationFrame(o),o=window.requestAnimationFrame(n)});return r.observe(e),()=>{window.cancelAnimationFrame(o),r.unobserve(e)}}},[e,n])}var jv=ca,kv=ua,$v=va,gn="Switch",[ap]=se(gn),[cp,lp]=ap(gn),xa=c.forwardRef((e,t)=>{const{__scopeSwitch:n,name:o,checked:r,defaultChecked:s,required:i,disabled:a,value:l="on",onCheckedChange:d,form:u,...f}=e,[v,m]=c.useState(null),g=j(t,C=>m(C)),h=c.useRef(!1),x=v?u||!!v.closest("form"):!0,[w,y]=Ee({prop:r,defaultProp:s??!1,onChange:d,caller:gn});return p.jsxs(cp,{scope:n,checked:w,disabled:a,children:[p.jsx(O.button,{type:"button",role:"switch","aria-checked":w,"aria-required":i,"data-state":ba(w),"data-disabled":a?"":void 0,disabled:a,value:l,...f,ref:g,onClick:R(e.onClick,C=>{y(b=>!b),x&&(h.current=C.isPropagationStopped(),h.current||C.stopPropagation())})}),x&&p.jsx(Ca,{control:v,bubbles:!h.current,name:o,value:l,checked:w,required:i,disabled:a,form:u,style:{transform:"translateX(-100%)"}})]})});xa.displayName=gn;var wa="SwitchThumb",ya=c.forwardRef((e,t)=>{const{__scopeSwitch:n,...o}=e,r=lp(wa,n);return p.jsx(O.span,{"data-state":ba(r.checked),"data-disabled":r.disabled?"":void 0,...o,ref:t})});ya.displayName=wa;var up="SwitchBubbleInput",Ca=c.forwardRef(({__scopeSwitch:e,control:t,checked:n,bubbles:o=!0,...r},s)=>{const i=c.useRef(null),a=j(i,s),l=as(n),d=hr(t);return c.useEffect(()=>{const u=i.current;if(!u)return;const f=window.HTMLInputElement.prototype,m=Object.getOwnPropertyDescriptor(f,"checked").set;if(l!==n&&m){const g=new Event("click",{bubbles:o});m.call(u,n),u.dispatchEvent(g)}},[l,n,o]),p.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:n,...r,tabIndex:-1,ref:a,style:{...r.style,...d,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});Ca.displayName=up;function ba(e){return e?"checked":"unchecked"}var Fv=xa,Bv=ya,xn="Tabs",[dp]=se(xn,[un]),Sa=un(),[fp,yo]=dp(xn),Ea=c.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,onValueChange:r,defaultValue:s,orientation:i="horizontal",dir:a,activationMode:l="automatic",...d}=e,u=gt(a),[f,v]=Ee({prop:o,onChange:r,defaultProp:s??"",caller:xn});return p.jsx(fp,{scope:n,baseId:ae(),value:f,onValueChange:v,orientation:i,dir:u,activationMode:l,children:p.jsx(O.div,{dir:u,"data-orientation":i,...d,ref:t})})});Ea.displayName=xn;var Ra="TabsList",Pa=c.forwardRef((e,t)=>{const{__scopeTabs:n,loop:o=!0,...r}=e,s=yo(Ra,n),i=Sa(n);return p.jsx(Gs,{asChild:!0,...i,orientation:s.orientation,dir:s.dir,loop:o,children:p.jsx(O.div,{role:"tablist","aria-orientation":s.orientation,...r,ref:t})})});Pa.displayName=Ra;var Ta="TabsTrigger",_a=c.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,disabled:r=!1,...s}=e,i=yo(Ta,n),a=Sa(n),l=Ia(i.baseId,o),d=Na(i.baseId,o),u=o===i.value;return p.jsx(Ks,{asChild:!0,...a,focusable:!r,active:u,children:p.jsx(O.button,{type:"button",role:"tab","aria-selected":u,"aria-controls":d,"data-state":u?"active":"inactive","data-disabled":r?"":void 0,disabled:r,id:l,...s,ref:t,onMouseDown:R(e.onMouseDown,f=>{!r&&f.button===0&&f.ctrlKey===!1?i.onValueChange(o):f.preventDefault()}),onKeyDown:R(e.onKeyDown,f=>{[" ","Enter"].includes(f.key)&&i.onValueChange(o)}),onFocus:R(e.onFocus,()=>{const f=i.activationMode!=="manual";!u&&!r&&f&&i.onValueChange(o)})})})});_a.displayName=Ta;var Ma="TabsContent",Aa=c.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,forceMount:r,children:s,...i}=e,a=yo(Ma,n),l=Ia(a.baseId,o),d=Na(a.baseId,o),u=o===a.value,f=c.useRef(u);return c.useEffect(()=>{const v=requestAnimationFrame(()=>f.current=!1);return()=>cancelAnimationFrame(v)},[]),p.jsx(Z,{present:r||u,children:({present:v})=>p.jsx(O.div,{"data-state":u?"active":"inactive","data-orientation":a.orientation,role:"tabpanel","aria-labelledby":l,hidden:!v,id:d,tabIndex:0,...i,ref:t,style:{...e.style,animationDuration:f.current?"0s":void 0},children:v&&s})})});Aa.displayName=Ma;function Ia(e,t){return`${e}-trigger-${t}`}function Na(e,t){return`${e}-content-${t}`}var Wv=Ea,Hv=Pa,Vv=_a,Uv=Aa,wn="Popover",[Oa]=se(wn,[Me]),Ct=Me(),[pp,Ne]=Oa(wn),Da=e=>{const{__scopePopover:t,children:n,open:o,defaultOpen:r,onOpenChange:s,modal:i=!1}=e,a=Ct(t),l=c.useRef(null),[d,u]=c.useState(!1),[f,v]=Ee({prop:o,defaultProp:r??!1,onChange:s,caller:wn});return p.jsx(qt,{...a,children:p.jsx(pp,{scope:t,contentId:ae(),triggerRef:l,open:f,onOpenChange:v,onOpenToggle:c.useCallback(()=>v(m=>!m),[v]),hasCustomAnchor:d,onCustomAnchorAdd:c.useCallback(()=>u(!0),[]),onCustomAnchorRemove:c.useCallback(()=>u(!1),[]),modal:i,children:n})})};Da.displayName=wn;var La="PopoverAnchor",vp=c.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=Ne(La,n),s=Ct(n),{onCustomAnchorAdd:i,onCustomAnchorRemove:a}=r;return c.useEffect(()=>(i(),()=>a()),[i,a]),p.jsx(pt,{...s,...o,ref:t})});vp.displayName=La;var ja="PopoverTrigger",ka=c.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=Ne(ja,n),s=Ct(n),i=j(t,r.triggerRef),a=p.jsx(O.button,{type:"button","aria-haspopup":"dialog","aria-expanded":r.open,"aria-controls":r.contentId,"data-state":Ha(r.open),...o,ref:i,onClick:R(e.onClick,r.onOpenToggle)});return r.hasCustomAnchor?a:p.jsx(pt,{asChild:!0,...s,children:a})});ka.displayName=ja;var Co="PopoverPortal",[hp,mp]=Oa(Co,{forceMount:void 0}),$a=e=>{const{__scopePopover:t,forceMount:n,children:o,container:r}=e,s=Ne(Co,t);return p.jsx(hp,{scope:t,forceMount:n,children:p.jsx(Z,{present:n||s.open,children:p.jsx(et,{asChild:!0,container:r,children:o})})})};$a.displayName=Co;var qe="PopoverContent",Fa=c.forwardRef((e,t)=>{const n=mp(qe,e.__scopePopover),{forceMount:o=n.forceMount,...r}=e,s=Ne(qe,e.__scopePopover);return p.jsx(Z,{present:o||s.open,children:s.modal?p.jsx(xp,{...r,ref:t}):p.jsx(wp,{...r,ref:t})})});Fa.displayName=qe;var gp=Le("PopoverContent.RemoveScroll"),xp=c.forwardRef((e,t)=>{const n=Ne(qe,e.__scopePopover),o=c.useRef(null),r=j(t,o),s=c.useRef(!1);return c.useEffect(()=>{const i=o.current;if(i)return on(i)},[]),p.jsx(mt,{as:gp,allowPinchZoom:!0,children:p.jsx(Ba,{...e,ref:r,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:R(e.onCloseAutoFocus,i=>{var a;i.preventDefault(),s.current||(a=n.triggerRef.current)==null||a.focus()}),onPointerDownOutside:R(e.onPointerDownOutside,i=>{const a=i.detail.originalEvent,l=a.button===0&&a.ctrlKey===!0,d=a.button===2||l;s.current=d},{checkForDefaultPrevented:!1}),onFocusOutside:R(e.onFocusOutside,i=>i.preventDefault(),{checkForDefaultPrevented:!1})})})}),wp=c.forwardRef((e,t)=>{const n=Ne(qe,e.__scopePopover),o=c.useRef(!1),r=c.useRef(!1);return p.jsx(Ba,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{var i,a;(i=e.onCloseAutoFocus)==null||i.call(e,s),s.defaultPrevented||(o.current||(a=n.triggerRef.current)==null||a.focus(),s.preventDefault()),o.current=!1,r.current=!1},onInteractOutside:s=>{var l,d;(l=e.onInteractOutside)==null||l.call(e,s),s.defaultPrevented||(o.current=!0,s.detail.originalEvent.type==="pointerdown"&&(r.current=!0));const i=s.target;((d=n.triggerRef.current)==null?void 0:d.contains(i))&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&r.current&&s.preventDefault()}})}),Ba=c.forwardRef((e,t)=>{const{__scopePopover:n,trapFocus:o,onOpenAutoFocus:r,onCloseAutoFocus:s,disableOutsidePointerEvents:i,onEscapeKeyDown:a,onPointerDownOutside:l,onFocusOutside:d,onInteractOutside:u,...f}=e,v=Ne(qe,n),m=Ct(n);return tn(),p.jsx(ht,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:r,onUnmountAutoFocus:s,children:p.jsx(Ze,{asChild:!0,disableOutsidePointerEvents:i,onInteractOutside:u,onEscapeKeyDown:a,onPointerDownOutside:l,onFocusOutside:d,onDismiss:()=>v.onOpenChange(!1),children:p.jsx(Zt,{"data-state":Ha(v.open),role:"dialog",id:v.contentId,...m,...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)"}})})})}),Wa="PopoverClose",yp=c.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=Ne(Wa,n);return p.jsx(O.button,{type:"button",...o,ref:t,onClick:R(e.onClick,()=>r.onOpenChange(!1))})});yp.displayName=Wa;var Cp="PopoverArrow",bp=c.forwardRef((e,t)=>{const{__scopePopover:n,...o}=e,r=Ct(n);return p.jsx(Qt,{...r,...o,ref:t})});bp.displayName=Cp;function Ha(e){return e?"open":"closed"}var Gv=Da,Kv=ka,zv=$a,Yv=Fa;function Sp(e,t=[]){let n=[];function o(s,i){const a=c.createContext(i);a.displayName=s+"Context";const l=n.length;n=[...n,i];const d=f=>{var w;const{scope:v,children:m,...g}=f,h=((w=v==null?void 0:v[e])==null?void 0:w[l])||a,x=c.useMemo(()=>g,Object.values(g));return p.jsx(h.Provider,{value:x,children:m})};d.displayName=s+"Provider";function u(f,v){var h;const m=((h=v==null?void 0:v[e])==null?void 0:h[l])||a,g=c.useContext(m);if(g)return g;if(i!==void 0)return i;throw new Error(`\`${f}\` must be used within \`${s}\``)}return[d,u]}const r=()=>{const s=n.map(i=>c.createContext(i));return function(a){const l=(a==null?void 0:a[e])||s;return c.useMemo(()=>({[`__scope${e}`]:{...a,[e]:l}}),[a,l])}};return r.scopeName=e,[o,Ep(r,...t)]}function Ep(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const o=e.map(r=>({useScope:r(),scopeName:r.scopeName}));return function(s){const i=o.reduce((a,{useScope:l,scopeName:d})=>{const f=l(s)[`__scope${d}`];return{...a,...f}},{});return c.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}var bo="Progress",So=100,[Rp]=Sp(bo),[Pp,Tp]=Rp(bo),Va=c.forwardRef((e,t)=>{const{__scopeProgress:n,value:o=null,max:r,getValueLabel:s=_p,...i}=e;(r||r===0)&&!Zo(r)&&console.error(Mp(`${r}`,"Progress"));const a=Zo(r)?r:So;o!==null&&!Qo(o,a)&&console.error(Ap(`${o}`,"Progress"));const l=Qo(o,a)?o:null,d=Ut(l)?s(l,a):void 0;return p.jsx(Pp,{scope:n,value:l,max:a,children:p.jsx(ln.div,{"aria-valuemax":a,"aria-valuemin":0,"aria-valuenow":Ut(l)?l:void 0,"aria-valuetext":d,role:"progressbar","data-state":Ka(l,a),"data-value":l??void 0,"data-max":a,...i,ref:t})})});Va.displayName=bo;var Ua="ProgressIndicator",Ga=c.forwardRef((e,t)=>{const{__scopeProgress:n,...o}=e,r=Tp(Ua,n);return p.jsx(ln.div,{"data-state":Ka(r.value,r.max),"data-value":r.value??void 0,"data-max":r.max,...o,ref:t})});Ga.displayName=Ua;function _p(e,t){return`${Math.round(e/t*100)}%`}function Ka(e,t){return e==null?"indeterminate":e===t?"complete":"loading"}function Ut(e){return typeof e=="number"}function Zo(e){return Ut(e)&&!isNaN(e)&&e>0}function Qo(e,t){return Ut(e)&&!isNaN(e)&&e<=t&&e>=0}function Mp(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${So}\`.`}function Ap(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be:
|
|
46
|
+
- a positive number
|
|
47
|
+
- less than the value passed to \`max\` (or ${So} if no \`max\` prop is set)
|
|
48
|
+
- \`null\` or \`undefined\` if the progress is indeterminate.
|
|
49
|
+
|
|
50
|
+
Defaulting to \`null\`.`}var Xv=Va,qv=Ga;export{Av as $,kp as A,gv as B,jp as C,Gp as D,wv as E,xv as F,ev as G,hv as H,qp as I,Sv as J,Ev as K,tv as L,Rv as M,Pv as N,Hp as O,Lp as P,_v as Q,Op as R,sv as S,Dp as T,Nv as U,Xp as V,Tv as W,Ov as X,Dv as Y,Mv as Z,Iv as _,Np as a,Lv as a0,Bp as a1,jv as a2,kv as a3,$v as a4,qf as a5,np as a6,Fv as a7,Bv as a8,Wv as a9,Hv as aa,Vv as ab,Uv as ac,Gv as ad,Kv as ae,zv as af,Yv as ag,Xv as ah,qv as ai,Fp as b,Kp as c,Wp as d,Vp as e,Up as f,zp as g,Yp as h,Zp as i,Qp as j,Jp as k,nv as l,rv as m,ov as n,iv as o,av as p,lv as q,cv as r,dv as s,fv as t,pv as u,vv as v,yv as w,mv as x,Cv as y,bv as z};
|
|
51
|
+
//# sourceMappingURL=radix-ui-BzbaiLpZ.js.map
|