@mesh.ai/rabbit 0.0.42 → 0.0.43

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.
@@ -1,5 +1,5 @@
1
- (function(ve,L){typeof exports=="object"&&typeof module<"u"?L(exports,require("react/jsx-runtime"),require("react"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react","react-dom"],L):(ve=typeof globalThis<"u"?globalThis:ve||self,L((ve["@mesh"]=ve["@mesh"]||{},ve["@mesh"]["ai/rabbit"]={}),ve["react/jsx-runtime"],ve.React,ve.ReactDOM))})(this,function(ve,L,u,At){"use strict";function Oc(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const me=Oc(u),Ng=Oc(At),U3="";function ee(){return ee=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ee.apply(this,arguments)}function Ag(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function yo(...e){return t=>e.forEach(n=>Ag(n,t))}function Oe(...e){return u.useCallback(yo(...e),e)}function Ct(e,t=[]){let n=[];function r(i,a){const s=u.createContext(a),l=n.length;n=[...n,a];function c(f){const{scope:p,children:m,...h}=f,v=(p==null?void 0:p[e][l])||s,x=u.useMemo(()=>h,Object.values(h));return u.createElement(v.Provider,{value:x},m)}function d(f,p){const m=(p==null?void 0:p[e][l])||s,h=u.useContext(m);if(h)return h;if(a!==void 0)return a;throw new Error(`\`${f}\` must be used within \`${i}\``)}return c.displayName=i+"Provider",[c,d]}const o=()=>{const i=n.map(a=>u.createContext(a));return function(s){const l=(s==null?void 0:s[e])||i;return u.useMemo(()=>({[`__scope${e}`]:{...s,[e]:l}}),[s,l])}};return o.scopeName=e,[r,Dg(o,...t)]}function Dg(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(i){const a=r.reduce((s,{useScope:l,scopeName:c})=>{const f=l(i)[`__scope${c}`];return{...s,...f}},{});return u.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function fe(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e==null||e(o),n===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}function He(e){const t=u.useRef(e);return u.useEffect(()=>{t.current=e}),u.useMemo(()=>(...n)=>{var r;return(r=t.current)===null||r===void 0?void 0:r.call(t,...n)},[])}function St({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=Ig({defaultProp:t,onChange:n}),i=e!==void 0,a=i?e:r,s=He(n),l=u.useCallback(c=>{if(i){const f=typeof c=="function"?c(e):c;f!==e&&s(f)}else o(c)},[i,e,o,s]);return[a,l]}function Ig({defaultProp:e,onChange:t}){const n=u.useState(e),[r]=n,o=u.useRef(r),i=He(t);return u.useEffect(()=>{o.current!==r&&(i(r),o.current=r)},[r,o,i]),n}function _c(e){const t=u.useRef({value:e,previous:e});return u.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}const ot=globalThis!=null&&globalThis.document?u.useLayoutEffect:()=>{};function ua(e){const[t,n]=u.useState(void 0);return ot(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const i=o[0];let a,s;if("borderBoxSize"in i){const l=i.borderBoxSize,c=Array.isArray(l)?l[0]:l;a=c.inlineSize,s=c.blockSize}else a=e.offsetWidth,s=e.offsetHeight;n({width:a,height:s})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}function Lg(e,t){return u.useReducer((n,r)=>{const o=t[n][r];return o??n},e)}const Zt=e=>{const{present:t,children:n}=e,r=Fg(t),o=typeof n=="function"?n({present:r.isPresent}):u.Children.only(n),i=Oe(r.ref,o.ref);return typeof n=="function"||r.isPresent?u.cloneElement(o,{ref:i}):null};Zt.displayName="Presence";function Fg(e){const[t,n]=u.useState(),r=u.useRef({}),o=u.useRef(e),i=u.useRef("none"),a=e?"mounted":"unmounted",[s,l]=Lg(a,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return u.useEffect(()=>{const c=bo(r.current);i.current=s==="mounted"?c:"none"},[s]),ot(()=>{const c=r.current,d=o.current;if(d!==e){const p=i.current,m=bo(c);e?l("MOUNT"):m==="none"||(c==null?void 0:c.display)==="none"?l("UNMOUNT"):l(d&&p!==m?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,l]),ot(()=>{if(t){const c=f=>{const m=bo(r.current).includes(f.animationName);f.target===t&&m&&At.flushSync(()=>l("ANIMATION_END"))},d=f=>{f.target===t&&(i.current=bo(r.current))};return t.addEventListener("animationstart",d),t.addEventListener("animationcancel",c),t.addEventListener("animationend",c),()=>{t.removeEventListener("animationstart",d),t.removeEventListener("animationcancel",c),t.removeEventListener("animationend",c)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:u.useCallback(c=>{c&&(r.current=getComputedStyle(c)),n(c)},[])}}function bo(e){return(e==null?void 0:e.animationName)||"none"}const yn=u.forwardRef((e,t)=>{const{children:n,...r}=e,o=u.Children.toArray(n),i=o.find(jg);if(i){const a=i.props.children,s=o.map(l=>l===i?u.Children.count(a)>1?u.Children.only(null):u.isValidElement(a)?a.props.children:null:l);return u.createElement(da,ee({},r,{ref:t}),u.isValidElement(a)?u.cloneElement(a,void 0,s):null)}return u.createElement(da,ee({},r,{ref:t}),n)});yn.displayName="Slot";const da=u.forwardRef((e,t)=>{const{children:n,...r}=e;return u.isValidElement(n)?u.cloneElement(n,{...zg(r,n.props),ref:t?yo(t,n.ref):n.ref}):u.Children.count(n)>1?u.Children.only(null):null});da.displayName="SlotClone";const Nc=({children:e})=>u.createElement(u.Fragment,null,e);function jg(e){return u.isValidElement(e)&&e.type===Nc}function zg(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...s)=>{i(...s),o(...s)}:o&&(n[r]=o):r==="style"?n[r]={...o,...i}:r==="className"&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}const we=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce((e,t)=>{const n=u.forwardRef((r,o)=>{const{asChild:i,...a}=r,s=i?yn:t;return u.useEffect(()=>{window[Symbol.for("radix-ui")]=!0},[]),u.createElement(s,ee({},a,{ref:o}))});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function fa(e,t){e&&At.flushSync(()=>e.dispatchEvent(t))}const Ac="Checkbox",[Wg,G3]=Ct(Ac),[Bg,Ug]=Wg(Ac),Hg=u.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:r,checked:o,defaultChecked:i,required:a,disabled:s,value:l="on",onCheckedChange:c,...d}=e,[f,p]=u.useState(null),m=Oe(t,$=>p($)),h=u.useRef(!1),v=f?!!f.closest("form"):!0,[x=!1,y]=St({prop:o,defaultProp:i,onChange:c}),b=u.useRef(x);return u.useEffect(()=>{const $=f==null?void 0:f.form;if($){const S=()=>y(b.current);return $.addEventListener("reset",S),()=>$.removeEventListener("reset",S)}},[f,y]),u.createElement(Bg,{scope:n,state:x,disabled:s},u.createElement(we.button,ee({type:"button",role:"checkbox","aria-checked":bn(x)?"mixed":x,"aria-required":a,"data-state":Dc(x),"data-disabled":s?"":void 0,disabled:s,value:l},d,{ref:m,onKeyDown:fe(e.onKeyDown,$=>{$.key==="Enter"&&$.preventDefault()}),onClick:fe(e.onClick,$=>{y(S=>bn(S)?!0:!S),v&&(h.current=$.isPropagationStopped(),h.current||$.stopPropagation())})})),v&&u.createElement(qg,{control:f,bubbles:!h.current,name:r,value:l,checked:x,required:a,disabled:s,style:{transform:"translateX(-100%)"}}))}),Gg="CheckboxIndicator",Vg=u.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...o}=e,i=Ug(Gg,n);return u.createElement(Zt,{present:r||bn(i.state)||i.state===!0},u.createElement(we.span,ee({"data-state":Dc(i.state),"data-disabled":i.disabled?"":void 0},o,{ref:t,style:{pointerEvents:"none",...e.style}})))}),qg=e=>{const{control:t,checked:n,bubbles:r=!0,...o}=e,i=u.useRef(null),a=_c(n),s=ua(t);return u.useEffect(()=>{const l=i.current,c=window.HTMLInputElement.prototype,f=Object.getOwnPropertyDescriptor(c,"checked").set;if(a!==n&&f){const p=new Event("click",{bubbles:r});l.indeterminate=bn(n),f.call(l,bn(n)?!1:n),l.dispatchEvent(p)}},[a,n,r]),u.createElement("input",ee({type:"checkbox","aria-hidden":!0,defaultChecked:bn(n)?!1:n},o,{tabIndex:-1,ref:i,style:{...e.style,...s,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function bn(e){return e==="indeterminate"}function Dc(e){return bn(e)?"indeterminate":e?"checked":"unchecked"}const Ic=Hg,Yg=Vg;var Kg={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const Xg=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),xo=(e,t)=>{const n=u.forwardRef(({color:r="currentColor",size:o=24,strokeWidth:i=2,absoluteStrokeWidth:a,children:s,...l},c)=>u.createElement("svg",{ref:c,...Kg,width:o,height:o,stroke:r,strokeWidth:a?Number(i)*24/Number(o):i,className:`lucide lucide-${Xg(e)}`,...l},[...t.map(([d,f])=>u.createElement(d,f)),...(Array.isArray(s)?s:[s])||[]]));return n.displayName=`${e}`,n},pa=xo("Check",[["polyline",{points:"20 6 9 17 4 12",key:"10jjfj"}]]),Rg=xo("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),Zg=xo("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]),Qg=xo("Circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);function Lc(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=Lc(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function Fc(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=Lc(e))&&(r&&(r+=" "),r+=t);return r}function Jg(){for(var e=0,t,n,r="";e<arguments.length;)(t=arguments[e++])&&(n=jc(t))&&(r&&(r+=" "),r+=n);return r}function jc(e){if(typeof e=="string")return e;for(var t,n="",r=0;r<e.length;r++)e[r]&&(t=jc(e[r]))&&(n&&(n+=" "),n+=t);return n}var ha="-";function e0(e){var t=n0(e),n=e.conflictingClassGroups,r=e.conflictingClassGroupModifiers,o=r===void 0?{}:r;function i(s){var l=s.split(ha);return l[0]===""&&l.length!==1&&l.shift(),zc(l,t)||t0(s)}function a(s,l){var c=n[s]||[];return l&&o[s]?[].concat(c,o[s]):c}return{getClassGroupId:i,getConflictingClassGroupIds:a}}function zc(e,t){var a;if(e.length===0)return t.classGroupId;var n=e[0],r=t.nextPart.get(n),o=r?zc(e.slice(1),r):void 0;if(o)return o;if(t.validators.length!==0){var i=e.join(ha);return(a=t.validators.find(function(s){var l=s.validator;return l(i)}))==null?void 0:a.classGroupId}}var Wc=/^\[(.+)\]$/;function t0(e){if(Wc.test(e)){var t=Wc.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}}function n0(e){var t=e.theme,n=e.prefix,r={nextPart:new Map,validators:[]},o=o0(Object.entries(e.classGroups),n);return o.forEach(function(i){var a=i[0],s=i[1];ma(s,r,a,t)}),r}function ma(e,t,n,r){e.forEach(function(o){if(typeof o=="string"){var i=o===""?t:Bc(t,o);i.classGroupId=n;return}if(typeof o=="function"){if(r0(o)){ma(o(r),t,n,r);return}t.validators.push({validator:o,classGroupId:n});return}Object.entries(o).forEach(function(a){var s=a[0],l=a[1];ma(l,Bc(t,s),n,r)})})}function Bc(e,t){var n=e;return t.split(ha).forEach(function(r){n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n}function r0(e){return e.isThemeGetter}function o0(e,t){return t?e.map(function(n){var r=n[0],o=n[1],i=o.map(function(a){return typeof a=="string"?t+a:typeof a=="object"?Object.fromEntries(Object.entries(a).map(function(s){var l=s[0],c=s[1];return[t+l,c]})):a});return[r,i]}):e}function i0(e){if(e<1)return{get:function(){},set:function(){}};var t=0,n=new Map,r=new Map;function o(i,a){n.set(i,a),t++,t>e&&(t=0,r=n,n=new Map)}return{get:function(a){var s=n.get(a);if(s!==void 0)return s;if((s=r.get(a))!==void 0)return o(a,s),s},set:function(a,s){n.has(a)?n.set(a,s):o(a,s)}}}var Uc="!";function a0(e){var t=e.separator||":",n=t.length===1,r=t[0],o=t.length;return function(a){for(var s=[],l=0,c=0,d,f=0;f<a.length;f++){var p=a[f];if(l===0){if(p===r&&(n||a.slice(f,f+o)===t)){s.push(a.slice(c,f)),c=f+o;continue}if(p==="/"){d=f;continue}}p==="["?l++:p==="]"&&l--}var m=s.length===0?a:a.substring(c),h=m.startsWith(Uc),v=h?m.substring(1):m,x=d&&d>c?d-c:void 0;return{modifiers:s,hasImportantModifier:h,baseClassName:v,maybePostfixModifierPosition:x}}}function s0(e){if(e.length<=1)return e;var t=[],n=[];return e.forEach(function(r){var o=r[0]==="[";o?(t.push.apply(t,n.sort().concat([r])),n=[]):n.push(r)}),t.push.apply(t,n.sort()),t}function l0(e){return{cache:i0(e.cacheSize),splitModifiers:a0(e),...e0(e)}}var c0=/\s+/;function u0(e,t){var n=t.splitModifiers,r=t.getClassGroupId,o=t.getConflictingClassGroupIds,i=new Set;return e.trim().split(c0).map(function(a){var s=n(a),l=s.modifiers,c=s.hasImportantModifier,d=s.baseClassName,f=s.maybePostfixModifierPosition,p=r(f?d.substring(0,f):d),m=!!f;if(!p){if(!f)return{isTailwindClass:!1,originalClassName:a};if(p=r(d),!p)return{isTailwindClass:!1,originalClassName:a};m=!1}var h=s0(l).join(":"),v=c?h+Uc:h;return{isTailwindClass:!0,modifierId:v,classGroupId:p,originalClassName:a,hasPostfixModifier:m}}).reverse().filter(function(a){if(!a.isTailwindClass)return!0;var s=a.modifierId,l=a.classGroupId,c=a.hasPostfixModifier,d=s+l;return i.has(d)?!1:(i.add(d),o(l,c).forEach(function(f){return i.add(s+f)}),!0)}).reverse().map(function(a){return a.originalClassName}).join(" ")}function d0(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r,o,i,a=s;function s(c){var d=t[0],f=t.slice(1),p=f.reduce(function(m,h){return h(m)},d());return r=l0(p),o=r.cache.get,i=r.cache.set,a=l,l(c)}function l(c){var d=o(c);if(d)return d;var f=u0(c,r);return i(c,f),f}return function(){return a(Jg.apply(null,arguments))}}function Ae(e){var t=function(r){return r[e]||[]};return t.isThemeGetter=!0,t}var Hc=/^\[(?:([a-z-]+):)?(.+)\]$/i,f0=/^\d+\/\d+$/,p0=new Set(["px","full","screen"]),h0=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,m0=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,v0=/^-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/;function ht(e){return xn(e)||p0.has(e)||f0.test(e)||va(e)}function va(e){return wn(e,"length",$0)}function g0(e){return wn(e,"size",Gc)}function y0(e){return wn(e,"position",Gc)}function b0(e){return wn(e,"url",C0)}function wo(e){return wn(e,"number",xn)}function xn(e){return!Number.isNaN(Number(e))}function x0(e){return e.endsWith("%")&&xn(e.slice(0,-1))}function Cr(e){return Vc(e)||wn(e,"number",Vc)}function xe(e){return Hc.test(e)}function Sr(){return!0}function Qt(e){return h0.test(e)}function w0(e){return wn(e,"",S0)}function wn(e,t,n){var r=Hc.exec(e);return r?r[1]?r[1]===t:n(r[2]):!1}function $0(e){return m0.test(e)}function Gc(){return!1}function C0(e){return e.startsWith("url(")}function Vc(e){return Number.isInteger(Number(e))}function S0(e){return v0.test(e)}function E0(){var e=Ae("colors"),t=Ae("spacing"),n=Ae("blur"),r=Ae("brightness"),o=Ae("borderColor"),i=Ae("borderRadius"),a=Ae("borderSpacing"),s=Ae("borderWidth"),l=Ae("contrast"),c=Ae("grayscale"),d=Ae("hueRotate"),f=Ae("invert"),p=Ae("gap"),m=Ae("gradientColorStops"),h=Ae("gradientColorStopPositions"),v=Ae("inset"),x=Ae("margin"),y=Ae("opacity"),b=Ae("padding"),$=Ae("saturate"),S=Ae("scale"),w=Ae("sepia"),T=Ae("skew"),O=Ae("space"),P=Ae("translate"),_=function(){return["auto","contain","none"]},j=function(){return["auto","hidden","clip","visible","scroll"]},F=function(){return["auto",xe,t]},V=function(){return[xe,t]},R=function(){return["",ht]},X=function(){return["auto",xn,xe]},C=function(){return["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"]},I=function(){return["solid","dashed","dotted","double","none"]},H=function(){return["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-lighter"]},B=function(){return["start","end","center","between","around","evenly","stretch"]},A=function(){return["","0",xe]},N=function(){return["auto","avoid","all","avoid-page","page","left","right","column"]},z=function(){return[xn,wo]},J=function(){return[xn,xe]};return{cacheSize:500,theme:{colors:[Sr],spacing:[ht],blur:["none","",Qt,xe],brightness:z(),borderColor:[e],borderRadius:["none","","full",Qt,xe],borderSpacing:V(),borderWidth:R(),contrast:z(),grayscale:A(),hueRotate:J(),invert:A(),gap:V(),gradientColorStops:[e],gradientColorStopPositions:[x0,va],inset:F(),margin:F(),opacity:z(),padding:V(),saturate:z(),scale:z(),sepia:A(),skew:J(),space:V(),translate:V()},classGroups:{aspect:[{aspect:["auto","square","video",xe]}],container:["container"],columns:[{columns:[Qt]}],"break-after":[{"break-after":N()}],"break-before":[{"break-before":N()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none"]}],clear:[{clear:["left","right","both","none"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[].concat(C(),[xe])}],overflow:[{overflow:j()}],"overflow-x":[{"overflow-x":j()}],"overflow-y":[{"overflow-y":j()}],overscroll:[{overscroll:_()}],"overscroll-x":[{"overscroll-x":_()}],"overscroll-y":[{"overscroll-y":_()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[v]}],"inset-x":[{"inset-x":[v]}],"inset-y":[{"inset-y":[v]}],start:[{start:[v]}],end:[{end:[v]}],top:[{top:[v]}],right:[{right:[v]}],bottom:[{bottom:[v]}],left:[{left:[v]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Cr]}],basis:[{basis:F()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",xe]}],grow:[{grow:A()}],shrink:[{shrink:A()}],order:[{order:["first","last","none",Cr]}],"grid-cols":[{"grid-cols":[Sr]}],"col-start-end":[{col:["auto",{span:["full",Cr]},xe]}],"col-start":[{"col-start":X()}],"col-end":[{"col-end":X()}],"grid-rows":[{"grid-rows":[Sr]}],"row-start-end":[{row:["auto",{span:[Cr]},xe]}],"row-start":[{"row-start":X()}],"row-end":[{"row-end":X()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",xe]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",xe]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal"].concat(B())}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal"].concat(B(),["baseline"])}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[].concat(B(),["baseline"])}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[b]}],px:[{px:[b]}],py:[{py:[b]}],ps:[{ps:[b]}],pe:[{pe:[b]}],pt:[{pt:[b]}],pr:[{pr:[b]}],pb:[{pb:[b]}],pl:[{pl:[b]}],m:[{m:[x]}],mx:[{mx:[x]}],my:[{my:[x]}],ms:[{ms:[x]}],me:[{me:[x]}],mt:[{mt:[x]}],mr:[{mr:[x]}],mb:[{mb:[x]}],ml:[{ml:[x]}],"space-x":[{"space-x":[O]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[O]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit",xe,t]}],"min-w":[{"min-w":["min","max","fit",xe,ht]}],"max-w":[{"max-w":["0","none","full","min","max","fit","prose",{screen:[Qt]},Qt,xe]}],h:[{h:[xe,t,"auto","min","max","fit"]}],"min-h":[{"min-h":["min","max","fit",xe,ht]}],"max-h":[{"max-h":[xe,t,"min","max","fit"]}],"font-size":[{text:["base",Qt,va]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",wo]}],"font-family":[{font:[Sr]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",xe]}],"line-clamp":[{"line-clamp":["none",xn,wo]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",xe,ht]}],"list-image":[{"list-image":["none",xe]}],"list-style-type":[{list:["none","disc","decimal",xe]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[y]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[y]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[].concat(I(),["wavy"])}],"text-decoration-thickness":[{decoration:["auto","from-font",ht]}],"underline-offset":[{"underline-offset":["auto",xe,ht]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],indent:[{indent:V()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",xe]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",xe]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[y]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[].concat(C(),[y0])}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",g0]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},b0]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[h]}],"gradient-via-pos":[{via:[h]}],"gradient-to-pos":[{to:[h]}],"gradient-from":[{from:[m]}],"gradient-via":[{via:[m]}],"gradient-to":[{to:[m]}],rounded:[{rounded:[i]}],"rounded-s":[{"rounded-s":[i]}],"rounded-e":[{"rounded-e":[i]}],"rounded-t":[{"rounded-t":[i]}],"rounded-r":[{"rounded-r":[i]}],"rounded-b":[{"rounded-b":[i]}],"rounded-l":[{"rounded-l":[i]}],"rounded-ss":[{"rounded-ss":[i]}],"rounded-se":[{"rounded-se":[i]}],"rounded-ee":[{"rounded-ee":[i]}],"rounded-es":[{"rounded-es":[i]}],"rounded-tl":[{"rounded-tl":[i]}],"rounded-tr":[{"rounded-tr":[i]}],"rounded-br":[{"rounded-br":[i]}],"rounded-bl":[{"rounded-bl":[i]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[y]}],"border-style":[{border:[].concat(I(),["hidden"])}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[y]}],"divide-style":[{divide:I()}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:[""].concat(I())}],"outline-offset":[{"outline-offset":[xe,ht]}],"outline-w":[{outline:[ht]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:R()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[y]}],"ring-offset-w":[{"ring-offset":[ht]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Qt,w0]}],"shadow-color":[{shadow:[Sr]}],opacity:[{opacity:[y]}],"mix-blend":[{"mix-blend":H()}],"bg-blend":[{"bg-blend":H()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",Qt,xe]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[f]}],saturate:[{saturate:[$]}],sepia:[{sepia:[w]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[f]}],"backdrop-opacity":[{"backdrop-opacity":[y]}],"backdrop-saturate":[{"backdrop-saturate":[$]}],"backdrop-sepia":[{"backdrop-sepia":[w]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[a]}],"border-spacing-x":[{"border-spacing-x":[a]}],"border-spacing-y":[{"border-spacing-y":[a]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",xe]}],duration:[{duration:J()}],ease:[{ease:["linear","in","out","in-out",xe]}],delay:[{delay:J()}],animate:[{animate:["none","spin","ping","pulse","bounce",xe]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[S]}],"scale-x":[{"scale-x":[S]}],"scale-y":[{"scale-y":[S]}],rotate:[{rotate:[Cr,xe]}],"translate-x":[{"translate-x":[P]}],"translate-y":[{"translate-y":[P]}],"skew-x":[{"skew-x":[T]}],"skew-y":[{"skew-y":[T]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",xe]}],accent:[{accent:["auto",e]}],appearance:["appearance-none"],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",xe]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":V()}],"scroll-mx":[{"scroll-mx":V()}],"scroll-my":[{"scroll-my":V()}],"scroll-ms":[{"scroll-ms":V()}],"scroll-me":[{"scroll-me":V()}],"scroll-mt":[{"scroll-mt":V()}],"scroll-mr":[{"scroll-mr":V()}],"scroll-mb":[{"scroll-mb":V()}],"scroll-ml":[{"scroll-ml":V()}],"scroll-p":[{"scroll-p":V()}],"scroll-px":[{"scroll-px":V()}],"scroll-py":[{"scroll-py":V()}],"scroll-ps":[{"scroll-ps":V()}],"scroll-pe":[{"scroll-pe":V()}],"scroll-pt":[{"scroll-pt":V()}],"scroll-pr":[{"scroll-pr":V()}],"scroll-pb":[{"scroll-pb":V()}],"scroll-pl":[{"scroll-pl":V()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","pinch-zoom","manipulation",{pan:["x","left","right","y","up","down"]}]}],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",xe]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[ht,wo]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}}var T0=d0(E0);function Ne(...e){return T0(Fc(e))}const qc=u.forwardRef(({className:e,...t},n)=>L.jsx("span",{className:"rabbit-ds",children:L.jsx(Ic,{ref:n,className:Ne("h-4 w-4 shrink-0 rounded-sm border-2 border-[#104F95] ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-[#104F95] data-[state=checked]:text-white",e,"rabbit-ds"),...t,children:L.jsx(Yg,{className:Ne("flex items-center justify-center text-current rabbit-ds"),children:L.jsx(pa,{className:"h-3 w-3"})})})}));qc.displayName=Ic.displayName;const Yc=qc,Kc=u.forwardRef((e,t)=>{const{pressed:n,defaultPressed:r=!1,onPressedChange:o,...i}=e,[a=!1,s]=St({prop:n,onChange:o,defaultProp:r});return u.createElement(we.button,ee({type:"button","aria-pressed":a,"data-state":a?"on":"off","data-disabled":e.disabled?"":void 0},i,{ref:t,onClick:fe(e.onClick,()=>{e.disabled||s(!a)})}))}),P0=Kc;function M0({icon:e,count:t,label:n,selected:r=!1,onSelectedChange:o}){return L.jsx("div",{className:"rabbit-ds h-7 flex-col w-auto p-0 rounded-full border-0 justify-center items-center inline-flex hover:cursor-pointer focus:outline-1 focus:outline-offset-2",children:L.jsx(P0,{defaultPressed:r,asChild:!0,onPressedChange:o,className:Ne("px-4 py-1 rounded-full border flex-row justify-start items-center gap-2.5 flex","data-[state=off]:border-gray-100 data-[state=off]:bg-gray-100 data-[state=off]:text-dove-gray-500","data-[state=on]:border-sky-800 data-[state=on]:bg-sky-100 data-[state=on]:text-sky-800"),children:L.jsxs("div",{children:[e?L.jsx("div",{className:"w-4 h-4 justify-center items-center flex",children:e}):null,L.jsxs("div",{className:"text-sm leading-tight font-semibold",children:[n?L.jsx("span",{children:n}):null," ",t?L.jsxs("span",{children:["(",t,")"]}):null]})]})})})}const Xc=e=>typeof e=="boolean"?"".concat(e):e===0?"0":e,Rc=Fc,Zc=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return Rc(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:o,defaultVariants:i}=t,a=Object.keys(o).map(c=>{const d=n==null?void 0:n[c],f=i==null?void 0:i[c];if(d===null)return null;const p=Xc(d)||Xc(f);return o[c][p]}),s=n&&Object.entries(n).reduce((c,d)=>{let[f,p]=d;return p===void 0||(c[f]=p),c},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((c,d)=>{let{class:f,className:p,...m}=d;return Object.entries(m).every(h=>{let[v,x]=h;return Array.isArray(x)?x.includes({...i,...s}[v]):{...i,...s}[v]===x})?[...c,f,p]:c},[]);return Rc(e,a,l,n==null?void 0:n.class,n==null?void 0:n.className)},k0=Zc("rabbit-ds font-sans px-4 py-2 rounded text-sm font-semibold justify-center items-center gap-1 inline-flex transition-colors focus:outline-1 focus:outline-offset-2 disabled:pointer-events-none",{variants:{variant:{filled:"",outline:"",text:""},status:{default:"",error:""},size:{normal:"h-10",small:"h-7"}},compoundVariants:[{variant:"filled",status:"default",className:"bg-[#1565BC] text-white hover:bg-[#125AA9] focus:bg-[#104F95] disabled:bg-[#99D2F9]"},{variant:"filled",status:"error",className:"bg-[#C62C02] text-white hover:bg-[#AA2602] focus:bg-[#A12402] disabled:bg-[#F6B9B9]"},{variant:"outline",status:"default",className:"bg-white text-[#1565BC] border border-[#1565BC] hover:text-[#125AA9] hover:border-[#125AA9] focus:border-[#104F95] focus:text-[#104F95] disabled:border-[#104F95] disabled:text-[#104F95]"},{variant:"outline",status:"error",className:"bg-white text-[#C62C02] border border-[#C62C02] hover:text-[#AA2602] hover:border-[#AA2602] focus:border-[#A12402] focus:text-[#A12402] disabled:border-[#F6B9B9] disabled:text-[#F6B9B9]"},{variant:"text",status:"default",className:"bg-white text-[#1565BC] border-0 hover:text-[#125AA9] focus:text-[#104F95] disabled:text-[#104F95]"},{variant:"text",status:"error",className:"bg-white text-[#C62C02] border-0 hover:text-[#AA2602] focus:text-[#A12402] disabled:text-[#F6B9B9]"}],defaultVariants:{variant:"filled",status:"default",size:"normal"}}),Qc=Zc("",{variants:{size:{normal:"h-4 w-4",small:"h-3 w-3"}},defaultVariants:{size:"normal"}}),ga=u.forwardRef(({className:e,variant:t,iconLeft:n,iconRight:r,status:o,size:i,asChild:a=!1,children:s,...l},c)=>{const d=a?yn:"button";return L.jsx("div",{className:"rabbit-ds",children:L.jsxs(d,{className:Ne(k0({variant:t,className:e,size:i,status:o})),ref:c,...l,children:[n?L.jsx("div",{className:Ne(Qc({size:i})),children:n}):null,s,r?L.jsx("div",{className:Ne(Qc({size:i})),children:r}):null]})})});ga.displayName="Button",ga.defaultProps={asChild:!1,iconLeft:void 0,iconRight:void 0};const O0=ga;function ya(e){const t=e+"CollectionProvider",[n,r]=Ct(t),[o,i]=n(t,{collectionRef:{current:null},itemMap:new Map}),a=m=>{const{scope:h,children:v}=m,x=u.useRef(null),y=u.useRef(new Map).current;return u.createElement(o,{scope:h,itemMap:y,collectionRef:x},v)},s=e+"CollectionSlot",l=u.forwardRef((m,h)=>{const{scope:v,children:x}=m,y=i(s,v),b=Oe(h,y.collectionRef);return u.createElement(yn,{ref:b},x)}),c=e+"CollectionItemSlot",d="data-radix-collection-item",f=u.forwardRef((m,h)=>{const{scope:v,children:x,...y}=m,b=u.useRef(null),$=Oe(h,b),S=i(c,v);return u.useEffect(()=>(S.itemMap.set(b,{ref:b,...y}),()=>void S.itemMap.delete(b))),u.createElement(yn,{[d]:"",ref:$},x)});function p(m){const h=i(e+"CollectionConsumer",m);return u.useCallback(()=>{const x=h.collectionRef.current;if(!x)return[];const y=Array.from(x.querySelectorAll(`[${d}]`));return Array.from(h.itemMap.values()).sort((S,w)=>y.indexOf(S.ref.current)-y.indexOf(w.ref.current))},[h.collectionRef,h.itemMap])}return[{Provider:a,Slot:l,ItemSlot:f},p,r]}const _0=u.createContext(void 0);function $o(e){const t=u.useContext(_0);return e||t||"ltr"}function Jc(e,t=globalThis==null?void 0:globalThis.document){const n=He(e);u.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r),()=>t.removeEventListener("keydown",r)},[n,t])}const ba="dismissableLayer.update",N0="dismissableLayer.pointerDownOutside",A0="dismissableLayer.focusOutside";let eu;const D0=u.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),tu=u.forwardRef((e,t)=>{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:i,onFocusOutside:a,onInteractOutside:s,onDismiss:l,...c}=e,d=u.useContext(D0),[f,p]=u.useState(null),m=(n=f==null?void 0:f.ownerDocument)!==null&&n!==void 0?n:globalThis==null?void 0:globalThis.document,[,h]=u.useState({}),v=Oe(t,P=>p(P)),x=Array.from(d.layers),[y]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),b=x.indexOf(y),$=f?x.indexOf(f):-1,S=d.layersWithOutsidePointerEventsDisabled.size>0,w=$>=b,T=I0(P=>{const _=P.target,j=[...d.branches].some(F=>F.contains(_));!w||j||(i==null||i(P),s==null||s(P),P.defaultPrevented||l==null||l())},m),O=L0(P=>{const _=P.target;[...d.branches].some(F=>F.contains(_))||(a==null||a(P),s==null||s(P),P.defaultPrevented||l==null||l())},m);return Jc(P=>{$===d.layers.size-1&&(o==null||o(P),!P.defaultPrevented&&l&&(P.preventDefault(),l()))},m),u.useEffect(()=>{if(f)return r&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(eu=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),nu(),()=>{r&&d.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=eu)}},[f,m,r,d]),u.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),nu())},[f,d]),u.useEffect(()=>{const P=()=>h({});return document.addEventListener(ba,P),()=>document.removeEventListener(ba,P)},[]),u.createElement(we.div,ee({},c,{ref:v,style:{pointerEvents:S?w?"auto":"none":void 0,...e.style},onFocusCapture:fe(e.onFocusCapture,O.onFocusCapture),onBlurCapture:fe(e.onBlurCapture,O.onBlurCapture),onPointerDownCapture:fe(e.onPointerDownCapture,T.onPointerDownCapture)}))});function I0(e,t=globalThis==null?void 0:globalThis.document){const n=He(e),r=u.useRef(!1),o=u.useRef(()=>{});return u.useEffect(()=>{const i=s=>{if(s.target&&!r.current){let c=function(){ru(N0,n,l,{discrete:!0})};const l={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);r.current=!1},a=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",i),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function L0(e,t=globalThis==null?void 0:globalThis.document){const n=He(e),r=u.useRef(!1);return u.useEffect(()=>{const o=i=>{i.target&&!r.current&&ru(A0,n,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function nu(){const e=new CustomEvent(ba);document.dispatchEvent(e)}function ru(e,t,n,{discrete:r}){const o=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?fa(o,i):o.dispatchEvent(i)}let xa=0;function ou(){u.useEffect(()=>{var e,t;const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",(e=n[0])!==null&&e!==void 0?e:iu()),document.body.insertAdjacentElement("beforeend",(t=n[1])!==null&&t!==void 0?t:iu()),xa++,()=>{xa===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(r=>r.remove()),xa--}},[])}function iu(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}const wa="focusScope.autoFocusOnMount",$a="focusScope.autoFocusOnUnmount",au={bubbles:!1,cancelable:!0},su=u.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:i,...a}=e,[s,l]=u.useState(null),c=He(o),d=He(i),f=u.useRef(null),p=Oe(t,v=>l(v)),m=u.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;u.useEffect(()=>{if(r){let v=function($){if(m.paused||!s)return;const S=$.target;s.contains(S)?f.current=S:Jt(f.current,{select:!0})},x=function($){if(m.paused||!s)return;const S=$.relatedTarget;S!==null&&(s.contains(S)||Jt(f.current,{select:!0}))},y=function($){if(document.activeElement===document.body)for(const w of $)w.removedNodes.length>0&&Jt(s)};document.addEventListener("focusin",v),document.addEventListener("focusout",x);const b=new MutationObserver(y);return s&&b.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",v),document.removeEventListener("focusout",x),b.disconnect()}}},[r,s,m.paused]),u.useEffect(()=>{if(s){uu.add(m);const v=document.activeElement;if(!s.contains(v)){const y=new CustomEvent(wa,au);s.addEventListener(wa,c),s.dispatchEvent(y),y.defaultPrevented||(F0(U0(lu(s)),{select:!0}),document.activeElement===v&&Jt(s))}return()=>{s.removeEventListener(wa,c),setTimeout(()=>{const y=new CustomEvent($a,au);s.addEventListener($a,d),s.dispatchEvent(y),y.defaultPrevented||Jt(v??document.body,{select:!0}),s.removeEventListener($a,d),uu.remove(m)},0)}}},[s,c,d,m]);const h=u.useCallback(v=>{if(!n&&!r||m.paused)return;const x=v.key==="Tab"&&!v.altKey&&!v.ctrlKey&&!v.metaKey,y=document.activeElement;if(x&&y){const b=v.currentTarget,[$,S]=j0(b);$&&S?!v.shiftKey&&y===S?(v.preventDefault(),n&&Jt($,{select:!0})):v.shiftKey&&y===$&&(v.preventDefault(),n&&Jt(S,{select:!0})):y===b&&v.preventDefault()}},[n,r,m.paused]);return u.createElement(we.div,ee({tabIndex:-1},a,{ref:p,onKeyDown:h}))});function F0(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Jt(r,{select:t}),document.activeElement!==n)return}function j0(e){const t=lu(e),n=cu(t,e),r=cu(t.reverse(),e);return[n,r]}function lu(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function cu(e,t){for(const n of e)if(!z0(n,{upTo:t}))return n}function z0(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function W0(e){return e instanceof HTMLInputElement&&"select"in e}function Jt(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&W0(e)&&t&&e.select()}}const uu=B0();function B0(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=du(e,t),e.unshift(t)},remove(t){var n;e=du(e,t),(n=e[0])===null||n===void 0||n.resume()}}}function du(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function U0(e){return e.filter(t=>t.tagName!=="A")}const H0=me["useId".toString()]||(()=>{});let G0=0;function Dt(e){const[t,n]=me.useState(H0());return ot(()=>{e||n(r=>r??String(G0++))},[e]),e||(t?`radix-${t}`:"")}const V0=["top","right","bottom","left"],en=Math.min,it=Math.max,Co=Math.round,So=Math.floor,tn=e=>({x:e,y:e}),q0={left:"right",right:"left",bottom:"top",top:"bottom"},Y0={start:"end",end:"start"};function Ca(e,t,n){return it(e,en(t,n))}function It(e,t){return typeof e=="function"?e(t):e}function Lt(e){return e.split("-")[0]}function Hn(e){return e.split("-")[1]}function Sa(e){return e==="x"?"y":"x"}function Ea(e){return e==="y"?"height":"width"}function Gn(e){return["top","bottom"].includes(Lt(e))?"y":"x"}function Ta(e){return Sa(Gn(e))}function K0(e,t,n){n===void 0&&(n=!1);const r=Hn(e),o=Ta(e),i=Ea(o);let a=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(a=Eo(a)),[a,Eo(a)]}function X0(e){const t=Eo(e);return[Pa(e),t,Pa(t)]}function Pa(e){return e.replace(/start|end/g,t=>Y0[t])}function R0(e,t,n){const r=["left","right"],o=["right","left"],i=["top","bottom"],a=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?i:a;default:return[]}}function Z0(e,t,n,r){const o=Hn(e);let i=R0(Lt(e),n==="start",r);return o&&(i=i.map(a=>a+"-"+o),t&&(i=i.concat(i.map(Pa)))),i}function Eo(e){return e.replace(/left|right|bottom|top/g,t=>q0[t])}function Q0(e){return{top:0,right:0,bottom:0,left:0,...e}}function fu(e){return typeof e!="number"?Q0(e):{top:e,right:e,bottom:e,left:e}}function To(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function pu(e,t,n){let{reference:r,floating:o}=e;const i=Gn(t),a=Ta(t),s=Ea(a),l=Lt(t),c=i==="y",d=r.x+r.width/2-o.width/2,f=r.y+r.height/2-o.height/2,p=r[s]/2-o[s]/2;let m;switch(l){case"top":m={x:d,y:r.y-o.height};break;case"bottom":m={x:d,y:r.y+r.height};break;case"right":m={x:r.x+r.width,y:f};break;case"left":m={x:r.x-o.width,y:f};break;default:m={x:r.x,y:r.y}}switch(Hn(t)){case"start":m[a]-=p*(n&&c?-1:1);break;case"end":m[a]+=p*(n&&c?-1:1);break}return m}const J0=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:a}=n,s=i.filter(Boolean),l=await(a.isRTL==null?void 0:a.isRTL(t));let c=await a.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:f}=pu(c,r,l),p=r,m={},h=0;for(let v=0;v<s.length;v++){const{name:x,fn:y}=s[v],{x:b,y:$,data:S,reset:w}=await y({x:d,y:f,initialPlacement:r,placement:p,strategy:o,middlewareData:m,rects:c,platform:a,elements:{reference:e,floating:t}});if(d=b??d,f=$??f,m={...m,[x]:{...m[x],...S}},w&&h<=50){h++,typeof w=="object"&&(w.placement&&(p=w.placement),w.rects&&(c=w.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:o}):w.rects),{x:d,y:f}=pu(c,p,l)),v=-1;continue}}return{x:d,y:f,placement:p,strategy:o,middlewareData:m}};async function Er(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:i,rects:a,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:f="floating",altBoundary:p=!1,padding:m=0}=It(t,e),h=fu(m),x=s[p?f==="floating"?"reference":"floating":f],y=To(await i.getClippingRect({element:(n=await(i.isElement==null?void 0:i.isElement(x)))==null||n?x:x.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(s.floating)),boundary:c,rootBoundary:d,strategy:l})),b=f==="floating"?{...a.floating,x:r,y:o}:a.reference,$=await(i.getOffsetParent==null?void 0:i.getOffsetParent(s.floating)),S=await(i.isElement==null?void 0:i.isElement($))?await(i.getScale==null?void 0:i.getScale($))||{x:1,y:1}:{x:1,y:1},w=To(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({rect:b,offsetParent:$,strategy:l}):b);return{top:(y.top-w.top+h.top)/S.y,bottom:(w.bottom-y.bottom+h.bottom)/S.y,left:(y.left-w.left+h.left)/S.x,right:(w.right-y.right+h.right)/S.x}}const hu=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:i,platform:a,elements:s}=t,{element:l,padding:c=0}=It(e,t)||{};if(l==null)return{};const d=fu(c),f={x:n,y:r},p=Ta(o),m=Ea(p),h=await a.getDimensions(l),v=p==="y",x=v?"top":"left",y=v?"bottom":"right",b=v?"clientHeight":"clientWidth",$=i.reference[m]+i.reference[p]-f[p]-i.floating[m],S=f[p]-i.reference[p],w=await(a.getOffsetParent==null?void 0:a.getOffsetParent(l));let T=w?w[b]:0;(!T||!await(a.isElement==null?void 0:a.isElement(w)))&&(T=s.floating[b]||i.floating[m]);const O=$/2-S/2,P=T/2-h[m]/2-1,_=en(d[x],P),j=en(d[y],P),F=_,V=T-h[m]-j,R=T/2-h[m]/2+O,X=Ca(F,R,V),I=Hn(o)!=null&&R!=X&&i.reference[m]/2-(R<F?_:j)-h[m]/2<0?R<F?F-R:V-R:0;return{[p]:f[p]-I,data:{[p]:X,centerOffset:R-X+I}}}}),mu=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n;const{placement:r,middlewareData:o,rects:i,initialPlacement:a,platform:s,elements:l}=t,{mainAxis:c=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:h=!0,...v}=It(e,t),x=Lt(r),y=Lt(a)===a,b=await(s.isRTL==null?void 0:s.isRTL(l.floating)),$=f||(y||!h?[Eo(a)]:X0(a));!f&&m!=="none"&&$.push(...Z0(a,h,m,b));const S=[a,...$],w=await Er(t,v),T=[];let O=((n=o.flip)==null?void 0:n.overflows)||[];if(c&&T.push(w[x]),d){const F=K0(r,i,b);T.push(w[F[0]],w[F[1]])}if(O=[...O,{placement:r,overflows:T}],!T.every(F=>F<=0)){var P,_;const F=(((P=o.flip)==null?void 0:P.index)||0)+1,V=S[F];if(V)return{data:{index:F,overflows:O},reset:{placement:V}};let R=(_=O.filter(X=>X.overflows[0]<=0).sort((X,C)=>X.overflows[1]-C.overflows[1])[0])==null?void 0:_.placement;if(!R)switch(p){case"bestFit":{var j;const X=(j=O.map(C=>[C.placement,C.overflows.filter(I=>I>0).reduce((I,H)=>I+H,0)]).sort((C,I)=>C[1]-I[1])[0])==null?void 0:j[0];X&&(R=X);break}case"initialPlacement":R=a;break}if(r!==R)return{reset:{placement:R}}}return{}}}};function vu(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function gu(e){return V0.some(t=>e[t]>=0)}const yu=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=It(e,t);switch(r){case"referenceHidden":{const i=await Er(t,{...o,elementContext:"reference"}),a=vu(i,n.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:gu(a)}}}case"escaped":{const i=await Er(t,{...o,altBoundary:!0}),a=vu(i,n.floating);return{data:{escapedOffsets:a,escaped:gu(a)}}}default:return{}}}}};async function ey(e,t){const{placement:n,platform:r,elements:o}=e,i=await(r.isRTL==null?void 0:r.isRTL(o.floating)),a=Lt(n),s=Hn(n),l=Gn(n)==="y",c=["left","top"].includes(a)?-1:1,d=i&&l?-1:1,f=It(t,e);let{mainAxis:p,crossAxis:m,alignmentAxis:h}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...f};return s&&typeof h=="number"&&(m=s==="end"?h*-1:h),l?{x:m*d,y:p*c}:{x:p*c,y:m*d}}const bu=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){const{x:n,y:r}=t,o=await ey(t,e);return{x:n+o.x,y:r+o.y,data:o}}}},xu=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:i=!0,crossAxis:a=!1,limiter:s={fn:x=>{let{x:y,y:b}=x;return{x:y,y:b}}},...l}=It(e,t),c={x:n,y:r},d=await Er(t,l),f=Gn(Lt(o)),p=Sa(f);let m=c[p],h=c[f];if(i){const x=p==="y"?"top":"left",y=p==="y"?"bottom":"right",b=m+d[x],$=m-d[y];m=Ca(b,m,$)}if(a){const x=f==="y"?"top":"left",y=f==="y"?"bottom":"right",b=h+d[x],$=h-d[y];h=Ca(b,h,$)}const v=s.fn({...t,[p]:m,[f]:h});return{...v,data:{x:v.x-n,y:v.y-r}}}}},wu=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:i,middlewareData:a}=t,{offset:s=0,mainAxis:l=!0,crossAxis:c=!0}=It(e,t),d={x:n,y:r},f=Gn(o),p=Sa(f);let m=d[p],h=d[f];const v=It(s,t),x=typeof v=="number"?{mainAxis:v,crossAxis:0}:{mainAxis:0,crossAxis:0,...v};if(l){const $=p==="y"?"height":"width",S=i.reference[p]-i.floating[$]+x.mainAxis,w=i.reference[p]+i.reference[$]-x.mainAxis;m<S?m=S:m>w&&(m=w)}if(c){var y,b;const $=p==="y"?"width":"height",S=["top","left"].includes(Lt(o)),w=i.reference[f]-i.floating[$]+(S&&((y=a.offset)==null?void 0:y[f])||0)+(S?0:x.crossAxis),T=i.reference[f]+i.reference[$]+(S?0:((b=a.offset)==null?void 0:b[f])||0)-(S?x.crossAxis:0);h<w?h=w:h>T&&(h=T)}return{[p]:m,[f]:h}}}},$u=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:o,elements:i}=t,{apply:a=()=>{},...s}=It(e,t),l=await Er(t,s),c=Lt(n),d=Hn(n),f=Gn(n)==="y",{width:p,height:m}=r.floating;let h,v;c==="top"||c==="bottom"?(h=c,v=d===(await(o.isRTL==null?void 0:o.isRTL(i.floating))?"start":"end")?"left":"right"):(v=c,h=d==="end"?"top":"bottom");const x=m-l[h],y=p-l[v],b=!t.middlewareData.shift;let $=x,S=y;if(f){const T=p-l.left-l.right;S=d||b?en(y,T):T}else{const T=m-l.top-l.bottom;$=d||b?en(x,T):T}if(b&&!d){const T=it(l.left,0),O=it(l.right,0),P=it(l.top,0),_=it(l.bottom,0);f?S=p-2*(T!==0||O!==0?T+O:it(l.left,l.right)):$=m-2*(P!==0||_!==0?P+_:it(l.top,l.bottom))}await a({...t,availableWidth:S,availableHeight:$});const w=await o.getDimensions(i.floating);return p!==w.width||m!==w.height?{reset:{rects:!0}}:{}}}};function nn(e){return Cu(e)?(e.nodeName||"").toLowerCase():"#document"}function at(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ft(e){var t;return(t=(Cu(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Cu(e){return e instanceof Node||e instanceof at(e).Node}function jt(e){return e instanceof Element||e instanceof at(e).Element}function Et(e){return e instanceof HTMLElement||e instanceof at(e).HTMLElement}function Su(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof at(e).ShadowRoot}function Tr(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=ct(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function ty(e){return["table","td","th"].includes(nn(e))}function Ma(e){const t=ka(),n=ct(e);return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function ny(e){let t=Vn(e);for(;Et(t)&&!Po(t);){if(Ma(t))return t;t=Vn(t)}return null}function ka(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Po(e){return["html","body","#document"].includes(nn(e))}function ct(e){return at(e).getComputedStyle(e)}function Mo(e){return jt(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function Vn(e){if(nn(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Su(e)&&e.host||Ft(e);return Su(t)?t.host:t}function Eu(e){const t=Vn(e);return Po(t)?e.ownerDocument?e.ownerDocument.body:e.body:Et(t)&&Tr(t)?t:Eu(t)}function ko(e,t){var n;t===void 0&&(t=[]);const r=Eu(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),i=at(r);return o?t.concat(i,i.visualViewport||[],Tr(r)?r:[]):t.concat(r,ko(r))}function Tu(e){const t=ct(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Et(e),i=o?e.offsetWidth:n,a=o?e.offsetHeight:r,s=Co(n)!==i||Co(r)!==a;return s&&(n=i,r=a),{width:n,height:r,$:s}}function Oa(e){return jt(e)?e:e.contextElement}function qn(e){const t=Oa(e);if(!Et(t))return tn(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:i}=Tu(t);let a=(i?Co(n.width):n.width)/r,s=(i?Co(n.height):n.height)/o;return(!a||!Number.isFinite(a))&&(a=1),(!s||!Number.isFinite(s))&&(s=1),{x:a,y:s}}const ry=tn(0);function Pu(e){const t=at(e);return!ka()||!t.visualViewport?ry:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function oy(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==at(e)?!1:t}function $n(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),i=Oa(e);let a=tn(1);t&&(r?jt(r)&&(a=qn(r)):a=qn(e));const s=oy(i,n,r)?Pu(i):tn(0);let l=(o.left+s.x)/a.x,c=(o.top+s.y)/a.y,d=o.width/a.x,f=o.height/a.y;if(i){const p=at(i),m=r&&jt(r)?at(r):r;let h=p.frameElement;for(;h&&r&&m!==p;){const v=qn(h),x=h.getBoundingClientRect(),y=ct(h),b=x.left+(h.clientLeft+parseFloat(y.paddingLeft))*v.x,$=x.top+(h.clientTop+parseFloat(y.paddingTop))*v.y;l*=v.x,c*=v.y,d*=v.x,f*=v.y,l+=b,c+=$,h=at(h).frameElement}}return To({width:d,height:f,x:l,y:c})}function iy(e){let{rect:t,offsetParent:n,strategy:r}=e;const o=Et(n),i=Ft(n);if(n===i)return t;let a={scrollLeft:0,scrollTop:0},s=tn(1);const l=tn(0);if((o||!o&&r!=="fixed")&&((nn(n)!=="body"||Tr(i))&&(a=Mo(n)),Et(n))){const c=$n(n);s=qn(n),l.x=c.x+n.clientLeft,l.y=c.y+n.clientTop}return{width:t.width*s.x,height:t.height*s.y,x:t.x*s.x-a.scrollLeft*s.x+l.x,y:t.y*s.y-a.scrollTop*s.y+l.y}}function ay(e){return Array.from(e.getClientRects())}function Mu(e){return $n(Ft(e)).left+Mo(e).scrollLeft}function sy(e){const t=Ft(e),n=Mo(e),r=e.ownerDocument.body,o=it(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),i=it(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+Mu(e);const s=-n.scrollTop;return ct(r).direction==="rtl"&&(a+=it(t.clientWidth,r.clientWidth)-o),{width:o,height:i,x:a,y:s}}function ly(e,t){const n=at(e),r=Ft(e),o=n.visualViewport;let i=r.clientWidth,a=r.clientHeight,s=0,l=0;if(o){i=o.width,a=o.height;const c=ka();(!c||c&&t==="fixed")&&(s=o.offsetLeft,l=o.offsetTop)}return{width:i,height:a,x:s,y:l}}function cy(e,t){const n=$n(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,i=Et(e)?qn(e):tn(1),a=e.clientWidth*i.x,s=e.clientHeight*i.y,l=o*i.x,c=r*i.y;return{width:a,height:s,x:l,y:c}}function ku(e,t,n){let r;if(t==="viewport")r=ly(e,n);else if(t==="document")r=sy(Ft(e));else if(jt(t))r=cy(t,n);else{const o=Pu(e);r={...t,x:t.x-o.x,y:t.y-o.y}}return To(r)}function Ou(e,t){const n=Vn(e);return n===t||!jt(n)||Po(n)?!1:ct(n).position==="fixed"||Ou(n,t)}function uy(e,t){const n=t.get(e);if(n)return n;let r=ko(e).filter(s=>jt(s)&&nn(s)!=="body"),o=null;const i=ct(e).position==="fixed";let a=i?Vn(e):e;for(;jt(a)&&!Po(a);){const s=ct(a),l=Ma(a);!l&&s.position==="fixed"&&(o=null),(i?!l&&!o:!l&&s.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Tr(a)&&!l&&Ou(e,a))?r=r.filter(d=>d!==a):o=s,a=Vn(a)}return t.set(e,r),r}function dy(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const a=[...n==="clippingAncestors"?uy(t,this._c):[].concat(n),r],s=a[0],l=a.reduce((c,d)=>{const f=ku(t,d,o);return c.top=it(f.top,c.top),c.right=en(f.right,c.right),c.bottom=en(f.bottom,c.bottom),c.left=it(f.left,c.left),c},ku(t,s,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function fy(e){return Tu(e)}function py(e,t,n){const r=Et(t),o=Ft(t),i=n==="fixed",a=$n(e,!0,i,t);let s={scrollLeft:0,scrollTop:0};const l=tn(0);if(r||!r&&!i)if((nn(t)!=="body"||Tr(o))&&(s=Mo(t)),r){const c=$n(t,!0,i,t);l.x=c.x+t.clientLeft,l.y=c.y+t.clientTop}else o&&(l.x=Mu(o));return{x:a.left+s.scrollLeft-l.x,y:a.top+s.scrollTop-l.y,width:a.width,height:a.height}}function _u(e,t){return!Et(e)||ct(e).position==="fixed"?null:t?t(e):e.offsetParent}function Nu(e,t){const n=at(e);if(!Et(e))return n;let r=_u(e,t);for(;r&&ty(r)&&ct(r).position==="static";)r=_u(r,t);return r&&(nn(r)==="html"||nn(r)==="body"&&ct(r).position==="static"&&!Ma(r))?n:r||ny(e)||n}const hy=async function(e){let{reference:t,floating:n,strategy:r}=e;const o=this.getOffsetParent||Nu,i=this.getDimensions;return{reference:py(t,await o(n),r),floating:{x:0,y:0,...await i(n)}}};function my(e){return ct(e).direction==="rtl"}const vy={convertOffsetParentRelativeRectToViewportRelativeRect:iy,getDocumentElement:Ft,getClippingRect:dy,getOffsetParent:Nu,getElementRects:hy,getClientRects:ay,getDimensions:fy,getScale:qn,isElement:jt,isRTL:my};function gy(e,t){let n=null,r;const o=Ft(e);function i(){clearTimeout(r),n&&n.disconnect(),n=null}function a(s,l){s===void 0&&(s=!1),l===void 0&&(l=1),i();const{left:c,top:d,width:f,height:p}=e.getBoundingClientRect();if(s||t(),!f||!p)return;const m=So(d),h=So(o.clientWidth-(c+f)),v=So(o.clientHeight-(d+p)),x=So(c),b={rootMargin:-m+"px "+-h+"px "+-v+"px "+-x+"px",threshold:it(0,en(1,l))||1};let $=!0;function S(w){const T=w[0].intersectionRatio;if(T!==l){if(!$)return a();T?a(!1,T):r=setTimeout(()=>{a(!1,1e-7)},100)}$=!1}try{n=new IntersectionObserver(S,{...b,root:o.ownerDocument})}catch{n=new IntersectionObserver(S,b)}n.observe(e)}return a(!0),i}function Au(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:i=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,c=Oa(e),d=o||i?[...c?ko(c):[],...ko(t)]:[];d.forEach(y=>{o&&y.addEventListener("scroll",n,{passive:!0}),i&&y.addEventListener("resize",n)});const f=c&&s?gy(c,n):null;let p=-1,m=null;a&&(m=new ResizeObserver(y=>{let[b]=y;b&&b.target===c&&m&&(m.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{m&&m.observe(t)})),n()}),c&&!l&&m.observe(c),m.observe(t));let h,v=l?$n(e):null;l&&x();function x(){const y=$n(e);v&&(y.x!==v.x||y.y!==v.y||y.width!==v.width||y.height!==v.height)&&n(),v=y,h=requestAnimationFrame(x)}return n(),()=>{d.forEach(y=>{o&&y.removeEventListener("scroll",n),i&&y.removeEventListener("resize",n)}),f&&f(),m&&m.disconnect(),m=null,l&&cancelAnimationFrame(h)}}const yy=(e,t,n)=>{const r=new Map,o={platform:vy,...n},i={...o.platform,_c:r};return J0(e,t,{...o,platform:i})},Du=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?hu({element:r.current,padding:o}).fn(n):{}:r?hu({element:r,padding:o}).fn(n):{}}}};var Oo=typeof document<"u"?u.useLayoutEffect:u.useEffect;function _o(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!_o(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const i=o[r];if(!(i==="_owner"&&e.$$typeof)&&!_o(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function Iu(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Lu(e,t){const n=Iu(e);return Math.round(t*n)/n}function Fu(e){const t=me.useRef(e);return Oo(()=>{t.current=e}),t}function ju(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:i,floating:a}={},transform:s=!0,whileElementsMounted:l,open:c}=e,[d,f]=me.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,m]=me.useState(r);_o(p,r)||m(r);const[h,v]=me.useState(null),[x,y]=me.useState(null),b=me.useCallback(I=>{I!=T.current&&(T.current=I,v(I))},[v]),$=me.useCallback(I=>{I!==O.current&&(O.current=I,y(I))},[y]),S=i||h,w=a||x,T=me.useRef(null),O=me.useRef(null),P=me.useRef(d),_=Fu(l),j=Fu(o),F=me.useCallback(()=>{if(!T.current||!O.current)return;const I={placement:t,strategy:n,middleware:p};j.current&&(I.platform=j.current),yy(T.current,O.current,I).then(H=>{const B={...H,isPositioned:!0};V.current&&!_o(P.current,B)&&(P.current=B,Ng.flushSync(()=>{f(B)}))})},[p,t,n,j]);Oo(()=>{c===!1&&P.current.isPositioned&&(P.current.isPositioned=!1,f(I=>({...I,isPositioned:!1})))},[c]);const V=me.useRef(!1);Oo(()=>(V.current=!0,()=>{V.current=!1}),[]),Oo(()=>{if(S&&(T.current=S),w&&(O.current=w),S&&w){if(_.current)return _.current(S,w,F);F()}},[S,w,F,_]);const R=me.useMemo(()=>({reference:T,floating:O,setReference:b,setFloating:$}),[b,$]),X=me.useMemo(()=>({reference:S,floating:w}),[S,w]),C=me.useMemo(()=>{const I={position:n,left:0,top:0};if(!X.floating)return I;const H=Lu(X.floating,d.x),B=Lu(X.floating,d.y);return s?{...I,transform:"translate("+H+"px, "+B+"px)",...Iu(X.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:H,top:B}},[n,s,X.floating,d.x,d.y]);return me.useMemo(()=>({...d,update:F,refs:R,elements:X,floatingStyles:C}),[d,F,R,X,C])}const zu="Popper",[Wu,No]=Ct(zu),[by,Bu]=Wu(zu),xy=e=>{const{__scopePopper:t,children:n}=e,[r,o]=u.useState(null);return u.createElement(by,{scope:t,anchor:r,onAnchorChange:o},n)},wy="PopperAnchor",$y=u.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,i=Bu(wy,n),a=u.useRef(null),s=Oe(t,a);return u.useEffect(()=>{i.onAnchorChange((r==null?void 0:r.current)||a.current)}),r?null:u.createElement(we.div,ee({},o,{ref:s}))}),Uu="PopperContent",[Cy,V3]=Wu(Uu),Sy=u.forwardRef((e,t)=>{var n,r,o,i,a,s,l,c;const{__scopePopper:d,side:f="bottom",sideOffset:p=0,align:m="center",alignOffset:h=0,arrowPadding:v=0,avoidCollisions:x=!0,collisionBoundary:y=[],collisionPadding:b=0,sticky:$="partial",hideWhenDetached:S=!1,updatePositionStrategy:w="optimized",onPlaced:T,...O}=e,P=Bu(Uu,d),[_,j]=u.useState(null),F=Oe(t,Ce=>j(Ce)),[V,R]=u.useState(null),X=ua(V),C=(n=X==null?void 0:X.width)!==null&&n!==void 0?n:0,I=(r=X==null?void 0:X.height)!==null&&r!==void 0?r:0,H=f+(m!=="center"?"-"+m:""),B=typeof b=="number"?b:{top:0,right:0,bottom:0,left:0,...b},A=Array.isArray(y)?y:[y],N=A.length>0,z={padding:B,boundary:A.filter(Ey),altBoundary:N},{refs:J,floatingStyles:Q,placement:oe,isPositioned:te,middlewareData:ae}=ju({strategy:"fixed",placement:H,whileElementsMounted:(...Ce)=>Au(...Ce,{animationFrame:w==="always"}),elements:{reference:P.anchor},middleware:[bu({mainAxis:p+I,alignmentAxis:h}),x&&xu({mainAxis:!0,crossAxis:!1,limiter:$==="partial"?wu():void 0,...z}),x&&mu({...z}),$u({...z,apply:({elements:Ce,rects:ke,availableWidth:je,availableHeight:_t})=>{const{width:mn,height:Ze}=ke.reference,qt=Ce.floating.style;qt.setProperty("--radix-popper-available-width",`${je}px`),qt.setProperty("--radix-popper-available-height",`${_t}px`),qt.setProperty("--radix-popper-anchor-width",`${mn}px`),qt.setProperty("--radix-popper-anchor-height",`${Ze}px`)}}),V&&Du({element:V,padding:v}),Ty({arrowWidth:C,arrowHeight:I}),S&&yu({strategy:"referenceHidden",...z})]}),[Y,le]=Hu(oe),U=He(T);ot(()=>{te&&(U==null||U())},[te,U]);const q=(o=ae.arrow)===null||o===void 0?void 0:o.x,re=(i=ae.arrow)===null||i===void 0?void 0:i.y,k=((a=ae.arrow)===null||a===void 0?void 0:a.centerOffset)!==0,[de,pe]=u.useState();return ot(()=>{_&&pe(window.getComputedStyle(_).zIndex)},[_]),u.createElement("div",{ref:J.setFloating,"data-radix-popper-content-wrapper":"",style:{...Q,transform:te?Q.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:de,"--radix-popper-transform-origin":[(s=ae.transformOrigin)===null||s===void 0?void 0:s.x,(l=ae.transformOrigin)===null||l===void 0?void 0:l.y].join(" ")},dir:e.dir},u.createElement(Cy,{scope:d,placedSide:Y,onArrowChange:R,arrowX:q,arrowY:re,shouldHideArrow:k},u.createElement(we.div,ee({"data-side":Y,"data-align":le},O,{ref:F,style:{...O.style,animation:te?void 0:"none",opacity:(c=ae.hide)!==null&&c!==void 0&&c.referenceHidden?0:void 0}}))))});function Ey(e){return e!==null}const Ty=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,i,a;const{placement:s,rects:l,middlewareData:c}=t,f=((n=c.arrow)===null||n===void 0?void 0:n.centerOffset)!==0,p=f?0:e.arrowWidth,m=f?0:e.arrowHeight,[h,v]=Hu(s),x={start:"0%",center:"50%",end:"100%"}[v],y=((r=(o=c.arrow)===null||o===void 0?void 0:o.x)!==null&&r!==void 0?r:0)+p/2,b=((i=(a=c.arrow)===null||a===void 0?void 0:a.y)!==null&&i!==void 0?i:0)+m/2;let $="",S="";return h==="bottom"?($=f?x:`${y}px`,S=`${-m}px`):h==="top"?($=f?x:`${y}px`,S=`${l.floating.height+m}px`):h==="right"?($=`${-m}px`,S=f?x:`${b}px`):h==="left"&&($=`${l.floating.width+m}px`,S=f?x:`${b}px`),{data:{x:$,y:S}}}});function Hu(e){const[t,n="center"]=e.split("-");return[t,n]}const _a=xy,Gu=$y,Vu=Sy,qu=u.forwardRef((e,t)=>{var n;const{container:r=globalThis==null||(n=globalThis.document)===null||n===void 0?void 0:n.body,...o}=e;return r?At.createPortal(u.createElement(we.div,ee({},o,{ref:t})),r):null}),Na="rovingFocusGroup.onEntryFocus",Py={bubbles:!1,cancelable:!0},Aa="RovingFocusGroup",[Da,Yu,My]=ya(Aa),[ky,Ao]=Ct(Aa,[My]),[Oy,_y]=ky(Aa),Ny=u.forwardRef((e,t)=>u.createElement(Da.Provider,{scope:e.__scopeRovingFocusGroup},u.createElement(Da.Slot,{scope:e.__scopeRovingFocusGroup},u.createElement(Ay,ee({},e,{ref:t}))))),Ay=u.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:i,currentTabStopId:a,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:l,onEntryFocus:c,...d}=e,f=u.useRef(null),p=Oe(t,f),m=$o(i),[h=null,v]=St({prop:a,defaultProp:s,onChange:l}),[x,y]=u.useState(!1),b=He(c),$=Yu(n),S=u.useRef(!1),[w,T]=u.useState(0);return u.useEffect(()=>{const O=f.current;if(O)return O.addEventListener(Na,b),()=>O.removeEventListener(Na,b)},[b]),u.createElement(Oy,{scope:n,orientation:r,dir:m,loop:o,currentTabStopId:h,onItemFocus:u.useCallback(O=>v(O),[v]),onItemShiftTab:u.useCallback(()=>y(!0),[]),onFocusableItemAdd:u.useCallback(()=>T(O=>O+1),[]),onFocusableItemRemove:u.useCallback(()=>T(O=>O-1),[])},u.createElement(we.div,ee({tabIndex:x||w===0?-1:0,"data-orientation":r},d,{ref:p,style:{outline:"none",...e.style},onMouseDown:fe(e.onMouseDown,()=>{S.current=!0}),onFocus:fe(e.onFocus,O=>{const P=!S.current;if(O.target===O.currentTarget&&P&&!x){const _=new CustomEvent(Na,Py);if(O.currentTarget.dispatchEvent(_),!_.defaultPrevented){const j=$().filter(C=>C.focusable),F=j.find(C=>C.active),V=j.find(C=>C.id===h),X=[F,V,...j].filter(Boolean).map(C=>C.ref.current);Ku(X)}}S.current=!1}),onBlur:fe(e.onBlur,()=>y(!1))})))}),Dy="RovingFocusGroupItem",Iy=u.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:i,...a}=e,s=Dt(),l=i||s,c=_y(Dy,n),d=c.currentTabStopId===l,f=Yu(n),{onFocusableItemAdd:p,onFocusableItemRemove:m}=c;return u.useEffect(()=>{if(r)return p(),()=>m()},[r,p,m]),u.createElement(Da.ItemSlot,{scope:n,id:l,focusable:r,active:o},u.createElement(we.span,ee({tabIndex:d?0:-1,"data-orientation":c.orientation},a,{ref:t,onMouseDown:fe(e.onMouseDown,h=>{r?c.onItemFocus(l):h.preventDefault()}),onFocus:fe(e.onFocus,()=>c.onItemFocus(l)),onKeyDown:fe(e.onKeyDown,h=>{if(h.key==="Tab"&&h.shiftKey){c.onItemShiftTab();return}if(h.target!==h.currentTarget)return;const v=jy(h,c.orientation,c.dir);if(v!==void 0){h.preventDefault();let y=f().filter(b=>b.focusable).map(b=>b.ref.current);if(v==="last")y.reverse();else if(v==="prev"||v==="next"){v==="prev"&&y.reverse();const b=y.indexOf(h.currentTarget);y=c.loop?zy(y,b+1):y.slice(b+1)}setTimeout(()=>Ku(y))}})})))}),Ly={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Fy(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function jy(e,t,n){const r=Fy(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return Ly[r]}function Ku(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function zy(e,t){return e.map((n,r)=>e[(t+r)%e.length])}const Xu=Ny,Ru=Iy;var Wy=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Yn=new WeakMap,Do=new WeakMap,Io={},Ia=0,Zu=function(e){return e&&(e.host||Zu(e.parentNode))},By=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=Zu(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},Uy=function(e,t,n,r){var o=By(t,Array.isArray(e)?e:[e]);Io[n]||(Io[n]=new WeakMap);var i=Io[n],a=[],s=new Set,l=new Set(o),c=function(f){!f||s.has(f)||(s.add(f),c(f.parentNode))};o.forEach(c);var d=function(f){!f||l.has(f)||Array.prototype.forEach.call(f.children,function(p){if(s.has(p))d(p);else{var m=p.getAttribute(r),h=m!==null&&m!=="false",v=(Yn.get(p)||0)+1,x=(i.get(p)||0)+1;Yn.set(p,v),i.set(p,x),a.push(p),v===1&&h&&Do.set(p,!0),x===1&&p.setAttribute(n,"true"),h||p.setAttribute(r,"true")}})};return d(t),s.clear(),Ia++,function(){a.forEach(function(f){var p=Yn.get(f)-1,m=i.get(f)-1;Yn.set(f,p),i.set(f,m),p||(Do.has(f)||f.removeAttribute(r),Do.delete(f)),m||f.removeAttribute(n)}),Ia--,Ia||(Yn=new WeakMap,Yn=new WeakMap,Do=new WeakMap,Io={})}},Qu=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=t||Wy(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live]"))),Uy(r,o,n,"aria-hidden")):function(){return null}},Tt=function(){return Tt=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])}return t},Tt.apply(this,arguments)};function Ju(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function Hy(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,i;r<o;r++)(i||!(r in t))&&(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var Lo="right-scroll-bar-position",Fo="width-before-scroll-bar",Gy="with-scroll-bars-hidden",Vy="--removed-body-scroll-bar-size";function qy(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Yy(e,t){var n=u.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}function Ky(e,t){return Yy(t||null,function(n){return e.forEach(function(r){return qy(r,n)})})}function Xy(e){return e}function Ry(e,t){t===void 0&&(t=Xy);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(i){var a=t(i,r);return n.push(a),function(){n=n.filter(function(s){return s!==a})}},assignSyncMedium:function(i){for(r=!0;n.length;){var a=n;n=[],a.forEach(i)}n={push:function(s){return i(s)},filter:function(){return n}}},assignMedium:function(i){r=!0;var a=[];if(n.length){var s=n;n=[],s.forEach(i),a=n}var l=function(){var d=a;a=[],d.forEach(i)},c=function(){return Promise.resolve().then(l)};c(),n={push:function(d){a.push(d),c()},filter:function(d){return a=a.filter(d),n}}}};return o}function Zy(e){e===void 0&&(e={});var t=Ry(null);return t.options=Tt({async:!0,ssr:!1},e),t}var ed=function(e){var t=e.sideCar,n=Ju(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return me.createElement(r,Tt({},n))};ed.isSideCarExport=!0;function Qy(e,t){return e.useMedium(t),ed}var td=Zy(),La=function(){},jo=me.forwardRef(function(e,t){var n=me.useRef(null),r=me.useState({onScrollCapture:La,onWheelCapture:La,onTouchMoveCapture:La}),o=r[0],i=r[1],a=e.forwardProps,s=e.children,l=e.className,c=e.removeScrollBar,d=e.enabled,f=e.shards,p=e.sideCar,m=e.noIsolation,h=e.inert,v=e.allowPinchZoom,x=e.as,y=x===void 0?"div":x,b=Ju(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as"]),$=p,S=Ky([n,t]),w=Tt(Tt({},b),o);return me.createElement(me.Fragment,null,d&&me.createElement($,{sideCar:td,removeScrollBar:c,shards:f,noIsolation:m,inert:h,setCallbacks:i,allowPinchZoom:!!v,lockRef:n}),a?me.cloneElement(me.Children.only(s),Tt(Tt({},w),{ref:S})):me.createElement(y,Tt({},w,{className:l,ref:S}),s))});jo.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},jo.classNames={fullWidth:Fo,zeroRight:Lo};var nd,Jy=function(){if(nd)return nd;if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function eb(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=Jy();return t&&e.setAttribute("nonce",t),e}function tb(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function nb(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var rb=function(){var e=0,t=null;return{add:function(n){e==0&&(t=eb())&&(tb(t,n),nb(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},ob=function(){var e=rb();return function(t,n){me.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},rd=function(){var e=ob(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},ib={left:0,top:0,right:0,gap:0},Fa=function(e){return parseInt(e||"",10)||0},ab=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[Fa(n),Fa(r),Fa(o)]},sb=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return ib;var t=ab(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},lb=rd(),cb=function(e,t,n,r){var o=e.left,i=e.top,a=e.right,s=e.gap;return n===void 0&&(n="margin"),`
2
- .`.concat(Gy,` {
1
+ (function(ve,L){typeof exports=="object"&&typeof module<"u"?L(exports,require("react/jsx-runtime"),require("react"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react","react-dom"],L):(ve=typeof globalThis<"u"?globalThis:ve||self,L((ve["@mesh"]=ve["@mesh"]||{},ve["@mesh"]["ai/rabbit"]={}),ve["react/jsx-runtime"],ve.React,ve.ReactDOM))})(this,function(ve,L,u,At){"use strict";function _c(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const me=_c(u),Ag=_c(At),V3="";function ee(){return ee=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ee.apply(this,arguments)}function Dg(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function bo(...e){return t=>e.forEach(n=>Dg(n,t))}function Oe(...e){return u.useCallback(bo(...e),e)}function Ct(e,t=[]){let n=[];function r(i,a){const s=u.createContext(a),l=n.length;n=[...n,a];function c(f){const{scope:p,children:m,...h}=f,v=(p==null?void 0:p[e][l])||s,x=u.useMemo(()=>h,Object.values(h));return u.createElement(v.Provider,{value:x},m)}function d(f,p){const m=(p==null?void 0:p[e][l])||s,h=u.useContext(m);if(h)return h;if(a!==void 0)return a;throw new Error(`\`${f}\` must be used within \`${i}\``)}return c.displayName=i+"Provider",[c,d]}const o=()=>{const i=n.map(a=>u.createContext(a));return function(s){const l=(s==null?void 0:s[e])||i;return u.useMemo(()=>({[`__scope${e}`]:{...s,[e]:l}}),[s,l])}};return o.scopeName=e,[r,Ig(o,...t)]}function Ig(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(i){const a=r.reduce((s,{useScope:l,scopeName:c})=>{const f=l(i)[`__scope${c}`];return{...s,...f}},{});return u.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function fe(e,t,{checkForDefaultPrevented:n=!0}={}){return function(o){if(e==null||e(o),n===!1||!o.defaultPrevented)return t==null?void 0:t(o)}}function He(e){const t=u.useRef(e);return u.useEffect(()=>{t.current=e}),u.useMemo(()=>(...n)=>{var r;return(r=t.current)===null||r===void 0?void 0:r.call(t,...n)},[])}function St({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=Lg({defaultProp:t,onChange:n}),i=e!==void 0,a=i?e:r,s=He(n),l=u.useCallback(c=>{if(i){const f=typeof c=="function"?c(e):c;f!==e&&s(f)}else o(c)},[i,e,o,s]);return[a,l]}function Lg({defaultProp:e,onChange:t}){const n=u.useState(e),[r]=n,o=u.useRef(r),i=He(t);return u.useEffect(()=>{o.current!==r&&(i(r),o.current=r)},[r,o,i]),n}function Nc(e){const t=u.useRef({value:e,previous:e});return u.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}const ot=globalThis!=null&&globalThis.document?u.useLayoutEffect:()=>{};function ua(e){const[t,n]=u.useState(void 0);return ot(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const i=o[0];let a,s;if("borderBoxSize"in i){const l=i.borderBoxSize,c=Array.isArray(l)?l[0]:l;a=c.inlineSize,s=c.blockSize}else a=e.offsetWidth,s=e.offsetHeight;n({width:a,height:s})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}function Fg(e,t){return u.useReducer((n,r)=>{const o=t[n][r];return o??n},e)}const Zt=e=>{const{present:t,children:n}=e,r=jg(t),o=typeof n=="function"?n({present:r.isPresent}):u.Children.only(n),i=Oe(r.ref,o.ref);return typeof n=="function"||r.isPresent?u.cloneElement(o,{ref:i}):null};Zt.displayName="Presence";function jg(e){const[t,n]=u.useState(),r=u.useRef({}),o=u.useRef(e),i=u.useRef("none"),a=e?"mounted":"unmounted",[s,l]=Fg(a,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return u.useEffect(()=>{const c=xo(r.current);i.current=s==="mounted"?c:"none"},[s]),ot(()=>{const c=r.current,d=o.current;if(d!==e){const p=i.current,m=xo(c);e?l("MOUNT"):m==="none"||(c==null?void 0:c.display)==="none"?l("UNMOUNT"):l(d&&p!==m?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,l]),ot(()=>{if(t){const c=f=>{const m=xo(r.current).includes(f.animationName);f.target===t&&m&&At.flushSync(()=>l("ANIMATION_END"))},d=f=>{f.target===t&&(i.current=xo(r.current))};return t.addEventListener("animationstart",d),t.addEventListener("animationcancel",c),t.addEventListener("animationend",c),()=>{t.removeEventListener("animationstart",d),t.removeEventListener("animationcancel",c),t.removeEventListener("animationend",c)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:u.useCallback(c=>{c&&(r.current=getComputedStyle(c)),n(c)},[])}}function xo(e){return(e==null?void 0:e.animationName)||"none"}const yn=u.forwardRef((e,t)=>{const{children:n,...r}=e,o=u.Children.toArray(n),i=o.find(zg);if(i){const a=i.props.children,s=o.map(l=>l===i?u.Children.count(a)>1?u.Children.only(null):u.isValidElement(a)?a.props.children:null:l);return u.createElement(da,ee({},r,{ref:t}),u.isValidElement(a)?u.cloneElement(a,void 0,s):null)}return u.createElement(da,ee({},r,{ref:t}),n)});yn.displayName="Slot";const da=u.forwardRef((e,t)=>{const{children:n,...r}=e;return u.isValidElement(n)?u.cloneElement(n,{...Wg(r,n.props),ref:t?bo(t,n.ref):n.ref}):u.Children.count(n)>1?u.Children.only(null):null});da.displayName="SlotClone";const Ac=({children:e})=>u.createElement(u.Fragment,null,e);function zg(e){return u.isValidElement(e)&&e.type===Ac}function Wg(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...s)=>{i(...s),o(...s)}:o&&(n[r]=o):r==="style"?n[r]={...o,...i}:r==="className"&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}const we=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce((e,t)=>{const n=u.forwardRef((r,o)=>{const{asChild:i,...a}=r,s=i?yn:t;return u.useEffect(()=>{window[Symbol.for("radix-ui")]=!0},[]),u.createElement(s,ee({},a,{ref:o}))});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function fa(e,t){e&&At.flushSync(()=>e.dispatchEvent(t))}const Dc="Checkbox",[Bg,Y3]=Ct(Dc),[Ug,Hg]=Bg(Dc),Gg=u.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:r,checked:o,defaultChecked:i,required:a,disabled:s,value:l="on",onCheckedChange:c,...d}=e,[f,p]=u.useState(null),m=Oe(t,$=>p($)),h=u.useRef(!1),v=f?!!f.closest("form"):!0,[x=!1,y]=St({prop:o,defaultProp:i,onChange:c}),b=u.useRef(x);return u.useEffect(()=>{const $=f==null?void 0:f.form;if($){const S=()=>y(b.current);return $.addEventListener("reset",S),()=>$.removeEventListener("reset",S)}},[f,y]),u.createElement(Ug,{scope:n,state:x,disabled:s},u.createElement(we.button,ee({type:"button",role:"checkbox","aria-checked":bn(x)?"mixed":x,"aria-required":a,"data-state":Ic(x),"data-disabled":s?"":void 0,disabled:s,value:l},d,{ref:m,onKeyDown:fe(e.onKeyDown,$=>{$.key==="Enter"&&$.preventDefault()}),onClick:fe(e.onClick,$=>{y(S=>bn(S)?!0:!S),v&&(h.current=$.isPropagationStopped(),h.current||$.stopPropagation())})})),v&&u.createElement(Yg,{control:f,bubbles:!h.current,name:r,value:l,checked:x,required:a,disabled:s,style:{transform:"translateX(-100%)"}}))}),Vg="CheckboxIndicator",qg=u.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...o}=e,i=Hg(Vg,n);return u.createElement(Zt,{present:r||bn(i.state)||i.state===!0},u.createElement(we.span,ee({"data-state":Ic(i.state),"data-disabled":i.disabled?"":void 0},o,{ref:t,style:{pointerEvents:"none",...e.style}})))}),Yg=e=>{const{control:t,checked:n,bubbles:r=!0,...o}=e,i=u.useRef(null),a=Nc(n),s=ua(t);return u.useEffect(()=>{const l=i.current,c=window.HTMLInputElement.prototype,f=Object.getOwnPropertyDescriptor(c,"checked").set;if(a!==n&&f){const p=new Event("click",{bubbles:r});l.indeterminate=bn(n),f.call(l,bn(n)?!1:n),l.dispatchEvent(p)}},[a,n,r]),u.createElement("input",ee({type:"checkbox","aria-hidden":!0,defaultChecked:bn(n)?!1:n},o,{tabIndex:-1,ref:i,style:{...e.style,...s,position:"absolute",pointerEvents:"none",opacity:0,margin:0}}))};function bn(e){return e==="indeterminate"}function Ic(e){return bn(e)?"indeterminate":e?"checked":"unchecked"}const Lc=Gg,Kg=qg;var Xg={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const Rg=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Cr=(e,t)=>{const n=u.forwardRef(({color:r="currentColor",size:o=24,strokeWidth:i=2,absoluteStrokeWidth:a,children:s,...l},c)=>u.createElement("svg",{ref:c,...Xg,width:o,height:o,stroke:r,strokeWidth:a?Number(i)*24/Number(o):i,className:`lucide lucide-${Rg(e)}`,...l},[...t.map(([d,f])=>u.createElement(d,f)),...(Array.isArray(s)?s:[s])||[]]));return n.displayName=`${e}`,n},pa=Cr("Check",[["polyline",{points:"20 6 9 17 4 12",key:"10jjfj"}]]),Zg=Cr("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),Qg=Cr("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]),Jg=Cr("Circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]),e0=Cr("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);function Fc(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=Fc(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function jc(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=Fc(e))&&(r&&(r+=" "),r+=t);return r}function t0(){for(var e=0,t,n,r="";e<arguments.length;)(t=arguments[e++])&&(n=zc(t))&&(r&&(r+=" "),r+=n);return r}function zc(e){if(typeof e=="string")return e;for(var t,n="",r=0;r<e.length;r++)e[r]&&(t=zc(e[r]))&&(n&&(n+=" "),n+=t);return n}var ha="-";function n0(e){var t=o0(e),n=e.conflictingClassGroups,r=e.conflictingClassGroupModifiers,o=r===void 0?{}:r;function i(s){var l=s.split(ha);return l[0]===""&&l.length!==1&&l.shift(),Wc(l,t)||r0(s)}function a(s,l){var c=n[s]||[];return l&&o[s]?[].concat(c,o[s]):c}return{getClassGroupId:i,getConflictingClassGroupIds:a}}function Wc(e,t){var a;if(e.length===0)return t.classGroupId;var n=e[0],r=t.nextPart.get(n),o=r?Wc(e.slice(1),r):void 0;if(o)return o;if(t.validators.length!==0){var i=e.join(ha);return(a=t.validators.find(function(s){var l=s.validator;return l(i)}))==null?void 0:a.classGroupId}}var Bc=/^\[(.+)\]$/;function r0(e){if(Bc.test(e)){var t=Bc.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}}function o0(e){var t=e.theme,n=e.prefix,r={nextPart:new Map,validators:[]},o=a0(Object.entries(e.classGroups),n);return o.forEach(function(i){var a=i[0],s=i[1];ma(s,r,a,t)}),r}function ma(e,t,n,r){e.forEach(function(o){if(typeof o=="string"){var i=o===""?t:Uc(t,o);i.classGroupId=n;return}if(typeof o=="function"){if(i0(o)){ma(o(r),t,n,r);return}t.validators.push({validator:o,classGroupId:n});return}Object.entries(o).forEach(function(a){var s=a[0],l=a[1];ma(l,Uc(t,s),n,r)})})}function Uc(e,t){var n=e;return t.split(ha).forEach(function(r){n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n}function i0(e){return e.isThemeGetter}function a0(e,t){return t?e.map(function(n){var r=n[0],o=n[1],i=o.map(function(a){return typeof a=="string"?t+a:typeof a=="object"?Object.fromEntries(Object.entries(a).map(function(s){var l=s[0],c=s[1];return[t+l,c]})):a});return[r,i]}):e}function s0(e){if(e<1)return{get:function(){},set:function(){}};var t=0,n=new Map,r=new Map;function o(i,a){n.set(i,a),t++,t>e&&(t=0,r=n,n=new Map)}return{get:function(a){var s=n.get(a);if(s!==void 0)return s;if((s=r.get(a))!==void 0)return o(a,s),s},set:function(a,s){n.has(a)?n.set(a,s):o(a,s)}}}var Hc="!";function l0(e){var t=e.separator||":",n=t.length===1,r=t[0],o=t.length;return function(a){for(var s=[],l=0,c=0,d,f=0;f<a.length;f++){var p=a[f];if(l===0){if(p===r&&(n||a.slice(f,f+o)===t)){s.push(a.slice(c,f)),c=f+o;continue}if(p==="/"){d=f;continue}}p==="["?l++:p==="]"&&l--}var m=s.length===0?a:a.substring(c),h=m.startsWith(Hc),v=h?m.substring(1):m,x=d&&d>c?d-c:void 0;return{modifiers:s,hasImportantModifier:h,baseClassName:v,maybePostfixModifierPosition:x}}}function c0(e){if(e.length<=1)return e;var t=[],n=[];return e.forEach(function(r){var o=r[0]==="[";o?(t.push.apply(t,n.sort().concat([r])),n=[]):n.push(r)}),t.push.apply(t,n.sort()),t}function u0(e){return{cache:s0(e.cacheSize),splitModifiers:l0(e),...n0(e)}}var d0=/\s+/;function f0(e,t){var n=t.splitModifiers,r=t.getClassGroupId,o=t.getConflictingClassGroupIds,i=new Set;return e.trim().split(d0).map(function(a){var s=n(a),l=s.modifiers,c=s.hasImportantModifier,d=s.baseClassName,f=s.maybePostfixModifierPosition,p=r(f?d.substring(0,f):d),m=!!f;if(!p){if(!f)return{isTailwindClass:!1,originalClassName:a};if(p=r(d),!p)return{isTailwindClass:!1,originalClassName:a};m=!1}var h=c0(l).join(":"),v=c?h+Hc:h;return{isTailwindClass:!0,modifierId:v,classGroupId:p,originalClassName:a,hasPostfixModifier:m}}).reverse().filter(function(a){if(!a.isTailwindClass)return!0;var s=a.modifierId,l=a.classGroupId,c=a.hasPostfixModifier,d=s+l;return i.has(d)?!1:(i.add(d),o(l,c).forEach(function(f){return i.add(s+f)}),!0)}).reverse().map(function(a){return a.originalClassName}).join(" ")}function p0(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r,o,i,a=s;function s(c){var d=t[0],f=t.slice(1),p=f.reduce(function(m,h){return h(m)},d());return r=u0(p),o=r.cache.get,i=r.cache.set,a=l,l(c)}function l(c){var d=o(c);if(d)return d;var f=f0(c,r);return i(c,f),f}return function(){return a(t0.apply(null,arguments))}}function Ae(e){var t=function(r){return r[e]||[]};return t.isThemeGetter=!0,t}var Gc=/^\[(?:([a-z-]+):)?(.+)\]$/i,h0=/^\d+\/\d+$/,m0=new Set(["px","full","screen"]),v0=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,g0=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,y0=/^-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/;function ht(e){return xn(e)||m0.has(e)||h0.test(e)||va(e)}function va(e){return wn(e,"length",S0)}function b0(e){return wn(e,"size",Vc)}function x0(e){return wn(e,"position",Vc)}function w0(e){return wn(e,"url",E0)}function wo(e){return wn(e,"number",xn)}function xn(e){return!Number.isNaN(Number(e))}function $0(e){return e.endsWith("%")&&xn(e.slice(0,-1))}function Sr(e){return qc(e)||wn(e,"number",qc)}function xe(e){return Gc.test(e)}function Er(){return!0}function Qt(e){return v0.test(e)}function C0(e){return wn(e,"",T0)}function wn(e,t,n){var r=Gc.exec(e);return r?r[1]?r[1]===t:n(r[2]):!1}function S0(e){return g0.test(e)}function Vc(){return!1}function E0(e){return e.startsWith("url(")}function qc(e){return Number.isInteger(Number(e))}function T0(e){return y0.test(e)}function P0(){var e=Ae("colors"),t=Ae("spacing"),n=Ae("blur"),r=Ae("brightness"),o=Ae("borderColor"),i=Ae("borderRadius"),a=Ae("borderSpacing"),s=Ae("borderWidth"),l=Ae("contrast"),c=Ae("grayscale"),d=Ae("hueRotate"),f=Ae("invert"),p=Ae("gap"),m=Ae("gradientColorStops"),h=Ae("gradientColorStopPositions"),v=Ae("inset"),x=Ae("margin"),y=Ae("opacity"),b=Ae("padding"),$=Ae("saturate"),S=Ae("scale"),w=Ae("sepia"),T=Ae("skew"),O=Ae("space"),P=Ae("translate"),_=function(){return["auto","contain","none"]},j=function(){return["auto","hidden","clip","visible","scroll"]},F=function(){return["auto",xe,t]},V=function(){return[xe,t]},R=function(){return["",ht]},X=function(){return["auto",xn,xe]},C=function(){return["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"]},I=function(){return["solid","dashed","dotted","double","none"]},H=function(){return["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-lighter"]},B=function(){return["start","end","center","between","around","evenly","stretch"]},A=function(){return["","0",xe]},N=function(){return["auto","avoid","all","avoid-page","page","left","right","column"]},z=function(){return[xn,wo]},J=function(){return[xn,xe]};return{cacheSize:500,theme:{colors:[Er],spacing:[ht],blur:["none","",Qt,xe],brightness:z(),borderColor:[e],borderRadius:["none","","full",Qt,xe],borderSpacing:V(),borderWidth:R(),contrast:z(),grayscale:A(),hueRotate:J(),invert:A(),gap:V(),gradientColorStops:[e],gradientColorStopPositions:[$0,va],inset:F(),margin:F(),opacity:z(),padding:V(),saturate:z(),scale:z(),sepia:A(),skew:J(),space:V(),translate:V()},classGroups:{aspect:[{aspect:["auto","square","video",xe]}],container:["container"],columns:[{columns:[Qt]}],"break-after":[{"break-after":N()}],"break-before":[{"break-before":N()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none"]}],clear:[{clear:["left","right","both","none"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[].concat(C(),[xe])}],overflow:[{overflow:j()}],"overflow-x":[{"overflow-x":j()}],"overflow-y":[{"overflow-y":j()}],overscroll:[{overscroll:_()}],"overscroll-x":[{"overscroll-x":_()}],"overscroll-y":[{"overscroll-y":_()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[v]}],"inset-x":[{"inset-x":[v]}],"inset-y":[{"inset-y":[v]}],start:[{start:[v]}],end:[{end:[v]}],top:[{top:[v]}],right:[{right:[v]}],bottom:[{bottom:[v]}],left:[{left:[v]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Sr]}],basis:[{basis:F()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",xe]}],grow:[{grow:A()}],shrink:[{shrink:A()}],order:[{order:["first","last","none",Sr]}],"grid-cols":[{"grid-cols":[Er]}],"col-start-end":[{col:["auto",{span:["full",Sr]},xe]}],"col-start":[{"col-start":X()}],"col-end":[{"col-end":X()}],"grid-rows":[{"grid-rows":[Er]}],"row-start-end":[{row:["auto",{span:[Sr]},xe]}],"row-start":[{"row-start":X()}],"row-end":[{"row-end":X()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",xe]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",xe]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal"].concat(B())}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal"].concat(B(),["baseline"])}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[].concat(B(),["baseline"])}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[b]}],px:[{px:[b]}],py:[{py:[b]}],ps:[{ps:[b]}],pe:[{pe:[b]}],pt:[{pt:[b]}],pr:[{pr:[b]}],pb:[{pb:[b]}],pl:[{pl:[b]}],m:[{m:[x]}],mx:[{mx:[x]}],my:[{my:[x]}],ms:[{ms:[x]}],me:[{me:[x]}],mt:[{mt:[x]}],mr:[{mr:[x]}],mb:[{mb:[x]}],ml:[{ml:[x]}],"space-x":[{"space-x":[O]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[O]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit",xe,t]}],"min-w":[{"min-w":["min","max","fit",xe,ht]}],"max-w":[{"max-w":["0","none","full","min","max","fit","prose",{screen:[Qt]},Qt,xe]}],h:[{h:[xe,t,"auto","min","max","fit"]}],"min-h":[{"min-h":["min","max","fit",xe,ht]}],"max-h":[{"max-h":[xe,t,"min","max","fit"]}],"font-size":[{text:["base",Qt,va]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",wo]}],"font-family":[{font:[Er]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",xe]}],"line-clamp":[{"line-clamp":["none",xn,wo]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",xe,ht]}],"list-image":[{"list-image":["none",xe]}],"list-style-type":[{list:["none","disc","decimal",xe]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[y]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[y]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[].concat(I(),["wavy"])}],"text-decoration-thickness":[{decoration:["auto","from-font",ht]}],"underline-offset":[{"underline-offset":["auto",xe,ht]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],indent:[{indent:V()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",xe]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",xe]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[y]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[].concat(C(),[x0])}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",b0]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},w0]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[h]}],"gradient-via-pos":[{via:[h]}],"gradient-to-pos":[{to:[h]}],"gradient-from":[{from:[m]}],"gradient-via":[{via:[m]}],"gradient-to":[{to:[m]}],rounded:[{rounded:[i]}],"rounded-s":[{"rounded-s":[i]}],"rounded-e":[{"rounded-e":[i]}],"rounded-t":[{"rounded-t":[i]}],"rounded-r":[{"rounded-r":[i]}],"rounded-b":[{"rounded-b":[i]}],"rounded-l":[{"rounded-l":[i]}],"rounded-ss":[{"rounded-ss":[i]}],"rounded-se":[{"rounded-se":[i]}],"rounded-ee":[{"rounded-ee":[i]}],"rounded-es":[{"rounded-es":[i]}],"rounded-tl":[{"rounded-tl":[i]}],"rounded-tr":[{"rounded-tr":[i]}],"rounded-br":[{"rounded-br":[i]}],"rounded-bl":[{"rounded-bl":[i]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[y]}],"border-style":[{border:[].concat(I(),["hidden"])}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[y]}],"divide-style":[{divide:I()}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:[""].concat(I())}],"outline-offset":[{"outline-offset":[xe,ht]}],"outline-w":[{outline:[ht]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:R()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[y]}],"ring-offset-w":[{"ring-offset":[ht]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Qt,C0]}],"shadow-color":[{shadow:[Er]}],opacity:[{opacity:[y]}],"mix-blend":[{"mix-blend":H()}],"bg-blend":[{"bg-blend":H()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",Qt,xe]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[f]}],saturate:[{saturate:[$]}],sepia:[{sepia:[w]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[f]}],"backdrop-opacity":[{"backdrop-opacity":[y]}],"backdrop-saturate":[{"backdrop-saturate":[$]}],"backdrop-sepia":[{"backdrop-sepia":[w]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[a]}],"border-spacing-x":[{"border-spacing-x":[a]}],"border-spacing-y":[{"border-spacing-y":[a]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",xe]}],duration:[{duration:J()}],ease:[{ease:["linear","in","out","in-out",xe]}],delay:[{delay:J()}],animate:[{animate:["none","spin","ping","pulse","bounce",xe]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[S]}],"scale-x":[{"scale-x":[S]}],"scale-y":[{"scale-y":[S]}],rotate:[{rotate:[Sr,xe]}],"translate-x":[{"translate-x":[P]}],"translate-y":[{"translate-y":[P]}],"skew-x":[{"skew-x":[T]}],"skew-y":[{"skew-y":[T]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",xe]}],accent:[{accent:["auto",e]}],appearance:["appearance-none"],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",xe]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":V()}],"scroll-mx":[{"scroll-mx":V()}],"scroll-my":[{"scroll-my":V()}],"scroll-ms":[{"scroll-ms":V()}],"scroll-me":[{"scroll-me":V()}],"scroll-mt":[{"scroll-mt":V()}],"scroll-mr":[{"scroll-mr":V()}],"scroll-mb":[{"scroll-mb":V()}],"scroll-ml":[{"scroll-ml":V()}],"scroll-p":[{"scroll-p":V()}],"scroll-px":[{"scroll-px":V()}],"scroll-py":[{"scroll-py":V()}],"scroll-ps":[{"scroll-ps":V()}],"scroll-pe":[{"scroll-pe":V()}],"scroll-pt":[{"scroll-pt":V()}],"scroll-pr":[{"scroll-pr":V()}],"scroll-pb":[{"scroll-pb":V()}],"scroll-pl":[{"scroll-pl":V()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","pinch-zoom","manipulation",{pan:["x","left","right","y","up","down"]}]}],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",xe]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[ht,wo]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}}var M0=p0(P0);function _e(...e){return M0(jc(e))}const Yc=u.forwardRef(({className:e,...t},n)=>L.jsx("span",{className:"rabbit-ds",children:L.jsx(Lc,{ref:n,className:_e("h-4 w-4 shrink-0 rounded-sm border-2 border-[#104F95] ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:bg-[#104F95] data-[state=checked]:text-white",e,"rabbit-ds"),...t,children:L.jsx(Kg,{className:_e("flex items-center justify-center text-current rabbit-ds"),children:L.jsx(pa,{className:"h-3 w-3"})})})}));Yc.displayName=Lc.displayName;const Kc=Yc,Xc=u.forwardRef((e,t)=>{const{pressed:n,defaultPressed:r=!1,onPressedChange:o,...i}=e,[a=!1,s]=St({prop:n,onChange:o,defaultProp:r});return u.createElement(we.button,ee({type:"button","aria-pressed":a,"data-state":a?"on":"off","data-disabled":e.disabled?"":void 0},i,{ref:t,onClick:fe(e.onClick,()=>{e.disabled||s(!a)})}))}),k0=Xc;function O0({icon:e,count:t,label:n,selected:r=!1,onSelectedChange:o}){return L.jsx("div",{className:"rabbit-ds h-7 flex-col w-auto p-0 rounded-full border-0 justify-center items-center inline-flex hover:cursor-pointer focus:outline-1 focus:outline-offset-2",children:L.jsx(k0,{defaultPressed:r,asChild:!0,onPressedChange:o,className:_e("px-4 py-1 rounded-full border flex-row justify-start items-center gap-2.5 flex","data-[state=off]:border-gray-100 data-[state=off]:bg-gray-100 data-[state=off]:text-dove-gray-500","data-[state=on]:border-sky-800 data-[state=on]:bg-sky-100 data-[state=on]:text-sky-800"),children:L.jsxs("div",{children:[e?L.jsx("div",{className:"w-4 h-4 justify-center items-center flex",children:e}):null,L.jsxs("div",{className:"text-sm leading-tight font-semibold",children:[n?L.jsx("span",{children:n}):null," ",t?L.jsxs("span",{children:["(",t,")"]}):null]})]})})})}const Rc=e=>typeof e=="boolean"?"".concat(e):e===0?"0":e,Zc=jc,Qc=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return Zc(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:o,defaultVariants:i}=t,a=Object.keys(o).map(c=>{const d=n==null?void 0:n[c],f=i==null?void 0:i[c];if(d===null)return null;const p=Rc(d)||Rc(f);return o[c][p]}),s=n&&Object.entries(n).reduce((c,d)=>{let[f,p]=d;return p===void 0||(c[f]=p),c},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((c,d)=>{let{class:f,className:p,...m}=d;return Object.entries(m).every(h=>{let[v,x]=h;return Array.isArray(x)?x.includes({...i,...s}[v]):{...i,...s}[v]===x})?[...c,f,p]:c},[]);return Zc(e,a,l,n==null?void 0:n.class,n==null?void 0:n.className)},_0=Qc("rabbit-ds font-sans px-4 py-2 rounded text-sm font-semibold justify-center items-center gap-1 inline-flex transition-colors focus:outline-1 focus:outline-offset-2 disabled:pointer-events-none",{variants:{variant:{filled:"",outline:"",text:""},status:{default:"",error:""},size:{normal:"h-10",small:"h-7"}},compoundVariants:[{variant:"filled",status:"default",className:"bg-[#1565BC] text-white hover:bg-[#125AA9] focus:bg-[#104F95] disabled:bg-[#99D2F9]"},{variant:"filled",status:"error",className:"bg-[#C62C02] text-white hover:bg-[#AA2602] focus:bg-[#A12402] disabled:bg-[#F6B9B9]"},{variant:"outline",status:"default",className:"bg-white text-[#1565BC] border border-[#1565BC] hover:text-[#125AA9] hover:border-[#125AA9] focus:border-[#104F95] focus:text-[#104F95] disabled:border-[#104F95] disabled:text-[#104F95]"},{variant:"outline",status:"error",className:"bg-white text-[#C62C02] border border-[#C62C02] hover:text-[#AA2602] hover:border-[#AA2602] focus:border-[#A12402] focus:text-[#A12402] disabled:border-[#F6B9B9] disabled:text-[#F6B9B9]"},{variant:"text",status:"default",className:"bg-white text-[#1565BC] border-0 hover:text-[#125AA9] focus:text-[#104F95] disabled:text-[#104F95]"},{variant:"text",status:"error",className:"bg-white text-[#C62C02] border-0 hover:text-[#AA2602] focus:text-[#A12402] disabled:text-[#F6B9B9]"}],defaultVariants:{variant:"filled",status:"default",size:"normal"}}),Jc=Qc("",{variants:{size:{normal:"h-4 w-4",small:"h-3 w-3"}},defaultVariants:{size:"normal"}}),ga=u.forwardRef(({className:e,variant:t,iconLeft:n,iconRight:r,status:o,size:i,asChild:a=!1,children:s,...l},c)=>{const d=a?yn:"button";return L.jsx("div",{className:"rabbit-ds",children:L.jsxs(d,{className:_e(_0({variant:t,className:e,size:i,status:o})),ref:c,...l,children:[n?L.jsx("div",{className:_e(Jc({size:i})),children:n}):null,s,r?L.jsx("div",{className:_e(Jc({size:i})),children:r}):null]})})});ga.displayName="Button",ga.defaultProps={asChild:!1,iconLeft:void 0,iconRight:void 0};const N0=ga,ya=u.forwardRef(({className:e,type:t,...n},r)=>L.jsxs("div",{className:"rabbit-ds relative font-sans",children:[t==="search"?L.jsx("div",{className:"absolute text-neutral-400 inset-y-0 left-0 mx-2 pointer-events-none w-5 h-5 my-auto p-0.5 justify-center items-center flex",children:L.jsx(e0,{})}):null,L.jsx("input",{type:t,className:_e("text-sm min-w-[224px] w-full h-10 px-3 py-2.5 bg-white rounded border border-neutral-400 gap-2.5 focus:outline-none hover:outline-none focus:border-sky-700 hover:border-sky-700 disabled:pointer-events-none disabled:bg-neutral-50 disabled:border-neutral-100 disable:text-neutral-400",e,t==="search"?"pl-8":""),ref:r,...n})]}));ya.displayName="Input",ya.defaultProps={className:""};const A0=ya;function ba(e){const t=e+"CollectionProvider",[n,r]=Ct(t),[o,i]=n(t,{collectionRef:{current:null},itemMap:new Map}),a=m=>{const{scope:h,children:v}=m,x=u.useRef(null),y=u.useRef(new Map).current;return u.createElement(o,{scope:h,itemMap:y,collectionRef:x},v)},s=e+"CollectionSlot",l=u.forwardRef((m,h)=>{const{scope:v,children:x}=m,y=i(s,v),b=Oe(h,y.collectionRef);return u.createElement(yn,{ref:b},x)}),c=e+"CollectionItemSlot",d="data-radix-collection-item",f=u.forwardRef((m,h)=>{const{scope:v,children:x,...y}=m,b=u.useRef(null),$=Oe(h,b),S=i(c,v);return u.useEffect(()=>(S.itemMap.set(b,{ref:b,...y}),()=>void S.itemMap.delete(b))),u.createElement(yn,{[d]:"",ref:$},x)});function p(m){const h=i(e+"CollectionConsumer",m);return u.useCallback(()=>{const x=h.collectionRef.current;if(!x)return[];const y=Array.from(x.querySelectorAll(`[${d}]`));return Array.from(h.itemMap.values()).sort((S,w)=>y.indexOf(S.ref.current)-y.indexOf(w.ref.current))},[h.collectionRef,h.itemMap])}return[{Provider:a,Slot:l,ItemSlot:f},p,r]}const D0=u.createContext(void 0);function $o(e){const t=u.useContext(D0);return e||t||"ltr"}function eu(e,t=globalThis==null?void 0:globalThis.document){const n=He(e);u.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return t.addEventListener("keydown",r),()=>t.removeEventListener("keydown",r)},[n,t])}const xa="dismissableLayer.update",I0="dismissableLayer.pointerDownOutside",L0="dismissableLayer.focusOutside";let tu;const F0=u.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),nu=u.forwardRef((e,t)=>{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:i,onFocusOutside:a,onInteractOutside:s,onDismiss:l,...c}=e,d=u.useContext(F0),[f,p]=u.useState(null),m=(n=f==null?void 0:f.ownerDocument)!==null&&n!==void 0?n:globalThis==null?void 0:globalThis.document,[,h]=u.useState({}),v=Oe(t,P=>p(P)),x=Array.from(d.layers),[y]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),b=x.indexOf(y),$=f?x.indexOf(f):-1,S=d.layersWithOutsidePointerEventsDisabled.size>0,w=$>=b,T=j0(P=>{const _=P.target,j=[...d.branches].some(F=>F.contains(_));!w||j||(i==null||i(P),s==null||s(P),P.defaultPrevented||l==null||l())},m),O=z0(P=>{const _=P.target;[...d.branches].some(F=>F.contains(_))||(a==null||a(P),s==null||s(P),P.defaultPrevented||l==null||l())},m);return eu(P=>{$===d.layers.size-1&&(o==null||o(P),!P.defaultPrevented&&l&&(P.preventDefault(),l()))},m),u.useEffect(()=>{if(f)return r&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(tu=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),ru(),()=>{r&&d.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=tu)}},[f,m,r,d]),u.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),ru())},[f,d]),u.useEffect(()=>{const P=()=>h({});return document.addEventListener(xa,P),()=>document.removeEventListener(xa,P)},[]),u.createElement(we.div,ee({},c,{ref:v,style:{pointerEvents:S?w?"auto":"none":void 0,...e.style},onFocusCapture:fe(e.onFocusCapture,O.onFocusCapture),onBlurCapture:fe(e.onBlurCapture,O.onBlurCapture),onPointerDownCapture:fe(e.onPointerDownCapture,T.onPointerDownCapture)}))});function j0(e,t=globalThis==null?void 0:globalThis.document){const n=He(e),r=u.useRef(!1),o=u.useRef(()=>{});return u.useEffect(()=>{const i=s=>{if(s.target&&!r.current){let c=function(){ou(I0,n,l,{discrete:!0})};const l={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}else t.removeEventListener("click",o.current);r.current=!1},a=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",i),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function z0(e,t=globalThis==null?void 0:globalThis.document){const n=He(e),r=u.useRef(!1);return u.useEffect(()=>{const o=i=>{i.target&&!r.current&&ou(L0,n,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function ru(){const e=new CustomEvent(xa);document.dispatchEvent(e)}function ou(e,t,n,{discrete:r}){const o=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?fa(o,i):o.dispatchEvent(i)}let wa=0;function iu(){u.useEffect(()=>{var e,t;const n=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",(e=n[0])!==null&&e!==void 0?e:au()),document.body.insertAdjacentElement("beforeend",(t=n[1])!==null&&t!==void 0?t:au()),wa++,()=>{wa===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(r=>r.remove()),wa--}},[])}function au(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.cssText="outline: none; opacity: 0; position: fixed; pointer-events: none",e}const $a="focusScope.autoFocusOnMount",Ca="focusScope.autoFocusOnUnmount",su={bubbles:!1,cancelable:!0},lu=u.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:o,onUnmountAutoFocus:i,...a}=e,[s,l]=u.useState(null),c=He(o),d=He(i),f=u.useRef(null),p=Oe(t,v=>l(v)),m=u.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;u.useEffect(()=>{if(r){let v=function($){if(m.paused||!s)return;const S=$.target;s.contains(S)?f.current=S:Jt(f.current,{select:!0})},x=function($){if(m.paused||!s)return;const S=$.relatedTarget;S!==null&&(s.contains(S)||Jt(f.current,{select:!0}))},y=function($){if(document.activeElement===document.body)for(const w of $)w.removedNodes.length>0&&Jt(s)};document.addEventListener("focusin",v),document.addEventListener("focusout",x);const b=new MutationObserver(y);return s&&b.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",v),document.removeEventListener("focusout",x),b.disconnect()}}},[r,s,m.paused]),u.useEffect(()=>{if(s){du.add(m);const v=document.activeElement;if(!s.contains(v)){const y=new CustomEvent($a,su);s.addEventListener($a,c),s.dispatchEvent(y),y.defaultPrevented||(W0(V0(cu(s)),{select:!0}),document.activeElement===v&&Jt(s))}return()=>{s.removeEventListener($a,c),setTimeout(()=>{const y=new CustomEvent(Ca,su);s.addEventListener(Ca,d),s.dispatchEvent(y),y.defaultPrevented||Jt(v??document.body,{select:!0}),s.removeEventListener(Ca,d),du.remove(m)},0)}}},[s,c,d,m]);const h=u.useCallback(v=>{if(!n&&!r||m.paused)return;const x=v.key==="Tab"&&!v.altKey&&!v.ctrlKey&&!v.metaKey,y=document.activeElement;if(x&&y){const b=v.currentTarget,[$,S]=B0(b);$&&S?!v.shiftKey&&y===S?(v.preventDefault(),n&&Jt($,{select:!0})):v.shiftKey&&y===$&&(v.preventDefault(),n&&Jt(S,{select:!0})):y===b&&v.preventDefault()}},[n,r,m.paused]);return u.createElement(we.div,ee({tabIndex:-1},a,{ref:p,onKeyDown:h}))});function W0(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Jt(r,{select:t}),document.activeElement!==n)return}function B0(e){const t=cu(e),n=uu(t,e),r=uu(t.reverse(),e);return[n,r]}function cu(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function uu(e,t){for(const n of e)if(!U0(n,{upTo:t}))return n}function U0(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function H0(e){return e instanceof HTMLInputElement&&"select"in e}function Jt(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&H0(e)&&t&&e.select()}}const du=G0();function G0(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=fu(e,t),e.unshift(t)},remove(t){var n;e=fu(e,t),(n=e[0])===null||n===void 0||n.resume()}}}function fu(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function V0(e){return e.filter(t=>t.tagName!=="A")}const q0=me["useId".toString()]||(()=>{});let Y0=0;function Dt(e){const[t,n]=me.useState(q0());return ot(()=>{e||n(r=>r??String(Y0++))},[e]),e||(t?`radix-${t}`:"")}const K0=["top","right","bottom","left"],en=Math.min,it=Math.max,Co=Math.round,So=Math.floor,tn=e=>({x:e,y:e}),X0={left:"right",right:"left",bottom:"top",top:"bottom"},R0={start:"end",end:"start"};function Sa(e,t,n){return it(e,en(t,n))}function It(e,t){return typeof e=="function"?e(t):e}function Lt(e){return e.split("-")[0]}function Hn(e){return e.split("-")[1]}function Ea(e){return e==="x"?"y":"x"}function Ta(e){return e==="y"?"height":"width"}function Gn(e){return["top","bottom"].includes(Lt(e))?"y":"x"}function Pa(e){return Ea(Gn(e))}function Z0(e,t,n){n===void 0&&(n=!1);const r=Hn(e),o=Pa(e),i=Ta(o);let a=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(a=Eo(a)),[a,Eo(a)]}function Q0(e){const t=Eo(e);return[Ma(e),t,Ma(t)]}function Ma(e){return e.replace(/start|end/g,t=>R0[t])}function J0(e,t,n){const r=["left","right"],o=["right","left"],i=["top","bottom"],a=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?i:a;default:return[]}}function ey(e,t,n,r){const o=Hn(e);let i=J0(Lt(e),n==="start",r);return o&&(i=i.map(a=>a+"-"+o),t&&(i=i.concat(i.map(Ma)))),i}function Eo(e){return e.replace(/left|right|bottom|top/g,t=>X0[t])}function ty(e){return{top:0,right:0,bottom:0,left:0,...e}}function pu(e){return typeof e!="number"?ty(e):{top:e,right:e,bottom:e,left:e}}function To(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function hu(e,t,n){let{reference:r,floating:o}=e;const i=Gn(t),a=Pa(t),s=Ta(a),l=Lt(t),c=i==="y",d=r.x+r.width/2-o.width/2,f=r.y+r.height/2-o.height/2,p=r[s]/2-o[s]/2;let m;switch(l){case"top":m={x:d,y:r.y-o.height};break;case"bottom":m={x:d,y:r.y+r.height};break;case"right":m={x:r.x+r.width,y:f};break;case"left":m={x:r.x-o.width,y:f};break;default:m={x:r.x,y:r.y}}switch(Hn(t)){case"start":m[a]-=p*(n&&c?-1:1);break;case"end":m[a]+=p*(n&&c?-1:1);break}return m}const ny=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:a}=n,s=i.filter(Boolean),l=await(a.isRTL==null?void 0:a.isRTL(t));let c=await a.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:f}=hu(c,r,l),p=r,m={},h=0;for(let v=0;v<s.length;v++){const{name:x,fn:y}=s[v],{x:b,y:$,data:S,reset:w}=await y({x:d,y:f,initialPlacement:r,placement:p,strategy:o,middlewareData:m,rects:c,platform:a,elements:{reference:e,floating:t}});if(d=b??d,f=$??f,m={...m,[x]:{...m[x],...S}},w&&h<=50){h++,typeof w=="object"&&(w.placement&&(p=w.placement),w.rects&&(c=w.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:o}):w.rects),{x:d,y:f}=hu(c,p,l)),v=-1;continue}}return{x:d,y:f,placement:p,strategy:o,middlewareData:m}};async function Tr(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:i,rects:a,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:f="floating",altBoundary:p=!1,padding:m=0}=It(t,e),h=pu(m),x=s[p?f==="floating"?"reference":"floating":f],y=To(await i.getClippingRect({element:(n=await(i.isElement==null?void 0:i.isElement(x)))==null||n?x:x.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(s.floating)),boundary:c,rootBoundary:d,strategy:l})),b=f==="floating"?{...a.floating,x:r,y:o}:a.reference,$=await(i.getOffsetParent==null?void 0:i.getOffsetParent(s.floating)),S=await(i.isElement==null?void 0:i.isElement($))?await(i.getScale==null?void 0:i.getScale($))||{x:1,y:1}:{x:1,y:1},w=To(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({rect:b,offsetParent:$,strategy:l}):b);return{top:(y.top-w.top+h.top)/S.y,bottom:(w.bottom-y.bottom+h.bottom)/S.y,left:(y.left-w.left+h.left)/S.x,right:(w.right-y.right+h.right)/S.x}}const mu=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:i,platform:a,elements:s}=t,{element:l,padding:c=0}=It(e,t)||{};if(l==null)return{};const d=pu(c),f={x:n,y:r},p=Pa(o),m=Ta(p),h=await a.getDimensions(l),v=p==="y",x=v?"top":"left",y=v?"bottom":"right",b=v?"clientHeight":"clientWidth",$=i.reference[m]+i.reference[p]-f[p]-i.floating[m],S=f[p]-i.reference[p],w=await(a.getOffsetParent==null?void 0:a.getOffsetParent(l));let T=w?w[b]:0;(!T||!await(a.isElement==null?void 0:a.isElement(w)))&&(T=s.floating[b]||i.floating[m]);const O=$/2-S/2,P=T/2-h[m]/2-1,_=en(d[x],P),j=en(d[y],P),F=_,V=T-h[m]-j,R=T/2-h[m]/2+O,X=Sa(F,R,V),I=Hn(o)!=null&&R!=X&&i.reference[m]/2-(R<F?_:j)-h[m]/2<0?R<F?F-R:V-R:0;return{[p]:f[p]-I,data:{[p]:X,centerOffset:R-X+I}}}}),vu=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n;const{placement:r,middlewareData:o,rects:i,initialPlacement:a,platform:s,elements:l}=t,{mainAxis:c=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:h=!0,...v}=It(e,t),x=Lt(r),y=Lt(a)===a,b=await(s.isRTL==null?void 0:s.isRTL(l.floating)),$=f||(y||!h?[Eo(a)]:Q0(a));!f&&m!=="none"&&$.push(...ey(a,h,m,b));const S=[a,...$],w=await Tr(t,v),T=[];let O=((n=o.flip)==null?void 0:n.overflows)||[];if(c&&T.push(w[x]),d){const F=Z0(r,i,b);T.push(w[F[0]],w[F[1]])}if(O=[...O,{placement:r,overflows:T}],!T.every(F=>F<=0)){var P,_;const F=(((P=o.flip)==null?void 0:P.index)||0)+1,V=S[F];if(V)return{data:{index:F,overflows:O},reset:{placement:V}};let R=(_=O.filter(X=>X.overflows[0]<=0).sort((X,C)=>X.overflows[1]-C.overflows[1])[0])==null?void 0:_.placement;if(!R)switch(p){case"bestFit":{var j;const X=(j=O.map(C=>[C.placement,C.overflows.filter(I=>I>0).reduce((I,H)=>I+H,0)]).sort((C,I)=>C[1]-I[1])[0])==null?void 0:j[0];X&&(R=X);break}case"initialPlacement":R=a;break}if(r!==R)return{reset:{placement:R}}}return{}}}};function gu(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function yu(e){return K0.some(t=>e[t]>=0)}const bu=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...o}=It(e,t);switch(r){case"referenceHidden":{const i=await Tr(t,{...o,elementContext:"reference"}),a=gu(i,n.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:yu(a)}}}case"escaped":{const i=await Tr(t,{...o,altBoundary:!0}),a=gu(i,n.floating);return{data:{escapedOffsets:a,escaped:yu(a)}}}default:return{}}}}};async function ry(e,t){const{placement:n,platform:r,elements:o}=e,i=await(r.isRTL==null?void 0:r.isRTL(o.floating)),a=Lt(n),s=Hn(n),l=Gn(n)==="y",c=["left","top"].includes(a)?-1:1,d=i&&l?-1:1,f=It(t,e);let{mainAxis:p,crossAxis:m,alignmentAxis:h}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...f};return s&&typeof h=="number"&&(m=s==="end"?h*-1:h),l?{x:m*d,y:p*c}:{x:p*c,y:m*d}}const xu=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){const{x:n,y:r}=t,o=await ry(t,e);return{x:n+o.x,y:r+o.y,data:o}}}},wu=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:i=!0,crossAxis:a=!1,limiter:s={fn:x=>{let{x:y,y:b}=x;return{x:y,y:b}}},...l}=It(e,t),c={x:n,y:r},d=await Tr(t,l),f=Gn(Lt(o)),p=Ea(f);let m=c[p],h=c[f];if(i){const x=p==="y"?"top":"left",y=p==="y"?"bottom":"right",b=m+d[x],$=m-d[y];m=Sa(b,m,$)}if(a){const x=f==="y"?"top":"left",y=f==="y"?"bottom":"right",b=h+d[x],$=h-d[y];h=Sa(b,h,$)}const v=s.fn({...t,[p]:m,[f]:h});return{...v,data:{x:v.x-n,y:v.y-r}}}}},$u=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:i,middlewareData:a}=t,{offset:s=0,mainAxis:l=!0,crossAxis:c=!0}=It(e,t),d={x:n,y:r},f=Gn(o),p=Ea(f);let m=d[p],h=d[f];const v=It(s,t),x=typeof v=="number"?{mainAxis:v,crossAxis:0}:{mainAxis:0,crossAxis:0,...v};if(l){const $=p==="y"?"height":"width",S=i.reference[p]-i.floating[$]+x.mainAxis,w=i.reference[p]+i.reference[$]-x.mainAxis;m<S?m=S:m>w&&(m=w)}if(c){var y,b;const $=p==="y"?"width":"height",S=["top","left"].includes(Lt(o)),w=i.reference[f]-i.floating[$]+(S&&((y=a.offset)==null?void 0:y[f])||0)+(S?0:x.crossAxis),T=i.reference[f]+i.reference[$]+(S?0:((b=a.offset)==null?void 0:b[f])||0)-(S?x.crossAxis:0);h<w?h=w:h>T&&(h=T)}return{[p]:m,[f]:h}}}},Cu=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:o,elements:i}=t,{apply:a=()=>{},...s}=It(e,t),l=await Tr(t,s),c=Lt(n),d=Hn(n),f=Gn(n)==="y",{width:p,height:m}=r.floating;let h,v;c==="top"||c==="bottom"?(h=c,v=d===(await(o.isRTL==null?void 0:o.isRTL(i.floating))?"start":"end")?"left":"right"):(v=c,h=d==="end"?"top":"bottom");const x=m-l[h],y=p-l[v],b=!t.middlewareData.shift;let $=x,S=y;if(f){const T=p-l.left-l.right;S=d||b?en(y,T):T}else{const T=m-l.top-l.bottom;$=d||b?en(x,T):T}if(b&&!d){const T=it(l.left,0),O=it(l.right,0),P=it(l.top,0),_=it(l.bottom,0);f?S=p-2*(T!==0||O!==0?T+O:it(l.left,l.right)):$=m-2*(P!==0||_!==0?P+_:it(l.top,l.bottom))}await a({...t,availableWidth:S,availableHeight:$});const w=await o.getDimensions(i.floating);return p!==w.width||m!==w.height?{reset:{rects:!0}}:{}}}};function nn(e){return Su(e)?(e.nodeName||"").toLowerCase():"#document"}function at(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ft(e){var t;return(t=(Su(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Su(e){return e instanceof Node||e instanceof at(e).Node}function jt(e){return e instanceof Element||e instanceof at(e).Element}function Et(e){return e instanceof HTMLElement||e instanceof at(e).HTMLElement}function Eu(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof at(e).ShadowRoot}function Pr(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=ct(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function oy(e){return["table","td","th"].includes(nn(e))}function ka(e){const t=Oa(),n=ct(e);return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(r=>(n.willChange||"").includes(r))||["paint","layout","strict","content"].some(r=>(n.contain||"").includes(r))}function iy(e){let t=Vn(e);for(;Et(t)&&!Po(t);){if(ka(t))return t;t=Vn(t)}return null}function Oa(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function Po(e){return["html","body","#document"].includes(nn(e))}function ct(e){return at(e).getComputedStyle(e)}function Mo(e){return jt(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function Vn(e){if(nn(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Eu(e)&&e.host||Ft(e);return Eu(t)?t.host:t}function Tu(e){const t=Vn(e);return Po(t)?e.ownerDocument?e.ownerDocument.body:e.body:Et(t)&&Pr(t)?t:Tu(t)}function ko(e,t){var n;t===void 0&&(t=[]);const r=Tu(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),i=at(r);return o?t.concat(i,i.visualViewport||[],Pr(r)?r:[]):t.concat(r,ko(r))}function Pu(e){const t=ct(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=Et(e),i=o?e.offsetWidth:n,a=o?e.offsetHeight:r,s=Co(n)!==i||Co(r)!==a;return s&&(n=i,r=a),{width:n,height:r,$:s}}function _a(e){return jt(e)?e:e.contextElement}function qn(e){const t=_a(e);if(!Et(t))return tn(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:i}=Pu(t);let a=(i?Co(n.width):n.width)/r,s=(i?Co(n.height):n.height)/o;return(!a||!Number.isFinite(a))&&(a=1),(!s||!Number.isFinite(s))&&(s=1),{x:a,y:s}}const ay=tn(0);function Mu(e){const t=at(e);return!Oa()||!t.visualViewport?ay:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function sy(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==at(e)?!1:t}function $n(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),i=_a(e);let a=tn(1);t&&(r?jt(r)&&(a=qn(r)):a=qn(e));const s=sy(i,n,r)?Mu(i):tn(0);let l=(o.left+s.x)/a.x,c=(o.top+s.y)/a.y,d=o.width/a.x,f=o.height/a.y;if(i){const p=at(i),m=r&&jt(r)?at(r):r;let h=p.frameElement;for(;h&&r&&m!==p;){const v=qn(h),x=h.getBoundingClientRect(),y=ct(h),b=x.left+(h.clientLeft+parseFloat(y.paddingLeft))*v.x,$=x.top+(h.clientTop+parseFloat(y.paddingTop))*v.y;l*=v.x,c*=v.y,d*=v.x,f*=v.y,l+=b,c+=$,h=at(h).frameElement}}return To({width:d,height:f,x:l,y:c})}function ly(e){let{rect:t,offsetParent:n,strategy:r}=e;const o=Et(n),i=Ft(n);if(n===i)return t;let a={scrollLeft:0,scrollTop:0},s=tn(1);const l=tn(0);if((o||!o&&r!=="fixed")&&((nn(n)!=="body"||Pr(i))&&(a=Mo(n)),Et(n))){const c=$n(n);s=qn(n),l.x=c.x+n.clientLeft,l.y=c.y+n.clientTop}return{width:t.width*s.x,height:t.height*s.y,x:t.x*s.x-a.scrollLeft*s.x+l.x,y:t.y*s.y-a.scrollTop*s.y+l.y}}function cy(e){return Array.from(e.getClientRects())}function ku(e){return $n(Ft(e)).left+Mo(e).scrollLeft}function uy(e){const t=Ft(e),n=Mo(e),r=e.ownerDocument.body,o=it(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),i=it(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+ku(e);const s=-n.scrollTop;return ct(r).direction==="rtl"&&(a+=it(t.clientWidth,r.clientWidth)-o),{width:o,height:i,x:a,y:s}}function dy(e,t){const n=at(e),r=Ft(e),o=n.visualViewport;let i=r.clientWidth,a=r.clientHeight,s=0,l=0;if(o){i=o.width,a=o.height;const c=Oa();(!c||c&&t==="fixed")&&(s=o.offsetLeft,l=o.offsetTop)}return{width:i,height:a,x:s,y:l}}function fy(e,t){const n=$n(e,!0,t==="fixed"),r=n.top+e.clientTop,o=n.left+e.clientLeft,i=Et(e)?qn(e):tn(1),a=e.clientWidth*i.x,s=e.clientHeight*i.y,l=o*i.x,c=r*i.y;return{width:a,height:s,x:l,y:c}}function Ou(e,t,n){let r;if(t==="viewport")r=dy(e,n);else if(t==="document")r=uy(Ft(e));else if(jt(t))r=fy(t,n);else{const o=Mu(e);r={...t,x:t.x-o.x,y:t.y-o.y}}return To(r)}function _u(e,t){const n=Vn(e);return n===t||!jt(n)||Po(n)?!1:ct(n).position==="fixed"||_u(n,t)}function py(e,t){const n=t.get(e);if(n)return n;let r=ko(e).filter(s=>jt(s)&&nn(s)!=="body"),o=null;const i=ct(e).position==="fixed";let a=i?Vn(e):e;for(;jt(a)&&!Po(a);){const s=ct(a),l=ka(a);!l&&s.position==="fixed"&&(o=null),(i?!l&&!o:!l&&s.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Pr(a)&&!l&&_u(e,a))?r=r.filter(d=>d!==a):o=s,a=Vn(a)}return t.set(e,r),r}function hy(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const a=[...n==="clippingAncestors"?py(t,this._c):[].concat(n),r],s=a[0],l=a.reduce((c,d)=>{const f=Ou(t,d,o);return c.top=it(f.top,c.top),c.right=en(f.right,c.right),c.bottom=en(f.bottom,c.bottom),c.left=it(f.left,c.left),c},Ou(t,s,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function my(e){return Pu(e)}function vy(e,t,n){const r=Et(t),o=Ft(t),i=n==="fixed",a=$n(e,!0,i,t);let s={scrollLeft:0,scrollTop:0};const l=tn(0);if(r||!r&&!i)if((nn(t)!=="body"||Pr(o))&&(s=Mo(t)),r){const c=$n(t,!0,i,t);l.x=c.x+t.clientLeft,l.y=c.y+t.clientTop}else o&&(l.x=ku(o));return{x:a.left+s.scrollLeft-l.x,y:a.top+s.scrollTop-l.y,width:a.width,height:a.height}}function Nu(e,t){return!Et(e)||ct(e).position==="fixed"?null:t?t(e):e.offsetParent}function Au(e,t){const n=at(e);if(!Et(e))return n;let r=Nu(e,t);for(;r&&oy(r)&&ct(r).position==="static";)r=Nu(r,t);return r&&(nn(r)==="html"||nn(r)==="body"&&ct(r).position==="static"&&!ka(r))?n:r||iy(e)||n}const gy=async function(e){let{reference:t,floating:n,strategy:r}=e;const o=this.getOffsetParent||Au,i=this.getDimensions;return{reference:vy(t,await o(n),r),floating:{x:0,y:0,...await i(n)}}};function yy(e){return ct(e).direction==="rtl"}const by={convertOffsetParentRelativeRectToViewportRelativeRect:ly,getDocumentElement:Ft,getClippingRect:hy,getOffsetParent:Au,getElementRects:gy,getClientRects:cy,getDimensions:my,getScale:qn,isElement:jt,isRTL:yy};function xy(e,t){let n=null,r;const o=Ft(e);function i(){clearTimeout(r),n&&n.disconnect(),n=null}function a(s,l){s===void 0&&(s=!1),l===void 0&&(l=1),i();const{left:c,top:d,width:f,height:p}=e.getBoundingClientRect();if(s||t(),!f||!p)return;const m=So(d),h=So(o.clientWidth-(c+f)),v=So(o.clientHeight-(d+p)),x=So(c),b={rootMargin:-m+"px "+-h+"px "+-v+"px "+-x+"px",threshold:it(0,en(1,l))||1};let $=!0;function S(w){const T=w[0].intersectionRatio;if(T!==l){if(!$)return a();T?a(!1,T):r=setTimeout(()=>{a(!1,1e-7)},100)}$=!1}try{n=new IntersectionObserver(S,{...b,root:o.ownerDocument})}catch{n=new IntersectionObserver(S,b)}n.observe(e)}return a(!0),i}function Du(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:i=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,c=_a(e),d=o||i?[...c?ko(c):[],...ko(t)]:[];d.forEach(y=>{o&&y.addEventListener("scroll",n,{passive:!0}),i&&y.addEventListener("resize",n)});const f=c&&s?xy(c,n):null;let p=-1,m=null;a&&(m=new ResizeObserver(y=>{let[b]=y;b&&b.target===c&&m&&(m.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{m&&m.observe(t)})),n()}),c&&!l&&m.observe(c),m.observe(t));let h,v=l?$n(e):null;l&&x();function x(){const y=$n(e);v&&(y.x!==v.x||y.y!==v.y||y.width!==v.width||y.height!==v.height)&&n(),v=y,h=requestAnimationFrame(x)}return n(),()=>{d.forEach(y=>{o&&y.removeEventListener("scroll",n),i&&y.removeEventListener("resize",n)}),f&&f(),m&&m.disconnect(),m=null,l&&cancelAnimationFrame(h)}}const wy=(e,t,n)=>{const r=new Map,o={platform:by,...n},i={...o.platform,_c:r};return ny(e,t,{...o,platform:i})},Iu=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:o}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?mu({element:r.current,padding:o}).fn(n):{}:r?mu({element:r,padding:o}).fn(n):{}}}};var Oo=typeof document<"u"?u.useLayoutEffect:u.useEffect;function _o(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!_o(e[r],t[r]))return!1;return!0}if(o=Object.keys(e),n=o.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,o[r]))return!1;for(r=n;r--!==0;){const i=o[r];if(!(i==="_owner"&&e.$$typeof)&&!_o(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function Lu(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Fu(e,t){const n=Lu(e);return Math.round(t*n)/n}function ju(e){const t=me.useRef(e);return Oo(()=>{t.current=e}),t}function zu(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:i,floating:a}={},transform:s=!0,whileElementsMounted:l,open:c}=e,[d,f]=me.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,m]=me.useState(r);_o(p,r)||m(r);const[h,v]=me.useState(null),[x,y]=me.useState(null),b=me.useCallback(I=>{I!=T.current&&(T.current=I,v(I))},[v]),$=me.useCallback(I=>{I!==O.current&&(O.current=I,y(I))},[y]),S=i||h,w=a||x,T=me.useRef(null),O=me.useRef(null),P=me.useRef(d),_=ju(l),j=ju(o),F=me.useCallback(()=>{if(!T.current||!O.current)return;const I={placement:t,strategy:n,middleware:p};j.current&&(I.platform=j.current),wy(T.current,O.current,I).then(H=>{const B={...H,isPositioned:!0};V.current&&!_o(P.current,B)&&(P.current=B,Ag.flushSync(()=>{f(B)}))})},[p,t,n,j]);Oo(()=>{c===!1&&P.current.isPositioned&&(P.current.isPositioned=!1,f(I=>({...I,isPositioned:!1})))},[c]);const V=me.useRef(!1);Oo(()=>(V.current=!0,()=>{V.current=!1}),[]),Oo(()=>{if(S&&(T.current=S),w&&(O.current=w),S&&w){if(_.current)return _.current(S,w,F);F()}},[S,w,F,_]);const R=me.useMemo(()=>({reference:T,floating:O,setReference:b,setFloating:$}),[b,$]),X=me.useMemo(()=>({reference:S,floating:w}),[S,w]),C=me.useMemo(()=>{const I={position:n,left:0,top:0};if(!X.floating)return I;const H=Fu(X.floating,d.x),B=Fu(X.floating,d.y);return s?{...I,transform:"translate("+H+"px, "+B+"px)",...Lu(X.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:H,top:B}},[n,s,X.floating,d.x,d.y]);return me.useMemo(()=>({...d,update:F,refs:R,elements:X,floatingStyles:C}),[d,F,R,X,C])}const Wu="Popper",[Bu,No]=Ct(Wu),[$y,Uu]=Bu(Wu),Cy=e=>{const{__scopePopper:t,children:n}=e,[r,o]=u.useState(null);return u.createElement($y,{scope:t,anchor:r,onAnchorChange:o},n)},Sy="PopperAnchor",Ey=u.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,i=Uu(Sy,n),a=u.useRef(null),s=Oe(t,a);return u.useEffect(()=>{i.onAnchorChange((r==null?void 0:r.current)||a.current)}),r?null:u.createElement(we.div,ee({},o,{ref:s}))}),Hu="PopperContent",[Ty,K3]=Bu(Hu),Py=u.forwardRef((e,t)=>{var n,r,o,i,a,s,l,c;const{__scopePopper:d,side:f="bottom",sideOffset:p=0,align:m="center",alignOffset:h=0,arrowPadding:v=0,avoidCollisions:x=!0,collisionBoundary:y=[],collisionPadding:b=0,sticky:$="partial",hideWhenDetached:S=!1,updatePositionStrategy:w="optimized",onPlaced:T,...O}=e,P=Uu(Hu,d),[_,j]=u.useState(null),F=Oe(t,Ce=>j(Ce)),[V,R]=u.useState(null),X=ua(V),C=(n=X==null?void 0:X.width)!==null&&n!==void 0?n:0,I=(r=X==null?void 0:X.height)!==null&&r!==void 0?r:0,H=f+(m!=="center"?"-"+m:""),B=typeof b=="number"?b:{top:0,right:0,bottom:0,left:0,...b},A=Array.isArray(y)?y:[y],N=A.length>0,z={padding:B,boundary:A.filter(My),altBoundary:N},{refs:J,floatingStyles:Q,placement:oe,isPositioned:te,middlewareData:ae}=zu({strategy:"fixed",placement:H,whileElementsMounted:(...Ce)=>Du(...Ce,{animationFrame:w==="always"}),elements:{reference:P.anchor},middleware:[xu({mainAxis:p+I,alignmentAxis:h}),x&&wu({mainAxis:!0,crossAxis:!1,limiter:$==="partial"?$u():void 0,...z}),x&&vu({...z}),Cu({...z,apply:({elements:Ce,rects:ke,availableWidth:je,availableHeight:_t})=>{const{width:mn,height:Ze}=ke.reference,qt=Ce.floating.style;qt.setProperty("--radix-popper-available-width",`${je}px`),qt.setProperty("--radix-popper-available-height",`${_t}px`),qt.setProperty("--radix-popper-anchor-width",`${mn}px`),qt.setProperty("--radix-popper-anchor-height",`${Ze}px`)}}),V&&Iu({element:V,padding:v}),ky({arrowWidth:C,arrowHeight:I}),S&&bu({strategy:"referenceHidden",...z})]}),[Y,le]=Gu(oe),U=He(T);ot(()=>{te&&(U==null||U())},[te,U]);const q=(o=ae.arrow)===null||o===void 0?void 0:o.x,re=(i=ae.arrow)===null||i===void 0?void 0:i.y,k=((a=ae.arrow)===null||a===void 0?void 0:a.centerOffset)!==0,[de,pe]=u.useState();return ot(()=>{_&&pe(window.getComputedStyle(_).zIndex)},[_]),u.createElement("div",{ref:J.setFloating,"data-radix-popper-content-wrapper":"",style:{...Q,transform:te?Q.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:de,"--radix-popper-transform-origin":[(s=ae.transformOrigin)===null||s===void 0?void 0:s.x,(l=ae.transformOrigin)===null||l===void 0?void 0:l.y].join(" ")},dir:e.dir},u.createElement(Ty,{scope:d,placedSide:Y,onArrowChange:R,arrowX:q,arrowY:re,shouldHideArrow:k},u.createElement(we.div,ee({"data-side":Y,"data-align":le},O,{ref:F,style:{...O.style,animation:te?void 0:"none",opacity:(c=ae.hide)!==null&&c!==void 0&&c.referenceHidden?0:void 0}}))))});function My(e){return e!==null}const ky=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,i,a;const{placement:s,rects:l,middlewareData:c}=t,f=((n=c.arrow)===null||n===void 0?void 0:n.centerOffset)!==0,p=f?0:e.arrowWidth,m=f?0:e.arrowHeight,[h,v]=Gu(s),x={start:"0%",center:"50%",end:"100%"}[v],y=((r=(o=c.arrow)===null||o===void 0?void 0:o.x)!==null&&r!==void 0?r:0)+p/2,b=((i=(a=c.arrow)===null||a===void 0?void 0:a.y)!==null&&i!==void 0?i:0)+m/2;let $="",S="";return h==="bottom"?($=f?x:`${y}px`,S=`${-m}px`):h==="top"?($=f?x:`${y}px`,S=`${l.floating.height+m}px`):h==="right"?($=`${-m}px`,S=f?x:`${b}px`):h==="left"&&($=`${l.floating.width+m}px`,S=f?x:`${b}px`),{data:{x:$,y:S}}}});function Gu(e){const[t,n="center"]=e.split("-");return[t,n]}const Na=Cy,Vu=Ey,qu=Py,Yu=u.forwardRef((e,t)=>{var n;const{container:r=globalThis==null||(n=globalThis.document)===null||n===void 0?void 0:n.body,...o}=e;return r?At.createPortal(u.createElement(we.div,ee({},o,{ref:t})),r):null}),Aa="rovingFocusGroup.onEntryFocus",Oy={bubbles:!1,cancelable:!0},Da="RovingFocusGroup",[Ia,Ku,_y]=ba(Da),[Ny,Ao]=Ct(Da,[_y]),[Ay,Dy]=Ny(Da),Iy=u.forwardRef((e,t)=>u.createElement(Ia.Provider,{scope:e.__scopeRovingFocusGroup},u.createElement(Ia.Slot,{scope:e.__scopeRovingFocusGroup},u.createElement(Ly,ee({},e,{ref:t}))))),Ly=u.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:o=!1,dir:i,currentTabStopId:a,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:l,onEntryFocus:c,...d}=e,f=u.useRef(null),p=Oe(t,f),m=$o(i),[h=null,v]=St({prop:a,defaultProp:s,onChange:l}),[x,y]=u.useState(!1),b=He(c),$=Ku(n),S=u.useRef(!1),[w,T]=u.useState(0);return u.useEffect(()=>{const O=f.current;if(O)return O.addEventListener(Aa,b),()=>O.removeEventListener(Aa,b)},[b]),u.createElement(Ay,{scope:n,orientation:r,dir:m,loop:o,currentTabStopId:h,onItemFocus:u.useCallback(O=>v(O),[v]),onItemShiftTab:u.useCallback(()=>y(!0),[]),onFocusableItemAdd:u.useCallback(()=>T(O=>O+1),[]),onFocusableItemRemove:u.useCallback(()=>T(O=>O-1),[])},u.createElement(we.div,ee({tabIndex:x||w===0?-1:0,"data-orientation":r},d,{ref:p,style:{outline:"none",...e.style},onMouseDown:fe(e.onMouseDown,()=>{S.current=!0}),onFocus:fe(e.onFocus,O=>{const P=!S.current;if(O.target===O.currentTarget&&P&&!x){const _=new CustomEvent(Aa,Oy);if(O.currentTarget.dispatchEvent(_),!_.defaultPrevented){const j=$().filter(C=>C.focusable),F=j.find(C=>C.active),V=j.find(C=>C.id===h),X=[F,V,...j].filter(Boolean).map(C=>C.ref.current);Xu(X)}}S.current=!1}),onBlur:fe(e.onBlur,()=>y(!1))})))}),Fy="RovingFocusGroupItem",jy=u.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:o=!1,tabStopId:i,...a}=e,s=Dt(),l=i||s,c=Dy(Fy,n),d=c.currentTabStopId===l,f=Ku(n),{onFocusableItemAdd:p,onFocusableItemRemove:m}=c;return u.useEffect(()=>{if(r)return p(),()=>m()},[r,p,m]),u.createElement(Ia.ItemSlot,{scope:n,id:l,focusable:r,active:o},u.createElement(we.span,ee({tabIndex:d?0:-1,"data-orientation":c.orientation},a,{ref:t,onMouseDown:fe(e.onMouseDown,h=>{r?c.onItemFocus(l):h.preventDefault()}),onFocus:fe(e.onFocus,()=>c.onItemFocus(l)),onKeyDown:fe(e.onKeyDown,h=>{if(h.key==="Tab"&&h.shiftKey){c.onItemShiftTab();return}if(h.target!==h.currentTarget)return;const v=By(h,c.orientation,c.dir);if(v!==void 0){h.preventDefault();let y=f().filter(b=>b.focusable).map(b=>b.ref.current);if(v==="last")y.reverse();else if(v==="prev"||v==="next"){v==="prev"&&y.reverse();const b=y.indexOf(h.currentTarget);y=c.loop?Uy(y,b+1):y.slice(b+1)}setTimeout(()=>Xu(y))}})})))}),zy={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Wy(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function By(e,t,n){const r=Wy(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return zy[r]}function Xu(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function Uy(e,t){return e.map((n,r)=>e[(t+r)%e.length])}const Ru=Iy,Zu=jy;var Hy=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Yn=new WeakMap,Do=new WeakMap,Io={},La=0,Qu=function(e){return e&&(e.host||Qu(e.parentNode))},Gy=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=Qu(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},Vy=function(e,t,n,r){var o=Gy(t,Array.isArray(e)?e:[e]);Io[n]||(Io[n]=new WeakMap);var i=Io[n],a=[],s=new Set,l=new Set(o),c=function(f){!f||s.has(f)||(s.add(f),c(f.parentNode))};o.forEach(c);var d=function(f){!f||l.has(f)||Array.prototype.forEach.call(f.children,function(p){if(s.has(p))d(p);else{var m=p.getAttribute(r),h=m!==null&&m!=="false",v=(Yn.get(p)||0)+1,x=(i.get(p)||0)+1;Yn.set(p,v),i.set(p,x),a.push(p),v===1&&h&&Do.set(p,!0),x===1&&p.setAttribute(n,"true"),h||p.setAttribute(r,"true")}})};return d(t),s.clear(),La++,function(){a.forEach(function(f){var p=Yn.get(f)-1,m=i.get(f)-1;Yn.set(f,p),i.set(f,m),p||(Do.has(f)||f.removeAttribute(r),Do.delete(f)),m||f.removeAttribute(n)}),La--,La||(Yn=new WeakMap,Yn=new WeakMap,Do=new WeakMap,Io={})}},Ju=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=t||Hy(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live]"))),Vy(r,o,n,"aria-hidden")):function(){return null}},Tt=function(){return Tt=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])}return t},Tt.apply(this,arguments)};function ed(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function qy(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,i;r<o;r++)(i||!(r in t))&&(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var Lo="right-scroll-bar-position",Fo="width-before-scroll-bar",Yy="with-scroll-bars-hidden",Ky="--removed-body-scroll-bar-size";function Xy(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Ry(e,t){var n=u.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var o=n.value;o!==r&&(n.value=r,n.callback(r,o))}}}})[0];return n.callback=t,n.facade}function Zy(e,t){return Ry(t||null,function(n){return e.forEach(function(r){return Xy(r,n)})})}function Qy(e){return e}function Jy(e,t){t===void 0&&(t=Qy);var n=[],r=!1,o={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(i){var a=t(i,r);return n.push(a),function(){n=n.filter(function(s){return s!==a})}},assignSyncMedium:function(i){for(r=!0;n.length;){var a=n;n=[],a.forEach(i)}n={push:function(s){return i(s)},filter:function(){return n}}},assignMedium:function(i){r=!0;var a=[];if(n.length){var s=n;n=[],s.forEach(i),a=n}var l=function(){var d=a;a=[],d.forEach(i)},c=function(){return Promise.resolve().then(l)};c(),n={push:function(d){a.push(d),c()},filter:function(d){return a=a.filter(d),n}}}};return o}function eb(e){e===void 0&&(e={});var t=Jy(null);return t.options=Tt({async:!0,ssr:!1},e),t}var td=function(e){var t=e.sideCar,n=ed(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return me.createElement(r,Tt({},n))};td.isSideCarExport=!0;function tb(e,t){return e.useMedium(t),td}var nd=eb(),Fa=function(){},jo=me.forwardRef(function(e,t){var n=me.useRef(null),r=me.useState({onScrollCapture:Fa,onWheelCapture:Fa,onTouchMoveCapture:Fa}),o=r[0],i=r[1],a=e.forwardProps,s=e.children,l=e.className,c=e.removeScrollBar,d=e.enabled,f=e.shards,p=e.sideCar,m=e.noIsolation,h=e.inert,v=e.allowPinchZoom,x=e.as,y=x===void 0?"div":x,b=ed(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as"]),$=p,S=Zy([n,t]),w=Tt(Tt({},b),o);return me.createElement(me.Fragment,null,d&&me.createElement($,{sideCar:nd,removeScrollBar:c,shards:f,noIsolation:m,inert:h,setCallbacks:i,allowPinchZoom:!!v,lockRef:n}),a?me.cloneElement(me.Children.only(s),Tt(Tt({},w),{ref:S})):me.createElement(y,Tt({},w,{className:l,ref:S}),s))});jo.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},jo.classNames={fullWidth:Fo,zeroRight:Lo};var rd,nb=function(){if(rd)return rd;if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function rb(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=nb();return t&&e.setAttribute("nonce",t),e}function ob(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function ib(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var ab=function(){var e=0,t=null;return{add:function(n){e==0&&(t=rb())&&(ob(t,n),ib(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},sb=function(){var e=ab();return function(t,n){me.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},od=function(){var e=sb(),t=function(n){var r=n.styles,o=n.dynamic;return e(r,o),null};return t},lb={left:0,top:0,right:0,gap:0},ja=function(e){return parseInt(e||"",10)||0},cb=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],o=t[e==="padding"?"paddingRight":"marginRight"];return[ja(n),ja(r),ja(o)]},ub=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return lb;var t=cb(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},db=od(),fb=function(e,t,n,r){var o=e.left,i=e.top,a=e.right,s=e.gap;return n===void 0&&(n="margin"),`
2
+ .`.concat(Yy,` {
3
3
  overflow: hidden `).concat(r,`;
4
4
  padding-right: `).concat(s,"px ").concat(r,`;
5
5
  }
@@ -33,35 +33,35 @@
33
33
  }
34
34
 
35
35
  body {
36
- `).concat(Vy,": ").concat(s,`px;
36
+ `).concat(Ky,": ").concat(s,`px;
37
37
  }
38
- `)},ub=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r,i=me.useMemo(function(){return sb(o)},[o]);return me.createElement(lb,{styles:cb(i,!t,o,n?"":"!important")})},ja=!1;if(typeof window<"u")try{var zo=Object.defineProperty({},"passive",{get:function(){return ja=!0,!0}});window.addEventListener("test",zo,zo),window.removeEventListener("test",zo,zo)}catch{ja=!1}var Kn=ja?{passive:!1}:!1,db=function(e){return e.tagName==="TEXTAREA"},od=function(e,t){var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!db(e)&&n[t]==="visible")},fb=function(e){return od(e,"overflowY")},pb=function(e){return od(e,"overflowX")},id=function(e,t){var n=t;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var r=ad(e,n);if(r){var o=sd(e,n),i=o[1],a=o[2];if(i>a)return!0}n=n.parentNode}while(n&&n!==document.body);return!1},hb=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},mb=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},ad=function(e,t){return e==="v"?fb(t):pb(t)},sd=function(e,t){return e==="v"?hb(t):mb(t)},vb=function(e,t){return e==="h"&&t==="rtl"?-1:1},gb=function(e,t,n,r,o){var i=vb(e,window.getComputedStyle(t).direction),a=i*r,s=n.target,l=t.contains(s),c=!1,d=a>0,f=0,p=0;do{var m=sd(e,s),h=m[0],v=m[1],x=m[2],y=v-x-i*h;(h||y)&&ad(e,s)&&(f+=y,p+=h),s=s.parentNode}while(!l&&s!==document.body||l&&(t.contains(s)||t===s));return(d&&(o&&f===0||!o&&a>f)||!d&&(o&&p===0||!o&&-a>p))&&(c=!0),c},Wo=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},ld=function(e){return[e.deltaX,e.deltaY]},cd=function(e){return e&&"current"in e?e.current:e},yb=function(e,t){return e[0]===t[0]&&e[1]===t[1]},bb=function(e){return`
38
+ `)},pb=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=r===void 0?"margin":r,i=me.useMemo(function(){return ub(o)},[o]);return me.createElement(db,{styles:fb(i,!t,o,n?"":"!important")})},za=!1;if(typeof window<"u")try{var zo=Object.defineProperty({},"passive",{get:function(){return za=!0,!0}});window.addEventListener("test",zo,zo),window.removeEventListener("test",zo,zo)}catch{za=!1}var Kn=za?{passive:!1}:!1,hb=function(e){return e.tagName==="TEXTAREA"},id=function(e,t){var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!hb(e)&&n[t]==="visible")},mb=function(e){return id(e,"overflowY")},vb=function(e){return id(e,"overflowX")},ad=function(e,t){var n=t;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var r=sd(e,n);if(r){var o=ld(e,n),i=o[1],a=o[2];if(i>a)return!0}n=n.parentNode}while(n&&n!==document.body);return!1},gb=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},yb=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},sd=function(e,t){return e==="v"?mb(t):vb(t)},ld=function(e,t){return e==="v"?gb(t):yb(t)},bb=function(e,t){return e==="h"&&t==="rtl"?-1:1},xb=function(e,t,n,r,o){var i=bb(e,window.getComputedStyle(t).direction),a=i*r,s=n.target,l=t.contains(s),c=!1,d=a>0,f=0,p=0;do{var m=ld(e,s),h=m[0],v=m[1],x=m[2],y=v-x-i*h;(h||y)&&sd(e,s)&&(f+=y,p+=h),s=s.parentNode}while(!l&&s!==document.body||l&&(t.contains(s)||t===s));return(d&&(o&&f===0||!o&&a>f)||!d&&(o&&p===0||!o&&-a>p))&&(c=!0),c},Wo=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},cd=function(e){return[e.deltaX,e.deltaY]},ud=function(e){return e&&"current"in e?e.current:e},wb=function(e,t){return e[0]===t[0]&&e[1]===t[1]},$b=function(e){return`
39
39
  .block-interactivity-`.concat(e,` {pointer-events: none;}
40
40
  .allow-interactivity-`).concat(e,` {pointer-events: all;}
41
- `)},xb=0,Xn=[];function wb(e){var t=me.useRef([]),n=me.useRef([0,0]),r=me.useRef(),o=me.useState(xb++)[0],i=me.useState(function(){return rd()})[0],a=me.useRef(e);me.useEffect(function(){a.current=e},[e]),me.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var v=Hy([e.lockRef.current],(e.shards||[]).map(cd),!0).filter(Boolean);return v.forEach(function(x){return x.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),v.forEach(function(x){return x.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var s=me.useCallback(function(v,x){if("touches"in v&&v.touches.length===2)return!a.current.allowPinchZoom;var y=Wo(v),b=n.current,$="deltaX"in v?v.deltaX:b[0]-y[0],S="deltaY"in v?v.deltaY:b[1]-y[1],w,T=v.target,O=Math.abs($)>Math.abs(S)?"h":"v";if("touches"in v&&O==="h"&&T.type==="range")return!1;var P=id(O,T);if(!P)return!0;if(P?w=O:(w=O==="v"?"h":"v",P=id(O,T)),!P)return!1;if(!r.current&&"changedTouches"in v&&($||S)&&(r.current=w),!w)return!0;var _=r.current||w;return gb(_,x,v,_==="h"?$:S,!0)},[]),l=me.useCallback(function(v){var x=v;if(!(!Xn.length||Xn[Xn.length-1]!==i)){var y="deltaY"in x?ld(x):Wo(x),b=t.current.filter(function(w){return w.name===x.type&&w.target===x.target&&yb(w.delta,y)})[0];if(b&&b.should){x.cancelable&&x.preventDefault();return}if(!b){var $=(a.current.shards||[]).map(cd).filter(Boolean).filter(function(w){return w.contains(x.target)}),S=$.length>0?s(x,$[0]):!a.current.noIsolation;S&&x.cancelable&&x.preventDefault()}}},[]),c=me.useCallback(function(v,x,y,b){var $={name:v,delta:x,target:y,should:b};t.current.push($),setTimeout(function(){t.current=t.current.filter(function(S){return S!==$})},1)},[]),d=me.useCallback(function(v){n.current=Wo(v),r.current=void 0},[]),f=me.useCallback(function(v){c(v.type,ld(v),v.target,s(v,e.lockRef.current))},[]),p=me.useCallback(function(v){c(v.type,Wo(v),v.target,s(v,e.lockRef.current))},[]);me.useEffect(function(){return Xn.push(i),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:p}),document.addEventListener("wheel",l,Kn),document.addEventListener("touchmove",l,Kn),document.addEventListener("touchstart",d,Kn),function(){Xn=Xn.filter(function(v){return v!==i}),document.removeEventListener("wheel",l,Kn),document.removeEventListener("touchmove",l,Kn),document.removeEventListener("touchstart",d,Kn)}},[]);var m=e.removeScrollBar,h=e.inert;return me.createElement(me.Fragment,null,h?me.createElement(i,{styles:bb(o)}):null,m?me.createElement(ub,{gapMode:"margin"}):null)}const $b=Qy(td,wb);var ud=me.forwardRef(function(e,t){return me.createElement(jo,Tt({},e,{ref:t,sideCar:$b}))});ud.classNames=jo.classNames;const dd=ud,za=["Enter"," "],Cb=["ArrowDown","PageUp","Home"],fd=["ArrowUp","PageDown","End"],Sb=[...Cb,...fd],Eb={ltr:[...za,"ArrowRight"],rtl:[...za,"ArrowLeft"]},Tb={ltr:["ArrowLeft"],rtl:["ArrowRight"]},Bo="Menu",[Pr,Pb,Mb]=ya(Bo),[Cn,pd]=Ct(Bo,[Mb,No,Ao]),Uo=No(),hd=Ao(),[md,rn]=Cn(Bo),[kb,Mr]=Cn(Bo),Ob=e=>{const{__scopeMenu:t,open:n=!1,children:r,dir:o,onOpenChange:i,modal:a=!0}=e,s=Uo(t),[l,c]=u.useState(null),d=u.useRef(!1),f=He(i),p=$o(o);return u.useEffect(()=>{const m=()=>{d.current=!0,document.addEventListener("pointerdown",h,{capture:!0,once:!0}),document.addEventListener("pointermove",h,{capture:!0,once:!0})},h=()=>d.current=!1;return document.addEventListener("keydown",m,{capture:!0}),()=>{document.removeEventListener("keydown",m,{capture:!0}),document.removeEventListener("pointerdown",h,{capture:!0}),document.removeEventListener("pointermove",h,{capture:!0})}},[]),u.createElement(_a,s,u.createElement(md,{scope:t,open:n,onOpenChange:f,content:l,onContentChange:c},u.createElement(kb,{scope:t,onClose:u.useCallback(()=>f(!1),[f]),isUsingKeyboardRef:d,dir:p,modal:a},r)))},vd=u.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=Uo(n);return u.createElement(Gu,ee({},o,r,{ref:t}))}),gd="MenuPortal",[_b,yd]=Cn(gd,{forceMount:void 0}),Nb=e=>{const{__scopeMenu:t,forceMount:n,children:r,container:o}=e,i=rn(gd,t);return u.createElement(_b,{scope:t,forceMount:n},u.createElement(Zt,{present:n||i.open},u.createElement(qu,{asChild:!0,container:o},r)))},mt="MenuContent",[Ab,Wa]=Cn(mt),Db=u.forwardRef((e,t)=>{const n=yd(mt,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,i=rn(mt,e.__scopeMenu),a=Mr(mt,e.__scopeMenu);return u.createElement(Pr.Provider,{scope:e.__scopeMenu},u.createElement(Zt,{present:r||i.open},u.createElement(Pr.Slot,{scope:e.__scopeMenu},a.modal?u.createElement(Ib,ee({},o,{ref:t})):u.createElement(Lb,ee({},o,{ref:t})))))}),Ib=u.forwardRef((e,t)=>{const n=rn(mt,e.__scopeMenu),r=u.useRef(null),o=Oe(t,r);return u.useEffect(()=>{const i=r.current;if(i)return Qu(i)},[]),u.createElement(Ba,ee({},e,{ref:o,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:fe(e.onFocusOutside,i=>i.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)}))}),Lb=u.forwardRef((e,t)=>{const n=rn(mt,e.__scopeMenu);return u.createElement(Ba,ee({},e,{ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)}))}),Ba=u.forwardRef((e,t)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:o,onOpenAutoFocus:i,onCloseAutoFocus:a,disableOutsidePointerEvents:s,onEntryFocus:l,onEscapeKeyDown:c,onPointerDownOutside:d,onFocusOutside:f,onInteractOutside:p,onDismiss:m,disableOutsideScroll:h,...v}=e,x=rn(mt,n),y=Mr(mt,n),b=Uo(n),$=hd(n),S=Pb(n),[w,T]=u.useState(null),O=u.useRef(null),P=Oe(t,O,x.onContentChange),_=u.useRef(0),j=u.useRef(""),F=u.useRef(0),V=u.useRef(null),R=u.useRef("right"),X=u.useRef(0),C=h?dd:u.Fragment,I=h?{as:yn,allowPinchZoom:!0}:void 0,H=A=>{var N,z;const J=j.current+A,Q=S().filter(U=>!U.disabled),oe=document.activeElement,te=(N=Q.find(U=>U.ref.current===oe))===null||N===void 0?void 0:N.textValue,ae=Q.map(U=>U.textValue),Y=tx(ae,J,te),le=(z=Q.find(U=>U.textValue===Y))===null||z===void 0?void 0:z.ref.current;(function U(q){j.current=q,window.clearTimeout(_.current),q!==""&&(_.current=window.setTimeout(()=>U(""),1e3))})(J),le&&setTimeout(()=>le.focus())};u.useEffect(()=>()=>window.clearTimeout(_.current),[]),ou();const B=u.useCallback(A=>{var N,z;return R.current===((N=V.current)===null||N===void 0?void 0:N.side)&&rx(A,(z=V.current)===null||z===void 0?void 0:z.area)},[]);return u.createElement(Ab,{scope:n,searchRef:j,onItemEnter:u.useCallback(A=>{B(A)&&A.preventDefault()},[B]),onItemLeave:u.useCallback(A=>{var N;B(A)||((N=O.current)===null||N===void 0||N.focus(),T(null))},[B]),onTriggerLeave:u.useCallback(A=>{B(A)&&A.preventDefault()},[B]),pointerGraceTimerRef:F,onPointerGraceIntentChange:u.useCallback(A=>{V.current=A},[])},u.createElement(C,I,u.createElement(su,{asChild:!0,trapped:o,onMountAutoFocus:fe(i,A=>{var N;A.preventDefault(),(N=O.current)===null||N===void 0||N.focus()}),onUnmountAutoFocus:a},u.createElement(tu,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:c,onPointerDownOutside:d,onFocusOutside:f,onInteractOutside:p,onDismiss:m},u.createElement(Xu,ee({asChild:!0},$,{dir:y.dir,orientation:"vertical",loop:r,currentTabStopId:w,onCurrentTabStopIdChange:T,onEntryFocus:fe(l,A=>{y.isUsingKeyboardRef.current||A.preventDefault()})}),u.createElement(Vu,ee({role:"menu","aria-orientation":"vertical","data-state":Td(x.open),"data-radix-menu-content":"",dir:y.dir},b,v,{ref:P,style:{outline:"none",...v.style},onKeyDown:fe(v.onKeyDown,A=>{const z=A.target.closest("[data-radix-menu-content]")===A.currentTarget,J=A.ctrlKey||A.altKey||A.metaKey,Q=A.key.length===1;z&&(A.key==="Tab"&&A.preventDefault(),!J&&Q&&H(A.key));const oe=O.current;if(A.target!==oe||!Sb.includes(A.key))return;A.preventDefault();const ae=S().filter(Y=>!Y.disabled).map(Y=>Y.ref.current);fd.includes(A.key)&&ae.reverse(),Jb(ae)}),onBlur:fe(e.onBlur,A=>{A.currentTarget.contains(A.target)||(window.clearTimeout(_.current),j.current="")}),onPointerMove:fe(e.onPointerMove,kr(A=>{const N=A.target,z=X.current!==A.clientX;if(A.currentTarget.contains(N)&&z){const J=A.clientX>X.current?"right":"left";R.current=J,X.current=A.clientX}}))})))))))}),bd=u.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.createElement(we.div,ee({role:"group"},r,{ref:t}))}),Fb=u.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.createElement(we.div,ee({},r,{ref:t}))}),Ua="MenuItem",xd="menu.itemSelect",Ha=u.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:r,...o}=e,i=u.useRef(null),a=Mr(Ua,e.__scopeMenu),s=Wa(Ua,e.__scopeMenu),l=Oe(t,i),c=u.useRef(!1),d=()=>{const f=i.current;if(!n&&f){const p=new CustomEvent(xd,{bubbles:!0,cancelable:!0});f.addEventListener(xd,m=>r==null?void 0:r(m),{once:!0}),fa(f,p),p.defaultPrevented?c.current=!1:a.onClose()}};return u.createElement(wd,ee({},o,{ref:l,disabled:n,onClick:fe(e.onClick,d),onPointerDown:f=>{var p;(p=e.onPointerDown)===null||p===void 0||p.call(e,f),c.current=!0},onPointerUp:fe(e.onPointerUp,f=>{var p;c.current||(p=f.currentTarget)===null||p===void 0||p.click()}),onKeyDown:fe(e.onKeyDown,f=>{const p=s.searchRef.current!=="";n||p&&f.key===" "||za.includes(f.key)&&(f.currentTarget.click(),f.preventDefault())})}))}),wd=u.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:r=!1,textValue:o,...i}=e,a=Wa(Ua,n),s=hd(n),l=u.useRef(null),c=Oe(t,l),[d,f]=u.useState(!1),[p,m]=u.useState("");return u.useEffect(()=>{const h=l.current;if(h){var v;m(((v=h.textContent)!==null&&v!==void 0?v:"").trim())}},[i.children]),u.createElement(Pr.ItemSlot,{scope:n,disabled:r,textValue:o??p},u.createElement(Ru,ee({asChild:!0},s,{focusable:!r}),u.createElement(we.div,ee({role:"menuitem","data-highlighted":d?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0},i,{ref:c,onPointerMove:fe(e.onPointerMove,kr(h=>{r?a.onItemLeave(h):(a.onItemEnter(h),h.defaultPrevented||h.currentTarget.focus())})),onPointerLeave:fe(e.onPointerLeave,kr(h=>a.onItemLeave(h))),onFocus:fe(e.onFocus,()=>f(!0)),onBlur:fe(e.onBlur,()=>f(!1))}))))}),jb=u.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:r,...o}=e;return u.createElement(Cd,{scope:e.__scopeMenu,checked:n},u.createElement(Ha,ee({role:"menuitemcheckbox","aria-checked":Go(n)?"mixed":n},o,{ref:t,"data-state":Ga(n),onSelect:fe(o.onSelect,()=>r==null?void 0:r(Go(n)?!0:!n),{checkForDefaultPrevented:!1})})))}),zb="MenuRadioGroup",[Wb,Bb]=Cn(zb,{value:void 0,onValueChange:()=>{}}),Ub=u.forwardRef((e,t)=>{const{value:n,onValueChange:r,...o}=e,i=He(r);return u.createElement(Wb,{scope:e.__scopeMenu,value:n,onValueChange:i},u.createElement(bd,ee({},o,{ref:t})))}),Hb="MenuRadioItem",Gb=u.forwardRef((e,t)=>{const{value:n,...r}=e,o=Bb(Hb,e.__scopeMenu),i=n===o.value;return u.createElement(Cd,{scope:e.__scopeMenu,checked:i},u.createElement(Ha,ee({role:"menuitemradio","aria-checked":i},r,{ref:t,"data-state":Ga(i),onSelect:fe(r.onSelect,()=>{var a;return(a=o.onValueChange)===null||a===void 0?void 0:a.call(o,n)},{checkForDefaultPrevented:!1})})))}),$d="MenuItemIndicator",[Cd,Vb]=Cn($d,{checked:!1}),qb=u.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:r,...o}=e,i=Vb($d,n);return u.createElement(Zt,{present:r||Go(i.checked)||i.checked===!0},u.createElement(we.span,ee({},o,{ref:t,"data-state":Ga(i.checked)})))}),Yb=u.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.createElement(we.div,ee({role:"separator","aria-orientation":"horizontal"},r,{ref:t}))}),Sd="MenuSub",[Kb,Ed]=Cn(Sd),Xb=e=>{const{__scopeMenu:t,children:n,open:r=!1,onOpenChange:o}=e,i=rn(Sd,t),a=Uo(t),[s,l]=u.useState(null),[c,d]=u.useState(null),f=He(o);return u.useEffect(()=>(i.open===!1&&f(!1),()=>f(!1)),[i.open,f]),u.createElement(_a,a,u.createElement(md,{scope:t,open:r,onOpenChange:f,content:c,onContentChange:d},u.createElement(Kb,{scope:t,contentId:Dt(),triggerId:Dt(),trigger:s,onTriggerChange:l},n)))},Ho="MenuSubTrigger",Rb=u.forwardRef((e,t)=>{const n=rn(Ho,e.__scopeMenu),r=Mr(Ho,e.__scopeMenu),o=Ed(Ho,e.__scopeMenu),i=Wa(Ho,e.__scopeMenu),a=u.useRef(null),{pointerGraceTimerRef:s,onPointerGraceIntentChange:l}=i,c={__scopeMenu:e.__scopeMenu},d=u.useCallback(()=>{a.current&&window.clearTimeout(a.current),a.current=null},[]);return u.useEffect(()=>d,[d]),u.useEffect(()=>{const f=s.current;return()=>{window.clearTimeout(f),l(null)}},[s,l]),u.createElement(vd,ee({asChild:!0},c),u.createElement(wd,ee({id:o.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":o.contentId,"data-state":Td(n.open)},e,{ref:yo(t,o.onTriggerChange),onClick:f=>{var p;(p=e.onClick)===null||p===void 0||p.call(e,f),!(e.disabled||f.defaultPrevented)&&(f.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:fe(e.onPointerMove,kr(f=>{i.onItemEnter(f),!f.defaultPrevented&&!e.disabled&&!n.open&&!a.current&&(i.onPointerGraceIntentChange(null),a.current=window.setTimeout(()=>{n.onOpenChange(!0),d()},100))})),onPointerLeave:fe(e.onPointerLeave,kr(f=>{var p;d();const m=(p=n.content)===null||p===void 0?void 0:p.getBoundingClientRect();if(m){var h;const v=(h=n.content)===null||h===void 0?void 0:h.dataset.side,x=v==="right",y=x?-5:5,b=m[x?"left":"right"],$=m[x?"right":"left"];i.onPointerGraceIntentChange({area:[{x:f.clientX+y,y:f.clientY},{x:b,y:m.top},{x:$,y:m.top},{x:$,y:m.bottom},{x:b,y:m.bottom}],side:v}),window.clearTimeout(s.current),s.current=window.setTimeout(()=>i.onPointerGraceIntentChange(null),300)}else{if(i.onTriggerLeave(f),f.defaultPrevented)return;i.onPointerGraceIntentChange(null)}})),onKeyDown:fe(e.onKeyDown,f=>{const p=i.searchRef.current!=="";if(!(e.disabled||p&&f.key===" ")&&Eb[r.dir].includes(f.key)){var m;n.onOpenChange(!0),(m=n.content)===null||m===void 0||m.focus(),f.preventDefault()}})})))}),Zb="MenuSubContent",Qb=u.forwardRef((e,t)=>{const n=yd(mt,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,i=rn(mt,e.__scopeMenu),a=Mr(mt,e.__scopeMenu),s=Ed(Zb,e.__scopeMenu),l=u.useRef(null),c=Oe(t,l);return u.createElement(Pr.Provider,{scope:e.__scopeMenu},u.createElement(Zt,{present:r||i.open},u.createElement(Pr.Slot,{scope:e.__scopeMenu},u.createElement(Ba,ee({id:s.contentId,"aria-labelledby":s.triggerId},o,{ref:c,align:"start",side:a.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:d=>{var f;a.isUsingKeyboardRef.current&&((f=l.current)===null||f===void 0||f.focus()),d.preventDefault()},onCloseAutoFocus:d=>d.preventDefault(),onFocusOutside:fe(e.onFocusOutside,d=>{d.target!==s.trigger&&i.onOpenChange(!1)}),onEscapeKeyDown:fe(e.onEscapeKeyDown,d=>{a.onClose(),d.preventDefault()}),onKeyDown:fe(e.onKeyDown,d=>{const f=d.currentTarget.contains(d.target),p=Tb[a.dir].includes(d.key);if(f&&p){var m;i.onOpenChange(!1),(m=s.trigger)===null||m===void 0||m.focus(),d.preventDefault()}})})))))});function Td(e){return e?"open":"closed"}function Go(e){return e==="indeterminate"}function Ga(e){return Go(e)?"indeterminate":e?"checked":"unchecked"}function Jb(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function ex(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function tx(e,t,n){const o=t.length>1&&Array.from(t).every(c=>c===t[0])?t[0]:t,i=n?e.indexOf(n):-1;let a=ex(e,Math.max(i,0));o.length===1&&(a=a.filter(c=>c!==n));const l=a.find(c=>c.toLowerCase().startsWith(o.toLowerCase()));return l!==n?l:void 0}function nx(e,t){const{x:n,y:r}=e;let o=!1;for(let i=0,a=t.length-1;i<t.length;a=i++){const s=t[i].x,l=t[i].y,c=t[a].x,d=t[a].y;l>r!=d>r&&n<(c-s)*(r-l)/(d-l)+s&&(o=!o)}return o}function rx(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return nx(n,t)}function kr(e){return t=>t.pointerType==="mouse"?e(t):void 0}const ox=Ob,ix=vd,ax=Nb,sx=Db,lx=bd,cx=Fb,ux=Ha,dx=jb,fx=Ub,px=Gb,hx=qb,mx=Yb,vx=Xb,gx=Rb,yx=Qb,Pd="DropdownMenu",[bx,q3]=Ct(Pd,[pd]),Ge=pd(),[xx,Md]=bx(Pd),wx=e=>{const{__scopeDropdownMenu:t,children:n,dir:r,open:o,defaultOpen:i,onOpenChange:a,modal:s=!0}=e,l=Ge(t),c=u.useRef(null),[d=!1,f]=St({prop:o,defaultProp:i,onChange:a});return u.createElement(xx,{scope:t,triggerId:Dt(),triggerRef:c,contentId:Dt(),open:d,onOpenChange:f,onOpenToggle:u.useCallback(()=>f(p=>!p),[f]),modal:s},u.createElement(ox,ee({},l,{open:d,onOpenChange:f,dir:r,modal:s}),n))},$x="DropdownMenuTrigger",Cx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:r=!1,...o}=e,i=Md($x,n),a=Ge(n);return u.createElement(ix,ee({asChild:!0},a),u.createElement(we.button,ee({type:"button",id:i.triggerId,"aria-haspopup":"menu","aria-expanded":i.open,"aria-controls":i.open?i.contentId:void 0,"data-state":i.open?"open":"closed","data-disabled":r?"":void 0,disabled:r},o,{ref:yo(t,i.triggerRef),onPointerDown:fe(e.onPointerDown,s=>{!r&&s.button===0&&s.ctrlKey===!1&&(i.onOpenToggle(),i.open||s.preventDefault())}),onKeyDown:fe(e.onKeyDown,s=>{r||(["Enter"," "].includes(s.key)&&i.onOpenToggle(),s.key==="ArrowDown"&&i.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(s.key)&&s.preventDefault())})})))}),Sx=e=>{const{__scopeDropdownMenu:t,...n}=e,r=Ge(t);return u.createElement(ax,ee({},r,n))},Ex="DropdownMenuContent",Tx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Md(Ex,n),i=Ge(n),a=u.useRef(!1);return u.createElement(sx,ee({id:o.contentId,"aria-labelledby":o.triggerId},i,r,{ref:t,onCloseAutoFocus:fe(e.onCloseAutoFocus,s=>{var l;a.current||(l=o.triggerRef.current)===null||l===void 0||l.focus(),a.current=!1,s.preventDefault()}),onInteractOutside:fe(e.onInteractOutside,s=>{const l=s.detail.originalEvent,c=l.button===0&&l.ctrlKey===!0,d=l.button===2||c;(!o.modal||d)&&(a.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}}))}),Px=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(lx,ee({},o,r,{ref:t}))}),Mx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(cx,ee({},o,r,{ref:t}))}),kx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(ux,ee({},o,r,{ref:t}))}),Ox=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(dx,ee({},o,r,{ref:t}))}),_x=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(fx,ee({},o,r,{ref:t}))}),Nx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(px,ee({},o,r,{ref:t}))}),Ax=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(hx,ee({},o,r,{ref:t}))}),Dx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(mx,ee({},o,r,{ref:t}))}),Ix=e=>{const{__scopeDropdownMenu:t,children:n,open:r,onOpenChange:o,defaultOpen:i}=e,a=Ge(t),[s=!1,l]=St({prop:r,defaultProp:i,onChange:o});return u.createElement(vx,ee({},a,{open:s,onOpenChange:l}),n)},Lx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(gx,ee({},o,r,{ref:t}))}),Fx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(yx,ee({},o,r,{ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}}))}),jx=wx,zx=Cx,kd=Sx,Od=Tx,_d=Px,Nd=Mx,Ad=kx,Dd=Ox,Wx=_x,Id=Nx,Ld=Ax,Fd=Dx,Bx=Ix,jd=Lx,zd=Fx,Ux=jx,Hx=zx,Gx=kd,Vx=Bx,qx=Wx,Wd=u.forwardRef(({className:e,...t},n)=>L.jsx(_d,{ref:n,className:Ne("w-full",e),...t}));Wd.displayName=_d.displayName;const Bd=u.forwardRef(({className:e,children:t,...n},r)=>L.jsxs(jd,{ref:r,className:Ne("flex cursor-default select-none px-2 py-1.5 bg-white rounded hover:bg-sky-100 hover:text-sky-800 hover:cursor-pointer justify-start items-start text-zinc-800 text-sm font-normal leading-tight focus:bg-sky-100 focus:text-sky-800 data-[state=checked]:bg-sky-100 data-[state=checked]:text-sky-800 focus:outline-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[t,L.jsx(Zg,{className:"ml-auto h-4 w-4"})]}));Bd.displayName=jd.displayName;const Ud=u.forwardRef(({className:e,...t},n)=>L.jsx(zd,{ref:n,className:Ne("rabbit-ds z-[1510] rabbit-ds min-w-[8rem] max-w-xs p-1 bg-white rounded-lg shadow flex flex-col justify-start items-start gap-1 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...t}));Ud.displayName=zd.displayName;const Hd=u.forwardRef(({className:e,sideOffset:t=4,...n},r)=>L.jsx(kd,{children:L.jsx(Od,{ref:r,sideOffset:t,className:Ne("rabbit-ds z-[1500] rabbit-ds min-w-[8rem] max-w-xs p-1 bg-white rounded-lg shadow flex flex-col justify-start items-start gap-1 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...n})}));Hd.displayName=Od.displayName;const Gd=u.forwardRef(({className:e,...t},n)=>L.jsx(Ad,{ref:n,className:Ne("relative flex flex-row w-full my-1 cursor-default select-none p-2 bg-white rounded hover:bg-sky-100 hover:text-sky-800 hover:cursor-pointer justify-start items-start text-zinc-800 text-sm font-normal leading-tight focus:bg-sky-100 focus:text-sky-800 data-[state=checked]:bg-sky-100 data-[state=checked]:text-sky-800 focus:outline-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...t}));Gd.displayName=Ad.displayName;const Vd=u.forwardRef(({className:e,children:t,checked:n,...r},o)=>L.jsxs(Dd,{ref:o,className:Ne("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:n,...r,children:[L.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:L.jsx(Ld,{children:L.jsx(pa,{className:"h-4 w-4 text-sky-800"})})}),t]}));Vd.displayName=Dd.displayName;const qd=u.forwardRef(({className:e,children:t,...n},r)=>L.jsxs(Id,{ref:r,className:Ne("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[L.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:L.jsx(Ld,{children:L.jsx(Qg,{className:"h-2 w-2 fill-current text-sky-800"})})}),t]}));qd.displayName=Id.displayName;const Yd=u.forwardRef(({className:e,...t},n)=>L.jsx(Nd,{ref:n,className:Ne("px-2 py-1.5 text-sm font-semibold",e),...t}));Yd.displayName=Nd.displayName;const Kd=u.forwardRef(({className:e,...t},n)=>L.jsx(Fd,{ref:n,className:Ne("h-px w-full bg-athens-gray-100",e),...t}));Kd.displayName=Fd.displayName;function Xd(e,[t,n]){return Math.min(n,Math.max(t,e))}const Rd=u.forwardRef((e,t)=>u.createElement(we.span,ee({},e,{ref:t,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}}))),Yx=Rd,Kx=[" ","Enter","ArrowUp","ArrowDown"],Xx=[" ","Enter"],Vo="Select",[qo,Va,Rx]=ya(Vo),[Rn,Y3]=Ct(Vo,[Rx,No]),qa=No(),[Zx,Sn]=Rn(Vo),[Qx,Jx]=Rn(Vo),ew=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:o,onOpenChange:i,value:a,defaultValue:s,onValueChange:l,dir:c,name:d,autoComplete:f,disabled:p,required:m}=e,h=qa(t),[v,x]=u.useState(null),[y,b]=u.useState(null),[$,S]=u.useState(!1),w=$o(c),[T=!1,O]=St({prop:r,defaultProp:o,onChange:i}),[P,_]=St({prop:a,defaultProp:s,onChange:l}),j=u.useRef(null),F=v?!!v.closest("form"):!0,[V,R]=u.useState(new Set),X=Array.from(V).map(C=>C.props.value).join(";");return u.createElement(_a,h,u.createElement(Zx,{required:m,scope:t,trigger:v,onTriggerChange:x,valueNode:y,onValueNodeChange:b,valueNodeHasChildren:$,onValueNodeHasChildrenChange:S,contentId:Dt(),value:P,onValueChange:_,open:T,onOpenChange:O,dir:w,triggerPointerDownPosRef:j,disabled:p},u.createElement(qo.Provider,{scope:t},u.createElement(Qx,{scope:e.__scopeSelect,onNativeOptionAdd:u.useCallback(C=>{R(I=>new Set(I).add(C))},[]),onNativeOptionRemove:u.useCallback(C=>{R(I=>{const H=new Set(I);return H.delete(C),H})},[])},n)),F?u.createElement(nf,{key:X,"aria-hidden":!0,required:m,tabIndex:-1,name:d,autoComplete:f,value:P,onChange:C=>_(C.target.value),disabled:p},P===void 0?u.createElement("option",{value:""}):null,Array.from(V)):null))},tw="SelectTrigger",nw=u.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...o}=e,i=qa(n),a=Sn(tw,n),s=a.disabled||r,l=Oe(t,a.onTriggerChange),c=Va(n),[d,f,p]=rf(h=>{const v=c().filter(b=>!b.disabled),x=v.find(b=>b.value===a.value),y=of(v,h,x);y!==void 0&&a.onValueChange(y.value)}),m=()=>{s||(a.onOpenChange(!0),p())};return u.createElement(Gu,ee({asChild:!0},i),u.createElement(we.button,ee({type:"button",role:"combobox","aria-controls":a.contentId,"aria-expanded":a.open,"aria-required":a.required,"aria-autocomplete":"none",dir:a.dir,"data-state":a.open?"open":"closed",disabled:s,"data-disabled":s?"":void 0,"data-placeholder":tf(a.value)?"":void 0},o,{ref:l,onClick:fe(o.onClick,h=>{h.currentTarget.focus()}),onPointerDown:fe(o.onPointerDown,h=>{const v=h.target;v.hasPointerCapture(h.pointerId)&&v.releasePointerCapture(h.pointerId),h.button===0&&h.ctrlKey===!1&&(m(),a.triggerPointerDownPosRef.current={x:Math.round(h.pageX),y:Math.round(h.pageY)},h.preventDefault())}),onKeyDown:fe(o.onKeyDown,h=>{const v=d.current!=="";!(h.ctrlKey||h.altKey||h.metaKey)&&h.key.length===1&&f(h.key),!(v&&h.key===" ")&&Kx.includes(h.key)&&(m(),h.preventDefault())})})))}),rw="SelectValue",ow=u.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,children:i,placeholder:a="",...s}=e,l=Sn(rw,n),{onValueNodeHasChildrenChange:c}=l,d=i!==void 0,f=Oe(t,l.onValueNodeChange);return ot(()=>{c(d)},[c,d]),u.createElement(we.span,ee({},s,{ref:f,style:{pointerEvents:"none"}}),tf(l.value)?u.createElement(u.Fragment,null,a):i)}),iw=u.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...o}=e;return u.createElement(we.span,ee({"aria-hidden":!0},o,{ref:t}),r||"▼")}),aw=e=>u.createElement(qu,ee({asChild:!0},e)),Zn="SelectContent",sw=u.forwardRef((e,t)=>{const n=Sn(Zn,e.__scopeSelect),[r,o]=u.useState();if(ot(()=>{o(new DocumentFragment)},[]),!n.open){const i=r;return i?At.createPortal(u.createElement(Zd,{scope:e.__scopeSelect},u.createElement(qo.Slot,{scope:e.__scopeSelect},u.createElement("div",null,e.children))),i):null}return u.createElement(lw,ee({},e,{ref:t}))}),zt=10,[Zd,Yo]=Rn(Zn),lw=u.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:i,onPointerDownOutside:a,side:s,sideOffset:l,align:c,alignOffset:d,arrowPadding:f,collisionBoundary:p,collisionPadding:m,sticky:h,hideWhenDetached:v,avoidCollisions:x,...y}=e,b=Sn(Zn,n),[$,S]=u.useState(null),[w,T]=u.useState(null),O=Oe(t,Y=>S(Y)),[P,_]=u.useState(null),[j,F]=u.useState(null),V=Va(n),[R,X]=u.useState(!1),C=u.useRef(!1);u.useEffect(()=>{if($)return Qu($)},[$]),ou();const I=u.useCallback(Y=>{const[le,...U]=V().map(k=>k.ref.current),[q]=U.slice(-1),re=document.activeElement;for(const k of Y)if(k===re||(k==null||k.scrollIntoView({block:"nearest"}),k===le&&w&&(w.scrollTop=0),k===q&&w&&(w.scrollTop=w.scrollHeight),k==null||k.focus(),document.activeElement!==re))return},[V,w]),H=u.useCallback(()=>I([P,$]),[I,P,$]);u.useEffect(()=>{R&&H()},[R,H]);const{onOpenChange:B,triggerPointerDownPosRef:A}=b;u.useEffect(()=>{if($){let Y={x:0,y:0};const le=q=>{var re,k,de,pe;Y={x:Math.abs(Math.round(q.pageX)-((re=(k=A.current)===null||k===void 0?void 0:k.x)!==null&&re!==void 0?re:0)),y:Math.abs(Math.round(q.pageY)-((de=(pe=A.current)===null||pe===void 0?void 0:pe.y)!==null&&de!==void 0?de:0))}},U=q=>{Y.x<=10&&Y.y<=10?q.preventDefault():$.contains(q.target)||B(!1),document.removeEventListener("pointermove",le),A.current=null};return A.current!==null&&(document.addEventListener("pointermove",le),document.addEventListener("pointerup",U,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",le),document.removeEventListener("pointerup",U,{capture:!0})}}},[$,B,A]),u.useEffect(()=>{const Y=()=>B(!1);return window.addEventListener("blur",Y),window.addEventListener("resize",Y),()=>{window.removeEventListener("blur",Y),window.removeEventListener("resize",Y)}},[B]);const[N,z]=rf(Y=>{const le=V().filter(re=>!re.disabled),U=le.find(re=>re.ref.current===document.activeElement),q=of(le,Y,U);q&&setTimeout(()=>q.ref.current.focus())}),J=u.useCallback((Y,le,U)=>{const q=!C.current&&!U;(b.value!==void 0&&b.value===le||q)&&(_(Y),q&&(C.current=!0))},[b.value]),Q=u.useCallback(()=>$==null?void 0:$.focus(),[$]),oe=u.useCallback((Y,le,U)=>{const q=!C.current&&!U;(b.value!==void 0&&b.value===le||q)&&F(Y)},[b.value]),te=r==="popper"?Qd:cw,ae=te===Qd?{side:s,sideOffset:l,align:c,alignOffset:d,arrowPadding:f,collisionBoundary:p,collisionPadding:m,sticky:h,hideWhenDetached:v,avoidCollisions:x}:{};return u.createElement(Zd,{scope:n,content:$,viewport:w,onViewportChange:T,itemRefCallback:J,selectedItem:P,onItemLeave:Q,itemTextRefCallback:oe,focusSelectedItem:H,selectedItemText:j,position:r,isPositioned:R,searchRef:N},u.createElement(dd,{as:yn,allowPinchZoom:!0},u.createElement(su,{asChild:!0,trapped:b.open,onMountAutoFocus:Y=>{Y.preventDefault()},onUnmountAutoFocus:fe(o,Y=>{var le;(le=b.trigger)===null||le===void 0||le.focus({preventScroll:!0}),Y.preventDefault()})},u.createElement(tu,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:i,onPointerDownOutside:a,onFocusOutside:Y=>Y.preventDefault(),onDismiss:()=>b.onOpenChange(!1)},u.createElement(te,ee({role:"listbox",id:b.contentId,"data-state":b.open?"open":"closed",dir:b.dir,onContextMenu:Y=>Y.preventDefault()},y,ae,{onPlaced:()=>X(!0),ref:O,style:{display:"flex",flexDirection:"column",outline:"none",...y.style},onKeyDown:fe(y.onKeyDown,Y=>{const le=Y.ctrlKey||Y.altKey||Y.metaKey;if(Y.key==="Tab"&&Y.preventDefault(),!le&&Y.key.length===1&&z(Y.key),["ArrowUp","ArrowDown","Home","End"].includes(Y.key)){let q=V().filter(re=>!re.disabled).map(re=>re.ref.current);if(["ArrowUp","End"].includes(Y.key)&&(q=q.slice().reverse()),["ArrowUp","ArrowDown"].includes(Y.key)){const re=Y.target,k=q.indexOf(re);q=q.slice(k+1)}setTimeout(()=>I(q)),Y.preventDefault()}})}))))))}),cw=u.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...o}=e,i=Sn(Zn,n),a=Yo(Zn,n),[s,l]=u.useState(null),[c,d]=u.useState(null),f=Oe(t,O=>d(O)),p=Va(n),m=u.useRef(!1),h=u.useRef(!0),{viewport:v,selectedItem:x,selectedItemText:y,focusSelectedItem:b}=a,$=u.useCallback(()=>{if(i.trigger&&i.valueNode&&s&&c&&v&&x&&y){const O=i.trigger.getBoundingClientRect(),P=c.getBoundingClientRect(),_=i.valueNode.getBoundingClientRect(),j=y.getBoundingClientRect();if(i.dir!=="rtl"){const re=j.left-P.left,k=_.left-re,de=O.left-k,pe=O.width+de,Ce=Math.max(pe,P.width),ke=window.innerWidth-zt,je=Xd(k,[zt,ke-Ce]);s.style.minWidth=pe+"px",s.style.left=je+"px"}else{const re=P.right-j.right,k=window.innerWidth-_.right-re,de=window.innerWidth-O.right-k,pe=O.width+de,Ce=Math.max(pe,P.width),ke=window.innerWidth-zt,je=Xd(k,[zt,ke-Ce]);s.style.minWidth=pe+"px",s.style.right=je+"px"}const F=p(),V=window.innerHeight-zt*2,R=v.scrollHeight,X=window.getComputedStyle(c),C=parseInt(X.borderTopWidth,10),I=parseInt(X.paddingTop,10),H=parseInt(X.borderBottomWidth,10),B=parseInt(X.paddingBottom,10),A=C+I+R+B+H,N=Math.min(x.offsetHeight*5,A),z=window.getComputedStyle(v),J=parseInt(z.paddingTop,10),Q=parseInt(z.paddingBottom,10),oe=O.top+O.height/2-zt,te=V-oe,ae=x.offsetHeight/2,Y=x.offsetTop+ae,le=C+I+Y,U=A-le;if(le<=oe){const re=x===F[F.length-1].ref.current;s.style.bottom="0px";const k=c.clientHeight-v.offsetTop-v.offsetHeight,de=Math.max(te,ae+(re?Q:0)+k+H),pe=le+de;s.style.height=pe+"px"}else{const re=x===F[0].ref.current;s.style.top="0px";const de=Math.max(oe,C+v.offsetTop+(re?J:0)+ae)+U;s.style.height=de+"px",v.scrollTop=le-oe+v.offsetTop}s.style.margin=`${zt}px 0`,s.style.minHeight=N+"px",s.style.maxHeight=V+"px",r==null||r(),requestAnimationFrame(()=>m.current=!0)}},[p,i.trigger,i.valueNode,s,c,v,x,y,i.dir,r]);ot(()=>$(),[$]);const[S,w]=u.useState();ot(()=>{c&&w(window.getComputedStyle(c).zIndex)},[c]);const T=u.useCallback(O=>{O&&h.current===!0&&($(),b==null||b(),h.current=!1)},[$,b]);return u.createElement(uw,{scope:n,contentWrapper:s,shouldExpandOnScrollRef:m,onScrollButtonChange:T},u.createElement("div",{ref:l,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:S}},u.createElement(we.div,ee({},o,{ref:f,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}}))))}),Qd=u.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:o=zt,...i}=e,a=qa(n);return u.createElement(Vu,ee({},a,i,{ref:t,align:r,collisionPadding:o,style:{boxSizing:"border-box",...i.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}}))}),[uw,dw]=Rn(Zn,{}),Jd="SelectViewport",fw=u.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=Yo(Jd,n),i=dw(Jd,n),a=Oe(t,o.onViewportChange),s=u.useRef(0);return u.createElement(u.Fragment,null,u.createElement("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"}}),u.createElement(qo.Slot,{scope:n},u.createElement(we.div,ee({"data-radix-select-viewport":"",role:"presentation"},r,{ref:a,style:{position:"relative",flex:1,overflow:"auto",...r.style},onScroll:fe(r.onScroll,l=>{const c=l.currentTarget,{contentWrapper:d,shouldExpandOnScrollRef:f}=i;if(f!=null&&f.current&&d){const p=Math.abs(s.current-c.scrollTop);if(p>0){const m=window.innerHeight-zt*2,h=parseFloat(d.style.minHeight),v=parseFloat(d.style.height),x=Math.max(h,v);if(x<m){const y=x+p,b=Math.min(m,y),$=y-b;d.style.height=b+"px",d.style.bottom==="0px"&&(c.scrollTop=$>0?$:0,d.style.justifyContent="flex-end")}}}s.current=c.scrollTop})}))))}),pw="SelectGroup",[hw,mw]=Rn(pw),vw=u.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=Dt();return u.createElement(hw,{scope:n,id:o},u.createElement(we.div,ee({role:"group","aria-labelledby":o},r,{ref:t})))}),gw="SelectLabel",yw=u.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=mw(gw,n);return u.createElement(we.div,ee({id:o.id},r,{ref:t}))}),Ya="SelectItem",[bw,ef]=Rn(Ya),xw=u.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:o=!1,textValue:i,...a}=e,s=Sn(Ya,n),l=Yo(Ya,n),c=s.value===r,[d,f]=u.useState(i??""),[p,m]=u.useState(!1),h=Oe(t,y=>{var b;return(b=l.itemRefCallback)===null||b===void 0?void 0:b.call(l,y,r,o)}),v=Dt(),x=()=>{o||(s.onValueChange(r),s.onOpenChange(!1))};if(r==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return u.createElement(bw,{scope:n,value:r,disabled:o,textId:v,isSelected:c,onItemTextChange:u.useCallback(y=>{f(b=>{var $;return b||(($=y==null?void 0:y.textContent)!==null&&$!==void 0?$:"").trim()})},[])},u.createElement(qo.ItemSlot,{scope:n,value:r,disabled:o,textValue:d},u.createElement(we.div,ee({role:"option","aria-labelledby":v,"data-highlighted":p?"":void 0,"aria-selected":c&&p,"data-state":c?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1},a,{ref:h,onFocus:fe(a.onFocus,()=>m(!0)),onBlur:fe(a.onBlur,()=>m(!1)),onPointerUp:fe(a.onPointerUp,x),onPointerMove:fe(a.onPointerMove,y=>{if(o){var b;(b=l.onItemLeave)===null||b===void 0||b.call(l)}else y.currentTarget.focus({preventScroll:!0})}),onPointerLeave:fe(a.onPointerLeave,y=>{if(y.currentTarget===document.activeElement){var b;(b=l.onItemLeave)===null||b===void 0||b.call(l)}}),onKeyDown:fe(a.onKeyDown,y=>{var b;((b=l.searchRef)===null||b===void 0?void 0:b.current)!==""&&y.key===" "||(Xx.includes(y.key)&&x(),y.key===" "&&y.preventDefault())})}))))}),Ko="SelectItemText",ww=u.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,...i}=e,a=Sn(Ko,n),s=Yo(Ko,n),l=ef(Ko,n),c=Jx(Ko,n),[d,f]=u.useState(null),p=Oe(t,y=>f(y),l.onItemTextChange,y=>{var b;return(b=s.itemTextRefCallback)===null||b===void 0?void 0:b.call(s,y,l.value,l.disabled)}),m=d==null?void 0:d.textContent,h=u.useMemo(()=>u.createElement("option",{key:l.value,value:l.value,disabled:l.disabled},m),[l.disabled,l.value,m]),{onNativeOptionAdd:v,onNativeOptionRemove:x}=c;return ot(()=>(v(h),()=>x(h)),[v,x,h]),u.createElement(u.Fragment,null,u.createElement(we.span,ee({id:l.textId},i,{ref:p})),l.isSelected&&a.valueNode&&!a.valueNodeHasChildren?At.createPortal(i.children,a.valueNode):null)}),$w="SelectItemIndicator",Cw=u.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return ef($w,n).isSelected?u.createElement(we.span,ee({"aria-hidden":!0},r,{ref:t})):null}),Sw=u.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return u.createElement(we.div,ee({"aria-hidden":!0},r,{ref:t}))});function tf(e){return e===""||e===void 0}const nf=u.forwardRef((e,t)=>{const{value:n,...r}=e,o=u.useRef(null),i=Oe(t,o),a=_c(n);return u.useEffect(()=>{const s=o.current,l=window.HTMLSelectElement.prototype,d=Object.getOwnPropertyDescriptor(l,"value").set;if(a!==n&&d){const f=new Event("change",{bubbles:!0});d.call(s,n),s.dispatchEvent(f)}},[a,n]),u.createElement(Rd,{asChild:!0},u.createElement("select",ee({},r,{ref:i,defaultValue:n})))});nf.displayName="BubbleSelect";function rf(e){const t=He(e),n=u.useRef(""),r=u.useRef(0),o=u.useCallback(a=>{const s=n.current+a;t(s),function l(c){n.current=c,window.clearTimeout(r.current),c!==""&&(r.current=window.setTimeout(()=>l(""),1e3))}(s)},[t]),i=u.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return u.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,o,i]}function of(e,t,n){const o=t.length>1&&Array.from(t).every(c=>c===t[0])?t[0]:t,i=n?e.indexOf(n):-1;let a=Ew(e,Math.max(i,0));o.length===1&&(a=a.filter(c=>c!==n));const l=a.find(c=>c.textValue.toLowerCase().startsWith(o.toLowerCase()));return l!==n?l:void 0}function Ew(e,t){return e.map((n,r)=>e[(t+r)%e.length])}const Tw=ew,af=nw,Pw=ow,Mw=iw,kw=aw,sf=sw,Ow=fw,_w=vw,lf=yw,cf=xw,Nw=ww,Aw=Cw,uf=Sw,Dw=Tw,Iw=_w,Lw=Pw,df=u.forwardRef(({className:e,children:t,...n},r)=>L.jsx("div",{className:"rabbit-ds",children:L.jsxs(af,{ref:r,className:Ne("rabbit-ds h-10 pr-3 py-2.5 rounded-tl text-sm rounded-tr border-b border-dashed hover:border-solid border-zinc-800 justify-between items-center gap-2 inline-flex focus:outline-none focus:border-solid disabled:cursor-not-allowed disabled:opacity-50",e),...n,children:[t,L.jsx(Mw,{asChild:!0,children:L.jsx(Rg,{className:"h-4 w-4"})})]})}));df.displayName=af.displayName;const ff=u.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>L.jsx(kw,{children:L.jsx(sf,{ref:o,className:Ne("relative z-[1500] rabbit-ds min-w-[8rem] max-w-xs p-1 bg-white rounded-lg shadow flex-col justify-start items-start gap-1 inline-flex data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:n,...r,children:L.jsx(Ow,{className:Ne("p-1",n==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t})})}));ff.displayName=sf.displayName;const pf=u.forwardRef(({className:e,...t},n)=>L.jsx(lf,{ref:n,className:Ne("py-1.5 px-2 text-sm font-semibold",e),...t}));pf.displayName=lf.displayName;const hf=u.forwardRef(({className:e,children:t,...n},r)=>L.jsxs(cf,{ref:r,className:Ne("relative flex w-full my-1 cursor-default select-none p-2 bg-white rounded flex-col hover:bg-sky-100 hover:text-sky-800 hover:cursor-pointer justify-start items-start text-zinc-800 text-sm font-normal leading-tight focus:bg-sky-100 focus:text-sky-800 data-[state=checked]:bg-sky-100 data-[state=checked]:text-sky-800 focus:outline-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[L.jsx("span",{className:"absolute right-2 flex h-4 w-4 items-center justify-center",children:L.jsx(Aw,{children:L.jsx(pa,{className:"h-4 w-4 text-sky-800"})})}),L.jsx(Nw,{children:t})]}));hf.displayName=cf.displayName;const mf=u.forwardRef(({className:e,...t},n)=>L.jsx(uf,{ref:n,className:Ne("-mx-1 my-1 h-px bg-muted",e),...t}));mf.displayName=uf.displayName;const Ka="dismissableLayer.update",Fw="dismissableLayer.pointerDownOutside",jw="dismissableLayer.focusOutside";let vf;const zw=u.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Ww=u.forwardRef((e,t)=>{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:i,onFocusOutside:a,onInteractOutside:s,onDismiss:l,...c}=e,d=u.useContext(zw),[f,p]=u.useState(null),m=(n=f==null?void 0:f.ownerDocument)!==null&&n!==void 0?n:globalThis==null?void 0:globalThis.document,[,h]=u.useState({}),v=Oe(t,P=>p(P)),x=Array.from(d.layers),[y]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),b=x.indexOf(y),$=f?x.indexOf(f):-1,S=d.layersWithOutsidePointerEventsDisabled.size>0,w=$>=b,T=Bw(P=>{const _=P.target,j=[...d.branches].some(F=>F.contains(_));!w||j||(i==null||i(P),s==null||s(P),P.defaultPrevented||l==null||l())},m),O=Uw(P=>{const _=P.target;[...d.branches].some(F=>F.contains(_))||(a==null||a(P),s==null||s(P),P.defaultPrevented||l==null||l())},m);return Jc(P=>{$===d.layers.size-1&&(o==null||o(P),!P.defaultPrevented&&l&&(P.preventDefault(),l()))},m),u.useEffect(()=>{if(f)return r&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(vf=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),gf(),()=>{r&&d.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=vf)}},[f,m,r,d]),u.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),gf())},[f,d]),u.useEffect(()=>{const P=()=>h({});return document.addEventListener(Ka,P),()=>document.removeEventListener(Ka,P)},[]),u.createElement(we.div,ee({},c,{ref:v,style:{pointerEvents:S?w?"auto":"none":void 0,...e.style},onFocusCapture:fe(e.onFocusCapture,O.onFocusCapture),onBlurCapture:fe(e.onBlurCapture,O.onBlurCapture),onPointerDownCapture:fe(e.onPointerDownCapture,T.onPointerDownCapture)}))});function Bw(e,t=globalThis==null?void 0:globalThis.document){const n=He(e),r=u.useRef(!1),o=u.useRef(()=>{});return u.useEffect(()=>{const i=s=>{if(s.target&&!r.current){let c=function(){yf(Fw,n,l,{discrete:!0})};const l={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}r.current=!1},a=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",i),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function Uw(e,t=globalThis==null?void 0:globalThis.document){const n=He(e),r=u.useRef(!1);return u.useEffect(()=>{const o=i=>{i.target&&!r.current&&yf(jw,n,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function gf(){const e=new CustomEvent(Ka);document.dispatchEvent(e)}function yf(e,t,n,{discrete:r}){const o=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?fa(o,i):o.dispatchEvent(i)}const bf="Popper",[xf,wf]=Ct(bf),[Hw,$f]=xf(bf),Gw=e=>{const{__scopePopper:t,children:n}=e,[r,o]=u.useState(null);return u.createElement(Hw,{scope:t,anchor:r,onAnchorChange:o},n)},Vw="PopperAnchor",qw=u.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,i=$f(Vw,n),a=u.useRef(null),s=Oe(t,a);return u.useEffect(()=>{i.onAnchorChange((r==null?void 0:r.current)||a.current)}),r?null:u.createElement(we.div,ee({},o,{ref:s}))}),Cf="PopperContent",[Yw,K3]=xf(Cf),Kw=u.forwardRef((e,t)=>{var n,r,o,i,a,s,l,c;const{__scopePopper:d,side:f="bottom",sideOffset:p=0,align:m="center",alignOffset:h=0,arrowPadding:v=0,collisionBoundary:x=[],collisionPadding:y=0,sticky:b="partial",hideWhenDetached:$=!1,avoidCollisions:S=!0,onPlaced:w,...T}=e,O=$f(Cf,d),[P,_]=u.useState(null),j=Oe(t,pe=>_(pe)),[F,V]=u.useState(null),R=ua(F),X=(n=R==null?void 0:R.width)!==null&&n!==void 0?n:0,C=(r=R==null?void 0:R.height)!==null&&r!==void 0?r:0,I=f+(m!=="center"?"-"+m:""),H=typeof y=="number"?y:{top:0,right:0,bottom:0,left:0,...y},B=Array.isArray(x)?x:[x],A=B.length>0,N={padding:H,boundary:B.filter(Xw),altBoundary:A},{refs:z,floatingStyles:J,placement:Q,isPositioned:oe,middlewareData:te}=ju({strategy:"fixed",placement:I,whileElementsMounted:Au,elements:{reference:O.anchor},middleware:[bu({mainAxis:p+C,alignmentAxis:h}),S&&xu({mainAxis:!0,crossAxis:!1,limiter:b==="partial"?wu():void 0,...N}),S&&mu({...N}),$u({...N,apply:({elements:pe,rects:Ce,availableWidth:ke,availableHeight:je})=>{const{width:_t,height:mn}=Ce.reference,Ze=pe.floating.style;Ze.setProperty("--radix-popper-available-width",`${ke}px`),Ze.setProperty("--radix-popper-available-height",`${je}px`),Ze.setProperty("--radix-popper-anchor-width",`${_t}px`),Ze.setProperty("--radix-popper-anchor-height",`${mn}px`)}}),F&&Du({element:F,padding:v}),Rw({arrowWidth:X,arrowHeight:C}),$&&yu({strategy:"referenceHidden"})]}),[ae,Y]=Sf(Q),le=He(w);ot(()=>{oe&&(le==null||le())},[oe,le]);const U=(o=te.arrow)===null||o===void 0?void 0:o.x,q=(i=te.arrow)===null||i===void 0?void 0:i.y,re=((a=te.arrow)===null||a===void 0?void 0:a.centerOffset)!==0,[k,de]=u.useState();return ot(()=>{P&&de(window.getComputedStyle(P).zIndex)},[P]),u.createElement("div",{ref:z.setFloating,"data-radix-popper-content-wrapper":"",style:{...J,transform:oe?J.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:k,"--radix-popper-transform-origin":[(s=te.transformOrigin)===null||s===void 0?void 0:s.x,(l=te.transformOrigin)===null||l===void 0?void 0:l.y].join(" ")},dir:e.dir},u.createElement(Yw,{scope:d,placedSide:ae,onArrowChange:V,arrowX:U,arrowY:q,shouldHideArrow:re},u.createElement(we.div,ee({"data-side":ae,"data-align":Y},T,{ref:j,style:{...T.style,animation:oe?void 0:"none",opacity:(c=te.hide)!==null&&c!==void 0&&c.referenceHidden?0:void 0}}))))});function Xw(e){return e!==null}const Rw=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,i,a;const{placement:s,rects:l,middlewareData:c}=t,f=((n=c.arrow)===null||n===void 0?void 0:n.centerOffset)!==0,p=f?0:e.arrowWidth,m=f?0:e.arrowHeight,[h,v]=Sf(s),x={start:"0%",center:"50%",end:"100%"}[v],y=((r=(o=c.arrow)===null||o===void 0?void 0:o.x)!==null&&r!==void 0?r:0)+p/2,b=((i=(a=c.arrow)===null||a===void 0?void 0:a.y)!==null&&i!==void 0?i:0)+m/2;let $="",S="";return h==="bottom"?($=f?x:`${y}px`,S=`${-m}px`):h==="top"?($=f?x:`${y}px`,S=`${l.floating.height+m}px`):h==="right"?($=`${-m}px`,S=f?x:`${b}px`):h==="left"&&($=`${l.floating.width+m}px`,S=f?x:`${b}px`),{data:{x:$,y:S}}}});function Sf(e){const[t,n="center"]=e.split("-");return[t,n]}const Zw=Gw,Qw=qw,Jw=Kw,e1=u.forwardRef((e,t)=>{var n;const{container:r=globalThis==null||(n=globalThis.document)===null||n===void 0?void 0:n.body,...o}=e;return r?At.createPortal(u.createElement(we.div,ee({},o,{ref:t})),r):null}),[Xo,X3]=Ct("Tooltip",[wf]),Xa=wf(),t1="TooltipProvider",n1=700,Ra="tooltip.open",[r1,Za]=Xo(t1),o1=e=>{const{__scopeTooltip:t,delayDuration:n=n1,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:i}=e,[a,s]=u.useState(!0),l=u.useRef(!1),c=u.useRef(0);return u.useEffect(()=>{const d=c.current;return()=>window.clearTimeout(d)},[]),u.createElement(r1,{scope:t,isOpenDelayed:a,delayDuration:n,onOpen:u.useCallback(()=>{window.clearTimeout(c.current),s(!1)},[]),onClose:u.useCallback(()=>{window.clearTimeout(c.current),c.current=window.setTimeout(()=>s(!0),r)},[r]),isPointerInTransitRef:l,onPointerInTransitChange:u.useCallback(d=>{l.current=d},[]),disableHoverableContent:o},i)},Qa="Tooltip",[i1,Or]=Xo(Qa),a1=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o=!1,onOpenChange:i,disableHoverableContent:a,delayDuration:s}=e,l=Za(Qa,e.__scopeTooltip),c=Xa(t),[d,f]=u.useState(null),p=Dt(),m=u.useRef(0),h=a??l.disableHoverableContent,v=s??l.delayDuration,x=u.useRef(!1),[y=!1,b]=St({prop:r,defaultProp:o,onChange:O=>{O?(l.onOpen(),document.dispatchEvent(new CustomEvent(Ra))):l.onClose(),i==null||i(O)}}),$=u.useMemo(()=>y?x.current?"delayed-open":"instant-open":"closed",[y]),S=u.useCallback(()=>{window.clearTimeout(m.current),x.current=!1,b(!0)},[b]),w=u.useCallback(()=>{window.clearTimeout(m.current),b(!1)},[b]),T=u.useCallback(()=>{window.clearTimeout(m.current),m.current=window.setTimeout(()=>{x.current=!0,b(!0)},v)},[v,b]);return u.useEffect(()=>()=>window.clearTimeout(m.current),[]),u.createElement(Zw,c,u.createElement(i1,{scope:t,contentId:p,open:y,stateAttribute:$,trigger:d,onTriggerChange:f,onTriggerEnter:u.useCallback(()=>{l.isOpenDelayed?T():S()},[l.isOpenDelayed,T,S]),onTriggerLeave:u.useCallback(()=>{h?w():window.clearTimeout(m.current)},[w,h]),onOpen:S,onClose:w,disableHoverableContent:h},n))},Ef="TooltipTrigger",s1=u.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=Or(Ef,n),i=Za(Ef,n),a=Xa(n),s=u.useRef(null),l=Oe(t,s,o.onTriggerChange),c=u.useRef(!1),d=u.useRef(!1),f=u.useCallback(()=>c.current=!1,[]);return u.useEffect(()=>()=>document.removeEventListener("pointerup",f),[f]),u.createElement(Qw,ee({asChild:!0},a),u.createElement(we.button,ee({"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute},r,{ref:l,onPointerMove:fe(e.onPointerMove,p=>{p.pointerType!=="touch"&&!d.current&&!i.isPointerInTransitRef.current&&(o.onTriggerEnter(),d.current=!0)}),onPointerLeave:fe(e.onPointerLeave,()=>{o.onTriggerLeave(),d.current=!1}),onPointerDown:fe(e.onPointerDown,()=>{c.current=!0,document.addEventListener("pointerup",f,{once:!0})}),onFocus:fe(e.onFocus,()=>{c.current||o.onOpen()}),onBlur:fe(e.onBlur,o.onClose),onClick:fe(e.onClick,o.onClose)})))}),Tf="TooltipPortal",[l1,c1]=Xo(Tf,{forceMount:void 0}),u1=e=>{const{__scopeTooltip:t,forceMount:n,children:r,container:o}=e,i=Or(Tf,t);return u.createElement(l1,{scope:t,forceMount:n},u.createElement(Zt,{present:n||i.open},u.createElement(e1,{asChild:!0,container:o},r)))},_r="TooltipContent",d1=u.forwardRef((e,t)=>{const n=c1(_r,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...i}=e,a=Or(_r,e.__scopeTooltip);return u.createElement(Zt,{present:r||a.open},a.disableHoverableContent?u.createElement(Pf,ee({side:o},i,{ref:t})):u.createElement(f1,ee({side:o},i,{ref:t})))}),f1=u.forwardRef((e,t)=>{const n=Or(_r,e.__scopeTooltip),r=Za(_r,e.__scopeTooltip),o=u.useRef(null),i=Oe(t,o),[a,s]=u.useState(null),{trigger:l,onClose:c}=n,d=o.current,{onPointerInTransitChange:f}=r,p=u.useCallback(()=>{s(null),f(!1)},[f]),m=u.useCallback((h,v)=>{const x=h.currentTarget,y={x:h.clientX,y:h.clientY},b=h1(y,x.getBoundingClientRect()),$=m1(y,b),S=v1(v.getBoundingClientRect()),w=y1([...$,...S]);s(w),f(!0)},[f]);return u.useEffect(()=>()=>p(),[p]),u.useEffect(()=>{if(l&&d){const h=x=>m(x,d),v=x=>m(x,l);return l.addEventListener("pointerleave",h),d.addEventListener("pointerleave",v),()=>{l.removeEventListener("pointerleave",h),d.removeEventListener("pointerleave",v)}}},[l,d,m,p]),u.useEffect(()=>{if(a){const h=v=>{const x=v.target,y={x:v.clientX,y:v.clientY},b=(l==null?void 0:l.contains(x))||(d==null?void 0:d.contains(x)),$=!g1(y,a);b?p():$&&(p(),c())};return document.addEventListener("pointermove",h),()=>document.removeEventListener("pointermove",h)}},[l,d,a,c,p]),u.createElement(Pf,ee({},e,{ref:i}))}),[p1,R3]=Xo(Qa,{isInside:!1}),Pf=u.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:i,onPointerDownOutside:a,...s}=e,l=Or(_r,n),c=Xa(n),{onClose:d}=l;return u.useEffect(()=>(document.addEventListener(Ra,d),()=>document.removeEventListener(Ra,d)),[d]),u.useEffect(()=>{if(l.trigger){const f=p=>{const m=p.target;m!=null&&m.contains(l.trigger)&&d()};return window.addEventListener("scroll",f,{capture:!0}),()=>window.removeEventListener("scroll",f,{capture:!0})}},[l.trigger,d]),u.createElement(Ww,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:i,onPointerDownOutside:a,onFocusOutside:f=>f.preventDefault(),onDismiss:d},u.createElement(Jw,ee({"data-state":l.stateAttribute},c,s,{ref:t,style:{...s.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"}}),u.createElement(Nc,null,r),u.createElement(p1,{scope:n,isInside:!0},u.createElement(Yx,{id:l.contentId,role:"tooltip"},o||r))))});function h1(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),i=Math.abs(t.left-e.x);switch(Math.min(n,r,o,i)){case i:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function m1(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function v1(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}function g1(e,t){const{x:n,y:r}=e;let o=!1;for(let i=0,a=t.length-1;i<t.length;a=i++){const s=t[i].x,l=t[i].y,c=t[a].x,d=t[a].y;l>r!=d>r&&n<(c-s)*(r-l)/(d-l)+s&&(o=!o)}return o}function y1(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),b1(t)}function b1(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const o=e[r];for(;t.length>=2;){const i=t[t.length-1],a=t[t.length-2];if((i.x-a.x)*(o.y-a.y)>=(i.y-a.y)*(o.x-a.x))t.pop();else break}t.push(o)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;n.length>=2;){const i=n[n.length-1],a=n[n.length-2];if((i.x-a.x)*(o.y-a.y)>=(i.y-a.y)*(o.x-a.x))n.pop();else break}n.push(o)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}const x1=o1,w1=a1,$1=s1,C1=u1,Mf=d1,kf=x1,Of=w1,_f=$1,Nf=C1,Ja=u.forwardRef(({className:e,sideOffset:t=4,...n},r)=>L.jsx(Mf,{ref:r,sideOffset:t,className:Ne("z-[1500] overflow-hidden p-2 bg-gray-600 max-w-xs rounded transition-opacity justify-start items-start inline-flex text-center text-white text-xs animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e,"rabbit-ds"),...n}));Ja.displayName=Mf.displayName;var Nr=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Qn(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Jn(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var es={exports:{}},Ro={exports:{}},Pe={};/** @license React v16.13.1
41
+ `)},Cb=0,Xn=[];function Sb(e){var t=me.useRef([]),n=me.useRef([0,0]),r=me.useRef(),o=me.useState(Cb++)[0],i=me.useState(function(){return od()})[0],a=me.useRef(e);me.useEffect(function(){a.current=e},[e]),me.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var v=qy([e.lockRef.current],(e.shards||[]).map(ud),!0).filter(Boolean);return v.forEach(function(x){return x.classList.add("allow-interactivity-".concat(o))}),function(){document.body.classList.remove("block-interactivity-".concat(o)),v.forEach(function(x){return x.classList.remove("allow-interactivity-".concat(o))})}}},[e.inert,e.lockRef.current,e.shards]);var s=me.useCallback(function(v,x){if("touches"in v&&v.touches.length===2)return!a.current.allowPinchZoom;var y=Wo(v),b=n.current,$="deltaX"in v?v.deltaX:b[0]-y[0],S="deltaY"in v?v.deltaY:b[1]-y[1],w,T=v.target,O=Math.abs($)>Math.abs(S)?"h":"v";if("touches"in v&&O==="h"&&T.type==="range")return!1;var P=ad(O,T);if(!P)return!0;if(P?w=O:(w=O==="v"?"h":"v",P=ad(O,T)),!P)return!1;if(!r.current&&"changedTouches"in v&&($||S)&&(r.current=w),!w)return!0;var _=r.current||w;return xb(_,x,v,_==="h"?$:S,!0)},[]),l=me.useCallback(function(v){var x=v;if(!(!Xn.length||Xn[Xn.length-1]!==i)){var y="deltaY"in x?cd(x):Wo(x),b=t.current.filter(function(w){return w.name===x.type&&w.target===x.target&&wb(w.delta,y)})[0];if(b&&b.should){x.cancelable&&x.preventDefault();return}if(!b){var $=(a.current.shards||[]).map(ud).filter(Boolean).filter(function(w){return w.contains(x.target)}),S=$.length>0?s(x,$[0]):!a.current.noIsolation;S&&x.cancelable&&x.preventDefault()}}},[]),c=me.useCallback(function(v,x,y,b){var $={name:v,delta:x,target:y,should:b};t.current.push($),setTimeout(function(){t.current=t.current.filter(function(S){return S!==$})},1)},[]),d=me.useCallback(function(v){n.current=Wo(v),r.current=void 0},[]),f=me.useCallback(function(v){c(v.type,cd(v),v.target,s(v,e.lockRef.current))},[]),p=me.useCallback(function(v){c(v.type,Wo(v),v.target,s(v,e.lockRef.current))},[]);me.useEffect(function(){return Xn.push(i),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:p}),document.addEventListener("wheel",l,Kn),document.addEventListener("touchmove",l,Kn),document.addEventListener("touchstart",d,Kn),function(){Xn=Xn.filter(function(v){return v!==i}),document.removeEventListener("wheel",l,Kn),document.removeEventListener("touchmove",l,Kn),document.removeEventListener("touchstart",d,Kn)}},[]);var m=e.removeScrollBar,h=e.inert;return me.createElement(me.Fragment,null,h?me.createElement(i,{styles:$b(o)}):null,m?me.createElement(pb,{gapMode:"margin"}):null)}const Eb=tb(nd,Sb);var dd=me.forwardRef(function(e,t){return me.createElement(jo,Tt({},e,{ref:t,sideCar:Eb}))});dd.classNames=jo.classNames;const fd=dd,Wa=["Enter"," "],Tb=["ArrowDown","PageUp","Home"],pd=["ArrowUp","PageDown","End"],Pb=[...Tb,...pd],Mb={ltr:[...Wa,"ArrowRight"],rtl:[...Wa,"ArrowLeft"]},kb={ltr:["ArrowLeft"],rtl:["ArrowRight"]},Bo="Menu",[Mr,Ob,_b]=ba(Bo),[Cn,hd]=Ct(Bo,[_b,No,Ao]),Uo=No(),md=Ao(),[vd,rn]=Cn(Bo),[Nb,kr]=Cn(Bo),Ab=e=>{const{__scopeMenu:t,open:n=!1,children:r,dir:o,onOpenChange:i,modal:a=!0}=e,s=Uo(t),[l,c]=u.useState(null),d=u.useRef(!1),f=He(i),p=$o(o);return u.useEffect(()=>{const m=()=>{d.current=!0,document.addEventListener("pointerdown",h,{capture:!0,once:!0}),document.addEventListener("pointermove",h,{capture:!0,once:!0})},h=()=>d.current=!1;return document.addEventListener("keydown",m,{capture:!0}),()=>{document.removeEventListener("keydown",m,{capture:!0}),document.removeEventListener("pointerdown",h,{capture:!0}),document.removeEventListener("pointermove",h,{capture:!0})}},[]),u.createElement(Na,s,u.createElement(vd,{scope:t,open:n,onOpenChange:f,content:l,onContentChange:c},u.createElement(Nb,{scope:t,onClose:u.useCallback(()=>f(!1),[f]),isUsingKeyboardRef:d,dir:p,modal:a},r)))},gd=u.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,o=Uo(n);return u.createElement(Vu,ee({},o,r,{ref:t}))}),yd="MenuPortal",[Db,bd]=Cn(yd,{forceMount:void 0}),Ib=e=>{const{__scopeMenu:t,forceMount:n,children:r,container:o}=e,i=rn(yd,t);return u.createElement(Db,{scope:t,forceMount:n},u.createElement(Zt,{present:n||i.open},u.createElement(Yu,{asChild:!0,container:o},r)))},mt="MenuContent",[Lb,Ba]=Cn(mt),Fb=u.forwardRef((e,t)=>{const n=bd(mt,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,i=rn(mt,e.__scopeMenu),a=kr(mt,e.__scopeMenu);return u.createElement(Mr.Provider,{scope:e.__scopeMenu},u.createElement(Zt,{present:r||i.open},u.createElement(Mr.Slot,{scope:e.__scopeMenu},a.modal?u.createElement(jb,ee({},o,{ref:t})):u.createElement(zb,ee({},o,{ref:t})))))}),jb=u.forwardRef((e,t)=>{const n=rn(mt,e.__scopeMenu),r=u.useRef(null),o=Oe(t,r);return u.useEffect(()=>{const i=r.current;if(i)return Ju(i)},[]),u.createElement(Ua,ee({},e,{ref:o,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:fe(e.onFocusOutside,i=>i.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)}))}),zb=u.forwardRef((e,t)=>{const n=rn(mt,e.__scopeMenu);return u.createElement(Ua,ee({},e,{ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)}))}),Ua=u.forwardRef((e,t)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:o,onOpenAutoFocus:i,onCloseAutoFocus:a,disableOutsidePointerEvents:s,onEntryFocus:l,onEscapeKeyDown:c,onPointerDownOutside:d,onFocusOutside:f,onInteractOutside:p,onDismiss:m,disableOutsideScroll:h,...v}=e,x=rn(mt,n),y=kr(mt,n),b=Uo(n),$=md(n),S=Ob(n),[w,T]=u.useState(null),O=u.useRef(null),P=Oe(t,O,x.onContentChange),_=u.useRef(0),j=u.useRef(""),F=u.useRef(0),V=u.useRef(null),R=u.useRef("right"),X=u.useRef(0),C=h?fd:u.Fragment,I=h?{as:yn,allowPinchZoom:!0}:void 0,H=A=>{var N,z;const J=j.current+A,Q=S().filter(U=>!U.disabled),oe=document.activeElement,te=(N=Q.find(U=>U.ref.current===oe))===null||N===void 0?void 0:N.textValue,ae=Q.map(U=>U.textValue),Y=ox(ae,J,te),le=(z=Q.find(U=>U.textValue===Y))===null||z===void 0?void 0:z.ref.current;(function U(q){j.current=q,window.clearTimeout(_.current),q!==""&&(_.current=window.setTimeout(()=>U(""),1e3))})(J),le&&setTimeout(()=>le.focus())};u.useEffect(()=>()=>window.clearTimeout(_.current),[]),iu();const B=u.useCallback(A=>{var N,z;return R.current===((N=V.current)===null||N===void 0?void 0:N.side)&&ax(A,(z=V.current)===null||z===void 0?void 0:z.area)},[]);return u.createElement(Lb,{scope:n,searchRef:j,onItemEnter:u.useCallback(A=>{B(A)&&A.preventDefault()},[B]),onItemLeave:u.useCallback(A=>{var N;B(A)||((N=O.current)===null||N===void 0||N.focus(),T(null))},[B]),onTriggerLeave:u.useCallback(A=>{B(A)&&A.preventDefault()},[B]),pointerGraceTimerRef:F,onPointerGraceIntentChange:u.useCallback(A=>{V.current=A},[])},u.createElement(C,I,u.createElement(lu,{asChild:!0,trapped:o,onMountAutoFocus:fe(i,A=>{var N;A.preventDefault(),(N=O.current)===null||N===void 0||N.focus()}),onUnmountAutoFocus:a},u.createElement(nu,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:c,onPointerDownOutside:d,onFocusOutside:f,onInteractOutside:p,onDismiss:m},u.createElement(Ru,ee({asChild:!0},$,{dir:y.dir,orientation:"vertical",loop:r,currentTabStopId:w,onCurrentTabStopIdChange:T,onEntryFocus:fe(l,A=>{y.isUsingKeyboardRef.current||A.preventDefault()})}),u.createElement(qu,ee({role:"menu","aria-orientation":"vertical","data-state":Pd(x.open),"data-radix-menu-content":"",dir:y.dir},b,v,{ref:P,style:{outline:"none",...v.style},onKeyDown:fe(v.onKeyDown,A=>{const z=A.target.closest("[data-radix-menu-content]")===A.currentTarget,J=A.ctrlKey||A.altKey||A.metaKey,Q=A.key.length===1;z&&(A.key==="Tab"&&A.preventDefault(),!J&&Q&&H(A.key));const oe=O.current;if(A.target!==oe||!Pb.includes(A.key))return;A.preventDefault();const ae=S().filter(Y=>!Y.disabled).map(Y=>Y.ref.current);pd.includes(A.key)&&ae.reverse(),nx(ae)}),onBlur:fe(e.onBlur,A=>{A.currentTarget.contains(A.target)||(window.clearTimeout(_.current),j.current="")}),onPointerMove:fe(e.onPointerMove,Or(A=>{const N=A.target,z=X.current!==A.clientX;if(A.currentTarget.contains(N)&&z){const J=A.clientX>X.current?"right":"left";R.current=J,X.current=A.clientX}}))})))))))}),xd=u.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.createElement(we.div,ee({role:"group"},r,{ref:t}))}),Wb=u.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.createElement(we.div,ee({},r,{ref:t}))}),Ha="MenuItem",wd="menu.itemSelect",Ga=u.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:r,...o}=e,i=u.useRef(null),a=kr(Ha,e.__scopeMenu),s=Ba(Ha,e.__scopeMenu),l=Oe(t,i),c=u.useRef(!1),d=()=>{const f=i.current;if(!n&&f){const p=new CustomEvent(wd,{bubbles:!0,cancelable:!0});f.addEventListener(wd,m=>r==null?void 0:r(m),{once:!0}),fa(f,p),p.defaultPrevented?c.current=!1:a.onClose()}};return u.createElement($d,ee({},o,{ref:l,disabled:n,onClick:fe(e.onClick,d),onPointerDown:f=>{var p;(p=e.onPointerDown)===null||p===void 0||p.call(e,f),c.current=!0},onPointerUp:fe(e.onPointerUp,f=>{var p;c.current||(p=f.currentTarget)===null||p===void 0||p.click()}),onKeyDown:fe(e.onKeyDown,f=>{const p=s.searchRef.current!=="";n||p&&f.key===" "||Wa.includes(f.key)&&(f.currentTarget.click(),f.preventDefault())})}))}),$d=u.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:r=!1,textValue:o,...i}=e,a=Ba(Ha,n),s=md(n),l=u.useRef(null),c=Oe(t,l),[d,f]=u.useState(!1),[p,m]=u.useState("");return u.useEffect(()=>{const h=l.current;if(h){var v;m(((v=h.textContent)!==null&&v!==void 0?v:"").trim())}},[i.children]),u.createElement(Mr.ItemSlot,{scope:n,disabled:r,textValue:o??p},u.createElement(Zu,ee({asChild:!0},s,{focusable:!r}),u.createElement(we.div,ee({role:"menuitem","data-highlighted":d?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0},i,{ref:c,onPointerMove:fe(e.onPointerMove,Or(h=>{r?a.onItemLeave(h):(a.onItemEnter(h),h.defaultPrevented||h.currentTarget.focus())})),onPointerLeave:fe(e.onPointerLeave,Or(h=>a.onItemLeave(h))),onFocus:fe(e.onFocus,()=>f(!0)),onBlur:fe(e.onBlur,()=>f(!1))}))))}),Bb=u.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:r,...o}=e;return u.createElement(Sd,{scope:e.__scopeMenu,checked:n},u.createElement(Ga,ee({role:"menuitemcheckbox","aria-checked":Go(n)?"mixed":n},o,{ref:t,"data-state":Va(n),onSelect:fe(o.onSelect,()=>r==null?void 0:r(Go(n)?!0:!n),{checkForDefaultPrevented:!1})})))}),Ub="MenuRadioGroup",[Hb,Gb]=Cn(Ub,{value:void 0,onValueChange:()=>{}}),Vb=u.forwardRef((e,t)=>{const{value:n,onValueChange:r,...o}=e,i=He(r);return u.createElement(Hb,{scope:e.__scopeMenu,value:n,onValueChange:i},u.createElement(xd,ee({},o,{ref:t})))}),qb="MenuRadioItem",Yb=u.forwardRef((e,t)=>{const{value:n,...r}=e,o=Gb(qb,e.__scopeMenu),i=n===o.value;return u.createElement(Sd,{scope:e.__scopeMenu,checked:i},u.createElement(Ga,ee({role:"menuitemradio","aria-checked":i},r,{ref:t,"data-state":Va(i),onSelect:fe(r.onSelect,()=>{var a;return(a=o.onValueChange)===null||a===void 0?void 0:a.call(o,n)},{checkForDefaultPrevented:!1})})))}),Cd="MenuItemIndicator",[Sd,Kb]=Cn(Cd,{checked:!1}),Xb=u.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:r,...o}=e,i=Kb(Cd,n);return u.createElement(Zt,{present:r||Go(i.checked)||i.checked===!0},u.createElement(we.span,ee({},o,{ref:t,"data-state":Va(i.checked)})))}),Rb=u.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return u.createElement(we.div,ee({role:"separator","aria-orientation":"horizontal"},r,{ref:t}))}),Ed="MenuSub",[Zb,Td]=Cn(Ed),Qb=e=>{const{__scopeMenu:t,children:n,open:r=!1,onOpenChange:o}=e,i=rn(Ed,t),a=Uo(t),[s,l]=u.useState(null),[c,d]=u.useState(null),f=He(o);return u.useEffect(()=>(i.open===!1&&f(!1),()=>f(!1)),[i.open,f]),u.createElement(Na,a,u.createElement(vd,{scope:t,open:r,onOpenChange:f,content:c,onContentChange:d},u.createElement(Zb,{scope:t,contentId:Dt(),triggerId:Dt(),trigger:s,onTriggerChange:l},n)))},Ho="MenuSubTrigger",Jb=u.forwardRef((e,t)=>{const n=rn(Ho,e.__scopeMenu),r=kr(Ho,e.__scopeMenu),o=Td(Ho,e.__scopeMenu),i=Ba(Ho,e.__scopeMenu),a=u.useRef(null),{pointerGraceTimerRef:s,onPointerGraceIntentChange:l}=i,c={__scopeMenu:e.__scopeMenu},d=u.useCallback(()=>{a.current&&window.clearTimeout(a.current),a.current=null},[]);return u.useEffect(()=>d,[d]),u.useEffect(()=>{const f=s.current;return()=>{window.clearTimeout(f),l(null)}},[s,l]),u.createElement(gd,ee({asChild:!0},c),u.createElement($d,ee({id:o.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":o.contentId,"data-state":Pd(n.open)},e,{ref:bo(t,o.onTriggerChange),onClick:f=>{var p;(p=e.onClick)===null||p===void 0||p.call(e,f),!(e.disabled||f.defaultPrevented)&&(f.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:fe(e.onPointerMove,Or(f=>{i.onItemEnter(f),!f.defaultPrevented&&!e.disabled&&!n.open&&!a.current&&(i.onPointerGraceIntentChange(null),a.current=window.setTimeout(()=>{n.onOpenChange(!0),d()},100))})),onPointerLeave:fe(e.onPointerLeave,Or(f=>{var p;d();const m=(p=n.content)===null||p===void 0?void 0:p.getBoundingClientRect();if(m){var h;const v=(h=n.content)===null||h===void 0?void 0:h.dataset.side,x=v==="right",y=x?-5:5,b=m[x?"left":"right"],$=m[x?"right":"left"];i.onPointerGraceIntentChange({area:[{x:f.clientX+y,y:f.clientY},{x:b,y:m.top},{x:$,y:m.top},{x:$,y:m.bottom},{x:b,y:m.bottom}],side:v}),window.clearTimeout(s.current),s.current=window.setTimeout(()=>i.onPointerGraceIntentChange(null),300)}else{if(i.onTriggerLeave(f),f.defaultPrevented)return;i.onPointerGraceIntentChange(null)}})),onKeyDown:fe(e.onKeyDown,f=>{const p=i.searchRef.current!=="";if(!(e.disabled||p&&f.key===" ")&&Mb[r.dir].includes(f.key)){var m;n.onOpenChange(!0),(m=n.content)===null||m===void 0||m.focus(),f.preventDefault()}})})))}),ex="MenuSubContent",tx=u.forwardRef((e,t)=>{const n=bd(mt,e.__scopeMenu),{forceMount:r=n.forceMount,...o}=e,i=rn(mt,e.__scopeMenu),a=kr(mt,e.__scopeMenu),s=Td(ex,e.__scopeMenu),l=u.useRef(null),c=Oe(t,l);return u.createElement(Mr.Provider,{scope:e.__scopeMenu},u.createElement(Zt,{present:r||i.open},u.createElement(Mr.Slot,{scope:e.__scopeMenu},u.createElement(Ua,ee({id:s.contentId,"aria-labelledby":s.triggerId},o,{ref:c,align:"start",side:a.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:d=>{var f;a.isUsingKeyboardRef.current&&((f=l.current)===null||f===void 0||f.focus()),d.preventDefault()},onCloseAutoFocus:d=>d.preventDefault(),onFocusOutside:fe(e.onFocusOutside,d=>{d.target!==s.trigger&&i.onOpenChange(!1)}),onEscapeKeyDown:fe(e.onEscapeKeyDown,d=>{a.onClose(),d.preventDefault()}),onKeyDown:fe(e.onKeyDown,d=>{const f=d.currentTarget.contains(d.target),p=kb[a.dir].includes(d.key);if(f&&p){var m;i.onOpenChange(!1),(m=s.trigger)===null||m===void 0||m.focus(),d.preventDefault()}})})))))});function Pd(e){return e?"open":"closed"}function Go(e){return e==="indeterminate"}function Va(e){return Go(e)?"indeterminate":e?"checked":"unchecked"}function nx(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function rx(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function ox(e,t,n){const o=t.length>1&&Array.from(t).every(c=>c===t[0])?t[0]:t,i=n?e.indexOf(n):-1;let a=rx(e,Math.max(i,0));o.length===1&&(a=a.filter(c=>c!==n));const l=a.find(c=>c.toLowerCase().startsWith(o.toLowerCase()));return l!==n?l:void 0}function ix(e,t){const{x:n,y:r}=e;let o=!1;for(let i=0,a=t.length-1;i<t.length;a=i++){const s=t[i].x,l=t[i].y,c=t[a].x,d=t[a].y;l>r!=d>r&&n<(c-s)*(r-l)/(d-l)+s&&(o=!o)}return o}function ax(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return ix(n,t)}function Or(e){return t=>t.pointerType==="mouse"?e(t):void 0}const sx=Ab,lx=gd,cx=Ib,ux=Fb,dx=xd,fx=Wb,px=Ga,hx=Bb,mx=Vb,vx=Yb,gx=Xb,yx=Rb,bx=Qb,xx=Jb,wx=tx,Md="DropdownMenu",[$x,X3]=Ct(Md,[hd]),Ge=hd(),[Cx,kd]=$x(Md),Sx=e=>{const{__scopeDropdownMenu:t,children:n,dir:r,open:o,defaultOpen:i,onOpenChange:a,modal:s=!0}=e,l=Ge(t),c=u.useRef(null),[d=!1,f]=St({prop:o,defaultProp:i,onChange:a});return u.createElement(Cx,{scope:t,triggerId:Dt(),triggerRef:c,contentId:Dt(),open:d,onOpenChange:f,onOpenToggle:u.useCallback(()=>f(p=>!p),[f]),modal:s},u.createElement(sx,ee({},l,{open:d,onOpenChange:f,dir:r,modal:s}),n))},Ex="DropdownMenuTrigger",Tx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:r=!1,...o}=e,i=kd(Ex,n),a=Ge(n);return u.createElement(lx,ee({asChild:!0},a),u.createElement(we.button,ee({type:"button",id:i.triggerId,"aria-haspopup":"menu","aria-expanded":i.open,"aria-controls":i.open?i.contentId:void 0,"data-state":i.open?"open":"closed","data-disabled":r?"":void 0,disabled:r},o,{ref:bo(t,i.triggerRef),onPointerDown:fe(e.onPointerDown,s=>{!r&&s.button===0&&s.ctrlKey===!1&&(i.onOpenToggle(),i.open||s.preventDefault())}),onKeyDown:fe(e.onKeyDown,s=>{r||(["Enter"," "].includes(s.key)&&i.onOpenToggle(),s.key==="ArrowDown"&&i.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(s.key)&&s.preventDefault())})})))}),Px=e=>{const{__scopeDropdownMenu:t,...n}=e,r=Ge(t);return u.createElement(cx,ee({},r,n))},Mx="DropdownMenuContent",kx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=kd(Mx,n),i=Ge(n),a=u.useRef(!1);return u.createElement(ux,ee({id:o.contentId,"aria-labelledby":o.triggerId},i,r,{ref:t,onCloseAutoFocus:fe(e.onCloseAutoFocus,s=>{var l;a.current||(l=o.triggerRef.current)===null||l===void 0||l.focus(),a.current=!1,s.preventDefault()}),onInteractOutside:fe(e.onInteractOutside,s=>{const l=s.detail.originalEvent,c=l.button===0&&l.ctrlKey===!0,d=l.button===2||c;(!o.modal||d)&&(a.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}}))}),Ox=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(dx,ee({},o,r,{ref:t}))}),_x=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(fx,ee({},o,r,{ref:t}))}),Nx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(px,ee({},o,r,{ref:t}))}),Ax=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(hx,ee({},o,r,{ref:t}))}),Dx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(mx,ee({},o,r,{ref:t}))}),Ix=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(vx,ee({},o,r,{ref:t}))}),Lx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(gx,ee({},o,r,{ref:t}))}),Fx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(yx,ee({},o,r,{ref:t}))}),jx=e=>{const{__scopeDropdownMenu:t,children:n,open:r,onOpenChange:o,defaultOpen:i}=e,a=Ge(t),[s=!1,l]=St({prop:r,defaultProp:i,onChange:o});return u.createElement(bx,ee({},a,{open:s,onOpenChange:l}),n)},zx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(xx,ee({},o,r,{ref:t}))}),Wx=u.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,o=Ge(n);return u.createElement(wx,ee({},o,r,{ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}}))}),Bx=Sx,Ux=Tx,Od=Px,_d=kx,Nd=Ox,Ad=_x,Dd=Nx,Id=Ax,Hx=Dx,Ld=Ix,Fd=Lx,jd=Fx,Gx=jx,zd=zx,Wd=Wx,Vx=Bx,qx=Ux,Yx=Od,Kx=Gx,Xx=Hx,Bd=u.forwardRef(({className:e,...t},n)=>L.jsx(Nd,{ref:n,className:_e("w-full",e),...t}));Bd.displayName=Nd.displayName;const Ud=u.forwardRef(({className:e,children:t,...n},r)=>L.jsxs(zd,{ref:r,className:_e("flex cursor-default select-none px-2 py-1.5 bg-white rounded hover:bg-sky-100 hover:text-sky-800 hover:cursor-pointer justify-start items-start text-zinc-800 text-sm font-normal leading-tight focus:bg-sky-100 focus:text-sky-800 data-[state=checked]:bg-sky-100 data-[state=checked]:text-sky-800 focus:outline-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[t,L.jsx(Qg,{className:"ml-auto h-4 w-4"})]}));Ud.displayName=zd.displayName;const Hd=u.forwardRef(({className:e,...t},n)=>L.jsx(Wd,{ref:n,className:_e("rabbit-ds z-[1510] rabbit-ds min-w-[8rem] max-w-xs p-1 bg-white rounded-lg shadow flex flex-col justify-start items-start gap-1 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...t}));Hd.displayName=Wd.displayName;const Gd=u.forwardRef(({className:e,sideOffset:t=4,...n},r)=>L.jsx(Od,{children:L.jsx(_d,{ref:r,sideOffset:t,className:_e("rabbit-ds z-[1500] rabbit-ds min-w-[8rem] max-w-xs p-1 bg-white rounded-lg shadow flex flex-col justify-start items-start gap-1 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...n})}));Gd.displayName=_d.displayName;const Vd=u.forwardRef(({className:e,...t},n)=>L.jsx(Dd,{ref:n,className:_e("relative flex flex-row w-full my-1 cursor-default select-none p-2 bg-white rounded hover:bg-sky-100 hover:text-sky-800 hover:cursor-pointer justify-start items-start text-zinc-800 text-sm font-normal leading-tight focus:bg-sky-100 focus:text-sky-800 data-[state=checked]:bg-sky-100 data-[state=checked]:text-sky-800 focus:outline-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...t}));Vd.displayName=Dd.displayName;const qd=u.forwardRef(({className:e,children:t,checked:n,...r},o)=>L.jsxs(Id,{ref:o,className:_e("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),checked:n,...r,children:[L.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:L.jsx(Fd,{children:L.jsx(pa,{className:"h-4 w-4 text-sky-800"})})}),t]}));qd.displayName=Id.displayName;const Yd=u.forwardRef(({className:e,children:t,...n},r)=>L.jsxs(Ld,{ref:r,className:_e("relative flex cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none transition-colors focus:bg-accent focus:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[L.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:L.jsx(Fd,{children:L.jsx(Jg,{className:"h-2 w-2 fill-current text-sky-800"})})}),t]}));Yd.displayName=Ld.displayName;const Kd=u.forwardRef(({className:e,...t},n)=>L.jsx(Ad,{ref:n,className:_e("px-2 py-1.5 text-sm font-semibold",e),...t}));Kd.displayName=Ad.displayName;const Xd=u.forwardRef(({className:e,...t},n)=>L.jsx(jd,{ref:n,className:_e("h-px w-full bg-athens-gray-100",e),...t}));Xd.displayName=jd.displayName;function Rd(e,[t,n]){return Math.min(n,Math.max(t,e))}const Zd=u.forwardRef((e,t)=>u.createElement(we.span,ee({},e,{ref:t,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}}))),Rx=Zd,Zx=[" ","Enter","ArrowUp","ArrowDown"],Qx=[" ","Enter"],Vo="Select",[qo,qa,Jx]=ba(Vo),[Rn,R3]=Ct(Vo,[Jx,No]),Ya=No(),[ew,Sn]=Rn(Vo),[tw,nw]=Rn(Vo),rw=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:o,onOpenChange:i,value:a,defaultValue:s,onValueChange:l,dir:c,name:d,autoComplete:f,disabled:p,required:m}=e,h=Ya(t),[v,x]=u.useState(null),[y,b]=u.useState(null),[$,S]=u.useState(!1),w=$o(c),[T=!1,O]=St({prop:r,defaultProp:o,onChange:i}),[P,_]=St({prop:a,defaultProp:s,onChange:l}),j=u.useRef(null),F=v?!!v.closest("form"):!0,[V,R]=u.useState(new Set),X=Array.from(V).map(C=>C.props.value).join(";");return u.createElement(Na,h,u.createElement(ew,{required:m,scope:t,trigger:v,onTriggerChange:x,valueNode:y,onValueNodeChange:b,valueNodeHasChildren:$,onValueNodeHasChildrenChange:S,contentId:Dt(),value:P,onValueChange:_,open:T,onOpenChange:O,dir:w,triggerPointerDownPosRef:j,disabled:p},u.createElement(qo.Provider,{scope:t},u.createElement(tw,{scope:e.__scopeSelect,onNativeOptionAdd:u.useCallback(C=>{R(I=>new Set(I).add(C))},[]),onNativeOptionRemove:u.useCallback(C=>{R(I=>{const H=new Set(I);return H.delete(C),H})},[])},n)),F?u.createElement(rf,{key:X,"aria-hidden":!0,required:m,tabIndex:-1,name:d,autoComplete:f,value:P,onChange:C=>_(C.target.value),disabled:p},P===void 0?u.createElement("option",{value:""}):null,Array.from(V)):null))},ow="SelectTrigger",iw=u.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...o}=e,i=Ya(n),a=Sn(ow,n),s=a.disabled||r,l=Oe(t,a.onTriggerChange),c=qa(n),[d,f,p]=of(h=>{const v=c().filter(b=>!b.disabled),x=v.find(b=>b.value===a.value),y=af(v,h,x);y!==void 0&&a.onValueChange(y.value)}),m=()=>{s||(a.onOpenChange(!0),p())};return u.createElement(Vu,ee({asChild:!0},i),u.createElement(we.button,ee({type:"button",role:"combobox","aria-controls":a.contentId,"aria-expanded":a.open,"aria-required":a.required,"aria-autocomplete":"none",dir:a.dir,"data-state":a.open?"open":"closed",disabled:s,"data-disabled":s?"":void 0,"data-placeholder":nf(a.value)?"":void 0},o,{ref:l,onClick:fe(o.onClick,h=>{h.currentTarget.focus()}),onPointerDown:fe(o.onPointerDown,h=>{const v=h.target;v.hasPointerCapture(h.pointerId)&&v.releasePointerCapture(h.pointerId),h.button===0&&h.ctrlKey===!1&&(m(),a.triggerPointerDownPosRef.current={x:Math.round(h.pageX),y:Math.round(h.pageY)},h.preventDefault())}),onKeyDown:fe(o.onKeyDown,h=>{const v=d.current!=="";!(h.ctrlKey||h.altKey||h.metaKey)&&h.key.length===1&&f(h.key),!(v&&h.key===" ")&&Zx.includes(h.key)&&(m(),h.preventDefault())})})))}),aw="SelectValue",sw=u.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,children:i,placeholder:a="",...s}=e,l=Sn(aw,n),{onValueNodeHasChildrenChange:c}=l,d=i!==void 0,f=Oe(t,l.onValueNodeChange);return ot(()=>{c(d)},[c,d]),u.createElement(we.span,ee({},s,{ref:f,style:{pointerEvents:"none"}}),nf(l.value)?u.createElement(u.Fragment,null,a):i)}),lw=u.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...o}=e;return u.createElement(we.span,ee({"aria-hidden":!0},o,{ref:t}),r||"▼")}),cw=e=>u.createElement(Yu,ee({asChild:!0},e)),Zn="SelectContent",uw=u.forwardRef((e,t)=>{const n=Sn(Zn,e.__scopeSelect),[r,o]=u.useState();if(ot(()=>{o(new DocumentFragment)},[]),!n.open){const i=r;return i?At.createPortal(u.createElement(Qd,{scope:e.__scopeSelect},u.createElement(qo.Slot,{scope:e.__scopeSelect},u.createElement("div",null,e.children))),i):null}return u.createElement(dw,ee({},e,{ref:t}))}),zt=10,[Qd,Yo]=Rn(Zn),dw=u.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:o,onEscapeKeyDown:i,onPointerDownOutside:a,side:s,sideOffset:l,align:c,alignOffset:d,arrowPadding:f,collisionBoundary:p,collisionPadding:m,sticky:h,hideWhenDetached:v,avoidCollisions:x,...y}=e,b=Sn(Zn,n),[$,S]=u.useState(null),[w,T]=u.useState(null),O=Oe(t,Y=>S(Y)),[P,_]=u.useState(null),[j,F]=u.useState(null),V=qa(n),[R,X]=u.useState(!1),C=u.useRef(!1);u.useEffect(()=>{if($)return Ju($)},[$]),iu();const I=u.useCallback(Y=>{const[le,...U]=V().map(k=>k.ref.current),[q]=U.slice(-1),re=document.activeElement;for(const k of Y)if(k===re||(k==null||k.scrollIntoView({block:"nearest"}),k===le&&w&&(w.scrollTop=0),k===q&&w&&(w.scrollTop=w.scrollHeight),k==null||k.focus(),document.activeElement!==re))return},[V,w]),H=u.useCallback(()=>I([P,$]),[I,P,$]);u.useEffect(()=>{R&&H()},[R,H]);const{onOpenChange:B,triggerPointerDownPosRef:A}=b;u.useEffect(()=>{if($){let Y={x:0,y:0};const le=q=>{var re,k,de,pe;Y={x:Math.abs(Math.round(q.pageX)-((re=(k=A.current)===null||k===void 0?void 0:k.x)!==null&&re!==void 0?re:0)),y:Math.abs(Math.round(q.pageY)-((de=(pe=A.current)===null||pe===void 0?void 0:pe.y)!==null&&de!==void 0?de:0))}},U=q=>{Y.x<=10&&Y.y<=10?q.preventDefault():$.contains(q.target)||B(!1),document.removeEventListener("pointermove",le),A.current=null};return A.current!==null&&(document.addEventListener("pointermove",le),document.addEventListener("pointerup",U,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",le),document.removeEventListener("pointerup",U,{capture:!0})}}},[$,B,A]),u.useEffect(()=>{const Y=()=>B(!1);return window.addEventListener("blur",Y),window.addEventListener("resize",Y),()=>{window.removeEventListener("blur",Y),window.removeEventListener("resize",Y)}},[B]);const[N,z]=of(Y=>{const le=V().filter(re=>!re.disabled),U=le.find(re=>re.ref.current===document.activeElement),q=af(le,Y,U);q&&setTimeout(()=>q.ref.current.focus())}),J=u.useCallback((Y,le,U)=>{const q=!C.current&&!U;(b.value!==void 0&&b.value===le||q)&&(_(Y),q&&(C.current=!0))},[b.value]),Q=u.useCallback(()=>$==null?void 0:$.focus(),[$]),oe=u.useCallback((Y,le,U)=>{const q=!C.current&&!U;(b.value!==void 0&&b.value===le||q)&&F(Y)},[b.value]),te=r==="popper"?Jd:fw,ae=te===Jd?{side:s,sideOffset:l,align:c,alignOffset:d,arrowPadding:f,collisionBoundary:p,collisionPadding:m,sticky:h,hideWhenDetached:v,avoidCollisions:x}:{};return u.createElement(Qd,{scope:n,content:$,viewport:w,onViewportChange:T,itemRefCallback:J,selectedItem:P,onItemLeave:Q,itemTextRefCallback:oe,focusSelectedItem:H,selectedItemText:j,position:r,isPositioned:R,searchRef:N},u.createElement(fd,{as:yn,allowPinchZoom:!0},u.createElement(lu,{asChild:!0,trapped:b.open,onMountAutoFocus:Y=>{Y.preventDefault()},onUnmountAutoFocus:fe(o,Y=>{var le;(le=b.trigger)===null||le===void 0||le.focus({preventScroll:!0}),Y.preventDefault()})},u.createElement(nu,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:i,onPointerDownOutside:a,onFocusOutside:Y=>Y.preventDefault(),onDismiss:()=>b.onOpenChange(!1)},u.createElement(te,ee({role:"listbox",id:b.contentId,"data-state":b.open?"open":"closed",dir:b.dir,onContextMenu:Y=>Y.preventDefault()},y,ae,{onPlaced:()=>X(!0),ref:O,style:{display:"flex",flexDirection:"column",outline:"none",...y.style},onKeyDown:fe(y.onKeyDown,Y=>{const le=Y.ctrlKey||Y.altKey||Y.metaKey;if(Y.key==="Tab"&&Y.preventDefault(),!le&&Y.key.length===1&&z(Y.key),["ArrowUp","ArrowDown","Home","End"].includes(Y.key)){let q=V().filter(re=>!re.disabled).map(re=>re.ref.current);if(["ArrowUp","End"].includes(Y.key)&&(q=q.slice().reverse()),["ArrowUp","ArrowDown"].includes(Y.key)){const re=Y.target,k=q.indexOf(re);q=q.slice(k+1)}setTimeout(()=>I(q)),Y.preventDefault()}})}))))))}),fw=u.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...o}=e,i=Sn(Zn,n),a=Yo(Zn,n),[s,l]=u.useState(null),[c,d]=u.useState(null),f=Oe(t,O=>d(O)),p=qa(n),m=u.useRef(!1),h=u.useRef(!0),{viewport:v,selectedItem:x,selectedItemText:y,focusSelectedItem:b}=a,$=u.useCallback(()=>{if(i.trigger&&i.valueNode&&s&&c&&v&&x&&y){const O=i.trigger.getBoundingClientRect(),P=c.getBoundingClientRect(),_=i.valueNode.getBoundingClientRect(),j=y.getBoundingClientRect();if(i.dir!=="rtl"){const re=j.left-P.left,k=_.left-re,de=O.left-k,pe=O.width+de,Ce=Math.max(pe,P.width),ke=window.innerWidth-zt,je=Rd(k,[zt,ke-Ce]);s.style.minWidth=pe+"px",s.style.left=je+"px"}else{const re=P.right-j.right,k=window.innerWidth-_.right-re,de=window.innerWidth-O.right-k,pe=O.width+de,Ce=Math.max(pe,P.width),ke=window.innerWidth-zt,je=Rd(k,[zt,ke-Ce]);s.style.minWidth=pe+"px",s.style.right=je+"px"}const F=p(),V=window.innerHeight-zt*2,R=v.scrollHeight,X=window.getComputedStyle(c),C=parseInt(X.borderTopWidth,10),I=parseInt(X.paddingTop,10),H=parseInt(X.borderBottomWidth,10),B=parseInt(X.paddingBottom,10),A=C+I+R+B+H,N=Math.min(x.offsetHeight*5,A),z=window.getComputedStyle(v),J=parseInt(z.paddingTop,10),Q=parseInt(z.paddingBottom,10),oe=O.top+O.height/2-zt,te=V-oe,ae=x.offsetHeight/2,Y=x.offsetTop+ae,le=C+I+Y,U=A-le;if(le<=oe){const re=x===F[F.length-1].ref.current;s.style.bottom="0px";const k=c.clientHeight-v.offsetTop-v.offsetHeight,de=Math.max(te,ae+(re?Q:0)+k+H),pe=le+de;s.style.height=pe+"px"}else{const re=x===F[0].ref.current;s.style.top="0px";const de=Math.max(oe,C+v.offsetTop+(re?J:0)+ae)+U;s.style.height=de+"px",v.scrollTop=le-oe+v.offsetTop}s.style.margin=`${zt}px 0`,s.style.minHeight=N+"px",s.style.maxHeight=V+"px",r==null||r(),requestAnimationFrame(()=>m.current=!0)}},[p,i.trigger,i.valueNode,s,c,v,x,y,i.dir,r]);ot(()=>$(),[$]);const[S,w]=u.useState();ot(()=>{c&&w(window.getComputedStyle(c).zIndex)},[c]);const T=u.useCallback(O=>{O&&h.current===!0&&($(),b==null||b(),h.current=!1)},[$,b]);return u.createElement(pw,{scope:n,contentWrapper:s,shouldExpandOnScrollRef:m,onScrollButtonChange:T},u.createElement("div",{ref:l,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:S}},u.createElement(we.div,ee({},o,{ref:f,style:{boxSizing:"border-box",maxHeight:"100%",...o.style}}))))}),Jd=u.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:o=zt,...i}=e,a=Ya(n);return u.createElement(qu,ee({},a,i,{ref:t,align:r,collisionPadding:o,style:{boxSizing:"border-box",...i.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}}))}),[pw,hw]=Rn(Zn,{}),ef="SelectViewport",mw=u.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=Yo(ef,n),i=hw(ef,n),a=Oe(t,o.onViewportChange),s=u.useRef(0);return u.createElement(u.Fragment,null,u.createElement("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"}}),u.createElement(qo.Slot,{scope:n},u.createElement(we.div,ee({"data-radix-select-viewport":"",role:"presentation"},r,{ref:a,style:{position:"relative",flex:1,overflow:"auto",...r.style},onScroll:fe(r.onScroll,l=>{const c=l.currentTarget,{contentWrapper:d,shouldExpandOnScrollRef:f}=i;if(f!=null&&f.current&&d){const p=Math.abs(s.current-c.scrollTop);if(p>0){const m=window.innerHeight-zt*2,h=parseFloat(d.style.minHeight),v=parseFloat(d.style.height),x=Math.max(h,v);if(x<m){const y=x+p,b=Math.min(m,y),$=y-b;d.style.height=b+"px",d.style.bottom==="0px"&&(c.scrollTop=$>0?$:0,d.style.justifyContent="flex-end")}}}s.current=c.scrollTop})}))))}),vw="SelectGroup",[gw,yw]=Rn(vw),bw=u.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=Dt();return u.createElement(gw,{scope:n,id:o},u.createElement(we.div,ee({role:"group","aria-labelledby":o},r,{ref:t})))}),xw="SelectLabel",ww=u.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,o=yw(xw,n);return u.createElement(we.div,ee({id:o.id},r,{ref:t}))}),Ka="SelectItem",[$w,tf]=Rn(Ka),Cw=u.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:o=!1,textValue:i,...a}=e,s=Sn(Ka,n),l=Yo(Ka,n),c=s.value===r,[d,f]=u.useState(i??""),[p,m]=u.useState(!1),h=Oe(t,y=>{var b;return(b=l.itemRefCallback)===null||b===void 0?void 0:b.call(l,y,r,o)}),v=Dt(),x=()=>{o||(s.onValueChange(r),s.onOpenChange(!1))};if(r==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return u.createElement($w,{scope:n,value:r,disabled:o,textId:v,isSelected:c,onItemTextChange:u.useCallback(y=>{f(b=>{var $;return b||(($=y==null?void 0:y.textContent)!==null&&$!==void 0?$:"").trim()})},[])},u.createElement(qo.ItemSlot,{scope:n,value:r,disabled:o,textValue:d},u.createElement(we.div,ee({role:"option","aria-labelledby":v,"data-highlighted":p?"":void 0,"aria-selected":c&&p,"data-state":c?"checked":"unchecked","aria-disabled":o||void 0,"data-disabled":o?"":void 0,tabIndex:o?void 0:-1},a,{ref:h,onFocus:fe(a.onFocus,()=>m(!0)),onBlur:fe(a.onBlur,()=>m(!1)),onPointerUp:fe(a.onPointerUp,x),onPointerMove:fe(a.onPointerMove,y=>{if(o){var b;(b=l.onItemLeave)===null||b===void 0||b.call(l)}else y.currentTarget.focus({preventScroll:!0})}),onPointerLeave:fe(a.onPointerLeave,y=>{if(y.currentTarget===document.activeElement){var b;(b=l.onItemLeave)===null||b===void 0||b.call(l)}}),onKeyDown:fe(a.onKeyDown,y=>{var b;((b=l.searchRef)===null||b===void 0?void 0:b.current)!==""&&y.key===" "||(Qx.includes(y.key)&&x(),y.key===" "&&y.preventDefault())})}))))}),Ko="SelectItemText",Sw=u.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:o,...i}=e,a=Sn(Ko,n),s=Yo(Ko,n),l=tf(Ko,n),c=nw(Ko,n),[d,f]=u.useState(null),p=Oe(t,y=>f(y),l.onItemTextChange,y=>{var b;return(b=s.itemTextRefCallback)===null||b===void 0?void 0:b.call(s,y,l.value,l.disabled)}),m=d==null?void 0:d.textContent,h=u.useMemo(()=>u.createElement("option",{key:l.value,value:l.value,disabled:l.disabled},m),[l.disabled,l.value,m]),{onNativeOptionAdd:v,onNativeOptionRemove:x}=c;return ot(()=>(v(h),()=>x(h)),[v,x,h]),u.createElement(u.Fragment,null,u.createElement(we.span,ee({id:l.textId},i,{ref:p})),l.isSelected&&a.valueNode&&!a.valueNodeHasChildren?At.createPortal(i.children,a.valueNode):null)}),Ew="SelectItemIndicator",Tw=u.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return tf(Ew,n).isSelected?u.createElement(we.span,ee({"aria-hidden":!0},r,{ref:t})):null}),Pw=u.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return u.createElement(we.div,ee({"aria-hidden":!0},r,{ref:t}))});function nf(e){return e===""||e===void 0}const rf=u.forwardRef((e,t)=>{const{value:n,...r}=e,o=u.useRef(null),i=Oe(t,o),a=Nc(n);return u.useEffect(()=>{const s=o.current,l=window.HTMLSelectElement.prototype,d=Object.getOwnPropertyDescriptor(l,"value").set;if(a!==n&&d){const f=new Event("change",{bubbles:!0});d.call(s,n),s.dispatchEvent(f)}},[a,n]),u.createElement(Zd,{asChild:!0},u.createElement("select",ee({},r,{ref:i,defaultValue:n})))});rf.displayName="BubbleSelect";function of(e){const t=He(e),n=u.useRef(""),r=u.useRef(0),o=u.useCallback(a=>{const s=n.current+a;t(s),function l(c){n.current=c,window.clearTimeout(r.current),c!==""&&(r.current=window.setTimeout(()=>l(""),1e3))}(s)},[t]),i=u.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return u.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,o,i]}function af(e,t,n){const o=t.length>1&&Array.from(t).every(c=>c===t[0])?t[0]:t,i=n?e.indexOf(n):-1;let a=Mw(e,Math.max(i,0));o.length===1&&(a=a.filter(c=>c!==n));const l=a.find(c=>c.textValue.toLowerCase().startsWith(o.toLowerCase()));return l!==n?l:void 0}function Mw(e,t){return e.map((n,r)=>e[(t+r)%e.length])}const kw=rw,sf=iw,Ow=sw,_w=lw,Nw=cw,lf=uw,Aw=mw,Dw=bw,cf=ww,uf=Cw,Iw=Sw,Lw=Tw,df=Pw,Fw=kw,jw=Dw,zw=Ow,ff=u.forwardRef(({className:e,children:t,...n},r)=>L.jsx("div",{className:"rabbit-ds",children:L.jsxs(sf,{ref:r,className:_e("rabbit-ds h-10 pr-3 py-2.5 rounded-tl text-sm rounded-tr border-b border-dashed hover:border-solid border-zinc-800 justify-between items-center gap-2 inline-flex focus:outline-none focus:border-solid disabled:cursor-not-allowed disabled:opacity-50",e),...n,children:[t,L.jsx(_w,{asChild:!0,children:L.jsx(Zg,{className:"h-4 w-4"})})]})}));ff.displayName=sf.displayName;const pf=u.forwardRef(({className:e,children:t,position:n="popper",...r},o)=>L.jsx(Nw,{children:L.jsx(lf,{ref:o,className:_e("relative z-[1500] rabbit-ds min-w-[8rem] max-w-xs p-1 bg-white rounded-lg shadow flex-col justify-start items-start gap-1 inline-flex data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:n,...r,children:L.jsx(Aw,{className:_e("p-1",n==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t})})}));pf.displayName=lf.displayName;const hf=u.forwardRef(({className:e,...t},n)=>L.jsx(cf,{ref:n,className:_e("py-1.5 px-2 text-sm font-semibold",e),...t}));hf.displayName=cf.displayName;const mf=u.forwardRef(({className:e,children:t,...n},r)=>L.jsxs(uf,{ref:r,className:_e("relative flex w-full my-1 cursor-default select-none p-2 bg-white rounded flex-col hover:bg-sky-100 hover:text-sky-800 hover:cursor-pointer justify-start items-start text-zinc-800 text-sm font-normal leading-tight focus:bg-sky-100 focus:text-sky-800 data-[state=checked]:bg-sky-100 data-[state=checked]:text-sky-800 focus:outline-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50",e),...n,children:[L.jsx("span",{className:"absolute right-2 flex h-4 w-4 items-center justify-center",children:L.jsx(Lw,{children:L.jsx(pa,{className:"h-4 w-4 text-sky-800"})})}),L.jsx(Iw,{children:t})]}));mf.displayName=uf.displayName;const vf=u.forwardRef(({className:e,...t},n)=>L.jsx(df,{ref:n,className:_e("-mx-1 my-1 h-px bg-muted",e),...t}));vf.displayName=df.displayName;const Xa="dismissableLayer.update",Ww="dismissableLayer.pointerDownOutside",Bw="dismissableLayer.focusOutside";let gf;const Uw=u.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Hw=u.forwardRef((e,t)=>{var n;const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:i,onFocusOutside:a,onInteractOutside:s,onDismiss:l,...c}=e,d=u.useContext(Uw),[f,p]=u.useState(null),m=(n=f==null?void 0:f.ownerDocument)!==null&&n!==void 0?n:globalThis==null?void 0:globalThis.document,[,h]=u.useState({}),v=Oe(t,P=>p(P)),x=Array.from(d.layers),[y]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),b=x.indexOf(y),$=f?x.indexOf(f):-1,S=d.layersWithOutsidePointerEventsDisabled.size>0,w=$>=b,T=Gw(P=>{const _=P.target,j=[...d.branches].some(F=>F.contains(_));!w||j||(i==null||i(P),s==null||s(P),P.defaultPrevented||l==null||l())},m),O=Vw(P=>{const _=P.target;[...d.branches].some(F=>F.contains(_))||(a==null||a(P),s==null||s(P),P.defaultPrevented||l==null||l())},m);return eu(P=>{$===d.layers.size-1&&(o==null||o(P),!P.defaultPrevented&&l&&(P.preventDefault(),l()))},m),u.useEffect(()=>{if(f)return r&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(gf=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),yf(),()=>{r&&d.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=gf)}},[f,m,r,d]),u.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),yf())},[f,d]),u.useEffect(()=>{const P=()=>h({});return document.addEventListener(Xa,P),()=>document.removeEventListener(Xa,P)},[]),u.createElement(we.div,ee({},c,{ref:v,style:{pointerEvents:S?w?"auto":"none":void 0,...e.style},onFocusCapture:fe(e.onFocusCapture,O.onFocusCapture),onBlurCapture:fe(e.onBlurCapture,O.onBlurCapture),onPointerDownCapture:fe(e.onPointerDownCapture,T.onPointerDownCapture)}))});function Gw(e,t=globalThis==null?void 0:globalThis.document){const n=He(e),r=u.useRef(!1),o=u.useRef(()=>{});return u.useEffect(()=>{const i=s=>{if(s.target&&!r.current){let c=function(){bf(Ww,n,l,{discrete:!0})};const l={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",o.current),o.current=c,t.addEventListener("click",o.current,{once:!0})):c()}r.current=!1},a=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",i),t.removeEventListener("click",o.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function Vw(e,t=globalThis==null?void 0:globalThis.document){const n=He(e),r=u.useRef(!1);return u.useEffect(()=>{const o=i=>{i.target&&!r.current&&bf(Bw,n,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",o),()=>t.removeEventListener("focusin",o)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function yf(){const e=new CustomEvent(Xa);document.dispatchEvent(e)}function bf(e,t,n,{discrete:r}){const o=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?fa(o,i):o.dispatchEvent(i)}const xf="Popper",[wf,$f]=Ct(xf),[qw,Cf]=wf(xf),Yw=e=>{const{__scopePopper:t,children:n}=e,[r,o]=u.useState(null);return u.createElement(qw,{scope:t,anchor:r,onAnchorChange:o},n)},Kw="PopperAnchor",Xw=u.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...o}=e,i=Cf(Kw,n),a=u.useRef(null),s=Oe(t,a);return u.useEffect(()=>{i.onAnchorChange((r==null?void 0:r.current)||a.current)}),r?null:u.createElement(we.div,ee({},o,{ref:s}))}),Sf="PopperContent",[Rw,Z3]=wf(Sf),Zw=u.forwardRef((e,t)=>{var n,r,o,i,a,s,l,c;const{__scopePopper:d,side:f="bottom",sideOffset:p=0,align:m="center",alignOffset:h=0,arrowPadding:v=0,collisionBoundary:x=[],collisionPadding:y=0,sticky:b="partial",hideWhenDetached:$=!1,avoidCollisions:S=!0,onPlaced:w,...T}=e,O=Cf(Sf,d),[P,_]=u.useState(null),j=Oe(t,pe=>_(pe)),[F,V]=u.useState(null),R=ua(F),X=(n=R==null?void 0:R.width)!==null&&n!==void 0?n:0,C=(r=R==null?void 0:R.height)!==null&&r!==void 0?r:0,I=f+(m!=="center"?"-"+m:""),H=typeof y=="number"?y:{top:0,right:0,bottom:0,left:0,...y},B=Array.isArray(x)?x:[x],A=B.length>0,N={padding:H,boundary:B.filter(Qw),altBoundary:A},{refs:z,floatingStyles:J,placement:Q,isPositioned:oe,middlewareData:te}=zu({strategy:"fixed",placement:I,whileElementsMounted:Du,elements:{reference:O.anchor},middleware:[xu({mainAxis:p+C,alignmentAxis:h}),S&&wu({mainAxis:!0,crossAxis:!1,limiter:b==="partial"?$u():void 0,...N}),S&&vu({...N}),Cu({...N,apply:({elements:pe,rects:Ce,availableWidth:ke,availableHeight:je})=>{const{width:_t,height:mn}=Ce.reference,Ze=pe.floating.style;Ze.setProperty("--radix-popper-available-width",`${ke}px`),Ze.setProperty("--radix-popper-available-height",`${je}px`),Ze.setProperty("--radix-popper-anchor-width",`${_t}px`),Ze.setProperty("--radix-popper-anchor-height",`${mn}px`)}}),F&&Iu({element:F,padding:v}),Jw({arrowWidth:X,arrowHeight:C}),$&&bu({strategy:"referenceHidden"})]}),[ae,Y]=Ef(Q),le=He(w);ot(()=>{oe&&(le==null||le())},[oe,le]);const U=(o=te.arrow)===null||o===void 0?void 0:o.x,q=(i=te.arrow)===null||i===void 0?void 0:i.y,re=((a=te.arrow)===null||a===void 0?void 0:a.centerOffset)!==0,[k,de]=u.useState();return ot(()=>{P&&de(window.getComputedStyle(P).zIndex)},[P]),u.createElement("div",{ref:z.setFloating,"data-radix-popper-content-wrapper":"",style:{...J,transform:oe?J.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:k,"--radix-popper-transform-origin":[(s=te.transformOrigin)===null||s===void 0?void 0:s.x,(l=te.transformOrigin)===null||l===void 0?void 0:l.y].join(" ")},dir:e.dir},u.createElement(Rw,{scope:d,placedSide:ae,onArrowChange:V,arrowX:U,arrowY:q,shouldHideArrow:re},u.createElement(we.div,ee({"data-side":ae,"data-align":Y},T,{ref:j,style:{...T.style,animation:oe?void 0:"none",opacity:(c=te.hide)!==null&&c!==void 0&&c.referenceHidden?0:void 0}}))))});function Qw(e){return e!==null}const Jw=e=>({name:"transformOrigin",options:e,fn(t){var n,r,o,i,a;const{placement:s,rects:l,middlewareData:c}=t,f=((n=c.arrow)===null||n===void 0?void 0:n.centerOffset)!==0,p=f?0:e.arrowWidth,m=f?0:e.arrowHeight,[h,v]=Ef(s),x={start:"0%",center:"50%",end:"100%"}[v],y=((r=(o=c.arrow)===null||o===void 0?void 0:o.x)!==null&&r!==void 0?r:0)+p/2,b=((i=(a=c.arrow)===null||a===void 0?void 0:a.y)!==null&&i!==void 0?i:0)+m/2;let $="",S="";return h==="bottom"?($=f?x:`${y}px`,S=`${-m}px`):h==="top"?($=f?x:`${y}px`,S=`${l.floating.height+m}px`):h==="right"?($=`${-m}px`,S=f?x:`${b}px`):h==="left"&&($=`${l.floating.width+m}px`,S=f?x:`${b}px`),{data:{x:$,y:S}}}});function Ef(e){const[t,n="center"]=e.split("-");return[t,n]}const e1=Yw,t1=Xw,n1=Zw,r1=u.forwardRef((e,t)=>{var n;const{container:r=globalThis==null||(n=globalThis.document)===null||n===void 0?void 0:n.body,...o}=e;return r?At.createPortal(u.createElement(we.div,ee({},o,{ref:t})),r):null}),[Xo,Q3]=Ct("Tooltip",[$f]),Ra=$f(),o1="TooltipProvider",i1=700,Za="tooltip.open",[a1,Qa]=Xo(o1),s1=e=>{const{__scopeTooltip:t,delayDuration:n=i1,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:i}=e,[a,s]=u.useState(!0),l=u.useRef(!1),c=u.useRef(0);return u.useEffect(()=>{const d=c.current;return()=>window.clearTimeout(d)},[]),u.createElement(a1,{scope:t,isOpenDelayed:a,delayDuration:n,onOpen:u.useCallback(()=>{window.clearTimeout(c.current),s(!1)},[]),onClose:u.useCallback(()=>{window.clearTimeout(c.current),c.current=window.setTimeout(()=>s(!0),r)},[r]),isPointerInTransitRef:l,onPointerInTransitChange:u.useCallback(d=>{l.current=d},[]),disableHoverableContent:o},i)},Ja="Tooltip",[l1,_r]=Xo(Ja),c1=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:o=!1,onOpenChange:i,disableHoverableContent:a,delayDuration:s}=e,l=Qa(Ja,e.__scopeTooltip),c=Ra(t),[d,f]=u.useState(null),p=Dt(),m=u.useRef(0),h=a??l.disableHoverableContent,v=s??l.delayDuration,x=u.useRef(!1),[y=!1,b]=St({prop:r,defaultProp:o,onChange:O=>{O?(l.onOpen(),document.dispatchEvent(new CustomEvent(Za))):l.onClose(),i==null||i(O)}}),$=u.useMemo(()=>y?x.current?"delayed-open":"instant-open":"closed",[y]),S=u.useCallback(()=>{window.clearTimeout(m.current),x.current=!1,b(!0)},[b]),w=u.useCallback(()=>{window.clearTimeout(m.current),b(!1)},[b]),T=u.useCallback(()=>{window.clearTimeout(m.current),m.current=window.setTimeout(()=>{x.current=!0,b(!0)},v)},[v,b]);return u.useEffect(()=>()=>window.clearTimeout(m.current),[]),u.createElement(e1,c,u.createElement(l1,{scope:t,contentId:p,open:y,stateAttribute:$,trigger:d,onTriggerChange:f,onTriggerEnter:u.useCallback(()=>{l.isOpenDelayed?T():S()},[l.isOpenDelayed,T,S]),onTriggerLeave:u.useCallback(()=>{h?w():window.clearTimeout(m.current)},[w,h]),onOpen:S,onClose:w,disableHoverableContent:h},n))},Tf="TooltipTrigger",u1=u.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,o=_r(Tf,n),i=Qa(Tf,n),a=Ra(n),s=u.useRef(null),l=Oe(t,s,o.onTriggerChange),c=u.useRef(!1),d=u.useRef(!1),f=u.useCallback(()=>c.current=!1,[]);return u.useEffect(()=>()=>document.removeEventListener("pointerup",f),[f]),u.createElement(t1,ee({asChild:!0},a),u.createElement(we.button,ee({"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute},r,{ref:l,onPointerMove:fe(e.onPointerMove,p=>{p.pointerType!=="touch"&&!d.current&&!i.isPointerInTransitRef.current&&(o.onTriggerEnter(),d.current=!0)}),onPointerLeave:fe(e.onPointerLeave,()=>{o.onTriggerLeave(),d.current=!1}),onPointerDown:fe(e.onPointerDown,()=>{c.current=!0,document.addEventListener("pointerup",f,{once:!0})}),onFocus:fe(e.onFocus,()=>{c.current||o.onOpen()}),onBlur:fe(e.onBlur,o.onClose),onClick:fe(e.onClick,o.onClose)})))}),Pf="TooltipPortal",[d1,f1]=Xo(Pf,{forceMount:void 0}),p1=e=>{const{__scopeTooltip:t,forceMount:n,children:r,container:o}=e,i=_r(Pf,t);return u.createElement(d1,{scope:t,forceMount:n},u.createElement(Zt,{present:n||i.open},u.createElement(r1,{asChild:!0,container:o},r)))},Nr="TooltipContent",h1=u.forwardRef((e,t)=>{const n=f1(Nr,e.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...i}=e,a=_r(Nr,e.__scopeTooltip);return u.createElement(Zt,{present:r||a.open},a.disableHoverableContent?u.createElement(Mf,ee({side:o},i,{ref:t})):u.createElement(m1,ee({side:o},i,{ref:t})))}),m1=u.forwardRef((e,t)=>{const n=_r(Nr,e.__scopeTooltip),r=Qa(Nr,e.__scopeTooltip),o=u.useRef(null),i=Oe(t,o),[a,s]=u.useState(null),{trigger:l,onClose:c}=n,d=o.current,{onPointerInTransitChange:f}=r,p=u.useCallback(()=>{s(null),f(!1)},[f]),m=u.useCallback((h,v)=>{const x=h.currentTarget,y={x:h.clientX,y:h.clientY},b=g1(y,x.getBoundingClientRect()),$=y1(y,b),S=b1(v.getBoundingClientRect()),w=w1([...$,...S]);s(w),f(!0)},[f]);return u.useEffect(()=>()=>p(),[p]),u.useEffect(()=>{if(l&&d){const h=x=>m(x,d),v=x=>m(x,l);return l.addEventListener("pointerleave",h),d.addEventListener("pointerleave",v),()=>{l.removeEventListener("pointerleave",h),d.removeEventListener("pointerleave",v)}}},[l,d,m,p]),u.useEffect(()=>{if(a){const h=v=>{const x=v.target,y={x:v.clientX,y:v.clientY},b=(l==null?void 0:l.contains(x))||(d==null?void 0:d.contains(x)),$=!x1(y,a);b?p():$&&(p(),c())};return document.addEventListener("pointermove",h),()=>document.removeEventListener("pointermove",h)}},[l,d,a,c,p]),u.createElement(Mf,ee({},e,{ref:i}))}),[v1,J3]=Xo(Ja,{isInside:!1}),Mf=u.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:i,onPointerDownOutside:a,...s}=e,l=_r(Nr,n),c=Ra(n),{onClose:d}=l;return u.useEffect(()=>(document.addEventListener(Za,d),()=>document.removeEventListener(Za,d)),[d]),u.useEffect(()=>{if(l.trigger){const f=p=>{const m=p.target;m!=null&&m.contains(l.trigger)&&d()};return window.addEventListener("scroll",f,{capture:!0}),()=>window.removeEventListener("scroll",f,{capture:!0})}},[l.trigger,d]),u.createElement(Hw,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:i,onPointerDownOutside:a,onFocusOutside:f=>f.preventDefault(),onDismiss:d},u.createElement(n1,ee({"data-state":l.stateAttribute},c,s,{ref:t,style:{...s.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"}}),u.createElement(Ac,null,r),u.createElement(v1,{scope:n,isInside:!0},u.createElement(Rx,{id:l.contentId,role:"tooltip"},o||r))))});function g1(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),o=Math.abs(t.right-e.x),i=Math.abs(t.left-e.x);switch(Math.min(n,r,o,i)){case i:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function y1(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function b1(e){const{top:t,right:n,bottom:r,left:o}=e;return[{x:o,y:t},{x:n,y:t},{x:n,y:r},{x:o,y:r}]}function x1(e,t){const{x:n,y:r}=e;let o=!1;for(let i=0,a=t.length-1;i<t.length;a=i++){const s=t[i].x,l=t[i].y,c=t[a].x,d=t[a].y;l>r!=d>r&&n<(c-s)*(r-l)/(d-l)+s&&(o=!o)}return o}function w1(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),$1(t)}function $1(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const o=e[r];for(;t.length>=2;){const i=t[t.length-1],a=t[t.length-2];if((i.x-a.x)*(o.y-a.y)>=(i.y-a.y)*(o.x-a.x))t.pop();else break}t.push(o)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const o=e[r];for(;n.length>=2;){const i=n[n.length-1],a=n[n.length-2];if((i.x-a.x)*(o.y-a.y)>=(i.y-a.y)*(o.x-a.x))n.pop();else break}n.push(o)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}const C1=s1,S1=c1,E1=u1,T1=p1,kf=h1,Of=C1,_f=S1,Nf=E1,Af=T1,es=u.forwardRef(({className:e,sideOffset:t=4,...n},r)=>L.jsx(kf,{ref:r,sideOffset:t,className:_e("z-[1500] overflow-hidden p-2 bg-gray-600 max-w-xs rounded transition-opacity justify-start items-start inline-flex text-center text-white text-xs animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e,"rabbit-ds"),...n}));es.displayName=kf.displayName;var Ar=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Qn(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Jn(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var ts={exports:{}},Ro={exports:{}},Pe={};/** @license React v16.13.1
42
42
  * react-is.production.min.js
43
43
  *
44
44
  * Copyright (c) Facebook, Inc. and its affiliates.
45
45
  *
46
46
  * This source code is licensed under the MIT license found in the
47
47
  * LICENSE file in the root directory of this source tree.
48
- */var Af;function S1(){if(Af)return Pe;Af=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,m=e?Symbol.for("react.memo"):60115,h=e?Symbol.for("react.lazy"):60116,v=e?Symbol.for("react.block"):60121,x=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,b=e?Symbol.for("react.scope"):60119;function $(w){if(typeof w=="object"&&w!==null){var T=w.$$typeof;switch(T){case t:switch(w=w.type,w){case l:case c:case r:case i:case o:case f:return w;default:switch(w=w&&w.$$typeof,w){case s:case d:case h:case m:case a:return w;default:return T}}case n:return T}}}function S(w){return $(w)===c}return Pe.AsyncMode=l,Pe.ConcurrentMode=c,Pe.ContextConsumer=s,Pe.ContextProvider=a,Pe.Element=t,Pe.ForwardRef=d,Pe.Fragment=r,Pe.Lazy=h,Pe.Memo=m,Pe.Portal=n,Pe.Profiler=i,Pe.StrictMode=o,Pe.Suspense=f,Pe.isAsyncMode=function(w){return S(w)||$(w)===l},Pe.isConcurrentMode=S,Pe.isContextConsumer=function(w){return $(w)===s},Pe.isContextProvider=function(w){return $(w)===a},Pe.isElement=function(w){return typeof w=="object"&&w!==null&&w.$$typeof===t},Pe.isForwardRef=function(w){return $(w)===d},Pe.isFragment=function(w){return $(w)===r},Pe.isLazy=function(w){return $(w)===h},Pe.isMemo=function(w){return $(w)===m},Pe.isPortal=function(w){return $(w)===n},Pe.isProfiler=function(w){return $(w)===i},Pe.isStrictMode=function(w){return $(w)===o},Pe.isSuspense=function(w){return $(w)===f},Pe.isValidElementType=function(w){return typeof w=="string"||typeof w=="function"||w===r||w===c||w===i||w===o||w===f||w===p||typeof w=="object"&&w!==null&&(w.$$typeof===h||w.$$typeof===m||w.$$typeof===a||w.$$typeof===s||w.$$typeof===d||w.$$typeof===x||w.$$typeof===y||w.$$typeof===b||w.$$typeof===v)},Pe.typeOf=$,Pe}var Me={};/** @license React v16.13.1
48
+ */var Df;function P1(){if(Df)return Pe;Df=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,m=e?Symbol.for("react.memo"):60115,h=e?Symbol.for("react.lazy"):60116,v=e?Symbol.for("react.block"):60121,x=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,b=e?Symbol.for("react.scope"):60119;function $(w){if(typeof w=="object"&&w!==null){var T=w.$$typeof;switch(T){case t:switch(w=w.type,w){case l:case c:case r:case i:case o:case f:return w;default:switch(w=w&&w.$$typeof,w){case s:case d:case h:case m:case a:return w;default:return T}}case n:return T}}}function S(w){return $(w)===c}return Pe.AsyncMode=l,Pe.ConcurrentMode=c,Pe.ContextConsumer=s,Pe.ContextProvider=a,Pe.Element=t,Pe.ForwardRef=d,Pe.Fragment=r,Pe.Lazy=h,Pe.Memo=m,Pe.Portal=n,Pe.Profiler=i,Pe.StrictMode=o,Pe.Suspense=f,Pe.isAsyncMode=function(w){return S(w)||$(w)===l},Pe.isConcurrentMode=S,Pe.isContextConsumer=function(w){return $(w)===s},Pe.isContextProvider=function(w){return $(w)===a},Pe.isElement=function(w){return typeof w=="object"&&w!==null&&w.$$typeof===t},Pe.isForwardRef=function(w){return $(w)===d},Pe.isFragment=function(w){return $(w)===r},Pe.isLazy=function(w){return $(w)===h},Pe.isMemo=function(w){return $(w)===m},Pe.isPortal=function(w){return $(w)===n},Pe.isProfiler=function(w){return $(w)===i},Pe.isStrictMode=function(w){return $(w)===o},Pe.isSuspense=function(w){return $(w)===f},Pe.isValidElementType=function(w){return typeof w=="string"||typeof w=="function"||w===r||w===c||w===i||w===o||w===f||w===p||typeof w=="object"&&w!==null&&(w.$$typeof===h||w.$$typeof===m||w.$$typeof===a||w.$$typeof===s||w.$$typeof===d||w.$$typeof===x||w.$$typeof===y||w.$$typeof===b||w.$$typeof===v)},Pe.typeOf=$,Pe}var Me={};/** @license React v16.13.1
49
49
  * react-is.development.js
50
50
  *
51
51
  * Copyright (c) Facebook, Inc. and its affiliates.
52
52
  *
53
53
  * This source code is licensed under the MIT license found in the
54
54
  * LICENSE file in the root directory of this source tree.
55
- */var Df;function E1(){return Df||(Df=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,m=e?Symbol.for("react.memo"):60115,h=e?Symbol.for("react.lazy"):60116,v=e?Symbol.for("react.block"):60121,x=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,b=e?Symbol.for("react.scope"):60119;function $(k){return typeof k=="string"||typeof k=="function"||k===r||k===c||k===i||k===o||k===f||k===p||typeof k=="object"&&k!==null&&(k.$$typeof===h||k.$$typeof===m||k.$$typeof===a||k.$$typeof===s||k.$$typeof===d||k.$$typeof===x||k.$$typeof===y||k.$$typeof===b||k.$$typeof===v)}function S(k){if(typeof k=="object"&&k!==null){var de=k.$$typeof;switch(de){case t:var pe=k.type;switch(pe){case l:case c:case r:case i:case o:case f:return pe;default:var Ce=pe&&pe.$$typeof;switch(Ce){case s:case d:case h:case m:case a:return Ce;default:return de}}case n:return de}}}var w=l,T=c,O=s,P=a,_=t,j=d,F=r,V=h,R=m,X=n,C=i,I=o,H=f,B=!1;function A(k){return B||(B=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),N(k)||S(k)===l}function N(k){return S(k)===c}function z(k){return S(k)===s}function J(k){return S(k)===a}function Q(k){return typeof k=="object"&&k!==null&&k.$$typeof===t}function oe(k){return S(k)===d}function te(k){return S(k)===r}function ae(k){return S(k)===h}function Y(k){return S(k)===m}function le(k){return S(k)===n}function U(k){return S(k)===i}function q(k){return S(k)===o}function re(k){return S(k)===f}Me.AsyncMode=w,Me.ConcurrentMode=T,Me.ContextConsumer=O,Me.ContextProvider=P,Me.Element=_,Me.ForwardRef=j,Me.Fragment=F,Me.Lazy=V,Me.Memo=R,Me.Portal=X,Me.Profiler=C,Me.StrictMode=I,Me.Suspense=H,Me.isAsyncMode=A,Me.isConcurrentMode=N,Me.isContextConsumer=z,Me.isContextProvider=J,Me.isElement=Q,Me.isForwardRef=oe,Me.isFragment=te,Me.isLazy=ae,Me.isMemo=Y,Me.isPortal=le,Me.isProfiler=U,Me.isStrictMode=q,Me.isSuspense=re,Me.isValidElementType=$,Me.typeOf=S}()),Me}var If;function Lf(){return If||(If=1,process.env.NODE_ENV==="production"?Ro.exports=S1():Ro.exports=E1()),Ro.exports}/*
55
+ */var If;function M1(){return If||(If=1,process.env.NODE_ENV!=="production"&&function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,i=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,d=e?Symbol.for("react.forward_ref"):60112,f=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,m=e?Symbol.for("react.memo"):60115,h=e?Symbol.for("react.lazy"):60116,v=e?Symbol.for("react.block"):60121,x=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,b=e?Symbol.for("react.scope"):60119;function $(k){return typeof k=="string"||typeof k=="function"||k===r||k===c||k===i||k===o||k===f||k===p||typeof k=="object"&&k!==null&&(k.$$typeof===h||k.$$typeof===m||k.$$typeof===a||k.$$typeof===s||k.$$typeof===d||k.$$typeof===x||k.$$typeof===y||k.$$typeof===b||k.$$typeof===v)}function S(k){if(typeof k=="object"&&k!==null){var de=k.$$typeof;switch(de){case t:var pe=k.type;switch(pe){case l:case c:case r:case i:case o:case f:return pe;default:var Ce=pe&&pe.$$typeof;switch(Ce){case s:case d:case h:case m:case a:return Ce;default:return de}}case n:return de}}}var w=l,T=c,O=s,P=a,_=t,j=d,F=r,V=h,R=m,X=n,C=i,I=o,H=f,B=!1;function A(k){return B||(B=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),N(k)||S(k)===l}function N(k){return S(k)===c}function z(k){return S(k)===s}function J(k){return S(k)===a}function Q(k){return typeof k=="object"&&k!==null&&k.$$typeof===t}function oe(k){return S(k)===d}function te(k){return S(k)===r}function ae(k){return S(k)===h}function Y(k){return S(k)===m}function le(k){return S(k)===n}function U(k){return S(k)===i}function q(k){return S(k)===o}function re(k){return S(k)===f}Me.AsyncMode=w,Me.ConcurrentMode=T,Me.ContextConsumer=O,Me.ContextProvider=P,Me.Element=_,Me.ForwardRef=j,Me.Fragment=F,Me.Lazy=V,Me.Memo=R,Me.Portal=X,Me.Profiler=C,Me.StrictMode=I,Me.Suspense=H,Me.isAsyncMode=A,Me.isConcurrentMode=N,Me.isContextConsumer=z,Me.isContextProvider=J,Me.isElement=Q,Me.isForwardRef=oe,Me.isFragment=te,Me.isLazy=ae,Me.isMemo=Y,Me.isPortal=le,Me.isProfiler=U,Me.isStrictMode=q,Me.isSuspense=re,Me.isValidElementType=$,Me.typeOf=S}()),Me}var Lf;function Ff(){return Lf||(Lf=1,process.env.NODE_ENV==="production"?Ro.exports=P1():Ro.exports=M1()),Ro.exports}/*
56
56
  object-assign
57
57
  (c) Sindre Sorhus
58
58
  @license MIT
59
- */var ts,Ff;function T1(){if(Ff)return ts;Ff=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(i){if(i==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(i)}function o(){try{if(!Object.assign)return!1;var i=new String("abc");if(i[5]="de",Object.getOwnPropertyNames(i)[0]==="5")return!1;for(var a={},s=0;s<10;s++)a["_"+String.fromCharCode(s)]=s;var l=Object.getOwnPropertyNames(a).map(function(d){return a[d]});if(l.join("")!=="0123456789")return!1;var c={};return"abcdefghijklmnopqrst".split("").forEach(function(d){c[d]=d}),Object.keys(Object.assign({},c)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return ts=o()?Object.assign:function(i,a){for(var s,l=r(i),c,d=1;d<arguments.length;d++){s=Object(arguments[d]);for(var f in s)t.call(s,f)&&(l[f]=s[f]);if(e){c=e(s);for(var p=0;p<c.length;p++)n.call(s,c[p])&&(l[c[p]]=s[c[p]])}}return l},ts}var ns,jf;function rs(){if(jf)return ns;jf=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return ns=e,ns}var os,zf;function Wf(){return zf||(zf=1,os=Function.call.bind(Object.prototype.hasOwnProperty)),os}var is,Bf;function P1(){if(Bf)return is;Bf=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=rs(),n={},r=Wf();e=function(i){var a="Warning: "+i;typeof console<"u"&&console.error(a);try{throw new Error(a)}catch{}}}function o(i,a,s,l,c){if(process.env.NODE_ENV!=="production"){for(var d in i)if(r(i,d)){var f;try{if(typeof i[d]!="function"){var p=Error((l||"React class")+": "+s+" type `"+d+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof i[d]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw p.name="Invariant Violation",p}f=i[d](a,d,l,s,null,t)}catch(h){f=h}if(f&&!(f instanceof Error)&&e((l||"React class")+": type specification of "+s+" `"+d+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof f+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),f instanceof Error&&!(f.message in n)){n[f.message]=!0;var m=c?c():"";e("Failed "+s+" type: "+f.message+(m??""))}}}}return o.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(n={})},is=o,is}var as,Uf;function M1(){if(Uf)return as;Uf=1;var e=Lf(),t=T1(),n=rs(),r=Wf(),o=P1(),i=function(){};process.env.NODE_ENV!=="production"&&(i=function(s){var l="Warning: "+s;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function a(){return null}return as=function(s,l){var c=typeof Symbol=="function"&&Symbol.iterator,d="@@iterator";function f(N){var z=N&&(c&&N[c]||N[d]);if(typeof z=="function")return z}var p="<<anonymous>>",m={array:y("array"),bigint:y("bigint"),bool:y("boolean"),func:y("function"),number:y("number"),object:y("object"),string:y("string"),symbol:y("symbol"),any:b(),arrayOf:$,element:S(),elementType:w(),instanceOf:T,node:j(),objectOf:P,oneOf:O,oneOfType:_,shape:V,exact:R};function h(N,z){return N===z?N!==0||1/N===1/z:N!==N&&z!==z}function v(N,z){this.message=N,this.data=z&&typeof z=="object"?z:{},this.stack=""}v.prototype=Error.prototype;function x(N){if(process.env.NODE_ENV!=="production")var z={},J=0;function Q(te,ae,Y,le,U,q,re){if(le=le||p,q=q||Y,re!==n){if(l){var k=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw k.name="Invariant Violation",k}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var de=le+":"+Y;!z[de]&&J<3&&(i("You are manually calling a React.PropTypes validation function for the `"+q+"` prop on `"+le+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),z[de]=!0,J++)}}return ae[Y]==null?te?ae[Y]===null?new v("The "+U+" `"+q+"` is marked as required "+("in `"+le+"`, but its value is `null`.")):new v("The "+U+" `"+q+"` is marked as required in "+("`"+le+"`, but its value is `undefined`.")):null:N(ae,Y,le,U,q)}var oe=Q.bind(null,!1);return oe.isRequired=Q.bind(null,!0),oe}function y(N){function z(J,Q,oe,te,ae,Y){var le=J[Q],U=I(le);if(U!==N){var q=H(le);return new v("Invalid "+te+" `"+ae+"` of type "+("`"+q+"` supplied to `"+oe+"`, expected ")+("`"+N+"`."),{expectedType:N})}return null}return x(z)}function b(){return x(a)}function $(N){function z(J,Q,oe,te,ae){if(typeof N!="function")return new v("Property `"+ae+"` of component `"+oe+"` has invalid PropType notation inside arrayOf.");var Y=J[Q];if(!Array.isArray(Y)){var le=I(Y);return new v("Invalid "+te+" `"+ae+"` of type "+("`"+le+"` supplied to `"+oe+"`, expected an array."))}for(var U=0;U<Y.length;U++){var q=N(Y,U,oe,te,ae+"["+U+"]",n);if(q instanceof Error)return q}return null}return x(z)}function S(){function N(z,J,Q,oe,te){var ae=z[J];if(!s(ae)){var Y=I(ae);return new v("Invalid "+oe+" `"+te+"` of type "+("`"+Y+"` supplied to `"+Q+"`, expected a single ReactElement."))}return null}return x(N)}function w(){function N(z,J,Q,oe,te){var ae=z[J];if(!e.isValidElementType(ae)){var Y=I(ae);return new v("Invalid "+oe+" `"+te+"` of type "+("`"+Y+"` supplied to `"+Q+"`, expected a single ReactElement type."))}return null}return x(N)}function T(N){function z(J,Q,oe,te,ae){if(!(J[Q]instanceof N)){var Y=N.name||p,le=A(J[Q]);return new v("Invalid "+te+" `"+ae+"` of type "+("`"+le+"` supplied to `"+oe+"`, expected ")+("instance of `"+Y+"`."))}return null}return x(z)}function O(N){if(!Array.isArray(N))return process.env.NODE_ENV!=="production"&&(arguments.length>1?i("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):i("Invalid argument supplied to oneOf, expected an array.")),a;function z(J,Q,oe,te,ae){for(var Y=J[Q],le=0;le<N.length;le++)if(h(Y,N[le]))return null;var U=JSON.stringify(N,function(re,k){var de=H(k);return de==="symbol"?String(k):k});return new v("Invalid "+te+" `"+ae+"` of value `"+String(Y)+"` "+("supplied to `"+oe+"`, expected one of "+U+"."))}return x(z)}function P(N){function z(J,Q,oe,te,ae){if(typeof N!="function")return new v("Property `"+ae+"` of component `"+oe+"` has invalid PropType notation inside objectOf.");var Y=J[Q],le=I(Y);if(le!=="object")return new v("Invalid "+te+" `"+ae+"` of type "+("`"+le+"` supplied to `"+oe+"`, expected an object."));for(var U in Y)if(r(Y,U)){var q=N(Y,U,oe,te,ae+"."+U,n);if(q instanceof Error)return q}return null}return x(z)}function _(N){if(!Array.isArray(N))return process.env.NODE_ENV!=="production"&&i("Invalid argument supplied to oneOfType, expected an instance of array."),a;for(var z=0;z<N.length;z++){var J=N[z];if(typeof J!="function")return i("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+B(J)+" at index "+z+"."),a}function Q(oe,te,ae,Y,le){for(var U=[],q=0;q<N.length;q++){var re=N[q],k=re(oe,te,ae,Y,le,n);if(k==null)return null;k.data&&r(k.data,"expectedType")&&U.push(k.data.expectedType)}var de=U.length>0?", expected one of type ["+U.join(", ")+"]":"";return new v("Invalid "+Y+" `"+le+"` supplied to "+("`"+ae+"`"+de+"."))}return x(Q)}function j(){function N(z,J,Q,oe,te){return X(z[J])?null:new v("Invalid "+oe+" `"+te+"` supplied to "+("`"+Q+"`, expected a ReactNode."))}return x(N)}function F(N,z,J,Q,oe){return new v((N||"React class")+": "+z+" type `"+J+"."+Q+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+oe+"`.")}function V(N){function z(J,Q,oe,te,ae){var Y=J[Q],le=I(Y);if(le!=="object")return new v("Invalid "+te+" `"+ae+"` of type `"+le+"` "+("supplied to `"+oe+"`, expected `object`."));for(var U in N){var q=N[U];if(typeof q!="function")return F(oe,te,ae,U,H(q));var re=q(Y,U,oe,te,ae+"."+U,n);if(re)return re}return null}return x(z)}function R(N){function z(J,Q,oe,te,ae){var Y=J[Q],le=I(Y);if(le!=="object")return new v("Invalid "+te+" `"+ae+"` of type `"+le+"` "+("supplied to `"+oe+"`, expected `object`."));var U=t({},J[Q],N);for(var q in U){var re=N[q];if(r(N,q)&&typeof re!="function")return F(oe,te,ae,q,H(re));if(!re)return new v("Invalid "+te+" `"+ae+"` key `"+q+"` supplied to `"+oe+"`.\nBad object: "+JSON.stringify(J[Q],null," ")+`
60
- Valid keys: `+JSON.stringify(Object.keys(N),null," "));var k=re(Y,q,oe,te,ae+"."+q,n);if(k)return k}return null}return x(z)}function X(N){switch(typeof N){case"number":case"string":case"undefined":return!0;case"boolean":return!N;case"object":if(Array.isArray(N))return N.every(X);if(N===null||s(N))return!0;var z=f(N);if(z){var J=z.call(N),Q;if(z!==N.entries){for(;!(Q=J.next()).done;)if(!X(Q.value))return!1}else for(;!(Q=J.next()).done;){var oe=Q.value;if(oe&&!X(oe[1]))return!1}}else return!1;return!0;default:return!1}}function C(N,z){return N==="symbol"?!0:z?z["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&z instanceof Symbol:!1}function I(N){var z=typeof N;return Array.isArray(N)?"array":N instanceof RegExp?"object":C(z,N)?"symbol":z}function H(N){if(typeof N>"u"||N===null)return""+N;var z=I(N);if(z==="object"){if(N instanceof Date)return"date";if(N instanceof RegExp)return"regexp"}return z}function B(N){var z=H(N);switch(z){case"array":case"object":return"an "+z;case"boolean":case"date":case"regexp":return"a "+z;default:return z}}function A(N){return!N.constructor||!N.constructor.name?p:N.constructor.name}return m.checkPropTypes=o,m.resetWarningCache=o.resetWarningCache,m.PropTypes=m,m},as}var ss,Hf;function k1(){if(Hf)return ss;Hf=1;var e=rs();function t(){}function n(){}return n.resetWarningCache=t,ss=function(){function r(a,s,l,c,d,f){if(f!==e){var p=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw p.name="Invariant Violation",p}}r.isRequired=r;function o(){return r}var i={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return i.PropTypes=i,i},ss}if(process.env.NODE_ENV!=="production"){var O1=Lf(),_1=!0;es.exports=M1()(O1.isElement,_1)}else es.exports=k1()();var Zo=es.exports;const ne=Qn(Zo);var Gf={exports:{}};/*!
59
+ */var ns,jf;function k1(){if(jf)return ns;jf=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(i){if(i==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(i)}function o(){try{if(!Object.assign)return!1;var i=new String("abc");if(i[5]="de",Object.getOwnPropertyNames(i)[0]==="5")return!1;for(var a={},s=0;s<10;s++)a["_"+String.fromCharCode(s)]=s;var l=Object.getOwnPropertyNames(a).map(function(d){return a[d]});if(l.join("")!=="0123456789")return!1;var c={};return"abcdefghijklmnopqrst".split("").forEach(function(d){c[d]=d}),Object.keys(Object.assign({},c)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return ns=o()?Object.assign:function(i,a){for(var s,l=r(i),c,d=1;d<arguments.length;d++){s=Object(arguments[d]);for(var f in s)t.call(s,f)&&(l[f]=s[f]);if(e){c=e(s);for(var p=0;p<c.length;p++)n.call(s,c[p])&&(l[c[p]]=s[c[p]])}}return l},ns}var rs,zf;function os(){if(zf)return rs;zf=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return rs=e,rs}var is,Wf;function Bf(){return Wf||(Wf=1,is=Function.call.bind(Object.prototype.hasOwnProperty)),is}var as,Uf;function O1(){if(Uf)return as;Uf=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=os(),n={},r=Bf();e=function(i){var a="Warning: "+i;typeof console<"u"&&console.error(a);try{throw new Error(a)}catch{}}}function o(i,a,s,l,c){if(process.env.NODE_ENV!=="production"){for(var d in i)if(r(i,d)){var f;try{if(typeof i[d]!="function"){var p=Error((l||"React class")+": "+s+" type `"+d+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof i[d]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw p.name="Invariant Violation",p}f=i[d](a,d,l,s,null,t)}catch(h){f=h}if(f&&!(f instanceof Error)&&e((l||"React class")+": type specification of "+s+" `"+d+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof f+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),f instanceof Error&&!(f.message in n)){n[f.message]=!0;var m=c?c():"";e("Failed "+s+" type: "+f.message+(m??""))}}}}return o.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(n={})},as=o,as}var ss,Hf;function _1(){if(Hf)return ss;Hf=1;var e=Ff(),t=k1(),n=os(),r=Bf(),o=O1(),i=function(){};process.env.NODE_ENV!=="production"&&(i=function(s){var l="Warning: "+s;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function a(){return null}return ss=function(s,l){var c=typeof Symbol=="function"&&Symbol.iterator,d="@@iterator";function f(N){var z=N&&(c&&N[c]||N[d]);if(typeof z=="function")return z}var p="<<anonymous>>",m={array:y("array"),bigint:y("bigint"),bool:y("boolean"),func:y("function"),number:y("number"),object:y("object"),string:y("string"),symbol:y("symbol"),any:b(),arrayOf:$,element:S(),elementType:w(),instanceOf:T,node:j(),objectOf:P,oneOf:O,oneOfType:_,shape:V,exact:R};function h(N,z){return N===z?N!==0||1/N===1/z:N!==N&&z!==z}function v(N,z){this.message=N,this.data=z&&typeof z=="object"?z:{},this.stack=""}v.prototype=Error.prototype;function x(N){if(process.env.NODE_ENV!=="production")var z={},J=0;function Q(te,ae,Y,le,U,q,re){if(le=le||p,q=q||Y,re!==n){if(l){var k=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw k.name="Invariant Violation",k}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var de=le+":"+Y;!z[de]&&J<3&&(i("You are manually calling a React.PropTypes validation function for the `"+q+"` prop on `"+le+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),z[de]=!0,J++)}}return ae[Y]==null?te?ae[Y]===null?new v("The "+U+" `"+q+"` is marked as required "+("in `"+le+"`, but its value is `null`.")):new v("The "+U+" `"+q+"` is marked as required in "+("`"+le+"`, but its value is `undefined`.")):null:N(ae,Y,le,U,q)}var oe=Q.bind(null,!1);return oe.isRequired=Q.bind(null,!0),oe}function y(N){function z(J,Q,oe,te,ae,Y){var le=J[Q],U=I(le);if(U!==N){var q=H(le);return new v("Invalid "+te+" `"+ae+"` of type "+("`"+q+"` supplied to `"+oe+"`, expected ")+("`"+N+"`."),{expectedType:N})}return null}return x(z)}function b(){return x(a)}function $(N){function z(J,Q,oe,te,ae){if(typeof N!="function")return new v("Property `"+ae+"` of component `"+oe+"` has invalid PropType notation inside arrayOf.");var Y=J[Q];if(!Array.isArray(Y)){var le=I(Y);return new v("Invalid "+te+" `"+ae+"` of type "+("`"+le+"` supplied to `"+oe+"`, expected an array."))}for(var U=0;U<Y.length;U++){var q=N(Y,U,oe,te,ae+"["+U+"]",n);if(q instanceof Error)return q}return null}return x(z)}function S(){function N(z,J,Q,oe,te){var ae=z[J];if(!s(ae)){var Y=I(ae);return new v("Invalid "+oe+" `"+te+"` of type "+("`"+Y+"` supplied to `"+Q+"`, expected a single ReactElement."))}return null}return x(N)}function w(){function N(z,J,Q,oe,te){var ae=z[J];if(!e.isValidElementType(ae)){var Y=I(ae);return new v("Invalid "+oe+" `"+te+"` of type "+("`"+Y+"` supplied to `"+Q+"`, expected a single ReactElement type."))}return null}return x(N)}function T(N){function z(J,Q,oe,te,ae){if(!(J[Q]instanceof N)){var Y=N.name||p,le=A(J[Q]);return new v("Invalid "+te+" `"+ae+"` of type "+("`"+le+"` supplied to `"+oe+"`, expected ")+("instance of `"+Y+"`."))}return null}return x(z)}function O(N){if(!Array.isArray(N))return process.env.NODE_ENV!=="production"&&(arguments.length>1?i("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):i("Invalid argument supplied to oneOf, expected an array.")),a;function z(J,Q,oe,te,ae){for(var Y=J[Q],le=0;le<N.length;le++)if(h(Y,N[le]))return null;var U=JSON.stringify(N,function(re,k){var de=H(k);return de==="symbol"?String(k):k});return new v("Invalid "+te+" `"+ae+"` of value `"+String(Y)+"` "+("supplied to `"+oe+"`, expected one of "+U+"."))}return x(z)}function P(N){function z(J,Q,oe,te,ae){if(typeof N!="function")return new v("Property `"+ae+"` of component `"+oe+"` has invalid PropType notation inside objectOf.");var Y=J[Q],le=I(Y);if(le!=="object")return new v("Invalid "+te+" `"+ae+"` of type "+("`"+le+"` supplied to `"+oe+"`, expected an object."));for(var U in Y)if(r(Y,U)){var q=N(Y,U,oe,te,ae+"."+U,n);if(q instanceof Error)return q}return null}return x(z)}function _(N){if(!Array.isArray(N))return process.env.NODE_ENV!=="production"&&i("Invalid argument supplied to oneOfType, expected an instance of array."),a;for(var z=0;z<N.length;z++){var J=N[z];if(typeof J!="function")return i("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+B(J)+" at index "+z+"."),a}function Q(oe,te,ae,Y,le){for(var U=[],q=0;q<N.length;q++){var re=N[q],k=re(oe,te,ae,Y,le,n);if(k==null)return null;k.data&&r(k.data,"expectedType")&&U.push(k.data.expectedType)}var de=U.length>0?", expected one of type ["+U.join(", ")+"]":"";return new v("Invalid "+Y+" `"+le+"` supplied to "+("`"+ae+"`"+de+"."))}return x(Q)}function j(){function N(z,J,Q,oe,te){return X(z[J])?null:new v("Invalid "+oe+" `"+te+"` supplied to "+("`"+Q+"`, expected a ReactNode."))}return x(N)}function F(N,z,J,Q,oe){return new v((N||"React class")+": "+z+" type `"+J+"."+Q+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+oe+"`.")}function V(N){function z(J,Q,oe,te,ae){var Y=J[Q],le=I(Y);if(le!=="object")return new v("Invalid "+te+" `"+ae+"` of type `"+le+"` "+("supplied to `"+oe+"`, expected `object`."));for(var U in N){var q=N[U];if(typeof q!="function")return F(oe,te,ae,U,H(q));var re=q(Y,U,oe,te,ae+"."+U,n);if(re)return re}return null}return x(z)}function R(N){function z(J,Q,oe,te,ae){var Y=J[Q],le=I(Y);if(le!=="object")return new v("Invalid "+te+" `"+ae+"` of type `"+le+"` "+("supplied to `"+oe+"`, expected `object`."));var U=t({},J[Q],N);for(var q in U){var re=N[q];if(r(N,q)&&typeof re!="function")return F(oe,te,ae,q,H(re));if(!re)return new v("Invalid "+te+" `"+ae+"` key `"+q+"` supplied to `"+oe+"`.\nBad object: "+JSON.stringify(J[Q],null," ")+`
60
+ Valid keys: `+JSON.stringify(Object.keys(N),null," "));var k=re(Y,q,oe,te,ae+"."+q,n);if(k)return k}return null}return x(z)}function X(N){switch(typeof N){case"number":case"string":case"undefined":return!0;case"boolean":return!N;case"object":if(Array.isArray(N))return N.every(X);if(N===null||s(N))return!0;var z=f(N);if(z){var J=z.call(N),Q;if(z!==N.entries){for(;!(Q=J.next()).done;)if(!X(Q.value))return!1}else for(;!(Q=J.next()).done;){var oe=Q.value;if(oe&&!X(oe[1]))return!1}}else return!1;return!0;default:return!1}}function C(N,z){return N==="symbol"?!0:z?z["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&z instanceof Symbol:!1}function I(N){var z=typeof N;return Array.isArray(N)?"array":N instanceof RegExp?"object":C(z,N)?"symbol":z}function H(N){if(typeof N>"u"||N===null)return""+N;var z=I(N);if(z==="object"){if(N instanceof Date)return"date";if(N instanceof RegExp)return"regexp"}return z}function B(N){var z=H(N);switch(z){case"array":case"object":return"an "+z;case"boolean":case"date":case"regexp":return"a "+z;default:return z}}function A(N){return!N.constructor||!N.constructor.name?p:N.constructor.name}return m.checkPropTypes=o,m.resetWarningCache=o.resetWarningCache,m.PropTypes=m,m},ss}var ls,Gf;function N1(){if(Gf)return ls;Gf=1;var e=os();function t(){}function n(){}return n.resetWarningCache=t,ls=function(){function r(a,s,l,c,d,f){if(f!==e){var p=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw p.name="Invariant Violation",p}}r.isRequired=r;function o(){return r}var i={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return i.PropTypes=i,i},ls}if(process.env.NODE_ENV!=="production"){var A1=Ff(),D1=!0;ts.exports=_1()(A1.isElement,D1)}else ts.exports=N1()();var Zo=ts.exports;const ne=Qn(Zo);var Vf={exports:{}};/*!
61
61
  Copyright (c) 2018 Jed Watson.
62
62
  Licensed under the MIT License (MIT), see
63
63
  http://jedwatson.github.io/classnames
64
- */(function(e){(function(){var t={}.hasOwnProperty;function n(){for(var r=[],o=0;o<arguments.length;o++){var i=arguments[o];if(i){var a=typeof i;if(a==="string"||a==="number")r.push(i);else if(Array.isArray(i)){if(i.length){var s=n.apply(null,i);s&&r.push(s)}}else if(a==="object"){if(i.toString!==Object.prototype.toString&&!i.toString.toString().includes("[native code]")){r.push(i.toString());continue}for(var l in i)t.call(i,l)&&i[l]&&r.push(l)}}}return r.join(" ")}e.exports?(n.default=n,e.exports=n):window.classNames=n})()})(Gf);var Qo=Gf.exports;const et=Qn(Qo);var N1=["top","left","transform","className","children","innerRef"];function ls(){return ls=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ls.apply(this,arguments)}function A1(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function En(e){var t=e.top,n=t===void 0?0:t,r=e.left,o=r===void 0?0:r,i=e.transform,a=e.className,s=e.children,l=e.innerRef,c=A1(e,N1);return u.createElement("g",ls({ref:l,className:et("visx-group",a),transform:i||"translate("+o+", "+n+")"},c),s)}En.propTypes={top:ne.number,left:ne.number,transform:ne.string,className:ne.string,children:ne.node,innerRef:ne.oneOfType([ne.string,ne.func,ne.object])};const D1=Object.freeze(Object.defineProperty({__proto__:null,Group:En},Symbol.toStringTag,{value:"Module"}));var I1=Vf;function Vf(e,t,n){e instanceof RegExp&&(e=qf(e,n)),t instanceof RegExp&&(t=qf(t,n));var r=Yf(e,t,n);return r&&{start:r[0],end:r[1],pre:n.slice(0,r[0]),body:n.slice(r[0]+e.length,r[1]),post:n.slice(r[1]+t.length)}}function qf(e,t){var n=t.match(e);return n?n[0]:null}Vf.range=Yf;function Yf(e,t,n){var r,o,i,a,s,l=n.indexOf(e),c=n.indexOf(t,l+1),d=l;if(l>=0&&c>0){for(r=[],i=n.length;d>=0&&!s;)d==l?(r.push(d),l=n.indexOf(e,d+1)):r.length==1?s=[r.pop(),c]:(o=r.pop(),o<i&&(i=o,a=c),c=n.indexOf(t,d+1)),d=l<c&&l>=0?l:c;r.length&&(s=[i,a])}return s}var L1=Kf;function Kf(e,t,n){e instanceof RegExp&&(e=Xf(e,n)),t instanceof RegExp&&(t=Xf(t,n));var r=Rf(e,t,n);return r&&{start:r[0],end:r[1],pre:n.slice(0,r[0]),body:n.slice(r[0]+e.length,r[1]),post:n.slice(r[1]+t.length)}}function Xf(e,t){var n=t.match(e);return n?n[0]:null}Kf.range=Rf;function Rf(e,t,n){var r,o,i,a,s,l=n.indexOf(e),c=n.indexOf(t,l+1),d=l;if(l>=0&&c>0){if(e===t)return[l,c];for(r=[],i=n.length;d>=0&&!s;)d==l?(r.push(d),l=n.indexOf(e,d+1)):r.length==1?s=[r.pop(),c]:(o=r.pop(),o<i&&(i=o,a=c),c=n.indexOf(t,d+1)),d=l<c&&l>=0?l:c;r.length&&(s=[i,a])}return s}var F1=L1,j1=Zf;function Zf(e,t,n){var r=e;return z1(e,t).reduce(function(o,i){return o.replace(i.functionIdentifier+"("+i.matches.body+")",W1(i.matches.body,i.functionIdentifier,n,r,t))},e)}function z1(e,t){var n=[],r=typeof t=="string"?new RegExp("\\b("+t+")\\("):t;do{var o=r.exec(e);if(!o)return n;if(o[1]===void 0)throw new Error("Missing the first couple of parenthesis to get the function identifier in "+t);var i=o[1],a=o.index,s=F1("(",")",e.substring(a));if(!s||s.start!==o[0].length-1)throw new SyntaxError(i+"(): missing closing ')' in the value '"+e+"'");n.push({matches:s,functionIdentifier:i}),e=s.post}while(r.test(e));return n}function W1(e,t,n,r,o){return n(Zf(e,o,n),t,r)}var Ve=function(e){this.value=e};Ve.math={isDegree:!0,acos:function(e){return Ve.math.isDegree?180/Math.PI*Math.acos(e):Math.acos(e)},add:function(e,t){return e+t},asin:function(e){return Ve.math.isDegree?180/Math.PI*Math.asin(e):Math.asin(e)},atan:function(e){return Ve.math.isDegree?180/Math.PI*Math.atan(e):Math.atan(e)},acosh:function(e){return Math.log(e+Math.sqrt(e*e-1))},asinh:function(e){return Math.log(e+Math.sqrt(e*e+1))},atanh:function(e){return Math.log((1+e)/(1-e))},C:function(e,t){var n=1,r=e-t,o=t;o<r&&(o=r,r=t);for(var i=o+1;i<=e;i++)n*=i;return n/Ve.math.fact(r)},changeSign:function(e){return-e},cos:function(e){return Ve.math.isDegree&&(e=Ve.math.toRadian(e)),Math.cos(e)},cosh:function(e){return(Math.pow(Math.E,e)+Math.pow(Math.E,-1*e))/2},div:function(e,t){return e/t},fact:function(e){if(e%1!==0)return"NaN";for(var t=1,n=2;n<=e;n++)t*=n;return t},inverse:function(e){return 1/e},log:function(e){return Math.log(e)/Math.log(10)},mod:function(e,t){return e%t},mul:function(e,t){return e*t},P:function(e,t){for(var n=1,r=Math.floor(e)-Math.floor(t)+1;r<=Math.floor(e);r++)n*=r;return n},Pi:function(e,t,n){for(var r=1,o=e;o<=t;o++)r*=Number(n.postfixEval({n:o}));return r},pow10x:function(e){for(var t=1;e--;)t*=10;return t},sigma:function(e,t,n){for(var r=0,o=e;o<=t;o++)r+=Number(n.postfixEval({n:o}));return r},sin:function(e){return Ve.math.isDegree&&(e=Ve.math.toRadian(e)),Math.sin(e)},sinh:function(e){return(Math.pow(Math.E,e)-Math.pow(Math.E,-1*e))/2},sub:function(e,t){return e-t},tan:function(e){return Ve.math.isDegree&&(e=Ve.math.toRadian(e)),Math.tan(e)},tanh:function(e){return Ve.sinha(e)/Ve.cosha(e)},toRadian:function(e){return e*Math.PI/180},and:function(e,t){return e&t}},Ve.Exception=function(e){this.message=e};var B1=Ve,ge=B1;function qe(e,t){for(var n=0;n<e.length;n++)e[n]+=t;return e}for(var on=[{token:"sin",show:"sin",type:0,value:ge.math.sin},{token:"cos",show:"cos",type:0,value:ge.math.cos},{token:"tan",show:"tan",type:0,value:ge.math.tan},{token:"pi",show:"&pi;",type:3,value:"PI"},{token:"(",show:"(",type:4,value:"("},{token:")",show:")",type:5,value:")"},{token:"P",show:"P",type:10,value:ge.math.P},{token:"C",show:"C",type:10,value:ge.math.C},{token:" ",show:" ",type:14,value:" ".anchor},{token:"asin",show:"asin",type:0,value:ge.math.asin},{token:"acos",show:"acos",type:0,value:ge.math.acos},{token:"atan",show:"atan",type:0,value:ge.math.atan},{token:"7",show:"7",type:1,value:"7"},{token:"8",show:"8",type:1,value:"8"},{token:"9",show:"9",type:1,value:"9"},{token:"int",show:"Int",type:0,value:Math.floor},{token:"cosh",show:"cosh",type:0,value:ge.math.cosh},{token:"acosh",show:"acosh",type:0,value:ge.math.acosh},{token:"ln",show:" ln",type:0,value:Math.log},{token:"^",show:"^",type:10,value:Math.pow},{token:"root",show:"root",type:0,value:Math.sqrt},{token:"4",show:"4",type:1,value:"4"},{token:"5",show:"5",type:1,value:"5"},{token:"6",show:"6",type:1,value:"6"},{token:"/",show:"&divide;",type:2,value:ge.math.div},{token:"!",show:"!",type:7,value:ge.math.fact},{token:"tanh",show:"tanh",type:0,value:ge.math.tanh},{token:"atanh",show:"atanh",type:0,value:ge.math.atanh},{token:"Mod",show:" Mod ",type:2,value:ge.math.mod},{token:"1",show:"1",type:1,value:"1"},{token:"2",show:"2",type:1,value:"2"},{token:"3",show:"3",type:1,value:"3"},{token:"*",show:"&times;",type:2,value:ge.math.mul},{token:"sinh",show:"sinh",type:0,value:ge.math.sinh},{token:"asinh",show:"asinh",type:0,value:ge.math.asinh},{token:"e",show:"e",type:3,value:"E"},{token:"log",show:" log",type:0,value:ge.math.log},{token:"0",show:"0",type:1,value:"0"},{token:".",show:".",type:6,value:"."},{token:"+",show:"+",type:9,value:ge.math.add},{token:"-",show:"-",type:9,value:ge.math.sub},{token:",",show:",",type:11,value:","},{token:"Sigma",show:"&Sigma;",type:12,value:ge.math.sigma},{token:"n",show:"n",type:13,value:"n"},{token:"Pi",show:"&Pi;",type:12,value:ge.math.Pi},{token:"pow",show:"pow",type:8,value:Math.pow,numberOfArguments:2},{token:"&",show:"&",type:9,value:ge.math.and}],cs={0:11,1:0,2:3,3:0,4:0,5:0,6:0,7:11,8:11,9:1,10:10,11:0,12:11,13:0,14:-1,15:11},Jo=0;Jo<on.length;Jo++)on[Jo].precedence=cs[on[Jo].type];var Pt={0:!0,1:!0,3:!0,4:!0,6:!0,8:!0,9:!0,12:!0,13:!0,14:!0,15:!0},er={0:!0,1:!0,2:!0,3:!0,4:!0,5:!0,6:!0,7:!0,8:!0,9:!0,10:!0,11:!0,12:!0,13:!0,15:!0},U1={0:!0,3:!0,4:!0,8:!0,12:!0,13:!0,15:!0},vt={},Ar={0:!0,1:!0,3:!0,4:!0,6:!0,8:!0,12:!0,13:!0,15:!0},H1={1:!0},Ye=[[],["1","2","3","7","8","9","4","5","6","+","-","*","/","(",")","^","!","P","C","e","0",".",",","n"," ","&"],["pi","ln","Pi"],["sin","cos","tan","Del","int","Mod","log","pow"],["asin","acos","atan","cosh","root","tanh","sinh"],["acosh","atanh","asinh","Sigma"]];function G1(e,t,n,r){for(var o=0;o<r;o++)if(e[n+o]!==t[o])return!1;return!0}ge.tokenTypes={FUNCTION_WITH_ONE_ARG:0,NUMBER:1,BINARY_OPERATOR_HIGH_PRECENDENCE:2,CONSTANT:3,OPENING_PARENTHESIS:4,CLOSING_PARENTHESIS:5,DECIMAL:6,POSTFIX_FUNCTION_WITH_ONE_ARG:7,FUNCTION_WITH_N_ARGS:8,BINARY_OPERATOR_LOW_PRECENDENCE:9,BINARY_OPERATOR_PERMUTATION:10,COMMA:11,EVALUATED_FUNCTION:12,EVALUATED_FUNCTION_PARAMETER:13,SPACE:14},ge.addToken=function(e){for(var t=0;t<e.length;t++){var n=e[t].token.length,r=-1;e[t].type===ge.tokenTypes.FUNCTION_WITH_N_ARGS&&e[t].numberOfArguments===void 0&&(e[t].numberOfArguments=2),Ye[n]=Ye[n]||[];for(var o=0;o<Ye[n].length;o++)if(e[t].token===Ye[n][o]){r=Qf(Ye[n][o],on);break}r===-1?(on.push(e[t]),e[t].precedence=cs[e[t].type],Ye.length<=e[t].token.length&&(Ye[e[t].token.length]=[]),Ye[e[t].token.length].push(e[t].token)):(on[r]=e[t],e[t].precedence=cs[e[t].type])}};function Qf(e,t){for(var n=0;n<t.length;n++)if(t[n].token===e)return n;return-1}function V1(e){for(var t=[],n=e.length,r,o,i,a=0;a<n;a++)if(!(a<n-1&&e[a]===" "&&e[a+1]===" ")){for(r="",o=e.length-a>Ye.length-2?Ye.length-1:e.length-a;o>0;o--)if(Ye[o]!==void 0)for(i=0;i<Ye[o].length;i++)G1(e,Ye[o][i],a,o)&&(r=Ye[o][i],i=Ye[o].length,o=0);if(a+=r.length-1,r==="")throw new ge.Exception("Can't understand after "+e.slice(a));t.push(on[Qf(r,on)])}return t}var q1={value:ge.math.changeSign,type:0,pre:21,show:"-"},ei={value:")",show:")",type:5,pre:0},Dr={value:"(",type:4,pre:0,show:"("};ge.lex=function(e,t){var n=[Dr],r=[],o=e,i=Pt,a=0,s=vt,l="",c;typeof t<"u"&&ge.addToken(t);var d={},f=V1(o);for(c=0;c<f.length;c++){var p=f[c];if(p.type===14){if(c>0&&c<f.length-1&&f[c+1].type===1&&(f[c-1].type===1||f[c-1].type===6))throw new ge.Exception("Unexpected Space");continue}var m=p.token,h=p.type,v=p.value,x=p.precedence,y=p.show,b=n[n.length-1],$;for($=r.length;$--&&r[$]===0;)if([0,2,3,4,5,9,11,12,13].indexOf(h)!==-1){if(i[h]!==!0)throw new ge.Exception(m+" is not allowed after "+l);n.push(ei),i=er,s=Ar,r.pop()}if(i[h]!==!0)throw new ge.Exception(m+" is not allowed after "+l);if(s[h]===!0&&(h=2,v=ge.math.mul,y="&times;",x=3,c=c-1),d={value:v,type:h,pre:x,show:y,numberOfArguments:p.numberOfArguments},h===0)i=Pt,s=vt,qe(r,2),n.push(d),f[c+1].type!==4&&(n.push(Dr),r.push(2));else if(h===1)b.type===1?(b.value+=v,qe(r,1)):n.push(d),i=er,s=U1;else if(h===2)i=Pt,s=vt,qe(r,2),n.push(d);else if(h===3)n.push(d),i=er,s=Ar;else if(h===4)qe(r,1),a++,i=Pt,s=vt,n.push(d);else if(h===5){if(!a)throw new ge.Exception("Closing parenthesis are more than opening one, wait What!!!");a--,i=er,s=Ar,n.push(d),qe(r,1)}else if(h===6){if(b.hasDec)throw new ge.Exception("Two decimals are not allowed in one number");b.type!==1&&(b={value:0,type:1,pre:0},n.push(b)),i=H1,qe(r,1),s=vt,b.value+=v,b.hasDec=!0}else h===7&&(i=er,s=Ar,qe(r,1),n.push(d));h===8?(i=Pt,s=vt,qe(r,p.numberOfArguments+2),n.push(d),f[c+1].type!==4&&(n.push(Dr),r.push(p.numberOfArguments+2))):h===9?(b.type===9?b.value===ge.math.add?(b.value=v,b.show=y,qe(r,1)):b.value===ge.math.sub&&y==="-"&&(b.value=ge.math.add,b.show="+",qe(r,1)):b.type!==5&&b.type!==7&&b.type!==1&&b.type!==3&&b.type!==13?m==="-"&&(i=Pt,s=vt,qe(r,2).push(2),n.push(q1),n.push(Dr)):(n.push(d),qe(r,2)),i=Pt,s=vt):h===10?(i=Pt,s=vt,qe(r,2),n.push(d)):h===11?(i=Pt,s=vt,n.push(d)):h===12?(i=Pt,s=vt,qe(r,6),n.push(d),f[c+1].type!==4&&(n.push(Dr),r.push(6))):h===13&&(i=er,s=Ar,n.push(d)),qe(r,-1),l=m}for($=r.length;$--;)n.push(ei);if(i[5]!==!0)throw new ge.Exception("complete the expression");for(;a--;)n.push(ei);return n.push(ei),new ge(n)};var Y1=ge,us=Y1;us.prototype.toPostfix=function(){for(var e=[],t,n,r,o,i,a=[{value:"(",type:4,pre:0}],s=this.value,l=1;l<s.length;l++)if(s[l].type===1||s[l].type===3||s[l].type===13)s[l].type===1&&(s[l].value=Number(s[l].value)),e.push(s[l]);else if(s[l].type===4)a.push(s[l]);else if(s[l].type===5)for(;(n=a.pop()).type!==4;)e.push(n);else if(s[l].type===11){for(;(n=a.pop()).type!==4;)e.push(n);a.push(n)}else{t=s[l],o=t.pre,i=a[a.length-1],r=i.pre;var c=i.value=="Math.pow"&&t.value=="Math.pow";if(o>r)a.push(t);else{for(;r>=o&&!c||c&&o<r;)n=a.pop(),i=a[a.length-1],e.push(n),r=i.pre,c=t.value=="Math.pow"&&i.value=="Math.pow";a.push(t)}}return new us(e)};var K1=us,Ir=K1;Ir.prototype.postfixEval=function(e){e=e||{},e.PI=Math.PI,e.E=Math.E;for(var t=[],n,r,o,i=this.value,a=typeof e.n<"u",s=0;s<i.length;s++)if(i[s].type===1)t.push({value:i[s].value,type:1});else if(i[s].type===3)t.push({value:e[i[s].value],type:1});else if(i[s].type===0)typeof t[t.length-1].type>"u"?t[t.length-1].value.push(i[s]):t[t.length-1].value=i[s].value(t[t.length-1].value);else if(i[s].type===7)typeof t[t.length-1].type>"u"?t[t.length-1].value.push(i[s]):t[t.length-1].value=i[s].value(t[t.length-1].value);else if(i[s].type===8){for(var l=[],c=0;c<i[s].numberOfArguments;c++)l.push(t.pop().value);t.push({type:1,value:i[s].value.apply(i[s],l.reverse())})}else i[s].type===10?(n=t.pop(),r=t.pop(),typeof r.type>"u"?(r.value=r.concat(n),r.value.push(i[s]),t.push(r)):typeof n.type>"u"?(n.unshift(r),n.push(i[s]),t.push(n)):t.push({type:1,value:i[s].value(r.value,n.value)})):i[s].type===2||i[s].type===9?(n=t.pop(),r=t.pop(),typeof r.type>"u"?(r=r.concat(n),r.push(i[s]),t.push(r)):typeof n.type>"u"?(n.unshift(r),n.push(i[s]),t.push(n)):t.push({type:1,value:i[s].value(r.value,n.value)})):i[s].type===12?(n=t.pop(),typeof n.type<"u"&&(n=[n]),r=t.pop(),o=t.pop(),t.push({type:1,value:i[s].value(o.value,r.value,new Ir(n))})):i[s].type===13&&(a?t.push({value:e[i[s].value],type:3}):t.push([i[s]]));if(t.length>1)throw new Ir.Exception("Uncaught Syntax error");return t[0].value>1e15?"Infinity":parseFloat(t[0].value.toFixed(15))},Ir.eval=function(e,t,n){return typeof t>"u"?this.lex(e).toPostfix().postfixEval():typeof n>"u"?typeof t.length<"u"?this.lex(e,t).toPostfix().postfixEval():this.lex(e).toPostfix().postfixEval(t):this.lex(e,t).toPostfix().postfixEval(n)};var X1=Ir,Jf=X1;Jf.prototype.formulaEval=function(){for(var e,t,n,r=[],o=this.value,i=0;i<o.length;i++)o[i].type===1||o[i].type===3?r.push({value:o[i].type===3?o[i].show:o[i].value,type:1}):o[i].type===13?r.push({value:o[i].show,type:1}):o[i].type===0?r[r.length-1]={value:o[i].show+(o[i].show!="-"?"(":"")+r[r.length-1].value+(o[i].show!="-"?")":""),type:0}:o[i].type===7?r[r.length-1]={value:(r[r.length-1].type!=1?"(":"")+r[r.length-1].value+(r[r.length-1].type!=1?")":"")+o[i].show,type:7}:o[i].type===10?(e=r.pop(),t=r.pop(),o[i].show==="P"||o[i].show==="C"?r.push({value:"<sup>"+t.value+"</sup>"+o[i].show+"<sub>"+e.value+"</sub>",type:10}):r.push({value:(t.type!=1?"(":"")+t.value+(t.type!=1?")":"")+"<sup>"+e.value+"</sup>",type:1})):o[i].type===2||o[i].type===9?(e=r.pop(),t=r.pop(),r.push({value:(t.type!=1?"(":"")+t.value+(t.type!=1?")":"")+o[i].show+(e.type!=1?"(":"")+e.value+(e.type!=1?")":""),type:o[i].type})):o[i].type===12&&(e=r.pop(),t=r.pop(),n=r.pop(),r.push({value:o[i].show+"("+n.value+","+t.value+","+e.value+")",type:12}));return r[0].value};var R1=Jf,Z1=I1,Q1=j1,J1=R1,e$=100,t$=/(\+|\-|\*|\\|[^a-z]|)(\s*)(\()/g,ds,n$=r$;function r$(e,t){ds=0,t=Math.pow(10,t===void 0?5:t),e=e.replace(/\n+/g," ");function n(o,i,a){if(ds++>e$)throw ds=0,new Error("Call stack overflow for "+a);if(o==="")throw new Error(i+"(): '"+a+"' must contain a non-whitespace string");o=r(o,a);var s=o$(o);if(s.length>1||o.indexOf("var(")>-1)return i+"("+o+")";var l=s[0]||"";l==="%"&&(o=o.replace(/\b[0-9\.]+%/g,function(f){return parseFloat(f.slice(0,-1))*.01}));var c=o.replace(new RegExp(l,"gi"),""),d;try{d=J1.eval(c)}catch{return i+"("+o+")"}return l==="%"&&(d*=100),(i.length||l==="%")&&(d=Math.round(d*t)/t),d+=l,d}function r(o,i){o=o.replace(/((?:\-[a-z]+\-)?calc)/g,"");for(var a="",s=o,l;l=t$.exec(s);){l[0].index>0&&(a+=s.substring(0,l[0].index));var c=Z1("(",")",s.substring([0].index));if(c.body==="")throw new Error("'"+o+"' must contain a non-whitespace string");var d=n(c.body,"",i);a+=c.pre+d,s=c.post}return a+s}return Q1(e,/((?:\-[a-z]+\-)?calc)\(/,n)}function o$(e){for(var t=[],n=[],r=/[\.0-9]([%a-z]+)/gi,o=r.exec(e);o;)!o||!o[1]||(n.indexOf(o[1].toLowerCase())===-1&&(t.push(o[1]),n.push(o[1].toLowerCase())),o=r.exec(e));return t}const fs=Qn(n$);var i$=typeof Nr=="object"&&Nr&&Nr.Object===Object&&Nr,a$=i$,s$=a$,l$=typeof self=="object"&&self&&self.Object===Object&&self,c$=s$||l$||Function("return this")(),ti=c$,u$=ti,d$=u$.Symbol,ep=d$,tp=ep,np=Object.prototype,f$=np.hasOwnProperty,p$=np.toString,Lr=tp?tp.toStringTag:void 0;function h$(e){var t=f$.call(e,Lr),n=e[Lr];try{e[Lr]=void 0;var r=!0}catch{}var o=p$.call(e);return r&&(t?e[Lr]=n:delete e[Lr]),o}var m$=h$,v$=Object.prototype,g$=v$.toString;function y$(e){return g$.call(e)}var b$=y$,rp=ep,x$=m$,w$=b$,$$="[object Null]",C$="[object Undefined]",op=rp?rp.toStringTag:void 0;function S$(e){return e==null?e===void 0?C$:$$:op&&op in Object(e)?x$(e):w$(e)}var ip=S$;function E$(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var ni=E$,T$=ip,P$=ni,M$="[object AsyncFunction]",k$="[object Function]",O$="[object GeneratorFunction]",_$="[object Proxy]";function N$(e){if(!P$(e))return!1;var t=T$(e);return t==k$||t==O$||t==M$||t==_$}var A$=N$,D$=ti,I$=D$["__core-js_shared__"],L$=I$,ps=L$,ap=function(){var e=/[^.]+$/.exec(ps&&ps.keys&&ps.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function F$(e){return!!ap&&ap in e}var j$=F$,z$=Function.prototype,W$=z$.toString;function B$(e){if(e!=null){try{return W$.call(e)}catch{}try{return e+""}catch{}}return""}var U$=B$,H$=A$,G$=j$,V$=ni,q$=U$,Y$=/[\\^$.*+?()[\]{}|]/g,K$=/^\[object .+?Constructor\]$/,X$=Function.prototype,R$=Object.prototype,Z$=X$.toString,Q$=R$.hasOwnProperty,J$=RegExp("^"+Z$.call(Q$).replace(Y$,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function eC(e){if(!V$(e)||G$(e))return!1;var t=H$(e)?J$:K$;return t.test(q$(e))}var tC=eC;function nC(e,t){return e==null?void 0:e[t]}var rC=nC,oC=tC,iC=rC;function aC(e,t){var n=iC(e,t);return oC(n)?n:void 0}var sp=aC,sC=sp,lC=sC(Object,"create"),ri=lC,lp=ri;function cC(){this.__data__=lp?lp(null):{},this.size=0}var uC=cC;function dC(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var fC=dC,pC=ri,hC="__lodash_hash_undefined__",mC=Object.prototype,vC=mC.hasOwnProperty;function gC(e){var t=this.__data__;if(pC){var n=t[e];return n===hC?void 0:n}return vC.call(t,e)?t[e]:void 0}var yC=gC,bC=ri,xC=Object.prototype,wC=xC.hasOwnProperty;function $C(e){var t=this.__data__;return bC?t[e]!==void 0:wC.call(t,e)}var CC=$C,SC=ri,EC="__lodash_hash_undefined__";function TC(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=SC&&t===void 0?EC:t,this}var PC=TC,MC=uC,kC=fC,OC=yC,_C=CC,NC=PC;function tr(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}tr.prototype.clear=MC,tr.prototype.delete=kC,tr.prototype.get=OC,tr.prototype.has=_C,tr.prototype.set=NC;var AC=tr;function DC(){this.__data__=[],this.size=0}var IC=DC;function LC(e,t){return e===t||e!==e&&t!==t}var FC=LC,jC=FC;function zC(e,t){for(var n=e.length;n--;)if(jC(e[n][0],t))return n;return-1}var oi=zC,WC=oi,BC=Array.prototype,UC=BC.splice;function HC(e){var t=this.__data__,n=WC(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():UC.call(t,n,1),--this.size,!0}var GC=HC,VC=oi;function qC(e){var t=this.__data__,n=VC(t,e);return n<0?void 0:t[n][1]}var YC=qC,KC=oi;function XC(e){return KC(this.__data__,e)>-1}var RC=XC,ZC=oi;function QC(e,t){var n=this.__data__,r=ZC(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}var JC=QC,eS=IC,tS=GC,nS=YC,rS=RC,oS=JC;function nr(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}nr.prototype.clear=eS,nr.prototype.delete=tS,nr.prototype.get=nS,nr.prototype.has=rS,nr.prototype.set=oS;var iS=nr,aS=sp,sS=ti,lS=aS(sS,"Map"),cS=lS,cp=AC,uS=iS,dS=cS;function fS(){this.size=0,this.__data__={hash:new cp,map:new(dS||uS),string:new cp}}var pS=fS;function hS(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var mS=hS,vS=mS;function gS(e,t){var n=e.__data__;return vS(t)?n[typeof t=="string"?"string":"hash"]:n.map}var ii=gS,yS=ii;function bS(e){var t=yS(this,e).delete(e);return this.size-=t?1:0,t}var xS=bS,wS=ii;function $S(e){return wS(this,e).get(e)}var CS=$S,SS=ii;function ES(e){return SS(this,e).has(e)}var TS=ES,PS=ii;function MS(e,t){var n=PS(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}var kS=MS,OS=pS,_S=xS,NS=CS,AS=TS,DS=kS;function rr(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}rr.prototype.clear=OS,rr.prototype.delete=_S,rr.prototype.get=NS,rr.prototype.has=AS,rr.prototype.set=DS;var IS=rr,up=IS,LS="Expected a function";function hs(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(LS);var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=e.apply(this,r);return n.cache=i.set(o,a)||i,a};return n.cache=new(hs.Cache||up),n}hs.Cache=up;var FS=hs;const jS=Qn(FS);var dp="__react_svg_text_measurement_id";function zS(e,t){try{var n=document.getElementById(dp);if(!n){var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("aria-hidden","true"),r.style.width="0",r.style.height="0",r.style.position="absolute",r.style.top="-100%",r.style.left="-100%",n=document.createElementNS("http://www.w3.org/2000/svg","text"),n.setAttribute("id",dp),r.appendChild(n),document.body.appendChild(r)}return Object.assign(n.style,t),n.textContent=e,n.getComputedTextLength()}catch{return null}}const fp=jS(zS,function(e,t){return e+"_"+JSON.stringify(t)});var WS=["verticalAnchor","scaleToFit","angle","width","lineHeight","capHeight","children","style"];function BS(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function ms(e){return typeof e=="number"}function pp(e){return typeof e=="number"&&Number.isFinite(e)||typeof e=="string"}function US(e){var t=e.verticalAnchor,n=t===void 0?"end":t,r=e.scaleToFit,o=r===void 0?!1:r,i=e.angle,a=e.width,s=e.lineHeight,l=s===void 0?"1em":s,c=e.capHeight,d=c===void 0?"0.71em":c,f=e.children,p=e.style,m=BS(e,WS),h=m.x,v=h===void 0?0:h,x=m.y,y=x===void 0?0:x,b=!pp(v)||!pp(y),$=u.useMemo(function(){var _=f==null?[]:f.toString().split(/(?:(?!\u00A0+)\s+)/);return{wordsWithWidth:_.map(function(j){return{word:j,wordWidth:fp(j,p)||0}}),spaceWidth:fp(" ",p)||0}},[f,p]),S=$.wordsWithWidth,w=$.spaceWidth,T=u.useMemo(function(){return b?[]:a||o?S.reduce(function(_,j){var F=j.word,V=j.wordWidth,R=_[_.length-1];if(R&&(a==null||o||(R.width||0)+V+w<a))R.words.push(F),R.width=R.width||0,R.width+=V+w;else{var X={words:[F],width:V};_.push(X)}return _},[]):[{words:f==null?[]:f.toString().split(/(?:(?!\u00A0+)\s+)/)}]},[b,a,o,f,S,w]),O=u.useMemo(function(){var _=b?"":fs(n==="start"?"calc("+d+")":n==="middle"?"calc("+(T.length-1)/2+" * -"+l+" + ("+d+" / 2))":"calc("+(T.length-1)+" * -"+l+")");return _},[b,n,d,T.length,l]),P=u.useMemo(function(){var _=[];if(b)return"";if(ms(v)&&ms(y)&&ms(a)&&o&&T.length>0){var j=T[0].width||1,F=o==="shrink-only"?Math.min(a/j,1):a/j,V=F,R=v-F*v,X=y-V*y;_.push("matrix("+F+", 0, 0, "+V+", "+R+", "+X+")")}return i&&_.push("rotate("+i+", "+v+", "+y+")"),_.length>0?_.join(" "):""},[b,v,y,a,o,T,i]);return{wordsByLines:T,startDy:O,transform:P}}var HS=["dx","dy","textAnchor","innerRef","innerTextRef","verticalAnchor","angle","lineHeight","scaleToFit","capHeight","width"];function vs(){return vs=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},vs.apply(this,arguments)}function GS(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}var VS={overflow:"visible"};function gs(e){var t=e.dx,n=t===void 0?0:t,r=e.dy,o=r===void 0?0:r,i=e.textAnchor,a=i===void 0?"start":i,s=e.innerRef,l=e.innerTextRef;e.verticalAnchor,e.angle;var c=e.lineHeight,d=c===void 0?"1em":c;e.scaleToFit,e.capHeight,e.width;var f=GS(e,HS),p=f.x,m=p===void 0?0:p,h=f.fontSize,v=US(e),x=v.wordsByLines,y=v.startDy,b=v.transform;return u.createElement("svg",{ref:s,x:n,y:o,fontSize:h,style:VS},x.length>0?u.createElement("text",vs({ref:l,transform:b},f,{textAnchor:a}),x.map(function($,S){return u.createElement("tspan",{key:S,x:m,dy:S===0?y:d},$.words.join(" "))})):null)}function ys(e,t,n){var r,o,i,a,s;t==null&&(t=100);function l(){var d=Date.now()-a;d<t&&d>=0?r=setTimeout(l,t-d):(r=null,n||(s=e.apply(i,o),i=o=null))}var c=function(){i=this,o=arguments,a=Date.now();var d=n&&!r;return r||(r=setTimeout(l,t)),d&&(s=e.apply(i,o),i=o=null),s};return c.clear=function(){r&&(clearTimeout(r),r=null)},c.flush=function(){r&&(s=e.apply(i,o),i=o=null,clearTimeout(r),r=null)},c}ys.debounce=ys;var qS=ys;const hp=Qn(qS);function YS(e){let{debounce:t,scroll:n,polyfill:r,offsetSize:o}=e===void 0?{debounce:0,scroll:!1,offsetSize:!1}:e;const i=r||(typeof window>"u"?class{}:window.ResizeObserver);if(!i)throw new Error("This browser does not support ResizeObserver out of the box. See: https://github.com/react-spring/react-use-measure/#resize-observer-polyfills");const[a,s]=u.useState({left:0,top:0,width:0,height:0,bottom:0,right:0,x:0,y:0}),l=u.useRef({element:null,scrollContainers:null,resizeObserver:null,lastBounds:a}),c=t?typeof t=="number"?t:t.scroll:null,d=t?typeof t=="number"?t:t.resize:null,f=u.useRef(!1);u.useEffect(()=>(f.current=!0,()=>void(f.current=!1)));const[p,m,h]=u.useMemo(()=>{const b=()=>{if(!l.current.element)return;const{left:$,top:S,width:w,height:T,bottom:O,right:P,x:_,y:j}=l.current.element.getBoundingClientRect(),F={left:$,top:S,width:w,height:T,bottom:O,right:P,x:_,y:j};l.current.element instanceof HTMLElement&&o&&(F.height=l.current.element.offsetHeight,F.width=l.current.element.offsetWidth),Object.freeze(F),f.current&&!ZS(l.current.lastBounds,F)&&s(l.current.lastBounds=F)};return[b,d?hp(b,d):b,c?hp(b,c):b]},[s,o,c,d]);function v(){l.current.scrollContainers&&(l.current.scrollContainers.forEach(b=>b.removeEventListener("scroll",h,!0)),l.current.scrollContainers=null),l.current.resizeObserver&&(l.current.resizeObserver.disconnect(),l.current.resizeObserver=null)}function x(){l.current.element&&(l.current.resizeObserver=new i(h),l.current.resizeObserver.observe(l.current.element),n&&l.current.scrollContainers&&l.current.scrollContainers.forEach(b=>b.addEventListener("scroll",h,{capture:!0,passive:!0})))}const y=b=>{!b||b===l.current.element||(v(),l.current.element=b,l.current.scrollContainers=mp(b),x())};return XS(h,!!n),KS(m),u.useEffect(()=>{v(),x()},[n,h,m]),u.useEffect(()=>v,[]),[y,a,p]}function KS(e){u.useEffect(()=>{const t=e;return window.addEventListener("resize",t),()=>void window.removeEventListener("resize",t)},[e])}function XS(e,t){u.useEffect(()=>{if(t){const n=e;return window.addEventListener("scroll",n,{capture:!0,passive:!0}),()=>void window.removeEventListener("scroll",n,!0)}},[e,t])}function mp(e){const t=[];if(!e||e===document.body)return t;const{overflow:n,overflowX:r,overflowY:o}=window.getComputedStyle(e);return[n,r,o].some(i=>i==="auto"||i==="scroll")&&t.push(e),[...t,...mp(e.parentElement)]}const RS=["x","y","top","bottom","left","right","width","height"],ZS=(e,t)=>RS.every(n=>e[n]===t[n]);var an=function(){function e(n){var r=n.x,o=r===void 0?0:r,i=n.y,a=i===void 0?0:i;this.x=0,this.y=0,this.x=o,this.y=a}var t=e.prototype;return t.value=function(){return{x:this.x,y:this.y}},t.toArray=function(){return[this.x,this.y]},e}();function QS(e,t){return new an({x:e.x+t.x,y:e.y+t.y})}function JS(e,t){return new an({x:e.x-t.x,y:e.y-t.y})}const vp=Jn(Object.freeze(Object.defineProperty({__proto__:null,Point:an,subtractPoints:JS,sumPoints:QS},Symbol.toStringTag,{value:"Module"})));function eE(e){return!!e&&e instanceof Element}function tE(e){return!!e&&(e instanceof SVGElement||"ownerSVGElement"in e)}function nE(e){return!!e&&"createSVGPoint"in e}function rE(e){return!!e&&"getScreenCTM"in e}function oE(e){return!!e&&"changedTouches"in e}function iE(e){return!!e&&"clientX"in e}function aE(e){return!!e&&(e instanceof Event||"nativeEvent"in e&&e.nativeEvent instanceof Event)}function Fr(){return Fr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Fr.apply(this,arguments)}var bs={x:0,y:0};function sE(e){if(!e)return Fr({},bs);if(oE(e))return e.changedTouches.length>0?{x:e.changedTouches[0].clientX,y:e.changedTouches[0].clientY}:Fr({},bs);if(iE(e))return{x:e.clientX,y:e.clientY};var t=e==null?void 0:e.target,n=t&&"getBoundingClientRect"in t?t.getBoundingClientRect():null;return n?{x:n.x+n.width/2,y:n.y+n.height/2}:Fr({},bs)}function gp(e,t){if(!e||!t)return null;var n=sE(t),r=tE(e)?e.ownerSVGElement:e,o=rE(r)?r.getScreenCTM():null;if(nE(r)&&o){var i=r.createSVGPoint();return i.x=n.x,i.y=n.y,i=i.matrixTransform(o.inverse()),new an({x:i.x,y:i.y})}var a=e.getBoundingClientRect();return new an({x:n.x-a.left-e.clientLeft,y:n.y-a.top-e.clientTop})}function lE(e,t){if(eE(e)&&t)return gp(e,t);if(aE(e)){var n=e,r=n.target;if(r)return gp(r,n)}return null}function sn(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function cE(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function xs(e){let t,n,r;e.length!==2?(t=sn,n=(s,l)=>sn(e(s),l),r=(s,l)=>e(s)-l):(t=e===sn||e===cE?e:uE,n=e,r=e);function o(s,l,c=0,d=s.length){if(c<d){if(t(l,l)!==0)return d;do{const f=c+d>>>1;n(s[f],l)<0?c=f+1:d=f}while(c<d)}return c}function i(s,l,c=0,d=s.length){if(c<d){if(t(l,l)!==0)return d;do{const f=c+d>>>1;n(s[f],l)<=0?c=f+1:d=f}while(c<d)}return c}function a(s,l,c=0,d=s.length){const f=o(s,l,c,d-1);return f>c&&r(s[f-1],l)>-r(s[f],l)?f-1:f}return{left:o,center:a,right:i}}function uE(){return 0}function yp(e){return e===null?NaN:+e}function*dE(e,t){if(t===void 0)for(let n of e)n!=null&&(n=+n)>=n&&(yield n);else{let n=-1;for(let r of e)(r=t(r,++n,e))!=null&&(r=+r)>=r&&(yield r)}}const fE=xs(sn).right;xs(yp).center;const or=fE;function pE(e,t){let n=0;if(t===void 0)for(let r of e)r!=null&&(r=+r)>=r&&++n;else{let r=-1;for(let o of e)(o=t(o,++r,e))!=null&&(o=+o)>=o&&++n}return n}function ai(e,t){let n,r;if(t===void 0)for(const o of e)o!=null&&(n===void 0?o>=o&&(n=r=o):(n>o&&(n=o),r<o&&(r=o)));else{let o=-1;for(let i of e)(i=t(i,++o,e))!=null&&(n===void 0?i>=i&&(n=r=i):(n>i&&(n=i),r<i&&(r=i)))}return[n,r]}class bp extends Map{constructor(t,n=vE){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[r,o]of t)this.set(r,o)}get(t){return super.get(xp(this,t))}has(t){return super.has(xp(this,t))}set(t,n){return super.set(hE(this,t),n)}delete(t){return super.delete(mE(this,t))}}function xp({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function hE({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function mE({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function vE(e){return e!==null&&typeof e=="object"?e.valueOf():e}function gE(e){return e}function yE(e=sn){if(e===sn)return wp;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const r=e(t,n);return r||r===0?r:(e(n,n)===0)-(e(t,t)===0)}}function wp(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}var bE=Array.prototype,xE=bE.slice;function ws(e){return()=>e}const wE=Math.sqrt(50),$E=Math.sqrt(10),CE=Math.sqrt(2);function si(e,t,n){const r=(t-e)/Math.max(0,n),o=Math.floor(Math.log10(r)),i=r/Math.pow(10,o),a=i>=wE?10:i>=$E?5:i>=CE?2:1;let s,l,c;return o<0?(c=Math.pow(10,-o)/a,s=Math.round(e*c),l=Math.round(t*c),s/c<e&&++s,l/c>t&&--l,c=-c):(c=Math.pow(10,o)*a,s=Math.round(e/c),l=Math.round(t/c),s*c<e&&++s,l*c>t&&--l),l<s&&.5<=n&&n<2?si(e,t,n*2):[s,l,c]}function li(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[o,i,a]=r?si(t,e,n):si(e,t,n);if(!(i>=o))return[];const s=i-o+1,l=new Array(s);if(r)if(a<0)for(let c=0;c<s;++c)l[c]=(i-c)/-a;else for(let c=0;c<s;++c)l[c]=(i-c)*a;else if(a<0)for(let c=0;c<s;++c)l[c]=(o+c)/-a;else for(let c=0;c<s;++c)l[c]=(o+c)*a;return l}function ir(e,t,n){return t=+t,e=+e,n=+n,si(e,t,n)[2]}function $s(e,t,n){t=+t,e=+e,n=+n;const r=t<e,o=r?ir(t,e,n):ir(e,t,n);return(r?-1:1)*(o<0?1/-o:o)}function SE(e,t,n){let r;for(;;){const o=ir(e,t,n);if(o===r||o===0||!isFinite(o))return[e,t];o>0?(e=Math.floor(e/o)*o,t=Math.ceil(t/o)*o):o<0&&(e=Math.ceil(e*o)/o,t=Math.floor(t*o)/o),r=o}}function EE(e){return Math.max(1,Math.ceil(Math.log(pE(e))/Math.LN2)+1)}function TE(){var e=gE,t=ai,n=EE;function r(o){Array.isArray(o)||(o=Array.from(o));var i,a=o.length,s,l,c=new Array(a);for(i=0;i<a;++i)c[i]=e(o[i],i,o);var d=t(c),f=d[0],p=d[1],m=n(c,f,p);if(!Array.isArray(m)){const $=p,S=+m;if(t===ai&&([f,p]=SE(f,p,S)),m=li(f,p,S),m[0]<=f&&(l=ir(f,p,S)),m[m.length-1]>=p)if($>=p&&t===ai){const w=ir(f,p,S);isFinite(w)&&(w>0?p=(Math.floor(p/w)+1)*w:w<0&&(p=(Math.ceil(p*-w)+1)/-w))}else m.pop()}for(var h=m.length,v=0,x=h;m[v]<=f;)++v;for(;m[x-1]>p;)--x;(v||x<h)&&(m=m.slice(v,x),h=x-v);var y=new Array(h+1),b;for(i=0;i<=h;++i)b=y[i]=[],b.x0=i>0?m[i-1]:f,b.x1=i<h?m[i]:p;if(isFinite(l)){if(l>0)for(i=0;i<a;++i)(s=c[i])!=null&&f<=s&&s<=p&&y[Math.min(h,Math.floor((s-f)/l))].push(o[i]);else if(l<0){for(i=0;i<a;++i)if((s=c[i])!=null&&f<=s&&s<=p){const $=Math.floor((f-s)*l);y[Math.min(h,$+(m[$]<=s))].push(o[i])}}}else for(i=0;i<a;++i)(s=c[i])!=null&&f<=s&&s<=p&&y[or(m,s,0,h)].push(o[i]);return y}return r.value=function(o){return arguments.length?(e=typeof o=="function"?o:ws(o),r):e},r.domain=function(o){return arguments.length?(t=typeof o=="function"?o:ws([o[0],o[1]]),r):t},r.thresholds=function(o){return arguments.length?(n=typeof o=="function"?o:ws(Array.isArray(o)?xE.call(o):o),r):n},r}function Cs(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let o of e)(o=t(o,++r,e))!=null&&(n<o||n===void 0&&o>=o)&&(n=o)}return n}function $p(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let o of e)(o=t(o,++r,e))!=null&&(n>o||n===void 0&&o>=o)&&(n=o)}return n}function Cp(e,t,n=0,r=1/0,o){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(e.length-1,r)),!(n<=t&&t<=r))return e;for(o=o===void 0?wp:yE(o);r>n;){if(r-n>600){const l=r-n+1,c=t-n+1,d=Math.log(l),f=.5*Math.exp(2*d/3),p=.5*Math.sqrt(d*f*(l-f)/l)*(c-l/2<0?-1:1),m=Math.max(n,Math.floor(t-c*f/l+p)),h=Math.min(r,Math.floor(t+(l-c)*f/l+p));Cp(e,t,m,h,o)}const i=e[t];let a=n,s=r;for(jr(e,n,t),o(e[r],i)>0&&jr(e,n,r);a<s;){for(jr(e,a,s),++a,--s;o(e[a],i)<0;)++a;for(;o(e[s],i)>0;)--s}o(e[n],i)===0?jr(e,n,s):(++s,jr(e,s,r)),s<=t&&(n=s+1),t<=s&&(r=s-1)}return e}function jr(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function PE(e,t,n){if(e=Float64Array.from(dE(e,n)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return $p(e);if(t>=1)return Cs(e);var r,o=(r-1)*t,i=Math.floor(o),a=Cs(Cp(e,i).subarray(0,i+1)),s=$p(e.subarray(i+1));return a+(s-a)*(o-i)}}function ME(e,t,n=yp){if(!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return+n(e[0],0,e);if(t>=1)return+n(e[r-1],r-1,e);var r,o=(r-1)*t,i=Math.floor(o),a=+n(e[i],i,e),s=+n(e[i+1],i+1,e);return a+(s-a)*(o-i)}}function kE(e,t,n){e=+e,t=+t,n=(o=arguments.length)<2?(t=e,e=0,1):o<3?1:+n;for(var r=-1,o=Math.max(0,Math.ceil((t-e)/n))|0,i=new Array(o);++r<o;)i[r]=e+r*n;return i}function ut(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function Wt(e,t){switch(arguments.length){case 0:break;case 1:{typeof e=="function"?this.interpolator(e):this.range(e);break}default:{this.domain(e),typeof t=="function"?this.interpolator(t):this.range(t);break}}return this}const Ss=Symbol("implicit");function ci(){var e=new bp,t=[],n=[],r=Ss;function o(i){let a=e.get(i);if(a===void 0){if(r!==Ss)return r;e.set(i,a=t.push(i)-1)}return n[a%n.length]}return o.domain=function(i){if(!arguments.length)return t.slice();t=[],e=new bp;for(const a of i)e.has(a)||e.set(a,t.push(a)-1);return o},o.range=function(i){return arguments.length?(n=Array.from(i),o):n.slice()},o.unknown=function(i){return arguments.length?(r=i,o):r},o.copy=function(){return ci(t,n).unknown(r)},ut.apply(o,arguments),o}function ui(){var e=ci().unknown(void 0),t=e.domain,n=e.range,r=0,o=1,i,a,s=!1,l=0,c=0,d=.5;delete e.unknown;function f(){var p=t().length,m=o<r,h=m?o:r,v=m?r:o;i=(v-h)/Math.max(1,p-l+c*2),s&&(i=Math.floor(i)),h+=(v-h-i*(p-l))*d,a=i*(1-l),s&&(h=Math.round(h),a=Math.round(a));var x=kE(p).map(function(y){return h+i*y});return n(m?x.reverse():x)}return e.domain=function(p){return arguments.length?(t(p),f()):t()},e.range=function(p){return arguments.length?([r,o]=p,r=+r,o=+o,f()):[r,o]},e.rangeRound=function(p){return[r,o]=p,r=+r,o=+o,s=!0,f()},e.bandwidth=function(){return a},e.step=function(){return i},e.round=function(p){return arguments.length?(s=!!p,f()):s},e.padding=function(p){return arguments.length?(l=Math.min(1,c=+p),f()):l},e.paddingInner=function(p){return arguments.length?(l=Math.min(1,p),f()):l},e.paddingOuter=function(p){return arguments.length?(c=+p,f()):c},e.align=function(p){return arguments.length?(d=Math.max(0,Math.min(1,p)),f()):d},e.copy=function(){return ui(t(),[r,o]).round(s).paddingInner(l).paddingOuter(c).align(d)},ut.apply(f(),arguments)}function Sp(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return Sp(t())},e}function Ep(){return Sp(ui.apply(null,arguments).paddingInner(1))}function ar(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function zr(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function ln(){}var Tn=.7,sr=1/Tn,lr="\\s*([+-]?\\d+)\\s*",Wr="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Mt="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",OE=/^#([0-9a-f]{3,8})$/,_E=new RegExp(`^rgb\\(${lr},${lr},${lr}\\)$`),NE=new RegExp(`^rgb\\(${Mt},${Mt},${Mt}\\)$`),AE=new RegExp(`^rgba\\(${lr},${lr},${lr},${Wr}\\)$`),DE=new RegExp(`^rgba\\(${Mt},${Mt},${Mt},${Wr}\\)$`),IE=new RegExp(`^hsl\\(${Wr},${Mt},${Mt}\\)$`),LE=new RegExp(`^hsla\\(${Wr},${Mt},${Mt},${Wr}\\)$`),Tp={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};ar(ln,Br,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Pp,formatHex:Pp,formatHex8:FE,formatHsl:jE,formatRgb:Mp,toString:Mp});function Pp(){return this.rgb().formatHex()}function FE(){return this.rgb().formatHex8()}function jE(){return Ap(this).formatHsl()}function Mp(){return this.rgb().formatRgb()}function Br(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=OE.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?kp(t):n===3?new ze(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?di(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?di(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=_E.exec(e))?new ze(t[1],t[2],t[3],1):(t=NE.exec(e))?new ze(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=AE.exec(e))?di(t[1],t[2],t[3],t[4]):(t=DE.exec(e))?di(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=IE.exec(e))?Np(t[1],t[2]/100,t[3]/100,1):(t=LE.exec(e))?Np(t[1],t[2]/100,t[3]/100,t[4]):Tp.hasOwnProperty(e)?kp(Tp[e]):e==="transparent"?new ze(NaN,NaN,NaN,0):null}function kp(e){return new ze(e>>16&255,e>>8&255,e&255,1)}function di(e,t,n,r){return r<=0&&(e=t=n=NaN),new ze(e,t,n,r)}function Es(e){return e instanceof ln||(e=Br(e)),e?(e=e.rgb(),new ze(e.r,e.g,e.b,e.opacity)):new ze}function fi(e,t,n,r){return arguments.length===1?Es(e):new ze(e,t,n,r??1)}function ze(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}ar(ze,fi,zr(ln,{brighter(e){return e=e==null?sr:Math.pow(sr,e),new ze(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Tn:Math.pow(Tn,e),new ze(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new ze(Pn(this.r),Pn(this.g),Pn(this.b),pi(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Op,formatHex:Op,formatHex8:zE,formatRgb:_p,toString:_p}));function Op(){return`#${Mn(this.r)}${Mn(this.g)}${Mn(this.b)}`}function zE(){return`#${Mn(this.r)}${Mn(this.g)}${Mn(this.b)}${Mn((isNaN(this.opacity)?1:this.opacity)*255)}`}function _p(){const e=pi(this.opacity);return`${e===1?"rgb(":"rgba("}${Pn(this.r)}, ${Pn(this.g)}, ${Pn(this.b)}${e===1?")":`, ${e})`}`}function pi(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Pn(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Mn(e){return e=Pn(e),(e<16?"0":"")+e.toString(16)}function Np(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new gt(e,t,n,r)}function Ap(e){if(e instanceof gt)return new gt(e.h,e.s,e.l,e.opacity);if(e instanceof ln||(e=Br(e)),!e)return new gt;if(e instanceof gt)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,o=Math.min(t,n,r),i=Math.max(t,n,r),a=NaN,s=i-o,l=(i+o)/2;return s?(t===i?a=(n-r)/s+(n<r)*6:n===i?a=(r-t)/s+2:a=(t-n)/s+4,s/=l<.5?i+o:2-i-o,a*=60):s=l>0&&l<1?0:a,new gt(a,s,l,e.opacity)}function Ts(e,t,n,r){return arguments.length===1?Ap(e):new gt(e,t,n,r??1)}function gt(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}ar(gt,Ts,zr(ln,{brighter(e){return e=e==null?sr:Math.pow(sr,e),new gt(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Tn:Math.pow(Tn,e),new gt(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,o=2*n-r;return new ze(Ps(e>=240?e-240:e+120,o,r),Ps(e,o,r),Ps(e<120?e+240:e-120,o,r),this.opacity)},clamp(){return new gt(Dp(this.h),hi(this.s),hi(this.l),pi(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=pi(this.opacity);return`${e===1?"hsl(":"hsla("}${Dp(this.h)}, ${hi(this.s)*100}%, ${hi(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Dp(e){return e=(e||0)%360,e<0?e+360:e}function hi(e){return Math.max(0,Math.min(1,e||0))}function Ps(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const Ip=Math.PI/180,Lp=180/Math.PI,mi=18,Fp=.96422,jp=1,zp=.82521,Wp=4/29,cr=6/29,Bp=3*cr*cr,WE=cr*cr*cr;function Up(e){if(e instanceof kt)return new kt(e.l,e.a,e.b,e.opacity);if(e instanceof Bt)return Hp(e);e instanceof ze||(e=Es(e));var t=Ns(e.r),n=Ns(e.g),r=Ns(e.b),o=ks((.2225045*t+.7168786*n+.0606169*r)/jp),i,a;return t===n&&n===r?i=a=o:(i=ks((.4360747*t+.3850649*n+.1430804*r)/Fp),a=ks((.0139322*t+.0971045*n+.7141733*r)/zp)),new kt(116*o-16,500*(i-o),200*(o-a),e.opacity)}function Ms(e,t,n,r){return arguments.length===1?Up(e):new kt(e,t,n,r??1)}function kt(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}ar(kt,Ms,zr(ln,{brighter(e){return new kt(this.l+mi*(e??1),this.a,this.b,this.opacity)},darker(e){return new kt(this.l-mi*(e??1),this.a,this.b,this.opacity)},rgb(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,n=isNaN(this.b)?e:e-this.b/200;return t=Fp*Os(t),e=jp*Os(e),n=zp*Os(n),new ze(_s(3.1338561*t-1.6168667*e-.4906146*n),_s(-.9787684*t+1.9161415*e+.033454*n),_s(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}}));function ks(e){return e>WE?Math.pow(e,1/3):e/Bp+Wp}function Os(e){return e>cr?e*e*e:Bp*(e-Wp)}function _s(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function Ns(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function BE(e){if(e instanceof Bt)return new Bt(e.h,e.c,e.l,e.opacity);if(e instanceof kt||(e=Up(e)),e.a===0&&e.b===0)return new Bt(NaN,0<e.l&&e.l<100?0:NaN,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*Lp;return new Bt(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}function As(e,t,n,r){return arguments.length===1?BE(e):new Bt(e,t,n,r??1)}function Bt(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}function Hp(e){if(isNaN(e.h))return new kt(e.l,0,0,e.opacity);var t=e.h*Ip;return new kt(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}ar(Bt,As,zr(ln,{brighter(e){return new Bt(this.h,this.c,this.l+mi*(e??1),this.opacity)},darker(e){return new Bt(this.h,this.c,this.l-mi*(e??1),this.opacity)},rgb(){return Hp(this).rgb()}}));var Gp=-.14861,Ds=1.78277,Is=-.29227,vi=-.90649,Ur=1.97294,Vp=Ur*vi,qp=Ur*Ds,Yp=Ds*Is-vi*Gp;function UE(e){if(e instanceof kn)return new kn(e.h,e.s,e.l,e.opacity);e instanceof ze||(e=Es(e));var t=e.r/255,n=e.g/255,r=e.b/255,o=(Yp*r+Vp*t-qp*n)/(Yp+Vp-qp),i=r-o,a=(Ur*(n-o)-Is*i)/vi,s=Math.sqrt(a*a+i*i)/(Ur*o*(1-o)),l=s?Math.atan2(a,i)*Lp-120:NaN;return new kn(l<0?l+360:l,s,o,e.opacity)}function Ls(e,t,n,r){return arguments.length===1?UE(e):new kn(e,t,n,r??1)}function kn(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}ar(kn,Ls,zr(ln,{brighter(e){return e=e==null?sr:Math.pow(sr,e),new kn(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Tn:Math.pow(Tn,e),new kn(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=isNaN(this.h)?0:(this.h+120)*Ip,t=+this.l,n=isNaN(this.s)?0:this.s*t*(1-t),r=Math.cos(e),o=Math.sin(e);return new ze(255*(t+n*(Gp*r+Ds*o)),255*(t+n*(Is*r+vi*o)),255*(t+n*(Ur*r)),this.opacity)}}));function Kp(e,t,n,r,o){var i=e*e,a=i*e;return((1-3*e+3*i-a)*t+(4-6*i+3*a)*n+(1+3*e+3*i-3*a)*r+a*o)/6}function Xp(e){var t=e.length-1;return function(n){var r=n<=0?n=0:n>=1?(n=1,t-1):Math.floor(n*t),o=e[r],i=e[r+1],a=r>0?e[r-1]:2*o-i,s=r<t-1?e[r+2]:2*i-o;return Kp((n-r/t)*t,a,o,i,s)}}function Rp(e){var t=e.length;return function(n){var r=Math.floor(((n%=1)<0?++n:n)*t),o=e[(r+t-1)%t],i=e[r%t],a=e[(r+1)%t],s=e[(r+2)%t];return Kp((n-r/t)*t,o,i,a,s)}}const gi=e=>()=>e;function Zp(e,t){return function(n){return e+n*t}}function HE(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function yi(e,t){var n=t-e;return n?Zp(e,n>180||n<-180?n-360*Math.round(n/360):n):gi(isNaN(e)?t:e)}function GE(e){return(e=+e)==1?We:function(t,n){return n-t?HE(t,n,e):gi(isNaN(t)?n:t)}}function We(e,t){var n=t-e;return n?Zp(e,n):gi(isNaN(e)?t:e)}const bi=function e(t){var n=GE(t);function r(o,i){var a=n((o=fi(o)).r,(i=fi(i)).r),s=n(o.g,i.g),l=n(o.b,i.b),c=We(o.opacity,i.opacity);return function(d){return o.r=a(d),o.g=s(d),o.b=l(d),o.opacity=c(d),o+""}}return r.gamma=e,r}(1);function Qp(e){return function(t){var n=t.length,r=new Array(n),o=new Array(n),i=new Array(n),a,s;for(a=0;a<n;++a)s=fi(t[a]),r[a]=s.r||0,o[a]=s.g||0,i[a]=s.b||0;return r=e(r),o=e(o),i=e(i),s.opacity=1,function(l){return s.r=r(l),s.g=o(l),s.b=i(l),s+""}}}var VE=Qp(Xp),qE=Qp(Rp);function Fs(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),o;return function(i){for(o=0;o<n;++o)r[o]=e[o]*(1-i)+t[o]*i;return r}}function Jp(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function YE(e,t){return(Jp(t)?Fs:eh)(e,t)}function eh(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,o=new Array(r),i=new Array(n),a;for(a=0;a<r;++a)o[a]=On(e[a],t[a]);for(;a<n;++a)i[a]=t[a];return function(s){for(a=0;a<r;++a)i[a]=o[a](s);return i}}function th(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function yt(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function nh(e,t){var n={},r={},o;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(o in t)o in e?n[o]=On(e[o],t[o]):r[o]=t[o];return function(i){for(o in n)r[o]=n[o](i);return r}}var js=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,zs=new RegExp(js.source,"g");function KE(e){return function(){return e}}function XE(e){return function(t){return e(t)+""}}function rh(e,t){var n=js.lastIndex=zs.lastIndex=0,r,o,i,a=-1,s=[],l=[];for(e=e+"",t=t+"";(r=js.exec(e))&&(o=zs.exec(t));)(i=o.index)>n&&(i=t.slice(n,i),s[a]?s[a]+=i:s[++a]=i),(r=r[0])===(o=o[0])?s[a]?s[a]+=o:s[++a]=o:(s[++a]=null,l.push({i:a,x:yt(r,o)})),n=zs.lastIndex;return n<t.length&&(i=t.slice(n),s[a]?s[a]+=i:s[++a]=i),s.length<2?l[0]?XE(l[0].x):KE(t):(t=l.length,function(c){for(var d=0,f;d<t;++d)s[(f=l[d]).i]=f.x(c);return s.join("")})}function On(e,t){var n=typeof t,r;return t==null||n==="boolean"?gi(t):(n==="number"?yt:n==="string"?(r=Br(t))?(t=r,bi):rh:t instanceof Br?bi:t instanceof Date?th:Jp(t)?Fs:Array.isArray(t)?eh:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?nh:yt)(e,t)}function RE(e){var t=e.length;return function(n){return e[Math.max(0,Math.min(t-1,Math.floor(n*t)))]}}function ZE(e,t){var n=yi(+e,+t);return function(r){var o=n(r);return o-360*Math.floor(o/360)}}function Hr(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}var oh=180/Math.PI,Ws={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function ih(e,t,n,r,o,i){var a,s,l;return(a=Math.sqrt(e*e+t*t))&&(e/=a,t/=a),(l=e*n+t*r)&&(n-=e*l,r-=t*l),(s=Math.sqrt(n*n+r*r))&&(n/=s,r/=s,l/=s),e*r<t*n&&(e=-e,t=-t,l=-l,a=-a),{translateX:o,translateY:i,rotate:Math.atan2(t,e)*oh,skewX:Math.atan(l)*oh,scaleX:a,scaleY:s}}var xi;function QE(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?Ws:ih(t.a,t.b,t.c,t.d,t.e,t.f)}function JE(e){return e==null||(xi||(xi=document.createElementNS("http://www.w3.org/2000/svg","g")),xi.setAttribute("transform",e),!(e=xi.transform.baseVal.consolidate()))?Ws:(e=e.matrix,ih(e.a,e.b,e.c,e.d,e.e,e.f))}function ah(e,t,n,r){function o(c){return c.length?c.pop()+" ":""}function i(c,d,f,p,m,h){if(c!==f||d!==p){var v=m.push("translate(",null,t,null,n);h.push({i:v-4,x:yt(c,f)},{i:v-2,x:yt(d,p)})}else(f||p)&&m.push("translate("+f+t+p+n)}function a(c,d,f,p){c!==d?(c-d>180?d+=360:d-c>180&&(c+=360),p.push({i:f.push(o(f)+"rotate(",null,r)-2,x:yt(c,d)})):d&&f.push(o(f)+"rotate("+d+r)}function s(c,d,f,p){c!==d?p.push({i:f.push(o(f)+"skewX(",null,r)-2,x:yt(c,d)}):d&&f.push(o(f)+"skewX("+d+r)}function l(c,d,f,p,m,h){if(c!==f||d!==p){var v=m.push(o(m)+"scale(",null,",",null,")");h.push({i:v-4,x:yt(c,f)},{i:v-2,x:yt(d,p)})}else(f!==1||p!==1)&&m.push(o(m)+"scale("+f+","+p+")")}return function(c,d){var f=[],p=[];return c=e(c),d=e(d),i(c.translateX,c.translateY,d.translateX,d.translateY,f,p),a(c.rotate,d.rotate,f,p),s(c.skewX,d.skewX,f,p),l(c.scaleX,c.scaleY,d.scaleX,d.scaleY,f,p),c=d=null,function(m){for(var h=-1,v=p.length,x;++h<v;)f[(x=p[h]).i]=x.x(m);return f.join("")}}}var e2=ah(QE,"px, ","px)","deg)"),t2=ah(JE,", ",")",")"),n2=1e-12;function sh(e){return((e=Math.exp(e))+1/e)/2}function r2(e){return((e=Math.exp(e))-1/e)/2}function o2(e){return((e=Math.exp(2*e))-1)/(e+1)}const i2=function e(t,n,r){function o(i,a){var s=i[0],l=i[1],c=i[2],d=a[0],f=a[1],p=a[2],m=d-s,h=f-l,v=m*m+h*h,x,y;if(v<n2)y=Math.log(p/c)/t,x=function(O){return[s+O*m,l+O*h,c*Math.exp(t*O*y)]};else{var b=Math.sqrt(v),$=(p*p-c*c+r*v)/(2*c*n*b),S=(p*p-c*c-r*v)/(2*p*n*b),w=Math.log(Math.sqrt($*$+1)-$),T=Math.log(Math.sqrt(S*S+1)-S);y=(T-w)/t,x=function(O){var P=O*y,_=sh(w),j=c/(n*b)*(_*o2(t*P+w)-r2(w));return[s+j*m,l+j*h,c*_/sh(t*P+w)]}}return x.duration=y*1e3*t/Math.SQRT2,x}return o.rho=function(i){var a=Math.max(.001,+i),s=a*a,l=s*s;return e(a,s,l)},o}(Math.SQRT2,2,4);function lh(e){return function(t,n){var r=e((t=Ts(t)).h,(n=Ts(n)).h),o=We(t.s,n.s),i=We(t.l,n.l),a=We(t.opacity,n.opacity);return function(s){return t.h=r(s),t.s=o(s),t.l=i(s),t.opacity=a(s),t+""}}}const ch=lh(yi);var uh=lh(We);function dh(e,t){var n=We((e=Ms(e)).l,(t=Ms(t)).l),r=We(e.a,t.a),o=We(e.b,t.b),i=We(e.opacity,t.opacity);return function(a){return e.l=n(a),e.a=r(a),e.b=o(a),e.opacity=i(a),e+""}}function fh(e){return function(t,n){var r=e((t=As(t)).h,(n=As(n)).h),o=We(t.c,n.c),i=We(t.l,n.l),a=We(t.opacity,n.opacity);return function(s){return t.h=r(s),t.c=o(s),t.l=i(s),t.opacity=a(s),t+""}}}const ph=fh(yi);var hh=fh(We);function mh(e){return function t(n){n=+n;function r(o,i){var a=e((o=Ls(o)).h,(i=Ls(i)).h),s=We(o.s,i.s),l=We(o.l,i.l),c=We(o.opacity,i.opacity);return function(d){return o.h=a(d),o.s=s(d),o.l=l(Math.pow(d,n)),o.opacity=c(d),o+""}}return r.gamma=t,r}(1)}const vh=mh(yi);var gh=mh(We);function yh(e,t){t===void 0&&(t=e,e=On);for(var n=0,r=t.length-1,o=t[0],i=new Array(r<0?0:r);n<r;)i[n]=e(o,o=t[++n]);return function(a){var s=Math.max(0,Math.min(r-1,Math.floor(a*=r)));return i[s](a-s)}}function a2(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e(r/(t-1));return n}function s2(e){return function(){return e}}function wi(e){return+e}var bh=[0,1];function Ke(e){return e}function Bs(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:s2(isNaN(t)?NaN:.5)}function l2(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function c2(e,t,n){var r=e[0],o=e[1],i=t[0],a=t[1];return o<r?(r=Bs(o,r),i=n(a,i)):(r=Bs(r,o),i=n(i,a)),function(s){return i(r(s))}}function u2(e,t,n){var r=Math.min(e.length,t.length)-1,o=new Array(r),i=new Array(r),a=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++a<r;)o[a]=Bs(e[a],e[a+1]),i[a]=n(t[a],t[a+1]);return function(s){var l=or(e,s,1,r)-1;return i[l](o[l](s))}}function Gr(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function $i(){var e=bh,t=bh,n=On,r,o,i,a=Ke,s,l,c;function d(){var p=Math.min(e.length,t.length);return a!==Ke&&(a=l2(e[0],e[p-1])),s=p>2?u2:c2,l=c=null,f}function f(p){return p==null||isNaN(p=+p)?i:(l||(l=s(e.map(r),t,n)))(r(a(p)))}return f.invert=function(p){return a(o((c||(c=s(t,e.map(r),yt)))(p)))},f.domain=function(p){return arguments.length?(e=Array.from(p,wi),d()):e.slice()},f.range=function(p){return arguments.length?(t=Array.from(p),d()):t.slice()},f.rangeRound=function(p){return t=Array.from(p),n=Hr,d()},f.clamp=function(p){return arguments.length?(a=p?!0:Ke,d()):a!==Ke},f.interpolate=function(p){return arguments.length?(n=p,d()):n},f.unknown=function(p){return arguments.length?(i=p,f):i},function(p,m){return r=p,o=m,d()}}function Us(){return $i()(Ke,Ke)}function d2(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Ci(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function ur(e){return e=Ci(Math.abs(e)),e?e[1]:NaN}function f2(e,t){return function(n,r){for(var o=n.length,i=[],a=0,s=e[0],l=0;o>0&&s>0&&(l+s+1>r&&(s=Math.max(1,r-l)),i.push(n.substring(o-=s,o+s)),!((l+=s+1)>r));)s=e[a=(a+1)%e.length];return i.reverse().join(t)}}function p2(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var h2=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Vr(e){if(!(t=h2.exec(e)))throw new Error("invalid format: "+e);var t;return new Hs({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}Vr.prototype=Hs.prototype;function Hs(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}Hs.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function m2(e){e:for(var t=e.length,n=1,r=-1,o;n<t;++n)switch(e[n]){case".":r=o=n;break;case"0":r===0&&(r=n),o=n;break;default:if(!+e[n])break e;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(o+1):e}var xh;function v2(e,t){var n=Ci(e,t);if(!n)return e+"";var r=n[0],o=n[1],i=o-(xh=Math.max(-8,Math.min(8,Math.floor(o/3)))*3)+1,a=r.length;return i===a?r:i>a?r+new Array(i-a+1).join("0"):i>0?r.slice(0,i)+"."+r.slice(i):"0."+new Array(1-i).join("0")+Ci(e,Math.max(0,t+i-1))[0]}function wh(e,t){var n=Ci(e,t);if(!n)return e+"";var r=n[0],o=n[1];return o<0?"0."+new Array(-o).join("0")+r:r.length>o+1?r.slice(0,o+1)+"."+r.slice(o+1):r+new Array(o-r.length+2).join("0")}const $h={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:d2,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>wh(e*100,t),r:wh,s:v2,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function Ch(e){return e}var Sh=Array.prototype.map,Eh=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function g2(e){var t=e.grouping===void 0||e.thousands===void 0?Ch:f2(Sh.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",o=e.decimal===void 0?".":e.decimal+"",i=e.numerals===void 0?Ch:p2(Sh.call(e.numerals,String)),a=e.percent===void 0?"%":e.percent+"",s=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function c(f){f=Vr(f);var p=f.fill,m=f.align,h=f.sign,v=f.symbol,x=f.zero,y=f.width,b=f.comma,$=f.precision,S=f.trim,w=f.type;w==="n"?(b=!0,w="g"):$h[w]||($===void 0&&($=12),S=!0,w="g"),(x||p==="0"&&m==="=")&&(x=!0,p="0",m="=");var T=v==="$"?n:v==="#"&&/[boxX]/.test(w)?"0"+w.toLowerCase():"",O=v==="$"?r:/[%p]/.test(w)?a:"",P=$h[w],_=/[defgprs%]/.test(w);$=$===void 0?6:/[gprs]/.test(w)?Math.max(1,Math.min(21,$)):Math.max(0,Math.min(20,$));function j(F){var V=T,R=O,X,C,I;if(w==="c")R=P(F)+R,F="";else{F=+F;var H=F<0||1/F<0;if(F=isNaN(F)?l:P(Math.abs(F),$),S&&(F=m2(F)),H&&+F==0&&h!=="+"&&(H=!1),V=(H?h==="("?h:s:h==="-"||h==="("?"":h)+V,R=(w==="s"?Eh[8+xh/3]:"")+R+(H&&h==="("?")":""),_){for(X=-1,C=F.length;++X<C;)if(I=F.charCodeAt(X),48>I||I>57){R=(I===46?o+F.slice(X+1):F.slice(X))+R,F=F.slice(0,X);break}}}b&&!x&&(F=t(F,1/0));var B=V.length+F.length+R.length,A=B<y?new Array(y-B+1).join(p):"";switch(b&&x&&(F=t(A+F,A.length?y-R.length:1/0),A=""),m){case"<":F=V+F+R+A;break;case"=":F=V+A+F+R;break;case"^":F=A.slice(0,B=A.length>>1)+V+F+R+A.slice(B);break;default:F=A+V+F+R;break}return i(F)}return j.toString=function(){return f+""},j}function d(f,p){var m=c((f=Vr(f),f.type="f",f)),h=Math.max(-8,Math.min(8,Math.floor(ur(p)/3)))*3,v=Math.pow(10,-h),x=Eh[8+h/3];return function(y){return m(v*y)+x}}return{format:c,formatPrefix:d}}var Si,Ei,Th;y2({thousands:",",grouping:[3],currency:["$",""]});function y2(e){return Si=g2(e),Ei=Si.format,Th=Si.formatPrefix,Si}function b2(e){return Math.max(0,-ur(Math.abs(e)))}function x2(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(ur(t)/3)))*3-ur(Math.abs(e)))}function w2(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,ur(t)-ur(e))+1}function Ph(e,t,n,r){var o=$s(e,t,n),i;switch(r=Vr(r??",f"),r.type){case"s":{var a=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(i=x2(o,a))&&(r.precision=i),Th(r,a)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(i=w2(o,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=i-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(i=b2(o))&&(r.precision=i-(r.type==="%")*2);break}}return Ei(r)}function cn(e){var t=e.domain;return e.ticks=function(n){var r=t();return li(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var o=t();return Ph(o[0],o[o.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),o=0,i=r.length-1,a=r[o],s=r[i],l,c,d=10;for(s<a&&(c=a,a=s,s=c,c=o,o=i,i=c);d-- >0;){if(c=ir(a,s,n),c===l)return r[o]=a,r[i]=s,t(r);if(c>0)a=Math.floor(a/c)*c,s=Math.ceil(s/c)*c;else if(c<0)a=Math.ceil(a*c)/c,s=Math.floor(s*c)/c;else break;l=c}return e},e}function Gs(){var e=Us();return e.copy=function(){return Gr(e,Gs())},ut.apply(e,arguments),cn(e)}function Mh(e){var t;function n(r){return r==null||isNaN(r=+r)?t:r}return n.invert=n,n.domain=n.range=function(r){return arguments.length?(e=Array.from(r,wi),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return Mh(e).unknown(t)},e=arguments.length?Array.from(e,wi):[0,1],cn(n)}function kh(e,t){e=e.slice();var n=0,r=e.length-1,o=e[n],i=e[r],a;return i<o&&(a=n,n=r,r=a,a=o,o=i,i=a),e[n]=t.floor(o),e[r]=t.ceil(i),e}function Oh(e){return Math.log(e)}function _h(e){return Math.exp(e)}function $2(e){return-Math.log(-e)}function C2(e){return-Math.exp(-e)}function S2(e){return isFinite(e)?+("1e"+e):e<0?0:e}function E2(e){return e===10?S2:e===Math.E?Math.exp:t=>Math.pow(e,t)}function T2(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function Nh(e){return(t,n)=>-e(-t,n)}function Vs(e){const t=e(Oh,_h),n=t.domain;let r=10,o,i;function a(){return o=T2(r),i=E2(r),n()[0]<0?(o=Nh(o),i=Nh(i),e($2,C2)):e(Oh,_h),t}return t.base=function(s){return arguments.length?(r=+s,a()):r},t.domain=function(s){return arguments.length?(n(s),a()):n()},t.ticks=s=>{const l=n();let c=l[0],d=l[l.length-1];const f=d<c;f&&([c,d]=[d,c]);let p=o(c),m=o(d),h,v;const x=s==null?10:+s;let y=[];if(!(r%1)&&m-p<x){if(p=Math.floor(p),m=Math.ceil(m),c>0){for(;p<=m;++p)for(h=1;h<r;++h)if(v=p<0?h/i(-p):h*i(p),!(v<c)){if(v>d)break;y.push(v)}}else for(;p<=m;++p)for(h=r-1;h>=1;--h)if(v=p>0?h/i(-p):h*i(p),!(v<c)){if(v>d)break;y.push(v)}y.length*2<x&&(y=li(c,d,x))}else y=li(p,m,Math.min(m-p,x)).map(i);return f?y.reverse():y},t.tickFormat=(s,l)=>{if(s==null&&(s=10),l==null&&(l=r===10?"s":","),typeof l!="function"&&(!(r%1)&&(l=Vr(l)).precision==null&&(l.trim=!0),l=Ei(l)),s===1/0)return l;const c=Math.max(1,r*s/t.ticks().length);return d=>{let f=d/i(Math.round(o(d)));return f*r<r-.5&&(f*=r),f<=c?l(d):""}},t.nice=()=>n(kh(n(),{floor:s=>i(Math.floor(o(s))),ceil:s=>i(Math.ceil(o(s)))})),t}function qs(){const e=Vs($i()).domain([1,10]);return e.copy=()=>Gr(e,qs()).base(e.base()),ut.apply(e,arguments),e}function Ah(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function Dh(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function Ys(e){var t=1,n=e(Ah(t),Dh(t));return n.constant=function(r){return arguments.length?e(Ah(t=+r),Dh(t)):t},cn(n)}function Ks(){var e=Ys($i());return e.copy=function(){return Gr(e,Ks()).constant(e.constant())},ut.apply(e,arguments)}function Ih(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function P2(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function M2(e){return e<0?-e*e:e*e}function Xs(e){var t=e(Ke,Ke),n=1;function r(){return n===1?e(Ke,Ke):n===.5?e(P2,M2):e(Ih(n),Ih(1/n))}return t.exponent=function(o){return arguments.length?(n=+o,r()):n},cn(t)}function Ti(){var e=Xs($i());return e.copy=function(){return Gr(e,Ti()).exponent(e.exponent())},ut.apply(e,arguments),e}function Lh(){return Ti.apply(null,arguments).exponent(.5)}function Fh(e){return Math.sign(e)*e*e}function k2(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function Rs(){var e=Us(),t=[0,1],n=!1,r;function o(i){var a=k2(e(i));return isNaN(a)?r:n?Math.round(a):a}return o.invert=function(i){return e.invert(Fh(i))},o.domain=function(i){return arguments.length?(e.domain(i),o):e.domain()},o.range=function(i){return arguments.length?(e.range((t=Array.from(i,wi)).map(Fh)),o):t.slice()},o.rangeRound=function(i){return o.range(i).round(!0)},o.round=function(i){return arguments.length?(n=!!i,o):n},o.clamp=function(i){return arguments.length?(e.clamp(i),o):e.clamp()},o.unknown=function(i){return arguments.length?(r=i,o):r},o.copy=function(){return Rs(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},ut.apply(o,arguments),cn(o)}function Zs(){var e=[],t=[],n=[],r;function o(){var a=0,s=Math.max(1,t.length);for(n=new Array(s-1);++a<s;)n[a-1]=ME(e,a/s);return i}function i(a){return a==null||isNaN(a=+a)?r:t[or(n,a)]}return i.invertExtent=function(a){var s=t.indexOf(a);return s<0?[NaN,NaN]:[s>0?n[s-1]:e[0],s<n.length?n[s]:e[e.length-1]]},i.domain=function(a){if(!arguments.length)return e.slice();e=[];for(let s of a)s!=null&&!isNaN(s=+s)&&e.push(s);return e.sort(sn),o()},i.range=function(a){return arguments.length?(t=Array.from(a),o()):t.slice()},i.unknown=function(a){return arguments.length?(r=a,i):r},i.quantiles=function(){return n.slice()},i.copy=function(){return Zs().domain(e).range(t).unknown(r)},ut.apply(i,arguments)}function Qs(){var e=0,t=1,n=1,r=[.5],o=[0,1],i;function a(l){return l!=null&&l<=l?o[or(r,l,0,n)]:i}function s(){var l=-1;for(r=new Array(n);++l<n;)r[l]=((l+1)*t-(l-n)*e)/(n+1);return a}return a.domain=function(l){return arguments.length?([e,t]=l,e=+e,t=+t,s()):[e,t]},a.range=function(l){return arguments.length?(n=(o=Array.from(l)).length-1,s()):o.slice()},a.invertExtent=function(l){var c=o.indexOf(l);return c<0?[NaN,NaN]:c<1?[e,r[0]]:c>=n?[r[n-1],t]:[r[c-1],r[c]]},a.unknown=function(l){return arguments.length&&(i=l),a},a.thresholds=function(){return r.slice()},a.copy=function(){return Qs().domain([e,t]).range(o).unknown(i)},ut.apply(cn(a),arguments)}function Js(){var e=[.5],t=[0,1],n,r=1;function o(i){return i!=null&&i<=i?t[or(e,i,0,r)]:n}return o.domain=function(i){return arguments.length?(e=Array.from(i),r=Math.min(e.length,t.length-1),o):e.slice()},o.range=function(i){return arguments.length?(t=Array.from(i),r=Math.min(e.length,t.length-1),o):t.slice()},o.invertExtent=function(i){var a=t.indexOf(i);return[e[a-1],e[a]]},o.unknown=function(i){return arguments.length?(n=i,o):n},o.copy=function(){return Js().domain(e).range(t).unknown(n)},ut.apply(o,arguments)}const el=new Date,tl=new Date;function Fe(e,t,n,r){function o(i){return e(i=arguments.length===0?new Date:new Date(+i)),i}return o.floor=i=>(e(i=new Date(+i)),i),o.ceil=i=>(e(i=new Date(i-1)),t(i,1),e(i),i),o.round=i=>{const a=o(i),s=o.ceil(i);return i-a<s-i?a:s},o.offset=(i,a)=>(t(i=new Date(+i),a==null?1:Math.floor(a)),i),o.range=(i,a,s)=>{const l=[];if(i=o.ceil(i),s=s==null?1:Math.floor(s),!(i<a)||!(s>0))return l;let c;do l.push(c=new Date(+i)),t(i,s),e(i);while(c<i&&i<a);return l},o.filter=i=>Fe(a=>{if(a>=a)for(;e(a),!i(a);)a.setTime(a-1)},(a,s)=>{if(a>=a)if(s<0)for(;++s<=0;)for(;t(a,-1),!i(a););else for(;--s>=0;)for(;t(a,1),!i(a););}),n&&(o.count=(i,a)=>(el.setTime(+i),tl.setTime(+a),e(el),e(tl),Math.floor(n(el,tl))),o.every=i=>(i=Math.floor(i),!isFinite(i)||!(i>0)?null:i>1?o.filter(r?a=>r(a)%i===0:a=>o.count(0,a)%i===0):o)),o}const dr=Fe(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);dr.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Fe(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):dr);const jh=dr.range,Ut=1e3,dt=Ut*60,Ht=dt*60,Gt=Ht*24,nl=Gt*7,zh=Gt*30,rl=Gt*365,bt=Fe(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Ut)},(e,t)=>(t-e)/Ut,e=>e.getUTCSeconds()),Wh=bt.range,qr=Fe(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Ut)},(e,t)=>{e.setTime(+e+t*dt)},(e,t)=>(t-e)/dt,e=>e.getMinutes()),O2=qr.range,Yr=Fe(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*dt)},(e,t)=>(t-e)/dt,e=>e.getUTCMinutes()),_2=Yr.range,Kr=Fe(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Ut-e.getMinutes()*dt)},(e,t)=>{e.setTime(+e+t*Ht)},(e,t)=>(t-e)/Ht,e=>e.getHours()),N2=Kr.range,Xr=Fe(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*Ht)},(e,t)=>(t-e)/Ht,e=>e.getUTCHours()),A2=Xr.range,_n=Fe(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*dt)/Gt,e=>e.getDate()-1),D2=_n.range,fr=Fe(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Gt,e=>e.getUTCDate()-1),I2=fr.range,ol=Fe(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Gt,e=>Math.floor(e/Gt)),L2=ol.range;function Nn(e){return Fe(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*dt)/nl)}const An=Nn(0),Rr=Nn(1),Bh=Nn(2),Uh=Nn(3),Dn=Nn(4),Hh=Nn(5),Gh=Nn(6),Vh=An.range,F2=Rr.range,j2=Bh.range,z2=Uh.range,W2=Dn.range,B2=Hh.range,U2=Gh.range;function In(e){return Fe(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/nl)}const Ln=In(0),Zr=In(1),qh=In(2),Yh=In(3),Fn=In(4),Kh=In(5),Xh=In(6),Rh=Ln.range,H2=Zr.range,G2=qh.range,V2=Yh.range,q2=Fn.range,Y2=Kh.range,K2=Xh.range,Qr=Fe(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth()),X2=Qr.range,Jr=Fe(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth()),R2=Jr.range,xt=Fe(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());xt.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Fe(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)});const Z2=xt.range,wt=Fe(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());wt.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Fe(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)});const Q2=wt.range;function Zh(e,t,n,r,o,i){const a=[[bt,1,Ut],[bt,5,5*Ut],[bt,15,15*Ut],[bt,30,30*Ut],[i,1,dt],[i,5,5*dt],[i,15,15*dt],[i,30,30*dt],[o,1,Ht],[o,3,3*Ht],[o,6,6*Ht],[o,12,12*Ht],[r,1,Gt],[r,2,2*Gt],[n,1,nl],[t,1,zh],[t,3,3*zh],[e,1,rl]];function s(c,d,f){const p=d<c;p&&([c,d]=[d,c]);const m=f&&typeof f.range=="function"?f:l(c,d,f),h=m?m.range(c,+d+1):[];return p?h.reverse():h}function l(c,d,f){const p=Math.abs(d-c)/f,m=xs(([,,x])=>x).right(a,p);if(m===a.length)return e.every($s(c/rl,d/rl,f));if(m===0)return dr.every(Math.max($s(c,d,f),1));const[h,v]=a[p/a[m-1][2]<a[m][2]/p?m-1:m];return h.every(v)}return[s,l]}const[Qh,Jh]=Zh(wt,Jr,Ln,ol,Xr,Yr),[em,tm]=Zh(xt,Qr,An,_n,Kr,qr);function il(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function al(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function eo(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function J2(e){var t=e.dateTime,n=e.date,r=e.time,o=e.periods,i=e.days,a=e.shortDays,s=e.months,l=e.shortMonths,c=to(o),d=no(o),f=to(i),p=no(i),m=to(a),h=no(a),v=to(s),x=no(s),y=to(l),b=no(l),$={a:H,A:B,b:A,B:N,c:null,d:sm,e:sm,f:$T,g:NT,G:DT,H:bT,I:xT,j:wT,L:lm,m:CT,M:ST,p:z,q:J,Q:hm,s:mm,S:ET,u:TT,U:PT,V:MT,w:kT,W:OT,x:null,X:null,y:_T,Y:AT,Z:IT,"%":pm},S={a:Q,A:oe,b:te,B:ae,c:null,d:um,e:um,f:zT,g:XT,G:ZT,H:LT,I:FT,j:jT,L:dm,m:WT,M:BT,p:Y,q:le,Q:hm,s:mm,S:UT,u:HT,U:GT,V:VT,w:qT,W:YT,x:null,X:null,y:KT,Y:RT,Z:QT,"%":pm},w={a:j,A:F,b:V,B:R,c:X,d:im,e:im,f:mT,g:om,G:rm,H:am,I:am,j:dT,L:hT,m:uT,M:fT,p:_,q:cT,Q:gT,s:yT,S:pT,u:oT,U:iT,V:aT,w:rT,W:sT,x:C,X:I,y:om,Y:rm,Z:lT,"%":vT};$.x=T(n,$),$.X=T(r,$),$.c=T(t,$),S.x=T(n,S),S.X=T(r,S),S.c=T(t,S);function T(U,q){return function(re){var k=[],de=-1,pe=0,Ce=U.length,ke,je,_t;for(re instanceof Date||(re=new Date(+re));++de<Ce;)U.charCodeAt(de)===37&&(k.push(U.slice(pe,de)),(je=nm[ke=U.charAt(++de)])!=null?ke=U.charAt(++de):je=ke==="e"?" ":"0",(_t=q[ke])&&(ke=_t(re,je)),k.push(ke),pe=de+1);return k.push(U.slice(pe,de)),k.join("")}}function O(U,q){return function(re){var k=eo(1900,void 0,1),de=P(k,U,re+="",0),pe,Ce;if(de!=re.length)return null;if("Q"in k)return new Date(k.Q);if("s"in k)return new Date(k.s*1e3+("L"in k?k.L:0));if(q&&!("Z"in k)&&(k.Z=0),"p"in k&&(k.H=k.H%12+k.p*12),k.m===void 0&&(k.m="q"in k?k.q:0),"V"in k){if(k.V<1||k.V>53)return null;"w"in k||(k.w=1),"Z"in k?(pe=al(eo(k.y,0,1)),Ce=pe.getUTCDay(),pe=Ce>4||Ce===0?Zr.ceil(pe):Zr(pe),pe=fr.offset(pe,(k.V-1)*7),k.y=pe.getUTCFullYear(),k.m=pe.getUTCMonth(),k.d=pe.getUTCDate()+(k.w+6)%7):(pe=il(eo(k.y,0,1)),Ce=pe.getDay(),pe=Ce>4||Ce===0?Rr.ceil(pe):Rr(pe),pe=_n.offset(pe,(k.V-1)*7),k.y=pe.getFullYear(),k.m=pe.getMonth(),k.d=pe.getDate()+(k.w+6)%7)}else("W"in k||"U"in k)&&("w"in k||(k.w="u"in k?k.u%7:"W"in k?1:0),Ce="Z"in k?al(eo(k.y,0,1)).getUTCDay():il(eo(k.y,0,1)).getDay(),k.m=0,k.d="W"in k?(k.w+6)%7+k.W*7-(Ce+5)%7:k.w+k.U*7-(Ce+6)%7);return"Z"in k?(k.H+=k.Z/100|0,k.M+=k.Z%100,al(k)):il(k)}}function P(U,q,re,k){for(var de=0,pe=q.length,Ce=re.length,ke,je;de<pe;){if(k>=Ce)return-1;if(ke=q.charCodeAt(de++),ke===37){if(ke=q.charAt(de++),je=w[ke in nm?q.charAt(de++):ke],!je||(k=je(U,re,k))<0)return-1}else if(ke!=re.charCodeAt(k++))return-1}return k}function _(U,q,re){var k=c.exec(q.slice(re));return k?(U.p=d.get(k[0].toLowerCase()),re+k[0].length):-1}function j(U,q,re){var k=m.exec(q.slice(re));return k?(U.w=h.get(k[0].toLowerCase()),re+k[0].length):-1}function F(U,q,re){var k=f.exec(q.slice(re));return k?(U.w=p.get(k[0].toLowerCase()),re+k[0].length):-1}function V(U,q,re){var k=y.exec(q.slice(re));return k?(U.m=b.get(k[0].toLowerCase()),re+k[0].length):-1}function R(U,q,re){var k=v.exec(q.slice(re));return k?(U.m=x.get(k[0].toLowerCase()),re+k[0].length):-1}function X(U,q,re){return P(U,t,q,re)}function C(U,q,re){return P(U,n,q,re)}function I(U,q,re){return P(U,r,q,re)}function H(U){return a[U.getDay()]}function B(U){return i[U.getDay()]}function A(U){return l[U.getMonth()]}function N(U){return s[U.getMonth()]}function z(U){return o[+(U.getHours()>=12)]}function J(U){return 1+~~(U.getMonth()/3)}function Q(U){return a[U.getUTCDay()]}function oe(U){return i[U.getUTCDay()]}function te(U){return l[U.getUTCMonth()]}function ae(U){return s[U.getUTCMonth()]}function Y(U){return o[+(U.getUTCHours()>=12)]}function le(U){return 1+~~(U.getUTCMonth()/3)}return{format:function(U){var q=T(U+="",$);return q.toString=function(){return U},q},parse:function(U){var q=O(U+="",!1);return q.toString=function(){return U},q},utcFormat:function(U){var q=T(U+="",S);return q.toString=function(){return U},q},utcParse:function(U){var q=O(U+="",!0);return q.toString=function(){return U},q}}}var nm={"-":"",_:" ",0:"0"},Be=/^\s*\d+/,eT=/^%/,tT=/[\\^$*+?|[\]().{}]/g;function Se(e,t,n){var r=e<0?"-":"",o=(r?-e:e)+"",i=o.length;return r+(i<n?new Array(n-i+1).join(t)+o:o)}function nT(e){return e.replace(tT,"\\$&")}function to(e){return new RegExp("^(?:"+e.map(nT).join("|")+")","i")}function no(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function rT(e,t,n){var r=Be.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function oT(e,t,n){var r=Be.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function iT(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function aT(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function sT(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function rm(e,t,n){var r=Be.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function om(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function lT(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function cT(e,t,n){var r=Be.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function uT(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function im(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function dT(e,t,n){var r=Be.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function am(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function fT(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function pT(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function hT(e,t,n){var r=Be.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function mT(e,t,n){var r=Be.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function vT(e,t,n){var r=eT.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function gT(e,t,n){var r=Be.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function yT(e,t,n){var r=Be.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function sm(e,t){return Se(e.getDate(),t,2)}function bT(e,t){return Se(e.getHours(),t,2)}function xT(e,t){return Se(e.getHours()%12||12,t,2)}function wT(e,t){return Se(1+_n.count(xt(e),e),t,3)}function lm(e,t){return Se(e.getMilliseconds(),t,3)}function $T(e,t){return lm(e,t)+"000"}function CT(e,t){return Se(e.getMonth()+1,t,2)}function ST(e,t){return Se(e.getMinutes(),t,2)}function ET(e,t){return Se(e.getSeconds(),t,2)}function TT(e){var t=e.getDay();return t===0?7:t}function PT(e,t){return Se(An.count(xt(e)-1,e),t,2)}function cm(e){var t=e.getDay();return t>=4||t===0?Dn(e):Dn.ceil(e)}function MT(e,t){return e=cm(e),Se(Dn.count(xt(e),e)+(xt(e).getDay()===4),t,2)}function kT(e){return e.getDay()}function OT(e,t){return Se(Rr.count(xt(e)-1,e),t,2)}function _T(e,t){return Se(e.getFullYear()%100,t,2)}function NT(e,t){return e=cm(e),Se(e.getFullYear()%100,t,2)}function AT(e,t){return Se(e.getFullYear()%1e4,t,4)}function DT(e,t){var n=e.getDay();return e=n>=4||n===0?Dn(e):Dn.ceil(e),Se(e.getFullYear()%1e4,t,4)}function IT(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Se(t/60|0,"0",2)+Se(t%60,"0",2)}function um(e,t){return Se(e.getUTCDate(),t,2)}function LT(e,t){return Se(e.getUTCHours(),t,2)}function FT(e,t){return Se(e.getUTCHours()%12||12,t,2)}function jT(e,t){return Se(1+fr.count(wt(e),e),t,3)}function dm(e,t){return Se(e.getUTCMilliseconds(),t,3)}function zT(e,t){return dm(e,t)+"000"}function WT(e,t){return Se(e.getUTCMonth()+1,t,2)}function BT(e,t){return Se(e.getUTCMinutes(),t,2)}function UT(e,t){return Se(e.getUTCSeconds(),t,2)}function HT(e){var t=e.getUTCDay();return t===0?7:t}function GT(e,t){return Se(Ln.count(wt(e)-1,e),t,2)}function fm(e){var t=e.getUTCDay();return t>=4||t===0?Fn(e):Fn.ceil(e)}function VT(e,t){return e=fm(e),Se(Fn.count(wt(e),e)+(wt(e).getUTCDay()===4),t,2)}function qT(e){return e.getUTCDay()}function YT(e,t){return Se(Zr.count(wt(e)-1,e),t,2)}function KT(e,t){return Se(e.getUTCFullYear()%100,t,2)}function XT(e,t){return e=fm(e),Se(e.getUTCFullYear()%100,t,2)}function RT(e,t){return Se(e.getUTCFullYear()%1e4,t,4)}function ZT(e,t){var n=e.getUTCDay();return e=n>=4||n===0?Fn(e):Fn.ceil(e),Se(e.getUTCFullYear()%1e4,t,4)}function QT(){return"+0000"}function pm(){return"%"}function hm(e){return+e}function mm(e){return Math.floor(+e/1e3)}var pr,vm,gm;JT({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function JT(e){return pr=J2(e),vm=pr.format,pr.parse,gm=pr.utcFormat,pr.utcParse,pr}function eP(e){return new Date(e)}function tP(e){return e instanceof Date?+e:+new Date(+e)}function sl(e,t,n,r,o,i,a,s,l,c){var d=Us(),f=d.invert,p=d.domain,m=c(".%L"),h=c(":%S"),v=c("%I:%M"),x=c("%I %p"),y=c("%a %d"),b=c("%b %d"),$=c("%B"),S=c("%Y");function w(T){return(l(T)<T?m:s(T)<T?h:a(T)<T?v:i(T)<T?x:r(T)<T?o(T)<T?y:b:n(T)<T?$:S)(T)}return d.invert=function(T){return new Date(f(T))},d.domain=function(T){return arguments.length?p(Array.from(T,tP)):p().map(eP)},d.ticks=function(T){var O=p();return e(O[0],O[O.length-1],T??10)},d.tickFormat=function(T,O){return O==null?w:c(O)},d.nice=function(T){var O=p();return(!T||typeof T.range!="function")&&(T=t(O[0],O[O.length-1],T??10)),T?p(kh(O,T)):d},d.copy=function(){return Gr(d,sl(e,t,n,r,o,i,a,s,l,c))},d}function ym(){return ut.apply(sl(em,tm,xt,Qr,An,_n,Kr,qr,bt,vm).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function bm(){return ut.apply(sl(Qh,Jh,wt,Jr,Ln,fr,Xr,Yr,bt,gm).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function Pi(){var e=0,t=1,n,r,o,i,a=Ke,s=!1,l;function c(f){return f==null||isNaN(f=+f)?l:a(o===0?.5:(f=(i(f)-n)*o,s?Math.max(0,Math.min(1,f)):f))}c.domain=function(f){return arguments.length?([e,t]=f,n=i(e=+e),r=i(t=+t),o=n===r?0:1/(r-n),c):[e,t]},c.clamp=function(f){return arguments.length?(s=!!f,c):s},c.interpolator=function(f){return arguments.length?(a=f,c):a};function d(f){return function(p){var m,h;return arguments.length?([m,h]=p,a=f(m,h),c):[a(0),a(1)]}}return c.range=d(On),c.rangeRound=d(Hr),c.unknown=function(f){return arguments.length?(l=f,c):l},function(f){return i=f,n=f(e),r=f(t),o=n===r?0:1/(r-n),c}}function un(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function xm(){var e=cn(Pi()(Ke));return e.copy=function(){return un(e,xm())},Wt.apply(e,arguments)}function wm(){var e=Vs(Pi()).domain([1,10]);return e.copy=function(){return un(e,wm()).base(e.base())},Wt.apply(e,arguments)}function $m(){var e=Ys(Pi());return e.copy=function(){return un(e,$m()).constant(e.constant())},Wt.apply(e,arguments)}function ll(){var e=Xs(Pi());return e.copy=function(){return un(e,ll()).exponent(e.exponent())},Wt.apply(e,arguments)}function nP(){return ll.apply(null,arguments).exponent(.5)}function Cm(){var e=[],t=Ke;function n(r){if(r!=null&&!isNaN(r=+r))return t((or(e,r,1)-1)/(e.length-1))}return n.domain=function(r){if(!arguments.length)return e.slice();e=[];for(let o of r)o!=null&&!isNaN(o=+o)&&e.push(o);return e.sort(sn),n},n.interpolator=function(r){return arguments.length?(t=r,n):t},n.range=function(){return e.map((r,o)=>t(o/(e.length-1)))},n.quantiles=function(r){return Array.from({length:r+1},(o,i)=>PE(e,i/r))},n.copy=function(){return Cm(t).domain(e)},Wt.apply(n,arguments)}function Mi(){var e=0,t=.5,n=1,r=1,o,i,a,s,l,c=Ke,d,f=!1,p;function m(v){return isNaN(v=+v)?p:(v=.5+((v=+d(v))-i)*(r*v<r*i?s:l),c(f?Math.max(0,Math.min(1,v)):v))}m.domain=function(v){return arguments.length?([e,t,n]=v,o=d(e=+e),i=d(t=+t),a=d(n=+n),s=o===i?0:.5/(i-o),l=i===a?0:.5/(a-i),r=i<o?-1:1,m):[e,t,n]},m.clamp=function(v){return arguments.length?(f=!!v,m):f},m.interpolator=function(v){return arguments.length?(c=v,m):c};function h(v){return function(x){var y,b,$;return arguments.length?([y,b,$]=x,c=yh(v,[y,b,$]),m):[c(0),c(.5),c(1)]}}return m.range=h(On),m.rangeRound=h(Hr),m.unknown=function(v){return arguments.length?(p=v,m):p},function(v){return d=v,o=v(e),i=v(t),a=v(n),s=o===i?0:.5/(i-o),l=i===a?0:.5/(a-i),r=i<o?-1:1,m}}function Sm(){var e=cn(Mi()(Ke));return e.copy=function(){return un(e,Sm())},Wt.apply(e,arguments)}function Em(){var e=Vs(Mi()).domain([.1,1,10]);return e.copy=function(){return un(e,Em()).base(e.base())},Wt.apply(e,arguments)}function Tm(){var e=Ys(Mi());return e.copy=function(){return un(e,Tm()).constant(e.constant())},Wt.apply(e,arguments)}function cl(){var e=Xs(Mi());return e.copy=function(){return un(e,cl()).exponent(e.exponent())},Wt.apply(e,arguments)}function rP(){return cl.apply(null,arguments).exponent(.5)}const oP=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:ui,scaleDiverging:Sm,scaleDivergingLog:Em,scaleDivergingPow:cl,scaleDivergingSqrt:rP,scaleDivergingSymlog:Tm,scaleIdentity:Mh,scaleImplicit:Ss,scaleLinear:Gs,scaleLog:qs,scaleOrdinal:ci,scalePoint:Ep,scalePow:Ti,scaleQuantile:Zs,scaleQuantize:Qs,scaleRadial:Rs,scaleSequential:xm,scaleSequentialLog:wm,scaleSequentialPow:ll,scaleSequentialQuantile:Cm,scaleSequentialSqrt:nP,scaleSequentialSymlog:$m,scaleSqrt:Lh,scaleSymlog:Ks,scaleThreshold:Js,scaleTime:ym,scaleUtc:bm,tickFormat:Ph},Symbol.toStringTag,{value:"Module"}));function iP(e,t){t.domain&&("nice"in e||"quantiles"in e||"padding"in e,e.domain(t.domain))}function aP(e,t){t.range&&("padding"in e,e.range(t.range))}function sP(e,t){"align"in e&&"align"in t&&typeof t.align<"u"&&e.align(t.align)}function lP(e,t){"base"in e&&"base"in t&&typeof t.base<"u"&&e.base(t.base)}function cP(e,t){"clamp"in e&&"clamp"in t&&typeof t.clamp<"u"&&e.clamp(t.clamp)}function uP(e,t){"constant"in e&&"constant"in t&&typeof t.constant<"u"&&e.constant(t.constant)}function dP(e,t){"exponent"in e&&"exponent"in t&&typeof t.exponent<"u"&&e.exponent(t.exponent)}const fP=Object.freeze(Object.defineProperty({__proto__:null,interpolate:On,interpolateArray:YE,interpolateBasis:Xp,interpolateBasisClosed:Rp,interpolateCubehelix:vh,interpolateCubehelixLong:gh,interpolateDate:th,interpolateDiscrete:RE,interpolateHcl:ph,interpolateHclLong:hh,interpolateHsl:ch,interpolateHslLong:uh,interpolateHue:ZE,interpolateLab:dh,interpolateNumber:yt,interpolateNumberArray:Fs,interpolateObject:nh,interpolateRgb:bi,interpolateRgbBasis:VE,interpolateRgbBasisClosed:qE,interpolateRound:Hr,interpolateString:rh,interpolateTransformCss:e2,interpolateTransformSvg:t2,interpolateZoom:i2,piecewise:yh,quantize:a2},Symbol.toStringTag,{value:"Module"}));var Pm={lab:dh,hcl:ph,"hcl-long":hh,hsl:ch,"hsl-long":uh,cubehelix:vh,"cubehelix-long":gh,rgb:bi};function pP(e){switch(e){case"lab":case"hcl":case"hcl-long":case"hsl":case"hsl-long":case"cubehelix":case"cubehelix-long":case"rgb":return Pm[e]}var t=e.type,n=e.gamma,r=Pm[t];return typeof n>"u"?r:r.gamma(n)}function hP(e,t){if("interpolate"in t&&"interpolate"in e&&typeof t.interpolate<"u"){var n=pP(t.interpolate);e.interpolate(n)}}const mP=Object.freeze(Object.defineProperty({__proto__:null,timeDay:_n,timeDays:D2,timeFriday:Hh,timeFridays:B2,timeHour:Kr,timeHours:N2,timeInterval:Fe,timeMillisecond:dr,timeMilliseconds:jh,timeMinute:qr,timeMinutes:O2,timeMonday:Rr,timeMondays:F2,timeMonth:Qr,timeMonths:X2,timeSaturday:Gh,timeSaturdays:U2,timeSecond:bt,timeSeconds:Wh,timeSunday:An,timeSundays:Vh,timeThursday:Dn,timeThursdays:W2,timeTickInterval:tm,timeTicks:em,timeTuesday:Bh,timeTuesdays:j2,timeWednesday:Uh,timeWednesdays:z2,timeWeek:An,timeWeeks:Vh,timeYear:xt,timeYears:Z2,unixDay:ol,unixDays:L2,utcDay:fr,utcDays:I2,utcFriday:Kh,utcFridays:Y2,utcHour:Xr,utcHours:A2,utcMillisecond:dr,utcMilliseconds:jh,utcMinute:Yr,utcMinutes:_2,utcMonday:Zr,utcMondays:H2,utcMonth:Jr,utcMonths:R2,utcSaturday:Xh,utcSaturdays:K2,utcSecond:bt,utcSeconds:Wh,utcSunday:Ln,utcSundays:Rh,utcThursday:Fn,utcThursdays:q2,utcTickInterval:Jh,utcTicks:Qh,utcTuesday:qh,utcTuesdays:G2,utcWednesday:Yh,utcWednesdays:V2,utcWeek:Ln,utcWeeks:Rh,utcYear:wt,utcYears:Q2},Symbol.toStringTag,{value:"Module"}));var vP=new Date(Date.UTC(2020,1,2,3,4,5)),gP="%Y-%m-%d %H:%M";function Mm(e){var t=e.tickFormat(1,gP)(vP);return t==="2020-02-02 03:04"}var km={day:_n,hour:Kr,minute:qr,month:Qr,second:bt,week:An,year:xt},Om={day:fr,hour:Xr,minute:Yr,month:Jr,second:bt,week:Ln,year:wt};function yP(e,t){if("nice"in t&&typeof t.nice<"u"&&"nice"in e){var n=t.nice;if(typeof n=="boolean")n&&e.nice();else if(typeof n=="number")e.nice(n);else{var r=e,o=Mm(r);if(typeof n=="string")r.nice(o?Om[n]:km[n]);else{var i=n.interval,a=n.step,s=(o?Om[i]:km[i]).every(a);s!=null&&r.nice(s)}}}}function bP(e,t){"padding"in e&&"padding"in t&&typeof t.padding<"u"&&e.padding(t.padding),"paddingInner"in e&&"paddingInner"in t&&typeof t.paddingInner<"u"&&e.paddingInner(t.paddingInner),"paddingOuter"in e&&"paddingOuter"in t&&typeof t.paddingOuter<"u"&&e.paddingOuter(t.paddingOuter)}function xP(e,t){if(t.reverse){var n=e.range().slice().reverse();"padding"in e,e.range(n)}}function wP(e,t){"round"in t&&typeof t.round<"u"&&(t.round&&"interpolate"in t&&typeof t.interpolate<"u"?console.warn("[visx/scale/applyRound] ignoring round: scale config contains round and interpolate. only applying interpolate. config:",t):"round"in e?e.round(t.round):"interpolate"in e&&t.round&&e.interpolate(Hr))}function $P(e,t){"unknown"in e&&"unknown"in t&&typeof t.unknown<"u"&&e.unknown(t.unknown)}function CP(e,t){if("zero"in t&&t.zero===!0){var n=e.domain(),r=n[0],o=n[1],i=o<r,a=i?[o,r]:[r,o],s=a[0],l=a[1],c=[Math.min(0,s),Math.max(0,l)];e.domain(i?c.reverse():c)}}var _m=["domain","nice","zero","interpolate","round","range","reverse","align","base","clamp","constant","exponent","padding","unknown"],SP={domain:iP,nice:yP,zero:CP,interpolate:hP,round:wP,align:sP,base:lP,clamp:cP,constant:uP,exponent:dP,padding:bP,range:aP,reverse:xP,unknown:$P};function Xe(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=new Set(t),o=_m.filter(function(i){return r.has(i)});return function(a,s){return typeof s<"u"&&o.forEach(function(l){SP[l](a,s)}),a}}var EP=Xe("domain","range","reverse","align","padding","round");function Nm(e){return EP(ui(),e)}var TP=Xe("domain","range","reverse","align","padding","round");function Am(e){return TP(Ep(),e)}var PP=Xe("domain","range","reverse","clamp","interpolate","nice","round","zero");function ro(e){return PP(Gs(),e)}var MP=Xe("domain","range","clamp","nice","round","unknown");function kP(e){return MP(Rs(),e)}var OP=Xe("domain","range","reverse","clamp","interpolate","nice","round");function Dm(e){return OP(ym(),e)}var _P=Xe("domain","range","reverse","clamp","interpolate","nice","round");function Im(e){return _P(bm(),e)}var NP=Xe("domain","range","reverse","base","clamp","interpolate","nice","round");function Lm(e){return NP(qs(),e)}var AP=Xe("domain","range","reverse","clamp","exponent","interpolate","nice","round","zero");function Fm(e){return AP(Ti(),e)}var DP=Xe("domain","range","reverse","unknown");function jm(e){return DP(ci(),e)}var IP=Xe("domain","range","reverse","nice","zero");function zm(e){return IP(Qs(),e)}var LP=Xe("domain","range","reverse");function Wm(e){return LP(Zs(),e)}var FP=Xe("domain","range","reverse","clamp","constant","nice","zero","round");function Bm(e){return FP(Ks(),e)}var jP=Xe("domain","range","reverse");function Um(e){return jP(Js(),e)}var zP=Xe("domain","range","reverse","clamp","interpolate","nice","round","zero");function Hm(e){return zP(Lh(),e)}function oo(e){if(typeof e<"u"&&"type"in e)switch(e.type){case"linear":return ro(e);case"log":return Lm(e);case"pow":return Fm(e);case"sqrt":return Hm(e);case"symlog":return Bm(e);case"time":return Dm(e);case"utc":return Im(e);case"quantile":return Wm(e);case"quantize":return zm(e);case"threshold":return Um(e);case"ordinal":return jm(e);case"point":return Am(e);case"band":return Nm(e)}return ro(e)}var WP=Xe.apply(void 0,_m);function BP(e,t){return WP(e.copy(),t)}function UP(e){return"paddingInner"in e?"band":"padding"in e?"point":"quantiles"in e?"quantile":"base"in e?"log":"exponent"in e?e.exponent()===.5?"sqrt":"pow":"constant"in e?"symlog":"clamp"in e?e.ticks()[0]instanceof Date?Mm(e)?"utc":"time":"linear":"nice"in e?"quantize":"invertExtent"in e?"threshold":"ordinal"}function ul(e){if((typeof e=="function"||typeof e=="object"&&e)&&"valueOf"in e){var t=e.valueOf();if(typeof t=="number")return t}return e}function dl(e,t){var n=e;return"ticks"in n?n.ticks(t):n.domain().filter(function(r,o,i){return t==null||i.length<=t||o%Math.round((i.length-1)/t)===0})}function Gm(e){return e==null?void 0:e.toString()}var HP=new Set(["linear","pow","quantize","sqrt","symlog"]);function fl(e){return HP.has(e.type)}const GP=Object.freeze(Object.defineProperty({__proto__:null,coerceNumber:ul,createScale:oo,getTicks:dl,inferScaleType:UP,scaleBand:Nm,scaleCanBeZeroed:fl,scaleLinear:ro,scaleLog:Lm,scaleOrdinal:jm,scalePoint:Am,scalePower:Fm,scaleQuantile:Wm,scaleQuantize:zm,scaleRadial:kP,scaleSqrt:Hm,scaleSymlog:Bm,scaleThreshold:Um,scaleTime:Dm,scaleUtc:Im,toString:Gm,updateScale:BP},Symbol.toStringTag,{value:"Module"}));var VP=u.createContext({});const Ot=VP;function pl(e){var t,n=e;return n&&"bandwidth"in n&&(t=n==null?void 0:n.bandwidth())!=null?t:0}function ft(e){return e!=null&&typeof e=="number"&&!Number.isNaN(e)&&Number.isFinite(e)}const Vm=Jn(D1),qm=Jn(GP);var hl=Math.PI,ml=2*hl,jn=1e-6,qP=ml-jn;function vl(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function gl(){return new vl}vl.prototype=gl.prototype={constructor:vl,moveTo:function(e,t){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)},closePath:function(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(e,t){this._+="L"+(this._x1=+e)+","+(this._y1=+t)},quadraticCurveTo:function(e,t,n,r){this._+="Q"+ +e+","+ +t+","+(this._x1=+n)+","+(this._y1=+r)},bezierCurveTo:function(e,t,n,r,o,i){this._+="C"+ +e+","+ +t+","+ +n+","+ +r+","+(this._x1=+o)+","+(this._y1=+i)},arcTo:function(e,t,n,r,o){e=+e,t=+t,n=+n,r=+r,o=+o;var i=this._x1,a=this._y1,s=n-e,l=r-t,c=i-e,d=a-t,f=c*c+d*d;if(o<0)throw new Error("negative radius: "+o);if(this._x1===null)this._+="M"+(this._x1=e)+","+(this._y1=t);else if(f>jn)if(!(Math.abs(d*s-l*c)>jn)||!o)this._+="L"+(this._x1=e)+","+(this._y1=t);else{var p=n-i,m=r-a,h=s*s+l*l,v=p*p+m*m,x=Math.sqrt(h),y=Math.sqrt(f),b=o*Math.tan((hl-Math.acos((h+f-v)/(2*x*y)))/2),$=b/y,S=b/x;Math.abs($-1)>jn&&(this._+="L"+(e+$*c)+","+(t+$*d)),this._+="A"+o+","+o+",0,0,"+ +(d*p>c*m)+","+(this._x1=e+S*s)+","+(this._y1=t+S*l)}},arc:function(e,t,n,r,o,i){e=+e,t=+t,n=+n,i=!!i;var a=n*Math.cos(r),s=n*Math.sin(r),l=e+a,c=t+s,d=1^i,f=i?r-o:o-r;if(n<0)throw new Error("negative radius: "+n);this._x1===null?this._+="M"+l+","+c:(Math.abs(this._x1-l)>jn||Math.abs(this._y1-c)>jn)&&(this._+="L"+l+","+c),n&&(f<0&&(f=f%ml+ml),f>qP?this._+="A"+n+","+n+",0,1,"+d+","+(e-a)+","+(t-s)+"A"+n+","+n+",0,1,"+d+","+(this._x1=l)+","+(this._y1=c):f>jn&&(this._+="A"+n+","+n+",0,"+ +(f>=hl)+","+d+","+(this._x1=e+n*Math.cos(o))+","+(this._y1=t+n*Math.sin(o))))},rect:function(e,t,n,r){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};function hr(e){return function(){return e}}function Ym(e){this._context=e}Ym.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function YP(e){return new Ym(e)}function Km(e){return e[0]}function Xm(e){return e[1]}function KP(){var e=Km,t=Xm,n=hr(!0),r=null,o=YP,i=null;function a(s){var l,c=s.length,d,f=!1,p;for(r==null&&(i=o(p=gl())),l=0;l<=c;++l)!(l<c&&n(d=s[l],l,s))===f&&((f=!f)?i.lineStart():i.lineEnd()),f&&i.point(+e(d,l,s),+t(d,l,s));if(p)return i=null,p+""||null}return a.x=function(s){return arguments.length?(e=typeof s=="function"?s:hr(+s),a):e},a.y=function(s){return arguments.length?(t=typeof s=="function"?s:hr(+s),a):t},a.defined=function(s){return arguments.length?(n=typeof s=="function"?s:hr(!!s),a):n},a.curve=function(s){return arguments.length?(o=s,r!=null&&(i=o(r)),a):o},a.context=function(s){return arguments.length?(s==null?r=i=null:i=o(r=s),a):r},a}var XP=Array.prototype.slice;function RP(e){return e.source}function ZP(e){return e.target}function QP(e){var t=RP,n=ZP,r=Km,o=Xm,i=null;function a(){var s,l=XP.call(arguments),c=t.apply(this,l),d=n.apply(this,l);if(i||(i=s=gl()),e(i,+r.apply(this,(l[0]=c,l)),+o.apply(this,l),+r.apply(this,(l[0]=d,l)),+o.apply(this,l)),s)return i=null,s+""||null}return a.source=function(s){return arguments.length?(t=s,a):t},a.target=function(s){return arguments.length?(n=s,a):n},a.x=function(s){return arguments.length?(r=typeof s=="function"?s:hr(+s),a):r},a.y=function(s){return arguments.length?(o=typeof s=="function"?s:hr(+s),a):o},a.context=function(s){return arguments.length?(i=s??null,a):i},a}function JP(e,t,n,r,o){e.moveTo(t,n),e.bezierCurveTo(t=(t+r)/2,n,t,o,r,o)}function eM(){return QP(JP)}function Rm(e,t){e(t)}function tM(e){var t=e===void 0?{}:e,n=t.x,r=t.y,o=t.defined,i=t.curve,a=KP();return n&&Rm(a.x,n),r&&Rm(a.y,r),o&&a.defined(o),i&&a.curve(i),a}var nM=["from","to","fill","className","innerRef"];function yl(){return yl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},yl.apply(this,arguments)}function rM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function Zm(e){var t=e.from,n=t===void 0?{x:0,y:0}:t,r=e.to,o=r===void 0?{x:1,y:1}:r,i=e.fill,a=i===void 0?"transparent":i,s=e.className,l=e.innerRef,c=rM(e,nM),d=n.x===o.x||n.y===o.y;return u.createElement("line",yl({ref:l,className:et("visx-line",s),x1:n.x,y1:n.y,x2:o.x,y2:o.y,fill:a,shapeRendering:d?"crispEdges":"auto"},c))}var oM=["children","data","x","y","fill","className","curve","innerRef","defined"];function bl(){return bl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},bl.apply(this,arguments)}function iM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function aM(e){var t=e.children,n=e.data,r=n===void 0?[]:n,o=e.x,i=e.y,a=e.fill,s=a===void 0?"transparent":a,l=e.className,c=e.curve,d=e.innerRef,f=e.defined,p=f===void 0?function(){return!0}:f,m=iM(e,oM),h=tM({x:o,y:i,defined:p,curve:c});return t?u.createElement(u.Fragment,null,t({path:h})):u.createElement("path",bl({ref:d,className:et("visx-linepath",l),d:h(r)||"",fill:s,strokeLinecap:"round"},m))}var sM=["className","innerRef"];function xl(){return xl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},xl.apply(this,arguments)}function lM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function cM(e){var t=e.className,n=e.innerRef,r=lM(e,sM);return u.createElement("rect",xl({ref:n,className:et("visx-bar",t)},r))}var uM=["children","className","innerRef","x","y","width","height","radius","all","top","bottom","left","right","topLeft","topRight","bottomLeft","bottomRight"];function wl(){return wl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},wl.apply(this,arguments)}function dM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function fM(e){var t=e.all,n=e.bottom,r=e.bottomLeft,o=e.bottomRight,i=e.height,a=e.left,s=e.radius,l=e.right,c=e.top,d=e.topLeft,f=e.topRight,p=e.width,m=e.x,h=e.y;f=t||c||l||f,o=t||n||l||o,r=t||n||a||r,d=t||c||a||d,s=Math.max(1,Math.min(s,Math.min(p,i)/2));var v=2*s,x=("M"+(m+s)+","+h+" h"+(p-v)+`
64
+ */(function(e){(function(){var t={}.hasOwnProperty;function n(){for(var r=[],o=0;o<arguments.length;o++){var i=arguments[o];if(i){var a=typeof i;if(a==="string"||a==="number")r.push(i);else if(Array.isArray(i)){if(i.length){var s=n.apply(null,i);s&&r.push(s)}}else if(a==="object"){if(i.toString!==Object.prototype.toString&&!i.toString.toString().includes("[native code]")){r.push(i.toString());continue}for(var l in i)t.call(i,l)&&i[l]&&r.push(l)}}}return r.join(" ")}e.exports?(n.default=n,e.exports=n):window.classNames=n})()})(Vf);var Qo=Vf.exports;const et=Qn(Qo);var I1=["top","left","transform","className","children","innerRef"];function cs(){return cs=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},cs.apply(this,arguments)}function L1(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function En(e){var t=e.top,n=t===void 0?0:t,r=e.left,o=r===void 0?0:r,i=e.transform,a=e.className,s=e.children,l=e.innerRef,c=L1(e,I1);return u.createElement("g",cs({ref:l,className:et("visx-group",a),transform:i||"translate("+o+", "+n+")"},c),s)}En.propTypes={top:ne.number,left:ne.number,transform:ne.string,className:ne.string,children:ne.node,innerRef:ne.oneOfType([ne.string,ne.func,ne.object])};const F1=Object.freeze(Object.defineProperty({__proto__:null,Group:En},Symbol.toStringTag,{value:"Module"}));var j1=qf;function qf(e,t,n){e instanceof RegExp&&(e=Yf(e,n)),t instanceof RegExp&&(t=Yf(t,n));var r=Kf(e,t,n);return r&&{start:r[0],end:r[1],pre:n.slice(0,r[0]),body:n.slice(r[0]+e.length,r[1]),post:n.slice(r[1]+t.length)}}function Yf(e,t){var n=t.match(e);return n?n[0]:null}qf.range=Kf;function Kf(e,t,n){var r,o,i,a,s,l=n.indexOf(e),c=n.indexOf(t,l+1),d=l;if(l>=0&&c>0){for(r=[],i=n.length;d>=0&&!s;)d==l?(r.push(d),l=n.indexOf(e,d+1)):r.length==1?s=[r.pop(),c]:(o=r.pop(),o<i&&(i=o,a=c),c=n.indexOf(t,d+1)),d=l<c&&l>=0?l:c;r.length&&(s=[i,a])}return s}var z1=Xf;function Xf(e,t,n){e instanceof RegExp&&(e=Rf(e,n)),t instanceof RegExp&&(t=Rf(t,n));var r=Zf(e,t,n);return r&&{start:r[0],end:r[1],pre:n.slice(0,r[0]),body:n.slice(r[0]+e.length,r[1]),post:n.slice(r[1]+t.length)}}function Rf(e,t){var n=t.match(e);return n?n[0]:null}Xf.range=Zf;function Zf(e,t,n){var r,o,i,a,s,l=n.indexOf(e),c=n.indexOf(t,l+1),d=l;if(l>=0&&c>0){if(e===t)return[l,c];for(r=[],i=n.length;d>=0&&!s;)d==l?(r.push(d),l=n.indexOf(e,d+1)):r.length==1?s=[r.pop(),c]:(o=r.pop(),o<i&&(i=o,a=c),c=n.indexOf(t,d+1)),d=l<c&&l>=0?l:c;r.length&&(s=[i,a])}return s}var W1=z1,B1=Qf;function Qf(e,t,n){var r=e;return U1(e,t).reduce(function(o,i){return o.replace(i.functionIdentifier+"("+i.matches.body+")",H1(i.matches.body,i.functionIdentifier,n,r,t))},e)}function U1(e,t){var n=[],r=typeof t=="string"?new RegExp("\\b("+t+")\\("):t;do{var o=r.exec(e);if(!o)return n;if(o[1]===void 0)throw new Error("Missing the first couple of parenthesis to get the function identifier in "+t);var i=o[1],a=o.index,s=W1("(",")",e.substring(a));if(!s||s.start!==o[0].length-1)throw new SyntaxError(i+"(): missing closing ')' in the value '"+e+"'");n.push({matches:s,functionIdentifier:i}),e=s.post}while(r.test(e));return n}function H1(e,t,n,r,o){return n(Qf(e,o,n),t,r)}var Ve=function(e){this.value=e};Ve.math={isDegree:!0,acos:function(e){return Ve.math.isDegree?180/Math.PI*Math.acos(e):Math.acos(e)},add:function(e,t){return e+t},asin:function(e){return Ve.math.isDegree?180/Math.PI*Math.asin(e):Math.asin(e)},atan:function(e){return Ve.math.isDegree?180/Math.PI*Math.atan(e):Math.atan(e)},acosh:function(e){return Math.log(e+Math.sqrt(e*e-1))},asinh:function(e){return Math.log(e+Math.sqrt(e*e+1))},atanh:function(e){return Math.log((1+e)/(1-e))},C:function(e,t){var n=1,r=e-t,o=t;o<r&&(o=r,r=t);for(var i=o+1;i<=e;i++)n*=i;return n/Ve.math.fact(r)},changeSign:function(e){return-e},cos:function(e){return Ve.math.isDegree&&(e=Ve.math.toRadian(e)),Math.cos(e)},cosh:function(e){return(Math.pow(Math.E,e)+Math.pow(Math.E,-1*e))/2},div:function(e,t){return e/t},fact:function(e){if(e%1!==0)return"NaN";for(var t=1,n=2;n<=e;n++)t*=n;return t},inverse:function(e){return 1/e},log:function(e){return Math.log(e)/Math.log(10)},mod:function(e,t){return e%t},mul:function(e,t){return e*t},P:function(e,t){for(var n=1,r=Math.floor(e)-Math.floor(t)+1;r<=Math.floor(e);r++)n*=r;return n},Pi:function(e,t,n){for(var r=1,o=e;o<=t;o++)r*=Number(n.postfixEval({n:o}));return r},pow10x:function(e){for(var t=1;e--;)t*=10;return t},sigma:function(e,t,n){for(var r=0,o=e;o<=t;o++)r+=Number(n.postfixEval({n:o}));return r},sin:function(e){return Ve.math.isDegree&&(e=Ve.math.toRadian(e)),Math.sin(e)},sinh:function(e){return(Math.pow(Math.E,e)-Math.pow(Math.E,-1*e))/2},sub:function(e,t){return e-t},tan:function(e){return Ve.math.isDegree&&(e=Ve.math.toRadian(e)),Math.tan(e)},tanh:function(e){return Ve.sinha(e)/Ve.cosha(e)},toRadian:function(e){return e*Math.PI/180},and:function(e,t){return e&t}},Ve.Exception=function(e){this.message=e};var G1=Ve,ge=G1;function qe(e,t){for(var n=0;n<e.length;n++)e[n]+=t;return e}for(var on=[{token:"sin",show:"sin",type:0,value:ge.math.sin},{token:"cos",show:"cos",type:0,value:ge.math.cos},{token:"tan",show:"tan",type:0,value:ge.math.tan},{token:"pi",show:"&pi;",type:3,value:"PI"},{token:"(",show:"(",type:4,value:"("},{token:")",show:")",type:5,value:")"},{token:"P",show:"P",type:10,value:ge.math.P},{token:"C",show:"C",type:10,value:ge.math.C},{token:" ",show:" ",type:14,value:" ".anchor},{token:"asin",show:"asin",type:0,value:ge.math.asin},{token:"acos",show:"acos",type:0,value:ge.math.acos},{token:"atan",show:"atan",type:0,value:ge.math.atan},{token:"7",show:"7",type:1,value:"7"},{token:"8",show:"8",type:1,value:"8"},{token:"9",show:"9",type:1,value:"9"},{token:"int",show:"Int",type:0,value:Math.floor},{token:"cosh",show:"cosh",type:0,value:ge.math.cosh},{token:"acosh",show:"acosh",type:0,value:ge.math.acosh},{token:"ln",show:" ln",type:0,value:Math.log},{token:"^",show:"^",type:10,value:Math.pow},{token:"root",show:"root",type:0,value:Math.sqrt},{token:"4",show:"4",type:1,value:"4"},{token:"5",show:"5",type:1,value:"5"},{token:"6",show:"6",type:1,value:"6"},{token:"/",show:"&divide;",type:2,value:ge.math.div},{token:"!",show:"!",type:7,value:ge.math.fact},{token:"tanh",show:"tanh",type:0,value:ge.math.tanh},{token:"atanh",show:"atanh",type:0,value:ge.math.atanh},{token:"Mod",show:" Mod ",type:2,value:ge.math.mod},{token:"1",show:"1",type:1,value:"1"},{token:"2",show:"2",type:1,value:"2"},{token:"3",show:"3",type:1,value:"3"},{token:"*",show:"&times;",type:2,value:ge.math.mul},{token:"sinh",show:"sinh",type:0,value:ge.math.sinh},{token:"asinh",show:"asinh",type:0,value:ge.math.asinh},{token:"e",show:"e",type:3,value:"E"},{token:"log",show:" log",type:0,value:ge.math.log},{token:"0",show:"0",type:1,value:"0"},{token:".",show:".",type:6,value:"."},{token:"+",show:"+",type:9,value:ge.math.add},{token:"-",show:"-",type:9,value:ge.math.sub},{token:",",show:",",type:11,value:","},{token:"Sigma",show:"&Sigma;",type:12,value:ge.math.sigma},{token:"n",show:"n",type:13,value:"n"},{token:"Pi",show:"&Pi;",type:12,value:ge.math.Pi},{token:"pow",show:"pow",type:8,value:Math.pow,numberOfArguments:2},{token:"&",show:"&",type:9,value:ge.math.and}],us={0:11,1:0,2:3,3:0,4:0,5:0,6:0,7:11,8:11,9:1,10:10,11:0,12:11,13:0,14:-1,15:11},Jo=0;Jo<on.length;Jo++)on[Jo].precedence=us[on[Jo].type];var Pt={0:!0,1:!0,3:!0,4:!0,6:!0,8:!0,9:!0,12:!0,13:!0,14:!0,15:!0},er={0:!0,1:!0,2:!0,3:!0,4:!0,5:!0,6:!0,7:!0,8:!0,9:!0,10:!0,11:!0,12:!0,13:!0,15:!0},V1={0:!0,3:!0,4:!0,8:!0,12:!0,13:!0,15:!0},vt={},Dr={0:!0,1:!0,3:!0,4:!0,6:!0,8:!0,12:!0,13:!0,15:!0},q1={1:!0},Ye=[[],["1","2","3","7","8","9","4","5","6","+","-","*","/","(",")","^","!","P","C","e","0",".",",","n"," ","&"],["pi","ln","Pi"],["sin","cos","tan","Del","int","Mod","log","pow"],["asin","acos","atan","cosh","root","tanh","sinh"],["acosh","atanh","asinh","Sigma"]];function Y1(e,t,n,r){for(var o=0;o<r;o++)if(e[n+o]!==t[o])return!1;return!0}ge.tokenTypes={FUNCTION_WITH_ONE_ARG:0,NUMBER:1,BINARY_OPERATOR_HIGH_PRECENDENCE:2,CONSTANT:3,OPENING_PARENTHESIS:4,CLOSING_PARENTHESIS:5,DECIMAL:6,POSTFIX_FUNCTION_WITH_ONE_ARG:7,FUNCTION_WITH_N_ARGS:8,BINARY_OPERATOR_LOW_PRECENDENCE:9,BINARY_OPERATOR_PERMUTATION:10,COMMA:11,EVALUATED_FUNCTION:12,EVALUATED_FUNCTION_PARAMETER:13,SPACE:14},ge.addToken=function(e){for(var t=0;t<e.length;t++){var n=e[t].token.length,r=-1;e[t].type===ge.tokenTypes.FUNCTION_WITH_N_ARGS&&e[t].numberOfArguments===void 0&&(e[t].numberOfArguments=2),Ye[n]=Ye[n]||[];for(var o=0;o<Ye[n].length;o++)if(e[t].token===Ye[n][o]){r=Jf(Ye[n][o],on);break}r===-1?(on.push(e[t]),e[t].precedence=us[e[t].type],Ye.length<=e[t].token.length&&(Ye[e[t].token.length]=[]),Ye[e[t].token.length].push(e[t].token)):(on[r]=e[t],e[t].precedence=us[e[t].type])}};function Jf(e,t){for(var n=0;n<t.length;n++)if(t[n].token===e)return n;return-1}function K1(e){for(var t=[],n=e.length,r,o,i,a=0;a<n;a++)if(!(a<n-1&&e[a]===" "&&e[a+1]===" ")){for(r="",o=e.length-a>Ye.length-2?Ye.length-1:e.length-a;o>0;o--)if(Ye[o]!==void 0)for(i=0;i<Ye[o].length;i++)Y1(e,Ye[o][i],a,o)&&(r=Ye[o][i],i=Ye[o].length,o=0);if(a+=r.length-1,r==="")throw new ge.Exception("Can't understand after "+e.slice(a));t.push(on[Jf(r,on)])}return t}var X1={value:ge.math.changeSign,type:0,pre:21,show:"-"},ei={value:")",show:")",type:5,pre:0},Ir={value:"(",type:4,pre:0,show:"("};ge.lex=function(e,t){var n=[Ir],r=[],o=e,i=Pt,a=0,s=vt,l="",c;typeof t<"u"&&ge.addToken(t);var d={},f=K1(o);for(c=0;c<f.length;c++){var p=f[c];if(p.type===14){if(c>0&&c<f.length-1&&f[c+1].type===1&&(f[c-1].type===1||f[c-1].type===6))throw new ge.Exception("Unexpected Space");continue}var m=p.token,h=p.type,v=p.value,x=p.precedence,y=p.show,b=n[n.length-1],$;for($=r.length;$--&&r[$]===0;)if([0,2,3,4,5,9,11,12,13].indexOf(h)!==-1){if(i[h]!==!0)throw new ge.Exception(m+" is not allowed after "+l);n.push(ei),i=er,s=Dr,r.pop()}if(i[h]!==!0)throw new ge.Exception(m+" is not allowed after "+l);if(s[h]===!0&&(h=2,v=ge.math.mul,y="&times;",x=3,c=c-1),d={value:v,type:h,pre:x,show:y,numberOfArguments:p.numberOfArguments},h===0)i=Pt,s=vt,qe(r,2),n.push(d),f[c+1].type!==4&&(n.push(Ir),r.push(2));else if(h===1)b.type===1?(b.value+=v,qe(r,1)):n.push(d),i=er,s=V1;else if(h===2)i=Pt,s=vt,qe(r,2),n.push(d);else if(h===3)n.push(d),i=er,s=Dr;else if(h===4)qe(r,1),a++,i=Pt,s=vt,n.push(d);else if(h===5){if(!a)throw new ge.Exception("Closing parenthesis are more than opening one, wait What!!!");a--,i=er,s=Dr,n.push(d),qe(r,1)}else if(h===6){if(b.hasDec)throw new ge.Exception("Two decimals are not allowed in one number");b.type!==1&&(b={value:0,type:1,pre:0},n.push(b)),i=q1,qe(r,1),s=vt,b.value+=v,b.hasDec=!0}else h===7&&(i=er,s=Dr,qe(r,1),n.push(d));h===8?(i=Pt,s=vt,qe(r,p.numberOfArguments+2),n.push(d),f[c+1].type!==4&&(n.push(Ir),r.push(p.numberOfArguments+2))):h===9?(b.type===9?b.value===ge.math.add?(b.value=v,b.show=y,qe(r,1)):b.value===ge.math.sub&&y==="-"&&(b.value=ge.math.add,b.show="+",qe(r,1)):b.type!==5&&b.type!==7&&b.type!==1&&b.type!==3&&b.type!==13?m==="-"&&(i=Pt,s=vt,qe(r,2).push(2),n.push(X1),n.push(Ir)):(n.push(d),qe(r,2)),i=Pt,s=vt):h===10?(i=Pt,s=vt,qe(r,2),n.push(d)):h===11?(i=Pt,s=vt,n.push(d)):h===12?(i=Pt,s=vt,qe(r,6),n.push(d),f[c+1].type!==4&&(n.push(Ir),r.push(6))):h===13&&(i=er,s=Dr,n.push(d)),qe(r,-1),l=m}for($=r.length;$--;)n.push(ei);if(i[5]!==!0)throw new ge.Exception("complete the expression");for(;a--;)n.push(ei);return n.push(ei),new ge(n)};var R1=ge,ds=R1;ds.prototype.toPostfix=function(){for(var e=[],t,n,r,o,i,a=[{value:"(",type:4,pre:0}],s=this.value,l=1;l<s.length;l++)if(s[l].type===1||s[l].type===3||s[l].type===13)s[l].type===1&&(s[l].value=Number(s[l].value)),e.push(s[l]);else if(s[l].type===4)a.push(s[l]);else if(s[l].type===5)for(;(n=a.pop()).type!==4;)e.push(n);else if(s[l].type===11){for(;(n=a.pop()).type!==4;)e.push(n);a.push(n)}else{t=s[l],o=t.pre,i=a[a.length-1],r=i.pre;var c=i.value=="Math.pow"&&t.value=="Math.pow";if(o>r)a.push(t);else{for(;r>=o&&!c||c&&o<r;)n=a.pop(),i=a[a.length-1],e.push(n),r=i.pre,c=t.value=="Math.pow"&&i.value=="Math.pow";a.push(t)}}return new ds(e)};var Z1=ds,Lr=Z1;Lr.prototype.postfixEval=function(e){e=e||{},e.PI=Math.PI,e.E=Math.E;for(var t=[],n,r,o,i=this.value,a=typeof e.n<"u",s=0;s<i.length;s++)if(i[s].type===1)t.push({value:i[s].value,type:1});else if(i[s].type===3)t.push({value:e[i[s].value],type:1});else if(i[s].type===0)typeof t[t.length-1].type>"u"?t[t.length-1].value.push(i[s]):t[t.length-1].value=i[s].value(t[t.length-1].value);else if(i[s].type===7)typeof t[t.length-1].type>"u"?t[t.length-1].value.push(i[s]):t[t.length-1].value=i[s].value(t[t.length-1].value);else if(i[s].type===8){for(var l=[],c=0;c<i[s].numberOfArguments;c++)l.push(t.pop().value);t.push({type:1,value:i[s].value.apply(i[s],l.reverse())})}else i[s].type===10?(n=t.pop(),r=t.pop(),typeof r.type>"u"?(r.value=r.concat(n),r.value.push(i[s]),t.push(r)):typeof n.type>"u"?(n.unshift(r),n.push(i[s]),t.push(n)):t.push({type:1,value:i[s].value(r.value,n.value)})):i[s].type===2||i[s].type===9?(n=t.pop(),r=t.pop(),typeof r.type>"u"?(r=r.concat(n),r.push(i[s]),t.push(r)):typeof n.type>"u"?(n.unshift(r),n.push(i[s]),t.push(n)):t.push({type:1,value:i[s].value(r.value,n.value)})):i[s].type===12?(n=t.pop(),typeof n.type<"u"&&(n=[n]),r=t.pop(),o=t.pop(),t.push({type:1,value:i[s].value(o.value,r.value,new Lr(n))})):i[s].type===13&&(a?t.push({value:e[i[s].value],type:3}):t.push([i[s]]));if(t.length>1)throw new Lr.Exception("Uncaught Syntax error");return t[0].value>1e15?"Infinity":parseFloat(t[0].value.toFixed(15))},Lr.eval=function(e,t,n){return typeof t>"u"?this.lex(e).toPostfix().postfixEval():typeof n>"u"?typeof t.length<"u"?this.lex(e,t).toPostfix().postfixEval():this.lex(e).toPostfix().postfixEval(t):this.lex(e,t).toPostfix().postfixEval(n)};var Q1=Lr,ep=Q1;ep.prototype.formulaEval=function(){for(var e,t,n,r=[],o=this.value,i=0;i<o.length;i++)o[i].type===1||o[i].type===3?r.push({value:o[i].type===3?o[i].show:o[i].value,type:1}):o[i].type===13?r.push({value:o[i].show,type:1}):o[i].type===0?r[r.length-1]={value:o[i].show+(o[i].show!="-"?"(":"")+r[r.length-1].value+(o[i].show!="-"?")":""),type:0}:o[i].type===7?r[r.length-1]={value:(r[r.length-1].type!=1?"(":"")+r[r.length-1].value+(r[r.length-1].type!=1?")":"")+o[i].show,type:7}:o[i].type===10?(e=r.pop(),t=r.pop(),o[i].show==="P"||o[i].show==="C"?r.push({value:"<sup>"+t.value+"</sup>"+o[i].show+"<sub>"+e.value+"</sub>",type:10}):r.push({value:(t.type!=1?"(":"")+t.value+(t.type!=1?")":"")+"<sup>"+e.value+"</sup>",type:1})):o[i].type===2||o[i].type===9?(e=r.pop(),t=r.pop(),r.push({value:(t.type!=1?"(":"")+t.value+(t.type!=1?")":"")+o[i].show+(e.type!=1?"(":"")+e.value+(e.type!=1?")":""),type:o[i].type})):o[i].type===12&&(e=r.pop(),t=r.pop(),n=r.pop(),r.push({value:o[i].show+"("+n.value+","+t.value+","+e.value+")",type:12}));return r[0].value};var J1=ep,e$=j1,t$=B1,n$=J1,r$=100,o$=/(\+|\-|\*|\\|[^a-z]|)(\s*)(\()/g,fs,i$=a$;function a$(e,t){fs=0,t=Math.pow(10,t===void 0?5:t),e=e.replace(/\n+/g," ");function n(o,i,a){if(fs++>r$)throw fs=0,new Error("Call stack overflow for "+a);if(o==="")throw new Error(i+"(): '"+a+"' must contain a non-whitespace string");o=r(o,a);var s=s$(o);if(s.length>1||o.indexOf("var(")>-1)return i+"("+o+")";var l=s[0]||"";l==="%"&&(o=o.replace(/\b[0-9\.]+%/g,function(f){return parseFloat(f.slice(0,-1))*.01}));var c=o.replace(new RegExp(l,"gi"),""),d;try{d=n$.eval(c)}catch{return i+"("+o+")"}return l==="%"&&(d*=100),(i.length||l==="%")&&(d=Math.round(d*t)/t),d+=l,d}function r(o,i){o=o.replace(/((?:\-[a-z]+\-)?calc)/g,"");for(var a="",s=o,l;l=o$.exec(s);){l[0].index>0&&(a+=s.substring(0,l[0].index));var c=e$("(",")",s.substring([0].index));if(c.body==="")throw new Error("'"+o+"' must contain a non-whitespace string");var d=n(c.body,"",i);a+=c.pre+d,s=c.post}return a+s}return t$(e,/((?:\-[a-z]+\-)?calc)\(/,n)}function s$(e){for(var t=[],n=[],r=/[\.0-9]([%a-z]+)/gi,o=r.exec(e);o;)!o||!o[1]||(n.indexOf(o[1].toLowerCase())===-1&&(t.push(o[1]),n.push(o[1].toLowerCase())),o=r.exec(e));return t}const ps=Qn(i$);var l$=typeof Ar=="object"&&Ar&&Ar.Object===Object&&Ar,c$=l$,u$=c$,d$=typeof self=="object"&&self&&self.Object===Object&&self,f$=u$||d$||Function("return this")(),ti=f$,p$=ti,h$=p$.Symbol,tp=h$,np=tp,rp=Object.prototype,m$=rp.hasOwnProperty,v$=rp.toString,Fr=np?np.toStringTag:void 0;function g$(e){var t=m$.call(e,Fr),n=e[Fr];try{e[Fr]=void 0;var r=!0}catch{}var o=v$.call(e);return r&&(t?e[Fr]=n:delete e[Fr]),o}var y$=g$,b$=Object.prototype,x$=b$.toString;function w$(e){return x$.call(e)}var $$=w$,op=tp,C$=y$,S$=$$,E$="[object Null]",T$="[object Undefined]",ip=op?op.toStringTag:void 0;function P$(e){return e==null?e===void 0?T$:E$:ip&&ip in Object(e)?C$(e):S$(e)}var ap=P$;function M$(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var ni=M$,k$=ap,O$=ni,_$="[object AsyncFunction]",N$="[object Function]",A$="[object GeneratorFunction]",D$="[object Proxy]";function I$(e){if(!O$(e))return!1;var t=k$(e);return t==N$||t==A$||t==_$||t==D$}var L$=I$,F$=ti,j$=F$["__core-js_shared__"],z$=j$,hs=z$,sp=function(){var e=/[^.]+$/.exec(hs&&hs.keys&&hs.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function W$(e){return!!sp&&sp in e}var B$=W$,U$=Function.prototype,H$=U$.toString;function G$(e){if(e!=null){try{return H$.call(e)}catch{}try{return e+""}catch{}}return""}var V$=G$,q$=L$,Y$=B$,K$=ni,X$=V$,R$=/[\\^$.*+?()[\]{}|]/g,Z$=/^\[object .+?Constructor\]$/,Q$=Function.prototype,J$=Object.prototype,eC=Q$.toString,tC=J$.hasOwnProperty,nC=RegExp("^"+eC.call(tC).replace(R$,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function rC(e){if(!K$(e)||Y$(e))return!1;var t=q$(e)?nC:Z$;return t.test(X$(e))}var oC=rC;function iC(e,t){return e==null?void 0:e[t]}var aC=iC,sC=oC,lC=aC;function cC(e,t){var n=lC(e,t);return sC(n)?n:void 0}var lp=cC,uC=lp,dC=uC(Object,"create"),ri=dC,cp=ri;function fC(){this.__data__=cp?cp(null):{},this.size=0}var pC=fC;function hC(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var mC=hC,vC=ri,gC="__lodash_hash_undefined__",yC=Object.prototype,bC=yC.hasOwnProperty;function xC(e){var t=this.__data__;if(vC){var n=t[e];return n===gC?void 0:n}return bC.call(t,e)?t[e]:void 0}var wC=xC,$C=ri,CC=Object.prototype,SC=CC.hasOwnProperty;function EC(e){var t=this.__data__;return $C?t[e]!==void 0:SC.call(t,e)}var TC=EC,PC=ri,MC="__lodash_hash_undefined__";function kC(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=PC&&t===void 0?MC:t,this}var OC=kC,_C=pC,NC=mC,AC=wC,DC=TC,IC=OC;function tr(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}tr.prototype.clear=_C,tr.prototype.delete=NC,tr.prototype.get=AC,tr.prototype.has=DC,tr.prototype.set=IC;var LC=tr;function FC(){this.__data__=[],this.size=0}var jC=FC;function zC(e,t){return e===t||e!==e&&t!==t}var WC=zC,BC=WC;function UC(e,t){for(var n=e.length;n--;)if(BC(e[n][0],t))return n;return-1}var oi=UC,HC=oi,GC=Array.prototype,VC=GC.splice;function qC(e){var t=this.__data__,n=HC(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():VC.call(t,n,1),--this.size,!0}var YC=qC,KC=oi;function XC(e){var t=this.__data__,n=KC(t,e);return n<0?void 0:t[n][1]}var RC=XC,ZC=oi;function QC(e){return ZC(this.__data__,e)>-1}var JC=QC,eS=oi;function tS(e,t){var n=this.__data__,r=eS(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}var nS=tS,rS=jC,oS=YC,iS=RC,aS=JC,sS=nS;function nr(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}nr.prototype.clear=rS,nr.prototype.delete=oS,nr.prototype.get=iS,nr.prototype.has=aS,nr.prototype.set=sS;var lS=nr,cS=lp,uS=ti,dS=cS(uS,"Map"),fS=dS,up=LC,pS=lS,hS=fS;function mS(){this.size=0,this.__data__={hash:new up,map:new(hS||pS),string:new up}}var vS=mS;function gS(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var yS=gS,bS=yS;function xS(e,t){var n=e.__data__;return bS(t)?n[typeof t=="string"?"string":"hash"]:n.map}var ii=xS,wS=ii;function $S(e){var t=wS(this,e).delete(e);return this.size-=t?1:0,t}var CS=$S,SS=ii;function ES(e){return SS(this,e).get(e)}var TS=ES,PS=ii;function MS(e){return PS(this,e).has(e)}var kS=MS,OS=ii;function _S(e,t){var n=OS(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}var NS=_S,AS=vS,DS=CS,IS=TS,LS=kS,FS=NS;function rr(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}rr.prototype.clear=AS,rr.prototype.delete=DS,rr.prototype.get=IS,rr.prototype.has=LS,rr.prototype.set=FS;var jS=rr,dp=jS,zS="Expected a function";function ms(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(zS);var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=e.apply(this,r);return n.cache=i.set(o,a)||i,a};return n.cache=new(ms.Cache||dp),n}ms.Cache=dp;var WS=ms;const BS=Qn(WS);var fp="__react_svg_text_measurement_id";function US(e,t){try{var n=document.getElementById(fp);if(!n){var r=document.createElementNS("http://www.w3.org/2000/svg","svg");r.setAttribute("aria-hidden","true"),r.style.width="0",r.style.height="0",r.style.position="absolute",r.style.top="-100%",r.style.left="-100%",n=document.createElementNS("http://www.w3.org/2000/svg","text"),n.setAttribute("id",fp),r.appendChild(n),document.body.appendChild(r)}return Object.assign(n.style,t),n.textContent=e,n.getComputedTextLength()}catch{return null}}const pp=BS(US,function(e,t){return e+"_"+JSON.stringify(t)});var HS=["verticalAnchor","scaleToFit","angle","width","lineHeight","capHeight","children","style"];function GS(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function vs(e){return typeof e=="number"}function hp(e){return typeof e=="number"&&Number.isFinite(e)||typeof e=="string"}function VS(e){var t=e.verticalAnchor,n=t===void 0?"end":t,r=e.scaleToFit,o=r===void 0?!1:r,i=e.angle,a=e.width,s=e.lineHeight,l=s===void 0?"1em":s,c=e.capHeight,d=c===void 0?"0.71em":c,f=e.children,p=e.style,m=GS(e,HS),h=m.x,v=h===void 0?0:h,x=m.y,y=x===void 0?0:x,b=!hp(v)||!hp(y),$=u.useMemo(function(){var _=f==null?[]:f.toString().split(/(?:(?!\u00A0+)\s+)/);return{wordsWithWidth:_.map(function(j){return{word:j,wordWidth:pp(j,p)||0}}),spaceWidth:pp(" ",p)||0}},[f,p]),S=$.wordsWithWidth,w=$.spaceWidth,T=u.useMemo(function(){return b?[]:a||o?S.reduce(function(_,j){var F=j.word,V=j.wordWidth,R=_[_.length-1];if(R&&(a==null||o||(R.width||0)+V+w<a))R.words.push(F),R.width=R.width||0,R.width+=V+w;else{var X={words:[F],width:V};_.push(X)}return _},[]):[{words:f==null?[]:f.toString().split(/(?:(?!\u00A0+)\s+)/)}]},[b,a,o,f,S,w]),O=u.useMemo(function(){var _=b?"":ps(n==="start"?"calc("+d+")":n==="middle"?"calc("+(T.length-1)/2+" * -"+l+" + ("+d+" / 2))":"calc("+(T.length-1)+" * -"+l+")");return _},[b,n,d,T.length,l]),P=u.useMemo(function(){var _=[];if(b)return"";if(vs(v)&&vs(y)&&vs(a)&&o&&T.length>0){var j=T[0].width||1,F=o==="shrink-only"?Math.min(a/j,1):a/j,V=F,R=v-F*v,X=y-V*y;_.push("matrix("+F+", 0, 0, "+V+", "+R+", "+X+")")}return i&&_.push("rotate("+i+", "+v+", "+y+")"),_.length>0?_.join(" "):""},[b,v,y,a,o,T,i]);return{wordsByLines:T,startDy:O,transform:P}}var qS=["dx","dy","textAnchor","innerRef","innerTextRef","verticalAnchor","angle","lineHeight","scaleToFit","capHeight","width"];function gs(){return gs=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},gs.apply(this,arguments)}function YS(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}var KS={overflow:"visible"};function ys(e){var t=e.dx,n=t===void 0?0:t,r=e.dy,o=r===void 0?0:r,i=e.textAnchor,a=i===void 0?"start":i,s=e.innerRef,l=e.innerTextRef;e.verticalAnchor,e.angle;var c=e.lineHeight,d=c===void 0?"1em":c;e.scaleToFit,e.capHeight,e.width;var f=YS(e,qS),p=f.x,m=p===void 0?0:p,h=f.fontSize,v=VS(e),x=v.wordsByLines,y=v.startDy,b=v.transform;return u.createElement("svg",{ref:s,x:n,y:o,fontSize:h,style:KS},x.length>0?u.createElement("text",gs({ref:l,transform:b},f,{textAnchor:a}),x.map(function($,S){return u.createElement("tspan",{key:S,x:m,dy:S===0?y:d},$.words.join(" "))})):null)}function bs(e,t,n){var r,o,i,a,s;t==null&&(t=100);function l(){var d=Date.now()-a;d<t&&d>=0?r=setTimeout(l,t-d):(r=null,n||(s=e.apply(i,o),i=o=null))}var c=function(){i=this,o=arguments,a=Date.now();var d=n&&!r;return r||(r=setTimeout(l,t)),d&&(s=e.apply(i,o),i=o=null),s};return c.clear=function(){r&&(clearTimeout(r),r=null)},c.flush=function(){r&&(s=e.apply(i,o),i=o=null,clearTimeout(r),r=null)},c}bs.debounce=bs;var XS=bs;const mp=Qn(XS);function RS(e){let{debounce:t,scroll:n,polyfill:r,offsetSize:o}=e===void 0?{debounce:0,scroll:!1,offsetSize:!1}:e;const i=r||(typeof window>"u"?class{}:window.ResizeObserver);if(!i)throw new Error("This browser does not support ResizeObserver out of the box. See: https://github.com/react-spring/react-use-measure/#resize-observer-polyfills");const[a,s]=u.useState({left:0,top:0,width:0,height:0,bottom:0,right:0,x:0,y:0}),l=u.useRef({element:null,scrollContainers:null,resizeObserver:null,lastBounds:a}),c=t?typeof t=="number"?t:t.scroll:null,d=t?typeof t=="number"?t:t.resize:null,f=u.useRef(!1);u.useEffect(()=>(f.current=!0,()=>void(f.current=!1)));const[p,m,h]=u.useMemo(()=>{const b=()=>{if(!l.current.element)return;const{left:$,top:S,width:w,height:T,bottom:O,right:P,x:_,y:j}=l.current.element.getBoundingClientRect(),F={left:$,top:S,width:w,height:T,bottom:O,right:P,x:_,y:j};l.current.element instanceof HTMLElement&&o&&(F.height=l.current.element.offsetHeight,F.width=l.current.element.offsetWidth),Object.freeze(F),f.current&&!eE(l.current.lastBounds,F)&&s(l.current.lastBounds=F)};return[b,d?mp(b,d):b,c?mp(b,c):b]},[s,o,c,d]);function v(){l.current.scrollContainers&&(l.current.scrollContainers.forEach(b=>b.removeEventListener("scroll",h,!0)),l.current.scrollContainers=null),l.current.resizeObserver&&(l.current.resizeObserver.disconnect(),l.current.resizeObserver=null)}function x(){l.current.element&&(l.current.resizeObserver=new i(h),l.current.resizeObserver.observe(l.current.element),n&&l.current.scrollContainers&&l.current.scrollContainers.forEach(b=>b.addEventListener("scroll",h,{capture:!0,passive:!0})))}const y=b=>{!b||b===l.current.element||(v(),l.current.element=b,l.current.scrollContainers=vp(b),x())};return QS(h,!!n),ZS(m),u.useEffect(()=>{v(),x()},[n,h,m]),u.useEffect(()=>v,[]),[y,a,p]}function ZS(e){u.useEffect(()=>{const t=e;return window.addEventListener("resize",t),()=>void window.removeEventListener("resize",t)},[e])}function QS(e,t){u.useEffect(()=>{if(t){const n=e;return window.addEventListener("scroll",n,{capture:!0,passive:!0}),()=>void window.removeEventListener("scroll",n,!0)}},[e,t])}function vp(e){const t=[];if(!e||e===document.body)return t;const{overflow:n,overflowX:r,overflowY:o}=window.getComputedStyle(e);return[n,r,o].some(i=>i==="auto"||i==="scroll")&&t.push(e),[...t,...vp(e.parentElement)]}const JS=["x","y","top","bottom","left","right","width","height"],eE=(e,t)=>JS.every(n=>e[n]===t[n]);var an=function(){function e(n){var r=n.x,o=r===void 0?0:r,i=n.y,a=i===void 0?0:i;this.x=0,this.y=0,this.x=o,this.y=a}var t=e.prototype;return t.value=function(){return{x:this.x,y:this.y}},t.toArray=function(){return[this.x,this.y]},e}();function tE(e,t){return new an({x:e.x+t.x,y:e.y+t.y})}function nE(e,t){return new an({x:e.x-t.x,y:e.y-t.y})}const gp=Jn(Object.freeze(Object.defineProperty({__proto__:null,Point:an,subtractPoints:nE,sumPoints:tE},Symbol.toStringTag,{value:"Module"})));function rE(e){return!!e&&e instanceof Element}function oE(e){return!!e&&(e instanceof SVGElement||"ownerSVGElement"in e)}function iE(e){return!!e&&"createSVGPoint"in e}function aE(e){return!!e&&"getScreenCTM"in e}function sE(e){return!!e&&"changedTouches"in e}function lE(e){return!!e&&"clientX"in e}function cE(e){return!!e&&(e instanceof Event||"nativeEvent"in e&&e.nativeEvent instanceof Event)}function jr(){return jr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},jr.apply(this,arguments)}var xs={x:0,y:0};function uE(e){if(!e)return jr({},xs);if(sE(e))return e.changedTouches.length>0?{x:e.changedTouches[0].clientX,y:e.changedTouches[0].clientY}:jr({},xs);if(lE(e))return{x:e.clientX,y:e.clientY};var t=e==null?void 0:e.target,n=t&&"getBoundingClientRect"in t?t.getBoundingClientRect():null;return n?{x:n.x+n.width/2,y:n.y+n.height/2}:jr({},xs)}function yp(e,t){if(!e||!t)return null;var n=uE(t),r=oE(e)?e.ownerSVGElement:e,o=aE(r)?r.getScreenCTM():null;if(iE(r)&&o){var i=r.createSVGPoint();return i.x=n.x,i.y=n.y,i=i.matrixTransform(o.inverse()),new an({x:i.x,y:i.y})}var a=e.getBoundingClientRect();return new an({x:n.x-a.left-e.clientLeft,y:n.y-a.top-e.clientTop})}function dE(e,t){if(rE(e)&&t)return yp(e,t);if(cE(e)){var n=e,r=n.target;if(r)return yp(r,n)}return null}function sn(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function fE(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function ws(e){let t,n,r;e.length!==2?(t=sn,n=(s,l)=>sn(e(s),l),r=(s,l)=>e(s)-l):(t=e===sn||e===fE?e:pE,n=e,r=e);function o(s,l,c=0,d=s.length){if(c<d){if(t(l,l)!==0)return d;do{const f=c+d>>>1;n(s[f],l)<0?c=f+1:d=f}while(c<d)}return c}function i(s,l,c=0,d=s.length){if(c<d){if(t(l,l)!==0)return d;do{const f=c+d>>>1;n(s[f],l)<=0?c=f+1:d=f}while(c<d)}return c}function a(s,l,c=0,d=s.length){const f=o(s,l,c,d-1);return f>c&&r(s[f-1],l)>-r(s[f],l)?f-1:f}return{left:o,center:a,right:i}}function pE(){return 0}function bp(e){return e===null?NaN:+e}function*hE(e,t){if(t===void 0)for(let n of e)n!=null&&(n=+n)>=n&&(yield n);else{let n=-1;for(let r of e)(r=t(r,++n,e))!=null&&(r=+r)>=r&&(yield r)}}const mE=ws(sn).right;ws(bp).center;const or=mE;function vE(e,t){let n=0;if(t===void 0)for(let r of e)r!=null&&(r=+r)>=r&&++n;else{let r=-1;for(let o of e)(o=t(o,++r,e))!=null&&(o=+o)>=o&&++n}return n}function ai(e,t){let n,r;if(t===void 0)for(const o of e)o!=null&&(n===void 0?o>=o&&(n=r=o):(n>o&&(n=o),r<o&&(r=o)));else{let o=-1;for(let i of e)(i=t(i,++o,e))!=null&&(n===void 0?i>=i&&(n=r=i):(n>i&&(n=i),r<i&&(r=i)))}return[n,r]}class xp extends Map{constructor(t,n=bE){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[r,o]of t)this.set(r,o)}get(t){return super.get(wp(this,t))}has(t){return super.has(wp(this,t))}set(t,n){return super.set(gE(this,t),n)}delete(t){return super.delete(yE(this,t))}}function wp({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function gE({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function yE({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function bE(e){return e!==null&&typeof e=="object"?e.valueOf():e}function xE(e){return e}function wE(e=sn){if(e===sn)return $p;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const r=e(t,n);return r||r===0?r:(e(n,n)===0)-(e(t,t)===0)}}function $p(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}var $E=Array.prototype,CE=$E.slice;function $s(e){return()=>e}const SE=Math.sqrt(50),EE=Math.sqrt(10),TE=Math.sqrt(2);function si(e,t,n){const r=(t-e)/Math.max(0,n),o=Math.floor(Math.log10(r)),i=r/Math.pow(10,o),a=i>=SE?10:i>=EE?5:i>=TE?2:1;let s,l,c;return o<0?(c=Math.pow(10,-o)/a,s=Math.round(e*c),l=Math.round(t*c),s/c<e&&++s,l/c>t&&--l,c=-c):(c=Math.pow(10,o)*a,s=Math.round(e/c),l=Math.round(t/c),s*c<e&&++s,l*c>t&&--l),l<s&&.5<=n&&n<2?si(e,t,n*2):[s,l,c]}function li(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[o,i,a]=r?si(t,e,n):si(e,t,n);if(!(i>=o))return[];const s=i-o+1,l=new Array(s);if(r)if(a<0)for(let c=0;c<s;++c)l[c]=(i-c)/-a;else for(let c=0;c<s;++c)l[c]=(i-c)*a;else if(a<0)for(let c=0;c<s;++c)l[c]=(o+c)/-a;else for(let c=0;c<s;++c)l[c]=(o+c)*a;return l}function ir(e,t,n){return t=+t,e=+e,n=+n,si(e,t,n)[2]}function Cs(e,t,n){t=+t,e=+e,n=+n;const r=t<e,o=r?ir(t,e,n):ir(e,t,n);return(r?-1:1)*(o<0?1/-o:o)}function PE(e,t,n){let r;for(;;){const o=ir(e,t,n);if(o===r||o===0||!isFinite(o))return[e,t];o>0?(e=Math.floor(e/o)*o,t=Math.ceil(t/o)*o):o<0&&(e=Math.ceil(e*o)/o,t=Math.floor(t*o)/o),r=o}}function ME(e){return Math.max(1,Math.ceil(Math.log(vE(e))/Math.LN2)+1)}function kE(){var e=xE,t=ai,n=ME;function r(o){Array.isArray(o)||(o=Array.from(o));var i,a=o.length,s,l,c=new Array(a);for(i=0;i<a;++i)c[i]=e(o[i],i,o);var d=t(c),f=d[0],p=d[1],m=n(c,f,p);if(!Array.isArray(m)){const $=p,S=+m;if(t===ai&&([f,p]=PE(f,p,S)),m=li(f,p,S),m[0]<=f&&(l=ir(f,p,S)),m[m.length-1]>=p)if($>=p&&t===ai){const w=ir(f,p,S);isFinite(w)&&(w>0?p=(Math.floor(p/w)+1)*w:w<0&&(p=(Math.ceil(p*-w)+1)/-w))}else m.pop()}for(var h=m.length,v=0,x=h;m[v]<=f;)++v;for(;m[x-1]>p;)--x;(v||x<h)&&(m=m.slice(v,x),h=x-v);var y=new Array(h+1),b;for(i=0;i<=h;++i)b=y[i]=[],b.x0=i>0?m[i-1]:f,b.x1=i<h?m[i]:p;if(isFinite(l)){if(l>0)for(i=0;i<a;++i)(s=c[i])!=null&&f<=s&&s<=p&&y[Math.min(h,Math.floor((s-f)/l))].push(o[i]);else if(l<0){for(i=0;i<a;++i)if((s=c[i])!=null&&f<=s&&s<=p){const $=Math.floor((f-s)*l);y[Math.min(h,$+(m[$]<=s))].push(o[i])}}}else for(i=0;i<a;++i)(s=c[i])!=null&&f<=s&&s<=p&&y[or(m,s,0,h)].push(o[i]);return y}return r.value=function(o){return arguments.length?(e=typeof o=="function"?o:$s(o),r):e},r.domain=function(o){return arguments.length?(t=typeof o=="function"?o:$s([o[0],o[1]]),r):t},r.thresholds=function(o){return arguments.length?(n=typeof o=="function"?o:$s(Array.isArray(o)?CE.call(o):o),r):n},r}function Ss(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let o of e)(o=t(o,++r,e))!=null&&(n<o||n===void 0&&o>=o)&&(n=o)}return n}function Cp(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let o of e)(o=t(o,++r,e))!=null&&(n>o||n===void 0&&o>=o)&&(n=o)}return n}function Sp(e,t,n=0,r=1/0,o){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(e.length-1,r)),!(n<=t&&t<=r))return e;for(o=o===void 0?$p:wE(o);r>n;){if(r-n>600){const l=r-n+1,c=t-n+1,d=Math.log(l),f=.5*Math.exp(2*d/3),p=.5*Math.sqrt(d*f*(l-f)/l)*(c-l/2<0?-1:1),m=Math.max(n,Math.floor(t-c*f/l+p)),h=Math.min(r,Math.floor(t+(l-c)*f/l+p));Sp(e,t,m,h,o)}const i=e[t];let a=n,s=r;for(zr(e,n,t),o(e[r],i)>0&&zr(e,n,r);a<s;){for(zr(e,a,s),++a,--s;o(e[a],i)<0;)++a;for(;o(e[s],i)>0;)--s}o(e[n],i)===0?zr(e,n,s):(++s,zr(e,s,r)),s<=t&&(n=s+1),t<=s&&(r=s-1)}return e}function zr(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function OE(e,t,n){if(e=Float64Array.from(hE(e,n)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return Cp(e);if(t>=1)return Ss(e);var r,o=(r-1)*t,i=Math.floor(o),a=Ss(Sp(e,i).subarray(0,i+1)),s=Cp(e.subarray(i+1));return a+(s-a)*(o-i)}}function _E(e,t,n=bp){if(!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return+n(e[0],0,e);if(t>=1)return+n(e[r-1],r-1,e);var r,o=(r-1)*t,i=Math.floor(o),a=+n(e[i],i,e),s=+n(e[i+1],i+1,e);return a+(s-a)*(o-i)}}function NE(e,t,n){e=+e,t=+t,n=(o=arguments.length)<2?(t=e,e=0,1):o<3?1:+n;for(var r=-1,o=Math.max(0,Math.ceil((t-e)/n))|0,i=new Array(o);++r<o;)i[r]=e+r*n;return i}function ut(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function Wt(e,t){switch(arguments.length){case 0:break;case 1:{typeof e=="function"?this.interpolator(e):this.range(e);break}default:{this.domain(e),typeof t=="function"?this.interpolator(t):this.range(t);break}}return this}const Es=Symbol("implicit");function ci(){var e=new xp,t=[],n=[],r=Es;function o(i){let a=e.get(i);if(a===void 0){if(r!==Es)return r;e.set(i,a=t.push(i)-1)}return n[a%n.length]}return o.domain=function(i){if(!arguments.length)return t.slice();t=[],e=new xp;for(const a of i)e.has(a)||e.set(a,t.push(a)-1);return o},o.range=function(i){return arguments.length?(n=Array.from(i),o):n.slice()},o.unknown=function(i){return arguments.length?(r=i,o):r},o.copy=function(){return ci(t,n).unknown(r)},ut.apply(o,arguments),o}function ui(){var e=ci().unknown(void 0),t=e.domain,n=e.range,r=0,o=1,i,a,s=!1,l=0,c=0,d=.5;delete e.unknown;function f(){var p=t().length,m=o<r,h=m?o:r,v=m?r:o;i=(v-h)/Math.max(1,p-l+c*2),s&&(i=Math.floor(i)),h+=(v-h-i*(p-l))*d,a=i*(1-l),s&&(h=Math.round(h),a=Math.round(a));var x=NE(p).map(function(y){return h+i*y});return n(m?x.reverse():x)}return e.domain=function(p){return arguments.length?(t(p),f()):t()},e.range=function(p){return arguments.length?([r,o]=p,r=+r,o=+o,f()):[r,o]},e.rangeRound=function(p){return[r,o]=p,r=+r,o=+o,s=!0,f()},e.bandwidth=function(){return a},e.step=function(){return i},e.round=function(p){return arguments.length?(s=!!p,f()):s},e.padding=function(p){return arguments.length?(l=Math.min(1,c=+p),f()):l},e.paddingInner=function(p){return arguments.length?(l=Math.min(1,p),f()):l},e.paddingOuter=function(p){return arguments.length?(c=+p,f()):c},e.align=function(p){return arguments.length?(d=Math.max(0,Math.min(1,p)),f()):d},e.copy=function(){return ui(t(),[r,o]).round(s).paddingInner(l).paddingOuter(c).align(d)},ut.apply(f(),arguments)}function Ep(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return Ep(t())},e}function Tp(){return Ep(ui.apply(null,arguments).paddingInner(1))}function ar(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function Wr(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function ln(){}var Tn=.7,sr=1/Tn,lr="\\s*([+-]?\\d+)\\s*",Br="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Mt="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",AE=/^#([0-9a-f]{3,8})$/,DE=new RegExp(`^rgb\\(${lr},${lr},${lr}\\)$`),IE=new RegExp(`^rgb\\(${Mt},${Mt},${Mt}\\)$`),LE=new RegExp(`^rgba\\(${lr},${lr},${lr},${Br}\\)$`),FE=new RegExp(`^rgba\\(${Mt},${Mt},${Mt},${Br}\\)$`),jE=new RegExp(`^hsl\\(${Br},${Mt},${Mt}\\)$`),zE=new RegExp(`^hsla\\(${Br},${Mt},${Mt},${Br}\\)$`),Pp={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};ar(ln,Ur,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Mp,formatHex:Mp,formatHex8:WE,formatHsl:BE,formatRgb:kp,toString:kp});function Mp(){return this.rgb().formatHex()}function WE(){return this.rgb().formatHex8()}function BE(){return Dp(this).formatHsl()}function kp(){return this.rgb().formatRgb()}function Ur(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=AE.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?Op(t):n===3?new ze(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?di(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?di(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=DE.exec(e))?new ze(t[1],t[2],t[3],1):(t=IE.exec(e))?new ze(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=LE.exec(e))?di(t[1],t[2],t[3],t[4]):(t=FE.exec(e))?di(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=jE.exec(e))?Ap(t[1],t[2]/100,t[3]/100,1):(t=zE.exec(e))?Ap(t[1],t[2]/100,t[3]/100,t[4]):Pp.hasOwnProperty(e)?Op(Pp[e]):e==="transparent"?new ze(NaN,NaN,NaN,0):null}function Op(e){return new ze(e>>16&255,e>>8&255,e&255,1)}function di(e,t,n,r){return r<=0&&(e=t=n=NaN),new ze(e,t,n,r)}function Ts(e){return e instanceof ln||(e=Ur(e)),e?(e=e.rgb(),new ze(e.r,e.g,e.b,e.opacity)):new ze}function fi(e,t,n,r){return arguments.length===1?Ts(e):new ze(e,t,n,r??1)}function ze(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}ar(ze,fi,Wr(ln,{brighter(e){return e=e==null?sr:Math.pow(sr,e),new ze(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Tn:Math.pow(Tn,e),new ze(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new ze(Pn(this.r),Pn(this.g),Pn(this.b),pi(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:_p,formatHex:_p,formatHex8:UE,formatRgb:Np,toString:Np}));function _p(){return`#${Mn(this.r)}${Mn(this.g)}${Mn(this.b)}`}function UE(){return`#${Mn(this.r)}${Mn(this.g)}${Mn(this.b)}${Mn((isNaN(this.opacity)?1:this.opacity)*255)}`}function Np(){const e=pi(this.opacity);return`${e===1?"rgb(":"rgba("}${Pn(this.r)}, ${Pn(this.g)}, ${Pn(this.b)}${e===1?")":`, ${e})`}`}function pi(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Pn(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Mn(e){return e=Pn(e),(e<16?"0":"")+e.toString(16)}function Ap(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new gt(e,t,n,r)}function Dp(e){if(e instanceof gt)return new gt(e.h,e.s,e.l,e.opacity);if(e instanceof ln||(e=Ur(e)),!e)return new gt;if(e instanceof gt)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,o=Math.min(t,n,r),i=Math.max(t,n,r),a=NaN,s=i-o,l=(i+o)/2;return s?(t===i?a=(n-r)/s+(n<r)*6:n===i?a=(r-t)/s+2:a=(t-n)/s+4,s/=l<.5?i+o:2-i-o,a*=60):s=l>0&&l<1?0:a,new gt(a,s,l,e.opacity)}function Ps(e,t,n,r){return arguments.length===1?Dp(e):new gt(e,t,n,r??1)}function gt(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}ar(gt,Ps,Wr(ln,{brighter(e){return e=e==null?sr:Math.pow(sr,e),new gt(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Tn:Math.pow(Tn,e),new gt(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,o=2*n-r;return new ze(Ms(e>=240?e-240:e+120,o,r),Ms(e,o,r),Ms(e<120?e+240:e-120,o,r),this.opacity)},clamp(){return new gt(Ip(this.h),hi(this.s),hi(this.l),pi(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=pi(this.opacity);return`${e===1?"hsl(":"hsla("}${Ip(this.h)}, ${hi(this.s)*100}%, ${hi(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Ip(e){return e=(e||0)%360,e<0?e+360:e}function hi(e){return Math.max(0,Math.min(1,e||0))}function Ms(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const Lp=Math.PI/180,Fp=180/Math.PI,mi=18,jp=.96422,zp=1,Wp=.82521,Bp=4/29,cr=6/29,Up=3*cr*cr,HE=cr*cr*cr;function Hp(e){if(e instanceof kt)return new kt(e.l,e.a,e.b,e.opacity);if(e instanceof Bt)return Gp(e);e instanceof ze||(e=Ts(e));var t=As(e.r),n=As(e.g),r=As(e.b),o=Os((.2225045*t+.7168786*n+.0606169*r)/zp),i,a;return t===n&&n===r?i=a=o:(i=Os((.4360747*t+.3850649*n+.1430804*r)/jp),a=Os((.0139322*t+.0971045*n+.7141733*r)/Wp)),new kt(116*o-16,500*(i-o),200*(o-a),e.opacity)}function ks(e,t,n,r){return arguments.length===1?Hp(e):new kt(e,t,n,r??1)}function kt(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}ar(kt,ks,Wr(ln,{brighter(e){return new kt(this.l+mi*(e??1),this.a,this.b,this.opacity)},darker(e){return new kt(this.l-mi*(e??1),this.a,this.b,this.opacity)},rgb(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,n=isNaN(this.b)?e:e-this.b/200;return t=jp*_s(t),e=zp*_s(e),n=Wp*_s(n),new ze(Ns(3.1338561*t-1.6168667*e-.4906146*n),Ns(-.9787684*t+1.9161415*e+.033454*n),Ns(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}}));function Os(e){return e>HE?Math.pow(e,1/3):e/Up+Bp}function _s(e){return e>cr?e*e*e:Up*(e-Bp)}function Ns(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function As(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function GE(e){if(e instanceof Bt)return new Bt(e.h,e.c,e.l,e.opacity);if(e instanceof kt||(e=Hp(e)),e.a===0&&e.b===0)return new Bt(NaN,0<e.l&&e.l<100?0:NaN,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*Fp;return new Bt(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}function Ds(e,t,n,r){return arguments.length===1?GE(e):new Bt(e,t,n,r??1)}function Bt(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}function Gp(e){if(isNaN(e.h))return new kt(e.l,0,0,e.opacity);var t=e.h*Lp;return new kt(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}ar(Bt,Ds,Wr(ln,{brighter(e){return new Bt(this.h,this.c,this.l+mi*(e??1),this.opacity)},darker(e){return new Bt(this.h,this.c,this.l-mi*(e??1),this.opacity)},rgb(){return Gp(this).rgb()}}));var Vp=-.14861,Is=1.78277,Ls=-.29227,vi=-.90649,Hr=1.97294,qp=Hr*vi,Yp=Hr*Is,Kp=Is*Ls-vi*Vp;function VE(e){if(e instanceof kn)return new kn(e.h,e.s,e.l,e.opacity);e instanceof ze||(e=Ts(e));var t=e.r/255,n=e.g/255,r=e.b/255,o=(Kp*r+qp*t-Yp*n)/(Kp+qp-Yp),i=r-o,a=(Hr*(n-o)-Ls*i)/vi,s=Math.sqrt(a*a+i*i)/(Hr*o*(1-o)),l=s?Math.atan2(a,i)*Fp-120:NaN;return new kn(l<0?l+360:l,s,o,e.opacity)}function Fs(e,t,n,r){return arguments.length===1?VE(e):new kn(e,t,n,r??1)}function kn(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}ar(kn,Fs,Wr(ln,{brighter(e){return e=e==null?sr:Math.pow(sr,e),new kn(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Tn:Math.pow(Tn,e),new kn(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=isNaN(this.h)?0:(this.h+120)*Lp,t=+this.l,n=isNaN(this.s)?0:this.s*t*(1-t),r=Math.cos(e),o=Math.sin(e);return new ze(255*(t+n*(Vp*r+Is*o)),255*(t+n*(Ls*r+vi*o)),255*(t+n*(Hr*r)),this.opacity)}}));function Xp(e,t,n,r,o){var i=e*e,a=i*e;return((1-3*e+3*i-a)*t+(4-6*i+3*a)*n+(1+3*e+3*i-3*a)*r+a*o)/6}function Rp(e){var t=e.length-1;return function(n){var r=n<=0?n=0:n>=1?(n=1,t-1):Math.floor(n*t),o=e[r],i=e[r+1],a=r>0?e[r-1]:2*o-i,s=r<t-1?e[r+2]:2*i-o;return Xp((n-r/t)*t,a,o,i,s)}}function Zp(e){var t=e.length;return function(n){var r=Math.floor(((n%=1)<0?++n:n)*t),o=e[(r+t-1)%t],i=e[r%t],a=e[(r+1)%t],s=e[(r+2)%t];return Xp((n-r/t)*t,o,i,a,s)}}const gi=e=>()=>e;function Qp(e,t){return function(n){return e+n*t}}function qE(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function yi(e,t){var n=t-e;return n?Qp(e,n>180||n<-180?n-360*Math.round(n/360):n):gi(isNaN(e)?t:e)}function YE(e){return(e=+e)==1?We:function(t,n){return n-t?qE(t,n,e):gi(isNaN(t)?n:t)}}function We(e,t){var n=t-e;return n?Qp(e,n):gi(isNaN(e)?t:e)}const bi=function e(t){var n=YE(t);function r(o,i){var a=n((o=fi(o)).r,(i=fi(i)).r),s=n(o.g,i.g),l=n(o.b,i.b),c=We(o.opacity,i.opacity);return function(d){return o.r=a(d),o.g=s(d),o.b=l(d),o.opacity=c(d),o+""}}return r.gamma=e,r}(1);function Jp(e){return function(t){var n=t.length,r=new Array(n),o=new Array(n),i=new Array(n),a,s;for(a=0;a<n;++a)s=fi(t[a]),r[a]=s.r||0,o[a]=s.g||0,i[a]=s.b||0;return r=e(r),o=e(o),i=e(i),s.opacity=1,function(l){return s.r=r(l),s.g=o(l),s.b=i(l),s+""}}}var KE=Jp(Rp),XE=Jp(Zp);function js(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),o;return function(i){for(o=0;o<n;++o)r[o]=e[o]*(1-i)+t[o]*i;return r}}function eh(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function RE(e,t){return(eh(t)?js:th)(e,t)}function th(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,o=new Array(r),i=new Array(n),a;for(a=0;a<r;++a)o[a]=On(e[a],t[a]);for(;a<n;++a)i[a]=t[a];return function(s){for(a=0;a<r;++a)i[a]=o[a](s);return i}}function nh(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function yt(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function rh(e,t){var n={},r={},o;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(o in t)o in e?n[o]=On(e[o],t[o]):r[o]=t[o];return function(i){for(o in n)r[o]=n[o](i);return r}}var zs=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Ws=new RegExp(zs.source,"g");function ZE(e){return function(){return e}}function QE(e){return function(t){return e(t)+""}}function oh(e,t){var n=zs.lastIndex=Ws.lastIndex=0,r,o,i,a=-1,s=[],l=[];for(e=e+"",t=t+"";(r=zs.exec(e))&&(o=Ws.exec(t));)(i=o.index)>n&&(i=t.slice(n,i),s[a]?s[a]+=i:s[++a]=i),(r=r[0])===(o=o[0])?s[a]?s[a]+=o:s[++a]=o:(s[++a]=null,l.push({i:a,x:yt(r,o)})),n=Ws.lastIndex;return n<t.length&&(i=t.slice(n),s[a]?s[a]+=i:s[++a]=i),s.length<2?l[0]?QE(l[0].x):ZE(t):(t=l.length,function(c){for(var d=0,f;d<t;++d)s[(f=l[d]).i]=f.x(c);return s.join("")})}function On(e,t){var n=typeof t,r;return t==null||n==="boolean"?gi(t):(n==="number"?yt:n==="string"?(r=Ur(t))?(t=r,bi):oh:t instanceof Ur?bi:t instanceof Date?nh:eh(t)?js:Array.isArray(t)?th:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?rh:yt)(e,t)}function JE(e){var t=e.length;return function(n){return e[Math.max(0,Math.min(t-1,Math.floor(n*t)))]}}function e2(e,t){var n=yi(+e,+t);return function(r){var o=n(r);return o-360*Math.floor(o/360)}}function Gr(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}var ih=180/Math.PI,Bs={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function ah(e,t,n,r,o,i){var a,s,l;return(a=Math.sqrt(e*e+t*t))&&(e/=a,t/=a),(l=e*n+t*r)&&(n-=e*l,r-=t*l),(s=Math.sqrt(n*n+r*r))&&(n/=s,r/=s,l/=s),e*r<t*n&&(e=-e,t=-t,l=-l,a=-a),{translateX:o,translateY:i,rotate:Math.atan2(t,e)*ih,skewX:Math.atan(l)*ih,scaleX:a,scaleY:s}}var xi;function t2(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?Bs:ah(t.a,t.b,t.c,t.d,t.e,t.f)}function n2(e){return e==null||(xi||(xi=document.createElementNS("http://www.w3.org/2000/svg","g")),xi.setAttribute("transform",e),!(e=xi.transform.baseVal.consolidate()))?Bs:(e=e.matrix,ah(e.a,e.b,e.c,e.d,e.e,e.f))}function sh(e,t,n,r){function o(c){return c.length?c.pop()+" ":""}function i(c,d,f,p,m,h){if(c!==f||d!==p){var v=m.push("translate(",null,t,null,n);h.push({i:v-4,x:yt(c,f)},{i:v-2,x:yt(d,p)})}else(f||p)&&m.push("translate("+f+t+p+n)}function a(c,d,f,p){c!==d?(c-d>180?d+=360:d-c>180&&(c+=360),p.push({i:f.push(o(f)+"rotate(",null,r)-2,x:yt(c,d)})):d&&f.push(o(f)+"rotate("+d+r)}function s(c,d,f,p){c!==d?p.push({i:f.push(o(f)+"skewX(",null,r)-2,x:yt(c,d)}):d&&f.push(o(f)+"skewX("+d+r)}function l(c,d,f,p,m,h){if(c!==f||d!==p){var v=m.push(o(m)+"scale(",null,",",null,")");h.push({i:v-4,x:yt(c,f)},{i:v-2,x:yt(d,p)})}else(f!==1||p!==1)&&m.push(o(m)+"scale("+f+","+p+")")}return function(c,d){var f=[],p=[];return c=e(c),d=e(d),i(c.translateX,c.translateY,d.translateX,d.translateY,f,p),a(c.rotate,d.rotate,f,p),s(c.skewX,d.skewX,f,p),l(c.scaleX,c.scaleY,d.scaleX,d.scaleY,f,p),c=d=null,function(m){for(var h=-1,v=p.length,x;++h<v;)f[(x=p[h]).i]=x.x(m);return f.join("")}}}var r2=sh(t2,"px, ","px)","deg)"),o2=sh(n2,", ",")",")"),i2=1e-12;function lh(e){return((e=Math.exp(e))+1/e)/2}function a2(e){return((e=Math.exp(e))-1/e)/2}function s2(e){return((e=Math.exp(2*e))-1)/(e+1)}const l2=function e(t,n,r){function o(i,a){var s=i[0],l=i[1],c=i[2],d=a[0],f=a[1],p=a[2],m=d-s,h=f-l,v=m*m+h*h,x,y;if(v<i2)y=Math.log(p/c)/t,x=function(O){return[s+O*m,l+O*h,c*Math.exp(t*O*y)]};else{var b=Math.sqrt(v),$=(p*p-c*c+r*v)/(2*c*n*b),S=(p*p-c*c-r*v)/(2*p*n*b),w=Math.log(Math.sqrt($*$+1)-$),T=Math.log(Math.sqrt(S*S+1)-S);y=(T-w)/t,x=function(O){var P=O*y,_=lh(w),j=c/(n*b)*(_*s2(t*P+w)-a2(w));return[s+j*m,l+j*h,c*_/lh(t*P+w)]}}return x.duration=y*1e3*t/Math.SQRT2,x}return o.rho=function(i){var a=Math.max(.001,+i),s=a*a,l=s*s;return e(a,s,l)},o}(Math.SQRT2,2,4);function ch(e){return function(t,n){var r=e((t=Ps(t)).h,(n=Ps(n)).h),o=We(t.s,n.s),i=We(t.l,n.l),a=We(t.opacity,n.opacity);return function(s){return t.h=r(s),t.s=o(s),t.l=i(s),t.opacity=a(s),t+""}}}const uh=ch(yi);var dh=ch(We);function fh(e,t){var n=We((e=ks(e)).l,(t=ks(t)).l),r=We(e.a,t.a),o=We(e.b,t.b),i=We(e.opacity,t.opacity);return function(a){return e.l=n(a),e.a=r(a),e.b=o(a),e.opacity=i(a),e+""}}function ph(e){return function(t,n){var r=e((t=Ds(t)).h,(n=Ds(n)).h),o=We(t.c,n.c),i=We(t.l,n.l),a=We(t.opacity,n.opacity);return function(s){return t.h=r(s),t.c=o(s),t.l=i(s),t.opacity=a(s),t+""}}}const hh=ph(yi);var mh=ph(We);function vh(e){return function t(n){n=+n;function r(o,i){var a=e((o=Fs(o)).h,(i=Fs(i)).h),s=We(o.s,i.s),l=We(o.l,i.l),c=We(o.opacity,i.opacity);return function(d){return o.h=a(d),o.s=s(d),o.l=l(Math.pow(d,n)),o.opacity=c(d),o+""}}return r.gamma=t,r}(1)}const gh=vh(yi);var yh=vh(We);function bh(e,t){t===void 0&&(t=e,e=On);for(var n=0,r=t.length-1,o=t[0],i=new Array(r<0?0:r);n<r;)i[n]=e(o,o=t[++n]);return function(a){var s=Math.max(0,Math.min(r-1,Math.floor(a*=r)));return i[s](a-s)}}function c2(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e(r/(t-1));return n}function u2(e){return function(){return e}}function wi(e){return+e}var xh=[0,1];function Ke(e){return e}function Us(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:u2(isNaN(t)?NaN:.5)}function d2(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function f2(e,t,n){var r=e[0],o=e[1],i=t[0],a=t[1];return o<r?(r=Us(o,r),i=n(a,i)):(r=Us(r,o),i=n(i,a)),function(s){return i(r(s))}}function p2(e,t,n){var r=Math.min(e.length,t.length)-1,o=new Array(r),i=new Array(r),a=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++a<r;)o[a]=Us(e[a],e[a+1]),i[a]=n(t[a],t[a+1]);return function(s){var l=or(e,s,1,r)-1;return i[l](o[l](s))}}function Vr(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function $i(){var e=xh,t=xh,n=On,r,o,i,a=Ke,s,l,c;function d(){var p=Math.min(e.length,t.length);return a!==Ke&&(a=d2(e[0],e[p-1])),s=p>2?p2:f2,l=c=null,f}function f(p){return p==null||isNaN(p=+p)?i:(l||(l=s(e.map(r),t,n)))(r(a(p)))}return f.invert=function(p){return a(o((c||(c=s(t,e.map(r),yt)))(p)))},f.domain=function(p){return arguments.length?(e=Array.from(p,wi),d()):e.slice()},f.range=function(p){return arguments.length?(t=Array.from(p),d()):t.slice()},f.rangeRound=function(p){return t=Array.from(p),n=Gr,d()},f.clamp=function(p){return arguments.length?(a=p?!0:Ke,d()):a!==Ke},f.interpolate=function(p){return arguments.length?(n=p,d()):n},f.unknown=function(p){return arguments.length?(i=p,f):i},function(p,m){return r=p,o=m,d()}}function Hs(){return $i()(Ke,Ke)}function h2(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Ci(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function ur(e){return e=Ci(Math.abs(e)),e?e[1]:NaN}function m2(e,t){return function(n,r){for(var o=n.length,i=[],a=0,s=e[0],l=0;o>0&&s>0&&(l+s+1>r&&(s=Math.max(1,r-l)),i.push(n.substring(o-=s,o+s)),!((l+=s+1)>r));)s=e[a=(a+1)%e.length];return i.reverse().join(t)}}function v2(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var g2=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function qr(e){if(!(t=g2.exec(e)))throw new Error("invalid format: "+e);var t;return new Gs({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}qr.prototype=Gs.prototype;function Gs(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}Gs.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function y2(e){e:for(var t=e.length,n=1,r=-1,o;n<t;++n)switch(e[n]){case".":r=o=n;break;case"0":r===0&&(r=n),o=n;break;default:if(!+e[n])break e;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(o+1):e}var wh;function b2(e,t){var n=Ci(e,t);if(!n)return e+"";var r=n[0],o=n[1],i=o-(wh=Math.max(-8,Math.min(8,Math.floor(o/3)))*3)+1,a=r.length;return i===a?r:i>a?r+new Array(i-a+1).join("0"):i>0?r.slice(0,i)+"."+r.slice(i):"0."+new Array(1-i).join("0")+Ci(e,Math.max(0,t+i-1))[0]}function $h(e,t){var n=Ci(e,t);if(!n)return e+"";var r=n[0],o=n[1];return o<0?"0."+new Array(-o).join("0")+r:r.length>o+1?r.slice(0,o+1)+"."+r.slice(o+1):r+new Array(o-r.length+2).join("0")}const Ch={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:h2,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>$h(e*100,t),r:$h,s:b2,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function Sh(e){return e}var Eh=Array.prototype.map,Th=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function x2(e){var t=e.grouping===void 0||e.thousands===void 0?Sh:m2(Eh.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",o=e.decimal===void 0?".":e.decimal+"",i=e.numerals===void 0?Sh:v2(Eh.call(e.numerals,String)),a=e.percent===void 0?"%":e.percent+"",s=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function c(f){f=qr(f);var p=f.fill,m=f.align,h=f.sign,v=f.symbol,x=f.zero,y=f.width,b=f.comma,$=f.precision,S=f.trim,w=f.type;w==="n"?(b=!0,w="g"):Ch[w]||($===void 0&&($=12),S=!0,w="g"),(x||p==="0"&&m==="=")&&(x=!0,p="0",m="=");var T=v==="$"?n:v==="#"&&/[boxX]/.test(w)?"0"+w.toLowerCase():"",O=v==="$"?r:/[%p]/.test(w)?a:"",P=Ch[w],_=/[defgprs%]/.test(w);$=$===void 0?6:/[gprs]/.test(w)?Math.max(1,Math.min(21,$)):Math.max(0,Math.min(20,$));function j(F){var V=T,R=O,X,C,I;if(w==="c")R=P(F)+R,F="";else{F=+F;var H=F<0||1/F<0;if(F=isNaN(F)?l:P(Math.abs(F),$),S&&(F=y2(F)),H&&+F==0&&h!=="+"&&(H=!1),V=(H?h==="("?h:s:h==="-"||h==="("?"":h)+V,R=(w==="s"?Th[8+wh/3]:"")+R+(H&&h==="("?")":""),_){for(X=-1,C=F.length;++X<C;)if(I=F.charCodeAt(X),48>I||I>57){R=(I===46?o+F.slice(X+1):F.slice(X))+R,F=F.slice(0,X);break}}}b&&!x&&(F=t(F,1/0));var B=V.length+F.length+R.length,A=B<y?new Array(y-B+1).join(p):"";switch(b&&x&&(F=t(A+F,A.length?y-R.length:1/0),A=""),m){case"<":F=V+F+R+A;break;case"=":F=V+A+F+R;break;case"^":F=A.slice(0,B=A.length>>1)+V+F+R+A.slice(B);break;default:F=A+V+F+R;break}return i(F)}return j.toString=function(){return f+""},j}function d(f,p){var m=c((f=qr(f),f.type="f",f)),h=Math.max(-8,Math.min(8,Math.floor(ur(p)/3)))*3,v=Math.pow(10,-h),x=Th[8+h/3];return function(y){return m(v*y)+x}}return{format:c,formatPrefix:d}}var Si,Ei,Ph;w2({thousands:",",grouping:[3],currency:["$",""]});function w2(e){return Si=x2(e),Ei=Si.format,Ph=Si.formatPrefix,Si}function $2(e){return Math.max(0,-ur(Math.abs(e)))}function C2(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(ur(t)/3)))*3-ur(Math.abs(e)))}function S2(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,ur(t)-ur(e))+1}function Mh(e,t,n,r){var o=Cs(e,t,n),i;switch(r=qr(r??",f"),r.type){case"s":{var a=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(i=C2(o,a))&&(r.precision=i),Ph(r,a)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(i=S2(o,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=i-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(i=$2(o))&&(r.precision=i-(r.type==="%")*2);break}}return Ei(r)}function cn(e){var t=e.domain;return e.ticks=function(n){var r=t();return li(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var o=t();return Mh(o[0],o[o.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),o=0,i=r.length-1,a=r[o],s=r[i],l,c,d=10;for(s<a&&(c=a,a=s,s=c,c=o,o=i,i=c);d-- >0;){if(c=ir(a,s,n),c===l)return r[o]=a,r[i]=s,t(r);if(c>0)a=Math.floor(a/c)*c,s=Math.ceil(s/c)*c;else if(c<0)a=Math.ceil(a*c)/c,s=Math.floor(s*c)/c;else break;l=c}return e},e}function Vs(){var e=Hs();return e.copy=function(){return Vr(e,Vs())},ut.apply(e,arguments),cn(e)}function kh(e){var t;function n(r){return r==null||isNaN(r=+r)?t:r}return n.invert=n,n.domain=n.range=function(r){return arguments.length?(e=Array.from(r,wi),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return kh(e).unknown(t)},e=arguments.length?Array.from(e,wi):[0,1],cn(n)}function Oh(e,t){e=e.slice();var n=0,r=e.length-1,o=e[n],i=e[r],a;return i<o&&(a=n,n=r,r=a,a=o,o=i,i=a),e[n]=t.floor(o),e[r]=t.ceil(i),e}function _h(e){return Math.log(e)}function Nh(e){return Math.exp(e)}function E2(e){return-Math.log(-e)}function T2(e){return-Math.exp(-e)}function P2(e){return isFinite(e)?+("1e"+e):e<0?0:e}function M2(e){return e===10?P2:e===Math.E?Math.exp:t=>Math.pow(e,t)}function k2(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function Ah(e){return(t,n)=>-e(-t,n)}function qs(e){const t=e(_h,Nh),n=t.domain;let r=10,o,i;function a(){return o=k2(r),i=M2(r),n()[0]<0?(o=Ah(o),i=Ah(i),e(E2,T2)):e(_h,Nh),t}return t.base=function(s){return arguments.length?(r=+s,a()):r},t.domain=function(s){return arguments.length?(n(s),a()):n()},t.ticks=s=>{const l=n();let c=l[0],d=l[l.length-1];const f=d<c;f&&([c,d]=[d,c]);let p=o(c),m=o(d),h,v;const x=s==null?10:+s;let y=[];if(!(r%1)&&m-p<x){if(p=Math.floor(p),m=Math.ceil(m),c>0){for(;p<=m;++p)for(h=1;h<r;++h)if(v=p<0?h/i(-p):h*i(p),!(v<c)){if(v>d)break;y.push(v)}}else for(;p<=m;++p)for(h=r-1;h>=1;--h)if(v=p>0?h/i(-p):h*i(p),!(v<c)){if(v>d)break;y.push(v)}y.length*2<x&&(y=li(c,d,x))}else y=li(p,m,Math.min(m-p,x)).map(i);return f?y.reverse():y},t.tickFormat=(s,l)=>{if(s==null&&(s=10),l==null&&(l=r===10?"s":","),typeof l!="function"&&(!(r%1)&&(l=qr(l)).precision==null&&(l.trim=!0),l=Ei(l)),s===1/0)return l;const c=Math.max(1,r*s/t.ticks().length);return d=>{let f=d/i(Math.round(o(d)));return f*r<r-.5&&(f*=r),f<=c?l(d):""}},t.nice=()=>n(Oh(n(),{floor:s=>i(Math.floor(o(s))),ceil:s=>i(Math.ceil(o(s)))})),t}function Ys(){const e=qs($i()).domain([1,10]);return e.copy=()=>Vr(e,Ys()).base(e.base()),ut.apply(e,arguments),e}function Dh(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function Ih(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function Ks(e){var t=1,n=e(Dh(t),Ih(t));return n.constant=function(r){return arguments.length?e(Dh(t=+r),Ih(t)):t},cn(n)}function Xs(){var e=Ks($i());return e.copy=function(){return Vr(e,Xs()).constant(e.constant())},ut.apply(e,arguments)}function Lh(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function O2(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function _2(e){return e<0?-e*e:e*e}function Rs(e){var t=e(Ke,Ke),n=1;function r(){return n===1?e(Ke,Ke):n===.5?e(O2,_2):e(Lh(n),Lh(1/n))}return t.exponent=function(o){return arguments.length?(n=+o,r()):n},cn(t)}function Ti(){var e=Rs($i());return e.copy=function(){return Vr(e,Ti()).exponent(e.exponent())},ut.apply(e,arguments),e}function Fh(){return Ti.apply(null,arguments).exponent(.5)}function jh(e){return Math.sign(e)*e*e}function N2(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function Zs(){var e=Hs(),t=[0,1],n=!1,r;function o(i){var a=N2(e(i));return isNaN(a)?r:n?Math.round(a):a}return o.invert=function(i){return e.invert(jh(i))},o.domain=function(i){return arguments.length?(e.domain(i),o):e.domain()},o.range=function(i){return arguments.length?(e.range((t=Array.from(i,wi)).map(jh)),o):t.slice()},o.rangeRound=function(i){return o.range(i).round(!0)},o.round=function(i){return arguments.length?(n=!!i,o):n},o.clamp=function(i){return arguments.length?(e.clamp(i),o):e.clamp()},o.unknown=function(i){return arguments.length?(r=i,o):r},o.copy=function(){return Zs(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},ut.apply(o,arguments),cn(o)}function Qs(){var e=[],t=[],n=[],r;function o(){var a=0,s=Math.max(1,t.length);for(n=new Array(s-1);++a<s;)n[a-1]=_E(e,a/s);return i}function i(a){return a==null||isNaN(a=+a)?r:t[or(n,a)]}return i.invertExtent=function(a){var s=t.indexOf(a);return s<0?[NaN,NaN]:[s>0?n[s-1]:e[0],s<n.length?n[s]:e[e.length-1]]},i.domain=function(a){if(!arguments.length)return e.slice();e=[];for(let s of a)s!=null&&!isNaN(s=+s)&&e.push(s);return e.sort(sn),o()},i.range=function(a){return arguments.length?(t=Array.from(a),o()):t.slice()},i.unknown=function(a){return arguments.length?(r=a,i):r},i.quantiles=function(){return n.slice()},i.copy=function(){return Qs().domain(e).range(t).unknown(r)},ut.apply(i,arguments)}function Js(){var e=0,t=1,n=1,r=[.5],o=[0,1],i;function a(l){return l!=null&&l<=l?o[or(r,l,0,n)]:i}function s(){var l=-1;for(r=new Array(n);++l<n;)r[l]=((l+1)*t-(l-n)*e)/(n+1);return a}return a.domain=function(l){return arguments.length?([e,t]=l,e=+e,t=+t,s()):[e,t]},a.range=function(l){return arguments.length?(n=(o=Array.from(l)).length-1,s()):o.slice()},a.invertExtent=function(l){var c=o.indexOf(l);return c<0?[NaN,NaN]:c<1?[e,r[0]]:c>=n?[r[n-1],t]:[r[c-1],r[c]]},a.unknown=function(l){return arguments.length&&(i=l),a},a.thresholds=function(){return r.slice()},a.copy=function(){return Js().domain([e,t]).range(o).unknown(i)},ut.apply(cn(a),arguments)}function el(){var e=[.5],t=[0,1],n,r=1;function o(i){return i!=null&&i<=i?t[or(e,i,0,r)]:n}return o.domain=function(i){return arguments.length?(e=Array.from(i),r=Math.min(e.length,t.length-1),o):e.slice()},o.range=function(i){return arguments.length?(t=Array.from(i),r=Math.min(e.length,t.length-1),o):t.slice()},o.invertExtent=function(i){var a=t.indexOf(i);return[e[a-1],e[a]]},o.unknown=function(i){return arguments.length?(n=i,o):n},o.copy=function(){return el().domain(e).range(t).unknown(n)},ut.apply(o,arguments)}const tl=new Date,nl=new Date;function Fe(e,t,n,r){function o(i){return e(i=arguments.length===0?new Date:new Date(+i)),i}return o.floor=i=>(e(i=new Date(+i)),i),o.ceil=i=>(e(i=new Date(i-1)),t(i,1),e(i),i),o.round=i=>{const a=o(i),s=o.ceil(i);return i-a<s-i?a:s},o.offset=(i,a)=>(t(i=new Date(+i),a==null?1:Math.floor(a)),i),o.range=(i,a,s)=>{const l=[];if(i=o.ceil(i),s=s==null?1:Math.floor(s),!(i<a)||!(s>0))return l;let c;do l.push(c=new Date(+i)),t(i,s),e(i);while(c<i&&i<a);return l},o.filter=i=>Fe(a=>{if(a>=a)for(;e(a),!i(a);)a.setTime(a-1)},(a,s)=>{if(a>=a)if(s<0)for(;++s<=0;)for(;t(a,-1),!i(a););else for(;--s>=0;)for(;t(a,1),!i(a););}),n&&(o.count=(i,a)=>(tl.setTime(+i),nl.setTime(+a),e(tl),e(nl),Math.floor(n(tl,nl))),o.every=i=>(i=Math.floor(i),!isFinite(i)||!(i>0)?null:i>1?o.filter(r?a=>r(a)%i===0:a=>o.count(0,a)%i===0):o)),o}const dr=Fe(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);dr.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Fe(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):dr);const zh=dr.range,Ut=1e3,dt=Ut*60,Ht=dt*60,Gt=Ht*24,rl=Gt*7,Wh=Gt*30,ol=Gt*365,bt=Fe(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Ut)},(e,t)=>(t-e)/Ut,e=>e.getUTCSeconds()),Bh=bt.range,Yr=Fe(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Ut)},(e,t)=>{e.setTime(+e+t*dt)},(e,t)=>(t-e)/dt,e=>e.getMinutes()),A2=Yr.range,Kr=Fe(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*dt)},(e,t)=>(t-e)/dt,e=>e.getUTCMinutes()),D2=Kr.range,Xr=Fe(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Ut-e.getMinutes()*dt)},(e,t)=>{e.setTime(+e+t*Ht)},(e,t)=>(t-e)/Ht,e=>e.getHours()),I2=Xr.range,Rr=Fe(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*Ht)},(e,t)=>(t-e)/Ht,e=>e.getUTCHours()),L2=Rr.range,_n=Fe(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*dt)/Gt,e=>e.getDate()-1),F2=_n.range,fr=Fe(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Gt,e=>e.getUTCDate()-1),j2=fr.range,il=Fe(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Gt,e=>Math.floor(e/Gt)),z2=il.range;function Nn(e){return Fe(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*dt)/rl)}const An=Nn(0),Zr=Nn(1),Uh=Nn(2),Hh=Nn(3),Dn=Nn(4),Gh=Nn(5),Vh=Nn(6),qh=An.range,W2=Zr.range,B2=Uh.range,U2=Hh.range,H2=Dn.range,G2=Gh.range,V2=Vh.range;function In(e){return Fe(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/rl)}const Ln=In(0),Qr=In(1),Yh=In(2),Kh=In(3),Fn=In(4),Xh=In(5),Rh=In(6),Zh=Ln.range,q2=Qr.range,Y2=Yh.range,K2=Kh.range,X2=Fn.range,R2=Xh.range,Z2=Rh.range,Jr=Fe(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth()),Q2=Jr.range,eo=Fe(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth()),J2=eo.range,xt=Fe(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());xt.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Fe(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)});const eT=xt.range,wt=Fe(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());wt.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Fe(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)});const tT=wt.range;function Qh(e,t,n,r,o,i){const a=[[bt,1,Ut],[bt,5,5*Ut],[bt,15,15*Ut],[bt,30,30*Ut],[i,1,dt],[i,5,5*dt],[i,15,15*dt],[i,30,30*dt],[o,1,Ht],[o,3,3*Ht],[o,6,6*Ht],[o,12,12*Ht],[r,1,Gt],[r,2,2*Gt],[n,1,rl],[t,1,Wh],[t,3,3*Wh],[e,1,ol]];function s(c,d,f){const p=d<c;p&&([c,d]=[d,c]);const m=f&&typeof f.range=="function"?f:l(c,d,f),h=m?m.range(c,+d+1):[];return p?h.reverse():h}function l(c,d,f){const p=Math.abs(d-c)/f,m=ws(([,,x])=>x).right(a,p);if(m===a.length)return e.every(Cs(c/ol,d/ol,f));if(m===0)return dr.every(Math.max(Cs(c,d,f),1));const[h,v]=a[p/a[m-1][2]<a[m][2]/p?m-1:m];return h.every(v)}return[s,l]}const[Jh,em]=Qh(wt,eo,Ln,il,Rr,Kr),[tm,nm]=Qh(xt,Jr,An,_n,Xr,Yr);function al(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function sl(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function to(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function nT(e){var t=e.dateTime,n=e.date,r=e.time,o=e.periods,i=e.days,a=e.shortDays,s=e.months,l=e.shortMonths,c=no(o),d=ro(o),f=no(i),p=ro(i),m=no(a),h=ro(a),v=no(s),x=ro(s),y=no(l),b=ro(l),$={a:H,A:B,b:A,B:N,c:null,d:lm,e:lm,f:ET,g:IT,G:FT,H:$T,I:CT,j:ST,L:cm,m:TT,M:PT,p:z,q:J,Q:mm,s:vm,S:MT,u:kT,U:OT,V:_T,w:NT,W:AT,x:null,X:null,y:DT,Y:LT,Z:jT,"%":hm},S={a:Q,A:oe,b:te,B:ae,c:null,d:dm,e:dm,f:UT,g:QT,G:eP,H:zT,I:WT,j:BT,L:fm,m:HT,M:GT,p:Y,q:le,Q:mm,s:vm,S:VT,u:qT,U:YT,V:KT,w:XT,W:RT,x:null,X:null,y:ZT,Y:JT,Z:tP,"%":hm},w={a:j,A:F,b:V,B:R,c:X,d:am,e:am,f:yT,g:im,G:om,H:sm,I:sm,j:hT,L:gT,m:pT,M:mT,p:_,q:fT,Q:xT,s:wT,S:vT,u:sT,U:lT,V:cT,w:aT,W:uT,x:C,X:I,y:im,Y:om,Z:dT,"%":bT};$.x=T(n,$),$.X=T(r,$),$.c=T(t,$),S.x=T(n,S),S.X=T(r,S),S.c=T(t,S);function T(U,q){return function(re){var k=[],de=-1,pe=0,Ce=U.length,ke,je,_t;for(re instanceof Date||(re=new Date(+re));++de<Ce;)U.charCodeAt(de)===37&&(k.push(U.slice(pe,de)),(je=rm[ke=U.charAt(++de)])!=null?ke=U.charAt(++de):je=ke==="e"?" ":"0",(_t=q[ke])&&(ke=_t(re,je)),k.push(ke),pe=de+1);return k.push(U.slice(pe,de)),k.join("")}}function O(U,q){return function(re){var k=to(1900,void 0,1),de=P(k,U,re+="",0),pe,Ce;if(de!=re.length)return null;if("Q"in k)return new Date(k.Q);if("s"in k)return new Date(k.s*1e3+("L"in k?k.L:0));if(q&&!("Z"in k)&&(k.Z=0),"p"in k&&(k.H=k.H%12+k.p*12),k.m===void 0&&(k.m="q"in k?k.q:0),"V"in k){if(k.V<1||k.V>53)return null;"w"in k||(k.w=1),"Z"in k?(pe=sl(to(k.y,0,1)),Ce=pe.getUTCDay(),pe=Ce>4||Ce===0?Qr.ceil(pe):Qr(pe),pe=fr.offset(pe,(k.V-1)*7),k.y=pe.getUTCFullYear(),k.m=pe.getUTCMonth(),k.d=pe.getUTCDate()+(k.w+6)%7):(pe=al(to(k.y,0,1)),Ce=pe.getDay(),pe=Ce>4||Ce===0?Zr.ceil(pe):Zr(pe),pe=_n.offset(pe,(k.V-1)*7),k.y=pe.getFullYear(),k.m=pe.getMonth(),k.d=pe.getDate()+(k.w+6)%7)}else("W"in k||"U"in k)&&("w"in k||(k.w="u"in k?k.u%7:"W"in k?1:0),Ce="Z"in k?sl(to(k.y,0,1)).getUTCDay():al(to(k.y,0,1)).getDay(),k.m=0,k.d="W"in k?(k.w+6)%7+k.W*7-(Ce+5)%7:k.w+k.U*7-(Ce+6)%7);return"Z"in k?(k.H+=k.Z/100|0,k.M+=k.Z%100,sl(k)):al(k)}}function P(U,q,re,k){for(var de=0,pe=q.length,Ce=re.length,ke,je;de<pe;){if(k>=Ce)return-1;if(ke=q.charCodeAt(de++),ke===37){if(ke=q.charAt(de++),je=w[ke in rm?q.charAt(de++):ke],!je||(k=je(U,re,k))<0)return-1}else if(ke!=re.charCodeAt(k++))return-1}return k}function _(U,q,re){var k=c.exec(q.slice(re));return k?(U.p=d.get(k[0].toLowerCase()),re+k[0].length):-1}function j(U,q,re){var k=m.exec(q.slice(re));return k?(U.w=h.get(k[0].toLowerCase()),re+k[0].length):-1}function F(U,q,re){var k=f.exec(q.slice(re));return k?(U.w=p.get(k[0].toLowerCase()),re+k[0].length):-1}function V(U,q,re){var k=y.exec(q.slice(re));return k?(U.m=b.get(k[0].toLowerCase()),re+k[0].length):-1}function R(U,q,re){var k=v.exec(q.slice(re));return k?(U.m=x.get(k[0].toLowerCase()),re+k[0].length):-1}function X(U,q,re){return P(U,t,q,re)}function C(U,q,re){return P(U,n,q,re)}function I(U,q,re){return P(U,r,q,re)}function H(U){return a[U.getDay()]}function B(U){return i[U.getDay()]}function A(U){return l[U.getMonth()]}function N(U){return s[U.getMonth()]}function z(U){return o[+(U.getHours()>=12)]}function J(U){return 1+~~(U.getMonth()/3)}function Q(U){return a[U.getUTCDay()]}function oe(U){return i[U.getUTCDay()]}function te(U){return l[U.getUTCMonth()]}function ae(U){return s[U.getUTCMonth()]}function Y(U){return o[+(U.getUTCHours()>=12)]}function le(U){return 1+~~(U.getUTCMonth()/3)}return{format:function(U){var q=T(U+="",$);return q.toString=function(){return U},q},parse:function(U){var q=O(U+="",!1);return q.toString=function(){return U},q},utcFormat:function(U){var q=T(U+="",S);return q.toString=function(){return U},q},utcParse:function(U){var q=O(U+="",!0);return q.toString=function(){return U},q}}}var rm={"-":"",_:" ",0:"0"},Be=/^\s*\d+/,rT=/^%/,oT=/[\\^$*+?|[\]().{}]/g;function Se(e,t,n){var r=e<0?"-":"",o=(r?-e:e)+"",i=o.length;return r+(i<n?new Array(n-i+1).join(t)+o:o)}function iT(e){return e.replace(oT,"\\$&")}function no(e){return new RegExp("^(?:"+e.map(iT).join("|")+")","i")}function ro(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function aT(e,t,n){var r=Be.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function sT(e,t,n){var r=Be.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function lT(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function cT(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function uT(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function om(e,t,n){var r=Be.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function im(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function dT(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function fT(e,t,n){var r=Be.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function pT(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function am(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function hT(e,t,n){var r=Be.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function sm(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function mT(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function vT(e,t,n){var r=Be.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function gT(e,t,n){var r=Be.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function yT(e,t,n){var r=Be.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function bT(e,t,n){var r=rT.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function xT(e,t,n){var r=Be.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function wT(e,t,n){var r=Be.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function lm(e,t){return Se(e.getDate(),t,2)}function $T(e,t){return Se(e.getHours(),t,2)}function CT(e,t){return Se(e.getHours()%12||12,t,2)}function ST(e,t){return Se(1+_n.count(xt(e),e),t,3)}function cm(e,t){return Se(e.getMilliseconds(),t,3)}function ET(e,t){return cm(e,t)+"000"}function TT(e,t){return Se(e.getMonth()+1,t,2)}function PT(e,t){return Se(e.getMinutes(),t,2)}function MT(e,t){return Se(e.getSeconds(),t,2)}function kT(e){var t=e.getDay();return t===0?7:t}function OT(e,t){return Se(An.count(xt(e)-1,e),t,2)}function um(e){var t=e.getDay();return t>=4||t===0?Dn(e):Dn.ceil(e)}function _T(e,t){return e=um(e),Se(Dn.count(xt(e),e)+(xt(e).getDay()===4),t,2)}function NT(e){return e.getDay()}function AT(e,t){return Se(Zr.count(xt(e)-1,e),t,2)}function DT(e,t){return Se(e.getFullYear()%100,t,2)}function IT(e,t){return e=um(e),Se(e.getFullYear()%100,t,2)}function LT(e,t){return Se(e.getFullYear()%1e4,t,4)}function FT(e,t){var n=e.getDay();return e=n>=4||n===0?Dn(e):Dn.ceil(e),Se(e.getFullYear()%1e4,t,4)}function jT(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Se(t/60|0,"0",2)+Se(t%60,"0",2)}function dm(e,t){return Se(e.getUTCDate(),t,2)}function zT(e,t){return Se(e.getUTCHours(),t,2)}function WT(e,t){return Se(e.getUTCHours()%12||12,t,2)}function BT(e,t){return Se(1+fr.count(wt(e),e),t,3)}function fm(e,t){return Se(e.getUTCMilliseconds(),t,3)}function UT(e,t){return fm(e,t)+"000"}function HT(e,t){return Se(e.getUTCMonth()+1,t,2)}function GT(e,t){return Se(e.getUTCMinutes(),t,2)}function VT(e,t){return Se(e.getUTCSeconds(),t,2)}function qT(e){var t=e.getUTCDay();return t===0?7:t}function YT(e,t){return Se(Ln.count(wt(e)-1,e),t,2)}function pm(e){var t=e.getUTCDay();return t>=4||t===0?Fn(e):Fn.ceil(e)}function KT(e,t){return e=pm(e),Se(Fn.count(wt(e),e)+(wt(e).getUTCDay()===4),t,2)}function XT(e){return e.getUTCDay()}function RT(e,t){return Se(Qr.count(wt(e)-1,e),t,2)}function ZT(e,t){return Se(e.getUTCFullYear()%100,t,2)}function QT(e,t){return e=pm(e),Se(e.getUTCFullYear()%100,t,2)}function JT(e,t){return Se(e.getUTCFullYear()%1e4,t,4)}function eP(e,t){var n=e.getUTCDay();return e=n>=4||n===0?Fn(e):Fn.ceil(e),Se(e.getUTCFullYear()%1e4,t,4)}function tP(){return"+0000"}function hm(){return"%"}function mm(e){return+e}function vm(e){return Math.floor(+e/1e3)}var pr,gm,ym;nP({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function nP(e){return pr=nT(e),gm=pr.format,pr.parse,ym=pr.utcFormat,pr.utcParse,pr}function rP(e){return new Date(e)}function oP(e){return e instanceof Date?+e:+new Date(+e)}function ll(e,t,n,r,o,i,a,s,l,c){var d=Hs(),f=d.invert,p=d.domain,m=c(".%L"),h=c(":%S"),v=c("%I:%M"),x=c("%I %p"),y=c("%a %d"),b=c("%b %d"),$=c("%B"),S=c("%Y");function w(T){return(l(T)<T?m:s(T)<T?h:a(T)<T?v:i(T)<T?x:r(T)<T?o(T)<T?y:b:n(T)<T?$:S)(T)}return d.invert=function(T){return new Date(f(T))},d.domain=function(T){return arguments.length?p(Array.from(T,oP)):p().map(rP)},d.ticks=function(T){var O=p();return e(O[0],O[O.length-1],T??10)},d.tickFormat=function(T,O){return O==null?w:c(O)},d.nice=function(T){var O=p();return(!T||typeof T.range!="function")&&(T=t(O[0],O[O.length-1],T??10)),T?p(Oh(O,T)):d},d.copy=function(){return Vr(d,ll(e,t,n,r,o,i,a,s,l,c))},d}function bm(){return ut.apply(ll(tm,nm,xt,Jr,An,_n,Xr,Yr,bt,gm).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function xm(){return ut.apply(ll(Jh,em,wt,eo,Ln,fr,Rr,Kr,bt,ym).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function Pi(){var e=0,t=1,n,r,o,i,a=Ke,s=!1,l;function c(f){return f==null||isNaN(f=+f)?l:a(o===0?.5:(f=(i(f)-n)*o,s?Math.max(0,Math.min(1,f)):f))}c.domain=function(f){return arguments.length?([e,t]=f,n=i(e=+e),r=i(t=+t),o=n===r?0:1/(r-n),c):[e,t]},c.clamp=function(f){return arguments.length?(s=!!f,c):s},c.interpolator=function(f){return arguments.length?(a=f,c):a};function d(f){return function(p){var m,h;return arguments.length?([m,h]=p,a=f(m,h),c):[a(0),a(1)]}}return c.range=d(On),c.rangeRound=d(Gr),c.unknown=function(f){return arguments.length?(l=f,c):l},function(f){return i=f,n=f(e),r=f(t),o=n===r?0:1/(r-n),c}}function un(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function wm(){var e=cn(Pi()(Ke));return e.copy=function(){return un(e,wm())},Wt.apply(e,arguments)}function $m(){var e=qs(Pi()).domain([1,10]);return e.copy=function(){return un(e,$m()).base(e.base())},Wt.apply(e,arguments)}function Cm(){var e=Ks(Pi());return e.copy=function(){return un(e,Cm()).constant(e.constant())},Wt.apply(e,arguments)}function cl(){var e=Rs(Pi());return e.copy=function(){return un(e,cl()).exponent(e.exponent())},Wt.apply(e,arguments)}function iP(){return cl.apply(null,arguments).exponent(.5)}function Sm(){var e=[],t=Ke;function n(r){if(r!=null&&!isNaN(r=+r))return t((or(e,r,1)-1)/(e.length-1))}return n.domain=function(r){if(!arguments.length)return e.slice();e=[];for(let o of r)o!=null&&!isNaN(o=+o)&&e.push(o);return e.sort(sn),n},n.interpolator=function(r){return arguments.length?(t=r,n):t},n.range=function(){return e.map((r,o)=>t(o/(e.length-1)))},n.quantiles=function(r){return Array.from({length:r+1},(o,i)=>OE(e,i/r))},n.copy=function(){return Sm(t).domain(e)},Wt.apply(n,arguments)}function Mi(){var e=0,t=.5,n=1,r=1,o,i,a,s,l,c=Ke,d,f=!1,p;function m(v){return isNaN(v=+v)?p:(v=.5+((v=+d(v))-i)*(r*v<r*i?s:l),c(f?Math.max(0,Math.min(1,v)):v))}m.domain=function(v){return arguments.length?([e,t,n]=v,o=d(e=+e),i=d(t=+t),a=d(n=+n),s=o===i?0:.5/(i-o),l=i===a?0:.5/(a-i),r=i<o?-1:1,m):[e,t,n]},m.clamp=function(v){return arguments.length?(f=!!v,m):f},m.interpolator=function(v){return arguments.length?(c=v,m):c};function h(v){return function(x){var y,b,$;return arguments.length?([y,b,$]=x,c=bh(v,[y,b,$]),m):[c(0),c(.5),c(1)]}}return m.range=h(On),m.rangeRound=h(Gr),m.unknown=function(v){return arguments.length?(p=v,m):p},function(v){return d=v,o=v(e),i=v(t),a=v(n),s=o===i?0:.5/(i-o),l=i===a?0:.5/(a-i),r=i<o?-1:1,m}}function Em(){var e=cn(Mi()(Ke));return e.copy=function(){return un(e,Em())},Wt.apply(e,arguments)}function Tm(){var e=qs(Mi()).domain([.1,1,10]);return e.copy=function(){return un(e,Tm()).base(e.base())},Wt.apply(e,arguments)}function Pm(){var e=Ks(Mi());return e.copy=function(){return un(e,Pm()).constant(e.constant())},Wt.apply(e,arguments)}function ul(){var e=Rs(Mi());return e.copy=function(){return un(e,ul()).exponent(e.exponent())},Wt.apply(e,arguments)}function aP(){return ul.apply(null,arguments).exponent(.5)}const sP=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:ui,scaleDiverging:Em,scaleDivergingLog:Tm,scaleDivergingPow:ul,scaleDivergingSqrt:aP,scaleDivergingSymlog:Pm,scaleIdentity:kh,scaleImplicit:Es,scaleLinear:Vs,scaleLog:Ys,scaleOrdinal:ci,scalePoint:Tp,scalePow:Ti,scaleQuantile:Qs,scaleQuantize:Js,scaleRadial:Zs,scaleSequential:wm,scaleSequentialLog:$m,scaleSequentialPow:cl,scaleSequentialQuantile:Sm,scaleSequentialSqrt:iP,scaleSequentialSymlog:Cm,scaleSqrt:Fh,scaleSymlog:Xs,scaleThreshold:el,scaleTime:bm,scaleUtc:xm,tickFormat:Mh},Symbol.toStringTag,{value:"Module"}));function lP(e,t){t.domain&&("nice"in e||"quantiles"in e||"padding"in e,e.domain(t.domain))}function cP(e,t){t.range&&("padding"in e,e.range(t.range))}function uP(e,t){"align"in e&&"align"in t&&typeof t.align<"u"&&e.align(t.align)}function dP(e,t){"base"in e&&"base"in t&&typeof t.base<"u"&&e.base(t.base)}function fP(e,t){"clamp"in e&&"clamp"in t&&typeof t.clamp<"u"&&e.clamp(t.clamp)}function pP(e,t){"constant"in e&&"constant"in t&&typeof t.constant<"u"&&e.constant(t.constant)}function hP(e,t){"exponent"in e&&"exponent"in t&&typeof t.exponent<"u"&&e.exponent(t.exponent)}const mP=Object.freeze(Object.defineProperty({__proto__:null,interpolate:On,interpolateArray:RE,interpolateBasis:Rp,interpolateBasisClosed:Zp,interpolateCubehelix:gh,interpolateCubehelixLong:yh,interpolateDate:nh,interpolateDiscrete:JE,interpolateHcl:hh,interpolateHclLong:mh,interpolateHsl:uh,interpolateHslLong:dh,interpolateHue:e2,interpolateLab:fh,interpolateNumber:yt,interpolateNumberArray:js,interpolateObject:rh,interpolateRgb:bi,interpolateRgbBasis:KE,interpolateRgbBasisClosed:XE,interpolateRound:Gr,interpolateString:oh,interpolateTransformCss:r2,interpolateTransformSvg:o2,interpolateZoom:l2,piecewise:bh,quantize:c2},Symbol.toStringTag,{value:"Module"}));var Mm={lab:fh,hcl:hh,"hcl-long":mh,hsl:uh,"hsl-long":dh,cubehelix:gh,"cubehelix-long":yh,rgb:bi};function vP(e){switch(e){case"lab":case"hcl":case"hcl-long":case"hsl":case"hsl-long":case"cubehelix":case"cubehelix-long":case"rgb":return Mm[e]}var t=e.type,n=e.gamma,r=Mm[t];return typeof n>"u"?r:r.gamma(n)}function gP(e,t){if("interpolate"in t&&"interpolate"in e&&typeof t.interpolate<"u"){var n=vP(t.interpolate);e.interpolate(n)}}const yP=Object.freeze(Object.defineProperty({__proto__:null,timeDay:_n,timeDays:F2,timeFriday:Gh,timeFridays:G2,timeHour:Xr,timeHours:I2,timeInterval:Fe,timeMillisecond:dr,timeMilliseconds:zh,timeMinute:Yr,timeMinutes:A2,timeMonday:Zr,timeMondays:W2,timeMonth:Jr,timeMonths:Q2,timeSaturday:Vh,timeSaturdays:V2,timeSecond:bt,timeSeconds:Bh,timeSunday:An,timeSundays:qh,timeThursday:Dn,timeThursdays:H2,timeTickInterval:nm,timeTicks:tm,timeTuesday:Uh,timeTuesdays:B2,timeWednesday:Hh,timeWednesdays:U2,timeWeek:An,timeWeeks:qh,timeYear:xt,timeYears:eT,unixDay:il,unixDays:z2,utcDay:fr,utcDays:j2,utcFriday:Xh,utcFridays:R2,utcHour:Rr,utcHours:L2,utcMillisecond:dr,utcMilliseconds:zh,utcMinute:Kr,utcMinutes:D2,utcMonday:Qr,utcMondays:q2,utcMonth:eo,utcMonths:J2,utcSaturday:Rh,utcSaturdays:Z2,utcSecond:bt,utcSeconds:Bh,utcSunday:Ln,utcSundays:Zh,utcThursday:Fn,utcThursdays:X2,utcTickInterval:em,utcTicks:Jh,utcTuesday:Yh,utcTuesdays:Y2,utcWednesday:Kh,utcWednesdays:K2,utcWeek:Ln,utcWeeks:Zh,utcYear:wt,utcYears:tT},Symbol.toStringTag,{value:"Module"}));var bP=new Date(Date.UTC(2020,1,2,3,4,5)),xP="%Y-%m-%d %H:%M";function km(e){var t=e.tickFormat(1,xP)(bP);return t==="2020-02-02 03:04"}var Om={day:_n,hour:Xr,minute:Yr,month:Jr,second:bt,week:An,year:xt},_m={day:fr,hour:Rr,minute:Kr,month:eo,second:bt,week:Ln,year:wt};function wP(e,t){if("nice"in t&&typeof t.nice<"u"&&"nice"in e){var n=t.nice;if(typeof n=="boolean")n&&e.nice();else if(typeof n=="number")e.nice(n);else{var r=e,o=km(r);if(typeof n=="string")r.nice(o?_m[n]:Om[n]);else{var i=n.interval,a=n.step,s=(o?_m[i]:Om[i]).every(a);s!=null&&r.nice(s)}}}}function $P(e,t){"padding"in e&&"padding"in t&&typeof t.padding<"u"&&e.padding(t.padding),"paddingInner"in e&&"paddingInner"in t&&typeof t.paddingInner<"u"&&e.paddingInner(t.paddingInner),"paddingOuter"in e&&"paddingOuter"in t&&typeof t.paddingOuter<"u"&&e.paddingOuter(t.paddingOuter)}function CP(e,t){if(t.reverse){var n=e.range().slice().reverse();"padding"in e,e.range(n)}}function SP(e,t){"round"in t&&typeof t.round<"u"&&(t.round&&"interpolate"in t&&typeof t.interpolate<"u"?console.warn("[visx/scale/applyRound] ignoring round: scale config contains round and interpolate. only applying interpolate. config:",t):"round"in e?e.round(t.round):"interpolate"in e&&t.round&&e.interpolate(Gr))}function EP(e,t){"unknown"in e&&"unknown"in t&&typeof t.unknown<"u"&&e.unknown(t.unknown)}function TP(e,t){if("zero"in t&&t.zero===!0){var n=e.domain(),r=n[0],o=n[1],i=o<r,a=i?[o,r]:[r,o],s=a[0],l=a[1],c=[Math.min(0,s),Math.max(0,l)];e.domain(i?c.reverse():c)}}var Nm=["domain","nice","zero","interpolate","round","range","reverse","align","base","clamp","constant","exponent","padding","unknown"],PP={domain:lP,nice:wP,zero:TP,interpolate:gP,round:SP,align:uP,base:dP,clamp:fP,constant:pP,exponent:hP,padding:$P,range:cP,reverse:CP,unknown:EP};function Xe(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=new Set(t),o=Nm.filter(function(i){return r.has(i)});return function(a,s){return typeof s<"u"&&o.forEach(function(l){PP[l](a,s)}),a}}var MP=Xe("domain","range","reverse","align","padding","round");function Am(e){return MP(ui(),e)}var kP=Xe("domain","range","reverse","align","padding","round");function Dm(e){return kP(Tp(),e)}var OP=Xe("domain","range","reverse","clamp","interpolate","nice","round","zero");function oo(e){return OP(Vs(),e)}var _P=Xe("domain","range","clamp","nice","round","unknown");function NP(e){return _P(Zs(),e)}var AP=Xe("domain","range","reverse","clamp","interpolate","nice","round");function Im(e){return AP(bm(),e)}var DP=Xe("domain","range","reverse","clamp","interpolate","nice","round");function Lm(e){return DP(xm(),e)}var IP=Xe("domain","range","reverse","base","clamp","interpolate","nice","round");function Fm(e){return IP(Ys(),e)}var LP=Xe("domain","range","reverse","clamp","exponent","interpolate","nice","round","zero");function jm(e){return LP(Ti(),e)}var FP=Xe("domain","range","reverse","unknown");function zm(e){return FP(ci(),e)}var jP=Xe("domain","range","reverse","nice","zero");function Wm(e){return jP(Js(),e)}var zP=Xe("domain","range","reverse");function Bm(e){return zP(Qs(),e)}var WP=Xe("domain","range","reverse","clamp","constant","nice","zero","round");function Um(e){return WP(Xs(),e)}var BP=Xe("domain","range","reverse");function Hm(e){return BP(el(),e)}var UP=Xe("domain","range","reverse","clamp","interpolate","nice","round","zero");function Gm(e){return UP(Fh(),e)}function io(e){if(typeof e<"u"&&"type"in e)switch(e.type){case"linear":return oo(e);case"log":return Fm(e);case"pow":return jm(e);case"sqrt":return Gm(e);case"symlog":return Um(e);case"time":return Im(e);case"utc":return Lm(e);case"quantile":return Bm(e);case"quantize":return Wm(e);case"threshold":return Hm(e);case"ordinal":return zm(e);case"point":return Dm(e);case"band":return Am(e)}return oo(e)}var HP=Xe.apply(void 0,Nm);function GP(e,t){return HP(e.copy(),t)}function VP(e){return"paddingInner"in e?"band":"padding"in e?"point":"quantiles"in e?"quantile":"base"in e?"log":"exponent"in e?e.exponent()===.5?"sqrt":"pow":"constant"in e?"symlog":"clamp"in e?e.ticks()[0]instanceof Date?km(e)?"utc":"time":"linear":"nice"in e?"quantize":"invertExtent"in e?"threshold":"ordinal"}function dl(e){if((typeof e=="function"||typeof e=="object"&&e)&&"valueOf"in e){var t=e.valueOf();if(typeof t=="number")return t}return e}function fl(e,t){var n=e;return"ticks"in n?n.ticks(t):n.domain().filter(function(r,o,i){return t==null||i.length<=t||o%Math.round((i.length-1)/t)===0})}function Vm(e){return e==null?void 0:e.toString()}var qP=new Set(["linear","pow","quantize","sqrt","symlog"]);function pl(e){return qP.has(e.type)}const YP=Object.freeze(Object.defineProperty({__proto__:null,coerceNumber:dl,createScale:io,getTicks:fl,inferScaleType:VP,scaleBand:Am,scaleCanBeZeroed:pl,scaleLinear:oo,scaleLog:Fm,scaleOrdinal:zm,scalePoint:Dm,scalePower:jm,scaleQuantile:Bm,scaleQuantize:Wm,scaleRadial:NP,scaleSqrt:Gm,scaleSymlog:Um,scaleThreshold:Hm,scaleTime:Im,scaleUtc:Lm,toString:Vm,updateScale:GP},Symbol.toStringTag,{value:"Module"}));var KP=u.createContext({});const Ot=KP;function hl(e){var t,n=e;return n&&"bandwidth"in n&&(t=n==null?void 0:n.bandwidth())!=null?t:0}function ft(e){return e!=null&&typeof e=="number"&&!Number.isNaN(e)&&Number.isFinite(e)}const qm=Jn(F1),Ym=Jn(YP);var ml=Math.PI,vl=2*ml,jn=1e-6,XP=vl-jn;function gl(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function yl(){return new gl}gl.prototype=yl.prototype={constructor:gl,moveTo:function(e,t){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)},closePath:function(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(e,t){this._+="L"+(this._x1=+e)+","+(this._y1=+t)},quadraticCurveTo:function(e,t,n,r){this._+="Q"+ +e+","+ +t+","+(this._x1=+n)+","+(this._y1=+r)},bezierCurveTo:function(e,t,n,r,o,i){this._+="C"+ +e+","+ +t+","+ +n+","+ +r+","+(this._x1=+o)+","+(this._y1=+i)},arcTo:function(e,t,n,r,o){e=+e,t=+t,n=+n,r=+r,o=+o;var i=this._x1,a=this._y1,s=n-e,l=r-t,c=i-e,d=a-t,f=c*c+d*d;if(o<0)throw new Error("negative radius: "+o);if(this._x1===null)this._+="M"+(this._x1=e)+","+(this._y1=t);else if(f>jn)if(!(Math.abs(d*s-l*c)>jn)||!o)this._+="L"+(this._x1=e)+","+(this._y1=t);else{var p=n-i,m=r-a,h=s*s+l*l,v=p*p+m*m,x=Math.sqrt(h),y=Math.sqrt(f),b=o*Math.tan((ml-Math.acos((h+f-v)/(2*x*y)))/2),$=b/y,S=b/x;Math.abs($-1)>jn&&(this._+="L"+(e+$*c)+","+(t+$*d)),this._+="A"+o+","+o+",0,0,"+ +(d*p>c*m)+","+(this._x1=e+S*s)+","+(this._y1=t+S*l)}},arc:function(e,t,n,r,o,i){e=+e,t=+t,n=+n,i=!!i;var a=n*Math.cos(r),s=n*Math.sin(r),l=e+a,c=t+s,d=1^i,f=i?r-o:o-r;if(n<0)throw new Error("negative radius: "+n);this._x1===null?this._+="M"+l+","+c:(Math.abs(this._x1-l)>jn||Math.abs(this._y1-c)>jn)&&(this._+="L"+l+","+c),n&&(f<0&&(f=f%vl+vl),f>XP?this._+="A"+n+","+n+",0,1,"+d+","+(e-a)+","+(t-s)+"A"+n+","+n+",0,1,"+d+","+(this._x1=l)+","+(this._y1=c):f>jn&&(this._+="A"+n+","+n+",0,"+ +(f>=ml)+","+d+","+(this._x1=e+n*Math.cos(o))+","+(this._y1=t+n*Math.sin(o))))},rect:function(e,t,n,r){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};function hr(e){return function(){return e}}function Km(e){this._context=e}Km.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function RP(e){return new Km(e)}function Xm(e){return e[0]}function Rm(e){return e[1]}function ZP(){var e=Xm,t=Rm,n=hr(!0),r=null,o=RP,i=null;function a(s){var l,c=s.length,d,f=!1,p;for(r==null&&(i=o(p=yl())),l=0;l<=c;++l)!(l<c&&n(d=s[l],l,s))===f&&((f=!f)?i.lineStart():i.lineEnd()),f&&i.point(+e(d,l,s),+t(d,l,s));if(p)return i=null,p+""||null}return a.x=function(s){return arguments.length?(e=typeof s=="function"?s:hr(+s),a):e},a.y=function(s){return arguments.length?(t=typeof s=="function"?s:hr(+s),a):t},a.defined=function(s){return arguments.length?(n=typeof s=="function"?s:hr(!!s),a):n},a.curve=function(s){return arguments.length?(o=s,r!=null&&(i=o(r)),a):o},a.context=function(s){return arguments.length?(s==null?r=i=null:i=o(r=s),a):r},a}var QP=Array.prototype.slice;function JP(e){return e.source}function eM(e){return e.target}function tM(e){var t=JP,n=eM,r=Xm,o=Rm,i=null;function a(){var s,l=QP.call(arguments),c=t.apply(this,l),d=n.apply(this,l);if(i||(i=s=yl()),e(i,+r.apply(this,(l[0]=c,l)),+o.apply(this,l),+r.apply(this,(l[0]=d,l)),+o.apply(this,l)),s)return i=null,s+""||null}return a.source=function(s){return arguments.length?(t=s,a):t},a.target=function(s){return arguments.length?(n=s,a):n},a.x=function(s){return arguments.length?(r=typeof s=="function"?s:hr(+s),a):r},a.y=function(s){return arguments.length?(o=typeof s=="function"?s:hr(+s),a):o},a.context=function(s){return arguments.length?(i=s??null,a):i},a}function nM(e,t,n,r,o){e.moveTo(t,n),e.bezierCurveTo(t=(t+r)/2,n,t,o,r,o)}function rM(){return tM(nM)}function Zm(e,t){e(t)}function oM(e){var t=e===void 0?{}:e,n=t.x,r=t.y,o=t.defined,i=t.curve,a=ZP();return n&&Zm(a.x,n),r&&Zm(a.y,r),o&&a.defined(o),i&&a.curve(i),a}var iM=["from","to","fill","className","innerRef"];function bl(){return bl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},bl.apply(this,arguments)}function aM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function Qm(e){var t=e.from,n=t===void 0?{x:0,y:0}:t,r=e.to,o=r===void 0?{x:1,y:1}:r,i=e.fill,a=i===void 0?"transparent":i,s=e.className,l=e.innerRef,c=aM(e,iM),d=n.x===o.x||n.y===o.y;return u.createElement("line",bl({ref:l,className:et("visx-line",s),x1:n.x,y1:n.y,x2:o.x,y2:o.y,fill:a,shapeRendering:d?"crispEdges":"auto"},c))}var sM=["children","data","x","y","fill","className","curve","innerRef","defined"];function xl(){return xl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},xl.apply(this,arguments)}function lM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function cM(e){var t=e.children,n=e.data,r=n===void 0?[]:n,o=e.x,i=e.y,a=e.fill,s=a===void 0?"transparent":a,l=e.className,c=e.curve,d=e.innerRef,f=e.defined,p=f===void 0?function(){return!0}:f,m=lM(e,sM),h=oM({x:o,y:i,defined:p,curve:c});return t?u.createElement(u.Fragment,null,t({path:h})):u.createElement("path",xl({ref:d,className:et("visx-linepath",l),d:h(r)||"",fill:s,strokeLinecap:"round"},m))}var uM=["className","innerRef"];function wl(){return wl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},wl.apply(this,arguments)}function dM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function fM(e){var t=e.className,n=e.innerRef,r=dM(e,uM);return u.createElement("rect",wl({ref:n,className:et("visx-bar",t)},r))}var pM=["children","className","innerRef","x","y","width","height","radius","all","top","bottom","left","right","topLeft","topRight","bottomLeft","bottomRight"];function $l(){return $l=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},$l.apply(this,arguments)}function hM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function mM(e){var t=e.all,n=e.bottom,r=e.bottomLeft,o=e.bottomRight,i=e.height,a=e.left,s=e.radius,l=e.right,c=e.top,d=e.topLeft,f=e.topRight,p=e.width,m=e.x,h=e.y;f=t||c||l||f,o=t||n||l||o,r=t||n||a||r,d=t||c||a||d,s=Math.max(1,Math.min(s,Math.min(p,i)/2));var v=2*s,x=("M"+(m+s)+","+h+" h"+(p-v)+`
65
65
  `+(f?"a"+s+","+s+" 0 0 1 "+s+","+s:"h"+s+"v"+s)+`
66
66
  v`+(i-v)+`
67
67
  `+(o?"a"+s+","+s+" 0 0 1 "+-s+","+s:"v"+s+"h"+-s)+`
@@ -70,17 +70,17 @@ Valid keys: `+JSON.stringify(Object.keys(N),null," "));var k=re(Y,q,oe,te,ae+".
70
70
  v`+(v-i)+`
71
71
  `+(d?"a"+s+","+s+" 0 0 1 "+s+","+-s:"v"+-s+"h"+s)+`
72
72
  z`).split(`
73
- `).join("");return x}function pM(e){var t=e.children,n=e.className,r=e.innerRef,o=e.x,i=e.y,a=e.width,s=e.height,l=e.radius,c=e.all,d=c===void 0?!1:c,f=e.top,p=f===void 0?!1:f,m=e.bottom,h=m===void 0?!1:m,v=e.left,x=v===void 0?!1:v,y=e.right,b=y===void 0?!1:y,$=e.topLeft,S=$===void 0?!1:$,w=e.topRight,T=w===void 0?!1:w,O=e.bottomLeft,P=O===void 0?!1:O,_=e.bottomRight,j=_===void 0?!1:_,F=dM(e,uM),V=fM({x:o,y:i,width:a,height:s,radius:l,all:d,top:p,bottom:h,left:x,right:b,topLeft:S,topRight:T,bottomLeft:P,bottomRight:j});return t?u.createElement(u.Fragment,null,t({path:V})):u.createElement("path",wl({ref:r,className:et("visx-bar-rounded",n),d:V},F))}function hM(e){return typeof(e==null?void 0:e.x)=="number"?e==null?void 0:e.x:0}function mM(e){return typeof(e==null?void 0:e.y)=="number"?e==null?void 0:e.y:0}function vM(e){return e==null?void 0:e.source}function gM(e){return e==null?void 0:e.target}var yM=["className","children","data","innerRef","path","x","y","source","target"];function $l(){return $l=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},$l.apply(this,arguments)}function bM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function xM(e){var t=e.source,n=e.target,r=e.x,o=e.y;return function(i){var a=eM();return a.x(r),a.y(o),a.source(t),a.target(n),a(i)}}function wM(e){var t=e.className,n=e.children,r=e.data,o=e.innerRef,i=e.path,a=e.x,s=a===void 0?mM:a,l=e.y,c=l===void 0?hM:l,d=e.source,f=d===void 0?vM:d,p=e.target,m=p===void 0?gM:p,h=bM(e,yM),v=i||xM({source:f,target:m,x:s,y:c});return n?u.createElement(u.Fragment,null,n({path:v})):u.createElement("path",$l({ref:o,className:et("visx-link visx-link-horizontal-diagonal",t),d:v(r)||""},h))}var $M=["AxisComponent"];function ki(){return ki=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ki.apply(this,arguments)}function CM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function SM(e){var t,n,r,o,i,a,s,l=e.AxisComponent,c=CM(e,$M),d=u.useContext(Ot),f=d.theme,p=d.xScale,m=d.yScale,h=d.margin,v=d.width,x=d.height,y=c.orientation,b=u.useMemo(function(){var P,_,j,F;return y==="left"||y==="right"?f==null||(P=f.axisStyles)==null||(_=P.y)==null?void 0:_[y]:f==null||(j=f.axisStyles)==null||(F=j.x)==null?void 0:F[y]},[f,y]),$=c.tickLabelProps,S=u.useMemo(function(){return $||b?function(P,_,j){return ki({},b==null?void 0:b.tickLabel,{width:y==="left"||y==="right"?h==null?void 0:h[y]:void 0},typeof $=="function"?$(P,_,j):$)}:void 0},[$,b,y,h]),w=y==="bottom"?(x??0)-((t=h==null?void 0:h.bottom)!=null?t:0):y==="top"&&(n=h==null?void 0:h.top)!=null?n:0,T=y==="left"?(r=h==null?void 0:h.left)!=null?r:0:y==="right"?(v??0)-((o=h==null?void 0:h.right)!=null?o:0):0,O=y==="left"||y==="right"?m:p;return O?u.createElement(l,ki({top:w,left:T,labelProps:b==null?void 0:b.axisLabel,stroke:b==null||(i=b.axisLine)==null?void 0:i.stroke,strokeWidth:b==null||(a=b.axisLine)==null?void 0:a.strokeWidth,tickLength:b==null?void 0:b.tickLength,tickStroke:b==null||(s=b.tickLine)==null?void 0:s.stroke},c,{tickLabelProps:S,scale:O})):null}var Oi={};Oi.__esModule=!0;var EM=Oi.default=OM,TM=Qm(u),PM=Qm(Qo),MM=["from","to","fill","className","innerRef"];function Qm(e){return e&&e.__esModule?e:{default:e}}function Cl(){return Cl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Cl.apply(this,arguments)}function kM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function OM(e){var t=e.from,n=t===void 0?{x:0,y:0}:t,r=e.to,o=r===void 0?{x:1,y:1}:r,i=e.fill,a=i===void 0?"transparent":i,s=e.className,l=e.innerRef,c=kM(e,MM),d=n.x===o.x||n.y===o.y;return TM.default.createElement("line",Cl({ref:l,className:(0,PM.default)("visx-line",s),x1:n.x,y1:n.y,x2:o.x,y2:o.y,fill:a,shapeRendering:d?"crispEdges":"auto"},c))}var _i={};_i.__esModule=!0,_i.default=_M;function _M(e){return"bandwidth"in e?e.bandwidth():0}var NM=rv,Jm=io(Zo),ev=io(u),AM=io(Qo),DM=io(Oi),IM=Vm,tv=vp,nv=qm,LM=io(_i),FM=["top","left","scale","width","stroke","strokeWidth","strokeDasharray","className","children","numTicks","lineStyle","offset","tickValues"];function io(e){return e&&e.__esModule?e:{default:e}}function Sl(){return Sl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Sl.apply(this,arguments)}function jM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function rv(e){var t=e.top,n=t===void 0?0:t,r=e.left,o=r===void 0?0:r,i=e.scale,a=e.width,s=e.stroke,l=s===void 0?"#eaf0f6":s,c=e.strokeWidth,d=c===void 0?1:c,f=e.strokeDasharray,p=e.className,m=e.children,h=e.numTicks,v=h===void 0?10:h,x=e.lineStyle,y=e.offset,b=e.tickValues,$=jM(e,FM),S=b??(0,nv.getTicks)(i,v),w=(y??0)+(0,LM.default)(i)/2,T=S.map(function(O,P){var _,j=((_=(0,nv.coerceNumber)(i(O)))!=null?_:0)+w;return{index:P,from:new tv.Point({x:0,y:j}),to:new tv.Point({x:a,y:j})}});return ev.default.createElement(IM.Group,{className:(0,AM.default)("visx-rows",p),top:n,left:o},m?m({lines:T}):T.map(function(O){var P=O.from,_=O.to,j=O.index;return ev.default.createElement(DM.default,Sl({key:"row-line-"+j,from:P,to:_,stroke:l,strokeWidth:d,strokeDasharray:f,style:x},$))}))}rv.propTypes={tickValues:Jm.default.array,width:Jm.default.number.isRequired};var zM=lv,ov=ao(Zo),iv=ao(u),WM=ao(Qo),BM=ao(Oi),UM=Vm,av=vp,sv=qm,HM=ao(_i),GM=["top","left","scale","height","stroke","strokeWidth","strokeDasharray","className","numTicks","lineStyle","offset","tickValues","children"];function ao(e){return e&&e.__esModule?e:{default:e}}function El(){return El=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},El.apply(this,arguments)}function VM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function lv(e){var t=e.top,n=t===void 0?0:t,r=e.left,o=r===void 0?0:r,i=e.scale,a=e.height,s=e.stroke,l=s===void 0?"#eaf0f6":s,c=e.strokeWidth,d=c===void 0?1:c,f=e.strokeDasharray,p=e.className,m=e.numTicks,h=m===void 0?10:m,v=e.lineStyle,x=e.offset,y=e.tickValues,b=e.children,$=VM(e,GM),S=y??(0,sv.getTicks)(i,h),w=(x??0)+(0,HM.default)(i)/2,T=S.map(function(O,P){var _,j=((_=(0,sv.coerceNumber)(i(O)))!=null?_:0)+w;return{index:P,from:new av.Point({x:j,y:0}),to:new av.Point({x:j,y:a})}});return iv.default.createElement(UM.Group,{className:(0,WM.default)("visx-columns",p),top:n,left:o},b?b({lines:T}):T.map(function(O){var P=O.from,_=O.to,j=O.index;return iv.default.createElement(BM.default,El({key:"column-line-"+j,from:P,to:_,stroke:l,strokeWidth:d,strokeDasharray:f,style:v},$))}))}lv.propTypes={tickValues:ov.default.array,height:ov.default.number.isRequired};var qM=["rows","columns","GridRowsComponent","GridColumnsComponent"];function Ni(){return Ni=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ni.apply(this,arguments)}function YM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function cv(e){var t=e.rows,n=t===void 0?!0:t,r=e.columns,o=r===void 0?!0:r,i=e.GridRowsComponent,a=e.GridColumnsComponent,s=YM(e,qM),l=u.useContext(Ot),c=l.theme,d=l.xScale,f=l.yScale,p=l.margin,m=l.innerWidth,h=l.innerHeight,v=c==null?void 0:c.gridStyles;return u.createElement(u.Fragment,null,n&&f&&m!=null&&u.createElement(i,Ni({left:p==null?void 0:p.left,lineStyle:v,width:m,scale:f},s)),o&&d&&h!=null&&u.createElement(a,Ni({top:p==null?void 0:p.top,lineStyle:v,height:h,scale:d},s)))}cv.propTypes={rows:ne.bool,columns:ne.bool};var KM={top:"top",left:"left",right:"right",bottom:"bottom"};const $t=KM;function XM(e){var t=e.labelOffset,n=e.labelProps,r=e.orientation,o=e.range,i=e.tickLabelFontSize,a=e.tickLength,s=r===$t.left||r===$t.top?-1:1,l,c,d;if(r===$t.top||r===$t.bottom){var f=r===$t.bottom&&typeof n.fontSize=="number"?n.fontSize:0;l=(Number(o[0])+Number(o[o.length-1]))/2,c=s*(a+t+i+f)}else l=s*((Number(o[0])+Number(o[o.length-1]))/2),c=-(a+t),d="rotate("+s*90+")";return{x:l,y:c,transform:d}}function so(){return so=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},so.apply(this,arguments)}function RM(e){var t=e.hideTicks,n=e.horizontal,r=e.orientation,o=e.tickClassName,i=e.tickComponent,a=e.tickLabelProps,s=e.tickStroke,l=s===void 0?"#222":s,c=e.tickTransform,d=e.ticks,f=e.strokeWidth,p=e.tickLineProps;return d.map(function(m){var h,v=m.value,x=m.index,y=m.from,b=m.to,$=m.formattedValue,S=(h=a[x])!=null?h:{},w=Math.max(10,typeof S.fontSize=="number"&&S.fontSize||0),T=b.y+(n&&r!==$t.top?w:0);return u.createElement(En,{key:"visx-tick-"+v+"-"+x,className:et("visx-axis-tick",o),transform:c},!t&&u.createElement(Zm,so({from:y,to:b,stroke:l,strokeWidth:f,strokeLinecap:"square"},p)),i?i(so({},S,{x:b.x,y:T,formattedValue:$})):u.createElement(gs,so({x:b.x,y:T},S),$))})}function Ai(){return Ai=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ai.apply(this,arguments)}var uv={textAnchor:"middle",fontFamily:"Arial",fontSize:10,fill:"#222"};function ZM(e){var t=e.axisFromPoint,n=e.axisLineClassName,r=e.axisToPoint,o=e.hideAxisLine,i=e.hideTicks,a=e.horizontal,s=e.label,l=s===void 0?"":s,c=e.labelClassName,d=e.labelOffset,f=d===void 0?14:d,p=e.labelProps,m=p===void 0?uv:p,h=e.orientation,v=h===void 0?$t.bottom:h,x=e.scale,y=e.stroke,b=y===void 0?"#222":y,$=e.strokeDasharray,S=e.strokeWidth,w=S===void 0?1:S,T=e.tickClassName,O=e.tickComponent,P=e.tickLineProps,_=e.tickLabelProps,j=e.tickLength,F=j===void 0?8:j,V=e.tickStroke,R=V===void 0?"#222":V,X=e.tickTransform,C=e.ticks,I=e.ticksComponent,H=I===void 0?RM:I,B=Ai({},uv,typeof _=="object"?_:null),A=C.map(function(z){var J=z.value,Q=z.index;return typeof _=="function"?_(J,Q,C):B}),N=Math.max.apply(Math,[10].concat(A.map(function(z){return typeof z.fontSize=="number"?z.fontSize:0})));return u.createElement(u.Fragment,null,H({hideTicks:i,horizontal:a,orientation:v,scale:x,tickClassName:T,tickComponent:O,tickLabelProps:A,tickStroke:R,tickTransform:X,ticks:C,strokeWidth:w,tickLineProps:P}),!o&&u.createElement(Zm,{className:et("visx-axis-line",n),from:t,to:r,stroke:b,strokeWidth:w,strokeDasharray:$}),l&&u.createElement(gs,Ai({className:et("visx-axis-label",c)},XM({labelOffset:f,labelProps:m,orientation:v,range:x.range(),tickLabelFontSize:N,tickLength:F}),m),l))}function QM(e,t){t===void 0&&(t="center");var n=e;if(t!=="start"&&"bandwidth"in n){var r=n.bandwidth();return t==="center"&&(r/=2),n.round()&&(r=Math.round(r)),function(o){var i=n(o);return typeof i=="number"?i+r:i}}return e}function JM(e){var t=e;return"tickFormat"in t?t.tickFormat():Gm}function Di(e,t){var n=e.x,r=e.y;return new an(t?{x:n,y:r}:{x:r,y:n})}function Tl(){return Tl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Tl.apply(this,arguments)}var Pl=0;function ek(e){return e===void 0&&(e=Pl),typeof e=="number"?{start:e,end:e}:Tl({start:Pl,end:Pl},e)}var tk=["children","axisClassName","hideAxisLine","hideTicks","hideZero","left","numTicks","orientation","rangePadding","scale","tickFormat","tickLength","tickValues","top"];function Ml(){return Ml=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ml.apply(this,arguments)}function nk(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function kl(e){var t=e.children,n=t===void 0?ZM:t,r=e.axisClassName,o=e.hideAxisLine,i=o===void 0?!1:o,a=e.hideTicks,s=a===void 0?!1:a,l=e.hideZero,c=l===void 0?!1:l,d=e.left,f=d===void 0?0:d,p=e.numTicks,m=p===void 0?10:p,h=e.orientation,v=h===void 0?$t.bottom:h,x=e.rangePadding,y=x===void 0?0:x,b=e.scale,$=e.tickFormat,S=e.tickLength,w=S===void 0?8:S,T=e.tickValues,O=e.top,P=O===void 0?0:O,_=nk(e,tk),j=$??JM(b),F=v===$t.left,V=v===$t.top,R=V||v===$t.bottom,X=QM(b),C=F||V?-1:1,I=b.range(),H=ek(y),B=Di({x:Number(I[0])+.5-H.start,y:0},R),A=Di({x:Number(I[I.length-1])+.5+H.end,y:0},R),N=(T??dl(b,m)).filter(function(J){return!c||J!==0&&J!=="0"}).map(function(J,Q){return{value:J,index:Q}}),z=N.map(function(J){var Q=J.value,oe=J.index,te=ul(X(Q));return{value:Q,index:oe,from:Di({x:te,y:0},R),to:Di({x:te,y:w*C},R),formattedValue:j(Q,oe,N)}});return u.createElement(En,{className:et("visx-axis",r),top:P,left:f},n(Ml({},_,{axisFromPoint:B,axisToPoint:A,hideAxisLine:i,hideTicks:s,hideZero:c,horizontal:R,numTicks:m,orientation:v,rangePadding:y,scale:b,tickFormat:j,tickLength:w,tickPosition:X,tickSign:C,ticks:z})))}function Ol(){return Ol=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ol.apply(this,arguments)}function dv(e){return u.createElement(SM,Ol({AxisComponent:kl},e))}function _l(){return _l=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},_l.apply(this,arguments)}function rk(e){return u.createElement(cv,_l({GridRowsComponent:NM,GridColumnsComponent:zM},e))}var ok=["tooltipOpen"];function ik(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function Ii(){return Ii=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ii.apply(this,arguments)}function Nl(e){var t=u.useState(Ii({tooltipOpen:!1},e)),n=t[0],r=t[1],o=u.useCallback(function(a){return r(typeof a=="function"?function(s){s.tooltipOpen;var l=ik(s,ok);return Ii({},a(l),{tooltipOpen:!0})}:{tooltipOpen:!0,tooltipLeft:a.tooltipLeft,tooltipTop:a.tooltipTop,tooltipData:a.tooltipData})},[r]),i=u.useCallback(function(){return r({tooltipOpen:!1,tooltipLeft:void 0,tooltipTop:void 0,tooltipData:void 0})},[r]);return{tooltipOpen:n.tooltipOpen,tooltipLeft:n.tooltipLeft,tooltipTop:n.tooltipTop,tooltipData:n.tooltipData,updateTooltip:r,showTooltip:o,hideTooltip:i}}function ak(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Al(e,t)}function Al(e,t){return Al=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},Al(e,t)}var fv=function(e){ak(t,e);function t(){return e.apply(this,arguments)||this}var n=t.prototype;return n.componentWillUnmount=function(){this.node&&document.body&&(document.body.removeChild(this.node),delete this.node)},n.render=function(){return!this.node&&typeof document<"u"&&(this.node=document.createElement("div"),this.props.zIndex!=null&&(this.node.style.zIndex=""+this.props.zIndex),document.body.append(this.node)),this.node?At.createPortal(this.props.children,this.node):null},t}(u.PureComponent);fv.propTypes={zIndex:ne.oneOfType([ne.number,ne.string])};var sk=["className","top","left","offsetLeft","offsetTop","style","children","unstyled","applyPositionStyle"];function Li(){return Li=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Li.apply(this,arguments)}function lk(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}var Dl={position:"absolute",backgroundColor:"white",color:"#666666",padding:".3rem .5rem",borderRadius:"3px",fontSize:"14px",boxShadow:"0 1px 2px rgba(33,33,33,0.2)",lineHeight:"1em",pointerEvents:"none"},Il=u.forwardRef(function(e,t){var n=e.className,r=e.top,o=e.left,i=e.offsetLeft,a=i===void 0?10:i,s=e.offsetTop,l=s===void 0?10:s,c=e.style,d=c===void 0?Dl:c,f=e.children,p=e.unstyled,m=p===void 0?!1:p,h=e.applyPositionStyle,v=h===void 0?!1:h,x=lk(e,sk);return u.createElement("div",Li({ref:t,className:et("visx-tooltip",n),style:Li({top:r==null||l==null?r:r+l,left:o==null||a==null?o:o+a},v&&{position:"absolute"},!m&&d)},x),f)});Il.propTypes={children:ne.node,className:ne.string,left:ne.number,offsetLeft:ne.number,offsetTop:ne.number,top:ne.number,applyPositionStyle:ne.bool,unstyled:ne.bool},Il.displayName="Tooltip";const pv=Il;function Ll(){return Ll=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ll.apply(this,arguments)}function ck(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function uk(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Fl(e,t)}function Fl(e,t){return Fl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},Fl(e,t)}var hv={top:0,right:0,bottom:0,left:0,width:0,height:0};function dk(e){var t;return t=function(n){uk(r,n);function r(i){var a;return a=n.call(this,i)||this,a.state={rect:void 0,parentRect:void 0},a.nodeRef=u.createRef(),a.getRects=a.getRects.bind(ck(a)),a}var o=r.prototype;return o.componentDidMount=function(){var a,s=this;this.node=(a=this.nodeRef)!=null&&a.current?this.nodeRef.current:At.findDOMNode(this),this.setState(function(){return s.getRects()})},o.getRects=function(){if(!this.node)return this.state;var a=this.node,s=a.parentNode,l=a.getBoundingClientRect?a.getBoundingClientRect():hv,c=s!=null&&s.getBoundingClientRect?s.getBoundingClientRect():hv;return{rect:l,parentRect:c}},o.render=function(){return u.createElement(e,Ll({nodeRef:this.nodeRef,getRects:this.getRects},this.state,this.props))},r}(u.PureComponent),t.displayName="withBoundingRects("+(e.displayName||"")+")",t}var mv=u.createContext({isFlippedVertically:!1,isFlippedHorizontally:!1}),fk=mv.Provider;mv.Consumer;var pk=["children","getRects","left","offsetLeft","offsetTop","parentRect","rect","style","top","unstyled","nodeRef"];function Fi(){return Fi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Fi.apply(this,arguments)}function hk(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function vv(e){var t=e.children;e.getRects;var n=e.left,r=n===void 0?0:n,o=e.offsetLeft,i=o===void 0?10:o,a=e.offsetTop,s=a===void 0?10:a,l=e.parentRect,c=e.rect,d=e.style,f=d===void 0?Dl:d,p=e.top,m=p===void 0?0:p,h=e.unstyled,v=h===void 0?!1:h,x=e.nodeRef,y=hk(e,pk),b,$=!1,S=!1;if(c&&l){var w=r,T=m;if(l.width){var O=w+i+c.width-l.width,P=c.width-w-i;$=O>0&&O>P}else{var _=w+i+c.width-window.innerWidth,j=c.width-w-i;$=_>0&&_>j}if(l.height){var F=T+s+c.height-l.height,V=c.height-T-s;S=F>0&&F>V}else S=T+s+c.height>window.innerHeight;w=$?w-c.width-i:w+i,T=S?T-c.height-s:T+s,w=Math.round(w),T=Math.round(T),b="translate("+w+"px, "+T+"px)"}return u.createElement(pv,Fi({ref:x,style:Fi({left:0,top:0,transform:b},!v&&f)},y),u.createElement(fk,{value:{isFlippedVertically:!S,isFlippedHorizontally:!$}},t))}vv.propTypes={nodeRef:ne.oneOfType([ne.string,ne.func,ne.object])};const mk=dk(vv);var vk=["detectBounds","zIndex"],gk=["left","top","detectBounds","zIndex"];function jl(){return jl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},jl.apply(this,arguments)}function gv(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function zl(e){var t=e===void 0?{}:e,n=t.detectBounds,r=n===void 0?!0:n,o=t.zIndex,i=gv(t,vk),a=YS(i),s=a[0],l=a[1],c=a[2],d=u.useState(!1),f=d[0],p=d[1];u.useEffect(function(){p(!1)},[]);var m=u.useMemo(function(){return function(h){var v=h.left,x=v===void 0?0:v,y=h.top,b=y===void 0?0:y,$=h.detectBounds,S=h.zIndex,w=gv(h,gk),T=$??r,O=S??o,P=T?mk:pv,_=f?0:window.scrollX,j=f?0:window.scrollY,F=x+(l.left||0)+_,V=b+(l.top||0)+j;return u.createElement(fv,{zIndex:O},u.createElement(P,jl({left:F,top:V},w)))}},[r,o,l.left,l.top,f]);return{containerRef:s,containerBounds:l,forceRefreshBounds:c,TooltipInPortal:m}}var yk=u.createContext(null);const lo=yk;var bk=["debounce","detectBounds","horizontalCrosshairStyle","glyphStyle","renderTooltip","renderGlyph","resizeObserverPolyfill","scroll","showDatumGlyph","showHorizontalCrosshair","showSeriesGlyphs","showVerticalCrosshair","snapTooltipToDatumX","snapTooltipToDatumY","verticalCrosshairStyle","zIndex"],xk=["x","y"];function yv(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function Vt(){return Vt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Vt.apply(this,arguments)}var Wl={position:"absolute",pointerEvents:"none",fontSize:0,lineHeight:0},wk={position:"absolute",left:0,top:0,opacity:0,width:0,height:0,pointerEvents:"none"};function bv(e){var t=u.useContext(Ot)||{},n=t.theme;return u.createElement("circle",Vt({cx:e.x,cy:e.y,r:e.size,fill:e.color,stroke:n==null?void 0:n.backgroundColor,strokeWidth:1.5,paintOrder:"fill"},e.glyphStyle))}bv.propTypes={isNearestDatum:ne.bool.isRequired};function $k(e){return u.createElement(bv,e)}function xv(e){var t,n,r,o,i,a,s,l,c,d,f,p,m,h=e.debounce,v=e.detectBounds,x=e.horizontalCrosshairStyle,y=e.glyphStyle,b=e.renderTooltip,$=e.renderGlyph,S=$===void 0?$k:$,w=e.resizeObserverPolyfill,T=e.scroll,O=T===void 0?!0:T,P=e.showDatumGlyph,_=P===void 0?!1:P,j=e.showHorizontalCrosshair,F=j===void 0?!1:j,V=e.showSeriesGlyphs,R=V===void 0?!1:V,X=e.showVerticalCrosshair,C=X===void 0?!1:X,I=e.snapTooltipToDatumX,H=I===void 0?!1:I,B=e.snapTooltipToDatumY,A=B===void 0?!1:B,N=e.verticalCrosshairStyle,z=e.zIndex,J=yv(e,bk),Q=u.useContext(Ot)||{},oe=Q.colorScale,te=Q.theme,ae=Q.innerHeight,Y=Q.innerWidth,le=Q.margin,U=Q.xScale,q=Q.yScale,re=Q.dataRegistry,k=Q.resizeObserverPolyfill,de=u.useContext(lo),pe=zl({debounce:h,detectBounds:v,polyfill:k||w,scroll:O,zIndex:z}),Ce=pe.containerRef,ke=pe.TooltipInPortal,je=pe.forceRefreshBounds,_t=u.useCallback(function(Qe){var pt;Ce((pt=Qe==null?void 0:Qe.parentElement)!=null?pt:null)},[Ce]),mn=de!=null&&de.tooltipOpen?b(Vt({},de,{colorScale:oe})):null,Ze=(de==null?void 0:de.tooltipOpen)&&mn!=null,qt=u.useRef(!1);u.useEffect(function(){Ze&&!qt.current&&je(),qt.current=Ze},[Ze,je]);var yr=de==null?void 0:de.tooltipLeft,Le=de==null?void 0:de.tooltipTop,Ri=U?pl(U):0,Zi=q?pl(q):0,fo=u.useCallback(function(Qe,pt){var Kt,Xt,lt=re==null?void 0:re.get(Qe),Bn=lt==null?void 0:lt.xAccessor,Un=lt==null?void 0:lt.yAccessor,xr=U&&Bn?(Kt=Number(U(Bn(pt)))+Ri/2)!=null?Kt:0:void 0,wr=q&&Un?(Xt=Number(q(Un(pt)))+Zi/2)!=null?Xt:0:void 0;return{left:xr,top:wr}},[re,Ri,Zi,U,q]),rt=de==null||(t=de.tooltipData)==null?void 0:t.nearestDatum,vn=(n=rt==null?void 0:rt.key)!=null?n:"";if(Ze&&rt&&(H||A)){var zn=fo(vn,rt.datum),Wn=zn.left,po=zn.top;yr=H&&ft(Wn)?Wn:yr,Le=A&&ft(po)?po:Le}var br=[];if(Ze&&(_||R)){var Qi,Ji=Number((Qi=y==null?void 0:y.radius)!=null?Qi:4);if(R){var ho,ea;Object.values((ho=de==null||(ea=de.tooltipData)==null?void 0:ea.datumByKey)!=null?ho:{}).forEach(function(Qe){var pt,Kt,Xt,lt=Qe.key,Bn=Qe.datum,Un=Qe.index,xr=(pt=(Kt=oe==null?void 0:oe(lt))!=null?Kt:te==null||(Xt=te.htmlLabel)==null?void 0:Xt.color)!=null?pt:"#222",wr=fo(lt,Bn),ia=wr.left,aa=wr.top;!ft(ia)||!ft(aa)||br.push({key:lt,color:xr,datum:Bn,index:Un,size:Ji,x:ia,y:aa,glyphStyle:y,isNearestDatum:rt?rt.key===lt:!1})})}else if(rt){var ta=fo(vn,rt.datum),Nt=ta.left,Yt=ta.top;if(ft(Nt)&&ft(Yt)){var mo,vo,go,na,ra,st,oa=(mo=(vo=(go=(na=vn&&(oe==null?void 0:oe(vn)))!=null?na:null)!=null?go:te==null||(ra=te.gridStyles)==null?void 0:ra.stroke)!=null?vo:te==null||(st=te.htmlLabel)==null?void 0:st.color)!=null?mo:"#222";br.push({key:vn,color:oa,datum:rt.datum,index:rt.index,size:Ji,x:Nt,y:Yt,glyphStyle:y,isNearestDatum:!0})}}}return u.createElement(u.Fragment,null,u.createElement("svg",{ref:_t,style:wk}),Ze&&u.createElement(u.Fragment,null,C&&u.createElement(ke,{className:"visx-crosshair visx-crosshair-vertical",left:yr,top:le==null?void 0:le.top,offsetLeft:0,offsetTop:0,detectBounds:!1,style:Wl},u.createElement("svg",{width:"1",height:ae,overflow:"visible"},u.createElement("line",Vt({x1:0,x2:0,y1:0,y2:ae,strokeWidth:1.5,stroke:(r=(o=te==null||(i=te.gridStyles)==null?void 0:i.stroke)!=null?o:te==null||(a=te.htmlLabel)==null?void 0:a.color)!=null?r:"#222"},N)))),F&&u.createElement(ke,{className:"visx-crosshair visx-crosshair-horizontal",left:le==null?void 0:le.left,top:Le,offsetLeft:0,offsetTop:0,detectBounds:!1,style:Wl},u.createElement("svg",{width:Y,height:"1",overflow:"visible"},u.createElement("line",Vt({x1:0,x2:Y,y1:0,y2:0,strokeWidth:1.5,stroke:(s=(l=te==null||(c=te.gridStyles)==null?void 0:c.stroke)!=null?l:te==null||(d=te.htmlLabel)==null?void 0:d.color)!=null?s:"#222"},x)))),br.map(function(Qe,pt){var Kt=Qe.x,Xt=Qe.y,lt=yv(Qe,xk);return u.createElement(ke,{key:pt,className:"visx-tooltip-glyph",left:Kt,top:Xt,offsetLeft:0,offsetTop:0,detectBounds:!1,style:Wl},u.createElement("svg",{overflow:"visible"},S(Vt({x:0,y:0},lt))))}),u.createElement(ke,Vt({left:yr,top:Le,style:Vt({},Dl,{background:(f=te==null?void 0:te.backgroundColor)!=null?f:"white",boxShadow:"0 1px 2px "+(te!=null&&(p=te.htmlLabel)!=null&&p.color?(te==null||(m=te.htmlLabel)==null?void 0:m.color)+"55":"#22222255")},te==null?void 0:te.htmlLabel)},J),mn)))}xv.propTypes={renderTooltip:ne.func.isRequired,renderGlyph:ne.func,snapTooltipToDatumX:ne.bool,snapTooltipToDatumY:ne.bool,showVerticalCrosshair:ne.bool,showHorizontalCrosshair:ne.bool,showDatumGlyph:ne.bool,showSeriesGlyphs:ne.bool};function wv(e){var t=u.useContext(lo);return t!=null&&t.tooltipOpen?u.createElement(xv,e):null}wv.propTypes={renderTooltip:ne.func.isRequired,renderGlyph:ne.func,snapTooltipToDatumX:ne.bool,snapTooltipToDatumY:ne.bool,showVerticalCrosshair:ne.bool,showHorizontalCrosshair:ne.bool,showDatumGlyph:ne.bool,showSeriesGlyphs:ne.bool};var Ck=ti,Sk=function(){return Ck.Date.now()},Ek=Sk,Tk=/\s/;function Pk(e){for(var t=e.length;t--&&Tk.test(e.charAt(t)););return t}var Mk=Pk,kk=Mk,Ok=/^\s+/;function _k(e){return e&&e.slice(0,kk(e)+1).replace(Ok,"")}var Nk=_k;function Ak(e){return e!=null&&typeof e=="object"}var Dk=Ak,Ik=ip,Lk=Dk,Fk="[object Symbol]";function jk(e){return typeof e=="symbol"||Lk(e)&&Ik(e)==Fk}var zk=jk,Wk=Nk,$v=ni,Bk=zk,Cv=0/0,Uk=/^[-+]0x[0-9a-f]+$/i,Hk=/^0b[01]+$/i,Gk=/^0o[0-7]+$/i,Vk=parseInt;function qk(e){if(typeof e=="number")return e;if(Bk(e))return Cv;if($v(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=$v(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=Wk(e);var n=Hk.test(e);return n||Gk.test(e)?Vk(e.slice(2),n?2:8):Uk.test(e)?Cv:+e}var Yk=qk,Kk=ni,Bl=Ek,Sv=Yk,Xk="Expected a function",Rk=Math.max,Zk=Math.min;function Qk(e,t,n){var r,o,i,a,s,l,c=0,d=!1,f=!1,p=!0;if(typeof e!="function")throw new TypeError(Xk);t=Sv(t)||0,Kk(n)&&(d=!!n.leading,f="maxWait"in n,i=f?Rk(Sv(n.maxWait)||0,t):i,p="trailing"in n?!!n.trailing:p);function m(T){var O=r,P=o;return r=o=void 0,c=T,a=e.apply(P,O),a}function h(T){return c=T,s=setTimeout(y,t),d?m(T):a}function v(T){var O=T-l,P=T-c,_=t-O;return f?Zk(_,i-P):_}function x(T){var O=T-l,P=T-c;return l===void 0||O>=t||O<0||f&&P>=i}function y(){var T=Bl();if(x(T))return b(T);s=setTimeout(y,v(T))}function b(T){return s=void 0,p&&r?m(T):(r=o=void 0,a)}function $(){s!==void 0&&clearTimeout(s),c=0,r=l=o=s=void 0}function S(){return s===void 0?a:b(Bl())}function w(){var T=Bl(),O=x(T);if(r=arguments,o=this,l=T,O){if(s===void 0)return h(l);if(f)return clearTimeout(s),s=setTimeout(y,t),m(l)}return s===void 0&&(s=setTimeout(y,t)),a}return w.cancel=$,w.flush=S,w}var Ev=Qk;const Tv=Qn(Ev);var Jk=kv,dn=Mv(Zo),eO=Mv(Ev),mr=nO(u),tO=["className","children","debounceTime","ignoreDimensions","parentSizeStyles","enableDebounceLeadingCall","resizeObserverPolyfill"];function Pv(e){if(typeof WeakMap!="function")return null;var t=new WeakMap,n=new WeakMap;return(Pv=function(o){return o?n:t})(e)}function nO(e,t){if(!t&&e&&e.__esModule)return e;if(e===null||typeof e!="object"&&typeof e!="function")return{default:e};var n=Pv(t);if(n&&n.has(e))return n.get(e);var r={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(i!=="default"&&Object.prototype.hasOwnProperty.call(e,i)){var a=o?Object.getOwnPropertyDescriptor(e,i):null;a&&(a.get||a.set)?Object.defineProperty(r,i,a):r[i]=e[i]}return r.default=e,n&&n.set(e,r),r}function Mv(e){return e&&e.__esModule?e:{default:e}}function ji(){return ji=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ji.apply(this,arguments)}function rO(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}var oO=[],iO={width:"100%",height:"100%"};function kv(e){var t=e.className,n=e.children,r=e.debounceTime,o=r===void 0?300:r,i=e.ignoreDimensions,a=i===void 0?oO:i,s=e.parentSizeStyles,l=s===void 0?iO:s,c=e.enableDebounceLeadingCall,d=c===void 0?!0:c,f=e.resizeObserverPolyfill,p=rO(e,tO),m=(0,mr.useRef)(null),h=(0,mr.useRef)(0),v=(0,mr.useState)({width:0,height:0,top:0,left:0}),x=v[0],y=v[1],b=(0,mr.useMemo)(function(){var $=Array.isArray(a)?a:[a];return(0,eO.default)(function(S){y(function(w){var T=Object.keys(w),O=T.filter(function(_){return w[_]!==S[_]}),P=O.every(function(_){return $.includes(_)});return P?w:S})},o,{leading:d})},[o,d,a]);return(0,mr.useEffect)(function(){var $=f||window.ResizeObserver,S=new $(function(w){w.forEach(function(T){var O,P=(O=T==null?void 0:T.contentRect)!=null?O:{},_=P.left,j=P.top,F=P.width,V=P.height;h.current=window.requestAnimationFrame(function(){b({width:F,height:V,top:j,left:_})})})});return m.current&&S.observe(m.current),function(){window.cancelAnimationFrame(h.current),S.disconnect(),b.cancel()}},[b,f]),mr.default.createElement("div",ji({style:l,ref:m,className:t},p),n(ji({},x,{ref:m.current,resize:b})))}kv.propTypes={className:dn.default.string,debounceTime:dn.default.number,enableDebounceLeadingCall:dn.default.bool,ignoreDimensions:dn.default.oneOfType([dn.default.any,dn.default.arrayOf(dn.default.any)]),children:dn.default.func.isRequired};var aO=u.createContext(null);const Ov=aO;function fn(e,t,n){var r=u.useContext(Ov),o=u.useRef();o.current=n;var i=u.useCallback(function(a,s,l){r&&r.emit(a,{event:s,svgPoint:lE(s),source:l})},[r]);return u.useEffect(function(){if(r&&e&&t){var a=function(l){var c;(!o.current||l!=null&&l.source&&(c=o.current)!=null&&c.includes(l.source))&&t(l)};return r.on(e,a),function(){return r==null?void 0:r.off(e,a)}}},[r,e,t]),r?i:null}function sO(e){return{all:e=e||new Map,on:function(t,n){var r=e.get(t);r&&r.push(n)||e.set(t,[n])},off:function(t,n){var r=e.get(t);r&&r.splice(r.indexOf(n)>>>0,1)},emit:function(t,n){(e.get(t)||[]).slice().map(function(r){r(n)}),(e.get("*")||[]).slice().map(function(r){r(t,n)})}}}function lO(e){var t=e.children,n=u.useMemo(function(){return sO()},[]);return u.createElement(Ov.Provider,{value:n},t)}function Ul(){return Ul=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ul.apply(this,arguments)}function _v(e){var t=e.hideTooltipDebounceMs,n=t===void 0?400:t,r=e.children,o=Nl(void 0),i=o.tooltipOpen,a=o.tooltipLeft,s=o.tooltipTop,l=o.tooltipData,c=o.updateTooltip,d=o.hideTooltip,f=u.useRef(null);function p(){f.current&&(f.current.cancel(),f.current=null)}u.useEffect(function(){return p},[]);var m=u.useRef(function(x){var y=x.svgPoint,b=x.index,$=x.key,S=x.datum,w=x.distanceX,T=x.distanceY;p();var O=ft(w)?w:1/0,P=ft(T)?T:1/0,_=Math.sqrt(Math.pow(O,2)+Math.pow(P,2));c(function(j){var F,V,R,X=j.tooltipData,C=X!=null&&X.nearestDatum&&ft(X.nearestDatum.distance)?X.nearestDatum.distance:1/0;return{tooltipOpen:!0,tooltipLeft:y==null?void 0:y.x,tooltipTop:y==null?void 0:y.y,tooltipData:{nearestDatum:((F=X==null||(V=X.nearestDatum)==null?void 0:V.key)!=null?F:"")!==$&&C<_?X==null?void 0:X.nearestDatum:{key:$,index:b,datum:S,distance:_},datumByKey:Ul({},X==null?void 0:X.datumByKey,(R={},R[$]={datum:S,index:b,key:$},R))}}})}),h=u.useCallback(function(){f.current=Tv(d,n),f.current()},[d,n]),v=u.useMemo(function(){return{tooltipOpen:i,tooltipLeft:a,tooltipTop:s,tooltipData:l,updateTooltip:c,showTooltip:m.current,hideTooltip:h}},[h,l,a,i,s,c]);return u.createElement(lo.Provider,{value:v},r)}_v.propTypes={hideTooltipDebounceMs:ne.number,children:ne.node.isRequired};const cO=Jn(oP);var co={},Hl={};Hl.__esModule=!0,Hl.default=uO;function uO(e,t){t.domain&&("nice"in e||"quantiles"in e||"padding"in e,e.domain(t.domain))}var Gl={};Gl.__esModule=!0,Gl.default=dO;function dO(e,t){t.range&&("padding"in e,e.range(t.range))}var Vl={};Vl.__esModule=!0,Vl.default=fO;function fO(e,t){"align"in e&&"align"in t&&typeof t.align<"u"&&e.align(t.align)}var ql={};ql.__esModule=!0,ql.default=pO;function pO(e,t){"base"in e&&"base"in t&&typeof t.base<"u"&&e.base(t.base)}var Yl={};Yl.__esModule=!0,Yl.default=hO;function hO(e,t){"clamp"in e&&"clamp"in t&&typeof t.clamp<"u"&&e.clamp(t.clamp)}var Kl={};Kl.__esModule=!0,Kl.default=mO;function mO(e,t){"constant"in e&&"constant"in t&&typeof t.constant<"u"&&e.constant(t.constant)}var Xl={};Xl.__esModule=!0,Xl.default=vO;function vO(e,t){"exponent"in e&&"exponent"in t&&typeof t.exponent<"u"&&e.exponent(t.exponent)}var Rl={},Zl={};const Nv=Jn(fP);Zl.__esModule=!0,Zl.default=gO;var pn=Nv,Av={lab:pn.interpolateLab,hcl:pn.interpolateHcl,"hcl-long":pn.interpolateHclLong,hsl:pn.interpolateHsl,"hsl-long":pn.interpolateHslLong,cubehelix:pn.interpolateCubehelix,"cubehelix-long":pn.interpolateCubehelixLong,rgb:pn.interpolateRgb};function gO(e){switch(e){case"lab":case"hcl":case"hcl-long":case"hsl":case"hsl-long":case"cubehelix":case"cubehelix-long":case"rgb":return Av[e]}var t=e.type,n=e.gamma,r=Av[t];return typeof n>"u"?r:r.gamma(n)}Rl.__esModule=!0,Rl.default=xO;var yO=bO(Zl);function bO(e){return e&&e.__esModule?e:{default:e}}function xO(e,t){if("interpolate"in t&&"interpolate"in e&&typeof t.interpolate<"u"){var n=(0,yO.default)(t.interpolate);e.interpolate(n)}}var Ql={};const wO=Jn(mP);var Jl={};Jl.__esModule=!0,Jl.default=SO;var $O=new Date(Date.UTC(2020,1,2,3,4,5)),CO="%Y-%m-%d %H:%M";function SO(e){var t=e.tickFormat(1,CO)($O);return t==="2020-02-02 03:04"}Ql.__esModule=!0,Ql.default=PO;var tt=wO,EO=TO(Jl);function TO(e){return e&&e.__esModule?e:{default:e}}var Dv={day:tt.timeDay,hour:tt.timeHour,minute:tt.timeMinute,month:tt.timeMonth,second:tt.timeSecond,week:tt.timeWeek,year:tt.timeYear},Iv={day:tt.utcDay,hour:tt.utcHour,minute:tt.utcMinute,month:tt.utcMonth,second:tt.utcSecond,week:tt.utcWeek,year:tt.utcYear};function PO(e,t){if("nice"in t&&typeof t.nice<"u"&&"nice"in e){var n=t.nice;if(typeof n=="boolean")n&&e.nice();else if(typeof n=="number")e.nice(n);else{var r=e,o=(0,EO.default)(r);if(typeof n=="string")r.nice(o?Iv[n]:Dv[n]);else{var i=n.interval,a=n.step,s=(o?Iv[i]:Dv[i]).every(a);s!=null&&r.nice(s)}}}}var ec={};ec.__esModule=!0,ec.default=MO;function MO(e,t){"padding"in e&&"padding"in t&&typeof t.padding<"u"&&e.padding(t.padding),"paddingInner"in e&&"paddingInner"in t&&typeof t.paddingInner<"u"&&e.paddingInner(t.paddingInner),"paddingOuter"in e&&"paddingOuter"in t&&typeof t.paddingOuter<"u"&&e.paddingOuter(t.paddingOuter)}var tc={};tc.__esModule=!0,tc.default=kO;function kO(e,t){if(t.reverse){var n=e.range().slice().reverse();"padding"in e,e.range(n)}}var nc={};nc.__esModule=!0,nc.default=_O;var OO=Nv;function _O(e,t){"round"in t&&typeof t.round<"u"&&(t.round&&"interpolate"in t&&typeof t.interpolate<"u"?console.warn("[visx/scale/applyRound] ignoring round: scale config contains round and interpolate. only applying interpolate. config:",t):"round"in e?e.round(t.round):"interpolate"in e&&t.round&&e.interpolate(OO.interpolateRound))}var rc={};rc.__esModule=!0,rc.default=NO;function NO(e,t){"unknown"in e&&"unknown"in t&&typeof t.unknown<"u"&&e.unknown(t.unknown)}var oc={};oc.__esModule=!0,oc.default=AO;function AO(e,t){if("zero"in t&&t.zero===!0){var n=e.domain(),r=n[0],o=n[1],i=o<r,a=i?[o,r]:[r,o],s=a[0],l=a[1],c=[Math.min(0,s),Math.max(0,l)];e.domain(i?c.reverse():c)}}co.__esModule=!0,co.ALL_OPERATORS=void 0,co.default=XO;var DO=nt(Hl),IO=nt(Gl),LO=nt(Vl),FO=nt(ql),jO=nt(Yl),zO=nt(Kl),WO=nt(Xl),BO=nt(Rl),UO=nt(Ql),HO=nt(ec),GO=nt(tc),VO=nt(nc),qO=nt(rc),YO=nt(oc);function nt(e){return e&&e.__esModule?e:{default:e}}var Lv=["domain","nice","zero","interpolate","round","range","reverse","align","base","clamp","constant","exponent","padding","unknown"];co.ALL_OPERATORS=Lv;var KO={domain:DO.default,nice:UO.default,zero:YO.default,interpolate:BO.default,round:VO.default,align:LO.default,base:FO.default,clamp:jO.default,constant:zO.default,exponent:WO.default,padding:HO.default,range:IO.default,reverse:GO.default,unknown:qO.default};function XO(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=new Set(t),o=Lv.filter(function(i){return r.has(i)});return function(a,s){return typeof s<"u"&&o.forEach(function(l){KO[l](a,s)}),a}}var RO=t_,ZO=cO,QO=JO(co);function JO(e){return e&&e.__esModule?e:{default:e}}var e_=(0,QO.default)("domain","range","reverse","unknown");function t_(e){return e_((0,ZO.scaleOrdinal)(),e)}var hn={red:["#fff5f5","#ffe3e3","#ffc9c9","#ffa8a8","#ff8787","#ff6b6b","#fa5252","#f03e3e","#e03131","#c92a2a"],pink:["#fff0f6","#ffdeeb","#fcc2d7","#faa2c1","#f783ac","#f06595","#e64980","#d6336c","#c2255c","#a61e4d"],grape:["#f8f0fc","#f3d9fa","#eebefa","#e599f7","#da77f2","#cc5de8","#be4bdb","#ae3ec9","#9c36b5","#862e9c"],violet:["#f3f0ff","#e5dbff","#d0bfff","#b197fc","#9775fa","#845ef7","#7950f2","#7048e8","#6741d9","#5f3dc4"],indigo:["#edf2ff","#dbe4ff","#bac8ff","#91a7ff","#748ffc","#5c7cfa","#4c6ef5","#4263eb","#3b5bdb","#364fc7"],blue:["#e8f7ff","#ccedff","#a3daff","#72c3fc","#4dadf7","#329af0","#228ae6","#1c7cd6","#1b6ec2","#1862ab"],cyan:["#e3fafc","#c5f6fa","#99e9f2","#66d9e8","#3bc9db","#22b8cf","#15aabf","#1098ad","#0c8599","#0b7285"],teal:["#e6fcf5","#c3fae8","#96f2d7","#63e6be","#38d9a9","#20c997","#12b886","#0ca678","#099268","#087f5b"],green:["#ebfbee","#d3f9d8","#b2f2bb","#8ce99a","#69db7c","#51cf66","#40c057","#37b24d","#2f9e44","#2b8a3e"],lime:["#f4fce3","#e9fac8","#d8f5a2","#c0eb75","#a9e34b","#94d82d","#82c91e","#74b816","#66a80f","#5c940d"],yellow:["#fff9db","#fff3bf","#ffec99","#ffe066","#ffd43b","#fcc419","#fab005","#f59f00","#f08c00","#e67700"],orange:["#fff4e6","#ffe8cc","#ffd8a8","#ffc078","#ffa94d","#ff922b","#fd7e14","#f76707","#e8590c","#d9480f"],gray:["#f8f9fa","#f1f3f5","#e9ecef","#dee2e6","#ced4da","#adb5bd","#868e96","#495057","#343a40","#212529"]},uo=hn.gray,ic=uo[7],n_=[hn.cyan[9],hn.cyan[3],hn.yellow[5],hn.red[4],hn.grape[8],hn.grape[5],hn.pink[9]];function De(){return De=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},De.apply(this,arguments)}var ac={fontFamily:"-apple-system,BlinkMacSystemFont,Roboto,Helvetica Neue,sans-serif",fontWeight:700,fontSize:12,textAnchor:"middle",pointerEvents:"none",letterSpacing:.4};function r_(e){var t,n,r,o,i,a,s=De({},ac,{fill:ic,stroke:"none"},e.svgLabelBig),l=De({},ac,{fontWeight:200,fontSize:11,fill:ic,stroke:"none"},e.svgLabelSmall),c=De({color:(t=(n=(r=(o=e.htmlLabel)==null?void 0:o.color)!=null?r:(i=e.svgLabelBig)==null?void 0:i.fill)!=null?n:(a=e.svgLabelSmall)==null?void 0:a.fill)!=null?t:ic},ac,e.htmlLabel);return{backgroundColor:e.backgroundColor,colors:[].concat(e.colors),htmlLabel:De({},c),svgLabelSmall:De({},l),svgLabelBig:De({},s),gridStyles:De({stroke:e.gridColor,strokeWidth:1},e.gridStyles),axisStyles:{x:{top:{axisLabel:De({},s,{dy:"-0.25em"}),axisLine:De({stroke:e.gridColorDark,strokeWidth:2},e.xAxisLineStyles),tickLabel:De({},l,{dy:"-0.25em"}),tickLength:e.tickLength,tickLine:De({strokeWidth:1,stroke:e.gridColor},e.xTickLineStyles)},bottom:{axisLabel:De({},s,{dy:"-0.25em"}),axisLine:De({stroke:e.gridColorDark,strokeWidth:2},e.xAxisLineStyles),tickLabel:De({},l,{dy:"0.125em"}),tickLength:e.tickLength,tickLine:De({strokeWidth:1,stroke:e.gridColor},e.xTickLineStyles)}},y:{left:{axisLabel:De({},s,{dx:"-1.25em"}),axisLine:De({stroke:e.gridColor,strokeWidth:1},e.yAxisLineStyles),tickLabel:De({},l,{textAnchor:"end",dx:"-0.25em",dy:"0.25em"}),tickLength:e.tickLength,tickLine:De({strokeWidth:1,stroke:e.gridColor},e.yTickLineStyles)},right:{axisLabel:De({},s,{dx:"1.25em"}),axisLine:De({stroke:e.gridColor,strokeWidth:1},e.yAxisLineStyles),tickLabel:De({},l,{textAnchor:"start",dx:"0.25em",dy:"0.25em"}),tickLength:e.tickLength,tickLine:De({strokeWidth:1,stroke:e.gridColor},e.yTickLineStyles)}}}}}const o_=r_({backgroundColor:"#fff",colors:n_,tickLength:4,svgLabelSmall:{fill:uo[7]},svgLabelBig:{fill:uo[9]},gridColor:uo[5],gridColorDark:uo[9]});var i_=u.createContext(o_);const a_=i_;var s_=function(){function e(){this.registry={},this.registryKeys=[]}var t=e.prototype;return t.registerData=function(r){var o=this,i=Array.isArray(r)?r:[r];i.forEach(function(a){a.key in o.registry&&o.registry[a.key]!=null&&console.debug("Overriding data registry key",a.key),o.registry[a.key]=a,o.registryKeys=Object.keys(o.registry)})},t.unregisterData=function(r){var o=this,i=Array.isArray(r)?r:[r];i.forEach(function(a){delete o.registry[a],o.registryKeys=Object.keys(o.registry)})},t.entries=function(){return Object.values(this.registry)},t.get=function(r){return this.registry[r]},t.keys=function(){return this.registryKeys},e}();function l_(){var e=u.useState(Math.random()),t=e[1],n=u.useMemo(function(){return new s_},[]);return u.useMemo(function(){return{registerData:function(){n.registerData.apply(n,arguments),t(Math.random())},unregisterData:function(){n.unregisterData.apply(n,arguments),t(Math.random())},entries:function(){return n.entries()},get:function(o){return n.get(o)},keys:function(){return n.keys()}}},[n])}var sc={width:0,height:0,margin:{top:0,right:0,bottom:0,left:0}};function c_(e){var t=u.useState({width:(e==null?void 0:e.width)==null?sc.width:e.width,height:(e==null?void 0:e.height)==null?sc.height:e.height,margin:(e==null?void 0:e.margin)==null?sc.margin:e.margin}),n=t[0],r=t[1],o=u.useCallback(function(i){(i.width!==n.width||i.height!==n.height||i.margin.left!==n.margin.left||i.margin.right!==n.margin.right||i.margin.top!==n.margin.top||i.margin.bottom!==n.margin.bottom)&&r(i)},[n.width,n.height,n.margin.left,n.margin.right,n.margin.bottom,n.margin.top]);return[n,o]}function zi(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function u_(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function lc(e){let t,n,r;e.length!==2?(t=zi,n=(s,l)=>zi(e(s),l),r=(s,l)=>e(s)-l):(t=e===zi||e===u_?e:d_,n=e,r=e);function o(s,l,c=0,d=s.length){if(c<d){if(t(l,l)!==0)return d;do{const f=c+d>>>1;n(s[f],l)<0?c=f+1:d=f}while(c<d)}return c}function i(s,l,c=0,d=s.length){if(c<d){if(t(l,l)!==0)return d;do{const f=c+d>>>1;n(s[f],l)<=0?c=f+1:d=f}while(c<d)}return c}function a(s,l,c=0,d=s.length){const f=o(s,l,c,d-1);return f>c&&r(s[f-1],l)>-r(s[f],l)?f-1:f}return{left:o,center:a,right:i}}function d_(){return 0}function f_(e){return e===null?NaN:+e}const p_=lc(zi).left;lc(f_).center;function Fv(e,t){let n,r;if(t===void 0)for(const o of e)o!=null&&(n===void 0?o>=o&&(n=r=o):(n>o&&(n=o),r<o&&(r=o)));else{let o=-1;for(let i of e)(i=t(i,++o,e))!=null&&(n===void 0?i>=i&&(n=r=i):(n>i&&(n=i),r<i&&(r=i)))}return[n,r]}function h_(e,t,n){e=+e,t=+t,n=(o=arguments.length)<2?(t=e,e=0,1):o<3?1:+n;for(var r=-1,o=Math.max(0,Math.ceil((t-e)/n))|0,i=new Array(o);++r<o;)i[r]=e+r*n;return i}function cc(e){return(e==null?void 0:e.type)==="band"||(e==null?void 0:e.type)==="ordinal"||(e==null?void 0:e.type)==="point"}function vr(){return vr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},vr.apply(this,arguments)}function m_(e){var t=e.dataRegistry,n=e.xRange,r=e.xScaleConfig,o=e.yRange,i=e.yScaleConfig,a=t.keys(),s=n[0],l=n[1],c=o[0],d=o[1],f=u.useMemo(function(){var m=a.map(function(y){return t.get(y)}),h=m.reduce(function(y,b){return b?y.concat(b.data.map(function($){return b.xAccessor($)})):y},[]);if(h.length!==0){var v=cc(r)?h:Fv(h),x=fl(r)?oo(vr({range:[s,l],domain:v,zero:!0},r)):oo(vr({range:[s,l],domain:v},r));return m.forEach(function(y){y!=null&&y.xScale&&(x=y.xScale(x))}),x}},[t,r,a,s,l]),p=u.useMemo(function(){var m=a.map(function(y){return t.get(y)}),h=m.reduce(function(y,b){return b?y.concat(b.data.map(function($){return b.yAccessor($)})):y},[]);if(h.length!==0){var v=cc(i)?h:Fv(h),x=fl(i)?oo(vr({range:[c,d],domain:v,zero:!0},i)):oo(vr({range:[c,d],domain:v},i));return m.forEach(function(y){y!=null&&y.yScale&&(x=y.yScale(x))}),x}},[t,i,a,c,d]);return{xScale:f,yScale:p}}function jv(e){var t=e.initialDimensions,n=e.theme,r=e.xScale,o=e.yScale,i=e.children,a=e.horizontal,s=a===void 0?"auto":a,l=e.resizeObserverPolyfill,c=u.useContext(a_),d=n||c,f=c_(t),p=f[0],m=p.width,h=p.height,v=p.margin,x=f[1],y=Math.max(0,m-v.left-v.right),b=Math.max(0,h-v.top-v.bottom),$=l_(),S=m_({dataRegistry:$,xScaleConfig:r,yScaleConfig:o,xRange:[v.left,Math.max(0,m-v.right)],yRange:[Math.max(0,h-v.bottom),v.top]}),w=S.xScale,T=S.yScale,O=$.keys(),P=u.useMemo(function(){return RO({domain:O,range:d.colors})},[O,d.colors]),_=s==="auto"?cc(o)||o.type==="time"||o.type==="utc":s,j=u.useMemo(function(){return{dataRegistry:$,registerData:$.registerData,unregisterData:$.unregisterData,xScale:w,yScale:T,colorScale:P,theme:d,width:m,height:h,margin:v,innerWidth:y,innerHeight:b,setDimensions:x,horizontal:_,resizeObserverPolyfill:l}},[P,$,h,_,b,y,v,x,d,m,w,T,l]);return u.createElement(Ot.Provider,{value:j},i)}jv.propTypes={children:ne.node.isRequired,horizontal:ne.oneOfType([ne.bool,ne.oneOf(["auto"])])};function zv(e){var t=e.source,n=e.onPointerOut,r=n===void 0?!0:n,o=e.onPointerMove,i=o===void 0?!0:o,a=e.onPointerUp,s=a===void 0?!0:a,l=e.onPointerDown,c=l===void 0?!0:l,d=e.onFocus,f=d===void 0?!1:d,p=e.onBlur,m=p===void 0?!1:p,h=fn(),v=u.useCallback(function(w){return h==null?void 0:h("pointermove",w,t)},[h,t]),x=u.useCallback(function(w){return h==null?void 0:h("pointerout",w,t)},[h,t]),y=u.useCallback(function(w){return h==null?void 0:h("pointerup",w,t)},[h,t]),b=u.useCallback(function(w){return h==null?void 0:h("pointerdown",w,t)},[h,t]),$=u.useCallback(function(w){return h==null?void 0:h("focus",w,t)},[h,t]),S=u.useCallback(function(w){return h==null?void 0:h("blur",w,t)},[h,t]);return{onPointerMove:i?v:void 0,onFocus:f?$:void 0,onBlur:m?S:void 0,onPointerOut:r?x:void 0,onPointerUp:s?y:void 0,onPointerDown:c?b:void 0}}var v_="GLYPHSERIES_EVENT_SOURCE",uc="XYCHART_EVENT_SOURCE";function Wv(e){return!!e&&("clientX"in e||"changedTouches"in e)}function g_(e){return!!e&&!Wv(e)}function Bv(e){var t=e.scale,n=e.accessor,r=e.scaledValue,o=e.data,i=t,a,s;if("invert"in i&&typeof i.invert=="function"){var l=lc(n).left,c=Number(i.invert(r)),d=l(o,c),f=o[d-1],p=o[d];a=!f||Math.abs(c-n(f))>Math.abs(c-n(p))?p:f,s=a===f?d-1:d}else if("step"in i&&typeof i.step<"u"){var m=t.domain(),h=t.range().map(Number),v=[].concat(h).sort(function(T,O){return T-O}),x=h_(v[0],v[1],i.step()),y=p_(x,r),b=h[0]<h[1]?m:m.reverse(),$=b[y-1],S=o.findIndex(function(T){return String(n(T))===String($)});a=o[S],s=S}else return console.warn("[visx/xychart/findNearestDatum] encountered incompatible scale type, bailing"),null;if(a==null||s==null)return null;var w=Math.abs(Number(i(n(a)))-r);return{datum:a,index:s,distance:w}}function y_(e){var t=e.xScale,n=e.xAccessor,r=e.yScale,o=e.yAccessor,i=e.point,a=e.data;if(!i)return null;var s=Bv({scale:t,accessor:n,scaledValue:i.x,data:a});return s?{datum:s.datum,index:s.index,distanceX:s.distance,distanceY:Math.abs(Number(r(o(s.datum)))-i.y)}:null}function b_(e){var t=e.yScale,n=e.yAccessor,r=e.xScale,o=e.xAccessor,i=e.point,a=e.data;if(!i)return null;var s=Bv({scale:t,accessor:n,scaledValue:i.y,data:a});return s?{datum:s.datum,index:s.index,distanceY:s.distance,distanceX:Math.abs(Number(r(o(s.datum)))-i.x)}:null}function dc(){return dc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},dc.apply(this,arguments)}var fc="__POINTER_EVENTS_ALL",Wi="__POINTER_EVENTS_NEAREST";function Uv(e){var t=e.dataKey,n=e.findNearestDatum,r=e.onBlur,o=e.onFocus,i=e.onPointerMove,a=e.onPointerOut,s=e.onPointerUp,l=e.onPointerDown,c=e.allowedSources,d=u.useContext(Ot),f=d.width,p=d.height,m=d.horizontal,h=d.dataRegistry,v=d.xScale,x=d.yScale,y=n||(m?b_:y_),b=u.useCallback(function(_){var j=_||{},F=j.svgPoint,V=j.event,R={},X=null,C=1/0;if(_&&V&&F&&f&&p&&v&&x){var I,H=t===Wi||t===fc,B=H?(I=h==null?void 0:h.keys())!=null?I:[]:Array.isArray(t)?t:[t];B.forEach(function(N){var z=h==null?void 0:h.get(N);if(z){var J=y({dataKey:N,data:z.data,height:p,point:F,width:f,xAccessor:z.xAccessor,xScale:v,yAccessor:z.yAccessor,yScale:x});if(J&&(R[N]=dc({key:N,svgPoint:F,event:V},J),t===Wi)){var Q,oe,te=Math.sqrt(((Q=J.distanceX)!=null?Q:Math.pow(1/0,2))+((oe=J.distanceY)!=null?oe:Math.pow(1/0,2)));X=te<C?R[N]:X,C=Math.min(C,te)}}});var A=t===Wi?[X]:t===fc||Array.isArray(t)?Object.values(R):[R[t]];return A.filter(function(N){return N})}return[]},[t,h,v,x,f,p,y]),$=u.useCallback(function(_){i&&b(_).forEach(function(j){return i(j)})},[b,i]),S=u.useCallback(function(_){s&&b(_).forEach(function(j){return s(j)})},[b,s]),w=u.useCallback(function(_){l&&b(_).forEach(function(j){return l(j)})},[b,l]),T=u.useCallback(function(_){o&&b(_).forEach(function(j){return o(j)})},[b,o]),O=u.useCallback(function(_){var j=_==null?void 0:_.event;j&&Wv(j)&&a&&a(j)},[a]),P=u.useCallback(function(_){var j=_==null?void 0:_.event;j&&g_(j)&&r&&r(j)},[r]);fn("pointermove",i?$:void 0,c),fn("pointerout",a?O:void 0,c),fn("pointerup",s?S:void 0,c),fn("pointerdown",l?w:void 0,c),fn("focus",o?T:void 0,c),fn("blur",r?P:void 0,c)}function Bi(){return Bi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Bi.apply(this,arguments)}var x_={top:50,right:50,bottom:50,left:50},w_=[uc];function gr(e){var t=e.accessibilityLabel,n=t===void 0?"XYChart":t,r=e.captureEvents,o=r===void 0?!0:r,i=e.children,a=e.height,s=e.horizontal,l=e.margin,c=l===void 0?x_:l,d=e.onPointerMove,f=e.onPointerOut,p=e.onPointerUp,m=e.onPointerDown,h=e.pointerEventsDataKey,v=h===void 0?"nearest":h,x=e.theme,y=e.width,b=e.xScale,$=e.yScale,S=e.resizeObserverPolyfill,w=u.useContext(Ot),T=w.setDimensions,O=w.resizeObserverPolyfill,P=u.useContext(lo),_=fn();u.useEffect(function(){T&&y!=null&&a!=null&&y>0&&a>0&&T({width:y,height:a,margin:c})},[T,y,a,c]);var j=zv({source:uc});return Uv({dataKey:v==="nearest"?Wi:fc,onPointerMove:d,onPointerOut:f,onPointerUp:p,onPointerDown:m,allowedSources:w_}),T?y==null||a==null?u.createElement(Jk,{resizeObserverPolyfill:O},function(F){return u.createElement(gr,Bi({},e,{width:e.width==null?F.width:e.width,height:e.height==null?F.height:e.height}))}):P==null?u.createElement(_v,null,u.createElement(gr,e)):_==null?u.createElement(lO,null,u.createElement(gr,e)):y<=0||a<=0?(console.info("XYChart has a zero width or height, bailing",{width:y,height:a}),null):u.createElement("svg",{width:y,height:a,"aria-label":n},i,o&&u.createElement("rect",Bi({x:c.left,y:c.top,width:y-c.left-c.right,height:a-c.top-c.bottom,fill:"transparent"},j))):!b||!$?(console.warn("[@visx/xychart] XYChart: When no DataProvider is available in context, you must pass xScale & yScale config to XYChart."),null):u.createElement(jv,{xScale:b,yScale:$,theme:x,initialDimensions:{width:y,height:a,margin:c},horizontal:s,resizeObserverPolyfill:S},u.createElement(gr,e))}gr.propTypes={accessibilityLabel:ne.string,captureEvents:ne.bool,width:ne.number,height:ne.number,children:ne.node.isRequired,horizontal:ne.oneOfType([ne.bool,ne.oneOf(["auto"])]),onPointerMove:ne.func,onPointerOut:ne.func,onPointerUp:ne.func,onPointerDown:ne.func,pointerEventsDataKey:ne.oneOf(["all","nearest"])};function pc(){return pc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},pc.apply(this,arguments)}function $_(e){function t(n){var r=n.dataKey,o=n.data,i=n.xAccessor,a=n.yAccessor,s=u.useContext(Ot),l=s.xScale,c=s.yScale,d=s.dataRegistry;u.useEffect(function(){return d&&d.registerData({key:r,data:o,xAccessor:i,yAccessor:a}),function(){return d==null?void 0:d.unregisterData(r)}},[d,r,o,i,a]);var f=d==null?void 0:d.get(r);if(!l||!c||!f)return null;var p=e;return u.createElement(p,pc({},n,{xScale:l,yScale:c,data:f.data,xAccessor:f.xAccessor,yAccessor:f.yAccessor}))}return t}function Hv(e,t,n){return n===void 0&&(n="center"),function(r){var o=e(t(r));if(ft(o)){var i=(n==="start"?0:pl(e))/(n==="center"?2:1);return o+i}return NaN}}function C_(e){var t,n=e.dataKey,r=e.enableEvents,o=e.findNearestDatum,i=e.onBlur,a=e.onFocus,s=e.onPointerMove,l=e.onPointerOut,c=e.onPointerUp,d=e.onPointerDown,f=e.source,p=e.allowedSources,m=(t=u.useContext(lo))!=null?t:{},h=m.showTooltip,v=m.hideTooltip,x=u.useCallback(function(w){h(w),s&&s(w)},[h,s]),y=u.useCallback(function(w){h(w),a&&a(w)},[h,a]),b=u.useCallback(function(w){v(),w&&l&&l(w)},[v,l]),$=u.useCallback(function(w){v(),w&&i&&i(w)},[v,i]),S=u.useCallback(function(w){h(w),d&&d(w)},[h,d]);return Uv({dataKey:n,findNearestDatum:o,onBlur:r?$:void 0,onFocus:r?y:void 0,onPointerMove:r?x:void 0,onPointerOut:r?b:void 0,onPointerUp:r?c:void 0,onPointerDown:r?S:void 0,allowedSources:p}),zv({source:f,onBlur:!!i&&r,onFocus:!!a&&r,onPointerMove:!!s&&r,onPointerOut:!!l&&r,onPointerUp:!!c&&r,onPointerDown:!!d&&r})}function hc(){return hc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},hc.apply(this,arguments)}function Gv(e){var t,n,r,o=e.colorAccessor,i=e.data,a=e.dataKey,s=e.onBlur,l=e.onFocus,c=e.onPointerMove,d=e.onPointerOut,f=e.onPointerUp,p=e.onPointerDown,m=e.enableEvents,h=m===void 0?!0:m,v=e.renderGlyphs,x=e.size,y=x===void 0?8:x,b=e.xAccessor,$=e.xScale,S=e.yAccessor,w=e.yScale,T=u.useContext(Ot),O=T.colorScale,P=T.theme,_=T.horizontal,j=u.useMemo(function(){return Hv($,b)},[$,b]),F=u.useMemo(function(){return Hv(w,S)},[w,S]),V=(t=(n=O==null?void 0:O(a))!=null?n:P==null||(r=P.colors)==null?void 0:r[0])!=null?t:"#222",R=v_+"-"+a,X=C_({dataKey:a,enableEvents:h,onBlur:s,onFocus:l,onPointerMove:c,onPointerOut:d,onPointerUp:f,onPointerDown:p,source:R,allowedSources:[uc,R]}),C=u.useMemo(function(){return i.map(function(I,H){var B,A=j(I);if(!ft(A))return null;var N=F(I);return ft(N)?{key:""+H,x:A,y:N,color:(B=o==null?void 0:o(I,H))!=null?B:V,size:typeof y=="function"?y(I):y,datum:I}:null}).filter(function(I){return I})},[V,o,i,j,F,y]);return u.createElement(u.Fragment,null,v(hc({glyphs:C,xScale:$,yScale:w,horizontal:_},X)))}Gv.propTypes={colorAccessor:ne.func,size:ne.oneOfType([ne.number,ne.func]),renderGlyphs:ne.func.isRequired};const S_=$_(Gv);function E_(e){var t=e.key,n=e.color,r=e.x,o=e.y,i=e.size,a=e.onBlur,s=e.onFocus,l=e.onPointerMove,c=e.onPointerOut,d=e.onPointerUp;return u.createElement("circle",{className:"visx-circle-glyph",key:t,tabIndex:a||s?0:void 0,fill:n,r:i/2,cx:r,cy:o,onBlur:a,onFocus:s,onPointerMove:l,onPointerOut:c,onPointerUp:d})}var T_=["renderGlyph"];function Ui(){return Ui=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ui.apply(this,arguments)}function P_(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function M_(e){var t=e.renderGlyph,n=t===void 0?E_:t,r=P_(e,T_),o=u.useCallback(function(i){var a=i.glyphs,s=i.onPointerMove,l=i.onPointerOut,c=i.onPointerUp,d=i.onFocus,f=i.onBlur;return a.map(function(p){return u.createElement(u.Fragment,{key:p.key},n(Ui({},p,{onPointerMove:s,onPointerOut:l,onPointerUp:c,onFocus:d,onBlur:f})))})},[n]);return u.createElement(S_,Ui({},r,{renderGlyphs:o}))}function Vv(e){var t=e.top,n=t===void 0?0:t,r=e.left,o=r===void 0?0:r,i=e.className,a=e.children;return u.createElement(En,{className:et("visx-glyph",i),top:n,left:o},a)}Vv.propTypes={top:ne.number,left:ne.number,className:ne.string,children:ne.node};var k_=["top","left","className"];function mc(){return mc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},mc.apply(this,arguments)}function O_(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function vc(e){var t=e.top,n=t===void 0?0:t,r=e.left,o=r===void 0?0:r,i=e.className,a=O_(e,k_);return u.createElement(Vv,{top:n,left:o},u.createElement("circle",mc({className:et("visx-glyph-dot",i)},a)))}vc.propTypes={className:ne.string,top:ne.number,left:ne.number,r:ne.number,cx:ne.number,cy:ne.number};var __=["className","children","debounceTime","ignoreDimensions","parentSizeStyles","enableDebounceLeadingCall","resizeObserverPolyfill"];function Hi(){return Hi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Hi.apply(this,arguments)}function N_(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}var A_=[],D_={width:"100%",height:"100%"};function Gi(e){var t=e.className,n=e.children,r=e.debounceTime,o=r===void 0?300:r,i=e.ignoreDimensions,a=i===void 0?A_:i,s=e.parentSizeStyles,l=s===void 0?D_:s,c=e.enableDebounceLeadingCall,d=c===void 0?!0:c,f=e.resizeObserverPolyfill,p=N_(e,__),m=u.useRef(null),h=u.useRef(0),v=u.useState({width:0,height:0,top:0,left:0}),x=v[0],y=v[1],b=u.useMemo(function(){var $=Array.isArray(a)?a:[a];return Tv(function(S){y(function(w){var T=Object.keys(w),O=T.filter(function(_){return w[_]!==S[_]}),P=O.every(function(_){return $.includes(_)});return P?w:S})},o,{leading:d})},[o,d,a]);return u.useEffect(function(){var $=f||window.ResizeObserver,S=new $(function(w){w.forEach(function(T){var O,P=(O=T==null?void 0:T.contentRect)!=null?O:{},_=P.left,j=P.top,F=P.width,V=P.height;h.current=window.requestAnimationFrame(function(){b({width:F,height:V,top:j,left:_})})})});return m.current&&S.observe(m.current),function(){window.cancelAnimationFrame(h.current),S.disconnect(),b.cancel()}},[b,f]),u.createElement("div",Hi({style:l,ref:m,className:t},p),n(Hi({},x,{ref:m.current,resize:b})))}Gi.propTypes={className:ne.string,debounceTime:ne.number,enableDebounceLeadingCall:ne.bool,ignoreDimensions:ne.oneOfType([ne.any,ne.arrayOf(ne.any)]),children:ne.func.isRequired};const qv=[{name:"default",dark:"#0091E7",light:"#62B9ED"},{name:"yellow",dark:"#8C6A00",light:"#FFDE88"},{name:"plum",dark:"#7D1779",light:"#E1AADD"},{name:"cyan",dark:"#329F95",light:"#C0FFF9"},{name:"purple",dark:"#7651BC",light:"#E7DAFF"},{name:"pink",dark:"#C01443",light:"#FAD4D4"},{name:"green",dark:"#44812F",light:"#B1E39F"},{name:"orange",dark:"#B96400",light:"#FFE7C5"},{name:"teal",dark:"#237C73",light:"#A1DFD5"},{name:"red",dark:"#C62C02",light:"#FFE1D9"}];function Re(e){return qv[e%qv.length]}function gc({textLabel:e,axisCharLimit:t,x:n,y:r,textStyles:o}){return L.jsx(kf,{children:L.jsxs(Of,{children:[L.jsx(_f,{asChild:!0,children:L.jsx("text",{className:"pointer-events-auto cursor-pointer",...o,x:n,y:r,children:e&&(e==null?void 0:e.length)>t?`${e==null?void 0:e.substring(0,t)}...`:e})}),L.jsx(Nf,{children:L.jsx(Ja,{className:"rabbit-ds",children:L.jsx("p",{children:e})})})]})})}const Yv=(e,t)=>u.Children.map(e,n=>u.isValidElement(n)&&typeof n.type=="function"&&n.type.displayName===t.displayName?n:null);function yc({value:e,darkColor:t,lightColor:n}){return L.jsxs("div",{className:"px-2 py-1 justify-start items-center gap-2 inline-flex",children:[L.jsx("div",{style:{backgroundColor:n,borderColor:t},className:"w-3 h-3 relative rounded-3xl border"}),L.jsx("div",{className:"justify-start items-start flex",children:L.jsx("div",{className:"text-zinc-800 text-xs font-normal leading-none",children:e})})]})}function bc({label:e,value:t}){return L.jsxs("div",{className:"px-1 py-0.5 flex-col justify-start items-start inline-flex max-w-sm",children:[L.jsx("div",{className:" text-stone-500 text-[10px] font-normal leading-none",children:e}),L.jsx("div",{className:"justify-start items-start text-sm flex font-medium",children:t||"-"})]})}function Ue({children:e,showSideBySide:t,tooltipTitle:n}){const r=Yv(e,yc),o=Yv(e,bc);return L.jsxs("div",{className:"rabbit-ds z-[1500] relative h-auto w-auto min-w-[200px] max-w-[400px] p-2 bg-white rounded-lg shadow flex-col justify-start items-start gap-2 inline-flex",children:[L.jsx("div",{className:"px-3 py-1 text-zinc-800 font-medium text-xs leading-none",children:n}),L.jsxs("div",{className:"w-full p-2 rounded-lg flex-col justify-start items-start flex",children:[t&&L.jsxs("div",{className:Ne("w-full flex"),children:[o&&o[0],L.jsx("div",{className:"w-0 border-r mx-3"}),o&&o[1]]}),!t&&L.jsx("div",{className:Ne("w-full grid gap-3 auto-rows-auto"),children:o})]}),r&&r.length>0?L.jsx("div",{className:"h-px px-2 w-full border-top bg-gray-100"}):null,r]})}yc.displayName="Legend",bc.displayName="Item",Ue.Legend=yc,Ue.Item=bc,Ue.defaultProps={showSideBySide:!1};function Kv({xValue:e,yValue:t,tooltipTitle:n,xAxisLabel:r,yAxisLabel:o,showSideBySide:i,legendValue:a,legendDarkColor:s,legendLightColor:l}){const c=e==null?void 0:e.toString(),d=t==null?void 0:t.toString();return L.jsxs(Ue,{tooltipTitle:n,showSideBySide:i,children:[L.jsx(Ue.Item,{label:r,value:c}),L.jsx(Ue.Item,{label:o,value:d}),L.jsx(Ue.Legend,{value:a,darkColor:s,lightColor:l})]})}Kv.defaultProps={xValue:void 0,yValue:void 0};function I_({data:e,xAccessor:t,yAccessor:n,connectNulls:r=!1}){const o=u.useContext(Ot),i=r?e.filter(a=>a.y!==null):e;return L.jsx(aM,{data:i,stroke:i[0].color.dark,strokeWidth:1,x:a=>{var s,l;return((s=o==null?void 0:o.xScale)==null?void 0:s.call(o,t(a)))+((l=o==null?void 0:o.xScale)==null?void 0:l.bandwidth())/2},y:a=>{var s;return(s=o==null?void 0:o.yScale)==null?void 0:s.call(o,n(a))}})}var xc={exports:{}};(function(e,t){(function(n,r){r(t)})(Nr,function(n){var r,o=Object.defineProperty,i=Object.defineProperties,a=Object.getOwnPropertyDescriptors,s=Object.getOwnPropertySymbols,l=Object.prototype.hasOwnProperty,c=Object.prototype.propertyIsEnumerable,d=Math.pow,f=(g,E,M)=>E in g?o(g,E,{enumerable:!0,configurable:!0,writable:!0,value:M}):g[E]=M,p=(g,E)=>{for(var M in E||(E={}))l.call(E,M)&&f(g,M,E[M]);if(s)for(var M of s(E))c.call(E,M)&&f(g,M,E[M]);return g},m=(g,E)=>i(g,a(E)),h=(g,E)=>{var M={};for(var D in g)l.call(g,D)&&E.indexOf(D)<0&&(M[D]=g[D]);if(g!=null&&s)for(var D of s(g))E.indexOf(D)<0&&c.call(g,D)&&(M[D]=g[D]);return M},v=(g,E,M)=>new Promise((D,G)=>{var Z=ie=>{try{K(M.next(ie))}catch(se){G(se)}},W=ie=>{try{K(M.throw(ie))}catch(se){G(se)}},K=ie=>ie.done?D(ie.value):Promise.resolve(ie.value).then(Z,W);K((M=M.apply(g,E)).next())});function x(g,E){return g[13]=1,g[14]=E>>8,g[15]=E&255,g[16]=E>>8,g[17]=E&255,g}const y="p".charCodeAt(0),b="H".charCodeAt(0),$="Y".charCodeAt(0),S="s".charCodeAt(0);let w;function T(){const g=new Int32Array(256);for(let E=0;E<256;E++){let M=E;for(let D=0;D<8;D++)M=M&1?3988292384^M>>>1:M>>>1;g[E]=M}return g}function O(g){let E=-1;w||(w=T());for(let M=0;M<g.length;M++)E=w[(E^g[M])&255]^E>>>8;return E^-1}function P(g){const E=g.length-1;for(let M=E;M>=4;M--)if(g[M-4]===9&&g[M-3]===y&&g[M-2]===b&&g[M-1]===$&&g[M]===S)return M-3;return 0}function _(g,E,M=!1){const D=new Uint8Array(13);E*=39.3701,D[0]=y,D[1]=b,D[2]=$,D[3]=S,D[4]=E>>>24,D[5]=E>>>16,D[6]=E>>>8,D[7]=E&255,D[8]=D[4],D[9]=D[5],D[10]=D[6],D[11]=D[7],D[12]=1;const G=O(D),Z=new Uint8Array(4);if(Z[0]=G>>>24,Z[1]=G>>>16,Z[2]=G>>>8,Z[3]=G&255,M){const W=P(g);return g.set(D,W),g.set(Z,W+13),g}else{const W=new Uint8Array(4);W[0]=0,W[1]=0,W[2]=0,W[3]=9;const K=new Uint8Array(54);return K.set(g,0),K.set(W,33),K.set(D,37),K.set(Z,50),K}}const j="AAlwSFlz",F="AAAJcEhZ",V="AAAACXBI";function R(g){let E=g.indexOf(j);return E===-1&&(E=g.indexOf(F)),E===-1&&(E=g.indexOf(V)),E}const X="[modern-screenshot]",C=typeof window<"u",I=C&&"Worker"in window,H=C&&"atob"in window,B=C&&"btoa"in window,A=C?(r=window.navigator)==null?void 0:r.userAgent:"",N=A.includes("Chrome"),z=A.includes("AppleWebKit")&&!N,J=A.includes("Firefox"),Q=g=>g&&"__CONTEXT__"in g,oe=g=>g.constructor.name==="CSSFontFaceRule",te=g=>g.constructor.name==="CSSImportRule",ae=g=>g.nodeType===1,Y=g=>typeof g.className=="object",le=g=>Y(g)&&g.tagName==="svg",U=g=>Y(g)&&g.tagName==="image",q=g=>ae(g)&&typeof g.style<"u"&&!Y(g),re=g=>g.nodeType===8,k=g=>g.nodeType===3,de=g=>g.tagName==="IMG",pe=g=>g.tagName==="VIDEO",Ce=g=>g.tagName==="CANVAS",ke=g=>g.tagName==="TEXTAREA",je=g=>g.tagName==="INPUT",_t=g=>g.tagName==="STYLE",mn=g=>g.tagName==="SCRIPT",Ze=g=>g.tagName==="SELECT",qt=g=>g.tagName==="SLOT",yr=g=>g.tagName==="IFRAME",Le=(...g)=>console.warn(X,...g),Ri=g=>console.time(`${X} ${g}`),Zi=g=>console.timeEnd(`${X} ${g}`),fo=g=>{var E;const M=(E=g==null?void 0:g.createElement)==null?void 0:E.call(g,"canvas");return M&&(M.height=M.width=1),M&&"toDataURL"in M&&!!M.toDataURL("image/webp").includes("image/webp")},rt=g=>g.startsWith("data:");function vn(g,E){if(g.match(/^[a-z]+:\/\//i))return g;if(C&&g.match(/^\/\//))return window.location.protocol+g;if(g.match(/^[a-z]+:/i)||!C)return g;const M=zn().implementation.createHTMLDocument(),D=M.createElement("base"),G=M.createElement("a");return M.head.appendChild(D),M.body.appendChild(G),E&&(D.href=E),G.href=g,G.href}function zn(g){var E;return(E=g&&ae(g)?g==null?void 0:g.ownerDocument:g)!=null?E:window.document}const Wn="http://www.w3.org/2000/svg";function po(g,E,M){const D=zn(M).createElementNS(Wn,"svg");return D.setAttributeNS(null,"width",g.toString()),D.setAttributeNS(null,"height",E.toString()),D.setAttributeNS(null,"viewBox",`0 0 ${g} ${E}`),D}function br(g,E){let M=new XMLSerializer().serializeToString(g);return E&&(M=M.replace(/[\u0000-\u0008\u000B\u000C\u000E-\u001F\uD800-\uDFFF\uFFFE\uFFFF]/ug,"")),`data:image/svg+xml;charset=utf-8,${encodeURIComponent(M)}`}function Qi(g,E="image/png",M=1){return v(this,null,function*(){try{return yield new Promise((D,G)=>{g.toBlob(Z=>{Z?D(Z):G(new Error("Blob is null"))},E,M)})}catch(D){if(H)return Le("Failed canvas to blob",{type:E,quality:M},D),Ji(g.toDataURL(E,M));throw D}})}function Ji(g){var E,M;const[D,G]=g.split(","),Z=(M=(E=D.match(/data:(.+);/))==null?void 0:E[1])!=null?M:void 0,W=window.atob(G),K=W.length,ie=new Uint8Array(K);for(let se=0;se<K;se+=1)ie[se]=W.charCodeAt(se);return new Blob([ie],{type:Z})}function ho(g,E){return new Promise((M,D)=>{const G=new FileReader;G.onload=()=>M(G.result),G.onerror=()=>D(G.error),G.onabort=()=>D(new Error(`Failed read blob to ${E}`)),E==="dataUrl"?G.readAsDataURL(g):E==="arrayBuffer"&&G.readAsArrayBuffer(g)})}const ea=g=>ho(g,"dataUrl"),ta=g=>ho(g,"arrayBuffer");function Nt(g,E){const M=zn(E).createElement("img");return M.decoding="sync",M.loading="eager",M.src=g,M}function Yt(g,E){return new Promise(M=>{const{timeout:D,ownerDocument:G,onError:Z}=E??{},W=typeof g=="string"?Nt(g,zn(G)):g;let K=null,ie=null;function se(){M(W),K&&clearTimeout(K),ie==null||ie()}if(D&&(K=setTimeout(se,D)),pe(W)){const ce=W.currentSrc||W.src;if(!ce)return W.poster?Yt(W.poster,E).then(M):se();if(W.readyState>=2)return se();const he=se,ue=be=>{Le("Failed video load",ce,be),Z==null||Z(be),se()};ie=()=>{W.removeEventListener("loadeddata",he),W.removeEventListener("error",ue)},W.addEventListener("loadeddata",he,{once:!0}),W.addEventListener("error",ue,{once:!0})}else{const ce=U(W)?W.href.baseVal:W.currentSrc||W.src;if(!ce)return se();const he=()=>v(this,null,function*(){if(de(W)&&"decode"in W)try{yield W.decode()}catch(be){Le("Failed to decode image, trying to render anyway",W.dataset.originalSrc||ce,be)}se()}),ue=be=>{Le("Failed image load",W.dataset.originalSrc||ce,be),se()};if(de(W)&&W.complete)return he();ie=()=>{W.removeEventListener("load",he),W.removeEventListener("error",ue)},W.addEventListener("load",he,{once:!0}),W.addEventListener("error",ue,{once:!0})}})}function mo(g,E){return v(this,null,function*(){q(g)&&(de(g)||pe(g)?yield Yt(g,{timeout:E}):yield Promise.all(["img","video"].flatMap(M=>Array.from(g.querySelectorAll(M)).map(D=>Yt(D,{timeout:E})))))})}const vo=function(){let g=0;const E=()=>`0000${(Math.random()*d(36,4)<<0).toString(36)}`.slice(-4);return()=>(g+=1,`u${E()}${g}`)}();function go(g){return g==null?void 0:g.split(",").map(E=>E.trim().replace(/"|'/g,"").toLowerCase()).filter(Boolean)}function na(g){return{time:E=>g&&Ri(E),timeEnd:E=>g&&Zi(E),warn:(...E)=>g&&Le(...E)}}function ra(g){return{cache:g?"no-cache":"force-cache"}}function st(g,E){return v(this,null,function*(){return Q(g)?g:oa(g,m(p({},E),{autoDestruct:!0}))})}function oa(g,E){return v(this,null,function*(){var M,D,G,Z,W;const{scale:K=1,workerUrl:ie,workerNumber:se=1}=E||{},ce=!!(E!=null&&E.debug),he=(M=E==null?void 0:E.features)!=null?M:!0,ue=(D=g.ownerDocument)!=null?D:C?window.document:void 0,be=(Z=(G=g.ownerDocument)==null?void 0:G.defaultView)!=null?Z:C?window:void 0,ye=new Map,$e=m(p({width:0,height:0,quality:1,type:"image/png",scale:K,backgroundColor:null,style:null,filter:null,maximumCanvasSize:0,timeout:3e4,progress:null,debug:ce,fetch:p({requestInit:ra((W=E==null?void 0:E.fetch)==null?void 0:W.bypassingCache),placeholderImage:"data:image/png;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",bypassingCache:!1},E==null?void 0:E.fetch),font:{},drawImageInterval:100,workerUrl:null,workerNumber:se,onCloneNode:null,onEmbedNode:null,onCreateForeignObjectSvg:null,autoDestruct:!1},E),{__CONTEXT__:!0,log:na(ce),node:g,ownerDocument:ue,ownerWindow:be,dpi:K===1?null:96*K,svgStyleElement:Qe(ue),svgDefsElement:ue==null?void 0:ue.createElementNS(Wn,"defs"),svgStyles:new Map,defaultComputedStyles:new Map,workers:[...new Array(I&&ie&&se?se:0)].map(()=>{try{const Ie=new Worker(ie);return Ie.onmessage=_e=>v(this,null,function*(){var Je,Rt,gn,Og;const{url:kc,result:_g}=_e.data;_g?(Rt=(Je=ye.get(kc))==null?void 0:Je.resovle)==null||Rt.call(Je,_g):(Og=(gn=ye.get(kc))==null?void 0:gn.reject)==null||Og.call(gn,new Error(`Error receiving message from worker: ${kc}`))}),Ie.onmessageerror=_e=>{var Je,Rt;const{url:gn}=_e.data;(Rt=(Je=ye.get(gn))==null?void 0:Je.reject)==null||Rt.call(Je,new Error(`Error receiving message from worker: ${gn}`))},Ie}catch(Ie){return Le("Failed to new Worker",Ie),null}}).filter(Boolean),fontFamilies:new Set,fontCssTexts:new Map,acceptOfImage:`${[fo(ue)&&"image/webp","image/svg+xml","image/*","*/*"].filter(Boolean).join(",")};q=0.8`,requests:ye,drawImageCount:0,tasks:[],features:he,isEnable:Ie=>{var _e;return typeof he=="boolean"?he:(_e=he[Ie])!=null?_e:!0}});$e.log.time("wait until load"),yield mo(g,$e.timeout),$e.log.timeEnd("wait until load");const{width:Ee,height:Te}=pt(g,$e);return $e.width=Ee,$e.height=Te,$e})}function Qe(g){if(!g)return;const E=g.createElement("style"),M=E.ownerDocument.createTextNode(`
73
+ `).join("");return x}function vM(e){var t=e.children,n=e.className,r=e.innerRef,o=e.x,i=e.y,a=e.width,s=e.height,l=e.radius,c=e.all,d=c===void 0?!1:c,f=e.top,p=f===void 0?!1:f,m=e.bottom,h=m===void 0?!1:m,v=e.left,x=v===void 0?!1:v,y=e.right,b=y===void 0?!1:y,$=e.topLeft,S=$===void 0?!1:$,w=e.topRight,T=w===void 0?!1:w,O=e.bottomLeft,P=O===void 0?!1:O,_=e.bottomRight,j=_===void 0?!1:_,F=hM(e,pM),V=mM({x:o,y:i,width:a,height:s,radius:l,all:d,top:p,bottom:h,left:x,right:b,topLeft:S,topRight:T,bottomLeft:P,bottomRight:j});return t?u.createElement(u.Fragment,null,t({path:V})):u.createElement("path",$l({ref:r,className:et("visx-bar-rounded",n),d:V},F))}function gM(e){return typeof(e==null?void 0:e.x)=="number"?e==null?void 0:e.x:0}function yM(e){return typeof(e==null?void 0:e.y)=="number"?e==null?void 0:e.y:0}function bM(e){return e==null?void 0:e.source}function xM(e){return e==null?void 0:e.target}var wM=["className","children","data","innerRef","path","x","y","source","target"];function Cl(){return Cl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Cl.apply(this,arguments)}function $M(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function CM(e){var t=e.source,n=e.target,r=e.x,o=e.y;return function(i){var a=rM();return a.x(r),a.y(o),a.source(t),a.target(n),a(i)}}function SM(e){var t=e.className,n=e.children,r=e.data,o=e.innerRef,i=e.path,a=e.x,s=a===void 0?yM:a,l=e.y,c=l===void 0?gM:l,d=e.source,f=d===void 0?bM:d,p=e.target,m=p===void 0?xM:p,h=$M(e,wM),v=i||CM({source:f,target:m,x:s,y:c});return n?u.createElement(u.Fragment,null,n({path:v})):u.createElement("path",Cl({ref:o,className:et("visx-link visx-link-horizontal-diagonal",t),d:v(r)||""},h))}var EM=["AxisComponent"];function ki(){return ki=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ki.apply(this,arguments)}function TM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function PM(e){var t,n,r,o,i,a,s,l=e.AxisComponent,c=TM(e,EM),d=u.useContext(Ot),f=d.theme,p=d.xScale,m=d.yScale,h=d.margin,v=d.width,x=d.height,y=c.orientation,b=u.useMemo(function(){var P,_,j,F;return y==="left"||y==="right"?f==null||(P=f.axisStyles)==null||(_=P.y)==null?void 0:_[y]:f==null||(j=f.axisStyles)==null||(F=j.x)==null?void 0:F[y]},[f,y]),$=c.tickLabelProps,S=u.useMemo(function(){return $||b?function(P,_,j){return ki({},b==null?void 0:b.tickLabel,{width:y==="left"||y==="right"?h==null?void 0:h[y]:void 0},typeof $=="function"?$(P,_,j):$)}:void 0},[$,b,y,h]),w=y==="bottom"?(x??0)-((t=h==null?void 0:h.bottom)!=null?t:0):y==="top"&&(n=h==null?void 0:h.top)!=null?n:0,T=y==="left"?(r=h==null?void 0:h.left)!=null?r:0:y==="right"?(v??0)-((o=h==null?void 0:h.right)!=null?o:0):0,O=y==="left"||y==="right"?m:p;return O?u.createElement(l,ki({top:w,left:T,labelProps:b==null?void 0:b.axisLabel,stroke:b==null||(i=b.axisLine)==null?void 0:i.stroke,strokeWidth:b==null||(a=b.axisLine)==null?void 0:a.strokeWidth,tickLength:b==null?void 0:b.tickLength,tickStroke:b==null||(s=b.tickLine)==null?void 0:s.stroke},c,{tickLabelProps:S,scale:O})):null}var Oi={};Oi.__esModule=!0;var MM=Oi.default=AM,kM=Jm(u),OM=Jm(Qo),_M=["from","to","fill","className","innerRef"];function Jm(e){return e&&e.__esModule?e:{default:e}}function Sl(){return Sl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Sl.apply(this,arguments)}function NM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function AM(e){var t=e.from,n=t===void 0?{x:0,y:0}:t,r=e.to,o=r===void 0?{x:1,y:1}:r,i=e.fill,a=i===void 0?"transparent":i,s=e.className,l=e.innerRef,c=NM(e,_M),d=n.x===o.x||n.y===o.y;return kM.default.createElement("line",Sl({ref:l,className:(0,OM.default)("visx-line",s),x1:n.x,y1:n.y,x2:o.x,y2:o.y,fill:a,shapeRendering:d?"crispEdges":"auto"},c))}var _i={};_i.__esModule=!0,_i.default=DM;function DM(e){return"bandwidth"in e?e.bandwidth():0}var IM=ov,ev=ao(Zo),tv=ao(u),LM=ao(Qo),FM=ao(Oi),jM=qm,nv=gp,rv=Ym,zM=ao(_i),WM=["top","left","scale","width","stroke","strokeWidth","strokeDasharray","className","children","numTicks","lineStyle","offset","tickValues"];function ao(e){return e&&e.__esModule?e:{default:e}}function El(){return El=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},El.apply(this,arguments)}function BM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function ov(e){var t=e.top,n=t===void 0?0:t,r=e.left,o=r===void 0?0:r,i=e.scale,a=e.width,s=e.stroke,l=s===void 0?"#eaf0f6":s,c=e.strokeWidth,d=c===void 0?1:c,f=e.strokeDasharray,p=e.className,m=e.children,h=e.numTicks,v=h===void 0?10:h,x=e.lineStyle,y=e.offset,b=e.tickValues,$=BM(e,WM),S=b??(0,rv.getTicks)(i,v),w=(y??0)+(0,zM.default)(i)/2,T=S.map(function(O,P){var _,j=((_=(0,rv.coerceNumber)(i(O)))!=null?_:0)+w;return{index:P,from:new nv.Point({x:0,y:j}),to:new nv.Point({x:a,y:j})}});return tv.default.createElement(jM.Group,{className:(0,LM.default)("visx-rows",p),top:n,left:o},m?m({lines:T}):T.map(function(O){var P=O.from,_=O.to,j=O.index;return tv.default.createElement(FM.default,El({key:"row-line-"+j,from:P,to:_,stroke:l,strokeWidth:d,strokeDasharray:f,style:x},$))}))}ov.propTypes={tickValues:ev.default.array,width:ev.default.number.isRequired};var UM=cv,iv=so(Zo),av=so(u),HM=so(Qo),GM=so(Oi),VM=qm,sv=gp,lv=Ym,qM=so(_i),YM=["top","left","scale","height","stroke","strokeWidth","strokeDasharray","className","numTicks","lineStyle","offset","tickValues","children"];function so(e){return e&&e.__esModule?e:{default:e}}function Tl(){return Tl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Tl.apply(this,arguments)}function KM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function cv(e){var t=e.top,n=t===void 0?0:t,r=e.left,o=r===void 0?0:r,i=e.scale,a=e.height,s=e.stroke,l=s===void 0?"#eaf0f6":s,c=e.strokeWidth,d=c===void 0?1:c,f=e.strokeDasharray,p=e.className,m=e.numTicks,h=m===void 0?10:m,v=e.lineStyle,x=e.offset,y=e.tickValues,b=e.children,$=KM(e,YM),S=y??(0,lv.getTicks)(i,h),w=(x??0)+(0,qM.default)(i)/2,T=S.map(function(O,P){var _,j=((_=(0,lv.coerceNumber)(i(O)))!=null?_:0)+w;return{index:P,from:new sv.Point({x:j,y:0}),to:new sv.Point({x:j,y:a})}});return av.default.createElement(VM.Group,{className:(0,HM.default)("visx-columns",p),top:n,left:o},b?b({lines:T}):T.map(function(O){var P=O.from,_=O.to,j=O.index;return av.default.createElement(GM.default,Tl({key:"column-line-"+j,from:P,to:_,stroke:l,strokeWidth:d,strokeDasharray:f,style:v},$))}))}cv.propTypes={tickValues:iv.default.array,height:iv.default.number.isRequired};var XM=["rows","columns","GridRowsComponent","GridColumnsComponent"];function Ni(){return Ni=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ni.apply(this,arguments)}function RM(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function uv(e){var t=e.rows,n=t===void 0?!0:t,r=e.columns,o=r===void 0?!0:r,i=e.GridRowsComponent,a=e.GridColumnsComponent,s=RM(e,XM),l=u.useContext(Ot),c=l.theme,d=l.xScale,f=l.yScale,p=l.margin,m=l.innerWidth,h=l.innerHeight,v=c==null?void 0:c.gridStyles;return u.createElement(u.Fragment,null,n&&f&&m!=null&&u.createElement(i,Ni({left:p==null?void 0:p.left,lineStyle:v,width:m,scale:f},s)),o&&d&&h!=null&&u.createElement(a,Ni({top:p==null?void 0:p.top,lineStyle:v,height:h,scale:d},s)))}uv.propTypes={rows:ne.bool,columns:ne.bool};var ZM={top:"top",left:"left",right:"right",bottom:"bottom"};const $t=ZM;function QM(e){var t=e.labelOffset,n=e.labelProps,r=e.orientation,o=e.range,i=e.tickLabelFontSize,a=e.tickLength,s=r===$t.left||r===$t.top?-1:1,l,c,d;if(r===$t.top||r===$t.bottom){var f=r===$t.bottom&&typeof n.fontSize=="number"?n.fontSize:0;l=(Number(o[0])+Number(o[o.length-1]))/2,c=s*(a+t+i+f)}else l=s*((Number(o[0])+Number(o[o.length-1]))/2),c=-(a+t),d="rotate("+s*90+")";return{x:l,y:c,transform:d}}function lo(){return lo=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},lo.apply(this,arguments)}function JM(e){var t=e.hideTicks,n=e.horizontal,r=e.orientation,o=e.tickClassName,i=e.tickComponent,a=e.tickLabelProps,s=e.tickStroke,l=s===void 0?"#222":s,c=e.tickTransform,d=e.ticks,f=e.strokeWidth,p=e.tickLineProps;return d.map(function(m){var h,v=m.value,x=m.index,y=m.from,b=m.to,$=m.formattedValue,S=(h=a[x])!=null?h:{},w=Math.max(10,typeof S.fontSize=="number"&&S.fontSize||0),T=b.y+(n&&r!==$t.top?w:0);return u.createElement(En,{key:"visx-tick-"+v+"-"+x,className:et("visx-axis-tick",o),transform:c},!t&&u.createElement(Qm,lo({from:y,to:b,stroke:l,strokeWidth:f,strokeLinecap:"square"},p)),i?i(lo({},S,{x:b.x,y:T,formattedValue:$})):u.createElement(ys,lo({x:b.x,y:T},S),$))})}function Ai(){return Ai=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ai.apply(this,arguments)}var dv={textAnchor:"middle",fontFamily:"Arial",fontSize:10,fill:"#222"};function ek(e){var t=e.axisFromPoint,n=e.axisLineClassName,r=e.axisToPoint,o=e.hideAxisLine,i=e.hideTicks,a=e.horizontal,s=e.label,l=s===void 0?"":s,c=e.labelClassName,d=e.labelOffset,f=d===void 0?14:d,p=e.labelProps,m=p===void 0?dv:p,h=e.orientation,v=h===void 0?$t.bottom:h,x=e.scale,y=e.stroke,b=y===void 0?"#222":y,$=e.strokeDasharray,S=e.strokeWidth,w=S===void 0?1:S,T=e.tickClassName,O=e.tickComponent,P=e.tickLineProps,_=e.tickLabelProps,j=e.tickLength,F=j===void 0?8:j,V=e.tickStroke,R=V===void 0?"#222":V,X=e.tickTransform,C=e.ticks,I=e.ticksComponent,H=I===void 0?JM:I,B=Ai({},dv,typeof _=="object"?_:null),A=C.map(function(z){var J=z.value,Q=z.index;return typeof _=="function"?_(J,Q,C):B}),N=Math.max.apply(Math,[10].concat(A.map(function(z){return typeof z.fontSize=="number"?z.fontSize:0})));return u.createElement(u.Fragment,null,H({hideTicks:i,horizontal:a,orientation:v,scale:x,tickClassName:T,tickComponent:O,tickLabelProps:A,tickStroke:R,tickTransform:X,ticks:C,strokeWidth:w,tickLineProps:P}),!o&&u.createElement(Qm,{className:et("visx-axis-line",n),from:t,to:r,stroke:b,strokeWidth:w,strokeDasharray:$}),l&&u.createElement(ys,Ai({className:et("visx-axis-label",c)},QM({labelOffset:f,labelProps:m,orientation:v,range:x.range(),tickLabelFontSize:N,tickLength:F}),m),l))}function tk(e,t){t===void 0&&(t="center");var n=e;if(t!=="start"&&"bandwidth"in n){var r=n.bandwidth();return t==="center"&&(r/=2),n.round()&&(r=Math.round(r)),function(o){var i=n(o);return typeof i=="number"?i+r:i}}return e}function nk(e){var t=e;return"tickFormat"in t?t.tickFormat():Vm}function Di(e,t){var n=e.x,r=e.y;return new an(t?{x:n,y:r}:{x:r,y:n})}function Pl(){return Pl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Pl.apply(this,arguments)}var Ml=0;function rk(e){return e===void 0&&(e=Ml),typeof e=="number"?{start:e,end:e}:Pl({start:Ml,end:Ml},e)}var ok=["children","axisClassName","hideAxisLine","hideTicks","hideZero","left","numTicks","orientation","rangePadding","scale","tickFormat","tickLength","tickValues","top"];function kl(){return kl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},kl.apply(this,arguments)}function ik(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function Ol(e){var t=e.children,n=t===void 0?ek:t,r=e.axisClassName,o=e.hideAxisLine,i=o===void 0?!1:o,a=e.hideTicks,s=a===void 0?!1:a,l=e.hideZero,c=l===void 0?!1:l,d=e.left,f=d===void 0?0:d,p=e.numTicks,m=p===void 0?10:p,h=e.orientation,v=h===void 0?$t.bottom:h,x=e.rangePadding,y=x===void 0?0:x,b=e.scale,$=e.tickFormat,S=e.tickLength,w=S===void 0?8:S,T=e.tickValues,O=e.top,P=O===void 0?0:O,_=ik(e,ok),j=$??nk(b),F=v===$t.left,V=v===$t.top,R=V||v===$t.bottom,X=tk(b),C=F||V?-1:1,I=b.range(),H=rk(y),B=Di({x:Number(I[0])+.5-H.start,y:0},R),A=Di({x:Number(I[I.length-1])+.5+H.end,y:0},R),N=(T??fl(b,m)).filter(function(J){return!c||J!==0&&J!=="0"}).map(function(J,Q){return{value:J,index:Q}}),z=N.map(function(J){var Q=J.value,oe=J.index,te=dl(X(Q));return{value:Q,index:oe,from:Di({x:te,y:0},R),to:Di({x:te,y:w*C},R),formattedValue:j(Q,oe,N)}});return u.createElement(En,{className:et("visx-axis",r),top:P,left:f},n(kl({},_,{axisFromPoint:B,axisToPoint:A,hideAxisLine:i,hideTicks:s,hideZero:c,horizontal:R,numTicks:m,orientation:v,rangePadding:y,scale:b,tickFormat:j,tickLength:w,tickPosition:X,tickSign:C,ticks:z})))}function _l(){return _l=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},_l.apply(this,arguments)}function fv(e){return u.createElement(PM,_l({AxisComponent:Ol},e))}function Nl(){return Nl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Nl.apply(this,arguments)}function ak(e){return u.createElement(uv,Nl({GridRowsComponent:IM,GridColumnsComponent:UM},e))}var sk=["tooltipOpen"];function lk(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function Ii(){return Ii=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ii.apply(this,arguments)}function Al(e){var t=u.useState(Ii({tooltipOpen:!1},e)),n=t[0],r=t[1],o=u.useCallback(function(a){return r(typeof a=="function"?function(s){s.tooltipOpen;var l=lk(s,sk);return Ii({},a(l),{tooltipOpen:!0})}:{tooltipOpen:!0,tooltipLeft:a.tooltipLeft,tooltipTop:a.tooltipTop,tooltipData:a.tooltipData})},[r]),i=u.useCallback(function(){return r({tooltipOpen:!1,tooltipLeft:void 0,tooltipTop:void 0,tooltipData:void 0})},[r]);return{tooltipOpen:n.tooltipOpen,tooltipLeft:n.tooltipLeft,tooltipTop:n.tooltipTop,tooltipData:n.tooltipData,updateTooltip:r,showTooltip:o,hideTooltip:i}}function ck(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Dl(e,t)}function Dl(e,t){return Dl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},Dl(e,t)}var pv=function(e){ck(t,e);function t(){return e.apply(this,arguments)||this}var n=t.prototype;return n.componentWillUnmount=function(){this.node&&document.body&&(document.body.removeChild(this.node),delete this.node)},n.render=function(){return!this.node&&typeof document<"u"&&(this.node=document.createElement("div"),this.props.zIndex!=null&&(this.node.style.zIndex=""+this.props.zIndex),document.body.append(this.node)),this.node?At.createPortal(this.props.children,this.node):null},t}(u.PureComponent);pv.propTypes={zIndex:ne.oneOfType([ne.number,ne.string])};var uk=["className","top","left","offsetLeft","offsetTop","style","children","unstyled","applyPositionStyle"];function Li(){return Li=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Li.apply(this,arguments)}function dk(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}var Il={position:"absolute",backgroundColor:"white",color:"#666666",padding:".3rem .5rem",borderRadius:"3px",fontSize:"14px",boxShadow:"0 1px 2px rgba(33,33,33,0.2)",lineHeight:"1em",pointerEvents:"none"},Ll=u.forwardRef(function(e,t){var n=e.className,r=e.top,o=e.left,i=e.offsetLeft,a=i===void 0?10:i,s=e.offsetTop,l=s===void 0?10:s,c=e.style,d=c===void 0?Il:c,f=e.children,p=e.unstyled,m=p===void 0?!1:p,h=e.applyPositionStyle,v=h===void 0?!1:h,x=dk(e,uk);return u.createElement("div",Li({ref:t,className:et("visx-tooltip",n),style:Li({top:r==null||l==null?r:r+l,left:o==null||a==null?o:o+a},v&&{position:"absolute"},!m&&d)},x),f)});Ll.propTypes={children:ne.node,className:ne.string,left:ne.number,offsetLeft:ne.number,offsetTop:ne.number,top:ne.number,applyPositionStyle:ne.bool,unstyled:ne.bool},Ll.displayName="Tooltip";const hv=Ll;function Fl(){return Fl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Fl.apply(this,arguments)}function fk(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function pk(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,jl(e,t)}function jl(e,t){return jl=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,o){return r.__proto__=o,r},jl(e,t)}var mv={top:0,right:0,bottom:0,left:0,width:0,height:0};function hk(e){var t;return t=function(n){pk(r,n);function r(i){var a;return a=n.call(this,i)||this,a.state={rect:void 0,parentRect:void 0},a.nodeRef=u.createRef(),a.getRects=a.getRects.bind(fk(a)),a}var o=r.prototype;return o.componentDidMount=function(){var a,s=this;this.node=(a=this.nodeRef)!=null&&a.current?this.nodeRef.current:At.findDOMNode(this),this.setState(function(){return s.getRects()})},o.getRects=function(){if(!this.node)return this.state;var a=this.node,s=a.parentNode,l=a.getBoundingClientRect?a.getBoundingClientRect():mv,c=s!=null&&s.getBoundingClientRect?s.getBoundingClientRect():mv;return{rect:l,parentRect:c}},o.render=function(){return u.createElement(e,Fl({nodeRef:this.nodeRef,getRects:this.getRects},this.state,this.props))},r}(u.PureComponent),t.displayName="withBoundingRects("+(e.displayName||"")+")",t}var vv=u.createContext({isFlippedVertically:!1,isFlippedHorizontally:!1}),mk=vv.Provider;vv.Consumer;var vk=["children","getRects","left","offsetLeft","offsetTop","parentRect","rect","style","top","unstyled","nodeRef"];function Fi(){return Fi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Fi.apply(this,arguments)}function gk(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function gv(e){var t=e.children;e.getRects;var n=e.left,r=n===void 0?0:n,o=e.offsetLeft,i=o===void 0?10:o,a=e.offsetTop,s=a===void 0?10:a,l=e.parentRect,c=e.rect,d=e.style,f=d===void 0?Il:d,p=e.top,m=p===void 0?0:p,h=e.unstyled,v=h===void 0?!1:h,x=e.nodeRef,y=gk(e,vk),b,$=!1,S=!1;if(c&&l){var w=r,T=m;if(l.width){var O=w+i+c.width-l.width,P=c.width-w-i;$=O>0&&O>P}else{var _=w+i+c.width-window.innerWidth,j=c.width-w-i;$=_>0&&_>j}if(l.height){var F=T+s+c.height-l.height,V=c.height-T-s;S=F>0&&F>V}else S=T+s+c.height>window.innerHeight;w=$?w-c.width-i:w+i,T=S?T-c.height-s:T+s,w=Math.round(w),T=Math.round(T),b="translate("+w+"px, "+T+"px)"}return u.createElement(hv,Fi({ref:x,style:Fi({left:0,top:0,transform:b},!v&&f)},y),u.createElement(mk,{value:{isFlippedVertically:!S,isFlippedHorizontally:!$}},t))}gv.propTypes={nodeRef:ne.oneOfType([ne.string,ne.func,ne.object])};const yk=hk(gv);var bk=["detectBounds","zIndex"],xk=["left","top","detectBounds","zIndex"];function zl(){return zl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},zl.apply(this,arguments)}function yv(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function Wl(e){var t=e===void 0?{}:e,n=t.detectBounds,r=n===void 0?!0:n,o=t.zIndex,i=yv(t,bk),a=RS(i),s=a[0],l=a[1],c=a[2],d=u.useState(!1),f=d[0],p=d[1];u.useEffect(function(){p(!1)},[]);var m=u.useMemo(function(){return function(h){var v=h.left,x=v===void 0?0:v,y=h.top,b=y===void 0?0:y,$=h.detectBounds,S=h.zIndex,w=yv(h,xk),T=$??r,O=S??o,P=T?yk:hv,_=f?0:window.scrollX,j=f?0:window.scrollY,F=x+(l.left||0)+_,V=b+(l.top||0)+j;return u.createElement(pv,{zIndex:O},u.createElement(P,zl({left:F,top:V},w)))}},[r,o,l.left,l.top,f]);return{containerRef:s,containerBounds:l,forceRefreshBounds:c,TooltipInPortal:m}}var wk=u.createContext(null);const co=wk;var $k=["debounce","detectBounds","horizontalCrosshairStyle","glyphStyle","renderTooltip","renderGlyph","resizeObserverPolyfill","scroll","showDatumGlyph","showHorizontalCrosshair","showSeriesGlyphs","showVerticalCrosshair","snapTooltipToDatumX","snapTooltipToDatumY","verticalCrosshairStyle","zIndex"],Ck=["x","y"];function bv(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function Vt(){return Vt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Vt.apply(this,arguments)}var Bl={position:"absolute",pointerEvents:"none",fontSize:0,lineHeight:0},Sk={position:"absolute",left:0,top:0,opacity:0,width:0,height:0,pointerEvents:"none"};function xv(e){var t=u.useContext(Ot)||{},n=t.theme;return u.createElement("circle",Vt({cx:e.x,cy:e.y,r:e.size,fill:e.color,stroke:n==null?void 0:n.backgroundColor,strokeWidth:1.5,paintOrder:"fill"},e.glyphStyle))}xv.propTypes={isNearestDatum:ne.bool.isRequired};function Ek(e){return u.createElement(xv,e)}function wv(e){var t,n,r,o,i,a,s,l,c,d,f,p,m,h=e.debounce,v=e.detectBounds,x=e.horizontalCrosshairStyle,y=e.glyphStyle,b=e.renderTooltip,$=e.renderGlyph,S=$===void 0?Ek:$,w=e.resizeObserverPolyfill,T=e.scroll,O=T===void 0?!0:T,P=e.showDatumGlyph,_=P===void 0?!1:P,j=e.showHorizontalCrosshair,F=j===void 0?!1:j,V=e.showSeriesGlyphs,R=V===void 0?!1:V,X=e.showVerticalCrosshair,C=X===void 0?!1:X,I=e.snapTooltipToDatumX,H=I===void 0?!1:I,B=e.snapTooltipToDatumY,A=B===void 0?!1:B,N=e.verticalCrosshairStyle,z=e.zIndex,J=bv(e,$k),Q=u.useContext(Ot)||{},oe=Q.colorScale,te=Q.theme,ae=Q.innerHeight,Y=Q.innerWidth,le=Q.margin,U=Q.xScale,q=Q.yScale,re=Q.dataRegistry,k=Q.resizeObserverPolyfill,de=u.useContext(co),pe=Wl({debounce:h,detectBounds:v,polyfill:k||w,scroll:O,zIndex:z}),Ce=pe.containerRef,ke=pe.TooltipInPortal,je=pe.forceRefreshBounds,_t=u.useCallback(function(Qe){var pt;Ce((pt=Qe==null?void 0:Qe.parentElement)!=null?pt:null)},[Ce]),mn=de!=null&&de.tooltipOpen?b(Vt({},de,{colorScale:oe})):null,Ze=(de==null?void 0:de.tooltipOpen)&&mn!=null,qt=u.useRef(!1);u.useEffect(function(){Ze&&!qt.current&&je(),qt.current=Ze},[Ze,je]);var yr=de==null?void 0:de.tooltipLeft,Le=de==null?void 0:de.tooltipTop,Ri=U?hl(U):0,Zi=q?hl(q):0,po=u.useCallback(function(Qe,pt){var Kt,Xt,lt=re==null?void 0:re.get(Qe),Bn=lt==null?void 0:lt.xAccessor,Un=lt==null?void 0:lt.yAccessor,xr=U&&Bn?(Kt=Number(U(Bn(pt)))+Ri/2)!=null?Kt:0:void 0,wr=q&&Un?(Xt=Number(q(Un(pt)))+Zi/2)!=null?Xt:0:void 0;return{left:xr,top:wr}},[re,Ri,Zi,U,q]),rt=de==null||(t=de.tooltipData)==null?void 0:t.nearestDatum,vn=(n=rt==null?void 0:rt.key)!=null?n:"";if(Ze&&rt&&(H||A)){var zn=po(vn,rt.datum),Wn=zn.left,ho=zn.top;yr=H&&ft(Wn)?Wn:yr,Le=A&&ft(ho)?ho:Le}var br=[];if(Ze&&(_||R)){var Qi,Ji=Number((Qi=y==null?void 0:y.radius)!=null?Qi:4);if(R){var mo,ea;Object.values((mo=de==null||(ea=de.tooltipData)==null?void 0:ea.datumByKey)!=null?mo:{}).forEach(function(Qe){var pt,Kt,Xt,lt=Qe.key,Bn=Qe.datum,Un=Qe.index,xr=(pt=(Kt=oe==null?void 0:oe(lt))!=null?Kt:te==null||(Xt=te.htmlLabel)==null?void 0:Xt.color)!=null?pt:"#222",wr=po(lt,Bn),ia=wr.left,aa=wr.top;!ft(ia)||!ft(aa)||br.push({key:lt,color:xr,datum:Bn,index:Un,size:Ji,x:ia,y:aa,glyphStyle:y,isNearestDatum:rt?rt.key===lt:!1})})}else if(rt){var ta=po(vn,rt.datum),Nt=ta.left,Yt=ta.top;if(ft(Nt)&&ft(Yt)){var vo,go,yo,na,ra,st,oa=(vo=(go=(yo=(na=vn&&(oe==null?void 0:oe(vn)))!=null?na:null)!=null?yo:te==null||(ra=te.gridStyles)==null?void 0:ra.stroke)!=null?go:te==null||(st=te.htmlLabel)==null?void 0:st.color)!=null?vo:"#222";br.push({key:vn,color:oa,datum:rt.datum,index:rt.index,size:Ji,x:Nt,y:Yt,glyphStyle:y,isNearestDatum:!0})}}}return u.createElement(u.Fragment,null,u.createElement("svg",{ref:_t,style:Sk}),Ze&&u.createElement(u.Fragment,null,C&&u.createElement(ke,{className:"visx-crosshair visx-crosshair-vertical",left:yr,top:le==null?void 0:le.top,offsetLeft:0,offsetTop:0,detectBounds:!1,style:Bl},u.createElement("svg",{width:"1",height:ae,overflow:"visible"},u.createElement("line",Vt({x1:0,x2:0,y1:0,y2:ae,strokeWidth:1.5,stroke:(r=(o=te==null||(i=te.gridStyles)==null?void 0:i.stroke)!=null?o:te==null||(a=te.htmlLabel)==null?void 0:a.color)!=null?r:"#222"},N)))),F&&u.createElement(ke,{className:"visx-crosshair visx-crosshair-horizontal",left:le==null?void 0:le.left,top:Le,offsetLeft:0,offsetTop:0,detectBounds:!1,style:Bl},u.createElement("svg",{width:Y,height:"1",overflow:"visible"},u.createElement("line",Vt({x1:0,x2:Y,y1:0,y2:0,strokeWidth:1.5,stroke:(s=(l=te==null||(c=te.gridStyles)==null?void 0:c.stroke)!=null?l:te==null||(d=te.htmlLabel)==null?void 0:d.color)!=null?s:"#222"},x)))),br.map(function(Qe,pt){var Kt=Qe.x,Xt=Qe.y,lt=bv(Qe,Ck);return u.createElement(ke,{key:pt,className:"visx-tooltip-glyph",left:Kt,top:Xt,offsetLeft:0,offsetTop:0,detectBounds:!1,style:Bl},u.createElement("svg",{overflow:"visible"},S(Vt({x:0,y:0},lt))))}),u.createElement(ke,Vt({left:yr,top:Le,style:Vt({},Il,{background:(f=te==null?void 0:te.backgroundColor)!=null?f:"white",boxShadow:"0 1px 2px "+(te!=null&&(p=te.htmlLabel)!=null&&p.color?(te==null||(m=te.htmlLabel)==null?void 0:m.color)+"55":"#22222255")},te==null?void 0:te.htmlLabel)},J),mn)))}wv.propTypes={renderTooltip:ne.func.isRequired,renderGlyph:ne.func,snapTooltipToDatumX:ne.bool,snapTooltipToDatumY:ne.bool,showVerticalCrosshair:ne.bool,showHorizontalCrosshair:ne.bool,showDatumGlyph:ne.bool,showSeriesGlyphs:ne.bool};function $v(e){var t=u.useContext(co);return t!=null&&t.tooltipOpen?u.createElement(wv,e):null}$v.propTypes={renderTooltip:ne.func.isRequired,renderGlyph:ne.func,snapTooltipToDatumX:ne.bool,snapTooltipToDatumY:ne.bool,showVerticalCrosshair:ne.bool,showHorizontalCrosshair:ne.bool,showDatumGlyph:ne.bool,showSeriesGlyphs:ne.bool};var Tk=ti,Pk=function(){return Tk.Date.now()},Mk=Pk,kk=/\s/;function Ok(e){for(var t=e.length;t--&&kk.test(e.charAt(t)););return t}var _k=Ok,Nk=_k,Ak=/^\s+/;function Dk(e){return e&&e.slice(0,Nk(e)+1).replace(Ak,"")}var Ik=Dk;function Lk(e){return e!=null&&typeof e=="object"}var Fk=Lk,jk=ap,zk=Fk,Wk="[object Symbol]";function Bk(e){return typeof e=="symbol"||zk(e)&&jk(e)==Wk}var Uk=Bk,Hk=Ik,Cv=ni,Gk=Uk,Sv=0/0,Vk=/^[-+]0x[0-9a-f]+$/i,qk=/^0b[01]+$/i,Yk=/^0o[0-7]+$/i,Kk=parseInt;function Xk(e){if(typeof e=="number")return e;if(Gk(e))return Sv;if(Cv(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Cv(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=Hk(e);var n=qk.test(e);return n||Yk.test(e)?Kk(e.slice(2),n?2:8):Vk.test(e)?Sv:+e}var Rk=Xk,Zk=ni,Ul=Mk,Ev=Rk,Qk="Expected a function",Jk=Math.max,eO=Math.min;function tO(e,t,n){var r,o,i,a,s,l,c=0,d=!1,f=!1,p=!0;if(typeof e!="function")throw new TypeError(Qk);t=Ev(t)||0,Zk(n)&&(d=!!n.leading,f="maxWait"in n,i=f?Jk(Ev(n.maxWait)||0,t):i,p="trailing"in n?!!n.trailing:p);function m(T){var O=r,P=o;return r=o=void 0,c=T,a=e.apply(P,O),a}function h(T){return c=T,s=setTimeout(y,t),d?m(T):a}function v(T){var O=T-l,P=T-c,_=t-O;return f?eO(_,i-P):_}function x(T){var O=T-l,P=T-c;return l===void 0||O>=t||O<0||f&&P>=i}function y(){var T=Ul();if(x(T))return b(T);s=setTimeout(y,v(T))}function b(T){return s=void 0,p&&r?m(T):(r=o=void 0,a)}function $(){s!==void 0&&clearTimeout(s),c=0,r=l=o=s=void 0}function S(){return s===void 0?a:b(Ul())}function w(){var T=Ul(),O=x(T);if(r=arguments,o=this,l=T,O){if(s===void 0)return h(l);if(f)return clearTimeout(s),s=setTimeout(y,t),m(l)}return s===void 0&&(s=setTimeout(y,t)),a}return w.cancel=$,w.flush=S,w}var Tv=tO;const Pv=Qn(Tv);var nO=Ov,dn=kv(Zo),rO=kv(Tv),mr=iO(u),oO=["className","children","debounceTime","ignoreDimensions","parentSizeStyles","enableDebounceLeadingCall","resizeObserverPolyfill"];function Mv(e){if(typeof WeakMap!="function")return null;var t=new WeakMap,n=new WeakMap;return(Mv=function(o){return o?n:t})(e)}function iO(e,t){if(!t&&e&&e.__esModule)return e;if(e===null||typeof e!="object"&&typeof e!="function")return{default:e};var n=Mv(t);if(n&&n.has(e))return n.get(e);var r={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if(i!=="default"&&Object.prototype.hasOwnProperty.call(e,i)){var a=o?Object.getOwnPropertyDescriptor(e,i):null;a&&(a.get||a.set)?Object.defineProperty(r,i,a):r[i]=e[i]}return r.default=e,n&&n.set(e,r),r}function kv(e){return e&&e.__esModule?e:{default:e}}function ji(){return ji=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ji.apply(this,arguments)}function aO(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}var sO=[],lO={width:"100%",height:"100%"};function Ov(e){var t=e.className,n=e.children,r=e.debounceTime,o=r===void 0?300:r,i=e.ignoreDimensions,a=i===void 0?sO:i,s=e.parentSizeStyles,l=s===void 0?lO:s,c=e.enableDebounceLeadingCall,d=c===void 0?!0:c,f=e.resizeObserverPolyfill,p=aO(e,oO),m=(0,mr.useRef)(null),h=(0,mr.useRef)(0),v=(0,mr.useState)({width:0,height:0,top:0,left:0}),x=v[0],y=v[1],b=(0,mr.useMemo)(function(){var $=Array.isArray(a)?a:[a];return(0,rO.default)(function(S){y(function(w){var T=Object.keys(w),O=T.filter(function(_){return w[_]!==S[_]}),P=O.every(function(_){return $.includes(_)});return P?w:S})},o,{leading:d})},[o,d,a]);return(0,mr.useEffect)(function(){var $=f||window.ResizeObserver,S=new $(function(w){w.forEach(function(T){var O,P=(O=T==null?void 0:T.contentRect)!=null?O:{},_=P.left,j=P.top,F=P.width,V=P.height;h.current=window.requestAnimationFrame(function(){b({width:F,height:V,top:j,left:_})})})});return m.current&&S.observe(m.current),function(){window.cancelAnimationFrame(h.current),S.disconnect(),b.cancel()}},[b,f]),mr.default.createElement("div",ji({style:l,ref:m,className:t},p),n(ji({},x,{ref:m.current,resize:b})))}Ov.propTypes={className:dn.default.string,debounceTime:dn.default.number,enableDebounceLeadingCall:dn.default.bool,ignoreDimensions:dn.default.oneOfType([dn.default.any,dn.default.arrayOf(dn.default.any)]),children:dn.default.func.isRequired};var cO=u.createContext(null);const _v=cO;function fn(e,t,n){var r=u.useContext(_v),o=u.useRef();o.current=n;var i=u.useCallback(function(a,s,l){r&&r.emit(a,{event:s,svgPoint:dE(s),source:l})},[r]);return u.useEffect(function(){if(r&&e&&t){var a=function(l){var c;(!o.current||l!=null&&l.source&&(c=o.current)!=null&&c.includes(l.source))&&t(l)};return r.on(e,a),function(){return r==null?void 0:r.off(e,a)}}},[r,e,t]),r?i:null}function uO(e){return{all:e=e||new Map,on:function(t,n){var r=e.get(t);r&&r.push(n)||e.set(t,[n])},off:function(t,n){var r=e.get(t);r&&r.splice(r.indexOf(n)>>>0,1)},emit:function(t,n){(e.get(t)||[]).slice().map(function(r){r(n)}),(e.get("*")||[]).slice().map(function(r){r(t,n)})}}}function dO(e){var t=e.children,n=u.useMemo(function(){return uO()},[]);return u.createElement(_v.Provider,{value:n},t)}function Hl(){return Hl=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Hl.apply(this,arguments)}function Nv(e){var t=e.hideTooltipDebounceMs,n=t===void 0?400:t,r=e.children,o=Al(void 0),i=o.tooltipOpen,a=o.tooltipLeft,s=o.tooltipTop,l=o.tooltipData,c=o.updateTooltip,d=o.hideTooltip,f=u.useRef(null);function p(){f.current&&(f.current.cancel(),f.current=null)}u.useEffect(function(){return p},[]);var m=u.useRef(function(x){var y=x.svgPoint,b=x.index,$=x.key,S=x.datum,w=x.distanceX,T=x.distanceY;p();var O=ft(w)?w:1/0,P=ft(T)?T:1/0,_=Math.sqrt(Math.pow(O,2)+Math.pow(P,2));c(function(j){var F,V,R,X=j.tooltipData,C=X!=null&&X.nearestDatum&&ft(X.nearestDatum.distance)?X.nearestDatum.distance:1/0;return{tooltipOpen:!0,tooltipLeft:y==null?void 0:y.x,tooltipTop:y==null?void 0:y.y,tooltipData:{nearestDatum:((F=X==null||(V=X.nearestDatum)==null?void 0:V.key)!=null?F:"")!==$&&C<_?X==null?void 0:X.nearestDatum:{key:$,index:b,datum:S,distance:_},datumByKey:Hl({},X==null?void 0:X.datumByKey,(R={},R[$]={datum:S,index:b,key:$},R))}}})}),h=u.useCallback(function(){f.current=Pv(d,n),f.current()},[d,n]),v=u.useMemo(function(){return{tooltipOpen:i,tooltipLeft:a,tooltipTop:s,tooltipData:l,updateTooltip:c,showTooltip:m.current,hideTooltip:h}},[h,l,a,i,s,c]);return u.createElement(co.Provider,{value:v},r)}Nv.propTypes={hideTooltipDebounceMs:ne.number,children:ne.node.isRequired};const fO=Jn(sP);var uo={},Gl={};Gl.__esModule=!0,Gl.default=pO;function pO(e,t){t.domain&&("nice"in e||"quantiles"in e||"padding"in e,e.domain(t.domain))}var Vl={};Vl.__esModule=!0,Vl.default=hO;function hO(e,t){t.range&&("padding"in e,e.range(t.range))}var ql={};ql.__esModule=!0,ql.default=mO;function mO(e,t){"align"in e&&"align"in t&&typeof t.align<"u"&&e.align(t.align)}var Yl={};Yl.__esModule=!0,Yl.default=vO;function vO(e,t){"base"in e&&"base"in t&&typeof t.base<"u"&&e.base(t.base)}var Kl={};Kl.__esModule=!0,Kl.default=gO;function gO(e,t){"clamp"in e&&"clamp"in t&&typeof t.clamp<"u"&&e.clamp(t.clamp)}var Xl={};Xl.__esModule=!0,Xl.default=yO;function yO(e,t){"constant"in e&&"constant"in t&&typeof t.constant<"u"&&e.constant(t.constant)}var Rl={};Rl.__esModule=!0,Rl.default=bO;function bO(e,t){"exponent"in e&&"exponent"in t&&typeof t.exponent<"u"&&e.exponent(t.exponent)}var Zl={},Ql={};const Av=Jn(mP);Ql.__esModule=!0,Ql.default=xO;var pn=Av,Dv={lab:pn.interpolateLab,hcl:pn.interpolateHcl,"hcl-long":pn.interpolateHclLong,hsl:pn.interpolateHsl,"hsl-long":pn.interpolateHslLong,cubehelix:pn.interpolateCubehelix,"cubehelix-long":pn.interpolateCubehelixLong,rgb:pn.interpolateRgb};function xO(e){switch(e){case"lab":case"hcl":case"hcl-long":case"hsl":case"hsl-long":case"cubehelix":case"cubehelix-long":case"rgb":return Dv[e]}var t=e.type,n=e.gamma,r=Dv[t];return typeof n>"u"?r:r.gamma(n)}Zl.__esModule=!0,Zl.default=CO;var wO=$O(Ql);function $O(e){return e&&e.__esModule?e:{default:e}}function CO(e,t){if("interpolate"in t&&"interpolate"in e&&typeof t.interpolate<"u"){var n=(0,wO.default)(t.interpolate);e.interpolate(n)}}var Jl={};const SO=Jn(yP);var ec={};ec.__esModule=!0,ec.default=PO;var EO=new Date(Date.UTC(2020,1,2,3,4,5)),TO="%Y-%m-%d %H:%M";function PO(e){var t=e.tickFormat(1,TO)(EO);return t==="2020-02-02 03:04"}Jl.__esModule=!0,Jl.default=OO;var tt=SO,MO=kO(ec);function kO(e){return e&&e.__esModule?e:{default:e}}var Iv={day:tt.timeDay,hour:tt.timeHour,minute:tt.timeMinute,month:tt.timeMonth,second:tt.timeSecond,week:tt.timeWeek,year:tt.timeYear},Lv={day:tt.utcDay,hour:tt.utcHour,minute:tt.utcMinute,month:tt.utcMonth,second:tt.utcSecond,week:tt.utcWeek,year:tt.utcYear};function OO(e,t){if("nice"in t&&typeof t.nice<"u"&&"nice"in e){var n=t.nice;if(typeof n=="boolean")n&&e.nice();else if(typeof n=="number")e.nice(n);else{var r=e,o=(0,MO.default)(r);if(typeof n=="string")r.nice(o?Lv[n]:Iv[n]);else{var i=n.interval,a=n.step,s=(o?Lv[i]:Iv[i]).every(a);s!=null&&r.nice(s)}}}}var tc={};tc.__esModule=!0,tc.default=_O;function _O(e,t){"padding"in e&&"padding"in t&&typeof t.padding<"u"&&e.padding(t.padding),"paddingInner"in e&&"paddingInner"in t&&typeof t.paddingInner<"u"&&e.paddingInner(t.paddingInner),"paddingOuter"in e&&"paddingOuter"in t&&typeof t.paddingOuter<"u"&&e.paddingOuter(t.paddingOuter)}var nc={};nc.__esModule=!0,nc.default=NO;function NO(e,t){if(t.reverse){var n=e.range().slice().reverse();"padding"in e,e.range(n)}}var rc={};rc.__esModule=!0,rc.default=DO;var AO=Av;function DO(e,t){"round"in t&&typeof t.round<"u"&&(t.round&&"interpolate"in t&&typeof t.interpolate<"u"?console.warn("[visx/scale/applyRound] ignoring round: scale config contains round and interpolate. only applying interpolate. config:",t):"round"in e?e.round(t.round):"interpolate"in e&&t.round&&e.interpolate(AO.interpolateRound))}var oc={};oc.__esModule=!0,oc.default=IO;function IO(e,t){"unknown"in e&&"unknown"in t&&typeof t.unknown<"u"&&e.unknown(t.unknown)}var ic={};ic.__esModule=!0,ic.default=LO;function LO(e,t){if("zero"in t&&t.zero===!0){var n=e.domain(),r=n[0],o=n[1],i=o<r,a=i?[o,r]:[r,o],s=a[0],l=a[1],c=[Math.min(0,s),Math.max(0,l)];e.domain(i?c.reverse():c)}}uo.__esModule=!0,uo.ALL_OPERATORS=void 0,uo.default=QO;var FO=nt(Gl),jO=nt(Vl),zO=nt(ql),WO=nt(Yl),BO=nt(Kl),UO=nt(Xl),HO=nt(Rl),GO=nt(Zl),VO=nt(Jl),qO=nt(tc),YO=nt(nc),KO=nt(rc),XO=nt(oc),RO=nt(ic);function nt(e){return e&&e.__esModule?e:{default:e}}var Fv=["domain","nice","zero","interpolate","round","range","reverse","align","base","clamp","constant","exponent","padding","unknown"];uo.ALL_OPERATORS=Fv;var ZO={domain:FO.default,nice:VO.default,zero:RO.default,interpolate:GO.default,round:KO.default,align:zO.default,base:WO.default,clamp:BO.default,constant:UO.default,exponent:HO.default,padding:qO.default,range:jO.default,reverse:YO.default,unknown:XO.default};function QO(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=new Set(t),o=Fv.filter(function(i){return r.has(i)});return function(a,s){return typeof s<"u"&&o.forEach(function(l){ZO[l](a,s)}),a}}var JO=o_,e_=fO,t_=n_(uo);function n_(e){return e&&e.__esModule?e:{default:e}}var r_=(0,t_.default)("domain","range","reverse","unknown");function o_(e){return r_((0,e_.scaleOrdinal)(),e)}var hn={red:["#fff5f5","#ffe3e3","#ffc9c9","#ffa8a8","#ff8787","#ff6b6b","#fa5252","#f03e3e","#e03131","#c92a2a"],pink:["#fff0f6","#ffdeeb","#fcc2d7","#faa2c1","#f783ac","#f06595","#e64980","#d6336c","#c2255c","#a61e4d"],grape:["#f8f0fc","#f3d9fa","#eebefa","#e599f7","#da77f2","#cc5de8","#be4bdb","#ae3ec9","#9c36b5","#862e9c"],violet:["#f3f0ff","#e5dbff","#d0bfff","#b197fc","#9775fa","#845ef7","#7950f2","#7048e8","#6741d9","#5f3dc4"],indigo:["#edf2ff","#dbe4ff","#bac8ff","#91a7ff","#748ffc","#5c7cfa","#4c6ef5","#4263eb","#3b5bdb","#364fc7"],blue:["#e8f7ff","#ccedff","#a3daff","#72c3fc","#4dadf7","#329af0","#228ae6","#1c7cd6","#1b6ec2","#1862ab"],cyan:["#e3fafc","#c5f6fa","#99e9f2","#66d9e8","#3bc9db","#22b8cf","#15aabf","#1098ad","#0c8599","#0b7285"],teal:["#e6fcf5","#c3fae8","#96f2d7","#63e6be","#38d9a9","#20c997","#12b886","#0ca678","#099268","#087f5b"],green:["#ebfbee","#d3f9d8","#b2f2bb","#8ce99a","#69db7c","#51cf66","#40c057","#37b24d","#2f9e44","#2b8a3e"],lime:["#f4fce3","#e9fac8","#d8f5a2","#c0eb75","#a9e34b","#94d82d","#82c91e","#74b816","#66a80f","#5c940d"],yellow:["#fff9db","#fff3bf","#ffec99","#ffe066","#ffd43b","#fcc419","#fab005","#f59f00","#f08c00","#e67700"],orange:["#fff4e6","#ffe8cc","#ffd8a8","#ffc078","#ffa94d","#ff922b","#fd7e14","#f76707","#e8590c","#d9480f"],gray:["#f8f9fa","#f1f3f5","#e9ecef","#dee2e6","#ced4da","#adb5bd","#868e96","#495057","#343a40","#212529"]},fo=hn.gray,ac=fo[7],i_=[hn.cyan[9],hn.cyan[3],hn.yellow[5],hn.red[4],hn.grape[8],hn.grape[5],hn.pink[9]];function De(){return De=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},De.apply(this,arguments)}var sc={fontFamily:"-apple-system,BlinkMacSystemFont,Roboto,Helvetica Neue,sans-serif",fontWeight:700,fontSize:12,textAnchor:"middle",pointerEvents:"none",letterSpacing:.4};function a_(e){var t,n,r,o,i,a,s=De({},sc,{fill:ac,stroke:"none"},e.svgLabelBig),l=De({},sc,{fontWeight:200,fontSize:11,fill:ac,stroke:"none"},e.svgLabelSmall),c=De({color:(t=(n=(r=(o=e.htmlLabel)==null?void 0:o.color)!=null?r:(i=e.svgLabelBig)==null?void 0:i.fill)!=null?n:(a=e.svgLabelSmall)==null?void 0:a.fill)!=null?t:ac},sc,e.htmlLabel);return{backgroundColor:e.backgroundColor,colors:[].concat(e.colors),htmlLabel:De({},c),svgLabelSmall:De({},l),svgLabelBig:De({},s),gridStyles:De({stroke:e.gridColor,strokeWidth:1},e.gridStyles),axisStyles:{x:{top:{axisLabel:De({},s,{dy:"-0.25em"}),axisLine:De({stroke:e.gridColorDark,strokeWidth:2},e.xAxisLineStyles),tickLabel:De({},l,{dy:"-0.25em"}),tickLength:e.tickLength,tickLine:De({strokeWidth:1,stroke:e.gridColor},e.xTickLineStyles)},bottom:{axisLabel:De({},s,{dy:"-0.25em"}),axisLine:De({stroke:e.gridColorDark,strokeWidth:2},e.xAxisLineStyles),tickLabel:De({},l,{dy:"0.125em"}),tickLength:e.tickLength,tickLine:De({strokeWidth:1,stroke:e.gridColor},e.xTickLineStyles)}},y:{left:{axisLabel:De({},s,{dx:"-1.25em"}),axisLine:De({stroke:e.gridColor,strokeWidth:1},e.yAxisLineStyles),tickLabel:De({},l,{textAnchor:"end",dx:"-0.25em",dy:"0.25em"}),tickLength:e.tickLength,tickLine:De({strokeWidth:1,stroke:e.gridColor},e.yTickLineStyles)},right:{axisLabel:De({},s,{dx:"1.25em"}),axisLine:De({stroke:e.gridColor,strokeWidth:1},e.yAxisLineStyles),tickLabel:De({},l,{textAnchor:"start",dx:"0.25em",dy:"0.25em"}),tickLength:e.tickLength,tickLine:De({strokeWidth:1,stroke:e.gridColor},e.yTickLineStyles)}}}}}const s_=a_({backgroundColor:"#fff",colors:i_,tickLength:4,svgLabelSmall:{fill:fo[7]},svgLabelBig:{fill:fo[9]},gridColor:fo[5],gridColorDark:fo[9]});var l_=u.createContext(s_);const c_=l_;var u_=function(){function e(){this.registry={},this.registryKeys=[]}var t=e.prototype;return t.registerData=function(r){var o=this,i=Array.isArray(r)?r:[r];i.forEach(function(a){a.key in o.registry&&o.registry[a.key]!=null&&console.debug("Overriding data registry key",a.key),o.registry[a.key]=a,o.registryKeys=Object.keys(o.registry)})},t.unregisterData=function(r){var o=this,i=Array.isArray(r)?r:[r];i.forEach(function(a){delete o.registry[a],o.registryKeys=Object.keys(o.registry)})},t.entries=function(){return Object.values(this.registry)},t.get=function(r){return this.registry[r]},t.keys=function(){return this.registryKeys},e}();function d_(){var e=u.useState(Math.random()),t=e[1],n=u.useMemo(function(){return new u_},[]);return u.useMemo(function(){return{registerData:function(){n.registerData.apply(n,arguments),t(Math.random())},unregisterData:function(){n.unregisterData.apply(n,arguments),t(Math.random())},entries:function(){return n.entries()},get:function(o){return n.get(o)},keys:function(){return n.keys()}}},[n])}var lc={width:0,height:0,margin:{top:0,right:0,bottom:0,left:0}};function f_(e){var t=u.useState({width:(e==null?void 0:e.width)==null?lc.width:e.width,height:(e==null?void 0:e.height)==null?lc.height:e.height,margin:(e==null?void 0:e.margin)==null?lc.margin:e.margin}),n=t[0],r=t[1],o=u.useCallback(function(i){(i.width!==n.width||i.height!==n.height||i.margin.left!==n.margin.left||i.margin.right!==n.margin.right||i.margin.top!==n.margin.top||i.margin.bottom!==n.margin.bottom)&&r(i)},[n.width,n.height,n.margin.left,n.margin.right,n.margin.bottom,n.margin.top]);return[n,o]}function zi(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function p_(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function cc(e){let t,n,r;e.length!==2?(t=zi,n=(s,l)=>zi(e(s),l),r=(s,l)=>e(s)-l):(t=e===zi||e===p_?e:h_,n=e,r=e);function o(s,l,c=0,d=s.length){if(c<d){if(t(l,l)!==0)return d;do{const f=c+d>>>1;n(s[f],l)<0?c=f+1:d=f}while(c<d)}return c}function i(s,l,c=0,d=s.length){if(c<d){if(t(l,l)!==0)return d;do{const f=c+d>>>1;n(s[f],l)<=0?c=f+1:d=f}while(c<d)}return c}function a(s,l,c=0,d=s.length){const f=o(s,l,c,d-1);return f>c&&r(s[f-1],l)>-r(s[f],l)?f-1:f}return{left:o,center:a,right:i}}function h_(){return 0}function m_(e){return e===null?NaN:+e}const v_=cc(zi).left;cc(m_).center;function jv(e,t){let n,r;if(t===void 0)for(const o of e)o!=null&&(n===void 0?o>=o&&(n=r=o):(n>o&&(n=o),r<o&&(r=o)));else{let o=-1;for(let i of e)(i=t(i,++o,e))!=null&&(n===void 0?i>=i&&(n=r=i):(n>i&&(n=i),r<i&&(r=i)))}return[n,r]}function g_(e,t,n){e=+e,t=+t,n=(o=arguments.length)<2?(t=e,e=0,1):o<3?1:+n;for(var r=-1,o=Math.max(0,Math.ceil((t-e)/n))|0,i=new Array(o);++r<o;)i[r]=e+r*n;return i}function uc(e){return(e==null?void 0:e.type)==="band"||(e==null?void 0:e.type)==="ordinal"||(e==null?void 0:e.type)==="point"}function vr(){return vr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},vr.apply(this,arguments)}function y_(e){var t=e.dataRegistry,n=e.xRange,r=e.xScaleConfig,o=e.yRange,i=e.yScaleConfig,a=t.keys(),s=n[0],l=n[1],c=o[0],d=o[1],f=u.useMemo(function(){var m=a.map(function(y){return t.get(y)}),h=m.reduce(function(y,b){return b?y.concat(b.data.map(function($){return b.xAccessor($)})):y},[]);if(h.length!==0){var v=uc(r)?h:jv(h),x=pl(r)?io(vr({range:[s,l],domain:v,zero:!0},r)):io(vr({range:[s,l],domain:v},r));return m.forEach(function(y){y!=null&&y.xScale&&(x=y.xScale(x))}),x}},[t,r,a,s,l]),p=u.useMemo(function(){var m=a.map(function(y){return t.get(y)}),h=m.reduce(function(y,b){return b?y.concat(b.data.map(function($){return b.yAccessor($)})):y},[]);if(h.length!==0){var v=uc(i)?h:jv(h),x=pl(i)?io(vr({range:[c,d],domain:v,zero:!0},i)):io(vr({range:[c,d],domain:v},i));return m.forEach(function(y){y!=null&&y.yScale&&(x=y.yScale(x))}),x}},[t,i,a,c,d]);return{xScale:f,yScale:p}}function zv(e){var t=e.initialDimensions,n=e.theme,r=e.xScale,o=e.yScale,i=e.children,a=e.horizontal,s=a===void 0?"auto":a,l=e.resizeObserverPolyfill,c=u.useContext(c_),d=n||c,f=f_(t),p=f[0],m=p.width,h=p.height,v=p.margin,x=f[1],y=Math.max(0,m-v.left-v.right),b=Math.max(0,h-v.top-v.bottom),$=d_(),S=y_({dataRegistry:$,xScaleConfig:r,yScaleConfig:o,xRange:[v.left,Math.max(0,m-v.right)],yRange:[Math.max(0,h-v.bottom),v.top]}),w=S.xScale,T=S.yScale,O=$.keys(),P=u.useMemo(function(){return JO({domain:O,range:d.colors})},[O,d.colors]),_=s==="auto"?uc(o)||o.type==="time"||o.type==="utc":s,j=u.useMemo(function(){return{dataRegistry:$,registerData:$.registerData,unregisterData:$.unregisterData,xScale:w,yScale:T,colorScale:P,theme:d,width:m,height:h,margin:v,innerWidth:y,innerHeight:b,setDimensions:x,horizontal:_,resizeObserverPolyfill:l}},[P,$,h,_,b,y,v,x,d,m,w,T,l]);return u.createElement(Ot.Provider,{value:j},i)}zv.propTypes={children:ne.node.isRequired,horizontal:ne.oneOfType([ne.bool,ne.oneOf(["auto"])])};function Wv(e){var t=e.source,n=e.onPointerOut,r=n===void 0?!0:n,o=e.onPointerMove,i=o===void 0?!0:o,a=e.onPointerUp,s=a===void 0?!0:a,l=e.onPointerDown,c=l===void 0?!0:l,d=e.onFocus,f=d===void 0?!1:d,p=e.onBlur,m=p===void 0?!1:p,h=fn(),v=u.useCallback(function(w){return h==null?void 0:h("pointermove",w,t)},[h,t]),x=u.useCallback(function(w){return h==null?void 0:h("pointerout",w,t)},[h,t]),y=u.useCallback(function(w){return h==null?void 0:h("pointerup",w,t)},[h,t]),b=u.useCallback(function(w){return h==null?void 0:h("pointerdown",w,t)},[h,t]),$=u.useCallback(function(w){return h==null?void 0:h("focus",w,t)},[h,t]),S=u.useCallback(function(w){return h==null?void 0:h("blur",w,t)},[h,t]);return{onPointerMove:i?v:void 0,onFocus:f?$:void 0,onBlur:m?S:void 0,onPointerOut:r?x:void 0,onPointerUp:s?y:void 0,onPointerDown:c?b:void 0}}var b_="GLYPHSERIES_EVENT_SOURCE",dc="XYCHART_EVENT_SOURCE";function Bv(e){return!!e&&("clientX"in e||"changedTouches"in e)}function x_(e){return!!e&&!Bv(e)}function Uv(e){var t=e.scale,n=e.accessor,r=e.scaledValue,o=e.data,i=t,a,s;if("invert"in i&&typeof i.invert=="function"){var l=cc(n).left,c=Number(i.invert(r)),d=l(o,c),f=o[d-1],p=o[d];a=!f||Math.abs(c-n(f))>Math.abs(c-n(p))?p:f,s=a===f?d-1:d}else if("step"in i&&typeof i.step<"u"){var m=t.domain(),h=t.range().map(Number),v=[].concat(h).sort(function(T,O){return T-O}),x=g_(v[0],v[1],i.step()),y=v_(x,r),b=h[0]<h[1]?m:m.reverse(),$=b[y-1],S=o.findIndex(function(T){return String(n(T))===String($)});a=o[S],s=S}else return console.warn("[visx/xychart/findNearestDatum] encountered incompatible scale type, bailing"),null;if(a==null||s==null)return null;var w=Math.abs(Number(i(n(a)))-r);return{datum:a,index:s,distance:w}}function w_(e){var t=e.xScale,n=e.xAccessor,r=e.yScale,o=e.yAccessor,i=e.point,a=e.data;if(!i)return null;var s=Uv({scale:t,accessor:n,scaledValue:i.x,data:a});return s?{datum:s.datum,index:s.index,distanceX:s.distance,distanceY:Math.abs(Number(r(o(s.datum)))-i.y)}:null}function $_(e){var t=e.yScale,n=e.yAccessor,r=e.xScale,o=e.xAccessor,i=e.point,a=e.data;if(!i)return null;var s=Uv({scale:t,accessor:n,scaledValue:i.y,data:a});return s?{datum:s.datum,index:s.index,distanceY:s.distance,distanceX:Math.abs(Number(r(o(s.datum)))-i.x)}:null}function fc(){return fc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},fc.apply(this,arguments)}var pc="__POINTER_EVENTS_ALL",Wi="__POINTER_EVENTS_NEAREST";function Hv(e){var t=e.dataKey,n=e.findNearestDatum,r=e.onBlur,o=e.onFocus,i=e.onPointerMove,a=e.onPointerOut,s=e.onPointerUp,l=e.onPointerDown,c=e.allowedSources,d=u.useContext(Ot),f=d.width,p=d.height,m=d.horizontal,h=d.dataRegistry,v=d.xScale,x=d.yScale,y=n||(m?$_:w_),b=u.useCallback(function(_){var j=_||{},F=j.svgPoint,V=j.event,R={},X=null,C=1/0;if(_&&V&&F&&f&&p&&v&&x){var I,H=t===Wi||t===pc,B=H?(I=h==null?void 0:h.keys())!=null?I:[]:Array.isArray(t)?t:[t];B.forEach(function(N){var z=h==null?void 0:h.get(N);if(z){var J=y({dataKey:N,data:z.data,height:p,point:F,width:f,xAccessor:z.xAccessor,xScale:v,yAccessor:z.yAccessor,yScale:x});if(J&&(R[N]=fc({key:N,svgPoint:F,event:V},J),t===Wi)){var Q,oe,te=Math.sqrt(((Q=J.distanceX)!=null?Q:Math.pow(1/0,2))+((oe=J.distanceY)!=null?oe:Math.pow(1/0,2)));X=te<C?R[N]:X,C=Math.min(C,te)}}});var A=t===Wi?[X]:t===pc||Array.isArray(t)?Object.values(R):[R[t]];return A.filter(function(N){return N})}return[]},[t,h,v,x,f,p,y]),$=u.useCallback(function(_){i&&b(_).forEach(function(j){return i(j)})},[b,i]),S=u.useCallback(function(_){s&&b(_).forEach(function(j){return s(j)})},[b,s]),w=u.useCallback(function(_){l&&b(_).forEach(function(j){return l(j)})},[b,l]),T=u.useCallback(function(_){o&&b(_).forEach(function(j){return o(j)})},[b,o]),O=u.useCallback(function(_){var j=_==null?void 0:_.event;j&&Bv(j)&&a&&a(j)},[a]),P=u.useCallback(function(_){var j=_==null?void 0:_.event;j&&x_(j)&&r&&r(j)},[r]);fn("pointermove",i?$:void 0,c),fn("pointerout",a?O:void 0,c),fn("pointerup",s?S:void 0,c),fn("pointerdown",l?w:void 0,c),fn("focus",o?T:void 0,c),fn("blur",r?P:void 0,c)}function Bi(){return Bi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Bi.apply(this,arguments)}var C_={top:50,right:50,bottom:50,left:50},S_=[dc];function gr(e){var t=e.accessibilityLabel,n=t===void 0?"XYChart":t,r=e.captureEvents,o=r===void 0?!0:r,i=e.children,a=e.height,s=e.horizontal,l=e.margin,c=l===void 0?C_:l,d=e.onPointerMove,f=e.onPointerOut,p=e.onPointerUp,m=e.onPointerDown,h=e.pointerEventsDataKey,v=h===void 0?"nearest":h,x=e.theme,y=e.width,b=e.xScale,$=e.yScale,S=e.resizeObserverPolyfill,w=u.useContext(Ot),T=w.setDimensions,O=w.resizeObserverPolyfill,P=u.useContext(co),_=fn();u.useEffect(function(){T&&y!=null&&a!=null&&y>0&&a>0&&T({width:y,height:a,margin:c})},[T,y,a,c]);var j=Wv({source:dc});return Hv({dataKey:v==="nearest"?Wi:pc,onPointerMove:d,onPointerOut:f,onPointerUp:p,onPointerDown:m,allowedSources:S_}),T?y==null||a==null?u.createElement(nO,{resizeObserverPolyfill:O},function(F){return u.createElement(gr,Bi({},e,{width:e.width==null?F.width:e.width,height:e.height==null?F.height:e.height}))}):P==null?u.createElement(Nv,null,u.createElement(gr,e)):_==null?u.createElement(dO,null,u.createElement(gr,e)):y<=0||a<=0?(console.info("XYChart has a zero width or height, bailing",{width:y,height:a}),null):u.createElement("svg",{width:y,height:a,"aria-label":n},i,o&&u.createElement("rect",Bi({x:c.left,y:c.top,width:y-c.left-c.right,height:a-c.top-c.bottom,fill:"transparent"},j))):!b||!$?(console.warn("[@visx/xychart] XYChart: When no DataProvider is available in context, you must pass xScale & yScale config to XYChart."),null):u.createElement(zv,{xScale:b,yScale:$,theme:x,initialDimensions:{width:y,height:a,margin:c},horizontal:s,resizeObserverPolyfill:S},u.createElement(gr,e))}gr.propTypes={accessibilityLabel:ne.string,captureEvents:ne.bool,width:ne.number,height:ne.number,children:ne.node.isRequired,horizontal:ne.oneOfType([ne.bool,ne.oneOf(["auto"])]),onPointerMove:ne.func,onPointerOut:ne.func,onPointerUp:ne.func,onPointerDown:ne.func,pointerEventsDataKey:ne.oneOf(["all","nearest"])};function hc(){return hc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},hc.apply(this,arguments)}function E_(e){function t(n){var r=n.dataKey,o=n.data,i=n.xAccessor,a=n.yAccessor,s=u.useContext(Ot),l=s.xScale,c=s.yScale,d=s.dataRegistry;u.useEffect(function(){return d&&d.registerData({key:r,data:o,xAccessor:i,yAccessor:a}),function(){return d==null?void 0:d.unregisterData(r)}},[d,r,o,i,a]);var f=d==null?void 0:d.get(r);if(!l||!c||!f)return null;var p=e;return u.createElement(p,hc({},n,{xScale:l,yScale:c,data:f.data,xAccessor:f.xAccessor,yAccessor:f.yAccessor}))}return t}function Gv(e,t,n){return n===void 0&&(n="center"),function(r){var o=e(t(r));if(ft(o)){var i=(n==="start"?0:hl(e))/(n==="center"?2:1);return o+i}return NaN}}function T_(e){var t,n=e.dataKey,r=e.enableEvents,o=e.findNearestDatum,i=e.onBlur,a=e.onFocus,s=e.onPointerMove,l=e.onPointerOut,c=e.onPointerUp,d=e.onPointerDown,f=e.source,p=e.allowedSources,m=(t=u.useContext(co))!=null?t:{},h=m.showTooltip,v=m.hideTooltip,x=u.useCallback(function(w){h(w),s&&s(w)},[h,s]),y=u.useCallback(function(w){h(w),a&&a(w)},[h,a]),b=u.useCallback(function(w){v(),w&&l&&l(w)},[v,l]),$=u.useCallback(function(w){v(),w&&i&&i(w)},[v,i]),S=u.useCallback(function(w){h(w),d&&d(w)},[h,d]);return Hv({dataKey:n,findNearestDatum:o,onBlur:r?$:void 0,onFocus:r?y:void 0,onPointerMove:r?x:void 0,onPointerOut:r?b:void 0,onPointerUp:r?c:void 0,onPointerDown:r?S:void 0,allowedSources:p}),Wv({source:f,onBlur:!!i&&r,onFocus:!!a&&r,onPointerMove:!!s&&r,onPointerOut:!!l&&r,onPointerUp:!!c&&r,onPointerDown:!!d&&r})}function mc(){return mc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},mc.apply(this,arguments)}function Vv(e){var t,n,r,o=e.colorAccessor,i=e.data,a=e.dataKey,s=e.onBlur,l=e.onFocus,c=e.onPointerMove,d=e.onPointerOut,f=e.onPointerUp,p=e.onPointerDown,m=e.enableEvents,h=m===void 0?!0:m,v=e.renderGlyphs,x=e.size,y=x===void 0?8:x,b=e.xAccessor,$=e.xScale,S=e.yAccessor,w=e.yScale,T=u.useContext(Ot),O=T.colorScale,P=T.theme,_=T.horizontal,j=u.useMemo(function(){return Gv($,b)},[$,b]),F=u.useMemo(function(){return Gv(w,S)},[w,S]),V=(t=(n=O==null?void 0:O(a))!=null?n:P==null||(r=P.colors)==null?void 0:r[0])!=null?t:"#222",R=b_+"-"+a,X=T_({dataKey:a,enableEvents:h,onBlur:s,onFocus:l,onPointerMove:c,onPointerOut:d,onPointerUp:f,onPointerDown:p,source:R,allowedSources:[dc,R]}),C=u.useMemo(function(){return i.map(function(I,H){var B,A=j(I);if(!ft(A))return null;var N=F(I);return ft(N)?{key:""+H,x:A,y:N,color:(B=o==null?void 0:o(I,H))!=null?B:V,size:typeof y=="function"?y(I):y,datum:I}:null}).filter(function(I){return I})},[V,o,i,j,F,y]);return u.createElement(u.Fragment,null,v(mc({glyphs:C,xScale:$,yScale:w,horizontal:_},X)))}Vv.propTypes={colorAccessor:ne.func,size:ne.oneOfType([ne.number,ne.func]),renderGlyphs:ne.func.isRequired};const P_=E_(Vv);function M_(e){var t=e.key,n=e.color,r=e.x,o=e.y,i=e.size,a=e.onBlur,s=e.onFocus,l=e.onPointerMove,c=e.onPointerOut,d=e.onPointerUp;return u.createElement("circle",{className:"visx-circle-glyph",key:t,tabIndex:a||s?0:void 0,fill:n,r:i/2,cx:r,cy:o,onBlur:a,onFocus:s,onPointerMove:l,onPointerOut:c,onPointerUp:d})}var k_=["renderGlyph"];function Ui(){return Ui=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ui.apply(this,arguments)}function O_(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function __(e){var t=e.renderGlyph,n=t===void 0?M_:t,r=O_(e,k_),o=u.useCallback(function(i){var a=i.glyphs,s=i.onPointerMove,l=i.onPointerOut,c=i.onPointerUp,d=i.onFocus,f=i.onBlur;return a.map(function(p){return u.createElement(u.Fragment,{key:p.key},n(Ui({},p,{onPointerMove:s,onPointerOut:l,onPointerUp:c,onFocus:d,onBlur:f})))})},[n]);return u.createElement(P_,Ui({},r,{renderGlyphs:o}))}function qv(e){var t=e.top,n=t===void 0?0:t,r=e.left,o=r===void 0?0:r,i=e.className,a=e.children;return u.createElement(En,{className:et("visx-glyph",i),top:n,left:o},a)}qv.propTypes={top:ne.number,left:ne.number,className:ne.string,children:ne.node};var N_=["top","left","className"];function vc(){return vc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},vc.apply(this,arguments)}function A_(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function gc(e){var t=e.top,n=t===void 0?0:t,r=e.left,o=r===void 0?0:r,i=e.className,a=A_(e,N_);return u.createElement(qv,{top:n,left:o},u.createElement("circle",vc({className:et("visx-glyph-dot",i)},a)))}gc.propTypes={className:ne.string,top:ne.number,left:ne.number,r:ne.number,cx:ne.number,cy:ne.number};var D_=["className","children","debounceTime","ignoreDimensions","parentSizeStyles","enableDebounceLeadingCall","resizeObserverPolyfill"];function Hi(){return Hi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Hi.apply(this,arguments)}function I_(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}var L_=[],F_={width:"100%",height:"100%"};function Gi(e){var t=e.className,n=e.children,r=e.debounceTime,o=r===void 0?300:r,i=e.ignoreDimensions,a=i===void 0?L_:i,s=e.parentSizeStyles,l=s===void 0?F_:s,c=e.enableDebounceLeadingCall,d=c===void 0?!0:c,f=e.resizeObserverPolyfill,p=I_(e,D_),m=u.useRef(null),h=u.useRef(0),v=u.useState({width:0,height:0,top:0,left:0}),x=v[0],y=v[1],b=u.useMemo(function(){var $=Array.isArray(a)?a:[a];return Pv(function(S){y(function(w){var T=Object.keys(w),O=T.filter(function(_){return w[_]!==S[_]}),P=O.every(function(_){return $.includes(_)});return P?w:S})},o,{leading:d})},[o,d,a]);return u.useEffect(function(){var $=f||window.ResizeObserver,S=new $(function(w){w.forEach(function(T){var O,P=(O=T==null?void 0:T.contentRect)!=null?O:{},_=P.left,j=P.top,F=P.width,V=P.height;h.current=window.requestAnimationFrame(function(){b({width:F,height:V,top:j,left:_})})})});return m.current&&S.observe(m.current),function(){window.cancelAnimationFrame(h.current),S.disconnect(),b.cancel()}},[b,f]),u.createElement("div",Hi({style:l,ref:m,className:t},p),n(Hi({},x,{ref:m.current,resize:b})))}Gi.propTypes={className:ne.string,debounceTime:ne.number,enableDebounceLeadingCall:ne.bool,ignoreDimensions:ne.oneOfType([ne.any,ne.arrayOf(ne.any)]),children:ne.func.isRequired};const Yv=[{name:"default",dark:"#0091E7",light:"#62B9ED"},{name:"yellow",dark:"#8C6A00",light:"#FFDE88"},{name:"plum",dark:"#7D1779",light:"#E1AADD"},{name:"cyan",dark:"#329F95",light:"#C0FFF9"},{name:"purple",dark:"#7651BC",light:"#E7DAFF"},{name:"pink",dark:"#C01443",light:"#FAD4D4"},{name:"green",dark:"#44812F",light:"#B1E39F"},{name:"orange",dark:"#B96400",light:"#FFE7C5"},{name:"teal",dark:"#237C73",light:"#A1DFD5"},{name:"red",dark:"#C62C02",light:"#FFE1D9"}];function Re(e){return Yv[e%Yv.length]}function yc({textLabel:e,axisCharLimit:t,x:n,y:r,textStyles:o}){return L.jsx(Of,{children:L.jsxs(_f,{children:[L.jsx(Nf,{asChild:!0,children:L.jsx("text",{className:"pointer-events-auto cursor-pointer",...o,x:n,y:r,children:e&&(e==null?void 0:e.length)>t?`${e==null?void 0:e.substring(0,t)}...`:e})}),L.jsx(Af,{children:L.jsx(es,{className:"rabbit-ds",children:L.jsx("p",{children:e})})})]})})}const Kv=(e,t)=>u.Children.map(e,n=>u.isValidElement(n)&&typeof n.type=="function"&&n.type.displayName===t.displayName?n:null);function bc({value:e,darkColor:t,lightColor:n}){return L.jsxs("div",{className:"px-2 py-1 justify-start items-center gap-2 inline-flex",children:[L.jsx("div",{style:{backgroundColor:n,borderColor:t},className:"w-3 h-3 relative rounded-3xl border"}),L.jsx("div",{className:"justify-start items-start flex",children:L.jsx("div",{className:"text-zinc-800 text-xs font-normal leading-none",children:e})})]})}function xc({label:e,value:t}){return L.jsxs("div",{className:"px-1 py-0.5 flex-col justify-start items-start inline-flex max-w-sm",children:[L.jsx("div",{className:" text-stone-500 text-[10px] font-normal leading-none",children:e}),L.jsx("div",{className:"justify-start items-start text-sm flex font-medium",children:t||"-"})]})}function Ue({children:e,showSideBySide:t,tooltipTitle:n}){const r=Kv(e,bc),o=Kv(e,xc);return L.jsxs("div",{className:"rabbit-ds z-[1500] relative h-auto w-auto min-w-[200px] max-w-[400px] p-2 bg-white rounded-lg shadow flex-col justify-start items-start gap-2 inline-flex",children:[L.jsx("div",{className:"px-3 py-1 text-zinc-800 font-medium text-xs leading-none",children:n}),L.jsxs("div",{className:"w-full p-2 rounded-lg flex-col justify-start items-start flex",children:[t&&L.jsxs("div",{className:_e("w-full flex"),children:[o&&o[0],L.jsx("div",{className:"w-0 border-r mx-3"}),o&&o[1]]}),!t&&L.jsx("div",{className:_e("w-full grid gap-3 auto-rows-auto"),children:o})]}),r&&r.length>0?L.jsx("div",{className:"h-px px-2 w-full border-top bg-gray-100"}):null,r]})}bc.displayName="Legend",xc.displayName="Item",Ue.Legend=bc,Ue.Item=xc,Ue.defaultProps={showSideBySide:!1};function Xv({xValue:e,yValue:t,tooltipTitle:n,xAxisLabel:r,yAxisLabel:o,showSideBySide:i,legendValue:a,legendDarkColor:s,legendLightColor:l}){const c=e==null?void 0:e.toString(),d=t==null?void 0:t.toString();return L.jsxs(Ue,{tooltipTitle:n,showSideBySide:i,children:[L.jsx(Ue.Item,{label:r,value:c}),L.jsx(Ue.Item,{label:o,value:d}),L.jsx(Ue.Legend,{value:a,darkColor:s,lightColor:l})]})}Xv.defaultProps={xValue:void 0,yValue:void 0};function j_({data:e,xAccessor:t,yAccessor:n,connectNulls:r=!1}){const o=u.useContext(Ot),i=r?e.filter(a=>a.y!==null):e;return L.jsx(cM,{data:i,stroke:i[0].color.dark,strokeWidth:1,x:a=>{var s,l;return((s=o==null?void 0:o.xScale)==null?void 0:s.call(o,t(a)))+((l=o==null?void 0:o.xScale)==null?void 0:l.bandwidth())/2},y:a=>{var s;return(s=o==null?void 0:o.yScale)==null?void 0:s.call(o,n(a))}})}var wc={exports:{}};(function(e,t){(function(n,r){r(t)})(Ar,function(n){var r,o=Object.defineProperty,i=Object.defineProperties,a=Object.getOwnPropertyDescriptors,s=Object.getOwnPropertySymbols,l=Object.prototype.hasOwnProperty,c=Object.prototype.propertyIsEnumerable,d=Math.pow,f=(g,E,M)=>E in g?o(g,E,{enumerable:!0,configurable:!0,writable:!0,value:M}):g[E]=M,p=(g,E)=>{for(var M in E||(E={}))l.call(E,M)&&f(g,M,E[M]);if(s)for(var M of s(E))c.call(E,M)&&f(g,M,E[M]);return g},m=(g,E)=>i(g,a(E)),h=(g,E)=>{var M={};for(var D in g)l.call(g,D)&&E.indexOf(D)<0&&(M[D]=g[D]);if(g!=null&&s)for(var D of s(g))E.indexOf(D)<0&&c.call(g,D)&&(M[D]=g[D]);return M},v=(g,E,M)=>new Promise((D,G)=>{var Z=ie=>{try{K(M.next(ie))}catch(se){G(se)}},W=ie=>{try{K(M.throw(ie))}catch(se){G(se)}},K=ie=>ie.done?D(ie.value):Promise.resolve(ie.value).then(Z,W);K((M=M.apply(g,E)).next())});function x(g,E){return g[13]=1,g[14]=E>>8,g[15]=E&255,g[16]=E>>8,g[17]=E&255,g}const y="p".charCodeAt(0),b="H".charCodeAt(0),$="Y".charCodeAt(0),S="s".charCodeAt(0);let w;function T(){const g=new Int32Array(256);for(let E=0;E<256;E++){let M=E;for(let D=0;D<8;D++)M=M&1?3988292384^M>>>1:M>>>1;g[E]=M}return g}function O(g){let E=-1;w||(w=T());for(let M=0;M<g.length;M++)E=w[(E^g[M])&255]^E>>>8;return E^-1}function P(g){const E=g.length-1;for(let M=E;M>=4;M--)if(g[M-4]===9&&g[M-3]===y&&g[M-2]===b&&g[M-1]===$&&g[M]===S)return M-3;return 0}function _(g,E,M=!1){const D=new Uint8Array(13);E*=39.3701,D[0]=y,D[1]=b,D[2]=$,D[3]=S,D[4]=E>>>24,D[5]=E>>>16,D[6]=E>>>8,D[7]=E&255,D[8]=D[4],D[9]=D[5],D[10]=D[6],D[11]=D[7],D[12]=1;const G=O(D),Z=new Uint8Array(4);if(Z[0]=G>>>24,Z[1]=G>>>16,Z[2]=G>>>8,Z[3]=G&255,M){const W=P(g);return g.set(D,W),g.set(Z,W+13),g}else{const W=new Uint8Array(4);W[0]=0,W[1]=0,W[2]=0,W[3]=9;const K=new Uint8Array(54);return K.set(g,0),K.set(W,33),K.set(D,37),K.set(Z,50),K}}const j="AAlwSFlz",F="AAAJcEhZ",V="AAAACXBI";function R(g){let E=g.indexOf(j);return E===-1&&(E=g.indexOf(F)),E===-1&&(E=g.indexOf(V)),E}const X="[modern-screenshot]",C=typeof window<"u",I=C&&"Worker"in window,H=C&&"atob"in window,B=C&&"btoa"in window,A=C?(r=window.navigator)==null?void 0:r.userAgent:"",N=A.includes("Chrome"),z=A.includes("AppleWebKit")&&!N,J=A.includes("Firefox"),Q=g=>g&&"__CONTEXT__"in g,oe=g=>g.constructor.name==="CSSFontFaceRule",te=g=>g.constructor.name==="CSSImportRule",ae=g=>g.nodeType===1,Y=g=>typeof g.className=="object",le=g=>Y(g)&&g.tagName==="svg",U=g=>Y(g)&&g.tagName==="image",q=g=>ae(g)&&typeof g.style<"u"&&!Y(g),re=g=>g.nodeType===8,k=g=>g.nodeType===3,de=g=>g.tagName==="IMG",pe=g=>g.tagName==="VIDEO",Ce=g=>g.tagName==="CANVAS",ke=g=>g.tagName==="TEXTAREA",je=g=>g.tagName==="INPUT",_t=g=>g.tagName==="STYLE",mn=g=>g.tagName==="SCRIPT",Ze=g=>g.tagName==="SELECT",qt=g=>g.tagName==="SLOT",yr=g=>g.tagName==="IFRAME",Le=(...g)=>console.warn(X,...g),Ri=g=>console.time(`${X} ${g}`),Zi=g=>console.timeEnd(`${X} ${g}`),po=g=>{var E;const M=(E=g==null?void 0:g.createElement)==null?void 0:E.call(g,"canvas");return M&&(M.height=M.width=1),M&&"toDataURL"in M&&!!M.toDataURL("image/webp").includes("image/webp")},rt=g=>g.startsWith("data:");function vn(g,E){if(g.match(/^[a-z]+:\/\//i))return g;if(C&&g.match(/^\/\//))return window.location.protocol+g;if(g.match(/^[a-z]+:/i)||!C)return g;const M=zn().implementation.createHTMLDocument(),D=M.createElement("base"),G=M.createElement("a");return M.head.appendChild(D),M.body.appendChild(G),E&&(D.href=E),G.href=g,G.href}function zn(g){var E;return(E=g&&ae(g)?g==null?void 0:g.ownerDocument:g)!=null?E:window.document}const Wn="http://www.w3.org/2000/svg";function ho(g,E,M){const D=zn(M).createElementNS(Wn,"svg");return D.setAttributeNS(null,"width",g.toString()),D.setAttributeNS(null,"height",E.toString()),D.setAttributeNS(null,"viewBox",`0 0 ${g} ${E}`),D}function br(g,E){let M=new XMLSerializer().serializeToString(g);return E&&(M=M.replace(/[\u0000-\u0008\u000B\u000C\u000E-\u001F\uD800-\uDFFF\uFFFE\uFFFF]/ug,"")),`data:image/svg+xml;charset=utf-8,${encodeURIComponent(M)}`}function Qi(g,E="image/png",M=1){return v(this,null,function*(){try{return yield new Promise((D,G)=>{g.toBlob(Z=>{Z?D(Z):G(new Error("Blob is null"))},E,M)})}catch(D){if(H)return Le("Failed canvas to blob",{type:E,quality:M},D),Ji(g.toDataURL(E,M));throw D}})}function Ji(g){var E,M;const[D,G]=g.split(","),Z=(M=(E=D.match(/data:(.+);/))==null?void 0:E[1])!=null?M:void 0,W=window.atob(G),K=W.length,ie=new Uint8Array(K);for(let se=0;se<K;se+=1)ie[se]=W.charCodeAt(se);return new Blob([ie],{type:Z})}function mo(g,E){return new Promise((M,D)=>{const G=new FileReader;G.onload=()=>M(G.result),G.onerror=()=>D(G.error),G.onabort=()=>D(new Error(`Failed read blob to ${E}`)),E==="dataUrl"?G.readAsDataURL(g):E==="arrayBuffer"&&G.readAsArrayBuffer(g)})}const ea=g=>mo(g,"dataUrl"),ta=g=>mo(g,"arrayBuffer");function Nt(g,E){const M=zn(E).createElement("img");return M.decoding="sync",M.loading="eager",M.src=g,M}function Yt(g,E){return new Promise(M=>{const{timeout:D,ownerDocument:G,onError:Z}=E??{},W=typeof g=="string"?Nt(g,zn(G)):g;let K=null,ie=null;function se(){M(W),K&&clearTimeout(K),ie==null||ie()}if(D&&(K=setTimeout(se,D)),pe(W)){const ce=W.currentSrc||W.src;if(!ce)return W.poster?Yt(W.poster,E).then(M):se();if(W.readyState>=2)return se();const he=se,ue=be=>{Le("Failed video load",ce,be),Z==null||Z(be),se()};ie=()=>{W.removeEventListener("loadeddata",he),W.removeEventListener("error",ue)},W.addEventListener("loadeddata",he,{once:!0}),W.addEventListener("error",ue,{once:!0})}else{const ce=U(W)?W.href.baseVal:W.currentSrc||W.src;if(!ce)return se();const he=()=>v(this,null,function*(){if(de(W)&&"decode"in W)try{yield W.decode()}catch(be){Le("Failed to decode image, trying to render anyway",W.dataset.originalSrc||ce,be)}se()}),ue=be=>{Le("Failed image load",W.dataset.originalSrc||ce,be),se()};if(de(W)&&W.complete)return he();ie=()=>{W.removeEventListener("load",he),W.removeEventListener("error",ue)},W.addEventListener("load",he,{once:!0}),W.addEventListener("error",ue,{once:!0})}})}function vo(g,E){return v(this,null,function*(){q(g)&&(de(g)||pe(g)?yield Yt(g,{timeout:E}):yield Promise.all(["img","video"].flatMap(M=>Array.from(g.querySelectorAll(M)).map(D=>Yt(D,{timeout:E})))))})}const go=function(){let g=0;const E=()=>`0000${(Math.random()*d(36,4)<<0).toString(36)}`.slice(-4);return()=>(g+=1,`u${E()}${g}`)}();function yo(g){return g==null?void 0:g.split(",").map(E=>E.trim().replace(/"|'/g,"").toLowerCase()).filter(Boolean)}function na(g){return{time:E=>g&&Ri(E),timeEnd:E=>g&&Zi(E),warn:(...E)=>g&&Le(...E)}}function ra(g){return{cache:g?"no-cache":"force-cache"}}function st(g,E){return v(this,null,function*(){return Q(g)?g:oa(g,m(p({},E),{autoDestruct:!0}))})}function oa(g,E){return v(this,null,function*(){var M,D,G,Z,W;const{scale:K=1,workerUrl:ie,workerNumber:se=1}=E||{},ce=!!(E!=null&&E.debug),he=(M=E==null?void 0:E.features)!=null?M:!0,ue=(D=g.ownerDocument)!=null?D:C?window.document:void 0,be=(Z=(G=g.ownerDocument)==null?void 0:G.defaultView)!=null?Z:C?window:void 0,ye=new Map,$e=m(p({width:0,height:0,quality:1,type:"image/png",scale:K,backgroundColor:null,style:null,filter:null,maximumCanvasSize:0,timeout:3e4,progress:null,debug:ce,fetch:p({requestInit:ra((W=E==null?void 0:E.fetch)==null?void 0:W.bypassingCache),placeholderImage:"data:image/png;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",bypassingCache:!1},E==null?void 0:E.fetch),font:{},drawImageInterval:100,workerUrl:null,workerNumber:se,onCloneNode:null,onEmbedNode:null,onCreateForeignObjectSvg:null,autoDestruct:!1},E),{__CONTEXT__:!0,log:na(ce),node:g,ownerDocument:ue,ownerWindow:be,dpi:K===1?null:96*K,svgStyleElement:Qe(ue),svgDefsElement:ue==null?void 0:ue.createElementNS(Wn,"defs"),svgStyles:new Map,defaultComputedStyles:new Map,workers:[...new Array(I&&ie&&se?se:0)].map(()=>{try{const Ie=new Worker(ie);return Ie.onmessage=Ne=>v(this,null,function*(){var Je,Rt,gn,_g;const{url:Oc,result:Ng}=Ne.data;Ng?(Rt=(Je=ye.get(Oc))==null?void 0:Je.resovle)==null||Rt.call(Je,Ng):(_g=(gn=ye.get(Oc))==null?void 0:gn.reject)==null||_g.call(gn,new Error(`Error receiving message from worker: ${Oc}`))}),Ie.onmessageerror=Ne=>{var Je,Rt;const{url:gn}=Ne.data;(Rt=(Je=ye.get(gn))==null?void 0:Je.reject)==null||Rt.call(Je,new Error(`Error receiving message from worker: ${gn}`))},Ie}catch(Ie){return Le("Failed to new Worker",Ie),null}}).filter(Boolean),fontFamilies:new Set,fontCssTexts:new Map,acceptOfImage:`${[po(ue)&&"image/webp","image/svg+xml","image/*","*/*"].filter(Boolean).join(",")};q=0.8`,requests:ye,drawImageCount:0,tasks:[],features:he,isEnable:Ie=>{var Ne;return typeof he=="boolean"?he:(Ne=he[Ie])!=null?Ne:!0}});$e.log.time("wait until load"),yield vo(g,$e.timeout),$e.log.timeEnd("wait until load");const{width:Ee,height:Te}=pt(g,$e);return $e.width=Ee,$e.height=Te,$e})}function Qe(g){if(!g)return;const E=g.createElement("style"),M=E.ownerDocument.createTextNode(`
74
74
  .______background-clip--text {
75
75
  background-clip: text;
76
76
  -webkit-background-clip: text;
77
77
  }
78
- `);return E.appendChild(M),E}function pt(g,E){let{width:M,height:D}=E;if(ae(g)&&(!M||!D)){const G=g.getBoundingClientRect();M=M||G.width||Number(g.getAttribute("width"))||0,D=D||G.height||Number(g.getAttribute("height"))||0}return{width:M,height:D}}function Kt(g,E){return v(this,null,function*(){const{log:M,timeout:D,drawImageCount:G,drawImageInterval:Z}=E;M.time("image to canvas");const W=yield Yt(g,{timeout:D}),{canvas:K,context2d:ie}=Xt(g.ownerDocument,E),se=()=>{try{ie==null||ie.drawImage(W,0,0,K.width,K.height)}catch(ce){Le("Failed to drawImage",ce)}};if(se(),E.isEnable("fixSvgXmlDecode"))for(let ce=0;ce<G;ce++)yield new Promise(he=>{setTimeout(()=>{se(),he()},ce+Z)});return E.drawImageCount=0,M.timeEnd("image to canvas"),K})}function Xt(g,E){const{width:M,height:D,scale:G,backgroundColor:Z,maximumCanvasSize:W}=E,K=g.createElement("canvas");K.width=Math.floor(M*G),K.height=Math.floor(D*G),K.style.width=`${M}px`,K.style.height=`${D}px`,W&&(K.width>W||K.height>W)&&(K.width>W&&K.height>W?K.width>K.height?(K.height*=W/K.width,K.width=W):(K.width*=W/K.height,K.height=W):K.width>W?(K.height*=W/K.width,K.width=W):(K.width*=W/K.height,K.height=W));const ie=K.getContext("2d");return ie&&Z&&(ie.fillStyle=Z,ie.fillRect(0,0,K.width,K.height)),{canvas:K,context2d:ie}}const lt=["width","height"],Bn=["stroke","fill"];function Un(g,E,M){var D;const{defaultComputedStyles:G,ownerDocument:Z}=M,W=g.nodeName.toLowerCase(),K=Y(g)&&W!=="svg",ie=K?Bn.map(Te=>[Te,g.getAttribute(Te)]).filter(([,Te])=>Te!==null):[],se=[K&&"svg",W,ie.map((Te,Ie)=>`${Te}=${Ie}`).join(","),E].filter(Boolean).join(":");if(G.has(se))return G.get(se);let ce=M.sandbox;if(!ce)try{Z&&(ce=Z.createElement("iframe"),ce.id=`__SANDBOX__-${vo()}`,ce.width="0",ce.height="0",ce.style.visibility="hidden",ce.style.position="fixed",Z.body.appendChild(ce),(D=ce.contentWindow)==null||D.document.write('<!DOCTYPE html><meta charset="UTF-8"><title></title><body>'),M.sandbox=ce)}catch(Te){Le("Failed to create iframe sandbox",Te)}if(!ce)return new Map;const he=ce.contentWindow;if(!he)return new Map;const ue=he.document;let be,ye;K?(be=ue.createElementNS(Wn,"svg"),ye=be.ownerDocument.createElementNS(be.namespaceURI,W),ie.forEach(([Te,Ie])=>{ye.setAttributeNS(null,Te,Ie)}),be.appendChild(ye)):be=ye=ue.createElement(W),ye.textContent=" ",ue.body.appendChild(be);const $e=he.getComputedStyle(ye,E),Ee=new Map;for(let Te=$e.length,Ie=0;Ie<Te;Ie++){const _e=$e.item(Ie);lt.includes(_e)||Ee.set(_e,$e.getPropertyValue(_e))}return ue.body.removeChild(be),G.set(se,Ee),Ee}function xr(g,E){var M;const D=new Map,G=[],Z=new Map;for(let W=g.length,K=0;K<W;K++){const ie=g.item(K),se=g.getPropertyValue(ie),ce=g.getPropertyPriority(ie),he=ie.lastIndexOf("-"),ue=he>-1?ie.substring(0,he):void 0;if(ue){let be=Z.get(ue);be||(be=new Map,Z.set(ue,be)),be.set(ie,[se,ce])}E.get(ie)===se&&!ce||(ue?G.push(ue):D.set(ie,[se,ce]))}for(let W=G.length,K=0;K<W;K++)(M=Z.get(G[K]))==null||M.forEach((ie,se)=>D.set(se,ie));return D}const wr=[":before",":after"],ia=[":-webkit-scrollbar",":-webkit-scrollbar-button",":-webkit-scrollbar-thumb",":-webkit-scrollbar-track",":-webkit-scrollbar-track-piece",":-webkit-scrollbar-corner",":-webkit-resizer"];function aa(g,E,M,D){const{ownerWindow:G,svgStyleElement:Z,svgStyles:W}=D;if(!Z||!G)return;function K(ie){var se;const ce=G.getComputedStyle(g,ie);let he=ce.getPropertyValue("content");if(!he||he==="none")return;he=he.replace(/(')|(")|(counter\(.+\))/g,"");const ue=[vo()],be=Un(g,ie,D),ye=[`content: '${he}';`],$e=xr(ce,be);if($e.delete("content"),$e.delete("-webkit-locale"),((se=$e.get("background-clip"))==null?void 0:se[0])==="text"&&E.classList.add("______background-clip--text"),$e.forEach(([Ie,_e],Je)=>{ye.push(`${Je}: ${Ie}${_e?" !important":""};`)}),ye.length===1)return;try{E.className=[E.className,...ue].join(" ")}catch{return}const Ee=ye.join(`
79
- `);let Te=W.get(Ee);Te||(Te=[],W.set(Ee,Te)),Te.push(`.${ue[0]}:${ie}`)}wr.forEach(K),M&&ia.forEach(K)}function m3(g,E){ke(g)&&(E.innerHTML=g.value),(ke(g)||je(g)||Ze(g))&&E.setAttribute("value",g.value)}function v3(g,E,M,D){var G,Z,W,K;const{ownerWindow:ie}=D,se=E.style,ce=ie.getComputedStyle(g),he=Un(g,null,D),ue=xr(ce,he);return ue.delete("transition-property"),ue.delete("all"),ue.delete("d"),ue.delete("content"),M&&(ue.delete("margin-top"),ue.delete("margin-right"),ue.delete("margin-bottom"),ue.delete("margin-left"),ue.delete("margin-block-start"),ue.delete("margin-block-end"),ue.delete("margin-inline-start"),ue.delete("margin-inline-end"),ue.set("box-sizing",["border-box",""])),((G=ue.get("background-clip"))==null?void 0:G[0])==="text"&&E.classList.add("______background-clip--text"),N&&(ue.has("font-kerning")||ue.set("font-kerning",["normal",""]),(((Z=ue.get("overflow-x"))==null?void 0:Z[0])==="hidden"||((W=ue.get("overflow-y"))==null?void 0:W[0])==="hidden")&&((K=ue.get("text-overflow"))==null?void 0:K[0])==="ellipsis"&&g.scrollWidth===g.clientWidth&&ue.set("text-overflow",["clip",""])),ue.forEach(([be,ye],$e)=>{se.setProperty($e,be,ye)}),ue}function g3(g,E){return v(this,null,function*(){var M,D,G;const{ownerDocument:Z,svgDefsElement:W}=E,K=(D=(M=g.querySelectorAll)==null?void 0:M.call(g,"use"))!=null?D:[];if(K.length)for(let ie=K.length,se=0;se<ie;se++){const ce=K[se],he=(G=ce.getAttribute("xlink:href"))!=null?G:ce.getAttribute("href");if(!he)continue;const ue=Z==null?void 0:Z.querySelector(`svg ${he}`);!ue||W!=null&&W.querySelector(he)||W==null||W.appendChild(yield sa(ue,E))}return g.cloneNode(!1)})}function y3(g,E){var M;try{if((M=g==null?void 0:g.contentDocument)!=null&&M.body)return sa(g.contentDocument.body,E)}catch(D){Le("Failed to clone iframe",D)}return g.cloneNode(!1)}function yg(g){if(g.ownerDocument)try{const G=g.toDataURL();if(G!=="data:,")return Nt(G,g.ownerDocument)}catch{}const E=g.cloneNode(!1),M=g.getContext("2d"),D=E.getContext("2d");try{return M&&D&&D.putImageData(M.getImageData(0,0,g.width,g.height),0,0),E}catch(G){Le("Failed to clone canvas",G)}return E}function b3(g){return v(this,null,function*(){if(g.ownerDocument&&!g.currentSrc&&g.poster)return Nt(g.poster,g.ownerDocument);const E=g.cloneNode(!1);E.crossOrigin="anonymous",g.currentSrc&&g.currentSrc!==g.src&&(E.src=g.currentSrc);const M=E.ownerDocument;if(M){let D=!0;if(yield Yt(E,{onError:()=>D=!1}),!D)return g.poster?Nt(g.poster,g.ownerDocument):E;E.currentTime=g.currentTime,yield new Promise(Z=>{E.addEventListener("seeked",Z,{once:!0})});const G=M.createElement("canvas");G.width=g.offsetWidth,G.height=g.offsetHeight;try{const Z=G.getContext("2d");Z&&Z.drawImage(E,0,0,G.width,G.height)}catch(Z){return Le("Failed to clone video",Z),g.poster?Nt(g.poster,g.ownerDocument):E}return yg(G)}return E})}function x3(g){const E=g.cloneNode(!1);return g.currentSrc&&g.currentSrc!==g.src&&(E.src=g.currentSrc,E.srcset=""),E.loading==="lazy"&&(E.loading="eager"),E}function w3(g,E){return Ce(g)?yg(g):yr(g)?y3(g,E):de(g)?x3(g):pe(g)?b3(g):le(g)?g3(g,E):g.cloneNode(!1)}function bg(g,E,M){return v(this,null,function*(){ae(E)&&(_t(E)||mn(E))||M.filter&&!M.filter(E)||g.appendChild(yield sa(E,M))})}function xg(g,E,M){return v(this,null,function*(){var D,G;const Z=(G=ae(g)?(D=g.shadowRoot)==null?void 0:D.firstChild:void 0)!=null?G:g.firstChild;for(let W=Z;W;W=W.nextSibling)if(!re(W))if(ae(W)&&qt(W)&&typeof W.assignedNodes=="function"){const K=W.assignedNodes();for(let ie=0;ie<K.length;ie++)yield bg(E,K[ie],M)}else yield bg(E,W,M)})}function $3(g,E){const{backgroundColor:M,width:D,height:G,style:Z}=E,W=g.style;if(M&&W.setProperty("background-color",M,"important"),D&&W.setProperty("width",`${D}px`,"important"),G&&W.setProperty("height",`${G}px`,"important"),Z)for(const K in Z)W[K]=Z[K]}const C3=/^[\w-]+$/;function sa(g,E,M=!1){return v(this,null,function*(){var D,G,Z,W;const{ownerDocument:K,ownerWindow:ie,fontFamilies:se}=E;if(K&&k(g))return K.createTextNode(g.data);if(K&&ie&&ae(g)&&(q(g)||Y(g))){const he=yield w3(g,E);if(E.isEnable("removeAbnormalAttributes")){const ye=he.getAttributeNames();for(let $e=ye.length,Ee=0;Ee<$e;Ee++){const Te=ye[Ee];C3.test(Te)||he.removeAttribute(Te)}}const ue=v3(g,he,M,E);M&&$3(he,E);let be=!1;if(E.isEnable("copyScrollbar")){const ye=[(D=ue.get("overflow-x"))==null?void 0:D[0],(G=ue.get("overflow-y"))==null?void 0:G[1]];be=ye.includes("scroll")||(ye.includes("auto")||ye.includes("overlay"))&&(g.scrollHeight>g.clientHeight||g.scrollWidth>g.clientWidth)}return aa(g,he,be,E),m3(g,he),(W=go((Z=ue.get("font-family"))==null?void 0:Z[0]))==null||W.forEach(ye=>se.add(ye)),pe(g)||(yield xg(g,he,E)),he}const ce=g.cloneNode(!1);return yield xg(g,ce,E),ce})}function wg(g){if(g.ownerDocument=void 0,g.ownerWindow=void 0,g.svgStyleElement=void 0,g.svgDefsElement=void 0,g.svgStyles.clear(),g.defaultComputedStyles.clear(),g.sandbox){try{g.sandbox.remove()}catch{}g.sandbox=void 0}g.workers=[],g.fontFamilies.clear(),g.fontCssTexts.clear(),g.requests.clear(),g.tasks=[]}function S3(g){const E=g,{url:M,timeout:D,responseType:G}=E,Z=h(E,["url","timeout","responseType"]),W=new AbortController,K=D?setTimeout(()=>W.abort(),D):void 0;return fetch(M,p({signal:W.signal},Z)).then(ie=>{if(!ie.ok)throw new Error("Failed fetch, not 2xx response",{cause:ie});switch(G){case"dataUrl":return ie.blob().then(ea);case"text":default:return ie.text()}}).finally(()=>clearTimeout(K))}function la(g,E){const{url:M,requestType:D="text",responseType:G="text",imageDom:Z}=E;let W=M;const{timeout:K,acceptOfImage:ie,requests:se,fetch:{requestInit:ce,bypassingCache:he,placeholderImage:ue},workers:be}=g;D==="image"&&(z||J)&&g.drawImageCount++;let ye=se.get(M);if(!ye){he&&(W+=(/\?/.test(W)?"&":"?")+new Date().getTime());const $e=p({url:W,timeout:K,responseType:G,headers:D==="image"?{accept:ie}:void 0},ce);ye={type:D,resovle:void 0,reject:void 0,response:null},ye.response=(!z&&M.startsWith("http")&&be.length?new Promise((Ee,Te)=>{be[se.size&be.length-1].postMessage(p({rawUrl:M},$e)),ye.resovle=Ee,ye.reject=Te}):S3($e)).catch(Ee=>{if(se.delete(M),D==="image"&&ue)return Le("Failed to fetch image base64, trying to use placeholder image",W),typeof ue=="string"?ue:ue(Z);throw Ee}),se.set(M,ye)}return ye.response}function $g(g,E,M,D){return v(this,null,function*(){if(!Cg(g))return g;for(const[G,Z]of E3(g,E))try{const W=yield la(M,{url:Z,requestType:D?"image":"text",responseType:"dataUrl"});g=g.replace(T3(G),`$1${W}$3`)}catch(W){Le("Failed to fetch css data url",G,W)}return g})}function Cg(g){return/url\((['"]?)([^'"]+?)\1\)/.test(g)}const Sg=/url\((['"]?)([^'"]+?)\1\)/g;function E3(g,E){const M=[];return g.replace(Sg,(D,G,Z)=>(M.push([Z,vn(Z,E)]),D)),M.filter(([D])=>!rt(D))}function T3(g){const E=g.replace(/([.*+?^${}()|\[\]\/\\])/g,"\\$1");return new RegExp(`(url\\(['"]?)(${E})(['"]?\\))`,"g")}function P3(g,E){return v(this,null,function*(){const{ownerDocument:M,svgStyleElement:D,fontFamilies:G,fontCssTexts:Z,tasks:W,font:K}=E;if(!(!M||!D||!G.size))if(K&&K.cssText){const ie=Tg(K.cssText,E);D.appendChild(M.createTextNode(`${ie}
80
- `))}else{const ie=Array.from(M.styleSheets).filter(se=>{try{return"cssRules"in se&&!!se.cssRules.length}catch(ce){return Le(`Error while reading CSS rules from ${se.href}`,ce),!1}});yield Promise.all(ie.flatMap(se=>Array.from(se.cssRules).map((ce,he)=>v(this,null,function*(){if(te(ce)){let ue=he+1;const be=ce.href;let ye="";try{ye=yield la(E,{url:be,requestType:"text",responseType:"text"})}catch(Ee){Le(`Error fetch remote css import from ${be}`,Ee)}const $e=ye.replace(Sg,(Ee,Te,Ie)=>Ee.replace(Ie,vn(Ie,be)));for(const Ee of k3($e))try{se.insertRule(Ee,Ee.startsWith("@import")?ue+=1:se.cssRules.length)}catch(Te){Le("Error inserting rule from remote css import",{rule:Ee,error:Te})}}})))),ie.flatMap(se=>Array.from(se.cssRules)).filter(se=>{var ce;return oe(se)&&Cg(se.style.getPropertyValue("src"))&&((ce=go(se.style.getPropertyValue("font-family")))==null?void 0:ce.some(he=>G.has(he)))}).forEach(se=>{const ce=se,he=Z.get(ce.cssText);he?D.appendChild(M.createTextNode(`${he}
81
- `)):W.push($g(ce.cssText,ce.parentStyleSheet?ce.parentStyleSheet.href:null,E).then(ue=>{ue=Tg(ue,E),Z.set(ce.cssText,ue),D.appendChild(M.createTextNode(`${ue}
82
- `))}))})}})}const M3=/(\/\*[\s\S]*?\*\/)/gi,Eg=/((@.*?keyframes [\s\S]*?){([\s\S]*?}\s*?)})/gi;function k3(g){if(g==null)return[];const E=[];let M=g.replace(M3,"");for(;;){const Z=Eg.exec(M);if(!Z)break;E.push(Z[0])}M=M.replace(Eg,"");const D=/@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi,G=new RegExp("((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})","gi");for(;;){let Z=D.exec(M);if(Z)G.lastIndex=D.lastIndex;else if(Z=G.exec(M),Z)D.lastIndex=G.lastIndex;else break;E.push(Z[0])}return E}const O3=/url\([^)]+\)\s*format\((["']?)([^"']+)\1\)/g,_3=/src:\s*(?:url\([^)]+\)\s*format\([^)]+\)[,;]\s*)+/g;function Tg(g,E){const{font:M}=E,D=M?M==null?void 0:M.preferredFormat:void 0;return D?g.replace(_3,G=>{for(;;){const[Z,,W]=O3.exec(G)||[];if(!W)return"";if(W===D)return`src: ${Z};`}}):g}function N3(g,E){if(de(g)){const M=g.currentSrc||g.src;if(!rt(M))return[la(E,{url:M,imageDom:g,requestType:"image",responseType:"dataUrl"}).then(D=>{D&&(g.srcset="",g.dataset.originalSrc=M,g.src=D||"")})];(z||J)&&E.drawImageCount++}else if(Y(g)&&!rt(g.href.baseVal)){const M=g.href.baseVal;return[la(E,{url:M,imageDom:g,requestType:"image",responseType:"dataUrl"}).then(D=>{D&&(g.dataset.originalSrc=M,g.href.baseVal=D||"")})]}return[]}const A3=["background-image","border-image-source","-webkit-border-image","-webkit-mask-image","list-style-image"];function D3(g,E){return A3.map(M=>{const D=g.getPropertyValue(M);return D?((z||J)&&E.drawImageCount++,$g(D,null,E,!0).then(G=>{!G||D===G||g.setProperty(M,G,g.getPropertyPriority(M))})):null}).filter(Boolean)}function Pg(g,E){const{tasks:M}=E;ae(g)&&(de(g)||U(g))&&M.push(...N3(g,E)),q(g)&&M.push(...D3(g.style,E)),g.childNodes.forEach(D=>{Pg(D,E)})}function Mg(g,E){return v(this,null,function*(){const M=yield st(g,E);if(ae(M.node)&&Y(M.node))return M.node;const{ownerDocument:D,log:G,tasks:Z,svgStyleElement:W,svgDefsElement:K,svgStyles:ie,font:se,progress:ce,autoDestruct:he,onCloneNode:ue,onEmbedNode:be,onCreateForeignObjectSvg:ye}=M;G.time("clone node");const $e=yield sa(M.node,M,!0);if(W&&D){let Je="";ie.forEach((Rt,gn)=>{Je+=`${Rt.join(`,
78
+ `);return E.appendChild(M),E}function pt(g,E){let{width:M,height:D}=E;if(ae(g)&&(!M||!D)){const G=g.getBoundingClientRect();M=M||G.width||Number(g.getAttribute("width"))||0,D=D||G.height||Number(g.getAttribute("height"))||0}return{width:M,height:D}}function Kt(g,E){return v(this,null,function*(){const{log:M,timeout:D,drawImageCount:G,drawImageInterval:Z}=E;M.time("image to canvas");const W=yield Yt(g,{timeout:D}),{canvas:K,context2d:ie}=Xt(g.ownerDocument,E),se=()=>{try{ie==null||ie.drawImage(W,0,0,K.width,K.height)}catch(ce){Le("Failed to drawImage",ce)}};if(se(),E.isEnable("fixSvgXmlDecode"))for(let ce=0;ce<G;ce++)yield new Promise(he=>{setTimeout(()=>{se(),he()},ce+Z)});return E.drawImageCount=0,M.timeEnd("image to canvas"),K})}function Xt(g,E){const{width:M,height:D,scale:G,backgroundColor:Z,maximumCanvasSize:W}=E,K=g.createElement("canvas");K.width=Math.floor(M*G),K.height=Math.floor(D*G),K.style.width=`${M}px`,K.style.height=`${D}px`,W&&(K.width>W||K.height>W)&&(K.width>W&&K.height>W?K.width>K.height?(K.height*=W/K.width,K.width=W):(K.width*=W/K.height,K.height=W):K.width>W?(K.height*=W/K.width,K.width=W):(K.width*=W/K.height,K.height=W));const ie=K.getContext("2d");return ie&&Z&&(ie.fillStyle=Z,ie.fillRect(0,0,K.width,K.height)),{canvas:K,context2d:ie}}const lt=["width","height"],Bn=["stroke","fill"];function Un(g,E,M){var D;const{defaultComputedStyles:G,ownerDocument:Z}=M,W=g.nodeName.toLowerCase(),K=Y(g)&&W!=="svg",ie=K?Bn.map(Te=>[Te,g.getAttribute(Te)]).filter(([,Te])=>Te!==null):[],se=[K&&"svg",W,ie.map((Te,Ie)=>`${Te}=${Ie}`).join(","),E].filter(Boolean).join(":");if(G.has(se))return G.get(se);let ce=M.sandbox;if(!ce)try{Z&&(ce=Z.createElement("iframe"),ce.id=`__SANDBOX__-${go()}`,ce.width="0",ce.height="0",ce.style.visibility="hidden",ce.style.position="fixed",Z.body.appendChild(ce),(D=ce.contentWindow)==null||D.document.write('<!DOCTYPE html><meta charset="UTF-8"><title></title><body>'),M.sandbox=ce)}catch(Te){Le("Failed to create iframe sandbox",Te)}if(!ce)return new Map;const he=ce.contentWindow;if(!he)return new Map;const ue=he.document;let be,ye;K?(be=ue.createElementNS(Wn,"svg"),ye=be.ownerDocument.createElementNS(be.namespaceURI,W),ie.forEach(([Te,Ie])=>{ye.setAttributeNS(null,Te,Ie)}),be.appendChild(ye)):be=ye=ue.createElement(W),ye.textContent=" ",ue.body.appendChild(be);const $e=he.getComputedStyle(ye,E),Ee=new Map;for(let Te=$e.length,Ie=0;Ie<Te;Ie++){const Ne=$e.item(Ie);lt.includes(Ne)||Ee.set(Ne,$e.getPropertyValue(Ne))}return ue.body.removeChild(be),G.set(se,Ee),Ee}function xr(g,E){var M;const D=new Map,G=[],Z=new Map;for(let W=g.length,K=0;K<W;K++){const ie=g.item(K),se=g.getPropertyValue(ie),ce=g.getPropertyPriority(ie),he=ie.lastIndexOf("-"),ue=he>-1?ie.substring(0,he):void 0;if(ue){let be=Z.get(ue);be||(be=new Map,Z.set(ue,be)),be.set(ie,[se,ce])}E.get(ie)===se&&!ce||(ue?G.push(ue):D.set(ie,[se,ce]))}for(let W=G.length,K=0;K<W;K++)(M=Z.get(G[K]))==null||M.forEach((ie,se)=>D.set(se,ie));return D}const wr=[":before",":after"],ia=[":-webkit-scrollbar",":-webkit-scrollbar-button",":-webkit-scrollbar-thumb",":-webkit-scrollbar-track",":-webkit-scrollbar-track-piece",":-webkit-scrollbar-corner",":-webkit-resizer"];function aa(g,E,M,D){const{ownerWindow:G,svgStyleElement:Z,svgStyles:W}=D;if(!Z||!G)return;function K(ie){var se;const ce=G.getComputedStyle(g,ie);let he=ce.getPropertyValue("content");if(!he||he==="none")return;he=he.replace(/(')|(")|(counter\(.+\))/g,"");const ue=[go()],be=Un(g,ie,D),ye=[`content: '${he}';`],$e=xr(ce,be);if($e.delete("content"),$e.delete("-webkit-locale"),((se=$e.get("background-clip"))==null?void 0:se[0])==="text"&&E.classList.add("______background-clip--text"),$e.forEach(([Ie,Ne],Je)=>{ye.push(`${Je}: ${Ie}${Ne?" !important":""};`)}),ye.length===1)return;try{E.className=[E.className,...ue].join(" ")}catch{return}const Ee=ye.join(`
79
+ `);let Te=W.get(Ee);Te||(Te=[],W.set(Ee,Te)),Te.push(`.${ue[0]}:${ie}`)}wr.forEach(K),M&&ia.forEach(K)}function y3(g,E){ke(g)&&(E.innerHTML=g.value),(ke(g)||je(g)||Ze(g))&&E.setAttribute("value",g.value)}function b3(g,E,M,D){var G,Z,W,K;const{ownerWindow:ie}=D,se=E.style,ce=ie.getComputedStyle(g),he=Un(g,null,D),ue=xr(ce,he);return ue.delete("transition-property"),ue.delete("all"),ue.delete("d"),ue.delete("content"),M&&(ue.delete("margin-top"),ue.delete("margin-right"),ue.delete("margin-bottom"),ue.delete("margin-left"),ue.delete("margin-block-start"),ue.delete("margin-block-end"),ue.delete("margin-inline-start"),ue.delete("margin-inline-end"),ue.set("box-sizing",["border-box",""])),((G=ue.get("background-clip"))==null?void 0:G[0])==="text"&&E.classList.add("______background-clip--text"),N&&(ue.has("font-kerning")||ue.set("font-kerning",["normal",""]),(((Z=ue.get("overflow-x"))==null?void 0:Z[0])==="hidden"||((W=ue.get("overflow-y"))==null?void 0:W[0])==="hidden")&&((K=ue.get("text-overflow"))==null?void 0:K[0])==="ellipsis"&&g.scrollWidth===g.clientWidth&&ue.set("text-overflow",["clip",""])),ue.forEach(([be,ye],$e)=>{se.setProperty($e,be,ye)}),ue}function x3(g,E){return v(this,null,function*(){var M,D,G;const{ownerDocument:Z,svgDefsElement:W}=E,K=(D=(M=g.querySelectorAll)==null?void 0:M.call(g,"use"))!=null?D:[];if(K.length)for(let ie=K.length,se=0;se<ie;se++){const ce=K[se],he=(G=ce.getAttribute("xlink:href"))!=null?G:ce.getAttribute("href");if(!he)continue;const ue=Z==null?void 0:Z.querySelector(`svg ${he}`);!ue||W!=null&&W.querySelector(he)||W==null||W.appendChild(yield sa(ue,E))}return g.cloneNode(!1)})}function w3(g,E){var M;try{if((M=g==null?void 0:g.contentDocument)!=null&&M.body)return sa(g.contentDocument.body,E)}catch(D){Le("Failed to clone iframe",D)}return g.cloneNode(!1)}function bg(g){if(g.ownerDocument)try{const G=g.toDataURL();if(G!=="data:,")return Nt(G,g.ownerDocument)}catch{}const E=g.cloneNode(!1),M=g.getContext("2d"),D=E.getContext("2d");try{return M&&D&&D.putImageData(M.getImageData(0,0,g.width,g.height),0,0),E}catch(G){Le("Failed to clone canvas",G)}return E}function $3(g){return v(this,null,function*(){if(g.ownerDocument&&!g.currentSrc&&g.poster)return Nt(g.poster,g.ownerDocument);const E=g.cloneNode(!1);E.crossOrigin="anonymous",g.currentSrc&&g.currentSrc!==g.src&&(E.src=g.currentSrc);const M=E.ownerDocument;if(M){let D=!0;if(yield Yt(E,{onError:()=>D=!1}),!D)return g.poster?Nt(g.poster,g.ownerDocument):E;E.currentTime=g.currentTime,yield new Promise(Z=>{E.addEventListener("seeked",Z,{once:!0})});const G=M.createElement("canvas");G.width=g.offsetWidth,G.height=g.offsetHeight;try{const Z=G.getContext("2d");Z&&Z.drawImage(E,0,0,G.width,G.height)}catch(Z){return Le("Failed to clone video",Z),g.poster?Nt(g.poster,g.ownerDocument):E}return bg(G)}return E})}function C3(g){const E=g.cloneNode(!1);return g.currentSrc&&g.currentSrc!==g.src&&(E.src=g.currentSrc,E.srcset=""),E.loading==="lazy"&&(E.loading="eager"),E}function S3(g,E){return Ce(g)?bg(g):yr(g)?w3(g,E):de(g)?C3(g):pe(g)?$3(g):le(g)?x3(g,E):g.cloneNode(!1)}function xg(g,E,M){return v(this,null,function*(){ae(E)&&(_t(E)||mn(E))||M.filter&&!M.filter(E)||g.appendChild(yield sa(E,M))})}function wg(g,E,M){return v(this,null,function*(){var D,G;const Z=(G=ae(g)?(D=g.shadowRoot)==null?void 0:D.firstChild:void 0)!=null?G:g.firstChild;for(let W=Z;W;W=W.nextSibling)if(!re(W))if(ae(W)&&qt(W)&&typeof W.assignedNodes=="function"){const K=W.assignedNodes();for(let ie=0;ie<K.length;ie++)yield xg(E,K[ie],M)}else yield xg(E,W,M)})}function E3(g,E){const{backgroundColor:M,width:D,height:G,style:Z}=E,W=g.style;if(M&&W.setProperty("background-color",M,"important"),D&&W.setProperty("width",`${D}px`,"important"),G&&W.setProperty("height",`${G}px`,"important"),Z)for(const K in Z)W[K]=Z[K]}const T3=/^[\w-]+$/;function sa(g,E,M=!1){return v(this,null,function*(){var D,G,Z,W;const{ownerDocument:K,ownerWindow:ie,fontFamilies:se}=E;if(K&&k(g))return K.createTextNode(g.data);if(K&&ie&&ae(g)&&(q(g)||Y(g))){const he=yield S3(g,E);if(E.isEnable("removeAbnormalAttributes")){const ye=he.getAttributeNames();for(let $e=ye.length,Ee=0;Ee<$e;Ee++){const Te=ye[Ee];T3.test(Te)||he.removeAttribute(Te)}}const ue=b3(g,he,M,E);M&&E3(he,E);let be=!1;if(E.isEnable("copyScrollbar")){const ye=[(D=ue.get("overflow-x"))==null?void 0:D[0],(G=ue.get("overflow-y"))==null?void 0:G[1]];be=ye.includes("scroll")||(ye.includes("auto")||ye.includes("overlay"))&&(g.scrollHeight>g.clientHeight||g.scrollWidth>g.clientWidth)}return aa(g,he,be,E),y3(g,he),(W=yo((Z=ue.get("font-family"))==null?void 0:Z[0]))==null||W.forEach(ye=>se.add(ye)),pe(g)||(yield wg(g,he,E)),he}const ce=g.cloneNode(!1);return yield wg(g,ce,E),ce})}function $g(g){if(g.ownerDocument=void 0,g.ownerWindow=void 0,g.svgStyleElement=void 0,g.svgDefsElement=void 0,g.svgStyles.clear(),g.defaultComputedStyles.clear(),g.sandbox){try{g.sandbox.remove()}catch{}g.sandbox=void 0}g.workers=[],g.fontFamilies.clear(),g.fontCssTexts.clear(),g.requests.clear(),g.tasks=[]}function P3(g){const E=g,{url:M,timeout:D,responseType:G}=E,Z=h(E,["url","timeout","responseType"]),W=new AbortController,K=D?setTimeout(()=>W.abort(),D):void 0;return fetch(M,p({signal:W.signal},Z)).then(ie=>{if(!ie.ok)throw new Error("Failed fetch, not 2xx response",{cause:ie});switch(G){case"dataUrl":return ie.blob().then(ea);case"text":default:return ie.text()}}).finally(()=>clearTimeout(K))}function la(g,E){const{url:M,requestType:D="text",responseType:G="text",imageDom:Z}=E;let W=M;const{timeout:K,acceptOfImage:ie,requests:se,fetch:{requestInit:ce,bypassingCache:he,placeholderImage:ue},workers:be}=g;D==="image"&&(z||J)&&g.drawImageCount++;let ye=se.get(M);if(!ye){he&&(W+=(/\?/.test(W)?"&":"?")+new Date().getTime());const $e=p({url:W,timeout:K,responseType:G,headers:D==="image"?{accept:ie}:void 0},ce);ye={type:D,resovle:void 0,reject:void 0,response:null},ye.response=(!z&&M.startsWith("http")&&be.length?new Promise((Ee,Te)=>{be[se.size&be.length-1].postMessage(p({rawUrl:M},$e)),ye.resovle=Ee,ye.reject=Te}):P3($e)).catch(Ee=>{if(se.delete(M),D==="image"&&ue)return Le("Failed to fetch image base64, trying to use placeholder image",W),typeof ue=="string"?ue:ue(Z);throw Ee}),se.set(M,ye)}return ye.response}function Cg(g,E,M,D){return v(this,null,function*(){if(!Sg(g))return g;for(const[G,Z]of M3(g,E))try{const W=yield la(M,{url:Z,requestType:D?"image":"text",responseType:"dataUrl"});g=g.replace(k3(G),`$1${W}$3`)}catch(W){Le("Failed to fetch css data url",G,W)}return g})}function Sg(g){return/url\((['"]?)([^'"]+?)\1\)/.test(g)}const Eg=/url\((['"]?)([^'"]+?)\1\)/g;function M3(g,E){const M=[];return g.replace(Eg,(D,G,Z)=>(M.push([Z,vn(Z,E)]),D)),M.filter(([D])=>!rt(D))}function k3(g){const E=g.replace(/([.*+?^${}()|\[\]\/\\])/g,"\\$1");return new RegExp(`(url\\(['"]?)(${E})(['"]?\\))`,"g")}function O3(g,E){return v(this,null,function*(){const{ownerDocument:M,svgStyleElement:D,fontFamilies:G,fontCssTexts:Z,tasks:W,font:K}=E;if(!(!M||!D||!G.size))if(K&&K.cssText){const ie=Pg(K.cssText,E);D.appendChild(M.createTextNode(`${ie}
80
+ `))}else{const ie=Array.from(M.styleSheets).filter(se=>{try{return"cssRules"in se&&!!se.cssRules.length}catch(ce){return Le(`Error while reading CSS rules from ${se.href}`,ce),!1}});yield Promise.all(ie.flatMap(se=>Array.from(se.cssRules).map((ce,he)=>v(this,null,function*(){if(te(ce)){let ue=he+1;const be=ce.href;let ye="";try{ye=yield la(E,{url:be,requestType:"text",responseType:"text"})}catch(Ee){Le(`Error fetch remote css import from ${be}`,Ee)}const $e=ye.replace(Eg,(Ee,Te,Ie)=>Ee.replace(Ie,vn(Ie,be)));for(const Ee of N3($e))try{se.insertRule(Ee,Ee.startsWith("@import")?ue+=1:se.cssRules.length)}catch(Te){Le("Error inserting rule from remote css import",{rule:Ee,error:Te})}}})))),ie.flatMap(se=>Array.from(se.cssRules)).filter(se=>{var ce;return oe(se)&&Sg(se.style.getPropertyValue("src"))&&((ce=yo(se.style.getPropertyValue("font-family")))==null?void 0:ce.some(he=>G.has(he)))}).forEach(se=>{const ce=se,he=Z.get(ce.cssText);he?D.appendChild(M.createTextNode(`${he}
81
+ `)):W.push(Cg(ce.cssText,ce.parentStyleSheet?ce.parentStyleSheet.href:null,E).then(ue=>{ue=Pg(ue,E),Z.set(ce.cssText,ue),D.appendChild(M.createTextNode(`${ue}
82
+ `))}))})}})}const _3=/(\/\*[\s\S]*?\*\/)/gi,Tg=/((@.*?keyframes [\s\S]*?){([\s\S]*?}\s*?)})/gi;function N3(g){if(g==null)return[];const E=[];let M=g.replace(_3,"");for(;;){const Z=Tg.exec(M);if(!Z)break;E.push(Z[0])}M=M.replace(Tg,"");const D=/@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi,G=new RegExp("((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})","gi");for(;;){let Z=D.exec(M);if(Z)G.lastIndex=D.lastIndex;else if(Z=G.exec(M),Z)D.lastIndex=G.lastIndex;else break;E.push(Z[0])}return E}const A3=/url\([^)]+\)\s*format\((["']?)([^"']+)\1\)/g,D3=/src:\s*(?:url\([^)]+\)\s*format\([^)]+\)[,;]\s*)+/g;function Pg(g,E){const{font:M}=E,D=M?M==null?void 0:M.preferredFormat:void 0;return D?g.replace(D3,G=>{for(;;){const[Z,,W]=A3.exec(G)||[];if(!W)return"";if(W===D)return`src: ${Z};`}}):g}function I3(g,E){if(de(g)){const M=g.currentSrc||g.src;if(!rt(M))return[la(E,{url:M,imageDom:g,requestType:"image",responseType:"dataUrl"}).then(D=>{D&&(g.srcset="",g.dataset.originalSrc=M,g.src=D||"")})];(z||J)&&E.drawImageCount++}else if(Y(g)&&!rt(g.href.baseVal)){const M=g.href.baseVal;return[la(E,{url:M,imageDom:g,requestType:"image",responseType:"dataUrl"}).then(D=>{D&&(g.dataset.originalSrc=M,g.href.baseVal=D||"")})]}return[]}const L3=["background-image","border-image-source","-webkit-border-image","-webkit-mask-image","list-style-image"];function F3(g,E){return L3.map(M=>{const D=g.getPropertyValue(M);return D?((z||J)&&E.drawImageCount++,Cg(D,null,E,!0).then(G=>{!G||D===G||g.setProperty(M,G,g.getPropertyPriority(M))})):null}).filter(Boolean)}function Mg(g,E){const{tasks:M}=E;ae(g)&&(de(g)||U(g))&&M.push(...I3(g,E)),q(g)&&M.push(...F3(g.style,E)),g.childNodes.forEach(D=>{Mg(D,E)})}function kg(g,E){return v(this,null,function*(){const M=yield st(g,E);if(ae(M.node)&&Y(M.node))return M.node;const{ownerDocument:D,log:G,tasks:Z,svgStyleElement:W,svgDefsElement:K,svgStyles:ie,font:se,progress:ce,autoDestruct:he,onCloneNode:ue,onEmbedNode:be,onCreateForeignObjectSvg:ye}=M;G.time("clone node");const $e=yield sa(M.node,M,!0);if(W&&D){let Je="";ie.forEach((Rt,gn)=>{Je+=`${Rt.join(`,
83
83
  `)} {
84
84
  ${gn}
85
85
  }
86
- `}),W.appendChild(D.createTextNode(Je))}G.timeEnd("clone node"),ue==null||ue($e),se!==!1&&ae($e)&&(G.time("embed web font"),yield P3($e,M),G.timeEnd("embed web font")),G.time("embed node"),Pg($e,M);const Ee=Z.length;let Te=0;const Ie=()=>v(this,null,function*(){for(;;){const Je=Z.pop();if(!Je)break;try{yield Je}catch(Rt){Le("Failed to run task",Rt)}ce==null||ce(++Te,Ee)}});ce==null||ce(Te,Ee),yield Promise.all([...Array(4)].map(Ie)),G.timeEnd("embed node"),be==null||be($e);const _e=I3($e,M);return K&&_e.insertBefore(K,_e.children[0]),W&&_e.insertBefore(W,_e.children[0]),he&&wg(M),ye==null||ye(_e),_e})}function I3(g,E){const{width:M,height:D}=E,G=po(M,D,g.ownerDocument),Z=G.ownerDocument.createElementNS(G.namespaceURI,"foreignObject");return Z.setAttributeNS(null,"x","0%"),Z.setAttributeNS(null,"y","0%"),Z.setAttributeNS(null,"width","100%"),Z.setAttributeNS(null,"height","100%"),Z.append(g),G.appendChild(Z),G}function ca(g,E){return v(this,null,function*(){var M;const D=yield st(g,E),G=yield Mg(D),Z=br(G,D.isEnable("removeControlCharacter"));D.autoDestruct||(D.svgStyleElement=Qe(D.ownerDocument),D.svgDefsElement=(M=D.ownerDocument)==null?void 0:M.createElementNS(Wn,"defs"),D.svgStyles.clear());const W=Nt(Z,G.ownerDocument);return yield Kt(W,D)})}function L3(g,E){return v(this,null,function*(){const M=yield st(g,E),{log:D,type:G,quality:Z,dpi:W}=M,K=yield ca(M);D.time("canvas to blob");const ie=yield Qi(K,G,Z);if(["image/png","image/jpeg"].includes(G)&&W){const se=yield ta(ie.slice(0,33));let ce=new Uint8Array(se);return G==="image/png"?ce=_(ce,W):G==="image/jpeg"&&(ce=x(ce,W)),new Blob([ce,ie.slice(33)],{type:G})}return D.timeEnd("canvas to blob"),ie})}function $r(g,E){return v(this,null,function*(){const M=yield st(g,E),{log:D,quality:G,type:Z,dpi:W}=M,K=yield ca(M);D.time("canvas to data url");let ie=K.toDataURL(Z,G);if(["image/png","image/jpeg"].includes(Z)&&W&&H&&B){const[se,ce]=ie.split(",");let he=0,ue=!1;if(Z==="image/png"){const _e=R(ce);_e>=0?(he=Math.ceil((_e+28)/3)*4,ue=!0):he=33/3*4}else Z==="image/jpeg"&&(he=18/3*4);const be=ce.substring(0,he),ye=ce.substring(he),$e=window.atob(be),Ee=new Uint8Array($e.length);for(let _e=0;_e<Ee.length;_e++)Ee[_e]=$e.charCodeAt(_e);const Te=Z==="image/png"?_(Ee,W,ue):x(Ee,W),Ie=window.btoa(String.fromCharCode(...Te));ie=[se,",",Ie,ye].join("")}return D.timeEnd("canvas to data url"),ie})}function kg(g,E){return v(this,null,function*(){const M=yield st(g,E),{width:D,height:G,ownerDocument:Z}=M,W=yield $r(M),K=po(D,G,Z),ie=K.ownerDocument.createElementNS(K.namespaceURI,"image");return ie.setAttributeNS(null,"href",W),ie.setAttributeNS(null,"height","100%"),ie.setAttributeNS(null,"width","100%"),K.appendChild(ie),br(K,M.isEnable("removeControlCharacter"))})}function F3(g,E){return v(this,null,function*(){const M=yield st(g,E),{ownerDocument:D,width:G,height:Z,scale:W,type:K}=M,ie=K==="image/svg+xml"?yield kg(M):yield $r(M),se=Nt(ie,D);return se.width=Math.floor(G*W),se.height=Math.floor(Z*W),se.style.width=`${G}px`,se.style.height=`${Z}px`,se})}function j3(g,E){return v(this,null,function*(){return $r(yield st(g,m(p({},E),{type:"image/jpeg"})))})}function z3(g,E){return v(this,null,function*(){const M=yield st(g,E),D=yield ca(M);return D.getContext("2d").getImageData(0,0,D.width,D.height).data})}function W3(g,E){return v(this,null,function*(){return $r(yield st(g,m(p({},E),{type:"image/png"})))})}function B3(g,E){return v(this,null,function*(){return $r(yield st(g,m(p({},E),{type:"image/webp"})))})}n.createContext=oa,n.destroyContext=wg,n.domToBlob=L3,n.domToCanvas=ca,n.domToDataUrl=$r,n.domToForeignObjectSvg=Mg,n.domToImage=F3,n.domToJpeg=j3,n.domToPixel=z3,n.domToPng=W3,n.domToSvg=kg,n.domToWebp=B3,n.loadMedia=Yt,n.waitUntilLoad=mo,Object.defineProperty(n,Symbol.toStringTag,{value:"Module"})})})(xc,xc.exports);var L_=xc.exports;const wc=(e,t,n)=>{u.useImperativeHandle(t,()=>({download(){e.current&&L_.domToPng(e.current,{scale:5}).then(r=>{const o=document.createElement("a");o.download=`${n}.png`,o.href=r,o.click()})}}))},F_=({x:e,y:t,datum:n,size:r})=>L.jsx(vc,{cx:e,cy:t,stroke:n.color.dark,strokeWidth:1,fill:n.color.light,r:r/2}),j_=({x:e,y:t,datum:n})=>L.jsx(vc,{cx:e,cy:t,stroke:n.color.dark,strokeWidth:1,fill:n.color.dark,r:5,style:{zIndex:1500}}),Vi={xAccessor:e=>e.x,yAccessor:e=>e.y},Xv=(e,t,n)=>n==="pre"?`${t}${e}`:`${e}${t}`,Rv=10,z_=5,$c=u.forwardRef(({nodes:e,height:t,width:n,xAxisValues:r,series:o,xAxisLabel:i,yAxisLabel:a,xAxisDomain:s,yAxisDomain:l,xAxisUnitSymbol:c,yAxisUnitSymbol:d,tooltipTitle:f,mode:p,xAxisCharLimit:m,connectNulls:h=!1,maxNodesInMiniMode:v=z_,tooltipStackCharLimit:x=Rv},y)=>{const[b,$]=u.useState(e.map(P=>P.id)),S=u.useRef(null);wc(S,y,`${i}-${a}-LineChart`);const w=u.useMemo(()=>o.map((P,_)=>({points:P.data.map((j,F)=>({x:r[F],y:j,nodeId:P.id,color:Re(_)}))})).slice(0,p==="mini"?v:o.length),[r,o,p,v]),T=u.useMemo(()=>p==="full"?w.filter(P=>b.includes(P.points[0].nodeId)):w,[w,b,p]),O=u.useMemo(()=>Math.floor((n-(p==="mini"?0:150))/(r.length*8)),[n,r,p]);return L.jsxs("div",{ref:S,id:"line-chart",className:"bg-white flex flex-col rabbit-ds",style:{width:n,height:t},children:[L.jsxs("div",{className:"w-full min-w-0 min-h-0 h-full flex flex-row",children:[L.jsx("div",{className:"w-full min-w-0 min-h-0 h-full",children:L.jsxs(gr,{margin:{top:10,left:50,right:50,bottom:50},xScale:{type:"band",nice:!0,...s&&{domain:s}},yScale:{type:"linear",nice:!0,...l&&{domain:l}},children:[L.jsx(rk,{columns:!1,numTicks:6,lineStyle:{stroke:"#EBEFF3",strokeWidth:1}}),L.jsx(dv,{hideTicks:!0,orientation:"bottom",stroke:"#CFD7DF",strokeWidth:1,numTicks:6,tickFormat:P=>c?Xv(P,c.symbol,c.position):P,rangePadding:{end:10},tickComponent:P=>L.jsx(gc,{textLabel:P.formattedValue||"",x:P.x,y:P.y,textStyles:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,fill:"#666666",textAnchor:"middle"},axisCharLimit:m??O}),label:`${i} ➔`,labelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,dy:10,fill:"#666666",textAnchor:"middle",verticalAnchor:"middle"}}),L.jsx(dv,{hideTicks:!0,numTicks:6,strokeWidth:1,orientation:"left",stroke:"#CFD7DF",label:`${a} ➔`,tickFormat:P=>d?Xv(P,d.symbol,d.position):P,tickLabelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,fill:"#666666"},labelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,dx:-20,fill:"#666666",textAnchor:"middle",verticalAnchor:"middle"}}),T.map((P,_)=>L.jsxs(L.Fragment,{children:[L.jsx(I_,{data:P.points,xAccessor:Vi.xAccessor,yAccessor:Vi.yAccessor,connectNulls:h}),L.jsx(M_,{dataKey:`Performance Management ${_}`,data:P.points,size:8,renderGlyph:F_,xAccessor:Vi.xAccessor,yAccessor:Vi.yAccessor})]})),L.jsx(wv,{showDatumGlyph:!0,scroll:!0,debounce:500,snapTooltipToDatumX:!0,snapTooltipToDatumY:!0,detectBounds:!0,unstyled:!0,applyPositionStyle:!0,renderGlyph:j_,renderTooltip:({tooltipData:P})=>{var F,V,R,X,C,I;const _=e.find(H=>{var B;return H.id===((B=P==null?void 0:P.nearestDatum)==null?void 0:B.datum.nodeId)}),j=((F=P==null?void 0:P.nearestDatum)==null?void 0:F.datum)&&((V=P==null?void 0:P.nearestDatum)==null?void 0:V.datum.x.length)<x;return L.jsx(Kv,{xValue:(R=P==null?void 0:P.nearestDatum)==null?void 0:R.datum.x,yValue:(X=P==null?void 0:P.nearestDatum)==null?void 0:X.datum.y,xAxisLabel:i,yAxisLabel:a,showSideBySide:!!j,tooltipTitle:f,legendValue:(_==null?void 0:_.name)||"",legendDarkColor:((C=P==null?void 0:P.nearestDatum)==null?void 0:C.datum.color.dark)||Re(0).dark,legendLightColor:((I=P==null?void 0:P.nearestDatum)==null?void 0:I.datum.color.light)||Re(0).light})}})]})}),p==="full"&&L.jsxs("div",{className:"w-64 p-4 bg-zinc-100 rounded-lg flex-col justify-start items-start gap-0.5 inline-flex text-xs grow-0 shrink-0 basis-auto",children:[L.jsxs("div",{className:"text-sm font-semibold pb-2",children:[L.jsx("span",{className:"pr-1",children:i}),"(",w.length,")"]}),w.map(P=>{const _=e.find(j=>j.id===P.points[0].nodeId);return _&&L.jsxs("div",{className:"flex justify-between items-center gap-1 py-1 w-full",children:[L.jsxs("div",{className:"flex justify-between items-center",children:[L.jsx("div",{style:{backgroundColor:P.points[0].color.light,borderColor:P.points[0].color.dark},className:"h-3 w-3 rounded-full border mr-1"}),_.name]}),L.jsx("div",{className:"flex items-center",children:L.jsx(Yc,{checked:b.includes(_.id),onCheckedChange:j=>{let F=[...b];j?F=[...b,_.id]:F.splice(b.indexOf(_.id),1),$(F)}})})]},_.id)})]})]}),p==="mini"&&L.jsx("div",{className:"flex flex-row flex-wrap justify-center gap-4 text-[10px] text-[#666666] font-semibold",children:w.map(P=>{const _=e.find(j=>j.id===P.points[0].nodeId);return L.jsxs("div",{className:"flex justify-center items-center gap-1",children:[L.jsx("div",{style:{backgroundColor:P.points[0].color.light,borderColor:P.points[0].color.dark},className:"h-3 w-3 rounded-full border"}),_==null?void 0:_.name]},_==null?void 0:_.id)})})]})}),W_={xAxisUnitSymbol:void 0,yAxisUnitSymbol:void 0,mode:"mini",xAxisCharLimit:void 0,tooltipStackCharLimit:Rv,xAxisDomain:void 0,yAxisDomain:void 0,connectNulls:!1};$c.defaultProps=W_,$c.displayName="LineBase";const Zv=u.forwardRef((e,t)=>L.jsx(Gi,{debounceTime:10,children:({width:n,height:r})=>L.jsx($c,{ref:t,width:n,height:r,...e})}));Zv.displayName="LineChart";const B_=Zv;function Qv(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let o of e)(o=t(o,++r,e))!=null&&(n<o||n===void 0&&o>=o)&&(n=o)}return n}function U_(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let o of e)(o=t(o,++r,e))!=null&&(n>o||n===void 0&&o>=o)&&(n=o)}return n}function Cc(e,t){let n=0;if(t===void 0)for(let r of e)(r=+r)&&(n+=r);else{let r=-1;for(let o of e)(o=+t(o,++r,e))&&(n+=o)}return n}function H_(e,t){return e.sourceLinks.length?e.depth:t-1}function qi(e){return function(){return e}}function Jv(e,t){return Yi(e.source,t.source)||e.index-t.index}function eg(e,t){return Yi(e.target,t.target)||e.index-t.index}function Yi(e,t){return e.y0-t.y0}function Sc(e){return e.value}function G_(e){return e.index}function V_(e){return e.nodes}function q_(e){return e.links}function tg(e,t){const n=e.get(t);if(!n)throw new Error("missing: "+t);return n}function ng({nodes:e}){for(const t of e){let n=t.y0,r=n;for(const o of t.sourceLinks)o.y0=n+o.width/2,n+=o.width;for(const o of t.targetLinks)o.y1=r+o.width/2,r+=o.width}}function Y_(){let e=0,t=0,n=1,r=1,o=24,i=8,a,s=G_,l=H_,c,d,f=V_,p=q_,m=6;function h(){const C={nodes:f.apply(null,arguments),links:p.apply(null,arguments)};return v(C),x(C),y(C),b(C),w(C),ng(C),C}h.update=function(C){return ng(C),C},h.nodeId=function(C){return arguments.length?(s=typeof C=="function"?C:qi(C),h):s},h.nodeAlign=function(C){return arguments.length?(l=typeof C=="function"?C:qi(C),h):l},h.nodeSort=function(C){return arguments.length?(c=C,h):c},h.nodeWidth=function(C){return arguments.length?(o=+C,h):o},h.nodePadding=function(C){return arguments.length?(i=a=+C,h):i},h.nodes=function(C){return arguments.length?(f=typeof C=="function"?C:qi(C),h):f},h.links=function(C){return arguments.length?(p=typeof C=="function"?C:qi(C),h):p},h.linkSort=function(C){return arguments.length?(d=C,h):d},h.size=function(C){return arguments.length?(e=t=0,n=+C[0],r=+C[1],h):[n-e,r-t]},h.extent=function(C){return arguments.length?(e=+C[0][0],n=+C[1][0],t=+C[0][1],r=+C[1][1],h):[[e,t],[n,r]]},h.iterations=function(C){return arguments.length?(m=+C,h):m};function v({nodes:C,links:I}){for(const[B,A]of C.entries())A.index=B,A.sourceLinks=[],A.targetLinks=[];const H=new Map(C.map((B,A)=>[s(B,A,C),B]));for(const[B,A]of I.entries()){A.index=B;let{source:N,target:z}=A;typeof N!="object"&&(N=A.source=tg(H,N)),typeof z!="object"&&(z=A.target=tg(H,z)),N.sourceLinks.push(A),z.targetLinks.push(A)}if(d!=null)for(const{sourceLinks:B,targetLinks:A}of C)B.sort(d),A.sort(d)}function x({nodes:C}){for(const I of C)I.value=I.fixedValue===void 0?Math.max(Cc(I.sourceLinks,Sc),Cc(I.targetLinks,Sc)):I.fixedValue}function y({nodes:C}){const I=C.length;let H=new Set(C),B=new Set,A=0;for(;H.size;){for(const N of H){N.depth=A;for(const{target:z}of N.sourceLinks)B.add(z)}if(++A>I)throw new Error("circular link");H=B,B=new Set}}function b({nodes:C}){const I=C.length;let H=new Set(C),B=new Set,A=0;for(;H.size;){for(const N of H){N.height=A;for(const{source:z}of N.targetLinks)B.add(z)}if(++A>I)throw new Error("circular link");H=B,B=new Set}}function $({nodes:C}){const I=Qv(C,A=>A.depth)+1,H=(n-e-o)/(I-1),B=new Array(I);for(const A of C){const N=Math.max(0,Math.min(I-1,Math.floor(l.call(null,A,I))));A.layer=N,A.x0=e+N*H,A.x1=A.x0+o,B[N]?B[N].push(A):B[N]=[A]}if(c)for(const A of B)A.sort(c);return B}function S(C){const I=U_(C,H=>(r-t-(H.length-1)*a)/Cc(H,Sc));for(const H of C){let B=t;for(const A of H){A.y0=B,A.y1=B+A.value*I,B=A.y1+a;for(const N of A.sourceLinks)N.width=N.value*I}B=(r-B+a)/(H.length+1);for(let A=0;A<H.length;++A){const N=H[A];N.y0+=B*(A+1),N.y1+=B*(A+1)}V(H)}}function w(C){const I=$(C);a=Math.min(i,(r-t)/(Qv(I,H=>H.length)-1)),S(I);for(let H=0;H<m;++H){const B=Math.pow(.99,H),A=Math.max(1-B,(H+1)/m);O(I,B,A),T(I,B,A)}}function T(C,I,H){for(let B=1,A=C.length;B<A;++B){const N=C[B];for(const z of N){let J=0,Q=0;for(const{source:te,value:ae}of z.targetLinks){let Y=ae*(z.layer-te.layer);J+=R(te,z)*Y,Q+=Y}if(!(Q>0))continue;let oe=(J/Q-z.y0)*I;z.y0+=oe,z.y1+=oe,F(z)}c===void 0&&N.sort(Yi),P(N,H)}}function O(C,I,H){for(let B=C.length,A=B-2;A>=0;--A){const N=C[A];for(const z of N){let J=0,Q=0;for(const{target:te,value:ae}of z.sourceLinks){let Y=ae*(te.layer-z.layer);J+=X(z,te)*Y,Q+=Y}if(!(Q>0))continue;let oe=(J/Q-z.y0)*I;z.y0+=oe,z.y1+=oe,F(z)}c===void 0&&N.sort(Yi),P(N,H)}}function P(C,I){const H=C.length>>1,B=C[H];j(C,B.y0-a,H-1,I),_(C,B.y1+a,H+1,I),j(C,r,C.length-1,I),_(C,t,0,I)}function _(C,I,H,B){for(;H<C.length;++H){const A=C[H],N=(I-A.y0)*B;N>1e-6&&(A.y0+=N,A.y1+=N),I=A.y1+a}}function j(C,I,H,B){for(;H>=0;--H){const A=C[H],N=(A.y1-I)*B;N>1e-6&&(A.y0-=N,A.y1-=N),I=A.y0-a}}function F({sourceLinks:C,targetLinks:I}){if(d===void 0){for(const{source:{sourceLinks:H}}of I)H.sort(eg);for(const{target:{targetLinks:H}}of C)H.sort(Jv)}}function V(C){if(d===void 0)for(const{sourceLinks:I,targetLinks:H}of C)I.sort(eg),H.sort(Jv)}function R(C,I){let H=C.y0-(C.sourceLinks.length-1)*a/2;for(const{target:B,width:A}of C.sourceLinks){if(B===I)break;H+=A+a}for(const{source:B,width:A}of I.targetLinks){if(B===C)break;H-=A}return H}function X(C,I){let H=I.y0-(I.targetLinks.length-1)*a/2;for(const{source:B,width:A}of I.targetLinks){if(B===C)break;H+=A+a}for(const{target:B,width:A}of C.sourceLinks){if(B===I)break;H-=A}return H}return h}function K_({tooltipData:e,fromLabel:t,toLabel:n,weightLabel:r,tooltipTitle:o}){var s,l,c,d;const i=e.source,a=e.target;return L.jsxs(Ue,{tooltipTitle:o,children:[L.jsx(Ue.Item,{label:t,value:i.name}),L.jsx(Ue.Item,{label:n,value:a.name}),L.jsx(Ue.Item,{label:r,value:e.weight.toString()}),L.jsx(Ue.Legend,{value:i.name,darkColor:(s=Re(i.index||0))==null?void 0:s.dark,lightColor:(l=Re(i.index||0))==null?void 0:l.light}),L.jsx(Ue.Legend,{value:a.name,darkColor:(c=Re(a.index||0))==null?void 0:c.dark,lightColor:(d=Re(a.index||0))==null?void 0:d.light})]})}const rg=80,og=20,X_=30,R_=12,ig=u.forwardRef(({height:e,width:t,tooltipTitle:n,nodes:r,links:o,groups:i,weightLabel:a},s)=>{const l=u.useMemo(()=>Y_().nodeId(C=>C.id).nodeWidth(R_).nodePadding(X_).nodeAlign(C=>C.group),[]),c=u.useRef(null);wc(c,s,`${n}-SankeyChart`);const[d,f]=u.useState(""),[p,m]=u.useState(null),{tooltipData:h,tooltipLeft:v,tooltipTop:x,tooltipOpen:y,showTooltip:b,hideTooltip:$}=Nl(),{containerBounds:S,containerRef:w,TooltipInPortal:T}=zl({detectBounds:!0,debounce:500,scroll:!0,zIndex:1500}),O=u.useMemo(()=>l.extent([[rg,og],[t-rg,e-og-50]])({nodes:r,links:o.map(C=>({...C,value:Number(C.weight)}))}),[e,t,l,r,o]),P=u.useMemo(()=>Math.max(...O.nodes.map(C=>C.depth??0)),[O]),_=u.useMemo(()=>{const C={};let I=-1/0;return O.nodes.forEach(H=>{const{group:B}=H;C[B]?(C[B].x=Math.max(C[B].x??-1/0,H.x0??-1/0),C[B].y=Math.max(C[B].y??-1/0,H.y1??-1/0)):(C[B]={},C[B].x=H.x0,C[B].y=H.y1),I=Math.max(I,C[B].y??-1/0),C[B].y=I}),C},[O]),j=u.useCallback(C=>{const I=l.nodeId()(C);f(d===I?"":I)},[d,l]),F=u.useCallback(()=>{f(""),m(null)},[]),V=u.useMemo(()=>d===""&&p===null?new Set:new Set(O.links.filter(C=>l.nodeId()(C.source)===d||l.nodeId()(C.target)===d||(p==null?void 0:p.source)===C.source&&(p==null?void 0:p.target)===C.target)),[d,O,p,l]),R=u.useCallback((C,I)=>{const H=("clientX"in C?C.clientX:0)-S.left,B=("clientY"in C?C.clientY:0)-S.top;m(I),H&&B&&b({tooltipLeft:H,tooltipTop:B,tooltipData:I})},[b,S]),X=u.useCallback(()=>{F(),$()},[F,$]);return L.jsxs("div",{ref:c,className:"bg-white w-min h-min rabbit-ds",id:"sankey-chart",children:[L.jsxs("svg",{height:e,width:t,ref:w,children:[L.jsx("g",{children:O.links.map(C=>L.jsx(wM,{data:C,source:I=>({x:I.source.x1,y:I.y0}),target:I=>({x:I.target.x0,y:I.y1}),x:I=>I.x??0,y:I=>I.y??0,fill:"none",pointerEvents:"stroke",onMouseLeave:()=>X(),onMouseMove:I=>R(I,C),stroke:Re(C.source.index||0).light,strokeWidth:C.width,strokeOpacity:V.has(C)?.7:.25},C.index))}),L.jsx("g",{children:O.nodes.map(C=>{var I,H,B;return L.jsx("g",{children:L.jsx(pM,{x:C.x0??0,height:(C.y1??0)-(C.y0??0)+10,width:(C.x1??0)-(C.x0??0),y:(C.y0??0)-5,onMouseEnter:()=>j(C),onMouseLeave:()=>F(),radius:2,fill:d===C.id?(I=Re(C.index||0))==null?void 0:I.dark:(H=Re(C.index||0))==null?void 0:H.light,stroke:(B=Re(C.index||0))==null?void 0:B.dark,all:!0})},C.index)})}),L.jsx("g",{children:i.map(C=>L.jsx(gc,{axisCharLimit:20,x:_[C.id].x??0,y:(_[C.id].y??0)+40,textLabel:C.name,textStyles:{fontSize:10,fontWeight:600,textAnchor:"middle",fill:"#666666"}},C.id))}),L.jsxs("g",{children:[O.nodes.map(C=>L.jsx(gc,{axisCharLimit:8,x:C.depth===P?(C.x1??0)+10:(C.x0??0)-10,y:(C.y0??0)+((C.y1??0)-(C.y0??0))/2,textLabel:C.name,textStyles:{fontSize:10,fontWeight:600,textAnchor:C.depth===P?"start":"end",fill:"#666666"}},C.index)),O.nodes.map(C=>C.value&&L.jsx(gs,{x:C.depth===P?(C.x1??0)+10:(C.x0??0)-10,y:(C.y0??0)+((C.y1??0)-(C.y0??0))/2+16,style:{fontSize:10,fontWeight:400,textAnchor:C.depth===P?"start":"end",fill:"#666666"},children:`(${C.value.toString()})`},C.index))]})]}),y&&h&&L.jsx(T,{top:x,left:v,unstyled:!0,applyPositionStyle:!0,children:L.jsx(K_,{tooltipData:h,fromLabel:`From: ${i[h.source.group].name}`,toLabel:`To: ${i[h.target.group].name}`,weightLabel:a,tooltipTitle:n})},Math.random())]})});ig.displayName="Sankey";const ag=u.forwardRef((e,t)=>L.jsx(Gi,{debounceTime:10,children:({width:n,height:r})=>n&&r&&L.jsx(ig,{ref:t,width:n,height:r,...e})}));ag.displayName="SankeyChart";const Z_=ag;function Q_(e){return"bandwidth"in e?e.bandwidth():0}var J_=["top","left","scale","width","stroke","strokeWidth","strokeDasharray","className","children","numTicks","lineStyle","offset","tickValues"];function Ec(){return Ec=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ec.apply(this,arguments)}function e3(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function sg(e){var t=e.top,n=t===void 0?0:t,r=e.left,o=r===void 0?0:r,i=e.scale,a=e.width,s=e.stroke,l=s===void 0?"#eaf0f6":s,c=e.strokeWidth,d=c===void 0?1:c,f=e.strokeDasharray,p=e.className,m=e.children,h=e.numTicks,v=h===void 0?10:h,x=e.lineStyle,y=e.offset,b=e.tickValues,$=e3(e,J_),S=b??dl(i,v),w=(y??0)+Q_(i)/2,T=S.map(function(O,P){var _,j=((_=ul(i(O)))!=null?_:0)+w;return{index:P,from:new an({x:0,y:j}),to:new an({x:a,y:j})}});return u.createElement(En,{className:et("visx-rows",p),top:n,left:o},m?m({lines:T}):T.map(function(O){var P=O.from,_=O.to,j=O.index;return u.createElement(EM,Ec({key:"row-line-"+j,from:P,to:_,stroke:l,strokeWidth:d,strokeDasharray:f,style:x},$))}))}sg.propTypes={tickValues:ne.array,width:ne.number.isRequired};function lg({xValue:e,yValue:t,tooltipTitle:n,xAxisLabel:r,yAxisLabel:o,legendValue:i,legendDarkColor:a,legendLightColor:s}){const l=e==null?void 0:e.toString(),c=t==null?void 0:t.toString();return L.jsxs(Ue,{tooltipTitle:n,showSideBySide:!0,children:[L.jsx(Ue.Item,{label:r,value:l}),L.jsx(Ue.Item,{label:o,value:c}),L.jsx(Ue.Legend,{value:i,darkColor:a,lightColor:s})]})}lg.defaultProps={xValue:void 0,yValue:void 0};const cg=20,ug=50,Tc=80,Ki=50,t3=10,n3=25,Pc=u.forwardRef(({tooltipTitle:e,xAxisLabel:t,yAxisLabel:n,domain:r,binCount:o,data:i,width:a,height:s,maxBinCount:l=n3,minBinCount:c=t3,integerBins:d=!1,integerYAxis:f=!1},p)=>{const m=u.useMemo(()=>ai(i),[i]),{histogramDomain:h,threshold:v,thresholdInteger:x}=u.useMemo(()=>{const A=m[0]??0,N=A===m[1]?c+A:m[1]??0,z=N-A>c?N:c+A,J=Math.min(Math.max(N-A,c),l),Q=Math.floor(m[0]??0),oe=Math.ceil(z);return{histogramDomain:r||(d?[Q,oe]:[A,N]),threshold:J,thresholdInteger:Math.ceil(J)}},[m,r,d,l,c]),y=u.useMemo(()=>ro({domain:h,range:[Ki,a-ug],round:!0,nice:!0}),[h,a]),b=u.useMemo(()=>TE().domain(y.domain()).thresholds(o||(d?x:v))(i),[y,o,i,v,x,d]),$=u.useMemo(()=>ro({domain:[0,Cs(b,A=>A.length)??0],range:[s-Tc,cg],round:!0,nice:!0}),[b,s]),S=u.useMemo(()=>$.ticks().filter(A=>f?Number.isInteger(A):A),[f,$]),w=u.useRef(null);wc(w,p,`${t}-${n}-Histogram`);const{tooltipData:T,tooltipLeft:O,tooltipTop:P,tooltipOpen:_,showTooltip:j,hideTooltip:F}=Nl(),{containerBounds:V,containerRef:R,TooltipInPortal:X}=zl({detectBounds:!0,debounce:500,scroll:!0,zIndex:1500}),C=a-Ki-ug,I=s-cg-Tc-100,H=u.useCallback((A,N)=>{const z=("clientX"in A?A.clientX:0)-V.left,J=("clientY"in A?A.clientY:0)-V.top;z&&J&&j({tooltipLeft:z,tooltipTop:J,tooltipData:N})},[j,V]),B=u.useCallback(()=>{F()},[F]);return L.jsxs("div",{className:"bg-white flex flex-col rabbit-ds",style:{width:a,height:s},ref:w,children:[L.jsxs("svg",{width:a,height:s,ref:R,children:[L.jsx(kl,{orientation:"bottom",scale:y,top:s-Tc,hideTicks:!0,numTicks:6,stroke:"#CFD7DF",strokeWidth:1,rangePadding:{end:10},label:`${t} ➔`,tickLabelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,fill:"#666666",textAnchor:"middle"},labelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,dy:10,fill:"#666666",textAnchor:"middle",verticalAnchor:"middle"}}),L.jsx(kl,{orientation:"left",scale:$,left:Ki,hideTicks:!0,strokeWidth:1,stroke:"#CFD7DF",tickFormat:f?Ei("d"):void 0,tickValues:S,label:`${n} ➔`,tickLabelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,fill:"#666666",textAnchor:"end"},labelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,dx:-20,fill:"#666666",textAnchor:"middle",verticalAnchor:"middle"}}),L.jsxs(En,{children:[L.jsx(sg,{scale:$,width:C,height:I,left:Ki,top:0,lineStyle:{stroke:"#EBEFF3",strokeWidth:1}}),b.map(A=>{const N=Math.abs($(0)-$(A.length)),z=Math.abs(y(A.x1??0)-y(A.x0??0));return L.jsx("g",{children:L.jsx(cM,{x:y(A.x0??0),y:$(A.length),width:z,height:N&&N-1,fill:Re(0).light,stroke:Re(0).dark,strokeWidth:1,onMouseMove:J=>H(J,A),onMouseLeave:()=>B()})},Math.random())})]})]}),_&&T&&L.jsx(X,{top:P,left:O,unstyled:!0,applyPositionStyle:!0,children:L.jsx(lg,{xAxisLabel:t,xValue:`${T.x0} to ${T.x1}`,yAxisLabel:n,yValue:T.length,tooltipTitle:e,legendValue:n,legendDarkColor:Re(0).dark,legendLightColor:Re(0).light})},Math.random()),$.domain()[2]]})}),dg=u.forwardRef((e,t)=>L.jsx(Gi,{debounceTime:10,children:({width:n,height:r})=>L.jsx(Pc,{ref:t,width:n,height:r,...e})}));Pc.defaultProps={domain:void 0,binCount:void 0,integerBins:!1,integerYAxis:!1},Pc.displayName="HistogramBase",dg.displayName="HistogramChart";const r3=dg;function o3({count:e,totalCount:t,title:n,subTitle:r,className:o,unstyledDimension:i=!1,style:a}){const s="max-w-[336px] min-h-[96px] min-w-[200px]";return L.jsxs("div",{className:Ne("rabbit-ds box-border px-2 py-4 bg-white rounded-lg shadow flex-col justify-center items-start gap-1 inline-flex",o,!i&&s),style:a,children:[L.jsxs("div",{className:"self-stretch px-3 py-1 flex items-baseline",children:[L.jsx("div",{className:"text-zinc-800 text-2xl font-semibold",children:e}),t&&t>0?L.jsxs("div",{className:"text-stone-500 text-xs font-normal",children:["/",t]}):null]}),L.jsx("div",{className:"self-stretch px-3 justify-start items-center gap-2 inline-flex",children:L.jsxs("div",{className:"grow shrink basis-0 flex-col justify-start items-start gap-0.5 inline-flex",children:[L.jsx("div",{className:"self-stretch justify-start items-start gap-2.5 inline-flex",children:L.jsx("div",{className:"grow shrink basis-0 text-zinc-800 text-xs font-semibold leading-none",children:n})}),r&&L.jsx("div",{className:"self-stretch justify-start py-2 items-center gap-1 inline-flex",children:L.jsx("div",{className:"grow shrink basis-0 text-stone-500 text-xs font-normal leading-none",children:r})})]})})]})}const Xi="ToggleGroup",[fg,e6]=Ct(Xi,[Ao]),pg=Ao(),i3=u.forwardRef((e,t)=>{const{type:n,...r}=e;if(n==="single"){const o=r;return u.createElement(a3,ee({},o,{ref:t}))}if(n==="multiple"){const o=r;return u.createElement(s3,ee({},o,{ref:t}))}throw new Error(`Missing prop \`type\` expected on \`${Xi}\``)}),[hg,mg]=fg(Xi),a3=u.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:o=()=>{},...i}=e,[a,s]=St({prop:n,defaultProp:r,onChange:o});return u.createElement(hg,{scope:e.__scopeToggleGroup,type:"single",value:a?[a]:[],onItemActivate:s,onItemDeactivate:u.useCallback(()=>s(""),[s])},u.createElement(vg,ee({},i,{ref:t})))}),s3=u.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:o=()=>{},...i}=e,[a=[],s]=St({prop:n,defaultProp:r,onChange:o}),l=u.useCallback(d=>s((f=[])=>[...f,d]),[s]),c=u.useCallback(d=>s((f=[])=>f.filter(p=>p!==d)),[s]);return u.createElement(hg,{scope:e.__scopeToggleGroup,type:"multiple",value:a,onItemActivate:l,onItemDeactivate:c},u.createElement(vg,ee({},i,{ref:t})))}),[l3,c3]=fg(Xi),vg=u.forwardRef((e,t)=>{const{__scopeToggleGroup:n,disabled:r=!1,rovingFocus:o=!0,orientation:i,dir:a,loop:s=!0,...l}=e,c=pg(n),d=$o(a),f={role:"group",dir:d,...l};return u.createElement(l3,{scope:n,rovingFocus:o,disabled:r},o?u.createElement(Xu,ee({asChild:!0},c,{orientation:i,dir:d,loop:s}),u.createElement(we.div,ee({},f,{ref:t}))):u.createElement(we.div,ee({},f,{ref:t})))}),Mc="ToggleGroupItem",u3=u.forwardRef((e,t)=>{const n=mg(Mc,e.__scopeToggleGroup),r=c3(Mc,e.__scopeToggleGroup),o=pg(e.__scopeToggleGroup),i=n.value.includes(e.value),a=r.disabled||e.disabled,s={...e,pressed:i,disabled:a},l=u.useRef(null);return r.rovingFocus?u.createElement(Ru,ee({asChild:!0},o,{focusable:!a,active:i,ref:l}),u.createElement(gg,ee({},s,{ref:t}))):u.createElement(gg,ee({},s,{ref:t}))}),gg=u.forwardRef((e,t)=>{const{__scopeToggleGroup:n,value:r,...o}=e,i=mg(Mc,n),a={role:"radio","aria-checked":e.pressed,"aria-pressed":void 0},s=i.type==="single"?a:void 0;return u.createElement(Kc,ee({},s,o,{ref:t,onPressedChange:l=>{l?i.onItemActivate(r):i.onItemDeactivate(r)}}))}),d3=i3,f3=u3;function p3({children:e,...t}){return L.jsx(d3,{className:"flex gap-2",...t,children:e})}function h3({value:e,disabled:t,selected:n,icon:r,label:o,count:i,...a}){return L.jsx(f3,{asChild:!0,value:e,...a,children:L.jsx("button",{type:"button",className:Ne("rabbit-ds h-7 flex-col w-auto p-0 border border-solid rounded-full justify-center items-center inline-flex hover:cursor-pointer focus:outline-1 focus:outline-offset-2","data-[state=off]:border-gray-100 data-[state=off]:bg-gray-100 data-[state=off]:text-dove-gray-500","data-[state=on]:border-sky-800 data-[state=on]:bg-sky-100 data-[state=on]:text-sky-800"),children:L.jsxs("div",{className:"px-4 py-1 rounded-full flex-row justify-start items-center gap-2.5 flex",children:[r?L.jsx("div",{className:"w-4 h-4 justify-center items-center flex",children:r}):null,L.jsxs("div",{className:"text-sm leading-tight font-semibold",children:[o?L.jsx("span",{children:o}):null," ",i?L.jsxs("span",{children:["(",i,")"]}):null]})]})})})}ve.Button=O0,ve.CardKPI=o3,ve.Checkbox=Yc,ve.Chip=M0,ve.ChipGroup=p3,ve.ChipGroupItem=h3,ve.Dropdown=Ux,ve.DropdownCheckboxItem=Vd,ve.DropdownContent=Hd,ve.DropdownGroup=Wd,ve.DropdownItem=Gd,ve.DropdownLabel=Yd,ve.DropdownPortal=Gx,ve.DropdownRadioGroup=qx,ve.DropdownRadioItem=qd,ve.DropdownSeparator=Kd,ve.DropdownSub=Vx,ve.DropdownSubContent=Ud,ve.DropdownSubTrigger=Bd,ve.DropdownTrigger=Hx,ve.HistogramChart=r3,ve.LineChart=B_,ve.SankeyChart=Z_,ve.Select=Dw,ve.SelectContent=ff,ve.SelectGroup=Iw,ve.SelectItem=hf,ve.SelectLabel=pf,ve.SelectSeparator=mf,ve.SelectTrigger=df,ve.SelectValue=Lw,ve.Tooltip=Of,ve.TooltipContent=Ja,ve.TooltipPortal=Nf,ve.TooltipProvider=kf,ve.TooltipTrigger=_f,Object.defineProperty(ve,Symbol.toStringTag,{value:"Module"})});
86
+ `}),W.appendChild(D.createTextNode(Je))}G.timeEnd("clone node"),ue==null||ue($e),se!==!1&&ae($e)&&(G.time("embed web font"),yield O3($e,M),G.timeEnd("embed web font")),G.time("embed node"),Mg($e,M);const Ee=Z.length;let Te=0;const Ie=()=>v(this,null,function*(){for(;;){const Je=Z.pop();if(!Je)break;try{yield Je}catch(Rt){Le("Failed to run task",Rt)}ce==null||ce(++Te,Ee)}});ce==null||ce(Te,Ee),yield Promise.all([...Array(4)].map(Ie)),G.timeEnd("embed node"),be==null||be($e);const Ne=j3($e,M);return K&&Ne.insertBefore(K,Ne.children[0]),W&&Ne.insertBefore(W,Ne.children[0]),he&&$g(M),ye==null||ye(Ne),Ne})}function j3(g,E){const{width:M,height:D}=E,G=ho(M,D,g.ownerDocument),Z=G.ownerDocument.createElementNS(G.namespaceURI,"foreignObject");return Z.setAttributeNS(null,"x","0%"),Z.setAttributeNS(null,"y","0%"),Z.setAttributeNS(null,"width","100%"),Z.setAttributeNS(null,"height","100%"),Z.append(g),G.appendChild(Z),G}function ca(g,E){return v(this,null,function*(){var M;const D=yield st(g,E),G=yield kg(D),Z=br(G,D.isEnable("removeControlCharacter"));D.autoDestruct||(D.svgStyleElement=Qe(D.ownerDocument),D.svgDefsElement=(M=D.ownerDocument)==null?void 0:M.createElementNS(Wn,"defs"),D.svgStyles.clear());const W=Nt(Z,G.ownerDocument);return yield Kt(W,D)})}function z3(g,E){return v(this,null,function*(){const M=yield st(g,E),{log:D,type:G,quality:Z,dpi:W}=M,K=yield ca(M);D.time("canvas to blob");const ie=yield Qi(K,G,Z);if(["image/png","image/jpeg"].includes(G)&&W){const se=yield ta(ie.slice(0,33));let ce=new Uint8Array(se);return G==="image/png"?ce=_(ce,W):G==="image/jpeg"&&(ce=x(ce,W)),new Blob([ce,ie.slice(33)],{type:G})}return D.timeEnd("canvas to blob"),ie})}function $r(g,E){return v(this,null,function*(){const M=yield st(g,E),{log:D,quality:G,type:Z,dpi:W}=M,K=yield ca(M);D.time("canvas to data url");let ie=K.toDataURL(Z,G);if(["image/png","image/jpeg"].includes(Z)&&W&&H&&B){const[se,ce]=ie.split(",");let he=0,ue=!1;if(Z==="image/png"){const Ne=R(ce);Ne>=0?(he=Math.ceil((Ne+28)/3)*4,ue=!0):he=33/3*4}else Z==="image/jpeg"&&(he=18/3*4);const be=ce.substring(0,he),ye=ce.substring(he),$e=window.atob(be),Ee=new Uint8Array($e.length);for(let Ne=0;Ne<Ee.length;Ne++)Ee[Ne]=$e.charCodeAt(Ne);const Te=Z==="image/png"?_(Ee,W,ue):x(Ee,W),Ie=window.btoa(String.fromCharCode(...Te));ie=[se,",",Ie,ye].join("")}return D.timeEnd("canvas to data url"),ie})}function Og(g,E){return v(this,null,function*(){const M=yield st(g,E),{width:D,height:G,ownerDocument:Z}=M,W=yield $r(M),K=ho(D,G,Z),ie=K.ownerDocument.createElementNS(K.namespaceURI,"image");return ie.setAttributeNS(null,"href",W),ie.setAttributeNS(null,"height","100%"),ie.setAttributeNS(null,"width","100%"),K.appendChild(ie),br(K,M.isEnable("removeControlCharacter"))})}function W3(g,E){return v(this,null,function*(){const M=yield st(g,E),{ownerDocument:D,width:G,height:Z,scale:W,type:K}=M,ie=K==="image/svg+xml"?yield Og(M):yield $r(M),se=Nt(ie,D);return se.width=Math.floor(G*W),se.height=Math.floor(Z*W),se.style.width=`${G}px`,se.style.height=`${Z}px`,se})}function B3(g,E){return v(this,null,function*(){return $r(yield st(g,m(p({},E),{type:"image/jpeg"})))})}function U3(g,E){return v(this,null,function*(){const M=yield st(g,E),D=yield ca(M);return D.getContext("2d").getImageData(0,0,D.width,D.height).data})}function H3(g,E){return v(this,null,function*(){return $r(yield st(g,m(p({},E),{type:"image/png"})))})}function G3(g,E){return v(this,null,function*(){return $r(yield st(g,m(p({},E),{type:"image/webp"})))})}n.createContext=oa,n.destroyContext=$g,n.domToBlob=z3,n.domToCanvas=ca,n.domToDataUrl=$r,n.domToForeignObjectSvg=kg,n.domToImage=W3,n.domToJpeg=B3,n.domToPixel=U3,n.domToPng=H3,n.domToSvg=Og,n.domToWebp=G3,n.loadMedia=Yt,n.waitUntilLoad=vo,Object.defineProperty(n,Symbol.toStringTag,{value:"Module"})})})(wc,wc.exports);var z_=wc.exports;const $c=(e,t,n)=>{u.useImperativeHandle(t,()=>({download(){e.current&&z_.domToPng(e.current,{scale:5}).then(r=>{const o=document.createElement("a");o.download=`${n}.png`,o.href=r,o.click()})}}))},W_=({x:e,y:t,datum:n,size:r})=>L.jsx(gc,{cx:e,cy:t,stroke:n.color.dark,strokeWidth:1,fill:n.color.light,r:r/2}),B_=({x:e,y:t,datum:n})=>L.jsx(gc,{cx:e,cy:t,stroke:n.color.dark,strokeWidth:1,fill:n.color.dark,r:5,style:{zIndex:1500}}),Vi={xAccessor:e=>e.x,yAccessor:e=>e.y},Rv=(e,t,n)=>n==="pre"?`${t}${e}`:`${e}${t}`,Zv=10,U_=5,Cc=u.forwardRef(({nodes:e,height:t,width:n,xAxisValues:r,series:o,xAxisLabel:i,yAxisLabel:a,xAxisDomain:s,yAxisDomain:l,xAxisUnitSymbol:c,yAxisUnitSymbol:d,tooltipTitle:f,mode:p,xAxisCharLimit:m,connectNulls:h=!1,maxNodesInMiniMode:v=U_,tooltipStackCharLimit:x=Zv},y)=>{const[b,$]=u.useState(e.map(P=>P.id)),S=u.useRef(null);$c(S,y,`${i}-${a}-LineChart`);const w=u.useMemo(()=>o.map((P,_)=>({points:P.data.map((j,F)=>({x:r[F],y:j,nodeId:P.id,color:Re(_)}))})).slice(0,p==="mini"?v:o.length),[r,o,p,v]),T=u.useMemo(()=>p==="full"?w.filter(P=>b.includes(P.points[0].nodeId)):w,[w,b,p]),O=u.useMemo(()=>Math.floor((n-(p==="mini"?0:150))/(r.length*8)),[n,r,p]);return L.jsxs("div",{ref:S,id:"line-chart",className:"bg-white flex flex-col rabbit-ds",style:{width:n,height:t},children:[L.jsxs("div",{className:"w-full min-w-0 min-h-0 h-full flex flex-row",children:[L.jsx("div",{className:"w-full min-w-0 min-h-0 h-full",children:L.jsxs(gr,{margin:{top:10,left:50,right:50,bottom:50},xScale:{type:"band",nice:!0,...s&&{domain:s}},yScale:{type:"linear",nice:!0,...l&&{domain:l}},children:[L.jsx(ak,{columns:!1,numTicks:6,lineStyle:{stroke:"#EBEFF3",strokeWidth:1}}),L.jsx(fv,{hideTicks:!0,orientation:"bottom",stroke:"#CFD7DF",strokeWidth:1,numTicks:6,tickFormat:P=>c?Rv(P,c.symbol,c.position):P,rangePadding:{end:10},tickComponent:P=>L.jsx(yc,{textLabel:P.formattedValue||"",x:P.x,y:P.y,textStyles:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,fill:"#666666",textAnchor:"middle"},axisCharLimit:m??O}),label:`${i} ➔`,labelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,dy:10,fill:"#666666",textAnchor:"middle",verticalAnchor:"middle"}}),L.jsx(fv,{hideTicks:!0,numTicks:6,strokeWidth:1,orientation:"left",stroke:"#CFD7DF",label:`${a} ➔`,tickFormat:P=>d?Rv(P,d.symbol,d.position):P,tickLabelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,fill:"#666666"},labelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,dx:-20,fill:"#666666",textAnchor:"middle",verticalAnchor:"middle"}}),T.map((P,_)=>L.jsxs(L.Fragment,{children:[L.jsx(j_,{data:P.points,xAccessor:Vi.xAccessor,yAccessor:Vi.yAccessor,connectNulls:h}),L.jsx(__,{dataKey:`Performance Management ${_}`,data:P.points,size:8,renderGlyph:W_,xAccessor:Vi.xAccessor,yAccessor:Vi.yAccessor})]})),L.jsx($v,{showDatumGlyph:!0,scroll:!0,debounce:500,snapTooltipToDatumX:!0,snapTooltipToDatumY:!0,detectBounds:!0,unstyled:!0,applyPositionStyle:!0,renderGlyph:B_,renderTooltip:({tooltipData:P})=>{var F,V,R,X,C,I;const _=e.find(H=>{var B;return H.id===((B=P==null?void 0:P.nearestDatum)==null?void 0:B.datum.nodeId)}),j=((F=P==null?void 0:P.nearestDatum)==null?void 0:F.datum)&&((V=P==null?void 0:P.nearestDatum)==null?void 0:V.datum.x.length)<x;return L.jsx(Xv,{xValue:(R=P==null?void 0:P.nearestDatum)==null?void 0:R.datum.x,yValue:(X=P==null?void 0:P.nearestDatum)==null?void 0:X.datum.y,xAxisLabel:i,yAxisLabel:a,showSideBySide:!!j,tooltipTitle:f,legendValue:(_==null?void 0:_.name)||"",legendDarkColor:((C=P==null?void 0:P.nearestDatum)==null?void 0:C.datum.color.dark)||Re(0).dark,legendLightColor:((I=P==null?void 0:P.nearestDatum)==null?void 0:I.datum.color.light)||Re(0).light})}})]})}),p==="full"&&L.jsxs("div",{className:"w-64 p-4 bg-zinc-100 rounded-lg flex-col justify-start items-start gap-0.5 inline-flex text-xs grow-0 shrink-0 basis-auto",children:[L.jsxs("div",{className:"text-sm font-semibold pb-2",children:[L.jsx("span",{className:"pr-1",children:i}),"(",w.length,")"]}),w.map(P=>{const _=e.find(j=>j.id===P.points[0].nodeId);return _&&L.jsxs("div",{className:"flex justify-between items-center gap-1 py-1 w-full",children:[L.jsxs("div",{className:"flex justify-between items-center",children:[L.jsx("div",{style:{backgroundColor:P.points[0].color.light,borderColor:P.points[0].color.dark},className:"h-3 w-3 rounded-full border mr-1"}),_.name]}),L.jsx("div",{className:"flex items-center",children:L.jsx(Kc,{checked:b.includes(_.id),onCheckedChange:j=>{let F=[...b];j?F=[...b,_.id]:F.splice(b.indexOf(_.id),1),$(F)}})})]},_.id)})]})]}),p==="mini"&&L.jsx("div",{className:"flex flex-row flex-wrap justify-center gap-4 text-[10px] text-[#666666] font-semibold",children:w.map(P=>{const _=e.find(j=>j.id===P.points[0].nodeId);return L.jsxs("div",{className:"flex justify-center items-center gap-1",children:[L.jsx("div",{style:{backgroundColor:P.points[0].color.light,borderColor:P.points[0].color.dark},className:"h-3 w-3 rounded-full border"}),_==null?void 0:_.name]},_==null?void 0:_.id)})})]})}),H_={xAxisUnitSymbol:void 0,yAxisUnitSymbol:void 0,mode:"mini",xAxisCharLimit:void 0,tooltipStackCharLimit:Zv,xAxisDomain:void 0,yAxisDomain:void 0,connectNulls:!1};Cc.defaultProps=H_,Cc.displayName="LineBase";const Qv=u.forwardRef((e,t)=>L.jsx(Gi,{debounceTime:10,children:({width:n,height:r})=>L.jsx(Cc,{ref:t,width:n,height:r,...e})}));Qv.displayName="LineChart";const G_=Qv;function Jv(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let o of e)(o=t(o,++r,e))!=null&&(n<o||n===void 0&&o>=o)&&(n=o)}return n}function V_(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let o of e)(o=t(o,++r,e))!=null&&(n>o||n===void 0&&o>=o)&&(n=o)}return n}function Sc(e,t){let n=0;if(t===void 0)for(let r of e)(r=+r)&&(n+=r);else{let r=-1;for(let o of e)(o=+t(o,++r,e))&&(n+=o)}return n}function q_(e,t){return e.sourceLinks.length?e.depth:t-1}function qi(e){return function(){return e}}function eg(e,t){return Yi(e.source,t.source)||e.index-t.index}function tg(e,t){return Yi(e.target,t.target)||e.index-t.index}function Yi(e,t){return e.y0-t.y0}function Ec(e){return e.value}function Y_(e){return e.index}function K_(e){return e.nodes}function X_(e){return e.links}function ng(e,t){const n=e.get(t);if(!n)throw new Error("missing: "+t);return n}function rg({nodes:e}){for(const t of e){let n=t.y0,r=n;for(const o of t.sourceLinks)o.y0=n+o.width/2,n+=o.width;for(const o of t.targetLinks)o.y1=r+o.width/2,r+=o.width}}function R_(){let e=0,t=0,n=1,r=1,o=24,i=8,a,s=Y_,l=q_,c,d,f=K_,p=X_,m=6;function h(){const C={nodes:f.apply(null,arguments),links:p.apply(null,arguments)};return v(C),x(C),y(C),b(C),w(C),rg(C),C}h.update=function(C){return rg(C),C},h.nodeId=function(C){return arguments.length?(s=typeof C=="function"?C:qi(C),h):s},h.nodeAlign=function(C){return arguments.length?(l=typeof C=="function"?C:qi(C),h):l},h.nodeSort=function(C){return arguments.length?(c=C,h):c},h.nodeWidth=function(C){return arguments.length?(o=+C,h):o},h.nodePadding=function(C){return arguments.length?(i=a=+C,h):i},h.nodes=function(C){return arguments.length?(f=typeof C=="function"?C:qi(C),h):f},h.links=function(C){return arguments.length?(p=typeof C=="function"?C:qi(C),h):p},h.linkSort=function(C){return arguments.length?(d=C,h):d},h.size=function(C){return arguments.length?(e=t=0,n=+C[0],r=+C[1],h):[n-e,r-t]},h.extent=function(C){return arguments.length?(e=+C[0][0],n=+C[1][0],t=+C[0][1],r=+C[1][1],h):[[e,t],[n,r]]},h.iterations=function(C){return arguments.length?(m=+C,h):m};function v({nodes:C,links:I}){for(const[B,A]of C.entries())A.index=B,A.sourceLinks=[],A.targetLinks=[];const H=new Map(C.map((B,A)=>[s(B,A,C),B]));for(const[B,A]of I.entries()){A.index=B;let{source:N,target:z}=A;typeof N!="object"&&(N=A.source=ng(H,N)),typeof z!="object"&&(z=A.target=ng(H,z)),N.sourceLinks.push(A),z.targetLinks.push(A)}if(d!=null)for(const{sourceLinks:B,targetLinks:A}of C)B.sort(d),A.sort(d)}function x({nodes:C}){for(const I of C)I.value=I.fixedValue===void 0?Math.max(Sc(I.sourceLinks,Ec),Sc(I.targetLinks,Ec)):I.fixedValue}function y({nodes:C}){const I=C.length;let H=new Set(C),B=new Set,A=0;for(;H.size;){for(const N of H){N.depth=A;for(const{target:z}of N.sourceLinks)B.add(z)}if(++A>I)throw new Error("circular link");H=B,B=new Set}}function b({nodes:C}){const I=C.length;let H=new Set(C),B=new Set,A=0;for(;H.size;){for(const N of H){N.height=A;for(const{source:z}of N.targetLinks)B.add(z)}if(++A>I)throw new Error("circular link");H=B,B=new Set}}function $({nodes:C}){const I=Jv(C,A=>A.depth)+1,H=(n-e-o)/(I-1),B=new Array(I);for(const A of C){const N=Math.max(0,Math.min(I-1,Math.floor(l.call(null,A,I))));A.layer=N,A.x0=e+N*H,A.x1=A.x0+o,B[N]?B[N].push(A):B[N]=[A]}if(c)for(const A of B)A.sort(c);return B}function S(C){const I=V_(C,H=>(r-t-(H.length-1)*a)/Sc(H,Ec));for(const H of C){let B=t;for(const A of H){A.y0=B,A.y1=B+A.value*I,B=A.y1+a;for(const N of A.sourceLinks)N.width=N.value*I}B=(r-B+a)/(H.length+1);for(let A=0;A<H.length;++A){const N=H[A];N.y0+=B*(A+1),N.y1+=B*(A+1)}V(H)}}function w(C){const I=$(C);a=Math.min(i,(r-t)/(Jv(I,H=>H.length)-1)),S(I);for(let H=0;H<m;++H){const B=Math.pow(.99,H),A=Math.max(1-B,(H+1)/m);O(I,B,A),T(I,B,A)}}function T(C,I,H){for(let B=1,A=C.length;B<A;++B){const N=C[B];for(const z of N){let J=0,Q=0;for(const{source:te,value:ae}of z.targetLinks){let Y=ae*(z.layer-te.layer);J+=R(te,z)*Y,Q+=Y}if(!(Q>0))continue;let oe=(J/Q-z.y0)*I;z.y0+=oe,z.y1+=oe,F(z)}c===void 0&&N.sort(Yi),P(N,H)}}function O(C,I,H){for(let B=C.length,A=B-2;A>=0;--A){const N=C[A];for(const z of N){let J=0,Q=0;for(const{target:te,value:ae}of z.sourceLinks){let Y=ae*(te.layer-z.layer);J+=X(z,te)*Y,Q+=Y}if(!(Q>0))continue;let oe=(J/Q-z.y0)*I;z.y0+=oe,z.y1+=oe,F(z)}c===void 0&&N.sort(Yi),P(N,H)}}function P(C,I){const H=C.length>>1,B=C[H];j(C,B.y0-a,H-1,I),_(C,B.y1+a,H+1,I),j(C,r,C.length-1,I),_(C,t,0,I)}function _(C,I,H,B){for(;H<C.length;++H){const A=C[H],N=(I-A.y0)*B;N>1e-6&&(A.y0+=N,A.y1+=N),I=A.y1+a}}function j(C,I,H,B){for(;H>=0;--H){const A=C[H],N=(A.y1-I)*B;N>1e-6&&(A.y0-=N,A.y1-=N),I=A.y0-a}}function F({sourceLinks:C,targetLinks:I}){if(d===void 0){for(const{source:{sourceLinks:H}}of I)H.sort(tg);for(const{target:{targetLinks:H}}of C)H.sort(eg)}}function V(C){if(d===void 0)for(const{sourceLinks:I,targetLinks:H}of C)I.sort(tg),H.sort(eg)}function R(C,I){let H=C.y0-(C.sourceLinks.length-1)*a/2;for(const{target:B,width:A}of C.sourceLinks){if(B===I)break;H+=A+a}for(const{source:B,width:A}of I.targetLinks){if(B===C)break;H-=A}return H}function X(C,I){let H=I.y0-(I.targetLinks.length-1)*a/2;for(const{source:B,width:A}of I.targetLinks){if(B===C)break;H+=A+a}for(const{target:B,width:A}of C.sourceLinks){if(B===I)break;H-=A}return H}return h}function Z_({tooltipData:e,fromLabel:t,toLabel:n,weightLabel:r,tooltipTitle:o}){var s,l,c,d;const i=e.source,a=e.target;return L.jsxs(Ue,{tooltipTitle:o,children:[L.jsx(Ue.Item,{label:t,value:i.name}),L.jsx(Ue.Item,{label:n,value:a.name}),L.jsx(Ue.Item,{label:r,value:e.weight.toString()}),L.jsx(Ue.Legend,{value:i.name,darkColor:(s=Re(i.index||0))==null?void 0:s.dark,lightColor:(l=Re(i.index||0))==null?void 0:l.light}),L.jsx(Ue.Legend,{value:a.name,darkColor:(c=Re(a.index||0))==null?void 0:c.dark,lightColor:(d=Re(a.index||0))==null?void 0:d.light})]})}const og=80,ig=20,Q_=30,J_=12,ag=u.forwardRef(({height:e,width:t,tooltipTitle:n,nodes:r,links:o,groups:i,weightLabel:a},s)=>{const l=u.useMemo(()=>R_().nodeId(C=>C.id).nodeWidth(J_).nodePadding(Q_).nodeAlign(C=>C.group),[]),c=u.useRef(null);$c(c,s,`${n}-SankeyChart`);const[d,f]=u.useState(""),[p,m]=u.useState(null),{tooltipData:h,tooltipLeft:v,tooltipTop:x,tooltipOpen:y,showTooltip:b,hideTooltip:$}=Al(),{containerBounds:S,containerRef:w,TooltipInPortal:T}=Wl({detectBounds:!0,debounce:500,scroll:!0,zIndex:1500}),O=u.useMemo(()=>l.extent([[og,ig],[t-og,e-ig-50]])({nodes:r,links:o.map(C=>({...C,value:Number(C.weight)}))}),[e,t,l,r,o]),P=u.useMemo(()=>Math.max(...O.nodes.map(C=>C.depth??0)),[O]),_=u.useMemo(()=>{const C={};let I=-1/0;return O.nodes.forEach(H=>{const{group:B}=H;C[B]?(C[B].x=Math.max(C[B].x??-1/0,H.x0??-1/0),C[B].y=Math.max(C[B].y??-1/0,H.y1??-1/0)):(C[B]={},C[B].x=H.x0,C[B].y=H.y1),I=Math.max(I,C[B].y??-1/0),C[B].y=I}),C},[O]),j=u.useCallback(C=>{const I=l.nodeId()(C);f(d===I?"":I)},[d,l]),F=u.useCallback(()=>{f(""),m(null)},[]),V=u.useMemo(()=>d===""&&p===null?new Set:new Set(O.links.filter(C=>l.nodeId()(C.source)===d||l.nodeId()(C.target)===d||(p==null?void 0:p.source)===C.source&&(p==null?void 0:p.target)===C.target)),[d,O,p,l]),R=u.useCallback((C,I)=>{const H=("clientX"in C?C.clientX:0)-S.left,B=("clientY"in C?C.clientY:0)-S.top;m(I),H&&B&&b({tooltipLeft:H,tooltipTop:B,tooltipData:I})},[b,S]),X=u.useCallback(()=>{F(),$()},[F,$]);return L.jsxs("div",{ref:c,className:"bg-white w-min h-min rabbit-ds",id:"sankey-chart",children:[L.jsxs("svg",{height:e,width:t,ref:w,children:[L.jsx("g",{children:O.links.map(C=>L.jsx(SM,{data:C,source:I=>({x:I.source.x1,y:I.y0}),target:I=>({x:I.target.x0,y:I.y1}),x:I=>I.x??0,y:I=>I.y??0,fill:"none",pointerEvents:"stroke",onMouseLeave:()=>X(),onMouseMove:I=>R(I,C),stroke:Re(C.source.index||0).light,strokeWidth:C.width,strokeOpacity:V.has(C)?.7:.25},C.index))}),L.jsx("g",{children:O.nodes.map(C=>{var I,H,B;return L.jsx("g",{children:L.jsx(vM,{x:C.x0??0,height:(C.y1??0)-(C.y0??0)+10,width:(C.x1??0)-(C.x0??0),y:(C.y0??0)-5,onMouseEnter:()=>j(C),onMouseLeave:()=>F(),radius:2,fill:d===C.id?(I=Re(C.index||0))==null?void 0:I.dark:(H=Re(C.index||0))==null?void 0:H.light,stroke:(B=Re(C.index||0))==null?void 0:B.dark,all:!0})},C.index)})}),L.jsx("g",{children:i.map(C=>L.jsx(yc,{axisCharLimit:20,x:_[C.id].x??0,y:(_[C.id].y??0)+40,textLabel:C.name,textStyles:{fontSize:10,fontWeight:600,textAnchor:"middle",fill:"#666666"}},C.id))}),L.jsxs("g",{children:[O.nodes.map(C=>L.jsx(yc,{axisCharLimit:8,x:C.depth===P?(C.x1??0)+10:(C.x0??0)-10,y:(C.y0??0)+((C.y1??0)-(C.y0??0))/2,textLabel:C.name,textStyles:{fontSize:10,fontWeight:600,textAnchor:C.depth===P?"start":"end",fill:"#666666"}},C.index)),O.nodes.map(C=>C.value&&L.jsx(ys,{x:C.depth===P?(C.x1??0)+10:(C.x0??0)-10,y:(C.y0??0)+((C.y1??0)-(C.y0??0))/2+16,style:{fontSize:10,fontWeight:400,textAnchor:C.depth===P?"start":"end",fill:"#666666"},children:`(${C.value.toString()})`},C.index))]})]}),y&&h&&L.jsx(T,{top:x,left:v,unstyled:!0,applyPositionStyle:!0,children:L.jsx(Z_,{tooltipData:h,fromLabel:`From: ${i[h.source.group].name}`,toLabel:`To: ${i[h.target.group].name}`,weightLabel:a,tooltipTitle:n})},Math.random())]})});ag.displayName="Sankey";const sg=u.forwardRef((e,t)=>L.jsx(Gi,{debounceTime:10,children:({width:n,height:r})=>n&&r&&L.jsx(ag,{ref:t,width:n,height:r,...e})}));sg.displayName="SankeyChart";const e3=sg;function t3(e){return"bandwidth"in e?e.bandwidth():0}var n3=["top","left","scale","width","stroke","strokeWidth","strokeDasharray","className","children","numTicks","lineStyle","offset","tickValues"];function Tc(){return Tc=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Tc.apply(this,arguments)}function r3(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function lg(e){var t=e.top,n=t===void 0?0:t,r=e.left,o=r===void 0?0:r,i=e.scale,a=e.width,s=e.stroke,l=s===void 0?"#eaf0f6":s,c=e.strokeWidth,d=c===void 0?1:c,f=e.strokeDasharray,p=e.className,m=e.children,h=e.numTicks,v=h===void 0?10:h,x=e.lineStyle,y=e.offset,b=e.tickValues,$=r3(e,n3),S=b??fl(i,v),w=(y??0)+t3(i)/2,T=S.map(function(O,P){var _,j=((_=dl(i(O)))!=null?_:0)+w;return{index:P,from:new an({x:0,y:j}),to:new an({x:a,y:j})}});return u.createElement(En,{className:et("visx-rows",p),top:n,left:o},m?m({lines:T}):T.map(function(O){var P=O.from,_=O.to,j=O.index;return u.createElement(MM,Tc({key:"row-line-"+j,from:P,to:_,stroke:l,strokeWidth:d,strokeDasharray:f,style:x},$))}))}lg.propTypes={tickValues:ne.array,width:ne.number.isRequired};function cg({xValue:e,yValue:t,tooltipTitle:n,xAxisLabel:r,yAxisLabel:o,legendValue:i,legendDarkColor:a,legendLightColor:s}){const l=e==null?void 0:e.toString(),c=t==null?void 0:t.toString();return L.jsxs(Ue,{tooltipTitle:n,showSideBySide:!0,children:[L.jsx(Ue.Item,{label:r,value:l}),L.jsx(Ue.Item,{label:o,value:c}),L.jsx(Ue.Legend,{value:i,darkColor:a,lightColor:s})]})}cg.defaultProps={xValue:void 0,yValue:void 0};const ug=20,dg=50,Pc=80,Ki=50,o3=10,i3=25,Mc=u.forwardRef(({tooltipTitle:e,xAxisLabel:t,yAxisLabel:n,domain:r,binCount:o,data:i,width:a,height:s,maxBinCount:l=i3,minBinCount:c=o3,integerBins:d=!1,integerYAxis:f=!1},p)=>{const m=u.useMemo(()=>ai(i),[i]),{histogramDomain:h,threshold:v,thresholdInteger:x}=u.useMemo(()=>{const A=m[0]??0,N=A===m[1]?c+A:m[1]??0,z=N-A>c?N:c+A,J=Math.min(Math.max(N-A,c),l),Q=Math.floor(m[0]??0),oe=Math.ceil(z);return{histogramDomain:r||(d?[Q,oe]:[A,N]),threshold:J,thresholdInteger:Math.ceil(J)}},[m,r,d,l,c]),y=u.useMemo(()=>oo({domain:h,range:[Ki,a-dg],round:!0,nice:!0}),[h,a]),b=u.useMemo(()=>kE().domain(y.domain()).thresholds(o||(d?x:v))(i),[y,o,i,v,x,d]),$=u.useMemo(()=>oo({domain:[0,Ss(b,A=>A.length)??0],range:[s-Pc,ug],round:!0,nice:!0}),[b,s]),S=u.useMemo(()=>$.ticks().filter(A=>f?Number.isInteger(A):A),[f,$]),w=u.useRef(null);$c(w,p,`${t}-${n}-Histogram`);const{tooltipData:T,tooltipLeft:O,tooltipTop:P,tooltipOpen:_,showTooltip:j,hideTooltip:F}=Al(),{containerBounds:V,containerRef:R,TooltipInPortal:X}=Wl({detectBounds:!0,debounce:500,scroll:!0,zIndex:1500}),C=a-Ki-dg,I=s-ug-Pc-100,H=u.useCallback((A,N)=>{const z=("clientX"in A?A.clientX:0)-V.left,J=("clientY"in A?A.clientY:0)-V.top;z&&J&&j({tooltipLeft:z,tooltipTop:J,tooltipData:N})},[j,V]),B=u.useCallback(()=>{F()},[F]);return L.jsxs("div",{className:"bg-white flex flex-col rabbit-ds",style:{width:a,height:s},ref:w,children:[L.jsxs("svg",{width:a,height:s,ref:R,children:[L.jsx(Ol,{orientation:"bottom",scale:y,top:s-Pc,hideTicks:!0,numTicks:6,stroke:"#CFD7DF",strokeWidth:1,rangePadding:{end:10},label:`${t} ➔`,tickLabelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,fill:"#666666",textAnchor:"middle"},labelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,dy:10,fill:"#666666",textAnchor:"middle",verticalAnchor:"middle"}}),L.jsx(Ol,{orientation:"left",scale:$,left:Ki,hideTicks:!0,strokeWidth:1,stroke:"#CFD7DF",tickFormat:f?Ei("d"):void 0,tickValues:S,label:`${n} ➔`,tickLabelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,fill:"#666666",textAnchor:"end"},labelProps:{fontFamily:"system-ui",fontSize:"10px",fontWeight:600,dx:-20,fill:"#666666",textAnchor:"middle",verticalAnchor:"middle"}}),L.jsxs(En,{children:[L.jsx(lg,{scale:$,width:C,height:I,left:Ki,top:0,lineStyle:{stroke:"#EBEFF3",strokeWidth:1}}),b.map(A=>{const N=Math.abs($(0)-$(A.length)),z=Math.abs(y(A.x1??0)-y(A.x0??0));return L.jsx("g",{children:L.jsx(fM,{x:y(A.x0??0),y:$(A.length),width:z,height:N&&N-1,fill:Re(0).light,stroke:Re(0).dark,strokeWidth:1,onMouseMove:J=>H(J,A),onMouseLeave:()=>B()})},Math.random())})]})]}),_&&T&&L.jsx(X,{top:P,left:O,unstyled:!0,applyPositionStyle:!0,children:L.jsx(cg,{xAxisLabel:t,xValue:`${T.x0} to ${T.x1}`,yAxisLabel:n,yValue:T.length,tooltipTitle:e,legendValue:n,legendDarkColor:Re(0).dark,legendLightColor:Re(0).light})},Math.random()),$.domain()[2]]})}),fg=u.forwardRef((e,t)=>L.jsx(Gi,{debounceTime:10,children:({width:n,height:r})=>L.jsx(Mc,{ref:t,width:n,height:r,...e})}));Mc.defaultProps={domain:void 0,binCount:void 0,integerBins:!1,integerYAxis:!1},Mc.displayName="HistogramBase",fg.displayName="HistogramChart";const a3=fg;function s3({count:e,totalCount:t,title:n,subTitle:r,className:o,unstyledDimension:i=!1,style:a}){const s="max-w-[336px] min-h-[96px] min-w-[200px]";return L.jsxs("div",{className:_e("rabbit-ds box-border px-2 py-4 bg-white rounded-lg shadow flex-col justify-center items-start gap-1 inline-flex",o,!i&&s),style:a,children:[L.jsxs("div",{className:"self-stretch px-3 py-1 flex items-baseline",children:[L.jsx("div",{className:"text-zinc-800 text-2xl font-semibold",children:e}),t&&t>0?L.jsxs("div",{className:"text-stone-500 text-xs font-normal",children:["/",t]}):null]}),L.jsx("div",{className:"self-stretch px-3 justify-start items-center gap-2 inline-flex",children:L.jsxs("div",{className:"grow shrink basis-0 flex-col justify-start items-start gap-0.5 inline-flex",children:[L.jsx("div",{className:"self-stretch justify-start items-start gap-2.5 inline-flex",children:L.jsx("div",{className:"grow shrink basis-0 text-zinc-800 text-xs font-semibold leading-none",children:n})}),r&&L.jsx("div",{className:"self-stretch justify-start py-2 items-center gap-1 inline-flex",children:L.jsx("div",{className:"grow shrink basis-0 text-stone-500 text-xs font-normal leading-none",children:r})})]})})]})}const Xi="ToggleGroup",[pg,r6]=Ct(Xi,[Ao]),hg=Ao(),l3=u.forwardRef((e,t)=>{const{type:n,...r}=e;if(n==="single"){const o=r;return u.createElement(c3,ee({},o,{ref:t}))}if(n==="multiple"){const o=r;return u.createElement(u3,ee({},o,{ref:t}))}throw new Error(`Missing prop \`type\` expected on \`${Xi}\``)}),[mg,vg]=pg(Xi),c3=u.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:o=()=>{},...i}=e,[a,s]=St({prop:n,defaultProp:r,onChange:o});return u.createElement(mg,{scope:e.__scopeToggleGroup,type:"single",value:a?[a]:[],onItemActivate:s,onItemDeactivate:u.useCallback(()=>s(""),[s])},u.createElement(gg,ee({},i,{ref:t})))}),u3=u.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:o=()=>{},...i}=e,[a=[],s]=St({prop:n,defaultProp:r,onChange:o}),l=u.useCallback(d=>s((f=[])=>[...f,d]),[s]),c=u.useCallback(d=>s((f=[])=>f.filter(p=>p!==d)),[s]);return u.createElement(mg,{scope:e.__scopeToggleGroup,type:"multiple",value:a,onItemActivate:l,onItemDeactivate:c},u.createElement(gg,ee({},i,{ref:t})))}),[d3,f3]=pg(Xi),gg=u.forwardRef((e,t)=>{const{__scopeToggleGroup:n,disabled:r=!1,rovingFocus:o=!0,orientation:i,dir:a,loop:s=!0,...l}=e,c=hg(n),d=$o(a),f={role:"group",dir:d,...l};return u.createElement(d3,{scope:n,rovingFocus:o,disabled:r},o?u.createElement(Ru,ee({asChild:!0},c,{orientation:i,dir:d,loop:s}),u.createElement(we.div,ee({},f,{ref:t}))):u.createElement(we.div,ee({},f,{ref:t})))}),kc="ToggleGroupItem",p3=u.forwardRef((e,t)=>{const n=vg(kc,e.__scopeToggleGroup),r=f3(kc,e.__scopeToggleGroup),o=hg(e.__scopeToggleGroup),i=n.value.includes(e.value),a=r.disabled||e.disabled,s={...e,pressed:i,disabled:a},l=u.useRef(null);return r.rovingFocus?u.createElement(Zu,ee({asChild:!0},o,{focusable:!a,active:i,ref:l}),u.createElement(yg,ee({},s,{ref:t}))):u.createElement(yg,ee({},s,{ref:t}))}),yg=u.forwardRef((e,t)=>{const{__scopeToggleGroup:n,value:r,...o}=e,i=vg(kc,n),a={role:"radio","aria-checked":e.pressed,"aria-pressed":void 0},s=i.type==="single"?a:void 0;return u.createElement(Xc,ee({},s,o,{ref:t,onPressedChange:l=>{l?i.onItemActivate(r):i.onItemDeactivate(r)}}))}),h3=l3,m3=p3;function v3({children:e,...t}){return L.jsx(h3,{className:"flex gap-2",...t,children:e})}function g3({value:e,disabled:t,selected:n,icon:r,label:o,count:i,...a}){return L.jsx(m3,{asChild:!0,value:e,...a,children:L.jsx("button",{type:"button",className:_e("rabbit-ds h-7 flex-col w-auto p-0 border border-solid rounded-full justify-center items-center inline-flex hover:cursor-pointer focus:outline-1 focus:outline-offset-2","data-[state=off]:border-gray-100 data-[state=off]:bg-gray-100 data-[state=off]:text-dove-gray-500","data-[state=on]:border-sky-800 data-[state=on]:bg-sky-100 data-[state=on]:text-sky-800"),children:L.jsxs("div",{className:"px-4 py-1 rounded-full flex-row justify-start items-center gap-2.5 flex",children:[r?L.jsx("div",{className:"w-4 h-4 justify-center items-center flex",children:r}):null,L.jsxs("div",{className:"text-sm leading-tight font-semibold",children:[o?L.jsx("span",{children:o}):null," ",i?L.jsxs("span",{children:["(",i,")"]}):null]})]})})})}ve.Button=N0,ve.CardKPI=s3,ve.Checkbox=Kc,ve.Chip=O0,ve.ChipGroup=v3,ve.ChipGroupItem=g3,ve.Dropdown=Vx,ve.DropdownCheckboxItem=qd,ve.DropdownContent=Gd,ve.DropdownGroup=Bd,ve.DropdownItem=Vd,ve.DropdownLabel=Kd,ve.DropdownPortal=Yx,ve.DropdownRadioGroup=Xx,ve.DropdownRadioItem=Yd,ve.DropdownSeparator=Xd,ve.DropdownSub=Kx,ve.DropdownSubContent=Hd,ve.DropdownSubTrigger=Ud,ve.DropdownTrigger=qx,ve.HistogramChart=a3,ve.Input=A0,ve.LineChart=G_,ve.SankeyChart=e3,ve.Select=Fw,ve.SelectContent=pf,ve.SelectGroup=jw,ve.SelectItem=mf,ve.SelectLabel=hf,ve.SelectSeparator=vf,ve.SelectTrigger=ff,ve.SelectValue=zw,ve.Tooltip=_f,ve.TooltipContent=es,ve.TooltipPortal=Af,ve.TooltipProvider=Of,ve.TooltipTrigger=Nf,Object.defineProperty(ve,Symbol.toStringTag,{value:"Module"})});