@jean2/client 1.0.0 → 1.0.3
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/assets/SessionContent-w-YQzt9T.js +9 -0
- package/dist/assets/{SessionMenuButton-CfDBJE0r.js → SessionMenuButton-Bg83zT6G.js} +1 -1
- package/dist/assets/{ThemeProvider-DWTAR83t.js → ThemeProvider-Da23NPAS.js} +1 -1
- package/dist/assets/_serverId-B4Rjk4iQ.js +12 -0
- package/dist/assets/{_serverId-D7fl2Don.js → _serverId-BwsJG6SV.js} +1 -1
- package/dist/assets/{_serverId-Z_onznBB.js → _serverId-COhNW61b.js} +2 -2
- package/dist/assets/_sessionId-CMkepspM.js +1 -0
- package/dist/assets/_sessionId-xZ5q7S0b.js +1 -0
- package/dist/assets/alert-qqwNRgnw.js +31 -0
- package/dist/assets/badge-CwZd07eA.js +45 -0
- package/dist/assets/{confirmation-dialog-CcyiA31R.js → confirmation-dialog-DGPNPL5O.js} +1 -1
- package/dist/assets/index-BDTQdmk9.js +10 -0
- package/dist/assets/index-DF4q2PgJ.css +2 -0
- package/dist/assets/overview-CEkUAF73.js +1 -0
- package/dist/assets/{platform-Be8afd__.js → platform-5d-ZQG2e.js} +1 -1
- package/dist/assets/{popover-DDHwMxwz.js → popover-BaZzl6-v.js} +1 -1
- package/dist/assets/{scroll-area-C-KPh_XU.js → scroll-area-16Gq00WS.js} +1 -1
- package/dist/assets/{sidebar-BNTVPq06.js → sidebar-DmGZgZwK.js} +1 -1
- package/dist/assets/src-BiLzKNfl.js +1 -0
- package/dist/assets/workspace-B-9b8A58.js +1 -0
- package/dist/index.html +6 -6
- package/package.json +1 -1
- package/dist/assets/SessionContent-6BakydNj.js +0 -9
- package/dist/assets/_serverId-B47rZ3cs.js +0 -12
- package/dist/assets/_sessionId-CJ6VLUC_.js +0 -1
- package/dist/assets/_sessionId-CMQvBPmZ.js +0 -1
- package/dist/assets/alert-DjGCaOkT.js +0 -31
- package/dist/assets/badge-CxHTOx9D.js +0 -45
- package/dist/assets/index-CGdDNSI7.js +0 -10
- package/dist/assets/index-QW5PCSUz.css +0 -2
- package/dist/assets/overview-GjLiY4UT.js +0 -1
- package/dist/assets/src-9dJwbSJY.js +0 -1
- package/dist/assets/workspace-DVaW6FBq.js +0 -1
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import{n as e,o as t,r as n,t as r}from"./compiler-runtime-DZXZ41-q.js";import{i}from"./src-9dJwbSJY.js";import{t as a}from"./createLucideIcon-BYAVpx9Z.js";function o(e){return Math.max(220,Math.min(512,e))}var s={SESSIONS:`jean2_sessions_panel_width`,FILES:`jean2_files_panel_width`},c=`jean2_draft_`,l=720*60*60*1e3;function u(){try{for(let e=0;e<localStorage.length;e++){let t=localStorage.key(e);if(!(!t||!t.startsWith(`jean2_draft_`)))try{let e=localStorage.getItem(t);if(!e)continue;let n=JSON.parse(e);Date.now()-n.updatedAt>2592e6&&localStorage.removeItem(t)}catch{localStorage.removeItem(t)}}}catch{}}var d=a(`check`,[[`path`,{d:`M20 6 9 17l-5-5`,key:`1gmf2c`}]]),f=a(`chevron-right`,[[`path`,{d:`m9 18 6-6-6-6`,key:`mthhwq`}]]),p=a(`circle-check-big`,[[`path`,{d:`M21.801 10A10 10 0 1 1 17 3.335`,key:`yps3ct`}],[`path`,{d:`m9 11 3 3L22 4`,key:`1pflzl`}]]),m=a(`circle-x`,[[`circle`,{cx:`12`,cy:`12`,r:`10`,key:`1mglay`}],[`path`,{d:`m15 9-6 6`,key:`1uzhvr`}],[`path`,{d:`m9 9 6 6`,key:`z0biqf`}]]),h=a(`folder`,[[`path`,{d:`M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z`,key:`1kt360`}]]),g=a(`loader-circle`,[[`path`,{d:`M21 12a9 9 0 1 1-6.219-8.56`,key:`13zald`}]]),_=a(`plus`,[[`path`,{d:`M5 12h14`,key:`1ays0h`}],[`path`,{d:`M12 5v14`,key:`s699le`}]]),v=a(`shield`,[[`path`,{d:`M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z`,key:`oel41y`}]]),y=a(`trash-2`,[[`path`,{d:`M10 11v6`,key:`nco0om`}],[`path`,{d:`M14 11v6`,key:`outv1u`}],[`path`,{d:`M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6`,key:`miytrc`}],[`path`,{d:`M3 6h18`,key:`d0wm0j`}],[`path`,{d:`M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2`,key:`e791ji`}]]),b=a(`x`,[[`path`,{d:`M18 6 6 18`,key:`1bl5f8`}],[`path`,{d:`m6 6 12 12`,key:`d8bk6v`}]]),x=t(n(),1),S=e=>{let t,n=new Set,r=(e,r)=>{let i=typeof e==`function`?e(t):e;if(!Object.is(i,t)){let e=t;t=(r==null?typeof i!=`object`||!i:r)?i:Object.assign({},t,i),n.forEach(n=>n(t,e))}},i=()=>t,a={setState:r,getState:i,getInitialState:()=>o,subscribe:e=>(n.add(e),()=>n.delete(e))},o=t=e(r,i,a);return a},C=(e=>e?S(e):S),w=e=>e;function T(e,t=w){let n=x.useSyncExternalStore(e.subscribe,x.useCallback(()=>t(e.getState()),[e,t]),x.useCallback(()=>t(e.getInitialState()),[e,t]));return x.useDebugValue(n),n}var E=e=>{let t=C(e),n=e=>T(t,e);return Object.assign(n,t),n},D=(e=>e?E(e):E),O={promptTokens:0,completionTokens:0,totalTokens:0},k=D((e,t)=>({currentSession:null,setCurrentSession:t=>e({currentSession:t}),clearActiveSession:()=>e({currentSession:null}),sessions:[],setSessions:t=>e(e=>({sessions:typeof t==`function`?t(e.sessions):t})),addSessionToFront:t=>e(e=>({sessions:[t,...e.sessions]})),updateSession:t=>e(e=>({sessions:e.sessions.map(e=>e.id===t.id?t:e)})),removeSessionById:t=>e(e=>({sessions:e.sessions.filter(e=>e.id!==t)})),clearSessions:()=>e({sessions:[]}),sessionUsage:{...O},currentModel:`gpt-4o`,selectedVariant:null,compactionSuccess:!1,setSessionUsage:t=>e({sessionUsage:t}),setCurrentModel:t=>e({currentModel:t}),setSelectedVariant:t=>e({selectedVariant:t}),setCompactionSuccess:t=>e({compactionSuccess:t}),clearChatSession:()=>e({sessionUsage:{...O},currentModel:`gpt-4o`,selectedVariant:null,compactionSuccess:!1}),messagesBySession:{},partsBySession:{},setMessagesBySession:t=>e(e=>({messagesBySession:typeof t==`function`?t(e.messagesBySession):t})),setPartsBySession:t=>e(e=>({partsBySession:typeof t==`function`?t(e.partsBySession):t})),getMessagesBySessionKeysCount:()=>Object.keys(t().messagesBySession).length,queuedMessages:{},clearQueuedMessages:()=>e({queuedMessages:{}}),setQueuedMessagesForSession:(t,n)=>e(e=>({queuedMessages:{...e.queuedMessages,[t]:n}})),addQueuedMessage:(t,n)=>e(e=>({queuedMessages:{...e.queuedMessages,[t]:[...e.queuedMessages[t]||[],n]}})),removeQueuedMessageById:(t,n)=>e(e=>({queuedMessages:{...e.queuedMessages,[t]:(e.queuedMessages[t]||[]).filter(e=>e.id!==n)}})),removeQueuedMessagesByIds:(t,n)=>e(e=>({queuedMessages:{...e.queuedMessages,[t]:(e.queuedMessages[t]||[]).filter(e=>!n.includes(e.id))}}))}));function A(){let e=k.getState();e.clearSessions(),e.clearActiveSession(),e.clearChatSession(),e.clearQueuedMessages(),e.setMessagesBySession({}),e.setPartsBySession({})}var j=D(e=>({serverId:null,workspaces:[],activeWorkspace:null,preconfigs:[],prompts:[],models:[],defaultModel:`gpt-4o`,defaultProvider:`openai`,providers:[],hydrate:(t,n)=>e({serverId:t,...n}),updateModels:(t,n,r)=>e({models:t,defaultModel:n,defaultProvider:r}),updatePreconfigs:t=>e({preconfigs:t}),updatePrompts:t=>e({prompts:t}),updateProviders:t=>e({providers:t}),setWorkspaces:t=>e({workspaces:t}),setActiveWorkspace:t=>e({activeWorkspace:t}),clearAll:()=>e({serverId:null,workspaces:[],activeWorkspace:null,preconfigs:[],prompts:[],models:[],defaultModel:`gpt-4o`,defaultProvider:`openai`,providers:[]})})),M=(0,x.createContext)(null),N=()=>{let e=(0,x.useContext)(M);if(e===null)throw Error(`useViewRefs must be used within a ViewRefsProvider`);return e},ee=(0,x.createContext)(null);function te(){let e=(0,x.useContext)(ee);if(!e)throw Error(`useSessionManager must be used within a SessionManagerContext.Provider`);return e}var P=D((e,t)=>({pendingRequests:[],handlers:new Map,timedOutRequestIds:new Set,addPendingRequest:t=>e(e=>t.ask.type===`permission`&&t.requestId&&e.timedOutRequestIds.has(t.requestId)?e:{pendingRequests:[...t.ask.type===`permission`&&t.requestId?e.pendingRequests.filter(e=>!(e.ask.type===`permission`&&e.requestId===t.requestId)):e.pendingRequests.filter(e=>e.toolCallId!==t.toolCallId),t]}),removePendingRequest:t=>e(e=>({pendingRequests:e.pendingRequests.filter(e=>e.toolCallId!==t)})),removePendingPermissionRequest:(t,n)=>e(e=>{let r=new Set(e.timedOutRequestIds);r.add(t);let i=e.pendingRequests.findIndex(e=>e.ask.type===`permission`&&e.requestId===t);return i===-1?n?{timedOutRequestIds:r,pendingRequests:e.pendingRequests.filter(e=>e.toolCallId!==n)}:{timedOutRequestIds:r}:{timedOutRequestIds:r,pendingRequests:e.pendingRequests.filter((e,t)=>t!==i)}}),replacePendingPermissionRequests:t=>e(e=>{let n=e.pendingRequests.filter(e=>e.ask.type!==`permission`);return{timedOutRequestIds:new Set,pendingRequests:[...n,...t]}}),clearPendingRequests:()=>e({pendingRequests:[],timedOutRequestIds:new Set}),clearPendingRequestsBySessionId:t=>e(e=>({pendingRequests:e.pendingRequests.filter(e=>e.sessionId!==t&&e.originSessionId!==t)})),registerHandler:(t,n)=>{e(e=>{var r;let i=new Map(e.handlers),a=(r=i.get(t))==null?[]:r;return i.set(t,[...a,n]),{handlers:i}})},unregisterHandler:(t,n)=>{e(e=>{let r=new Map(e.handlers),i=r.get(t);return i&&r.set(t,i.filter(e=>e!==n)),{handlers:r}})},getHandlers:e=>{var n;return(n=t().handlers.get(e))==null?[]:n}})),ne=`jean2_sound_chat_finish_enabled`,re=`jean2_sound_permission_enabled`,ie=(e,t)=>{if(typeof window>`u`)return t;let n=localStorage.getItem(e);return n===null?t:n===`true`},ae=D(e=>({showSettings:!1,showConfiguration:!1,showTools:!1,showMCPDialog:!1,showWorkspacePermissions:!1,showAddServer:!1,editServerData:null,setShowSettings:t=>e({showSettings:t}),setShowConfiguration:t=>e({showConfiguration:t}),setShowTools:t=>e({showTools:t}),setShowMCPDialog:t=>e({showMCPDialog:t}),setShowWorkspacePermissions:t=>e({showWorkspacePermissions:t}),setShowAddServer:t=>e({showAddServer:t}),setEditServerData:t=>e({editServerData:t}),chatFinishSoundEnabled:ie(ne,!0),permissionSoundEnabled:ie(re,!0),setChatFinishSoundEnabled:t=>{typeof window<`u`&&localStorage.setItem(ne,String(t)),e({chatFinishSoundEnabled:t})},setPermissionSoundEnabled:t=>{typeof window<`u`&&localStorage.setItem(re,String(t)),e({permissionSoundEnabled:t})},filePreviewTarget:null,openFilePreview:t=>e({filePreviewTarget:t}),closeFilePreview:()=>e({filePreviewTarget:null})})),F=D(e=>({connected:!1,authError:null,connectionTimedOut:!1,retryCount:0,nextRetryIn:0,streamingSessionIds:new Set,interruptedSessions:new Set,setConnected:t=>e({connected:t}),setAuthError:t=>e({authError:t}),setConnectionTimedOut:t=>e({connectionTimedOut:t}),setRetryCount:t=>e(e=>({retryCount:typeof t==`function`?t(e.retryCount):t})),setNextRetryIn:t=>e(e=>({nextRetryIn:typeof t==`function`?t(e.nextRetryIn):t})),resetConnection:()=>e({connected:!1,authError:null,connectionTimedOut:!1,retryCount:0,nextRetryIn:0,streamingSessionIds:new Set,interruptedSessions:new Set}),clearStreamingSessions:()=>e({streamingSessionIds:new Set}),addStreamingSession:t=>e(e=>{if(e.streamingSessionIds.has(t))return e;let n=new Set(e.streamingSessionIds);return n.add(t),{streamingSessionIds:n}}),removeStreamingSession:t=>e(e=>{if(!e.streamingSessionIds.has(t))return e;let n=new Set(e.streamingSessionIds);return n.delete(t),{streamingSessionIds:n}}),replaceStreamingSessions:t=>e({streamingSessionIds:t instanceof Set?t:new Set(t)}),addInterruptedSession:t=>e(e=>{if(e.interruptedSessions.has(t))return e;let n=new Set(e.interruptedSessions);return n.add(t),{interruptedSessions:n}}),removeInterruptedSession:t=>e(e=>{if(!e.interruptedSessions.has(t))return e;let n=new Set(e.interruptedSessions);return n.delete(t),{interruptedSessions:n}}),clearInterruptedSessions:()=>e({interruptedSessions:new Set})})),I=t(i(),1),L=e(),R=r();function z(e){var t,n,r=``;if(typeof e==`string`||typeof e==`number`)r+=e;else if(typeof e==`object`)if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=z(e[t]))&&(r&&(r+=` `),r+=n)}else for(n in e)e[n]&&(r&&(r+=` `),r+=n);return r}function oe(){for(var e,t,n=0,r=``,i=arguments.length;n<i;n++)(e=arguments[n])&&(t=z(e))&&(r&&(r+=` `),r+=t);return r}var se=e=>typeof e==`boolean`?`${e}`:e===0?`0`:e,ce=oe,le=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return ce(e,n==null?void 0:n.class,n==null?void 0:n.className);let{variants:i,defaultVariants:a}=t,o=Object.keys(i).map(e=>{let t=n==null?void 0:n[e],r=a==null?void 0:a[e];if(t===null)return null;let o=se(t)||se(r);return i[e][o]}),s=n&&Object.entries(n).reduce((e,t)=>{let[n,r]=t;return r===void 0||(e[n]=r),e},{});return ce(e,o,t==null||(r=t.compoundVariants)==null?void 0:r.reduce((e,t)=>{let{class:n,className:r,...i}=t;return Object.entries(i).every(e=>{let[t,n]=e;return Array.isArray(n)?n.includes({...a,...s}[t]):{...a,...s}[t]===n})?[...e,n,r]:e},[]),n==null?void 0:n.class,n==null?void 0:n.className)};function ue(e,t){if(typeof e==`function`)return e(t);e!=null&&(e.current=t)}function de(...e){return t=>{let n=!1,r=e.map(e=>{let r=ue(e,t);return!n&&typeof r==`function`&&(n=!0),r});if(n)return()=>{for(let t=0;t<r.length;t++){let n=r[t];typeof n==`function`?n():ue(e[t],null)}}}}function B(...e){return x.useCallback(de(...e),e)}function fe(e){let t=me(e),n=x.forwardRef((e,n)=>{let{children:r,...i}=e,a=x.Children.toArray(r),o=a.find(_e);if(o){let e=o.props.children,r=a.map(t=>t===o?x.Children.count(e)>1?x.Children.only(null):x.isValidElement(e)?e.props.children:null:t);return(0,L.jsx)(t,{...i,ref:n,children:x.isValidElement(e)?x.cloneElement(e,void 0,r):null})}return(0,L.jsx)(t,{...i,ref:n,children:r})});return n.displayName=`${e}.Slot`,n}var pe=fe(`Slot`);function me(e){let t=x.forwardRef((e,t)=>{let{children:n,...r}=e;if(x.isValidElement(n)){let e=ye(n),i=ve(r,n.props);return n.type!==x.Fragment&&(i.ref=t?de(t,e):e),x.cloneElement(n,i)}return x.Children.count(n)>1?x.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var he=Symbol(`radix.slottable`);function ge(e){let t=({children:e})=>(0,L.jsx)(L.Fragment,{children:e});return t.displayName=`${e}.Slottable`,t.__radixId=he,t}function _e(e){return x.isValidElement(e)&&typeof e.type==`function`&&`__radixId`in e.type&&e.type.__radixId===he}function ve(e,t){let n={...t};for(let r in t){let i=e[r],a=t[r];/^on[A-Z]/.test(r)?i&&a?n[r]=(...e)=>{let t=a(...e);return i(...e),t}:i&&(n[r]=i):r===`style`?n[r]={...i,...a}:r===`className`&&(n[r]=[i,a].filter(Boolean).join(` `))}return{...e,...n}}function ye(e){var t,n;let r=(t=Object.getOwnPropertyDescriptor(e.props,`ref`))==null?void 0:t.get,i=r&&`isReactWarning`in r&&r.isReactWarning;return i?e.ref:(r=(n=Object.getOwnPropertyDescriptor(e,`ref`))==null?void 0:n.get,i=r&&`isReactWarning`in r&&r.isReactWarning,i?e.props.ref:e.props.ref||e.ref)}var V=[`a`,`button`,`div`,`form`,`h2`,`h3`,`img`,`input`,`label`,`li`,`nav`,`ol`,`p`,`select`,`span`,`svg`,`ul`].reduce((e,t)=>{let n=fe(`Primitive.${t}`),r=x.forwardRef((e,r)=>{let{asChild:i,...a}=e,o=i?n:t;return typeof window<`u`&&(window[Symbol.for(`radix-ui`)]=!0),(0,L.jsx)(o,{...a,ref:r})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function be(e,t){e&&I.flushSync(()=>e.dispatchEvent(t))}var xe=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`}),Se=`VisuallyHidden`,Ce=x.forwardRef((e,t)=>(0,L.jsx)(V.span,{...e,ref:t,style:{...xe,...e.style}}));Ce.displayName=Se;var we=Ce;function Te(e,t){let n=x.createContext(t),r=e=>{let{children:t,...r}=e,i=x.useMemo(()=>r,Object.values(r));return(0,L.jsx)(n.Provider,{value:i,children:t})};r.displayName=e+`Provider`;function i(r){let i=x.useContext(n);if(i)return i;if(t!==void 0)return t;throw Error(`\`${r}\` must be used within \`${e}\``)}return[r,i]}function Ee(e,t=[]){let n=[];function r(t,r){let i=x.createContext(r),a=n.length;n=[...n,r];let o=t=>{var n;let{scope:r,children:o,...s}=t,c=(r==null||(n=r[e])==null?void 0:n[a])||i,l=x.useMemo(()=>s,Object.values(s));return(0,L.jsx)(c.Provider,{value:l,children:o})};o.displayName=t+`Provider`;function s(n,o){var s;let c=(o==null||(s=o[e])==null?void 0:s[a])||i,l=x.useContext(c);if(l)return l;if(r!==void 0)return r;throw Error(`\`${n}\` must be used within \`${t}\``)}return[o,s]}let i=()=>{let t=n.map(e=>x.createContext(e));return function(n){let r=(n==null?void 0:n[e])||t;return x.useMemo(()=>({[`__scope${e}`]:{...n,[e]:r}}),[n,r])}};return i.scopeName=e,[r,De(i,...t)]}function De(...e){let t=e[0];if(e.length===1)return t;let n=()=>{let n=e.map(e=>({useScope:e(),scopeName:e.scopeName}));return function(e){let r=n.reduce((t,{useScope:n,scopeName:r})=>{let i=n(e)[`__scope${r}`];return{...t,...i}},{});return x.useMemo(()=>({[`__scope${t.scopeName}`]:r}),[r])}};return n.scopeName=t.scopeName,n}function Oe(e){let t=e+`CollectionProvider`,[n,r]=Ee(t),[i,a]=n(t,{collectionRef:{current:null},itemMap:new Map}),o=e=>{let{scope:t,children:n}=e,r=x.useRef(null),a=x.useRef(new Map).current;return(0,L.jsx)(i,{scope:t,itemMap:a,collectionRef:r,children:n})};o.displayName=t;let s=e+`CollectionSlot`,c=fe(s),l=x.forwardRef((e,t)=>{let{scope:n,children:r}=e;return(0,L.jsx)(c,{ref:B(t,a(s,n).collectionRef),children:r})});l.displayName=s;let u=e+`CollectionItemSlot`,d=`data-radix-collection-item`,f=fe(u),p=x.forwardRef((e,t)=>{let{scope:n,children:r,...i}=e,o=x.useRef(null),s=B(t,o),c=a(u,n);return x.useEffect(()=>(c.itemMap.set(o,{ref:o,...i}),()=>void c.itemMap.delete(o))),(0,L.jsx)(f,{[d]:``,ref:s,children:r})});p.displayName=u;function m(t){let n=a(e+`CollectionConsumer`,t);return x.useCallback(()=>{let e=n.collectionRef.current;if(!e)return[];let t=Array.from(e.querySelectorAll(`[${d}]`));return Array.from(n.itemMap.values()).sort((e,n)=>t.indexOf(e.ref.current)-t.indexOf(n.ref.current))},[n.collectionRef,n.itemMap])}return[{Provider:o,Slot:l,ItemSlot:p},m,r]}typeof window<`u`&&window.document&&window.document.createElement;function H(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e==null||e(r),n===!1||!r.defaultPrevented)return t==null?void 0:t(r)}}var ke,Ae=(ke=globalThis)!=null&&ke.document?x.useLayoutEffect:()=>{},je=x.useInsertionEffect||Ae;function Me({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){let[i,a,o]=Ne({defaultProp:t,onChange:n}),s=e!==void 0,c=s?e:i;{let t=x.useRef(e!==void 0);x.useEffect(()=>{let e=t.current;e!==s&&console.warn(`${r} is changing from ${e?`controlled`:`uncontrolled`} to ${s?`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.`),t.current=s},[s,r])}return[c,x.useCallback(t=>{if(s){let r=Pe(t)?t(e):t;if(r!==e){var n;(n=o.current)==null||n.call(o,r)}}else a(t)},[s,e,a,o])]}function Ne({defaultProp:e,onChange:t}){let[n,r]=x.useState(e),i=x.useRef(n),a=x.useRef(t);return je(()=>{a.current=t},[t]),x.useEffect(()=>{if(i.current!==n){var e;(e=a.current)==null||e.call(a,n),i.current=n}},[n,i]),[n,r,a]}function Pe(e){return typeof e==`function`}function Fe(e,t){return x.useReducer((e,n)=>{let r=t[e][n];return r==null?e:r},e)}var U=e=>{let{present:t,children:n}=e,r=Ie(t),i=typeof n==`function`?n({present:r.isPresent}):x.Children.only(n),a=B(r.ref,Re(i));return typeof n==`function`||r.isPresent?x.cloneElement(i,{ref:a}):null};U.displayName=`Presence`;function Ie(e){let[t,n]=x.useState(),r=x.useRef(null),i=x.useRef(e),a=x.useRef(`none`),[o,s]=Fe(e?`mounted`:`unmounted`,{mounted:{UNMOUNT:`unmounted`,ANIMATION_OUT:`unmountSuspended`},unmountSuspended:{MOUNT:`mounted`,ANIMATION_END:`unmounted`},unmounted:{MOUNT:`mounted`}});return x.useEffect(()=>{let e=Le(r.current);a.current=o===`mounted`?e:`none`},[o]),Ae(()=>{let t=r.current,n=i.current;if(n!==e){let r=a.current,o=Le(t);e?s(`MOUNT`):o===`none`||(t==null?void 0:t.display)===`none`?s(`UNMOUNT`):s(n&&r!==o?`ANIMATION_OUT`:`UNMOUNT`),i.current=e}},[e,s]),Ae(()=>{if(t){var e;let n,o=(e=t.ownerDocument.defaultView)==null?window:e,c=e=>{let a=Le(r.current).includes(CSS.escape(e.animationName));if(e.target===t&&a&&(s(`ANIMATION_END`),!i.current)){let e=t.style.animationFillMode;t.style.animationFillMode=`forwards`,n=o.setTimeout(()=>{t.style.animationFillMode===`forwards`&&(t.style.animationFillMode=e)})}},l=e=>{e.target===t&&(a.current=Le(r.current))};return t.addEventListener(`animationstart`,l),t.addEventListener(`animationcancel`,c),t.addEventListener(`animationend`,c),()=>{o.clearTimeout(n),t.removeEventListener(`animationstart`,l),t.removeEventListener(`animationcancel`,c),t.removeEventListener(`animationend`,c)}}else s(`ANIMATION_END`)},[t,s]),{isPresent:[`mounted`,`unmountSuspended`].includes(o),ref:x.useCallback(e=>{r.current=e?getComputedStyle(e):null,n(e)},[])}}function Le(e){return(e==null?void 0:e.animationName)||`none`}function Re(e){var t,n;let r=(t=Object.getOwnPropertyDescriptor(e.props,`ref`))==null?void 0:t.get,i=r&&`isReactWarning`in r&&r.isReactWarning;return i?e.ref:(r=(n=Object.getOwnPropertyDescriptor(e,`ref`))==null?void 0:n.get,i=r&&`isReactWarning`in r&&r.isReactWarning,i?e.props.ref:e.props.ref||e.ref)}var ze=x.useId||(()=>void 0),Be=0;function W(e){let[t,n]=x.useState(ze());return Ae(()=>{e||n(e=>e==null?String(Be++):e)},[e]),e||(t?`radix-${t}`:``)}var Ve=`Collapsible`,[He,Ue]=Ee(Ve),[We,Ge]=He(Ve),Ke=x.forwardRef((e,t)=>{let{__scopeCollapsible:n,open:r,defaultOpen:i,disabled:a,onOpenChange:o,...s}=e,[c,l]=Me({prop:r,defaultProp:i==null?!1:i,onChange:o,caller:Ve});return(0,L.jsx)(We,{scope:n,disabled:a,contentId:W(),open:c,onOpenToggle:x.useCallback(()=>l(e=>!e),[l]),children:(0,L.jsx)(V.div,{"data-state":Qe(c),"data-disabled":a?``:void 0,...s,ref:t})})});Ke.displayName=Ve;var qe=`CollapsibleTrigger`,Je=x.forwardRef((e,t)=>{let{__scopeCollapsible:n,...r}=e,i=Ge(qe,n);return(0,L.jsx)(V.button,{type:`button`,"aria-controls":i.contentId,"aria-expanded":i.open||!1,"data-state":Qe(i.open),"data-disabled":i.disabled?``:void 0,disabled:i.disabled,...r,ref:t,onClick:H(e.onClick,i.onOpenToggle)})});Je.displayName=qe;var Ye=`CollapsibleContent`,Xe=x.forwardRef((e,t)=>{let{forceMount:n,...r}=e,i=Ge(Ye,e.__scopeCollapsible);return(0,L.jsx)(U,{present:n||i.open,children:({present:e})=>(0,L.jsx)(Ze,{...r,ref:t,present:e})})});Xe.displayName=Ye;var Ze=x.forwardRef((e,t)=>{let{__scopeCollapsible:n,present:r,children:i,...a}=e,o=Ge(Ye,n),[s,c]=x.useState(r),l=x.useRef(null),u=B(t,l),d=x.useRef(0),f=d.current,p=x.useRef(0),m=p.current,h=o.open||s,g=x.useRef(h),_=x.useRef(void 0);return x.useEffect(()=>{let e=requestAnimationFrame(()=>g.current=!1);return()=>cancelAnimationFrame(e)},[]),Ae(()=>{let e=l.current;if(e){_.current=_.current||{transitionDuration:e.style.transitionDuration,animationName:e.style.animationName},e.style.transitionDuration=`0s`,e.style.animationName=`none`;let t=e.getBoundingClientRect();d.current=t.height,p.current=t.width,g.current||(e.style.transitionDuration=_.current.transitionDuration,e.style.animationName=_.current.animationName),c(r)}},[o.open,r]),(0,L.jsx)(V.div,{"data-state":Qe(o.open),"data-disabled":o.disabled?``:void 0,id:o.contentId,hidden:!h,...a,ref:u,style:{"--radix-collapsible-content-height":f?`${f}px`:void 0,"--radix-collapsible-content-width":m?`${m}px`:void 0,...e.style},children:h&&i})});function Qe(e){return e?`open`:`closed`}var $e=Ke,et=x.createContext(void 0);function tt(e){let t=x.useContext(et);return e||t||`ltr`}function nt(e){let t=x.useRef(e);return x.useEffect(()=>{t.current=e}),x.useMemo(()=>(...e)=>{var n;return(n=t.current)==null?void 0:n.call(t,...e)},[])}function rt(e,t=(()=>{var e;return(e=globalThis)==null?void 0:e.document})()){let n=nt(e);x.useEffect(()=>{let e=e=>{e.key===`Escape`&&n(e)};return t.addEventListener(`keydown`,e,{capture:!0}),()=>t.removeEventListener(`keydown`,e,{capture:!0})},[n,t])}var it=`DismissableLayer`,at=`dismissableLayer.update`,ot=`dismissableLayer.pointerDownOutside`,st=`dismissableLayer.focusOutside`,ct,lt=x.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),ut=x.forwardRef((e,t)=>{var n,r;let{disableOutsidePointerEvents:i=!1,onEscapeKeyDown:a,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:c,onDismiss:l,...u}=e,d=x.useContext(lt),[f,p]=x.useState(null),m=(n=f==null?void 0:f.ownerDocument)==null?(r=globalThis)==null?void 0:r.document:n,[,h]=x.useState({}),g=B(t,e=>p(e)),_=Array.from(d.layers),[v]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),y=_.indexOf(v),b=f?_.indexOf(f):-1,S=d.layersWithOutsidePointerEventsDisabled.size>0,C=b>=y,w=pt(e=>{let t=e.target,n=[...d.branches].some(e=>e.contains(t));!C||n||(o==null||o(e),c==null||c(e),e.defaultPrevented||l==null||l())},m),T=mt(e=>{let t=e.target;[...d.branches].some(e=>e.contains(t))||(s==null||s(e),c==null||c(e),e.defaultPrevented||l==null||l())},m);return rt(e=>{b===d.layers.size-1&&(a==null||a(e),!e.defaultPrevented&&l&&(e.preventDefault(),l()))},m),x.useEffect(()=>{if(f)return i&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(ct=m.body.style.pointerEvents,m.body.style.pointerEvents=`none`),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),ht(),()=>{i&&d.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=ct)}},[f,m,i,d]),x.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),ht())},[f,d]),x.useEffect(()=>{let e=()=>h({});return document.addEventListener(at,e),()=>document.removeEventListener(at,e)},[]),(0,L.jsx)(V.div,{...u,ref:g,style:{pointerEvents:S?C?`auto`:`none`:void 0,...e.style},onFocusCapture:H(e.onFocusCapture,T.onFocusCapture),onBlurCapture:H(e.onBlurCapture,T.onBlurCapture),onPointerDownCapture:H(e.onPointerDownCapture,w.onPointerDownCapture)})});ut.displayName=it;var dt=`DismissableLayerBranch`,ft=x.forwardRef((e,t)=>{let n=x.useContext(lt),r=x.useRef(null),i=B(t,r);return x.useEffect(()=>{let e=r.current;if(e)return n.branches.add(e),()=>{n.branches.delete(e)}},[n.branches]),(0,L.jsx)(V.div,{...e,ref:i})});ft.displayName=dt;function pt(e,t=(()=>{var e;return(e=globalThis)==null?void 0:e.document})()){let n=nt(e),r=x.useRef(!1),i=x.useRef(()=>{});return x.useEffect(()=>{let e=e=>{if(e.target&&!r.current){let r=function(){gt(ot,n,a,{discrete:!0})},a={originalEvent:e};e.pointerType===`touch`?(t.removeEventListener(`click`,i.current),i.current=r,t.addEventListener(`click`,i.current,{once:!0})):r()}else t.removeEventListener(`click`,i.current);r.current=!1},a=window.setTimeout(()=>{t.addEventListener(`pointerdown`,e)},0);return()=>{window.clearTimeout(a),t.removeEventListener(`pointerdown`,e),t.removeEventListener(`click`,i.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function mt(e,t=(()=>{var e;return(e=globalThis)==null?void 0:e.document})()){let n=nt(e),r=x.useRef(!1);return x.useEffect(()=>{let e=e=>{e.target&&!r.current&>(st,n,{originalEvent:e},{discrete:!1})};return t.addEventListener(`focusin`,e),()=>t.removeEventListener(`focusin`,e)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function ht(){let e=new CustomEvent(at);document.dispatchEvent(e)}function gt(e,t,n,{discrete:r}){let i=n.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?be(i,a):i.dispatchEvent(a)}var _t=`focusScope.autoFocusOnMount`,vt=`focusScope.autoFocusOnUnmount`,yt={bubbles:!1,cancelable:!0},bt=`FocusScope`,xt=x.forwardRef((e,t)=>{let{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:a,...o}=e,[s,c]=x.useState(null),l=nt(i),u=nt(a),d=x.useRef(null),f=B(t,e=>c(e)),p=x.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;x.useEffect(()=>{if(r){let e=function(e){if(p.paused||!s)return;let t=e.target;s.contains(t)?d.current=t:Ot(d.current,{select:!0})},t=function(e){if(p.paused||!s)return;let t=e.relatedTarget;t!==null&&(s.contains(t)||Ot(d.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(let t of e)t.removedNodes.length>0&&Ot(s)};document.addEventListener(`focusin`,e),document.addEventListener(`focusout`,t);let r=new MutationObserver(n);return s&&r.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener(`focusin`,e),document.removeEventListener(`focusout`,t),r.disconnect()}}},[r,s,p.paused]),x.useEffect(()=>{if(s){kt.add(p);let e=document.activeElement;if(!s.contains(e)){let t=new CustomEvent(_t,yt);s.addEventListener(_t,l),s.dispatchEvent(t),t.defaultPrevented||(St(Mt(wt(s)),{select:!0}),document.activeElement===e&&Ot(s))}return()=>{s.removeEventListener(_t,l),setTimeout(()=>{let t=new CustomEvent(vt,yt);s.addEventListener(vt,u),s.dispatchEvent(t),t.defaultPrevented||Ot(e==null?document.body:e,{select:!0}),s.removeEventListener(vt,u),kt.remove(p)},0)}}},[s,l,u,p]);let m=x.useCallback(e=>{if(!n&&!r||p.paused)return;let t=e.key===`Tab`&&!e.altKey&&!e.ctrlKey&&!e.metaKey,i=document.activeElement;if(t&&i){let t=e.currentTarget,[r,a]=Ct(t);r&&a?!e.shiftKey&&i===a?(e.preventDefault(),n&&Ot(r,{select:!0})):e.shiftKey&&i===r&&(e.preventDefault(),n&&Ot(a,{select:!0})):i===t&&e.preventDefault()}},[n,r,p.paused]);return(0,L.jsx)(V.div,{tabIndex:-1,...o,ref:f,onKeyDown:m})});xt.displayName=bt;function St(e,{select:t=!1}={}){let n=document.activeElement;for(let r of e)if(Ot(r,{select:t}),document.activeElement!==n)return}function Ct(e){let t=wt(e);return[Tt(t,e),Tt(t.reverse(),e)]}function wt(e){let t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>{let t=e.tagName===`INPUT`&&e.type===`hidden`;return e.disabled||e.hidden||t?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Tt(e,t){for(let n of e)if(!Et(n,{upTo:t}))return n}function Et(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 Dt(e){return e instanceof HTMLInputElement&&`select`in e}function Ot(e,{select:t=!1}={}){if(e&&e.focus){let n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Dt(e)&&t&&e.select()}}var kt=At();function At(){let e=[];return{add(t){let n=e[0];t!==n&&(n==null||n.pause()),e=jt(e,t),e.unshift(t)},remove(t){var n;e=jt(e,t),(n=e[0])==null||n.resume()}}}function jt(e,t){let n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Mt(e){return e.filter(e=>e.tagName!==`A`)}var Nt=`Portal`,Pt=x.forwardRef((e,t)=>{var n;let{container:r,...i}=e,[a,o]=x.useState(!1);Ae(()=>o(!0),[]);let s=r||a&&((n=globalThis)==null||(n=n.document)==null?void 0:n.body);return s?I.createPortal((0,L.jsx)(V.div,{...i,ref:t}),s):null});Pt.displayName=Nt;var Ft=0;function It(){x.useEffect(()=>{var e,t;let n=document.querySelectorAll(`[data-radix-focus-guard]`);return document.body.insertAdjacentElement(`afterbegin`,(e=n[0])==null?Lt():e),document.body.insertAdjacentElement(`beforeend`,(t=n[1])==null?Lt():t),Ft++,()=>{Ft===1&&document.querySelectorAll(`[data-radix-focus-guard]`).forEach(e=>e.remove()),Ft--}},[])}function Lt(){let 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 Rt=function(){return Rt=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n],t)Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},Rt.apply(this,arguments)};function zt(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function Bt(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,a;r<i;r++)(a||!(r in t))&&(a||(a=Array.prototype.slice.call(t,0,r)),a[r]=t[r]);return e.concat(a||Array.prototype.slice.call(t))}var Vt=`right-scroll-bar-position`,Ht=`width-before-scroll-bar`,Ut=`with-scroll-bars-hidden`,Wt=`--removed-body-scroll-bar-size`;function Gt(e,t){return typeof e==`function`?e(t):e&&(e.current=t),e}function Kt(e,t){var n=(0,x.useState)(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(e){var t=n.value;t!==e&&(n.value=e,n.callback(e,t))}}}})[0];return n.callback=t,n.facade}var qt=typeof window<`u`?x.useLayoutEffect:x.useEffect,Jt=new WeakMap;function Yt(e,t){var n=Kt(t||null,function(t){return e.forEach(function(e){return Gt(e,t)})});return qt(function(){var t=Jt.get(n);if(t){var r=new Set(t),i=new Set(e),a=n.current;r.forEach(function(e){i.has(e)||Gt(e,null)}),i.forEach(function(e){r.has(e)||Gt(e,a)})}Jt.set(n,e)},[e]),n}function Xt(e){return e}function Zt(e,t){t===void 0&&(t=Xt);var n=[],r=!1;return{read:function(){if(r)throw 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(e){var i=t(e,r);return n.push(i),function(){n=n.filter(function(e){return e!==i})}},assignSyncMedium:function(e){for(r=!0;n.length;){var t=n;n=[],t.forEach(e)}n={push:function(t){return e(t)},filter:function(){return n}}},assignMedium:function(e){r=!0;var t=[];if(n.length){var i=n;n=[],i.forEach(e),t=n}var a=function(){var n=t;t=[],n.forEach(e)},o=function(){return Promise.resolve().then(a)};o(),n={push:function(e){t.push(e),o()},filter:function(e){return t=t.filter(e),n}}}}}function Qt(e){e===void 0&&(e={});var t=Zt(null);return t.options=Rt({async:!0,ssr:!1},e),t}var $t=function(e){var t=e.sideCar,n=zt(e,[`sideCar`]);if(!t)throw Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw Error(`Sidecar medium not found`);return x.createElement(r,Rt({},n))};$t.isSideCarExport=!0;function en(e,t){return e.useMedium(t),$t}var tn=Qt(),nn=function(){},rn=x.forwardRef(function(e,t){var n=x.useRef(null),r=x.useState({onScrollCapture:nn,onWheelCapture:nn,onTouchMoveCapture:nn}),i=r[0],a=r[1],o=e.forwardProps,s=e.children,c=e.className,l=e.removeScrollBar,u=e.enabled,d=e.shards,f=e.sideCar,p=e.noRelative,m=e.noIsolation,h=e.inert,g=e.allowPinchZoom,_=e.as,v=_===void 0?`div`:_,y=e.gapMode,b=zt(e,[`forwardProps`,`children`,`className`,`removeScrollBar`,`enabled`,`shards`,`sideCar`,`noRelative`,`noIsolation`,`inert`,`allowPinchZoom`,`as`,`gapMode`]),S=f,C=Yt([n,t]),w=Rt(Rt({},b),i);return x.createElement(x.Fragment,null,u&&x.createElement(S,{sideCar:tn,removeScrollBar:l,shards:d,noRelative:p,noIsolation:m,inert:h,setCallbacks:a,allowPinchZoom:!!g,lockRef:n,gapMode:y}),o?x.cloneElement(x.Children.only(s),Rt(Rt({},w),{ref:C})):x.createElement(v,Rt({},w,{className:c,ref:C}),s))});rn.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},rn.classNames={fullWidth:Ht,zeroRight:Vt};var an,on=function(){if(an)return an;if(typeof __webpack_nonce__<`u`)return __webpack_nonce__};function sn(){if(!document)return null;var e=document.createElement(`style`);e.type=`text/css`;var t=on();return t&&e.setAttribute(`nonce`,t),e}function cn(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function ln(e){(document.head||document.getElementsByTagName(`head`)[0]).appendChild(e)}var un=function(){var e=0,t=null;return{add:function(n){e==0&&(t=sn())&&(cn(t,n),ln(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},dn=function(){var e=un();return function(t,n){x.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},fn=function(){var e=dn();return function(t){var n=t.styles,r=t.dynamic;return e(n,r),null}},pn={left:0,top:0,right:0,gap:0},mn=function(e){return parseInt(e||``,10)||0},hn=function(e){var t=window.getComputedStyle(document.body),n=t[e===`padding`?`paddingLeft`:`marginLeft`],r=t[e===`padding`?`paddingTop`:`marginTop`],i=t[e===`padding`?`paddingRight`:`marginRight`];return[mn(n),mn(r),mn(i)]},gn=function(e){if(e===void 0&&(e=`margin`),typeof window>`u`)return pn;var t=hn(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},_n=fn(),vn=`data-scroll-locked`,yn=function(e,t,n,r){var i=e.left,a=e.top,o=e.right,s=e.gap;return n===void 0&&(n=`margin`),`
|
|
2
|
-
.${Ut} {
|
|
3
|
-
overflow: hidden ${r};
|
|
4
|
-
padding-right: ${s}px ${r};
|
|
5
|
-
}
|
|
6
|
-
body[${vn}] {
|
|
7
|
-
overflow: hidden ${r};
|
|
8
|
-
overscroll-behavior: contain;
|
|
9
|
-
${[t&&`position: relative ${r};`,n===`margin`&&`
|
|
10
|
-
padding-left: ${i}px;
|
|
11
|
-
padding-top: ${a}px;
|
|
12
|
-
padding-right: ${o}px;
|
|
13
|
-
margin-left:0;
|
|
14
|
-
margin-top:0;
|
|
15
|
-
margin-right: ${s}px ${r};
|
|
16
|
-
`,n===`padding`&&`padding-right: ${s}px ${r};`].filter(Boolean).join(``)}
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
.${Vt} {
|
|
20
|
-
right: ${s}px ${r};
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
.${Ht} {
|
|
24
|
-
margin-right: ${s}px ${r};
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
.${Vt} .${Vt} {
|
|
28
|
-
right: 0 ${r};
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
.${Ht} .${Ht} {
|
|
32
|
-
margin-right: 0 ${r};
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
body[${vn}] {
|
|
36
|
-
${Wt}: ${s}px;
|
|
37
|
-
}
|
|
38
|
-
`},bn=function(){var e=parseInt(document.body.getAttribute(`data-scroll-locked`)||`0`,10);return isFinite(e)?e:0},xn=function(){x.useEffect(function(){return document.body.setAttribute(vn,(bn()+1).toString()),function(){var e=bn()-1;e<=0?document.body.removeAttribute(vn):document.body.setAttribute(vn,e.toString())}},[])},Sn=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?`margin`:r;xn();var a=x.useMemo(function(){return gn(i)},[i]);return x.createElement(_n,{styles:yn(a,!t,i,n?``:`!important`)})},Cn=!1;if(typeof window<`u`)try{var wn=Object.defineProperty({},`passive`,{get:function(){return Cn=!0,!0}});window.addEventListener(`test`,wn,wn),window.removeEventListener(`test`,wn,wn)}catch{Cn=!1}var Tn=Cn?{passive:!1}:!1,En=function(e){return e.tagName===`TEXTAREA`},Dn=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!==`hidden`&&!(n.overflowY===n.overflowX&&!En(e)&&n[t]===`visible`)},On=function(e){return Dn(e,`overflowY`)},kn=function(e){return Dn(e,`overflowX`)},An=function(e,t){var n=t.ownerDocument,r=t;do{if(typeof ShadowRoot<`u`&&r instanceof ShadowRoot&&(r=r.host),Nn(e,r)){var i=Pn(e,r);if(i[1]>i[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},jn=function(e){return[e.scrollTop,e.scrollHeight,e.clientHeight]},Mn=function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]},Nn=function(e,t){return e===`v`?On(t):kn(t)},Pn=function(e,t){return e===`v`?jn(t):Mn(t)},Fn=function(e,t){return e===`h`&&t===`rtl`?-1:1},In=function(e,t,n,r,i){var a=Fn(e,window.getComputedStyle(t).direction),o=a*r,s=n.target,c=t.contains(s),l=!1,u=o>0,d=0,f=0;do{if(!s)break;var p=Pn(e,s),m=p[0],h=p[1]-p[2]-a*m;(m||h)&&Nn(e,s)&&(d+=h,f+=m);var g=s.parentNode;s=g&&g.nodeType===Node.DOCUMENT_FRAGMENT_NODE?g.host:g}while(!c&&s!==document.body||c&&(t.contains(s)||t===s));return(u&&(i&&Math.abs(d)<1||!i&&o>d)||!u&&(i&&Math.abs(f)<1||!i&&-o>f))&&(l=!0),l},Ln=function(e){return`changedTouches`in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Rn=function(e){return[e.deltaX,e.deltaY]},zn=function(e){return e&&`current`in e?e.current:e},Bn=function(e,t){return e[0]===t[0]&&e[1]===t[1]},Vn=function(e){return`
|
|
39
|
-
.block-interactivity-${e} {pointer-events: none;}
|
|
40
|
-
.allow-interactivity-${e} {pointer-events: all;}
|
|
41
|
-
`},Hn=0,Un=[];function Wn(e){var t=x.useRef([]),n=x.useRef([0,0]),r=x.useRef(),i=x.useState(Hn++)[0],a=x.useState(fn)[0],o=x.useRef(e);x.useEffect(function(){o.current=e},[e]),x.useEffect(function(){if(e.inert){document.body.classList.add(`block-interactivity-${i}`);var t=Bt([e.lockRef.current],(e.shards||[]).map(zn),!0).filter(Boolean);return t.forEach(function(e){return e.classList.add(`allow-interactivity-${i}`)}),function(){document.body.classList.remove(`block-interactivity-${i}`),t.forEach(function(e){return e.classList.remove(`allow-interactivity-${i}`)})}}},[e.inert,e.lockRef.current,e.shards]);var s=x.useCallback(function(e,t){if(`touches`in e&&e.touches.length===2||e.type===`wheel`&&e.ctrlKey)return!o.current.allowPinchZoom;var i=Ln(e),a=n.current,s=`deltaX`in e?e.deltaX:a[0]-i[0],c=`deltaY`in e?e.deltaY:a[1]-i[1],l,u=e.target,d=Math.abs(s)>Math.abs(c)?`h`:`v`;if(`touches`in e&&d===`h`&&u.type===`range`)return!1;var f=window.getSelection(),p=f&&f.anchorNode;if(p&&(p===u||p.contains(u)))return!1;var m=An(d,u);if(!m)return!0;if(m?l=d:(l=d===`v`?`h`:`v`,m=An(d,u)),!m)return!1;if(!r.current&&`changedTouches`in e&&(s||c)&&(r.current=l),!l)return!0;var h=r.current||l;return In(h,t,e,h===`h`?s:c,!0)},[]),c=x.useCallback(function(e){var n=e;if(!(!Un.length||Un[Un.length-1]!==a)){var r=`deltaY`in n?Rn(n):Ln(n),i=t.current.filter(function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&Bn(e.delta,r)})[0];if(i&&i.should){n.cancelable&&n.preventDefault();return}if(!i){var c=(o.current.shards||[]).map(zn).filter(Boolean).filter(function(e){return e.contains(n.target)});(c.length>0?s(n,c[0]):!o.current.noIsolation)&&n.cancelable&&n.preventDefault()}}},[]),l=x.useCallback(function(e,n,r,i){var a={name:e,delta:n,target:r,should:i,shadowParent:Gn(r)};t.current.push(a),setTimeout(function(){t.current=t.current.filter(function(e){return e!==a})},1)},[]),u=x.useCallback(function(e){n.current=Ln(e),r.current=void 0},[]),d=x.useCallback(function(t){l(t.type,Rn(t),t.target,s(t,e.lockRef.current))},[]),f=x.useCallback(function(t){l(t.type,Ln(t),t.target,s(t,e.lockRef.current))},[]);x.useEffect(function(){return Un.push(a),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:f}),document.addEventListener(`wheel`,c,Tn),document.addEventListener(`touchmove`,c,Tn),document.addEventListener(`touchstart`,u,Tn),function(){Un=Un.filter(function(e){return e!==a}),document.removeEventListener(`wheel`,c,Tn),document.removeEventListener(`touchmove`,c,Tn),document.removeEventListener(`touchstart`,u,Tn)}},[]);var p=e.removeScrollBar,m=e.inert;return x.createElement(x.Fragment,null,m?x.createElement(a,{styles:Vn(i)}):null,p?x.createElement(Sn,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function Gn(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}var Kn=en(tn,Wn),qn=x.forwardRef(function(e,t){return x.createElement(rn,Rt({},e,{ref:t,sideCar:Kn}))});qn.classNames=rn.classNames;var Jn=function(e){return typeof document>`u`?null:(Array.isArray(e)?e[0]:e).ownerDocument.body},Yn=new WeakMap,Xn=new WeakMap,Zn={},Qn=0,$n=function(e){return e&&(e.host||$n(e.parentNode))},er=function(e,t){return t.map(function(t){if(e.contains(t))return t;var n=$n(t);return n&&e.contains(n)?n:(console.error(`aria-hidden`,t,`in not contained inside`,e,`. Doing nothing`),null)}).filter(function(e){return!!e})},tr=function(e,t,n,r){var i=er(t,Array.isArray(e)?e:[e]);Zn[n]||(Zn[n]=new WeakMap);var a=Zn[n],o=[],s=new Set,c=new Set(i),l=function(e){!e||s.has(e)||(s.add(e),l(e.parentNode))};i.forEach(l);var u=function(e){!e||c.has(e)||Array.prototype.forEach.call(e.children,function(e){if(s.has(e))u(e);else try{var t=e.getAttribute(r),i=t!==null&&t!==`false`,c=(Yn.get(e)||0)+1,l=(a.get(e)||0)+1;Yn.set(e,c),a.set(e,l),o.push(e),c===1&&i&&Xn.set(e,!0),l===1&&e.setAttribute(n,`true`),i||e.setAttribute(r,`true`)}catch(t){console.error(`aria-hidden: cannot operate on `,e,t)}})};return u(t),s.clear(),Qn++,function(){o.forEach(function(e){var t=Yn.get(e)-1,i=a.get(e)-1;Yn.set(e,t),a.set(e,i),t||(Xn.has(e)||e.removeAttribute(r),Xn.delete(e)),i||e.removeAttribute(n)}),Qn--,Qn||(Yn=new WeakMap,Yn=new WeakMap,Xn=new WeakMap,Zn={})}},nr=function(e,t,n){n===void 0&&(n=`data-aria-hidden`);var r=Array.from(Array.isArray(e)?e:[e]),i=t||Jn(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll(`[aria-live], script`))),tr(r,i,n,`aria-hidden`)):function(){return null}},rr=`Dialog`,[ir,ar]=Ee(rr),[or,sr]=ir(rr),cr=e=>{let{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!0}=e,s=x.useRef(null),c=x.useRef(null),[l,u]=Me({prop:r,defaultProp:i==null?!1:i,onChange:a,caller:rr});return(0,L.jsx)(or,{scope:t,triggerRef:s,contentRef:c,contentId:W(),titleId:W(),descriptionId:W(),open:l,onOpenChange:u,onOpenToggle:x.useCallback(()=>u(e=>!e),[u]),modal:o,children:n})};cr.displayName=rr;var lr=`DialogTrigger`,ur=x.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=sr(lr,n),a=B(t,i.triggerRef);return(0,L.jsx)(V.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":i.open,"aria-controls":i.contentId,"data-state":Ar(i.open),...r,ref:a,onClick:H(e.onClick,i.onOpenToggle)})});ur.displayName=lr;var dr=`DialogPortal`,[fr,pr]=ir(dr,{forceMount:void 0}),mr=e=>{let{__scopeDialog:t,forceMount:n,children:r,container:i}=e,a=sr(dr,t);return(0,L.jsx)(fr,{scope:t,forceMount:n,children:x.Children.map(r,e=>(0,L.jsx)(U,{present:n||a.open,children:(0,L.jsx)(Pt,{asChild:!0,container:i,children:e})}))})};mr.displayName=dr;var hr=`DialogOverlay`,gr=x.forwardRef((e,t)=>{let n=pr(hr,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=sr(hr,e.__scopeDialog);return a.modal?(0,L.jsx)(U,{present:r||a.open,children:(0,L.jsx)(vr,{...i,ref:t})}):null});gr.displayName=hr;var _r=fe(`DialogOverlay.RemoveScroll`),vr=x.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=sr(hr,n);return(0,L.jsx)(qn,{as:_r,allowPinchZoom:!0,shards:[i.contentRef],children:(0,L.jsx)(V.div,{"data-state":Ar(i.open),...r,ref:t,style:{pointerEvents:`auto`,...r.style}})})}),yr=`DialogContent`,br=x.forwardRef((e,t)=>{let n=pr(yr,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=sr(yr,e.__scopeDialog);return(0,L.jsx)(U,{present:r||a.open,children:a.modal?(0,L.jsx)(xr,{...i,ref:t}):(0,L.jsx)(Sr,{...i,ref:t})})});br.displayName=yr;var xr=x.forwardRef((e,t)=>{let n=sr(yr,e.__scopeDialog),r=x.useRef(null),i=B(t,n.contentRef,r);return x.useEffect(()=>{let e=r.current;if(e)return nr(e)},[]),(0,L.jsx)(Cr,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:H(e.onCloseAutoFocus,e=>{var t;e.preventDefault(),(t=n.triggerRef.current)==null||t.focus()}),onPointerDownOutside:H(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;(t.button===2||n)&&e.preventDefault()}),onFocusOutside:H(e.onFocusOutside,e=>e.preventDefault())})}),Sr=x.forwardRef((e,t)=>{let n=sr(yr,e.__scopeDialog),r=x.useRef(!1),i=x.useRef(!1);return(0,L.jsx)(Cr,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{var a;if((a=e.onCloseAutoFocus)==null||a.call(e,t),!t.defaultPrevented){var o;r.current||(o=n.triggerRef.current)==null||o.focus(),t.preventDefault()}r.current=!1,i.current=!1},onInteractOutside:t=>{var a,o;(a=e.onInteractOutside)==null||a.call(e,t),t.defaultPrevented||(r.current=!0,t.detail.originalEvent.type===`pointerdown`&&(i.current=!0));let s=t.target;(o=n.triggerRef.current)!=null&&o.contains(s)&&t.preventDefault(),t.detail.originalEvent.type===`focusin`&&i.current&&t.preventDefault()}})}),Cr=x.forwardRef((e,t)=>{let{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:a,...o}=e,s=sr(yr,n),c=x.useRef(null),l=B(t,c);return It(),(0,L.jsxs)(L.Fragment,{children:[(0,L.jsx)(xt,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:a,children:(0,L.jsx)(ut,{role:`dialog`,id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":Ar(s.open),...o,ref:l,onDismiss:()=>s.onOpenChange(!1)})}),(0,L.jsxs)(L.Fragment,{children:[(0,L.jsx)(Pr,{titleId:s.titleId}),(0,L.jsx)(Ir,{contentRef:c,descriptionId:s.descriptionId})]})]})}),wr=`DialogTitle`,Tr=x.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=sr(wr,n);return(0,L.jsx)(V.h2,{id:i.titleId,...r,ref:t})});Tr.displayName=wr;var Er=`DialogDescription`,Dr=x.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=sr(Er,n);return(0,L.jsx)(V.p,{id:i.descriptionId,...r,ref:t})});Dr.displayName=Er;var Or=`DialogClose`,kr=x.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=sr(Or,n);return(0,L.jsx)(V.button,{type:`button`,...r,ref:t,onClick:H(e.onClick,()=>i.onOpenChange(!1))})});kr.displayName=Or;function Ar(e){return e?`open`:`closed`}var jr=`DialogTitleWarning`,[Mr,Nr]=Te(jr,{contentName:yr,titleName:wr,docsSlug:`dialog`}),Pr=({titleId:e})=>{let t=Nr(jr),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 x.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},Fr=`DialogDescriptionWarning`,Ir=({contentRef:e,descriptionId:t})=>{let n=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${Nr(Fr).contentName}}.`;return x.useEffect(()=>{var r;let i=(r=e.current)==null?void 0:r.getAttribute(`aria-describedby`);t&&i&&(document.getElementById(t)||console.warn(n))},[n,e,t]),null},Lr=cr,Rr=mr,zr=gr,Br=br,Vr=Tr,Hr=Dr,Ur=kr;function Wr(e){let[t,n]=x.useState(void 0);return Ae(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});let t=new ResizeObserver(t=>{if(!Array.isArray(t)||!t.length)return;let r=t[0],i,a;if(`borderBoxSize`in r){let e=r.borderBoxSize,t=Array.isArray(e)?e[0]:e;i=t.inlineSize,a=t.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return t.observe(e,{box:`border-box`}),()=>t.unobserve(e)}else n(void 0)},[e]),t}var Gr=[`top`,`right`,`bottom`,`left`],Kr=Math.min,G=Math.max,qr=Math.round,Jr=Math.floor,Yr=e=>({x:e,y:e}),Xr={left:`right`,right:`left`,bottom:`top`,top:`bottom`};function Zr(e,t,n){return G(e,Kr(t,n))}function Qr(e,t){return typeof e==`function`?e(t):e}function $r(e){return e.split(`-`)[0]}function ei(e){return e.split(`-`)[1]}function ti(e){return e===`x`?`y`:`x`}function ni(e){return e===`y`?`height`:`width`}function ri(e){let t=e[0];return t===`t`||t===`b`?`y`:`x`}function ii(e){return ti(ri(e))}function ai(e,t,n){n===void 0&&(n=!1);let r=ei(e),i=ii(e),a=ni(i),o=i===`x`?r===(n?`end`:`start`)?`right`:`left`:r===`start`?`bottom`:`top`;return t.reference[a]>t.floating[a]&&(o=mi(o)),[o,mi(o)]}function oi(e){let t=mi(e);return[si(e),t,si(t)]}function si(e){return e.includes(`start`)?e.replace(`start`,`end`):e.replace(`end`,`start`)}var ci=[`left`,`right`],li=[`right`,`left`],ui=[`top`,`bottom`],di=[`bottom`,`top`];function fi(e,t,n){switch(e){case`top`:case`bottom`:return n?t?li:ci:t?ci:li;case`left`:case`right`:return t?ui:di;default:return[]}}function pi(e,t,n,r){let i=ei(e),a=fi($r(e),n===`start`,r);return i&&(a=a.map(e=>e+`-`+i),t&&(a=a.concat(a.map(si)))),a}function mi(e){let t=$r(e);return Xr[t]+e.slice(t.length)}function hi(e){return{top:0,right:0,bottom:0,left:0,...e}}function gi(e){return typeof e==`number`?{top:e,right:e,bottom:e,left:e}:hi(e)}function _i(e){let{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function vi(e,t,n){let{reference:r,floating:i}=e,a=ri(t),o=ii(t),s=ni(o),c=$r(t),l=a===`y`,u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2,p;switch(c){case`top`:p={x:u,y:r.y-i.height};break;case`bottom`:p={x:u,y:r.y+r.height};break;case`right`:p={x:r.x+r.width,y:d};break;case`left`:p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}switch(ei(t)){case`start`:p[o]-=f*(n&&l?-1:1);break;case`end`:p[o]+=f*(n&&l?-1:1);break}return p}async function yi(e,t){var n;t===void 0&&(t={});let{x:r,y:i,platform:a,rects:o,elements:s,strategy:c}=e,{boundary:l=`clippingAncestors`,rootBoundary:u=`viewport`,elementContext:d=`floating`,altBoundary:f=!1,padding:p=0}=Qr(t,e),m=gi(p),h=s[f?d===`floating`?`reference`:`floating`:d],g=_i(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(h)))==null||n?h:h.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(s.floating)),boundary:l,rootBoundary:u,strategy:c})),_=d===`floating`?{x:r,y:i,width:o.floating.width,height:o.floating.height}:o.reference,v=await(a.getOffsetParent==null?void 0:a.getOffsetParent(s.floating)),y=await(a.isElement==null?void 0:a.isElement(v))&&await(a.getScale==null?void 0:a.getScale(v))||{x:1,y:1},b=_i(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:_,offsetParent:v,strategy:c}):_);return{top:(g.top-b.top+m.top)/y.y,bottom:(b.bottom-g.bottom+m.bottom)/y.y,left:(g.left-b.left+m.left)/y.x,right:(b.right-g.right+m.right)/y.x}}var bi=50,xi=async(e,t,n)=>{let{placement:r=`bottom`,strategy:i=`absolute`,middleware:a=[],platform:o}=n,s=o.detectOverflow?o:{...o,detectOverflow:yi},c=await(o.isRTL==null?void 0:o.isRTL(t)),l=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=vi(l,r,c),f=r,p=0,m={};for(let n=0;n<a.length;n++){let h=a[n];if(!h)continue;let{name:g,fn:_}=h,{x:v,y,data:b,reset:x}=await _({x:u,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:m,rects:l,platform:s,elements:{reference:e,floating:t}});u=v==null?u:v,d=y==null?d:y,m[g]={...m[g],...b},x&&p<bi&&(p++,typeof x==`object`&&(x.placement&&(f=x.placement),x.rects&&(l=x.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):x.rects),{x:u,y:d}=vi(l,f,c)),n=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:m}},Si=e=>({name:`arrow`,options:e,async fn(t){let{x:n,y:r,placement:i,rects:a,platform:o,elements:s,middlewareData:c}=t,{element:l,padding:u=0}=Qr(e,t)||{};if(l==null)return{};let d=gi(u),f={x:n,y:r},p=ii(i),m=ni(p),h=await o.getDimensions(l),g=p===`y`,_=g?`top`:`left`,v=g?`bottom`:`right`,y=g?`clientHeight`:`clientWidth`,b=a.reference[m]+a.reference[p]-f[p]-a.floating[m],x=f[p]-a.reference[p],S=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l)),C=S?S[y]:0;(!C||!await(o.isElement==null?void 0:o.isElement(S)))&&(C=s.floating[y]||a.floating[m]);let w=b/2-x/2,T=C/2-h[m]/2-1,E=Kr(d[_],T),D=Kr(d[v],T),O=E,k=C-h[m]-D,A=C/2-h[m]/2+w,j=Zr(O,A,k),M=!c.arrow&&ei(i)!=null&&A!==j&&a.reference[m]/2-(A<O?E:D)-h[m]/2<0,N=M?A<O?A-O:A-k:0;return{[p]:f[p]+N,data:{[p]:j,centerOffset:A-j-N,...M&&{alignmentOffset:N}},reset:M}}}),Ci=function(e){return e===void 0&&(e={}),{name:`flip`,options:e,async fn(t){var n,r;let{placement:i,middlewareData:a,rects:o,initialPlacement:s,platform:c,elements:l}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:p=`bestFit`,fallbackAxisSideDirection:m=`none`,flipAlignment:h=!0,...g}=Qr(e,t);if((n=a.arrow)!=null&&n.alignmentOffset)return{};let _=$r(i),v=ri(s),y=$r(s)===s,b=await(c.isRTL==null?void 0:c.isRTL(l.floating)),x=f||(y||!h?[mi(s)]:oi(s)),S=m!==`none`;!f&&S&&x.push(...pi(s,h,m,b));let C=[s,...x],w=await c.detectOverflow(t,g),T=[],E=((r=a.flip)==null?void 0:r.overflows)||[];if(u&&T.push(w[_]),d){let e=ai(i,o,b);T.push(w[e[0]],w[e[1]])}if(E=[...E,{placement:i,overflows:T}],!T.every(e=>e<=0)){var D,O;let e=(((D=a.flip)==null?void 0:D.index)||0)+1,t=C[e];if(t&&(!(d===`alignment`&&v!==ri(t))||E.every(e=>ri(e.placement)===v?e.overflows[0]>0:!0)))return{data:{index:e,overflows:E},reset:{placement:t}};let n=(O=E.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])==null?void 0:O.placement;if(!n)switch(p){case`bestFit`:{var k;let e=(k=E.filter(e=>{if(S){let t=ri(e.placement);return t===v||t===`y`}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])==null?void 0:k[0];e&&(n=e);break}case`initialPlacement`:n=s;break}if(i!==n)return{reset:{placement:n}}}return{}}}};function wi(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Ti(e){return Gr.some(t=>e[t]>=0)}var Ei=function(e){return e===void 0&&(e={}),{name:`hide`,options:e,async fn(t){let{rects:n,platform:r}=t,{strategy:i=`referenceHidden`,...a}=Qr(e,t);switch(i){case`referenceHidden`:{let e=wi(await r.detectOverflow(t,{...a,elementContext:`reference`}),n.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:Ti(e)}}}case`escaped`:{let e=wi(await r.detectOverflow(t,{...a,altBoundary:!0}),n.floating);return{data:{escapedOffsets:e,escaped:Ti(e)}}}default:return{}}}}},Di=new Set([`left`,`top`]);async function Oi(e,t){let{placement:n,platform:r,elements:i}=e,a=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=$r(n),s=ei(n),c=ri(n)===`y`,l=Di.has(o)?-1:1,u=a&&c?-1:1,d=Qr(t,e),{mainAxis:f,crossAxis:p,alignmentAxis:m}=typeof d==`number`?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof m==`number`&&(p=s===`end`?m*-1:m),c?{x:p*u,y:f*l}:{x:f*l,y:p*u}}var ki=function(e){return e===void 0&&(e=0),{name:`offset`,options:e,async fn(t){var n,r;let{x:i,y:a,placement:o,middlewareData:s}=t,c=await Oi(t,e);return o===((n=s.offset)==null?void 0:n.placement)&&(r=s.arrow)!=null&&r.alignmentOffset?{}:{x:i+c.x,y:a+c.y,data:{...c,placement:o}}}}},Ai=function(e){return e===void 0&&(e={}),{name:`shift`,options:e,async fn(t){let{x:n,y:r,placement:i,platform:a}=t,{mainAxis:o=!0,crossAxis:s=!1,limiter:c={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=Qr(e,t),u={x:n,y:r},d=await a.detectOverflow(t,l),f=ri($r(i)),p=ti(f),m=u[p],h=u[f];if(o){let e=p===`y`?`top`:`left`,t=p===`y`?`bottom`:`right`,n=m+d[e],r=m-d[t];m=Zr(n,m,r)}if(s){let e=f===`y`?`top`:`left`,t=f===`y`?`bottom`:`right`,n=h+d[e],r=h-d[t];h=Zr(n,h,r)}let g=c.fn({...t,[p]:m,[f]:h});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[p]:o,[f]:s}}}}}},ji=function(e){return e===void 0&&(e={}),{options:e,fn(t){let{x:n,y:r,placement:i,rects:a,middlewareData:o}=t,{offset:s=0,mainAxis:c=!0,crossAxis:l=!0}=Qr(e,t),u={x:n,y:r},d=ri(i),f=ti(d),p=u[f],m=u[d],h=Qr(s,t),g=typeof h==`number`?{mainAxis:h,crossAxis:0}:{mainAxis:0,crossAxis:0,...h};if(c){let e=f===`y`?`height`:`width`,t=a.reference[f]-a.floating[e]+g.mainAxis,n=a.reference[f]+a.reference[e]-g.mainAxis;p<t?p=t:p>n&&(p=n)}if(l){var _,v;let e=f===`y`?`width`:`height`,t=Di.has($r(i)),n=a.reference[d]-a.floating[e]+(t&&((_=o.offset)==null?void 0:_[d])||0)+(t?0:g.crossAxis),r=a.reference[d]+a.reference[e]+(t?0:((v=o.offset)==null?void 0:v[d])||0)-(t?g.crossAxis:0);m<n?m=n:m>r&&(m=r)}return{[f]:p,[d]:m}}}},Mi=function(e){return e===void 0&&(e={}),{name:`size`,options:e,async fn(t){var n,r;let{placement:i,rects:a,platform:o,elements:s}=t,{apply:c=()=>{},...l}=Qr(e,t),u=await o.detectOverflow(t,l),d=$r(i),f=ei(i),p=ri(i)===`y`,{width:m,height:h}=a.floating,g,_;d===`top`||d===`bottom`?(g=d,_=f===(await(o.isRTL==null?void 0:o.isRTL(s.floating))?`start`:`end`)?`left`:`right`):(_=d,g=f===`end`?`top`:`bottom`);let v=h-u.top-u.bottom,y=m-u.left-u.right,b=Kr(h-u[g],v),x=Kr(m-u[_],y),S=!t.middlewareData.shift,C=b,w=x;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(w=y),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(C=v),S&&!f){let e=G(u.left,0),t=G(u.right,0),n=G(u.top,0),r=G(u.bottom,0);p?w=m-2*(e!==0||t!==0?e+t:G(u.left,u.right)):C=h-2*(n!==0||r!==0?n+r:G(u.top,u.bottom))}await c({...t,availableWidth:w,availableHeight:C});let T=await o.getDimensions(s.floating);return m!==T.width||h!==T.height?{reset:{rects:!0}}:{}}}};function Ni(){return typeof window<`u`}function Pi(e){return Ii(e)?(e.nodeName||``).toLowerCase():`#document`}function K(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Fi(e){var t;return(t=(Ii(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Ii(e){return Ni()?e instanceof Node||e instanceof K(e).Node:!1}function Li(e){return Ni()?e instanceof Element||e instanceof K(e).Element:!1}function Ri(e){return Ni()?e instanceof HTMLElement||e instanceof K(e).HTMLElement:!1}function zi(e){return!Ni()||typeof ShadowRoot>`u`?!1:e instanceof ShadowRoot||e instanceof K(e).ShadowRoot}function Bi(e){let{overflow:t,overflowX:n,overflowY:r,display:i}=Zi(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&i!==`inline`&&i!==`contents`}function Vi(e){return/^(table|td|th)$/.test(Pi(e))}function Hi(e){try{if(e.matches(`:popover-open`))return!0}catch{}try{return e.matches(`:modal`)}catch{return!1}}var Ui=/transform|translate|scale|rotate|perspective|filter/,Wi=/paint|layout|strict|content/,Gi=e=>!!e&&e!==`none`,Ki;function qi(e){let t=Li(e)?Zi(e):e;return Gi(t.transform)||Gi(t.translate)||Gi(t.scale)||Gi(t.rotate)||Gi(t.perspective)||!Yi()&&(Gi(t.backdropFilter)||Gi(t.filter))||Ui.test(t.willChange||``)||Wi.test(t.contain||``)}function Ji(e){let t=$i(e);for(;Ri(t)&&!Xi(t);){if(qi(t))return t;if(Hi(t))return null;t=$i(t)}return null}function Yi(){return Ki==null&&(Ki=typeof CSS<`u`&&CSS.supports&&CSS.supports(`-webkit-backdrop-filter`,`none`)),Ki}function Xi(e){return/^(html|body|#document)$/.test(Pi(e))}function Zi(e){return K(e).getComputedStyle(e)}function Qi(e){return Li(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function $i(e){if(Pi(e)===`html`)return e;let t=e.assignedSlot||e.parentNode||zi(e)&&e.host||Fi(e);return zi(t)?t.host:t}function ea(e){let t=$i(e);return Xi(t)?e.ownerDocument?e.ownerDocument.body:e.body:Ri(t)&&Bi(t)?t:ea(t)}function ta(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);let i=ea(e),a=i===((r=e.ownerDocument)==null?void 0:r.body),o=K(i);if(a){let e=na(o);return t.concat(o,o.visualViewport||[],Bi(i)?i:[],e&&n?ta(e):[])}else return t.concat(i,ta(i,[],n))}function na(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function ra(e){let t=Zi(e),n=parseFloat(t.width)||0,r=parseFloat(t.height)||0,i=Ri(e),a=i?e.offsetWidth:n,o=i?e.offsetHeight:r,s=qr(n)!==a||qr(r)!==o;return s&&(n=a,r=o),{width:n,height:r,$:s}}function ia(e){return Li(e)?e:e.contextElement}function aa(e){let t=ia(e);if(!Ri(t))return Yr(1);let n=t.getBoundingClientRect(),{width:r,height:i,$:a}=ra(t),o=(a?qr(n.width):n.width)/r,s=(a?qr(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}var oa=Yr(0);function sa(e){let t=K(e);return!Yi()||!t.visualViewport?oa:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function ca(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==K(e)?!1:t}function la(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);let i=e.getBoundingClientRect(),a=ia(e),o=Yr(1);t&&(r?Li(r)&&(o=aa(r)):o=aa(e));let s=ca(a,n,r)?sa(a):Yr(0),c=(i.left+s.x)/o.x,l=(i.top+s.y)/o.y,u=i.width/o.x,d=i.height/o.y;if(a){let e=K(a),t=r&&Li(r)?K(r):r,n=e,i=na(n);for(;i&&r&&t!==n;){let e=aa(i),t=i.getBoundingClientRect(),r=Zi(i),a=t.left+(i.clientLeft+parseFloat(r.paddingLeft))*e.x,o=t.top+(i.clientTop+parseFloat(r.paddingTop))*e.y;c*=e.x,l*=e.y,u*=e.x,d*=e.y,c+=a,l+=o,n=K(i),i=na(n)}}return _i({width:u,height:d,x:c,y:l})}function ua(e,t){let n=Qi(e).scrollLeft;return t?t.left+n:la(Fi(e)).left+n}function da(e,t){let n=e.getBoundingClientRect();return{x:n.left+t.scrollLeft-ua(e,n),y:n.top+t.scrollTop}}function fa(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e,a=i===`fixed`,o=Fi(r),s=t?Hi(t.floating):!1;if(r===o||s&&a)return n;let c={scrollLeft:0,scrollTop:0},l=Yr(1),u=Yr(0),d=Ri(r);if((d||!d&&!a)&&((Pi(r)!==`body`||Bi(o))&&(c=Qi(r)),d)){let e=la(r);l=aa(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}let f=o&&!d&&!a?da(o,c):Yr(0);return{width:n.width*l.x,height:n.height*l.y,x:n.x*l.x-c.scrollLeft*l.x+u.x+f.x,y:n.y*l.y-c.scrollTop*l.y+u.y+f.y}}function pa(e){return Array.from(e.getClientRects())}function ma(e){let t=Fi(e),n=Qi(e),r=e.ownerDocument.body,i=G(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=G(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),o=-n.scrollLeft+ua(e),s=-n.scrollTop;return Zi(r).direction===`rtl`&&(o+=G(t.clientWidth,r.clientWidth)-i),{width:i,height:a,x:o,y:s}}var ha=25;function ga(e,t){let n=K(e),r=Fi(e),i=n.visualViewport,a=r.clientWidth,o=r.clientHeight,s=0,c=0;if(i){a=i.width,o=i.height;let e=Yi();(!e||e&&t===`fixed`)&&(s=i.offsetLeft,c=i.offsetTop)}let l=ua(r);if(l<=0){let e=r.ownerDocument,t=e.body,n=getComputedStyle(t),i=e.compatMode===`CSS1Compat`&&parseFloat(n.marginLeft)+parseFloat(n.marginRight)||0,o=Math.abs(r.clientWidth-t.clientWidth-i);o<=ha&&(a-=o)}else l<=ha&&(a+=l);return{width:a,height:o,x:s,y:c}}function _a(e,t){let n=la(e,!0,t===`fixed`),r=n.top+e.clientTop,i=n.left+e.clientLeft,a=Ri(e)?aa(e):Yr(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:i*a.x,y:r*a.y}}function va(e,t,n){let r;if(t===`viewport`)r=ga(e,n);else if(t===`document`)r=ma(Fi(e));else if(Li(t))r=_a(t,n);else{let n=sa(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return _i(r)}function ya(e,t){let n=$i(e);return n===t||!Li(n)||Xi(n)?!1:Zi(n).position===`fixed`||ya(n,t)}function ba(e,t){let n=t.get(e);if(n)return n;let r=ta(e,[],!1).filter(e=>Li(e)&&Pi(e)!==`body`),i=null,a=Zi(e).position===`fixed`,o=a?$i(e):e;for(;Li(o)&&!Xi(o);){let t=Zi(o),n=qi(o);!n&&t.position===`fixed`&&(i=null),(a?!n&&!i:!n&&t.position===`static`&&i&&(i.position===`absolute`||i.position===`fixed`)||Bi(o)&&!n&&ya(e,o))?r=r.filter(e=>e!==o):i=t,o=$i(o)}return t.set(e,r),r}function xa(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e,a=[...n===`clippingAncestors`?Hi(t)?[]:ba(t,this._c):[].concat(n),r],o=va(t,a[0],i),s=o.top,c=o.right,l=o.bottom,u=o.left;for(let e=1;e<a.length;e++){let n=va(t,a[e],i);s=G(n.top,s),c=Kr(n.right,c),l=Kr(n.bottom,l),u=G(n.left,u)}return{width:c-u,height:l-s,x:u,y:s}}function Sa(e){let{width:t,height:n}=ra(e);return{width:t,height:n}}function Ca(e,t,n){let r=Ri(t),i=Fi(t),a=n===`fixed`,o=la(e,!0,a,t),s={scrollLeft:0,scrollTop:0},c=Yr(0);function l(){c.x=ua(i)}if(r||!r&&!a)if((Pi(t)!==`body`||Bi(i))&&(s=Qi(t)),r){let e=la(t,!0,a,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}else i&&l();a&&!r&&i&&l();let u=i&&!r&&!a?da(i,s):Yr(0);return{x:o.left+s.scrollLeft-c.x-u.x,y:o.top+s.scrollTop-c.y-u.y,width:o.width,height:o.height}}function wa(e){return Zi(e).position===`static`}function Ta(e,t){if(!Ri(e)||Zi(e).position===`fixed`)return null;if(t)return t(e);let n=e.offsetParent;return Fi(e)===n&&(n=n.ownerDocument.body),n}function Ea(e,t){let n=K(e);if(Hi(e))return n;if(!Ri(e)){let t=$i(e);for(;t&&!Xi(t);){if(Li(t)&&!wa(t))return t;t=$i(t)}return n}let r=Ta(e,t);for(;r&&Vi(r)&&wa(r);)r=Ta(r,t);return r&&Xi(r)&&wa(r)&&!qi(r)?n:r||Ji(e)||n}var Da=async function(e){let t=this.getOffsetParent||Ea,n=this.getDimensions,r=await n(e.floating);return{reference:Ca(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Oa(e){return Zi(e).direction===`rtl`}var ka={convertOffsetParentRelativeRectToViewportRelativeRect:fa,getDocumentElement:Fi,getClippingRect:xa,getOffsetParent:Ea,getElementRects:Da,getClientRects:pa,getDimensions:Sa,getScale:aa,isElement:Li,isRTL:Oa};function Aa(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function ja(e,t){let n=null,r,i=Fi(e);function a(){var e;clearTimeout(r),(e=n)==null||e.disconnect(),n=null}function o(s,c){s===void 0&&(s=!1),c===void 0&&(c=1),a();let l=e.getBoundingClientRect(),{left:u,top:d,width:f,height:p}=l;if(s||t(),!f||!p)return;let m=Jr(d),h=Jr(i.clientWidth-(u+f)),g=Jr(i.clientHeight-(d+p)),_=Jr(u),v={rootMargin:-m+`px `+-h+`px `+-g+`px `+-_+`px`,threshold:G(0,Kr(1,c))||1},y=!0;function b(t){let n=t[0].intersectionRatio;if(n!==c){if(!y)return o();n?o(!1,n):r=setTimeout(()=>{o(!1,1e-7)},1e3)}n===1&&!Aa(l,e.getBoundingClientRect())&&o(),y=!1}try{n=new IntersectionObserver(b,{...v,root:i.ownerDocument})}catch{n=new IntersectionObserver(b,v)}n.observe(e)}return o(!0),a}function Ma(e,t,n,r){r===void 0&&(r={});let{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:o=typeof ResizeObserver==`function`,layoutShift:s=typeof IntersectionObserver==`function`,animationFrame:c=!1}=r,l=ia(e),u=i||a?[...l?ta(l):[],...t?ta(t):[]]:[];u.forEach(e=>{i&&e.addEventListener(`scroll`,n,{passive:!0}),a&&e.addEventListener(`resize`,n)});let d=l&&s?ja(l,n):null,f=-1,p=null;o&&(p=new ResizeObserver(e=>{let[r]=e;r&&r.target===l&&p&&t&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var e;(e=p)==null||e.observe(t)})),n()}),l&&!c&&p.observe(l),t&&p.observe(t));let m,h=c?la(e):null;c&&g();function g(){let t=la(e);h&&!Aa(h,t)&&n(),h=t,m=requestAnimationFrame(g)}return n(),()=>{var e;u.forEach(e=>{i&&e.removeEventListener(`scroll`,n),a&&e.removeEventListener(`resize`,n)}),d==null||d(),(e=p)==null||e.disconnect(),p=null,c&&cancelAnimationFrame(m)}}var Na=ki,Pa=Ai,Fa=Ci,Ia=Mi,La=Ei,Ra=Si,za=ji,Ba=(e,t,n)=>{let r=new Map,i={platform:ka,...n},a={...i.platform,_c:r};return xi(e,t,{...i,platform:a})},Va=typeof document<`u`?x.useLayoutEffect:function(){};function Ha(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,r,i;if(e&&t&&typeof e==`object`){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Ha(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){let n=i[r];if(!(n===`_owner`&&e.$$typeof)&&!Ha(e[n],t[n]))return!1}return!0}return e!==e&&t!==t}function Ua(e){return typeof window>`u`?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Wa(e,t){let n=Ua(e);return Math.round(t*n)/n}function Ga(e){let t=x.useRef(e);return Va(()=>{t.current=e}),t}function Ka(e){e===void 0&&(e={});let{placement:t=`bottom`,strategy:n=`absolute`,middleware:r=[],platform:i,elements:{reference:a,floating:o}={},transform:s=!0,whileElementsMounted:c,open:l}=e,[u,d]=x.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=x.useState(r);Ha(f,r)||p(r);let[m,h]=x.useState(null),[g,_]=x.useState(null),v=x.useCallback(e=>{e!==C.current&&(C.current=e,h(e))},[]),y=x.useCallback(e=>{e!==w.current&&(w.current=e,_(e))},[]),b=a||m,S=o||g,C=x.useRef(null),w=x.useRef(null),T=x.useRef(u),E=c!=null,D=Ga(c),O=Ga(i),k=Ga(l),A=x.useCallback(()=>{if(!C.current||!w.current)return;let e={placement:t,strategy:n,middleware:f};O.current&&(e.platform=O.current),Ba(C.current,w.current,e).then(e=>{let t={...e,isPositioned:k.current!==!1};j.current&&!Ha(T.current,t)&&(T.current=t,I.flushSync(()=>{d(t)}))})},[f,t,n,O,k]);Va(()=>{l===!1&&T.current.isPositioned&&(T.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[l]);let j=x.useRef(!1);Va(()=>(j.current=!0,()=>{j.current=!1}),[]),Va(()=>{if(b&&(C.current=b),S&&(w.current=S),b&&S){if(D.current)return D.current(b,S,A);A()}},[b,S,A,D,E]);let M=x.useMemo(()=>({reference:C,floating:w,setReference:v,setFloating:y}),[v,y]),N=x.useMemo(()=>({reference:b,floating:S}),[b,S]),ee=x.useMemo(()=>{let e={position:n,left:0,top:0};if(!N.floating)return e;let t=Wa(N.floating,u.x),r=Wa(N.floating,u.y);return s?{...e,transform:`translate(`+t+`px, `+r+`px)`,...Ua(N.floating)>=1.5&&{willChange:`transform`}}:{position:n,left:t,top:r}},[n,s,N.floating,u.x,u.y]);return x.useMemo(()=>({...u,update:A,refs:M,elements:N,floatingStyles:ee}),[u,A,M,N,ee])}var qa=e=>{function t(e){return{}.hasOwnProperty.call(e,`current`)}return{name:`arrow`,options:e,fn(n){let{element:r,padding:i}=typeof e==`function`?e(n):e;return r&&t(r)?r.current==null?{}:Ra({element:r.current,padding:i}).fn(n):r?Ra({element:r,padding:i}).fn(n):{}}}},Ja=(e,t)=>{let n=Na(e);return{name:n.name,fn:n.fn,options:[e,t]}},Ya=(e,t)=>{let n=Pa(e);return{name:n.name,fn:n.fn,options:[e,t]}},Xa=(e,t)=>({fn:za(e).fn,options:[e,t]}),Za=(e,t)=>{let n=Fa(e);return{name:n.name,fn:n.fn,options:[e,t]}},Qa=(e,t)=>{let n=Ia(e);return{name:n.name,fn:n.fn,options:[e,t]}},$a=(e,t)=>{let n=La(e);return{name:n.name,fn:n.fn,options:[e,t]}},eo=(e,t)=>{let n=qa(e);return{name:n.name,fn:n.fn,options:[e,t]}},to=`Arrow`,no=x.forwardRef((e,t)=>{let{children:n,width:r=10,height:i=5,...a}=e;return(0,L.jsx)(V.svg,{...a,ref:t,width:r,height:i,viewBox:`0 0 30 10`,preserveAspectRatio:`none`,children:e.asChild?n:(0,L.jsx)(`polygon`,{points:`0,0 30,0 15,10`})})});no.displayName=to;var ro=no,io=`Popper`,[ao,oo]=Ee(io),[so,co]=ao(io),lo=e=>{let{__scopePopper:t,children:n}=e,[r,i]=x.useState(null);return(0,L.jsx)(so,{scope:t,anchor:r,onAnchorChange:i,children:n})};lo.displayName=io;var uo=`PopperAnchor`,fo=x.forwardRef((e,t)=>{let{__scopePopper:n,virtualRef:r,...i}=e,a=co(uo,n),o=x.useRef(null),s=B(t,o),c=x.useRef(null);return x.useEffect(()=>{let e=c.current;c.current=(r==null?void 0:r.current)||o.current,e!==c.current&&a.onAnchorChange(c.current)}),r?null:(0,L.jsx)(V.div,{...i,ref:s})});fo.displayName=uo;var po=`PopperContent`,[mo,ho]=ao(po),go=x.forwardRef((e,t)=>{var n,r,i,a,o,s,c,l;let{__scopePopper:u,side:d=`bottom`,sideOffset:f=0,align:p=`center`,alignOffset:m=0,arrowPadding:h=0,avoidCollisions:g=!0,collisionBoundary:_=[],collisionPadding:v=0,sticky:y=`partial`,hideWhenDetached:b=!1,updatePositionStrategy:S=`optimized`,onPlaced:C,...w}=e,T=co(po,u),[E,D]=x.useState(null),O=B(t,e=>D(e)),[k,A]=x.useState(null),j=Wr(k),M=(n=j==null?void 0:j.width)==null?0:n,N=(r=j==null?void 0:j.height)==null?0:r,ee=d+(p===`center`?``:`-`+p),te=typeof v==`number`?v:{top:0,right:0,bottom:0,left:0,...v},P=Array.isArray(_)?_:[_],ne=P.length>0,re={padding:te,boundary:P.filter(bo),altBoundary:ne},{refs:ie,floatingStyles:ae,placement:F,isPositioned:I,middlewareData:R}=Ka({strategy:`fixed`,placement:ee,whileElementsMounted:(...e)=>Ma(...e,{animationFrame:S===`always`}),elements:{reference:T.anchor},middleware:[Ja({mainAxis:f+N,alignmentAxis:m}),g&&Ya({mainAxis:!0,crossAxis:!1,limiter:y===`partial`?Xa():void 0,...re}),g&&Za({...re}),Qa({...re,apply:({elements:e,rects:t,availableWidth:n,availableHeight:r})=>{let{width:i,height:a}=t.reference,o=e.floating.style;o.setProperty(`--radix-popper-available-width`,`${n}px`),o.setProperty(`--radix-popper-available-height`,`${r}px`),o.setProperty(`--radix-popper-anchor-width`,`${i}px`),o.setProperty(`--radix-popper-anchor-height`,`${a}px`)}}),k&&eo({element:k,padding:h}),xo({arrowWidth:M,arrowHeight:N}),b&&$a({strategy:`referenceHidden`,...re})]}),[z,oe]=So(F),se=nt(C);Ae(()=>{I&&(se==null||se())},[I,se]);let ce=(i=R.arrow)==null?void 0:i.x,le=(a=R.arrow)==null?void 0:a.y,ue=((o=R.arrow)==null?void 0:o.centerOffset)!==0,[de,fe]=x.useState();return Ae(()=>{E&&fe(window.getComputedStyle(E).zIndex)},[E]),(0,L.jsx)(`div`,{ref:ie.setFloating,"data-radix-popper-content-wrapper":``,style:{...ae,transform:I?ae.transform:`translate(0, -200%)`,minWidth:`max-content`,zIndex:de,"--radix-popper-transform-origin":[(s=R.transformOrigin)==null?void 0:s.x,(c=R.transformOrigin)==null?void 0:c.y].join(` `),...((l=R.hide)==null?void 0:l.referenceHidden)&&{visibility:`hidden`,pointerEvents:`none`}},dir:e.dir,children:(0,L.jsx)(mo,{scope:u,placedSide:z,onArrowChange:A,arrowX:ce,arrowY:le,shouldHideArrow:ue,children:(0,L.jsx)(V.div,{"data-side":z,"data-align":oe,...w,ref:O,style:{...w.style,animation:I?void 0:`none`}})})})});go.displayName=po;var _o=`PopperArrow`,vo={top:`bottom`,right:`left`,bottom:`top`,left:`right`},yo=x.forwardRef(function(e,t){let{__scopePopper:n,...r}=e,i=ho(_o,n),a=vo[i.placedSide];return(0,L.jsx)(`span`,{ref:i.onArrowChange,style:{position:`absolute`,left:i.arrowX,top:i.arrowY,[a]:0,transformOrigin:{top:``,right:`0 0`,bottom:`center 0`,left:`100% 0`}[i.placedSide],transform:{top:`translateY(100%)`,right:`translateY(50%) rotate(90deg) translateX(-50%)`,bottom:`rotate(180deg)`,left:`translateY(50%) rotate(-90deg) translateX(50%)`}[i.placedSide],visibility:i.shouldHideArrow?`hidden`:void 0},children:(0,L.jsx)(ro,{...r,ref:t,style:{...r.style,display:`block`}})})});yo.displayName=_o;function bo(e){return e!==null}var xo=e=>({name:`transformOrigin`,options:e,fn(t){var n,r,i,a,o;let{placement:s,rects:c,middlewareData:l}=t,u=((n=l.arrow)==null?void 0:n.centerOffset)!==0,d=u?0:e.arrowWidth,f=u?0:e.arrowHeight,[p,m]=So(s),h={start:`0%`,center:`50%`,end:`100%`}[m],g=((r=(i=l.arrow)==null?void 0:i.x)==null?0:r)+d/2,_=((a=(o=l.arrow)==null?void 0:o.y)==null?0:a)+f/2,v=``,y=``;return p===`bottom`?(v=u?h:`${g}px`,y=`${-f}px`):p===`top`?(v=u?h:`${g}px`,y=`${c.floating.height+f}px`):p===`right`?(v=`${-f}px`,y=u?h:`${_}px`):p===`left`&&(v=`${c.floating.width+f}px`,y=u?h:`${_}px`),{data:{x:v,y}}}});function So(e){let[t,n=`center`]=e.split(`-`);return[t,n]}var Co=lo,wo=fo,To=go,Eo=yo,Do=`rovingFocusGroup.onEntryFocus`,Oo={bubbles:!1,cancelable:!0},ko=`RovingFocusGroup`,[Ao,jo,Mo]=Oe(ko),[No,Po]=Ee(ko,[Mo]),[Fo,Io]=No(ko),Lo=x.forwardRef((e,t)=>(0,L.jsx)(Ao.Provider,{scope:e.__scopeRovingFocusGroup,children:(0,L.jsx)(Ao.Slot,{scope:e.__scopeRovingFocusGroup,children:(0,L.jsx)(Ro,{...e,ref:t})})}));Lo.displayName=ko;var Ro=x.forwardRef((e,t)=>{let{__scopeRovingFocusGroup:n,orientation:r,loop:i=!1,dir:a,currentTabStopId:o,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:c,onEntryFocus:l,preventScrollOnEntryFocus:u=!1,...d}=e,f=x.useRef(null),p=B(t,f),m=tt(a),[h,g]=Me({prop:o,defaultProp:s==null?null:s,onChange:c,caller:ko}),[_,v]=x.useState(!1),y=nt(l),b=jo(n),S=x.useRef(!1),[C,w]=x.useState(0);return x.useEffect(()=>{let e=f.current;if(e)return e.addEventListener(Do,y),()=>e.removeEventListener(Do,y)},[y]),(0,L.jsx)(Fo,{scope:n,orientation:r,dir:m,loop:i,currentTabStopId:h,onItemFocus:x.useCallback(e=>g(e),[g]),onItemShiftTab:x.useCallback(()=>v(!0),[]),onFocusableItemAdd:x.useCallback(()=>w(e=>e+1),[]),onFocusableItemRemove:x.useCallback(()=>w(e=>e-1),[]),children:(0,L.jsx)(V.div,{tabIndex:_||C===0?-1:0,"data-orientation":r,...d,ref:p,style:{outline:`none`,...e.style},onMouseDown:H(e.onMouseDown,()=>{S.current=!0}),onFocus:H(e.onFocus,e=>{let t=!S.current;if(e.target===e.currentTarget&&t&&!_){let t=new CustomEvent(Do,Oo);if(e.currentTarget.dispatchEvent(t),!t.defaultPrevented){let e=b().filter(e=>e.focusable);Wo([e.find(e=>e.active),e.find(e=>e.id===h),...e].filter(Boolean).map(e=>e.ref.current),u)}}S.current=!1}),onBlur:H(e.onBlur,()=>v(!1))})})}),zo=`RovingFocusGroupItem`,Bo=x.forwardRef((e,t)=>{let{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:a,children:o,...s}=e,c=W(),l=a||c,u=Io(zo,n),d=u.currentTabStopId===l,f=jo(n),{onFocusableItemAdd:p,onFocusableItemRemove:m,currentTabStopId:h}=u;return x.useEffect(()=>{if(r)return p(),()=>m()},[r,p,m]),(0,L.jsx)(Ao.ItemSlot,{scope:n,id:l,focusable:r,active:i,children:(0,L.jsx)(V.span,{tabIndex:d?0:-1,"data-orientation":u.orientation,...s,ref:t,onMouseDown:H(e.onMouseDown,e=>{r?u.onItemFocus(l):e.preventDefault()}),onFocus:H(e.onFocus,()=>u.onItemFocus(l)),onKeyDown:H(e.onKeyDown,e=>{if(e.key===`Tab`&&e.shiftKey){u.onItemShiftTab();return}if(e.target!==e.currentTarget)return;let t=Uo(e,u.orientation,u.dir);if(t!==void 0){if(e.metaKey||e.ctrlKey||e.altKey||e.shiftKey)return;e.preventDefault();let n=f().filter(e=>e.focusable).map(e=>e.ref.current);if(t===`last`)n.reverse();else if(t===`prev`||t===`next`){t===`prev`&&n.reverse();let r=n.indexOf(e.currentTarget);n=u.loop?Go(n,r+1):n.slice(r+1)}setTimeout(()=>Wo(n))}}),children:typeof o==`function`?o({isCurrentTabStop:d,hasTabStop:h!=null}):o})})});Bo.displayName=zo;var Vo={ArrowLeft:`prev`,ArrowUp:`prev`,ArrowRight:`next`,ArrowDown:`next`,PageUp:`first`,Home:`first`,PageDown:`last`,End:`last`};function Ho(e,t){return t===`rtl`?e===`ArrowLeft`?`ArrowRight`:e===`ArrowRight`?`ArrowLeft`:e:e}function Uo(e,t,n){let r=Ho(e.key,n);if(!(t===`vertical`&&[`ArrowLeft`,`ArrowRight`].includes(r))&&!(t===`horizontal`&&[`ArrowUp`,`ArrowDown`].includes(r)))return Vo[r]}function Wo(e,t=!1){let n=document.activeElement;for(let r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function Go(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var Ko=Lo,qo=Bo,Jo=[`Enter`,` `],Yo=[`ArrowDown`,`PageUp`,`Home`],Xo=[`ArrowUp`,`PageDown`,`End`],Zo=[...Yo,...Xo],Qo={ltr:[...Jo,`ArrowRight`],rtl:[...Jo,`ArrowLeft`]},$o={ltr:[`ArrowLeft`],rtl:[`ArrowRight`]},es=`Menu`,[ts,ns,rs]=Oe(es),[is,as]=Ee(es,[rs,oo,Po]),os=oo(),ss=Po(),[cs,ls]=is(es),[us,ds]=is(es),fs=e=>{let{__scopeMenu:t,open:n=!1,children:r,dir:i,onOpenChange:a,modal:o=!0}=e,s=os(t),[c,l]=x.useState(null),u=x.useRef(!1),d=nt(a),f=tt(i);return x.useEffect(()=>{let e=()=>{u.current=!0,document.addEventListener(`pointerdown`,t,{capture:!0,once:!0}),document.addEventListener(`pointermove`,t,{capture:!0,once:!0})},t=()=>u.current=!1;return document.addEventListener(`keydown`,e,{capture:!0}),()=>{document.removeEventListener(`keydown`,e,{capture:!0}),document.removeEventListener(`pointerdown`,t,{capture:!0}),document.removeEventListener(`pointermove`,t,{capture:!0})}},[]),(0,L.jsx)(Co,{...s,children:(0,L.jsx)(cs,{scope:t,open:n,onOpenChange:d,content:c,onContentChange:l,children:(0,L.jsx)(us,{scope:t,onClose:x.useCallback(()=>d(!1),[d]),isUsingKeyboardRef:u,dir:f,modal:o,children:r})})})};fs.displayName=es;var ps=`MenuAnchor`,ms=x.forwardRef((e,t)=>{let{__scopeMenu:n,...r}=e,i=os(n);return(0,L.jsx)(wo,{...i,...r,ref:t})});ms.displayName=ps;var hs=`MenuPortal`,[gs,_s]=is(hs,{forceMount:void 0}),vs=e=>{let{__scopeMenu:t,forceMount:n,children:r,container:i}=e,a=ls(hs,t);return(0,L.jsx)(gs,{scope:t,forceMount:n,children:(0,L.jsx)(U,{present:n||a.open,children:(0,L.jsx)(Pt,{asChild:!0,container:i,children:r})})})};vs.displayName=hs;var q=`MenuContent`,[ys,bs]=is(q),xs=x.forwardRef((e,t)=>{let n=_s(q,e.__scopeMenu),{forceMount:r=n.forceMount,...i}=e,a=ls(q,e.__scopeMenu),o=ds(q,e.__scopeMenu);return(0,L.jsx)(ts.Provider,{scope:e.__scopeMenu,children:(0,L.jsx)(U,{present:r||a.open,children:(0,L.jsx)(ts.Slot,{scope:e.__scopeMenu,children:o.modal?(0,L.jsx)(Ss,{...i,ref:t}):(0,L.jsx)(Cs,{...i,ref:t})})})})}),Ss=x.forwardRef((e,t)=>{let n=ls(q,e.__scopeMenu),r=x.useRef(null),i=B(t,r);return x.useEffect(()=>{let e=r.current;if(e)return nr(e)},[]),(0,L.jsx)(Ts,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:H(e.onFocusOutside,e=>e.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),Cs=x.forwardRef((e,t)=>{let n=ls(q,e.__scopeMenu);return(0,L.jsx)(Ts,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),ws=fe(`MenuContent.ScrollLock`),Ts=x.forwardRef((e,t)=>{let{__scopeMenu:n,loop:r=!1,trapFocus:i,onOpenAutoFocus:a,onCloseAutoFocus:o,disableOutsidePointerEvents:s,onEntryFocus:c,onEscapeKeyDown:l,onPointerDownOutside:u,onFocusOutside:d,onInteractOutside:f,onDismiss:p,disableOutsideScroll:m,...h}=e,g=ls(q,n),_=ds(q,n),v=os(n),y=ss(n),b=ns(n),[S,C]=x.useState(null),w=x.useRef(null),T=B(t,w,g.onContentChange),E=x.useRef(0),D=x.useRef(``),O=x.useRef(0),k=x.useRef(null),A=x.useRef(`right`),j=x.useRef(0),M=m?qn:x.Fragment,N=m?{as:ws,allowPinchZoom:!0}:void 0,ee=e=>{var t,n;let r=D.current+e,i=b().filter(e=>!e.disabled),a=document.activeElement,o=(t=i.find(e=>e.ref.current===a))==null?void 0:t.textValue,s=lc(i.map(e=>e.textValue),r,o),c=(n=i.find(e=>e.textValue===s))==null?void 0:n.ref.current;(function e(t){D.current=t,window.clearTimeout(E.current),t!==``&&(E.current=window.setTimeout(()=>e(``),1e3))})(r),c&&setTimeout(()=>c.focus())};x.useEffect(()=>()=>window.clearTimeout(E.current),[]),It();let te=x.useCallback(e=>{var t,n;return A.current===((t=k.current)==null?void 0:t.side)&&dc(e,(n=k.current)==null?void 0:n.area)},[]);return(0,L.jsx)(ys,{scope:n,searchRef:D,onItemEnter:x.useCallback(e=>{te(e)&&e.preventDefault()},[te]),onItemLeave:x.useCallback(e=>{var t;te(e)||((t=w.current)==null||t.focus(),C(null))},[te]),onTriggerLeave:x.useCallback(e=>{te(e)&&e.preventDefault()},[te]),pointerGraceTimerRef:O,onPointerGraceIntentChange:x.useCallback(e=>{k.current=e},[]),children:(0,L.jsx)(M,{...N,children:(0,L.jsx)(xt,{asChild:!0,trapped:i,onMountAutoFocus:H(a,e=>{var t;e.preventDefault(),(t=w.current)==null||t.focus({preventScroll:!0})}),onUnmountAutoFocus:o,children:(0,L.jsx)(ut,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:l,onPointerDownOutside:u,onFocusOutside:d,onInteractOutside:f,onDismiss:p,children:(0,L.jsx)(Ko,{asChild:!0,...y,dir:_.dir,orientation:`vertical`,loop:r,currentTabStopId:S,onCurrentTabStopIdChange:C,onEntryFocus:H(c,e=>{_.isUsingKeyboardRef.current||e.preventDefault()}),preventScrollOnEntryFocus:!0,children:(0,L.jsx)(To,{role:`menu`,"aria-orientation":`vertical`,"data-state":ic(g.open),"data-radix-menu-content":``,dir:_.dir,...v,...h,ref:T,style:{outline:`none`,...h.style},onKeyDown:H(h.onKeyDown,e=>{let t=e.target.closest(`[data-radix-menu-content]`)===e.currentTarget,n=e.ctrlKey||e.altKey||e.metaKey,r=e.key.length===1;t&&(e.key===`Tab`&&e.preventDefault(),!n&&r&&ee(e.key));let i=w.current;if(e.target!==i||!Zo.includes(e.key))return;e.preventDefault();let a=b().filter(e=>!e.disabled).map(e=>e.ref.current);Xo.includes(e.key)&&a.reverse(),sc(a)}),onBlur:H(e.onBlur,e=>{e.currentTarget.contains(e.target)||(window.clearTimeout(E.current),D.current=``)}),onPointerMove:H(e.onPointerMove,fc(e=>{let t=e.target,n=j.current!==e.clientX;e.currentTarget.contains(t)&&n&&(A.current=e.clientX>j.current?`right`:`left`,j.current=e.clientX)}))})})})})})})});xs.displayName=q;var Es=`MenuGroup`,Ds=x.forwardRef((e,t)=>{let{__scopeMenu:n,...r}=e;return(0,L.jsx)(V.div,{role:`group`,...r,ref:t})});Ds.displayName=Es;var Os=`MenuLabel`,ks=x.forwardRef((e,t)=>{let{__scopeMenu:n,...r}=e;return(0,L.jsx)(V.div,{...r,ref:t})});ks.displayName=Os;var As=`MenuItem`,js=`menu.itemSelect`,Ms=x.forwardRef((e,t)=>{let{disabled:n=!1,onSelect:r,...i}=e,a=x.useRef(null),o=ds(As,e.__scopeMenu),s=bs(As,e.__scopeMenu),c=B(t,a),l=x.useRef(!1),u=()=>{let e=a.current;if(!n&&e){let t=new CustomEvent(js,{bubbles:!0,cancelable:!0});e.addEventListener(js,e=>r==null?void 0:r(e),{once:!0}),be(e,t),t.defaultPrevented?l.current=!1:o.onClose()}};return(0,L.jsx)(Ns,{...i,ref:c,disabled:n,onClick:H(e.onClick,u),onPointerDown:t=>{var n;(n=e.onPointerDown)==null||n.call(e,t),l.current=!0},onPointerUp:H(e.onPointerUp,e=>{var t;l.current||(t=e.currentTarget)==null||t.click()}),onKeyDown:H(e.onKeyDown,e=>{let t=s.searchRef.current!==``;n||t&&e.key===` `||Jo.includes(e.key)&&(e.currentTarget.click(),e.preventDefault())})})});Ms.displayName=As;var Ns=x.forwardRef((e,t)=>{let{__scopeMenu:n,disabled:r=!1,textValue:i,...a}=e,o=bs(As,n),s=ss(n),c=x.useRef(null),l=B(t,c),[u,d]=x.useState(!1),[f,p]=x.useState(``);return x.useEffect(()=>{let e=c.current;if(e){var t;p(((t=e.textContent)==null?``:t).trim())}},[a.children]),(0,L.jsx)(ts.ItemSlot,{scope:n,disabled:r,textValue:i==null?f:i,children:(0,L.jsx)(qo,{asChild:!0,...s,focusable:!r,children:(0,L.jsx)(V.div,{role:`menuitem`,"data-highlighted":u?``:void 0,"aria-disabled":r||void 0,"data-disabled":r?``:void 0,...a,ref:l,onPointerMove:H(e.onPointerMove,fc(e=>{r?o.onItemLeave(e):(o.onItemEnter(e),e.defaultPrevented||e.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:H(e.onPointerLeave,fc(e=>o.onItemLeave(e))),onFocus:H(e.onFocus,()=>d(!0)),onBlur:H(e.onBlur,()=>d(!1))})})})}),Ps=`MenuCheckboxItem`,Fs=x.forwardRef((e,t)=>{let{checked:n=!1,onCheckedChange:r,...i}=e;return(0,L.jsx)(Us,{scope:e.__scopeMenu,checked:n,children:(0,L.jsx)(Ms,{role:`menuitemcheckbox`,"aria-checked":ac(n)?`mixed`:n,...i,ref:t,"data-state":oc(n),onSelect:H(i.onSelect,()=>r==null?void 0:r(ac(n)?!0:!n),{checkForDefaultPrevented:!1})})})});Fs.displayName=Ps;var Is=`MenuRadioGroup`,[Ls,Rs]=is(Is,{value:void 0,onValueChange:()=>{}}),zs=x.forwardRef((e,t)=>{let{value:n,onValueChange:r,...i}=e,a=nt(r);return(0,L.jsx)(Ls,{scope:e.__scopeMenu,value:n,onValueChange:a,children:(0,L.jsx)(Ds,{...i,ref:t})})});zs.displayName=Is;var Bs=`MenuRadioItem`,Vs=x.forwardRef((e,t)=>{let{value:n,...r}=e,i=Rs(Bs,e.__scopeMenu),a=n===i.value;return(0,L.jsx)(Us,{scope:e.__scopeMenu,checked:a,children:(0,L.jsx)(Ms,{role:`menuitemradio`,"aria-checked":a,...r,ref:t,"data-state":oc(a),onSelect:H(r.onSelect,()=>{var e;return(e=i.onValueChange)==null?void 0:e.call(i,n)},{checkForDefaultPrevented:!1})})})});Vs.displayName=Bs;var Hs=`MenuItemIndicator`,[Us,Ws]=is(Hs,{checked:!1}),Gs=x.forwardRef((e,t)=>{let{__scopeMenu:n,forceMount:r,...i}=e,a=Ws(Hs,n);return(0,L.jsx)(U,{present:r||ac(a.checked)||a.checked===!0,children:(0,L.jsx)(V.span,{...i,ref:t,"data-state":oc(a.checked)})})});Gs.displayName=Hs;var Ks=`MenuSeparator`,qs=x.forwardRef((e,t)=>{let{__scopeMenu:n,...r}=e;return(0,L.jsx)(V.div,{role:`separator`,"aria-orientation":`horizontal`,...r,ref:t})});qs.displayName=Ks;var Js=`MenuArrow`,Ys=x.forwardRef((e,t)=>{let{__scopeMenu:n,...r}=e,i=os(n);return(0,L.jsx)(Eo,{...i,...r,ref:t})});Ys.displayName=Js;var Xs=`MenuSub`,[Zs,Qs]=is(Xs),$s=e=>{let{__scopeMenu:t,children:n,open:r=!1,onOpenChange:i}=e,a=ls(Xs,t),o=os(t),[s,c]=x.useState(null),[l,u]=x.useState(null),d=nt(i);return x.useEffect(()=>(a.open===!1&&d(!1),()=>d(!1)),[a.open,d]),(0,L.jsx)(Co,{...o,children:(0,L.jsx)(cs,{scope:t,open:r,onOpenChange:d,content:l,onContentChange:u,children:(0,L.jsx)(Zs,{scope:t,contentId:W(),triggerId:W(),trigger:s,onTriggerChange:c,children:n})})})};$s.displayName=Xs;var ec=`MenuSubTrigger`,tc=x.forwardRef((e,t)=>{let n=ls(ec,e.__scopeMenu),r=ds(ec,e.__scopeMenu),i=Qs(ec,e.__scopeMenu),a=bs(ec,e.__scopeMenu),o=x.useRef(null),{pointerGraceTimerRef:s,onPointerGraceIntentChange:c}=a,l={__scopeMenu:e.__scopeMenu},u=x.useCallback(()=>{o.current&&window.clearTimeout(o.current),o.current=null},[]);return x.useEffect(()=>u,[u]),x.useEffect(()=>{let e=s.current;return()=>{window.clearTimeout(e),c(null)}},[s,c]),(0,L.jsx)(ms,{asChild:!0,...l,children:(0,L.jsx)(Ns,{id:i.triggerId,"aria-haspopup":`menu`,"aria-expanded":n.open,"aria-controls":i.contentId,"data-state":ic(n.open),...e,ref:de(t,i.onTriggerChange),onClick:t=>{var r;(r=e.onClick)==null||r.call(e,t),!(e.disabled||t.defaultPrevented)&&(t.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:H(e.onPointerMove,fc(t=>{a.onItemEnter(t),!t.defaultPrevented&&!e.disabled&&!n.open&&!o.current&&(a.onPointerGraceIntentChange(null),o.current=window.setTimeout(()=>{n.onOpenChange(!0),u()},100))})),onPointerLeave:H(e.onPointerLeave,fc(e=>{var t;u();let r=(t=n.content)==null?void 0:t.getBoundingClientRect();if(r){var i;let t=(i=n.content)==null?void 0:i.dataset.side,o=t===`right`,c=o?-5:5,l=r[o?`left`:`right`],u=r[o?`right`:`left`];a.onPointerGraceIntentChange({area:[{x:e.clientX+c,y:e.clientY},{x:l,y:r.top},{x:u,y:r.top},{x:u,y:r.bottom},{x:l,y:r.bottom}],side:t}),window.clearTimeout(s.current),s.current=window.setTimeout(()=>a.onPointerGraceIntentChange(null),300)}else{if(a.onTriggerLeave(e),e.defaultPrevented)return;a.onPointerGraceIntentChange(null)}})),onKeyDown:H(e.onKeyDown,t=>{let i=a.searchRef.current!==``;if(!(e.disabled||i&&t.key===` `)&&Qo[r.dir].includes(t.key)){var o;n.onOpenChange(!0),(o=n.content)==null||o.focus(),t.preventDefault()}})})})});tc.displayName=ec;var nc=`MenuSubContent`,rc=x.forwardRef((e,t)=>{let n=_s(q,e.__scopeMenu),{forceMount:r=n.forceMount,...i}=e,a=ls(q,e.__scopeMenu),o=ds(q,e.__scopeMenu),s=Qs(nc,e.__scopeMenu),c=x.useRef(null),l=B(t,c);return(0,L.jsx)(ts.Provider,{scope:e.__scopeMenu,children:(0,L.jsx)(U,{present:r||a.open,children:(0,L.jsx)(ts.Slot,{scope:e.__scopeMenu,children:(0,L.jsx)(Ts,{id:s.contentId,"aria-labelledby":s.triggerId,...i,ref:l,align:`start`,side:o.dir===`rtl`?`left`:`right`,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:e=>{var t;o.isUsingKeyboardRef.current&&((t=c.current)==null||t.focus()),e.preventDefault()},onCloseAutoFocus:e=>e.preventDefault(),onFocusOutside:H(e.onFocusOutside,e=>{e.target!==s.trigger&&a.onOpenChange(!1)}),onEscapeKeyDown:H(e.onEscapeKeyDown,e=>{o.onClose(),e.preventDefault()}),onKeyDown:H(e.onKeyDown,e=>{let t=e.currentTarget.contains(e.target),n=$o[o.dir].includes(e.key);if(t&&n){var r;a.onOpenChange(!1),(r=s.trigger)==null||r.focus(),e.preventDefault()}})})})})})});rc.displayName=nc;function ic(e){return e?`open`:`closed`}function ac(e){return e===`indeterminate`}function oc(e){return ac(e)?`indeterminate`:e?`checked`:`unchecked`}function sc(e){let t=document.activeElement;for(let n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function cc(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function lc(e,t,n){let r=t.length>1&&Array.from(t).every(e=>e===t[0])?t[0]:t,i=n?e.indexOf(n):-1,a=cc(e,Math.max(i,0));r.length===1&&(a=a.filter(e=>e!==n));let o=a.find(e=>e.toLowerCase().startsWith(r.toLowerCase()));return o===n?void 0:o}function uc(e,t){let{x:n,y:r}=e,i=!1;for(let e=0,a=t.length-1;e<t.length;a=e++){let o=t[e],s=t[a],c=o.x,l=o.y,u=s.x,d=s.y;l>r!=d>r&&n<(u-c)*(r-l)/(d-l)+c&&(i=!i)}return i}function dc(e,t){return t?uc({x:e.clientX,y:e.clientY},t):!1}function fc(e){return t=>t.pointerType===`mouse`?e(t):void 0}var pc=fs,mc=ms,hc=vs,gc=xs,_c=Ds,vc=ks,yc=Ms,bc=Fs,xc=zs,Sc=Vs,Cc=Gs,wc=qs,Tc=Ys,Ec=tc,Dc=rc,Oc=`DropdownMenu`,[kc,Ac]=Ee(Oc,[as]),J=as(),[jc,Mc]=kc(Oc),Nc=e=>{let{__scopeDropdownMenu:t,children:n,dir:r,open:i,defaultOpen:a,onOpenChange:o,modal:s=!0}=e,c=J(t),l=x.useRef(null),[u,d]=Me({prop:i,defaultProp:a==null?!1:a,onChange:o,caller:Oc});return(0,L.jsx)(jc,{scope:t,triggerId:W(),triggerRef:l,contentId:W(),open:u,onOpenChange:d,onOpenToggle:x.useCallback(()=>d(e=>!e),[d]),modal:s,children:(0,L.jsx)(pc,{...c,open:u,onOpenChange:d,dir:r,modal:s,children:n})})};Nc.displayName=Oc;var Pc=`DropdownMenuTrigger`,Fc=x.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,disabled:r=!1,...i}=e,a=Mc(Pc,n),o=J(n);return(0,L.jsx)(mc,{asChild:!0,...o,children:(0,L.jsx)(V.button,{type:`button`,id:a.triggerId,"aria-haspopup":`menu`,"aria-expanded":a.open,"aria-controls":a.open?a.contentId:void 0,"data-state":a.open?`open`:`closed`,"data-disabled":r?``:void 0,disabled:r,...i,ref:de(t,a.triggerRef),onPointerDown:H(e.onPointerDown,e=>{!r&&e.button===0&&e.ctrlKey===!1&&(a.onOpenToggle(),a.open||e.preventDefault())}),onKeyDown:H(e.onKeyDown,e=>{r||([`Enter`,` `].includes(e.key)&&a.onOpenToggle(),e.key===`ArrowDown`&&a.onOpenChange(!0),[`Enter`,` `,`ArrowDown`].includes(e.key)&&e.preventDefault())})})})});Fc.displayName=Pc;var Ic=`DropdownMenuPortal`,Lc=e=>{let{__scopeDropdownMenu:t,...n}=e,r=J(t);return(0,L.jsx)(hc,{...r,...n})};Lc.displayName=Ic;var Rc=`DropdownMenuContent`,zc=x.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=Mc(Rc,n),a=J(n),o=x.useRef(!1);return(0,L.jsx)(gc,{id:i.contentId,"aria-labelledby":i.triggerId,...a,...r,ref:t,onCloseAutoFocus:H(e.onCloseAutoFocus,e=>{var t;o.current||(t=i.triggerRef.current)==null||t.focus(),o.current=!1,e.preventDefault()}),onInteractOutside:H(e.onInteractOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0,r=t.button===2||n;(!i.modal||r)&&(o.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)`}})});zc.displayName=Rc;var Bc=`DropdownMenuGroup`,Vc=x.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=J(n);return(0,L.jsx)(_c,{...i,...r,ref:t})});Vc.displayName=Bc;var Hc=`DropdownMenuLabel`,Uc=x.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=J(n);return(0,L.jsx)(vc,{...i,...r,ref:t})});Uc.displayName=Hc;var Wc=`DropdownMenuItem`,Gc=x.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=J(n);return(0,L.jsx)(yc,{...i,...r,ref:t})});Gc.displayName=Wc;var Kc=`DropdownMenuCheckboxItem`,qc=x.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=J(n);return(0,L.jsx)(bc,{...i,...r,ref:t})});qc.displayName=Kc;var Jc=`DropdownMenuRadioGroup`,Yc=x.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=J(n);return(0,L.jsx)(xc,{...i,...r,ref:t})});Yc.displayName=Jc;var Xc=`DropdownMenuRadioItem`,Zc=x.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=J(n);return(0,L.jsx)(Sc,{...i,...r,ref:t})});Zc.displayName=Xc;var Qc=`DropdownMenuItemIndicator`,$c=x.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=J(n);return(0,L.jsx)(Cc,{...i,...r,ref:t})});$c.displayName=Qc;var el=`DropdownMenuSeparator`,tl=x.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=J(n);return(0,L.jsx)(wc,{...i,...r,ref:t})});tl.displayName=el;var nl=`DropdownMenuArrow`,rl=x.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=J(n);return(0,L.jsx)(Tc,{...i,...r,ref:t})});rl.displayName=nl;var il=`DropdownMenuSubTrigger`,al=x.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=J(n);return(0,L.jsx)(Ec,{...i,...r,ref:t})});al.displayName=il;var ol=`DropdownMenuSubContent`,sl=x.forwardRef((e,t)=>{let{__scopeDropdownMenu:n,...r}=e,i=J(n);return(0,L.jsx)(Dc,{...i,...r,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)`}})});sl.displayName=ol;var cl=Nc,ll=Fc,ul=Lc,dl=zc,fl=Uc,pl=Gc,ml=qc,hl=$c,gl=tl,_l=`Separator`,vl=`horizontal`,yl=[`horizontal`,`vertical`],bl=x.forwardRef((e,t)=>{let{decorative:n,orientation:r=vl,...i}=e,a=xl(r)?r:vl,o=n?{role:`none`}:{"aria-orientation":a===`vertical`?a:void 0,role:`separator`};return(0,L.jsx)(V.div,{"data-orientation":a,...o,...i,ref:t})});bl.displayName=_l;function xl(e){return yl.includes(e)}var Sl=bl,[Cl,wl]=Ee(`Tooltip`,[oo]),Tl=oo(),El=`TooltipProvider`,Dl=700,Ol=`tooltip.open`,[kl,Al]=Cl(El),jl=e=>{let{__scopeTooltip:t,delayDuration:n=Dl,skipDelayDuration:r=300,disableHoverableContent:i=!1,children:a}=e,o=x.useRef(!0),s=x.useRef(!1),c=x.useRef(0);return x.useEffect(()=>{let e=c.current;return()=>window.clearTimeout(e)},[]),(0,L.jsx)(kl,{scope:t,isOpenDelayedRef:o,delayDuration:n,onOpen:x.useCallback(()=>{window.clearTimeout(c.current),o.current=!1},[]),onClose:x.useCallback(()=>{window.clearTimeout(c.current),c.current=window.setTimeout(()=>o.current=!0,r)},[r]),isPointerInTransitRef:s,onPointerInTransitChange:x.useCallback(e=>{s.current=e},[]),disableHoverableContent:i,children:a})};jl.displayName=El;var Ml=`Tooltip`,[Nl,Pl]=Cl(Ml),Fl=e=>{let{__scopeTooltip:t,children:n,open:r,defaultOpen:i,onOpenChange:a,disableHoverableContent:o,delayDuration:s}=e,c=Al(Ml,e.__scopeTooltip),l=Tl(t),[u,d]=x.useState(null),f=W(),p=x.useRef(0),m=o==null?c.disableHoverableContent:o,h=s==null?c.delayDuration:s,g=x.useRef(!1),[_,v]=Me({prop:r,defaultProp:i==null?!1:i,onChange:e=>{e?(c.onOpen(),document.dispatchEvent(new CustomEvent(Ol))):c.onClose(),a==null||a(e)},caller:Ml}),y=x.useMemo(()=>_?g.current?`delayed-open`:`instant-open`:`closed`,[_]),b=x.useCallback(()=>{window.clearTimeout(p.current),p.current=0,g.current=!1,v(!0)},[v]),S=x.useCallback(()=>{window.clearTimeout(p.current),p.current=0,v(!1)},[v]),C=x.useCallback(()=>{window.clearTimeout(p.current),p.current=window.setTimeout(()=>{g.current=!0,v(!0),p.current=0},h)},[h,v]);return x.useEffect(()=>()=>{p.current&&(window.clearTimeout(p.current),p.current=0)},[]),(0,L.jsx)(Co,{...l,children:(0,L.jsx)(Nl,{scope:t,contentId:f,open:_,stateAttribute:y,trigger:u,onTriggerChange:d,onTriggerEnter:x.useCallback(()=>{c.isOpenDelayedRef.current?C():b()},[c.isOpenDelayedRef,C,b]),onTriggerLeave:x.useCallback(()=>{m?S():(window.clearTimeout(p.current),p.current=0)},[S,m]),onOpen:b,onClose:S,disableHoverableContent:m,children:n})})};Fl.displayName=Ml;var Il=`TooltipTrigger`,Ll=x.forwardRef((e,t)=>{let{__scopeTooltip:n,...r}=e,i=Pl(Il,n),a=Al(Il,n),o=Tl(n),s=B(t,x.useRef(null),i.onTriggerChange),c=x.useRef(!1),l=x.useRef(!1),u=x.useCallback(()=>c.current=!1,[]);return x.useEffect(()=>()=>document.removeEventListener(`pointerup`,u),[u]),(0,L.jsx)(wo,{asChild:!0,...o,children:(0,L.jsx)(V.button,{"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute,...r,ref:s,onPointerMove:H(e.onPointerMove,e=>{e.pointerType!==`touch`&&!l.current&&!a.isPointerInTransitRef.current&&(i.onTriggerEnter(),l.current=!0)}),onPointerLeave:H(e.onPointerLeave,()=>{i.onTriggerLeave(),l.current=!1}),onPointerDown:H(e.onPointerDown,()=>{i.open&&i.onClose(),c.current=!0,document.addEventListener(`pointerup`,u,{once:!0})}),onFocus:H(e.onFocus,()=>{c.current||i.onOpen()}),onBlur:H(e.onBlur,i.onClose),onClick:H(e.onClick,i.onClose)})})});Ll.displayName=Il;var Rl=`TooltipPortal`,[zl,Bl]=Cl(Rl,{forceMount:void 0}),Vl=e=>{let{__scopeTooltip:t,forceMount:n,children:r,container:i}=e,a=Pl(Rl,t);return(0,L.jsx)(zl,{scope:t,forceMount:n,children:(0,L.jsx)(U,{present:n||a.open,children:(0,L.jsx)(Pt,{asChild:!0,container:i,children:r})})})};Vl.displayName=Rl;var Hl=`TooltipContent`,Ul=x.forwardRef((e,t)=>{let n=Bl(Hl,e.__scopeTooltip),{forceMount:r=n.forceMount,side:i=`top`,...a}=e,o=Pl(Hl,e.__scopeTooltip);return(0,L.jsx)(U,{present:r||o.open,children:o.disableHoverableContent?(0,L.jsx)(Jl,{side:i,...a,ref:t}):(0,L.jsx)(Wl,{side:i,...a,ref:t})})}),Wl=x.forwardRef((e,t)=>{let n=Pl(Hl,e.__scopeTooltip),r=Al(Hl,e.__scopeTooltip),i=x.useRef(null),a=B(t,i),[o,s]=x.useState(null),{trigger:c,onClose:l}=n,u=i.current,{onPointerInTransitChange:d}=r,f=x.useCallback(()=>{s(null),d(!1)},[d]),p=x.useCallback((e,t)=>{let n=e.currentTarget,r={x:e.clientX,y:e.clientY},i=Ql(r,Zl(r,n.getBoundingClientRect())),a=$l(t.getBoundingClientRect());s(tu([...i,...a])),d(!0)},[d]);return x.useEffect(()=>()=>f(),[f]),x.useEffect(()=>{if(c&&u){let e=e=>p(e,u),t=e=>p(e,c);return c.addEventListener(`pointerleave`,e),u.addEventListener(`pointerleave`,t),()=>{c.removeEventListener(`pointerleave`,e),u.removeEventListener(`pointerleave`,t)}}},[c,u,p,f]),x.useEffect(()=>{if(o){let e=e=>{let t=e.target,n={x:e.clientX,y:e.clientY},r=(c==null?void 0:c.contains(t))||(u==null?void 0:u.contains(t)),i=!eu(n,o);r?f():i&&(f(),l())};return document.addEventListener(`pointermove`,e),()=>document.removeEventListener(`pointermove`,e)}},[c,u,o,l,f]),(0,L.jsx)(Jl,{...e,ref:a})}),[Gl,Kl]=Cl(Ml,{isInside:!1}),ql=ge(`TooltipContent`),Jl=x.forwardRef((e,t)=>{let{__scopeTooltip:n,children:r,"aria-label":i,onEscapeKeyDown:a,onPointerDownOutside:o,...s}=e,c=Pl(Hl,n),l=Tl(n),{onClose:u}=c;return x.useEffect(()=>(document.addEventListener(Ol,u),()=>document.removeEventListener(Ol,u)),[u]),x.useEffect(()=>{if(c.trigger){let e=e=>{let t=e.target;t!=null&&t.contains(c.trigger)&&u()};return window.addEventListener(`scroll`,e,{capture:!0}),()=>window.removeEventListener(`scroll`,e,{capture:!0})}},[c.trigger,u]),(0,L.jsx)(ut,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:o,onFocusOutside:e=>e.preventDefault(),onDismiss:u,children:(0,L.jsxs)(To,{"data-state":c.stateAttribute,...l,...s,ref:t,style:{...s.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:[(0,L.jsx)(ql,{children:r}),(0,L.jsx)(Gl,{scope:n,isInside:!0,children:(0,L.jsx)(we,{id:c.contentId,role:`tooltip`,children:i||r})})]})})});Ul.displayName=Hl;var Yl=`TooltipArrow`,Xl=x.forwardRef((e,t)=>{let{__scopeTooltip:n,...r}=e,i=Tl(n);return Kl(Yl,n).isInside?null:(0,L.jsx)(Eo,{...i,...r,ref:t})});Xl.displayName=Yl;function Zl(e,t){let n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(n,r,i,a)){case a:return`left`;case i:return`right`;case n:return`top`;case r:return`bottom`;default:throw Error(`unreachable`)}}function Ql(e,t,n=5){let r=[];switch(t){case`top`:r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case`bottom`:r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case`left`:r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case`right`:r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function $l(e){let{top:t,right:n,bottom:r,left:i}=e;return[{x:i,y:t},{x:n,y:t},{x:n,y:r},{x:i,y:r}]}function eu(e,t){let{x:n,y:r}=e,i=!1;for(let e=0,a=t.length-1;e<t.length;a=e++){let o=t[e],s=t[a],c=o.x,l=o.y,u=s.x,d=s.y;l>r!=d>r&&n<(u-c)*(r-l)/(d-l)+c&&(i=!i)}return i}function tu(e){let t=e.slice();return t.sort((e,t)=>e.x<t.x?-1:e.x>t.x?1:e.y<t.y?-1:+(e.y>t.y)),nu(t)}function nu(e){if(e.length<=1)return e.slice();let t=[];for(let n=0;n<e.length;n++){let r=e[n];for(;t.length>=2;){let e=t[t.length-1],n=t[t.length-2];if((e.x-n.x)*(r.y-n.y)>=(e.y-n.y)*(r.x-n.x))t.pop();else break}t.push(r)}t.pop();let n=[];for(let t=e.length-1;t>=0;t--){let r=e[t];for(;n.length>=2;){let e=n[n.length-1],t=n[n.length-2];if((e.x-t.x)*(r.y-t.y)>=(e.y-t.y)*(r.x-t.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 ru=jl,iu=Fl,au=Ll,ou=Vl,su=Ul,cu=Xl,lu=640,uu=1280;function du(){let e=(0,R.c)(2),[t,n]=x.useState(void 0),r,i;return e[0]===Symbol.for(`react.memo_cache_sentinel`)?(r=()=>{let e=window.matchMedia(`(max-width: ${lu-1}px)`),t=()=>{n(window.innerWidth<lu)};return e.addEventListener(`change`,t),n(window.innerWidth<lu),()=>e.removeEventListener(`change`,t)},i=[],e[0]=r,e[1]=i):(r=e[0],i=e[1]),x.useEffect(r,i),!!t}function fu(){let e=(0,R.c)(2),[t,n]=x.useState(void 0),r,i;return e[0]===Symbol.for(`react.memo_cache_sentinel`)?(r=()=>{let e=window.matchMedia(`(max-width: ${uu-1}px)`),t=()=>{n(window.innerWidth<uu)};return e.addEventListener(`change`,t),n(window.innerWidth<uu),()=>e.removeEventListener(`change`,t)},i=[],e[0]=r,e[1]=i):(r=e[0],i=e[1]),x.useEffect(r,i),!!t}var pu=(e,t)=>{let n=Array(e.length+t.length);for(let t=0;t<e.length;t++)n[t]=e[t];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},mu=(e,t)=>({classGroupId:e,validator:t}),hu=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),gu=`-`,_u=[],vu=`arbitrary..`,yu=e=>{let t=Su(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:e=>{if(e.startsWith(`[`)&&e.endsWith(`]`))return xu(e);let n=e.split(gu);return bu(n,+(n[0]===``&&n.length>1),t)},getConflictingClassGroupIds:(e,t)=>{if(t){let t=r[e],i=n[e];return t?i?pu(i,t):t:i||_u}return n[e]||_u}}},bu=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;let r=e[t],i=n.nextPart.get(r);if(i){let n=bu(e,t+1,i);if(n)return n}let a=n.validators;if(a===null)return;let o=t===0?e.join(gu):e.slice(t).join(gu),s=a.length;for(let e=0;e<s;e++){let t=a[e];if(t.validator(o))return t.classGroupId}},xu=e=>e.slice(1,-1).indexOf(`:`)===-1?void 0:(()=>{let t=e.slice(1,-1),n=t.indexOf(`:`),r=t.slice(0,n);return r?vu+r:void 0})(),Su=e=>{let{theme:t,classGroups:n}=e;return Cu(n,t)},Cu=(e,t)=>{let n=hu();for(let r in e){let i=e[r];wu(i,n,r,t)}return n},wu=(e,t,n,r)=>{let i=e.length;for(let a=0;a<i;a++){let i=e[a];Tu(i,t,n,r)}},Tu=(e,t,n,r)=>{if(typeof e==`string`){Eu(e,t,n);return}if(typeof e==`function`){Du(e,t,n,r);return}Ou(e,t,n,r)},Eu=(e,t,n)=>{let r=e===``?t:ku(t,e);r.classGroupId=n},Du=(e,t,n,r)=>{if(Au(e)){wu(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(mu(n,e))},Ou=(e,t,n,r)=>{let i=Object.entries(e),a=i.length;for(let e=0;e<a;e++){let[a,o]=i[e];wu(o,ku(t,a),n,r)}},ku=(e,t)=>{let n=e,r=t.split(gu),i=r.length;for(let e=0;e<i;e++){let t=r[e],i=n.nextPart.get(t);i||(i=hu(),n.nextPart.set(t,i)),n=i}return n},Au=e=>`isThemeGetter`in e&&e.isThemeGetter===!0,ju=e=>{if(e<1)return{get:()=>void 0,set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null),i=(i,a)=>{n[i]=a,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(e){let t=n[e];if(t!==void 0)return t;if((t=r[e])!==void 0)return i(e,t),t},set(e,t){e in n?n[e]=t:i(e,t)}}},Mu=`!`,Nu=`:`,Pu=[],Fu=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),Iu=e=>{let{prefix:t,experimentalParseClassName:n}=e,r=e=>{let t=[],n=0,r=0,i=0,a,o=e.length;for(let s=0;s<o;s++){let o=e[s];if(n===0&&r===0){if(o===Nu){t.push(e.slice(i,s)),i=s+1;continue}if(o===`/`){a=s;continue}}o===`[`?n++:o===`]`?n--:o===`(`?r++:o===`)`&&r--}let s=t.length===0?e:e.slice(i),c=s,l=!1;s.endsWith(Mu)?(c=s.slice(0,-1),l=!0):s.startsWith(Mu)&&(c=s.slice(1),l=!0);let u=a&&a>i?a-i:void 0;return Fu(t,l,c,u)};if(t){let e=t+Nu,n=r;r=t=>t.startsWith(e)?n(t.slice(e.length)):Fu(Pu,!1,t,void 0,!0)}if(n){let e=r;r=t=>n({className:t,parseClassName:e})}return r},Lu=e=>{let t=new Map;return e.orderSensitiveModifiers.forEach((e,n)=>{t.set(e,1e6+n)}),e=>{let n=[],r=[];for(let i=0;i<e.length;i++){let a=e[i],o=a[0]===`[`,s=t.has(a);o||s?(r.length>0&&(r.sort(),n.push(...r),r=[]),n.push(a)):r.push(a)}return r.length>0&&(r.sort(),n.push(...r)),n}},Ru=e=>({cache:ju(e.cacheSize),parseClassName:Iu(e),sortModifiers:Lu(e),...yu(e)}),zu=/\s+/,Bu=(e,t)=>{let{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:a}=t,o=[],s=e.trim().split(zu),c=``;for(let e=s.length-1;e>=0;--e){let t=s[e],{isExternal:l,modifiers:u,hasImportantModifier:d,baseClassName:f,maybePostfixModifierPosition:p}=n(t);if(l){c=t+(c.length>0?` `+c:c);continue}let m=!!p,h=r(m?f.substring(0,p):f);if(!h){if(!m){c=t+(c.length>0?` `+c:c);continue}if(h=r(f),!h){c=t+(c.length>0?` `+c:c);continue}m=!1}let g=u.length===0?``:u.length===1?u[0]:a(u).join(`:`),_=d?g+Mu:g,v=_+h;if(o.indexOf(v)>-1)continue;o.push(v);let y=i(h,m);for(let e=0;e<y.length;++e){let t=y[e];o.push(_+t)}c=t+(c.length>0?` `+c:c)}return c},Vu=(...e)=>{let t=0,n,r,i=``;for(;t<e.length;)(n=e[t++])&&(r=Hu(n))&&(i&&(i+=` `),i+=r);return i},Hu=e=>{if(typeof e==`string`)return e;let t,n=``;for(let r=0;r<e.length;r++)e[r]&&(t=Hu(e[r]))&&(n&&(n+=` `),n+=t);return n},Uu=(e,...t)=>{let n,r,i,a,o=o=>(n=Ru(t.reduce((e,t)=>t(e),e())),r=n.cache.get,i=n.cache.set,a=s,s(o)),s=e=>{let t=r(e);if(t)return t;let a=Bu(e,n);return i(e,a),a};return a=o,(...e)=>a(Vu(...e))},Wu=[],Y=e=>{let t=t=>t[e]||Wu;return t.isThemeGetter=!0,t},Gu=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,Ku=/^\((?:(\w[\w-]*):)?(.+)\)$/i,qu=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,Ju=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Yu=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Xu=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Zu=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Qu=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,$u=e=>qu.test(e),X=e=>!!e&&!Number.isNaN(Number(e)),ed=e=>!!e&&Number.isInteger(Number(e)),td=e=>e.endsWith(`%`)&&X(e.slice(0,-1)),nd=e=>Ju.test(e),rd=()=>!0,id=e=>Yu.test(e)&&!Xu.test(e),ad=()=>!1,od=e=>Zu.test(e),sd=e=>Qu.test(e),cd=e=>!Z(e)&&!Q(e),ld=e=>wd(e,Od,ad),Z=e=>Gu.test(e),ud=e=>wd(e,kd,id),dd=e=>wd(e,Ad,X),fd=e=>wd(e,Md,rd),pd=e=>wd(e,jd,ad),md=e=>wd(e,Ed,ad),hd=e=>wd(e,Dd,sd),gd=e=>wd(e,Nd,od),Q=e=>Ku.test(e),_d=e=>Td(e,kd),vd=e=>Td(e,jd),yd=e=>Td(e,Ed),bd=e=>Td(e,Od),xd=e=>Td(e,Dd),Sd=e=>Td(e,Nd,!0),Cd=e=>Td(e,Md,!0),wd=(e,t,n)=>{let r=Gu.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},Td=(e,t,n=!1)=>{let r=Ku.exec(e);return r?r[1]?t(r[1]):n:!1},Ed=e=>e===`position`||e===`percentage`,Dd=e=>e===`image`||e===`url`,Od=e=>e===`length`||e===`size`||e===`bg-size`,kd=e=>e===`length`,Ad=e=>e===`number`,jd=e=>e===`family-name`,Md=e=>e===`number`||e===`weight`,Nd=e=>e===`shadow`,Pd=Uu(()=>{let e=Y(`color`),t=Y(`font`),n=Y(`text`),r=Y(`font-weight`),i=Y(`tracking`),a=Y(`leading`),o=Y(`breakpoint`),s=Y(`container`),c=Y(`spacing`),l=Y(`radius`),u=Y(`shadow`),d=Y(`inset-shadow`),f=Y(`text-shadow`),p=Y(`drop-shadow`),m=Y(`blur`),h=Y(`perspective`),g=Y(`aspect`),_=Y(`ease`),v=Y(`animate`),y=()=>[`auto`,`avoid`,`all`,`avoid-page`,`page`,`left`,`right`,`column`],b=()=>[`center`,`top`,`bottom`,`left`,`right`,`top-left`,`left-top`,`top-right`,`right-top`,`bottom-right`,`right-bottom`,`bottom-left`,`left-bottom`],x=()=>[...b(),Q,Z],S=()=>[`auto`,`hidden`,`clip`,`visible`,`scroll`],C=()=>[`auto`,`contain`,`none`],w=()=>[Q,Z,c],T=()=>[$u,`full`,`auto`,...w()],E=()=>[ed,`none`,`subgrid`,Q,Z],D=()=>[`auto`,{span:[`full`,ed,Q,Z]},ed,Q,Z],O=()=>[ed,`auto`,Q,Z],k=()=>[`auto`,`min`,`max`,`fr`,Q,Z],A=()=>[`start`,`end`,`center`,`between`,`around`,`evenly`,`stretch`,`baseline`,`center-safe`,`end-safe`],j=()=>[`start`,`end`,`center`,`stretch`,`center-safe`,`end-safe`],M=()=>[`auto`,...w()],N=()=>[$u,`auto`,`full`,`dvw`,`dvh`,`lvw`,`lvh`,`svw`,`svh`,`min`,`max`,`fit`,...w()],ee=()=>[$u,`screen`,`full`,`dvw`,`lvw`,`svw`,`min`,`max`,`fit`,...w()],te=()=>[$u,`screen`,`full`,`lh`,`dvh`,`lvh`,`svh`,`min`,`max`,`fit`,...w()],P=()=>[e,Q,Z],ne=()=>[...b(),yd,md,{position:[Q,Z]}],re=()=>[`no-repeat`,{repeat:[``,`x`,`y`,`space`,`round`]}],ie=()=>[`auto`,`cover`,`contain`,bd,ld,{size:[Q,Z]}],ae=()=>[td,_d,ud],F=()=>[``,`none`,`full`,l,Q,Z],I=()=>[``,X,_d,ud],L=()=>[`solid`,`dashed`,`dotted`,`double`],R=()=>[`normal`,`multiply`,`screen`,`overlay`,`darken`,`lighten`,`color-dodge`,`color-burn`,`hard-light`,`soft-light`,`difference`,`exclusion`,`hue`,`saturation`,`color`,`luminosity`],z=()=>[X,td,yd,md],oe=()=>[``,`none`,m,Q,Z],se=()=>[`none`,X,Q,Z],ce=()=>[`none`,X,Q,Z],le=()=>[X,Q,Z],ue=()=>[$u,`full`,...w()];return{cacheSize:500,theme:{animate:[`spin`,`ping`,`pulse`,`bounce`],aspect:[`video`],blur:[nd],breakpoint:[nd],color:[rd],container:[nd],"drop-shadow":[nd],ease:[`in`,`out`,`in-out`],font:[cd],"font-weight":[`thin`,`extralight`,`light`,`normal`,`medium`,`semibold`,`bold`,`extrabold`,`black`],"inset-shadow":[nd],leading:[`none`,`tight`,`snug`,`normal`,`relaxed`,`loose`],perspective:[`dramatic`,`near`,`normal`,`midrange`,`distant`,`none`],radius:[nd],shadow:[nd],spacing:[`px`,X],text:[nd],"text-shadow":[nd],tracking:[`tighter`,`tight`,`normal`,`wide`,`wider`,`widest`]},classGroups:{aspect:[{aspect:[`auto`,`square`,$u,Z,Q,g]}],container:[`container`],columns:[{columns:[X,Z,Q,s]}],"break-after":[{"break-after":y()}],"break-before":[{"break-before":y()}],"break-inside":[{"break-inside":[`auto`,`avoid`,`avoid-page`,`avoid-column`]}],"box-decoration":[{"box-decoration":[`slice`,`clone`]}],box:[{box:[`border`,`content`]}],display:[`block`,`inline-block`,`inline`,`flex`,`inline-flex`,`table`,`inline-table`,`table-caption`,`table-cell`,`table-column`,`table-column-group`,`table-footer-group`,`table-header-group`,`table-row-group`,`table-row`,`flow-root`,`grid`,`inline-grid`,`contents`,`list-item`,`hidden`],sr:[`sr-only`,`not-sr-only`],float:[{float:[`right`,`left`,`none`,`start`,`end`]}],clear:[{clear:[`left`,`right`,`both`,`none`,`start`,`end`]}],isolation:[`isolate`,`isolation-auto`],"object-fit":[{object:[`contain`,`cover`,`fill`,`none`,`scale-down`]}],"object-position":[{object:x()}],overflow:[{overflow:S()}],"overflow-x":[{"overflow-x":S()}],"overflow-y":[{"overflow-y":S()}],overscroll:[{overscroll:C()}],"overscroll-x":[{"overscroll-x":C()}],"overscroll-y":[{"overscroll-y":C()}],position:[`static`,`fixed`,`absolute`,`relative`,`sticky`],inset:[{inset:T()}],"inset-x":[{"inset-x":T()}],"inset-y":[{"inset-y":T()}],start:[{"inset-s":T(),start:T()}],end:[{"inset-e":T(),end:T()}],"inset-bs":[{"inset-bs":T()}],"inset-be":[{"inset-be":T()}],top:[{top:T()}],right:[{right:T()}],bottom:[{bottom:T()}],left:[{left:T()}],visibility:[`visible`,`invisible`,`collapse`],z:[{z:[ed,`auto`,Q,Z]}],basis:[{basis:[$u,`full`,`auto`,s,...w()]}],"flex-direction":[{flex:[`row`,`row-reverse`,`col`,`col-reverse`]}],"flex-wrap":[{flex:[`nowrap`,`wrap`,`wrap-reverse`]}],flex:[{flex:[X,$u,`auto`,`initial`,`none`,Z]}],grow:[{grow:[``,X,Q,Z]}],shrink:[{shrink:[``,X,Q,Z]}],order:[{order:[ed,`first`,`last`,`none`,Q,Z]}],"grid-cols":[{"grid-cols":E()}],"col-start-end":[{col:D()}],"col-start":[{"col-start":O()}],"col-end":[{"col-end":O()}],"grid-rows":[{"grid-rows":E()}],"row-start-end":[{row:D()}],"row-start":[{"row-start":O()}],"row-end":[{"row-end":O()}],"grid-flow":[{"grid-flow":[`row`,`col`,`dense`,`row-dense`,`col-dense`]}],"auto-cols":[{"auto-cols":k()}],"auto-rows":[{"auto-rows":k()}],gap:[{gap:w()}],"gap-x":[{"gap-x":w()}],"gap-y":[{"gap-y":w()}],"justify-content":[{justify:[...A(),`normal`]}],"justify-items":[{"justify-items":[...j(),`normal`]}],"justify-self":[{"justify-self":[`auto`,...j()]}],"align-content":[{content:[`normal`,...A()]}],"align-items":[{items:[...j(),{baseline:[``,`last`]}]}],"align-self":[{self:[`auto`,...j(),{baseline:[``,`last`]}]}],"place-content":[{"place-content":A()}],"place-items":[{"place-items":[...j(),`baseline`]}],"place-self":[{"place-self":[`auto`,...j()]}],p:[{p:w()}],px:[{px:w()}],py:[{py:w()}],ps:[{ps:w()}],pe:[{pe:w()}],pbs:[{pbs:w()}],pbe:[{pbe:w()}],pt:[{pt:w()}],pr:[{pr:w()}],pb:[{pb:w()}],pl:[{pl:w()}],m:[{m:M()}],mx:[{mx:M()}],my:[{my:M()}],ms:[{ms:M()}],me:[{me:M()}],mbs:[{mbs:M()}],mbe:[{mbe:M()}],mt:[{mt:M()}],mr:[{mr:M()}],mb:[{mb:M()}],ml:[{ml:M()}],"space-x":[{"space-x":w()}],"space-x-reverse":[`space-x-reverse`],"space-y":[{"space-y":w()}],"space-y-reverse":[`space-y-reverse`],size:[{size:N()}],"inline-size":[{inline:[`auto`,...ee()]}],"min-inline-size":[{"min-inline":[`auto`,...ee()]}],"max-inline-size":[{"max-inline":[`none`,...ee()]}],"block-size":[{block:[`auto`,...te()]}],"min-block-size":[{"min-block":[`auto`,...te()]}],"max-block-size":[{"max-block":[`none`,...te()]}],w:[{w:[s,`screen`,...N()]}],"min-w":[{"min-w":[s,`screen`,`none`,...N()]}],"max-w":[{"max-w":[s,`screen`,`none`,`prose`,{screen:[o]},...N()]}],h:[{h:[`screen`,`lh`,...N()]}],"min-h":[{"min-h":[`screen`,`lh`,`none`,...N()]}],"max-h":[{"max-h":[`screen`,`lh`,...N()]}],"font-size":[{text:[`base`,n,_d,ud]}],"font-smoothing":[`antialiased`,`subpixel-antialiased`],"font-style":[`italic`,`not-italic`],"font-weight":[{font:[r,Cd,fd]}],"font-stretch":[{"font-stretch":[`ultra-condensed`,`extra-condensed`,`condensed`,`semi-condensed`,`normal`,`semi-expanded`,`expanded`,`extra-expanded`,`ultra-expanded`,td,Z]}],"font-family":[{font:[vd,pd,t]}],"font-features":[{"font-features":[Z]}],"fvn-normal":[`normal-nums`],"fvn-ordinal":[`ordinal`],"fvn-slashed-zero":[`slashed-zero`],"fvn-figure":[`lining-nums`,`oldstyle-nums`],"fvn-spacing":[`proportional-nums`,`tabular-nums`],"fvn-fraction":[`diagonal-fractions`,`stacked-fractions`],tracking:[{tracking:[i,Q,Z]}],"line-clamp":[{"line-clamp":[X,`none`,Q,dd]}],leading:[{leading:[a,...w()]}],"list-image":[{"list-image":[`none`,Q,Z]}],"list-style-position":[{list:[`inside`,`outside`]}],"list-style-type":[{list:[`disc`,`decimal`,`none`,Q,Z]}],"text-alignment":[{text:[`left`,`center`,`right`,`justify`,`start`,`end`]}],"placeholder-color":[{placeholder:P()}],"text-color":[{text:P()}],"text-decoration":[`underline`,`overline`,`line-through`,`no-underline`],"text-decoration-style":[{decoration:[...L(),`wavy`]}],"text-decoration-thickness":[{decoration:[X,`from-font`,`auto`,Q,ud]}],"text-decoration-color":[{decoration:P()}],"underline-offset":[{"underline-offset":[X,`auto`,Q,Z]}],"text-transform":[`uppercase`,`lowercase`,`capitalize`,`normal-case`],"text-overflow":[`truncate`,`text-ellipsis`,`text-clip`],"text-wrap":[{text:[`wrap`,`nowrap`,`balance`,`pretty`]}],indent:[{indent:w()}],"vertical-align":[{align:[`baseline`,`top`,`middle`,`bottom`,`text-top`,`text-bottom`,`sub`,`super`,Q,Z]}],whitespace:[{whitespace:[`normal`,`nowrap`,`pre`,`pre-line`,`pre-wrap`,`break-spaces`]}],break:[{break:[`normal`,`words`,`all`,`keep`]}],wrap:[{wrap:[`break-word`,`anywhere`,`normal`]}],hyphens:[{hyphens:[`none`,`manual`,`auto`]}],content:[{content:[`none`,Q,Z]}],"bg-attachment":[{bg:[`fixed`,`local`,`scroll`]}],"bg-clip":[{"bg-clip":[`border`,`padding`,`content`,`text`]}],"bg-origin":[{"bg-origin":[`border`,`padding`,`content`]}],"bg-position":[{bg:ne()}],"bg-repeat":[{bg:re()}],"bg-size":[{bg:ie()}],"bg-image":[{bg:[`none`,{linear:[{to:[`t`,`tr`,`r`,`br`,`b`,`bl`,`l`,`tl`]},ed,Q,Z],radial:[``,Q,Z],conic:[ed,Q,Z]},xd,hd]}],"bg-color":[{bg:P()}],"gradient-from-pos":[{from:ae()}],"gradient-via-pos":[{via:ae()}],"gradient-to-pos":[{to:ae()}],"gradient-from":[{from:P()}],"gradient-via":[{via:P()}],"gradient-to":[{to:P()}],rounded:[{rounded:F()}],"rounded-s":[{"rounded-s":F()}],"rounded-e":[{"rounded-e":F()}],"rounded-t":[{"rounded-t":F()}],"rounded-r":[{"rounded-r":F()}],"rounded-b":[{"rounded-b":F()}],"rounded-l":[{"rounded-l":F()}],"rounded-ss":[{"rounded-ss":F()}],"rounded-se":[{"rounded-se":F()}],"rounded-ee":[{"rounded-ee":F()}],"rounded-es":[{"rounded-es":F()}],"rounded-tl":[{"rounded-tl":F()}],"rounded-tr":[{"rounded-tr":F()}],"rounded-br":[{"rounded-br":F()}],"rounded-bl":[{"rounded-bl":F()}],"border-w":[{border:I()}],"border-w-x":[{"border-x":I()}],"border-w-y":[{"border-y":I()}],"border-w-s":[{"border-s":I()}],"border-w-e":[{"border-e":I()}],"border-w-bs":[{"border-bs":I()}],"border-w-be":[{"border-be":I()}],"border-w-t":[{"border-t":I()}],"border-w-r":[{"border-r":I()}],"border-w-b":[{"border-b":I()}],"border-w-l":[{"border-l":I()}],"divide-x":[{"divide-x":I()}],"divide-x-reverse":[`divide-x-reverse`],"divide-y":[{"divide-y":I()}],"divide-y-reverse":[`divide-y-reverse`],"border-style":[{border:[...L(),`hidden`,`none`]}],"divide-style":[{divide:[...L(),`hidden`,`none`]}],"border-color":[{border:P()}],"border-color-x":[{"border-x":P()}],"border-color-y":[{"border-y":P()}],"border-color-s":[{"border-s":P()}],"border-color-e":[{"border-e":P()}],"border-color-bs":[{"border-bs":P()}],"border-color-be":[{"border-be":P()}],"border-color-t":[{"border-t":P()}],"border-color-r":[{"border-r":P()}],"border-color-b":[{"border-b":P()}],"border-color-l":[{"border-l":P()}],"divide-color":[{divide:P()}],"outline-style":[{outline:[...L(),`none`,`hidden`]}],"outline-offset":[{"outline-offset":[X,Q,Z]}],"outline-w":[{outline:[``,X,_d,ud]}],"outline-color":[{outline:P()}],shadow:[{shadow:[``,`none`,u,Sd,gd]}],"shadow-color":[{shadow:P()}],"inset-shadow":[{"inset-shadow":[`none`,d,Sd,gd]}],"inset-shadow-color":[{"inset-shadow":P()}],"ring-w":[{ring:I()}],"ring-w-inset":[`ring-inset`],"ring-color":[{ring:P()}],"ring-offset-w":[{"ring-offset":[X,ud]}],"ring-offset-color":[{"ring-offset":P()}],"inset-ring-w":[{"inset-ring":I()}],"inset-ring-color":[{"inset-ring":P()}],"text-shadow":[{"text-shadow":[`none`,f,Sd,gd]}],"text-shadow-color":[{"text-shadow":P()}],opacity:[{opacity:[X,Q,Z]}],"mix-blend":[{"mix-blend":[...R(),`plus-darker`,`plus-lighter`]}],"bg-blend":[{"bg-blend":R()}],"mask-clip":[{"mask-clip":[`border`,`padding`,`content`,`fill`,`stroke`,`view`]},`mask-no-clip`],"mask-composite":[{mask:[`add`,`subtract`,`intersect`,`exclude`]}],"mask-image-linear-pos":[{"mask-linear":[X]}],"mask-image-linear-from-pos":[{"mask-linear-from":z()}],"mask-image-linear-to-pos":[{"mask-linear-to":z()}],"mask-image-linear-from-color":[{"mask-linear-from":P()}],"mask-image-linear-to-color":[{"mask-linear-to":P()}],"mask-image-t-from-pos":[{"mask-t-from":z()}],"mask-image-t-to-pos":[{"mask-t-to":z()}],"mask-image-t-from-color":[{"mask-t-from":P()}],"mask-image-t-to-color":[{"mask-t-to":P()}],"mask-image-r-from-pos":[{"mask-r-from":z()}],"mask-image-r-to-pos":[{"mask-r-to":z()}],"mask-image-r-from-color":[{"mask-r-from":P()}],"mask-image-r-to-color":[{"mask-r-to":P()}],"mask-image-b-from-pos":[{"mask-b-from":z()}],"mask-image-b-to-pos":[{"mask-b-to":z()}],"mask-image-b-from-color":[{"mask-b-from":P()}],"mask-image-b-to-color":[{"mask-b-to":P()}],"mask-image-l-from-pos":[{"mask-l-from":z()}],"mask-image-l-to-pos":[{"mask-l-to":z()}],"mask-image-l-from-color":[{"mask-l-from":P()}],"mask-image-l-to-color":[{"mask-l-to":P()}],"mask-image-x-from-pos":[{"mask-x-from":z()}],"mask-image-x-to-pos":[{"mask-x-to":z()}],"mask-image-x-from-color":[{"mask-x-from":P()}],"mask-image-x-to-color":[{"mask-x-to":P()}],"mask-image-y-from-pos":[{"mask-y-from":z()}],"mask-image-y-to-pos":[{"mask-y-to":z()}],"mask-image-y-from-color":[{"mask-y-from":P()}],"mask-image-y-to-color":[{"mask-y-to":P()}],"mask-image-radial":[{"mask-radial":[Q,Z]}],"mask-image-radial-from-pos":[{"mask-radial-from":z()}],"mask-image-radial-to-pos":[{"mask-radial-to":z()}],"mask-image-radial-from-color":[{"mask-radial-from":P()}],"mask-image-radial-to-color":[{"mask-radial-to":P()}],"mask-image-radial-shape":[{"mask-radial":[`circle`,`ellipse`]}],"mask-image-radial-size":[{"mask-radial":[{closest:[`side`,`corner`],farthest:[`side`,`corner`]}]}],"mask-image-radial-pos":[{"mask-radial-at":b()}],"mask-image-conic-pos":[{"mask-conic":[X]}],"mask-image-conic-from-pos":[{"mask-conic-from":z()}],"mask-image-conic-to-pos":[{"mask-conic-to":z()}],"mask-image-conic-from-color":[{"mask-conic-from":P()}],"mask-image-conic-to-color":[{"mask-conic-to":P()}],"mask-mode":[{mask:[`alpha`,`luminance`,`match`]}],"mask-origin":[{"mask-origin":[`border`,`padding`,`content`,`fill`,`stroke`,`view`]}],"mask-position":[{mask:ne()}],"mask-repeat":[{mask:re()}],"mask-size":[{mask:ie()}],"mask-type":[{"mask-type":[`alpha`,`luminance`]}],"mask-image":[{mask:[`none`,Q,Z]}],filter:[{filter:[``,`none`,Q,Z]}],blur:[{blur:oe()}],brightness:[{brightness:[X,Q,Z]}],contrast:[{contrast:[X,Q,Z]}],"drop-shadow":[{"drop-shadow":[``,`none`,p,Sd,gd]}],"drop-shadow-color":[{"drop-shadow":P()}],grayscale:[{grayscale:[``,X,Q,Z]}],"hue-rotate":[{"hue-rotate":[X,Q,Z]}],invert:[{invert:[``,X,Q,Z]}],saturate:[{saturate:[X,Q,Z]}],sepia:[{sepia:[``,X,Q,Z]}],"backdrop-filter":[{"backdrop-filter":[``,`none`,Q,Z]}],"backdrop-blur":[{"backdrop-blur":oe()}],"backdrop-brightness":[{"backdrop-brightness":[X,Q,Z]}],"backdrop-contrast":[{"backdrop-contrast":[X,Q,Z]}],"backdrop-grayscale":[{"backdrop-grayscale":[``,X,Q,Z]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[X,Q,Z]}],"backdrop-invert":[{"backdrop-invert":[``,X,Q,Z]}],"backdrop-opacity":[{"backdrop-opacity":[X,Q,Z]}],"backdrop-saturate":[{"backdrop-saturate":[X,Q,Z]}],"backdrop-sepia":[{"backdrop-sepia":[``,X,Q,Z]}],"border-collapse":[{border:[`collapse`,`separate`]}],"border-spacing":[{"border-spacing":w()}],"border-spacing-x":[{"border-spacing-x":w()}],"border-spacing-y":[{"border-spacing-y":w()}],"table-layout":[{table:[`auto`,`fixed`]}],caption:[{caption:[`top`,`bottom`]}],transition:[{transition:[``,`all`,`colors`,`opacity`,`shadow`,`transform`,`none`,Q,Z]}],"transition-behavior":[{transition:[`normal`,`discrete`]}],duration:[{duration:[X,`initial`,Q,Z]}],ease:[{ease:[`linear`,`initial`,_,Q,Z]}],delay:[{delay:[X,Q,Z]}],animate:[{animate:[`none`,v,Q,Z]}],backface:[{backface:[`hidden`,`visible`]}],perspective:[{perspective:[h,Q,Z]}],"perspective-origin":[{"perspective-origin":x()}],rotate:[{rotate:se()}],"rotate-x":[{"rotate-x":se()}],"rotate-y":[{"rotate-y":se()}],"rotate-z":[{"rotate-z":se()}],scale:[{scale:ce()}],"scale-x":[{"scale-x":ce()}],"scale-y":[{"scale-y":ce()}],"scale-z":[{"scale-z":ce()}],"scale-3d":[`scale-3d`],skew:[{skew:le()}],"skew-x":[{"skew-x":le()}],"skew-y":[{"skew-y":le()}],transform:[{transform:[Q,Z,``,`none`,`gpu`,`cpu`]}],"transform-origin":[{origin:x()}],"transform-style":[{transform:[`3d`,`flat`]}],translate:[{translate:ue()}],"translate-x":[{"translate-x":ue()}],"translate-y":[{"translate-y":ue()}],"translate-z":[{"translate-z":ue()}],"translate-none":[`translate-none`],accent:[{accent:P()}],appearance:[{appearance:[`none`,`auto`]}],"caret-color":[{caret:P()}],"color-scheme":[{scheme:[`normal`,`dark`,`light`,`light-dark`,`only-dark`,`only-light`]}],cursor:[{cursor:[`auto`,`default`,`pointer`,`wait`,`text`,`move`,`help`,`not-allowed`,`none`,`context-menu`,`progress`,`cell`,`crosshair`,`vertical-text`,`alias`,`copy`,`no-drop`,`grab`,`grabbing`,`all-scroll`,`col-resize`,`row-resize`,`n-resize`,`e-resize`,`s-resize`,`w-resize`,`ne-resize`,`nw-resize`,`se-resize`,`sw-resize`,`ew-resize`,`ns-resize`,`nesw-resize`,`nwse-resize`,`zoom-in`,`zoom-out`,Q,Z]}],"field-sizing":[{"field-sizing":[`fixed`,`content`]}],"pointer-events":[{"pointer-events":[`auto`,`none`]}],resize:[{resize:[`none`,``,`y`,`x`]}],"scroll-behavior":[{scroll:[`auto`,`smooth`]}],"scroll-m":[{"scroll-m":w()}],"scroll-mx":[{"scroll-mx":w()}],"scroll-my":[{"scroll-my":w()}],"scroll-ms":[{"scroll-ms":w()}],"scroll-me":[{"scroll-me":w()}],"scroll-mbs":[{"scroll-mbs":w()}],"scroll-mbe":[{"scroll-mbe":w()}],"scroll-mt":[{"scroll-mt":w()}],"scroll-mr":[{"scroll-mr":w()}],"scroll-mb":[{"scroll-mb":w()}],"scroll-ml":[{"scroll-ml":w()}],"scroll-p":[{"scroll-p":w()}],"scroll-px":[{"scroll-px":w()}],"scroll-py":[{"scroll-py":w()}],"scroll-ps":[{"scroll-ps":w()}],"scroll-pe":[{"scroll-pe":w()}],"scroll-pbs":[{"scroll-pbs":w()}],"scroll-pbe":[{"scroll-pbe":w()}],"scroll-pt":[{"scroll-pt":w()}],"scroll-pr":[{"scroll-pr":w()}],"scroll-pb":[{"scroll-pb":w()}],"scroll-pl":[{"scroll-pl":w()}],"snap-align":[{snap:[`start`,`end`,`center`,`align-none`]}],"snap-stop":[{snap:[`normal`,`always`]}],"snap-type":[{snap:[`none`,`x`,`y`,`both`]}],"snap-strictness":[{snap:[`mandatory`,`proximity`]}],touch:[{touch:[`auto`,`none`,`manipulation`]}],"touch-x":[{"touch-pan":[`x`,`left`,`right`]}],"touch-y":[{"touch-pan":[`y`,`up`,`down`]}],"touch-pz":[`touch-pinch-zoom`],select:[{select:[`none`,`text`,`all`,`auto`]}],"will-change":[{"will-change":[`auto`,`scroll`,`contents`,`transform`,Q,Z]}],fill:[{fill:[`none`,...P()]}],"stroke-w":[{stroke:[X,_d,ud,dd]}],stroke:[{stroke:[`none`,...P()]}],"forced-color-adjust":[{"forced-color-adjust":[`auto`,`none`]}]},conflictingClassGroups:{overflow:[`overflow-x`,`overflow-y`],overscroll:[`overscroll-x`,`overscroll-y`],inset:[`inset-x`,`inset-y`,`inset-bs`,`inset-be`,`start`,`end`,`top`,`right`,`bottom`,`left`],"inset-x":[`right`,`left`],"inset-y":[`top`,`bottom`],flex:[`basis`,`grow`,`shrink`],gap:[`gap-x`,`gap-y`],p:[`px`,`py`,`ps`,`pe`,`pbs`,`pbe`,`pt`,`pr`,`pb`,`pl`],px:[`pr`,`pl`],py:[`pt`,`pb`],m:[`mx`,`my`,`ms`,`me`,`mbs`,`mbe`,`mt`,`mr`,`mb`,`ml`],mx:[`mr`,`ml`],my:[`mt`,`mb`],size:[`w`,`h`],"font-size":[`leading`],"fvn-normal":[`fvn-ordinal`,`fvn-slashed-zero`,`fvn-figure`,`fvn-spacing`,`fvn-fraction`],"fvn-ordinal":[`fvn-normal`],"fvn-slashed-zero":[`fvn-normal`],"fvn-figure":[`fvn-normal`],"fvn-spacing":[`fvn-normal`],"fvn-fraction":[`fvn-normal`],"line-clamp":[`display`,`overflow`],rounded:[`rounded-s`,`rounded-e`,`rounded-t`,`rounded-r`,`rounded-b`,`rounded-l`,`rounded-ss`,`rounded-se`,`rounded-ee`,`rounded-es`,`rounded-tl`,`rounded-tr`,`rounded-br`,`rounded-bl`],"rounded-s":[`rounded-ss`,`rounded-es`],"rounded-e":[`rounded-se`,`rounded-ee`],"rounded-t":[`rounded-tl`,`rounded-tr`],"rounded-r":[`rounded-tr`,`rounded-br`],"rounded-b":[`rounded-br`,`rounded-bl`],"rounded-l":[`rounded-tl`,`rounded-bl`],"border-spacing":[`border-spacing-x`,`border-spacing-y`],"border-w":[`border-w-x`,`border-w-y`,`border-w-s`,`border-w-e`,`border-w-bs`,`border-w-be`,`border-w-t`,`border-w-r`,`border-w-b`,`border-w-l`],"border-w-x":[`border-w-r`,`border-w-l`],"border-w-y":[`border-w-t`,`border-w-b`],"border-color":[`border-color-x`,`border-color-y`,`border-color-s`,`border-color-e`,`border-color-bs`,`border-color-be`,`border-color-t`,`border-color-r`,`border-color-b`,`border-color-l`],"border-color-x":[`border-color-r`,`border-color-l`],"border-color-y":[`border-color-t`,`border-color-b`],translate:[`translate-x`,`translate-y`,`translate-none`],"translate-none":[`translate`,`translate-x`,`translate-y`,`translate-z`],"scroll-m":[`scroll-mx`,`scroll-my`,`scroll-ms`,`scroll-me`,`scroll-mbs`,`scroll-mbe`,`scroll-mt`,`scroll-mr`,`scroll-mb`,`scroll-ml`],"scroll-mx":[`scroll-mr`,`scroll-ml`],"scroll-my":[`scroll-mt`,`scroll-mb`],"scroll-p":[`scroll-px`,`scroll-py`,`scroll-ps`,`scroll-pe`,`scroll-pbs`,`scroll-pbe`,`scroll-pt`,`scroll-pr`,`scroll-pb`,`scroll-pl`],"scroll-px":[`scroll-pr`,`scroll-pl`],"scroll-py":[`scroll-pt`,`scroll-pb`],touch:[`touch-x`,`touch-y`,`touch-pz`],"touch-x":[`touch`],"touch-y":[`touch`],"touch-pz":[`touch`]},conflictingClassGroupModifiers:{"font-size":[`leading`]},orderSensitiveModifiers:[`*`,`**`,`after`,`backdrop`,`before`,`details-content`,`file`,`first-letter`,`first-line`,`marker`,`placeholder`,`selection`]}});function $(...e){return Pd(oe(e))}var Fd=le(`group/button inline-flex shrink-0 items-center justify-center rounded-lg border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,{variants:{variant:{default:`bg-primary text-primary-foreground [a]:hover:bg-primary/80`,outline:`border-border bg-background hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50`,secondary:`bg-secondary text-secondary-foreground hover:bg-secondary/80 aria-expanded:bg-secondary aria-expanded:text-secondary-foreground`,ghost:`hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50`,destructive:`bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:hover:bg-destructive/30 dark:focus-visible:ring-destructive/40`,link:`text-primary underline-offset-4 hover:underline`},size:{default:`h-8 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2`,xs:`h-6 gap-1 rounded-[min(var(--radius-md),10px)] px-2 text-xs in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3`,sm:`h-7 gap-1 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5`,lg:`h-9 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-3 has-data-[icon=inline-start]:pl-3`,icon:`size-8`,"icon-xs":`size-6 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-lg [&_svg:not([class*='size-'])]:size-3`,"icon-sm":`size-7 rounded-[min(var(--radius-md),12px)] in-data-[slot=button-group]:rounded-lg`,"icon-lg":`size-9`}},defaultVariants:{variant:`default`,size:`default`}});function Id(e){let t=(0,R.c)(16),n,r,i,a,o;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4],o=t[5]):({className:n,variant:i,size:a,asChild:o,...r}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a,t[5]=o);let s=i===void 0?`default`:i,c=a===void 0?`default`:a,l=o!==void 0&&o?pe:`button`,u;t[6]!==n||t[7]!==c||t[8]!==s?(u=$(Fd({variant:s,size:c,className:n})),t[6]=n,t[7]=c,t[8]=s,t[9]=u):u=t[9];let d;return t[10]!==l||t[11]!==r||t[12]!==c||t[13]!==u||t[14]!==s?(d=(0,L.jsx)(l,{"data-slot":`button`,"data-variant":s,"data-size":c,className:u,...r}),t[10]=l,t[11]=r,t[12]=c,t[13]=u,t[14]=s,t[15]=d):d=t[15],d}function Ld(e){let t=(0,R.c)(10),n,r,i;t[0]===e?(n=t[1],r=t[2],i=t[3]):({className:n,type:i,...r}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i);let a;t[4]===n?a=t[5]:(a=$(`h-8 w-full min-w-0 rounded-lg border border-input bg-transparent px-2.5 py-1 text-base transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40`,n),t[4]=n,t[5]=a);let o;return t[6]!==r||t[7]!==a||t[8]!==i?(o=(0,L.jsx)(`input`,{type:i,"data-slot":`input`,className:a,...r}),t[6]=r,t[7]=a,t[8]=i,t[9]=o):o=t[9],o}function Rd(e){let t=(0,R.c)(12),n,r,i,a;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4]):({className:n,orientation:i,decorative:a,...r}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a);let o=i===void 0?`horizontal`:i,s=a===void 0?!0:a,c;t[5]===n?c=t[6]:(c=$(`shrink-0 bg-border data-horizontal:h-px data-horizontal:w-full data-vertical:w-px data-vertical:self-stretch`,n),t[5]=n,t[6]=c);let l;return t[7]!==s||t[8]!==o||t[9]!==r||t[10]!==c?(l=(0,L.jsx)(Sl,{"data-slot":`separator`,decorative:s,orientation:o,className:c,...r}),t[7]=s,t[8]=o,t[9]=r,t[10]=c,t[11]=l):l=t[11],l}function zd(e){let t=(0,R.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=$(`animate-pulse rounded-md bg-muted`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,L.jsx)(`div`,{"data-slot":`skeleton`,className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Bd(e){let t=(0,R.c)(6),n,r;t[0]===e?(n=t[1],r=t[2]):({delayDuration:r,...n}=e,t[0]=e,t[1]=n,t[2]=r);let i=r===void 0?0:r,a;return t[3]!==i||t[4]!==n?(a=(0,L.jsx)(ru,{"data-slot":`tooltip-provider`,delayDuration:i,...n}),t[3]=i,t[4]=n,t[5]=a):a=t[5],a}function Vd(e){let t=(0,R.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,L.jsx)(iu,{"data-slot":`tooltip`,...n}),t[2]=n,t[3]=r),r}function Hd(e){let t=(0,R.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,L.jsx)(au,{"data-slot":`tooltip-trigger`,...n}),t[2]=n,t[3]=r),r}function Ud(e){let t=(0,R.c)(13),n,r,i,a;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4]):({className:r,sideOffset:a,children:n,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a);let o=a===void 0?0:a,s;t[5]===r?s=t[6]:(s=$(`z-50 inline-flex w-fit max-w-xs origin-(--radix-tooltip-content-transform-origin) items-center gap-1.5 rounded-md bg-foreground px-3 py-1.5 text-xs text-background has-data-[slot=kbd]:pr-1.5 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 **:data-[slot=kbd]:relative **:data-[slot=kbd]:isolate **:data-[slot=kbd]:z-50 **:data-[slot=kbd]:rounded-sm data-[state=delayed-open]:animate-in data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95`,r),t[5]=r,t[6]=s);let c;t[7]===Symbol.for(`react.memo_cache_sentinel`)?(c=(0,L.jsx)(cu,{className:`z-50 size-2.5 translate-y-[calc(-50%_-_2px)] rotate-45 rounded-[2px] bg-foreground fill-foreground`}),t[7]=c):c=t[7];let l;return t[8]!==n||t[9]!==i||t[10]!==o||t[11]!==s?(l=(0,L.jsx)(ou,{children:(0,L.jsxs)(su,{"data-slot":`tooltip-content`,sideOffset:o,className:s,...i,children:[n,c]})}),t[8]=n,t[9]=i,t[10]=o,t[11]=s,t[12]=l):l=t[12],l}function Wd(e){let t=(0,R.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,L.jsx)(cl,{"data-slot":`dropdown-menu`,...n}),t[2]=n,t[3]=r),r}function Gd(e){let t=(0,R.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,L.jsx)(ll,{"data-slot":`dropdown-menu-trigger`,...n}),t[2]=n,t[3]=r),r}function Kd(e){let t=(0,R.c)(12),n,r,i,a;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4]):({className:n,align:i,sideOffset:a,...r}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a);let o=i===void 0?`start`:i,s=a===void 0?4:a,c;t[5]===n?c=t[6]:(c=$(`z-50 max-h-(--radix-dropdown-menu-content-available-height) w-(--radix-dropdown-menu-trigger-width) min-w-32 origin-(--radix-dropdown-menu-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-lg bg-popover p-1 text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:overflow-hidden data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95`,n),t[5]=n,t[6]=c);let l;return t[7]!==o||t[8]!==r||t[9]!==s||t[10]!==c?(l=(0,L.jsx)(ul,{children:(0,L.jsx)(dl,{"data-slot":`dropdown-menu-content`,sideOffset:s,align:o,className:c,...r})}),t[7]=o,t[8]=r,t[9]=s,t[10]=c,t[11]=l):l=t[11],l}function qd(e){let t=(0,R.c)(12),n,r,i,a;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4]):({className:n,inset:r,variant:a,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a);let o=a===void 0?`default`:a,s;t[5]===n?s=t[6]:(s=$(`group/dropdown-menu-item relative flex cursor-default items-center gap-1.5 rounded-md px-1.5 py-1 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-inset:pl-7 data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 data-[variant=destructive]:focus:text-destructive dark:data-[variant=destructive]:focus:bg-destructive/20 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 data-[variant=destructive]:*:[svg]:text-destructive`,n),t[5]=n,t[6]=s);let c;return t[7]!==r||t[8]!==i||t[9]!==s||t[10]!==o?(c=(0,L.jsx)(pl,{"data-slot":`dropdown-menu-item`,"data-inset":r,"data-variant":o,className:s,...i}),t[7]=r,t[8]=i,t[9]=s,t[10]=o,t[11]=c):c=t[11],c}function Jd(e){let t=(0,R.c)(15),n,r,i,a,o;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4],o=t[5]):({className:i,children:r,checked:n,inset:a,...o}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a,t[5]=o);let s;t[6]===i?s=t[7]:(s=$(`relative flex cursor-default items-center gap-1.5 rounded-md py-1 pr-8 pl-1.5 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground data-inset:pl-7 data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,i),t[6]=i,t[7]=s);let c;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(c=(0,L.jsx)(`span`,{className:`pointer-events-none absolute right-2 flex items-center justify-center`,"data-slot":`dropdown-menu-checkbox-item-indicator`,children:(0,L.jsx)(hl,{children:(0,L.jsx)(d,{})})}),t[8]=c):c=t[8];let l;return t[9]!==n||t[10]!==r||t[11]!==a||t[12]!==o||t[13]!==s?(l=(0,L.jsxs)(ml,{"data-slot":`dropdown-menu-checkbox-item`,"data-inset":a,className:s,checked:n,...o,children:[c,r]}),t[9]=n,t[10]=r,t[11]=a,t[12]=o,t[13]=s,t[14]=l):l=t[14],l}function Yd(e){let t=(0,R.c)(10),n,r,i;t[0]===e?(n=t[1],r=t[2],i=t[3]):({className:n,inset:r,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i);let a;t[4]===n?a=t[5]:(a=$(`px-1.5 py-1 text-xs font-medium text-muted-foreground data-inset:pl-7`,n),t[4]=n,t[5]=a);let o;return t[6]!==r||t[7]!==i||t[8]!==a?(o=(0,L.jsx)(fl,{"data-slot":`dropdown-menu-label`,"data-inset":r,className:a,...i}),t[6]=r,t[7]=i,t[8]=a,t[9]=o):o=t[9],o}function Xd(e){let t=(0,R.c)(8),n,r;t[0]===e?(n=t[1],r=t[2]):({className:n,...r}=e,t[0]=e,t[1]=n,t[2]=r);let i;t[3]===n?i=t[4]:(i=$(`-mx-1 my-1 h-px bg-border`,n),t[3]=n,t[4]=i);let a;return t[5]!==r||t[6]!==i?(a=(0,L.jsx)(gl,{"data-slot":`dropdown-menu-separator`,className:i,...r}),t[5]=r,t[6]=i,t[7]=a):a=t[7],a}function Zd(e){let t=(0,R.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,L.jsx)($e,{"data-slot":`collapsible`,...n}),t[2]=n,t[3]=r),r}function Qd(e){let t=(0,R.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,L.jsx)(Je,{"data-slot":`collapsible-trigger`,...n}),t[2]=n,t[3]=r),r}function $d(e){let t=(0,R.c)(4),n;t[0]===e?n=t[1]:({...n}=e,t[0]=e,t[1]=n);let r;return t[2]===n?r=t[3]:(r=(0,L.jsx)(Xe,{"data-slot":`collapsible-content`,...n}),t[2]=n,t[3]=r),r}var ef=le(`group/badge inline-flex h-5 w-fit shrink-0 items-center justify-center gap-1 overflow-hidden rounded-4xl border border-transparent px-2 py-0.5 text-xs font-medium whitespace-nowrap transition-all focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&>svg]:pointer-events-none [&>svg]:size-3!`,{variants:{variant:{default:`bg-primary text-primary-foreground [a]:hover:bg-primary/80`,secondary:`bg-secondary text-secondary-foreground [a]:hover:bg-secondary/80`,destructive:`bg-destructive/10 text-destructive focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:focus-visible:ring-destructive/40 [a]:hover:bg-destructive/20`,outline:`border-border text-foreground [a]:hover:bg-muted [a]:hover:text-muted-foreground`,ghost:`hover:bg-muted hover:text-muted-foreground dark:hover:bg-muted/50`,link:`text-primary underline-offset-4 hover:underline`}},defaultVariants:{variant:`default`}});function tf(e){let t=(0,R.c)(13),n,r,i,a;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4]):({className:n,variant:i,asChild:a,...r}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a);let o=i===void 0?`default`:i,s=a!==void 0&&a?pe:`span`,c;t[5]!==n||t[6]!==o?(c=$(ef({variant:o}),n),t[5]=n,t[6]=o,t[7]=c):c=t[7];let l;return t[8]!==s||t[9]!==r||t[10]!==c||t[11]!==o?(l=(0,L.jsx)(s,{"data-slot":`badge`,"data-variant":o,className:c,...r}),t[8]=s,t[9]=r,t[10]=c,t[11]=o,t[12]=l):l=t[12],l}export{V as $,oo as A,o as At,qn as B,qo as C,m as Ct,Eo as D,c as Dt,wo as E,d as Et,zr as F,nt as G,Pt as H,Rr as I,U as J,tt as K,Lr as L,Ur as M,Br as N,To as O,l as Ot,Hr as P,Ee as Q,Vr as R,du as S,h as St,Po as T,f as Tt,xt as U,It as V,ut as W,Ae as X,Me as Y,H as Z,Rd as _,b as _t,Wd as a,oe as at,$ as b,_ as bt,qd as c,P as ct,Gd as d,M as dt,pe as et,Vd as f,N as ft,zd as g,D as gt,Hd as h,k as ht,Qd as i,le as it,Wr as j,u as jt,Co as k,s as kt,Yd as l,ee as lt,Bd as m,A as mt,Zd as n,de as nt,Jd as o,F as ot,Ud as p,j as pt,W as q,$d as r,B as rt,Kd as s,ae as st,tf as t,fe as tt,Xd as u,te as ut,Ld as v,y as vt,Ko as w,p as wt,fu as x,g as xt,Id as y,v as yt,nr as z};
|