@vacano/ui 0.0.1 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -1,26 +1,26 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const w=require("./Minus-C6HNRQfO.cjs"),He=require("@emotion/react"),X=require("react"),Ft=require("react-dom"),We=require("react/jsx-runtime");function wo(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,o.get?o:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const C=wo(X),pn=wo(Ft);function sr(){return sr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var o in r)({}).hasOwnProperty.call(r,o)&&(e[o]=r[o])}return e},sr.apply(null,arguments)}const bn=6,xn="Loading";var mn=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|popover|popoverTarget|popoverTargetAction|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,Cn=w.memoize(function(e){return mn.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91}),vn=Cn,wn=function(t){return t!=="theme"},Tr=function(t){return typeof t=="string"&&t.charCodeAt(0)>96?vn:wn},$r=function(t,r,o){var n;if(r){var s=r.shouldForwardProp;n=t.__emotion_forwardProp&&s?function(l){return t.__emotion_forwardProp(l)&&s(l)}:s}return typeof n!="function"&&o&&(n=t.__emotion_forwardProp),n},yn=function(t){var r=t.cache,o=t.serialized,n=t.isStringTag;return w.registerStyles(r,o,n),w.useInsertionEffectAlwaysWithSyncFallback(function(){return w.insertStyles(r,o,n)}),null},kn=function e(t,r){var o=t.__emotion_real===t,n=o&&t.__emotion_base||t,s,l;r!==void 0&&(s=r.label,l=r.target);var c=$r(t,r,o),d=c||Tr(n),a=!d("as");return function(){var u=arguments,g=o&&t.__emotion_styles!==void 0?t.__emotion_styles.slice(0):[];if(s!==void 0&&g.push("label:"+s+";"),u[0]==null||u[0].raw===void 0)g.push.apply(g,u);else{var f=u[0];g.push(f[0]);for(var p=u.length,x=1;x<p;x++)g.push(u[x],f[x])}var h=He.withEmotionCache(function(y,m,v){var k=a&&y.as||n,R="",I=[],P=y;if(y.theme==null){P={};for(var L in y)P[L]=y[L];P.theme=C.useContext(He.ThemeContext)}typeof y.className=="string"?R=w.getRegisteredStyles(m.registered,I,y.className):y.className!=null&&(R=y.className+" ");var j=w.serializeStyles(g.concat(I),m.registered,P);R+=m.key+"-"+j.name,l!==void 0&&(R+=" "+l);var Z=a&&c===void 0?Tr(k):d,$={};for(var F in y)a&&F==="as"||Z(F)&&($[F]=y[F]);return $.className=R,v&&($.ref=v),C.createElement(C.Fragment,null,C.createElement(yn,{cache:m,serialized:j,isStringTag:typeof k=="string"}),C.createElement(k,$))});return h.displayName=s!==void 0?s:"Styled("+(typeof n=="string"?n:n.displayName||n.name||"Component")+")",h.defaultProps=t.defaultProps,h.__emotion_real=h,h.__emotion_base=n,h.__emotion_styles=g,h.__emotion_forwardProp=c,Object.defineProperty(h,"toString",{value:function(){return"."+l}}),h.withComponent=function(y,m){var v=e(y,sr({},r,m,{shouldForwardProp:$r(h,m,!0)}));return v.apply(void 0,g)},h}},Rn=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"],O=kn.bind(null);Rn.forEach(function(e){O[e]=O(e)});const Sn=He.keyframes`
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("./X-BRRD8eNW.cjs"),qe=require("@emotion/react"),_=require("react"),ft=require("react-dom"),Ue=require("react/jsx-runtime");function Lo(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,o.get?o:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const w=Lo(_),$n=Lo(ft);function ar(){return ar=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var o in r)({}).hasOwnProperty.call(r,o)&&(e[o]=r[o])}return e},ar.apply(null,arguments)}const In=6,Tn="Loading";var On=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|popover|popoverTarget|popoverTargetAction|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,Mn=m.memoize(function(e){return On.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91}),An=Mn,Pn=function(t){return t!=="theme"},jr=function(t){return typeof t=="string"&&t.charCodeAt(0)>96?An:Pn},Br=function(t,r,o){var i;if(r){var c=r.shouldForwardProp;i=t.__emotion_forwardProp&&c?function(l){return t.__emotion_forwardProp(l)&&c(l)}:c}return typeof i!="function"&&o&&(i=t.__emotion_forwardProp),i},Dn=function(t){var r=t.cache,o=t.serialized,i=t.isStringTag;return m.registerStyles(r,o,i),m.useInsertionEffectAlwaysWithSyncFallback(function(){return m.insertStyles(r,o,i)}),null},Ln=function e(t,r){var o=t.__emotion_real===t,i=o&&t.__emotion_base||t,c,l;r!==void 0&&(c=r.label,l=r.target);var s=Br(t,r,o),d=s||jr(i),a=!d("as");return function(){var u=arguments,h=o&&t.__emotion_styles!==void 0?t.__emotion_styles.slice(0):[];if(c!==void 0&&h.push("label:"+c+";"),u[0]==null||u[0].raw===void 0)h.push.apply(h,u);else{var f=u[0];h.push(f[0]);for(var b=u.length,C=1;C<b;C++)h.push(u[C],f[C])}var g=qe.withEmotionCache(function(y,p,v){var k=a&&y.as||i,S="",T=[],M=y;if(y.theme==null){M={};for(var N in y)M[N]=y[N];M.theme=w.useContext(qe.ThemeContext)}typeof y.className=="string"?S=m.getRegisteredStyles(p.registered,T,y.className):y.className!=null&&(S=y.className+" ");var B=m.serializeStyles(h.concat(T),p.registered,M);S+=p.key+"-"+B.name,l!==void 0&&(S+=" "+l);var X=a&&s===void 0?jr(k):d,O={};for(var F in y)a&&F==="as"||X(F)&&(O[F]=y[F]);return O.className=S,v&&(O.ref=v),w.createElement(w.Fragment,null,w.createElement(Dn,{cache:p,serialized:B,isStringTag:typeof k=="string"}),w.createElement(k,O))});return g.displayName=c!==void 0?c:"Styled("+(typeof i=="string"?i:i.displayName||i.name||"Component")+")",g.defaultProps=t.defaultProps,g.__emotion_real=g,g.__emotion_base=i,g.__emotion_styles=h,g.__emotion_forwardProp=s,Object.defineProperty(g,"toString",{value:function(){return"."+l}}),g.withComponent=function(y,p){var v=e(y,ar({},r,p,{shouldForwardProp:Br(g,p,!0)}));return v.apply(void 0,h)},g}},Nn=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"],I=Ln.bind(null);Nn.forEach(function(e){I[e]=I(e)});const Fn=qe.keyframes`
2
2
  0%, 100% {
3
3
  opacity: 1;
4
4
  }
5
5
  50% {
6
6
  opacity: 0.3;
7
7
  }
8
- `,En=O.span`
8
+ `,_n=I.span`
9
9
  display: inline-flex;
10
10
  align-items: center;
11
11
  gap: ${({$size:e})=>Math.round(e*.6)}px;
12
- `,Kt=O.span`
12
+ `,Xt=I.span`
13
13
  width: ${({$size:e})=>e}px;
14
14
  height: ${({$size:e})=>e}px;
15
15
  border-radius: 50%;
16
16
  background: currentColor;
17
- animation: ${Sn} 0.8s ease-in-out infinite;
17
+ animation: ${Fn} 0.8s ease-in-out infinite;
18
18
  animation-delay: ${({$delay:e})=>e}s;
19
- `,In=w.classNameGetter("loader"),yo=({"aria-label":e=xn,className:t,classnames:r,size:o=bn,...n})=>w.jsxs(En,{...n,className:In("container",t,r==null?void 0:r.container),role:"status","aria-label":e,$size:o,children:[w.jsx(Kt,{$size:o,$delay:0}),w.jsx(Kt,{$size:o,$delay:.15}),w.jsx(Kt,{$size:o,$delay:.3})]}),On=24,Tn="Loading",$n=He.keyframes`
19
+ `,jn=m.classNameGetter("loader"),No=({"aria-label":e=Tn,className:t,classnames:r,size:o=In,...i})=>m.jsxs(_n,{...i,className:jn("container",t,r==null?void 0:r.container),role:"status","aria-label":e,$size:o,children:[m.jsx(Xt,{$size:o,$delay:0}),m.jsx(Xt,{$size:o,$delay:.15}),m.jsx(Xt,{$size:o,$delay:.3})]}),Bn=24,zn="Loading",Wn=qe.keyframes`
20
20
  to {
21
21
  transform: rotate(1turn);
22
22
  }
23
- `,Ar=e=>Math.max(2,Math.round(e/10)),An=O.span`
23
+ `,zr=e=>Math.max(2,Math.round(e/10)),Vn=I.span`
24
24
  display: inline-block;
25
25
  width: ${({$size:e})=>e}px;
26
26
  aspect-ratio: 1;
@@ -33,7 +33,7 @@
33
33
  position: absolute;
34
34
  inset: 0;
35
35
  border-radius: 50%;
36
- border: ${({$size:e})=>Ar(e)}px solid currentColor;
36
+ border: ${({$size:e})=>zr(e)}px solid currentColor;
37
37
  opacity: 0.2;
38
38
  }
39
39
 
@@ -43,11 +43,11 @@
43
43
  position: absolute;
44
44
  inset: 0;
45
45
  border-radius: 50%;
46
- border: ${({$size:e})=>Ar(e)}px solid transparent;
46
+ border: ${({$size:e})=>zr(e)}px solid transparent;
47
47
  border-right-color: currentColor;
48
- animation: ${$n} 0.8s linear infinite;
48
+ animation: ${Wn} 0.8s linear infinite;
49
49
  }
50
- `,Mn=w.classNameGetter("spinner"),ko=({"aria-label":e=Tn,className:t,classnames:r,size:o=On,...n})=>w.jsx(An,{...n,className:Mn("container",t,r==null?void 0:r.container),role:"status","aria-label":e,$size:o}),Pn="primary",ge=(e,t)=>e.button[t],Dn=O.button`
50
+ `,Hn=m.classNameGetter("spinner"),Fo=({"aria-label":e=zn,className:t,classnames:r,size:o=Bn,...i})=>m.jsx(Vn,{...i,className:Hn("container",t,r==null?void 0:r.container),role:"status","aria-label":e,$size:o}),Un="primary",pe=(e,t)=>e.button[t],Kn=I.button`
51
51
  display: inline-flex;
52
52
  align-items: center;
53
53
  justify-content: center;
@@ -68,54 +68,54 @@
68
68
  width: ${({$fullWidth:e})=>e?"100%":"auto"};
69
69
  min-width: ${({$iconOnly:e})=>e?"32px":"auto"};
70
70
 
71
- color: ${({theme:e,$variant:t})=>ge(e,t).color};
72
- background-color: ${({theme:e,$variant:t})=>ge(e,t).backgroundColor};
73
- border-color: ${({theme:e,$variant:t})=>ge(e,t).borderColor};
71
+ color: ${({theme:e,$variant:t})=>pe(e,t).color};
72
+ background-color: ${({theme:e,$variant:t})=>pe(e,t).backgroundColor};
73
+ border-color: ${({theme:e,$variant:t})=>pe(e,t).borderColor};
74
74
 
75
75
  &:hover:not(:disabled) {
76
- background-color: ${({theme:e,$variant:t})=>ge(e,t).hover.backgroundColor};
77
- border-color: ${({theme:e,$variant:t})=>ge(e,t).hover.borderColor};
76
+ background-color: ${({theme:e,$variant:t})=>pe(e,t).hover.backgroundColor};
77
+ border-color: ${({theme:e,$variant:t})=>pe(e,t).hover.borderColor};
78
78
  }
79
79
 
80
80
  &:active:not(:disabled) {
81
- background-color: ${({theme:e,$variant:t})=>ge(e,t).active.backgroundColor};
82
- border-color: ${({theme:e,$variant:t})=>ge(e,t).active.borderColor};
81
+ background-color: ${({theme:e,$variant:t})=>pe(e,t).active.backgroundColor};
82
+ border-color: ${({theme:e,$variant:t})=>pe(e,t).active.borderColor};
83
83
  }
84
84
 
85
85
  &:focus-visible {
86
86
  outline: 2px solid
87
- ${({theme:e,$variant:t})=>ge(e,t).focus.outlineColor};
87
+ ${({theme:e,$variant:t})=>pe(e,t).focus.outlineColor};
88
88
  outline-offset: 1px;
89
89
  }
90
90
 
91
91
  &:disabled {
92
92
  cursor: ${({$loading:e})=>e?"wait":"not-allowed"};
93
- color: ${({theme:e,$variant:t})=>ge(e,t).disabled.color};
94
- background-color: ${({theme:e,$variant:t})=>ge(e,t).disabled.backgroundColor};
95
- border-color: ${({theme:e,$variant:t})=>ge(e,t).disabled.borderColor};
93
+ color: ${({theme:e,$variant:t})=>pe(e,t).disabled.color};
94
+ background-color: ${({theme:e,$variant:t})=>pe(e,t).disabled.backgroundColor};
95
+ border-color: ${({theme:e,$variant:t})=>pe(e,t).disabled.borderColor};
96
96
  }
97
- `,Ln=O.span`
97
+ `,Gn=I.span`
98
98
  position: relative;
99
99
  display: inline-flex;
100
100
  align-items: center;
101
101
  gap: 6px;
102
- `,Nn=O.span`
102
+ `,qn=I.span`
103
103
  display: inline-flex;
104
104
  align-items: center;
105
105
  justify-content: center;
106
106
  flex-shrink: 0;
107
107
  visibility: ${({$loading:e})=>e?"hidden":"visible"};
108
- color: ${({theme:e,$variant:t})=>ge(e,t).icon.color};
108
+ color: ${({theme:e,$variant:t})=>pe(e,t).icon.color};
109
109
 
110
110
  button:disabled & {
111
- color: ${({theme:e,$variant:t})=>ge(e,t).disabled.color};
111
+ color: ${({theme:e,$variant:t})=>pe(e,t).disabled.color};
112
112
  }
113
- `,Fn=O.span`
113
+ `,Xn=I.span`
114
114
  overflow: hidden;
115
115
  white-space: nowrap;
116
116
  text-overflow: ellipsis;
117
117
  visibility: ${({$loading:e})=>e?"hidden":"visible"};
118
- `,_n=O.span`
118
+ `,Yn=I.span`
119
119
  display: inline-flex;
120
120
  align-items: center;
121
121
  justify-content: center;
@@ -125,40 +125,40 @@
125
125
  font-weight: 600;
126
126
  line-height: 1.5;
127
127
  visibility: ${({$loading:e})=>e?"hidden":"visible"};
128
- color: ${({theme:e,$variant:t})=>ge(e,t).char.color};
129
- background-color: ${({theme:e,$variant:t})=>ge(e,t).char.backgroundColor};
128
+ color: ${({theme:e,$variant:t})=>pe(e,t).char.color};
129
+ background-color: ${({theme:e,$variant:t})=>pe(e,t).char.backgroundColor};
130
130
 
131
131
  button:disabled & {
132
- color: ${({theme:e,$variant:t})=>ge(e,t).disabled.color};
132
+ color: ${({theme:e,$variant:t})=>pe(e,t).disabled.color};
133
133
  background-color: transparent;
134
134
  }
135
- `,Mr=O.span`
135
+ `,Wr=I.span`
136
136
  position: absolute;
137
137
  inset: 0;
138
138
  display: inline-flex;
139
139
  align-items: center;
140
140
  justify-content: center;
141
- `,jn=(e,t,r,o,n)=>{const s=X.useMemo(()=>!!e&&!t&&!r,[e,t,r]),l=X.useMemo(()=>o&&s,[o,s]),c=X.useMemo(()=>o&&!s,[o,s]),d=X.useCallback(a=>{if(o){a.preventDefault();return}n==null||n(a)},[o,n]);return{iconOnly:s,showSpinner:l,showDots:c,handleClick:d}},ze=w.classNameGetter("button"),zn=18,Bn=({char:e,children:t,className:r,classnames:o,disabled:n,fullWidth:s,icon:l,loading:c,onClick:d,variant:a=Pn,...u})=>{const{iconOnly:g,showSpinner:f,showDots:p,handleClick:x}=jn(l,t,e,c,d),h=()=>l?w.jsx(Nn,{className:ze("icon",o==null?void 0:o.icon),$variant:a,$loading:c,children:l}):null,y=()=>f?w.jsx(Mr,{className:ze("loader",o==null?void 0:o.loader),children:w.jsx(ko,{size:zn})}):p?w.jsx(Mr,{className:ze("loader",o==null?void 0:o.loader),children:w.jsx(yo,{size:4})}):null;return w.jsx(Dn,{...u,className:ze("container",r,o==null?void 0:o.container),disabled:n||c,onClick:x,$variant:a,$fullWidth:s,$loading:c,$iconOnly:g,children:w.jsxs(Ln,{className:ze("content",o==null?void 0:o.content),children:[h(),y(),t&&w.jsx(Fn,{className:ze("text",o==null?void 0:o.text),$loading:c,children:t}),e&&w.jsx(_n,{className:ze("char",o==null?void 0:o.char),$variant:a,$loading:c,children:e})]})})},Wn=(e,t,r,o)=>t||r?o==="warning"?e.checkbox.state.warning.box.checked.borderColor:o==="error"?e.checkbox.state.error.box.checked.borderColor:e.checkbox.box.checked.borderColor:o==="warning"?e.checkbox.state.warning.box.borderColor:o==="error"?e.checkbox.state.error.box.borderColor:e.checkbox.box.borderColor,Vn=(e,t,r,o)=>t||r?o==="warning"?e.checkbox.state.warning.box.checked.backgroundColor:o==="error"?e.checkbox.state.error.box.checked.backgroundColor:e.checkbox.box.checked.backgroundColor:e.checkbox.box.backgroundColor,Hn=(e,t)=>t==="warning"?e.checkbox.state.warning.box.focus.shadowColor:t==="error"?e.checkbox.state.error.box.focus.shadowColor:e.checkbox.box.focus.shadowColor,Un=(e,t)=>t==="warning"?e.checkbox.state.warning.label.color:t==="error"?e.checkbox.state.error.label.color:e.checkbox.label.color,Gn=O.label`
141
+ `,Qn=(e,t,r,o,i)=>{const c=_.useMemo(()=>!!e&&!t&&!r,[e,t,r]),l=_.useMemo(()=>o&&c,[o,c]),s=_.useMemo(()=>o&&!c,[o,c]),d=_.useCallback(a=>{if(o){a.preventDefault();return}i==null||i(a)},[o,i]);return{iconOnly:c,showSpinner:l,showDots:s,handleClick:d}},Ve=m.classNameGetter("button"),Zn=18,Jn=({char:e,children:t,className:r,classnames:o,disabled:i,fullWidth:c,icon:l,loading:s,onClick:d,variant:a=Un,...u})=>{const{iconOnly:h,showSpinner:f,showDots:b,handleClick:C}=Qn(l,t,e,s,d),g=()=>l?m.jsx(qn,{className:Ve("icon",o==null?void 0:o.icon),$variant:a,$loading:s,children:l}):null,y=()=>f?m.jsx(Wr,{className:Ve("loader",o==null?void 0:o.loader),children:m.jsx(Fo,{size:Zn})}):b?m.jsx(Wr,{className:Ve("loader",o==null?void 0:o.loader),children:m.jsx(No,{size:4})}):null;return m.jsx(Kn,{...u,className:Ve("container",r,o==null?void 0:o.container),disabled:i||s,onClick:C,$variant:a,$fullWidth:c,$loading:s,$iconOnly:h,children:m.jsxs(Gn,{className:Ve("content",o==null?void 0:o.content),children:[g(),y(),t&&m.jsx(Xn,{className:Ve("text",o==null?void 0:o.text),$loading:s,children:t}),e&&m.jsx(Yn,{className:Ve("char",o==null?void 0:o.char),$variant:a,$loading:s,children:e})]})})},ei=(e,t,r,o)=>t||r?o==="warning"?e.checkbox.state.warning.box.checked.borderColor:o==="error"?e.checkbox.state.error.box.checked.borderColor:e.checkbox.box.checked.borderColor:o==="warning"?e.checkbox.state.warning.box.borderColor:o==="error"?e.checkbox.state.error.box.borderColor:e.checkbox.box.borderColor,ti=(e,t,r,o)=>t||r?o==="warning"?e.checkbox.state.warning.box.checked.backgroundColor:o==="error"?e.checkbox.state.error.box.checked.backgroundColor:e.checkbox.box.checked.backgroundColor:e.checkbox.box.backgroundColor,ri=(e,t)=>t==="warning"?e.checkbox.state.warning.box.focus.shadowColor:t==="error"?e.checkbox.state.error.box.focus.shadowColor:e.checkbox.box.focus.shadowColor,oi=(e,t)=>t==="warning"?e.checkbox.state.warning.label.color:t==="error"?e.checkbox.state.error.label.color:e.checkbox.label.color,ni=I.label`
142
142
  display: inline-flex;
143
143
  align-items: center;
144
144
  gap: 8px;
145
145
  cursor: pointer;
146
146
 
147
147
  &:has(input:focus-visible) > span:first-of-type {
148
- box-shadow: 0 0 0 3px ${({theme:e,$state:t})=>Hn(e,t)};
148
+ box-shadow: 0 0 0 3px ${({theme:e,$state:t})=>ri(e,t)};
149
149
  }
150
150
 
151
151
  ${({$disabled:e})=>e&&`
152
152
  opacity: 0.5;
153
153
  cursor: not-allowed;
154
154
  `}
155
- `,Kn=O.input`
155
+ `,ii=I.input`
156
156
  position: absolute;
157
157
  opacity: 0;
158
158
  width: 0;
159
159
  height: 0;
160
160
  pointer-events: none;
161
- `,qn=O.span`
161
+ `,li=I.span`
162
162
  display: inline-flex;
163
163
  align-items: center;
164
164
  justify-content: center;
@@ -166,13 +166,13 @@
166
166
  height: 18px;
167
167
  border-radius: 6px;
168
168
  border: 1.5px solid
169
- ${({theme:e,$checked:t,$indeterminate:r,$state:o})=>Wn(e,t,r,o)};
170
- background-color: ${({theme:e,$checked:t,$indeterminate:r,$state:o})=>Vn(e,t,r,o)};
169
+ ${({theme:e,$checked:t,$indeterminate:r,$state:o})=>ei(e,t,r,o)};
170
+ background-color: ${({theme:e,$checked:t,$indeterminate:r,$state:o})=>ti(e,t,r,o)};
171
171
  transition:
172
172
  border-color 0.15s ease,
173
173
  background-color 0.15s ease,
174
174
  box-shadow 0.15s ease;
175
- `,Xn=O.span`
175
+ `,ci=I.span`
176
176
  display: inline-flex;
177
177
  align-items: center;
178
178
  justify-content: center;
@@ -182,13 +182,13 @@
182
182
  transition:
183
183
  opacity 0.15s ease,
184
184
  transform 0.15s ease;
185
- `,Yn=O.span`
185
+ `,si=I.span`
186
186
  font-size: 14px;
187
187
  line-height: 1.5;
188
- color: ${({theme:e,$state:t})=>Un(e,t)};
188
+ color: ${({theme:e,$state:t})=>oi(e,t)};
189
189
  user-select: none;
190
190
  font-weight: 500;
191
- `,nt=w.classNameGetter("checkbox"),br=({checked:e,className:t,classnames:r,disabled:o,indeterminate:n,label:s,onChange:l,ref:c,state:d,...a})=>w.jsxs(Gn,{className:nt("container",t,r==null?void 0:r.container),$disabled:o,$state:d,children:[w.jsx(Kn,{...a,ref:c,type:"checkbox",className:nt("input",r==null?void 0:r.input),checked:e,disabled:o,onChange:l}),w.jsx(qn,{className:nt("box",r==null?void 0:r.box),$checked:e,$indeterminate:n,$state:d,children:w.jsx(Xn,{className:nt("icon",r==null?void 0:r.icon),$visible:n||e,children:n?w.jsx(w.Minus,{}):w.jsx(w.Check,{})})}),s&&w.jsx(Yn,{className:nt("label",r==null?void 0:r.label),$state:d,children:s})]}),Zn=(e,t)=>{switch(t){case"neutral":return e.chip.color.neutral;case"success":return e.chip.color.success;case"warning":return e.chip.color.warning;case"error":return e.chip.color.error;default:return e.chip.color.default}},Qn=(e,t)=>{switch(t){case"neutral":return e.chip.backgroundColor.neutral;case"success":return e.chip.backgroundColor.success;case"warning":return e.chip.backgroundColor.warning;case"error":return e.chip.backgroundColor.error;default:return e.chip.backgroundColor.default}},Jn=O.span`
191
+ `,ct=m.classNameGetter("checkbox"),mr=({checked:e,className:t,classnames:r,disabled:o,indeterminate:i,label:c,onChange:l,ref:s,state:d,...a})=>m.jsxs(ni,{className:ct("container",t,r==null?void 0:r.container),$disabled:o,$state:d,children:[m.jsx(ii,{...a,ref:s,type:"checkbox",className:ct("input",r==null?void 0:r.input),checked:e,disabled:o,onChange:l}),m.jsx(li,{className:ct("box",r==null?void 0:r.box),$checked:e,$indeterminate:i,$state:d,children:m.jsx(ci,{className:ct("icon",r==null?void 0:r.icon),$visible:i||e,children:i?m.jsx(m.Minus,{}):m.jsx(m.Check,{})})}),c&&m.jsx(si,{className:ct("label",r==null?void 0:r.label),$state:d,children:c})]}),ai=(e,t)=>{switch(t){case"neutral":return e.chip.color.neutral;case"success":return e.chip.color.success;case"warning":return e.chip.color.warning;case"error":return e.chip.color.error;default:return e.chip.color.default}},ui=(e,t)=>{switch(t){case"neutral":return e.chip.backgroundColor.neutral;case"success":return e.chip.backgroundColor.success;case"warning":return e.chip.backgroundColor.warning;case"error":return e.chip.backgroundColor.error;default:return e.chip.backgroundColor.default}},di=I.span`
192
192
  display: inline-flex;
193
193
  align-items: center;
194
194
  justify-content: center;
@@ -200,84 +200,84 @@
200
200
  font-weight: 600;
201
201
  min-width: 0;
202
202
  max-width: ${({$fullWidth:e})=>e?"none":"200px"};
203
- color: ${({theme:e,$status:t})=>Zn(e,t)};
204
- background-color: ${({theme:e,$status:t})=>Qn(e,t)};
205
- `,ei=O.span`
203
+ color: ${({theme:e,$status:t})=>ai(e,t)};
204
+ background-color: ${({theme:e,$status:t})=>ui(e,t)};
205
+ `,fi=I.span`
206
206
  overflow: hidden;
207
207
  text-overflow: ellipsis;
208
208
  white-space: nowrap;
209
- `,Pr=w.classNameGetter("chip"),ti=({children:e,className:t,classnames:r,fullWidth:o,status:n,...s})=>w.jsx(Jn,{...s,className:Pr("container",t,r==null?void 0:r.container),$fullWidth:o,$status:n,children:w.jsx(ei,{className:Pr("text",r==null?void 0:r.text),children:e})}),Ro="bottom",So="start",Eo=4,ri=e=>e.dropdown.content.backgroundColor,oi=e=>e.dropdown.content.borderColor,ni=e=>e.dropdown.content.shadow,ii=O.div`
209
+ `,Vr=m.classNameGetter("chip"),gi=({children:e,className:t,classnames:r,fullWidth:o,status:i,...c})=>m.jsx(di,{...c,className:Vr("container",t,r==null?void 0:r.container),$fullWidth:o,$status:i,children:m.jsx(fi,{className:Vr("text",r==null?void 0:r.text),children:e})}),_o="bottom",jo="start",Bo=4,hi=e=>e.dropdown.content.backgroundColor,pi=e=>e.dropdown.content.borderColor,bi=e=>e.dropdown.content.shadow,xi=I.div`
210
210
  display: inline-block;
211
211
  position: relative;
212
212
  min-width: 0;
213
213
  width: ${({$fullWidth:e})=>e?"100%":"auto"};
214
- `,li=O.div`
214
+ `,mi=I.div`
215
215
  display: inline-flex;
216
216
  min-width: 0;
217
217
  width: ${({$fullWidth:e})=>e?"100%":"auto"};
218
- `,si=O.div`
218
+ `,Ci=I.div`
219
219
  z-index: 1000;
220
220
  width: max-content;
221
221
  border-radius: 12px;
222
- border: 1px solid ${({theme:e})=>oi(e)};
223
- background-color: ${({theme:e})=>ri(e)};
224
- box-shadow: ${({theme:e})=>ni(e)};
222
+ border: 1px solid ${({theme:e})=>pi(e)};
223
+ background-color: ${({theme:e})=>hi(e)};
224
+ box-shadow: ${({theme:e})=>bi(e)};
225
225
  visibility: ${({$isOpen:e})=>e?"visible":"hidden"};
226
226
  opacity: ${({$isOpen:e})=>e?1:0};
227
227
  pointer-events: ${({$isOpen:e})=>e?"auto":"none"};
228
228
  transition:
229
229
  opacity 0.15s ease,
230
230
  visibility 0.15s ease;
231
- `;function _t(){return typeof window<"u"}function _e(e){return Io(e)?(e.nodeName||"").toLowerCase():"#document"}function Ce(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ie(e){var t;return(t=(Io(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Io(e){return _t()?e instanceof Node||e instanceof Ce(e).Node:!1}function re(e){return _t()?e instanceof Element||e instanceof Ce(e).Element:!1}function le(e){return _t()?e instanceof HTMLElement||e instanceof Ce(e).HTMLElement:!1}function cr(e){return!_t()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ce(e).ShadowRoot}const ci=new Set(["inline","contents"]);function at(e){const{overflow:t,overflowX:r,overflowY:o,display:n}=ye(e);return/auto|scroll|overlay|hidden|clip/.test(t+o+r)&&!ci.has(n)}const ai=new Set(["table","td","th"]);function ui(e){return ai.has(_e(e))}const di=[":popover-open",":modal"];function jt(e){return di.some(t=>{try{return e.matches(t)}catch{return!1}})}const fi=["transform","translate","scale","rotate","perspective"],gi=["transform","translate","scale","rotate","perspective","filter"],hi=["paint","layout","strict","content"];function xr(e){const t=zt(),r=re(e)?ye(e):e;return fi.some(o=>r[o]?r[o]!=="none":!1)||(r.containerType?r.containerType!=="normal":!1)||!t&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!t&&(r.filter?r.filter!=="none":!1)||gi.some(o=>(r.willChange||"").includes(o))||hi.some(o=>(r.contain||"").includes(o))}function pi(e){let t=Ae(e);for(;le(t)&&!$e(t);){if(xr(t))return t;if(jt(t))return null;t=Ae(t)}return null}function zt(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const bi=new Set(["html","body","#document"]);function $e(e){return bi.has(_e(e))}function ye(e){return Ce(e).getComputedStyle(e)}function Bt(e){return re(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Ae(e){if(_e(e)==="html")return e;const t=e.assignedSlot||e.parentNode||cr(e)&&e.host||Ie(e);return cr(t)?t.host:t}function Oo(e){const t=Ae(e);return $e(t)?e.ownerDocument?e.ownerDocument.body:e.body:le(t)&&at(t)?t:Oo(t)}function Ne(e,t,r){var o;t===void 0&&(t=[]),r===void 0&&(r=!0);const n=Oo(e),s=n===((o=e.ownerDocument)==null?void 0:o.body),l=Ce(n);if(s){const c=ar(l);return t.concat(l,l.visualViewport||[],at(n)?n:[],c&&r?Ne(c):[])}return t.concat(n,Ne(n,[],r))}function ar(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}const Je=Math.min,me=Math.max,Et=Math.round,Ye=Math.floor,Ee=e=>({x:e,y:e}),xi={left:"right",right:"left",bottom:"top",top:"bottom"},mi={start:"end",end:"start"};function Dr(e,t,r){return me(e,Je(t,r))}function ut(e,t){return typeof e=="function"?e(t):e}function Fe(e){return e.split("-")[0]}function dt(e){return e.split("-")[1]}function To(e){return e==="x"?"y":"x"}function $o(e){return e==="y"?"height":"width"}const Ci=new Set(["top","bottom"]);function Te(e){return Ci.has(Fe(e))?"y":"x"}function Ao(e){return To(Te(e))}function vi(e,t,r){r===void 0&&(r=!1);const o=dt(e),n=Ao(e),s=$o(n);let l=n==="x"?o===(r?"end":"start")?"right":"left":o==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(l=It(l)),[l,It(l)]}function wi(e){const t=It(e);return[ur(e),t,ur(t)]}function ur(e){return e.replace(/start|end/g,t=>mi[t])}const Lr=["left","right"],Nr=["right","left"],yi=["top","bottom"],ki=["bottom","top"];function Ri(e,t,r){switch(e){case"top":case"bottom":return r?t?Nr:Lr:t?Lr:Nr;case"left":case"right":return t?yi:ki;default:return[]}}function Si(e,t,r,o){const n=dt(e);let s=Ri(Fe(e),r==="start",o);return n&&(s=s.map(l=>l+"-"+n),t&&(s=s.concat(s.map(ur)))),s}function It(e){return e.replace(/left|right|bottom|top/g,t=>xi[t])}function Ei(e){return{top:0,right:0,bottom:0,left:0,...e}}function Ii(e){return typeof e!="number"?Ei(e):{top:e,right:e,bottom:e,left:e}}function Ot(e){const{x:t,y:r,width:o,height:n}=e;return{width:o,height:n,top:r,left:t,right:t+o,bottom:r+n,x:t,y:r}}/*!
231
+ `;function Bt(){return typeof window<"u"}function ze(e){return zo(e)?(e.nodeName||"").toLowerCase():"#document"}function ye(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Me(e){var t;return(t=(zo(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function zo(e){return Bt()?e instanceof Node||e instanceof ye(e).Node:!1}function ie(e){return Bt()?e instanceof Element||e instanceof ye(e).Element:!1}function se(e){return Bt()?e instanceof HTMLElement||e instanceof ye(e).HTMLElement:!1}function ur(e){return!Bt()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof ye(e).ShadowRoot}const vi=new Set(["inline","contents"]);function gt(e){const{overflow:t,overflowX:r,overflowY:o,display:i}=Re(e);return/auto|scroll|overlay|hidden|clip/.test(t+o+r)&&!vi.has(i)}const wi=new Set(["table","td","th"]);function yi(e){return wi.has(ze(e))}const ki=[":popover-open",":modal"];function zt(e){return ki.some(t=>{try{return e.matches(t)}catch{return!1}})}const Si=["transform","translate","scale","rotate","perspective"],Ri=["transform","translate","scale","rotate","perspective","filter"],Ei=["paint","layout","strict","content"];function Cr(e){const t=Wt(),r=ie(e)?Re(e):e;return Si.some(o=>r[o]?r[o]!=="none":!1)||(r.containerType?r.containerType!=="normal":!1)||!t&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!t&&(r.filter?r.filter!=="none":!1)||Ri.some(o=>(r.willChange||"").includes(o))||Ei.some(o=>(r.contain||"").includes(o))}function $i(e){let t=De(e);for(;se(t)&&!Pe(t);){if(Cr(t))return t;if(zt(t))return null;t=De(t)}return null}function Wt(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const Ii=new Set(["html","body","#document"]);function Pe(e){return Ii.has(ze(e))}function Re(e){return ye(e).getComputedStyle(e)}function Vt(e){return ie(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function De(e){if(ze(e)==="html")return e;const t=e.assignedSlot||e.parentNode||ur(e)&&e.host||Me(e);return ur(t)?t.host:t}function Wo(e){const t=De(e);return Pe(t)?e.ownerDocument?e.ownerDocument.body:e.body:se(t)&&gt(t)?t:Wo(t)}function je(e,t,r){var o;t===void 0&&(t=[]),r===void 0&&(r=!0);const i=Wo(e),c=i===((o=e.ownerDocument)==null?void 0:o.body),l=ye(i);if(c){const s=dr(l);return t.concat(l,l.visualViewport||[],gt(i)?i:[],s&&r?je(s):[])}return t.concat(i,je(i,[],r))}function dr(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}const ot=Math.min,we=Math.max,Ot=Math.round,et=Math.floor,Oe=e=>({x:e,y:e}),Ti={left:"right",right:"left",bottom:"top",top:"bottom"},Oi={start:"end",end:"start"};function Hr(e,t,r){return we(e,ot(t,r))}function ht(e,t){return typeof e=="function"?e(t):e}function Be(e){return e.split("-")[0]}function pt(e){return e.split("-")[1]}function Vo(e){return e==="x"?"y":"x"}function Ho(e){return e==="y"?"height":"width"}const Mi=new Set(["top","bottom"]);function Ae(e){return Mi.has(Be(e))?"y":"x"}function Uo(e){return Vo(Ae(e))}function Ai(e,t,r){r===void 0&&(r=!1);const o=pt(e),i=Uo(e),c=Ho(i);let l=i==="x"?o===(r?"end":"start")?"right":"left":o==="start"?"bottom":"top";return t.reference[c]>t.floating[c]&&(l=Mt(l)),[l,Mt(l)]}function Pi(e){const t=Mt(e);return[fr(e),t,fr(t)]}function fr(e){return e.replace(/start|end/g,t=>Oi[t])}const Ur=["left","right"],Kr=["right","left"],Di=["top","bottom"],Li=["bottom","top"];function Ni(e,t,r){switch(e){case"top":case"bottom":return r?t?Kr:Ur:t?Ur:Kr;case"left":case"right":return t?Di:Li;default:return[]}}function Fi(e,t,r,o){const i=pt(e);let c=Ni(Be(e),r==="start",o);return i&&(c=c.map(l=>l+"-"+i),t&&(c=c.concat(c.map(fr)))),c}function Mt(e){return e.replace(/left|right|bottom|top/g,t=>Ti[t])}function _i(e){return{top:0,right:0,bottom:0,left:0,...e}}function ji(e){return typeof e!="number"?_i(e):{top:e,right:e,bottom:e,left:e}}function At(e){const{x:t,y:r,width:o,height:i}=e;return{width:o,height:i,top:r,left:t,right:t+o,bottom:r+i,x:t,y:r}}/*!
232
232
  * tabbable 6.3.0
233
233
  * @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE
234
- */var Oi=["input:not([inert])","select:not([inert])","textarea:not([inert])","a[href]:not([inert])","button:not([inert])","[tabindex]:not(slot):not([inert])","audio[controls]:not([inert])","video[controls]:not([inert])",'[contenteditable]:not([contenteditable="false"]):not([inert])',"details>summary:first-of-type:not([inert])","details:not([inert])"],Tt=Oi.join(","),Mo=typeof Element>"u",et=Mo?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,$t=!Mo&&Element.prototype.getRootNode?function(e){var t;return e==null||(t=e.getRootNode)===null||t===void 0?void 0:t.call(e)}:function(e){return e==null?void 0:e.ownerDocument},st=function(t,r){var o;r===void 0&&(r=!0);var n=t==null||(o=t.getAttribute)===null||o===void 0?void 0:o.call(t,"inert"),s=n===""||n==="true",l=s||r&&t&&st(t.parentNode);return l},Ti=function(t){var r,o=t==null||(r=t.getAttribute)===null||r===void 0?void 0:r.call(t,"contenteditable");return o===""||o==="true"},Po=function(t,r,o){if(st(t))return[];var n=Array.prototype.slice.apply(t.querySelectorAll(Tt));return r&&et.call(t,Tt)&&n.unshift(t),n=n.filter(o),n},At=function(t,r,o){for(var n=[],s=Array.from(t);s.length;){var l=s.shift();if(!st(l,!1))if(l.tagName==="SLOT"){var c=l.assignedElements(),d=c.length?c:l.children,a=At(d,!0,o);o.flatten?n.push.apply(n,a):n.push({scopeParent:l,candidates:a})}else{var u=et.call(l,Tt);u&&o.filter(l)&&(r||!t.includes(l))&&n.push(l);var g=l.shadowRoot||typeof o.getShadowRoot=="function"&&o.getShadowRoot(l),f=!st(g,!1)&&(!o.shadowRootFilter||o.shadowRootFilter(l));if(g&&f){var p=At(g===!0?l.children:g.children,!0,o);o.flatten?n.push.apply(n,p):n.push({scopeParent:l,candidates:p})}else s.unshift.apply(s,l.children)}}return n},Do=function(t){return!isNaN(parseInt(t.getAttribute("tabindex"),10))},Lo=function(t){if(!t)throw new Error("No node provided");return t.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(t.tagName)||Ti(t))&&!Do(t)?0:t.tabIndex},$i=function(t,r){var o=Lo(t);return o<0&&r&&!Do(t)?0:o},Ai=function(t,r){return t.tabIndex===r.tabIndex?t.documentOrder-r.documentOrder:t.tabIndex-r.tabIndex},No=function(t){return t.tagName==="INPUT"},Mi=function(t){return No(t)&&t.type==="hidden"},Pi=function(t){var r=t.tagName==="DETAILS"&&Array.prototype.slice.apply(t.children).some(function(o){return o.tagName==="SUMMARY"});return r},Di=function(t,r){for(var o=0;o<t.length;o++)if(t[o].checked&&t[o].form===r)return t[o]},Li=function(t){if(!t.name)return!0;var r=t.form||$t(t),o=function(c){return r.querySelectorAll('input[type="radio"][name="'+c+'"]')},n;if(typeof window<"u"&&typeof window.CSS<"u"&&typeof window.CSS.escape=="function")n=o(window.CSS.escape(t.name));else try{n=o(t.name)}catch(l){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",l.message),!1}var s=Di(n,t.form);return!s||s===t},Ni=function(t){return No(t)&&t.type==="radio"},Fi=function(t){return Ni(t)&&!Li(t)},_i=function(t){var r,o=t&&$t(t),n=(r=o)===null||r===void 0?void 0:r.host,s=!1;if(o&&o!==t){var l,c,d;for(s=!!((l=n)!==null&&l!==void 0&&(c=l.ownerDocument)!==null&&c!==void 0&&c.contains(n)||t!=null&&(d=t.ownerDocument)!==null&&d!==void 0&&d.contains(t));!s&&n;){var a,u,g;o=$t(n),n=(a=o)===null||a===void 0?void 0:a.host,s=!!((u=n)!==null&&u!==void 0&&(g=u.ownerDocument)!==null&&g!==void 0&&g.contains(n))}}return s},Fr=function(t){var r=t.getBoundingClientRect(),o=r.width,n=r.height;return o===0&&n===0},ji=function(t,r){var o=r.displayCheck,n=r.getShadowRoot;if(o==="full-native"&&"checkVisibility"in t){var s=t.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});return!s}if(getComputedStyle(t).visibility==="hidden")return!0;var l=et.call(t,"details>summary:first-of-type"),c=l?t.parentElement:t;if(et.call(c,"details:not([open]) *"))return!0;if(!o||o==="full"||o==="full-native"||o==="legacy-full"){if(typeof n=="function"){for(var d=t;t;){var a=t.parentElement,u=$t(t);if(a&&!a.shadowRoot&&n(a)===!0)return Fr(t);t.assignedSlot?t=t.assignedSlot:!a&&u!==t.ownerDocument?t=u.host:t=a}t=d}if(_i(t))return!t.getClientRects().length;if(o!=="legacy-full")return!0}else if(o==="non-zero-area")return Fr(t);return!1},zi=function(t){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(t.tagName))for(var r=t.parentElement;r;){if(r.tagName==="FIELDSET"&&r.disabled){for(var o=0;o<r.children.length;o++){var n=r.children.item(o);if(n.tagName==="LEGEND")return et.call(r,"fieldset[disabled] *")?!0:!n.contains(t)}return!0}r=r.parentElement}return!1},dr=function(t,r){return!(r.disabled||st(r)||Mi(r)||ji(r,t)||Pi(r)||zi(r))},fr=function(t,r){return!(Fi(r)||Lo(r)<0||!dr(t,r))},Bi=function(t){var r=parseInt(t.getAttribute("tabindex"),10);return!!(isNaN(r)||r>=0)},Fo=function(t){var r=[],o=[];return t.forEach(function(n,s){var l=!!n.scopeParent,c=l?n.scopeParent:n,d=$i(c,l),a=l?Fo(n.candidates):c;d===0?l?r.push.apply(r,a):r.push(c):o.push({documentOrder:s,tabIndex:d,item:n,isScope:l,content:a})}),o.sort(Ai).reduce(function(n,s){return s.isScope?n.push.apply(n,s.content):n.push(s.content),n},[]).concat(r)},mr=function(t,r){r=r||{};var o;return r.getShadowRoot?o=At([t],r.includeContainer,{filter:fr.bind(null,r),flatten:!1,getShadowRoot:r.getShadowRoot,shadowRootFilter:Bi}):o=Po(t,r.includeContainer,fr.bind(null,r)),Fo(o)},Wi=function(t,r){r=r||{};var o;return r.getShadowRoot?o=At([t],r.includeContainer,{filter:dr.bind(null,r),flatten:!0,getShadowRoot:r.getShadowRoot}):o=Po(t,r.includeContainer,dr.bind(null,r)),o},_o=function(t,r){if(r=r||{},!t)throw new Error("No node provided");return et.call(t,Tt)===!1?!1:fr(r,t)};function Vi(){const e=navigator.userAgentData;return e!=null&&e.platform?e.platform:navigator.platform}function jo(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(t=>{let{brand:r,version:o}=t;return r+"/"+o}).join(" "):navigator.userAgent}function Hi(){return/apple/i.test(navigator.vendor)}function gr(){const e=/android/i;return e.test(Vi())||e.test(jo())}function Ui(){return jo().includes("jsdom/")}const _r="data-floating-ui-focusable",Gi="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])",qt="ArrowLeft",Xt="ArrowRight",Ki="ArrowUp",qi="ArrowDown";function Pe(e){let t=e.activeElement;for(;((r=t)==null||(r=r.shadowRoot)==null?void 0:r.activeElement)!=null;){var r;t=t.shadowRoot.activeElement}return t}function xe(e,t){if(!e||!t)return!1;const r=t.getRootNode==null?void 0:t.getRootNode();if(e.contains(t))return!0;if(r&&cr(r)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function De(e){return"composedPath"in e?e.composedPath()[0]:e.target}function Yt(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);const r=e;return r.target!=null&&t.contains(r.target)}function Xi(e){return e.matches("html,body")}function we(e){return(e==null?void 0:e.ownerDocument)||document}function zo(e){return le(e)&&e.matches(Gi)}function hr(e){return e?e.getAttribute("role")==="combobox"&&zo(e):!1}function Mt(e){return e?e.hasAttribute(_r)?e:e.querySelector("["+_r+"]")||e:null}function Ve(e,t,r){return r===void 0&&(r=!0),e.filter(n=>{var s;return n.parentId===t&&(!r||((s=n.context)==null?void 0:s.open))}).flatMap(n=>[n,...Ve(e,n.id,r)])}function Yi(e,t){let r,o=-1;function n(s,l){l>o&&(r=s,o=l),Ve(e,s).forEach(d=>{n(d.id,l+1)})}return n(t,0),e.find(s=>s.id===r)}function jr(e,t){var r;let o=[],n=(r=e.find(s=>s.id===t))==null?void 0:r.parentId;for(;n;){const s=e.find(l=>l.id===n);n=s==null?void 0:s.parentId,s&&(o=o.concat(s))}return o}function ae(e){e.preventDefault(),e.stopPropagation()}function Zi(e){return"nativeEvent"in e}function Bo(e){return e.mozInputSource===0&&e.isTrusted?!0:gr()&&e.pointerType?e.type==="click"&&e.buttons===1:e.detail===0&&!e.pointerType}function Wo(e){return Ui()?!1:!gr()&&e.width===0&&e.height===0||gr()&&e.width===1&&e.height===1&&e.pressure===0&&e.detail===0&&e.pointerType==="mouse"||e.width<1&&e.height<1&&e.pressure===0&&e.detail===0&&e.pointerType==="touch"}function zr(e,t){return["mouse","pen"].includes(e)}var Qi=typeof document<"u",Ji=function(){},se=Qi?X.useLayoutEffect:Ji;const el={...C};function Se(e){const t=C.useRef(e);return se(()=>{t.current=e}),t}const tl=el.useInsertionEffect,rl=tl||(e=>e());function ue(e){const t=C.useRef(()=>{if(process.env.NODE_ENV!=="production")throw new Error("Cannot call an event handler while rendering.")});return rl(()=>{t.current=e}),C.useCallback(function(){for(var r=arguments.length,o=new Array(r),n=0;n<r;n++)o[n]=arguments[n];return t.current==null?void 0:t.current(...o)},[])}function mt(e,t,r){return Math.floor(e/t)!==r}function lt(e,t){return t<0||t>=e.current.length}function Zt(e,t){return he(e,{disabledIndices:t})}function Br(e,t){return he(e,{decrement:!0,startingIndex:e.current.length,disabledIndices:t})}function he(e,t){let{startingIndex:r=-1,decrement:o=!1,disabledIndices:n,amount:s=1}=t===void 0?{}:t,l=r;do l+=o?-s:s;while(l>=0&&l<=e.current.length-1&&Rt(e,l,n));return l}function ol(e,t){let{event:r,orientation:o,loop:n,rtl:s,cols:l,disabledIndices:c,minIndex:d,maxIndex:a,prevIndex:u,stopEvent:g=!1}=t,f=u;if(r.key===Ki){if(g&&ae(r),u===-1)f=a;else if(f=he(e,{startingIndex:f,amount:l,decrement:!0,disabledIndices:c}),n&&(u-l<d||f<0)){const p=u%l,x=a%l,h=a-(x-p);x===p?f=a:f=x>p?h:h-l}lt(e,f)&&(f=u)}if(r.key===qi&&(g&&ae(r),u===-1?f=d:(f=he(e,{startingIndex:u,amount:l,disabledIndices:c}),n&&u+l>a&&(f=he(e,{startingIndex:u%l-l,amount:l,disabledIndices:c}))),lt(e,f)&&(f=u)),o==="both"){const p=Ye(u/l);r.key===(s?qt:Xt)&&(g&&ae(r),u%l!==l-1?(f=he(e,{startingIndex:u,disabledIndices:c}),n&&mt(f,l,p)&&(f=he(e,{startingIndex:u-u%l-1,disabledIndices:c}))):n&&(f=he(e,{startingIndex:u-u%l-1,disabledIndices:c})),mt(f,l,p)&&(f=u)),r.key===(s?Xt:qt)&&(g&&ae(r),u%l!==0?(f=he(e,{startingIndex:u,decrement:!0,disabledIndices:c}),n&&mt(f,l,p)&&(f=he(e,{startingIndex:u+(l-u%l),decrement:!0,disabledIndices:c}))):n&&(f=he(e,{startingIndex:u+(l-u%l),decrement:!0,disabledIndices:c})),mt(f,l,p)&&(f=u));const x=Ye(a/l)===p;lt(e,f)&&(n&&x?f=r.key===(s?Xt:qt)?a:he(e,{startingIndex:u-u%l-1,disabledIndices:c}):f=u)}return f}function nl(e,t,r){const o=[];let n=0;return e.forEach((s,l)=>{let{width:c,height:d}=s;if(c>t&&process.env.NODE_ENV!=="production")throw new Error("[Floating UI]: Invalid grid - item width at index "+l+" is greater than grid columns");let a=!1;for(r&&(n=0);!a;){const u=[];for(let g=0;g<c;g++)for(let f=0;f<d;f++)u.push(n+g+f*t);n%t+c<=t&&u.every(g=>o[g]==null)?(u.forEach(g=>{o[g]=l}),a=!0):n++}}),[...o]}function il(e,t,r,o,n){if(e===-1)return-1;const s=r.indexOf(e),l=t[e];switch(n){case"tl":return s;case"tr":return l?s+l.width-1:s;case"bl":return l?s+(l.height-1)*o:s;case"br":return r.lastIndexOf(e)}}function ll(e,t){return t.flatMap((r,o)=>e.includes(r)?[o]:[])}function Rt(e,t,r){if(typeof r=="function")return r(t);if(r)return r.includes(t);const o=e.current[t];return o==null||o.hasAttribute("disabled")||o.getAttribute("aria-disabled")==="true"}const Wt=()=>({getShadowRoot:!0,displayCheck:typeof ResizeObserver=="function"&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function Vo(e,t){const r=mr(e,Wt()),o=r.length;if(o===0)return;const n=Pe(we(e)),s=r.indexOf(n),l=s===-1?t===1?0:o-1:s+t;return r[l]}function sl(e){return Vo(we(e).body,1)||e}function cl(e){return Vo(we(e).body,-1)||e}function Wr(e,t){const r=t||e.currentTarget,o=e.relatedTarget;return!o||!xe(r,o)}function Vr(e,t,r){let{reference:o,floating:n}=e;const s=Te(t),l=Ao(t),c=$o(l),d=Fe(t),a=s==="y",u=o.x+o.width/2-n.width/2,g=o.y+o.height/2-n.height/2,f=o[c]/2-n[c]/2;let p;switch(d){case"top":p={x:u,y:o.y-n.height};break;case"bottom":p={x:u,y:o.y+o.height};break;case"right":p={x:o.x+o.width,y:g};break;case"left":p={x:o.x-n.width,y:g};break;default:p={x:o.x,y:o.y}}switch(dt(t)){case"start":p[l]-=f*(r&&a?-1:1);break;case"end":p[l]+=f*(r&&a?-1:1);break}return p}const al=async(e,t,r)=>{const{placement:o="bottom",strategy:n="absolute",middleware:s=[],platform:l}=r,c=s.filter(Boolean),d=await(l.isRTL==null?void 0:l.isRTL(t));let a=await l.getElementRects({reference:e,floating:t,strategy:n}),{x:u,y:g}=Vr(a,o,d),f=o,p={},x=0;for(let h=0;h<c.length;h++){const{name:y,fn:m}=c[h],{x:v,y:k,data:R,reset:I}=await m({x:u,y:g,initialPlacement:o,placement:f,strategy:n,middlewareData:p,rects:a,platform:l,elements:{reference:e,floating:t}});u=v??u,g=k??g,p={...p,[y]:{...p[y],...R}},I&&x<=50&&(x++,typeof I=="object"&&(I.placement&&(f=I.placement),I.rects&&(a=I.rects===!0?await l.getElementRects({reference:e,floating:t,strategy:n}):I.rects),{x:u,y:g}=Vr(a,f,d)),h=-1)}return{x:u,y:g,placement:f,strategy:n,middlewareData:p}};async function Cr(e,t){var r;t===void 0&&(t={});const{x:o,y:n,platform:s,rects:l,elements:c,strategy:d}=e,{boundary:a="clippingAncestors",rootBoundary:u="viewport",elementContext:g="floating",altBoundary:f=!1,padding:p=0}=ut(t,e),x=Ii(p),y=c[f?g==="floating"?"reference":"floating":g],m=Ot(await s.getClippingRect({element:(r=await(s.isElement==null?void 0:s.isElement(y)))==null||r?y:y.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(c.floating)),boundary:a,rootBoundary:u,strategy:d})),v=g==="floating"?{x:o,y:n,width:l.floating.width,height:l.floating.height}:l.reference,k=await(s.getOffsetParent==null?void 0:s.getOffsetParent(c.floating)),R=await(s.isElement==null?void 0:s.isElement(k))?await(s.getScale==null?void 0:s.getScale(k))||{x:1,y:1}:{x:1,y:1},I=Ot(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:v,offsetParent:k,strategy:d}):v);return{top:(m.top-I.top+x.top)/R.y,bottom:(I.bottom-m.bottom+x.bottom)/R.y,left:(m.left-I.left+x.left)/R.x,right:(I.right-m.right+x.right)/R.x}}const ul=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var r,o;const{placement:n,middlewareData:s,rects:l,initialPlacement:c,platform:d,elements:a}=t,{mainAxis:u=!0,crossAxis:g=!0,fallbackPlacements:f,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:x="none",flipAlignment:h=!0,...y}=ut(e,t);if((r=s.arrow)!=null&&r.alignmentOffset)return{};const m=Fe(n),v=Te(c),k=Fe(c)===c,R=await(d.isRTL==null?void 0:d.isRTL(a.floating)),I=f||(k||!h?[It(c)]:wi(c)),P=x!=="none";!f&&P&&I.push(...Si(c,h,x,R));const L=[c,...I],j=await Cr(t,y),Z=[];let $=((o=s.flip)==null?void 0:o.overflows)||[];if(u&&Z.push(j[m]),g){const S=vi(n,l,R);Z.push(j[S[0]],j[S[1]])}if($=[...$,{placement:n,overflows:Z}],!Z.every(S=>S<=0)){var F,Y;const S=(((F=s.flip)==null?void 0:F.index)||0)+1,E=L[S];if(E&&(!(g==="alignment"?v!==Te(E):!1)||$.every(b=>Te(b.placement)===v?b.overflows[0]>0:!0)))return{data:{index:S,overflows:$},reset:{placement:E}};let _=(Y=$.filter(D=>D.overflows[0]<=0).sort((D,b)=>D.overflows[1]-b.overflows[1])[0])==null?void 0:Y.placement;if(!_)switch(p){case"bestFit":{var U;const D=(U=$.filter(b=>{if(P){const T=Te(b.placement);return T===v||T==="y"}return!0}).map(b=>[b.placement,b.overflows.filter(T=>T>0).reduce((T,N)=>T+N,0)]).sort((b,T)=>b[1]-T[1])[0])==null?void 0:U[0];D&&(_=D);break}case"initialPlacement":_=c;break}if(n!==_)return{reset:{placement:_}}}return{}}}},dl=new Set(["left","top"]);async function fl(e,t){const{placement:r,platform:o,elements:n}=e,s=await(o.isRTL==null?void 0:o.isRTL(n.floating)),l=Fe(r),c=dt(r),d=Te(r)==="y",a=dl.has(l)?-1:1,u=s&&d?-1:1,g=ut(t,e);let{mainAxis:f,crossAxis:p,alignmentAxis:x}=typeof g=="number"?{mainAxis:g,crossAxis:0,alignmentAxis:null}:{mainAxis:g.mainAxis||0,crossAxis:g.crossAxis||0,alignmentAxis:g.alignmentAxis};return c&&typeof x=="number"&&(p=c==="end"?x*-1:x),d?{x:p*u,y:f*a}:{x:f*a,y:p*u}}const gl=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,o;const{x:n,y:s,placement:l,middlewareData:c}=t,d=await fl(t,e);return l===((r=c.offset)==null?void 0:r.placement)&&(o=c.arrow)!=null&&o.alignmentOffset?{}:{x:n+d.x,y:s+d.y,data:{...d,placement:l}}}}},hl=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:r,y:o,placement:n}=t,{mainAxis:s=!0,crossAxis:l=!1,limiter:c={fn:y=>{let{x:m,y:v}=y;return{x:m,y:v}}},...d}=ut(e,t),a={x:r,y:o},u=await Cr(t,d),g=Te(Fe(n)),f=To(g);let p=a[f],x=a[g];if(s){const y=f==="y"?"top":"left",m=f==="y"?"bottom":"right",v=p+u[y],k=p-u[m];p=Dr(v,p,k)}if(l){const y=g==="y"?"top":"left",m=g==="y"?"bottom":"right",v=x+u[y],k=x-u[m];x=Dr(v,x,k)}const h=c.fn({...t,[f]:p,[g]:x});return{...h,data:{x:h.x-r,y:h.y-o,enabled:{[f]:s,[g]:l}}}}}},pl=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var r,o;const{placement:n,rects:s,platform:l,elements:c}=t,{apply:d=()=>{},...a}=ut(e,t),u=await Cr(t,a),g=Fe(n),f=dt(n),p=Te(n)==="y",{width:x,height:h}=s.floating;let y,m;g==="top"||g==="bottom"?(y=g,m=f===(await(l.isRTL==null?void 0:l.isRTL(c.floating))?"start":"end")?"left":"right"):(m=g,y=f==="end"?"top":"bottom");const v=h-u.top-u.bottom,k=x-u.left-u.right,R=Je(h-u[y],v),I=Je(x-u[m],k),P=!t.middlewareData.shift;let L=R,j=I;if((r=t.middlewareData.shift)!=null&&r.enabled.x&&(j=k),(o=t.middlewareData.shift)!=null&&o.enabled.y&&(L=v),P&&!f){const $=me(u.left,0),F=me(u.right,0),Y=me(u.top,0),U=me(u.bottom,0);p?j=x-2*($!==0||F!==0?$+F:me(u.left,u.right)):L=h-2*(Y!==0||U!==0?Y+U:me(u.top,u.bottom))}await d({...t,availableWidth:j,availableHeight:L});const Z=await l.getDimensions(c.floating);return x!==Z.width||h!==Z.height?{reset:{rects:!0}}:{}}}};function Ho(e){const t=ye(e);let r=parseFloat(t.width)||0,o=parseFloat(t.height)||0;const n=le(e),s=n?e.offsetWidth:r,l=n?e.offsetHeight:o,c=Et(r)!==s||Et(o)!==l;return c&&(r=s,o=l),{width:r,height:o,$:c}}function vr(e){return re(e)?e:e.contextElement}function Ze(e){const t=vr(e);if(!le(t))return Ee(1);const r=t.getBoundingClientRect(),{width:o,height:n,$:s}=Ho(t);let l=(s?Et(r.width):r.width)/o,c=(s?Et(r.height):r.height)/n;return(!l||!Number.isFinite(l))&&(l=1),(!c||!Number.isFinite(c))&&(c=1),{x:l,y:c}}const bl=Ee(0);function Uo(e){const t=Ce(e);return!zt()||!t.visualViewport?bl:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function xl(e,t,r){return t===void 0&&(t=!1),!r||t&&r!==Ce(e)?!1:t}function Ue(e,t,r,o){t===void 0&&(t=!1),r===void 0&&(r=!1);const n=e.getBoundingClientRect(),s=vr(e);let l=Ee(1);t&&(o?re(o)&&(l=Ze(o)):l=Ze(e));const c=xl(s,r,o)?Uo(s):Ee(0);let d=(n.left+c.x)/l.x,a=(n.top+c.y)/l.y,u=n.width/l.x,g=n.height/l.y;if(s){const f=Ce(s),p=o&&re(o)?Ce(o):o;let x=f,h=ar(x);for(;h&&o&&p!==x;){const y=Ze(h),m=h.getBoundingClientRect(),v=ye(h),k=m.left+(h.clientLeft+parseFloat(v.paddingLeft))*y.x,R=m.top+(h.clientTop+parseFloat(v.paddingTop))*y.y;d*=y.x,a*=y.y,u*=y.x,g*=y.y,d+=k,a+=R,x=Ce(h),h=ar(x)}}return Ot({width:u,height:g,x:d,y:a})}function Vt(e,t){const r=Bt(e).scrollLeft;return t?t.left+r:Ue(Ie(e)).left+r}function Go(e,t){const r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-Vt(e,r),n=r.top+t.scrollTop;return{x:o,y:n}}function ml(e){let{elements:t,rect:r,offsetParent:o,strategy:n}=e;const s=n==="fixed",l=Ie(o),c=t?jt(t.floating):!1;if(o===l||c&&s)return r;let d={scrollLeft:0,scrollTop:0},a=Ee(1);const u=Ee(0),g=le(o);if((g||!g&&!s)&&((_e(o)!=="body"||at(l))&&(d=Bt(o)),le(o))){const p=Ue(o);a=Ze(o),u.x=p.x+o.clientLeft,u.y=p.y+o.clientTop}const f=l&&!g&&!s?Go(l,d):Ee(0);return{width:r.width*a.x,height:r.height*a.y,x:r.x*a.x-d.scrollLeft*a.x+u.x+f.x,y:r.y*a.y-d.scrollTop*a.y+u.y+f.y}}function Cl(e){return Array.from(e.getClientRects())}function vl(e){const t=Ie(e),r=Bt(e),o=e.ownerDocument.body,n=me(t.scrollWidth,t.clientWidth,o.scrollWidth,o.clientWidth),s=me(t.scrollHeight,t.clientHeight,o.scrollHeight,o.clientHeight);let l=-r.scrollLeft+Vt(e);const c=-r.scrollTop;return ye(o).direction==="rtl"&&(l+=me(t.clientWidth,o.clientWidth)-n),{width:n,height:s,x:l,y:c}}const Hr=25;function wl(e,t){const r=Ce(e),o=Ie(e),n=r.visualViewport;let s=o.clientWidth,l=o.clientHeight,c=0,d=0;if(n){s=n.width,l=n.height;const u=zt();(!u||u&&t==="fixed")&&(c=n.offsetLeft,d=n.offsetTop)}const a=Vt(o);if(a<=0){const u=o.ownerDocument,g=u.body,f=getComputedStyle(g),p=u.compatMode==="CSS1Compat"&&parseFloat(f.marginLeft)+parseFloat(f.marginRight)||0,x=Math.abs(o.clientWidth-g.clientWidth-p);x<=Hr&&(s-=x)}else a<=Hr&&(s+=a);return{width:s,height:l,x:c,y:d}}const yl=new Set(["absolute","fixed"]);function kl(e,t){const r=Ue(e,!0,t==="fixed"),o=r.top+e.clientTop,n=r.left+e.clientLeft,s=le(e)?Ze(e):Ee(1),l=e.clientWidth*s.x,c=e.clientHeight*s.y,d=n*s.x,a=o*s.y;return{width:l,height:c,x:d,y:a}}function Ur(e,t,r){let o;if(t==="viewport")o=wl(e,r);else if(t==="document")o=vl(Ie(e));else if(re(t))o=kl(t,r);else{const n=Uo(e);o={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return Ot(o)}function Ko(e,t){const r=Ae(e);return r===t||!re(r)||$e(r)?!1:ye(r).position==="fixed"||Ko(r,t)}function Rl(e,t){const r=t.get(e);if(r)return r;let o=Ne(e,[],!1).filter(c=>re(c)&&_e(c)!=="body"),n=null;const s=ye(e).position==="fixed";let l=s?Ae(e):e;for(;re(l)&&!$e(l);){const c=ye(l),d=xr(l);!d&&c.position==="fixed"&&(n=null),(s?!d&&!n:!d&&c.position==="static"&&!!n&&yl.has(n.position)||at(l)&&!d&&Ko(e,l))?o=o.filter(u=>u!==l):n=c,l=Ae(l)}return t.set(e,o),o}function Sl(e){let{element:t,boundary:r,rootBoundary:o,strategy:n}=e;const l=[...r==="clippingAncestors"?jt(t)?[]:Rl(t,this._c):[].concat(r),o],c=l[0],d=l.reduce((a,u)=>{const g=Ur(t,u,n);return a.top=me(g.top,a.top),a.right=Je(g.right,a.right),a.bottom=Je(g.bottom,a.bottom),a.left=me(g.left,a.left),a},Ur(t,c,n));return{width:d.right-d.left,height:d.bottom-d.top,x:d.left,y:d.top}}function El(e){const{width:t,height:r}=Ho(e);return{width:t,height:r}}function Il(e,t,r){const o=le(t),n=Ie(t),s=r==="fixed",l=Ue(e,!0,s,t);let c={scrollLeft:0,scrollTop:0};const d=Ee(0);function a(){d.x=Vt(n)}if(o||!o&&!s)if((_e(t)!=="body"||at(n))&&(c=Bt(t)),o){const p=Ue(t,!0,s,t);d.x=p.x+t.clientLeft,d.y=p.y+t.clientTop}else n&&a();s&&!o&&n&&a();const u=n&&!o&&!s?Go(n,c):Ee(0),g=l.left+c.scrollLeft-d.x-u.x,f=l.top+c.scrollTop-d.y-u.y;return{x:g,y:f,width:l.width,height:l.height}}function Qt(e){return ye(e).position==="static"}function Gr(e,t){if(!le(e)||ye(e).position==="fixed")return null;if(t)return t(e);let r=e.offsetParent;return Ie(e)===r&&(r=r.ownerDocument.body),r}function qo(e,t){const r=Ce(e);if(jt(e))return r;if(!le(e)){let n=Ae(e);for(;n&&!$e(n);){if(re(n)&&!Qt(n))return n;n=Ae(n)}return r}let o=Gr(e,t);for(;o&&ui(o)&&Qt(o);)o=Gr(o,t);return o&&$e(o)&&Qt(o)&&!xr(o)?r:o||pi(e)||r}const Ol=async function(e){const t=this.getOffsetParent||qo,r=this.getDimensions,o=await r(e.floating);return{reference:Il(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}};function Tl(e){return ye(e).direction==="rtl"}const $l={convertOffsetParentRelativeRectToViewportRelativeRect:ml,getDocumentElement:Ie,getClippingRect:Sl,getOffsetParent:qo,getElementRects:Ol,getClientRects:Cl,getDimensions:El,getScale:Ze,isElement:re,isRTL:Tl};function Xo(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Al(e,t){let r=null,o;const n=Ie(e);function s(){var c;clearTimeout(o),(c=r)==null||c.disconnect(),r=null}function l(c,d){c===void 0&&(c=!1),d===void 0&&(d=1),s();const a=e.getBoundingClientRect(),{left:u,top:g,width:f,height:p}=a;if(c||t(),!f||!p)return;const x=Ye(g),h=Ye(n.clientWidth-(u+f)),y=Ye(n.clientHeight-(g+p)),m=Ye(u),k={rootMargin:-x+"px "+-h+"px "+-y+"px "+-m+"px",threshold:me(0,Je(1,d))||1};let R=!0;function I(P){const L=P[0].intersectionRatio;if(L!==d){if(!R)return l();L?l(!1,L):o=setTimeout(()=>{l(!1,1e-7)},1e3)}L===1&&!Xo(a,e.getBoundingClientRect())&&l(),R=!1}try{r=new IntersectionObserver(I,{...k,root:n.ownerDocument})}catch{r=new IntersectionObserver(I,k)}r.observe(e)}return l(!0),s}function Yo(e,t,r,o){o===void 0&&(o={});const{ancestorScroll:n=!0,ancestorResize:s=!0,elementResize:l=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:d=!1}=o,a=vr(e),u=n||s?[...a?Ne(a):[],...Ne(t)]:[];u.forEach(m=>{n&&m.addEventListener("scroll",r,{passive:!0}),s&&m.addEventListener("resize",r)});const g=a&&c?Al(a,r):null;let f=-1,p=null;l&&(p=new ResizeObserver(m=>{let[v]=m;v&&v.target===a&&p&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var k;(k=p)==null||k.observe(t)})),r()}),a&&!d&&p.observe(a),p.observe(t));let x,h=d?Ue(e):null;d&&y();function y(){const m=Ue(e);h&&!Xo(h,m)&&r(),h=m,x=requestAnimationFrame(y)}return r(),()=>{var m;u.forEach(v=>{n&&v.removeEventListener("scroll",r),s&&v.removeEventListener("resize",r)}),g==null||g(),(m=p)==null||m.disconnect(),p=null,d&&cancelAnimationFrame(x)}}const Ml=gl,Pl=hl,Dl=ul,Ll=pl,Nl=(e,t,r)=>{const o=new Map,n={platform:$l,...r},s={...n.platform,_c:o};return al(e,t,{...n,platform:s})};var Fl=typeof document<"u",_l=function(){},St=Fl?X.useLayoutEffect:_l;function Pt(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 r,o,n;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(o=r;o--!==0;)if(!Pt(e[o],t[o]))return!1;return!0}if(n=Object.keys(e),r=n.length,r!==Object.keys(t).length)return!1;for(o=r;o--!==0;)if(!{}.hasOwnProperty.call(t,n[o]))return!1;for(o=r;o--!==0;){const s=n[o];if(!(s==="_owner"&&e.$$typeof)&&!Pt(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function Zo(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Kr(e,t){const r=Zo(e);return Math.round(t*r)/r}function Jt(e){const t=C.useRef(e);return St(()=>{t.current=e}),t}function jl(e){e===void 0&&(e={});const{placement:t="bottom",strategy:r="absolute",middleware:o=[],platform:n,elements:{reference:s,floating:l}={},transform:c=!0,whileElementsMounted:d,open:a}=e,[u,g]=C.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=C.useState(o);Pt(f,o)||p(o);const[x,h]=C.useState(null),[y,m]=C.useState(null),v=C.useCallback(b=>{b!==P.current&&(P.current=b,h(b))},[]),k=C.useCallback(b=>{b!==L.current&&(L.current=b,m(b))},[]),R=s||x,I=l||y,P=C.useRef(null),L=C.useRef(null),j=C.useRef(u),Z=d!=null,$=Jt(d),F=Jt(n),Y=Jt(a),U=C.useCallback(()=>{if(!P.current||!L.current)return;const b={placement:t,strategy:r,middleware:f};F.current&&(b.platform=F.current),Nl(P.current,L.current,b).then(T=>{const N={...T,isPositioned:Y.current!==!1};S.current&&!Pt(j.current,N)&&(j.current=N,pn.flushSync(()=>{g(N)}))})},[f,t,r,F,Y]);St(()=>{a===!1&&j.current.isPositioned&&(j.current.isPositioned=!1,g(b=>({...b,isPositioned:!1})))},[a]);const S=C.useRef(!1);St(()=>(S.current=!0,()=>{S.current=!1}),[]),St(()=>{if(R&&(P.current=R),I&&(L.current=I),R&&I){if($.current)return $.current(R,I,U);U()}},[R,I,U,$,Z]);const E=C.useMemo(()=>({reference:P,floating:L,setReference:v,setFloating:k}),[v,k]),_=C.useMemo(()=>({reference:R,floating:I}),[R,I]),D=C.useMemo(()=>{const b={position:r,left:0,top:0};if(!_.floating)return b;const T=Kr(_.floating,u.x),N=Kr(_.floating,u.y);return c?{...b,transform:"translate("+T+"px, "+N+"px)",...Zo(_.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:T,top:N}},[r,c,_.floating,u.x,u.y]);return C.useMemo(()=>({...u,update:U,refs:E,elements:_,floatingStyles:D}),[u,U,E,_,D])}const Qo=(e,t)=>({...Ml(e),options:[e,t]}),Jo=(e,t)=>({...Pl(e),options:[e,t]}),en=(e,t)=>({...Dl(e),options:[e,t]}),zl=(e,t)=>({...Ll(e),options:[e,t]}),Bl="data-floating-ui-focusable",qr="active",Xr="selected",ft="ArrowLeft",gt="ArrowRight",tn="ArrowUp",Ht="ArrowDown",Wl={...C};let Yr=!1,Vl=0;const Zr=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+Vl++;function Hl(){const[e,t]=C.useState(()=>Yr?Zr():void 0);return se(()=>{e==null&&t(Zr())},[]),C.useEffect(()=>{Yr=!0},[]),e}const Ul=Wl.useId,rn=Ul||Hl;let ct;process.env.NODE_ENV!=="production"&&(ct=new Set);function er(){for(var e,t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];const n="Floating UI: "+r.join(" ");if(!((e=ct)!=null&&e.has(n))){var s;(s=ct)==null||s.add(n),console.warn(n)}}function Gl(){for(var e,t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];const n="Floating UI: "+r.join(" ");if(!((e=ct)!=null&&e.has(n))){var s;(s=ct)==null||s.add(n),console.error(n)}}function Kl(){const e=new Map;return{emit(t,r){var o;(o=e.get(t))==null||o.forEach(n=>n(r))},on(t,r){e.has(t)||e.set(t,new Set),e.get(t).add(r)},off(t,r){var o;(o=e.get(t))==null||o.delete(r)}}}const ql=C.createContext(null),Xl=C.createContext(null),wr=()=>{var e;return((e=C.useContext(ql))==null?void 0:e.id)||null},Ut=()=>C.useContext(Xl);function Dt(e){return"data-floating-ui-"+e}function pr(e){e.current!==-1&&(clearTimeout(e.current),e.current=-1)}let Qr=0;function Be(e,t){t===void 0&&(t={});const{preventScroll:r=!1,cancelPrevious:o=!0,sync:n=!1}=t;o&&cancelAnimationFrame(Qr);const s=()=>e==null?void 0:e.focus({preventScroll:r});n?s():Qr=requestAnimationFrame(s)}function Yl(e){return(e==null?void 0:e.ownerDocument)||document}const Qe={inert:new WeakMap,"aria-hidden":new WeakMap,none:new WeakMap};function Jr(e){return e==="inert"?Qe.inert:e==="aria-hidden"?Qe["aria-hidden"]:Qe.none}let Ct=new WeakSet,vt={},tr=0;const Zl=()=>typeof HTMLElement<"u"&&"inert"in HTMLElement.prototype,on=e=>e&&(e.host||on(e.parentNode)),Ql=(e,t)=>t.map(r=>{if(e.contains(r))return r;const o=on(r);return e.contains(o)?o:null}).filter(r=>r!=null);function Jl(e,t,r,o){const n="data-floating-ui-inert",s=o?"inert":r?"aria-hidden":null,l=Ql(t,e),c=new Set,d=new Set(l),a=[];vt[n]||(vt[n]=new WeakMap);const u=vt[n];l.forEach(g),f(t),c.clear();function g(p){!p||c.has(p)||(c.add(p),p.parentNode&&g(p.parentNode))}function f(p){!p||d.has(p)||[].forEach.call(p.children,x=>{if(_e(x)!=="script")if(c.has(x))f(x);else{const h=s?x.getAttribute(s):null,y=h!==null&&h!=="false",m=Jr(s),v=(m.get(x)||0)+1,k=(u.get(x)||0)+1;m.set(x,v),u.set(x,k),a.push(x),v===1&&y&&Ct.add(x),k===1&&x.setAttribute(n,""),!y&&s&&x.setAttribute(s,s==="inert"?"":"true")}})}return tr++,()=>{a.forEach(p=>{const x=Jr(s),y=(x.get(p)||0)-1,m=(u.get(p)||0)-1;x.set(p,y),u.set(p,m),y||(!Ct.has(p)&&s&&p.removeAttribute(s),Ct.delete(p)),m||p.removeAttribute(n)}),tr--,tr||(Qe.inert=new WeakMap,Qe["aria-hidden"]=new WeakMap,Qe.none=new WeakMap,Ct=new WeakSet,vt={})}}function eo(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!1);const o=Yl(e[0]).body;return Jl(e.concat(Array.from(o.querySelectorAll('[aria-live],[role="status"],output'))),o,t,r)}const yr={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"fixed",whiteSpace:"nowrap",width:"1px",top:0,left:0},to=C.forwardRef(function(t,r){const[o,n]=C.useState();se(()=>{Hi()&&n("button")},[]);const s={ref:r,tabIndex:0,role:o,"aria-hidden":o?void 0:!0,[Dt("focus-guard")]:"",style:yr};return We.jsx("span",{...t,...s})}),es=C.createContext(null),ts=()=>C.useContext(es);function ro(e){return C.useMemo(()=>t=>{e.forEach(r=>{r&&(r.current=t)})},e)}const rs=20;let Le=[];function kr(){Le=Le.filter(e=>e.isConnected)}function os(e){kr(),e&&_e(e)!=="body"&&(Le.push(e),Le.length>rs&&(Le=Le.slice(-20)))}function oo(){return kr(),Le[Le.length-1]}function ns(e){const t=Wt();return _o(e,t)?e:mr(e,t)[0]||e}function no(e,t){var r;if(!t.current.includes("floating")&&!((r=e.getAttribute("role"))!=null&&r.includes("dialog")))return;const o=Wt(),s=Wi(e,o).filter(c=>{const d=c.getAttribute("data-tabindex")||"";return _o(c,o)||c.hasAttribute("data-tabindex")&&!d.startsWith("-")}),l=e.getAttribute("tabindex");t.current.includes("floating")||s.length===0?l!=="0"&&e.setAttribute("tabindex","0"):(l!=="-1"||e.hasAttribute("data-tabindex")&&e.getAttribute("data-tabindex")!=="-1")&&(e.setAttribute("tabindex","-1"),e.setAttribute("data-tabindex","-1"))}const is=C.forwardRef(function(t,r){return We.jsx("button",{...t,type:"button",ref:r,tabIndex:-1,style:yr})});function ls(e){const{context:t,children:r,disabled:o=!1,order:n=["content"],guards:s=!0,initialFocus:l=0,returnFocus:c=!0,restoreFocus:d=!1,modal:a=!0,visuallyHiddenDismiss:u=!1,closeOnFocusOut:g=!0,outsideElementsInert:f=!1,getInsideElements:p=()=>[]}=e,{open:x,onOpenChange:h,events:y,dataRef:m,elements:{domReference:v,floating:k}}=t,R=ue(()=>{var z;return(z=m.current.floatingContext)==null?void 0:z.nodeId}),I=ue(p),P=typeof l=="number"&&l<0,L=hr(v)&&P,j=Zl(),Z=j?s:!0,$=!Z||j&&f,F=Se(n),Y=Se(l),U=Se(c),S=Ut(),E=ts(),_=C.useRef(null),D=C.useRef(null),b=C.useRef(!1),T=C.useRef(!1),N=C.useRef(-1),ne=C.useRef(-1),be=E!=null,V=Mt(k),q=ue(function(z){return z===void 0&&(z=V),z?mr(z,Wt()):[]}),H=ue(z=>{const G=q(z);return F.current.map(B=>v&&B==="reference"?v:V&&B==="floating"?V:G).filter(Boolean).flat()});C.useEffect(()=>{if(o||!a)return;function z(B){if(B.key==="Tab"){xe(V,Pe(we(V)))&&q().length===0&&!L&&ae(B);const ee=H(),oe=De(B);F.current[0]==="reference"&&oe===v&&(ae(B),B.shiftKey?Be(ee[ee.length-1]):Be(ee[1])),F.current[1]==="floating"&&oe===V&&B.shiftKey&&(ae(B),Be(ee[0]))}}const G=we(V);return G.addEventListener("keydown",z),()=>{G.removeEventListener("keydown",z)}},[o,v,V,a,F,L,q,H]),C.useEffect(()=>{if(o||!k)return;function z(G){const B=De(G),oe=q().indexOf(B);oe!==-1&&(N.current=oe)}return k.addEventListener("focusin",z),()=>{k.removeEventListener("focusin",z)}},[o,k,q]),C.useEffect(()=>{if(o||!g)return;function z(){T.current=!0,setTimeout(()=>{T.current=!1})}function G(oe){const K=oe.relatedTarget,pe=oe.currentTarget,ce=De(oe);queueMicrotask(()=>{const fe=R(),ke=!(xe(v,K)||xe(k,K)||xe(K,k)||xe(E==null?void 0:E.portalNode,K)||K!=null&&K.hasAttribute(Dt("focus-guard"))||S&&(Ve(S.nodesRef.current,fe).find(M=>{var W,A;return xe((W=M.context)==null?void 0:W.elements.floating,K)||xe((A=M.context)==null?void 0:A.elements.domReference,K)})||jr(S.nodesRef.current,fe).find(M=>{var W,A,Q;return[(W=M.context)==null?void 0:W.elements.floating,Mt((A=M.context)==null?void 0:A.elements.floating)].includes(K)||((Q=M.context)==null?void 0:Q.elements.domReference)===K})));if(pe===v&&V&&no(V,F),d&&pe!==v&&!(ce!=null&&ce.isConnected)&&Pe(we(V))===we(V).body){le(V)&&V.focus();const M=N.current,W=q(),A=W[M]||W[W.length-1]||V;le(A)&&A.focus()}if(m.current.insideReactTree){m.current.insideReactTree=!1;return}(L||!a)&&K&&ke&&!T.current&&K!==oo()&&(b.current=!0,h(!1,oe,"focus-out"))})}const B=!!(!S&&E);function ee(){pr(ne),m.current.insideReactTree=!0,ne.current=window.setTimeout(()=>{m.current.insideReactTree=!1})}if(k&&le(v))return v.addEventListener("focusout",G),v.addEventListener("pointerdown",z),k.addEventListener("focusout",G),B&&k.addEventListener("focusout",ee,!0),()=>{v.removeEventListener("focusout",G),v.removeEventListener("pointerdown",z),k.removeEventListener("focusout",G),B&&k.removeEventListener("focusout",ee,!0)}},[o,v,k,V,a,S,E,h,g,d,q,L,R,F,m]);const J=C.useRef(null),de=C.useRef(null),tt=ro([J,E==null?void 0:E.beforeInsideRef]),Ge=ro([de,E==null?void 0:E.afterInsideRef]);C.useEffect(()=>{var z,G;if(o||!k)return;const B=Array.from((E==null||(z=E.portalNode)==null?void 0:z.querySelectorAll("["+Dt("portal")+"]"))||[]),oe=(G=(S?jr(S.nodesRef.current,R()):[]).find(ce=>{var fe;return hr(((fe=ce.context)==null?void 0:fe.elements.domReference)||null)}))==null||(G=G.context)==null?void 0:G.elements.domReference,K=[k,oe,...B,...I(),_.current,D.current,J.current,de.current,E==null?void 0:E.beforeOutsideRef.current,E==null?void 0:E.afterOutsideRef.current,F.current.includes("reference")||L?v:null].filter(ce=>ce!=null),pe=a||L?eo(K,!$,$):eo(K);return()=>{pe()}},[o,v,k,a,F,E,L,Z,$,S,R,I]),se(()=>{if(o||!le(V))return;const z=we(V),G=Pe(z);queueMicrotask(()=>{const B=H(V),ee=Y.current,oe=(typeof ee=="number"?B[ee]:ee.current)||V,K=xe(V,G);!P&&!K&&x&&Be(oe,{preventScroll:oe===V})})},[o,x,V,P,H,Y]),se(()=>{if(o||!V)return;const z=we(V),G=Pe(z);os(G);function B(K){let{reason:pe,event:ce,nested:fe}=K;if(["hover","safe-polygon"].includes(pe)&&ce.type==="mouseleave"&&(b.current=!0),pe==="outside-press")if(fe)b.current=!1;else if(Bo(ce)||Wo(ce))b.current=!1;else{let ke=!1;document.createElement("div").focus({get preventScroll(){return ke=!0,!1}}),ke?b.current=!1:b.current=!0}}y.on("openchange",B);const ee=z.createElement("span");ee.setAttribute("tabindex","-1"),ee.setAttribute("aria-hidden","true"),Object.assign(ee.style,yr),be&&v&&v.insertAdjacentElement("afterend",ee);function oe(){if(typeof U.current=="boolean"){const K=v||oo();return K&&K.isConnected?K:ee}return U.current.current||ee}return()=>{y.off("openchange",B);const K=Pe(z),pe=xe(k,K)||S&&Ve(S.nodesRef.current,R(),!1).some(fe=>{var ke;return xe((ke=fe.context)==null?void 0:ke.elements.floating,K)}),ce=oe();queueMicrotask(()=>{const fe=ns(ce);U.current&&!b.current&&le(fe)&&(!(fe!==K&&K!==z.body)||pe)&&fe.focus({preventScroll:!0}),ee.remove()})}},[o,k,V,U,m,y,S,be,v,R]),C.useEffect(()=>(queueMicrotask(()=>{b.current=!1}),()=>{queueMicrotask(kr)}),[o]),se(()=>{if(!o&&E)return E.setFocusManagerState({modal:a,closeOnFocusOut:g,open:x,onOpenChange:h,domReference:v}),()=>{E.setFocusManagerState(null)}},[o,E,a,x,h,g,v]),se(()=>{o||V&&no(V,F)},[o,V,F]);function Oe(z){return o||!u||!a?null:We.jsx(is,{ref:z==="start"?_:D,onClick:G=>h(!1,G.nativeEvent),children:typeof u=="string"?u:"Dismiss"})}const Ke=!o&&Z&&(a?!L:!0)&&(be||a);return We.jsxs(We.Fragment,{children:[Ke&&We.jsx(to,{"data-type":"inside",ref:tt,onFocus:z=>{if(a){const B=H();Be(n[0]==="reference"?B[0]:B[B.length-1])}else if(E!=null&&E.preserveTabOrder&&E.portalNode)if(b.current=!1,Wr(z,E.portalNode)){const B=sl(v);B==null||B.focus()}else{var G;(G=E.beforeOutsideRef.current)==null||G.focus()}}}),!L&&Oe("start"),r,Oe("end"),Ke&&We.jsx(to,{"data-type":"inside",ref:Ge,onFocus:z=>{if(a)Be(H()[0]);else if(E!=null&&E.preserveTabOrder&&E.portalNode)if(g&&(b.current=!0),Wr(z,E.portalNode)){const B=cl(v);B==null||B.focus()}else{var G;(G=E.afterOutsideRef.current)==null||G.focus()}}})]})}function io(e){return le(e.target)&&e.target.tagName==="BUTTON"}function ss(e){return le(e.target)&&e.target.tagName==="A"}function lo(e){return zo(e)}function nn(e,t){t===void 0&&(t={});const{open:r,onOpenChange:o,dataRef:n,elements:{domReference:s}}=e,{enabled:l=!0,event:c="click",toggle:d=!0,ignoreMouse:a=!1,keyboardHandlers:u=!0,stickIfOpen:g=!0}=t,f=C.useRef(),p=C.useRef(!1),x=C.useMemo(()=>({onPointerDown(h){f.current=h.pointerType},onMouseDown(h){const y=f.current;h.button===0&&c!=="click"&&(zr(y)&&a||(r&&d&&(!(n.current.openEvent&&g)||n.current.openEvent.type==="mousedown")?o(!1,h.nativeEvent,"click"):(h.preventDefault(),o(!0,h.nativeEvent,"click"))))},onClick(h){const y=f.current;if(c==="mousedown"&&f.current){f.current=void 0;return}zr(y)&&a||(r&&d&&(!(n.current.openEvent&&g)||n.current.openEvent.type==="click")?o(!1,h.nativeEvent,"click"):o(!0,h.nativeEvent,"click"))},onKeyDown(h){f.current=void 0,!(h.defaultPrevented||!u||io(h))&&(h.key===" "&&!lo(s)&&(h.preventDefault(),p.current=!0),!ss(h)&&h.key==="Enter"&&o(!(r&&d),h.nativeEvent,"click"))},onKeyUp(h){h.defaultPrevented||!u||io(h)||lo(s)||h.key===" "&&p.current&&(p.current=!1,o(!(r&&d),h.nativeEvent,"click"))}}),[n,s,c,a,u,o,r,g,d]);return C.useMemo(()=>l?{reference:x}:{},[l,x])}const cs={pointerdown:"onPointerDown",mousedown:"onMouseDown",click:"onClick"},as={pointerdown:"onPointerDownCapture",mousedown:"onMouseDownCapture",click:"onClickCapture"},so=e=>{var t,r;return{escapeKey:typeof e=="boolean"?e:(t=e==null?void 0:e.escapeKey)!=null?t:!1,outsidePress:typeof e=="boolean"?e:(r=e==null?void 0:e.outsidePress)!=null?r:!0}};function ln(e,t){t===void 0&&(t={});const{open:r,onOpenChange:o,elements:n,dataRef:s}=e,{enabled:l=!0,escapeKey:c=!0,outsidePress:d=!0,outsidePressEvent:a="pointerdown",referencePress:u=!1,referencePressEvent:g="pointerdown",ancestorScroll:f=!1,bubbles:p,capture:x}=t,h=Ut(),y=ue(typeof d=="function"?d:()=>!1),m=typeof d=="function"?y:d,v=C.useRef(!1),{escapeKey:k,outsidePress:R}=so(p),{escapeKey:I,outsidePress:P}=so(x),L=C.useRef(!1),j=ue(S=>{var E;if(!r||!l||!c||S.key!=="Escape"||L.current)return;const _=(E=s.current.floatingContext)==null?void 0:E.nodeId,D=h?Ve(h.nodesRef.current,_):[];if(!k&&(S.stopPropagation(),D.length>0)){let b=!0;if(D.forEach(T=>{var N;if((N=T.context)!=null&&N.open&&!T.context.dataRef.current.__escapeKeyBubbles){b=!1;return}}),!b)return}o(!1,Zi(S)?S.nativeEvent:S,"escape-key")}),Z=ue(S=>{var E;const _=()=>{var D;j(S),(D=De(S))==null||D.removeEventListener("keydown",_)};(E=De(S))==null||E.addEventListener("keydown",_)}),$=ue(S=>{var E;const _=s.current.insideReactTree;s.current.insideReactTree=!1;const D=v.current;if(v.current=!1,a==="click"&&D||_||typeof m=="function"&&!m(S))return;const b=De(S),T="["+Dt("inert")+"]",N=we(n.floating).querySelectorAll(T);let ne=re(b)?b:null;for(;ne&&!$e(ne);){const H=Ae(ne);if($e(H)||!re(H))break;ne=H}if(N.length&&re(b)&&!Xi(b)&&!xe(b,n.floating)&&Array.from(N).every(H=>!xe(ne,H)))return;if(le(b)&&U){const H=$e(b),J=ye(b),de=/auto|scroll/,tt=H||de.test(J.overflowX),Ge=H||de.test(J.overflowY),Oe=tt&&b.clientWidth>0&&b.scrollWidth>b.clientWidth,Ke=Ge&&b.clientHeight>0&&b.scrollHeight>b.clientHeight,z=J.direction==="rtl",G=Ke&&(z?S.offsetX<=b.offsetWidth-b.clientWidth:S.offsetX>b.clientWidth),B=Oe&&S.offsetY>b.clientHeight;if(G||B)return}const be=(E=s.current.floatingContext)==null?void 0:E.nodeId,V=h&&Ve(h.nodesRef.current,be).some(H=>{var J;return Yt(S,(J=H.context)==null?void 0:J.elements.floating)});if(Yt(S,n.floating)||Yt(S,n.domReference)||V)return;const q=h?Ve(h.nodesRef.current,be):[];if(q.length>0){let H=!0;if(q.forEach(J=>{var de;if((de=J.context)!=null&&de.open&&!J.context.dataRef.current.__outsidePressBubbles){H=!1;return}}),!H)return}o(!1,S,"outside-press")}),F=ue(S=>{var E;const _=()=>{var D;$(S),(D=De(S))==null||D.removeEventListener(a,_)};(E=De(S))==null||E.addEventListener(a,_)});C.useEffect(()=>{if(!r||!l)return;s.current.__escapeKeyBubbles=k,s.current.__outsidePressBubbles=R;let S=-1;function E(N){o(!1,N,"ancestor-scroll")}function _(){window.clearTimeout(S),L.current=!0}function D(){S=window.setTimeout(()=>{L.current=!1},zt()?5:0)}const b=we(n.floating);c&&(b.addEventListener("keydown",I?Z:j,I),b.addEventListener("compositionstart",_),b.addEventListener("compositionend",D)),m&&b.addEventListener(a,P?F:$,P);let T=[];return f&&(re(n.domReference)&&(T=Ne(n.domReference)),re(n.floating)&&(T=T.concat(Ne(n.floating))),!re(n.reference)&&n.reference&&n.reference.contextElement&&(T=T.concat(Ne(n.reference.contextElement)))),T=T.filter(N=>{var ne;return N!==((ne=b.defaultView)==null?void 0:ne.visualViewport)}),T.forEach(N=>{N.addEventListener("scroll",E,{passive:!0})}),()=>{c&&(b.removeEventListener("keydown",I?Z:j,I),b.removeEventListener("compositionstart",_),b.removeEventListener("compositionend",D)),m&&b.removeEventListener(a,P?F:$,P),T.forEach(N=>{N.removeEventListener("scroll",E)}),window.clearTimeout(S)}},[s,n,c,m,a,r,o,f,l,k,R,j,I,Z,$,P,F]),C.useEffect(()=>{s.current.insideReactTree=!1},[s,m,a]);const Y=C.useMemo(()=>({onKeyDown:j,...u&&{[cs[g]]:S=>{o(!1,S.nativeEvent,"reference-press")},...g!=="click"&&{onClick(S){o(!1,S.nativeEvent,"reference-press")}}}}),[j,o,u,g]),U=C.useMemo(()=>({onKeyDown:j,onMouseDown(){v.current=!0},onMouseUp(){v.current=!0},[as[a]]:()=>{s.current.insideReactTree=!0}}),[j,a,s]);return C.useMemo(()=>l?{reference:Y,floating:U}:{},[l,Y,U])}function us(e){const{open:t=!1,onOpenChange:r,elements:o}=e,n=rn(),s=C.useRef({}),[l]=C.useState(()=>Kl()),c=wr()!=null;if(process.env.NODE_ENV!=="production"){const p=o.reference;p&&!re(p)&&Gl("Cannot pass a virtual element to the `elements.reference` option,","as it must be a real DOM element. Use `refs.setPositionReference()`","instead.")}const[d,a]=C.useState(o.reference),u=ue((p,x,h)=>{s.current.openEvent=p?x:void 0,l.emit("openchange",{open:p,event:x,reason:h,nested:c}),r==null||r(p,x,h)}),g=C.useMemo(()=>({setPositionReference:a}),[]),f=C.useMemo(()=>({reference:d||o.reference||null,floating:o.floating||null,domReference:o.reference}),[d,o.reference,o.floating]);return C.useMemo(()=>({dataRef:s,open:t,onOpenChange:u,elements:f,events:l,floatingId:n,refs:g}),[t,u,f,l,n,g])}function sn(e){e===void 0&&(e={});const{nodeId:t}=e,r=us({...e,elements:{reference:null,floating:null,...e.elements}}),o=e.rootContext||r,n=o.elements,[s,l]=C.useState(null),[c,d]=C.useState(null),u=(n==null?void 0:n.domReference)||s,g=C.useRef(null),f=Ut();se(()=>{u&&(g.current=u)},[u]);const p=jl({...e,elements:{...n,...c&&{reference:c}}}),x=C.useCallback(k=>{const R=re(k)?{getBoundingClientRect:()=>k.getBoundingClientRect(),getClientRects:()=>k.getClientRects(),contextElement:k}:k;d(R),p.refs.setReference(R)},[p.refs]),h=C.useCallback(k=>{(re(k)||k===null)&&(g.current=k,l(k)),(re(p.refs.reference.current)||p.refs.reference.current===null||k!==null&&!re(k))&&p.refs.setReference(k)},[p.refs]),y=C.useMemo(()=>({...p.refs,setReference:h,setPositionReference:x,domReference:g}),[p.refs,h,x]),m=C.useMemo(()=>({...p.elements,domReference:u}),[p.elements,u]),v=C.useMemo(()=>({...p,...o,refs:y,elements:m,nodeId:t}),[p,y,m,t,o]);return se(()=>{o.dataRef.current.floatingContext=v;const k=f==null?void 0:f.nodesRef.current.find(R=>R.id===t);k&&(k.context=v)}),C.useMemo(()=>({...p,context:v,refs:y,elements:m}),[p,y,m,v])}function rr(e,t,r){const o=new Map,n=r==="item";let s=e;if(n&&e){const{[qr]:l,[Xr]:c,...d}=e;s=d}return{...r==="floating"&&{tabIndex:-1,[Bl]:""},...s,...t.map(l=>{const c=l?l[r]:null;return typeof c=="function"?e?c(e):null:c}).concat(e).reduce((l,c)=>(c&&Object.entries(c).forEach(d=>{let[a,u]=d;if(!(n&&[qr,Xr].includes(a)))if(a.indexOf("on")===0){if(o.has(a)||o.set(a,[]),typeof u=="function"){var g;(g=o.get(a))==null||g.push(u),l[a]=function(){for(var f,p=arguments.length,x=new Array(p),h=0;h<p;h++)x[h]=arguments[h];return(f=o.get(a))==null?void 0:f.map(y=>y(...x)).find(y=>y!==void 0)}}}else l[a]=u}),l),{})}}function cn(e){e===void 0&&(e=[]);const t=e.map(c=>c==null?void 0:c.reference),r=e.map(c=>c==null?void 0:c.floating),o=e.map(c=>c==null?void 0:c.item),n=C.useCallback(c=>rr(c,e,"reference"),t),s=C.useCallback(c=>rr(c,e,"floating"),r),l=C.useCallback(c=>rr(c,e,"item"),o);return C.useMemo(()=>({getReferenceProps:n,getFloatingProps:s,getItemProps:l}),[n,s,l])}const ds="Escape";function Gt(e,t,r){switch(e){case"vertical":return t;case"horizontal":return r;default:return t||r}}function wt(e,t){return Gt(t,e===tn||e===Ht,e===ft||e===gt)}function or(e,t,r){return Gt(t,e===Ht,r?e===ft:e===gt)||e==="Enter"||e===" "||e===""}function co(e,t,r){return Gt(t,r?e===ft:e===gt,e===Ht)}function ao(e,t,r,o){const n=r?e===gt:e===ft,s=e===tn;return t==="both"||t==="horizontal"&&o&&o>1?e===ds:Gt(t,n,s)}function fs(e,t){const{open:r,onOpenChange:o,elements:n,floatingId:s}=e,{listRef:l,activeIndex:c,onNavigate:d=()=>{},enabled:a=!0,selectedIndex:u=null,allowEscape:g=!1,loop:f=!1,nested:p=!1,rtl:x=!1,virtual:h=!1,focusItemOnOpen:y="auto",focusItemOnHover:m=!0,openOnArrowKeyDown:v=!0,disabledIndices:k=void 0,orientation:R="vertical",parentOrientation:I,cols:P=1,scrollItemIntoView:L=!0,virtualItemRef:j,itemSizes:Z,dense:$=!1}=t;process.env.NODE_ENV!=="production"&&(g&&(f||er("`useListNavigation` looping must be enabled to allow escaping."),h||er("`useListNavigation` must be virtual to allow escaping.")),R==="vertical"&&P>1&&er("In grid list navigation mode (`cols` > 1), the `orientation` should",'be either "horizontal" or "both".'));const F=Mt(n.floating),Y=Se(F),U=wr(),S=Ut();se(()=>{e.dataRef.current.orientation=R},[e,R]);const E=ue(()=>{d(b.current===-1?null:b.current)}),_=hr(n.domReference),D=C.useRef(y),b=C.useRef(u??-1),T=C.useRef(null),N=C.useRef(!0),ne=C.useRef(E),be=C.useRef(!!n.floating),V=C.useRef(r),q=C.useRef(!1),H=C.useRef(!1),J=Se(k),de=Se(r),tt=Se(L),Ge=Se(u),[Oe,Ke]=C.useState(),[z,G]=C.useState(),B=ue(()=>{function M(te){if(h){var ie;(ie=te.id)!=null&&ie.endsWith("-fui-option")&&(te.id=s+"-"+Math.random().toString(16).slice(2,10)),Ke(te.id),S==null||S.events.emit("virtualfocus",te),j&&(j.current=te)}else Be(te,{sync:q.current,preventScroll:!0})}const W=l.current[b.current],A=H.current;W&&M(W),(q.current?te=>te():requestAnimationFrame)(()=>{const te=l.current[b.current]||W;if(!te)return;W||M(te);const ie=tt.current;ie&&oe&&(A||!N.current)&&(te.scrollIntoView==null||te.scrollIntoView(typeof ie=="boolean"?{block:"nearest",inline:"nearest"}:ie))})});se(()=>{a&&(r&&n.floating?D.current&&u!=null&&(H.current=!0,b.current=u,E()):be.current&&(b.current=-1,ne.current()))},[a,r,n.floating,u,E]),se(()=>{if(a&&r&&n.floating)if(c==null){if(q.current=!1,Ge.current!=null)return;if(be.current&&(b.current=-1,B()),(!V.current||!be.current)&&D.current&&(T.current!=null||D.current===!0&&T.current==null)){let M=0;const W=()=>{l.current[0]==null?(M<2&&(M?requestAnimationFrame:queueMicrotask)(W),M++):(b.current=T.current==null||or(T.current,R,x)||p?Zt(l,J.current):Br(l,J.current),T.current=null,E())};W()}}else lt(l,c)||(b.current=c,B(),H.current=!1)},[a,r,n.floating,c,Ge,p,l,R,x,E,B,J]),se(()=>{var M;if(!a||n.floating||!S||h||!be.current)return;const W=S.nodesRef.current,A=(M=W.find(ie=>ie.id===U))==null||(M=M.context)==null?void 0:M.elements.floating,Q=Pe(we(n.floating)),te=W.some(ie=>ie.context&&xe(ie.context.elements.floating,Q));A&&!te&&N.current&&A.focus({preventScroll:!0})},[a,n.floating,S,U,h]),se(()=>{if(!a||!S||!h||U)return;function M(W){G(W.id),j&&(j.current=W)}return S.events.on("virtualfocus",M),()=>{S.events.off("virtualfocus",M)}},[a,S,h,U,j]),se(()=>{ne.current=E,V.current=r,be.current=!!n.floating}),se(()=>{r||(T.current=null,D.current=y)},[r,y]);const ee=c!=null,oe=C.useMemo(()=>{function M(A){if(!de.current)return;const Q=l.current.indexOf(A);Q!==-1&&b.current!==Q&&(b.current=Q,E())}return{onFocus(A){let{currentTarget:Q}=A;q.current=!0,M(Q)},onClick:A=>{let{currentTarget:Q}=A;return Q.focus({preventScroll:!0})},onMouseMove(A){let{currentTarget:Q}=A;q.current=!0,H.current=!1,m&&M(Q)},onPointerLeave(A){let{pointerType:Q}=A;if(!(!N.current||Q==="touch")&&(q.current=!0,!!m&&(b.current=-1,E(),!h))){var te;(te=Y.current)==null||te.focus({preventScroll:!0})}}}},[de,Y,m,l,E,h]),K=C.useCallback(()=>{var M;return I??(S==null||(M=S.nodesRef.current.find(W=>W.id===U))==null||(M=M.context)==null||(M=M.dataRef)==null?void 0:M.current.orientation)},[U,S,I]),pe=ue(M=>{if(N.current=!1,q.current=!0,M.which===229||!de.current&&M.currentTarget===Y.current)return;if(p&&ao(M.key,R,x,P)){wt(M.key,K())||ae(M),o(!1,M.nativeEvent,"list-navigation"),le(n.domReference)&&(h?S==null||S.events.emit("virtualfocus",n.domReference):n.domReference.focus());return}const W=b.current,A=Zt(l,k),Q=Br(l,k);if(_||(M.key==="Home"&&(ae(M),b.current=A,E()),M.key==="End"&&(ae(M),b.current=Q,E())),P>1){const te=Z||Array.from({length:l.current.length},()=>({width:1,height:1})),ie=nl(te,P,$),rt=ie.findIndex(ve=>ve!=null&&!Rt(l,ve,k)),ht=ie.reduce((ve,je,pt)=>je!=null&&!Rt(l,je,k)?pt:ve,-1),ot=ie[ol({current:ie.map(ve=>ve!=null?l.current[ve]:null)},{event:M,orientation:R,loop:f,rtl:x,cols:P,disabledIndices:ll([...(typeof k!="function"?k:null)||l.current.map((ve,je)=>Rt(l,je,k)?je:void 0),void 0],ie),minIndex:rt,maxIndex:ht,prevIndex:il(b.current>Q?A:b.current,te,ie,P,M.key===Ht?"bl":M.key===(x?ft:gt)?"tr":"tl"),stopEvent:!0})];if(ot!=null&&(b.current=ot,E()),R==="both")return}if(wt(M.key,R)){if(ae(M),r&&!h&&Pe(M.currentTarget.ownerDocument)===M.currentTarget){b.current=or(M.key,R,x)?A:Q,E();return}or(M.key,R,x)?f?b.current=W>=Q?g&&W!==l.current.length?-1:A:he(l,{startingIndex:W,disabledIndices:k}):b.current=Math.min(Q,he(l,{startingIndex:W,disabledIndices:k})):f?b.current=W<=A?g&&W!==-1?l.current.length:Q:he(l,{startingIndex:W,decrement:!0,disabledIndices:k}):b.current=Math.max(A,he(l,{startingIndex:W,decrement:!0,disabledIndices:k})),lt(l,b.current)&&(b.current=-1),E()}}),ce=C.useMemo(()=>h&&r&&ee&&{"aria-activedescendant":z||Oe},[h,r,ee,z,Oe]),fe=C.useMemo(()=>({"aria-orientation":R==="both"?void 0:R,..._?{}:ce,onKeyDown:pe,onPointerMove(){N.current=!0}}),[ce,pe,R,_]),ke=C.useMemo(()=>{function M(A){y==="auto"&&Bo(A.nativeEvent)&&(D.current=!0)}function W(A){D.current=y,y==="auto"&&Wo(A.nativeEvent)&&(D.current=!0)}return{...ce,onKeyDown(A){N.current=!1;const Q=A.key.startsWith("Arrow"),te=["Home","End"].includes(A.key),ie=Q||te,rt=co(A.key,R,x),ht=ao(A.key,R,x,P),ot=co(A.key,K(),x),ve=wt(A.key,R),je=(p?ot:ve)||A.key==="Enter"||A.key.trim()==="";if(h&&r){const bt=S==null?void 0:S.nodesRef.current.find(xt=>xt.parentId==null),Me=S&&bt?Yi(S.nodesRef.current,bt.id):null;if(ie&&Me&&j){const xt=new KeyboardEvent("keydown",{key:A.key,bubbles:!0});if(rt||ht){var pt,Sr;const hn=((pt=Me.context)==null?void 0:pt.elements.domReference)===A.currentTarget,Ir=ht&&!hn?(Sr=Me.context)==null?void 0:Sr.elements.domReference:rt?l.current.find(Or=>(Or==null?void 0:Or.id)===Oe):null;Ir&&(ae(A),Ir.dispatchEvent(xt),G(void 0))}if((ve||te)&&Me.context&&Me.context.open&&Me.parentId&&A.currentTarget!==Me.context.elements.domReference){var Er;ae(A),(Er=Me.context.elements.domReference)==null||Er.dispatchEvent(xt);return}}return pe(A)}if(!(!r&&!v&&Q)){if(je){const bt=wt(A.key,K());T.current=p&&bt?null:A.key}if(p){ot&&(ae(A),r?(b.current=Zt(l,J.current),E()):o(!0,A.nativeEvent,"list-navigation"));return}ve&&(u!=null&&(b.current=u),ae(A),!r&&v?o(!0,A.nativeEvent,"list-navigation"):pe(A),r&&E())}},onFocus(){r&&!h&&(b.current=-1,E())},onPointerDown:W,onPointerEnter:W,onMouseDown:M,onClick:M}},[Oe,ce,P,pe,J,y,l,p,E,o,r,v,R,K,x,u,S,h,j]);return C.useMemo(()=>a?{reference:ke,floating:fe,item:oe}:{},[a,ke,fe,oe])}const gs=new Map([["select","listbox"],["combobox","listbox"],["label",!1]]);function hs(e,t){var r,o;t===void 0&&(t={});const{open:n,elements:s,floatingId:l}=e,{enabled:c=!0,role:d="dialog"}=t,a=rn(),u=((r=s.domReference)==null?void 0:r.id)||a,g=C.useMemo(()=>{var v;return((v=Mt(s.floating))==null?void 0:v.id)||l},[s.floating,l]),f=(o=gs.get(d))!=null?o:d,x=wr()!=null,h=C.useMemo(()=>f==="tooltip"||d==="label"?{["aria-"+(d==="label"?"labelledby":"describedby")]:n?g:void 0}:{"aria-expanded":n?"true":"false","aria-haspopup":f==="alertdialog"?"dialog":f,"aria-controls":n?g:void 0,...f==="listbox"&&{role:"combobox"},...f==="menu"&&{id:u},...f==="menu"&&x&&{role:"menuitem"},...d==="select"&&{"aria-autocomplete":"none"},...d==="combobox"&&{"aria-autocomplete":"list"}},[f,g,x,n,u,d]),y=C.useMemo(()=>{const v={id:g,...f&&{role:f}};return f==="tooltip"||d==="label"?v:{...v,...f==="menu"&&{"aria-labelledby":u}}},[f,g,u,d]),m=C.useCallback(v=>{let{active:k,selected:R}=v;const I={role:"option",...k&&{id:g+"-fui-option"}};switch(d){case"select":case"combobox":return{...I,"aria-selected":R}}return{}},[g,d]);return C.useMemo(()=>c?{reference:h,floating:y,item:m}:{},[c,h,y,m])}function ps(e,t){var r;const{open:o,dataRef:n}=e,{listRef:s,activeIndex:l,onMatch:c,onTypingChange:d,enabled:a=!0,findMatch:u=null,resetMs:g=750,ignoreKeys:f=[],selectedIndex:p=null}=t,x=C.useRef(-1),h=C.useRef(""),y=C.useRef((r=p??l)!=null?r:-1),m=C.useRef(null),v=ue(c),k=ue(d),R=Se(u),I=Se(f);se(()=>{o&&(pr(x),m.current=null,h.current="")},[o]),se(()=>{if(o&&h.current===""){var $;y.current=($=p??l)!=null?$:-1}},[o,p,l]);const P=ue($=>{$?n.current.typing||(n.current.typing=$,k($)):n.current.typing&&(n.current.typing=$,k($))}),L=ue($=>{function F(_,D,b){const T=R.current?R.current(D,b):D.find(N=>(N==null?void 0:N.toLocaleLowerCase().indexOf(b.toLocaleLowerCase()))===0);return T?_.indexOf(T):-1}const Y=s.current;if(h.current.length>0&&h.current[0]!==" "&&(F(Y,Y,h.current)===-1?P(!1):$.key===" "&&ae($)),Y==null||I.current.includes($.key)||$.key.length!==1||$.ctrlKey||$.metaKey||$.altKey)return;o&&$.key!==" "&&(ae($),P(!0)),Y.every(_=>{var D,b;return _?((D=_[0])==null?void 0:D.toLocaleLowerCase())!==((b=_[1])==null?void 0:b.toLocaleLowerCase()):!0})&&h.current===$.key&&(h.current="",y.current=m.current),h.current+=$.key,pr(x),x.current=window.setTimeout(()=>{h.current="",y.current=m.current,P(!1)},g);const S=y.current,E=F(Y,[...Y.slice((S||0)+1),...Y.slice(0,(S||0)+1)],h.current);E!==-1?(v(E),m.current=E):$.key!==" "&&(h.current="",P(!1))}),j=C.useMemo(()=>({onKeyDown:L}),[L]),Z=C.useMemo(()=>({onKeyDown:L,onKeyUp($){$.key===" "&&P(!1)}}),[L,P]);return C.useMemo(()=>a?{reference:j,floating:Z}:{},[a,j,Z])}const bs=(e,t)=>`${e}-${t}`,xs=(e=Ro,t=So,r=Eo,o,n)=>{const[s,l]=X.useState(!1),c=o!==void 0,d=c?o:s,a=X.useCallback(v=>{c||l(v),n==null||n(v)},[c,n]),u=X.useMemo(()=>bs(e,t),[e,t]),{refs:g,floatingStyles:f,context:p}=sn({open:d,onOpenChange:a,placement:u,middleware:[Qo(r),en(),Jo({padding:8})],whileElementsMounted:Yo}),x=nn(p),h=ln(p,{escapeKey:!0,outsidePress:!0}),{getReferenceProps:y,getFloatingProps:m}=cn([x,h]);return{isOpen:d,setIsOpen:a,refs:{setReference:g.setReference,setFloating:g.setFloating},floatingStyles:f,getReferenceProps:y,getFloatingProps:m}},nr=w.classNameGetter("dropdown"),ms=({trigger:e,children:t,placement:r=Ro,align:o=So,offset:n=Eo,open:s,onOpenChange:l,portalRenderNode:c,classnames:d,className:a,fullWidth:u,...g})=>{const{isOpen:f,refs:p,floatingStyles:x,getReferenceProps:h,getFloatingProps:y}=xs(r,o,n,s,l),m=()=>{const v=w.jsx(si,{ref:p.setFloating,className:nr("content",d==null?void 0:d.content),style:x,$isOpen:f,...y(),children:t});return c?Ft.createPortal(v,c):v};return w.jsxs(ii,{...g,className:nr("container",a,d==null?void 0:d.container),$fullWidth:u,children:[w.jsx(li,{ref:p.setReference,className:nr("trigger",d==null?void 0:d.trigger),$fullWidth:u,...h(),children:e}),m()]})},uo={hidden:["M13.359 11.238C15.06 9.72 16 8 16 8s-3-5.5-8-5.5a7 7 0 0 0-2.79.588l.77.771A6 6 0 0 1 8 3.5c2.12 0 3.879 1.168 5.168 2.457A13 13 0 0 1 14.828 8q-.086.13-.195.288c-.335.48-.83 1.12-1.465 1.755q-.247.248-.517.486z","M11.297 9.176a3.5 3.5 0 0 0-4.474-4.474l.823.823a2.5 2.5 0 0 1 2.829 2.829zm-2.943 1.299.822.822a3.5 3.5 0 0 1-4.474-4.474l.823.823a2.5 2.5 0 0 0 2.829 2.829","M3.35 5.47q-.27.24-.518.487A13 13 0 0 0 1.172 8l.195.288c.335.48.83 1.12 1.465 1.755C4.121 11.332 5.881 12.5 8 12.5c.716 0 1.39-.133 2.02-.36l.77.772A7 7 0 0 1 8 13.5C3 13.5 0 8 0 8s.939-1.721 2.641-3.238l.708.709zm10.296 8.884-12-12 .708-.708 12 12z"],visible:["M16 8s-3-5.5-8-5.5S0 8 0 8s3 5.5 8 5.5S16 8 16 8M1.173 8a13 13 0 0 1 1.66-2.043C4.12 4.668 5.88 3.5 8 3.5s3.879 1.168 5.168 2.457A13 13 0 0 1 14.828 8q-.086.13-.195.288c-.335.48-.83 1.12-1.465 1.755C11.879 11.332 10.119 12.5 8 12.5s-3.879-1.168-5.168-2.457A13 13 0 0 1 1.172 8z","M8 5.5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5M4.5 8a3.5 3.5 0 1 1 7 0 3.5 3.5 0 0 1-7 0"]},Cs=(e,t,r)=>r?e.input.wrapper.disabled.backgroundColor:t==="warning"?e.input.state.warning.wrapper.backgroundColor:t==="error"?e.input.state.error.wrapper.backgroundColor:e.input.wrapper.backgroundColor,vs=(e,t,r)=>r?e.input.wrapper.disabled.borderColor:t==="warning"?e.input.state.warning.wrapper.borderColor:t==="error"?e.input.state.error.wrapper.borderColor:e.input.wrapper.borderColor,ws=(e,t)=>t==="warning"?e.input.state.warning.wrapper.focus.outlineColor:t==="error"?e.input.state.error.wrapper.focus.outlineColor:e.input.wrapper.focus.outlineColor,ys=(e,t)=>t==="warning"?e.input.state.warning.label.color:t==="error"?e.input.state.error.label.color:e.input.label.color,ks=(e,t)=>t==="warning"?e.input.state.warning.input.color:t==="error"?e.input.state.error.input.color:e.input.input.color,Rs=(e,t)=>t==="warning"?e.input.state.warning.input.placeholderColor:t==="error"?e.input.state.error.input.placeholderColor:e.input.input.placeholderColor,Ss=(e,t,r)=>r?e.input.icon.disabled.color:t==="warning"?e.input.state.warning.icon.color:t==="error"?e.input.state.error.icon.color:e.input.icon.color,Es=(e,t)=>t==="warning"?e.input.state.warning.icon.color:t==="error"?e.input.state.error.icon.color:e.input.toggle.color,Is=O.div`
234
+ */var Bi=["input:not([inert])","select:not([inert])","textarea:not([inert])","a[href]:not([inert])","button:not([inert])","[tabindex]:not(slot):not([inert])","audio[controls]:not([inert])","video[controls]:not([inert])",'[contenteditable]:not([contenteditable="false"]):not([inert])',"details>summary:first-of-type:not([inert])","details:not([inert])"],Pt=Bi.join(","),Ko=typeof Element>"u",nt=Ko?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,Dt=!Ko&&Element.prototype.getRootNode?function(e){var t;return e==null||(t=e.getRootNode)===null||t===void 0?void 0:t.call(e)}:function(e){return e==null?void 0:e.ownerDocument},ut=function(t,r){var o;r===void 0&&(r=!0);var i=t==null||(o=t.getAttribute)===null||o===void 0?void 0:o.call(t,"inert"),c=i===""||i==="true",l=c||r&&t&&ut(t.parentNode);return l},zi=function(t){var r,o=t==null||(r=t.getAttribute)===null||r===void 0?void 0:r.call(t,"contenteditable");return o===""||o==="true"},Go=function(t,r,o){if(ut(t))return[];var i=Array.prototype.slice.apply(t.querySelectorAll(Pt));return r&&nt.call(t,Pt)&&i.unshift(t),i=i.filter(o),i},Lt=function(t,r,o){for(var i=[],c=Array.from(t);c.length;){var l=c.shift();if(!ut(l,!1))if(l.tagName==="SLOT"){var s=l.assignedElements(),d=s.length?s:l.children,a=Lt(d,!0,o);o.flatten?i.push.apply(i,a):i.push({scopeParent:l,candidates:a})}else{var u=nt.call(l,Pt);u&&o.filter(l)&&(r||!t.includes(l))&&i.push(l);var h=l.shadowRoot||typeof o.getShadowRoot=="function"&&o.getShadowRoot(l),f=!ut(h,!1)&&(!o.shadowRootFilter||o.shadowRootFilter(l));if(h&&f){var b=Lt(h===!0?l.children:h.children,!0,o);o.flatten?i.push.apply(i,b):i.push({scopeParent:l,candidates:b})}else c.unshift.apply(c,l.children)}}return i},qo=function(t){return!isNaN(parseInt(t.getAttribute("tabindex"),10))},Xo=function(t){if(!t)throw new Error("No node provided");return t.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(t.tagName)||zi(t))&&!qo(t)?0:t.tabIndex},Wi=function(t,r){var o=Xo(t);return o<0&&r&&!qo(t)?0:o},Vi=function(t,r){return t.tabIndex===r.tabIndex?t.documentOrder-r.documentOrder:t.tabIndex-r.tabIndex},Yo=function(t){return t.tagName==="INPUT"},Hi=function(t){return Yo(t)&&t.type==="hidden"},Ui=function(t){var r=t.tagName==="DETAILS"&&Array.prototype.slice.apply(t.children).some(function(o){return o.tagName==="SUMMARY"});return r},Ki=function(t,r){for(var o=0;o<t.length;o++)if(t[o].checked&&t[o].form===r)return t[o]},Gi=function(t){if(!t.name)return!0;var r=t.form||Dt(t),o=function(s){return r.querySelectorAll('input[type="radio"][name="'+s+'"]')},i;if(typeof window<"u"&&typeof window.CSS<"u"&&typeof window.CSS.escape=="function")i=o(window.CSS.escape(t.name));else try{i=o(t.name)}catch(l){return console.error("Looks like you have a radio button with a name attribute containing invalid CSS selector characters and need the CSS.escape polyfill: %s",l.message),!1}var c=Ki(i,t.form);return!c||c===t},qi=function(t){return Yo(t)&&t.type==="radio"},Xi=function(t){return qi(t)&&!Gi(t)},Yi=function(t){var r,o=t&&Dt(t),i=(r=o)===null||r===void 0?void 0:r.host,c=!1;if(o&&o!==t){var l,s,d;for(c=!!((l=i)!==null&&l!==void 0&&(s=l.ownerDocument)!==null&&s!==void 0&&s.contains(i)||t!=null&&(d=t.ownerDocument)!==null&&d!==void 0&&d.contains(t));!c&&i;){var a,u,h;o=Dt(i),i=(a=o)===null||a===void 0?void 0:a.host,c=!!((u=i)!==null&&u!==void 0&&(h=u.ownerDocument)!==null&&h!==void 0&&h.contains(i))}}return c},Gr=function(t){var r=t.getBoundingClientRect(),o=r.width,i=r.height;return o===0&&i===0},Qi=function(t,r){var o=r.displayCheck,i=r.getShadowRoot;if(o==="full-native"&&"checkVisibility"in t){var c=t.checkVisibility({checkOpacity:!1,opacityProperty:!1,contentVisibilityAuto:!0,visibilityProperty:!0,checkVisibilityCSS:!0});return!c}if(getComputedStyle(t).visibility==="hidden")return!0;var l=nt.call(t,"details>summary:first-of-type"),s=l?t.parentElement:t;if(nt.call(s,"details:not([open]) *"))return!0;if(!o||o==="full"||o==="full-native"||o==="legacy-full"){if(typeof i=="function"){for(var d=t;t;){var a=t.parentElement,u=Dt(t);if(a&&!a.shadowRoot&&i(a)===!0)return Gr(t);t.assignedSlot?t=t.assignedSlot:!a&&u!==t.ownerDocument?t=u.host:t=a}t=d}if(Yi(t))return!t.getClientRects().length;if(o!=="legacy-full")return!0}else if(o==="non-zero-area")return Gr(t);return!1},Zi=function(t){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(t.tagName))for(var r=t.parentElement;r;){if(r.tagName==="FIELDSET"&&r.disabled){for(var o=0;o<r.children.length;o++){var i=r.children.item(o);if(i.tagName==="LEGEND")return nt.call(r,"fieldset[disabled] *")?!0:!i.contains(t)}return!0}r=r.parentElement}return!1},gr=function(t,r){return!(r.disabled||ut(r)||Hi(r)||Qi(r,t)||Ui(r)||Zi(r))},hr=function(t,r){return!(Xi(r)||Xo(r)<0||!gr(t,r))},Ji=function(t){var r=parseInt(t.getAttribute("tabindex"),10);return!!(isNaN(r)||r>=0)},Qo=function(t){var r=[],o=[];return t.forEach(function(i,c){var l=!!i.scopeParent,s=l?i.scopeParent:i,d=Wi(s,l),a=l?Qo(i.candidates):s;d===0?l?r.push.apply(r,a):r.push(s):o.push({documentOrder:c,tabIndex:d,item:i,isScope:l,content:a})}),o.sort(Vi).reduce(function(i,c){return c.isScope?i.push.apply(i,c.content):i.push(c.content),i},[]).concat(r)},vr=function(t,r){r=r||{};var o;return r.getShadowRoot?o=Lt([t],r.includeContainer,{filter:hr.bind(null,r),flatten:!1,getShadowRoot:r.getShadowRoot,shadowRootFilter:Ji}):o=Go(t,r.includeContainer,hr.bind(null,r)),Qo(o)},el=function(t,r){r=r||{};var o;return r.getShadowRoot?o=Lt([t],r.includeContainer,{filter:gr.bind(null,r),flatten:!0,getShadowRoot:r.getShadowRoot}):o=Go(t,r.includeContainer,gr.bind(null,r)),o},Zo=function(t,r){if(r=r||{},!t)throw new Error("No node provided");return nt.call(t,Pt)===!1?!1:hr(r,t)};function tl(){const e=navigator.userAgentData;return e!=null&&e.platform?e.platform:navigator.platform}function Jo(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(t=>{let{brand:r,version:o}=t;return r+"/"+o}).join(" "):navigator.userAgent}function rl(){return/apple/i.test(navigator.vendor)}function pr(){const e=/android/i;return e.test(tl())||e.test(Jo())}function ol(){return Jo().includes("jsdom/")}const qr="data-floating-ui-focusable",nl="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])",Yt="ArrowLeft",Qt="ArrowRight",il="ArrowUp",ll="ArrowDown";function Ne(e){let t=e.activeElement;for(;((r=t)==null||(r=r.shadowRoot)==null?void 0:r.activeElement)!=null;){var r;t=t.shadowRoot.activeElement}return t}function me(e,t){if(!e||!t)return!1;const r=t.getRootNode==null?void 0:t.getRootNode();if(e.contains(t))return!0;if(r&&ur(r)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function Fe(e){return"composedPath"in e?e.composedPath()[0]:e.target}function Zt(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);const r=e;return r.target!=null&&t.contains(r.target)}function cl(e){return e.matches("html,body")}function Se(e){return(e==null?void 0:e.ownerDocument)||document}function en(e){return se(e)&&e.matches(nl)}function br(e){return e?e.getAttribute("role")==="combobox"&&en(e):!1}function Nt(e){return e?e.hasAttribute(qr)?e:e.querySelector("["+qr+"]")||e:null}function Ke(e,t,r){return r===void 0&&(r=!0),e.filter(i=>{var c;return i.parentId===t&&(!r||((c=i.context)==null?void 0:c.open))}).flatMap(i=>[i,...Ke(e,i.id,r)])}function sl(e,t){let r,o=-1;function i(c,l){l>o&&(r=c,o=l),Ke(e,c).forEach(d=>{i(d.id,l+1)})}return i(t,0),e.find(c=>c.id===r)}function Xr(e,t){var r;let o=[],i=(r=e.find(c=>c.id===t))==null?void 0:r.parentId;for(;i;){const c=e.find(l=>l.id===i);i=c==null?void 0:c.parentId,c&&(o=o.concat(c))}return o}function fe(e){e.preventDefault(),e.stopPropagation()}function al(e){return"nativeEvent"in e}function tn(e){return e.mozInputSource===0&&e.isTrusted?!0:pr()&&e.pointerType?e.type==="click"&&e.buttons===1:e.detail===0&&!e.pointerType}function rn(e){return ol()?!1:!pr()&&e.width===0&&e.height===0||pr()&&e.width===1&&e.height===1&&e.pressure===0&&e.detail===0&&e.pointerType==="mouse"||e.width<1&&e.height<1&&e.pressure===0&&e.detail===0&&e.pointerType==="touch"}function Yr(e,t){return["mouse","pen"].includes(e)}var ul=typeof document<"u",dl=function(){},ae=ul?_.useLayoutEffect:dl;const fl={...w};function Te(e){const t=w.useRef(e);return ae(()=>{t.current=e}),t}const gl=fl.useInsertionEffect,hl=gl||(e=>e());function ge(e){const t=w.useRef(()=>{if(process.env.NODE_ENV!=="production")throw new Error("Cannot call an event handler while rendering.")});return hl(()=>{t.current=e}),w.useCallback(function(){for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return t.current==null?void 0:t.current(...o)},[])}function yt(e,t,r){return Math.floor(e/t)!==r}function at(e,t){return t<0||t>=e.current.length}function Jt(e,t){return be(e,{disabledIndices:t})}function Qr(e,t){return be(e,{decrement:!0,startingIndex:e.current.length,disabledIndices:t})}function be(e,t){let{startingIndex:r=-1,decrement:o=!1,disabledIndices:i,amount:c=1}=t===void 0?{}:t,l=r;do l+=o?-c:c;while(l>=0&&l<=e.current.length-1&&It(e,l,i));return l}function pl(e,t){let{event:r,orientation:o,loop:i,rtl:c,cols:l,disabledIndices:s,minIndex:d,maxIndex:a,prevIndex:u,stopEvent:h=!1}=t,f=u;if(r.key===il){if(h&&fe(r),u===-1)f=a;else if(f=be(e,{startingIndex:f,amount:l,decrement:!0,disabledIndices:s}),i&&(u-l<d||f<0)){const b=u%l,C=a%l,g=a-(C-b);C===b?f=a:f=C>b?g:g-l}at(e,f)&&(f=u)}if(r.key===ll&&(h&&fe(r),u===-1?f=d:(f=be(e,{startingIndex:u,amount:l,disabledIndices:s}),i&&u+l>a&&(f=be(e,{startingIndex:u%l-l,amount:l,disabledIndices:s}))),at(e,f)&&(f=u)),o==="both"){const b=et(u/l);r.key===(c?Yt:Qt)&&(h&&fe(r),u%l!==l-1?(f=be(e,{startingIndex:u,disabledIndices:s}),i&&yt(f,l,b)&&(f=be(e,{startingIndex:u-u%l-1,disabledIndices:s}))):i&&(f=be(e,{startingIndex:u-u%l-1,disabledIndices:s})),yt(f,l,b)&&(f=u)),r.key===(c?Qt:Yt)&&(h&&fe(r),u%l!==0?(f=be(e,{startingIndex:u,decrement:!0,disabledIndices:s}),i&&yt(f,l,b)&&(f=be(e,{startingIndex:u+(l-u%l),decrement:!0,disabledIndices:s}))):i&&(f=be(e,{startingIndex:u+(l-u%l),decrement:!0,disabledIndices:s})),yt(f,l,b)&&(f=u));const C=et(a/l)===b;at(e,f)&&(i&&C?f=r.key===(c?Qt:Yt)?a:be(e,{startingIndex:u-u%l-1,disabledIndices:s}):f=u)}return f}function bl(e,t,r){const o=[];let i=0;return e.forEach((c,l)=>{let{width:s,height:d}=c;if(s>t&&process.env.NODE_ENV!=="production")throw new Error("[Floating UI]: Invalid grid - item width at index "+l+" is greater than grid columns");let a=!1;for(r&&(i=0);!a;){const u=[];for(let h=0;h<s;h++)for(let f=0;f<d;f++)u.push(i+h+f*t);i%t+s<=t&&u.every(h=>o[h]==null)?(u.forEach(h=>{o[h]=l}),a=!0):i++}}),[...o]}function xl(e,t,r,o,i){if(e===-1)return-1;const c=r.indexOf(e),l=t[e];switch(i){case"tl":return c;case"tr":return l?c+l.width-1:c;case"bl":return l?c+(l.height-1)*o:c;case"br":return r.lastIndexOf(e)}}function ml(e,t){return t.flatMap((r,o)=>e.includes(r)?[o]:[])}function It(e,t,r){if(typeof r=="function")return r(t);if(r)return r.includes(t);const o=e.current[t];return o==null||o.hasAttribute("disabled")||o.getAttribute("aria-disabled")==="true"}const Ht=()=>({getShadowRoot:!0,displayCheck:typeof ResizeObserver=="function"&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function on(e,t){const r=vr(e,Ht()),o=r.length;if(o===0)return;const i=Ne(Se(e)),c=r.indexOf(i),l=c===-1?t===1?0:o-1:c+t;return r[l]}function Cl(e){return on(Se(e).body,1)||e}function vl(e){return on(Se(e).body,-1)||e}function Zr(e,t){const r=t||e.currentTarget,o=e.relatedTarget;return!o||!me(r,o)}function Jr(e,t,r){let{reference:o,floating:i}=e;const c=Ae(t),l=Uo(t),s=Ho(l),d=Be(t),a=c==="y",u=o.x+o.width/2-i.width/2,h=o.y+o.height/2-i.height/2,f=o[s]/2-i[s]/2;let b;switch(d){case"top":b={x:u,y:o.y-i.height};break;case"bottom":b={x:u,y:o.y+o.height};break;case"right":b={x:o.x+o.width,y:h};break;case"left":b={x:o.x-i.width,y:h};break;default:b={x:o.x,y:o.y}}switch(pt(t)){case"start":b[l]-=f*(r&&a?-1:1);break;case"end":b[l]+=f*(r&&a?-1:1);break}return b}const wl=async(e,t,r)=>{const{placement:o="bottom",strategy:i="absolute",middleware:c=[],platform:l}=r,s=c.filter(Boolean),d=await(l.isRTL==null?void 0:l.isRTL(t));let a=await l.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:h}=Jr(a,o,d),f=o,b={},C=0;for(let g=0;g<s.length;g++){const{name:y,fn:p}=s[g],{x:v,y:k,data:S,reset:T}=await p({x:u,y:h,initialPlacement:o,placement:f,strategy:i,middlewareData:b,rects:a,platform:l,elements:{reference:e,floating:t}});u=v??u,h=k??h,b={...b,[y]:{...b[y],...S}},T&&C<=50&&(C++,typeof T=="object"&&(T.placement&&(f=T.placement),T.rects&&(a=T.rects===!0?await l.getElementRects({reference:e,floating:t,strategy:i}):T.rects),{x:u,y:h}=Jr(a,f,d)),g=-1)}return{x:u,y:h,placement:f,strategy:i,middlewareData:b}};async function wr(e,t){var r;t===void 0&&(t={});const{x:o,y:i,platform:c,rects:l,elements:s,strategy:d}=e,{boundary:a="clippingAncestors",rootBoundary:u="viewport",elementContext:h="floating",altBoundary:f=!1,padding:b=0}=ht(t,e),C=ji(b),y=s[f?h==="floating"?"reference":"floating":h],p=At(await c.getClippingRect({element:(r=await(c.isElement==null?void 0:c.isElement(y)))==null||r?y:y.contextElement||await(c.getDocumentElement==null?void 0:c.getDocumentElement(s.floating)),boundary:a,rootBoundary:u,strategy:d})),v=h==="floating"?{x:o,y:i,width:l.floating.width,height:l.floating.height}:l.reference,k=await(c.getOffsetParent==null?void 0:c.getOffsetParent(s.floating)),S=await(c.isElement==null?void 0:c.isElement(k))?await(c.getScale==null?void 0:c.getScale(k))||{x:1,y:1}:{x:1,y:1},T=At(c.convertOffsetParentRelativeRectToViewportRelativeRect?await c.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:v,offsetParent:k,strategy:d}):v);return{top:(p.top-T.top+C.top)/S.y,bottom:(T.bottom-p.bottom+C.bottom)/S.y,left:(p.left-T.left+C.left)/S.x,right:(T.right-p.right+C.right)/S.x}}const yl=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var r,o;const{placement:i,middlewareData:c,rects:l,initialPlacement:s,platform:d,elements:a}=t,{mainAxis:u=!0,crossAxis:h=!0,fallbackPlacements:f,fallbackStrategy:b="bestFit",fallbackAxisSideDirection:C="none",flipAlignment:g=!0,...y}=ht(e,t);if((r=c.arrow)!=null&&r.alignmentOffset)return{};const p=Be(i),v=Ae(s),k=Be(s)===s,S=await(d.isRTL==null?void 0:d.isRTL(a.floating)),T=f||(k||!g?[Mt(s)]:Pi(s)),M=C!=="none";!f&&M&&T.push(...Fi(s,g,C,S));const N=[s,...T],B=await wr(t,y),X=[];let O=((o=c.flip)==null?void 0:o.overflows)||[];if(u&&X.push(B[p]),h){const R=Ai(i,l,S);X.push(B[R[0]],B[R[1]])}if(O=[...O,{placement:i,overflows:X}],!X.every(R=>R<=0)){var F,G;const R=(((F=c.flip)==null?void 0:F.index)||0)+1,$=N[R];if($&&(!(h==="alignment"?v!==Ae($):!1)||O.every(x=>Ae(x.placement)===v?x.overflows[0]>0:!0)))return{data:{index:R,overflows:O},reset:{placement:$}};let j=(G=O.filter(L=>L.overflows[0]<=0).sort((L,x)=>L.overflows[1]-x.overflows[1])[0])==null?void 0:G.placement;if(!j)switch(b){case"bestFit":{var V;const L=(V=O.filter(x=>{if(M){const E=Ae(x.placement);return E===v||E==="y"}return!0}).map(x=>[x.placement,x.overflows.filter(E=>E>0).reduce((E,A)=>E+A,0)]).sort((x,E)=>x[1]-E[1])[0])==null?void 0:V[0];L&&(j=L);break}case"initialPlacement":j=s;break}if(i!==j)return{reset:{placement:j}}}return{}}}},kl=new Set(["left","top"]);async function Sl(e,t){const{placement:r,platform:o,elements:i}=e,c=await(o.isRTL==null?void 0:o.isRTL(i.floating)),l=Be(r),s=pt(r),d=Ae(r)==="y",a=kl.has(l)?-1:1,u=c&&d?-1:1,h=ht(t,e);let{mainAxis:f,crossAxis:b,alignmentAxis:C}=typeof h=="number"?{mainAxis:h,crossAxis:0,alignmentAxis:null}:{mainAxis:h.mainAxis||0,crossAxis:h.crossAxis||0,alignmentAxis:h.alignmentAxis};return s&&typeof C=="number"&&(b=s==="end"?C*-1:C),d?{x:b*u,y:f*a}:{x:f*a,y:b*u}}const Rl=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,o;const{x:i,y:c,placement:l,middlewareData:s}=t,d=await Sl(t,e);return l===((r=s.offset)==null?void 0:r.placement)&&(o=s.arrow)!=null&&o.alignmentOffset?{}:{x:i+d.x,y:c+d.y,data:{...d,placement:l}}}}},El=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:r,y:o,placement:i}=t,{mainAxis:c=!0,crossAxis:l=!1,limiter:s={fn:y=>{let{x:p,y:v}=y;return{x:p,y:v}}},...d}=ht(e,t),a={x:r,y:o},u=await wr(t,d),h=Ae(Be(i)),f=Vo(h);let b=a[f],C=a[h];if(c){const y=f==="y"?"top":"left",p=f==="y"?"bottom":"right",v=b+u[y],k=b-u[p];b=Hr(v,b,k)}if(l){const y=h==="y"?"top":"left",p=h==="y"?"bottom":"right",v=C+u[y],k=C-u[p];C=Hr(v,C,k)}const g=s.fn({...t,[f]:b,[h]:C});return{...g,data:{x:g.x-r,y:g.y-o,enabled:{[f]:c,[h]:l}}}}}},$l=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var r,o;const{placement:i,rects:c,platform:l,elements:s}=t,{apply:d=()=>{},...a}=ht(e,t),u=await wr(t,a),h=Be(i),f=pt(i),b=Ae(i)==="y",{width:C,height:g}=c.floating;let y,p;h==="top"||h==="bottom"?(y=h,p=f===(await(l.isRTL==null?void 0:l.isRTL(s.floating))?"start":"end")?"left":"right"):(p=h,y=f==="end"?"top":"bottom");const v=g-u.top-u.bottom,k=C-u.left-u.right,S=ot(g-u[y],v),T=ot(C-u[p],k),M=!t.middlewareData.shift;let N=S,B=T;if((r=t.middlewareData.shift)!=null&&r.enabled.x&&(B=k),(o=t.middlewareData.shift)!=null&&o.enabled.y&&(N=v),M&&!f){const O=we(u.left,0),F=we(u.right,0),G=we(u.top,0),V=we(u.bottom,0);b?B=C-2*(O!==0||F!==0?O+F:we(u.left,u.right)):N=g-2*(G!==0||V!==0?G+V:we(u.top,u.bottom))}await d({...t,availableWidth:B,availableHeight:N});const X=await l.getDimensions(s.floating);return C!==X.width||g!==X.height?{reset:{rects:!0}}:{}}}};function nn(e){const t=Re(e);let r=parseFloat(t.width)||0,o=parseFloat(t.height)||0;const i=se(e),c=i?e.offsetWidth:r,l=i?e.offsetHeight:o,s=Ot(r)!==c||Ot(o)!==l;return s&&(r=c,o=l),{width:r,height:o,$:s}}function yr(e){return ie(e)?e:e.contextElement}function tt(e){const t=yr(e);if(!se(t))return Oe(1);const r=t.getBoundingClientRect(),{width:o,height:i,$:c}=nn(t);let l=(c?Ot(r.width):r.width)/o,s=(c?Ot(r.height):r.height)/i;return(!l||!Number.isFinite(l))&&(l=1),(!s||!Number.isFinite(s))&&(s=1),{x:l,y:s}}const Il=Oe(0);function ln(e){const t=ye(e);return!Wt()||!t.visualViewport?Il:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Tl(e,t,r){return t===void 0&&(t=!1),!r||t&&r!==ye(e)?!1:t}function Xe(e,t,r,o){t===void 0&&(t=!1),r===void 0&&(r=!1);const i=e.getBoundingClientRect(),c=yr(e);let l=Oe(1);t&&(o?ie(o)&&(l=tt(o)):l=tt(e));const s=Tl(c,r,o)?ln(c):Oe(0);let d=(i.left+s.x)/l.x,a=(i.top+s.y)/l.y,u=i.width/l.x,h=i.height/l.y;if(c){const f=ye(c),b=o&&ie(o)?ye(o):o;let C=f,g=dr(C);for(;g&&o&&b!==C;){const y=tt(g),p=g.getBoundingClientRect(),v=Re(g),k=p.left+(g.clientLeft+parseFloat(v.paddingLeft))*y.x,S=p.top+(g.clientTop+parseFloat(v.paddingTop))*y.y;d*=y.x,a*=y.y,u*=y.x,h*=y.y,d+=k,a+=S,C=ye(g),g=dr(C)}}return At({width:u,height:h,x:d,y:a})}function Ut(e,t){const r=Vt(e).scrollLeft;return t?t.left+r:Xe(Me(e)).left+r}function cn(e,t){const r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-Ut(e,r),i=r.top+t.scrollTop;return{x:o,y:i}}function Ol(e){let{elements:t,rect:r,offsetParent:o,strategy:i}=e;const c=i==="fixed",l=Me(o),s=t?zt(t.floating):!1;if(o===l||s&&c)return r;let d={scrollLeft:0,scrollTop:0},a=Oe(1);const u=Oe(0),h=se(o);if((h||!h&&!c)&&((ze(o)!=="body"||gt(l))&&(d=Vt(o)),se(o))){const b=Xe(o);a=tt(o),u.x=b.x+o.clientLeft,u.y=b.y+o.clientTop}const f=l&&!h&&!c?cn(l,d):Oe(0);return{width:r.width*a.x,height:r.height*a.y,x:r.x*a.x-d.scrollLeft*a.x+u.x+f.x,y:r.y*a.y-d.scrollTop*a.y+u.y+f.y}}function Ml(e){return Array.from(e.getClientRects())}function Al(e){const t=Me(e),r=Vt(e),o=e.ownerDocument.body,i=we(t.scrollWidth,t.clientWidth,o.scrollWidth,o.clientWidth),c=we(t.scrollHeight,t.clientHeight,o.scrollHeight,o.clientHeight);let l=-r.scrollLeft+Ut(e);const s=-r.scrollTop;return Re(o).direction==="rtl"&&(l+=we(t.clientWidth,o.clientWidth)-i),{width:i,height:c,x:l,y:s}}const eo=25;function Pl(e,t){const r=ye(e),o=Me(e),i=r.visualViewport;let c=o.clientWidth,l=o.clientHeight,s=0,d=0;if(i){c=i.width,l=i.height;const u=Wt();(!u||u&&t==="fixed")&&(s=i.offsetLeft,d=i.offsetTop)}const a=Ut(o);if(a<=0){const u=o.ownerDocument,h=u.body,f=getComputedStyle(h),b=u.compatMode==="CSS1Compat"&&parseFloat(f.marginLeft)+parseFloat(f.marginRight)||0,C=Math.abs(o.clientWidth-h.clientWidth-b);C<=eo&&(c-=C)}else a<=eo&&(c+=a);return{width:c,height:l,x:s,y:d}}const Dl=new Set(["absolute","fixed"]);function Ll(e,t){const r=Xe(e,!0,t==="fixed"),o=r.top+e.clientTop,i=r.left+e.clientLeft,c=se(e)?tt(e):Oe(1),l=e.clientWidth*c.x,s=e.clientHeight*c.y,d=i*c.x,a=o*c.y;return{width:l,height:s,x:d,y:a}}function to(e,t,r){let o;if(t==="viewport")o=Pl(e,r);else if(t==="document")o=Al(Me(e));else if(ie(t))o=Ll(t,r);else{const i=ln(e);o={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return At(o)}function sn(e,t){const r=De(e);return r===t||!ie(r)||Pe(r)?!1:Re(r).position==="fixed"||sn(r,t)}function Nl(e,t){const r=t.get(e);if(r)return r;let o=je(e,[],!1).filter(s=>ie(s)&&ze(s)!=="body"),i=null;const c=Re(e).position==="fixed";let l=c?De(e):e;for(;ie(l)&&!Pe(l);){const s=Re(l),d=Cr(l);!d&&s.position==="fixed"&&(i=null),(c?!d&&!i:!d&&s.position==="static"&&!!i&&Dl.has(i.position)||gt(l)&&!d&&sn(e,l))?o=o.filter(u=>u!==l):i=s,l=De(l)}return t.set(e,o),o}function Fl(e){let{element:t,boundary:r,rootBoundary:o,strategy:i}=e;const l=[...r==="clippingAncestors"?zt(t)?[]:Nl(t,this._c):[].concat(r),o],s=l[0],d=l.reduce((a,u)=>{const h=to(t,u,i);return a.top=we(h.top,a.top),a.right=ot(h.right,a.right),a.bottom=ot(h.bottom,a.bottom),a.left=we(h.left,a.left),a},to(t,s,i));return{width:d.right-d.left,height:d.bottom-d.top,x:d.left,y:d.top}}function _l(e){const{width:t,height:r}=nn(e);return{width:t,height:r}}function jl(e,t,r){const o=se(t),i=Me(t),c=r==="fixed",l=Xe(e,!0,c,t);let s={scrollLeft:0,scrollTop:0};const d=Oe(0);function a(){d.x=Ut(i)}if(o||!o&&!c)if((ze(t)!=="body"||gt(i))&&(s=Vt(t)),o){const b=Xe(t,!0,c,t);d.x=b.x+t.clientLeft,d.y=b.y+t.clientTop}else i&&a();c&&!o&&i&&a();const u=i&&!o&&!c?cn(i,s):Oe(0),h=l.left+s.scrollLeft-d.x-u.x,f=l.top+s.scrollTop-d.y-u.y;return{x:h,y:f,width:l.width,height:l.height}}function er(e){return Re(e).position==="static"}function ro(e,t){if(!se(e)||Re(e).position==="fixed")return null;if(t)return t(e);let r=e.offsetParent;return Me(e)===r&&(r=r.ownerDocument.body),r}function an(e,t){const r=ye(e);if(zt(e))return r;if(!se(e)){let i=De(e);for(;i&&!Pe(i);){if(ie(i)&&!er(i))return i;i=De(i)}return r}let o=ro(e,t);for(;o&&yi(o)&&er(o);)o=ro(o,t);return o&&Pe(o)&&er(o)&&!Cr(o)?r:o||$i(e)||r}const Bl=async function(e){const t=this.getOffsetParent||an,r=this.getDimensions,o=await r(e.floating);return{reference:jl(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}};function zl(e){return Re(e).direction==="rtl"}const Wl={convertOffsetParentRelativeRectToViewportRelativeRect:Ol,getDocumentElement:Me,getClippingRect:Fl,getOffsetParent:an,getElementRects:Bl,getClientRects:Ml,getDimensions:_l,getScale:tt,isElement:ie,isRTL:zl};function un(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Vl(e,t){let r=null,o;const i=Me(e);function c(){var s;clearTimeout(o),(s=r)==null||s.disconnect(),r=null}function l(s,d){s===void 0&&(s=!1),d===void 0&&(d=1),c();const a=e.getBoundingClientRect(),{left:u,top:h,width:f,height:b}=a;if(s||t(),!f||!b)return;const C=et(h),g=et(i.clientWidth-(u+f)),y=et(i.clientHeight-(h+b)),p=et(u),k={rootMargin:-C+"px "+-g+"px "+-y+"px "+-p+"px",threshold:we(0,ot(1,d))||1};let S=!0;function T(M){const N=M[0].intersectionRatio;if(N!==d){if(!S)return l();N?l(!1,N):o=setTimeout(()=>{l(!1,1e-7)},1e3)}N===1&&!un(a,e.getBoundingClientRect())&&l(),S=!1}try{r=new IntersectionObserver(T,{...k,root:i.ownerDocument})}catch{r=new IntersectionObserver(T,k)}r.observe(e)}return l(!0),c}function kr(e,t,r,o){o===void 0&&(o={});const{ancestorScroll:i=!0,ancestorResize:c=!0,elementResize:l=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:d=!1}=o,a=yr(e),u=i||c?[...a?je(a):[],...je(t)]:[];u.forEach(p=>{i&&p.addEventListener("scroll",r,{passive:!0}),c&&p.addEventListener("resize",r)});const h=a&&s?Vl(a,r):null;let f=-1,b=null;l&&(b=new ResizeObserver(p=>{let[v]=p;v&&v.target===a&&b&&(b.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var k;(k=b)==null||k.observe(t)})),r()}),a&&!d&&b.observe(a),b.observe(t));let C,g=d?Xe(e):null;d&&y();function y(){const p=Xe(e);g&&!un(g,p)&&r(),g=p,C=requestAnimationFrame(y)}return r(),()=>{var p;u.forEach(v=>{i&&v.removeEventListener("scroll",r),c&&v.removeEventListener("resize",r)}),h==null||h(),(p=b)==null||p.disconnect(),b=null,d&&cancelAnimationFrame(C)}}const Hl=Rl,Ul=El,Kl=yl,Gl=$l,ql=(e,t,r)=>{const o=new Map,i={platform:Wl,...r},c={...i.platform,_c:o};return wl(e,t,{...i,platform:c})};var Xl=typeof document<"u",Yl=function(){},Tt=Xl?_.useLayoutEffect:Yl;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 r,o,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(o=r;o--!==0;)if(!Ft(e[o],t[o]))return!1;return!0}if(i=Object.keys(e),r=i.length,r!==Object.keys(t).length)return!1;for(o=r;o--!==0;)if(!{}.hasOwnProperty.call(t,i[o]))return!1;for(o=r;o--!==0;){const c=i[o];if(!(c==="_owner"&&e.$$typeof)&&!Ft(e[c],t[c]))return!1}return!0}return e!==e&&t!==t}function dn(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function oo(e,t){const r=dn(e);return Math.round(t*r)/r}function tr(e){const t=w.useRef(e);return Tt(()=>{t.current=e}),t}function Ql(e){e===void 0&&(e={});const{placement:t="bottom",strategy:r="absolute",middleware:o=[],platform:i,elements:{reference:c,floating:l}={},transform:s=!0,whileElementsMounted:d,open:a}=e,[u,h]=w.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[f,b]=w.useState(o);Ft(f,o)||b(o);const[C,g]=w.useState(null),[y,p]=w.useState(null),v=w.useCallback(x=>{x!==M.current&&(M.current=x,g(x))},[]),k=w.useCallback(x=>{x!==N.current&&(N.current=x,p(x))},[]),S=c||C,T=l||y,M=w.useRef(null),N=w.useRef(null),B=w.useRef(u),X=d!=null,O=tr(d),F=tr(i),G=tr(a),V=w.useCallback(()=>{if(!M.current||!N.current)return;const x={placement:t,strategy:r,middleware:f};F.current&&(x.platform=F.current),ql(M.current,N.current,x).then(E=>{const A={...E,isPositioned:G.current!==!1};R.current&&!Ft(B.current,A)&&(B.current=A,$n.flushSync(()=>{h(A)}))})},[f,t,r,F,G]);Tt(()=>{a===!1&&B.current.isPositioned&&(B.current.isPositioned=!1,h(x=>({...x,isPositioned:!1})))},[a]);const R=w.useRef(!1);Tt(()=>(R.current=!0,()=>{R.current=!1}),[]),Tt(()=>{if(S&&(M.current=S),T&&(N.current=T),S&&T){if(O.current)return O.current(S,T,V);V()}},[S,T,V,O,X]);const $=w.useMemo(()=>({reference:M,floating:N,setReference:v,setFloating:k}),[v,k]),j=w.useMemo(()=>({reference:S,floating:T}),[S,T]),L=w.useMemo(()=>{const x={position:r,left:0,top:0};if(!j.floating)return x;const E=oo(j.floating,u.x),A=oo(j.floating,u.y);return s?{...x,transform:"translate("+E+"px, "+A+"px)",...dn(j.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:E,top:A}},[r,s,j.floating,u.x,u.y]);return w.useMemo(()=>({...u,update:V,refs:$,elements:j,floatingStyles:L}),[u,V,$,j,L])}const Sr=(e,t)=>({...Hl(e),options:[e,t]}),Rr=(e,t)=>({...Ul(e),options:[e,t]}),Er=(e,t)=>({...Kl(e),options:[e,t]}),fn=(e,t)=>({...Gl(e),options:[e,t]}),Zl="data-floating-ui-focusable",no="active",io="selected",bt="ArrowLeft",xt="ArrowRight",gn="ArrowUp",Kt="ArrowDown",Jl={...w};let lo=!1,ec=0;const co=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+ec++;function tc(){const[e,t]=w.useState(()=>lo?co():void 0);return ae(()=>{e==null&&t(co())},[]),w.useEffect(()=>{lo=!0},[]),e}const rc=Jl.useId,hn=rc||tc;let dt;process.env.NODE_ENV!=="production"&&(dt=new Set);function rr(){for(var e,t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];const i="Floating UI: "+r.join(" ");if(!((e=dt)!=null&&e.has(i))){var c;(c=dt)==null||c.add(i),console.warn(i)}}function oc(){for(var e,t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];const i="Floating UI: "+r.join(" ");if(!((e=dt)!=null&&e.has(i))){var c;(c=dt)==null||c.add(i),console.error(i)}}function nc(){const e=new Map;return{emit(t,r){var o;(o=e.get(t))==null||o.forEach(i=>i(r))},on(t,r){e.has(t)||e.set(t,new Set),e.get(t).add(r)},off(t,r){var o;(o=e.get(t))==null||o.delete(r)}}}const ic=w.createContext(null),lc=w.createContext(null),$r=()=>{var e;return((e=w.useContext(ic))==null?void 0:e.id)||null},Gt=()=>w.useContext(lc);function _t(e){return"data-floating-ui-"+e}function xr(e){e.current!==-1&&(clearTimeout(e.current),e.current=-1)}let so=0;function He(e,t){t===void 0&&(t={});const{preventScroll:r=!1,cancelPrevious:o=!0,sync:i=!1}=t;o&&cancelAnimationFrame(so);const c=()=>e==null?void 0:e.focus({preventScroll:r});i?c():so=requestAnimationFrame(c)}function cc(e){return(e==null?void 0:e.ownerDocument)||document}const rt={inert:new WeakMap,"aria-hidden":new WeakMap,none:new WeakMap};function ao(e){return e==="inert"?rt.inert:e==="aria-hidden"?rt["aria-hidden"]:rt.none}let kt=new WeakSet,St={},or=0;const sc=()=>typeof HTMLElement<"u"&&"inert"in HTMLElement.prototype,pn=e=>e&&(e.host||pn(e.parentNode)),ac=(e,t)=>t.map(r=>{if(e.contains(r))return r;const o=pn(r);return e.contains(o)?o:null}).filter(r=>r!=null);function uc(e,t,r,o){const i="data-floating-ui-inert",c=o?"inert":r?"aria-hidden":null,l=ac(t,e),s=new Set,d=new Set(l),a=[];St[i]||(St[i]=new WeakMap);const u=St[i];l.forEach(h),f(t),s.clear();function h(b){!b||s.has(b)||(s.add(b),b.parentNode&&h(b.parentNode))}function f(b){!b||d.has(b)||[].forEach.call(b.children,C=>{if(ze(C)!=="script")if(s.has(C))f(C);else{const g=c?C.getAttribute(c):null,y=g!==null&&g!=="false",p=ao(c),v=(p.get(C)||0)+1,k=(u.get(C)||0)+1;p.set(C,v),u.set(C,k),a.push(C),v===1&&y&&kt.add(C),k===1&&C.setAttribute(i,""),!y&&c&&C.setAttribute(c,c==="inert"?"":"true")}})}return or++,()=>{a.forEach(b=>{const C=ao(c),y=(C.get(b)||0)-1,p=(u.get(b)||0)-1;C.set(b,y),u.set(b,p),y||(!kt.has(b)&&c&&b.removeAttribute(c),kt.delete(b)),p||b.removeAttribute(i)}),or--,or||(rt.inert=new WeakMap,rt["aria-hidden"]=new WeakMap,rt.none=new WeakMap,kt=new WeakSet,St={})}}function uo(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!1);const o=cc(e[0]).body;return uc(e.concat(Array.from(o.querySelectorAll('[aria-live],[role="status"],output'))),o,t,r)}const Ir={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"fixed",whiteSpace:"nowrap",width:"1px",top:0,left:0},fo=w.forwardRef(function(t,r){const[o,i]=w.useState();ae(()=>{rl()&&i("button")},[]);const c={ref:r,tabIndex:0,role:o,"aria-hidden":o?void 0:!0,[_t("focus-guard")]:"",style:Ir};return Ue.jsx("span",{...t,...c})}),dc=w.createContext(null),fc=()=>w.useContext(dc);function go(e){return w.useMemo(()=>t=>{e.forEach(r=>{r&&(r.current=t)})},e)}const gc=20;let _e=[];function Tr(){_e=_e.filter(e=>e.isConnected)}function hc(e){Tr(),e&&ze(e)!=="body"&&(_e.push(e),_e.length>gc&&(_e=_e.slice(-20)))}function ho(){return Tr(),_e[_e.length-1]}function pc(e){const t=Ht();return Zo(e,t)?e:vr(e,t)[0]||e}function po(e,t){var r;if(!t.current.includes("floating")&&!((r=e.getAttribute("role"))!=null&&r.includes("dialog")))return;const o=Ht(),c=el(e,o).filter(s=>{const d=s.getAttribute("data-tabindex")||"";return Zo(s,o)||s.hasAttribute("data-tabindex")&&!d.startsWith("-")}),l=e.getAttribute("tabindex");t.current.includes("floating")||c.length===0?l!=="0"&&e.setAttribute("tabindex","0"):(l!=="-1"||e.hasAttribute("data-tabindex")&&e.getAttribute("data-tabindex")!=="-1")&&(e.setAttribute("tabindex","-1"),e.setAttribute("data-tabindex","-1"))}const bc=w.forwardRef(function(t,r){return Ue.jsx("button",{...t,type:"button",ref:r,tabIndex:-1,style:Ir})});function bn(e){const{context:t,children:r,disabled:o=!1,order:i=["content"],guards:c=!0,initialFocus:l=0,returnFocus:s=!0,restoreFocus:d=!1,modal:a=!0,visuallyHiddenDismiss:u=!1,closeOnFocusOut:h=!0,outsideElementsInert:f=!1,getInsideElements:b=()=>[]}=e,{open:C,onOpenChange:g,events:y,dataRef:p,elements:{domReference:v,floating:k}}=t,S=ge(()=>{var W;return(W=p.current.floatingContext)==null?void 0:W.nodeId}),T=ge(b),M=typeof l=="number"&&l<0,N=br(v)&&M,B=sc(),X=B?c:!0,O=!X||B&&f,F=Te(i),G=Te(l),V=Te(s),R=Gt(),$=fc(),j=w.useRef(null),L=w.useRef(null),x=w.useRef(!1),E=w.useRef(!1),A=w.useRef(-1),ee=w.useRef(-1),ue=$!=null,z=Nt(k),Y=ge(function(W){return W===void 0&&(W=z),W?vr(W,Ht()):[]}),H=ge(W=>{const Q=Y(W);return F.current.map(U=>v&&U==="reference"?v:z&&U==="floating"?z:Q).filter(Boolean).flat()});w.useEffect(()=>{if(o||!a)return;function W(U){if(U.key==="Tab"){me(z,Ne(Se(z)))&&Y().length===0&&!N&&fe(U);const re=H(),le=Fe(U);F.current[0]==="reference"&&le===v&&(fe(U),U.shiftKey?He(re[re.length-1]):He(re[1])),F.current[1]==="floating"&&le===z&&U.shiftKey&&(fe(U),He(re[0]))}}const Q=Se(z);return Q.addEventListener("keydown",W),()=>{Q.removeEventListener("keydown",W)}},[o,v,z,a,F,N,Y,H]),w.useEffect(()=>{if(o||!k)return;function W(Q){const U=Fe(Q),le=Y().indexOf(U);le!==-1&&(A.current=le)}return k.addEventListener("focusin",W),()=>{k.removeEventListener("focusin",W)}},[o,k,Y]),w.useEffect(()=>{if(o||!h)return;function W(){E.current=!0,setTimeout(()=>{E.current=!1})}function Q(le){const Z=le.relatedTarget,xe=le.currentTarget,de=Fe(le);queueMicrotask(()=>{const he=S(),$e=!(me(v,Z)||me(k,Z)||me(Z,k)||me($==null?void 0:$.portalNode,Z)||Z!=null&&Z.hasAttribute(_t("focus-guard"))||R&&(Ke(R.nodesRef.current,he).find(D=>{var K,P;return me((K=D.context)==null?void 0:K.elements.floating,Z)||me((P=D.context)==null?void 0:P.elements.domReference,Z)})||Xr(R.nodesRef.current,he).find(D=>{var K,P,J;return[(K=D.context)==null?void 0:K.elements.floating,Nt((P=D.context)==null?void 0:P.elements.floating)].includes(Z)||((J=D.context)==null?void 0:J.elements.domReference)===Z})));if(xe===v&&z&&po(z,F),d&&xe!==v&&!(de!=null&&de.isConnected)&&Ne(Se(z))===Se(z).body){se(z)&&z.focus();const D=A.current,K=Y(),P=K[D]||K[K.length-1]||z;se(P)&&P.focus()}if(p.current.insideReactTree){p.current.insideReactTree=!1;return}(N||!a)&&Z&&$e&&!E.current&&Z!==ho()&&(x.current=!0,g(!1,le,"focus-out"))})}const U=!!(!R&&$);function re(){xr(ee),p.current.insideReactTree=!0,ee.current=window.setTimeout(()=>{p.current.insideReactTree=!1})}if(k&&se(v))return v.addEventListener("focusout",Q),v.addEventListener("pointerdown",W),k.addEventListener("focusout",Q),U&&k.addEventListener("focusout",re,!0),()=>{v.removeEventListener("focusout",Q),v.removeEventListener("pointerdown",W),k.removeEventListener("focusout",Q),U&&k.removeEventListener("focusout",re,!0)}},[o,v,k,z,a,R,$,g,h,d,Y,N,S,F,p]);const te=w.useRef(null),q=w.useRef(null),ne=go([te,$==null?void 0:$.beforeInsideRef]),Ee=go([q,$==null?void 0:$.afterInsideRef]);w.useEffect(()=>{var W,Q;if(o||!k)return;const U=Array.from(($==null||(W=$.portalNode)==null?void 0:W.querySelectorAll("["+_t("portal")+"]"))||[]),le=(Q=(R?Xr(R.nodesRef.current,S()):[]).find(de=>{var he;return br(((he=de.context)==null?void 0:he.elements.domReference)||null)}))==null||(Q=Q.context)==null?void 0:Q.elements.domReference,Z=[k,le,...U,...T(),j.current,L.current,te.current,q.current,$==null?void 0:$.beforeOutsideRef.current,$==null?void 0:$.afterOutsideRef.current,F.current.includes("reference")||N?v:null].filter(de=>de!=null),xe=a||N?uo(Z,!O,O):uo(Z);return()=>{xe()}},[o,v,k,a,F,$,N,X,O,R,S,T]),ae(()=>{if(o||!se(z))return;const W=Se(z),Q=Ne(W);queueMicrotask(()=>{const U=H(z),re=G.current,le=(typeof re=="number"?U[re]:re.current)||z,Z=me(z,Q);!M&&!Z&&C&&He(le,{preventScroll:le===z})})},[o,C,z,M,H,G]),ae(()=>{if(o||!z)return;const W=Se(z),Q=Ne(W);hc(Q);function U(Z){let{reason:xe,event:de,nested:he}=Z;if(["hover","safe-polygon"].includes(xe)&&de.type==="mouseleave"&&(x.current=!0),xe==="outside-press")if(he)x.current=!1;else if(tn(de)||rn(de))x.current=!1;else{let $e=!1;document.createElement("div").focus({get preventScroll(){return $e=!0,!1}}),$e?x.current=!1:x.current=!0}}y.on("openchange",U);const re=W.createElement("span");re.setAttribute("tabindex","-1"),re.setAttribute("aria-hidden","true"),Object.assign(re.style,Ir),ue&&v&&v.insertAdjacentElement("afterend",re);function le(){if(typeof V.current=="boolean"){const Z=v||ho();return Z&&Z.isConnected?Z:re}return V.current.current||re}return()=>{y.off("openchange",U);const Z=Ne(W),xe=me(k,Z)||R&&Ke(R.nodesRef.current,S(),!1).some(he=>{var $e;return me(($e=he.context)==null?void 0:$e.elements.floating,Z)}),de=le();queueMicrotask(()=>{const he=pc(de);V.current&&!x.current&&se(he)&&(!(he!==Z&&Z!==W.body)||xe)&&he.focus({preventScroll:!0}),re.remove()})}},[o,k,z,V,p,y,R,ue,v,S]),w.useEffect(()=>(queueMicrotask(()=>{x.current=!1}),()=>{queueMicrotask(Tr)}),[o]),ae(()=>{if(!o&&$)return $.setFocusManagerState({modal:a,closeOnFocusOut:h,open:C,onOpenChange:g,domReference:v}),()=>{$.setFocusManagerState(null)}},[o,$,a,C,g,h,v]),ae(()=>{o||z&&po(z,F)},[o,z,F]);function Ce(W){return o||!u||!a?null:Ue.jsx(bc,{ref:W==="start"?j:L,onClick:Q=>g(!1,Q.nativeEvent),children:typeof u=="string"?u:"Dismiss"})}const Ye=!o&&X&&(a?!N:!0)&&(ue||a);return Ue.jsxs(Ue.Fragment,{children:[Ye&&Ue.jsx(fo,{"data-type":"inside",ref:ne,onFocus:W=>{if(a){const U=H();He(i[0]==="reference"?U[0]:U[U.length-1])}else if($!=null&&$.preserveTabOrder&&$.portalNode)if(x.current=!1,Zr(W,$.portalNode)){const U=Cl(v);U==null||U.focus()}else{var Q;(Q=$.beforeOutsideRef.current)==null||Q.focus()}}}),!N&&Ce("start"),r,Ce("end"),Ye&&Ue.jsx(fo,{"data-type":"inside",ref:Ee,onFocus:W=>{if(a)He(H()[0]);else if($!=null&&$.preserveTabOrder&&$.portalNode)if(h&&(x.current=!0),Zr(W,$.portalNode)){const U=vl(v);U==null||U.focus()}else{var Q;(Q=$.afterOutsideRef.current)==null||Q.focus()}}})]})}function bo(e){return se(e.target)&&e.target.tagName==="BUTTON"}function xc(e){return se(e.target)&&e.target.tagName==="A"}function xo(e){return en(e)}function Or(e,t){t===void 0&&(t={});const{open:r,onOpenChange:o,dataRef:i,elements:{domReference:c}}=e,{enabled:l=!0,event:s="click",toggle:d=!0,ignoreMouse:a=!1,keyboardHandlers:u=!0,stickIfOpen:h=!0}=t,f=w.useRef(),b=w.useRef(!1),C=w.useMemo(()=>({onPointerDown(g){f.current=g.pointerType},onMouseDown(g){const y=f.current;g.button===0&&s!=="click"&&(Yr(y)&&a||(r&&d&&(!(i.current.openEvent&&h)||i.current.openEvent.type==="mousedown")?o(!1,g.nativeEvent,"click"):(g.preventDefault(),o(!0,g.nativeEvent,"click"))))},onClick(g){const y=f.current;if(s==="mousedown"&&f.current){f.current=void 0;return}Yr(y)&&a||(r&&d&&(!(i.current.openEvent&&h)||i.current.openEvent.type==="click")?o(!1,g.nativeEvent,"click"):o(!0,g.nativeEvent,"click"))},onKeyDown(g){f.current=void 0,!(g.defaultPrevented||!u||bo(g))&&(g.key===" "&&!xo(c)&&(g.preventDefault(),b.current=!0),!xc(g)&&g.key==="Enter"&&o(!(r&&d),g.nativeEvent,"click"))},onKeyUp(g){g.defaultPrevented||!u||bo(g)||xo(c)||g.key===" "&&b.current&&(b.current=!1,o(!(r&&d),g.nativeEvent,"click"))}}),[i,c,s,a,u,o,r,h,d]);return w.useMemo(()=>l?{reference:C}:{},[l,C])}const mc={pointerdown:"onPointerDown",mousedown:"onMouseDown",click:"onClick"},Cc={pointerdown:"onPointerDownCapture",mousedown:"onMouseDownCapture",click:"onClickCapture"},mo=e=>{var t,r;return{escapeKey:typeof e=="boolean"?e:(t=e==null?void 0:e.escapeKey)!=null?t:!1,outsidePress:typeof e=="boolean"?e:(r=e==null?void 0:e.outsidePress)!=null?r:!0}};function Mr(e,t){t===void 0&&(t={});const{open:r,onOpenChange:o,elements:i,dataRef:c}=e,{enabled:l=!0,escapeKey:s=!0,outsidePress:d=!0,outsidePressEvent:a="pointerdown",referencePress:u=!1,referencePressEvent:h="pointerdown",ancestorScroll:f=!1,bubbles:b,capture:C}=t,g=Gt(),y=ge(typeof d=="function"?d:()=>!1),p=typeof d=="function"?y:d,v=w.useRef(!1),{escapeKey:k,outsidePress:S}=mo(b),{escapeKey:T,outsidePress:M}=mo(C),N=w.useRef(!1),B=ge(R=>{var $;if(!r||!l||!s||R.key!=="Escape"||N.current)return;const j=($=c.current.floatingContext)==null?void 0:$.nodeId,L=g?Ke(g.nodesRef.current,j):[];if(!k&&(R.stopPropagation(),L.length>0)){let x=!0;if(L.forEach(E=>{var A;if((A=E.context)!=null&&A.open&&!E.context.dataRef.current.__escapeKeyBubbles){x=!1;return}}),!x)return}o(!1,al(R)?R.nativeEvent:R,"escape-key")}),X=ge(R=>{var $;const j=()=>{var L;B(R),(L=Fe(R))==null||L.removeEventListener("keydown",j)};($=Fe(R))==null||$.addEventListener("keydown",j)}),O=ge(R=>{var $;const j=c.current.insideReactTree;c.current.insideReactTree=!1;const L=v.current;if(v.current=!1,a==="click"&&L||j||typeof p=="function"&&!p(R))return;const x=Fe(R),E="["+_t("inert")+"]",A=Se(i.floating).querySelectorAll(E);let ee=ie(x)?x:null;for(;ee&&!Pe(ee);){const H=De(ee);if(Pe(H)||!ie(H))break;ee=H}if(A.length&&ie(x)&&!cl(x)&&!me(x,i.floating)&&Array.from(A).every(H=>!me(ee,H)))return;if(se(x)&&V){const H=Pe(x),te=Re(x),q=/auto|scroll/,ne=H||q.test(te.overflowX),Ee=H||q.test(te.overflowY),Ce=ne&&x.clientWidth>0&&x.scrollWidth>x.clientWidth,Ye=Ee&&x.clientHeight>0&&x.scrollHeight>x.clientHeight,W=te.direction==="rtl",Q=Ye&&(W?R.offsetX<=x.offsetWidth-x.clientWidth:R.offsetX>x.clientWidth),U=Ce&&R.offsetY>x.clientHeight;if(Q||U)return}const ue=($=c.current.floatingContext)==null?void 0:$.nodeId,z=g&&Ke(g.nodesRef.current,ue).some(H=>{var te;return Zt(R,(te=H.context)==null?void 0:te.elements.floating)});if(Zt(R,i.floating)||Zt(R,i.domReference)||z)return;const Y=g?Ke(g.nodesRef.current,ue):[];if(Y.length>0){let H=!0;if(Y.forEach(te=>{var q;if((q=te.context)!=null&&q.open&&!te.context.dataRef.current.__outsidePressBubbles){H=!1;return}}),!H)return}o(!1,R,"outside-press")}),F=ge(R=>{var $;const j=()=>{var L;O(R),(L=Fe(R))==null||L.removeEventListener(a,j)};($=Fe(R))==null||$.addEventListener(a,j)});w.useEffect(()=>{if(!r||!l)return;c.current.__escapeKeyBubbles=k,c.current.__outsidePressBubbles=S;let R=-1;function $(A){o(!1,A,"ancestor-scroll")}function j(){window.clearTimeout(R),N.current=!0}function L(){R=window.setTimeout(()=>{N.current=!1},Wt()?5:0)}const x=Se(i.floating);s&&(x.addEventListener("keydown",T?X:B,T),x.addEventListener("compositionstart",j),x.addEventListener("compositionend",L)),p&&x.addEventListener(a,M?F:O,M);let E=[];return f&&(ie(i.domReference)&&(E=je(i.domReference)),ie(i.floating)&&(E=E.concat(je(i.floating))),!ie(i.reference)&&i.reference&&i.reference.contextElement&&(E=E.concat(je(i.reference.contextElement)))),E=E.filter(A=>{var ee;return A!==((ee=x.defaultView)==null?void 0:ee.visualViewport)}),E.forEach(A=>{A.addEventListener("scroll",$,{passive:!0})}),()=>{s&&(x.removeEventListener("keydown",T?X:B,T),x.removeEventListener("compositionstart",j),x.removeEventListener("compositionend",L)),p&&x.removeEventListener(a,M?F:O,M),E.forEach(A=>{A.removeEventListener("scroll",$)}),window.clearTimeout(R)}},[c,i,s,p,a,r,o,f,l,k,S,B,T,X,O,M,F]),w.useEffect(()=>{c.current.insideReactTree=!1},[c,p,a]);const G=w.useMemo(()=>({onKeyDown:B,...u&&{[mc[h]]:R=>{o(!1,R.nativeEvent,"reference-press")},...h!=="click"&&{onClick(R){o(!1,R.nativeEvent,"reference-press")}}}}),[B,o,u,h]),V=w.useMemo(()=>({onKeyDown:B,onMouseDown(){v.current=!0},onMouseUp(){v.current=!0},[Cc[a]]:()=>{c.current.insideReactTree=!0}}),[B,a,c]);return w.useMemo(()=>l?{reference:G,floating:V}:{},[l,G,V])}function vc(e){const{open:t=!1,onOpenChange:r,elements:o}=e,i=hn(),c=w.useRef({}),[l]=w.useState(()=>nc()),s=$r()!=null;if(process.env.NODE_ENV!=="production"){const b=o.reference;b&&!ie(b)&&oc("Cannot pass a virtual element to the `elements.reference` option,","as it must be a real DOM element. Use `refs.setPositionReference()`","instead.")}const[d,a]=w.useState(o.reference),u=ge((b,C,g)=>{c.current.openEvent=b?C:void 0,l.emit("openchange",{open:b,event:C,reason:g,nested:s}),r==null||r(b,C,g)}),h=w.useMemo(()=>({setPositionReference:a}),[]),f=w.useMemo(()=>({reference:d||o.reference||null,floating:o.floating||null,domReference:o.reference}),[d,o.reference,o.floating]);return w.useMemo(()=>({dataRef:c,open:t,onOpenChange:u,elements:f,events:l,floatingId:i,refs:h}),[t,u,f,l,i,h])}function Ar(e){e===void 0&&(e={});const{nodeId:t}=e,r=vc({...e,elements:{reference:null,floating:null,...e.elements}}),o=e.rootContext||r,i=o.elements,[c,l]=w.useState(null),[s,d]=w.useState(null),u=(i==null?void 0:i.domReference)||c,h=w.useRef(null),f=Gt();ae(()=>{u&&(h.current=u)},[u]);const b=Ql({...e,elements:{...i,...s&&{reference:s}}}),C=w.useCallback(k=>{const S=ie(k)?{getBoundingClientRect:()=>k.getBoundingClientRect(),getClientRects:()=>k.getClientRects(),contextElement:k}:k;d(S),b.refs.setReference(S)},[b.refs]),g=w.useCallback(k=>{(ie(k)||k===null)&&(h.current=k,l(k)),(ie(b.refs.reference.current)||b.refs.reference.current===null||k!==null&&!ie(k))&&b.refs.setReference(k)},[b.refs]),y=w.useMemo(()=>({...b.refs,setReference:g,setPositionReference:C,domReference:h}),[b.refs,g,C]),p=w.useMemo(()=>({...b.elements,domReference:u}),[b.elements,u]),v=w.useMemo(()=>({...b,...o,refs:y,elements:p,nodeId:t}),[b,y,p,t,o]);return ae(()=>{o.dataRef.current.floatingContext=v;const k=f==null?void 0:f.nodesRef.current.find(S=>S.id===t);k&&(k.context=v)}),w.useMemo(()=>({...b,context:v,refs:y,elements:p}),[b,y,p,v])}function nr(e,t,r){const o=new Map,i=r==="item";let c=e;if(i&&e){const{[no]:l,[io]:s,...d}=e;c=d}return{...r==="floating"&&{tabIndex:-1,[Zl]:""},...c,...t.map(l=>{const s=l?l[r]:null;return typeof s=="function"?e?s(e):null:s}).concat(e).reduce((l,s)=>(s&&Object.entries(s).forEach(d=>{let[a,u]=d;if(!(i&&[no,io].includes(a)))if(a.indexOf("on")===0){if(o.has(a)||o.set(a,[]),typeof u=="function"){var h;(h=o.get(a))==null||h.push(u),l[a]=function(){for(var f,b=arguments.length,C=new Array(b),g=0;g<b;g++)C[g]=arguments[g];return(f=o.get(a))==null?void 0:f.map(y=>y(...C)).find(y=>y!==void 0)}}}else l[a]=u}),l),{})}}function Pr(e){e===void 0&&(e=[]);const t=e.map(s=>s==null?void 0:s.reference),r=e.map(s=>s==null?void 0:s.floating),o=e.map(s=>s==null?void 0:s.item),i=w.useCallback(s=>nr(s,e,"reference"),t),c=w.useCallback(s=>nr(s,e,"floating"),r),l=w.useCallback(s=>nr(s,e,"item"),o);return w.useMemo(()=>({getReferenceProps:i,getFloatingProps:c,getItemProps:l}),[i,c,l])}const wc="Escape";function qt(e,t,r){switch(e){case"vertical":return t;case"horizontal":return r;default:return t||r}}function Rt(e,t){return qt(t,e===gn||e===Kt,e===bt||e===xt)}function ir(e,t,r){return qt(t,e===Kt,r?e===bt:e===xt)||e==="Enter"||e===" "||e===""}function Co(e,t,r){return qt(t,r?e===bt:e===xt,e===Kt)}function vo(e,t,r,o){const i=r?e===xt:e===bt,c=e===gn;return t==="both"||t==="horizontal"&&o&&o>1?e===wc:qt(t,i,c)}function xn(e,t){const{open:r,onOpenChange:o,elements:i,floatingId:c}=e,{listRef:l,activeIndex:s,onNavigate:d=()=>{},enabled:a=!0,selectedIndex:u=null,allowEscape:h=!1,loop:f=!1,nested:b=!1,rtl:C=!1,virtual:g=!1,focusItemOnOpen:y="auto",focusItemOnHover:p=!0,openOnArrowKeyDown:v=!0,disabledIndices:k=void 0,orientation:S="vertical",parentOrientation:T,cols:M=1,scrollItemIntoView:N=!0,virtualItemRef:B,itemSizes:X,dense:O=!1}=t;process.env.NODE_ENV!=="production"&&(h&&(f||rr("`useListNavigation` looping must be enabled to allow escaping."),g||rr("`useListNavigation` must be virtual to allow escaping.")),S==="vertical"&&M>1&&rr("In grid list navigation mode (`cols` > 1), the `orientation` should",'be either "horizontal" or "both".'));const F=Nt(i.floating),G=Te(F),V=$r(),R=Gt();ae(()=>{e.dataRef.current.orientation=S},[e,S]);const $=ge(()=>{d(x.current===-1?null:x.current)}),j=br(i.domReference),L=w.useRef(y),x=w.useRef(u??-1),E=w.useRef(null),A=w.useRef(!0),ee=w.useRef($),ue=w.useRef(!!i.floating),z=w.useRef(r),Y=w.useRef(!1),H=w.useRef(!1),te=Te(k),q=Te(r),ne=Te(N),Ee=Te(u),[Ce,Ye]=w.useState(),[W,Q]=w.useState(),U=ge(()=>{function D(oe){if(g){var ce;(ce=oe.id)!=null&&ce.endsWith("-fui-option")&&(oe.id=c+"-"+Math.random().toString(16).slice(2,10)),Ye(oe.id),R==null||R.events.emit("virtualfocus",oe),B&&(B.current=oe)}else He(oe,{sync:Y.current,preventScroll:!0})}const K=l.current[x.current],P=H.current;K&&D(K),(Y.current?oe=>oe():requestAnimationFrame)(()=>{const oe=l.current[x.current]||K;if(!oe)return;K||D(oe);const ce=ne.current;ce&&le&&(P||!A.current)&&(oe.scrollIntoView==null||oe.scrollIntoView(typeof ce=="boolean"?{block:"nearest",inline:"nearest"}:ce))})});ae(()=>{a&&(r&&i.floating?L.current&&u!=null&&(H.current=!0,x.current=u,$()):ue.current&&(x.current=-1,ee.current()))},[a,r,i.floating,u,$]),ae(()=>{if(a&&r&&i.floating)if(s==null){if(Y.current=!1,Ee.current!=null)return;if(ue.current&&(x.current=-1,U()),(!z.current||!ue.current)&&L.current&&(E.current!=null||L.current===!0&&E.current==null)){let D=0;const K=()=>{l.current[0]==null?(D<2&&(D?requestAnimationFrame:queueMicrotask)(K),D++):(x.current=E.current==null||ir(E.current,S,C)||b?Jt(l,te.current):Qr(l,te.current),E.current=null,$())};K()}}else at(l,s)||(x.current=s,U(),H.current=!1)},[a,r,i.floating,s,Ee,b,l,S,C,$,U,te]),ae(()=>{var D;if(!a||i.floating||!R||g||!ue.current)return;const K=R.nodesRef.current,P=(D=K.find(ce=>ce.id===V))==null||(D=D.context)==null?void 0:D.elements.floating,J=Ne(Se(i.floating)),oe=K.some(ce=>ce.context&&me(ce.context.elements.floating,J));P&&!oe&&A.current&&P.focus({preventScroll:!0})},[a,i.floating,R,V,g]),ae(()=>{if(!a||!R||!g||V)return;function D(K){Q(K.id),B&&(B.current=K)}return R.events.on("virtualfocus",D),()=>{R.events.off("virtualfocus",D)}},[a,R,g,V,B]),ae(()=>{ee.current=$,z.current=r,ue.current=!!i.floating}),ae(()=>{r||(E.current=null,L.current=y)},[r,y]);const re=s!=null,le=w.useMemo(()=>{function D(P){if(!q.current)return;const J=l.current.indexOf(P);J!==-1&&x.current!==J&&(x.current=J,$())}return{onFocus(P){let{currentTarget:J}=P;Y.current=!0,D(J)},onClick:P=>{let{currentTarget:J}=P;return J.focus({preventScroll:!0})},onMouseMove(P){let{currentTarget:J}=P;Y.current=!0,H.current=!1,p&&D(J)},onPointerLeave(P){let{pointerType:J}=P;if(!(!A.current||J==="touch")&&(Y.current=!0,!!p&&(x.current=-1,$(),!g))){var oe;(oe=G.current)==null||oe.focus({preventScroll:!0})}}}},[q,G,p,l,$,g]),Z=w.useCallback(()=>{var D;return T??(R==null||(D=R.nodesRef.current.find(K=>K.id===V))==null||(D=D.context)==null||(D=D.dataRef)==null?void 0:D.current.orientation)},[V,R,T]),xe=ge(D=>{if(A.current=!1,Y.current=!0,D.which===229||!q.current&&D.currentTarget===G.current)return;if(b&&vo(D.key,S,C,M)){Rt(D.key,Z())||fe(D),o(!1,D.nativeEvent,"list-navigation"),se(i.domReference)&&(g?R==null||R.events.emit("virtualfocus",i.domReference):i.domReference.focus());return}const K=x.current,P=Jt(l,k),J=Qr(l,k);if(j||(D.key==="Home"&&(fe(D),x.current=P,$()),D.key==="End"&&(fe(D),x.current=J,$())),M>1){const oe=X||Array.from({length:l.current.length},()=>({width:1,height:1})),ce=bl(oe,M,O),it=ce.findIndex(ke=>ke!=null&&!It(l,ke,k)),mt=ce.reduce((ke,We,Ct)=>We!=null&&!It(l,We,k)?Ct:ke,-1),lt=ce[pl({current:ce.map(ke=>ke!=null?l.current[ke]:null)},{event:D,orientation:S,loop:f,rtl:C,cols:M,disabledIndices:ml([...(typeof k!="function"?k:null)||l.current.map((ke,We)=>It(l,We,k)?We:void 0),void 0],ce),minIndex:it,maxIndex:mt,prevIndex:xl(x.current>J?P:x.current,oe,ce,M,D.key===Kt?"bl":D.key===(C?bt:xt)?"tr":"tl"),stopEvent:!0})];if(lt!=null&&(x.current=lt,$()),S==="both")return}if(Rt(D.key,S)){if(fe(D),r&&!g&&Ne(D.currentTarget.ownerDocument)===D.currentTarget){x.current=ir(D.key,S,C)?P:J,$();return}ir(D.key,S,C)?f?x.current=K>=J?h&&K!==l.current.length?-1:P:be(l,{startingIndex:K,disabledIndices:k}):x.current=Math.min(J,be(l,{startingIndex:K,disabledIndices:k})):f?x.current=K<=P?h&&K!==-1?l.current.length:J:be(l,{startingIndex:K,decrement:!0,disabledIndices:k}):x.current=Math.max(P,be(l,{startingIndex:K,decrement:!0,disabledIndices:k})),at(l,x.current)&&(x.current=-1),$()}}),de=w.useMemo(()=>g&&r&&re&&{"aria-activedescendant":W||Ce},[g,r,re,W,Ce]),he=w.useMemo(()=>({"aria-orientation":S==="both"?void 0:S,...j?{}:de,onKeyDown:xe,onPointerMove(){A.current=!0}}),[de,xe,S,j]),$e=w.useMemo(()=>{function D(P){y==="auto"&&tn(P.nativeEvent)&&(L.current=!0)}function K(P){L.current=y,y==="auto"&&rn(P.nativeEvent)&&(L.current=!0)}return{...de,onKeyDown(P){A.current=!1;const J=P.key.startsWith("Arrow"),oe=["Home","End"].includes(P.key),ce=J||oe,it=Co(P.key,S,C),mt=vo(P.key,S,C,M),lt=Co(P.key,Z(),C),ke=Rt(P.key,S),We=(b?lt:ke)||P.key==="Enter"||P.key.trim()==="";if(g&&r){const vt=R==null?void 0:R.nodesRef.current.find(wt=>wt.parentId==null),Le=R&&vt?sl(R.nodesRef.current,vt.id):null;if(ce&&Le&&B){const wt=new KeyboardEvent("keydown",{key:P.key,bubbles:!0});if(it||mt){var Ct,Lr;const En=((Ct=Le.context)==null?void 0:Ct.elements.domReference)===P.currentTarget,Fr=mt&&!En?(Lr=Le.context)==null?void 0:Lr.elements.domReference:it?l.current.find(_r=>(_r==null?void 0:_r.id)===Ce):null;Fr&&(fe(P),Fr.dispatchEvent(wt),Q(void 0))}if((ke||oe)&&Le.context&&Le.context.open&&Le.parentId&&P.currentTarget!==Le.context.elements.domReference){var Nr;fe(P),(Nr=Le.context.elements.domReference)==null||Nr.dispatchEvent(wt);return}}return xe(P)}if(!(!r&&!v&&J)){if(We){const vt=Rt(P.key,Z());E.current=b&&vt?null:P.key}if(b){lt&&(fe(P),r?(x.current=Jt(l,te.current),$()):o(!0,P.nativeEvent,"list-navigation"));return}ke&&(u!=null&&(x.current=u),fe(P),!r&&v?o(!0,P.nativeEvent,"list-navigation"):xe(P),r&&$())}},onFocus(){r&&!g&&(x.current=-1,$())},onPointerDown:K,onPointerEnter:K,onMouseDown:D,onClick:D}},[Ce,de,M,xe,te,y,l,b,$,o,r,v,S,Z,C,u,R,g,B]);return w.useMemo(()=>a?{reference:$e,floating:he,item:le}:{},[a,$e,he,le])}const yc=new Map([["select","listbox"],["combobox","listbox"],["label",!1]]);function mn(e,t){var r,o;t===void 0&&(t={});const{open:i,elements:c,floatingId:l}=e,{enabled:s=!0,role:d="dialog"}=t,a=hn(),u=((r=c.domReference)==null?void 0:r.id)||a,h=w.useMemo(()=>{var v;return((v=Nt(c.floating))==null?void 0:v.id)||l},[c.floating,l]),f=(o=yc.get(d))!=null?o:d,C=$r()!=null,g=w.useMemo(()=>f==="tooltip"||d==="label"?{["aria-"+(d==="label"?"labelledby":"describedby")]:i?h:void 0}:{"aria-expanded":i?"true":"false","aria-haspopup":f==="alertdialog"?"dialog":f,"aria-controls":i?h:void 0,...f==="listbox"&&{role:"combobox"},...f==="menu"&&{id:u},...f==="menu"&&C&&{role:"menuitem"},...d==="select"&&{"aria-autocomplete":"none"},...d==="combobox"&&{"aria-autocomplete":"list"}},[f,h,C,i,u,d]),y=w.useMemo(()=>{const v={id:h,...f&&{role:f}};return f==="tooltip"||d==="label"?v:{...v,...f==="menu"&&{"aria-labelledby":u}}},[f,h,u,d]),p=w.useCallback(v=>{let{active:k,selected:S}=v;const T={role:"option",...k&&{id:h+"-fui-option"}};switch(d){case"select":case"combobox":return{...T,"aria-selected":S}}return{}},[h,d]);return w.useMemo(()=>s?{reference:g,floating:y,item:p}:{},[s,g,y,p])}function kc(e,t){var r;const{open:o,dataRef:i}=e,{listRef:c,activeIndex:l,onMatch:s,onTypingChange:d,enabled:a=!0,findMatch:u=null,resetMs:h=750,ignoreKeys:f=[],selectedIndex:b=null}=t,C=w.useRef(-1),g=w.useRef(""),y=w.useRef((r=b??l)!=null?r:-1),p=w.useRef(null),v=ge(s),k=ge(d),S=Te(u),T=Te(f);ae(()=>{o&&(xr(C),p.current=null,g.current="")},[o]),ae(()=>{if(o&&g.current===""){var O;y.current=(O=b??l)!=null?O:-1}},[o,b,l]);const M=ge(O=>{O?i.current.typing||(i.current.typing=O,k(O)):i.current.typing&&(i.current.typing=O,k(O))}),N=ge(O=>{function F(j,L,x){const E=S.current?S.current(L,x):L.find(A=>(A==null?void 0:A.toLocaleLowerCase().indexOf(x.toLocaleLowerCase()))===0);return E?j.indexOf(E):-1}const G=c.current;if(g.current.length>0&&g.current[0]!==" "&&(F(G,G,g.current)===-1?M(!1):O.key===" "&&fe(O)),G==null||T.current.includes(O.key)||O.key.length!==1||O.ctrlKey||O.metaKey||O.altKey)return;o&&O.key!==" "&&(fe(O),M(!0)),G.every(j=>{var L,x;return j?((L=j[0])==null?void 0:L.toLocaleLowerCase())!==((x=j[1])==null?void 0:x.toLocaleLowerCase()):!0})&&g.current===O.key&&(g.current="",y.current=p.current),g.current+=O.key,xr(C),C.current=window.setTimeout(()=>{g.current="",y.current=p.current,M(!1)},h);const R=y.current,$=F(G,[...G.slice((R||0)+1),...G.slice(0,(R||0)+1)],g.current);$!==-1?(v($),p.current=$):O.key!==" "&&(g.current="",M(!1))}),B=w.useMemo(()=>({onKeyDown:N}),[N]),X=w.useMemo(()=>({onKeyDown:N,onKeyUp(O){O.key===" "&&M(!1)}}),[N,M]);return w.useMemo(()=>a?{reference:B,floating:X}:{},[a,B,X])}const Sc=(e,t)=>`${e}-${t}`,Rc=(e=_o,t=jo,r=Bo,o,i)=>{const[c,l]=_.useState(!1),s=o!==void 0,d=s?o:c,a=_.useCallback(v=>{s||l(v),i==null||i(v)},[s,i]),u=_.useMemo(()=>Sc(e,t),[e,t]),{refs:h,floatingStyles:f,context:b}=Ar({open:d,onOpenChange:a,placement:u,middleware:[Sr(r),Er(),Rr({padding:8})],whileElementsMounted:kr}),C=Or(b),g=Mr(b,{escapeKey:!0,outsidePress:!0}),{getReferenceProps:y,getFloatingProps:p}=Pr([C,g]);return{isOpen:d,setIsOpen:a,refs:{setReference:h.setReference,setFloating:h.setFloating},floatingStyles:f,getReferenceProps:y,getFloatingProps:p}},lr=m.classNameGetter("dropdown"),Ec=({trigger:e,children:t,placement:r=_o,align:o=jo,offset:i=Bo,open:c,onOpenChange:l,portalRenderNode:s,classnames:d,className:a,fullWidth:u,...h})=>{const{isOpen:f,refs:b,floatingStyles:C,getReferenceProps:g,getFloatingProps:y}=Rc(r,o,i,c,l),p=()=>{const v=m.jsx(Ci,{ref:b.setFloating,className:lr("content",d==null?void 0:d.content),style:C,$isOpen:f,...y(),children:t});return s?ft.createPortal(v,s):v};return m.jsxs(xi,{...h,className:lr("container",a,d==null?void 0:d.container),$fullWidth:u,children:[m.jsx(mi,{ref:b.setReference,className:lr("trigger",d==null?void 0:d.trigger),$fullWidth:u,...g(),children:e}),p()]})},wo={hidden:["M13.359 11.238C15.06 9.72 16 8 16 8s-3-5.5-8-5.5a7 7 0 0 0-2.79.588l.77.771A6 6 0 0 1 8 3.5c2.12 0 3.879 1.168 5.168 2.457A13 13 0 0 1 14.828 8q-.086.13-.195.288c-.335.48-.83 1.12-1.465 1.755q-.247.248-.517.486z","M11.297 9.176a3.5 3.5 0 0 0-4.474-4.474l.823.823a2.5 2.5 0 0 1 2.829 2.829zm-2.943 1.299.822.822a3.5 3.5 0 0 1-4.474-4.474l.823.823a2.5 2.5 0 0 0 2.829 2.829","M3.35 5.47q-.27.24-.518.487A13 13 0 0 0 1.172 8l.195.288c.335.48.83 1.12 1.465 1.755C4.121 11.332 5.881 12.5 8 12.5c.716 0 1.39-.133 2.02-.36l.77.772A7 7 0 0 1 8 13.5C3 13.5 0 8 0 8s.939-1.721 2.641-3.238l.708.709zm10.296 8.884-12-12 .708-.708 12 12z"],visible:["M16 8s-3-5.5-8-5.5S0 8 0 8s3 5.5 8 5.5S16 8 16 8M1.173 8a13 13 0 0 1 1.66-2.043C4.12 4.668 5.88 3.5 8 3.5s3.879 1.168 5.168 2.457A13 13 0 0 1 14.828 8q-.086.13-.195.288c-.335.48-.83 1.12-1.465 1.755C11.879 11.332 10.119 12.5 8 12.5s-3.879-1.168-5.168-2.457A13 13 0 0 1 1.172 8z","M8 5.5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5M4.5 8a3.5 3.5 0 1 1 7 0 3.5 3.5 0 0 1-7 0"]},$c=(e,t,r)=>r?e.input.wrapper.disabled.backgroundColor:t==="warning"?e.input.state.warning.wrapper.backgroundColor:t==="error"?e.input.state.error.wrapper.backgroundColor:e.input.wrapper.backgroundColor,Ic=(e,t,r)=>r?e.input.wrapper.disabled.borderColor:t==="warning"?e.input.state.warning.wrapper.borderColor:t==="error"?e.input.state.error.wrapper.borderColor:e.input.wrapper.borderColor,Tc=(e,t)=>t==="warning"?e.input.state.warning.wrapper.focus.outlineColor:t==="error"?e.input.state.error.wrapper.focus.outlineColor:e.input.wrapper.focus.outlineColor,Oc=(e,t)=>t==="warning"?e.input.state.warning.label.color:t==="error"?e.input.state.error.label.color:e.input.label.color,Mc=(e,t)=>t==="warning"?e.input.state.warning.input.color:t==="error"?e.input.state.error.input.color:e.input.input.color,Ac=(e,t)=>t==="warning"?e.input.state.warning.input.placeholderColor:t==="error"?e.input.state.error.input.placeholderColor:e.input.input.placeholderColor,Pc=(e,t,r)=>r?e.input.icon.disabled.color:t==="warning"?e.input.state.warning.icon.color:t==="error"?e.input.state.error.icon.color:e.input.icon.color,Dc=(e,t)=>t==="warning"?e.input.state.warning.icon.color:t==="error"?e.input.state.error.icon.color:e.input.toggle.color,Lc=I.div`
235
235
  display: flex;
236
236
  flex-direction: column;
237
237
  gap: 2px;
238
238
  width: ${({$fullWidth:e})=>e?"100%":"auto"};
239
239
  min-width: 0;
240
240
  max-width: ${({$fullWidth:e})=>e?"none":"320px"};
241
- `,Os=O.label`
241
+ `,Nc=I.label`
242
242
  font-size: 11px;
243
243
  font-weight: 500;
244
244
  line-height: 1.5;
245
- color: ${({theme:e,$state:t})=>ys(e,t)};
245
+ color: ${({theme:e,$state:t})=>Oc(e,t)};
246
246
  margin-left: 2px;
247
- `,Ts=O.div`
247
+ `,Fc=I.div`
248
248
  display: grid;
249
249
  grid-template-columns: auto 1fr auto;
250
250
  align-items: center;
251
251
  height: 32px;
252
252
  padding: 0 12px;
253
- background-color: ${({theme:e,$state:t,$disabled:r})=>Cs(e,t,r)};
253
+ background-color: ${({theme:e,$state:t,$disabled:r})=>$c(e,t,r)};
254
254
  border-radius: 10px;
255
255
  border: 1px solid
256
- ${({theme:e,$state:t,$disabled:r})=>vs(e,t,r)};
256
+ ${({theme:e,$state:t,$disabled:r})=>Ic(e,t,r)};
257
257
  transition: border-color 0.15s ease;
258
258
 
259
259
  &:has(:focus-visible) {
260
- outline: 2px solid ${({theme:e,$state:t})=>ws(e,t)};
260
+ outline: 2px solid ${({theme:e,$state:t})=>Tc(e,t)};
261
261
  outline-offset: 1px;
262
262
  }
263
263
 
264
264
  ${({$disabled:e})=>e&&`
265
265
  cursor: not-allowed;
266
266
  `}
267
- `,$s=O.input`
267
+ `,_c=I.input`
268
268
  grid-column: 2;
269
269
  width: 100%;
270
270
  height: 100%;
271
271
  font-size: 14px;
272
272
  font-weight: 400;
273
273
  line-height: 1.5;
274
- color: ${({theme:e,$state:t})=>ks(e,t)};
274
+ color: ${({theme:e,$state:t})=>Mc(e,t)};
275
275
  background-color: transparent;
276
276
  border: none;
277
277
  outline: none;
278
278
 
279
279
  &::placeholder {
280
- color: ${({theme:e,$state:t})=>Rs(e,t)};
280
+ color: ${({theme:e,$state:t})=>Ac(e,t)};
281
281
  }
282
282
 
283
283
  &:disabled {
@@ -294,13 +294,13 @@
294
294
  &[type='number'] {
295
295
  appearance: textfield;
296
296
  }
297
- `,As=O.span`
297
+ `,jc=I.span`
298
298
  display: flex;
299
299
  align-items: center;
300
300
  justify-content: center;
301
301
  margin-right: 8px;
302
- color: ${({theme:e,$state:t,$disabled:r})=>Ss(e,t,r)};
303
- `,Ms=O.button`
302
+ color: ${({theme:e,$state:t,$disabled:r})=>Pc(e,t,r)};
303
+ `,Bc=I.button`
304
304
  display: grid;
305
305
  place-items: center;
306
306
  margin-left: 8px;
@@ -308,36 +308,211 @@
308
308
  background: none;
309
309
  border: none;
310
310
  cursor: pointer;
311
- color: ${({theme:e,$state:t})=>Es(e,t)};
311
+ color: ${({theme:e,$state:t})=>Dc(e,t)};
312
312
 
313
313
  ${({$disabled:e})=>e&&`
314
314
  opacity: 0.5;
315
315
  pointer-events: none;
316
316
  `}
317
- `,Ps=O.svg`
317
+ `,zc=I.svg`
318
+ width: 16px;
319
+ height: 16px;
320
+ `,Wc=({onBlur:e,onFocus:t,type:r,value:o})=>{const[i,c]=_.useState(!1),l=r==="password";return{inputType:_.useMemo(()=>l&&i?"text":r,[l,i,r]),isPassword:l,isPasswordVisible:i,handleBlur:f=>{e==null||e(f)},handleFocus:f=>{t==null||t(f)},handlePasswordMouseDown:f=>{f.preventDefault(),o&&c(!0)},handlePasswordMouseUp:()=>{c(!1)}}},Qe=m.classNameGetter("input"),Vc=({className:e,classnames:t,fullWidth:r,icon:o,label:i,onChange:c,onBlur:l,onFocus:s,ref:d,state:a,type:u,value:h,...f})=>{const{inputType:b,isPassword:C,isPasswordVisible:g,handleBlur:y,handleFocus:p,handlePasswordMouseDown:v,handlePasswordMouseUp:k}=Wc({onBlur:l,onFocus:s,type:u,value:h}),S=g?wo.visible:wo.hidden,T=()=>o||null;return m.jsxs(Lc,{className:Qe("container",e,t==null?void 0:t.container),$fullWidth:r,children:[i&&m.jsx(Nc,{className:Qe("label",t==null?void 0:t.label),$state:a,children:i}),m.jsxs(Fc,{className:Qe("wrapper",t==null?void 0:t.wrapper),$state:a,$disabled:f.disabled,children:[o&&m.jsx(jc,{className:Qe("icon",t==null?void 0:t.icon),$disabled:f.disabled,$state:a,children:T()}),m.jsx(_c,{...f,ref:d,className:Qe("input",t==null?void 0:t.input),$state:a,type:b,value:h,onChange:c,onFocus:p,onBlur:y}),C&&m.jsx(Bc,{type:"button",className:Qe("toggle",t==null?void 0:t.toggle),$state:a,$disabled:f.disabled,onMouseDown:v,onMouseUp:k,onMouseLeave:k,tabIndex:-1,children:m.jsx(zc,{viewBox:"0 0 16 16",fill:"currentColor",children:S.map(M=>m.jsx("path",{d:M},M))})})]})]})};function Ze(e,t,r){let o=r.initialDeps??[],i,c=!0;function l(){var s,d,a;let u;r.key&&((s=r.debug)!=null&&s.call(r))&&(u=Date.now());const h=e();if(!(h.length!==o.length||h.some((C,g)=>o[g]!==C)))return i;o=h;let b;if(r.key&&((d=r.debug)!=null&&d.call(r))&&(b=Date.now()),i=t(...h),r.key&&((a=r.debug)!=null&&a.call(r))){const C=Math.round((Date.now()-u)*100)/100,g=Math.round((Date.now()-b)*100)/100,y=g/16,p=(v,k)=>{for(v=String(v);v.length<k;)v=" "+v;return v};console.info(`%c⏱ ${p(g,5)} /${p(C,5)} ms`,`
321
+ font-size: .6rem;
322
+ font-weight: bold;
323
+ color: hsl(${Math.max(0,Math.min(120-120*y,120))}deg 100% 31%);`,r==null?void 0:r.key)}return r!=null&&r.onChange&&!(c&&r.skipInitialOnChange)&&r.onChange(i),c=!1,i}return l.updateDeps=s=>{o=s},l}function yo(e,t){if(e===void 0)throw new Error("Unexpected undefined");return e}const Hc=(e,t)=>Math.abs(e-t)<1.01,Uc=(e,t,r)=>{let o;return function(...i){e.clearTimeout(o),o=e.setTimeout(()=>t.apply(this,i),r)}},ko=e=>{const{offsetWidth:t,offsetHeight:r}=e;return{width:t,height:r}},Kc=e=>e,Gc=e=>{const t=Math.max(e.startIndex-e.overscan,0),r=Math.min(e.endIndex+e.overscan,e.count-1),o=[];for(let i=t;i<=r;i++)o.push(i);return o},qc=(e,t)=>{const r=e.scrollElement;if(!r)return;const o=e.targetWindow;if(!o)return;const i=l=>{const{width:s,height:d}=l;t({width:Math.round(s),height:Math.round(d)})};if(i(ko(r)),!o.ResizeObserver)return()=>{};const c=new o.ResizeObserver(l=>{const s=()=>{const d=l[0];if(d!=null&&d.borderBoxSize){const a=d.borderBoxSize[0];if(a){i({width:a.inlineSize,height:a.blockSize});return}}i(ko(r))};e.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(s):s()});return c.observe(r,{box:"border-box"}),()=>{c.unobserve(r)}},So={passive:!0},Ro=typeof window>"u"?!0:"onscrollend"in window,Xc=(e,t)=>{const r=e.scrollElement;if(!r)return;const o=e.targetWindow;if(!o)return;let i=0;const c=e.options.useScrollendEvent&&Ro?()=>{}:Uc(o,()=>{t(i,!1)},e.options.isScrollingResetDelay),l=u=>()=>{const{horizontal:h,isRtl:f}=e.options;i=h?r.scrollLeft*(f&&-1||1):r.scrollTop,c(),t(i,u)},s=l(!0),d=l(!1);d(),r.addEventListener("scroll",s,So);const a=e.options.useScrollendEvent&&Ro;return a&&r.addEventListener("scrollend",d,So),()=>{r.removeEventListener("scroll",s),a&&r.removeEventListener("scrollend",d)}},Yc=(e,t,r)=>{if(t!=null&&t.borderBoxSize){const o=t.borderBoxSize[0];if(o)return Math.round(o[r.options.horizontal?"inlineSize":"blockSize"])}return e[r.options.horizontal?"offsetWidth":"offsetHeight"]},Qc=(e,{adjustments:t=0,behavior:r},o)=>{var i,c;const l=e+t;(c=(i=o.scrollElement)==null?void 0:i.scrollTo)==null||c.call(i,{[o.options.horizontal?"left":"top"]:l,behavior:r})};class Zc{constructor(t){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.measurementsCache=[],this.itemSizeCache=new Map,this.laneAssignments=new Map,this.pendingMeasuredCacheIndexes=[],this.prevLanes=void 0,this.lanesChangedFlag=!1,this.lanesSettling=!1,this.scrollRect=null,this.scrollOffset=null,this.scrollDirection=null,this.scrollAdjustments=0,this.elementsCache=new Map,this.observer=(()=>{let r=null;const o=()=>r||(!this.targetWindow||!this.targetWindow.ResizeObserver?null:r=new this.targetWindow.ResizeObserver(i=>{i.forEach(c=>{const l=()=>{this._measureElement(c.target,c)};this.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(l):l()})}));return{disconnect:()=>{var i;(i=o())==null||i.disconnect(),r=null},observe:i=>{var c;return(c=o())==null?void 0:c.observe(i,{box:"border-box"})},unobserve:i=>{var c;return(c=o())==null?void 0:c.unobserve(i)}}})(),this.range=null,this.setOptions=r=>{Object.entries(r).forEach(([o,i])=>{typeof i>"u"&&delete r[o]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:Kc,rangeExtractor:Gc,onChange:()=>{},measureElement:Yc,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:"data-index",initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,enabled:!0,isRtl:!1,useScrollendEvent:!1,useAnimationFrameWithResizeObserver:!1,...r}},this.notify=r=>{var o,i;(i=(o=this.options).onChange)==null||i.call(o,this,r)},this.maybeNotify=Ze(()=>(this.calculateRange(),[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]),r=>{this.notify(r)},{key:process.env.NODE_ENV!=="production"&&"maybeNotify",debug:()=>this.options.debug,initialDeps:[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]}),this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(r=>r()),this.unsubs=[],this.observer.disconnect(),this.scrollElement=null,this.targetWindow=null},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{var r;const o=this.options.enabled?this.options.getScrollElement():null;if(this.scrollElement!==o){if(this.cleanup(),!o){this.maybeNotify();return}this.scrollElement=o,this.scrollElement&&"ownerDocument"in this.scrollElement?this.targetWindow=this.scrollElement.ownerDocument.defaultView:this.targetWindow=((r=this.scrollElement)==null?void 0:r.window)??null,this.elementsCache.forEach(i=>{this.observer.observe(i)}),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0}),this.unsubs.push(this.options.observeElementRect(this,i=>{this.scrollRect=i,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(i,c)=>{this.scrollAdjustments=0,this.scrollDirection=c?this.getScrollOffset()<i?"forward":"backward":null,this.scrollOffset=i,this.isScrolling=c,this.maybeNotify()}))}},this.getSize=()=>this.options.enabled?(this.scrollRect=this.scrollRect??this.options.initialRect,this.scrollRect[this.options.horizontal?"width":"height"]):(this.scrollRect=null,0),this.getScrollOffset=()=>this.options.enabled?(this.scrollOffset=this.scrollOffset??(typeof this.options.initialOffset=="function"?this.options.initialOffset():this.options.initialOffset),this.scrollOffset):(this.scrollOffset=null,0),this.getFurthestMeasurement=(r,o)=>{const i=new Map,c=new Map;for(let l=o-1;l>=0;l--){const s=r[l];if(i.has(s.lane))continue;const d=c.get(s.lane);if(d==null||s.end>d.end?c.set(s.lane,s):s.end<d.end&&i.set(s.lane,!0),i.size===this.options.lanes)break}return c.size===this.options.lanes?Array.from(c.values()).sort((l,s)=>l.end===s.end?l.index-s.index:l.end-s.end)[0]:void 0},this.getMeasurementOptions=Ze(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled,this.options.lanes],(r,o,i,c,l,s)=>(this.prevLanes!==void 0&&this.prevLanes!==s&&(this.lanesChangedFlag=!0),this.prevLanes=s,this.pendingMeasuredCacheIndexes=[],{count:r,paddingStart:o,scrollMargin:i,getItemKey:c,enabled:l,lanes:s}),{key:!1,skipInitialOnChange:!0,onChange:()=>{this.notify(this.isScrolling)}}),this.getMeasurements=Ze(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:r,paddingStart:o,scrollMargin:i,getItemKey:c,enabled:l,lanes:s},d)=>{if(!l)return this.measurementsCache=[],this.itemSizeCache.clear(),this.laneAssignments.clear(),[];if(this.laneAssignments.size>r)for(const f of this.laneAssignments.keys())f>=r&&this.laneAssignments.delete(f);this.lanesChangedFlag&&(this.lanesChangedFlag=!1,this.lanesSettling=!0,this.measurementsCache=[],this.itemSizeCache.clear(),this.laneAssignments.clear(),this.pendingMeasuredCacheIndexes=[]),this.measurementsCache.length===0&&(this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach(f=>{this.itemSizeCache.set(f.key,f.size)}));const a=this.lanesSettling?0:this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[],this.lanesSettling&&this.measurementsCache.length===r&&(this.lanesSettling=!1);const u=this.measurementsCache.slice(0,a),h=new Array(s).fill(void 0);for(let f=0;f<a;f++){const b=u[f];b&&(h[b.lane]=f)}for(let f=a;f<r;f++){const b=c(f),C=this.laneAssignments.get(f);let g,y;if(C!==void 0&&this.options.lanes>1){g=C;const S=h[g],T=S!==void 0?u[S]:void 0;y=T?T.end+this.options.gap:o+i}else{const S=this.options.lanes===1?u[f-1]:this.getFurthestMeasurement(u,f);y=S?S.end+this.options.gap:o+i,g=S?S.lane:f%this.options.lanes,this.options.lanes>1&&this.laneAssignments.set(f,g)}const p=d.get(b),v=typeof p=="number"?p:this.options.estimateSize(f),k=y+v;u[f]={index:f,start:y,size:v,end:k,key:b,lane:g},h[g]=f}return this.measurementsCache=u,u},{key:process.env.NODE_ENV!=="production"&&"getMeasurements",debug:()=>this.options.debug}),this.calculateRange=Ze(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset(),this.options.lanes],(r,o,i,c)=>this.range=r.length>0&&o>0?Jc({measurements:r,outerSize:o,scrollOffset:i,lanes:c}):null,{key:process.env.NODE_ENV!=="production"&&"calculateRange",debug:()=>this.options.debug}),this.getVirtualIndexes=Ze(()=>{let r=null,o=null;const i=this.calculateRange();return i&&(r=i.startIndex,o=i.endIndex),this.maybeNotify.updateDeps([this.isScrolling,r,o]),[this.options.rangeExtractor,this.options.overscan,this.options.count,r,o]},(r,o,i,c,l)=>c===null||l===null?[]:r({startIndex:c,endIndex:l,overscan:o,count:i}),{key:process.env.NODE_ENV!=="production"&&"getVirtualIndexes",debug:()=>this.options.debug}),this.indexFromElement=r=>{const o=this.options.indexAttribute,i=r.getAttribute(o);return i?parseInt(i,10):(console.warn(`Missing attribute name '${o}={index}' on measured element.`),-1)},this._measureElement=(r,o)=>{const i=this.indexFromElement(r),c=this.measurementsCache[i];if(!c)return;const l=c.key,s=this.elementsCache.get(l);s!==r&&(s&&this.observer.unobserve(s),this.observer.observe(r),this.elementsCache.set(l,r)),r.isConnected&&this.resizeItem(i,this.options.measureElement(r,o,this))},this.resizeItem=(r,o)=>{const i=this.measurementsCache[r];if(!i)return;const c=this.itemSizeCache.get(i.key)??i.size,l=o-c;l!==0&&((this.shouldAdjustScrollPositionOnItemSizeChange!==void 0?this.shouldAdjustScrollPositionOnItemSizeChange(i,l,this):i.start<this.getScrollOffset()+this.scrollAdjustments)&&(process.env.NODE_ENV!=="production"&&this.options.debug&&console.info("correction",l),this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=l,behavior:void 0})),this.pendingMeasuredCacheIndexes.push(i.index),this.itemSizeCache=new Map(this.itemSizeCache.set(i.key,o)),this.notify(!1))},this.measureElement=r=>{if(!r){this.elementsCache.forEach((o,i)=>{o.isConnected||(this.observer.unobserve(o),this.elementsCache.delete(i))});return}this._measureElement(r,void 0)},this.getVirtualItems=Ze(()=>[this.getVirtualIndexes(),this.getMeasurements()],(r,o)=>{const i=[];for(let c=0,l=r.length;c<l;c++){const s=r[c],d=o[s];i.push(d)}return i},{key:process.env.NODE_ENV!=="production"&&"getVirtualItems",debug:()=>this.options.debug}),this.getVirtualItemForOffset=r=>{const o=this.getMeasurements();if(o.length!==0)return yo(o[Cn(0,o.length-1,i=>yo(o[i]).start,r)])},this.getOffsetForAlignment=(r,o,i=0)=>{const c=this.getSize(),l=this.getScrollOffset();o==="auto"&&(o=r>=l+c?"end":"start"),o==="center"?r+=(i-c)/2:o==="end"&&(r-=c);const s=this.getTotalSize()+this.options.scrollMargin-c;return Math.max(Math.min(s,r),0)},this.getOffsetForIndex=(r,o="auto")=>{r=Math.max(0,Math.min(r,this.options.count-1));const i=this.measurementsCache[r];if(!i)return;const c=this.getSize(),l=this.getScrollOffset();if(o==="auto")if(i.end>=l+c-this.options.scrollPaddingEnd)o="end";else if(i.start<=l+this.options.scrollPaddingStart)o="start";else return[l,o];const s=o==="end"?i.end+this.options.scrollPaddingEnd:i.start-this.options.scrollPaddingStart;return[this.getOffsetForAlignment(s,o,i.size),o]},this.isDynamicMode=()=>this.elementsCache.size>0,this.scrollToOffset=(r,{align:o="start",behavior:i}={})=>{i==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getOffsetForAlignment(r,o),{adjustments:void 0,behavior:i})},this.scrollToIndex=(r,{align:o="auto",behavior:i}={})=>{i==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),r=Math.max(0,Math.min(r,this.options.count-1));let c=0;const l=10,s=a=>{if(!this.targetWindow)return;const u=this.getOffsetForIndex(r,a);if(!u){console.warn("Failed to get offset for index:",r);return}const[h,f]=u;this._scrollToOffset(h,{adjustments:void 0,behavior:i}),this.targetWindow.requestAnimationFrame(()=>{const b=this.getScrollOffset(),C=this.getOffsetForIndex(r,f);if(!C){console.warn("Failed to get offset for index:",r);return}Hc(C[0],b)||d(f)})},d=a=>{this.targetWindow&&(c++,c<l?(process.env.NODE_ENV!=="production"&&this.options.debug&&console.info("Schedule retry",c,l),this.targetWindow.requestAnimationFrame(()=>s(a))):console.warn(`Failed to scroll to index ${r} after ${l} attempts.`))};s(o)},this.scrollBy=(r,{behavior:o}={})=>{o==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getScrollOffset()+r,{adjustments:void 0,behavior:o})},this.getTotalSize=()=>{var r;const o=this.getMeasurements();let i;if(o.length===0)i=this.options.paddingStart;else if(this.options.lanes===1)i=((r=o[o.length-1])==null?void 0:r.end)??0;else{const c=Array(this.options.lanes).fill(null);let l=o.length-1;for(;l>=0&&c.some(s=>s===null);){const s=o[l];c[s.lane]===null&&(c[s.lane]=s.end),l--}i=Math.max(...c.filter(s=>s!==null))}return Math.max(i-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(r,{adjustments:o,behavior:i})=>{this.options.scrollToFn(r,{behavior:i,adjustments:o},this)},this.measure=()=>{this.itemSizeCache=new Map,this.laneAssignments=new Map,this.notify(!1)},this.setOptions(t)}}const Cn=(e,t,r,o)=>{for(;e<=t;){const i=(e+t)/2|0,c=r(i);if(c<o)e=i+1;else if(c>o)t=i-1;else return i}return e>0?e-1:0};function Jc({measurements:e,outerSize:t,scrollOffset:r,lanes:o}){const i=e.length-1,c=d=>e[d].start;if(e.length<=o)return{startIndex:0,endIndex:i};let l=Cn(0,i,c,r),s=l;if(o===1)for(;s<i&&e[s].end<r+t;)s++;else if(o>1){const d=Array(o).fill(0);for(;s<i&&d.some(u=>u<r+t);){const u=e[s];d[u.lane]=u.end,s++}const a=Array(o).fill(r+t);for(;l>=0&&a.some(u=>u>=r);){const u=e[l];a[u.lane]=u.start,l--}l=Math.max(0,l-l%o),s=Math.min(i,s+(o-1-s%o))}return{startIndex:l,endIndex:s}}const Eo=typeof document<"u"?w.useLayoutEffect:w.useEffect;function es(e){const t=w.useReducer(()=>({}),{})[1],r={...e,onChange:(i,c)=>{var l;c?ft.flushSync(t):t(),(l=e.onChange)==null||l.call(e,i,c)}},[o]=w.useState(()=>new Zc(r));return o.setOptions(r),Eo(()=>o._didMount(),[]),Eo(()=>o._willUpdate()),o}function vn(e){return es({observeElementRect:qc,observeElementOffset:Xc,scrollToFn:Qc,...e})}const ts="Select...",rs="Search...",os="No options",wn="bottom",ns=256,is=32,ls=4,cs=(e,t,r)=>r?e.multiSelect.trigger.disabled.backgroundColor:t==="warning"?e.multiSelect.state.warning.trigger.backgroundColor:t==="error"?e.multiSelect.state.error.trigger.backgroundColor:e.multiSelect.trigger.backgroundColor,ss=(e,t,r)=>r?e.multiSelect.trigger.disabled.borderColor:t==="warning"?e.multiSelect.state.warning.trigger.borderColor:t==="error"?e.multiSelect.state.error.trigger.borderColor:e.multiSelect.trigger.borderColor,as=(e,t)=>t==="warning"?e.multiSelect.state.warning.trigger.focus.outlineColor:t==="error"?e.multiSelect.state.error.trigger.focus.outlineColor:e.multiSelect.trigger.focus.outlineColor,us=(e,t)=>t==="warning"?e.multiSelect.state.warning.label.color:t==="error"?e.multiSelect.state.error.label.color:e.multiSelect.label.color,ds=(e,t)=>t?e.multiSelect.placeholder.disabled.color:e.multiSelect.placeholder.color,fs=(e,t,r)=>r?e.multiSelect.chip.disabled.backgroundColor:t==="warning"?e.multiSelect.state.warning.chip.backgroundColor:t==="error"?e.multiSelect.state.error.chip.backgroundColor:e.multiSelect.chip.backgroundColor,gs=(e,t,r)=>r?e.multiSelect.chip.disabled.color:t==="warning"?e.multiSelect.state.warning.chip.color:t==="error"?e.multiSelect.state.error.chip.color:e.multiSelect.chip.color,hs=(e,t,r)=>r?e.multiSelect.chip.disabled.remove.color:t==="warning"?e.multiSelect.state.warning.chip.remove.color:t==="error"?e.multiSelect.state.error.chip.remove.color:e.multiSelect.chip.remove.color,ps=(e,t,r)=>r?e.multiSelect.icon.disabled.color:t==="warning"?e.multiSelect.state.warning.icon.color:t==="error"?e.multiSelect.state.error.icon.color:e.multiSelect.icon.color,bs=(e,t,r)=>r?e.multiSelect.chevron.disabled.color:t==="warning"?e.multiSelect.state.warning.chevron.color:t==="error"?e.multiSelect.state.error.chevron.color:e.multiSelect.chevron.color,xs=I.div`
324
+ display: flex;
325
+ flex-direction: column;
326
+ gap: 2px;
327
+ position: relative;
328
+ width: ${({$fullWidth:e})=>e?"100%":"auto"};
329
+ min-width: 120px;
330
+ max-width: ${({$fullWidth:e})=>e?"none":"320px"};
331
+ `,ms=I.label`
332
+ font-size: 11px;
333
+ font-weight: 500;
334
+ line-height: 1.5;
335
+ color: ${({theme:e,$state:t})=>us(e,t)};
336
+ margin-left: 2px;
337
+ `,Cs=I.button`
338
+ display: flex;
339
+ align-items: center;
340
+ min-height: 32px;
341
+ padding: 4px 12px 4px 8px;
342
+ background-color: ${({theme:e,$state:t,$disabled:r})=>cs(e,t,r)};
343
+ border-radius: 10px;
344
+ border: 1px solid
345
+ ${({theme:e,$state:t,$disabled:r})=>ss(e,t,r)};
346
+ cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
347
+ transition: border-color 0.15s ease;
348
+ font-family: inherit;
349
+ text-align: left;
350
+ width: 100%;
351
+ gap: 4px;
352
+
353
+ &:focus-visible {
354
+ outline: 2px solid ${({theme:e,$state:t})=>as(e,t)};
355
+ outline-offset: 1px;
356
+ }
357
+ `,vs=I.span`
358
+ display: flex;
359
+ align-items: center;
360
+ justify-content: center;
361
+ flex-shrink: 0;
362
+ color: ${({theme:e,$state:t,$disabled:r})=>ps(e,t,r)};
363
+ `,ws=I.div`
364
+ display: flex;
365
+ flex-wrap: wrap;
366
+ gap: 4px;
367
+ flex: 1;
368
+ min-width: 0;
369
+ min-height: 24px;
370
+ align-items: center;
371
+ `,ys=I.span`
372
+ display: inline-flex;
373
+ align-items: center;
374
+ height: 24px;
375
+ padding: 0 4px 0 8px;
376
+ border-radius: 6px;
377
+ font-size: 13px;
378
+ font-weight: 400;
379
+ min-width: 0;
380
+ max-width: 100%;
381
+ background-color: ${({theme:e,$state:t,$disabled:r})=>fs(e,t,r)};
382
+ color: ${({theme:e,$state:t,$disabled:r})=>gs(e,t,r)};
383
+ `,ks=I.span`
384
+ flex: 1;
385
+ min-width: 0;
386
+ overflow: hidden;
387
+ text-overflow: ellipsis;
388
+ white-space: nowrap;
389
+ `,Ss=I.span`
390
+ display: flex;
391
+ align-items: center;
392
+ justify-content: center;
393
+ width: 16px;
394
+ height: 16px;
395
+ margin-left: 4px;
396
+ border-radius: 4px;
397
+ cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
398
+ color: ${({theme:e,$state:t,$disabled:r})=>hs(e,t,r)};
399
+ transition: color 0.15s ease;
400
+
401
+ &:hover {
402
+ color: ${({theme:e,$disabled:t})=>t?e.multiSelect.chip.disabled.remove.color:e.multiSelect.chip.remove.hover.color};
403
+ }
404
+ `,Rs=I.span`
405
+ font-size: 14px;
406
+ font-weight: 400;
407
+ line-height: 1.5;
408
+ color: ${({theme:e,$disabled:t})=>ds(e,t)};
409
+ `,Es=I.span`
410
+ display: flex;
411
+ align-items: center;
412
+ justify-content: center;
413
+ flex-shrink: 0;
414
+ margin-left: auto;
415
+ color: ${({theme:e,$state:t,$disabled:r})=>bs(e,t,r)};
416
+ transition: transform 0.15s ease;
417
+ transform: ${({$isOpen:e})=>e?"rotate(180deg)":"rotate(0deg)"};
418
+ `,$s=I.div`
419
+ z-index: 1000;
420
+ max-height: ${({$maxHeight:e})=>e}px;
421
+ overflow: hidden;
422
+ border-radius: 12px;
423
+ border: 1px solid ${({theme:e})=>e.multiSelect.content.borderColor};
424
+ background-color: ${({theme:e})=>e.multiSelect.content.backgroundColor};
425
+ box-shadow: ${({theme:e})=>e.multiSelect.content.shadow};
426
+ visibility: ${({$isOpen:e})=>e?"visible":"hidden"};
427
+ opacity: ${({$isOpen:e})=>e?1:0};
428
+ pointer-events: ${({$isOpen:e})=>e?"auto":"none"};
429
+ transition:
430
+ opacity 0.15s ease,
431
+ visibility 0.15s ease;
432
+ `,Is=I.div`
433
+ border-bottom: 1px solid ${({theme:e})=>e.multiSelect.search.borderColor};
434
+ `,Ts=I.input`
435
+ width: 100%;
436
+ height: 32px;
437
+ padding: 0 12px;
438
+ font-size: 14px;
439
+ font-weight: 500;
440
+ line-height: 1.5;
441
+ font-family: inherit;
442
+ color: ${({theme:e})=>e.multiSelect.search.color};
443
+ background-color: transparent;
444
+ outline: none;
445
+ border: 0;
446
+
447
+ &::placeholder {
448
+ color: ${({theme:e})=>e.multiSelect.search.placeholderColor};
449
+ }
450
+ `,$o=I.div`
451
+ padding: 4px;
452
+ overflow-y: auto;
453
+ max-height: inherit;
454
+ `,Io=I.div`
455
+ display: flex;
456
+ align-items: center;
457
+ height: 32px;
458
+ padding: 0 12px;
459
+ font-size: 14px;
460
+ font-weight: 400;
461
+ line-height: 1.5;
462
+ border-radius: 8px;
463
+ cursor: pointer;
464
+ transition: background-color 0.1s ease;
465
+ color: ${({theme:e})=>e.multiSelect.option.color};
466
+ background-color: ${({theme:e,$isHighlighted:t})=>t?e.multiSelect.option.hover.backgroundColor:e.multiSelect.option.backgroundColor};
467
+
468
+ &:hover {
469
+ background-color: ${({theme:e})=>e.multiSelect.option.hover.backgroundColor};
470
+ }
471
+ `,To=I.span`
472
+ display: flex;
473
+ align-items: center;
474
+ justify-content: center;
318
475
  width: 16px;
319
476
  height: 16px;
320
- `,Ds=({onBlur:e,onFocus:t,type:r,value:o})=>{const[n,s]=X.useState(!1),l=r==="password";return{inputType:X.useMemo(()=>l&&n?"text":r,[l,n,r]),isPassword:l,isPasswordVisible:n,handleBlur:f=>{e==null||e(f)},handleFocus:f=>{t==null||t(f)},handlePasswordMouseDown:f=>{f.preventDefault(),o&&s(!0)},handlePasswordMouseUp:()=>{s(!1)}}},qe=w.classNameGetter("input"),Ls=({className:e,classnames:t,fullWidth:r,icon:o,label:n,onChange:s,onBlur:l,onFocus:c,ref:d,state:a,type:u,value:g,...f})=>{const{inputType:p,isPassword:x,isPasswordVisible:h,handleBlur:y,handleFocus:m,handlePasswordMouseDown:v,handlePasswordMouseUp:k}=Ds({onBlur:l,onFocus:c,type:u,value:g}),R=h?uo.visible:uo.hidden,I=()=>o||null;return w.jsxs(Is,{className:qe("container",e,t==null?void 0:t.container),$fullWidth:r,children:[n&&w.jsx(Os,{className:qe("label",t==null?void 0:t.label),$state:a,children:n}),w.jsxs(Ts,{className:qe("wrapper",t==null?void 0:t.wrapper),$state:a,$disabled:f.disabled,children:[o&&w.jsx(As,{className:qe("icon",t==null?void 0:t.icon),$disabled:f.disabled,$state:a,children:I()}),w.jsx($s,{...f,ref:d,className:qe("input",t==null?void 0:t.input),$state:a,type:p,value:g,onChange:s,onFocus:m,onBlur:y}),x&&w.jsx(Ms,{type:"button",className:qe("toggle",t==null?void 0:t.toggle),$state:a,$disabled:f.disabled,onMouseDown:v,onMouseUp:k,onMouseLeave:k,tabIndex:-1,children:w.jsx(Ps,{viewBox:"0 0 16 16",fill:"currentColor",children:R.map(P=>w.jsx("path",{d:P},P))})})]})]})},Ns=(e,t,r)=>t?r==="warning"?e.radio.state.warning.circle.checked.borderColor:r==="error"?e.radio.state.error.circle.checked.borderColor:e.radio.circle.checked.borderColor:r==="warning"?e.radio.state.warning.circle.borderColor:r==="error"?e.radio.state.error.circle.borderColor:e.radio.circle.borderColor,Fs=(e,t)=>t==="warning"?e.radio.state.warning.circle.focus.shadowColor:t==="error"?e.radio.state.error.circle.focus.shadowColor:e.radio.circle.focus.shadowColor,_s=(e,t)=>t==="warning"?e.radio.state.warning.dot.color:t==="error"?e.radio.state.error.dot.color:e.radio.dot.color,js=(e,t)=>t==="warning"?e.radio.state.warning.label.color:t==="error"?e.radio.state.error.label.color:e.radio.label.color,zs=O.label`
477
+ margin-right: 8px;
478
+ flex-shrink: 0;
479
+ color: ${({theme:e})=>e.multiSelect.option.check.color};
480
+ opacity: ${({$isSelected:e})=>e?1:.15};
481
+ `,Oo=I.span`
482
+ flex: 1;
483
+ min-width: 0;
484
+ overflow: hidden;
485
+ text-overflow: ellipsis;
486
+ white-space: nowrap;
487
+ `,Os=I.div`
488
+ display: flex;
489
+ align-items: center;
490
+ justify-content: center;
491
+ height: 64px;
492
+ font-size: 14px;
493
+ font-weight: 400;
494
+ color: ${({theme:e})=>e.multiSelect.empty.color};
495
+ `,Ms=e=>`${e}-start`,As=({options:e,value:t,onChange:r,placement:o=wn,searchable:i=!1,disabled:c=!1})=>{const[l,s]=_.useState(!1),[d,a]=_.useState(""),[u,h]=_.useState(null),f=_.useRef([]),b=_.useRef(null),C=_.useMemo(()=>e.filter(x=>t.includes(x.value)),[e,t]),g=_.useMemo(()=>{if(!i||!d)return e;const x=d.toLowerCase();return e.filter(E=>E.label.toLowerCase().includes(x))},[e,d,i]),y=_.useCallback(x=>{c||(s(x),x||(a(""),h(null)))},[c]),p=_.useMemo(()=>Ms(o),[o]),{refs:v,floatingStyles:k,context:S}=Ar({open:l,onOpenChange:y,placement:p,middleware:[Sr(ls),Er(),Rr({padding:8}),fn({apply({rects:x,elements:E}){Object.assign(E.floating.style,{width:`${x.reference.width}px`})}})],whileElementsMounted:kr}),T=Or(S,{enabled:!c}),M=Mr(S),N=mn(S,{role:"listbox"}),B=xn(S,{listRef:f,activeIndex:u,onNavigate:h,virtual:!0,loop:!0}),X=_.useCallback(x=>t.includes(x),[t]),O=_.useCallback(x=>{const E=t.includes(x.value);r(E?t.filter(A=>A!==x.value):[...t,x.value])},[t,r]),F=_.useCallback((x,E)=>{E.stopPropagation(),r(t.filter(A=>A!==x))},[t,r]),{getReferenceProps:G,getFloatingProps:V,getItemProps:R}=Pr([T,M,N,B]),$=_.useCallback(()=>{const x=G(),E=x.onKeyDown;return{...x,onKeyDown:A=>{if(E==null||E(A),A.key==="Enter"&&l&&u!==null){A.preventDefault();const ee=g[u];ee&&O(ee)}A.key==="Backspace"&&!i&&t.length>0&&(A.preventDefault(),r(t.slice(0,-1)))}}},[G,l,u,g,O,i,t,r]),j=_.useCallback(x=>{a(x.target.value),h(0)},[]),L=_.useCallback(x=>{if(x.key==="Enter"&&u!==null){x.preventDefault();const E=g[u];E&&O(E)}x.key==="Backspace"&&d===""&&t.length>0&&(x.preventDefault(),r(t.slice(0,-1)))},[u,g,O,d,t,r]);return{isOpen:l,setIsOpen:y,selectedOptions:C,filteredOptions:g,searchQuery:d,setSearchQuery:a,highlightedIndex:u,context:S,refs:{setReference:v.setReference,setFloating:v.setFloating},floatingStyles:k,getReferenceProps:$,getFloatingProps:V,getItemProps:x=>R({onClick:()=>{const E=g[x];E&&O(E)},onKeyDown:E=>{if(E.key==="Enter"||E.key===" "){E.preventDefault();const A=g[x];A&&O(A)}}}),listRef:f,handleToggle:O,handleRemove:F,handleSearchChange:j,handleSearchKeyDown:L,searchInputRef:b,isSelected:X}},ve=m.classNameGetter("multiselect"),Ps=({options:e,value:t,onChange:r,placeholder:o=ts,searchPlaceholder:i=rs,emptyMessage:c=os,label:l,icon:s,state:d,disabled:a,fullWidth:u,placement:h=wn,maxHeight:f=ns,virtualized:b,searchable:C,portalRenderNode:g,className:y,classnames:p,...v})=>{const k=_.useRef(null),{isOpen:S,selectedOptions:T,filteredOptions:M,searchQuery:N,context:B,refs:X,floatingStyles:O,getReferenceProps:F,getFloatingProps:G,getItemProps:V,listRef:R,handleSearchChange:$,handleSearchKeyDown:j,handleRemove:L,searchInputRef:x,highlightedIndex:E,isSelected:A}=As({options:e,value:t,onChange:r,placement:h,searchable:C,disabled:a}),ue=f-(C?56:0)-8,z=vn({count:M.length,getScrollElement:()=>k.current,estimateSize:()=>is,overscan:5,enabled:b}),Y=()=>M.length===0?m.jsx(Os,{className:ve("empty",p==null?void 0:p.empty),children:c}):b?m.jsx($o,{ref:k,className:ve("list",p==null?void 0:p.list),style:{maxHeight:ue,overflow:"auto"},children:m.jsx("div",{style:{height:z.getTotalSize(),width:"100%",position:"relative"},children:z.getVirtualItems().map(q=>{const ne=M[q.index];if(!ne)return null;const Ee=A(ne.value);return m.jsxs(Io,{ref:Ce=>{R.current[q.index]=Ce},className:ve("option",p==null?void 0:p.option),$isHighlighted:E===q.index,style:{position:"absolute",top:0,left:0,width:"100%",height:q.size,transform:`translateY(${q.start}px)`},...V(q.index),children:[m.jsx(To,{$isSelected:Ee,children:m.jsx(m.Check,{size:16})}),m.jsx(Oo,{children:ne.label})]},ne.value)})})}):m.jsx($o,{ref:k,className:ve("list",p==null?void 0:p.list),style:{maxHeight:ue},children:M.map((q,ne)=>{const Ee=A(q.value);return m.jsxs(Io,{ref:Ce=>{R.current[ne]=Ce},className:ve("option",p==null?void 0:p.option),$isHighlighted:E===ne,...V(ne),children:[m.jsx(To,{$isSelected:Ee,children:m.jsx(m.Check,{size:16})}),m.jsx(Oo,{children:q.label})]},q.value)})}),H=()=>{if(!S)return null;const q=m.jsx(bn,{context:B,initialFocus:C?x:void 0,modal:!1,children:m.jsxs($s,{ref:X.setFloating,className:ve("content",p==null?void 0:p.content),style:O,$isOpen:S,$maxHeight:f,...G(),children:[C&&m.jsx(Is,{className:ve("search",p==null?void 0:p.search),children:m.jsx(Ts,{ref:x,type:"text",placeholder:i,value:N,onChange:$,onKeyDown:j,onClick:ne=>ne.stopPropagation()})}),Y()]})});return g?ft.createPortal(q,g):q},te=()=>T.length===0?m.jsx(Rs,{$disabled:a,children:o}):T.map(q=>m.jsxs(ys,{className:ve("chip",p==null?void 0:p.chip),$state:d,$disabled:a,children:[m.jsx(ks,{children:q.label}),m.jsx(Ss,{role:"button",tabIndex:a?-1:0,className:ve("chip-remove",p==null?void 0:p.chipRemove),$state:d,$disabled:a,onClick:ne=>!a&&L(q.value,ne),onKeyDown:ne=>{!a&&(ne.key==="Enter"||ne.key===" ")&&(ne.preventDefault(),L(q.value,ne))},"aria-label":`Remove ${q.label}`,children:m.jsx(m.X,{size:12})})]},q.value));return m.jsxs(xs,{...v,className:ve("container",y,p==null?void 0:p.container),$fullWidth:u,children:[l&&m.jsx(ms,{className:ve("label",p==null?void 0:p.label),$state:d,children:l}),m.jsxs(Cs,{ref:X.setReference,type:"button",className:ve("trigger",p==null?void 0:p.trigger),$state:d,$disabled:a,$isOpen:S,$hasValue:T.length>0,disabled:a,"aria-haspopup":"listbox","aria-expanded":S,...F(),children:[s&&m.jsx(vs,{$state:d,$disabled:a,children:s}),m.jsx(ws,{className:ve("chips",p==null?void 0:p.chips),children:te()}),m.jsx(Es,{$state:d,$disabled:a,$isOpen:S,children:m.jsx(m.ChevronDown,{size:16})})]}),H()]})},Ds=(e,t,r)=>t?r==="warning"?e.radio.state.warning.circle.checked.borderColor:r==="error"?e.radio.state.error.circle.checked.borderColor:e.radio.circle.checked.borderColor:r==="warning"?e.radio.state.warning.circle.borderColor:r==="error"?e.radio.state.error.circle.borderColor:e.radio.circle.borderColor,Ls=(e,t)=>t==="warning"?e.radio.state.warning.circle.focus.shadowColor:t==="error"?e.radio.state.error.circle.focus.shadowColor:e.radio.circle.focus.shadowColor,Ns=(e,t)=>t==="warning"?e.radio.state.warning.dot.color:t==="error"?e.radio.state.error.dot.color:e.radio.dot.color,Fs=(e,t)=>t==="warning"?e.radio.state.warning.label.color:t==="error"?e.radio.state.error.label.color:e.radio.label.color,_s=I.label`
321
496
  display: inline-flex;
322
497
  align-items: center;
323
498
  gap: 8px;
324
499
  cursor: pointer;
325
500
 
326
501
  &:has(input:focus-visible) > span:first-of-type {
327
- box-shadow: 0 0 0 3px ${({theme:e,$state:t})=>Fs(e,t)};
502
+ box-shadow: 0 0 0 3px ${({theme:e,$state:t})=>Ls(e,t)};
328
503
  }
329
504
 
330
505
  ${({$disabled:e})=>e&&`
331
506
  opacity: 0.5;
332
507
  cursor: not-allowed;
333
508
  `}
334
- `,Bs=O.input`
509
+ `,js=I.input`
335
510
  position: absolute;
336
511
  opacity: 0;
337
512
  width: 0;
338
513
  height: 0;
339
514
  pointer-events: none;
340
- `,Ws=O.span`
515
+ `,Bs=I.span`
341
516
  display: inline-flex;
342
517
  align-items: center;
343
518
  justify-content: center;
@@ -345,31 +520,28 @@
345
520
  height: 18px;
346
521
  border-radius: 50%;
347
522
  border: 1.5px solid
348
- ${({theme:e,$checked:t,$state:r})=>Ns(e,t,r)};
523
+ ${({theme:e,$checked:t,$state:r})=>Ds(e,t,r)};
349
524
  background-color: transparent;
350
525
  transition:
351
526
  border-color 0.15s ease,
352
527
  box-shadow 0.15s ease;
353
- `,Vs=O.span`
528
+ `,zs=I.span`
354
529
  width: 10px;
355
530
  height: 10px;
356
531
  border-radius: 50%;
357
- background-color: ${({theme:e,$state:t})=>_s(e,t)};
532
+ background-color: ${({theme:e,$state:t})=>Ns(e,t)};
358
533
  opacity: ${({$visible:e})=>e?1:0};
359
534
  transform: ${({$visible:e})=>e?"scale(1)":"scale(0)"};
360
535
  transition:
361
536
  opacity 0.15s ease,
362
537
  transform 0.15s ease;
363
- `,Hs=O.span`
538
+ `,Ws=I.span`
364
539
  font-size: 14px;
365
540
  line-height: 1.5;
366
- color: ${({theme:e,$state:t})=>js(e,t)};
541
+ color: ${({theme:e,$state:t})=>Fs(e,t)};
367
542
  user-select: none;
368
543
  font-weight: 500;
369
- `,it=w.classNameGetter("radio"),Rr=({checked:e,className:t,classnames:r,disabled:o,label:n,onChange:s,ref:l,state:c,...d})=>w.jsxs(zs,{className:it("container",t,r==null?void 0:r.container),$disabled:o,$state:c,children:[w.jsx(Bs,{...d,ref:l,type:"radio",className:it("input",r==null?void 0:r.input),checked:e,disabled:o,onChange:s}),w.jsx(Ws,{className:it("circle",r==null?void 0:r.circle),$checked:e,$state:c,children:w.jsx(Vs,{className:it("dot",r==null?void 0:r.dot),$visible:e,$state:c})}),n&&w.jsx(Hs,{className:it("label",r==null?void 0:r.label),$state:c,children:n})]});function Xe(e,t,r){let o=r.initialDeps??[],n,s=!0;function l(){var c,d,a;let u;r.key&&((c=r.debug)!=null&&c.call(r))&&(u=Date.now());const g=e();if(!(g.length!==o.length||g.some((x,h)=>o[h]!==x)))return n;o=g;let p;if(r.key&&((d=r.debug)!=null&&d.call(r))&&(p=Date.now()),n=t(...g),r.key&&((a=r.debug)!=null&&a.call(r))){const x=Math.round((Date.now()-u)*100)/100,h=Math.round((Date.now()-p)*100)/100,y=h/16,m=(v,k)=>{for(v=String(v);v.length<k;)v=" "+v;return v};console.info(`%c⏱ ${m(h,5)} /${m(x,5)} ms`,`
370
- font-size: .6rem;
371
- font-weight: bold;
372
- color: hsl(${Math.max(0,Math.min(120-120*y,120))}deg 100% 31%);`,r==null?void 0:r.key)}return r!=null&&r.onChange&&!(s&&r.skipInitialOnChange)&&r.onChange(n),s=!1,n}return l.updateDeps=c=>{o=c},l}function fo(e,t){if(e===void 0)throw new Error("Unexpected undefined");return e}const Us=(e,t)=>Math.abs(e-t)<1.01,Gs=(e,t,r)=>{let o;return function(...n){e.clearTimeout(o),o=e.setTimeout(()=>t.apply(this,n),r)}},go=e=>{const{offsetWidth:t,offsetHeight:r}=e;return{width:t,height:r}},Ks=e=>e,qs=e=>{const t=Math.max(e.startIndex-e.overscan,0),r=Math.min(e.endIndex+e.overscan,e.count-1),o=[];for(let n=t;n<=r;n++)o.push(n);return o},Xs=(e,t)=>{const r=e.scrollElement;if(!r)return;const o=e.targetWindow;if(!o)return;const n=l=>{const{width:c,height:d}=l;t({width:Math.round(c),height:Math.round(d)})};if(n(go(r)),!o.ResizeObserver)return()=>{};const s=new o.ResizeObserver(l=>{const c=()=>{const d=l[0];if(d!=null&&d.borderBoxSize){const a=d.borderBoxSize[0];if(a){n({width:a.inlineSize,height:a.blockSize});return}}n(go(r))};e.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(c):c()});return s.observe(r,{box:"border-box"}),()=>{s.unobserve(r)}},ho={passive:!0},po=typeof window>"u"?!0:"onscrollend"in window,Ys=(e,t)=>{const r=e.scrollElement;if(!r)return;const o=e.targetWindow;if(!o)return;let n=0;const s=e.options.useScrollendEvent&&po?()=>{}:Gs(o,()=>{t(n,!1)},e.options.isScrollingResetDelay),l=u=>()=>{const{horizontal:g,isRtl:f}=e.options;n=g?r.scrollLeft*(f&&-1||1):r.scrollTop,s(),t(n,u)},c=l(!0),d=l(!1);d(),r.addEventListener("scroll",c,ho);const a=e.options.useScrollendEvent&&po;return a&&r.addEventListener("scrollend",d,ho),()=>{r.removeEventListener("scroll",c),a&&r.removeEventListener("scrollend",d)}},Zs=(e,t,r)=>{if(t!=null&&t.borderBoxSize){const o=t.borderBoxSize[0];if(o)return Math.round(o[r.options.horizontal?"inlineSize":"blockSize"])}return e[r.options.horizontal?"offsetWidth":"offsetHeight"]},Qs=(e,{adjustments:t=0,behavior:r},o)=>{var n,s;const l=e+t;(s=(n=o.scrollElement)==null?void 0:n.scrollTo)==null||s.call(n,{[o.options.horizontal?"left":"top"]:l,behavior:r})};class Js{constructor(t){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.measurementsCache=[],this.itemSizeCache=new Map,this.laneAssignments=new Map,this.pendingMeasuredCacheIndexes=[],this.prevLanes=void 0,this.lanesChangedFlag=!1,this.lanesSettling=!1,this.scrollRect=null,this.scrollOffset=null,this.scrollDirection=null,this.scrollAdjustments=0,this.elementsCache=new Map,this.observer=(()=>{let r=null;const o=()=>r||(!this.targetWindow||!this.targetWindow.ResizeObserver?null:r=new this.targetWindow.ResizeObserver(n=>{n.forEach(s=>{const l=()=>{this._measureElement(s.target,s)};this.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(l):l()})}));return{disconnect:()=>{var n;(n=o())==null||n.disconnect(),r=null},observe:n=>{var s;return(s=o())==null?void 0:s.observe(n,{box:"border-box"})},unobserve:n=>{var s;return(s=o())==null?void 0:s.unobserve(n)}}})(),this.range=null,this.setOptions=r=>{Object.entries(r).forEach(([o,n])=>{typeof n>"u"&&delete r[o]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:Ks,rangeExtractor:qs,onChange:()=>{},measureElement:Zs,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:"data-index",initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,enabled:!0,isRtl:!1,useScrollendEvent:!1,useAnimationFrameWithResizeObserver:!1,...r}},this.notify=r=>{var o,n;(n=(o=this.options).onChange)==null||n.call(o,this,r)},this.maybeNotify=Xe(()=>(this.calculateRange(),[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]),r=>{this.notify(r)},{key:process.env.NODE_ENV!=="production"&&"maybeNotify",debug:()=>this.options.debug,initialDeps:[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]}),this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(r=>r()),this.unsubs=[],this.observer.disconnect(),this.scrollElement=null,this.targetWindow=null},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{var r;const o=this.options.enabled?this.options.getScrollElement():null;if(this.scrollElement!==o){if(this.cleanup(),!o){this.maybeNotify();return}this.scrollElement=o,this.scrollElement&&"ownerDocument"in this.scrollElement?this.targetWindow=this.scrollElement.ownerDocument.defaultView:this.targetWindow=((r=this.scrollElement)==null?void 0:r.window)??null,this.elementsCache.forEach(n=>{this.observer.observe(n)}),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0}),this.unsubs.push(this.options.observeElementRect(this,n=>{this.scrollRect=n,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(n,s)=>{this.scrollAdjustments=0,this.scrollDirection=s?this.getScrollOffset()<n?"forward":"backward":null,this.scrollOffset=n,this.isScrolling=s,this.maybeNotify()}))}},this.getSize=()=>this.options.enabled?(this.scrollRect=this.scrollRect??this.options.initialRect,this.scrollRect[this.options.horizontal?"width":"height"]):(this.scrollRect=null,0),this.getScrollOffset=()=>this.options.enabled?(this.scrollOffset=this.scrollOffset??(typeof this.options.initialOffset=="function"?this.options.initialOffset():this.options.initialOffset),this.scrollOffset):(this.scrollOffset=null,0),this.getFurthestMeasurement=(r,o)=>{const n=new Map,s=new Map;for(let l=o-1;l>=0;l--){const c=r[l];if(n.has(c.lane))continue;const d=s.get(c.lane);if(d==null||c.end>d.end?s.set(c.lane,c):c.end<d.end&&n.set(c.lane,!0),n.size===this.options.lanes)break}return s.size===this.options.lanes?Array.from(s.values()).sort((l,c)=>l.end===c.end?l.index-c.index:l.end-c.end)[0]:void 0},this.getMeasurementOptions=Xe(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled,this.options.lanes],(r,o,n,s,l,c)=>(this.prevLanes!==void 0&&this.prevLanes!==c&&(this.lanesChangedFlag=!0),this.prevLanes=c,this.pendingMeasuredCacheIndexes=[],{count:r,paddingStart:o,scrollMargin:n,getItemKey:s,enabled:l,lanes:c}),{key:!1,skipInitialOnChange:!0,onChange:()=>{this.notify(this.isScrolling)}}),this.getMeasurements=Xe(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:r,paddingStart:o,scrollMargin:n,getItemKey:s,enabled:l,lanes:c},d)=>{if(!l)return this.measurementsCache=[],this.itemSizeCache.clear(),this.laneAssignments.clear(),[];if(this.laneAssignments.size>r)for(const f of this.laneAssignments.keys())f>=r&&this.laneAssignments.delete(f);this.lanesChangedFlag&&(this.lanesChangedFlag=!1,this.lanesSettling=!0,this.measurementsCache=[],this.itemSizeCache.clear(),this.laneAssignments.clear(),this.pendingMeasuredCacheIndexes=[]),this.measurementsCache.length===0&&(this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach(f=>{this.itemSizeCache.set(f.key,f.size)}));const a=this.lanesSettling?0:this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[],this.lanesSettling&&this.measurementsCache.length===r&&(this.lanesSettling=!1);const u=this.measurementsCache.slice(0,a),g=new Array(c).fill(void 0);for(let f=0;f<a;f++){const p=u[f];p&&(g[p.lane]=f)}for(let f=a;f<r;f++){const p=s(f),x=this.laneAssignments.get(f);let h,y;if(x!==void 0&&this.options.lanes>1){h=x;const R=g[h],I=R!==void 0?u[R]:void 0;y=I?I.end+this.options.gap:o+n}else{const R=this.options.lanes===1?u[f-1]:this.getFurthestMeasurement(u,f);y=R?R.end+this.options.gap:o+n,h=R?R.lane:f%this.options.lanes,this.options.lanes>1&&this.laneAssignments.set(f,h)}const m=d.get(p),v=typeof m=="number"?m:this.options.estimateSize(f),k=y+v;u[f]={index:f,start:y,size:v,end:k,key:p,lane:h},g[h]=f}return this.measurementsCache=u,u},{key:process.env.NODE_ENV!=="production"&&"getMeasurements",debug:()=>this.options.debug}),this.calculateRange=Xe(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset(),this.options.lanes],(r,o,n,s)=>this.range=r.length>0&&o>0?ec({measurements:r,outerSize:o,scrollOffset:n,lanes:s}):null,{key:process.env.NODE_ENV!=="production"&&"calculateRange",debug:()=>this.options.debug}),this.getVirtualIndexes=Xe(()=>{let r=null,o=null;const n=this.calculateRange();return n&&(r=n.startIndex,o=n.endIndex),this.maybeNotify.updateDeps([this.isScrolling,r,o]),[this.options.rangeExtractor,this.options.overscan,this.options.count,r,o]},(r,o,n,s,l)=>s===null||l===null?[]:r({startIndex:s,endIndex:l,overscan:o,count:n}),{key:process.env.NODE_ENV!=="production"&&"getVirtualIndexes",debug:()=>this.options.debug}),this.indexFromElement=r=>{const o=this.options.indexAttribute,n=r.getAttribute(o);return n?parseInt(n,10):(console.warn(`Missing attribute name '${o}={index}' on measured element.`),-1)},this._measureElement=(r,o)=>{const n=this.indexFromElement(r),s=this.measurementsCache[n];if(!s)return;const l=s.key,c=this.elementsCache.get(l);c!==r&&(c&&this.observer.unobserve(c),this.observer.observe(r),this.elementsCache.set(l,r)),r.isConnected&&this.resizeItem(n,this.options.measureElement(r,o,this))},this.resizeItem=(r,o)=>{const n=this.measurementsCache[r];if(!n)return;const s=this.itemSizeCache.get(n.key)??n.size,l=o-s;l!==0&&((this.shouldAdjustScrollPositionOnItemSizeChange!==void 0?this.shouldAdjustScrollPositionOnItemSizeChange(n,l,this):n.start<this.getScrollOffset()+this.scrollAdjustments)&&(process.env.NODE_ENV!=="production"&&this.options.debug&&console.info("correction",l),this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=l,behavior:void 0})),this.pendingMeasuredCacheIndexes.push(n.index),this.itemSizeCache=new Map(this.itemSizeCache.set(n.key,o)),this.notify(!1))},this.measureElement=r=>{if(!r){this.elementsCache.forEach((o,n)=>{o.isConnected||(this.observer.unobserve(o),this.elementsCache.delete(n))});return}this._measureElement(r,void 0)},this.getVirtualItems=Xe(()=>[this.getVirtualIndexes(),this.getMeasurements()],(r,o)=>{const n=[];for(let s=0,l=r.length;s<l;s++){const c=r[s],d=o[c];n.push(d)}return n},{key:process.env.NODE_ENV!=="production"&&"getVirtualItems",debug:()=>this.options.debug}),this.getVirtualItemForOffset=r=>{const o=this.getMeasurements();if(o.length!==0)return fo(o[an(0,o.length-1,n=>fo(o[n]).start,r)])},this.getOffsetForAlignment=(r,o,n=0)=>{const s=this.getSize(),l=this.getScrollOffset();o==="auto"&&(o=r>=l+s?"end":"start"),o==="center"?r+=(n-s)/2:o==="end"&&(r-=s);const c=this.getTotalSize()+this.options.scrollMargin-s;return Math.max(Math.min(c,r),0)},this.getOffsetForIndex=(r,o="auto")=>{r=Math.max(0,Math.min(r,this.options.count-1));const n=this.measurementsCache[r];if(!n)return;const s=this.getSize(),l=this.getScrollOffset();if(o==="auto")if(n.end>=l+s-this.options.scrollPaddingEnd)o="end";else if(n.start<=l+this.options.scrollPaddingStart)o="start";else return[l,o];const c=o==="end"?n.end+this.options.scrollPaddingEnd:n.start-this.options.scrollPaddingStart;return[this.getOffsetForAlignment(c,o,n.size),o]},this.isDynamicMode=()=>this.elementsCache.size>0,this.scrollToOffset=(r,{align:o="start",behavior:n}={})=>{n==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getOffsetForAlignment(r,o),{adjustments:void 0,behavior:n})},this.scrollToIndex=(r,{align:o="auto",behavior:n}={})=>{n==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),r=Math.max(0,Math.min(r,this.options.count-1));let s=0;const l=10,c=a=>{if(!this.targetWindow)return;const u=this.getOffsetForIndex(r,a);if(!u){console.warn("Failed to get offset for index:",r);return}const[g,f]=u;this._scrollToOffset(g,{adjustments:void 0,behavior:n}),this.targetWindow.requestAnimationFrame(()=>{const p=this.getScrollOffset(),x=this.getOffsetForIndex(r,f);if(!x){console.warn("Failed to get offset for index:",r);return}Us(x[0],p)||d(f)})},d=a=>{this.targetWindow&&(s++,s<l?(process.env.NODE_ENV!=="production"&&this.options.debug&&console.info("Schedule retry",s,l),this.targetWindow.requestAnimationFrame(()=>c(a))):console.warn(`Failed to scroll to index ${r} after ${l} attempts.`))};c(o)},this.scrollBy=(r,{behavior:o}={})=>{o==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getScrollOffset()+r,{adjustments:void 0,behavior:o})},this.getTotalSize=()=>{var r;const o=this.getMeasurements();let n;if(o.length===0)n=this.options.paddingStart;else if(this.options.lanes===1)n=((r=o[o.length-1])==null?void 0:r.end)??0;else{const s=Array(this.options.lanes).fill(null);let l=o.length-1;for(;l>=0&&s.some(c=>c===null);){const c=o[l];s[c.lane]===null&&(s[c.lane]=c.end),l--}n=Math.max(...s.filter(c=>c!==null))}return Math.max(n-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(r,{adjustments:o,behavior:n})=>{this.options.scrollToFn(r,{behavior:n,adjustments:o},this)},this.measure=()=>{this.itemSizeCache=new Map,this.laneAssignments=new Map,this.notify(!1)},this.setOptions(t)}}const an=(e,t,r,o)=>{for(;e<=t;){const n=(e+t)/2|0,s=r(n);if(s<o)e=n+1;else if(s>o)t=n-1;else return n}return e>0?e-1:0};function ec({measurements:e,outerSize:t,scrollOffset:r,lanes:o}){const n=e.length-1,s=d=>e[d].start;if(e.length<=o)return{startIndex:0,endIndex:n};let l=an(0,n,s,r),c=l;if(o===1)for(;c<n&&e[c].end<r+t;)c++;else if(o>1){const d=Array(o).fill(0);for(;c<n&&d.some(u=>u<r+t);){const u=e[c];d[u.lane]=u.end,c++}const a=Array(o).fill(r+t);for(;l>=0&&a.some(u=>u>=r);){const u=e[l];a[u.lane]=u.start,l--}l=Math.max(0,l-l%o),c=Math.min(n,c+(o-1-c%o))}return{startIndex:l,endIndex:c}}const bo=typeof document<"u"?C.useLayoutEffect:C.useEffect;function tc(e){const t=C.useReducer(()=>({}),{})[1],r={...e,onChange:(n,s)=>{var l;s?Ft.flushSync(t):t(),(l=e.onChange)==null||l.call(e,n,s)}},[o]=C.useState(()=>new Js(r));return o.setOptions(r),bo(()=>o._didMount(),[]),bo(()=>o._willUpdate()),o}function rc(e){return tc({observeElementRect:Xs,observeElementOffset:Ys,scrollToFn:Qs,...e})}const oc="Select...",nc="Search...",ic="No options",un="bottom",lc=256,sc=32,cc=4,ac=(e,t,r)=>r?e.select.trigger.disabled.backgroundColor:t==="warning"?e.select.state.warning.trigger.backgroundColor:t==="error"?e.select.state.error.trigger.backgroundColor:e.select.trigger.backgroundColor,uc=(e,t,r)=>r?e.select.trigger.disabled.borderColor:t==="warning"?e.select.state.warning.trigger.borderColor:t==="error"?e.select.state.error.trigger.borderColor:e.select.trigger.borderColor,dc=(e,t)=>t==="warning"?e.select.state.warning.trigger.focus.outlineColor:t==="error"?e.select.state.error.trigger.focus.outlineColor:e.select.trigger.focus.outlineColor,fc=(e,t)=>t==="warning"?e.select.state.warning.label.color:t==="error"?e.select.state.error.label.color:e.select.label.color,gc=(e,t,r,o)=>r?e.select.value.disabled.color:o?t==="warning"?e.select.state.warning.value.placeholderColor:t==="error"?e.select.state.error.value.placeholderColor:e.select.value.placeholderColor:t==="warning"?e.select.state.warning.value.color:t==="error"?e.select.state.error.value.color:e.select.value.color,hc=(e,t,r)=>r?e.select.icon.disabled.color:t==="warning"?e.select.state.warning.icon.color:t==="error"?e.select.state.error.icon.color:e.select.icon.color,pc=(e,t,r)=>r?e.select.chevron.disabled.color:t==="warning"?e.select.state.warning.chevron.color:t==="error"?e.select.state.error.chevron.color:e.select.chevron.color,bc=O.div`
544
+ `,st=m.classNameGetter("radio"),Dr=({checked:e,className:t,classnames:r,disabled:o,label:i,onChange:c,ref:l,state:s,...d})=>m.jsxs(_s,{className:st("container",t,r==null?void 0:r.container),$disabled:o,$state:s,children:[m.jsx(js,{...d,ref:l,type:"radio",className:st("input",r==null?void 0:r.input),checked:e,disabled:o,onChange:c}),m.jsx(Bs,{className:st("circle",r==null?void 0:r.circle),$checked:e,$state:s,children:m.jsx(zs,{className:st("dot",r==null?void 0:r.dot),$visible:e,$state:s})}),i&&m.jsx(Ws,{className:st("label",r==null?void 0:r.label),$state:s,children:i})]}),Vs="Select...",Hs="Search...",Us="No options",yn="bottom",Ks=256,Gs=32,qs=4,Xs=(e,t,r)=>r?e.select.trigger.disabled.backgroundColor:t==="warning"?e.select.state.warning.trigger.backgroundColor:t==="error"?e.select.state.error.trigger.backgroundColor:e.select.trigger.backgroundColor,Ys=(e,t,r)=>r?e.select.trigger.disabled.borderColor:t==="warning"?e.select.state.warning.trigger.borderColor:t==="error"?e.select.state.error.trigger.borderColor:e.select.trigger.borderColor,Qs=(e,t)=>t==="warning"?e.select.state.warning.trigger.focus.outlineColor:t==="error"?e.select.state.error.trigger.focus.outlineColor:e.select.trigger.focus.outlineColor,Zs=(e,t)=>t==="warning"?e.select.state.warning.label.color:t==="error"?e.select.state.error.label.color:e.select.label.color,Js=(e,t,r,o)=>r?e.select.value.disabled.color:o?t==="warning"?e.select.state.warning.value.placeholderColor:t==="error"?e.select.state.error.value.placeholderColor:e.select.value.placeholderColor:t==="warning"?e.select.state.warning.value.color:t==="error"?e.select.state.error.value.color:e.select.value.color,ea=(e,t,r)=>r?e.select.icon.disabled.color:t==="warning"?e.select.state.warning.icon.color:t==="error"?e.select.state.error.icon.color:e.select.icon.color,ta=(e,t,r)=>r?e.select.chevron.disabled.color:t==="warning"?e.select.state.warning.chevron.color:t==="error"?e.select.state.error.chevron.color:e.select.chevron.color,ra=I.div`
373
545
  display: flex;
374
546
  flex-direction: column;
375
547
  gap: 2px;
@@ -377,21 +549,21 @@
377
549
  width: ${({$fullWidth:e})=>e?"100%":"auto"};
378
550
  min-width: 120px;
379
551
  max-width: ${({$fullWidth:e})=>e?"none":"320px"};
380
- `,xc=O.label`
552
+ `,oa=I.label`
381
553
  font-size: 11px;
382
554
  font-weight: 500;
383
555
  line-height: 1.5;
384
- color: ${({theme:e,$state:t})=>fc(e,t)};
556
+ color: ${({theme:e,$state:t})=>Zs(e,t)};
385
557
  margin-left: 2px;
386
- `,mc=O.button`
558
+ `,na=I.button`
387
559
  display: flex;
388
560
  align-items: center;
389
561
  height: 32px;
390
562
  padding: 0 12px;
391
- background-color: ${({theme:e,$state:t,$disabled:r})=>ac(e,t,r)};
563
+ background-color: ${({theme:e,$state:t,$disabled:r})=>Xs(e,t,r)};
392
564
  border-radius: 10px;
393
565
  border: 1px solid
394
- ${({theme:e,$state:t,$disabled:r})=>uc(e,t,r)};
566
+ ${({theme:e,$state:t,$disabled:r})=>Ys(e,t,r)};
395
567
  cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
396
568
  transition: border-color 0.15s ease;
397
569
  font-family: inherit;
@@ -399,16 +571,16 @@
399
571
  width: 100%;
400
572
 
401
573
  &:focus-visible {
402
- outline: 2px solid ${({theme:e,$state:t})=>dc(e,t)};
574
+ outline: 2px solid ${({theme:e,$state:t})=>Qs(e,t)};
403
575
  outline-offset: 1px;
404
576
  }
405
- `,Cc=O.span`
577
+ `,ia=I.span`
406
578
  display: flex;
407
579
  align-items: center;
408
580
  justify-content: center;
409
581
  margin-right: 8px;
410
- color: ${({theme:e,$state:t,$disabled:r})=>hc(e,t,r)};
411
- `,vc=O.span`
582
+ color: ${({theme:e,$state:t,$disabled:r})=>ea(e,t,r)};
583
+ `,la=I.span`
412
584
  flex: 1;
413
585
  min-width: 0;
414
586
  font-size: 14px;
@@ -417,16 +589,16 @@
417
589
  overflow: hidden;
418
590
  white-space: nowrap;
419
591
  text-overflow: ellipsis;
420
- color: ${({theme:e,$state:t,$disabled:r,$isPlaceholder:o})=>gc(e,t,r,o)};
421
- `,wc=O.span`
592
+ color: ${({theme:e,$state:t,$disabled:r,$isPlaceholder:o})=>Js(e,t,r,o)};
593
+ `,ca=I.span`
422
594
  display: flex;
423
595
  align-items: center;
424
596
  justify-content: center;
425
597
  margin-left: 8px;
426
- color: ${({theme:e,$state:t,$disabled:r})=>pc(e,t,r)};
598
+ color: ${({theme:e,$state:t,$disabled:r})=>ta(e,t,r)};
427
599
  transition: transform 0.15s ease;
428
600
  transform: ${({$isOpen:e})=>e?"rotate(180deg)":"rotate(0deg)"};
429
- `,yc=O.div`
601
+ `,sa=I.div`
430
602
  z-index: 1000;
431
603
  max-height: ${({$maxHeight:e})=>e}px;
432
604
  overflow: hidden;
@@ -440,10 +612,9 @@
440
612
  transition:
441
613
  opacity 0.15s ease,
442
614
  visibility 0.15s ease;
443
- `,kc=O.div`
444
- padding: 8px;
615
+ `,aa=I.div`
445
616
  border-bottom: 1px solid ${({theme:e})=>e.select.search.borderColor};
446
- `,Rc=O.input`
617
+ `,ua=I.input`
447
618
  width: 100%;
448
619
  height: 32px;
449
620
  padding: 0 12px;
@@ -452,24 +623,18 @@
452
623
  line-height: 1.5;
453
624
  font-family: inherit;
454
625
  color: ${({theme:e})=>e.select.search.color};
455
- background-color: ${({theme:e})=>e.select.search.backgroundColor};
456
- border: 1px solid ${({theme:e})=>e.select.search.borderColor};
457
- border-radius: 8px;
626
+ background-color: transparent;
627
+ border: 0;
458
628
  outline: none;
459
629
 
460
630
  &::placeholder {
461
631
  color: ${({theme:e})=>e.select.search.placeholderColor};
462
632
  }
463
-
464
- &:focus {
465
- outline: 2px solid ${({theme:e})=>e.select.trigger.focus.outlineColor};
466
- outline-offset: 1px;
467
- }
468
- `,xo=O.div`
633
+ `,Mo=I.div`
469
634
  padding: 4px;
470
635
  overflow-y: auto;
471
636
  max-height: inherit;
472
- `,mo=O.div`
637
+ `,Ao=I.div`
473
638
  display: flex;
474
639
  align-items: center;
475
640
  justify-content: space-between;
@@ -481,25 +646,27 @@
481
646
  border-radius: 8px;
482
647
  cursor: pointer;
483
648
  transition: background-color 0.1s ease;
484
- color: ${({theme:e,$isSelected:t})=>t?e.select.option.selected.color:e.select.option.color};
485
- background-color: ${({theme:e,$isSelected:t,$isHighlighted:r})=>t?e.select.option.selected.backgroundColor:r?e.select.option.hover.backgroundColor:e.select.option.backgroundColor};
649
+ color: ${({theme:e})=>e.select.option.color};
650
+ background-color: ${({theme:e,$isHighlighted:t})=>t?e.select.option.hover.backgroundColor:e.select.option.backgroundColor};
486
651
 
487
652
  &:hover {
488
- background-color: ${({theme:e,$isSelected:t})=>t?e.select.option.selected.backgroundColor:e.select.option.hover.backgroundColor};
653
+ background-color: ${({theme:e})=>e.select.option.hover.backgroundColor};
489
654
  }
490
- `,Co=O.span`
655
+ `,Po=I.span`
491
656
  flex: 1;
492
657
  min-width: 0;
493
658
  overflow: hidden;
494
659
  text-overflow: ellipsis;
495
660
  white-space: nowrap;
496
- `,vo=O.span`
661
+ `,Do=I.span`
497
662
  display: flex;
498
663
  align-items: center;
499
664
  justify-content: center;
500
665
  margin-left: 8px;
501
666
  flex-shrink: 0;
502
- `,Sc=O.div`
667
+ color: ${({theme:e})=>e.select.option.check.color};
668
+ opacity: ${({$isSelected:e})=>e?1:.15};
669
+ `,da=I.div`
503
670
  display: flex;
504
671
  align-items: center;
505
672
  justify-content: center;
@@ -507,15 +674,15 @@
507
674
  font-size: 14px;
508
675
  font-weight: 400;
509
676
  color: ${({theme:e})=>e.select.empty.color};
510
- `,Ec=e=>`${e}-start`,Ic=({options:e,value:t,onChange:r,placement:o=un,searchable:n=!1,disabled:s=!1})=>{const[l,c]=X.useState(!1),[d,a]=X.useState(""),[u,g]=X.useState(null),f=X.useRef([]),p=X.useRef(null),x=X.useMemo(()=>e.find(b=>b.value===t),[e,t]),h=X.useMemo(()=>{if(!n||!d)return e;const b=d.toLowerCase();return e.filter(T=>T.label.toLowerCase().includes(b))},[e,d,n]),y=X.useRef(e.map(b=>b.label));y.current=h.map(b=>b.label);const m=X.useCallback(b=>{s||(c(b),b||(a(""),g(null)))},[s]),v=X.useMemo(()=>Ec(o),[o]),{refs:k,floatingStyles:R,context:I}=sn({open:l,onOpenChange:m,placement:v,middleware:[Qo(cc),en(),Jo({padding:8}),zl({apply({rects:b,elements:T}){Object.assign(T.floating.style,{width:`${b.reference.width}px`})}})],whileElementsMounted:Yo}),P=nn(I,{enabled:!s}),L=ln(I),j=hs(I,{role:"listbox"}),Z=fs(I,{listRef:f,activeIndex:u,onNavigate:g,virtual:!0,loop:!0}),$=ps(I,{listRef:y,activeIndex:u,onMatch:n?void 0:g,enabled:!n}),F=X.useCallback(b=>{r==null||r(b.value),c(!1),a(""),g(null)},[r]),{getReferenceProps:Y,getFloatingProps:U,getItemProps:S}=cn([P,L,j,Z,$]),E=X.useCallback(()=>{const b=Y(),T=b.onKeyDown;return{...b,onKeyDown:N=>{if(T==null||T(N),N.key==="Enter"&&l&&u!==null){N.preventDefault();const ne=h[u];ne&&F(ne)}}}},[Y,l,u,h,F]),_=X.useCallback(b=>{a(b.target.value),g(0)},[]),D=X.useCallback(b=>{if(b.key==="Enter"&&u!==null){b.preventDefault();const T=h[u];T&&F(T)}},[u,h,F]);return{isOpen:l,setIsOpen:m,selectedOption:x,filteredOptions:h,searchQuery:d,setSearchQuery:a,highlightedIndex:u,context:I,refs:{setReference:k.setReference,setFloating:k.setFloating},floatingStyles:R,getReferenceProps:E,getFloatingProps:U,getItemProps:b=>S({onClick:()=>{const T=h[b];T&&F(T)},onKeyDown:T=>{if(T.key==="Enter"){T.preventDefault();const N=h[b];N&&F(N)}}}),listRef:f,handleSelect:F,handleSearchChange:_,handleSearchKeyDown:D,searchInputRef:p}},Re=w.classNameGetter("select"),Oc=({options:e,value:t,onChange:r,placeholder:o=oc,searchPlaceholder:n=nc,emptyMessage:s=ic,label:l,icon:c,state:d,disabled:a,fullWidth:u,placement:g=un,maxHeight:f=lc,virtualized:p,searchable:x,portalRenderNode:h,className:y,classnames:m,...v})=>{const k=X.useRef(null),{isOpen:R,selectedOption:I,filteredOptions:P,searchQuery:L,context:j,refs:Z,floatingStyles:$,getReferenceProps:F,getFloatingProps:Y,getItemProps:U,listRef:S,handleSearchChange:E,handleSearchKeyDown:_,searchInputRef:D,highlightedIndex:b}=Ic({options:e,value:t,onChange:r,placement:g,searchable:x,disabled:a}),N=f-(x?56:0)-8,ne=rc({count:P.length,getScrollElement:()=>k.current,estimateSize:()=>sc,overscan:5,enabled:p}),be=()=>P.length===0?w.jsx(Sc,{className:Re("empty",m==null?void 0:m.empty),children:s}):p?w.jsx(xo,{ref:k,className:Re("list",m==null?void 0:m.list),style:{maxHeight:N,overflow:"auto"},children:w.jsx("div",{style:{height:ne.getTotalSize(),width:"100%",position:"relative"},children:ne.getVirtualItems().map(q=>{const H=P[q.index];if(!H)return null;const J=H.value===t;return w.jsxs(mo,{ref:de=>{S.current[q.index]=de},className:Re("option",m==null?void 0:m.option),$isSelected:J,$isHighlighted:b===q.index,style:{position:"absolute",top:0,left:0,width:"100%",height:q.size,transform:`translateY(${q.start}px)`},...U(q.index),children:[w.jsx(Co,{children:H.label}),J&&w.jsx(vo,{children:w.jsx(w.Check,{size:16})})]},H.value)})})}):w.jsx(xo,{ref:k,className:Re("list",m==null?void 0:m.list),style:{maxHeight:N},children:P.map((q,H)=>{const J=q.value===t;return w.jsxs(mo,{ref:de=>{S.current[H]=de},className:Re("option",m==null?void 0:m.option),$isSelected:J,$isHighlighted:b===H,...U(H),children:[w.jsx(Co,{children:q.label}),J&&w.jsx(vo,{children:w.jsx(w.Check,{size:16})})]},q.value)})}),V=()=>{if(!R)return null;const q=w.jsx(ls,{context:j,initialFocus:x?D:void 0,modal:!1,children:w.jsxs(yc,{ref:Z.setFloating,className:Re("content",m==null?void 0:m.content),style:$,$isOpen:R,$maxHeight:f,...Y(),children:[x&&w.jsx(kc,{className:Re("search",m==null?void 0:m.search),children:w.jsx(Rc,{ref:D,type:"text",placeholder:n,value:L,onChange:E,onKeyDown:_,onClick:H=>H.stopPropagation()})}),be()]})});return h?Ft.createPortal(q,h):q};return w.jsxs(bc,{...v,className:Re("container",y,m==null?void 0:m.container),$fullWidth:u,children:[l&&w.jsx(xc,{className:Re("label",m==null?void 0:m.label),$state:d,children:l}),w.jsxs(mc,{ref:Z.setReference,type:"button",className:Re("trigger",m==null?void 0:m.trigger),$state:d,$disabled:a,$isOpen:R,disabled:a,"aria-haspopup":"listbox","aria-expanded":R,...F(),children:[c&&w.jsx(Cc,{$state:d,$disabled:a,children:c}),w.jsx(vc,{$isPlaceholder:!I,$state:d,$disabled:a,children:I?I.label:o}),w.jsx(wc,{$state:d,$disabled:a,$isOpen:R,children:w.jsx(w.ChevronDown,{size:16})})]}),V()]})},Tc=(e,t,r)=>r?e.checkboxCard.container.disabled.backgroundColor:t?e.checkboxCard.container.checked.backgroundColor:e.checkboxCard.container.backgroundColor,$c=(e,t,r,o)=>o?e.checkboxCard.container.disabled.borderColor:t==="warning"?r?e.checkboxCard.state.warning.container.checked.borderColor:e.checkboxCard.state.warning.container.borderColor:t==="error"?r?e.checkboxCard.state.error.container.checked.borderColor:e.checkboxCard.state.error.container.borderColor:r?e.checkboxCard.container.checked.borderColor:e.checkboxCard.container.borderColor,Ac=(e,t,r)=>t==="warning"?r?e.checkboxCard.state.warning.container.checked.borderColor:e.checkboxCard.state.warning.container.borderColor:t==="error"?r?e.checkboxCard.state.error.container.checked.borderColor:e.checkboxCard.state.error.container.borderColor:r?e.checkboxCard.container.checked.borderColor:e.checkboxCard.container.hover.borderColor,Mc=(e,t)=>t==="warning"?e.checkboxCard.state.warning.container.borderColor:t==="error"?e.checkboxCard.state.error.container.borderColor:e.checkboxCard.container.focus.outlineColor,Pc=(e,t,r)=>t==="warning"?e.checkboxCard.state.warning.label.color:t==="error"?e.checkboxCard.state.error.label.color:e.checkboxCard.label.color,Dc=(e,t,r)=>t==="warning"?e.checkboxCard.state.warning.description.color:t==="error"?e.checkboxCard.state.error.description.color:e.checkboxCard.description.color,Lc=O.label`
677
+ `,fa=e=>`${e}-start`,ga=({options:e,value:t,onChange:r,placement:o=yn,searchable:i=!1,disabled:c=!1})=>{const[l,s]=_.useState(!1),[d,a]=_.useState(""),[u,h]=_.useState(null),f=_.useRef([]),b=_.useRef(null),C=_.useMemo(()=>e.find(x=>x.value===t),[e,t]),g=_.useMemo(()=>{if(!i||!d)return e;const x=d.toLowerCase();return e.filter(E=>E.label.toLowerCase().includes(x))},[e,d,i]),y=_.useRef(e.map(x=>x.label));y.current=g.map(x=>x.label);const p=_.useCallback(x=>{c||(s(x),x||(a(""),h(null)))},[c]),v=_.useMemo(()=>fa(o),[o]),{refs:k,floatingStyles:S,context:T}=Ar({open:l,onOpenChange:p,placement:v,middleware:[Sr(qs),Er(),Rr({padding:8}),fn({apply({rects:x,elements:E}){Object.assign(E.floating.style,{width:`${x.reference.width}px`})}})],whileElementsMounted:kr}),M=Or(T,{enabled:!c}),N=Mr(T),B=mn(T,{role:"listbox"}),X=xn(T,{listRef:f,activeIndex:u,onNavigate:h,virtual:!0,loop:!0}),O=kc(T,{listRef:y,activeIndex:u,onMatch:i?void 0:h,enabled:!i}),F=_.useCallback(x=>{r==null||r(x.value),s(!1),a(""),h(null)},[r]),{getReferenceProps:G,getFloatingProps:V,getItemProps:R}=Pr([M,N,B,X,O]),$=_.useCallback(()=>{const x=G(),E=x.onKeyDown;return{...x,onKeyDown:A=>{if(E==null||E(A),A.key==="Enter"&&l&&u!==null){A.preventDefault();const ee=g[u];ee&&F(ee)}}}},[G,l,u,g,F]),j=_.useCallback(x=>{a(x.target.value),h(0)},[]),L=_.useCallback(x=>{if(x.key==="Enter"&&u!==null){x.preventDefault();const E=g[u];E&&F(E)}},[u,g,F]);return{isOpen:l,setIsOpen:p,selectedOption:C,filteredOptions:g,searchQuery:d,setSearchQuery:a,highlightedIndex:u,context:T,refs:{setReference:k.setReference,setFloating:k.setFloating},floatingStyles:S,getReferenceProps:$,getFloatingProps:V,getItemProps:x=>R({onClick:()=>{const E=g[x];E&&F(E)},onKeyDown:E=>{if(E.key==="Enter"){E.preventDefault();const A=g[x];A&&F(A)}}}),listRef:f,handleSelect:F,handleSearchChange:j,handleSearchKeyDown:L,searchInputRef:b}},Ie=m.classNameGetter("select"),ha=({options:e,value:t,onChange:r,placeholder:o=Vs,searchPlaceholder:i=Hs,emptyMessage:c=Us,label:l,icon:s,state:d,disabled:a,fullWidth:u,placement:h=yn,maxHeight:f=Ks,virtualized:b,searchable:C,portalRenderNode:g,className:y,classnames:p,...v})=>{const k=_.useRef(null),{isOpen:S,selectedOption:T,filteredOptions:M,searchQuery:N,context:B,refs:X,floatingStyles:O,getReferenceProps:F,getFloatingProps:G,getItemProps:V,listRef:R,handleSearchChange:$,handleSearchKeyDown:j,searchInputRef:L,highlightedIndex:x}=ga({options:e,value:t,onChange:r,placement:h,searchable:C,disabled:a}),A=f-(C?56:0)-8,ee=vn({count:M.length,getScrollElement:()=>k.current,estimateSize:()=>Gs,overscan:5,enabled:b}),ue=()=>M.length===0?m.jsx(da,{className:Ie("empty",p==null?void 0:p.empty),children:c}):b?m.jsx(Mo,{ref:k,className:Ie("list",p==null?void 0:p.list),style:{maxHeight:A,overflow:"auto"},children:m.jsx("div",{style:{height:ee.getTotalSize(),width:"100%",position:"relative"},children:ee.getVirtualItems().map(Y=>{const H=M[Y.index];if(!H)return null;const te=H.value===t;return m.jsxs(Ao,{ref:q=>{R.current[Y.index]=q},className:Ie("option",p==null?void 0:p.option),$isHighlighted:x===Y.index,style:{position:"absolute",top:0,left:0,width:"100%",height:Y.size,transform:`translateY(${Y.start}px)`},...V(Y.index),children:[m.jsx(Po,{children:H.label}),m.jsx(Do,{$isSelected:te,children:m.jsx(m.Check,{size:16})})]},H.value)})})}):m.jsx(Mo,{ref:k,className:Ie("list",p==null?void 0:p.list),style:{maxHeight:A},children:M.map((Y,H)=>{const te=Y.value===t;return m.jsxs(Ao,{ref:q=>{R.current[H]=q},className:Ie("option",p==null?void 0:p.option),$isHighlighted:x===H,...V(H),children:[m.jsx(Po,{children:Y.label}),m.jsx(Do,{$isSelected:te,children:m.jsx(m.Check,{size:16})})]},Y.value)})}),z=()=>{if(!S)return null;const Y=m.jsx(bn,{context:B,initialFocus:C?L:void 0,modal:!1,children:m.jsxs(sa,{ref:X.setFloating,className:Ie("content",p==null?void 0:p.content),style:O,$isOpen:S,$maxHeight:f,...G(),children:[C&&m.jsx(aa,{className:Ie("search",p==null?void 0:p.search),children:m.jsx(ua,{ref:L,type:"text",placeholder:i,value:N,onChange:$,onKeyDown:j,onClick:H=>H.stopPropagation()})}),ue()]})});return g?ft.createPortal(Y,g):Y};return m.jsxs(ra,{...v,className:Ie("container",y,p==null?void 0:p.container),$fullWidth:u,children:[l&&m.jsx(oa,{className:Ie("label",p==null?void 0:p.label),$state:d,children:l}),m.jsxs(na,{ref:X.setReference,type:"button",className:Ie("trigger",p==null?void 0:p.trigger),$state:d,$disabled:a,$isOpen:S,disabled:a,"aria-haspopup":"listbox","aria-expanded":S,...F(),children:[s&&m.jsx(ia,{$state:d,$disabled:a,children:s}),m.jsx(la,{$isPlaceholder:!T,$state:d,$disabled:a,children:T?T.label:o}),m.jsx(ca,{$state:d,$disabled:a,$isOpen:S,children:m.jsx(m.ChevronDown,{size:16})})]}),z()]})},pa=(e,t,r)=>r?e.checkboxCard.container.disabled.backgroundColor:t?e.checkboxCard.container.checked.backgroundColor:e.checkboxCard.container.backgroundColor,ba=(e,t,r,o)=>o?e.checkboxCard.container.disabled.borderColor:t==="warning"?r?e.checkboxCard.state.warning.container.checked.borderColor:e.checkboxCard.state.warning.container.borderColor:t==="error"?r?e.checkboxCard.state.error.container.checked.borderColor:e.checkboxCard.state.error.container.borderColor:r?e.checkboxCard.container.checked.borderColor:e.checkboxCard.container.borderColor,xa=(e,t,r)=>t==="warning"?r?e.checkboxCard.state.warning.container.checked.borderColor:e.checkboxCard.state.warning.container.borderColor:t==="error"?r?e.checkboxCard.state.error.container.checked.borderColor:e.checkboxCard.state.error.container.borderColor:r?e.checkboxCard.container.checked.borderColor:e.checkboxCard.container.hover.borderColor,ma=(e,t)=>t==="warning"?e.checkboxCard.state.warning.container.borderColor:t==="error"?e.checkboxCard.state.error.container.borderColor:e.checkboxCard.container.focus.outlineColor,Ca=(e,t,r)=>t==="warning"?e.checkboxCard.state.warning.label.color:t==="error"?e.checkboxCard.state.error.label.color:e.checkboxCard.label.color,va=(e,t,r)=>t==="warning"?e.checkboxCard.state.warning.description.color:t==="error"?e.checkboxCard.state.error.description.color:e.checkboxCard.description.color,wa=I.label`
511
678
  display: grid;
512
679
  grid-template-columns: auto 1fr;
513
680
  align-items: start;
514
681
  gap: 12px;
515
682
  padding: 12px;
516
- background-color: ${({theme:e,$checked:t,$disabled:r})=>Tc(e,t,r)};
683
+ background-color: ${({theme:e,$checked:t,$disabled:r})=>pa(e,t,r)};
517
684
  border: 1px solid
518
- ${({theme:e,$state:t,$checked:r,$disabled:o})=>$c(e,t,r,o)};
685
+ ${({theme:e,$state:t,$checked:r,$disabled:o})=>ba(e,t,r,o)};
519
686
  border-radius: 12px;
520
687
  cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
521
688
  transition:
@@ -525,18 +692,18 @@
525
692
  min-width: 0;
526
693
 
527
694
  &:hover:not([data-disabled='true']) {
528
- border-color: ${({theme:e,$state:t,$checked:r})=>Ac(e,t,r)};
695
+ border-color: ${({theme:e,$state:t,$checked:r})=>xa(e,t,r)};
529
696
  }
530
697
 
531
698
  &:has(:focus-visible) {
532
- outline: 2px solid ${({theme:e,$state:t})=>Mc(e,t)};
699
+ outline: 2px solid ${({theme:e,$state:t})=>ma(e,t)};
533
700
  outline-offset: 1px;
534
701
  }
535
702
 
536
703
  .vacano_checkbox_container {
537
704
  pointer-events: none;
538
705
  }
539
- `,Nc=O.input`
706
+ `,ya=I.input`
540
707
  position: absolute;
541
708
  width: 1px;
542
709
  height: 1px;
@@ -546,37 +713,37 @@
546
713
  clip: rect(0, 0, 0, 0);
547
714
  white-space: nowrap;
548
715
  border: 0;
549
- `,Fc=O.div`
716
+ `,ka=I.div`
550
717
  display: flex;
551
718
  flex-direction: column;
552
719
  gap: 2px;
553
720
  min-width: 0;
554
- `,_c=O.span`
721
+ `,Sa=I.span`
555
722
  font-size: 14px;
556
723
  font-weight: 500;
557
724
  line-height: 1.4;
558
- color: ${({theme:e,$state:t})=>Pc(e,t)};
725
+ color: ${({theme:e,$state:t})=>Ca(e,t)};
559
726
 
560
727
  label[data-disabled='true'] & {
561
728
  color: ${({theme:e})=>e.checkboxCard.label.disabled.color};
562
729
  }
563
- `,jc=O.span`
730
+ `,Ra=I.span`
564
731
  font-size: 12px;
565
732
  font-weight: 400;
566
733
  line-height: 1.4;
567
- color: ${({theme:e,$state:t})=>Dc(e,t)};
734
+ color: ${({theme:e,$state:t})=>va(e,t)};
568
735
 
569
736
  label[data-disabled='true'] & {
570
737
  color: ${({theme:e})=>e.checkboxCard.description.disabled.color};
571
738
  }
572
- `,yt=w.classNameGetter("checkboxCard"),zc=({checked:e,className:t,classnames:r,description:o,disabled:n,fullWidth:s,label:l,onChange:c,ref:d,state:a,...u})=>w.jsxs(Lc,{className:yt("container",t,r==null?void 0:r.container),$checked:e,$disabled:n,$fullWidth:s,$state:a,"data-disabled":n,children:[w.jsx(Nc,{...u,ref:d,type:"checkbox",checked:e,disabled:n,onChange:c}),w.jsx(br,{className:r==null?void 0:r.checkbox,checked:e,disabled:n,state:a,onChange:()=>{},tabIndex:-1,"aria-hidden":!0}),w.jsxs(Fc,{className:yt("content",r==null?void 0:r.content),children:[w.jsx(_c,{className:yt("label",r==null?void 0:r.label),$state:a,children:l}),o&&w.jsx(jc,{className:yt("description",r==null?void 0:r.description),$state:a,children:o})]})]}),Bc=O.div`
739
+ `,Et=m.classNameGetter("checkboxCard"),Ea=({checked:e,className:t,classnames:r,description:o,disabled:i,fullWidth:c,label:l,onChange:s,ref:d,state:a,...u})=>m.jsxs(wa,{className:Et("container",t,r==null?void 0:r.container),$checked:e,$disabled:i,$fullWidth:c,$state:a,"data-disabled":i,children:[m.jsx(ya,{...u,ref:d,type:"checkbox",checked:e,disabled:i,onChange:s}),m.jsx(mr,{className:r==null?void 0:r.checkbox,checked:e,disabled:i,state:a,onChange:()=>{},tabIndex:-1,"aria-hidden":!0}),m.jsxs(ka,{className:Et("content",r==null?void 0:r.content),children:[m.jsx(Sa,{className:Et("label",r==null?void 0:r.label),$state:a,children:l}),o&&m.jsx(Ra,{className:Et("description",r==null?void 0:r.description),$state:a,children:o})]})]}),$a=I.div`
573
740
  display: flex;
574
741
  flex-direction: column;
575
742
  gap: 8px;
576
743
  border: none;
577
744
  margin: 0;
578
745
  padding: 0;
579
- `,Wc=O.span`
746
+ `,Ia=I.span`
580
747
  font-size: 13px;
581
748
  font-weight: 500;
582
749
  line-height: 1.5;
@@ -584,19 +751,19 @@
584
751
  color: ${({theme:e})=>e.checkboxGroup.label.color};
585
752
  margin-bottom: 4px;
586
753
  padding: 0;
587
- `,Vc=O.div`
754
+ `,Ta=I.div`
588
755
  display: flex;
589
756
  flex-direction: column;
590
757
  gap: 12px;
591
- `,ir=w.classNameGetter("checkboxGroup"),Hc=({className:e,classnames:t,disabled:r,label:o,onChange:n,options:s,value:l,...c})=>{const d=(a,u)=>{n(u?[...l,a]:l.filter(g=>g!==a))};return w.jsxs(Bc,{...c,className:ir("container",e,t==null?void 0:t.container),children:[o&&w.jsx(Wc,{className:ir("label",t==null?void 0:t.label),children:o}),w.jsx(Vc,{className:ir("options",t==null?void 0:t.options),children:s.map(a=>w.jsx(br,{className:t==null?void 0:t.checkbox,checked:l.includes(a.value),label:a.label,disabled:r,onChange:u=>d(a.value,u.target.checked)},a.value))})]})},Uc=(e,t,r)=>r?e.radioCard.container.disabled.backgroundColor:t?e.radioCard.container.checked.backgroundColor:e.radioCard.container.backgroundColor,Gc=(e,t,r,o)=>o?e.radioCard.container.disabled.borderColor:t==="warning"?r?e.radioCard.state.warning.container.checked.borderColor:e.radioCard.state.warning.container.borderColor:t==="error"?r?e.radioCard.state.error.container.checked.borderColor:e.radioCard.state.error.container.borderColor:r?e.radioCard.container.checked.borderColor:e.radioCard.container.borderColor,Kc=(e,t,r)=>t==="warning"?r?e.radioCard.state.warning.container.checked.borderColor:e.radioCard.state.warning.container.borderColor:t==="error"?r?e.radioCard.state.error.container.checked.borderColor:e.radioCard.state.error.container.borderColor:r?e.radioCard.container.checked.borderColor:e.radioCard.container.hover.borderColor,qc=(e,t)=>t==="warning"?e.radioCard.state.warning.container.borderColor:t==="error"?e.radioCard.state.error.container.borderColor:e.radioCard.container.focus.outlineColor,Xc=(e,t,r)=>t==="warning"?e.radioCard.state.warning.label.color:t==="error"?e.radioCard.state.error.label.color:e.radioCard.label.color,Yc=(e,t,r)=>t==="warning"?e.radioCard.state.warning.description.color:t==="error"?e.radioCard.state.error.description.color:e.radioCard.description.color,Zc=O.label`
758
+ `,cr=m.classNameGetter("checkboxGroup"),Oa=({className:e,classnames:t,disabled:r,label:o,onChange:i,options:c,value:l,...s})=>{const d=(a,u)=>{i(u?[...l,a]:l.filter(h=>h!==a))};return m.jsxs($a,{...s,className:cr("container",e,t==null?void 0:t.container),children:[o&&m.jsx(Ia,{className:cr("label",t==null?void 0:t.label),children:o}),m.jsx(Ta,{className:cr("options",t==null?void 0:t.options),children:c.map(a=>m.jsx(mr,{className:t==null?void 0:t.checkbox,checked:l.includes(a.value),label:a.label,disabled:r,onChange:u=>d(a.value,u.target.checked)},a.value))})]})},Ma=(e,t,r)=>r?e.radioCard.container.disabled.backgroundColor:t?e.radioCard.container.checked.backgroundColor:e.radioCard.container.backgroundColor,Aa=(e,t,r,o)=>o?e.radioCard.container.disabled.borderColor:t==="warning"?r?e.radioCard.state.warning.container.checked.borderColor:e.radioCard.state.warning.container.borderColor:t==="error"?r?e.radioCard.state.error.container.checked.borderColor:e.radioCard.state.error.container.borderColor:r?e.radioCard.container.checked.borderColor:e.radioCard.container.borderColor,Pa=(e,t,r)=>t==="warning"?r?e.radioCard.state.warning.container.checked.borderColor:e.radioCard.state.warning.container.borderColor:t==="error"?r?e.radioCard.state.error.container.checked.borderColor:e.radioCard.state.error.container.borderColor:r?e.radioCard.container.checked.borderColor:e.radioCard.container.hover.borderColor,Da=(e,t)=>t==="warning"?e.radioCard.state.warning.container.borderColor:t==="error"?e.radioCard.state.error.container.borderColor:e.radioCard.container.focus.outlineColor,La=(e,t,r)=>t==="warning"?e.radioCard.state.warning.label.color:t==="error"?e.radioCard.state.error.label.color:e.radioCard.label.color,Na=(e,t,r)=>t==="warning"?e.radioCard.state.warning.description.color:t==="error"?e.radioCard.state.error.description.color:e.radioCard.description.color,Fa=I.label`
592
759
  display: grid;
593
760
  grid-template-columns: auto 1fr;
594
761
  align-items: start;
595
762
  gap: 12px;
596
763
  padding: 12px;
597
- background-color: ${({theme:e,$checked:t,$disabled:r})=>Uc(e,t,r)};
764
+ background-color: ${({theme:e,$checked:t,$disabled:r})=>Ma(e,t,r)};
598
765
  border: 1px solid
599
- ${({theme:e,$state:t,$checked:r,$disabled:o})=>Gc(e,t,r,o)};
766
+ ${({theme:e,$state:t,$checked:r,$disabled:o})=>Aa(e,t,r,o)};
600
767
  border-radius: 12px;
601
768
  cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
602
769
  transition:
@@ -606,18 +773,18 @@
606
773
  min-width: 0;
607
774
 
608
775
  &:hover:not([data-disabled='true']) {
609
- border-color: ${({theme:e,$state:t,$checked:r})=>Kc(e,t,r)};
776
+ border-color: ${({theme:e,$state:t,$checked:r})=>Pa(e,t,r)};
610
777
  }
611
778
 
612
779
  &:has(:focus-visible) {
613
- outline: 2px solid ${({theme:e,$state:t})=>qc(e,t)};
780
+ outline: 2px solid ${({theme:e,$state:t})=>Da(e,t)};
614
781
  outline-offset: 1px;
615
782
  }
616
783
 
617
784
  .vacano_radio_container {
618
785
  pointer-events: none;
619
786
  }
620
- `,Qc=O.input`
787
+ `,_a=I.input`
621
788
  position: absolute;
622
789
  width: 1px;
623
790
  height: 1px;
@@ -627,48 +794,48 @@
627
794
  clip: rect(0, 0, 0, 0);
628
795
  white-space: nowrap;
629
796
  border: 0;
630
- `,Jc=O.div`
797
+ `,ja=I.div`
631
798
  display: flex;
632
799
  flex-direction: column;
633
800
  gap: 2px;
634
801
  min-width: 0;
635
- `,ea=O.span`
802
+ `,Ba=I.span`
636
803
  font-size: 14px;
637
804
  font-weight: 500;
638
805
  line-height: 1.4;
639
- color: ${({theme:e,$state:t})=>Xc(e,t)};
806
+ color: ${({theme:e,$state:t})=>La(e,t)};
640
807
 
641
808
  label[data-disabled='true'] & {
642
809
  color: ${({theme:e})=>e.radioCard.label.disabled.color};
643
810
  }
644
- `,ta=O.span`
811
+ `,za=I.span`
645
812
  font-size: 12px;
646
813
  font-weight: 400;
647
814
  line-height: 1.4;
648
- color: ${({theme:e,$state:t})=>Yc(e,t)};
815
+ color: ${({theme:e,$state:t})=>Na(e,t)};
649
816
 
650
817
  label[data-disabled='true'] & {
651
818
  color: ${({theme:e})=>e.radioCard.description.disabled.color};
652
819
  }
653
- `,kt=w.classNameGetter("radioCard"),ra=({checked:e,className:t,classnames:r,description:o,disabled:n,fullWidth:s,label:l,onChange:c,ref:d,state:a,...u})=>w.jsxs(Zc,{className:kt("container",t,r==null?void 0:r.container),$checked:e,$disabled:n,$fullWidth:s,$state:a,"data-disabled":n,children:[w.jsx(Qc,{...u,ref:d,type:"radio",checked:e,disabled:n,onChange:c}),w.jsx(Rr,{className:r==null?void 0:r.radio,checked:e,disabled:n,state:a,onChange:()=>{},tabIndex:-1,"aria-hidden":!0}),w.jsxs(Jc,{className:kt("content",r==null?void 0:r.content),children:[w.jsx(ea,{className:kt("label",r==null?void 0:r.label),$state:a,children:l}),o&&w.jsx(ta,{className:kt("description",r==null?void 0:r.description),$state:a,children:o})]})]}),oa=O.div`
820
+ `,$t=m.classNameGetter("radioCard"),Wa=({checked:e,className:t,classnames:r,description:o,disabled:i,fullWidth:c,label:l,onChange:s,ref:d,state:a,...u})=>m.jsxs(Fa,{className:$t("container",t,r==null?void 0:r.container),$checked:e,$disabled:i,$fullWidth:c,$state:a,"data-disabled":i,children:[m.jsx(_a,{...u,ref:d,type:"radio",checked:e,disabled:i,onChange:s}),m.jsx(Dr,{className:r==null?void 0:r.radio,checked:e,disabled:i,state:a,onChange:()=>{},tabIndex:-1,"aria-hidden":!0}),m.jsxs(ja,{className:$t("content",r==null?void 0:r.content),children:[m.jsx(Ba,{className:$t("label",r==null?void 0:r.label),$state:a,children:l}),o&&m.jsx(za,{className:$t("description",r==null?void 0:r.description),$state:a,children:o})]})]}),Va=I.div`
654
821
  display: flex;
655
822
  flex-direction: column;
656
823
  gap: 8px;
657
824
  border: none;
658
825
  margin: 0;
659
826
  padding: 0;
660
- `,na=O.span`
827
+ `,Ha=I.span`
661
828
  font-size: 13px;
662
829
  font-weight: 500;
663
830
  line-height: 1.5;
664
831
  color: ${({theme:e})=>e.radioGroup.label.color};
665
832
  margin-bottom: 4px;
666
833
  padding: 0;
667
- `,ia=O.div`
834
+ `,Ua=I.div`
668
835
  display: flex;
669
836
  flex-direction: column;
670
837
  gap: 12px;
671
- `,lr=w.classNameGetter("radioGroup"),la=({className:e,classnames:t,disabled:r,label:o,name:n,onChange:s,options:l,value:c,...d})=>w.jsxs(oa,{...d,className:lr("container",e,t==null?void 0:t.container),children:[o&&w.jsx(na,{className:lr("label",t==null?void 0:t.label),children:o}),w.jsx(ia,{className:lr("options",t==null?void 0:t.options),children:l.map(a=>w.jsx(Rr,{className:t==null?void 0:t.radio,name:n,checked:c===a.value,label:a.label,disabled:r,onChange:()=>s(a.value)},a.value))})]}),i={black:"#000000",white:"#ffffff",onyx:"#111111",carbonBlack:"#232323",graphite:"#343434",slate:"#484848",ash:"#6b6b6b",silver:"#8c8c8c",mist:"#b0b0b0",cloud:"#d4d4d4",snow:"#ebebeb",icyBlue:"#bde0fe",blue:"#0050c8",green:"#009650",amber:"#b48200",red:"#c83232",grey:"#646464",blueBg:"#0064ff1a",greenBg:"#00c8641a",amberBg:"#ffb4001a",redBg:"#ff50501a",greyBg:"#0000000d",hoverLight:"#00000008",activeLight:"#00000012",hoverDark:"#ffffff12",activeDark:"#ffffff20",redLight:"#c8323214",redMedium:"#c8323228",focusRingDark:"#00000080",focusRingDarkSubtle:"#00000040",focusRingLight:"#ffffff80",focusRingLightSubtle:"#ffffff40",focusRingDanger:"#c8323280",focusRingWarning:"#b4820040",focusRingError:"#c8323240",inputBgLight:"#00000008",inputBgDark:"#ffffff0d",inputBgWarning:"#ffb4001a",inputBgError:"#ff50501a"},Lt={xl:"0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1)"},Nt={chip:{color:{default:i.grey,neutral:i.blue,success:i.green,warning:i.amber,error:i.red},backgroundColor:{default:i.greyBg,neutral:i.blueBg,success:i.greenBg,warning:i.amberBg,error:i.redBg}},button:{primary:{color:i.white,backgroundColor:i.onyx,borderColor:i.onyx,hover:{backgroundColor:i.carbonBlack,borderColor:i.carbonBlack},active:{backgroundColor:i.graphite,borderColor:i.graphite},focus:{outlineColor:i.focusRingDark},disabled:{color:i.silver,backgroundColor:i.snow,borderColor:i.snow},char:{color:i.snow,backgroundColor:i.slate},icon:{color:i.white}},secondary:{color:i.onyx,backgroundColor:i.snow,borderColor:i.cloud,hover:{backgroundColor:i.cloud,borderColor:i.mist},active:{backgroundColor:i.cloud,borderColor:i.silver},focus:{outlineColor:i.focusRingDarkSubtle},disabled:{color:i.silver,backgroundColor:i.snow,borderColor:i.snow},char:{color:i.slate,backgroundColor:i.mist},icon:{color:i.slate}},ghost:{color:i.onyx,backgroundColor:"transparent",borderColor:"transparent",hover:{backgroundColor:i.hoverLight,borderColor:"transparent"},active:{backgroundColor:i.activeLight,borderColor:"transparent"},focus:{outlineColor:i.focusRingDarkSubtle},disabled:{color:i.silver,backgroundColor:"transparent",borderColor:"transparent"},char:{color:i.ash,backgroundColor:i.snow},icon:{color:i.slate}},danger:{color:i.red,backgroundColor:"transparent",borderColor:i.redLight,hover:{backgroundColor:i.redLight,borderColor:i.redLight},active:{backgroundColor:i.redMedium,borderColor:i.redMedium},focus:{outlineColor:i.focusRingDanger},disabled:{color:i.mist,backgroundColor:i.snow,borderColor:i.snow},char:{color:i.red,backgroundColor:i.redLight},icon:{color:i.red}}},checkbox:{box:{backgroundColor:"transparent",borderColor:i.mist,checked:{backgroundColor:i.onyx,borderColor:i.onyx},focus:{shadowColor:i.focusRingDarkSubtle}},icon:{color:i.white},label:{color:i.onyx},state:{warning:{box:{borderColor:i.amber,checked:{backgroundColor:i.amber,borderColor:i.amber},focus:{shadowColor:i.focusRingWarning}},label:{color:i.amber}},error:{box:{borderColor:i.red,checked:{backgroundColor:i.red,borderColor:i.red},focus:{shadowColor:i.focusRingError}},label:{color:i.red}}}},checkboxCard:{container:{backgroundColor:i.white,borderColor:i.mist,hover:{borderColor:i.silver},checked:{backgroundColor:i.white,borderColor:i.onyx},focus:{outlineColor:i.focusRingDarkSubtle},disabled:{backgroundColor:i.snow,borderColor:i.cloud}},label:{color:i.onyx,disabled:{color:i.silver}},description:{color:i.slate,disabled:{color:i.silver}},state:{warning:{container:{borderColor:i.amber,checked:{borderColor:i.amber}},label:{color:i.amber},description:{color:i.amber}},error:{container:{borderColor:i.red,checked:{borderColor:i.red}},label:{color:i.red},description:{color:i.red}}}},checkboxGroup:{label:{color:i.onyx}},input:{wrapper:{backgroundColor:i.inputBgLight,borderColor:i.mist,focus:{outlineColor:i.focusRingDarkSubtle},disabled:{backgroundColor:i.snow,borderColor:i.cloud}},label:{color:i.slate},input:{color:i.onyx,placeholderColor:i.silver,disabled:{color:i.silver}},icon:{color:i.slate,disabled:{color:i.silver}},toggle:{color:i.slate},state:{warning:{wrapper:{backgroundColor:i.inputBgWarning,borderColor:i.amber,focus:{outlineColor:i.focusRingWarning}},label:{color:i.amber},input:{color:i.onyx,placeholderColor:i.amber},icon:{color:i.amber}},error:{wrapper:{backgroundColor:i.inputBgError,borderColor:i.red,focus:{outlineColor:i.focusRingError}},label:{color:i.red},input:{color:i.onyx,placeholderColor:i.red},icon:{color:i.red}}}},radio:{circle:{borderColor:i.mist,checked:{borderColor:i.onyx},focus:{shadowColor:i.focusRingDarkSubtle}},dot:{color:i.onyx},label:{color:i.onyx},state:{warning:{circle:{borderColor:i.amber,checked:{borderColor:i.amber},focus:{shadowColor:i.focusRingWarning}},dot:{color:i.amber},label:{color:i.amber}},error:{circle:{borderColor:i.red,checked:{borderColor:i.red},focus:{shadowColor:i.focusRingError}},dot:{color:i.red},label:{color:i.red}}}},radioCard:{container:{backgroundColor:i.white,borderColor:i.mist,hover:{borderColor:i.silver},checked:{backgroundColor:i.white,borderColor:i.onyx},focus:{outlineColor:i.focusRingDarkSubtle},disabled:{backgroundColor:i.snow,borderColor:i.cloud}},label:{color:i.onyx,disabled:{color:i.silver}},description:{color:i.slate,disabled:{color:i.silver}},state:{warning:{container:{borderColor:i.amber,checked:{borderColor:i.amber}},label:{color:i.amber},description:{color:i.amber}},error:{container:{borderColor:i.red,checked:{borderColor:i.red}},label:{color:i.red},description:{color:i.red}}}},radioGroup:{label:{color:i.onyx}},dropdown:{content:{backgroundColor:i.white,borderColor:i.cloud,shadow:Lt.xl}},select:{trigger:{backgroundColor:i.inputBgLight,borderColor:i.mist,focus:{outlineColor:i.focusRingDarkSubtle},disabled:{backgroundColor:i.snow,borderColor:i.cloud}},label:{color:i.slate},value:{color:i.onyx,placeholderColor:i.silver,disabled:{color:i.silver}},icon:{color:i.slate,disabled:{color:i.silver}},chevron:{color:i.slate,disabled:{color:i.silver}},content:{backgroundColor:i.white,borderColor:i.cloud,shadow:Lt.xl},option:{color:i.onyx,backgroundColor:"transparent",hover:{backgroundColor:i.hoverLight},selected:{backgroundColor:i.blueBg,color:i.blue}},search:{backgroundColor:i.snow,borderColor:i.cloud,color:i.onyx,placeholderColor:i.silver},empty:{color:i.silver},state:{warning:{trigger:{backgroundColor:i.inputBgWarning,borderColor:i.amber,focus:{outlineColor:i.focusRingWarning}},label:{color:i.amber},value:{color:i.onyx,placeholderColor:i.amber},icon:{color:i.amber},chevron:{color:i.amber}},error:{trigger:{backgroundColor:i.inputBgError,borderColor:i.red,focus:{outlineColor:i.focusRingError}},label:{color:i.red},value:{color:i.onyx,placeholderColor:i.red},icon:{color:i.red},chevron:{color:i.red}}}}},dn={chip:{color:{default:i.icyBlue,neutral:i.icyBlue,success:i.green,warning:i.amber,error:i.red},backgroundColor:{default:i.graphite,neutral:i.graphite,success:i.greenBg,warning:i.amberBg,error:i.redBg}},button:{primary:{color:i.black,backgroundColor:i.white,borderColor:i.white,hover:{backgroundColor:i.cloud,borderColor:i.cloud},active:{backgroundColor:i.mist,borderColor:i.mist},focus:{outlineColor:i.focusRingLight},disabled:{color:i.ash,backgroundColor:i.graphite,borderColor:i.graphite},char:{color:i.slate,backgroundColor:i.cloud},icon:{color:i.black}},secondary:{color:i.white,backgroundColor:i.graphite,borderColor:i.slate,hover:{backgroundColor:i.slate,borderColor:i.ash},active:{backgroundColor:i.ash,borderColor:i.silver},focus:{outlineColor:i.focusRingLightSubtle},disabled:{color:i.ash,backgroundColor:i.carbonBlack,borderColor:i.carbonBlack},char:{color:i.mist,backgroundColor:i.slate},icon:{color:i.cloud}},ghost:{color:i.white,backgroundColor:"transparent",borderColor:"transparent",hover:{backgroundColor:i.hoverDark,borderColor:"transparent"},active:{backgroundColor:i.activeDark,borderColor:"transparent"},focus:{outlineColor:i.focusRingLightSubtle},disabled:{color:i.ash,backgroundColor:"transparent",borderColor:"transparent"},char:{color:i.mist,backgroundColor:i.graphite},icon:{color:i.cloud}},danger:{color:i.red,backgroundColor:"transparent",borderColor:i.redLight,hover:{backgroundColor:i.redLight,borderColor:i.redLight},active:{backgroundColor:i.redMedium,borderColor:i.redMedium},focus:{outlineColor:i.focusRingDanger},disabled:{color:i.ash,backgroundColor:i.carbonBlack,borderColor:i.carbonBlack},char:{color:i.red,backgroundColor:i.redLight},icon:{color:i.red}}},checkbox:{box:{backgroundColor:"transparent",borderColor:i.ash,checked:{backgroundColor:i.white,borderColor:i.white},focus:{shadowColor:i.focusRingLightSubtle}},icon:{color:i.black},label:{color:i.white},state:{warning:{box:{borderColor:i.amber,checked:{backgroundColor:i.amber,borderColor:i.amber},focus:{shadowColor:i.focusRingWarning}},label:{color:i.amber}},error:{box:{borderColor:i.red,checked:{backgroundColor:i.red,borderColor:i.red},focus:{shadowColor:i.focusRingError}},label:{color:i.red}}}},checkboxCard:{container:{backgroundColor:i.graphite,borderColor:i.slate,hover:{borderColor:i.ash},checked:{backgroundColor:i.graphite,borderColor:i.white},focus:{outlineColor:i.focusRingLightSubtle},disabled:{backgroundColor:i.carbonBlack,borderColor:i.slate}},label:{color:i.white,disabled:{color:i.ash}},description:{color:i.cloud,disabled:{color:i.ash}},state:{warning:{container:{borderColor:i.amber,checked:{borderColor:i.amber}},label:{color:i.amber},description:{color:i.amber}},error:{container:{borderColor:i.red,checked:{borderColor:i.red}},label:{color:i.red},description:{color:i.red}}}},checkboxGroup:{label:{color:i.white}},input:{wrapper:{backgroundColor:i.inputBgDark,borderColor:i.slate,focus:{outlineColor:i.focusRingLightSubtle},disabled:{backgroundColor:i.graphite,borderColor:i.slate}},label:{color:i.cloud},input:{color:i.white,placeholderColor:i.ash,disabled:{color:i.ash}},icon:{color:i.cloud,disabled:{color:i.ash}},toggle:{color:i.cloud},state:{warning:{wrapper:{backgroundColor:i.inputBgWarning,borderColor:i.amber,focus:{outlineColor:i.focusRingWarning}},label:{color:i.amber},input:{color:i.white,placeholderColor:i.amber},icon:{color:i.amber}},error:{wrapper:{backgroundColor:i.inputBgError,borderColor:i.red,focus:{outlineColor:i.focusRingError}},label:{color:i.red},input:{color:i.white,placeholderColor:i.red},icon:{color:i.red}}}},radio:{circle:{borderColor:i.ash,checked:{borderColor:i.white},focus:{shadowColor:i.focusRingLightSubtle}},dot:{color:i.white},label:{color:i.white},state:{warning:{circle:{borderColor:i.amber,checked:{borderColor:i.amber},focus:{shadowColor:i.focusRingWarning}},dot:{color:i.amber},label:{color:i.amber}},error:{circle:{borderColor:i.red,checked:{borderColor:i.red},focus:{shadowColor:i.focusRingError}},dot:{color:i.red},label:{color:i.red}}}},radioCard:{container:{backgroundColor:i.graphite,borderColor:i.slate,hover:{borderColor:i.ash},checked:{backgroundColor:i.graphite,borderColor:i.white},focus:{outlineColor:i.focusRingLightSubtle},disabled:{backgroundColor:i.carbonBlack,borderColor:i.slate}},label:{color:i.white,disabled:{color:i.ash}},description:{color:i.cloud,disabled:{color:i.ash}},state:{warning:{container:{borderColor:i.amber,checked:{borderColor:i.amber}},label:{color:i.amber},description:{color:i.amber}},error:{container:{borderColor:i.red,checked:{borderColor:i.red}},label:{color:i.red},description:{color:i.red}}}},radioGroup:{label:{color:i.white}},dropdown:{content:{backgroundColor:i.graphite,borderColor:i.slate,shadow:Lt.xl}},select:{trigger:{backgroundColor:i.inputBgDark,borderColor:i.slate,focus:{outlineColor:i.focusRingLightSubtle},disabled:{backgroundColor:i.graphite,borderColor:i.slate}},label:{color:i.cloud},value:{color:i.white,placeholderColor:i.ash,disabled:{color:i.ash}},icon:{color:i.cloud,disabled:{color:i.ash}},chevron:{color:i.cloud,disabled:{color:i.ash}},content:{backgroundColor:i.graphite,borderColor:i.slate,shadow:Lt.xl},option:{color:i.white,backgroundColor:"transparent",hover:{backgroundColor:i.hoverDark},selected:{backgroundColor:i.blueBg,color:i.blue}},search:{backgroundColor:i.carbonBlack,borderColor:i.slate,color:i.white,placeholderColor:i.ash},empty:{color:i.ash},state:{warning:{trigger:{backgroundColor:i.inputBgWarning,borderColor:i.amber,focus:{outlineColor:i.focusRingWarning}},label:{color:i.amber},value:{color:i.white,placeholderColor:i.amber},icon:{color:i.amber},chevron:{color:i.amber}},error:{trigger:{backgroundColor:i.inputBgError,borderColor:i.red,focus:{outlineColor:i.focusRingError}},label:{color:i.red},value:{color:i.white,placeholderColor:i.red},icon:{color:i.red},chevron:{color:i.red}}}}},fn=X.createContext({mode:"light",theme:Nt,setMode:()=>{}}),sa=()=>{const e=X.useContext(fn);if(!e)throw new Error("useTheme must be used within a ThemeProvider");return e},ca=He.css`
838
+ `,sr=m.classNameGetter("radioGroup"),Ka=({className:e,classnames:t,disabled:r,label:o,name:i,onChange:c,options:l,value:s,...d})=>m.jsxs(Va,{...d,className:sr("container",e,t==null?void 0:t.container),children:[o&&m.jsx(Ha,{className:sr("label",t==null?void 0:t.label),children:o}),m.jsx(Ua,{className:sr("options",t==null?void 0:t.options),children:l.map(a=>m.jsx(Dr,{className:t==null?void 0:t.radio,name:i,checked:s===a.value,label:a.label,disabled:r,onChange:()=>c(a.value)},a.value))})]}),n={black:"#000000",white:"#ffffff",onyx:"#111111",carbonBlack:"#232323",graphite:"#343434",slate:"#484848",ash:"#6b6b6b",silver:"#8c8c8c",mist:"#b0b0b0",cloud:"#d4d4d4",snow:"#ebebeb",icyBlue:"#bde0fe",blue:"#0050c8",green:"#009650",amber:"#b48200",red:"#c83232",grey:"#646464",blueBg:"#0064ff1a",greenBg:"#00c8641a",amberBg:"#ffb4001a",redBg:"#ff50501a",greyBg:"#0000000d",hoverLight:"#00000008",activeLight:"#00000012",hoverDark:"#ffffff12",activeDark:"#ffffff20",redLight:"#c8323214",redMedium:"#c8323228",focusRingDark:"#00000080",focusRingDarkSubtle:"#00000040",focusRingLight:"#ffffff80",focusRingLightSubtle:"#ffffff40",focusRingDanger:"#c8323280",focusRingWarning:"#b4820040",focusRingError:"#c8323240",inputBgLight:"#00000008",inputBgDark:"#ffffff0d",inputBgWarning:"#ffb4001a",inputBgError:"#ff50501a"},Ge={none:"none",sm:"0 1px 2px 0 rgb(0 0 0 / 0.05)",md:"0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1)",lg:"0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1)",xl:"0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1)",xl2:"0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1)",xl3:"0 25px 50px -12px rgb(0 0 0 / 0.25)",inner:"inset 0 2px 4px 0 rgb(0 0 0 / 0.05)"},Je={sm:640,md:768,lg:1024,xl:1280,xl2:1536},Ga={sm:`@media (min-width: ${Je.sm}px)`,md:`@media (min-width: ${Je.md}px)`,lg:`@media (min-width: ${Je.lg}px)`,xl:`@media (min-width: ${Je.xl}px)`,xl2:`@media (min-width: ${Je.xl2}px)`},jt={chip:{color:{default:n.grey,neutral:n.blue,success:n.green,warning:n.amber,error:n.red},backgroundColor:{default:n.greyBg,neutral:n.blueBg,success:n.greenBg,warning:n.amberBg,error:n.redBg}},button:{primary:{color:n.white,backgroundColor:n.onyx,borderColor:n.onyx,hover:{backgroundColor:n.carbonBlack,borderColor:n.carbonBlack},active:{backgroundColor:n.graphite,borderColor:n.graphite},focus:{outlineColor:n.focusRingDark},disabled:{color:n.silver,backgroundColor:n.snow,borderColor:n.snow},char:{color:n.snow,backgroundColor:n.slate},icon:{color:n.white}},secondary:{color:n.onyx,backgroundColor:n.snow,borderColor:n.cloud,hover:{backgroundColor:n.cloud,borderColor:n.mist},active:{backgroundColor:n.cloud,borderColor:n.silver},focus:{outlineColor:n.focusRingDarkSubtle},disabled:{color:n.silver,backgroundColor:n.snow,borderColor:n.snow},char:{color:n.slate,backgroundColor:n.mist},icon:{color:n.slate}},ghost:{color:n.onyx,backgroundColor:"transparent",borderColor:"transparent",hover:{backgroundColor:n.hoverLight,borderColor:"transparent"},active:{backgroundColor:n.activeLight,borderColor:"transparent"},focus:{outlineColor:n.focusRingDarkSubtle},disabled:{color:n.silver,backgroundColor:"transparent",borderColor:"transparent"},char:{color:n.ash,backgroundColor:n.snow},icon:{color:n.slate}},danger:{color:n.red,backgroundColor:"transparent",borderColor:n.redLight,hover:{backgroundColor:n.redLight,borderColor:n.redLight},active:{backgroundColor:n.redMedium,borderColor:n.redMedium},focus:{outlineColor:n.focusRingDanger},disabled:{color:n.mist,backgroundColor:n.snow,borderColor:n.snow},char:{color:n.red,backgroundColor:n.redLight},icon:{color:n.red}}},checkbox:{box:{backgroundColor:"transparent",borderColor:n.mist,checked:{backgroundColor:n.onyx,borderColor:n.onyx},focus:{shadowColor:n.focusRingDarkSubtle}},icon:{color:n.white},label:{color:n.onyx},state:{warning:{box:{borderColor:n.amber,checked:{backgroundColor:n.amber,borderColor:n.amber},focus:{shadowColor:n.focusRingWarning}},label:{color:n.amber}},error:{box:{borderColor:n.red,checked:{backgroundColor:n.red,borderColor:n.red},focus:{shadowColor:n.focusRingError}},label:{color:n.red}}}},checkboxCard:{container:{backgroundColor:n.white,borderColor:n.mist,hover:{borderColor:n.silver},checked:{backgroundColor:n.white,borderColor:n.onyx},focus:{outlineColor:n.focusRingDarkSubtle},disabled:{backgroundColor:n.snow,borderColor:n.cloud}},label:{color:n.onyx,disabled:{color:n.silver}},description:{color:n.slate,disabled:{color:n.silver}},state:{warning:{container:{borderColor:n.amber,checked:{borderColor:n.amber}},label:{color:n.amber},description:{color:n.amber}},error:{container:{borderColor:n.red,checked:{borderColor:n.red}},label:{color:n.red},description:{color:n.red}}}},checkboxGroup:{label:{color:n.onyx}},input:{wrapper:{backgroundColor:n.inputBgLight,borderColor:n.mist,focus:{outlineColor:n.focusRingDarkSubtle},disabled:{backgroundColor:n.snow,borderColor:n.cloud}},label:{color:n.slate},input:{color:n.onyx,placeholderColor:n.silver,disabled:{color:n.silver}},icon:{color:n.slate,disabled:{color:n.silver}},toggle:{color:n.slate},state:{warning:{wrapper:{backgroundColor:n.inputBgWarning,borderColor:n.amber,focus:{outlineColor:n.focusRingWarning}},label:{color:n.amber},input:{color:n.onyx,placeholderColor:n.amber},icon:{color:n.amber}},error:{wrapper:{backgroundColor:n.inputBgError,borderColor:n.red,focus:{outlineColor:n.focusRingError}},label:{color:n.red},input:{color:n.onyx,placeholderColor:n.red},icon:{color:n.red}}}},radio:{circle:{borderColor:n.mist,checked:{borderColor:n.onyx},focus:{shadowColor:n.focusRingDarkSubtle}},dot:{color:n.onyx},label:{color:n.onyx},state:{warning:{circle:{borderColor:n.amber,checked:{borderColor:n.amber},focus:{shadowColor:n.focusRingWarning}},dot:{color:n.amber},label:{color:n.amber}},error:{circle:{borderColor:n.red,checked:{borderColor:n.red},focus:{shadowColor:n.focusRingError}},dot:{color:n.red},label:{color:n.red}}}},radioCard:{container:{backgroundColor:n.white,borderColor:n.mist,hover:{borderColor:n.silver},checked:{backgroundColor:n.white,borderColor:n.onyx},focus:{outlineColor:n.focusRingDarkSubtle},disabled:{backgroundColor:n.snow,borderColor:n.cloud}},label:{color:n.onyx,disabled:{color:n.silver}},description:{color:n.slate,disabled:{color:n.silver}},state:{warning:{container:{borderColor:n.amber,checked:{borderColor:n.amber}},label:{color:n.amber},description:{color:n.amber}},error:{container:{borderColor:n.red,checked:{borderColor:n.red}},label:{color:n.red},description:{color:n.red}}}},radioGroup:{label:{color:n.onyx}},dropdown:{content:{backgroundColor:n.white,borderColor:n.cloud,shadow:Ge.xl}},select:{trigger:{backgroundColor:n.inputBgLight,borderColor:n.mist,focus:{outlineColor:n.focusRingDarkSubtle},disabled:{backgroundColor:n.snow,borderColor:n.cloud}},label:{color:n.slate},value:{color:n.onyx,placeholderColor:n.silver,disabled:{color:n.silver}},icon:{color:n.slate,disabled:{color:n.silver}},chevron:{color:n.slate,disabled:{color:n.silver}},content:{backgroundColor:n.white,borderColor:n.cloud,shadow:Ge.xl},option:{color:n.onyx,backgroundColor:"transparent",hover:{backgroundColor:n.hoverLight},selected:{backgroundColor:n.blueBg,color:n.blue},check:{color:n.blue}},search:{backgroundColor:n.snow,borderColor:n.cloud,color:n.onyx,placeholderColor:n.silver},empty:{color:n.silver},state:{warning:{trigger:{backgroundColor:n.inputBgWarning,borderColor:n.amber,focus:{outlineColor:n.focusRingWarning}},label:{color:n.amber},value:{color:n.onyx,placeholderColor:n.amber},icon:{color:n.amber},chevron:{color:n.amber}},error:{trigger:{backgroundColor:n.inputBgError,borderColor:n.red,focus:{outlineColor:n.focusRingError}},label:{color:n.red},value:{color:n.onyx,placeholderColor:n.red},icon:{color:n.red},chevron:{color:n.red}}}},multiSelect:{trigger:{backgroundColor:n.inputBgLight,borderColor:n.mist,focus:{outlineColor:n.focusRingDarkSubtle},disabled:{backgroundColor:n.snow,borderColor:n.cloud}},label:{color:n.slate},placeholder:{color:n.silver,disabled:{color:n.silver}},chip:{backgroundColor:n.snow,color:n.onyx,remove:{color:n.slate,hover:{color:n.onyx}},disabled:{backgroundColor:n.cloud,color:n.silver,remove:{color:n.silver}}},icon:{color:n.slate,disabled:{color:n.silver}},chevron:{color:n.slate,disabled:{color:n.silver}},content:{backgroundColor:n.white,borderColor:n.cloud,shadow:Ge.xl},option:{color:n.onyx,backgroundColor:"transparent",hover:{backgroundColor:n.hoverLight},selected:{backgroundColor:n.blueBg,color:n.blue},check:{color:n.blue}},search:{backgroundColor:n.snow,borderColor:n.cloud,color:n.onyx,placeholderColor:n.silver},empty:{color:n.silver},state:{warning:{trigger:{backgroundColor:n.inputBgWarning,borderColor:n.amber,focus:{outlineColor:n.focusRingWarning}},label:{color:n.amber},chip:{backgroundColor:n.amberBg,color:n.amber,remove:{color:n.amber}},icon:{color:n.amber},chevron:{color:n.amber}},error:{trigger:{backgroundColor:n.inputBgError,borderColor:n.red,focus:{outlineColor:n.focusRingError}},label:{color:n.red},chip:{backgroundColor:n.redBg,color:n.red,remove:{color:n.red}},icon:{color:n.red},chevron:{color:n.red}}}}},kn={chip:{color:{default:n.icyBlue,neutral:n.icyBlue,success:n.green,warning:n.amber,error:n.red},backgroundColor:{default:n.graphite,neutral:n.graphite,success:n.greenBg,warning:n.amberBg,error:n.redBg}},button:{primary:{color:n.black,backgroundColor:n.white,borderColor:n.white,hover:{backgroundColor:n.cloud,borderColor:n.cloud},active:{backgroundColor:n.mist,borderColor:n.mist},focus:{outlineColor:n.focusRingLight},disabled:{color:n.ash,backgroundColor:n.graphite,borderColor:n.graphite},char:{color:n.slate,backgroundColor:n.cloud},icon:{color:n.black}},secondary:{color:n.white,backgroundColor:n.graphite,borderColor:n.slate,hover:{backgroundColor:n.slate,borderColor:n.ash},active:{backgroundColor:n.ash,borderColor:n.silver},focus:{outlineColor:n.focusRingLightSubtle},disabled:{color:n.ash,backgroundColor:n.carbonBlack,borderColor:n.carbonBlack},char:{color:n.mist,backgroundColor:n.slate},icon:{color:n.cloud}},ghost:{color:n.white,backgroundColor:"transparent",borderColor:"transparent",hover:{backgroundColor:n.hoverDark,borderColor:"transparent"},active:{backgroundColor:n.activeDark,borderColor:"transparent"},focus:{outlineColor:n.focusRingLightSubtle},disabled:{color:n.ash,backgroundColor:"transparent",borderColor:"transparent"},char:{color:n.mist,backgroundColor:n.graphite},icon:{color:n.cloud}},danger:{color:n.red,backgroundColor:"transparent",borderColor:n.redLight,hover:{backgroundColor:n.redLight,borderColor:n.redLight},active:{backgroundColor:n.redMedium,borderColor:n.redMedium},focus:{outlineColor:n.focusRingDanger},disabled:{color:n.ash,backgroundColor:n.carbonBlack,borderColor:n.carbonBlack},char:{color:n.red,backgroundColor:n.redLight},icon:{color:n.red}}},checkbox:{box:{backgroundColor:"transparent",borderColor:n.ash,checked:{backgroundColor:n.white,borderColor:n.white},focus:{shadowColor:n.focusRingLightSubtle}},icon:{color:n.black},label:{color:n.white},state:{warning:{box:{borderColor:n.amber,checked:{backgroundColor:n.amber,borderColor:n.amber},focus:{shadowColor:n.focusRingWarning}},label:{color:n.amber}},error:{box:{borderColor:n.red,checked:{backgroundColor:n.red,borderColor:n.red},focus:{shadowColor:n.focusRingError}},label:{color:n.red}}}},checkboxCard:{container:{backgroundColor:n.graphite,borderColor:n.slate,hover:{borderColor:n.ash},checked:{backgroundColor:n.graphite,borderColor:n.white},focus:{outlineColor:n.focusRingLightSubtle},disabled:{backgroundColor:n.carbonBlack,borderColor:n.slate}},label:{color:n.white,disabled:{color:n.ash}},description:{color:n.cloud,disabled:{color:n.ash}},state:{warning:{container:{borderColor:n.amber,checked:{borderColor:n.amber}},label:{color:n.amber},description:{color:n.amber}},error:{container:{borderColor:n.red,checked:{borderColor:n.red}},label:{color:n.red},description:{color:n.red}}}},checkboxGroup:{label:{color:n.white}},input:{wrapper:{backgroundColor:n.inputBgDark,borderColor:n.slate,focus:{outlineColor:n.focusRingLightSubtle},disabled:{backgroundColor:n.graphite,borderColor:n.slate}},label:{color:n.cloud},input:{color:n.white,placeholderColor:n.ash,disabled:{color:n.ash}},icon:{color:n.cloud,disabled:{color:n.ash}},toggle:{color:n.cloud},state:{warning:{wrapper:{backgroundColor:n.inputBgWarning,borderColor:n.amber,focus:{outlineColor:n.focusRingWarning}},label:{color:n.amber},input:{color:n.white,placeholderColor:n.amber},icon:{color:n.amber}},error:{wrapper:{backgroundColor:n.inputBgError,borderColor:n.red,focus:{outlineColor:n.focusRingError}},label:{color:n.red},input:{color:n.white,placeholderColor:n.red},icon:{color:n.red}}}},radio:{circle:{borderColor:n.ash,checked:{borderColor:n.white},focus:{shadowColor:n.focusRingLightSubtle}},dot:{color:n.white},label:{color:n.white},state:{warning:{circle:{borderColor:n.amber,checked:{borderColor:n.amber},focus:{shadowColor:n.focusRingWarning}},dot:{color:n.amber},label:{color:n.amber}},error:{circle:{borderColor:n.red,checked:{borderColor:n.red},focus:{shadowColor:n.focusRingError}},dot:{color:n.red},label:{color:n.red}}}},radioCard:{container:{backgroundColor:n.graphite,borderColor:n.slate,hover:{borderColor:n.ash},checked:{backgroundColor:n.graphite,borderColor:n.white},focus:{outlineColor:n.focusRingLightSubtle},disabled:{backgroundColor:n.carbonBlack,borderColor:n.slate}},label:{color:n.white,disabled:{color:n.ash}},description:{color:n.cloud,disabled:{color:n.ash}},state:{warning:{container:{borderColor:n.amber,checked:{borderColor:n.amber}},label:{color:n.amber},description:{color:n.amber}},error:{container:{borderColor:n.red,checked:{borderColor:n.red}},label:{color:n.red},description:{color:n.red}}}},radioGroup:{label:{color:n.white}},dropdown:{content:{backgroundColor:n.graphite,borderColor:n.slate,shadow:Ge.xl}},select:{trigger:{backgroundColor:n.inputBgDark,borderColor:n.slate,focus:{outlineColor:n.focusRingLightSubtle},disabled:{backgroundColor:n.graphite,borderColor:n.slate}},label:{color:n.cloud},value:{color:n.white,placeholderColor:n.ash,disabled:{color:n.ash}},icon:{color:n.cloud,disabled:{color:n.ash}},chevron:{color:n.cloud,disabled:{color:n.ash}},content:{backgroundColor:n.graphite,borderColor:n.slate,shadow:Ge.xl},option:{color:n.white,backgroundColor:"transparent",hover:{backgroundColor:n.hoverDark},selected:{backgroundColor:n.blueBg,color:n.blue},check:{color:n.blue}},search:{backgroundColor:n.carbonBlack,borderColor:n.slate,color:n.white,placeholderColor:n.ash},empty:{color:n.ash},state:{warning:{trigger:{backgroundColor:n.inputBgWarning,borderColor:n.amber,focus:{outlineColor:n.focusRingWarning}},label:{color:n.amber},value:{color:n.white,placeholderColor:n.amber},icon:{color:n.amber},chevron:{color:n.amber}},error:{trigger:{backgroundColor:n.inputBgError,borderColor:n.red,focus:{outlineColor:n.focusRingError}},label:{color:n.red},value:{color:n.white,placeholderColor:n.red},icon:{color:n.red},chevron:{color:n.red}}}},multiSelect:{trigger:{backgroundColor:n.inputBgDark,borderColor:n.slate,focus:{outlineColor:n.focusRingLightSubtle},disabled:{backgroundColor:n.graphite,borderColor:n.slate}},label:{color:n.cloud},placeholder:{color:n.ash,disabled:{color:n.ash}},chip:{backgroundColor:n.slate,color:n.white,remove:{color:n.cloud,hover:{color:n.white}},disabled:{backgroundColor:n.graphite,color:n.ash,remove:{color:n.ash}}},icon:{color:n.cloud,disabled:{color:n.ash}},chevron:{color:n.cloud,disabled:{color:n.ash}},content:{backgroundColor:n.graphite,borderColor:n.slate,shadow:Ge.xl},option:{color:n.white,backgroundColor:"transparent",hover:{backgroundColor:n.hoverDark},selected:{backgroundColor:n.blueBg,color:n.blue},check:{color:n.blue}},search:{backgroundColor:n.carbonBlack,borderColor:n.slate,color:n.white,placeholderColor:n.ash},empty:{color:n.ash},state:{warning:{trigger:{backgroundColor:n.inputBgWarning,borderColor:n.amber,focus:{outlineColor:n.focusRingWarning}},label:{color:n.amber},chip:{backgroundColor:n.amberBg,color:n.amber,remove:{color:n.amber}},icon:{color:n.amber},chevron:{color:n.amber}},error:{trigger:{backgroundColor:n.inputBgError,borderColor:n.red,focus:{outlineColor:n.focusRingError}},label:{color:n.red},chip:{backgroundColor:n.redBg,color:n.red,remove:{color:n.red}},icon:{color:n.red},chevron:{color:n.red}}}}},Sn=_.createContext({mode:"light",theme:jt,setMode:()=>{}}),qa=()=>{const e=_.useContext(Sn);if(!e)throw new Error("useTheme must be used within a ThemeProvider");return e},Xa=qe.css`
672
839
  *,
673
840
  *::before,
674
841
  *::after {
@@ -751,5 +918,5 @@
751
918
  border-collapse: collapse;
752
919
  border-spacing: 0;
753
920
  }
754
- `,gn=()=>w.jsx(He.Global,{styles:ca});function aa({children:e,defaultMode:t="light"}){const[r,o]=X.useState(t),n=X.useMemo(()=>{switch(r){case"light":return Nt;case"dark":return dn;default:return Nt}},[r]),s=X.useMemo(()=>({theme:n,mode:r,setMode:o}),[n,r]);return w.jsx(fn,{value:s,children:w.jsxs(He.ThemeProvider,{theme:n,children:[w.jsx(gn,{}),e]})})}exports.Button=Bn;exports.Checkbox=br;exports.CheckboxCard=zc;exports.CheckboxGroup=Hc;exports.Chip=ti;exports.Dropdown=ms;exports.GlobalStyle=gn;exports.Input=Ls;exports.Loader=yo;exports.Radio=Rr;exports.RadioCard=ra;exports.RadioGroup=la;exports.Select=Oc;exports.Spinner=ko;exports.ThemeProvider=aa;exports.themeDark=dn;exports.themeLight=Nt;exports.useTheme=sa;
921
+ `,Rn=()=>m.jsx(qe.Global,{styles:Xa});function Ya({children:e,defaultMode:t="light"}){const[r,o]=_.useState(t),i=_.useMemo(()=>{switch(r){case"light":return jt;case"dark":return kn;default:return jt}},[r]),c=_.useMemo(()=>({theme:i,mode:r,setMode:o}),[i,r]);return m.jsx(Sn,{value:c,children:m.jsxs(qe.ThemeProvider,{theme:i,children:[m.jsx(Rn,{}),e]})})}exports.Button=Jn;exports.Checkbox=mr;exports.CheckboxCard=Ea;exports.CheckboxGroup=Oa;exports.Chip=gi;exports.Dropdown=Ec;exports.GlobalStyle=Rn;exports.Input=Vc;exports.Loader=No;exports.MultiSelect=Ps;exports.Radio=Dr;exports.RadioCard=Wa;exports.RadioGroup=Ka;exports.Select=ha;exports.Spinner=Fo;exports.ThemeProvider=Ya;exports.breakpoints=Je;exports.colors=n;exports.media=Ga;exports.shadows=Ge;exports.themeDark=kn;exports.themeLight=jt;exports.useTheme=qa;
755
922
  //# sourceMappingURL=index.cjs.map