@nicorp/nui 0.0.1
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/README.md +36 -0
- package/dist/index.cjs.js +51 -0
- package/dist/index.cjs.js.map +1 -0
- package/dist/index.d.ts +156 -0
- package/dist/index.es.js +10302 -0
- package/dist/index.es.js.map +1 -0
- package/dist/nui.css +1 -0
- package/dist/vite.svg +1 -0
- package/package.json +79 -0
package/README.md
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
# NUI (Nicorp UI)
|
|
2
|
+
|
|
3
|
+
A reusable UI component library for Nicorp projects, built with React, TypeScript, Tailwind CSS, and Radix UI.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install @nicorp/nui
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Usage
|
|
12
|
+
|
|
13
|
+
Import styles in your app's root (e.g., `main.tsx` or `App.tsx`):
|
|
14
|
+
|
|
15
|
+
```tsx
|
|
16
|
+
import '@nicorp/nui/dist/nui.css';
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
Use components:
|
|
20
|
+
|
|
21
|
+
```tsx
|
|
22
|
+
import { Button } from '@nicorp/nui';
|
|
23
|
+
|
|
24
|
+
function App() {
|
|
25
|
+
return <Button>Click me</Button>;
|
|
26
|
+
}
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
## Tailwind Configuration
|
|
30
|
+
|
|
31
|
+
To use the NUI theme variables in your project, ensure your `tailwind.config.js` or CSS imports the NUI variables. NUI uses CSS variables for theming.
|
|
32
|
+
|
|
33
|
+
## Development
|
|
34
|
+
|
|
35
|
+
1. `npm install`
|
|
36
|
+
2. `npm run build`
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const se=require("react"),fo=require("react-dom");function po(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const i=po(se),ft=po(fo);function mo(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=mo(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function ho(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=mo(e))&&(r&&(r+=" "),r+=t);return r}const Lc=(e,t)=>{const n=new Array(e.length+t.length);for(let r=0;r<e.length;r++)n[r]=e[r];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},Fc=(e,t)=>({classGroupId:e,validator:t}),go=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),kt="-",Sr=[],Vc="arbitrary..",Wc=e=>{const t=Hc(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:a=>{if(a.startsWith("[")&&a.endsWith("]"))return Bc(a);const c=a.split(kt),l=c[0]===""&&c.length>1?1:0;return vo(c,l,t)},getConflictingClassGroupIds:(a,c)=>{if(c){const l=r[a],u=n[a];return l?u?Lc(u,l):l:u||Sr}return n[a]||Sr}}},vo=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;const o=e[t],s=n.nextPart.get(o);if(s){const u=vo(e,t+1,s);if(u)return u}const a=n.validators;if(a===null)return;const c=t===0?e.join(kt):e.slice(t).join(kt),l=a.length;for(let u=0;u<l;u++){const f=a[u];if(f.validator(c))return f.classGroupId}},Bc=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const t=e.slice(1,-1),n=t.indexOf(":"),r=t.slice(0,n);return r?Vc+r:void 0})(),Hc=e=>{const{theme:t,classGroups:n}=e;return zc(n,t)},zc=(e,t)=>{const n=go();for(const r in e){const o=e[r];Fn(o,n,r,t)}return n},Fn=(e,t,n,r)=>{const o=e.length;for(let s=0;s<o;s++){const a=e[s];Uc(a,t,n,r)}},Uc=(e,t,n,r)=>{if(typeof e=="string"){Gc(e,t,n);return}if(typeof e=="function"){Kc(e,t,n,r);return}Yc(e,t,n,r)},Gc=(e,t,n)=>{const r=e===""?t:yo(t,e);r.classGroupId=n},Kc=(e,t,n,r)=>{if(Xc(e)){Fn(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(Fc(n,e))},Yc=(e,t,n,r)=>{const o=Object.entries(e),s=o.length;for(let a=0;a<s;a++){const[c,l]=o[a];Fn(l,yo(t,c),n,r)}},yo=(e,t)=>{let n=e;const r=t.split(kt),o=r.length;for(let s=0;s<o;s++){const a=r[s];let c=n.nextPart.get(a);c||(c=go(),n.nextPart.set(a,c)),n=c}return n},Xc=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,qc=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null);const o=(s,a)=>{n[s]=a,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(s){let a=n[s];if(a!==void 0)return a;if((a=r[s])!==void 0)return o(s,a),a},set(s,a){s in n?n[s]=a:o(s,a)}}},Pn="!",Cr=":",Zc=[],Er=(e,t,n,r,o)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:o}),Jc=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=o=>{const s=[];let a=0,c=0,l=0,u;const f=o.length;for(let m=0;m<f;m++){const y=o[m];if(a===0&&c===0){if(y===Cr){s.push(o.slice(l,m)),l=m+1;continue}if(y==="/"){u=m;continue}}y==="["?a++:y==="]"?a--:y==="("?c++:y===")"&&c--}const d=s.length===0?o:o.slice(l);let h=d,g=!1;d.endsWith(Pn)?(h=d.slice(0,-1),g=!0):d.startsWith(Pn)&&(h=d.slice(1),g=!0);const v=u&&u>l?u-l:void 0;return Er(s,g,h,v)};if(t){const o=t+Cr,s=r;r=a=>a.startsWith(o)?s(a.slice(o.length)):Er(Zc,!1,a,void 0,!0)}if(n){const o=r;r=s=>n({className:s,parseClassName:o})}return r},Qc=e=>{const t=new Map;return e.orderSensitiveModifiers.forEach((n,r)=>{t.set(n,1e6+r)}),n=>{const r=[];let o=[];for(let s=0;s<n.length;s++){const a=n[s],c=a[0]==="[",l=t.has(a);c||l?(o.length>0&&(o.sort(),r.push(...o),o=[]),r.push(a)):o.push(a)}return o.length>0&&(o.sort(),r.push(...o)),r}},el=e=>({cache:qc(e.cacheSize),parseClassName:Jc(e),sortModifiers:Qc(e),...Wc(e)}),tl=/\s+/,nl=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o,sortModifiers:s}=t,a=[],c=e.trim().split(tl);let l="";for(let u=c.length-1;u>=0;u-=1){const f=c[u],{isExternal:d,modifiers:h,hasImportantModifier:g,baseClassName:v,maybePostfixModifierPosition:m}=n(f);if(d){l=f+(l.length>0?" "+l:l);continue}let y=!!m,x=r(y?v.substring(0,m):v);if(!x){if(!y){l=f+(l.length>0?" "+l:l);continue}if(x=r(v),!x){l=f+(l.length>0?" "+l:l);continue}y=!1}const b=h.length===0?"":h.length===1?h[0]:s(h).join(":"),w=g?b+Pn:b,C=w+x;if(a.indexOf(C)>-1)continue;a.push(C);const _=o(x,y);for(let O=0;O<_.length;++O){const N=_[O];a.push(w+N)}l=f+(l.length>0?" "+l:l)}return l},rl=(...e)=>{let t=0,n,r,o="";for(;t<e.length;)(n=e[t++])&&(r=xo(n))&&(o&&(o+=" "),o+=r);return o},xo=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=xo(e[r]))&&(n&&(n+=" "),n+=t);return n},ol=(e,...t)=>{let n,r,o,s;const a=l=>{const u=t.reduce((f,d)=>d(f),e());return n=el(u),r=n.cache.get,o=n.cache.set,s=c,c(l)},c=l=>{const u=r(l);if(u)return u;const f=nl(l,n);return o(l,f),f};return s=a,(...l)=>s(rl(...l))},sl=[],re=e=>{const t=n=>n[e]||sl;return t.isThemeGetter=!0,t},bo=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,wo=/^\((?:(\w[\w-]*):)?(.+)\)$/i,il=/^\d+\/\d+$/,al=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,cl=/\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$/,ll=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,ul=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,dl=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,ze=e=>il.test(e),G=e=>!!e&&!Number.isNaN(Number(e)),Ne=e=>!!e&&Number.isInteger(Number(e)),fn=e=>e.endsWith("%")&&G(e.slice(0,-1)),Ee=e=>al.test(e),fl=()=>!0,pl=e=>cl.test(e)&&!ll.test(e),So=()=>!1,ml=e=>ul.test(e),hl=e=>dl.test(e),gl=e=>!I(e)&&!T(e),vl=e=>Ze(e,Ro,So),I=e=>bo.test(e),Le=e=>Ze(e,Po,pl),pn=e=>Ze(e,Sl,G),Rr=e=>Ze(e,Co,So),yl=e=>Ze(e,Eo,hl),wt=e=>Ze(e,_o,ml),T=e=>wo.test(e),rt=e=>Je(e,Po),xl=e=>Je(e,Cl),Pr=e=>Je(e,Co),bl=e=>Je(e,Ro),wl=e=>Je(e,Eo),St=e=>Je(e,_o,!0),Ze=(e,t,n)=>{const r=bo.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},Je=(e,t,n=!1)=>{const r=wo.exec(e);return r?r[1]?t(r[1]):n:!1},Co=e=>e==="position"||e==="percentage",Eo=e=>e==="image"||e==="url",Ro=e=>e==="length"||e==="size"||e==="bg-size",Po=e=>e==="length",Sl=e=>e==="number",Cl=e=>e==="family-name",_o=e=>e==="shadow",El=()=>{const e=re("color"),t=re("font"),n=re("text"),r=re("font-weight"),o=re("tracking"),s=re("leading"),a=re("breakpoint"),c=re("container"),l=re("spacing"),u=re("radius"),f=re("shadow"),d=re("inset-shadow"),h=re("text-shadow"),g=re("drop-shadow"),v=re("blur"),m=re("perspective"),y=re("aspect"),x=re("ease"),b=re("animate"),w=()=>["auto","avoid","all","avoid-page","page","left","right","column"],C=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],_=()=>[...C(),T,I],O=()=>["auto","hidden","clip","visible","scroll"],N=()=>["auto","contain","none"],P=()=>[T,I,l],j=()=>[ze,"full","auto",...P()],F=()=>[Ne,"none","subgrid",T,I],z=()=>["auto",{span:["full",Ne,T,I]},Ne,T,I],V=()=>[Ne,"auto",T,I],U=()=>["auto","min","max","fr",T,I],H=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],K=()=>["start","end","center","stretch","center-safe","end-safe"],k=()=>["auto",...P()],W=()=>[ze,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...P()],E=()=>[e,T,I],A=()=>[...C(),Pr,Rr,{position:[T,I]}],J=()=>["no-repeat",{repeat:["","x","y","space","round"]}],S=()=>["auto","cover","contain",bl,vl,{size:[T,I]}],D=()=>[fn,rt,Le],$=()=>["","none","full",u,T,I],L=()=>["",G,rt,Le],ne=()=>["solid","dashed","dotted","double"],te=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],R=()=>[G,fn,Pr,Rr],Y=()=>["","none",v,T,I],ee=()=>["none",G,T,I],X=()=>["none",G,T,I],Z=()=>[G,T,I],Q=()=>[ze,"full",...P()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[Ee],breakpoint:[Ee],color:[fl],container:[Ee],"drop-shadow":[Ee],ease:["in","out","in-out"],font:[gl],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[Ee],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[Ee],shadow:[Ee],spacing:["px",G],text:[Ee],"text-shadow":[Ee],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",ze,I,T,y]}],container:["container"],columns:[{columns:[G,I,T,c]}],"break-after":[{"break-after":w()}],"break-before":[{"break-before":w()}],"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:_()}],overflow:[{overflow:O()}],"overflow-x":[{"overflow-x":O()}],"overflow-y":[{"overflow-y":O()}],overscroll:[{overscroll:N()}],"overscroll-x":[{"overscroll-x":N()}],"overscroll-y":[{"overscroll-y":N()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:j()}],"inset-x":[{"inset-x":j()}],"inset-y":[{"inset-y":j()}],start:[{start:j()}],end:[{end:j()}],top:[{top:j()}],right:[{right:j()}],bottom:[{bottom:j()}],left:[{left:j()}],visibility:["visible","invisible","collapse"],z:[{z:[Ne,"auto",T,I]}],basis:[{basis:[ze,"full","auto",c,...P()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[G,ze,"auto","initial","none",I]}],grow:[{grow:["",G,T,I]}],shrink:[{shrink:["",G,T,I]}],order:[{order:[Ne,"first","last","none",T,I]}],"grid-cols":[{"grid-cols":F()}],"col-start-end":[{col:z()}],"col-start":[{"col-start":V()}],"col-end":[{"col-end":V()}],"grid-rows":[{"grid-rows":F()}],"row-start-end":[{row:z()}],"row-start":[{"row-start":V()}],"row-end":[{"row-end":V()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":U()}],"auto-rows":[{"auto-rows":U()}],gap:[{gap:P()}],"gap-x":[{"gap-x":P()}],"gap-y":[{"gap-y":P()}],"justify-content":[{justify:[...H(),"normal"]}],"justify-items":[{"justify-items":[...K(),"normal"]}],"justify-self":[{"justify-self":["auto",...K()]}],"align-content":[{content:["normal",...H()]}],"align-items":[{items:[...K(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...K(),{baseline:["","last"]}]}],"place-content":[{"place-content":H()}],"place-items":[{"place-items":[...K(),"baseline"]}],"place-self":[{"place-self":["auto",...K()]}],p:[{p:P()}],px:[{px:P()}],py:[{py:P()}],ps:[{ps:P()}],pe:[{pe:P()}],pt:[{pt:P()}],pr:[{pr:P()}],pb:[{pb:P()}],pl:[{pl:P()}],m:[{m:k()}],mx:[{mx:k()}],my:[{my:k()}],ms:[{ms:k()}],me:[{me:k()}],mt:[{mt:k()}],mr:[{mr:k()}],mb:[{mb:k()}],ml:[{ml:k()}],"space-x":[{"space-x":P()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":P()}],"space-y-reverse":["space-y-reverse"],size:[{size:W()}],w:[{w:[c,"screen",...W()]}],"min-w":[{"min-w":[c,"screen","none",...W()]}],"max-w":[{"max-w":[c,"screen","none","prose",{screen:[a]},...W()]}],h:[{h:["screen","lh",...W()]}],"min-h":[{"min-h":["screen","lh","none",...W()]}],"max-h":[{"max-h":["screen","lh",...W()]}],"font-size":[{text:["base",n,rt,Le]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,T,pn]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",fn,I]}],"font-family":[{font:[xl,I,t]}],"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:[o,T,I]}],"line-clamp":[{"line-clamp":[G,"none",T,pn]}],leading:[{leading:[s,...P()]}],"list-image":[{"list-image":["none",T,I]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",T,I]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:E()}],"text-color":[{text:E()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ne(),"wavy"]}],"text-decoration-thickness":[{decoration:[G,"from-font","auto",T,Le]}],"text-decoration-color":[{decoration:E()}],"underline-offset":[{"underline-offset":[G,"auto",T,I]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:P()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",T,I]}],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",T,I]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:A()}],"bg-repeat":[{bg:J()}],"bg-size":[{bg:S()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Ne,T,I],radial:["",T,I],conic:[Ne,T,I]},wl,yl]}],"bg-color":[{bg:E()}],"gradient-from-pos":[{from:D()}],"gradient-via-pos":[{via:D()}],"gradient-to-pos":[{to:D()}],"gradient-from":[{from:E()}],"gradient-via":[{via:E()}],"gradient-to":[{to:E()}],rounded:[{rounded:$()}],"rounded-s":[{"rounded-s":$()}],"rounded-e":[{"rounded-e":$()}],"rounded-t":[{"rounded-t":$()}],"rounded-r":[{"rounded-r":$()}],"rounded-b":[{"rounded-b":$()}],"rounded-l":[{"rounded-l":$()}],"rounded-ss":[{"rounded-ss":$()}],"rounded-se":[{"rounded-se":$()}],"rounded-ee":[{"rounded-ee":$()}],"rounded-es":[{"rounded-es":$()}],"rounded-tl":[{"rounded-tl":$()}],"rounded-tr":[{"rounded-tr":$()}],"rounded-br":[{"rounded-br":$()}],"rounded-bl":[{"rounded-bl":$()}],"border-w":[{border:L()}],"border-w-x":[{"border-x":L()}],"border-w-y":[{"border-y":L()}],"border-w-s":[{"border-s":L()}],"border-w-e":[{"border-e":L()}],"border-w-t":[{"border-t":L()}],"border-w-r":[{"border-r":L()}],"border-w-b":[{"border-b":L()}],"border-w-l":[{"border-l":L()}],"divide-x":[{"divide-x":L()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":L()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...ne(),"hidden","none"]}],"divide-style":[{divide:[...ne(),"hidden","none"]}],"border-color":[{border:E()}],"border-color-x":[{"border-x":E()}],"border-color-y":[{"border-y":E()}],"border-color-s":[{"border-s":E()}],"border-color-e":[{"border-e":E()}],"border-color-t":[{"border-t":E()}],"border-color-r":[{"border-r":E()}],"border-color-b":[{"border-b":E()}],"border-color-l":[{"border-l":E()}],"divide-color":[{divide:E()}],"outline-style":[{outline:[...ne(),"none","hidden"]}],"outline-offset":[{"outline-offset":[G,T,I]}],"outline-w":[{outline:["",G,rt,Le]}],"outline-color":[{outline:E()}],shadow:[{shadow:["","none",f,St,wt]}],"shadow-color":[{shadow:E()}],"inset-shadow":[{"inset-shadow":["none",d,St,wt]}],"inset-shadow-color":[{"inset-shadow":E()}],"ring-w":[{ring:L()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:E()}],"ring-offset-w":[{"ring-offset":[G,Le]}],"ring-offset-color":[{"ring-offset":E()}],"inset-ring-w":[{"inset-ring":L()}],"inset-ring-color":[{"inset-ring":E()}],"text-shadow":[{"text-shadow":["none",h,St,wt]}],"text-shadow-color":[{"text-shadow":E()}],opacity:[{opacity:[G,T,I]}],"mix-blend":[{"mix-blend":[...te(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":te()}],"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":[G]}],"mask-image-linear-from-pos":[{"mask-linear-from":R()}],"mask-image-linear-to-pos":[{"mask-linear-to":R()}],"mask-image-linear-from-color":[{"mask-linear-from":E()}],"mask-image-linear-to-color":[{"mask-linear-to":E()}],"mask-image-t-from-pos":[{"mask-t-from":R()}],"mask-image-t-to-pos":[{"mask-t-to":R()}],"mask-image-t-from-color":[{"mask-t-from":E()}],"mask-image-t-to-color":[{"mask-t-to":E()}],"mask-image-r-from-pos":[{"mask-r-from":R()}],"mask-image-r-to-pos":[{"mask-r-to":R()}],"mask-image-r-from-color":[{"mask-r-from":E()}],"mask-image-r-to-color":[{"mask-r-to":E()}],"mask-image-b-from-pos":[{"mask-b-from":R()}],"mask-image-b-to-pos":[{"mask-b-to":R()}],"mask-image-b-from-color":[{"mask-b-from":E()}],"mask-image-b-to-color":[{"mask-b-to":E()}],"mask-image-l-from-pos":[{"mask-l-from":R()}],"mask-image-l-to-pos":[{"mask-l-to":R()}],"mask-image-l-from-color":[{"mask-l-from":E()}],"mask-image-l-to-color":[{"mask-l-to":E()}],"mask-image-x-from-pos":[{"mask-x-from":R()}],"mask-image-x-to-pos":[{"mask-x-to":R()}],"mask-image-x-from-color":[{"mask-x-from":E()}],"mask-image-x-to-color":[{"mask-x-to":E()}],"mask-image-y-from-pos":[{"mask-y-from":R()}],"mask-image-y-to-pos":[{"mask-y-to":R()}],"mask-image-y-from-color":[{"mask-y-from":E()}],"mask-image-y-to-color":[{"mask-y-to":E()}],"mask-image-radial":[{"mask-radial":[T,I]}],"mask-image-radial-from-pos":[{"mask-radial-from":R()}],"mask-image-radial-to-pos":[{"mask-radial-to":R()}],"mask-image-radial-from-color":[{"mask-radial-from":E()}],"mask-image-radial-to-color":[{"mask-radial-to":E()}],"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":C()}],"mask-image-conic-pos":[{"mask-conic":[G]}],"mask-image-conic-from-pos":[{"mask-conic-from":R()}],"mask-image-conic-to-pos":[{"mask-conic-to":R()}],"mask-image-conic-from-color":[{"mask-conic-from":E()}],"mask-image-conic-to-color":[{"mask-conic-to":E()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:A()}],"mask-repeat":[{mask:J()}],"mask-size":[{mask:S()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",T,I]}],filter:[{filter:["","none",T,I]}],blur:[{blur:Y()}],brightness:[{brightness:[G,T,I]}],contrast:[{contrast:[G,T,I]}],"drop-shadow":[{"drop-shadow":["","none",g,St,wt]}],"drop-shadow-color":[{"drop-shadow":E()}],grayscale:[{grayscale:["",G,T,I]}],"hue-rotate":[{"hue-rotate":[G,T,I]}],invert:[{invert:["",G,T,I]}],saturate:[{saturate:[G,T,I]}],sepia:[{sepia:["",G,T,I]}],"backdrop-filter":[{"backdrop-filter":["","none",T,I]}],"backdrop-blur":[{"backdrop-blur":Y()}],"backdrop-brightness":[{"backdrop-brightness":[G,T,I]}],"backdrop-contrast":[{"backdrop-contrast":[G,T,I]}],"backdrop-grayscale":[{"backdrop-grayscale":["",G,T,I]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[G,T,I]}],"backdrop-invert":[{"backdrop-invert":["",G,T,I]}],"backdrop-opacity":[{"backdrop-opacity":[G,T,I]}],"backdrop-saturate":[{"backdrop-saturate":[G,T,I]}],"backdrop-sepia":[{"backdrop-sepia":["",G,T,I]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":P()}],"border-spacing-x":[{"border-spacing-x":P()}],"border-spacing-y":[{"border-spacing-y":P()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",T,I]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[G,"initial",T,I]}],ease:[{ease:["linear","initial",x,T,I]}],delay:[{delay:[G,T,I]}],animate:[{animate:["none",b,T,I]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[m,T,I]}],"perspective-origin":[{"perspective-origin":_()}],rotate:[{rotate:ee()}],"rotate-x":[{"rotate-x":ee()}],"rotate-y":[{"rotate-y":ee()}],"rotate-z":[{"rotate-z":ee()}],scale:[{scale:X()}],"scale-x":[{"scale-x":X()}],"scale-y":[{"scale-y":X()}],"scale-z":[{"scale-z":X()}],"scale-3d":["scale-3d"],skew:[{skew:Z()}],"skew-x":[{"skew-x":Z()}],"skew-y":[{"skew-y":Z()}],transform:[{transform:[T,I,"","none","gpu","cpu"]}],"transform-origin":[{origin:_()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:Q()}],"translate-x":[{"translate-x":Q()}],"translate-y":[{"translate-y":Q()}],"translate-z":[{"translate-z":Q()}],"translate-none":["translate-none"],accent:[{accent:E()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:E()}],"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",T,I]}],"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":P()}],"scroll-mx":[{"scroll-mx":P()}],"scroll-my":[{"scroll-my":P()}],"scroll-ms":[{"scroll-ms":P()}],"scroll-me":[{"scroll-me":P()}],"scroll-mt":[{"scroll-mt":P()}],"scroll-mr":[{"scroll-mr":P()}],"scroll-mb":[{"scroll-mb":P()}],"scroll-ml":[{"scroll-ml":P()}],"scroll-p":[{"scroll-p":P()}],"scroll-px":[{"scroll-px":P()}],"scroll-py":[{"scroll-py":P()}],"scroll-ps":[{"scroll-ps":P()}],"scroll-pe":[{"scroll-pe":P()}],"scroll-pt":[{"scroll-pt":P()}],"scroll-pr":[{"scroll-pr":P()}],"scroll-pb":[{"scroll-pb":P()}],"scroll-pl":[{"scroll-pl":P()}],"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",T,I]}],fill:[{fill:["none",...E()]}],"stroke-w":[{stroke:[G,rt,Le,pn]}],stroke:[{stroke:["none",...E()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","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","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","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-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-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-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-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"]}},Rl=ol(El);function B(...e){return Rl(ho(e))}var Ct={exports:{}},ot={};var _r;function Pl(){if(_r)return ot;_r=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function n(r,o,s){var a=null;if(s!==void 0&&(a=""+s),o.key!==void 0&&(a=""+o.key),"key"in o){s={};for(var c in o)c!=="key"&&(s[c]=o[c])}else s=o;return o=s.ref,{$$typeof:e,type:r,key:a,ref:o!==void 0?o:null,props:s}}return ot.Fragment=t,ot.jsx=n,ot.jsxs=n,ot}var st={};var Nr;function _l(){return Nr||(Nr=1,process.env.NODE_ENV!=="production"&&(function(){function e(S){if(S==null)return null;if(typeof S=="function")return S.$$typeof===z?null:S.displayName||S.name||null;if(typeof S=="string")return S;switch(S){case y:return"Fragment";case b:return"Profiler";case x:return"StrictMode";case O:return"Suspense";case N:return"SuspenseList";case F:return"Activity"}if(typeof S=="object")switch(typeof S.tag=="number"&&console.error("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),S.$$typeof){case m:return"Portal";case C:return S.displayName||"Context";case w:return(S._context.displayName||"Context")+".Consumer";case _:var D=S.render;return S=S.displayName,S||(S=D.displayName||D.name||"",S=S!==""?"ForwardRef("+S+")":"ForwardRef"),S;case P:return D=S.displayName||null,D!==null?D:e(S.type)||"Memo";case j:D=S._payload,S=S._init;try{return e(S(D))}catch{}}return null}function t(S){return""+S}function n(S){try{t(S);var D=!1}catch{D=!0}if(D){D=console;var $=D.error,L=typeof Symbol=="function"&&Symbol.toStringTag&&S[Symbol.toStringTag]||S.constructor.name||"Object";return $.call(D,"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",L),t(S)}}function r(S){if(S===y)return"<>";if(typeof S=="object"&&S!==null&&S.$$typeof===j)return"<...>";try{var D=e(S);return D?"<"+D+">":"<...>"}catch{return"<...>"}}function o(){var S=V.A;return S===null?null:S.getOwner()}function s(){return Error("react-stack-top-frame")}function a(S){if(U.call(S,"key")){var D=Object.getOwnPropertyDescriptor(S,"key").get;if(D&&D.isReactWarning)return!1}return S.key!==void 0}function c(S,D){function $(){k||(k=!0,console.error("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)",D))}$.isReactWarning=!0,Object.defineProperty(S,"key",{get:$,configurable:!0})}function l(){var S=e(this.type);return W[S]||(W[S]=!0,console.error("Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.")),S=this.props.ref,S!==void 0?S:null}function u(S,D,$,L,ne,te){var R=$.ref;return S={$$typeof:v,type:S,key:D,props:$,_owner:L},(R!==void 0?R:null)!==null?Object.defineProperty(S,"ref",{enumerable:!1,get:l}):Object.defineProperty(S,"ref",{enumerable:!1,value:null}),S._store={},Object.defineProperty(S._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:0}),Object.defineProperty(S,"_debugInfo",{configurable:!1,enumerable:!1,writable:!0,value:null}),Object.defineProperty(S,"_debugStack",{configurable:!1,enumerable:!1,writable:!0,value:ne}),Object.defineProperty(S,"_debugTask",{configurable:!1,enumerable:!1,writable:!0,value:te}),Object.freeze&&(Object.freeze(S.props),Object.freeze(S)),S}function f(S,D,$,L,ne,te){var R=D.children;if(R!==void 0)if(L)if(H(R)){for(L=0;L<R.length;L++)d(R[L]);Object.freeze&&Object.freeze(R)}else console.error("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else d(R);if(U.call(D,"key")){R=e(S);var Y=Object.keys(D).filter(function(X){return X!=="key"});L=0<Y.length?"{key: someKey, "+Y.join(": ..., ")+": ...}":"{key: someKey}",J[R+L]||(Y=0<Y.length?"{"+Y.join(": ..., ")+": ...}":"{}",console.error(`A props object containing a "key" prop is being spread into JSX:
|
|
2
|
+
let props = %s;
|
|
3
|
+
<%s {...props} />
|
|
4
|
+
React keys must be passed directly to JSX without using spread:
|
|
5
|
+
let props = %s;
|
|
6
|
+
<%s key={someKey} {...props} />`,L,R,Y,R),J[R+L]=!0)}if(R=null,$!==void 0&&(n($),R=""+$),a(D)&&(n(D.key),R=""+D.key),"key"in D){$={};for(var ee in D)ee!=="key"&&($[ee]=D[ee])}else $=D;return R&&c($,typeof S=="function"?S.displayName||S.name||"Unknown":S),u(S,R,$,o(),ne,te)}function d(S){h(S)?S._store&&(S._store.validated=1):typeof S=="object"&&S!==null&&S.$$typeof===j&&(S._payload.status==="fulfilled"?h(S._payload.value)&&S._payload.value._store&&(S._payload.value._store.validated=1):S._store&&(S._store.validated=1))}function h(S){return typeof S=="object"&&S!==null&&S.$$typeof===v}var g=se,v=Symbol.for("react.transitional.element"),m=Symbol.for("react.portal"),y=Symbol.for("react.fragment"),x=Symbol.for("react.strict_mode"),b=Symbol.for("react.profiler"),w=Symbol.for("react.consumer"),C=Symbol.for("react.context"),_=Symbol.for("react.forward_ref"),O=Symbol.for("react.suspense"),N=Symbol.for("react.suspense_list"),P=Symbol.for("react.memo"),j=Symbol.for("react.lazy"),F=Symbol.for("react.activity"),z=Symbol.for("react.client.reference"),V=g.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,U=Object.prototype.hasOwnProperty,H=Array.isArray,K=console.createTask?console.createTask:function(){return null};g={react_stack_bottom_frame:function(S){return S()}};var k,W={},E=g.react_stack_bottom_frame.bind(g,s)(),A=K(r(s)),J={};st.Fragment=y,st.jsx=function(S,D,$){var L=1e4>V.recentlyCreatedOwnerStacks++;return f(S,D,$,!1,L?Error("react-stack-top-frame"):E,L?K(r(S)):A)},st.jsxs=function(S,D,$){var L=1e4>V.recentlyCreatedOwnerStacks++;return f(S,D,$,!0,L?Error("react-stack-top-frame"):E,L?K(r(S)):A)}})()),st}var Ar;function Nl(){return Ar||(Ar=1,process.env.NODE_ENV==="production"?Ct.exports=Pl():Ct.exports=_l()),Ct.exports}var p=Nl();function Or(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function ie(...e){return t=>{let n=!1;const r=e.map(o=>{const s=Or(o,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let o=0;o<r.length;o++){const s=r[o];typeof s=="function"?s():Or(e[o],null)}}}}function q(...e){return i.useCallback(ie(...e),e)}var Al=Symbol.for("react.lazy"),Dt=i[" use ".trim().toString()];function Ol(e){return typeof e=="object"&&e!==null&&"then"in e}function No(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===Al&&"_payload"in e&&Ol(e._payload)}function Ao(e){const t=Tl(e),n=i.forwardRef((r,o)=>{let{children:s,...a}=r;No(s)&&typeof Dt=="function"&&(s=Dt(s._payload));const c=i.Children.toArray(s),l=c.find(kl);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}var Il=Ao("Slot");function Tl(e){const t=i.forwardRef((n,r)=>{let{children:o,...s}=n;if(No(o)&&typeof Dt=="function"&&(o=Dt(o._payload)),i.isValidElement(o)){const a=jl(o),c=Dl(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Ml=Symbol("radix.slottable");function kl(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Ml}function Dl(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function jl(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}const Ir=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,Tr=ho,Vn=(e,t)=>n=>{var r;if(t?.variants==null)return Tr(e,n?.class,n?.className);const{variants:o,defaultVariants:s}=t,a=Object.keys(o).map(u=>{const f=n?.[u],d=s?.[u];if(f===null)return null;const h=Ir(f)||Ir(d);return o[u][h]}),c=n&&Object.entries(n).reduce((u,f)=>{let[d,h]=f;return h===void 0||(u[d]=h),u},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((u,f)=>{let{class:d,className:h,...g}=f;return Object.entries(g).every(v=>{let[m,y]=v;return Array.isArray(y)?y.includes({...s,...c}[m]):{...s,...c}[m]===y})?[...u,d,h]:u},[]);return Tr(e,a,l,n?.class,n?.className)},Oo=Vn("inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),Io=i.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...o},s)=>{const a=r?Il:"button";return p.jsx(a,{className:B(Oo({variant:t,size:n,className:e})),ref:s,...o})});Io.displayName="Button";const To=i.forwardRef(({className:e,type:t,...n},r)=>p.jsx("input",{type:t,className:B("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),ref:r,...n}));To.displayName="Input";const Mo=i.forwardRef(({className:e,...t},n)=>p.jsx("textarea",{className:B("flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),ref:n,...t}));Mo.displayName="Textarea";var $l=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],pt=$l.reduce((e,t)=>{const n=Ao(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),Ll="Label",ko=i.forwardRef((e,t)=>p.jsx(pt.label,{...e,ref:t,onMouseDown:n=>{n.target.closest("button, input, select, textarea")||(e.onMouseDown?.(n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));ko.displayName=Ll;var Do=ko;const Fl=Vn("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),jo=i.forwardRef(({className:e,...t},n)=>p.jsx(Do,{ref:n,className:B(Fl(),e),...t}));jo.displayName=Do.displayName;const $o=Vn("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}});function Vl({className:e,variant:t,...n}){return p.jsx("div",{className:B($o({variant:t}),e),...n})}var Wl="Separator",Mr="horizontal",Bl=["horizontal","vertical"],Lo=i.forwardRef((e,t)=>{const{decorative:n,orientation:r=Mr,...o}=e,s=Hl(r)?r:Mr,c=n?{role:"none"}:{"aria-orientation":s==="vertical"?s:void 0,role:"separator"};return p.jsx(pt.div,{"data-orientation":s,...c,...o,ref:t})});Lo.displayName=Wl;function Hl(e){return Bl.includes(e)}var Fo=Lo;const Vo=i.forwardRef(({className:e,orientation:t="horizontal",...n},r)=>p.jsx(Fo,{ref:r,decorative:!0,orientation:t,className:B("shrink-0 bg-border",t==="horizontal"?"h-[1px] w-full":"h-full w-[1px]",e),...n}));Vo.displayName=Fo.displayName;function zl(e,t=[]){let n=[];function r(s,a){const c=i.createContext(a);c.displayName=s+"Context";const l=n.length;n=[...n,a];const u=d=>{const{scope:h,children:g,...v}=d,m=h?.[e]?.[l]||c,y=i.useMemo(()=>v,Object.values(v));return p.jsx(m.Provider,{value:y,children:g})};u.displayName=s+"Provider";function f(d,h){const g=h?.[e]?.[l]||c,v=i.useContext(g);if(v)return v;if(a!==void 0)return a;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[u,f]}const o=()=>{const s=n.map(a=>i.createContext(a));return function(c){const l=c?.[e]||s;return i.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return o.scopeName=e,[r,Ul(o,...t)]}function Ul(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const a=r.reduce((c,{useScope:l,scopeName:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return i.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function pe(e){const t=i.useRef(e);return i.useEffect(()=>{t.current=e}),i.useMemo(()=>(...n)=>t.current?.(...n),[])}var oe=globalThis?.document?i.useLayoutEffect:()=>{},Et={exports:{}},mn={};var kr;function Gl(){if(kr)return mn;kr=1;var e=se;function t(d,h){return d===h&&(d!==0||1/d===1/h)||d!==d&&h!==h}var n=typeof Object.is=="function"?Object.is:t,r=e.useState,o=e.useEffect,s=e.useLayoutEffect,a=e.useDebugValue;function c(d,h){var g=h(),v=r({inst:{value:g,getSnapshot:h}}),m=v[0].inst,y=v[1];return s(function(){m.value=g,m.getSnapshot=h,l(m)&&y({inst:m})},[d,g,h]),o(function(){return l(m)&&y({inst:m}),d(function(){l(m)&&y({inst:m})})},[d]),a(g),g}function l(d){var h=d.getSnapshot;d=d.value;try{var g=h();return!n(d,g)}catch{return!0}}function u(d,h){return h()}var f=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?u:c;return mn.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:f,mn}var hn={};var Dr;function Kl(){return Dr||(Dr=1,process.env.NODE_ENV!=="production"&&(function(){function e(g,v){return g===v&&(g!==0||1/g===1/v)||g!==g&&v!==v}function t(g,v){f||o.startTransition===void 0||(f=!0,console.error("You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."));var m=v();if(!d){var y=v();s(m,y)||(console.error("The result of getSnapshot should be cached to avoid an infinite loop"),d=!0)}y=a({inst:{value:m,getSnapshot:v}});var x=y[0].inst,b=y[1];return l(function(){x.value=m,x.getSnapshot=v,n(x)&&b({inst:x})},[g,m,v]),c(function(){return n(x)&&b({inst:x}),g(function(){n(x)&&b({inst:x})})},[g]),u(m),m}function n(g){var v=g.getSnapshot;g=g.value;try{var m=v();return!s(g,m)}catch{return!0}}function r(g,v){return v()}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var o=se,s=typeof Object.is=="function"?Object.is:e,a=o.useState,c=o.useEffect,l=o.useLayoutEffect,u=o.useDebugValue,f=!1,d=!1,h=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?r:t;hn.useSyncExternalStore=o.useSyncExternalStore!==void 0?o.useSyncExternalStore:h,typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()),hn}var jr;function Yl(){return jr||(jr=1,process.env.NODE_ENV==="production"?Et.exports=Gl():Et.exports=Kl()),Et.exports}var Xl=Yl();function ql(){return Xl.useSyncExternalStore(Zl,()=>!0,()=>!1)}function Zl(){return()=>{}}var Wn="Avatar",[Jl]=zl(Wn),[Ql,Wo]=Jl(Wn),Bo=i.forwardRef((e,t)=>{const{__scopeAvatar:n,...r}=e,[o,s]=i.useState("idle");return p.jsx(Ql,{scope:n,imageLoadingStatus:o,onImageLoadingStatusChange:s,children:p.jsx(pt.span,{...r,ref:t})})});Bo.displayName=Wn;var Ho="AvatarImage",zo=i.forwardRef((e,t)=>{const{__scopeAvatar:n,src:r,onLoadingStatusChange:o=()=>{},...s}=e,a=Wo(Ho,n),c=eu(r,s),l=pe(u=>{o(u),a.onImageLoadingStatusChange(u)});return oe(()=>{c!=="idle"&&l(c)},[c,l]),c==="loaded"?p.jsx(pt.img,{...s,ref:t,src:r}):null});zo.displayName=Ho;var Uo="AvatarFallback",Go=i.forwardRef((e,t)=>{const{__scopeAvatar:n,delayMs:r,...o}=e,s=Wo(Uo,n),[a,c]=i.useState(r===void 0);return i.useEffect(()=>{if(r!==void 0){const l=window.setTimeout(()=>c(!0),r);return()=>window.clearTimeout(l)}},[r]),a&&s.imageLoadingStatus!=="loaded"?p.jsx(pt.span,{...o,ref:t}):null});Go.displayName=Uo;function $r(e,t){return e?t?(e.src!==t&&(e.src=t),e.complete&&e.naturalWidth>0?"loaded":"loading"):"error":"idle"}function eu(e,{referrerPolicy:t,crossOrigin:n}){const r=ql(),o=i.useRef(null),s=r?(o.current||(o.current=new window.Image),o.current):null,[a,c]=i.useState(()=>$r(s,e));return oe(()=>{c($r(s,e))},[s,e]),oe(()=>{const l=d=>()=>{c(d)};if(!s)return;const u=l("loaded"),f=l("error");return s.addEventListener("load",u),s.addEventListener("error",f),t&&(s.referrerPolicy=t),typeof n=="string"&&(s.crossOrigin=n),()=>{s.removeEventListener("load",u),s.removeEventListener("error",f)}},[s,n,t]),a}var Ko=Bo,Yo=zo,Xo=Go;const qo=i.forwardRef(({className:e,...t},n)=>p.jsx(Ko,{ref:n,className:B("relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full",e),...t}));qo.displayName=Ko.displayName;const Zo=i.forwardRef(({className:e,...t},n)=>p.jsx(Yo,{ref:n,className:B("aspect-square h-full w-full",e),...t}));Zo.displayName=Yo.displayName;const Jo=i.forwardRef(({className:e,...t},n)=>p.jsx(Xo,{ref:n,className:B("flex h-full w-full items-center justify-center rounded-full bg-muted",e),...t}));Jo.displayName=Xo.displayName;const Qo=i.forwardRef(({className:e,...t},n)=>p.jsx("div",{ref:n,className:B("rounded-lg border bg-card text-card-foreground shadow-sm",e),...t}));Qo.displayName="Card";const es=i.forwardRef(({className:e,...t},n)=>p.jsx("div",{ref:n,className:B("flex flex-col space-y-1.5 p-6",e),...t}));es.displayName="CardHeader";const ts=i.forwardRef(({className:e,...t},n)=>p.jsx("h3",{ref:n,className:B("text-2xl font-semibold leading-none tracking-tight",e),...t}));ts.displayName="CardTitle";const ns=i.forwardRef(({className:e,...t},n)=>p.jsx("p",{ref:n,className:B("text-sm text-muted-foreground",e),...t}));ns.displayName="CardDescription";const rs=i.forwardRef(({className:e,...t},n)=>p.jsx("div",{ref:n,className:B("p-6 pt-0",e),...t}));rs.displayName="CardContent";const os=i.forwardRef(({className:e,...t},n)=>p.jsx("div",{ref:n,className:B("flex items-center p-6 pt-0",e),...t}));os.displayName="CardFooter";function tu(e,t=[]){let n=[];function r(s,a){const c=i.createContext(a),l=n.length;n=[...n,a];const u=d=>{const{scope:h,children:g,...v}=d,m=h?.[e]?.[l]||c,y=i.useMemo(()=>v,Object.values(v));return p.jsx(m.Provider,{value:y,children:g})};u.displayName=s+"Provider";function f(d,h){const g=h?.[e]?.[l]||c,v=i.useContext(g);if(v)return v;if(a!==void 0)return a;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[u,f]}const o=()=>{const s=n.map(a=>i.createContext(a));return function(c){const l=c?.[e]||s;return i.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return o.scopeName=e,[r,nu(o,...t)]}function nu(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const a=r.reduce((c,{useScope:l,scopeName:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return i.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function M(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e?.(o),n===!1||!o.defaultPrevented)return t?.(o)}}var ru=i[" useInsertionEffect ".trim().toString()]||oe;function Ie({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[o,s,a]=ou({defaultProp:t,onChange:n}),c=e!==void 0,l=c?e:o;{const f=i.useRef(e!==void 0);i.useEffect(()=>{const d=f.current;d!==c&&console.warn(`${r} is changing from ${d?"controlled":"uncontrolled"} to ${c?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),f.current=c},[c,r])}const u=i.useCallback(f=>{if(c){const d=su(f)?f(e):f;d!==e&&a.current?.(d)}else s(f)},[c,e,s,a]);return[l,u]}function ou({defaultProp:e,onChange:t}){const[n,r]=i.useState(e),o=i.useRef(n),s=i.useRef(t);return ru(()=>{s.current=t},[t]),i.useEffect(()=>{o.current!==n&&(s.current?.(n),o.current=n)},[n,o]),[n,r,s]}function su(e){return typeof e=="function"}function Bn(e){const t=i.useRef({value:e,previous:e});return i.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}function Hn(e){const[t,n]=i.useState(void 0);return oe(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const s=o[0];let a,c;if("borderBoxSize"in s){const l=s.borderBoxSize,u=Array.isArray(l)?l[0]:l;a=u.inlineSize,c=u.blockSize}else a=e.offsetWidth,c=e.offsetHeight;n({width:a,height:c})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}function iu(e,t){return i.useReducer((n,r)=>t[n][r]??n,e)}var _e=e=>{const{present:t,children:n}=e,r=au(t),o=typeof n=="function"?n({present:r.isPresent}):i.Children.only(n),s=q(r.ref,cu(o));return typeof n=="function"||r.isPresent?i.cloneElement(o,{ref:s}):null};_e.displayName="Presence";function au(e){const[t,n]=i.useState(),r=i.useRef(null),o=i.useRef(e),s=i.useRef("none"),a=e?"mounted":"unmounted",[c,l]=iu(a,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return i.useEffect(()=>{const u=Rt(r.current);s.current=c==="mounted"?u:"none"},[c]),oe(()=>{const u=r.current,f=o.current;if(f!==e){const h=s.current,g=Rt(u);e?l("MOUNT"):g==="none"||u?.display==="none"?l("UNMOUNT"):l(f&&h!==g?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,l]),oe(()=>{if(t){let u;const f=t.ownerDocument.defaultView??window,d=g=>{const m=Rt(r.current).includes(CSS.escape(g.animationName));if(g.target===t&&m&&(l("ANIMATION_END"),!o.current)){const y=t.style.animationFillMode;t.style.animationFillMode="forwards",u=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=y)})}},h=g=>{g.target===t&&(s.current=Rt(r.current))};return t.addEventListener("animationstart",h),t.addEventListener("animationcancel",d),t.addEventListener("animationend",d),()=>{f.clearTimeout(u),t.removeEventListener("animationstart",h),t.removeEventListener("animationcancel",d),t.removeEventListener("animationend",d)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(c),ref:i.useCallback(u=>{r.current=u?getComputedStyle(u):null,n(u)},[])}}function Rt(e){return e?.animationName||"none"}function cu(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function lu(e){const t=uu(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(fu);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function uu(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=mu(o),c=pu(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var du=Symbol("radix.slottable");function fu(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===du}function pu(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function mu(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var hu=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],zn=hu.reduce((e,t)=>{const n=lu(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),zt="Checkbox",[gu]=tu(zt),[vu,Un]=gu(zt);function yu(e){const{__scopeCheckbox:t,checked:n,children:r,defaultChecked:o,disabled:s,form:a,name:c,onCheckedChange:l,required:u,value:f="on",internal_do_not_use_render:d}=e,[h,g]=Ie({prop:n,defaultProp:o??!1,onChange:l,caller:zt}),[v,m]=i.useState(null),[y,x]=i.useState(null),b=i.useRef(!1),w=v?!!a||!!v.closest("form"):!0,C={checked:h,disabled:s,setChecked:g,control:v,setControl:m,name:c,form:a,value:f,hasConsumerStoppedPropagationRef:b,required:u,defaultChecked:Oe(o)?!1:o,isFormControl:w,bubbleInput:y,setBubbleInput:x};return p.jsx(vu,{scope:t,...C,children:xu(d)?d(C):r})}var ss="CheckboxTrigger",is=i.forwardRef(({__scopeCheckbox:e,onKeyDown:t,onClick:n,...r},o)=>{const{control:s,value:a,disabled:c,checked:l,required:u,setControl:f,setChecked:d,hasConsumerStoppedPropagationRef:h,isFormControl:g,bubbleInput:v}=Un(ss,e),m=q(o,f),y=i.useRef(l);return i.useEffect(()=>{const x=s?.form;if(x){const b=()=>d(y.current);return x.addEventListener("reset",b),()=>x.removeEventListener("reset",b)}},[s,d]),p.jsx(zn.button,{type:"button",role:"checkbox","aria-checked":Oe(l)?"mixed":l,"aria-required":u,"data-state":ds(l),"data-disabled":c?"":void 0,disabled:c,value:a,...r,ref:m,onKeyDown:M(t,x=>{x.key==="Enter"&&x.preventDefault()}),onClick:M(n,x=>{d(b=>Oe(b)?!0:!b),v&&g&&(h.current=x.isPropagationStopped(),h.current||x.stopPropagation())})})});is.displayName=ss;var Gn=i.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:r,checked:o,defaultChecked:s,required:a,disabled:c,value:l,onCheckedChange:u,form:f,...d}=e;return p.jsx(yu,{__scopeCheckbox:n,checked:o,defaultChecked:s,disabled:c,required:a,onCheckedChange:u,name:r,form:f,value:l,internal_do_not_use_render:({isFormControl:h})=>p.jsxs(p.Fragment,{children:[p.jsx(is,{...d,ref:t,__scopeCheckbox:n}),h&&p.jsx(us,{__scopeCheckbox:n})]})})});Gn.displayName=zt;var as="CheckboxIndicator",cs=i.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...o}=e,s=Un(as,n);return p.jsx(_e,{present:r||Oe(s.checked)||s.checked===!0,children:p.jsx(zn.span,{"data-state":ds(s.checked),"data-disabled":s.disabled?"":void 0,...o,ref:t,style:{pointerEvents:"none",...e.style}})})});cs.displayName=as;var ls="CheckboxBubbleInput",us=i.forwardRef(({__scopeCheckbox:e,...t},n)=>{const{control:r,hasConsumerStoppedPropagationRef:o,checked:s,defaultChecked:a,required:c,disabled:l,name:u,value:f,form:d,bubbleInput:h,setBubbleInput:g}=Un(ls,e),v=q(n,g),m=Bn(s),y=Hn(r);i.useEffect(()=>{const b=h;if(!b)return;const w=window.HTMLInputElement.prototype,_=Object.getOwnPropertyDescriptor(w,"checked").set,O=!o.current;if(m!==s&&_){const N=new Event("click",{bubbles:O});b.indeterminate=Oe(s),_.call(b,Oe(s)?!1:s),b.dispatchEvent(N)}},[h,m,s,o]);const x=i.useRef(Oe(s)?!1:s);return p.jsx(zn.input,{type:"checkbox","aria-hidden":!0,defaultChecked:a??x.current,required:c,disabled:l,name:u,value:f,form:d,...t,tabIndex:-1,ref:v,style:{...t.style,...y,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});us.displayName=ls;function xu(e){return typeof e=="function"}function Oe(e){return e==="indeterminate"}function ds(e){return Oe(e)?"indeterminate":e?"checked":"unchecked"}const bu=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),wu=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,r)=>r?r.toUpperCase():n.toLowerCase()),Lr=e=>{const t=wu(e);return t.charAt(0).toUpperCase()+t.slice(1)},fs=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim(),Su=e=>{for(const t in e)if(t.startsWith("aria-")||t==="role"||t==="title")return!0};var Cu={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const Eu=se.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:s,iconNode:a,...c},l)=>se.createElement("svg",{ref:l,...Cu,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:fs("lucide",o),...!s&&!Su(c)&&{"aria-hidden":"true"},...c},[...a.map(([u,f])=>se.createElement(u,f)),...Array.isArray(s)?s:[s]]));const Qe=(e,t)=>{const n=se.forwardRef(({className:r,...o},s)=>se.createElement(Eu,{ref:s,iconNode:t,className:fs(`lucide-${bu(Lr(e))}`,`lucide-${e}`,r),...o}));return n.displayName=Lr(e),n};const Ru=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],Kn=Qe("check",Ru);const Pu=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],ps=Qe("chevron-down",Pu);const _u=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],Nu=Qe("chevron-right",_u);const Au=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],Ou=Qe("chevron-up",Au);const Iu=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],Tu=Qe("circle",Iu);const Mu=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],ku=Qe("x",Mu),ms=i.forwardRef(({className:e,...t},n)=>p.jsx(Gn,{ref:n,className:B("peer h-4 w-4 shrink-0 rounded-sm border border-primary ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground",e),...t,children:p.jsx(cs,{className:B("flex items-center justify-center text-current"),children:p.jsx(Kn,{className:"h-4 w-4"})})}));ms.displayName=Gn.displayName;function Du(e,t=[]){let n=[];function r(s,a){const c=i.createContext(a),l=n.length;n=[...n,a];const u=d=>{const{scope:h,children:g,...v}=d,m=h?.[e]?.[l]||c,y=i.useMemo(()=>v,Object.values(v));return p.jsx(m.Provider,{value:y,children:g})};u.displayName=s+"Provider";function f(d,h){const g=h?.[e]?.[l]||c,v=i.useContext(g);if(v)return v;if(a!==void 0)return a;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[u,f]}const o=()=>{const s=n.map(a=>i.createContext(a));return function(c){const l=c?.[e]||s;return i.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return o.scopeName=e,[r,ju(o,...t)]}function ju(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const a=r.reduce((c,{useScope:l,scopeName:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return i.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function $u(e){const t=Lu(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(Vu);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function Lu(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=Bu(o),c=Wu(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Fu=Symbol("radix.slottable");function Vu(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Fu}function Wu(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Bu(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Hu=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],hs=Hu.reduce((e,t)=>{const n=$u(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),Ut="Switch",[zu]=Du(Ut),[Uu,Gu]=zu(Ut),gs=i.forwardRef((e,t)=>{const{__scopeSwitch:n,name:r,checked:o,defaultChecked:s,required:a,disabled:c,value:l="on",onCheckedChange:u,form:f,...d}=e,[h,g]=i.useState(null),v=q(t,w=>g(w)),m=i.useRef(!1),y=h?f||!!h.closest("form"):!0,[x,b]=Ie({prop:o,defaultProp:s??!1,onChange:u,caller:Ut});return p.jsxs(Uu,{scope:n,checked:x,disabled:c,children:[p.jsx(hs.button,{type:"button",role:"switch","aria-checked":x,"aria-required":a,"data-state":bs(x),"data-disabled":c?"":void 0,disabled:c,value:l,...d,ref:v,onClick:M(e.onClick,w=>{b(C=>!C),y&&(m.current=w.isPropagationStopped(),m.current||w.stopPropagation())})}),y&&p.jsx(xs,{control:h,bubbles:!m.current,name:r,value:l,checked:x,required:a,disabled:c,form:f,style:{transform:"translateX(-100%)"}})]})});gs.displayName=Ut;var vs="SwitchThumb",ys=i.forwardRef((e,t)=>{const{__scopeSwitch:n,...r}=e,o=Gu(vs,n);return p.jsx(hs.span,{"data-state":bs(o.checked),"data-disabled":o.disabled?"":void 0,...r,ref:t})});ys.displayName=vs;var Ku="SwitchBubbleInput",xs=i.forwardRef(({__scopeSwitch:e,control:t,checked:n,bubbles:r=!0,...o},s)=>{const a=i.useRef(null),c=q(a,s),l=Bn(n),u=Hn(t);return i.useEffect(()=>{const f=a.current;if(!f)return;const d=window.HTMLInputElement.prototype,g=Object.getOwnPropertyDescriptor(d,"checked").set;if(l!==n&&g){const v=new Event("click",{bubbles:r});g.call(f,n),f.dispatchEvent(v)}},[l,n,r]),p.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:n,...o,tabIndex:-1,ref:c,style:{...o.style,...u,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});xs.displayName=Ku;function bs(e){return e?"checked":"unchecked"}var ws=gs,Yu=ys;const Ss=i.forwardRef(({className:e,...t},n)=>p.jsx(ws,{className:B("peer inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-primary data-[state=unchecked]:bg-input",e),...t,ref:n,children:p.jsx(Yu,{className:B("pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0")})}));Ss.displayName=ws.displayName;function Fr(e,[t,n]){return Math.min(n,Math.max(t,e))}function Xu(e,t=[]){let n=[];function r(s,a){const c=i.createContext(a),l=n.length;n=[...n,a];const u=d=>{const{scope:h,children:g,...v}=d,m=h?.[e]?.[l]||c,y=i.useMemo(()=>v,Object.values(v));return p.jsx(m.Provider,{value:y,children:g})};u.displayName=s+"Provider";function f(d,h){const g=h?.[e]?.[l]||c,v=i.useContext(g);if(v)return v;if(a!==void 0)return a;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[u,f]}const o=()=>{const s=n.map(a=>i.createContext(a));return function(c){const l=c?.[e]||s;return i.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return o.scopeName=e,[r,qu(o,...t)]}function qu(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const a=r.reduce((c,{useScope:l,scopeName:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return i.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function Vr(e){const t=Zu(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(Qu);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function Zu(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=td(o),c=ed(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Ju=Symbol("radix.slottable");function Qu(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Ju}function ed(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function td(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function Yn(e){const t=e+"CollectionProvider",[n,r]=Xu(t),[o,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),a=m=>{const{scope:y,children:x}=m,b=se.useRef(null),w=se.useRef(new Map).current;return p.jsx(o,{scope:y,itemMap:w,collectionRef:b,children:x})};a.displayName=t;const c=e+"CollectionSlot",l=Vr(c),u=se.forwardRef((m,y)=>{const{scope:x,children:b}=m,w=s(c,x),C=q(y,w.collectionRef);return p.jsx(l,{ref:C,children:b})});u.displayName=c;const f=e+"CollectionItemSlot",d="data-radix-collection-item",h=Vr(f),g=se.forwardRef((m,y)=>{const{scope:x,children:b,...w}=m,C=se.useRef(null),_=q(y,C),O=s(f,x);return se.useEffect(()=>(O.itemMap.set(C,{ref:C,...w}),()=>{O.itemMap.delete(C)})),p.jsx(h,{[d]:"",ref:_,children:b})});g.displayName=f;function v(m){const y=s(e+"CollectionConsumer",m);return se.useCallback(()=>{const b=y.collectionRef.current;if(!b)return[];const w=Array.from(b.querySelectorAll(`[${d}]`));return Array.from(y.itemMap.values()).sort((O,N)=>w.indexOf(O.ref.current)-w.indexOf(N.ref.current))},[y.collectionRef,y.itemMap])}return[{Provider:a,Slot:u,ItemSlot:g},v,r]}function nd(e,t=[]){let n=[];function r(s,a){const c=i.createContext(a),l=n.length;n=[...n,a];const u=d=>{const{scope:h,children:g,...v}=d,m=h?.[e]?.[l]||c,y=i.useMemo(()=>v,Object.values(v));return p.jsx(m.Provider,{value:y,children:g})};u.displayName=s+"Provider";function f(d,h){const g=h?.[e]?.[l]||c,v=i.useContext(g);if(v)return v;if(a!==void 0)return a;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[u,f]}const o=()=>{const s=n.map(a=>i.createContext(a));return function(c){const l=c?.[e]||s;return i.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return o.scopeName=e,[r,rd(o,...t)]}function rd(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const a=r.reduce((c,{useScope:l,scopeName:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return i.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}var od=i.createContext(void 0);function Xn(e){const t=i.useContext(od);return e||t||"ltr"}function sd(e){const t=id(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(cd);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function id(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=ud(o),c=ld(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var ad=Symbol("radix.slottable");function cd(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===ad}function ld(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function ud(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var dd=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Cs=dd.reduce((e,t)=>{const n=sd(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function fd(e,t){e&&ft.flushSync(()=>e.dispatchEvent(t))}function pd(e,t=globalThis?.document){const n=pe(e);i.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var md="DismissableLayer",_n="dismissableLayer.update",hd="dismissableLayer.pointerDownOutside",gd="dismissableLayer.focusOutside",Wr,Es=i.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Gt=i.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:s,onInteractOutside:a,onDismiss:c,...l}=e,u=i.useContext(Es),[f,d]=i.useState(null),h=f?.ownerDocument??globalThis?.document,[,g]=i.useState({}),v=q(t,N=>d(N)),m=Array.from(u.layers),[y]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),x=m.indexOf(y),b=f?m.indexOf(f):-1,w=u.layersWithOutsidePointerEventsDisabled.size>0,C=b>=x,_=xd(N=>{const P=N.target,j=[...u.branches].some(F=>F.contains(P));!C||j||(o?.(N),a?.(N),N.defaultPrevented||c?.())},h),O=bd(N=>{const P=N.target;[...u.branches].some(F=>F.contains(P))||(s?.(N),a?.(N),N.defaultPrevented||c?.())},h);return pd(N=>{b===u.layers.size-1&&(r?.(N),!N.defaultPrevented&&c&&(N.preventDefault(),c()))},h),i.useEffect(()=>{if(f)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(Wr=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(f)),u.layers.add(f),Br(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(h.body.style.pointerEvents=Wr)}},[f,h,n,u]),i.useEffect(()=>()=>{f&&(u.layers.delete(f),u.layersWithOutsidePointerEventsDisabled.delete(f),Br())},[f,u]),i.useEffect(()=>{const N=()=>g({});return document.addEventListener(_n,N),()=>document.removeEventListener(_n,N)},[]),p.jsx(Cs.div,{...l,ref:v,style:{pointerEvents:w?C?"auto":"none":void 0,...e.style},onFocusCapture:M(e.onFocusCapture,O.onFocusCapture),onBlurCapture:M(e.onBlurCapture,O.onBlurCapture),onPointerDownCapture:M(e.onPointerDownCapture,_.onPointerDownCapture)})});Gt.displayName=md;var vd="DismissableLayerBranch",yd=i.forwardRef((e,t)=>{const n=i.useContext(Es),r=i.useRef(null),o=q(t,r);return i.useEffect(()=>{const s=r.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),p.jsx(Cs.div,{...e,ref:o})});yd.displayName=vd;function xd(e,t=globalThis?.document){const n=pe(e),r=i.useRef(!1),o=i.useRef(()=>{});return i.useEffect(()=>{const s=c=>{if(c.target&&!r.current){let l=function(){Rs(hd,n,u,{discrete:!0})};const u={originalEvent:c};c.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=l,t.addEventListener("click",o.current,{once:!0})):l()}else t.removeEventListener("click",o.current);r.current=!1},a=window.setTimeout(()=>{t.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",s),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function bd(e,t=globalThis?.document){const n=pe(e),r=i.useRef(!1);return i.useEffect(()=>{const o=s=>{s.target&&!r.current&&Rs(gd,n,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Br(){const e=new CustomEvent(_n);document.dispatchEvent(e)}function Rs(e,t,n,{discrete:r}){const o=n.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?fd(o,s):o.dispatchEvent(s)}var gn=0;function qn(){i.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Hr()),document.body.insertAdjacentElement("beforeend",e[1]??Hr()),gn++,()=>{gn===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),gn--}},[])}function Hr(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}function wd(e){const t=Sd(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(Ed);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function Sd(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=Pd(o),c=Rd(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Cd=Symbol("radix.slottable");function Ed(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Cd}function Rd(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Pd(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var _d=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Nd=_d.reduce((e,t)=>{const n=wd(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),vn="focusScope.autoFocusOnMount",yn="focusScope.autoFocusOnUnmount",zr={bubbles:!1,cancelable:!0},Ad="FocusScope",Kt=i.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:s,...a}=e,[c,l]=i.useState(null),u=pe(o),f=pe(s),d=i.useRef(null),h=q(t,m=>l(m)),g=i.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;i.useEffect(()=>{if(r){let m=function(w){if(g.paused||!c)return;const C=w.target;c.contains(C)?d.current=C:Ae(d.current,{select:!0})},y=function(w){if(g.paused||!c)return;const C=w.relatedTarget;C!==null&&(c.contains(C)||Ae(d.current,{select:!0}))},x=function(w){if(document.activeElement===document.body)for(const _ of w)_.removedNodes.length>0&&Ae(c)};document.addEventListener("focusin",m),document.addEventListener("focusout",y);const b=new MutationObserver(x);return c&&b.observe(c,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",m),document.removeEventListener("focusout",y),b.disconnect()}}},[r,c,g.paused]),i.useEffect(()=>{if(c){Gr.add(g);const m=document.activeElement;if(!c.contains(m)){const x=new CustomEvent(vn,zr);c.addEventListener(vn,u),c.dispatchEvent(x),x.defaultPrevented||(Od(Dd(Ps(c)),{select:!0}),document.activeElement===m&&Ae(c))}return()=>{c.removeEventListener(vn,u),setTimeout(()=>{const x=new CustomEvent(yn,zr);c.addEventListener(yn,f),c.dispatchEvent(x),x.defaultPrevented||Ae(m??document.body,{select:!0}),c.removeEventListener(yn,f),Gr.remove(g)},0)}}},[c,u,f,g]);const v=i.useCallback(m=>{if(!n&&!r||g.paused)return;const y=m.key==="Tab"&&!m.altKey&&!m.ctrlKey&&!m.metaKey,x=document.activeElement;if(y&&x){const b=m.currentTarget,[w,C]=Id(b);w&&C?!m.shiftKey&&x===C?(m.preventDefault(),n&&Ae(w,{select:!0})):m.shiftKey&&x===w&&(m.preventDefault(),n&&Ae(C,{select:!0})):x===b&&m.preventDefault()}},[n,r,g.paused]);return p.jsx(Nd.div,{tabIndex:-1,...a,ref:h,onKeyDown:v})});Kt.displayName=Ad;function Od(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Ae(r,{select:t}),document.activeElement!==n)return}function Id(e){const t=Ps(e),n=Ur(t,e),r=Ur(t.reverse(),e);return[n,r]}function Ps(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Ur(e,t){for(const n of e)if(!Td(n,{upTo:t}))return n}function Td(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 Md(e){return e instanceof HTMLInputElement&&"select"in e}function Ae(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Md(e)&&t&&e.select()}}var Gr=kd();function kd(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=Kr(e,t),e.unshift(t)},remove(t){e=Kr(e,t),e[0]?.resume()}}}function Kr(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function Dd(e){return e.filter(t=>t.tagName!=="A")}var jd=i[" useId ".trim().toString()]||(()=>{}),$d=0;function he(e){const[t,n]=i.useState(jd());return oe(()=>{n(r=>r??String($d++))},[e]),t?`radix-${t}`:""}const Ld=["top","right","bottom","left"],Te=Math.min,ce=Math.max,jt=Math.round,Pt=Math.floor,we=e=>({x:e,y:e}),Fd={left:"right",right:"left",bottom:"top",top:"bottom"},Vd={start:"end",end:"start"};function Nn(e,t,n){return ce(e,Te(t,n))}function Re(e,t){return typeof e=="function"?e(t):e}function Pe(e){return e.split("-")[0]}function et(e){return e.split("-")[1]}function Zn(e){return e==="x"?"y":"x"}function Jn(e){return e==="y"?"height":"width"}const Wd=new Set(["top","bottom"]);function be(e){return Wd.has(Pe(e))?"y":"x"}function Qn(e){return Zn(be(e))}function Bd(e,t,n){n===void 0&&(n=!1);const r=et(e),o=Qn(e),s=Jn(o);let a=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(a=$t(a)),[a,$t(a)]}function Hd(e){const t=$t(e);return[An(e),t,An(t)]}function An(e){return e.replace(/start|end/g,t=>Vd[t])}const Yr=["left","right"],Xr=["right","left"],zd=["top","bottom"],Ud=["bottom","top"];function Gd(e,t,n){switch(e){case"top":case"bottom":return n?t?Xr:Yr:t?Yr:Xr;case"left":case"right":return t?zd:Ud;default:return[]}}function Kd(e,t,n,r){const o=et(e);let s=Gd(Pe(e),n==="start",r);return o&&(s=s.map(a=>a+"-"+o),t&&(s=s.concat(s.map(An)))),s}function $t(e){return e.replace(/left|right|bottom|top/g,t=>Fd[t])}function Yd(e){return{top:0,right:0,bottom:0,left:0,...e}}function _s(e){return typeof e!="number"?Yd(e):{top:e,right:e,bottom:e,left:e}}function Lt(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function qr(e,t,n){let{reference:r,floating:o}=e;const s=be(t),a=Qn(t),c=Jn(a),l=Pe(t),u=s==="y",f=r.x+r.width/2-o.width/2,d=r.y+r.height/2-o.height/2,h=r[c]/2-o[c]/2;let g;switch(l){case"top":g={x:f,y:r.y-o.height};break;case"bottom":g={x:f,y:r.y+r.height};break;case"right":g={x:r.x+r.width,y:d};break;case"left":g={x:r.x-o.width,y:d};break;default:g={x:r.x,y:r.y}}switch(et(t)){case"start":g[a]-=h*(n&&u?-1:1);break;case"end":g[a]+=h*(n&&u?-1:1);break}return g}const Xd=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:s=[],platform:a}=n,c=s.filter(Boolean),l=await(a.isRTL==null?void 0:a.isRTL(t));let u=await a.getElementRects({reference:e,floating:t,strategy:o}),{x:f,y:d}=qr(u,r,l),h=r,g={},v=0;for(let m=0;m<c.length;m++){const{name:y,fn:x}=c[m],{x:b,y:w,data:C,reset:_}=await x({x:f,y:d,initialPlacement:r,placement:h,strategy:o,middlewareData:g,rects:u,platform:a,elements:{reference:e,floating:t}});f=b??f,d=w??d,g={...g,[y]:{...g[y],...C}},_&&v<=50&&(v++,typeof _=="object"&&(_.placement&&(h=_.placement),_.rects&&(u=_.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:o}):_.rects),{x:f,y:d}=qr(u,h,l)),m=-1)}return{x:f,y:d,placement:h,strategy:o,middlewareData:g}};async function ct(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:s,rects:a,elements:c,strategy:l}=e,{boundary:u="clippingAncestors",rootBoundary:f="viewport",elementContext:d="floating",altBoundary:h=!1,padding:g=0}=Re(t,e),v=_s(g),y=c[h?d==="floating"?"reference":"floating":d],x=Lt(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(y)))==null||n?y:y.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(c.floating)),boundary:u,rootBoundary:f,strategy:l})),b=d==="floating"?{x:r,y:o,width:a.floating.width,height:a.floating.height}:a.reference,w=await(s.getOffsetParent==null?void 0:s.getOffsetParent(c.floating)),C=await(s.isElement==null?void 0:s.isElement(w))?await(s.getScale==null?void 0:s.getScale(w))||{x:1,y:1}:{x:1,y:1},_=Lt(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:b,offsetParent:w,strategy:l}):b);return{top:(x.top-_.top+v.top)/C.y,bottom:(_.bottom-x.bottom+v.bottom)/C.y,left:(x.left-_.left+v.left)/C.x,right:(_.right-x.right+v.right)/C.x}}const qd=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:s,platform:a,elements:c,middlewareData:l}=t,{element:u,padding:f=0}=Re(e,t)||{};if(u==null)return{};const d=_s(f),h={x:n,y:r},g=Qn(o),v=Jn(g),m=await a.getDimensions(u),y=g==="y",x=y?"top":"left",b=y?"bottom":"right",w=y?"clientHeight":"clientWidth",C=s.reference[v]+s.reference[g]-h[g]-s.floating[v],_=h[g]-s.reference[g],O=await(a.getOffsetParent==null?void 0:a.getOffsetParent(u));let N=O?O[w]:0;(!N||!await(a.isElement==null?void 0:a.isElement(O)))&&(N=c.floating[w]||s.floating[v]);const P=C/2-_/2,j=N/2-m[v]/2-1,F=Te(d[x],j),z=Te(d[b],j),V=F,U=N-m[v]-z,H=N/2-m[v]/2+P,K=Nn(V,H,U),k=!l.arrow&&et(o)!=null&&H!==K&&s.reference[v]/2-(H<V?F:z)-m[v]/2<0,W=k?H<V?H-V:H-U:0;return{[g]:h[g]+W,data:{[g]:K,centerOffset:H-K-W,...k&&{alignmentOffset:W}},reset:k}}}),Zd=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:s,rects:a,initialPlacement:c,platform:l,elements:u}=t,{mainAxis:f=!0,crossAxis:d=!0,fallbackPlacements:h,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:v="none",flipAlignment:m=!0,...y}=Re(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const x=Pe(o),b=be(c),w=Pe(c)===c,C=await(l.isRTL==null?void 0:l.isRTL(u.floating)),_=h||(w||!m?[$t(c)]:Hd(c)),O=v!=="none";!h&&O&&_.push(...Kd(c,m,v,C));const N=[c,..._],P=await ct(t,y),j=[];let F=((r=s.flip)==null?void 0:r.overflows)||[];if(f&&j.push(P[x]),d){const H=Bd(o,a,C);j.push(P[H[0]],P[H[1]])}if(F=[...F,{placement:o,overflows:j}],!j.every(H=>H<=0)){var z,V;const H=(((z=s.flip)==null?void 0:z.index)||0)+1,K=N[H];if(K&&(!(d==="alignment"?b!==be(K):!1)||F.every(E=>be(E.placement)===b?E.overflows[0]>0:!0)))return{data:{index:H,overflows:F},reset:{placement:K}};let k=(V=F.filter(W=>W.overflows[0]<=0).sort((W,E)=>W.overflows[1]-E.overflows[1])[0])==null?void 0:V.placement;if(!k)switch(g){case"bestFit":{var U;const W=(U=F.filter(E=>{if(O){const A=be(E.placement);return A===b||A==="y"}return!0}).map(E=>[E.placement,E.overflows.filter(A=>A>0).reduce((A,J)=>A+J,0)]).sort((E,A)=>E[1]-A[1])[0])==null?void 0:U[0];W&&(k=W);break}case"initialPlacement":k=c;break}if(o!==k)return{reset:{placement:k}}}return{}}}};function Zr(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Jr(e){return Ld.some(t=>e[t]>=0)}const Jd=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=Re(e,t);switch(r){case"referenceHidden":{const s=await ct(t,{...o,elementContext:"reference"}),a=Zr(s,n.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:Jr(a)}}}case"escaped":{const s=await ct(t,{...o,altBoundary:!0}),a=Zr(s,n.floating);return{data:{escapedOffsets:a,escaped:Jr(a)}}}default:return{}}}}},Ns=new Set(["left","top"]);async function Qd(e,t){const{placement:n,platform:r,elements:o}=e,s=await(r.isRTL==null?void 0:r.isRTL(o.floating)),a=Pe(n),c=et(n),l=be(n)==="y",u=Ns.has(a)?-1:1,f=s&&l?-1:1,d=Re(t,e);let{mainAxis:h,crossAxis:g,alignmentAxis:v}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return c&&typeof v=="number"&&(g=c==="end"?v*-1:v),l?{x:g*f,y:h*u}:{x:h*u,y:g*f}}const ef=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:s,placement:a,middlewareData:c}=t,l=await Qd(t,e);return a===((n=c.offset)==null?void 0:n.placement)&&(r=c.arrow)!=null&&r.alignmentOffset?{}:{x:o+l.x,y:s+l.y,data:{...l,placement:a}}}}},tf=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:s=!0,crossAxis:a=!1,limiter:c={fn:y=>{let{x,y:b}=y;return{x,y:b}}},...l}=Re(e,t),u={x:n,y:r},f=await ct(t,l),d=be(Pe(o)),h=Zn(d);let g=u[h],v=u[d];if(s){const y=h==="y"?"top":"left",x=h==="y"?"bottom":"right",b=g+f[y],w=g-f[x];g=Nn(b,g,w)}if(a){const y=d==="y"?"top":"left",x=d==="y"?"bottom":"right",b=v+f[y],w=v-f[x];v=Nn(b,v,w)}const m=c.fn({...t,[h]:g,[d]:v});return{...m,data:{x:m.x-n,y:m.y-r,enabled:{[h]:s,[d]:a}}}}}},nf=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:s,middlewareData:a}=t,{offset:c=0,mainAxis:l=!0,crossAxis:u=!0}=Re(e,t),f={x:n,y:r},d=be(o),h=Zn(d);let g=f[h],v=f[d];const m=Re(c,t),y=typeof m=="number"?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(l){const w=h==="y"?"height":"width",C=s.reference[h]-s.floating[w]+y.mainAxis,_=s.reference[h]+s.reference[w]-y.mainAxis;g<C?g=C:g>_&&(g=_)}if(u){var x,b;const w=h==="y"?"width":"height",C=Ns.has(Pe(o)),_=s.reference[d]-s.floating[w]+(C&&((x=a.offset)==null?void 0:x[d])||0)+(C?0:y.crossAxis),O=s.reference[d]+s.reference[w]+(C?0:((b=a.offset)==null?void 0:b[d])||0)-(C?y.crossAxis:0);v<_?v=_:v>O&&(v=O)}return{[h]:g,[d]:v}}}},rf=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:o,rects:s,platform:a,elements:c}=t,{apply:l=()=>{},...u}=Re(e,t),f=await ct(t,u),d=Pe(o),h=et(o),g=be(o)==="y",{width:v,height:m}=s.floating;let y,x;d==="top"||d==="bottom"?(y=d,x=h===(await(a.isRTL==null?void 0:a.isRTL(c.floating))?"start":"end")?"left":"right"):(x=d,y=h==="end"?"top":"bottom");const b=m-f.top-f.bottom,w=v-f.left-f.right,C=Te(m-f[y],b),_=Te(v-f[x],w),O=!t.middlewareData.shift;let N=C,P=_;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(P=w),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(N=b),O&&!h){const F=ce(f.left,0),z=ce(f.right,0),V=ce(f.top,0),U=ce(f.bottom,0);g?P=v-2*(F!==0||z!==0?F+z:ce(f.left,f.right)):N=m-2*(V!==0||U!==0?V+U:ce(f.top,f.bottom))}await l({...t,availableWidth:P,availableHeight:N});const j=await a.getDimensions(c.floating);return v!==j.width||m!==j.height?{reset:{rects:!0}}:{}}}};function Yt(){return typeof window<"u"}function tt(e){return As(e)?(e.nodeName||"").toLowerCase():"#document"}function le(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ce(e){var t;return(t=(As(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function As(e){return Yt()?e instanceof Node||e instanceof le(e).Node:!1}function ge(e){return Yt()?e instanceof Element||e instanceof le(e).Element:!1}function Se(e){return Yt()?e instanceof HTMLElement||e instanceof le(e).HTMLElement:!1}function Qr(e){return!Yt()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof le(e).ShadowRoot}const of=new Set(["inline","contents"]);function mt(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=ve(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!of.has(o)}const sf=new Set(["table","td","th"]);function af(e){return sf.has(tt(e))}const cf=[":popover-open",":modal"];function Xt(e){return cf.some(t=>{try{return e.matches(t)}catch{return!1}})}const lf=["transform","translate","scale","rotate","perspective"],uf=["transform","translate","scale","rotate","perspective","filter"],df=["paint","layout","strict","content"];function er(e){const t=tr(),n=ge(e)?ve(e):e;return lf.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||uf.some(r=>(n.willChange||"").includes(r))||df.some(r=>(n.contain||"").includes(r))}function ff(e){let t=Me(e);for(;Se(t)&&!qe(t);){if(er(t))return t;if(Xt(t))return null;t=Me(t)}return null}function tr(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const pf=new Set(["html","body","#document"]);function qe(e){return pf.has(tt(e))}function ve(e){return le(e).getComputedStyle(e)}function qt(e){return ge(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Me(e){if(tt(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Qr(e)&&e.host||Ce(e);return Qr(t)?t.host:t}function Os(e){const t=Me(e);return qe(t)?e.ownerDocument?e.ownerDocument.body:e.body:Se(t)&&mt(t)?t:Os(t)}function lt(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=Os(e),s=o===((r=e.ownerDocument)==null?void 0:r.body),a=le(o);if(s){const c=On(a);return t.concat(a,a.visualViewport||[],mt(o)?o:[],c&&n?lt(c):[])}return t.concat(o,lt(o,[],n))}function On(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Is(e){const t=ve(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Se(e),s=o?e.offsetWidth:n,a=o?e.offsetHeight:r,c=jt(n)!==s||jt(r)!==a;return c&&(n=s,r=a),{width:n,height:r,$:c}}function nr(e){return ge(e)?e:e.contextElement}function Ye(e){const t=nr(e);if(!Se(t))return we(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:s}=Is(t);let a=(s?jt(n.width):n.width)/r,c=(s?jt(n.height):n.height)/o;return(!a||!Number.isFinite(a))&&(a=1),(!c||!Number.isFinite(c))&&(c=1),{x:a,y:c}}const mf=we(0);function Ts(e){const t=le(e);return!tr()||!t.visualViewport?mf:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function hf(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==le(e)?!1:t}function Fe(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),s=nr(e);let a=we(1);t&&(r?ge(r)&&(a=Ye(r)):a=Ye(e));const c=hf(s,n,r)?Ts(s):we(0);let l=(o.left+c.x)/a.x,u=(o.top+c.y)/a.y,f=o.width/a.x,d=o.height/a.y;if(s){const h=le(s),g=r&&ge(r)?le(r):r;let v=h,m=On(v);for(;m&&r&&g!==v;){const y=Ye(m),x=m.getBoundingClientRect(),b=ve(m),w=x.left+(m.clientLeft+parseFloat(b.paddingLeft))*y.x,C=x.top+(m.clientTop+parseFloat(b.paddingTop))*y.y;l*=y.x,u*=y.y,f*=y.x,d*=y.y,l+=w,u+=C,v=le(m),m=On(v)}}return Lt({width:f,height:d,x:l,y:u})}function Zt(e,t){const n=qt(e).scrollLeft;return t?t.left+n:Fe(Ce(e)).left+n}function Ms(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-Zt(e,n),o=n.top+t.scrollTop;return{x:r,y:o}}function gf(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const s=o==="fixed",a=Ce(r),c=t?Xt(t.floating):!1;if(r===a||c&&s)return n;let l={scrollLeft:0,scrollTop:0},u=we(1);const f=we(0),d=Se(r);if((d||!d&&!s)&&((tt(r)!=="body"||mt(a))&&(l=qt(r)),Se(r))){const g=Fe(r);u=Ye(r),f.x=g.x+r.clientLeft,f.y=g.y+r.clientTop}const h=a&&!d&&!s?Ms(a,l):we(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-l.scrollLeft*u.x+f.x+h.x,y:n.y*u.y-l.scrollTop*u.y+f.y+h.y}}function vf(e){return Array.from(e.getClientRects())}function yf(e){const t=Ce(e),n=qt(e),r=e.ownerDocument.body,o=ce(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=ce(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+Zt(e);const c=-n.scrollTop;return ve(r).direction==="rtl"&&(a+=ce(t.clientWidth,r.clientWidth)-o),{width:o,height:s,x:a,y:c}}const eo=25;function xf(e,t){const n=le(e),r=Ce(e),o=n.visualViewport;let s=r.clientWidth,a=r.clientHeight,c=0,l=0;if(o){s=o.width,a=o.height;const f=tr();(!f||f&&t==="fixed")&&(c=o.offsetLeft,l=o.offsetTop)}const u=Zt(r);if(u<=0){const f=r.ownerDocument,d=f.body,h=getComputedStyle(d),g=f.compatMode==="CSS1Compat"&&parseFloat(h.marginLeft)+parseFloat(h.marginRight)||0,v=Math.abs(r.clientWidth-d.clientWidth-g);v<=eo&&(s-=v)}else u<=eo&&(s+=u);return{width:s,height:a,x:c,y:l}}const bf=new Set(["absolute","fixed"]);function wf(e,t){const n=Fe(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,s=Se(e)?Ye(e):we(1),a=e.clientWidth*s.x,c=e.clientHeight*s.y,l=o*s.x,u=r*s.y;return{width:a,height:c,x:l,y:u}}function to(e,t,n){let r;if(t==="viewport")r=xf(e,n);else if(t==="document")r=yf(Ce(e));else if(ge(t))r=wf(t,n);else{const o=Ts(e);r={x:t.x-o.x,y:t.y-o.y,width:t.width,height:t.height}}return Lt(r)}function ks(e,t){const n=Me(e);return n===t||!ge(n)||qe(n)?!1:ve(n).position==="fixed"||ks(n,t)}function Sf(e,t){const n=t.get(e);if(n)return n;let r=lt(e,[],!1).filter(c=>ge(c)&&tt(c)!=="body"),o=null;const s=ve(e).position==="fixed";let a=s?Me(e):e;for(;ge(a)&&!qe(a);){const c=ve(a),l=er(a);!l&&c.position==="fixed"&&(o=null),(s?!l&&!o:!l&&c.position==="static"&&!!o&&bf.has(o.position)||mt(a)&&!l&&ks(e,a))?r=r.filter(f=>f!==a):o=c,a=Me(a)}return t.set(e,r),r}function Cf(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const a=[...n==="clippingAncestors"?Xt(t)?[]:Sf(t,this._c):[].concat(n),r],c=a[0],l=a.reduce((u,f)=>{const d=to(t,f,o);return u.top=ce(d.top,u.top),u.right=Te(d.right,u.right),u.bottom=Te(d.bottom,u.bottom),u.left=ce(d.left,u.left),u},to(t,c,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function Ef(e){const{width:t,height:n}=Is(e);return{width:t,height:n}}function Rf(e,t,n){const r=Se(t),o=Ce(t),s=n==="fixed",a=Fe(e,!0,s,t);let c={scrollLeft:0,scrollTop:0};const l=we(0);function u(){l.x=Zt(o)}if(r||!r&&!s)if((tt(t)!=="body"||mt(o))&&(c=qt(t)),r){const g=Fe(t,!0,s,t);l.x=g.x+t.clientLeft,l.y=g.y+t.clientTop}else o&&u();s&&!r&&o&&u();const f=o&&!r&&!s?Ms(o,c):we(0),d=a.left+c.scrollLeft-l.x-f.x,h=a.top+c.scrollTop-l.y-f.y;return{x:d,y:h,width:a.width,height:a.height}}function xn(e){return ve(e).position==="static"}function no(e,t){if(!Se(e)||ve(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Ce(e)===n&&(n=n.ownerDocument.body),n}function Ds(e,t){const n=le(e);if(Xt(e))return n;if(!Se(e)){let o=Me(e);for(;o&&!qe(o);){if(ge(o)&&!xn(o))return o;o=Me(o)}return n}let r=no(e,t);for(;r&&af(r)&&xn(r);)r=no(r,t);return r&&qe(r)&&xn(r)&&!er(r)?n:r||ff(e)||n}const Pf=async function(e){const t=this.getOffsetParent||Ds,n=this.getDimensions,r=await n(e.floating);return{reference:Rf(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function _f(e){return ve(e).direction==="rtl"}const Nf={convertOffsetParentRelativeRectToViewportRelativeRect:gf,getDocumentElement:Ce,getClippingRect:Cf,getOffsetParent:Ds,getElementRects:Pf,getClientRects:vf,getDimensions:Ef,getScale:Ye,isElement:ge,isRTL:_f};function js(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Af(e,t){let n=null,r;const o=Ce(e);function s(){var c;clearTimeout(r),(c=n)==null||c.disconnect(),n=null}function a(c,l){c===void 0&&(c=!1),l===void 0&&(l=1),s();const u=e.getBoundingClientRect(),{left:f,top:d,width:h,height:g}=u;if(c||t(),!h||!g)return;const v=Pt(d),m=Pt(o.clientWidth-(f+h)),y=Pt(o.clientHeight-(d+g)),x=Pt(f),w={rootMargin:-v+"px "+-m+"px "+-y+"px "+-x+"px",threshold:ce(0,Te(1,l))||1};let C=!0;function _(O){const N=O[0].intersectionRatio;if(N!==l){if(!C)return a();N?a(!1,N):r=setTimeout(()=>{a(!1,1e-7)},1e3)}N===1&&!js(u,e.getBoundingClientRect())&&a(),C=!1}try{n=new IntersectionObserver(_,{...w,root:o.ownerDocument})}catch{n=new IntersectionObserver(_,w)}n.observe(e)}return a(!0),s}function Of(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:s=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,u=nr(e),f=o||s?[...u?lt(u):[],...lt(t)]:[];f.forEach(x=>{o&&x.addEventListener("scroll",n,{passive:!0}),s&&x.addEventListener("resize",n)});const d=u&&c?Af(u,n):null;let h=-1,g=null;a&&(g=new ResizeObserver(x=>{let[b]=x;b&&b.target===u&&g&&(g.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var w;(w=g)==null||w.observe(t)})),n()}),u&&!l&&g.observe(u),g.observe(t));let v,m=l?Fe(e):null;l&&y();function y(){const x=Fe(e);m&&!js(m,x)&&n(),m=x,v=requestAnimationFrame(y)}return n(),()=>{var x;f.forEach(b=>{o&&b.removeEventListener("scroll",n),s&&b.removeEventListener("resize",n)}),d?.(),(x=g)==null||x.disconnect(),g=null,l&&cancelAnimationFrame(v)}}const If=ef,Tf=tf,Mf=Zd,kf=rf,Df=Jd,ro=qd,jf=nf,$f=(e,t,n)=>{const r=new Map,o={platform:Nf,...n},s={...o.platform,_c:r};return Xd(e,t,{...o,platform:s})};var Lf=typeof document<"u",Ff=function(){},It=Lf?se.useLayoutEffect:Ff;function Ft(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,o;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(!Ft(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const s=o[r];if(!(s==="_owner"&&e.$$typeof)&&!Ft(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function $s(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function oo(e,t){const n=$s(e);return Math.round(t*n)/n}function bn(e){const t=i.useRef(e);return It(()=>{t.current=e}),t}function Vf(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:s,floating:a}={},transform:c=!0,whileElementsMounted:l,open:u}=e,[f,d]=i.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[h,g]=i.useState(r);Ft(h,r)||g(r);const[v,m]=i.useState(null),[y,x]=i.useState(null),b=i.useCallback(E=>{E!==O.current&&(O.current=E,m(E))},[]),w=i.useCallback(E=>{E!==N.current&&(N.current=E,x(E))},[]),C=s||v,_=a||y,O=i.useRef(null),N=i.useRef(null),P=i.useRef(f),j=l!=null,F=bn(l),z=bn(o),V=bn(u),U=i.useCallback(()=>{if(!O.current||!N.current)return;const E={placement:t,strategy:n,middleware:h};z.current&&(E.platform=z.current),$f(O.current,N.current,E).then(A=>{const J={...A,isPositioned:V.current!==!1};H.current&&!Ft(P.current,J)&&(P.current=J,ft.flushSync(()=>{d(J)}))})},[h,t,n,z,V]);It(()=>{u===!1&&P.current.isPositioned&&(P.current.isPositioned=!1,d(E=>({...E,isPositioned:!1})))},[u]);const H=i.useRef(!1);It(()=>(H.current=!0,()=>{H.current=!1}),[]),It(()=>{if(C&&(O.current=C),_&&(N.current=_),C&&_){if(F.current)return F.current(C,_,U);U()}},[C,_,U,F,j]);const K=i.useMemo(()=>({reference:O,floating:N,setReference:b,setFloating:w}),[b,w]),k=i.useMemo(()=>({reference:C,floating:_}),[C,_]),W=i.useMemo(()=>{const E={position:n,left:0,top:0};if(!k.floating)return E;const A=oo(k.floating,f.x),J=oo(k.floating,f.y);return c?{...E,transform:"translate("+A+"px, "+J+"px)",...$s(k.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:A,top:J}},[n,c,k.floating,f.x,f.y]);return i.useMemo(()=>({...f,update:U,refs:K,elements:k,floatingStyles:W}),[f,U,K,k,W])}const Wf=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?ro({element:r.current,padding:o}).fn(n):{}:r?ro({element:r,padding:o}).fn(n):{}}}},Bf=(e,t)=>({...If(e),options:[e,t]}),Hf=(e,t)=>({...Tf(e),options:[e,t]}),zf=(e,t)=>({...jf(e),options:[e,t]}),Uf=(e,t)=>({...Mf(e),options:[e,t]}),Gf=(e,t)=>({...kf(e),options:[e,t]}),Kf=(e,t)=>({...Df(e),options:[e,t]}),Yf=(e,t)=>({...Wf(e),options:[e,t]});function Xf(e){const t=qf(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(Jf);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function qf(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=ep(o),c=Qf(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Zf=Symbol("radix.slottable");function Jf(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Zf}function Qf(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function ep(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var tp=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],np=tp.reduce((e,t)=>{const n=Xf(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),rp="Arrow",Ls=i.forwardRef((e,t)=>{const{children:n,width:r=10,height:o=5,...s}=e;return p.jsx(np.svg,{...s,ref:t,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:p.jsx("polygon",{points:"0,0 30,0 15,10"})})});Ls.displayName=rp;var op=Ls;function sp(e,t=[]){let n=[];function r(s,a){const c=i.createContext(a),l=n.length;n=[...n,a];const u=d=>{const{scope:h,children:g,...v}=d,m=h?.[e]?.[l]||c,y=i.useMemo(()=>v,Object.values(v));return p.jsx(m.Provider,{value:y,children:g})};u.displayName=s+"Provider";function f(d,h){const g=h?.[e]?.[l]||c,v=i.useContext(g);if(v)return v;if(a!==void 0)return a;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[u,f]}const o=()=>{const s=n.map(a=>i.createContext(a));return function(c){const l=c?.[e]||s;return i.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return o.scopeName=e,[r,ip(o,...t)]}function ip(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const a=r.reduce((c,{useScope:l,scopeName:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return i.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function ap(e){const t=cp(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(up);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function cp(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=fp(o),c=dp(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var lp=Symbol("radix.slottable");function up(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===lp}function dp(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function fp(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var pp=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Fs=pp.reduce((e,t)=>{const n=ap(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),rr="Popper",[Vs,Jt]=sp(rr),[mp,Ws]=Vs(rr),Bs=e=>{const{__scopePopper:t,children:n}=e,[r,o]=i.useState(null);return p.jsx(mp,{scope:t,anchor:r,onAnchorChange:o,children:n})};Bs.displayName=rr;var Hs="PopperAnchor",zs=i.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,s=Ws(Hs,n),a=i.useRef(null),c=q(t,a),l=i.useRef(null);return i.useEffect(()=>{const u=l.current;l.current=r?.current||a.current,u!==l.current&&s.onAnchorChange(l.current)}),r?null:p.jsx(Fs.div,{...o,ref:c})});zs.displayName=Hs;var or="PopperContent",[hp,gp]=Vs(or),Us=i.forwardRef((e,t)=>{const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:s="center",alignOffset:a=0,arrowPadding:c=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:f=0,sticky:d="partial",hideWhenDetached:h=!1,updatePositionStrategy:g="optimized",onPlaced:v,...m}=e,y=Ws(or,n),[x,b]=i.useState(null),w=q(t,R=>b(R)),[C,_]=i.useState(null),O=Hn(C),N=O?.width??0,P=O?.height??0,j=r+(s!=="center"?"-"+s:""),F=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},z=Array.isArray(u)?u:[u],V=z.length>0,U={padding:F,boundary:z.filter(yp),altBoundary:V},{refs:H,floatingStyles:K,placement:k,isPositioned:W,middlewareData:E}=Vf({strategy:"fixed",placement:j,whileElementsMounted:(...R)=>Of(...R,{animationFrame:g==="always"}),elements:{reference:y.anchor},middleware:[Bf({mainAxis:o+P,alignmentAxis:a}),l&&Hf({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?zf():void 0,...U}),l&&Uf({...U}),Gf({...U,apply:({elements:R,rects:Y,availableWidth:ee,availableHeight:X})=>{const{width:Z,height:Q}=Y.reference,de=R.floating.style;de.setProperty("--radix-popper-available-width",`${ee}px`),de.setProperty("--radix-popper-available-height",`${X}px`),de.setProperty("--radix-popper-anchor-width",`${Z}px`),de.setProperty("--radix-popper-anchor-height",`${Q}px`)}}),C&&Yf({element:C,padding:c}),xp({arrowWidth:N,arrowHeight:P}),h&&Kf({strategy:"referenceHidden",...U})]}),[A,J]=Ys(k),S=pe(v);oe(()=>{W&&S?.()},[W,S]);const D=E.arrow?.x,$=E.arrow?.y,L=E.arrow?.centerOffset!==0,[ne,te]=i.useState();return oe(()=>{x&&te(window.getComputedStyle(x).zIndex)},[x]),p.jsx("div",{ref:H.setFloating,"data-radix-popper-content-wrapper":"",style:{...K,transform:W?K.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:ne,"--radix-popper-transform-origin":[E.transformOrigin?.x,E.transformOrigin?.y].join(" "),...E.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:p.jsx(hp,{scope:n,placedSide:A,onArrowChange:_,arrowX:D,arrowY:$,shouldHideArrow:L,children:p.jsx(Fs.div,{"data-side":A,"data-align":J,...m,ref:w,style:{...m.style,animation:W?void 0:"none"}})})})});Us.displayName=or;var Gs="PopperArrow",vp={top:"bottom",right:"left",bottom:"top",left:"right"},Ks=i.forwardRef(function(t,n){const{__scopePopper:r,...o}=t,s=gp(Gs,r),a=vp[s.placedSide];return p.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[a]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:p.jsx(op,{...o,ref:n,style:{...o.style,display:"block"}})})});Ks.displayName=Gs;function yp(e){return e!==null}var xp=e=>({name:"transformOrigin",options:e,fn(t){const{placement:n,rects:r,middlewareData:o}=t,a=o.arrow?.centerOffset!==0,c=a?0:e.arrowWidth,l=a?0:e.arrowHeight,[u,f]=Ys(n),d={start:"0%",center:"50%",end:"100%"}[f],h=(o.arrow?.x??0)+c/2,g=(o.arrow?.y??0)+l/2;let v="",m="";return u==="bottom"?(v=a?d:`${h}px`,m=`${-l}px`):u==="top"?(v=a?d:`${h}px`,m=`${r.floating.height+l}px`):u==="right"?(v=`${-l}px`,m=a?d:`${g}px`):u==="left"&&(v=`${r.floating.width+l}px`,m=a?d:`${g}px`),{data:{x:v,y:m}}}});function Ys(e){const[t,n="center"]=e.split("-");return[t,n]}var sr=Bs,Xs=zs,qs=Us,Zs=Ks;function bp(e){const t=wp(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(Cp);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function wp(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=Rp(o),c=Ep(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Sp=Symbol("radix.slottable");function Cp(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Sp}function Ep(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Rp(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Pp=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],_p=Pp.reduce((e,t)=>{const n=bp(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),Np="Portal",Qt=i.forwardRef((e,t)=>{const{container:n,...r}=e,[o,s]=i.useState(!1);oe(()=>s(!0),[]);const a=n||o&&globalThis?.document?.body;return a?fo.createPortal(p.jsx(_p.div,{...r,ref:t}),a):null});Qt.displayName=Np;function Js(e){const t=Ap(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(Ip);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function Ap(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=Mp(o),c=Tp(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Op=Symbol("radix.slottable");function Ip(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Op}function Tp(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Mp(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var kp=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],ue=kp.reduce((e,t)=>{const n=Js(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Dp(e){const t=jp(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(Lp);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function jp(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=Vp(o),c=Fp(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var $p=Symbol("radix.slottable");function Lp(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===$p}function Fp(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Vp(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Wp=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Bp=Wp.reduce((e,t)=>{const n=Dp(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),Qs=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"}),Hp="VisuallyHidden",zp=i.forwardRef((e,t)=>p.jsx(Bp.span,{...e,ref:t,style:{...Qs,...e.style}}));zp.displayName=Hp;var Up=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Ue=new WeakMap,_t=new WeakMap,Nt={},wn=0,ei=function(e){return e&&(e.host||ei(e.parentNode))},Gp=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=ei(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},Kp=function(e,t,n,r){var o=Gp(t,Array.isArray(e)?e:[e]);Nt[n]||(Nt[n]=new WeakMap);var s=Nt[n],a=[],c=new Set,l=new Set(o),u=function(d){!d||c.has(d)||(c.add(d),u(d.parentNode))};o.forEach(u);var f=function(d){!d||l.has(d)||Array.prototype.forEach.call(d.children,function(h){if(c.has(h))f(h);else try{var g=h.getAttribute(r),v=g!==null&&g!=="false",m=(Ue.get(h)||0)+1,y=(s.get(h)||0)+1;Ue.set(h,m),s.set(h,y),a.push(h),m===1&&v&&_t.set(h,!0),y===1&&h.setAttribute(n,"true"),v||h.setAttribute(r,"true")}catch(x){console.error("aria-hidden: cannot operate on ",h,x)}})};return f(t),c.clear(),wn++,function(){a.forEach(function(d){var h=Ue.get(d)-1,g=s.get(d)-1;Ue.set(d,h),s.set(d,g),h||(_t.has(d)||d.removeAttribute(r),_t.delete(d)),g||d.removeAttribute(n)}),wn--,wn||(Ue=new WeakMap,Ue=new WeakMap,_t=new WeakMap,Nt={})}},ir=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=Up(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live], script"))),Kp(r,o,n,"aria-hidden")):function(){return null}},xe=function(){return xe=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},xe.apply(this,arguments)};function ti(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 o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function Yp(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,s;r<o;r++)(s||!(r in t))&&(s||(s=Array.prototype.slice.call(t,0,r)),s[r]=t[r]);return e.concat(s||Array.prototype.slice.call(t))}var Tt="right-scroll-bar-position",Mt="width-before-scroll-bar",Xp="with-scroll-bars-hidden",qp="--removed-body-scroll-bar-size";function Sn(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Zp(e,t){var n=se.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}var Jp=typeof window<"u"?i.useLayoutEffect:i.useEffect,so=new WeakMap;function Qp(e,t){var n=Zp(null,function(r){return e.forEach(function(o){return Sn(o,r)})});return Jp(function(){var r=so.get(n);if(r){var o=new Set(r),s=new Set(e),a=n.current;o.forEach(function(c){s.has(c)||Sn(c,null)}),s.forEach(function(c){o.has(c)||Sn(c,a)})}so.set(n,e)},[e]),n}function em(e){return e}function tm(e,t){t===void 0&&(t=em);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(s){var a=t(s,r);return n.push(a),function(){n=n.filter(function(c){return c!==a})}},assignSyncMedium:function(s){for(r=!0;n.length;){var a=n;n=[],a.forEach(s)}n={push:function(c){return s(c)},filter:function(){return n}}},assignMedium:function(s){r=!0;var a=[];if(n.length){var c=n;n=[],c.forEach(s),a=n}var l=function(){var f=a;a=[],f.forEach(s)},u=function(){return Promise.resolve().then(l)};u(),n={push:function(f){a.push(f),u()},filter:function(f){return a=a.filter(f),n}}}};return o}function nm(e){e===void 0&&(e={});var t=tm(null);return t.options=xe({async:!0,ssr:!1},e),t}var ni=function(e){var t=e.sideCar,n=ti(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return i.createElement(r,xe({},n))};ni.isSideCarExport=!0;function rm(e,t){return e.useMedium(t),ni}var ri=nm(),Cn=function(){},en=i.forwardRef(function(e,t){var n=i.useRef(null),r=i.useState({onScrollCapture:Cn,onWheelCapture:Cn,onTouchMoveCapture:Cn}),o=r[0],s=r[1],a=e.forwardProps,c=e.children,l=e.className,u=e.removeScrollBar,f=e.enabled,d=e.shards,h=e.sideCar,g=e.noRelative,v=e.noIsolation,m=e.inert,y=e.allowPinchZoom,x=e.as,b=x===void 0?"div":x,w=e.gapMode,C=ti(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),_=h,O=Qp([n,t]),N=xe(xe({},C),o);return i.createElement(i.Fragment,null,f&&i.createElement(_,{sideCar:ri,removeScrollBar:u,shards:d,noRelative:g,noIsolation:v,inert:m,setCallbacks:s,allowPinchZoom:!!y,lockRef:n,gapMode:w}),a?i.cloneElement(i.Children.only(c),xe(xe({},N),{ref:O})):i.createElement(b,xe({},N,{className:l,ref:O}),c))});en.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};en.classNames={fullWidth:Mt,zeroRight:Tt};var om=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function sm(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=om();return t&&e.setAttribute("nonce",t),e}function im(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function am(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var cm=function(){var e=0,t=null;return{add:function(n){e==0&&(t=sm())&&(im(t,n),am(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},lm=function(){var e=cm();return function(t,n){i.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},oi=function(){var e=lm(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},um={left:0,top:0,right:0,gap:0},En=function(e){return parseInt(e||"",10)||0},dm=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[En(n),En(r),En(o)]},fm=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return um;var t=dm(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])}},pm=oi(),Xe="data-scroll-locked",mm=function(e,t,n,r){var o=e.left,s=e.top,a=e.right,c=e.gap;return n===void 0&&(n="margin"),`
|
|
7
|
+
.`.concat(Xp,` {
|
|
8
|
+
overflow: hidden `).concat(r,`;
|
|
9
|
+
padding-right: `).concat(c,"px ").concat(r,`;
|
|
10
|
+
}
|
|
11
|
+
body[`).concat(Xe,`] {
|
|
12
|
+
overflow: hidden `).concat(r,`;
|
|
13
|
+
overscroll-behavior: contain;
|
|
14
|
+
`).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
|
|
15
|
+
padding-left: `.concat(o,`px;
|
|
16
|
+
padding-top: `).concat(s,`px;
|
|
17
|
+
padding-right: `).concat(a,`px;
|
|
18
|
+
margin-left:0;
|
|
19
|
+
margin-top:0;
|
|
20
|
+
margin-right: `).concat(c,"px ").concat(r,`;
|
|
21
|
+
`),n==="padding"&&"padding-right: ".concat(c,"px ").concat(r,";")].filter(Boolean).join(""),`
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.`).concat(Tt,` {
|
|
25
|
+
right: `).concat(c,"px ").concat(r,`;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.`).concat(Mt,` {
|
|
29
|
+
margin-right: `).concat(c,"px ").concat(r,`;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.`).concat(Tt," .").concat(Tt,` {
|
|
33
|
+
right: 0 `).concat(r,`;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.`).concat(Mt," .").concat(Mt,` {
|
|
37
|
+
margin-right: 0 `).concat(r,`;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
body[`).concat(Xe,`] {
|
|
41
|
+
`).concat(qp,": ").concat(c,`px;
|
|
42
|
+
}
|
|
43
|
+
`)},io=function(){var e=parseInt(document.body.getAttribute(Xe)||"0",10);return isFinite(e)?e:0},hm=function(){i.useEffect(function(){return document.body.setAttribute(Xe,(io()+1).toString()),function(){var e=io()-1;e<=0?document.body.removeAttribute(Xe):document.body.setAttribute(Xe,e.toString())}},[])},gm=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r;hm();var s=i.useMemo(function(){return fm(o)},[o]);return i.createElement(pm,{styles:mm(s,!t,o,n?"":"!important")})},In=!1;if(typeof window<"u")try{var At=Object.defineProperty({},"passive",{get:function(){return In=!0,!0}});window.addEventListener("test",At,At),window.removeEventListener("test",At,At)}catch{In=!1}var Ge=In?{passive:!1}:!1,vm=function(e){return e.tagName==="TEXTAREA"},si=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!vm(e)&&n[t]==="visible")},ym=function(e){return si(e,"overflowY")},xm=function(e){return si(e,"overflowX")},ao=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var o=ii(e,r);if(o){var s=ai(e,r),a=s[1],c=s[2];if(a>c)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},bm=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},wm=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},ii=function(e,t){return e==="v"?ym(t):xm(t)},ai=function(e,t){return e==="v"?bm(t):wm(t)},Sm=function(e,t){return e==="h"&&t==="rtl"?-1:1},Cm=function(e,t,n,r,o){var s=Sm(e,window.getComputedStyle(t).direction),a=s*r,c=n.target,l=t.contains(c),u=!1,f=a>0,d=0,h=0;do{if(!c)break;var g=ai(e,c),v=g[0],m=g[1],y=g[2],x=m-y-s*v;(v||x)&&ii(e,c)&&(d+=x,h+=v);var b=c.parentNode;c=b&&b.nodeType===Node.DOCUMENT_FRAGMENT_NODE?b.host:b}while(!l&&c!==document.body||l&&(t.contains(c)||t===c));return(f&&Math.abs(d)<1||!f&&Math.abs(h)<1)&&(u=!0),u},Ot=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},co=function(e){return[e.deltaX,e.deltaY]},lo=function(e){return e&&"current"in e?e.current:e},Em=function(e,t){return e[0]===t[0]&&e[1]===t[1]},Rm=function(e){return`
|
|
44
|
+
.block-interactivity-`.concat(e,` {pointer-events: none;}
|
|
45
|
+
.allow-interactivity-`).concat(e,` {pointer-events: all;}
|
|
46
|
+
`)},Pm=0,Ke=[];function _m(e){var t=i.useRef([]),n=i.useRef([0,0]),r=i.useRef(),o=i.useState(Pm++)[0],s=i.useState(oi)[0],a=i.useRef(e);i.useEffect(function(){a.current=e},[e]),i.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var m=Yp([e.lockRef.current],(e.shards||[]).map(lo),!0).filter(Boolean);return m.forEach(function(y){return y.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),m.forEach(function(y){return y.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var c=i.useCallback(function(m,y){if("touches"in m&&m.touches.length===2||m.type==="wheel"&&m.ctrlKey)return!a.current.allowPinchZoom;var x=Ot(m),b=n.current,w="deltaX"in m?m.deltaX:b[0]-x[0],C="deltaY"in m?m.deltaY:b[1]-x[1],_,O=m.target,N=Math.abs(w)>Math.abs(C)?"h":"v";if("touches"in m&&N==="h"&&O.type==="range")return!1;var P=window.getSelection(),j=P&&P.anchorNode,F=j?j===O||j.contains(O):!1;if(F)return!1;var z=ao(N,O);if(!z)return!0;if(z?_=N:(_=N==="v"?"h":"v",z=ao(N,O)),!z)return!1;if(!r.current&&"changedTouches"in m&&(w||C)&&(r.current=_),!_)return!0;var V=r.current||_;return Cm(V,y,m,V==="h"?w:C)},[]),l=i.useCallback(function(m){var y=m;if(!(!Ke.length||Ke[Ke.length-1]!==s)){var x="deltaY"in y?co(y):Ot(y),b=t.current.filter(function(_){return _.name===y.type&&(_.target===y.target||y.target===_.shadowParent)&&Em(_.delta,x)})[0];if(b&&b.should){y.cancelable&&y.preventDefault();return}if(!b){var w=(a.current.shards||[]).map(lo).filter(Boolean).filter(function(_){return _.contains(y.target)}),C=w.length>0?c(y,w[0]):!a.current.noIsolation;C&&y.cancelable&&y.preventDefault()}}},[]),u=i.useCallback(function(m,y,x,b){var w={name:m,delta:y,target:x,should:b,shadowParent:Nm(x)};t.current.push(w),setTimeout(function(){t.current=t.current.filter(function(C){return C!==w})},1)},[]),f=i.useCallback(function(m){n.current=Ot(m),r.current=void 0},[]),d=i.useCallback(function(m){u(m.type,co(m),m.target,c(m,e.lockRef.current))},[]),h=i.useCallback(function(m){u(m.type,Ot(m),m.target,c(m,e.lockRef.current))},[]);i.useEffect(function(){return Ke.push(s),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:h}),document.addEventListener("wheel",l,Ge),document.addEventListener("touchmove",l,Ge),document.addEventListener("touchstart",f,Ge),function(){Ke=Ke.filter(function(m){return m!==s}),document.removeEventListener("wheel",l,Ge),document.removeEventListener("touchmove",l,Ge),document.removeEventListener("touchstart",f,Ge)}},[]);var g=e.removeScrollBar,v=e.inert;return i.createElement(i.Fragment,null,v?i.createElement(s,{styles:Rm(o)}):null,g?i.createElement(gm,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function Nm(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const Am=rm(ri,_m);var tn=i.forwardRef(function(e,t){return i.createElement(en,xe({},e,{ref:t,sideCar:Am}))});tn.classNames=en.classNames;var Om=[" ","Enter","ArrowUp","ArrowDown"],Im=[" ","Enter"],Ve="Select",[nn,rn,Tm]=Yn(Ve),[nt]=nd(Ve,[Tm,Jt]),on=Jt(),[Mm,ke]=nt(Ve),[km,Dm]=nt(Ve),ci=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:o,onOpenChange:s,value:a,defaultValue:c,onValueChange:l,dir:u,name:f,autoComplete:d,disabled:h,required:g,form:v}=e,m=on(t),[y,x]=i.useState(null),[b,w]=i.useState(null),[C,_]=i.useState(!1),O=Xn(u),[N,P]=Ie({prop:r,defaultProp:o??!1,onChange:s,caller:Ve}),[j,F]=Ie({prop:a,defaultProp:c,onChange:l,caller:Ve}),z=i.useRef(null),V=y?v||!!y.closest("form"):!0,[U,H]=i.useState(new Set),K=Array.from(U).map(k=>k.props.value).join(";");return p.jsx(sr,{...m,children:p.jsxs(Mm,{required:g,scope:t,trigger:y,onTriggerChange:x,valueNode:b,onValueNodeChange:w,valueNodeHasChildren:C,onValueNodeHasChildrenChange:_,contentId:he(),value:j,onValueChange:F,open:N,onOpenChange:P,dir:O,triggerPointerDownPosRef:z,disabled:h,children:[p.jsx(nn.Provider,{scope:t,children:p.jsx(km,{scope:e.__scopeSelect,onNativeOptionAdd:i.useCallback(k=>{H(W=>new Set(W).add(k))},[]),onNativeOptionRemove:i.useCallback(k=>{H(W=>{const E=new Set(W);return E.delete(k),E})},[]),children:n})}),V?p.jsxs(Mi,{"aria-hidden":!0,required:g,tabIndex:-1,name:f,autoComplete:d,value:j,onChange:k=>F(k.target.value),disabled:h,form:v,children:[j===void 0?p.jsx("option",{value:""}):null,Array.from(U)]},K):null]})})};ci.displayName=Ve;var li="SelectTrigger",ui=i.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...o}=e,s=on(n),a=ke(li,n),c=a.disabled||r,l=q(t,a.onTriggerChange),u=rn(n),f=i.useRef("touch"),[d,h,g]=Di(m=>{const y=u().filter(w=>!w.disabled),x=y.find(w=>w.value===a.value),b=ji(y,m,x);b!==void 0&&a.onValueChange(b.value)}),v=m=>{c||(a.onOpenChange(!0),g()),m&&(a.triggerPointerDownPosRef.current={x:Math.round(m.pageX),y:Math.round(m.pageY)})};return p.jsx(Xs,{asChild:!0,...s,children:p.jsx(ue.button,{type:"button",role:"combobox","aria-controls":a.contentId,"aria-expanded":a.open,"aria-required":a.required,"aria-autocomplete":"none",dir:a.dir,"data-state":a.open?"open":"closed",disabled:c,"data-disabled":c?"":void 0,"data-placeholder":ki(a.value)?"":void 0,...o,ref:l,onClick:M(o.onClick,m=>{m.currentTarget.focus(),f.current!=="mouse"&&v(m)}),onPointerDown:M(o.onPointerDown,m=>{f.current=m.pointerType;const y=m.target;y.hasPointerCapture(m.pointerId)&&y.releasePointerCapture(m.pointerId),m.button===0&&m.ctrlKey===!1&&m.pointerType==="mouse"&&(v(m),m.preventDefault())}),onKeyDown:M(o.onKeyDown,m=>{const y=d.current!=="";!(m.ctrlKey||m.altKey||m.metaKey)&&m.key.length===1&&h(m.key),!(y&&m.key===" ")&&Om.includes(m.key)&&(v(),m.preventDefault())})})})});ui.displayName=li;var di="SelectValue",fi=i.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,children:s,placeholder:a="",...c}=e,l=ke(di,n),{onValueNodeHasChildrenChange:u}=l,f=s!==void 0,d=q(t,l.onValueNodeChange);return oe(()=>{u(f)},[u,f]),p.jsx(ue.span,{...c,ref:d,style:{pointerEvents:"none"},children:ki(l.value)?p.jsx(p.Fragment,{children:a}):s})});fi.displayName=di;var jm="SelectIcon",pi=i.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...o}=e;return p.jsx(ue.span,{"aria-hidden":!0,...o,ref:t,children:r||"▼"})});pi.displayName=jm;var $m="SelectPortal",mi=e=>p.jsx(Qt,{asChild:!0,...e});mi.displayName=$m;var We="SelectContent",hi=i.forwardRef((e,t)=>{const n=ke(We,e.__scopeSelect),[r,o]=i.useState();if(oe(()=>{o(new DocumentFragment)},[]),!n.open){const s=r;return s?ft.createPortal(p.jsx(gi,{scope:e.__scopeSelect,children:p.jsx(nn.Slot,{scope:e.__scopeSelect,children:p.jsx("div",{children:e.children})})}),s):null}return p.jsx(vi,{...e,ref:t})});hi.displayName=We;var me=10,[gi,De]=nt(We),Lm="SelectContentImpl",Fm=Js("SelectContent.RemoveScroll"),vi=i.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:s,onPointerDownOutside:a,side:c,sideOffset:l,align:u,alignOffset:f,arrowPadding:d,collisionBoundary:h,collisionPadding:g,sticky:v,hideWhenDetached:m,avoidCollisions:y,...x}=e,b=ke(We,n),[w,C]=i.useState(null),[_,O]=i.useState(null),N=q(t,R=>C(R)),[P,j]=i.useState(null),[F,z]=i.useState(null),V=rn(n),[U,H]=i.useState(!1),K=i.useRef(!1);i.useEffect(()=>{if(w)return ir(w)},[w]),qn();const k=i.useCallback(R=>{const[Y,...ee]=V().map(Q=>Q.ref.current),[X]=ee.slice(-1),Z=document.activeElement;for(const Q of R)if(Q===Z||(Q?.scrollIntoView({block:"nearest"}),Q===Y&&_&&(_.scrollTop=0),Q===X&&_&&(_.scrollTop=_.scrollHeight),Q?.focus(),document.activeElement!==Z))return},[V,_]),W=i.useCallback(()=>k([P,w]),[k,P,w]);i.useEffect(()=>{U&&W()},[U,W]);const{onOpenChange:E,triggerPointerDownPosRef:A}=b;i.useEffect(()=>{if(w){let R={x:0,y:0};const Y=X=>{R={x:Math.abs(Math.round(X.pageX)-(A.current?.x??0)),y:Math.abs(Math.round(X.pageY)-(A.current?.y??0))}},ee=X=>{R.x<=10&&R.y<=10?X.preventDefault():w.contains(X.target)||E(!1),document.removeEventListener("pointermove",Y),A.current=null};return A.current!==null&&(document.addEventListener("pointermove",Y),document.addEventListener("pointerup",ee,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",Y),document.removeEventListener("pointerup",ee,{capture:!0})}}},[w,E,A]),i.useEffect(()=>{const R=()=>E(!1);return window.addEventListener("blur",R),window.addEventListener("resize",R),()=>{window.removeEventListener("blur",R),window.removeEventListener("resize",R)}},[E]);const[J,S]=Di(R=>{const Y=V().filter(Z=>!Z.disabled),ee=Y.find(Z=>Z.ref.current===document.activeElement),X=ji(Y,R,ee);X&&setTimeout(()=>X.ref.current.focus())}),D=i.useCallback((R,Y,ee)=>{const X=!K.current&&!ee;(b.value!==void 0&&b.value===Y||X)&&(j(R),X&&(K.current=!0))},[b.value]),$=i.useCallback(()=>w?.focus(),[w]),L=i.useCallback((R,Y,ee)=>{const X=!K.current&&!ee;(b.value!==void 0&&b.value===Y||X)&&z(R)},[b.value]),ne=r==="popper"?Tn:yi,te=ne===Tn?{side:c,sideOffset:l,align:u,alignOffset:f,arrowPadding:d,collisionBoundary:h,collisionPadding:g,sticky:v,hideWhenDetached:m,avoidCollisions:y}:{};return p.jsx(gi,{scope:n,content:w,viewport:_,onViewportChange:O,itemRefCallback:D,selectedItem:P,onItemLeave:$,itemTextRefCallback:L,focusSelectedItem:W,selectedItemText:F,position:r,isPositioned:U,searchRef:J,children:p.jsx(tn,{as:Fm,allowPinchZoom:!0,children:p.jsx(Kt,{asChild:!0,trapped:b.open,onMountAutoFocus:R=>{R.preventDefault()},onUnmountAutoFocus:M(o,R=>{b.trigger?.focus({preventScroll:!0}),R.preventDefault()}),children:p.jsx(Gt,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:s,onPointerDownOutside:a,onFocusOutside:R=>R.preventDefault(),onDismiss:()=>b.onOpenChange(!1),children:p.jsx(ne,{role:"listbox",id:b.contentId,"data-state":b.open?"open":"closed",dir:b.dir,onContextMenu:R=>R.preventDefault(),...x,...te,onPlaced:()=>H(!0),ref:N,style:{display:"flex",flexDirection:"column",outline:"none",...x.style},onKeyDown:M(x.onKeyDown,R=>{const Y=R.ctrlKey||R.altKey||R.metaKey;if(R.key==="Tab"&&R.preventDefault(),!Y&&R.key.length===1&&S(R.key),["ArrowUp","ArrowDown","Home","End"].includes(R.key)){let X=V().filter(Z=>!Z.disabled).map(Z=>Z.ref.current);if(["ArrowUp","End"].includes(R.key)&&(X=X.slice().reverse()),["ArrowUp","ArrowDown"].includes(R.key)){const Z=R.target,Q=X.indexOf(Z);X=X.slice(Q+1)}setTimeout(()=>k(X)),R.preventDefault()}})})})})})})});vi.displayName=Lm;var Vm="SelectItemAlignedPosition",yi=i.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...o}=e,s=ke(We,n),a=De(We,n),[c,l]=i.useState(null),[u,f]=i.useState(null),d=q(t,N=>f(N)),h=rn(n),g=i.useRef(!1),v=i.useRef(!0),{viewport:m,selectedItem:y,selectedItemText:x,focusSelectedItem:b}=a,w=i.useCallback(()=>{if(s.trigger&&s.valueNode&&c&&u&&m&&y&&x){const N=s.trigger.getBoundingClientRect(),P=u.getBoundingClientRect(),j=s.valueNode.getBoundingClientRect(),F=x.getBoundingClientRect();if(s.dir!=="rtl"){const Z=F.left-P.left,Q=j.left-Z,de=N.left-Q,$e=N.width+de,ln=Math.max($e,P.width),un=window.innerWidth-me,dn=Fr(Q,[me,Math.max(me,un-ln)]);c.style.minWidth=$e+"px",c.style.left=dn+"px"}else{const Z=P.right-F.right,Q=window.innerWidth-j.right-Z,de=window.innerWidth-N.right-Q,$e=N.width+de,ln=Math.max($e,P.width),un=window.innerWidth-me,dn=Fr(Q,[me,Math.max(me,un-ln)]);c.style.minWidth=$e+"px",c.style.right=dn+"px"}const z=h(),V=window.innerHeight-me*2,U=m.scrollHeight,H=window.getComputedStyle(u),K=parseInt(H.borderTopWidth,10),k=parseInt(H.paddingTop,10),W=parseInt(H.borderBottomWidth,10),E=parseInt(H.paddingBottom,10),A=K+k+U+E+W,J=Math.min(y.offsetHeight*5,A),S=window.getComputedStyle(m),D=parseInt(S.paddingTop,10),$=parseInt(S.paddingBottom,10),L=N.top+N.height/2-me,ne=V-L,te=y.offsetHeight/2,R=y.offsetTop+te,Y=K+k+R,ee=A-Y;if(Y<=L){const Z=z.length>0&&y===z[z.length-1].ref.current;c.style.bottom="0px";const Q=u.clientHeight-m.offsetTop-m.offsetHeight,de=Math.max(ne,te+(Z?$:0)+Q+W),$e=Y+de;c.style.height=$e+"px"}else{const Z=z.length>0&&y===z[0].ref.current;c.style.top="0px";const de=Math.max(L,K+m.offsetTop+(Z?D:0)+te)+ee;c.style.height=de+"px",m.scrollTop=Y-L+m.offsetTop}c.style.margin=`${me}px 0`,c.style.minHeight=J+"px",c.style.maxHeight=V+"px",r?.(),requestAnimationFrame(()=>g.current=!0)}},[h,s.trigger,s.valueNode,c,u,m,y,x,s.dir,r]);oe(()=>w(),[w]);const[C,_]=i.useState();oe(()=>{u&&_(window.getComputedStyle(u).zIndex)},[u]);const O=i.useCallback(N=>{N&&v.current===!0&&(w(),b?.(),v.current=!1)},[w,b]);return p.jsx(Bm,{scope:n,contentWrapper:c,shouldExpandOnScrollRef:g,onScrollButtonChange:O,children:p.jsx("div",{ref:l,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:C},children:p.jsx(ue.div,{...o,ref:d,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}})})})});yi.displayName=Vm;var Wm="SelectPopperPosition",Tn=i.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:o=me,...s}=e,a=on(n);return p.jsx(qs,{...a,...s,ref:t,align:r,collisionPadding:o,style:{boxSizing:"border-box",...s.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});Tn.displayName=Wm;var[Bm,ar]=nt(We,{}),Mn="SelectViewport",xi=i.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:r,...o}=e,s=De(Mn,n),a=ar(Mn,n),c=q(t,s.onViewportChange),l=i.useRef(0);return p.jsxs(p.Fragment,{children:[p.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:r}),p.jsx(nn.Slot,{scope:n,children:p.jsx(ue.div,{"data-radix-select-viewport":"",role:"presentation",...o,ref:c,style:{position:"relative",flex:1,overflow:"hidden auto",...o.style},onScroll:M(o.onScroll,u=>{const f=u.currentTarget,{contentWrapper:d,shouldExpandOnScrollRef:h}=a;if(h?.current&&d){const g=Math.abs(l.current-f.scrollTop);if(g>0){const v=window.innerHeight-me*2,m=parseFloat(d.style.minHeight),y=parseFloat(d.style.height),x=Math.max(m,y);if(x<v){const b=x+g,w=Math.min(v,b),C=b-w;d.style.height=w+"px",d.style.bottom==="0px"&&(f.scrollTop=C>0?C:0,d.style.justifyContent="flex-end")}}}l.current=f.scrollTop})})})]})});xi.displayName=Mn;var bi="SelectGroup",[Hm,zm]=nt(bi),wi=i.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=he();return p.jsx(Hm,{scope:n,id:o,children:p.jsx(ue.div,{role:"group","aria-labelledby":o,...r,ref:t})})});wi.displayName=bi;var Si="SelectLabel",Ci=i.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=zm(Si,n);return p.jsx(ue.div,{id:o.id,...r,ref:t})});Ci.displayName=Si;var Vt="SelectItem",[Um,Ei]=nt(Vt),Ri=i.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:o=!1,textValue:s,...a}=e,c=ke(Vt,n),l=De(Vt,n),u=c.value===r,[f,d]=i.useState(s??""),[h,g]=i.useState(!1),v=q(t,b=>l.itemRefCallback?.(b,r,o)),m=he(),y=i.useRef("touch"),x=()=>{o||(c.onValueChange(r),c.onOpenChange(!1))};if(r==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return p.jsx(Um,{scope:n,value:r,disabled:o,textId:m,isSelected:u,onItemTextChange:i.useCallback(b=>{d(w=>w||(b?.textContent??"").trim())},[]),children:p.jsx(nn.ItemSlot,{scope:n,value:r,disabled:o,textValue:f,children:p.jsx(ue.div,{role:"option","aria-labelledby":m,"data-highlighted":h?"":void 0,"aria-selected":u&&h,"data-state":u?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1,...a,ref:v,onFocus:M(a.onFocus,()=>g(!0)),onBlur:M(a.onBlur,()=>g(!1)),onClick:M(a.onClick,()=>{y.current!=="mouse"&&x()}),onPointerUp:M(a.onPointerUp,()=>{y.current==="mouse"&&x()}),onPointerDown:M(a.onPointerDown,b=>{y.current=b.pointerType}),onPointerMove:M(a.onPointerMove,b=>{y.current=b.pointerType,o?l.onItemLeave?.():y.current==="mouse"&&b.currentTarget.focus({preventScroll:!0})}),onPointerLeave:M(a.onPointerLeave,b=>{b.currentTarget===document.activeElement&&l.onItemLeave?.()}),onKeyDown:M(a.onKeyDown,b=>{l.searchRef?.current!==""&&b.key===" "||(Im.includes(b.key)&&x(),b.key===" "&&b.preventDefault())})})})})});Ri.displayName=Vt;var it="SelectItemText",Pi=i.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,...s}=e,a=ke(it,n),c=De(it,n),l=Ei(it,n),u=Dm(it,n),[f,d]=i.useState(null),h=q(t,x=>d(x),l.onItemTextChange,x=>c.itemTextRefCallback?.(x,l.value,l.disabled)),g=f?.textContent,v=i.useMemo(()=>p.jsx("option",{value:l.value,disabled:l.disabled,children:g},l.value),[l.disabled,l.value,g]),{onNativeOptionAdd:m,onNativeOptionRemove:y}=u;return oe(()=>(m(v),()=>y(v)),[m,y,v]),p.jsxs(p.Fragment,{children:[p.jsx(ue.span,{id:l.textId,...s,ref:h}),l.isSelected&&a.valueNode&&!a.valueNodeHasChildren?ft.createPortal(s.children,a.valueNode):null]})});Pi.displayName=it;var _i="SelectItemIndicator",Ni=i.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return Ei(_i,n).isSelected?p.jsx(ue.span,{"aria-hidden":!0,...r,ref:t}):null});Ni.displayName=_i;var kn="SelectScrollUpButton",Ai=i.forwardRef((e,t)=>{const n=De(kn,e.__scopeSelect),r=ar(kn,e.__scopeSelect),[o,s]=i.useState(!1),a=q(t,r.onScrollButtonChange);return oe(()=>{if(n.viewport&&n.isPositioned){let c=function(){const u=l.scrollTop>0;s(u)};const l=n.viewport;return c(),l.addEventListener("scroll",c),()=>l.removeEventListener("scroll",c)}},[n.viewport,n.isPositioned]),o?p.jsx(Ii,{...e,ref:a,onAutoScroll:()=>{const{viewport:c,selectedItem:l}=n;c&&l&&(c.scrollTop=c.scrollTop-l.offsetHeight)}}):null});Ai.displayName=kn;var Dn="SelectScrollDownButton",Oi=i.forwardRef((e,t)=>{const n=De(Dn,e.__scopeSelect),r=ar(Dn,e.__scopeSelect),[o,s]=i.useState(!1),a=q(t,r.onScrollButtonChange);return oe(()=>{if(n.viewport&&n.isPositioned){let c=function(){const u=l.scrollHeight-l.clientHeight,f=Math.ceil(l.scrollTop)<u;s(f)};const l=n.viewport;return c(),l.addEventListener("scroll",c),()=>l.removeEventListener("scroll",c)}},[n.viewport,n.isPositioned]),o?p.jsx(Ii,{...e,ref:a,onAutoScroll:()=>{const{viewport:c,selectedItem:l}=n;c&&l&&(c.scrollTop=c.scrollTop+l.offsetHeight)}}):null});Oi.displayName=Dn;var Ii=i.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...o}=e,s=De("SelectScrollButton",n),a=i.useRef(null),c=rn(n),l=i.useCallback(()=>{a.current!==null&&(window.clearInterval(a.current),a.current=null)},[]);return i.useEffect(()=>()=>l(),[l]),oe(()=>{c().find(f=>f.ref.current===document.activeElement)?.ref.current?.scrollIntoView({block:"nearest"})},[c]),p.jsx(ue.div,{"aria-hidden":!0,...o,ref:t,style:{flexShrink:0,...o.style},onPointerDown:M(o.onPointerDown,()=>{a.current===null&&(a.current=window.setInterval(r,50))}),onPointerMove:M(o.onPointerMove,()=>{s.onItemLeave?.(),a.current===null&&(a.current=window.setInterval(r,50))}),onPointerLeave:M(o.onPointerLeave,()=>{l()})})}),Gm="SelectSeparator",Ti=i.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return p.jsx(ue.div,{"aria-hidden":!0,...r,ref:t})});Ti.displayName=Gm;var jn="SelectArrow",Km=i.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=on(n),s=ke(jn,n),a=De(jn,n);return s.open&&a.position==="popper"?p.jsx(Zs,{...o,...r,ref:t}):null});Km.displayName=jn;var Ym="SelectBubbleInput",Mi=i.forwardRef(({__scopeSelect:e,value:t,...n},r)=>{const o=i.useRef(null),s=q(r,o),a=Bn(t);return i.useEffect(()=>{const c=o.current;if(!c)return;const l=window.HTMLSelectElement.prototype,f=Object.getOwnPropertyDescriptor(l,"value").set;if(a!==t&&f){const d=new Event("change",{bubbles:!0});f.call(c,t),c.dispatchEvent(d)}},[a,t]),p.jsx(ue.select,{...n,style:{...Qs,...n.style},ref:s,defaultValue:t})});Mi.displayName=Ym;function ki(e){return e===""||e===void 0}function Di(e){const t=pe(e),n=i.useRef(""),r=i.useRef(0),o=i.useCallback(a=>{const c=n.current+a;t(c),(function l(u){n.current=u,window.clearTimeout(r.current),u!==""&&(r.current=window.setTimeout(()=>l(""),1e3))})(c)},[t]),s=i.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return i.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,o,s]}function ji(e,t,n){const o=t.length>1&&Array.from(t).every(u=>u===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let a=Xm(e,Math.max(s,0));o.length===1&&(a=a.filter(u=>u!==n));const l=a.find(u=>u.textValue.toLowerCase().startsWith(o.toLowerCase()));return l!==n?l:void 0}function Xm(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var qm=ci,$i=ui,Zm=fi,Jm=pi,Qm=mi,Li=hi,eh=xi,th=wi,Fi=Ci,Vi=Ri,nh=Pi,rh=Ni,Wi=Ai,Bi=Oi,Hi=Ti;const oh=qm,sh=th,ih=Zm,zi=i.forwardRef(({className:e,children:t,...n},r)=>p.jsxs($i,{ref:r,className:B("flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",e),...n,children:[t,p.jsx(Jm,{asChild:!0,children:p.jsx(ps,{className:"h-4 w-4 opacity-50"})})]}));zi.displayName=$i.displayName;const cr=i.forwardRef(({className:e,...t},n)=>p.jsx(Wi,{ref:n,className:B("flex cursor-default items-center justify-center py-1",e),...t,children:p.jsx(Ou,{className:"h-4 w-4"})}));cr.displayName=Wi.displayName;const lr=i.forwardRef(({className:e,...t},n)=>p.jsx(Bi,{ref:n,className:B("flex cursor-default items-center justify-center py-1",e),...t,children:p.jsx(ps,{className:"h-4 w-4"})}));lr.displayName=Bi.displayName;const Ui=i.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>p.jsx(Qm,{children:p.jsxs(Li,{ref:o,className:B("relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 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",n==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:n,...r,children:[p.jsx(cr,{}),p.jsx(eh,{className:B("p-1",n==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t}),p.jsx(lr,{})]})}));Ui.displayName=Li.displayName;const Gi=i.forwardRef(({className:e,...t},n)=>p.jsx(Fi,{ref:n,className:B("py-1.5 pl-8 pr-2 text-sm font-semibold",e),...t}));Gi.displayName=Fi.displayName;const Ki=i.forwardRef(({className:e,children:t,...n},r)=>p.jsxs(Vi,{ref:r,className:B("relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[p.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:p.jsx(rh,{children:p.jsx(Kn,{className:"h-4 w-4"})})}),p.jsx(nh,{children:t})]}));Ki.displayName=Vi.displayName;const Yi=i.forwardRef(({className:e,...t},n)=>p.jsx(Hi,{ref:n,className:B("-mx-1 my-1 h-px bg-muted",e),...t}));Yi.displayName=Hi.displayName;function ah(e,t){const n=i.createContext(t),r=s=>{const{children:a,...c}=s,l=i.useMemo(()=>c,Object.values(c));return p.jsx(n.Provider,{value:l,children:a})};r.displayName=e+"Provider";function o(s){const a=i.useContext(n);if(a)return a;if(t!==void 0)return t;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[r,o]}function ch(e,t=[]){let n=[];function r(s,a){const c=i.createContext(a),l=n.length;n=[...n,a];const u=d=>{const{scope:h,children:g,...v}=d,m=h?.[e]?.[l]||c,y=i.useMemo(()=>v,Object.values(v));return p.jsx(m.Provider,{value:y,children:g})};u.displayName=s+"Provider";function f(d,h){const g=h?.[e]?.[l]||c,v=i.useContext(g);if(v)return v;if(a!==void 0)return a;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[u,f]}const o=()=>{const s=n.map(a=>i.createContext(a));return function(c){const l=c?.[e]||s;return i.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return o.scopeName=e,[r,lh(o,...t)]}function lh(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const a=r.reduce((c,{useScope:l,scopeName:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return i.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function Xi(e){const t=uh(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(fh);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function uh(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=mh(o),c=ph(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var dh=Symbol("radix.slottable");function fh(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===dh}function ph(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function mh(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var hh=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],ht=hh.reduce((e,t)=>{const n=Xi(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),sn="Dialog",[qi]=ch(sn),[gh,ye]=qi(sn),Zi=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:o,onOpenChange:s,modal:a=!0}=e,c=i.useRef(null),l=i.useRef(null),[u,f]=Ie({prop:r,defaultProp:o??!1,onChange:s,caller:sn});return p.jsx(gh,{scope:t,triggerRef:c,contentRef:l,contentId:he(),titleId:he(),descriptionId:he(),open:u,onOpenChange:f,onOpenToggle:i.useCallback(()=>f(d=>!d),[f]),modal:a,children:n})};Zi.displayName=sn;var Ji="DialogTrigger",Qi=i.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(Ji,n),s=q(t,o.triggerRef);return p.jsx(ht.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.contentId,"data-state":fr(o.open),...r,ref:s,onClick:M(e.onClick,o.onOpenToggle)})});Qi.displayName=Ji;var ur="DialogPortal",[vh,ea]=qi(ur,{forceMount:void 0}),ta=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:o}=e,s=ye(ur,t);return p.jsx(vh,{scope:t,forceMount:n,children:i.Children.map(r,a=>p.jsx(_e,{present:n||s.open,children:p.jsx(Qt,{asChild:!0,container:o,children:a})}))})};ta.displayName=ur;var Wt="DialogOverlay",na=i.forwardRef((e,t)=>{const n=ea(Wt,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=ye(Wt,e.__scopeDialog);return s.modal?p.jsx(_e,{present:r||s.open,children:p.jsx(xh,{...o,ref:t})}):null});na.displayName=Wt;var yh=Xi("DialogOverlay.RemoveScroll"),xh=i.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(Wt,n);return p.jsx(tn,{as:yh,allowPinchZoom:!0,shards:[o.contentRef],children:p.jsx(ht.div,{"data-state":fr(o.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),Be="DialogContent",ra=i.forwardRef((e,t)=>{const n=ea(Be,e.__scopeDialog),{forceMount:r=n.forceMount,...o}=e,s=ye(Be,e.__scopeDialog);return p.jsx(_e,{present:r||s.open,children:s.modal?p.jsx(bh,{...o,ref:t}):p.jsx(wh,{...o,ref:t})})});ra.displayName=Be;var bh=i.forwardRef((e,t)=>{const n=ye(Be,e.__scopeDialog),r=i.useRef(null),o=q(t,n.contentRef,r);return i.useEffect(()=>{const s=r.current;if(s)return ir(s)},[]),p.jsx(oa,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:M(e.onCloseAutoFocus,s=>{s.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:M(e.onPointerDownOutside,s=>{const a=s.detail.originalEvent,c=a.button===0&&a.ctrlKey===!0;(a.button===2||c)&&s.preventDefault()}),onFocusOutside:M(e.onFocusOutside,s=>s.preventDefault())})}),wh=i.forwardRef((e,t)=>{const n=ye(Be,e.__scopeDialog),r=i.useRef(!1),o=i.useRef(!1);return p.jsx(oa,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{e.onCloseAutoFocus?.(s),s.defaultPrevented||(r.current||n.triggerRef.current?.focus(),s.preventDefault()),r.current=!1,o.current=!1},onInteractOutside:s=>{e.onInteractOutside?.(s),s.defaultPrevented||(r.current=!0,s.detail.originalEvent.type==="pointerdown"&&(o.current=!0));const a=s.target;n.triggerRef.current?.contains(a)&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&o.current&&s.preventDefault()}})}),oa=i.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:s,...a}=e,c=ye(Be,n),l=i.useRef(null),u=q(t,l);return qn(),p.jsxs(p.Fragment,{children:[p.jsx(Kt,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:o,onUnmountAutoFocus:s,children:p.jsx(Gt,{role:"dialog",id:c.contentId,"aria-describedby":c.descriptionId,"aria-labelledby":c.titleId,"data-state":fr(c.open),...a,ref:u,onDismiss:()=>c.onOpenChange(!1)})}),p.jsxs(p.Fragment,{children:[p.jsx(Sh,{titleId:c.titleId}),p.jsx(Eh,{contentRef:l,descriptionId:c.descriptionId})]})]})}),dr="DialogTitle",sa=i.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(dr,n);return p.jsx(ht.h2,{id:o.titleId,...r,ref:t})});sa.displayName=dr;var ia="DialogDescription",aa=i.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(ia,n);return p.jsx(ht.p,{id:o.descriptionId,...r,ref:t})});aa.displayName=ia;var ca="DialogClose",la=i.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,o=ye(ca,n);return p.jsx(ht.button,{type:"button",...r,ref:t,onClick:M(e.onClick,()=>o.onOpenChange(!1))})});la.displayName=ca;function fr(e){return e?"open":"closed"}var ua="DialogTitleWarning",[Mv,da]=ah(ua,{contentName:Be,titleName:dr,docsSlug:"dialog"}),Sh=({titleId:e})=>{const t=da(ua),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
|
|
47
|
+
|
|
48
|
+
If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
49
|
+
|
|
50
|
+
For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return i.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},Ch="DialogDescriptionWarning",Eh=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${da(Ch).contentName}}.`;return i.useEffect(()=>{const o=e.current?.getAttribute("aria-describedby");t&&o&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},Rh=Zi,Ph=Qi,_h=ta,fa=na,pa=ra,ma=sa,ha=aa,ga=la;const Nh=Rh,Ah=Ph,va=_h,Oh=ga,pr=i.forwardRef(({className:e,...t},n)=>p.jsx(fa,{ref:n,className:B("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));pr.displayName=fa.displayName;const ya=i.forwardRef(({className:e,children:t,...n},r)=>p.jsxs(va,{children:[p.jsx(pr,{}),p.jsxs(pa,{ref:r,className:B("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...n,children:[t,p.jsxs(ga,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:[p.jsx(ku,{className:"h-4 w-4"}),p.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));ya.displayName=pa.displayName;const xa=({className:e,...t})=>p.jsx("div",{className:B("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});xa.displayName="DialogHeader";const ba=({className:e,...t})=>p.jsx("div",{className:B("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...t});ba.displayName="DialogFooter";const wa=i.forwardRef(({className:e,...t},n)=>p.jsx(ma,{ref:n,className:B("text-lg font-semibold leading-none tracking-tight",e),...t}));wa.displayName=ma.displayName;const Sa=i.forwardRef(({className:e,...t},n)=>p.jsx(ha,{ref:n,className:B("text-sm text-muted-foreground",e),...t}));Sa.displayName=ha.displayName;function Ih(e,t=[]){let n=[];function r(s,a){const c=i.createContext(a),l=n.length;n=[...n,a];const u=d=>{const{scope:h,children:g,...v}=d,m=h?.[e]?.[l]||c,y=i.useMemo(()=>v,Object.values(v));return p.jsx(m.Provider,{value:y,children:g})};u.displayName=s+"Provider";function f(d,h){const g=h?.[e]?.[l]||c,v=i.useContext(g);if(v)return v;if(a!==void 0)return a;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[u,f]}const o=()=>{const s=n.map(a=>i.createContext(a));return function(c){const l=c?.[e]||s;return i.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return o.scopeName=e,[r,Th(o,...t)]}function Th(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const a=r.reduce((c,{useScope:l,scopeName:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return i.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function Mh(e){const t=kh(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(jh);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function kh(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=Lh(o),c=$h(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Dh=Symbol("radix.slottable");function jh(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Dh}function $h(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Lh(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Fh=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Vh=Fh.reduce((e,t)=>{const n=Mh(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Wh(e,t=[]){let n=[];function r(s,a){const c=i.createContext(a),l=n.length;n=[...n,a];const u=d=>{const{scope:h,children:g,...v}=d,m=h?.[e]?.[l]||c,y=i.useMemo(()=>v,Object.values(v));return p.jsx(m.Provider,{value:y,children:g})};u.displayName=s+"Provider";function f(d,h){const g=h?.[e]?.[l]||c,v=i.useContext(g);if(v)return v;if(a!==void 0)return a;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[u,f]}const o=()=>{const s=n.map(a=>i.createContext(a));return function(c){const l=c?.[e]||s;return i.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return o.scopeName=e,[r,Bh(o,...t)]}function Bh(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const a=r.reduce((c,{useScope:l,scopeName:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return i.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function Ca(e){const t=Hh(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(Uh);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function Hh(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=Kh(o),c=Gh(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var zh=Symbol("radix.slottable");function Uh(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===zh}function Gh(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function Kh(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Yh=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],gt=Yh.reduce((e,t)=>{const n=Ca(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Xh(e,t){e&&ft.flushSync(()=>e.dispatchEvent(t))}function qh(e,t=[]){let n=[];function r(s,a){const c=i.createContext(a),l=n.length;n=[...n,a];const u=d=>{const{scope:h,children:g,...v}=d,m=h?.[e]?.[l]||c,y=i.useMemo(()=>v,Object.values(v));return p.jsx(m.Provider,{value:y,children:g})};u.displayName=s+"Provider";function f(d,h){const g=h?.[e]?.[l]||c,v=i.useContext(g);if(v)return v;if(a!==void 0)return a;throw new Error(`\`${d}\` must be used within \`${s}\``)}return[u,f]}const o=()=>{const s=n.map(a=>i.createContext(a));return function(c){const l=c?.[e]||s;return i.useMemo(()=>({[`__scope${e}`]:{...c,[e]:l}}),[c,l])}};return o.scopeName=e,[r,Zh(o,...t)]}function Zh(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(s){const a=r.reduce((c,{useScope:l,scopeName:u})=>{const d=l(s)[`__scope${u}`];return{...c,...d}},{});return i.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function Jh(e){const t=Qh(e),n=i.forwardRef((r,o)=>{const{children:s,...a}=r,c=i.Children.toArray(s),l=c.find(tg);if(l){const u=l.props.children,f=c.map(d=>d===l?i.Children.count(u)>1?i.Children.only(null):i.isValidElement(u)?u.props.children:null:d);return p.jsx(t,{...a,ref:o,children:i.isValidElement(u)?i.cloneElement(u,void 0,f):null})}return p.jsx(t,{...a,ref:o,children:s})});return n.displayName=`${e}.Slot`,n}function Qh(e){const t=i.forwardRef((n,r)=>{const{children:o,...s}=n;if(i.isValidElement(o)){const a=rg(o),c=ng(s,o.props);return o.type!==i.Fragment&&(c.ref=r?ie(r,a):a),i.cloneElement(o,c)}return i.Children.count(o)>1?i.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var eg=Symbol("radix.slottable");function tg(e){return i.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===eg}function ng(e,t){const n={...t};for(const r in t){const o=e[r],s=t[r];/^on[A-Z]/.test(r)?o&&s?n[r]=(...c)=>{const l=s(...c);return o(...c),l}:o&&(n[r]=o):r==="style"?n[r]={...o,...s}:r==="className"&&(n[r]=[o,s].filter(Boolean).join(" "))}return{...e,...n}}function rg(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var og=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Ea=og.reduce((e,t)=>{const n=Jh(`Primitive.${t}`),r=i.forwardRef((o,s)=>{const{asChild:a,...c}=o,l=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...c,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),Rn="rovingFocusGroup.onEntryFocus",sg={bubbles:!1,cancelable:!0},vt="RovingFocusGroup",[$n,Ra,ig]=Yn(vt),[ag,Pa]=qh(vt,[ig]),[cg,lg]=ag(vt),_a=i.forwardRef((e,t)=>p.jsx($n.Provider,{scope:e.__scopeRovingFocusGroup,children:p.jsx($n.Slot,{scope:e.__scopeRovingFocusGroup,children:p.jsx(ug,{...e,ref:t})})}));_a.displayName=vt;var ug=i.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:s,currentTabStopId:a,defaultCurrentTabStopId:c,onCurrentTabStopIdChange:l,onEntryFocus:u,preventScrollOnEntryFocus:f=!1,...d}=e,h=i.useRef(null),g=q(t,h),v=Xn(s),[m,y]=Ie({prop:a,defaultProp:c??null,onChange:l,caller:vt}),[x,b]=i.useState(!1),w=pe(u),C=Ra(n),_=i.useRef(!1),[O,N]=i.useState(0);return i.useEffect(()=>{const P=h.current;if(P)return P.addEventListener(Rn,w),()=>P.removeEventListener(Rn,w)},[w]),p.jsx(cg,{scope:n,orientation:r,dir:v,loop:o,currentTabStopId:m,onItemFocus:i.useCallback(P=>y(P),[y]),onItemShiftTab:i.useCallback(()=>b(!0),[]),onFocusableItemAdd:i.useCallback(()=>N(P=>P+1),[]),onFocusableItemRemove:i.useCallback(()=>N(P=>P-1),[]),children:p.jsx(Ea.div,{tabIndex:x||O===0?-1:0,"data-orientation":r,...d,ref:g,style:{outline:"none",...e.style},onMouseDown:M(e.onMouseDown,()=>{_.current=!0}),onFocus:M(e.onFocus,P=>{const j=!_.current;if(P.target===P.currentTarget&&j&&!x){const F=new CustomEvent(Rn,sg);if(P.currentTarget.dispatchEvent(F),!F.defaultPrevented){const z=C().filter(k=>k.focusable),V=z.find(k=>k.active),U=z.find(k=>k.id===m),K=[V,U,...z].filter(Boolean).map(k=>k.ref.current);Oa(K,f)}}_.current=!1}),onBlur:M(e.onBlur,()=>b(!1))})})}),Na="RovingFocusGroupItem",Aa=i.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:s,children:a,...c}=e,l=he(),u=s||l,f=lg(Na,n),d=f.currentTabStopId===u,h=Ra(n),{onFocusableItemAdd:g,onFocusableItemRemove:v,currentTabStopId:m}=f;return i.useEffect(()=>{if(r)return g(),()=>v()},[r,g,v]),p.jsx($n.ItemSlot,{scope:n,id:u,focusable:r,active:o,children:p.jsx(Ea.span,{tabIndex:d?0:-1,"data-orientation":f.orientation,...c,ref:t,onMouseDown:M(e.onMouseDown,y=>{r?f.onItemFocus(u):y.preventDefault()}),onFocus:M(e.onFocus,()=>f.onItemFocus(u)),onKeyDown:M(e.onKeyDown,y=>{if(y.key==="Tab"&&y.shiftKey){f.onItemShiftTab();return}if(y.target!==y.currentTarget)return;const x=pg(y,f.orientation,f.dir);if(x!==void 0){if(y.metaKey||y.ctrlKey||y.altKey||y.shiftKey)return;y.preventDefault();let w=h().filter(C=>C.focusable).map(C=>C.ref.current);if(x==="last")w.reverse();else if(x==="prev"||x==="next"){x==="prev"&&w.reverse();const C=w.indexOf(y.currentTarget);w=f.loop?mg(w,C+1):w.slice(C+1)}setTimeout(()=>Oa(w))}}),children:typeof a=="function"?a({isCurrentTabStop:d,hasTabStop:m!=null}):a})})});Aa.displayName=Na;var dg={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function fg(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function pg(e,t,n){const r=fg(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return dg[r]}function Oa(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function mg(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var hg=_a,gg=Aa,Ln=["Enter"," "],vg=["ArrowDown","PageUp","Home"],Ia=["ArrowUp","PageDown","End"],yg=[...vg,...Ia],xg={ltr:[...Ln,"ArrowRight"],rtl:[...Ln,"ArrowLeft"]},bg={ltr:["ArrowLeft"],rtl:["ArrowRight"]},yt="Menu",[ut,wg,Sg]=Yn(yt),[He,Ta]=Wh(yt,[Sg,Jt,Pa]),xt=Jt(),Ma=Pa(),[ka,je]=He(yt),[Cg,bt]=He(yt),Da=e=>{const{__scopeMenu:t,open:n=!1,children:r,dir:o,onOpenChange:s,modal:a=!0}=e,c=xt(t),[l,u]=i.useState(null),f=i.useRef(!1),d=pe(s),h=Xn(o);return i.useEffect(()=>{const g=()=>{f.current=!0,document.addEventListener("pointerdown",v,{capture:!0,once:!0}),document.addEventListener("pointermove",v,{capture:!0,once:!0})},v=()=>f.current=!1;return document.addEventListener("keydown",g,{capture:!0}),()=>{document.removeEventListener("keydown",g,{capture:!0}),document.removeEventListener("pointerdown",v,{capture:!0}),document.removeEventListener("pointermove",v,{capture:!0})}},[]),p.jsx(sr,{...c,children:p.jsx(ka,{scope:t,open:n,onOpenChange:d,content:l,onContentChange:u,children:p.jsx(Cg,{scope:t,onClose:i.useCallback(()=>d(!1),[d]),isUsingKeyboardRef:f,dir:h,modal:a,children:r})})})};Da.displayName=yt;var Eg="MenuAnchor",mr=i.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=xt(n);return p.jsx(Xs,{...o,...r,ref:t})});mr.displayName=Eg;var hr="MenuPortal",[Rg,ja]=He(hr,{forceMount:void 0}),$a=e=>{const{__scopeMenu:t,forceMount:n,children:r,container:o}=e,s=je(hr,t);return p.jsx(Rg,{scope:t,forceMount:n,children:p.jsx(_e,{present:n||s.open,children:p.jsx(Qt,{asChild:!0,container:o,children:r})})})};$a.displayName=hr;var fe="MenuContent",[Pg,gr]=He(fe),La=i.forwardRef((e,t)=>{const n=ja(fe,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,s=je(fe,e.__scopeMenu),a=bt(fe,e.__scopeMenu);return p.jsx(ut.Provider,{scope:e.__scopeMenu,children:p.jsx(_e,{present:r||s.open,children:p.jsx(ut.Slot,{scope:e.__scopeMenu,children:a.modal?p.jsx(_g,{...o,ref:t}):p.jsx(Ng,{...o,ref:t})})})})}),_g=i.forwardRef((e,t)=>{const n=je(fe,e.__scopeMenu),r=i.useRef(null),o=q(t,r);return i.useEffect(()=>{const s=r.current;if(s)return ir(s)},[]),p.jsx(vr,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:M(e.onFocusOutside,s=>s.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),Ng=i.forwardRef((e,t)=>{const n=je(fe,e.__scopeMenu);return p.jsx(vr,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),Ag=Ca("MenuContent.ScrollLock"),vr=i.forwardRef((e,t)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:o,onOpenAutoFocus:s,onCloseAutoFocus:a,disableOutsidePointerEvents:c,onEntryFocus:l,onEscapeKeyDown:u,onPointerDownOutside:f,onFocusOutside:d,onInteractOutside:h,onDismiss:g,disableOutsideScroll:v,...m}=e,y=je(fe,n),x=bt(fe,n),b=xt(n),w=Ma(n),C=wg(n),[_,O]=i.useState(null),N=i.useRef(null),P=q(t,N,y.onContentChange),j=i.useRef(0),F=i.useRef(""),z=i.useRef(0),V=i.useRef(null),U=i.useRef("right"),H=i.useRef(0),K=v?tn:i.Fragment,k=v?{as:Ag,allowPinchZoom:!0}:void 0,W=A=>{const J=F.current+A,S=C().filter(R=>!R.disabled),D=document.activeElement,$=S.find(R=>R.ref.current===D)?.textValue,L=S.map(R=>R.textValue),ne=Wg(L,J,$),te=S.find(R=>R.textValue===ne)?.ref.current;(function R(Y){F.current=Y,window.clearTimeout(j.current),Y!==""&&(j.current=window.setTimeout(()=>R(""),1e3))})(J),te&&setTimeout(()=>te.focus())};i.useEffect(()=>()=>window.clearTimeout(j.current),[]),qn();const E=i.useCallback(A=>U.current===V.current?.side&&Hg(A,V.current?.area),[]);return p.jsx(Pg,{scope:n,searchRef:F,onItemEnter:i.useCallback(A=>{E(A)&&A.preventDefault()},[E]),onItemLeave:i.useCallback(A=>{E(A)||(N.current?.focus(),O(null))},[E]),onTriggerLeave:i.useCallback(A=>{E(A)&&A.preventDefault()},[E]),pointerGraceTimerRef:z,onPointerGraceIntentChange:i.useCallback(A=>{V.current=A},[]),children:p.jsx(K,{...k,children:p.jsx(Kt,{asChild:!0,trapped:o,onMountAutoFocus:M(s,A=>{A.preventDefault(),N.current?.focus({preventScroll:!0})}),onUnmountAutoFocus:a,children:p.jsx(Gt,{asChild:!0,disableOutsidePointerEvents:c,onEscapeKeyDown:u,onPointerDownOutside:f,onFocusOutside:d,onInteractOutside:h,onDismiss:g,children:p.jsx(hg,{asChild:!0,...w,dir:x.dir,orientation:"vertical",loop:r,currentTabStopId:_,onCurrentTabStopIdChange:O,onEntryFocus:M(l,A=>{x.isUsingKeyboardRef.current||A.preventDefault()}),preventScrollOnEntryFocus:!0,children:p.jsx(qs,{role:"menu","aria-orientation":"vertical","data-state":tc(y.open),"data-radix-menu-content":"",dir:x.dir,...b,...m,ref:P,style:{outline:"none",...m.style},onKeyDown:M(m.onKeyDown,A=>{const S=A.target.closest("[data-radix-menu-content]")===A.currentTarget,D=A.ctrlKey||A.altKey||A.metaKey,$=A.key.length===1;S&&(A.key==="Tab"&&A.preventDefault(),!D&&$&&W(A.key));const L=N.current;if(A.target!==L||!yg.includes(A.key))return;A.preventDefault();const te=C().filter(R=>!R.disabled).map(R=>R.ref.current);Ia.includes(A.key)&&te.reverse(),Fg(te)}),onBlur:M(e.onBlur,A=>{A.currentTarget.contains(A.target)||(window.clearTimeout(j.current),F.current="")}),onPointerMove:M(e.onPointerMove,dt(A=>{const J=A.target,S=H.current!==A.clientX;if(A.currentTarget.contains(J)&&S){const D=A.clientX>H.current?"right":"left";U.current=D,H.current=A.clientX}}))})})})})})})});La.displayName=fe;var Og="MenuGroup",yr=i.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return p.jsx(gt.div,{role:"group",...r,ref:t})});yr.displayName=Og;var Ig="MenuLabel",Fa=i.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return p.jsx(gt.div,{...r,ref:t})});Fa.displayName=Ig;var Bt="MenuItem",uo="menu.itemSelect",an=i.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:r,...o}=e,s=i.useRef(null),a=bt(Bt,e.__scopeMenu),c=gr(Bt,e.__scopeMenu),l=q(t,s),u=i.useRef(!1),f=()=>{const d=s.current;if(!n&&d){const h=new CustomEvent(uo,{bubbles:!0,cancelable:!0});d.addEventListener(uo,g=>r?.(g),{once:!0}),Xh(d,h),h.defaultPrevented?u.current=!1:a.onClose()}};return p.jsx(Va,{...o,ref:l,disabled:n,onClick:M(e.onClick,f),onPointerDown:d=>{e.onPointerDown?.(d),u.current=!0},onPointerUp:M(e.onPointerUp,d=>{u.current||d.currentTarget?.click()}),onKeyDown:M(e.onKeyDown,d=>{const h=c.searchRef.current!=="";n||h&&d.key===" "||Ln.includes(d.key)&&(d.currentTarget.click(),d.preventDefault())})})});an.displayName=Bt;var Va=i.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:r=!1,textValue:o,...s}=e,a=gr(Bt,n),c=Ma(n),l=i.useRef(null),u=q(t,l),[f,d]=i.useState(!1),[h,g]=i.useState("");return i.useEffect(()=>{const v=l.current;v&&g((v.textContent??"").trim())},[s.children]),p.jsx(ut.ItemSlot,{scope:n,disabled:r,textValue:o??h,children:p.jsx(gg,{asChild:!0,...c,focusable:!r,children:p.jsx(gt.div,{role:"menuitem","data-highlighted":f?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0,...s,ref:u,onPointerMove:M(e.onPointerMove,dt(v=>{r?a.onItemLeave(v):(a.onItemEnter(v),v.defaultPrevented||v.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:M(e.onPointerLeave,dt(v=>a.onItemLeave(v))),onFocus:M(e.onFocus,()=>d(!0)),onBlur:M(e.onBlur,()=>d(!1))})})})}),Tg="MenuCheckboxItem",Wa=i.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:r,...o}=e;return p.jsx(Ga,{scope:e.__scopeMenu,checked:n,children:p.jsx(an,{role:"menuitemcheckbox","aria-checked":Ht(n)?"mixed":n,...o,ref:t,"data-state":wr(n),onSelect:M(o.onSelect,()=>r?.(Ht(n)?!0:!n),{checkForDefaultPrevented:!1})})})});Wa.displayName=Tg;var Ba="MenuRadioGroup",[Mg,kg]=He(Ba,{value:void 0,onValueChange:()=>{}}),Ha=i.forwardRef((e,t)=>{const{value:n,onValueChange:r,...o}=e,s=pe(r);return p.jsx(Mg,{scope:e.__scopeMenu,value:n,onValueChange:s,children:p.jsx(yr,{...o,ref:t})})});Ha.displayName=Ba;var za="MenuRadioItem",Ua=i.forwardRef((e,t)=>{const{value:n,...r}=e,o=kg(za,e.__scopeMenu),s=n===o.value;return p.jsx(Ga,{scope:e.__scopeMenu,checked:s,children:p.jsx(an,{role:"menuitemradio","aria-checked":s,...r,ref:t,"data-state":wr(s),onSelect:M(r.onSelect,()=>o.onValueChange?.(n),{checkForDefaultPrevented:!1})})})});Ua.displayName=za;var xr="MenuItemIndicator",[Ga,Dg]=He(xr,{checked:!1}),Ka=i.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:r,...o}=e,s=Dg(xr,n);return p.jsx(_e,{present:r||Ht(s.checked)||s.checked===!0,children:p.jsx(gt.span,{...o,ref:t,"data-state":wr(s.checked)})})});Ka.displayName=xr;var jg="MenuSeparator",Ya=i.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return p.jsx(gt.div,{role:"separator","aria-orientation":"horizontal",...r,ref:t})});Ya.displayName=jg;var $g="MenuArrow",Xa=i.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=xt(n);return p.jsx(Zs,{...o,...r,ref:t})});Xa.displayName=$g;var br="MenuSub",[Lg,qa]=He(br),Za=e=>{const{__scopeMenu:t,children:n,open:r=!1,onOpenChange:o}=e,s=je(br,t),a=xt(t),[c,l]=i.useState(null),[u,f]=i.useState(null),d=pe(o);return i.useEffect(()=>(s.open===!1&&d(!1),()=>d(!1)),[s.open,d]),p.jsx(sr,{...a,children:p.jsx(ka,{scope:t,open:r,onOpenChange:d,content:u,onContentChange:f,children:p.jsx(Lg,{scope:t,contentId:he(),triggerId:he(),trigger:c,onTriggerChange:l,children:n})})})};Za.displayName=br;var at="MenuSubTrigger",Ja=i.forwardRef((e,t)=>{const n=je(at,e.__scopeMenu),r=bt(at,e.__scopeMenu),o=qa(at,e.__scopeMenu),s=gr(at,e.__scopeMenu),a=i.useRef(null),{pointerGraceTimerRef:c,onPointerGraceIntentChange:l}=s,u={__scopeMenu:e.__scopeMenu},f=i.useCallback(()=>{a.current&&window.clearTimeout(a.current),a.current=null},[]);return i.useEffect(()=>f,[f]),i.useEffect(()=>{const d=c.current;return()=>{window.clearTimeout(d),l(null)}},[c,l]),p.jsx(mr,{asChild:!0,...u,children:p.jsx(Va,{id:o.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":o.contentId,"data-state":tc(n.open),...e,ref:ie(t,o.onTriggerChange),onClick:d=>{e.onClick?.(d),!(e.disabled||d.defaultPrevented)&&(d.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:M(e.onPointerMove,dt(d=>{s.onItemEnter(d),!d.defaultPrevented&&!e.disabled&&!n.open&&!a.current&&(s.onPointerGraceIntentChange(null),a.current=window.setTimeout(()=>{n.onOpenChange(!0),f()},100))})),onPointerLeave:M(e.onPointerLeave,dt(d=>{f();const h=n.content?.getBoundingClientRect();if(h){const g=n.content?.dataset.side,v=g==="right",m=v?-5:5,y=h[v?"left":"right"],x=h[v?"right":"left"];s.onPointerGraceIntentChange({area:[{x:d.clientX+m,y:d.clientY},{x:y,y:h.top},{x,y:h.top},{x,y:h.bottom},{x:y,y:h.bottom}],side:g}),window.clearTimeout(c.current),c.current=window.setTimeout(()=>s.onPointerGraceIntentChange(null),300)}else{if(s.onTriggerLeave(d),d.defaultPrevented)return;s.onPointerGraceIntentChange(null)}})),onKeyDown:M(e.onKeyDown,d=>{const h=s.searchRef.current!=="";e.disabled||h&&d.key===" "||xg[r.dir].includes(d.key)&&(n.onOpenChange(!0),n.content?.focus(),d.preventDefault())})})})});Ja.displayName=at;var Qa="MenuSubContent",ec=i.forwardRef((e,t)=>{const n=ja(fe,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,s=je(fe,e.__scopeMenu),a=bt(fe,e.__scopeMenu),c=qa(Qa,e.__scopeMenu),l=i.useRef(null),u=q(t,l);return p.jsx(ut.Provider,{scope:e.__scopeMenu,children:p.jsx(_e,{present:r||s.open,children:p.jsx(ut.Slot,{scope:e.__scopeMenu,children:p.jsx(vr,{id:c.contentId,"aria-labelledby":c.triggerId,...o,ref:u,align:"start",side:a.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:f=>{a.isUsingKeyboardRef.current&&l.current?.focus(),f.preventDefault()},onCloseAutoFocus:f=>f.preventDefault(),onFocusOutside:M(e.onFocusOutside,f=>{f.target!==c.trigger&&s.onOpenChange(!1)}),onEscapeKeyDown:M(e.onEscapeKeyDown,f=>{a.onClose(),f.preventDefault()}),onKeyDown:M(e.onKeyDown,f=>{const d=f.currentTarget.contains(f.target),h=bg[a.dir].includes(f.key);d&&h&&(s.onOpenChange(!1),c.trigger?.focus(),f.preventDefault())})})})})})});ec.displayName=Qa;function tc(e){return e?"open":"closed"}function Ht(e){return e==="indeterminate"}function wr(e){return Ht(e)?"indeterminate":e?"checked":"unchecked"}function Fg(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function Vg(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function Wg(e,t,n){const o=t.length>1&&Array.from(t).every(u=>u===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let a=Vg(e,Math.max(s,0));o.length===1&&(a=a.filter(u=>u!==n));const l=a.find(u=>u.toLowerCase().startsWith(o.toLowerCase()));return l!==n?l:void 0}function Bg(e,t){const{x:n,y:r}=e;let o=!1;for(let s=0,a=t.length-1;s<t.length;a=s++){const c=t[s],l=t[a],u=c.x,f=c.y,d=l.x,h=l.y;f>r!=h>r&&n<(d-u)*(r-f)/(h-f)+u&&(o=!o)}return o}function Hg(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return Bg(n,t)}function dt(e){return t=>t.pointerType==="mouse"?e(t):void 0}var zg=Da,Ug=mr,Gg=$a,Kg=La,Yg=yr,Xg=Fa,qg=an,Zg=Wa,Jg=Ha,Qg=Ua,ev=Ka,tv=Ya,nv=Xa,rv=Za,ov=Ja,sv=ec,cn="DropdownMenu",[iv]=Ih(cn,[Ta]),ae=Ta(),[av,nc]=iv(cn),rc=e=>{const{__scopeDropdownMenu:t,children:n,dir:r,open:o,defaultOpen:s,onOpenChange:a,modal:c=!0}=e,l=ae(t),u=i.useRef(null),[f,d]=Ie({prop:o,defaultProp:s??!1,onChange:a,caller:cn});return p.jsx(av,{scope:t,triggerId:he(),triggerRef:u,contentId:he(),open:f,onOpenChange:d,onOpenToggle:i.useCallback(()=>d(h=>!h),[d]),modal:c,children:p.jsx(zg,{...l,open:f,onOpenChange:d,dir:r,modal:c,children:n})})};rc.displayName=cn;var oc="DropdownMenuTrigger",sc=i.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:r=!1,...o}=e,s=nc(oc,n),a=ae(n);return p.jsx(Ug,{asChild:!0,...a,children:p.jsx(Vh.button,{type:"button",id:s.triggerId,"aria-haspopup":"menu","aria-expanded":s.open,"aria-controls":s.open?s.contentId:void 0,"data-state":s.open?"open":"closed","data-disabled":r?"":void 0,disabled:r,...o,ref:ie(t,s.triggerRef),onPointerDown:M(e.onPointerDown,c=>{!r&&c.button===0&&c.ctrlKey===!1&&(s.onOpenToggle(),s.open||c.preventDefault())}),onKeyDown:M(e.onKeyDown,c=>{r||(["Enter"," "].includes(c.key)&&s.onOpenToggle(),c.key==="ArrowDown"&&s.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(c.key)&&c.preventDefault())})})})});sc.displayName=oc;var cv="DropdownMenuPortal",ic=e=>{const{__scopeDropdownMenu:t,...n}=e,r=ae(t);return p.jsx(Gg,{...r,...n})};ic.displayName=cv;var ac="DropdownMenuContent",cc=i.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=nc(ac,n),s=ae(n),a=i.useRef(!1);return p.jsx(Kg,{id:o.contentId,"aria-labelledby":o.triggerId,...s,...r,ref:t,onCloseAutoFocus:M(e.onCloseAutoFocus,c=>{a.current||o.triggerRef.current?.focus(),a.current=!1,c.preventDefault()}),onInteractOutside:M(e.onInteractOutside,c=>{const l=c.detail.originalEvent,u=l.button===0&&l.ctrlKey===!0,f=l.button===2||u;(!o.modal||f)&&(a.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});cc.displayName=ac;var lv="DropdownMenuGroup",lc=i.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=ae(n);return p.jsx(Yg,{...o,...r,ref:t})});lc.displayName=lv;var uv="DropdownMenuLabel",uc=i.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=ae(n);return p.jsx(Xg,{...o,...r,ref:t})});uc.displayName=uv;var dv="DropdownMenuItem",dc=i.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=ae(n);return p.jsx(qg,{...o,...r,ref:t})});dc.displayName=dv;var fv="DropdownMenuCheckboxItem",fc=i.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=ae(n);return p.jsx(Zg,{...o,...r,ref:t})});fc.displayName=fv;var pv="DropdownMenuRadioGroup",pc=i.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=ae(n);return p.jsx(Jg,{...o,...r,ref:t})});pc.displayName=pv;var mv="DropdownMenuRadioItem",mc=i.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=ae(n);return p.jsx(Qg,{...o,...r,ref:t})});mc.displayName=mv;var hv="DropdownMenuItemIndicator",hc=i.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=ae(n);return p.jsx(ev,{...o,...r,ref:t})});hc.displayName=hv;var gv="DropdownMenuSeparator",gc=i.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=ae(n);return p.jsx(tv,{...o,...r,ref:t})});gc.displayName=gv;var vv="DropdownMenuArrow",yv=i.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=ae(n);return p.jsx(nv,{...o,...r,ref:t})});yv.displayName=vv;var xv=e=>{const{__scopeDropdownMenu:t,children:n,open:r,onOpenChange:o,defaultOpen:s}=e,a=ae(t),[c,l]=Ie({prop:r,defaultProp:s??!1,onChange:o,caller:"DropdownMenuSub"});return p.jsx(rv,{...a,open:c,onOpenChange:l,children:n})},bv="DropdownMenuSubTrigger",vc=i.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=ae(n);return p.jsx(ov,{...o,...r,ref:t})});vc.displayName=bv;var wv="DropdownMenuSubContent",yc=i.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=ae(n);return p.jsx(sv,{...o,...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)"}})});yc.displayName=wv;var Sv=rc,Cv=sc,xc=ic,bc=cc,Ev=lc,wc=uc,Sc=dc,Cc=fc,Rv=pc,Ec=mc,Rc=hc,Pc=gc,Pv=xv,_c=vc,Nc=yc;const _v=Sv,Nv=Cv,Av=Ev,Ov=xc,Iv=Pv,Tv=Rv,Ac=i.forwardRef(({className:e,inset:t,children:n,...r},o)=>p.jsxs(_c,{ref:o,className:B("flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none focus:bg-accent data-[state=open]:bg-accent",t&&"pl-8",e),...r,children:[n,p.jsx(Nu,{className:"ml-auto h-4 w-4"})]}));Ac.displayName=_c.displayName;const Oc=i.forwardRef(({className:e,...t},n)=>p.jsx(Nc,{ref:n,className:B("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-lg data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 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",e),...t}));Oc.displayName=Nc.displayName;const Ic=i.forwardRef(({className:e,sideOffset:t=4,...n},r)=>p.jsx(xc,{children:p.jsx(bc,{ref:r,sideOffset:t,className:B("z-50 min-w-[8rem] overflow-hidden rounded-md border bg-popover p-1 text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 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",e),...n})}));Ic.displayName=bc.displayName;const Tc=i.forwardRef(({className:e,inset:t,...n},r)=>p.jsx(Sc,{ref:r,className:B("relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",t&&"pl-8",e),...n}));Tc.displayName=Sc.displayName;const Mc=i.forwardRef(({className:e,children:t,checked:n,...r},o)=>p.jsxs(Cc,{ref:o,className:B("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:n,...r,children:[p.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:p.jsx(Rc,{children:p.jsx(Kn,{className:"h-4 w-4"})})}),t]}));Mc.displayName=Cc.displayName;const kc=i.forwardRef(({className:e,children:t,...n},r)=>p.jsxs(Ec,{ref:r,className:B("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[p.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:p.jsx(Rc,{children:p.jsx(Tu,{className:"h-2 w-2 fill-current"})})}),t]}));kc.displayName=Ec.displayName;const Dc=i.forwardRef(({className:e,inset:t,...n},r)=>p.jsx(wc,{ref:r,className:B("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...n}));Dc.displayName=wc.displayName;const jc=i.forwardRef(({className:e,...t},n)=>p.jsx(Pc,{ref:n,className:B("-mx-1 my-1 h-px bg-muted",e),...t}));jc.displayName=Pc.displayName;const $c=({className:e,...t})=>p.jsx("span",{className:B("ml-auto text-xs tracking-widest opacity-60",e),...t});$c.displayName="DropdownMenuShortcut";exports.Avatar=qo;exports.AvatarFallback=Jo;exports.AvatarImage=Zo;exports.Badge=Vl;exports.Button=Io;exports.Card=Qo;exports.CardContent=rs;exports.CardDescription=ns;exports.CardFooter=os;exports.CardHeader=es;exports.CardTitle=ts;exports.Checkbox=ms;exports.Dialog=Nh;exports.DialogClose=Oh;exports.DialogContent=ya;exports.DialogDescription=Sa;exports.DialogFooter=ba;exports.DialogHeader=xa;exports.DialogOverlay=pr;exports.DialogPortal=va;exports.DialogTitle=wa;exports.DialogTrigger=Ah;exports.DropdownMenu=_v;exports.DropdownMenuCheckboxItem=Mc;exports.DropdownMenuContent=Ic;exports.DropdownMenuGroup=Av;exports.DropdownMenuItem=Tc;exports.DropdownMenuLabel=Dc;exports.DropdownMenuPortal=Ov;exports.DropdownMenuRadioGroup=Tv;exports.DropdownMenuRadioItem=kc;exports.DropdownMenuSeparator=jc;exports.DropdownMenuShortcut=$c;exports.DropdownMenuSub=Iv;exports.DropdownMenuSubContent=Oc;exports.DropdownMenuSubTrigger=Ac;exports.DropdownMenuTrigger=Nv;exports.Input=To;exports.Label=jo;exports.Select=oh;exports.SelectContent=Ui;exports.SelectGroup=sh;exports.SelectItem=Ki;exports.SelectLabel=Gi;exports.SelectScrollDownButton=lr;exports.SelectScrollUpButton=cr;exports.SelectSeparator=Yi;exports.SelectTrigger=zi;exports.SelectValue=ih;exports.Separator=Vo;exports.Switch=Ss;exports.Textarea=Mo;exports.badgeVariants=$o;exports.buttonVariants=Oo;exports.cn=B;
|
|
51
|
+
//# sourceMappingURL=index.cjs.js.map
|